File tree Expand file tree Collapse file tree 4 files changed +2709
-1003
lines changed Expand file tree Collapse file tree 4 files changed +2709
-1003
lines changed Original file line number Diff line number Diff line change 1414
1515jobs :
1616 lint :
17- name : Javascript standard lint
17+ name : Lint commit messages and code
1818 runs-on : ubuntu-latest
1919 steps :
2020 - name : Checkout repository
2121 uses : actions/checkout@v4
2222 with :
2323 persist-credentials : false
2424 show-progress : false
25+ fetch-depth : 0
2526
2627 - name : setup node
2728 uses : actions/setup-node@v4
2829 with :
2930 node-version : 20
3031 cache : npm
31- - run : npm clean-install
32- - run : npm run lint
32+
33+ - name : Install npm dependencies
34+ run : npm clean-install
35+
36+ - name : Validate current commit (last commit) with commitlint
37+ if : github.event_name == 'push'
38+ run : npx commitlint --last --verbose
39+
40+ - name : Validate PR commits with commitlint
41+ if : github.event_name == 'pull_request'
42+ run : npx commitlint --from ${{ github.event.pull_request.base.sha }} --to ${{ github.event.pull_request.head.sha }} --verbose
43+
44+ - name : Lint code
45+ run : npm run lint
3346
3447 unittest :
3548 name : unit tests
Original file line number Diff line number Diff line change 1+ export default {
2+ extends : [ '@commitlint/config-conventional' ] ,
3+ rules : {
4+ // disable max body line length - otherwise dependabot can error
5+ 'body-max-line-length' : [ 0 ] ,
6+ } ,
7+ } ;
You can’t perform that action at this time.
0 commit comments