import { rm } from 'node:fs/promises';
import { buildCommandContext, type CommandContext } from '../../../app/command-context.js';
import { type OatConfig } from '../../../config/oat-config.js';
import { buildProjectArchiveS3Uri, buildRepoArchiveS3Uri, ensureS3ArchiveAccess, type ExecFileLike, resolveLocalArchiveProjectPath, resolvePrimaryRepoRoot } from './archive-utils.js';
export interface ArchiveSyncOptions {
    dryRun?: boolean;
    force?: boolean;
    profile?: string;
    region?: string;
}
export interface ProjectArchiveCommandDependencies {
    buildCommandContext: (options: Parameters<typeof buildCommandContext>[0]) => CommandContext;
    resolveProjectRoot: (cwd: string) => Promise<string>;
    readOatConfig: (repoRoot: string) => Promise<OatConfig>;
    resolveProjectsRoot: (repoRoot: string, env: NodeJS.ProcessEnv) => Promise<string>;
    ensureS3ArchiveAccess: typeof ensureS3ArchiveAccess;
    buildRepoArchiveS3Uri: typeof buildRepoArchiveS3Uri;
    buildProjectArchiveS3Uri: typeof buildProjectArchiveS3Uri;
    resolveLocalArchiveProjectPath: typeof resolveLocalArchiveProjectPath;
    resolvePrimaryRepoRoot: typeof resolvePrimaryRepoRoot;
    execFile: ExecFileLike;
    removeDirectory: typeof rm;
    processEnv: NodeJS.ProcessEnv;
}
export declare function defaultProjectArchiveCommandDependencies(): ProjectArchiveCommandDependencies;
export declare function resolveLocalArchiveRoot(projectsRoot: string): string;
export declare function resolveSyncAwsEnv(processEnv: NodeJS.ProcessEnv, options: ArchiveSyncOptions, config: OatConfig): {
    env: NodeJS.ProcessEnv;
    awsProfile: string | undefined;
    awsRegion: string | undefined;
};
export declare function buildArchiveSyncArgs(source: string, target: string, options: ArchiveSyncOptions): string[];
export declare function runArchiveSync(repoRoot: string, source: string, target: string, options: ArchiveSyncOptions, awsEnv: NodeJS.ProcessEnv, dependencies: ProjectArchiveCommandDependencies): Promise<void>;
export interface ArchiveSnapshotEntry {
    dateStamp: string | null;
    projectName: string;
    snapshotName: string;
    source: string;
    target: string;
}
export declare function listArchiveSnapshots(repoRoot: string, projectsRoot: string, s3Uri: string, awsEnv: NodeJS.ProcessEnv, dependencies: ProjectArchiveCommandDependencies): Promise<ArchiveSnapshotEntry[]>;
export declare function compareSnapshotEntries(left: ArchiveSnapshotEntry, right: ArchiveSnapshotEntry): number;
export declare function selectLatestSnapshots(snapshots: ArchiveSnapshotEntry[]): ArchiveSnapshotEntry[];
export declare function readLocalSnapshotName(repoRoot: string, target: string): Promise<string | null>;
export declare function syncArchiveSnapshot(repoRoot: string, snapshot: ArchiveSnapshotEntry, options: ArchiveSyncOptions, awsEnv: NodeJS.ProcessEnv, dependencies: ProjectArchiveCommandDependencies): Promise<boolean>;
export declare function runArchiveSyncCommand(dependencies: ProjectArchiveCommandDependencies, projectName: string | undefined, options: ArchiveSyncOptions, context: CommandContext, commandLabel?: string): Promise<void>;
//# sourceMappingURL=sync-runner.d.ts.map