wtf-p 0.3.0 → 0.5.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/README.md +146 -208
- package/bin/commands/doctor.js +88 -2
- package/bin/commands/install-logic.js +127 -36
- package/bin/commands/status.js +22 -4
- package/bin/commands/update.js +5 -4
- package/bin/install.js +66 -26
- package/bin/lib/analyze-impact.js +105 -0
- package/bin/lib/bib-format.js +161 -0
- package/bin/lib/bib-index.js +104 -0
- package/bin/lib/checkpoint.js +183 -0
- package/bin/lib/citation-fetcher.js +299 -0
- package/bin/lib/citation-ranker.js +133 -0
- package/bin/lib/context-primer.js +214 -0
- package/bin/lib/manifest.js +80 -2
- package/bin/lib/scholar-lookup.js +188 -0
- package/bin/lib/semantic-scholar.js +184 -0
- package/bin/lib/utils.js +22 -1
- package/bin/uninstall.js +270 -111
- package/core/write-the-f-paper/references/agent-model-matrix.md +62 -0
- package/core/write-the-f-paper/references/checkpoints.md +160 -9
- package/core/write-the-f-paper/references/context-fidelity.md +153 -0
- package/core/write-the-f-paper/references/deviation-rules.md +150 -0
- package/core/write-the-f-paper/references/git-integration.md +80 -0
- package/core/write-the-f-paper/references/orchestrator-pattern.md +167 -0
- package/core/write-the-f-paper/references/planning-config.md +135 -0
- package/core/write-the-f-paper/references/ui-brand.md +186 -0
- package/core/write-the-f-paper/templates/UAT.md +80 -0
- package/core/write-the-f-paper/templates/base-prefs.yaml +42 -0
- package/core/write-the-f-paper/templates/config.json +31 -5
- package/core/write-the-f-paper/workflows/create-outline.wcn.md +1 -1
- package/core/write-the-f-paper/workflows/execute-outline.md +163 -0
- package/core/write-the-f-paper/workflows/execute-outline.wcn.md +73 -0
- package/core/write-the-f-paper/workflows/execute-section.wcn.md +141 -169
- package/core/write-the-f-paper/workflows/plan-section.wcn.md +96 -103
- package/core/write-the-f-paper/workflows/research-gap.md +27 -3
- package/core/write-the-f-paper/workflows/research-gap.wcn.md +18 -1
- package/core/write-the-f-paper/workflows/verify-work.md +251 -0
- package/core/write-the-f-paper/workflows/verify-work.wcn.md +74 -0
- package/package.json +19 -7
- package/vendors/claude/.claude-plugin/plugin.json +2 -2
- package/vendors/claude/agents/wtfp/argument-verifier.md +189 -0
- package/vendors/claude/agents/wtfp/citation-expert.md +45 -0
- package/vendors/claude/agents/wtfp/citation-formatter.md +42 -0
- package/vendors/claude/agents/wtfp/coherence-checker.md +167 -0
- package/vendors/claude/agents/wtfp/outliner.md +259 -0
- package/vendors/claude/agents/wtfp/plan-checker.md +249 -0
- package/vendors/claude/agents/wtfp/prose-polisher.md +166 -0
- package/vendors/claude/agents/wtfp/research-synthesizer.md +215 -0
- package/vendors/claude/agents/wtfp/section-planner.md +364 -0
- package/vendors/claude/agents/wtfp/section-reviewer.md +182 -0
- package/vendors/claude/agents/wtfp/section-writer.md +312 -0
- package/vendors/claude/commands/wtfp/add-todo.md +108 -0
- package/vendors/claude/commands/wtfp/analyze-bib.md +60 -249
- package/vendors/claude/commands/wtfp/audit-milestone.md +286 -0
- package/vendors/claude/commands/wtfp/check-refs.md +60 -131
- package/vendors/claude/commands/wtfp/check-todos.md +152 -0
- package/vendors/claude/commands/wtfp/checkpoint.md +105 -0
- package/vendors/claude/commands/wtfp/contribute.md +1 -1
- package/vendors/claude/commands/wtfp/create-outline.md +109 -195
- package/vendors/claude/commands/wtfp/create-poster.md +1 -1
- package/vendors/claude/commands/wtfp/create-slides.md +1 -1
- package/vendors/claude/commands/wtfp/discuss-section.md +1 -1
- package/vendors/claude/commands/wtfp/execute-outline.md +257 -0
- package/vendors/claude/commands/wtfp/export-latex.md +1 -1
- package/vendors/claude/commands/wtfp/help.md +174 -280
- package/vendors/claude/commands/wtfp/insert-section.md +1 -1
- package/vendors/claude/commands/wtfp/list-assumptions.md +1 -1
- package/vendors/claude/commands/wtfp/map-project.md +35 -124
- package/vendors/claude/commands/wtfp/new-paper.md +88 -362
- package/vendors/claude/commands/wtfp/pause-writing.md +1 -1
- package/vendors/claude/commands/wtfp/plan-milestone-gaps.md +255 -0
- package/vendors/claude/commands/wtfp/plan-revision.md +1 -1
- package/vendors/claude/commands/wtfp/plan-section.md +165 -190
- package/vendors/claude/commands/wtfp/polish-prose.md +66 -118
- package/vendors/claude/commands/wtfp/progress.md +82 -254
- package/vendors/claude/commands/wtfp/quick.md +107 -0
- package/vendors/claude/commands/wtfp/remove-section.md +1 -1
- package/vendors/claude/commands/wtfp/report-bug.md +1 -1
- package/vendors/claude/commands/wtfp/request-feature.md +1 -1
- package/vendors/claude/commands/wtfp/research-gap.md +138 -151
- package/vendors/claude/commands/wtfp/resume-writing.md +1 -1
- package/vendors/claude/commands/wtfp/review-section.md +55 -333
- package/vendors/claude/commands/wtfp/settings.md +197 -0
- package/vendors/claude/commands/wtfp/submit-milestone.md +248 -99
- package/vendors/claude/commands/wtfp/update.md +112 -0
- package/vendors/claude/commands/wtfp/verify-work.md +254 -0
- package/vendors/claude/commands/wtfp/write-section.md +144 -180
- package/vendors/claude/mcp/research-server/package.json +13 -0
- package/vendors/claude/mcp/research-server/src/index.js +133 -0
- package/vendors/gemini/agents/wtfp/argument-verifier.md +184 -0
- package/vendors/gemini/agents/wtfp/citation-expert.md +41 -0
- package/vendors/gemini/agents/wtfp/citation-formatter.md +38 -0
- package/vendors/gemini/agents/wtfp/coherence-checker.md +162 -0
- package/vendors/gemini/agents/wtfp/outliner.md +252 -0
- package/vendors/gemini/agents/wtfp/plan-checker.md +244 -0
- package/vendors/gemini/agents/wtfp/prose-polisher.md +158 -0
- package/vendors/gemini/agents/wtfp/research-synthesizer.md +205 -0
- package/vendors/gemini/agents/wtfp/section-planner.md +355 -0
- package/vendors/gemini/agents/wtfp/section-reviewer.md +175 -0
- package/vendors/gemini/agents/wtfp/section-writer.md +304 -0
- package/vendors/gemini/commands/wtfp/add-todo.toml +102 -0
- package/vendors/gemini/commands/wtfp/analyze-bib.toml +126 -0
- package/vendors/gemini/commands/wtfp/audit-milestone.toml +278 -0
- package/vendors/gemini/commands/wtfp/check-refs.toml +123 -0
- package/vendors/gemini/commands/wtfp/check-todos.toml +145 -0
- package/vendors/gemini/commands/wtfp/checkpoint.toml +96 -0
- package/vendors/gemini/commands/wtfp/contribute.toml +269 -0
- package/vendors/gemini/commands/wtfp/create-outline.toml +180 -0
- package/vendors/gemini/commands/wtfp/create-poster.toml +36 -0
- package/vendors/gemini/commands/wtfp/create-slides.toml +35 -0
- package/vendors/gemini/commands/wtfp/discuss-section.toml +62 -0
- package/vendors/gemini/commands/wtfp/execute-outline.toml +247 -0
- package/vendors/gemini/commands/wtfp/export-latex.toml +209 -0
- package/vendors/gemini/commands/wtfp/help.toml +184 -0
- package/vendors/gemini/commands/wtfp/insert-section.toml +123 -0
- package/vendors/gemini/commands/wtfp/list-assumptions.toml +104 -0
- package/vendors/gemini/commands/wtfp/map-project.toml +99 -0
- package/vendors/gemini/commands/wtfp/new-paper.toml +160 -0
- package/vendors/gemini/commands/wtfp/pause-writing.toml +140 -0
- package/vendors/gemini/commands/wtfp/plan-milestone-gaps.toml +249 -0
- package/vendors/gemini/commands/wtfp/plan-revision.toml +171 -0
- package/vendors/gemini/commands/wtfp/plan-section.toml +212 -0
- package/vendors/gemini/commands/wtfp/polish-prose.toml +114 -0
- package/vendors/gemini/commands/wtfp/progress.toml +145 -0
- package/vendors/gemini/commands/wtfp/quick.toml +96 -0
- package/vendors/gemini/commands/wtfp/remove-section.toml +140 -0
- package/vendors/gemini/commands/wtfp/report-bug.toml +126 -0
- package/vendors/gemini/commands/wtfp/request-feature.toml +155 -0
- package/vendors/gemini/commands/wtfp/research-gap.toml +214 -0
- package/vendors/gemini/commands/wtfp/resume-writing.toml +136 -0
- package/vendors/gemini/commands/wtfp/review-section.toml +121 -0
- package/vendors/gemini/commands/wtfp/settings.toml +191 -0
- package/vendors/gemini/commands/wtfp/submit-milestone.toml +351 -0
- package/vendors/gemini/commands/wtfp/update.toml +107 -0
- package/vendors/gemini/commands/wtfp/verify-work.toml +245 -0
- package/vendors/gemini/commands/wtfp/write-section.toml +228 -0
- package/vendors/opencode/agents/wtfp/argument-verifier.md +184 -0
- package/vendors/opencode/agents/wtfp/citation-expert.md +41 -0
- package/vendors/opencode/agents/wtfp/citation-formatter.md +38 -0
- package/vendors/opencode/agents/wtfp/coherence-checker.md +162 -0
- package/vendors/opencode/agents/wtfp/outliner.md +252 -0
- package/vendors/opencode/agents/wtfp/plan-checker.md +244 -0
- package/vendors/opencode/agents/wtfp/prose-polisher.md +158 -0
- package/vendors/opencode/agents/wtfp/research-synthesizer.md +205 -0
- package/vendors/opencode/agents/wtfp/section-planner.md +355 -0
- package/vendors/opencode/agents/wtfp/section-reviewer.md +175 -0
- package/vendors/opencode/agents/wtfp/section-writer.md +304 -0
- package/vendors/opencode/commands/wtfp/add-todo.md +103 -0
- package/vendors/opencode/commands/wtfp/analyze-bib.md +127 -0
- package/vendors/opencode/commands/wtfp/audit-milestone.md +279 -0
- package/vendors/opencode/commands/wtfp/check-refs.md +124 -0
- package/vendors/opencode/commands/wtfp/check-todos.md +146 -0
- package/vendors/opencode/commands/wtfp/checkpoint.md +97 -0
- package/vendors/opencode/commands/wtfp/contribute.md +266 -0
- package/vendors/opencode/commands/wtfp/create-outline.md +181 -0
- package/vendors/opencode/commands/wtfp/create-poster.md +37 -0
- package/vendors/opencode/commands/wtfp/create-slides.md +36 -0
- package/vendors/opencode/commands/wtfp/discuss-section.md +63 -0
- package/vendors/opencode/commands/wtfp/execute-outline.md +248 -0
- package/vendors/opencode/commands/wtfp/export-latex.md +210 -0
- package/vendors/opencode/commands/wtfp/help.md +185 -0
- package/vendors/opencode/commands/wtfp/insert-section.md +124 -0
- package/vendors/opencode/commands/wtfp/list-assumptions.md +105 -0
- package/vendors/opencode/commands/wtfp/map-project.md +100 -0
- package/vendors/opencode/commands/wtfp/new-paper.md +161 -0
- package/vendors/opencode/commands/wtfp/pause-writing.md +141 -0
- package/vendors/opencode/commands/wtfp/plan-milestone-gaps.md +250 -0
- package/vendors/opencode/commands/wtfp/plan-revision.md +174 -0
- package/vendors/opencode/commands/wtfp/plan-section.md +214 -0
- package/vendors/opencode/commands/wtfp/polish-prose.md +115 -0
- package/vendors/opencode/commands/wtfp/progress.md +146 -0
- package/vendors/opencode/commands/wtfp/quick.md +97 -0
- package/vendors/opencode/commands/wtfp/remove-section.md +141 -0
- package/vendors/opencode/commands/wtfp/report-bug.md +127 -0
- package/vendors/opencode/commands/wtfp/request-feature.md +156 -0
- package/vendors/opencode/commands/wtfp/research-gap.md +215 -0
- package/vendors/opencode/commands/wtfp/resume-writing.md +137 -0
- package/vendors/opencode/commands/wtfp/review-section.md +123 -0
- package/vendors/opencode/commands/wtfp/settings.md +192 -0
- package/vendors/opencode/commands/wtfp/submit-milestone.md +352 -0
- package/vendors/opencode/commands/wtfp/update.md +108 -0
- package/vendors/opencode/commands/wtfp/verify-work.md +246 -0
- package/vendors/opencode/commands/wtfp/write-section.md +228 -0
|
@@ -1,43 +1,58 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: wtfp:submit-milestone
|
|
3
|
-
description: Archive completed submission
|
|
3
|
+
description: Archive a completed draft or submission version
|
|
4
4
|
argument-hint: "[version]"
|
|
5
5
|
allowed-tools:
|
|
6
6
|
- Read
|
|
7
7
|
- Bash
|
|
8
8
|
- Write
|
|
9
9
|
- AskUserQuestion
|
|
10
|
+
- Glob
|
|
11
|
+
- Grep
|
|
10
12
|
---
|
|
11
13
|
|
|
12
14
|
<objective>
|
|
13
15
|
Archive a completed draft or submission round.
|
|
14
16
|
|
|
17
|
+
Archives full state to `.planning/milestones/{version}/`.
|
|
15
18
|
Creates MILESTONES.md entry with stats.
|
|
16
|
-
|
|
17
|
-
Creates git tag
|
|
18
|
-
|
|
19
|
+
Evolves PROJECT.md (shipped claims to Validated).
|
|
20
|
+
Creates annotated git tag.
|
|
21
|
+
Resets ROADMAP.md for revision round.
|
|
19
22
|
</objective>
|
|
20
23
|
|
|
21
24
|
<process>
|
|
22
25
|
|
|
23
|
-
<step name="
|
|
24
|
-
**
|
|
26
|
+
<step name="validate_environment">
|
|
27
|
+
**Step 1: Validate Environment and Gather Stats**
|
|
25
28
|
|
|
26
29
|
```bash
|
|
27
30
|
[ ! -f .planning/STATE.md ] && echo "ERROR: No project state found" && exit 1
|
|
31
|
+
[ ! -f .planning/ROADMAP.md ] && echo "ERROR: No ROADMAP.md found" && exit 1
|
|
32
|
+
[ ! -f .planning/PROJECT.md ] && echo "ERROR: No PROJECT.md found" && exit 1
|
|
28
33
|
```
|
|
29
34
|
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
-
|
|
35
|
+
Read version from argument:
|
|
36
|
+
```bash
|
|
37
|
+
VERSION=$ARGUMENTS # e.g., "draft-1", "camera-ready", "revision-2"
|
|
38
|
+
[ -z "$VERSION" ] && echo "ERROR: Version required. Usage: /wtfp:submit-milestone draft-1" && exit 1
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
**Gather statistics from ROADMAP.md and section summaries:**
|
|
42
|
+
- Total sections (count section entries in ROADMAP)
|
|
43
|
+
- Sections complete (count checked `[x]` entries)
|
|
44
|
+
- Read all SUMMARY.md files in `.planning/sections/*/`:
|
|
45
|
+
- Total words (sum from each summary)
|
|
46
|
+
- Citations used
|
|
47
|
+
- Figures
|
|
48
|
+
- Tables
|
|
33
49
|
|
|
34
|
-
If incomplete:
|
|
50
|
+
If incomplete sections exist:
|
|
35
51
|
```
|
|
36
52
|
WARNING: Not all sections are complete.
|
|
37
53
|
|
|
38
54
|
Sections remaining:
|
|
39
55
|
- [Section N]: [status]
|
|
40
|
-
- [Section M]: [status]
|
|
41
56
|
|
|
42
57
|
Continue anyway?
|
|
43
58
|
```
|
|
@@ -46,155 +61,287 @@ Use AskUserQuestion:
|
|
|
46
61
|
- header: "Proceed?"
|
|
47
62
|
- question: "Archive milestone with incomplete sections?"
|
|
48
63
|
- options:
|
|
49
|
-
- "Yes, archive anyway"
|
|
50
|
-
- "No, finish first"
|
|
64
|
+
- "Yes, archive anyway" -- Create milestone as-is
|
|
65
|
+
- "No, finish first" -- Return to writing
|
|
66
|
+
|
|
67
|
+
</step>
|
|
68
|
+
|
|
69
|
+
<step name="read_git_config">
|
|
70
|
+
**Step 2: Read Git Config**
|
|
71
|
+
|
|
72
|
+
```bash
|
|
73
|
+
BRANCH_STRATEGY=$(cat .planning/config.json 2>/dev/null | grep -o '"branching_strategy"[[:space:]]*:[[:space:]]*"[^"]*"' | grep -o '"[^"]*"$' | tr -d '"' || echo "none")
|
|
74
|
+
SQUASH=$(cat .planning/config.json 2>/dev/null | grep -o '"squash_on_merge"[[:space:]]*:[[:space:]]*[^,}]*' | grep -o 'true\|false' || echo "false")
|
|
75
|
+
COMMIT_DOCS=$(cat .planning/config.json 2>/dev/null | grep -o '"commit_docs"[[:space:]]*:[[:space:]]*[^,}]*' | grep -o 'true\|false' || echo "true")
|
|
76
|
+
SUBMISSION_TEMPLATE=$(cat .planning/config.json 2>/dev/null | grep -o '"submission_branch_template"[[:space:]]*:[[:space:]]*"[^"]*"' | grep -o '"[^"]*"$' | tr -d '"' || echo "wtfp/{milestone}-{slug}")
|
|
77
|
+
```
|
|
78
|
+
|
|
79
|
+
Store these for use in subsequent steps.
|
|
51
80
|
|
|
52
81
|
</step>
|
|
53
82
|
|
|
54
|
-
<step name="
|
|
55
|
-
**
|
|
83
|
+
<step name="archive">
|
|
84
|
+
**Step 3: Archive to .planning/milestones/ (MLN-01)**
|
|
85
|
+
|
|
86
|
+
```bash
|
|
87
|
+
ARCHIVE_DIR=".planning/milestones/${VERSION}"
|
|
88
|
+
mkdir -p "$ARCHIVE_DIR"
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
Archive these files:
|
|
92
|
+
```bash
|
|
93
|
+
# Core planning files
|
|
94
|
+
cp .planning/ROADMAP.md "$ARCHIVE_DIR/${VERSION}-ROADMAP.md"
|
|
95
|
+
cp .planning/STATE.md "$ARCHIVE_DIR/${VERSION}-STATE.md"
|
|
96
|
+
|
|
97
|
+
# Argument map if exists
|
|
98
|
+
cp .planning/structure/argument-map.md "$ARCHIVE_DIR/${VERSION}-argument-map.md" 2>/dev/null || true
|
|
99
|
+
|
|
100
|
+
# All section summaries
|
|
101
|
+
for summary in .planning/sections/*/*-SUMMARY.md; do
|
|
102
|
+
[ -f "$summary" ] && cp "$summary" "$ARCHIVE_DIR/"
|
|
103
|
+
done
|
|
104
|
+
```
|
|
56
105
|
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
-
|
|
60
|
-
|
|
61
|
-
- Word variance: [+/- Z%]
|
|
62
|
-
- Citations used: [N]
|
|
63
|
-
- Figures: [N]
|
|
64
|
-
- Tables: [N]
|
|
65
|
-
- Issues resolved: [N]
|
|
66
|
-
- Issues deferred: [N]
|
|
106
|
+
Verify archive created:
|
|
107
|
+
```bash
|
|
108
|
+
ls -la "$ARCHIVE_DIR/"
|
|
109
|
+
```
|
|
67
110
|
|
|
68
111
|
</step>
|
|
69
112
|
|
|
70
|
-
<step name="
|
|
71
|
-
**Create/
|
|
113
|
+
<step name="milestones_entry">
|
|
114
|
+
**Step 4: Create/Update MILESTONES.md (MLN-02)**
|
|
115
|
+
|
|
116
|
+
Read existing MILESTONES.md if present, otherwise create header.
|
|
117
|
+
|
|
118
|
+
Prepend new entry to `.planning/MILESTONES.md`:
|
|
72
119
|
|
|
73
120
|
```markdown
|
|
74
121
|
# Milestones
|
|
75
122
|
|
|
76
|
-
##
|
|
77
|
-
|
|
78
|
-
**Date:** [date]
|
|
79
|
-
**Status:** [Submitted / Draft / Ready for Review]
|
|
123
|
+
## {version} - {description}
|
|
80
124
|
|
|
81
|
-
|
|
82
|
-
|
|
125
|
+
**Date:** {YYYY-MM-DD}
|
|
126
|
+
**Status:** {Submitted / Draft / Ready for Review}
|
|
83
127
|
|
|
84
128
|
### Stats
|
|
85
|
-
- Sections:
|
|
86
|
-
- Words:
|
|
87
|
-
- Citations:
|
|
88
|
-
- Figures:
|
|
129
|
+
- Sections: {M}/{N} complete
|
|
130
|
+
- Words: {X} / {Y} target ({variance}%)
|
|
131
|
+
- Citations: {N}
|
|
132
|
+
- Figures: {N}
|
|
133
|
+
- Tables: {N}
|
|
89
134
|
|
|
90
135
|
### Sections Included
|
|
91
136
|
| Section | Words | Status |
|
|
92
137
|
|---------|-------|--------|
|
|
93
|
-
|
|
|
94
|
-
| Methods | [X] | Complete |
|
|
138
|
+
| {name} | {X} | {status} |
|
|
95
139
|
| ... | | |
|
|
96
140
|
|
|
97
141
|
### Key Decisions
|
|
98
|
-
|
|
142
|
+
{Extract from section SUMMARY.md files - concatenate "Decisions Made" sections}
|
|
99
143
|
|
|
100
144
|
### Known Issues
|
|
101
|
-
|
|
145
|
+
{Any deferred issues from section reviews - extract from SUMMARY.md "Next Steps" sections}
|
|
102
146
|
|
|
103
147
|
### Git Reference
|
|
104
|
-
- Tag: `
|
|
105
|
-
- Commit:
|
|
148
|
+
- Tag: `{version}`
|
|
149
|
+
- Commit: {hash}
|
|
150
|
+
- Archive: `.planning/milestones/{version}/`
|
|
106
151
|
|
|
107
152
|
---
|
|
108
153
|
|
|
109
|
-
|
|
154
|
+
{Previous milestones below...}
|
|
110
155
|
```
|
|
111
156
|
|
|
112
157
|
</step>
|
|
113
158
|
|
|
114
|
-
<step name="
|
|
115
|
-
**
|
|
159
|
+
<step name="project_evolution">
|
|
160
|
+
**Step 5: Update PROJECT.md (MLN-03)**
|
|
161
|
+
|
|
162
|
+
Read PROJECT.md. Make these updates:
|
|
163
|
+
|
|
164
|
+
**Requirements section:**
|
|
165
|
+
- Identify items marked as complete/shipped in the "Active" or "In Progress" column
|
|
166
|
+
- Move those items to "Validated" status
|
|
167
|
+
|
|
168
|
+
**What This Is section:**
|
|
169
|
+
- Append: "v{version}: {brief milestone description}"
|
|
170
|
+
|
|
171
|
+
**Key Decisions section:**
|
|
172
|
+
- Add entry: "{date} | Milestone {version} archived | {N} sections, {X} words"
|
|
116
173
|
|
|
174
|
+
Write updated PROJECT.md.
|
|
175
|
+
|
|
176
|
+
</step>
|
|
177
|
+
|
|
178
|
+
<step name="git_tag">
|
|
179
|
+
**Step 6: Git Operations (MLN-04)**
|
|
180
|
+
|
|
181
|
+
**If BRANCH_STRATEGY = "submission":**
|
|
182
|
+
|
|
183
|
+
1. Create submission branch:
|
|
117
184
|
```bash
|
|
118
|
-
|
|
185
|
+
# Resolve template variables
|
|
186
|
+
PAPER_SLUG=$(cat .planning/PROJECT.md | grep -m1 "^#" | sed 's/^# //' | tr '[:upper:]' '[:lower:]' | tr ' ' '-' | tr -cd '[:alnum:]-')
|
|
187
|
+
BRANCH_NAME=$(echo "$SUBMISSION_TEMPLATE" | sed "s/{milestone}/${VERSION}/g" | sed "s/{slug}/${PAPER_SLUG}/g")
|
|
188
|
+
|
|
189
|
+
git checkout -b "$BRANCH_NAME"
|
|
119
190
|
```
|
|
120
191
|
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
192
|
+
2. Commit archive and MILESTONES.md:
|
|
193
|
+
```bash
|
|
194
|
+
git add .planning/milestones/
|
|
195
|
+
git add .planning/MILESTONES.md
|
|
196
|
+
git add .planning/PROJECT.md
|
|
197
|
+
|
|
198
|
+
# Respect commit_docs for planning files
|
|
199
|
+
if [ "$COMMIT_DOCS" = "true" ]; then
|
|
200
|
+
git add .planning/STATE.md .planning/ROADMAP.md
|
|
201
|
+
fi
|
|
125
202
|
|
|
126
|
-
|
|
203
|
+
git commit -m "$(cat <<'EOF'
|
|
204
|
+
milestone({version}): archive submission
|
|
205
|
+
|
|
206
|
+
Sections: {M}/{N}
|
|
207
|
+
Words: {X}
|
|
208
|
+
Date: {date}
|
|
127
209
|
|
|
128
|
-
|
|
129
|
-
|
|
210
|
+
Archive: .planning/milestones/{version}/
|
|
211
|
+
EOF
|
|
212
|
+
)"
|
|
213
|
+
```
|
|
130
214
|
|
|
215
|
+
3. Create annotated tag:
|
|
131
216
|
```bash
|
|
132
|
-
git
|
|
217
|
+
git tag -a "${VERSION}" -m "$(cat <<EOF
|
|
218
|
+
Milestone: ${VERSION}
|
|
219
|
+
|
|
220
|
+
Sections completed:
|
|
221
|
+
$(list sections from stats)
|
|
222
|
+
|
|
223
|
+
Words: ${WORD_COUNT}
|
|
224
|
+
Date: ${DATE}
|
|
225
|
+
Archive: .planning/milestones/${VERSION}/
|
|
226
|
+
EOF
|
|
227
|
+
)"
|
|
228
|
+
```
|
|
229
|
+
|
|
230
|
+
4. Merge back to base branch:
|
|
231
|
+
```bash
|
|
232
|
+
BASE_BRANCH=$(git rev-parse --abbrev-ref HEAD@{1} 2>/dev/null || echo "main")
|
|
233
|
+
git checkout "$BASE_BRANCH"
|
|
234
|
+
|
|
235
|
+
if [ "$SQUASH" = "true" ]; then
|
|
236
|
+
git merge --squash "$BRANCH_NAME"
|
|
237
|
+
git commit -m "milestone(${VERSION}): squash merge submission branch"
|
|
238
|
+
else
|
|
239
|
+
git merge --no-ff "$BRANCH_NAME" -m "milestone(${VERSION}): merge submission branch"
|
|
240
|
+
fi
|
|
241
|
+
|
|
242
|
+
git branch -d "$BRANCH_NAME"
|
|
243
|
+
```
|
|
244
|
+
|
|
245
|
+
**If BRANCH_STRATEGY != "submission":**
|
|
246
|
+
|
|
247
|
+
1. Commit archive and MILESTONES.md (respect commit_docs):
|
|
248
|
+
```bash
|
|
249
|
+
git add .planning/milestones/
|
|
250
|
+
git add .planning/MILESTONES.md
|
|
251
|
+
git add .planning/PROJECT.md
|
|
252
|
+
|
|
253
|
+
if [ "$COMMIT_DOCS" = "true" ]; then
|
|
254
|
+
git add .planning/STATE.md .planning/ROADMAP.md
|
|
255
|
+
fi
|
|
256
|
+
|
|
133
257
|
git commit -m "$(cat <<'EOF'
|
|
134
|
-
milestone:
|
|
258
|
+
milestone({version}): archive submission
|
|
259
|
+
|
|
260
|
+
Sections: {M}/{N}
|
|
261
|
+
Words: {X}
|
|
262
|
+
Date: {date}
|
|
135
263
|
|
|
136
|
-
|
|
137
|
-
Sections: [M]/[N]
|
|
138
|
-
Status: [status]
|
|
264
|
+
Archive: .planning/milestones/{version}/
|
|
139
265
|
EOF
|
|
140
266
|
)"
|
|
267
|
+
```
|
|
268
|
+
|
|
269
|
+
2. Create annotated tag:
|
|
270
|
+
```bash
|
|
271
|
+
git tag -a "${VERSION}" -m "$(cat <<EOF
|
|
272
|
+
Milestone: ${VERSION}
|
|
141
273
|
|
|
142
|
-
|
|
274
|
+
Sections completed:
|
|
275
|
+
$(list sections from stats)
|
|
276
|
+
|
|
277
|
+
Words: ${WORD_COUNT}
|
|
278
|
+
Date: ${DATE}
|
|
279
|
+
Archive: .planning/milestones/${VERSION}/
|
|
280
|
+
EOF
|
|
281
|
+
)"
|
|
143
282
|
```
|
|
144
283
|
|
|
145
284
|
</step>
|
|
146
285
|
|
|
147
|
-
<step name="
|
|
148
|
-
**
|
|
286
|
+
<step name="reset_roadmap">
|
|
287
|
+
**Step 7: Reset ROADMAP.md (MLN-05)**
|
|
149
288
|
|
|
150
|
-
|
|
151
|
-
- header: "Next Steps"
|
|
152
|
-
- question: "What's next after this milestone?"
|
|
153
|
-
- options:
|
|
154
|
-
- "Wait for reviews" — Pause until feedback
|
|
155
|
-
- "Start revisions" — Begin revision round
|
|
156
|
-
- "Done for now" — Just archive
|
|
289
|
+
After archival, prepare for revision round:
|
|
157
290
|
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
291
|
+
1. Add "Previous Milestone" note at top of ROADMAP.md:
|
|
292
|
+
```markdown
|
|
293
|
+
> **Previous:** {version} archived on {date}
|
|
294
|
+
```
|
|
295
|
+
|
|
296
|
+
2. Reset all section checkboxes (change `[x]` to `[ ]`):
|
|
297
|
+
```bash
|
|
298
|
+
sed -i 's/\[x\]/[ ]/g' .planning/ROADMAP.md
|
|
299
|
+
```
|
|
300
|
+
|
|
301
|
+
3. Keep section structure intact for revision round.
|
|
302
|
+
|
|
303
|
+
4. Update STATE.md:
|
|
304
|
+
- Reset position to "Revision round after {version}"
|
|
305
|
+
- Note milestone archived
|
|
306
|
+
- Clear any in-progress tracking
|
|
162
307
|
|
|
163
308
|
</step>
|
|
164
309
|
|
|
165
|
-
<step name="
|
|
166
|
-
**
|
|
310
|
+
<step name="completion_banner">
|
|
311
|
+
**Step 8: Completion Banner**
|
|
167
312
|
|
|
168
313
|
```
|
|
169
|
-
|
|
314
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
315
|
+
WTF-P ► MILESTONE ARCHIVED ✓
|
|
316
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
170
317
|
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
- Git tag: [version]
|
|
318
|
+
Version: {version}
|
|
319
|
+
Archive: .planning/milestones/{version}/
|
|
320
|
+
Tag: {version}
|
|
175
321
|
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
322
|
+
Stats:
|
|
323
|
+
Sections: {M}/{N}
|
|
324
|
+
Words: {X}
|
|
325
|
+
Citations: {N}
|
|
180
326
|
|
|
181
|
-
|
|
327
|
+
Git:
|
|
328
|
+
Commit: {hash}
|
|
329
|
+
Tag: {version}
|
|
182
330
|
|
|
183
|
-
|
|
331
|
+
───────────────────────────────────────────
|
|
184
332
|
|
|
185
|
-
|
|
333
|
+
## Next Up
|
|
186
334
|
|
|
187
335
|
**Wait for reviews:**
|
|
188
|
-
|
|
189
|
-
`/wtfp:import-reviews` (coming soon)
|
|
336
|
+
Run `/wtfp:progress` when feedback arrives
|
|
190
337
|
|
|
191
338
|
**Start revisions:**
|
|
192
|
-
`/wtfp:progress`
|
|
339
|
+
Run `/wtfp:progress` to see what needs revision
|
|
193
340
|
|
|
194
|
-
**
|
|
195
|
-
|
|
341
|
+
**Audit before next submission:**
|
|
342
|
+
Run `/wtfp:audit-milestone` to check readiness
|
|
196
343
|
|
|
197
|
-
|
|
344
|
+
───────────────────────────────────────────
|
|
198
345
|
```
|
|
199
346
|
|
|
200
347
|
</step>
|
|
@@ -202,10 +349,12 @@ Your work is archived. Run `/wtfp:progress` when ready to continue.
|
|
|
202
349
|
</process>
|
|
203
350
|
|
|
204
351
|
<success_criteria>
|
|
205
|
-
- [ ]
|
|
206
|
-
- [ ]
|
|
207
|
-
- [ ] MILESTONES.md
|
|
208
|
-
- [ ]
|
|
209
|
-
- [ ] Git tag created
|
|
210
|
-
- [ ]
|
|
352
|
+
- [ ] Archive directory created at `.planning/milestones/{version}/`
|
|
353
|
+
- [ ] Archive contains: ROADMAP, argument-map, STATE, section summaries
|
|
354
|
+
- [ ] MILESTONES.md entry created with version, date, stats table
|
|
355
|
+
- [ ] PROJECT.md updated (shipped items to Validated, What This Is appended)
|
|
356
|
+
- [ ] Git tag created with annotated message listing sections completed
|
|
357
|
+
- [ ] ROADMAP.md reset for revision round (checkboxes unchecked)
|
|
358
|
+
- [ ] Branching strategy respected (submission branch if configured)
|
|
359
|
+
- [ ] commit_docs guard respected for planning file commits
|
|
211
360
|
</success_criteria>
|
|
@@ -0,0 +1,112 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: wtfp:update
|
|
3
|
+
description: Check for updates and install newer version
|
|
4
|
+
allowed-tools:
|
|
5
|
+
- Read
|
|
6
|
+
- Bash
|
|
7
|
+
- AskUserQuestion
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
<objective>
|
|
11
|
+
Check npm registry for newer version, show what changed, offer to update.
|
|
12
|
+
</objective>
|
|
13
|
+
|
|
14
|
+
<context>
|
|
15
|
+
No arguments. Checks current installed version against npm registry.
|
|
16
|
+
</context>
|
|
17
|
+
|
|
18
|
+
<process>
|
|
19
|
+
|
|
20
|
+
## 1. Get Current Version
|
|
21
|
+
|
|
22
|
+
Try global install first:
|
|
23
|
+
```bash
|
|
24
|
+
CURRENT=$(node -e "console.log(require('$(npm root -g)/wtf-p/package.json').version)" 2>/dev/null || echo "")
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
If empty, try local:
|
|
28
|
+
```bash
|
|
29
|
+
CURRENT=$(node -e "console.log(require('./package.json').version)" 2>/dev/null || echo "unknown")
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
If still unknown, notify user:
|
|
33
|
+
```
|
|
34
|
+
Could not determine current WTF-P version.
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
## 2. Check npm Registry
|
|
38
|
+
|
|
39
|
+
```bash
|
|
40
|
+
LATEST=$(npm view wtf-p version 2>/dev/null || echo "")
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
If empty:
|
|
44
|
+
```
|
|
45
|
+
Could not reach npm registry. Check your connection.
|
|
46
|
+
```
|
|
47
|
+
Exit.
|
|
48
|
+
|
|
49
|
+
## 3. Compare Versions
|
|
50
|
+
|
|
51
|
+
If CURRENT == LATEST:
|
|
52
|
+
```
|
|
53
|
+
WTF-P is up to date (v{CURRENT}).
|
|
54
|
+
```
|
|
55
|
+
Exit.
|
|
56
|
+
|
|
57
|
+
If CURRENT < LATEST, continue to show update available.
|
|
58
|
+
|
|
59
|
+
## 4. Fetch Changelog
|
|
60
|
+
|
|
61
|
+
Attempt to get changelog information:
|
|
62
|
+
```bash
|
|
63
|
+
npm view wtf-p readme 2>/dev/null | head -80
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
Or read from installed path if available:
|
|
67
|
+
```bash
|
|
68
|
+
cat $(npm root -g)/wtf-p/CHANGELOG.md 2>/dev/null | head -100
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
Extract relevant changes between current and latest versions.
|
|
72
|
+
|
|
73
|
+
## 5. Present Update Option
|
|
74
|
+
|
|
75
|
+
Use AskUserQuestion:
|
|
76
|
+
- header: "Update Available"
|
|
77
|
+
- question: "WTF-P v{CURRENT} -> v{LATEST}\n\n{changelog excerpt showing new features/fixes}"
|
|
78
|
+
- options:
|
|
79
|
+
- "Update now"
|
|
80
|
+
- "Skip for now"
|
|
81
|
+
- "Show full changelog"
|
|
82
|
+
|
|
83
|
+
## 6. Handle Response
|
|
84
|
+
|
|
85
|
+
**"Update now":**
|
|
86
|
+
```bash
|
|
87
|
+
npm install -g wtf-p@latest
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
Confirm:
|
|
91
|
+
```
|
|
92
|
+
Updated to v{LATEST}. Restart your terminal for changes to take effect.
|
|
93
|
+
```
|
|
94
|
+
|
|
95
|
+
**"Skip for now":**
|
|
96
|
+
```
|
|
97
|
+
Update skipped. Run /wtfp:update when ready.
|
|
98
|
+
```
|
|
99
|
+
Exit.
|
|
100
|
+
|
|
101
|
+
**"Show full changelog":**
|
|
102
|
+
Display more changelog content, then ask again (Update now / Skip for now).
|
|
103
|
+
|
|
104
|
+
</process>
|
|
105
|
+
|
|
106
|
+
<success_criteria>
|
|
107
|
+
- [ ] Current and latest version compared
|
|
108
|
+
- [ ] Changelog diff shown when update available
|
|
109
|
+
- [ ] User can update or skip
|
|
110
|
+
- [ ] npm install -g runs on confirm
|
|
111
|
+
- [ ] Restart reminder shown after update
|
|
112
|
+
</success_criteria>
|