diff options
| author | Mica White <botahamec@outlook.com> | 2023-08-08 17:29:09 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-08-08 17:29:09 -0400 |
| commit | 24b3b0315317f89f69f82f7a90e48daa2c3cd98c (patch) | |
| tree | b883b9f50e39e2520cc4764cf8f6b845b46badb1 /.github/workflows/pr_check.yml | |
| parent | 136aa6b0a449fae0a6d96fa16d946e61b01cafc0 (diff) | |
Create pr_check.yml
Diffstat (limited to '.github/workflows/pr_check.yml')
| -rw-r--r-- | .github/workflows/pr_check.yml | 52 |
1 files changed, 52 insertions, 0 deletions
diff --git a/.github/workflows/pr_check.yml b/.github/workflows/pr_check.yml new file mode 100644 index 0000000..83ff4da --- /dev/null +++ b/.github/workflows/pr_check.yml @@ -0,0 +1,52 @@ +name: PR Check + +on: + pull_request: + branches: [ "main" ] + +env: + CARGO_TERM_COLOR: always + +jobs: + fmt: + name: rustfmt + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: actions-rs/toolchain@v1 + with: + profile: minimal + toolchain: stable + override: true + - uses: actions-rs/cargo@v1 + with: + command: fmt + args: --all -- --check + + clippy: + name: clippy + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v2 + - name: Install Rust Toolchain + uses: actions-rs/toolchain@v1 + with: + toolchain: stable + components: clippy + override: true + - name: Run rustfmt + run: cargo fmt -- --check + - name: Run clippy + run: cargo clippy --all-warnings --deny warnings + + test: + name: test + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: actions-rs/toolchain@v1 + with: + profile: minimal + toolchain: stable + override: true |
