Skip to content

Efficiency updates (#5) #45

Efficiency updates (#5)

Efficiency updates (#5) #45

Workflow file for this run

name: CI
on:
push:
branches: [main]
paths:
- 'method/**'
- '.github/workflows/ci.yml'
pull_request:
branches: [main]
paths:
- 'method/**'
- '.github/workflows/ci.yml'
workflow_dispatch:
jobs:
rust:
name: Rust build, test, lint
runs-on: ubuntu-latest
defaults:
run:
working-directory: method
steps:
- uses: actions/checkout@v4
- name: Install Rust toolchain
uses: dtolnay/rust-toolchain@stable
with:
components: rustfmt, clippy
- name: Cache cargo registry and target
uses: actions/cache@v4
with:
path: |
~/.cargo/registry
~/.cargo/git
method/target
key: cargo-${{ runner.os }}-${{ hashFiles('method/Cargo.lock') }}
restore-keys: |
cargo-${{ runner.os }}-
- name: cargo fmt --check
run: cargo fmt --all -- --check
- name: cargo clippy
run: cargo clippy --all-targets -- -D warnings
- name: cargo build
run: cargo build --verbose
- name: cargo test
run: cargo test --verbose