factor out installCabal' from installCabalBindist
, to be shared with installCabalBinIsolated
function
This commit is contained in:
parent
9b3d55a095
commit
8b7c22440e
@ -470,13 +470,13 @@ installCabalBindist dlinfo ver = do
|
||||
let lInstCabal = headMay . reverse . sort $ cVers
|
||||
when (maybe True (ver >=) lInstCabal) $ liftE $ setCabal ver
|
||||
|
||||
where
|
||||
-- | Install an unpacked cabal distribution.
|
||||
installCabal' :: (MonadLogger m, MonadCatch m, MonadIO m)
|
||||
-- | Install an unpacked cabal distribution.
|
||||
installCabal' :: (MonadLogger m, MonadCatch m, MonadIO m)
|
||||
=> FilePath -- ^ Path to the unpacked cabal bindist (where the executable resides)
|
||||
-> FilePath -- ^ Path to install to
|
||||
-> Version
|
||||
-> Excepts '[CopyError] m ()
|
||||
installCabal' path inst = do
|
||||
installCabal' path inst ver = do
|
||||
lift $ $(logInfo) "Installing cabal"
|
||||
let cabalFile = "cabal"
|
||||
liftIO $ createDirRecursive' inst
|
||||
|
Loading…
Reference in New Issue
Block a user