-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
[clap_mangen] possible values not shown in generated man page #3861
Comments
Huh, we have #3360 for improving possible values but not an issue for tracking showing them in the first place. |
epage
added
E-easy
Call for participation: Experience needed to fix: Easy / not much
A-man
Area: man generator
labels
Jun 22, 2022
I wouldn't mind working on this if it's not being handled already |
Go for it! |
Calder-Ty
added a commit
to Calder-Ty/clap
that referenced
this issue
Aug 16, 2022
This adds feature parity for mangen with the standard help output. Users will now see the list of possible values for value arguments. One change that was made to make this possible was adding the method `get_possible_values` to the public API for an arg. I tried to think of a way to get around this, but because this is the interface that the help generation uses, and it is part of the crate public interface I thing adding it as a part of the public API might be for the best. fixes: clap-rs#3861
Calder-Ty
added a commit
to Calder-Ty/clap
that referenced
this issue
Aug 16, 2022
This adds feature parity for mangen with the standard help output. Users will now see the list of possible values for value arguments. One change that was made to make this possible was adding the method `get_possible_values` to the public API for an arg. I tried to think of a way to get around this, but because this is the interface that the help generation uses, and it is part of the crate public interface I thing adding it as a part of the public API might be for the best. fixes: clap-rs#3861
Calder-Ty
added a commit
to Calder-Ty/clap
that referenced
this issue
Aug 16, 2022
This adds feature parity for mangen with the standard help output. Users will now see the list of possible values for value arguments. One change that was made to make this possible was adding the method `get_possible_values` to the public API for an arg. I tried to think of a way to get around this, but because this is the interface that the help generation uses, and it is part of the crate public interface I thing adding it as a part of the public API might be for the best. fixes: clap-rs#3861
Calder-Ty
added a commit
to Calder-Ty/clap
that referenced
this issue
Aug 20, 2022
This adds feature parity for mangen with the standard help output. Users will now see the list of possible values for value arguments. One change that was made to make this possible was adding the method `get_possible_values` to the public API for an arg. I tried to think of a way to get around this, but because this is the interface that the help generation uses, and it is part of the crate public interface I thing adding it as a part of the public API might be for the best. fixes: clap-rs#3861
Calder-Ty
added a commit
to Calder-Ty/clap
that referenced
this issue
Aug 24, 2022
This adds feature parity for mangen with the standard help output. Users will now see the list of possible values for value arguments. One change that was made to make this possible was adding the method `get_possible_values` to the public API for an arg. I tried to think of a way to get around this, but because this is the interface that the help generation uses, and it is part of the crate public interface I thing adding it as a part of the public API might be for the best. fixes: clap-rs#3861
Calder-Ty
added a commit
to Calder-Ty/clap
that referenced
this issue
Aug 30, 2022
This adds feature parity for mangen with the standard help output. Users will now see the list of possible values for value arguments. One change that was made to make this possible was adding the method `get_possible_values` to the public API for an arg. I tried to think of a way to get around this, but because this is the interface that the help generation uses, and it is part of the crate public interface I thing adding it as a part of the public API might be for the best. cherry-pick to backport this fix to v3 fixes: clap-rs#3861
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Please complete the following tasks
Rust Version
rustc 1.61.0 (fe5b13d68 2022-05-18)
Clap Version
3.2.6
Minimal reproducible code
Steps to reproduce the bug with the above code
clap = { version = "3.2.6", features = ["derive"] }
andclap_mangen = "0.1.9"
toCargo.toml
cargo run | man -P cat -l -
Actual Behaviour
The above example prints both the normal help message generated by
clap
and the man page generated byclap_mangen
(example output is provided below). The man page does not mention the possible values (true
andfalse
) anywhere. The same is true for enums.Expected Behaviour
The man page should mention the possible values just like the help message does (
[possible values: true, false]
).Additional Context
Output of above example:
Debug Output
The text was updated successfully, but these errors were encountered: