diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index d73cad0..a097085 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -2,6 +2,8 @@ name: Cargo Build & Test on: push: + branches: + - main pull_request: jobs: @@ -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 diff --git a/.gitignore b/.gitignore index ea8c4bf..0a76350 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,3 @@ /target +# IDEs +.vscode/