diff --git a/.github/workflows/rust-release.yml b/.github/workflows/rust-release.yml index 1d53cb320..07a2e87ef 100644 --- a/.github/workflows/rust-release.yml +++ b/.github/workflows/rust-release.yml @@ -10,9 +10,7 @@ # archive as a GitHub Release asset, then manually dispatch # `release_mode=promote_signed` with `unsigned_run_id` and `signed_macos_asset`. # The signed handoff archive should contain target or artifact directories such -# as `aarch64-apple-darwin/` with signed binaries. To inspect packaged unsigned -# macOS archives without publishing them, manually dispatch -# `release_mode=build_unsigned_archive`. +# as `aarch64-apple-darwin/` with signed binaries. name: rust-release on: @@ -22,13 +20,12 @@ on: workflow_dispatch: inputs: release_mode: - description: "build_unsigned creates unsigned macOS handoff artifacts; build_unsigned_archive uploads packaged unsigned macOS archives as run artifacts only; promote_signed finishes a release from signed macOS handoff artifacts." + description: "build_unsigned creates unsigned macOS handoff artifacts; promote_signed finishes a release from signed macOS handoff artifacts." required: false type: choice default: build_unsigned options: - build_unsigned - - build_unsigned_archive - promote_signed sign_macos: description: "Deprecated compatibility input; use release_mode instead." @@ -74,7 +71,7 @@ jobs: case "${RELEASE_MODE}" in signed) if [[ "${GITHUB_EVENT_NAME}" == "workflow_dispatch" ]]; then - echo "❌ Manual rust-release runs must use release_mode=build_unsigned, build_unsigned_archive, or promote_signed" + echo "❌ Manual rust-release runs must use release_mode=build_unsigned or release_mode=promote_signed" exit 1 fi ;; @@ -84,12 +81,6 @@ jobs: exit 1 fi ;; - build_unsigned_archive) - if [[ "${GITHUB_EVENT_NAME}" != "workflow_dispatch" ]]; then - echo "❌ release_mode=build_unsigned_archive is only valid for manual runs" - exit 1 - fi - ;; promote_signed) if [[ "${GITHUB_EVENT_NAME}" != "workflow_dispatch" ]]; then echo "❌ release_mode=promote_signed is only valid for manual runs" @@ -119,7 +110,7 @@ jobs: esac if [[ "${GITHUB_EVENT_NAME}" == "workflow_dispatch" && "${REQUESTED_SIGN_MACOS}" == "true" ]]; then - echo "::warning title=Deprecated sign_macos input ignored::Use release_mode=build_unsigned, build_unsigned_archive, or promote_signed instead." + echo "::warning title=Deprecated sign_macos input ignored::Use release_mode=build_unsigned or release_mode=promote_signed instead." fi # 1. Must be a tag and match the regex @@ -158,7 +149,6 @@ jobs: # 2026-03-04: temporarily change releases to use thin LTO because # Ubuntu ARM is timing out at 60 minutes. CARGO_PROFILE_RELEASE_LTO: ${{ contains(github.ref_name, '-alpha') && 'thin' || 'thin' }} - RELEASE_MODE: ${{ github.event_name == 'workflow_dispatch' && inputs.release_mode || 'signed' }} SIGN_MACOS: ${{ github.event_name != 'workflow_dispatch' }} strategy: @@ -334,7 +324,7 @@ jobs: path: codex-rs/target/**/cargo-timings/cargo-timing.html if-no-files-found: warn - - if: ${{ runner.os == 'macOS' && env.RELEASE_MODE == 'build_unsigned' }} + - if: ${{ runner.os == 'macOS' && env.SIGN_MACOS != 'true' }} name: Stage unsigned macOS artifacts shell: bash run: | @@ -359,7 +349,7 @@ jobs: zstd -T0 -19 --rm "${unsigned_path}" done - - if: ${{ runner.os == 'macOS' && env.RELEASE_MODE == 'build_unsigned' }} + - if: ${{ runner.os == 'macOS' && env.SIGN_MACOS != 'true' }} name: Upload unsigned macOS artifacts uses: actions/upload-artifact@bbbca2ddaa5d8feaa63e36b76fdaad77386f024f # v7.0.0 with: @@ -473,31 +463,18 @@ jobs: fi - name: Build Codex package archive - if: ${{ runner.os != 'macOS' || env.SIGN_MACOS == 'true' || env.RELEASE_MODE == 'build_unsigned_archive' }} + if: ${{ runner.os != 'macOS' || env.SIGN_MACOS == 'true' }} shell: bash env: TARGET: ${{ matrix.target }} BUNDLE: ${{ matrix.bundle }} run: | set -euo pipefail - archive_dir="dist/${TARGET}" - if [[ "${RUNNER_OS}" == "macOS" && "${RELEASE_MODE}" == "build_unsigned_archive" ]]; then - archive_dir="unsigned-archive-dist/${TARGET}" - fi bash "${GITHUB_WORKSPACE}/.github/scripts/build-codex-package-archive.sh" \ --target "$TARGET" \ --bundle "$BUNDLE" \ --entrypoint-dir "target/${TARGET}/release" \ - --archive-dir "$archive_dir" - - - name: Upload unsigned macOS package archives - if: ${{ runner.os == 'macOS' && env.RELEASE_MODE == 'build_unsigned_archive' }} - uses: actions/upload-artifact@bbbca2ddaa5d8feaa63e36b76fdaad77386f024f # v7.0.0 - with: - name: ${{ matrix.artifact_name }}-unsigned-archive - path: | - codex-rs/unsigned-archive-dist/${{ matrix.target }}/* - if-no-files-found: error + --archive-dir "dist/${TARGET}" - name: Build Python runtime wheel if: ${{ matrix.bundle == 'primary' && (runner.os != 'macOS' || env.SIGN_MACOS == 'true') }} @@ -836,7 +813,7 @@ jobs: codex-rs/dist/${{ matrix.target }}/* build-windows: - if: ${{ github.event_name != 'workflow_dispatch' || (inputs.release_mode != 'promote_signed' && inputs.release_mode != 'build_unsigned_archive') }} + if: ${{ github.event_name != 'workflow_dispatch' || inputs.release_mode != 'promote_signed' }} needs: tag-check uses: ./.github/workflows/rust-release-windows.yml with: @@ -844,7 +821,7 @@ jobs: secrets: inherit argument-comment-lint-release-assets: - if: ${{ github.event_name != 'workflow_dispatch' || (inputs.release_mode != 'promote_signed' && inputs.release_mode != 'build_unsigned_archive') }} + if: ${{ github.event_name != 'workflow_dispatch' || inputs.release_mode != 'promote_signed' }} name: argument-comment-lint release assets needs: tag-check uses: ./.github/workflows/rust-release-argument-comment-lint.yml @@ -852,7 +829,7 @@ jobs: publish: true zsh-release-assets: - if: ${{ github.event_name != 'workflow_dispatch' || (inputs.release_mode != 'promote_signed' && inputs.release_mode != 'build_unsigned_archive') }} + if: ${{ github.event_name != 'workflow_dispatch' || inputs.release_mode != 'promote_signed' }} name: zsh release assets needs: tag-check uses: ./.github/workflows/rust-release-zsh.yml @@ -881,7 +858,6 @@ jobs: ) || ( (github.event_name != 'workflow_dispatch' || inputs.release_mode != 'promote_signed') && - (github.event_name != 'workflow_dispatch' || inputs.release_mode != 'build_unsigned_archive') && needs.build.result == 'success' && needs.stage-signed-macos.result == 'skipped' && needs.build-windows.result == 'success' &&