@codyswann/lisa 3.29.0 → 3.29.2
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/core/upstream-evidence-manifest.d.ts.map +1 -1
- package/dist/core/upstream-evidence-manifest.js +3 -2
- package/dist/core/upstream-evidence-manifest.js.map +1 -1
- package/dist/health/ruleset-inspection.d.ts.map +1 -1
- package/dist/health/ruleset-inspection.js +104 -3
- package/dist/health/ruleset-inspection.js.map +1 -1
- package/package.json +1 -1
- package/plugins/lisa/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa/.codex-plugin/plugin.json +1 -1
- package/plugins/lisa-agy/plugin.json +1 -1
- package/plugins/lisa-cdk/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-cdk/.codex-plugin/plugin.json +1 -1
- package/plugins/lisa-cdk-agy/plugin.json +1 -1
- package/plugins/lisa-cdk-copilot/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-cdk-cursor/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-copilot/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-cursor/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-expo/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-expo/.codex-plugin/plugin.json +1 -1
- package/plugins/lisa-expo-agy/plugin.json +1 -1
- package/plugins/lisa-expo-copilot/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-expo-cursor/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-harper-fabric/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-harper-fabric/.codex-plugin/plugin.json +1 -1
- package/plugins/lisa-harper-fabric-agy/plugin.json +1 -1
- package/plugins/lisa-harper-fabric-copilot/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-harper-fabric-cursor/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-nestjs/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-nestjs/.codex-plugin/plugin.json +1 -1
- package/plugins/lisa-nestjs-agy/plugin.json +1 -1
- package/plugins/lisa-nestjs-copilot/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-nestjs-cursor/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-openclaw/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-openclaw/.codex-plugin/plugin.json +1 -1
- package/plugins/lisa-openclaw-agy/plugin.json +1 -1
- package/plugins/lisa-openclaw-copilot/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-openclaw-cursor/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-phaser/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-phaser/.codex-plugin/plugin.json +1 -1
- package/plugins/lisa-phaser-agy/plugin.json +1 -1
- package/plugins/lisa-phaser-copilot/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-phaser-cursor/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-rails/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-rails/.codex-plugin/plugin.json +1 -1
- package/plugins/lisa-rails-agy/plugin.json +1 -1
- package/plugins/lisa-rails-copilot/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-rails-cursor/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-typescript/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-typescript/.codex-plugin/plugin.json +1 -1
- package/plugins/lisa-typescript-agy/plugin.json +1 -1
- package/plugins/lisa-typescript-copilot/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-typescript-cursor/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-wiki/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-wiki/.codex-plugin/plugin.json +1 -1
- package/plugins/lisa-wiki-agy/plugin.json +1 -1
- package/plugins/lisa-wiki-copilot/.claude-plugin/plugin.json +1 -1
- package/plugins/lisa-wiki-cursor/.claude-plugin/plugin.json +1 -1
- package/scripts/lisa-github-rulesets.sh +51 -0
- package/typescript/copy-overwrite/.lintstagedrc.json +4 -5
|
@@ -427,6 +427,54 @@ add_config_required_checks() {
|
|
|
427
427
|
end'
|
|
428
428
|
}
|
|
429
429
|
|
|
430
|
+
preserve_live_required_checks() {
|
|
431
|
+
local repo="$1"
|
|
432
|
+
local existing_id="$2"
|
|
433
|
+
local json="$3"
|
|
434
|
+
local ruleset_name="$4"
|
|
435
|
+
|
|
436
|
+
if [[ -z "$existing_id" ]]; then
|
|
437
|
+
echo "$json"
|
|
438
|
+
return 0
|
|
439
|
+
fi
|
|
440
|
+
|
|
441
|
+
local live
|
|
442
|
+
if ! live=$(gh api -X GET "repos/$repo/rulesets/$existing_id" 2>/dev/null); then
|
|
443
|
+
log_warning "Could not read existing ruleset '$ruleset_name' details — refusing to silently replace required checks" >&2
|
|
444
|
+
return 1
|
|
445
|
+
fi
|
|
446
|
+
|
|
447
|
+
echo "$json" | jq --argjson live "$live" '
|
|
448
|
+
def required_checks:
|
|
449
|
+
(.rules // [])
|
|
450
|
+
| map(select(.type == "required_status_checks"))
|
|
451
|
+
| .[0].parameters.required_status_checks // [];
|
|
452
|
+
|
|
453
|
+
($live | required_checks) as $live_checks
|
|
454
|
+
| if ($live_checks | length) == 0 then .
|
|
455
|
+
elif ((.rules // []) | map(select(.type == "required_status_checks")) | length) > 0 then
|
|
456
|
+
.rules |= map(
|
|
457
|
+
if .type == "required_status_checks" then
|
|
458
|
+
.parameters.required_status_checks |= (
|
|
459
|
+
. as $expected
|
|
460
|
+
| . + ($live_checks | map(
|
|
461
|
+
select(.context as $c | ($expected | map(.context) | index($c)) | not)
|
|
462
|
+
))
|
|
463
|
+
)
|
|
464
|
+
else . end
|
|
465
|
+
)
|
|
466
|
+
else
|
|
467
|
+
.rules = ((.rules // []) + [{
|
|
468
|
+
type: "required_status_checks",
|
|
469
|
+
parameters: {
|
|
470
|
+
strict_required_status_checks_policy: false,
|
|
471
|
+
do_not_enforce_on_create: true,
|
|
472
|
+
required_status_checks: $live_checks
|
|
473
|
+
}
|
|
474
|
+
}])
|
|
475
|
+
end'
|
|
476
|
+
}
|
|
477
|
+
|
|
430
478
|
apply_ruleset() {
|
|
431
479
|
local repo="$1"
|
|
432
480
|
local template_file="$2"
|
|
@@ -453,6 +501,9 @@ apply_ruleset() {
|
|
|
453
501
|
|
|
454
502
|
local existing_id
|
|
455
503
|
existing_id=$(find_ruleset_by_name "$existing_rulesets" "$ruleset_name")
|
|
504
|
+
if [[ -n "$existing_id" ]]; then
|
|
505
|
+
clean_template=$(preserve_live_required_checks "$repo" "$existing_id" "$clean_template" "$ruleset_name")
|
|
506
|
+
fi
|
|
456
507
|
|
|
457
508
|
if [[ "$DRY_RUN" == "true" ]]; then
|
|
458
509
|
if [[ -n "$existing_id" ]]; then
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
{
|
|
2
|
-
"*.{js,mjs,ts,tsx}": [
|
|
2
|
+
"*.{js,mjs,ts,tsx,jsx}": [
|
|
3
3
|
"oxlint --fix --no-error-on-unmatched-pattern",
|
|
4
4
|
"eslint --quiet --cache --fix --no-error-on-unmatched-pattern --no-warn-ignored",
|
|
5
|
-
"ast-grep scan"
|
|
6
|
-
],
|
|
7
|
-
"*.{json,mjs,js,ts,jsx,tsx,html,md,mdx,css,scss,yaml,yml,graphql}": [
|
|
5
|
+
"ast-grep scan",
|
|
8
6
|
"prettier --write"
|
|
9
|
-
]
|
|
7
|
+
],
|
|
8
|
+
"*.{json,html,md,mdx,css,scss,yaml,yml,graphql}": ["prettier --write"]
|
|
10
9
|
}
|