@specforge/mcp 2.0.9 → 2.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +324 -0
- package/bin/specforge-mcp +19 -1
- package/dist/cli/commands/blocked.d.ts +16 -0
- package/dist/cli/commands/blocked.d.ts.map +1 -0
- package/dist/cli/commands/blocked.js +214 -0
- package/dist/cli/commands/blocked.js.map +1 -0
- package/dist/cli/commands/configure.d.ts +16 -0
- package/dist/cli/commands/configure.d.ts.map +1 -0
- package/dist/cli/commands/configure.js +218 -0
- package/dist/cli/commands/configure.js.map +1 -0
- package/dist/cli/commands/configure.types.d.ts +110 -0
- package/dist/cli/commands/configure.types.d.ts.map +1 -0
- package/dist/cli/commands/configure.types.js +105 -0
- package/dist/cli/commands/configure.types.js.map +1 -0
- package/dist/cli/commands/debug/call.d.ts +14 -0
- package/dist/cli/commands/debug/call.d.ts.map +1 -0
- package/dist/cli/commands/debug/call.js +117 -0
- package/dist/cli/commands/debug/call.js.map +1 -0
- package/dist/cli/commands/debug/index.d.ts +12 -0
- package/dist/cli/commands/debug/index.d.ts.map +1 -0
- package/dist/cli/commands/debug/index.js +12 -0
- package/dist/cli/commands/debug/index.js.map +1 -0
- package/dist/cli/commands/debug/register.d.ts +11 -0
- package/dist/cli/commands/debug/register.d.ts.map +1 -0
- package/dist/cli/commands/debug/register.js +90 -0
- package/dist/cli/commands/debug/register.js.map +1 -0
- package/dist/cli/commands/debug/test.d.ts +13 -0
- package/dist/cli/commands/debug/test.d.ts.map +1 -0
- package/dist/cli/commands/debug/test.js +117 -0
- package/dist/cli/commands/debug/test.js.map +1 -0
- package/dist/cli/commands/debug/tools.d.ts +13 -0
- package/dist/cli/commands/debug/tools.d.ts.map +1 -0
- package/dist/cli/commands/debug/tools.js +117 -0
- package/dist/cli/commands/debug/tools.js.map +1 -0
- package/dist/cli/commands/debug/types.d.ts +117 -0
- package/dist/cli/commands/debug/types.d.ts.map +1 -0
- package/dist/cli/commands/debug/types.js +43 -0
- package/dist/cli/commands/debug/types.js.map +1 -0
- package/dist/cli/commands/debug/whoami.d.ts +13 -0
- package/dist/cli/commands/debug/whoami.d.ts.map +1 -0
- package/dist/cli/commands/debug/whoami.js +161 -0
- package/dist/cli/commands/debug/whoami.js.map +1 -0
- package/dist/cli/commands/docs/content/api.d.ts +7 -0
- package/dist/cli/commands/docs/content/api.d.ts.map +1 -0
- package/dist/cli/commands/docs/content/api.js +64 -0
- package/dist/cli/commands/docs/content/api.js.map +1 -0
- package/dist/cli/commands/docs/content/concepts.d.ts +7 -0
- package/dist/cli/commands/docs/content/concepts.d.ts.map +1 -0
- package/dist/cli/commands/docs/content/concepts.js +68 -0
- package/dist/cli/commands/docs/content/concepts.js.map +1 -0
- package/dist/cli/commands/docs/content/examples.d.ts +7 -0
- package/dist/cli/commands/docs/content/examples.d.ts.map +1 -0
- package/dist/cli/commands/docs/content/examples.js +84 -0
- package/dist/cli/commands/docs/content/examples.js.map +1 -0
- package/dist/cli/commands/docs/content/index.d.ts +10 -0
- package/dist/cli/commands/docs/content/index.d.ts.map +1 -0
- package/dist/cli/commands/docs/content/index.js +10 -0
- package/dist/cli/commands/docs/content/index.js.map +1 -0
- package/dist/cli/commands/docs/content/workflow.d.ts +7 -0
- package/dist/cli/commands/docs/content/workflow.d.ts.map +1 -0
- package/dist/cli/commands/docs/content/workflow.js +44 -0
- package/dist/cli/commands/docs/content/workflow.js.map +1 -0
- package/dist/cli/commands/docs/content.d.ts +23 -0
- package/dist/cli/commands/docs/content.d.ts.map +1 -0
- package/dist/cli/commands/docs/content.js +38 -0
- package/dist/cli/commands/docs/content.js.map +1 -0
- package/dist/cli/commands/docs/display.d.ts +26 -0
- package/dist/cli/commands/docs/display.d.ts.map +1 -0
- package/dist/cli/commands/docs/display.js +53 -0
- package/dist/cli/commands/docs/display.js.map +1 -0
- package/dist/cli/commands/docs/docs.d.ts +19 -0
- package/dist/cli/commands/docs/docs.d.ts.map +1 -0
- package/dist/cli/commands/docs/docs.js +124 -0
- package/dist/cli/commands/docs/docs.js.map +1 -0
- package/dist/cli/commands/docs/index.d.ts +13 -0
- package/dist/cli/commands/docs/index.d.ts.map +1 -0
- package/dist/cli/commands/docs/index.js +13 -0
- package/dist/cli/commands/docs/index.js.map +1 -0
- package/dist/cli/commands/docs/register.d.ts +23 -0
- package/dist/cli/commands/docs/register.d.ts.map +1 -0
- package/dist/cli/commands/docs/register.js +64 -0
- package/dist/cli/commands/docs/register.js.map +1 -0
- package/dist/cli/commands/docs/tool-docs.d.ts +44 -0
- package/dist/cli/commands/docs/tool-docs.d.ts.map +1 -0
- package/dist/cli/commands/docs/tool-docs.js +182 -0
- package/dist/cli/commands/docs/tool-docs.js.map +1 -0
- package/dist/cli/commands/docs/tool-examples.d.ts +14 -0
- package/dist/cli/commands/docs/tool-examples.d.ts.map +1 -0
- package/dist/cli/commands/docs/tool-examples.js +127 -0
- package/dist/cli/commands/docs/tool-examples.js.map +1 -0
- package/dist/cli/commands/docs/types.d.ts +108 -0
- package/dist/cli/commands/docs/types.d.ts.map +1 -0
- package/dist/cli/commands/docs/types.js +33 -0
- package/dist/cli/commands/docs/types.js.map +1 -0
- package/dist/cli/commands/doctor.d.ts +16 -0
- package/dist/cli/commands/doctor.d.ts.map +1 -0
- package/dist/cli/commands/doctor.js +322 -0
- package/dist/cli/commands/doctor.js.map +1 -0
- package/dist/cli/commands/doctor.types.d.ts +177 -0
- package/dist/cli/commands/doctor.types.d.ts.map +1 -0
- package/dist/cli/commands/doctor.types.js +172 -0
- package/dist/cli/commands/doctor.types.js.map +1 -0
- package/dist/cli/commands/index.d.ts +18 -0
- package/dist/cli/commands/index.d.ts.map +1 -0
- package/dist/cli/commands/index.js +18 -0
- package/dist/cli/commands/index.js.map +1 -0
- package/dist/cli/commands/init.d.ts +17 -0
- package/dist/cli/commands/init.d.ts.map +1 -0
- package/dist/cli/commands/init.js +326 -0
- package/dist/cli/commands/init.js.map +1 -0
- package/dist/cli/commands/init.types.d.ts +141 -0
- package/dist/cli/commands/init.types.d.ts.map +1 -0
- package/dist/cli/commands/init.types.js +24 -0
- package/dist/cli/commands/init.types.js.map +1 -0
- package/dist/cli/commands/login.d.ts +40 -0
- package/dist/cli/commands/login.d.ts.map +1 -0
- package/dist/cli/commands/login.js +174 -0
- package/dist/cli/commands/login.js.map +1 -0
- package/dist/cli/commands/next.d.ts +16 -0
- package/dist/cli/commands/next.d.ts.map +1 -0
- package/dist/cli/commands/next.js +279 -0
- package/dist/cli/commands/next.js.map +1 -0
- package/dist/cli/commands/next.types.d.ts +191 -0
- package/dist/cli/commands/next.types.d.ts.map +1 -0
- package/dist/cli/commands/next.types.js +129 -0
- package/dist/cli/commands/next.types.js.map +1 -0
- package/dist/cli/commands/projects.d.ts +16 -0
- package/dist/cli/commands/projects.d.ts.map +1 -0
- package/dist/cli/commands/projects.js +149 -0
- package/dist/cli/commands/projects.js.map +1 -0
- package/dist/cli/commands/projects.types.d.ts +81 -0
- package/dist/cli/commands/projects.types.d.ts.map +1 -0
- package/dist/cli/commands/projects.types.js +35 -0
- package/dist/cli/commands/projects.types.js.map +1 -0
- package/dist/cli/commands/review/display.d.ts +33 -0
- package/dist/cli/commands/review/display.d.ts.map +1 -0
- package/dist/cli/commands/review/display.js +159 -0
- package/dist/cli/commands/review/display.js.map +1 -0
- package/dist/cli/commands/review/epic-review.d.ts +13 -0
- package/dist/cli/commands/review/epic-review.d.ts.map +1 -0
- package/dist/cli/commands/review/epic-review.js +69 -0
- package/dist/cli/commands/review/epic-review.js.map +1 -0
- package/dist/cli/commands/review/index.d.ts +13 -0
- package/dist/cli/commands/review/index.d.ts.map +1 -0
- package/dist/cli/commands/review/index.js +17 -0
- package/dist/cli/commands/review/index.js.map +1 -0
- package/dist/cli/commands/review/report.d.ts +31 -0
- package/dist/cli/commands/review/report.d.ts.map +1 -0
- package/dist/cli/commands/review/report.js +146 -0
- package/dist/cli/commands/review/report.js.map +1 -0
- package/dist/cli/commands/review/review.d.ts +17 -0
- package/dist/cli/commands/review/review.d.ts.map +1 -0
- package/dist/cli/commands/review/review.js +129 -0
- package/dist/cli/commands/review/review.js.map +1 -0
- package/dist/cli/commands/review/spec-review.d.ts +13 -0
- package/dist/cli/commands/review/spec-review.d.ts.map +1 -0
- package/dist/cli/commands/review/spec-review.js +65 -0
- package/dist/cli/commands/review/spec-review.js.map +1 -0
- package/dist/cli/commands/review/ticket-review.d.ts +37 -0
- package/dist/cli/commands/review/ticket-review.d.ts.map +1 -0
- package/dist/cli/commands/review/ticket-review.js +194 -0
- package/dist/cli/commands/review/ticket-review.js.map +1 -0
- package/dist/cli/commands/review/types.d.ts +232 -0
- package/dist/cli/commands/review/types.d.ts.map +1 -0
- package/dist/cli/commands/review/types.js +85 -0
- package/dist/cli/commands/review/types.js.map +1 -0
- package/dist/cli/commands/scaffold/display.d.ts +27 -0
- package/dist/cli/commands/scaffold/display.d.ts.map +1 -0
- package/dist/cli/commands/scaffold/display.js +90 -0
- package/dist/cli/commands/scaffold/display.js.map +1 -0
- package/dist/cli/commands/scaffold/index.d.ts +12 -0
- package/dist/cli/commands/scaffold/index.d.ts.map +1 -0
- package/dist/cli/commands/scaffold/index.js +12 -0
- package/dist/cli/commands/scaffold/index.js.map +1 -0
- package/dist/cli/commands/scaffold/register.d.ts +11 -0
- package/dist/cli/commands/scaffold/register.d.ts.map +1 -0
- package/dist/cli/commands/scaffold/register.js +25 -0
- package/dist/cli/commands/scaffold/register.js.map +1 -0
- package/dist/cli/commands/scaffold/scaffold.d.ts +11 -0
- package/dist/cli/commands/scaffold/scaffold.d.ts.map +1 -0
- package/dist/cli/commands/scaffold/scaffold.js +111 -0
- package/dist/cli/commands/scaffold/scaffold.js.map +1 -0
- package/dist/cli/commands/scaffold/targets.d.ts +31 -0
- package/dist/cli/commands/scaffold/targets.d.ts.map +1 -0
- package/dist/cli/commands/scaffold/targets.js +84 -0
- package/dist/cli/commands/scaffold/targets.js.map +1 -0
- package/dist/cli/commands/scaffold/types.d.ts +88 -0
- package/dist/cli/commands/scaffold/types.d.ts.map +1 -0
- package/dist/cli/commands/scaffold/types.js +21 -0
- package/dist/cli/commands/scaffold/types.js.map +1 -0
- package/dist/cli/commands/scaffold/utils.d.ts +31 -0
- package/dist/cli/commands/scaffold/utils.d.ts.map +1 -0
- package/dist/cli/commands/scaffold/utils.js +71 -0
- package/dist/cli/commands/scaffold/utils.js.map +1 -0
- package/dist/cli/commands/session/display.d.ts +40 -0
- package/dist/cli/commands/session/display.d.ts.map +1 -0
- package/dist/cli/commands/session/display.js +114 -0
- package/dist/cli/commands/session/display.js.map +1 -0
- package/dist/cli/commands/session/end.d.ts +12 -0
- package/dist/cli/commands/session/end.d.ts.map +1 -0
- package/dist/cli/commands/session/end.js +165 -0
- package/dist/cli/commands/session/end.js.map +1 -0
- package/dist/cli/commands/session/index.d.ts +13 -0
- package/dist/cli/commands/session/index.d.ts.map +1 -0
- package/dist/cli/commands/session/index.js +13 -0
- package/dist/cli/commands/session/index.js.map +1 -0
- package/dist/cli/commands/session/register.d.ts +12 -0
- package/dist/cli/commands/session/register.d.ts.map +1 -0
- package/dist/cli/commands/session/register.js +87 -0
- package/dist/cli/commands/session/register.js.map +1 -0
- package/dist/cli/commands/session/start.d.ts +12 -0
- package/dist/cli/commands/session/start.d.ts.map +1 -0
- package/dist/cli/commands/session/start.js +189 -0
- package/dist/cli/commands/session/start.js.map +1 -0
- package/dist/cli/commands/session/status.d.ts +12 -0
- package/dist/cli/commands/session/status.d.ts.map +1 -0
- package/dist/cli/commands/session/status.js +93 -0
- package/dist/cli/commands/session/status.js.map +1 -0
- package/dist/cli/commands/session/types.d.ts +179 -0
- package/dist/cli/commands/session/types.d.ts.map +1 -0
- package/dist/cli/commands/session/types.js +8 -0
- package/dist/cli/commands/session/types.js.map +1 -0
- package/dist/cli/commands/session/utils.d.ts +24 -0
- package/dist/cli/commands/session/utils.d.ts.map +1 -0
- package/dist/cli/commands/session/utils.js +72 -0
- package/dist/cli/commands/session/utils.js.map +1 -0
- package/dist/cli/commands/specs.d.ts +16 -0
- package/dist/cli/commands/specs.d.ts.map +1 -0
- package/dist/cli/commands/specs.js +212 -0
- package/dist/cli/commands/specs.js.map +1 -0
- package/dist/cli/commands/specs.types.d.ts +120 -0
- package/dist/cli/commands/specs.types.d.ts.map +1 -0
- package/dist/cli/commands/specs.types.js +75 -0
- package/dist/cli/commands/specs.types.js.map +1 -0
- package/dist/cli/commands/status.d.ts +17 -0
- package/dist/cli/commands/status.d.ts.map +1 -0
- package/dist/cli/commands/status.js +271 -0
- package/dist/cli/commands/status.js.map +1 -0
- package/dist/cli/commands/status.types.d.ts +382 -0
- package/dist/cli/commands/status.types.d.ts.map +1 -0
- package/dist/cli/commands/status.types.js +166 -0
- package/dist/cli/commands/status.types.js.map +1 -0
- package/dist/cli/commands/switch.d.ts +18 -0
- package/dist/cli/commands/switch.d.ts.map +1 -0
- package/dist/cli/commands/switch.js +181 -0
- package/dist/cli/commands/switch.js.map +1 -0
- package/dist/cli/commands/switch.types.d.ts +123 -0
- package/dist/cli/commands/switch.types.d.ts.map +1 -0
- package/dist/cli/commands/switch.types.js +65 -0
- package/dist/cli/commands/switch.types.js.map +1 -0
- package/dist/cli/commands/ticket/command.d.ts +14 -0
- package/dist/cli/commands/ticket/command.d.ts.map +1 -0
- package/dist/cli/commands/ticket/command.js +141 -0
- package/dist/cli/commands/ticket/command.js.map +1 -0
- package/dist/cli/commands/ticket/display.d.ts +56 -0
- package/dist/cli/commands/ticket/display.d.ts.map +1 -0
- package/dist/cli/commands/ticket/display.js +205 -0
- package/dist/cli/commands/ticket/display.js.map +1 -0
- package/dist/cli/commands/ticket/index.d.ts +11 -0
- package/dist/cli/commands/ticket/index.d.ts.map +1 -0
- package/dist/cli/commands/ticket/index.js +11 -0
- package/dist/cli/commands/ticket/index.js.map +1 -0
- package/dist/cli/commands/ticket/register.d.ts +11 -0
- package/dist/cli/commands/ticket/register.d.ts.map +1 -0
- package/dist/cli/commands/ticket/register.js +39 -0
- package/dist/cli/commands/ticket/register.js.map +1 -0
- package/dist/cli/commands/ticket/resolver.d.ts +16 -0
- package/dist/cli/commands/ticket/resolver.d.ts.map +1 -0
- package/dist/cli/commands/ticket/resolver.js +35 -0
- package/dist/cli/commands/ticket/resolver.js.map +1 -0
- package/dist/cli/commands/ticket/types.d.ts +157 -0
- package/dist/cli/commands/ticket/types.d.ts.map +1 -0
- package/dist/cli/commands/ticket/types.js +8 -0
- package/dist/cli/commands/ticket/types.js.map +1 -0
- package/dist/cli/commands/tickets.d.ts +16 -0
- package/dist/cli/commands/tickets.d.ts.map +1 -0
- package/dist/cli/commands/tickets.js +271 -0
- package/dist/cli/commands/tickets.js.map +1 -0
- package/dist/cli/commands/tickets.types.d.ts +202 -0
- package/dist/cli/commands/tickets.types.d.ts.map +1 -0
- package/dist/cli/commands/tickets.types.js +138 -0
- package/dist/cli/commands/tickets.types.js.map +1 -0
- package/dist/cli/config/index.d.ts +11 -0
- package/dist/cli/config/index.d.ts.map +1 -0
- package/dist/cli/config/index.js +11 -0
- package/dist/cli/config/index.js.map +1 -0
- package/dist/cli/config/loader.d.ts +98 -0
- package/dist/cli/config/loader.d.ts.map +1 -0
- package/dist/cli/config/loader.js +237 -0
- package/dist/cli/config/loader.js.map +1 -0
- package/dist/cli/config/paths.d.ts +96 -0
- package/dist/cli/config/paths.d.ts.map +1 -0
- package/dist/cli/config/paths.js +140 -0
- package/dist/cli/config/paths.js.map +1 -0
- package/dist/cli/config/types.d.ts +148 -0
- package/dist/cli/config/types.d.ts.map +1 -0
- package/dist/cli/config/types.js +34 -0
- package/dist/cli/config/types.js.map +1 -0
- package/dist/cli/config/writer.d.ts +171 -0
- package/dist/cli/config/writer.d.ts.map +1 -0
- package/dist/cli/config/writer.js +312 -0
- package/dist/cli/config/writer.js.map +1 -0
- package/dist/cli/index.d.ts +30 -0
- package/dist/cli/index.d.ts.map +1 -0
- package/dist/cli/index.js +183 -0
- package/dist/cli/index.js.map +1 -0
- package/dist/cli/middleware/auth-guard.d.ts +107 -0
- package/dist/cli/middleware/auth-guard.d.ts.map +1 -0
- package/dist/cli/middleware/auth-guard.js +190 -0
- package/dist/cli/middleware/auth-guard.js.map +1 -0
- package/dist/cli/middleware/error-handler.d.ts +133 -0
- package/dist/cli/middleware/error-handler.d.ts.map +1 -0
- package/dist/cli/middleware/error-handler.js +209 -0
- package/dist/cli/middleware/error-handler.js.map +1 -0
- package/dist/cli/middleware/index.d.ts +6 -0
- package/dist/cli/middleware/index.d.ts.map +1 -0
- package/dist/cli/middleware/index.js +6 -0
- package/dist/cli/middleware/index.js.map +1 -0
- package/dist/cli/templates/commands.d.ts +20 -0
- package/dist/cli/templates/commands.d.ts.map +1 -0
- package/dist/cli/templates/commands.js +174 -0
- package/dist/cli/templates/commands.js.map +1 -0
- package/dist/cli/templates/content/sf-autonomous.d.ts +7 -0
- package/dist/cli/templates/content/sf-autonomous.d.ts.map +1 -0
- package/dist/cli/templates/content/sf-autonomous.js +78 -0
- package/dist/cli/templates/content/sf-autonomous.js.map +1 -0
- package/dist/cli/templates/content/sf-blockers.d.ts +7 -0
- package/dist/cli/templates/content/sf-blockers.d.ts.map +1 -0
- package/dist/cli/templates/content/sf-blockers.js +68 -0
- package/dist/cli/templates/content/sf-blockers.js.map +1 -0
- package/dist/cli/templates/content/sf-commit.d.ts +7 -0
- package/dist/cli/templates/content/sf-commit.d.ts.map +1 -0
- package/dist/cli/templates/content/sf-commit.js +78 -0
- package/dist/cli/templates/content/sf-commit.js.map +1 -0
- package/dist/cli/templates/content/sf-context.d.ts +7 -0
- package/dist/cli/templates/content/sf-context.d.ts.map +1 -0
- package/dist/cli/templates/content/sf-context.js +64 -0
- package/dist/cli/templates/content/sf-context.js.map +1 -0
- package/dist/cli/templates/content/sf-create-epics.d.ts +7 -0
- package/dist/cli/templates/content/sf-create-epics.d.ts.map +1 -0
- package/dist/cli/templates/content/sf-create-epics.js +70 -0
- package/dist/cli/templates/content/sf-create-epics.js.map +1 -0
- package/dist/cli/templates/content/sf-create-spec.d.ts +7 -0
- package/dist/cli/templates/content/sf-create-spec.d.ts.map +1 -0
- package/dist/cli/templates/content/sf-create-spec.js +67 -0
- package/dist/cli/templates/content/sf-create-spec.js.map +1 -0
- package/dist/cli/templates/content/sf-create-tickets.d.ts +7 -0
- package/dist/cli/templates/content/sf-create-tickets.d.ts.map +1 -0
- package/dist/cli/templates/content/sf-create-tickets.js +76 -0
- package/dist/cli/templates/content/sf-create-tickets.js.map +1 -0
- package/dist/cli/templates/content/sf-epic.d.ts +7 -0
- package/dist/cli/templates/content/sf-epic.d.ts.map +1 -0
- package/dist/cli/templates/content/sf-epic.js +69 -0
- package/dist/cli/templates/content/sf-epic.js.map +1 -0
- package/dist/cli/templates/content/sf-help.d.ts +7 -0
- package/dist/cli/templates/content/sf-help.d.ts.map +1 -0
- package/dist/cli/templates/content/sf-help.js +61 -0
- package/dist/cli/templates/content/sf-help.js.map +1 -0
- package/dist/cli/templates/content/sf-import.d.ts +7 -0
- package/dist/cli/templates/content/sf-import.d.ts.map +1 -0
- package/dist/cli/templates/content/sf-import.js +88 -0
- package/dist/cli/templates/content/sf-import.js.map +1 -0
- package/dist/cli/templates/content/sf-init.d.ts +7 -0
- package/dist/cli/templates/content/sf-init.d.ts.map +1 -0
- package/dist/cli/templates/content/sf-init.js +61 -0
- package/dist/cli/templates/content/sf-init.js.map +1 -0
- package/dist/cli/templates/content/sf-next.d.ts +7 -0
- package/dist/cli/templates/content/sf-next.d.ts.map +1 -0
- package/dist/cli/templates/content/sf-next.js +67 -0
- package/dist/cli/templates/content/sf-next.js.map +1 -0
- package/dist/cli/templates/content/sf-reset.d.ts +7 -0
- package/dist/cli/templates/content/sf-reset.d.ts.map +1 -0
- package/dist/cli/templates/content/sf-reset.js +78 -0
- package/dist/cli/templates/content/sf-reset.js.map +1 -0
- package/dist/cli/templates/content/sf-review.d.ts +7 -0
- package/dist/cli/templates/content/sf-review.d.ts.map +1 -0
- package/dist/cli/templates/content/sf-review.js +67 -0
- package/dist/cli/templates/content/sf-review.js.map +1 -0
- package/dist/cli/templates/content/sf-search.d.ts +7 -0
- package/dist/cli/templates/content/sf-search.d.ts.map +1 -0
- package/dist/cli/templates/content/sf-search.js +64 -0
- package/dist/cli/templates/content/sf-search.js.map +1 -0
- package/dist/cli/templates/content/sf-status.d.ts +7 -0
- package/dist/cli/templates/content/sf-status.d.ts.map +1 -0
- package/dist/cli/templates/content/sf-status.js +67 -0
- package/dist/cli/templates/content/sf-status.js.map +1 -0
- package/dist/cli/templates/content/sf-ticket.d.ts +7 -0
- package/dist/cli/templates/content/sf-ticket.d.ts.map +1 -0
- package/dist/cli/templates/content/sf-ticket.js +76 -0
- package/dist/cli/templates/content/sf-ticket.js.map +1 -0
- package/dist/cli/templates/content/sf-validate.d.ts +7 -0
- package/dist/cli/templates/content/sf-validate.d.ts.map +1 -0
- package/dist/cli/templates/content/sf-validate.js +78 -0
- package/dist/cli/templates/content/sf-validate.js.map +1 -0
- package/dist/cli/templates/index.d.ts +7 -0
- package/dist/cli/templates/index.d.ts.map +1 -0
- package/dist/cli/templates/index.js +7 -0
- package/dist/cli/templates/index.js.map +1 -0
- package/dist/cli/ui/colors.d.ts +76 -0
- package/dist/cli/ui/colors.d.ts.map +1 -0
- package/dist/cli/ui/colors.js +81 -0
- package/dist/cli/ui/colors.js.map +1 -0
- package/dist/cli/ui/dashboard.d.ts +54 -0
- package/dist/cli/ui/dashboard.d.ts.map +1 -0
- package/dist/cli/ui/dashboard.js +339 -0
- package/dist/cli/ui/dashboard.js.map +1 -0
- package/dist/cli/ui/index.d.ts +7 -0
- package/dist/cli/ui/index.d.ts.map +1 -0
- package/dist/cli/ui/index.js +7 -0
- package/dist/cli/ui/index.js.map +1 -0
- package/dist/cli/ui/output.d.ts +117 -0
- package/dist/cli/ui/output.d.ts.map +1 -0
- package/dist/cli/ui/output.js +172 -0
- package/dist/cli/ui/output.js.map +1 -0
- package/dist/cli/ui/spinner.d.ts +105 -0
- package/dist/cli/ui/spinner.d.ts.map +1 -0
- package/dist/cli/ui/spinner.js +148 -0
- package/dist/cli/ui/spinner.js.map +1 -0
- package/dist/cli/ui/time.d.ts +54 -0
- package/dist/cli/ui/time.d.ts.map +1 -0
- package/dist/cli/ui/time.js +173 -0
- package/dist/cli/ui/time.js.map +1 -0
- package/dist/lib/format.d.ts +4 -4
- package/dist/lib/format.js +5 -5
- package/dist/server.js +8 -8
- package/dist/server.js.map +1 -1
- package/dist/tools/core/session.js +6 -6
- package/dist/tools/core/session.js.map +1 -1
- package/dist/tools/index.js +9 -9
- package/dist/tools/index.js.map +1 -1
- package/dist/validation/index.js +1 -1
- package/dist/validation/index.js.map +1 -1
- package/package.json +9 -2
|
@@ -0,0 +1,326 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Init Command
|
|
3
|
+
*
|
|
4
|
+
* Initializes SpecForge for a project by creating config files
|
|
5
|
+
* and linking to a SpecForge project and specification.
|
|
6
|
+
*/
|
|
7
|
+
import inquirer from 'inquirer';
|
|
8
|
+
import ora from 'ora';
|
|
9
|
+
import fs from 'node:fs';
|
|
10
|
+
import { resolveConfig, saveProjectConfig, saveMcpConfig, addToGitignore, getConfigPaths, } from '../config/index.js';
|
|
11
|
+
import { withErrorHandler, CliError, NetworkError, ValidationError } from '../middleware/error-handler.js';
|
|
12
|
+
import { printSuccess, printWarning, printBlank, printHeader, printField, printHint, } from '../ui/output.js';
|
|
13
|
+
import { colors } from '../ui/colors.js';
|
|
14
|
+
import { ApiClient } from '../../client/api-client.js';
|
|
15
|
+
import { FORMAT_CHOICES, DEFAULT_FORMAT, } from './init.types.js';
|
|
16
|
+
/**
|
|
17
|
+
* Fetch user's projects from API
|
|
18
|
+
*/
|
|
19
|
+
async function fetchProjects(client) {
|
|
20
|
+
const response = await client.call('list_projects', {});
|
|
21
|
+
return response.projects || [];
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* Fetch specifications for a project
|
|
25
|
+
*/
|
|
26
|
+
async function fetchSpecifications(client, projectId) {
|
|
27
|
+
const response = await client.call('list_specifications', { projectId });
|
|
28
|
+
return response.specifications || [];
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* Check if config files already exist
|
|
32
|
+
*/
|
|
33
|
+
function checkExistingFiles() {
|
|
34
|
+
const paths = getConfigPaths();
|
|
35
|
+
const mcpConfig = fs.existsSync(paths.mcpConfig);
|
|
36
|
+
const projectConfig = fs.existsSync(paths.projectConfig);
|
|
37
|
+
return {
|
|
38
|
+
mcpConfig,
|
|
39
|
+
projectConfig,
|
|
40
|
+
anyExists: mcpConfig || projectConfig,
|
|
41
|
+
};
|
|
42
|
+
}
|
|
43
|
+
/**
|
|
44
|
+
* Build project choices for inquirer
|
|
45
|
+
*/
|
|
46
|
+
function buildProjectChoices(projects) {
|
|
47
|
+
return projects.map((p) => ({
|
|
48
|
+
name: `${p.name}${p.specificationCount ? ` (${p.specificationCount} specs)` : ''}`,
|
|
49
|
+
value: p.id,
|
|
50
|
+
short: p.name,
|
|
51
|
+
}));
|
|
52
|
+
}
|
|
53
|
+
/**
|
|
54
|
+
* Build specification choices for inquirer
|
|
55
|
+
*/
|
|
56
|
+
function buildSpecificationChoices(specs) {
|
|
57
|
+
const choices = specs.map((s) => {
|
|
58
|
+
const ticketInfo = s.ticketCount
|
|
59
|
+
? ` - ${s.completedTicketCount || 0}/${s.ticketCount} tickets`
|
|
60
|
+
: '';
|
|
61
|
+
return {
|
|
62
|
+
name: `${s.title} [${s.status}]${ticketInfo}`,
|
|
63
|
+
value: s.id,
|
|
64
|
+
short: s.title,
|
|
65
|
+
};
|
|
66
|
+
});
|
|
67
|
+
// Add "none" option
|
|
68
|
+
choices.push({
|
|
69
|
+
name: colors.muted('(skip - select later)'),
|
|
70
|
+
value: undefined,
|
|
71
|
+
});
|
|
72
|
+
return choices;
|
|
73
|
+
}
|
|
74
|
+
/**
|
|
75
|
+
* Prompt user to select a project
|
|
76
|
+
*/
|
|
77
|
+
async function promptForProject(projects) {
|
|
78
|
+
const choices = buildProjectChoices(projects);
|
|
79
|
+
const { projectId } = await inquirer.prompt([
|
|
80
|
+
{
|
|
81
|
+
type: 'list',
|
|
82
|
+
name: 'projectId',
|
|
83
|
+
message: 'Select project for this directory:',
|
|
84
|
+
choices,
|
|
85
|
+
pageSize: 10,
|
|
86
|
+
},
|
|
87
|
+
]);
|
|
88
|
+
const selected = projects.find((p) => p.id === projectId);
|
|
89
|
+
if (!selected) {
|
|
90
|
+
throw new CliError('Project selection failed');
|
|
91
|
+
}
|
|
92
|
+
return selected;
|
|
93
|
+
}
|
|
94
|
+
/**
|
|
95
|
+
* Prompt user to select a specification
|
|
96
|
+
*/
|
|
97
|
+
async function promptForSpecification(specs) {
|
|
98
|
+
if (specs.length === 0) {
|
|
99
|
+
return undefined;
|
|
100
|
+
}
|
|
101
|
+
const choices = buildSpecificationChoices(specs);
|
|
102
|
+
const { specificationId } = await inquirer.prompt([
|
|
103
|
+
{
|
|
104
|
+
type: 'list',
|
|
105
|
+
name: 'specificationId',
|
|
106
|
+
message: 'Select default specification (optional):',
|
|
107
|
+
choices,
|
|
108
|
+
pageSize: 10,
|
|
109
|
+
},
|
|
110
|
+
]);
|
|
111
|
+
if (!specificationId) {
|
|
112
|
+
return undefined;
|
|
113
|
+
}
|
|
114
|
+
return specs.find((s) => s.id === specificationId);
|
|
115
|
+
}
|
|
116
|
+
/**
|
|
117
|
+
* Prompt user to select output format
|
|
118
|
+
*/
|
|
119
|
+
async function promptForFormat() {
|
|
120
|
+
const { format } = await inquirer.prompt([
|
|
121
|
+
{
|
|
122
|
+
type: 'list',
|
|
123
|
+
name: 'format',
|
|
124
|
+
message: 'Default output format:',
|
|
125
|
+
choices: FORMAT_CHOICES,
|
|
126
|
+
default: DEFAULT_FORMAT,
|
|
127
|
+
},
|
|
128
|
+
]);
|
|
129
|
+
return format;
|
|
130
|
+
}
|
|
131
|
+
/**
|
|
132
|
+
* Validate project ID exists
|
|
133
|
+
*/
|
|
134
|
+
function validateProjectId(projectId, projects) {
|
|
135
|
+
const project = projects.find((p) => p.id === projectId);
|
|
136
|
+
if (!project) {
|
|
137
|
+
const available = projects.map((p) => ` - ${p.id}: ${p.name}`).join('\n');
|
|
138
|
+
throw new ValidationError(`Project not found: ${projectId}`, `Available projects:\n${available}`);
|
|
139
|
+
}
|
|
140
|
+
return project;
|
|
141
|
+
}
|
|
142
|
+
/**
|
|
143
|
+
* Validate specification ID exists
|
|
144
|
+
*/
|
|
145
|
+
function validateSpecificationId(specId, specs) {
|
|
146
|
+
const spec = specs.find((s) => s.id === specId);
|
|
147
|
+
if (!spec) {
|
|
148
|
+
const available = specs.map((s) => ` - ${s.id}: ${s.title}`).join('\n');
|
|
149
|
+
throw new ValidationError(`Specification not found: ${specId}`, `Available specifications:\n${available}`);
|
|
150
|
+
}
|
|
151
|
+
return spec;
|
|
152
|
+
}
|
|
153
|
+
/**
|
|
154
|
+
* Init command implementation
|
|
155
|
+
*/
|
|
156
|
+
export async function initAction(options) {
|
|
157
|
+
// Check authentication
|
|
158
|
+
const config = resolveConfig();
|
|
159
|
+
if (!config.apiKey) {
|
|
160
|
+
throw new CliError('Not authenticated', 1, 'Run `specforge-mcp login` to authenticate first');
|
|
161
|
+
}
|
|
162
|
+
// Header
|
|
163
|
+
printBlank();
|
|
164
|
+
printHeader('SpecForge Project Setup');
|
|
165
|
+
console.log(colors.muted(`Using API key from ${config.sources.apiKey === 'env' ? 'environment' : '~/.specforge/config.json'}`));
|
|
166
|
+
printBlank();
|
|
167
|
+
// Check for existing files
|
|
168
|
+
const existing = checkExistingFiles();
|
|
169
|
+
if (existing.anyExists && !options.force) {
|
|
170
|
+
printWarning('Configuration files already exist:');
|
|
171
|
+
if (existing.mcpConfig) {
|
|
172
|
+
console.log(` ${colors.muted('•')} .mcp.json`);
|
|
173
|
+
}
|
|
174
|
+
if (existing.projectConfig) {
|
|
175
|
+
console.log(` ${colors.muted('•')} .specforge.json`);
|
|
176
|
+
}
|
|
177
|
+
printBlank();
|
|
178
|
+
console.log(`Use ${colors.primary('--force')} to overwrite existing files.`);
|
|
179
|
+
printBlank();
|
|
180
|
+
return;
|
|
181
|
+
}
|
|
182
|
+
// Create API client
|
|
183
|
+
const client = new ApiClient({
|
|
184
|
+
apiKey: config.apiKey,
|
|
185
|
+
apiUrl: config.apiUrl,
|
|
186
|
+
debug: config.debug,
|
|
187
|
+
});
|
|
188
|
+
// Fetch projects
|
|
189
|
+
const spinner = ora({
|
|
190
|
+
text: 'Connecting to SpecForge...',
|
|
191
|
+
color: 'cyan',
|
|
192
|
+
}).start();
|
|
193
|
+
let projects;
|
|
194
|
+
try {
|
|
195
|
+
projects = await fetchProjects(client);
|
|
196
|
+
spinner.succeed('Connected to SpecForge');
|
|
197
|
+
}
|
|
198
|
+
catch (error) {
|
|
199
|
+
spinner.fail('Connection failed');
|
|
200
|
+
const message = error instanceof Error ? error.message : String(error);
|
|
201
|
+
if (message.includes('401') || message.includes('Unauthorized')) {
|
|
202
|
+
throw new CliError('Authentication failed', 1, 'Your API key may be invalid. Run `specforge-mcp login` to re-authenticate');
|
|
203
|
+
}
|
|
204
|
+
throw new NetworkError(`Failed to fetch projects: ${message}`);
|
|
205
|
+
}
|
|
206
|
+
// Handle no projects
|
|
207
|
+
if (projects.length === 0) {
|
|
208
|
+
printBlank();
|
|
209
|
+
printWarning('No projects found in your account.');
|
|
210
|
+
console.log(`Create a project at ${colors.primary.underline('https://specforge.com.br')} first.`);
|
|
211
|
+
printBlank();
|
|
212
|
+
return;
|
|
213
|
+
}
|
|
214
|
+
// Select project
|
|
215
|
+
let selectedProject;
|
|
216
|
+
if (options.project) {
|
|
217
|
+
selectedProject = validateProjectId(options.project, projects);
|
|
218
|
+
console.log(colors.muted(`Using project: ${selectedProject.name}`));
|
|
219
|
+
}
|
|
220
|
+
else {
|
|
221
|
+
selectedProject = await promptForProject(projects);
|
|
222
|
+
}
|
|
223
|
+
// Fetch specifications for selected project
|
|
224
|
+
const specsSpinner = ora({
|
|
225
|
+
text: 'Fetching specifications...',
|
|
226
|
+
color: 'cyan',
|
|
227
|
+
}).start();
|
|
228
|
+
let specs;
|
|
229
|
+
try {
|
|
230
|
+
specs = await fetchSpecifications(client, selectedProject.id);
|
|
231
|
+
specsSpinner.succeed(`Found ${specs.length} specification(s)`);
|
|
232
|
+
}
|
|
233
|
+
catch (error) {
|
|
234
|
+
specsSpinner.fail('Failed to fetch specifications');
|
|
235
|
+
throw new NetworkError(`Failed to fetch specifications: ${error instanceof Error ? error.message : String(error)}`);
|
|
236
|
+
}
|
|
237
|
+
// Select specification
|
|
238
|
+
let selectedSpec;
|
|
239
|
+
if (options.spec) {
|
|
240
|
+
if (specs.length === 0) {
|
|
241
|
+
printWarning(`No specifications found. Ignoring --spec flag.`);
|
|
242
|
+
}
|
|
243
|
+
else {
|
|
244
|
+
selectedSpec = validateSpecificationId(options.spec, specs);
|
|
245
|
+
console.log(colors.muted(`Using specification: ${selectedSpec.title}`));
|
|
246
|
+
}
|
|
247
|
+
}
|
|
248
|
+
else if (specs.length > 0) {
|
|
249
|
+
selectedSpec = await promptForSpecification(specs);
|
|
250
|
+
}
|
|
251
|
+
// Select format
|
|
252
|
+
let selectedFormat;
|
|
253
|
+
if (options.format) {
|
|
254
|
+
if (options.format !== 'json' && options.format !== 'toon') {
|
|
255
|
+
throw new ValidationError(`Invalid format: ${options.format}`, 'Valid formats are: json, toon');
|
|
256
|
+
}
|
|
257
|
+
selectedFormat = options.format;
|
|
258
|
+
console.log(colors.muted(`Using format: ${selectedFormat}`));
|
|
259
|
+
}
|
|
260
|
+
else {
|
|
261
|
+
selectedFormat = await promptForFormat();
|
|
262
|
+
}
|
|
263
|
+
// Generate and save config files
|
|
264
|
+
printBlank();
|
|
265
|
+
// Save .mcp.json
|
|
266
|
+
saveMcpConfig();
|
|
267
|
+
printSuccess('Created .mcp.json');
|
|
268
|
+
// Save .specforge.json
|
|
269
|
+
saveProjectConfig({
|
|
270
|
+
projectId: selectedProject.id,
|
|
271
|
+
specificationId: selectedSpec?.id,
|
|
272
|
+
format: selectedFormat,
|
|
273
|
+
autoSetContext: true,
|
|
274
|
+
});
|
|
275
|
+
printSuccess('Created .specforge.json');
|
|
276
|
+
// Add to .gitignore
|
|
277
|
+
const addedToGitignore = addToGitignore('.specforge.json');
|
|
278
|
+
if (addedToGitignore) {
|
|
279
|
+
printSuccess('Added .specforge.json to .gitignore');
|
|
280
|
+
}
|
|
281
|
+
// Success summary
|
|
282
|
+
printBlank();
|
|
283
|
+
printHeader('Configuration Complete');
|
|
284
|
+
printBlank();
|
|
285
|
+
printField('Project', selectedProject.name);
|
|
286
|
+
if (selectedSpec) {
|
|
287
|
+
printField('Specification', selectedSpec.title);
|
|
288
|
+
}
|
|
289
|
+
printField('Format', selectedFormat);
|
|
290
|
+
printField('Auto-context', 'enabled');
|
|
291
|
+
printBlank();
|
|
292
|
+
console.log(colors.warning('Restart Claude Code to activate SpecForge MCP.'));
|
|
293
|
+
printBlank();
|
|
294
|
+
// Next steps
|
|
295
|
+
console.log(colors.bold('Next steps:'));
|
|
296
|
+
printHint('specforge-mcp status', 'verify your configuration');
|
|
297
|
+
printHint('specforge-mcp tickets', 'view tickets for this specification');
|
|
298
|
+
printBlank();
|
|
299
|
+
}
|
|
300
|
+
/**
|
|
301
|
+
* Register init command with Commander
|
|
302
|
+
*/
|
|
303
|
+
export function registerInitCommand(program) {
|
|
304
|
+
program
|
|
305
|
+
.command('init')
|
|
306
|
+
.description('Initialize SpecForge for this project')
|
|
307
|
+
.option('--project <id>', 'Project ID (non-interactive)')
|
|
308
|
+
.option('--spec <id>', 'Specification ID (non-interactive)')
|
|
309
|
+
.option('--format <format>', 'Output format: json or toon (default: toon)')
|
|
310
|
+
.option('-f, --force', 'Overwrite existing configuration files')
|
|
311
|
+
.addHelpText('after', `
|
|
312
|
+
Examples:
|
|
313
|
+
$ specforge-mcp init # Interactive setup
|
|
314
|
+
$ specforge-mcp init --project proj_abc123 # Set project non-interactively
|
|
315
|
+
$ specforge-mcp init --project proj_abc --spec spec_xyz --format toon
|
|
316
|
+
$ specforge-mcp init --force # Overwrite existing config
|
|
317
|
+
|
|
318
|
+
This command creates:
|
|
319
|
+
.mcp.json - Claude Code MCP server configuration
|
|
320
|
+
.specforge.json - Project-specific SpecForge settings
|
|
321
|
+
|
|
322
|
+
After running init, restart Claude Code to activate the MCP server.
|
|
323
|
+
`)
|
|
324
|
+
.action(withErrorHandler(initAction));
|
|
325
|
+
}
|
|
326
|
+
//# sourceMappingURL=init.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"init.js","sourceRoot":"","sources":["../../../src/cli/commands/init.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAGH,OAAO,QAAQ,MAAM,UAAU,CAAC;AAEhC,OAAO,GAAG,MAAM,KAAK,CAAC;AACtB,OAAO,EAAE,MAAM,SAAS,CAAC;AACzB,OAAO,EACL,aAAa,EACb,iBAAiB,EACjB,aAAa,EACb,cAAc,EACd,cAAc,GACf,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAAE,gBAAgB,EAAE,QAAQ,EAAE,YAAY,EAAE,eAAe,EAAE,MAAM,gCAAgC,CAAC;AAC3G,OAAO,EACL,YAAY,EACZ,YAAY,EACZ,UAAU,EACV,WAAW,EACX,UAAU,EACV,SAAS,GACV,MAAM,iBAAiB,CAAC;AACzB,OAAO,EAAE,MAAM,EAAE,MAAM,iBAAiB,CAAC;AACzC,OAAO,EAAE,SAAS,EAAE,MAAM,4BAA4B,CAAC;AACvD,OAAO,EASL,cAAc,EACd,cAAc,GACf,MAAM,iBAAiB,CAAC;AAEzB;;GAEG;AACH,KAAK,UAAU,aAAa,CAAC,MAAiB;IAC5C,MAAM,QAAQ,GAAG,MAAM,MAAM,CAAC,IAAI,CAAuB,eAAe,EAAE,EAAE,CAAC,CAAC;IAC9E,OAAO,QAAQ,CAAC,QAAQ,IAAI,EAAE,CAAC;AACjC,CAAC;AAED;;GAEG;AACH,KAAK,UAAU,mBAAmB,CAChC,MAAiB,EACjB,SA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AAC;SAC1E,MAAM,CAAC,aAAa,EAAE,wCAAwC,CAAC;SAC/D,WAAW,CAAC,OAAO,EAAE;;;;;;;;;;;;CAYzB,CAAC;SACG,MAAM,CAAC,gBAAgB,CAAC,UAAU,CAAC,CAAC,CAAC;AAC1C,CAAC"}
|
|
@@ -0,0 +1,141 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Init Command Types
|
|
3
|
+
*
|
|
4
|
+
* Type definitions for the init command including options,
|
|
5
|
+
* API responses, and selection interfaces.
|
|
6
|
+
*/
|
|
7
|
+
/**
|
|
8
|
+
* Command line options for init command
|
|
9
|
+
*/
|
|
10
|
+
export interface InitOptions {
|
|
11
|
+
/** Project ID for non-interactive mode */
|
|
12
|
+
project?: string;
|
|
13
|
+
/** Specification ID for non-interactive mode */
|
|
14
|
+
spec?: string;
|
|
15
|
+
/** Output format preference */
|
|
16
|
+
format?: 'json' | 'toon';
|
|
17
|
+
/** Force overwrite existing config files */
|
|
18
|
+
force?: boolean;
|
|
19
|
+
}
|
|
20
|
+
/**
|
|
21
|
+
* Project returned from list_projects API call
|
|
22
|
+
*/
|
|
23
|
+
export interface Project {
|
|
24
|
+
/** Unique project identifier */
|
|
25
|
+
id: string;
|
|
26
|
+
/** Human-readable project name */
|
|
27
|
+
name: string;
|
|
28
|
+
/** Optional description */
|
|
29
|
+
description?: string;
|
|
30
|
+
/** Number of specifications in this project */
|
|
31
|
+
specificationCount?: number;
|
|
32
|
+
/** Creation timestamp */
|
|
33
|
+
createdAt?: string;
|
|
34
|
+
/** Last update timestamp */
|
|
35
|
+
updatedAt?: string;
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* Specification returned from list_specifications API call
|
|
39
|
+
*/
|
|
40
|
+
export interface Specification {
|
|
41
|
+
/** Unique specification identifier */
|
|
42
|
+
id: string;
|
|
43
|
+
/** Specification title */
|
|
44
|
+
title: string;
|
|
45
|
+
/** Current status (draft, ready, in_progress, completed) */
|
|
46
|
+
status: SpecificationStatus;
|
|
47
|
+
/** Number of tickets in this specification */
|
|
48
|
+
ticketCount?: number;
|
|
49
|
+
/** Number of completed tickets */
|
|
50
|
+
completedTicketCount?: number;
|
|
51
|
+
/** Optional description */
|
|
52
|
+
description?: string;
|
|
53
|
+
/** Creation timestamp */
|
|
54
|
+
createdAt?: string;
|
|
55
|
+
/** Last update timestamp */
|
|
56
|
+
updatedAt?: string;
|
|
57
|
+
}
|
|
58
|
+
/**
|
|
59
|
+
* Specification status values
|
|
60
|
+
*/
|
|
61
|
+
export type SpecificationStatus = 'draft' | 'ready' | 'in_progress' | 'completed' | 'archived';
|
|
62
|
+
/**
|
|
63
|
+
* API response for list_projects call
|
|
64
|
+
*/
|
|
65
|
+
export interface ListProjectsResponse {
|
|
66
|
+
/** List of user's projects */
|
|
67
|
+
projects: Project[];
|
|
68
|
+
/** Total count (for pagination) */
|
|
69
|
+
total?: number;
|
|
70
|
+
}
|
|
71
|
+
/**
|
|
72
|
+
* API response for list_specifications call
|
|
73
|
+
*/
|
|
74
|
+
export interface ListSpecificationsResponse {
|
|
75
|
+
/** List of specifications for the project */
|
|
76
|
+
specifications: Specification[];
|
|
77
|
+
/** Total count (for pagination) */
|
|
78
|
+
total?: number;
|
|
79
|
+
}
|
|
80
|
+
/**
|
|
81
|
+
* User's selections during init flow
|
|
82
|
+
*/
|
|
83
|
+
export interface InitSelections {
|
|
84
|
+
/** Selected project */
|
|
85
|
+
project: Project;
|
|
86
|
+
/** Selected specification (optional) */
|
|
87
|
+
specification?: Specification;
|
|
88
|
+
/** Selected output format */
|
|
89
|
+
format: 'json' | 'toon';
|
|
90
|
+
}
|
|
91
|
+
/**
|
|
92
|
+
* Result of checking existing config files
|
|
93
|
+
*/
|
|
94
|
+
export interface ExistingFilesCheck {
|
|
95
|
+
/** Whether .mcp.json exists */
|
|
96
|
+
mcpConfig: boolean;
|
|
97
|
+
/** Whether .specforge.json exists */
|
|
98
|
+
projectConfig: boolean;
|
|
99
|
+
/** Whether any file exists */
|
|
100
|
+
anyExists: boolean;
|
|
101
|
+
}
|
|
102
|
+
/**
|
|
103
|
+
* Inquirer choice format for project selection
|
|
104
|
+
*/
|
|
105
|
+
export interface ProjectChoice {
|
|
106
|
+
/** Display name */
|
|
107
|
+
name: string;
|
|
108
|
+
/** Project ID value */
|
|
109
|
+
value: string;
|
|
110
|
+
/** Short name (optional) */
|
|
111
|
+
short?: string;
|
|
112
|
+
}
|
|
113
|
+
/**
|
|
114
|
+
* Inquirer choice format for specification selection
|
|
115
|
+
*/
|
|
116
|
+
export interface SpecificationChoice {
|
|
117
|
+
/** Display name */
|
|
118
|
+
name: string;
|
|
119
|
+
/** Specification ID value (undefined for "none" option) */
|
|
120
|
+
value: string | undefined;
|
|
121
|
+
/** Short name (optional) */
|
|
122
|
+
short?: string;
|
|
123
|
+
}
|
|
124
|
+
/**
|
|
125
|
+
* Inquirer choice format for format selection
|
|
126
|
+
*/
|
|
127
|
+
export interface FormatChoice {
|
|
128
|
+
/** Display name */
|
|
129
|
+
name: string;
|
|
130
|
+
/** Format value */
|
|
131
|
+
value: 'json' | 'toon';
|
|
132
|
+
}
|
|
133
|
+
/**
|
|
134
|
+
* Format display names with descriptions
|
|
135
|
+
*/
|
|
136
|
+
export declare const FORMAT_CHOICES: FormatChoice[];
|
|
137
|
+
/**
|
|
138
|
+
* Default format selection
|
|
139
|
+
*/
|
|
140
|
+
export declare const DEFAULT_FORMAT: 'json' | 'toon';
|
|
141
|
+
//# sourceMappingURL=init.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"init.types.d.ts","sourceRoot":"","sources":["../../../src/cli/commands/init.types.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH;;GAEG;AACH,MAAM,WAAW,WAAW;IAC1B,0CAA0C;IAC1C,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB,gDAAgD;IAChD,IAAI,CAAC,EAAE,MAAM,CAAC;IAEd,+BAA+B;IAC/B,MAAM,CAAC,EAAE,M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AAC,EAAE,MAAM,CAAC;CAChB;AAED;;GAEG;AACH,MAAM,WAAW,cAAc;IAC7B,uBAAuB;IACvB,OAAO,EAAE,OAAO,CAAC;IAEjB,wCAAwC;IACxC,aAAa,CAAC,EAAE,aAAa,CAAC;IAE9B,6BAA6B;IAC7B,MAAM,EAAE,MAAM,GAAG,MAAM,CAAC;CACzB;AAED;;GAEG;AACH,MAAM,WAAW,kBAAkB;IACjC,+BAA+B;IAC/B,SAAS,EAAE,OAAO,CAAC;IAEnB,qCAAqC;IACrC,aAAa,EAAE,OAAO,CAAC;IAEvB,8BAA8B;IAC9B,SAAS,EAAE,OAAO,CAAC;CACpB;AAED;;GAEG;AACH,MAAM,WAAW,aAAa;IAC5B,mBAAmB;IACnB,IAAI,EAAE,MAAM,CAAC;IAEb,uBAAuB;IACvB,KAAK,EAAE,MAAM,CAAC;IAEd,4BAA4B;IAC5B,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED;;GAEG;AACH,MAAM,WAAW,mBAAmB;IAClC,mBAAmB;IACnB,IAAI,EAAE,MAAM,CAAC;IAEb,2DAA2D;IAC3D,KAAK,EAAE,MAAM,GAAG,SAAS,CAAC;IAE1B,4BAA4B;IAC5B,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED;;GAEG;AACH,MAAM,WAAW,YAAY;IAC3B,mBAAmB;IACnB,IAAI,EAAE,MAAM,CAAC;IAEb,mBAAmB;IACnB,KAAK,EAAE,MAAM,GAAG,MAAM,CAAC;CACxB;AAED;;GAEG;AACH,eAAO,MAAM,cAAc,EAAE,YAAY,EASxC,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,cAAc,EAAE,MAAM,GAAG,MAAe,CAAC"}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Init Command Types
|
|
3
|
+
*
|
|
4
|
+
* Type definitions for the init command including options,
|
|
5
|
+
* API responses, and selection interfaces.
|
|
6
|
+
*/
|
|
7
|
+
/**
|
|
8
|
+
* Format display names with descriptions
|
|
9
|
+
*/
|
|
10
|
+
export const FORMAT_CHOICES = [
|
|
11
|
+
{
|
|
12
|
+
name: 'toon (recommended - 44% fewer tokens)',
|
|
13
|
+
value: 'toon',
|
|
14
|
+
},
|
|
15
|
+
{
|
|
16
|
+
name: 'json (standard JSON format)',
|
|
17
|
+
value: 'json',
|
|
18
|
+
},
|
|
19
|
+
];
|
|
20
|
+
/**
|
|
21
|
+
* Default format selection
|
|
22
|
+
*/
|
|
23
|
+
export const DEFAULT_FORMAT = 'toon';
|
|
24
|
+
//# sourceMappingURL=init.types.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"init.types.js","sourceRoot":"","sources":["../../../src/cli/commands/init.types.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AA0KH;;GAEG;AACH,MAAM,CAAC,MAAM,cAAc,GAAmB;IAC5C;QACE,IAAI,EAAE,uCAAuC;QAC7C,KAAK,EAAE,MAAM;KACd;IACD;QACE,IAAI,EAAE,6BAA6B;QACnC,KAAK,EAAE,MAAM;KACd;CACF,CAAC;AAEF;;GAEG;AACH,MAAM,CAAC,MAAM,cAAc,GAAoB,MAAM,CAAC"}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Login Command
|
|
3
|
+
*
|
|
4
|
+
* Authenticates users with their SpecForge API key.
|
|
5
|
+
* Supports both interactive (masked input) and non-interactive (--api-key flag) modes.
|
|
6
|
+
*/
|
|
7
|
+
import { Command } from 'commander';
|
|
8
|
+
/**
|
|
9
|
+
* Login command options
|
|
10
|
+
*/
|
|
11
|
+
export interface LoginOptions {
|
|
12
|
+
/** API key provided via --api-key flag */
|
|
13
|
+
apiKey?: string;
|
|
14
|
+
/** Force re-authentication even if already logged in */
|
|
15
|
+
force?: boolean;
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* User information returned from API validation
|
|
19
|
+
*/
|
|
20
|
+
export interface UserInfo {
|
|
21
|
+
/** User's email address */
|
|
22
|
+
email: string;
|
|
23
|
+
/** User's display name */
|
|
24
|
+
name?: string;
|
|
25
|
+
/** User ID */
|
|
26
|
+
userId?: string;
|
|
27
|
+
}
|
|
28
|
+
/**
|
|
29
|
+
* Login command implementation
|
|
30
|
+
*
|
|
31
|
+
* @param options - Command options
|
|
32
|
+
*/
|
|
33
|
+
export declare function loginAction(options: LoginOptions): Promise<void>;
|
|
34
|
+
/**
|
|
35
|
+
* Register login command with Commander
|
|
36
|
+
*
|
|
37
|
+
* @param program - Commander program instance
|
|
38
|
+
*/
|
|
39
|
+
export declare function registerLoginCommand(program: Command): void;
|
|
40
|
+
//# sourceMappingURL=login.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"login.d.ts","sourceRoot":"","sources":["../../../src/cli/commands/login.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAYpC;;GAEG;AACH,MAAM,WAAW,YAAY;IAC3B,0CAA0C;IAC1C,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,wDAAwD;IACxD,KAAK,CAAC,EAAE,OAAO,CAAC;CACjB;AAED;;GAEG;AACH,MAAM,WAAW,QAAQ;IACvB,2BAA2B;IAC3B,KAAK,EAAE,MAAM,CAAC;IACd,0BAA0B;IAC1B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,cAAc;IACd,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAuGD;;;;GAIG;AACH,wBAAsB,WAAW,CAAC,OAAO,EAAE,YAAY,GAAG,OAAO,CAAC,IAAI,CAAC,CAsEtE;AAED;;;;GAIG;AACH,wBAAgB,oBAAoB,CAAC,OAAO,EAAE,OAAO,GAAG,IAAI,CAgB3D"}
|