Skip to content

Commit b867db5

Browse files
authored
[debug-certificate-mangaer] remove shell integration timeout and make make activation event more specific (#5322)
1 parent 6a6dfc5 commit b867db5

2 files changed

Lines changed: 3 additions & 11 deletions

File tree

vscode-extensions/debug-certificate-manager-vscode-extension/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "debug-certificate-manager",
3-
"version": "0.0.2",
3+
"version": "0.0.3",
44
"repository": {
55
"type": "git",
66
"url": "https://github.com/microsoft/rushstack.git",
@@ -107,7 +107,7 @@
107107
},
108108
"enabledApiProposals": [],
109109
"activationEvents": [
110-
"workspaceContains:.vscode/debug-certificate-manager.json"
110+
"workspaceContains:/.vscode/debug-certificate-manager.json"
111111
],
112112
"dependencies": {
113113
"@rushstack/debug-certificate-manager": "workspace:*",

vscode-extensions/debug-certificate-manager-vscode-extension/src/terminal.ts

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -20,24 +20,16 @@ export async function runWorkspaceCommandAsync({
2020
const shellIntegration: vscode.TerminalShellIntegration =
2121
vsTerminal.shellIntegration ??
2222
(await new Promise((resolve, reject) => {
23-
let timeoutId: NodeJS.Timeout | undefined;
2423
const shellIntegrationDisposable: vscode.Disposable = vscode.window.onDidChangeTerminalShellIntegration(
2524
(event) => {
2625
if (event.terminal !== vsTerminal) {
2726
return;
2827
}
29-
if (timeoutId) {
30-
clearTimeout(timeoutId);
31-
timeoutId = undefined;
32-
}
28+
3329
resolve(event.shellIntegration);
3430
shellIntegrationDisposable?.dispose();
3531
}
3632
);
37-
timeoutId = setTimeout(() => {
38-
shellIntegrationDisposable?.dispose();
39-
reject(new Error('Shell integration timeout'));
40-
}, 5000);
4133
}));
4234

4335
// Run the command through shell integration and grab output

0 commit comments

Comments
 (0)