eas-cli 16.28.0 → 16.30.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 +97 -94
- package/build/analytics/AnalyticsManager.js +4 -4
- package/build/analytics/common.js +1 -2
- package/build/api.js +5 -5
- package/build/branch/delete.js +1 -2
- package/build/branch/queries.js +5 -5
- package/build/branch/utils.js +2 -2
- package/build/build/android/build.js +3 -4
- package/build/build/android/graphql.js +1 -2
- package/build/build/android/prepareJob.js +1 -2
- package/build/build/android/syncProjectConfiguration.js +2 -3
- package/build/build/android/version.js +6 -6
- package/build/build/build.js +3 -4
- package/build/build/configure.js +4 -5
- package/build/build/createContext.js +1 -2
- package/build/build/evaluateConfigWithEnvVarsAsync.js +1 -2
- package/build/build/graphql.js +7 -7
- package/build/build/ios/build.js +2 -3
- package/build/build/ios/credentials.js +2 -3
- package/build/build/ios/graphql.js +2 -3
- package/build/build/ios/prepareJob.js +2 -3
- package/build/build/ios/syncProjectConfiguration.js +1 -2
- package/build/build/ios/version.js +10 -10
- package/build/build/local.js +2 -2
- package/build/build/metadata.js +3 -4
- package/build/build/queries.js +4 -4
- package/build/build/runBuildAndSubmit.js +2 -3
- package/build/build/utils/appJson.js +2 -3
- package/build/build/utils/credentials.js +1 -2
- package/build/build/utils/devClient.js +1 -2
- package/build/build/utils/formatBuild.js +2 -3
- package/build/build/utils/printBuildInfo.js +4 -5
- package/build/build/utils/repository.js +8 -9
- package/build/build/utils/resourceClass.js +1 -2
- package/build/build/utils/url.js +8 -9
- package/build/build/utils/version.js +2 -3
- package/build/build/validate.js +3 -4
- package/build/channel/branch-mapping.js +24 -24
- package/build/channel/delete.d.ts +5 -0
- package/build/channel/delete.js +23 -0
- package/build/channel/print-utils.js +2 -3
- package/build/channel/queries.js +8 -8
- package/build/channel/utils.js +1 -2
- package/build/commandUtils/builds.js +3 -4
- package/build/commandUtils/context/contextUtils/createGraphqlClient.js +1 -2
- package/build/commandUtils/context/contextUtils/findProjectDirAndVerifyProjectSetupAsync.js +2 -3
- package/build/commandUtils/context/contextUtils/getProjectIdAsync.js +3 -4
- package/build/commandUtils/context/contextUtils/loadServerSideEnvironmentVariablesAsync.js +1 -2
- package/build/commandUtils/experienceParser.d.ts +6 -0
- package/build/commandUtils/experienceParser.js +42 -0
- package/build/commandUtils/new/commands.js +3 -4
- package/build/commandUtils/new/configs.js +4 -5
- package/build/commandUtils/new/projectFiles.js +6 -7
- package/build/commandUtils/new/utils.js +1 -2
- package/build/commandUtils/projectNameValidation.d.ts +8 -0
- package/build/commandUtils/projectNameValidation.js +30 -0
- package/build/commandUtils/workflow/buildProfileUtils.js +12 -13
- package/build/commandUtils/workflow/creation.js +5 -5
- package/build/commandUtils/workflow/fetchLogs.js +2 -3
- package/build/commandUtils/workflow/inputs.js +5 -5
- package/build/commandUtils/workflow/stateMachine.js +7 -7
- package/build/commandUtils/workflow/utils.js +12 -12
- package/build/commandUtils/workflow/validation.js +4 -5
- package/build/commands/build/cancel.js +1 -2
- package/build/commands/build/delete.js +1 -2
- package/build/commands/build/index.js +1 -2
- package/build/commands/channel/delete.js +7 -23
- package/build/commands/channel/edit.js +1 -2
- package/build/commands/channel/pause.js +1 -2
- package/build/commands/channel/resume.js +1 -2
- package/build/commands/deploy/index.js +1 -1
- package/build/commands/project/init.js +3 -1
- package/build/commands/project/new.js +3 -4
- package/build/commands/update/index.d.ts +8 -0
- package/build/commands/update/index.js +39 -2
- package/build/commands/update/list.d.ts +3 -0
- package/build/commands/update/list.js +30 -1
- package/build/commands/update/revert-update-rollout.js +1 -2
- package/build/credentials/android/actions/BuildCredentialsUtils.js +6 -7
- package/build/credentials/android/api/GraphqlClient.js +21 -21
- package/build/credentials/android/api/graphql/queries/AndroidAppCredentialsQuery.d.ts +2 -2
- package/build/credentials/android/api/graphql/queries/GoogleServiceAccountKeyQuery.d.ts +5 -5
- package/build/credentials/android/utils/googleServiceAccountKey.js +4 -4
- package/build/credentials/android/utils/keystore.js +2 -3
- package/build/credentials/android/utils/keystoreNew.js +3 -4
- package/build/credentials/android/utils/printCredentials.js +3 -4
- package/build/credentials/credentialsJson/read.js +3 -4
- package/build/credentials/credentialsJson/update.js +2 -3
- package/build/credentials/credentialsJson/utils.js +2 -3
- package/build/credentials/ios/actions/AppleTeamFormatting.js +1 -2
- package/build/credentials/ios/actions/AppleTeamUtils.js +1 -2
- package/build/credentials/ios/actions/AscApiKeyUtils.js +10 -10
- package/build/credentials/ios/actions/BuildCredentialsUtils.js +7 -8
- package/build/credentials/ios/actions/DeviceUtils.js +2 -3
- package/build/credentials/ios/actions/DistributionCertificateUtils.js +4 -5
- package/build/credentials/ios/actions/ProvisioningProfileUtils.js +2 -3
- package/build/credentials/ios/actions/PushKeyUtils.js +5 -6
- package/build/credentials/ios/actions/SetUpAdhocProvisioningProfile.js +2 -2
- package/build/credentials/ios/actions/SetUpTargetBuildCredentials.js +6 -2
- package/build/credentials/ios/api/GraphqlClient.js +24 -25
- package/build/credentials/ios/api/graphql/queries/AppStoreConnectApiKeyQuery.d.ts +5 -5
- package/build/credentials/ios/api/graphql/queries/AppleDeviceQuery.d.ts +8 -8
- package/build/credentials/ios/api/graphql/queries/AppleDistributionCertificateQuery.d.ts +5 -5
- package/build/credentials/ios/api/graphql/queries/ApplePushKeyQuery.d.ts +5 -5
- package/build/credentials/ios/api/graphql/queries/IosAppCredentialsQuery.d.ts +1 -1
- package/build/credentials/ios/appstore/AppStoreApi.d.ts +0 -2
- package/build/credentials/ios/appstore/Credentials.js +4 -5
- package/build/credentials/ios/appstore/Credentials.types.d.ts +0 -1
- package/build/credentials/ios/appstore/CredentialsUtils.js +6 -7
- package/build/credentials/ios/appstore/ascApiKey.d.ts +0 -1
- package/build/credentials/ios/appstore/ascApiKey.js +6 -7
- package/build/credentials/ios/appstore/authenticate.d.ts +0 -1
- package/build/credentials/ios/appstore/authenticate.js +4 -5
- package/build/credentials/ios/appstore/authenticateTypes.d.ts +0 -1
- package/build/credentials/ios/appstore/bundleId.d.ts +0 -1
- package/build/credentials/ios/appstore/bundleId.js +2 -3
- package/build/credentials/ios/appstore/bundleIdCapabilities.d.ts +0 -1
- package/build/credentials/ios/appstore/bundleIdCapabilities.js +3 -3
- package/build/credentials/ios/appstore/capabilityIdentifiers.d.ts +0 -1
- package/build/credentials/ios/appstore/capabilityIdentifiers.js +1 -2
- package/build/credentials/ios/appstore/capabilityList.d.ts +0 -1
- package/build/credentials/ios/appstore/contractMessages.d.ts +0 -1
- package/build/credentials/ios/appstore/contractMessages.js +2 -3
- package/build/credentials/ios/appstore/distributionCertificate.d.ts +0 -1
- package/build/credentials/ios/appstore/distributionCertificate.js +7 -7
- package/build/credentials/ios/appstore/ensureAppExists.d.ts +6 -1
- package/build/credentials/ios/appstore/ensureAppExists.js +55 -18
- package/build/credentials/ios/appstore/ensureTestFlightGroup.d.ts +0 -1
- package/build/credentials/ios/appstore/ensureTestFlightGroup.js +1 -2
- package/build/credentials/ios/appstore/keychain.js +4 -4
- package/build/credentials/ios/appstore/provisioningProfile.d.ts +0 -1
- package/build/credentials/ios/appstore/provisioningProfile.js +5 -5
- package/build/credentials/ios/appstore/provisioningProfileAdhoc.d.ts +0 -1
- package/build/credentials/ios/appstore/provisioningProfileAdhoc.js +1 -2
- package/build/credentials/ios/appstore/pushKey.js +4 -4
- package/build/credentials/ios/appstore/resolveCredentials.d.ts +0 -1
- package/build/credentials/ios/appstore/resolveCredentials.js +6 -7
- package/build/credentials/ios/credentials.d.ts +0 -1
- package/build/credentials/ios/credentials.js +2 -2
- package/build/credentials/ios/utils/authType.d.ts +0 -1
- package/build/credentials/ios/utils/authType.js +1 -2
- package/build/credentials/ios/utils/convertHTMLToASCII.js +1 -2
- package/build/credentials/ios/utils/p12Certificate.d.ts +0 -1
- package/build/credentials/ios/utils/p12Certificate.js +3 -4
- package/build/credentials/ios/utils/printCredentials.js +3 -4
- package/build/credentials/ios/utils/provisioningProfile.js +5 -6
- package/build/credentials/ios/validators/validateAscApiKey.js +2 -3
- package/build/credentials/ios/validators/validateDistributionCertificate.js +1 -2
- package/build/credentials/ios/validators/validateProvisioningProfile.js +1 -2
- package/build/credentials/ios/validators/validatePushKey.js +1 -2
- package/build/credentials/manager/IosActions.js +4 -4
- package/build/credentials/manager/SelectPlatform.js +1 -1
- package/build/credentials/utils/promptForCredentials.js +3 -4
- package/build/devices/actions/create/currentMachineMethod.js +1 -2
- package/build/devices/actions/create/developerPortalMethod.d.ts +0 -1
- package/build/devices/actions/create/developerPortalMethod.js +2 -3
- package/build/devices/actions/create/inputMethod.js +1 -2
- package/build/devices/actions/create/registrationUrlMethod.js +1 -2
- package/build/devices/actions/create/utils.js +4 -5
- package/build/devices/context.js +1 -2
- package/build/devices/queries.js +4 -4
- package/build/devices/udids.js +2 -3
- package/build/devices/utils/formatDevice.js +2 -3
- package/build/fetch.d.ts +0 -1
- package/build/fetch.js +1 -1
- package/build/fingerprint/cli.js +3 -4
- package/build/fingerprint/diff.js +1 -2
- package/build/fingerprint/types.d.ts +0 -1
- package/build/fingerprint/utils.js +4 -5
- package/build/graphql/client.js +2 -2
- package/build/graphql/generated.d.ts +177 -88
- package/build/graphql/generated.js +39 -3
- package/build/graphql/mutations/PublishMutation.d.ts +2 -2
- package/build/graphql/queries/AccountUsageQuery.d.ts +1 -1
- package/build/graphql/queries/AppVersionQuery.d.ts +1 -1
- package/build/graphql/queries/BackgroundJobReceiptQuery.d.ts +1 -1
- package/build/graphql/queries/BranchQuery.d.ts +3 -3
- package/build/graphql/queries/BuildQuery.d.ts +3 -3
- package/build/graphql/queries/ChannelQuery.d.ts +2 -2
- package/build/graphql/queries/ChannelQuery.js +2 -2
- package/build/graphql/queries/EnvironmentVariablesQuery.d.ts +12 -12
- package/build/graphql/queries/FingerprintQuery.d.ts +6 -6
- package/build/graphql/queries/PublishQuery.d.ts +1 -1
- package/build/graphql/queries/SubmissionQuery.d.ts +1 -1
- package/build/graphql/queries/UserQuery.d.ts +1 -1
- package/build/graphql/queries/WorkflowJobQuery.d.ts +2 -2
- package/build/graphql/queries/WorkflowRunQuery.d.ts +4 -4
- package/build/graphql/types/AppPlatform.js +2 -3
- package/build/log.js +2 -3
- package/build/metadata/apple/config/reader.d.ts +0 -1
- package/build/metadata/apple/config/writer.d.ts +0 -1
- package/build/metadata/apple/data.d.ts +0 -1
- package/build/metadata/apple/tasks/age-rating.d.ts +0 -1
- package/build/metadata/apple/tasks/age-rating.js +0 -1
- package/build/metadata/apple/tasks/app-info.d.ts +0 -1
- package/build/metadata/apple/tasks/app-info.js +15 -4
- package/build/metadata/apple/tasks/app-review-detail.d.ts +0 -1
- package/build/metadata/apple/tasks/app-review-detail.js +0 -1
- package/build/metadata/apple/tasks/app-version.d.ts +0 -1
- package/build/metadata/apple/tasks/app-version.js +15 -3
- package/build/metadata/apple/tasks/index.js +1 -2
- package/build/metadata/apple/types.d.ts +0 -1
- package/build/metadata/auth.d.ts +0 -1
- package/build/metadata/auth.js +1 -2
- package/build/metadata/config/resolve.js +4 -5
- package/build/metadata/config/validate.js +1 -2
- package/build/metadata/download.js +1 -2
- package/build/metadata/errors.js +3 -3
- package/build/metadata/upload.js +1 -2
- package/build/metadata/utils/ajv.js +2 -3
- package/build/metadata/utils/asc.d.ts +0 -1
- package/build/metadata/utils/date.js +1 -2
- package/build/metadata/utils/log.js +1 -2
- package/build/metadata/utils/retry.js +2 -3
- package/build/metadata/utils/telemetry.d.ts +0 -1
- package/build/metadata/utils/telemetry.js +2 -3
- package/build/onboarding/git.js +3 -4
- package/build/onboarding/installDependencies.js +3 -3
- package/build/onboarding/runCommand.js +1 -2
- package/build/ora.js +1 -2
- package/build/platform.d.ts +1 -0
- package/build/platform.js +28 -10
- package/build/project/android/applicationId.js +6 -6
- package/build/project/android/gradle.js +1 -2
- package/build/project/android/gradleUtils.js +4 -4
- package/build/project/android/versions.js +3 -3
- package/build/project/applicationIdentifier.js +1 -2
- package/build/project/customBuildConfig.js +3 -4
- package/build/project/expoConfig.js +5 -6
- package/build/project/expoSdk.js +1 -2
- package/build/project/fetchOrCreateProjectIDForWriteToConfigWithConfirmationAsync.js +2 -3
- package/build/project/ios/bundleIdentifier.js +6 -6
- package/build/project/ios/entitlements.js +2 -3
- package/build/project/ios/exemptEncryption.js +1 -2
- package/build/project/ios/scheme.js +2 -3
- package/build/project/ios/target.d.ts +0 -1
- package/build/project/ios/target.js +8 -9
- package/build/project/ios/versions.js +3 -3
- package/build/project/maybeUploadAssetMapAsync.js +1 -2
- package/build/project/maybeUploadFingerprintAsync.js +1 -2
- package/build/project/metroConfig.js +1 -2
- package/build/project/projectUtils.js +15 -16
- package/build/project/publish.d.ts +15 -2
- package/build/project/publish.js +56 -29
- package/build/project/remoteVersionSource.js +6 -6
- package/build/project/resolveRuntimeVersionAsync.js +2 -3
- package/build/project/uploadAccountScopedFileAsync.js +1 -2
- package/build/project/uploadAccountScopedProjectSourceAsync.js +1 -2
- package/build/project/workflow.js +3 -4
- package/build/prompts.js +5 -6
- package/build/rollout/branch-mapping.js +14 -15
- package/build/rollout/utils.js +5 -6
- package/build/run/android/aapt.js +2 -3
- package/build/run/android/adb.js +8 -9
- package/build/run/android/emulator.js +6 -6
- package/build/run/android/run.js +1 -2
- package/build/run/android/sdk.d.ts +0 -1
- package/build/run/android/sdk.js +2 -2
- package/build/run/android/systemRequirements.js +1 -2
- package/build/run/ios/run.js +1 -2
- package/build/run/ios/simctl.js +1 -2
- package/build/run/ios/simulator.js +9 -10
- package/build/run/ios/systemRequirements.js +1 -2
- package/build/run/ios/xcode.js +5 -5
- package/build/run/ios/xcrun.js +3 -4
- package/build/run/run.js +2 -3
- package/build/run/utils.js +1 -2
- package/build/submit/ArchiveSource.js +3 -3
- package/build/submit/android/ServiceAccountSource.js +4 -4
- package/build/submit/commons.js +2 -3
- package/build/submit/context.js +1 -2
- package/build/submit/ios/AppProduce.js +1 -2
- package/build/submit/ios/AppSpecificPasswordSource.js +3 -3
- package/build/submit/ios/AscApiKeySource.js +4 -4
- package/build/submit/ios/utils/language.js +1 -2
- package/build/submit/submit.js +3 -4
- package/build/submit/utils/builds.js +1 -2
- package/build/submit/utils/errors.js +1 -2
- package/build/submit/utils/files.js +2 -3
- package/build/submit/utils/logs.js +1 -2
- package/build/submit/utils/summary.js +2 -3
- package/build/submit/utils/urls.js +2 -3
- package/build/submit/utils/wait.js +2 -3
- package/build/update/android/UpdatesModule.js +2 -3
- package/build/update/configure.js +4 -4
- package/build/update/delete.js +1 -2
- package/build/update/getBranchFromChannelNameAndCreateAndLinkIfNotExistsAsync.js +1 -2
- package/build/update/ios/UpdatesModule.js +2 -3
- package/build/update/queries.d.ts +5 -3
- package/build/update/queries.js +12 -9
- package/build/update/republish.js +5 -6
- package/build/update/roll-back-to-embedded.js +1 -2
- package/build/update/utils.js +15 -15
- package/build/uploads.js +3 -4
- package/build/user/User.js +2 -3
- package/build/user/actions.js +1 -2
- package/build/user/expoSsoLauncher.js +1 -2
- package/build/user/fetchSessionSecretAndSsoUser.js +1 -2
- package/build/user/fetchSessionSecretAndUser.js +1 -2
- package/build/user/fetchUser.js +1 -2
- package/build/utils/code-signing.d.ts +0 -1
- package/build/utils/code-signing.js +7 -8
- package/build/utils/date.js +1 -2
- package/build/utils/download.js +2 -3
- package/build/utils/expoCli.js +4 -4
- package/build/utils/expoUpdatesCli.js +2 -2
- package/build/utils/expodash/areSetsEqual.js +1 -1
- package/build/utils/expodash/capitalize.js +1 -1
- package/build/utils/expodash/chunk.js +1 -1
- package/build/utils/expodash/differenceBy.js +1 -1
- package/build/utils/expodash/filter.js +1 -2
- package/build/utils/expodash/groupBy.js +1 -1
- package/build/utils/expodash/intersection.js +1 -1
- package/build/utils/expodash/mapMapAsync.js +1 -1
- package/build/utils/expodash/memoize.js +1 -2
- package/build/utils/expodash/pick.js +1 -1
- package/build/utils/expodash/sortBy.js +1 -1
- package/build/utils/expodash/uniq.js +1 -1
- package/build/utils/expodash/uniqBy.js +1 -1
- package/build/utils/expodash/zipObject.js +1 -1
- package/build/utils/files.js +2 -3
- package/build/utils/formatFields.js +1 -1
- package/build/utils/image.js +3 -3
- package/build/utils/json.js +2 -3
- package/build/utils/plist.d.ts +0 -1
- package/build/utils/plist.js +3 -4
- package/build/utils/pollForBackgroundJobReceiptAsync.js +2 -2
- package/build/utils/profiles.js +3 -4
- package/build/utils/progress.js +1 -2
- package/build/utils/promise.js +1 -2
- package/build/utils/prompts.js +8 -9
- package/build/utils/queries.js +2 -3
- package/build/utils/relay.js +4 -4
- package/build/utils/statuspageService.js +1 -2
- package/build/utils/timer.js +4 -5
- package/build/utils/usage/checkForOverages.js +4 -5
- package/build/utils/variableUtils.js +4 -5
- package/build/vcs/clients/git.js +1 -2
- package/build/vcs/git.js +5 -6
- package/build/vcs/index.js +1 -2
- package/build/vcs/local.js +2 -2
- package/build/webhooks/formatWebhook.js +1 -2
- package/build/webhooks/input.js +3 -4
- package/build/worker/assets.d.ts +0 -1
- package/build/worker/assets.js +6 -7
- package/build/worker/deployment.js +8 -9
- package/build/worker/mutations.d.ts +1 -1
- package/build/worker/queries.d.ts +4 -4
- package/build/worker/upload.d.ts +0 -2
- package/build/worker/upload.js +5 -6
- package/build/worker/utils/logs.js +5 -5
- package/build/worker/utils/multipart.js +3 -3
- package/oclif.manifest.json +35 -1
- package/package.json +13 -11
|
@@ -1,6 +1,12 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.executeWorkflowSelectionActionsAsync = exports.workflowStepSelectionAction = exports.workflowJobSelectionAction = exports.workflowRunSelectionAction = exports.
|
|
3
|
+
exports.executeWorkflowSelectionActionsAsync = exports.workflowStepSelectionAction = exports.workflowJobSelectionAction = exports.workflowRunSelectionAction = exports.WorkflowCommandSelectionStateValue = void 0;
|
|
4
|
+
exports.moveToNewWorkflowCommandSelectionState = moveToNewWorkflowCommandSelectionState;
|
|
5
|
+
exports.moveToWorkflowRunSelectionState = moveToWorkflowRunSelectionState;
|
|
6
|
+
exports.moveToWorkflowJobSelectionState = moveToWorkflowJobSelectionState;
|
|
7
|
+
exports.moveToWorkflowStepSelectionState = moveToWorkflowStepSelectionState;
|
|
8
|
+
exports.moveToWorkflowSelectionFinishedState = moveToWorkflowSelectionFinishedState;
|
|
9
|
+
exports.moveToWorkflowSelectionErrorState = moveToWorkflowSelectionErrorState;
|
|
4
10
|
const tslib_1 = require("tslib");
|
|
5
11
|
const utils_1 = require("./utils");
|
|
6
12
|
const AppQuery_1 = require("../../graphql/queries/AppQuery");
|
|
@@ -49,32 +55,26 @@ function moveToNewWorkflowCommandSelectionState(previousState, newStateValue, pa
|
|
|
49
55
|
...parameters,
|
|
50
56
|
};
|
|
51
57
|
}
|
|
52
|
-
exports.moveToNewWorkflowCommandSelectionState = moveToNewWorkflowCommandSelectionState;
|
|
53
58
|
function moveToWorkflowRunSelectionState(previousState, params) {
|
|
54
59
|
return moveToNewWorkflowCommandSelectionState(previousState, WorkflowCommandSelectionStateValue.WORKFLOW_RUN_SELECTION, {
|
|
55
60
|
runId: params?.runId,
|
|
56
61
|
jobId: undefined,
|
|
57
62
|
});
|
|
58
63
|
}
|
|
59
|
-
exports.moveToWorkflowRunSelectionState = moveToWorkflowRunSelectionState;
|
|
60
64
|
function moveToWorkflowJobSelectionState(previousState, params) {
|
|
61
65
|
return moveToNewWorkflowCommandSelectionState(previousState, WorkflowCommandSelectionStateValue.WORKFLOW_JOB_SELECTION, params);
|
|
62
66
|
}
|
|
63
|
-
exports.moveToWorkflowJobSelectionState = moveToWorkflowJobSelectionState;
|
|
64
67
|
function moveToWorkflowStepSelectionState(previousState, params) {
|
|
65
68
|
return moveToNewWorkflowCommandSelectionState(previousState, WorkflowCommandSelectionStateValue.WORKFLOW_STEP_SELECTION, params);
|
|
66
69
|
}
|
|
67
|
-
exports.moveToWorkflowStepSelectionState = moveToWorkflowStepSelectionState;
|
|
68
70
|
function moveToWorkflowSelectionFinishedState(previousState, params) {
|
|
69
71
|
return moveToNewWorkflowCommandSelectionState(previousState, WorkflowCommandSelectionStateValue.FINISH, params);
|
|
70
72
|
}
|
|
71
|
-
exports.moveToWorkflowSelectionFinishedState = moveToWorkflowSelectionFinishedState;
|
|
72
73
|
function moveToWorkflowSelectionErrorState(previousState, message) {
|
|
73
74
|
return moveToNewWorkflowCommandSelectionState(previousState, WorkflowCommandSelectionStateValue.ERROR, {
|
|
74
75
|
message,
|
|
75
76
|
});
|
|
76
77
|
}
|
|
77
|
-
exports.moveToWorkflowSelectionErrorState = moveToWorkflowSelectionErrorState;
|
|
78
78
|
// eslint-disable-next-line async-protect/async-suffix
|
|
79
79
|
const workflowRunSelectionAction = async (prevState) => {
|
|
80
80
|
const { graphqlClient, projectId, runId, jobId, allSteps } = prevState;
|
|
@@ -1,6 +1,17 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.workflowRunExitCodes =
|
|
3
|
+
exports.workflowRunExitCodes = void 0;
|
|
4
|
+
exports.computeTriggerInfoForWorkflowRun = computeTriggerInfoForWorkflowRun;
|
|
5
|
+
exports.choiceFromWorkflowRun = choiceFromWorkflowRun;
|
|
6
|
+
exports.choiceFromWorkflowJob = choiceFromWorkflowJob;
|
|
7
|
+
exports.choicesFromWorkflowLogs = choicesFromWorkflowLogs;
|
|
8
|
+
exports.processWorkflowRuns = processWorkflowRuns;
|
|
9
|
+
exports.fetchAndProcessLogsFromJobAsync = fetchAndProcessLogsFromJobAsync;
|
|
10
|
+
exports.infoForActiveWorkflowRunAsync = infoForActiveWorkflowRunAsync;
|
|
11
|
+
exports.infoForFailedWorkflowRunAsync = infoForFailedWorkflowRunAsync;
|
|
12
|
+
exports.fileExistsAsync = fileExistsAsync;
|
|
13
|
+
exports.maybeReadStdinAsync = maybeReadStdinAsync;
|
|
14
|
+
exports.showWorkflowStatusAsync = showWorkflowStatusAsync;
|
|
4
15
|
const tslib_1 = require("tslib");
|
|
5
16
|
const chalk_1 = tslib_1.__importDefault(require("chalk"));
|
|
6
17
|
const fs = tslib_1.__importStar(require("node:fs"));
|
|
@@ -41,7 +52,6 @@ function computeTriggerInfoForWorkflowRun(run) {
|
|
|
41
52
|
}
|
|
42
53
|
return { triggerType, trigger };
|
|
43
54
|
}
|
|
44
|
-
exports.computeTriggerInfoForWorkflowRun = computeTriggerInfoForWorkflowRun;
|
|
45
55
|
function choiceFromWorkflowRun(run) {
|
|
46
56
|
const titleArray = [
|
|
47
57
|
run.workflowFileName,
|
|
@@ -56,7 +66,6 @@ function choiceFromWorkflowRun(run) {
|
|
|
56
66
|
description: `ID: ${run.id}, Message: ${run.gitCommitMessage?.split('\n')[0] ?? ''}`,
|
|
57
67
|
};
|
|
58
68
|
}
|
|
59
|
-
exports.choiceFromWorkflowRun = choiceFromWorkflowRun;
|
|
60
69
|
function choiceFromWorkflowJob(job, index) {
|
|
61
70
|
return {
|
|
62
71
|
title: `${job.name} - ${job.status}`,
|
|
@@ -64,7 +73,6 @@ function choiceFromWorkflowJob(job, index) {
|
|
|
64
73
|
description: `ID: ${job.id}`,
|
|
65
74
|
};
|
|
66
75
|
}
|
|
67
|
-
exports.choiceFromWorkflowJob = choiceFromWorkflowJob;
|
|
68
76
|
function choicesFromWorkflowLogs(logs) {
|
|
69
77
|
return Array.from(logs.keys())
|
|
70
78
|
.map(step => {
|
|
@@ -80,7 +88,6 @@ function choicesFromWorkflowLogs(logs) {
|
|
|
80
88
|
})
|
|
81
89
|
.filter(step => step.status !== 'skipped');
|
|
82
90
|
}
|
|
83
|
-
exports.choicesFromWorkflowLogs = choicesFromWorkflowLogs;
|
|
84
91
|
function processWorkflowRuns(runs) {
|
|
85
92
|
return runs.map(run => {
|
|
86
93
|
const finishedAt = run.status === generated_1.WorkflowRunStatus.InProgress ? null : run.updatedAt;
|
|
@@ -100,7 +107,6 @@ function processWorkflowRuns(runs) {
|
|
|
100
107
|
};
|
|
101
108
|
});
|
|
102
109
|
}
|
|
103
|
-
exports.processWorkflowRuns = processWorkflowRuns;
|
|
104
110
|
async function fetchAndProcessLogsFromJobAsync(state, job) {
|
|
105
111
|
let rawLogs;
|
|
106
112
|
switch (job.type) {
|
|
@@ -136,7 +142,6 @@ async function fetchAndProcessLogsFromJobAsync(state, job) {
|
|
|
136
142
|
});
|
|
137
143
|
return logs;
|
|
138
144
|
}
|
|
139
|
-
exports.fetchAndProcessLogsFromJobAsync = fetchAndProcessLogsFromJobAsync;
|
|
140
145
|
function descriptionForJobStatus(status) {
|
|
141
146
|
switch (status) {
|
|
142
147
|
case generated_1.WorkflowJobStatus.New:
|
|
@@ -193,7 +198,6 @@ async function infoForActiveWorkflowRunAsync(graphqlClient, workflowRun, maxLogL
|
|
|
193
198
|
statusLines.push((0, formatFields_1.default)(statusValues));
|
|
194
199
|
return statusLines.join('\n');
|
|
195
200
|
}
|
|
196
|
-
exports.infoForActiveWorkflowRunAsync = infoForActiveWorkflowRunAsync;
|
|
197
201
|
async function infoForFailedWorkflowRunAsync(graphqlClient, workflowRun, maxLogLines = -1 // -1 means no limit
|
|
198
202
|
) {
|
|
199
203
|
const statusLines = [];
|
|
@@ -226,14 +230,12 @@ async function infoForFailedWorkflowRunAsync(graphqlClient, workflowRun, maxLogL
|
|
|
226
230
|
statusLines.push((0, formatFields_1.default)(statusValues));
|
|
227
231
|
return statusLines.join('\n');
|
|
228
232
|
}
|
|
229
|
-
exports.infoForFailedWorkflowRunAsync = infoForFailedWorkflowRunAsync;
|
|
230
233
|
async function fileExistsAsync(filePath) {
|
|
231
234
|
return await fs.promises
|
|
232
235
|
.access(filePath, fs.constants.F_OK)
|
|
233
236
|
.then(() => true)
|
|
234
237
|
.catch(() => false);
|
|
235
238
|
}
|
|
236
|
-
exports.fileExistsAsync = fileExistsAsync;
|
|
237
239
|
async function maybeReadStdinAsync() {
|
|
238
240
|
// Check if there's data on stdin
|
|
239
241
|
if (process.stdin.isTTY) {
|
|
@@ -257,7 +259,6 @@ async function maybeReadStdinAsync() {
|
|
|
257
259
|
});
|
|
258
260
|
});
|
|
259
261
|
}
|
|
260
|
-
exports.maybeReadStdinAsync = maybeReadStdinAsync;
|
|
261
262
|
async function showWorkflowStatusAsync(graphqlClient, { workflowRunId, spinnerUsesStdErr, waitForCompletion = true, }) {
|
|
262
263
|
log_1.default.log('Waiting for workflow run to complete. You can press Ctrl+C to exit.');
|
|
263
264
|
const spinner = (0, ora_1.ora)({
|
|
@@ -317,7 +318,6 @@ async function showWorkflowStatusAsync(graphqlClient, { workflowRunId, spinnerUs
|
|
|
317
318
|
await (0, promise_1.sleepAsync)(10 /* seconds */ * 1000 /* milliseconds */);
|
|
318
319
|
}
|
|
319
320
|
}
|
|
320
|
-
exports.showWorkflowStatusAsync = showWorkflowStatusAsync;
|
|
321
321
|
exports.workflowRunExitCodes = {
|
|
322
322
|
WORKFLOW_FAILED: 11,
|
|
323
323
|
WORKFLOW_CANCELED: 12,
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
3
|
+
exports.validateWorkflowFileAsync = validateWorkflowFileAsync;
|
|
4
|
+
exports.logWorkflowValidationErrors = logWorkflowValidationErrors;
|
|
5
|
+
exports.parsedYamlFromWorkflowContents = parsedYamlFromWorkflowContents;
|
|
6
|
+
exports.workflowContentsFromParsedYaml = workflowContentsFromParsedYaml;
|
|
4
7
|
const tslib_1 = require("tslib");
|
|
5
8
|
const errors_1 = require("@expo/eas-json/build/errors");
|
|
6
9
|
const core_1 = require("@urql/core");
|
|
@@ -37,7 +40,6 @@ async function validateWorkflowFileAsync(workflowFileContents, projectDir, graph
|
|
|
37
40
|
log_1.default.debug(`Validating workflow on server...`);
|
|
38
41
|
await validateWorkflowOnServerAsync(graphqlClient, projectId, workflowFileContents);
|
|
39
42
|
}
|
|
40
|
-
exports.validateWorkflowFileAsync = validateWorkflowFileAsync;
|
|
41
43
|
function logWorkflowValidationErrors(error) {
|
|
42
44
|
if (error instanceof errors_1.MissingEasJsonError) {
|
|
43
45
|
throw new Error('Workflows require a valid eas.json. Please run "eas build:configure" to create it.');
|
|
@@ -62,7 +64,6 @@ function logWorkflowValidationErrors(error) {
|
|
|
62
64
|
log_1.default.error(`Unexpected error: ${String(error)}`);
|
|
63
65
|
}
|
|
64
66
|
}
|
|
65
|
-
exports.logWorkflowValidationErrors = logWorkflowValidationErrors;
|
|
66
67
|
function validateWorkflowIsNotEmpty(parsedYaml) {
|
|
67
68
|
if (parsedYaml === null ||
|
|
68
69
|
parsedYaml === undefined ||
|
|
@@ -126,11 +127,9 @@ function parsedYamlFromWorkflowContents(workflowFileContents) {
|
|
|
126
127
|
const parsedYaml = YAML.parse(workflowFileContents.yamlConfig);
|
|
127
128
|
return parsedYaml;
|
|
128
129
|
}
|
|
129
|
-
exports.parsedYamlFromWorkflowContents = parsedYamlFromWorkflowContents;
|
|
130
130
|
function workflowContentsFromParsedYaml(parsedYaml) {
|
|
131
131
|
return YAML.stringify(parsedYaml);
|
|
132
132
|
}
|
|
133
|
-
exports.workflowContentsFromParsedYaml = workflowContentsFromParsedYaml;
|
|
134
133
|
// eslint-disable-next-line @typescript-eslint/explicit-function-return-type
|
|
135
134
|
async function fetchWorkflowSchemaAsync() {
|
|
136
135
|
// EXPO_TESTING_WORKFLOW_SCHEMA_PATH is used only for testing against a different schema
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.selectBuildToCancelAsync =
|
|
3
|
+
exports.selectBuildToCancelAsync = selectBuildToCancelAsync;
|
|
4
4
|
const tslib_1 = require("tslib");
|
|
5
5
|
const core_1 = require("@oclif/core");
|
|
6
6
|
const graphql_tag_1 = tslib_1.__importDefault(require("graphql-tag"));
|
|
@@ -63,7 +63,6 @@ async function selectBuildToCancelAsync(graphqlClient, projectId, projectDisplay
|
|
|
63
63
|
: null;
|
|
64
64
|
}
|
|
65
65
|
}
|
|
66
|
-
exports.selectBuildToCancelAsync = selectBuildToCancelAsync;
|
|
67
66
|
class BuildCancel extends EasCommand_1.default {
|
|
68
67
|
static description = 'cancel a build';
|
|
69
68
|
static args = [{ name: 'BUILD_ID' }];
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.selectBuildToDeleteAsync =
|
|
3
|
+
exports.selectBuildToDeleteAsync = selectBuildToDeleteAsync;
|
|
4
4
|
const tslib_1 = require("tslib");
|
|
5
5
|
const core_1 = require("@oclif/core");
|
|
6
6
|
const graphql_tag_1 = tslib_1.__importDefault(require("graphql-tag"));
|
|
@@ -54,7 +54,6 @@ async function selectBuildToDeleteAsync(graphqlClient, projectId, projectDisplay
|
|
|
54
54
|
: null;
|
|
55
55
|
}
|
|
56
56
|
}
|
|
57
|
-
exports.selectBuildToDeleteAsync = selectBuildToDeleteAsync;
|
|
58
57
|
class BuildDelete extends EasCommand_1.default {
|
|
59
58
|
static description = 'delete a build';
|
|
60
59
|
static args = [{ name: 'BUILD_ID' }];
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.handleDeprecatedEasJsonAsync =
|
|
3
|
+
exports.handleDeprecatedEasJsonAsync = handleDeprecatedEasJsonAsync;
|
|
4
4
|
const tslib_1 = require("tslib");
|
|
5
5
|
const eas_build_job_1 = require("@expo/eas-build-job");
|
|
6
6
|
const eas_json_1 = require("@expo/eas-json");
|
|
@@ -302,4 +302,3 @@ async function handleDeprecatedEasJsonAsync(projectDir, nonInteractive) {
|
|
|
302
302
|
await easJsonAccessor.writeAsync();
|
|
303
303
|
log_1.default.withTick('Updated eas.json');
|
|
304
304
|
}
|
|
305
|
-
exports.handleDeprecatedEasJsonAsync = handleDeprecatedEasJsonAsync;
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
const tslib_1 = require("tslib");
|
|
4
|
-
const
|
|
4
|
+
const delete_1 = require("../../channel/delete");
|
|
5
5
|
const queries_1 = require("../../channel/queries");
|
|
6
6
|
const EasCommand_1 = tslib_1.__importDefault(require("../../commandUtils/EasCommand"));
|
|
7
7
|
const flags_1 = require("../../commandUtils/flags");
|
|
8
|
-
const client_1 = require("../../graphql/client");
|
|
9
8
|
const ChannelQuery_1 = require("../../graphql/queries/ChannelQuery");
|
|
10
9
|
const log_1 = tslib_1.__importDefault(require("../../log"));
|
|
11
10
|
const prompts_1 = require("../../prompts");
|
|
12
11
|
const json_1 = require("../../utils/json");
|
|
12
|
+
const pollForBackgroundJobReceiptAsync_1 = require("../../utils/pollForBackgroundJobReceiptAsync");
|
|
13
13
|
class ChannelDelete extends EasCommand_1.default {
|
|
14
14
|
static description = 'Delete a channel';
|
|
15
15
|
static args = [
|
|
@@ -61,7 +61,7 @@ class ChannelDelete extends EasCommand_1.default {
|
|
|
61
61
|
}
|
|
62
62
|
if (!nonInteractive) {
|
|
63
63
|
log_1.default.addNewLineIfNone();
|
|
64
|
-
log_1.default.warn(`You are about to permanently delete channel: "${channelName}"
|
|
64
|
+
log_1.default.warn(`You are about to permanently delete channel: "${channelName}". Deleting this channel will also permanently remove all associated builds from your account. \nThis action is irreversible.`);
|
|
65
65
|
log_1.default.newLine();
|
|
66
66
|
const confirmed = await (0, prompts_1.toggleConfirmAsync)({ message: 'Are you sure you wish to proceed?' });
|
|
67
67
|
if (!confirmed) {
|
|
@@ -69,11 +69,11 @@ class ChannelDelete extends EasCommand_1.default {
|
|
|
69
69
|
process.exit(1);
|
|
70
70
|
}
|
|
71
71
|
}
|
|
72
|
-
const
|
|
73
|
-
|
|
74
|
-
});
|
|
72
|
+
const receipt = await (0, delete_1.scheduleChannelDeletionAsync)(graphqlClient, { channelId });
|
|
73
|
+
const successfulReceipt = await (0, pollForBackgroundJobReceiptAsync_1.pollForBackgroundJobReceiptAsync)(graphqlClient, receipt);
|
|
74
|
+
log_1.default.debug('Deletion result', { successfulReceipt });
|
|
75
75
|
if (jsonFlag) {
|
|
76
|
-
(0, json_1.printJsonOnlyOutput)(
|
|
76
|
+
(0, json_1.printJsonOnlyOutput)({ id: channelId });
|
|
77
77
|
}
|
|
78
78
|
else {
|
|
79
79
|
log_1.default.withTick(`️Deleted channel "${channelName}".`);
|
|
@@ -81,19 +81,3 @@ class ChannelDelete extends EasCommand_1.default {
|
|
|
81
81
|
}
|
|
82
82
|
}
|
|
83
83
|
exports.default = ChannelDelete;
|
|
84
|
-
async function deleteChannelOnAppAsync(graphqlClient, { channelId }) {
|
|
85
|
-
const data = await (0, client_1.withErrorHandlingAsync)(graphqlClient
|
|
86
|
-
.mutation((0, graphql_tag_1.default) `
|
|
87
|
-
mutation DeleteUpdateChannel($channelId: ID!) {
|
|
88
|
-
updateChannel {
|
|
89
|
-
deleteUpdateChannel(channelId: $channelId) {
|
|
90
|
-
id
|
|
91
|
-
}
|
|
92
|
-
}
|
|
93
|
-
}
|
|
94
|
-
`, {
|
|
95
|
-
channelId,
|
|
96
|
-
})
|
|
97
|
-
.toPromise());
|
|
98
|
-
return data.updateChannel.deleteUpdateChannel;
|
|
99
|
-
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.updateChannelBranchMappingAsync =
|
|
3
|
+
exports.updateChannelBranchMappingAsync = updateChannelBranchMappingAsync;
|
|
4
4
|
const tslib_1 = require("tslib");
|
|
5
5
|
const core_1 = require("@oclif/core");
|
|
6
6
|
const chalk_1 = tslib_1.__importDefault(require("chalk"));
|
|
@@ -38,7 +38,6 @@ async function updateChannelBranchMappingAsync(graphqlClient, { channelId, branc
|
|
|
38
38
|
}
|
|
39
39
|
return channel;
|
|
40
40
|
}
|
|
41
|
-
exports.updateChannelBranchMappingAsync = updateChannelBranchMappingAsync;
|
|
42
41
|
class ChannelEdit extends EasCommand_1.default {
|
|
43
42
|
static description = 'point a channel at a new branch';
|
|
44
43
|
static args = [
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.pauseUpdateChannelAsync =
|
|
3
|
+
exports.pauseUpdateChannelAsync = pauseUpdateChannelAsync;
|
|
4
4
|
const tslib_1 = require("tslib");
|
|
5
5
|
const core_1 = require("@oclif/core");
|
|
6
6
|
const chalk_1 = tslib_1.__importDefault(require("chalk"));
|
|
@@ -34,7 +34,6 @@ async function pauseUpdateChannelAsync(graphqlClient, { channelId }) {
|
|
|
34
34
|
}
|
|
35
35
|
return channel;
|
|
36
36
|
}
|
|
37
|
-
exports.pauseUpdateChannelAsync = pauseUpdateChannelAsync;
|
|
38
37
|
class ChannelPause extends EasCommand_1.default {
|
|
39
38
|
static description = 'pause a channel to stop it from sending updates';
|
|
40
39
|
static args = [
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.resumeUpdateChannelAsync =
|
|
3
|
+
exports.resumeUpdateChannelAsync = resumeUpdateChannelAsync;
|
|
4
4
|
const tslib_1 = require("tslib");
|
|
5
5
|
const core_1 = require("@oclif/core");
|
|
6
6
|
const chalk_1 = tslib_1.__importDefault(require("chalk"));
|
|
@@ -34,7 +34,6 @@ async function resumeUpdateChannelAsync(graphqlClient, { channelId }) {
|
|
|
34
34
|
}
|
|
35
35
|
return channel;
|
|
36
36
|
}
|
|
37
|
-
exports.resumeUpdateChannelAsync = resumeUpdateChannelAsync;
|
|
38
37
|
class ChannelResume extends EasCommand_1.default {
|
|
39
38
|
static description = 'resume a channel to start sending updates';
|
|
40
39
|
static args = [
|
|
@@ -351,7 +351,7 @@ async function resolveExportedProjectAsync(flags, projectDir) {
|
|
|
351
351
|
function logExportedProjectInfo(project) {
|
|
352
352
|
let modifiedAgo = '';
|
|
353
353
|
// Only show the timestamp for exports older than 1 minute
|
|
354
|
-
if (project.modifiedAt && Date.now() - project.modifiedAt.getTime() >
|
|
354
|
+
if (project.modifiedAt && Date.now() - project.modifiedAt.getTime() > 60_000) {
|
|
355
355
|
modifiedAgo = ` - exported ${(0, timeago_js_1.format)(project.modifiedAt)}`;
|
|
356
356
|
log_1.default.warn(`> Project export: ${project.type}${modifiedAgo}`);
|
|
357
357
|
}
|
|
@@ -9,6 +9,7 @@ const url_1 = require("../../build/utils/url");
|
|
|
9
9
|
const EasCommand_1 = tslib_1.__importDefault(require("../../commandUtils/EasCommand"));
|
|
10
10
|
const getProjectIdAsync_1 = require("../../commandUtils/context/contextUtils/getProjectIdAsync");
|
|
11
11
|
const flags_1 = require("../../commandUtils/flags");
|
|
12
|
+
const projectNameValidation_1 = require("../../commandUtils/projectNameValidation");
|
|
12
13
|
const generated_1 = require("../../graphql/generated");
|
|
13
14
|
const AppMutation_1 = require("../../graphql/mutations/AppMutation");
|
|
14
15
|
const AppQuery_1 = require("../../graphql/queries/AppQuery");
|
|
@@ -192,8 +193,9 @@ class ProjectInit extends EasCommand_1.default {
|
|
|
192
193
|
if (!accountName) {
|
|
193
194
|
throw new Error('No account selected for project. Canceling.');
|
|
194
195
|
}
|
|
195
|
-
const projectName = exp.slug;
|
|
196
|
+
const projectName = (0, projectNameValidation_1.validSlugName)(exp.slug); // This filters out invalid characters
|
|
196
197
|
const projectFullName = `@${accountName}/${projectName}`;
|
|
198
|
+
(0, projectNameValidation_1.validateFullNameAndSlug)(projectFullName, projectName);
|
|
197
199
|
const existingProjectIdOnServer = await (0, fetchOrCreateProjectIDForWriteToConfigWithConfirmationAsync_1.findProjectIdByAccountNameAndSlugNullableAsync)(graphqlClient, accountName, projectName);
|
|
198
200
|
if (existingProjectIdOnServer) {
|
|
199
201
|
if (!force) {
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
3
|
+
exports.generateConfigsAsync = generateConfigsAsync;
|
|
4
|
+
exports.createProjectAsync = createProjectAsync;
|
|
5
|
+
exports.generateProjectFilesAsync = generateProjectFilesAsync;
|
|
4
6
|
const tslib_1 = require("tslib");
|
|
5
7
|
const core_1 = require("@oclif/core");
|
|
6
8
|
const chalk_1 = tslib_1.__importDefault(require("chalk"));
|
|
@@ -29,7 +31,6 @@ async function generateConfigsAsync(args, actor, graphqlClient) {
|
|
|
29
31
|
projectName,
|
|
30
32
|
};
|
|
31
33
|
}
|
|
32
|
-
exports.generateConfigsAsync = generateConfigsAsync;
|
|
33
34
|
async function createProjectAsync({ graphqlClient, actor, projectDirectory, projectAccount, projectName, }) {
|
|
34
35
|
const projectFullName = `@${projectAccount}/${projectName}`;
|
|
35
36
|
const projectDashboardUrl = (0, url_1.getProjectDashboardUrl)(projectAccount, projectName);
|
|
@@ -55,7 +56,6 @@ async function createProjectAsync({ graphqlClient, actor, projectDirectory, proj
|
|
|
55
56
|
log_1.default.withInfo(`Project successfully linked (ID: ${chalk_1.default.bold(projectId)})`);
|
|
56
57
|
return projectId;
|
|
57
58
|
}
|
|
58
|
-
exports.createProjectAsync = createProjectAsync;
|
|
59
59
|
async function generateProjectFilesAsync(projectDir, app, packageManager) {
|
|
60
60
|
const spinner = (0, ora_1.ora)(`Generating project files`).start();
|
|
61
61
|
await (0, projectFiles_1.generateAppConfigAsync)(projectDir, app);
|
|
@@ -67,7 +67,6 @@ async function generateProjectFilesAsync(projectDir, app, packageManager) {
|
|
|
67
67
|
log_1.default.withInfo(`Generated ${chalk_1.default.bold('app.json')}. ${(0, log_1.learnMore)('https://docs.expo.dev/versions/latest/config/app/')}`);
|
|
68
68
|
log_1.default.withInfo(`Generated ${chalk_1.default.bold('eas.json')}. ${(0, log_1.learnMore)('https://docs.expo.dev/build-reference/eas-json/')}`);
|
|
69
69
|
}
|
|
70
|
-
exports.generateProjectFilesAsync = generateProjectFilesAsync;
|
|
71
70
|
class New extends EasCommand_1.default {
|
|
72
71
|
static aliases = ['new'];
|
|
73
72
|
static description = 'Create a new project configured with Expo Application Services (EAS)';
|
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
import EasCommand from '../../commandUtils/EasCommand';
|
|
2
2
|
import { RequestedPlatform } from '../../platform';
|
|
3
|
+
/**
|
|
4
|
+
* Preprocess argv to handle --source-maps with optional value.
|
|
5
|
+
* If --source-maps is followed by another flag (starts with -) or end of args,
|
|
6
|
+
* insert 'true' as the default value.
|
|
7
|
+
*/
|
|
8
|
+
export declare function preprocessSourceMapsArg(argv: string[]): string[];
|
|
3
9
|
export default class UpdatePublish extends EasCommand {
|
|
4
10
|
static description: string;
|
|
5
11
|
static flags: {
|
|
@@ -12,6 +18,8 @@ export default class UpdatePublish extends EasCommand {
|
|
|
12
18
|
'input-dir': import("@oclif/core/lib/interfaces").OptionFlag<string>;
|
|
13
19
|
'skip-bundler': import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
|
|
14
20
|
'clear-cache': import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
|
|
21
|
+
'no-bytecode': import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
|
|
22
|
+
'source-maps': import("@oclif/core/lib/interfaces").OptionFlag<string>;
|
|
15
23
|
'emit-metadata': import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
|
|
16
24
|
'rollout-percentage': import("@oclif/core/lib/interfaces").OptionFlag<number | undefined>;
|
|
17
25
|
platform: import("@oclif/core/lib/interfaces").OptionFlag<RequestedPlatform>;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.preprocessSourceMapsArg = preprocessSourceMapsArg;
|
|
3
4
|
const tslib_1 = require("tslib");
|
|
4
5
|
const eas_build_job_1 = require("@expo/eas-build-job");
|
|
5
6
|
const eas_json_1 = require("@expo/eas-json");
|
|
@@ -33,6 +34,26 @@ const uniqBy_1 = tslib_1.__importDefault(require("../../utils/expodash/uniqBy"))
|
|
|
33
34
|
const formatFields_1 = tslib_1.__importDefault(require("../../utils/formatFields"));
|
|
34
35
|
const json_1 = require("../../utils/json");
|
|
35
36
|
const statuspageService_1 = require("../../utils/statuspageService");
|
|
37
|
+
/**
|
|
38
|
+
* Preprocess argv to handle --source-maps with optional value.
|
|
39
|
+
* If --source-maps is followed by another flag (starts with -) or end of args,
|
|
40
|
+
* insert 'true' as the default value.
|
|
41
|
+
*/
|
|
42
|
+
function preprocessSourceMapsArg(argv) {
|
|
43
|
+
const result = [];
|
|
44
|
+
for (let i = 0; i < argv.length; i++) {
|
|
45
|
+
const arg = argv[i];
|
|
46
|
+
result.push(arg);
|
|
47
|
+
if (arg === '--source-maps') {
|
|
48
|
+
const nextArg = argv[i + 1];
|
|
49
|
+
// If no next arg or next arg is a flag, insert 'true' as the value
|
|
50
|
+
if (nextArg === undefined || nextArg.startsWith('-')) {
|
|
51
|
+
result.push('true');
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
return result;
|
|
56
|
+
}
|
|
36
57
|
class UpdatePublish extends EasCommand_1.default {
|
|
37
58
|
static description = 'publish an update group';
|
|
38
59
|
static flags = {
|
|
@@ -62,6 +83,16 @@ class UpdatePublish extends EasCommand_1.default {
|
|
|
62
83
|
description: `Clear the bundler cache before publishing`,
|
|
63
84
|
default: false,
|
|
64
85
|
}),
|
|
86
|
+
'no-bytecode': core_1.Flags.boolean({
|
|
87
|
+
description: `Skip generating Hermes bytecode (output plain JavaScript instead)`,
|
|
88
|
+
default: false,
|
|
89
|
+
hidden: true,
|
|
90
|
+
}),
|
|
91
|
+
'source-maps': core_1.Flags.string({
|
|
92
|
+
description: `Emit source maps. Options: true (default), inline, false`,
|
|
93
|
+
default: 'true',
|
|
94
|
+
hidden: true,
|
|
95
|
+
}),
|
|
65
96
|
'emit-metadata': core_1.Flags.boolean({
|
|
66
97
|
description: `Emit "eas-update-metadata.json" in the bundle folder with detailed information about the generated updates`,
|
|
67
98
|
default: false,
|
|
@@ -96,9 +127,11 @@ class UpdatePublish extends EasCommand_1.default {
|
|
|
96
127
|
...this.ContextOptions.ServerSideEnvironmentVariables,
|
|
97
128
|
};
|
|
98
129
|
async runAsync() {
|
|
99
|
-
|
|
130
|
+
// Preprocess argv to handle --source-maps with optional value
|
|
131
|
+
const preprocessedArgv = preprocessSourceMapsArg(this.argv);
|
|
132
|
+
const { flags: rawFlags } = await this.parse(UpdatePublish, preprocessedArgv);
|
|
100
133
|
const paginatedQueryOptions = (0, pagination_1.getPaginatedQueryOptions)(rawFlags);
|
|
101
|
-
const { auto: autoFlag, platform: requestedPlatform, channelName: channelNameArg, updateMessage: updateMessageArg, inputDir, skipBundler, clearCache, privateKeyPath, json: jsonFlag, nonInteractive, branchName: branchNameArg, emitMetadata, rolloutPercentage, environment, } = this.sanitizeFlags(rawFlags);
|
|
134
|
+
const { auto: autoFlag, platform: requestedPlatform, channelName: channelNameArg, updateMessage: updateMessageArg, inputDir, skipBundler, clearCache, noBytecode, sourceMaps, privateKeyPath, json: jsonFlag, nonInteractive, branchName: branchNameArg, emitMetadata, rolloutPercentage, environment, } = this.sanitizeFlags(rawFlags);
|
|
102
135
|
const { getDynamicPublicProjectConfigAsync, getDynamicPrivateProjectConfigAsync, loggedIn: { graphqlClient }, vcsClient, getServerSideEnvironmentVariablesAsync, } = await this.getContextAsync(UpdatePublish, {
|
|
103
136
|
nonInteractive,
|
|
104
137
|
withServerSideEnvironment: environment ?? null,
|
|
@@ -153,6 +186,8 @@ class UpdatePublish extends EasCommand_1.default {
|
|
|
153
186
|
exp,
|
|
154
187
|
platformFlag: requestedPlatform,
|
|
155
188
|
clearCache,
|
|
189
|
+
noBytecode,
|
|
190
|
+
sourceMaps,
|
|
156
191
|
extraEnv: maybeServerEnv,
|
|
157
192
|
});
|
|
158
193
|
bundleSpinner.succeed('Exported bundle(s)');
|
|
@@ -528,6 +563,8 @@ class UpdatePublish extends EasCommand_1.default {
|
|
|
528
563
|
inputDir: flags['input-dir'],
|
|
529
564
|
skipBundler,
|
|
530
565
|
clearCache: flags['clear-cache'] ? true : !!flags['environment'],
|
|
566
|
+
noBytecode: flags['no-bytecode'] ?? false,
|
|
567
|
+
sourceMaps: flags['source-maps'],
|
|
531
568
|
platform: flags.platform,
|
|
532
569
|
privateKeyPath: flags['private-key-path'],
|
|
533
570
|
rolloutPercentage: flags['rollout-percentage'],
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import EasCommand from '../../commandUtils/EasCommand';
|
|
2
|
+
import { RequestedPlatform } from '../../platform';
|
|
2
3
|
export default class UpdateList extends EasCommand {
|
|
3
4
|
static description: string;
|
|
4
5
|
static flags: {
|
|
@@ -8,6 +9,8 @@ export default class UpdateList extends EasCommand {
|
|
|
8
9
|
offset: import("@oclif/core/lib/interfaces").OptionFlag<number | undefined>;
|
|
9
10
|
branch: import("@oclif/core/lib/interfaces").OptionFlag<string | undefined>;
|
|
10
11
|
all: import("@oclif/core/lib/interfaces").BooleanFlag<boolean>;
|
|
12
|
+
platform: import("@oclif/core/lib/interfaces").OptionFlag<RequestedPlatform | undefined>;
|
|
13
|
+
'runtime-version': import("@oclif/core/lib/interfaces").OptionFlag<string | undefined>;
|
|
11
14
|
};
|
|
12
15
|
static contextDefinition: {
|
|
13
16
|
loggedIn: import("../../commandUtils/context/LoggedInContextField").default;
|
|
@@ -6,6 +6,8 @@ const queries_1 = require("../../branch/queries");
|
|
|
6
6
|
const EasCommand_1 = tslib_1.__importDefault(require("../../commandUtils/EasCommand"));
|
|
7
7
|
const flags_1 = require("../../commandUtils/flags");
|
|
8
8
|
const pagination_1 = require("../../commandUtils/pagination");
|
|
9
|
+
const generated_1 = require("../../graphql/generated");
|
|
10
|
+
const platform_1 = require("../../platform");
|
|
9
11
|
const queries_2 = require("../../update/queries");
|
|
10
12
|
const json_1 = require("../../utils/json");
|
|
11
13
|
class UpdateList extends EasCommand_1.default {
|
|
@@ -20,6 +22,14 @@ class UpdateList extends EasCommand_1.default {
|
|
|
20
22
|
exclusive: ['branch'],
|
|
21
23
|
default: false,
|
|
22
24
|
}),
|
|
25
|
+
platform: core_1.Flags.enum({
|
|
26
|
+
options: Object.values(platform_1.RequestedPlatform),
|
|
27
|
+
char: 'p',
|
|
28
|
+
description: 'Filter updates by platform',
|
|
29
|
+
}),
|
|
30
|
+
'runtime-version': core_1.Flags.string({
|
|
31
|
+
description: 'Filter updates by runtime version',
|
|
32
|
+
}),
|
|
23
33
|
...pagination_1.EasPaginatedQueryFlags,
|
|
24
34
|
limit: (0, pagination_1.getLimitFlagWithCustomValues)({ defaultTo: 25, limit: 50 }),
|
|
25
35
|
...flags_1.EasNonInteractiveAndJsonFlags,
|
|
@@ -30,7 +40,7 @@ class UpdateList extends EasCommand_1.default {
|
|
|
30
40
|
};
|
|
31
41
|
async runAsync() {
|
|
32
42
|
const { flags } = await this.parse(UpdateList);
|
|
33
|
-
const { branch: branchFlag, all, json: jsonFlag, 'non-interactive': nonInteractive } = flags;
|
|
43
|
+
const { branch: branchFlag, all, json: jsonFlag, 'non-interactive': nonInteractive, platform: requestedPlatform, } = flags;
|
|
34
44
|
const { projectId, loggedIn: { graphqlClient }, } = await this.getContextAsync(UpdateList, {
|
|
35
45
|
nonInteractive,
|
|
36
46
|
});
|
|
@@ -38,9 +48,15 @@ class UpdateList extends EasCommand_1.default {
|
|
|
38
48
|
if (jsonFlag) {
|
|
39
49
|
(0, json_1.enableJsonOutput)();
|
|
40
50
|
}
|
|
51
|
+
// Build filter object
|
|
52
|
+
const filter = {
|
|
53
|
+
platform: toAppPlatform(requestedPlatform),
|
|
54
|
+
runtimeVersions: flags['runtime-version'] ? [flags['runtime-version']] : undefined,
|
|
55
|
+
};
|
|
41
56
|
if (all) {
|
|
42
57
|
await (0, queries_2.listAndRenderUpdateGroupsOnAppAsync)(graphqlClient, {
|
|
43
58
|
projectId,
|
|
59
|
+
filter,
|
|
44
60
|
paginatedQueryOptions,
|
|
45
61
|
});
|
|
46
62
|
}
|
|
@@ -49,6 +65,7 @@ class UpdateList extends EasCommand_1.default {
|
|
|
49
65
|
await (0, queries_2.listAndRenderUpdateGroupsOnBranchAsync)(graphqlClient, {
|
|
50
66
|
projectId,
|
|
51
67
|
branchName: branchFlag,
|
|
68
|
+
filter,
|
|
52
69
|
paginatedQueryOptions,
|
|
53
70
|
});
|
|
54
71
|
}
|
|
@@ -74,6 +91,7 @@ class UpdateList extends EasCommand_1.default {
|
|
|
74
91
|
await (0, queries_2.listAndRenderUpdateGroupsOnBranchAsync)(graphqlClient, {
|
|
75
92
|
projectId,
|
|
76
93
|
branchName: selectedBranch.name,
|
|
94
|
+
filter,
|
|
77
95
|
paginatedQueryOptions,
|
|
78
96
|
});
|
|
79
97
|
}
|
|
@@ -81,3 +99,14 @@ class UpdateList extends EasCommand_1.default {
|
|
|
81
99
|
}
|
|
82
100
|
}
|
|
83
101
|
exports.default = UpdateList;
|
|
102
|
+
const toAppPlatform = (requestedPlatform) => {
|
|
103
|
+
if (!requestedPlatform || requestedPlatform === platform_1.RequestedPlatform.All) {
|
|
104
|
+
return undefined;
|
|
105
|
+
}
|
|
106
|
+
else if (requestedPlatform === platform_1.RequestedPlatform.Android) {
|
|
107
|
+
return generated_1.AppPlatform.Android;
|
|
108
|
+
}
|
|
109
|
+
else {
|
|
110
|
+
return generated_1.AppPlatform.Ios;
|
|
111
|
+
}
|
|
112
|
+
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.nonNullish =
|
|
3
|
+
exports.nonNullish = nonNullish;
|
|
4
4
|
const tslib_1 = require("tslib");
|
|
5
5
|
const core_1 = require("@oclif/core");
|
|
6
6
|
const assert_1 = tslib_1.__importDefault(require("assert"));
|
|
@@ -19,7 +19,6 @@ const pollForBackgroundJobReceiptAsync_1 = require("../../utils/pollForBackgroun
|
|
|
19
19
|
function nonNullish(value) {
|
|
20
20
|
return value !== null && value !== undefined;
|
|
21
21
|
}
|
|
22
|
-
exports.nonNullish = nonNullish;
|
|
23
22
|
class UpdateRevertUpdateRollout extends EasCommand_1.default {
|
|
24
23
|
static description = 'revert a rollout update for a project';
|
|
25
24
|
static flags = {
|