Skip to content
Merged
Changes from 3 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
55 changes: 54 additions & 1 deletion .github/workflows/contracts.yml
Original file line number Diff line number Diff line change
Expand Up @@ -136,4 +136,57 @@
run: npx hardhat compile

- name: Run hardhat tests
run: npx hardhat test
run: npx hardhat test

lint:
if: github.event.pull_request.draft == false
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- uses: actions/setup-node@v4
with:
node-version: '18'
- run: yarn install --frozen-lockfile

- uses: foundry-rs/foundry-toolchain@v1 # stable channel is fine
- name: Check Solidity formatting
run: forge fmt --check

- name: Check JS/docs formatting
run: npx prettier --check "**/*.{js,ts,jsx,tsx,md,json,yml,yaml}"

slither:
needs: foundry
runs-on: ubuntu-latest
env:
FOUND_OUT_DIR: artifacts
steps:
- uses: actions/checkout@v4

- uses: actions/setup-node@v4
with: { node-version: '18' }
- run: yarn install --frozen-lockfile

- uses: foundry-rs/foundry-toolchain@v1
with: { version: nightly }
- run: forge build --build-info --evm-version cancun

- uses: actions/setup-python@v5
with: { python-version: '3.11' }
- run: |
python -m pip install --upgrade pip
pip install slither-analyzer==0.11.0
- name: Run Slither
run: |
slither . \
--foundry-out-directory "$FOUND_OUT_DIR" \
--exclude-dependencies \
--json slither-report.json \
--markdown-root slither-report.md
- uses: actions/upload-artifact@v4
with:
name: slither-static-analysis
path: |
slither-report.json
slither-report.md
Loading