Stream: t-compiler/rust-analyzer

Topic: Adding roots to a Vfs

Tadeo Kondrak (Apr 02 2020 at 15:30, on Zulip):

Is it intentional that new roots can't be added to a ra_vfs::Vfs after creation? I'm playing around with possibly writing a Kakoune "plugin" for rust-analyzer, where there would only be one server for multiple projects, so adding roots to an existing Vfs could be useful. It's possible I'm just missing something obvious, since I haven't learned much about how all of rust-analyzer fits together.

matklad (Apr 02 2020 at 15:32, on Zulip):

matklad (Apr 02 2020 at 15:32, on Zulip):

srry for short reply, doing other stufff rn

Tadeo Kondrak (Apr 02 2020 at 15:36, on Zulip):

Thanks, I'll probably just find the root manually and create a Vfs individually for each project to start then.

std::Veetaha (Apr 02 2020 at 15:46, on Zulip):

Are you talking about using a single server process for multiple disconnected project folders? I know at least one blocker for implementing this. We cannot share the cargo check watcher between them right now...

Tadeo Kondrak (Apr 02 2020 at 15:52, on Zulip):

It's the same process, but they don't actually have to share any analysis state between projects. I was trying to share the Vfs since it was relatively low-level, but there's no actual need to, I think.

Last update: Jul 28 2021 at 04:00UTC