From 222c86dbcbb97667ed7788d1ed76c354e9319a1c Mon Sep 17 00:00:00 2001 From: Tiago Castro Date: Thu, 21 Nov 2024 14:57:16 +0000 Subject: [PATCH] build: use rust stable for linting Nightly is no longer required since latest update, so we can remove its requirement and thus simplify the devel rather than require using both stable and nightly compiler. This should also reduce the target/debug size as there'll be only builds from one compiler. Signed-off-by: Tiago Castro --- nix/shell/rust.nix | 2 +- scripts/rust-linter-env.sh | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/nix/shell/rust.nix b/nix/shell/rust.nix index 6852b0f..0cb55b4 100644 --- a/nix/shell/rust.nix +++ b/nix/shell/rust.nix @@ -19,7 +19,7 @@ let shellEnv = { # Path to nightly Rust, needed for linter and style. - RUST_NIGHTLY_PATH = rustChannels.nightly; + # RUST_NIGHTLY_PATH = rustChannels.nightly; # Path to debug output dir. RUST_TARGET_DEBUG = "target/debug"; diff --git a/scripts/rust-linter-env.sh b/scripts/rust-linter-env.sh index a3c9624..85969bd 100644 --- a/scripts/rust-linter-env.sh +++ b/scripts/rust-linter-env.sh @@ -46,10 +46,10 @@ fi # rustfmt and clippy "2021-11-29". # When upgrading Rust toolchain version, check 'cargo --version', # 'cargo fmt --version', 'cargo clippy --version' and put them here. -RUST_TOOLCHAIN_VER="2024-10-30" -WANTED_CARGO_VER="cargo 1.84.0-nightly (* 2024-10-25)" -WANTED_RUSTFMT_VER="rustfmt 1.8.0-nightly (* 2024-10-29)" -WANTED_CLIPPY_VER="clippy 0.1.84 (* 2024-10-29)" +RUST_TOOLCHAIN_VER=${RUST_TOOLCHAIN_VER:-"1.82.0"} +WANTED_CARGO_VER=${WANTED_CARGO_VER:-"cargo 1.82.0 (* 2024-08-21)"} +WANTED_RUSTFMT_VER=${WANTED_RUSTFMT_VER:-"rustfmt 1.7.1-stable (* 2024-10-15)"} +WANTED_CLIPPY_VER=${WANTED_CLIPPY_VER:-"clippy 0.1.82 (* 2024-10-15)"} CARGO="cargo" CARGO_MODE="system"