feat(rust): exclude bad directories from rust-analyzer (#5021)

## Description

rust-analyzer is unfortunately not smart enough to use a folder's
.gitignore (or similar) when looking for rust files to analyze, meaning
that when it finds a large enough folder (e.g: .git, .direnv) it
completely dies going through it searching for rust files.

This commit adds a filter of common folders that are big enough to
potentially choke rust-analyzer. The list could be amended in the
future.

## Checklist

- [X] I've read the
[CONTRIBUTING](https://github.com/LazyVim/LazyVim/blob/main/CONTRIBUTING.md)
guidelines.
This commit is contained in:
iniw 2024-12-13 03:28:09 -03:00 committed by GitHub
parent 29c4dea4e7
commit 94f6df048f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -92,6 +92,19 @@ return {
["async-recursion"] = { "async_recursion" },
},
},
files = {
excludeDirs = {
".direnv",
".git",
".github",
".gitlab",
"bin",
"node_modules",
"target",
"venv",
".venv",
},
},
},
},
},