pr-publish
Skill2 starsChanged 15 days agoMITView on GitHub
Post an approved PR draft: a review, replies, or a description
1 other project uses a version of this.
Adopted by
Most recently taken up by
- JQ-WCoding/devkittheir own version, first seen Nov 22, 2026
Other versions1 project uses a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 1
- JQ-WCoding/devkit★ 1same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository81 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- templates/CLAUDE.mdCLAUDE.md
- add-languageSkill
- audit-a11ySkill
- audit-archSkill
- audit-ciSkill
- audit-debtSkill
- audit-doc-driftSkill
- audit-flagsSkill
- audit-infraSkill
- audit-perfSkill
- audit-readinessSkill
- audit-securitySkill
- audit-slopSkill
- audit-testsSkill
- audit-tokensSkill
- audit-verifySkill
- backup-patternsSkill
- bash-patternsSkill
- claude-code-mods-patternsSkill
- code-challengeSkill
- code-contractSkill
- code-deep-reviewSkill
- code-evaluateSkill
- code-from-designSkill
- code-historySkill
- code-host-patternsSkill
- code-impactSkill
- code-migrateSkill
- code-tourSkill
- code-visualSkill
- depsSkill
- django-patternsSkill
- docker-patternsSkill
- drf-patternsSkill
- engineering-fundamentalsSkill
- fastapi-patternsSkill
- git-patternsSkill
- go-patternsSkill
- graphql-patternsSkill
- investigateSkill
- javascript-patternsSkill
- kit-rulesSkill
- logging-patternsSkill
- meta-conventionsSkill
- meta-promptSkill
- meta-refreshSkill
- meta-retroSkill
- meta-skillSkill
- monitoring-patternsSkill
- next-app-router-patternsSkill
- nuxt-patternsSkill
- opentofu-patternsSkill
- pr-descriptionSkill
- pr-queueSkill
- pr-replySkill
- pr-reviewSkill
- python-patternsSkill
- react-patternsSkill
- report-formatSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
4 rules. About 0 are common, 1 is distinctive, and 3 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈1
Distinctive · estimate
This author's own choices. Worth a look.
3
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 23
Never push, approve, request changes, resolve threads, or edit or delete existing comments.
- Very specific: line 31
Read the draft's header: Kind, PR or Branch, Head.
- Very specific: line 32
Read the draft's post log, <draft path without .md>.posted.log, if it exists.
- Very specific: line 64
Every pr-* draft starts with this header, and this skill parses it.
≈ “Common” is an estimate: at least 1 in 5 of the 408,460 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
/pr-publish
Post a draft the user approved: a review, replies, or a description.
Never push, approve, request changes, resolve threads, or edit or delete existing comments.
Tone and shape: skills/kit-rules/reference/output.md section 4, which wins over this file; the sections this file defines stay.
Find the draft
- With a PR number: the drafts in
kit scratch-dirwith prefixpr-review-<n>orpr-reply-<n>, plus anypr-description-*.mdwhose headerPR:line names#<n>. Without one: the current branch's drafts with prefixpr-description-<branch>(/in the branch name becomes-), plus the review and reply drafts of its open PR, if any. A branch draft counts only when its header'sBranch:line names the branch or itsPR:line names that open PR: another branch's draft can share its name. Never a wider glob:pr-review-1*picks up PR 12's. - Take the newest file per kind (
ls -t). If there's none, stop and name the drafting kind to run. If there's more than one kind, ask which via AskUserQuestion. - Read the draft's header:
Kind,PRorBranch,Head.<repo>comes from thePR:line, or from the repository path for aBranch:header. - Read the draft's post log,
<draft path without .md>.posted.log, if it exists. Sections it lists are already posted and are skipped. Every section posted: say so and stop.
Check before posting
- Head, for a review: the PR's head SHA; for a description:
git rev-parse HEAD. Different from the header'sHead: stop, say so, and offer to re-draft. A reply skips this check: pushing the fixes it promises moves the head, and its anchors are comment ids, not lines. - Review: every inline anchor's line still falls inside a hunk of the PR's diff.
- Description: whether the branch has an open PR is checked now, never taken from the header. No open PR:
git ls-remote origin "refs/heads/<branch>"must print the header'sHead. Missing or different: stop with "push first". Never push. - Split the draft into one body file per unposted comment under scratch, through Write, each byte-identical to its section's postable text with surrounding blank lines trimmed. The header, headings, and a reply's leading quote are not comment text. A description gets a title file holding the
Title:line's text and a body file holding everything after that line. - One AskUserQuestion with options
PostandCancel: "Post N comments to PR<n>?", or for a description "Update the title and body of PR<n>?" or "Open a PR from<branch>?". Nothing is posted withoutPostfrom this session.
Post
Review and reply post one comment per API call, at least 30 s apart, in file order, except a review's summary, which goes last. A batched review can't be paced, so never use one.
Each section's call is the Post table in skills/code-host-patterns.
The title comes from a file because a title like feat(pr): /pr skill would be shell-expanded inside a typed double-quoted string; a command substitution's output isn't.
Run the review or reply loop as one Bash call with run_in_background, sleep 30 between posts inside it; the harness blocks a foreground sleep. After each post, append the section heading and the URL and created_at that skills/code-host-patterns names as one tab-separated line to the post log. A failed post stops the loop: report it, never retry blind; a rerun resumes from the log.
30 s sits under each host's content limits (skills/code-host-patterns). Some endpoints have lower, unnamed limits, so a 403 or 429 means stop and report.
Check, then reply
- Fetch each posted comment (a description: the PR's title and body) and diff its text against its body file. Any difference is reported, never silently edited.
- Inline review comments: the returned
pathandlinematch the anchor. - Consecutive
created_atvalues in the post log are at least 30 s apart.
Reply: the PR URL, the posted count, and any mismatch. Ask before deleting the body files; keep the draft and its post log.
Draft header
Every pr-* draft starts with this header, and this skill parses it.
# PR <n or branch> <kind> draft (not posted)
Kind: <description|review|reply>
PR: <repo>#<n>
Head: <full head SHA the draft was written against><repo> is the host's repository path (skills/code-host-patterns). A description for a branch with no PR yet writes Branch: <name> in place of the PR: line.
Arguments: $ARGUMENTS
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

