export type Phase =
  | 'requirements'
  | 'design'
  | 'planning'
  | 'implementation'
  | 'testing'
  | 'deployment'
  | 'monitoring';

export interface EnvironmentDefinition {
  code: string;
  name: string;
  contextFileName: string;
  commandPath: string;
  skillPath?: string;
  description?: string;
  isCustomCommandPath?: boolean;
  customCommandExtension?: string;
  globalCommandPath?: string;
}

export type EnvironmentCode = 'cursor' | 'claude' | 'github' | 'gemini' | 'codex' | 'windsurf' | 'kilocode' | 'amp' | 'opencode' | 'roo' | 'antigravity';

export const DEFAULT_DOCS_DIR = 'docs/ai';

export interface DevKitConfig {
  version: string;
  paths?: {
    docs?: string;
  };
  environments: EnvironmentCode[];
  phases: Phase[];
  skills?: ConfigSkill[];
  createdAt: string;
  updatedAt: string;
}

export interface ConfigSkill {
  registry: string;
  name: string;
}

export interface SkillRegistriesConfig {
  registries?: Record<string, string>;
}

export interface GlobalDevKitConfig {
  skills?: SkillRegistriesConfig;
}

export interface PhaseMetadata {
  phase: string;
  title: string;
  description: string;
}

export const AVAILABLE_PHASES: Phase[] = [
  'requirements',
  'design',
  'planning',
  'implementation',
  'testing',
  'deployment',
  'monitoring'
];

export const PHASE_DISPLAY_NAMES: Record<Phase, string> = {
  requirements: 'Requirements & Problem Understanding',
  design: 'System Design & Architecture',
  planning: 'Project Planning & Task Breakdown',
  implementation: 'Implementation Guide',
  testing: 'Testing Strategy',
  deployment: 'Deployment Strategy',
  monitoring: 'Monitoring & Observability'
};
