create-quiver 0.14.0 → 0.14.1
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/CHANGELOG.md +11 -0
- package/README.md +183 -518
- package/README_FOR_AI.md +32 -26
- package/ROADMAP.md +5 -0
- package/assets/quiver-wordmark.svg +22 -0
- package/docs/AI_CONTEXT.md.template +2 -0
- package/docs/AI_ONBOARDING_PROMPT.md.template +9 -1
- package/docs/CLI_UX_GUIDE.md +125 -0
- package/docs/COMMANDS.md.template +16 -3
- package/docs/GITFLOW_PR_GUIDE.md +70 -0
- package/docs/getting-started/linux.md +84 -0
- package/docs/getting-started/macos.md +85 -0
- package/docs/getting-started/windows-git-bash-wsl.md +78 -0
- package/docs/getting-started/windows-powershell.md +96 -0
- package/docs/reference/commands.md +94 -0
- package/docs/workflows/existing-project.md +131 -0
- package/docs/workflows/full-ai-spec-to-pr.md +311 -0
- package/docs/workflows/legacy-quiver-project.md +102 -0
- package/docs/workflows/new-project.md +76 -0
- package/package.json +5 -1
- package/specs/quiver-v29-planner-prepare-context-cli-ux/EVIDENCE_REPORT.md +163 -0
- package/specs/quiver-v29-planner-prepare-context-cli-ux/EXECUTION_PLAN.md +72 -0
- package/specs/quiver-v29-planner-prepare-context-cli-ux/SPEC.md +173 -0
- package/specs/quiver-v29-planner-prepare-context-cli-ux/STATUS.md +34 -0
- package/specs/quiver-v29-planner-prepare-context-cli-ux/pr.md +95 -0
- package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-00-cli-ux-spec-foundation/CLOSURE_BRIEF.md +32 -0
- package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-00-cli-ux-spec-foundation/EXECUTION_BRIEF.md +45 -0
- package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-00-cli-ux-spec-foundation/slice.json +58 -0
- package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-01-cli-ux-primitives-theme/CLOSURE_BRIEF.md +33 -0
- package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-01-cli-ux-primitives-theme/EXECUTION_BRIEF.md +49 -0
- package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-01-cli-ux-primitives-theme/slice.json +75 -0
- package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-02-planner-context-proposal-contract/CLOSURE_BRIEF.md +32 -0
- package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-02-planner-context-proposal-contract/EXECUTION_BRIEF.md +47 -0
- package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-02-planner-context-proposal-contract/slice.json +71 -0
- package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-03-prepare-context-planner-review-flow/CLOSURE_BRIEF.md +33 -0
- package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-03-prepare-context-planner-review-flow/EXECUTION_BRIEF.md +52 -0
- package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-03-prepare-context-planner-review-flow/slice.json +82 -0
- package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-04-ux-flag-matrix-compatibility/CLOSURE_BRIEF.md +34 -0
- package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-04-ux-flag-matrix-compatibility/EXECUTION_BRIEF.md +46 -0
- package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-04-ux-flag-matrix-compatibility/slice.json +73 -0
- package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-05-progressive-command-adoption/CLOSURE_BRIEF.md +34 -0
- package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-05-progressive-command-adoption/EXECUTION_BRIEF.md +46 -0
- package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-05-progressive-command-adoption/slice.json +83 -0
- package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-06-docs-tests-smoke-readiness/CLOSURE_BRIEF.md +31 -0
- package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-06-docs-tests-smoke-readiness/EXECUTION_BRIEF.md +50 -0
- package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-06-docs-tests-smoke-readiness/slice.json +95 -0
- package/src/create-quiver/commands/ai.js +458 -3
- package/src/create-quiver/commands/spec.js +64 -2
- package/src/create-quiver/index.js +49 -1
- package/src/create-quiver/lib/ai/context-proposal.js +389 -0
- package/src/create-quiver/lib/ai/context-proposal.schema.js +31 -0
- package/src/create-quiver/lib/cli/editor.js +118 -0
- package/src/create-quiver/lib/cli/theme.js +100 -0
- package/src/create-quiver/lib/cli/ux-flags.js +151 -0
- package/src/create-quiver/lib/cli/ux.js +130 -0
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
# Flujo para proyecto con Quiver anterior
|
|
2
|
+
|
|
3
|
+
Usá este flujo cuando el proyecto ya tiene archivos de Quiver creados por una versión anterior.
|
|
4
|
+
|
|
5
|
+
## 1. Entrar al proyecto
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
cd /ruta/al/proyecto
|
|
9
|
+
git status -sb
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
Qué hace:
|
|
13
|
+
|
|
14
|
+
- revisa la rama actual y los cambios pendientes.
|
|
15
|
+
|
|
16
|
+
## 2. Ejecutar doctor
|
|
17
|
+
|
|
18
|
+
```bash
|
|
19
|
+
npx --yes create-quiver@latest doctor
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
Qué hace:
|
|
23
|
+
|
|
24
|
+
- detecta si el proyecto está inicializado, incompleto, legacy, híbrido o sano.
|
|
25
|
+
|
|
26
|
+
## 3. Previsualizar migración
|
|
27
|
+
|
|
28
|
+
```bash
|
|
29
|
+
npx --yes create-quiver@latest migrate --dry-run
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
Qué hace:
|
|
33
|
+
|
|
34
|
+
- muestra qué actualizaría Quiver;
|
|
35
|
+
- evita escribir archivos.
|
|
36
|
+
|
|
37
|
+
## 4. Aplicar migración
|
|
38
|
+
|
|
39
|
+
```bash
|
|
40
|
+
npx --yes create-quiver@latest migrate
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
Qué hace:
|
|
44
|
+
|
|
45
|
+
- actualiza documentación y estado interno de Quiver;
|
|
46
|
+
- preserva archivos existentes del proyecto;
|
|
47
|
+
- mantiene la migración lo más aditiva posible.
|
|
48
|
+
|
|
49
|
+
Usá esta variante si no querés instalar dependencias:
|
|
50
|
+
|
|
51
|
+
```bash
|
|
52
|
+
npx --yes create-quiver@latest migrate --skip-install
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
## 5. Reconstruir contexto del proyecto
|
|
56
|
+
|
|
57
|
+
```bash
|
|
58
|
+
npx --yes create-quiver@latest analyze
|
|
59
|
+
npx --yes create-quiver@latest doctor
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
Qué hace:
|
|
63
|
+
|
|
64
|
+
- refresca `docs/PROJECT_MAP.md`;
|
|
65
|
+
- confirma que la estructura migrada esté sana.
|
|
66
|
+
|
|
67
|
+
## 6. Preparar contexto para IA
|
|
68
|
+
|
|
69
|
+
```bash
|
|
70
|
+
npx --yes create-quiver@latest ai prepare-context --dry-run
|
|
71
|
+
npx --yes create-quiver@latest ai prepare-context
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
Modo asistido por planner, útil cuando el contexto anterior quedó desactualizado:
|
|
75
|
+
|
|
76
|
+
```bash
|
|
77
|
+
npx --yes create-quiver@latest ai prepare-context --with-planner --dry-run
|
|
78
|
+
npx --yes create-quiver@latest ai prepare-context --with-planner --review --interactive
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
Qué hace:
|
|
82
|
+
|
|
83
|
+
- actualiza contexto de onboarding de forma segura;
|
|
84
|
+
- reporta supuestos y contradicciones.
|
|
85
|
+
|
|
86
|
+
## 7. Commit de migración
|
|
87
|
+
|
|
88
|
+
```bash
|
|
89
|
+
git status -sb
|
|
90
|
+
git add AGENTS.md docs .quiver .gitignore package.json package-lock.json
|
|
91
|
+
git commit -m "docs: migrate quiver workflow"
|
|
92
|
+
```
|
|
93
|
+
|
|
94
|
+
Qué hace:
|
|
95
|
+
|
|
96
|
+
- crea una base estable antes de empezar specs nuevas.
|
|
97
|
+
|
|
98
|
+
Ajustá los paths según lo que haya informado la migración.
|
|
99
|
+
|
|
100
|
+
Siguiente paso:
|
|
101
|
+
|
|
102
|
+
- [Ejecutar el flujo completo de spec a PR con IA](./full-ai-spec-to-pr.md)
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
# Flujo para proyecto nuevo
|
|
2
|
+
|
|
3
|
+
Usá este flujo cuando el repositorio todavía no existe o la carpeta está vacía.
|
|
4
|
+
|
|
5
|
+
## 1. Crear la carpeta del proyecto
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
mkdir mi-proyecto
|
|
9
|
+
cd mi-proyecto
|
|
10
|
+
git init
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
Qué hace:
|
|
14
|
+
|
|
15
|
+
- crea una carpeta para el proyecto;
|
|
16
|
+
- inicializa Git para que Quiver pueda razonar sobre cambios y worktrees.
|
|
17
|
+
|
|
18
|
+
## 2. Inicializar Quiver
|
|
19
|
+
|
|
20
|
+
```bash
|
|
21
|
+
npx --yes create-quiver@latest init --name "Mi Proyecto"
|
|
22
|
+
```
|
|
23
|
+
|
|
24
|
+
Qué hace:
|
|
25
|
+
|
|
26
|
+
- crea el contrato visible de Quiver;
|
|
27
|
+
- crea el estado interno en `.quiver/`;
|
|
28
|
+
- agrega scripts `quiver:*` cuando existe o se crea `package.json`.
|
|
29
|
+
|
|
30
|
+
## 3. Revisar el próximo paso
|
|
31
|
+
|
|
32
|
+
```bash
|
|
33
|
+
npx --yes create-quiver@latest flow
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
Qué hace:
|
|
37
|
+
|
|
38
|
+
- muestra el estado actual del workflow;
|
|
39
|
+
- recomienda el próximo comando seguro.
|
|
40
|
+
|
|
41
|
+
## 4. Analizar y validar
|
|
42
|
+
|
|
43
|
+
```bash
|
|
44
|
+
npx --yes create-quiver@latest analyze
|
|
45
|
+
npx --yes create-quiver@latest doctor
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
Qué hace:
|
|
49
|
+
|
|
50
|
+
- crea o actualiza `docs/PROJECT_MAP.md`;
|
|
51
|
+
- refresca el contexto para IA;
|
|
52
|
+
- valida que el contrato de Quiver esté sano.
|
|
53
|
+
|
|
54
|
+
## 5. Preparar contexto para IA
|
|
55
|
+
|
|
56
|
+
```bash
|
|
57
|
+
npx --yes create-quiver@latest ai prepare-context --dry-run
|
|
58
|
+
npx --yes create-quiver@latest ai prepare-context
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
Modo asistido por planner, si querés que una IA proponga el contexto:
|
|
62
|
+
|
|
63
|
+
```bash
|
|
64
|
+
npx --yes create-quiver@latest ai prepare-context --with-planner --dry-run
|
|
65
|
+
npx --yes create-quiver@latest ai prepare-context --with-planner --review --interactive
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
Qué hace:
|
|
69
|
+
|
|
70
|
+
- previsualiza cambios documentales de onboarding;
|
|
71
|
+
- escribe la documentación de contexto después de revisar;
|
|
72
|
+
- evita cambios en código de producto.
|
|
73
|
+
|
|
74
|
+
Siguiente paso:
|
|
75
|
+
|
|
76
|
+
- [Ejecutar el flujo completo de spec a PR con IA](./full-ai-spec-to-pr.md)
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "create-quiver",
|
|
3
|
-
"version": "0.14.
|
|
3
|
+
"version": "0.14.1",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "Quiver CLI for scaffolding projects from the packaged template",
|
|
6
6
|
"license": "MIT",
|
|
@@ -49,5 +49,9 @@
|
|
|
49
49
|
"smoke:tiered-pack": "bash scripts/ci/smoke-tiered-pack.sh",
|
|
50
50
|
"smoke:guided-workflow": "bash scripts/ci/smoke-guided-workflow.sh",
|
|
51
51
|
"release:quiver": "bash scripts/release-quiver.sh"
|
|
52
|
+
},
|
|
53
|
+
"dependencies": {
|
|
54
|
+
"@clack/prompts": "^1.4.0",
|
|
55
|
+
"zod": "^4.4.3"
|
|
52
56
|
}
|
|
53
57
|
}
|
|
@@ -0,0 +1,163 @@
|
|
|
1
|
+
# Evidence Report - Quiver v29 Planner Prepare Context CLI UX
|
|
2
|
+
|
|
3
|
+
**Status:** Initial documentation package evidence
|
|
4
|
+
**Date:** 2026-05-26
|
|
5
|
+
|
|
6
|
+
## Scope
|
|
7
|
+
|
|
8
|
+
This evidence report currently covers creation of the approved spec/slice package only. Implementation evidence must be appended by each execution slice.
|
|
9
|
+
|
|
10
|
+
## Commands Run During Spec Creation
|
|
11
|
+
|
|
12
|
+
```bash
|
|
13
|
+
find specs/quiver-v29-planner-prepare-context-cli-ux -name 'slice.json' -print -exec node -e "JSON.parse(require('fs').readFileSync(process.argv[1], 'utf8')); console.log('ok ' + process.argv[1])" {} \;
|
|
14
|
+
git diff --check
|
|
15
|
+
for f in specs/quiver-v29-planner-prepare-context-cli-ux/slices/*/EXECUTION_BRIEF.md specs/quiver-v29-planner-prepare-context-cli-ux/slices/*/CLOSURE_BRIEF.md; do node bin/create-quiver.js check-handoff "$f" >/dev/null || exit 1; done; echo "handoff briefs ok"
|
|
16
|
+
node bin/create-quiver.js spec validate specs/quiver-v29-planner-prepare-context-cli-ux
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
## Results
|
|
20
|
+
|
|
21
|
+
- `slice-00-cli-ux-spec-foundation` completed as the documentation foundation slice.
|
|
22
|
+
- Every `slice.json` parsed successfully.
|
|
23
|
+
- `git diff --check` passed.
|
|
24
|
+
- Every `EXECUTION_BRIEF.md` and `CLOSURE_BRIEF.md` passed `check-handoff` after normalizing the required `Acceptance Criteria` heading.
|
|
25
|
+
- Initial `spec validate` reported this file as missing; this report was added to satisfy the spec validation contract.
|
|
26
|
+
- `node bin/create-quiver.js spec validate specs/quiver-v29-planner-prepare-context-cli-ux` passed after adding this report.
|
|
27
|
+
|
|
28
|
+
## Pending Evidence
|
|
29
|
+
|
|
30
|
+
Implementation slices must append:
|
|
31
|
+
|
|
32
|
+
- focused unit tests;
|
|
33
|
+
- command integration tests;
|
|
34
|
+
- CI/no-TTY/JSON validation;
|
|
35
|
+
- package smoke;
|
|
36
|
+
- tarball dry-run;
|
|
37
|
+
- final docs sync validation.
|
|
38
|
+
|
|
39
|
+
## slice-01-cli-ux-primitives-theme Evidence
|
|
40
|
+
|
|
41
|
+
**Date:** 2026-05-26
|
|
42
|
+
**Status:** Passed
|
|
43
|
+
|
|
44
|
+
### Commands
|
|
45
|
+
|
|
46
|
+
```bash
|
|
47
|
+
node --test tests/lib/cli-theme.test.js tests/lib/cli-ux.test.js tests/lib/cli-editor.test.js
|
|
48
|
+
npm run package:quiver
|
|
49
|
+
git diff --check
|
|
50
|
+
```
|
|
51
|
+
|
|
52
|
+
### Results
|
|
53
|
+
|
|
54
|
+
- `node --test tests/lib/cli-theme.test.js tests/lib/cli-ux.test.js tests/lib/cli-editor.test.js` passed with 18 tests.
|
|
55
|
+
- `npm run package:quiver` passed and produced package smoke output for `create-quiver-0.14.0.tgz`.
|
|
56
|
+
- `git diff --check` passed.
|
|
57
|
+
- Dependencies were added through npm so `package-lock.json` records the resolved package metadata.
|
|
58
|
+
|
|
59
|
+
## slice-02-planner-context-proposal-contract Evidence
|
|
60
|
+
|
|
61
|
+
**Date:** 2026-05-26
|
|
62
|
+
**Status:** Passed
|
|
63
|
+
|
|
64
|
+
### Commands
|
|
65
|
+
|
|
66
|
+
```bash
|
|
67
|
+
node --test tests/lib/ai-context-proposal.test.js
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
### Results
|
|
71
|
+
|
|
72
|
+
- `node --test tests/lib/ai-context-proposal.test.js` passed with 8 tests.
|
|
73
|
+
- Fixtures cover valid JSON, fenced JSON, malformed output, product-code path, absolute path, and path traversal.
|
|
74
|
+
- The slice did not invoke providers and did not modify `runPrepareContext` write behavior.
|
|
75
|
+
|
|
76
|
+
## slice-04-ux-flag-matrix-compatibility Evidence
|
|
77
|
+
|
|
78
|
+
**Date:** 2026-05-26
|
|
79
|
+
**Status:** Passed
|
|
80
|
+
|
|
81
|
+
### Commands
|
|
82
|
+
|
|
83
|
+
```bash
|
|
84
|
+
node --test tests/commands/ux-flags.test.js tests/commands/cli-contract.test.js tests/lib/cli-ux.test.js
|
|
85
|
+
```
|
|
86
|
+
|
|
87
|
+
### Results
|
|
88
|
+
|
|
89
|
+
- `node --test tests/commands/ux-flags.test.js tests/commands/cli-contract.test.js tests/lib/cli-ux.test.js` passed with 22 tests.
|
|
90
|
+
- Tests cover matrix support, unsupported flags, incompatible `--json` combinations, read-only commands, `ai pr --with-planner`, and parseable JSON output for existing commands.
|
|
91
|
+
|
|
92
|
+
## slice-03-prepare-context-planner-review-flow Evidence
|
|
93
|
+
|
|
94
|
+
**Date:** 2026-05-26
|
|
95
|
+
**Status:** Passed
|
|
96
|
+
|
|
97
|
+
### Commands
|
|
98
|
+
|
|
99
|
+
```bash
|
|
100
|
+
node --test tests/commands/ai-onboard.test.js tests/commands/ai-prepare-context-planner.test.js tests/lib/ai-context-proposal.test.js
|
|
101
|
+
node --test tests/commands/ux-flags.test.js tests/commands/cli-contract.test.js tests/lib/cli-ux.test.js
|
|
102
|
+
git diff --check
|
|
103
|
+
```
|
|
104
|
+
|
|
105
|
+
### Results
|
|
106
|
+
|
|
107
|
+
- `node --test tests/commands/ai-onboard.test.js tests/commands/ai-prepare-context-planner.test.js tests/lib/ai-context-proposal.test.js` passed with 25 tests.
|
|
108
|
+
- `node --test tests/commands/ux-flags.test.js tests/commands/cli-contract.test.js tests/lib/cli-ux.test.js` passed with 22 tests.
|
|
109
|
+
- Tests cover deterministic compatibility, planner dry-run, prompt printing, provider success, provider failure, invalid planner output, review cancellation, review edit/revalidation, and interactive decline.
|
|
110
|
+
- `git diff --check` passed.
|
|
111
|
+
|
|
112
|
+
## slice-05-progressive-command-adoption Evidence
|
|
113
|
+
|
|
114
|
+
**Date:** 2026-05-26
|
|
115
|
+
**Status:** Passed
|
|
116
|
+
|
|
117
|
+
### Commands
|
|
118
|
+
|
|
119
|
+
```bash
|
|
120
|
+
node --test tests/commands/ai-plan.test.js tests/commands/spec-create.test.js tests/commands/ai-pr.test.js tests/commands/ux-flags.test.js
|
|
121
|
+
```
|
|
122
|
+
|
|
123
|
+
### Results
|
|
124
|
+
|
|
125
|
+
- `node --test tests/commands/ai-plan.test.js tests/commands/spec-create.test.js tests/commands/ai-pr.test.js tests/commands/ux-flags.test.js` passed with 46 tests.
|
|
126
|
+
- Tests cover `ai plan` UX flags, draft review, interactive decline, `spec create --review`, `spec create --interactive`, `ai pr --review`, `ai pr --interactive`, and the central unsupported flag matrix.
|
|
127
|
+
|
|
128
|
+
## slice-06-docs-tests-smoke-readiness Evidence
|
|
129
|
+
|
|
130
|
+
**Date:** 2026-05-26
|
|
131
|
+
**Status:** Passed
|
|
132
|
+
|
|
133
|
+
### Commands
|
|
134
|
+
|
|
135
|
+
```bash
|
|
136
|
+
node --test tests/commands/ai-prepare-context-planner.test.js tests/commands/ai-plan.test.js tests/commands/spec-create.test.js tests/commands/ai-pr.test.js tests/commands/ux-flags.test.js tests/commands/cli-contract.test.js tests/lib/cli-theme.test.js tests/lib/cli-ux.test.js tests/lib/cli-editor.test.js tests/lib/ai-context-proposal.test.js
|
|
137
|
+
node bin/create-quiver.js --help >/tmp/quiver-help.txt && rg -- '--with-planner|--interactive|--review|--no-color' /tmp/quiver-help.txt
|
|
138
|
+
node --test tests/**/*.test.js
|
|
139
|
+
npm run smoke:create-quiver
|
|
140
|
+
npm run smoke:doctor-fixtures
|
|
141
|
+
npm run smoke:guided-workflow
|
|
142
|
+
npm run package:quiver
|
|
143
|
+
npm pack --dry-run
|
|
144
|
+
git diff --check
|
|
145
|
+
node bin/create-quiver.js spec validate specs/quiver-v29-planner-prepare-context-cli-ux
|
|
146
|
+
```
|
|
147
|
+
|
|
148
|
+
### Results
|
|
149
|
+
|
|
150
|
+
- Focused command/UX validation passed with 87 tests and confirmed the public help includes `--with-planner`, `--interactive`, `--review`, and `--no-color`.
|
|
151
|
+
- Full test suite passed with 426 tests.
|
|
152
|
+
- `npm run smoke:create-quiver` passed.
|
|
153
|
+
- `npm run smoke:doctor-fixtures` passed with 13 fixture states.
|
|
154
|
+
- `npm run smoke:guided-workflow` passed.
|
|
155
|
+
- `npm run package:quiver` passed and validated package safety.
|
|
156
|
+
- `npm pack --dry-run` passed and produced a clean dry-run tarball report for `create-quiver@0.14.0`.
|
|
157
|
+
- `git diff --check` passed.
|
|
158
|
+
- `node bin/create-quiver.js spec validate specs/quiver-v29-planner-prepare-context-cli-ux` passed after closure metadata updates.
|
|
159
|
+
|
|
160
|
+
### Notes
|
|
161
|
+
|
|
162
|
+
- Npm printed a non-blocking update notice for npm `11.12.1 -> 11.15.0`.
|
|
163
|
+
- Publishing and PR creation remain outside this slice.
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
# Execution Plan - Quiver v29 Planner Prepare Context CLI UX
|
|
2
|
+
|
|
3
|
+
## Execution Order
|
|
4
|
+
|
|
5
|
+
```mermaid
|
|
6
|
+
flowchart TD
|
|
7
|
+
S00[slice-00: CLI UX spec foundation]
|
|
8
|
+
S01[slice-01: CLI UX primitives, theme, and dependencies]
|
|
9
|
+
S02[slice-02: Planner context proposal contract]
|
|
10
|
+
S03[slice-03: Planner-assisted prepare-context review flow]
|
|
11
|
+
S04[slice-04: UX flag matrix and compatibility guardrails]
|
|
12
|
+
S05[slice-05: Progressive command adoption]
|
|
13
|
+
S06[slice-06: Docs, tests, smoke, and release readiness]
|
|
14
|
+
|
|
15
|
+
S00 --> S01
|
|
16
|
+
S01 --> S02
|
|
17
|
+
S01 --> S04
|
|
18
|
+
S02 --> S03
|
|
19
|
+
S04 --> S03
|
|
20
|
+
S03 --> S05
|
|
21
|
+
S04 --> S05
|
|
22
|
+
S02 --> S06
|
|
23
|
+
S03 --> S06
|
|
24
|
+
S04 --> S06
|
|
25
|
+
S05 --> S06
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
## Waves
|
|
29
|
+
|
|
30
|
+
### Wave 0 - Sequential
|
|
31
|
+
|
|
32
|
+
1. `slice-00-cli-ux-spec-foundation`
|
|
33
|
+
|
|
34
|
+
This slice must run first. It establishes the approved UX standard, command/flag matrix, and documentation contract.
|
|
35
|
+
|
|
36
|
+
### Wave 1 - Sequential
|
|
37
|
+
|
|
38
|
+
1. `slice-01-cli-ux-primitives-theme`
|
|
39
|
+
|
|
40
|
+
This slice adds shared UX infrastructure and dependencies. Other implementation slices depend on this common layer.
|
|
41
|
+
|
|
42
|
+
### Wave 2 - Parallel after slice-01
|
|
43
|
+
|
|
44
|
+
- `slice-02-planner-context-proposal-contract`
|
|
45
|
+
- `slice-04-ux-flag-matrix-compatibility`
|
|
46
|
+
|
|
47
|
+
These can run in parallel if their write scopes stay separated: proposal validation under AI libs, flag/output guardrails under CLI parsing and UX helpers.
|
|
48
|
+
|
|
49
|
+
### Wave 3 - Sequential
|
|
50
|
+
|
|
51
|
+
1. `slice-03-prepare-context-planner-review-flow`
|
|
52
|
+
|
|
53
|
+
This slice depends on the proposal contract and UX compatibility rules.
|
|
54
|
+
|
|
55
|
+
### Wave 4 - Sequential
|
|
56
|
+
|
|
57
|
+
1. `slice-05-progressive-command-adoption`
|
|
58
|
+
|
|
59
|
+
This slice applies the standard to selected commands after `ai prepare-context` proves the pattern.
|
|
60
|
+
|
|
61
|
+
### Wave 5 - Sequential close
|
|
62
|
+
|
|
63
|
+
1. `slice-06-docs-tests-smoke-readiness`
|
|
64
|
+
|
|
65
|
+
This slice closes docs, generated templates, validation coverage, package smoke, and release readiness.
|
|
66
|
+
|
|
67
|
+
## Parallel Safety Notes
|
|
68
|
+
|
|
69
|
+
- Do not run `slice-03` before `slice-02` and `slice-04` are complete.
|
|
70
|
+
- Do not run `slice-05` before `slice-03`; progressive adoption should reuse the proven prepare-context pattern.
|
|
71
|
+
- `slice-06` is never parallel-safe because it validates all previous slices and updates final documentation.
|
|
72
|
+
- If `slice-02` or `slice-04` both need to modify central CLI parsing, run `slice-04` first, then rebase `slice-02`.
|
|
@@ -0,0 +1,173 @@
|
|
|
1
|
+
# Quiver v29 - Planner-Assisted Prepare Context and CLI UX Standard
|
|
2
|
+
|
|
3
|
+
**Date:** 2026-05-26
|
|
4
|
+
**Status:** Planned
|
|
5
|
+
**Source:** User-approved requirement to improve `ai prepare-context` with optional planner IA and standardize CLI UX across Quiver.
|
|
6
|
+
|
|
7
|
+
Slice numbering resets here. This spec intentionally starts at `slice-00`.
|
|
8
|
+
|
|
9
|
+
## Problem
|
|
10
|
+
|
|
11
|
+
`npx create-quiver ai prepare-context` is currently safe and deterministic: it prepares docs-only context using templates and project signals. That behavior must remain, but Quiver also needs an explicit planner-assisted mode where a configured planner IA can analyze project context and propose richer onboarding documentation.
|
|
12
|
+
|
|
13
|
+
At the same time, Quiver's CLI UX has grown command by command. It needs a shared standard for loaders, prompts, visual hierarchy, review flows, flags, color usage, non-interactive execution, CI, `--json`, agents, and errors. Without a standard, each new AI command risks solving UX differently.
|
|
14
|
+
|
|
15
|
+
## Objective
|
|
16
|
+
|
|
17
|
+
Create a CLI UX standard for Quiver and implement the first high-value application of it:
|
|
18
|
+
|
|
19
|
+
- keep `ai prepare-context` deterministic by default;
|
|
20
|
+
- add explicit planner-assisted preparation;
|
|
21
|
+
- add safe interactive/review flows;
|
|
22
|
+
- validate planner output before writes;
|
|
23
|
+
- standardize output modes, colors, prompts, loaders, and flags;
|
|
24
|
+
- apply the standard progressively to selected commands.
|
|
25
|
+
|
|
26
|
+
## Scope
|
|
27
|
+
|
|
28
|
+
### Included
|
|
29
|
+
|
|
30
|
+
- UX standard documentation for Quiver CLI commands.
|
|
31
|
+
- Shared CLI UX/theme/editor helpers.
|
|
32
|
+
- Quiver color tokens for human-mode output.
|
|
33
|
+
- Optional `--with-planner` mode for `ai prepare-context`.
|
|
34
|
+
- Optional `--interactive` and `--review` flows where they add value.
|
|
35
|
+
- `--print-prompt`, `--dry-run`, `--json`, CI, no-TTY, no-color compatibility.
|
|
36
|
+
- Planner proposal contract validated with a structured schema.
|
|
37
|
+
- Docs-only allowlist for context writes.
|
|
38
|
+
- `$EDITOR` review before applying AI-generated documentation.
|
|
39
|
+
- Progressive adoption plan for `ai plan`, `spec create`, and `ai pr`.
|
|
40
|
+
- Tests, fixtures, documentation, and package smoke readiness.
|
|
41
|
+
|
|
42
|
+
### Excluded
|
|
43
|
+
|
|
44
|
+
- Replacing the whole CLI parser with `commander`, `yargs`, or `oclif`.
|
|
45
|
+
- Adding terminal dashboards with `ink`, `blessed`, or `neo-blessed`.
|
|
46
|
+
- Adding image output protocols.
|
|
47
|
+
- Migrating tests from `node:test` to `vitest`.
|
|
48
|
+
- Storing provider credentials.
|
|
49
|
+
- Allowing planner IA to modify product code.
|
|
50
|
+
- Making interactive prompts mandatory.
|
|
51
|
+
|
|
52
|
+
## Approved Acceptance Criteria
|
|
53
|
+
|
|
54
|
+
### Prepare-context modes
|
|
55
|
+
|
|
56
|
+
1. Given a project with Quiver initialized, when `npx create-quiver ai prepare-context --dry-run` runs, then Quiver keeps the current deterministic behavior, invokes no provider, writes no files, and shows the proposed docs plan.
|
|
57
|
+
2. Given a user runs `npx create-quiver ai prepare-context` without new flags, when the command finishes, then it writes only allowed context docs and does not modify product code.
|
|
58
|
+
3. Given a planner profile or explicit provider is available, when `npx create-quiver ai prepare-context --with-planner --dry-run` runs, then Quiver shows provider invocation, context inputs, candidate docs, and no writes.
|
|
59
|
+
4. Given the user has reviewed dry-run output, when `npx create-quiver ai prepare-context --with-planner` runs, then Quiver invokes the planner, validates the output, and applies only allowed docs-only changes.
|
|
60
|
+
5. Given the user wants to use another AI environment, when `--with-planner --print-prompt` is used, then Quiver prints the exact prompt and exits without provider auth or writes.
|
|
61
|
+
6. Given planner output suggests docs updates, when Quiver evaluates it, then only allowed context docs can be written.
|
|
62
|
+
7. Given planner output attempts product-code, dependency, build, test, lockfile, runtime, absolute, traversal, or outside-repo writes, when Quiver validates it, then the command blocks those writes and reports why.
|
|
63
|
+
8. Given the command writes docs, when it completes, then it snapshots touched docs under `.quiver/runs/<run-id>/snapshots/` and reports files, assumptions, risks, and generation source.
|
|
64
|
+
9. Given provider CLI fails, is missing, or is unauthenticated, when planner mode runs, then Quiver shows an actionable error and writes no partial changes.
|
|
65
|
+
10. Given planner output is incomplete, ambiguous, or invalid, when Quiver processes it, then Quiver does not write files automatically and reports the next safe step.
|
|
66
|
+
|
|
67
|
+
### CLI UX standard
|
|
68
|
+
|
|
69
|
+
11. Given the new behavior, when docs are reviewed, then README, command reference, templates, and `README_FOR_AI.md` explain deterministic mode, planner-assisted mode, and safe usage.
|
|
70
|
+
12. Given the new command surface, when tests run, then there is coverage for deterministic mode, planner dry-run, prompt printing, provider failure, invalid output, path blocking, docs-only writes, TTY/no-TTY, CI, and `--json`.
|
|
71
|
+
13. Given any command uses UX output, when it runs, then it clearly indicates whether it is deterministic, planner-assisted, interactive, review, dry-run, or machine mode.
|
|
72
|
+
14. Given multiple docs or checks are proposed, when human output is shown, then Quiver groups files, actions, risks, and next steps with clear visual hierarchy.
|
|
73
|
+
15. Given `--json`, CI, or stdout/stderr redirection, when output is produced, then no spinners, prompts, colors, or decorative symbols appear in machine-readable output.
|
|
74
|
+
16. Given a command supports `--review`, when a proposal exists, then Quiver opens `$VISUAL` or `$EDITOR`; if neither is available, it leaves an artifact path and gives a manual next step.
|
|
75
|
+
17. Given a command supports prompts, when `--interactive` is not used, then it must not block for interactive choices except already documented confirmations.
|
|
76
|
+
18. Given a prompt is added, when automation is needed, then equivalent non-interactive flags must exist.
|
|
77
|
+
19. Given a command uses loaders, when it runs in human TTY mode, then loaders appear only for slow stages and never hide errors.
|
|
78
|
+
20. Given an output uses colors, when colors are disabled or unsupported, then the output remains readable.
|
|
79
|
+
|
|
80
|
+
### Standard flags and visual identity
|
|
81
|
+
|
|
82
|
+
21. Given the UX standard, when docs are reviewed, then `--with-planner`, `--interactive`, and `--review` are defined with purpose, rules, and applicable commands.
|
|
83
|
+
22. Given a command is evaluated for those flags, when there is no generation, human decision, review, or planner value, then the command must not expose decorative flags.
|
|
84
|
+
23. Given `--with-planner --review` runs on a command that writes persistent AI-generated docs, then Quiver generates, validates, opens for human review, revalidates, and applies only allowed changes after approval.
|
|
85
|
+
24. Given unsupported UX flags are used on a command, then Quiver fails early with a clear explanation and an alternative command.
|
|
86
|
+
25. Given the Quiver CLI uses loaders, states, badges, or highlighted sections, when colors are enabled, then it uses the Quiver palette consistently:
|
|
87
|
+
- `quiver.sky` `#86C8F2`
|
|
88
|
+
- `quiver.blue` `#6BADEB`
|
|
89
|
+
- `quiver.periwinkle` `#7F9EE8`
|
|
90
|
+
- `quiver.violet` `#9B82E6`
|
|
91
|
+
- `quiver.magenta` `#D56AB0`
|
|
92
|
+
26. Given semantic status output is needed, then success/error/warning semantics remain clear and are not replaced blindly by brand colors.
|
|
93
|
+
27. Given a migrated command shows output, then colors and symbols come from centralized helpers, not command-local hardcoding.
|
|
94
|
+
|
|
95
|
+
## Approved Technical Plan
|
|
96
|
+
|
|
97
|
+
1. Keep the current no-IA `ai prepare-context` behavior as the default.
|
|
98
|
+
2. Add shared CLI UX helpers behind a small internal abstraction before command adoption.
|
|
99
|
+
3. Add Quiver theme tokens and no-color/CI/no-TTY detection.
|
|
100
|
+
4. Add `$EDITOR` review support with safe fallback.
|
|
101
|
+
5. Add a planner context proposal contract and schema validation.
|
|
102
|
+
6. Add planner-assisted `ai prepare-context` flow with `--with-planner`, `--print-prompt`, `--dry-run`, `--review`, and `--interactive`.
|
|
103
|
+
7. Add strict docs-only allowlist and path safety for planner-generated writes.
|
|
104
|
+
8. Improve human output with loaders and hierarchy only where safe.
|
|
105
|
+
9. Preserve clean JSON output and automation behavior.
|
|
106
|
+
10. Apply the UX flag standard first to `ai prepare-context`, then selected parts of `ai plan`, `spec create`, and `ai pr`.
|
|
107
|
+
11. Document the standard and update generated templates.
|
|
108
|
+
12. Add tests and package/tarball smoke coverage.
|
|
109
|
+
|
|
110
|
+
## Command/Flag Matrix
|
|
111
|
+
|
|
112
|
+
| Command | `--with-planner` | `--interactive` | `--review` | Scope in this spec |
|
|
113
|
+
|---|---:|---:|---:|---|
|
|
114
|
+
| `ai prepare-context` | yes | yes | yes | Full implementation |
|
|
115
|
+
| `ai plan` | yes | yes | yes | Progressive adoption and contract alignment |
|
|
116
|
+
| `spec create` | yes | yes | yes | Progressive adoption and guardrails |
|
|
117
|
+
| `ai pr` | no | yes | yes | Review/edit PR body and interactive inputs |
|
|
118
|
+
| `ai onboard` | implicit planner | future | future | Documented follow-up |
|
|
119
|
+
| `ai revise` | future | future | future | Documented follow-up |
|
|
120
|
+
| `ai review-plan` | no planner flag | future | future | Documented follow-up |
|
|
121
|
+
| `doctor` | no | future for fixes | no | Documented follow-up |
|
|
122
|
+
| `flow`, `next`, `graph`, `ai inspect`, `ai export`, list commands | no | no | no | Must remain read-only/scriptable |
|
|
123
|
+
|
|
124
|
+
## Tools and Dependency Decisions
|
|
125
|
+
|
|
126
|
+
- Adopt `zod` for validating planner proposal contracts.
|
|
127
|
+
- Adopt `@clack/prompts` behind internal helpers for interactive prompts and human-mode spinners.
|
|
128
|
+
- Use Node native process spawning for `$EDITOR`.
|
|
129
|
+
- Do not adopt `commander`, `yargs`, or `oclif` in this spec.
|
|
130
|
+
- Do not adopt `ink`, `blessed`, `neo-blessed`, terminal image protocols, or `vitest` in this spec.
|
|
131
|
+
|
|
132
|
+
## Slice Roadmap
|
|
133
|
+
|
|
134
|
+
| Slice | Title | Status | Dependencies |
|
|
135
|
+
|---|---|---|---|
|
|
136
|
+
| slice-00 | CLI UX spec foundation | completed | none |
|
|
137
|
+
| slice-01 | CLI UX primitives, theme, and dependencies | completed | slice-00 |
|
|
138
|
+
| slice-02 | Planner context proposal contract | completed | slice-01 |
|
|
139
|
+
| slice-03 | Planner-assisted prepare-context review flow | completed | slice-01, slice-02 |
|
|
140
|
+
| slice-04 | UX flag matrix and compatibility guardrails | completed | slice-01 |
|
|
141
|
+
| slice-05 | Progressive command adoption | completed | slice-03, slice-04 |
|
|
142
|
+
| slice-06 | Docs, tests, smoke, and release readiness | completed | slice-02, slice-03, slice-04, slice-05 |
|
|
143
|
+
|
|
144
|
+
## Validation Strategy
|
|
145
|
+
|
|
146
|
+
- `node --test tests/**/*.test.js`
|
|
147
|
+
- focused command tests for `ai prepare-context`
|
|
148
|
+
- focused tests for UX mode detection and theme fallback
|
|
149
|
+
- focused tests for planner proposal schema/path validation
|
|
150
|
+
- focused tests for editor review cancellation and invalid edit fallback
|
|
151
|
+
- `npm run smoke:create-quiver`
|
|
152
|
+
- `npm run smoke:doctor-fixtures`
|
|
153
|
+
- `npm run smoke:guided-workflow`
|
|
154
|
+
- `npm run package:quiver`
|
|
155
|
+
- `npm pack --dry-run`
|
|
156
|
+
- `git diff --check`
|
|
157
|
+
- `npx create-quiver check-handoff` for all slice briefs
|
|
158
|
+
- JSON parse validation for all `slice.json` files
|
|
159
|
+
|
|
160
|
+
## Risks
|
|
161
|
+
|
|
162
|
+
- New dependencies may affect startup time, CJS/ESM compatibility, and package size.
|
|
163
|
+
- Visual output can break automation unless strictly disabled for `--json`, CI, no-TTY, and pipes.
|
|
164
|
+
- Planner output can be useful but invalid; the validation path must be strict.
|
|
165
|
+
- `$EDITOR` behavior differs across macOS, Linux, Windows PowerShell, Git Bash, and WSL.
|
|
166
|
+
- `--review` can become ambiguous unless consistently defined as "review before persistent writes".
|
|
167
|
+
- Progressive adoption can create inconsistent UX if the matrix is not documented and enforced.
|
|
168
|
+
|
|
169
|
+
## Resolved Decisions
|
|
170
|
+
|
|
171
|
+
- No-color behavior uses both `--no-color` and environment detection (`NO_COLOR`, CI, and no-TTY).
|
|
172
|
+
- `ai plan --with-planner` is accepted for UX consistency because planner behavior is already implicit.
|
|
173
|
+
- `spec create --with-planner` is accepted because the command consumes an already reviewed and approved planner output; it does not execute a provider again.
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
# Quiver v29 Status
|
|
2
|
+
|
|
3
|
+
**Spec:** `quiver-v29-planner-prepare-context-cli-ux`
|
|
4
|
+
**Status:** Completed
|
|
5
|
+
**Created:** 2026-05-26
|
|
6
|
+
|
|
7
|
+
## Current State
|
|
8
|
+
|
|
9
|
+
- Acceptance criteria approved.
|
|
10
|
+
- Technical plan approved.
|
|
11
|
+
- Spec package prepared for execution.
|
|
12
|
+
- `slice-00` completed as the documentary foundation.
|
|
13
|
+
- `slice-01` completed with shared CLI UX primitives, Quiver theme tokens, editor helper, and focused tests.
|
|
14
|
+
- `slice-02` completed with planner proposal schema, parser, docs-only allowlist, unsafe path rejection, and redacted invalid-output artifacts.
|
|
15
|
+
- `slice-04` completed with centralized UX flag support, unsupported/incompatible flag guardrails, and CLI contract tests.
|
|
16
|
+
- `slice-03` completed with explicit planner-assisted `ai prepare-context`, dry-run, prompt printing, provider execution, review, interactive approval, docs-only snapshots, and tests.
|
|
17
|
+
- `slice-05` completed with progressive UX adoption for `ai plan`, `spec create`, and `ai pr`.
|
|
18
|
+
- `slice-06` completed with documentation sync, CLI UX guide, generated template updates, full tests, smoke, package, tarball dry-run, and release readiness evidence.
|
|
19
|
+
|
|
20
|
+
## Slice Status
|
|
21
|
+
|
|
22
|
+
| Slice | Status | Notes |
|
|
23
|
+
|---|---|---|
|
|
24
|
+
| slice-00-cli-ux-spec-foundation | completed | Spec package validated and ready as foundation commit. |
|
|
25
|
+
| slice-01-cli-ux-primitives-theme | completed | Added shared CLI theme/UX/editor helpers and focused unit tests; package smoke passed. |
|
|
26
|
+
| slice-02-planner-context-proposal-contract | completed | Added zod proposal contract, parser, path safety, fixtures, and tests. |
|
|
27
|
+
| slice-03-prepare-context-planner-review-flow | completed | Implemented planner-assisted prepare-context while preserving deterministic default behavior. |
|
|
28
|
+
| slice-04-ux-flag-matrix-compatibility | completed | Added flag matrix, early validation, help entries, and tests for unsupported/incompatible UX flags. |
|
|
29
|
+
| slice-05-progressive-command-adoption | completed | Added review/interactive paths for selected planner/spec/PR commands and tests. |
|
|
30
|
+
| slice-06-docs-tests-smoke-readiness | completed | Final docs, templates, full tests, smoke, package, and tarball readiness passed. |
|
|
31
|
+
|
|
32
|
+
## Next Step
|
|
33
|
+
|
|
34
|
+
Open the PR for `quiver-v29-planner-prepare-context-cli-ux`, merge after review, and publish only after the package release process is explicitly requested.
|