Protect main with a ruleset: require CI and drift-check, block force-push

Aperta
#218 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
3/5
Tempo stimato
1-2 giorni
Idoneità per principianti
48/100
Tipo di issue
Funzionalità
Chiarezza
Specificata chiaramente
Stato di attività
Attiva
Stack tecnologico
github
Ambito
ci-cd

Direzione di ricerca

Read the repository’s current protection and ruleset state using the main protection and /rulesets endpoints, then identify the CI matrix and drift-check status checks. Configure the main ruleset with the requested pull request, status-check, force-push, and deletion restrictions, retaining the admin bypass; done when failing-CI PRs cannot merge and direct pushes are rejected.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

ci effort: small impact: medium priority: medium release

Why it matters

Every merge to main triggers release.yml, which tags and publishes to npm and the MCP Registry. main has no protection, so a direct push or a merge with red CI ships to users. #190 covers the release workflow not waiting for CI, and #191 covers action hardening; neither covers repository rules.

Evidence

  • gh api repos/TMHSDigital/screencast-mcp/branches/main/protection returns 404 (not protected).
  • /rulesets is empty.

Suggested approach

Add a ruleset on main:

  • require pull requests
  • require the CI matrix (Ubuntu and Windows) and drift-check to pass
  • block force-pushes and deletion
  • optionally require linear history

Allow an admin bypass for emergencies.

Done when

  • A PR with failing CI cannot be merged.
  • A direct push to main is rejected.
Lingua principale
TypeScript
Stelle
1
Fork
4
Merge medio
14h 8m
PR unite (30g)
48

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di TMHSDigital/screencast-mcp

Tutte le issue di TMHSDigital/screencast-mcp

Issue simili

Altre issue su TypeScript

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.