Update CI workflows + add badges to README #1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Slither analysis | |
on: | |
workflow_dispatch: | |
pull_request: | |
push: | |
branches: | |
- main | |
jobs: | |
analyze: | |
strategy: | |
fail-fast: true | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
submodules: recursive | |
- name: ❇️ Setup Node.js v20 | |
uses: actions/setup-node@v4 | |
with: | |
node-version: "20.x" | |
cache: "npm" | |
- name: Install Foundry | |
uses: foundry-rs/foundry-toolchain@v1 | |
- name: Install dependencies | |
run: | | |
npm ci | |
forge install | |
- name: Build project | |
run: npm run build | |
- name: Run Slither | |
uses: crytic/[email protected] | |
id: slither | |
with: | |
sarif: results.sarif | |
fail-on: none | |
node-version: 18 | |
ignore-compile: true | |
- name: Upload SARIF file | |
uses: github/codeql-action/upload-sarif@v2 | |
with: | |
sarif_file: ${{ steps.slither.outputs.sarif }} |