mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-03-31 01:00:29 -04:00
Merge from vscode b12f623603e2fc1c5b3037115fa37c1a6acc4165 (#6760)
This commit is contained in:
@@ -993,10 +993,10 @@ export class ClearSelectionTerminalAction extends Action {
|
||||
}
|
||||
}
|
||||
|
||||
export class AllowWorkspaceShellTerminalCommand extends Action {
|
||||
export class ManageWorkspaceShellPermissionsTerminalCommand extends Action {
|
||||
|
||||
public static readonly ID = TERMINAL_COMMAND_ID.WORKSPACE_SHELL_ALLOW;
|
||||
public static readonly LABEL = nls.localize('workbench.action.terminal.allowWorkspaceShell', "Allow Workspace Shell Configuration");
|
||||
public static readonly ID = TERMINAL_COMMAND_ID.MANAGE_WORKSPACE_SHELL_PERMISSIONS;
|
||||
public static readonly LABEL = nls.localize('workbench.action.terminal.manageWorkspaceShellPermissions', "Manage Workspace Shell Permissions");
|
||||
|
||||
constructor(
|
||||
id: string, label: string,
|
||||
@@ -1005,27 +1005,8 @@ export class AllowWorkspaceShellTerminalCommand extends Action {
|
||||
super(id, label);
|
||||
}
|
||||
|
||||
public run(event?: any): Promise<any> {
|
||||
this.terminalService.setWorkspaceShellAllowed(true);
|
||||
return Promise.resolve(undefined);
|
||||
}
|
||||
}
|
||||
|
||||
export class DisallowWorkspaceShellTerminalCommand extends Action {
|
||||
|
||||
public static readonly ID = TERMINAL_COMMAND_ID.WORKSPACE_SHELL_DISALLOW;
|
||||
public static readonly LABEL = nls.localize('workbench.action.terminal.disallowWorkspaceShell', "Disallow Workspace Shell Configuration");
|
||||
|
||||
constructor(
|
||||
id: string, label: string,
|
||||
@ITerminalService private readonly terminalService: ITerminalService
|
||||
) {
|
||||
super(id, label);
|
||||
}
|
||||
|
||||
public run(event?: any): Promise<any> {
|
||||
this.terminalService.setWorkspaceShellAllowed(false);
|
||||
return Promise.resolve(undefined);
|
||||
public async run(event?: any): Promise<any> {
|
||||
await this.terminalService.manageWorkspaceShellPermissions();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user