Skip to content

Fix/missing oz contracts (#261) #812

Fix/missing oz contracts (#261)

Fix/missing oz contracts (#261) #812

Workflow file for this run

name: rust
permissions:
contents: read
on:
workflow_dispatch:
push:
branches: [main]
pull_request:
paths-ignore:
- 'website/**'
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
env:
CARGO_TERM_COLOR: always
jobs:
check:
name: Check
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v5
- name: Restore cache
id: cache-restore
uses: actions/cache/restore@v4
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
- run: rustup update
- run: rustup target add wasm32v1-none
- run: rustup component add rustfmt clippy
- name: Install system dependencies
run: |
sudo apt-get update
sudo apt-get install -y libdbus-1-dev pkg-config libudev-dev
- uses: taiki-e/install-action@nextest
- uses: taiki-e/install-action@just
- uses: cargo-bins/cargo-binstall@main
- name: Run cargo fmt
run: cargo fmt --all -- --check
- run: just setup
- name: build since clippy needs contracts to be built
run: just build
- name: Run cargo clippy
run: cargo clippy --all
- name: Unit Tests
run: just test
- name: Always Save Cache
id: cache-save
if: always() && steps.cache-restore.outputs.cache-hit != 'true'
uses: actions/cache/save@v4
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: ${{ steps.cache-restore.outputs.cache-primary-key }}