hackage-server
hackage-server copied to clipboard
Link to last working doc
This pull request implements issue #668 as an GSoC project, mentored by @gbaz. It adds an indicator for each package version with a working doc. It looks like this, where version 0.1.0
has doc but 0.1.1
not:
Actually I'm not very satisfied with the UI and am expecting a better idea.
This is my first time contributing here, so if I did something wrong in code style or structure please point it out.
Now I changed the UI and this time it's much better. When the current version doesn't have a doc built, it tries to find the greatest version with a working doc that is not depcrated. Screensoht:
I think that find code is correct. However, I think the link should not be in the versions listing.
Rather, it should be either above or below the modules listing in the main pane, not the sidebar. (As the modules listing is where people would click through to get the docs, should they exist:

Additionally, maybe the redirect for docs, as described in this issue, could pick last working docs: https://github.com/haskell/hackage-server/issues/1095
The described redirect for docs is added. Now DocumentationFeature
depend on VersionsFeature
, since it has to find out the package status. Unpreferred versions are also excluded from redirection. Will work on UI tomorrow.
Screenshot:
was accidentally included in https://github.com/haskell/hackage-server/pull/1116 and hence already merged