Skip to content

🚀 Major Quality Improvements: Security, Performance & Test Coverage #88

🚀 Major Quality Improvements: Security, Performance & Test Coverage

🚀 Major Quality Improvements: Security, Performance & Test Coverage #88

Workflow file for this run

name: Rust Build
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
permissions:
contents: read
statuses: write
env:
CARGO_TERM_COLOR: always
CARGO_INCREMENTAL: 0
CARGO_NET_RETRY: 10
RUST_BACKTRACE: short
RUSTFLAGS: "-D warnings"
RUSTUP_MAX_RETRIES: 10
# Cancel previous runs on new push
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
build:
runs-on: ubuntu-latest
timeout-minutes: 30
steps:
- uses: actions/checkout@v4
- name: Install Rust nightly
uses: dtolnay/rust-toolchain@nightly
with:
components: llvm-tools-preview
- name: Setup sccache
id: sccache
uses: mozilla-actions/sccache-action@v0.0.4
continue-on-error: true
- name: Configure sccache
if: steps.sccache.outcome == 'success'
run: |
echo "RUSTC_WRAPPER=sccache" >> $GITHUB_ENV
echo "SCCACHE_GHA_ENABLED=true" >> $GITHUB_ENV
- name: Cache Cargo
uses: Swatinem/rust-cache@v2
with:
shared-key: "build"
save-if: ${{ github.ref == 'refs/heads/main' }}
- name: Build with nightly features
run: |
echo "Using Rust nightly for zero-cost GAT abstractions"
rustc --version
cargo build --verbose --all-features --workspace
- name: Build release
run: cargo build --release --verbose --all-features --workspace
- name: sccache stats
if: always()
run: sccache --show-stats || echo "sccache not available"
continue-on-error: true