UNPKG

gitset

Version:

Enhanced git init with user configuration management

42 lines 1.32 kB
import { ErrorType, GitStartError } from '../types/cli.js'; /** * Centralized error handling with consistent messaging and styling */ export declare class ErrorHandler { /** * Main error handling entry point */ static handle(error: unknown): void; /** * Handle application-specific errors */ private static handleGitStartError; /** * Handle generic JavaScript errors */ private static handleGenericError; /** * Handle unknown error types */ private static handleUnknownError; /** * Show recoverability message based on error type */ private static showRecoverabilityMessage; /** * Show contextual help based on error type */ private static showErrorHelp; /** * Get help messages for each error type */ private static getHelpMessages; /** * Show general help information */ private static showGeneralHelp; static createError(type: ErrorType, message: string, recoverable?: boolean, suggestion?: string): GitStartError; static validateAndThrow(condition: boolean, error: GitStartError): void; static safeExecute<T>(operation: () => Promise<T>, errorType: ErrorType, errorMessage: string, suggestion?: string): Promise<T>; } //# sourceMappingURL=error-handler.d.ts.map