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

Upgrade clap to 3.2.5 #161

Closed
wants to merge 2 commits into from
Closed

Upgrade clap to 3.2.5 #161

wants to merge 2 commits into from

Conversation

steveklabnik
Copy link
Contributor

Clap 3.2 is the last release before 4.0:
https://epage.github.io/blog/2022/06/clap-32-last-call-before-40/

These changes upgrade our usage of features that are being deprecated,
insuring that we shall have an easy upgrade path to 4.0.

The two biggest changes:

  1. removing NoAutoVersion.
  2. changing our usage of parse_int::parse to the new value_parser API

Big thanks to @epage for helping out with 2:
clap-rs/clap#3839

And for working through some error messages:
clap-rs/clap#3822

As for NoAutoVersion, opting into the new behavior via action does
what we want, except that the output for doing it with another
incorrect flag doesn't give the error about how that's incorrect. I
suspect that this is an acceptable change in behavior, but worth calling
out. You can see the difference in the chip.trycmd tests.

Clap 3.2 is the last release before 4.0:
https://epage.github.io/blog/2022/06/clap-32-last-call-before-40/

These changes upgrade our usage of features that are being deprecated,
insuring that we shall have an easy upgrade path to 4.0.

The two biggest changes:

1. removing NoAutoVersion.
2. changing our usage of parse_int::parse to the new value_parser API

Big thanks to @epage for helping out with 2:
clap-rs/clap#3839

And for working through some error messages:
clap-rs/clap#3822

As for NoAutoVersion, opting into the new behavior via `action` does
what we want, *except* that the output for doing it with another
incorrect flag doesn't give the error about how that's incorrect. I
suspect that this is an acceptable change in behavior, but worth calling
out. You can see the difference in the chip.trycmd tests.
src/main.rs Outdated Show resolved Hide resolved
epage added a commit to epage/clap that referenced this pull request Jun 16, 2022
This was an oversight when listing out the options as identified when
looking at oxidecomputer/humility#161.
@steveklabnik
Copy link
Contributor Author

This is so out of date that if I pursue this again in the future I'll have to re-do it from scratch anyway, closing.

@steveklabnik steveklabnik deleted the upgrade-clap branch April 21, 2023 15:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants