-
Notifications
You must be signed in to change notification settings - Fork 778
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
Implement uv help
manually instead of using Clap default
#4906
Conversation
bd5670c
to
0344631
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Found a way to make it panic, but i do like the more concise help a lot.
$ cargo run -q -- help pip install
thread 'main' panicked at /home/konsti/.cargo/registry/src/index.crates.io-6f17d22bba15001f/clap_builder-4.5.8/src/builder/debug_asserts.rs:214:13:
Command install: Argument or group 'offline' specified in 'conflicts_with*' for 'refresh' does not exist
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
I feel like I'm always drowning in the help output from `uv` because we have so many options. I basically agree with the commentary in clap-rs/clap#4687 that having different behaviors for `-h` and `--help` is surprising. I think `--help` is more obvious for users and I want to optimize for that experience. This roughly matches the help menus in Cargo and pip. The `uv help` command can be used for long help. In #4906 and #4909 we improve that command. Extends #4904 which adds test cases for the existing behavior.
Fixed the panic :) |
Should these be different?
|
Yes they should be different but we should be displaying the long-form documentation for all those options in the second invocation. Will investigate that... |
Ah I pushed a fix to #4909 but not here by accident. |
Extends #4906 Adds paged display of "long' help to `uv help` invocations when `less` or `more` is available.
Extends #4772
Implements
uv help
ourselves so we can do things like #4909Adds hints to use
uv help
for more details during short help display.