aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/CabalHelper/Compiletime/Compile.hs4
-rw-r--r--src/CabalHelper/Compiletime/Types.hs2
2 files changed, 3 insertions, 3 deletions
diff --git a/src/CabalHelper/Compiletime/Compile.hs b/src/CabalHelper/Compiletime/Compile.hs
index b956932..a96ded8 100644
--- a/src/CabalHelper/Compiletime/Compile.hs
+++ b/src/CabalHelper/Compiletime/Compile.hs
@@ -196,7 +196,7 @@ compile distdir opts@Options {..} Compile {..} = do
\|| (major1) == "++show mj1++" && (major2) < "++show mj2++"\
\|| (major1) == "++show mj1++" && (major2) == "++show mj2++" && (minor) <= "++show mi++")"
],
- maybeToList $ ("-package-conf="++) <$> packageDbDir <$> compPackageDb,
+ maybeToList $ ("-package-conf="++) <$> unPackageDbDir <$> compPackageDb,
map ("-i"++) $ nub $ "":compCabalHelperSourceDir:maybeToList cnCabalSourceDir,
if isNothing cnCabalSourceDir
@@ -550,7 +550,7 @@ listCabalVersions opts = listCabalVersions' opts Nothing
-- TODO: Include sandbox? Probably only relevant for build-type:custom projects.
listCabalVersions' :: Options -> Maybe PackageDbDir -> IO [Version]
listCabalVersions' Options {..} mdb = do
- let mdbopt = ("--package-conf="++) <$> packageDbDir <$> mdb
+ let mdbopt = ("--package-conf="++) <$> unPackageDbDir <$> mdb
opts = ["list", "--simple-output", "Cabal"] ++ maybeToList mdbopt
catMaybes . map (fmap snd . parsePkgId . fromString) . words
diff --git a/src/CabalHelper/Compiletime/Types.hs b/src/CabalHelper/Compiletime/Types.hs
index cf36e49a..297f785 100644
--- a/src/CabalHelper/Compiletime/Types.hs
+++ b/src/CabalHelper/Compiletime/Types.hs
@@ -34,7 +34,7 @@ data Options = Options {
, oCabalPkgDb :: Maybe PackageDbDir
}
-newtype PackageDbDir = PackageDbDir { packageDbDir :: FilePath }
+newtype PackageDbDir = PackageDbDir { unPackageDbDir :: FilePath }
defaultOptions :: Options
defaultOptions = Options False "ghc" "ghc-pkg" "cabal" Nothing Nothing