@kindgi/cli 0.0.0-bootstrap.0 → 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 +201 -0
- package/README.md +738 -1
- package/dist/build/apt.d.ts +16 -0
- package/dist/build/apt.d.ts.map +1 -0
- package/dist/build/apt.js +50 -0
- package/dist/build/apt.js.map +1 -0
- package/dist/build/bundle.d.ts +48 -0
- package/dist/build/bundle.d.ts.map +1 -0
- package/dist/build/bundle.js +125 -0
- package/dist/build/bundle.js.map +1 -0
- package/dist/build/containerfile.d.ts +27 -0
- package/dist/build/containerfile.d.ts.map +1 -0
- package/dist/build/containerfile.js +197 -0
- package/dist/build/containerfile.js.map +1 -0
- package/dist/build/context-files.d.ts +24 -0
- package/dist/build/context-files.d.ts.map +1 -0
- package/dist/build/context-files.js +99 -0
- package/dist/build/context-files.js.map +1 -0
- package/dist/build/defaults.d.ts +66 -0
- package/dist/build/defaults.d.ts.map +1 -0
- package/dist/build/defaults.js +597 -0
- package/dist/build/defaults.js.map +1 -0
- package/dist/build/envelope.d.ts +72 -0
- package/dist/build/envelope.d.ts.map +1 -0
- package/dist/build/envelope.js +76 -0
- package/dist/build/envelope.js.map +1 -0
- package/dist/build/host-install.d.ts +100 -0
- package/dist/build/host-install.d.ts.map +1 -0
- package/dist/build/host-install.js +443 -0
- package/dist/build/host-install.js.map +1 -0
- package/dist/build/image-config.d.ts +32 -0
- package/dist/build/image-config.d.ts.map +1 -0
- package/dist/build/image-config.js +129 -0
- package/dist/build/image-config.js.map +1 -0
- package/dist/build/integrity.d.ts +51 -0
- package/dist/build/integrity.d.ts.map +1 -0
- package/dist/build/integrity.js +75 -0
- package/dist/build/integrity.js.map +1 -0
- package/dist/build/node-image.d.ts +18 -0
- package/dist/build/node-image.d.ts.map +1 -0
- package/dist/build/node-image.js +46 -0
- package/dist/build/node-image.js.map +1 -0
- package/dist/build/pack-root.d.ts +69 -0
- package/dist/build/pack-root.d.ts.map +1 -0
- package/dist/build/pack-root.js +102 -0
- package/dist/build/pack-root.js.map +1 -0
- package/dist/build/poetry-requirements.d.ts +5 -0
- package/dist/build/poetry-requirements.d.ts.map +1 -0
- package/dist/build/poetry-requirements.js +8 -0
- package/dist/build/poetry-requirements.js.map +1 -0
- package/dist/build/python-image.d.ts +40 -0
- package/dist/build/python-image.d.ts.map +1 -0
- package/dist/build/python-image.js +197 -0
- package/dist/build/python-image.js.map +1 -0
- package/dist/build/runners.d.ts +259 -0
- package/dist/build/runners.d.ts.map +1 -0
- package/dist/build/runners.js +4 -0
- package/dist/build/runners.js.map +1 -0
- package/dist/build/version-specifier.d.ts +2 -0
- package/dist/build/version-specifier.d.ts.map +1 -0
- package/dist/build/version-specifier.js +70 -0
- package/dist/build/version-specifier.js.map +1 -0
- package/dist/cli-package.d.ts +15 -0
- package/dist/cli-package.d.ts.map +1 -0
- package/dist/cli-package.js +37 -0
- package/dist/cli-package.js.map +1 -0
- package/dist/cli.d.ts +3 -0
- package/dist/cli.d.ts.map +1 -0
- package/dist/cli.js +26 -0
- package/dist/cli.js.map +1 -0
- package/dist/commands/adapters.d.ts +3 -0
- package/dist/commands/adapters.d.ts.map +1 -0
- package/dist/commands/adapters.js +148 -0
- package/dist/commands/adapters.js.map +1 -0
- package/dist/commands/agents.d.ts +3 -0
- package/dist/commands/agents.d.ts.map +1 -0
- package/dist/commands/agents.js +82 -0
- package/dist/commands/agents.js.map +1 -0
- package/dist/commands/approvals.d.ts +3 -0
- package/dist/commands/approvals.d.ts.map +1 -0
- package/dist/commands/approvals.js +92 -0
- package/dist/commands/approvals.js.map +1 -0
- package/dist/commands/artifacts.d.ts +3 -0
- package/dist/commands/artifacts.d.ts.map +1 -0
- package/dist/commands/artifacts.js +87 -0
- package/dist/commands/artifacts.js.map +1 -0
- package/dist/commands/auth.d.ts +25 -0
- package/dist/commands/auth.d.ts.map +1 -0
- package/dist/commands/auth.js +283 -0
- package/dist/commands/auth.js.map +1 -0
- package/dist/commands/build.d.ts +46 -0
- package/dist/commands/build.d.ts.map +1 -0
- package/dist/commands/build.js +902 -0
- package/dist/commands/build.js.map +1 -0
- package/dist/commands/capabilities.d.ts +3 -0
- package/dist/commands/capabilities.d.ts.map +1 -0
- package/dist/commands/capabilities.js +38 -0
- package/dist/commands/capabilities.js.map +1 -0
- package/dist/commands/conversations.d.ts +3 -0
- package/dist/commands/conversations.d.ts.map +1 -0
- package/dist/commands/conversations.js +75 -0
- package/dist/commands/conversations.js.map +1 -0
- package/dist/commands/deploy.d.ts +7 -0
- package/dist/commands/deploy.d.ts.map +1 -0
- package/dist/commands/deploy.js +697 -0
- package/dist/commands/deploy.js.map +1 -0
- package/dist/commands/dev.d.ts +43 -0
- package/dist/commands/dev.d.ts.map +1 -0
- package/dist/commands/dev.js +1110 -0
- package/dist/commands/dev.js.map +1 -0
- package/dist/commands/env.d.ts +27 -0
- package/dist/commands/env.d.ts.map +1 -0
- package/dist/commands/env.js +816 -0
- package/dist/commands/env.js.map +1 -0
- package/dist/commands/feedback.d.ts +33 -0
- package/dist/commands/feedback.d.ts.map +1 -0
- package/dist/commands/feedback.js +374 -0
- package/dist/commands/feedback.js.map +1 -0
- package/dist/commands/flows.d.ts +3 -0
- package/dist/commands/flows.d.ts.map +1 -0
- package/dist/commands/flows.js +60 -0
- package/dist/commands/flows.js.map +1 -0
- package/dist/commands/guardrails.d.ts +3 -0
- package/dist/commands/guardrails.d.ts.map +1 -0
- package/dist/commands/guardrails.js +89 -0
- package/dist/commands/guardrails.js.map +1 -0
- package/dist/commands/health.d.ts +8 -0
- package/dist/commands/health.d.ts.map +1 -0
- package/dist/commands/health.js +40 -0
- package/dist/commands/health.js.map +1 -0
- package/dist/commands/helpers.d.ts +48 -0
- package/dist/commands/helpers.d.ts.map +1 -0
- package/dist/commands/helpers.js +110 -0
- package/dist/commands/helpers.js.map +1 -0
- package/dist/commands/index.d.ts +7 -0
- package/dist/commands/index.d.ts.map +1 -0
- package/dist/commands/index.js +90 -0
- package/dist/commands/index.js.map +1 -0
- package/dist/commands/init.d.ts +46 -0
- package/dist/commands/init.d.ts.map +1 -0
- package/dist/commands/init.js +454 -0
- package/dist/commands/init.js.map +1 -0
- package/dist/commands/key.d.ts +3 -0
- package/dist/commands/key.d.ts.map +1 -0
- package/dist/commands/key.js +322 -0
- package/dist/commands/key.js.map +1 -0
- package/dist/commands/mcp.d.ts +43 -0
- package/dist/commands/mcp.d.ts.map +1 -0
- package/dist/commands/mcp.js +433 -0
- package/dist/commands/mcp.js.map +1 -0
- package/dist/commands/memory.d.ts +3 -0
- package/dist/commands/memory.d.ts.map +1 -0
- package/dist/commands/memory.js +82 -0
- package/dist/commands/memory.js.map +1 -0
- package/dist/commands/observations.d.ts +3 -0
- package/dist/commands/observations.d.ts.map +1 -0
- package/dist/commands/observations.js +27 -0
- package/dist/commands/observations.js.map +1 -0
- package/dist/commands/proposals.d.ts +3 -0
- package/dist/commands/proposals.d.ts.map +1 -0
- package/dist/commands/proposals.js +116 -0
- package/dist/commands/proposals.js.map +1 -0
- package/dist/commands/provenance.d.ts +3 -0
- package/dist/commands/provenance.d.ts.map +1 -0
- package/dist/commands/provenance.js +53 -0
- package/dist/commands/provenance.js.map +1 -0
- package/dist/commands/providers.d.ts +3 -0
- package/dist/commands/providers.d.ts.map +1 -0
- package/dist/commands/providers.js +212 -0
- package/dist/commands/providers.js.map +1 -0
- package/dist/commands/reviewers.d.ts +3 -0
- package/dist/commands/reviewers.d.ts.map +1 -0
- package/dist/commands/reviewers.js +78 -0
- package/dist/commands/reviewers.js.map +1 -0
- package/dist/commands/runs.d.ts +3 -0
- package/dist/commands/runs.d.ts.map +1 -0
- package/dist/commands/runs.js +223 -0
- package/dist/commands/runs.js.map +1 -0
- package/dist/commands/secrets.d.ts +18 -0
- package/dist/commands/secrets.d.ts.map +1 -0
- package/dist/commands/secrets.js +702 -0
- package/dist/commands/secrets.js.map +1 -0
- package/dist/commands/skills.d.ts +64 -0
- package/dist/commands/skills.d.ts.map +1 -0
- package/dist/commands/skills.js +430 -0
- package/dist/commands/skills.js.map +1 -0
- package/dist/commands/test.d.ts +5 -0
- package/dist/commands/test.d.ts.map +1 -0
- package/dist/commands/test.js +181 -0
- package/dist/commands/test.js.map +1 -0
- package/dist/commands/tokens.d.ts +3 -0
- package/dist/commands/tokens.d.ts.map +1 -0
- package/dist/commands/tokens.js +33 -0
- package/dist/commands/tokens.js.map +1 -0
- package/dist/commands/tools.d.ts +3 -0
- package/dist/commands/tools.d.ts.map +1 -0
- package/dist/commands/tools.js +162 -0
- package/dist/commands/tools.js.map +1 -0
- package/dist/commands/types.d.ts +54 -0
- package/dist/commands/types.d.ts.map +1 -0
- package/dist/commands/types.js +4 -0
- package/dist/commands/types.js.map +1 -0
- package/dist/commands/unwired.d.ts +22 -0
- package/dist/commands/unwired.d.ts.map +1 -0
- package/dist/commands/unwired.js +52 -0
- package/dist/commands/unwired.js.map +1 -0
- package/dist/commands/version.d.ts +8 -0
- package/dist/commands/version.d.ts.map +1 -0
- package/dist/commands/version.js +41 -0
- package/dist/commands/version.js.map +1 -0
- package/dist/config.d.ts +42 -0
- package/dist/config.d.ts.map +1 -0
- package/dist/config.js +83 -0
- package/dist/config.js.map +1 -0
- package/dist/context.d.ts +162 -0
- package/dist/context.d.ts.map +1 -0
- package/dist/context.js +45 -0
- package/dist/context.js.map +1 -0
- package/dist/deploy/defaults.d.ts +14 -0
- package/dist/deploy/defaults.d.ts.map +1 -0
- package/dist/deploy/defaults.js +37 -0
- package/dist/deploy/defaults.js.map +1 -0
- package/dist/deploy/envelope-loader.d.ts +24 -0
- package/dist/deploy/envelope-loader.d.ts.map +1 -0
- package/dist/deploy/envelope-loader.js +141 -0
- package/dist/deploy/envelope-loader.js.map +1 -0
- package/dist/deploy/post.d.ts +48 -0
- package/dist/deploy/post.d.ts.map +1 -0
- package/dist/deploy/post.js +210 -0
- package/dist/deploy/post.js.map +1 -0
- package/dist/deploy/response.d.ts +42 -0
- package/dist/deploy/response.d.ts.map +1 -0
- package/dist/deploy/response.js +128 -0
- package/dist/deploy/response.js.map +1 -0
- package/dist/deploy/runners.d.ts +218 -0
- package/dist/deploy/runners.d.ts.map +1 -0
- package/dist/deploy/runners.js +4 -0
- package/dist/deploy/runners.js.map +1 -0
- package/dist/dev/bundler.d.ts +10 -0
- package/dist/dev/bundler.d.ts.map +1 -0
- package/dist/dev/bundler.js +235 -0
- package/dist/dev/bundler.js.map +1 -0
- package/dist/dev/defaults.d.ts +140 -0
- package/dist/dev/defaults.d.ts.map +1 -0
- package/dist/dev/defaults.js +709 -0
- package/dist/dev/defaults.js.map +1 -0
- package/dist/dev/dev-only-imports.d.ts +15 -0
- package/dist/dev/dev-only-imports.d.ts.map +1 -0
- package/dist/dev/dev-only-imports.js +57 -0
- package/dist/dev/dev-only-imports.js.map +1 -0
- package/dist/dev/docker-compose.dev.yml +68 -0
- package/dist/dev/index-child.d.ts +2 -0
- package/dist/dev/index-child.d.ts.map +1 -0
- package/dist/dev/index-child.js +53 -0
- package/dist/dev/index-child.js.map +1 -0
- package/dist/dev/pack-code.d.ts +36 -0
- package/dist/dev/pack-code.d.ts.map +1 -0
- package/dist/dev/pack-code.js +129 -0
- package/dist/dev/pack-code.js.map +1 -0
- package/dist/dev/pack-env.d.ts +13 -0
- package/dist/dev/pack-env.d.ts.map +1 -0
- package/dist/dev/pack-env.js +36 -0
- package/dist/dev/pack-env.js.map +1 -0
- package/dist/dev/pack-service.d.ts +40 -0
- package/dist/dev/pack-service.d.ts.map +1 -0
- package/dist/dev/pack-service.js +189 -0
- package/dist/dev/pack-service.js.map +1 -0
- package/dist/dev/paths.d.ts +22 -0
- package/dist/dev/paths.d.ts.map +1 -0
- package/dist/dev/paths.js +35 -0
- package/dist/dev/paths.js.map +1 -0
- package/dist/dev/postgres-container.d.ts +77 -0
- package/dist/dev/postgres-container.d.ts.map +1 -0
- package/dist/dev/postgres-container.js +346 -0
- package/dist/dev/postgres-container.js.map +1 -0
- package/dist/dev/python-builder.d.ts +16 -0
- package/dist/dev/python-builder.d.ts.map +1 -0
- package/dist/dev/python-builder.js +122 -0
- package/dist/dev/python-builder.js.map +1 -0
- package/dist/dev/register.d.ts +71 -0
- package/dist/dev/register.d.ts.map +1 -0
- package/dist/dev/register.js +54 -0
- package/dist/dev/register.js.map +1 -0
- package/dist/dev/runners.d.ts +312 -0
- package/dist/dev/runners.d.ts.map +1 -0
- package/dist/dev/runners.js +4 -0
- package/dist/dev/runners.js.map +1 -0
- package/dist/dev/runtime-container.d.ts +71 -0
- package/dist/dev/runtime-container.d.ts.map +1 -0
- package/dist/dev/runtime-container.js +173 -0
- package/dist/dev/runtime-container.js.map +1 -0
- package/dist/dev/runtime-env.d.ts +62 -0
- package/dist/dev/runtime-env.d.ts.map +1 -0
- package/dist/dev/runtime-env.js +100 -0
- package/dist/dev/runtime-env.js.map +1 -0
- package/dist/dev/runtime-image.d.ts +26 -0
- package/dist/dev/runtime-image.d.ts.map +1 -0
- package/dist/dev/runtime-image.js +44 -0
- package/dist/dev/runtime-image.js.map +1 -0
- package/dist/dev/runtime-registry.d.ts +73 -0
- package/dist/dev/runtime-registry.d.ts.map +1 -0
- package/dist/dev/runtime-registry.js +111 -0
- package/dist/dev/runtime-registry.js.map +1 -0
- package/dist/env/defaults.d.ts +3 -0
- package/dist/env/defaults.d.ts.map +1 -0
- package/dist/env/defaults.js +22 -0
- package/dist/env/defaults.js.map +1 -0
- package/dist/env/pack-env-plan.d.ts +70 -0
- package/dist/env/pack-env-plan.d.ts.map +1 -0
- package/dist/env/pack-env-plan.js +236 -0
- package/dist/env/pack-env-plan.js.map +1 -0
- package/dist/env/parser.d.ts +9 -0
- package/dist/env/parser.d.ts.map +1 -0
- package/dist/env/parser.js +11 -0
- package/dist/env/parser.js.map +1 -0
- package/dist/env/project-env.d.ts +34 -0
- package/dist/env/project-env.d.ts.map +1 -0
- package/dist/env/project-env.js +45 -0
- package/dist/env/project-env.js.map +1 -0
- package/dist/env/runners.d.ts +22 -0
- package/dist/env/runners.d.ts.map +1 -0
- package/dist/env/runners.js +4 -0
- package/dist/env/runners.js.map +1 -0
- package/dist/env/writer.d.ts +7 -0
- package/dist/env/writer.d.ts.map +1 -0
- package/dist/env/writer.js +9 -0
- package/dist/env/writer.js.map +1 -0
- package/dist/errors.d.ts +31 -0
- package/dist/errors.d.ts.map +1 -0
- package/dist/errors.js +111 -0
- package/dist/errors.js.map +1 -0
- package/dist/help.d.ts +5 -0
- package/dist/help.d.ts.map +1 -0
- package/dist/help.js +61 -0
- package/dist/help.js.map +1 -0
- package/dist/index.d.ts +13 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +13 -0
- package/dist/index.js.map +1 -0
- package/dist/init/augment-scaffolder.d.ts +86 -0
- package/dist/init/augment-scaffolder.d.ts.map +1 -0
- package/dist/init/augment-scaffolder.js +538 -0
- package/dist/init/augment-scaffolder.js.map +1 -0
- package/dist/init/dependency-specs.d.ts +58 -0
- package/dist/init/dependency-specs.d.ts.map +1 -0
- package/dist/init/dependency-specs.js +153 -0
- package/dist/init/dependency-specs.js.map +1 -0
- package/dist/init/gitignore-patcher.d.ts +23 -0
- package/dist/init/gitignore-patcher.d.ts.map +1 -0
- package/dist/init/gitignore-patcher.js +103 -0
- package/dist/init/gitignore-patcher.js.map +1 -0
- package/dist/init/mode-detect.d.ts +34 -0
- package/dist/init/mode-detect.d.ts.map +1 -0
- package/dist/init/mode-detect.js +115 -0
- package/dist/init/mode-detect.js.map +1 -0
- package/dist/init/package-json-patcher.d.ts +36 -0
- package/dist/init/package-json-patcher.d.ts.map +1 -0
- package/dist/init/package-json-patcher.js +128 -0
- package/dist/init/package-json-patcher.js.map +1 -0
- package/dist/init/pnpm-workspace-patcher.d.ts +55 -0
- package/dist/init/pnpm-workspace-patcher.d.ts.map +1 -0
- package/dist/init/pnpm-workspace-patcher.js +248 -0
- package/dist/init/pnpm-workspace-patcher.js.map +1 -0
- package/dist/init/pyproject-patcher.d.ts +56 -0
- package/dist/init/pyproject-patcher.d.ts.map +1 -0
- package/dist/init/pyproject-patcher.js +324 -0
- package/dist/init/pyproject-patcher.js.map +1 -0
- package/dist/init/python-augment.d.ts +22 -0
- package/dist/init/python-augment.d.ts.map +1 -0
- package/dist/init/python-augment.js +300 -0
- package/dist/init/python-augment.js.map +1 -0
- package/dist/init/template-files.d.ts +18 -0
- package/dist/init/template-files.d.ts.map +1 -0
- package/dist/init/template-files.js +53 -0
- package/dist/init/template-files.js.map +1 -0
- package/dist/key/defaults.d.ts +3 -0
- package/dist/key/defaults.d.ts.map +1 -0
- package/dist/key/defaults.js +60 -0
- package/dist/key/defaults.js.map +1 -0
- package/dist/key/fingerprint.d.ts +6 -0
- package/dist/key/fingerprint.d.ts.map +1 -0
- package/dist/key/fingerprint.js +25 -0
- package/dist/key/fingerprint.js.map +1 -0
- package/dist/key/paths.d.ts +30 -0
- package/dist/key/paths.d.ts.map +1 -0
- package/dist/key/paths.js +51 -0
- package/dist/key/paths.js.map +1 -0
- package/dist/key/runners.d.ts +60 -0
- package/dist/key/runners.d.ts.map +1 -0
- package/dist/key/runners.js +4 -0
- package/dist/key/runners.js.map +1 -0
- package/dist/main.d.ts +113 -0
- package/dist/main.d.ts.map +1 -0
- package/dist/main.js +199 -0
- package/dist/main.js.map +1 -0
- package/dist/mcp/launcher.d.ts +143 -0
- package/dist/mcp/launcher.d.ts.map +1 -0
- package/dist/mcp/launcher.js +393 -0
- package/dist/mcp/launcher.js.map +1 -0
- package/dist/mcp/preset-loader.d.ts +29 -0
- package/dist/mcp/preset-loader.d.ts.map +1 -0
- package/dist/mcp/preset-loader.js +217 -0
- package/dist/mcp/preset-loader.js.map +1 -0
- package/dist/mcp/preset-types.d.ts +71 -0
- package/dist/mcp/preset-types.d.ts.map +1 -0
- package/dist/mcp/preset-types.js +4 -0
- package/dist/mcp/preset-types.js.map +1 -0
- package/dist/mcp/presets/README.md +68 -0
- package/dist/mcp/presets/postgres.json +15 -0
- package/dist/output.d.ts +26 -0
- package/dist/output.d.ts.map +1 -0
- package/dist/output.js +46 -0
- package/dist/output.js.map +1 -0
- package/dist/pack-config.d.ts +37 -0
- package/dist/pack-config.d.ts.map +1 -0
- package/dist/pack-config.js +65 -0
- package/dist/pack-config.js.map +1 -0
- package/dist/package-manager.d.ts +33 -0
- package/dist/package-manager.d.ts.map +1 -0
- package/dist/package-manager.js +129 -0
- package/dist/package-manager.js.map +1 -0
- package/dist/parse.d.ts +88 -0
- package/dist/parse.d.ts.map +1 -0
- package/dist/parse.js +100 -0
- package/dist/parse.js.map +1 -0
- package/dist/providers/preset-loader.d.ts +47 -0
- package/dist/providers/preset-loader.d.ts.map +1 -0
- package/dist/providers/preset-loader.js +107 -0
- package/dist/providers/preset-loader.js.map +1 -0
- package/dist/providers/presets/anthropic.json +47 -0
- package/dist/providers/presets/gemini.json +40 -0
- package/dist/reference.d.ts +28 -0
- package/dist/reference.d.ts.map +1 -0
- package/dist/reference.js +52 -0
- package/dist/reference.js.map +1 -0
- package/dist/sdk-package.d.ts +9 -0
- package/dist/sdk-package.d.ts.map +1 -0
- package/dist/sdk-package.js +20 -0
- package/dist/sdk-package.js.map +1 -0
- package/dist/sdk-skills/kindgi-authoring-agents/SKILL.md +252 -0
- package/dist/sdk-skills/kindgi-authoring-flows/SKILL.md +302 -0
- package/dist/sdk-skills/kindgi-authoring-guardrails/SKILL.md +297 -0
- package/dist/sdk-skills/kindgi-authoring-mcp-servers/SKILL.md +289 -0
- package/dist/sdk-skills/kindgi-authoring-providers/SKILL.md +705 -0
- package/dist/sdk-skills/kindgi-authoring-tools/SKILL.md +298 -0
- package/dist/sdk-skills/kindgi-framework-feedback/SKILL.md +211 -0
- package/dist/sdk-skills/kindgi-getting-started/SKILL.md +189 -0
- package/dist/sdk-skills/kindgi-python-authoring-agents/SKILL.md +205 -0
- package/dist/sdk-skills/kindgi-python-authoring-flows/SKILL.md +325 -0
- package/dist/sdk-skills/kindgi-python-authoring-guardrails/SKILL.md +176 -0
- package/dist/sdk-skills/kindgi-python-authoring-tools/SKILL.md +305 -0
- package/dist/sdk-skills/kindgi-python-getting-started/SKILL.md +242 -0
- package/dist/stop-signal.d.ts +15 -0
- package/dist/stop-signal.d.ts.map +1 -0
- package/dist/stop-signal.js +16 -0
- package/dist/stop-signal.js.map +1 -0
- package/dist/templates/minimal/.nvmrc +1 -0
- package/dist/templates/minimal/AGENTS.md +23 -0
- package/dist/templates/minimal/README.md.tmpl +69 -0
- package/dist/templates/minimal/agents/.gitkeep +0 -0
- package/dist/templates/minimal/flows/.gitkeep +0 -0
- package/dist/templates/minimal/gitignore +8 -0
- package/dist/templates/minimal/guardrails/.gitkeep +0 -0
- package/dist/templates/minimal/kindgi.config.ts.tmpl +44 -0
- package/dist/templates/minimal/package.json.tmpl +25 -0
- package/dist/templates/minimal/pnpm-workspace.yaml +8 -0
- package/dist/templates/minimal/tools/.gitkeep +0 -0
- package/dist/templates/minimal/tsconfig.json.tmpl +27 -0
- package/dist/templates/minimal/vitest.config.ts.tmpl +14 -0
- package/dist/templates/python/AGENTS.md +30 -0
- package/dist/templates/python/README.md.tmpl +56 -0
- package/dist/templates/python/agents/echo_agent.py.tmpl +23 -0
- package/dist/templates/python/flows/echo_flow.py.tmpl +17 -0
- package/dist/templates/python/gitignore +9 -0
- package/dist/templates/python/guardrails/response_not_empty.py.tmpl +27 -0
- package/dist/templates/python/pyproject.toml.tmpl +42 -0
- package/dist/templates/python/tests/test_tools.py.tmpl +22 -0
- package/dist/templates/python/tools/echo.py.tmpl +27 -0
- package/dist/templates/python/tools/greet.py.tmpl +20 -0
- package/dist/templates/sample/.nvmrc +1 -0
- package/dist/templates/sample/AGENTS.md +23 -0
- package/dist/templates/sample/README.md.tmpl +85 -0
- package/dist/templates/sample/agents/echo-agent/index.ts.tmpl +34 -0
- package/dist/templates/sample/flows/echo-flow/index.ts.tmpl +59 -0
- package/dist/templates/sample/gitignore +8 -0
- package/dist/templates/sample/guardrails/response-not-empty/index.ts.tmpl +58 -0
- package/dist/templates/sample/kindgi.config.ts.tmpl +41 -0
- package/dist/templates/sample/package.json.tmpl +25 -0
- package/dist/templates/sample/pnpm-workspace.yaml +8 -0
- package/dist/templates/sample/tools/echo/index.test.ts.tmpl +31 -0
- package/dist/templates/sample/tools/echo/index.ts.tmpl +37 -0
- package/dist/templates/sample/tools/fetch-httpbin/index.ts.tmpl +60 -0
- package/dist/templates/sample/tools/greet/index.ts.tmpl +35 -0
- package/dist/templates/sample/tsconfig.json.tmpl +27 -0
- package/dist/templates/sample/vitest.config.ts.tmpl +14 -0
- package/dist/terminal-input.d.ts +17 -0
- package/dist/terminal-input.d.ts.map +1 -0
- package/dist/terminal-input.js +88 -0
- package/dist/terminal-input.js.map +1 -0
- package/dist/test/defaults.d.ts +3 -0
- package/dist/test/defaults.d.ts.map +1 -0
- package/dist/test/defaults.js +104 -0
- package/dist/test/defaults.js.map +1 -0
- package/dist/test/runners.d.ts +60 -0
- package/dist/test/runners.d.ts.map +1 -0
- package/dist/test/runners.js +4 -0
- package/dist/test/runners.js.map +1 -0
- package/dist/version-info.d.ts +9 -0
- package/dist/version-info.d.ts.map +1 -0
- package/dist/version-info.js +27 -0
- package/dist/version-info.js.map +1 -0
- package/dist/write-fully.d.ts +13 -0
- package/dist/write-fully.d.ts.map +1 -0
- package/dist/write-fully.js +17 -0
- package/dist/write-fully.js.map +1 -0
- package/package.json +63 -4
|
@@ -0,0 +1,181 @@
|
|
|
1
|
+
// SPDX-License-Identifier: Apache-2.0
|
|
2
|
+
// Copyright (C) 2026 Kindgi Inc.
|
|
3
|
+
/**
|
|
4
|
+
* `kindgi test` — run the pack's tests via vitest.
|
|
5
|
+
*
|
|
6
|
+
* Shells out to the pack's OWN installed vitest binary
|
|
7
|
+
* (either `pnpm exec vitest` or `npx --no-install vitest`, picked at
|
|
8
|
+
* production wire time). The CLI does NOT bundle a vitest version —
|
|
9
|
+
* that would force upgrades on downstream packs whenever the CLI
|
|
10
|
+
* upgrades.
|
|
11
|
+
*
|
|
12
|
+
* Ergonomic defaults:
|
|
13
|
+
* - Refuses to spawn without a `vitest.config.*` at the pack root
|
|
14
|
+
* (bare vitest would sweep the whole repo on dev machines).
|
|
15
|
+
* - `--watch` threads through as `--watch`. Everything else (except
|
|
16
|
+
* the CLI's own `--reporter` short-cut + `--path`) is verbatim
|
|
17
|
+
* pass-through after `--`.
|
|
18
|
+
* - Ctrl+C forwards to the child process (via `ctx.stopSignal`),
|
|
19
|
+
* matching `kindgi dev`.
|
|
20
|
+
*
|
|
21
|
+
* Every child-process side-effect flows through `TestRunners` so tests
|
|
22
|
+
* substitute stubs; production wiring lives at
|
|
23
|
+
* `packages/cli/src/test/defaults.ts`.
|
|
24
|
+
*/
|
|
25
|
+
import { readFile } from 'node:fs/promises';
|
|
26
|
+
import { isAbsolute, join, resolve } from 'node:path';
|
|
27
|
+
import { KINDGI_CONFIG_FILENAMES } from '@kindgi/handler-runtime';
|
|
28
|
+
import { renderJson } from '../output.js';
|
|
29
|
+
export const testCommand = {
|
|
30
|
+
kind: 'leaf',
|
|
31
|
+
name: 'test',
|
|
32
|
+
description: "Run the pack's tests via vitest. Ergonomic wrapper over `vitest run`.",
|
|
33
|
+
usage: 'kindgi test [--watch] [--reporter <name>] [--path <dir>] [-- <vitest-args>...]',
|
|
34
|
+
optionSpec: {
|
|
35
|
+
watch: {
|
|
36
|
+
type: 'boolean',
|
|
37
|
+
description: 'Run vitest in watch mode. By default the tests run once (`vitest run`).',
|
|
38
|
+
},
|
|
39
|
+
reporter: {
|
|
40
|
+
type: 'string',
|
|
41
|
+
description: "The vitest reporter to use (vitest's `--reporter`), e.g. `verbose` or `json`.",
|
|
42
|
+
},
|
|
43
|
+
path: {
|
|
44
|
+
type: 'string',
|
|
45
|
+
description: 'The pack root, with a `kindgi.config.ts` (or `.mts`) and a `vitest.config.*`. Default: the current directory.',
|
|
46
|
+
},
|
|
47
|
+
},
|
|
48
|
+
run: async (ctx) => runTestCommand(ctx),
|
|
49
|
+
};
|
|
50
|
+
export async function runTestCommand(ctx) {
|
|
51
|
+
const runners = ctx.testRunners;
|
|
52
|
+
if (runners === undefined) {
|
|
53
|
+
return {
|
|
54
|
+
kind: 'error',
|
|
55
|
+
stderr: 'Internal error: kindgi test requires test runners to be wired. ' +
|
|
56
|
+
'Rebuild the CLI (`pnpm --filter @kindgi/cli build`).\n',
|
|
57
|
+
exitCode: 1,
|
|
58
|
+
};
|
|
59
|
+
}
|
|
60
|
+
const args = resolveArgs(ctx);
|
|
61
|
+
// Confirm kindgi.config.ts sits at the pack root — same shape
|
|
62
|
+
// kindgi dev / build use. Failing loud beats a cryptic vitest
|
|
63
|
+
// error later.
|
|
64
|
+
const configOk = await ensurePackConfig(args.packDir);
|
|
65
|
+
if (!configOk) {
|
|
66
|
+
return {
|
|
67
|
+
kind: 'error',
|
|
68
|
+
stderr: `kindgi test could not find a kindgi.config.ts at ${args.packDir}.\nRun \`kindgi init <pack-name>\` to scaffold a pack, or pass --path=<dir>.\n`,
|
|
69
|
+
exitCode: 1,
|
|
70
|
+
};
|
|
71
|
+
}
|
|
72
|
+
const hasConfig = await runners.hasVitestConfig({ packDir: args.packDir });
|
|
73
|
+
if (!hasConfig) {
|
|
74
|
+
return {
|
|
75
|
+
kind: 'error',
|
|
76
|
+
stderr: `kindgi test could not find a vitest config at ${args.packDir}.\nCreate one (e.g. \`vitest.config.ts\`) or \`cd\` into your pack root.\nThe two templates shipped with \`kindgi init\` ship one out of the box.\n`,
|
|
77
|
+
exitCode: 1,
|
|
78
|
+
};
|
|
79
|
+
}
|
|
80
|
+
const forwarded = buildForwardedArgs(args);
|
|
81
|
+
const banner = [
|
|
82
|
+
'',
|
|
83
|
+
` Running pack tests: ${args.packDir}`,
|
|
84
|
+
` Runner: vitest (via pack's local install)`,
|
|
85
|
+
` Mode: ${args.watch ? 'watch' : 'one-shot'}`,
|
|
86
|
+
...(args.reporter !== undefined ? [` Reporter: ${args.reporter}`] : []),
|
|
87
|
+
...(args.passthroughArgs.length > 0
|
|
88
|
+
? [` Pass-through args: ${args.passthroughArgs.join(' ')}`]
|
|
89
|
+
: []),
|
|
90
|
+
'',
|
|
91
|
+
];
|
|
92
|
+
const result = await runners.runTests({
|
|
93
|
+
packDir: args.packDir,
|
|
94
|
+
runner: 'vitest',
|
|
95
|
+
args: forwarded,
|
|
96
|
+
env: ctx.env,
|
|
97
|
+
...(ctx.stopSignal !== undefined && { signal: ctx.stopSignal }),
|
|
98
|
+
onLog: (chunk) => {
|
|
99
|
+
// Forward child output to stderr so JSON stdout stays clean.
|
|
100
|
+
process.stderr.write(chunk);
|
|
101
|
+
},
|
|
102
|
+
});
|
|
103
|
+
if (!result.spawned) {
|
|
104
|
+
if (result.reason === 'runner-binary-not-found') {
|
|
105
|
+
return {
|
|
106
|
+
kind: 'error',
|
|
107
|
+
stderr: 'kindgi test could not find the vitest binary. ' +
|
|
108
|
+
'Install it in your pack: `pnpm add -D vitest` (or `npm i -D vitest`).\n' +
|
|
109
|
+
`The CLI does NOT bundle vitest — it uses the pack's own install.\n`,
|
|
110
|
+
exitCode: 1,
|
|
111
|
+
};
|
|
112
|
+
}
|
|
113
|
+
return {
|
|
114
|
+
kind: 'error',
|
|
115
|
+
stderr: `kindgi test failed to spawn the vitest runner (${result.resolvedBinary ?? 'unknown'}). Check your pack's install (\`pnpm install\`) and re-run.\n`,
|
|
116
|
+
exitCode: 1,
|
|
117
|
+
};
|
|
118
|
+
}
|
|
119
|
+
const summary = {
|
|
120
|
+
packDir: args.packDir,
|
|
121
|
+
runner: 'vitest',
|
|
122
|
+
resolvedBinary: result.resolvedBinary,
|
|
123
|
+
watch: args.watch,
|
|
124
|
+
...(args.reporter !== undefined && { reporter: args.reporter }),
|
|
125
|
+
passthroughArgs: args.passthroughArgs,
|
|
126
|
+
exitCode: result.exitCode,
|
|
127
|
+
};
|
|
128
|
+
const rendered = renderJson(summary, ctx.globals.format);
|
|
129
|
+
const stderr = `${banner.join('\n')}\n`;
|
|
130
|
+
if (result.exitCode === 0) {
|
|
131
|
+
return { kind: 'ok', rendered: { stdout: rendered.stdout, stderr } };
|
|
132
|
+
}
|
|
133
|
+
return {
|
|
134
|
+
kind: 'ok',
|
|
135
|
+
exitCode: result.exitCode,
|
|
136
|
+
rendered: { stdout: rendered.stdout, stderr },
|
|
137
|
+
};
|
|
138
|
+
}
|
|
139
|
+
function resolveArgs(ctx) {
|
|
140
|
+
const pathFlag = ctx.options.path;
|
|
141
|
+
const rawPath = typeof pathFlag === 'string' && pathFlag !== '' ? pathFlag : ctx.cwd;
|
|
142
|
+
const packDir = isAbsolute(rawPath) ? rawPath : resolve(ctx.cwd, rawPath);
|
|
143
|
+
const watch = ctx.options.watch === true;
|
|
144
|
+
const reporterFlag = ctx.options.reporter;
|
|
145
|
+
const reporter = typeof reporterFlag === 'string' && reporterFlag !== '' ? reporterFlag : undefined;
|
|
146
|
+
// node:util.parseArgs surfaces tokens after `--` as regular
|
|
147
|
+
// positionals when `allowPositionals: true`. `kindgi test` treats
|
|
148
|
+
// every positional as a pass-through vitest arg — the command has
|
|
149
|
+
// no positional inputs of its own.
|
|
150
|
+
const passthroughArgs = ctx.positionals;
|
|
151
|
+
return { packDir, watch, reporter, passthroughArgs };
|
|
152
|
+
}
|
|
153
|
+
function buildForwardedArgs(args) {
|
|
154
|
+
const out = [];
|
|
155
|
+
// vitest defaults to watch=true when invoked without subcommand; the
|
|
156
|
+
// CLI's contract is one-shot unless `--watch` is set.
|
|
157
|
+
if (args.watch) {
|
|
158
|
+
out.push('--watch');
|
|
159
|
+
}
|
|
160
|
+
else {
|
|
161
|
+
out.push('run');
|
|
162
|
+
}
|
|
163
|
+
if (args.reporter !== undefined) {
|
|
164
|
+
out.push('--reporter', args.reporter);
|
|
165
|
+
}
|
|
166
|
+
out.push(...args.passthroughArgs);
|
|
167
|
+
return out;
|
|
168
|
+
}
|
|
169
|
+
async function ensurePackConfig(packDir) {
|
|
170
|
+
for (const c of KINDGI_CONFIG_FILENAMES) {
|
|
171
|
+
try {
|
|
172
|
+
await readFile(join(packDir, c), 'utf8');
|
|
173
|
+
return true;
|
|
174
|
+
}
|
|
175
|
+
catch {
|
|
176
|
+
// try next
|
|
177
|
+
}
|
|
178
|
+
}
|
|
179
|
+
return false;
|
|
180
|
+
}
|
|
181
|
+
//# sourceMappingURL=test.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"test.js","sourceRoot":"","sources":["../../src/commands/test.ts"],"names":[],"mappings":"AAAA,sCAAsC;AACtC,iCAAiC;AAEjC;;;;;;;;;;;;;;;;;;;;;GAqBG;AAEH,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAC5C,OAAO,EAAE,UAAU,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACtD,OAAO,EAAE,uBAAuB,EAAE,MAAM,yBAAyB,CAAC;AAGlE,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAG1C,MAAM,CAAC,MAAM,WAAW,GAAgB;IACtC,IAAI,EAAE,MAAM;IACZ,IAAI,EAAE,MAAM;IACZ,WAAW,EAAE,uEAAuE;IACpF,KAAK,EAAE,gFAAgF;IACvF,UAAU,EAAE;QACV,KAAK,EAAE;YACL,IAAI,EAAE,SAAS;YACf,WAAW,EAAE,yEAAyE;SACvF;QACD,QAAQ,EAAE;YACR,IAAI,EAAE,QAAQ;YACd,WAAW,EAAE,+EAA+E;SAC7F;QACD,IAAI,EAAE;YACJ,IAAI,EAAE,QAAQ;YACd,WAAW,EACT,+GAA+G;SAClH;KACF;IACD,GAAG,EAAE,KAAK,EAAE,GAAG,EAA0B,EAAE,CAAC,cAAc,CAAC,GAAG,CAAC;CAChE,CAAC;AAEF,MAAM,CAAC,KAAK,UAAU,cAAc,CAAC,GAAmB;IACtD,MAAM,OAAO,GAAG,GAAG,CAAC,WAAW,CAAC;IAChC,IAAI,OAAO,KAAK,SAAS,EAAE,CAAC;QAC1B,OAAO;YACL,IAAI,EAAE,OAAO;YACb,MAAM,EACJ,iEAAiE;gBACjE,wDAAwD;YAC1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C,WAAW,CAAC;IAExC,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,QAAQ,EAAE,eAAe,EAAE,CAAC;AACvD,CAAC;AAED,SAAS,kBAAkB,CAAC,IAAsB;IAChD,MAAM,GAAG,GAAa,EAAE,CAAC;IACzB,qEAAqE;IACrE,sDAAsD;IACtD,IAAI,IAAI,CAAC,KAAK,EAAE,CAAC;QACf,GAAG,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC;IACtB,CAAC;SAAM,CAAC;QACN,GAAG,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;IAClB,CAAC;IACD,IAAI,IAAI,CAAC,QAAQ,KAAK,SAAS,EAAE,CAAC;QAChC,GAAG,CAAC,IAAI,CAAC,YAAY,EAAE,IAAI,CAAC,QAAQ,CAAC,CAAC;IACxC,CAAC;IACD,GAAG,CAAC,IAAI,CAAC,GAAG,IAAI,CAAC,eAAe,CAAC,CAAC;IAClC,OAAO,GAAG,CAAC;AACb,CAAC;AAED,KAAK,UAAU,gBAAgB,CAAC,OAAe;IAC7C,KAAK,MAAM,CAAC,IAAI,uBAAuB,EAAE,CAAC;QACxC,IAAI,CAAC;YACH,MAAM,QAAQ,CAAC,IAAI,CAAC,OAAO,EAAE,CAAC,CAAC,EAAE,MAAM,CAAC,CAAC;YACzC,OAAO,IAAI,CAAC;QACd,CAAC;QAAC,MAAM,CAAC;YACP,WAAW;QACb,CAAC;IACH,CAAC;IACD,OAAO,KAAK,CAAC;AACf,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tokens.d.ts","sourceRoot":"","sources":["../../src/commands/tokens.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,OAAO,EAAe,MAAM,YAAY,CAAC;AA6BvD,eAAO,MAAM,aAAa,EAAE,OAK3B,CAAC"}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
// SPDX-License-Identifier: Apache-2.0
|
|
2
|
+
// Copyright (C) 2026 Kindgi Inc.
|
|
3
|
+
import { requiredPositional, runSdk, throwUnwired } from './helpers.js';
|
|
4
|
+
const create = {
|
|
5
|
+
kind: 'leaf',
|
|
6
|
+
name: 'create',
|
|
7
|
+
description: 'Create a new API token.',
|
|
8
|
+
usage: 'kindgi tokens create --spec=<json-or-@file>',
|
|
9
|
+
optionSpec: {
|
|
10
|
+
spec: {
|
|
11
|
+
type: 'string',
|
|
12
|
+
description: 'The token as inline JSON or `@<file>`, every field optional: `role` (`admin` or `member`, default `member`), `capabilities`, `label`, `expiresAt`, `projectId`.',
|
|
13
|
+
},
|
|
14
|
+
},
|
|
15
|
+
run: (ctx) => runSdk(ctx, 'tokens create', async () => throwUnwired('tokens.create')),
|
|
16
|
+
};
|
|
17
|
+
const revoke = {
|
|
18
|
+
kind: 'leaf',
|
|
19
|
+
name: 'revoke',
|
|
20
|
+
description: 'Revoke an API token.',
|
|
21
|
+
usage: 'kindgi tokens revoke <token-id>',
|
|
22
|
+
run: (ctx) => runSdk(ctx, 'tokens revoke', async () => {
|
|
23
|
+
requiredPositional(ctx, 0, 'token-id');
|
|
24
|
+
throwUnwired('tokens.revoke');
|
|
25
|
+
}),
|
|
26
|
+
};
|
|
27
|
+
export const tokensCommand = {
|
|
28
|
+
kind: 'group',
|
|
29
|
+
name: 'tokens',
|
|
30
|
+
description: 'Manage API tokens.',
|
|
31
|
+
subcommands: [create, revoke],
|
|
32
|
+
};
|
|
33
|
+
//# sourceMappingURL=tokens.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tokens.js","sourceRoot":"","sources":["../../src/commands/tokens.ts"],"names":[],"mappings":"AAAA,sCAAsC;AACtC,iCAAiC;AAEjC,OAAO,EAAE,kBAAkB,EAAE,MAAM,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AAGxE,MAAM,MAAM,GAAgB;IAC1B,IAAI,EAAE,MAAM;IACZ,IAAI,EAAE,QAAQ;IACd,WAAW,EAAE,yBAAyB;IACtC,KAAK,EAAE,6CAA6C;IACpD,UAAU,EAAE;QACV,IAAI,EAAE;YACJ,IAAI,EAAE,QAAQ;YACd,WAAW,EACT,iKAAiK;SACpK;KACF;IACD,GAAG,EAAE,CAAC,GAAG,EAAE,EAAE,CAAC,MAAM,CAAC,GAAG,EAAE,eAAe,EAAE,KAAK,IAAI,EAAE,CAAC,YAAY,CAAC,eAAe,CAAC,CAAC;CACtF,CAAC;AAEF,MAAM,MAAM,GAAgB;IAC1B,IAAI,EAAE,MAAM;IACZ,IAAI,EAAE,QAAQ;IACd,WAAW,EAAE,sBAAsB;IACnC,KAAK,EAAE,iCAAiC;IACxC,GAAG,EAAE,CAAC,GAAG,EAAE,EAAE,CACX,MAAM,CAAC,GAAG,EAAE,eAAe,EAAE,KAAK,IAAI,EAAE;QACtC,kBAAkB,CAAC,GAAG,EAAE,CAAC,EAAE,UAAU,CAAC,CAAC;QACvC,YAAY,CAAC,eAAe,CAAC,CAAC;IAChC,CAAC,CAAC;CACL,CAAC;AAEF,MAAM,CAAC,MAAM,aAAa,GAAY;IACpC,IAAI,EAAE,OAAO;IACb,IAAI,EAAE,QAAQ;IACd,WAAW,EAAE,oBAAoB;IACjC,WAAW,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC;CAC9B,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tools.d.ts","sourceRoot":"","sources":["../../src/commands/tools.ts"],"names":[],"mappings":"AAcA,OAAO,KAAK,EAAE,OAAO,EAAe,MAAM,YAAY,CAAC;AA2KvD,eAAO,MAAM,YAAY,EAAE,OAK1B,CAAC"}
|
|
@@ -0,0 +1,162 @@
|
|
|
1
|
+
// SPDX-License-Identifier: Apache-2.0
|
|
2
|
+
// Copyright (C) 2026 Kindgi Inc.
|
|
3
|
+
import { requiredPositional, runSdk, stringFlag, throwUnwired, truncateCell, } from './helpers.js';
|
|
4
|
+
/** `tools list --table`. */
|
|
5
|
+
const TOOLS_TABLE = {
|
|
6
|
+
rows: (page) => page.items,
|
|
7
|
+
columns: [
|
|
8
|
+
{ header: 'ID', get: (tool) => String(tool.id) },
|
|
9
|
+
{ header: 'VERSION', get: (tool) => tool.version ?? '' },
|
|
10
|
+
{ header: 'DESCRIPTION', get: (tool) => truncateCell(tool.description, 60) },
|
|
11
|
+
],
|
|
12
|
+
};
|
|
13
|
+
const list = {
|
|
14
|
+
kind: 'leaf',
|
|
15
|
+
name: 'list',
|
|
16
|
+
description: 'List registered tools.',
|
|
17
|
+
usage: 'kindgi tools list [--name=<prefix>] [--limit=<n>] [--cursor=<c>]',
|
|
18
|
+
optionSpec: {
|
|
19
|
+
name: { type: 'string', description: 'Only the tools whose id starts with this prefix.' },
|
|
20
|
+
limit: {
|
|
21
|
+
type: 'string',
|
|
22
|
+
description: 'The most tools to return (default 25, at most 100).',
|
|
23
|
+
},
|
|
24
|
+
cursor: {
|
|
25
|
+
type: 'string',
|
|
26
|
+
description: "Resume after this cursor, from the previous page's `nextCursor`.",
|
|
27
|
+
},
|
|
28
|
+
},
|
|
29
|
+
run: (ctx) => runSdk(ctx, 'tools list', async () => {
|
|
30
|
+
const name = stringFlag(ctx, 'name');
|
|
31
|
+
const cursor = stringFlag(ctx, 'cursor');
|
|
32
|
+
const limitStr = stringFlag(ctx, 'limit');
|
|
33
|
+
const limit = limitStr !== undefined ? Number.parseInt(limitStr, 10) : undefined;
|
|
34
|
+
if (limit !== undefined && Number.isNaN(limit)) {
|
|
35
|
+
throw new Error(`--limit must be an integer, got "${limitStr}"`);
|
|
36
|
+
}
|
|
37
|
+
return await ctx.client().tools.list({
|
|
38
|
+
...(name !== undefined && { name }),
|
|
39
|
+
...(cursor !== undefined && { cursor: cursor }),
|
|
40
|
+
...(limit !== undefined && { limit }),
|
|
41
|
+
});
|
|
42
|
+
}, TOOLS_TABLE),
|
|
43
|
+
};
|
|
44
|
+
const get = {
|
|
45
|
+
kind: 'leaf',
|
|
46
|
+
name: 'get',
|
|
47
|
+
description: 'Fetch the latest active version of a tool.',
|
|
48
|
+
usage: 'kindgi tools get <tool-id>',
|
|
49
|
+
run: (ctx) => runSdk(ctx, 'tools get', async () => {
|
|
50
|
+
const toolId = requiredPositional(ctx, 0, 'tool-id');
|
|
51
|
+
return await ctx.client().tools.get(toolId);
|
|
52
|
+
}),
|
|
53
|
+
};
|
|
54
|
+
const publish = {
|
|
55
|
+
kind: 'leaf',
|
|
56
|
+
name: 'publish',
|
|
57
|
+
description: 'Publish a tool manifest at a specific version.',
|
|
58
|
+
usage: 'kindgi tools publish --manifest=<json-or-@file>',
|
|
59
|
+
optionSpec: {
|
|
60
|
+
manifest: {
|
|
61
|
+
type: 'string',
|
|
62
|
+
description: 'The tool manifest as JSON, or `@<file>` to read it from a file. Required.',
|
|
63
|
+
},
|
|
64
|
+
},
|
|
65
|
+
run: (ctx) => runSdk(ctx, 'tools publish', async () => throwUnwired('tools.publish')),
|
|
66
|
+
};
|
|
67
|
+
const unregister = {
|
|
68
|
+
kind: 'leaf',
|
|
69
|
+
name: 'unregister',
|
|
70
|
+
description: 'Unregister a specific tool version.',
|
|
71
|
+
usage: 'kindgi tools unregister <tool-id> --version=<semver>',
|
|
72
|
+
optionSpec: {
|
|
73
|
+
version: {
|
|
74
|
+
type: 'string',
|
|
75
|
+
description: 'The version to unregister (semver); `kindgi tools reinstate` brings it back. Required.',
|
|
76
|
+
},
|
|
77
|
+
},
|
|
78
|
+
run: (ctx) => runSdk(ctx, 'tools unregister', async () => {
|
|
79
|
+
const toolId = requiredPositional(ctx, 0, 'tool-id');
|
|
80
|
+
const version = stringFlag(ctx, 'version');
|
|
81
|
+
if (version === undefined)
|
|
82
|
+
throw new Error('--version=<semver> is required');
|
|
83
|
+
return await ctx.client().tools.unregisterVersion(toolId, version);
|
|
84
|
+
}),
|
|
85
|
+
};
|
|
86
|
+
const versions = {
|
|
87
|
+
kind: 'leaf',
|
|
88
|
+
name: 'versions',
|
|
89
|
+
description: 'List published versions of a tool (active + optionally tombstoned).',
|
|
90
|
+
usage: 'kindgi tools versions <tool-id> [--include-tombstoned] [--limit=<n>] [--cursor=<c>]',
|
|
91
|
+
optionSpec: {
|
|
92
|
+
'include-tombstoned': {
|
|
93
|
+
type: 'boolean',
|
|
94
|
+
description: 'Include unregistered versions too, each with its `unregisteredAt`.',
|
|
95
|
+
},
|
|
96
|
+
limit: {
|
|
97
|
+
type: 'string',
|
|
98
|
+
description: 'The most versions to return (default 25, at most 100).',
|
|
99
|
+
},
|
|
100
|
+
cursor: {
|
|
101
|
+
type: 'string',
|
|
102
|
+
description: "Resume after this cursor, from the previous page's `nextCursor`.",
|
|
103
|
+
},
|
|
104
|
+
},
|
|
105
|
+
run: (ctx) => runSdk(ctx, 'tools versions', async () => {
|
|
106
|
+
const toolId = requiredPositional(ctx, 0, 'tool-id');
|
|
107
|
+
const cursor = stringFlag(ctx, 'cursor');
|
|
108
|
+
const limitStr = stringFlag(ctx, 'limit');
|
|
109
|
+
const limit = limitStr !== undefined ? Number.parseInt(limitStr, 10) : undefined;
|
|
110
|
+
if (limit !== undefined && Number.isNaN(limit)) {
|
|
111
|
+
throw new Error(`--limit must be an integer, got "${limitStr}"`);
|
|
112
|
+
}
|
|
113
|
+
const includeTombstoned = ctx.options['include-tombstoned'] === true;
|
|
114
|
+
return await ctx.client().tools.listVersions(toolId, {
|
|
115
|
+
...(cursor !== undefined && { cursor: cursor }),
|
|
116
|
+
...(limit !== undefined && { limit }),
|
|
117
|
+
...(includeTombstoned && { includeTombstoned: true }),
|
|
118
|
+
});
|
|
119
|
+
}),
|
|
120
|
+
};
|
|
121
|
+
const getVersion = {
|
|
122
|
+
kind: 'leaf',
|
|
123
|
+
name: 'get-version',
|
|
124
|
+
description: 'Fetch a specific tool version by exact semver.',
|
|
125
|
+
usage: 'kindgi tools get-version <tool-id> --version=<semver>',
|
|
126
|
+
optionSpec: {
|
|
127
|
+
version: { type: 'string', description: 'The exact version to fetch (semver). Required.' },
|
|
128
|
+
},
|
|
129
|
+
run: (ctx) => runSdk(ctx, 'tools get-version', async () => {
|
|
130
|
+
const toolId = requiredPositional(ctx, 0, 'tool-id');
|
|
131
|
+
const version = stringFlag(ctx, 'version');
|
|
132
|
+
if (version === undefined)
|
|
133
|
+
throw new Error('--version=<semver> is required');
|
|
134
|
+
return await ctx.client().tools.getVersion(toolId, version);
|
|
135
|
+
}),
|
|
136
|
+
};
|
|
137
|
+
const reinstate = {
|
|
138
|
+
kind: 'leaf',
|
|
139
|
+
name: 'reinstate',
|
|
140
|
+
description: 'Un-tombstone a specific tool version.',
|
|
141
|
+
usage: 'kindgi tools reinstate <tool-id> --version=<semver>',
|
|
142
|
+
optionSpec: {
|
|
143
|
+
version: {
|
|
144
|
+
type: 'string',
|
|
145
|
+
description: 'The unregistered version to bring back (semver). Required.',
|
|
146
|
+
},
|
|
147
|
+
},
|
|
148
|
+
run: (ctx) => runSdk(ctx, 'tools reinstate', async () => {
|
|
149
|
+
const toolId = requiredPositional(ctx, 0, 'tool-id');
|
|
150
|
+
const version = stringFlag(ctx, 'version');
|
|
151
|
+
if (version === undefined)
|
|
152
|
+
throw new Error('--version=<semver> is required');
|
|
153
|
+
return await ctx.client().tools.reinstateVersion(toolId, version);
|
|
154
|
+
}),
|
|
155
|
+
};
|
|
156
|
+
export const toolsCommand = {
|
|
157
|
+
kind: 'group',
|
|
158
|
+
name: 'tools',
|
|
159
|
+
description: 'Manage tool registrations.',
|
|
160
|
+
subcommands: [list, get, publish, unregister, versions, getVersion, reinstate],
|
|
161
|
+
};
|
|
162
|
+
//# sourceMappingURL=tools.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tools.js","sourceRoot":"","sources":["../../src/commands/tools.ts"],"names":[],"mappings":"AAAA,sCAAsC;AACtC,iCAAiC;AAKjC,OAAO,EAEL,kBAAkB,EAClB,MAAM,EACN,UAAU,EACV,YAAY,EACZ,YAAY,GACb,MAAM,cAAc,CAAC;AAGtB,4BAA4B;AAC5B,MAAM,WAAW,GAAgC;IAC/C,IAAI,EAAE,CAAC,I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BAA4B;IACzC,WAAW,EAAE,CAAC,IAAI,EAAE,GAAG,EAAE,OAAO,EAAE,UAAU,EAAE,QAAQ,EAAE,UAAU,EAAE,SAAS,CAAC;CAC/E,CAAC"}
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import type { CommandContext } from '../context.js';
|
|
2
|
+
import type { Rendered } from '../output.js';
|
|
3
|
+
/**
|
|
4
|
+
* A leaf command handler. Returns either a rendered success payload or
|
|
5
|
+
* a rendered error. The dispatcher writes stdout/stderr and picks an
|
|
6
|
+
* exit code accordingly.
|
|
7
|
+
*/
|
|
8
|
+
export type CommandResult = {
|
|
9
|
+
readonly kind: 'ok';
|
|
10
|
+
readonly rendered: Rendered;
|
|
11
|
+
readonly exitCode?: number;
|
|
12
|
+
} | {
|
|
13
|
+
readonly kind: 'error';
|
|
14
|
+
readonly stderr: string;
|
|
15
|
+
readonly exitCode: number;
|
|
16
|
+
};
|
|
17
|
+
export interface LeafCommand {
|
|
18
|
+
readonly kind: 'leaf';
|
|
19
|
+
readonly name: string;
|
|
20
|
+
readonly description: string;
|
|
21
|
+
readonly usage: string;
|
|
22
|
+
/** Option spec merged with the global spec by the parser. */
|
|
23
|
+
readonly optionSpec?: Readonly<Record<string, ParseArgsOption>>;
|
|
24
|
+
readonly run: (ctx: CommandContext) => Promise<CommandResult>;
|
|
25
|
+
}
|
|
26
|
+
export interface GroupCommand {
|
|
27
|
+
readonly kind: 'group';
|
|
28
|
+
readonly name: string;
|
|
29
|
+
readonly description: string;
|
|
30
|
+
readonly subcommands: readonly Command[];
|
|
31
|
+
}
|
|
32
|
+
export type Command = LeafCommand | GroupCommand;
|
|
33
|
+
export type ParseArgsOption = {
|
|
34
|
+
type: 'string';
|
|
35
|
+
multiple?: boolean;
|
|
36
|
+
short?: string;
|
|
37
|
+
default?: string;
|
|
38
|
+
/** What the flag does, in one sentence: `--help` and the docs show it. */
|
|
39
|
+
description?: string;
|
|
40
|
+
/**
|
|
41
|
+
* The value may be left out (`--push`, or `--push` before another
|
|
42
|
+
* flag): the option is then `''`. Given, it's the next token or
|
|
43
|
+
* `--push=<value>`.
|
|
44
|
+
*/
|
|
45
|
+
optionalValue?: boolean;
|
|
46
|
+
} | {
|
|
47
|
+
type: 'boolean';
|
|
48
|
+
multiple?: boolean;
|
|
49
|
+
short?: string;
|
|
50
|
+
default?: boolean;
|
|
51
|
+
/** What the flag does, in one sentence: `--help` and the docs show it. */
|
|
52
|
+
description?: string;
|
|
53
|
+
};
|
|
54
|
+
//# sourceMappingURL=types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/commands/types.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,eAAe,CAAC;AACpD,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,cAAc,CAAC;AAE7C;;;;GAIG;AACH,MAAM,MAAM,aAAa,GACrB;IAAE,QAAQ,CAAC,IAAI,EAAE,IAAI,CAAC;IAAC,QAAQ,CAAC,QAAQ,EAAE,QAAQ,CAAC;IAAC,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAA;CAAE,GAChF;IAAE,QAAQ,CAAC,IAAI,EAAE,OAAO,CAAC;IAAC,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAA;CAAE,CAAC;AAEnF,MAAM,WAAW,WAAW;IAC1B,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAC;IAC7B,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IACvB,6DAA6D;IAC7D,QAAQ,CAAC,UAAU,CAAC,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,eAAe,CAAC,CAAC,CAAC;IAChE,QAAQ,CAAC,GAAG,EAAE,CAAC,GAAG,EAAE,cAAc,KAAK,OAAO,CAAC,aAAa,CAAC,CAAC;CAC/D;AAED,MAAM,WAAW,YAAY;IAC3B,QAAQ,CAAC,IAAI,EAAE,OAAO,CAAC;IACvB,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAC;IAC7B,QAAQ,CAAC,WAAW,EAAE,SAAS,OAAO,EAAE,CAAC;CAC1C;AAED,MAAM,MAAM,OAAO,GAAG,WAAW,GAAG,YAAY,CAAC;AAEjD,MAAM,MAAM,eAAe,GACvB;IACE,IAAI,EAAE,QAAQ,CAAC;IACf,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,0EAA0E;IAC1E,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB;;;;OAIG;IACH,aAAa,CAAC,EAAE,OAAO,CAAC;CACzB,GACD;IACE,IAAI,EAAE,SAAS,CAAC;IAChB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,0EAA0E;IAC1E,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/commands/types.ts"],"names":[],"mappings":"AAAA,sCAAsC;AACtC,iCAAiC"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import type { Command } from './types.js';
|
|
2
|
+
/**
|
|
3
|
+
* Commands whose API this release doesn't wire yet: they call
|
|
4
|
+
* `throwUnwired` and fail with "not yet wired". They stay callable, so a
|
|
5
|
+
* script gets an honest error rather than "unknown command", but `--help`
|
|
6
|
+
* and the generated reference leave them out until they work.
|
|
7
|
+
*
|
|
8
|
+
* A path is the command words (`'agents list'`); a group's path hides the
|
|
9
|
+
* whole group. Wiring a command means removing it here (a test counts the
|
|
10
|
+
* `throwUnwired` call sites against this list).
|
|
11
|
+
*/
|
|
12
|
+
export declare const UNWIRED_COMMANDS: ReadonlySet<string>;
|
|
13
|
+
/**
|
|
14
|
+
* Why a listed command isn't available, when the reason isn't simply "not
|
|
15
|
+
* wired yet": what the CLI prints instead of the generic message.
|
|
16
|
+
*/
|
|
17
|
+
export declare const UNWIRED_REASONS: ReadonlyMap<string, string>;
|
|
18
|
+
/** Whether the command at `path` (its words, from the root) is wired. */
|
|
19
|
+
export declare function isWired(path: readonly string[]): boolean;
|
|
20
|
+
/** The commands under `parent` (its words) that are wired, in order. */
|
|
21
|
+
export declare function wiredCommands(commands: readonly Command[], parent?: readonly string[]): readonly Command[];
|
|
22
|
+
//# sourceMappingURL=unwired.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"unwired.d.ts","sourceRoot":"","sources":["../../src/commands/unwired.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,YAAY,CAAC;AAE1C;;;;;;;;;GASG;AACH,eAAO,MAAM,gBAAgB,EAAE,WAAW,CAAC,MAAM,CAgB/C,CAAC;AAEH;;;GAGG;AACH,eAAO,MAAM,eAAe,EAAE,WAAW,CAAC,MAAM,EAAE,MAAM,CAKtD,CAAC;AAEH,yEAAyE;AACzE,wBAAgB,OAAO,CAAC,IAAI,EAAE,SAAS,MAAM,EAAE,GAAG,OAAO,CAKxD;AAED,wEAAwE;AACxE,wBAAgB,aAAa,CAC3B,QAAQ,EAAE,SAAS,OAAO,EAAE,EAC5B,MAAM,GAAE,SAAS,MAAM,EAAO,GAC7B,SAAS,OAAO,EAAE,CAEpB"}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
// SPDX-License-Identifier: Apache-2.0
|
|
2
|
+
// Copyright (C) 2026 Kindgi Inc.
|
|
3
|
+
/**
|
|
4
|
+
* Commands whose API this release doesn't wire yet: they call
|
|
5
|
+
* `throwUnwired` and fail with "not yet wired". They stay callable, so a
|
|
6
|
+
* script gets an honest error rather than "unknown command", but `--help`
|
|
7
|
+
* and the generated reference leave them out until they work.
|
|
8
|
+
*
|
|
9
|
+
* A path is the command words (`'agents list'`); a group's path hides the
|
|
10
|
+
* whole group. Wiring a command means removing it here (a test counts the
|
|
11
|
+
* `throwUnwired` call sites against this list).
|
|
12
|
+
*/
|
|
13
|
+
export const UNWIRED_COMMANDS = new Set([
|
|
14
|
+
'artifacts',
|
|
15
|
+
'capabilities',
|
|
16
|
+
'conversations',
|
|
17
|
+
'flows',
|
|
18
|
+
'memory',
|
|
19
|
+
'observations',
|
|
20
|
+
'proposals',
|
|
21
|
+
'provenance',
|
|
22
|
+
'tokens',
|
|
23
|
+
'agents list',
|
|
24
|
+
'agents get',
|
|
25
|
+
'agents unregister',
|
|
26
|
+
'agents versions',
|
|
27
|
+
'tools publish',
|
|
28
|
+
'runs resume',
|
|
29
|
+
]);
|
|
30
|
+
/**
|
|
31
|
+
* Why a listed command isn't available, when the reason isn't simply "not
|
|
32
|
+
* wired yet": what the CLI prints instead of the generic message.
|
|
33
|
+
*/
|
|
34
|
+
export const UNWIRED_REASONS = new Map([
|
|
35
|
+
[
|
|
36
|
+
'runs resume',
|
|
37
|
+
'resuming a run at a waitpoint is not available in this release: every waitpoint belongs to an approval or to the runtime. A run waiting for an approval continues when a reviewer decides it: `kindgi approvals complete <approval-id> --decision=approve`.',
|
|
38
|
+
],
|
|
39
|
+
]);
|
|
40
|
+
/** Whether the command at `path` (its words, from the root) is wired. */
|
|
41
|
+
export function isWired(path) {
|
|
42
|
+
for (let i = 1; i <= path.length; i += 1) {
|
|
43
|
+
if (UNWIRED_COMMANDS.has(path.slice(0, i).join(' ')))
|
|
44
|
+
return false;
|
|
45
|
+
}
|
|
46
|
+
return true;
|
|
47
|
+
}
|
|
48
|
+
/** The commands under `parent` (its words) that are wired, in order. */
|
|
49
|
+
export function wiredCommands(commands, parent = []) {
|
|
50
|
+
return commands.filter((command) => isWired([...parent, command.name]));
|
|
51
|
+
}
|
|
52
|
+
//# sourceMappingURL=unwired.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"unwired.js","sourceRoot":"","sources":["../../src/commands/unwired.ts"],"names":[],"mappings":"AAAA,sCAAsC;AACtC,iCAAiC;AAIjC;;;;;;;;;GASG;AACH,MAAM,CAAC,MAAM,gBAAgB,GAAwB,IAAI,GAAG,CAAC;IAC3D,WAAW;IACX,cAAc;IACd,eAAe;IACf,OAAO;IACP,QAAQ;IACR,cAAc;IACd,WAAW;IACX,YAAY;IACZ,QAAQ;IACR,aAAa;IACb,YAAY;IACZ,mBAAmB;IACnB,iBAAiB;IACjB,eAAe;IACf,aAAa;CACd,CAAC,CAAC;AAEH;;;GAGG;AACH,MAAM,CAAC,MAAM,eAAe,GAAgC,IAAI,GAAG,CAAC;IAClE;QACE,aAAa;QACb,6PAA6P;KAC9P;CACF,CAAC,CAAC;AAEH,yEAAyE;AACzE,MAAM,UAAU,OAAO,CAAC,IAAuB;IAC7C,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,IAAI,IAAI,CAAC,MAAM,EAAE,CAAC,IAAI,CAAC,EAAE,CAAC;QACzC,IAAI,gBAAgB,CAAC,GAAG,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;YAAE,OAAO,KAAK,CAAC;IACrE,CAAC;IACD,OAAO,IAAI,CAAC;AACd,CAAC;AAED,wEAAwE;AACxE,MAAM,UAAU,aAAa,CAC3B,QAA4B,EAC5B,SAA4B,EAAE;IAE9B,OAAO,QAAQ,CAAC,MAAM,CAAC,CAAC,OAAO,EAAE,EAAE,CAAC,OAAO,CAAC,CAAC,GAAG,MAAM,EAAE,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;AAC1E,CAAC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { LeafCommand } from './types.js';
|
|
2
|
+
/**
|
|
3
|
+
* Print CLI + SDK versions, plus (if the API is reachable) the server's
|
|
4
|
+
* OpenAPI info block. Never requires an auth token — `/v1/openapi.json`
|
|
5
|
+
* is public.
|
|
6
|
+
*/
|
|
7
|
+
export declare const versionCommand: LeafCommand;
|
|
8
|
+
//# sourceMappingURL=version.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"version.d.ts","sourceRoot":"","sources":["../../src/commands/version.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAiB,WAAW,EAAE,MAAM,YAAY,CAAC;AAE7D;;;;GAIG;AACH,eAAO,MAAM,cAAc,EAAE,WAiC5B,CAAC"}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
// SPDX-License-Identifier: Apache-2.0
|
|
2
|
+
// Copyright (C) 2026 Kindgi Inc.
|
|
3
|
+
import { renderJson } from '../output.js';
|
|
4
|
+
import { CLI_VERSION, SDK_VERSION } from '../version-info.js';
|
|
5
|
+
/**
|
|
6
|
+
* Print CLI + SDK versions, plus (if the API is reachable) the server's
|
|
7
|
+
* OpenAPI info block. Never requires an auth token — `/v1/openapi.json`
|
|
8
|
+
* is public.
|
|
9
|
+
*/
|
|
10
|
+
export const versionCommand = {
|
|
11
|
+
kind: 'leaf',
|
|
12
|
+
name: 'version',
|
|
13
|
+
description: 'Print CLI + SDK versions (and API version if reachable).',
|
|
14
|
+
usage: 'kindgi version',
|
|
15
|
+
run: async (ctx) => {
|
|
16
|
+
const info = {
|
|
17
|
+
cli: CLI_VERSION,
|
|
18
|
+
sdk: SDK_VERSION,
|
|
19
|
+
};
|
|
20
|
+
if (ctx.config.apiUrl !== undefined) {
|
|
21
|
+
info.apiUrl = ctx.config.apiUrl;
|
|
22
|
+
try {
|
|
23
|
+
const url = `${ctx.config.apiUrl.replace(/\/+$/, '')}/v1/openapi.json`;
|
|
24
|
+
const res = await ctx.fetch(url, { method: 'GET' });
|
|
25
|
+
if (res.ok) {
|
|
26
|
+
const body = (await res.json());
|
|
27
|
+
if (body.info !== undefined)
|
|
28
|
+
info.api = body.info;
|
|
29
|
+
}
|
|
30
|
+
else {
|
|
31
|
+
info.apiUnreachable = `HTTP ${res.status}`;
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
catch (err) {
|
|
35
|
+
info.apiUnreachable = err.message;
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
return { kind: 'ok', rendered: renderJson(info, ctx.globals.format) };
|
|
39
|
+
},
|
|
40
|
+
};
|
|
41
|
+
//# sourceMappingURL=version.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"version.js","sourceRoot":"","sources":["../../src/commands/version.ts"],"names":[],"mappings":"AAAA,sCAAsC;AACtC,iCAAiC;AAEjC,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,WAAW,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AAG9D;;;;GAIG;AACH,MAAM,CAAC,MAAM,cAAc,GAAgB;IACzC,IAAI,EAAE,MAAM;IACZ,IAAI,EAAE,SAAS;IACf,WAAW,EAAE,0DAA0D;IACvE,KAAK,EAAE,gBAAgB;IACvB,GAAG,EAAE,KAAK,EAAE,GAAG,EAA0B,EAAE;QACzC,MAAM,IAAI,GAMN;YACF,GAAG,EAAE,WAAW;YAChB,GAAG,EAAE,WAAW;SACjB,CAAC;QACF,IAAI,GAAG,CAAC,MAAM,CAAC,MAAM,KAAK,SAAS,EAAE,CAAC;YACpC,IAAI,CAAC,MAAM,GAAG,GAAG,CAAC,MAAM,CAAC,MAAM,CAAC;YAChC,IAAI,CAAC;gBACH,MAAM,GAAG,GAAG,GAAG,GAAG,CAAC,MAAM,CAAC,MAAM,CAAC,OAAO,CAAC,MAAM,EAAE,EAAE,CAAC,kBAAkB,CAAC;gBACvE,MAAM,GAAG,GAAG,MAAM,GAAG,CAAC,KA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