summaryrefslogtreecommitdiff
path: root/deps/npm/node_modules/npm-registry-fetch/config.js
diff options
context:
space:
mode:
Diffstat (limited to 'deps/npm/node_modules/npm-registry-fetch/config.js')
-rw-r--r--deps/npm/node_modules/npm-registry-fetch/config.js24
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)
-}