diff --git a/.github/workflows/build-darwin.yml b/.github/workflows/build-darwin.yml index 5c29476..2074b3e 100644 --- a/.github/workflows/build-darwin.yml +++ b/.github/workflows/build-darwin.yml @@ -7,6 +7,10 @@ on: description: Name of artifact as which Darwin executable to be uploaded required: true type: string + arch: + description: "amd64 or arm64" + required: true + type: string version: description: Version to replace with required: false @@ -15,7 +19,7 @@ on: jobs: build-darwin: name: Build MacOS executable - runs-on: macos-13 + runs-on: ${{ inputs.arch == 'arm64' && 'macos-14' || 'macos-13' }} steps: - name: Install Conan run: pip3 install --break-system-packages conan==2.0.10 diff --git a/.github/workflows/cd-release.yml b/.github/workflows/cd-release.yml index 4dfdc85..a402bd8 100644 --- a/.github/workflows/cd-release.yml +++ b/.github/workflows/cd-release.yml @@ -22,8 +22,14 @@ jobs: build-darwin: name: Build Darwin executable uses: ./.github/workflows/build-darwin.yml + strategy: + matrix: + arch: + - amd64 + - arm64 with: - output-artifact-name: lottie-to-png.darwin.amd64 + output-artifact-name: lottie-to-png.darwin.${{ matrix.arch }} + arch: ${{ matrix.arch }} version: ${{ github.ref_name }} build-windows: @@ -141,6 +147,7 @@ jobs: - linux.amd64 - linux.arm64 - darwin.amd64 + - darwin.arm64 - windows.amd64.exe env: filename: lottie-converter.${{ matrix.file }}.zip diff --git a/.github/workflows/ci-build-and-test.yml b/.github/workflows/ci-build-and-test.yml index e3b369d..bdd4dd4 100644 --- a/.github/workflows/ci-build-and-test.yml +++ b/.github/workflows/ci-build-and-test.yml @@ -35,16 +35,28 @@ jobs: build-darwin: name: Build Darwin executable uses: ./.github/workflows/build-darwin.yml + strategy: + matrix: + arch: + - amd64 + - arm64 with: - output-artifact-name: lottie-to-png.darwin.amd64 + output-artifact-name: lottie-to-png.darwin.${{ matrix.arch }} + arch: ${{ matrix.arch }} test-darwin: name: Test on Darwin needs: build-darwin uses: ./.github/workflows/test-darwin.yml + strategy: + matrix: + arch: + - amd64 + - arm64 with: - input-artifact-name: lottie-to-png.darwin.amd64 - output-artifact-name: test-results.darwin + input-artifact-name: lottie-to-png.darwin.${{ matrix.arch }} + output-artifact-name: test-results.darwin.${{ matrix.arch }} + arch: ${{ matrix.arch }} build-windows: name: Build Windows executable diff --git a/.github/workflows/test-darwin.yml b/.github/workflows/test-darwin.yml index fcdf6cd..6eb725d 100644 --- a/.github/workflows/test-darwin.yml +++ b/.github/workflows/test-darwin.yml @@ -3,6 +3,10 @@ name: Test on Darwin on: workflow_call: inputs: + arch: + description: "amd64 or arm64" + required: true + type: string input-artifact-name: description: Name of artifact as which Darwin executable is uploaded required: true @@ -15,7 +19,7 @@ on: jobs: test-darwin: name: Test on Darwin - runs-on: macos-13 + runs-on: ${{ inputs.arch == 'arm64' && 'macos-14' || 'macos-13' }} strategy: matrix: case: