@axiomatic-labs/claudeflow 2.10.341 → 2.11.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/lib/install.js +40 -29
- package/lib/version.js +1 -1
- package/package.json +1 -1
package/lib/install.js
CHANGED
|
@@ -10,7 +10,7 @@ const ui = require('./ui.js');
|
|
|
10
10
|
// from the release so template subskills stay in sync, while preserving any
|
|
11
11
|
// user-generated skills that are not part of the shipped asset.
|
|
12
12
|
const TEMPLATE_AGENTS = new Set(['claudeflow-explorer', 'claudeflow-planner', 'example-agent']);
|
|
13
|
-
const TEMPLATE_MANAGED_MANIFEST = path.join('.
|
|
13
|
+
const TEMPLATE_MANAGED_MANIFEST = path.join('.claudeflow', 'config', 'template-managed-manifest.json');
|
|
14
14
|
const CLAUDE_BACKUP_ROOT = '.claudeflow-backups';
|
|
15
15
|
|
|
16
16
|
async function run() {
|
|
@@ -56,6 +56,7 @@ async function run() {
|
|
|
56
56
|
ui.step('Extracting template files...');
|
|
57
57
|
execSync(`unzip -o "${tmpZip}" -d "${tmpExtract}"`, { stdio: 'pipe' });
|
|
58
58
|
const srcClaude = path.join(tmpExtract, '.claude');
|
|
59
|
+
const srcClaudeflow = path.join(tmpExtract, '.claudeflow');
|
|
59
60
|
const nextManagedPaths = collectManagedPathsFromRelease(tmpExtract);
|
|
60
61
|
const previousManifest = readTemplateManagedManifest(cwd);
|
|
61
62
|
const previousManagedPaths = previousManifest
|
|
@@ -128,15 +129,15 @@ async function run() {
|
|
|
128
129
|
}
|
|
129
130
|
|
|
130
131
|
// Copy shared runtime scripts used by skills and hooks
|
|
131
|
-
const srcRuntime = path.join(
|
|
132
|
-
const dstRuntime = path.join(cwd, '.
|
|
132
|
+
const srcRuntime = path.join(srcClaudeflow, 'runtime');
|
|
133
|
+
const dstRuntime = path.join(cwd, '.claudeflow', 'runtime');
|
|
133
134
|
if (fs.existsSync(srcRuntime)) {
|
|
134
135
|
copyDirSync(srcRuntime, dstRuntime);
|
|
135
136
|
}
|
|
136
137
|
|
|
137
138
|
// Copy canonical template-managed assets used by init/update composition
|
|
138
|
-
const srcTemplates = path.join(
|
|
139
|
-
const dstTemplates = path.join(cwd, '.
|
|
139
|
+
const srcTemplates = path.join(srcClaudeflow, 'templates');
|
|
140
|
+
const dstTemplates = path.join(cwd, '.claudeflow', 'templates');
|
|
140
141
|
if (fs.existsSync(srcTemplates)) {
|
|
141
142
|
copyDirSync(srcTemplates, dstTemplates);
|
|
142
143
|
}
|
|
@@ -170,20 +171,20 @@ async function run() {
|
|
|
170
171
|
}
|
|
171
172
|
|
|
172
173
|
// Copy all docs
|
|
173
|
-
const srcDocs = path.join(
|
|
174
|
-
const dstDocs = path.join(cwd, '.
|
|
174
|
+
const srcDocs = path.join(srcClaudeflow, 'docs');
|
|
175
|
+
const dstDocs = path.join(cwd, '.claudeflow', 'docs');
|
|
175
176
|
if (fs.existsSync(srcDocs)) {
|
|
176
177
|
copyDirSync(srcDocs, dstDocs);
|
|
177
178
|
}
|
|
178
179
|
|
|
179
|
-
// Ensure .
|
|
180
|
-
fs.mkdirSync(path.join(cwd, '.
|
|
181
|
-
const srcTmp = path.join(
|
|
180
|
+
// Ensure .claudeflow/tmp exists and copy bundled scripts
|
|
181
|
+
fs.mkdirSync(path.join(cwd, '.claudeflow', 'tmp'), { recursive: true });
|
|
182
|
+
const srcTmp = path.join(srcClaudeflow, 'tmp');
|
|
182
183
|
if (fs.existsSync(srcTmp)) {
|
|
183
184
|
const tmpFiles = fs.readdirSync(srcTmp);
|
|
184
185
|
for (const file of tmpFiles) {
|
|
185
186
|
const srcFile = path.join(srcTmp, file);
|
|
186
|
-
const dstFile = path.join(cwd, '.
|
|
187
|
+
const dstFile = path.join(cwd, '.claudeflow', 'tmp', file);
|
|
187
188
|
if (fs.statSync(srcFile).isFile()) {
|
|
188
189
|
fs.copyFileSync(srcFile, dstFile);
|
|
189
190
|
}
|
|
@@ -192,7 +193,7 @@ async function run() {
|
|
|
192
193
|
|
|
193
194
|
// Write version file
|
|
194
195
|
writeLocalVersion(version);
|
|
195
|
-
nextManagedPaths.add(normalizeRelativePath(path.join('.
|
|
196
|
+
nextManagedPaths.add(normalizeRelativePath(path.join('.claudeflow', 'version')));
|
|
196
197
|
|
|
197
198
|
// Persist managed path manifest for deterministic stale-file pruning on update
|
|
198
199
|
writeTemplateManagedManifest(cwd, version, nextManagedPaths);
|
|
@@ -219,7 +220,7 @@ async function run() {
|
|
|
219
220
|
hookCount = fs.readdirSync(hooksDir, { withFileTypes: true }).filter((e) => e.isDirectory()).length;
|
|
220
221
|
} catch {}
|
|
221
222
|
|
|
222
|
-
const docsDir = path.join(cwd, '.
|
|
223
|
+
const docsDir = path.join(cwd, '.claudeflow', 'docs');
|
|
223
224
|
let docCount = 0;
|
|
224
225
|
try {
|
|
225
226
|
docCount = fs.readdirSync(docsDir).filter((f) => !f.startsWith('.')).length;
|
|
@@ -530,6 +531,7 @@ function addFilesFromDir(set, rootBase, targetDir) {
|
|
|
530
531
|
|
|
531
532
|
function collectManagedPathsFromRelease(extractRoot) {
|
|
532
533
|
const srcClaude = path.join(extractRoot, '.claude');
|
|
534
|
+
const srcClaudeflow = path.join(extractRoot, '.claudeflow');
|
|
533
535
|
const managed = new Set();
|
|
534
536
|
|
|
535
537
|
const settingsPath = path.join(srcClaude, 'settings.json');
|
|
@@ -537,8 +539,12 @@ function collectManagedPathsFromRelease(extractRoot) {
|
|
|
537
539
|
managed.add('.claude/settings.json');
|
|
538
540
|
}
|
|
539
541
|
|
|
540
|
-
|
|
541
|
-
|
|
542
|
+
// Claude Code native dirs: hooks stay in .claude/
|
|
543
|
+
addFilesFromDir(managed, extractRoot, path.join(srcClaude, 'hooks'));
|
|
544
|
+
|
|
545
|
+
// Claudeflow dirs: runtime, templates, docs in .claudeflow/
|
|
546
|
+
['runtime', 'templates', 'docs'].forEach((folder) => {
|
|
547
|
+
addFilesFromDir(managed, extractRoot, path.join(srcClaudeflow, folder));
|
|
542
548
|
});
|
|
543
549
|
|
|
544
550
|
const skillsDir = path.join(srcClaude, 'skills');
|
|
@@ -561,38 +567,43 @@ function collectManagedPathsFromRelease(extractRoot) {
|
|
|
561
567
|
}
|
|
562
568
|
}
|
|
563
569
|
|
|
564
|
-
const tmpDir = path.join(
|
|
570
|
+
const tmpDir = path.join(srcClaudeflow, 'tmp');
|
|
565
571
|
if (fs.existsSync(tmpDir)) {
|
|
566
572
|
const entries = fs.readdirSync(tmpDir, { withFileTypes: true });
|
|
567
573
|
for (const entry of entries) {
|
|
568
574
|
if (entry.isFile()) {
|
|
569
|
-
managed.add(normalizeRelativePath(path.join('.
|
|
575
|
+
managed.add(normalizeRelativePath(path.join('.claudeflow', 'tmp', entry.name)));
|
|
570
576
|
}
|
|
571
577
|
}
|
|
572
578
|
}
|
|
573
579
|
|
|
574
|
-
const versionFile = path.join(
|
|
580
|
+
const versionFile = path.join(srcClaudeflow, 'version');
|
|
575
581
|
if (fs.existsSync(versionFile)) {
|
|
576
|
-
managed.add('.
|
|
582
|
+
managed.add('.claudeflow/version');
|
|
577
583
|
}
|
|
578
584
|
|
|
579
585
|
return managed;
|
|
580
586
|
}
|
|
581
587
|
|
|
582
588
|
function collectLegacyManagedPathsFromDisk(projectRoot) {
|
|
583
|
-
const
|
|
589
|
+
const claudeDir = path.join(projectRoot, '.claude');
|
|
590
|
+
const claudeflowDir = path.join(projectRoot, '.claudeflow');
|
|
584
591
|
const managed = new Set();
|
|
585
592
|
|
|
586
|
-
const settingsPath = path.join(
|
|
593
|
+
const settingsPath = path.join(claudeDir, 'settings.json');
|
|
587
594
|
if (fs.existsSync(settingsPath)) {
|
|
588
595
|
managed.add('.claude/settings.json');
|
|
589
596
|
}
|
|
590
597
|
|
|
591
|
-
|
|
592
|
-
|
|
598
|
+
// Claude Code native: hooks stay in .claude/
|
|
599
|
+
addFilesFromDir(managed, projectRoot, path.join(claudeDir, 'hooks'));
|
|
600
|
+
|
|
601
|
+
// Claudeflow dirs: runtime, templates, docs in .claudeflow/
|
|
602
|
+
['runtime', 'templates', 'docs'].forEach((folder) => {
|
|
603
|
+
addFilesFromDir(managed, projectRoot, path.join(claudeflowDir, folder));
|
|
593
604
|
});
|
|
594
605
|
|
|
595
|
-
const skillsDir = path.join(
|
|
606
|
+
const skillsDir = path.join(claudeDir, 'skills');
|
|
596
607
|
if (fs.existsSync(skillsDir)) {
|
|
597
608
|
const entries = fs.readdirSync(skillsDir, { withFileTypes: true });
|
|
598
609
|
for (const entry of entries) {
|
|
@@ -602,7 +613,7 @@ function collectLegacyManagedPathsFromDisk(projectRoot) {
|
|
|
602
613
|
}
|
|
603
614
|
}
|
|
604
615
|
|
|
605
|
-
const agentsDir = path.join(
|
|
616
|
+
const agentsDir = path.join(claudeDir, 'agents');
|
|
606
617
|
if (fs.existsSync(agentsDir)) {
|
|
607
618
|
for (const agentName of TEMPLATE_AGENTS) {
|
|
608
619
|
const filePath = path.join(agentsDir, `${agentName}.md`);
|
|
@@ -612,19 +623,19 @@ function collectLegacyManagedPathsFromDisk(projectRoot) {
|
|
|
612
623
|
}
|
|
613
624
|
}
|
|
614
625
|
|
|
615
|
-
const tmpDir = path.join(
|
|
626
|
+
const tmpDir = path.join(claudeflowDir, 'tmp');
|
|
616
627
|
if (fs.existsSync(tmpDir)) {
|
|
617
628
|
const entries = fs.readdirSync(tmpDir, { withFileTypes: true });
|
|
618
629
|
for (const entry of entries) {
|
|
619
630
|
if (entry.isFile() && entry.name.endsWith('.py')) {
|
|
620
|
-
managed.add(normalizeRelativePath(path.join('.
|
|
631
|
+
managed.add(normalizeRelativePath(path.join('.claudeflow', 'tmp', entry.name)));
|
|
621
632
|
}
|
|
622
633
|
}
|
|
623
634
|
}
|
|
624
635
|
|
|
625
|
-
const versionFile = path.join(
|
|
636
|
+
const versionFile = path.join(claudeflowDir, 'version');
|
|
626
637
|
if (fs.existsSync(versionFile)) {
|
|
627
|
-
managed.add('.
|
|
638
|
+
managed.add('.claudeflow/version');
|
|
628
639
|
}
|
|
629
640
|
|
|
630
641
|
return managed;
|
package/lib/version.js
CHANGED
|
@@ -4,7 +4,7 @@ const { getGitHubToken } = require('./auth.js');
|
|
|
4
4
|
const { getLatestRelease } = require('./download.js');
|
|
5
5
|
const ui = require('./ui.js');
|
|
6
6
|
|
|
7
|
-
const VERSION_FILE = path.join(process.cwd(), '.
|
|
7
|
+
const VERSION_FILE = path.join(process.cwd(), '.claudeflow', 'version');
|
|
8
8
|
|
|
9
9
|
function readLocalVersion() {
|
|
10
10
|
try {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@axiomatic-labs/claudeflow",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.11.0",
|
|
4
4
|
"description": "Claudeflow — AI-powered development toolkit for Claude Code. Skills, agents, hooks, and quality gates that ship production apps.",
|
|
5
5
|
"bin": {
|
|
6
6
|
"claudeflow": "./bin/cli.js"
|