Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix multi-package Haddock CSS handling #10637

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

ozkutuk
Copy link

@ozkutuk ozkutuk commented Dec 12, 2024

Fixes #10636

This PR fixes the linked issue by making the stylesheet path absolute before passing it to Haddock, and also passing the stylesheet to the index generator as well.

QA Notes

Calling cabal haddock-project --css=<css-file> on a multi-package project where every package has its own subdirectory (and not have their source files at the project root) should produce documentation such that:

  • The index (i.e. ./haddocks/index.html) is styled by the provided CSS file
  • Each package has their docs (i.e. ./haddocs/<package>/<module>.html) styled by the provided CSS file

This reproducer of the original issue can be used for QA purposes.


Template Α: This PR modifies behaviour or interface

Include the following checklist in your PR:

@ulysses4ever
Copy link
Collaborator

Thanks! This will need a changelog file and preferably Manual QA notes (especially since it doesn’t have tests).

@ozkutuk
Copy link
Author

ozkutuk commented Dec 12, 2024

@ulysses4ever I have added a changelog file and QA notes. I wasn't sure whether this would be considered a significant change, but I have refrained from marking it as such unless you suggest otherwise.

@geekosaur
Copy link
Collaborator

@ozkutuk
Copy link
Author

ozkutuk commented Dec 12, 2024

Is the failing check related to my changes, or is it a flaky test? I can't see how the changes would only cause macos-latest ghc-9.10.1 to break.

@geekosaur
Copy link
Collaborator

That test (very rarely) fails for no obvious reason, and restarting the job generally fixes it. I've restarted it.

@geekosaur
Copy link
Collaborator

Uh… not supposed to fail multiple times like that, especially for a simple change like this.

Copy link
Collaborator

@ulysses4ever ulysses4ever left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@ulysses4ever ulysses4ever added the merge me Tell Mergify Bot to merge label Dec 13, 2024
@mergify mergify bot added the ready and waiting Mergify is waiting out the cooldown period label Dec 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
merge me Tell Mergify Bot to merge ready and waiting Mergify is waiting out the cooldown period
Projects
None yet
Development

Successfully merging this pull request may close these issues.

haddock-project --css does not properly apply the stylesheet in multi-package projects
3 participants