Skip to content

Update ci.yml #30

Update ci.yml

Update ci.yml #30

Workflow file for this run

# https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs
name: ci
on:
push:
# branches: [main]
pull_request:
branches: [main]
permissions:
contents: read
jobs:
windows-latest:
strategy:
fail-fast: false
matrix: # Add [23.x] after nodejs/nan#979 or similar.
node-version: [15.x] # [23.x, 22.x, 21.x, 20.x, 19.x, 18.x, 17.x, 16.x, 15.x]
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
- run: npm install
- run: npm run-script rebuild-tests
- run: npm test
- run: make test
windows-2019:
strategy:
fail-fast: false
matrix:
node-version: [8.x] # [14.x, 13.x, 12.x, 10.x, 8.x]
runs-on: windows-2019
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
- run: npm install
- run: npm run-script rebuild-tests
- run: npm test
- run: make test
python2:
strategy:
fail-fast: false
matrix:
node-version: [11.x, 9.x, 7.x, 6.x, 5.x, 4.x, 0.12, '0.10']
runs-on: windows-2019
env:
# NODE_GYP_FORCE_PYTHON: C:\Python27\python # Breaks 11, 9, 7
PYTHON: C:\Python27\python
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
- run: |
choco install python2
C:\Python27\python --version # Python 2.7.18
python --version # This is still Python 3
- name: Prepend Python27 to Windows PATH
shell: powershell
run: echo "C:\Python27`n$(Get-Content $env:GITHUB_PATH)" | Set-Content $env:GITHUB_PATH
- run: python --version # This is now Python 2.7.18!
- if: matrix.node-version == '5.x'
run: npm -g install npm@3
- if: matrix.node-version == '0.12' || matrix.node-version == '0.10'
run: npm -g install npm@2
- run: npm install
# - run: npm run-script rebuild-tests # This fails!!
# - run: npm test
- run: make test