create-claude-cabinet 0.6.0 → 0.6.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/README.md +84 -33
- package/lib/cli.js +13 -13
- package/lib/metadata.js +1 -1
- package/lib/reset.js +10 -10
- package/lib/settings-merge.js +1 -1
- package/package.json +1 -1
- package/templates/README.md +4 -4
- package/templates/briefing/_briefing-template.md +3 -3
- package/templates/cabinet/committees-template.yaml +1 -1
- package/templates/hooks/{cor-upstream-guard.sh → cc-upstream-guard.sh} +8 -8
- package/templates/hooks/skill-telemetry.sh +0 -1
- package/templates/scripts/{cor-drift-check.cjs → cc-drift-check.cjs} +10 -10
- package/templates/skills/{cabinet-cor-health → cabinet-cc-health}/SKILL.md +151 -13
- package/templates/skills/{cor-upgrade → cc-upgrade}/SKILL.md +196 -21
- package/templates/skills/debrief/SKILL.md +8 -8
- package/templates/skills/debrief/phases/upstream-feedback.md +11 -11
- package/templates/skills/extract/SKILL.md +27 -27
- package/templates/skills/link/SKILL.md +11 -11
- package/templates/skills/onboard/SKILL.md +17 -17
- package/templates/skills/onboard/phases/detect-state.md +3 -3
- package/templates/skills/onboard/phases/generate-briefing.md +2 -2
- package/templates/skills/onboard/phases/interview.md +7 -7
- package/templates/skills/onboard/phases/modularity-menu.md +2 -2
- package/templates/skills/onboard/phases/post-onboard-audit.md +3 -3
- package/templates/skills/onboard/phases/summary.md +1 -1
- package/templates/skills/onboard/phases/work-tracking.md +3 -3
- package/templates/skills/orient/SKILL.md +1 -1
- package/templates/skills/orient/phases/context.md +2 -2
- package/templates/skills/publish/SKILL.md +1 -1
- package/templates/skills/unlink/SKILL.md +3 -3
package/README.md
CHANGED
|
@@ -26,11 +26,11 @@ and weigh in when their expertise matters:
|
|
|
26
26
|
Open a terminal, `cd` into your project folder, and run:
|
|
27
27
|
|
|
28
28
|
```bash
|
|
29
|
-
curl -fsSL https://raw.githubusercontent.com/orenmagid/claude-
|
|
29
|
+
curl -fsSL https://raw.githubusercontent.com/orenmagid/claude-cabinet/main/install.sh | bash
|
|
30
30
|
```
|
|
31
31
|
|
|
32
32
|
That's it. If you don't have git or Node.js, it installs them.
|
|
33
|
-
No choices to make —
|
|
33
|
+
No choices to make — you get everything.
|
|
34
34
|
|
|
35
35
|
Then open [Claude Code](https://claude.ai/code) in the same folder and
|
|
36
36
|
say `/onboard`. It'll interview you about your project and set everything
|
|
@@ -41,8 +41,8 @@ step-by-step walkthrough.
|
|
|
41
41
|
|
|
42
42
|
### For developers
|
|
43
43
|
|
|
44
|
-
If you have Node.js installed and want
|
|
45
|
-
|
|
44
|
+
If you have Node.js installed and want to choose which modules to
|
|
45
|
+
install, or want the lean option (skips work tracking and compliance):
|
|
46
46
|
|
|
47
47
|
```bash
|
|
48
48
|
npx create-claude-cabinet
|
|
@@ -55,42 +55,93 @@ it's done, open Claude Code and run `/onboard`.
|
|
|
55
55
|
## What You Get
|
|
56
56
|
|
|
57
57
|
### The Session Loop (always installed)
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
58
|
+
|
|
59
|
+
This is the foundation. You run these commands — they don't happen
|
|
60
|
+
automatically.
|
|
61
|
+
|
|
62
|
+
- **`/orient`** — open every session with this. Claude reads project
|
|
63
|
+
state, checks health, surfaces what needs attention, and briefs you
|
|
64
|
+
so you never start blind. Think of it as the morning briefing before
|
|
65
|
+
the cabinet gets to work.
|
|
66
|
+
- **`/debrief`** — close every session with this. Claude marks work
|
|
67
|
+
done, records lessons, updates state, and prepares the briefing for
|
|
68
|
+
next time. Without debrief, the next orient starts with stale
|
|
69
|
+
information. The loop is what gives Claude memory across sessions.
|
|
70
|
+
|
|
71
|
+
**The habit matters.** Orient and debrief take 30 seconds each. Skip
|
|
72
|
+
them and sessions start from zero — Claude forgets what happened,
|
|
73
|
+
repeats mistakes, and you spend the first 10 minutes re-explaining
|
|
74
|
+
context. Keep the loop and each session picks up where the last one
|
|
75
|
+
left off.
|
|
76
|
+
|
|
77
|
+
### The Cabinet (included in lean)
|
|
78
|
+
|
|
79
|
+
20 expert cabinet members who each own a domain and stay in their lane.
|
|
80
|
+
**Speed-freak** watches performance. **Boundary-man** catches edge cases.
|
|
81
|
+
**Record-keeper** flags when docs drift from code. **Workflow-cop**
|
|
68
82
|
evaluates whether your process actually works. Each member has a
|
|
69
|
-
portfolio,
|
|
70
|
-
|
|
83
|
+
portfolio, produces structured findings, and knows when to speak up
|
|
84
|
+
and when to stay quiet.
|
|
85
|
+
|
|
86
|
+
You convene the cabinet with **`/audit`** — run it occasionally (every
|
|
87
|
+
few sessions, or before a release) to get a full review from every
|
|
88
|
+
relevant member. You don't need to audit every session. The cabinet
|
|
89
|
+
waits until called.
|
|
90
|
+
|
|
91
|
+
Members are organized into **committees** — groups by concern, so you
|
|
92
|
+
can convene just the experts you need. Security review? Convene the
|
|
93
|
+
security committee. Performance concerns? Just the speed committee.
|
|
94
|
+
|
|
95
|
+
### Planning + Execution (included in lean)
|
|
96
|
+
|
|
97
|
+
Don't just start building — brief the cabinet first.
|
|
98
|
+
|
|
99
|
+
- **`/plan`** — describe what you want to build. Claude drafts a plan,
|
|
100
|
+
then the relevant cabinet members critique it before a single line is
|
|
101
|
+
written. The security member notices the missing auth check. The
|
|
102
|
+
data integrity member catches the NULL handling gap. You approve the
|
|
103
|
+
plan, and it carries enough detail for any future session to execute
|
|
104
|
+
without re-exploring.
|
|
105
|
+
- **`/execute`** — pick up an approved plan and build it step by step.
|
|
106
|
+
Cabinet members watch at each checkpoint. The plan tells Claude what
|
|
107
|
+
to do; execute makes sure it gets done right.
|
|
71
108
|
|
|
72
|
-
###
|
|
73
|
-
- **`/plan`** — structured planning with cabinet critique. Before you
|
|
74
|
-
build, the relevant members weigh in on your approach.
|
|
75
|
-
- **`/execute`** — step-through execution with checkpoints. Cabinet
|
|
76
|
-
members watch at each stage.
|
|
109
|
+
### Work Tracking (full install)
|
|
77
110
|
|
|
78
|
-
### Work Tracking (opt-in)
|
|
79
111
|
Local SQLite database for actions, projects, and status tracking. Claude
|
|
80
112
|
reads and writes it directly — no external service needed. Skip this if
|
|
81
113
|
you already use GitHub Issues, Linear, or something else.
|
|
82
114
|
|
|
83
|
-
### Compliance Stack (
|
|
115
|
+
### Compliance Stack (full install)
|
|
116
|
+
|
|
84
117
|
Scoped instructions in `.claude/rules/` that load by file path. An
|
|
85
118
|
enforcement pipeline that promotes recurring feedback into deterministic
|
|
86
119
|
hooks — things that keep going wrong become things that can't go wrong.
|
|
87
120
|
|
|
88
|
-
### Lifecycle (
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
- **`/
|
|
121
|
+
### Lifecycle (included in lean)
|
|
122
|
+
|
|
123
|
+
- **`/onboard`** — the cabinet's first briefing. Claude interviews you
|
|
124
|
+
about your project and prepares everything the members need to do
|
|
125
|
+
their jobs. Re-run it as the project matures — the interview adapts.
|
|
126
|
+
- **`/seed`** — recruit new members. Claude detects new tech in your
|
|
127
|
+
project and proposes expert members to cover it. Your cabinet grows
|
|
128
|
+
with your project.
|
|
129
|
+
- **`/cc-upgrade`** — when Claude Cabinet publishes updates, this skill
|
|
130
|
+
runs the installer for the mechanical parts and walks you through
|
|
131
|
+
what changed conversationally. Intelligence is the merge strategy.
|
|
132
|
+
|
|
133
|
+
## Your Workflow
|
|
134
|
+
|
|
135
|
+
The day-to-day rhythm:
|
|
136
|
+
|
|
137
|
+
1. **Start a session** → `/orient` (get briefed)
|
|
138
|
+
2. **Do your work** → talk to Claude, use `/plan` for anything non-trivial
|
|
139
|
+
3. **Build it** → `/execute` to implement approved plans with cabinet oversight
|
|
140
|
+
4. **Check quality** → `/audit` occasionally for a full cabinet review
|
|
141
|
+
5. **Close the session** → `/debrief` (close the loop)
|
|
142
|
+
|
|
143
|
+
Steps 1 and 5 are the minimum. Everything in between is yours to use as
|
|
144
|
+
needed. The more you use, the more the cabinet learns about your project.
|
|
94
145
|
|
|
95
146
|
## How It Works
|
|
96
147
|
|
|
@@ -135,7 +186,7 @@ scripts/
|
|
|
135
186
|
├── pib-db.js # work tracking CLI (if installed)
|
|
136
187
|
└── ... # triage tools (if audit installed)
|
|
137
188
|
|
|
138
|
-
.
|
|
189
|
+
.ccrc.json # installation metadata
|
|
139
190
|
```
|
|
140
191
|
|
|
141
192
|
## Upgrading
|
|
@@ -144,13 +195,13 @@ Re-run the installer to pick up new versions:
|
|
|
144
195
|
|
|
145
196
|
```bash
|
|
146
197
|
# Shell installer (re-downloads latest)
|
|
147
|
-
curl -fsSL https://raw.githubusercontent.com/orenmagid/claude-
|
|
198
|
+
curl -fsSL https://raw.githubusercontent.com/orenmagid/claude-cabinet/main/install.sh | bash
|
|
148
199
|
|
|
149
200
|
# npm installer (if using Node.js)
|
|
150
201
|
npx create-claude-cabinet
|
|
151
202
|
```
|
|
152
203
|
|
|
153
|
-
In Claude Code, run `/
|
|
204
|
+
In Claude Code, run `/cc-upgrade` for conversational merge of upstream
|
|
154
205
|
changes with your customizations.
|
|
155
206
|
|
|
156
207
|
## Works Across Projects
|
|
@@ -160,7 +211,7 @@ with Claude everywhere.
|
|
|
160
211
|
|
|
161
212
|
- **Your identity** (`~/.claude/CLAUDE.md`) — set up once, carries to
|
|
162
213
|
every project. Claude always knows who you are and what you do.
|
|
163
|
-
- **Project registry** (`~/.claude/
|
|
214
|
+
- **Project registry** (`~/.claude/cc-registry.json`) — tracks all
|
|
164
215
|
your projects. `/onboard` asks how they relate; `/orient` flags
|
|
165
216
|
when work in one might affect another.
|
|
166
217
|
- **Debrief maintenance** — if you mention something new about yourself
|
package/lib/cli.js
CHANGED
|
@@ -24,7 +24,7 @@ const MODULES = {
|
|
|
24
24
|
mandatory: false,
|
|
25
25
|
default: true,
|
|
26
26
|
lean: true,
|
|
27
|
-
templates: ['hooks/git-guardrails.sh', 'hooks/
|
|
27
|
+
templates: ['hooks/git-guardrails.sh', 'hooks/cc-upstream-guard.sh', 'hooks/skill-telemetry.sh', 'hooks/skill-tool-telemetry.sh', 'scripts/cc-drift-check.cjs'],
|
|
28
28
|
},
|
|
29
29
|
'work-tracking': {
|
|
30
30
|
name: 'Work Tracking (pib-db or markdown)',
|
|
@@ -62,7 +62,7 @@ const MODULES = {
|
|
|
62
62
|
'cabinet', 'briefing',
|
|
63
63
|
'skills/cabinet-accessibility', 'skills/cabinet-anti-confirmation',
|
|
64
64
|
'skills/cabinet-architecture', 'skills/cabinet-boundary-man',
|
|
65
|
-
'skills/cabinet-
|
|
65
|
+
'skills/cabinet-cc-health', 'skills/cabinet-data-integrity',
|
|
66
66
|
'skills/cabinet-debugger', 'skills/cabinet-historian',
|
|
67
67
|
'skills/cabinet-organized-mind', 'skills/cabinet-process-therapist',
|
|
68
68
|
'skills/cabinet-qa', 'skills/cabinet-record-keeper',
|
|
@@ -76,12 +76,12 @@ const MODULES = {
|
|
|
76
76
|
],
|
|
77
77
|
},
|
|
78
78
|
'lifecycle': {
|
|
79
|
-
name: 'Lifecycle (onboard + seed +
|
|
79
|
+
name: 'Lifecycle (onboard + seed + cc-upgrade + link)',
|
|
80
80
|
description: 'Onboarding prepares the briefings. Seed proposes new cabinet members when you adopt new tech.',
|
|
81
81
|
mandatory: false,
|
|
82
82
|
default: true,
|
|
83
83
|
lean: true,
|
|
84
|
-
templates: ['skills/onboard', 'skills/seed', 'skills/
|
|
84
|
+
templates: ['skills/onboard', 'skills/seed', 'skills/cc-upgrade', 'skills/link', 'skills/unlink', 'skills/publish', 'skills/extract'],
|
|
85
85
|
},
|
|
86
86
|
'validate': {
|
|
87
87
|
name: 'Validate',
|
|
@@ -105,7 +105,7 @@ function detectProjectState(dir) {
|
|
|
105
105
|
const entries = fs.readdirSync(dir);
|
|
106
106
|
const signals = entries.filter(e => PROJECT_SIGNALS.includes(e));
|
|
107
107
|
const hasClaude = entries.includes('.claude');
|
|
108
|
-
const hasPibrc = fs.existsSync(path.join(dir, '.
|
|
108
|
+
const hasPibrc = fs.existsSync(path.join(dir, '.ccrc.json'));
|
|
109
109
|
|
|
110
110
|
if (hasPibrc) return 'existing-install';
|
|
111
111
|
if (signals.length > 0) return 'existing-project';
|
|
@@ -161,7 +161,7 @@ function printHelp() {
|
|
|
161
161
|
npx create-claude-cabinet --lean Session loop + planning + cabinet
|
|
162
162
|
npx create-claude-cabinet --yes --no-db Install everything except DB
|
|
163
163
|
npx create-claude-cabinet --dry-run Preview what would be installed
|
|
164
|
-
npx create-claude-cabinet --reset Remove
|
|
164
|
+
npx create-claude-cabinet --reset Remove CC files safely
|
|
165
165
|
npx create-claude-cabinet --reset --dry-run Preview what --reset would do
|
|
166
166
|
`);
|
|
167
167
|
}
|
|
@@ -193,16 +193,16 @@ async function run() {
|
|
|
193
193
|
|
|
194
194
|
// --- User identity + project registry ---
|
|
195
195
|
const claudeHome = path.join(os.homedir(), '.claude');
|
|
196
|
-
const registryPath = path.join(claudeHome, '
|
|
196
|
+
const registryPath = path.join(claudeHome, 'cc-registry.json');
|
|
197
197
|
const claudeMdPath = path.join(claudeHome, 'CLAUDE.md');
|
|
198
198
|
|
|
199
199
|
if (!flags.dryRun) {
|
|
200
200
|
if (!fs.existsSync(claudeHome)) fs.mkdirSync(claudeHome, { recursive: true });
|
|
201
201
|
}
|
|
202
202
|
|
|
203
|
-
// First-ever
|
|
204
|
-
const
|
|
205
|
-
if (
|
|
203
|
+
// First-ever CC install: set up user identity
|
|
204
|
+
const firstCcInstall = !fs.existsSync(registryPath);
|
|
205
|
+
if (firstCcInstall && !flags.yes && !flags.lean && !flags.dryRun) {
|
|
206
206
|
const claudeMdContent = fs.existsSync(claudeMdPath) ? fs.readFileSync(claudeMdPath, 'utf8') : '';
|
|
207
207
|
if (!claudeMdContent.includes('# About Me')) {
|
|
208
208
|
console.log(' This looks like your first time assembling a cabinet.');
|
|
@@ -432,11 +432,11 @@ async function run() {
|
|
|
432
432
|
// use skeleton defaults. Phase files are created by /onboard
|
|
433
433
|
// based on the project interview, not copied as generic templates.
|
|
434
434
|
// Exception: cabinet members (always copied), and skills whose phase
|
|
435
|
-
// files ARE the instructions (onboard, seed,
|
|
435
|
+
// files ARE the instructions (onboard, seed, cc-upgrade, publish,
|
|
436
436
|
// extract) — these need their phases to function.
|
|
437
437
|
const alwaysCopyPhases = [
|
|
438
438
|
'skills/onboard', 'skills/seed',
|
|
439
|
-
'skills/
|
|
439
|
+
'skills/cc-upgrade', 'skills/publish', 'skills/extract',
|
|
440
440
|
];
|
|
441
441
|
const isSkill = tmpl.startsWith('skills/') && !alwaysCopyPhases.some(p => tmpl.startsWith(p));
|
|
442
442
|
const results = await copyTemplates(srcPath, destPath, {
|
|
@@ -566,7 +566,7 @@ async function run() {
|
|
|
566
566
|
version: VERSION,
|
|
567
567
|
manifest: allManifest,
|
|
568
568
|
});
|
|
569
|
-
console.log(' 📝 Created .
|
|
569
|
+
console.log(' 📝 Created .ccrc.json');
|
|
570
570
|
}
|
|
571
571
|
|
|
572
572
|
// --- Update project registry ---
|
package/lib/metadata.js
CHANGED
package/lib/reset.js
CHANGED
|
@@ -4,8 +4,8 @@ const crypto = require('crypto');
|
|
|
4
4
|
const { read: readMetadata, METADATA_FILE } = require('./metadata');
|
|
5
5
|
const { DEFAULT_HOOKS } = require('./settings-merge');
|
|
6
6
|
|
|
7
|
-
//
|
|
8
|
-
const
|
|
7
|
+
// CC-managed hook command patterns — used to identify hooks to remove
|
|
8
|
+
const CC_HOOK_PATTERNS = [
|
|
9
9
|
'.claude/hooks/git-guardrails.sh',
|
|
10
10
|
'.claude/hooks/skill-telemetry.sh',
|
|
11
11
|
'.claude/hooks/skill-tool-telemetry.sh',
|
|
@@ -29,10 +29,10 @@ function reconstructManifest(metadata) {
|
|
|
29
29
|
}
|
|
30
30
|
|
|
31
31
|
/**
|
|
32
|
-
* Remove
|
|
32
|
+
* Remove CC files from a project using the manifest for safety.
|
|
33
33
|
*
|
|
34
34
|
* For each manifest entry:
|
|
35
|
-
* - Hash matches → remove (unmodified
|
|
35
|
+
* - Hash matches → remove (unmodified CC file)
|
|
36
36
|
* - Hash differs → skip with [CUSTOMIZED] warning (unless --force)
|
|
37
37
|
* - File missing → skip (already removed)
|
|
38
38
|
*
|
|
@@ -49,7 +49,7 @@ async function reset(projectDir, { dryRun = false, force = false } = {}) {
|
|
|
49
49
|
|
|
50
50
|
const metadata = readMetadata(projectDir);
|
|
51
51
|
if (!metadata) {
|
|
52
|
-
console.log(' No .
|
|
52
|
+
console.log(' No .ccrc.json found — nothing to reset.');
|
|
53
53
|
return;
|
|
54
54
|
}
|
|
55
55
|
|
|
@@ -60,7 +60,7 @@ async function reset(projectDir, { dryRun = false, force = false } = {}) {
|
|
|
60
60
|
if (!manifest || Object.keys(manifest).length === 0) {
|
|
61
61
|
manifest = reconstructManifest(metadata);
|
|
62
62
|
if (Object.keys(manifest).length === 0) {
|
|
63
|
-
console.log(' Could not reconstruct manifest. Use --force to remove all
|
|
63
|
+
console.log(' Could not reconstruct manifest. Use --force to remove all CC directories.\n');
|
|
64
64
|
if (!force) return;
|
|
65
65
|
}
|
|
66
66
|
}
|
|
@@ -101,7 +101,7 @@ async function reset(projectDir, { dryRun = false, force = false } = {}) {
|
|
|
101
101
|
}
|
|
102
102
|
}
|
|
103
103
|
|
|
104
|
-
// Clean
|
|
104
|
+
// Clean CC hooks from settings.json
|
|
105
105
|
const settingsPath = path.join(projectDir, '.claude', 'settings.json');
|
|
106
106
|
let hooksRemoved = 0;
|
|
107
107
|
if (fs.existsSync(settingsPath)) {
|
|
@@ -110,7 +110,7 @@ async function reset(projectDir, { dryRun = false, force = false } = {}) {
|
|
|
110
110
|
for (const [event, hookGroups] of Object.entries(settings.hooks)) {
|
|
111
111
|
const filtered = hookGroups.filter(group => {
|
|
112
112
|
const commands = group.hooks.map(h => h.command);
|
|
113
|
-
return !commands.some(cmd =>
|
|
113
|
+
return !commands.some(cmd => CC_HOOK_PATTERNS.includes(cmd));
|
|
114
114
|
});
|
|
115
115
|
const removedCount = hookGroups.length - filtered.length;
|
|
116
116
|
hooksRemoved += removedCount;
|
|
@@ -133,7 +133,7 @@ async function reset(projectDir, { dryRun = false, force = false } = {}) {
|
|
|
133
133
|
}
|
|
134
134
|
}
|
|
135
135
|
|
|
136
|
-
// Remove .
|
|
136
|
+
// Remove .ccrc.json last
|
|
137
137
|
const pibrcPath = path.join(projectDir, METADATA_FILE);
|
|
138
138
|
if (!dryRun && fs.existsSync(pibrcPath)) {
|
|
139
139
|
fs.unlinkSync(pibrcPath);
|
|
@@ -160,7 +160,7 @@ async function reset(projectDir, { dryRun = false, force = false } = {}) {
|
|
|
160
160
|
}
|
|
161
161
|
|
|
162
162
|
if (hooksRemoved > 0) {
|
|
163
|
-
console.log(` 🔧 Removed ${hooksRemoved}
|
|
163
|
+
console.log(` 🔧 Removed ${hooksRemoved} CC hook${hooksRemoved === 1 ? '' : 's'} from settings.json`);
|
|
164
164
|
}
|
|
165
165
|
|
|
166
166
|
if (!dryRun) {
|
package/lib/settings-merge.js
CHANGED
package/package.json
CHANGED
package/templates/README.md
CHANGED
|
@@ -59,7 +59,7 @@ adoption is straightforward: copy what you need into your project's
|
|
|
59
59
|
| `skills/triage-audit/SKILL.md` | 5 | **Triage skeleton.** Load findings, prepare commentary, present via local web UI or CLI, apply verdicts (fix/defer/reject), create actions for approved findings. 3 phase files. |
|
|
60
60
|
| `skills/onboard/SKILL.md` | 7 | **Onboarding skeleton.** Conversational interview that generates the initial context layer. Re-runnable: first run generates, subsequent runs refine. 6 phase files. |
|
|
61
61
|
| `skills/seed/SKILL.md` | 7 | **Capability seeding skeleton.** Detects technology adoption signals, proposes expertise conversations, builds and maintains cabinet members collaboratively. 4 phase files. |
|
|
62
|
-
| `skills/
|
|
62
|
+
| `skills/cc-upgrade/SKILL.md` | 7 | **Upgrade skeleton.** Conversational merge when new Claude Cabinet skeletons arrive. Intelligence is the merge strategy — conversation, not mechanical copy. 4 phase files. |
|
|
63
63
|
|
|
64
64
|
### Scripts (6)
|
|
65
65
|
|
|
@@ -106,7 +106,7 @@ execution, audit). Each is a named domain expert encoded in markdown.
|
|
|
106
106
|
|
|
107
107
|
| Cabinet Member | Domain | Activation |
|
|
108
108
|
|------------|--------|-----------|
|
|
109
|
-
| `
|
|
109
|
+
| `cc-health` | Claude Cabinet adoption health, phase file coverage, configuration drift, anti-bloat | Always-on during audit |
|
|
110
110
|
|
|
111
111
|
**Infrastructure files (7):**
|
|
112
112
|
|
|
@@ -395,7 +395,7 @@ There is no `box.yaml` or template engine. Configuration uses two mechanisms:
|
|
|
395
395
|
(GTD expertise, Mantine quality, sync health, etc.). EXTENSIONS.md
|
|
396
396
|
includes examples showing how to write your own domain cabinet members.
|
|
397
397
|
- **Distribution mechanism** — No npm package, no installer. Copy files.
|
|
398
|
-
The `/onboard` skill guides adoption. The `/
|
|
398
|
+
The `/onboard` skill guides adoption. The `/cc-upgrade` skill handles updates.
|
|
399
399
|
|
|
400
400
|
## Relationship to Flow
|
|
401
401
|
|
|
@@ -430,7 +430,7 @@ This package includes all 7 waves of the extraction:
|
|
|
430
430
|
reusable patterns, cabinet member writing guide with 3 examples)
|
|
431
431
|
7. **Lifecycle layer** — done (onboard skeleton for project adoption with
|
|
432
432
|
3-mode re-runnability, seed skeleton for capability seeding from tech
|
|
433
|
-
signals, upgrade skeleton for conversational box updates,
|
|
433
|
+
signals, upgrade skeleton for conversational box updates, cc-health
|
|
434
434
|
cabinet member for adoption monitoring, pib-db enhancements: status
|
|
435
435
|
tracking, tags, update-action command, migration logic)
|
|
436
436
|
|
|
@@ -71,7 +71,7 @@ Which cabinet members need which briefing files (identity is always loaded):
|
|
|
71
71
|
| anti-confirmation | | | | | |
|
|
72
72
|
| architecture | x | x | | | |
|
|
73
73
|
| boundary-man | x | x | | | |
|
|
74
|
-
|
|
|
74
|
+
| cc-health | | x | x | | |
|
|
75
75
|
| data-integrity | x | x | | | x |
|
|
76
76
|
| debugger | x | | | | |
|
|
77
77
|
| record-keeper | | x | | | |
|
|
@@ -118,7 +118,7 @@ exists so cabinet members know what's available.
|
|
|
118
118
|
only if the interview produced content for them.
|
|
119
119
|
- **/seed** adds domain extension files when specialized cabinet members
|
|
120
120
|
are adopted.
|
|
121
|
-
- **/
|
|
121
|
+
- **/cc-upgrade** can migrate a monolithic `_briefing.md` into the
|
|
122
122
|
split format.
|
|
123
123
|
|
|
124
124
|
## Backward Compatibility
|
|
@@ -131,7 +131,7 @@ or if no `briefing` field is present, the system falls back to reading
|
|
|
131
131
|
- Existing projects with a monolithic `_briefing.md` continue to work
|
|
132
132
|
without changes.
|
|
133
133
|
- Projects can migrate incrementally — split out one file at a time.
|
|
134
|
-
- `/
|
|
134
|
+
- `/cc-upgrade` handles the full migration when the project is ready.
|
|
135
135
|
|
|
136
136
|
## Finding Format
|
|
137
137
|
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
#!/bin/bash
|
|
2
|
-
#
|
|
2
|
+
# CC Upstream Guard — PreToolUse hook for Edit and Write tool calls
|
|
3
3
|
#
|
|
4
4
|
# Blocks modifications to files managed by Claude Cabinet. These files
|
|
5
|
-
# are upstream-owned: updates come through /
|
|
5
|
+
# are upstream-owned: updates come through /cc-upgrade, not direct edits.
|
|
6
6
|
# Project-specific customization goes in briefing files and phase files.
|
|
7
7
|
#
|
|
8
8
|
# How it works:
|
|
9
|
-
# Reads .
|
|
9
|
+
# Reads .ccrc.json manifest (list of CC-installed files with hashes).
|
|
10
10
|
# If the target file_path is in the manifest, block the write.
|
|
11
11
|
#
|
|
12
12
|
# ROLLBACK: Comment out the PreToolUse entry for this hook in
|
|
@@ -24,12 +24,12 @@ if [ -z "$FILE_PATH" ]; then
|
|
|
24
24
|
exit 0
|
|
25
25
|
fi
|
|
26
26
|
|
|
27
|
-
# Find the project root (where .
|
|
27
|
+
# Find the project root (where .ccrc.json lives)
|
|
28
28
|
# Walk up from current directory
|
|
29
29
|
find_project_root() {
|
|
30
30
|
local dir="$PWD"
|
|
31
31
|
while [ "$dir" != "/" ]; do
|
|
32
|
-
if [ -f "$dir/.
|
|
32
|
+
if [ -f "$dir/.ccrc.json" ]; then
|
|
33
33
|
echo "$dir"
|
|
34
34
|
return 0
|
|
35
35
|
fi
|
|
@@ -41,7 +41,7 @@ find_project_root() {
|
|
|
41
41
|
PROJECT_ROOT=$(find_project_root)
|
|
42
42
|
|
|
43
43
|
if [ -z "$PROJECT_ROOT" ]; then
|
|
44
|
-
# No .
|
|
44
|
+
# No .ccrc.json found — not a CC project, allow everything
|
|
45
45
|
echo '{"decision":"allow"}'
|
|
46
46
|
exit 0
|
|
47
47
|
fi
|
|
@@ -64,7 +64,7 @@ fi
|
|
|
64
64
|
IN_MANIFEST=$(python3 -c "
|
|
65
65
|
import json, sys
|
|
66
66
|
try:
|
|
67
|
-
with open('$PROJECT_ROOT/.
|
|
67
|
+
with open('$PROJECT_ROOT/.ccrc.json') as f:
|
|
68
68
|
data = json.load(f)
|
|
69
69
|
manifest = data.get('manifest', {})
|
|
70
70
|
print('yes' if '$REL_PATH' in manifest else 'no')
|
|
@@ -73,7 +73,7 @@ except:
|
|
|
73
73
|
" 2>/dev/null)
|
|
74
74
|
|
|
75
75
|
if [ "$IN_MANIFEST" = "yes" ]; then
|
|
76
|
-
echo "{\"decision\":\"block\",\"reason\":\"Blocked: $REL_PATH is managed by Claude Cabinet.
|
|
76
|
+
echo "{\"decision\":\"block\",\"reason\":\"Blocked: $REL_PATH is managed by Claude Cabinet. CC-managed files are upstream-owned — edits come through /cc-upgrade, not direct modification. Put project-specific content in briefing files or phase files instead.\"}"
|
|
77
77
|
else
|
|
78
78
|
echo '{"decision":"allow"}'
|
|
79
79
|
fi
|
|
@@ -21,7 +21,6 @@ SKILLS=""
|
|
|
21
21
|
for skill_path in "$SKILL_DIR"/*/SKILL.md; do
|
|
22
22
|
[ -f "$skill_path" ] || continue
|
|
23
23
|
skill=$(basename "$(dirname "$skill_path")")
|
|
24
|
-
[ "$skill" = "perspectives" ] && continue
|
|
25
24
|
[ "$skill" = "_template" ] && continue
|
|
26
25
|
SKILLS="$SKILLS $skill"
|
|
27
26
|
done
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
//
|
|
2
|
+
// CC Drift Check — detect modified upstream-managed files
|
|
3
3
|
//
|
|
4
|
-
// Compares current file hashes against .
|
|
4
|
+
// Compares current file hashes against .ccrc.json manifest hashes.
|
|
5
5
|
// Reports files that have been modified since install (drift).
|
|
6
6
|
//
|
|
7
7
|
// Usage:
|
|
8
|
-
// node scripts/
|
|
9
|
-
// node scripts/
|
|
10
|
-
// node scripts/
|
|
8
|
+
// node scripts/cc-drift-check.js # exit 0 if clean, 1 if drift
|
|
9
|
+
// node scripts/cc-drift-check.js --json # output JSON for programmatic use
|
|
10
|
+
// node scripts/cc-drift-check.js --fix # show what /cc-upgrade would fix
|
|
11
11
|
|
|
12
12
|
const fs = require('fs');
|
|
13
13
|
const path = require('path');
|
|
@@ -15,18 +15,18 @@ const crypto = require('crypto');
|
|
|
15
15
|
|
|
16
16
|
const projectRoot = findProjectRoot();
|
|
17
17
|
if (!projectRoot) {
|
|
18
|
-
console.error('No .
|
|
18
|
+
console.error('No .ccrc.json found — not a CC project.');
|
|
19
19
|
process.exit(2);
|
|
20
20
|
}
|
|
21
21
|
|
|
22
|
-
const metadataPath = path.join(projectRoot, '.
|
|
22
|
+
const metadataPath = path.join(projectRoot, '.ccrc.json');
|
|
23
23
|
const metadata = JSON.parse(fs.readFileSync(metadataPath, 'utf8'));
|
|
24
24
|
const manifest = metadata.manifest || {};
|
|
25
25
|
|
|
26
26
|
function findProjectRoot() {
|
|
27
27
|
let dir = process.cwd();
|
|
28
28
|
while (dir !== path.dirname(dir)) {
|
|
29
|
-
if (fs.existsSync(path.join(dir, '.
|
|
29
|
+
if (fs.existsSync(path.join(dir, '.ccrc.json'))) return dir;
|
|
30
30
|
dir = path.dirname(dir);
|
|
31
31
|
}
|
|
32
32
|
return null;
|
|
@@ -64,7 +64,7 @@ if (args.includes('--json')) {
|
|
|
64
64
|
console.log(JSON.stringify({ drifted, missing, clean: clean.length }, null, 2));
|
|
65
65
|
} else {
|
|
66
66
|
if (drifted.length === 0 && missing.length === 0) {
|
|
67
|
-
console.log(`All ${clean.length}
|
|
67
|
+
console.log(`All ${clean.length} CC-managed files match upstream hashes.`);
|
|
68
68
|
} else {
|
|
69
69
|
if (drifted.length > 0) {
|
|
70
70
|
console.log(`Drifted (${drifted.length} files modified from upstream):`);
|
|
@@ -76,7 +76,7 @@ if (args.includes('--json')) {
|
|
|
76
76
|
}
|
|
77
77
|
console.log(`\nClean: ${clean.length} files match.`);
|
|
78
78
|
if (args.includes('--fix')) {
|
|
79
|
-
console.log('\nRun /
|
|
79
|
+
console.log('\nRun /cc-upgrade to restore drifted files to upstream versions.');
|
|
80
80
|
}
|
|
81
81
|
}
|
|
82
82
|
}
|