Skip to content

Commit

Permalink
haddock-project: added --all switch
Browse files Browse the repository at this point in the history
Added `--all` (`--haddock-all`) switches for compatibility with
`haddock` command.  `--haddock-all` alias is added, since that's what is
suggested by some warning messages.

Fixes haskell#10051
  • Loading branch information
coot authored and tbidne committed Jul 7, 2024
1 parent e9d41c8 commit f950d4e
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 0 deletions.
21 changes: 21 additions & 0 deletions Cabal/src/Distribution/Simple/Setup/Haddock.hs
Original file line number Diff line number Diff line change
Expand Up @@ -584,6 +584,27 @@ haddockProjectOptions _showOrParseArgs =
haddockProjectForeignLibs
(\v flags -> flags{haddockProjectForeignLibs = v})
trueArg
, option
""
["all", "haddock-all"]
"Run haddock for all targets"
( \f ->
allFlags
[ haddockProjectExecutables f
, haddockProjectTestSuites f
, haddockProjectBenchmarks f
, haddockProjectForeignLibs f
]
)
( \v flags ->
flags
{ haddockProjectExecutables = v
, haddockProjectTestSuites = v
, haddockProjectBenchmarks = v
, haddockProjectForeignLibs = v
}
)
trueArg
, option
""
["internal"]
Expand Down
4 changes: 4 additions & 0 deletions changelog.d/issue-10051
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
synopsis: Added `--all` and `--haddock-all` switches to `haddock-project` subcommand
packages: cabal-install
issues: #10051
prs: #2272

0 comments on commit f950d4e

Please sign in to comment.