Skip to content

Improve documentation of SetupHooks#11771

Open
sheaf wants to merge 1 commit intomasterfrom
doc-hooks
Open

Improve documentation of SetupHooks#11771
sheaf wants to merge 1 commit intomasterfrom
doc-hooks

Conversation

@sheaf
Copy link
Copy Markdown
Collaborator

@sheaf sheaf commented Apr 29, 2026

Changes:

  • Add an usage overview that explains what the various hooks may be useful for.
  • Add a worked example for dynamicRule as it is the most complex aspect of the API.
  • Unexpose the gnarly RuleCommands constructors, advising usage of staticRule and dynamicRule instead.
  • Various small tweaks, including additional haddock comments for dynamicRule.

Template Α: This PR modifies behaviour or interface

@sheaf
Copy link
Copy Markdown
Collaborator Author

sheaf commented Apr 30, 2026

I've added a new "how to use SetupHooks" guide entry now.

Copy link
Copy Markdown
Member

@Mikolaj Mikolaj left a comment

Choose a reason for hiding this comment

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

I totally approve!

Adds a how-to guide in the Cabal's user guide.

Changes to the SetupHooks module and Haddocks:

  - Add an usage overview that explains what the various hooks may
    be useful for.
  - Add a worked example for 'dynamicRule' as it is the most complex
    aspect of the API.
  - Unexpose the gnarly 'RuleCommands' constructors, advising usage of
    'staticRule' and 'dynamicRule' instead.
  - Various small tweaks, including additional haddock comments for
    'dynamicRule'.

Fixes #11461
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants