Skip to content

Commit

Permalink
Add min rust version check
Browse files Browse the repository at this point in the history
  • Loading branch information
DoumanAsh committed Jul 26, 2024
1 parent 0aef808 commit ce13092
Showing 1 changed file with 25 additions and 0 deletions.
25 changes: 25 additions & 0 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
name: Rust

env:
min_rust_version: "1.64.0"

on:
push:
branches:
Expand All @@ -20,6 +23,28 @@ on:
- 'Cargo.toml'

jobs:
min-rust-check:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
- name: Install Rust Unix
run: |
if rustup --version >/dev/null 2>&1; then
rustup install ${{ env.min_rust_version }}
rustup default ${{ env.min_rust_version }}
else
curl https://sh.rustup.rs -sSf | sh -s -- -y --profile minimal --default-toolchain ${{ env.min_rust_version }}
echo ::add-path::$HOME/.cargo/bin
fi
- name: Rust version
run: |
cargo --version
rustc --version
- name: Check
run: |
cargo check --features xxh32,const_xxh32,xxh64,const_xxh64,xxh3,const_xxh3
full-test:
runs-on: ubuntu-latest
if: github.event.pull_request.draft == false
Expand Down

0 comments on commit ce13092

Please sign in to comment.