@capgo/cli 7.121.0 → 7.122.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/README.md +1 -0
- package/dist/index.js +378 -378
- package/dist/package.json +3 -2
- package/dist/src/bundle/builder-cta.d.ts +18 -0
- package/dist/src/bundle/upload.d.ts +7 -0
- package/dist/src/schemas/bundle.d.ts +1 -0
- package/dist/src/sdk.js +190 -190
- package/package.json +3 -2
- package/skills/release-management/SKILL.md +1 -0
package/dist/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@capgo/cli",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "7.
|
|
4
|
+
"version": "7.122.0",
|
|
5
5
|
"description": "A CLI to upload to capgo servers",
|
|
6
6
|
"author": "Martin martin@capgo.app",
|
|
7
7
|
"license": "Apache 2.0",
|
|
@@ -70,6 +70,7 @@
|
|
|
70
70
|
"test:version-edge-cases": "bun test/test-version-validation.mjs",
|
|
71
71
|
"test:regex": "bun test/test-regex-validation.mjs",
|
|
72
72
|
"test:upload": "bun test/test-upload-validation.mjs",
|
|
73
|
+
"test:fail-on-incompatible": "bun test/test-fail-on-incompatible.mjs",
|
|
73
74
|
"test:credentials": "bun test/test-credentials.mjs",
|
|
74
75
|
"test:credentials-validation": "bun test/test-credentials-validation.mjs",
|
|
75
76
|
"test:android-service-account-validation": "bun test/test-android-service-account-validation.mjs",
|
|
@@ -105,7 +106,7 @@
|
|
|
105
106
|
"test:macos-signing": "bun test/test-macos-signing.mjs",
|
|
106
107
|
"test:apple-api-import-helpers": "bun test/test-apple-api-import-helpers.mjs",
|
|
107
108
|
"test:manifest-path-encoding": "bun test/test-manifest-path-encoding.mjs",
|
|
108
|
-
"test": "bun run build && bun run test:version-detection:setup && bun run test:bundle && bun run test:functional && bun run test:semver && bun run test:version-edge-cases && bun run test:regex && bun run test:upload && bun run test:credentials && bun run test:credentials-validation && bun run test:android-service-account-validation && bun run test:build-zip-filter && bun run test:checksum && bun run test:build-needed && bun run test:ci-prompts && bun run test:ci-secrets && bun run test:android-onboarding-progress && bun run test:onboarding-telemetry && bun run test:v2-event-migration && bun run test:analytics && bun run test:analytics-error-category && bun run test:analytics-org-resolver && bun run test:supabase-perf && bun run test:mcp-analytics && bun run test:app-created-source && bun run test:doctor-analytics && bun run test:posthog-exception && bun run test:build-platform-selection && bun run test:onboarding-recovery && bun run test:onboarding-progress && bun run test:onboarding-run-targets && bun run test:run-device-command && bun run test:init-app-conflict && bun run test:init-guardrails && bun run test:prompt-preferences && bun run test:esm-sdk && bun run test:mcp && bun run test:version-detection && bun run test:platform-paths && bun run test:payload-split && bun run test:manifest-path-encoding && bun run test:macos-signing && bun run test:apple-api-import-helpers && bun run test:ai-log-capture && bun run test:ai-analyze-flow && bun run test:ai-render-markdown && bun run test:ai-onboarding-mode && bun run test:ai-fit && bun run test:platform-layout && bun run test:frame-fit && bun run test:onboarding-min-size && bun run test:min-size-gate && bun run test:shell-size-gate && bun run test:build-log-sanitize && bun run test:build-output-viewport && bun run test:diff-viewer-viewport && bun run test:build-complete-exit",
|
|
109
|
+
"test": "bun run build && bun run test:version-detection:setup && bun run test:bundle && bun run test:functional && bun run test:semver && bun run test:version-edge-cases && bun run test:regex && bun run test:upload && bun run test:fail-on-incompatible && bun run test:credentials && bun run test:credentials-validation && bun run test:android-service-account-validation && bun run test:build-zip-filter && bun run test:checksum && bun run test:build-needed && bun run test:ci-prompts && bun run test:ci-secrets && bun run test:android-onboarding-progress && bun run test:onboarding-telemetry && bun run test:v2-event-migration && bun run test:analytics && bun run test:analytics-error-category && bun run test:analytics-org-resolver && bun run test:supabase-perf && bun run test:mcp-analytics && bun run test:app-created-source && bun run test:doctor-analytics && bun run test:posthog-exception && bun run test:build-platform-selection && bun run test:onboarding-recovery && bun run test:onboarding-progress && bun run test:onboarding-run-targets && bun run test:run-device-command && bun run test:init-app-conflict && bun run test:init-guardrails && bun run test:prompt-preferences && bun run test:esm-sdk && bun run test:mcp && bun run test:version-detection && bun run test:platform-paths && bun run test:payload-split && bun run test:manifest-path-encoding && bun run test:macos-signing && bun run test:apple-api-import-helpers && bun run test:ai-log-capture && bun run test:ai-analyze-flow && bun run test:ai-render-markdown && bun run test:ai-onboarding-mode && bun run test:ai-fit && bun run test:platform-layout && bun run test:frame-fit && bun run test:onboarding-min-size && bun run test:min-size-gate && bun run test:shell-size-gate && bun run test:build-log-sanitize && bun run test:build-output-viewport && bun run test:diff-viewer-viewport && bun run test:build-complete-exit",
|
|
109
110
|
"test:build-platform-selection": "bun test/test-build-platform-selection.mjs",
|
|
110
111
|
"test:ai-log-capture": "bun test/test-ai-log-capture.mjs",
|
|
111
112
|
"test:ai-analyze-flow": "bun test/test-ai-analyze-flow.mjs",
|
|
@@ -13,6 +13,24 @@ export interface BuilderCtaContext {
|
|
|
13
13
|
* whether the app already has build credentials.
|
|
14
14
|
*/
|
|
15
15
|
export declare function decideBuilderCtaSurface(ctx: BuilderCtaContext): BuilderCtaSurface;
|
|
16
|
+
export interface ShouldBlockIncompatibleUploadContext {
|
|
17
|
+
incompatible: boolean;
|
|
18
|
+
failOnIncompatible: boolean;
|
|
19
|
+
interactive: boolean;
|
|
20
|
+
/** The resolved Builder CTA action (`continue` in CI / when declined). */
|
|
21
|
+
builderAction: BuilderCtaAction;
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* Pure decision: should an incompatible upload be blocked (abort + exit non-zero)
|
|
25
|
+
* instead of uploaded, given `--fail-on-incompatible`?
|
|
26
|
+
*
|
|
27
|
+
* - Only confirmed-incompatible bundles with the flag set are candidates.
|
|
28
|
+
* - Non-interactive (CI): block immediately.
|
|
29
|
+
* - Interactive: block only when the user declined the Capgo Builder native-build
|
|
30
|
+
* escape hatch (`builderAction === 'continue'`). Accepting a native build
|
|
31
|
+
* (`launch-build` / `launch-onboarding`) supersedes the OTA upload, so do not block.
|
|
32
|
+
*/
|
|
33
|
+
export declare function shouldBlockIncompatibleUpload(ctx: ShouldBlockIncompatibleUploadContext): boolean;
|
|
16
34
|
export declare function printBuilderCiAd(hasCredentials: boolean): void;
|
|
17
35
|
/** Confirm-prompt seam (`@clack/prompts` `confirm` satisfies it); injectable for tests. */
|
|
18
36
|
export type BuilderConfirm = (opts: {
|
|
@@ -5,6 +5,13 @@ type SupabaseType = Awaited<ReturnType<typeof createSupabaseClient>>;
|
|
|
5
5
|
export type { UploadBundleResult };
|
|
6
6
|
export declare function getDefaultUploadChannel(appId: string, supabase: SupabaseType, hostWeb: string): Promise<string>;
|
|
7
7
|
export declare function uploadBundleInternal(preAppid: string, options: OptionsUpload, silent?: boolean): Promise<UploadBundleResult>;
|
|
8
|
+
/**
|
|
9
|
+
* Validate mutually-exclusive and dependent upload options, failing fast (via
|
|
10
|
+
* `uploadFail`) before any network call. Exported so the option-conflict guards
|
|
11
|
+
* (e.g. `--fail-on-incompatible` + `--ignore-metadata-check`) can be unit-tested
|
|
12
|
+
* directly.
|
|
13
|
+
*/
|
|
14
|
+
export declare function checkValidOptions(options: OptionsUpload): void;
|
|
8
15
|
export declare function uploadBundle(appid: string, options: OptionsUpload): Promise<{
|
|
9
16
|
success: boolean;
|
|
10
17
|
bundle: string;
|
|
@@ -26,6 +26,7 @@ export declare const optionsUploadSchema: z.ZodObject<{
|
|
|
26
26
|
autoMinUpdateVersion: z.ZodOptional<z.ZodBoolean>;
|
|
27
27
|
autoSetBundle: z.ZodOptional<z.ZodBoolean>;
|
|
28
28
|
ignoreMetadataCheck: z.ZodOptional<z.ZodBoolean>;
|
|
29
|
+
failOnIncompatible: z.ZodOptional<z.ZodBoolean>;
|
|
29
30
|
ignoreChecksumCheck: z.ZodOptional<z.ZodBoolean>;
|
|
30
31
|
forceCrc32Checksum: z.ZodOptional<z.ZodBoolean>;
|
|
31
32
|
timeout: z.ZodOptional<z.ZodNumber>;
|