@skitterbyte/skitterspec-github 0.0.0-stage → 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (112) hide show
  1. package/MIGRATION.md +1107 -0
  2. package/README.md +53 -2
  3. package/assets/claude-md-section.md +85 -0
  4. package/assets/commands/allow-main.md +33 -0
  5. package/assets/commands/spec-connect.md +13 -0
  6. package/assets/commands/spec-live.md +14 -0
  7. package/assets/commands/spec-remote-review.md +37 -0
  8. package/assets/commands/spec-skip.md +24 -0
  9. package/assets/core/SETUP.md +112 -0
  10. package/assets/core/env.config.json.example +56 -0
  11. package/assets/core/env.config.md +557 -0
  12. package/assets/core/gating.config.json.example +4 -0
  13. package/assets/core/gating.config.md +81 -0
  14. package/assets/core/github.config.json.example +18 -0
  15. package/assets/core/github.config.md +66 -0
  16. package/assets/hooks/main-guard.cjs +162 -0
  17. package/assets/hooks/review-gate.cjs +146 -0
  18. package/assets/review/page.html +3384 -0
  19. package/assets/rules/commit-trailers.md +103 -0
  20. package/assets/rules/negative-checks.md +69 -0
  21. package/assets/rules/offered-unblocks.md +100 -0
  22. package/assets/rules/spec-planning.md +692 -0
  23. package/assets/rules/spec-reports.md +557 -0
  24. package/assets/skills/no-spec/SKILL.md +246 -0
  25. package/assets/skills/spec/SKILL.md +718 -0
  26. package/assets/skills/spec-bug/SKILL.md +646 -0
  27. package/assets/skills/spec-cancel/SKILL.md +263 -0
  28. package/assets/skills/spec-claim/SKILL.md +122 -0
  29. package/assets/skills/spec-complete/SKILL.md +450 -0
  30. package/assets/skills/spec-diff/SKILL.md +870 -0
  31. package/assets/skills/spec-github-setup/SKILL.md +236 -0
  32. package/assets/skills/spec-hotfix/SKILL.md +668 -0
  33. package/assets/skills/spec-init/SKILL.md +178 -0
  34. package/assets/skills/spec-list/SKILL.md +172 -0
  35. package/assets/skills/spec-next/SKILL.md +685 -0
  36. package/assets/skills/spec-push/SKILL.md +307 -0
  37. package/assets/skills/spec-review/SKILL.md +258 -0
  38. package/assets/skills/spec-reviewed/SKILL.md +284 -0
  39. package/assets/skills/spec-start/SKILL.md +554 -0
  40. package/assets/skills/spec-status/SKILL.md +112 -0
  41. package/assets/skills/spec-sync/SKILL.md +226 -0
  42. package/assets/skills/spec-to-main/SKILL.md +139 -0
  43. package/bin/skitterspec-github.js +61 -0
  44. package/package.json +41 -4
  45. package/src/cli.js +5901 -0
  46. package/src/deprecate.js +138 -0
  47. package/src/env/bootstrap.js +188 -0
  48. package/src/env/building.js +143 -0
  49. package/src/env/classify.js +176 -0
  50. package/src/env/commitcmd.js +108 -0
  51. package/src/env/config.js +753 -0
  52. package/src/env/dev.js +63 -0
  53. package/src/env/hooks.js +226 -0
  54. package/src/env/hotfix.js +411 -0
  55. package/src/env/hotfixland.js +302 -0
  56. package/src/env/integrate.js +126 -0
  57. package/src/env/live.js +504 -0
  58. package/src/env/mainguard.js +299 -0
  59. package/src/env/provision.js +466 -0
  60. package/src/env/proxy.js +192 -0
  61. package/src/env/prune.js +119 -0
  62. package/src/env/registry.js +159 -0
  63. package/src/env/render.js +17 -0
  64. package/src/env/resolve.js +716 -0
  65. package/src/env/review.js +2577 -0
  66. package/src/env/reviewers/coderabbit.js +228 -0
  67. package/src/env/reviewers.js +517 -0
  68. package/src/env/serve.js +1044 -0
  69. package/src/env/supervise.js +157 -0
  70. package/src/env/teardown.js +248 -0
  71. package/src/env/trust.js +87 -0
  72. package/src/gating.js +155 -0
  73. package/src/init.js +1150 -0
  74. package/src/lines-diff.js +114 -0
  75. package/src/prompts.js +129 -0
  76. package/src/vendor/github/api.js +786 -0
  77. package/src/vendor/github/cli-sync.js +1530 -0
  78. package/src/vendor/github/commands.js +44 -0
  79. package/src/vendor/github/config.js +414 -0
  80. package/src/vendor/github/credentials.js +109 -0
  81. package/src/vendor/github/dialect.js +62 -0
  82. package/src/vendor/github/identity.js +38 -0
  83. package/src/vendor/github/mcp.js +85 -0
  84. package/src/vendor/provider-kit/index.js +41 -0
  85. package/src/vendor/provider-kit/src/adapter.js +23 -0
  86. package/src/vendor/provider-kit/src/apply.js +207 -0
  87. package/src/vendor/provider-kit/src/args.js +68 -0
  88. package/src/vendor/provider-kit/src/assignment.js +277 -0
  89. package/src/vendor/provider-kit/src/config.js +198 -0
  90. package/src/vendor/provider-kit/src/credentials.js +404 -0
  91. package/src/vendor/provider-kit/src/doctor.js +35 -0
  92. package/src/vendor/provider-kit/src/http.js +63 -0
  93. package/src/vendor/provider-kit/src/identity.js +93 -0
  94. package/src/vendor/provider-kit/src/md-compare.js +39 -0
  95. package/src/vendor/provider-kit/src/md-tables.js +94 -0
  96. package/src/vendor/provider-kit/src/prompt.js +50 -0
  97. package/src/vendor/provider-kit/src/released.js +269 -0
  98. package/src/vendor/provider-kit/src/releases.js +380 -0
  99. package/src/vendor/provider-kit/src/specs.js +166 -0
  100. package/src/vendor/provider-kit/src/transport.js +22 -0
  101. package/src/vendor/sync-core/index.js +93 -0
  102. package/src/vendor/sync-core/src/base.js +81 -0
  103. package/src/vendor/sync-core/src/compare.js +338 -0
  104. package/src/vendor/sync-core/src/dialect.js +51 -0
  105. package/src/vendor/sync-core/src/fields.js +36 -0
  106. package/src/vendor/sync-core/src/legacy.js +100 -0
  107. package/src/vendor/sync-core/src/normalize.js +998 -0
  108. package/src/vendor/sync-core/src/push.js +85 -0
  109. package/src/vendor/sync-core/src/retarget.js +278 -0
  110. package/src/vendor/sync-core/src/task-block.js +308 -0
  111. package/src/vendor/sync-core/src/verify.js +67 -0
  112. package/src/vendor/sync-core/src/write.js +191 -0
