about summary refs log tree commit diff
path: root/src/etc/rust_analyzer_eglot.el
diff options
context:
space:
mode:
authorStuart Cook <Zalathar@users.noreply.github.com>2025-10-03 09:16:26 +1000
committerGitHub <noreply@github.com>2025-10-03 09:16:26 +1000
commita3291ede1a28a79c37c296bd021939751f69969a (patch)
tree5f18ea3924e586518e7494132cef7828b57f48d7 /src/etc/rust_analyzer_eglot.el
parent5c7ae0c7ed184c603e5224604a9f33ca0e8e0b36 (diff)
parent24144ff499852b0fab63cf0c93d4c8d8b2fad8ef (diff)
downloadrust-a3291ede1a28a79c37c296bd021939751f69969a.tar.gz
rust-a3291ede1a28a79c37c296bd021939751f69969a.zip
Rollup merge of #141839 - tshepang:ease-lsp-use, r=Mark-Simulacrum,fee1-dead
make rust-analyzer use a dedicated build directory

inspired by https://github.com/rust-lang/rust/pull/132794
Diffstat (limited to 'src/etc/rust_analyzer_eglot.el')
-rw-r--r--src/etc/rust_analyzer_eglot.el8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/etc/rust_analyzer_eglot.el b/src/etc/rust_analyzer_eglot.el
index 3151cb1a6e7..e5abf67235a 100644
--- a/src/etc/rust_analyzer_eglot.el
+++ b/src/etc/rust_analyzer_eglot.el
@@ -6,6 +6,8 @@
                                        :overrideCommand ["python3"
                                                          "x.py"
                                                          "check"
+                                                         "--build-dir"
+                                                         "build-rust-analyzer"
                                                          "--json-output"])
                  :linkedProjects ["Cargo.toml"
                                   "compiler/rustc_codegen_cranelift/Cargo.toml"
@@ -13,9 +15,9 @@
                                   "library/Cargo.toml"
                                   "src/bootstrap/Cargo.toml"
                                   "src/tools/rust-analyzer/Cargo.toml"]
-                 :rustfmt ( :overrideCommand ["build/host/rustfmt/bin/rustfmt"
+                 :rustfmt ( :overrideCommand ["build-rust-analyzer/host/rustfmt/bin/rustfmt"
                                               "--edition=2024"])
-                 :procMacro ( :server "build/host/stage0/libexec/rust-analyzer-proc-macro-srv"
+                 :procMacro ( :server "build-rust-analyzer/host/stage0/libexec/rust-analyzer-proc-macro-srv"
                                       :enable t)
                  :cargo ( :buildScripts ( :enable t
                                                   :invocationLocation "root"
@@ -23,6 +25,8 @@
                                                   :overrideCommand ["python3"
                                                                     "x.py"
                                                                     "check"
+                                                                    "--build-dir"
+                                                                    "build-rust-analyzer"
                                                                     "--json-output"
                                                                     "--compile-time-deps"])]
                                         :sysrootSrc "./library"