Truly independent web browser
Meta+CI: Run the Rust GC lints in lint-ci.sh
Shannon Booth4a87f486d388
diff --git a/.github/workflows/lint-code.yml b/.github/workflows/lint-code.ymlindex f4bca476495..2826aa3e340 100644--- a/.github/workflows/lint-code.yml+++ b/.github/workflows/lint-code.yml@@ -22,6 +22,10 @@ jobs:arch: 'x86_64'type: 'lint'+ - name: Install the toolchain of the Rust GC lints+ working-directory: Meta/RustLints+ run: rustup toolchain install+- name: Lintrun: "${GITHUB_WORKSPACE}/Meta/lint-ci.sh"diff --git a/Meta/RustLints/rust-toolchain.toml b/Meta/RustLints/rust-toolchain.tomlindex 56756b9a4eb..bddf9a60548 100644--- a/Meta/RustLints/rust-toolchain.toml+++ b/Meta/RustLints/rust-toolchain.toml@@ -2,4 +2,5 @@# The nightly that matches the workspace's stable toolchain (1.98) most closely. The driver links its compiler, so# rustc-dev must match it exactly.channel = "nightly-2026-06-22"+profile = "minimal"components = ["rustc-dev", "llvm-tools", "rust-src"]diff --git a/Meta/lint-ci.sh b/Meta/lint-ci.shindex 3862137f197..bce18e97325 100755--- a/Meta/lint-ci.sh+++ b/Meta/lint-ci.sh@@ -86,6 +86,22 @@ if (( should_lint_rust )); thenecho -e "[${BOLD_RED}FAIL${NC}]: cargo clippy -- -D clippy::all"((FAILURES+=1))fi++ # The GC lints link the compiler of a pinned nightly, which only some setups have.+ rust_lints_toolchain=$(sed -n 's/^channel = "\(.*\)"$/\1/p' Meta/RustLints/rust-toolchain.toml)+ if rustup component list --toolchain "${rust_lints_toolchain}" --installed 2>/dev/null | grep -q '^rustc-dev'; then+ rust_lints_target_dir="${script_path}/../Build/rust-lints"+ if CARGO_TARGET_DIR="${rust_lints_target_dir}" cargo +"${rust_lints_toolchain}" test --quiet \+ --manifest-path Meta/RustLints/Cargo.toml \+ && CARGO_TARGET_DIR="${rust_lints_target_dir}" Meta/RustLints/run.sh --quiet ; then+ echo -e "[${GREEN}OK${NC}]: Meta/RustLints/run.sh"+ else+ echo -e "[${BOLD_RED}FAIL${NC}]: Meta/RustLints/run.sh"+ ((FAILURES+=1))+ fi+ else+ echo "Skipping Meta/RustLints/run.sh: ${rust_lints_toolchain} with rustc-dev is not installed."+ fielseecho "No Rust files to check."fi