Describe the feature or problem you’d like to solve
I need to manage my organization secrets and I want to update the selected repositories.
Kind of how it's done with the dedicated REST API:
https://docs.github.com/en/rest/actions/secrets?apiVersion=2022-11-28#set-selected-repositories-for-an-organization-secret (but with repository names instead of IDs)
At the moment when skipping --body
gh secret set MY_SECRET --org my-org --visibility selected --repos repo1,repo2
it read from reads from standard input:
Proposed solution
How will it benefit CLI and its users?
We can add an extra tag that tells the CLI not to touch the previous secret value at all:
gh secret set MY_SECRET --org my-org --keep-previous-body --visibility selected --repos repo1,repo2
Not sure about the -keep-previous-body tag name.
But for sure I think it will be cumbersome to add an extra gh secret command for that.
Additional context
May be related to:
Describe the feature or problem you’d like to solve
I need to manage my organization secrets and I want to update the selected repositories.
Kind of how it's done with the dedicated REST API:
https://docs.github.com/en/rest/actions/secrets?apiVersion=2022-11-28#set-selected-repositories-for-an-organization-secret (but with repository names instead of IDs)
At the moment when skipping
--bodygh secret set MY_SECRET --org my-org --visibility selected --repos repo1,repo2it read from reads from standard input:
Proposed solution
How will it benefit CLI and its users?
We can add an extra tag that tells the CLI not to touch the previous secret value at all:
gh secret set MY_SECRET --org my-org --keep-previous-body --visibility selected --repos repo1,repo2Not sure about the
-keep-previous-bodytag name.But for sure I think it will be cumbersome to add an extra
gh secretcommand for that.Additional context
May be related to:
secret update#6327