chore: optimize workspace for faster build #83
Workflow file for this run
This file contains 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: Cairo Contracts | |
on: | |
pull_request: | |
paths: | |
- .github/workflows/cairo-contracts.yaml | |
- cairo-contracts/** | |
- justfile | |
push: | |
tags: | |
- v[0-9]+.* | |
branches: | |
- "release/*" | |
- main | |
jobs: | |
test-contracts: | |
name: Test Cairo Contracts | |
runs-on: ubuntu-latest | |
timeout-minutes: 60 | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: cachix/install-nix-action@V27 | |
with: | |
extra_nix_config: | | |
experimental-features = nix-command flakes | |
- uses: cachix/cachix-action@v15 | |
with: | |
name: ibc-starknet | |
extraPullNames: hermes-sdk,cosmos-nix | |
authToken: ${{ secrets.CACHIX_AUTH_TOKEN }} | |
- name: Build Cairo contracts | |
working-directory: ./cairo-contracts | |
run: | | |
nix shell ..#scarb -c \ | |
scarb build | |
- name: Run Tests | |
working-directory: ./cairo-contracts | |
run: | | |
nix shell ..#snforge -c \ | |
snforge test |