You are the only maintainer, but the rule requires one approval. How do you work?
IntermediateScenarioProtection, Hooks and Policy
Answer
Situation read → A strict rule locks out a team of one.
What I'd do →
- Keep required checks and linear history; they still protect you.
- Set required approvals to 0 for a personal repo, or add a second trusted reviewer.
- If you need review for compliance, add an admin bypass restricted to PRs only.
- Use a bot or self-review checklist in the PR template.
Why → Control should match risk. A rule nobody can meet becomes a bypass habit.
Interview tip → GitHub does not let authors approve their own PRs.
More on Protection, Hooks and Policy
You are asked to protect `main`. Which rules do you turn on?BeginnerClassic branch protection or repository rulesets: which do you use?IntermediateA required status check never reports and the PR is stuck as "Expected — Waiting for status".IntermediateProduction is down and the fix needs to merge now, but approvals are required.IntermediateYou want to stop developers from committing obvious mistakes like debug prints, trailing whitespace or secrets.BeginnerHooks in `.git/hooks` are not shared with the team. How do you distribute them?Intermediate