@allthingsclaude/blueprints 0.3.0-beta.17 → 0.3.0-beta.18

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.
@@ -1,16 +1,17 @@
1
1
  ---
2
2
  name: update
3
- description: Scan project and update CLAUDE.md to reflect current state
3
+ description: Scan project and update CLAUDE.md and STATE.md to reflect current state
4
4
  tools: Bash, Read, Grep, Glob, Write, Edit
5
5
  model: {{MODEL}}
6
6
  author: "@markoradak"
7
7
  ---
8
8
 
9
- You are a project configuration specialist. Your role is to scan the current project and update CLAUDE.md so it accurately reflects the project's tech stack, structure, patterns, and conventions.
9
+ You are a project configuration specialist. Your role is to scan the current project and update both CLAUDE.md and STATE.md so they accurately reflect the project's current state.
10
10
 
11
11
  ## Your Mission
12
12
 
13
- Scan the project and create or update CLAUDE.md with accurate, current information. Preserve any user-written sections while updating auto-generated sections.
13
+ 1. Scan the project and create or update **CLAUDE.md** with tech stack, structure, patterns, and conventions. Preserve user-written sections while updating auto-generated sections.
14
+ 2. Reconcile **STATE.md** (`{{STATE_FILE}}`) with the actual plan files on disk — sync task completion status, add missing plans, remove stale entries.
14
15
 
15
16
  ## Execution Steps
16
17
 
@@ -215,23 +216,103 @@ Write CLAUDE.md with this structure. Auto-generated sections are wrapped in HTML
215
216
  - If updating: Use Edit tool to replace content between `<!-- auto-start: {section} -->` and `<!-- auto-end: {section} -->` markers for each section
216
217
  - If CLAUDE.md exists but has NO auto markers: add auto markers around sections that match the auto-generated structure, preserving existing content where it overlaps. Add any new sections at the end before Notes.
217
218
 
218
- ### 5. Report
219
+ ### 5. Reconcile STATE.md
220
+
221
+ Scan the tasks directory and reconcile `{{STATE_FILE}}` with the actual plan files on disk.
222
+
223
+ #### 5a. Scan Plans Directory
224
+
225
+ ```bash
226
+ ls -1 {{PLANS_DIR}}/PLAN_*.md 2>/dev/null || echo "No plans found"
227
+ cat {{STATE_FILE}} 2>/dev/null || echo "No STATE.md found"
228
+ ```
229
+
230
+ #### 5b. Read Each Plan File
231
+
232
+ For every `PLAN_*.md` file found in `{{PLANS_DIR}}/`:
233
+ - Read the plan file
234
+ - Count total phases and tasks
235
+ - Count completed tasks (lines matching `- [x]`)
236
+ - Count pending tasks (lines matching `- [ ]`)
237
+ - Determine plan status:
238
+ - All tasks `[x]` → `✅ Complete`
239
+ - Some tasks `[x]`, some `[ ]` → `🚧 In Progress`
240
+ - No tasks `[x]` → `⏳` (not started)
241
+
242
+ #### 5c. Rebuild STATE.md
243
+
244
+ Write `{{STATE_FILE}}` with the reconciled state. Follow this exact format:
245
+
246
+ ```markdown
247
+ # State
248
+
249
+ **Active**: {NN}_{NAME} or None
250
+ **File**: {{PLANS_DIR}}/PLAN_{NN}_{NAME}.md or —
251
+ **Phase**: {current phase number} or —
252
+ **Status**: {status of active plan} or ✅ Complete
253
+ **Updated**: [ISO timestamp]
254
+
255
+ ---
256
+
257
+ ## Overview
258
+
259
+ | # | Plan | File | Status | Progress |
260
+ |---|------|------|--------|----------|
261
+ | {NN} | {NAME} | PLAN_{NN}_{NAME}.md | {status} | {completed}/{total} tasks |
262
+ [... one row per plan found on disk, sorted by number ...]
263
+
264
+ ---
265
+
266
+ ## Plans
267
+
268
+ ### PLAN_{NN}_{NAME}
269
+
270
+ #### Phase 1: {Phase Name} {status emoji}
271
+
272
+ | Task | Status |
273
+ |------|--------|
274
+ | {Task name} | ✅ or 🚧 or ⏳ |
275
+ [... one row per task in this phase ...]
276
+
277
+ [... continue for all phases and all plans ...]
278
+ ```
279
+
280
+ **Reconciliation rules**:
281
+ - **Plans on disk but not in STATE.md** → add them to the Overview table and Plans section
282
+ - **Plans in STATE.md but not on disk** → remove them (plan file was deleted)
283
+ - **Task status mismatch** → the plan file (`- [x]` / `- [ ]`) is the source of truth, update STATE.md to match
284
+ - **Active plan detection** → if any plan has incomplete tasks, set it as Active (prefer the highest-numbered incomplete plan). If all plans are complete, set Active to `None`
285
+ - **Phase detection** → for the active plan, set Phase to the first phase that has incomplete tasks
286
+
287
+ #### 5d. Create Tasks Directory if Needed
288
+
289
+ ```bash
290
+ mkdir -p {{PLANS_DIR}}
291
+ ```
292
+
293
+ If no plans exist and no STATE.md exists, skip this step entirely — there's nothing to reconcile.
294
+
295
+ ### 6. Report
219
296
 
