From f9a3c3f891a26ccc04c05c3a3c1ee23cd23fa797 Mon Sep 17 00:00:00 2001 From: Ashley Wulber Date: Mon, 19 Feb 2024 14:31:19 -0500 Subject: [PATCH 1/2] chore: refactor github ci so that it doesn't use 1.65 for tests --- .github/workflows/ci.yml | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2d9a6a7e7..99fb8c94b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -14,6 +14,44 @@ jobs: rust: ['1.65.0', 'stable', 'beta'] runs-on: ubuntu-latest + steps: + - name: Checkout sources + uses: actions/checkout@v2 + + - name: Cargo cache + uses: actions/cache@v1 + with: + path: ~/.cargo + key: cargo-${{ matrix.rust }} + + - name: Rust toolchain + uses: actions-rs/toolchain@v1 + with: + toolchain: ${{ matrix.rust }} + override: true + + - name: Install system dependencies + run: sudo apt-get install libxkbcommon-dev libwayland-dev + + - name: Check lib no features + uses: actions-rs/cargo@v1 + with: + command: check + args: --no-default-features + + - name: Check full features + uses: actions-rs/cargo@v1 + with: + command: check + args: --all-features + + test: + strategy: + fail-fast: false + matrix: + rust: ['stable', 'beta'] + runs-on: ubuntu-latest + steps: - name: Checkout sources uses: actions/checkout@v2 From b988e6c570949b0c7f0a323e5a64712769aa9c3b Mon Sep 17 00:00:00 2001 From: Ashley Wulber Date: Wed, 28 Feb 2024 20:11:02 -0500 Subject: [PATCH 2/2] refactor: simplify ci and use setup-rust-action --- .github/workflows/ci.yml | 37 ++++++++++--------------------------- 1 file changed, 10 insertions(+), 27 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 99fb8c94b..91587401b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -25,25 +25,18 @@ jobs: key: cargo-${{ matrix.rust }} - name: Rust toolchain - uses: actions-rs/toolchain@v1 + uses: hecrj/setup-rust-action@v1 with: - toolchain: ${{ matrix.rust }} - override: true + rust-version: ${{ matrix.rust }} - name: Install system dependencies run: sudo apt-get install libxkbcommon-dev libwayland-dev - name: Check lib no features - uses: actions-rs/cargo@v1 - with: - command: check - args: --no-default-features + run: cargo check --no-default-features - name: Check full features - uses: actions-rs/cargo@v1 - with: - command: check - args: --all-features + run: cargo check --all-features test: strategy: @@ -63,31 +56,21 @@ jobs: key: cargo-${{ matrix.rust }} - name: Rust toolchain - uses: actions-rs/toolchain@v1 + uses: hecrj/setup-rust-action@v1 with: - toolchain: ${{ matrix.rust }} - override: true + rust-version: ${{ matrix.rust }} - name: Install system dependencies run: sudo apt-get install libxkbcommon-dev libwayland-dev - name: Test lib no features - uses: actions-rs/cargo@v1 - with: - command: test - args: --no-default-features --lib + run: cargo test --no-default-features --lib - name: Test doc no features - uses: actions-rs/cargo@v1 - with: - command: test - args: --no-default-features --doc + run: cargo test --no-default-features --doc - name: Test full features - uses: actions-rs/cargo@v1 - with: - command: test - args: --all-features + run: cargo test --all-features lint: runs-on: ubuntu-latest @@ -97,7 +80,7 @@ jobs: uses: actions/checkout@v2 - name: Rust toolchain - uses: actions-rs/toolchain@v1 + uses: hecrj/setup-rust-action@v1 with: toolchain: stable override: true