30 lines
651 B
YAML
30 lines
651 B
YAML
name: Rust
|
|
|
|
on:
|
|
push:
|
|
branches: [ "master" ]
|
|
pull_request:
|
|
branches: [ "master" ]
|
|
|
|
env:
|
|
CARGO_TERM_COLOR: always
|
|
|
|
jobs:
|
|
build:
|
|
if: ${{ false }} # <- This make sure the workflow is skipped without any alert
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- uses: actions/checkout@v3
|
|
- name: Install rust toolchain
|
|
run: curl https://sh.rustup.rs -sSf | sh -s -- -y --default-toolchain nightly
|
|
- name: Build
|
|
run: $HOME/.cargo/bin/cargo build --verbose
|
|
- name: Run tests
|
|
run: $HOME/.cargo/bin/cargo test --verbose
|
|
- name: Clippy
|
|
run: cargo clippy
|
|
- name: Formatting
|
|
run: cargo fmt --check
|