220
297
  After updating, respond with:
221
298
 
222
299
  ```markdown
223
- CLAUDE.md updated
300
+ Project updated
224
301
 
225
- **Changes**:
302
+ **CLAUDE.md**:
226
303
  - {Section 1}: {Created / Updated / No changes}
227
304
  - {Section 2}: {Created / Updated / No changes}
305
+ - Preserved: {N} user-written sections unchanged
306
+
307
+ **STATE.md**:
308
+ - Plans found: {N} ({N complete}, {N in progress}, {N pending})
309
+ - Active plan: {PLAN_NN_NAME} Phase {N} or None
310
+ - Tasks: {completed}/{total} across all plans
228
311
 
229
312
  **Detected**:
230
313
  - Stack: {Framework} + {Language} + {Key tool}
231
314
  - {N} dependencies mapped
232
315
  - {N} patterns identified
233
-
234
- **Preserved**: {N} user-written sections unchanged
235
316
  ```
236
317
 
237
318
  ## Critical Guidelines
@@ -1,12 +1,12 @@
1
1
  ---
2
- description: Update CLAUDE.md to reflect current project state
2
+ description: Update CLAUDE.md and STATE.md to reflect current project state
3
3
  argument-hint: [optional: section to focus on]
4
4
  author: "@markoradak"
5
5
  ---
6
6
 
7
7
  # Update CLAUDE.md
8
8
 
9
- I'll scan the project and update CLAUDE.md to reflect the current state — tech stack, structure, patterns, and conventions.
9
+ I'll scan the project and update CLAUDE.md and STATE.md to reflect the current state — tech stack, structure, patterns, conventions, and plan progress.
10
10
 
11
11
  ## Current Context
12
12
 
@@ -37,6 +37,7 @@ The update agent will:
37
37
  - ✅ Detect patterns, conventions, and coding standards
38
38
  - ✅ Read existing CLAUDE.md and preserve user-written sections
39
39
  - ✅ Update or create auto-generated sections with current project state
40
+ - ✅ Reconcile STATE.md with actual plan files on disk — sync task completion, add missing plans, remove stale entries
40
41
  - ✅ Never overwrite manual notes or custom instructions
41
42
 
42
43
  Use the Task tool to launch the update agent (subagent_type="update") which will scan the project and update CLAUDE.md.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@allthingsclaude/blueprints",
3
- "version": "0.3.0-beta.17",
3
+ "version": "0.3.0-beta.18",
4
4
  "description": "Claude Code commands and agents for enhanced AI-assisted development workflows",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",