@codyswann/lisa 1.85.6 → 1.85.7
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/dist/migrations/ensure-lisa-postinstall.d.ts.map +1 -1
- package/dist/migrations/ensure-lisa-postinstall.js +17 -3
- package/dist/migrations/ensure-lisa-postinstall.js.map +1 -1
- package/package.json +1 -1
- package/plugins/lisa/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-cdk/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-expo/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-nestjs/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-rails/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-typescript/.claude-plugin/plugin.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ensure-lisa-postinstall.d.ts","sourceRoot":"","sources":["../../src/migrations/ensure-lisa-postinstall.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EACV,SAAS,EACT,gBAAgB,EAChB,eAAe,EAChB,MAAM,0BAA0B,CAAC;
|
|
1
|
+
{"version":3,"file":"ensure-lisa-postinstall.d.ts","sourceRoot":"","sources":["../../src/migrations/ensure-lisa-postinstall.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EACV,SAAS,EACT,gBAAgB,EAChB,eAAe,EAChB,MAAM,0BAA0B,CAAC;AA0ElC;;;;;;;;;GASG;AACH,qBAAa,8BAA+B,YAAW,SAAS;IAC9D,QAAQ,CAAC,IAAI,6BAA6B;IAC1C,QAAQ,CAAC,WAAW,qEACgD;IAEpE;;;;OAIG;IACG,OAAO,CAAC,GAAG,EAAE,gBAAgB,GAAG,OAAO,CAAC,OAAO,CAAC;IAmBtD;;;;OAIG;IACG,KAAK,CAAC,GAAG,EAAE,gBAAgB,GAAG,OAAO,CAAC,eAAe,CAAC;CAqC7D"}
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import * as path from "node:path";
|
|
2
2
|
import { readJsonOrNull, writeJson } from "../utils/json-utils.js";
|
|
3
3
|
const PACKAGE_JSON = "package.json";
|
|
4
|
-
const
|
|
4
|
+
const CI_GUARD_PREFIX = '[ -n "$CI" ] || ';
|
|
5
|
+
const LISA_INVOCATION = `${CI_GUARD_PREFIX}node node_modules/@codyswann/lisa/dist/index.js --yes --skip-git-check . 2>/dev/null || true`;
|
|
5
6
|
const LISA_MARKER = "node_modules/@codyswann/lisa/dist/index.js";
|
|
6
7
|
/**
|
|
7
8
|
* Project types that do not use Node.js postinstall hooks (e.g. Rails).
|
|
@@ -17,7 +18,15 @@ async function readPackageJson(projectDir) {
|
|
|
17
18
|
return readJsonOrNull(path.join(projectDir, PACKAGE_JSON));
|
|
18
19
|
}
|
|
19
20
|
/**
|
|
20
|
-
*
|
|
21
|
+
* Legacy Lisa invocation pattern (without CI guard). Existing projects may
|
|
22
|
+
* have this form chained with other commands; we detect and replace it so
|
|
23
|
+
* the CI guard is introduced without duplicating the invocation.
|
|
24
|
+
*/
|
|
25
|
+
const LEGACY_LISA_INVOCATION_RE = /node node_modules\/@codyswann\/lisa\/dist\/index\.js --yes --skip-git-check \. 2>\/dev\/null \|\| true/;
|
|
26
|
+
/**
|
|
27
|
+
* Compose the new postinstall, prepending the Lisa invocation to any existing command.
|
|
28
|
+
* If the existing script already contains a legacy Lisa invocation (no CI guard),
|
|
29
|
+
* replace it in place with the guarded invocation rather than duplicating it.
|
|
21
30
|
* @param existing - Existing postinstall script (may be undefined)
|
|
22
31
|
* @returns The composed postinstall script
|
|
23
32
|
*/
|
|
@@ -26,6 +35,9 @@ function composePostinstall(existing) {
|
|
|
26
35
|
if (!trimmed) {
|
|
27
36
|
return LISA_INVOCATION;
|
|
28
37
|
}
|
|
38
|
+
if (trimmed.includes(LISA_MARKER)) {
|
|
39
|
+
return trimmed.replace(LEGACY_LISA_INVOCATION_RE, LISA_INVOCATION);
|
|
40
|
+
}
|
|
29
41
|
return `${LISA_INVOCATION} && ${trimmed}`;
|
|
30
42
|
}
|
|
31
43
|
/**
|
|
@@ -68,7 +80,9 @@ export class EnsureLisaPostinstallMigration {
|
|
|
68
80
|
return false;
|
|
69
81
|
}
|
|
70
82
|
const postinstall = pkg.scripts?.postinstall;
|
|
71
|
-
if (postinstall &&
|
|
83
|
+
if (postinstall &&
|
|
84
|
+
postinstall.includes(LISA_MARKER) &&
|
|
85
|
+
postinstall.includes(CI_GUARD_PREFIX)) {
|
|
72
86
|
return false;
|
|
73
87
|
}
|
|
74
88
|
return true;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ensure-lisa-postinstall.js","sourceRoot":"","sources":["../../src/migrations/ensure-lisa-postinstall.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,IAAI,MAAM,WAAW,CAAC;AAElC,OAAO,EAAE,cAAc,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAC;AAOnE,MAAM,YAAY,GAAG,cAAc,CAAC;AACpC,MAAM,eAAe,
|
|
1
|
+
{"version":3,"file":"ensure-lisa-postinstall.js","sourceRoot":"","sources":["../../src/migrations/ensure-lisa-postinstall.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,IAAI,MAAM,WAAW,CAAC;AAElC,OAAO,EAAE,cAAc,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAC;AAOnE,MAAM,YAAY,GAAG,cAAc,CAAC;AACpC,MAAM,eAAe,GAAG,kBAAkB,CAAC;AAC3C,MAAM,eAAe,GAAG,GAAG,eAAe,8FAA8F,CAAC;AACzI,MAAM,WAAW,GAAG,4CAA4C,CAAC;AAEjE;;;GAGG;AACH,MAAM,cAAc,GAA2B,CAAC,OAAO,CAAC,CAAC;AAUzD;;;;GAIG;AACH,KAAK,UAAU,eAAe,CAC5B,UAAkB;IAElB,OAAO,cAAc,CAAc,IAAI,CAAC,IAAI,CAAC,UAAU,EAAE,YAAY,CAAC,CAAC,CAAC;AAC1E,CAAC;AAED;;;;GAIG;AACH,MAAM,yBAAyB,G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AAE,SAAS;YACjB,YAAY,EAAE,CAAC,YAAY,CAAC;YAC5B,OAAO;SACR,CAAC;IACJ,CAAC;CACF"}
|
package/package.json
CHANGED
|
@@ -78,7 +78,7 @@
|
|
|
78
78
|
"lodash": ">=4.18.1"
|
|
79
79
|
},
|
|
80
80
|
"name": "@codyswann/lisa",
|
|
81
|
-
"version": "1.85.
|
|
81
|
+
"version": "1.85.7",
|
|
82
82
|
"description": "Claude Code governance framework that applies guardrails, guidance, and automated enforcement to projects",
|
|
83
83
|
"main": "dist/index.js",
|
|
84
84
|
"exports": {
|