import { Command } from 'commander'; import { PrdService } from './service.js'; import { runPrdWizard } from './wizard.js'; interface InitCommandOptions { readonly name: string; readonly project: string; readonly template?: 'software' | 'feature' | 'spike'; } interface ListCommandOptions { readonly project: string; } interface ShowCommandOptions { readonly project: string; readonly id?: string; } interface ImportCommandOptions { readonly project: string; readonly file: string; readonly acceptSuccessor?: boolean; } interface ExportCommandOptions { readonly project: string; readonly id?: string; readonly out?: string; } function serviceFor(project: string): PrdService { return new PrdService({ projectPath: project }); } export function buildPrdyCli(): Command { const program = new Command(); program.name('mosaic').description('Mosaic CLI').exitOverride(); const prdy = program.command('prdy').description('PRD wizard commands'); prdy .command('init') .description('Create a PRD document') .requiredOption('--name ', 'PRD name') .requiredOption('--project ', 'Project path') .option('--template