diff --git a/package.json b/package.json index 0a8af56..0dfe899 100644 --- a/package.json +++ b/package.json @@ -55,6 +55,11 @@ "title": "Connect to Instance", "icon": "$(remote)" }, + { + "command": "powershell-universal.reconnect", + "title": "Reconnect to Instance", + "icon": "$(refresh)" + }, { "command": "powershell-universal.reloadConfig", "title": "Reload Configuration", @@ -455,6 +460,11 @@ "when": "view == universalConnectionProviderView && viewItem == connection", "group": "inline" }, + { + "command": "powershell-universal.reconnect", + "when": "view == universalConnectionProviderView && viewItem == connection-connected", + "group": "inline" + }, { "command": "powershell-universal.viewDashboard", "when": "view == universalDashboardProviderView && viewItem == dashboard", diff --git a/src/commands/connect.ts b/src/commands/connect.ts index 16f2a85..8f8084d 100644 --- a/src/commands/connect.ts +++ b/src/commands/connect.ts @@ -6,6 +6,7 @@ import { load } from '../settings'; export const registerConnectCommands = (context: vscode.ExtensionContext) => { vscode.commands.registerCommand('powershell-universal.addConnection', AddConnection); vscode.commands.registerCommand('powershell-universal.connection', x => Connection(x, context)); + vscode.commands.registerCommand('powershell-universal.reconnect', x => Connection(x, context)); } export const AddConnection = async (context: vscode.ExtensionContext) => {