File tree Expand file tree Collapse file tree 1 file changed +14
-1
lines changed Expand file tree Collapse file tree 1 file changed +14
-1
lines changed Original file line number Diff line number Diff line change @@ -128,10 +128,23 @@ jobs:
128128 runs-on : ${{ matrix.os }}
129129 steps :
130130 - uses : actions/checkout@v5
131+ - name : Decide Node Version
132+ id : decide-node-version
133+ shell : bash
134+ run : |
135+ NODE_VERSION=18.x
136+ if [ "${{ matrix.version}}" = "canary" ]; then
137+ # this is not ideal, because we set node@20 just when explicitly using canary tag as target
138+ # but next@canary are still on 15 major, so we can't yet use major version of resolved next version
139+ # as condition
140+ NODE_VERSION=20.x
141+ fi
142+ echo "version=$NODE_VERSION" >> $GITHUB_OUTPUT
143+ echo "Node version for 'next@${{ matrix.version }}' is '$NODE_VERSION'"
131144 - name : ' Install Node'
132145 uses : actions/setup-node@v4
133146 with :
134- node-version : ' 18.x '
147+ node-version : ${{ steps.decide-node-version.outputs.version }}
135148 cache : ' npm'
136149 cache-dependency-path : ' **/package-lock.json'
137150 - name : Prefer npm global on windows
You can’t perform that action at this time.
0 commit comments