Skip to content

Commit

Permalink
ci: add job to check the contracts are formatted and can be compiled (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
ricomateo authored Jan 30, 2025
1 parent 4286221 commit df7ec47
Showing 1 changed file with 40 additions and 0 deletions.
40 changes: 40 additions & 0 deletions .github/workflows/contracts.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: Contracts CI

on:
push:
branches: [main]
pull_request:
branches: [ '**' ]

env:
FOUNDRY_PROFILE: ci

jobs:
check:
strategy:
fail-fast: true

name: Foundry project
runs-on: ubuntu-latest
defaults:
run:
working-directory: ./contracts

steps:
- uses: actions/checkout@v4
with:
submodules: recursive

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

- name: Show Forge version
run: forge --version

- name: Run Forge fmt
run: forge fmt --check

- name: Run Forge build
run: forge build

0 comments on commit df7ec47

Please sign in to comment.