@skitterbyte/skitterspec-github 3.2.1 → 3.2.3
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/assets/review/page.html +4 -0
- package/assets/skills/spec-next/SKILL.md +43 -22
- package/package.json +1 -1
- package/src/cli.js +59 -13
- package/src/env/review.js +4 -1
- package/src/env/serve.js +3 -1
package/assets/review/page.html
CHANGED
|
@@ -1997,6 +1997,10 @@ a.ticket:hover { border-color: var(--accent); }
|
|
|
1997
1997
|
// because `Commit & Continue` names a next phase a spec with no phase files
|
|
1998
1998
|
// does not have. Same three buttons as `refresh`, a different subject.
|
|
1999
1999
|
fix: ['commit', 'changes', 'discuss'],
|
|
2000
|
+
// A PHASE STOPPED AT ITS MANUAL STEPS: the code half commits so it can go
|
|
2001
|
+
// live and be tested; the steps come next, so there is nothing to Continue
|
|
2002
|
+
// into. `/spec-next` §3 renders it, and arms nothing.
|
|
2003
|
+
manual: ['commit', 'changes', 'discuss'],
|
|
2000
2004
|
// A KEPT PHASE of an autonomous run: the run committed it and carried on,
|
|
2001
2005
|
// so there is nothing to decide here — it is read, not answered.
|
|
2002
2006
|
snapshot: [],
|
|
@@ -353,28 +353,55 @@ Then build it, following the project rules in `.claude/rules/*.md` and `CLAUDE.m
|
|
|
353
353
|
- Never hardcode dates in tests; never run destructive commands against a real
|
|
354
354
|
database — use the project's test database only.
|
|
355
355
|
|
|
356
|
-
### Manual steps — list them,
|
|
356
|
+
### Manual steps — list them, end the turn, ask when they come back
|
|
357
357
|
|
|
358
358
|
Some tasks are a person's to do: every task in an **Issue** spec, and any task
|
|
359
359
|
you cannot perform yourself — operate a UI, check a device, confirm something
|
|
360
360
|
on a board, run a manual test pass. That is a **judgment**, not a marker: there
|
|
361
361
|
is no `(manual)` tag to look for, and a spec written before this rule has none.
|
|
362
362
|
|
|
363
|
-
Build the tasks before the first manual one as usual
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
**never only the phase file's path**. A pointer to the file
|
|
367
|
-
out of the terminal to find out what to do, which is the
|
|
368
|
-
fix; the steps themselves are what they act on.
|
|
363
|
+
Build the tasks before the first manual one as usual, to green.
|
|
364
|
+
Then **stop at it** and print
|
|
365
|
+
**every remaining manual step of this phase, verbatim and numbered** —
|
|
366
|
+
never fenced, and **never only the phase file's path**. A pointer to the file
|
|
367
|
+
sends the reader out of the terminal to find out what to do, which is the
|
|
368
|
+
failure this exists to fix; the steps themselves are what they act on.
|
|
369
369
|
|
|
370
370
|
**Steps you had to write are saved first.** When the phase file holds only a
|
|
371
371
|
vague manual task — "check it on the running host" — and you wrote the steps
|
|
372
372
|
yourself, add them under that task as numbered sub-checkboxes **before** you
|
|
373
|
-
|
|
374
|
-
up its own set lists different steps from the ones the reader was shown.
|
|
375
|
-
phase whose manual steps are already tasks is left as it is.
|
|
376
|
-
|
|
377
|
-
|
|
373
|
+
list them. The conversation does not survive a `/clear`, and a later run that
|
|
374
|
+
makes up its own set lists different steps from the ones the reader was shown.
|
|
375
|
+
A phase whose manual steps are already tasks is left as it is.
|
|
376
|
+
|
|
377
|
+
**The first listing ends the turn, and asks no question.** Asking in the same
|
|
378
|
+
turn fails twice over (ereqs, 2026-11-24): the harness's question dialog can
|
|
379
|
+
cover the text before it, so the reader sees "how did it go?" with no steps;
|
|
380
|
+
and the work is not reachable yet — uncommitted in this worktree, not live, not
|
|
381
|
+
on the base branch — so nothing could have been tested. The stop is a report:
|
|
382
|
+
|
|
383
|
+
1. **Render the page for the code built so far**, only where the project has
|
|
384
|
+
isolation: `skitterspec spec-env review <spec> --buttons manual`. The
|
|
385
|
+
`manual` set offers `Commit` and drops `Commit & Continue`: the code half
|
|
386
|
+
commits so `/spec-live` can take a clean tree, and what follows is a
|
|
387
|
+
person's testing, not a build. It **does not arm** the gate — the phase did
|
|
388
|
+
not end. Committing part of a phase is deliberate here, unlike a `midrun`
|
|
389
|
+
page: the manual steps test this code, and it cannot be reached until it is
|
|
390
|
+
committed. Wait for the verdict as §5 does, under its banner; a `Commit`
|
|
391
|
+
runs through `/spec-diff` §2a.
|
|
392
|
+
2. **End `⚠️`**, `Why` the phase stopped at its manual steps. `Next` first
|
|
393
|
+
names how to reach the work — `/commit`, then `/spec-live`; or
|
|
394
|
+
`/commit`, then `/spec-to-main` where live refuses the branch (it touches
|
|
395
|
+
migrations, which would change the shared database) or a step needs it on
|
|
396
|
+
the base branch — then the steps a row each, then a closing row: *tell me
|
|
397
|
+
how it went, or `/spec-next`*. The rows follow
|
|
398
|
+
`.claude/rules/spec-reports.md`, *Open manual steps are rows*.
|
|
399
|
+
|
|
400
|
+
**The operator's next message is the answer** — "all done", "step 5 failed:
|
|
401
|
+
…" — read as one of the three below. Or a later `/spec-next` finds the steps
|
|
402
|
+
still unticked: re-list them, and now that the operator has come back, ask.
|
|
403
|
+
A picker carries the steps **inside the question text**,
|
|
404
|
+
never only in the text before it. The three answers:
|
|
378
405
|
|
|
379
406
|
- **All done** — tick those steps and carry on to the end of the phase.
|
|
380
407
|
- **Some failed** — the picker cannot list the steps (it holds four options and
|
|
@@ -384,16 +411,10 @@ Then ask one question, with three answers:
|
|
|
384
411
|
never switch.
|
|
385
412
|
- **Not yet** — tick nothing.
|
|
386
413
|
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
**Some failed or Not yet leaves the phase `🔄`, and stops the run there.** Code
|
|
392
|
-
tasks after an unconfirmed step are not built past it, and the phase did not
|
|
393
|
-
end: **skip §4's done-marking and §5 entirely** — no page, no arm, no wait.
|
|
394
|
-
End `⚠️` and name `/spec-next` in `Next`; it re-lists the same unticked steps.
|
|
395
|
-
Its `Next` lists the open steps a row each, copied from the phase file —
|
|
396
|
-
`.claude/rules/spec-reports.md`, *Open manual steps are rows*.
|
|
414
|
+
**The stop, Some failed and Not yet leave the phase `🔄`, and stop the run there.** Code tasks after an unconfirmed step are not built past it, and the
|
|
415
|
+
phase did not end: **skip §4's done-marking and §5's committing render** — on
|
|
416
|
+
an answer, no page, no arm, no wait. End `⚠️` and name `/spec-next` in `Next`;
|
|
417
|
+
it re-lists the same unticked steps, a row each, copied from the phase file.
|
|
397
418
|
|
|
398
419
|
## 4. Record progress
|
|
399
420
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@skitterbyte/skitterspec-github",
|
|
3
|
-
"version": "3.2.
|
|
3
|
+
"version": "3.2.3",
|
|
4
4
|
"description": "Spec-driven development for Claude Code, with one-way GitHub sync — a superset of @skitterbyte/skitterspec: the base filesystem workflow plus /spec-status · /spec-push · /spec-claim and the spec-sync CLI, mirroring specs to GitHub Issues, sub-issues and a Projects v2 board, with GitHub Releases. The repo is canonical; GitHub is a generated mirror. Install this OR the base OR one other superset — exactly one.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"claude",
|
package/src/cli.js
CHANGED
|
@@ -344,6 +344,7 @@ Usage:
|
|
|
344
344
|
prune reap orphaned test-DB volumes (--older-than <days>)
|
|
345
345
|
dev up <spec> start host dev servers on the spec's ports
|
|
346
346
|
dev down <spec> stop the spec's host dev servers
|
|
347
|
+
(--plan on either: describe, touch nothing)
|
|
347
348
|
connect <spec> expose a spec on the canonical ports (main = off)
|
|
348
349
|
integrate <spec> plan the land: rebase + fast-forward, or in PR
|
|
349
350
|
mode push + PR (--push, --draft, --strategy);
|
|
@@ -7119,12 +7120,17 @@ async function specEnvReview(dir, config, specArg, flags, invokedFrom = dir) {
|
|
|
7119
7120
|
// servers (e.g. `pnpm dev`) need a block even on a worktree-only spec, so `up`
|
|
7120
7121
|
// allocates a slot if the spec has none (idempotent). The planner is pure
|
|
7121
7122
|
// (dev.js); the spawning/killing lives in supervise.js.
|
|
7122
|
-
|
|
7123
|
+
//
|
|
7124
|
+
// `--plan` describes and touches nothing — no slot reserved, nothing spawned or
|
|
7125
|
+
// killed — as it does on `up`, `bootstrap` and `hotfix land`. This verb once
|
|
7126
|
+
// never received the flags, so `dev up --plan` started the very servers it was
|
|
7127
|
+
// asked to describe (bug-dev-up-plan-starts-servers).
|
|
7128
|
+
async function specEnvDev(dir, config, positional, flags = {}) {
|
|
7123
7129
|
const action = positional[0]
|
|
7124
7130
|
const specArg = positional[1]
|
|
7125
7131
|
// The action must be named; the spec may be omitted (resolved from the registry).
|
|
7126
7132
|
if (action !== 'up' && action !== 'down') {
|
|
7127
|
-
process.stdout.write('Usage: skitterspec spec-env dev <up|down> [spec]\n')
|
|
7133
|
+
process.stdout.write('Usage: skitterspec spec-env dev <up|down> [spec] [--plan]\n')
|
|
7128
7134
|
return
|
|
7129
7135
|
}
|
|
7130
7136
|
const spec = resolveSpecWithWorktree(dir, config, specArg)
|
|
@@ -7139,9 +7145,10 @@ async function specEnvDev(dir, config, positional) {
|
|
|
7139
7145
|
let slot
|
|
7140
7146
|
if (action === 'up') {
|
|
7141
7147
|
// Ensure a slot (idempotent) so the port block is reserved even worktree-only.
|
|
7148
|
+
// A plan computes the same slot and writes nothing.
|
|
7142
7149
|
const alloc = allocateSlot(registry, spec.folder)
|
|
7143
7150
|
slot = alloc.slot
|
|
7144
|
-
writeRegistry(dir, config, alloc.registry)
|
|
7151
|
+
if (!flags.plan) writeRegistry(dir, config, alloc.registry)
|
|
7145
7152
|
} else {
|
|
7146
7153
|
// Teardown only needs the pid-file paths (keyed by folder, not slot), so the
|
|
7147
7154
|
// slot value is immaterial — use the existing one, or 0 as a placeholder.
|
|
@@ -7152,6 +7159,32 @@ async function specEnvDev(dir, config, positional) {
|
|
|
7152
7159
|
|
|
7153
7160
|
const plan = planDev(spec, slot, config)
|
|
7154
7161
|
|
|
7162
|
+
if (flags.plan) {
|
|
7163
|
+
// A live pid is the positive signal for "already running"; a missing or
|
|
7164
|
+
// stale pid file reads as would-start, which is what `up` would then do.
|
|
7165
|
+
const running = (proc) => {
|
|
7166
|
+
const pid = readPid(path.resolve(dir, proc.pidFile))
|
|
7167
|
+
return pid && isAlive(pid) ? pid : null
|
|
7168
|
+
}
|
|
7169
|
+
const out = [
|
|
7170
|
+
`spec-env dev ${action}: ${spec.folder} slot ${slot} (plan — nothing ${action === 'up' ? 'started' : 'stopped'})`,
|
|
7171
|
+
]
|
|
7172
|
+
for (const proc of plan.procs) {
|
|
7173
|
+
const pid = running(proc)
|
|
7174
|
+
if (action === 'up') {
|
|
7175
|
+
out.push(
|
|
7176
|
+
pid
|
|
7177
|
+
? ` ${proc.name}: port ${proc.port} already running (pid ${pid})`
|
|
7178
|
+
: ` ${proc.name}: port ${proc.port} would start: ${proc.command}`,
|
|
7179
|
+
)
|
|
7180
|
+
} else {
|
|
7181
|
+
out.push(` ${proc.name}: ${pid ? `would stop pid ${pid}` : 'not running'}`)
|
|
7182
|
+
}
|
|
7183
|
+
}
|
|
7184
|
+
process.stdout.write(out.join('\n') + '\n')
|
|
7185
|
+
return
|
|
7186
|
+
}
|
|
7187
|
+
|
|
7155
7188
|
if (action === 'up') {
|
|
7156
7189
|
const out = [`spec-env dev up: ${spec.folder} slot ${slot} (ports from ${plan.portOffset})`]
|
|
7157
7190
|
for (const proc of plan.procs) {
|
|
@@ -8110,6 +8143,17 @@ function liveRebaseTarget(dir, config, base) {
|
|
|
8110
8143
|
|
|
8111
8144
|
// Take the running instance: rebase the spec's branch onto base, free it from its
|
|
8112
8145
|
// worktree, and check it out in the primary checkout so the dev server reloads it.
|
|
8146
|
+
// A TAKE THAT DID NOT HAPPEN SAYS SO FIRST. Every outcome used to open
|
|
8147
|
+
// `spec-env live take: …`, so a one-line refusal read like the success line,
|
|
8148
|
+
// and an operator (ereqs, 2026-11-24) went to test a feature that was never
|
|
8149
|
+
// switched in. The marker leads, the consequence follows, the reason after.
|
|
8150
|
+
function notLive(folder, why) {
|
|
8151
|
+
return (
|
|
8152
|
+
`✖ NOT LIVE — spec-env live take refused ${folder}; nothing switched, ` +
|
|
8153
|
+
`the running instance is unchanged.\n\n ${why}\n`
|
|
8154
|
+
)
|
|
8155
|
+
}
|
|
8156
|
+
|
|
8113
8157
|
async function specEnvLiveTake(dir, config, specArg, flags = {}) {
|
|
8114
8158
|
const spec = resolveSpecWithWorktree(dir, config, specArg)
|
|
8115
8159
|
|
|
@@ -8197,7 +8241,7 @@ async function specEnvLiveTake(dir, config, specArg, flags = {}) {
|
|
|
8197
8241
|
// entitled to the same way out — so the refusal prints what it would have
|
|
8198
8242
|
// offered rather than making a harness the only route to it.
|
|
8199
8243
|
process.stdout.write(
|
|
8200
|
-
|
|
8244
|
+
notLive(spec.folder, `blocked — ${plan.reason}.`) +
|
|
8201
8245
|
(plan.offer ? ` ${plan.offer.label}: ${plan.offer.command}\n` : ''),
|
|
8202
8246
|
)
|
|
8203
8247
|
return
|
|
@@ -8214,17 +8258,20 @@ async function specEnvLiveTake(dir, config, specArg, flags = {}) {
|
|
|
8214
8258
|
const started = runGit(spec.worktreePath, ['rebase', '--show-current-patch']).ok
|
|
8215
8259
|
if (started) runGit(spec.worktreePath, ['rebase', '--abort'])
|
|
8216
8260
|
process.stdout.write(
|
|
8217
|
-
|
|
8218
|
-
|
|
8219
|
-
|
|
8220
|
-
|
|
8221
|
-
|
|
8261
|
+
notLive(
|
|
8262
|
+
spec.folder,
|
|
8263
|
+
started
|
|
8264
|
+
? `rebase of ${spec.branch} onto ${onto} hit conflicts — ` +
|
|
8265
|
+
`resolve them in ${spec.worktreePath}, then retry.`
|
|
8266
|
+
: `rebase of ${spec.branch} onto ${onto} could not start — ` +
|
|
8267
|
+
`git said:\n ${reb.err.split('\n').join('\n ')}`,
|
|
8268
|
+
),
|
|
8222
8269
|
)
|
|
8223
8270
|
return
|
|
8224
8271
|
}
|
|
8225
8272
|
const det = runGit(spec.worktreePath, ['switch', '--detach'])
|
|
8226
8273
|
if (!det.ok) {
|
|
8227
|
-
process.stdout.write(
|
|
8274
|
+
process.stdout.write(notLive(spec.folder, `could not detach the worktree — ${det.err}`))
|
|
8228
8275
|
return
|
|
8229
8276
|
}
|
|
8230
8277
|
const co = runGit(dir, ['checkout', spec.branch])
|
|
@@ -8232,8 +8279,7 @@ async function specEnvLiveTake(dir, config, specArg, flags = {}) {
|
|
|
8232
8279
|
// Roll the detach back so the worktree keeps its branch.
|
|
8233
8280
|
runGit(spec.worktreePath, ['switch', spec.branch])
|
|
8234
8281
|
process.stdout.write(
|
|
8235
|
-
|
|
8236
|
-
`checkout — ${co.err}\n`,
|
|
8282
|
+
notLive(spec.folder, `could not check out ${spec.branch} in the primary checkout — ${co.err}`),
|
|
8237
8283
|
)
|
|
8238
8284
|
return
|
|
8239
8285
|
}
|
|
@@ -8719,7 +8765,7 @@ async function specEnvDispatch(sub, dir, config, positional, flags, present, inv
|
|
|
8719
8765
|
specEnvPrune(dir, config, flags)
|
|
8720
8766
|
break
|
|
8721
8767
|
case 'dev':
|
|
8722
|
-
await specEnvDev(dir, config, positional)
|
|
8768
|
+
await specEnvDev(dir, config, positional, flags)
|
|
8723
8769
|
break
|
|
8724
8770
|
case 'connect':
|
|
8725
8771
|
await specEnvConnect(dir, config, positional[0])
|
package/src/env/review.js
CHANGED
|
@@ -984,7 +984,10 @@ const COMMITTING = ['commit', 'commit-continue', 'commit-start', 'commit-land',
|
|
|
984
984
|
// at all, because the run committed that phase and carried on. `final` is the
|
|
985
985
|
// page an autonomous run ends on under `pause`: `complete`, `push`, `pr`, plus
|
|
986
986
|
// `changes` and `discuss`.
|
|
987
|
-
|
|
987
|
+
// `manual` is a phase stopped at its manual steps: its code half is green and
|
|
988
|
+
// must be committed before `/spec-live` will take it, and what follows is a
|
|
989
|
+
// person's testing, not a build — so `Commit`, never `Commit & Continue`.
|
|
990
|
+
const BUTTON_SETS = ['committing', 'midrun', 'authoring', 'refresh', 'nospec', 'fix', 'manual', 'snapshot', 'final']
|
|
988
991
|
const DEFAULT_BUTTON_SET = 'committing'
|
|
989
992
|
|
|
990
993
|
/**
|
package/src/env/serve.js
CHANGED
|
@@ -531,7 +531,9 @@ function receivePass(dir, config, spec, blob) {
|
|
|
531
531
|
*/
|
|
532
532
|
// `final` too: the run's last render declared it, and a served re-render
|
|
533
533
|
// must keep offering the ending rather than fall back to `Commit`.
|
|
534
|
-
|
|
534
|
+
// `manual` narrows the same way `fix` does: a served re-render of a phase
|
|
535
|
+
// stopped at its manual steps must not hand back `Commit & Continue`.
|
|
536
|
+
const NARROWING_SETS = ['midrun', 'refresh', 'fix', 'manual', 'final']
|
|
535
537
|
|
|
536
538
|
function buttonsForView(viewKind, spec, recorded) {
|
|
537
539
|
if (NARROWING_SETS.includes(recorded)) return recorded
|