stackabletech / stackabletech/stackable-utils
Add tool to manage branch protection rules across many repositories
Nobody has claimed this yet.
- Dominant language
- Shell
- Stars
- 2
- Forks
- 1
- PR merge metrics
- No merged PRs in 30d
Description
We currently have a branch protection rule in place that protects "release-*" branches in our repositories.
This has drawbacks:
- it will cause release scripts to fail because the newly created release branches cannot be pushed to by the script
- prs on these branches cannot use the merge queue (not possible with wildcards in the branch name)
It might be worth switching to individual protection rules for every release, but that would make them hard to change/administer.
The github api allows managing these rules: https://docs.github.com/en/rest/branches/branch-protection?apiVersion=2022-11-28
We should look into writing a simple python script that takes a list of repos and release names and updates these protection rules.
Contributor guide
No contributing guide indexed for this repository
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 with the GitHub branch protection REST API linked in the issue and determine how protection rules can be managed for multiple repositories. Define the script inputs as repository and release-name lists; done means the rules can be updated centrally without relying on the release-* wildcard, so release pushes and merge queues work.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- github, python
- Domain
- devops, release
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100