Skip to content

Commit

Permalink
Merge pull request #2 from nyonson/chore/add-format-check
Browse files Browse the repository at this point in the history
Add format and lint check to CI
  • Loading branch information
rustaceanrob authored Mar 1, 2024
2 parents b9eade9 + 9911633 commit 60fdcf8
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 8 deletions.
15 changes: 12 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ name: Cargo Build & Test

on:
push:
branches:
- main
pull_request:

jobs:
Expand All @@ -16,8 +18,15 @@ jobs:
- nightly
steps:
- uses: actions/checkout@v3
- run: rustup update ${{ matrix.toolchain }} && rustup default ${{ matrix.toolchain }}
- run: cargo build --verbose
- run: cargo test --verbose
- name: Update Toolchain
run: rustup default ${{ matrix.toolchain }} && rustup component add --toolchain ${{ matrix.toolchain }} rustfmt && rustup component add --toolchain ${{ matrix.toolchain }} clippy && rustup update ${{ matrix.toolchain }}
- name: Build
run: cargo build --verbose
- name: Lint
run: cargo clippy --all --all-targets
- name: Format
run: cargo fmt --all -- --check
- name: Test
run: cargo test --verbose


2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
/target
# IDEs
.vscode/
5 changes: 0 additions & 5 deletions .vscode/settings.json

This file was deleted.

0 comments on commit 60fdcf8

Please sign in to comment.