@shrkcrft/cli 0.1.0-alpha.30 → 0.1.0-alpha.31
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/asset-preview/apply-asset-preview.js +1 -1
- package/dist/authoring/authoring-kit.d.ts +9 -1
- package/dist/authoring/authoring-kit.d.ts.map +1 -1
- package/dist/authoring/authoring-kit.js +26 -13
- package/dist/bootstrap/unlinked-workspace-dependency.d.ts +11 -0
- package/dist/bootstrap/unlinked-workspace-dependency.d.ts.map +1 -0
- package/dist/bootstrap/unlinked-workspace-dependency.js +99 -0
- package/dist/command-registry.d.ts +100 -1
- package/dist/command-registry.d.ts.map +1 -1
- package/dist/command-registry.js +130 -3
- package/dist/commands/api-diff.command.d.ts.map +1 -1
- package/dist/commands/api-diff.command.js +12 -0
- package/dist/commands/apply.command.d.ts.map +1 -1
- package/dist/commands/apply.command.js +3 -0
- package/dist/commands/arch.command.d.ts.map +1 -1
- package/dist/commands/arch.command.js +26 -7
- package/dist/commands/architecture.command.d.ts.map +1 -1
- package/dist/commands/architecture.command.js +8 -2
- package/dist/commands/baseline.command.d.ts +54 -3
- package/dist/commands/baseline.command.d.ts.map +1 -1
- package/dist/commands/baseline.command.js +582 -74
- package/dist/commands/biome.command.d.ts.map +1 -1
- package/dist/commands/biome.command.js +20 -0
- package/dist/commands/boundaries.command.d.ts +9 -1
- package/dist/commands/boundaries.command.d.ts.map +1 -1
- package/dist/commands/boundaries.command.js +88 -20
- package/dist/commands/bundle.command.d.ts.map +1 -1
- package/dist/commands/bundle.command.js +57 -11
- package/dist/commands/cache-align.command.d.ts.map +1 -1
- package/dist/commands/cache-align.command.js +3 -1
- package/dist/commands/changelog-data.d.ts.map +1 -1
- package/dist/commands/changelog-data.js +138 -0
- package/dist/commands/changes.command.d.ts.map +1 -1
- package/dist/commands/changes.command.js +15 -0
- package/dist/commands/check.command.d.ts.map +1 -1
- package/dist/commands/check.command.js +1241 -322
- package/dist/commands/checks.command.d.ts.map +1 -1
- package/dist/commands/checks.command.js +188 -40
- package/dist/commands/ci.command.d.ts.map +1 -1
- package/dist/commands/ci.command.js +35 -2
- package/dist/commands/code-intel.command.d.ts.map +1 -1
- package/dist/commands/code-intel.command.js +3 -0
- package/dist/commands/command-catalog.d.ts +23 -1
- package/dist/commands/command-catalog.d.ts.map +1 -1
- package/dist/commands/command-catalog.js +152 -35
- package/dist/commands/commands.command.d.ts +21 -3
- package/dist/commands/commands.command.d.ts.map +1 -1
- package/dist/commands/commands.command.js +172 -27
- package/dist/commands/compress.command.d.ts.map +1 -1
- package/dist/commands/compress.command.js +4 -0
- package/dist/commands/constructs.command.d.ts.map +1 -1
- package/dist/commands/constructs.command.js +50 -12
- package/dist/commands/context.command.d.ts.map +1 -1
- package/dist/commands/context.command.js +40 -5
- package/dist/commands/contract-templates.command.d.ts.map +1 -1
- package/dist/commands/contract-templates.command.js +9 -1
- package/dist/commands/contract.command.d.ts.map +1 -1
- package/dist/commands/contract.command.js +35 -0
- package/dist/commands/conventions.command.d.ts.map +1 -1
- package/dist/commands/conventions.command.js +189 -29
- package/dist/commands/coverage.command.d.ts.map +1 -1
- package/dist/commands/coverage.command.js +9 -0
- package/dist/commands/daily.commands.d.ts +0 -1
- package/dist/commands/daily.commands.d.ts.map +1 -1
- package/dist/commands/daily.commands.js +12 -76
- package/dist/commands/dashboard.command.d.ts.map +1 -1
- package/dist/commands/dashboard.command.js +10 -0
- package/dist/commands/dev.command.d.ts.map +1 -1
- package/dist/commands/dev.command.js +45 -2
- package/dist/commands/diagnostics.command.d.ts +0 -2
- package/dist/commands/diagnostics.command.d.ts.map +1 -1
- package/dist/commands/diagnostics.command.js +5 -78
- package/dist/commands/diff-check.command.d.ts +6 -4
- package/dist/commands/diff-check.command.d.ts.map +1 -1
- package/dist/commands/diff-check.command.js +190 -103
- package/dist/commands/docs-references.command.d.ts +13 -0
- package/dist/commands/docs-references.command.d.ts.map +1 -1
- package/dist/commands/docs-references.command.js +269 -72
- package/dist/commands/doctor.command.d.ts.map +1 -1
- package/dist/commands/doctor.command.js +58 -4
- package/dist/commands/drift.command.d.ts.map +1 -1
- package/dist/commands/drift.command.js +17 -4
- package/dist/commands/eslint.command.d.ts.map +1 -1
- package/dist/commands/eslint.command.js +20 -0
- package/dist/commands/export.command.d.ts.map +1 -1
- package/dist/commands/export.command.js +23 -1
- package/dist/commands/feedback-dispatch.command.d.ts.map +1 -1
- package/dist/commands/feedback-dispatch.command.js +29 -0
- package/dist/commands/feedback.command.d.ts.map +1 -1
- package/dist/commands/feedback.command.js +6 -1
- package/dist/commands/finish.command.d.ts.map +1 -1
- package/dist/commands/finish.command.js +32 -8
- package/dist/commands/fix.command.d.ts.map +1 -1
- package/dist/commands/fix.command.js +19 -0
- package/dist/commands/gate.command.d.ts +6 -1
- package/dist/commands/gate.command.d.ts.map +1 -1
- package/dist/commands/gate.command.js +50 -124
- package/dist/commands/gates.command.d.ts +52 -0
- package/dist/commands/gates.command.d.ts.map +1 -1
- package/dist/commands/gates.command.js +811 -185
- package/dist/commands/gen.command.d.ts.map +1 -1
- package/dist/commands/gen.command.js +4 -0
- package/dist/commands/generated.command.d.ts +33 -3
- package/dist/commands/generated.command.d.ts.map +1 -1
- package/dist/commands/generated.command.js +499 -147
- package/dist/commands/graph-code-subverbs.d.ts +15 -0
- package/dist/commands/graph-code-subverbs.d.ts.map +1 -1
- package/dist/commands/graph-code-subverbs.js +198 -24
- package/dist/commands/graph.command.d.ts.map +1 -1
- package/dist/commands/graph.command.js +79 -37
- package/dist/commands/help.command.d.ts +30 -6
- package/dist/commands/help.command.d.ts.map +1 -1
- package/dist/commands/help.command.js +323 -199
- package/dist/commands/helper.command.d.ts +1 -0
- package/dist/commands/helper.command.d.ts.map +1 -1
- package/dist/commands/helper.command.js +195 -56
- package/dist/commands/impact.command.d.ts.map +1 -1
- package/dist/commands/impact.command.js +115 -12
- package/dist/commands/infer.command.d.ts.map +1 -1
- package/dist/commands/infer.command.js +20 -45
- package/dist/commands/ingest.command.d.ts +0 -1
- package/dist/commands/ingest.command.d.ts.map +1 -1
- package/dist/commands/ingest.command.js +25 -41
- package/dist/commands/knowledge-author.command.d.ts +0 -3
- package/dist/commands/knowledge-author.command.d.ts.map +1 -1
- package/dist/commands/knowledge-author.command.js +10 -23
- package/dist/commands/knowledge.command.d.ts.map +1 -1
- package/dist/commands/knowledge.command.js +469 -129
- package/dist/commands/languages.command.d.ts.map +1 -1
- package/dist/commands/languages.command.js +27 -0
- package/dist/commands/lint.command.d.ts.map +1 -1
- package/dist/commands/lint.command.js +3 -0
- package/dist/commands/mcp.command.d.ts +18 -0
- package/dist/commands/mcp.command.d.ts.map +1 -1
- package/dist/commands/mcp.command.js +33 -8
- package/dist/commands/onboard.command.d.ts.map +1 -1
- package/dist/commands/onboard.command.js +20 -0
- package/dist/commands/owners.command.d.ts.map +1 -1
- package/dist/commands/owners.command.js +14 -2
- package/dist/commands/packs-new.d.ts +13 -1
- package/dist/commands/packs-new.d.ts.map +1 -1
- package/dist/commands/packs-new.js +500 -335
- package/dist/commands/packs.command.d.ts.map +1 -1
- package/dist/commands/packs.command.js +378 -36
- package/dist/commands/paths.command.d.ts.map +1 -1
- package/dist/commands/paths.command.js +9 -1
- package/dist/commands/pipelines.command.d.ts.map +1 -1
- package/dist/commands/pipelines.command.js +7 -1
- package/dist/commands/plan-check.command.d.ts.map +1 -1
- package/dist/commands/plan-check.command.js +3 -0
- package/dist/commands/plan.command.d.ts.map +1 -1
- package/dist/commands/plan.command.js +3 -0
- package/dist/commands/playbooks.command.d.ts.map +1 -1
- package/dist/commands/playbooks.command.js +7 -2
- package/dist/commands/policy-lint.command.d.ts +19 -2
- package/dist/commands/policy-lint.command.d.ts.map +1 -1
- package/dist/commands/policy-lint.command.js +224 -65
- package/dist/commands/policy.command.d.ts.map +1 -1
- package/dist/commands/policy.command.js +6 -1
- package/dist/commands/pr.command.d.ts.map +1 -1
- package/dist/commands/pr.command.js +14 -0
- package/dist/commands/presets.command.d.ts.map +1 -1
- package/dist/commands/presets.command.js +12 -27
- package/dist/commands/profiles.command.d.ts.map +1 -1
- package/dist/commands/profiles.command.js +94 -26
- package/dist/commands/provenance.command.js +1 -1
- package/dist/commands/quality.command.d.ts.map +1 -1
- package/dist/commands/quality.command.js +129 -33
- package/dist/commands/recommend.command.d.ts +20 -4
- package/dist/commands/recommend.command.d.ts.map +1 -1
- package/dist/commands/recommend.command.js +172 -278
- package/dist/commands/registrations.command.d.ts.map +1 -1
- package/dist/commands/registrations.command.js +138 -13
- package/dist/commands/registry-lifecycle-run.d.ts +14 -0
- package/dist/commands/registry-lifecycle-run.d.ts.map +1 -0
- package/dist/commands/registry-lifecycle-run.js +336 -0
- package/dist/commands/registry.command.d.ts.map +1 -1
- package/dist/commands/registry.command.js +235 -62
- package/dist/commands/release.command.d.ts.map +1 -1
- package/dist/commands/release.command.js +99 -20
- package/dist/commands/report.command.d.ts.map +1 -1
- package/dist/commands/report.command.js +38 -2
- package/dist/commands/reuse-coverage.command.d.ts +23 -0
- package/dist/commands/reuse-coverage.command.d.ts.map +1 -0
- package/dist/commands/reuse-coverage.command.js +536 -0
- package/dist/commands/reuse.command.d.ts +3 -18
- package/dist/commands/reuse.command.d.ts.map +1 -1
- package/dist/commands/reuse.command.js +395 -244
- package/dist/commands/review.command.d.ts.map +1 -1
- package/dist/commands/review.command.js +33 -1
- package/dist/commands/rounds.command.d.ts.map +1 -1
- package/dist/commands/rounds.command.js +5 -0
- package/dist/commands/safety.command.d.ts.map +1 -1
- package/dist/commands/safety.command.js +9 -0
- package/dist/commands/scaffolds.command.d.ts.map +1 -1
- package/dist/commands/scaffolds.command.js +97 -25
- package/dist/commands/search.command.d.ts +0 -8
- package/dist/commands/search.command.d.ts.map +1 -1
- package/dist/commands/search.command.js +136 -28
- package/dist/commands/self-config-xrefs.command.d.ts +24 -0
- package/dist/commands/self-config-xrefs.command.d.ts.map +1 -0
- package/dist/commands/self-config-xrefs.command.js +170 -0
- package/dist/commands/self-config.command.d.ts.map +1 -1
- package/dist/commands/self-config.command.js +261 -65
- package/dist/commands/smart-context.command.d.ts.map +1 -1
- package/dist/commands/smart-context.command.js +39 -3
- package/dist/commands/spec.command.d.ts.map +1 -1
- package/dist/commands/spec.command.js +3 -0
- package/dist/commands/stats.command.d.ts.map +1 -1
- package/dist/commands/stats.command.js +3 -0
- package/dist/commands/surface.command.d.ts +6 -1
- package/dist/commands/surface.command.d.ts.map +1 -1
- package/dist/commands/surface.command.js +256 -54
- package/dist/commands/task-context.command.js +1 -1
- package/dist/commands/task.command.d.ts.map +1 -1
- package/dist/commands/task.command.js +22 -1
- package/dist/commands/templates.command.d.ts +4 -0
- package/dist/commands/templates.command.d.ts.map +1 -1
- package/dist/commands/templates.command.js +109 -22
- package/dist/commands/test.command.d.ts.map +1 -1
- package/dist/commands/test.command.js +161 -33
- package/dist/commands/tests.command.d.ts.map +1 -1
- package/dist/commands/tests.command.js +29 -3
- package/dist/commands/trace.command.d.ts.map +1 -1
- package/dist/commands/trace.command.js +29 -4
- package/dist/commands/watch.command.d.ts.map +1 -1
- package/dist/commands/watch.command.js +3 -0
- package/dist/commands/why.command.d.ts.map +1 -1
- package/dist/commands/why.command.js +3 -0
- package/dist/commands/wiring.command.d.ts +18 -4
- package/dist/commands/wiring.command.d.ts.map +1 -1
- package/dist/commands/wiring.command.js +360 -73
- package/dist/dashboard/code-intelligence-data.js +4 -4
- package/dist/diff/deleted-orphan-coverage.d.ts +32 -0
- package/dist/diff/deleted-orphan-coverage.d.ts.map +1 -0
- package/dist/diff/deleted-orphan-coverage.js +107 -0
- package/dist/diff/deleted-orphan-scope-notes.d.ts +23 -0
- package/dist/diff/deleted-orphan-scope-notes.d.ts.map +1 -0
- package/dist/diff/deleted-orphan-scope-notes.js +49 -0
- package/dist/diff/deleted-orphans.d.ts +32 -0
- package/dist/diff/deleted-orphans.d.ts.map +1 -1
- package/dist/diff/deleted-orphans.js +42 -2
- package/dist/dispatch/closest-match.d.ts +15 -0
- package/dist/dispatch/closest-match.d.ts.map +1 -0
- package/dist/dispatch/closest-match.js +47 -0
- package/dist/dispatch/global-flags.d.ts +94 -0
- package/dist/dispatch/global-flags.d.ts.map +1 -0
- package/dist/dispatch/global-flags.js +123 -0
- package/dist/dispatch/guard-invocation-input.d.ts +24 -0
- package/dist/dispatch/guard-invocation-input.d.ts.map +1 -0
- package/dist/dispatch/guard-invocation-input.js +1 -0
- package/dist/dispatch/guard-invocation.d.ts +33 -0
- package/dist/dispatch/guard-invocation.d.ts.map +1 -0
- package/dist/dispatch/guard-invocation.js +183 -0
- package/dist/dispatch/help-intercept.d.ts +22 -0
- package/dist/dispatch/help-intercept.d.ts.map +1 -0
- package/dist/dispatch/help-intercept.js +42 -0
- package/dist/dispatch/i-declared-invocation.d.ts +17 -0
- package/dist/dispatch/i-declared-invocation.d.ts.map +1 -0
- package/dist/dispatch/i-declared-invocation.js +1 -0
- package/dist/dispatch/i-unknown-flag-refusal-input.d.ts +28 -0
- package/dist/dispatch/i-unknown-flag-refusal-input.d.ts.map +1 -0
- package/dist/dispatch/i-unknown-flag-refusal-input.js +1 -0
- package/dist/dispatch/invocation-rejection-kind.d.ts +15 -0
- package/dist/dispatch/invocation-rejection-kind.d.ts.map +1 -0
- package/dist/dispatch/invocation-rejection-kind.js +15 -0
- package/dist/dispatch/invocation-rejection.d.ts +18 -0
- package/dist/dispatch/invocation-rejection.d.ts.map +1 -0
- package/dist/dispatch/invocation-rejection.js +1 -0
- package/dist/dispatch/judge-invocation.d.ts +24 -0
- package/dist/dispatch/judge-invocation.d.ts.map +1 -0
- package/dist/dispatch/judge-invocation.js +50 -0
- package/dist/dispatch/positional-mode.d.ts +18 -0
- package/dist/dispatch/positional-mode.d.ts.map +1 -0
- package/dist/dispatch/positional-mode.js +18 -0
- package/dist/dispatch/read-tracking-map.d.ts +28 -0
- package/dist/dispatch/read-tracking-map.d.ts.map +1 -0
- package/dist/dispatch/read-tracking-map.js +58 -0
- package/dist/dispatch/refuse-sibling-valve-flags.d.ts +30 -0
- package/dist/dispatch/refuse-sibling-valve-flags.d.ts.map +1 -0
- package/dist/dispatch/refuse-sibling-valve-flags.js +65 -0
- package/dist/dispatch/subverb-spec.d.ts +26 -0
- package/dist/dispatch/subverb-spec.d.ts.map +1 -0
- package/dist/dispatch/subverb-spec.js +1 -0
- package/dist/dispatch/undocumented-flag-reads.d.ts +22 -0
- package/dist/dispatch/undocumented-flag-reads.d.ts.map +1 -0
- package/dist/dispatch/undocumented-flag-reads.js +283 -0
- package/dist/dispatch/unknown-flag-refusal-mode.d.ts +13 -0
- package/dist/dispatch/unknown-flag-refusal-mode.d.ts.map +1 -0
- package/dist/dispatch/unknown-flag-refusal-mode.js +13 -0
- package/dist/dispatch/unknown-flag-refusal.d.ts +22 -0
- package/dist/dispatch/unknown-flag-refusal.d.ts.map +1 -0
- package/dist/dispatch/unknown-flag-refusal.js +57 -0
- package/dist/dispatch/unread-flags.d.ts +152 -0
- package/dist/dispatch/unread-flags.d.ts.map +1 -0
- package/dist/dispatch/unread-flags.js +295 -0
- package/dist/dispatch/verdict-valve-flag.d.ts +21 -0
- package/dist/dispatch/verdict-valve-flag.d.ts.map +1 -0
- package/dist/dispatch/verdict-valve-flag.js +21 -0
- package/dist/dispatch/walk-declared-subverbs.d.ts +14 -0
- package/dist/dispatch/walk-declared-subverbs.d.ts.map +1 -0
- package/dist/dispatch/walk-declared-subverbs.js +28 -0
- package/dist/exit-codes.d.ts +41 -3
- package/dist/exit-codes.d.ts.map +1 -1
- package/dist/exit-codes.js +153 -14
- package/dist/finish/run-finish.d.ts +72 -5
- package/dist/finish/run-finish.d.ts.map +1 -1
- package/dist/finish/run-finish.js +453 -104
- package/dist/gates/accepted-empty-note.d.ts +10 -0
- package/dist/gates/accepted-empty-note.d.ts.map +1 -0
- package/dist/gates/accepted-empty-note.js +11 -0
- package/dist/gates/allow-empty.d.ts +25 -0
- package/dist/gates/allow-empty.d.ts.map +1 -0
- package/dist/gates/allow-empty.js +27 -0
- package/dist/gates/asset-doctor-failing-units.d.ts +16 -0
- package/dist/gates/asset-doctor-failing-units.d.ts.map +1 -0
- package/dist/gates/asset-doctor-failing-units.js +14 -0
- package/dist/gates/asset-doctor-failure-line.d.ts +16 -0
- package/dist/gates/asset-doctor-failure-line.d.ts.map +1 -0
- package/dist/gates/asset-doctor-failure-line.js +28 -0
- package/dist/gates/empty-rule-advice-lines.d.ts +15 -0
- package/dist/gates/empty-rule-advice-lines.d.ts.map +1 -0
- package/dist/gates/empty-rule-advice-lines.js +20 -0
- package/dist/gates/gate-envelope.d.ts +85 -8
- package/dist/gates/gate-envelope.d.ts.map +1 -1
- package/dist/gates/gate-envelope.js +56 -7
- package/dist/gates/gate-rule-globs.d.ts +37 -3
- package/dist/gates/gate-rule-globs.d.ts.map +1 -1
- package/dist/gates/gate-rule-globs.js +78 -40
- package/dist/gates/gate-rule-view.d.ts +17 -4
- package/dist/gates/gate-rule-view.d.ts.map +1 -1
- package/dist/gates/gate-rule-view.js +105 -90
- package/dist/gates/i-coverage-dead-glob.d.ts +19 -0
- package/dist/gates/i-coverage-dead-glob.d.ts.map +1 -0
- package/dist/gates/i-coverage-dead-glob.js +1 -0
- package/dist/gates/i-coverage-negation.d.ts +13 -0
- package/dist/gates/i-coverage-negation.d.ts.map +1 -0
- package/dist/gates/i-coverage-negation.js +1 -0
- package/dist/gates/i-registration-query-settle-input.d.ts +18 -0
- package/dist/gates/i-registration-query-settle-input.d.ts.map +1 -0
- package/dist/gates/i-registration-query-settle-input.js +1 -0
- package/dist/gates/i-unit-state-note-row.d.ts +16 -0
- package/dist/gates/i-unit-state-note-row.d.ts.map +1 -0
- package/dist/gates/i-unit-state-note-row.js +1 -0
- package/dist/gates/i-unit-state-notes.d.ts +32 -0
- package/dist/gates/i-unit-state-notes.d.ts.map +1 -0
- package/dist/gates/i-unit-state-notes.js +1 -0
- package/dist/gates/incomplete-registry-inventory.d.ts +19 -0
- package/dist/gates/incomplete-registry-inventory.d.ts.map +1 -0
- package/dist/gates/incomplete-registry-inventory.js +63 -0
- package/dist/gates/measure-registration-roles.d.ts +10 -0
- package/dist/gates/measure-registration-roles.d.ts.map +1 -0
- package/dist/gates/measure-registration-roles.js +9 -0
- package/dist/gates/plane-verdict.d.ts +14 -0
- package/dist/gates/plane-verdict.d.ts.map +1 -0
- package/dist/gates/plane-verdict.js +22 -0
- package/dist/gates/qualify-clean-for-units.d.ts +12 -0
- package/dist/gates/qualify-clean-for-units.d.ts.map +1 -0
- package/dist/gates/qualify-clean-for-units.js +18 -0
- package/dist/gates/registration-graph-verdict.d.ts +34 -0
- package/dist/gates/registration-graph-verdict.d.ts.map +1 -0
- package/dist/gates/registration-graph-verdict.js +70 -0
- package/dist/gates/registration-roles.d.ts +9 -0
- package/dist/gates/registration-roles.d.ts.map +1 -0
- package/dist/gates/registration-roles.js +1 -0
- package/dist/gates/registry-liveness.d.ts +11 -0
- package/dist/gates/registry-liveness.d.ts.map +1 -0
- package/dist/gates/registry-liveness.js +13 -0
- package/dist/gates/rule-coverage.d.ts +187 -4
- package/dist/gates/rule-coverage.d.ts.map +1 -1
- package/dist/gates/rule-coverage.js +501 -49
- package/dist/gates/run-gate-planes.d.ts +14 -0
- package/dist/gates/run-gate-planes.d.ts.map +1 -1
- package/dist/gates/run-gate-planes.js +172 -30
- package/dist/gates/scaffold-selftest.d.ts +56 -0
- package/dist/gates/scaffold-selftest.d.ts.map +1 -0
- package/dist/gates/scaffold-selftest.js +119 -0
- package/dist/gates/seam-rejected-rules.d.ts +28 -0
- package/dist/gates/seam-rejected-rules.d.ts.map +1 -0
- package/dist/gates/seam-rejected-rules.js +95 -0
- package/dist/gates/self-test-check.d.ts +29 -0
- package/dist/gates/self-test-check.d.ts.map +1 -0
- package/dist/gates/self-test-check.js +1 -0
- package/dist/gates/self-test-subject.d.ts +28 -0
- package/dist/gates/self-test-subject.d.ts.map +1 -0
- package/dist/gates/self-test-subject.js +1 -0
- package/dist/gates/self-test.d.ts +20 -0
- package/dist/gates/self-test.d.ts.map +1 -0
- package/dist/gates/self-test.js +82 -0
- package/dist/gates/settle-verdict.d.ts +14 -0
- package/dist/gates/settle-verdict.d.ts.map +1 -0
- package/dist/gates/settle-verdict.js +13 -0
- package/dist/gates/settled-verdict.d.ts +8 -0
- package/dist/gates/settled-verdict.d.ts.map +1 -0
- package/dist/gates/settled-verdict.js +1 -0
- package/dist/gates/template-registry-coverage.d.ts +18 -0
- package/dist/gates/template-registry-coverage.d.ts.map +1 -0
- package/dist/gates/template-registry-coverage.js +24 -0
- package/dist/gates/unit-state-notes.d.ts +40 -0
- package/dist/gates/unit-state-notes.d.ts.map +1 -0
- package/dist/gates/unit-state-notes.js +71 -0
- package/dist/gates/verdict-line.d.ts +18 -0
- package/dist/gates/verdict-line.d.ts.map +1 -0
- package/dist/gates/verdict-line.js +40 -0
- package/dist/graph/graph-reuse-lookup.d.ts +10 -0
- package/dist/graph/graph-reuse-lookup.d.ts.map +1 -0
- package/dist/graph/graph-reuse-lookup.js +41 -0
- package/dist/graph/index-behind-hint.d.ts +11 -0
- package/dist/graph/index-behind-hint.d.ts.map +1 -0
- package/dist/graph/index-behind-hint.js +27 -0
- package/dist/knowledge/knowledge-stale-gate-flags.d.ts +3 -0
- package/dist/knowledge/knowledge-stale-gate-flags.d.ts.map +1 -0
- package/dist/knowledge/knowledge-stale-gate-flags.js +1 -0
- package/dist/knowledge/knowledge-stale-gate-input.d.ts +3 -0
- package/dist/knowledge/knowledge-stale-gate-input.d.ts.map +1 -0
- package/dist/knowledge/knowledge-stale-gate-input.js +1 -0
- package/dist/knowledge/knowledge-stale-gate-result.d.ts +3 -0
- package/dist/knowledge/knowledge-stale-gate-result.d.ts.map +1 -0
- package/dist/knowledge/knowledge-stale-gate-result.js +1 -0
- package/dist/knowledge/knowledge-stale-gate.d.ts +10 -0
- package/dist/knowledge/knowledge-stale-gate.d.ts.map +1 -0
- package/dist/knowledge/knowledge-stale-gate.js +9 -0
- package/dist/main.d.ts.map +1 -1
- package/dist/main.js +200 -83
- package/dist/output/failure-hints.d.ts.map +1 -1
- package/dist/output/failure-hints.js +11 -9
- package/dist/output/rejected-entries-note.d.ts +57 -0
- package/dist/output/rejected-entries-note.d.ts.map +1 -0
- package/dist/output/rejected-entries-note.js +103 -0
- package/dist/output/stdout-is-pipe.d.ts +13 -0
- package/dist/output/stdout-is-pipe.d.ts.map +1 -0
- package/dist/output/stdout-is-pipe.js +21 -0
- package/dist/packs/stale-build-warning.d.ts +11 -0
- package/dist/packs/stale-build-warning.d.ts.map +1 -0
- package/dist/packs/stale-build-warning.js +23 -0
- package/dist/quality/run-quality.d.ts +123 -0
- package/dist/quality/run-quality.d.ts.map +1 -0
- package/dist/quality/run-quality.js +442 -0
- package/dist/schemas/json-schemas.d.ts +184 -3
- package/dist/schemas/json-schemas.d.ts.map +1 -1
- package/dist/schemas/json-schemas.js +113 -2
- package/dist/shrk.d.ts +3 -0
- package/dist/shrk.d.ts.map +1 -0
- package/dist/shrk.js +30 -0
- package/dist/surface/audience-applicability.d.ts +26 -0
- package/dist/surface/audience-applicability.d.ts.map +1 -0
- package/dist/surface/audience-applicability.js +60 -0
- package/dist/surface/catalog-command-safety.d.ts +18 -0
- package/dist/surface/catalog-command-safety.d.ts.map +1 -0
- package/dist/surface/catalog-command-safety.js +62 -0
- package/dist/surface/cli-command-resolver.d.ts +21 -0
- package/dist/surface/cli-command-resolver.d.ts.map +1 -0
- package/dist/surface/cli-command-resolver.js +87 -0
- package/dist/surface/command-dispatch-kind.d.ts +20 -0
- package/dist/surface/command-dispatch-kind.d.ts.map +1 -0
- package/dist/surface/command-dispatch-kind.js +20 -0
- package/dist/surface/command-index-entry.d.ts +40 -0
- package/dist/surface/command-index-entry.d.ts.map +1 -0
- package/dist/surface/command-index-entry.js +1 -0
- package/dist/surface/command-index.d.ts +77 -0
- package/dist/surface/command-index.d.ts.map +1 -0
- package/dist/surface/command-index.js +323 -0
- package/dist/surface/i-command-index.d.ts +22 -0
- package/dist/surface/i-command-index.d.ts.map +1 -0
- package/dist/surface/i-command-index.js +1 -0
- package/dist/surface/i-command-string-context.d.ts +20 -0
- package/dist/surface/i-command-string-context.d.ts.map +1 -0
- package/dist/surface/i-command-string-context.js +1 -0
- package/dist/surface/i-surface-denial.d.ts +13 -0
- package/dist/surface/i-surface-denial.d.ts.map +1 -0
- package/dist/surface/i-surface-denial.js +1 -0
- package/dist/surface/load-surface-context.d.ts +17 -1
- package/dist/surface/load-surface-context.d.ts.map +1 -1
- package/dist/surface/load-surface-context.js +48 -10
- package/dist/surface/not-enabled-error.d.ts +38 -4
- package/dist/surface/not-enabled-error.d.ts.map +1 -1
- package/dist/surface/not-enabled-error.js +96 -6
- package/dist/surface/profiles.d.ts +7 -0
- package/dist/surface/profiles.d.ts.map +1 -1
- package/dist/surface/resolve-command-string.d.ts +10 -0
- package/dist/surface/resolve-command-string.d.ts.map +1 -0
- package/dist/surface/resolve-command-string.js +572 -0
- package/dist/surface/surface-config-writer.d.ts +7 -2
- package/dist/surface/surface-config-writer.d.ts.map +1 -1
- package/dist/surface/surface-config-writer.js +25 -6
- package/dist/surface/surface-layer.d.ts +11 -0
- package/dist/surface/surface-layer.d.ts.map +1 -0
- package/dist/surface/surface-layer.js +11 -0
- package/dist/surface/surface-refusal-reason.d.ts +16 -0
- package/dist/surface/surface-refusal-reason.d.ts.map +1 -0
- package/dist/surface/surface-refusal-reason.js +16 -0
- package/dist/surface/surface-selector.d.ts +26 -0
- package/dist/surface/surface-selector.d.ts.map +1 -0
- package/dist/surface/surface-selector.js +42 -0
- package/dist/surface/surface-summary.d.ts +61 -18
- package/dist/surface/surface-summary.d.ts.map +1 -1
- package/dist/surface/surface-summary.js +147 -60
- package/dist/surface/tier.d.ts +85 -22
- package/dist/surface/tier.d.ts.map +1 -1
- package/dist/surface/tier.js +132 -30
- package/dist/usage/usage-log.d.ts +6 -1
- package/dist/usage/usage-log.d.ts.map +1 -1
- package/dist/usage/usage-log.js +7 -2
- package/dist/validation/run-validation-loop.d.ts +9 -0
- package/dist/validation/run-validation-loop.d.ts.map +1 -1
- package/dist/validation/run-validation-loop.js +14 -11
- package/dist/validation/typecheck-emitted.d.ts +8 -9
- package/dist/validation/typecheck-emitted.d.ts.map +1 -1
- package/dist/validation/typecheck-emitted.js +17 -97
- package/package.json +34 -34
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"review.command.d.ts","sourceRoot":"","sources":["../../src/commands/review.command.ts"],"names":[],"mappings":"AAgBA,OAAO,EAML,KAAK,eAAe,EAErB,MAAM,wBAAwB,CAAC;
|
|
1
|
+
{"version":3,"file":"review.command.d.ts","sourceRoot":"","sources":["../../src/commands/review.command.ts"],"names":[],"mappings":"AAgBA,OAAO,EAML,KAAK,eAAe,EAErB,MAAM,wBAAwB,CAAC;AAyHhC,eAAO,MAAM,aAAa,EAAE,eAwH3B,CAAC"}
|
|
@@ -2,6 +2,7 @@ import { existsSync, readFileSync, writeFileSync } from 'node:fs';
|
|
|
2
2
|
import * as nodePath from 'node:path';
|
|
3
3
|
import { buildReviewPacket, buildReviewPacketV2, buildReviewPacketV3, inspectSharkcraft, renderReviewComment, renderReviewCommentV2, renderReviewCommentV3, REVIEW_PACKET_V2_SCHEMA, REVIEW_PACKET_V3_SCHEMA, } from '@shrkcrft/inspector';
|
|
4
4
|
import { flagBool, flagNumber, flagString, flagList, resolveCwd, } from "../command-registry.js";
|
|
5
|
+
import { PositionalMode } from "../dispatch/positional-mode.js";
|
|
5
6
|
import { asJson, header, kv } from "../output/format-output.js";
|
|
6
7
|
function renderGithubActionYaml(options) {
|
|
7
8
|
const steps = [];
|
|
@@ -74,8 +75,39 @@ function scaffoldOptionsFromArgs(args) {
|
|
|
74
75
|
commentPlaceholder: flagBool(args, 'comment-placeholder'),
|
|
75
76
|
};
|
|
76
77
|
}
|
|
78
|
+
/**
|
|
79
|
+
* Every flag `render-comment` reads, in every packet mode: the v1 renderer
|
|
80
|
+
* reads the artifact flags (`--boundaries|--coverage|--drift <file>`) through
|
|
81
|
+
* `readArtifact(args, name)` — undocumented, a v3 packet (which never reads
|
|
82
|
+
* them) turned `--boundaries b.json` into an "ignored flag" exit 2.
|
|
83
|
+
*/
|
|
84
|
+
const RENDER_COMMENT_USAGE = 'shrk review render-comment <packet.json> [--output <file>] [--title <title>] [--format markdown|html|github|gitlab] ' +
|
|
85
|
+
'[--max-files N] [--max-items N] [--max-rules N] [--include-boundaries] [--include-coverage] [--include-drift] ' +
|
|
86
|
+
'[--collapse-long-sections] [--boundaries <file>] [--coverage <file>] [--drift <file>]';
|
|
77
87
|
export const reviewCommand = {
|
|
78
88
|
name: 'review',
|
|
89
|
+
// positionals are changed FILES (`review a.ts b.ts`) or a verb: a
|
|
90
|
+
// verb-shaped token that is neither is refused, not reviewed as a file.
|
|
91
|
+
positionals: PositionalMode.Path,
|
|
92
|
+
subverbs: [
|
|
93
|
+
{
|
|
94
|
+
name: 'scaffold',
|
|
95
|
+
description: 'Print a PR-review workflow template.',
|
|
96
|
+
usage: 'shrk review scaffold github-action [--with-boundaries] [--with-coverage] [--with-drift] [--artifact-only] [--comment-placeholder]',
|
|
97
|
+
positionals: PositionalMode.Free,
|
|
98
|
+
},
|
|
99
|
+
{
|
|
100
|
+
name: 'render-comment',
|
|
101
|
+
description: 'Render a Markdown PR comment from a saved packet.',
|
|
102
|
+
usage: RENDER_COMMENT_USAGE,
|
|
103
|
+
positionals: PositionalMode.Path,
|
|
104
|
+
},
|
|
105
|
+
{
|
|
106
|
+
name: 'packet',
|
|
107
|
+
description: 'Build the review packet.',
|
|
108
|
+
usage: 'shrk review packet [files... | --files a,b] [--since <ref>] [--staged] [--json]',
|
|
109
|
+
},
|
|
110
|
+
],
|
|
79
111
|
description: 'Build a PR-review packet: changed files (via git), affected path conventions, relevant rules/templates/pipelines, boundary violations on those files, missing-test heuristic, verification commands. Also: `shrk review scaffold github-action` prints a workflow template with optional `--with-boundaries / --with-coverage / --with-drift / --artifact-only / --comment-placeholder` flags. `shrk review render-comment <packet.json>` renders a Markdown PR comment from a saved packet.',
|
|
80
112
|
usage: 'shrk [--cwd <dir>] review [files... | --files a,b] [--since <ref>] [--staged] [--no-untracked] [--json] | shrk review scaffold github-action [...] | shrk review render-comment <packet.json> [--output <file>]',
|
|
81
113
|
booleanFlags: new Set([
|
|
@@ -172,7 +204,7 @@ export const reviewCommand = {
|
|
|
172
204
|
async function runRenderComment(args) {
|
|
173
205
|
const inputPath = args.positional[1];
|
|
174
206
|
if (!inputPath) {
|
|
175
|
-
process.stderr.write(
|
|
207
|
+
process.stderr.write(`Usage: ${RENDER_COMMENT_USAGE}\n`);
|
|
176
208
|
return 2;
|
|
177
209
|
}
|
|
178
210
|
const full = nodePath.isAbsolute(inputPath)
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"rounds.command.d.ts","sourceRoot":"","sources":["../../src/commands/rounds.command.ts"],"names":[],"mappings":"AAsBA,OAAO,EAIL,KAAK,eAAe,EAErB,MAAM,wBAAwB,CAAC;
|
|
1
|
+
{"version":3,"file":"rounds.command.d.ts","sourceRoot":"","sources":["../../src/commands/rounds.command.ts"],"names":[],"mappings":"AAsBA,OAAO,EAIL,KAAK,eAAe,EAErB,MAAM,wBAAwB,CAAC;AAkBhC,eAAO,MAAM,oBAAoB,EAAE,eAgClC,CAAC;AAEF,eAAO,MAAM,iBAAiB,EAAE,eAmB/B,CAAC;AAEF,eAAO,MAAM,iBAAiB,EAAE,eAiC/B,CAAC;AAEF,eAAO,MAAM,iBAAiB,EAAE,eAgB/B,CAAC;AAEF,eAAO,MAAM,mBAAmB,EAAE,eAejC,CAAC;AAEF,eAAO,MAAM,iBAAiB,EAAE,eAoC/B,CAAC"}
|
|
@@ -12,6 +12,7 @@ import { ALL_TOOLS } from '@shrkcrft/mcp-server';
|
|
|
12
12
|
import { captureRoundSnapshot, diffRounds as diffRoundSnapshots, listRoundIds, loadRoundSnapshot, renderRoundsDiffMarkdown, writeRoundSnapshot, } from '@shrkcrft/inspector';
|
|
13
13
|
import { COMMAND_CATALOG } from "./command-catalog.js";
|
|
14
14
|
import { flagBool, flagString, resolveCwd, } from "../command-registry.js";
|
|
15
|
+
import { PositionalMode } from "../dispatch/positional-mode.js";
|
|
15
16
|
import { asJson, header } from "../output/format-output.js";
|
|
16
17
|
function collectCommandsFromCatalog() {
|
|
17
18
|
return COMMAND_CATALOG.map((e) => ({
|
|
@@ -115,6 +116,8 @@ export const roundsShowCommand = {
|
|
|
115
116
|
};
|
|
116
117
|
export const diffParentCommand = {
|
|
117
118
|
name: 'diff',
|
|
119
|
+
// Mixed-mode: `rounds` is a trie child.
|
|
120
|
+
positionals: PositionalMode.None,
|
|
118
121
|
description: 'Diff two artifacts. Currently supports `diff rounds` for round-to-round snapshot diffs.',
|
|
119
122
|
usage: 'shrk diff rounds --from <id> --to <id> [--json]',
|
|
120
123
|
async run(args) {
|
|
@@ -129,6 +132,8 @@ export const diffParentCommand = {
|
|
|
129
132
|
};
|
|
130
133
|
export const roundsParentCommand = {
|
|
131
134
|
name: 'rounds',
|
|
135
|
+
// Mixed-mode: capture / list / show are trie children.
|
|
136
|
+
positionals: PositionalMode.None,
|
|
132
137
|
description: 'Capture / list / show round snapshots under .sharkcraft/rounds/.',
|
|
133
138
|
usage: 'shrk rounds [capture|list|show] [args]',
|
|
134
139
|
async run(args) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"safety.command.d.ts","sourceRoot":"","sources":["../../src/commands/safety.command.ts"],"names":[],"mappings":"AAMA,OAAO,EAGL,KAAK,eAAe,EAErB,MAAM,wBAAwB,CAAC;
|
|
1
|
+
{"version":3,"file":"safety.command.d.ts","sourceRoot":"","sources":["../../src/commands/safety.command.ts"],"names":[],"mappings":"AAMA,OAAO,EAGL,KAAK,eAAe,EAErB,MAAM,wBAAwB,CAAC;AAOhC,eAAO,MAAM,aAAa,EAAE,eA2E3B,CAAC"}
|
|
@@ -1,10 +1,19 @@
|
|
|
1
1
|
import { buildSafetyAudit, buildSafetyAuditDeep, inspectSharkcraft, } from '@shrkcrft/inspector';
|
|
2
2
|
import { flagBool, resolveCwd, } from "../command-registry.js";
|
|
3
|
+
import { PositionalMode } from "../dispatch/positional-mode.js";
|
|
3
4
|
import { asJson, header, kv } from "../output/format-output.js";
|
|
4
5
|
import { COMMAND_CATALOG } from "./command-catalog.js";
|
|
5
6
|
const PLAN_SECRET_ENV = 'SHARKCRAFT_PLAN_SECRET';
|
|
6
7
|
export const safetyCommand = {
|
|
7
8
|
name: 'safety',
|
|
9
|
+
positionals: PositionalMode.None,
|
|
10
|
+
subverbs: [
|
|
11
|
+
{
|
|
12
|
+
name: 'audit',
|
|
13
|
+
description: 'Audit the safety model: writers, shell runners, the MCP read-only invariant, signatures.',
|
|
14
|
+
usage: 'shrk safety audit [--deep] [--json]',
|
|
15
|
+
},
|
|
16
|
+
],
|
|
8
17
|
description: 'Audit the SharkCraft safety model: which commands write source, which run shell, MCP read-only invariant, pack signature status, plan-signing status. Read-only.',
|
|
9
18
|
usage: 'shrk safety audit [--json]',
|
|
10
19
|
async run(args) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"scaffolds.command.d.ts","sourceRoot":"","sources":["../../src/commands/scaffolds.command.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"scaffolds.command.d.ts","sourceRoot":"","sources":["../../src/commands/scaffolds.command.ts"],"names":[],"mappings":"AAYA,OAAO,EAGL,KAAK,eAAe,EAErB,MAAM,wBAAwB,CAAC;AAShC,eAAO,MAAM,oBAAoB,EAAE,eAmDlC,CAAC;AAEF,eAAO,MAAM,mBAAmB,EAAE,eAuCjC,CAAC;AAEF,eAAO,MAAM,sBAAsB,EAAE,eA8FpC,CAAC"}
|
|
@@ -1,6 +1,13 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { assetDoctorProposedExit, buildScaffoldPatternDoctorReport, collectKindRejections, ContributionKind, contributionFileLabel, formatEntryRejection, inspectSharkcraft, loadScaffoldPatternsFromInspection, settledUnitStates, } from '@shrkcrft/inspector';
|
|
2
|
+
import { formatCoverage } from '@shrkcrft/core';
|
|
2
3
|
import { flagBool, resolveCwd, } from "../command-registry.js";
|
|
3
4
|
import { asJson, header, kv } from "../output/format-output.js";
|
|
5
|
+
import { rejectedEntriesNote } from "../output/rejected-entries-note.js";
|
|
6
|
+
import { ALLOW_EMPTY_FLAG, allowEmptyValve } from "../gates/allow-empty.js";
|
|
7
|
+
import { assetDoctorFailingUnits } from "../gates/asset-doctor-failing-units.js";
|
|
8
|
+
import { assetDoctorFailureLine } from "../gates/asset-doctor-failure-line.js";
|
|
9
|
+
import { settleVerdict } from "../gates/settle-verdict.js";
|
|
10
|
+
import { verdictLine } from "../gates/verdict-line.js";
|
|
4
11
|
export const scaffoldsListCommand = {
|
|
5
12
|
name: 'list',
|
|
6
13
|
description: 'List every scaffold pattern contributed by an installed pack.',
|
|
@@ -9,6 +16,10 @@ export const scaffoldsListCommand = {
|
|
|
9
16
|
const cwd = resolveCwd(args);
|
|
10
17
|
const inspection = await inspectSharkcraft({ cwd });
|
|
11
18
|
const result = await loadScaffoldPatternsFromInspection(inspection);
|
|
19
|
+
// THE rejection channel (round 12, 12.1): a pattern the loader refused
|
|
20
|
+
// (no templateId / matchPaths / confidence, a duplicate id) is a record
|
|
21
|
+
// with every reason — it used to be a raw `! …` warning string.
|
|
22
|
+
const rejected = await collectKindRejections(inspection, [ContributionKind.ScaffoldPattern]);
|
|
12
23
|
if (flagBool(args, 'json')) {
|
|
13
24
|
process.stdout.write(asJson({
|
|
14
25
|
patterns: result.patterns.map((p) => ({
|
|
@@ -17,20 +28,23 @@ export const scaffoldsListCommand = {
|
|
|
17
28
|
templateId: p.pattern.templateId,
|
|
18
29
|
confidence: p.pattern.confidence,
|
|
19
30
|
matchPaths: p.pattern.matchPaths,
|
|
31
|
+
...(p.pattern.expectEmptyUnits ? { expectEmptyUnits: p.pattern.expectEmptyUnits } : {}),
|
|
20
32
|
appliesWhen: p.pattern.appliesWhen,
|
|
21
33
|
source: p.source,
|
|
22
34
|
})),
|
|
23
35
|
warnings: result.warnings,
|
|
36
|
+
rejected: rejected.map((r) => ({ ...r, file: contributionFileLabel(inspection.projectRoot, r.file) })),
|
|
24
37
|
}) + '\n');
|
|
25
38
|
return 0;
|
|
26
39
|
}
|
|
27
40
|
process.stdout.write(header(`Scaffold patterns (${result.patterns.length})`));
|
|
28
41
|
for (const p of result.patterns) {
|
|
29
|
-
process.stdout.write(` • ${p.pattern.id.padEnd(36)} ${p.pattern.confidence.padEnd(7)} → ${p.pattern.templateId}\n`);
|
|
30
|
-
process.stdout.write(` ${p.pattern.title}\n`);
|
|
42
|
+
process.stdout.write(` • ${p.pattern.id.padEnd(36)} ${String(p.pattern.confidence).padEnd(7)} → ${p.pattern.templateId}\n`);
|
|
43
|
+
process.stdout.write(` ${p.pattern.title ?? ''}\n`);
|
|
31
44
|
process.stdout.write(` source: ${p.source.packageName ?? p.source.type}\n`);
|
|
32
45
|
}
|
|
33
46
|
if (result.warnings.length > 0) {
|
|
47
|
+
// File-level problems (missing, not an array, failed to import).
|
|
34
48
|
process.stdout.write('\nWarnings:\n');
|
|
35
49
|
for (const w of result.warnings)
|
|
36
50
|
process.stdout.write(` ! ${w}\n`);
|
|
@@ -38,6 +52,9 @@ export const scaffoldsListCommand = {
|
|
|
38
52
|
if (result.patterns.length === 0) {
|
|
39
53
|
process.stdout.write('\nNo scaffold patterns found. Packs can contribute them via `scaffoldPatternFiles`.\n');
|
|
40
54
|
}
|
|
55
|
+
const note = rejectedEntriesNote(rejected, inspection.projectRoot, 'shrk scaffolds doctor');
|
|
56
|
+
if (note)
|
|
57
|
+
process.stdout.write(`\n${note}`);
|
|
41
58
|
return 0;
|
|
42
59
|
},
|
|
43
60
|
};
|
|
@@ -69,8 +86,11 @@ export const scaffoldsGetCommand = {
|
|
|
69
86
|
process.stdout.write(kv('confidence', match.pattern.confidence) + '\n');
|
|
70
87
|
process.stdout.write(kv('source', match.source.packageName ?? match.source.type) + '\n');
|
|
71
88
|
process.stdout.write(`\nMatch paths:\n`);
|
|
72
|
-
|
|
73
|
-
|
|
89
|
+
const marked = new Map((match.pattern.expectEmptyUnits ?? []).map((m) => [m.unit, m]));
|
|
90
|
+
for (const m of match.pattern.matchPaths) {
|
|
91
|
+
const mark = marked.get(m);
|
|
92
|
+
process.stdout.write(` - ${m}${mark ? ` (expectEmpty${mark.reason ? `: ${mark.reason}` : ''})` : ''}\n`);
|
|
93
|
+
}
|
|
74
94
|
process.stdout.write(`\nApplies when:\n`);
|
|
75
95
|
for (const a of match.pattern.appliesWhen)
|
|
76
96
|
process.stdout.write(` - ${a}\n`);
|
|
@@ -82,41 +102,93 @@ export const scaffoldsGetCommand = {
|
|
|
82
102
|
};
|
|
83
103
|
export const scaffoldsDoctorCommand = {
|
|
84
104
|
name: 'doctor',
|
|
85
|
-
description: 'Validate scaffold pattern definitions (templates exist, strategies recognized, …).',
|
|
86
|
-
usage: 'shrk scaffolds doctor [--json]',
|
|
105
|
+
description: 'Validate scaffold pattern definitions (templates exist, strategies recognized, …) and count the files every matchPaths glob matches — a glob or pattern matching nothing is a dead unit (exit 2), unless the glob is marked { pattern, expectEmpty: true } (accepted, printed; reported once a file matches).',
|
|
106
|
+
usage: 'shrk scaffolds doctor [--json] [--strict] [--fail-on-dead-units] [--allow-empty]',
|
|
107
|
+
booleanFlags: new Set(['json', 'strict', 'fail-on-dead-units', ALLOW_EMPTY_FLAG]),
|
|
87
108
|
async run(args) {
|
|
88
109
|
const cwd = resolveCwd(args);
|
|
89
110
|
const inspection = await inspectSharkcraft({ cwd });
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
111
|
+
// THE scaffold-pattern doctor (round 13) — MCP get_scaffold_pattern_doctor
|
|
112
|
+
// reads the same report. No pattern declared examined nothing: NOT VERIFIED
|
|
113
|
+
// (2), like every other asset doctor over an empty input, unless
|
|
114
|
+
// `--allow-empty` accepts it (printed).
|
|
115
|
+
const report = await buildScaffoldPatternDoctorReport(inspection, allowEmptyValve(args, 0));
|
|
116
|
+
const proposed = assetDoctorProposedExit({ errors: report.errors, warnings: report.warnings, units: report.measured.liveness.flatMap((s) => s.units) }, { strict: flagBool(args, 'strict'), failOnDeadUnits: flagBool(args, 'fail-on-dead-units') });
|
|
117
|
+
const settled = settleVerdict(proposed, report.coverage);
|
|
118
|
+
const deadUnits = report.measured.deadUnits;
|
|
119
|
+
// THE units that fail this run (round 13 review) — printed and in --json,
|
|
120
|
+
// so a 1 from --fail-on-dead-units is never silent about why.
|
|
121
|
+
const failing = assetDoctorFailingUnits(report.measured.liveness.flatMap((s) => s.units), {
|
|
122
|
+
failOnDeadUnits: flagBool(args, 'fail-on-dead-units'),
|
|
123
|
+
strict: flagBool(args, 'strict'),
|
|
124
|
+
});
|
|
125
|
+
const rejected = report.rejected.map((r) => ({ ...r, file: contributionFileLabel(inspection.projectRoot, r.file) }));
|
|
94
126
|
if (flagBool(args, 'json')) {
|
|
95
127
|
process.stdout.write(asJson({
|
|
96
|
-
patterns:
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
128
|
+
patterns: report.patterns.length,
|
|
129
|
+
failingUnits: failing.map((u) => ({ list: u.list, unit: u.unit, state: u.state, message: u.message })),
|
|
130
|
+
errors: report.errors,
|
|
131
|
+
warnings: report.warnings,
|
|
132
|
+
dead: deadUnits.length,
|
|
133
|
+
issues: report.issues,
|
|
134
|
+
loadWarnings: report.loadWarnings,
|
|
135
|
+
rejected,
|
|
136
|
+
patternCoverage: report.patternCoverage,
|
|
137
|
+
coverage: report.coverage,
|
|
138
|
+
deadUnits,
|
|
139
|
+
units: settledUnitStates(report.measured.liveness),
|
|
140
|
+
exitCode: settled.exit,
|
|
141
|
+
verdict: settled.verdict,
|
|
142
|
+
shortfalls: settled.shortfalls,
|
|
143
|
+
accepted: settled.accepted,
|
|
101
144
|
}) + '\n');
|
|
102
|
-
return
|
|
145
|
+
return settled.exit;
|
|
103
146
|
}
|
|
104
147
|
process.stdout.write(header('Scaffold pattern doctor'));
|
|
105
|
-
process.stdout.write(kv('patterns',
|
|
106
|
-
process.stdout.write(kv('errors',
|
|
107
|
-
process.stdout.write(kv('warnings',
|
|
108
|
-
|
|
148
|
+
process.stdout.write(kv('patterns', report.patterns.length.toString()) + '\n');
|
|
149
|
+
process.stdout.write(kv('errors', report.errors.toString()) + '\n');
|
|
150
|
+
process.stdout.write(kv('warnings', report.warnings.toString()) + '\n');
|
|
151
|
+
process.stdout.write(kv('dead', deadUnits.length.toString()) + '\n');
|
|
152
|
+
for (const c of report.coverage)
|
|
153
|
+
process.stdout.write(kv('coverage', formatCoverage(c)) + '\n');
|
|
154
|
+
if (report.issues.length > 0) {
|
|
109
155
|
process.stdout.write('\nIssues:\n');
|
|
110
|
-
for (const i of issues) {
|
|
156
|
+
for (const i of report.issues) {
|
|
111
157
|
const tag = i.severity === 'error' ? 'ERR ' : i.severity === 'warning' ? 'WARN' : 'INFO';
|
|
112
158
|
process.stdout.write(` ${tag} ${i.patternId.padEnd(28)} ${i.field.padEnd(20)} ${i.message}\n`);
|
|
113
159
|
}
|
|
114
160
|
}
|
|
115
|
-
if (
|
|
161
|
+
if (report.rejected.length > 0) {
|
|
162
|
+
process.stdout.write('\nRejected entries (refused by the loader — NOT in effect):\n');
|
|
163
|
+
for (const r of report.rejected) {
|
|
164
|
+
process.stdout.write(` ERR ${contributionFileLabel(inspection.projectRoot, r.file)} ${formatEntryRejection(r)}\n`);
|
|
165
|
+
}
|
|
166
|
+
}
|
|
167
|
+
if (report.loadWarnings.length > 0) {
|
|
116
168
|
process.stdout.write('\nLoad warnings:\n');
|
|
117
|
-
for (const w of
|
|
169
|
+
for (const w of report.loadWarnings)
|
|
118
170
|
process.stdout.write(` ! ${w}\n`);
|
|
119
171
|
}
|
|
120
|
-
|
|
172
|
+
// A stale LOCAL expectEmpty marker withholds the ✓ (a pack's is INFO).
|
|
173
|
+
const globs = report.measured.liveness[0];
|
|
174
|
+
const staleLocal = (globs?.wentLive ?? []).filter((u) => u.mark?.packageName === undefined).length;
|
|
175
|
+
const intendedEmpty = globs?.intendedEmpty.length ?? 0;
|
|
176
|
+
const clean = report.patterns.length === 0
|
|
177
|
+
? 'No scaffold patterns declared — nothing to verify.'
|
|
178
|
+
: report.warnings > 0
|
|
179
|
+
? `No blocking scaffold-pattern issues — ${report.warnings} warning(s) reported above.`
|
|
180
|
+
: staleLocal > 0
|
|
181
|
+
? `No blocking scaffold-pattern issues — ${staleLocal} expectEmpty marker(s) went live (listed above; remove the markers).`
|
|
182
|
+
: `${report.patterns.length} pattern(s) valid; every matchPaths glob matches a file${intendedEmpty > 0 ? ' or is intended empty' : ''}. ✓`;
|
|
183
|
+
const line = verdictLine(settled, clean);
|
|
184
|
+
if (line)
|
|
185
|
+
process.stdout.write('\n' + line + '\n');
|
|
186
|
+
// Round 13 review: a 1 from --fail-on-dead-units names its units.
|
|
187
|
+
if (settled.exit === 1) {
|
|
188
|
+
const failure = assetDoctorFailureLine('scaffold-pattern doctor', failing);
|
|
189
|
+
if (failure)
|
|
190
|
+
process.stdout.write('\n' + failure + '\n');
|
|
191
|
+
}
|
|
192
|
+
return settled.exit;
|
|
121
193
|
},
|
|
122
194
|
};
|
|
@@ -1,12 +1,4 @@
|
|
|
1
1
|
import { type ICommandHandler } from '../command-registry.js';
|
|
2
2
|
export declare const searchCommand: ICommandHandler;
|
|
3
3
|
export declare const searchTuningListCommand: ICommandHandler;
|
|
4
|
-
/**
|
|
5
|
-
* Top-level `shrk search-tuning <verb>` alias.
|
|
6
|
-
*
|
|
7
|
-
* Lets users invoke `shrk search-tuning explain "<query>"` without
|
|
8
|
-
* remembering the nested `shrk search tuning explain ...` form. Routes
|
|
9
|
-
* directly through the existing handler to avoid drift.
|
|
10
|
-
*/
|
|
11
|
-
export declare const searchTuningTopLevelCommand: ICommandHandler;
|
|
12
4
|
//# sourceMappingURL=search.command.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"search.command.d.ts","sourceRoot":"","sources":["../../src/commands/search.command.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"search.command.d.ts","sourceRoot":"","sources":["../../src/commands/search.command.ts"],"names":[],"mappings":"AAuBA,OAAO,EAML,KAAK,eAAe,EAErB,MAAM,wBAAwB,CAAC;AA0ChC,eAAO,MAAM,aAAa,EAAE,eAqJ3B,CAAC;AAEF,eAAO,MAAM,uBAAuB,EAAE,eA6LrC,CAAC"}
|
|
@@ -1,6 +1,15 @@
|
|
|
1
|
-
import { buildSearchIndex, entrypointBanner, explainSearchTuning, inspectSharkcraft, loadConstructs, loadPlaybooks, loadSearchTuning, renderSearchText, renderTuningExplainHtml, renderTuningExplainMarkdown, searchIndex, SearchKind, SearchResultKind, SearchSource, } from '@shrkcrft/inspector';
|
|
1
|
+
import { assetDoctorProposedExit, buildSearchIndex, ContributionKind, entrypointBanner, explainSearchTuning, inspectSharkcraft, lintSearchTuning, listSearchTuningIssues, loadConstructs, loadPlaybooks, loadSearchTuning, renderSearchText, renderTuningExplainHtml, renderTuningExplainMarkdown, searchIndex, SearchKind, SearchResultKind, SearchSource, settledUnitStates, } from '@shrkcrft/inspector';
|
|
2
|
+
import { usageExitFor } from "../exit-codes.js";
|
|
2
3
|
import { flagBool, flagNumber, flagString, flagList, resolveCwd, } from "../command-registry.js";
|
|
4
|
+
import { PositionalMode } from "../dispatch/positional-mode.js";
|
|
3
5
|
import { asJson } from "../output/format-output.js";
|
|
6
|
+
import { writeRejectedEntriesNote } from "../output/rejected-entries-note.js";
|
|
7
|
+
import { formatCoverage } from '@shrkcrft/core';
|
|
8
|
+
import { ALLOW_EMPTY_FLAG, allowEmptyValve } from "../gates/allow-empty.js";
|
|
9
|
+
import { assetDoctorFailingUnits } from "../gates/asset-doctor-failing-units.js";
|
|
10
|
+
import { assetDoctorFailureLine } from "../gates/asset-doctor-failure-line.js";
|
|
11
|
+
import { settleVerdict } from "../gates/settle-verdict.js";
|
|
12
|
+
import { verdictLine } from "../gates/verdict-line.js";
|
|
4
13
|
const VALID_KINDS = new Set(Object.values(SearchKind));
|
|
5
14
|
const VALID_SOURCES = new Set(Object.values(SearchSource));
|
|
6
15
|
// Universal-search (v2) filter vocabularies. `--kind` is one of the
|
|
@@ -34,6 +43,36 @@ function parseSources(args) {
|
|
|
34
43
|
}
|
|
35
44
|
export const searchCommand = {
|
|
36
45
|
name: 'search',
|
|
46
|
+
// The positionals are the free-form query; `tuning` is dispatched here.
|
|
47
|
+
positionals: PositionalMode.Free,
|
|
48
|
+
// The group parses every subverb's argv, so the doctor's boolean flags live
|
|
49
|
+
// here too: none may swallow a following token. `search --fail-on-dead-units
|
|
50
|
+
// tuning doctor` used to bind `tuning` as the flag's value and run a
|
|
51
|
+
// universal search for "doctor" at exit 0 (round 13).
|
|
52
|
+
booleanFlags: new Set([ALLOW_EMPTY_FLAG, 'fail-on-dead-units', 'strict', 'json']),
|
|
53
|
+
subverbs: [
|
|
54
|
+
{
|
|
55
|
+
name: 'tuning',
|
|
56
|
+
description: 'List, doctor, or explain the search-tuning entries (local + pack).',
|
|
57
|
+
usage: 'shrk search tuning list|doctor|explain <query> [--format markdown|html|json]',
|
|
58
|
+
// An unknown token used to fall through to the listing at exit 0.
|
|
59
|
+
positionals: PositionalMode.None,
|
|
60
|
+
subverbs: [
|
|
61
|
+
{ name: 'list', description: 'List the search-tuning entries (the default).', usage: 'shrk search tuning list [--format text|json]' },
|
|
62
|
+
{
|
|
63
|
+
name: 'doctor',
|
|
64
|
+
description: 'THE search-tuning lint plus the loader issues. A boost key whose target is missing is a dead unit (exit 2) unless its value is marked { weight, expectEmpty: true } (accepted, printed; reported once the target is registered).',
|
|
65
|
+
usage: 'shrk search tuning doctor [--strict] [--fail-on-dead-units] [--allow-empty] [--format text|json]',
|
|
66
|
+
},
|
|
67
|
+
{
|
|
68
|
+
name: 'explain',
|
|
69
|
+
description: 'Which tunings move the top results of a query, and by how much.',
|
|
70
|
+
usage: 'shrk search tuning explain <query> [--kind <kind>] [--source <source>] [--limit N] [--format markdown|html|json]',
|
|
71
|
+
positionals: PositionalMode.Free,
|
|
72
|
+
},
|
|
73
|
+
],
|
|
74
|
+
},
|
|
75
|
+
],
|
|
37
76
|
description: 'Universal search across commands, MCP tools, knowledge, rules, paths, conventions, templates, helpers, playbooks, constructs, policies, decisions, scaffold patterns, contract templates, migration profiles, feedback rules, task routing hints, docs, recent reports. Default emits the 7-section unified output; pass --legacy for the flat output.',
|
|
38
77
|
usage: 'shrk search <query> [--kind <kind>] [--source local|pack|...] [--limit N] [--explain] [--commands-only] [--actions-only] [--format text|markdown|json] [--legacy]',
|
|
39
78
|
async run(args) {
|
|
@@ -200,31 +239,115 @@ export const searchTuningListCommand = {
|
|
|
200
239
|
}
|
|
201
240
|
return 0;
|
|
202
241
|
}
|
|
203
|
-
const { entries, issues } = await loadSearchTuning(inspection);
|
|
204
242
|
if (sub === 'doctor') {
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
243
|
+
// `--format` takes what the doctor can print: text or JSON. `--format
|
|
244
|
+
// json` used to be ignored (text), and markdown / html were advertised
|
|
245
|
+
// but never rendered — a usage error now, never a silent fallback.
|
|
246
|
+
const format = flagString(args, 'format');
|
|
247
|
+
if (format !== undefined && format !== 'text' && format !== 'json') {
|
|
248
|
+
process.stderr.write(`'shrk search tuning doctor' --format takes text or json (got "${format}"). Run \`shrk help search\` for the flags it accepts.\n`);
|
|
249
|
+
return usageExitFor('search tuning doctor');
|
|
208
250
|
}
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
251
|
+
const wantJson = flagBool(args, 'json') || format === 'json';
|
|
252
|
+
// THE search-tuning lint (shared with the self-config doctor) plus the
|
|
253
|
+
// loader's own issues. It used to print "No issues." over a dead bare
|
|
254
|
+
// key, a misspelled prefix, a missing target, triggers no query can
|
|
255
|
+
// produce and a silent total-cap discard.
|
|
256
|
+
const lint = await lintSearchTuning(inspection);
|
|
257
|
+
const issues = [...listSearchTuningIssues(inspection), ...lint.issues];
|
|
258
|
+
const errors = issues.filter((i) => i.severity === 'error').length;
|
|
259
|
+
const warnings = issues.filter((i) => i.severity === 'warning').length;
|
|
260
|
+
// THE asset-doctor proposal (round 13): errors, warnings under --strict,
|
|
261
|
+
// and every settled unit THE --fail-on-dead-units predicate fails.
|
|
262
|
+
const proposed = assetDoctorProposedExit({ errors, warnings, units: lint.liveness.flatMap((s) => s.units) }, { strict: flagBool(args, 'strict'), failOnDeadUnits: flagBool(args, 'fail-on-dead-units') });
|
|
263
|
+
// Dead keys / triggers and unverifiable keys are coverage: never a pass.
|
|
264
|
+
// No tuning declared examined nothing: NOT VERIFIED (2), like every other
|
|
265
|
+
// asset doctor over an empty input, unless `--allow-empty` accepts it.
|
|
266
|
+
const coverage = lint.entries === 0
|
|
267
|
+
? [
|
|
268
|
+
...lint.coverage,
|
|
269
|
+
{
|
|
270
|
+
unit: 'search-tuning entries',
|
|
271
|
+
expected: 0,
|
|
272
|
+
examined: 0,
|
|
273
|
+
reason: 'no search tuning declared',
|
|
274
|
+
...allowEmptyValve(args, 0),
|
|
275
|
+
},
|
|
276
|
+
]
|
|
277
|
+
: lint.coverage;
|
|
278
|
+
const settled = settleVerdict(proposed, coverage);
|
|
279
|
+
// THE units that fail this run (round 13 review) — printed and in
|
|
280
|
+
// --json, so a 1 from --fail-on-dead-units is never silent about why.
|
|
281
|
+
const failing = assetDoctorFailingUnits(lint.liveness.flatMap((s) => s.units), {
|
|
282
|
+
failOnDeadUnits: flagBool(args, 'fail-on-dead-units'),
|
|
283
|
+
strict: flagBool(args, 'strict'),
|
|
284
|
+
});
|
|
285
|
+
if (wantJson) {
|
|
286
|
+
process.stdout.write(asJson({
|
|
287
|
+
entries: lint.entries,
|
|
288
|
+
failingUnits: failing.map((u) => ({ list: u.list, unit: u.unit, state: u.state, message: u.message })),
|
|
289
|
+
issues,
|
|
290
|
+
probes: lint.probes,
|
|
291
|
+
coverage,
|
|
292
|
+
deadUnits: lint.deadUnits,
|
|
293
|
+
units: settledUnitStates(lint.liveness),
|
|
294
|
+
exitCode: settled.exit,
|
|
295
|
+
verdict: settled.verdict,
|
|
296
|
+
shortfalls: settled.shortfalls,
|
|
297
|
+
accepted: settled.accepted,
|
|
298
|
+
}) + '\n');
|
|
299
|
+
return settled.exit;
|
|
213
300
|
}
|
|
301
|
+
const p = lint.probes;
|
|
302
|
+
process.stdout.write(`Tuning entries: ${lint.entries}\n`);
|
|
303
|
+
process.stdout.write(`Boost keys: probed ${p.probed} · resolved ${p.resolved} · missing ${p.missing} · unprefixed ${p.unprefixed} · unknown-kind ${p.unknownKind} · unverified ${p.unverified}\n`);
|
|
304
|
+
for (const c of coverage)
|
|
305
|
+
process.stdout.write(`Coverage: ${formatCoverage(c)}\n`);
|
|
214
306
|
for (const i of issues) {
|
|
215
|
-
process.stdout.write(` ${i.severity.toUpperCase().padEnd(8)} ${i.code.padEnd(
|
|
307
|
+
process.stdout.write(` ${i.severity.toUpperCase().padEnd(8)} ${i.code.padEnd(22)} ${i.message}${i.tuningId ? ` (${i.tuningId})` : ''}\n`);
|
|
308
|
+
}
|
|
309
|
+
// A stale LOCAL expectEmpty marker withholds the ✓ (a pack's is INFO).
|
|
310
|
+
const keys = lint.liveness[0];
|
|
311
|
+
const staleLocal = (keys?.wentLive ?? []).filter((u) => u.mark?.packageName === undefined).length;
|
|
312
|
+
const clean = lint.entries === 0
|
|
313
|
+
? 'No search tuning declared — nothing to verify.'
|
|
314
|
+
: warnings > 0
|
|
315
|
+
? `No blocking search-tuning issues — ${warnings} warning(s) reported above.`
|
|
316
|
+
: staleLocal > 0
|
|
317
|
+
? `No blocking search-tuning issues — ${staleLocal} expectEmpty marker(s) went live (listed above; remove the markers).`
|
|
318
|
+
: `Every boost key fires${(keys?.intendedEmpty.length ?? 0) > 0 ? ' or is intended empty' : ''} and every trigger is reachable. ✓`;
|
|
319
|
+
const line = verdictLine(settled, clean);
|
|
320
|
+
if (line)
|
|
321
|
+
process.stdout.write(line + '\n');
|
|
322
|
+
// Round 13 review: a 1 from --fail-on-dead-units names its units.
|
|
323
|
+
if (settled.exit === 1) {
|
|
324
|
+
const failure = assetDoctorFailureLine('search-tuning doctor', failing);
|
|
325
|
+
if (failure)
|
|
326
|
+
process.stdout.write(failure + '\n');
|
|
216
327
|
}
|
|
217
|
-
return
|
|
328
|
+
return settled.exit;
|
|
218
329
|
}
|
|
219
|
-
// Default: list.
|
|
220
|
-
|
|
330
|
+
// Default: list. It renders text or JSON: a `--format` it cannot render is a
|
|
331
|
+
// usage error, never a silent text fallback (round 13 review — its usage
|
|
332
|
+
// advertised markdown / html, which printed the text listing at exit 0).
|
|
333
|
+
const listFormat = flagString(args, 'format');
|
|
334
|
+
if (listFormat !== undefined && listFormat !== 'text' && listFormat !== 'json') {
|
|
335
|
+
process.stderr.write(`'shrk search tuning list' --format takes text or json (got "${listFormat}"). Run \`shrk help search\` for the flags it accepts.\n`);
|
|
336
|
+
return usageExitFor('search tuning list');
|
|
337
|
+
}
|
|
338
|
+
const { entries } = await loadSearchTuning(inspection);
|
|
339
|
+
// A tuning entry its loader refused (no id) is named (round 12, 12.1).
|
|
340
|
+
const note = { next: 'shrk search tuning doctor' };
|
|
341
|
+
if (flagBool(args, 'json') || listFormat === 'json') {
|
|
221
342
|
process.stdout.write(asJson(entries) + '\n');
|
|
343
|
+
await writeRejectedEntriesNote(inspection, [ContributionKind.SearchTuning], { ...note, json: true });
|
|
222
344
|
return 0;
|
|
223
345
|
}
|
|
224
346
|
process.stdout.write(`Search tuning (${entries.length} entries)\n`);
|
|
225
347
|
for (const e of entries) {
|
|
226
348
|
process.stdout.write(` ${e.id.padEnd(36)} ${e.source}${e.packageName ? ` (${e.packageName})` : ''}\n`);
|
|
227
349
|
}
|
|
350
|
+
await writeRejectedEntriesNote(inspection, [ContributionKind.SearchTuning], note);
|
|
228
351
|
return 0;
|
|
229
352
|
},
|
|
230
353
|
};
|
|
@@ -276,18 +399,3 @@ function renderUniversalSearchSummary(report, topN) {
|
|
|
276
399
|
lines.push('(text mode is summary-only — pass --verbose / --full for the 7-section bundle, --json for machine output.)');
|
|
277
400
|
return lines.join('\n') + '\n';
|
|
278
401
|
}
|
|
279
|
-
/**
|
|
280
|
-
* Top-level `shrk search-tuning <verb>` alias.
|
|
281
|
-
*
|
|
282
|
-
* Lets users invoke `shrk search-tuning explain "<query>"` without
|
|
283
|
-
* remembering the nested `shrk search tuning explain ...` form. Routes
|
|
284
|
-
* directly through the existing handler to avoid drift.
|
|
285
|
-
*/
|
|
286
|
-
export const searchTuningTopLevelCommand = {
|
|
287
|
-
name: 'search-tuning',
|
|
288
|
-
description: 'Alias — `shrk search-tuning <list|doctor|explain>` (delegates to `shrk search tuning ...`).',
|
|
289
|
-
usage: 'shrk search-tuning <list|doctor|explain> [<query>] [--kind <kind>] [--source <source>] [--limit N] [--format text|markdown|html|json]',
|
|
290
|
-
async run(args) {
|
|
291
|
-
return searchTuningListCommand.run(args);
|
|
292
|
-
},
|
|
293
|
-
};
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* `shrk self-config resolve <id>` and `shrk self-config xrefs` — the lookup and
|
|
3
|
+
* listing verbs over THE declared cross-reference collector.
|
|
4
|
+
*
|
|
5
|
+
* Ids carry no namespace prefix, so "is this `related` id live, and what is
|
|
6
|
+
* it?" used to mean grepping several asset sources in turn. `resolve` answers
|
|
7
|
+
* it for one id: every registry that has it (most specific first, with the verb
|
|
8
|
+
* that shows it) and every declared field pointing at it. `xrefs` prints the
|
|
9
|
+
* extracted set — the contract `gates explain` honours for gate rules. Both are
|
|
10
|
+
* thin renderers: the answers come from `buildDeclaredXrefReport` and the
|
|
11
|
+
* reference registry, never from a walk of their own.
|
|
12
|
+
*/
|
|
13
|
+
import { type ReferenceKind } from '@shrkcrft/inspector';
|
|
14
|
+
import { type ICommandHandler } from '../command-registry.js';
|
|
15
|
+
/**
|
|
16
|
+
* The verb that shows an id of each kind. Every entry must resolve through the
|
|
17
|
+
* live command index (`r75-xrefs-cli.test.ts` locks it), so a renamed verb
|
|
18
|
+
* fails the day it is renamed instead of being printed as a dead command. A
|
|
19
|
+
* kind with no show / list verb is absent — never guessed.
|
|
20
|
+
*/
|
|
21
|
+
export declare const REFERENCE_KIND_VERBS: Readonly<Partial<Record<ReferenceKind, string>>>;
|
|
22
|
+
export declare const selfConfigResolveCommand: ICommandHandler;
|
|
23
|
+
export declare const selfConfigXrefsCommand: ICommandHandler;
|
|
24
|
+
//# sourceMappingURL=self-config-xrefs.command.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"self-config-xrefs.command.d.ts","sourceRoot":"","sources":["../../src/commands/self-config-xrefs.command.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AACH,OAAO,EAaL,KAAK,aAAa,EACnB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EAIL,KAAK,eAAe,EAErB,MAAM,wBAAwB,CAAC;AAIhC;;;;;GAKG;AACH,eAAO,MAAM,oBAAoB,EAAE,QAAQ,CAAC,OAAO,CAAC,MAAM,CAAC,aAAa,EAAE,MAAM,CAAC,CAAC,CAe/B,CAAC;AAuBpD,eAAO,MAAM,wBAAwB,EAAE,eA4DtC,CAAC;AAKF,eAAO,MAAM,sBAAsB,EAAE,eA4DpC,CAAC"}
|