UNPKG

663 BTypeScriptView Raw
1/// <reference types="node" />
2import { Arch } from "builder-util";
3import { Hash } from "crypto";
4export interface BuildCacheInfo {
5 executableDigest: string;
6}
7export declare class BuildCacheManager {
8 private readonly executableFile;
9 static VERSION: string;
10 readonly cacheDir: string;
11 readonly cacheInfoFile: string;
12 readonly cacheFile: string;
13 cacheInfo: BuildCacheInfo | null;
14 private newDigest;
15 constructor(outDir: string, executableFile: string, arch: Arch);
16 copyIfValid(digest: string): Promise<boolean>;
17 save(): Promise<void>;
18}
19export declare function digest(hash: Hash, files: Array<string>): Promise<string>;