mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-10-02 06:41:48 +00:00
allow to exclude certain files and directories
This commit is contained in:
parent
058c2daba1
commit
deea8f52d9
7 changed files with 43 additions and 15 deletions
|
@ -1,7 +1,7 @@
|
|||
use serde::{Deserialize, Deserializer};
|
||||
|
||||
/// Client provided initialization options
|
||||
#[derive(Deserialize, Clone, Copy, Debug, PartialEq, Eq)]
|
||||
#[derive(Deserialize, Clone, Debug, PartialEq, Eq)]
|
||||
#[serde(rename_all = "camelCase", default)]
|
||||
pub struct ServerConfig {
|
||||
/// Whether the client supports our custom highlighting publishing decorations.
|
||||
|
@ -18,12 +18,19 @@ pub struct ServerConfig {
|
|||
#[serde(deserialize_with = "nullable_bool_true")]
|
||||
pub show_workspace_loaded: bool,
|
||||
|
||||
pub exclude_globs: Vec<String>,
|
||||
|
||||
pub lru_capacity: Option<usize>,
|
||||
}
|
||||
|
||||
impl Default for ServerConfig {
|
||||
fn default() -> ServerConfig {
|
||||
ServerConfig { publish_decorations: false, show_workspace_loaded: true, lru_capacity: None }
|
||||
ServerConfig {
|
||||
publish_decorations: false,
|
||||
show_workspace_loaded: true,
|
||||
exclude_globs: Vec::new(),
|
||||
lru_capacity: None,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue