Skip to content

ci: manage repository rulesets as code - #1371

Closed
MrCroxx wants to merge 2 commits into
mainfrom
codex/rulesets-as-code
Closed

MrCroxx wants to merge 2 commits into
mainfrom
codex/rulesets-as-code

Conversation

@MrCroxx

@MrCroxx MrCroxx commented Oct 8, 2026 •

Copy link
Copy Markdown
Member

Manage the existing repository ruleset through versioned JSON and a GitHub Actions pipeline. The imported configuration preserves the current live ruleset, including the Rust 1.95.0 required checks, so initial reconciliation is a no-op.

Pull requests validate the configuration and preview changes using a read-only token. After merge, the workflow reconciles the latest main configuration using RULESETS_TOKEN from the main-only rulesets environment. Manual dispatch defaults to dry-run. Updates target explicit existing ruleset IDs, detect edits during planning, skip unchanged rulesets, and verify writes by reading back the configuration; no rulesets are created or deleted.

Validation: eight synchronizer tests and actionlint passed locally. The Rulesets workflow also passed on this PR; its read-only preview reported no visible differences, and the privileged sync job was skipped as intended. RULESETS_TOKEN is configured only in the main-only rulesets environment. Administrative authentication and reconciliation remain to be verified after merge; because the imported configuration matches GitHub, the initial sync is expected to perform no writes.

Signed-off-by: MrCroxx <mrcroxx.cs@gmail.com>
@MrCroxx
MrCroxx marked this pull request as ready for review October 8, 2026 07:59
@codecov

codecov Bot commented Oct 8, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
see 3 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

1 participant