2023-10-13 02:02:43 +00:00
|
|
|
name: pr
|
|
|
|
|
2023-05-22 23:01:40 +00:00
|
|
|
on:
|
2023-10-13 01:47:10 +00:00
|
|
|
pull_request:
|
|
|
|
branches: ["main"]
|
2023-05-22 23:01:40 +00:00
|
|
|
|
|
|
|
env:
|
2023-10-13 01:47:10 +00:00
|
|
|
CARGO_TERM_COLOR: always
|
2023-05-22 23:01:40 +00:00
|
|
|
|
|
|
|
jobs:
|
2023-10-13 02:02:43 +00:00
|
|
|
build:
|
2023-10-13 01:47:10 +00:00
|
|
|
runs-on: ubuntu-latest
|
2023-05-23 04:43:48 +00:00
|
|
|
|
2023-10-13 01:47:10 +00:00
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v3
|
2023-05-23 04:43:48 +00:00
|
|
|
|
2023-10-13 01:47:10 +00:00
|
|
|
# Install Rust with clippy/rustfmt
|
|
|
|
- uses: actions-rust-lang/setup-rust-toolchain@v1
|
|
|
|
with:
|
|
|
|
components: clippy, rustfmt
|
2023-05-23 19:04:27 +00:00
|
|
|
|
2023-10-13 01:47:10 +00:00
|
|
|
# Make sure u guys don't write bad code
|
|
|
|
- run: cargo test --verbose
|
|
|
|
- run: cargo clippy --no-deps
|
|
|
|
- run: cargo fmt --check
|
2023-10-16 04:05:40 +00:00
|
|
|
|
|
|
|
# Check for unused dependencies
|
|
|
|
- uses: bnjbvr/cargo-machete@main
|