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

vendor: github.com/spf13/cobra v1.8.0 #2215

Merged
merged 1 commit into from
Jan 31, 2024

Conversation

thaJeztah
Copy link
Member

Release notes highlights:

Features

  • Support usage as plugin for tools like kubectl - this means that programs that utilize a "plugin-like" structure have much better support and usage (like for completions, command paths, etc.)
  • Move documentation sources to site/content
  • Add 'one required flag' group - this includes a new MarkFlagsOneRequired API for flags which can be used to mark a flag group as required and cause command failure if at least one is not used when invoked.
  • Customizable error message prefix - This adds the SetErrPrefix and ErrPrefix APIs on the Command struct to allow for setting a custom prefix for errors
  • feat: add getters for flag completions
  • Feature: allow running persistent run hooks of all parents
  • Improve API to get flag completion function

Bug fixes

  • Fix typo in fish completions
  • Fix grammar: 'allows to'
  • powershell: escape variable with curly brackets
  • Don't complete --help flag when flag parsing disabled
  • Replace all non-alphanumerics in active help env var program prefix

- release notes: https://github.com/spf13/cobra/releases/tag/v1.8.0
- full diff: spf13/cobra@v1.7.0...v1.8.0

Release notes highlights:

Features

- Support usage as plugin for tools like kubectl - this means that programs
  that utilize a "plugin-like" structure have much better support and usage
  (like for completions, command paths, etc.)
- Move documentation sources to site/content
- Add 'one required flag' group - this includes a new MarkFlagsOneRequired API
  for flags which can be used to mark a flag group as required and cause command
  failure if at least one is not used when invoked.
- Customizable error message prefix - This adds the SetErrPrefix and ErrPrefix
  APIs on the Command struct to allow for setting a custom prefix for errors
- feat: add getters for flag completions
- Feature: allow running persistent run hooks of all parents
- Improve API to get flag completion function

Bug fixes

- Fix typo in fish completions
- Fix grammar: 'allows to'
- powershell: escape variable with curly brackets
- Don't complete --help flag when flag parsing disabled
- Replace all non-alphanumerics in active help env var program prefix

Signed-off-by: Sebastiaan van Stijn <[email protected]>
@thaJeztah thaJeztah self-assigned this Jan 26, 2024
@crazy-max
Copy link
Member

Ah they finally moved docs to a subdir!

image

@thaJeztah
Copy link
Member Author

Yes, they did!

We should also have a look at the "plugin" changes they added (if we can use those), the SetErrPrefix feature, and this one sounds potentially interesting also for our plug-ins use-case;

Feature: allow running persistent run hooks of all parents

@crazy-max
Copy link
Member

crazy-max commented Jan 26, 2024

Yes, they did!

We should also have a look at the "plugin" changes they added (if we can use those), the SetErrPrefix feature, and this one sounds potentially interesting also for our plug-ins use-case;

Feature: allow running persistent run hooks of all parents

Yeah we also need some client-side integration tests, not just on linux but also macos/windows to make sure there is no regression as follow-up of #2206

@tonistiigi tonistiigi merged commit 8babd5a into docker:master Jan 31, 2024
63 checks passed
@thaJeztah thaJeztah deleted the bump_cobra_1.8 branch January 31, 2024 03:00
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.

3 participants