@skitterbyte/skitterspec-azure-boards 2.2.0 → 2.4.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/assets/claude-md-section.md +20 -1
- package/assets/core/azure-boards.config.md +4 -2
- package/assets/core/env.config.json.example +1 -0
- package/assets/core/env.config.md +90 -6
- package/assets/hooks/main-guard.cjs +18 -2
- package/assets/hooks/review-gate.cjs +19 -2
- package/assets/rules/commit-trailers.md +24 -1
- package/assets/rules/spec-planning.md +131 -18
- package/assets/rules/spec-reports.md +1 -1
- package/assets/skills/spec/SKILL.md +95 -6
- package/assets/skills/spec-azure-setup/SKILL.md +23 -1
- package/assets/skills/spec-bug/SKILL.md +68 -3
- package/assets/skills/spec-cancel/SKILL.md +35 -0
- package/assets/skills/spec-claim/SKILL.md +41 -2
- package/assets/skills/spec-complete/SKILL.md +113 -0
- package/assets/skills/spec-hotfix/SKILL.md +72 -4
- package/assets/skills/spec-incident/SKILL.md +44 -0
- package/assets/skills/spec-next/SKILL.md +12 -5
- package/assets/skills/spec-push/SKILL.md +22 -0
- package/assets/skills/spec-review/SKILL.md +32 -0
- package/assets/skills/spec-start/SKILL.md +50 -3
- package/assets/skills/spec-status/SKILL.md +18 -3
- package/assets/skills/spec-sync/SKILL.md +1 -0
- package/assets/skills/spec-to-main/SKILL.md +47 -1
- package/package.json +1 -1
- package/src/cli.js +1091 -39
- package/src/env/base.js +104 -0
- package/src/env/config.js +75 -3
- package/src/env/disposition.js +62 -0
- package/src/env/handoff.js +80 -0
- package/src/env/host.js +262 -0
- package/src/env/hotfix.js +225 -0
- package/src/env/hotfixland.js +103 -9
- package/src/env/inflight.js +95 -0
- package/src/env/integrate.js +130 -4
- package/src/env/mainguard.js +6 -0
- package/src/env/phases.js +28 -0
- package/src/env/provision.js +18 -6
- package/src/env/resolve.js +108 -9
- package/src/env/serve.js +6 -1
- package/src/env/specstate.js +101 -0
- package/src/env/teardown.js +42 -0
- package/src/vendor/azure-boards/cli-sync.js +47 -3
- package/src/vendor/azure-boards/config.js +17 -5
- package/src/vendor/provider-kit/index.js +4 -0
- package/src/vendor/provider-kit/src/apply.js +49 -4
- package/src/vendor/provider-kit/src/assignment.js +78 -1
- package/src/vendor/provider-kit/src/config.js +34 -1
- package/src/vendor/provider-kit/src/list-rows.js +35 -11
- package/src/vendor/provider-kit/src/released.js +14 -1
- package/src/vendor/provider-kit/src/specs.js +4 -2
- package/src/vendor/provider-kit/src/splice.js +64 -0
- package/src/vendor/provider-kit/src/status.js +137 -0
- package/src/vendor/sync-core/index.js +14 -1
- package/src/vendor/sync-core/src/compare.js +17 -5
- package/src/vendor/sync-core/src/normalize.js +50 -7
- package/src/vendor/sync-core/src/push.js +26 -2
- package/src/vendor/sync-core/src/summary.js +257 -0
|
@@ -167,7 +167,9 @@ not write the spec until this is resolved.
|
|
|
167
167
|
asking. Verify endpoints/models/files actually exist before relying on them.
|
|
168
168
|
- Cover, at minimum, the areas that apply:
|
|
169
169
|
1. **Problem & why** — what's broken/missing, who feels it, why now.
|
|
170
|
-
2. **Scope & non-goals** — explicit out-of-scope items
|
|
170
|
+
2. **Scope & non-goals** — explicit out-of-scope items, and the
|
|
171
|
+
**acceptance criteria**: what someone checks, without reading the code,
|
|
172
|
+
to call the work done (they become `## Acceptance criteria`).
|
|
171
173
|
3. **Affected areas** — concrete files/modules/packages this touches.
|
|
172
174
|
4. **Proposed solution shape** — the chosen approach and the alternatives
|
|
173
175
|
rejected, with the reason (this becomes "Decisions").
|
|
@@ -198,6 +200,39 @@ not write the spec until this is resolved.
|
|
|
198
200
|
Stop grilling when there are no unresolved branches that would change the spec.
|
|
199
201
|
Briefly play back the agreed understanding before writing.
|
|
200
202
|
|
|
203
|
+
### Watch for the other doors — bug, hotfix, incident
|
|
204
|
+
|
|
205
|
+
`/spec` is the default door, so work that belongs to another skill arrives here
|
|
206
|
+
described in the user's own words — no issue, no labels for Phase 0 to route
|
|
207
|
+
on. While grilling, watch for the signals that mark the other kinds and raise
|
|
208
|
+
the hand-off **the moment one appears**, not at the end of the grill: for a
|
|
209
|
+
live outage especially, finishing a feature grill first is actively harmful,
|
|
210
|
+
because `/spec-incident` exists to be written *during* the outage.
|
|
211
|
+
|
|
212
|
+
- **Defect** — behaviour differing from intended ("it's broken", a failing
|
|
213
|
+
flow, a stack trace of a failure) → propose **`/spec-bug`**.
|
|
214
|
+
- **Defect on a released version** — the defect is on what is deployed ("in
|
|
215
|
+
prod", "since v2.1") → propose **`/spec-hotfix`**.
|
|
216
|
+
- **Live outage** — a service down or degraded **right now**, users affected
|
|
217
|
+
as we speak → propose **`/spec-incident`**.
|
|
218
|
+
|
|
219
|
+
**Always confirm; never silently switch.** Name the signal in the user's own
|
|
220
|
+
words, propose the destination with a one-line reason, and let them decide. A
|
|
221
|
+
decline carries the grill on where it was, and the same signal is not raised
|
|
222
|
+
again. A signal is a question, never a verdict: a pasted stack trace in
|
|
223
|
+
"handle this error nicely" is a feature request. When one description carries
|
|
224
|
+
several signals, propose the most specific destination —
|
|
225
|
+
**incident > hotfix > bug**.
|
|
226
|
+
|
|
227
|
+
**On a confirmed switch, hand off in-session and carry the context.** Invoke
|
|
228
|
+
the destination skill directly and seed it with everything the grilling has
|
|
229
|
+
already established — symptom, version, impact, repro material, decisions so
|
|
230
|
+
far — so it grills only what it still needs ("seed, don't skip, the grill",
|
|
231
|
+
exactly as issue adoption does). Do not stop and tell the user to retype: that
|
|
232
|
+
shape belongs to Phase 0's label routing, which fires before any grilling has
|
|
233
|
+
happened and so has nothing to lose. The full routing matrix lives in
|
|
234
|
+
`.claude/rules/spec-planning.md`.
|
|
235
|
+
|
|
201
236
|
### Propose the kind — feature, chore or issue
|
|
202
237
|
|
|
203
238
|
This skill writes three kinds of spec, and
|
|
@@ -225,10 +260,13 @@ the point.
|
|
|
225
260
|
|
|
226
261
|
There is no `/spec-chore` or `/spec-issue` and none should be added: one entry
|
|
227
262
|
point, one grill, and the kind is an output of understanding the work rather
|
|
228
|
-
than a door the user must pick before describing it. The
|
|
229
|
-
|
|
230
|
-
needs a different grill and starts mid-flight —
|
|
231
|
-
one, hand off to **`/spec-
|
|
263
|
+
than a door the user must pick before describing it. The kinds with their own
|
|
264
|
+
doors — bug, hotfix, and the **incident**, an outage or degradation of a live
|
|
265
|
+
service that needs a different grill and starts mid-flight — are the watch's
|
|
266
|
+
business above: when the grilling uncovers one, hand off to **`/spec-bug`**,
|
|
267
|
+
**`/spec-hotfix`** or **`/spec-incident`** rather than writing it here, and it
|
|
268
|
+
is never too late to propose that — reaching this proposal with the signal
|
|
269
|
+
unraised is a missed watch, not a reason to write the wrong kind.
|
|
232
270
|
|
|
233
271
|
## Phase B — write the spec
|
|
234
272
|
|
|
@@ -304,6 +342,28 @@ move to, **warn, don't refuse**, and say the trailer for that commit wants
|
|
|
304
342
|
a feature, `chore-` for a chore, `issue-` for an issue (the bug counterpart
|
|
305
343
|
uses `bug-`, the incident one `incident-`).
|
|
306
344
|
|
|
345
|
+
**Who owns this spec's status.** Only when `specs/.core/azure-boards.config.json` exists.
|
|
346
|
+
Run `skitterspec spec-sync ownership --json` once and read both values:
|
|
347
|
+
|
|
348
|
+
- **`workflowState: "pull"`** — Azure Boards is the record of this spec's status, so
|
|
349
|
+
this skill **writes no `> **Status:**` header and appends no State log row**,
|
|
350
|
+
wherever its steps below say to. A spec this skill creates gets neither: its
|
|
351
|
+
header carries `> **Tracker:** <work item url>` instead, filled in once linking
|
|
352
|
+
has stamped the url, and its body has no `## State log` section. Readiness is
|
|
353
|
+
the spec's own content — a `Draft` is a spec whose **Open questions** is not
|
|
354
|
+
empty — so nothing is lost with the header.
|
|
355
|
+
- **`assignee: "pull"`** — Azure Boards holds who is building it, so this skill
|
|
356
|
+
**writes no `> **Developer:**` line** either.
|
|
357
|
+
- **Anything else** — `push`, `none`, sync reported off, or the command failing
|
|
358
|
+
— is cannot-tell, and the steps below run exactly as written.
|
|
359
|
+
|
|
360
|
+
What `pull` leaves alone: the folder move (a bucket records what the repo did to
|
|
361
|
+
the code, not a planning status), the phase files and index, and the Changelog.
|
|
362
|
+
A reason a `Status:` header would have carried — a cancellation's, a knock-back
|
|
363
|
+
to Draft — goes in a dated Changelog line instead. A spec that already carries
|
|
364
|
+
any of these lines keeps them untouched: they are history, and nothing rewrites
|
|
365
|
+
them.
|
|
366
|
+
|
|
307
367
|
Use this template (keep it **as concise as possible** — no filler, no restating
|
|
308
368
|
the codebase, link rather than duplicate):
|
|
309
369
|
|
|
@@ -328,10 +388,20 @@ the codebase, link rather than duplicate):
|
|
|
328
388
|
> "none: not user-facing". An empty value or a bare
|
|
329
389
|
> "none" is not a valid outcome — see Phase A item 10>
|
|
330
390
|
|
|
391
|
+
## Summary
|
|
392
|
+
|
|
393
|
+
<1–3 sentences: what the work delivers, for someone who will never open the
|
|
394
|
+
spec — no phase breakdown, no implementation detail. With a ticketing provider
|
|
395
|
+
in summary mode this is what the ticket leads with.>
|
|
396
|
+
|
|
331
397
|
## Problem
|
|
332
398
|
|
|
333
399
|
<2–6 sentences: what's wrong/missing and why it matters. No fluff.>
|
|
334
400
|
|
|
401
|
+
## Acceptance criteria
|
|
402
|
+
|
|
403
|
+
- <an observable check, from Phase A item 2 — one per line>
|
|
404
|
+
|
|
335
405
|
## Decisions
|
|
336
406
|
|
|
337
407
|
<Numbered, confirmed decisions from Phase A. Each: the choice + one-line why,
|
|
@@ -441,6 +511,11 @@ Rules for the spec body:
|
|
|
441
511
|
- **Changelog** is mandatory and lives in the spec. Every later decision or
|
|
442
512
|
course-correction gets a dated one-line entry. Convert relative dates to
|
|
443
513
|
absolute.
|
|
514
|
+
- **`## Summary` and `## Acceptance criteria` are the ticket-facing pair.**
|
|
515
|
+
Write them for a reader on the board, not the one building it: the summary
|
|
516
|
+
says what the work delivers, each criterion is something a person can check.
|
|
517
|
+
A ticketing provider in summary mode projects exactly these (plus the
|
|
518
|
+
Impact table's surfaces, Gating and progress) and nothing else.
|
|
444
519
|
- Keep it tight. If a section adds no information, delete it.
|
|
445
520
|
|
|
446
521
|
## Phase C — finish up
|
|
@@ -524,6 +599,18 @@ on the branch you are standing on — so a spec left on its own branch would be
|
|
|
524
599
|
invisible to everyone, including the next `/spec` run. The commit goes on the
|
|
525
600
|
branch and then the branch goes onto the base:
|
|
526
601
|
|
|
602
|
+
**Unless the project set `land.specDocs: "branch"`** — the lane for a base
|
|
603
|
+
branch nobody may push, where the spec document rides the feature branch and
|
|
604
|
+
lands with the work's PR. There both verdicts commit on the branch and
|
|
605
|
+
**skip the integrate below entirely**; `commit-start` carries into
|
|
606
|
+
`/spec-start` over the same worktree exactly as ever, and plain `commit` keeps
|
|
607
|
+
the branch AND the worktree, because they are now the only copy of the
|
|
608
|
+
document. Say the trade out loud in the report's `Notes`: the backlog is found
|
|
609
|
+
through the tracker listing (or `git branch`), not `ls specs/backlog/` on base
|
|
610
|
+
— and a later `/spec-cancel` of a never-started branch-mode spec deletes the
|
|
611
|
+
branch and worktree with the spec document dying with them, no PR ever having
|
|
612
|
+
existed. Under the default `"trunk"` everything below applies unchanged.
|
|
613
|
+
|
|
527
614
|
```
|
|
528
615
|
skitterspec spec-env integrate <name>
|
|
529
616
|
```
|
|
@@ -645,7 +732,9 @@ is opted in). If it's absent, skip this entirely — the spec stays local-only a
|
|
|
645
732
|
the skill behaves exactly as above. When present, link the spec you just wrote
|
|
646
733
|
so status and discussion live in Boards while the repo stays the source of
|
|
647
734
|
truth. A spec is a **work item**; each phase is a **child work item**, carrying
|
|
648
|
-
that phase's tasks in its description as a read-only markdown checklist.
|
|
735
|
+
that phase's tasks in its description as a read-only markdown checklist. That is the `spec` description mode;
|
|
736
|
+
under `summary` (a new config's default) the issue and each sub-issue carry
|
|
737
|
+
a short block instead, and the phase's tasks stay in git.
|
|
649
738
|
|
|
650
739
|
**Linking is just the first push**, so it runs the same engine path `/spec-push`
|
|
651
740
|
does — you never create the work item by hand:
|
|
@@ -136,6 +136,27 @@ Then settle the four bucket→state names against that list:
|
|
|
136
136
|
Each answer that differs from the defaults becomes a `--state <bucket>=<name>`
|
|
137
137
|
flag in step 6.
|
|
138
138
|
|
|
139
|
+
## 5b. What does a ticket carry?
|
|
140
|
+
|
|
141
|
+
Ask once, with the recommendation first — this decides what the team sees on
|
|
142
|
+
every ticket, so it is theirs to choose rather than a default to inherit:
|
|
143
|
+
|
|
144
|
+
- **`summary`** *(recommended — what `init-config` writes)* — the ticket holds a
|
|
145
|
+
short delimited block: the spec's summary, its acceptance criteria, the
|
|
146
|
+
surfaces it touches, its gating and its progress. Push splices that block in
|
|
147
|
+
beside whatever the team writes, which no push ever touches. The spec itself
|
|
148
|
+
stays in git.
|
|
149
|
+
- **`spec`** — the whole overview is the ticket body, replaced on every push.
|
|
150
|
+
Pass `--description spec` to `init-config`.
|
|
151
|
+
|
|
152
|
+
Azure Boards's block is marked with a heading for now (`summary.delimiter`), provisional
|
|
153
|
+
until a measured run settles which delimiter Azure Boards's editor keeps.
|
|
154
|
+
|
|
155
|
+
Then name the phase mode, without asking unless they raise it:
|
|
156
|
+
`mapping.phases` stays `subissue` — one assignable sub-issue per phase, which
|
|
157
|
+
is what lets phases run in parallel. `deferred` (minted at `/spec-start`),
|
|
158
|
+
`inline` and `none` (no sub-issues at all) are one edit to the file away.
|
|
159
|
+
|
|
139
160
|
## 6. Write it
|
|
140
161
|
|
|
141
162
|
```
|
|
@@ -143,7 +164,8 @@ skitterspec spec-sync init-config \
|
|
|
143
164
|
--org-url https://dev.azure.com/<org> --project <project> \
|
|
144
165
|
[--work-item-type Issue] [--child-type Task] \
|
|
145
166
|
[--kind-type <kind>=<Type> …] [--bug-type <Type> …] [--hotfix-type <Type> …] \
|
|
146
|
-
[--state <bucket>=<name> …] [--force] [--json]
|
|
167
|
+
[--state <bucket>=<name> …] [--force] [--json] \
|
|
168
|
+
[--description summary|spec]
|
|
147
169
|
```
|
|
148
170
|
|
|
149
171
|
The engine writes **only the keys that differ from the defaults**, so the file
|
|
@@ -160,6 +160,38 @@ Bugs are concrete — confirm, don't over-grill. Establish:
|
|
|
160
160
|
against the broken one (the bug usually lives in the differential). Do NOT
|
|
161
161
|
patch a symptom before you understand the cause.
|
|
162
162
|
|
|
163
|
+
### Watch for the other doors — hotfix, incident, or not a bug at all
|
|
164
|
+
|
|
165
|
+
The investigation above is where mis-entry shows, so watch it for the signals
|
|
166
|
+
that mark the other kinds and raise the hand-off the moment one appears —
|
|
167
|
+
before the failing test is written, while nothing is on disk
|
|
168
|
+
(`.claude/rules/spec-planning.md` carries the full routing matrix):
|
|
169
|
+
|
|
170
|
+
- **On a released version** — the defect is on what is deployed ("in prod",
|
|
171
|
+
"since v2.1") → propose **`/spec-hotfix`**. This is the escalation that must
|
|
172
|
+
not be missed: a fix built here lands on `main` and never reaches the
|
|
173
|
+
running version.
|
|
174
|
+
- **Live outage** — a service down or degraded **right now** → propose
|
|
175
|
+
**`/spec-incident`**; the record comes first, and the fix returns as a
|
|
176
|
+
linked spec.
|
|
177
|
+
- **Not a defect** — the ask is new or changed behaviour, not restoring
|
|
178
|
+
intended behaviour → propose **`/spec`**, whose kind proposal picks feature,
|
|
179
|
+
chore or issue from there.
|
|
180
|
+
|
|
181
|
+
**Always confirm; never silently switch** — name the signal in the user's own
|
|
182
|
+
words with a one-line reason, and a decline carries this skill on where it
|
|
183
|
+
was, the same signal not raised again. When several signals appear at once,
|
|
184
|
+
propose the most specific destination — incident over hotfix.
|
|
185
|
+
**On a confirmed switch, hand off in-session and carry the context**: invoke
|
|
186
|
+
the destination skill directly and seed it with what §1 established — symptom,
|
|
187
|
+
repro, root-cause notes, any version named — so it grills only what it still
|
|
188
|
+
needs.
|
|
189
|
+
|
|
190
|
+
**Once the failing test exists, the repro is evidence, not a question to re-litigate**
|
|
191
|
+
— but evidence can still escalate: a red test that also fails at
|
|
192
|
+
the released tag is the hotfix signal with proof attached, and the hand-off
|
|
193
|
+
carries the failing test across.
|
|
194
|
+
|
|
163
195
|
## 2. Isolate the fix in a worktree — when isolation is enabled
|
|
164
196
|
|
|
165
197
|
**Only when per-spec isolation is enabled** (`specs/.core/env.config.json`
|
|
@@ -269,6 +301,28 @@ split it into phase files (`01-<slug>.md`, `02-…`) with a phase index in
|
|
|
269
301
|
`00-overview.md`, exactly like a feature spec. It starts in `in-progress`
|
|
270
302
|
because work is already underway. Keep it lean:
|
|
271
303
|
|
|
304
|
+
**Who owns this spec's status.** Only when `specs/.core/azure-boards.config.json` exists.
|
|
305
|
+
Run `skitterspec spec-sync ownership --json` once and read both values:
|
|
306
|
+
|
|
307
|
+
- **`workflowState: "pull"`** — Azure Boards is the record of this spec's status, so
|
|
308
|
+
this skill **writes no `> **Status:**` header and appends no State log row**,
|
|
309
|
+
wherever its steps below say to. A spec this skill creates gets neither: its
|
|
310
|
+
header carries `> **Tracker:** <work item url>` instead, filled in once linking
|
|
311
|
+
has stamped the url, and its body has no `## State log` section. Readiness is
|
|
312
|
+
the spec's own content — a `Draft` is a spec whose **Open questions** is not
|
|
313
|
+
empty — so nothing is lost with the header.
|
|
314
|
+
- **`assignee: "pull"`** — Azure Boards holds who is building it, so this skill
|
|
315
|
+
**writes no `> **Developer:**` line** either.
|
|
316
|
+
- **Anything else** — `push`, `none`, sync reported off, or the command failing
|
|
317
|
+
— is cannot-tell, and the steps below run exactly as written.
|
|
318
|
+
|
|
319
|
+
What `pull` leaves alone: the folder move (a bucket records what the repo did to
|
|
320
|
+
the code, not a planning status), the phase files and index, and the Changelog.
|
|
321
|
+
A reason a `Status:` header would have carried — a cancellation's, a knock-back
|
|
322
|
+
to Draft — goes in a dated Changelog line instead. A spec that already carries
|
|
323
|
+
any of these lines keeps them untouched: they are history, and nothing rewrites
|
|
324
|
+
them.
|
|
325
|
+
|
|
272
326
|
```markdown
|
|
273
327
|
# Bug: <short title>
|
|
274
328
|
|
|
@@ -347,7 +401,9 @@ is opted in). If it's absent, skip this entirely — the spec stays local-only a
|
|
|
347
401
|
the skill behaves exactly as above. When present, link the spec you just wrote
|
|
348
402
|
so status and discussion live in Boards while the repo stays the source of
|
|
349
403
|
truth. A spec is a **work item**; each phase is a **child work item**, carrying
|
|
350
|
-
that phase's tasks in its description as a read-only markdown checklist.
|
|
404
|
+
that phase's tasks in its description as a read-only markdown checklist. That is the `spec` description mode;
|
|
405
|
+
under `summary` (a new config's default) the issue and each sub-issue carry
|
|
406
|
+
a short block instead, and the phase's tasks stay in git.
|
|
351
407
|
|
|
352
408
|
**Linking is just the first push**, so it runs the same engine path `/spec-push`
|
|
353
409
|
does — you never create the work item by hand:
|
|
@@ -428,6 +484,12 @@ item is a cosmetic gap that `/spec-claim` closes later.
|
|
|
428
484
|
skitterspec spec-sync assign <spec> --to <id> --name "<display name>"
|
|
429
485
|
```
|
|
430
486
|
|
|
487
|
+
**Where `spec-sync ownership` reports `assignee: pull`**, the work item is the
|
|
488
|
+
record and the spec file is not: add `--if-unassigned`. It writes Azure Boards
|
|
489
|
+
directly, claims the work item only when nobody holds it, and stamps nothing —
|
|
490
|
+
so step 4 has no header to leave alone, since under `pull` no `Developer:`
|
|
491
|
+
line was written.
|
|
492
|
+
|
|
431
493
|
4. **Leave `> **Developer:**` as `git config user.name`** — the step above this
|
|
432
494
|
seam already set it, and this seam must not overwrite it with the tracker's
|
|
433
495
|
display name.
|
|
@@ -449,12 +511,15 @@ item is a cosmetic gap that `/spec-claim` closes later.
|
|
|
449
511
|
|
|
450
512
|
**Nothing is pushed here.** `assign` writes the repo only, and the refresh these
|
|
451
513
|
skills already run sends it. Assignment is an ordinary field of the projection,
|
|
452
|
-
not a side errand with its own network call.
|
|
514
|
+
not a side errand with its own network call. Under `pull` the
|
|
515
|
+
`assign` call is itself the write, so there is nothing for a push to carry.
|
|
453
516
|
|
|
454
517
|
**There is no unassign step anywhere.** The projection derives the assignee from
|
|
455
518
|
the spec's lifecycle bucket, so `/spec-complete` and `/spec-cancel` release the
|
|
456
519
|
work item through the push they already make. The stamp deliberately stays in
|
|
457
|
-
the file: who actioned the work outlives who is currently holding it.
|
|
520
|
+
the file: who actioned the work outlives who is currently holding it. Under `pull`
|
|
521
|
+
the projection carries no assignee at all, so finishing a spec leaves it on
|
|
522
|
+
the work item: the board keeps who did the work.
|
|
458
523
|
|
|
459
524
|
Azure Boards has no project picker: a minted work item lands in the configured
|
|
460
525
|
`azure.project` by construction, decided once in
|
|
@@ -37,6 +37,28 @@ it verbatim/condensed for the header.
|
|
|
37
37
|
|
|
38
38
|
## 4. Stamp the spec
|
|
39
39
|
|
|
40
|
+
**Who owns this spec's status.** Only when `specs/.core/azure-boards.config.json` exists.
|
|
41
|
+
Run `skitterspec spec-sync ownership --json` once and read both values:
|
|
42
|
+
|
|
43
|
+
- **`workflowState: "pull"`** — Azure Boards is the record of this spec's status, so
|
|
44
|
+
this skill **writes no `> **Status:**` header and appends no State log row**,
|
|
45
|
+
wherever its steps below say to. A spec this skill creates gets neither: its
|
|
46
|
+
header carries `> **Tracker:** <work item url>` instead, filled in once linking
|
|
47
|
+
has stamped the url, and its body has no `## State log` section. Readiness is
|
|
48
|
+
the spec's own content — a `Draft` is a spec whose **Open questions** is not
|
|
49
|
+
empty — so nothing is lost with the header.
|
|
50
|
+
- **`assignee: "pull"`** — Azure Boards holds who is building it, so this skill
|
|
51
|
+
**writes no `> **Developer:**` line** either.
|
|
52
|
+
- **Anything else** — `push`, `none`, sync reported off, or the command failing
|
|
53
|
+
— is cannot-tell, and the steps below run exactly as written.
|
|
54
|
+
|
|
55
|
+
What `pull` leaves alone: the folder move (a bucket records what the repo did to
|
|
56
|
+
the code, not a planning status), the phase files and index, and the Changelog.
|
|
57
|
+
A reason a `Status:` header would have carried — a cancellation's, a knock-back
|
|
58
|
+
to Draft — goes in a dated Changelog line instead. A spec that already carries
|
|
59
|
+
any of these lines keeps them untouched: they are history, and nothing rewrites
|
|
60
|
+
them.
|
|
61
|
+
|
|
40
62
|
Update the **Status** header in the entry point so the reason is visible at the
|
|
41
63
|
top:
|
|
42
64
|
|
|
@@ -75,6 +97,10 @@ PAT is set (see `apply.transport` in `azure-boards.config.md`).
|
|
|
75
97
|
complete/cancelled/reviewed in the repo regardless; the mirror is disposable
|
|
76
98
|
and the next push repairs it. Do not roll anything back, and do not stop to
|
|
77
99
|
ask.
|
|
100
|
+
- **In `/spec-complete`'s PR mode this push belongs to run 2.** Run 1 readies
|
|
101
|
+
a PR, and a ready PR is not a merged one — so skip it on run 1, even where
|
|
102
|
+
the `branch` lane committed the move to ride the PR, and run it on run 2 once
|
|
103
|
+
the host has merged. The tracker's Done lands when the work does.
|
|
78
104
|
- **Say what happened** in the skill's report: mirror updated, skipped as
|
|
79
105
|
unlinked, or failed with the reason.
|
|
80
106
|
- **There is no unassign step here.** The projection derives the assignee from
|
|
@@ -253,6 +279,15 @@ only ordering that survives.
|
|
|
253
279
|
copy of abandoned work. Seeing no such section here is the expected case, not
|
|
254
280
|
a fault — and if the user wants the remote branch gone anyway, that is their
|
|
255
281
|
call to make explicitly, not something to tidy away on their behalf.
|
|
282
|
+
|
|
283
|
+
**In PR mode the same confirm-first section may carry the PR abandon**
|
|
284
|
+
(`gh pr close` / `az repos pr update --status abandoned`): a cancelled spec
|
|
285
|
+
must not leave a live PR behind — it is noise with a merge button on it.
|
|
286
|
+
The teardown of an open-PR spec is refused unforced (the PR is named), so
|
|
287
|
+
this line appears on the forced run the refusal led to; ask before running
|
|
288
|
+
it like the delete above, and run the abandon **before** any remote branch
|
|
289
|
+
delete — closing the PR first is what stops the host complaining about a
|
|
290
|
+
deleted source branch.
|
|
256
291
|
4. `skitterspec spec-env prune` — reap orphaned test-DB volumes that belong to no
|
|
257
292
|
live spec (leftovers from declined/aborted teardowns or manual worktree
|
|
258
293
|
removal). Show the orphan list and, **only on the user's confirmation**, run
|
|
@@ -26,6 +26,27 @@ checks the same thing and writes nothing, so the rule holds for a script, a
|
|
|
26
26
|
chained command, and anyone who reached for the CLI directly. Prose in one
|
|
27
27
|
skill is not a guard; it is a guard's documentation.
|
|
28
28
|
|
|
29
|
+
## Under `pull`, the work item is the record
|
|
30
|
+
|
|
31
|
+
Ask once: `skitterspec spec-sync ownership --json`. Where `assignee` is
|
|
32
|
+
**`pull`**, Azure Boards owns who is building the spec, and the repo keeps no copy — so
|
|
33
|
+
the steps below change in four places, and only these:
|
|
34
|
+
|
|
35
|
+
- **`assign` writes Azure Boards directly and stamps nothing.** There is no repo record
|
|
36
|
+
to change and no push to follow: §4 does not run, because the `assign` call
|
|
37
|
+
*was* the write.
|
|
38
|
+
- **Take checks Azure Boards, not the file.** Run `assign <spec> --to <id> --if-unassigned`
|
|
39
|
+
first. If it reports the work item is already assigned to someone else, that is
|
|
40
|
+
step 2's colleague: name them, confirm, then run it again without the flag.
|
|
41
|
+
- **No `> **Developer:**` line is written**, by any mode. The tracker names the
|
|
42
|
+
person; a header would be the copy `pull` exists to remove.
|
|
43
|
+
- **§3 is skipped.** The work item's own history records the move, and a
|
|
44
|
+
Changelog line saying who holds it would be that copy again.
|
|
45
|
+
|
|
46
|
+
Everything else stands: the opt-in check, resolving a person through a search
|
|
47
|
+
before a hand-over, and the report. Under `push` (or with ownership unknown)
|
|
48
|
+
nothing in this section applies.
|
|
49
|
+
|
|
29
50
|
## 1. Identify the target spec
|
|
30
51
|
|
|
31
52
|
The argument, else the spec in flight for this session, else ask. Unlike
|
|
@@ -78,8 +99,26 @@ now".
|
|
|
78
99
|
where search is unavailable, confirmed with the user.)
|
|
79
100
|
2. On several matches, show them and let the user pick. On none, say so and
|
|
80
101
|
stop — do not fall back to the raw argument as an id.
|
|
81
|
-
3.
|
|
82
|
-
|
|
102
|
+
3. **Make the work reachable before you hand it over.** Run
|
|
103
|
+
`skitterspec spec-env handoff <spec> --json`. A spec's branch lives in a
|
|
104
|
+
local worktree, so without this the work item would name a new owner for code
|
|
105
|
+
only you can see.
|
|
106
|
+
- **`blocked`** — relay the reason. Where it carries an `offer` (uncommitted
|
|
107
|
+
work: `/commit`), offer it once as `offered-unblocks.md` says, run it on a
|
|
108
|
+
yes, then run `handoff` again. With no offer, stop here: nothing is assigned.
|
|
109
|
+
- **`commands`** non-empty — the branch is not published at HEAD. Ask once,
|
|
110
|
+
naming the target: *"push `<branch>` to `<remote>` so <name> can pick it
|
|
111
|
+
up?"* Run it on a yes. On a no, stop: a hand-over the new owner cannot
|
|
112
|
+
reach is not a hand-over, so nothing is assigned.
|
|
113
|
+
- Then post the note it wrote onto the work item:
|
|
114
|
+
`skitterspec spec-sync comment <spec> --file <notePath>`. It names the
|
|
115
|
+
branch, the sha and the phases done, and a comment is the surface no later
|
|
116
|
+
push replaces. A failed post is said and does not stop the hand-over.
|
|
117
|
+
|
|
118
|
+
The new owner's `/spec-start <spec>` resumes from that branch rather than
|
|
119
|
+
forking a fresh one (`spec-env up` sees it on the remote).
|
|
120
|
+
4. Stamp it with the resolved id and display name.
|
|
121
|
+
5. Set `> **Developer:**` to that person's **Azure display name**.
|
|
83
122
|
|
|
84
123
|
This is the **one** place the tracker's name reaches the header, and the
|
|
85
124
|
exception is the whole reason it exists: there is no `git config user.name`
|
|
@@ -102,6 +102,29 @@ feature was designed not to disturb.
|
|
|
102
102
|
|
|
103
103
|
- Tick all completed tasks in the phase files; flip every finished phase-file
|
|
104
104
|
heading **and** every row in the `00-overview.md` phase index to `✅`.
|
|
105
|
+
|
|
106
|
+
**Who owns this spec's status.** Only when `specs/.core/azure-boards.config.json` exists.
|
|
107
|
+
Run `skitterspec spec-sync ownership --json` once and read both values:
|
|
108
|
+
|
|
109
|
+
- **`workflowState: "pull"`** — Azure Boards is the record of this spec's status, so
|
|
110
|
+
this skill **writes no `> **Status:**` header and appends no State log row**,
|
|
111
|
+
wherever its steps below say to. A spec this skill creates gets neither: its
|
|
112
|
+
header carries `> **Tracker:** <work item url>` instead, filled in once linking
|
|
113
|
+
has stamped the url, and its body has no `## State log` section. Readiness is
|
|
114
|
+
the spec's own content — a `Draft` is a spec whose **Open questions** is not
|
|
115
|
+
empty — so nothing is lost with the header.
|
|
116
|
+
- **`assignee: "pull"`** — Azure Boards holds who is building it, so this skill
|
|
117
|
+
**writes no `> **Developer:**` line** either.
|
|
118
|
+
- **Anything else** — `push`, `none`, sync reported off, or the command failing
|
|
119
|
+
— is cannot-tell, and the steps below run exactly as written.
|
|
120
|
+
|
|
121
|
+
What `pull` leaves alone: the folder move (a bucket records what the repo did to
|
|
122
|
+
the code, not a planning status), the phase files and index, and the Changelog.
|
|
123
|
+
A reason a `Status:` header would have carried — a cancellation's, a knock-back
|
|
124
|
+
to Draft — goes in a dated Changelog line instead. A spec that already carries
|
|
125
|
+
any of these lines keeps them untouched: they are history, and nothing rewrites
|
|
126
|
+
them.
|
|
127
|
+
|
|
105
128
|
- Set the **Status** header in the entry point:
|
|
106
129
|
`> **Status:** Complete (<YYYY-MM-DD>)`.
|
|
107
130
|
- Append a **State log** row:
|
|
@@ -136,6 +159,10 @@ PAT is set (see `apply.transport` in `azure-boards.config.md`).
|
|
|
136
159
|
complete/cancelled/reviewed in the repo regardless; the mirror is disposable
|
|
137
160
|
and the next push repairs it. Do not roll anything back, and do not stop to
|
|
138
161
|
ask.
|
|
162
|
+
- **In `/spec-complete`'s PR mode this push belongs to run 2.** Run 1 readies
|
|
163
|
+
a PR, and a ready PR is not a merged one — so skip it on run 1, even where
|
|
164
|
+
the `branch` lane committed the move to ride the PR, and run it on run 2 once
|
|
165
|
+
the host has merged. The tracker's Done lands when the work does.
|
|
139
166
|
- **Say what happened** in the skill's report: mirror updated, skipped as
|
|
140
167
|
unlinked, or failed with the reason.
|
|
141
168
|
- **There is no unassign step here.** The projection derives the assignee from
|
|
@@ -289,6 +316,27 @@ in that order, and stops at the first step that fails:
|
|
|
289
316
|
**Then stop: the worktree is kept** (step 7). The branch is what the next
|
|
290
317
|
`-hotfix.N` is cut from if this deploy fails, so it waits for the deploy.
|
|
291
318
|
|
|
319
|
+
**A branch-based hotfix** (`> **Base version:** <branch>@<sha>`, from
|
|
320
|
+
`hotfix.releaseBranch`) runs the same command and the same consent ask — the
|
|
321
|
+
engine picks the path from the header. What differs is what it does:
|
|
322
|
+
|
|
323
|
+
- it **rebases** onto `<remote>/<branch>` and **lands on the release branch** by
|
|
324
|
+
`land.strategy`: under `ff` the push of the hotfix onto that branch *is* the
|
|
325
|
+
land (so the consent ask names the release branch, not only a tag); under `pr`
|
|
326
|
+
it pushes the hotfix branch and opens a **ready** PR, then holds with
|
|
327
|
+
`the PR into <branch> is open` — re-run the same command once it merges;
|
|
328
|
+
- the **tag** is optional (`hotfix.tag`): cut and pushed after the land, or not
|
|
329
|
+
at all;
|
|
330
|
+
- the **carry** goes to the resolved base — the current rc under
|
|
331
|
+
`baseBranchPattern` — directly under `ff`, through a `carry/<slug>` branch and
|
|
332
|
+
its own ready PR under `pr`.
|
|
333
|
+
|
|
334
|
+
`Landed` then names the release branch, how it landed (fast-forward, or the PR
|
|
335
|
+
and whether it merged), the tag if one was cut, and the carry. A PR still
|
|
336
|
+
waiting on its merge is a `⚠️` — the land is not done until the host says so.
|
|
337
|
+
`spec-env hotfix finish` tears it down once both the land and the carry are
|
|
338
|
+
confirmed, naming every check that is not.
|
|
339
|
+
|
|
292
340
|
### 6-feature/bug. `Type: Feature` / `Type: Bug` — rebase + fast-forward
|
|
293
341
|
|
|
294
342
|
Land the finished branch on the base branch so the work reaches `main` (or your
|
|
@@ -324,6 +372,19 @@ is finished — e.g. to run a later phase in CI or a shared test env? Use
|
|
|
324
372
|
`git -C <worktree> rebase --abort`, relay the conflict, and **stop** — leave it
|
|
325
373
|
to the user; do not tear anything down.
|
|
326
374
|
On a **no-op** ("already landed"), just say so and continue.
|
|
375
|
+
|
|
376
|
+
**Under a rolling base** (`baseBranchPattern` in `env.config.json`) the plan
|
|
377
|
+
can carry two more things, and both are the engine's to say:
|
|
378
|
+
- a `git -C <mainRepoPath> switch <base>` (or `switch -c … --track`) **first**,
|
|
379
|
+
when the primary checkout still has an older release candidate out — run it
|
|
380
|
+
in order with the rest;
|
|
381
|
+
- a `retarget: forked from <old> · landing onto <new>` line, when the rc
|
|
382
|
+
rolled while this spec was in flight. It is the land working, not a fault:
|
|
383
|
+
relay it verbatim in the `Landed` row so the reader sees where the work went.
|
|
384
|
+
|
|
385
|
+
A refusal naming `no branch matches <pattern>` means no release candidate is
|
|
386
|
+
visible — usually not fetched. Relay it, stop with `⏸`, and name
|
|
387
|
+
`skitterspec spec-env base` (it fetches and lists) as the next step.
|
|
327
388
|
3. **Run the after-land commands.** Where the plan ends with a
|
|
328
389
|
`then, in the primary checkout (<path>), run:` section — the project's
|
|
329
390
|
`afterLand`, such as a data migration — run those commands in that
|
|
@@ -343,6 +404,58 @@ is finished — e.g. to run a later phase in CI or a shared test env? Use
|
|
|
343
404
|
5. **Report** the landing (base branch, fast-forward result). It **never pushes** —
|
|
344
405
|
mention the user can `git push` the base branch themselves.
|
|
345
406
|
|
|
407
|
+
### 6-pr. PR mode (`land.strategy: "pr"`) — dispose, push, ready; finish after the merge
|
|
408
|
+
|
|
409
|
+
Completion is **two runs** here, the `hotfix land`/`finish` shape: the merge is
|
|
410
|
+
the host's act and may be days away, so the run that readies the PR cannot also
|
|
411
|
+
finalise. Which run this is, the engine says: `spec-env integrate <name>`
|
|
412
|
+
printing a `(pr)` plan is run 1; printing
|
|
413
|
+
`already landed … — finish what the merge deferred` is run 2.
|
|
414
|
+
|
|
415
|
+
**Run 1 — the last control point.** Once the PR is ready, anyone can merge from
|
|
416
|
+
the host UI and the tracker's automations act — so everything that needs a
|
|
417
|
+
person happens before the ready, in this order:
|
|
418
|
+
|
|
419
|
+
1. **Disposition pass — mandatory, before anything is pushed.** Run
|
|
420
|
+
`skitterspec spec-env disposition <name> --json`. For every unticked task,
|
|
421
|
+
non-✅ phase and surfaced follow-up it lists, the user disposes it:
|
|
422
|
+
**tick** (it was done — tick it, naming the evidence) · **spin off** (a
|
|
423
|
+
follow-on ticket minted now, linked to this one — offer `/spec` or the
|
|
424
|
+
provider's mint) · **drop** (a dated Changelog line with the reason, the
|
|
425
|
+
`none: <reason>` grammar). Batch the asking; never decide for them, and
|
|
426
|
+
never auto-create. **Refuse to ready the PR while anything is undisposed**
|
|
427
|
+
— you asked the enumeration, so it cannot also be fine. `clean` proceeds
|
|
428
|
+
with nothing asked.
|
|
429
|
+
2. **Consent, naming the target.** Ask once, plainly:
|
|
430
|
+
*"push `<branch>` and open the PR into `<base>` on `<remote>`, ready for
|
|
431
|
+
merge?"* — the base branch is named so a spec that outlived a release roll
|
|
432
|
+
is caught by the person reading a stale rc name. On a no, stop with the
|
|
433
|
+
held commands relayed.
|
|
434
|
+
3. **Run the plan.** `skitterspec spec-env integrate <name> --push` and run
|
|
435
|
+
what it prints: fetch, rebase onto `<remote>/<base>`, the push, and the PR
|
|
436
|
+
create — or, where a draft already exists, the flip-to-ready. A rebase
|
|
437
|
+
conflict aborts and stops exactly as 6-feature/bug step 2.
|
|
438
|
+
4. **Defer the finalise.** §4's bucket move follows the spec documents'
|
|
439
|
+
`land.specDocs` lane: under `trunk` leave the spec in `specs/in-progress/`
|
|
440
|
+
— run 2 moves it on base after the merge; under `branch` commit the move on
|
|
441
|
+
the branch *before* step 3 so it rides the PR. Either way
|
|
442
|
+
**the tracker's Done waits for run 2**: a ready PR is not a merged one.
|
|
443
|
+
5. **Stop, keeping the worktree.** Report
|
|
444
|
+
`Landed: PR #N opened — finish after merge` (or `ready`), spec
|
|
445
|
+
`In Progress`, worktree standing. No afterLand runs — the plan deferred it
|
|
446
|
+
— and no teardown. The merge is what un-blocks run 2; nothing here waits on
|
|
447
|
+
it.
|
|
448
|
+
|
|
449
|
+
**Run 2 — after the host merges.** `integrate` recognises the landed branch
|
|
450
|
+
(ancestry or the host's answer) and prints the finish: catch local base up and
|
|
451
|
+
the deferred `afterLand` with the land's own range. Run those, then do what run
|
|
452
|
+
1 deferred — the §4 move (trunk lane) with its State log row and commit, the
|
|
453
|
+
§5 report — then **§7 teardown runs as normal**:
|
|
454
|
+
a host-merged branch counts as landed (squash and rebase
|
|
455
|
+
merges included), and a host that auto-deleted the branch makes the remote
|
|
456
|
+
delete an already-gone no-op, never a failure. Re-test on base before calling
|
|
457
|
+
it done, exactly as 6-feature/bug step 4.
|
|
458
|
+
|
|
346
459
|
## 7. Tear down the environment (opt-in, only if configured)
|
|
347
460
|
|
|
348
461
|
**A hotfix is torn down later, by `hotfix finish`.**
|