mirror of
https://github.com/lldap/lldap.git
synced 2026-03-31 15:07:48 +01:00
Use variable for Rust version in CI workflow
Replace hardcoded "1.85.0" references with RUST_VERSION environment variable for better maintainability. Now the Rust version only needs to be updated in one place. Co-authored-by: nitnelave <796633+nitnelave@users.noreply.github.com>
This commit is contained in:
@@ -8,6 +8,7 @@ on:
|
||||
|
||||
env:
|
||||
CARGO_TERM_COLOR: always
|
||||
RUST_VERSION: "1.85.0"
|
||||
|
||||
jobs:
|
||||
pre_job:
|
||||
@@ -34,10 +35,10 @@ jobs:
|
||||
steps:
|
||||
- name: Checkout sources
|
||||
uses: actions/checkout@v5.0.0
|
||||
- name: Install Rust 1.85.0
|
||||
- name: Install Rust ${{ env.RUST_VERSION }}
|
||||
uses: dtolnay/rust-toolchain@stable
|
||||
with:
|
||||
toolchain: 1.85.0
|
||||
toolchain: ${{ env.RUST_VERSION }}
|
||||
- uses: Swatinem/rust-cache@v2
|
||||
- name: Build
|
||||
run: cargo build --verbose --workspace
|
||||
@@ -58,10 +59,10 @@ jobs:
|
||||
- name: Checkout sources
|
||||
uses: actions/checkout@v5.0.0
|
||||
|
||||
- name: Install Rust 1.85.0
|
||||
- name: Install Rust ${{ env.RUST_VERSION }}
|
||||
uses: dtolnay/rust-toolchain@stable
|
||||
with:
|
||||
toolchain: 1.85.0
|
||||
toolchain: ${{ env.RUST_VERSION }}
|
||||
|
||||
- uses: Swatinem/rust-cache@v2
|
||||
|
||||
@@ -80,10 +81,10 @@ jobs:
|
||||
- name: Checkout sources
|
||||
uses: actions/checkout@v5.0.0
|
||||
|
||||
- name: Install Rust 1.85.0
|
||||
- name: Install Rust ${{ env.RUST_VERSION }}
|
||||
uses: dtolnay/rust-toolchain@stable
|
||||
with:
|
||||
toolchain: 1.85.0
|
||||
toolchain: ${{ env.RUST_VERSION }}
|
||||
|
||||
- uses: Swatinem/rust-cache@v2
|
||||
|
||||
@@ -104,11 +105,11 @@ jobs:
|
||||
- name: Checkout sources
|
||||
uses: actions/checkout@v5.0.0
|
||||
|
||||
- name: Install Rust 1.85.0 and nightly
|
||||
- name: Install Rust ${{ env.RUST_VERSION }} and nightly
|
||||
run: |
|
||||
rustup toolchain install 1.85.0 --component llvm-tools-preview
|
||||
rustup toolchain install ${{ env.RUST_VERSION }} --component llvm-tools-preview
|
||||
rustup toolchain install nightly --component llvm-tools-preview
|
||||
rustup default 1.85.0
|
||||
rustup default ${{ env.RUST_VERSION }}
|
||||
|
||||
- uses: taiki-e/install-action@cargo-llvm-cov
|
||||
|
||||
|
||||
Reference in New Issue
Block a user