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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add the possibility to handle all positional arguments together #3595

Open
Mia-Cross opened this issue Jan 12, 2024 · 0 comments
Open

Add the possibility to handle all positional arguments together #3595

Mia-Cross opened this issue Jan 12, 2024 · 0 comments
Assignees
Labels
core enhancement priority:medium Improvements that are not the main priority

Comments

@Mia-Cross
Copy link
Contributor

Community Note

  • Please vote on this issue by adding a 馃憤 reaction to the original issue to help the community and maintainers prioritize this request
  • Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for issue followers and do not help prioritize the request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment

Description

As of today, if a command has several positional arguments, the CLI will separate them and run the command as many times as there are positional arguments, each time with one of the arguments. For example :

scw rdb acl add 1.2.3.4 1.1.1.1 instance-id=xxxxx-xxx-xxx-xxxxxx

is actually done in 2 steps :

(1) scw rdb acl add 1.2.3.4 instance-id=xxxxx-xxx-xxx-xxxxxx
(2) scw rdb acl add 1.1.1.1 instance-id=xxxxx-xxx-xxx-xxxxxx

This can be problematic for verbs such as set because every run will overwrite the previous one.

How I imagine scw could expose this functionality

By modifying the code around here, we should be able to introduce specific behaviors for set verbs, so that :

scw rdb acl set 1.2.3.4 1.1.1.1 instance-id=xxxxx-xxx-xxx-xxxxxx

sets all positional arguments in the same run.

References

@Mia-Cross Mia-Cross self-assigned this Jan 12, 2024
@Mia-Cross Mia-Cross added the core label Jan 12, 2024
@remyleone remyleone added the priority:medium Improvements that are not the main priority label Jan 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
core enhancement priority:medium Improvements that are not the main priority
Projects
None yet
Development

No branches or pull requests

2 participants