import { type InstallMethod } from "../config.ts";
import { type BrandUpdateChannel } from "../core/brand.ts";
/** Version of the latest GitHub Release, from its tag; drafts and prereleases are not installable. */
export declare function readLatestReleaseVersion(payload: unknown): string | undefined;
/** Reads the available version out of whichever registry document was fetched. */
export declare function readAvailableVersion(payload: unknown, channel: BrandUpdateChannel | undefined): string | undefined;
export interface LatestPiRelease {
    version: string;
    packageName?: string;
    note?: string;
}
/** Include useful errno details hidden behind Node's generic "fetch failed" error. */
export declare function formatVersionCheckError(error: unknown): string;
export declare function comparePackageVersions(leftVersion: string, rightVersion: string): number | undefined;
export declare function isNewerPackageVersion(candidateVersion: string, currentVersion: string): boolean;
export declare function getReleaseChangelogUrl(version: string): string;
export interface VersionCheckOptions {
    timeoutMs?: number;
    retry?: boolean;
    /** Defaults to the running install; tests pass it explicitly. */
    installMethod?: InstallMethod;
}
export declare function getLatestPiRelease(currentVersion: string, options?: VersionCheckOptions): Promise<LatestPiRelease | undefined>;
export declare function getLatestPiVersion(currentVersion: string, options?: VersionCheckOptions): Promise<string | undefined>;
export declare function checkForNewPiVersion(currentVersion: string, options?: Pick<VersionCheckOptions, "installMethod">): Promise<LatestPiRelease | undefined>;
//# sourceMappingURL=version-check.d.ts.map