Skip to content

refactor: foundry.toml and CI #3

refactor: foundry.toml and CI

refactor: foundry.toml and CI #3

Workflow file for this run

name: CI
on:
pull_request:
jobs:
gas-report:
name: Report Gas
runs-on: ubuntu-latest
permissions: write-all
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Install Foundry
uses: foundry-rs/foundry-toolchain@v1
with:
version: nightly
- name: Install Dependencies
run: forge install
- name: Generate gas diff
uses: atarpara/[email protected]
with:
token: ${{ secrets.GITHUB_TOKEN }}
include-fuzz-tests: true
# fresh-snapshots: true
include-new-contracts: true
id : gas_diff
- name: Add gas diff to sticky comment
if: github.event_name == 'pull_request' || github.event_name == 'pull_request_target'
uses: marocchino/sticky-pull-request-comment@v2
with:
# delete the comment in case changes no longer impact gas costs
delete: ${{ !steps.gas_diff.outputs.markdown }}
message: ${{ steps.gas_diff.outputs.markdown }}
# https://github.com/atarpara/foundry-snapshot-diff