mirror of
https://github.com/commercialhaskell/stackage.git
synced 2026-01-12 07:18:31 +01:00
skip-hoogle options
This commit is contained in:
parent
d0138fae7a
commit
076c477905
@ -1,6 +1,7 @@
|
||||
## 0.6.1
|
||||
|
||||
* Switch to V2 upload by default
|
||||
* --skip-hoogle option
|
||||
|
||||
## 0.6.0
|
||||
|
||||
|
||||
@ -42,6 +42,7 @@ data BuildFlags = BuildFlags
|
||||
, bfSkipCheck :: !Bool
|
||||
, bfUploadV1 :: !Bool
|
||||
, bfServer :: !StackageServer
|
||||
, bfBuildHoogle :: !Bool
|
||||
} deriving (Show)
|
||||
|
||||
data BuildType = Nightly | LTS BumpType
|
||||
@ -221,6 +222,7 @@ getPerformBuild buildFlags Settings {..} = PerformBuild
|
||||
, pbEnableExecDyn = bfEnableExecDyn buildFlags
|
||||
, pbVerbose = bfVerbose buildFlags
|
||||
, pbAllowNewer = bfSkipCheck buildFlags
|
||||
, pbBuildHoogle = bfBuildHoogle buildFlags
|
||||
}
|
||||
|
||||
-- | Make a complete plan, build, test and upload bundle, docs and
|
||||
|
||||
@ -33,6 +33,7 @@ data InstallFlags = InstallFlags
|
||||
, ifEnableExecDyn :: !Bool
|
||||
, ifVerbose :: !Bool
|
||||
, ifSkipCheck :: !Bool
|
||||
, ifBuildHoogle :: !Bool
|
||||
} deriving (Show)
|
||||
|
||||
-- | Source for build plan.
|
||||
@ -55,6 +56,7 @@ getPerformBuild plan InstallFlags{..} =
|
||||
, pbEnableExecDyn = ifEnableExecDyn
|
||||
, pbVerbose = ifVerbose
|
||||
, pbAllowNewer = ifSkipCheck
|
||||
, pbBuildHoogle = ifBuildHoogle
|
||||
}
|
||||
|
||||
-- | Install stackage from an existing build plan.
|
||||
|
||||
@ -69,6 +69,10 @@ data PerformBuild = PerformBuild
|
||||
, pbVerbose :: Bool
|
||||
, pbAllowNewer :: Bool
|
||||
-- ^ Pass --allow-newer to cabal configure
|
||||
, pbBuildHoogle :: Bool
|
||||
-- ^ Should we build Hoogle database?
|
||||
--
|
||||
-- May be disabled due to: https://ghc.haskell.org/trac/ghc/ticket/9921
|
||||
}
|
||||
|
||||
data PackageInfo = PackageInfo
|
||||
@ -421,12 +425,13 @@ singleBuild pb@PerformBuild {..} registeredPackages SingleBuild {..} =
|
||||
, "/,"
|
||||
, fpToText hf
|
||||
]
|
||||
args = "haddock"
|
||||
: "--hyperlink-source"
|
||||
: "--html"
|
||||
: "--hoogle"
|
||||
: "--html-location=../$pkg-$version/"
|
||||
: hfsOpts
|
||||
args = ($ hfsOpts) $ execWriter $ do
|
||||
let tell' x = tell (x:)
|
||||
tell' "haddock"
|
||||
tell' "--hyperlink-source"
|
||||
tell' "--html"
|
||||
when pbBuildHoogle $ tell' "--hoogle"
|
||||
tell' "--html-location=../$pkg-$version/"
|
||||
|
||||
eres <- tryAny $ run "cabal" args
|
||||
|
||||
|
||||
@ -116,7 +116,12 @@ main =
|
||||
(long "server-url" <>
|
||||
metavar "SERVER-URL" <>
|
||||
showDefault <> value (T.unpack $ unStackageServer def) <>
|
||||
help "Server to upload bundle to")))
|
||||
help "Server to upload bundle to"))) <*>
|
||||
fmap
|
||||
not
|
||||
(switch
|
||||
(long "skip-hoogle" <>
|
||||
help "Skip generating Hoogle input files"))
|
||||
|
||||
nightlyUploadFlags = fromString <$> strArgument
|
||||
(metavar "DATE" <>
|
||||
@ -178,7 +183,12 @@ main =
|
||||
help "Output verbose detail about the build steps") <*>
|
||||
switch
|
||||
(long "skip-check" <>
|
||||
help "Skip the check phase, and pass --allow-newer to cabal configure")
|
||||
help "Skip the check phase, and pass --allow-newer to cabal configure") <*>
|
||||
fmap
|
||||
not
|
||||
(switch
|
||||
(long "skip-hoogle" <>
|
||||
help "Skip generating Hoogle input files"))
|
||||
|
||||
uploadv2 (path, url) = withManager tlsManagerSettings $ \man -> do
|
||||
token <- getStackageAuthToken
|
||||
|
||||
Loading…
Reference in New Issue
Block a user