diff options
Diffstat (limited to 'cli/lsp/lsp_custom.rs')
-rw-r--r-- | cli/lsp/lsp_custom.rs | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/cli/lsp/lsp_custom.rs b/cli/lsp/lsp_custom.rs index 685da6b14..96f7be790 100644 --- a/cli/lsp/lsp_custom.rs +++ b/cli/lsp/lsp_custom.rs @@ -91,6 +91,27 @@ impl lsp::notification::Notification const METHOD: &'static str = "deno/didChangeDenoConfiguration"; } +pub enum DidUpgradeCheckNotification {} + +impl lsp::notification::Notification for DidUpgradeCheckNotification { + type Params = DidUpgradeCheckNotificationParams; + + const METHOD: &'static str = "deno/didUpgradeCheck"; +} + +#[derive(Debug, Deserialize, Serialize)] +#[serde(rename_all = "camelCase")] +pub struct UpgradeAvailable { + pub latest_version: String, + pub is_canary: bool, +} + +#[derive(Debug, Deserialize, Serialize)] +#[serde(rename_all = "camelCase")] +pub struct DidUpgradeCheckNotificationParams { + pub upgrade_available: Option<UpgradeAvailable>, +} + /// This notification is only sent for testing purposes /// in order to know what the latest diagnostics are. pub enum DiagnosticBatchNotification {} |