UNPKG

@pimzino/claude-code-spec-workflow

Version:

Automated workflows for Claude Code. Includes spec-driven development (Requirements → Design → Tasks → Implementation) with intelligent task execution, optional steering documents and streamlined bug fix workflow (Report → Analyze → Fix → Verify). We have

69 lines 2.27 kB
/** * Detects project type(s) based on files present in the project directory. * Supports multiple project types including Node.js, Python, Java, C#, Go, Rust, PHP, and Ruby. * * @param projectPath - Path to the project directory to analyze * @returns Promise resolving to array of detected project type names * * @example * ```typescript * const types = await detectProjectType('/path/to/project'); * console.log(types); // ['Node.js', 'TypeScript'] * ``` */ export declare function detectProjectType(projectPath: string): Promise<string[]>; /** * Validates that Claude Code CLI is installed and accessible. * * @returns Promise resolving to true if Claude Code is available, false otherwise * * @example * ```typescript * const isInstalled = await validateClaudeCode(); * if (!isInstalled) { * console.log('Please install Claude Code first'); * } * ``` */ export declare function validateClaudeCode(): Promise<boolean>; /** * Checks if a file exists at the given path. * * @param filePath - Path to the file to check * @returns Promise resolving to true if file exists, false otherwise * * @example * ```typescript * const exists = await fileExists('package.json'); * if (exists) { * console.log('Found package.json'); * } * ``` */ export declare function fileExists(filePath: string): Promise<boolean>; /** * Ensures a directory exists by creating it recursively if needed. * * @param dirPath - Path to the directory to create * @throws Error if directory creation fails for reasons other than already existing * * @example * ```typescript * await ensureDirectory('.claude/specs/my-feature'); * // Directory structure is now guaranteed to exist * ``` */ export declare function ensureDirectory(dirPath: string): Promise<void>; /** * Check if a port is available */ export declare function isPortAvailable(port: number): Promise<boolean>; /** * Find an available port starting from a given port number */ export declare function findAvailablePort(startPort?: number, maxAttempts?: number): Promise<number>; /** * Get the best available port from a list of preferred ports, with fallback */ export declare function getBestAvailablePort(preferredPorts?: number[]): Promise<number>; //# sourceMappingURL=utils.d.ts.map