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

GenericCLI: Support for multiple positional arguments #155

Merged
merged 11 commits into from
Sep 26, 2024

Conversation

Gerrit91
Copy link
Contributor

@Gerrit91 Gerrit91 commented Sep 18, 2024

Currently we can only generate commands like describe <id>. However, some APIs have compound keys for IDs, e.g. for size reservations it's useful to have describe <project> <size>, which makes a unique identifier for this API.

This was implemented as non-breaking. If you have multiple positional arguments to pass, you can now do so by using MultiArgGenericCLI.

Internally, the entire old implementation with the single positional argument interface is mapped to the new multi argument interface to reduce code redundancy and maintain test-ability of this package.

  • Update metalctl and check if tests still pass and no breaking changes occur

@Gerrit91 Gerrit91 changed the title GenericCLI: Support for multiple ID arguments GenericCLI: Support for multiple positional arguments Sep 19, 2024
@Gerrit91 Gerrit91 marked this pull request as ready for review September 19, 2024 07:25
@Gerrit91 Gerrit91 requested a review from a team as a code owner September 19, 2024 07:25
@Gerrit91 Gerrit91 merged commit 25397a6 into master Sep 26, 2024
2 checks passed
@Gerrit91 Gerrit91 deleted the multiple-id-args branch September 26, 2024 11:36
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.

2 participants