Skip to content

Commit 2f0878d

Browse files
committed
Revert remote scheme change
It doesn't show in the explorer anymore so there's no point. Also remove the local scheme transform which is no longer required with the latest client-side extension implementation.
1 parent f65c9b2 commit 2f0878d

File tree

2 files changed

+5
-19
lines changed

2 files changed

+5
-19
lines changed

scripts/vscode.patch

+2-13
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,8 @@
11
diff --git a/src/vs/base/common/network.ts b/src/vs/base/common/network.ts
2-
index 6d41e85e42..f845d0bf9e 100644
2+
index 6d41e85e42..64f39687a4 100644
33
--- a/src/vs/base/common/network.ts
44
+++ b/src/vs/base/common/network.ts
5-
@@ -48,7 +48,9 @@ export namespace Schemas {
6-
7-
export const command: string = 'command';
8-
9-
- export const vscodeRemote: string = 'vscode-remote';
10-
+ // NOTE@coder: Changed this so it'll be reflected in the explorer to prevent
11-
+ // confusion with vscode-remote itself.
12-
+ export const vscodeRemote: string = 'code-server';
13-
14-
export const vscodeRemoteResource: string = 'vscode-remote-resource';
15-
16-
@@ -96,12 +98,12 @@ class RemoteAuthoritiesImpl {
5+
@@ -96,12 +96,12 @@ class RemoteAuthoritiesImpl {
176
if (host && host.indexOf(':') !== -1) {
187
host = `[${host}]`;
198
}

src/node/uriTransformer.js

+3-6
Original file line numberDiff line numberDiff line change
@@ -4,22 +4,19 @@ module.exports = (remoteAuthority) => {
44
return {
55
transformIncoming: (uri) => {
66
switch (uri.scheme) {
7-
case "code-server": return { scheme: "file", path: uri.path };
8-
case "file": return { scheme: "code-server", path: uri.path };
7+
case "vscode-remote": return { scheme: "file", path: uri.path };
98
default: return uri;
109
}
1110
},
1211
transformOutgoing: (uri) => {
1312
switch (uri.scheme) {
14-
case "code-server": return { scheme: "file", path: uri.path };
15-
case "file": return { scheme: "code-server", authority: remoteAuthority, path: uri.path };
13+
case "file": return { scheme: "vscode-remote", authority: remoteAuthority, path: uri.path };
1614
default: return uri;
1715
}
1816
},
1917
transformOutgoingScheme: (scheme) => {
2018
switch (scheme) {
21-
case "code-server": return "file";
22-
case "file": return "code-server";
19+
case "file": return "vscode-local";
2320
default: return scheme;
2421
}
2522
},

0 commit comments

Comments
 (0)