Skip to content

Commit

Permalink
Simplify setting of process env PATH.
Browse files Browse the repository at this point in the history
  • Loading branch information
Globegitter committed May 29, 2019
1 parent 1e11a7c commit 4c0fc18
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions internal/node/node_loader.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,7 @@ var fs = require('fs');

const isWindows = /^win/i.test(process.platform);
// Ensure that node is added to the path for any subprocess calls
if (isWindows) {
process.env.PATH = `${path.dirname(process.execPath)};${process.env.PATH}`
} else {
process.env.PATH = `${path.dirname(process.execPath)}:${process.env.PATH}`
}
process.env.PATH = [path.dirname(process.execPath), process.env.PATH].join(isWindows ? ';' : ':');

const DEBUG = false;

Expand Down

0 comments on commit 4c0fc18

Please sign in to comment.