Open jtracey opened 2 years ago
Can you show me your lsp-mode config please.
Can you try if it works when you add the config options to lsp-rust-analyzer-cargo-watch-args
. But you're right it should pick up the config automatically.
I would consider using the cargo lints
package instead. https://lib.rs/crates/cargo-lints, it's supported by Rustic, and much more convenient.
Additionally, the reason which causes a rebuild could be either one of the build.rs scripts.
In fact, judging by how many scripts require you to ignore the build.rs
I'd imagine that it's a little buggy and triggers a re-compilation when the dependencies haven't really changed.
Update: cargo-lints
is no longer maintained. The original workaround is not suitable anymore.
I'm not sure if this is a bug in rustic, rust-analyzer, or lsp, and I haven't been very successful in tracking down what's going on, so feel free to point me elsewhere. When I open a file in the coreutils project, clippy is run as the linter. If I then run clippy from the command line, it treats it as a clean rebuild, and vice versa. It seems like the problem is the additional clippy flags in .cargo/config, like the cache is invalidated because they aren't being applied when run via rustic.