@untangle-code/cli 0.0.0-stage → 0.1.1
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/LICENSE +661 -0
- package/NOTICE +90 -0
- package/README.md +451 -2
- package/THIRD_PARTY_LICENSES.md +152 -0
- package/dist/cli/args.d.ts +48 -0
- package/dist/cli/args.d.ts.map +1 -0
- package/dist/cli/args.js +167 -0
- package/dist/cli/args.js.map +1 -0
- package/dist/cli/command.d.ts +69 -0
- package/dist/cli/command.d.ts.map +1 -0
- package/dist/cli/command.js +82 -0
- package/dist/cli/command.js.map +1 -0
- package/dist/cli/deadline.d.ts +33 -0
- package/dist/cli/deadline.d.ts.map +1 -0
- package/dist/cli/deadline.js +49 -0
- package/dist/cli/deadline.js.map +1 -0
- package/dist/cli/embedder-deadline.d.ts +72 -0
- package/dist/cli/embedder-deadline.d.ts.map +1 -0
- package/dist/cli/embedder-deadline.js +117 -0
- package/dist/cli/embedder-deadline.js.map +1 -0
- package/dist/cli/exit.d.ts +71 -0
- package/dist/cli/exit.d.ts.map +1 -0
- package/dist/cli/exit.js +81 -0
- package/dist/cli/exit.js.map +1 -0
- package/dist/cli/graphs.d.ts +65 -0
- package/dist/cli/graphs.d.ts.map +1 -0
- package/dist/cli/graphs.js +108 -0
- package/dist/cli/graphs.js.map +1 -0
- package/dist/cli/index-freshness.d.ts +13 -0
- package/dist/cli/index-freshness.d.ts.map +1 -0
- package/dist/cli/index-freshness.js +226 -0
- package/dist/cli/index-freshness.js.map +1 -0
- package/dist/cli/index-refresh.d.ts +10 -0
- package/dist/cli/index-refresh.d.ts.map +1 -0
- package/dist/cli/index-refresh.js +76 -0
- package/dist/cli/index-refresh.js.map +1 -0
- package/dist/cli/index-state.d.ts +184 -0
- package/dist/cli/index-state.d.ts.map +1 -0
- package/dist/cli/index-state.js +852 -0
- package/dist/cli/index-state.js.map +1 -0
- package/dist/cli/io.d.ts +29 -0
- package/dist/cli/io.d.ts.map +1 -0
- package/dist/cli/io.js +42 -0
- package/dist/cli/io.js.map +1 -0
- package/dist/cli/language-support.d.ts +77 -0
- package/dist/cli/language-support.d.ts.map +1 -0
- package/dist/cli/language-support.js +152 -0
- package/dist/cli/language-support.js.map +1 -0
- package/dist/cli/renewing-lease.d.ts +26 -0
- package/dist/cli/renewing-lease.d.ts.map +1 -0
- package/dist/cli/renewing-lease.js +102 -0
- package/dist/cli/renewing-lease.js.map +1 -0
- package/dist/cli/search-graph-enrichment.d.ts +16 -0
- package/dist/cli/search-graph-enrichment.d.ts.map +1 -0
- package/dist/cli/search-graph-enrichment.js +428 -0
- package/dist/cli/search-graph-enrichment.js.map +1 -0
- package/dist/cli/system.d.ts +34 -0
- package/dist/cli/system.d.ts.map +1 -0
- package/dist/cli/system.js +89 -0
- package/dist/cli/system.js.map +1 -0
- package/dist/cli/vector-store-policy.d.ts +116 -0
- package/dist/cli/vector-store-policy.d.ts.map +1 -0
- package/dist/cli/vector-store-policy.js +160 -0
- package/dist/cli/vector-store-policy.js.map +1 -0
- package/dist/cli/version.d.ts +3 -0
- package/dist/cli/version.d.ts.map +1 -0
- package/dist/cli/version.js +3 -0
- package/dist/cli/version.js.map +1 -0
- package/dist/cli/workspace.d.ts +105 -0
- package/dist/cli/workspace.d.ts.map +1 -0
- package/dist/cli/workspace.js +215 -0
- package/dist/cli/workspace.js.map +1 -0
- package/dist/commands/complexity.d.ts +72 -0
- package/dist/commands/complexity.d.ts.map +1 -0
- package/dist/commands/complexity.js +580 -0
- package/dist/commands/complexity.js.map +1 -0
- package/dist/commands/doctor.d.ts +66 -0
- package/dist/commands/doctor.d.ts.map +1 -0
- package/dist/commands/doctor.js +764 -0
- package/dist/commands/doctor.js.map +1 -0
- package/dist/commands/doctor.languages.d.ts +37 -0
- package/dist/commands/doctor.languages.d.ts.map +1 -0
- package/dist/commands/doctor.languages.js +143 -0
- package/dist/commands/doctor.languages.js.map +1 -0
- package/dist/commands/doctor.storage.d.ts +17 -0
- package/dist/commands/doctor.storage.d.ts.map +1 -0
- package/dist/commands/doctor.storage.js +91 -0
- package/dist/commands/doctor.storage.js.map +1 -0
- package/dist/commands/extensions/add.d.ts +10 -0
- package/dist/commands/extensions/add.d.ts.map +1 -0
- package/dist/commands/extensions/add.js +213 -0
- package/dist/commands/extensions/add.js.map +1 -0
- package/dist/commands/extensions/configure.d.ts +5 -0
- package/dist/commands/extensions/configure.d.ts.map +1 -0
- package/dist/commands/extensions/configure.js +58 -0
- package/dist/commands/extensions/configure.js.map +1 -0
- package/dist/commands/extensions/container.d.ts +15 -0
- package/dist/commands/extensions/container.d.ts.map +1 -0
- package/dist/commands/extensions/container.js +135 -0
- package/dist/commands/extensions/container.js.map +1 -0
- package/dist/commands/extensions/context.d.ts +37 -0
- package/dist/commands/extensions/context.d.ts.map +1 -0
- package/dist/commands/extensions/context.js +72 -0
- package/dist/commands/extensions/context.js.map +1 -0
- package/dist/commands/extensions/enable.d.ts +6 -0
- package/dist/commands/extensions/enable.d.ts.map +1 -0
- package/dist/commands/extensions/enable.js +180 -0
- package/dist/commands/extensions/enable.js.map +1 -0
- package/dist/commands/extensions/environment.d.ts +74 -0
- package/dist/commands/extensions/environment.d.ts.map +1 -0
- package/dist/commands/extensions/environment.js +168 -0
- package/dist/commands/extensions/environment.js.map +1 -0
- package/dist/commands/extensions/feature-scan.d.ts +48 -0
- package/dist/commands/extensions/feature-scan.d.ts.map +1 -0
- package/dist/commands/extensions/feature-scan.js +156 -0
- package/dist/commands/extensions/feature-scan.js.map +1 -0
- package/dist/commands/extensions/invoke.d.ts +60 -0
- package/dist/commands/extensions/invoke.d.ts.map +1 -0
- package/dist/commands/extensions/invoke.js +275 -0
- package/dist/commands/extensions/invoke.js.map +1 -0
- package/dist/commands/extensions/list.d.ts +5 -0
- package/dist/commands/extensions/list.d.ts.map +1 -0
- package/dist/commands/extensions/list.js +125 -0
- package/dist/commands/extensions/list.js.map +1 -0
- package/dist/commands/extensions/logs.d.ts +5 -0
- package/dist/commands/extensions/logs.d.ts.map +1 -0
- package/dist/commands/extensions/logs.js +74 -0
- package/dist/commands/extensions/logs.js.map +1 -0
- package/dist/commands/extensions/provision.d.ts +36 -0
- package/dist/commands/extensions/provision.d.ts.map +1 -0
- package/dist/commands/extensions/provision.js +137 -0
- package/dist/commands/extensions/provision.js.map +1 -0
- package/dist/commands/extensions/remove.d.ts +5 -0
- package/dist/commands/extensions/remove.d.ts.map +1 -0
- package/dist/commands/extensions/remove.js +77 -0
- package/dist/commands/extensions/remove.js.map +1 -0
- package/dist/commands/extensions/render.d.ts +16 -0
- package/dist/commands/extensions/render.d.ts.map +1 -0
- package/dist/commands/extensions/render.js +25 -0
- package/dist/commands/extensions/render.js.map +1 -0
- package/dist/commands/extensions/run.d.ts +30 -0
- package/dist/commands/extensions/run.d.ts.map +1 -0
- package/dist/commands/extensions/run.js +292 -0
- package/dist/commands/extensions/run.js.map +1 -0
- package/dist/commands/extensions/secret-store.d.ts +15 -0
- package/dist/commands/extensions/secret-store.d.ts.map +1 -0
- package/dist/commands/extensions/secret-store.js +164 -0
- package/dist/commands/extensions/secret-store.js.map +1 -0
- package/dist/commands/extensions/setup.d.ts +17 -0
- package/dist/commands/extensions/setup.d.ts.map +1 -0
- package/dist/commands/extensions/setup.js +94 -0
- package/dist/commands/extensions/setup.js.map +1 -0
- package/dist/commands/extensions/source.d.ts +47 -0
- package/dist/commands/extensions/source.d.ts.map +1 -0
- package/dist/commands/extensions/source.js +142 -0
- package/dist/commands/extensions/source.js.map +1 -0
- package/dist/commands/extensions/state.d.ts +62 -0
- package/dist/commands/extensions/state.d.ts.map +1 -0
- package/dist/commands/extensions/state.js +177 -0
- package/dist/commands/extensions/state.js.map +1 -0
- package/dist/commands/extensions/status.d.ts +9 -0
- package/dist/commands/extensions/status.d.ts.map +1 -0
- package/dist/commands/extensions/status.js +239 -0
- package/dist/commands/extensions/status.js.map +1 -0
- package/dist/commands/extensions.d.ts +3 -0
- package/dist/commands/extensions.d.ts.map +1 -0
- package/dist/commands/extensions.js +223 -0
- package/dist/commands/extensions.js.map +1 -0
- package/dist/commands/flow/index.d.ts +3 -0
- package/dist/commands/flow/index.d.ts.map +1 -0
- package/dist/commands/flow/index.js +295 -0
- package/dist/commands/flow/index.js.map +1 -0
- package/dist/commands/flow/limits.d.ts +12 -0
- package/dist/commands/flow/limits.d.ts.map +1 -0
- package/dist/commands/flow/limits.js +13 -0
- package/dist/commands/flow/limits.js.map +1 -0
- package/dist/commands/flow/output.d.ts +8 -0
- package/dist/commands/flow/output.d.ts.map +1 -0
- package/dist/commands/flow/output.js +11 -0
- package/dist/commands/flow/output.js.map +1 -0
- package/dist/commands/flow/render.d.ts +51 -0
- package/dist/commands/flow/render.d.ts.map +1 -0
- package/dist/commands/flow/render.js +220 -0
- package/dist/commands/flow/render.js.map +1 -0
- package/dist/commands/flow/select.d.ts +31 -0
- package/dist/commands/flow/select.d.ts.map +1 -0
- package/dist/commands/flow/select.js +62 -0
- package/dist/commands/flow/select.js.map +1 -0
- package/dist/commands/graph/boundaries-input.d.ts +26 -0
- package/dist/commands/graph/boundaries-input.d.ts.map +1 -0
- package/dist/commands/graph/boundaries-input.js +54 -0
- package/dist/commands/graph/boundaries-input.js.map +1 -0
- package/dist/commands/graph/boundaries.d.ts +4 -0
- package/dist/commands/graph/boundaries.d.ts.map +1 -0
- package/dist/commands/graph/boundaries.js +141 -0
- package/dist/commands/graph/boundaries.js.map +1 -0
- package/dist/commands/graph/bounds.d.ts +16 -0
- package/dist/commands/graph/bounds.d.ts.map +1 -0
- package/dist/commands/graph/bounds.js +22 -0
- package/dist/commands/graph/bounds.js.map +1 -0
- package/dist/commands/graph/category-clusters.d.ts +20 -0
- package/dist/commands/graph/category-clusters.d.ts.map +1 -0
- package/dist/commands/graph/category-clusters.js +158 -0
- package/dist/commands/graph/category-clusters.js.map +1 -0
- package/dist/commands/graph/feature-3d.d.ts +22 -0
- package/dist/commands/graph/feature-3d.d.ts.map +1 -0
- package/dist/commands/graph/feature-3d.js +114 -0
- package/dist/commands/graph/feature-3d.js.map +1 -0
- package/dist/commands/graph/feature-clusters.d.ts +17 -0
- package/dist/commands/graph/feature-clusters.d.ts.map +1 -0
- package/dist/commands/graph/feature-clusters.js +94 -0
- package/dist/commands/graph/feature-clusters.js.map +1 -0
- package/dist/commands/graph/feature-html.d.ts +26 -0
- package/dist/commands/graph/feature-html.d.ts.map +1 -0
- package/dist/commands/graph/feature-html.js +314 -0
- package/dist/commands/graph/feature-html.js.map +1 -0
- package/dist/commands/graph/feature-map.d.ts +31 -0
- package/dist/commands/graph/feature-map.d.ts.map +1 -0
- package/dist/commands/graph/feature-map.js +217 -0
- package/dist/commands/graph/feature-map.js.map +1 -0
- package/dist/commands/graph/feature-model.d.ts +55 -0
- package/dist/commands/graph/feature-model.d.ts.map +1 -0
- package/dist/commands/graph/feature-model.js +167 -0
- package/dist/commands/graph/feature-model.js.map +1 -0
- package/dist/commands/graph/feature-untangle-motion.d.ts +33 -0
- package/dist/commands/graph/feature-untangle-motion.d.ts.map +1 -0
- package/dist/commands/graph/feature-untangle-motion.js +155 -0
- package/dist/commands/graph/feature-untangle-motion.js.map +1 -0
- package/dist/commands/graph/index.d.ts +3 -0
- package/dist/commands/graph/index.d.ts.map +1 -0
- package/dist/commands/graph/index.js +414 -0
- package/dist/commands/graph/index.js.map +1 -0
- package/dist/commands/graph/render.d.ts +63 -0
- package/dist/commands/graph/render.d.ts.map +1 -0
- package/dist/commands/graph/render.js +352 -0
- package/dist/commands/graph/render.js.map +1 -0
- package/dist/commands/graph/select.d.ts +34 -0
- package/dist/commands/graph/select.d.ts.map +1 -0
- package/dist/commands/graph/select.js +55 -0
- package/dist/commands/graph/select.js.map +1 -0
- package/dist/commands/index/index.d.ts +6 -0
- package/dist/commands/index/index.d.ts.map +1 -0
- package/dist/commands/index/index.js +461 -0
- package/dist/commands/index/index.js.map +1 -0
- package/dist/commands/index/render.d.ts +53 -0
- package/dist/commands/index/render.d.ts.map +1 -0
- package/dist/commands/index/render.js +205 -0
- package/dist/commands/index/render.js.map +1 -0
- package/dist/commands/index/target.d.ts +34 -0
- package/dist/commands/index/target.d.ts.map +1 -0
- package/dist/commands/index/target.js +97 -0
- package/dist/commands/index/target.js.map +1 -0
- package/dist/commands/index-watch.d.ts +30 -0
- package/dist/commands/index-watch.d.ts.map +1 -0
- package/dist/commands/index-watch.js +138 -0
- package/dist/commands/index-watch.js.map +1 -0
- package/dist/commands/init/command.d.ts +25 -0
- package/dist/commands/init/command.d.ts.map +1 -0
- package/dist/commands/init/command.js +198 -0
- package/dist/commands/init/command.js.map +1 -0
- package/dist/commands/init/config-draft.d.ts +48 -0
- package/dist/commands/init/config-draft.d.ts.map +1 -0
- package/dist/commands/init/config-draft.js +201 -0
- package/dist/commands/init/config-draft.js.map +1 -0
- package/dist/commands/init/diff.d.ts +33 -0
- package/dist/commands/init/diff.d.ts.map +1 -0
- package/dist/commands/init/diff.js +109 -0
- package/dist/commands/init/diff.js.map +1 -0
- package/dist/commands/init/http-probe.d.ts +26 -0
- package/dist/commands/init/http-probe.d.ts.map +1 -0
- package/dist/commands/init/http-probe.js +144 -0
- package/dist/commands/init/http-probe.js.map +1 -0
- package/dist/commands/init/ignore-rules.d.ts +70 -0
- package/dist/commands/init/ignore-rules.d.ts.map +1 -0
- package/dist/commands/init/ignore-rules.js +146 -0
- package/dist/commands/init/ignore-rules.js.map +1 -0
- package/dist/commands/init/index.d.ts +33 -0
- package/dist/commands/init/index.d.ts.map +1 -0
- package/dist/commands/init/index.js +32 -0
- package/dist/commands/init/index.js.map +1 -0
- package/dist/commands/init/integrations-apply.d.ts +50 -0
- package/dist/commands/init/integrations-apply.d.ts.map +1 -0
- package/dist/commands/init/integrations-apply.js +452 -0
- package/dist/commands/init/integrations-apply.js.map +1 -0
- package/dist/commands/init/integrations-plan.d.ts +68 -0
- package/dist/commands/init/integrations-plan.d.ts.map +1 -0
- package/dist/commands/init/integrations-plan.js +515 -0
- package/dist/commands/init/integrations-plan.js.map +1 -0
- package/dist/commands/init/integrations.d.ts +5 -0
- package/dist/commands/init/integrations.d.ts.map +1 -0
- package/dist/commands/init/integrations.js +4 -0
- package/dist/commands/init/integrations.js.map +1 -0
- package/dist/commands/init/languages.d.ts +55 -0
- package/dist/commands/init/languages.d.ts.map +1 -0
- package/dist/commands/init/languages.js +245 -0
- package/dist/commands/init/languages.js.map +1 -0
- package/dist/commands/init/product-context.d.ts +63 -0
- package/dist/commands/init/product-context.d.ts.map +1 -0
- package/dist/commands/init/product-context.js +390 -0
- package/dist/commands/init/product-context.js.map +1 -0
- package/dist/commands/init/render.d.ts +38 -0
- package/dist/commands/init/render.d.ts.map +1 -0
- package/dist/commands/init/render.js +501 -0
- package/dist/commands/init/render.js.map +1 -0
- package/dist/commands/init/report.d.ts +24 -0
- package/dist/commands/init/report.d.ts.map +1 -0
- package/dist/commands/init/report.js +163 -0
- package/dist/commands/init/report.js.map +1 -0
- package/dist/commands/init/run.d.ts +71 -0
- package/dist/commands/init/run.d.ts.map +1 -0
- package/dist/commands/init/run.js +253 -0
- package/dist/commands/init/run.js.map +1 -0
- package/dist/commands/init/services.d.ts +82 -0
- package/dist/commands/init/services.d.ts.map +1 -0
- package/dist/commands/init/services.js +209 -0
- package/dist/commands/init/services.js.map +1 -0
- package/dist/commands/init/storage.d.ts +8 -0
- package/dist/commands/init/storage.d.ts.map +1 -0
- package/dist/commands/init/storage.js +102 -0
- package/dist/commands/init/storage.js.map +1 -0
- package/dist/commands/init/toml.d.ts +65 -0
- package/dist/commands/init/toml.d.ts.map +1 -0
- package/dist/commands/init/toml.js +159 -0
- package/dist/commands/init/toml.js.map +1 -0
- package/dist/commands/init/topology.d.ts +54 -0
- package/dist/commands/init/topology.d.ts.map +1 -0
- package/dist/commands/init/topology.js +146 -0
- package/dist/commands/init/topology.js.map +1 -0
- package/dist/commands/init/types.d.ts +334 -0
- package/dist/commands/init/types.d.ts.map +1 -0
- package/dist/commands/init/types.js +31 -0
- package/dist/commands/init/types.js.map +1 -0
- package/dist/commands/init/wizard-terminal.d.ts +36 -0
- package/dist/commands/init/wizard-terminal.d.ts.map +1 -0
- package/dist/commands/init/wizard-terminal.js +163 -0
- package/dist/commands/init/wizard-terminal.js.map +1 -0
- package/dist/commands/init/wizard.d.ts +25 -0
- package/dist/commands/init/wizard.d.ts.map +1 -0
- package/dist/commands/init/wizard.js +358 -0
- package/dist/commands/init/wizard.js.map +1 -0
- package/dist/commands/mcp.d.ts +4 -0
- package/dist/commands/mcp.d.ts.map +1 -0
- package/dist/commands/mcp.js +111 -0
- package/dist/commands/mcp.js.map +1 -0
- package/dist/commands/product-test-runner.d.ts +4 -0
- package/dist/commands/product-test-runner.d.ts.map +1 -0
- package/dist/commands/product-test-runner.js +85 -0
- package/dist/commands/product-test-runner.js.map +1 -0
- package/dist/commands/product.d.ts +16 -0
- package/dist/commands/product.d.ts.map +1 -0
- package/dist/commands/product.js +262 -0
- package/dist/commands/product.js.map +1 -0
- package/dist/commands/query.d.ts +114 -0
- package/dist/commands/query.d.ts.map +1 -0
- package/dist/commands/query.js +783 -0
- package/dist/commands/query.js.map +1 -0
- package/dist/commands/scan.d.ts +10 -0
- package/dist/commands/scan.d.ts.map +1 -0
- package/dist/commands/scan.js +302 -0
- package/dist/commands/scan.js.map +1 -0
- package/dist/commands/sdd.d.ts +24 -0
- package/dist/commands/sdd.d.ts.map +1 -0
- package/dist/commands/sdd.js +195 -0
- package/dist/commands/sdd.js.map +1 -0
- package/dist/commands/unavailable.d.ts +40 -0
- package/dist/commands/unavailable.d.ts.map +1 -0
- package/dist/commands/unavailable.js +73 -0
- package/dist/commands/unavailable.js.map +1 -0
- package/dist/commands/watch/analyze.d.ts +69 -0
- package/dist/commands/watch/analyze.d.ts.map +1 -0
- package/dist/commands/watch/analyze.js +402 -0
- package/dist/commands/watch/analyze.js.map +1 -0
- package/dist/commands/watch/cli.d.ts +8 -0
- package/dist/commands/watch/cli.d.ts.map +1 -0
- package/dist/commands/watch/cli.js +97 -0
- package/dist/commands/watch/cli.js.map +1 -0
- package/dist/commands/watch/delta.d.ts +46 -0
- package/dist/commands/watch/delta.d.ts.map +1 -0
- package/dist/commands/watch/delta.js +170 -0
- package/dist/commands/watch/delta.js.map +1 -0
- package/dist/commands/watch/events.d.ts +214 -0
- package/dist/commands/watch/events.d.ts.map +1 -0
- package/dist/commands/watch/events.js +13 -0
- package/dist/commands/watch/events.js.map +1 -0
- package/dist/commands/watch/index.d.ts +19 -0
- package/dist/commands/watch/index.d.ts.map +1 -0
- package/dist/commands/watch/index.js +15 -0
- package/dist/commands/watch/index.js.map +1 -0
- package/dist/commands/watch/options.d.ts +43 -0
- package/dist/commands/watch/options.d.ts.map +1 -0
- package/dist/commands/watch/options.js +193 -0
- package/dist/commands/watch/options.js.map +1 -0
- package/dist/commands/watch/render.d.ts +26 -0
- package/dist/commands/watch/render.d.ts.map +1 -0
- package/dist/commands/watch/render.js +175 -0
- package/dist/commands/watch/render.js.map +1 -0
- package/dist/commands/watch/run.d.ts +14 -0
- package/dist/commands/watch/run.d.ts.map +1 -0
- package/dist/commands/watch/run.js +460 -0
- package/dist/commands/watch/run.js.map +1 -0
- package/dist/commands/watch/runtime.d.ts +67 -0
- package/dist/commands/watch/runtime.d.ts.map +1 -0
- package/dist/commands/watch/runtime.js +149 -0
- package/dist/commands/watch/runtime.js.map +1 -0
- package/dist/commands/watch-command.d.ts +3 -0
- package/dist/commands/watch-command.d.ts.map +1 -0
- package/dist/commands/watch-command.js +273 -0
- package/dist/commands/watch-command.js.map +1 -0
- package/dist/entry-point.d.ts +11 -0
- package/dist/entry-point.d.ts.map +1 -0
- package/dist/entry-point.js +65 -0
- package/dist/entry-point.js.map +1 -0
- package/dist/index.d.ts +38 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +245 -0
- package/dist/index.js.map +1 -0
- package/dist/mcp/boundaries-schema.d.ts +262 -0
- package/dist/mcp/boundaries-schema.d.ts.map +1 -0
- package/dist/mcp/boundaries-schema.js +183 -0
- package/dist/mcp/boundaries-schema.js.map +1 -0
- package/dist/mcp/default-runtime.d.ts +16 -0
- package/dist/mcp/default-runtime.d.ts.map +1 -0
- package/dist/mcp/default-runtime.js +718 -0
- package/dist/mcp/default-runtime.js.map +1 -0
- package/dist/mcp/envelope.d.ts +13 -0
- package/dist/mcp/envelope.d.ts.map +1 -0
- package/dist/mcp/envelope.js +29 -0
- package/dist/mcp/envelope.js.map +1 -0
- package/dist/mcp/index.d.ts +8 -0
- package/dist/mcp/index.d.ts.map +1 -0
- package/dist/mcp/index.js +8 -0
- package/dist/mcp/index.js.map +1 -0
- package/dist/mcp/output-schemas.d.ts +5928 -0
- package/dist/mcp/output-schemas.d.ts.map +1 -0
- package/dist/mcp/output-schemas.js +2814 -0
- package/dist/mcp/output-schemas.js.map +1 -0
- package/dist/mcp/path-sandbox.d.ts +35 -0
- package/dist/mcp/path-sandbox.d.ts.map +1 -0
- package/dist/mcp/path-sandbox.js +128 -0
- package/dist/mcp/path-sandbox.js.map +1 -0
- package/dist/mcp/server.d.ts +155 -0
- package/dist/mcp/server.d.ts.map +1 -0
- package/dist/mcp/server.js +257 -0
- package/dist/mcp/server.js.map +1 -0
- package/dist/mcp/stdio.d.ts +20 -0
- package/dist/mcp/stdio.d.ts.map +1 -0
- package/dist/mcp/stdio.js +71 -0
- package/dist/mcp/stdio.js.map +1 -0
- package/dist/mcp/tools.d.ts +355 -0
- package/dist/mcp/tools.d.ts.map +1 -0
- package/dist/mcp/tools.js +319 -0
- package/dist/mcp/tools.js.map +1 -0
- package/dist/mcp/types.d.ts +15 -0
- package/dist/mcp/types.d.ts.map +1 -0
- package/dist/mcp/types.js +45 -0
- package/dist/mcp/types.js.map +1 -0
- package/package.json +99 -3
- package/src/cli/args.ts +231 -0
- package/src/cli/command.ts +146 -0
- package/src/cli/deadline.ts +56 -0
- package/src/cli/embedder-deadline.ts +187 -0
- package/src/cli/exit.ts +94 -0
- package/src/cli/graphs.ts +191 -0
- package/src/cli/index-freshness.ts +303 -0
- package/src/cli/index-refresh.ts +125 -0
- package/src/cli/index-state.ts +1217 -0
- package/src/cli/io.ts +56 -0
- package/src/cli/language-support.ts +203 -0
- package/src/cli/renewing-lease.ts +121 -0
- package/src/cli/search-graph-enrichment.ts +639 -0
- package/src/cli/system.ts +94 -0
- package/src/cli/vector-store-policy.ts +213 -0
- package/src/cli/version.ts +2 -0
- package/src/cli/workspace.ts +324 -0
- package/src/commands/complexity.ts +776 -0
- package/src/commands/doctor.languages.ts +187 -0
- package/src/commands/doctor.storage.ts +124 -0
- package/src/commands/doctor.ts +946 -0
- package/src/commands/extensions/add.ts +312 -0
- package/src/commands/extensions/configure.ts +82 -0
- package/src/commands/extensions/container.ts +209 -0
- package/src/commands/extensions/context.ts +109 -0
- package/src/commands/extensions/enable.ts +237 -0
- package/src/commands/extensions/environment.ts +218 -0
- package/src/commands/extensions/feature-scan.ts +232 -0
- package/src/commands/extensions/invoke.ts +368 -0
- package/src/commands/extensions/list.ts +158 -0
- package/src/commands/extensions/logs.ts +104 -0
- package/src/commands/extensions/provision.ts +206 -0
- package/src/commands/extensions/remove.ts +110 -0
- package/src/commands/extensions/render.ts +32 -0
- package/src/commands/extensions/run.ts +386 -0
- package/src/commands/extensions/secret-store.ts +223 -0
- package/src/commands/extensions/setup.ts +140 -0
- package/src/commands/extensions/source.ts +189 -0
- package/src/commands/extensions/state.ts +252 -0
- package/src/commands/extensions/status.ts +320 -0
- package/src/commands/extensions.ts +280 -0
- package/src/commands/flow/index.ts +402 -0
- package/src/commands/flow/limits.ts +14 -0
- package/src/commands/flow/output.ts +16 -0
- package/src/commands/flow/render.ts +318 -0
- package/src/commands/flow/select.ts +101 -0
- package/src/commands/graph/boundaries-input.ts +63 -0
- package/src/commands/graph/boundaries.ts +182 -0
- package/src/commands/graph/bounds.ts +25 -0
- package/src/commands/graph/category-clusters.ts +194 -0
- package/src/commands/graph/feature-3d.ts +141 -0
- package/src/commands/graph/feature-clusters.ts +125 -0
- package/src/commands/graph/feature-html.ts +336 -0
- package/src/commands/graph/feature-map.ts +270 -0
- package/src/commands/graph/feature-model.ts +234 -0
- package/src/commands/graph/feature-untangle-motion.ts +192 -0
- package/src/commands/graph/index.ts +562 -0
- package/src/commands/graph/render.ts +503 -0
- package/src/commands/graph/select.ts +77 -0
- package/src/commands/index/index.ts +595 -0
- package/src/commands/index/render.ts +325 -0
- package/src/commands/index/target.ts +136 -0
- package/src/commands/index-watch.ts +206 -0
- package/src/commands/init/command.ts +238 -0
- package/src/commands/init/config-draft.ts +235 -0
- package/src/commands/init/diff.ts +117 -0
- package/src/commands/init/http-probe.ts +150 -0
- package/src/commands/init/ignore-rules.ts +170 -0
- package/src/commands/init/index.ts +63 -0
- package/src/commands/init/integrations-apply.ts +618 -0
- package/src/commands/init/integrations-plan.ts +634 -0
- package/src/commands/init/integrations.ts +8 -0
- package/src/commands/init/languages.ts +320 -0
- package/src/commands/init/product-context.ts +576 -0
- package/src/commands/init/render.ts +598 -0
- package/src/commands/init/report.ts +204 -0
- package/src/commands/init/run.ts +349 -0
- package/src/commands/init/services.ts +271 -0
- package/src/commands/init/storage.ts +136 -0
- package/src/commands/init/toml.ts +174 -0
- package/src/commands/init/topology.ts +192 -0
- package/src/commands/init/types.ts +366 -0
- package/src/commands/init/wizard-terminal.ts +206 -0
- package/src/commands/init/wizard.ts +450 -0
- package/src/commands/mcp.ts +123 -0
- package/src/commands/product-test-runner.ts +80 -0
- package/src/commands/product.ts +331 -0
- package/src/commands/query.ts +1032 -0
- package/src/commands/scan.ts +360 -0
- package/src/commands/sdd.ts +243 -0
- package/src/commands/unavailable.ts +92 -0
- package/src/commands/watch/README.md +160 -0
- package/src/commands/watch/analyze.ts +600 -0
- package/src/commands/watch/cli.ts +108 -0
- package/src/commands/watch/delta.ts +186 -0
- package/src/commands/watch/events.ts +235 -0
- package/src/commands/watch/index.ts +53 -0
- package/src/commands/watch/options.ts +234 -0
- package/src/commands/watch/render.ts +240 -0
- package/src/commands/watch/run.ts +553 -0
- package/src/commands/watch/runtime.ts +167 -0
- package/src/commands/watch-command.ts +294 -0
- package/src/entry-point.ts +67 -0
- package/src/index.ts +291 -0
- package/src/mcp/boundaries-schema.ts +193 -0
- package/src/mcp/default-runtime.ts +1034 -0
- package/src/mcp/envelope.ts +57 -0
- package/src/mcp/index.ts +28 -0
- package/src/mcp/output-schemas.ts +3071 -0
- package/src/mcp/path-sandbox.ts +156 -0
- package/src/mcp/server.ts +358 -0
- package/src/mcp/stdio.ts +92 -0
- package/src/mcp/tools.ts +563 -0
- package/src/mcp/types.ts +66 -0
|
@@ -0,0 +1,234 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Aufrufoptionen von `untangle watch`.
|
|
3
|
+
*
|
|
4
|
+
* Bewusst ohne Argument-Bibliothek: die Menge ist klein, geschlossen und
|
|
5
|
+
* vollstaendig hier dokumentiert. Eine unbekannte Option ist ein FEHLER und
|
|
6
|
+
* wird nie stillschweigend ignoriert — eine ignorierte Option ist die
|
|
7
|
+
* lautloseste Art, etwas anderes zu messen als der Nutzer wollte (E4).
|
|
8
|
+
*/
|
|
9
|
+
import path from "node:path";
|
|
10
|
+
|
|
11
|
+
export interface WatchOptionsV1 {
|
|
12
|
+
/** Absoluter, OS-nativer Pfad des ueberwachten Baums. */
|
|
13
|
+
root: string;
|
|
14
|
+
repoId: string;
|
|
15
|
+
refId: string;
|
|
16
|
+
format: "text" | "json";
|
|
17
|
+
/** Absoluter Pfad der Mitschrift, oder `null`. */
|
|
18
|
+
outPath: string | null;
|
|
19
|
+
/** Farbe im Terminal. Nur wahr, wenn stdout ein TTY ist und niemand widerspricht. */
|
|
20
|
+
color: boolean;
|
|
21
|
+
debounceMs: number;
|
|
22
|
+
reconciliationIntervalMs: number;
|
|
23
|
+
/** Dateien groesser als dies gehen mit Grund ins Ledger statt in die Zahlen. */
|
|
24
|
+
maxFileBytes: number;
|
|
25
|
+
/** Hoechstzahl der je Aenderung ausgewiesenen Scope-Deltas. */
|
|
26
|
+
scopeLimit: number;
|
|
27
|
+
/**
|
|
28
|
+
* Nach so vielen Aenderungsereignissen sauber beenden. `null` = nur auf
|
|
29
|
+
* Signal. Existiert, damit ein Lauf reproduzierbar vorfuehrbar ist, ohne
|
|
30
|
+
* dass jemand ein Signal von Hand schicken muss.
|
|
31
|
+
*/
|
|
32
|
+
exitAfterChanges: number | null;
|
|
33
|
+
/** Nur die Grundmessung ausgeben und beenden (Selbsttest, kein Watch-Lauf). */
|
|
34
|
+
baselineOnly: boolean;
|
|
35
|
+
help: boolean;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
export interface ParsedWatchArgsV1 {
|
|
39
|
+
ok: true;
|
|
40
|
+
options: WatchOptionsV1;
|
|
41
|
+
}
|
|
42
|
+
export interface FailedWatchArgsV1 {
|
|
43
|
+
ok: false;
|
|
44
|
+
message: string;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
export const WATCH_USAGE = `untangle watch — complexity monitoring
|
|
48
|
+
|
|
49
|
+
Watch a tree and report each metric's delta for every change
|
|
50
|
+
(structural, semantic, cyclomatic, cognitive), including whether
|
|
51
|
+
complexity decreased or increased.
|
|
52
|
+
|
|
53
|
+
Usage:
|
|
54
|
+
untangle watch [OPTIONS]
|
|
55
|
+
|
|
56
|
+
Options:
|
|
57
|
+
--root PATH Watched tree (default: current directory)
|
|
58
|
+
--repo-id ID Repository identity for the lock (default: directory name)
|
|
59
|
+
--ref-id ID Ref identity for the lock (default: <repo-id>:working-tree)
|
|
60
|
+
--format text|json Output format (default: text; json = one JSON line per event)
|
|
61
|
+
--out FILE Also save the stream to FILE (always without color)
|
|
62
|
+
--no-color Disable color even on a TTY
|
|
63
|
+
--debounce MS Debounce quiet period (default: 200)
|
|
64
|
+
--reconcile MS Full reconciliation interval (default: 30000)
|
|
65
|
+
--max-file-bytes N File size limit (default: 5242880)
|
|
66
|
+
--scopes N Maximum reported scope deltas per change (default: 5)
|
|
67
|
+
--exit-after N Stop cleanly after N changes (default: on signal only)
|
|
68
|
+
--baseline-only Report the baseline and exit
|
|
69
|
+
--index Maintain the search index instead of complexity stream
|
|
70
|
+
--repo ID --index: required with several configured repositories
|
|
71
|
+
--ref NAME --index: must be physically checked out
|
|
72
|
+
--embedder auto|offline --index: current index profile or explicitly offline
|
|
73
|
+
-h, --help Show this help
|
|
74
|
+
|
|
75
|
+
Search-index mode:
|
|
76
|
+
--index requires the complete CLI build (pnpm build).
|
|
77
|
+
--reconcile becomes the check interval; --baseline-only checks/updates once;
|
|
78
|
+
--exit-after counts updates. Progress goes to stderr.
|
|
79
|
+
|
|
80
|
+
Shutdown:
|
|
81
|
+
SIGINT (Ctrl-C) or SIGTERM stops cleanly: watcher stopped, stream
|
|
82
|
+
closed, ref lock released. No orphaned lock is left behind.`;
|
|
83
|
+
|
|
84
|
+
const DEFAULTS = {
|
|
85
|
+
debounceMs: 200,
|
|
86
|
+
reconciliationIntervalMs: 30_000,
|
|
87
|
+
maxFileBytes: 5 * 1024 * 1024,
|
|
88
|
+
scopeLimit: 5,
|
|
89
|
+
};
|
|
90
|
+
|
|
91
|
+
export interface ParseWatchArgsEnv {
|
|
92
|
+
cwd: string;
|
|
93
|
+
isTty: boolean;
|
|
94
|
+
/** `NO_COLOR` aus der Umgebung (jeder nicht-leere Wert schaltet Farbe ab). */
|
|
95
|
+
noColorEnv: string | undefined;
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
export function parseWatchArgs(
|
|
99
|
+
argv: readonly string[],
|
|
100
|
+
env: ParseWatchArgsEnv,
|
|
101
|
+
): ParsedWatchArgsV1 | FailedWatchArgsV1 {
|
|
102
|
+
let root = env.cwd;
|
|
103
|
+
let repoId: string | null = null;
|
|
104
|
+
let refId: string | null = null;
|
|
105
|
+
let format: "text" | "json" = "text";
|
|
106
|
+
let outPath: string | null = null;
|
|
107
|
+
let colorRequested = true;
|
|
108
|
+
let debounceMs = DEFAULTS.debounceMs;
|
|
109
|
+
let reconciliationIntervalMs = DEFAULTS.reconciliationIntervalMs;
|
|
110
|
+
let maxFileBytes = DEFAULTS.maxFileBytes;
|
|
111
|
+
let scopeLimit = DEFAULTS.scopeLimit;
|
|
112
|
+
let exitAfterChanges: number | null = null;
|
|
113
|
+
let baselineOnly = false;
|
|
114
|
+
let help = false;
|
|
115
|
+
|
|
116
|
+
for (let index = 0; index < argv.length; index++) {
|
|
117
|
+
const arg = argv[index] as string;
|
|
118
|
+
const takeValue = (): string | null => {
|
|
119
|
+
const value = argv[index + 1];
|
|
120
|
+
if (value === undefined || value.startsWith("--")) return null;
|
|
121
|
+
index++;
|
|
122
|
+
return value;
|
|
123
|
+
};
|
|
124
|
+
switch (arg) {
|
|
125
|
+
case "-h":
|
|
126
|
+
case "--help":
|
|
127
|
+
help = true;
|
|
128
|
+
break;
|
|
129
|
+
case "--no-color":
|
|
130
|
+
colorRequested = false;
|
|
131
|
+
break;
|
|
132
|
+
case "--baseline-only":
|
|
133
|
+
baselineOnly = true;
|
|
134
|
+
break;
|
|
135
|
+
case "--root": {
|
|
136
|
+
const value = takeValue();
|
|
137
|
+
if (value === null) return fail("--root requires a path");
|
|
138
|
+
root = path.resolve(env.cwd, value);
|
|
139
|
+
break;
|
|
140
|
+
}
|
|
141
|
+
case "--repo-id": {
|
|
142
|
+
const value = takeValue();
|
|
143
|
+
if (value === null) return fail("--repo-id requires a string");
|
|
144
|
+
repoId = value;
|
|
145
|
+
break;
|
|
146
|
+
}
|
|
147
|
+
case "--ref-id": {
|
|
148
|
+
const value = takeValue();
|
|
149
|
+
if (value === null) return fail("--ref-id requires a string");
|
|
150
|
+
refId = value;
|
|
151
|
+
break;
|
|
152
|
+
}
|
|
153
|
+
case "--format": {
|
|
154
|
+
const value = takeValue();
|
|
155
|
+
if (value !== "text" && value !== "json") {
|
|
156
|
+
return fail(`--format requires "text" or "json"; received "${String(value)}"`);
|
|
157
|
+
}
|
|
158
|
+
format = value;
|
|
159
|
+
break;
|
|
160
|
+
}
|
|
161
|
+
case "--out": {
|
|
162
|
+
const value = takeValue();
|
|
163
|
+
if (value === null) return fail("--out requires a file path");
|
|
164
|
+
outPath = path.resolve(env.cwd, value);
|
|
165
|
+
break;
|
|
166
|
+
}
|
|
167
|
+
case "--debounce": {
|
|
168
|
+
const value = positiveInt(takeValue());
|
|
169
|
+
if (value === null) return fail("--debounce requires a positive integer");
|
|
170
|
+
debounceMs = value;
|
|
171
|
+
break;
|
|
172
|
+
}
|
|
173
|
+
case "--reconcile": {
|
|
174
|
+
const value = positiveInt(takeValue());
|
|
175
|
+
if (value === null) return fail("--reconcile requires a positive integer");
|
|
176
|
+
reconciliationIntervalMs = value;
|
|
177
|
+
break;
|
|
178
|
+
}
|
|
179
|
+
case "--max-file-bytes": {
|
|
180
|
+
const value = positiveInt(takeValue());
|
|
181
|
+
if (value === null) return fail("--max-file-bytes requires a positive integer");
|
|
182
|
+
maxFileBytes = value;
|
|
183
|
+
break;
|
|
184
|
+
}
|
|
185
|
+
case "--scopes": {
|
|
186
|
+
const value = positiveInt(takeValue());
|
|
187
|
+
if (value === null) return fail("--scopes requires a positive integer");
|
|
188
|
+
scopeLimit = value;
|
|
189
|
+
break;
|
|
190
|
+
}
|
|
191
|
+
case "--exit-after": {
|
|
192
|
+
const value = positiveInt(takeValue());
|
|
193
|
+
if (value === null) return fail("--exit-after requires a positive integer");
|
|
194
|
+
exitAfterChanges = value;
|
|
195
|
+
break;
|
|
196
|
+
}
|
|
197
|
+
default:
|
|
198
|
+
return fail(`unknown option "${arg}"; see "untangle watch --help"`);
|
|
199
|
+
}
|
|
200
|
+
}
|
|
201
|
+
|
|
202
|
+
const effectiveRepoId = repoId ?? path.basename(root);
|
|
203
|
+
const colorPossible = env.isTty && (env.noColorEnv === undefined || env.noColorEnv === "");
|
|
204
|
+
|
|
205
|
+
return {
|
|
206
|
+
ok: true,
|
|
207
|
+
options: {
|
|
208
|
+
root,
|
|
209
|
+
repoId: effectiveRepoId,
|
|
210
|
+
refId: refId ?? `${effectiveRepoId}:working-tree`,
|
|
211
|
+
format,
|
|
212
|
+
outPath,
|
|
213
|
+
color: colorRequested && colorPossible && format === "text",
|
|
214
|
+
debounceMs,
|
|
215
|
+
reconciliationIntervalMs,
|
|
216
|
+
maxFileBytes,
|
|
217
|
+
scopeLimit,
|
|
218
|
+
exitAfterChanges,
|
|
219
|
+
baselineOnly,
|
|
220
|
+
help,
|
|
221
|
+
},
|
|
222
|
+
};
|
|
223
|
+
}
|
|
224
|
+
|
|
225
|
+
function fail(message: string): FailedWatchArgsV1 {
|
|
226
|
+
return { ok: false, message };
|
|
227
|
+
}
|
|
228
|
+
|
|
229
|
+
function positiveInt(raw: string | null): number | null {
|
|
230
|
+
if (raw === null) return null;
|
|
231
|
+
const value = Number.parseInt(raw, 10);
|
|
232
|
+
if (!Number.isInteger(value) || value <= 0) return null;
|
|
233
|
+
return value;
|
|
234
|
+
}
|
|
@@ -0,0 +1,240 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Darstellung des Stroms — lesbar im Terminal, maschinenlesbar mit
|
|
3
|
+
* `--format json`.
|
|
4
|
+
*
|
|
5
|
+
* Beide Wege speisen sich aus DENSELBEN `WatchStreamEventV1`-Werten
|
|
6
|
+
* (`events.ts`); die Textform laesst nie etwas weg, was die JSON-Form traegt,
|
|
7
|
+
* ausser den Scope-Deltas jenseits von `--scopes`.
|
|
8
|
+
*
|
|
9
|
+
* FARBE nur, wenn stdout ein TTY ist (`options.ts` entscheidet das, nicht
|
|
10
|
+
* dieses Modul). Eine Mitschrift per `--out` ist deshalb IMMER frei von
|
|
11
|
+
* Steuerzeichen: eine Datei voller ANSI-Sequenzen ist keine Mitschrift,
|
|
12
|
+
* sondern ein Screenshot.
|
|
13
|
+
*/
|
|
14
|
+
import { METRIC_KEYS, type MetricKey, type WatchStreamEventV1 } from "./events.js";
|
|
15
|
+
|
|
16
|
+
const RESET = "\u001B[0m";
|
|
17
|
+
const PALETTE = {
|
|
18
|
+
abgebaut: "\u001B[32m", // gruen: Komplexitaet abgebaut
|
|
19
|
+
aufgebaut: "\u001B[31m", // rot: Komplexitaet aufgebaut
|
|
20
|
+
unveraendert: "\u001B[2m", // gedimmt
|
|
21
|
+
path: "\u001B[1m",
|
|
22
|
+
warn: "\u001B[33m",
|
|
23
|
+
meta: "\u001B[2m",
|
|
24
|
+
} as const;
|
|
25
|
+
|
|
26
|
+
/** Feste Spaltenbreite, damit vier Metriken untereinander lesbar bleiben. */
|
|
27
|
+
const METRIC_LABEL_WIDTH = Math.max(...METRIC_KEYS.map((key) => key.length));
|
|
28
|
+
const DIRECTION_LABELS = {
|
|
29
|
+
abgebaut: "reduced",
|
|
30
|
+
aufgebaut: "increased",
|
|
31
|
+
unveraendert: "unchanged",
|
|
32
|
+
} as const;
|
|
33
|
+
|
|
34
|
+
export interface RendererOptions {
|
|
35
|
+
color: boolean;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
/** Eine Zeile JSON je Ereignis (JSONL) — stabil sortierte Schluessel gibt `JSON.stringify` nicht her, die Feldreihenfolge folgt der Deklaration in `events.ts`. */
|
|
39
|
+
export function renderJson(event: WatchStreamEventV1): string {
|
|
40
|
+
return JSON.stringify(event);
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
/** Menschenlesbare Darstellung eines Ereignisses; mehrzeilig, ohne Zeilenumbruch am Ende. */
|
|
44
|
+
export function renderText(event: WatchStreamEventV1, options: RendererOptions): string {
|
|
45
|
+
const paint = (text: string, key: keyof typeof PALETTE): string =>
|
|
46
|
+
options.color ? `${PALETTE[key]}${text}${RESET}` : text;
|
|
47
|
+
const stamp = clockOf(event.at);
|
|
48
|
+
const lines: string[] = [];
|
|
49
|
+
|
|
50
|
+
switch (event.kind) {
|
|
51
|
+
case "started":
|
|
52
|
+
lines.push(`${stamp} untangle watch — complexity monitoring`);
|
|
53
|
+
lines.push(`${indent()}Tree ${event.root}`);
|
|
54
|
+
lines.push(`${indent()}Repo ${event.repoId} Ref ${event.refId}`);
|
|
55
|
+
lines.push(`${indent()}Lock ${event.lockKey}`);
|
|
56
|
+
break;
|
|
57
|
+
|
|
58
|
+
case "baseline": {
|
|
59
|
+
lines.push(`${stamp} Baseline complete (${String(event.durationMs)} ms)`);
|
|
60
|
+
lines.push(
|
|
61
|
+
`${indent()}${String(event.filesAnalyzed)} file(s) measured, ` +
|
|
62
|
+
`${String(event.scopeCount)} Scope(s); ` +
|
|
63
|
+
`${String(event.filesUnanalyzed)} file(s) not analyzed (see above)`,
|
|
64
|
+
);
|
|
65
|
+
lines.push(
|
|
66
|
+
paint(
|
|
67
|
+
`${indent()}${String(event.filesExcludedByRules)} path(s) excluded by ignore rules ` +
|
|
68
|
+
`(.gitignore, default exclusions), not analysis failures`,
|
|
69
|
+
"meta",
|
|
70
|
+
),
|
|
71
|
+
);
|
|
72
|
+
for (const metric of METRIC_KEYS) {
|
|
73
|
+
lines.push(
|
|
74
|
+
`${indent()}${pad(metric)} ${formatNumber(event.totals[metric]).padStart(9)}` +
|
|
75
|
+
` ${paint(readingLabel(metric), "meta")}`,
|
|
76
|
+
);
|
|
77
|
+
}
|
|
78
|
+
if (event.scopeIdCollisions > 0 || event.nodeKindFallbacks > 0) {
|
|
79
|
+
lines.push(
|
|
80
|
+
paint(
|
|
81
|
+
`${indent()}Limitation: ${String(event.scopeIdCollisions)} ambiguous ` +
|
|
82
|
+
`adapter scope ID(s) remapped, ${String(event.nodeKindFallbacks)} ` +
|
|
83
|
+
`NodeKindFact(s) assigned through a fallback.`,
|
|
84
|
+
"meta",
|
|
85
|
+
),
|
|
86
|
+
);
|
|
87
|
+
}
|
|
88
|
+
break;
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
case "change": {
|
|
92
|
+
const sign = { added: "+", modified: "~", deleted: "-" }[event.changeKind];
|
|
93
|
+
lines.push(
|
|
94
|
+
`${stamp} ${sign} ${paint(event.path, "path")} ` +
|
|
95
|
+
`${paint(verdictLabel(event.verdict), event.verdict)}`,
|
|
96
|
+
);
|
|
97
|
+
for (const delta of event.metrics) {
|
|
98
|
+
const before = delta.previous === null ? "—" : formatNumber(delta.previous);
|
|
99
|
+
const after = delta.current === null ? "—" : formatNumber(delta.current);
|
|
100
|
+
const change = `${formatSigned(delta.delta)}, ${DIRECTION_LABELS[delta.direction]}`;
|
|
101
|
+
lines.push(
|
|
102
|
+
`${indent()}${pad(delta.metric)} ${before.padStart(7)} -> ${after.padStart(7)} ` +
|
|
103
|
+
paint(`(${change})`, delta.direction),
|
|
104
|
+
);
|
|
105
|
+
}
|
|
106
|
+
if (event.scopes.length > 0) {
|
|
107
|
+
lines.push(`${indent()}Contribution locations (execution_unit scope):`);
|
|
108
|
+
for (const scope of event.scopes) {
|
|
109
|
+
const before = scope.previous === null ? "—" : formatNumber(scope.previous);
|
|
110
|
+
const after = scope.current === null ? "—" : formatNumber(scope.current);
|
|
111
|
+
lines.push(
|
|
112
|
+
`${indent(4)}${scope.metric} ${before} -> ${after} ` +
|
|
113
|
+
paint(
|
|
114
|
+
`(${formatSigned(scope.delta)}, ${DIRECTION_LABELS[scope.direction]})`,
|
|
115
|
+
scope.direction,
|
|
116
|
+
) +
|
|
117
|
+
` ${scope.label} [${scope.kind}] line ${String(scope.line)}`,
|
|
118
|
+
);
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
for (const note of event.notes) {
|
|
122
|
+
lines.push(paint(`${indent()}Note: ${note}`, "meta"));
|
|
123
|
+
}
|
|
124
|
+
break;
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
case "unanalyzed": {
|
|
128
|
+
const entry = event.entry;
|
|
129
|
+
lines.push(
|
|
130
|
+
`${stamp} ${paint("!", "warn")} ${paint(entry.path ?? "(no path)", "path")} — ` +
|
|
131
|
+
paint(`NOT ANALYZED (${entry.reason}, tier ${entry.stage})`, "warn"),
|
|
132
|
+
);
|
|
133
|
+
lines.push(`${indent()}${entry.detail}`);
|
|
134
|
+
lines.push(
|
|
135
|
+
paint(
|
|
136
|
+
`${indent()}${entry.recoverable ? "A later attempt may succeed." : "Permanent: another attempt will not change the result."}`,
|
|
137
|
+
"meta",
|
|
138
|
+
),
|
|
139
|
+
);
|
|
140
|
+
break;
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
case "status":
|
|
144
|
+
lines.push(
|
|
145
|
+
`${stamp} State: ${event.status}` +
|
|
146
|
+
(event.detail === null ? "" : ` — ${paint(event.detail, "warn")}`),
|
|
147
|
+
);
|
|
148
|
+
break;
|
|
149
|
+
|
|
150
|
+
case "stopped": {
|
|
151
|
+
const why = {
|
|
152
|
+
signal: `Signal ${event.signal ?? "?"}`,
|
|
153
|
+
limit: "--exit-after reached",
|
|
154
|
+
baseline: "--baseline-only",
|
|
155
|
+
error: "Error",
|
|
156
|
+
}[event.reason];
|
|
157
|
+
lines.push(`${stamp} Stopped (${why}) after ${String(event.durationMs)} ms`);
|
|
158
|
+
lines.push(
|
|
159
|
+
`${indent()}${String(event.changesObserved)} change(s) processed, ` +
|
|
160
|
+
`${String(event.filesUnanalyzed)} file(s) not analyzable`,
|
|
161
|
+
);
|
|
162
|
+
lines.push(`${indent()}Net change in this session:`);
|
|
163
|
+
for (const metric of METRIC_KEYS) {
|
|
164
|
+
const value = event.net[metric];
|
|
165
|
+
lines.push(
|
|
166
|
+
`${indent(4)}${pad(metric)} ${paint(formatSigned(value).padStart(9), directionKey(value))}`,
|
|
167
|
+
);
|
|
168
|
+
}
|
|
169
|
+
lines.push(
|
|
170
|
+
`${indent()}Total: ${paint(verdictLabel(event.netDirection), event.netDirection)}`,
|
|
171
|
+
);
|
|
172
|
+
lines.push(
|
|
173
|
+
paint(
|
|
174
|
+
`${indent()}Backlog: peak ${String(event.queue.maxDepthObserved)} item(s), ` +
|
|
175
|
+
`${String(event.queue.maxBytesObserved)} bytes; ` +
|
|
176
|
+
`${String(event.queue.overBudgetAdmissions)} budget exception(s)`,
|
|
177
|
+
"meta",
|
|
178
|
+
),
|
|
179
|
+
);
|
|
180
|
+
lines.push(
|
|
181
|
+
`${indent()}Ref lock ${event.lockReleased ? "released" : paint("NOT released", "warn")}`,
|
|
182
|
+
);
|
|
183
|
+
break;
|
|
184
|
+
}
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
return lines.join("\n");
|
|
188
|
+
}
|
|
189
|
+
|
|
190
|
+
function directionKey(value: number): "abgebaut" | "aufgebaut" | "unveraendert" {
|
|
191
|
+
if (value < 0) return "abgebaut";
|
|
192
|
+
if (value > 0) return "aufgebaut";
|
|
193
|
+
return "unveraendert";
|
|
194
|
+
}
|
|
195
|
+
|
|
196
|
+
function verdictLabel(direction: "abgebaut" | "aufgebaut" | "unveraendert"): string {
|
|
197
|
+
switch (direction) {
|
|
198
|
+
case "abgebaut":
|
|
199
|
+
return "Complexity reduced";
|
|
200
|
+
case "aufgebaut":
|
|
201
|
+
return "Complexity increased";
|
|
202
|
+
default:
|
|
203
|
+
return "Complexity unchanged";
|
|
204
|
+
}
|
|
205
|
+
}
|
|
206
|
+
|
|
207
|
+
function readingLabel(metric: MetricKey): string {
|
|
208
|
+
return metric === "semantic"
|
|
209
|
+
? "file_chunks scope (estimated tokens across all chunks)"
|
|
210
|
+
: "execution_unit scope (each execution unit exactly once)";
|
|
211
|
+
}
|
|
212
|
+
|
|
213
|
+
function pad(metric: string): string {
|
|
214
|
+
return metric.padEnd(METRIC_LABEL_WIDTH, " ");
|
|
215
|
+
}
|
|
216
|
+
|
|
217
|
+
function indent(width = 10): string {
|
|
218
|
+
return " ".repeat(width);
|
|
219
|
+
}
|
|
220
|
+
|
|
221
|
+
/** Ganze Zahlen ohne Nachkomma, gebrochene mit zwei Stellen. */
|
|
222
|
+
export function formatNumber(value: number): string {
|
|
223
|
+
return Number.isInteger(value) ? String(value) : value.toFixed(2);
|
|
224
|
+
}
|
|
225
|
+
|
|
226
|
+
/** Immer mit Vorzeichen — `0` bleibt `0`, damit "keine Wirkung" auch so aussieht. */
|
|
227
|
+
export function formatSigned(value: number): string {
|
|
228
|
+
if (value === 0) return "0";
|
|
229
|
+
const text = formatNumber(Math.abs(value));
|
|
230
|
+
return value > 0 ? `+${text}` : `-${text}`;
|
|
231
|
+
}
|
|
232
|
+
|
|
233
|
+
/**
|
|
234
|
+
* `HH:MM:SS` aus einem ISO-Zeitstempel. Zeitangaben sind PROTOKOLLAUSGABE,
|
|
235
|
+
* nie Ergebnisdaten — die Metriken selbst kennen keine Uhrzeit.
|
|
236
|
+
*/
|
|
237
|
+
function clockOf(iso: string): string {
|
|
238
|
+
const match = /T(\d{2}:\d{2}:\d{2})/.exec(iso);
|
|
239
|
+
return match === null ? iso.padEnd(8, " ") : (match[1] as string);
|
|
240
|
+
}
|