Moved CI into one file, lint depends on build

This commit is contained in:
Xithrius 2021-09-19 17:26:40 -07:00
parent 869fd53ab0
commit 3ab4f8ff57
No known key found for this signature in database
GPG Key ID: BD0FC909FA912B62
2 changed files with 21 additions and 26 deletions

View File

@ -1,4 +1,4 @@
name: Building & Testing
name: CI
on:
push:
@ -10,7 +10,7 @@ env:
CARGO_TERM_COLOR: always
jobs:
build:
build-test:
strategy:
fail-fast: false
@ -34,3 +34,22 @@ jobs:
- name: Run tests
run: cargo test --verbose
lint:
name: Formatter
needs: build-test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Install Rust
run: |
rustup update stable
rustup default stable
rustup component add rustfmt
- name: Check Formatting
run: cargo fmt --all -- --check

View File

@ -1,24 +0,0 @@
name: Linting
on:
push:
branches:
- main
pull_request:
jobs:
rustfmt:
name: Formatter
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Install Rust
run: |
rustup update stable
rustup default stable
rustup component add rustfmt
- name: Check Formatting
run: cargo fmt --all -- --check