mirror of
https://github.com/SableClient/Sable.git
synced 2026-11-20 00:51:17 -08:00
Bumps the github-actions group with 2 updates in the / directory: [actions/attest-build-provenance](https://github.com/actions/attest-build-provenance) and [Swatinem/rust-cache](https://github.com/swatinem/rust-cache). Updates `actions/attest-build-provenance` from 4.1.1 to 4.2.2 - [Release notes](https://github.com/actions/attest-build-provenance/releases) - [Changelog](https://github.com/actions/attest-build-provenance/blob/main/RELEASE.md) - [Commits](https://github.com/actions/attest-build-provenance/compare/0f67c3f4856b2e3261c31976d6725780e5e4c373...4d101475d8b20a2381f78447822ac1eab6504dd8) Updates `Swatinem/rust-cache` from 2.9.1 to 2.9.2 - [Release notes](https://github.com/swatinem/rust-cache/releases) - [Changelog](https://github.com/Swatinem/rust-cache/blob/master/CHANGELOG.md) - [Commits](https://github.com/swatinem/rust-cache/compare/c19371144df3bb44fab255c43d04cbc2ab54d1c4...6323deb102c322ba6fcbdcafc7e3dddab59af2b6) --- updated-dependencies: - dependency-name: actions/attest-build-provenance dependency-version: 4.2.2 dependency-type: direct:production update-type: version-update:semver-minor dependency-group: github-actions - dependency-name: Swatinem/rust-cache dependency-version: 2.9.2 dependency-type: direct:production update-type: version-update:semver-patch dependency-group: github-actions ... Signed-off-by: dependabot[bot] <[email protected]>
88 lines
2.3 KiB
YAML
88 lines
2.3 KiB
YAML
name: Rust quality checks
|
|
|
|
on:
|
|
pull_request:
|
|
paths:
|
|
- 'src-tauri/**'
|
|
- '.github/workflows/rust-quality.yml'
|
|
push:
|
|
branches: [dev]
|
|
paths:
|
|
- 'src-tauri/**'
|
|
- '.github/workflows/rust-quality.yml'
|
|
merge_group:
|
|
|
|
permissions: {}
|
|
|
|
jobs:
|
|
format:
|
|
name: Rust format
|
|
runs-on: ubuntu-latest
|
|
permissions:
|
|
contents: read
|
|
env:
|
|
CARGO_INCREMENTAL: 0
|
|
CARGO_TERM_COLOR: always
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
with:
|
|
persist-credentials: false
|
|
|
|
- name: Setup mise
|
|
uses: jdx/mise-action@7e36c90d9ab29c415a2384db3006f3ec8a8cc654 # v4.2.4
|
|
with:
|
|
cache: true
|
|
|
|
- name: Check Rust formatting
|
|
run: cargo fmt --manifest-path src-tauri/Cargo.toml -- --check
|
|
|
|
checks:
|
|
name: Rust check, test, and Clippy
|
|
runs-on: ubuntu-22.04
|
|
permissions:
|
|
contents: read
|
|
env:
|
|
CARGO_INCREMENTAL: 0
|
|
CARGO_TERM_COLOR: always
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
with:
|
|
persist-credentials: false
|
|
|
|
- name: Install Tauri build dependencies
|
|
run: |
|
|
sudo apt-get update
|
|
sudo apt-get install -y \
|
|
build-essential \
|
|
libayatana-appindicator3-dev \
|
|
libgtk-3-dev \
|
|
librsvg2-dev \
|
|
libsoup-3.0-dev \
|
|
libssl-dev \
|
|
libwebkit2gtk-4.1-dev \
|
|
libxdo-dev \
|
|
pkg-config
|
|
|
|
- name: Setup mise
|
|
uses: jdx/mise-action@7e36c90d9ab29c415a2384db3006f3ec8a8cc654 # v4.2.4
|
|
with:
|
|
cache: true
|
|
|
|
- name: Cache Rust build
|
|
uses: Swatinem/rust-cache@6323deb102c322ba6fcbdcafc7e3dddab59af2b6 # v2.9.2
|
|
with:
|
|
workspaces: src-tauri
|
|
# Restore only on PRs; the repo sits at the 10 GiB cache cap.
|
|
save-if: ${{ github.ref == 'refs/heads/dev' }}
|
|
|
|
- name: Check native app
|
|
run: cargo check --locked --manifest-path src-tauri/Cargo.toml
|
|
|
|
- name: Run Rust tests
|
|
run: cargo test --locked --manifest-path src-tauri/Cargo.toml
|
|
|
|
- name: Run Clippy
|
|
run: cargo clippy --locked --manifest-path src-tauri/Cargo.toml --all-targets -- -D warnings
|