Skip to content

Commit

Permalink
Re #6270 Fix --haddock-arguments with --haddock-for-hackage
Browse files Browse the repository at this point in the history
  • Loading branch information
mpilgrem committed Mar 5, 2024
1 parent 59f3e81 commit 441df6f
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 14 deletions.
2 changes: 2 additions & 0 deletions ChangeLog.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@ Other enhancements:

Bug fixes:

* `--haddock-for-hackage` does not ignore `--haddock-arguments`.

## v2.15.1 - 2024-02-09

Release notes:
Expand Down
29 changes: 15 additions & 14 deletions src/Stack/Build/ExecutePackage.hs
Original file line number Diff line number Diff line change
Expand Up @@ -596,20 +596,21 @@ singleBuild

fulfillHaddockExpectations pname mcurator $ \keep -> do
let args = concat
( if isHaddockForHackage
then
[ [ "--for-hackage" ] ]
else
[ [ "--html"
, "--hoogle"
, "--html-location=../$pkg-$version/"
]
, [ "--haddock-option=--hyperlinked-source"
| ee.buildOpts.haddockHyperlinkSource
]
, [ "--internal" | ee.buildOpts.haddockInternal ]
, quickjump
]
( ( if isHaddockForHackage
then
[ [ "--for-hackage" ] ]
else
[ [ "--html"
, "--hoogle"
, "--html-location=../$pkg-$version/"
]
, [ "--haddock-option=--hyperlinked-source"
| ee.buildOpts.haddockHyperlinkSource
]
, [ "--internal" | ee.buildOpts.haddockInternal ]
, quickjump
]
)
<> [ [ "--haddock-option=" <> opt
| opt <- ee.buildOpts.haddockOpts.additionalArgs
]
Expand Down

0 comments on commit 441df6f

Please sign in to comment.