@codyswann/lisa 2.146.0 → 2.147.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.
Files changed (63) hide show
  1. package/package.json +1 -1
  2. package/plugins/lisa/.claude-plugin/plugin.json +1 -1
  3. package/plugins/lisa/.codex-plugin/plugin.json +1 -1
  4. package/plugins/lisa-agy/plugin.json +1 -1
  5. package/plugins/lisa-cdk/.claude-plugin/plugin.json +1 -1
  6. package/plugins/lisa-cdk/.codex-plugin/plugin.json +1 -1
  7. package/plugins/lisa-cdk-agy/plugin.json +1 -1
  8. package/plugins/lisa-cdk-copilot/.claude-plugin/plugin.json +1 -1
  9. package/plugins/lisa-cdk-cursor/.claude-plugin/plugin.json +1 -1
  10. package/plugins/lisa-copilot/.claude-plugin/plugin.json +1 -1
  11. package/plugins/lisa-cursor/.claude-plugin/plugin.json +1 -1
  12. package/plugins/lisa-expo/.claude-plugin/plugin.json +1 -1
  13. package/plugins/lisa-expo/.codex-plugin/plugin.json +1 -1
  14. package/plugins/lisa-expo-agy/plugin.json +1 -1
  15. package/plugins/lisa-expo-copilot/.claude-plugin/plugin.json +1 -1
  16. package/plugins/lisa-expo-cursor/.claude-plugin/plugin.json +1 -1
  17. package/plugins/lisa-harper-fabric/.claude-plugin/plugin.json +1 -1
  18. package/plugins/lisa-harper-fabric/.codex-plugin/plugin.json +1 -1
  19. package/plugins/lisa-harper-fabric-agy/plugin.json +1 -1
  20. package/plugins/lisa-harper-fabric-copilot/.claude-plugin/plugin.json +1 -1
  21. package/plugins/lisa-harper-fabric-cursor/.claude-plugin/plugin.json +1 -1
  22. package/plugins/lisa-nestjs/.claude-plugin/plugin.json +1 -1
  23. package/plugins/lisa-nestjs/.codex-plugin/plugin.json +1 -1
  24. package/plugins/lisa-nestjs-agy/plugin.json +1 -1
  25. package/plugins/lisa-nestjs-copilot/.claude-plugin/plugin.json +1 -1
  26. package/plugins/lisa-nestjs-cursor/.claude-plugin/plugin.json +1 -1
  27. package/plugins/lisa-openclaw/.claude-plugin/plugin.json +1 -1
  28. package/plugins/lisa-openclaw/.codex-plugin/plugin.json +1 -1
  29. package/plugins/lisa-openclaw-agy/plugin.json +1 -1
  30. package/plugins/lisa-openclaw-copilot/.claude-plugin/plugin.json +1 -1
  31. package/plugins/lisa-openclaw-cursor/.claude-plugin/plugin.json +1 -1
  32. package/plugins/lisa-rails/.claude-plugin/plugin.json +1 -1
  33. package/plugins/lisa-rails/.codex-plugin/plugin.json +1 -1
  34. package/plugins/lisa-rails-agy/plugin.json +1 -1
  35. package/plugins/lisa-rails-copilot/.claude-plugin/plugin.json +1 -1
  36. package/plugins/lisa-rails-cursor/.claude-plugin/plugin.json +1 -1
  37. package/plugins/lisa-typescript/.claude-plugin/plugin.json +1 -1
  38. package/plugins/lisa-typescript/.codex-plugin/plugin.json +1 -1
  39. package/plugins/lisa-typescript-agy/plugin.json +1 -1
  40. package/plugins/lisa-typescript-copilot/.claude-plugin/plugin.json +1 -1
  41. package/plugins/lisa-typescript-cursor/.claude-plugin/plugin.json +1 -1
  42. package/plugins/lisa-wiki/.claude-plugin/plugin.json +1 -1
  43. package/plugins/lisa-wiki/.codex-plugin/plugin.json +1 -1
  44. package/plugins/lisa-wiki/schema/lisa-wiki-config.schema.json +46 -2
  45. package/plugins/lisa-wiki/scripts/lint-wiki.mjs +137 -0
  46. package/plugins/lisa-wiki/scripts/validate-config.mjs +89 -0
  47. package/plugins/lisa-wiki-agy/plugin.json +1 -1
  48. package/plugins/lisa-wiki-agy/schema/lisa-wiki-config.schema.json +46 -2
  49. package/plugins/lisa-wiki-agy/scripts/lint-wiki.mjs +137 -0
  50. package/plugins/lisa-wiki-agy/scripts/validate-config.mjs +89 -0
  51. package/plugins/lisa-wiki-copilot/.claude-plugin/plugin.json +1 -1
  52. package/plugins/lisa-wiki-copilot/schema/lisa-wiki-config.schema.json +46 -2
  53. package/plugins/lisa-wiki-copilot/scripts/lint-wiki.mjs +137 -0
  54. package/plugins/lisa-wiki-copilot/scripts/validate-config.mjs +89 -0
  55. package/plugins/lisa-wiki-cursor/.claude-plugin/plugin.json +1 -1
  56. package/plugins/lisa-wiki-cursor/schema/lisa-wiki-config.schema.json +46 -2
  57. package/plugins/lisa-wiki-cursor/scripts/lint-wiki.mjs +137 -0
  58. package/plugins/lisa-wiki-cursor/scripts/validate-config.mjs +89 -0
  59. package/plugins/src/wiki/schema/lisa-wiki-config.schema.json +46 -2
  60. package/plugins/src/wiki/scripts/lint-wiki.mjs +137 -0
  61. package/plugins/src/wiki/scripts/validate-config.mjs +89 -0
  62. package/scripts/install-claude-plugins.sh +31 -0
  63. package/all/copy-overwrite/.safety-net.json +0 -25
