Skip to content

Merge pull request #61 from Zli-UoA/ticket/#31 #49

Merge pull request #61 from Zli-UoA/ticket/#31

Merge pull request #61 from Zli-UoA/ticket/#31 #49

Workflow file for this run

name: CI
on:
push:
paths:
- "backend/**"
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
defaults:
run:
working-directory: ./backend
steps:
- name: Setup Rust
uses: dtolnay/rust-toolchain@stable
- name: Checkout
uses: actions/checkout@v4
- name: Restore Cache
uses: Swatinem/rust-cache@v2
with:
workspaces: backend
- name: Build project
run: |
cargo build
lint:
runs-on: ubuntu-latest
defaults:
run:
working-directory: ./backend
steps:
- name: Setup Rust
uses: dtolnay/rust-toolchain@stable
- name: Checkout
uses: actions/checkout@v4
- name: Restore Cache
uses: Swatinem/rust-cache@v2
with:
workspaces: backend
- name: lint check
run: |
cargo clippy
- name: format check
run: |
cargo fmt --check
test:
runs-on: ubuntu-latest
defaults:
run:
working-directory: ./backend
steps:
- name: Setup Rust
uses: dtolnay/rust-toolchain@stable
- name: Checkout
uses: actions/checkout@v4
- name: Restore Cache
uses: Swatinem/rust-cache@v2
with:
workspaces: backend
- name: test
run: |
cargo test