From 2af145711874bfda875b8167da9c59738d5b8dc2 Mon Sep 17 00:00:00 2001 From: Piotr Szeremeta Date: Tue, 12 Mar 2024 00:29:57 +0100 Subject: [PATCH] [ENG-11445] Add 'verbose-fastlane' flag for verbose fastlane logs --- packages/eas-cli/src/commands/submit.ts | 9 +++++++++ packages/eas-cli/src/graphql/generated.ts | 1 + packages/eas-cli/src/submit/context.ts | 2 ++ packages/eas-cli/src/submit/ios/IosSubmitter.ts | 3 +++ 4 files changed, 15 insertions(+) diff --git a/packages/eas-cli/src/commands/submit.ts b/packages/eas-cli/src/commands/submit.ts index 1496721b40..50322e7faa 100644 --- a/packages/eas-cli/src/commands/submit.ts +++ b/packages/eas-cli/src/commands/submit.ts @@ -33,6 +33,7 @@ interface RawCommandFlags { verbose: boolean; wait: boolean; 'non-interactive': boolean; + 'verbose-fastlane'?: boolean; } interface CommandFlags { @@ -42,6 +43,7 @@ interface CommandFlags { verbose: boolean; wait: boolean; nonInteractive: boolean; + isVerboseFastlaneEnabled?: boolean; } export default class Submit extends EasCommand { @@ -83,6 +85,10 @@ export default class Submit extends EasCommand { default: true, allowNo: true, }), + 'verbose-fastlane': Flags.boolean({ + default: false, + description: 'Enable verbose logging for the submission process', + }), 'non-interactive': Flags.boolean({ default: false, description: 'Run command in non-interactive mode', @@ -132,6 +138,7 @@ export default class Submit extends EasCommand { profile: submissionProfile.profile, archiveFlags: flagsWithPlatform.archiveFlags, nonInteractive: flagsWithPlatform.nonInteractive, + isVerboseFastlaneEnabled: flagsWithPlatform.isVerboseFastlaneEnabled, actor, graphqlClient, analytics, @@ -175,6 +182,7 @@ export default class Submit extends EasCommand { wait, profile, 'non-interactive': nonInteractive, + 'verbose-fastlane': isVerboseFastlaneEnabled, ...archiveFlags } = flags; @@ -195,6 +203,7 @@ export default class Submit extends EasCommand { wait, profile, nonInteractive, + isVerboseFastlaneEnabled, }; } diff --git a/packages/eas-cli/src/graphql/generated.ts b/packages/eas-cli/src/graphql/generated.ts index 17d4d4c2a8..55df09abdd 100644 --- a/packages/eas-cli/src/graphql/generated.ts +++ b/packages/eas-cli/src/graphql/generated.ts @@ -3924,6 +3924,7 @@ export type IosSubmissionConfigInput = { ascApiKey?: InputMaybe; ascApiKeyId?: InputMaybe; ascAppIdentifier: Scalars['String']['input']; + isVerboseLoggingEnabled?: InputMaybe; }; export type KeystoreGenerationUrl = { diff --git a/packages/eas-cli/src/submit/context.ts b/packages/eas-cli/src/submit/context.ts index 357baa247b..c36d684612 100644 --- a/packages/eas-cli/src/submit/context.ts +++ b/packages/eas-cli/src/submit/context.ts @@ -21,6 +21,7 @@ export interface SubmissionContext { analyticsEventProperties: AnalyticsEventProperties; exp: ExpoConfig; nonInteractive: boolean; + isVerboseFastlaneEnabled?: boolean; platform: T; profile: SubmitProfile; projectDir: string; @@ -46,6 +47,7 @@ export async function createSubmissionContextAsync(params: { credentialsCtx?: CredentialsContext; env?: Record; nonInteractive: boolean; + isVerboseFastlaneEnabled?: boolean; platform: T; profile: SubmitProfile; projectDir: string; diff --git a/packages/eas-cli/src/submit/ios/IosSubmitter.ts b/packages/eas-cli/src/submit/ios/IosSubmitter.ts index 0ef29637c0..3dfded6dba 100644 --- a/packages/eas-cli/src/submit/ios/IosSubmitter.ts +++ b/packages/eas-cli/src/submit/ios/IosSubmitter.ts @@ -32,6 +32,7 @@ export interface IosSubmissionOptions archiveSource: ArchiveSource; appSpecificPasswordSource?: AppSpecificPasswordSource; ascApiKeySource?: AscApiKeySource; + isVerboseFastlaneEnabled?: boolean; } interface ResolvedSourceOptions { @@ -124,9 +125,11 @@ export default class IosSubmitter extends BaseSubmitter< ): IosSubmissionConfigInput { const { appSpecificPassword, ascApiKeyResult } = credentials; const { appleIdUsername, ascAppIdentifier } = options; + const { isVerboseFastlaneEnabled } = this.ctx; return { ascAppIdentifier, appleIdUsername, + isVerboseFastlaneEnabled, ...(appSpecificPassword ? this.formatAppSpecificPassword(appSpecificPassword) : null), ...(ascApiKeyResult?.result ? this.formatAscApiKeyResult(ascApiKeyResult.result) : null), };