Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
46 changes: 46 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,52 @@ permissions:
contents: read

jobs:
msrv:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false
- name: Find the declared MSRV
shell: bash # Without this, the shell here is `bash` but without `-o pipefail`.
Comment thread
EliahKagan marked this conversation as resolved.
run: |
msrv="$(
cargo metadata --format-version 1 --no-deps |
jq -er '
.packages[]
| select(.name == "prodash")
| .rust_version
'
)"

# Expand to x.y.0, since rustup would otherwise install the newest x.y.z.
case "$msrv" in
*.*.*) ;;
*) msrv="$msrv.0" ;;
esac

tee -a "$GITHUB_ENV" <<<"MSRV=$msrv"
- name: Install the MSRV toolchain
run: rustup toolchain install "$MSRV" --profile minimal --no-self-update
- name: Check the base crate on the declared MSRV
run: cargo "+$MSRV" check --locked --lib

all-features-floor:
runs-on: ubuntu-latest
env:
# Not the MSRV. `rust-version` covers the base crate, while optional features can
# need newer compilers through their optional dependencies. Hard-coded, so that
# a rise in this floor fails here.
ALL_FEATURES_FLOOR: "1.88.0"
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false
- name: Install the all-features floor toolchain
run: rustup toolchain install "$ALL_FEATURES_FLOOR" --profile minimal --no-self-update
- name: Check every feature at once
run: cargo "+$ALL_FEATURES_FLOOR" check --locked --all-features

build-and-test-linux:
runs-on: ubuntu-latest
steps:
Expand Down