Skip to content

Commit

Permalink
Merge #226
Browse files Browse the repository at this point in the history
226: Fix warnings in CI r=Aadamandersson a=Aadamandersson

This fixes the warnings in our CI.
We are currently using  [action-rs/toolchain](https://github.com/actions-rs/toolchain) to install the Rust toolchain in Github Actions. But as it seems to be unmaintained (see actions-rs/toolchain#216) and needs to be replaced to fix some of the warnings (see actions-rs/toolchain#219) I have replaced it with [dtolnay/rust-toolchain](https://github.com/dtolnay/rust-toolchain), which looks like a suitable replacement.

Co-authored-by: Adam Andersson <[email protected]>
  • Loading branch information
bors[bot] and Aadamandersson authored May 16, 2023
2 parents 22da3d6 + 2316f92 commit e691350
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 67 deletions.
8 changes: 4 additions & 4 deletions .github/bors.toml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
status = [
"Check (nightly)",
"Test (nightly)",
"Check",
"Test",
"Rustfmt",
"Clippy (nightly)",
"Deploy (nightly)",
"Clippy",
"Deploy",
"Typos"
]
delete_merged_branches = true
84 changes: 21 additions & 63 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,102 +12,60 @@ jobs:
check:
name: Check
runs-on: ubuntu-latest
strategy:
matrix:
rust:
- nightly
steps:
- uses: actions/[email protected]
- uses: actions-rs/[email protected]
with:
profile: minimal
toolchain: ${{ matrix.rust }}
override: true
- uses: actions-rs/[email protected]
with:
command: check
- uses: actions/checkout@v3
- uses: dtolnay/rust-toolchain@nightly
- uses: Swatinem/rust-cache@v2
- run: cargo check

test:
name: Test
runs-on: ubuntu-latest
strategy:
matrix:
rust:
- nightly
steps:
- uses: actions/[email protected]
- uses: actions-rs/[email protected]
with:
profile: minimal
toolchain: ${{ matrix.rust }}
override: true
- uses: actions-rs/[email protected]
with:
command: test
- uses: actions/checkout@v3
- uses: dtolnay/rust-toolchain@nightly
- uses: Swatinem/rust-cache@v2
- run: cargo test

deploy:
name: Deploy
runs-on: ubuntu-latest
strategy:
matrix:
rust:
- nightly
steps:
- uses: actions/[email protected]
- uses: actions-rs/[email protected]
with:
profile: minimal
toolchain: ${{ matrix.rust }}
override: true
- uses: actions/checkout@v3
- uses: dtolnay/rust-toolchain@nightly
- uses: Swatinem/rust-cache@v2
- uses: actions/setup-node@v3
with:
node-version-file: '.nvmrc'
- uses: actions-rs/[email protected]
with:
command: xtask
args: deploy --check
- run: cargo xtask deploy --check

rustfmt:
name: Rustfmt
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2.4.0
- uses: actions-rs/toolchain@v1.0.7
- uses: actions/checkout@v3
- uses: dtolnay/rust-toolchain@nightly
with:
profile: minimal
toolchain: nightly
components: rustfmt
override: true
- uses: actions-rs/[email protected]
with:
command: fmt
args: --check
- uses: Swatinem/rust-cache@v2
- run: cargo fmt --check

clippy:
name: Clippy
runs-on: ubuntu-latest
strategy:
matrix:
rust:
- nightly
steps:
- uses: actions/checkout@v2.4.0
- uses: actions-rs/toolchain@v1.0.7
- uses: actions/checkout@v3
- uses: dtolnay/rust-toolchain@nightly
with:
profile: minimal
toolchain: ${{ matrix.rust }}
components: clippy
override: true
- uses: actions-rs/[email protected]
with:
command: clippy
args: -- -Dwarnings
- uses: Swatinem/rust-cache@v2
- run: cargo clippy -- -Dwarnings

typos:
name: Typos
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2.4.0
- uses: actions/checkout@v3
- uses: crate-ci/[email protected]
with:
config: ./.typos.toml

0 comments on commit e691350

Please sign in to comment.