cc-sidebar 0.1.5 → 0.1.7
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 +2 -2
- package/package.json +3 -2
- package/scripts/statusline.sh +61 -0
- package/skills/{brain-dump → clarify}/SKILL.md +144 -99
- package/src/components/RawSidebar.tsx +2 -41
- package/src/persistence/store.ts +1 -1
package/README.md
CHANGED
|
@@ -128,7 +128,7 @@ cc-sidebar includes skills that integrate with Claude Code:
|
|
|
128
128
|
|
|
129
129
|
| Skill | Trigger | What it does |
|
|
130
130
|
|-------|---------|--------------|
|
|
131
|
-
| `/
|
|
131
|
+
| `/clarify` | `/clarify` | Interview to clarify tasks, creates plan + todos (works for new or existing tasks) |
|
|
132
132
|
| `/prioritize` | `/prioritize` | Re-prioritize all sidebar tasks as a staff engineer |
|
|
133
133
|
| `sidebar-awareness` | (always on) | Gives Claude context about sidebar data files |
|
|
134
134
|
|
|
@@ -142,7 +142,7 @@ cp -r ~/.bun/install/global/node_modules/cc-sidebar/skills/* ~/.claude/skills/
|
|
|
142
142
|
Or install individually:
|
|
143
143
|
|
|
144
144
|
```bash
|
|
145
|
-
cp -r ~/.bun/install/global/node_modules/cc-sidebar/skills/
|
|
145
|
+
cp -r ~/.bun/install/global/node_modules/cc-sidebar/skills/clarify ~/.claude/skills/
|
|
146
146
|
cp -r ~/.bun/install/global/node_modules/cc-sidebar/skills/prioritize ~/.claude/skills/
|
|
147
147
|
```
|
|
148
148
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "cc-sidebar",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.7",
|
|
4
4
|
"description": "Visual sidebar for managing todos, tasks, and context alongside Claude Code",
|
|
5
5
|
"author": "Tyler Nishida",
|
|
6
6
|
"license": "MIT",
|
|
@@ -24,7 +24,8 @@
|
|
|
24
24
|
"files": [
|
|
25
25
|
"src",
|
|
26
26
|
"skills",
|
|
27
|
-
"commands"
|
|
27
|
+
"commands",
|
|
28
|
+
"scripts"
|
|
28
29
|
],
|
|
29
30
|
"scripts": {
|
|
30
31
|
"start": "bun run src/cli.ts",
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
#!/bin/bash
|
|
2
|
+
# Claude Code statusline script for claude-sidebar
|
|
3
|
+
# Receives JSON from Claude Code via stdin, extracts key metrics, writes to shared file
|
|
4
|
+
#
|
|
5
|
+
# Install: Add to ~/.claude/settings.json:
|
|
6
|
+
# { "statusline": { "script": "/path/to/claude-sidebar/scripts/statusline.sh" } }
|
|
7
|
+
|
|
8
|
+
set -e
|
|
9
|
+
|
|
10
|
+
# Read JSON from stdin
|
|
11
|
+
input=$(cat)
|
|
12
|
+
|
|
13
|
+
# Extract context window data
|
|
14
|
+
CTX_SIZE=$(echo "$input" | jq -r '.context_window.context_window_size // 200000')
|
|
15
|
+
USAGE=$(echo "$input" | jq -r '.context_window.current_usage // {}')
|
|
16
|
+
INPUT_TOKENS=$(echo "$USAGE" | jq -r '(.input_tokens // 0) + (.cache_creation_input_tokens // 0) + (.cache_read_input_tokens // 0)')
|
|
17
|
+
OUTPUT_TOKENS=$(echo "$input" | jq -r '.context_window.current_usage.output_tokens // 0')
|
|
18
|
+
|
|
19
|
+
# Calculate context percentage (input + output tokens)
|
|
20
|
+
TOTAL_TOKENS=$((INPUT_TOKENS + OUTPUT_TOKENS))
|
|
21
|
+
if [ "$CTX_SIZE" -gt 0 ]; then
|
|
22
|
+
CTX_PERCENT=$((TOTAL_TOKENS * 100 / CTX_SIZE))
|
|
23
|
+
else
|
|
24
|
+
CTX_PERCENT=0
|
|
25
|
+
fi
|
|
26
|
+
|
|
27
|
+
# Extract cost and duration
|
|
28
|
+
COST=$(echo "$input" | jq -r '.cost.total_cost_usd // 0')
|
|
29
|
+
DURATION_MS=$(echo "$input" | jq -r '.cost.total_duration_ms // 0')
|
|
30
|
+
DURATION_MIN=$((DURATION_MS / 60000))
|
|
31
|
+
|
|
32
|
+
# Extract model
|
|
33
|
+
MODEL=$(echo "$input" | jq -r '.model.display_name // "Unknown"')
|
|
34
|
+
|
|
35
|
+
# Get project directory and git info
|
|
36
|
+
PROJECT_DIR=$(echo "$input" | jq -r '.workspace.project_dir // ""')
|
|
37
|
+
BRANCH=""
|
|
38
|
+
REPO=""
|
|
39
|
+
if [ -n "$PROJECT_DIR" ] && [ -d "$PROJECT_DIR" ]; then
|
|
40
|
+
cd "$PROJECT_DIR" 2>/dev/null || true
|
|
41
|
+
BRANCH=$(git branch --show-current 2>/dev/null || echo "")
|
|
42
|
+
REPO=$(basename "$PROJECT_DIR")
|
|
43
|
+
fi
|
|
44
|
+
|
|
45
|
+
# Ensure directory exists
|
|
46
|
+
mkdir -p ~/.claude-sidebar
|
|
47
|
+
|
|
48
|
+
# Write processed data
|
|
49
|
+
cat > ~/.claude-sidebar/statusline.json << EOF
|
|
50
|
+
{
|
|
51
|
+
"contextPercent": $CTX_PERCENT,
|
|
52
|
+
"contextTokens": $TOTAL_TOKENS,
|
|
53
|
+
"contextSize": $CTX_SIZE,
|
|
54
|
+
"costUsd": $COST,
|
|
55
|
+
"durationMin": $DURATION_MIN,
|
|
56
|
+
"model": "$MODEL",
|
|
57
|
+
"branch": "$BRANCH",
|
|
58
|
+
"repo": "$REPO",
|
|
59
|
+
"updatedAt": "$(date -u +%Y-%m-%dT%H:%M:%SZ)"
|
|
60
|
+
}
|
|
61
|
+
EOF
|
|
@@ -1,36 +1,43 @@
|
|
|
1
1
|
---
|
|
2
|
-
name:
|
|
2
|
+
name: clarify
|
|
3
3
|
description: |
|
|
4
|
-
|
|
4
|
+
Clarify tasks through conversation - works for new ideas or existing sidebar tasks.
|
|
5
5
|
|
|
6
|
-
Use when: (1) You have
|
|
7
|
-
(2) You want to clarify a single task through conversation
|
|
8
|
-
(3)
|
|
6
|
+
Use when: (1) You have thoughts/ideas that need clarification before becoming actionable,
|
|
7
|
+
(2) You want to clarify a single task through conversation,
|
|
8
|
+
(3) The sidebar sends a task for clarification (via `c` key).
|
|
9
9
|
|
|
10
|
-
Triggers: "/
|
|
10
|
+
Triggers: "/clarify", "clarify this", "let me explain this task".
|
|
11
11
|
|
|
12
12
|
Requires: Claude Code sidebar for todo integration, Atomic Plans for plan output.
|
|
13
13
|
---
|
|
14
14
|
|
|
15
|
-
#
|
|
15
|
+
# Clarify Skill
|
|
16
16
|
|
|
17
|
-
|
|
17
|
+
Clarify tasks through structured conversation. Works for both new ideas (creates todos) and existing sidebar tasks (updates them).
|
|
18
18
|
|
|
19
19
|
## Invocation
|
|
20
20
|
|
|
21
|
-
- `/
|
|
22
|
-
- `/
|
|
21
|
+
- `/clarify` - Start interviewing from scratch
|
|
22
|
+
- `/clarify [text]` - Clarify provided text (single task or many)
|
|
23
|
+
- `/clarify --task-id <id> [task content]` - Clarify existing sidebar task (sent by sidebar `c` key)
|
|
23
24
|
|
|
24
25
|
## Process
|
|
25
26
|
|
|
26
27
|
Follow these steps in order:
|
|
27
28
|
|
|
28
|
-
### 1.
|
|
29
|
+
### 1. Detect Mode
|
|
30
|
+
|
|
31
|
+
Check if invoked with `--task-id`:
|
|
32
|
+
- **With task ID**: Updating an existing sidebar task
|
|
33
|
+
- **Without task ID**: Creating new todo(s) from scratch
|
|
34
|
+
|
|
35
|
+
### 2. Locate Configuration
|
|
29
36
|
|
|
30
37
|
Check the project's CLAUDE.md for the Atomic Plans folder path. Look for a section like:
|
|
31
38
|
|
|
32
39
|
```markdown
|
|
33
|
-
##
|
|
40
|
+
## Clarify Configuration
|
|
34
41
|
Plan folder: /path/to/plans
|
|
35
42
|
```
|
|
36
43
|
|
|
@@ -46,13 +53,13 @@ Or check if Atomic Plans is already configured:
|
|
|
46
53
|
2. After they provide a path, ask: "Would you like me to add this to CLAUDE.md so I remember next time?"
|
|
47
54
|
3. If yes, append the configuration to CLAUDE.md
|
|
48
55
|
|
|
49
|
-
###
|
|
56
|
+
### 3. Interview Phase
|
|
50
57
|
|
|
51
|
-
The goal is to
|
|
58
|
+
The goal is to fully understand the task(s) through conversation.
|
|
52
59
|
|
|
53
|
-
**IMPORTANT: Never short-circuit the process.** Whether the user provides one clear task or a chaotic mess of ideas, always interview to clarify. A "single clear task" still benefits from clarification - edge cases, implementation approach, constraints, etc.
|
|
60
|
+
**IMPORTANT: Never short-circuit the process.** Whether the user provides one clear task or a chaotic mess of ideas, always interview to clarify. A "single clear task" still benefits from clarification - edge cases, implementation approach, constraints, etc.
|
|
54
61
|
|
|
55
|
-
**If the user provided text with the command** (`/
|
|
62
|
+
**If the user provided text with the command** (`/clarify [text]`):
|
|
56
63
|
- Skip the opening question - they already told you what's on their mind
|
|
57
64
|
- Go straight to AskUserQuestion to clarify specifics:
|
|
58
65
|
- Ambiguous parts that need clarification
|
|
@@ -61,29 +68,89 @@ The goal is to extract actionable, project-relevant tasks through conversation.
|
|
|
61
68
|
- Missing context: priorities, dependencies
|
|
62
69
|
- Anything else you need to fully understand the task(s)
|
|
63
70
|
|
|
64
|
-
**If no text was provided** (`/
|
|
71
|
+
**If no text was provided** (`/clarify` alone):
|
|
65
72
|
- Start with a plain text invitation (NOT AskUserQuestion):
|
|
66
73
|
|
|
67
74
|
"What's on your mind? Tell me everything - tasks, concerns, ideas,
|
|
68
|
-
whatever's floating around. I'll help organize it."
|
|
75
|
+
whatever's floating around. I'll help clarify and organize it."
|
|
69
76
|
|
|
70
77
|
- Let the user ramble freely in their response
|
|
71
78
|
- THEN use AskUserQuestion to clarify specifics about what they said
|
|
72
79
|
|
|
80
|
+
**Interview guidelines:**
|
|
81
|
+
- Don't ask obvious questions - if something is clear from the task description, skip it
|
|
82
|
+
- Be thorough - keep interviewing until you have complete clarity
|
|
83
|
+
- Always include "Anything else I should know?" as a final question
|
|
84
|
+
|
|
73
85
|
**Key questions to consider** (use AskUserQuestion for these):
|
|
74
86
|
- What's the most important thing here?
|
|
75
87
|
- Are there dependencies between these tasks?
|
|
76
88
|
- What constraints should I know about?
|
|
77
89
|
- Is there anything blocking progress on any of these?
|
|
78
|
-
- Anything else I should know?
|
|
79
90
|
|
|
80
91
|
**Scope filtering:**
|
|
81
92
|
If the user mentions things unrelated to the current project (personal tasks, other projects), ask:
|
|
82
93
|
"Some of this seems unrelated to [current project]. Should I include those tasks anyway, or focus only on [project]-related work?"
|
|
83
94
|
|
|
84
|
-
###
|
|
95
|
+
### 4. Create Plan
|
|
96
|
+
|
|
97
|
+
Create a new plan in the Atomic Plans folder with:
|
|
98
|
+
|
|
99
|
+
**Filename:** `NNN-clarify-[topic].md` where NNN is the next number in sequence.
|
|
100
|
+
|
|
101
|
+
**Content:**
|
|
102
|
+
```markdown
|
|
103
|
+
---
|
|
104
|
+
plan: NNN
|
|
105
|
+
title: [Topic]
|
|
106
|
+
state: active
|
|
107
|
+
created: YYYY-MM-DD
|
|
108
|
+
updated: YYYY-MM-DD
|
|
109
|
+
---
|
|
110
|
+
|
|
111
|
+
# [Topic]
|
|
112
|
+
|
|
113
|
+
## Intent
|
|
114
|
+
[Summary of what the user wants to accomplish]
|
|
115
|
+
|
|
116
|
+
## Specs
|
|
117
|
+
[Detailed specifications gathered during interview]
|
|
85
118
|
|
|
86
|
-
|
|
119
|
+
## Context
|
|
120
|
+
[Key decisions, constraints, and context gathered during interview]
|
|
121
|
+
|
|
122
|
+
## Next
|
|
123
|
+
- [ ] Execute the task(s)
|
|
124
|
+
```
|
|
125
|
+
|
|
126
|
+
### 5. Update or Create Todos
|
|
127
|
+
|
|
128
|
+
**If updating existing task** (has `--task-id`):
|
|
129
|
+
|
|
130
|
+
Update the existing task in the sidebar:
|
|
131
|
+
|
|
132
|
+
```bash
|
|
133
|
+
node << 'SCRIPT'
|
|
134
|
+
const fs = require('fs');
|
|
135
|
+
const crypto = require('crypto');
|
|
136
|
+
const path = require('path');
|
|
137
|
+
const sidebarDir = path.join(require('os').homedir(), '.claude-sidebar');
|
|
138
|
+
const hash = crypto.createHash('sha256').update(process.cwd()).digest('hex').slice(0, 12);
|
|
139
|
+
const tasksPath = path.join(sidebarDir, 'projects', hash, 'tasks.json');
|
|
140
|
+
let tasks = JSON.parse(fs.readFileSync(tasksPath, 'utf-8'));
|
|
141
|
+
const task = tasks.find(t => t.id === 'TASK_ID_HERE'); // REPLACE with actual task ID
|
|
142
|
+
if (task) {
|
|
143
|
+
task.clarified = true;
|
|
144
|
+
task.planPath = 'PLAN_FILENAME.md'; // REPLACE with actual plan filename
|
|
145
|
+
fs.writeFileSync(tasksPath, JSON.stringify(tasks, null, 2));
|
|
146
|
+
console.log('Task clarified and linked to plan');
|
|
147
|
+
}
|
|
148
|
+
SCRIPT
|
|
149
|
+
```
|
|
150
|
+
|
|
151
|
+
**If creating new todos** (no `--task-id`):
|
|
152
|
+
|
|
153
|
+
Extract discrete, actionable tasks from the interview. Each todo should be:
|
|
87
154
|
- **Specific**: Clear what needs to be done
|
|
88
155
|
- **Actionable**: Can be worked on independently
|
|
89
156
|
- **Scoped**: Relevant to the current project (unless user said otherwise)
|
|
@@ -95,20 +162,9 @@ Assign each task a numeric priority (1 = most important). Consider:
|
|
|
95
162
|
- **Impact**: High-value features over nice-to-haves
|
|
96
163
|
- **Effort**: Quick wins can be prioritized to build momentum
|
|
97
164
|
|
|
98
|
-
Mark the top 3 most important tasks as "recommended" (shown with
|
|
99
|
-
|
|
100
|
-
### 4. Write Todos to Sidebar
|
|
165
|
+
Mark the top 3 most important tasks as "recommended" (shown with star in sidebar).
|
|
101
166
|
|
|
102
|
-
Write
|
|
103
|
-
|
|
104
|
-
**IMPORTANT:** Tasks are stored per-project using a hash of the working directory:
|
|
105
|
-
```
|
|
106
|
-
~/.claude-sidebar/projects/<hash>/tasks.json
|
|
107
|
-
```
|
|
108
|
-
|
|
109
|
-
**IMPORTANT: Read first, then append.** Do not clobber existing todos.
|
|
110
|
-
|
|
111
|
-
Use this exact script to write todos (it handles the project hash automatically):
|
|
167
|
+
Write todos to the **project-specific** tasks file:
|
|
112
168
|
|
|
113
169
|
```bash
|
|
114
170
|
node << 'SCRIPT'
|
|
@@ -129,7 +185,7 @@ let existing = [];
|
|
|
129
185
|
try { existing = JSON.parse(fs.readFileSync(tasksPath, 'utf-8')); } catch {}
|
|
130
186
|
|
|
131
187
|
// Plan filename (just the filename, not full path)
|
|
132
|
-
const planPath = "NNN-
|
|
188
|
+
const planPath = "NNN-clarify-topic.md"; // REPLACE with actual plan filename
|
|
133
189
|
|
|
134
190
|
// New todos - REPLACE THIS ARRAY with extracted tasks
|
|
135
191
|
// Each task needs: content, priority (1=highest), recommended (true for top 3)
|
|
@@ -142,7 +198,7 @@ const newTodos = [
|
|
|
142
198
|
id: crypto.randomUUID(),
|
|
143
199
|
content: task.content,
|
|
144
200
|
createdAt: new Date().toISOString(),
|
|
145
|
-
clarified: true, //
|
|
201
|
+
clarified: true, // Clarify IS the clarification process
|
|
146
202
|
priority: task.priority, // Numeric priority (1 = most important)
|
|
147
203
|
recommended: task.recommended, // Top 3 get star indicator
|
|
148
204
|
planPath: planPath // Links task to the plan file
|
|
@@ -155,101 +211,90 @@ console.log('Added ' + newTodos.length + ' todos to sidebar');
|
|
|
155
211
|
SCRIPT
|
|
156
212
|
```
|
|
157
213
|
|
|
158
|
-
###
|
|
159
|
-
|
|
160
|
-
Create a new plan in the Atomic Plans folder with:
|
|
161
|
-
|
|
162
|
-
**Filename:** `NNN-brain-dump-[topic].md` where NNN is the next number in sequence.
|
|
163
|
-
|
|
164
|
-
**Content:**
|
|
165
|
-
```markdown
|
|
166
|
-
---
|
|
167
|
-
plan: NNN
|
|
168
|
-
title: Brain Dump - [Topic]
|
|
169
|
-
state: active
|
|
170
|
-
created: YYYY-MM-DD
|
|
171
|
-
updated: YYYY-MM-DD
|
|
172
|
-
---
|
|
173
|
-
|
|
174
|
-
# Brain Dump - [Topic]
|
|
214
|
+
### 6. Present and Prompt
|
|
175
215
|
|
|
176
|
-
|
|
177
|
-
[Summary of what the user wants to accomplish]
|
|
216
|
+
After creating/updating todos and plan:
|
|
178
217
|
|
|
179
|
-
|
|
180
|
-
|
|
218
|
+
1. Show a summary of what was created/updated
|
|
219
|
+
2. Ask: **"Execute this task now, or save for later?"**
|
|
220
|
+
- If execute → work on the task immediately
|
|
221
|
+
- If save → confirm the task is clarified and stop
|
|
181
222
|
|
|
182
|
-
|
|
183
|
-
[Key decisions, constraints, and context gathered during interview]
|
|
184
|
-
|
|
185
|
-
## Next
|
|
186
|
-
- [ ] Work through todos in sidebar
|
|
223
|
+
**Example for existing task:**
|
|
187
224
|
```
|
|
225
|
+
Clarified your task and created plan 007-auth-refactor.md
|
|
188
226
|
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
After creating todos and plan:
|
|
192
|
-
|
|
193
|
-
1. Show a summary of what was created:
|
|
194
|
-
- Number of todos added to sidebar
|
|
195
|
-
- Link to the plan file
|
|
227
|
+
Task: Refactor authentication module
|
|
228
|
+
Specs: JWT-based, 24hr expiry, refresh tokens...
|
|
196
229
|
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
- Use clarify mode (`c` key) to add specs to unclarified todos
|
|
200
|
-
- Use `/ralph-loop` to batch process all todos
|
|
230
|
+
Execute this task now, or save for later?
|
|
231
|
+
```
|
|
201
232
|
|
|
202
|
-
Example
|
|
233
|
+
**Example for new tasks:**
|
|
203
234
|
```
|
|
204
|
-
Created
|
|
235
|
+
Created 3 todos in your sidebar and plan 008-api-improvements.md
|
|
205
236
|
|
|
206
237
|
Your todos:
|
|
207
|
-
1.
|
|
208
|
-
2.
|
|
209
|
-
3.
|
|
210
|
-
4. Document the new auth flow
|
|
211
|
-
5. Remove deprecated auth code
|
|
238
|
+
1. Add rate limiting to API endpoints
|
|
239
|
+
2. Implement request validation
|
|
240
|
+
3. Add API documentation
|
|
212
241
|
|
|
213
|
-
|
|
242
|
+
Execute the first task now, or save for later?
|
|
214
243
|
```
|
|
215
244
|
|
|
216
245
|
## Relationship to Other Features
|
|
217
246
|
|
|
218
247
|
| Feature | Purpose | When to Use |
|
|
219
248
|
|---------|---------|-------------|
|
|
220
|
-
|
|
|
221
|
-
|
|
|
249
|
+
| `/clarify` | Interview and clarify task(s) | When you need to think through a task before doing it |
|
|
250
|
+
| Sidebar `c` key | Invokes `/clarify --task-id` | Quick way to clarify a queued task |
|
|
222
251
|
| `/prioritize` | Re-evaluate and reorder all tasks | When context changes or you want fresh prioritization |
|
|
223
|
-
| Ralph-loop | Batch process todos autonomously | After
|
|
252
|
+
| Ralph-loop | Batch process todos autonomously | After clarifying, to work through all todos |
|
|
224
253
|
|
|
225
254
|
## Example Sessions
|
|
226
255
|
|
|
227
|
-
###
|
|
256
|
+
### From Sidebar (existing task)
|
|
228
257
|
```
|
|
229
|
-
User
|
|
258
|
+
[User presses 'c' on task "Add user authentication"]
|
|
259
|
+
|
|
260
|
+
Sidebar sends: /clarify --task-id abc123 Add user authentication
|
|
261
|
+
|
|
262
|
+
Claude: [Uses AskUserQuestion]
|
|
263
|
+
- What auth method? (JWT, session, OAuth?)
|
|
264
|
+
- Any specific security requirements?
|
|
265
|
+
- Which routes need protection?
|
|
266
|
+
|
|
267
|
+
User: [Answers]
|
|
230
268
|
|
|
231
|
-
Claude: [
|
|
269
|
+
Claude: [Creates plan, updates task with clarified=true]
|
|
270
|
+
|
|
271
|
+
Clarified your task and created plan 005-user-auth.md
|
|
272
|
+
|
|
273
|
+
Execute this task now, or save for later?
|
|
274
|
+
```
|
|
275
|
+
|
|
276
|
+
### From Chat (new task)
|
|
277
|
+
```
|
|
278
|
+
User: /clarify I need to add shift+enter support for multiline input
|
|
279
|
+
|
|
280
|
+
Claude: [Uses AskUserQuestion]
|
|
232
281
|
- Which input modes need this? (adding new todos, editing existing, both?)
|
|
233
282
|
- Should Enter still submit, with Shift+Enter for newlines?
|
|
234
|
-
- Any other keyboard shortcuts you want to add while we're in there?
|
|
235
283
|
|
|
236
|
-
User: [Answers
|
|
284
|
+
User: [Answers]
|
|
237
285
|
|
|
238
286
|
Claude: [Creates todo, writes to sidebar, creates plan]
|
|
239
287
|
|
|
240
288
|
Created 1 todo in your sidebar and plan 009-multiline-input.md
|
|
241
289
|
|
|
242
|
-
|
|
243
|
-
1. Add shift+enter for multiline input in add/edit modes
|
|
244
|
-
|
|
245
|
-
Work on this now, or save for later?
|
|
290
|
+
Execute this task now, or save for later?
|
|
246
291
|
```
|
|
247
292
|
|
|
248
|
-
###
|
|
293
|
+
### From Chat (multiple tasks)
|
|
249
294
|
```
|
|
250
|
-
User: /
|
|
295
|
+
User: /clarify
|
|
251
296
|
|
|
252
|
-
Claude: What's on your mind? Tell me everything
|
|
297
|
+
Claude: What's on your mind? Tell me everything.
|
|
253
298
|
|
|
254
299
|
User: ugh so much. the auth is a mess, we're using like 3 different
|
|
255
300
|
patterns. also need to update the docs. oh and there's that bug with
|
|
@@ -259,7 +304,7 @@ Claude: [Uses AskUserQuestion]
|
|
|
259
304
|
- Which auth pattern should we standardize on?
|
|
260
305
|
- Is the session timeout bug blocking anything?
|
|
261
306
|
|
|
262
|
-
User: [Answers
|
|
307
|
+
User: [Answers]
|
|
263
308
|
|
|
264
309
|
Claude: [Creates todos, writes to sidebar, creates plan]
|
|
265
310
|
|
|
@@ -267,9 +312,9 @@ Created 4 todos in your sidebar and plan 010-auth-cleanup.md
|
|
|
267
312
|
|
|
268
313
|
Your todos:
|
|
269
314
|
1. Standardize auth on JWT pattern
|
|
270
|
-
2. Fix session timeout bug
|
|
315
|
+
2. Fix session timeout bug
|
|
271
316
|
3. Update auth documentation
|
|
272
317
|
4. Remove deprecated OAuth1 code
|
|
273
318
|
|
|
274
|
-
|
|
319
|
+
Execute the first task now, or save for later?
|
|
275
320
|
```
|
|
@@ -711,47 +711,8 @@ export class RawSidebar {
|
|
|
711
711
|
const sortedTasks = this.getSortedTasks();
|
|
712
712
|
const task = sortedTasks[this.state.selectedIndex];
|
|
713
713
|
if (task) {
|
|
714
|
-
|
|
715
|
-
|
|
716
|
-
TASK ID: ${task.id}
|
|
717
|
-
TASK: ${task.content}
|
|
718
|
-
|
|
719
|
-
Interview me about this task using AskUserQuestion. Ask about anything relevant: technical implementation, UI/UX, edge cases, concerns, tradeoffs, constraints, dependencies, etc.
|
|
720
|
-
|
|
721
|
-
Guidelines:
|
|
722
|
-
- Don't ask obvious questions - if something is clear from the task description, don't ask about it
|
|
723
|
-
- Be thorough - keep interviewing until you have complete clarity
|
|
724
|
-
- Always include "Anything else I should know?" as a final question
|
|
725
|
-
|
|
726
|
-
After the interview:
|
|
727
|
-
1. Write specs to an Atomic Plan file (check project CLAUDE.md for plan folder path)
|
|
728
|
-
2. Update the task in the sidebar using this script:
|
|
729
|
-
|
|
730
|
-
\`\`\`bash
|
|
731
|
-
node << 'SCRIPT'
|
|
732
|
-
const fs = require('fs');
|
|
733
|
-
const crypto = require('crypto');
|
|
734
|
-
const path = require('path');
|
|
735
|
-
const sidebarDir = path.join(require('os').homedir(), '.claude-sidebar');
|
|
736
|
-
const hash = crypto.createHash('sha256').update(process.cwd()).digest('hex').slice(0, 12);
|
|
737
|
-
const tasksPath = path.join(sidebarDir, 'projects', hash, 'tasks.json');
|
|
738
|
-
let tasks = JSON.parse(fs.readFileSync(tasksPath, 'utf-8'));
|
|
739
|
-
const task = tasks.find(t => t.id === '${task.id}');
|
|
740
|
-
if (task) {
|
|
741
|
-
task.clarified = true;
|
|
742
|
-
task.planPath = 'PLAN_FILENAME.md'; // REPLACE with actual plan filename
|
|
743
|
-
fs.writeFileSync(tasksPath, JSON.stringify(tasks, null, 2));
|
|
744
|
-
console.log('Task updated with clarified=true and planPath');
|
|
745
|
-
}
|
|
746
|
-
SCRIPT
|
|
747
|
-
\`\`\`
|
|
748
|
-
|
|
749
|
-
3. Ask me: "Execute this task now, or save for later?"
|
|
750
|
-
- If I say execute → work on the task
|
|
751
|
-
- If I say save → just confirm the task is clarified and stop`;
|
|
752
|
-
|
|
753
|
-
sendToClaudePane(clarifyPrompt);
|
|
754
|
-
// Don't activate - let the task stay in queue until user decides
|
|
714
|
+
// Invoke the clarify skill with task ID
|
|
715
|
+
sendToClaudePane(`/clarify --task-id ${task.id} ${task.content}`);
|
|
755
716
|
this.render();
|
|
756
717
|
focusClaudePane();
|
|
757
718
|
}
|
package/src/persistence/store.ts
CHANGED
|
@@ -52,7 +52,7 @@ export interface Task {
|
|
|
52
52
|
id: string;
|
|
53
53
|
content: string;
|
|
54
54
|
createdAt: string;
|
|
55
|
-
clarified?: boolean; // Was this task clarified via
|
|
55
|
+
clarified?: boolean; // Was this task clarified via /clarify skill?
|
|
56
56
|
priority?: number; // Sort order (lower = higher priority, 1 = most important)
|
|
57
57
|
recommended?: boolean; // Claude's top picks (shown with star)
|
|
58
58
|
planPath?: string; // Filename of associated Atomic Plan
|