Skip to content

Commit 2f7cd44

Browse files
committed
Don't revive URI before sending from ext to main
Fixes microsoft#235331
1 parent 086501e commit 2f7cd44

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

extensions/terminal-suggest/src/terminalSuggestMain.ts

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -148,13 +148,13 @@ export async function activate(context: vscode.ExtensionContext) {
148148
}
149149

150150
if (terminal.shellIntegration?.cwd && (result.filesRequested || result.foldersRequested)) {
151-
let cwd;
152-
if (vscode.env.remoteName) {
153-
cwd = vscode.Uri.file((result.cwd ?? terminal.shellIntegration.cwd).path).with({ authority: vscode.env.remoteName, scheme: 'vscode-remote' });
154-
} else {
155-
cwd = vscode.Uri.file((result.cwd ?? terminal.shellIntegration.cwd).fsPath);
156-
}
157-
return new vscode.TerminalCompletionList(result.items, { filesRequested: result.filesRequested, foldersRequested: result.foldersRequested, fileExtensions: result.fileExtensions, cwd, env: terminal.shellIntegration?.env?.value, });
151+
return new vscode.TerminalCompletionList(result.items, {
152+
filesRequested: result.filesRequested,
153+
foldersRequested: result.foldersRequested,
154+
fileExtensions: result.fileExtensions,
155+
cwd: result.cwd ?? terminal.shellIntegration.cwd,
156+
env: terminal.shellIntegration?.env?.value,
157+
});
158158
}
159159
return result.items;
160160
}

src/vs/workbench/api/common/extHostTypeConverters.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3205,7 +3205,7 @@ export namespace TerminalResourceRequestConfig {
32053205
return {
32063206
...resourceRequestConfig,
32073207
pathSeparator,
3208-
cwd: resourceRequestConfig.cwd ? URI.revive(resourceRequestConfig.cwd) : undefined,
3208+
cwd: resourceRequestConfig.cwd,
32093209
};
32103210
}
32113211
}

0 commit comments

Comments
 (0)