@@ -22,6 +22,17 @@ const RETENTION = [
22
22
  "external-pointer-only",
23
23
  ];
24
24
  const SENSITIVITY = ["public", "internal", "confidential", "restricted"];
25
+ const REDACTION_ENTITIES = [
26
+ "api_key",
27
+ "bank_account",
28
+ "credit_card",
29
+ "oauth_token",
30
+ "password",
31
+ "private_key",
32
+ "routing_number",
33
+ "ssn",
34
+ ];
35
+ const REDACTION_SCANNERS = ["builtin", "gitleaks", "presidio"];
25
36
  const SOURCE_LAYOUT = ["by-system", "by-category"];
26
37
  const README_MODE = ["rich", "stub", "preserve"];
27
38
 
@@ -49,6 +60,14 @@ function checkType(value, type, label) {
49
60
  );
50
61
  }
51
62
  }
63
+ function checkKnownKeys(object, allowed, label) {
64
+ if (!isObject(object)) return;
65
+ for (const key of Object.keys(object)) {
66
+ if (!allowed.includes(key)) {
67
+ err(`${label}.${key}: unknown field`);
68
+ }
69
+ }
70
+ }
52
71
 
53
72
  if (!fs.existsSync(configPath)) {
54
73
  console.error(`✗ config not found: ${configPath}`);
@@ -123,8 +142,78 @@ if (config.readme !== undefined) {
123
142
  if (config.sensitivity !== undefined) {
124
143
  if (!isObject(config.sensitivity)) err("sensitivity: must be an object");
125
144
  else {
145
+ checkKnownKeys(
146
+ config.sensitivity,
147
+ ["enabled", "default", "redaction"],
148
+ "sensitivity"
149
+ );
126
150
  checkType(config.sensitivity.enabled, "boolean", "sensitivity.enabled");
127
151
  checkEnum(config.sensitivity.default, SENSITIVITY, "sensitivity.default");
152
+ if (config.sensitivity.redaction !== undefined) {
153
+ if (!isObject(config.sensitivity.redaction)) {
154
+ err("sensitivity.redaction: must be an object");
155
+ } else {
156
+ const redaction = config.sensitivity.redaction;
157
+ checkKnownKeys(
158
+ redaction,
159
+ [
160
+ "enabled",
161
+ "scanners",
162
+ "failClosed",
163
+ "requireReview",
164
+ "allowedEntities",
165
+ "blockedEntities",
166
+ ],
167
+ "sensitivity.redaction"
168
+ );
169
+ checkType(
170
+ redaction.enabled,
171
+ "boolean",
172
+ "sensitivity.redaction.enabled"
173
+ );
174
+ checkType(
175
+ redaction.failClosed,
176
+ "boolean",
177
+ "sensitivity.redaction.failClosed"
178
+ );
179
+ checkType(
180
+ redaction.requireReview,
181
+ "boolean",
182
+ "sensitivity.redaction.requireReview"
183
+ );
184
+ if (
185
+ redaction.scanners !== undefined &&
186
+ !(isStringArray(redaction.scanners) && redaction.scanners.length > 0)
187
+ ) {
188
+ err(
189
+ "sensitivity.redaction.scanners: must be a non-empty array of strings"
190
+ );
191
+ }
192
+ const scanners = isStringArray(redaction.scanners)
193
+ ? redaction.scanners
194
+ : [];
195
+ for (const scanner of scanners) {
196
+ checkEnum(
197
+ scanner,
198
+ REDACTION_SCANNERS,
199
+ "sensitivity.redaction.scanners[]"
200
+ );
201
+ }
202
+ for (const key of ["allowedEntities", "blockedEntities"]) {
203
+ if (redaction[key] !== undefined && !isStringArray(redaction[key])) {
204
+ err(`sensitivity.redaction.${key}: must be an array of strings`);
205
+ }
206
+ const entities = isStringArray(redaction[key]) ? redaction[key] : [];
207
+ for (const entity of entities) {
208
+ checkEnum(
209
+ entity,
210
+ REDACTION_ENTITIES,
211
+ `sensitivity.redaction.${key}[]`
212
+ );
213
+ }
214
+ }
215
+ }
216
+ }
128
217
  }
129
218
  }
130
219
  if (config.documentation !== undefined) {
@@ -112,6 +112,37 @@ if changed:
112
112
  PYEOF
113
113
  fi
114
114
 
115
+ # Remove the legacy cc-safety-net inline rules file (self-heal existing projects).
116
+ #
117
+ # Lisa historically shipped a project-root `.safety-net.json` (the cc-safety-net
118
+ # <=0.9.0 inline-rules format) via all/copy-overwrite/. cc-safety-net 1.0.1
119
+ # dropped that format entirely: its PreToolUse Bash guard now treats a
120
+ # project-level `.safety-net.json` as a "legacy rules config location" and FAILS
121
+ # CLOSED — denying EVERY Bash command (even `echo`/`ls`) with "legacy rules
122
+ # config location is no longer used; ask the user to run `npx -y cc-safety-net
123
+ # rule migrate`" — while `rule migrate` cannot convert it (it only looks for a
124
+ # global ~/.cc-safety-net/config.json). The result bricks the agent, and on an
125
+ # unattended/scheduled run there is no human to intervene.
126
+ #
127
+ # 1.0.1 runs fine on its built-in rules with no config file, and Lisa's own
128
+ # block-no-verify.sh + parity-safety-net.sh hooks already enforce --no-verify and
129
+ # destructive-command guards across every agent, so the file is now dead weight.
130
+ # Lisa no longer ships it (removed from all/copy-overwrite/), but copy-overwrite
131
+ # never deletes, so already-provisioned projects keep a stale copy. Remove it
132
+ # here — but ONLY the Lisa-shipped file (identified by its marker rule name), so a
133
+ # project's own hand-authored `.safety-net.json` is never touched.
134
+ LEGACY_SAFETY_NET="$PROJECT_ROOT/.safety-net.json"
135
+ if [ -f "$LEGACY_SAFETY_NET" ] && command -v jq >/dev/null 2>&1; then
136
+ if jq -e '
137
+ (.rules | type == "array")
138
+ and ([.rules[]?.name] | index("block-git-commit-no-verify") != null)
139
+ and ([.rules[]?.name] | index("block-git-push-no-verify") != null)
140
+ ' "$LEGACY_SAFETY_NET" >/dev/null 2>&1; then
141
+ rm -f "$LEGACY_SAFETY_NET" \
142
+ && echo "Removed legacy .safety-net.json (incompatible with cc-safety-net >=1.0.0; using built-in + Lisa-native guards)."
143
+ fi
144
+ fi
145
+
115
146
  # Install plugins only when claude CLI is available
116
147
  if ! command -v claude &>/dev/null; then exit 0; fi
117
148
 
@@ -1,25 +0,0 @@
1
- {
2
- "version": 1,
3
- "rules": [
4
- {
5
- "name": "block-git-commit-no-verify",
6
- "command": "git",
7
- "subcommand": "commit",
8
- "block_args": ["--no-verify", "-n"],
9
- "reason": "--no-verify is not allowed. Fix the commit to pass all checks."
10
- },
11
- {
12
- "name": "block-git-stash",
13
- "command": "git",
14
- "subcommand": "stash",
15
- "reason": "Stashing changes is not allowed. Please commit or discard your changes before stashing. If a commit hook is preventing the commit, either fix whatever is preventing the commit or fail out and let the human know why."
16
- },
17
- {
18
- "name": "block-git-push-no-verify",
19
- "command": "git",
20
- "subcommand": "push",
21
- "block_args": ["--no-verify"],
22
- "reason": "--no-verify is not allowed. Fix the push to pass all checks."
23
- }
24
- ]
25
- }