Stream: t-compiler/rust-analyzer

Topic: rls_vscode_extension


alcroito (Feb 23 2021 at 12:55, on Zulip):

Hi. Not sure if this is the right channel, but here goes. I added some new config fields to rust analyzer config.rs, and would like to test them / set them using VSCode. Are there some docs on how to build the RLS vscode extension and load it into vscode? I didn't seem to find any in the RLS dev docs.

Laurențiu (Feb 23 2021 at 12:56, on Zulip):

Yes, but first, which extension are you using?

alcroito (Feb 23 2021 at 12:56, on Zulip):

rust-analyzer. i assume the one in src/editors/code

Laurențiu (Feb 23 2021 at 12:56, on Zulip):

https://github.com/rust-analyzer/rust-analyzer/blob/master/docs/dev/debugging.md

Laurențiu (Feb 23 2021 at 12:57, on Zulip):

I usually just cargo xtask install --client and skip the debugger

alcroito (Feb 23 2021 at 12:58, on Zulip):

Running cargo xtask --install client-code doesn't seem to do much, it only shows the xtask subcommands

Jonas Schievink [he/him] (Feb 23 2021 at 12:58, on Zulip):

without the --

alcroito (Feb 23 2021 at 12:58, on Zulip):

Error: Unused arguments. :)

Laurențiu (Feb 23 2021 at 12:58, on Zulip):

Ugh, sorry

Jonas Schievink [he/him] (Feb 23 2021 at 12:59, on Zulip):

cargo xtask install --client

Laurențiu (Feb 23 2021 at 12:59, on Zulip):

Shows I don't run that often enough :)

alcroito (Feb 23 2021 at 13:00, on Zulip):

Extension 'rust-analyzer.vsix' was successfully installed.
Does that mean that the extension is already installed into the vscode instance i usually use?

Laurențiu (Feb 23 2021 at 13:00, on Zulip):

Yup

alcroito (Feb 23 2021 at 13:02, on Zulip):

Nice, restarting vscode shows the new options. And of course, knowing the magical command now, i found 'cargo xtask install --client' referenced in the 'Launching rust-analyzer' section of the dev docs. I guess Having a more stand-out section just for that might be useful, for those of use who don't usually develop vscode extensions.

alcroito (Feb 23 2021 at 13:02, on Zulip):

Thank you!

Last update: Jul 27 2021 at 20:45UTC