'st2 <thing> delete' should accept multiple positional args for removal
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 6.5k
- Forks
- 787
- PR merge metrics
- No merged PRs in 30d
Description
Initially comes from a release testing when specific testing pack installs 100+ action aliases and we have no way to delete them in a bulky way.
The following construct fails because st2 action-alias delete can only accept single positional arg as id:
st2 action-alias delete pack.alias1 pack.alias2
Better example that ideally should work:
st2 action-alias delete $(st2 action-alias list -p chatops_tests -a id | awk '{print $2}')
The general CLI improvement here and helpful from user's perspective would be allowing multiple IDs for removal.
From what I remember, only st2 pack delete 1 2 3 4 5 only works this way.
Affected CLI:
st2 action delete
st2 action-alias delete
st2 key delete
st2 policy delete
...
and so on
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at the CLI entry points for st2 action delete, st2 action-alias delete, st2 key delete, st2 policy delete, and the existing st2 pack delete behavior. Compare how positional IDs are parsed and verify that each affected delete command accepts multiple IDs, including the bulk action-alias example.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- cli
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100