Skip to content
Snippets Groups Projects
Verified Commit d9c864d3 authored by Julian Ospald's avatar Julian Ospald :tea:
Browse files

Make sure cabal is executable wrt #46

parent 4280d710
No related branches found
No related tags found
No related merge requests found
Pipeline #23425 canceled
...@@ -275,10 +275,20 @@ installCabalBindist dlinfo ver (PlatformRequest {..}) = do ...@@ -275,10 +275,20 @@ installCabalBindist dlinfo ver (PlatformRequest {..}) = do
let cabalFile = [rel|cabal|] let cabalFile = [rel|cabal|]
liftIO $ createDirRecursive newDirPerms inst liftIO $ createDirRecursive newDirPerms inst
destFileName <- lift $ parseRel (toFilePath cabalFile <> "-" <> verToBS ver) destFileName <- lift $ parseRel (toFilePath cabalFile <> "-" <> verToBS ver)
let destPath = inst </> destFileName
handleIO (throwE . CopyError . show) $ liftIO $ copyFile handleIO (throwE . CopyError . show) $ liftIO $ copyFile
(path </> cabalFile) (path </> cabalFile)
(inst </> destFileName) (destPath)
Overwrite Overwrite
liftIO $ setFileMode
(toFilePath destPath)
( newFilePerms
`unionFileModes` ownerExecuteMode
`unionFileModes` groupExecuteMode
`unionFileModes` otherExecuteMode
)
-- | Installs cabal into @~\/.ghcup\/bin/cabal-\<ver\>@ and -- | Installs cabal into @~\/.ghcup\/bin/cabal-\<ver\>@ and
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment