diff --git a/.circleci/config.yml b/.circleci/config.yml index 2eb4a63b33d..91a15d50cf9 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -24,6 +24,10 @@ parameters: default: false type: boolean + run_prealpha_workflow: + default: false + type: boolean + jobs: choose_ci_jobs: docker: diff --git a/.circleci/configurations/jobs.yml b/.circleci/configurations/jobs.yml index d0d17a83f6a..1f40dd95ff3 100644 --- a/.circleci/configurations/jobs.yml +++ b/.circleci/configurations/jobs.yml @@ -250,9 +250,9 @@ jobs: executor: reactnativeandroid-xlarge parameters: release_type: - description: The type of release to build. Must be one of "nightly", "release", "dry-run". + description: The type of release to build. Must be one of "nightly", "release", "dry-run", "prealpha". type: enum - enum: ["nightly", "release", "dry-run"] + enum: ["nightly", "release", "dry-run", "prealpha"] default: "dry-run" steps: - checkout @@ -1159,9 +1159,9 @@ jobs: build_npm_package: parameters: release_type: - description: The type of release to build. Must be one of "nightly", "release", "dry-run". + description: The type of release to build. Must be one of "nightly", "release", "dry-run", or "prealpha". type: enum - enum: ["nightly", "release", "dry-run"] + enum: ["nightly", "release", "dry-run", "prealpha"] default: "dry-run" executor: reactnativeandroid-xlarge environment: @@ -1201,16 +1201,17 @@ jobs: - attach_workspace: at: . - # START: Stables and nightlies + # START: Stables, nightlies and prealphas # This conditional step sets up the necessary credentials for publishing react-native to npm. - when: condition: or: - equal: [ "release", << parameters.release_type >> ] - equal: [ "nightly", << parameters.release_type >> ] + - equal: [ "prealpha", << parameters.release_type >> ] steps: - run: echo "//registry.npmjs.org/:_authToken=${CIRCLE_NPM_TOKEN}" > ~/.npmrc - # END: Stables and nightlies + # END: Stables, prealpha and nightlies - with_gradle_cache: steps: @@ -1288,19 +1289,6 @@ jobs: command: | node scripts/circleci/poll-maven.js - - # ------------------------- - # JOBS: Nightly - # ------------------------- - nightly_job: - machine: - image: ubuntu-2004:202010-01 - steps: - - run: - name: Nightly - command: | - echo "Nightly build run" - find_and_publish_bumped_packages: executor: nodelts steps: diff --git a/.circleci/configurations/test_workflows/testAll.yml b/.circleci/configurations/test_workflows/testAll.yml index 145dcbd71ff..ad95c094443 100644 --- a/.circleci/configurations/test_workflows/testAll.yml +++ b/.circleci/configurations/test_workflows/testAll.yml @@ -3,6 +3,7 @@ and: - equal: [ false, << pipeline.parameters.run_release_workflow >> ] - equal: [ false, << pipeline.parameters.run_nightly_workflow >> ] + - equal: [ false, << pipeline.parameters.run_prealpha_workflow >> ] jobs: - prepare_package_for_release: name: prepare_package_for_release diff --git a/.circleci/configurations/test_workflows/testAndroid.yml b/.circleci/configurations/test_workflows/testAndroid.yml index b21ed9775fc..fd14ab1f26c 100644 --- a/.circleci/configurations/test_workflows/testAndroid.yml +++ b/.circleci/configurations/test_workflows/testAndroid.yml @@ -3,6 +3,7 @@ and: - equal: [ false, << pipeline.parameters.run_release_workflow >> ] - equal: [ false, << pipeline.parameters.run_nightly_workflow >> ] + - equal: [ false, << pipeline.parameters.run_prealpha_workflow >> ] jobs: - prepare_package_for_release: name: prepare_package_for_release diff --git a/.circleci/configurations/test_workflows/testE2E.yml b/.circleci/configurations/test_workflows/testE2E.yml index b161180ee5a..a18277b9826 100644 --- a/.circleci/configurations/test_workflows/testE2E.yml +++ b/.circleci/configurations/test_workflows/testE2E.yml @@ -3,6 +3,7 @@ and: - equal: [ false, << pipeline.parameters.run_release_workflow >> ] - equal: [ false, << pipeline.parameters.run_nightly_workflow >> ] + - equal: [ false, << pipeline.parameters.run_prealpha_workflow >> ] jobs: - test_e2e_ios: ruby_version: "2.7.7" diff --git a/.circleci/configurations/test_workflows/testIOS.yml b/.circleci/configurations/test_workflows/testIOS.yml index 484ef5a8f2e..487358cef7a 100644 --- a/.circleci/configurations/test_workflows/testIOS.yml +++ b/.circleci/configurations/test_workflows/testIOS.yml @@ -3,6 +3,7 @@ and: - equal: [ false, << pipeline.parameters.run_release_workflow >> ] - equal: [ false, << pipeline.parameters.run_nightly_workflow >> ] + - equal: [ false, << pipeline.parameters.run_prealpha_workflow >> ] jobs: - prepare_package_for_release: name: prepare_package_for_release diff --git a/.circleci/configurations/test_workflows/testJS.yml b/.circleci/configurations/test_workflows/testJS.yml index 6c5ea93e1c7..0c381150c17 100644 --- a/.circleci/configurations/test_workflows/testJS.yml +++ b/.circleci/configurations/test_workflows/testJS.yml @@ -3,6 +3,7 @@ and: - equal: [ false, << pipeline.parameters.run_release_workflow >> ] - equal: [ false, << pipeline.parameters.run_nightly_workflow >> ] + - equal: [ false, << pipeline.parameters.run_prealpha_workflow >> ] jobs: - test_js: run_disabled_tests: false diff --git a/.circleci/configurations/top_level.yml b/.circleci/configurations/top_level.yml index 4bfbebeb383..22fb66b3fc4 100644 --- a/.circleci/configurations/top_level.yml +++ b/.circleci/configurations/top_level.yml @@ -29,7 +29,7 @@ references: environment: - TERM: "dumb" - GRADLE_OPTS: '-Dorg.gradle.daemon=false' - # By default we only build ARM64 to save time/resources. For release/nightlies, we override this value to build all archs. + # By default we only build ARM64 to save time/resources. For release/nightlies/prealpha, we override this value to build all archs. - ORG_GRADLE_PROJECT_reactNativeArchitectures: "arm64-v8a" # Repeated here, as the environment key in this executor will overwrite the one in defaults - PUBLIC_ANALYSISBOT_GITHUB_TOKEN_A: *github_analysisbot_token_a @@ -145,3 +145,7 @@ parameters: run_nightly_workflow: default: false type: boolean + + run_prealpha_workflow: + default: false + type: boolean diff --git a/.circleci/configurations/workflows.yml b/.circleci/configurations/workflows.yml index be128b7d0af..abf5c0bab65 100644 --- a/.circleci/configurations/workflows.yml +++ b/.circleci/configurations/workflows.yml @@ -7,6 +7,7 @@ # and: # - equal: [ false, << pipeline.parameters.run_release_workflow >> ] # - equal: [ false, << pipeline.parameters.run_nightly_workflow >> ] +# - equal: [ false, << pipeline.parameters.run_prealpha_workflow >> ] # # It's setup this way so we can trigger a release via a POST # See limitations: https://support.circleci.com/hc/en-us/articles/360050351292-How-to-trigger-a-workflow-via-CircleCI-API-v2 @@ -80,6 +81,7 @@ workflows: and: - equal: [ false, << pipeline.parameters.run_release_workflow >> ] - equal: [ false, << pipeline.parameters.run_nightly_workflow >> ] + - equal: [ false, << pipeline.parameters.run_prealpha_workflow >> ] jobs: # Run lints on every commit - analyze_code @@ -90,7 +92,6 @@ workflows: nightly: when: << pipeline.parameters.run_nightly_workflow >> jobs: - - nightly_job - prepare_hermes_workspace - build_android: release_type: "nightly" @@ -124,11 +125,48 @@ workflows: - build_hermes_macos - build_hermesc_windows + prealpha: + when: << pipeline.parameters.run_prealpha_workflow >> + jobs: + - prepare_hermes_workspace + - build_android: + release_type: "prealpha" + - build_hermesc_linux: + requires: + - prepare_hermes_workspace + - build_hermesc_apple: + requires: + - prepare_hermes_workspace + - build_apple_slices_hermes: + requires: + - build_hermesc_apple + matrix: + parameters: + flavor: ["Debug", "Release"] + slice: ["macosx", "iphoneos", "iphonesimulator", "catalyst"] + - build_hermesc_windows: + requires: + - prepare_hermes_workspace + - build_hermes_macos: + requires: + - build_apple_slices_hermes + matrix: + parameters: + flavor: ["Debug", "Release"] + - build_npm_package: + release_type: "prealpha" + requires: + - build_android + - build_hermesc_linux + - build_hermes_macos + - build_hermesc_windows + publish_bumped_packages: when: and: - equal: [ false, << pipeline.parameters.run_release_workflow >> ] - equal: [ false, << pipeline.parameters.run_nightly_workflow >> ] + - equal: [ false, << pipeline.parameters.run_prealpha_workflow >> ] jobs: - find_and_publish_bumped_packages: <<: *main_or_stable_only