[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M7DH4P3JQMNEZTEYC5AV5WWR":3,"skill-same:01M7DH4P3JQMNEZTEYC5AV5WWR":47},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":25,"commitSha":26,"skillDirectory":27,"forksCount":28,"repositoryHtmlUrl":29,"repositoryHomepageUrl":6,"ownerHtmlUrl":30,"ownerBlogUrl":31,"ownerDescription":6,"updatedAt":32,"install":33,"resources":46},"01M7DH4P3JQMNEZTEYC5AV5WWR","run-spec-worktree-merge",null,"Take a verified task pull request to merged — poll CI and review with runspec.py pr-check, run bounded review rounds through the same worker, keep the branch current by merging origin\u002Fmain, merge only on verdict=ready, confirm the merge on origin\u002Fmain, and clean up the task's worktree","turbokast\u002Fmythhelm","turbokast","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F335585049?v=4","01M7DGYYSHNA1BW1Y9GJFN6DVC","TurboKast","01M7DGYYT6GTPCFADDKS5ZXM1Y",0,"Apache-2.0","https:\u002F\u002Fgithub.com\u002Fturbokast\u002Fmythhelm\u002Fblob\u002Fmain\u002F.claude\u002Fskills\u002Frun-spec-worktree-merge\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: run-spec-worktree-merge\ndescription: Take a verified task pull request to merged — poll CI and review with runspec.py pr-check, run bounded review rounds through the same worker, keep the branch current by merging origin\u002Fmain, merge only on verdict=ready, confirm the merge on origin\u002Fmain, and clean up the task's worktree\nargument-hint: \"\u003Cspec-name> --task N --pr P --worktree \u003Cpath>\"\n---\n\n# Run Spec — Review Loop and Merge\n\nEvery task's work reaches `main` through its own pull request, merged by the orchestrator only when GitHub, not the worker, says it is ready. This is the step that turns \"the worker says it is done\" into \"it is done\".\n\n## Input\n\n`$ARGUMENTS`: the spec, the task, its pull request and the worker's worktree path (absent when resuming a pull request from an earlier run). A lifecycle pull request passes `--lifecycle` instead of a task.\n\n## Invocation contexts\n\n- **Slash command**: runs the loop for one pull request and reports the verdict; it merges only when the person confirms (write gate) or passed `--merge`.\n- **Model-invoked**: the same.\n- **Non-interactive**: inside `\u002Frun-spec`, the run's start is the pre-approval to merge its own task and lifecycle pull requests on `verdict=ready`. Without that context, the merge is a write gate: stop at it and return the verdict.\n\n## Steps\n\n1. **Wait for GitHub, then read it.**\n\n   ```bash\n   gh pr checks \u003Cpr> --watch --interval 30          # waits for CI; its exit status is not the verdict\n   python3 scripts\u002Fharness\u002Frunspec.py pr-check --spec \u003Cspec> --task \u003CN> --pr \u003Cpr>\n   ```\n\n   The verdict is the last line. `pr-check` requires: the pull request open and not a draft; every check's latest run passing or skipped, `CI OK` and `CodeRabbit` present; zero unresolved review threads; a mergeable state that is not conflicting, behind or blocked; the task's completion entry in the pull request's own `tasks.md`, naming this pull request; every changed file inside the task's `Files` or named in its `Spec deviations`; and no leak in the title, body or added lines (`scripts\u002Fci\u002Fcheck-public-hygiene.sh`).\n   - Exit 3, `verdict=unknown` (a check pending, the review not posted, merge state not computed): wait and poll again. Never merge on 3. A review bot that has not started after ten minutes gets a `@coderabbitai review` comment.\n   - Exit 1, `verdict=not-ready`: go to step 2.\n   - Exit 0, `verdict=ready`: go to step 3.\n   - Exit 2: GitHub or git could not be read. That is missing data, not a verdict: retry, then escalate.\n2. **Review round.** Send the `reason=` lines to the same worker with the review-round template (`\u002Frun-spec-dispatch`). Record `review_round`. When it returns, re-run `\u002Frun-spec` Phase 2 step 3 (verification) on the new head, then step 1 here. After three rounds that still end `not-ready`, stop the run: escalation 1.\n   - `behind` or `conflict`: the worker merges `origin\u002Fmain` into its branch in its worktree (never a rebase, never a force push), re-runs its gates and pushes.\n   - Reviewing a branch whose base trails origin\u002Fmain: review the branch's own diff, `git diff \u003Cmerge-base> HEAD` with `\u003Cmerge-base>` from `git merge-base origin\u002Fmain HEAD` after `git fetch origin main`, for scope and deletions. A tree-diff against origin\u002Fmain shows other merged work as deletions the branch never made; use it only to confirm the merge result after the branch is updated.\n   - `scope:` for a file the task legitimately needed: the worker names it in `Spec deviations` with the reason. The orchestrator passes `--accept-scope \u003Cpath>` only for a file the spec itself sanctions elsewhere, and records why in a `verify` event.\n   - `leak:` in the diff: the worker removes it and pushes. A credential (`token`, `private-key`) that was pushed at all stays exposed in the branch history: stop the run and have the operator revoke it. A leak in the title or body stops the run and goes to the operator: the body's edit history stays public, and a `gh api` write to the pull request is a publishing action (`.claude\u002Fhooks\u002Fguard-publish.sh`).\n3. **Merge.**\n\n   ```bash\n   git -C \u003Cworktree> status --porcelain           # must print nothing: no work left behind\n   git worktree remove \u003Cworktree>                 # refuses a dirty worktree; never --force past that\n   gh pr merge \u003Cpr> --squash --delete-branch\n   python3 scripts\u002Fharness\u002Frunspec.py verify-merged --spec \u003Cspec> --task \u003CN> --pr \u003Cpr>\n   python3 scripts\u002Fharness\u002Frunspec.py event --spec \u003Cspec> --kind merge --task \u003CN> --pr \u003Cpr> --result ok\n   ```\n\n   Under an autonomy grant (`scripts\u002Forchestration\u002Fautonomy.sh status` reports it live), `.claude\u002Fhooks\u002Fguard-autonomy.sh` refuses that merge line: record the verdict under the grant with `python3 scripts\u002Forchestration\u002Fautonomy.py merge-check --pr \u003Cpr> --spec \u003Cspec> --task \u003CN>` (`--lifecycle` for a lifecycle pull request), and merge with the `gh pr merge \u003Cpr> --squash --match-head-commit \u003Csha>` it prints (add `--delete-branch`).\n\n   `verify-merged` fetches origin and requires the pull request merged, its merge commit on origin\u002Fmain, and the task's entry there naming the pull request. Anything else is not a merge: record `--result fail` and stop the run. A dirty worktree at the first command means the pushed branch is not the whole work: resume the worker to commit or discard it, then start again at step 1.\n4. **Report** `[\u003Cdone>\u002F\u003Ctotal>] Task N — \u003Cname>: MERGED (PR #\u003Cpr>)`, then `git fetch origin` so the next batch's workers start from the new tip.\n\n## Conflict prevention\n\nParallel tasks have disjoint `Files` by construction (`\u002Frun-spec-parallel-detection`). The spec files every task edits merge without conflict because each task writes only its own `tasks.md` block and its own seeded `handoff.md` section. The conflicts that remain come from a file outside the Files lists, usually one named as a deviation: the second pull request to merge picks it up at step 2 as `behind` or `conflict`.\n\n## Output\n\nOne line per pull request: `PR #\u003Cpr> task \u003CN>: merged (\u003Cmerge sha>)`, or the verdict and reasons at the stop.\n","# Run Spec — Review Loop and Merge\n\nEvery task's work reaches `main` through its own pull request, merged by the orchestrator only when GitHub, not the worker, says it is ready. This is the step that turns \"the worker says it is done\" into \"it is done\".\n\n## Input\n\n`$ARGUMENTS`: the spec, the task, its pull request and the worker's worktree path (absent when resuming a pull request from an earlier run). A lifecycle pull request passes `--lifecycle` instead of a task.\n\n## Invocation contexts\n\n- **Slash command**: runs the loop for one pull request and reports the verdict; it merges only when the person confirms (write gate) or passed `--merge`.\n- **Model-invoked**: the same.\n- **Non-interactive**: inside `\u002Frun-spec`, the run's start is the pre-approval to merge its own task and lifecycle pull requests on `verdict=ready`. Without that context, the merge is a write gate: stop at it and return the verdict.\n\n## Steps\n\n1. **Wait for GitHub, then read it.**\n\n   ```bash\n   gh pr checks \u003Cpr> --watch --interval 30          # waits for CI; its exit status is not the verdict\n   python3 scripts\u002Fharness\u002Frunspec.py pr-check --spec \u003Cspec> --task \u003CN> --pr \u003Cpr>\n   ```\n\n   The verdict is the last line. `pr-check` requires: the pull request open and not a draft; every check's latest run passing or skipped, `CI OK` and `CodeRabbit` present; zero unresolved review threads; a mergeable state that is not conflicting, behind or blocked; the task's completion entry in the pull request's own `tasks.md`, naming this pull request; every changed file inside the task's `Files` or named in its `Spec deviations`; and no leak in the title, body or added lines (`scripts\u002Fci\u002Fcheck-public-hygiene.sh`).\n   - Exit 3, `verdict=unknown` (a check pending, the review not posted, merge state not computed): wait and poll again. Never merge on 3. A review bot that has not started after ten minutes gets a `@coderabbitai review` comment.\n   - Exit 1, `verdict=not-ready`: go to step 2.\n   - Exit 0, `verdict=ready`: go to step 3.\n   - Exit 2: GitHub or git could not be read. That is missing data, not a verdict: retry, then escalate.\n2. **Review round.** Send the `reason=` lines to the same worker with the review-round template (`\u002Frun-spec-dispatch`). Record `review_round`. When it returns, re-run `\u002Frun-spec` Phase 2 step 3 (verification) on the new head, then step 1 here. After three rounds that still end `not-ready`, stop the run: escalation 1.\n   - `behind` or `conflict`: the worker merges `origin\u002Fmain` into its branch in its worktree (never a rebase, never a force push), re-runs its gates and pushes.\n   - Reviewing a branch whose base trails origin\u002Fmain: review the branch's own diff, `git diff \u003Cmerge-base> HEAD` with `\u003Cmerge-base>` from `git merge-base origin\u002Fmain HEAD` after `git fetch origin main`, for scope and deletions. A tree-diff against origin\u002Fmain shows other merged work as deletions the branch never made; use it only to confirm the merge result after the branch is updated.\n   - `scope:` for a file the task legitimately needed: the worker names it in `Spec deviations` with the reason. The orchestrator passes `--accept-scope \u003Cpath>` only for a file the spec itself sanctions elsewhere, and records why in a `verify` event.\n   - `leak:` in the diff: the worker removes it and pushes. A credential (`token`, `private-key`) that was pushed at all stays exposed in the branch history: stop the run and have the operator revoke it. A leak in the title or body stops the run and goes to the operator: the body's edit history stays public, and a `gh api` write to the pull request is a publishing action (`.claude\u002Fhooks\u002Fguard-publish.sh`).\n3. **Merge.**\n\n   ```bash\n   git -C \u003Cworktree> status --porcelain           # must print nothing: no work left behind\n   git worktree remove \u003Cworktree>                 # refuses a dirty worktree; never --force past that\n   gh pr merge \u003Cpr> --squash --delete-branch\n   python3 scripts\u002Fharness\u002Frunspec.py verify-merged --spec \u003Cspec> --task \u003CN> --pr \u003Cpr>\n   python3 scripts\u002Fharness\u002Frunspec.py event --spec \u003Cspec> --kind merge --task \u003CN> --pr \u003Cpr> --result ok\n   ```\n\n   Under an autonomy grant (`scripts\u002Forchestration\u002Fautonomy.sh status` reports it live), `.claude\u002Fhooks\u002Fguard-autonomy.sh` refuses that merge line: record the verdict under the grant with `python3 scripts\u002Forchestration\u002Fautonomy.py merge-check --pr \u003Cpr> --spec \u003Cspec> --task \u003CN>` (`--lifecycle` for a lifecycle pull request), and merge with the `gh pr merge \u003Cpr> --squash --match-head-commit \u003Csha>` it prints (add `--delete-branch`).\n\n   `verify-merged` fetches origin and requires the pull request merged, its merge commit on origin\u002Fmain, and the task's entry there naming the pull request. Anything else is not a merge: record `--result fail` and stop the run. A dirty worktree at the first command means the pushed branch is not the whole work: resume the worker to commit or discard it, then start again at step 1.\n4. **Report** `[\u003Cdone>\u002F\u003Ctotal>] Task N — \u003Cname>: MERGED (PR #\u003Cpr>)`, then `git fetch origin` so the next batch's workers start from the new tip.\n\n## Conflict prevention\n\nParallel tasks have disjoint `Files` by construction (`\u002Frun-spec-parallel-detection`). The spec files every task edits merge without conflict because each task writes only its own `tasks.md` block and its own seeded `handoff.md` section. The conflicts that remain come from a file outside the Files lists, usually one named as a deviation: the second pull request to merge picks it up at step 2 as `behind` or `conflict`.\n\n## Output\n\nOne line per pull request: `PR #\u003Cpr> task \u003CN>: merged (\u003Cmerge sha>)`, or the verdict and reasons at the stop.\n",{"name":5,"description":7,"argument-hint":24},"\u003Cspec-name> --task N --pr P --worktree \u003Cpath>","main","6e250ec86158119da148ddc017b960ed3b2bee2b",".claude\u002Fskills\u002Frun-spec-worktree-merge",1,"https:\u002F\u002Fgithub.com\u002Fturbokast\u002Fmythhelm","https:\u002F\u002Fgithub.com\u002Fturbokast","https:\u002F\u002Fturbokast.com","2026-11-10 17:37:03",{"source":8,"skillName":5,"commands":34,"prompt":44,"zipAvailable":45},[35,38,41],{"tool":36,"command":37},"npx","npx skills add turbokast\u002Fmythhelm --skill run-spec-worktree-merge",{"tool":39,"command":40},"bunx","bunx skills add turbokast\u002Fmythhelm --skill run-spec-worktree-merge",{"tool":42,"command":43},"pnpm","pnpm dlx skills add turbokast\u002Fmythhelm --skill run-spec-worktree-merge","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fturbokast\u002Fmythhelm\u002Fblob\u002Fmain\u002F.claude\u002Fskills\u002Frun-spec-worktree-merge\u002FSKILL.md",true,[],[48,55,62,69,76,83],{"skillNo":49,"name":50,"nameZh":6,"description":51,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":52,"categories":53,"keywords":54,"publishedAt":19},"01M7DH77QH78C95S7A5V1GFKKF","mythhelm-deliver-backlog","Coordinate a MYTHHELM backlog run with the shared stage checks and maintainer checkpoints.","https:\u002F\u002Fgithub.com\u002Fturbokast\u002Fmythhelm\u002Fblob\u002Fmain\u002F.grok\u002Fskills\u002Fmythhelm-deliver-backlog\u002FSKILL.md",[],[],{"skillNo":56,"name":57,"nameZh":6,"description":58,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":59,"categories":60,"keywords":61,"publishedAt":19},"01M7DH748EXYG9RVBWPBJ73M27","mythhelm-bootstrap","Orient a Grok Build session in the MYTHHELM repository before task or spec work.","https:\u002F\u002Fgithub.com\u002Fturbokast\u002Fmythhelm\u002Fblob\u002Fmain\u002F.grok\u002Fskills\u002Fmythhelm-bootstrap\u002FSKILL.md",[],[],{"skillNo":63,"name":64,"nameZh":6,"description":65,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":66,"categories":67,"keywords":68,"publishedAt":19},"01M7DH70XJE0DZA4T5DYR1TWKZ","vendor-consult","Run one advisory stage consult (premise-ground, spec-validate, task-review, change-review, stuck-oracle, dossier) with an optional external vendor, then adjudicate the answer at its anchors","https:\u002F\u002Fgithub.com\u002Fturbokast\u002Fmythhelm\u002Fblob\u002Fmain\u002F.claude\u002Fskills\u002Fvendor-consult\u002FSKILL.md",[],[],{"skillNo":70,"name":71,"nameZh":6,"description":72,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":73,"categories":74,"keywords":75,"publishedAt":19},"01M7DH6X9HSQ308P5FNDSKYR5R","update-docs","Bring README, docs\u002F, knowledge\u002F, WORKFLOW.md and CLAUDE.md in line with what a shipped spec or a merged change actually did — find every statement the change made stale, fix it where readers look, and add only the new facts they need","https:\u002F\u002Fgithub.com\u002Fturbokast\u002Fmythhelm\u002Fblob\u002Fmain\u002F.claude\u002Fskills\u002Fupdate-docs\u002FSKILL.md",[],[],{"skillNo":77,"name":78,"nameZh":6,"description":79,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":80,"categories":81,"keywords":82,"publishedAt":19},"01M7DH6T82XR40XQFNRTN4AHGN","triage","Score an idea or a GitHub issue against the master spec's stages, gates and commitments, check it for duplicates, and recommend whether it becomes a backlog card; read-only","https:\u002F\u002Fgithub.com\u002Fturbokast\u002Fmythhelm\u002Fblob\u002Fmain\u002F.claude\u002Fskills\u002Ftriage\u002FSKILL.md",[],[],{"skillNo":84,"name":85,"nameZh":6,"description":86,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":87,"categories":88,"keywords":89,"publishedAt":19},"01M7DH6Q17PM4ESX978QYFV6H6","test-driven-development","Red-green-refactor for Go — use when implementing any feature, bug fix or behaviour change, before writing implementation code","https:\u002F\u002Fgithub.com\u002Fturbokast\u002Fmythhelm\u002Fblob\u002Fmain\u002F.claude\u002Fskills\u002Ftest-driven-development\u002FSKILL.md",[],[]]