Skip to content

refactor: simplify Query command implementation (#160) #67

refactor: simplify Query command implementation (#160)

refactor: simplify Query command implementation (#160) #67

Workflow file for this run

name: rust
on:
pull_request:
push:
branches:
- main
env:
CARGO_TERM_COLOR: always
RUSTFLAGS: -D warnings
JUST_TIMESTAMP: true
JUST_COLOR: always
JUST_EXPLAIN: true
JUST_VERBOSE: 4
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: ${{ github.ref != 'refs/heads/main' && !startsWith(github.ref, 'refs/tags/') }}
jobs:
rust:
runs-on: ubuntu-latest
strategy:
matrix:
task: [build, lint, fmt, test, docs, coverage, deny, insta]
name: ${{ matrix.task }}
steps:
- uses: actions/cache/restore@36f1e144e1c8edb0a652766b484448563d8baf46 # v4
id: cache
with:
path: |
~/.rustup
~/.cargo/bin/
~/.cargo/.crates.toml
~/.cargo/.crates2.json
key: toolchain-${{ matrix.task }}
- uses: extractions/setup-just@e33e0265a09d6d736e2ee1e0eb685ef1de4669ff # v2
- uses: actions/checkout@09d2acae674a48949e3602304ab46fd20ae0c42f # v4
- uses: Swatinem/rust-cache@9d47c6ad4b02e050fd481d890b2ea34778fd09d6 # v2
with:
key: ${{ matrix.task }}
cache-bin: false
save-if: ${{ github.ref == 'refs/heads/main' }}
- run: just ${{ matrix.task }}-ci
- if: ${{ matrix.task == 'coverage' }}
uses: coverallsapp/github-action@648a8eb78e6d50909eff900e4ec85cab4524a45b # v2
with:
file: lcov.info
- if: ${{ github.ref == 'refs/heads/main' }}
uses: actions/cache/save@36f1e144e1c8edb0a652766b484448563d8baf46 # v4
with:
path: |
~/.rustup
~/.cargo/bin/
~/.cargo/.crates.toml
~/.cargo/.crates2.json
key: ${{ steps.cache.outputs.cache-primary-key }}