plugins/open-pr/skills/open-pr/SKILL.md
Use when wrapping up a development task and getting a PR ready — runs local tests, creates a PR (if one doesn't exist) with a structured description template, conducts a code review via the review skill, and checks CI status with quick fixes. Trigger when the user says they're done with a feature, want to open a PR, wrap up, finalize their work, or push their branch for review. Also invoke proactively after completing all tasks in an implementation plan. Does NOT merge — suggests /merge-pr when the PR is ready to land.
npx skillsauth add harnessprotocol/harness-kit open-prInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
A structured PR preparation workflow: tests → create PR → code review → CI → hand off to merge.
Announce at start: "I'm using the open-pr skill to get this PR ready."
Run the test suite before touching anything else. Detect the right command from project files:
| Indicator | Command |
|-----------|---------|
| CLAUDE.md test command | Use that (takes precedence over all below) |
| go.mod | go test ./... |
| package.json | npm test or yarn test |
| pyproject.toml / setup.py | pytest |
| Cargo.toml | cargo test |
If tests fail: Stop. Show the failures clearly. Don't proceed — fix them or ask the user how to handle. Do not skip or bypass test hooks.
If tests pass: Continue.
gh pr view --json number,url,state 2>/dev/null
git push -u origin $(git branch --show-current)
Use the most meaningful commit message as a starting point, cleaned up to be concise. Follow conventional commit format (feat:, fix:, refactor:, etc.) if the repo uses it — check recent commits with git log --oneline -10.
Infer labels from the branch name and commits — apply with --label if the label exists in the repo:
| Pattern | Label |
|---------|-------|
| fix/, bug/, "fix" in commits | bug |
| feat/, feature/ | enhancement |
| refactor/, chore/ | refactor |
| docs/ | documentation |
Skip labels that don't exist in the repo rather than erroring.
Fill in every section based on the actual changes — no unfilled placeholders:
## Summary
<!-- What this PR does and why — 2-4 sentences. Lead with intent, not implementation. -->
## Changes
<!-- Key changes. Be specific — not "updated code" but what and why. -->
-
## Test Plan
<!-- How this was verified -->
- [ ] Local tests pass
- [ ] CI checks pass
- [ ] <any manual or integration steps>
## Notes
<!-- Edge cases, follow-ups, known limitations, or anything a reviewer should know -->
gh pr create \
--title "<title>" \
--body "$(cat <<'EOF'
<filled-template>
EOF
)"
Leave --reviewer and --assignee unset.
Invoke the review skill (use the Skill tool) to review all changes in this PR.
The review should cover:
## Code Review, ## Standards, or ## Gotchas sections and incorporate those requirementsAfter the review, present a clear report:
Code Review Report
──────────────────
[MUST FIX] <issue> — <file>:<line>
[SUGGESTION] <issue>
No blocking issues found.
If MUST FIX items: Address them, commit, push. Once resolved, continue to Step 5.
If only suggestions: Note them for the user to follow up post-merge at their discretion.
gh pr checks
All passing: Continue.
Failing:
"CI is failing due to [X]. This needs a dedicated fix before merging — let's plan it out."
Never proceed to merge with failing CI.
Once tests, review, and CI are all green, report the PR status and suggest the next step:
PR #<N> is ready to merge.
──────────────────────────
Title: <title>
Branch: <branch> → <base>
URL: <url>
✓ Local tests pass
✓ Code review clean (or: N suggestions noted for follow-up)
✓ CI passing
Run /merge-pr to squash merge and clean up.
Do not merge, rebase, or push anything further. Hand off cleanly.
| Step | Action | Block on failure? |
|------|--------|-------------------|
| 1. Local tests | Run test suite | Yes — fix first |
| 2. PR check | Exists? | Skip to review |
| 3. Create PR | Push + gh pr create | — |
| 4. Code review | review skill | Yes for MUST FIX |
| 5. CI | gh pr checks | Yes — fix or stop |
| 6. Report | PR summary + /merge-pr suggestion | — |
Never:
--no-verify to bypass hooksAlways:
/merge-pr at the endtools
Harness Kit documentation — installation, plugin catalog, creating plugins, cross-harness setup, architecture, and FAQ. Use when working with or configuring harness-kit plugins, understanding the plugin/skill system, installing slash commands, setting up AI coding tool configuration, answering questions about the plugin marketplace, writing SKILL.md files, using harness.yaml, or integrating with Copilot, Cursor, or Codex. Do NOT use for general Claude Code questions unrelated to harness-kit.
development
Use when user invokes /stats or asks about Claude Code usage, token consumption, session history, model distribution, or activity patterns. Generates an interactive HTML dashboard with charts and tables, auto-opens in browser. Also triggers on "how much have I used Claude", "show my usage", "token usage", "session stats", "usage report", "usage dashboard". Do NOT use for API billing or cost estimation — token counts are not costs.
development
Use when user invokes /review to review code changes. Also triggers on "review my code", "check this PR", "look at my changes". Accepts a PR number (e.g. /review 123), a path filter (e.g. /review src/auth/), or no argument (reviews current branch vs base). Produces structured per-file review with severity labels, cross-file analysis, and an overall verdict. Do NOT use for explaining what code does — use /explain instead.
testing
Use when user invokes /research command with any source — URL, GitHub repo, YouTube video, podcast, Reddit post, academic paper, documentation page, product site, local file, or empty. Processes and indexes research materials with raw source preservation and topic-level synthesis coalescing. Do NOT use for quick factual questions — use /explain instead.