Merge branch 'main' into wire-up-leaderboard #1
This file contains hidden or 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: Contracts CI | |
| on: | |
| push: | |
| paths: | |
| - "contracts/**" | |
| pull_request: | |
| paths: | |
| - "contracts/**" | |
| env: | |
| CARGO_TERM_COLOR: always | |
| jobs: | |
| contracts: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Install Rust toolchain | |
| uses: dtolnay/rust-toolchain@stable | |
| - name: Add wasm target | |
| run: rustup target add wasm32v1-none | |
| - name: Cache cargo and target | |
| uses: Swatinem/rust-cache@v2 | |
| with: | |
| workspaces: ". -> target" | |
| - name: Build contracts | |
| run: cargo build --target wasm32v1-none --release | |
| - name: Run tests | |
| run: cargo test | |
| - name: Run clippy | |
| run: cargo clippy -- -D warnings | |
| - name: Check formatting | |
| run: cargo fmt --check |