From 8a16eb4cb3552023a8e8b384b47abb7ccd64d13f Mon Sep 17 00:00:00 2001 From: Dirk Stolle Date: Mon, 19 Jun 2023 19:43:33 +0200 Subject: [PATCH] replace unmaintained actions-rs/* actions in CI workflows (#1099) Basically all of the `actions-rs/*` actions are unmaintained. See for more information. Due to their age they generate several warnings in CI runs. To get rid of those warnings the occurrences of `actions-rs/toolchain` are replaced by `dtolnay/rust-toolchain`, and the occurrences of `actions-rs/cargo` are replaced by direct invocations of `cargo`. --- .github/workflows/macos.yml | 11 ++-------- .github/workflows/main.yml | 44 +++++++------------------------------ 2 files changed, 10 insertions(+), 45 deletions(-) diff --git a/.github/workflows/macos.yml b/.github/workflows/macos.yml index c5616322e..b80a7b1f5 100644 --- a/.github/workflows/macos.yml +++ b/.github/workflows/macos.yml @@ -30,14 +30,7 @@ jobs: name: Test Suite runs-on: macos-latest steps: - - uses: actions-rs/toolchain@v1 - with: - profile: minimal - toolchain: stable - override: true + - uses: dtolnay/rust-toolchain@stable - uses: Swatinem/rust-cache@v2 - uses: actions/checkout@v3 - - uses: actions-rs/cargo@v1 - with: - command: test - args: --all --tests + - run: cargo test --all --tests diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index a3bff9fc6..1a4b156cd 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -32,30 +32,19 @@ jobs: name: Check runs-on: ubuntu-latest steps: - - uses: actions-rs/toolchain@v1 - with: - profile: minimal - toolchain: stable - override: true + - uses: dtolnay/rust-toolchain@stable - uses: Swatinem/rust-cache@v2 - run: sudo apt-get update - run: sudo apt install libwebkit2gtk-4.1-dev libgtk-3-dev libayatana-appindicator3-dev - uses: actions/checkout@v3 - - uses: actions-rs/cargo@v1 - with: - command: check - args: --all --examples --tests + - run: cargo check --all --examples --tests test: if: github.event.pull_request.draft == false name: Test Suite runs-on: ubuntu-latest steps: - - uses: actions-rs/toolchain@v1 - with: - profile: minimal - toolchain: stable - override: true + - uses: dtolnay/rust-toolchain@stable - uses: Swatinem/rust-cache@v2 - run: sudo apt-get update - run: sudo apt install libwebkit2gtk-4.1-dev libgtk-3-dev libayatana-appindicator3-dev @@ -63,48 +52,31 @@ jobs: - uses: browser-actions/setup-firefox@latest - uses: jetli/wasm-pack-action@v0.4.0 - uses: actions/checkout@v3 - - uses: actions-rs/cargo@v1 - with: - command: make - args: tests + - run: cargo make tests fmt: if: github.event.pull_request.draft == false name: Rustfmt runs-on: ubuntu-latest steps: - - uses: actions-rs/toolchain@v1 - with: - profile: minimal - toolchain: stable - override: true + - uses: dtolnay/rust-toolchain@stable - uses: Swatinem/rust-cache@v2 - run: rustup component add rustfmt - uses: actions/checkout@v3 - - uses: actions-rs/cargo@v1 - with: - command: fmt - args: --all -- --check + - run: cargo fmt --all -- --check clippy: if: github.event.pull_request.draft == false name: Clippy runs-on: ubuntu-latest steps: - - uses: actions-rs/toolchain@v1 - with: - profile: minimal - toolchain: stable - override: true + - uses: dtolnay/rust-toolchain@stable - uses: Swatinem/rust-cache@v2 - run: sudo apt-get update - run: sudo apt install libwebkit2gtk-4.1-dev libgtk-3-dev libayatana-appindicator3-dev - run: rustup component add clippy - uses: actions/checkout@v3 - - uses: actions-rs/cargo@v1 - with: - command: clippy - args: --workspace --examples --tests -- -D warnings + - run: cargo clippy --workspace --examples --tests -- -D warnings # Coverage is disabled until we can fix it # coverage: