Fix hardcoded repository path in the scp call

This commit is contained in:
2023-10-26 19:40:47 +02:00
parent 58a1b8864c
commit 6c0e2c2d24
2 changed files with 14 additions and 4 deletions

View File

@ -121,9 +121,11 @@ remoteFileExists url = hostedSources url
uploadCommand :: Text -> Text -> SlackBuilderT ()
uploadCommand localPath remotePath' = do
remoteRoot <- SlackBuilderT $ asks remotePath
liftIO $ callProcess "scp" $ Text.unpack <$>
[ "slackbuilds/" <> localPath
, remoteRoot <> remotePath'
repository' <- SlackBuilderT $ asks repository
liftIO $ callProcess "scp"
[ repository' </> Text.unpack localPath
, Text.unpack $ remoteRoot <> remotePath'
]
cloneAndArchive :: Text -> Text -> FilePath -> Text -> SlackBuilderT ()