Skip to content

Improve "Protect version branches" ruleset#529

Merged
llucax merged 9 commits intofrequenz-floss:v0.x.xfrom
llucax:migrate-rules
Mar 4, 2026
Merged

Improve "Protect version branches" ruleset#529
llucax merged 9 commits intofrequenz-floss:v0.x.xfrom
llucax:migrate-rules

Conversation

@llucax
Copy link
Contributor

@llucax llucax commented Mar 4, 2026

This PR updates the Protect version branches ruleset policy: disables mandatory code-owner review, removes automatic Copilot review, and requires the Migrate Repo Config status check (plus other minor maintainance changes).

It also adds a migration step that detects/applies those ruleset updates. It also introduces reusable GitHub ruleset API helpers in the migration template so future ruleset migrations can be implemented consistently without duplicating low-level gh api plumbing.

Fixes #470 and #471.

llucax added 5 commits March 4, 2026 09:28
Copilot review now uses scarse premium requests, and this will be taken
from the person creating the PR without them having a saying on how
their premium requests are used, so we change to manual review requests.

Signed-off-by: Leandro Lucarella <luca-frequenz@llucax.com>
It seems like GitHub changed this ID.

Signed-off-by: Leandro Lucarella <luca-frequenz@llucax.com>
Signed-off-by: Leandro Lucarella <luca-frequenz@llucax.com>
Code owners are good to request automatic review, but in practice it
prevented some people with write access to approve PRs, which can be
annoying. This is also necessary for the auto-dependabot and
repo-config-migrate workflows to be able to approve and merge PRs
automatically.

Signed-off-by: Leandro Lucarella <luca-frequenz@llucax.com>
We want to make sure that merges are blocked if the repo config
migration failed/requires manual intervention.

Signed-off-by: Leandro Lucarella <luca-frequenz@llucax.com>
@llucax llucax requested a review from a team as a code owner March 4, 2026 11:20
@llucax llucax requested review from florian-wagner-frequenz and removed request for a team March 4, 2026 11:20
@github-actions github-actions bot added part:docs Affects the documentation part:cookiecutter Affects the generation of projects using cookiecutter labels Mar 4, 2026
@llucax llucax self-assigned this Mar 4, 2026
@llucax llucax added this to the v0.15.0 milestone Mar 4, 2026
llucax added 4 commits March 4, 2026 12:50
It is OK for the migration script to be long.

Signed-off-by: Leandro Lucarella <luca-frequenz@llucax.com>
Add a migration step that updates the "Protect version branches" GitHub
ruleset from migrate.py.

Signed-off-by: Leandro Lucarella <luca-frequenz@llucax.com>
Copy the reusable GitHub ruleset helper functions to the migration
script template so future migration steps can query and update rulesets
without duplicating API plumbing.

Signed-off-by: Leandro Lucarella <luca-frequenz@llucax.com>
Signed-off-by: Leandro Lucarella <luca-frequenz@llucax.com>
@llucax llucax enabled auto-merge March 4, 2026 12:15
@llucax llucax requested a review from Marenz March 4, 2026 12:15
@llucax llucax added this pull request to the merge queue Mar 4, 2026
Merged via the queue into frequenz-floss:v0.x.x with commit 06b21cc Mar 4, 2026
6 checks passed
@llucax llucax deleted the migrate-rules branch March 4, 2026 17:16
@llucax llucax linked an issue Mar 5, 2026 that may be closed by this pull request
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

part:cookiecutter Affects the generation of projects using cookiecutter part:docs Affects the documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[protection rules] Don't require approval from a code owner [protection rules] Disable automatic Copilot reviews

2 participants