@vibe-agent-toolkit/cli 0.2.0-rc.11 → 0.2.0-rc.12
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/README.md +3 -3
- package/dist/bin/supervise-cli.d.ts +45 -0
- package/dist/bin/supervise-cli.d.ts.map +1 -0
- package/dist/bin/supervise-cli.js +83 -0
- package/dist/bin/supervise-cli.js.map +1 -0
- package/dist/bin/vat +95 -43
- package/dist/bin/vat.d.ts +15 -4
- package/dist/bin/vat.d.ts.map +1 -1
- package/dist/bin/vat.js +95 -43
- package/dist/bin/vat.js.map +1 -1
- package/dist/bin.js +21 -29
- package/dist/bin.js.map +1 -1
- package/dist/command-tree.d.ts +45 -0
- package/dist/command-tree.d.ts.map +1 -0
- package/dist/command-tree.js +60 -0
- package/dist/command-tree.js.map +1 -0
- package/dist/commands/agent/build-schema.d.ts +100 -0
- package/dist/commands/agent/build-schema.d.ts.map +1 -0
- package/dist/commands/agent/build-schema.js +32 -0
- package/dist/commands/agent/build-schema.js.map +1 -0
- package/dist/commands/agent/build.d.ts +1 -0
- package/dist/commands/agent/build.d.ts.map +1 -1
- package/dist/commands/agent/build.js +63 -33
- package/dist/commands/agent/build.js.map +1 -1
- package/dist/commands/agent/import-schema.d.ts +75 -0
- package/dist/commands/agent/import-schema.d.ts.map +1 -0
- package/dist/commands/agent/import-schema.js +25 -0
- package/dist/commands/agent/import-schema.js.map +1 -0
- package/dist/commands/agent/import.d.ts.map +1 -1
- package/dist/commands/agent/import.js +33 -27
- package/dist/commands/agent/import.js.map +1 -1
- package/dist/commands/agent/index.d.ts.map +1 -1
- package/dist/commands/agent/index.js +132 -37
- package/dist/commands/agent/index.js.map +1 -1
- package/dist/commands/agent/install-path.d.ts.map +1 -1
- package/dist/commands/agent/install-path.js +2 -1
- package/dist/commands/agent/install-path.js.map +1 -1
- package/dist/commands/agent/install-schema.d.ts +89 -0
- package/dist/commands/agent/install-schema.d.ts.map +1 -0
- package/dist/commands/agent/install-schema.js +29 -0
- package/dist/commands/agent/install-schema.js.map +1 -0
- package/dist/commands/agent/install.d.ts +7 -1
- package/dist/commands/agent/install.d.ts.map +1 -1
- package/dist/commands/agent/install.js +78 -108
- package/dist/commands/agent/install.js.map +1 -1
- package/dist/commands/agent/installed-schema.d.ts +140 -0
- package/dist/commands/agent/installed-schema.d.ts.map +1 -0
- package/dist/commands/agent/installed-schema.js +36 -0
- package/dist/commands/agent/installed-schema.js.map +1 -0
- package/dist/commands/agent/installed.d.ts +1 -1
- package/dist/commands/agent/installed.d.ts.map +1 -1
- package/dist/commands/agent/installed.js +104 -75
- package/dist/commands/agent/installed.js.map +1 -1
- package/dist/commands/agent/list-schema.d.ts +128 -0
- package/dist/commands/agent/list-schema.d.ts.map +1 -0
- package/dist/commands/agent/list-schema.js +34 -0
- package/dist/commands/agent/list-schema.js.map +1 -0
- package/dist/commands/agent/list.d.ts +4 -3
- package/dist/commands/agent/list.d.ts.map +1 -1
- package/dist/commands/agent/list.js +50 -37
- package/dist/commands/agent/list.js.map +1 -1
- package/dist/commands/agent/run.d.ts +3 -0
- package/dist/commands/agent/run.d.ts.map +1 -1
- package/dist/commands/agent/run.js +8 -3
- package/dist/commands/agent/run.js.map +1 -1
- package/dist/commands/agent/uninstall-schema.d.ts +89 -0
- package/dist/commands/agent/uninstall-schema.d.ts.map +1 -0
- package/dist/commands/agent/uninstall-schema.js +29 -0
- package/dist/commands/agent/uninstall-schema.js.map +1 -0
- package/dist/commands/agent/uninstall.d.ts +5 -1
- package/dist/commands/agent/uninstall.d.ts.map +1 -1
- package/dist/commands/agent/uninstall.js +50 -38
- package/dist/commands/agent/uninstall.js.map +1 -1
- package/dist/commands/agent/validate-schema.d.ts +129 -0
- package/dist/commands/agent/validate-schema.d.ts.map +1 -0
- package/dist/commands/agent/validate-schema.js +35 -0
- package/dist/commands/agent/validate-schema.js.map +1 -0
- package/dist/commands/agent/validate.d.ts +6 -0
- package/dist/commands/agent/validate.d.ts.map +1 -1
- package/dist/commands/agent/validate.js +64 -36
- package/dist/commands/agent/validate.js.map +1 -1
- package/dist/commands/ard/emit-schema.d.ts +108 -0
- package/dist/commands/ard/emit-schema.d.ts.map +1 -0
- package/dist/commands/ard/emit-schema.js +37 -0
- package/dist/commands/ard/emit-schema.js.map +1 -0
- package/dist/commands/ard/emit.d.ts +21 -65
- package/dist/commands/ard/emit.d.ts.map +1 -1
- package/dist/commands/ard/emit.js +68 -74
- package/dist/commands/ard/emit.js.map +1 -1
- package/dist/commands/ard/index.d.ts.map +1 -1
- package/dist/commands/ard/index.js +14 -11
- package/dist/commands/ard/index.js.map +1 -1
- package/dist/commands/audit/compat-lane-findings.d.ts +65 -0
- package/dist/commands/audit/compat-lane-findings.d.ts.map +1 -0
- package/dist/commands/audit/compat-lane-findings.js +72 -0
- package/dist/commands/audit/compat-lane-findings.js.map +1 -0
- package/dist/commands/audit/distributed-tree.d.ts +2 -2
- package/dist/commands/audit/distributed-tree.d.ts.map +1 -1
- package/dist/commands/audit/distributed-tree.js +23 -12
- package/dist/commands/audit/distributed-tree.js.map +1 -1
- package/dist/commands/audit/git-url-clone.d.ts +15 -7
- package/dist/commands/audit/git-url-clone.d.ts.map +1 -1
- package/dist/commands/audit/git-url-clone.js +85 -42
- package/dist/commands/audit/git-url-clone.js.map +1 -1
- package/dist/commands/audit/hierarchical-output.d.ts +28 -4
- package/dist/commands/audit/hierarchical-output.d.ts.map +1 -1
- package/dist/commands/audit/hierarchical-output.js +44 -27
- package/dist/commands/audit/hierarchical-output.js.map +1 -1
- package/dist/commands/audit/scan-population.d.ts.map +1 -1
- package/dist/commands/audit/scan-population.js +2 -1
- package/dist/commands/audit/scan-population.js.map +1 -1
- package/dist/commands/audit-schema.d.ts +1247 -0
- package/dist/commands/audit-schema.d.ts.map +1 -0
- package/dist/commands/audit-schema.js +139 -0
- package/dist/commands/audit-schema.js.map +1 -0
- package/dist/commands/audit-settings-schema.d.ts +417 -0
- package/dist/commands/audit-settings-schema.d.ts.map +1 -0
- package/dist/commands/audit-settings-schema.js +77 -0
- package/dist/commands/audit-settings-schema.js.map +1 -0
- package/dist/commands/audit-settings.d.ts +28 -9
- package/dist/commands/audit-settings.d.ts.map +1 -1
- package/dist/commands/audit-settings.js +215 -151
- package/dist/commands/audit-settings.js.map +1 -1
- package/dist/commands/audit.d.ts +72 -33
- package/dist/commands/audit.d.ts.map +1 -1
- package/dist/commands/audit.js +405 -411
- package/dist/commands/audit.js.map +1 -1
- package/dist/commands/build.d.ts +61 -4
- package/dist/commands/build.d.ts.map +1 -1
- package/dist/commands/build.js +176 -190
- package/dist/commands/build.js.map +1 -1
- package/dist/commands/cache/clear-schema.d.ts +111 -0
- package/dist/commands/cache/clear-schema.d.ts.map +1 -0
- package/dist/commands/cache/clear-schema.js +37 -0
- package/dist/commands/cache/clear-schema.js.map +1 -0
- package/dist/commands/cache/clear.d.ts +28 -26
- package/dist/commands/cache/clear.d.ts.map +1 -1
- package/dist/commands/cache/clear.js +108 -103
- package/dist/commands/cache/clear.js.map +1 -1
- package/dist/commands/cache/index.d.ts.map +1 -1
- package/dist/commands/cache/index.js +13 -7
- package/dist/commands/cache/index.js.map +1 -1
- package/dist/commands/claude/claude-config.d.ts +23 -6
- package/dist/commands/claude/claude-config.d.ts.map +1 -1
- package/dist/commands/claude/claude-config.js +29 -15
- package/dist/commands/claude/claude-config.js.map +1 -1
- package/dist/commands/claude/context.d.ts +55 -2
- package/dist/commands/claude/context.d.ts.map +1 -1
- package/dist/commands/claude/context.js +74 -50
- package/dist/commands/claude/context.js.map +1 -1
- package/dist/commands/claude/marketplace/changelog-utils.js +2 -2
- package/dist/commands/claude/marketplace/changelog-utils.js.map +1 -1
- package/dist/commands/claude/marketplace/git-publish.d.ts +14 -1
- package/dist/commands/claude/marketplace/git-publish.d.ts.map +1 -1
- package/dist/commands/claude/marketplace/git-publish.js +135 -68
- package/dist/commands/claude/marketplace/git-publish.js.map +1 -1
- package/dist/commands/claude/marketplace/license-utils.d.ts +3 -5
- package/dist/commands/claude/marketplace/license-utils.d.ts.map +1 -1
- package/dist/commands/claude/marketplace/license-utils.js +16 -7
- package/dist/commands/claude/marketplace/license-utils.js.map +1 -1
- package/dist/commands/claude/marketplace/publish-schema.d.ts +137 -0
- package/dist/commands/claude/marketplace/publish-schema.d.ts.map +1 -0
- package/dist/commands/claude/marketplace/publish-schema.js +32 -0
- package/dist/commands/claude/marketplace/publish-schema.js.map +1 -0
- package/dist/commands/claude/marketplace/publish-tree.d.ts +6 -0
- package/dist/commands/claude/marketplace/publish-tree.d.ts.map +1 -1
- package/dist/commands/claude/marketplace/publish-tree.js +75 -17
- package/dist/commands/claude/marketplace/publish-tree.js.map +1 -1
- package/dist/commands/claude/marketplace/publish.d.ts +27 -0
- package/dist/commands/claude/marketplace/publish.d.ts.map +1 -1
- package/dist/commands/claude/marketplace/publish.js +84 -50
- package/dist/commands/claude/marketplace/publish.js.map +1 -1
- package/dist/commands/claude/marketplace/validate-schema.d.ts +362 -0
- package/dist/commands/claude/marketplace/validate-schema.d.ts.map +1 -0
- package/dist/commands/claude/marketplace/validate-schema.js +67 -0
- package/dist/commands/claude/marketplace/validate-schema.js.map +1 -0
- package/dist/commands/claude/marketplace/validate.d.ts +40 -53
- package/dist/commands/claude/marketplace/validate.d.ts.map +1 -1
- package/dist/commands/claude/marketplace/validate.js +358 -214
- package/dist/commands/claude/marketplace/validate.js.map +1 -1
- package/dist/commands/claude/org/api-keys.d.ts +3 -0
- package/dist/commands/claude/org/api-keys.d.ts.map +1 -1
- package/dist/commands/claude/org/api-keys.js +4 -5
- package/dist/commands/claude/org/api-keys.js.map +1 -1
- package/dist/commands/claude/org/code-analytics.js +1 -1
- package/dist/commands/claude/org/code-analytics.js.map +1 -1
- package/dist/commands/claude/org/cost.d.ts.map +1 -1
- package/dist/commands/claude/org/cost.js +11 -33
- package/dist/commands/claude/org/cost.js.map +1 -1
- package/dist/commands/claude/org/helpers.d.ts +40 -27
- package/dist/commands/claude/org/helpers.d.ts.map +1 -1
- package/dist/commands/claude/org/helpers.js +61 -66
- package/dist/commands/claude/org/helpers.js.map +1 -1
- package/dist/commands/claude/org/index.d.ts.map +1 -1
- package/dist/commands/claude/org/index.js +10 -4
- package/dist/commands/claude/org/index.js.map +1 -1
- package/dist/commands/claude/org/info.d.ts.map +1 -1
- package/dist/commands/claude/org/info.js +2 -3
- package/dist/commands/claude/org/info.js.map +1 -1
- package/dist/commands/claude/org/invites.d.ts +3 -0
- package/dist/commands/claude/org/invites.d.ts.map +1 -1
- package/dist/commands/claude/org/invites.js +5 -7
- package/dist/commands/claude/org/invites.js.map +1 -1
- package/dist/commands/claude/org/skills.d.ts +76 -21
- package/dist/commands/claude/org/skills.d.ts.map +1 -1
- package/dist/commands/claude/org/skills.js +273 -246
- package/dist/commands/claude/org/skills.js.map +1 -1
- package/dist/commands/claude/org/stubs-schema.d.ts +56 -0
- package/dist/commands/claude/org/stubs-schema.d.ts.map +1 -0
- package/dist/commands/claude/org/stubs-schema.js +23 -0
- package/dist/commands/claude/org/stubs-schema.js.map +1 -0
- package/dist/commands/claude/org/stubs.d.ts +8 -3
- package/dist/commands/claude/org/stubs.d.ts.map +1 -1
- package/dist/commands/claude/org/stubs.js +9 -9
- package/dist/commands/claude/org/stubs.js.map +1 -1
- package/dist/commands/claude/org/usage.d.ts.map +1 -1
- package/dist/commands/claude/org/usage.js +1 -2
- package/dist/commands/claude/org/usage.js.map +1 -1
- package/dist/commands/claude/org/users.d.ts +3 -0
- package/dist/commands/claude/org/users.d.ts.map +1 -1
- package/dist/commands/claude/org/users.js +6 -8
- package/dist/commands/claude/org/users.js.map +1 -1
- package/dist/commands/claude/org/workspaces.d.ts +3 -0
- package/dist/commands/claude/org/workspaces.d.ts.map +1 -1
- package/dist/commands/claude/org/workspaces.js +10 -15
- package/dist/commands/claude/org/workspaces.js.map +1 -1
- package/dist/commands/claude/plugin/build-schema.d.ts +642 -0
- package/dist/commands/claude/plugin/build-schema.d.ts.map +1 -0
- package/dist/commands/claude/plugin/build-schema.js +51 -0
- package/dist/commands/claude/plugin/build-schema.js.map +1 -0
- package/dist/commands/claude/plugin/build.d.ts +220 -45
- package/dist/commands/claude/plugin/build.d.ts.map +1 -1
- package/dist/commands/claude/plugin/build.js +466 -249
- package/dist/commands/claude/plugin/build.js.map +1 -1
- package/dist/commands/claude/plugin/helpers.d.ts +186 -24
- package/dist/commands/claude/plugin/helpers.d.ts.map +1 -1
- package/dist/commands/claude/plugin/helpers.js +110 -68
- package/dist/commands/claude/plugin/helpers.js.map +1 -1
- package/dist/commands/claude/plugin/install-schema.d.ts +144 -0
- package/dist/commands/claude/plugin/install-schema.d.ts.map +1 -0
- package/dist/commands/claude/plugin/install-schema.js +36 -0
- package/dist/commands/claude/plugin/install-schema.js.map +1 -0
- package/dist/commands/claude/plugin/install.d.ts +191 -11
- package/dist/commands/claude/plugin/install.d.ts.map +1 -1
- package/dist/commands/claude/plugin/install.js +688 -628
- package/dist/commands/claude/plugin/install.js.map +1 -1
- package/dist/commands/claude/plugin/kept-findings.d.ts +19 -0
- package/dist/commands/claude/plugin/kept-findings.d.ts.map +1 -0
- package/dist/commands/claude/plugin/kept-findings.js +24 -0
- package/dist/commands/claude/plugin/kept-findings.js.map +1 -0
- package/dist/commands/claude/plugin/list-schema.d.ts +223 -0
- package/dist/commands/claude/plugin/list-schema.d.ts.map +1 -0
- package/dist/commands/claude/plugin/list-schema.js +34 -0
- package/dist/commands/claude/plugin/list-schema.js.map +1 -0
- package/dist/commands/claude/plugin/list.d.ts +18 -0
- package/dist/commands/claude/plugin/list.d.ts.map +1 -1
- package/dist/commands/claude/plugin/list.js +53 -45
- package/dist/commands/claude/plugin/list.js.map +1 -1
- package/dist/commands/claude/plugin/npm-pack.d.ts +15 -0
- package/dist/commands/claude/plugin/npm-pack.d.ts.map +1 -0
- package/dist/commands/claude/plugin/npm-pack.js +39 -0
- package/dist/commands/claude/plugin/npm-pack.js.map +1 -0
- package/dist/commands/claude/plugin/plugin-changelog.d.ts +5 -1
- package/dist/commands/claude/plugin/plugin-changelog.d.ts.map +1 -1
- package/dist/commands/claude/plugin/plugin-changelog.js +9 -5
- package/dist/commands/claude/plugin/plugin-changelog.js.map +1 -1
- package/dist/commands/claude/plugin/plugin-files.d.ts +21 -2
- package/dist/commands/claude/plugin/plugin-files.d.ts.map +1 -1
- package/dist/commands/claude/plugin/plugin-files.js +65 -32
- package/dist/commands/claude/plugin/plugin-files.js.map +1 -1
- package/dist/commands/claude/plugin/plugin-validators.d.ts +13 -0
- package/dist/commands/claude/plugin/plugin-validators.d.ts.map +1 -1
- package/dist/commands/claude/plugin/plugin-validators.js +64 -16
- package/dist/commands/claude/plugin/plugin-validators.js.map +1 -1
- package/dist/commands/claude/plugin/tree-copy.d.ts.map +1 -1
- package/dist/commands/claude/plugin/tree-copy.js +63 -37
- package/dist/commands/claude/plugin/tree-copy.js.map +1 -1
- package/dist/commands/claude/plugin/uninstall-schema.d.ts +112 -0
- package/dist/commands/claude/plugin/uninstall-schema.d.ts.map +1 -0
- package/dist/commands/claude/plugin/uninstall-schema.js +28 -0
- package/dist/commands/claude/plugin/uninstall-schema.js.map +1 -0
- package/dist/commands/claude/plugin/uninstall.d.ts +57 -0
- package/dist/commands/claude/plugin/uninstall.d.ts.map +1 -1
- package/dist/commands/claude/plugin/uninstall.js +176 -64
- package/dist/commands/claude/plugin/uninstall.js.map +1 -1
- package/dist/commands/consistency-check.d.ts.map +1 -1
- package/dist/commands/consistency-check.js +8 -6
- package/dist/commands/consistency-check.js.map +1 -1
- package/dist/commands/corpus/index.d.ts.map +1 -1
- package/dist/commands/corpus/index.js +26 -10
- package/dist/commands/corpus/index.js.map +1 -1
- package/dist/commands/corpus/report.d.ts +34 -16
- package/dist/commands/corpus/report.d.ts.map +1 -1
- package/dist/commands/corpus/report.js +36 -18
- package/dist/commands/corpus/report.js.map +1 -1
- package/dist/commands/corpus/runner.d.ts +25 -20
- package/dist/commands/corpus/runner.d.ts.map +1 -1
- package/dist/commands/corpus/runner.js +123 -67
- package/dist/commands/corpus/runner.js.map +1 -1
- package/dist/commands/corpus/scan-schema.d.ts +127 -0
- package/dist/commands/corpus/scan-schema.d.ts.map +1 -0
- package/dist/commands/corpus/scan-schema.js +31 -0
- package/dist/commands/corpus/scan-schema.js.map +1 -0
- package/dist/commands/corpus/scan.d.ts +31 -0
- package/dist/commands/corpus/scan.d.ts.map +1 -1
- package/dist/commands/corpus/scan.js +124 -50
- package/dist/commands/corpus/scan.js.map +1 -1
- package/dist/commands/corpus/seed.d.ts +11 -8
- package/dist/commands/corpus/seed.d.ts.map +1 -1
- package/dist/commands/corpus/seed.js +29 -11
- package/dist/commands/corpus/seed.js.map +1 -1
- package/dist/commands/doctor-render.d.ts +52 -0
- package/dist/commands/doctor-render.d.ts.map +1 -0
- package/dist/commands/doctor-render.js +110 -0
- package/dist/commands/doctor-render.js.map +1 -0
- package/dist/commands/doctor-schema.d.ts +191 -0
- package/dist/commands/doctor-schema.d.ts.map +1 -0
- package/dist/commands/doctor-schema.js +44 -0
- package/dist/commands/doctor-schema.js.map +1 -0
- package/dist/commands/doctor.d.ts +7 -62
- package/dist/commands/doctor.d.ts.map +1 -1
- package/dist/commands/doctor.js +126 -165
- package/dist/commands/doctor.js.map +1 -1
- package/dist/commands/inventory-schema.d.ts +7297 -0
- package/dist/commands/inventory-schema.d.ts.map +1 -0
- package/dist/commands/inventory-schema.js +28 -0
- package/dist/commands/inventory-schema.js.map +1 -0
- package/dist/commands/inventory.d.ts +1 -1
- package/dist/commands/inventory.d.ts.map +1 -1
- package/dist/commands/inventory.js +89 -41
- package/dist/commands/inventory.js.map +1 -1
- package/dist/commands/mcp/index.d.ts.map +1 -1
- package/dist/commands/mcp/index.js +15 -0
- package/dist/commands/mcp/index.js.map +1 -1
- package/dist/commands/mcp/list-collections-schema.d.ts +101 -0
- package/dist/commands/mcp/list-collections-schema.d.ts.map +1 -0
- package/dist/commands/mcp/list-collections-schema.js +22 -0
- package/dist/commands/mcp/list-collections-schema.js.map +1 -0
- package/dist/commands/mcp/list-collections.d.ts +1 -1
- package/dist/commands/mcp/list-collections.d.ts.map +1 -1
- package/dist/commands/mcp/list-collections.js +19 -17
- package/dist/commands/mcp/list-collections.js.map +1 -1
- package/dist/commands/mcp/serve.d.ts +5 -0
- package/dist/commands/mcp/serve.d.ts.map +1 -1
- package/dist/commands/mcp/serve.js +29 -15
- package/dist/commands/mcp/serve.js.map +1 -1
- package/dist/commands/okf/index.d.ts.map +1 -1
- package/dist/commands/okf/index.js +6 -5
- package/dist/commands/okf/index.js.map +1 -1
- package/dist/commands/okf/validate-schema.d.ts +171 -0
- package/dist/commands/okf/validate-schema.d.ts.map +1 -0
- package/dist/commands/okf/validate-schema.js +44 -0
- package/dist/commands/okf/validate-schema.js.map +1 -0
- package/dist/commands/okf/validate.d.ts +16 -149
- package/dist/commands/okf/validate.d.ts.map +1 -1
- package/dist/commands/okf/validate.js +64 -62
- package/dist/commands/okf/validate.js.map +1 -1
- package/dist/commands/orchestrator-schema.d.ts +419 -0
- package/dist/commands/orchestrator-schema.d.ts.map +1 -0
- package/dist/commands/orchestrator-schema.js +91 -0
- package/dist/commands/orchestrator-schema.js.map +1 -0
- package/dist/commands/phase-utils.d.ts +188 -220
- package/dist/commands/phase-utils.d.ts.map +1 -1
- package/dist/commands/phase-utils.js +210 -258
- package/dist/commands/phase-utils.js.map +1 -1
- package/dist/commands/positional-args.d.ts +13 -11
- package/dist/commands/positional-args.d.ts.map +1 -1
- package/dist/commands/positional-args.js +16 -15
- package/dist/commands/positional-args.js.map +1 -1
- package/dist/commands/rag/admin-schema.d.ts +152 -0
- package/dist/commands/rag/admin-schema.d.ts.map +1 -0
- package/dist/commands/rag/admin-schema.js +31 -0
- package/dist/commands/rag/admin-schema.js.map +1 -0
- package/dist/commands/rag/clear-command.d.ts.map +1 -1
- package/dist/commands/rag/clear-command.js +30 -15
- package/dist/commands/rag/clear-command.js.map +1 -1
- package/dist/commands/rag/command-helpers.d.ts +31 -7
- package/dist/commands/rag/command-helpers.d.ts.map +1 -1
- package/dist/commands/rag/command-helpers.js +41 -21
- package/dist/commands/rag/command-helpers.js.map +1 -1
- package/dist/commands/rag/index-command.d.ts +37 -48
- package/dist/commands/rag/index-command.d.ts.map +1 -1
- package/dist/commands/rag/index-command.js +80 -65
- package/dist/commands/rag/index-command.js.map +1 -1
- package/dist/commands/rag/index-schema.d.ts +107 -0
- package/dist/commands/rag/index-schema.d.ts.map +1 -0
- package/dist/commands/rag/index-schema.js +34 -0
- package/dist/commands/rag/index-schema.js.map +1 -0
- package/dist/commands/rag/index.d.ts.map +1 -1
- package/dist/commands/rag/index.js +88 -41
- package/dist/commands/rag/index.js.map +1 -1
- package/dist/commands/rag/query-command.d.ts +18 -4
- package/dist/commands/rag/query-command.d.ts.map +1 -1
- package/dist/commands/rag/query-command.js +42 -27
- package/dist/commands/rag/query-command.js.map +1 -1
- package/dist/commands/rag/query-schema.d.ts +363 -0
- package/dist/commands/rag/query-schema.d.ts.map +1 -0
- package/dist/commands/rag/query-schema.js +59 -0
- package/dist/commands/rag/query-schema.js.map +1 -0
- package/dist/commands/rag/stats-command.d.ts.map +1 -1
- package/dist/commands/rag/stats-command.js +19 -18
- package/dist/commands/rag/stats-command.js.map +1 -1
- package/dist/commands/resources/check-progress.d.ts +64 -11
- package/dist/commands/resources/check-progress.d.ts.map +1 -1
- package/dist/commands/resources/check-progress.js +77 -4
- package/dist/commands/resources/check-progress.js.map +1 -1
- package/dist/commands/resources/check-schema.d.ts +335 -0
- package/dist/commands/resources/check-schema.d.ts.map +1 -0
- package/dist/commands/resources/check-schema.js +104 -0
- package/dist/commands/resources/check-schema.js.map +1 -0
- package/dist/commands/resources/check-supervisor.d.ts +315 -71
- package/dist/commands/resources/check-supervisor.d.ts.map +1 -1
- package/dist/commands/resources/check-supervisor.js +493 -107
- package/dist/commands/resources/check-supervisor.js.map +1 -1
- package/dist/commands/resources/check.d.ts +56 -249
- package/dist/commands/resources/check.d.ts.map +1 -1
- package/dist/commands/resources/check.js +416 -276
- package/dist/commands/resources/check.js.map +1 -1
- package/dist/commands/resources/index.d.ts.map +1 -1
- package/dist/commands/resources/index.js +165 -91
- package/dist/commands/resources/index.js.map +1 -1
- package/dist/commands/resources/query-schema.d.ts +188 -0
- package/dist/commands/resources/query-schema.d.ts.map +1 -0
- package/dist/commands/resources/query-schema.js +48 -0
- package/dist/commands/resources/query-schema.js.map +1 -0
- package/dist/commands/resources/query.d.ts +17 -12
- package/dist/commands/resources/query.d.ts.map +1 -1
- package/dist/commands/resources/query.js +60 -48
- package/dist/commands/resources/query.js.map +1 -1
- package/dist/commands/resources/scan-schema.d.ts +195 -0
- package/dist/commands/resources/scan-schema.d.ts.map +1 -0
- package/dist/commands/resources/scan-schema.js +53 -0
- package/dist/commands/resources/scan-schema.js.map +1 -0
- package/dist/commands/resources/scan.d.ts +26 -3
- package/dist/commands/resources/scan.d.ts.map +1 -1
- package/dist/commands/resources/scan.js +51 -53
- package/dist/commands/resources/scan.js.map +1 -1
- package/dist/commands/resources/validate-schema.d.ts +326 -0
- package/dist/commands/resources/validate-schema.d.ts.map +1 -0
- package/dist/commands/resources/validate-schema.js +60 -0
- package/dist/commands/resources/validate-schema.js.map +1 -0
- package/dist/commands/resources/validate.d.ts +45 -169
- package/dist/commands/resources/validate.d.ts.map +1 -1
- package/dist/commands/resources/validate.js +221 -485
- package/dist/commands/resources/validate.js.map +1 -1
- package/dist/commands/skill/review-checklist.d.ts.map +1 -1
- package/dist/commands/skill/review-checklist.js +0 -1
- package/dist/commands/skill/review-checklist.js.map +1 -1
- package/dist/commands/skill/review-schema.d.ts +278 -0
- package/dist/commands/skill/review-schema.d.ts.map +1 -0
- package/dist/commands/skill/review-schema.js +46 -0
- package/dist/commands/skill/review-schema.js.map +1 -0
- package/dist/commands/skill/review.d.ts +8 -234
- package/dist/commands/skill/review.d.ts.map +1 -1
- package/dist/commands/skill/review.js +54 -78
- package/dist/commands/skill/review.js.map +1 -1
- package/dist/commands/skill/test/auth-flags.d.ts +3 -0
- package/dist/commands/skill/test/auth-flags.d.ts.map +1 -1
- package/dist/commands/skill/test/auth-flags.js +6 -2
- package/dist/commands/skill/test/auth-flags.js.map +1 -1
- package/dist/commands/skill/test/configure-schema.d.ts +67 -0
- package/dist/commands/skill/test/configure-schema.d.ts.map +1 -0
- package/dist/commands/skill/test/configure-schema.js +27 -0
- package/dist/commands/skill/test/configure-schema.js.map +1 -0
- package/dist/commands/skill/test/configure.d.ts +12 -5
- package/dist/commands/skill/test/configure.d.ts.map +1 -1
- package/dist/commands/skill/test/configure.js +101 -31
- package/dist/commands/skill/test/configure.js.map +1 -1
- package/dist/commands/skill/test/run-schema.d.ts +107 -0
- package/dist/commands/skill/test/run-schema.d.ts.map +1 -0
- package/dist/commands/skill/test/run-schema.js +36 -0
- package/dist/commands/skill/test/run-schema.js.map +1 -0
- package/dist/commands/skill/test/run.d.ts +3 -2
- package/dist/commands/skill/test/run.d.ts.map +1 -1
- package/dist/commands/skill/test/run.js +316 -155
- package/dist/commands/skill/test/run.js.map +1 -1
- package/dist/commands/skills/build-schema.d.ts +199 -0
- package/dist/commands/skills/build-schema.d.ts.map +1 -0
- package/dist/commands/skills/build-schema.js +55 -0
- package/dist/commands/skills/build-schema.js.map +1 -0
- package/dist/commands/skills/build.d.ts +95 -298
- package/dist/commands/skills/build.d.ts.map +1 -1
- package/dist/commands/skills/build.js +415 -818
- package/dist/commands/skills/build.js.map +1 -1
- package/dist/commands/skills/command-helpers.d.ts +5 -11
- package/dist/commands/skills/command-helpers.d.ts.map +1 -1
- package/dist/commands/skills/command-helpers.js +7 -17
- package/dist/commands/skills/command-helpers.js.map +1 -1
- package/dist/commands/skills/index.js +12 -6
- package/dist/commands/skills/index.js.map +1 -1
- package/dist/commands/skills/install-schema.d.ts +153 -0
- package/dist/commands/skills/install-schema.d.ts.map +1 -0
- package/dist/commands/skills/install-schema.js +44 -0
- package/dist/commands/skills/install-schema.js.map +1 -0
- package/dist/commands/skills/install.d.ts +76 -8
- package/dist/commands/skills/install.d.ts.map +1 -1
- package/dist/commands/skills/install.js +230 -194
- package/dist/commands/skills/install.js.map +1 -1
- package/dist/commands/skills/list-schema.d.ts +145 -0
- package/dist/commands/skills/list-schema.d.ts.map +1 -0
- package/dist/commands/skills/list-schema.js +37 -0
- package/dist/commands/skills/list-schema.js.map +1 -0
- package/dist/commands/skills/list.d.ts +39 -8
- package/dist/commands/skills/list.d.ts.map +1 -1
- package/dist/commands/skills/list.js +110 -122
- package/dist/commands/skills/list.js.map +1 -1
- package/dist/commands/skills/package-schema.d.ts +98 -0
- package/dist/commands/skills/package-schema.d.ts.map +1 -0
- package/dist/commands/skills/package-schema.js +32 -0
- package/dist/commands/skills/package-schema.js.map +1 -0
- package/dist/commands/skills/package.d.ts +85 -14
- package/dist/commands/skills/package.d.ts.map +1 -1
- package/dist/commands/skills/package.js +288 -207
- package/dist/commands/skills/package.js.map +1 -1
- package/dist/commands/skills/scope-guard.d.ts +27 -20
- package/dist/commands/skills/scope-guard.d.ts.map +1 -1
- package/dist/commands/skills/scope-guard.js +43 -32
- package/dist/commands/skills/scope-guard.js.map +1 -1
- package/dist/commands/skills/skill-discovery.d.ts +1 -1
- package/dist/commands/skills/skill-discovery.d.ts.map +1 -1
- package/dist/commands/skills/skill-discovery.js +40 -19
- package/dist/commands/skills/skill-discovery.js.map +1 -1
- package/dist/commands/skills/source-resolvers.d.ts +58 -8
- package/dist/commands/skills/source-resolvers.d.ts.map +1 -1
- package/dist/commands/skills/source-resolvers.js +113 -38
- package/dist/commands/skills/source-resolvers.js.map +1 -1
- package/dist/commands/skills/validate-command.d.ts.map +1 -1
- package/dist/commands/skills/validate-command.js +31 -51
- package/dist/commands/skills/validate-command.js.map +1 -1
- package/dist/commands/skills/validate-schema.d.ts +199 -0
- package/dist/commands/skills/validate-schema.d.ts.map +1 -0
- package/dist/commands/skills/validate-schema.js +44 -0
- package/dist/commands/skills/validate-schema.js.map +1 -0
- package/dist/commands/skills/validate.d.ts +100 -136
- package/dist/commands/skills/validate.d.ts.map +1 -1
- package/dist/commands/skills/validate.js +257 -343
- package/dist/commands/skills/validate.js.map +1 -1
- package/dist/commands/validate.d.ts +17 -5
- package/dist/commands/validate.d.ts.map +1 -1
- package/dist/commands/validate.js +139 -94
- package/dist/commands/validate.js.map +1 -1
- package/dist/commands/verify.d.ts +121 -110
- package/dist/commands/verify.d.ts.map +1 -1
- package/dist/commands/verify.js +230 -294
- package/dist/commands/verify.js.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/report-schemas.d.ts +12398 -35
- package/dist/report-schemas.d.ts.map +1 -1
- package/dist/report-schemas.js +624 -66
- package/dist/report-schemas.js.map +1 -1
- package/dist/skill-resolution/packaging-config.js +2 -2
- package/dist/skill-resolution/packaging-config.js.map +1 -1
- package/dist/skill-resolution/resolve-skill-reference.d.ts.map +1 -1
- package/dist/skill-resolution/resolve-skill-reference.js +20 -13
- package/dist/skill-resolution/resolve-skill-reference.js.map +1 -1
- package/dist/utils/agent-discovery.d.ts +34 -1
- package/dist/utils/agent-discovery.d.ts.map +1 -1
- package/dist/utils/agent-discovery.js +80 -38
- package/dist/utils/agent-discovery.js.map +1 -1
- package/dist/utils/claude-context-lens.d.ts +13 -6
- package/dist/utils/claude-context-lens.d.ts.map +1 -1
- package/dist/utils/claude-context-lens.js +11 -12
- package/dist/utils/claude-context-lens.js.map +1 -1
- package/dist/utils/command-error-codes.d.ts +12 -0
- package/dist/utils/command-error-codes.d.ts.map +1 -0
- package/dist/utils/command-error-codes.js +12 -0
- package/dist/utils/command-error-codes.js.map +1 -0
- package/dist/utils/command-refusal.d.ts +58 -0
- package/dist/utils/command-refusal.d.ts.map +1 -0
- package/dist/utils/command-refusal.js +170 -0
- package/dist/utils/command-refusal.js.map +1 -0
- package/dist/utils/commander-ending.d.ts +40 -0
- package/dist/utils/commander-ending.d.ts.map +1 -0
- package/dist/utils/commander-ending.js +42 -0
- package/dist/utils/commander-ending.js.map +1 -0
- package/dist/utils/config-loader.d.ts +13 -8
- package/dist/utils/config-loader.d.ts.map +1 -1
- package/dist/utils/config-loader.js +84 -45
- package/dist/utils/config-loader.js.map +1 -1
- package/dist/utils/corpus-target.d.ts +1 -1
- package/dist/utils/corpus-target.d.ts.map +1 -1
- package/dist/utils/corpus-target.js +6 -4
- package/dist/utils/corpus-target.js.map +1 -1
- package/dist/utils/debug-diagnostics.d.ts +18 -0
- package/dist/utils/debug-diagnostics.d.ts.map +1 -0
- package/dist/utils/debug-diagnostics.js +23 -0
- package/dist/utils/debug-diagnostics.js.map +1 -0
- package/dist/utils/document-writer.d.ts +191 -0
- package/dist/utils/document-writer.d.ts.map +1 -0
- package/dist/utils/document-writer.js +319 -0
- package/dist/utils/document-writer.js.map +1 -0
- package/dist/utils/help-loader.d.ts +2 -2
- package/dist/utils/help-loader.js +2 -2
- package/dist/utils/install-plan.d.ts +99 -0
- package/dist/utils/install-plan.d.ts.map +1 -0
- package/dist/utils/install-plan.js +146 -0
- package/dist/utils/install-plan.js.map +1 -0
- package/dist/utils/issue-anchor.d.ts +1 -1
- package/dist/utils/issue-anchor.d.ts.map +1 -1
- package/dist/utils/issue-anchor.js.map +1 -1
- package/dist/utils/issue-rendering.d.ts +8 -3
- package/dist/utils/issue-rendering.d.ts.map +1 -1
- package/dist/utils/issue-rendering.js +4 -0
- package/dist/utils/issue-rendering.js.map +1 -1
- package/dist/utils/lens-population.d.ts +20 -0
- package/dist/utils/lens-population.d.ts.map +1 -0
- package/dist/utils/lens-population.js +15 -0
- package/dist/utils/lens-population.js.map +1 -0
- package/dist/utils/marketplace-io.d.ts +63 -0
- package/dist/utils/marketplace-io.d.ts.map +1 -0
- package/dist/utils/marketplace-io.js +63 -0
- package/dist/utils/marketplace-io.js.map +1 -0
- package/dist/utils/operator-notices.d.ts +97 -0
- package/dist/utils/operator-notices.d.ts.map +1 -0
- package/dist/utils/operator-notices.js +115 -0
- package/dist/utils/operator-notices.js.map +1 -0
- package/dist/utils/optional-backend.d.ts +18 -15
- package/dist/utils/optional-backend.d.ts.map +1 -1
- package/dist/utils/optional-backend.js +22 -33
- package/dist/utils/optional-backend.js.map +1 -1
- package/dist/utils/output.d.ts +5 -43
- package/dist/utils/output.d.ts.map +1 -1
- package/dist/utils/output.js +8 -63
- package/dist/utils/output.js.map +1 -1
- package/dist/utils/package-json.d.ts +3 -4
- package/dist/utils/package-json.d.ts.map +1 -1
- package/dist/utils/package-json.js +8 -8
- package/dist/utils/package-json.js.map +1 -1
- package/dist/utils/population-wiring.d.ts +31 -38
- package/dist/utils/population-wiring.d.ts.map +1 -1
- package/dist/utils/population-wiring.js +38 -32
- package/dist/utils/population-wiring.js.map +1 -1
- package/dist/utils/project-root-policy.d.ts +74 -1
- package/dist/utils/project-root-policy.d.ts.map +1 -1
- package/dist/utils/project-root-policy.js +146 -8
- package/dist/utils/project-root-policy.js.map +1 -1
- package/dist/utils/projection-lenses.d.ts +25 -7
- package/dist/utils/projection-lenses.d.ts.map +1 -1
- package/dist/utils/projection-lenses.js +20 -6
- package/dist/utils/projection-lenses.js.map +1 -1
- package/dist/utils/projection-query.d.ts +17 -10
- package/dist/utils/projection-query.d.ts.map +1 -1
- package/dist/utils/projection-query.js +47 -28
- package/dist/utils/projection-query.js.map +1 -1
- package/dist/utils/projection-store.d.ts +2 -2
- package/dist/utils/projection-store.d.ts.map +1 -1
- package/dist/utils/projection-store.js +74 -45
- package/dist/utils/projection-store.js.map +1 -1
- package/dist/utils/rag-database.d.ts +61 -0
- package/dist/utils/rag-database.d.ts.map +1 -0
- package/dist/utils/rag-database.js +178 -0
- package/dist/utils/rag-database.js.map +1 -0
- package/dist/utils/relation-limits.d.ts +7 -2
- package/dist/utils/relation-limits.d.ts.map +1 -1
- package/dist/utils/relation-limits.js +6 -1
- package/dist/utils/relation-limits.js.map +1 -1
- package/dist/utils/relativize-paths.d.ts +23 -0
- package/dist/utils/relativize-paths.d.ts.map +1 -1
- package/dist/utils/relativize-paths.js +32 -1
- package/dist/utils/relativize-paths.js.map +1 -1
- package/dist/utils/resource-loader.d.ts +76 -32
- package/dist/utils/resource-loader.d.ts.map +1 -1
- package/dist/utils/resource-loader.js +132 -66
- package/dist/utils/resource-loader.js.map +1 -1
- package/dist/utils/run-integrity.d.ts +64 -31
- package/dist/utils/run-integrity.d.ts.map +1 -1
- package/dist/utils/run-integrity.js +76 -35
- package/dist/utils/run-integrity.js.map +1 -1
- package/dist/utils/scope-locations.d.ts +7 -5
- package/dist/utils/scope-locations.d.ts.map +1 -1
- package/dist/utils/scope-locations.js +37 -12
- package/dist/utils/scope-locations.js.map +1 -1
- package/dist/utils/staging-dir.d.ts +7 -0
- package/dist/utils/staging-dir.d.ts.map +1 -0
- package/dist/utils/staging-dir.js +12 -0
- package/dist/utils/staging-dir.js.map +1 -0
- package/dist/utils/url-redact.d.ts +9 -0
- package/dist/utils/url-redact.d.ts.map +1 -1
- package/dist/utils/url-redact.js +13 -0
- package/dist/utils/url-redact.js.map +1 -1
- package/dist/utils/user-context-scanner.d.ts +3 -2
- package/dist/utils/user-context-scanner.d.ts.map +1 -1
- package/dist/utils/user-context-scanner.js +24 -4
- package/dist/utils/user-context-scanner.js.map +1 -1
- package/dist/utils/validate-help-files.d.ts.map +1 -1
- package/dist/utils/validate-help-files.js +8 -14
- package/dist/utils/validate-help-files.js.map +1 -1
- package/dist/utils/vat-bin-path.d.ts.map +1 -1
- package/dist/utils/vat-bin-path.js +3 -3
- package/dist/utils/vat-bin-path.js.map +1 -1
- package/dist/utils/verdict-helpers.d.ts.map +1 -1
- package/dist/utils/verdict-helpers.js +5 -5
- package/dist/utils/verdict-helpers.js.map +1 -1
- package/docs/agent.md +347 -2
- package/docs/audit.md +312 -89
- package/docs/doctor.md +65 -19
- package/docs/index.md +571 -20
- package/docs/mcp.md +64 -12
- package/docs/rag.md +176 -48
- package/docs/resources.md +257 -71
- package/docs/skill-test.md +148 -19
- package/docs/skills.md +459 -174
- package/package.json +16 -19
- package/schemas/agent-build.json +268 -0
- package/schemas/agent-import.json +252 -0
- package/schemas/agent-install.json +260 -0
- package/schemas/agent-installed.json +287 -0
- package/schemas/agent-list.json +279 -0
- package/schemas/agent-uninstall.json +260 -0
- package/schemas/agent-validate.json +279 -0
- package/schemas/ard-emit.json +224 -106
- package/schemas/audit-settings.json +472 -0
- package/schemas/audit.json +635 -0
- package/schemas/cache-clear.json +273 -0
- package/schemas/claude-marketplace-publish.json +286 -0
- package/schemas/claude-marketplace-validate.json +352 -0
- package/schemas/claude-org-not-implemented.json +239 -0
- package/schemas/claude-plugin-build.json +446 -0
- package/schemas/claude-plugin-install.json +291 -0
- package/schemas/claude-plugin-list.json +326 -0
- package/schemas/claude-plugin-uninstall.json +272 -0
- package/schemas/corpus-audit.json +635 -0
- package/schemas/corpus-scan.json +293 -0
- package/schemas/doctor.json +299 -0
- package/schemas/inventory.json +982 -0
- package/schemas/mcp-list-collections.json +268 -0
- package/schemas/okf-validate.json +224 -106
- package/schemas/orchestrator.json +299 -0
- package/schemas/rag-clear.json +253 -0
- package/schemas/rag-index.json +273 -0
- package/schemas/rag-query.json +365 -0
- package/schemas/rag-stats.json +269 -0
- package/schemas/resources-check.json +242 -108
- package/schemas/resources-query.json +333 -0
- package/schemas/resources-scan.json +321 -0
- package/schemas/resources-validate.json +332 -0
- package/schemas/skill-review.json +224 -106
- package/schemas/skill-test-configure.json +256 -0
- package/schemas/skill-test-run.json +296 -0
- package/schemas/skills-build.json +325 -0
- package/schemas/skills-install.json +287 -0
- package/schemas/skills-list.json +283 -0
- package/schemas/skills-package.json +270 -0
- package/schemas/skills-validate.json +285 -0
- package/dist/commands/skills/shared.d.ts +0 -29
- package/dist/commands/skills/shared.d.ts.map +0 -1
- package/dist/commands/skills/shared.js +0 -33
- package/dist/commands/skills/shared.js.map +0 -1
- package/dist/utils/command-error.d.ts +0 -194
- package/dist/utils/command-error.d.ts.map +0 -1
- package/dist/utils/command-error.js +0 -237
- package/dist/utils/command-error.js.map +0 -1
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* What the `--compat` and `--settings` lanes of `vat audit` found, as findings.
|
|
3
|
+
*
|
|
4
|
+
* The lanes publish their answers as blocks on the plugin's row (`data.files[].compatibility`,
|
|
5
|
+
* `.settings`). A block is not a finding: a plugin whose skill the org policy blocks was
|
|
6
|
+
* `status: ok`, `findings: []`, `summary: {0, 0, 0}` beside a stderr line saying a conflict was
|
|
7
|
+
* found — the human channel and the document disagreeing about one run. Each thing a lane found,
|
|
8
|
+
* and each thing it could not look at, is therefore ALSO a finding on the plugin's own result, so
|
|
9
|
+
* the envelope's status, the row's status and the file counts are derived from it like any other.
|
|
10
|
+
*
|
|
11
|
+
* Pure: it reads the rendered blocks and decides nothing about severity at run time.
|
|
12
|
+
*/
|
|
13
|
+
import type { ValidationIssue } from '@vibe-agent-toolkit/schema';
|
|
14
|
+
/** A path a lane never examined, as the document renders it: root-relative, with the reason. */
|
|
15
|
+
interface UncheckedPath {
|
|
16
|
+
readonly path: string;
|
|
17
|
+
readonly reason: string;
|
|
18
|
+
}
|
|
19
|
+
/** As much of the two rendered blocks as a finding is derived from. */
|
|
20
|
+
export interface CompatLaneAnswer {
|
|
21
|
+
/** The analyzer's block: its unchecked paths, or the reason it could not run for the plugin at all. */
|
|
22
|
+
readonly compatibility: {
|
|
23
|
+
readonly analyzed: false;
|
|
24
|
+
readonly reason: string;
|
|
25
|
+
} | {
|
|
26
|
+
readonly unchecked: readonly UncheckedPath[];
|
|
27
|
+
};
|
|
28
|
+
/** The settings block, present iff the run asked for `--settings`. */
|
|
29
|
+
readonly settings?: {
|
|
30
|
+
readonly compatible: boolean;
|
|
31
|
+
readonly conflicts: ReadonlyArray<{
|
|
32
|
+
readonly detail: string;
|
|
33
|
+
readonly settingsFile: string;
|
|
34
|
+
readonly settingsLevel: string;
|
|
35
|
+
}>;
|
|
36
|
+
readonly unchecked?: readonly UncheckedPath[];
|
|
37
|
+
};
|
|
38
|
+
}
|
|
39
|
+
/** A finding the document already carries: as much of it as the dedupe reads. */
|
|
40
|
+
export interface FiledFinding {
|
|
41
|
+
readonly code: string;
|
|
42
|
+
readonly location: string;
|
|
43
|
+
}
|
|
44
|
+
/**
|
|
45
|
+
* The findings one plugin's lane answers amount to:
|
|
46
|
+
*
|
|
47
|
+
* - `SETTINGS_POLICY_CONFLICT` for each settings conflict — a tool, a hook, an MCP server or a
|
|
48
|
+
* model the plugin declares and the effective settings block — on the plugin;
|
|
49
|
+
* - `COMPAT_NOT_CHECKED` when the analyzer could not run for the plugin at all, on the plugin;
|
|
50
|
+
* - `COMPAT_NOT_CHECKED` for each path a lane could not examine, at that path — unless the
|
|
51
|
+
* document already carries that path's refusal ({@link SAME_REFUSAL_CODES}), or this call has
|
|
52
|
+
* just filed the plugin itself as not checked: one refused path is one finding, however many
|
|
53
|
+
* lanes met it.
|
|
54
|
+
*
|
|
55
|
+
* Each is a `warning`: the lanes are advisory, as `COMPAT_TARGET_INCOMPATIBLE` and the sibling
|
|
56
|
+
* verb's `SETTINGS_RULE_SHADOWED` are, so they move the status and the counts and never the exit code.
|
|
57
|
+
*
|
|
58
|
+
* @param pluginLocation - The plugin's own row path, root-relative (`.` for the scan root)
|
|
59
|
+
* @param answer - The two blocks as the document renders them
|
|
60
|
+
* @param filed - Every finding the document already carries, each with the location it is published at
|
|
61
|
+
* @returns The lanes' findings for this plugin, conflicts first
|
|
62
|
+
*/
|
|
63
|
+
export declare function compatLaneIssues(pluginLocation: string, answer: CompatLaneAnswer, filed: readonly FiledFinding[]): ValidationIssue[];
|
|
64
|
+
export {};
|
|
65
|
+
//# sourceMappingURL=compat-lane-findings.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"compat-lane-findings.d.ts","sourceRoot":"","sources":["../../../src/commands/audit/compat-lane-findings.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,4BAA4B,CAAC;AAElE,gGAAgG;AAChG,UAAU,aAAa;IACrB,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;CACzB;AAED,uEAAuE;AACvE,MAAM,WAAW,gBAAgB;IAC/B,uGAAuG;IACvG,QAAQ,CAAC,aAAa,EAAE;QAAE,QAAQ,CAAC,QAAQ,EAAE,KAAK,CAAC;QAAC,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAA;KAAE,GAAG;QAAE,QAAQ,CAAC,SAAS,EAAE,SAAS,aAAa,EAAE,CAAA;KAAE,CAAC;IACjI,sEAAsE;IACtE,QAAQ,CAAC,QAAQ,CAAC,EAAE;QAClB,QAAQ,CAAC,UAAU,EAAE,OAAO,CAAC;QAC7B,QAAQ,CAAC,SAAS,EAAE,aAAa,CAAC;YAAE,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;YAAC,QAAQ,CAAC,YAAY,EAAE,MAAM,CAAC;YAAC,QAAQ,CAAC,aAAa,EAAE,MAAM,CAAA;SAAE,CAAC,CAAC;QAC9H,QAAQ,CAAC,SAAS,CAAC,EAAE,SAAS,aAAa,EAAE,CAAC;KAC/C,CAAC;CACH;AAED,iFAAiF;AACjF,MAAM,WAAW,YAAY;IAC3B,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;CAC3B;AAyBD;;;;;;;;;;;;;;;;;;GAkBG;AACH,wBAAgB,gBAAgB,CAAC,cAAc,EAAE,MAAM,EAAE,MAAM,EAAE,gBAAgB,EAAE,KAAK,EAAE,SAAS,YAAY,EAAE,GAAG,eAAe,EAAE,CAiBpI"}
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* What the `--compat` and `--settings` lanes of `vat audit` found, as findings.
|
|
3
|
+
*
|
|
4
|
+
* The lanes publish their answers as blocks on the plugin's row (`data.files[].compatibility`,
|
|
5
|
+
* `.settings`). A block is not a finding: a plugin whose skill the org policy blocks was
|
|
6
|
+
* `status: ok`, `findings: []`, `summary: {0, 0, 0}` beside a stderr line saying a conflict was
|
|
7
|
+
* found — the human channel and the document disagreeing about one run. Each thing a lane found,
|
|
8
|
+
* and each thing it could not look at, is therefore ALSO a finding on the plugin's own result, so
|
|
9
|
+
* the envelope's status, the row's status and the file counts are derived from it like any other.
|
|
10
|
+
*
|
|
11
|
+
* Pure: it reads the rendered blocks and decides nothing about severity at run time.
|
|
12
|
+
*/
|
|
13
|
+
/**
|
|
14
|
+
* The codes that already SAY "this path was not read": the scan's own refusal of it, the
|
|
15
|
+
* validator's refusal of its frontmatter (the settings check lists that same file as unchecked),
|
|
16
|
+
* and this lane's own finding for another plugin that holds the path. Only a finding of one of
|
|
17
|
+
* these at a path makes a `COMPAT_NOT_CHECKED` there a repeat — an unrelated finding that happens
|
|
18
|
+
* to sit at the same location says nothing about whether the lanes read it.
|
|
19
|
+
*/
|
|
20
|
+
const SAME_REFUSAL_CODES = new Set(['SCAN_PATH_UNREADABLE', 'SKILL_MISSING_FRONTMATTER', 'COMPAT_NOT_CHECKED']);
|
|
21
|
+
const NOT_CHECKED_FIX = 'Make the path readable and well-formed, then re-run; until then the compatibility and settings answers for this plugin do not cover it.';
|
|
22
|
+
function notChecked(location, message) {
|
|
23
|
+
return { code: 'COMPAT_NOT_CHECKED', severity: 'warning', message, location, fix: NOT_CHECKED_FIX };
|
|
24
|
+
}
|
|
25
|
+
/** Every path either lane could not examine, each once, with the first reason given for it. */
|
|
26
|
+
function uncheckedPaths(answer) {
|
|
27
|
+
const byPath = new Map();
|
|
28
|
+
const all = ['unchecked' in answer.compatibility ? answer.compatibility.unchecked : [], answer.settings?.unchecked ?? []].flat();
|
|
29
|
+
for (const unchecked of all)
|
|
30
|
+
if (!byPath.has(unchecked.path))
|
|
31
|
+
byPath.set(unchecked.path, unchecked);
|
|
32
|
+
return [...byPath.values()];
|
|
33
|
+
}
|
|
34
|
+
/**
|
|
35
|
+
* The findings one plugin's lane answers amount to:
|
|
36
|
+
*
|
|
37
|
+
* - `SETTINGS_POLICY_CONFLICT` for each settings conflict — a tool, a hook, an MCP server or a
|
|
38
|
+
* model the plugin declares and the effective settings block — on the plugin;
|
|
39
|
+
* - `COMPAT_NOT_CHECKED` when the analyzer could not run for the plugin at all, on the plugin;
|
|
40
|
+
* - `COMPAT_NOT_CHECKED` for each path a lane could not examine, at that path — unless the
|
|
41
|
+
* document already carries that path's refusal ({@link SAME_REFUSAL_CODES}), or this call has
|
|
42
|
+
* just filed the plugin itself as not checked: one refused path is one finding, however many
|
|
43
|
+
* lanes met it.
|
|
44
|
+
*
|
|
45
|
+
* Each is a `warning`: the lanes are advisory, as `COMPAT_TARGET_INCOMPATIBLE` and the sibling
|
|
46
|
+
* verb's `SETTINGS_RULE_SHADOWED` are, so they move the status and the counts and never the exit code.
|
|
47
|
+
*
|
|
48
|
+
* @param pluginLocation - The plugin's own row path, root-relative (`.` for the scan root)
|
|
49
|
+
* @param answer - The two blocks as the document renders them
|
|
50
|
+
* @param filed - Every finding the document already carries, each with the location it is published at
|
|
51
|
+
* @returns The lanes' findings for this plugin, conflicts first
|
|
52
|
+
*/
|
|
53
|
+
export function compatLaneIssues(pluginLocation, answer, filed) {
|
|
54
|
+
const refused = new Set(filed.filter((finding) => SAME_REFUSAL_CODES.has(finding.code)).map((finding) => finding.location));
|
|
55
|
+
const issues = (answer.settings?.conflicts ?? []).map((conflict) => ({
|
|
56
|
+
code: 'SETTINGS_POLICY_CONFLICT',
|
|
57
|
+
severity: 'warning',
|
|
58
|
+
message: `${conflict.detail} — ${conflict.settingsFile} (${conflict.settingsLevel} settings).`,
|
|
59
|
+
location: pluginLocation,
|
|
60
|
+
fix: 'Remove what the policy blocks from the plugin, or change the settings rule the message names.',
|
|
61
|
+
}));
|
|
62
|
+
if ('analyzed' in answer.compatibility) {
|
|
63
|
+
issues.push(notChecked(pluginLocation, `The compatibility analysis could not run for this plugin, so the run has no compatibility answer for it: ${answer.compatibility.reason}`));
|
|
64
|
+
refused.add(pluginLocation);
|
|
65
|
+
}
|
|
66
|
+
for (const { path, reason } of uncheckedPaths(answer)) {
|
|
67
|
+
if (!refused.has(path))
|
|
68
|
+
issues.push(notChecked(path, `The compatibility and settings checks could not examine this path, so their answers for the plugin do not cover it: ${reason}`));
|
|
69
|
+
}
|
|
70
|
+
return issues;
|
|
71
|
+
}
|
|
72
|
+
//# sourceMappingURL=compat-lane-findings.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"compat-lane-findings.js","sourceRoot":"","sources":["../../../src/commands/audit/compat-lane-findings.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AA4BH;;;;;;GAMG;AACH,MAAM,kBAAkB,GAAwB,IAAI,GAAG,CAAC,CAAC,sBAAsB,EAAE,2BAA2B,EAAE,oBAAoB,CAAC,CAAC,CAAC;AAErI,MAAM,eAAe,GAAG,yIAAyI,CAAC;AAElK,SAAS,UAAU,CAAC,QAAgB,EAAE,OAAe;IACnD,OAAO,EAAE,IAAI,EAAE,oBAAoB,EAAE,QAAQ,EAAE,SAAS,EAAE,OAAO,EAAE,QAAQ,EAAE,GAAG,EAAE,eAAe,EAAE,CAAC;AACtG,CAAC;AAED,+FAA+F;AAC/F,SAAS,cAAc,CAAC,MAAwB;IAC9C,MAAM,MAAM,GAAG,IAAI,GAAG,EAAyB,CAAC;IAChD,MAAM,GAAG,GAAG,CAAC,WAAW,IAAI,MAAM,CAAC,aAAa,CAAC,CAAC,CAAC,MAAM,CAAC,aAAa,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,EAAE,MAAM,CAAC,QAAQ,EAAE,SAAS,IAAI,EAAE,CAAC,CAAC,IAAI,EAAE,CAAC;IACjI,KAAK,MAAM,SAAS,IAAI,GAAG;QAAE,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,SAAS,CAAC,IAAI,CAAC;YAAE,MAAM,CAAC,GAAG,CAAC,SAAS,CA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I,EAAE,uHAAuH,MAAM,EAAE,CAAC,CAAC,CAAC;IACzL,CAAC;IACD,OAAO,MAAM,CAAC;AAChB,CAAC"}
|
|
@@ -188,7 +188,7 @@ export declare function isWithin(root: string, absolutePath: string): boolean;
|
|
|
188
188
|
* Classify the tree holding `skillMdPath`. See this module's header for the
|
|
189
189
|
* reasoning behind each clause and the order they are applied in.
|
|
190
190
|
*/
|
|
191
|
-
export declare function classifyScannedSkillTree(skillMdPath: string): Promise<SkillTreeProvenance>;
|
|
191
|
+
export declare function classifyScannedSkillTree(skillMdPath: string, within: string): Promise<SkillTreeProvenance>;
|
|
192
192
|
/**
|
|
193
193
|
* Will a crawl rooted at this SKILL.md's directory actually report the WHOLE
|
|
194
194
|
* subtree beneath it — nested skills included?
|
|
@@ -203,7 +203,7 @@ export declare function classifyScannedSkillTree(skillMdPath: string): Promise<S
|
|
|
203
203
|
* skill, and a scan rooted above `<claudeDir>/skills` reaches an install root
|
|
204
204
|
* from outside one.
|
|
205
205
|
*/
|
|
206
|
-
export declare function crawlOwnsSubtree(skillMdPath: string): Promise<boolean>;
|
|
206
|
+
export declare function crawlOwnsSubtree(skillMdPath: string, within: string): Promise<boolean>;
|
|
207
207
|
/**
|
|
208
208
|
* The agent-instruction files present in a skill's own directory, when that
|
|
209
209
|
* directory is a distributed tree. Empty otherwise — including when the caller
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"distributed-tree.d.ts","sourceRoot":"","sources":["../../../src/commands/audit/distributed-tree.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA0FG;AAGH,OAAO,EAAsB,KAAK,gBAAgB,EAAE,MAAM,wCAAwC,CAAC;AACnG,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,4BAA4B,CAAC;AAOlE,OAAO,EAEL,UAAU,EACX,MAAM,+BAA+B,C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AACH,wBAAsB,gBAAgB,CAAC,WAAW,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC,CAE5F;AA+BD;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,wBAAsB,uBAAuB,CAC3C,SAAS,EAAE,MAAM,EACjB,YAAY,EAAE,MAAM,EACpB,SAAS,EAAE,OAAO,GACjB,OAAO,CAAC,eAAe,EAAE,CAAC,CAuB5B"}
|
|
@@ -168,10 +168,16 @@ export async function getOrCreateGitTracker(gitRoot) {
|
|
|
168
168
|
* {@link resetGitTrackerCache} itself between phases, exactly as this module's
|
|
169
169
|
* own tests do in `beforeEach`.
|
|
170
170
|
*/
|
|
171
|
-
export const gitTrackerForProjectRoot =
|
|
172
|
-
|
|
171
|
+
export const gitTrackerForProjectRoot = (projectRoot) => {
|
|
172
|
+
let gitRoot;
|
|
173
|
+
try {
|
|
174
|
+
gitRoot = gitFindRoot(projectRoot);
|
|
175
|
+
}
|
|
176
|
+
catch (error) {
|
|
177
|
+
return Promise.reject(error);
|
|
178
|
+
}
|
|
173
179
|
if (gitRoot === null) {
|
|
174
|
-
return undefined;
|
|
180
|
+
return Promise.resolve(undefined);
|
|
175
181
|
}
|
|
176
182
|
// No catch, deliberately. "Not a repository" and "git did not answer" are
|
|
177
183
|
// both absorbed INSIDE `GitTracker.initialize()` (a null listing, a tracker
|
|
@@ -226,9 +232,12 @@ const REPO_SOURCE = 'repo-source';
|
|
|
226
232
|
* Canonicalising the SKILL.md before deriving the git root is what keeps the
|
|
227
233
|
* second fix honest — the tracker's own keys are built from the root it is given,
|
|
228
234
|
* so a canonical lookup against a non-canonical root would miss every time.
|
|
235
|
+
*
|
|
236
|
+
* @param within - The tree `filePath` was crawled in (the audit's scan root), whose links are read
|
|
237
|
+
* before the kernel follows them; `filePath` itself when it is the operator's own path
|
|
229
238
|
*/
|
|
230
|
-
function canonicalPath(filePath) {
|
|
231
|
-
return toForwardSlash(normalizePath(safePath.resolve(filePath)));
|
|
239
|
+
function canonicalPath(filePath, within) {
|
|
240
|
+
return toForwardSlash(normalizePath(safePath.resolve(filePath), within));
|
|
232
241
|
}
|
|
233
242
|
/**
|
|
234
243
|
* True when `absolutePath` is `root` or lies beneath it.
|
|
@@ -258,14 +267,16 @@ function isUnderClaudeInstallRoot(canonicalAbsolutePath) {
|
|
|
258
267
|
const { pluginsDir, skillsDir, marketplacesDir } = getClaudeUserPaths();
|
|
259
268
|
// marketplacesDir is nested under pluginsDir; listed anyway so the set reads as
|
|
260
269
|
// the three install destinations rather than as an accident of layout.
|
|
261
|
-
return [pluginsDir, skillsDir, marketplacesDir].some((dir) =>
|
|
270
|
+
return [pluginsDir, skillsDir, marketplacesDir].some((dir) =>
|
|
271
|
+
// An install root is the operator's own configuration (`CLAUDE_CONFIG_DIR`/`HOME`), never a crawled entry.
|
|
272
|
+
isWithin(canonicalPath(dir, dir), canonicalAbsolutePath));
|
|
262
273
|
}
|
|
263
274
|
/**
|
|
264
275
|
* Classify the tree holding `skillMdPath`. See this module's header for the
|
|
265
276
|
* reasoning behind each clause and the order they are applied in.
|
|
266
277
|
*/
|
|
267
|
-
export async function classifyScannedSkillTree(skillMdPath) {
|
|
268
|
-
const absolute = canonicalPath(skillMdPath);
|
|
278
|
+
export async function classifyScannedSkillTree(skillMdPath, within) {
|
|
279
|
+
const absolute = canonicalPath(skillMdPath, within);
|
|
269
280
|
const memoized = provenanceCache.get(absolute);
|
|
270
281
|
if (memoized !== undefined) {
|
|
271
282
|
return memoized;
|
|
@@ -309,8 +320,8 @@ async function classifyUncached(absolute) {
|
|
|
309
320
|
* skill, and a scan rooted above `<claudeDir>/skills` reaches an install root
|
|
310
321
|
* from outside one.
|
|
311
322
|
*/
|
|
312
|
-
export async function crawlOwnsSubtree(skillMdPath) {
|
|
313
|
-
return (await classifyScannedSkillTree(skillMdPath)) !== REPO_SOURCE;
|
|
323
|
+
export async function crawlOwnsSubtree(skillMdPath, within) {
|
|
324
|
+
return (await classifyScannedSkillTree(skillMdPath, within)) !== REPO_SOURCE;
|
|
314
325
|
}
|
|
315
326
|
/**
|
|
316
327
|
* The tree's own directory, spelled as a location a reader can act on.
|
|
@@ -365,11 +376,11 @@ function treeLocation(treeRoot, locationRoot) {
|
|
|
365
376
|
export async function distributedTreeFindings(skillPath, locationRoot, crawlTree) {
|
|
366
377
|
if (!crawlTree)
|
|
367
378
|
return [];
|
|
368
|
-
const provenance = await classifyScannedSkillTree(skillPath);
|
|
379
|
+
const provenance = await classifyScannedSkillTree(skillPath, locationRoot);
|
|
369
380
|
if (provenance === REPO_SOURCE)
|
|
370
381
|
return [];
|
|
371
382
|
const treeRoot = safePath.resolve(skillPath, '..');
|
|
372
|
-
const present = detectPackagedAgentInstructionFiles(treeRoot, locationRoot, []);
|
|
383
|
+
const present = detectPackagedAgentInstructionFiles(treeRoot, locationRoot, [], []);
|
|
373
384
|
if (provenance === 'distributed')
|
|
374
385
|
return present;
|
|
375
386
|
// Provenance is unknown. Report the unknown, not the files: calling them
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"distributed-tree.js","sourceRoot":"","sources":["../../../src/commands/audit/distributed-tree.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA0FG;AAEH,OAAO,EAAE,mCAAmC,EAAE,gBAAgB,EAAE,MAAM,kCAAkC,CAAC;AACzG,OAAO,EAAE,kBAAkB,EAAyB,MAAM,wCAAwC,CAAC;AAEnG,OAAO,EACL,aAAa,EACb,aAAa,EACb,QAAQ,EACR,cAAc,GACf,MAAM,2BAA2B,CAAC;AACnC,OAAO,EACL,WAAW,EACX,UAAU,GACX,MAAM,+BAA+B,CAAC;AAEvC,iFAAiF;AACjF,MAAM,eAAe,GAA4B,IAAI,GAAG,EAAE,CAAC;AAE3D;;;;;;GAMG;AACH,MAAM,CAAC,KAAK,UAA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AE,OAAO,EAAE,CAAC;IAE1C,MAAM,QAAQ,GAAG,QAAQ,CAAC,OAAO,CAAC,SAAS,EAAE,IAAI,CAAC,CAAC;IACnD,MAAM,OAAO,GAAG,mCAAmC,CAAC,QAAQ,EAAE,YAAY,EAAE,EAAE,EAAE,EAAE,CAAC,CAAC;IACpF,IAAI,UAAU,KAAK,aAAa;QAAE,OAAO,OAAO,CAAC;IAEjD,yEAAyE;IACzE,gFAAgF;IAChF,iFAAiF;IACjF,+EAA+E;IAC/E,8EAA8E;IAC9E,2EAA2E;IAC3E,IAAI,OAAO,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,EAAE,CAAC;IACpC,MAAM,QAAQ,GAAG,YAAY,CAAC,QAAQ,EAAE,YAAY,CAAC,CAAC;IACtD,OAAO;QACL,gBAAgB,CAAC,+BAA+B,EAAE;YAChD,QAAQ;YACR,MAAM,EAAE,GAAG,QAAQ,KAAK,OAAO,CAAC,MAAM,iDAAiD;SACxF,CAAC;KACH,CAAC;AACJ,CAAC"}
|
|
@@ -2,12 +2,13 @@
|
|
|
2
2
|
* Shallow-clone-and-cleanup helper for `vat audit <git-url>`.
|
|
3
3
|
*
|
|
4
4
|
* Pipeline:
|
|
5
|
-
* 1.
|
|
6
|
-
* 2.
|
|
5
|
+
* 1. makeStagingDir('vat-audit-')
|
|
6
|
+
* 2. guard every terminating signal: dispose of the tempdir, then die of it — held until the
|
|
7
|
+
* tempdir's one disposal (step 6, or the signal's own) has settled
|
|
7
8
|
* 3. git clone --depth 1 --single-branch [--branch <ref>]
|
|
8
9
|
* 4. git rev-parse HEAD → resolved commit SHA
|
|
9
10
|
* 5. yield (tempdir, targetDir, provenance) to caller
|
|
10
|
-
* 6.
|
|
11
|
+
* 6. dispose of the tempdir, success or failure, unless `keepTempForDebug`
|
|
11
12
|
*/
|
|
12
13
|
import { type ParsedGitUrl } from '@vibe-agent-toolkit/utils/git';
|
|
13
14
|
import type { Provenance } from './provenance.js';
|
|
@@ -24,9 +25,16 @@ export interface CloneOptions {
|
|
|
24
25
|
keepTempForDebug: boolean;
|
|
25
26
|
}
|
|
26
27
|
/**
|
|
27
|
-
* Run `body` against a freshly shallow-cloned repo
|
|
28
|
-
*
|
|
29
|
-
*
|
|
28
|
+
* Run `body` against a freshly shallow-cloned repo, then dispose of the clone (unless
|
|
29
|
+
* `options.keepTempForDebug`). `body` must not end the process itself: a caller that exits
|
|
30
|
+
* does so once this has settled.
|
|
31
|
+
*
|
|
32
|
+
* A failure of the clone or of `body` is rethrown unchanged, a clone that will not go recorded
|
|
33
|
+
* beside it (`suppressedFaultsOf`). Once `body` succeeded, a clone the OS would not remove is
|
|
34
|
+
* returned as `leftover` beside its value — the work is done, so it is never the refusal.
|
|
30
35
|
*/
|
|
31
|
-
export declare function withClonedRepo<T>(parsed: ParsedGitUrl, options: CloneOptions, body: (ctx: CloneAndAuditContext) => Promise<T>): Promise<
|
|
36
|
+
export declare function withClonedRepo<T>(parsed: ParsedGitUrl, options: CloneOptions, body: (ctx: CloneAndAuditContext) => Promise<T>): Promise<{
|
|
37
|
+
readonly value: T;
|
|
38
|
+
readonly leftover: unknown;
|
|
39
|
+
}>;
|
|
32
40
|
//# sourceMappingURL=git-url-clone.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"git-url-clone.d.ts","sourceRoot":"","sources":["../../../src/commands/audit/git-url-clone.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"git-url-clone.d.ts","sourceRoot":"","sources":["../../../src/commands/audit/git-url-clone.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAOH,OAAO,EAAE,KAAK,YAAY,EAAE,MAAM,+BAA+B,CAAC;AAMlE,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAElD,MAAM,WAAW,oBAAoB;IACnC,OAAO,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;IAClB,UAAU,EAAE,UAAU,CAAC;CACxB;AAED,MAAM,WAAW,YAAY;IAC3B;;;OAGG;IACH,gBAAgB,EAAE,OAAO,CAAC;CAC3B;AAkCD;;;;;;;;GAQG;AACH,wBAAsB,cAAc,CAAC,CAAC,EACpC,MAAM,EAAE,YAAY,EACpB,OAAO,EAAE,YAAY,EACrB,IAAI,EAAE,CAAC,GAAG,EAAE,oBAAoB,KAAK,OAAO,CAAC,CAAC,CAAC,GAC9C,OAAO,CAAC;IAAE,QAAQ,CAAC,KAAK,EAAE,CAAC,CAAC;IAAC,QAAQ,CAAC,QAAQ,EAAE,OAAO,CAAA;CAAE,CAAC,CAoD5D"}
|
|
@@ -2,57 +2,99 @@
|
|
|
2
2
|
* Shallow-clone-and-cleanup helper for `vat audit <git-url>`.
|
|
3
3
|
*
|
|
4
4
|
* Pipeline:
|
|
5
|
-
* 1.
|
|
6
|
-
* 2.
|
|
5
|
+
* 1. makeStagingDir('vat-audit-')
|
|
6
|
+
* 2. guard every terminating signal: dispose of the tempdir, then die of it — held until the
|
|
7
|
+
* tempdir's one disposal (step 6, or the signal's own) has settled
|
|
7
8
|
* 3. git clone --depth 1 --single-branch [--branch <ref>]
|
|
8
9
|
* 4. git rev-parse HEAD → resolved commit SHA
|
|
9
10
|
* 5. yield (tempdir, targetDir, provenance) to caller
|
|
10
|
-
* 6.
|
|
11
|
+
* 6. dispose of the tempdir, success or failure, unless `keepTempForDebug`
|
|
11
12
|
*/
|
|
12
|
-
import { mkdtempSync, rmSync } from 'node:fs';
|
|
13
13
|
import { cloneGitSource } from '@vibe-agent-toolkit/agent-skills';
|
|
14
|
-
import {
|
|
14
|
+
import { ExitCode } from '@vibe-agent-toolkit/schema';
|
|
15
|
+
import { disposeTempDir, disposeTempDirAfterFailure } from '@vibe-agent-toolkit/utils';
|
|
16
|
+
import { handleTerminatingSignals } from '@vibe-agent-toolkit/utils/process';
|
|
17
|
+
import { CommandRefusalError, errorMessageOf, refusalCodeOf } from '../../utils/command-refusal.js';
|
|
18
|
+
import { makeStagingDir } from '../../utils/staging-dir.js';
|
|
15
19
|
/**
|
|
16
|
-
*
|
|
17
|
-
*
|
|
18
|
-
*
|
|
20
|
+
* Clone the source, or refuse. A subpath the clone does not hold, or one that
|
|
21
|
+
* escapes it, arrives coded (`GIT_SUBPATH_INVALID`) and keeps its own refusal —
|
|
22
|
+
* `USAGE_INVALID`, the argument's mistake. Anything else the clone step throws
|
|
23
|
+
* (a clone that fails, a ref it does not have) means the source the operator
|
|
24
|
+
* named could not be read: `INPUT_UNREADABLE`. Only the clone step is coded; a
|
|
25
|
+
* failure inside the audit that follows is the audit's own.
|
|
26
|
+
*/
|
|
27
|
+
function cloneSource(parsed, tempdir) {
|
|
28
|
+
try {
|
|
29
|
+
return cloneGitSource(parsed, tempdir);
|
|
30
|
+
}
|
|
31
|
+
catch (error) {
|
|
32
|
+
if (refusalCodeOf(error) !== 'INTERNAL_ERROR')
|
|
33
|
+
throw error;
|
|
34
|
+
throw new CommandRefusalError('INPUT_UNREADABLE', errorMessageOf(error), { cause: error });
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* Dispose of the clone's tempdir once the work on it is DONE — or, under `keepTempForDebug`,
|
|
39
|
+
* keep it and say where.
|
|
40
|
+
*
|
|
41
|
+
* @returns `undefined`, or the leftover: the classified fault naming a tempdir the OS would not
|
|
42
|
+
* remove, for the caller to publish as a warning beside the work it finished
|
|
43
|
+
*/
|
|
44
|
+
async function disposeClone(tempdir, options) {
|
|
45
|
+
if (options.keepTempForDebug) {
|
|
46
|
+
process.stderr.write(`[vat: debug — temp dir preserved: ${tempdir}]\n`);
|
|
47
|
+
return undefined;
|
|
48
|
+
}
|
|
49
|
+
return await disposeTempDir(tempdir);
|
|
50
|
+
}
|
|
51
|
+
/**
|
|
52
|
+
* Run `body` against a freshly shallow-cloned repo, then dispose of the clone (unless
|
|
53
|
+
* `options.keepTempForDebug`). `body` must not end the process itself: a caller that exits
|
|
54
|
+
* does so once this has settled.
|
|
55
|
+
*
|
|
56
|
+
* A failure of the clone or of `body` is rethrown unchanged, a clone that will not go recorded
|
|
57
|
+
* beside it (`suppressedFaultsOf`). Once `body` succeeded, a clone the OS would not remove is
|
|
58
|
+
* returned as `leftover` beside its value — the work is done, so it is never the refusal.
|
|
19
59
|
*/
|
|
20
60
|
export async function withClonedRepo(parsed, options, body) {
|
|
21
|
-
|
|
22
|
-
const
|
|
61
|
+
// Through the one classified creation: a temp directory the OS will not make is the environment's fault.
|
|
62
|
+
const tempdir = await makeStagingDir('vat-audit-');
|
|
63
|
+
// ONE disposal, whoever starts it: the work's own end (after success or failure) or a signal. It
|
|
64
|
+
// settles on what it left behind, whichever path started it, so the signal path can name it. The
|
|
65
|
+
// guard is held until that disposal has SETTLED — a Ctrl-C that also kills `git` fails the clone
|
|
66
|
+
// step, and a guard released before the failure path's disposal let the pending signal kill the
|
|
67
|
+
// process half-way through it, the clone left behind.
|
|
68
|
+
let disposal;
|
|
69
|
+
const dispose = (start) => (disposal ??= start());
|
|
70
|
+
// Interrupted: dispose of the clone first, then die of the signal. No report follows a signal, so a
|
|
71
|
+
// clone that will not go is named on stderr. A repeat (a terminal Ctrl-C under the `vat` wrapper
|
|
72
|
+
// arrives twice) is swallowed — see `handleTerminatingSignals`.
|
|
73
|
+
const signalGuard = handleTerminatingSignals({
|
|
74
|
+
fallbackExitCode: ExitCode.ERROR,
|
|
75
|
+
cleanup: () => dispose(() => disposeClone(tempdir, options)).then((leftover) => {
|
|
76
|
+
if (leftover !== undefined)
|
|
77
|
+
process.stderr.write(`[vat: interrupted — temp dir left behind: ${errorMessageOf(leftover)}]\n`);
|
|
78
|
+
},
|
|
79
|
+
// A rejection is a refusal to dispose at all (nothing was touched): say that, not "left behind".
|
|
80
|
+
(error_) => {
|
|
81
|
+
process.stderr.write(`[vat: interrupted — temp dir not disposed of: ${errorMessageOf(error_)}]\n`);
|
|
82
|
+
}),
|
|
83
|
+
});
|
|
84
|
+
// The work's own disposal, then the guard's release — released even when the disposal REJECTS
|
|
85
|
+
// (a refusal to dispose at all), so a guard never outlives the work it guarded.
|
|
86
|
+
const disposeThenRelease = async (start) => {
|
|
23
87
|
try {
|
|
24
|
-
|
|
88
|
+
return await dispose(start);
|
|
25
89
|
}
|
|
26
90
|
finally {
|
|
27
|
-
process.
|
|
28
|
-
|
|
91
|
+
// A signal that arrived meanwhile ends the process once this same disposal has settled.
|
|
92
|
+
await signalGuard.releaseOrAwaitEnding();
|
|
29
93
|
}
|
|
30
94
|
};
|
|
31
|
-
|
|
32
|
-
// The audit pipeline calls `process.exit()` on completion
|
|
33
|
-
// (`handleAuditResults` in audit.ts), which would skip any `finally`
|
|
34
|
-
// block here. Register an `'exit'` listener so cleanup runs even when
|
|
35
|
-
// the process is ending — this is Node's documented escape hatch for
|
|
36
|
-
// "always run this sync cleanup". We still keep the `finally` below so
|
|
37
|
-
// thrown errors and the non-exit path behave the same.
|
|
38
|
-
let cleaned = false;
|
|
39
|
-
const cleanup = () => {
|
|
40
|
-
if (cleaned)
|
|
41
|
-
return;
|
|
42
|
-
cleaned = true;
|
|
43
|
-
if (options.keepTempForDebug) {
|
|
44
|
-
process.stderr.write(`[vat: debug — temp dir preserved: ${tempdir}]\n`);
|
|
45
|
-
}
|
|
46
|
-
else {
|
|
47
|
-
rmSync(tempdir, { recursive: true, force: true });
|
|
48
|
-
}
|
|
49
|
-
};
|
|
50
|
-
const exitListener = () => {
|
|
51
|
-
cleanup();
|
|
52
|
-
};
|
|
53
|
-
process.on('exit', exitListener);
|
|
95
|
+
let value;
|
|
54
96
|
try {
|
|
55
|
-
const { ref, commit, targetDir } =
|
|
97
|
+
const { ref, commit, targetDir } = cloneSource(parsed, tempdir);
|
|
56
98
|
const { subpath } = parsed;
|
|
57
99
|
const provenance = {
|
|
58
100
|
url: parsed.cloneUrl,
|
|
@@ -60,12 +102,13 @@ export async function withClonedRepo(parsed, options, body) {
|
|
|
60
102
|
commit,
|
|
61
103
|
...(subpath ? { subpath } : {}),
|
|
62
104
|
};
|
|
63
|
-
|
|
105
|
+
value = await body({ tempdir, targetDir, provenance });
|
|
64
106
|
}
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
cleanup();
|
|
107
|
+
catch (error) {
|
|
108
|
+
await disposeThenRelease(() => (options.keepTempForDebug ? disposeClone(tempdir, options) : disposeTempDirAfterFailure(tempdir, error)));
|
|
109
|
+
throw error;
|
|
69
110
|
}
|
|
111
|
+
const leftover = await disposeThenRelease(() => disposeClone(tempdir, options));
|
|
112
|
+
return { value, leftover };
|
|
70
113
|
}
|
|
71
114
|
//# sourceMappingURL=git-url-clone.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"git-url-clone.js","sourceRoot":"","sources":["../../../src/commands/audit/git-url-clone.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"git-url-clone.js","sourceRoot":"","sources":["../../../src/commands/audit/git-url-clone.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAIH,OAAO,EAAE,cAAc,EAAE,MAAM,kCAAkC,CAAC;AAClE,OAAO,EAAE,QAAQ,EAAE,MAAM,4BAA4B,CAAC;AACtD,OAAO,EAAE,cAAc,EAAE,0BAA0B,EAAE,MAAM,2BAA2B,CAAC;AAEvF,OAAO,EAAE,wBAAwB,EAAE,MAAM,mCAAmC,CAAC;AAE7E,OAAO,EAAE,mBAAmB,EAAE,cAAc,EAAE,aAAa,EAAE,MAAM,gCAAgC,CAAC;AACpG,OAAO,EAAE,cAAc,EAAE,MAAM,4BAA4B,CAAC;AAkB5D;;;;;;;GAOG;AACH,SAAS,WAAW,CAAC,MAAoB,EAAE,OAAe;IACxD,IAAI,CAAC;QACH,OAAO,cAAc,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IACzC,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACf,IAAI,aAAa,CAAC,KAAK,CAAC,KAAK,gBAAgB;YAAE,MAAM,KAAK,CAAC;QAC3D,MAAM,IAA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AAC,CAAC,CAAC;IAChF,OAAO,EAAE,KAAK,EAAE,QAAQ,EAAE,CAAC;AAC7B,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type
|
|
2
|
-
import { type
|
|
1
|
+
import { type ValidationResult } from '@vibe-agent-toolkit/agent-skills';
|
|
2
|
+
import { type SeverityCounts } from '@vibe-agent-toolkit/schema';
|
|
3
3
|
export interface HierarchicalOutput {
|
|
4
4
|
marketplaces: MarketplaceGroup[];
|
|
5
5
|
cachedPlugins: PluginGroup[];
|
|
@@ -15,14 +15,38 @@ export interface PluginGroup {
|
|
|
15
15
|
skills: SkillEntry[];
|
|
16
16
|
}
|
|
17
17
|
export type CacheStatus = 'stale' | 'orphaned' | 'fresh';
|
|
18
|
+
/**
|
|
19
|
+
* One skill in the `--user` view. Its findings are the report envelope's (each
|
|
20
|
+
* `location` names the file); the entry carries their distribution, the same
|
|
21
|
+
* `status` + `summary` pair every `files[]` row carries.
|
|
22
|
+
*/
|
|
18
23
|
export interface SkillEntry {
|
|
19
24
|
name: string;
|
|
20
25
|
/** Path relative to the run root stated once at the top of the report. */
|
|
21
26
|
path: string;
|
|
22
|
-
|
|
23
|
-
|
|
27
|
+
/** Literal: `findings` iff the skill carries any finding. */
|
|
28
|
+
status: 'ok' | 'findings';
|
|
29
|
+
summary: SeverityCounts;
|
|
24
30
|
cacheStatus?: CacheStatus;
|
|
25
31
|
}
|
|
32
|
+
/**
|
|
33
|
+
* Add misconfiguration issues to standalone skills in wrong locations
|
|
34
|
+
*
|
|
35
|
+
* Detects standalone SKILL.md files in ~/.claude/plugins/ that won't be recognized
|
|
36
|
+
* by Claude Code. These should be either moved to ~/.claude/skills/ or properly
|
|
37
|
+
* configured as plugins with .claude-plugin/plugin.json.
|
|
38
|
+
*
|
|
39
|
+
* Applied to the `--user` run's RESULTS, before the report is built, so the
|
|
40
|
+
* finding reaches the envelope's `findings` and `summary` and the `files[]` row
|
|
41
|
+
* as well as the hierarchy. It used to be added inside the hierarchy only: an
|
|
42
|
+
* error-severity finding the header never counted and the exit code never saw.
|
|
43
|
+
*
|
|
44
|
+
* @param results - Validation results to check — every result of the run, so a
|
|
45
|
+
* skill-claude-plugin's own plugin result is among them
|
|
46
|
+
* @param locationRoot - Run root the emitted `location` is expressed relative to
|
|
47
|
+
* @returns Results with misconfiguration issues added
|
|
48
|
+
*/
|
|
49
|
+
export declare function addMisconfigurationIssues(results: ValidationResult[], locationRoot: string): ValidationResult[];
|
|
26
50
|
/**
|
|
27
51
|
* Build hierarchical output structure from validation results.
|
|
28
52
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"hierarchical-output.d.ts","sourceRoot":"","sources":["../../../src/commands/audit/hierarchical-output.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,
|
|
1
|
+
{"version":3,"file":"hierarchical-output.d.ts","sourceRoot":"","sources":["../../../src/commands/audit/hierarchical-output.ts"],"names":[],"mappings":"AAEA,OAAO,EAAkB,KAAK,gBAAgB,EAAE,MAAM,kCAAkC,CAAC;AACzF,OAAO,EAAmB,KAAK,cAAc,EAAwB,MAAM,4BAA4B,CAAC;AAGxG,MAAM,WAAW,kBAAkB;IACjC,YAAY,EAAE,gBAAgB,EAAE,CAAC;IACjC,aAAa,EAAE,WAAW,EAAE,CAAC;IAC7B,iBAAiB,EAAE,WAAW,EAAE,CAAC;IACjC,gBAAgB,EAAE,UAAU,EAAE,CAAC;CAChC;AAED,MAAM,WAAW,gBAAgB;IAC/B,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,WAAW,EAAE,CAAC;CACxB;AAED,MAAM,WAAW,WAAW;IAC1B,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,UAAU,EAAE,CAAC;CACtB;AAED,MAAM,MAAM,WAAW,GAAG,OAAO,GAAG,UAAU,GAAG,OAAO,CAAC;AAEzD;;;;GAIG;AACH,MAAM,WAAW,UAAU;IACzB,IAAI,EAAE,MAAM,CAAC;IACb,0EAA0E;IAC1E,IAAI,EAAE,MAAM,CAAC;IACb,6DAA6D;IAC7D,MAAM,EAAE,IAAI,GAAG,UAAU,CAAC;IAC1B,OAAO,EAAE,cAAc,CAAC;IACxB,WAAW,CAAC,EAAE,WAAW,CAAC;CAC3B;AAuYD;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAgB,yBAAyB,CAAC,OAAO,EAAE,gBAAgB,EAAE,EAAE,YAAY,EAAE,MAAM,GAAG,gBAAgB,EAAE,CAuB/G;AAED;;;;;;;;;;;;;;;;;;GAkBG;AACH,wBAAgB,uBAAuB,CACrC,OAAO,EAAE,gBAAgB,EAAE,EAC3B,OAAO,EAAE,OAAO,EAChB,YAAY,EAAE,MAAM,GACnB,kBAAkB,CAuCpB"}
|