diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 034b308b6..369bcab26 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -1,4 +1,4 @@ -name: 'Release CI' +name: Release CI # This workflow triggers when a PR is merged into `main`, but jobs have conditions to only run when: # - A PR is closed, merged into `main`, from a branch that matches the pattern `release/v*.*.*` @@ -86,65 +86,3 @@ jobs: push: ${{ needs.push-or-load.outputs.push }} platforms: ${{ needs.push-or-load.outputs.platforms }} discord-webhook: ${{ secrets.DISCORD_WEBHOOK }} - - # build-web-app: - # name: Build web app - # runs-on: [self-hosted] - # if: false # TODO: Enable this once 0.1.0 is ready - # steps: - # - name: Checkout repository - # uses: actions/checkout@v3 - - # - name: Build the app - # uses: ./.github/actions/build-web - - # - name: Upload the build - # uses: ./.github/actions/upload-artifact - # with: - # upload-name: webapp - # upload-path: apps/web/dist - - # build-server: - # strategy: - # fail-fast: true - # matrix: - # platform: [macos, windows] - # name: Build server app - # needs: build-web - # runs-on: ${{ matrix.platform }} - # if: false # TODO: Enable this once 0.1.0 is ready - # steps: - # - name: Checkout repository - # uses: actions/checkout@v3 - - # - name: Build the server - # uses: ./.github/actions/build-server - # with: - # platform: ${{ matrix.platform }} - - # - name: Upload the server binary - # uses: ./.github/actions/upload-artifact - # with: - # upload-name: stump_server-${{ matrix.platform }} - # upload-path: target/release/stump_server - - # # TODO: Investigate if I can just merge this with the above - # build-linux-server: - # name: Build server app (self-hosted runner) - # needs: build-web - # runs-on: [self-hosted] - # if: false # TODO: Enable this once 0.1.0 is ready - # steps: - # - name: Checkout repository - # uses: actions/checkout@v3 - - # - name: Build the server - # uses: ./.github/actions/build-server - # with: - # platform: 'linux' - - # - name: Upload the server binary - # uses: ./.github/actions/upload-artifact - # with: - # upload-name: stump_server-linux - # upload-path: target/release/stump_server diff --git a/.github/workflows/release_binary.yml b/.github/workflows/release_binary.yml index 1c660b7b0..89550d55c 100644 --- a/.github/workflows/release_binary.yml +++ b/.github/workflows/release_binary.yml @@ -24,13 +24,18 @@ jobs: needs: build-webapp strategy: matrix: - os: [ubuntu-latest, macos-latest, windows-latest] + # Note: macos-13 is intel-based, macos-latest is M1-based + # See https://docs.github.com/en/actions/using-github-hosted-runners/about-github-hosted-runners/about-github-hosted-runners#supported-runners-and-hardware-resources + os: [ubuntu-latest, macos-13, macos-latest, windows-latest] include: - os: ubuntu-latest artifact_name: linux-artifact artifact_filename: stump_server + - os: macos-13 + artifact_name: macos-intel-artifact + artifact_filename: stump_server - os: macos-latest - artifact_name: macos-artifact + artifact_name: macos-arm-artifact artifact_filename: stump_server - os: windows-latest artifact_name: windows-artifact @@ -57,6 +62,7 @@ jobs: with: upload-name: ${{ matrix.artifact_name }} upload-path: staging + # This job creates the release and organizes associated files create-release: needs: build-binary @@ -74,11 +80,17 @@ jobs: name: linux-artifact path: StumpServer-linux - - name: Download artifact (macOS) + - name: Download artifact (macOS Intel) + uses: actions/download-artifact@v4 + with: + name: macos-intel-artifact + path: StumpServer-macos-intel + + - name: Download artifact (macOS ARM) uses: actions/download-artifact@v4 with: - name: macos-artifact - path: StumpServer-macos + name: macos-arm-artifact + path: StumpServer-macos-arm - name: Download artifact (Windows) uses: actions/download-artifact@v4 @@ -93,8 +105,10 @@ jobs: run: | cd StumpServer-linux zip -r ../linux-build-results.zip * - cd ../StumpServer-macos - zip -r ../macos-build-results.zip * + cd ../StumpServer-macos-intel + zip -r ../macos-intel-build-results.zip * + cd ../StumpServer-macos-arm + zip -r ../macos-arm-build-results.zip * cd ../StumpServer-windows zip -r ../windows-build-results.zip * cd .. @@ -106,6 +120,7 @@ jobs: --target main \ --title 'v${{ github.event.inputs.version }}' \ --generate-notes \ - linux-build-results.zip#StumpServer-${{ github.event.inputs.version }}-x64-Linux.zip \ - macos-build-results.zip#StumpServer-${{ github.event.inputs.version }}-x64-macOS.zip \ - windows-build-results.zip#StumpServer-${{ github.event.inputs.version }}-x64-Windows.zip + linux-build-results.zip#StumpServer-${{ github.event.inputs.version }}-linux-x86_64.zip \ + macos-intel-build-results.zip#StumpServer-${{ github.event.inputs.version }}-macos-intel.zip \ + macos-arm-build-results.zip#StumpServer-${{ github.event.inputs.version }}-macos-arm.zip \ + windows-build-results.zip#StumpServer-${{ github.event.inputs.version }}-windows-x86_64.zip