@axiomatic-labs/claudeflow 2.13.146 → 2.13.149

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.
Files changed (2) hide show
  1. package/lib/install.js +19 -52
  2. package/package.json +1 -1
package/lib/install.js CHANGED
@@ -65,16 +65,12 @@ async function run() {
65
65
  ui.step('Extracting template files...');
66
66
  execSync(`unzip -o "${tmpZip}" -d "${tmpExtract}"`, { stdio: 'pipe' });
67
67
  const srcClaudeflow = path.join(tmpExtract, '.claudeflow');
68
- const dstActiveModePath = path.join(cwd, '.claudeflow', 'active-mode');
69
- const zipActiveModePath = path.join(srcClaudeflow, 'active-mode');
70
- let activeMode = 'normal';
71
- if (fs.existsSync(dstActiveModePath)) {
72
- activeMode = fs.readFileSync(dstActiveModePath, 'utf8').trim() || 'normal';
73
- } else if (fs.existsSync(zipActiveModePath)) {
74
- activeMode = fs.readFileSync(zipActiveModePath, 'utf8').trim() || 'normal';
75
- }
76
- const srcClaude = path.join(srcClaudeflow, 'variants', activeMode);
77
- const nextManagedPaths = collectManagedPathsFromRelease(tmpExtract, activeMode);
68
+ // v2.13.148+: mode is per-build, not per-project. There are no more
69
+ // variants/{boost,normal} directories the template ships a single
70
+ // .claude/ tree, and claudeflow-build asks "fast or normal?" at each
71
+ // invocation. So we source directly from the zip's .claude/ root.
72
+ const srcClaude = path.join(tmpExtract, '.claude');
73
+ const nextManagedPaths = collectManagedPathsFromRelease(tmpExtract);
78
74
  const previousManifest = readTemplateManagedManifest(cwd);
79
75
  const previousManagedPaths = previousManifest
80
76
  ? previousManifest.managedPaths
@@ -219,32 +215,10 @@ async function run() {
219
215
  }
220
216
  }
221
217
 
222
- // Copy variant-switch CLI (claudeflow-mode.js + helpers used by the
223
- // /claudeflow-mode slash command to rotate .claude/ between boost and
224
- // normal variants).
225
- const srcCli = path.join(srcClaudeflow, 'cli');
226
- const dstCli = path.join(cwd, '.claudeflow', 'cli');
227
- if (fs.existsSync(srcCli)) {
228
- copyDirSync(srcCli, dstCli);
229
- }
230
-
231
- // Copy variants (boost + normal). The /claudeflow-mode command rotates
232
- // the active .claude/ between these. Each variant is a complete
233
- // .claude/-shaped tree (skills, hooks, agents, commands, settings).
234
- const srcVariants = path.join(srcClaudeflow, 'variants');
235
- const dstVariants = path.join(cwd, '.claudeflow', 'variants');
236
- if (fs.existsSync(srcVariants)) {
237
- copyDirSync(srcVariants, dstVariants);
238
- }
239
-
240
- // Copy active-mode marker only when the project doesn't have one yet.
241
- // Preserves the user's current mode (boost | normal) across updates —
242
- // overwriting would silently rotate them back to the shipped default.
243
- const srcActiveMode = path.join(srcClaudeflow, 'active-mode');
244
- const dstActiveMode = path.join(cwd, '.claudeflow', 'active-mode');
245
- if (fs.existsSync(srcActiveMode) && !fs.existsSync(dstActiveMode)) {
246
- fs.copyFileSync(srcActiveMode, dstActiveMode);
247
- }
218
+ // v2.13.148+: variants/ and active-mode were removed. Mode (fast/normal)
219
+ // is now per-build, persisted in workflow-state.runs[run_id].top_level.mode.
220
+ // The user picks the mode via AskUserQuestion at every claudeflow-build
221
+ // invocation. No global project-level mode marker.
248
222
 
249
223
  // Write version file
250
224
  writeLocalVersion(version);
@@ -974,9 +948,10 @@ function addFilesFromDir(set, rootBase, targetDir, opts = {}) {
974
948
  }
975
949
  }
976
950
 
977
- function collectManagedPathsFromRelease(extractRoot, mode = 'normal') {
951
+ function collectManagedPathsFromRelease(extractRoot) {
978
952
  const srcClaudeflow = path.join(extractRoot, '.claudeflow');
979
- const srcClaude = path.join(srcClaudeflow, 'variants', mode);
953
+ // v2.13.148+: single .claude/ tree at the zip root, no variants.
954
+ const srcClaude = path.join(extractRoot, '.claude');
980
955
  const managed = new Set();
981
956
 
982
957
  const settingsPath = path.join(srcClaude, 'settings.json');
@@ -984,25 +959,16 @@ function collectManagedPathsFromRelease(extractRoot, mode = 'normal') {
984
959
  managed.add('.claude/settings.json');
985
960
  }
986
961
 
987
- // Claude Code native dirs: hooks stay in .claude/. Source from the variant
988
- // but record paths under the install destination (.claude/hooks/...) so
989
- // stale-pruning resolves correctly against the user's project.
990
962
  addFilesFromDir(managed, extractRoot, path.join(srcClaude, 'hooks'), {
991
963
  destPrefix: '.claude/hooks',
992
964
  });
993
965
 
994
- // Claudeflow dirs: runtime, templates, docs, cli, variants in .claudeflow/
995
- ['runtime', 'templates', 'docs', 'cli', 'variants'].forEach((folder) => {
966
+ // Claudeflow dirs: runtime, templates, docs, cli in .claudeflow/.
967
+ // (variants/ removed in v2.13.148.)
968
+ ['runtime', 'templates', 'docs', 'cli'].forEach((folder) => {
996
969
  addFilesFromDir(managed, extractRoot, path.join(srcClaudeflow, folder));
997
970
  });
998
971
 
999
- // Root-level marker file for the active variant (boost | normal).
1000
- // Required so `/claudeflow-mode` can report the current mode after install.
1001
- const activeModePath = path.join(srcClaudeflow, 'active-mode');
1002
- if (fs.existsSync(activeModePath)) {
1003
- managed.add('.claudeflow/active-mode');
1004
- }
1005
-
1006
972
  const skillsDir = path.join(srcClaude, 'skills');
1007
973
  if (fs.existsSync(skillsDir)) {
1008
974
  const entries = fs.readdirSync(skillsDir, { withFileTypes: true });
@@ -1057,8 +1023,9 @@ function collectLegacyManagedPathsFromDisk(projectRoot) {
1057
1023
  // Claude Code native: hooks stay in .claude/
1058
1024
  addFilesFromDir(managed, projectRoot, path.join(claudeDir, 'hooks'));
1059
1025
 
1060
- // Claudeflow dirs: runtime, templates, docs, cli, variants in .claudeflow/
1061
- ['runtime', 'templates', 'docs', 'cli', 'variants'].forEach((folder) => {
1026
+ // Claudeflow dirs: runtime, templates, docs, cli in .claudeflow/
1027
+ // (variants/ removed in v2.13.148.)
1028
+ ['runtime', 'templates', 'docs', 'cli'].forEach((folder) => {
1062
1029
  addFilesFromDir(managed, projectRoot, path.join(claudeflowDir, folder));
1063
1030
  });
1064
1031
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@axiomatic-labs/claudeflow",
3
- "version": "2.13.146",
3
+ "version": "2.13.149",
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"