From 79988a8a5c2e3c1f29ca1e20c2d4a258863cd106 Mon Sep 17 00:00:00 2001 From: Daniel Gröber Date: Fri, 12 Jan 2018 19:47:07 +0100 Subject: Make PackageDbDir newtype accessor more conventional --- src/CabalHelper/Compiletime/Compile.hs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/CabalHelper/Compiletime/Compile.hs') 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 -- cgit v1.2.3