Create cache repo path if it doesn't exist

This commit is contained in:
Justin Leitgeb 2014-06-04 08:51:29 -05:00
parent 148c485c68
commit a7e2e9a064

View File

@ -91,8 +91,12 @@ defaultSuccessHandler _ = putStrLn "Deploy completed successfully."
-- system.
setupDirs :: RC (Maybe String)
setupDirs = do
pathName <- use $ config . deployPath
remoteCommand $ "mkdir -p " ++ joinPath [pathName, "releases"]
conf <- use config
remoteCommand $ intercalate " && "
[ "mkdir -p " ++ releasesPath conf
, "mkdir -p " ++ cacheRepoPath conf
]
remoteCommand :: String -- ^ The command to run remotely
-> RC (Maybe String)