Skip to content

Commit 24aee0d

Browse files
authored
ci(workflows): exclude some node versions for windows/mac, update tools as needed for test (#140)
1 parent 183f619 commit 24aee0d

File tree

1 file changed

+22
-8
lines changed

1 file changed

+22
-8
lines changed

Diff for: .github/workflows/nodejs.yml

+22-8
Original file line numberDiff line numberDiff line change
@@ -42,9 +42,6 @@ jobs:
4242
node-version: ${{ matrix.node-version }}
4343
cache: "npm"
4444

45-
- name: Use latest NPM
46-
run: sudo npm i -g npm
47-
4845
- name: Install dependencies
4946
run: npm ci
5047

@@ -66,6 +63,15 @@ jobs:
6663
os: [ubuntu-latest, windows-latest, macos-latest]
6764
node-version: [10.x, 12.x, 14.x, 16.x, 18.x, 20.x, 22.x]
6865
webpack-version: [latest]
66+
exclude:
67+
- os: windows-latest
68+
node-version: 10.x
69+
- os: macos-latest
70+
node-version: 10.x
71+
- os: macos-latest
72+
node-version: 12.x
73+
- os: macos-latest
74+
node-version: 14.x
6975

7076
runs-on: ${{ matrix.os }}
7177

@@ -86,13 +92,21 @@ jobs:
8692
node-version: ${{ matrix.node-version }}
8793
cache: "npm"
8894

89-
- name: Use latest NPM on ubuntu/macos
90-
if: matrix.os == 'ubuntu-latest' || matrix.os == 'macos-latest'
91-
run: sudo npm i -g npm
95+
- name: Update node-gyp on windows
96+
if: matrix.os == 'windows-latest' && (matrix.node-version == '12.x' || matrix.node-version == '14.x')
97+
run: Get-Command node | Select-Object -ExpandProperty Source | Join-Path -ChildPath "..\node_modules\npm\node_modules\npm-lifecycle" -Resolve | Push-Location; npm install [email protected]; Pop-Location
98+
99+
- name: Install Python setuptools on ubuntu
100+
if: matrix.os == 'ubuntu-latest'
101+
run: python3 -m pip install setuptools
102+
103+
- name: Install Python setuptools on macos
104+
if: matrix.os == 'macos-latest'
105+
run: brew install python-setuptools
92106

93-
- name: Use latest NPM on windows
107+
- name: Install Python setuptools on windows
94108
if: matrix.os == 'windows-latest'
95-
run: npm i -g npm
109+
run: python -m pip install setuptools
96110

97111
- name: Install dependencies
98112
run: npm ci

0 commit comments

Comments
 (0)