Skip to content

Commit

Permalink
testing
Browse files Browse the repository at this point in the history
  • Loading branch information
TheTechsTech committed Feb 5, 2018
1 parent f8492b6 commit e5d2de1
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions util/run.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,13 @@ var utilSwitches = require('./switches');
*/
module.exports = function (command, switches) {
return when.promise(function (fulfill, reject, progress) {
// add platform binary to environment path
var envPath = process.env.path;
if (envPath.indexOf('7za') < 0) {
var macos = (process.platform == "darwin") ? require('macos-release').version : '';
var pathto7z = path.join(__dirname, "..","binaries", macos == '' ? process.platform : process.platform, macos );
process.env.path += (envPath[envPath.length -1] === ';') ? pathto7z : ';' + pathto7z;
}

// Parse the command variable. If the command is not a string reject the
// Promise. Otherwise transform the command into two variables: the command
Expand Down

0 comments on commit e5d2de1

Please sign in to comment.