Stream: t-compiler/rust-analyzer

Topic: setting r-a options in lsp-mode


Jake Goulding (Jan 04 2021 at 15:07, on Zulip):

How can I set arbitrary options in lsp-mode? I'd like to set:

    "rust-analyzer.cargo.loadOutDirsFromCheck": true,
    "rust-analyzer.procMacro.enable": true,

I've skimmed through lsp-rust but nothing jumped out at me.

Florian Diebold (Jan 04 2021 at 15:18, on Zulip):

there are customization variables for most RA settings, e.g. lsp-rust-analyzer-cargo-load-out-dirs-from-check and lsp-rust-analyzer-proc-macro-enable. (there might be a few settings missing, which would need to be added in lsp-mode to be able to set them)

Jake Goulding (Jan 04 2021 at 15:21, on Zulip):

Heh, I didn't expect there to be specific options already in the code.

Jake Goulding (Jan 04 2021 at 15:21, on Zulip):

I was looking for a dump-all place

matklad (Jan 04 2021 at 16:02, on Zulip):

I'd say it is an lsp-mode bug if it doesn't allow free-form options. Also, rust-analyzer --print-config-schema now exists.

Last update: Jul 28 2021 at 03:30UTC