import { type ProcessPort } from '../platform/process.js'; export declare const PACKAGE_NAME = "@sirtheo/claude-switch"; export interface UpdateInfo { latestVersion: string; installCommand: string; /** True when the installed version is BELOW the published `minsafe` tag — * i.e. it carries a known security/data-loss bug. Callers escalate the * notice (loud, persistent, shown even on the passthrough hot path). * Fail-open: any uncertainty (no tag, fetch failure, parse error) → false. */ critical: boolean; } /** * Returns the command array to update the package, based on how it is * currently installed (detected from the binary path). */ export declare function detectInstallCommand(): string[]; /** * Runs the detected install command with live stdio. * Returns true if the process exited successfully. */ export declare function performUpdate(deps?: { process?: ProcessPort; }): boolean; /** * Render the user-facing update notice, shared by the passthrough hot path and * the `claude switch` dispatcher so the two never drift. A `critical` update * (installed version below the minsafe tag) gets a loud, bold-red, can't-miss * banner; a routine update keeps the quiet one-liner. Colour is gated by the * caller (off when stderr isn't a TTY, or under --no-color / NO_COLOR), so * piped/scripted output stays clean. */ export declare function formatUpdateNotice(info: UpdateInfo, currentVersion: string, opts: { color: boolean; }): string;