diff options
author | ShuiRuTian <[email protected]> | 2021-01-08 09:49:13 +0000 |
---|---|---|
committer | ShuiRuTian <[email protected]> | 2021-01-08 09:49:13 +0000 |
commit | c08391ce32c471d09fcc6fe48bd295bbb5a7de10 (patch) | |
tree | 07f9b00291c7b15e26e950f295814cf5a20d4739 /crates | |
parent | 5c2b0e0835cd727ec84e1a3b11bd4c2004fc0f72 (diff) |
support folder rename for initial request.
Diffstat (limited to 'crates')
-rw-r--r-- | crates/rust-analyzer/src/caps.rs | 24 |
1 files changed, 16 insertions, 8 deletions
diff --git a/crates/rust-analyzer/src/caps.rs b/crates/rust-analyzer/src/caps.rs index 80e46bf7f..5167a005f 100644 --- a/crates/rust-analyzer/src/caps.rs +++ b/crates/rust-analyzer/src/caps.rs | |||
@@ -77,14 +77,22 @@ pub fn server_capabilities(client_caps: &ClientCapabilities) -> ServerCapabiliti | |||
77 | will_create: None, | 77 | will_create: None, |
78 | did_rename: None, | 78 | did_rename: None, |
79 | will_rename: Some(FileOperationRegistrationOptions { | 79 | will_rename: Some(FileOperationRegistrationOptions { |
80 | filters: vec![FileOperationFilter { | 80 | filters: vec![ |
81 | scheme: Some(String::from("file")), | 81 | FileOperationFilter { |
82 | pattern: FileOperationPattern { | 82 | scheme: Some(String::from("file")), |
83 | glob: String::from("**/*.rs"), | 83 | pattern: FileOperationPattern { |
84 | matches: Some(FileOperationPatternKind::File), | 84 | glob: String::from("**/*.rs"), |
85 | options: None, | 85 | matches: Some(FileOperationPatternKind::File), |
86 | }, | 86 | options: None, |
87 | }], | 87 | }, |
88 | FileOperationFilter { | ||
89 | scheme: Some(String::from("untitled")), | ||
90 | pattern: FileOperationPattern { | ||
91 | glob: String::from("**"), | ||
92 | matches: Some(FileOperationPatternKind::Folder), | ||
93 | options: None, | ||
94 | }, | ||
95 | }], | ||
88 | }), | 96 | }), |
89 | did_delete: None, | 97 | did_delete: None, |
90 | will_delete: None, | 98 | will_delete: None, |