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

Move CLI common options into dune --help page #11436

Open
yawaramin opened this issue Feb 3, 2025 · 2 comments
Open

Move CLI common options into dune --help page #11436

yawaramin opened this issue Feb 3, 2025 · 2 comments
Labels
cli Command line related

Comments

@yawaramin
Copy link
Contributor

Currently in dune --help, the 'Common Options' section lists only two options: --help and --version. And the help pages for subcommands like dune build --help etc. also have a 'Common Options' section where they list all the other common options.

The common options should be moved from the individual subcommand help pages, into the dune --help page, and replaced with a reference to the latter page.

@maiste maiste added the cli Command line related label Feb 3, 2025
@maiste
Copy link
Collaborator

maiste commented Feb 3, 2025

Thanks for your comment. I can't speak for other people usages, but it seems more intuitive to have the options you can use with the command you run in the same help page than having to run --help to have access to both. Maybe I'm missing your point here?

On a side note, we are discussing internally ways to improve the Dune CLI in the future 👍

@yawaramin
Copy link
Contributor Author

It's arguable whether the dune SUBCOMMAND --help should show the common options or just point to dune --help which should document those.

But at the very least the common options should be shown in both dune --help as well as in dune SUBCOMMAND --help. Because (and different people will have different opinions here but) some people will definitely go to dune --help to look for the common options. They won't think to look in the help manual for a specific subcommand. I know this is true because I just spoke to someone last night in the OCaml Discord who did exactly this.

As another example, we can see that the opam help pages show common options in both opam --help and in opam SUBCOMMAND --help. So we can just point to the precedent set there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cli Command line related
Projects
None yet
Development

No branches or pull requests

2 participants