()
| 698 | } |
| 699 | |
| 700 | private registerCommands(): void { |
| 701 | this.registeredCommands = [ |
| 702 | vscode.commands.registerCommand( |
| 703 | "PowerShell.RestartSession", |
| 704 | async () => { |
| 705 | await this.restartSession(); |
| 706 | }, |
| 707 | ), |
| 708 | vscode.commands.registerCommand( |
| 709 | this.ShowSessionMenuCommandName, |
| 710 | async () => { |
| 711 | await this.showSessionMenu(); |
| 712 | }, |
| 713 | ), |
| 714 | vscode.workspace.onDidChangeConfiguration((e) => |
| 715 | this.restartOnCriticalConfigChange(e), |
| 716 | ), |
| 717 | vscode.commands.registerCommand( |
| 718 | "PowerShell.ShowSessionConsole", |
| 719 | (isExecute?: boolean) => { |
| 720 | this.showSessionTerminal(isExecute); |
| 721 | }, |
| 722 | ), |
| 723 | ]; |
| 724 | } |
| 725 | |
| 726 | private async findPowerShell( |
| 727 | wantedName?: string, |
no test coverage detected