mirror of
https://github.com/commercialhaskell/stackage.git
synced 2026-01-11 23:08:30 +01:00
Add --skip-upload flag
Easier for testing stackage the executable/library itself.
This commit is contained in:
parent
fb73435572
commit
1f2824540e
@ -28,6 +28,7 @@ import System.IO (BufferMode (LineBuffering), hSetBuffering)
|
||||
-- | Flags passed in from the command line.
|
||||
data BuildFlags = BuildFlags
|
||||
{ bfEnableTests :: !Bool
|
||||
, bfDoUpload :: !Bool
|
||||
} deriving (Show)
|
||||
|
||||
data BuildType = Nightly | LTS BumpType
|
||||
@ -182,7 +183,8 @@ completeBuild buildType buildFlags = withManager tlsManagerSettings $ \man -> do
|
||||
}
|
||||
performBuild pb >>= mapM_ putStrLn
|
||||
|
||||
finallyUpload settings man pb
|
||||
when (bfDoUpload buildFlags) $
|
||||
finallyUpload settings man pb
|
||||
|
||||
-- | The final part of the complete build process: uploading a bundle,
|
||||
-- docs and a distro to hackage.
|
||||
|
||||
@ -61,4 +61,9 @@ main =
|
||||
not
|
||||
(switch
|
||||
(long "skip-tests" <>
|
||||
help "Skip build and running the test suites"))
|
||||
help "Skip build and running the test suites")) <*>
|
||||
fmap
|
||||
not
|
||||
(switch
|
||||
(long "skip-upload" <>
|
||||
help "Skip uploading bundle, docs, etc."))
|
||||
|
||||
Loading…
Reference in New Issue
Block a user