import type { HfHubAccessor } from '../../accessor/hf_hub.ts'; /** The repository's branches, tags and conversion refs. */ export declare function fetchRefs(accessor: HfHubAccessor): Promise>; /** * The commit the mount's revision currently points at. * * Read from the repo object rather than from /refs because the repo object * answers it for a tag and a commit-pinned mount too, where /refs only * enumerates branches. * * Asked of the revision endpoint, not the bare one: the bare object's `sha` * is the default branch's whatever revision was requested, and the cache is * keyed by this sha. Reading the wrong one files a `--revision dev` download * under main's snapshot and points refs/dev at it, so a later main download * finds the snapshot already there and serves dev's bytes. */ export declare function headCommit(accessor: HfHubAccessor): Promise; /** What the Hub says is missing when a listing came back empty. */ export declare enum Absence { PRESENT = "present", REPO = "repo", REVISION = "revision" } /** The endpoint whose url upstream names in its not-found messages. */ export declare function revisionUrl(accessor: HfHubAccessor): string; /** * Why a listing came back empty, asked of the Hub directly. * * `fetchTree` folds 401/403/404 into an empty listing on purpose: a mount's * readdir over a repository it cannot see has to render an empty directory * rather than raise. A CLI verb wants the opposite, so it asks this on the * failure path only, which costs one request and only when something already * went wrong. * * The status cannot answer it. A missing repository, a missing revision and a * missing file are all 404, and only the Hub's `X-Error-Code` header tells * them apart; probed against the live Hub, not inferred. */ export declare function classifyAbsence(accessor: HfHubAccessor): Promise; //# sourceMappingURL=repo.d.ts.map