Skip to content

Commit 94ed0bb

Browse files
liskinNeoScript
andauthored
fix(rust): remove rls and rust-analysis for Rust 1.87+ compatibility (#1362)
* fix(rust): remove rls and rust-analysis for Rust 1.87+ compatibility Rust 1.87.0 and later have removed the long-deprecated RLS and rust-analysis components. This change updates the install script to only add rust-src, rustfmt, and clippy, preventing build errors during feature installation. See: rust-lang/rust#126856 https://blog.rust-lang.org/2022/07/01/RLS-deprecation/ https://github.com/rust-lang/rustup/blob/a92432fc8b6d5d4e56ebd08ca1c45b7b1294c1bd/doc/user-guide/src/concepts/components.md#previous-components Fixes: #1361 * Drop support for older rust version that do not have rust-analyzer * Add rust-analyzer as replacement for rls * Update devcontainer-feature version number * Add proposed version options * test(rust): Bump pinned rust version to one incl rust-analyzer --------- Co-authored-by: neoscript <[email protected]>
1 parent 4f8a62a commit 94ed0bb

File tree

4 files changed

+13
-8
lines changed

4 files changed

+13
-8
lines changed

src/rust/devcontainer-feature.json

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"id": "rust",
3-
"version": "1.3.2",
3+
"version": "1.3.3",
44
"name": "Rust",
55
"documentationURL": "https://github.com/devcontainers/features/tree/main/src/rust",
66
"description": "Installs Rust, common Rust utilities, and their required dependencies",
@@ -10,6 +10,14 @@
1010
"proposals": [
1111
"latest",
1212
"none",
13+
"1.87",
14+
"1.86",
15+
"1.85",
16+
"1.84",
17+
"1.83",
18+
"1.82",
19+
"1.81",
20+
"1.80",
1321
"1.79",
1422
"1.78",
1523
"1.77",
@@ -25,10 +33,7 @@
2533
"1.67",
2634
"1.66",
2735
"1.65",
28-
"1.64",
29-
"1.63",
30-
"1.62",
31-
"1.61"
36+
"1.64"
3237
],
3338
"default": "latest",
3439
"description": "Select or enter a version of Rust to install."

src/rust/install.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -203,7 +203,7 @@ if [ "${UPDATE_RUST}" = "true" ]; then
203203
rustup update 2>&1
204204
fi
205205
echo "Installing common Rust dependencies..."
206-
rustup component add rls rust-analysis rust-src rustfmt clippy 2>&1
206+
rustup component add rust-analyzer rust-src rustfmt clippy 2>&1
207207

208208
if [ -n "${RUSTUP_TARGETS}" ]; then
209209
IFS=',' read -ra targets <<< "${RUSTUP_TARGETS}"

test/rust/rust_at_pinned_version.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ source dev-container-features-test-lib
88
# Definition specific tests
99
check "cargo version" cargo --version
1010
check "rustc version" rustc --version
11-
check "correct rust version" rustc --version | grep 1.62.0
11+
check "correct rust version" rustc --version | grep 1.64.0
1212

1313

1414
# Report result

test/rust/scenarios.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"image": "ubuntu:focal",
44
"features": {
55
"rust": {
6-
"version": "1.62.0"
6+
"version": "1.64.0"
77
}
88
}
99
},

0 commit comments

Comments
 (0)