chore(subprocess-local): bump node-pty beta
This commit is contained in:
32
patches/node-pty@1.2.0-beta.15.patch
Normal file
32
patches/node-pty@1.2.0-beta.15.patch
Normal file
@@ -0,0 +1,32 @@
|
||||
diff --git a/lib/unixTerminal.js b/lib/unixTerminal.js
|
||||
index 6966d24..18f1d25 100644
|
||||
--- a/lib/unixTerminal.js
|
||||
+++ b/lib/unixTerminal.js
|
||||
@@ -28,10 +28,23 @@ var terminal_1 = require("./terminal");
|
||||
var utils_1 = require("./utils");
|
||||
var native = (0, utils_1.loadNativeModule)('pty');
|
||||
var pty = native.module;
|
||||
-var helperPath = native.dir + '/spawn-helper';
|
||||
-helperPath = path.resolve(__dirname, helperPath);
|
||||
-helperPath = helperPath.replace('app.asar', 'app.asar.unpacked');
|
||||
-helperPath = helperPath.replace('node_modules.asar', 'node_modules.asar.unpacked');
|
||||
+// A current external embedded-runtime consumer supplies a non-sibling helper.
|
||||
+var helperPath = process.env.DSH_NODE_PTY_SPAWN_HELPER;
|
||||
+if (helperPath) {
|
||||
+ helperPath = path.resolve(helperPath);
|
||||
+}
|
||||
+else {
|
||||
+ var executableSibling = process.execPath + '-spawn-helper';
|
||||
+ if (fs.existsSync(executableSibling)) {
|
||||
+ helperPath = executableSibling;
|
||||
+ }
|
||||
+ else {
|
||||
+ helperPath = native.dir + '/spawn-helper';
|
||||
+ helperPath = path.resolve(__dirname, helperPath);
|
||||
+ helperPath = helperPath.replace('app.asar', 'app.asar.unpacked');
|
||||
+ helperPath = helperPath.replace('node_modules.asar', 'node_modules.asar.unpacked');
|
||||
+ }
|
||||
+}
|
||||
var DEFAULT_FILE = 'sh';
|
||||
var DEFAULT_NAME = 'xterm';
|
||||
var DESTROY_SOCKET_TIMEOUT_MS = 200;
|
||||
Reference in New Issue
Block a user