Fix new clippy warnings introduced in Rust 1.97 #572
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| on: | |
| push: | |
| pull_request: | |
| workflow_dispatch: | |
| jobs: | |
| ci_stable: | |
| runs-on: ${{ matrix.os }} | |
| strategy: | |
| matrix: | |
| os: [ macos-latest, windows-latest, windows-11-arm, ubuntu-latest, ubuntu-24.04-arm ] | |
| steps: | |
| - name: Fetch head | |
| uses: actions/checkout@v7 | |
| - name: Install rust stable | |
| uses: actions-rust-lang/setup-rust-toolchain@v1 | |
| with: | |
| toolchain: stable | |
| components: rustfmt, clippy | |
| - name: Format check | |
| run: cargo fmt --check | |
| - name: Clippy check | |
| run: cargo clippy --no-deps --all-targets --all-features -- -D warnings | |
| - name: Build native | |
| run: cargo build --all-targets --all-features --verbose | |
| - name: Install and start gnome-keyring | |
| if: matrix.os == 'ubuntu-latest' | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y gnome-keyring | |
| # run gnome-keyring with 'foobar' as the password for the login keyring | |
| # this will create a new login keyring and unlock it | |
| # the login password doesn't matter, but the keyring must be unlocked for the tests to work | |
| gnome-keyring-daemon --components=secrets --daemonize --unlock <<< 'foobar' | |
| - name: Test native | |
| if: matrix.os == 'ubuntu-latest' || matrix.os == 'macos-latest' || matrix.os == 'windows-latest' | |
| run: cargo test --lib --all-features --verbose | |
| - name: Build iOS | |
| if: matrix.os == 'macos-latest' | |
| run: | | |
| rustup target add aarch64-apple-ios | |
| cargo build --target aarch64-apple-ios --all-features --verbose | |
| - name: Setup Android NDK | |
| if: matrix.os == 'ubuntu-latest' | |
| uses: nttld/setup-ndk@v1 | |
| id: setup-ndk | |
| with: | |
| ndk-version: r29 | |
| - name: Build Android | |
| if: matrix.os == 'ubuntu-latest' | |
| env: | |
| ANDROID_NDK_HOME: ${{ steps.setup-ndk.outputs.ndk-path }} | |
| ANDROID_NDK_ROOT: ${{ steps.setup-ndk.outputs.ndk-path }} | |
| run: | | |
| rustup target add aarch64-linux-android | |
| cargo install cargo-ndk | |
| cargo ndk -t arm64-v8a build --all-features --verbose | |
| ci_msrv: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Fetch head | |
| uses: actions/checkout@v7 | |
| - name: Install rust MSRV | |
| uses: actions-rust-lang/setup-rust-toolchain@v1 | |
| with: | |
| toolchain: 1.88 | |
| components: clippy | |
| - name: Clippy check | |
| run: cargo clippy --no-deps --all-targets --all-features -- -D warnings |