Skip to content

Commit

Permalink
ci: move web3 commit lint to parallel check (solana-labs#21414)
Browse files Browse the repository at this point in the history
  • Loading branch information
jstarry authored Nov 24, 2021
1 parent 3c2276f commit c68a11f
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 7 deletions.
32 changes: 26 additions & 6 deletions .github/workflows/web3.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,18 +19,16 @@ jobs:
steps:
- run: echo "Done"

check-web3:
web3-commit-lint:
runs-on: ubuntu-latest
# Set to true in order to avoid cancelling other workflow jobs.
# Mergify will still require web3-commit-lint for automerge
continue-on-error: true

defaults:
run:
working-directory: web3.js

strategy:
matrix:
node: [ '12', '14', '16' ]

name: Node ${{ matrix.node }}
steps:
- uses: actions/checkout@v2
with:
Expand All @@ -48,6 +46,28 @@ jobs:
run: bash commitlint.sh
env:
COMMIT_RANGE: ${{ github.event.pull_request.base.sha }}..${{ github.event.pull_request.head.sha }}

check-web3:
runs-on: ubuntu-latest

defaults:
run:
working-directory: web3.js

strategy:
matrix:
node: [ '12', '14', '16' ]

name: Node ${{ matrix.node }}
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: ${{ matrix.node }}
cache: 'npm'
cache-dependency-path: web3.js/package-lock.json
- run: npm i -g npm@7
- run: npm ci
- run: npm run lint
- run: |
npm run build
Expand Down
4 changes: 3 additions & 1 deletion .mergify.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,10 @@ pull_request_rules:
- status-success=check-explorer
- -files~=^explorer/
- or:
- and:
- status-success=all-web3-checks
- status-success=web3-commit-lint
# only require web3 checks if web3.js files changed
- status-success=all-web3-checks
- -files~=^web3.js/
actions:
merge:
Expand Down

0 comments on commit c68a11f

Please sign in to comment.