File tree Expand file tree Collapse file tree 1 file changed +61
-0
lines changed
Expand file tree Collapse file tree 1 file changed +61
-0
lines changed Original file line number Diff line number Diff line change 1+ name : CI Shariff-Plus
2+
3+ on :
4+ push :
5+ branches : [ "develop" ]
6+ pull_request :
7+ branches : [ "develop" ]
8+
9+ concurrency :
10+ group : ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
11+ cancel-in-progress : true
12+
13+ jobs :
14+ npm :
15+ name : Install JS/CSS dependencies
16+ runs-on : ubuntu-latest
17+ steps :
18+ - uses : actions/checkout@v5
19+ - uses : actions/setup-node@v4
20+ with :
21+ node-version : latest
22+ - uses : actions/cache@v4
23+ id : cache-npm
24+ with :
25+ path : node_modules
26+ key : ${{ runner.os }}-node-${{ hashFiles('package-lock.json', 'src/**') }}
27+ - name : Run npm ci
28+ if : steps.cache-npm.outputs.cache-hit != 'true'
29+ run : npm ci
30+
31+ test :
32+ name : Check Javascript & CSS code style and run test
33+ runs-on : ubuntu-latest
34+ needs : [npm]
35+ steps :
36+ - uses : actions/checkout@v5
37+ - uses : actions/setup-node@v4
38+ with :
39+ node-version : latest
40+ - uses : actions/cache/restore@v4
41+ with :
42+ path : node_modules
43+ key : ${{ runner.os }}-node-${{ hashFiles('package-lock.json', 'src/**') }}
44+ - name : Check code style and run unit test
45+ run : npm run test
46+
47+ build :
48+ name : Build distribution
49+ runs-on : ubuntu-latest
50+ needs : [npm]
51+ steps :
52+ - uses : actions/checkout@v5
53+ - uses : actions/setup-node@v4
54+ with :
55+ node-version : latest
56+ - uses : actions/cache/restore@v4
57+ with :
58+ path : node_modules
59+ key : ${{ runner.os }}-node-${{ hashFiles('package-lock.json', 'src/**') }}
60+ - name : Run build
61+ run : npm run build
You can’t perform that action at this time.
0 commit comments