Skip to content

Commit

Permalink
Check minimal versions more precisely
Browse files Browse the repository at this point in the history
  • Loading branch information
tottoto authored and seanmonstar committed Sep 27, 2023
1 parent da38b1c commit 62cf7a6
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 10 deletions.
19 changes: 10 additions & 9 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -61,10 +61,6 @@ jobs:
run: ./ci/h2spec.sh
if: matrix.rust == 'stable'

- name: Check minimal versions
run: cargo clean; cargo update -Zminimal-versions; cargo check
if: matrix.rust == 'nightly'

clippy_check:
runs-on: ubuntu-latest
steps:
Expand All @@ -83,14 +79,19 @@ jobs:
uses: actions/checkout@v3

- name: Get MSRV from package metadata
id: metadata
run: |
cargo metadata --no-deps --format-version 1 |
jq -r '"msrv=" + (.packages[] | select(.name == "h2")).rust_version' >> $GITHUB_OUTPUT
id: msrv
run: grep rust-version Cargo.toml | cut -d '"' -f2 | sed 's/^/version=/' >> $GITHUB_OUTPUT

- name: Install Rust (${{ steps.metadata.outputs.msrv }})
id: msrv-toolchain
uses: dtolnay/rust-toolchain@master
with:
toolchain: ${{ steps.metadata.outputs.msrv }}
toolchain: ${{ steps.msrv.outputs.version }}

- run: cargo check -p h2

- uses: dtolnay/rust-toolchain@nightly
- uses: taiki-e/install-action@cargo-hack
- uses: taiki-e/install-action@cargo-minimal-versions

- run: cargo +${{ steps.msrv-toolchain.outputs.name }} minimal-versions check
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ tokio-util = { version = "0.7.1", features = ["codec"] }
tokio = { version = "1", features = ["io-util"] }
bytes = "1"
http = "0.2"
tracing = { version = "0.1.21", default-features = false, features = ["std"] }
tracing = { version = "0.1.32", default-features = false, features = ["std"] }
fnv = "1.0.5"
slab = "0.4.2"
indexmap = { version = "1.5.2", features = ["std"] }
Expand Down

0 comments on commit 62cf7a6

Please sign in to comment.