@chipctx/cli-updater 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bootChecker.d.ts +16 -0
- package/dist/cache.d.ts +8 -0
- package/dist/decideAction.d.ts +9 -0
- package/dist/index.d.ts +10 -0
- package/dist/index.js +1943 -0
- package/dist/interceptor.d.ts +6 -0
- package/dist/runner/npm.d.ts +22 -0
- package/dist/runner/tarball.d.ts +15 -0
- package/dist/types.d.ts +71 -0
- package/dist/updateManager.d.ts +25 -0
- package/dist/versionClient.d.ts +15 -0
- package/package.json +35 -0
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { CacheStore } from "./cache.js";
|
|
2
|
+
import type { AppAdapter } from "./types.js";
|
|
3
|
+
export interface BootCheckerOptions {
|
|
4
|
+
adapter: AppAdapter;
|
|
5
|
+
cache: CacheStore;
|
|
6
|
+
timeoutMs?: number;
|
|
7
|
+
}
|
|
8
|
+
export declare class BootChecker {
|
|
9
|
+
private adapter;
|
|
10
|
+
private cache;
|
|
11
|
+
private timeoutMs;
|
|
12
|
+
private task;
|
|
13
|
+
constructor(opts: BootCheckerOptions);
|
|
14
|
+
init(): Promise<void>;
|
|
15
|
+
private runRefresh;
|
|
16
|
+
}
|
package/dist/cache.d.ts
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { UpdateState } from "./types.js";
|
|
2
|
+
export declare class CacheStore {
|
|
3
|
+
readonly path: string;
|
|
4
|
+
constructor(path: string);
|
|
5
|
+
load(): Promise<UpdateState | null>;
|
|
6
|
+
save(state: UpdateState): Promise<void>;
|
|
7
|
+
markPrompted(target: string, now: number): Promise<void>;
|
|
8
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { Action, Mode, UpdateState, VersionResponse } from "./types.js";
|
|
2
|
+
export interface DecideInput {
|
|
3
|
+
resp: VersionResponse;
|
|
4
|
+
state: UpdateState;
|
|
5
|
+
mode: Mode;
|
|
6
|
+
now: number;
|
|
7
|
+
autoUpdateEnv?: boolean;
|
|
8
|
+
}
|
|
9
|
+
export declare function decideAction(input: DecideInput): Action;
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export declare const VERSION = "0.1.0";
|
|
2
|
+
export * from "./types.js";
|
|
3
|
+
export { CacheStore } from "./cache.js";
|
|
4
|
+
export { VersionClient } from "./versionClient.js";
|
|
5
|
+
export { BootChecker } from "./bootChecker.js";
|
|
6
|
+
export { UpdateManager } from "./updateManager.js";
|
|
7
|
+
export { decideAction } from "./decideAction.js";
|
|
8
|
+
export { interpretResponseHeaders, attachResponseInterceptor, } from "./interceptor.js";
|
|
9
|
+
export { createTarballRunner } from "./runner/tarball.js";
|
|
10
|
+
export { createNpmRunner } from "./runner/npm.js";
|