package/README.md CHANGED
@@ -1,3 +1,54 @@
1
- # Temporary Holding Version
1
+ # @skitterbyte/skitterspec-github
2
2
 
3
- This version is a temporary placeholder for this package. An operational version to replace this has been submitted for review and is awaiting a staged release.
3
+ Spec-driven development for Claude Code, with **one-way GitHub sync** — a
4
+ superset of [`@skitterbyte/skitterspec`](https://www.npmjs.com/package/@skitterbyte/skitterspec):
5
+ the base filesystem workflow plus `/spec-push` · `/spec-status` · `/spec-claim`
6
+ and the `spec-sync` CLI. The repo is canonical; GitHub is a generated mirror.
7
+
8
+ Install exactly one distribution — this, the base, or one other superset —
9
+ never two:
10
+
11
+ ```
12
+ npx @skitterbyte/skitterspec-github init
13
+ ```
14
+
15
+ ## What the sync is
16
+
17
+ - A spec is a GitHub **issue**; each phase a **sub-issue**; tasks ride along as
18
+ a task list in the body (still a read-only mirror — the repo wins on every
19
+ push).
20
+ - **Workflow state lives on a Projects v2 board.** An issue is only open or
21
+ closed, so each lifecycle bucket maps to an option of the board's `Status`
22
+ field; `complete` and `cancelled` also close the issue (`completed` /
23
+ `not_planned`). The board is required — one per repo.
24
+ - **One-way**: nothing is read back into the repo. A body edited on GitHub —
25
+ a ticked box included — is reported and replaced on the next push, loudly.
26
+ - **Releases**: CI runs `spec-sync release create <tag>` on a tag push. It makes
27
+ a GitHub Release listing exactly the issues that tag contains, by their
28
+ `Refs: #N` trailers. `release deployed <tag> <env>` then sets a second board
29
+ field, `Deployed`, so release stages never mix into the work state.
30
+ - **Assignment**: `/spec-start` assigns the issue to your login; `/spec-claim`
31
+ hands it on. Only collaborators can be assigned, and that is checked before
32
+ anything is written.
33
+ - **Intake**: `spec-sync intake` lists issues waiting to become specs, routed
34
+ to `/spec`, `/spec-bug` or `/spec-hotfix` by label.
35
+
36
+ ## Setup
37
+
38
+ Everything here is free on a personal account. You need a Projects v2 board
39
+ and a **classic** token with the `repo` and `project` scopes. `/spec-github-setup`
40
+ interviews you and writes `specs/.core/github.config.json` (owner, repo, board
41
+ number, bucket→Status options). Keep the token out of the repo — export
42
+ `GITHUB_TOKEN`, or:
43
+
44
+ ```
45
+ skitterspec-github spec-sync credentials set
46
+ ```
47
+
48
+ `skitterspec-github spec-sync doctor --check-remote` reports readiness across
49
+ every layer, token scopes included.
50
+
51
+ Not yet shipped for GitHub: `retarget`, `reattach`, `spec-sanitise`.
52
+
53
+ This package's `bin/`, `src/` and `assets/` are composed at build time from the
54
+ skitterspec monorepo — see the repo for sources and development.
@@ -0,0 +1,85 @@
1
+ ## Spec workflow
2
+
3
+ Spec-driven development runs through the lifecycle **skills** — use them so
4
+ structure and lifecycle stay consistent. The everyday loop is
5
+ **`spec → start → next → commit → complete`**, with **`/spec-diff`** to read what
6
+ a phase changed and `/spec-connect` when you want to test the spec in a browser.
7
+
8
+ **Skills vs commands.** The lifecycle skills are read by Claude, which exercises
9
+ judgment. `/spec-connect` and `/spec-live` are **slash commands** instead — each
10
+ pre-executes one `spec-env` verb and relays it, so only you can run them; a
11
+ skill that wants one will tell you to type it.
12
+
13
+ **Seeing the work.** A phase is built in its own worktree, so `git diff` in your
14
+ terminal answers about the base branch. **`/spec-diff`** renders that worktree's
15
+ diff as a self-contained HTML page you open locally — or publish, and read on a
16
+ phone. The diff never passes through the model, so the page costs no context
17
+ tokens however large it is; the optional written review is the part that costs,
18
+ and it is offered rather than assumed. `/spec-next` writes the page at the end of
19
+ every phase.
20
+
21
+ **Handing the review back.** The page takes marks: tick `✓ accept` per file as
22
+ you read, note anything against a line or a whole file, answer the questions a
23
+ written review asked — then **end it in a decision**. At the end of a phase the
24
+ buttons are `✓ Commit`, `✓ Commit & Continue` (commit, then build the next
25
+ phase), `↺ Request changes` and `… Discuss first`. A spec that has just been
26
+ written gets `✓ Commit & Start` instead — the `commit-start` verdict, which is
27
+ the `commit && /spec-start` you would otherwise type. A **served** page hands
28
+ the pass to the engine, which **holds** it and shows a six-digit code. Committing
29
+ is unavailable while a note is open — you asked for something, so it cannot also
30
+ be fine — and it hands off to your own commit skill (`review.commitWith`,
31
+ `/commit` by default) rather than a copy living here. Fixes come back as
32
+ resolutions, so the next render shows each note struck through with what changed.
33
+ An accept remembers the file's content, so it lapses by itself when that file
34
+ changes again. The marks are information — nothing gates on them; the verdict is
35
+ the one thing you choose, once.
36
+
37
+ **A second opinion, when you want one** (`review.reviewers`, empty by default).
38
+ Point it at a code reviewer that runs from your terminal — CodeRabbit's CLI has
39
+ a free tier and `{ "use": "coderabbit" }` is the whole setup; anything printing
40
+ [rdjsonl](https://github.com/reviewdog/reviewdog) works too — and its findings
41
+ land on the page beside your own notes, each badged with the tool that found it
42
+ and linked to the line it is about. `/spec-next` runs them once per phase;
43
+ `/spec-diff --reviewers` is the mid-phase ask. **They never block a commit** —
44
+ reply to one and your reply does, because then a person has asked for something.
45
+ A reviewer that could not run says `did not run — <why>` rather than passing as
46
+ clean, because on the page you commit from those two must not look alike.
47
+ Adding one sends your diff to whatever the command talks to, which is why the
48
+ list starts empty and `init` never writes one.
49
+
50
+ **Above the verdicts sits one line that is not a verdict.** `▶ Put it live`
51
+ commits the phase, checks the branch out where your dev server can see it, and
52
+ hands you back the same page with the same options — so you can judge the change
53
+ by *using* it, not only by reading it. It clears no gate: you have looked at it
54
+ running and concluded nothing, so the phase still owes an answer.
55
+
56
+ **Every render lists where the page can be read**, labelled, in a fixed order —
57
+ `local`, `network`, `remote` — each either a URL or the one command that turns it
58
+ on, plus a `live:` line saying whether the change is also running. `local` and
59
+ `network` are two doors into one room: the same server and the same waiting
60
+ verdict, so one wait covers both. `remote` is a published page, a second store —
61
+ a verdict there needs `/spec-reviewed`, and it stays off until someone types
62
+ **`/spec-remote-review`**, which toggles it. Publishing is permitted by that
63
+ command, never performed by it: a published page is one this tooling cannot
64
+ remove.
65
+
66
+ **One ending.** Every spec skill finishes with the same block — a verdict
67
+ (`✅` · `⚠️` · `❌` · `⏸`), then a table of the fields that skill declares,
68
+ ending on the one thing to do next. A refusal emits it too, so "nothing
69
+ happened" is reported rather than absent, and `Follow-ups` is always there
70
+ because a recorded `none` is a decision. Skills stay quiet while they run. The
71
+ shape lives in **`.claude/rules/spec-reports.md`**.
72
+
73
+ The skill table, the spec type/folder conventions and the per-spec isolation
74
+ model all live in **`.claude/rules/spec-planning.md`**, the canonical reference
75
+ every spec skill points at. Tailor its per-phase test commands to this stack.
76
+
77
+ **Release gating** *(only when `specs/.core/gating.config.json` exists)* — each
78
+ spec records whether it ships behind a feature flag, as
79
+ `> **Gating:** <flag name>` or `> **Gating:** none: <one-line reason>`. `/spec`,
80
+ `/spec-bug` and `/spec-hotfix` ask; `/spec-review`, `/spec-start` and
81
+ `/spec-complete` report a spec that has no answer, and never block over it.
82
+ `skitterspec gating check` lists them and always exits 0. The point is that the
83
+ question is **on the record**: a missing line is an oversight, a reason is a
84
+ decision. Skitterspec never reads your flag system — it asks and cites the doc
85
+ you point it at. Without that config, none of this appears.
@@ -0,0 +1,33 @@
1
+ ---
2
+ description: Allow writes on the base branch for this session — bare allows it with no reason, a reason records why, `off` clears it
3
+ argument-hint: "[<reason> | off]"
4
+ allowed-tools: Bash({{exec}} skitterspec spec-env main allow:*)
5
+ disable-model-invocation: true
6
+ ---
7
+ !`{{exec}} skitterspec spec-env main allow $ARGUMENTS`
8
+
9
+ Relay the engine output above verbatim. Add nothing and run nothing else.
10
+
11
+ **Only you can run this, and that is the whole guard.** The main-guard hook
12
+ refuses an `Edit` or a `Write` in the primary checkout while it sits on the base
13
+ branch, and it names two exits: move the work with `/no-spec` or `/spec-start`,
14
+ or have you lift the guard. Claude can take the first exit on its own and can
15
+ never take the second — a guard the model can lift is decoration, which is the
16
+ same line `/spec-reviewed` draws.
17
+
18
+ **Give it a reason.** `/allow-main fixing the lockfile by hand` records why; bare
19
+ records `none given`. The reason is the part a reviewer can argue with, exactly
20
+ as with a `Gating:` header — and it is what you will read when you wonder later
21
+ why the base branch has an uncommitted file on it.
22
+
23
+ **It lapses with the session where it can.** The allow is recorded against this
24
+ session, so it ends when the session does. Where the harness exposes no session
25
+ id it degrades to a repo-wide allow that outlives the session and is cleared only
26
+ by `/allow-main off`; the engine says which kind you got, so do not read a bare
27
+ "allowed" as temporary.
28
+
29
+ **It is machine-local and gitignored.** Unlike `/spec-remote-review`, this writes
30
+ nothing anyone else pulls: it is your decision about your checkout, not the
31
+ project's policy. The project-wide switch is `guards.mainIsLandingZone` in
32
+ `specs/.core/env.config.json`, and turning that off is a different, committed
33
+ decision.
@@ -0,0 +1,13 @@
1
+ ---
2
+ description: Expose one spec's dev servers on the canonical localhost ports — bare uses the spec you are on, `main` hands them back
3
+ argument-hint: "[<spec> | main]"
4
+ allowed-tools: Bash({{exec}} skitterspec spec-env connect:*)
5
+ disable-model-invocation: true
6
+ ---
7
+ !`{{exec}} skitterspec spec-env connect $ARGUMENTS`
8
+
9
+ Relay the engine output above verbatim. Add nothing and run nothing else.
10
+
11
+ Only if it reports a **canonical port is in use**: say that the main checkout's
12
+ dev server still holds that port, and that stopping it and re-running is the fix
13
+ (the proxy cannot share a port main is bound to).
@@ -0,0 +1,14 @@
1
+ ---
2
+ description: Put one spec live on the already-running dev server — bare takes the spec you are on, `<spec>` takes that one, `main` hands the instance back
3
+ argument-hint: "[<spec> | main | status | release | abort]"
4
+ allowed-tools: Bash({{exec}} skitterspec spec-env live:*)
5
+ disable-model-invocation: true
6
+ ---
7
+ !`{{exec}} skitterspec spec-env live $ARGUMENTS`
8
+
9
+ Relay the engine output above verbatim. Add nothing and run nothing else.
10
+
11
+ The engine enforces every refusal itself and prints why — a hotfix, a stateful
12
+ spec (`Stack: worktree + docker`), a branch touching migrations, a dirty tree, a
13
+ rebase conflict, or another spec already holding the instance. Do not re-explain
14
+ or work around any of them.
@@ -0,0 +1,37 @@
1
+ ---
2
+ description: Permit or forbid publishing this spec's review for a reader off your network — bare toggles it, `on`/`off` set it explicitly
3
+ argument-hint: "[on | off]"
4
+ allowed-tools: Bash({{exec}} skitterspec spec-env review allow remote:*)
5
+ disable-model-invocation: true
6
+ ---
7
+ !`{{exec}} skitterspec spec-env review allow remote --set "$ARGUMENTS"`
8
+
9
+ Relay the engine output above verbatim. Add nothing to it.
10
+
11
+ **Then one thing, and only when the engine asked for it.** Where the output
12
+ carries a `review:` and a `publish:` line, typing this command **is** the ask
13
+ to publish that page: the banner named this command beside a review the reader
14
+ could not reach, so the link is what they are waiting for. Publish it exactly
15
+ as `/spec-diff` §6 describes (run the `publish:` command, publish the copy it
16
+ names with a store, write the URL file), then re-emit the review banner with
17
+ all three tiers, `remote` now carrying the URL. A wait already running keeps
18
+ running; do not restart it or the server. If the harness refuses the publish,
19
+ say so in one line and keep the banner as it was, because local and network
20
+ still work.
21
+
22
+ With no `publish:` line, run nothing else. Nothing has a page to publish, or
23
+ the tier was turned off.
24
+
25
+ **Bare toggles.** That is the common case: you are looking at a render whose
26
+ `remote:` line says which way it currently is, and what you want is the other
27
+ one. `on` and `off` are there for when you are not looking at it.
28
+
29
+ **It is per spec.** The engine resolves the spec from the worktree you are
30
+ standing in and records the permission in the gitignored review store, so
31
+ the base branch is untouched and no other spec may publish because of it.
32
+ `skitterspec spec-env review allow remote --project` is the committed,
33
+ every-spec form, for a team that wants it.
34
+
35
+ **A published page is one skitterspec cannot delete**, and a verdict pressed
36
+ on one needs `/spec-reviewed`, because nothing pushes from an artifact's store
37
+ into a conversation.
@@ -0,0 +1,24 @@
1
+ ---
2
+ description: Move on from a phase without a verdict, with the reason on the record — clears the review gate
3
+ argument-hint: "\"<reason>\""
4
+ allowed-tools: Bash({{exec}} skitterspec spec-env review skip:*)
5
+ disable-model-invocation: true
6
+ ---
7
+ !`{{exec}} skitterspec spec-env review skip "$ARGUMENTS"`
8
+
9
+ Relay the engine output above verbatim. Add nothing and run nothing else.
10
+
11
+ **It refuses with no reason, and that refusal is the feature.** A skip with no
12
+ reason is indistinguishable from nobody having looked — where
13
+ `none: additive, nothing to revert` is a decision a reviewer can argue with. If
14
+ the engine asked for a reason, relay that and stop; do not supply one on the
15
+ operator's behalf.
16
+
17
+ **It is one of exactly two exits**, and the other is a committing verdict on the
18
+ page. Nothing else discharges a phase's obligation — not a mid-run `Continue`,
19
+ not an action, not a render.
20
+
21
+ **Only you can run it.** Like `/allow-main`, this lifts a guard aimed at Claude,
22
+ so Claude must not be able to lift it. `/spec-connect` and `/spec-live` are
23
+ user-only for the milder reason that there is no judgement to apply; this one is
24
+ user-only because of who the guard is for.
@@ -0,0 +1,112 @@
1
+ # Setting up GitHub sync (one-way)
2
+
3
+ The repo is the source of truth; GitHub is a generated mirror. A spec becomes a
4
+ GitHub **issue**, each phase a **sub-issue**, and a spec's lifecycle bucket a
5
+ **Status** on a Projects v2 board. Nothing is read back and merged: a person's
6
+ edit on GitHub is reported, then replaced by the next push.
7
+
8
+ What you need, all free on a personal account:
9
+
10
+ - the repo, on GitHub;
11
+ - a **Projects v2 board** owned by the same account — one per repo;
12
+ - a **classic** personal access token with the `repo` and `project` scopes.
13
+
14
+ Do the steps in order — each one is checked by the next.
15
+
16
+ ## 1. Install the package
17
+
18
+ ```
19
+ pnpm add -D @skitterbyte/skitterspec-github
20
+ pnpm exec skitterspec init --isolation
21
+ ```
22
+
23
+ Install exactly one distribution: the base, or one superset. This one provides
24
+ both `skitterspec-github` and `skitterspec`.
25
+
26
+ ## 2. Make the board
27
+
28
+ On GitHub: **Projects → New project → Board**, owned by the repo's owner. Note
29
+ its number from the URL (`…/projects/7` → `7`).
30
+
31
+ - The **Status** field it starts with is where a spec's state lives. Add
32
+ `Backlog` and `Cancelled` options beside `Todo`, `In Progress` and `Done` —
33
+ or map `backlog` to `Todo` in step 4.
34
+ - Under the board's **Workflows**, turn off *Item closed* and *Pull request
35
+ merged* (both set Done): the engine sets Status itself, and a second writer
36
+ is one the next push overrides.
37
+ - Optional, for releases: a second single-select field, **Deployed**, with
38
+ options such as `Test`, `Demo`, `Prod`. Keep release stages out of Status —
39
+ otherwise a finished phase reads as deployed.
40
+
41
+ ## 3. The token
42
+
43
+ Create a **classic** token at https://github.com/settings/tokens with the
44
+ `repo` and `project` scopes. Fine-grained tokens are documented only for
45
+ org-owned boards.
46
+
47
+ Then store it **yourself, in your own terminal** — never paste it into a chat:
48
+
49
+ ```
50
+ pnpm exec skitterspec-github spec-sync credentials set --owner <owner>
51
+ # GitHub token for github.com/<owner> (classic, repo + project; hidden): ●●●●●●●●
52
+ ```
53
+
54
+ An exported `GITHUB_TOKEN` or `GH_TOKEN` works instead and wins over the store.
55
+ `credentials status` shows which one is in use, as a fingerprint.
56
+
57
+ ## 4. Configure — run `/spec-github-setup`
58
+
59
+ It reads the owner and repo off your remote, asks for the board number,
60
+ validates every bucket's Status option against the board, and writes
61
+ `specs/.core/github.config.json` through `spec-sync init-config`. By hand:
62
+
63
+ ```
64
+ pnpm exec skitterspec-github spec-sync init-config \
65
+ --owner <owner> --repo <repo> --project 7 [--state backlog=Todo]
66
+ ```
67
+
68
+ **Commit the file.** Spec worktrees fork from commits, so an uncommitted config
69
+ is invisible in every one of them and sync reports itself off there.
70
+
71
+ ## 5. Check — `spec-sync doctor`
72
+
73
+ ```
74
+ pnpm exec skitterspec-github spec-sync doctor --check-remote
75
+ ```
76
+
77
+ Every row names its own fix: the config, the token, its scopes (classic tokens
78
+ only — a fine-grained token's scopes cannot be read), the board's Status
79
+ options, and the labels.
80
+
81
+ ## 6. Push a spec
82
+
83
+ `/spec` links a new spec as it writes it. For an existing one, `/spec-push`.
84
+ A repo moving from another tracker keeps its old stamps on finished specs; push
85
+ each backlog and in-progress spec to link it here.
86
+
87
+ ## Release smoke checklist
88
+
89
+ Run against a throwaway repo and board before cutting a release of this
90
+ provider.
91
+
92
+ 1. **Doctor** — every row ok, including Token scopes and Board states.
93
+ 2. **States** — `spec-sync states` lists the options and every bucket row
94
+ reads `ok`.
95
+ 3. **Mint** — on a test spec with at least one phase and a task checklist:
96
+ plan + apply. Expect a `spec`-labelled issue, one `phase`-labelled sub-issue
97
+ per phase linked under it, all on the board with their Status, and the
98
+ frontmatter stamped `#N`.
99
+ 4. **Bucket move** — move the spec to `complete/` and push: Status `Done` **and**
100
+ the issue closed as completed. Move it back: reopened, Status restored.
101
+ 5. **Adopt + preserve** — hand-create an issue with a body, stamp it onto a
102
+ spec, run `spec-sync preserve`, then push: the original survives as a
103
+ comment, and a second `preserve` says already preserved.
104
+ 6. **Verify** — save a read-back (`{ "issue": "<body>", "subIssues": { "<ref>":
105
+ "<body>" } }`, keyed by the phase file's basename **without** `.md`) and run
106
+ `spec-sync verify`: every body round-trips intact.
107
+ 7. **Drift** — tick a task box on GitHub, then `spec-sync status --remote`
108
+ reports the body edited; the next push replaces it and says so.
109
+ 8. **Released** — over a range with `Refs: #N` trailers and an older
110
+ `Refs: KEY-N` one: tickets listed, the old one counted as historical.
111
+ 9. **Intake** — label an issue with `intake.label` (and one with a bug label):
112
+ `spec-sync intake` lists both, routed to `/spec` and `/spec-bug`.
@@ -0,0 +1,56 @@
1
+ {
2
+ "mode": "worktree",
3
+ "worktree": {
4
+ "root": "../{repo}-wt",
5
+ "folderPattern": "{slug}"
6
+ },
7
+ "docker": {
8
+ "enabled": true,
9
+ "composeFile": "docker-compose.yml",
10
+ "projectNamePattern": "{repoSlug}_{slug}",
11
+ "portBase": 3000,
12
+ "portsPerSpec": 10,
13
+ "envFile": ".env",
14
+ "backupCommand": ""
15
+ },
16
+ "seedFiles": {
17
+ "mode": "symlink",
18
+ "files": [
19
+ ".env"
20
+ ]
21
+ },
22
+ "setup": [],
23
+ "dev": [],
24
+ "proxy": {
25
+ "enabled": true,
26
+ "host": "127.0.0.1"
27
+ },
28
+ "registry": ".spec-env/registry.json",
29
+ "branch": {
30
+ "pattern": "{type}/{slug}",
31
+ "identifierField": "github_identifier"
32
+ },
33
+ "spec": {
34
+ "companionPaths": [
35
+ "specs/.core/github-base/{identifier}.base.json"
36
+ ]
37
+ },
38
+ "baseBranch": "",
39
+ "guards": {
40
+ "refuseTeardownIfDirty": true,
41
+ "refuseTeardownIfUnpushed": true
42
+ },
43
+ "review": {
44
+ "reader": "detect",
45
+ "servePort": "auto",
46
+ "serve": "always",
47
+ "allowNetwork": true,
48
+ "allowRemote": false,
49
+ "commitWith": "/commit",
50
+ "required": true,
51
+ "reviewers": []
52
+ },
53
+ "live": {
54
+ "migrations": []
55
+ }
56
+ }