diff options
Diffstat (limited to 'node_modules/node-gyp/lib/install.js')
-rw-r--r-- | node_modules/node-gyp/lib/install.js | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/node_modules/node-gyp/lib/install.js b/node_modules/node-gyp/lib/install.js index f68cd7fd6..c919c1058 100644 --- a/node_modules/node-gyp/lib/install.js +++ b/node_modules/node-gyp/lib/install.js @@ -11,6 +11,7 @@ const request = require('request') const mkdir = require('mkdirp') const processRelease = require('./process-release') const win = process.platform === 'win32' +const getProxyFromURI = require('./proxy') function install (fs, gyp, argv, callback) { var release = processRelease(argv, gyp, process.version, process.release) @@ -410,10 +411,7 @@ function download (gyp, env, url) { } // basic support for a proxy server - var proxyUrl = gyp.opts.proxy || - env.http_proxy || - env.HTTP_PROXY || - env.npm_config_proxy + var proxyUrl = getProxyFromURI(gyp, env, url) if (proxyUrl) { if (/^https?:\/\//i.test(proxyUrl)) { log.verbose('download', 'using proxy url: "%s"', proxyUrl) |