@axiomatic-labs/claudeflow 2.43.32 → 2.43.34
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 +26 -0
- package/lib/version.js +2 -2
- package/package.json +1 -1
package/lib/install.js
CHANGED
|
@@ -190,6 +190,14 @@ function installFromPayload(src, cwd) {
|
|
|
190
190
|
return out;
|
|
191
191
|
}
|
|
192
192
|
|
|
193
|
+
// `a < b` for `x.y.z` versions (numeric, missing parts = 0). Used to detect a STALE npx-cached CLI.
|
|
194
|
+
function semverLt(a, b) {
|
|
195
|
+
const pa = String(a).split('.').map(n => parseInt(n, 10) || 0);
|
|
196
|
+
const pb = String(b).split('.').map(n => parseInt(n, 10) || 0);
|
|
197
|
+
for (let i = 0; i < 3; i++) { if ((pa[i] || 0) < (pb[i] || 0)) return true; if ((pa[i] || 0) > (pb[i] || 0)) return false; }
|
|
198
|
+
return false;
|
|
199
|
+
}
|
|
200
|
+
|
|
193
201
|
async function run() {
|
|
194
202
|
const current = readLocalVersion();
|
|
195
203
|
ui.banner(current || undefined);
|
|
@@ -205,6 +213,24 @@ async function run() {
|
|
|
205
213
|
const version = (release.tag_name || '').replace(/^v/, '')
|
|
206
214
|
|| asset.name.replace(/^claudeflow-?v?/, '').replace(/\.zip$/, '');
|
|
207
215
|
|
|
216
|
+
// STALE-npx-CACHE GUARD. This CLI binary is whatever npx ran — and `npx <pkg> install` (no @version) will
|
|
217
|
+
// happily REUSE a cached OLD CLI without checking npm for a newer one. An old CLI still downloads the fresh
|
|
218
|
+
// release ZIP (so hooks/playbooks/scripts update — looks like it worked) but its `mergeSettings` predates
|
|
219
|
+
// newer placement logic (e.g. the `env` block merge added after v2.42.0), so config like the agent-teams env
|
|
220
|
+
// vars is SILENTLY skipped — hooks land, env never does. If this CLI's own version is OLDER than the release
|
|
221
|
+
// it's installing, that's exactly the stale-cache case → make it LOUD (the old CLI itself can't, but once a
|
|
222
|
+
// user is on a guarded version this catches every future recurrence).
|
|
223
|
+
let staleCli = false;
|
|
224
|
+
try {
|
|
225
|
+
const cliVersion = require('../package.json').version;
|
|
226
|
+
staleCli = semverLt(cliVersion, version);
|
|
227
|
+
if (staleCli) {
|
|
228
|
+
ui.warn(`Stale CLI: npx is running a CACHED v${cliVersion} but the latest release is v${version}.`);
|
|
229
|
+
ui.warn(` An old CLI updates hooks but can SKIP config (the agent-teams env vars, etc.). To install with`);
|
|
230
|
+
ui.warn(` the matching CLI: ${ui.BOLD}npx @axiomatic-labs/claudeflow@latest install${ui.RESET} (or clear the npx cache: ${ui.BOLD}npx clear-npx-cache${ui.RESET}).`);
|
|
231
|
+
}
|
|
232
|
+
} catch {}
|
|
233
|
+
|
|
208
234
|
ui.step(`Downloading ${asset.name}...`);
|
|
209
235
|
const zipBuffer = await downloadReleaseAsset(asset, token);
|
|
210
236
|
|
package/lib/version.js
CHANGED
|
@@ -31,7 +31,7 @@ async function run() {
|
|
|
31
31
|
if (local) {
|
|
32
32
|
ui.info(`Installed: ${local}`);
|
|
33
33
|
} else {
|
|
34
|
-
ui.warn('Not installed. Run: npx @axiomatic-labs/claudeflow install');
|
|
34
|
+
ui.warn('Not installed. Run: npx @axiomatic-labs/claudeflow@latest install');
|
|
35
35
|
}
|
|
36
36
|
|
|
37
37
|
const token = getGitHubToken();
|
|
@@ -50,7 +50,7 @@ async function run() {
|
|
|
50
50
|
if (local && local === latest) {
|
|
51
51
|
ui.success('Up to date.');
|
|
52
52
|
} else if (local) {
|
|
53
|
-
ui.warn('Update available. Run: npx @axiomatic-labs/claudeflow install');
|
|
53
|
+
ui.warn('Update available. Run: npx @axiomatic-labs/claudeflow@latest install (the @latest avoids a stale npx cache)');
|
|
54
54
|
}
|
|
55
55
|
} catch (err) {
|
|
56
56
|
ui.error(`Could not fetch latest release: ${err.message}`);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@axiomatic-labs/claudeflow",
|
|
3
|
-
"version": "2.43.
|
|
3
|
+
"version": "2.43.34",
|
|
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"
|