pr-finish-pass
БесплатноБез исполняемых скриптовНе проверенFinal-polish pass on the current PR or feature branch before it lands. Rebases on origin/main, force-pushes, drives CI to green, then reviews the diff for…
от burin-labs★ 34 звезды на GitHubОб этом скилле
pr-finish-pass
Final-polish sweep on whatever work is currently in flight. That is usually a named PR, but it works equally well on an unpushed feature branch or a session's accumulated diff. The goal is to get the change to a state a senior reviewer would land without comments.
The sweep is not a generic code review. It targets the recurring issues this repo accumulates between "the feature works" and "the PR is landable."
When to use
- A PR is open and you want it merged today.
- A feature branch is about to become a PR.
- A session produced a diff worth landing and you want it polished before opening the PR.
If there is no current branch worth polishing — say so and stop.
Phase 0 — identify the work
Determine the scope before touching anything:
git status --short
git rev-parse --abbrev-ref HEAD # current branch
git log --oneline origin/main..HEAD # commits to ship
gh pr view --json number,state,headRefName,mergeStateStatus 2>/dev/null
If gh pr view returns a PR, you are in PR mode. Otherwise you are
in branch mode — the rebase / CI phases are skipped and you go
straight to the review sweep.
Read the full diff before doing anything else:
git diff origin/main...HEAD
For PRs in PR mode, also read gh pr view --json title,body,comments
and skim review comments — sometimes the easiest finding is one a
reviewer already left.
Phase 1 — rebase on origin/main (PR mode only)
git fetch origin main
git rebase origin/main
Resolve conflicts inline. Common conflict rules in this repo:
changelog.d/*.md: keep distinct fragments from both sides. Release tooling owns the generatedCHANGELOG.md.docs/theme/harn-keywords.js: regenerate withmake gen-highlight.spec/HARN_SPEC.md/docs/src/language-spec.md: keep neither generated side. Resolve the editablespec/chapters/*.mdsources, then runmake sync-language-spec.Cargo.lock: resolve from the merged manifests, then runmake setup-rustin the worktree.- Any file with both sides reformatted: take one side then
make fmt/make fmt-harn/ portal lint as appropriate.
Then force-push with lease:
git push --force-with-lease
Never --force without --with-lease — co-authors may have pushed.
Phase 2 — drive CI to green (PR mode only)
gh pr checks
gh run list --branch "$(git branch --show-current)" --limit 5
For each failing check, fetch the actual log and read it:
gh run view <run-id> --log-failed
Address failures comprehensively — do not paper over them with retries
or continue-on-error. Common categories:
- Format / clippy / lint failures: run
make fmt,make lint,make lint-harn,make fmt-harnand commit the fixes. - Test failures: reproduce locally with
make test-oneand theHARN_TEST_ONE_NAMEandHARN_TEST_ONE_PACKAGEvariables. Usemake test-affectedwhen the failure spans a changed crate. Read the test, read the code under test, and fix the root cause. - Conformance failures:
./scripts/harn_bin.sh -- test conformance --filter <name>reproduces a single case. If a.expectedfile needs updating because user-visible behavior intentionally changed, do that explicitly — don't blindly accept new output. - Portal / VS Code / tree-sitter failures: run the corresponding
npm run portal:lint/npm run portal:build/npm testlocally. make check-language-spec/make check-highlight/make check-trigger-quickref: these are drift checks. Re-run the generators and commit the regenerated outputs.make lint-test-patterns: see the flaky-test guidance in Phase 3.make check-docs-snippets: a.harnsnippet underdocs/src/no longer parses or type-checks. Fix the snippet, not the parser.
Push fixes incrementally; let CI re-run between iterations rather than batching every guess at once.
If a failure is a known-flaky test unrelated to the diff, re-run the
specific job (gh run rerun <run-id> --failed). Do not silence it.
Phase 3 — the review sweep
This is the substance of the skill. Walk the diff and look for each of the following classes of finding. Fix every material one inline; note non-material findings in your end-of-turn summary so the user can decide whether to address them.
3.1 correctness, performance, security, privacy, reliability
- Off-by-ones, unhandled
Option/Result, panics on hostile input, integer overflow on user-controlled arithmetic. - Unbounded allocations driven by external input (request body sizes, iterator chains over network responses, recursive structures with no depth cap).
- Concurrency: shared mutable state without synchronization, deadlocks
from nested locks, cancellation safety on
select!arms. - Secrets in logs, request/response bodies, error messages, transcripts. This crate writes a lot of structured logs — check whether anything us
Установить pr-finish-pass в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
FAQ
Что делает скилл pr-finish-pass?
Final-polish pass on the current PR or feature branch before it lands. Rebases on origin/main, force-pushes, drives CI to green, then reviews the diff for correctness/perf/security/reliability bugs, flaky test patterns banned by `make lint-test-patterns`, sloppy comments a senior engineer would not write, cross-crate drift (typechecker / formatter / portal / DAP / LSP / tree-sitter), DRY/polish, Rust orchestration logic that should be Harn script composing host capabilities, prompt prose that belongs in `.harn.prompt` files, long files that should be split, and interpreter perf wins that bundle naturally with the change. Triggers when the user says "finish pass", "polish this PR", "wrap up the PR", or otherwise asks for a final review-and-fix sweep before merge.
Как установить скилл pr-finish-pass?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл pr-finish-pass запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
doc-coauthoring
Guide users through a structured workflow for co-authoring documentation. Use when user wants to write documentation, proposals, technical specs, decision…
от Anthropicacademy-guide
Stop and check this skill before finishing any reply to a question about how to use Claude or a Claude product — it recommends matching courses, tutorials…
от Anthropicinternal-comms
A set of resources to help me write all kinds of internal communications, using the formats that my company likes to use. Claude should use this skill…
от Anthropicskill-development
This skill should be used when the user wants to "create a skill", "add a skill to plugin", "write a new skill", "improve skill description", "organize skill…
от Anthropic