Skip to content

Add help target to the makefile - #10608

Merged
mergify[bot] merged 1 commit into
haskell:masterfrom
cabalism:doc/makefile-10596
Dec 4, 2024
Merged

Add help target to the makefile#10608
mergify[bot] merged 1 commit into
haskell:masterfrom
cabalism:doc/makefile-10596

Conversation

@philderbeast

Copy link
Copy Markdown
Collaborator

Fix#10596. Add help for some of the makefile targets.

$ make help
all Build the Cabal libraries and cabal-install executables.
checks Run all local checks; whitespace, style, and lint.
doctest-install Install doctest tool needed for running doctests.
doctest Run doctests.
exe Builds the cabal-install executables.
fix-whitespace Run fix-whitespace in fix mode.
ghcid-cli Run ghcid for the cabal-install executable.
ghcid-lib Run ghcid for the Cabal library.
help-banner Show the help banner.
help Show the commented targets.
init Set up git hooks and ignored revisions.
lib Builds the Cabal libraries.
lint-json Run HLint in JSON mode.
lint Run HLint.
style-commit Run the code styler on the previous commit.
style-modified Run the code styler on modified files.
style Run the code styler.
tags Generate editor tags, vim ctags and emacs etags.
users-guide Build the users guide.
users-guide-requirements Install the requirements for building the users guide.
whitespace Run fix-whitespace in check mode.

Template B: This PR does not modify behaviour or interface

E.g. the PR only touches documentation or tests, does refactorings, etc.

Include the following checklist in your PR:

  • Patches conform to the coding conventions.
  • Is this a PR that fixes CI? If so, it will need to be backported to older cabal release branches (ask maintainers for directions).

Comment threadMakefile Outdated
@philderbeast

Copy link
Copy Markdown
CollaboratorAuthor

Label merge+no rebase is necessary when the pull request is from an organisation.

@mergifymergifyBot added the ready and waiting Mergify is waiting out the cooldown period label Nov 29, 2024
- Add comments for users-guide* targets
- Comment tags target
- Add comment for checks
- Comment doctesting and ghcid
- Add help-banner target
- Add comments to all, lib and exe targets
- Add full stops to the help comments
- Manual fix-whitespace
@philderbeast

philderbeast commented Dec 2, 2024

Copy link
Copy Markdown
CollaboratorAuthor

The help after #10603 was merged to master.

Tip

Should we switch from prefix/infix to suffix for fix, from -fix-* to *-fix, for the fixing targets?

@geekosaur, you chose the prefix name for fix-whitespace in 2858dc0 and that matches the tool name. On the other hand the lexical grouping works better with a suffix.

$ make help
all Build the Cabal libraries and cabal-install executables.
checks Run all local checks; whitespace, typos, style, and lint.
doctest-install Install doctest tool needed for running doctests.
doctest Run doctests.
exe Builds the cabal-install executables.
- fix-whitespace Run fix-whitespace in fix mode.
ghcid-cli Run ghcid for the cabal-install executable.
ghcid-lib Run ghcid for the Cabal library.
help-banner Show the help banner.
help Show the commented targets.
init Set up git hooks and ignored revisions.
lib Builds the Cabal libraries.
lint-json Run HLint in JSON mode.
lint Run HLint.
- markdown-fix-typos Fix typos in markdown files
markdown-typos Find typos in markdown files
+ markdown-typos-fix Fix typos in markdown files
style-commit Run the code styler on the previous commit.
style-modified Run the code styler on modified files.
style Run the code styler.
tags Generate editor tags, vim ctags and emacs etags.
typos-install Install typos-cli for typos target using cargo
users-guide Build the users guide.
- users-guide-fix-typos Fix typos in users guide
users-guide-requirements Install the requirements for building the users guide.
users-guide-typos Find typos in users guide
+ users-guide-typos-fix Fix typos in users guide
whitespace Run fix-whitespace in check mode.
+ whitespace-fix Run fix-whitespace in fix mode. 

@geekosaur

Copy link
Copy Markdown
Collaborator

There's also DevX vs. what makes the help text look better.

@philderbeast

philderbeast commented Dec 2, 2024

Copy link
Copy Markdown
CollaboratorAuthor

One thing I hadn't noted earlier is the number of groups with a common prefix that we have already:

  • doctestdoctest + doctest-install
  • ghcidghcid-cli + ghcid-lib
  • lintlint + lint-json
  • stylestyle + style-commit + style-modified
  • users-guideusers-guide + users-guide-requirements

We have could have common suffixes too; -install, -check and -fix.

@mergifymergifyBot added the merge delay passed Applied (usually by Mergify) when PR approved and received no updates for 2 days label Dec 4, 2024
@mergify
mergifyBot merged commit daa6ffa into haskell:masterDec 4, 2024
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

merge delay passedApplied (usually by Mergify) when PR approved and received no updates for 2 daysmerge+no rebaseready and waitingMergify is waiting out the cooldown period

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Self-document the makefile

3 participants

@philderbeast@geekosaur@ffaf1