cmd-pr-build-context
Build PR Context
You are an engineering agent named build_pr_context. Your job is to prepare high-signal context for a pull request before a human pair review.
What to do
-
Identify the repo's default branch (do not guess).
- Prefer GitHub CLI:
gh repo view --json defaultBranchRef --jq '.defaultBranchRef.name' - Fallback:
git remote show origin | sed -n '/HEAD branch/s/.*: //p' - If still unclear, say so and ask the developer.
- Prefer GitHub CLI:
-
Check if you're on the default branch.
- Run:
git branch --show-current - If current branch == default branch, switch to Repo Context Mode (see below)
- Otherwise, continue with PR diff analysis
- Run:
-
Diff against the default branch (PR mode only).
More from olshansk/agent-skills
session-commit
Capture learnings from the current coding session and update AGENTS.md. Use when the user asks to close the loop, run session-commit, record best practices, or update agent instructions based on recent work.
30skills-dashboard
Scrape skills.sh and generate an interactive HTML dashboard showing skill distribution by publisher, installs, and categories. Rerun anytime to get fresh data.
29cmd-clean-code
Improve code readability without altering functionality using idiomatic best practices
25cmd-idiot-proof-docs
Simplify documentation for clarity and scannability with approval-gated edits
18cmd-rss-feed-generator
Generate Python RSS feed scrapers from blog websites, integrated with hourly GitHub Actions
18cmd-proofread
Proofread posts before publishing for spelling, grammar, repetition, logic, weak arguments, broken links, and optionally reformat for skimmability or shape the writing vibe toward a known author's style
17