Skip to content

Commit 4df13e9

Browse files
committed
Adjust scheme and authority of URIs in remote terminals
Fixes microsoft#208572
1 parent 960217f commit 4df13e9

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

src/vs/workbench/contrib/terminalContrib/links/browser/terminalLinkResolver.ts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,14 @@ export class TerminalLinkResolver implements ITerminalLinkResolver {
2525
}
2626

2727
async resolveLink(processManager: Pick<ITerminalProcessManager, 'initialCwd' | 'os' | 'remoteAuthority' | 'userHome'> & { backend?: Pick<ITerminalBackend, 'getWslPath'> }, link: string, uri?: URI): Promise<ResolvedLink> {
28+
// Correct scheme and authority for remote terminals
29+
if (uri && processManager.remoteAuthority) {
30+
uri = uri.with({
31+
scheme: Schemas.vscodeRemote,
32+
authority: processManager.remoteAuthority
33+
});
34+
}
35+
2836
// Get the link cache
2937
let cache = this._resolvedLinkCaches.get(processManager.remoteAuthority ?? '');
3038
if (!cache) {

0 commit comments

Comments
 (0)