@theia/remote 1.56.0 → 1.57.0-next.112
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/lib/electron-browser/local-backend-services.d.ts +11 -0
- package/lib/electron-browser/local-backend-services.d.ts.map +1 -0
- package/lib/electron-browser/local-backend-services.js +37 -0
- package/lib/electron-browser/local-backend-services.js.map +1 -0
- package/lib/electron-browser/port-forwarding/port-forwarding-service.d.ts.map +1 -1
- package/lib/electron-browser/port-forwarding/port-forwarding-service.js +2 -1
- package/lib/electron-browser/port-forwarding/port-forwarding-service.js.map +1 -1
- package/lib/electron-browser/remote-frontend-contribution.d.ts.map +1 -1
- package/lib/electron-browser/remote-frontend-contribution.js +4 -3
- package/lib/electron-browser/remote-frontend-contribution.js.map +1 -1
- package/lib/electron-browser/remote-frontend-module.d.ts.map +1 -1
- package/lib/electron-browser/remote-frontend-module.js +13 -0
- package/lib/electron-browser/remote-frontend-module.js.map +1 -1
- package/lib/electron-browser/remote-user-storage-provider.d.ts +21 -0
- package/lib/electron-browser/remote-user-storage-provider.d.ts.map +1 -0
- package/lib/electron-browser/remote-user-storage-provider.js +75 -0
- package/lib/electron-browser/remote-user-storage-provider.js.map +1 -0
- package/lib/electron-node/remote-types.d.ts +1 -0
- package/lib/electron-node/remote-types.d.ts.map +1 -1
- package/lib/electron-node/setup/remote-native-dependency-contribution.d.ts +1 -0
- package/lib/electron-node/setup/remote-native-dependency-contribution.d.ts.map +1 -1
- package/lib/electron-node/setup/remote-native-dependency-service.d.ts +1 -0
- package/lib/electron-node/setup/remote-native-dependency-service.d.ts.map +1 -1
- package/lib/electron-node/setup/remote-setup-service.d.ts.map +1 -1
- package/lib/electron-node/setup/remote-setup-service.js +3 -0
- package/lib/electron-node/setup/remote-setup-service.js.map +1 -1
- package/package.json +6 -5
- package/src/electron-browser/local-backend-services.ts +31 -0
- package/src/electron-browser/port-forwarding/port-forwarding-service.ts +2 -1
- package/src/electron-browser/remote-frontend-contribution.ts +4 -3
- package/src/electron-browser/remote-frontend-module.ts +18 -1
- package/src/electron-browser/remote-user-storage-provider.ts +64 -0
- package/src/electron-node/setup/remote-setup-service.ts +2 -0
package/README.md
CHANGED
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { RpcProxy } from '@theia/core';
|
|
2
|
+
import { RemoteFileSystemProvider, RemoteFileSystemServer } from '@theia/filesystem/lib/common/remote-file-system-provider';
|
|
3
|
+
export declare const LocalEnvVariablesServer: unique symbol;
|
|
4
|
+
export declare const LocalRemoteFileSytemServer: unique symbol;
|
|
5
|
+
/**
|
|
6
|
+
* provide file access to local files while connected to a remote workspace or dev container.
|
|
7
|
+
*/
|
|
8
|
+
export declare class LocalRemoteFileSystemProvider extends RemoteFileSystemProvider {
|
|
9
|
+
protected readonly server: RpcProxy<RemoteFileSystemServer>;
|
|
10
|
+
}
|
|
11
|
+
//# sourceMappingURL=local-backend-services.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"local-backend-services.d.ts","sourceRoot":"","sources":["../../src/electron-browser/local-backend-services.ts"],"names":[],"mappings":"AAgBA,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAEvC,OAAO,EAAE,wBAAwB,EAAE,sBAAsB,EAAE,MAAM,0DAA0D,CAAC;AAE5H,eAAO,MAAM,uBAAuB,eAA0C,CAAC;AAC/E,eAAO,MAAM,0BAA0B,eAAuC,CAAC;AAE/E;;GAEG;AACH,qBACa,6BAA8B,SAAQ,wBAAwB;IACvE,mBAC4B,MAAM,EAAE,QAAQ,CAAC,sBAAsB,CAAC,CAAC;CACxE"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// *****************************************************************************
|
|
3
|
+
// Copyright (C) 2024 TypeFox and others.
|
|
4
|
+
//
|
|
5
|
+
// This program and the accompanying materials are made available under the
|
|
6
|
+
// terms of the Eclipse Public License v. 2.0 which is available at
|
|
7
|
+
// http://www.eclipse.org/legal/epl-2.0.
|
|
8
|
+
//
|
|
9
|
+
// This Source Code may also be made available under the following Secondary
|
|
10
|
+
// Licenses when the conditions for such availability set forth in the Eclipse
|
|
11
|
+
// Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
12
|
+
// with the GNU Classpath Exception which is available at
|
|
13
|
+
// https://www.gnu.org/software/classpath/license.html.
|
|
14
|
+
//
|
|
15
|
+
// SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-only WITH Classpath-exception-2.0
|
|
16
|
+
// *****************************************************************************
|
|
17
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18
|
+
exports.LocalRemoteFileSystemProvider = exports.LocalRemoteFileSytemServer = exports.LocalEnvVariablesServer = void 0;
|
|
19
|
+
const tslib_1 = require("tslib");
|
|
20
|
+
const inversify_1 = require("@theia/core/shared/inversify");
|
|
21
|
+
const remote_file_system_provider_1 = require("@theia/filesystem/lib/common/remote-file-system-provider");
|
|
22
|
+
exports.LocalEnvVariablesServer = Symbol('LocalEnviromentVariableServer');
|
|
23
|
+
exports.LocalRemoteFileSytemServer = Symbol('LocalRemoteFileSytemServer');
|
|
24
|
+
/**
|
|
25
|
+
* provide file access to local files while connected to a remote workspace or dev container.
|
|
26
|
+
*/
|
|
27
|
+
let LocalRemoteFileSystemProvider = class LocalRemoteFileSystemProvider extends remote_file_system_provider_1.RemoteFileSystemProvider {
|
|
28
|
+
};
|
|
29
|
+
exports.LocalRemoteFileSystemProvider = LocalRemoteFileSystemProvider;
|
|
30
|
+
tslib_1.__decorate([
|
|
31
|
+
(0, inversify_1.inject)(exports.LocalRemoteFileSytemServer),
|
|
32
|
+
tslib_1.__metadata("design:type", Object)
|
|
33
|
+
], LocalRemoteFileSystemProvider.prototype, "server", void 0);
|
|
34
|
+
exports.LocalRemoteFileSystemProvider = LocalRemoteFileSystemProvider = tslib_1.__decorate([
|
|
35
|
+
(0, inversify_1.injectable)()
|
|
36
|
+
], LocalRemoteFileSystemProvider);
|
|
37
|
+
//# sourceMappingURL=local-backend-services.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"local-backend-services.js","sourceRoot":"","sources":["../../src/electron-browser/local-backend-services.ts"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,yCAAyC;AACzC,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,gFAAgF;AAChF,gFAAgF;;;;AAGhF,4DAAkE;AAClE,0GAA4H;AAE/G,QAAA,uBAAuB,GAAG,MAAM,CAAC,+BAA+B,CAAC,CAAC;AAClE,QAAA,0BAA0B,GAAG,MAAM,CAAC,4BAA4B,CAAC,CAAC;AAE/E;;GAEG;AAEI,IAAM,6BAA6B,GAAnC,MAAM,6BAA8B,SAAQ,sDAAwB;CAG1E,CAAA;AAHY,sEAA6B;AAEV;IAD3B,IAAA,kBAAM,EAAC,kCAA0B,CAAC;;6DACkC;wCAF5D,6BAA6B;IADzC,IAAA,sBAAU,GAAE;GACA,6BAA6B,CAGzC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"port-forwarding-service.d.ts","sourceRoot":"","sources":["../../../src/electron-browser/port-forwarding/port-forwarding-service.ts"],"names":[],"mappings":"AAgBA,OAAO,EAAE,OAAO,EAAE,MAAM,aAAa,CAAC;AAEtC,OAAO,EAAE,4BAA4B,EAAE,MAAM,uDAAuD,CAAC;
|
|
1
|
+
{"version":3,"file":"port-forwarding-service.d.ts","sourceRoot":"","sources":["../../../src/electron-browser/port-forwarding/port-forwarding-service.ts"],"names":[],"mappings":"AAgBA,OAAO,EAAE,OAAO,EAAE,MAAM,aAAa,CAAC;AAEtC,OAAO,EAAE,4BAA4B,EAAE,MAAM,uDAAuD,CAAC;AAGrG,MAAM,WAAW,aAAa;IAC1B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,OAAO,EAAE,OAAO,CAAC;CACpB;AAED,qBACa,qBAAqB;IAG9B,QAAQ,CAAC,QAAQ,EAAE,4BAA4B,CAAC;IAEhD,SAAS,CAAC,QAAQ,CAAC,uBAAuB,gBAAuB;IACjE,QAAQ,CAAC,gBAAgB,oCAAsC;IAE/D,cAAc,EAAE,aAAa,EAAE,CAAM;IAGrC,IAAI,IAAI,IAAI;IAOZ,cAAc,CAAC,MAAM,CAAC,EAAE,MAAM,GAAG,aAAa;IAK9C,UAAU,CAAC,IAAI,EAAE,aAAa,EAAE,SAAS,EAAE,MAAM,GAAG,IAAI;IAqBxD,UAAU,CAAC,IAAI,EAAE,aAAa,GAAG,IAAI;IASrC,cAAc,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO;CAU3C"}
|
|
@@ -20,6 +20,7 @@ const tslib_1 = require("tslib");
|
|
|
20
20
|
const core_1 = require("@theia/core");
|
|
21
21
|
const inversify_1 = require("@theia/core/shared/inversify");
|
|
22
22
|
const remote_port_forwarding_provider_1 = require("../../electron-common/remote-port-forwarding-provider");
|
|
23
|
+
const electron_local_ws_connection_source_1 = require("@theia/core/lib/electron-browser/messaging/electron-local-ws-connection-source");
|
|
23
24
|
let PortForwardingService = class PortForwardingService {
|
|
24
25
|
constructor() {
|
|
25
26
|
this.onDidChangePortsEmitter = new core_1.Emitter();
|
|
@@ -37,7 +38,7 @@ let PortForwardingService = class PortForwardingService {
|
|
|
37
38
|
return this.forwardedPorts[index - 1];
|
|
38
39
|
}
|
|
39
40
|
updatePort(port, newAdress) {
|
|
40
|
-
const connectionPort =
|
|
41
|
+
const connectionPort = (0, electron_local_ws_connection_source_1.getCurrentPort)();
|
|
41
42
|
if (!connectionPort) {
|
|
42
43
|
// if there is no open remote connection we can't forward a port
|
|
43
44
|
return;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"port-forwarding-service.js","sourceRoot":"","sources":["../../../src/electron-browser/port-forwarding/port-forwarding-service.ts"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,yCAAyC;AACzC,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,gFAAgF;AAChF,gFAAgF;;;;AAEhF,sCAAsC;AACtC,4DAAiF;AACjF,2GAAqG;
|
|
1
|
+
{"version":3,"file":"port-forwarding-service.js","sourceRoot":"","sources":["../../../src/electron-browser/port-forwarding/port-forwarding-service.ts"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,yCAAyC;AACzC,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,gFAAgF;AAChF,gFAAgF;;;;AAEhF,sCAAsC;AACtC,4DAAiF;AACjF,2GAAqG;AACrG,wIAAgH;AAUzG,IAAM,qBAAqB,GAA3B,MAAM,qBAAqB;IAA3B;QAKgB,4BAAuB,GAAG,IAAI,cAAO,EAAQ,CAAC;QACxD,qBAAgB,GAAG,IAAI,CAAC,uBAAuB,CAAC,KAAK,CAAC;QAE/D,mBAAc,GAAoB,EAAE,CAAC;IAuDzC,CAAC;IApDG,IAAI;QACA,IAAI,CAAC,QAAQ,CAAC,iBAAiB,EAAE,CAAC,IAAI,CAAC,KAAK,CAAC,EAAE;YAC3C,IAAI,CAAC,cAAc,GAAG,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,OAAO,EAAE,CAAC,CAAC,OAAO,EAAE,SAAS,EAAE,CAAC,CAAC,IAAI,EAAE,OAAO,EAAE,KAAK,EAAE,CAAC,CAAC,CA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KAAK,CAAC,CAAC,EAAE,CAAC;YACf,IAAI,CAAC,cAAc,CAAC,MAAM,CAAC,KAAK,EAAE,CAAC,CAAC,CAAC;YACrC,IAAI,CAAC,QAAQ,CAAC,WAAW,CAAC,EAAE,IAAI,EAAE,IAAI,CAAC,SAAU,EAAE,CAAC,CAAC;YACrD,IAAI,CAAC,uBAAuB,CAAC,IAAI,EAAE,CAAC;QACxC,CAAC;IACL,CAAC;IAED,cAAc,CAAC,OAAe;QAC1B,MAAM,KAAK,GAAG,OAAO,CAAC,KAAK,CAAC,aAAa,CAAC,CAAC;QAC3C,IAAI,CAAC,KAAK,EAAE,CAAC;YACT,OAAO,KAAK,CAAC;QACjB,CAAC;QAED,MAAM,IAAI,GAAG,QAAQ,CAAC,OAAO,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC;QAE/E,OAAO,CAAC,IAAI,CAAC,cAAc,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,SAAS,KAAK,IAAI,CAAC,CAAC;IAChE,CAAC;CACJ,CAAA;AA/DY,sDAAqB;AAGrB;IADR,IAAA,kBAAM,EAAC,8DAA4B,CAAC;;uDACW;AAQhD;IADC,IAAA,yBAAa,GAAE;;;;iDAMf;gCAhBQ,qBAAqB;IADjC,IAAA,sBAAU,GAAE;GACA,qBAAqB,CA+DjC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"remote-frontend-contribution.d.ts","sourceRoot":"","sources":["../../src/electron-browser/remote-frontend-contribution.ts"],"names":[],"mappings":"AAgBA,OAAO,EAAE,OAAO,EAAE,mBAAmB,EAAE,eAAe,EAAE,oBAAoB,EAAO,iBAAiB,EAAkB,MAAM,aAAa,CAAC;AAC1I,OAAO,EAAE,+BAA+B,EAAE,SAAS,EAAsC,MAAM,yBAAyB,C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CAAC,aAAa,EAAE,aAAa,CAAC;IAGhD,SAAS,CAAC,QAAQ,CAAC,2BAA2B,EAAE,oBAAoB,CAAC,0BAA0B,CAAC,CAAC;IAEjG,SAAS,CAAC,cAAc,iBAAwB;IAE1C,SAAS,IAAI,OAAO,CAAC,IAAI,CAAC;cAYhB,YAAY,CAAC,IAAI,EAAE,YAAY,GAAG,OAAO,CAAC,IAAI,CAAC;IAoB/D,gBAAgB,CAAC,QAAQ,EAAE,eAAe,GAAG,IAAI;cAejC,gBAAgB,IAAI,OAAO,CAAC,IAAI,CAAC;cAUjC,YAAY,IAAI,OAAO,CAAC,IAAI,CAAC;CA4BhD"}
|
|
@@ -24,6 +24,7 @@ const remote_status_service_1 = require("../electron-common/remote-status-servic
|
|
|
24
24
|
const remote_registry_contribution_1 = require("./remote-registry-contribution");
|
|
25
25
|
const remote_service_1 = require("./remote-service");
|
|
26
26
|
const window_service_1 = require("@theia/core/lib/browser/window/window-service");
|
|
27
|
+
const electron_local_ws_connection_source_1 = require("@theia/core/lib/electron-browser/messaging/electron-local-ws-connection-source");
|
|
27
28
|
var RemoteCommands;
|
|
28
29
|
(function (RemoteCommands) {
|
|
29
30
|
RemoteCommands.REMOTE_SELECT = {
|
|
@@ -39,7 +40,7 @@ let RemoteFrontendContribution = class RemoteFrontendContribution {
|
|
|
39
40
|
this.remoteRegistry = new remote_registry_contribution_1.RemoteRegistry();
|
|
40
41
|
}
|
|
41
42
|
async configure() {
|
|
42
|
-
const port =
|
|
43
|
+
const port = (0, electron_local_ws_connection_source_1.getCurrentPort)();
|
|
43
44
|
if (port) {
|
|
44
45
|
const status = await this.remoteStatusService.getStatus(Number(port));
|
|
45
46
|
await this.setStatusBar(status);
|
|
@@ -84,9 +85,9 @@ let RemoteFrontendContribution = class RemoteFrontendContribution {
|
|
|
84
85
|
});
|
|
85
86
|
}
|
|
86
87
|
async disconnectRemote() {
|
|
87
|
-
const
|
|
88
|
-
const localPort = searchParams.get('localPort');
|
|
88
|
+
const localPort = (0, electron_local_ws_connection_source_1.getLocalPort)();
|
|
89
89
|
if (localPort) {
|
|
90
|
+
const searchParams = new URLSearchParams(location.search);
|
|
90
91
|
const currentPort = searchParams.get('port');
|
|
91
92
|
this.remoteStatusService.connectionClosed(parseInt(currentPort !== null && currentPort !== void 0 ? currentPort : '0'));
|
|
92
93
|
this.windowService.reload({ search: { port: localPort } });
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"remote-frontend-contribution.js","sourceRoot":"","sources":["../../src/electron-browser/remote-frontend-contribution.ts"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,yCAAyC;AACzC,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,gFAAgF;AAChF,gFAAgF;;;;AAEhF,sCAA0I;AAC1I,qDAAyH;AACzH,4DAAmF;AACnF,oFAA6F;AAC7F,iFAA4F;AAC5F,qDAAiD;AACjD,kFAA8E;
|
|
1
|
+
{"version":3,"file":"remote-frontend-contribution.js","sourceRoot":"","sources":["../../src/electron-browser/remote-frontend-contribution.ts"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,yCAAyC;AACzC,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,gFAAgF;AAChF,gFAAgF;;;;AAEhF,sCAA0I;AAC1I,qDAAyH;AACzH,4DAAmF;AACnF,oFAA6F;AAC7F,iFAA4F;AAC5F,qDAAiD;AACjD,kFAA8E;AAC9E,wIAA8H;AAE9H,IAAiB,cAAc,CAQ9B;AARD,WAAiB,cAAc;IACd,4BAAa,GAAY;QAClC,EAAE,EAAE,eAAe;KACtB,CAAC;IACW,gCAAiB,GAAY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C;CAEJ,CAAA;AA9GY,gEAA0B;AAGhB;IADlB,IAAA,kBAAM,EAAC,mBAAS,CAAC;;6DACsB;AAGrB;IADlB,IAAA,kBAAM,EAAC,wBAAiB,CAAC;IAAE,IAAA,oBAAQ,GAAE;;qEACmB;AAGtC;IADlB,IAAA,kBAAM,EAAC,sBAAe,CAAC;sCACY,sBAAe;mEAAC;AAGjC;IADlB,IAAA,kBAAM,EAAC,8BAAa,CAAC;sCACY,8BAAa;iEAAC;AAG7B;IADlB,IAAA,kBAAM,EAAC,2CAAmB,CAAC;;uEACgC;AAGzC;IADlB,IAAA,kBAAM,EAAC,8BAAa,CAAC;;iEAC0B;AAG7B;IADlB,IAAA,kBAAM,EAAC,2BAAoB,CAAC;IAAE,IAAA,iBAAK,EAAC,yDAA0B,CAAC;;+EACiC;qCArBxF,0BAA0B;IADtC,IAAA,sBAAU,GAAE;GACA,0BAA0B,CA8GtC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"remote-frontend-module.d.ts","sourceRoot":"","sources":["../../src/electron-browser/remote-frontend-module.ts"],"names":[],"mappings":"AAiBA,OAAO,EAAE,eAAe,EAAE,MAAM,8BAA8B,CAAC;AAgB/D,OAAO,6DAA6D,CAAC;;
|
|
1
|
+
{"version":3,"file":"remote-frontend-module.d.ts","sourceRoot":"","sources":["../../src/electron-browser/remote-frontend-module.ts"],"names":[],"mappings":"AAiBA,OAAO,EAAE,eAAe,EAAE,MAAM,8BAA8B,CAAC;AAgB/D,OAAO,6DAA6D,CAAC;;AAOrE,wBA2CG"}
|
|
@@ -33,6 +33,11 @@ const port_forwarding_service_1 = require("./port-forwarding/port-forwarding-ser
|
|
|
33
33
|
const remote_port_forwarding_provider_1 = require("../electron-common/remote-port-forwarding-provider");
|
|
34
34
|
const service_connection_provider_1 = require("@theia/core/lib/browser/messaging/service-connection-provider");
|
|
35
35
|
require("../../src/electron-browser/style/port-forwarding-widget.css");
|
|
36
|
+
const user_storage_contribution_1 = require("@theia/userstorage/lib/browser/user-storage-contribution");
|
|
37
|
+
const remote_user_storage_provider_1 = require("./remote-user-storage-provider");
|
|
38
|
+
const remote_file_system_provider_1 = require("@theia/filesystem/lib/common/remote-file-system-provider");
|
|
39
|
+
const local_backend_services_1 = require("./local-backend-services");
|
|
40
|
+
const env_variables_1 = require("@theia/core/lib/common/env-variables");
|
|
36
41
|
exports.default = new inversify_1.ContainerModule((bind, _, __, rebind) => {
|
|
37
42
|
bind(remote_frontend_contribution_1.RemoteFrontendContribution).toSelf().inSingletonScope();
|
|
38
43
|
bind(browser_1.FrontendApplicationContribution).toService(remote_frontend_contribution_1.RemoteFrontendContribution);
|
|
@@ -53,5 +58,13 @@ exports.default = new inversify_1.ContainerModule((bind, _, __, rebind) => {
|
|
|
53
58
|
bind(remote_ssh_connection_provider_1.RemoteSSHConnectionProvider).toDynamicValue(ctx => service_connection_provider_1.ServiceConnectionProvider.createLocalProxy(ctx.container, remote_ssh_connection_provider_1.RemoteSSHConnectionProviderPath)).inSingletonScope();
|
|
54
59
|
bind(remote_status_service_1.RemoteStatusService).toDynamicValue(ctx => service_connection_provider_1.ServiceConnectionProvider.createLocalProxy(ctx.container, remote_status_service_1.RemoteStatusServicePath)).inSingletonScope();
|
|
55
60
|
bind(remote_port_forwarding_provider_1.RemotePortForwardingProvider).toDynamicValue(ctx => service_connection_provider_1.ServiceConnectionProvider.createLocalProxy(ctx.container, remote_port_forwarding_provider_1.RemoteRemotePortForwardingProviderPath)).inSingletonScope();
|
|
61
|
+
bind(local_backend_services_1.LocalRemoteFileSytemServer).toDynamicValue(ctx => browser_1.isRemote ?
|
|
62
|
+
service_connection_provider_1.ServiceConnectionProvider.createLocalProxy(ctx.container, remote_file_system_provider_1.remoteFileSystemPath, new remote_file_system_provider_1.RemoteFileSystemProxyFactory()) :
|
|
63
|
+
ctx.container.get(remote_file_system_provider_1.RemoteFileSystemServer));
|
|
64
|
+
bind(local_backend_services_1.LocalEnvVariablesServer).toDynamicValue(ctx => browser_1.isRemote ?
|
|
65
|
+
service_connection_provider_1.ServiceConnectionProvider.createLocalProxy(ctx.container, env_variables_1.envVariablesPath) :
|
|
66
|
+
ctx.container.get(env_variables_1.EnvVariablesServer));
|
|
67
|
+
bind(local_backend_services_1.LocalRemoteFileSystemProvider).toSelf().inSingletonScope();
|
|
68
|
+
rebind(user_storage_contribution_1.UserStorageContribution).to(remote_user_storage_provider_1.RemoteUserStorageContribution);
|
|
56
69
|
});
|
|
57
70
|
//# sourceMappingURL=remote-frontend-module.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"remote-frontend-module.js","sourceRoot":"","sources":["../../src/electron-browser/remote-frontend-module.ts"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,yCAAyC;AACzC,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,gFAAgF;AAChF,gFAAgF;;AAEhF,sCAA4E;AAC5E,4DAA+D;AAC/D,
|
|
1
|
+
{"version":3,"file":"remote-frontend-module.js","sourceRoot":"","sources":["../../src/electron-browser/remote-frontend-module.ts"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,yCAAyC;AACzC,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,gFAAgF;AAChF,gFAAgF;;AAEhF,sCAA4E;AAC5E,4DAA+D;AAC/D,qDAAyH;AACzH,uEAAkE;AAClE,sGAAiI;AACjI,iFAA4E;AAC5E,iFAA4E;AAC5E,qDAAiD;AACjD,oFAAwG;AACxG,kIAA4H;AAC5H,+FAAwF;AACxF,6DAA6D;AAC7D,qFAA2G;AAC3G,+FAA2F;AAC3F,uFAAkF;AAClF,wG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AC,CAAC;AAEtE,CAAC,CAAC,CAAC"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { FileService } from '@theia/filesystem/lib/browser/file-service';
|
|
2
|
+
import { FileSystemProvider } from '@theia/filesystem/lib/common/files';
|
|
3
|
+
import { UserStorageContribution } from '@theia/userstorage/lib/browser/user-storage-contribution';
|
|
4
|
+
import { RemoteStatusService } from '../electron-common/remote-status-service';
|
|
5
|
+
import { LocalRemoteFileSystemProvider } from './local-backend-services';
|
|
6
|
+
import { Deferred } from '@theia/core/lib/common/promise-util';
|
|
7
|
+
import { URI } from '@theia/core';
|
|
8
|
+
import { EnvVariablesServer } from '@theia/core/lib/common/env-variables';
|
|
9
|
+
/**
|
|
10
|
+
* This overide is to have remote connections still use settings, keymaps, etc. from the local machine.
|
|
11
|
+
*/
|
|
12
|
+
export declare class RemoteUserStorageContribution extends UserStorageContribution {
|
|
13
|
+
protected readonly remoteStatusService: RemoteStatusService;
|
|
14
|
+
protected readonly localRemoteFileSystemProvider: LocalRemoteFileSystemProvider;
|
|
15
|
+
protected readonly localEnvironments: EnvVariablesServer;
|
|
16
|
+
isRemoteConnection: Deferred<boolean>;
|
|
17
|
+
protected init(): void;
|
|
18
|
+
protected getDelegate(service: FileService): Promise<FileSystemProvider>;
|
|
19
|
+
protected getCongigDirUri(): Promise<URI>;
|
|
20
|
+
}
|
|
21
|
+
//# sourceMappingURL=remote-user-storage-provider.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"remote-user-storage-provider.d.ts","sourceRoot":"","sources":["../../src/electron-browser/remote-user-storage-provider.ts"],"names":[],"mappings":"AAiBA,OAAO,EAAE,WAAW,EAAE,MAAM,4CAA4C,CAAC;AACzE,OAAO,EAAE,kBAAkB,EAAE,MAAM,oCAAoC,CAAC;AACxE,OAAO,EAAE,uBAAuB,EAAE,MAAM,0DAA0D,CAAC;AACnG,OAAO,EAAE,mBAAmB,EAAE,MAAM,0CAA0C,CAAC;AAC/E,OAAO,EAA2B,6BAA6B,EAAE,MAAM,0BAA0B,CAAC;AAClG,OAAO,EAAE,QAAQ,EAAE,MAAM,qCAAqC,CAAC;AAC/D,OAAO,EAAE,GAAG,EAAE,MAAM,aAAa,CAAC;AAClC,OAAO,EAAE,kBAAkB,EAAE,MAAM,sCAAsC,CAAC;AAG1E;;GAEG;AACH,qBACa,6BAA8B,SAAQ,uBAAuB;IAEtE,SAAS,CAAC,QAAQ,CAAC,mBAAmB,EAAE,mBAAmB,CAAC;IAG5D,SAAS,CAAC,QAAQ,CAAC,6BAA6B,EAAE,6BAA6B,CAAC;IAGhF,SAAS,CAAC,QAAQ,CAAC,iBAAiB,EAAE,kBAAkB,CAAC;IAEzD,kBAAkB,EAAE,QAAQ,CAAC,OAAO,CAAC,CAAkB;IAGvD,SAAS,CAAC,IAAI,IAAI,IAAI;cAOG,WAAW,CAAC,OAAO,EAAE,WAAW,GAAG,OAAO,CAAC,kBAAkB,CAAC;cAM9D,eAAe,IAAI,OAAO,CAAC,GAAG,CAAC;CAM3D"}
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// *****************************************************************************
|
|
3
|
+
// Copyright (C) 2024 TypeFox and others.
|
|
4
|
+
//
|
|
5
|
+
// This program and the accompanying materials are made available under the
|
|
6
|
+
// terms of the Eclipse Public License v. 2.0 which is available at
|
|
7
|
+
// http://www.eclipse.org/legal/epl-2.0.
|
|
8
|
+
//
|
|
9
|
+
// This Source Code may also be made available under the following Secondary
|
|
10
|
+
// Licenses when the conditions for such availability set forth in the Eclipse
|
|
11
|
+
// Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
12
|
+
// with the GNU Classpath Exception which is available at
|
|
13
|
+
// https://www.gnu.org/software/classpath/license.html.
|
|
14
|
+
//
|
|
15
|
+
// SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-only WITH Classpath-exception-2.0
|
|
16
|
+
// *****************************************************************************
|
|
17
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18
|
+
exports.RemoteUserStorageContribution = void 0;
|
|
19
|
+
const tslib_1 = require("tslib");
|
|
20
|
+
const inversify_1 = require("@theia/core/shared/inversify");
|
|
21
|
+
const user_storage_contribution_1 = require("@theia/userstorage/lib/browser/user-storage-contribution");
|
|
22
|
+
const remote_status_service_1 = require("../electron-common/remote-status-service");
|
|
23
|
+
const local_backend_services_1 = require("./local-backend-services");
|
|
24
|
+
const promise_util_1 = require("@theia/core/lib/common/promise-util");
|
|
25
|
+
const core_1 = require("@theia/core");
|
|
26
|
+
const env_variables_1 = require("@theia/core/lib/common/env-variables");
|
|
27
|
+
const electron_local_ws_connection_source_1 = require("@theia/core/lib/electron-browser/messaging/electron-local-ws-connection-source");
|
|
28
|
+
/**
|
|
29
|
+
* This overide is to have remote connections still use settings, keymaps, etc. from the local machine.
|
|
30
|
+
*/
|
|
31
|
+
let RemoteUserStorageContribution = class RemoteUserStorageContribution extends user_storage_contribution_1.UserStorageContribution {
|
|
32
|
+
constructor() {
|
|
33
|
+
super(...arguments);
|
|
34
|
+
this.isRemoteConnection = new promise_util_1.Deferred();
|
|
35
|
+
}
|
|
36
|
+
init() {
|
|
37
|
+
const port = (0, electron_local_ws_connection_source_1.getCurrentPort)();
|
|
38
|
+
if (port) {
|
|
39
|
+
this.remoteStatusService.getStatus(Number(port)).then(status => this.isRemoteConnection.resolve(status.alive));
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
async getDelegate(service) {
|
|
43
|
+
return await this.isRemoteConnection.promise ?
|
|
44
|
+
this.localRemoteFileSystemProvider
|
|
45
|
+
: service.activateProvider('file');
|
|
46
|
+
}
|
|
47
|
+
async getCongigDirUri() {
|
|
48
|
+
return await this.isRemoteConnection.promise ?
|
|
49
|
+
new core_1.URI(await this.localEnvironments.getConfigDirUri())
|
|
50
|
+
: super.getCongigDirUri();
|
|
51
|
+
}
|
|
52
|
+
};
|
|
53
|
+
exports.RemoteUserStorageContribution = RemoteUserStorageContribution;
|
|
54
|
+
tslib_1.__decorate([
|
|
55
|
+
(0, inversify_1.inject)(remote_status_service_1.RemoteStatusService),
|
|
56
|
+
tslib_1.__metadata("design:type", Object)
|
|
57
|
+
], RemoteUserStorageContribution.prototype, "remoteStatusService", void 0);
|
|
58
|
+
tslib_1.__decorate([
|
|
59
|
+
(0, inversify_1.inject)(local_backend_services_1.LocalRemoteFileSystemProvider),
|
|
60
|
+
tslib_1.__metadata("design:type", local_backend_services_1.LocalRemoteFileSystemProvider)
|
|
61
|
+
], RemoteUserStorageContribution.prototype, "localRemoteFileSystemProvider", void 0);
|
|
62
|
+
tslib_1.__decorate([
|
|
63
|
+
(0, inversify_1.inject)(local_backend_services_1.LocalEnvVariablesServer),
|
|
64
|
+
tslib_1.__metadata("design:type", Object)
|
|
65
|
+
], RemoteUserStorageContribution.prototype, "localEnvironments", void 0);
|
|
66
|
+
tslib_1.__decorate([
|
|
67
|
+
(0, inversify_1.postConstruct)(),
|
|
68
|
+
tslib_1.__metadata("design:type", Function),
|
|
69
|
+
tslib_1.__metadata("design:paramtypes", []),
|
|
70
|
+
tslib_1.__metadata("design:returntype", void 0)
|
|
71
|
+
], RemoteUserStorageContribution.prototype, "init", null);
|
|
72
|
+
exports.RemoteUserStorageContribution = RemoteUserStorageContribution = tslib_1.__decorate([
|
|
73
|
+
(0, inversify_1.injectable)()
|
|
74
|
+
], RemoteUserStorageContribution);
|
|
75
|
+
//# sourceMappingURL=remote-user-storage-provider.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"remote-user-storage-provider.js","sourceRoot":"","sources":["../../src/electron-browser/remote-user-storage-provider.ts"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,yCAAyC;AACzC,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,gFAAgF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;IADT,IAAA,yBAAa,GAAE;;;;yDAMf;wCAlBQ,6BAA6B;IADzC,IAAA,sBAAU,GAAE;GACA,6BAA6B,CAgCzC"}
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
/// <reference types="node" />
|
|
3
3
|
/// <reference types="node" />
|
|
4
4
|
/// <reference types="node" />
|
|
5
|
+
/// <reference types="node" />
|
|
5
6
|
import { Disposable, Event } from '@theia/core';
|
|
6
7
|
import * as net from 'net';
|
|
7
8
|
export type RemoteStatusReport = (message: string) => void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"remote-types.d.ts","sourceRoot":"","sources":["../../src/electron-node/remote-types.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"remote-types.d.ts","sourceRoot":"","sources":["../../src/electron-node/remote-types.ts"],"names":[],"mappings":";;;;;AAgBA,OAAO,EAAE,UAAU,EAAE,KAAK,EAAE,MAAM,aAAa,CAAC;AAChD,OAAO,KAAK,GAAG,MAAM,KAAK,CAAC;AAE3B,MAAM,MAAM,kBAAkB,GAAG,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC;AAE3D,MAAM,WAAW,YAAY;IACzB,IAAI,EAAE,MAAM,CAAA;IACZ,MAAM,EAAE,MAAM,CAAA;IACd,MAAM,EAAE,QAAQ,CAAA;IAChB,IAAI,CAAC,EAAE,MAAM,CAAA;CAChB;AAED,MAAM,WAAW,iBAAiB;IAC9B,GAAG,CAAC,EAAE,MAAM,CAAC,UAAU,CAAC;CAC3B;AAED,MAAM,WAAW,gBAAgB;IAC7B,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,MAAM,CAAC;CAClB;AAED,MAAM,MAAM,gBAAgB,GAAG,CAAC,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,KAAK,OAAO,CAAC;AAE3E,MAAM,WAAW,gBAAiB,SAAQ,UAAU;IAChD,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,EAAE,MAAM,CAAC;IAClB,UAAU,EAAE,MAAM,CAAC;IACnB,eAAe,EAAE,KAAK,CAAC,IAAI,CAAC,CAAC;IAC7B,UAAU,CAAC,MAAM,EAAE,GAAG,CAAC,MAAM,EAAE,IAAI,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAEpD;;OAEG;IACH,IAAI,CAAC,GAAG,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,MAAM,EAAE,EAAE,OAAO,CAAC,EAAE,iBAAiB,GAAG,OAAO,CAAC,gBAAgB,CAAC,CAAC;IAE3F;;;OAGG;IACH,WAAW,CAAC,GAAG,EAAE,MAAM,EAAE,MAAM,EAAE,gBAAgB,EAAE,IAAI,CAAC,EAAE,MAAM,EAAE,EAAE,OAAO,CAAC,EAAE,iBAAiB,GAAG,OAAO,CAAC,gBAAgB,CAAC,CAAC;IAE5H;;OAEG;IACH,IAAI,CAAC,SAAS,EAAE,MAAM,GAAG,MAAM,GAAG,MAAM,CAAC,cAAc,EAAE,UAAU,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAE5F;;OAEG;IACH,WAAW,CAAC,IAAI,IAAI,CAAC;CACxB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"remote-native-dependency-contribution.d.ts","sourceRoot":"","sources":["../../../src/electron-node/setup/remote-native-dependency-contribution.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"remote-native-dependency-contribution.d.ts","sourceRoot":"","sources":["../../../src/electron-node/setup/remote-native-dependency-contribution.ts"],"names":[],"mappings":";;AAiBA,OAAO,EAAE,cAAc,EAAE,MAAM,mCAAmC,CAAC;AACnE,OAAO,EAAE,cAAc,EAAE,MAAM,qDAAqD,CAAC;AAErF,MAAM,WAAW,oBAAoB;IACjC,IAAI,EAAE,MAAM,CAAC;IACb,IAAI,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,MAAM,kBAAkB,GAAG,sBAAsB,GAAG,2BAA2B,CAAC;AAEtF,MAAM,WAAW,sBAAsB;IACnC,IAAI,EAAE,oBAAoB,CAAA;IAC1B,MAAM,EAAE,MAAM,CAAA;CACjB;AAED,yBAAiB,oBAAoB,CAAC;IAClC,SAAgB,EAAE,CAAC,IAAI,EAAE,OAAO,GAAG,IAAI,IAAI,sBAAsB,CAEhE;CACJ;AAED,MAAM,WAAW,2BAA2B;IACxC,OAAO,EAAE,KAAK,GAAG,KAAK,GAAG,KAAK,CAAA;IAC9B,MAAM,EAAE,MAAM,CAAA;CACjB;AAED,yBAAiB,2BAA2B,CAAC;IACzC,SAAgB,EAAE,CAAC,IAAI,EAAE,OAAO,GAAG,IAAI,IAAI,2BAA2B,CAErE;CACJ;AAED,MAAM,WAAW,eAAe;IAC5B,cAAc,EAAE,cAAc,CAAA;IAC9B,YAAY,EAAE,MAAM,CAAC;IACrB,QAAQ,EAAE,CAAC,WAAW,EAAE,MAAM,GAAG,cAAc,KAAK,OAAO,CAAC,MAAM,CAAC,CAAA;CACtE;AAED,eAAO,MAAM,kCAAkC,eAA+C,CAAC;AAE/F;;GAEG;AACH,MAAM,WAAW,kCAAkC;IAC/C,QAAQ,CAAC,OAAO,EAAE,eAAe,GAAG,OAAO,CAAC,kBAAkB,CAAC,CAAC;CACnE"}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
/// <reference types="node" />
|
|
2
|
+
/// <reference types="node" />
|
|
2
3
|
import { ContributionProvider } from '@theia/core';
|
|
3
4
|
import { RequestService, RequestOptions } from '@theia/core/shared/@theia/request';
|
|
4
5
|
import { DependencyDownload, RemoteNativeDependencyContribution } from './remote-native-dependency-contribution';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"remote-native-dependency-service.d.ts","sourceRoot":"","sources":["../../../src/electron-node/setup/remote-native-dependency-service.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"remote-native-dependency-service.d.ts","sourceRoot":"","sources":["../../../src/electron-node/setup/remote-native-dependency-service.ts"],"names":[],"mappings":";;AAgBA,OAAO,EAAE,oBAAoB,EAAiB,MAAM,aAAa,CAAC;AAElE,OAAO,EAAkB,cAAc,EAAE,cAAc,EAAE,MAAM,mCAAmC,CAAC;AAInG,OAAO,EAAE,kBAAkB,EAA+B,kCAAkC,EAAE,MAAM,yCAAyC,CAAC;AAC9I,OAAO,EAAE,cAAc,EAAE,MAAM,qDAAqD,CAAC;AAMrF,eAAO,MAAM,oBAAoB;;;;;CAKhC,CAAC;AAEF,MAAM,WAAW,oBAAoB;IACjC,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,MAAM,CAAC;IACf,IAAI,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,qBACa,6BAA6B;IAGtC,SAAS,CAAC,6BAA6B,EAAE,oBAAoB,CAAC,kCAAkC,CAAC,CAAC;IAGlG,SAAS,CAAC,cAAc,EAAE,cAAc,CAAC;IAEnC,oBAAoB,CAAC,cAAc,EAAE,cAAc,EAAE,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,oBAAoB,EAAE,CAAC;cAc9F,kBAAkB,CAAC,WAAW,EAAE,MAAM,GAAG,cAAc,GAAG,OAAO,CAAC,MAAM,CAAC;cAYzE,eAAe,CAAC,UAAU,EAAE,kBAAkB,EAAE,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,oBAAoB,EAAE,CAAC;CAiCtH"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"remote-setup-service.d.ts","sourceRoot":"","sources":["../../../src/electron-node/setup/remote-setup-service.ts"],"names":[],"mappings":"AAiBA,OAAO,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,kBAAkB,EAAE,MAAM,iBAAiB,CAAC;AACzF,OAAO,EAAoB,qBAAqB,EAAE,cAAc,EAAE,MAAM,qDAAqD,CAAC;AAC9H,OAAO,EAAE,kBAAkB,EAAE,MAAM,+CAA+C,CAAC;AACnF,OA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AAC;cA6CpD,gBAAgB,CAAC,UAAU,EAAE,gBAAgB,EAAE,QAAQ,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC;cAiC9H,oBAAoB,CAAC,UAAU,EAAE,gBAAgB,GAAG,OAAO,CAAC,cAAc,CAAC;cAgD3E,sBAAsB,CAAC,UAAU,EAAE,gBAAgB,EAAE,QAAQ,EAAE,cAAc,GAAG,OAAO,CAAC,MAAM,CAAC;IAK/G,SAAS,CAAC,gBAAgB,IAAI,MAAM;IAMpC,SAAS,CAAC,oBAAoB,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM;cAIpC,WAAW,CAAC,UAAU,EAAE,gBAAgB,EAAE,QAAQ,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;cAOtG,eAAe,CAAC,UAAU,EAAE,gBAAgB,EAAE,UAAU,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC;cAKnF,WAAW,CAAC,UAAU,EAAE,gBAAgB,EAAE,QAAQ,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,EAAE,eAAe,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;cAO/H,mBAAmB,CAAC,UAAU,EAAE,gBAAgB,EAAE,QAAQ,EAAE,cAAc,EAAE,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,gBAAgB,CAAC;CAGzI"}
|
|
@@ -136,6 +136,9 @@ let RemoteSetupService = class RemoteSetupService {
|
|
|
136
136
|
else if (archResult.match(/i\d83/)) { // i386, i483, i683
|
|
137
137
|
arch = 'x86';
|
|
138
138
|
}
|
|
139
|
+
else if (archResult.includes('aarch64')) {
|
|
140
|
+
arch = 'arm64';
|
|
141
|
+
}
|
|
139
142
|
else {
|
|
140
143
|
arch = archResult.trim();
|
|
141
144
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"remote-setup-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AA8B,GAAG,MAAM,CAAC,MAAM,CAAC,CAAC;QACpE,CAAC;IACL,CAAC;IAES,KAAK,CAAC,eAAe,CAAC,UAA4B,EAAE,UAAkB;QAC5E,MAAM,QAAQ,GAAG,MAAM,UAAU,CAAC,IAAI,CAAC,OAAO,UAAU,GAAG,CAAC,CAAC;QAC7D,OAAO,CAAC,OAAO,CAAC,QAAQ,CAAC,MAAM,CAAC,CAAC;IACrC,CAAC;IAES,KAAK,CAAC,WAAW,CAAC,UAA4B,EAAE,QAAwB,EAAE,UAAkB,EAAE,eAAuB;QAC3H,MAAM,MAAM,GAAG,MAAM,UAAU,CAAC,IAAI,CAAC,IAAI,CAAC,aAAa,CAAC,KAAK,CAAC,QAAQ,EAAE,UAAU,EAAE,eAAe,CAAC,CAAC,CAAC;QACtG,IAAI,MAAM,CAAC,MAAM,EAAE,CAAC;YAChB,MAAM,IAAI,KAAK,CAAC,mBAAmB,GAAG,MAAM,CAAC,MAAM,CAAC,CAAC;QACzD,CAAC;IACL,CAAC;IAES,KAAK,CAAC,mBAAmB,CAAC,UAA4B,EAAE,QAAwB,EAAE,MAAc;QACtG,OAAO,UAAU,CAAC,IAAI,CAAC,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,QAAQ,CAAC,EAAE,CAAC,MAAM,CAAC,CAAC,CAAC;IACxE,CAAC;CACJ,CAAA;
|
|
1
|
+
{"version":3,"file":"remote-setup-service.js","sourceRoot":"","sources":["../../../src/electron-node/setup/remote-setup-service.ts"],"names":[],"mappings":";AAAA,gFAAgF;AAChF,yCAAyC;AACzC,EAAE;AACF,2EAA2E;AAC3E,mEAAmE;AACnE,wCAAwC;AACxC,EAAE;AACF,4EAA4E;AAC5E,8EAA8E;AAC9E,6EAA6E;AAC7E,yDAAyD;AACzD,uDAAuD;AACvD,EAAE;AACF,gFAAgF;AAChF,gFAAgF;;;;AAEhF,4DAAyE;AAEzE,iGAA8H;AAC9H,uFAAmF;AACnF,+DAA0D;AAC1D,yFAAmF;AACn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.0-next.112+f4778c273",
|
|
4
4
|
"description": "Theia - Remote",
|
|
5
5
|
"dependencies": {
|
|
6
|
-
"@theia/core": "1.
|
|
7
|
-
"@theia/filesystem": "1.
|
|
6
|
+
"@theia/core": "1.57.0-next.112+f4778c273",
|
|
7
|
+
"@theia/filesystem": "1.57.0-next.112+f4778c273",
|
|
8
|
+
"@theia/userstorage": "1.57.0-next.112+f4778c273",
|
|
8
9
|
"archiver": "^5.3.1",
|
|
9
10
|
"decompress": "^4.2.1",
|
|
10
11
|
"decompress-tar": "^4.0.0",
|
|
@@ -52,7 +53,7 @@
|
|
|
52
53
|
"watch": "theiaext watch"
|
|
53
54
|
},
|
|
54
55
|
"devDependencies": {
|
|
55
|
-
"@theia/ext-scripts": "1.
|
|
56
|
+
"@theia/ext-scripts": "1.58.0",
|
|
56
57
|
"@types/archiver": "^5.3.2",
|
|
57
58
|
"@types/decompress": "^4.2.4",
|
|
58
59
|
"@types/express-http-proxy": "^1.6.6",
|
|
@@ -63,5 +64,5 @@
|
|
|
63
64
|
"nyc": {
|
|
64
65
|
"extends": "../../configs/nyc.json"
|
|
65
66
|
},
|
|
66
|
-
"gitHead": "
|
|
67
|
+
"gitHead": "f4778c2737bb75613f0e1f99da8996bad91f6e17"
|
|
67
68
|
}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
// *****************************************************************************
|
|
2
|
+
// Copyright (C) 2024 TypeFox and others.
|
|
3
|
+
//
|
|
4
|
+
// This program and the accompanying materials are made available under the
|
|
5
|
+
// terms of the Eclipse Public License v. 2.0 which is available at
|
|
6
|
+
// http://www.eclipse.org/legal/epl-2.0.
|
|
7
|
+
//
|
|
8
|
+
// This Source Code may also be made available under the following Secondary
|
|
9
|
+
// Licenses when the conditions for such availability set forth in the Eclipse
|
|
10
|
+
// Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
11
|
+
// with the GNU Classpath Exception which is available at
|
|
12
|
+
// https://www.gnu.org/software/classpath/license.html.
|
|
13
|
+
//
|
|
14
|
+
// SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-only WITH Classpath-exception-2.0
|
|
15
|
+
// *****************************************************************************
|
|
16
|
+
|
|
17
|
+
import { RpcProxy } from '@theia/core';
|
|
18
|
+
import { inject, injectable } from '@theia/core/shared/inversify';
|
|
19
|
+
import { RemoteFileSystemProvider, RemoteFileSystemServer } from '@theia/filesystem/lib/common/remote-file-system-provider';
|
|
20
|
+
|
|
21
|
+
export const LocalEnvVariablesServer = Symbol('LocalEnviromentVariableServer');
|
|
22
|
+
export const LocalRemoteFileSytemServer = Symbol('LocalRemoteFileSytemServer');
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
* provide file access to local files while connected to a remote workspace or dev container.
|
|
26
|
+
*/
|
|
27
|
+
@injectable()
|
|
28
|
+
export class LocalRemoteFileSystemProvider extends RemoteFileSystemProvider {
|
|
29
|
+
@inject(LocalRemoteFileSytemServer)
|
|
30
|
+
protected override readonly server: RpcProxy<RemoteFileSystemServer>;
|
|
31
|
+
}
|
|
@@ -17,6 +17,7 @@
|
|
|
17
17
|
import { Emitter } from '@theia/core';
|
|
18
18
|
import { inject, injectable, postConstruct } from '@theia/core/shared/inversify';
|
|
19
19
|
import { RemotePortForwardingProvider } from '../../electron-common/remote-port-forwarding-provider';
|
|
20
|
+
import { getCurrentPort } from '@theia/core/lib/electron-browser/messaging/electron-local-ws-connection-source';
|
|
20
21
|
|
|
21
22
|
export interface ForwardedPort {
|
|
22
23
|
localPort?: number;
|
|
@@ -50,7 +51,7 @@ export class PortForwardingService {
|
|
|
50
51
|
}
|
|
51
52
|
|
|
52
53
|
updatePort(port: ForwardedPort, newAdress: string): void {
|
|
53
|
-
const connectionPort =
|
|
54
|
+
const connectionPort = getCurrentPort();
|
|
54
55
|
if (!connectionPort) {
|
|
55
56
|
// if there is no open remote connection we can't forward a port
|
|
56
57
|
return;
|
|
@@ -21,6 +21,7 @@ import { RemoteStatus, RemoteStatusService } from '../electron-common/remote-sta
|
|
|
21
21
|
import { RemoteRegistry, RemoteRegistryContribution } from './remote-registry-contribution';
|
|
22
22
|
import { RemoteService } from './remote-service';
|
|
23
23
|
import { WindowService } from '@theia/core/lib/browser/window/window-service';
|
|
24
|
+
import { getLocalPort, getCurrentPort } from '@theia/core/lib/electron-browser/messaging/electron-local-ws-connection-source';
|
|
24
25
|
|
|
25
26
|
export namespace RemoteCommands {
|
|
26
27
|
export const REMOTE_SELECT: Command = {
|
|
@@ -59,7 +60,7 @@ export class RemoteFrontendContribution implements CommandContribution, Frontend
|
|
|
59
60
|
protected remoteRegistry = new RemoteRegistry();
|
|
60
61
|
|
|
61
62
|
async configure(): Promise<void> {
|
|
62
|
-
const port =
|
|
63
|
+
const port = getCurrentPort();
|
|
63
64
|
if (port) {
|
|
64
65
|
const status = await this.remoteStatusService.getStatus(Number(port));
|
|
65
66
|
await this.setStatusBar(status);
|
|
@@ -106,9 +107,9 @@ export class RemoteFrontendContribution implements CommandContribution, Frontend
|
|
|
106
107
|
}
|
|
107
108
|
|
|
108
109
|
protected async disconnectRemote(): Promise<void> {
|
|
109
|
-
const
|
|
110
|
-
const localPort = searchParams.get('localPort');
|
|
110
|
+
const localPort = getLocalPort();
|
|
111
111
|
if (localPort) {
|
|
112
|
+
const searchParams = new URLSearchParams(location.search);
|
|
112
113
|
const currentPort = searchParams.get('port');
|
|
113
114
|
this.remoteStatusService.connectionClosed(parseInt(currentPort ?? '0'));
|
|
114
115
|
this.windowService.reload({ search: { port: localPort } });
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
|
|
17
17
|
import { bindContributionProvider, CommandContribution } from '@theia/core';
|
|
18
18
|
import { ContainerModule } from '@theia/core/shared/inversify';
|
|
19
|
-
import { bindViewContribution, FrontendApplicationContribution, WidgetFactory } from '@theia/core/lib/browser';
|
|
19
|
+
import { bindViewContribution, FrontendApplicationContribution, isRemote, WidgetFactory } from '@theia/core/lib/browser';
|
|
20
20
|
import { RemoteSSHContribution } from './remote-ssh-contribution';
|
|
21
21
|
import { RemoteSSHConnectionProvider, RemoteSSHConnectionProviderPath } from '../electron-common/remote-ssh-connection-provider';
|
|
22
22
|
import { RemoteFrontendContribution } from './remote-frontend-contribution';
|
|
@@ -32,6 +32,11 @@ import { PortForwardingService } from './port-forwarding/port-forwarding-service
|
|
|
32
32
|
import { RemotePortForwardingProvider, RemoteRemotePortForwardingProviderPath } from '../electron-common/remote-port-forwarding-provider';
|
|
33
33
|
import { ServiceConnectionProvider } from '@theia/core/lib/browser/messaging/service-connection-provider';
|
|
34
34
|
import '../../src/electron-browser/style/port-forwarding-widget.css';
|
|
35
|
+
import { UserStorageContribution } from '@theia/userstorage/lib/browser/user-storage-contribution';
|
|
36
|
+
import { RemoteUserStorageContribution } from './remote-user-storage-provider';
|
|
37
|
+
import { remoteFileSystemPath, RemoteFileSystemProxyFactory, RemoteFileSystemServer } from '@theia/filesystem/lib/common/remote-file-system-provider';
|
|
38
|
+
import { LocalEnvVariablesServer, LocalRemoteFileSystemProvider, LocalRemoteFileSytemServer } from './local-backend-services';
|
|
39
|
+
import { envVariablesPath, EnvVariablesServer } from '@theia/core/lib/common/env-variables';
|
|
35
40
|
|
|
36
41
|
export default new ContainerModule((bind, _, __, rebind) => {
|
|
37
42
|
bind(RemoteFrontendContribution).toSelf().inSingletonScope();
|
|
@@ -65,4 +70,16 @@ export default new ContainerModule((bind, _, __, rebind) => {
|
|
|
65
70
|
bind(RemotePortForwardingProvider).toDynamicValue(ctx =>
|
|
66
71
|
ServiceConnectionProvider.createLocalProxy<RemotePortForwardingProvider>(ctx.container, RemoteRemotePortForwardingProviderPath)).inSingletonScope();
|
|
67
72
|
|
|
73
|
+
bind(LocalRemoteFileSytemServer).toDynamicValue(ctx =>
|
|
74
|
+
isRemote ?
|
|
75
|
+
ServiceConnectionProvider.createLocalProxy(ctx.container, remoteFileSystemPath, new RemoteFileSystemProxyFactory()) :
|
|
76
|
+
ctx.container.get(RemoteFileSystemServer));
|
|
77
|
+
bind(LocalEnvVariablesServer).toDynamicValue(ctx =>
|
|
78
|
+
isRemote ?
|
|
79
|
+
ServiceConnectionProvider.createLocalProxy<EnvVariablesServer>(ctx.container, envVariablesPath) :
|
|
80
|
+
ctx.container.get(EnvVariablesServer));
|
|
81
|
+
bind(LocalRemoteFileSystemProvider).toSelf().inSingletonScope();
|
|
82
|
+
rebind(UserStorageContribution).to(RemoteUserStorageContribution);
|
|
83
|
+
|
|
68
84
|
});
|
|
85
|
+
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
// *****************************************************************************
|
|
2
|
+
// Copyright (C) 2024 TypeFox and others.
|
|
3
|
+
//
|
|
4
|
+
// This program and the accompanying materials are made available under the
|
|
5
|
+
// terms of the Eclipse Public License v. 2.0 which is available at
|
|
6
|
+
// http://www.eclipse.org/legal/epl-2.0.
|
|
7
|
+
//
|
|
8
|
+
// This Source Code may also be made available under the following Secondary
|
|
9
|
+
// Licenses when the conditions for such availability set forth in the Eclipse
|
|
10
|
+
// Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
11
|
+
// with the GNU Classpath Exception which is available at
|
|
12
|
+
// https://www.gnu.org/software/classpath/license.html.
|
|
13
|
+
//
|
|
14
|
+
// SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-only WITH Classpath-exception-2.0
|
|
15
|
+
// *****************************************************************************
|
|
16
|
+
|
|
17
|
+
import { injectable, inject, postConstruct } from '@theia/core/shared/inversify';
|
|
18
|
+
import { FileService } from '@theia/filesystem/lib/browser/file-service';
|
|
19
|
+
import { FileSystemProvider } from '@theia/filesystem/lib/common/files';
|
|
20
|
+
import { UserStorageContribution } from '@theia/userstorage/lib/browser/user-storage-contribution';
|
|
21
|
+
import { RemoteStatusService } from '../electron-common/remote-status-service';
|
|
22
|
+
import { LocalEnvVariablesServer, LocalRemoteFileSystemProvider } from './local-backend-services';
|
|
23
|
+
import { Deferred } from '@theia/core/lib/common/promise-util';
|
|
24
|
+
import { URI } from '@theia/core';
|
|
25
|
+
import { EnvVariablesServer } from '@theia/core/lib/common/env-variables';
|
|
26
|
+
import { getCurrentPort } from '@theia/core/lib/electron-browser/messaging/electron-local-ws-connection-source';
|
|
27
|
+
|
|
28
|
+
/**
|
|
29
|
+
* This overide is to have remote connections still use settings, keymaps, etc. from the local machine.
|
|
30
|
+
*/
|
|
31
|
+
@injectable()
|
|
32
|
+
export class RemoteUserStorageContribution extends UserStorageContribution {
|
|
33
|
+
@inject(RemoteStatusService)
|
|
34
|
+
protected readonly remoteStatusService: RemoteStatusService;
|
|
35
|
+
|
|
36
|
+
@inject(LocalRemoteFileSystemProvider)
|
|
37
|
+
protected readonly localRemoteFileSystemProvider: LocalRemoteFileSystemProvider;
|
|
38
|
+
|
|
39
|
+
@inject(LocalEnvVariablesServer)
|
|
40
|
+
protected readonly localEnvironments: EnvVariablesServer;
|
|
41
|
+
|
|
42
|
+
isRemoteConnection: Deferred<boolean> = new Deferred();
|
|
43
|
+
|
|
44
|
+
@postConstruct()
|
|
45
|
+
protected init(): void {
|
|
46
|
+
const port = getCurrentPort();
|
|
47
|
+
if (port) {
|
|
48
|
+
this.remoteStatusService.getStatus(Number(port)).then(status => this.isRemoteConnection.resolve(status.alive));
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
protected override async getDelegate(service: FileService): Promise<FileSystemProvider> {
|
|
53
|
+
return await this.isRemoteConnection.promise ?
|
|
54
|
+
this.localRemoteFileSystemProvider
|
|
55
|
+
: service.activateProvider('file');
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
protected override async getCongigDirUri(): Promise<URI> {
|
|
59
|
+
return await this.isRemoteConnection.promise ?
|
|
60
|
+
new URI(await this.localEnvironments.getConfigDirUri())
|
|
61
|
+
: super.getCongigDirUri();
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
}
|