Rufflewind
Rufflewind

Reputation: 8966

Why does cabal haddock --hyperlink-source not generate the source HTMLs?

For a cabal project, I wanted to generate haddock documentation with hyperlinks to the source code, so I did the usual:

cabal haddock --hyperlink-source

The links were generated, but upon clicking the links I find that the actual source code is not included even though the links are. The source code is supposed to be rendered via HTML. How do I generate those as well?


Currently using:

Upvotes: 4

Views: 341

Answers (1)

Rufflewind
Rufflewind

Reputation: 8966

Turns out it was because hscolour was not installed. Installing it via:

cabal install hscolour

fixed the problem.

Interestingly, there was a warning for it that said

Warning: The program 'hscolour' version >=1.8 is required but it could not be found.

but it was buried inside the usual haddock output so I didn't notice it until now.

Upvotes: 7

Related Questions