@gobing-ai/spur 0.3.40 → 0.3.42
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/.claude-plugin/marketplace.json +15 -0
- package/README.md +15 -1
- package/config/templates/AGENTS.md +5 -3
- package/config/workflows/task-pipeline.yaml +103 -12
- package/package.json +15 -12
- package/plugins/README.md +655 -0
- package/plugins/sp/README.md +621 -0
- package/plugins/sp/agents/expert-spur.md +109 -0
- package/plugins/sp/agents/super-coder.md +126 -0
- package/plugins/sp/agents/super-planner.md +283 -0
- package/plugins/sp/agents/super-reviewer.md +154 -0
- package/plugins/sp/commands/dev-arch.md +30 -0
- package/plugins/sp/commands/dev-brainstorm.md +40 -0
- package/plugins/sp/commands/dev-changelog.md +28 -0
- package/plugins/sp/commands/dev-daily.md +29 -0
- package/plugins/sp/commands/dev-debug.md +29 -0
- package/plugins/sp/commands/dev-dogfood.md +33 -0
- package/plugins/sp/commands/dev-featurechange.md +130 -0
- package/plugins/sp/commands/dev-find-conflict.md +51 -0
- package/plugins/sp/commands/dev-find-issue.md +76 -0
- package/plugins/sp/commands/dev-find-next.md +60 -0
- package/plugins/sp/commands/dev-fixall.md +33 -0
- package/plugins/sp/commands/dev-gitmsg.md +28 -0
- package/plugins/sp/commands/dev-gtd.md +97 -0
- package/plugins/sp/commands/dev-handover.md +26 -0
- package/plugins/sp/commands/dev-idea.md +50 -0
- package/plugins/sp/commands/dev-next.md +31 -0
- package/plugins/sp/commands/dev-parallel.md +30 -0
- package/plugins/sp/commands/dev-plan.md +46 -0
- package/plugins/sp/commands/dev-refine.md +48 -0
- package/plugins/sp/commands/dev-refineall.md +65 -0
- package/plugins/sp/commands/dev-refresh.md +32 -0
- package/plugins/sp/commands/dev-reverse.md +32 -0
- package/plugins/sp/commands/dev-review.md +31 -0
- package/plugins/sp/commands/dev-run.md +63 -0
- package/plugins/sp/commands/dev-runall.md +80 -0
- package/plugins/sp/commands/dev-simplify.md +39 -0
- package/plugins/sp/commands/dev-unit.md +29 -0
- package/plugins/sp/commands/dev-verify.md +48 -0
- package/plugins/sp/commands/dev-verifyall.md +72 -0
- package/plugins/sp/commands/dev-wrap.md +30 -0
- package/plugins/sp/commands/dev-wrapall.md +33 -0
- package/plugins/sp/commands/rule-add.md +18 -0
- package/plugins/sp/commands/rule-refine.md +18 -0
- package/plugins/sp/commands/rule-scan.md +18 -0
- package/plugins/sp/commands/spur-init.md +22 -0
- package/plugins/sp/commands/workflow-add.md +18 -0
- package/plugins/sp/commands/workflow-refine.md +18 -0
- package/plugins/sp/hooks/agent-hint.ts +60 -0
- package/plugins/sp/hooks/careful-guard.ts +147 -0
- package/plugins/sp/hooks/context-post-tool.ts +325 -0
- package/plugins/sp/hooks/context-session-start.ts +182 -0
- package/plugins/sp/hooks/context-session-stop.ts +95 -0
- package/plugins/sp/hooks/hooks.json +51 -0
- package/plugins/sp/hooks/pi/guard-extension.ts +341 -0
- package/plugins/sp/hooks/task-write-guard.ts +84 -0
- package/plugins/sp/plugin.json +8 -0
- package/plugins/sp/scripts/batch-preflight.ts +204 -0
- package/plugins/sp/scripts/daily-summary/daily-summary.ts +606 -0
- package/plugins/sp/scripts/daily-summary/logger.ts +28 -0
- package/plugins/sp/scripts/dogfood-testing/detect-pipeline-driving.ts +363 -0
- package/plugins/sp/scripts/dogfood-testing/validate-report.ts +168 -0
- package/plugins/sp/scripts/feature-sync-bounded.ts +451 -0
- package/plugins/sp/scripts/stage-registry-adapter.ts +1341 -0
- package/plugins/sp/scripts/task-size-precheck.ts +202 -0
- package/plugins/sp/scripts/validate-commands.ts +651 -0
- package/plugins/sp/scripts/validate-flag-contracts.ts +875 -0
- package/plugins/sp/skills/brainstorm/SKILL.md +361 -0
- package/plugins/sp/skills/brainstorm/agents/openai.yaml +14 -0
- package/plugins/sp/skills/brainstorm/examples/ideation-example.md +209 -0
- package/plugins/sp/skills/brainstorm/metadata.openclaw +7 -0
- package/plugins/sp/skills/brainstorm/references/grilling-interview.md +68 -0
- package/plugins/sp/skills/brainstorm/references/workflows.md +255 -0
- package/plugins/sp/skills/branch-workflow/SKILL.md +109 -0
- package/plugins/sp/skills/branch-workflow/references/branch-lifecycle.md +69 -0
- package/plugins/sp/skills/branch-workflow/references/worktree-patterns.md +100 -0
- package/plugins/sp/skills/code-implementation/SKILL.md +176 -0
- package/plugins/sp/skills/code-implementation/references/debugging.md +64 -0
- package/plugins/sp/skills/code-implementation/references/implementation-patterns.md +113 -0
- package/plugins/sp/skills/code-improvement/SKILL.md +231 -0
- package/plugins/sp/skills/code-improvement/references/deepening-signals.md +205 -0
- package/plugins/sp/skills/code-review/SKILL.md +112 -0
- package/plugins/sp/skills/code-review/references/receiving-code-review.md +70 -0
- package/plugins/sp/skills/code-review/references/review-lenses.md +117 -0
- package/plugins/sp/skills/code-review/references/self-review-checklist.md +53 -0
- package/plugins/sp/skills/code-review/references/verification-before-completion.md +68 -0
- package/plugins/sp/skills/code-simplification/SKILL.md +225 -0
- package/plugins/sp/skills/code-testing/SKILL.md +108 -0
- package/plugins/sp/skills/code-testing/references/stacks/bun-ts.md +165 -0
- package/plugins/sp/skills/code-testing/references/stacks/go.md +88 -0
- package/plugins/sp/skills/code-testing/references/stacks/python.md +117 -0
- package/plugins/sp/skills/code-testing/references/test-loop-breaker.md +37 -0
- package/plugins/sp/skills/code-testing/references/test-output-discipline.md +52 -0
- package/plugins/sp/skills/code-testing/references/unit-testing.md +212 -0
- package/plugins/sp/skills/code-verification/SKILL.md +535 -0
- package/plugins/sp/skills/code-verification/references/code-improvement.md +39 -0
- package/plugins/sp/skills/code-verification/references/secu-review.md +94 -0
- package/plugins/sp/skills/code-verification/references/verdict-schema.md +141 -0
- package/plugins/sp/skills/conflict-finding/SKILL.md +254 -0
- package/plugins/sp/skills/conflict-finding/references/authority-resolution.md +258 -0
- package/plugins/sp/skills/conflict-finding/references/comparison-protocol.md +277 -0
- package/plugins/sp/skills/conflict-finding/references/finding-contract.md +346 -0
- package/plugins/sp/skills/conflict-finding/references/remediation-routing.md +276 -0
- package/plugins/sp/skills/daily-summary/SKILL.md +171 -0
- package/plugins/sp/skills/daily-summary/agents/openai.yaml +13 -0
- package/plugins/sp/skills/doc-evolve/SKILL.md +175 -0
- package/plugins/sp/skills/doc-evolve/references/operations.md +93 -0
- package/plugins/sp/skills/dogfood-testing/SKILL.md +608 -0
- package/plugins/sp/skills/dogfood-testing/references/monitor-ledger.md +211 -0
- package/plugins/sp/skills/dogfood-testing/references/report-template.md +351 -0
- package/plugins/sp/skills/doubt-driven-development/SKILL.md +136 -0
- package/plugins/sp/skills/functional-review/SKILL.md +364 -0
- package/plugins/sp/skills/functional-review/references/verdict-schema.md +133 -0
- package/plugins/sp/skills/indexed-context/SKILL.md +164 -0
- package/plugins/sp/skills/issue-finding/SKILL.md +424 -0
- package/plugins/sp/skills/issue-finding/agents/openai.yaml +15 -0
- package/plugins/sp/skills/issue-finding/examples/expected-findings.json +27 -0
- package/plugins/sp/skills/issue-finding/examples/session-test-loop.jsonl +23 -0
- package/plugins/sp/skills/issue-finding/references/session-formats.md +121 -0
- package/plugins/sp/skills/next-feature/SKILL.md +125 -0
- package/plugins/sp/skills/next-feature/references/handoff-routing.md +92 -0
- package/plugins/sp/skills/next-feature/references/proposal-contract.md +49 -0
- package/plugins/sp/skills/next-feature/references/ranking-rubric.md +52 -0
- package/plugins/sp/skills/next-feature/references/signal-derivation.md +67 -0
- package/plugins/sp/skills/next-router/SKILL.md +181 -0
- package/plugins/sp/skills/next-router/references/messages.md +90 -0
- package/plugins/sp/skills/next-router/references/routing-table.md +216 -0
- package/plugins/sp/skills/parallel-execution/SKILL.md +148 -0
- package/plugins/sp/skills/parallel-execution/references/dispatch-surface.md +100 -0
- package/plugins/sp/skills/parallel-execution/references/fan-out-patterns.md +101 -0
- package/plugins/sp/skills/parallel-execution/references/result-synthesis.md +94 -0
- package/plugins/sp/skills/reverse-engineering/SKILL.md +375 -0
- package/plugins/sp/skills/reverse-engineering/agents/openai.yaml +18 -0
- package/plugins/sp/skills/source-driven-development/SKILL.md +124 -0
- package/plugins/sp/skills/spec-decomposition/SKILL.md +117 -0
- package/plugins/sp/skills/spec-decomposition/references/decomposition.md +539 -0
- package/plugins/sp/skills/spur-cli/SKILL.md +133 -0
- package/plugins/sp/skills/spur-cli/references/agent.md +179 -0
- package/plugins/sp/skills/spur-cli/references/features/acceptance-criteria.md +82 -0
- package/plugins/sp/skills/spur-cli/references/features/hierarchy-mece.md +177 -0
- package/plugins/sp/skills/spur-cli/references/features/roadmap-priority.md +84 -0
- package/plugins/sp/skills/spur-cli/references/features/verbs.md +122 -0
- package/plugins/sp/skills/spur-cli/references/features.md +234 -0
- package/plugins/sp/skills/spur-cli/references/init.md +119 -0
- package/plugins/sp/skills/spur-cli/references/message.md +98 -0
- package/plugins/sp/skills/spur-cli/references/rules/authoring-rules.md +212 -0
- package/plugins/sp/skills/spur-cli/references/rules/fine-tuning.md +148 -0
- package/plugins/sp/skills/spur-cli/references/rules/operations.md +228 -0
- package/plugins/sp/skills/spur-cli/references/rules/validation-and-extension.md +129 -0
- package/plugins/sp/skills/spur-cli/references/rules.md +209 -0
- package/plugins/sp/skills/spur-cli/references/serve.md +58 -0
- package/plugins/sp/skills/spur-cli/references/tasks/l3-guard-cheatsheet.md +98 -0
- package/plugins/sp/skills/spur-cli/references/tasks/section-editing.md +95 -0
- package/plugins/sp/skills/spur-cli/references/tasks/verbs.md +361 -0
- package/plugins/sp/skills/spur-cli/references/tasks.md +278 -0
- package/plugins/sp/skills/spur-cli/references/team.md +133 -0
- package/plugins/sp/skills/spur-cli/references/workflows/authoring-workflows.md +226 -0
- package/plugins/sp/skills/spur-cli/references/workflows/operations.md +211 -0
- package/plugins/sp/skills/spur-cli/references/workflows/validation-and-extension.md +129 -0
- package/plugins/sp/skills/spur-cli/references/workflows.md +355 -0
- package/plugins/sp/skills/spur-dev/SKILL.md +224 -0
- package/plugins/sp/skills/spur-dev/references/ac-style-guide.md +196 -0
- package/plugins/sp/skills/spur-dev/references/cross-cutting.md +664 -0
- package/plugins/sp/skills/spur-dev/references/decision-brief.md +80 -0
- package/plugins/sp/skills/spur-dev/references/dev-operations.md +546 -0
- package/plugins/sp/skills/spur-dev/references/done-housekeeping.md +164 -0
- package/plugins/sp/skills/spur-dev/references/execution-batch.md +727 -0
- package/plugins/sp/skills/spur-dev/references/execution-workflow.md +350 -0
- package/plugins/sp/skills/spur-dev/references/feature-link-helper.md +191 -0
- package/plugins/sp/skills/spur-dev/references/flag-glossary.md +417 -0
- package/plugins/sp/skills/spur-dev/references/gate-checklists.md +171 -0
- package/plugins/sp/skills/spur-dev/references/glossary.md +95 -0
- package/plugins/sp/skills/spur-dev/references/idea-evaluation.md +80 -0
- package/plugins/sp/skills/spur-dev/references/inline-pipeline-driver.md +88 -0
- package/plugins/sp/skills/spur-dev/references/planning-workflow.md +302 -0
- package/plugins/sp/skills/spur-dev/references/product-planning.md +206 -0
- package/plugins/sp/skills/spur-dev/references/section-batching.md +24 -0
- package/plugins/sp/skills/sys-architecture/SKILL.md +155 -0
- package/plugins/sp/skills/sys-architecture/references/decision-method.md +137 -0
- package/plugins/sp/skills/sys-architecture/references/upkeep-survey.md +75 -0
- package/plugins/sp/skills/sys-debugging/SKILL.md +228 -0
- package/plugins/sp/skills/sys-debugging/references/debugging-protocol.md +62 -0
- package/plugins/sp/skills/test-driven-development/SKILL.md +248 -0
- package/plugins/sp/skills/wayfinder/SKILL.md +292 -0
- package/spur.js +6093 -5180
package/README.md
CHANGED
|
@@ -23,6 +23,20 @@ spur --help
|
|
|
23
23
|
bunx @gobing-ai/spur --help
|
|
24
24
|
```
|
|
25
25
|
|
|
26
|
+
#### Install the `sp` plugin to your coding agents
|
|
27
|
+
|
|
28
|
+
The npm package ships the `sp` plugin and its marketplace manifest alongside the CLI. Install it
|
|
29
|
+
into your supported coding agents without cloning this repository:
|
|
30
|
+
|
|
31
|
+
```bash
|
|
32
|
+
# point superskill at the installed @gobing-ai/spur package root
|
|
33
|
+
superskill install sp --marketplace $(npm root -g)/@gobing-ai/spur
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
(With Bun: `bun install -g @gobing-ai/spur`; the package root is `$(npm root -g)/@gobing-ai/spur`
|
|
37
|
+
or `$(bun pm bin -g)/../lib/node_modules/@gobing-ai/spur`.) This registers the marketplace and
|
|
38
|
+
installs the `sp` plugin to Claude Code, Codex, Gemini CLI, pi, omp, OpenCode, Antigravity, etc.
|
|
39
|
+
|
|
26
40
|
### If you don't have Bun — standalone binary
|
|
27
41
|
|
|
28
42
|
A self-contained executable (Bun embedded) for macOS and Linux. No runtime to install.
|
|
@@ -50,7 +64,7 @@ Windows: use the Bun path under WSL.
|
|
|
50
64
|
The published tarball is a self-contained Bun bundle plus static assets:
|
|
51
65
|
|
|
52
66
|
| Path | Purpose |
|
|
53
|
-
|
|
67
|
+
| ------ | --------- |
|
|
54
68
|
| `spur.js` | CLI entry (`bin.spur`) |
|
|
55
69
|
| `config/` | Default rules, workflows, tasks, templates, plugins (ADR-015 SSOT) |
|
|
56
70
|
| `web/` | Spur Board SPA served by `spur serve` |
|
|
@@ -36,7 +36,7 @@ All product development work goes through the harness by default.
|
|
|
36
36
|
| ------ | ---------- | -------- |
|
|
37
37
|
| Plan a feature (intake → AC → tasks) | `/sp:dev-plan`, `/sp:dev-idea` | Freeform feature files without gates |
|
|
38
38
|
| Drive one task end-to-end | `/sp:dev-run <wbs>` or **`sp:super-planner`** | Implement with no task / no pipeline |
|
|
39
|
-
| Batch or parallel task runs | `/sp:dev-runall
|
|
39
|
+
| Batch or parallel task runs | `/sp:dev-runall` (host sequential; **`sp:super-planner`** explicit/parallel), `/sp:dev-parallel` | Unordered multi-task thrash |
|
|
40
40
|
| Batch-refine tasks under a feature | `/sp:dev-refineall --feature <id> --auto` | Hand-looping `/sp:dev-refine` per WBS |
|
|
41
41
|
| Multi-step corpus CLI (tasks/features/rules/workflows) | **`sp:expert-spur`** | Raw Write/Edit on corpus files |
|
|
42
42
|
| Look up `spur` verbs / flags / `--json` | Skill **`sp:spur-cli`** | Inventing flags from memory |
|
|
@@ -64,8 +64,10 @@ All product development work goes through the harness by default.
|
|
|
64
64
|
5. **Keep tool ownership explicit** — project lifecycle/corpus/gates → Spur; plugin installation and
|
|
65
65
|
capability lifecycle → Superskill. Do not hand-maintain per-platform adapters Superskill generates.
|
|
66
66
|
6. **Run dev skills inline by default** — direct model-bearing `/sp:dev-*` commands execute in the
|
|
67
|
-
current coding-agent session.
|
|
68
|
-
`
|
|
67
|
+
current coding-agent session. Interactive `/sp:dev-run --mode full` and sequential
|
|
68
|
+
`/sp:dev-runall` with omit/`--agent inline` interpret `task-pipeline.yaml` in-session; `--agent
|
|
69
|
+
auto`, a name, parallel/headless execution, direct `spur agent run`, and engine-driven workflow
|
|
70
|
+
`agent.run` remain subprocess surfaces.
|
|
69
71
|
|
|
70
72
|
**Platform fallback:** Platforms without slash commands and/or subagents still use the harness.
|
|
71
73
|
Install the plugin through Superskill for the target platform, then use skills `sp:spur-dev`,
|
|
@@ -131,11 +131,29 @@ states:
|
|
|
131
131
|
# semantics are deliberately untouched; the gate lives here.
|
|
132
132
|
# R4 (0487): one divergence line when the two executors differ (legitimate
|
|
133
133
|
# when only implementAgent is pinned, but it must be visible in the log).
|
|
134
|
+
# R2 (0503): omp/pi env-key probe misses are soft because the CLI process
|
|
135
|
+
# cannot see relay-owned credentials; explicit non-omp auth failures remain hard.
|
|
134
136
|
- kind: shell
|
|
135
137
|
options:
|
|
136
138
|
command: >-
|
|
137
139
|
mkdir -p .spur/run &&
|
|
138
140
|
DOCTOR_FILE=".spur/run/$wbs-precheck-doctor.status" &&
|
|
141
|
+
classifyDoctorProbe() {
|
|
142
|
+
PROBE_DETAIL="$1";
|
|
143
|
+
PROBE_AGENT="$2";
|
|
144
|
+
case "$PROBE_AGENT" in
|
|
145
|
+
omp|omp-*|pi|pi-*)
|
|
146
|
+
if printf '%s' "$PROBE_DETAIL" | grep -Eiq 'API key not found for provider|no probe registered'; then
|
|
147
|
+
printf 'env-miss\n';
|
|
148
|
+
return;
|
|
149
|
+
fi;;
|
|
150
|
+
esac;
|
|
151
|
+
if printf '%s' "$PROBE_DETAIL" | grep -Eiq 'invalid (API )?key|unauthori[sz]ed|forbidden|authentication failed|credential(s)? rejected'; then
|
|
152
|
+
printf 'auth-fail\n';
|
|
153
|
+
else
|
|
154
|
+
printf 'unknown\n';
|
|
155
|
+
fi;
|
|
156
|
+
} &&
|
|
139
157
|
STATUS=PASS;
|
|
140
158
|
if [ -n "$implementAgent" ] && [ "$implementAgent" != "$agent" ]; then
|
|
141
159
|
echo "precheck: agent=$agent implementAgent=$implementAgent (executors diverge)";
|
|
@@ -152,10 +170,16 @@ states:
|
|
|
152
170
|
};
|
|
153
171
|
AUTH=$(printf '%s' "$OUT" | jq -r '.agents[0].authenticated // "unknown"' 2>/dev/null || echo unknown);
|
|
154
172
|
DETAIL=$(printf '%s' "$OUT" | jq -r '.agents[0].modelStatus.detail // ""' 2>/dev/null || echo "");
|
|
155
|
-
|
|
173
|
+
PROBE=$(classifyDoctorProbe "$DETAIL" "$EXE");
|
|
174
|
+
echo "precheck: $EXE auth=$AUTH probe=$PROBE $DETAIL";
|
|
156
175
|
if [ "$AUTH" = unauthenticated ]; then
|
|
157
|
-
|
|
158
|
-
|
|
176
|
+
case "$EXE:$PROBE" in
|
|
177
|
+
omp*:env-miss|pi*:env-miss|omp*:unknown|pi*:unknown)
|
|
178
|
+
echo "precheck: SOFT - executor $EXE auth probe cannot see agent-owned credentials";;
|
|
179
|
+
*)
|
|
180
|
+
echo "precheck: FAIL - executor $EXE is unauthenticated; fix agent.default or pass --vars '{\"agent\":\"<authenticated-executor>\"}' ($spurBin agent doctor $EXE --json); $DETAIL";
|
|
181
|
+
STATUS=FAIL;;
|
|
182
|
+
esac;
|
|
159
183
|
fi;
|
|
160
184
|
done;
|
|
161
185
|
echo "$STATUS" > "$DOCTOR_FILE";
|
|
@@ -238,7 +262,21 @@ states:
|
|
|
238
262
|
requireDiff: true
|
|
239
263
|
- kind: shell
|
|
240
264
|
options:
|
|
241
|
-
command:
|
|
265
|
+
command: >-
|
|
266
|
+
retry_transient() {
|
|
267
|
+
RETRY_OUTPUT=$("$@" 2>&1); RETRY_RC=$?;
|
|
268
|
+
printf '%s\n' "$RETRY_OUTPUT";
|
|
269
|
+
if [ "$RETRY_RC" -eq 0 ]; then return 0; fi;
|
|
270
|
+
if ! printf '%s' "$RETRY_OUTPUT" | grep -Eq 'ENOENT|EBUSY|ENOTEMPTY|database is locked'; then return "$RETRY_RC"; fi;
|
|
271
|
+
sleep 2;
|
|
272
|
+
RETRY_SECOND_OUTPUT=$("$@" 2>&1); RETRY_RC=$?;
|
|
273
|
+
printf '%s\n' "$RETRY_SECOND_OUTPUT";
|
|
274
|
+
if [ "$RETRY_RC" -ne 0 ] && printf '%s\n%s' "$RETRY_OUTPUT" "$RETRY_SECOND_OUTPUT" | grep -Eq 'ENOENT|EBUSY|ENOTEMPTY'; then
|
|
275
|
+
echo "node_modules link/dependency broken — run bun install and retry";
|
|
276
|
+
fi;
|
|
277
|
+
return "$RETRY_RC";
|
|
278
|
+
};
|
|
279
|
+
retry_transient $spurBin task update "$wbs" wip --no-lifecycle
|
|
242
280
|
# Post-implement cleanup: auto-format any unformatted output the agent produced.
|
|
243
281
|
# The agent may leave files that don't pass `biome check`, which then fails
|
|
244
282
|
# `bun run lint` downstream. Running format here is cheap (< 1 s) and prevents
|
|
@@ -265,7 +303,8 @@ states:
|
|
|
265
303
|
# test-recheck — soft recheck → review | test-fix | failed (never silent lifecycle abort)
|
|
266
304
|
- id: test
|
|
267
305
|
description: >
|
|
268
|
-
Soft quality-gate probe (single
|
|
306
|
+
Soft quality-gate probe (single logical gate on the green path; bounded retries only
|
|
307
|
+
for SQLite lock contention). Runs
|
|
269
308
|
`${vars.qualityGateCmd}`, records PASS|FAIL under
|
|
270
309
|
`.spur/run/<wbs>-test-gate.status`, resets the fix attempt counter, always exit 0.
|
|
271
310
|
onEnter:
|
|
@@ -277,8 +316,20 @@ states:
|
|
|
277
316
|
LOG_FILE=".spur/run/$wbs-test-gate.log" &&
|
|
278
317
|
ATTEMPT_FILE=".spur/run/$wbs-test-fix-attempt" &&
|
|
279
318
|
echo 0 > "$ATTEMPT_FILE" &&
|
|
280
|
-
|
|
281
|
-
|
|
319
|
+
: > "$LOG_FILE" &&
|
|
320
|
+
gate_attempt=1;
|
|
321
|
+
while [ "$gate_attempt" -le 5 ]; do
|
|
322
|
+
ATTEMPT_LOG="$LOG_FILE.attempt-$gate_attempt";
|
|
323
|
+
sh -c "$qualityGateCmd" > "$ATTEMPT_LOG" 2>&1; gate_rc=$?;
|
|
324
|
+
gate_locked=0;
|
|
325
|
+
grep -q 'SQLiteError: database is locked' "$ATTEMPT_LOG" && gate_locked=1;
|
|
326
|
+
cat "$ATTEMPT_LOG" >> "$LOG_FILE";
|
|
327
|
+
rm -f "$ATTEMPT_LOG";
|
|
328
|
+
if [ "$gate_rc" -eq 0 ] || [ "$gate_locked" -ne 1 ] || [ "$gate_attempt" -ge 5 ]; then break; fi;
|
|
329
|
+
printf 'quality gate: database is locked; retrying (%s/5) in 10s\n' "$gate_attempt" | tee -a "$LOG_FILE";
|
|
330
|
+
sleep 10;
|
|
331
|
+
gate_attempt=$((gate_attempt + 1));
|
|
332
|
+
done &&
|
|
282
333
|
cat "$LOG_FILE" &&
|
|
283
334
|
FINDINGS_FILE=".spur/run/$wbs-test-gate.findings" &&
|
|
284
335
|
set +e; grep -oE '[A-Za-z0-9_./-]+\.[A-Za-z]+:[0-9]+' "$LOG_FILE" | sort -u | head -20 | tr '\n' ' ' > "$FINDINGS_FILE"; set -e &&
|
|
@@ -319,7 +370,7 @@ states:
|
|
|
319
370
|
|
|
320
371
|
- id: test-recheck
|
|
321
372
|
description: >
|
|
322
|
-
Soft recheck after fixall. Writes PASS|FAIL (always exit 0). Transitions
|
|
373
|
+
Soft recheck after fixall with bounded SQLite-lock retry. Writes PASS|FAIL (always exit 0). Transitions
|
|
323
374
|
branch to review (PASS), another test-fix (FAIL and under max attempts),
|
|
324
375
|
or the pipeline `failed` state (FAIL and attempts exhausted) — never a
|
|
325
376
|
raw lifecycle abort that skips the terminal `failed` state.
|
|
@@ -330,8 +381,20 @@ states:
|
|
|
330
381
|
mkdir -p .spur/run &&
|
|
331
382
|
STATUS_FILE=".spur/run/$wbs-test-gate.status" &&
|
|
332
383
|
LOG_FILE=".spur/run/$wbs-test-gate.log" &&
|
|
333
|
-
|
|
334
|
-
|
|
384
|
+
: > "$LOG_FILE" &&
|
|
385
|
+
gate_attempt=1;
|
|
386
|
+
while [ "$gate_attempt" -le 5 ]; do
|
|
387
|
+
ATTEMPT_LOG="$LOG_FILE.attempt-$gate_attempt";
|
|
388
|
+
sh -c "$qualityGateCmd" > "$ATTEMPT_LOG" 2>&1; gate_rc=$?;
|
|
389
|
+
gate_locked=0;
|
|
390
|
+
grep -q 'SQLiteError: database is locked' "$ATTEMPT_LOG" && gate_locked=1;
|
|
391
|
+
cat "$ATTEMPT_LOG" >> "$LOG_FILE";
|
|
392
|
+
rm -f "$ATTEMPT_LOG";
|
|
393
|
+
if [ "$gate_rc" -eq 0 ] || [ "$gate_locked" -ne 1 ] || [ "$gate_attempt" -ge 5 ]; then break; fi;
|
|
394
|
+
printf 'quality gate: database is locked; retrying (%s/5) in 10s\n' "$gate_attempt" | tee -a "$LOG_FILE";
|
|
395
|
+
sleep 10;
|
|
396
|
+
gate_attempt=$((gate_attempt + 1));
|
|
397
|
+
done &&
|
|
335
398
|
cat "$LOG_FILE" &&
|
|
336
399
|
FINDINGS_FILE=".spur/run/$wbs-test-gate.findings" &&
|
|
337
400
|
set +e; grep -oE '[A-Za-z0-9_./-]+\.[A-Za-z]+:[0-9]+' "$LOG_FILE" | sort -u | head -20 | tr '\n' ' ' > "$FINDINGS_FILE"; set -e &&
|
|
@@ -396,7 +459,21 @@ states:
|
|
|
396
459
|
onEnter:
|
|
397
460
|
- kind: shell
|
|
398
461
|
options:
|
|
399
|
-
command:
|
|
462
|
+
command: >-
|
|
463
|
+
retry_transient() {
|
|
464
|
+
RETRY_OUTPUT=$("$@" 2>&1); RETRY_RC=$?;
|
|
465
|
+
printf '%s\n' "$RETRY_OUTPUT";
|
|
466
|
+
if [ "$RETRY_RC" -eq 0 ]; then return 0; fi;
|
|
467
|
+
if ! printf '%s' "$RETRY_OUTPUT" | grep -Eq 'ENOENT|EBUSY|ENOTEMPTY|database is locked'; then return "$RETRY_RC"; fi;
|
|
468
|
+
sleep 2;
|
|
469
|
+
RETRY_SECOND_OUTPUT=$("$@" 2>&1); RETRY_RC=$?;
|
|
470
|
+
printf '%s\n' "$RETRY_SECOND_OUTPUT";
|
|
471
|
+
if [ "$RETRY_RC" -ne 0 ] && printf '%s\n%s' "$RETRY_OUTPUT" "$RETRY_SECOND_OUTPUT" | grep -Eq 'ENOENT|EBUSY|ENOTEMPTY'; then
|
|
472
|
+
echo "node_modules link/dependency broken — run bun install and retry";
|
|
473
|
+
fi;
|
|
474
|
+
return "$RETRY_RC";
|
|
475
|
+
};
|
|
476
|
+
retry_transient $spurBin task record "$wbs" --solution-from-diff --transition testing
|
|
400
477
|
# Best-effort, and portable across layouts. `feature-sync-bounded.ts` is a
|
|
401
478
|
# Spur-monorepo path — `spur init` never scaffolds `plugins/sp/`, so a seeded
|
|
402
479
|
# project must fall back to the plain `spur feature sync` verb rather than
|
|
@@ -427,7 +504,21 @@ states:
|
|
|
427
504
|
onEnter:
|
|
428
505
|
- kind: shell
|
|
429
506
|
options:
|
|
430
|
-
command:
|
|
507
|
+
command: >-
|
|
508
|
+
retry_transient() {
|
|
509
|
+
RETRY_OUTPUT=$("$@" 2>&1); RETRY_RC=$?;
|
|
510
|
+
printf '%s\n' "$RETRY_OUTPUT";
|
|
511
|
+
if [ "$RETRY_RC" -eq 0 ]; then return 0; fi;
|
|
512
|
+
if ! printf '%s' "$RETRY_OUTPUT" | grep -Eq 'ENOENT|EBUSY|ENOTEMPTY|database is locked'; then return "$RETRY_RC"; fi;
|
|
513
|
+
sleep 2;
|
|
514
|
+
RETRY_SECOND_OUTPUT=$("$@" 2>&1); RETRY_RC=$?;
|
|
515
|
+
printf '%s\n' "$RETRY_SECOND_OUTPUT";
|
|
516
|
+
if [ "$RETRY_RC" -ne 0 ] && printf '%s\n%s' "$RETRY_OUTPUT" "$RETRY_SECOND_OUTPUT" | grep -Eq 'ENOENT|EBUSY|ENOTEMPTY'; then
|
|
517
|
+
echo "node_modules link/dependency broken — run bun install and retry";
|
|
518
|
+
fi;
|
|
519
|
+
return "$RETRY_RC";
|
|
520
|
+
};
|
|
521
|
+
retry_transient $spurBin task update "$wbs" done --no-lifecycle
|
|
431
522
|
- kind: note
|
|
432
523
|
options:
|
|
433
524
|
message: "Pipeline complete for task ${vars.wbs} (done gate cleared)."
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gobing-ai/spur",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.42",
|
|
4
4
|
"description": "Spur CLI — local-first harness for mainstream coding agents: constraint checking, workflow orchestration, agent health, and history analytics. Bun-native; exposes the `spur` command.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"spur",
|
|
@@ -31,7 +31,9 @@
|
|
|
31
31
|
"config",
|
|
32
32
|
"schemas",
|
|
33
33
|
"web",
|
|
34
|
-
"README.md"
|
|
34
|
+
"README.md",
|
|
35
|
+
"plugins/",
|
|
36
|
+
".claude-plugin/"
|
|
35
37
|
],
|
|
36
38
|
"engines": {
|
|
37
39
|
"bun": ">=1.3.0"
|
|
@@ -43,21 +45,22 @@
|
|
|
43
45
|
"dev": "bun run src/index.ts",
|
|
44
46
|
"build": "bun run ../../scripts/spur-dev.ts build-cli",
|
|
45
47
|
"build:binaries": "bun run ../../scripts/spur-dev.ts build-binaries",
|
|
46
|
-
"build:bundle": "bun run ../../scripts/spur-dev.ts bundle-web && bun build src/index.ts --target=bun --outfile spur.js && bun run ../../scripts/spur-dev.ts bundle-config config",
|
|
48
|
+
"build:bundle": "bun run ../../scripts/spur-dev.ts bundle-web && bun build src/index.ts --target=bun --outfile spur.js && bun run ../../scripts/spur-dev.ts bundle-config config && bun run ../../scripts/spur-dev.ts bundle-plugins",
|
|
47
49
|
"test": "bun test tests --coverage --coverage-dir=../../.coverage --pass-with-no-tests",
|
|
48
50
|
"typecheck": "tsc --noEmit",
|
|
49
|
-
"
|
|
51
|
+
"prepack": "bun run build:bundle",
|
|
52
|
+
"prepublishOnly": "bun run ../../scripts/spur-dev.ts check-marketplace-version"
|
|
50
53
|
},
|
|
51
54
|
"devDependencies": {
|
|
52
55
|
"@commander-js/extra-typings": "^14.0.0",
|
|
53
|
-
"@gobing-ai/ts-db": "^0.4.
|
|
54
|
-
"@gobing-ai/ts-ai-runner": "^0.4.
|
|
55
|
-
"@gobing-ai/ts-dual-workflow-engine": "^0.4.
|
|
56
|
-
"@gobing-ai/ts-infra": "^0.4.
|
|
57
|
-
"@gobing-ai/ts-llm-jsonl-importer": "^0.4.
|
|
58
|
-
"@gobing-ai/ts-rule-engine": "^0.4.
|
|
59
|
-
"@gobing-ai/ts-runtime": "^0.4.
|
|
60
|
-
"@gobing-ai/ts-utils": "^0.4.
|
|
56
|
+
"@gobing-ai/ts-db": "^0.4.24",
|
|
57
|
+
"@gobing-ai/ts-ai-runner": "^0.4.24",
|
|
58
|
+
"@gobing-ai/ts-dual-workflow-engine": "^0.4.24",
|
|
59
|
+
"@gobing-ai/ts-infra": "^0.4.24",
|
|
60
|
+
"@gobing-ai/ts-llm-jsonl-importer": "^0.4.24",
|
|
61
|
+
"@gobing-ai/ts-rule-engine": "^0.4.24",
|
|
62
|
+
"@gobing-ai/ts-runtime": "^0.4.24",
|
|
63
|
+
"@gobing-ai/ts-utils": "^0.4.24",
|
|
61
64
|
"@types/bun": "1.3.14",
|
|
62
65
|
"@types/figlet": "^1.7.0",
|
|
63
66
|
"@types/node-notifier": "8.0.5",
|