diff options
author | Kat Marchán <kzm@zkat.tech> | 2019-01-29 14:43:00 -0800 |
---|---|---|
committer | Myles Borins <mylesborins@google.com> | 2019-05-16 14:57:00 -0400 |
commit | d2413d630ccc6e75d956e44c28d2952a438c71a2 (patch) | |
tree | 115e9f3a144480b00b5d6d6df905ea85aa9bf84e /deps/npm/node_modules/npm-registry-fetch/config.js | |
parent | e880904d22e8858bed2e5d33d21a08ca0e273d64 (diff) | |
download | node-new-d2413d630ccc6e75d956e44c28d2952a438c71a2.tar.gz |
deps: upgrade npm to 6.7.0
PR-URL: https://github.com/nodejs/node/pull/25804
Reviewed-By: Myles Borins <myles.borins@gmail.com>
Diffstat (limited to 'deps/npm/node_modules/npm-registry-fetch/config.js')
-rw-r--r-- | deps/npm/node_modules/npm-registry-fetch/config.js | 24 |
1 files changed, 14 insertions, 10 deletions
diff --git a/deps/npm/node_modules/npm-registry-fetch/config.js b/deps/npm/node_modules/npm-registry-fetch/config.js index 6249f66e05..7fe5dacc94 100644 --- a/deps/npm/node_modules/npm-registry-fetch/config.js +++ b/deps/npm/node_modules/npm-registry-fetch/config.js @@ -1,12 +1,12 @@ 'use strict' const pkg = require('./package.json') -const pudding = require('figgy-pudding') +const figgyPudding = require('figgy-pudding') const silentLog = require('./silentlog.js') -const AUTH_REGEX = /^(?:.*:)?(_authToken|username|_password|password|email|always-auth|_auth|otp)$/ +const AUTH_REGEX = /^(?:.*:)?(token|_authToken|username|_password|password|email|always-auth|_auth|otp)$/ const SCOPE_REGISTRY_REGEX = /@.*:registry$/gi -const RegFetchConfig = pudding({ +module.exports = figgyPudding({ 'agent': {}, 'algorithms': {}, 'body': {}, @@ -17,8 +17,14 @@ const RegFetchConfig = pudding({ 'fetch-retry-factor': {}, 'fetch-retry-maxtimeout': {}, 'fetch-retry-mintimeout': {}, + 'force-auth': {}, + forceAuth: 'force-auth', 'gid': {}, + 'gzip': {}, 'headers': {}, + 'https-proxy': {}, + 'ignore-body': {}, + ignoreBody: 'ignore-body', 'integrity': {}, 'is-from-ci': 'isFromCI', 'isFromCI': { @@ -37,6 +43,9 @@ const RegFetchConfig = pudding({ 'log': { default: silentLog }, + 'map-json': 'mapJson', + 'mapJSON': 'mapJson', + 'mapJson': {}, 'max-sockets': 'maxsockets', 'maxsockets': { default: 12 @@ -45,6 +54,7 @@ const RegFetchConfig = pudding({ 'method': { default: 'GET' }, + 'no-proxy': {}, 'noproxy': {}, 'npm-session': 'npmSession', 'npmSession': {}, @@ -54,7 +64,7 @@ const RegFetchConfig = pudding({ 'prefer-online': {}, 'projectScope': {}, 'project-scope': 'projectScope', - 'Promise': {}, + 'Promise': {default: () => Promise}, 'proxy': {}, 'query': {}, 'refer': {}, @@ -86,9 +96,3 @@ const RegFetchConfig = pudding({ return key.match(AUTH_REGEX) || key.match(SCOPE_REGISTRY_REGEX) } }) - -module.exports = config -function config (opts) { - opts = opts || {} - return RegFetchConfig(opts, opts.config) -} |