/** * Only session transcripts are archivable. The session roots also hold current-state files that must stay live: * captured capability artifacts (`canon/artifacts/`), captured memory files (`…/memory/…`), and index docs * (`SKIPPED.md`, `MAPPING.md`, `PROJECTIONS.md`, `.gitkeep`). 09-26: the prefix-only filter had archived ~1.3k of them. */ export declare function isArchivablePath(p: string): boolean; /** * The files of ONE session move and dedupe together: chunks (`.jsonl.part-NNNN`), sidecars (`.events.jsonl`, * `.meta.json`), and subagent files (`/subagents/…`, `.subagents/…`). Key = the path up to the first uuid * segment (its stem), else the directory + the basename's stem. */ export declare function sessionUnit(p: string): string; export interface CanonArchiveOptions { store: string; days?: number; dryRun?: boolean; push?: boolean; } /** * Remove UNTRACKED files that are byte-identical to an archived copy at the same original path, before a commit * stages them. Two writers re-create archived sessions on disk: the browser-branch fold-in (`git checkout FETCH_HEAD * -- native/browser-cortex` restores every file the branch holds) and harness roots whose copies are re-staged * unchanged. Without this, every sync re-adds them and every archive run drops them again (seen 09-26: 77 files per * cycle). A session that grew differs from its archived copy and stays; files tracked in HEAD are never touched. */ export declare function dropArchivedDuplicates(store: string, label: string): number; /** * Remove a NEWLY staged session that is an ECHO of a session the store already holds under a DIFFERENT project dir * (same harness, same file names, identical bytes — live or archived). Mechanism (09-26, 21 archived ids): a hosted box * hydrates sessions with `pull --native --project "$PWD"` into ~/.claude/projects/-root/, then its outbound sync captures * them as new sessions under native/claude-code/-root/ → `canon pull ` became ambiguous. Unit-level (sessionUnit): * the whole session must be new under this dir and every file must match the SAME other dir; a session continued on * the box differs and is kept. Files tracked in HEAD are never touched. */ export declare function dropEchoedSessions(store: string, label: string): number; /** Archive under the store's single-writer lock (withStoreLock); busy = nothing done this cycle (0). */ export declare function canonArchive(opts: CanonArchiveOptions): Promise; //# sourceMappingURL=canonArchive.d.ts.map