@hanzlaa/rcode 4.7.1 → 4.7.2

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hanzlaa/rcode",
3
- "version": "4.7.1",
3
+ "version": "4.7.2",
4
4
  "description": "rcode — the AI team that never forgets. Persistent memory, specialist agents, and slash commands for AI IDEs. Works in Claude Code, Cursor, Gemini, VS Code, and Antigravity.",
5
5
  "main": "cli/index.js",
6
6
  "bin": {
@@ -1,6 +1,15 @@
1
1
  ---
2
2
  name: rcode-do
3
- description: "[ROUTER] Interactive picker — describe what you want and rcode picks the command"
3
+ description: >-
4
+ [ROUTER] Interactive picker — describe what you want and rcode picks
5
+ the command. Activates whenever the user says "use rcode", "using
6
+ rcode", "rcode kar do", "rcode say kara do", "let rcode handle
7
+ this/it", "rcode this", or otherwise names rcode as the tool to use
8
+ for a task without naming a specific /rcode-* command — especially
9
+ when the request bundles multiple asks (e.g. "init a phase, build a
10
+ checklist, make a sprint"). Route through this picker instead of
11
+ hand-rolling files or Bash workarounds for what rcode already has a
12
+ command for.
4
13
  argument-hint: "[optional question or task description]"
5
14
  allowed-tools:
6
15
  - Read
@@ -79,6 +79,12 @@ Planner prompt:
79
79
  **Phase:** {phase_number}
80
80
  **Mode:** {standard | gap_closure | reviews}
81
81
 
82
+ ## Scope
83
+
84
+ Default: `phase` (one SPRINT.md, up to 8 stories — see Scope-Driven Sizing in your role instructions).
85
+
86
+ **Self-upgrade to `initiative` mid-decomposition** if, once you've read CONTEXT.md/ROADMAP.md and started breaking down the work, it splits into independent waves or work-streams (e.g. shared-primitive foundation → feature-local migrations → cleanup/tests) and total stories would exceed 8. When that happens, emit multiple SPRINT.md files (`{phase}-1-SPRINT.md`, `{phase}-2-SPRINT.md`, ...) in this same run instead of one oversized plan. Do not wait for rcode-sprint-checker's "scope exceeds context budget" rejection to force a resharding pass — that costs a full extra planner run. Decide the split now, while you're already looking at the file/story list.
87
+
82
88
  <files_to_read>
83
89
  - {state_path} (Project State)
84
90
  - {roadmap_path} (Roadmap)
@@ -131,7 +131,11 @@ export function Breadcrumb({ items }) {
131
131
  * @param {{ cmd: string, desc: string }} props
132
132
  */
133
133
  export function CmdHint({ cmd, desc }) {
134
- function handleClick() {
134
+ function handleClick(e) {
135
+ // CmdHint often sits inside a clickable card row (SprintCard's empty
136
+ // state, etc.) — without this, copying the command also fires the
137
+ // row's own click (e.g. navigating away mid-copy).
138
+ if (e && e.stopPropagation) e.stopPropagation();
135
139
  navigator.clipboard.writeText(cmd)
136
140
  .then(() => showToast('Copied: ' + cmd))
137
141
  .catch(() => {
@@ -291,9 +295,7 @@ export function SprintCard({ sprint: s, S }) {
291
295
  </div>
292
296
  <div style="margin-top:6px;"><${ProgressBar} done=${done} total=${stories.length}/></div>
293
297
  ${stories.length === 0 ? html`
294
- <div class="empty-action" style="margin-top:var(--space-2);font-size:var(--text-xs);">
295
- No tasks — run <code>/rcode-plan ${phaseId}</code> to populate
296
- </div>
298
+ <${CmdHint} cmd=${'/rcode-plan ' + phaseId} desc="Populate this sprint with tasks"/>
297
299
  ` : null}
298
300
  ${s.started_at ? html`
299
301
  <div style="color:var(--text-muted);font-size:var(--text-xs);margin-top:4px;">
@@ -9,7 +9,7 @@
9
9
 
10
10
  import { html } from '../preact.js';
11
11
  import { useStore } from '../store.js';
12
- import { pressable } from '../components/shared.js';
12
+ import { pressable, CmdHint } from '../components/shared.js';
13
13
  import { Icon } from '../icons-client.js';
14
14
 
15
15
  export function BacklogView() {
@@ -23,7 +23,7 @@ export function BacklogView() {
23
23
  ? html`
24
24
  <div class="empty">
25
25
  No phases waiting in the backlog.
26
- <div class="empty-action">Run /rcode-add-phase to queue up new work</div>
26
+ <${CmdHint} cmd="/rcode-add-phase" desc="Queue up new work"/>
27
27
  </div>
28
28
  `
29
29
  : html`
@@ -9,11 +9,11 @@
9
9
 
10
10
  import { html, useState, useCallback } from '../preact.js';
11
11
  import { useStore, refresh } from '../store.js';
12
- import { allTasks, currentPhaseName } from '../util.js';
12
+ import { allTasks, currentPhaseName, currentPhaseId } from '../util.js';
13
13
  import { stopStory, openOrchPanel, openTermPanel, setTaskStatus } from '../orchestrator.js';
14
14
  import { openFileViewer } from '../store.js';
15
15
  import { openRunnerPicker } from '../components/RunnerPicker.js';
16
- import { showToast } from '../components/shared.js';
16
+ import { showToast, CmdHint } from '../components/shared.js';
17
17
 
18
18
  // ---- Column descriptors ----
19
19
  const COLS = [
@@ -262,9 +262,11 @@ export function KanbanView() {
262
262
  ${' is active.'}
263
263
  </div>
264
264
  ` : null}
265
+ <${CmdHint}
266
+ cmd=${'/rcode-plan' + (currentPhaseId(currentPhase) ? ' ' + currentPhaseId(currentPhase) : '')}
267
+ desc="Generate sprint stories"/>
265
268
  <div class="empty-action">
266
- Run <code>/rcode-plan</code> to generate sprint stories, or browse
267
- planning docs in the <a href="#files">Files</a> view.
269
+ Or browse planning docs in the <a href="#files">Files</a> view.
268
270
  </div>
269
271
  </div>
270
272
  </div>
@@ -14,6 +14,7 @@
14
14
 
15
15
  import { html, useState, useEffect } from '../preact.js';
16
16
  import { FileReader } from '../components/FileReader.js';
17
+ import { CmdHint } from '../components/shared.js';
17
18
 
18
19
  // ---- Command hints accordion ----
19
20
  const MEMORY_HINTS = [
@@ -127,7 +128,7 @@ export function MemoryView() {
127
128
  <div class="empty">
128
129
  <h3 style="color:var(--rcode-gold);">Not initialised</h3>
129
130
  <p>The Memory Bank is rcode's structured project context.</p>
130
- <div class="empty-action">Run <code>/rcode-memory-init</code> to bootstrap</div>
131
+ <${CmdHint} cmd="/rcode-memory-init" desc="Bootstrap the Memory Bank"/>
131
132
  </div>
132
133
  </div>
133
134
  `;
@@ -11,7 +11,7 @@ import { html, useState } from '../preact.js';
11
11
  import { useStore } from '../store.js';
12
12
  import { pct, humanDate, phaseHints, chip, phaseMilestone } from '../util.js';
13
13
  import {
14
- Chip, ProgressBar, Breadcrumb, CmdHints, RunningBadge, SprintCard, PhaseCard,
14
+ Chip, ProgressBar, Breadcrumb, CmdHint, CmdHints, RunningBadge, SprintCard, PhaseCard,
15
15
  } from '../components/shared.js';
16
16
  import { openTermPanel, runningInPhase } from '../orchestrator.js';
17
17
  import { openFileViewer } from '../store.js';
@@ -118,7 +118,7 @@ function PhaseDetail({ phase: p, S }) {
118
118
  : html`
119
119
  <div class="empty">
120
120
  No sprints in this phase yet.
121
- <div class="empty-action">Run /rcode-plan to create sprints</div>
121
+ <${CmdHint} cmd=${'/rcode-plan ' + p.id} desc="Create sprints for this phase"/>
122
122
  </div>
123
123
  `}
124
124
  </div>
@@ -212,7 +212,7 @@ export function PhasesView({ subId, filters }) {
212
212
  : html`
213
213
  <div class="empty">
214
214
  No phases yet.
215
- <div class="empty-action">Run /rcode-new-project to start</div>
215
+ <${CmdHint} cmd="/rcode-new-project" desc="Design your first project"/>
216
216
  </div>
217
217
  `}
218
218
  </div>
@@ -10,9 +10,9 @@
10
10
 
11
11
  import { html, useState } from '../preact.js';
12
12
  import { useStore } from '../store.js';
13
- import { pct, humanDate, allSprints, sprintHints, chip, phaseMilestone } from '../util.js';
13
+ import { pct, humanDate, allSprints, sprintHints, chip, phaseMilestone, currentPhaseId } from '../util.js';
14
14
  import {
15
- Chip, ProgressBar, Breadcrumb, CmdHints, RunningBadge, SprintCard, TaskCard,
15
+ Chip, ProgressBar, Breadcrumb, CmdHint, CmdHints, RunningBadge, SprintCard, TaskCard,
16
16
  } from '../components/shared.js';
17
17
  import { openTermPanel, runningInSprint } from '../orchestrator.js';
18
18
  import { openFileViewer } from '../store.js';
@@ -105,7 +105,7 @@ function SprintDetail({ sprint: s, S }) {
105
105
  : html`
106
106
  <div class="empty">
107
107
  No tasks in this sprint yet.
108
- <div class="empty-action">Run /rcode-create-story to add tasks</div>
108
+ <${CmdHint} cmd=${'/rcode-create-story ' + s.id} desc="Add a task to this sprint"/>
109
109
  </div>
110
110
  `}
111
111
  </div>
@@ -210,7 +210,7 @@ export function SprintsView({ subId, filters }) {
210
210
  : html`
211
211
  <div class="empty">
212
212
  No sprints yet.
213
- <div class="empty-action">Run /rcode-plan to create sprints</div>
213
+ <${CmdHint} cmd=${'/rcode-plan' + (currentPhaseId(S.currentPhase) ? ' ' + currentPhaseId(S.currentPhase) : '')} desc="Plan sprints for the current phase"/>
214
214
  </div>
215
215
  `}
216
216
  </div>
@@ -9,7 +9,7 @@
9
9
  import { html, useState, useMemo } from '../preact.js';
10
10
  import { useStore } from '../store.js';
11
11
  import { allTasks, currentPhaseId } from '../util.js';
12
- import { CmdHints, TaskCard } from '../components/shared.js';
12
+ import { CmdHint, CmdHints, TaskCard } from '../components/shared.js';
13
13
 
14
14
  function TaskGrouped({ tasks }) {
15
15
  if (!tasks.length) return null;
@@ -137,9 +137,7 @@ export function TasksView() {
137
137
  : html`
138
138
  <div class="empty">
139
139
  No tasks yet.
140
- <div class="empty-action">
141
- Run <code>/rcode-plan${phaseHint}</code> to generate tasks for this project.
142
- </div>
140
+ <${CmdHint} cmd=${'/rcode-plan' + phaseHint} desc="Generate tasks for this project"/>
143
141
  </div>
144
142
  `}
145
143
  </div>