From e385492f30fe48f448cdc5af477896d912239b29 Mon Sep 17 00:00:00 2001 From: Robin van Wijngaarden Date: Thu, 22 Aug 2024 16:19:03 +0200 Subject: [PATCH] ci: use x64 arch node 10, 12, 14 for macos-latest --- .github/workflows/ci.yml | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 64b6d77..f956596 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -56,10 +56,21 @@ jobs: name: plugin-test (pnpm v${{ matrix.version }}, Node.js v${{ matrix.node }}, ${{ matrix.os }}) runs-on: ${{ matrix.os }} steps: + - uses: actions/github-script@v7 + id: calculate_architecture + with: + result-encoding: string + script: | + if ('${{ matrix.os }}' === 'macos-latest' && ['10', '12', '14'].includes('${{ matrix.node }}')) { + return "x64" + } else { + return '' + } - name: Setup Node.js uses: actions/setup-node@v4 with: node-version: ${{ matrix.node }} + architecture: ${{ steps.calculate_architecture.outputs.result }} - name: Test pnpm uses: asdf-vm/actions/plugin-test@v3 with: