Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: add slither static analysis checks #197

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 23 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,3 +55,26 @@ jobs:
id: coverage

- uses: codecov/codecov-action@v3

slither-analyze:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

- name: Install foundry
uses: foundry-rs/foundry-toolchain@v1
with:
version: nightly

- name: Run Slither
uses: crytic/slither-action@main
id: slither # Required to reference this step in the next step.
with:
fail-on: none # Required to avoid failing the CI run regardless of findings.
sarif: results.sarif
slither-args: --filter-paths "./lib|./test|./script" --exclude naming-convention

- name: Upload SARIF file
uses: github/codeql-action/upload-sarif@v2
with:
sarif_file: ${{ steps.slither.outputs.sarif }}