@hot-updater/cli-tools 1.2.0-rc.1 → 1.2.0-rc.11

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.
Files changed (3) hide show
  1. package/dist/index.d.mts +429 -114
  2. package/dist/index.mjs +1436 -981
  3. package/package.json +5 -5
package/dist/index.d.mts CHANGED
@@ -1,6 +1,6 @@
1
1
  import { Readable } from "stream";
2
2
  import { Key as Key$1 } from "node:readline";
3
- import { AnyHotUpdaterPlugin, BundleSigningAdapter, ConfigInput, ConfiguredDatabase, EngineDatabase, HotUpdaterCoreApi, LocalSigningConfig, Migrator, NativeFingerprint, NativeFingerprintOptions, Platform, PluginClientPlugin, RequiredDeep, SchemaGenerator, SecretsAdapter, SigningConfig, StorageAdapter, StorageAdapterWith, StoragePutResult, ToolingDatabase } from "@hot-updater/plugin-core";
3
+ import { AnyHotUpdaterPlugin, ConfigInput, ConfiguredDatabase, EngineDatabase, HotUpdaterCoreApi, Migrator, NativeFingerprint, NativeFingerprintOptions, Platform, PluginClientPlugin, RequiredDeep, SchemaGenerator, SecretRef, SecretsAdapter, SigningConfig, StorageAdapter, StorageAdapterWith, StoragePutResult, ToolingDatabase } from "@hot-updater/plugin-core";
4
4
  import { Readable as Readable$1, Writable } from "node:stream";
5
5
  import { ManifestArchive } from "@hot-updater/protocol";
6
6
  //#region src/BuildLogger.d.ts
@@ -18,13 +18,41 @@ interface BuildFailureSummaryConfig {
18
18
  end: LinePattern;
19
19
  includeEnd: boolean;
20
20
  }[];
21
+ /**
22
+ * Lines never printed, nor counted in the last lines, such as a
23
+ * download's progress meter.
24
+ */
25
+ ignore?: LinePattern[];
26
+ /**
27
+ * How many of the last lines print after the kept ones, for a tool whose
28
+ * error line is followed by its cause. Without it, the last lines print
29
+ * only when no line is kept.
30
+ */
31
+ tail?: number;
32
+ /** The widest a printed line is, cut with `…`: the log has it whole. */
33
+ maxWidth?: number;
34
+ /**
35
+ * The line that ends the tool's report of its error, after which its
36
+ * output is boilerplate, such as a crash report's links: the summary is
37
+ * the kept lines, without the last lines.
38
+ */
39
+ stopAfter?: LinePattern;
21
40
  }
41
+ /**
42
+ * Reads the short phase a live build line shows, such as `Compiling
43
+ * React-Core · 412 files`, from each line of the tool's raw output, or
44
+ * undefined for a line that starts no phase. One reader reads one run.
45
+ */
46
+ type BuildPhaseReader = (line: string) => string | undefined;
22
47
  interface BuildLoggerConfig {
23
48
  logPrefix: string;
24
- /** Lines that should be surfaced in prompt output as important events. */
25
- importantLogPatterns: LinePattern[];
26
- /** Progress stages: stage index advances when corresponding output patterns are observed. */
27
- progressStages: LinePattern[][];
49
+ /**
50
+ * The log file to append to, such as an archive's for its export, instead
51
+ * of a new one.
52
+ */
53
+ logFilePath?: string;
54
+ /** A phase reader for each run. */
55
+ createPhaseReader: () => BuildPhaseReader;
28
56
  /** What a failure prints from the tool's raw output. */
29
57
  failureSummary: BuildFailureSummaryConfig;
30
58
  }
