|
1 | 1 | use lsp_types::{ |
2 | 2 | ClientCapabilities, CompletionOptions, DeclarationCapability, DiagnosticOptions, |
3 | 3 | DiagnosticServerCapabilities, HoverProviderCapability, InlayHintOptions, |
4 | | - InlayHintServerCapabilities, MarkupKind, OneOf, RenameOptions, |
5 | | - SelectionRangeProviderCapability, SemanticTokensFullOptions, SemanticTokensLegend, |
6 | | - SemanticTokensOptions, SemanticTokensServerCapabilities, ServerCapabilities, |
7 | | - SignatureHelpOptions, TextDocumentSyncCapability, TextDocumentSyncKind, |
| 4 | + InlayHintServerCapabilities, MarkupKind, NotebookCellSelector, NotebookSelector, OneOf, |
| 5 | + RenameOptions, SelectionRangeProviderCapability, SemanticTokensFullOptions, |
| 6 | + SemanticTokensLegend, SemanticTokensOptions, SemanticTokensServerCapabilities, |
| 7 | + ServerCapabilities, SignatureHelpOptions, TextDocumentSyncCapability, TextDocumentSyncKind, |
8 | 8 | TextDocumentSyncOptions, TypeDefinitionProviderCapability, WorkDoneProgressOptions, |
9 | 9 | }; |
10 | 10 |
|
@@ -407,6 +407,16 @@ pub(crate) fn server_capabilities( |
407 | 407 | selection_range_provider: Some(SelectionRangeProviderCapability::Simple(true)), |
408 | 408 | document_symbol_provider: Some(OneOf::Left(true)), |
409 | 409 | workspace_symbol_provider: Some(OneOf::Left(true)), |
| 410 | + notebook_document_sync: Some(OneOf::Left(lsp_types::NotebookDocumentSyncOptions { |
| 411 | + save: Some(false), |
| 412 | + notebook_selector: [NotebookSelector::ByCells { |
| 413 | + notebook: None, |
| 414 | + cells: vec![NotebookCellSelector { |
| 415 | + language: "python".to_string(), |
| 416 | + }], |
| 417 | + }] |
| 418 | + .to_vec(), |
| 419 | + })), |
410 | 420 | ..Default::default() |
411 | 421 | } |
412 | 422 | } |
|
0 commit comments