Skip to content

Commit fb82c59

Browse files
nattogJohn Richard Chipps-Harding
authored andcommitted
Add Windows to CI actions (#9)
* add windows to ci actions * format lint scripts
1 parent 6b65619 commit fb82c59

File tree

2 files changed

+18
-7
lines changed

2 files changed

+18
-7
lines changed

.github/workflows/nodejs.yml

Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,17 @@ name: node-ci
22

33
on: [push]
44

5+
env:
6+
CI: true
7+
58
jobs:
69
test:
710
name: Test on node ${{ matrix.node-version }} and ${{ matrix.os }}
811
runs-on: ${{ matrix.os }}
912
strategy:
1013
matrix:
1114
node-version: [10, 12]
12-
os: [ubuntu-latest, macos-latest]
15+
os: [ubuntu-latest, macos-latest, windows-latest]
1316

1417
steps:
1518
- uses: actions/checkout@v1
@@ -22,10 +25,18 @@ jobs:
2225
- name: Install latest npm
2326
run: npm install --global npm@latest
2427

25-
- name: npm install, lint and test
28+
- name: npm install and lint
2629
run: |
2730
npm install
2831
npm run lint
29-
npm test -- --ci
30-
env:
31-
CI: true
32+
33+
- name: Test (Windows)
34+
if: matrix.os == 'windows-latest'
35+
run: |
36+
cd ..
37+
cd D:\a\react-shader-canvas\react-shader-canvas
38+
npm test
39+
40+
- name: Test (Unix)
41+
if: matrix.os != 'windows-latest'
42+
run: npm test

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,11 +27,11 @@
2727
"release": "np",
2828
"lint": "npm-run-all --parallel lint:*",
2929
"lint:js": "eslint \"**/*.js\"",
30-
"lint:import": "import-sort -l 'src/**/*.{js,jsx}'",
30+
"lint:import": "import-sort -l \"src/**/*.{js,jsx}\"",
3131
"lint:format": "prettier \"**/*.{js,md}\" --check",
3232
"fix": "npm-run-all --sequential fix:*",
3333
"fix:js": "eslint \"**/*.js\" --fix",
34-
"fix:import": "import-sort --write 'src/**/*.{js,jsx}'",
34+
"fix:import": "import-sort --write \"src/**/*.{js,jsx}\"",
3535
"fix:format": "prettier \"**/*.{js,md}\" --write"
3636
},
3737
"author": "John Chipps-Harding (john@signal-noise.com)",

0 commit comments

Comments
 (0)