Skip to content

Update all dependencies to latest versions #110

Update all dependencies to latest versions

Update all dependencies to latest versions #110

Workflow file for this run

name: Rust
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
env:
DATABASE_URL: sqlite:${{ github.workspace }}/healthpi.db
RUSTFLAGS: "-Dwarnings"
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install Rust toolchain
id: toolchain
uses: dtolnay/[email protected]
with:
components: clippy, rustfmt
- name: Install dependencies
run: sudo apt install libdbus-1-dev pkg-config && cargo install sqlx-cli
- name: Run migration
run: sqlx database create && sqlx migrate run
- name: Check formatting
run: cargo fmt --check
- name: Cache cargo dependencies
uses: actions/cache@v3
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: ${{ runner.os }}-${{ hashFiles('**/Cargo.lock') }}-rust-${{ steps.toolchain.outputs.cachekey }}
- name: Run clippy
run: cargo clippy
- name: Run tests
run: cargo test