diff options
Diffstat (limited to '.github/workflows')
-rw-r--r-- | .github/workflows/rust.yml | 39 |
1 files changed, 15 insertions, 24 deletions
diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index 225b523..5c5f8e2 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -2,37 +2,28 @@ name: Rust on: push: - branches: [ master ] + branches: [master] pull_request: - branches: [ master ] + branches: [master] env: CARGO_TERM_COLOR: always jobs: build: - runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 - - uses: actions/cache@v2 - with: - path: | - ~/.cargo/registry - ~/.cargo/git - target - key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }} - - uses: actions-rs/toolchain@v1 - with: - toolchain: nightly - target: thumbv7em-none-eabihf - override: true - components: rustfmt - - - name: Build - run: ./ci.sh - - - name: Format - run: cargo fmt --verbose - + - uses: actions/checkout@v2 + - uses: actions/cache@v2 + with: + path: | + ~/.cargo/registry + ~/.cargo/git + target + key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }} + + - name: Check fmt + run: cargo fmt -- --check + - name: Build + run: ./ci.sh |