specweave 1.0.256 → 1.0.259
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.md +56 -221
- package/README.md +31 -0
- package/bin/specweave.js +17 -0
- package/dist/src/adapters/README.md +4 -4
- package/dist/src/adapters/agents-md-generator.d.ts.map +1 -1
- package/dist/src/adapters/agents-md-generator.js +0 -2
- package/dist/src/adapters/agents-md-generator.js.map +1 -1
- package/dist/src/adapters/claude/README.md +3 -3
- package/dist/src/adapters/claude/adapter.js +3 -3
- package/dist/src/adapters/claude-md-generator.js +1 -1
- package/dist/src/adapters/claude-md-generator.js.map +1 -1
- package/dist/src/adapters/registry.yaml +1 -1
- package/dist/src/cli/commands/create-increment.d.ts +24 -0
- package/dist/src/cli/commands/create-increment.d.ts.map +1 -0
- package/dist/src/cli/commands/create-increment.js +53 -0
- package/dist/src/cli/commands/create-increment.js.map +1 -0
- package/dist/src/cli/commands/init.d.ts.map +1 -1
- package/dist/src/cli/commands/init.js +48 -31
- package/dist/src/cli/commands/init.js.map +1 -1
- package/dist/src/cli/commands/update.d.ts.map +1 -1
- package/dist/src/cli/commands/update.js +36 -0
- package/dist/src/cli/commands/update.js.map +1 -1
- package/dist/src/cli/helpers/init/directory-structure.d.ts.map +1 -1
- package/dist/src/cli/helpers/init/directory-structure.js +13 -1
- package/dist/src/cli/helpers/init/directory-structure.js.map +1 -1
- package/dist/src/cli/helpers/init/summary-banner.d.ts +11 -0
- package/dist/src/cli/helpers/init/summary-banner.d.ts.map +1 -1
- package/dist/src/cli/helpers/init/summary-banner.js +49 -3
- package/dist/src/cli/helpers/init/summary-banner.js.map +1 -1
- package/dist/src/cli/helpers/issue-tracker/index.d.ts.map +1 -1
- package/dist/src/cli/helpers/issue-tracker/index.js +0 -1
- package/dist/src/cli/helpers/issue-tracker/index.js.map +1 -1
- package/dist/src/cli/helpers/issue-tracker/sync-config-writer.d.ts.map +1 -1
- package/dist/src/cli/helpers/issue-tracker/sync-config-writer.js +6 -2
- package/dist/src/cli/helpers/issue-tracker/sync-config-writer.js.map +1 -1
- package/dist/src/core/ac-progress-sync.d.ts +13 -0
- package/dist/src/core/ac-progress-sync.d.ts.map +1 -1
- package/dist/src/core/ac-progress-sync.js +28 -0
- package/dist/src/core/ac-progress-sync.js.map +1 -1
- package/dist/src/core/config/types.d.ts +24 -1
- package/dist/src/core/config/types.d.ts.map +1 -1
- package/dist/src/core/config/types.js +6 -1
- package/dist/src/core/config/types.js.map +1 -1
- package/dist/src/core/doctor/checkers/project-structure-checker.d.ts +1 -0
- package/dist/src/core/doctor/checkers/project-structure-checker.d.ts.map +1 -1
- package/dist/src/core/doctor/checkers/project-structure-checker.js +53 -3
- package/dist/src/core/doctor/checkers/project-structure-checker.js.map +1 -1
- package/dist/src/core/fabric/security-scanner.d.ts.map +1 -1
- package/dist/src/core/fabric/security-scanner.js +70 -9
- package/dist/src/core/fabric/security-scanner.js.map +1 -1
- package/dist/src/core/increment/increment-utils.d.ts +6 -0
- package/dist/src/core/increment/increment-utils.d.ts.map +1 -1
- package/dist/src/core/increment/increment-utils.js +5 -0
- package/dist/src/core/increment/increment-utils.js.map +1 -1
- package/dist/src/core/living-docs/discovery.d.ts +2 -0
- package/dist/src/core/living-docs/discovery.d.ts.map +1 -1
- package/dist/src/core/living-docs/discovery.js +91 -17
- package/dist/src/core/living-docs/discovery.js.map +1 -1
- package/dist/src/core/living-docs/intelligent-analyzer/index.d.ts +5 -0
- package/dist/src/core/living-docs/intelligent-analyzer/index.d.ts.map +1 -1
- package/dist/src/core/living-docs/intelligent-analyzer/index.js +3 -3
- package/dist/src/core/living-docs/intelligent-analyzer/index.js.map +1 -1
- package/dist/src/core/living-docs/lsp-bootstrapper.d.ts +64 -0
- package/dist/src/core/living-docs/lsp-bootstrapper.d.ts.map +1 -0
- package/dist/src/core/living-docs/lsp-bootstrapper.js +118 -0
- package/dist/src/core/living-docs/lsp-bootstrapper.js.map +1 -0
- package/dist/src/core/project/project-service.d.ts +10 -1
- package/dist/src/core/project/project-service.d.ts.map +1 -1
- package/dist/src/core/project/project-service.js +37 -2
- package/dist/src/core/project/project-service.js.map +1 -1
- package/dist/src/core/universal-auto-create.d.ts +64 -0
- package/dist/src/core/universal-auto-create.d.ts.map +1 -0
- package/dist/src/core/universal-auto-create.js +228 -0
- package/dist/src/core/universal-auto-create.js.map +1 -0
- package/package.json +1 -1
- package/plugins/specweave/PLUGIN.md +0 -3
- package/plugins/specweave/commands/living-docs.md +0 -2
- package/plugins/specweave/hooks/stop-sync.sh +34 -5
- package/plugins/specweave/hooks/user-prompt-submit.sh +115 -326
- package/plugins/specweave/hooks/v2/dispatchers/post-tool-use.sh +19 -5
- package/plugins/specweave/hooks/v2/handlers/ac-sync-dispatcher.sh +14 -4
- package/plugins/specweave/hooks/v2/handlers/universal-auto-create-dispatcher.sh +181 -0
- package/plugins/specweave/lib/hooks/sync-living-docs.js +4 -2
- package/plugins/specweave/scripts/skill-context.sh +160 -0
- package/plugins/specweave/skills/architect/SKILL.md +1 -1
- package/plugins/specweave/skills/archive-increments/SKILL.md +13 -3
- package/plugins/specweave/skills/auto/SKILL.md +92 -1038
- package/plugins/specweave/skills/do/SKILL.md +66 -1106
- package/plugins/specweave/skills/docs/SKILL.md +124 -56
- package/plugins/specweave/skills/done/SKILL.md +76 -1406
- package/plugins/specweave/skills/framework/SKILL.md +1 -1
- package/plugins/specweave/skills/increment/SKILL.md +1 -1
- package/plugins/specweave/skills/increment-planner/SKILL.md +29 -19
- package/plugins/specweave/skills/jobs/SKILL.md +52 -0
- package/plugins/specweave/skills/multi-project-spec-mapper/SKILL.md +1 -1
- package/plugins/specweave/skills/save/SKILL.md +51 -1372
- package/plugins/specweave/skills/smart-reopen-detector/SKILL.md +1 -1
- package/plugins/specweave/skills/tdd-orchestrator/SKILL.md +1 -1
- package/plugins/specweave/skills/validate/SKILL.md +65 -848
- package/plugins/specweave-backend/skills/database-optimizer/SKILL.md +1 -1
- package/plugins/specweave-backend/skills/graphql/SKILL.md +1 -1
- package/plugins/specweave-frontend/skills/design-system-architect/SKILL.md +1 -1
- package/plugins/specweave-frontend/skills/frontend/SKILL.md +1 -1
- package/plugins/specweave-frontend/skills/frontend-architect/SKILL.md +1 -1
- package/plugins/specweave-frontend/skills/frontend-design/SKILL.md +1 -1
- package/plugins/specweave-frontend/skills/i18n-expert/SKILL.md +1 -1
- package/plugins/specweave-payments/skills/billing-automation/SKILL.md +1 -1
- package/plugins/specweave-testing/skills/accessibility-testing/SKILL.md +1 -1
- package/src/templates/CLAUDE.md.template +50 -356
- package/src/templates/config.json.template +5 -1
- package/plugins/specweave/commands/brownfield-analyzer.md +0 -408
- package/plugins/specweave/commands/brownfield-onboarder.md +0 -837
- package/plugins/specweave/commands/export-skills.md +0 -179
|
@@ -1,103 +1,171 @@
|
|
|
1
1
|
---
|
|
2
|
-
description:
|
|
3
|
-
argument-hint: "[topic] [--public] [--internal] [--adr] [--list]"
|
|
2
|
+
description: Documentation hub - browse, search, serve living docs. Use for "show docs", "browse docs", "find docs", "load docs", "read ADR", "serve docs", "preview docs", "docs status".
|
|
3
|
+
argument-hint: "[topic] [--serve] [--status] [--public] [--internal] [--adr] [--list]"
|
|
4
4
|
---
|
|
5
5
|
|
|
6
|
-
#
|
|
6
|
+
# Documentation Hub
|
|
7
7
|
|
|
8
8
|
## Project Overrides
|
|
9
9
|
|
|
10
10
|
!`s="docs"; for d in .specweave/skill-memories .claude/skill-memories "$HOME/.claude/skill-memories"; do p="$d/$s.md"; [ -f "$p" ] && awk '/^## Learnings$/{ok=1;next}/^## /{ok=0}ok' "$p" && break; done 2>/dev/null; true`
|
|
11
11
|
|
|
12
|
-
Browse, search, and
|
|
12
|
+
Browse, search, load, and serve SpecWeave living documentation.
|
|
13
13
|
|
|
14
|
-
##
|
|
14
|
+
## Config-Driven Directories
|
|
15
15
|
|
|
16
|
+
Read configured doc directories before any operation:
|
|
17
|
+
|
|
18
|
+
```bash
|
|
19
|
+
# Read configured doc directories (default: .specweave/docs)
|
|
20
|
+
DOC_DIRS=$(jq -r '(.documentation.directories // [".specweave/docs"])[]' .specweave/config.json 2>/dev/null)
|
|
21
|
+
[ -z "$DOC_DIRS" ] && DOC_DIRS=".specweave/docs"
|
|
16
22
|
```
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
internal/ # Developer docs (specs, architecture, ADRs, operations)
|
|
20
|
-
```
|
|
23
|
+
|
|
24
|
+
All search/list commands below MUST iterate over `$DOC_DIRS` instead of hardcoding `.specweave/docs`.
|
|
21
25
|
|
|
22
26
|
## Behavior
|
|
23
27
|
|
|
24
|
-
### 1. No arguments
|
|
28
|
+
### 1. No arguments: Show documentation dashboard
|
|
29
|
+
|
|
30
|
+
Run these diagnostic commands:
|
|
25
31
|
|
|
26
32
|
```bash
|
|
27
|
-
|
|
28
|
-
|
|
33
|
+
# Read configured doc directories
|
|
34
|
+
DOC_DIRS=$(jq -r '(.documentation.directories // [".specweave/docs"])[]' .specweave/config.json 2>/dev/null)
|
|
35
|
+
[ -z "$DOC_DIRS" ] && DOC_DIRS=".specweave/docs"
|
|
36
|
+
|
|
37
|
+
# Count documents across all directories
|
|
38
|
+
DOC_COUNT=0
|
|
39
|
+
for dir in $DOC_DIRS; do
|
|
40
|
+
if [ -d "$dir" ]; then
|
|
41
|
+
C=$(find "$dir" -name "*.md" -type f 2>/dev/null | wc -l | tr -d ' ')
|
|
42
|
+
DOC_COUNT=$((DOC_COUNT + C))
|
|
43
|
+
fi
|
|
44
|
+
done
|
|
45
|
+
echo "DOC_COUNT:$DOC_COUNT"
|
|
46
|
+
|
|
47
|
+
# Check Docusaurus install status
|
|
48
|
+
[ -d ".specweave/docs-site-internal/node_modules" ] && echo "DOCUSAURUS:installed" || echo "DOCUSAURUS:not_installed"
|
|
49
|
+
|
|
50
|
+
# Check if docs server is running
|
|
51
|
+
SERVER_INFO=$(lsof -i :3000-3010 -sTCP:LISTEN 2>/dev/null | grep -i node | head -1 | awk '{print $9}' | cut -d: -f2)
|
|
52
|
+
[ -n "$SERVER_INFO" ] && echo "SERVER:running:$SERVER_INFO" || echo "SERVER:stopped"
|
|
53
|
+
|
|
54
|
+
# List topics per directory
|
|
55
|
+
for dir in $DOC_DIRS; do
|
|
56
|
+
echo "=== $dir ==="
|
|
57
|
+
if [ -d "$dir/public" ]; then
|
|
58
|
+
echo " Public:"
|
|
59
|
+
ls "$dir/public/" 2>/dev/null || echo " (none)"
|
|
60
|
+
fi
|
|
61
|
+
if [ -d "$dir/internal" ]; then
|
|
62
|
+
echo " Internal:"
|
|
63
|
+
ls "$dir/internal/" 2>/dev/null || echo " (none)"
|
|
64
|
+
fi
|
|
65
|
+
if [ -d "$dir/internal/architecture/adr" ]; then
|
|
66
|
+
echo " ADRs:"
|
|
67
|
+
ls "$dir/internal/architecture/adr/" 2>/dev/null || echo " (none)"
|
|
68
|
+
fi
|
|
69
|
+
# For non-standard directories (e.g., docs/), list top-level folders
|
|
70
|
+
if [ "$dir" != ".specweave/docs" ] && [ -d "$dir" ]; then
|
|
71
|
+
echo " Folders:"
|
|
72
|
+
ls -d "$dir"/*/ 2>/dev/null | xargs -I{} basename {} || echo " (none)"
|
|
73
|
+
fi
|
|
74
|
+
done
|
|
75
|
+
```
|
|
29
76
|
|
|
30
|
-
|
|
31
|
-
echo "=== Internal Docs ==="
|
|
32
|
-
ls .specweave/docs/internal/ 2>/dev/null || echo "(none)"
|
|
77
|
+
Present as a clean dashboard.
|
|
33
78
|
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
79
|
+
**Then ALWAYS include serve guidance** (same as `--serve` behavior):
|
|
80
|
+
- If server is already running: "Docs server running at http://localhost:<port>"
|
|
81
|
+
- If server is NOT running: Show the `specweave docs preview` instructions (see section 4 below)
|
|
37
82
|
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
```
|
|
83
|
+
This ensures every `/sw:docs` invocation gives the user a clear path to browse docs in their browser.
|
|
84
|
+
|
|
85
|
+
### 2. `--list`: List topics only
|
|
42
86
|
|
|
43
|
-
|
|
87
|
+
Same as dashboard but skip server/Docusaurus diagnostics. Just list folder names with descriptions.
|
|
44
88
|
|
|
45
|
-
###
|
|
89
|
+
### 3. Topic argument: Search and load docs
|
|
46
90
|
|
|
47
91
|
When user provides a topic (e.g., `/sw:docs sync`, `/sw:docs troubleshooting`):
|
|
48
92
|
|
|
49
|
-
1. **Search**
|
|
93
|
+
1. **Search** across all configured directories:
|
|
50
94
|
```bash
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
95
|
+
DOC_DIRS=$(jq -r '(.documentation.directories // [".specweave/docs"])[]' .specweave/config.json 2>/dev/null)
|
|
96
|
+
[ -z "$DOC_DIRS" ] && DOC_DIRS=".specweave/docs"
|
|
97
|
+
for dir in $DOC_DIRS; do
|
|
98
|
+
find "$dir" -type d -iname "*<topic>*" -maxdepth 4 2>/dev/null
|
|
99
|
+
find "$dir" -type f -iname "*<topic>*.md" -maxdepth 5 2>/dev/null
|
|
100
|
+
done
|
|
56
101
|
```
|
|
57
102
|
|
|
58
103
|
2. **If found**: Read the most relevant files (up to 3-5) and present a summary
|
|
59
104
|
3. **If not found**: Search file contents with Grep for the topic keyword, then present matches
|
|
60
105
|
|
|
61
|
-
###
|
|
106
|
+
### 4. `--serve` or serve intent: Browser preview guide
|
|
107
|
+
|
|
108
|
+
Detect serve intent from: `--serve`, `--preview`, or phrases like "serve", "preview", "browser", "open docs", "start server".
|
|
109
|
+
|
|
110
|
+
1. Check if server is already running:
|
|
111
|
+
```bash
|
|
112
|
+
lsof -i :3000-3010 -sTCP:LISTEN 2>/dev/null | grep -i node
|
|
113
|
+
```
|
|
114
|
+
|
|
115
|
+
2. **If running**: "Docs server already running at http://localhost:<port>"
|
|
116
|
+
3. **If not running**: Display:
|
|
117
|
+
```
|
|
118
|
+
To view docs in browser with hot reload, run in your terminal:
|
|
119
|
+
|
|
120
|
+
specweave docs preview
|
|
121
|
+
|
|
122
|
+
First run auto-installs Docusaurus (~30-60 seconds).
|
|
123
|
+
Subsequent runs start instantly.
|
|
124
|
+
|
|
125
|
+
Options:
|
|
126
|
+
specweave docs preview --port 3005 Use specific port
|
|
127
|
+
specweave docs preview --no-browser Don't auto-open browser
|
|
128
|
+
|
|
129
|
+
To stop: Ctrl+C in terminal, or: specweave docs kill
|
|
130
|
+
```
|
|
131
|
+
|
|
132
|
+
### 5. `--status`: Full status report
|
|
133
|
+
|
|
134
|
+
Run and display output of:
|
|
135
|
+
```bash
|
|
136
|
+
specweave docs status
|
|
137
|
+
```
|
|
138
|
+
|
|
139
|
+
### 6. Flags
|
|
62
140
|
|
|
63
141
|
| Flag | Behavior |
|
|
64
142
|
|------|----------|
|
|
65
143
|
| `--public` | Only search public docs |
|
|
66
144
|
| `--internal` | Only search internal docs |
|
|
67
145
|
| `--adr` | List and load ADRs specifically |
|
|
68
|
-
| `--list` |
|
|
146
|
+
| `--list` | List topics without diagnostics |
|
|
147
|
+
| `--serve` | Browser preview guide |
|
|
148
|
+
| `--status` | Run `specweave docs status` |
|
|
69
149
|
|
|
70
|
-
###
|
|
150
|
+
### 7. ADR Mode (`--adr` or "ADR" in topic)
|
|
71
151
|
|
|
72
|
-
List all ADRs with their titles:
|
|
152
|
+
List all ADRs with their titles across all directories:
|
|
73
153
|
```bash
|
|
74
|
-
|
|
75
|
-
|
|
154
|
+
DOC_DIRS=$(jq -r '(.documentation.directories // [".specweave/docs"])[]' .specweave/config.json 2>/dev/null)
|
|
155
|
+
[ -z "$DOC_DIRS" ] && DOC_DIRS=".specweave/docs"
|
|
156
|
+
for dir in $DOC_DIRS; do
|
|
157
|
+
for f in "$dir"/internal/architecture/adr/*.md; do
|
|
158
|
+
[ -f "$f" ] && echo "$(basename "$f"): $(head -1 "$f" | sed 's/^# //')"
|
|
159
|
+
done
|
|
76
160
|
done
|
|
77
161
|
```
|
|
78
162
|
|
|
79
163
|
If a specific ADR number is given, read and present it.
|
|
80
164
|
|
|
81
|
-
## Output
|
|
165
|
+
## Output Footer
|
|
166
|
+
|
|
167
|
+
Always append to any output:
|
|
82
168
|
|
|
83
|
-
When listing topics:
|
|
84
169
|
```
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
Public:
|
|
88
|
-
guides/ - Getting started, core concepts, mobile
|
|
89
|
-
workflows/ - Development workflows
|
|
90
|
-
troubleshooting/ - Common issues and fixes
|
|
91
|
-
api/ - API documentation
|
|
92
|
-
integrations/ - External tool integration guides
|
|
93
|
-
|
|
94
|
-
Internal:
|
|
95
|
-
specs/ - Feature specifications
|
|
96
|
-
architecture/ - ADRs, HLD, diagrams, concepts
|
|
97
|
-
operations/ - Operational runbooks
|
|
98
|
-
repos/ - Repository module documentation
|
|
99
|
-
|
|
100
|
-
Use: /sw:docs <topic> to load specific docs
|
|
170
|
+
Tip: Run `specweave docs preview` in your terminal to view all docs in browser with hot reload.
|
|
101
171
|
```
|
|
102
|
-
|
|
103
|
-
When loading docs, present content with clear headers and file paths for reference.
|