prjct-cli 0.12.1 → 0.13.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/CHANGELOG.md +43 -0
- package/CLAUDE.md +18 -6
- package/bin/serve.js +12 -30
- package/core/data/index.ts +19 -5
- package/core/data/md-base-manager.ts +203 -0
- package/core/data/md-queue-manager.ts +179 -0
- package/core/data/md-state-manager.ts +133 -0
- package/core/serializers/index.ts +20 -0
- package/core/serializers/queue-serializer.ts +210 -0
- package/core/serializers/state-serializer.ts +136 -0
- package/core/utils/file-helper.ts +12 -0
- package/package.json +1 -1
- package/packages/web/app/api/projects/[id]/stats/route.ts +6 -29
- package/packages/web/app/project/[id]/page.tsx +34 -1
- package/packages/web/app/project/[id]/stats/page.tsx +11 -5
- package/packages/web/app/settings/page.tsx +2 -221
- package/packages/web/components/AppSidebar/AppSidebar.tsx +5 -3
- package/packages/web/components/BlockersCard/BlockersCard.tsx +67 -0
- package/packages/web/components/BlockersCard/BlockersCard.types.ts +11 -0
- package/packages/web/components/BlockersCard/index.ts +2 -0
- package/packages/web/components/CommandButton/CommandButton.tsx +10 -3
- package/packages/web/lib/projects.ts +28 -27
- package/packages/web/lib/services/projects.server.ts +25 -21
- package/packages/web/lib/services/stats.server.ts +355 -57
- package/packages/web/package.json +0 -2
- package/templates/commands/decision.md +226 -0
- package/templates/commands/done.md +100 -68
- package/templates/commands/feature.md +102 -103
- package/templates/commands/idea.md +41 -38
- package/templates/commands/now.md +94 -33
- package/templates/commands/pause.md +90 -30
- package/templates/commands/ship.md +179 -74
- package/templates/commands/sync.md +324 -200
- package/packages/web/app/api/migrate/route.ts +0 -46
- package/packages/web/app/api/settings/route.ts +0 -97
- package/packages/web/app/api/v2/projects/[id]/unified/route.ts +0 -57
- package/packages/web/lib/json-loader.ts +0 -630
- package/packages/web/lib/services/migration.server.ts +0 -600
|
@@ -1,26 +1,41 @@
|
|
|
1
1
|
---
|
|
2
2
|
allowed-tools: [Read, Write, Bash, Glob, Grep]
|
|
3
|
-
description: '
|
|
3
|
+
description: 'Deep sync - analyze git, update ALL project data'
|
|
4
4
|
timestamp-rule: 'GetTimestamp() for all timestamps'
|
|
5
|
-
architecture: '
|
|
5
|
+
architecture: 'MD-first - MD files are source of truth'
|
|
6
6
|
---
|
|
7
7
|
|
|
8
|
-
# /p:sync -
|
|
8
|
+
# /p:sync - Deep Project Sync
|
|
9
9
|
|
|
10
|
-
|
|
10
|
+
**CRITICAL**: This is a DEEP analysis. Sync EVERYTHING with the real state of the repository.
|
|
11
11
|
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
12
|
+
## What Gets Analyzed & Updated
|
|
13
|
+
|
|
14
|
+
### Git Analysis (Deep)
|
|
15
|
+
- `git status` - Uncommitted changes, staged files
|
|
16
|
+
- `git log` - Recent commits to detect completed tasks
|
|
17
|
+
- `git diff` - What's changed since last commit
|
|
18
|
+
- `git branch` - Current branch, feature branches
|
|
19
|
+
|
|
20
|
+
### ALL MD Files Updated
|
|
21
|
+
- `core/now.md` - Current task (validate against git status)
|
|
22
|
+
- `core/next.md` - Task queue (remove completed ones)
|
|
23
|
+
- `progress/shipped.md` - Add tasks found in commits
|
|
24
|
+
- `planning/ideas.md` - Keep valid, remove implemented
|
|
25
|
+
- `planning/roadmap.md` - Update feature status
|
|
26
|
+
|
|
27
|
+
### Project Metadata
|
|
28
|
+
- `project.json` - ALL fields with real data
|
|
29
|
+
- `CLAUDE.md` - Quick Reference with real stats
|
|
30
|
+
- `analysis/repo-summary.md` - Full analysis
|
|
31
|
+
- `agents/*.md` - Specialized agents
|
|
17
32
|
|
|
18
33
|
## Context Variables
|
|
19
34
|
- `{projectId}`: From `.prjct/prjct.config.json`
|
|
20
35
|
- `{globalPath}`: `~/.prjct-cli/projects/{projectId}`
|
|
21
|
-
- `{
|
|
22
|
-
|
|
23
|
-
|
|
36
|
+
- `{cwd}`: Current working directory (repo path)
|
|
37
|
+
|
|
38
|
+
---
|
|
24
39
|
|
|
25
40
|
## Step 1: Read Config
|
|
26
41
|
|
|
@@ -31,290 +46,399 @@ IF file not found:
|
|
|
31
46
|
OUTPUT: "No prjct project. Run /p:init first."
|
|
32
47
|
STOP
|
|
33
48
|
|
|
34
|
-
|
|
49
|
+
---
|
|
35
50
|
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
51
|
+
## Step 2: Deep Git Analysis
|
|
52
|
+
|
|
53
|
+
### 2.1 Git Status (Uncommitted Work)
|
|
54
|
+
```bash
|
|
55
|
+
git status --porcelain
|
|
56
|
+
```
|
|
39
57
|
|
|
40
58
|
EXTRACT:
|
|
41
|
-
- {
|
|
42
|
-
- {
|
|
43
|
-
- {
|
|
59
|
+
- `{stagedFiles}`: Files staged for commit (A, M, D prefixed with space)
|
|
60
|
+
- `{modifiedFiles}`: Modified but not staged (M, D without space prefix)
|
|
61
|
+
- `{untrackedFiles}`: New files (??)
|
|
62
|
+
- `{hasUncommittedChanges}`: true/false
|
|
63
|
+
|
|
64
|
+
### 2.2 Recent Commits (Last 20)
|
|
65
|
+
```bash
|
|
66
|
+
git log --oneline -20 --pretty=format:"%h|%s|%ad" --date=short
|
|
67
|
+
```
|
|
44
68
|
|
|
45
|
-
|
|
46
|
-
|
|
69
|
+
ANALYZE each commit message for:
|
|
70
|
+
- Keywords: "feat:", "fix:", "complete", "done", "implement", "add", "finish"
|
|
71
|
+
- Task patterns: "Task: X", "#123", issue references
|
|
72
|
+
- Feature completions: "feat(auth):", "feat: user login"
|
|
47
73
|
|
|
48
|
-
|
|
49
|
-
- {sourceDir}: Main source directory (src/, lib/, app/)
|
|
50
|
-
- {testDir}: Test directory (test/, tests/, __tests__/)
|
|
51
|
-
- {configFiles}: Config files found
|
|
74
|
+
EXTRACT: `{completedTasks}` - List of tasks found in commits
|
|
52
75
|
|
|
53
|
-
###
|
|
76
|
+
### 2.3 Current Branch Analysis
|
|
77
|
+
```bash
|
|
78
|
+
git branch --show-current
|
|
79
|
+
git log main..HEAD --oneline 2>/dev/null || git log master..HEAD --oneline 2>/dev/null
|
|
80
|
+
```
|
|
54
81
|
|
|
55
|
-
|
|
82
|
+
EXTRACT:
|
|
83
|
+
- `{currentBranch}`: Current branch name
|
|
84
|
+
- `{branchCommits}`: Commits ahead of main
|
|
85
|
+
- `{isFeatureBranch}`: true if not main/master
|
|
86
|
+
|
|
87
|
+
### 2.4 Uncommitted Changes Summary
|
|
88
|
+
```bash
|
|
89
|
+
git diff --stat
|
|
90
|
+
git diff --cached --stat
|
|
91
|
+
```
|
|
56
92
|
|
|
57
|
-
|
|
58
|
-
# Repository Summary
|
|
93
|
+
EXTRACT: `{changesDescription}` - What files are being worked on
|
|
59
94
|
|
|
60
|
-
|
|
95
|
+
---
|
|
61
96
|
|
|
62
|
-
##
|
|
63
|
-
- Languages: {languages}
|
|
64
|
-
- Frameworks: {frameworks}
|
|
65
|
-
- Package Manager: {packageManager}
|
|
97
|
+
## Step 3: Gather Project Stats
|
|
66
98
|
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
-
|
|
70
|
-
- Entry: {entryPoint}
|
|
71
|
-
|
|
72
|
-
## Files
|
|
73
|
-
- Total: {fileCount}
|
|
74
|
-
- Source: {sourceCount}
|
|
75
|
-
- Tests: {testCount}
|
|
99
|
+
### Count Files
|
|
100
|
+
```bash
|
|
101
|
+
find . -type f \( -name "*.js" -o -name "*.ts" -o -name "*.jsx" -o -name "*.tsx" -o -name "*.py" -o -name "*.go" -o -name "*.rs" \) -not -path "./node_modules/*" -not -path "./.git/*" -not -path "./dist/*" -not -path "./.next/*" | wc -l
|
|
76
102
|
```
|
|
103
|
+
EXTRACT: `{fileCount}`
|
|
77
104
|
|
|
78
|
-
|
|
105
|
+
### Count Commits
|
|
106
|
+
```bash
|
|
107
|
+
git rev-list --count HEAD
|
|
108
|
+
```
|
|
109
|
+
EXTRACT: `{commitCount}`
|
|
79
110
|
|
|
80
|
-
###
|
|
81
|
-
READ
|
|
82
|
-
|
|
83
|
-
- Largest files (potential complexity)
|
|
84
|
-
- Utility/helper files
|
|
85
|
-
- Test files
|
|
86
|
-
- Config files
|
|
111
|
+
### Get Version
|
|
112
|
+
READ: `package.json` → version field
|
|
113
|
+
EXTRACT: `{version}`
|
|
87
114
|
|
|
88
|
-
###
|
|
115
|
+
### Get Project Name
|
|
116
|
+
READ: `package.json` → name field OR directory name
|
|
117
|
+
EXTRACT: `{projectName}`
|
|
89
118
|
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
119
|
+
### Detect Stack
|
|
120
|
+
GLOB for config files and analyze:
|
|
121
|
+
- `package.json` → Node.js, detect React/Vue/Express/Next.js
|
|
122
|
+
- `Cargo.toml` → Rust
|
|
123
|
+
- `go.mod` → Go
|
|
124
|
+
- `requirements.txt` / `pyproject.toml` → Python
|
|
95
125
|
|
|
96
|
-
|
|
126
|
+
EXTRACT: `{languages}`, `{frameworks}`, `{techStack}`
|
|
97
127
|
|
|
98
|
-
|
|
99
|
-
- God classes (files > 300 lines)
|
|
100
|
-
- Deep nesting (> 4 levels)
|
|
101
|
-
- Code duplication
|
|
102
|
-
- Magic numbers
|
|
103
|
-
- Mixed concerns
|
|
128
|
+
---
|
|
104
129
|
|
|
105
|
-
|
|
130
|
+
## Step 4: Sync Core MD Files
|
|
106
131
|
|
|
107
|
-
|
|
132
|
+
### 4.1 Update now.md (Current Task)
|
|
108
133
|
|
|
109
|
-
|
|
110
|
-
# Code Patterns - {project}
|
|
134
|
+
READ: `{globalPath}/core/now.md`
|
|
111
135
|
|
|
112
|
-
|
|
136
|
+
**Logic:**
|
|
137
|
+
- IF `{hasUncommittedChanges}` AND now.md is empty:
|
|
138
|
+
- INFER task from modified files (e.g., "Working on: auth module")
|
|
139
|
+
- UPDATE now.md with inferred task
|
|
113
140
|
|
|
114
|
-
|
|
115
|
-
-
|
|
141
|
+
- IF now.md has task AND task appears in recent commits:
|
|
142
|
+
- Task is DONE → Clear now.md, add to shipped.md
|
|
116
143
|
|
|
117
|
-
|
|
118
|
-
-
|
|
119
|
-
- Classes: {convention}
|
|
120
|
-
- Files: {convention}
|
|
121
|
-
- Async: {pattern}
|
|
144
|
+
- IF `{isFeatureBranch}`:
|
|
145
|
+
- Suggest task based on branch name (e.g., `feature/auth` → "Implement authentication")
|
|
122
146
|
|
|
123
|
-
|
|
124
|
-
1. **{issue}**: {file:line} - Fix: {action}
|
|
147
|
+
WRITE: `{globalPath}/core/now.md`
|
|
125
148
|
|
|
126
|
-
|
|
127
|
-
1. {action}
|
|
128
|
-
```
|
|
149
|
+
### 4.2 Update next.md (Task Queue)
|
|
129
150
|
|
|
130
|
-
|
|
151
|
+
READ: `{globalPath}/core/next.md`
|
|
131
152
|
|
|
132
|
-
|
|
153
|
+
**Logic:**
|
|
154
|
+
- Parse existing tasks (lines starting with `- `)
|
|
155
|
+
- For each task, check if it appears in `{completedTasks}` from commits
|
|
156
|
+
- REMOVE completed tasks from queue
|
|
157
|
+
- Keep remaining tasks
|
|
133
158
|
|
|
134
|
-
|
|
159
|
+
WRITE: `{globalPath}/core/next.md`
|
|
135
160
|
|
|
136
|
-
|
|
137
|
-
IF React/Vue/Angular detected:
|
|
138
|
-
GENERATE: `agents/fe.md` (Frontend Specialist)
|
|
139
|
-
IF Express/Fastify/Nest detected:
|
|
140
|
-
GENERATE: `agents/be.md` (Backend Specialist)
|
|
161
|
+
### 4.3 Update shipped.md (Completed Work)
|
|
141
162
|
|
|
142
|
-
|
|
143
|
-
GENERATE: `agents/py.md` (Python Specialist)
|
|
163
|
+
READ: `{globalPath}/progress/shipped.md`
|
|
144
164
|
|
|
145
|
-
|
|
146
|
-
|
|
165
|
+
**Logic:**
|
|
166
|
+
- For each task in `{completedTasks}` from git commits:
|
|
167
|
+
- Check if NOT already in shipped.md
|
|
168
|
+
- ADD new entries with commit date
|
|
147
169
|
|
|
148
|
-
|
|
149
|
-
|
|
170
|
+
FORMAT for new entries:
|
|
171
|
+
```markdown
|
|
172
|
+
- **{taskName}** - {date}
|
|
173
|
+
- Commit: {commitHash}
|
|
174
|
+
```
|
|
150
175
|
|
|
151
|
-
|
|
176
|
+
WRITE: `{globalPath}/progress/shipped.md`
|
|
152
177
|
|
|
153
|
-
|
|
178
|
+
### 4.4 Update ideas.md
|
|
154
179
|
|
|
155
|
-
|
|
156
|
-
# {Name} Agent
|
|
180
|
+
READ: `{globalPath}/planning/ideas.md`
|
|
157
181
|
|
|
158
|
-
|
|
159
|
-
|
|
182
|
+
**Logic:**
|
|
183
|
+
- Parse existing ideas
|
|
184
|
+
- Check if any idea was implemented (appears in commits)
|
|
185
|
+
- REMOVE implemented ideas OR mark as done
|
|
160
186
|
|
|
161
|
-
|
|
162
|
-
- {skill1}
|
|
163
|
-
- {skill2}
|
|
187
|
+
WRITE: `{globalPath}/planning/ideas.md`
|
|
164
188
|
|
|
165
|
-
|
|
166
|
-
{From patterns.md}
|
|
189
|
+
### 4.5 Update roadmap.md
|
|
167
190
|
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
191
|
+
READ: `{globalPath}/planning/roadmap.md`
|
|
192
|
+
|
|
193
|
+
**Logic:**
|
|
194
|
+
- Parse features and their status
|
|
195
|
+
- For each feature, check commits for implementation
|
|
196
|
+
- UPDATE status: planning → in-progress → completed
|
|
197
|
+
- Add completion dates where applicable
|
|
198
|
+
|
|
199
|
+
WRITE: `{globalPath}/planning/roadmap.md`
|
|
171
200
|
|
|
172
|
-
|
|
201
|
+
---
|
|
202
|
+
|
|
203
|
+
## Step 5: Update CLAUDE.md
|
|
173
204
|
|
|
174
205
|
READ: `{globalPath}/CLAUDE.md`
|
|
175
206
|
|
|
176
|
-
|
|
177
|
-
### Add Patterns Summary
|
|
207
|
+
### Quick Reference Table (MUST UPDATE)
|
|
178
208
|
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
209
|
+
```markdown
|
|
210
|
+
## Quick Reference
|
|
211
|
+
|
|
212
|
+
| Field | Value |
|
|
213
|
+
|-------|-------|
|
|
214
|
+
| **Name** | {projectName} |
|
|
215
|
+
| **Version** | {version} |
|
|
216
|
+
| **Stack** | {stack} |
|
|
217
|
+
| **Files** | {fileCount} |
|
|
218
|
+
| **Commits** | {commitCount} |
|
|
219
|
+
| **Branch** | {currentBranch} |
|
|
220
|
+
| **Path** | {cwd} |
|
|
221
|
+
| **Last Sync** | {GetTimestamp()} |
|
|
222
|
+
```
|
|
182
223
|
|
|
183
|
-
|
|
184
|
-
- {key conventions}
|
|
185
|
-
- {design patterns}
|
|
224
|
+
### Git Status Section
|
|
186
225
|
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
226
|
+
```markdown
|
|
227
|
+
## Current Git Status
|
|
228
|
+
|
|
229
|
+
**Branch**: `{currentBranch}`
|
|
230
|
+
**Uncommitted Changes**: {hasUncommittedChanges ? "Yes" : "Clean"}
|
|
190
231
|
|
|
191
|
-
|
|
232
|
+
{IF hasUncommittedChanges}
|
|
233
|
+
### Modified Files
|
|
234
|
+
{list of modified files}
|
|
192
235
|
|
|
193
|
-
|
|
236
|
+
### What's Being Worked On
|
|
237
|
+
{changesDescription}
|
|
238
|
+
{ENDIF}
|
|
239
|
+
```
|
|
194
240
|
|
|
195
|
-
|
|
241
|
+
WRITE: `{globalPath}/CLAUDE.md`
|
|
242
|
+
|
|
243
|
+
---
|
|
196
244
|
|
|
197
|
-
|
|
198
|
-
- Try package.json → `name` field
|
|
199
|
-
- Try Cargo.toml → `[package] name`
|
|
200
|
-
- Try pyproject.toml → `[project] name`
|
|
201
|
-
- Fallback to directory name (last segment of current path)
|
|
245
|
+
## Step 6: Update project.json
|
|
202
246
|
|
|
203
|
-
|
|
247
|
+
READ existing: `{globalPath}/project.json` (preserve createdAt)
|
|
248
|
+
|
|
249
|
+
WRITE: `{globalPath}/project.json`
|
|
204
250
|
|
|
205
251
|
```json
|
|
206
252
|
{
|
|
207
253
|
"projectId": "{projectId}",
|
|
208
254
|
"repoPath": "{cwd}",
|
|
209
255
|
"name": "{projectName}",
|
|
210
|
-
"
|
|
256
|
+
"version": "{version}",
|
|
257
|
+
"techStack": {techStack},
|
|
258
|
+
"fileCount": {fileCount},
|
|
259
|
+
"commitCount": {commitCount},
|
|
260
|
+
"stack": "{stack}",
|
|
261
|
+
"currentBranch": "{currentBranch}",
|
|
262
|
+
"hasUncommittedChanges": {hasUncommittedChanges},
|
|
211
263
|
"createdAt": "{existingCreatedAt || GetTimestamp()}",
|
|
212
264
|
"lastSync": "{GetTimestamp()}"
|
|
213
265
|
}
|
|
214
266
|
```
|
|
215
267
|
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
268
|
+
---
|
|
269
|
+
|
|
270
|
+
## Step 7: Generate Analysis Files
|
|
271
|
+
|
|
272
|
+
### repo-summary.md
|
|
273
|
+
WRITE: `{globalPath}/analysis/repo-summary.md`
|
|
274
|
+
|
|
275
|
+
```markdown
|
|
276
|
+
# Repository Summary
|
|
277
|
+
|
|
278
|
+
> Generated: {GetTimestamp()}
|
|
279
|
+
|
|
280
|
+
## Project
|
|
281
|
+
- **Name**: {projectName}
|
|
282
|
+
- **Version**: {version}
|
|
283
|
+
- **Path**: {cwd}
|
|
284
|
+
|
|
285
|
+
## Stack
|
|
286
|
+
- **Languages**: {languages}
|
|
287
|
+
- **Frameworks**: {frameworks}
|
|
288
|
+
- **Package Manager**: {packageManager}
|
|
289
|
+
|
|
290
|
+
## Stats
|
|
291
|
+
- **Files**: {fileCount}
|
|
292
|
+
- **Commits**: {commitCount}
|
|
293
|
+
- **Contributors**: {contributorCount}
|
|
223
294
|
|
|
224
|
-
|
|
295
|
+
## Structure
|
|
296
|
+
- **Source**: {sourceDir}
|
|
297
|
+
- **Tests**: {testDir}
|
|
298
|
+
- **Config**: {configFiles}
|
|
299
|
+
|
|
300
|
+
## Git Status
|
|
301
|
+
- **Branch**: {currentBranch}
|
|
302
|
+
- **Uncommitted**: {hasUncommittedChanges}
|
|
303
|
+
- **Recent Activity**: {recentCommitCount} commits this week
|
|
304
|
+
```
|
|
225
305
|
|
|
226
|
-
|
|
227
|
-
WRITE: `{globalPath}/
|
|
306
|
+
### patterns.md (Code patterns detected)
|
|
307
|
+
Analyze code and WRITE: `{globalPath}/analysis/patterns.md`
|
|
228
308
|
|
|
229
|
-
|
|
309
|
+
---
|
|
230
310
|
|
|
231
|
-
|
|
311
|
+
## Step 8: Generate/Update Agents
|
|
232
312
|
|
|
233
|
-
|
|
313
|
+
Based on detected stack, generate specialized agents in `{globalPath}/agents/`:
|
|
234
314
|
|
|
235
|
-
|
|
236
|
-
-
|
|
237
|
-
-
|
|
238
|
-
-
|
|
239
|
-
- views/roadmap.md reflects data/roadmap.json
|
|
240
|
-
- views/shipped.md reflects data/shipped.json
|
|
315
|
+
- `coordinator.md` - Always generated
|
|
316
|
+
- `fe.md` - If React/Vue/Angular detected
|
|
317
|
+
- `be.md` - If Express/Fastify/Django detected
|
|
318
|
+
- `qa.md` - If tests detected
|
|
241
319
|
|
|
242
|
-
|
|
320
|
+
---
|
|
243
321
|
|
|
244
|
-
|
|
322
|
+
## Step 9: Log to Memory
|
|
323
|
+
|
|
324
|
+
APPEND to: `{globalPath}/memory/context.jsonl`
|
|
245
325
|
|
|
246
|
-
Single line (JSONL):
|
|
247
326
|
```json
|
|
248
|
-
{"
|
|
327
|
+
{"ts":"{GetTimestamp()}","action":"sync","branch":"{currentBranch}","uncommitted":{hasUncommittedChanges},"tasksCompleted":{completedTaskCount},"fileCount":{fileCount},"commitCount":{commitCount}}
|
|
249
328
|
```
|
|
250
329
|
|
|
330
|
+
---
|
|
331
|
+
|
|
251
332
|
## Output
|
|
252
333
|
|
|
253
|
-
SUCCESS:
|
|
254
334
|
```
|
|
255
|
-
🔄
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
├──
|
|
259
|
-
├──
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
├──
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
├──
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
335
|
+
🔄 Deep Sync Complete
|
|
336
|
+
|
|
337
|
+
📊 Project Stats
|
|
338
|
+
├── Files: {fileCount}
|
|
339
|
+
├── Commits: {commitCount}
|
|
340
|
+
├── Version: {version}
|
|
341
|
+
└── Stack: {stack}
|
|
342
|
+
|
|
343
|
+
🌿 Git Status
|
|
344
|
+
├── Branch: {currentBranch}
|
|
345
|
+
├── Uncommitted: {hasUncommittedChanges ? "Yes - " + modifiedCount + " files" : "Clean"}
|
|
346
|
+
└── Recent: {recentCommitCount} commits this week
|
|
347
|
+
|
|
348
|
+
✅ Tasks Synced
|
|
349
|
+
├── Completed (from commits): {completedTaskCount}
|
|
350
|
+
├── Removed from queue: {removedFromQueue}
|
|
351
|
+
└── Added to shipped: {addedToShipped}
|
|
352
|
+
|
|
353
|
+
📁 Files Updated
|
|
354
|
+
├── core/now.md
|
|
355
|
+
├── core/next.md
|
|
356
|
+
├── progress/shipped.md
|
|
357
|
+
├── planning/ideas.md
|
|
358
|
+
├── planning/roadmap.md
|
|
359
|
+
├── project.json
|
|
360
|
+
├── CLAUDE.md
|
|
361
|
+
└── analysis/*.md
|
|
362
|
+
|
|
363
|
+
{IF hasUncommittedChanges}
|
|
364
|
+
⚠️ You have uncommitted changes:
|
|
365
|
+
{changesDescription}
|
|
366
|
+
|
|
367
|
+
Next: Commit your work or continue coding
|
|
368
|
+
{ELSE}
|
|
369
|
+
✨ Repository is clean!
|
|
370
|
+
|
|
371
|
+
Next: /p:now to start a new task
|
|
372
|
+
{ENDIF}
|
|
276
373
|
```
|
|
277
374
|
|
|
375
|
+
---
|
|
376
|
+
|
|
278
377
|
## Error Handling
|
|
279
378
|
|
|
280
379
|
| Error | Response | Action |
|
|
281
380
|
|-------|----------|--------|
|
|
282
381
|
| No config | "No prjct project" | STOP |
|
|
283
|
-
|
|
|
284
|
-
|
|
|
382
|
+
| Not a git repo | "Not a git repository" | WARN, continue without git |
|
|
383
|
+
| No commits | Use defaults | CONTINUE |
|
|
384
|
+
| File read error | Skip that file | CONTINUE |
|
|
385
|
+
|
|
386
|
+
---
|
|
285
387
|
|
|
286
388
|
## Examples
|
|
287
389
|
|
|
288
|
-
### Example
|
|
390
|
+
### Example: Clean repo, tasks completed
|
|
289
391
|
```
|
|
290
|
-
🔄
|
|
392
|
+
🔄 Deep Sync Complete
|
|
393
|
+
|
|
394
|
+
📊 Project Stats
|
|
395
|
+
├── Files: 156
|
|
396
|
+
├── Commits: 234
|
|
397
|
+
├── Version: 1.2.0
|
|
398
|
+
└── Stack: TypeScript + React + Node.js
|
|
291
399
|
|
|
292
|
-
|
|
293
|
-
├──
|
|
294
|
-
├──
|
|
295
|
-
└──
|
|
400
|
+
🌿 Git Status
|
|
401
|
+
├── Branch: main
|
|
402
|
+
├── Uncommitted: Clean
|
|
403
|
+
└── Recent: 8 commits this week
|
|
296
404
|
|
|
297
|
-
|
|
298
|
-
├──
|
|
299
|
-
├──
|
|
300
|
-
└──
|
|
405
|
+
✅ Tasks Synced
|
|
406
|
+
├── Completed (from commits): 3
|
|
407
|
+
├── Removed from queue: 2
|
|
408
|
+
└── Added to shipped: 3
|
|
301
409
|
|
|
302
|
-
|
|
410
|
+
📁 Files Updated
|
|
411
|
+
├── core/now.md (cleared - task completed)
|
|
412
|
+
├── core/next.md (2 tasks removed)
|
|
413
|
+
├── progress/shipped.md (+3 entries)
|
|
414
|
+
└── All metadata updated
|
|
415
|
+
|
|
416
|
+
✨ Repository is clean!
|
|
417
|
+
|
|
418
|
+
Next: /p:now to start a new task
|
|
303
419
|
```
|
|
304
420
|
|
|
305
|
-
### Example
|
|
421
|
+
### Example: Work in progress
|
|
306
422
|
```
|
|
307
|
-
🔄
|
|
423
|
+
🔄 Deep Sync Complete
|
|
424
|
+
|
|
425
|
+
📊 Project Stats
|
|
426
|
+
├── Files: 156
|
|
427
|
+
├── Commits: 234
|
|
428
|
+
├── Version: 1.2.0
|
|
429
|
+
└── Stack: TypeScript + React + Node.js
|
|
430
|
+
|
|
431
|
+
🌿 Git Status
|
|
432
|
+
├── Branch: feature/auth
|
|
433
|
+
├── Uncommitted: Yes - 5 files
|
|
434
|
+
└── Recent: 3 commits today
|
|
308
435
|
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
436
|
+
⚠️ You have uncommitted changes:
|
|
437
|
+
M src/auth/login.tsx
|
|
438
|
+
M src/auth/signup.tsx
|
|
439
|
+
A src/auth/utils.ts
|
|
313
440
|
|
|
314
|
-
|
|
315
|
-
├── Agents: 3 (coordinator, py, qa)
|
|
316
|
-
├── Patterns: 5 detected
|
|
317
|
-
└── Anti-patterns: 1 flagged
|
|
441
|
+
Working on: Authentication module
|
|
318
442
|
|
|
319
|
-
Next:
|
|
443
|
+
Next: Commit your work or continue coding
|
|
320
444
|
```
|