@@ -38,55 +66,67 @@ declare class BuildFailedError extends Error {
38
66
  readonly logPath: string | null;
39
67
  /** The lines of the tool's output the summary printed. */
40
68
  readonly summary: string[];
41
- constructor(message: string, { logPath, summary, cause }: {
69
+ /**
70
+ * What to do about it, such as accepting an agreement, which the summary
71
+ * doesn't say: the one line a command prints after it, or null.
72
+ */
73
+ readonly hint: string | null;
74
+ constructor(message: string, { logPath, summary, hint, cause }: {
42
75
  logPath: string | null;
43
76
  summary: string[];
77
+ hint?: string | null;
44
78
  cause?: unknown;
45
79
  });
46
80
  }
47
81
  declare class BuildLogger {
48
82
  private readonly config;
49
- private state;
50
83
  private logWriter?;
84
+ private step?;
51
85
  private summaryLines;
52
86
  private tailLines;
87
+ private lineCount;
88
+ private stopped;
53
89
  private openBlock?;
54
- private readonly promptProgress;
55
- private readonly stageCount;
56
90
  constructor(config: BuildLoggerConfig);
57
- start(): Promise<void>;
58
91
  /**
59
- * Writes the tool's raw output to the log file and reads its failure
60
- * summary from it, and shows progress from `display`, a formatter's
61
- * output of it such as xcbeautify's, or from the raw output without one.
92
+ * Opens the log, writes `header` to it, such as the tool's command line,
93
+ * which the terminal doesn't show, and starts the step titled `title`.
62
94
  */
63
- processStream(input: Readable, { display }?: {
64
- display?: Readable;
95
+ start({ title, header }: {
96
+ title: string;
97
+ header?: string[];
65
98
  }): Promise<void>;
99
+ /**
100
+ * Writes the tool's raw output to the log file, reads its failure summary
101
+ * from it, and shows its phases on the step's line.
102
+ */
103
+ processStream(input: Readable): Promise<void>;
66
104
  /** The build log, relative to the project, or null without one. */
67
105
  get logPath(): string | null;
106
+ /** The build log's absolute path, or null without one. */
107
+ get logFilePath(): string | null;
68
108
  /**
69
109
  * The lines of the raw output a failure prints: the ones the config's
70
- * `failureSummary` keeps, deduplicated, or the last lines without any.
110
+ * `failureSummary` keeps, deduplicated, with its `tail` unless the output
111
+ * reached `stopAfter`, or the last lines without any.
71
112
  */
72
113
  get failureSummary(): string[];
73
114
  private consumeSummaryStream;
74
115
  private processSummaryLine;
75
116
  private keepSummaryLine;
76
117
  private consumeProgressStream;
77
- private processProgressLine;
118
+ /**
119
+ * Ends the step with `message` and its duration, or, for a failure, as
120
+ * failed, then prints the failure summary and the log's path.
121
+ */
78
122
  stop(message?: string, success?: boolean): void;
79
123
  writeError(error: unknown): void;
80
124
  close(): Promise<void>;
81
- private updateProgress;
82
- private finishRemainingProgress;
83
- private shouldLogLine;
84
125
  /**
85
126
  * Prints the failure summary and the log's path to stderr, so a `--json`
86
127
  * command's stdout stays its JSON.
87
128
  */
88
129
  private showFailureSummary;
89
- private showLogFileLocation;
90
130
  }
91
131
  //#endregion
92
132
  //#region src/appSetup.d.ts
@@ -196,21 +236,79 @@ declare const banner: (version?: string) => string;
196
236
  declare const printBanner: (version?: string) => void;
197
237
  //#endregion
198
238
  //#region src/bundleSigning.d.ts
239
+ /** The secret `signing: secret("bundle-signing-key")` names, which `secrets issue` creates. */
240
+ declare const BUNDLE_SIGNING_KEY_SECRET = "bundle-signing-key";
241
+ /** The command that creates and stores a bundle signing key. */
242
+ declare const ISSUE_SIGNING_KEY_COMMAND = "npx hot-updater secrets issue bundle-signing-key";
243
+ /** The command that stores a bundle signing key you have. */
244
+ declare const PUT_SIGNING_KEY_COMMAND = "npx hot-updater secrets put bundle-signing-key <key.pem>";
245
+ /** The command that stores the bundle signing key you have as `name`. */
246
+ declare const bundleSigningPutCommand: (name: string) => string;
247
+ /** What deploy and doctor say when the config sets no `signing`. */
248
+ declare const UNSIGNED_BUNDLES_WARNING = "Bundles are unsigned.";
249
+ /** The next step after `UNSIGNED_BUNDLES_WARNING`. */
250
+ declare const UNSIGNED_BUNDLES_NEXT_STEP = "To sign them, run:";
251
+ /** What deploy and doctor say when `signing` is no shape it takes. */
252
+ declare const INVALID_SIGNING_MESSAGE = "signing takes secret(\"bundle-signing-key\").";
253
+ /** The next step after `INVALID_SIGNING_MESSAGE`. */
254
+ declare const INVALID_SIGNING_NEXT_STEP = "Store your key:";
255
+ /**
256
+ * The config's `signing`, read without reading any key:
257
+ * - `on`: signs, with the private key from a secret or a file. The
258
+ * shorthand `secret("<name>")` is `{ enabled: true, privateKey }`;
259
+ * - `off`: `{ enabled: false }`, which turns signing off on purpose;
260
+ * - `unsigned`: no `signing`, which deploy and doctor warn about;
261
+ * - `invalid`: any other value, such as a signing adapter of earlier
262
+ * releases, which deploy refuses rather than deploy unsigned.
263
+ */
264
+ type BundleSigningState = {
265
+ readonly status: "on";
266
+ readonly key: {
267
+ readonly secret: string;
268
+ } | {
269
+ readonly privateKeyPath: string;
270
+ };
271
+ } | {
272
+ readonly status: "off";
273
+ } | {
274
+ readonly status: "unsigned";
275
+ } | {
276
+ readonly status: "invalid";
277
+ readonly message: string;
278
+ };
279
+ declare const readBundleSigningState: (signing: unknown) => BundleSigningState;
280
+ /** The `secret()` the config's `signing` reads its private key from, if any. */
281
+ declare const bundleSigningSecretRef: (signing: unknown) => SecretRef | undefined;
282
+ /**
283
+ * A bundle signing failure whose message the CLI prints as it is: it names
284
+ * the secret and the next step, and quotes no key material.
285
+ */
286
+ declare class BundleSigningKeyError extends Error {
287
+ constructor(message: string, options?: ErrorOptions);
288
+ }
199
289
  interface BundleSigningSession {
200
- readonly name: string;
201
290
  readonly publicKey: string;
202
291
  readonly signFileHash: (fileHash: string) => Promise<string>;
203
292
  }
204
293
  declare const readBundleSigningPublicKeyFile: (publicKeyPath: string, options?: {
205
294
  readonly cwd?: string;
206
295
  }) => Promise<string>;
207
- declare const prepareBundleSigning: (signing: SigningConfig | undefined, options?: {
208
- readonly cwd?: string;
209
- }) => Promise<BundleSigningSession | null>;
210
- /** Resolves the public identity of the configured bundle signer. */
211
- declare const getBundleSigningPublicKey: (signing: SigningConfig | undefined, options?: {
296
+ interface BundleSigningOptions {
212
297
  readonly cwd?: string;
213
- }) => Promise<string | null>;
298
+ /** The config's `secrets` adapter; the configured one by default. */
299
+ readonly secrets?: SecretsAdapter;
300
+ }
301
+ /**
302
+ * Prepares the run's bundle signing: the public key the app must embed, and
303
+ * a signer of SHA-256 file hashes that signs each hash once. Null when
304
+ * `signing` is omitted or `{ enabled: false }`.
305
+ */
306
+ declare const prepareBundleSigning: (signing: unknown, options?: BundleSigningOptions) => Promise<BundleSigningSession | null>;
307
+ /**
308
+ * The public key of the configured bundle signing key, in SPKI PEM; null
309
+ * when `signing` signs nothing.
310
+ */
311
+ declare const getBundleSigningPublicKey: (signing: unknown, options?: BundleSigningOptions) => Promise<string | null>;
214
312
  //#endregion
215
313
  //#region src/ConfigBuilder.d.ts
216
314
  type BuildType = "bare" | "rock" | "expo";
@@ -364,8 +462,8 @@ declare const CREDENTIAL_ENV_NAMES: {
364
462
  //#endregion
365
463
  //#region src/credentialResolver.d.ts
366
464
  /**
367
- * The build credentials the CLI resolves by name. Deploy credentials reach
368
- * the config's adapters through `secretEnv`.
465
+ * The build credentials the CLI resolves by name. Adapter credentials are
466
+ * `secret()`s the adapters call.
369
467
  */
370
468
  interface Credentials {
371
469
  /** App Store Connect API key, for automatic signing and uploads. */
@@ -412,40 +510,52 @@ interface CredentialResolver {
412
510
  dispose(): Promise<void>;
413
511
  }
414
512
  /**
415
- * The sentence every "credential unavailable" message ends with: the
416
- * environment variables that provide `kind` whatever the secrets adapter.
513
+ * A command to print, broken at spaces with ` \` once a line would pass
514
+ * 74 columns, each continuation indented two spaces, so a terminal never
515
+ * wraps it mid-word and it still pastes as one command.
417
516
  */
418
- declare const credentialOverrideHint: (kind: CredentialKind) => string;
517
+ declare const formatCommand: (command: string) => string;
518
+ /** The credentials Hot Updater issues itself after a sign-in. */
519
+ type IssuedCredentialKind = "asc-api-key";
520
+ /** The credentials `secrets put <name> <file>` stores from one file. */
521
+ type FileCredentialKind = Exclude<CredentialKind, IssuedCredentialKind>;
419
522
  /**
420
- * The command that stores a credential of `kind` you have as `name` through
421
- * the config's `secrets` adapter, from its files.
523
+ * The command that stores the file you have as `name`: the service
524
+ * account's JSON key, or the app's upload keystore. `--kind` is named only
525
+ * for a name that is not the kind.
422
526
  */
423
- declare const credentialPutCommand: (kind: CredentialKind, name?: string) => string;
424
- /** The credentials Hot Updater issues itself after a sign-in. */
425
- type IssuedCredentialKind = Exclude<CredentialKind, "android-keystore">;
527
+ declare const credentialPutCommand: (kind: FileCredentialKind, name?: string) => string;
426
528
  /**
427
- * The command that signs in once, at a terminal, and stores the key Hot
428
- * Updater issues as `name`: an App Store Connect API key after an Apple
429
- * Account sign-in, a Play service account after a Google one.
529
+ * The command that stores the key Hot Updater issues as `name`: an App
530
+ * Store Connect API key after an Apple Account sign-in, and an upload
531
+ * keystore it creates.
430
532
  */
431
- declare const credentialIssueCommand: (kind: IssuedCredentialKind, name?: string) => string;
533
+ declare const credentialIssueCommand: (kind: CredentialKind, name?: string) => string;
432
534
  /** The command group of each issued kind's shortcut, `<group> login`. */
433
535
  declare const CREDENTIAL_LOGIN_GROUPS: {
434
536
  readonly "asc-api-key": "apple";
435
- readonly "play-service-account": "google-play";
436
537
  };
437
538
  /**
438
539
  * The command people meet first that issues `kind` as `name`: its shortcut,
439
- * `apple login` for an App Store Connect API key or `google-play login`
440
- * for a Play service account, which takes nothing and stores the kind's
441
- * own name; for another name, `credentialIssueCommand`.
540
+ * `apple login` for an App Store Connect API key, which takes nothing and
541
+ * stores the kind's own name; for another name, `credentialIssueCommand`.
442
542
  */
443
543
  declare const credentialLoginCommand: (kind: IssuedCredentialKind, name?: string) => string;
444
544
  /**
445
545
  * The command that stores a missing credential of `kind` as `name`: the
446
- * keystore you have, or the key Hot Updater issues after a sign-in.
546
+ * key Hot Updater issues after an Apple sign-in, or the file you have.
447
547
  */
448
548
  declare const credentialStoreCommand: (kind: CredentialKind, name?: string) => string;
549
+ /**
550
+ * Why `secrets` has no `name`, and the command that brings the existing
551
+ * one in, never one that creates another: a signing key may already be
552
+ * trusted by a shipped app or a store. Under a team's adapter the name or
553
+ * the access is wrong; under `localSecrets()` this machine lacks it.
554
+ */
555
+ declare const describeMissingSecret: (secrets: SecretsAdapter, name: string, { action, command }: {
556
+ action?: string;
557
+ command: string;
558
+ }) => string;
449
559
  declare class CredentialUnavailableError extends Error {
450
560
  readonly kind: CredentialKind;
451
561
  /** The environment variables that can provide this credential. */
@@ -581,6 +691,14 @@ declare const createHotUpdaterConfigScaffoldFromBuilder: (builder: ConfigBuilder
581
691
  * existing config with the scaffold's build, storage, database, plugins, and
582
692
  * helpers merged in, keeping the project's own settings.
583
693
  */
694
+ /**
695
+ * Whether `hot-updater.config.ts` in `cwd` sets a team `secrets` adapter,
696
+ * read from its text: a `secrets` property other than `localSecrets(...)`,
697
+ * or a config whose shape init can't read. False without the file. Init
698
+ * reads the store through the loaded config, so one that sets a store but
699
+ * doesn't load must be fixed first.
700
+ */
701
+ declare const configSetsTeamSecrets: (cwd: string) => Promise<boolean>;
584
702
  declare const writeHotUpdaterConfig: (scaffold: HotUpdaterConfigScaffold, filePath?: string) => Promise<WriteHotUpdaterConfigResult>;
585
703
  /**
586
704
  * Writes hot-updater.config.ts and says what it did. `settings` names the
@@ -593,6 +711,30 @@ declare const writeHotUpdaterFiles: (scaffold: HotUpdaterConfigScaffold, { cwd,
593
711
  }) => Promise<{
594
712
  readonly config: WriteHotUpdaterConfigResult;
595
713
  }>;
714
+ /** What `addSigningSecretToConfigText` did. */
715
+ type AddSigningSecretResult = {
716
+ readonly status: "added";
717
+ readonly text: string;
718
+ } |
719
+ /** The config already sets `signing`, which stays as it is. */
720
+ {
721
+ readonly status: "kept";
722
+ } |
723
+ /** The file is no `export default defineConfig({ ... })` it can edit. */
724
+ {
725
+ readonly status: "unsupported";
726
+ };
727
+ /**
728
+ * The config text with `signing: secret("<name>")` added, and `secret` in
729
+ * its `hot-updater` import, once. A config that sets `signing` in any form,
730
+ * such as 1.1's `{ enabled: true, privateKeyPath }`, is kept.
731
+ */
732
+ declare const addSigningSecretToConfigText: (text: string, name: string) => AddSigningSecretResult;
733
+ /**
734
+ * Adds `signing: secret("<name>")` to `hot-updater.config.ts` in `cwd`, as
735
+ * `addSigningSecretToConfigText` does. Without the file, nothing is written.
736
+ */
737
+ declare const addSigningSecretToConfig: (cwd: string, name: string) => Promise<AddSigningSecretResult["status"] | "missing">;
596
738
  //#endregion
597
739
  //#region src/hotUpdaterEnv.d.ts
598
740
  type HotUpdaterInitEnv = {
@@ -601,7 +743,12 @@ type HotUpdaterInitEnv = {
601
743
  readonly managedEnv: Readonly<Record<string, string>>;
602
744
  };
603
745
  declare const getHotUpdaterInitInputEnv: ({ env, managedEnv }: HotUpdaterInitEnv, nonInteractive: boolean) => Readonly<Record<string, string>>;
604
- declare const readHotUpdaterInitEnv: (cwd: string, envFile?: string) => Promise<HotUpdaterInitEnv>;
746
+ /**
747
+ * Init's inputs: `.env.hotupdater` (`managedEnv`), with `envFile`'s over
748
+ * it (`env`). `secretsEnv`, the credentials init read from a team secrets
749
+ * store, sits under both, as values the file would hold.
750
+ */
751
+ declare const readHotUpdaterInitEnv: (cwd: string, envFile?: string, secretsEnv?: Readonly<Record<string, string>>) => Promise<HotUpdaterInitEnv>;
605
752
  declare const getHotUpdaterEnvValue: (env: Readonly<Record<string, string>>, key: string) => string | undefined;
606
753
  /**
607
754
  * An env file's variables as `process.loadEnvFile` sets them, the way
@@ -611,6 +758,11 @@ declare const getHotUpdaterEnvValue: (env: Readonly<Record<string, string>>, key
611
758
  declare const parseLoadedEnv: (content: string) => Readonly<Record<string, string>>;
612
759
  /** `cwd`'s `.env.hotupdater` as the config loads it; empty when there is none. */
613
760
  declare const readLoadedHotUpdaterEnv: (cwd: string) => Promise<Readonly<Record<string, string>>>;
761
+ /**
762
+ * `file`, an env file a command was given, relative to `cwd`, as
763
+ * `parseLoadedEnv` reads it; a file that can't be read is refused by name.
764
+ */
765
+ declare const readLoadedEnvFile: (file: string, cwd: string) => Promise<Readonly<Record<string, string>>>;
614
766
  //#endregion
615
767
  //#region src/HotUpdateDirUtil.d.ts
616
768
  declare const HotUpdateDirUtil: {
@@ -673,6 +825,13 @@ type InitProviderInputsDefinition = Readonly<Record<string, InitProviderInputDef
673
825
  type InitProviderDefinition<TInputs extends InitProviderInputsDefinition = InitProviderInputsDefinition> = {
674
826
  readonly inputs: TInputs;
675
827
  readonly label: string;
828
+ /**
829
+ * The variables of the credentials the config init writes reads with
830
+ * `secret()`, such as an API token. With a team `secrets` adapter, init
831
+ * stores them there with the app's API key, and reads one the
832
+ * environment and the env file lack from it.
833
+ */
834
+ readonly secrets?: readonly string[];
676
835
  };
677
836
  declare const defineInitProvider: <const TInputs extends InitProviderInputsDefinition>(provider: InitProviderDefinition<TInputs>) => InitProviderDefinition<TInputs>;
678
837
  declare const shouldAutoSelectOnlyInitResource: ({ availableResourceCount, savedIdentifier }: {
@@ -711,6 +870,12 @@ declare const getInitProviderEnvVars: <TInputs extends InitProviderInputsDefinit
711
870
  type RunInitOptions = {
712
871
  readonly build: BuildType;
713
872
  readonly envFile?: string;
873
+ /**
874
+ * Credentials the environment and the env files lack, read from the
875
+ * config's team `secrets` adapter (`InitProviderDefinition.secrets`):
876
+ * init reads them as if `.env.hotupdater` held them.
877
+ */
878
+ readonly secretsEnv?: Readonly<Record<string, string>>;
714
879
  };
715
880
  declare class InitError extends Error {
716
881
  readonly name: string;
@@ -879,6 +1044,8 @@ declare const reactNativeCliFingerprint: (cwd: string, options: NativeFingerprin
879
1044
  type HotUpdaterLogWriter = {
880
1045
  logFilePath: string | null;
881
1046
  writeStream: (input: Readable) => Promise<void>;
1047
+ /** Writes lines of its own, such as the command a build runs. */
1048
+ writeLines: (lines: readonly string[]) => void;
882
1049
  writeError: (error: unknown) => void;
883
1050
  close: () => Promise<void>;
884
1051
  };
@@ -888,17 +1055,6 @@ declare const createLogWriter: ({ prefix, logFilePath }: {
888
1055
  logFilePath?: string;
889
1056
  }) => Promise<HotUpdaterLogWriter>;
890
1057
  //#endregion
891
- //#region src/localBundleSigning.d.ts
892
- /** The secret `keys generate --secret` stores the private key as by default. */
893
- declare const DEFAULT_SIGNING_KEY_SECRET = "bundle-signing-key";
894
- /** Local signing enabled, with its private key from a file or a secret. */
895
- type EnabledLocalSigningConfig = Extract<LocalSigningConfig, {
896
- enabled: true;
897
- }>;
898
- declare const normalizeSigningConfig: (signing: SigningConfig | undefined, { secrets }?: {
899
- readonly secrets?: SecretsAdapter;
900
- }) => BundleSigningAdapter | EnabledLocalSigningConfig | undefined;
901
- //#endregion
902
1058
  //#region src/loadConfig.d.ts
903
1059
  type HotUpdaterConfigOptions = {
904
1060
  platform: Platform;
@@ -911,11 +1067,16 @@ type ConfigResponse = RequiredDeep<Omit<ConfigInput, "database" | "storage" | "p
911
1067
  storage?: StorageAdapter;
912
1068
  /** The plugins the server runs; none when the config lists none. */
913
1069
  plugins: readonly AnyHotUpdaterPlugin[];
914
- signing?: ReturnType<typeof normalizeSigningConfig>;
915
1070
  /**
916
- * Where `secret:` references and issued keys are read and stored: the
917
- * config's adapter with `localSecrets()`'s store after it (`withLocalKeyStore`),
918
- * or `localSecrets()` when it sets none.
1071
+ * As the config sets it, read only when a command signs: deploy refuses a
1072
+ * value it doesn't take (`readBundleSigningState`), and other commands,
1073
+ * such as the `secrets put` that fixes it, still load the config.
1074
+ */
1075
+ signing?: SigningConfig;
1076
+ /**
1077
+ * Where `secret()` references and issued keys are read and stored: the
1078
+ * config's adapter alone, or `localSecrets()` when it sets none
1079
+ * (`resolveSecretsAdapter`).
919
1080
  */
920
1081
  secrets: SecretsAdapter;
921
1082
  };
@@ -932,6 +1093,13 @@ declare const loadPlatformConfigs: <TPlatform extends Platform>(platforms: reado
932
1093
  readonly platform: TPlatform;
933
1094
  readonly config: ConfigResponse;
934
1095
  }[]>;
1096
+ /**
1097
+ * The names the config's `secret()`s reference for its adapters, such as
1098
+ * `HOT_UPDATER_CLOUDFLARE_API_TOKEN`, in the order the config created
1099
+ * them: every name but those of build credentials, which `doctor` lists
1100
+ * by field.
1101
+ */
1102
+ declare const getDeploySecretNames: (config: ConfigResponse) => readonly string[];
935
1103
  //#endregion
936
1104
  //#region src/serverDefinition.d.ts
937
1105
  /** A plugin's endpoint on a server's `handlers.client`. */
@@ -1051,6 +1219,30 @@ declare const makeEnv: (newEnvVars: Record<string, EnvVarValue>, filePath?: stri
1051
1219
  readonly expectedContent?: string;
1052
1220
  }) => Promise<string>;
1053
1221
  //#endregion
1222
+ //#region src/messageLines.d.ts
1223
+ /**
1224
+ * The widest line of a message the CLI prints: clack puts it after its
1225
+ * 3-column gutter (`│ `), and the whole line stays within 76 columns.
1226
+ */
1227
+ declare const MESSAGE_WIDTH = 73;
1228
+ /**
1229
+ * The columns `text` takes in a terminal, without its colors: `│`, `■`,
1230
+ * and `…` take one each, though each is several bytes.
1231
+ */
1232
+ declare const displayWidth: (text: string) => number;
1233
+ /**
1234
+ * `text` cut to `width` display columns, with `…` for the rest, never
1235
+ * inside a character: a cut line loses its colors.
1236
+ */
1237
+ declare const truncateLine: (text: string, width: number) => string;
1238
+ /**
1239
+ * A message of `lines`, each at most `MESSAGE_WIDTH` columns, broken at
1240
+ * spaces, so a name, a path, or a list it embeds never widens a line. A
1241
+ * word longer than a line, such as a URL or a path, gets a line of its
1242
+ * own. Lines that fit, such as an indented command, stay as they are.
1243
+ */
1244
+ declare const fitMessage: (lines: readonly string[]) => string;
1245
+ //#endregion
1054
1246
  //#region src/minBundleId.d.ts
1055
1247
  /**
1056
1248
  * The MIN_BUNDLE_ID a native build compiles in, which is also the ID of its
@@ -2298,7 +2490,7 @@ declare const readPackageUp: <T = unknown>(cwd: string) => Promise<ReadPackageUp
2298
2490
  * interpreter reads (`NODE_*` but `NODE_ENV`, `PATH`, `LD_*`, `DYLD_*`,
2299
2491
  * `BASH_ENV`, `ENV`, `GIT_*`, `npm_config_*`, the JVM's, Gradle's, Ruby's,
2300
2492
  * Python's, and Perl's options), or one Hot Updater reads its credentials
2301
- * from. `secretEnv` refuses these names, and so does every environment the
2493
+ * from. `secret()` refuses these names, and so does every environment the
2302
2494
  * CLI gives a child process from resolved secrets.
2303
2495
  */
2304
2496
  declare const isReservedVariableName: (name: string) => boolean;
@@ -2388,14 +2580,16 @@ declare const readLocalKey: (name: string, cwd: string) => Promise<string | unde
2388
2580
  declare const writeLocalKey: (name: string, value: string, cwd: string) => Promise<string>;
2389
2581
  //#endregion
2390
2582
  //#region src/secrets.d.ts
2391
- /** Whether `name` is a secret's name, as `secret:<name>` takes one. */
2583
+ /** Whether `name` is a secret's name, as `secret("<name>")` takes one. */
2392
2584
  declare const isSecretName: (name: string) => boolean;
2585
+ /** Whether `value` is a `secret("<name>")` reference. */
2586
+ declare const isSecretRef: (value: unknown) => value is SecretRef;
2393
2587
  /**
2394
- * The secret name a config's `secret:<name>` reference names, such as
2395
- * `release-keystore` for `"secret:release-keystore"`. `field` is the config
2396
- * field the reference is in, which the error names.
2588
+ * The secret name a config's `secret("<name>")` names, such as
2589
+ * `release-keystore` for `secret("release-keystore")`. `field` is the
2590
+ * config field it is in, which the error names.
2397
2591
  */
2398
- declare const parseSecretReference: (reference: string, field: string) => string;
2592
+ declare const parseSecretReference: (reference: unknown, field: string) => string;
2399
2593
  /**
2400
2594
  * The environment variable the default store reads a secret from: a name
2401
2595
  * that is a variable name already, such as `CLOUDFLARE_API_TOKEN`, as it
@@ -2415,9 +2609,9 @@ declare const LOCAL_SECRETS_NAME = "localSecrets";
2415
2609
  * `~/.hot-updater/secrets/<project-key>/<name>.json`; `set` writes that
2416
2610
  * file, 0600 in a 0700 directory, outside the project, so it survives
2417
2611
  * `node_modules` and is never committed. `HOT_UPDATER_HOME` moves
2418
- * `~/.hot-updater`. The project key is the same for every clone of one app
2419
- * on a machine (its `origin` remote and its directory in the repository),
2420
- * so another machine signs in and issues a key of its own.
2612
+ * `~/.hot-updater`. The project key hashes the checkout's real path
2613
+ * (`getProjectKey`), so each clone of an app has its own directory, and
2614
+ * another clone or machine signs in and issues a key of its own.
2421
2615
  *
2422
2616
  * @example
2423
2617
  * export default defineConfig({ secrets: localSecrets(), ... });
@@ -2429,38 +2623,43 @@ interface LocalSecretsOptions {
2429
2623
  * each, such as `~/.hot-updater/secrets/my-app`: `~` is the home
2430
2624
  * directory, and a relative path is the project's. A directory in a git
2431
2625
  * work tree must be one git ignores. Defaults to
2432
- * `~/.hot-updater/secrets/<project-key>`, whose key is the same for every
2433
- * clone of the app on a machine (`getProjectKey`).
2626
+ * `~/.hot-updater/secrets/<project-key>`, whose key hashes the
2627
+ * checkout's real path, one per clone (`getProjectKey`).
2434
2628
  */
2435
2629
  readonly path?: string;
2436
2630
  }
2437
2631
  /**
2438
- * The config's `secrets` adapter with `localSecrets()`'s store after it:
2439
- * `get` reads each name the adapter does not hold from
2440
- * `~/.hot-updater/secrets/<project-key>/<name>.json`, and `set` stores there
2441
- * when the adapter stores nothing. Without an adapter, it is
2442
- * `localSecrets()` itself. Keys Hot Updater issues, and credentials
2443
- * `secrets put` imports, are reused by the next build on this machine with
2444
- * no step in between.
2632
+ * The `secrets` adapter a config load uses: the config's own adapter as it
2633
+ * is, with no store on this machine under it, or `localSecrets()` when the
2634
+ * config sets none.
2445
2635
  */
2446
- declare const withLocalKeyStore: (configured?: SecretsAdapter) => SecretsAdapter;
2636
+ declare const resolveSecretsAdapter: (configured?: SecretsAdapter) => SecretsAdapter;
2447
2637
  /**
2448
- * The `localSecrets()` store `secrets` reads after its adapter, and stores
2449
- * in when the adapter stores nothing: `localSecrets({ path })`'s, else the
2450
- * default one.
2638
+ * `localSecrets()`'s store, for `localSecrets()` itself; undefined for any
2639
+ * other adapter, which keeps nothing on this machine.
2451
2640
  */
2452
- declare const getLocalSecretsStore: (secrets: SecretsAdapter) => LocalSecretsStore;
2641
+ declare const getLocalSecretsStore: (secrets: SecretsAdapter) => LocalSecretsStore | undefined;
2453
2642
  /**
2454
- * The config's own `secrets` adapter, without `localSecrets()`'s store
2455
- * after it: undefined for `localSecrets()`, and when the config sets none.
2456
- * `secretEnv` reads deploy credentials from it.
2643
+ * The config's own `secrets` adapter: undefined for `localSecrets()`,
2644
+ * which is the adapter when the config sets none. A called `secret()` reads
2645
+ * from it.
2457
2646
  */
2458
2647
  declare const getConfiguredAdapter: (secrets: SecretsAdapter) => SecretsAdapter | undefined;
2459
2648
  /**
2460
- * Where `secrets.set` stores `name`, for messages: the config's adapter
2461
- * when it stores values, else `localSecrets()`'s file.
2649
+ * Where `secrets.set` stores `name`, for messages: the config's adapter,
2650
+ * else `localSecrets()`'s file.
2462
2651
  */
2463
2652
  declare const describeStoredSecret: (secrets: SecretsAdapter, name: string) => string;
2653
+ /**
2654
+ * `name`'s value, read in the order `secrets.get` reads it, with the one
2655
+ * place it came from, for messages: the config's adapter
2656
+ * (`describeSecret`), the environment variable `localSecrets()` reads
2657
+ * first, or `localSecrets()`'s file. Undefined when nothing holds it.
2658
+ */
2659
+ declare const readSecretWithSource: (secrets: SecretsAdapter, name: string, cwd: string) => Promise<{
2660
+ readonly value: string;
2661
+ readonly source: string;
2662
+ } | undefined>;
2464
2663
  /**
2465
2664
  * Whether a key `secrets` stores stays on this machine: it is `localSecrets()`,
2466
2665
  * whose files no other machine reads.
@@ -2468,56 +2667,172 @@ declare const describeStoredSecret: (secrets: SecretsAdapter, name: string) => s
2468
2667
  declare const keepsKeysOnThisMachine: (secrets: SecretsAdapter) => boolean;
2469
2668
  /**
2470
2669
  * The `secrets` adapter of one config load, filled once the config it
2471
- * evaluates resolves: each `secretEnv` the evaluation creates reads from it.
2670
+ * evaluates resolves: each `secret()` the evaluation creates reads from it,
2671
+ * and adds its name to `names`.
2472
2672
  */
2473
2673
  interface SecretsScope {
2474
2674
  secrets?: SecretsAdapter;
2675
+ names?: Set<string>;
2676
+ /**
2677
+ * The names build credentials reference, such as `signing.keystore`'s,
2678
+ * which the CLI reads for their kind: the batched read leaves them out.
2679
+ */
2680
+ buildNames?: Set<string>;
2681
+ /** The one read of the scope's other names, once a `secret()` is called. */
2682
+ read?: Promise<Readonly<Record<string, string | undefined>>>;
2475
2683
  }
2476
2684
  /**
2477
2685
  * Evaluates a config, the file or a config function, with `scope` as the
2478
- * scope of every `secretEnv` it creates, so each reads the `secrets` of the
2686
+ * scope of every `secret()` it creates, so each reads the `secrets` of the
2479
2687
  * config that created it, whatever config loads after. It is kept on
2480
2688
  * `globalThis`: the config file loads its own copy of Hot Updater's modules.
2481
2689
  */
2482
2690
  declare const withSecretsScope: <T>(scope: SecretsScope, evaluate: () => Promise<T> | T) => Promise<T>;
2483
2691
  /**
2484
2692
  * Makes `secrets` the adapter a credential resolver reads from by default,
2485
- * and a `secretEnv` created outside any config load, as `loadConfig` does
2693
+ * and a `secret()` created outside any config load, as `loadConfig` does
2486
2694
  * with the config's. It is kept on `globalThis`: the config file loads Hot
2487
2695
  * Updater's modules again, as its own copies.
2488
2696
  */
2489
2697
  declare const setConfiguredSecrets: (secrets: SecretsAdapter) => void;
2490
2698
  /**
2491
- * The config's `secrets` adapter with `localSecrets()`'s store after it
2492
- * (`withLocalKeyStore`), `localSecrets()` until a config loads.
2699
+ * The config's `secrets` adapter (`resolveSecretsAdapter`), `localSecrets()`
2700
+ * until a config loads.
2493
2701
  */
2494
2702
  declare const getConfiguredSecrets: () => SecretsAdapter;
2703
+ /**
2704
+ * `names` from `secrets` in one `get`. A read that fails names the secrets
2705
+ * and the adapter, with the adapter's own error on the next line, such as
2706
+ * `EACCES: permission denied, open '<file>'`.
2707
+ */
2708
+ declare const readSecrets: (secrets: SecretsAdapter, names: readonly string[], cwd: string) => Promise<Readonly<Record<string, string | undefined>>>;
2495
2709
  /** Where an adapter keeps `name`, for messages. */
2496
2710
  declare const describeSecret: (secrets: SecretsAdapter, name: string) => string;
2497
2711
  /**
2498
- * Environment variables from the `secrets` adapter of the config that
2499
- * creates it, as a function a config calls when an adapter needs them, so loading
2500
- * `hot-updater.config.ts` reads no secret. Each name set in the environment
2501
- * or `.env.hotupdater` wins; the others are read from the config's
2502
- * `secrets` adapter in one call, and without one they must be set. The values go only to the caller: they are never set in
2503
- * `process.env`, and are masked in the CLI's logs. Names a loader or
2504
- * interpreter reads, such as `NODE_OPTIONS`, are refused.
2712
+ * `secret("<name>")`: the secret `name` in `hot-updater.config.ts`, for a
2713
+ * build credential, such as `signing.keystore`, or any adapter credential,
2714
+ * which calls it on first use, so loading the config reads no secret.
2715
+ * Called, it reads `name`'s variable (`secretVariableName`) in the
2716
+ * environment or `.env.hotupdater`, else the config's `secrets` adapter:
2717
+ * the first call reads every name the config's `secret()`s reference and
2718
+ * the environment doesn't set, in one `get`. With `localSecrets()`, the
2719
+ * variable must be set: its files hold only the keys Hot Updater stores.
2720
+ * Values are masked in the CLI's logs and never set in `process.env`.
2721
+ * Names a loader or interpreter reads, such as `NODE_OPTIONS`, are refused.
2722
+ * A server passes its own environment's values instead.
2505
2723
  *
2506
2724
  * @example
2507
- * const deploy = secretEnv(["S3_ACCESS_KEY_ID", "S3_SECRET_ACCESS_KEY"]);
2508
- * s3Storage({
2725
+ * r2Storage({
2509
2726
  * bucketName: "bundles",
2510
- * region: "us-east-1",
2511
- * credentials: async () => {
2512
- * const env = await deploy();
2513
- * return {
2514
- * accessKeyId: env.S3_ACCESS_KEY_ID,
2515
- * secretAccessKey: env.S3_SECRET_ACCESS_KEY,
2516
- * };
2727
+ * accountId: "<account-id>",
2728
+ * credentials: {
2729
+ * accessKeyId: secret("HOT_UPDATER_CLOUDFLARE_R2_ACCESS_KEY_ID"),
2730
+ * secretAccessKey: secret("HOT_UPDATER_CLOUDFLARE_R2_SECRET_ACCESS_KEY"),
2517
2731
  * },
2518
2732
  * });
2519
2733
  */
2520
- declare const secretEnv: <const TName extends string>(names: readonly TName[]) => (() => Promise<Readonly<Record<TName, string>>>);
2734
+ declare const secret: (name: string) => SecretRef;
2735
+ //#endregion
2736
+ //#region src/step.d.ts
2737
+ type Output = Writable & {
2738
+ isTTY?: boolean;
2739
+ columns?: number;
2740
+ };
2741
+ /** `4.2s`, `38s`, `6m41s`, `1h02m`. */
2742
+ declare const formatDuration: (ms: number) => string;
2743
+ /**
2744
+ * `message` with `duration` at the right edge of a step's line, the message
2745
+ * cut with `…` when the line would be wider.
2746
+ */
2747
+ declare const withDuration: (message: string, ms: number, width?: number) => string;
2748
+ /** How a finished step's line is marked. */
2749
+ type StepLevel = "step" | "info" | "warn";
2750
+ /**
2751
+ * A step of a command that takes a while, shown as one line: at a terminal,
2752
+ * a spinner whose line shows the step's current detail and its elapsed
2753
+ * time, which ends as the step's line with its duration; elsewhere, such as
2754
+ * in CI, only that last line.
2755
+ *
2756
+ * While it runs, what other code prints through `p` is held: a spinner's
2757
+ * messages become the step's detail, and logs print after the step's line,
2758
+ * but an error ends the step as failed first and prints at once, since the
2759
+ * process may exit right after it.
2760
+ */
2761
+ interface Step {
2762
+ /** Starts the step, once: nothing shows before. */
2763
+ start(): Step;
2764
+ /** Shows `detail` after the title on the live line, or the title alone. */
2765
+ update(detail?: string): void;
2766
+ /**
2767
+ * Ends the step with `message`, the title by default, and its duration,
2768
+ * marked as a finished step or with `level`.
2769
+ */
2770
+ succeed(message?: string, options?: {
2771
+ level?: StepLevel;
2772
+ }): void;
2773
+ /** Ends the step as failed, with `message` or `<title> failed`. */
2774
+ fail(message?: string): void;
2775
+ /** Milliseconds since it started, or 0 before. */
2776
+ readonly elapsedMs: number;
2777
+ /** Whether it started and has not ended. */
2778
+ readonly active: boolean;
2779
+ }
2780
+ interface StepOptions {
2781
+ output?: Output;
2782
+ }
2783
+ /**
2784
+ * A step that shows nothing until `start()`. A step created while another
2785
+ * runs is part of it: its title and detail become the running step's detail,
2786
+ * and its failure fails the running step.
2787
+ */
2788
+ declare const createStep: (title: string, { output }?: StepOptions) => Step;
2789
+ /**
2790
+ * Ends the running step as failed, if one runs, before a command prints
2791
+ * its error.
2792
+ */
2793
+ declare const failActiveStep: () => void;
2794
+ /** A step, started. */
2795
+ declare const startStep: (title: string, options?: StepOptions) => Step;
2796
+ /**
2797
+ * Runs `run` as a step titled `title`, which ends with `done(result)`, or as
2798
+ * failed when `run` throws.
2799
+ */
2800
+ declare const withStep: <T>(title: string, run: (step: Step) => Promise<T>, done?: (result: T) => string, options?: StepOptions) => Promise<T>;
2801
+ //#endregion
2802
+ //#region src/teamSecrets.d.ts
2803
+ /**
2804
+ * The client API key the managed servers' `apiKeys()` gives an app, which
2805
+ * init saves (`API_KEY_ENV` in `@hot-updater/plugin-api-keys`). The config
2806
+ * never reads it; a team store shares it with the deploy credentials, so a
2807
+ * teammate's init registers the same key again rather than a new one.
2808
+ */
2809
+ declare const MANAGED_CLIENT_CREDENTIAL_ENV = "HOT_UPDATER_API_KEY";
2810
+ /**
2811
+ * The config's own `secrets` adapter, the team store: undefined when the
2812
+ * config sets none, which is `localSecrets()`. Loading the config runs its
2813
+ * `process.loadEnvFile(".env.hotupdater")`, which init must not see, so
2814
+ * `process.env` is restored after it.
2815
+ */
2816
+ declare const loadTeamSecrets: () => Promise<SecretsAdapter | undefined>;
2817
+ /**
2818
+ * `names` neither the environment nor `env`, init's env files, sets, read
2819
+ * from `secrets` in one call: the values a teammate's init, or a run after
2820
+ * the file's lines were deleted, replays with.
2821
+ */
2822
+ declare const readMissingFromTeamSecrets: (secrets: SecretsAdapter, names: readonly string[], { env, cwd }: {
2823
+ readonly env: Readonly<Record<string, string>>;
2824
+ readonly cwd: string;
2825
+ }) => Promise<Readonly<Record<string, string>>>;
2826
+ /**
2827
+ * Stores each of `names` that `envFile`, `.env.hotupdater` by default,
2828
+ * holds through `secrets`, then reads them back in one call. Only the file
2829
+ * is read, never the environment. The file is left as it is. Returns the
2830
+ * names stored, in the order of `names`; throws when the adapter reads
2831
+ * back another value.
2832
+ */
2833
+ declare const storeEnvFileSecrets: (secrets: SecretsAdapter, names: readonly string[], cwd: string,
2834
+ /** An env file to read instead of `.env.hotupdater`, relative to `cwd`. */
2835
+ envFile?: string) => Promise<readonly string[]>;
2521
2836
  //#endregion
2522
2837
  //#region src/storageFiles.d.ts
2523
2838
  declare const getStorageFileByteSize: (filePath: string) => Promise<number>;
@@ -2542,4 +2857,4 @@ type TransformTemplateArgs<T extends string> = { [Key in ExtractPlaceholders<T>]
2542
2857
  */
2543
2858
  declare function transformTemplate<T extends string>(templateString: T, values: TransformTemplateArgs<T>): string;
2544
2859
  //#endregion
2545
- export { AppClientCredential, AppClientPlugin, AssembleServerOptions, AssembledServer, BuildFailedError, BuildFailureSummaryConfig, BuildLogger, BuildLoggerConfig, BuildType, BundleSigningSession, CREDENTIAL_ENV_NAMES, CREDENTIAL_LOGIN_GROUPS, ClientAuthSpec, ClientCredentialSpec, ConfigBuilder, ConfigBuilderScaffold, ConfigResponse, CreateCredentialResolverOptions, CreateHotUpdaterConfigScaffoldFromBuilderOptions, CreateHotUpdaterConfigScaffoldOptions, type CredentialFiles, CredentialKind, CredentialRequest, CredentialResolver, CredentialUnavailableError, Credentials, DEFAULT_SIGNING_KEY_SECRET, HOT_UPDATER_HOME_ENV, HOT_UPDATER_SERVER_PACKAGE_VERSION_ENV, HotUpdateDirUtil, HotUpdaterConfigOptions, HotUpdaterConfigScaffold, HotUpdaterInitEnv, HotUpdaterLogWriter, INTERFACE_FINGERPRINT_ENGINE, ImportInfo, InitEnvFileError, InitError, InitProviderDefinition, InitProviderInputDefinition, InitProviderInputPersistence, IssuedCredentialKind, LOCAL_SECRETS_NAME, LegacyInfrastructureError, LocalSecretsOptions, LocalSecretsStore, ManagedHelperStatement, ManagedHelperStrategy, MissingInitInputsError, NativeDependency, NativeInterface, PromptProgress, PromptSpinner, ProviderConfig, ProvisionedClientCredential, ReactNativeMetadata, ReadPackageUpResult, RunInitOptions, SecretsScope, ServerClientEndpoint, ServerDefinition, ServerDefinitionError, WriteHotUpdaterConfigResult, assembleServer, assertInfrastructureGenerationAtUrl, assertInfrastructureGenerationPayload, assertInitInputs, assertInitProviderInputs, assertUnreservedEnv, autolinkingConfigCommand, banner, clientAuthOf, typedColors as colors, confirmInitInputPersistence, copyDirToTmp, createCredentialResolver, createHotUpdaterConfigScaffold, createHotUpdaterConfigScaffoldFromBuilder, createInterfaceFingerprint, createLocalSecretsStore, createLogWriter, createMigrator, createMinBundleId, createTarBrTargetFiles, createZip, credentialIssueCommand, credentialLoginCommand, credentialOverrideHint, credentialPutCommand, credentialStoreCommand, decryptJson, defineInitProvider, describeSecret, describeStoredSecret, encryptJson, ensureInstallPackages, generateClientCredential, generateSchema, generatesSchema, getAndroidSdkPath, getBundleSigningPublicKey, getConfiguredAdapter, getConfiguredSecrets, getCwd, getHotUpdaterEnvValue, getHotUpdaterHome, getHotUpdaterInitInputEnv, getInitProviderEnvVars, getInitProviderTextPromptValues, getLocalKeyFile, getLocalKeyStoreDir, getLocalSecretsStore, getMissingInitInputs, getMissingInitProviderInputs, getPackageManager, getProjectKey, getReactNativeMetadatas, getStorageFileByteSize, isCI, isCodegenSpecFile, isReservedVariableName, isSecretName, isServerDefinition, keepsKeysOnThisMachine, link, loadConfig, loadPlatformConfigs, localSecrets, log, makeEnv, maskSecretValues, moduleSpecifiersOf, nonInteractiveReason, p, parseLoadedEnv, parseSecretReference, prepareBundleSigning, printAppSetup, printBanner, provisionClientCredential, putStorageFile, reactNativeCliFingerprint, reactNativeConfigCommand, readBundleSigningPublicKeyFile, readHotUpdaterInitEnv, readLoadedHotUpdaterEnv, readLocalKey, readPackageUp, readReactNativeInterface, readSecretVariables, registerCredentialValue, registerSecretValue, renderAppImports, renderAppSetup, renderImportStatements, resolveExpoAutolinking, resolveHotUpdaterServerVersion, resolveInitProviderInput, resolveInitProviderInputs, resolveLocalSecretsPath, resolvePackageVersion, secretEnv, secretVariableName, serverDefinitionOf, setConfiguredSecrets, shouldAutoSelectOnlyInitResource, stripAnsi, transformEnv, transformTemplate, withCredentialResolver, withLocalKeyStore, withSecretsScope, writeHotUpdaterConfig, writeHotUpdaterFiles, writeLocalKey };
2860
+ export { AddSigningSecretResult, AppClientCredential, AppClientPlugin, AssembleServerOptions, AssembledServer, BUNDLE_SIGNING_KEY_SECRET, BuildFailedError, BuildFailureSummaryConfig, BuildLogger, BuildLoggerConfig, BuildPhaseReader, BuildType, BundleSigningKeyError, BundleSigningOptions, BundleSigningSession, BundleSigningState, CREDENTIAL_ENV_NAMES, CREDENTIAL_LOGIN_GROUPS, ClientAuthSpec, ClientCredentialSpec, ConfigBuilder, ConfigBuilderScaffold, ConfigResponse, CreateCredentialResolverOptions, CreateHotUpdaterConfigScaffoldFromBuilderOptions, CreateHotUpdaterConfigScaffoldOptions, type CredentialFiles, CredentialKind, CredentialRequest, CredentialResolver, CredentialUnavailableError, Credentials, FileCredentialKind, HOT_UPDATER_HOME_ENV, HOT_UPDATER_SERVER_PACKAGE_VERSION_ENV, HotUpdateDirUtil, HotUpdaterConfigOptions, HotUpdaterConfigScaffold, HotUpdaterInitEnv, HotUpdaterLogWriter, INTERFACE_FINGERPRINT_ENGINE, INVALID_SIGNING_MESSAGE, INVALID_SIGNING_NEXT_STEP, ISSUE_SIGNING_KEY_COMMAND, ImportInfo, InitEnvFileError, InitError, InitProviderDefinition, InitProviderInputDefinition, InitProviderInputPersistence, IssuedCredentialKind, LOCAL_SECRETS_NAME, LegacyInfrastructureError, LocalSecretsOptions, LocalSecretsStore, MANAGED_CLIENT_CREDENTIAL_ENV, MESSAGE_WIDTH, ManagedHelperStatement, ManagedHelperStrategy, MissingInitInputsError, NativeDependency, NativeInterface, PUT_SIGNING_KEY_COMMAND, PromptProgress, PromptSpinner, ProviderConfig, ProvisionedClientCredential, ReactNativeMetadata, ReadPackageUpResult, RunInitOptions, SecretsScope, ServerClientEndpoint, ServerDefinition, ServerDefinitionError, Step, StepLevel, UNSIGNED_BUNDLES_NEXT_STEP, UNSIGNED_BUNDLES_WARNING, WriteHotUpdaterConfigResult, addSigningSecretToConfig, addSigningSecretToConfigText, assembleServer, assertInfrastructureGenerationAtUrl, assertInfrastructureGenerationPayload, assertInitInputs, assertInitProviderInputs, assertUnreservedEnv, autolinkingConfigCommand, banner, bundleSigningPutCommand, bundleSigningSecretRef, clientAuthOf, typedColors as colors, configSetsTeamSecrets, confirmInitInputPersistence, copyDirToTmp, createCredentialResolver, createHotUpdaterConfigScaffold, createHotUpdaterConfigScaffoldFromBuilder, createInterfaceFingerprint, createLocalSecretsStore, createLogWriter, createMigrator, createMinBundleId, createStep, createTarBrTargetFiles, createZip, credentialIssueCommand, credentialLoginCommand, credentialPutCommand, credentialStoreCommand, decryptJson, defineInitProvider, describeMissingSecret, describeSecret, describeStoredSecret, displayWidth, encryptJson, ensureInstallPackages, failActiveStep, fitMessage, formatCommand, formatDuration, generateClientCredential, generateSchema, generatesSchema, getAndroidSdkPath, getBundleSigningPublicKey, getConfiguredAdapter, getConfiguredSecrets, getCwd, getDeploySecretNames, getHotUpdaterEnvValue, getHotUpdaterHome, getHotUpdaterInitInputEnv, getInitProviderEnvVars, getInitProviderTextPromptValues, getLocalKeyFile, getLocalKeyStoreDir, getLocalSecretsStore, getMissingInitInputs, getMissingInitProviderInputs, getPackageManager, getProjectKey, getReactNativeMetadatas, getStorageFileByteSize, isCI, isCodegenSpecFile, isReservedVariableName, isSecretName, isSecretRef, isServerDefinition, keepsKeysOnThisMachine, link, loadConfig, loadPlatformConfigs, loadTeamSecrets, localSecrets, log, makeEnv, maskSecretValues, moduleSpecifiersOf, nonInteractiveReason, p, parseLoadedEnv, parseSecretReference, prepareBundleSigning, printAppSetup, printBanner, provisionClientCredential, putStorageFile, reactNativeCliFingerprint, reactNativeConfigCommand, readBundleSigningPublicKeyFile, readBundleSigningState, readHotUpdaterInitEnv, readLoadedEnvFile, readLoadedHotUpdaterEnv, readLocalKey, readMissingFromTeamSecrets, readPackageUp, readReactNativeInterface, readSecretVariables, readSecretWithSource, readSecrets, registerCredentialValue, registerSecretValue, renderAppImports, renderAppSetup, renderImportStatements, resolveExpoAutolinking, resolveHotUpdaterServerVersion, resolveInitProviderInput, resolveInitProviderInputs, resolveLocalSecretsPath, resolvePackageVersion, resolveSecretsAdapter, secret, secretVariableName, serverDefinitionOf, setConfiguredSecrets, shouldAutoSelectOnlyInitResource, startStep, storeEnvFileSecrets, stripAnsi, transformEnv, transformTemplate, truncateLine, withCredentialResolver, withDuration, withSecretsScope, withStep, writeHotUpdaterConfig, writeHotUpdaterFiles, writeLocalKey };