Skip to content

Commit

Permalink
Merge pull request #81 from sdovenor/replace-fix
Browse files Browse the repository at this point in the history
Fix replace for nodistPrefix and envVersion

fixes #79
  • Loading branch information
marcelklehr committed Apr 13, 2015
2 parents c46bef5 + 44cff20 commit ab9a456
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions cli.js
Expand Up @@ -56,10 +56,10 @@ process.title = 'nodist';
if(!process.env['NODIST_PREFIX']) abort('Please set the path to the nodist directory in the NODIST_PREFIX environment variable.')

var distUrl = 'http://nodejs.org/dist'
var nodistPrefix = process.env['NODIST_PREFIX'].replace('"', '')
var nodistPrefix = process.env['NODIST_PREFIX'].replace(/"/g, '')
var proxy = (process.env.HTTP_PROXY || process.env.http_proxy || process.env.HTTPS_PROXY || process.env.https_proxy || "");
var wantX64 = process.env['NODIST_X64']!=null? process.env['NODIST_X64']==1 : (process.arch=='x64'); // if the env var is set, use its value, other wise use process.arch
var envVersion = process.env['NODIST_VERSION']? process.env['NODIST_VERSION'].replace('"', '') : process.env['NODIST_VERSION']
var envVersion = process.env['NODIST_VERSION']? process.env['NODIST_VERSION'].replace(/"/g, '') : process.env['NODIST_VERSION']

// Create a nodist instance
var n = new nodist(
Expand Down Expand Up @@ -279,4 +279,4 @@ if (command.match(/^global$/i) && argv[1] || argv[0] && !argv[1]) {
// HELP display help for unknown cli parameters
{
help();
}
}

0 comments on commit ab9a456

Please sign in to comment.