eas-cli 2.2.1 → 2.4.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 +47 -47
- package/build/ApiV2Error.d.ts +15 -0
- package/build/ApiV2Error.js +14 -0
- package/build/api.d.ts +10 -16
- package/build/api.js +52 -59
- package/build/branch/queries.d.ts +3 -2
- package/build/branch/queries.js +7 -7
- package/build/build/android/build.js +3 -3
- package/build/build/android/syncProjectConfiguration.d.ts +2 -1
- package/build/build/android/syncProjectConfiguration.js +2 -2
- package/build/build/android/version.d.ts +2 -1
- package/build/build/android/version.js +4 -4
- package/build/build/build.d.ts +2 -1
- package/build/build/build.js +5 -5
- package/build/build/context.d.ts +2 -0
- package/build/build/createContext.d.ts +3 -1
- package/build/build/createContext.js +4 -2
- package/build/build/ios/build.js +3 -3
- package/build/build/ios/syncProjectConfiguration.d.ts +2 -1
- package/build/build/ios/syncProjectConfiguration.js +2 -2
- package/build/build/ios/version.d.ts +2 -1
- package/build/build/ios/version.js +4 -4
- package/build/build/queries.d.ts +2 -1
- package/build/build/queries.js +3 -3
- package/build/build/runBuildAndSubmit.d.ts +2 -1
- package/build/build/runBuildAndSubmit.js +26 -16
- package/build/build/types.d.ts +6 -1
- package/build/build/types.js +5 -0
- package/build/channel/queries.d.ts +4 -3
- package/build/channel/queries.js +13 -13
- package/build/commandUtils/EasCommand.d.ts +24 -3
- package/build/commandUtils/EasCommand.js +36 -6
- package/build/commandUtils/context/ContextField.d.ts +2 -0
- package/build/commandUtils/context/DynamicProjectConfigContextField.d.ts +1 -1
- package/build/commandUtils/context/DynamicProjectConfigContextField.js +2 -2
- package/build/commandUtils/context/LoggedInContextField.d.ts +12 -0
- package/build/commandUtils/context/LoggedInContextField.js +15 -0
- package/build/commandUtils/context/MaybeLoggedInContextField.d.ts +12 -0
- package/build/commandUtils/context/MaybeLoggedInContextField.js +17 -0
- package/build/commandUtils/context/OptionalProjectConfigContextField.d.ts +1 -1
- package/build/commandUtils/context/OptionalProjectConfigContextField.js +2 -2
- package/build/commandUtils/context/ProjectConfigContextField.d.ts +1 -1
- package/build/commandUtils/context/ProjectConfigContextField.js +2 -2
- package/build/commandUtils/context/SessionManagementContextField.d.ts +5 -0
- package/build/commandUtils/context/SessionManagementContextField.js +10 -0
- package/build/commandUtils/context/contextUtils/createGraphqlClient.d.ts +11 -0
- package/build/commandUtils/context/contextUtils/createGraphqlClient.js +43 -0
- package/build/commandUtils/context/contextUtils/getProjectIdAsync.d.ts +2 -1
- package/build/commandUtils/context/contextUtils/getProjectIdAsync.js +11 -7
- package/build/commands/account/login.d.ts +3 -0
- package/build/commands/account/login.js +7 -2
- package/build/commands/account/logout.d.ts +3 -0
- package/build/commands/account/logout.js +7 -2
- package/build/commands/account/view.d.ts +3 -0
- package/build/commands/account/view.js +8 -3
- package/build/commands/branch/create.d.ts +3 -1
- package/build/commands/branch/create.js +6 -5
- package/build/commands/branch/delete.d.ts +1 -0
- package/build/commands/branch/delete.js +10 -9
- package/build/commands/branch/list.d.ts +1 -0
- package/build/commands/branch/list.js +3 -2
- package/build/commands/branch/rename.d.ts +1 -0
- package/build/commands/branch/rename.js +6 -5
- package/build/commands/branch/view.d.ts +1 -0
- package/build/commands/branch/view.js +4 -3
- package/build/commands/build/cancel.d.ts +3 -1
- package/build/commands/build/cancel.js +14 -13
- package/build/commands/build/configure.d.ts +1 -0
- package/build/commands/build/configure.js +4 -3
- package/build/commands/build/index.d.ts +1 -1
- package/build/commands/build/index.js +9 -3
- package/build/commands/build/inspect.d.ts +1 -1
- package/build/commands/build/inspect.js +2 -2
- package/build/commands/build/list.d.ts +1 -0
- package/build/commands/build/list.js +4 -3
- package/build/commands/build/version/set.d.ts +1 -1
- package/build/commands/build/version/set.js +4 -4
- package/build/commands/build/version/sync.d.ts +1 -1
- package/build/commands/build/version/sync.js +2 -2
- package/build/commands/build/view.d.ts +1 -0
- package/build/commands/build/view.js +5 -4
- package/build/commands/channel/create.d.ts +3 -1
- package/build/commands/channel/create.js +8 -7
- package/build/commands/channel/delete.d.ts +1 -0
- package/build/commands/channel/delete.js +7 -6
- package/build/commands/channel/edit.d.ts +3 -1
- package/build/commands/channel/edit.js +12 -8
- package/build/commands/channel/list.d.ts +1 -0
- package/build/commands/channel/list.js +3 -2
- package/build/commands/channel/rollout.d.ts +1 -0
- package/build/commands/channel/rollout.js +15 -14
- package/build/commands/channel/view.d.ts +1 -0
- package/build/commands/channel/view.js +4 -3
- package/build/commands/credentials.d.ts +1 -1
- package/build/commands/credentials.js +2 -2
- package/build/commands/device/create.d.ts +1 -1
- package/build/commands/device/create.js +2 -1
- package/build/commands/device/delete.d.ts +3 -1
- package/build/commands/device/delete.js +9 -8
- package/build/commands/device/list.d.ts +1 -0
- package/build/commands/device/list.js +5 -4
- package/build/commands/device/view.d.ts +1 -0
- package/build/commands/device/view.js +4 -3
- package/build/commands/metadata/pull.d.ts +1 -1
- package/build/commands/metadata/pull.js +2 -1
- package/build/commands/metadata/push.d.ts +1 -1
- package/build/commands/metadata/push.js +2 -1
- package/build/commands/open.d.ts +1 -0
- package/build/commands/open.js +3 -2
- package/build/commands/project/info.d.ts +1 -0
- package/build/commands/project/info.js +5 -4
- package/build/commands/project/init.d.ts +1 -1
- package/build/commands/project/init.js +5 -5
- package/build/commands/secret/create.d.ts +1 -0
- package/build/commands/secret/create.js +10 -9
- package/build/commands/secret/delete.d.ts +1 -0
- package/build/commands/secret/delete.js +4 -3
- package/build/commands/secret/list.d.ts +1 -0
- package/build/commands/secret/list.js +3 -2
- package/build/commands/submit.d.ts +1 -1
- package/build/commands/submit.js +4 -3
- package/build/commands/update/configure.d.ts +1 -0
- package/build/commands/update/configure.js +4 -3
- package/build/commands/update/delete.d.ts +3 -0
- package/build/commands/update/delete.js +9 -3
- package/build/commands/update/index.d.ts +3 -1
- package/build/commands/update/index.js +23 -17
- package/build/commands/update/list.d.ts +1 -0
- package/build/commands/update/list.js +6 -5
- package/build/commands/update/view.d.ts +3 -0
- package/build/commands/update/view.js +7 -1
- package/build/commands/webhook/create.d.ts +1 -0
- package/build/commands/webhook/create.js +3 -2
- package/build/commands/webhook/delete.d.ts +1 -0
- package/build/commands/webhook/delete.js +7 -6
- package/build/commands/webhook/list.d.ts +1 -0
- package/build/commands/webhook/list.js +4 -3
- package/build/commands/webhook/update.d.ts +3 -0
- package/build/commands/webhook/update.js +8 -2
- package/build/commands/webhook/view.d.ts +3 -0
- package/build/commands/webhook/view.js +7 -1
- package/build/credentials/android/actions/AssignFcm.js +2 -2
- package/build/credentials/android/actions/AssignGoogleServiceAccountKey.js +2 -2
- package/build/credentials/android/actions/BuildCredentialsUtils.js +12 -12
- package/build/credentials/android/actions/CreateFcm.js +1 -1
- package/build/credentials/android/actions/CreateGoogleServiceAccountKey.js +1 -1
- package/build/credentials/android/actions/CreateKeystore.js +4 -4
- package/build/credentials/android/actions/RemoveFcm.js +2 -2
- package/build/credentials/android/actions/RemoveGoogleServiceAccountKey.js +2 -2
- package/build/credentials/android/actions/RemoveKeystore.js +1 -1
- package/build/credentials/android/actions/SetUpBuildCredentials.js +3 -3
- package/build/credentials/android/actions/SetUpBuildCredentialsFromCredentialsJson.js +3 -3
- package/build/credentials/android/actions/SetUpGoogleServiceAccountKey.js +3 -3
- package/build/credentials/android/actions/UseExistingGoogleServiceAccountKey.js +1 -1
- package/build/credentials/android/api/GraphqlClient.d.ts +19 -18
- package/build/credentials/android/api/GraphqlClient.js +45 -45
- package/build/credentials/android/api/graphql/mutations/AndroidAppBuildCredentialsMutation.d.ts +3 -2
- package/build/credentials/android/api/graphql/mutations/AndroidAppBuildCredentialsMutation.js +4 -4
- package/build/credentials/android/api/graphql/mutations/AndroidAppCredentialsMutation.d.ts +4 -3
- package/build/credentials/android/api/graphql/mutations/AndroidAppCredentialsMutation.js +6 -6
- package/build/credentials/android/api/graphql/mutations/AndroidFcmMutation.d.ts +3 -2
- package/build/credentials/android/api/graphql/mutations/AndroidFcmMutation.js +4 -4
- package/build/credentials/android/api/graphql/mutations/AndroidKeystoreMutation.d.ts +3 -2
- package/build/credentials/android/api/graphql/mutations/AndroidKeystoreMutation.js +4 -4
- package/build/credentials/android/api/graphql/mutations/GoogleServiceAccountKeyMutation.d.ts +3 -2
- package/build/credentials/android/api/graphql/mutations/GoogleServiceAccountKeyMutation.js +4 -4
- package/build/credentials/android/api/graphql/queries/AndroidAppCredentialsQuery.d.ts +2 -1
- package/build/credentials/android/api/graphql/queries/AndroidAppCredentialsQuery.js +2 -2
- package/build/credentials/android/api/graphql/queries/GoogleServiceAccountKeyQuery.d.ts +2 -1
- package/build/credentials/android/api/graphql/queries/GoogleServiceAccountKeyQuery.js +2 -2
- package/build/credentials/android/utils/keystore.d.ts +2 -1
- package/build/credentials/android/utils/keystore.js +6 -6
- package/build/credentials/context.d.ts +3 -0
- package/build/credentials/context.js +1 -0
- package/build/credentials/credentialsJson/update.js +1 -1
- package/build/credentials/ios/actions/AppleTeamUtils.js +1 -1
- package/build/credentials/ios/actions/AscApiKeyUtils.js +1 -1
- package/build/credentials/ios/actions/AssignAscApiKey.js +2 -2
- package/build/credentials/ios/actions/AssignPushKey.js +2 -2
- package/build/credentials/ios/actions/BuildCredentialsUtils.js +5 -5
- package/build/credentials/ios/actions/ConfigureProvisioningProfile.js +1 -1
- package/build/credentials/ios/actions/CreateAscApiKey.js +1 -1
- package/build/credentials/ios/actions/CreateDistributionCertificate.js +1 -1
- package/build/credentials/ios/actions/CreateProvisioningProfile.js +2 -2
- package/build/credentials/ios/actions/CreatePushKey.js +1 -1
- package/build/credentials/ios/actions/DistributionCertificateUtils.js +2 -2
- package/build/credentials/ios/actions/PushKeyUtils.js +1 -1
- package/build/credentials/ios/actions/RemoveAscApiKey.js +1 -1
- package/build/credentials/ios/actions/RemoveDistributionCertificate.js +1 -1
- package/build/credentials/ios/actions/RemoveProvisioningProfile.js +1 -1
- package/build/credentials/ios/actions/RemovePushKey.js +1 -1
- package/build/credentials/ios/actions/SetUpAdhocProvisioningProfile.js +8 -8
- package/build/credentials/ios/actions/SetUpAscApiKey.js +2 -2
- package/build/credentials/ios/actions/SetUpDistributionCertificate.js +2 -2
- package/build/credentials/ios/actions/SetUpProvisioningProfile.js +1 -1
- package/build/credentials/ios/actions/SetUpPushKey.js +4 -4
- package/build/credentials/ios/actions/SetUpTargetBuildCredentialsFromCredentialsJson.js +5 -5
- package/build/credentials/ios/api/GraphqlClient.d.ts +25 -24
- package/build/credentials/ios/api/GraphqlClient.js +73 -73
- package/build/credentials/ios/api/graphql/mutations/AppStoreConnectApiKeyMutation.d.ts +3 -2
- package/build/credentials/ios/api/graphql/mutations/AppStoreConnectApiKeyMutation.js +4 -4
- package/build/credentials/ios/api/graphql/mutations/AppleAppIdentifierMutation.d.ts +2 -1
- package/build/credentials/ios/api/graphql/mutations/AppleAppIdentifierMutation.js +2 -2
- package/build/credentials/ios/api/graphql/mutations/AppleDeviceMutation.d.ts +3 -2
- package/build/credentials/ios/api/graphql/mutations/AppleDeviceMutation.js +4 -4
- package/build/credentials/ios/api/graphql/mutations/AppleDeviceRegistrationRequestMutation.d.ts +2 -1
- package/build/credentials/ios/api/graphql/mutations/AppleDeviceRegistrationRequestMutation.js +2 -2
- package/build/credentials/ios/api/graphql/mutations/AppleDistributionCertificateMutation.d.ts +3 -2
- package/build/credentials/ios/api/graphql/mutations/AppleDistributionCertificateMutation.js +4 -4
- package/build/credentials/ios/api/graphql/mutations/AppleProvisioningProfileMutation.d.ts +4 -3
- package/build/credentials/ios/api/graphql/mutations/AppleProvisioningProfileMutation.js +6 -6
- package/build/credentials/ios/api/graphql/mutations/ApplePushKeyMutation.d.ts +3 -2
- package/build/credentials/ios/api/graphql/mutations/ApplePushKeyMutation.js +4 -4
- package/build/credentials/ios/api/graphql/mutations/AppleTeamMutation.d.ts +2 -1
- package/build/credentials/ios/api/graphql/mutations/AppleTeamMutation.js +2 -2
- package/build/credentials/ios/api/graphql/mutations/IosAppBuildCredentialsMutation.d.ts +4 -3
- package/build/credentials/ios/api/graphql/mutations/IosAppBuildCredentialsMutation.js +6 -6
- package/build/credentials/ios/api/graphql/mutations/IosAppCredentialsMutation.d.ts +4 -3
- package/build/credentials/ios/api/graphql/mutations/IosAppCredentialsMutation.js +6 -6
- package/build/credentials/ios/api/graphql/queries/AppStoreConnectApiKeyQuery.d.ts +2 -1
- package/build/credentials/ios/api/graphql/queries/AppStoreConnectApiKeyQuery.js +2 -2
- package/build/credentials/ios/api/graphql/queries/AppleAppIdentifierQuery.d.ts +2 -1
- package/build/credentials/ios/api/graphql/queries/AppleAppIdentifierQuery.js +2 -2
- package/build/credentials/ios/api/graphql/queries/AppleDeviceQuery.d.ts +4 -3
- package/build/credentials/ios/api/graphql/queries/AppleDeviceQuery.js +6 -6
- package/build/credentials/ios/api/graphql/queries/AppleDistributionCertificateQuery.d.ts +3 -2
- package/build/credentials/ios/api/graphql/queries/AppleDistributionCertificateQuery.js +4 -4
- package/build/credentials/ios/api/graphql/queries/AppleProvisioningProfileQuery.d.ts +2 -1
- package/build/credentials/ios/api/graphql/queries/AppleProvisioningProfileQuery.js +2 -2
- package/build/credentials/ios/api/graphql/queries/ApplePushKeyQuery.d.ts +2 -1
- package/build/credentials/ios/api/graphql/queries/ApplePushKeyQuery.js +2 -2
- package/build/credentials/ios/api/graphql/queries/AppleTeamQuery.d.ts +3 -2
- package/build/credentials/ios/api/graphql/queries/AppleTeamQuery.js +4 -4
- package/build/credentials/ios/api/graphql/queries/IosAppBuildCredentialsQuery.d.ts +2 -1
- package/build/credentials/ios/api/graphql/queries/IosAppBuildCredentialsQuery.js +2 -2
- package/build/credentials/ios/api/graphql/queries/IosAppCredentialsQuery.d.ts +3 -2
- package/build/credentials/ios/api/graphql/queries/IosAppCredentialsQuery.js +4 -4
- package/build/credentials/manager/HelperActions.d.ts +2 -0
- package/build/credentials/manager/ManageAndroid.js +4 -3
- package/build/credentials/manager/ManageIos.js +4 -3
- package/build/credentials/manager/SelectAndroidBuildCredentials.js +2 -2
- package/build/credentials/manager/SelectPlatform.d.ts +3 -1
- package/build/credentials/manager/SelectPlatform.js +2 -1
- package/build/devices/actions/create/action.d.ts +3 -1
- package/build/devices/actions/create/action.js +5 -4
- package/build/devices/actions/create/developerPortalMethod.d.ts +2 -1
- package/build/devices/actions/create/developerPortalMethod.js +9 -9
- package/build/devices/actions/create/inputMethod.d.ts +2 -1
- package/build/devices/actions/create/inputMethod.js +4 -4
- package/build/devices/actions/create/registrationUrlMethod.d.ts +2 -1
- package/build/devices/actions/create/registrationUrlMethod.js +4 -4
- package/build/devices/context.d.ts +4 -1
- package/build/devices/context.js +2 -1
- package/build/devices/manager.d.ts +3 -1
- package/build/devices/manager.js +9 -8
- package/build/devices/queries.d.ts +4 -3
- package/build/devices/queries.js +7 -7
- package/build/graphql/client.d.ts +1 -8
- package/build/graphql/client.js +1 -39
- package/build/graphql/generated.d.ts +2 -7
- package/build/graphql/generated.js +2 -0
- package/build/graphql/mutations/AppMutation.d.ts +2 -1
- package/build/graphql/mutations/AppMutation.js +2 -2
- package/build/graphql/mutations/AppVersionMutation.d.ts +2 -1
- package/build/graphql/mutations/AppVersionMutation.js +2 -2
- package/build/graphql/mutations/BuildMutation.d.ts +3 -2
- package/build/graphql/mutations/BuildMutation.js +4 -4
- package/build/graphql/mutations/EnvironmentSecretMutation.d.ts +4 -3
- package/build/graphql/mutations/EnvironmentSecretMutation.js +6 -6
- package/build/graphql/mutations/KeystoreGenerationUrlMutation.d.ts +2 -1
- package/build/graphql/mutations/KeystoreGenerationUrlMutation.js +2 -2
- package/build/graphql/mutations/PublishMutation.d.ts +4 -3
- package/build/graphql/mutations/PublishMutation.js +6 -6
- package/build/graphql/mutations/SubmissionMutation.d.ts +3 -2
- package/build/graphql/mutations/SubmissionMutation.js +4 -4
- package/build/graphql/mutations/UploadSessionMutation.d.ts +2 -1
- package/build/graphql/mutations/UploadSessionMutation.js +2 -2
- package/build/graphql/mutations/WebhookMutation.d.ts +4 -3
- package/build/graphql/mutations/WebhookMutation.js +6 -6
- package/build/graphql/queries/AppQuery.d.ts +3 -2
- package/build/graphql/queries/AppQuery.js +4 -4
- package/build/graphql/queries/AppVersionQuery.d.ts +2 -1
- package/build/graphql/queries/AppVersionQuery.js +2 -2
- package/build/graphql/queries/BranchQuery.d.ts +4 -3
- package/build/graphql/queries/BranchQuery.js +6 -6
- package/build/graphql/queries/BuildQuery.d.ts +4 -3
- package/build/graphql/queries/BuildQuery.js +6 -6
- package/build/graphql/queries/ChannelQuery.d.ts +3 -2
- package/build/graphql/queries/ChannelQuery.js +4 -4
- package/build/graphql/queries/EnvironmentSecretsQuery.d.ts +3 -2
- package/build/graphql/queries/EnvironmentSecretsQuery.js +4 -4
- package/build/graphql/queries/PublishQuery.d.ts +3 -2
- package/build/graphql/queries/PublishQuery.js +4 -4
- package/build/graphql/queries/StatuspageServiceQuery.d.ts +2 -1
- package/build/graphql/queries/StatuspageServiceQuery.js +2 -2
- package/build/graphql/queries/SubmissionQuery.d.ts +3 -2
- package/build/graphql/queries/SubmissionQuery.js +4 -4
- package/build/graphql/queries/UpdateQuery.d.ts +4 -3
- package/build/graphql/queries/UpdateQuery.js +6 -6
- package/build/graphql/queries/UserQuery.d.ts +2 -1
- package/build/graphql/queries/UserQuery.js +2 -2
- package/build/graphql/queries/WebhookQuery.d.ts +3 -2
- package/build/graphql/queries/WebhookQuery.js +4 -4
- package/build/project/fetchOrCreateProjectIDForWriteToConfigWithConfirmationAsync.d.ts +3 -2
- package/build/project/fetchOrCreateProjectIDForWriteToConfigWithConfirmationAsync.js +5 -5
- package/build/project/projectUtils.d.ts +3 -2
- package/build/project/projectUtils.js +4 -4
- package/build/project/publish.d.ts +3 -2
- package/build/project/publish.js +7 -7
- package/build/submit/ArchiveSource.d.ts +2 -1
- package/build/submit/ArchiveSource.js +30 -30
- package/build/submit/android/AndroidSubmitter.js +2 -2
- package/build/submit/context.d.ts +3 -0
- package/build/submit/context.js +3 -2
- package/build/submit/ios/IosSubmitter.js +2 -2
- package/build/submit/submit.d.ts +2 -1
- package/build/submit/submit.js +2 -2
- package/build/submit/utils/builds.d.ts +2 -1
- package/build/submit/utils/builds.js +2 -2
- package/build/submit/utils/errors.js +20 -4
- package/build/submit/utils/files.d.ts +2 -1
- package/build/submit/utils/files.js +2 -2
- package/build/submit/utils/wait.d.ts +2 -1
- package/build/submit/utils/wait.js +2 -2
- package/build/update/android/UpdatesModule.d.ts +2 -1
- package/build/update/android/UpdatesModule.js +2 -2
- package/build/update/ios/UpdatesModule.d.ts +2 -1
- package/build/update/ios/UpdatesModule.js +2 -2
- package/build/update/queries.d.ts +4 -3
- package/build/update/queries.js +22 -12
- package/build/uploads.d.ts +2 -1
- package/build/uploads.js +2 -2
- package/build/user/SessionManager.d.ts +70 -0
- package/build/user/SessionManager.js +258 -0
- package/build/user/User.d.ts +0 -9
- package/build/user/User.js +1 -60
- package/build/user/fetchSessionSecretAndUser.d.ts +9 -0
- package/build/user/fetchSessionSecretAndUser.js +43 -0
- package/build/utils/statuspageService.d.ts +2 -1
- package/build/utils/statuspageService.js +4 -4
- package/oclif.manifest.json +1 -1
- package/package.json +2 -2
- package/build/commandUtils/context/ActorContextField.d.ts +0 -5
- package/build/commandUtils/context/ActorContextField.js +0 -11
- package/build/commandUtils/context/contextUtils/ensureLoggedInAsync.d.ts +0 -21
- package/build/commandUtils/context/contextUtils/ensureLoggedInAsync.js +0 -75
- package/build/user/otp.d.ts +0 -29
- package/build/user/otp.js +0 -119
- package/build/user/sessionStorage.d.ts +0 -11
- package/build/user/sessionStorage.js +0 -36
package/build/project/publish.js
CHANGED
|
@@ -174,8 +174,8 @@ async function collectAssetsAsync({ inputDir, platforms, }) {
|
|
|
174
174
|
return assetsFinal;
|
|
175
175
|
}
|
|
176
176
|
exports.collectAssetsAsync = collectAssetsAsync;
|
|
177
|
-
async function filterOutAssetsThatAlreadyExistAsync(uniqueAssetsWithStorageKey) {
|
|
178
|
-
const assetMetadata = await PublishQuery_1.PublishQuery.getAssetMetadataAsync(uniqueAssetsWithStorageKey.map(asset => asset.storageKey));
|
|
177
|
+
async function filterOutAssetsThatAlreadyExistAsync(graphqlClient, uniqueAssetsWithStorageKey) {
|
|
178
|
+
const assetMetadata = await PublishQuery_1.PublishQuery.getAssetMetadataAsync(graphqlClient, uniqueAssetsWithStorageKey.map(asset => asset.storageKey));
|
|
179
179
|
const missingAssetKeys = assetMetadata
|
|
180
180
|
.filter(result => result.status !== generated_1.AssetMetadataStatus.Exists)
|
|
181
181
|
.map(result => result.storageKey);
|
|
@@ -185,7 +185,7 @@ async function filterOutAssetsThatAlreadyExistAsync(uniqueAssetsWithStorageKey)
|
|
|
185
185
|
return missingAssets;
|
|
186
186
|
}
|
|
187
187
|
exports.filterOutAssetsThatAlreadyExistAsync = filterOutAssetsThatAlreadyExistAsync;
|
|
188
|
-
async function uploadAssetsAsync(assetsForUpdateInfoGroup, projectId, updateSpinnerText) {
|
|
188
|
+
async function uploadAssetsAsync(graphqlClient, assetsForUpdateInfoGroup, projectId, updateSpinnerText) {
|
|
189
189
|
let assets = [];
|
|
190
190
|
let platform;
|
|
191
191
|
for (platform in assetsForUpdateInfoGroup) {
|
|
@@ -204,18 +204,18 @@ async function uploadAssetsAsync(assetsForUpdateInfoGroup, projectId, updateSpin
|
|
|
204
204
|
const uniqueAssets = (0, uniqBy_1.default)(assetsWithStorageKey, asset => asset.storageKey);
|
|
205
205
|
const totalAssets = uniqueAssets.length;
|
|
206
206
|
updateSpinnerText === null || updateSpinnerText === void 0 ? void 0 : updateSpinnerText(totalAssets, totalAssets);
|
|
207
|
-
let missingAssets = await filterOutAssetsThatAlreadyExistAsync(uniqueAssets);
|
|
207
|
+
let missingAssets = await filterOutAssetsThatAlreadyExistAsync(graphqlClient, uniqueAssets);
|
|
208
208
|
const uniqueUploadedAssetCount = missingAssets.length;
|
|
209
209
|
const missingAssetChunks = (0, chunk_1.default)(missingAssets, 100);
|
|
210
210
|
const specifications = [];
|
|
211
211
|
for (const missingAssets of missingAssetChunks) {
|
|
212
|
-
const { specifications: chunkSpecifications } = await PublishMutation_1.PublishMutation.getUploadURLsAsync(missingAssets.map(ma => ma.contentType));
|
|
212
|
+
const { specifications: chunkSpecifications } = await PublishMutation_1.PublishMutation.getUploadURLsAsync(graphqlClient, missingAssets.map(ma => ma.contentType));
|
|
213
213
|
specifications.push(...chunkSpecifications);
|
|
214
214
|
}
|
|
215
215
|
updateSpinnerText === null || updateSpinnerText === void 0 ? void 0 : updateSpinnerText(totalAssets, missingAssets.length);
|
|
216
216
|
const assetUploadPromiseLimit = (0, promise_limit_1.default)(15);
|
|
217
217
|
const [assetLimitPerUpdateGroup] = await Promise.all([
|
|
218
|
-
PublishQuery_1.PublishQuery.getAssetLimitPerUpdateGroupAsync(projectId),
|
|
218
|
+
PublishQuery_1.PublishQuery.getAssetLimitPerUpdateGroupAsync(graphqlClient, projectId),
|
|
219
219
|
missingAssets.map((missingAsset, i) => {
|
|
220
220
|
assetUploadPromiseLimit(async () => {
|
|
221
221
|
const presignedPost = JSON.parse(specifications[i]);
|
|
@@ -226,7 +226,7 @@ async function uploadAssetsAsync(assetsForUpdateInfoGroup, projectId, updateSpin
|
|
|
226
226
|
let timeout = 1;
|
|
227
227
|
while (missingAssets.length > 0) {
|
|
228
228
|
const timeoutPromise = new Promise(resolve => setTimeout(resolve, Math.min(timeout * 1000, 5000))); // linear backoff
|
|
229
|
-
missingAssets = await filterOutAssetsThatAlreadyExistAsync(missingAssets);
|
|
229
|
+
missingAssets = await filterOutAssetsThatAlreadyExistAsync(graphqlClient, missingAssets);
|
|
230
230
|
await timeoutPromise; // await after filterOutAssetsThatAlreadyExistAsync for easy mocking with jest.runAllTimers
|
|
231
231
|
timeout += 1;
|
|
232
232
|
updateSpinnerText === null || updateSpinnerText === void 0 ? void 0 : updateSpinnerText(totalAssets, missingAssets.length);
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { Platform } from '@expo/eas-build-job';
|
|
2
|
+
import { ExpoGraphqlClient } from '../commandUtils/context/contextUtils/createGraphqlClient';
|
|
2
3
|
import { BuildFragment } from '../graphql/generated';
|
|
3
4
|
export declare const BUILD_LIST_ITEM_COUNT = 4;
|
|
4
5
|
export declare enum ArchiveSourceType {
|
|
@@ -42,6 +43,6 @@ export interface Archive {
|
|
|
42
43
|
url?: string;
|
|
43
44
|
}
|
|
44
45
|
export declare type ArchiveSource = ArchiveUrlSource | ArchiveLatestSource | ArchivePathSource | ArchiveBuildIdSource | ArchiveBuildListSource | ArchivePromptSource;
|
|
45
|
-
export declare function getArchiveAsync(source: ArchiveSource): Promise<Archive>;
|
|
46
|
+
export declare function getArchiveAsync(graphqlClient: ExpoGraphqlClient, source: ArchiveSource): Promise<Archive>;
|
|
46
47
|
export declare function isUuidV4(s: string): boolean;
|
|
47
48
|
export {};
|
|
@@ -24,34 +24,34 @@ var ArchiveSourceType;
|
|
|
24
24
|
ArchiveSourceType[ArchiveSourceType["buildList"] = 4] = "buildList";
|
|
25
25
|
ArchiveSourceType[ArchiveSourceType["prompt"] = 5] = "prompt";
|
|
26
26
|
})(ArchiveSourceType = exports.ArchiveSourceType || (exports.ArchiveSourceType = {}));
|
|
27
|
-
async function getArchiveAsync(source) {
|
|
27
|
+
async function getArchiveAsync(graphqlClient, source) {
|
|
28
28
|
switch (source.sourceType) {
|
|
29
29
|
case ArchiveSourceType.prompt: {
|
|
30
|
-
return await handlePromptSourceAsync(source);
|
|
30
|
+
return await handlePromptSourceAsync(graphqlClient, source);
|
|
31
31
|
}
|
|
32
32
|
case ArchiveSourceType.url: {
|
|
33
|
-
return await handleUrlSourceAsync(source);
|
|
33
|
+
return await handleUrlSourceAsync(graphqlClient, source);
|
|
34
34
|
}
|
|
35
35
|
case ArchiveSourceType.latest: {
|
|
36
|
-
return await handleLatestSourceAsync(source);
|
|
36
|
+
return await handleLatestSourceAsync(graphqlClient, source);
|
|
37
37
|
}
|
|
38
38
|
case ArchiveSourceType.path: {
|
|
39
|
-
return await handlePathSourceAsync(source);
|
|
39
|
+
return await handlePathSourceAsync(graphqlClient, source);
|
|
40
40
|
}
|
|
41
41
|
case ArchiveSourceType.buildId: {
|
|
42
|
-
return await handleBuildIdSourceAsync(source);
|
|
42
|
+
return await handleBuildIdSourceAsync(graphqlClient, source);
|
|
43
43
|
}
|
|
44
44
|
case ArchiveSourceType.buildList: {
|
|
45
|
-
return await handleBuildListSourceAsync(source);
|
|
45
|
+
return await handleBuildListSourceAsync(graphqlClient, source);
|
|
46
46
|
}
|
|
47
47
|
}
|
|
48
48
|
}
|
|
49
49
|
exports.getArchiveAsync = getArchiveAsync;
|
|
50
|
-
async function handleUrlSourceAsync(source) {
|
|
50
|
+
async function handleUrlSourceAsync(graphqlClient, source) {
|
|
51
51
|
const { url } = source;
|
|
52
52
|
if (!validateUrl(url)) {
|
|
53
53
|
log_1.default.error(chalk_1.default.bold(`The URL you provided is invalid: ${url}`));
|
|
54
|
-
return getArchiveAsync({
|
|
54
|
+
return getArchiveAsync(graphqlClient, {
|
|
55
55
|
...source,
|
|
56
56
|
sourceType: ArchiveSourceType.prompt,
|
|
57
57
|
});
|
|
@@ -59,7 +59,7 @@ async function handleUrlSourceAsync(source) {
|
|
|
59
59
|
const maybeBuildId = isBuildDetailsPage(url);
|
|
60
60
|
if (maybeBuildId) {
|
|
61
61
|
if (await askIfUseBuildIdFromUrlAsync(source, maybeBuildId)) {
|
|
62
|
-
return getArchiveAsync({
|
|
62
|
+
return getArchiveAsync(graphqlClient, {
|
|
63
63
|
...source,
|
|
64
64
|
sourceType: ArchiveSourceType.buildId,
|
|
65
65
|
id: maybeBuildId,
|
|
@@ -71,12 +71,12 @@ async function handleUrlSourceAsync(source) {
|
|
|
71
71
|
source,
|
|
72
72
|
};
|
|
73
73
|
}
|
|
74
|
-
async function handleLatestSourceAsync(source) {
|
|
74
|
+
async function handleLatestSourceAsync(graphqlClient, source) {
|
|
75
75
|
try {
|
|
76
|
-
const [latestBuild] = await (0, builds_1.getRecentBuildsForSubmissionAsync)((0, AppPlatform_1.toAppPlatform)(source.platform), source.projectId);
|
|
76
|
+
const [latestBuild] = await (0, builds_1.getRecentBuildsForSubmissionAsync)(graphqlClient, (0, AppPlatform_1.toAppPlatform)(source.platform), source.projectId);
|
|
77
77
|
if (!latestBuild) {
|
|
78
78
|
log_1.default.error(chalk_1.default.bold("Couldn't find any builds for this project on EAS servers. It looks like you haven't run 'eas build' yet."));
|
|
79
|
-
return getArchiveAsync({
|
|
79
|
+
return getArchiveAsync(graphqlClient, {
|
|
80
80
|
...source,
|
|
81
81
|
sourceType: ArchiveSourceType.prompt,
|
|
82
82
|
});
|
|
@@ -91,29 +91,29 @@ async function handleLatestSourceAsync(source) {
|
|
|
91
91
|
throw err;
|
|
92
92
|
}
|
|
93
93
|
}
|
|
94
|
-
async function handlePathSourceAsync(source) {
|
|
94
|
+
async function handlePathSourceAsync(graphqlClient, source) {
|
|
95
95
|
if (!(await (0, files_1.isExistingFileAsync)(source.path))) {
|
|
96
96
|
log_1.default.error(chalk_1.default.bold(`${source.path} doesn't exist`));
|
|
97
|
-
return getArchiveAsync({
|
|
97
|
+
return getArchiveAsync(graphqlClient, {
|
|
98
98
|
...source,
|
|
99
99
|
sourceType: ArchiveSourceType.prompt,
|
|
100
100
|
});
|
|
101
101
|
}
|
|
102
102
|
log_1.default.log('Uploading your app archive to the Expo Submission Service');
|
|
103
|
-
const uploadUrl = await (0, files_1.uploadAppArchiveAsync)(source.path);
|
|
103
|
+
const uploadUrl = await (0, files_1.uploadAppArchiveAsync)(graphqlClient, source.path);
|
|
104
104
|
return {
|
|
105
105
|
url: uploadUrl,
|
|
106
106
|
source,
|
|
107
107
|
};
|
|
108
108
|
}
|
|
109
|
-
async function handleBuildIdSourceAsync(source) {
|
|
109
|
+
async function handleBuildIdSourceAsync(graphqlClient, source) {
|
|
110
110
|
try {
|
|
111
|
-
const build = await BuildQuery_1.BuildQuery.byIdAsync(source.id);
|
|
111
|
+
const build = await BuildQuery_1.BuildQuery.byIdAsync(graphqlClient, source.id);
|
|
112
112
|
if (build.platform !== (0, AppPlatform_1.toAppPlatform)(source.platform)) {
|
|
113
113
|
const expectedPlatformName = platform_1.appPlatformDisplayNames[(0, AppPlatform_1.toAppPlatform)(source.platform)];
|
|
114
114
|
const receivedPlatformName = platform_1.appPlatformDisplayNames[build.platform];
|
|
115
115
|
log_1.default.error(chalk_1.default.bold(`Build platform doesn't match! Expected ${expectedPlatformName} build but got ${receivedPlatformName}.`));
|
|
116
|
-
return getArchiveAsync({
|
|
116
|
+
return getArchiveAsync(graphqlClient, {
|
|
117
117
|
...source,
|
|
118
118
|
sourceType: ArchiveSourceType.prompt,
|
|
119
119
|
});
|
|
@@ -128,24 +128,24 @@ async function handleBuildIdSourceAsync(source) {
|
|
|
128
128
|
log_1.default.warn('Are you sure that the given ID corresponds to a build from EAS Build?');
|
|
129
129
|
log_1.default.warn(`Build IDs from the classic build service (expo build:[android|ios]) are not supported. ${(0, log_1.learnMore)('https://docs.expo.dev/submit/classic-builds/')}`);
|
|
130
130
|
log_1.default.debug('Original error:', err);
|
|
131
|
-
return getArchiveAsync({
|
|
131
|
+
return getArchiveAsync(graphqlClient, {
|
|
132
132
|
...source,
|
|
133
133
|
sourceType: ArchiveSourceType.prompt,
|
|
134
134
|
});
|
|
135
135
|
}
|
|
136
136
|
}
|
|
137
|
-
async function handleBuildListSourceAsync(source) {
|
|
137
|
+
async function handleBuildListSourceAsync(graphqlClient, source) {
|
|
138
138
|
try {
|
|
139
139
|
const appPlatform = (0, AppPlatform_1.toAppPlatform)(source.platform);
|
|
140
140
|
const expiryDate = new Date(); // artifacts expire after 30 days
|
|
141
141
|
expiryDate.setDate(expiryDate.getDate() - 30);
|
|
142
|
-
const recentBuilds = await (0, builds_1.getRecentBuildsForSubmissionAsync)(appPlatform, source.projectId, {
|
|
142
|
+
const recentBuilds = await (0, builds_1.getRecentBuildsForSubmissionAsync)(graphqlClient, appPlatform, source.projectId, {
|
|
143
143
|
limit: exports.BUILD_LIST_ITEM_COUNT,
|
|
144
144
|
});
|
|
145
145
|
if (recentBuilds.length < 1) {
|
|
146
146
|
log_1.default.error(chalk_1.default.bold(`Couldn't find any ${platform_1.appPlatformDisplayNames[appPlatform]} builds for this project on EAS servers. ` +
|
|
147
147
|
"It looks like you haven't run 'eas build' yet."));
|
|
148
|
-
return getArchiveAsync({
|
|
148
|
+
return getArchiveAsync(graphqlClient, {
|
|
149
149
|
...source,
|
|
150
150
|
sourceType: ArchiveSourceType.prompt,
|
|
151
151
|
});
|
|
@@ -153,7 +153,7 @@ async function handleBuildListSourceAsync(source) {
|
|
|
153
153
|
if (recentBuilds.every(it => new Date(it.updatedAt) < expiryDate)) {
|
|
154
154
|
log_1.default.error(chalk_1.default.bold('It looks like all of your build artifacts have expired. ' +
|
|
155
155
|
'EAS keeps your build artifacts only for 30 days.'));
|
|
156
|
-
return getArchiveAsync({
|
|
156
|
+
return getArchiveAsync(graphqlClient, {
|
|
157
157
|
...source,
|
|
158
158
|
sourceType: ArchiveSourceType.prompt,
|
|
159
159
|
});
|
|
@@ -171,7 +171,7 @@ async function handleBuildListSourceAsync(source) {
|
|
|
171
171
|
warn: 'This artifact has expired',
|
|
172
172
|
});
|
|
173
173
|
if (selectedBuild == null) {
|
|
174
|
-
return getArchiveAsync({
|
|
174
|
+
return getArchiveAsync(graphqlClient, {
|
|
175
175
|
...source,
|
|
176
176
|
sourceType: ArchiveSourceType.prompt,
|
|
177
177
|
});
|
|
@@ -211,7 +211,7 @@ function formatBuildChoice(build, expiryDate) {
|
|
|
211
211
|
disabled: buildDate < expiryDate,
|
|
212
212
|
};
|
|
213
213
|
}
|
|
214
|
-
async function handlePromptSourceAsync(source) {
|
|
214
|
+
async function handlePromptSourceAsync(graphqlClient, source) {
|
|
215
215
|
const { sourceType: sourceTypeRaw } = await (0, prompts_1.promptAsync)({
|
|
216
216
|
name: 'sourceType',
|
|
217
217
|
type: 'select',
|
|
@@ -236,7 +236,7 @@ async function handlePromptSourceAsync(source) {
|
|
|
236
236
|
switch (sourceType) {
|
|
237
237
|
case ArchiveSourceType.url: {
|
|
238
238
|
const url = await askForArchiveUrlAsync(source.platform);
|
|
239
|
-
return getArchiveAsync({
|
|
239
|
+
return getArchiveAsync(graphqlClient, {
|
|
240
240
|
...source,
|
|
241
241
|
sourceType: ArchiveSourceType.url,
|
|
242
242
|
url,
|
|
@@ -244,21 +244,21 @@ async function handlePromptSourceAsync(source) {
|
|
|
244
244
|
}
|
|
245
245
|
case ArchiveSourceType.path: {
|
|
246
246
|
const path = await askForArchivePathAsync(source.platform);
|
|
247
|
-
return getArchiveAsync({
|
|
247
|
+
return getArchiveAsync(graphqlClient, {
|
|
248
248
|
...source,
|
|
249
249
|
sourceType: ArchiveSourceType.path,
|
|
250
250
|
path,
|
|
251
251
|
});
|
|
252
252
|
}
|
|
253
253
|
case ArchiveSourceType.buildList: {
|
|
254
|
-
return getArchiveAsync({
|
|
254
|
+
return getArchiveAsync(graphqlClient, {
|
|
255
255
|
...source,
|
|
256
256
|
sourceType: ArchiveSourceType.buildList,
|
|
257
257
|
});
|
|
258
258
|
}
|
|
259
259
|
case ArchiveSourceType.buildId: {
|
|
260
260
|
const id = await askForBuildIdAsync();
|
|
261
|
-
return getArchiveAsync({
|
|
261
|
+
return getArchiveAsync(graphqlClient, {
|
|
262
262
|
...source,
|
|
263
263
|
sourceType: ArchiveSourceType.buildId,
|
|
264
264
|
id,
|
|
@@ -13,7 +13,7 @@ class AndroidSubmitter extends BaseSubmitter_1.default {
|
|
|
13
13
|
constructor(ctx, options) {
|
|
14
14
|
const sourceOptionsResolver = {
|
|
15
15
|
// eslint-disable-next-line async-protect/async-suffix
|
|
16
|
-
archive: async () => await (0, ArchiveSource_1.getArchiveAsync)(this.options.archiveSource),
|
|
16
|
+
archive: async () => await (0, ArchiveSource_1.getArchiveAsync)(ctx.graphqlClient, this.options.archiveSource),
|
|
17
17
|
// eslint-disable-next-line async-protect/async-suffix
|
|
18
18
|
serviceAccountKeyResult: async () => {
|
|
19
19
|
return await (0, ServiceAccountSource_1.getServiceAccountKeyResultAsync)(this.ctx, this.options.serviceAccountSource);
|
|
@@ -44,7 +44,7 @@ class AndroidSubmitter extends BaseSubmitter_1.default {
|
|
|
44
44
|
};
|
|
45
45
|
}
|
|
46
46
|
async createPlatformSubmissionAsync({ projectId, submissionConfig, buildId, }) {
|
|
47
|
-
return await SubmissionMutation_1.SubmissionMutation.createAndroidSubmissionAsync({
|
|
47
|
+
return await SubmissionMutation_1.SubmissionMutation.createAndroidSubmissionAsync(this.ctx.graphqlClient, {
|
|
48
48
|
appId: projectId,
|
|
49
49
|
config: submissionConfig,
|
|
50
50
|
submittedBuildId: buildId,
|
|
@@ -2,6 +2,7 @@ import { ExpoConfig } from '@expo/config';
|
|
|
2
2
|
import { Platform } from '@expo/eas-build-job';
|
|
3
3
|
import { SubmitProfile } from '@expo/eas-json';
|
|
4
4
|
import { TrackingContext } from '../analytics/common';
|
|
5
|
+
import { ExpoGraphqlClient } from '../commandUtils/context/contextUtils/createGraphqlClient';
|
|
5
6
|
import { CredentialsContext } from '../credentials/context';
|
|
6
7
|
import { Actor } from '../user/User';
|
|
7
8
|
export interface SubmissionContext<T extends Platform> {
|
|
@@ -17,6 +18,7 @@ export interface SubmissionContext<T extends Platform> {
|
|
|
17
18
|
projectId: string;
|
|
18
19
|
projectName: string;
|
|
19
20
|
user: Actor;
|
|
21
|
+
graphqlClient: ExpoGraphqlClient;
|
|
20
22
|
applicationIdentifierOverride?: string;
|
|
21
23
|
}
|
|
22
24
|
export interface SubmitArchiveFlags {
|
|
@@ -35,6 +37,7 @@ export declare function createSubmissionContextAsync<T extends Platform>(params:
|
|
|
35
37
|
projectDir: string;
|
|
36
38
|
applicationIdentifier?: string;
|
|
37
39
|
actor: Actor;
|
|
40
|
+
graphqlClient: ExpoGraphqlClient;
|
|
38
41
|
exp: ExpoConfig;
|
|
39
42
|
projectId: string;
|
|
40
43
|
}): Promise<SubmissionContext<T>>;
|
package/build/submit/context.js
CHANGED
|
@@ -6,16 +6,17 @@ const events_1 = require("../analytics/events");
|
|
|
6
6
|
const context_1 = require("../credentials/context");
|
|
7
7
|
const projectUtils_1 = require("../project/projectUtils");
|
|
8
8
|
async function createSubmissionContextAsync(params) {
|
|
9
|
-
const { applicationIdentifier, projectDir, nonInteractive, actor, exp, projectId } = params;
|
|
9
|
+
const { applicationIdentifier, projectDir, nonInteractive, actor, exp, projectId, graphqlClient, } = params;
|
|
10
10
|
const { env, ...rest } = params;
|
|
11
11
|
const projectName = exp.slug;
|
|
12
|
-
const account = await (0, projectUtils_1.getOwnerAccountForProjectIdAsync)(projectId);
|
|
12
|
+
const account = await (0, projectUtils_1.getOwnerAccountForProjectIdAsync)(graphqlClient, projectId);
|
|
13
13
|
const accountId = account.id;
|
|
14
14
|
let credentialsCtx = params.credentialsCtx;
|
|
15
15
|
if (!credentialsCtx) {
|
|
16
16
|
credentialsCtx = new context_1.CredentialsContext({
|
|
17
17
|
projectDir,
|
|
18
18
|
user: actor,
|
|
19
|
+
graphqlClient,
|
|
19
20
|
projectInfo: { exp, projectId },
|
|
20
21
|
nonInteractive,
|
|
21
22
|
});
|
|
@@ -15,7 +15,7 @@ class IosSubmitter extends BaseSubmitter_1.default {
|
|
|
15
15
|
constructor(ctx, options) {
|
|
16
16
|
const sourceOptionsResolver = {
|
|
17
17
|
// eslint-disable-next-line async-protect/async-suffix
|
|
18
|
-
archive: async () => await (0, ArchiveSource_1.getArchiveAsync)(this.options.archiveSource),
|
|
18
|
+
archive: async () => await (0, ArchiveSource_1.getArchiveAsync)(ctx.graphqlClient, this.options.archiveSource),
|
|
19
19
|
// eslint-disable-next-line async-protect/async-suffix
|
|
20
20
|
credentials: async () => {
|
|
21
21
|
const maybeAppSpecificPassword = this.options.appSpecificPasswordSource
|
|
@@ -59,7 +59,7 @@ class IosSubmitter extends BaseSubmitter_1.default {
|
|
|
59
59
|
};
|
|
60
60
|
}
|
|
61
61
|
async createPlatformSubmissionAsync({ projectId, submissionConfig, buildId, }) {
|
|
62
|
-
return await SubmissionMutation_1.SubmissionMutation.createIosSubmissionAsync({
|
|
62
|
+
return await SubmissionMutation_1.SubmissionMutation.createIosSubmissionAsync(this.ctx.graphqlClient, {
|
|
63
63
|
appId: projectId,
|
|
64
64
|
config: submissionConfig,
|
|
65
65
|
submittedBuildId: buildId,
|
package/build/submit/submit.d.ts
CHANGED
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import { Platform } from '@expo/eas-build-job';
|
|
2
|
+
import { ExpoGraphqlClient } from '../commandUtils/context/contextUtils/createGraphqlClient';
|
|
2
3
|
import { SubmissionFragment } from '../graphql/generated';
|
|
3
4
|
import { SubmissionContext } from './context';
|
|
4
5
|
export declare function submitAsync<T extends Platform>(ctx: SubmissionContext<T>): Promise<SubmissionFragment>;
|
|
5
|
-
export declare function waitToCompleteAsync(submissions: SubmissionFragment[], { verbose }?: {
|
|
6
|
+
export declare function waitToCompleteAsync(graphqlClient: ExpoGraphqlClient, submissions: SubmissionFragment[], { verbose }?: {
|
|
6
7
|
verbose?: boolean;
|
|
7
8
|
}): Promise<SubmissionFragment[]>;
|
|
8
9
|
export declare function exitWithNonZeroCodeIfSomeSubmissionsDidntFinish(submissions: SubmissionFragment[]): void;
|
package/build/submit/submit.js
CHANGED
|
@@ -27,9 +27,9 @@ async function submitAsync(ctx) {
|
|
|
27
27
|
});
|
|
28
28
|
}
|
|
29
29
|
exports.submitAsync = submitAsync;
|
|
30
|
-
async function waitToCompleteAsync(submissions, { verbose = false } = {}) {
|
|
30
|
+
async function waitToCompleteAsync(graphqlClient, submissions, { verbose = false } = {}) {
|
|
31
31
|
log_1.default.newLine();
|
|
32
|
-
const completedSubmissions = await (0, wait_1.waitForSubmissionsEndAsync)(submissions);
|
|
32
|
+
const completedSubmissions = await (0, wait_1.waitForSubmissionsEndAsync)(graphqlClient, submissions);
|
|
33
33
|
const moreSubmissions = completedSubmissions.length > 1;
|
|
34
34
|
if (moreSubmissions) {
|
|
35
35
|
log_1.default.newLine();
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
+
import { ExpoGraphqlClient } from '../../commandUtils/context/contextUtils/createGraphqlClient';
|
|
1
2
|
import { AppPlatform, BuildFragment } from '../../graphql/generated';
|
|
2
|
-
export declare function getRecentBuildsForSubmissionAsync(platform: AppPlatform, appId: string, { limit }?: {
|
|
3
|
+
export declare function getRecentBuildsForSubmissionAsync(graphqlClient: ExpoGraphqlClient, platform: AppPlatform, appId: string, { limit }?: {
|
|
3
4
|
limit?: number;
|
|
4
5
|
}): Promise<BuildFragment[]>;
|
|
@@ -3,8 +3,8 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.getRecentBuildsForSubmissionAsync = void 0;
|
|
4
4
|
const generated_1 = require("../../graphql/generated");
|
|
5
5
|
const BuildQuery_1 = require("../../graphql/queries/BuildQuery");
|
|
6
|
-
async function getRecentBuildsForSubmissionAsync(platform, appId, { limit = 1 } = {}) {
|
|
7
|
-
return await BuildQuery_1.BuildQuery.viewBuildsOnAppAsync({
|
|
6
|
+
async function getRecentBuildsForSubmissionAsync(graphqlClient, platform, appId, { limit = 1 } = {}) {
|
|
7
|
+
return await BuildQuery_1.BuildQuery.viewBuildsOnAppAsync(graphqlClient, {
|
|
8
8
|
appId,
|
|
9
9
|
limit,
|
|
10
10
|
offset: 0,
|
|
@@ -14,9 +14,13 @@ var SubmissionErrorCode;
|
|
|
14
14
|
SubmissionErrorCode["ANDROID_FIRST_UPLOAD_ERROR"] = "SUBMISSION_SERVICE_ANDROID_FIRST_UPLOAD_ERROR";
|
|
15
15
|
SubmissionErrorCode["ANDROID_OLD_VERSION_CODE_ERROR"] = "SUBMISSION_SERVICE_ANDROID_OLD_VERSION_CODE_ERROR";
|
|
16
16
|
SubmissionErrorCode["ANDROID_MISSING_PRIVACY_POLICY"] = "SUBMISSION_SERVICE_ANDROID_MISSING_PRIVACY_POLICY";
|
|
17
|
-
SubmissionErrorCode["
|
|
17
|
+
SubmissionErrorCode["IOS_OLD_APP_VERSION"] = "SUBMISSION_SERVICE_IOS_OLD_APP_VERSION";
|
|
18
|
+
SubmissionErrorCode["IOS_OLD_BUILD_NUMBER"] = "SUBMISSION_SERVICE_IOS_OLD_BUILD_NUMBER";
|
|
19
|
+
SubmissionErrorCode["IOS_INVALID_APP_VERSION_NUMBER"] = "SUBMISSION_SERVICE_IOS_INVALID_APP_VERSION_NUMBER";
|
|
20
|
+
SubmissionErrorCode["IOS_INVALID_BUILD_NUMBER"] = "SUBMISSION_SERVICE_IOS_INVALID_BUILD_NUMBER";
|
|
18
21
|
SubmissionErrorCode["IOS_UNKNOWN_ERROR"] = "SUBMISSION_SERVICE_IOS_UNKNOWN_ERROR";
|
|
19
22
|
SubmissionErrorCode["IOS_MISSING_APP_ICON"] = "SUBMISSION_SERVICE_IOS_MISSING_APP_ICON";
|
|
23
|
+
SubmissionErrorCode["IOS_TRANSPARENT_APP_ICON"] = "SUBMISSION_SERVICE_IOS_TRANSPARENT_APP_ICON";
|
|
20
24
|
SubmissionErrorCode["IOS_INVALID_SIGNATURE"] = "SUBMISSION_SERVICE_IOS_INVALID_SIGNATURE";
|
|
21
25
|
SubmissionErrorCode["IOS_INCORRECT_CREDENTIALS"] = "SUBMISSION_SERVICE_IOS_INVALID_CREDENTIALS";
|
|
22
26
|
SubmissionErrorCode["IOS_IPAD_INVALID_ORIENTATION"] = "SUBMISSION_SERVICE_IOS_IPAD_INVALID_ORIENTATION";
|
|
@@ -39,14 +43,26 @@ const SubmissionErrorMessages = {
|
|
|
39
43
|
`${(0, log_1.learnMore)('https://expo.fyi/bumping-android-version-code')}.`,
|
|
40
44
|
[SubmissionErrorCode.ANDROID_MISSING_PRIVACY_POLICY]: 'The app has permissions that require a privacy policy set for the app.\n' +
|
|
41
45
|
`${(0, log_1.learnMore)('https://expo.fyi/missing-privacy-policy')}.`,
|
|
42
|
-
[SubmissionErrorCode.
|
|
43
|
-
'Versions are identified by
|
|
44
|
-
"If you're submitting an Expo project built with EAS Build, increment the
|
|
46
|
+
[SubmissionErrorCode.IOS_OLD_APP_VERSION]: "You've already submitted this version of the app.\n" +
|
|
47
|
+
'Versions are identified by CFBundleShortVersionString from Info.plist (expo.version in app.json).\n' +
|
|
48
|
+
"If you're submitting an Expo project built with EAS Build, increment the version (expo.version) in app.json and build the project again.",
|
|
49
|
+
[SubmissionErrorCode.IOS_OLD_BUILD_NUMBER]: "You've already submitted this build of the app.\n" +
|
|
50
|
+
'Builds are identified by CFBundleVersion from Info.plist (expo.ios.buildNumber in app.json).\n' +
|
|
51
|
+
"If you're submitting an Expo project built with EAS Build, increment the build number (expo.ios.buildNumber) in app.json and build the project again.\n" +
|
|
45
52
|
`${(0, log_1.learnMore)('https://expo.fyi/bumping-ios-build-number')}.`,
|
|
53
|
+
[SubmissionErrorCode.IOS_INVALID_APP_VERSION_NUMBER]: 'Invalid app version number.\n' +
|
|
54
|
+
'Versions are identified by CFBundleShortVersionString from Info.plist (expo.version in app.json).\n' +
|
|
55
|
+
"If you're submitting an Expo project built with EAS Build, fix the version (expo.version) in app.json and build the project again.\n" +
|
|
56
|
+
`${(0, log_1.learnMore)('https://developer.apple.com/documentation/bundleresources/information_property_list/cfbundleshortversionstring')}.`,
|
|
57
|
+
[SubmissionErrorCode.IOS_INVALID_BUILD_NUMBER]: 'Invalid build number.\n' +
|
|
58
|
+
'Builds are identified by CFBundleVersion from Info.plist (expo.ios.buildNumber in app.json).\n' +
|
|
59
|
+
"If you're submitting an Expo project built with EAS Build, fix the build number (expo.ios.buildNumber) in app.json and build the project again.\n" +
|
|
60
|
+
`${(0, log_1.learnMore)('https://developer.apple.com/documentation/bundleresources/information_property_list/cfbundleversion')}.`,
|
|
46
61
|
[SubmissionErrorCode.IOS_UNKNOWN_ERROR]: "We couldn't figure out what went wrong. See logs to learn more.",
|
|
47
62
|
[SubmissionErrorCode.IOS_MISSING_APP_ICON]: 'Your iOS app icon is missing or is an invalid format. The icon must be a 1024x1024 PNG image with no transparency.\n' +
|
|
48
63
|
'Check your icon image and icon configuration in app.json.\n' +
|
|
49
64
|
`${(0, log_1.learnMore)('https://docs.expo.dev/guides/app-icons/')}`,
|
|
65
|
+
[SubmissionErrorCode.IOS_TRANSPARENT_APP_ICON]: `Invalid App Store Icon. The App Store Icon can't be transparent nor contain an alpha channel.`,
|
|
50
66
|
[SubmissionErrorCode.IOS_INVALID_SIGNATURE]: 'Your app signature seems to be invalid.\n' +
|
|
51
67
|
"Check your iOS Distribution Certificate and your app's Provisioning Profile.\n" +
|
|
52
68
|
`${(0, log_1.learnMore)('https://docs.expo.dev/distribution/app-signing')}`,
|
|
@@ -1,2 +1,3 @@
|
|
|
1
|
+
import { ExpoGraphqlClient } from '../../commandUtils/context/contextUtils/createGraphqlClient';
|
|
1
2
|
export declare function isExistingFileAsync(filePath: string): Promise<boolean>;
|
|
2
|
-
export declare function uploadAppArchiveAsync(path: string): Promise<string>;
|
|
3
|
+
export declare function uploadAppArchiveAsync(graphqlClient: ExpoGraphqlClient, path: string): Promise<string>;
|
|
@@ -16,9 +16,9 @@ async function isExistingFileAsync(filePath) {
|
|
|
16
16
|
}
|
|
17
17
|
}
|
|
18
18
|
exports.isExistingFileAsync = isExistingFileAsync;
|
|
19
|
-
async function uploadAppArchiveAsync(path) {
|
|
19
|
+
async function uploadAppArchiveAsync(graphqlClient, path) {
|
|
20
20
|
const fileSize = (await fs_extra_1.default.stat(path)).size;
|
|
21
|
-
const { url } = await (0, uploads_1.uploadFileAtPathToS3Async)(generated_1.UploadSessionType.EasSubmitAppArchive, path, (0, progress_1.createProgressTracker)({
|
|
21
|
+
const { url } = await (0, uploads_1.uploadFileAtPathToS3Async)(graphqlClient, generated_1.UploadSessionType.EasSubmitAppArchive, path, (0, progress_1.createProgressTracker)({
|
|
22
22
|
total: fileSize,
|
|
23
23
|
message: 'Uploading to EAS Submit',
|
|
24
24
|
completedMessage: 'Uploaded to EAS Submit',
|
|
@@ -1,2 +1,3 @@
|
|
|
1
|
+
import { ExpoGraphqlClient } from '../../commandUtils/context/contextUtils/createGraphqlClient';
|
|
1
2
|
import { SubmissionFragment } from '../../graphql/generated';
|
|
2
|
-
export declare function waitForSubmissionsEndAsync(initialSubmissions: SubmissionFragment[]): Promise<SubmissionFragment[]>;
|
|
3
|
+
export declare function waitForSubmissionsEndAsync(graphqlClient: ExpoGraphqlClient, initialSubmissions: SubmissionFragment[]): Promise<SubmissionFragment[]>;
|
|
@@ -13,13 +13,13 @@ const APP_STORE_NAMES = {
|
|
|
13
13
|
[generated_1.AppPlatform.Ios]: 'Apple App Store Connect',
|
|
14
14
|
};
|
|
15
15
|
const CHECK_INTERVAL_MS = 5000;
|
|
16
|
-
async function waitForSubmissionsEndAsync(initialSubmissions) {
|
|
16
|
+
async function waitForSubmissionsEndAsync(graphqlClient, initialSubmissions) {
|
|
17
17
|
log_1.default.log(`Waiting for submission${initialSubmissions.length > 1 ? 's' : ''} to complete. You can press Ctrl+C to exit.`);
|
|
18
18
|
const spinner = (0, ora_1.ora)(`Submitting`).start();
|
|
19
19
|
while (true) {
|
|
20
20
|
const submissions = await Promise.all(initialSubmissions.map(({ id }) => {
|
|
21
21
|
try {
|
|
22
|
-
return SubmissionQuery_1.SubmissionQuery.byIdAsync(id, { useCache: false });
|
|
22
|
+
return SubmissionQuery_1.SubmissionQuery.byIdAsync(graphqlClient, id, { useCache: false });
|
|
23
23
|
}
|
|
24
24
|
catch (err) {
|
|
25
25
|
log_1.default.debug('Failed to fetch the submission status', err);
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { ExpoConfig } from '@expo/config';
|
|
2
|
-
|
|
2
|
+
import { ExpoGraphqlClient } from '../../commandUtils/context/contextUtils/createGraphqlClient';
|
|
3
|
+
export declare function syncUpdatesConfigurationAsync(graphqlClient: ExpoGraphqlClient, projectDir: string, exp: ExpoConfig, projectId: string): Promise<void>;
|
|
3
4
|
export declare function readReleaseChannelSafelyAsync(projectDir: string): Promise<string | null>;
|
|
4
5
|
export declare function readChannelSafelyAsync(projectDir: string): Promise<string | null>;
|
|
@@ -5,9 +5,9 @@ const config_plugins_1 = require("@expo/config-plugins");
|
|
|
5
5
|
const platform_1 = require("../../platform");
|
|
6
6
|
const projectUtils_1 = require("../../project/projectUtils");
|
|
7
7
|
const utils_1 = require("../utils");
|
|
8
|
-
async function syncUpdatesConfigurationAsync(projectDir, exp, projectId) {
|
|
8
|
+
async function syncUpdatesConfigurationAsync(graphqlClient, projectDir, exp, projectId) {
|
|
9
9
|
(0, utils_1.ensureValidVersions)(exp, platform_1.RequestedPlatform.Android);
|
|
10
|
-
const accountName = (await (0, projectUtils_1.getOwnerAccountForProjectIdAsync)(projectId)).name;
|
|
10
|
+
const accountName = (await (0, projectUtils_1.getOwnerAccountForProjectIdAsync)(graphqlClient, projectId)).name;
|
|
11
11
|
const androidManifestPath = await config_plugins_1.AndroidConfig.Paths.getAndroidManifestAsync(projectDir);
|
|
12
12
|
const androidManifest = await getAndroidManifestAsync(projectDir);
|
|
13
13
|
const updatedAndroidManifest = config_plugins_1.AndroidConfig.Updates.setUpdatesConfig(projectDir, exp, androidManifest, accountName);
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { ExpoConfig } from '@expo/config';
|
|
2
|
-
|
|
2
|
+
import { ExpoGraphqlClient } from '../../commandUtils/context/contextUtils/createGraphqlClient';
|
|
3
|
+
export declare function syncUpdatesConfigurationAsync(graphqlClient: ExpoGraphqlClient, projectDir: string, exp: ExpoConfig, projectId: string): Promise<void>;
|
|
3
4
|
export declare function readReleaseChannelSafelyAsync(projectDir: string): Promise<string | null>;
|
|
4
5
|
export declare function readChannelSafelyAsync(projectDir: string): Promise<string | null>;
|
|
@@ -7,9 +7,9 @@ const projectUtils_1 = require("../../project/projectUtils");
|
|
|
7
7
|
const plist_1 = require("../../utils/plist");
|
|
8
8
|
const vcs_1 = require("../../vcs");
|
|
9
9
|
const utils_1 = require("../utils");
|
|
10
|
-
async function syncUpdatesConfigurationAsync(projectDir, exp, projectId) {
|
|
10
|
+
async function syncUpdatesConfigurationAsync(graphqlClient, projectDir, exp, projectId) {
|
|
11
11
|
(0, utils_1.ensureValidVersions)(exp, platform_1.RequestedPlatform.Ios);
|
|
12
|
-
const accountName = (await (0, projectUtils_1.getOwnerAccountForProjectIdAsync)(projectId)).name;
|
|
12
|
+
const accountName = (await (0, projectUtils_1.getOwnerAccountForProjectIdAsync)(graphqlClient, projectId)).name;
|
|
13
13
|
const expoPlist = await readExpoPlistAsync(projectDir);
|
|
14
14
|
const updatedExpoPlist = config_plugins_1.IOSConfig.Updates.setUpdatesConfig(projectDir, exp, expoPlist, accountName);
|
|
15
15
|
await writeExpoPlistAsync(projectDir, updatedExpoPlist);
|
|
@@ -1,17 +1,18 @@
|
|
|
1
|
+
import { ExpoGraphqlClient } from '../commandUtils/context/contextUtils/createGraphqlClient';
|
|
1
2
|
import { PaginatedQueryOptions } from '../commandUtils/pagination';
|
|
2
3
|
import { UpdateFragment } from '../graphql/generated';
|
|
3
4
|
export declare const UPDATES_LIMIT = 50;
|
|
4
5
|
export declare const UPDATE_GROUPS_LIMIT = 25;
|
|
5
|
-
export declare function listAndRenderUpdateGroupsOnAppAsync({ projectId, paginatedQueryOptions, }: {
|
|
6
|
+
export declare function listAndRenderUpdateGroupsOnAppAsync(graphqlClient: ExpoGraphqlClient, { projectId, paginatedQueryOptions, }: {
|
|
6
7
|
projectId: string;
|
|
7
8
|
paginatedQueryOptions: PaginatedQueryOptions;
|
|
8
9
|
}): Promise<void>;
|
|
9
|
-
export declare function listAndRenderUpdateGroupsOnBranchAsync({ projectId, branchName, paginatedQueryOptions, }: {
|
|
10
|
+
export declare function listAndRenderUpdateGroupsOnBranchAsync(graphqlClient: ExpoGraphqlClient, { projectId, branchName, paginatedQueryOptions, }: {
|
|
10
11
|
projectId: string;
|
|
11
12
|
branchName: string;
|
|
12
13
|
paginatedQueryOptions: PaginatedQueryOptions;
|
|
13
14
|
}): Promise<void>;
|
|
14
|
-
export declare function selectUpdateGroupOnBranchAsync({ projectId, branchName, paginatedQueryOptions, }: {
|
|
15
|
+
export declare function selectUpdateGroupOnBranchAsync(graphqlClient: ExpoGraphqlClient, { projectId, branchName, paginatedQueryOptions, }: {
|
|
15
16
|
projectId: string;
|
|
16
17
|
branchName: string;
|
|
17
18
|
paginatedQueryOptions: PaginatedQueryOptions;
|
package/build/update/queries.js
CHANGED
|
@@ -13,10 +13,10 @@ const queries_1 = require("../utils/queries");
|
|
|
13
13
|
const utils_1 = require("./utils");
|
|
14
14
|
exports.UPDATES_LIMIT = 50;
|
|
15
15
|
exports.UPDATE_GROUPS_LIMIT = 25;
|
|
16
|
-
async function listAndRenderUpdateGroupsOnAppAsync({ projectId, paginatedQueryOptions, }) {
|
|
16
|
+
async function listAndRenderUpdateGroupsOnAppAsync(graphqlClient, { projectId, paginatedQueryOptions, }) {
|
|
17
17
|
var _a, _b;
|
|
18
18
|
if (paginatedQueryOptions.nonInteractive) {
|
|
19
|
-
const updateGroups = await queryUpdateGroupsOnAppAsync({
|
|
19
|
+
const updateGroups = await queryUpdateGroupsOnAppAsync(graphqlClient, {
|
|
20
20
|
limit: (_a = paginatedQueryOptions.limit) !== null && _a !== void 0 ? _a : exports.UPDATE_GROUPS_LIMIT,
|
|
21
21
|
offset: paginatedQueryOptions.offset,
|
|
22
22
|
appId: projectId,
|
|
@@ -27,7 +27,7 @@ async function listAndRenderUpdateGroupsOnAppAsync({ projectId, paginatedQueryOp
|
|
|
27
27
|
await (0, queries_1.paginatedQueryWithConfirmPromptAsync)({
|
|
28
28
|
limit: (_b = paginatedQueryOptions.limit) !== null && _b !== void 0 ? _b : exports.UPDATE_GROUPS_LIMIT,
|
|
29
29
|
offset: paginatedQueryOptions.offset,
|
|
30
|
-
queryToPerform: (limit, offset) => queryUpdateGroupsOnAppAsync({ limit, offset, appId: projectId }),
|
|
30
|
+
queryToPerform: (limit, offset) => queryUpdateGroupsOnAppAsync(graphqlClient, { limit, offset, appId: projectId }),
|
|
31
31
|
promptOptions: {
|
|
32
32
|
title: 'Load more update groups?',
|
|
33
33
|
renderListItems: updateGroups => renderUpdateGroupsOnAppAsTable(updateGroups, paginatedQueryOptions),
|
|
@@ -36,10 +36,10 @@ async function listAndRenderUpdateGroupsOnAppAsync({ projectId, paginatedQueryOp
|
|
|
36
36
|
}
|
|
37
37
|
}
|
|
38
38
|
exports.listAndRenderUpdateGroupsOnAppAsync = listAndRenderUpdateGroupsOnAppAsync;
|
|
39
|
-
async function listAndRenderUpdateGroupsOnBranchAsync({ projectId, branchName, paginatedQueryOptions, }) {
|
|
39
|
+
async function listAndRenderUpdateGroupsOnBranchAsync(graphqlClient, { projectId, branchName, paginatedQueryOptions, }) {
|
|
40
40
|
var _a, _b;
|
|
41
41
|
if (paginatedQueryOptions.nonInteractive) {
|
|
42
|
-
const updateGroups = await queryUpdateGroupsOnBranchAsync({
|
|
42
|
+
const updateGroups = await queryUpdateGroupsOnBranchAsync(graphqlClient, {
|
|
43
43
|
limit: (_a = paginatedQueryOptions.limit) !== null && _a !== void 0 ? _a : exports.UPDATE_GROUPS_LIMIT,
|
|
44
44
|
offset: paginatedQueryOptions.offset,
|
|
45
45
|
appId: projectId,
|
|
@@ -51,7 +51,12 @@ async function listAndRenderUpdateGroupsOnBranchAsync({ projectId, branchName, p
|
|
|
51
51
|
await (0, queries_1.paginatedQueryWithConfirmPromptAsync)({
|
|
52
52
|
limit: (_b = paginatedQueryOptions.limit) !== null && _b !== void 0 ? _b : exports.UPDATE_GROUPS_LIMIT,
|
|
53
53
|
offset: paginatedQueryOptions.offset,
|
|
54
|
-
queryToPerform: (limit, offset) => queryUpdateGroupsOnBranchAsync(
|
|
54
|
+
queryToPerform: (limit, offset) => queryUpdateGroupsOnBranchAsync(graphqlClient, {
|
|
55
|
+
limit,
|
|
56
|
+
offset,
|
|
57
|
+
appId: projectId,
|
|
58
|
+
branchName,
|
|
59
|
+
}),
|
|
55
60
|
promptOptions: {
|
|
56
61
|
title: 'Load more update groups?',
|
|
57
62
|
renderListItems: updateGroups => renderUpdateGroupsOnBranchAsTable({ updateGroups, branchName, paginatedQueryOptions }),
|
|
@@ -60,7 +65,7 @@ async function listAndRenderUpdateGroupsOnBranchAsync({ projectId, branchName, p
|
|
|
60
65
|
}
|
|
61
66
|
}
|
|
62
67
|
exports.listAndRenderUpdateGroupsOnBranchAsync = listAndRenderUpdateGroupsOnBranchAsync;
|
|
63
|
-
async function selectUpdateGroupOnBranchAsync({ projectId, branchName, paginatedQueryOptions, }) {
|
|
68
|
+
async function selectUpdateGroupOnBranchAsync(graphqlClient, { projectId, branchName, paginatedQueryOptions, }) {
|
|
64
69
|
var _a;
|
|
65
70
|
if (paginatedQueryOptions.nonInteractive) {
|
|
66
71
|
throw new Error('Unable to select an update in non-interactive mode.');
|
|
@@ -68,7 +73,12 @@ async function selectUpdateGroupOnBranchAsync({ projectId, branchName, paginated
|
|
|
68
73
|
const updateGroup = await (0, queries_1.paginatedQueryWithSelectPromptAsync)({
|
|
69
74
|
limit: (_a = paginatedQueryOptions.limit) !== null && _a !== void 0 ? _a : exports.UPDATE_GROUPS_LIMIT,
|
|
70
75
|
offset: paginatedQueryOptions.offset,
|
|
71
|
-
queryToPerform: (limit, offset) => queryUpdateGroupsOnBranchAsync(
|
|
76
|
+
queryToPerform: (limit, offset) => queryUpdateGroupsOnBranchAsync(graphqlClient, {
|
|
77
|
+
appId: projectId,
|
|
78
|
+
branchName,
|
|
79
|
+
limit,
|
|
80
|
+
offset,
|
|
81
|
+
}),
|
|
72
82
|
promptOptions: {
|
|
73
83
|
title: 'Load more update groups?',
|
|
74
84
|
createDisplayTextForSelectionPromptListItem: updateGroup => (0, utils_1.formatUpdateTitle)(updateGroup[0]),
|
|
@@ -81,11 +91,11 @@ async function selectUpdateGroupOnBranchAsync({ projectId, branchName, paginated
|
|
|
81
91
|
return updateGroup;
|
|
82
92
|
}
|
|
83
93
|
exports.selectUpdateGroupOnBranchAsync = selectUpdateGroupOnBranchAsync;
|
|
84
|
-
async function queryUpdateGroupsOnBranchAsync(args) {
|
|
85
|
-
return await UpdateQuery_1.UpdateQuery.viewUpdateGroupsOnBranchAsync(args);
|
|
94
|
+
async function queryUpdateGroupsOnBranchAsync(graphqlClient, args) {
|
|
95
|
+
return await UpdateQuery_1.UpdateQuery.viewUpdateGroupsOnBranchAsync(graphqlClient, args);
|
|
86
96
|
}
|
|
87
|
-
async function queryUpdateGroupsOnAppAsync(args) {
|
|
88
|
-
return await UpdateQuery_1.UpdateQuery.viewUpdateGroupsOnAppAsync(args);
|
|
97
|
+
async function queryUpdateGroupsOnAppAsync(graphqlClient, args) {
|
|
98
|
+
return await UpdateQuery_1.UpdateQuery.viewUpdateGroupsOnAppAsync(graphqlClient, args);
|
|
89
99
|
}
|
|
90
100
|
function renderUpdateGroupsOnBranchAsTable({ updateGroups, branchName, paginatedQueryOptions: { json }, }) {
|
|
91
101
|
var _a, _b;
|