@skitterbyte/skitterspec-github 1.3.0 → 2.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.
- package/MIGRATION.md +141 -1
- package/README.md +9 -7
- package/assets/core/SETUP.md +10 -12
- package/assets/core/github.config.md +50 -69
- package/assets/rules/spec-planning.md +13 -3
- package/assets/skills/spec-github-setup/SKILL.md +6 -4
- package/assets/skills/spec-list/SKILL.md +28 -4
- package/assets/skills/spec-status/SKILL.md +28 -27
- package/assets/skills/spec-sync/SKILL.md +11 -27
- package/package.json +1 -1
- package/src/vendor/github/api.js +86 -123
- package/src/vendor/github/cli-sync.js +87 -81
- package/src/vendor/github/config.js +5 -57
- package/src/vendor/github/mcp.js +1 -5
- package/src/vendor/provider-kit/src/config.js +101 -48
- package/src/vendor/provider-kit/src/list-assignee.js +71 -0
- package/src/vendor/provider-kit/src/list-rows.js +35 -0
- package/src/vendor/provider-kit/src/released.js +27 -77
- package/src/vendor/provider-kit/src/specs.js +89 -7
- package/src/vendor/sync-core/index.js +3 -4
- package/src/vendor/sync-core/src/compare.js +6 -6
- package/src/vendor/sync-core/src/normalize.js +30 -57
- package/src/vendor/provider-kit/src/releases.js +0 -595
package/MIGRATION.md
CHANGED
|
@@ -1,5 +1,104 @@
|
|
|
1
1
|
# Migration guide
|
|
2
2
|
|
|
3
|
+
## `@skitterbyte/skitterspec-github` v1 → v2 (tell, don't track)
|
|
4
|
+
|
|
5
|
+
Skitterspec now tells GitHub about **its own** transitions and nothing
|
|
6
|
+
else. It writes nothing about releases or deployments, and it never reads a
|
|
7
|
+
ticket's state back.
|
|
8
|
+
|
|
9
|
+
### Breaking change 1 — The `release create|deployed|complete|reconcile` verbs are removed
|
|
10
|
+
|
|
11
|
+
They exit 1 with one line naming `spec-sync released <range> --json`. A pipeline
|
|
12
|
+
still calling them goes red rather than silently believing it mirrors
|
|
13
|
+
anything. **To migrate**, replace the step with your own script over the
|
|
14
|
+
release's ticket list:
|
|
15
|
+
|
|
16
|
+
```sh
|
|
17
|
+
skitterspec-github spec-sync released "<previous-tag>..<tag>" --json
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
Each ticket row now carries `spec` and `url` (both `null` for a ref no spec has
|
|
21
|
+
linked), so the script needs no second lookup. Set whatever GitHub field,
|
|
22
|
+
state or release object your process uses from that list. The checkout needs
|
|
23
|
+
`fetch-depth: 0` so the previous tag is visible.
|
|
24
|
+
|
|
25
|
+
### Breaking change 2 — The `releases` block (`deployedField`, `series`) and `release.stages` are retired
|
|
26
|
+
|
|
27
|
+
The keys are ignored, like any unknown key, so a config carrying them still
|
|
28
|
+
loads. `spec-sync doctor` names them as unused config (a `warn`, never a
|
|
29
|
+
failure). Delete them when you remove the CI step.
|
|
30
|
+
|
|
31
|
+
### Breaking change 3 — no state drift
|
|
32
|
+
|
|
33
|
+
`spec-sync status --remote` and `/spec-status` no longer compare the tracker's
|
|
34
|
+
state with the spec's. A ticket someone moved on GitHub is not reported, and
|
|
35
|
+
push still resends state only when the spec itself moves. The edited-description
|
|
36
|
+
warning is unchanged.
|
|
37
|
+
|
|
38
|
+
## `@skitterbyte/skitterspec-azure-boards` v1 → v2 (tell, don't track)
|
|
39
|
+
|
|
40
|
+
Skitterspec now tells Azure Boards about **its own** transitions and nothing
|
|
41
|
+
else. It writes nothing about releases or deployments, and it never reads a
|
|
42
|
+
ticket's state back.
|
|
43
|
+
|
|
44
|
+
### Breaking change 1 — The `release create|deployed|complete` verbs are removed
|
|
45
|
+
|
|
46
|
+
They exit 1 with one line naming `spec-sync released <range> --json`. A pipeline
|
|
47
|
+
still calling them goes red rather than silently believing it mirrors
|
|
48
|
+
anything. **To migrate**, replace the step with your own script over the
|
|
49
|
+
release's ticket list:
|
|
50
|
+
|
|
51
|
+
```sh
|
|
52
|
+
skitterspec-azure-boards spec-sync released "<previous-tag>..<tag>" --json
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
Each ticket row now carries `spec` and `url` (both `null` for a ref no spec has
|
|
56
|
+
linked), so the script needs no second lookup. Set whatever Azure Boards field,
|
|
57
|
+
state or release object your process uses from that list. The checkout needs
|
|
58
|
+
`fetch-depth: 0` so the previous tag is visible.
|
|
59
|
+
|
|
60
|
+
### Breaking change 2 — The `releases` block (`workItemType`, `series`, `ticketTag`, `deployedField`) and `release.stages` are retired
|
|
61
|
+
|
|
62
|
+
The keys are ignored, like any unknown key, so a config carrying them still
|
|
63
|
+
loads. `spec-sync doctor` names them as unused config (a `warn`, never a
|
|
64
|
+
failure). Delete them when you remove the CI step.
|
|
65
|
+
|
|
66
|
+
### Breaking change 3 — no state drift
|
|
67
|
+
|
|
68
|
+
`spec-sync status --remote` and `/spec-status` no longer compare the tracker's
|
|
69
|
+
state with the spec's. A ticket someone moved on Azure Boards is not reported, and
|
|
70
|
+
push still resends state only when the spec itself moves. The edited-description
|
|
71
|
+
warning is unchanged.
|
|
72
|
+
|
|
73
|
+
## `@skitterbyte/skitterspec-jira` v1 → v2 (tell, don't track)
|
|
74
|
+
|
|
75
|
+
Skitterspec now tells Jira about **its own** transitions and nothing else. It
|
|
76
|
+
writes nothing about releases or deployments, and it never reads an issue's
|
|
77
|
+
status back.
|
|
78
|
+
|
|
79
|
+
### Breaking change 1 — no status drift
|
|
80
|
+
|
|
81
|
+
`spec-sync status --remote` and `/spec-status` no longer compare Jira's status
|
|
82
|
+
with the spec's. An issue someone moved on Jira is not reported, and push still
|
|
83
|
+
transitions it only when the spec itself moves. The edited-description warning
|
|
84
|
+
is unchanged.
|
|
85
|
+
|
|
86
|
+
### Breaking change 2 — `release.stages` retired
|
|
87
|
+
|
|
88
|
+
It was accepted and validated before, and never acted on. It is now ignored
|
|
89
|
+
like any unknown key, and `spec-sync doctor` names it as unused config (a
|
|
90
|
+
`warn`, never a failure). Delete it.
|
|
91
|
+
|
|
92
|
+
### Also — `released --json` names the spec
|
|
93
|
+
|
|
94
|
+
Each ticket row now carries `spec` and `url` (both `null` for a ref no spec has
|
|
95
|
+
linked), so CI can record a release, for example as a fix version, without a
|
|
96
|
+
second lookup:
|
|
97
|
+
|
|
98
|
+
```sh
|
|
99
|
+
skitterspec-jira spec-sync released "<previous-tag>..<tag>" --json
|
|
100
|
+
```
|
|
101
|
+
|
|
3
102
|
## `@skitterbyte/skitterspec` v23 → v24 (hotfix land runs the release itself)
|
|
4
103
|
|
|
5
104
|
### Breaking change 1 — `spec-env hotfix land` runs its steps, and holds before the carry
|
|
@@ -275,7 +374,48 @@ can run it.
|
|
|
275
374
|
committed file, so it changes for everyone who pulls and leaves that tree dirty.
|
|
276
375
|
The engine says so when it does.
|
|
277
376
|
|
|
278
|
-
## `@skitterbyte/skitterspec-linear` v18 → v19 (hotfix land runs the release itself)
|
|
377
|
+
## `@skitterbyte/skitterspec-linear` v18 → v19 (tell, don't track; hotfix land runs the release itself)
|
|
378
|
+
|
|
379
|
+
Skitterspec now tells Linear about **its own** transitions and nothing
|
|
380
|
+
else. It writes nothing about releases or deployments, and it never reads a
|
|
381
|
+
ticket's state back.
|
|
382
|
+
|
|
383
|
+
### Breaking change 1 — The `spec-sync stage` verb is removed
|
|
384
|
+
|
|
385
|
+
It exits 1 with one line naming `spec-sync released <range> --json`. A pipeline
|
|
386
|
+
still calling it goes red rather than silently believing it mirrors
|
|
387
|
+
anything. **To migrate**, replace the step with your own script over the
|
|
388
|
+
release's ticket list:
|
|
389
|
+
|
|
390
|
+
```sh
|
|
391
|
+
skitterspec-linear spec-sync released "<previous-tag>..<tag>" --json
|
|
392
|
+
```
|
|
393
|
+
|
|
394
|
+
Each ticket row now carries `spec` and `url` (both `null` for a ref no spec has
|
|
395
|
+
linked), so the script needs no second lookup. Set whatever Linear field,
|
|
396
|
+
state or release object your process uses from that list. The checkout needs
|
|
397
|
+
`fetch-depth: 0` so the previous tag is visible.
|
|
398
|
+
|
|
399
|
+
### Breaking change 2 — `release.stages` (the deployment ladder) is retired
|
|
400
|
+
|
|
401
|
+
The keys are ignored, like any unknown key, so a config carrying them still
|
|
402
|
+
loads. `spec-sync doctor` names them as unused config (a `warn`, never a
|
|
403
|
+
failure). Delete them when you remove the CI step.
|
|
404
|
+
|
|
405
|
+
### Breaking change 3 — no state drift
|
|
406
|
+
|
|
407
|
+
`spec-sync status --remote` and `/spec-status` no longer compare the tracker's
|
|
408
|
+
state with the spec's. A ticket someone moved on Linear is not reported, and
|
|
409
|
+
push still resends state only when the spec itself moves. The edited-description
|
|
410
|
+
warning is unchanged.
|
|
411
|
+
|
|
412
|
+
**A ladder rung no longer reads as `complete`.** Where a state was a
|
|
413
|
+
`release.stages` rung, the live `spec-sync list` now shows it as unmapped. To
|
|
414
|
+
keep it reading as finished, list it as an alias:
|
|
415
|
+
`"complete": ["Done", "On Test"]`. `init-config --stage` is gone too, and is
|
|
416
|
+
refused as an unknown flag.
|
|
417
|
+
|
|
418
|
+
### Also — hotfix land runs the release itself
|
|
279
419
|
|
|
280
420
|
The same change as `@skitterbyte/skitterspec` v23 → v24 above — this
|
|
281
421
|
distribution composes the same engine. Read that entry; nothing here is
|
package/README.md
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Spec-driven development for Claude Code, with **one-way GitHub sync** — a
|
|
4
4
|
superset of [`@skitterbyte/skitterspec`](https://www.npmjs.com/package/@skitterbyte/skitterspec):
|
|
5
|
-
the base filesystem workflow plus `/spec-push` · `/spec-status` · `/spec-claim`
|
|
5
|
+
the base filesystem workflow plus `/spec-push` · `/spec-status` · `/spec-list` · `/spec-claim`
|
|
6
6
|
and the `spec-sync` CLI. The repo is canonical; GitHub is a generated mirror.
|
|
7
7
|
|
|
8
8
|
Install exactly one distribution — this, the base, or one other superset —
|
|
@@ -21,12 +21,14 @@ npx @skitterbyte/skitterspec-github init
|
|
|
21
21
|
closed, so each lifecycle bucket maps to an option of the board's `Status`
|
|
22
22
|
field; `complete` and `cancelled` also close the issue (`completed` /
|
|
23
23
|
`not_planned`). The board is required — one per repo.
|
|
24
|
-
- **One-way**: nothing is read back into the repo
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
24
|
+
- **One-way**: nothing is read back into the repo, and skitterspec tells the
|
|
25
|
+
board only about its own transitions — a card moved by hand is left alone. A
|
|
26
|
+
body edited on GitHub — a ticked box included — is reported and replaced on
|
|
27
|
+
the next push, loudly.
|
|
28
|
+
- **Releases are yours to record**: `spec-sync released <range> --json` lists
|
|
29
|
+
exactly the issues a range contains, by their `Refs: #N` trailers, each with
|
|
30
|
+
its spec and url. Your CI pipes that into whatever records a release or a
|
|
31
|
+
deploy; skitterspec writes neither.
|
|
30
32
|
- **Assignment**: `/spec-start` assigns the issue to your login; `/spec-claim`
|
|
31
33
|
hands it on. Only collaborators can be assigned, and that is checked before
|
|
32
34
|
anything is written.
|
package/assets/core/SETUP.md
CHANGED
|
@@ -34,16 +34,13 @@ its number from the URL (`…/projects/7` → `7`).
|
|
|
34
34
|
- Under the board's **Workflows**, turn off *Item closed* and *Pull request
|
|
35
35
|
merged* (both set Done): the engine sets Status itself, and a second writer
|
|
36
36
|
is one the next push overrides.
|
|
37
|
-
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
the semantics and a copy-paste workflow. The workflow's secret must be a
|
|
45
|
-
classic PAT (`repo` + `project`): the Actions `GITHUB_TOKEN` cannot write a
|
|
46
|
-
user-owned Projects board.
|
|
37
|
+
- Deploy tracking is yours to add, not skitterspec's. If you want it on the
|
|
38
|
+
board, give it a field of its own (a `Deployed` single-select, say) and set
|
|
39
|
+
it from your CI using `spec-sync released <range> --json` — keep release
|
|
40
|
+
stages out of Status, or a finished phase reads as deployed.
|
|
41
|
+
`github.config.md` → "Releases and deploys" has the details. A CI secret for
|
|
42
|
+
this must be a classic PAT (`repo` + `project`): the Actions `GITHUB_TOKEN`
|
|
43
|
+
cannot write a user-owned Projects board.
|
|
47
44
|
|
|
48
45
|
## 3. The token
|
|
49
46
|
|
|
@@ -111,9 +108,10 @@ provider.
|
|
|
111
108
|
6. **Verify** — save a read-back (`{ "issue": "<body>", "subIssues": { "<ref>":
|
|
112
109
|
"<body>" } }`, keyed by the phase file's basename **without** `.md`) and run
|
|
113
110
|
`spec-sync verify`: every body round-trips intact.
|
|
114
|
-
7. **
|
|
111
|
+
7. **Edited body** — tick a task box on GitHub, then `spec-sync status --remote`
|
|
115
112
|
reports the body edited; the next push replaces it and says so.
|
|
116
113
|
8. **Released** — over a range with `Refs: #N` trailers and an older
|
|
117
|
-
`Refs: KEY-N` one: tickets listed, the old one counted as historical.
|
|
114
|
+
`Refs: KEY-N` one: tickets listed, the old one counted as historical. With
|
|
115
|
+
`--json`, each linked ticket names its spec and url.
|
|
118
116
|
9. **Intake** — label an issue with `intake.label` (and one with a bug label):
|
|
119
117
|
`spec-sync intake` lists both, routed to `/spec` and `/spec-bug`.
|
|
@@ -30,9 +30,9 @@ Option names must match the field's options exactly (case aside). An unknown
|
|
|
30
30
|
name is refused and the refusal lists the options the field does have.
|
|
31
31
|
|
|
32
32
|
**Map work states, not pipeline stages.** "On Test" is where a *release* is,
|
|
33
|
-
not where a spec's work is.
|
|
34
|
-
that
|
|
35
|
-
deployed.
|
|
33
|
+
not where a spec's work is. If you track deploys on the board, keep them on a
|
|
34
|
+
field of your own that your CI sets — never as a Status option, or a finished
|
|
35
|
+
phase will read as deployed. See "Releases and deploys" below.
|
|
36
36
|
|
|
37
37
|
## Fields
|
|
38
38
|
|
|
@@ -44,83 +44,64 @@ deployed.
|
|
|
44
44
|
| `github.statusField` | `Status` | The single-select carrying workflow state. |
|
|
45
45
|
| `github.labels.spec` / `.phase` | `spec` / `phase` | Labels that tell a spec issue from a phase. Empty string = no label. |
|
|
46
46
|
| `github.issueTypes.spec` / `.phase` | — | Issue type names. **Org-owned repos only** — naming one on a personal repo is refused by GitHub. |
|
|
47
|
-
| `states.<bucket>` | see table | Board Status option per lifecycle bucket. |
|
|
47
|
+
| `states.<bucket>` | see table | Board Status option per lifecycle bucket — a string, or an array whose first name is written and whose rest are read-only aliases. |
|
|
48
48
|
| `intake.label` | — | The label `/spec --from-issue` lists. |
|
|
49
49
|
| `intake.bugLabels` / `.hotfixLabels` | `["bug"]` / `[]` | Labels that route an adopted issue to `/spec-bug` / `/spec-hotfix`. |
|
|
50
50
|
| `auth.tokenEnv` | `GITHUB_TOKEN` | Env var holding the token; `GH_TOKEN` is read after it. |
|
|
51
51
|
| `apply.transport` | — | `api` or `mcp`; unset = API when a token resolves. |
|
|
52
52
|
| `sync.baseDir` | `specs/.core/github-base` | Last-pushed snapshots. Commit them. |
|
|
53
53
|
| `sync.fieldOwnership` | all `push` | Per-field ownership; `"none"` declines one (e.g. `assignee`). |
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
```json
|
|
66
|
-
"releases": {
|
|
67
|
-
"series": [
|
|
68
|
-
{ "tagPrefix": "myapp@",
|
|
69
|
-
"envs": { "staged": "Staged", "published": "Published" },
|
|
70
|
-
"npm": "@scope/myapp" }
|
|
71
|
-
]
|
|
54
|
+
|
|
55
|
+
## More than one name per bucket — read-only aliases
|
|
56
|
+
|
|
57
|
+
A board usually has more states than the four buckets: "Blocked", "Next
|
|
58
|
+
Sprint", "Released". A bucket's value may be an **array** instead of a string:
|
|
59
|
+
|
|
60
|
+
```jsonc
|
|
61
|
+
"states": {
|
|
62
|
+
"in-progress": ["Active", "Blocked"],
|
|
63
|
+
"complete": ["Closed", "Released"]
|
|
72
64
|
}
|
|
73
65
|
```
|
|
74
66
|
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
- A
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
```yaml
|
|
101
|
-
on:
|
|
102
|
-
schedule:
|
|
103
|
-
- cron: '17 * * * *'
|
|
104
|
-
workflow_dispatch:
|
|
105
|
-
permissions:
|
|
106
|
-
contents: read
|
|
107
|
-
jobs:
|
|
108
|
-
reconcile:
|
|
109
|
-
runs-on: ubuntu-latest
|
|
110
|
-
steps:
|
|
111
|
-
- uses: actions/checkout@v7
|
|
112
|
-
with:
|
|
113
|
-
fetch-depth: 0
|
|
114
|
-
# …install your toolchain…
|
|
115
|
-
- env:
|
|
116
|
-
GITHUB_TOKEN: ${{ secrets.YOUR_PAT_SECRET }}
|
|
117
|
-
run: |
|
|
118
|
-
if [ -z "$GITHUB_TOKEN" ]; then
|
|
119
|
-
echo "::notice::no PAT secret — reconcile skipped"; exit 0
|
|
120
|
-
fi
|
|
121
|
-
skitterspec-github spec-sync release reconcile --apply
|
|
67
|
+
- **The first name is the only one push writes**, and only when the spec
|
|
68
|
+
itself moves. The rest are never written.
|
|
69
|
+
- **The rest are read as that bucket** by the listing: the live
|
|
70
|
+
`spec-sync list` hides every `complete` / `cancelled` name, `--state <bucket>`
|
|
71
|
+
matches all of them, and `spec-sync states` lists each alias under its
|
|
72
|
+
bucket.
|
|
73
|
+
- **Nothing is pulled.** An alias changes what the report *says* about a
|
|
74
|
+
ticket, never the spec.
|
|
75
|
+
- A plain string works exactly as before. An alias that also names another
|
|
76
|
+
bucket is refused at load. An alias the tracker lacks is reported by
|
|
77
|
+
`spec-sync states` but never blocks a push, because it is never written.
|
|
78
|
+
- `spec-sync status` never reads an issue's Status at all, aliased or not:
|
|
79
|
+
skitterspec tells the board about its own transitions and nothing else.
|
|
80
|
+
|
|
81
|
+
## Releases and deploys — the host project's to write
|
|
82
|
+
|
|
83
|
+
Skitterspec moves an issue's Status only at its own transitions, and it writes
|
|
84
|
+
nothing about releases or deployments. What a project records about a release
|
|
85
|
+
— a GitHub Release, a `Deployed` field, a comment — is its own CI's to write.
|
|
86
|
+
|
|
87
|
+
The one release question skitterspec answers is
|
|
88
|
+
**which issues a range contains**, because only the `Refs: #N` trailers know:
|
|
89
|
+
|
|
90
|
+
```sh
|
|
91
|
+
skitterspec-github spec-sync released "<previous-tag>..<tag>" --json
|
|
122
92
|
```
|
|
123
93
|
|
|
94
|
+
Each row carries the `ref`, its commit count, the `spec` that stamped it and its
|
|
95
|
+
`url` — `null` for a ref no spec has linked, never a guess. The checkout needs
|
|
96
|
+
`fetch-depth: 0` so the previous tag is visible. Pipe the list into `gh`, the
|
|
97
|
+
GraphQL API or anything else. This repo's own `scripts/mirror-deployed.cjs` is
|
|
98
|
+
a worked example: it sets the board's `Deployed` field on a tag push, on
|
|
99
|
+
approval, and hourly for approvals made elsewhere.
|
|
100
|
+
|
|
101
|
+
The `releases` block and the `spec-sync release` verbs are **retired**:
|
|
102
|
+
`release` exits 1 naming `released --json`, and `spec-sync doctor` flags a
|
|
103
|
+
leftover `releases` block as unused config (a warning, never a failure).
|
|
104
|
+
|
|
124
105
|
## The token
|
|
125
106
|
|
|
126
107
|
A **classic** personal access token with the `repo` and `project` scopes.
|
|
@@ -492,9 +492,19 @@ missing alias.
|
|
|
492
492
|
Sync is **one-way**: the repo is the source of truth and the tracker is a
|
|
493
493
|
**generated mirror**. It ships `/spec-push` (repo→tracker; computes a create/update plan
|
|
494
494
|
against a committed last-pushed snapshot and applies it) and `/spec-status`
|
|
495
|
-
(read-only
|
|
496
|
-
|
|
497
|
-
|
|
495
|
+
(read-only — what would push, and whether someone edited a description there),
|
|
496
|
+
backed by a `spec-sync` CLI. There is no content pull — the tracker is never
|
|
497
|
+
read back or merged.
|
|
498
|
+
|
|
499
|
+
**It tells, it doesn't track.** Skitterspec sends the tracker its own
|
|
500
|
+
transitions — a spec starting, a phase finishing, a spec completing or being
|
|
501
|
+
cancelled — and nothing else. A status someone changes on the tracker is
|
|
502
|
+
theirs to have changed: it is never read back, never reported, and only
|
|
503
|
+
overwritten when the spec itself next moves. Releases and deployments are the
|
|
504
|
+
host project's to record. The one release question skitterspec answers is which
|
|
505
|
+
tickets a commit range contains (`spec-sync released <range> --json`, each row
|
|
506
|
+
with its spec and url), because only the `Refs:` trailers know. What the
|
|
507
|
+
project's CI does with that list is its own business.
|
|
498
508
|
|
|
499
509
|
**One-way means the repo wins, and it now wins *loudly*.** Those are different
|
|
500
510
|
claims and only the first was ever in doubt. A ticket's description is generated
|
|
@@ -93,9 +93,10 @@ automations are theirs to choose.
|
|
|
93
93
|
merged → Done" workflows**, or leave them knowingly: the engine sets Status
|
|
94
94
|
itself, and a board automation moving it too is a second writer the next push
|
|
95
95
|
overrides.
|
|
96
|
-
- **
|
|
97
|
-
|
|
98
|
-
|
|
96
|
+
- **Release stages never go on Status** (Test, Demo, Prod), or a finished
|
|
97
|
+
phase reads as deployed. If the user tracks deploys, that is a field of their
|
|
98
|
+
own that their CI sets from `spec-sync released --json` — setup does not need
|
|
99
|
+
it, and skitterspec never writes it.
|
|
99
100
|
|
|
100
101
|
## 5. Check the Status options
|
|
101
102
|
|
|
@@ -203,7 +204,8 @@ Then name the next step:
|
|
|
203
204
|
|
|
204
205
|
- `/spec` — write a spec; with GitHub configured it creates the linked issue in
|
|
205
206
|
the configured repo, puts it on the board and stamps its number.
|
|
206
|
-
- `/spec-status` — read-only
|
|
207
|
+
- `/spec-status` — read-only report of what would push, the safe way to prove
|
|
208
|
+
the link works.
|
|
207
209
|
- `/spec-push` — send a spec up.
|
|
208
210
|
|
|
209
211
|
Mention what setup did **not** configure, so the defaults aren't mistaken for
|
|
@@ -32,6 +32,10 @@ The user asks in plain language; the engine takes flags. Map, then run:
|
|
|
32
32
|
| "what specs are there", "/spec-list" | *(none — the live default)* |
|
|
33
33
|
| "what's done", "everything" | `--all` |
|
|
34
34
|
| "what's cancelled", a named status | `--state "<name>"` (repeatable) |
|
|
35
|
+
| "what's next", "the next few in the backlog" | `--next N` |
|
|
36
|
+
| "what's in progress", a lifecycle bucket | `--state in-progress` |
|
|
37
|
+
| "what's mine", "what am I on" | `--mine` |
|
|
38
|
+
| "what is Priya doing", a named person | `--by "<name or email>"` |
|
|
35
39
|
|
|
36
40
|
The default scope is **live** — whatever `config.states` maps `backlog` and
|
|
37
41
|
`in-progress` to. It is deliberately not everything: in a project with any
|
|
@@ -40,14 +44,34 @@ history, Done dwarfs the rows anyone wanted.
|
|
|
40
44
|
`--state` and `--all` are **alternatives**, and the engine refuses the pair
|
|
41
45
|
rather than letting one win silently.
|
|
42
46
|
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
47
|
+
`--mine` and `--by` filter by **assignee** and combine with the scope; they
|
|
48
|
+
cannot be combined with each other. Every row carries its assignee, and a
|
|
49
|
+
ticket no spec has adopted yet is listed too, marked `(no spec)` — under
|
|
50
|
+
`--mine` that is often exactly what is next. `--mine` with an unknown identity
|
|
51
|
+
lists **nothing** and says why (`spec-sync whoami --set` fixes it); relay that
|
|
52
|
+
rather than retrying without the filter. `--by` matching nobody or several
|
|
53
|
+
people exits 1 and names them — relay it and ask which one.
|
|
54
|
+
|
|
55
|
+
`--next N` is the top of the backlog in the tracker's own order, board position (the order items are dragged into). It picks the scope itself, so it does not combine with `--state`
|
|
56
|
+
or `--all`; the engine refuses that pair rather than picking a winner. It does
|
|
57
|
+
combine with `--mine` / `--by`.
|
|
58
|
+
|
|
59
|
+
**Every row shows the board's state and the spec's own status side by side.**
|
|
60
|
+
The spec status is read from the spec's **own worktree** when one exists, so an
|
|
61
|
+
in-flight spec reads `in-progress` even on the base branch, where its folder
|
|
62
|
+
still says `backlog`. `≠ <bucket>` marks a row whose board state maps to a
|
|
63
|
+
different bucket than its spec; a state that maps to no bucket never gets one.
|
|
64
|
+
`—` means the spec is not on this machine. Relay it as printed; never "correct"
|
|
65
|
+
either column from the other. The board says where the ticket is, and the spec
|
|
66
|
+
says where the work is.
|
|
67
|
+
|
|
68
|
+
`--state` also takes a lifecycle bucket: `--state in-progress` matches every
|
|
69
|
+
board state configured for it (`states` aliases included).
|
|
46
70
|
|
|
47
71
|
## 2. Run the engine
|
|
48
72
|
|
|
49
73
|
```
|
|
50
|
-
skitterspec spec-sync list [--state <name> …|--all] [--json]
|
|
74
|
+
skitterspec spec-sync list [--state <name|bucket> …|--all|--next N] [--mine | --by <user>] [--json]
|
|
51
75
|
```
|
|
52
76
|
|
|
53
77
|
- **`transport = api`** (credentials resolve) → it queried GitHub and printed the
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: spec-status
|
|
3
|
-
description: Show a spec's one-way sync status against GitHub — a read-only
|
|
3
|
+
description: Show a spec's one-way sync status against GitHub — a read-only report naming what would push, and whether someone edited the issue's description since the last push. Changes nothing. Opt-in — needs specs/.core/github.config.json. Use when the user says "/spec-status", "is this spec in sync with GitHub", "what would push", or "show spec sync status".
|
|
4
4
|
disable-model-invocation: true
|
|
5
5
|
---
|
|
6
6
|
|
|
7
|
-
# /spec-status — one-way sync
|
|
7
|
+
# /spec-status — one-way sync report
|
|
8
8
|
|
|
9
9
|
> Stay silent while this runs — speak only to ask something you cannot answer
|
|
10
10
|
> yourself, or to report a failure at the moment it happens. Read
|
|
@@ -15,13 +15,17 @@ Read-only. Reports two things and writes nothing:
|
|
|
15
15
|
|
|
16
16
|
1. **Pending push** — has the spec changed since the last push (is there an issue
|
|
17
17
|
description/state or any phase sub-issue to create or update)?
|
|
18
|
-
2. **
|
|
19
|
-
|
|
20
|
-
|
|
18
|
+
2. **Description edited** — did someone edit the issue's description on GitHub
|
|
19
|
+
since the last push? The next push replaces it, so this is worth reading
|
|
20
|
+
first.
|
|
21
|
+
|
|
22
|
+
**Status is not compared, deliberately.** Skitterspec tells GitHub about its
|
|
23
|
+
own transitions and never reads a status back: a card someone moved by hand is
|
|
24
|
+
theirs to have moved, and push resends State only when the spec itself moves.
|
|
21
25
|
|
|
22
26
|
The repo is the source of truth; GitHub is a generated mirror, so there is no
|
|
23
|
-
per-field "conflict" — only "what would the next push send" and "did
|
|
24
|
-
|
|
27
|
+
per-field "conflict" — only "what would the next push send" and "did someone
|
|
28
|
+
write over the mirror's text".
|
|
25
29
|
|
|
26
30
|
**Opt-in**: only runs when `specs/.core/github.config.json` exists. If absent,
|
|
27
31
|
tell the user how to enable GitHub sync and stop.
|
|
@@ -30,19 +34,16 @@ tell the user how to enable GitHub sync and stop.
|
|
|
30
34
|
|
|
31
35
|
Use the argument, else the spec in context; ask if unclear.
|
|
32
36
|
|
|
33
|
-
## 2. Fetch the GitHub issue (optional, for
|
|
37
|
+
## 2. Fetch the GitHub issue (optional, for the description check)
|
|
34
38
|
|
|
35
39
|
If the spec has a `github_identifier`, discover the GitHub MCP read tool
|
|
36
|
-
(`issue_read`) and write the issue JSON to a temp file
|
|
37
|
-
|
|
38
|
-
connected, skip the drift lines (still report pending-push).
|
|
40
|
+
(`issue_read`) and write the issue JSON to a temp file. If GitHub isn't
|
|
41
|
+
connected, skip the description check (still report pending-push).
|
|
39
42
|
|
|
40
|
-
**Write the whole issue, including its `description`.**
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
loss is silent. Keep `url` too: it is what the description line points the
|
|
45
|
-
reader at.
|
|
43
|
+
**Write the whole issue, including its `description`.** That is the field the
|
|
44
|
+
check reads; without it the check has nothing to look at, and it says nothing
|
|
45
|
+
rather than guessing, so the loss is silent. Keep `url` too: it is what the
|
|
46
|
+
description line points the reader at.
|
|
46
47
|
|
|
47
48
|
**The description itself never enters the conversation.** The engine hashes it
|
|
48
49
|
and compares hashes; what it prints is *that* the text changed, plus where to
|
|
@@ -59,8 +60,9 @@ skitterspec spec-sync status <spec> [--remote <issuefile>] [--workspace-states <
|
|
|
59
60
|
```
|
|
60
61
|
|
|
61
62
|
- Reports `push: pending — N to create, M to update` or `up to date`.
|
|
62
|
-
- With `--remote`, adds a `drift:` line
|
|
63
|
-
|
|
63
|
+
- With `--remote`, adds a `drift:` line when the issue's description was
|
|
64
|
+
edited on GitHub since the last push, and nothing otherwise. It never reports
|
|
65
|
+
the board's Status.
|
|
64
66
|
- With `--workspace-states`, fails loudly if a configured state name isn't a
|
|
65
67
|
Status option on the board (the push would refuse at apply time).
|
|
66
68
|
|
|
@@ -88,18 +90,17 @@ the shape; this section carries only what is specific here.
|
|
|
88
90
|
**Verdicts**
|
|
89
91
|
|
|
90
92
|
- `✅` — in sync; nothing would push.
|
|
91
|
-
- `⚠️` —
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
description means a person wrote something that the next push replaces.
|
|
93
|
+
- `⚠️` — N objects would push, or the issue's **description** was edited on
|
|
94
|
+
GitHub since the last push. Neither is an error, but both are the reason
|
|
95
|
+
someone ran this. **Say which**, since they call for different things: a
|
|
96
|
+
pending push is routine, and an edited description means a person wrote
|
|
97
|
+
something that the next push replaces.
|
|
97
98
|
- `⏸` — no config, or the spec is not linked. Nothing to compare.
|
|
98
99
|
|
|
99
100
|
**Fields:** `Tracker` · `Follow-ups` · `Next`
|
|
100
101
|
|
|
101
|
-
`Tracker` is the
|
|
102
|
-
|
|
102
|
+
`Tracker` is the answer in one line — what would push, and whether the
|
|
103
|
+
description was edited. `Next` is `/spec-push` when a push is pending, and nothing to
|
|
103
104
|
do when it is not.
|
|
104
105
|
|
|
105
106
|
A **`phases: <mode>`** line names the phase mode that resolved for this spec's
|