[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M6DZB420JCDQPGVBXCE7WWWV":3,"skill-same:01M6DZB420JCDQPGVBXCE7WWWV":55},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":15,"categories":16,"keywords":17,"publishedAt":27,"linkOnly":28,"markdownContent":29,"markdownBody":30,"frontMatter":31,"refName":33,"commitSha":34,"skillDirectory":35,"forksCount":36,"repositoryHtmlUrl":37,"repositoryHomepageUrl":38,"ownerHtmlUrl":39,"ownerBlogUrl":40,"ownerDescription":6,"updatedAt":41,"install":42,"resources":54},"01M6DZB420JCDQPGVBXCE7WWWV","eforge-stack",null,"Synchronize the git-spice stack, preview with dry-run, interpret the sync report, and recover from manual sync conflicts","eforge-build\u002Feforge","eforge-build","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F268386632?v=4","01M6DZ9WAH8M3XRV4J88WG5SB5","01M6DZ9WEVEC6BJ62ZX3RAVA02",71,"Apache-2.0","https:\u002F\u002Fgithub.com\u002Feforge-build\u002Feforge\u002Fblob\u002Fmain\u002Fpackages\u002Fpi-eforge\u002Fskills\u002Feforge-stack\u002FSKILL.md",[],[18,19,20,21,22,23,24,25,26],"stack","eforge stack","sync","run","report","git","conflicts","preview","dry","2026-11-10 10:12:30",false,"---\nname: eforge-stack\ndescription: Synchronize the git-spice stack, preview with dry-run, interpret the sync report, and recover from manual sync conflicts\ndisable-model-invocation: true\n---\n\n# \u002Feforge:stack:sync\n\nManually synchronize the git-spice stack for this project. Use `--dry-run` to preview what commands would run without executing them.\n\nThis skill covers manual `eforge stack sync` recovery. During stacked PR landing with `landing.action: pr`, eforge attempts automatic provider-encapsulated recovery for provider-classified recoverable restack conflicts before asking for manual intervention. Landing also preflights the remote base: if a missing parent branch's artifact commit is an ancestor of trunk, eforge automatically performs branch-scoped stale-parent repair by tracking initially untracked children against trunk or retargeting already tracked children; otherwise it fails closed with manual stack-base repair guidance. Before submitting the PR, landing runs provider repo sync, branch restack, and a remote-base freshness proof for the branch being submitted.\n\nStack sync is a daemon-owned operation that runs from the project root. The daemon calls `git-spice repo sync` followed by `git-spice stack restack`. Triggers include: this command (`\u002Feforge:stack:sync`), the CLI (`eforge stack sync`), the `eforge_stack_sync` tool, and — when `stacking.sync.afterBuild: true` is configured — automatically after each build completes.\n\n## Requirements\n\nStack sync requires `stacking.enabled: true` in `eforge\u002Fconfig.yaml` and git-spice initialized in the repository (`git-spice repo init`). If stacking is not enabled the daemon returns `outcome: \"skipped\"` with a reason.\n\n## Step 1: Detect dry-run flag\n\nCheck `$ARGUMENTS` for `--dry-run`. If present, set `dryRun: true` in the tool call.\n\n## Step 2: Run the sync\n\nCall the `eforge_stack_sync` tool with `{ dryRun: \u003Ctrue|false> }`.\n\n## Step 3: Interpret the response\n\nThe tool returns a structured sync report. Interpret each field:\n\n| Field | Meaning |\n|-------|---------|\n| `outcome` | One of `\"skipped\"`, `\"complete\"`, `\"deferred\"`, `\"failed\"`, `\"conflict\"` |\n| `reason` | Human-readable reason (always present for skipped\u002Fdeferred\u002Ffailed\u002Fconflict) |\n| `stackingActive` | Whether stacking is enabled and active for this project |\n| `dryRun` | Whether this was a preview-only run |\n| `localTrunkSha` | SHA of the local trunk branch |\n| `originTrunkSha` | SHA of `origin\u002F\u003Ctrunk>` |\n| `fastForward` | True when local trunk is at or behind origin (fast-forward eligible) |\n| `restackCandidates` | Artifact branches eligible for restack |\n| `activeBuildSkips` | Branches\u002Fworktrees skipped because active builds are using their worktrees and overlap the stack candidate set |\n| `providerCommands` | git-spice commands that ran (or would run in dry-run) |\n| `error` | Error message when outcome is `\"failed\"` or `\"conflict\"` |\n\n### Outcome summaries\n\n**`skipped`** - Stacking is not enabled or no stacking configuration found. Nothing was changed. Show the `reason` to the user. Suggest enabling stacking with `\u002Feforge:config` or `\u002Feforge:workflow`.\n\n**`complete`** - All eligible artifact branches were restacked onto the latest trunk. Show the list of `providerCommands` that ran and the `restackCandidates` that were processed.\n\n**`deferred`** - Active builds are running and their worktrees overlap the stack candidate set. The restack step was skipped to avoid conflicting with in-flight builds. Show `activeBuildSkips` and `reason`. The `activeBuildPolicy` field will be `\"defer\"` when a deferred outcome was explicitly requested. If `stacking.sync.afterBuild: true` is configured, the daemon will retry deferred syncs after each build completes — no manual action is needed. Otherwise, suggest waiting for active builds to complete and then running `\u002Feforge:stack:sync` again.\n\n**`failed`** - The sync command exited with a non-zero code. Show `error` and the failed `providerCommands`. Suggest running `git-spice` manually to investigate, then re-running sync after resolving the issue.\n\n**`conflict`** - A manual sync restack step hit a merge conflict. Show `error` and the `providerCommands` list. Proceed with the manual sync conflict recovery flow below.\n\n### Active-build skips\n\nWhen `activeBuildSkips` is non-empty, report which branches were excluded and why. These branches were left unchanged because active eforge builds are using their worktrees. When `outcome` is `\"deferred\"`, the entire restack step was skipped; when `outcome` is `\"complete\"`, only the listed branches were skipped and the rest were restacked. Re-run sync after the active builds complete to restack the skipped branches.\n\n### Fast-forward check\n\nWhen `fastForward` is `false`, the local trunk is ahead of `origin\u002F\u003Ctrunk>`. Sync uses a fast-forward-only trunk policy: it will not force-push or rebase trunk. Tell the user to push or align their local trunk before syncing.\n\n## Step 4: Manual sync conflict recovery\n\nWhen `outcome` is `\"conflict\"`, the conflict came from `eforge stack sync`. Do not describe this as the stacked PR landing recovery path; landing recovery runs automatically first for provider-classified recoverable restack conflicts, stale-parent landing repair is automatic and branch-scoped when parent artifact ancestry proves trunk integration (tracking initially untracked children against trunk or retargeting already tracked children), and landing-time sync\u002Ffreshness is automatic for the branch being submitted.\n\nWhen `outcome` is `\"conflict\"`:\n\n1. Show the error and the exact commands that ran up to the point of conflict.\n2. Instruct the user:\n   > A merge conflict occurred during manual stack sync restack. To recover:\n   > 1. Run `git status` to see the conflicting files.\n   > 2. Resolve the conflicts in the affected files.\n   > 3. Run `git add \u003Cresolved-files>` to stage the resolved files.\n   > 4. Run `git rebase --continue` (or the git-spice equivalent) to resume the restack.\n   > 5. Once the restack finishes, run `\u002Feforge:stack:sync` again to sync remaining branches.\n3. Offer to re-run the sync after the user confirms they have resolved the conflict.\n\n## Dry-run output\n\nWhen `dryRun` is `true`:\n\n- Make clear that no commands were executed.\n- List each entry in `providerCommands` with its `command` and `args`.\n- Show `restackCandidates` — the branches that would be restacked.\n- Show `activeBuildSkips` — branches that would be skipped due to active builds.\n\n## Related skills\n\n| Skill | Command | When to suggest |\n|-------|---------|----------------|\n| Workflow | `\u002Feforge:workflow` | User wants to configure workflow preset (stacking, landing action, auto-sync) |\n| Config | `\u002Feforge:config` | User wants to enable\u002Fdisable stacking or change sync config |\n| Status | `\u002Feforge:status` | User wants to check build progress before sync |\n","# \u002Feforge:stack:sync\n\nManually synchronize the git-spice stack for this project. Use `--dry-run` to preview what commands would run without executing them.\n\nThis skill covers manual `eforge stack sync` recovery. During stacked PR landing with `landing.action: pr`, eforge attempts automatic provider-encapsulated recovery for provider-classified recoverable restack conflicts before asking for manual intervention. Landing also preflights the remote base: if a missing parent branch's artifact commit is an ancestor of trunk, eforge automatically performs branch-scoped stale-parent repair by tracking initially untracked children against trunk or retargeting already tracked children; otherwise it fails closed with manual stack-base repair guidance. Before submitting the PR, landing runs provider repo sync, branch restack, and a remote-base freshness proof for the branch being submitted.\n\nStack sync is a daemon-owned operation that runs from the project root. The daemon calls `git-spice repo sync` followed by `git-spice stack restack`. Triggers include: this command (`\u002Feforge:stack:sync`), the CLI (`eforge stack sync`), the `eforge_stack_sync` tool, and — when `stacking.sync.afterBuild: true` is configured — automatically after each build completes.\n\n## Requirements\n\nStack sync requires `stacking.enabled: true` in `eforge\u002Fconfig.yaml` and git-spice initialized in the repository (`git-spice repo init`). If stacking is not enabled the daemon returns `outcome: \"skipped\"` with a reason.\n\n## Step 1: Detect dry-run flag\n\nCheck `$ARGUMENTS` for `--dry-run`. If present, set `dryRun: true` in the tool call.\n\n## Step 2: Run the sync\n\nCall the `eforge_stack_sync` tool with `{ dryRun: \u003Ctrue|false> }`.\n\n## Step 3: Interpret the response\n\nThe tool returns a structured sync report. Interpret each field:\n\n| Field | Meaning |\n|-------|---------|\n| `outcome` | One of `\"skipped\"`, `\"complete\"`, `\"deferred\"`, `\"failed\"`, `\"conflict\"` |\n| `reason` | Human-readable reason (always present for skipped\u002Fdeferred\u002Ffailed\u002Fconflict) |\n| `stackingActive` | Whether stacking is enabled and active for this project |\n| `dryRun` | Whether this was a preview-only run |\n| `localTrunkSha` | SHA of the local trunk branch |\n| `originTrunkSha` | SHA of `origin\u002F\u003Ctrunk>` |\n| `fastForward` | True when local trunk is at or behind origin (fast-forward eligible) |\n| `restackCandidates` | Artifact branches eligible for restack |\n| `activeBuildSkips` | Branches\u002Fworktrees skipped because active builds are using their worktrees and overlap the stack candidate set |\n| `providerCommands` | git-spice commands that ran (or would run in dry-run) |\n| `error` | Error message when outcome is `\"failed\"` or `\"conflict\"` |\n\n### Outcome summaries\n\n**`skipped`** - Stacking is not enabled or no stacking configuration found. Nothing was changed. Show the `reason` to the user. Suggest enabling stacking with `\u002Feforge:config` or `\u002Feforge:workflow`.\n\n**`complete`** - All eligible artifact branches were restacked onto the latest trunk. Show the list of `providerCommands` that ran and the `restackCandidates` that were processed.\n\n**`deferred`** - Active builds are running and their worktrees overlap the stack candidate set. The restack step was skipped to avoid conflicting with in-flight builds. Show `activeBuildSkips` and `reason`. The `activeBuildPolicy` field will be `\"defer\"` when a deferred outcome was explicitly requested. If `stacking.sync.afterBuild: true` is configured, the daemon will retry deferred syncs after each build completes — no manual action is needed. Otherwise, suggest waiting for active builds to complete and then running `\u002Feforge:stack:sync` again.\n\n**`failed`** - The sync command exited with a non-zero code. Show `error` and the failed `providerCommands`. Suggest running `git-spice` manually to investigate, then re-running sync after resolving the issue.\n\n**`conflict`** - A manual sync restack step hit a merge conflict. Show `error` and the `providerCommands` list. Proceed with the manual sync conflict recovery flow below.\n\n### Active-build skips\n\nWhen `activeBuildSkips` is non-empty, report which branches were excluded and why. These branches were left unchanged because active eforge builds are using their worktrees. When `outcome` is `\"deferred\"`, the entire restack step was skipped; when `outcome` is `\"complete\"`, only the listed branches were skipped and the rest were restacked. Re-run sync after the active builds complete to restack the skipped branches.\n\n### Fast-forward check\n\nWhen `fastForward` is `false`, the local trunk is ahead of `origin\u002F\u003Ctrunk>`. Sync uses a fast-forward-only trunk policy: it will not force-push or rebase trunk. Tell the user to push or align their local trunk before syncing.\n\n## Step 4: Manual sync conflict recovery\n\nWhen `outcome` is `\"conflict\"`, the conflict came from `eforge stack sync`. Do not describe this as the stacked PR landing recovery path; landing recovery runs automatically first for provider-classified recoverable restack conflicts, stale-parent landing repair is automatic and branch-scoped when parent artifact ancestry proves trunk integration (tracking initially untracked children against trunk or retargeting already tracked children), and landing-time sync\u002Ffreshness is automatic for the branch being submitted.\n\nWhen `outcome` is `\"conflict\"`:\n\n1. Show the error and the exact commands that ran up to the point of conflict.\n2. Instruct the user:\n   > A merge conflict occurred during manual stack sync restack. To recover:\n   > 1. Run `git status` to see the conflicting files.\n   > 2. Resolve the conflicts in the affected files.\n   > 3. Run `git add \u003Cresolved-files>` to stage the resolved files.\n   > 4. Run `git rebase --continue` (or the git-spice equivalent) to resume the restack.\n   > 5. Once the restack finishes, run `\u002Feforge:stack:sync` again to sync remaining branches.\n3. Offer to re-run the sync after the user confirms they have resolved the conflict.\n\n## Dry-run output\n\nWhen `dryRun` is `true`:\n\n- Make clear that no commands were executed.\n- List each entry in `providerCommands` with its `command` and `args`.\n- Show `restackCandidates` — the branches that would be restacked.\n- Show `activeBuildSkips` — branches that would be skipped due to active builds.\n\n## Related skills\n\n| Skill | Command | When to suggest |\n|-------|---------|----------------|\n| Workflow | `\u002Feforge:workflow` | User wants to configure workflow preset (stacking, landing action, auto-sync) |\n| Config | `\u002Feforge:config` | User wants to enable\u002Fdisable stacking or change sync config |\n| Status | `\u002Feforge:status` | User wants to check build progress before sync |\n",{"name":5,"description":7,"disable-model-invocation":32},true,"main","499776fb979b8166258cdf9bb95b41de703de835","packages\u002Fpi-eforge\u002Fskills\u002Feforge-stack",4,"https:\u002F\u002Fgithub.com\u002Feforge-build\u002Feforge","https:\u002F\u002Fwww.eforge.build","https:\u002F\u002Fgithub.com\u002Feforge-build","https:\u002F\u002Feforge.build","2026-07-14 04:45:40",{"source":8,"skillName":5,"commands":43,"prompt":53,"zipAvailable":32},[44,47,50],{"tool":45,"command":46},"npx","npx skills add eforge-build\u002Feforge --skill eforge-stack",{"tool":48,"command":49},"bunx","bunx skills add eforge-build\u002Feforge --skill eforge-stack",{"tool":51,"command":52},"pnpm","pnpm dlx skills add eforge-build\u002Feforge --skill eforge-stack","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Feforge-build\u002Feforge\u002Fblob\u002Fmain\u002Fpackages\u002Fpi-eforge\u002Fskills\u002Feforge-stack\u002FSKILL.md",[],[56,76,89,102,113,131],{"skillNo":57,"name":58,"nameZh":6,"description":59,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":60,"categories":61,"keywords":67,"publishedAt":27},"01M6DZBCECD12JJM3BZMWT3Y4N","eforge-workflow","Set up or reconfigure the eforge workflow preset — landing action, stacking, PR settings, and automatic stack sync","https:\u002F\u002Fgithub.com\u002Feforge-build\u002Feforge\u002Fblob\u002Fmain\u002Fpackages\u002Fpi-eforge\u002Fskills\u002Feforge-workflow\u002FSKILL.md",[62],{"categoryNo":63,"categoryName":64,"taxonomyType":65,"taxonomyTypeDesc":66},"01JBSEEDCAT000000000000023","Skill与智能体开发","SCENARIO","使用场景",[68,69,70,71,72,20,18,73,74,75],"eforge workflow","workflow","pr","preset","SET","settings","landing","up",{"skillNo":77,"name":78,"nameZh":6,"description":79,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":80,"categories":81,"keywords":82,"publishedAt":27},"01M6DZB994EMFBB6NQY5K2M2FG","eforge-update","Check for eforge updates and guide through updating the CLI package and daemon","https:\u002F\u002Fgithub.com\u002Feforge-build\u002Feforge\u002Fblob\u002Fmain\u002Fpackages\u002Fpi-eforge\u002Fskills\u002Feforge-update\u002FSKILL.md",[],[83,84,85,86,87,88],"update","eforge update","guide","check","package","cli",{"skillNo":90,"name":91,"nameZh":6,"description":92,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":93,"categories":94,"keywords":95,"publishedAt":27},"01M6DZB6MD3FP4X1DNMH2X5RVD","eforge-status","Check eforge run status and queue state via daemon tools","https:\u002F\u002Fgithub.com\u002Feforge-build\u002Feforge\u002Fblob\u002Fmain\u002Fpackages\u002Fpi-eforge\u002Fskills\u002Feforge-status\u002FSKILL.md",[],[96,97,86,98,99,100,101,21],"eforge status","status","via","queue","Tools","state",{"skillNo":103,"name":104,"nameZh":6,"description":105,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":106,"categories":107,"keywords":108,"publishedAt":27},"01M6DZB15H8P4KR68PDDGA54E4","eforge-restart","Safely restart the eforge daemon, checking for active builds first","https:\u002F\u002Fgithub.com\u002Feforge-build\u002Feforge\u002Fblob\u002Fmain\u002Fpackages\u002Fpi-eforge\u002Fskills\u002Feforge-restart\u002FSKILL.md",[],[109,110,111,112],"eforge restart","restart","active","first",{"skillNo":114,"name":115,"nameZh":6,"description":116,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":117,"categories":118,"keywords":124,"publishedAt":27},"01M6DZAY5M4C2SFV8P6GTZWN85","eforge-recover","Inspect the recovery verdict for a failed PRD and apply the recommended action (retry, continue-repair, abandon, or manual)","https:\u002F\u002Fgithub.com\u002Feforge-build\u002Feforge\u002Fblob\u002Fmain\u002Fpackages\u002Fpi-eforge\u002Fskills\u002Feforge-recover\u002FSKILL.md",[119],{"categoryNo":120,"categoryName":121,"taxonomyType":122,"taxonomyTypeDesc":123},"01JBSEEDCAT000000000000031","产品经理","PROFESSION","适用职业",[125,126,127,128,129,130],"eforge recover","verdict","repair","continue","recovery","prd",{"skillNo":132,"name":133,"nameZh":6,"description":134,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":6,"repositoryNo":12,"starsCount":13,"licenseSpdxId":14,"licenseFileUrl":6,"sourceHtmlUrl":135,"categories":136,"keywords":138,"publishedAt":27},"01M6DZAV6K145TV5MJ3DYK7ZPY","eforge-profile","List, inspect, and switch agent runtime profiles","https:\u002F\u002Fgithub.com\u002Feforge-build\u002Feforge\u002Fblob\u002Fmain\u002Fpackages\u002Fpi-eforge\u002Fskills\u002Feforge-profile\u002FSKILL.md",[137],{"categoryNo":63,"categoryName":64,"taxonomyType":65,"taxonomyTypeDesc":66},[139,140,141,142,143,144],"eforge profile","profile","agent runtime","runtime","switch","list"]