File tree Expand file tree Collapse file tree 1 file changed +47
-0
lines changed Expand file tree Collapse file tree 1 file changed +47
-0
lines changed Original file line number Diff line number Diff line change 1+ name : Scratch Parser CI-CD
2+
3+ on :
4+ pull_request : # Runs whenever a pull request is created or updated
5+ push : # Runs whenever a commit is pushed to the repository...
6+ branches : [master] # ...on any of these branches
7+ concurrency :
8+ group : ' ${{ github.workflow }} @ ${{ github.event.pull_request.head.label || github.head_ref || github.ref }}'
9+ cancel-in-progress : true
10+
11+ permissions :
12+ contents : write
13+ pages : write
14+ issues : write
15+ pull-requests : write
16+
17+ jobs :
18+ build-and-deploy :
19+ runs-on : ubuntu-latest
20+ steps :
21+ - uses : actions/checkout@v4
22+ - uses : wagoid/commitlint-github-action@v5
23+ - uses : actions/setup-node@v3
24+ with :
25+ cache : " npm"
26+ node-version-file : " .nvmrc"
27+ - name : Info
28+ run : |
29+ cat <<EOF
30+ Node version: $(node --version)
31+ NPM version: $(npm --version)
32+ GitHub ref: ${{ github.ref }}
33+ GitHub head ref: ${{ github.head_ref }}
34+ EOF
35+ - name : Install NPM Dependencies
36+ run : |
37+ npm ci
38+ - name : Lint
39+ run : npm run test:lint
40+ - name : Run All Tests
41+ run : npm run test
42+ - name : Semantic Release
43+ if : github.ref == 'master'
44+ env :
45+ NPM_TOKEN : ${{ secrets.NPM_TOKEN }}
46+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
47+ run : npx --no -- semantic-release
You can’t perform that action at this time.
0 commit comments