Repository navigation
feat(pr-management): add the shepherd skill for a maintainer's own open PRs - #2109
Merged
Merged
Conversation
…en PRs `pr-management-shepherd` gets the viewer's open PRs to a mergeable state and keeps the default branch green: it re-runs CI jobs cancelled at their time limit, fixes real failures and code-scanning notes on the branch, rebases stale branches behind a whole-tree pre-push gate, repairs a red default branch, and hands everyone else's PRs to `pr-management-code-review`. Every push, rerun, post and auto-merge is a proposal; it never merges. Step 3 decides one action per PR from a fixed table; its eval suite covers a timeout, a lint failure in a changed file, an open CodeQL note, a failure only in untouched files, an all-green PR without auto-merge, and an injection attempt in a review comment. It reads a failed job's step list rather than its whole log, which keeps the timeout check to a few hundred tokens. Generated-by: Claude Opus 5 Claude-Session: https://claude.ai/code/session_01NyQq9UgHu7T8a8DfcfyP2M
Generated-by: Claude Opus 5 Claude-Session: https://claude.ai/code/session_01NyQq9UgHu7T8a8DfcfyP2M
potiuk
enabled auto-merge (squash)
November 15, 2026 15:04
2 tasks done
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
pr-management-shepherd: gets the maintainer's own open PRs to a mergeable state and keeps the default branch green. Step 3 picks one action per PR from a fixed table: rebase, rerun a job cancelled at its time limit, fix a failure in a changed file, fix a red default branch, fix an open code-scanning or reviewer comment, wait, or enable auto-merge. Everyone else's PRs go topr-management-code-review.merge-candidates/why-not-merge.md). It printsgh pr mergefor an approvedCLEANPR, and enables auto-merge only on confirmation. Force pushes carry a lease on the SHA last pushed; a contributor's branch is pushed to only when the maintainer asks andmaintainerCanModifyis true.Written with
write-skilland passed throughoptimize-skill. The body is about 2,000 tokens excluding pre-flight, and description + when_to_use about 130.Type of change
Test plan
tools/skill-evals/evals/pr-management-shepherd/: 6/6 passed (two live runs, journaled).skill-and-tool-validate: no violations, no warnings for the new skill.prek run --all-files --skip workspace-pytest --skip lychee, then the tests for changed members: passed.Linked issues
None.
Generative AI disclosure: prepared with Claude Code (Opus 5).
🤖 Generated with Claude Code