@@ -8,7 +8,7 @@ To test this:
8
8
9
9
1. build fresh Coder workspace
10
10
2. clone code-server
11
- 3. `yarn watch `
11
+ 3. `yarn build && yarn build:vscode && KEEP_MODULES=1 yarn release `
12
12
4. test built-in terminal
13
13
14
14
Index: code-server/lib/vscode/build/gulpfile.reh.js
@@ -17,14 +17,14 @@ Index: code-server/lib/vscode/build/gulpfile.reh.js
17
17
+++ code-server/lib/vscode/build/gulpfile.reh.js
18
18
@@ -125,9 +125,7 @@ const serverWithWebEntryPoints = [
19
19
];
20
-
20
+
21
21
function getNodeVersion() {
22
22
- const yarnrc = fs.readFileSync(path.join(REPO_ROOT, 'remote', '.yarnrc'), 'utf8');
23
23
- const target = /^target "(.*)"$/m.exec(yarnrc)[1];
24
24
- return target;
25
25
+ return process.versions.node;
26
26
}
27
-
27
+
28
28
const nodeVersion = getNodeVersion();
29
29
Index: code-server/lib/vscode/build/lib/node.js
30
30
===================================================================
@@ -47,13 +47,13 @@ Index: code-server/lib/vscode/build/lib/node.ts
47
47
+++ code-server/lib/vscode/build/lib/node.ts
48
48
@@ -7,9 +7,7 @@ import * as path from 'path';
49
49
import * as fs from 'fs';
50
-
50
+
51
51
const root = path.dirname(path.dirname(__dirname));
52
52
- const yarnrcPath = path.join(root, 'remote', '.yarnrc');
53
53
- const yarnrc = fs.readFileSync(yarnrcPath, 'utf8');
54
54
- const version = /^target\s+"([^"]+)"$/m.exec(yarnrc)![1];
55
55
+ const version = process.versions.node;
56
-
56
+
57
57
const platform = process.platform;
58
58
const arch = process.arch;
59
59
Index: code-server/lib/vscode/build/lib/util.js
@@ -75,16 +75,16 @@ Index: code-server/lib/vscode/build/lib/util.ts
75
75
===================================================================
76
76
--- code-server.orig/lib/vscode/build/lib/util.ts
77
77
+++ code-server/lib/vscode/build/lib/util.ts
78
- @@ -371,9 +371,7 @@ export function streamToPromise(stream:
78
+ @@ -371,9 +371,7 @@ export function streamToPromise(stream:
79
79
}
80
-
80
+
81
81
export function getElectronVersion(): string {
82
82
- const yarnrc = fs.readFileSync(path.join(root, '.yarnrc'), 'utf8');
83
83
- const target = /^target "(.*)"$/m.exec(yarnrc)![1];
84
84
- return target;
85
85
+ return process.versions.node;
86
86
}
87
-
87
+
88
88
export function acquireWebNodePaths() {
89
89
@@ -455,4 +453,3 @@ export function buildWebNodePaths(outDir
90
90
result.taskName = 'build-web-node-paths';
@@ -98,7 +98,7 @@ Index: code-server/lib/vscode/build/npm/preinstall.js
98
98
@@ -32,6 +32,13 @@ if (!/yarn[\w-.]*\.c?js$|yarnpkg$/.test(
99
99
err = true;
100
100
}
101
-
101
+
102
102
+ fs.rmSync(path.join(__dirname, '..', '..', '.yarnrc'), {
103
103
+ force: true
104
104
+ });
0 commit comments