Skip to content

feat: emit branch-protection.json from manifest #5

@joshua-temple

Description

@joshua-temple

Problem

Required-check names on protected branches are derived from generated callback job IDs (validate, build_<name>, deploy_<name>, etc.). Adopters guess at the exact names and apply via gh api manually, with rules drifting from generator output over time as callbacks rename or restructure.

Proposed

Add cascade generate branch-protection --env <env> (or similar) that emits a JSON payload suitable for:

gh api -X PUT repos/<repo>/branches/<branch>/protection --input -

Payload includes required-check names sourced directly from the generator's job IDs, with sensible defaults for review counts / linear history / signed commits etc.

Impact

Removes the "what's the check name today?" guess. Protection rules stay in sync with generator output across upgrades. Additive, zero schema risk — lands post-1.0.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions