haskell / haddock

Haskell Documentation Tool
www.haskell.org/haddock/
BSD 2-Clause "Simplified" License
361 stars 241 forks source link

Package metadata #1493

Closed coot closed 2 years ago

coot commented 2 years ago

I would like haddock to be aware of at least rudimentary package metadata. As as a start the package name of what is being build. The rationale for that is splitting the haddocks generated content page (the tree of modules) into a list of trees one per package. The simple way to solve this is to pass --package-name & --package-version to haddock which would be written to the interface file file; when haddock generates the content page it reads the interface files it would know which interfaces comes from which package:

I have a draft pr where I infer package names from interface file names.

coot commented 2 years ago

@Kleidukos let me know what do you think. Here's a print screen of what I have so far: image

I think it would be nice to also print package version next to its name.

coot commented 2 years ago

Related to haskell/cabal#7669.

Kleidukos commented 2 years ago

@coot I love it.