@interopio/iocd-cli
Version:
CLI tool for setting up, building and packaging io.Connect Desktop platforms
30 lines • 837 B
TypeScript
export declare enum ErrorCode {
GENERAL = 1,
INVALID_CONFIG = 2,
NETWORK_ERROR = 3,
FILE_SYSTEM_ERROR = 4,
COMPONENT_ERROR = 5,
VALIDATION_ERROR = 6,
PERMISSION_ERROR = 7,
NOT_FOUND = 8,
BUILD_ERROR = 9
}
export interface CLIErrorOptions {
code?: ErrorCode;
cause?: Error;
suggestions?: string[];
showLogPath?: boolean;
}
export declare class CLIError extends Error {
readonly code: ErrorCode;
readonly cause?: Error | undefined;
readonly suggestions: string[];
readonly showLogPath: boolean;
constructor(message: string, options?: CLIErrorOptions);
}
export declare class ErrorHandler {
private static logger;
static handle(error: Error | CLIError): void;
static wrap(fn: () => Promise<any>): Promise<any>;
}
//# sourceMappingURL=error.handler.d.ts.map