diff -Nru nodejs-0.11.14/AUTHORS nodejs-0.11.15/AUTHORS
--- nodejs-0.11.14/AUTHORS 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/AUTHORS 2015-01-20 21:22:17.000000000 +0000
@@ -568,3 +568,15 @@
Jackson Tian
Tristan Berger
Mathias Schreck
+Steven R. Loomis
+Matthew Fitzsimmons
+Swaagie
+Emmanuel Odeke
+Eric Mill
+Brendan Ashworth
+Alejandro Oviedo
+pkcs
+Saúl Ibarra Corretgé
+silverwind
+Steven R. Loomis
+James M Snell
diff -Nru nodejs-0.11.14/benchmark/misc/module-loader.js nodejs-0.11.15/benchmark/misc/module-loader.js
--- nodejs-0.11.14/benchmark/misc/module-loader.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/benchmark/misc/module-loader.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,72 @@
+// Copyright Joyent, Inc. and other Node contributors.
+//
+// Permission is hereby granted, free of charge, to any person obtaining a
+// copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to permit
+// persons to whom the Software is furnished to do so, subject to the
+// following conditions:
+//
+// The above copyright notice and this permission notice shall be included
+// in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
+// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
+// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
+// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
+// USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+
+var fs = require('fs');
+var path = require('path');
+var common = require('../common.js');
+var packageJson = '{"main": "index.js"}';
+
+var tmpDirectory = path.join(__dirname, '..', 'tmp');
+var benchmarkDirectory = path.join(tmpDirectory, 'nodejs-benchmark-module');
+
+var bench = common.createBenchmark(main, {
+ thousands: [50]
+});
+
+function main(conf) {
+ rmrf(tmpDirectory);
+ try { fs.mkdirSync(tmpDirectory); } catch (e) {}
+ try { fs.mkdirSync(benchmarkDirectory); } catch (e) {}
+
+ var n = +conf.thousands * 1e3;
+ for (var i = 0; i <= n; i++) {
+ fs.mkdirSync(benchmarkDirectory + i);
+ fs.writeFileSync(benchmarkDirectory + i + '/package.json', '{"main": "index.js"}');
+ fs.writeFileSync(benchmarkDirectory + i + '/index.js', 'module.exports = "";');
+ }
+
+ measure(n);
+}
+
+function measure(n) {
+ bench.start();
+ for (var i = 0; i <= n; i++) {
+ require(benchmarkDirectory + i);
+ }
+ bench.end(n / 1e3);
+}
+
+function rmrf(location) {
+ if (fs.existsSync(location)) {
+ var things = fs.readdirSync(location);
+ things.forEach(function(thing) {
+ var cur = path.join(location, thing),
+ isDirectory = fs.statSync(cur).isDirectory();
+ if (isDirectory) {
+ rmrf(cur);
+ return;
+ }
+ fs.unlinkSync(cur);
+ });
+ fs.rmdirSync(location);
+ }
+}
diff -Nru nodejs-0.11.14/ChangeLog nodejs-0.11.15/ChangeLog
--- nodejs-0.11.14/ChangeLog 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/ChangeLog 2015-01-20 21:22:17.000000000 +0000
@@ -1,4 +1,143 @@
-2014.09.24, Version 0.11.14 (Unstable)
+2015.01.20, Version 0.11.15 (Unstable)
+
+* v8: Upgrade to 3.28.73
+
+* uv: Upgrade to 1.0.2
+
+* npm: Upgrade to v2.1.6
+
+* uv: float patch to revert tty breakage (Trevor Norris)
+
+* v8: re-implement debugger-agent (Fedor Indutny)
+
+* v8: apply floating irhydra patch (Fedor Indutny)
+
+* v8: fix postmortem-metadata generator (Refael Ackermann)
+
+* debugger: fix unhandled error in setBreakpoint (Miroslav Bajtoš)
+
+* async-wrap: add event hooks (Trevor Norris)
+
+* async-wrap: expose async-wrap as binding (Trevor Norris)
+
+* buffer, doc: misc. fix and cleanup (Trevor Norris)
+
+* buffer: add generic functions for (u)int ops (Yazhong Liu)
+
+* buffer: fix and cleanup fill() (Trevor Norris)
+
+* buffer: mv floating point read/write checks to JS (Trevor Norris)
+
+* build, i18n: improve Intl build, add "--with-intl" (Steven R. Loomis)
+
+* build: add small-icu support for binary packages (Julien Gilli)
+
+* build: do not generate support for libuv's probes (Julien Gilli)
+
+* build: i18n: add icu config options (Steven R. Loomis)
+
+* build: i18n: support little-endian machines (Steven Loomis)
+
+* build: vcbuild fix "The input line is too long." (Alexis Campailla)
+
+* child_process: improve spawn() argument handling (cjihrig)
+
+* cluster: avoid race enabling debugger in worker (Timothy J Fontaine)
+
+* cluster: cluster.disconnect() should check status (Sam Roberts)
+
+* cluster: do not signal children in debug mode (Fedor Indutny)
+
+* cluster: don't assert if worker has no handles (Sam Roberts)
+
+* core: fix usage of uv_cwd (Saúl Ibarra Corretgé)
+
+* core: replace uv_fs_readdir with uv_fs_scandir (Saúl Ibarra Corretgé)
+
+* crypto: createDiffieHellman throw for bad args (Trevor Norris)
+
+* crypto: lower RSS usage for TLSCallbacks (Fedor Indutny)
+
+* crypto: store thread id as pointer-sized (Alexis Campailla)
+
+* dns: propagate domain for c-ares methods (Chris Dickinson)
+
+* fs: fix symlink error message (Vladimir Kurchatkin)
+
+* http: Improve _addHeaderLines method (Jackson Tian)
+
+* http: cleanup setHeader() (Trevor Norris)
+
+* http: rename flush to flushHeaders (Timothy J Fontaine)
+
+* lib,src: fix spawnSync ignoring its 'env' option (Juanjo)
+
+* modules: adding load linked modules feature (Thorsten Lorenz)
+
+* net: Make server.connections un-enumerable (Patrick Mooney)
+
+* net: add pauseOnConnect option to createServer() (cjihrig)
+
+* net: make connect() input validation synchronous (cjihrig)
+
+* node: avoid automatic microtask runs (Vladimir Kurchatkin)
+
+* node: fix throws before timer module is loaded (Trevor Norris)
+
+* openssl: fix keypress requirement in apps on win32 (Fedor Indutny)
+
+* path: added parse() and format() functions (Rory Bradford)
+
+* path: allow calling platform specific methods (Timothy J Fontaine)
+
+* path: don't lower-cases drive letters (Bert Belder)
+
+* path: refactor normalizeArray() (Nathan Woltman)
+
+* process: pid can be a string in process.kill() (Sam Roberts)
+
+* readline: fix performance issue when large line (Jicheng Li)
+
+* readline: should not require an output stream. (Julien Gilli)
+
+* smalloc: check if obj has external data (Vladimir Kurchatkin)
+
+* smalloc: don't allow to dispose typed arrays (Vladimir Kurchatkin)
+
+* smalloc: fix bad assert for zero length data (Trevor Norris)
+
+* smalloc: fix copyOnto optimization (Vladimir Kurchatkin)
+
+* src: all wrap's now use actual FunctionTemplate (Trevor Norris)
+
+* src: fix VC++ warning C4244 (Rasmus Christian Pedersen)
+
+* src: remove Async Listener (Trevor Norris)
+
+* stream: switch _writableState.buffer to queue (Chris Dickinson)
+
+* streams: make setDefaultEncoding() throw (Brian White)
+
+* streams: set default encoding for writable streams (Johnny Ray)
+
+* tls: remove tls.createSecurePair code deprecation (Jackson Tian)
+
+* tls_wrap: ignore ZERO_RETURN after close_notify (Fedor Indutny)
+
+* url: change hostname regex to negate invalid chars (Jonathan Johnson)
+
+* url: fixed encoding for slash switching emulation. (Evan Rutledge Borden)
+
+* url: improve parsing speed (CGavrila)
+
+* url: make query() consistent (Gabriel Wicke)
+
+* url: support `path` for url.format (Yazhong Liu)
+
+* util: add es6 Symbol support for `util.inspect` (gyson)
+
+
+2014.09.24, Version 0.11.14 (Unstable), 902090af5375e497dded310575f19de5328a9bbc
* uv: Upgrade to v1.0.0-rc1
@@ -787,7 +926,60 @@
* console: `console.dir()` bypasses inspect() methods (Nathan Rajlich)
-2014.09.16, Version 0.10.32 (Stable)
+2014.12.22, Version 0.10.35 (Stable)
+
+* tls: re-add 1024-bit SSL certs removed by f9456a2 (Chris Dickinson)
+
+* timers: don't close interval timers when unrefd (Julien Gilli)
+
+* timers: don't mutate unref list while iterating it (Julien Gilli)
+
+
+2014.12.17, Version 0.10.34 (Stable), 52795f8fcc2de77cf997e671ea58614e5e425dfe
+
+* uv: update to v0.10.30
+
+* zlib: upgrade to v1.2.8
+
+* child_process: check execFile args is an array (Sam Roberts)
+
+* child_process: check fork args is an array (Sam Roberts)
+
+* crypto: update root certificates (Ben Noordhuis)
+
+* domains: fix issues with abort on uncaught (Julien Gilli)
+
+* timers: Avoid linear scan in _unrefActive. (Julien Gilli)
+
+* timers: fix unref() memory leak (Trevor Norris)
+
+* v8: add api for aborting on uncaught exception (Julien Gilli)
+
+* debugger: fix when using "use strict" (Julien Gilli)
+
+
+2014.10.20, Version 0.10.33 (Stable), 8d045a30e95602b443eb259a5021d33feb4df079
+
+* openssl: Update to 1.0.1j (Addressing multiple CVEs)
+
+* uv: Update to v0.10.29
+
+* child_process: properly support optional args (cjihrig)
+
+* crypto: Disable autonegotiation for SSLv2/3 by default (Fedor Indutny,
+ Timothy J Fontaine, Alexis Campailla)
+
+ This is a behavior change, by default we will not allow the negotiation to
+ SSLv2 or SSLv3. If you want this behavior, run Node.js with either
+ `--enable-ssl2` or `--enable-ssl3` respectively.
+
+ This does not change the behavior for users specifically requesting
+ `SSLv2_method` or `SSLv3_method`. While this behavior is not advised, it is
+ assumed you know what you're doing since you're specifically asking to use
+ these methods.
+
+
+2014.09.16, Version 0.10.32 (Stable), 0fe0d121551593c23a565db8397f85f17bb0f00e
* npm: Update to 1.4.28
@@ -839,7 +1031,7 @@
* deps: backport 4ed5fde4f from v8 upstream (Fedor Indutny)
-* deps: cherry-pick eca441b2 from OpenSSL (Fedor Indutny)
+*
* lib: remove and restructure calls to isNaN() (cjihrig)
diff -Nru nodejs-0.11.14/common.gypi nodejs-0.11.15/common.gypi
--- nodejs-0.11.14/common.gypi 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/common.gypi 2015-01-20 21:22:17.000000000 +0000
@@ -26,10 +26,10 @@
}],
['GENERATOR == "ninja" or OS== "mac"', {
'OBJ_DIR': '<(PRODUCT_DIR)/obj',
- 'V8_BASE': '<(PRODUCT_DIR)/libv8_base.<(target_arch).a',
+ 'V8_BASE': '<(PRODUCT_DIR)/libv8_base.a',
}, {
'OBJ_DIR': '<(PRODUCT_DIR)/obj.target',
- 'V8_BASE': '<(PRODUCT_DIR)/obj.target/deps/v8/tools/gyp/libv8_base.<(target_arch).a',
+ 'V8_BASE': '<(PRODUCT_DIR)/obj.target/deps/v8/tools/gyp/libv8_base.a',
}],
],
},
diff -Nru nodejs-0.11.14/configure nodejs-0.11.15/configure
--- nodejs-0.11.14/configure 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/configure 2015-01-20 21:22:17.000000000 +0000
@@ -6,6 +6,8 @@
import shlex
import subprocess
import sys
+import shutil
+import string
CC = os.environ.get('CC', 'cc')
@@ -13,6 +15,10 @@
sys.path.insert(0, os.path.join(root_dir, 'tools', 'gyp', 'pylib'))
from gyp.common import GetFlavor
+# imports in tools/configure.d
+sys.path.insert(0, os.path.join(root_dir, 'tools', 'configure.d'))
+import nodedownload
+
# parse our options
parser = optparse.OptionParser()
@@ -236,21 +242,36 @@
dest='with_etw',
help='build with ETW (default is true on Windows)')
+parser.add_option('--download',
+ action='store',
+ dest='download_list',
+ help=nodedownload.help())
+
parser.add_option('--with-icu-path',
action='store',
dest='with_icu_path',
help='Path to icu.gyp (ICU i18n, Chromium version only.)')
+parser.add_option('--with-icu-locales',
+ action='store',
+ dest='with_icu_locales',
+ help='Comma-separated list of locales for "small-icu". Default: "root,en". "root" is assumed.')
+
+parser.add_option('--with-intl',
+ action='store',
+ dest='with_intl',
+ help='Intl mode: none, full-icu, small-icu (default is none)')
+
+parser.add_option('--with-icu-source',
+ action='store',
+ dest='with_icu_source',
+ help='Intl mode: optional local path to icu/ dir, or path/URL of icu source archive.')
+
parser.add_option('--with-perfctr',
action='store_true',
dest='with_perfctr',
help='build with performance counters (default is true on Windows)')
-parser.add_option('--with-sslv2',
- action='store_true',
- dest='with_sslv2',
- help='enable SSL v2')
-
parser.add_option('--without-dtrace',
action='store_true',
dest='without_dtrace',
@@ -282,6 +303,16 @@
dest='without_ssl',
help='build without SSL')
+parser.add_option('--without-ssl2',
+ action='store_true',
+ dest='ssl2',
+ help='Disable SSL v2')
+
+parser.add_option('--without-ssl3',
+ action='store_true',
+ dest='ssl3',
+ help='Disable SSL v3')
+
parser.add_option('--xcode',
action='store_true',
dest='use_xcode',
@@ -289,6 +320,8 @@
(options, args) = parser.parse_args()
+# set up auto-download list
+auto_downloads = nodedownload.parse(options.download_list)
def b(value):
"""Returns the string 'true' if value is truthy, 'false' otherwise."""
@@ -640,11 +673,12 @@
if options.without_ssl:
return
- # OpenSSL uses `#ifndef OPENSSL_NO_SSL2` checks so only define the
- # macro when we want to _disable_ SSL2.
- if not options.with_sslv2:
+ if options.ssl2:
o['defines'] += ['OPENSSL_NO_SSL2=1']
+ if options.ssl3:
+ o['defines'] += ['OPENSSL_NO_SSL3=1']
+
if options.shared_openssl:
(libs, cflags) = pkg_config('openssl') or ('-lssl -lcrypto', '')
@@ -686,13 +720,259 @@
print('ctrpp not found in WinSDK path--using pre-gen files '
'from tools/msvs/genfiles.')
+def write(filename, data):
+ filename = os.path.join(root_dir, filename)
+ print 'creating ', filename
+ f = open(filename, 'w+')
+ f.write(data)
+
+do_not_edit = '# Do not edit. Generated by the configure script.\n'
+
+def glob_to_var(dir_base, dir_sub):
+ list = []
+ dir_all = os.path.join(dir_base, dir_sub)
+ files = os.walk(dir_all)
+ for ent in files:
+ (path, dirs, files) = ent
+ for file in files:
+ if file.endswith('.cpp') or file.endswith('.c') or file.endswith('.h'):
+ list.append('%s/%s' % (dir_sub, file))
+ break
+ return list
+
+def configure_intl(o):
+ icus = [
+ {
+ 'url': 'http://download.icu-project.org/files/icu4c/54.1/icu4c-54_1-src.zip',
+ # from https://ssl.icu-project.org/files/icu4c/54.1/icu4c-src-54_1.md5:
+ 'md5': '6b89d60e2f0e140898ae4d7f72323bca',
+ },
+ ]
+ def icu_download(path):
+ # download ICU, if needed
+ for icu in icus:
+ url = icu['url']
+ md5 = icu['md5']
+ local = url.split('/')[-1]
+ targetfile = os.path.join(root_dir, 'deps', local)
+ if not os.path.isfile(targetfile):
+ if nodedownload.candownload(auto_downloads, "icu"):
+ nodedownload.retrievefile(url, targetfile)
+ else:
+ print ' Re-using existing %s' % targetfile
+ if os.path.isfile(targetfile):
+ sys.stdout.write(' Checking file integrity with MD5:\r')
+ gotmd5 = nodedownload.md5sum(targetfile)
+ print ' MD5: %s %s' % (gotmd5, targetfile)
+ if (md5 == gotmd5):
+ return targetfile
+ else:
+ print ' Expected: %s *MISMATCH*' % md5
+ print '\n ** Corrupted ZIP? Delete %s to retry download.\n' % targetfile
+ return None
+ icu_config = {
+ 'variables': {}
+ }
+ icu_config_name = 'icu_config.gypi'
+ def write_config(data, name):
+ return
+
+ # write an empty file to start with
+ write(icu_config_name, do_not_edit +
+ pprint.pformat(icu_config, indent=2) + '\n')
+
+ # always set icu_small, node.gyp depends on it being defined.
+ o['variables']['icu_small'] = b(False)
-def configure_icu(o):
+ with_intl = options.with_intl
+ with_icu_source = options.with_icu_source
have_icu_path = bool(options.with_icu_path)
- o['variables']['v8_enable_i18n_support'] = int(have_icu_path)
- if have_icu_path:
+ if have_icu_path and with_intl:
+ print 'Error: Cannot specify both --with-icu-path and --with-intl'
+ sys.exit(1)
+ elif have_icu_path:
+ # Chromium .gyp mode: --with-icu-path
+ o['variables']['v8_enable_i18n_support'] = 1
+ # use the .gyp given
o['variables']['icu_gyp_path'] = options.with_icu_path
-
+ return
+ # --with-intl=
+ # set the default
+ if with_intl is None:
+ with_intl = 'none' # The default mode of Intl
+ # sanity check localelist
+ if options.with_icu_locales and (with_intl != 'small-icu'):
+ print 'Error: --with-icu-locales only makes sense with --with-intl=small-icu'
+ sys.exit(1)
+ if with_intl == 'none' or with_intl is None:
+ o['variables']['v8_enable_i18n_support'] = 0
+ return # no Intl
+ elif with_intl == 'small-icu':
+ # small ICU (English only)
+ o['variables']['v8_enable_i18n_support'] = 1
+ o['variables']['icu_small'] = b(True)
+ with_icu_locales = options.with_icu_locales
+ if not with_icu_locales:
+ with_icu_locales = 'root,en'
+ locs = set(with_icu_locales.split(','))
+ locs.add('root') # must have root
+ o['variables']['icu_locales'] = string.join(locs,',')
+ elif with_intl == 'full-icu':
+ # full ICU
+ o['variables']['v8_enable_i18n_support'] = 1
+ elif with_intl == 'system-icu':
+ # ICU from pkg-config.
+ o['variables']['v8_enable_i18n_support'] = 1
+ pkgicu = pkg_config('icu-i18n')
+ if not pkgicu:
+ print 'Error: could not load pkg-config data for "icu-i18n".'
+ print 'See above errors or the README.md.'
+ sys.exit(1)
+ (libs, cflags) = pkgicu
+ o['libraries'] += libs.split()
+ o['cflags'] += cflags.split()
+ # use the "system" .gyp
+ o['variables']['icu_gyp_path'] = 'tools/icu/icu-system.gyp'
+ return
+ else:
+ print 'Error: unknown value --with-intl=%s' % with_intl
+ sys.exit(1)
+ # Note: non-ICU implementations could use other 'with_intl'
+ # values.
+
+ # this is just the 'deps' dir. Used for unpacking.
+ icu_parent_path = os.path.join(root_dir, 'deps')
+
+ # The full path to the ICU source directory.
+ icu_full_path = os.path.join(icu_parent_path, 'icu')
+
+ # icu-tmp is used to download and unpack the ICU tarball.
+ icu_tmp_path = os.path.join(icu_parent_path, 'icu-tmp')
+
+ # --with-icu-source processing
+ # first, check that they didn't pass --with-icu-source=deps/icu
+ if with_icu_source and os.path.abspath(icu_full_path) == os.path.abspath(with_icu_source):
+ print 'Ignoring redundant --with-icu-source=%s' % (with_icu_source)
+ with_icu_source = None
+ # if with_icu_source is still set, try to use it.
+ if with_icu_source:
+ if os.path.isdir(icu_full_path):
+ print 'Deleting old ICU source: %s' % (icu_full_path)
+ shutil.rmtree(icu_full_path)
+ # now, what path was given?
+ if os.path.isdir(with_icu_source):
+ # it's a path. Copy it.
+ print '%s -> %s' % (with_icu_source, icu_full_path)
+ shutil.copytree(with_icu_source, icu_full_path)
+ else:
+ # could be file or URL.
+ # Set up temporary area
+ if os.path.isdir(icu_tmp_path):
+ shutil.rmtree(icu_tmp_path)
+ os.mkdir(icu_tmp_path)
+ icu_tarball = None
+ if os.path.isfile(with_icu_source):
+ # it's a file. Try to unpack it.
+ icu_tarball = with_icu_source
+ else:
+ # Can we download it?
+ local = os.path.join(icu_tmp_path, with_icu_source.split('/')[-1]) # local part
+ icu_tarball = nodedownload.retrievefile(with_icu_source, local)
+ # continue with "icu_tarball"
+ nodedownload.unpack(icu_tarball, icu_tmp_path)
+ # Did it unpack correctly? Should contain 'icu'
+ tmp_icu = os.path.join(icu_tmp_path, 'icu')
+ if os.path.isdir(tmp_icu):
+ os.rename(tmp_icu, icu_full_path)
+ shutil.rmtree(icu_tmp_path)
+ else:
+ print ' Error: --with-icu-source=%s did not result in an "icu" dir.' % with_icu_source
+ shutil.rmtree(icu_tmp_path)
+ sys.exit(1)
+
+ # ICU mode. (icu-generic.gyp)
+ byteorder = sys.byteorder
+ o['variables']['icu_gyp_path'] = 'tools/icu/icu-generic.gyp'
+ # ICU source dir relative to root
+ o['variables']['icu_path'] = icu_full_path
+ if not os.path.isdir(icu_full_path):
+ print '* ECMA-402 (Intl) support didn\'t find ICU in %s..' % (icu_full_path)
+ # can we download (or find) a zipfile?
+ localzip = icu_download(icu_full_path)
+ if localzip:
+ nodedownload.unpack(localzip, icu_parent_path)
+ if not os.path.isdir(icu_full_path):
+ print ' Cannot build Intl without ICU in %s.' % (icu_full_path)
+ print ' (Fix, or disable with "--with-intl=none" )'
+ sys.exit(1)
+ else:
+ print '* Using ICU in %s' % (icu_full_path)
+ # Now, what version of ICU is it? We just need the "major", such as 54.
+ # uvernum.h contains it as a #define.
+ uvernum_h = os.path.join(icu_full_path, 'source/common/unicode/uvernum.h')
+ if not os.path.isfile(uvernum_h):
+ print ' Error: could not load %s - is ICU installed?' % uvernum_h
+ sys.exit(1)
+ icu_ver_major = None
+ matchVerExp = r'^\s*#define\s+U_ICU_VERSION_SHORT\s+"([^"]*)".*'
+ match_version = re.compile(matchVerExp)
+ for line in open(uvernum_h).readlines():
+ m = match_version.match(line)
+ if m:
+ icu_ver_major = m.group(1)
+ if not icu_ver_major:
+ print ' Could not read U_ICU_VERSION_SHORT version from %s' % uvernum_h
+ sys.exit(1)
+ icu_endianness = sys.byteorder[0]; # TODO(srl295): EBCDIC should be 'e'
+ o['variables']['icu_ver_major'] = icu_ver_major
+ o['variables']['icu_endianness'] = icu_endianness
+ icu_data_file_l = 'icudt%s%s.dat' % (icu_ver_major, 'l')
+ icu_data_file = 'icudt%s%s.dat' % (icu_ver_major, icu_endianness)
+ # relative to configure
+ icu_data_path = os.path.join(icu_full_path,
+ 'source/data/in',
+ icu_data_file_l)
+ # relative to dep..
+ icu_data_in = os.path.join('../../deps/icu/source/data/in', icu_data_file_l)
+ if not os.path.isfile(icu_data_path) and icu_endianness != 'l':
+ # use host endianness
+ icu_data_path = os.path.join(icu_full_path,
+ 'source/data/in',
+ icu_data_file)
+ # relative to dep..
+ icu_data_in = os.path.join('icu/source/data/in',
+ icu_data_file)
+ # this is the input '.dat' file to use .. icudt*.dat
+ # may be little-endian if from a icu-project.org tarball
+ o['variables']['icu_data_in'] = icu_data_in
+ # this is the icudt*.dat file which node will be using (platform endianness)
+ o['variables']['icu_data_file'] = icu_data_file
+ if not os.path.isfile(icu_data_path):
+ print ' Error: ICU prebuilt data file %s does not exist.' % icu_data_path
+ print ' See the README.md.'
+ # .. and we're not about to build it from .gyp!
+ sys.exit(1)
+ # map from variable name to subdirs
+ icu_src = {
+ 'stubdata': 'stubdata',
+ 'common': 'common',
+ 'i18n': 'i18n',
+ 'io': 'io',
+ 'tools': 'tools/toolutil',
+ 'genccode': 'tools/genccode',
+ 'genrb': 'tools/genrb',
+ 'icupkg': 'tools/icupkg',
+ }
+ # this creates a variable icu_src_XXX for each of the subdirs
+ # with a list of the src files to use
+ for i in icu_src:
+ var = 'icu_src_%s' % i
+ path = '../../deps/icu/source/%s' % icu_src[i]
+ icu_config['variables'][var] = glob_to_var('tools/icu', path)
+ # write updated icu_config.gypi with a bunch of paths
+ write(icu_config_name, do_not_edit +
+ pprint.pformat(icu_config, indent=2) + '\n')
+ return # end of configure_intl
# determine the "flavor" (operating system) we're building for,
# leveraging gyp's GetFlavor function
@@ -717,7 +997,7 @@
configure_v8(output)
configure_openssl(output)
configure_winsdk(output)
-configure_icu(output)
+configure_intl(output)
configure_fullystatic(output)
# variables should be a root level element,
@@ -730,13 +1010,7 @@
}
pprint.pprint(output, indent=2)
-def write(filename, data):
- filename = os.path.join(root_dir, filename)
- print 'creating ', filename
- f = open(filename, 'w+')
- f.write(data)
-
-write('config.gypi', '# Do not edit. Generated by the configure script.\n' +
+write('config.gypi', do_not_edit +
pprint.pformat(output, indent=2) + '\n')
config = {
@@ -767,4 +1041,4 @@
gyp_args += args
-subprocess.call(gyp_args)
+sys.exit(subprocess.call(gyp_args))
diff -Nru nodejs-0.11.14/debian/changelog nodejs-0.11.15/debian/changelog
--- nodejs-0.11.14/debian/changelog 2014-10-23 20:27:54.000000000 +0000
+++ nodejs-0.11.15/debian/changelog 2015-01-21 18:54:27.000000000 +0000
@@ -1,3 +1,9 @@
+nodejs (0.11.15-1chl1~precise1) precise; urgency=low
+
+ * 0.11.15 (devel) release.
+
+ -- Chris Lea Wed, 21 Jan 2015 10:52:28 -0800
+
nodejs (0.11.14-1chl1~precise1) precise; urgency=low
* 0.11.14 (devel) release.
diff -Nru nodejs-0.11.14/deps/debugger-agent/debugger-agent.gyp nodejs-0.11.15/deps/debugger-agent/debugger-agent.gyp
--- nodejs-0.11.14/deps/debugger-agent/debugger-agent.gyp 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/debugger-agent/debugger-agent.gyp 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,24 @@
+{
+ "targets": [{
+ "target_name": "debugger-agent",
+ "type": "<(library)",
+ "include_dirs": [
+ "src",
+ "include",
+ "../v8/include",
+ "../uv/include",
+
+ # Private node.js folder and stuff needed to include from it
+ "../../src",
+ "../cares/include",
+ ],
+ "direct_dependent_settings": {
+ "include_dirs": [
+ "include",
+ ],
+ },
+ "sources": [
+ "src/agent.cc",
+ ],
+ }],
+}
diff -Nru nodejs-0.11.14/deps/debugger-agent/include/debugger-agent.h nodejs-0.11.15/deps/debugger-agent/include/debugger-agent.h
--- nodejs-0.11.14/deps/debugger-agent/include/debugger-agent.h 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/debugger-agent/include/debugger-agent.h 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,109 @@
+// Copyright Fedor Indutny and other Node contributors.
+//
+// Permission is hereby granted, free of charge, to any person obtaining a
+// copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to permit
+// persons to whom the Software is furnished to do so, subject to the
+// following conditions:
+//
+// The above copyright notice and this permission notice shall be included
+// in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
+// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
+// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
+// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
+// USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+#ifndef DEPS_DEBUGGER_AGENT_INCLUDE_DEBUGGER_AGENT_H_
+#define DEPS_DEBUGGER_AGENT_INCLUDE_DEBUGGER_AGENT_H_
+
+#include "uv.h"
+#include "v8.h"
+#include "v8-debug.h"
+
+namespace node {
+
+// Forward declaration
+class Environment;
+
+namespace debugger {
+
+// Forward declaration
+class AgentMessage;
+
+class Agent {
+ public:
+ explicit Agent(node::Environment* env);
+ ~Agent();
+
+ typedef void (*DispatchHandler)(node::Environment* env);
+
+ // Start the debugger agent thread
+ bool Start(int port, bool wait);
+ // Listen for debug events
+ void Enable();
+ // Stop the debugger agent
+ void Stop();
+
+ inline void set_dispatch_handler(DispatchHandler handler) {
+ dispatch_handler_ = handler;
+ }
+
+ inline node::Environment* parent_env() const { return parent_env_; }
+ inline node::Environment* child_env() const { return child_env_; }
+
+ protected:
+ void InitAdaptor(Environment* env);
+
+ // Worker body
+ void WorkerRun();
+
+ static void ThreadCb(Agent* agent);
+ static void ParentSignalCb(uv_async_t* signal);
+ static void ChildSignalCb(uv_async_t* signal);
+ static void MessageHandler(const v8::Debug::Message& message);
+
+ // V8 API
+ static Agent* Unwrap(const v8::FunctionCallbackInfo& args);
+ static void NotifyListen(const v8::FunctionCallbackInfo& args);
+ static void NotifyWait(const v8::FunctionCallbackInfo& args);
+ static void SendCommand(const v8::FunctionCallbackInfo& args);
+
+ void EnqueueMessage(AgentMessage* message);
+
+ enum State {
+ kNone,
+ kRunning
+ };
+
+ // TODO(indutny): Verify that there are no races
+ State state_;
+
+ int port_;
+ bool wait_;
+
+ uv_sem_t start_sem_;
+ uv_mutex_t message_mutex_;
+ uv_async_t child_signal_;
+
+ uv_thread_t thread_;
+ node::Environment* parent_env_;
+ node::Environment* child_env_;
+ uv_loop_t child_loop_;
+ v8::Persistent api_;
+
+ // QUEUE
+ void* messages_[2];
+
+ DispatchHandler dispatch_handler_;
+};
+
+} // namespace debugger
+} // namespace node
+
+#endif // DEPS_DEBUGGER_AGENT_INCLUDE_DEBUGGER_AGENT_H_
diff -Nru nodejs-0.11.14/deps/debugger-agent/lib/_debugger_agent.js nodejs-0.11.15/deps/debugger-agent/lib/_debugger_agent.js
--- nodejs-0.11.14/deps/debugger-agent/lib/_debugger_agent.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/debugger-agent/lib/_debugger_agent.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,191 @@
+var assert = require('assert');
+var net = require('net');
+var util = require('util');
+var Buffer = require('buffer').Buffer;
+
+var Transform = require('stream').Transform;
+
+exports.start = function start() {
+ var agent = new Agent();
+
+ // Do not let `agent.listen()` request listening from cluster master
+ var cluster = require('cluster');
+ cluster.isWorker = false;
+ cluster.isMaster = true;
+
+ agent.on('error', function(err) {
+ process._rawDebug(err.stack || err);
+ });
+
+ agent.listen(process._debugAPI.port, function() {
+ var addr = this.address();
+ process._rawDebug('Debugger listening on port %d', addr.port);
+ process._debugAPI.notifyListen();
+ });
+
+ // Just to spin-off events
+ // TODO(indutny): Figure out why node.cc isn't doing this
+ setImmediate(function() {
+ });
+
+ process._debugAPI.onclose = function() {
+ // We don't care about it, but it prevents loop from cleaning up gently
+ // NOTE: removeAllListeners won't work, as it doesn't call `removeListener`
+ process.listeners('SIGWINCH').forEach(function(fn) {
+ process.removeListener('SIGWINCH', fn);
+ });
+
+ agent.close();
+ };
+
+ // Not used now, but anyway
+ return agent;
+};
+
+function Agent() {
+ net.Server.call(this, this.onConnection);
+
+ this.first = true;
+ this.binding = process._debugAPI;
+
+ var self = this;
+ this.binding.onmessage = function(msg) {
+ self.clients.forEach(function(client) {
+ client.send({}, msg);
+ });
+ };
+
+ this.clients = [];
+ assert(this.binding, 'Debugger agent running without bindings!');
+}
+util.inherits(Agent, net.Server);
+
+Agent.prototype.onConnection = function onConnection(socket) {
+ var c = new Client(this, socket);
+
+ c.start();
+ this.clients.push(c);
+
+ var self = this;
+ c.once('close', function() {
+ var index = self.clients.indexOf(c);
+ assert(index !== -1);
+ self.clients.splice(index, 1);
+ });
+};
+
+Agent.prototype.notifyWait = function notifyWait() {
+ if (this.first)
+ this.binding.notifyWait();
+ this.first = false;
+};
+
+function Client(agent, socket) {
+ Transform.call(this);
+ this._readableState.objectMode = true;
+
+ this.agent = agent;
+ this.binding = this.agent.binding;
+ this.socket = socket;
+
+ // Parse incoming data
+ this.state = 'headers';
+ this.headers = {};
+ this.buffer = '';
+ socket.pipe(this);
+
+ this.on('data', this.onCommand);
+
+ var self = this;
+ this.socket.on('close', function() {
+ self.destroy();
+ });
+}
+util.inherits(Client, Transform);
+
+Client.prototype.destroy = function destroy(msg) {
+ this.socket.destroy();
+
+ this.emit('close');
+};
+
+Client.prototype._transform = function _transform(data, enc, cb) {
+ cb();
+
+ this.buffer += data;
+
+ while (true) {
+ if (this.state === 'headers') {
+ // Not enough data
+ if (!/\r\n/.test(this.buffer))
+ break;
+
+ if (/^\r\n/.test(this.buffer)) {
+ this.buffer = this.buffer.slice(2);
+ this.state = 'body';
+ continue;
+ }
+
+ // Match:
+ // Header-name: header-value\r\n
+ var match = this.buffer.match(/^([^:\s\r\n]+)\s*:\s*([^\s\r\n]+)\r\n/);
+ if (!match)
+ return this.destroy('Expected header, but failed to parse it');
+
+ this.headers[match[1].toLowerCase()] = match[2];
+
+ this.buffer = this.buffer.slice(match[0].length);
+ } else {
+ var len = this.headers['content-length'];
+ if (len === undefined)
+ return this.destroy('Expected content-length');
+
+ len = len | 0;
+ if (Buffer.byteLength(this.buffer) < len)
+ break;
+
+ this.push(new Command(this.headers, this.buffer.slice(0, len)));
+ this.state = 'headers';
+ this.buffer = this.buffer.slice(len);
+ this.headers = {};
+ }
+ }
+};
+
+Client.prototype.send = function send(headers, data) {
+ if (!data)
+ data = '';
+
+ var out = [];
+ Object.keys(headers).forEach(function(key) {
+ out.push(key + ': ' + headers[key]);
+ });
+ out.push('Content-Length: ' + Buffer.byteLength(data), '');
+
+ this.socket.cork();
+ this.socket.write(out.join('\r\n') + '\r\n');
+
+ if (data.length > 0)
+ this.socket.write(data);
+ this.socket.uncork();
+};
+
+Client.prototype.start = function start() {
+ this.send({
+ Type: 'connect',
+ 'V8-Version': process.versions.v8,
+ 'Protocol-Version': 1,
+ 'Embedding-Host': 'node ' + process.version
+ });
+};
+
+Client.prototype.onCommand = function onCommand(cmd) {
+ this.binding.sendCommand(cmd.body);
+
+ this.agent.notifyWait();
+};
+
+function Command(headers, body) {
+ this.headers = headers;
+ this.body = body;
+}
diff -Nru nodejs-0.11.14/deps/debugger-agent/src/agent.cc nodejs-0.11.15/deps/debugger-agent/src/agent.cc
--- nodejs-0.11.14/deps/debugger-agent/src/agent.cc 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/debugger-agent/src/agent.cc 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,347 @@
+// Copyright Fedor Indutny and other Node contributors.
+//
+// Permission is hereby granted, free of charge, to any person obtaining a
+// copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to permit
+// persons to whom the Software is furnished to do so, subject to the
+// following conditions:
+//
+// The above copyright notice and this permission notice shall be included
+// in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
+// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
+// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
+// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
+// USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+#include "agent.h"
+#include "debugger-agent.h"
+
+#include "node.h"
+#include "node_internals.h" // ARRAY_SIZE
+#include "env.h"
+#include "env-inl.h"
+#include "v8.h"
+#include "v8-debug.h"
+#include "util.h"
+#include "util-inl.h"
+#include "queue.h"
+
+#include
+
+namespace node {
+namespace debugger {
+
+using v8::Context;
+using v8::Function;
+using v8::FunctionCallbackInfo;
+using v8::FunctionTemplate;
+using v8::Handle;
+using v8::HandleScope;
+using v8::Integer;
+using v8::Isolate;
+using v8::Local;
+using v8::Locker;
+using v8::Object;
+using v8::String;
+using v8::Value;
+
+
+Agent::Agent(Environment* env) : state_(kNone),
+ port_(5858),
+ wait_(false),
+ parent_env_(env),
+ child_env_(NULL),
+ dispatch_handler_(NULL) {
+ int err;
+
+ err = uv_sem_init(&start_sem_, 0);
+ CHECK_EQ(err, 0);
+
+ err = uv_mutex_init(&message_mutex_);
+ CHECK_EQ(err, 0);
+
+ QUEUE_INIT(&messages_);
+}
+
+
+Agent::~Agent() {
+ Stop();
+
+ uv_sem_destroy(&start_sem_);
+ uv_mutex_destroy(&message_mutex_);
+
+ // Clean-up messages
+ while (!QUEUE_EMPTY(&messages_)) {
+ QUEUE* q = QUEUE_HEAD(&messages_);
+ QUEUE_REMOVE(q);
+ AgentMessage* msg = ContainerOf(&AgentMessage::member, q);
+ delete msg;
+ }
+}
+
+
+bool Agent::Start(int port, bool wait) {
+ int err;
+
+ if (state_ == kRunning)
+ return false;
+
+ err = uv_loop_init(&child_loop_);
+ if (err != 0)
+ goto loop_init_failed;
+
+ // Interruption signal handler
+ err = uv_async_init(&child_loop_, &child_signal_, ChildSignalCb);
+ if (err != 0)
+ goto async_init_failed;
+ uv_unref(reinterpret_cast(&child_signal_));
+
+ port_ = port;
+ wait_ = wait;
+
+ err = uv_thread_create(&thread_,
+ reinterpret_cast(ThreadCb),
+ this);
+ if (err != 0)
+ goto thread_create_failed;
+
+ uv_sem_wait(&start_sem_);
+
+ state_ = kRunning;
+
+ return true;
+
+ thread_create_failed:
+ uv_close(reinterpret_cast(&child_signal_), NULL);
+
+ async_init_failed:
+ err = uv_loop_close(&child_loop_);
+ CHECK_EQ(err, 0);
+
+ loop_init_failed:
+ return false;
+}
+
+
+void Agent::Enable() {
+ v8::Debug::SetMessageHandler(MessageHandler);
+
+ // Assign environment to the debugger's context
+ // NOTE: The debugger context is created after `SetMessageHandler()` call
+ parent_env()->AssignToContext(v8::Debug::GetDebugContext());
+}
+
+
+void Agent::Stop() {
+ int err;
+
+ if (state_ != kRunning) {
+ return;
+ }
+
+ v8::Debug::SetMessageHandler(NULL);
+
+ // Send empty message to terminate things
+ EnqueueMessage(new AgentMessage(NULL, 0));
+
+ // Signal worker thread to make it stop
+ err = uv_async_send(&child_signal_);
+ CHECK_EQ(err, 0);
+
+ err = uv_thread_join(&thread_);
+ CHECK_EQ(err, 0);
+
+ uv_close(reinterpret_cast(&child_signal_), NULL);
+ uv_run(&child_loop_, UV_RUN_NOWAIT);
+
+ err = uv_loop_close(&child_loop_);
+ CHECK_EQ(err, 0);
+
+ state_ = kNone;
+}
+
+
+void Agent::WorkerRun() {
+ static const char* argv[] = { "node", "--debug-agent" };
+ Isolate* isolate = Isolate::New();
+ {
+ Locker locker(isolate);
+ Isolate::Scope isolate_scope(isolate);
+
+ HandleScope handle_scope(isolate);
+ Local context = Context::New(isolate);
+
+ Context::Scope context_scope(context);
+ Environment* env = CreateEnvironment(
+ isolate,
+ &child_loop_,
+ context,
+ ARRAY_SIZE(argv),
+ argv,
+ ARRAY_SIZE(argv),
+ argv);
+
+ child_env_ = env;
+
+ // Expose API
+ InitAdaptor(env);
+ LoadEnvironment(env);
+
+ CHECK_EQ(&child_loop_, env->event_loop());
+ uv_run(&child_loop_, UV_RUN_DEFAULT);
+
+ // Clean-up peristent
+ api_.Reset();
+
+ // Clean-up all running handles
+ env->CleanupHandles();
+
+ env->Dispose();
+ env = NULL;
+ }
+ isolate->Dispose();
+}
+
+
+void Agent::InitAdaptor(Environment* env) {
+ Isolate* isolate = env->isolate();
+ HandleScope scope(isolate);
+
+ // Create API adaptor
+ Local t = FunctionTemplate::New(isolate);
+ t->InstanceTemplate()->SetInternalFieldCount(1);
+ t->SetClassName(String::NewFromUtf8(isolate, "DebugAPI"));
+
+ NODE_SET_PROTOTYPE_METHOD(t, "notifyListen", NotifyListen);
+ NODE_SET_PROTOTYPE_METHOD(t, "notifyWait", NotifyWait);
+ NODE_SET_PROTOTYPE_METHOD(t, "sendCommand", SendCommand);
+
+ Local api = t->GetFunction()->NewInstance();
+ api->SetAlignedPointerInInternalField(0, this);
+
+ api->Set(String::NewFromUtf8(isolate, "port"), Integer::New(isolate, port_));
+
+ env->process_object()->Set(String::NewFromUtf8(isolate, "_debugAPI"), api);
+ api_.Reset(env->isolate(), api);
+}
+
+
+Agent* Agent::Unwrap(const v8::FunctionCallbackInfo& args) {
+ void* ptr = args.Holder()->GetAlignedPointerFromInternalField(0);
+ return reinterpret_cast(ptr);
+}
+
+
+void Agent::NotifyListen(const FunctionCallbackInfo& args) {
+ Agent* a = Unwrap(args);
+
+ // Notify other thread that we are ready to process events
+ uv_sem_post(&a->start_sem_);
+}
+
+
+void Agent::NotifyWait(const FunctionCallbackInfo& args) {
+ Agent* a = Unwrap(args);
+
+ a->wait_ = false;
+
+ int err = uv_async_send(&a->child_signal_);
+ CHECK_EQ(err, 0);
+}
+
+
+void Agent::SendCommand(const FunctionCallbackInfo& args) {
+ Agent* a = Unwrap(args);
+ Environment* env = a->child_env();
+ HandleScope scope(env->isolate());
+
+ String::Value v(args[0]);
+
+ v8::Debug::SendCommand(a->parent_env()->isolate(), *v, v.length());
+ if (a->dispatch_handler_ != NULL)
+ a->dispatch_handler_(a->parent_env());
+}
+
+
+void Agent::ThreadCb(Agent* agent) {
+ agent->WorkerRun();
+}
+
+
+void Agent::ChildSignalCb(uv_async_t* signal) {
+ Agent* a = ContainerOf(&Agent::child_signal_, signal);
+ Isolate* isolate = a->child_env()->isolate();
+
+ HandleScope scope(isolate);
+ Local api = PersistentToLocal(isolate, a->api_);
+
+ uv_mutex_lock(&a->message_mutex_);
+ while (!QUEUE_EMPTY(&a->messages_)) {
+ QUEUE* q = QUEUE_HEAD(&a->messages_);
+ AgentMessage* msg = ContainerOf(&AgentMessage::member, q);
+
+ // Time to close everything
+ if (msg->data() == NULL) {
+ QUEUE_REMOVE(q);
+ delete msg;
+
+ MakeCallback(isolate, api, "onclose", 0, NULL);
+ break;
+ }
+
+ // Waiting for client, do not send anything just yet
+ // TODO(indutny): move this to js-land
+ if (a->wait_)
+ break;
+
+ QUEUE_REMOVE(q);
+ Local argv[] = {
+ String::NewFromTwoByte(isolate,
+ msg->data(),
+ String::kNormalString,
+ msg->length())
+ };
+
+ // Emit message
+ MakeCallback(isolate,
+ api,
+ "onmessage",
+ ARRAY_SIZE(argv),
+ argv);
+ delete msg;
+ }
+ uv_mutex_unlock(&a->message_mutex_);
+}
+
+
+void Agent::EnqueueMessage(AgentMessage* message) {
+ uv_mutex_lock(&message_mutex_);
+ QUEUE_INSERT_TAIL(&messages_, &message->member);
+ uv_mutex_unlock(&message_mutex_);
+ uv_async_send(&child_signal_);
+}
+
+
+void Agent::MessageHandler(const v8::Debug::Message& message) {
+ Isolate* isolate = message.GetIsolate();
+ Environment* env = Environment::GetCurrent(isolate);
+ Agent* a = env->debugger_agent();
+ CHECK_NE(a, NULL);
+ CHECK_EQ(isolate, a->parent_env()->isolate());
+
+ HandleScope scope(isolate);
+ Local json = message.GetJSON();
+ String::Value v(json);
+
+ AgentMessage* msg = new AgentMessage(*v, v.length());
+ a->EnqueueMessage(msg);
+}
+
+} // namespace debugger
+} // namespace node
diff -Nru nodejs-0.11.14/deps/debugger-agent/src/agent.h nodejs-0.11.15/deps/debugger-agent/src/agent.h
--- nodejs-0.11.14/deps/debugger-agent/src/agent.h 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/debugger-agent/src/agent.h 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,64 @@
+// Copyright Fedor Indutny and other Node contributors.
+//
+// Permission is hereby granted, free of charge, to any person obtaining a
+// copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to permit
+// persons to whom the Software is furnished to do so, subject to the
+// following conditions:
+//
+// The above copyright notice and this permission notice shall be included
+// in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
+// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
+// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
+// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
+// USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+#ifndef DEPS_DEBUGGER_AGENT_SRC_AGENT_H_
+#define DEPS_DEBUGGER_AGENT_SRC_AGENT_H_
+
+#include "v8.h"
+#include "v8-debug.h"
+#include "queue.h"
+
+#include
+#include
+
+namespace node {
+namespace debugger {
+
+class AgentMessage {
+ public:
+ AgentMessage(uint16_t* val, int length) : length_(length) {
+ if (val == NULL) {
+ data_ = val;
+ } else {
+ data_ = new uint16_t[length];
+ memcpy(data_, val, length * sizeof(*data_));
+ }
+ }
+
+ ~AgentMessage() {
+ delete[] data_;
+ data_ = NULL;
+ }
+
+ inline const uint16_t* data() const { return data_; }
+ inline int length() const { return length_; }
+
+ QUEUE member;
+
+ private:
+ uint16_t* data_;
+ int length_;
+};
+
+} // namespace debugger
+} // namespace node
+
+#endif // DEPS_DEBUGGER_AGENT_SRC_AGENT_H_
diff -Nru nodejs-0.11.14/deps/npm/bin/npm-cli.js nodejs-0.11.15/deps/npm/bin/npm-cli.js
--- nodejs-0.11.14/deps/npm/bin/npm-cli.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/bin/npm-cli.js 2015-01-20 21:22:17.000000000 +0000
@@ -21,7 +21,7 @@
var path = require("path")
, npm = require("../lib/npm.js")
- , npmconf = require("npmconf")
+ , npmconf = require("../lib/config/core.js")
, errorHandler = require("../lib/utils/error-handler.js")
, configDefs = npmconf.defs
diff -Nru nodejs-0.11.14/deps/npm/CHANGELOG.md nodejs-0.11.15/deps/npm/CHANGELOG.md
--- nodejs-0.11.14/deps/npm/CHANGELOG.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/CHANGELOG.md 2015-01-20 21:22:17.000000000 +0000
@@ -1,3 +1,318 @@
+### v2.1.6 (2014-10-23):
+
+* [`681b398`](https://github.com/npm/npm/commit/681b3987a18e7aba0aaf78c91a23c7cc0ab82ce8)
+ [#6523](https://github.com/npm/npm/issues/6523) fix default `logelevel` doc
+ ([@KenanY](https://github.com/KenanY))
+* [`80b368f`](https://github.com/npm/npm/commit/80b368ffd786d4d008734b56c4a6fe12d2cb2926)
+ [#6528](https://github.com/npm/npm/issues/6528) `npm version` should work in
+ a git directory without git ([@terinjokes](https://github.com/terinjokes))
+* [`5f5f9e4`](https://github.com/npm/npm/commit/5f5f9e4ddf544c2da6adf3f8c885238b0e745076)
+ [#6483](https://github.com/npm/npm/issues/6483) `init-package-json@1.1.1`:
+ Properly pick up default values from environment variables.
+ ([@othiym23](https://github.com/othiym23))
+* [`a114870`](https://github.com/npm/npm/commit/a1148702f53f82d49606b2e4dac7581261fff442)
+ perl 5.18.x doesn't like -pi without filenames
+ ([@othiym23](https://github.com/othiym23))
+* [`de5ba00`](https://github.com/npm/npm/commit/de5ba007a48db876eb5bfb6156435f3512d58977)
+ `request@2.46.0`: Tests and cleanup.
+ ([@othiym23](https://github.com/othiym23))
+* [`76933f1`](https://github.com/npm/npm/commit/76933f169f17b5273b32e924a7b392d5729931a7)
+ `fstream-npm@1.0.1`: Always include `LICENSE[.*]`, `LICENCE[.*]`,
+ `CHANGES[.*]`, `CHANGELOG[.*]`, and `HISTORY[.*]`.
+ ([@jonathanong](https://github.com/jonathanong))
+
+### v2.1.5 (2014-10-16):
+
+* [`6a14b23`](https://github.com/npm/npm/commit/6a14b232a0e34158bd95bb25c607167be995c204)
+ [#6397](https://github.com/npm/npm/issues/6397) Defactor npmconf back into
+ npm. ([@othiym23](https://github.com/othiym23))
+* [`4000e33`](https://github.com/npm/npm/commit/4000e3333a76ca4844681efa8737cfac24b7c2c8)
+ [#6323](https://github.com/npm/npm/issues/6323) Install `peerDependencies`
+ from top. ([@othiym23](https://github.com/othiym23))
+* [`5d119ae`](https://github.com/npm/npm/commit/5d119ae246f27353b14ff063559d1ba8c616bb89)
+ [#6498](https://github.com/npm/npm/issues/6498) Better error messages on
+ malformed `.npmrc` properties. ([@nicks](https://github.com/nicks))
+* [`ae18efb`](https://github.com/npm/npm/commit/ae18efb65fed427b1ef18e4862885bf60b87b92e)
+ [#6093](https://github.com/npm/npm/issues/6093) Replace instances of 'hash'
+ with 'object' in documentation. ([@zeke](https://github.com/zeke))
+* [`53108b2`](https://github.com/npm/npm/commit/53108b276fec5f97a38250933a2768d58b6928da)
+ [#1558](https://github.com/npm/npm/issues/1558) Clarify how local paths
+ should be used. ([@KenanY](https://github.com/KenanY))
+* [`344fa1a`](https://github.com/npm/npm/commit/344fa1a219ac8867022df3dc58a47636dde8a242)
+ [#6488](https://github.com/npm/npm/issues/6488) Work around bug in marked.
+ ([@othiym23](https://github.com/othiym23))
+
+OUTDATED DEPENDENCY CLEANUP JAMBOREE
+
+* [`60c2942`](https://github.com/npm/npm/commit/60c2942e13655d9ecdf6e0f1f97f10cb71a75255)
+ `realize-package-specifier@1.2.0`: Handle names and rawSpecs more
+ consistently. ([@iarna](https://github.com/iarna))
+* [`1b5c95f`](https://github.com/npm/npm/commit/1b5c95fbda77b87342bd48c5ecac5b1fd571ccfe)
+ `sha@1.3.0`: Change line endings?
+ ([@ForbesLindesay](https://github.com/ForbesLindesay))
+* [`d7dee3f`](https://github.com/npm/npm/commit/d7dee3f3f7d9e7c2061a4ecb4dd93e3e4bfe4f2e)
+ `request@2.45.0`: Dependency updates, better proxy support, better compressed
+ response handling, lots of 'use strict'.
+ ([@mikeal](https://github.com/mikeal))
+* [`3d75180`](https://github.com/npm/npm/commit/3d75180c2cc79fa3adfa0e4cb783a27192189a65)
+ `opener@1.4.0`: Added gratuitous return.
+ ([@Domenic](https://github.com/Domenic))
+* [`8e2703f`](https://github.com/npm/npm/commit/8e2703f78d280d1edeb749e257dda1f288bad6e3)
+ `retry@0.6.1` / `npm-registry-client@3.2.4`: Change of ownership.
+ ([@tim-kos](https://github.com/tim-kos))
+* [`c87b00f`](https://github.com/npm/npm/commit/c87b00f82f92434ee77831915012c77a6c244c39)
+ `once@1.3.1`: Wrap once with wrappy. ([@isaacs](https://github.com/isaacs))
+* [`01ec790`](https://github.com/npm/npm/commit/01ec790fd47def56eda6abb3b8d809093e8f493f)
+ `npm-user-validate@0.1.1`: Correct repository URL.
+ ([@robertkowalski](https://github.com/robertkowalski))
+* [`389e52c`](https://github.com/npm/npm/commit/389e52c2d94c818ca8935ccdcf392994fec564a2)
+ `glob@4.0.6`: Now absolutely requires `graceful-fs`.
+ ([@isaacs](https://github.com/isaacs))
+* [`e15ab15`](https://github.com/npm/npm/commit/e15ab15a27a8f14cf0d9dc6f11dee452080378a0)
+ `ini@1.3.0`: Tighten up whitespace handling.
+ ([@isaacs](https://github.com/isaacs))
+* [`7610f3e`](https://github.com/npm/npm/commit/7610f3e62e699292ece081bfd33084d436e3246d)
+ `archy@1.0.0` ([@substack](https://github.com/substack))
+* [`9c13149`](https://github.com/npm/npm/commit/9c1314985e513e20ffa3ea0ca333ba2ab78299c9)
+ `semver@4.1.0`: Add support for prerelease identifiers.
+ ([@bromanko](https://github.com/bromanko))
+* [`f096c25`](https://github.com/npm/npm/commit/f096c250441b031d758f03afbe8d2321f94c7703)
+ `graceful-fs@3.0.4`: Add a bunch of additional tests, skip the unfortunate
+ complications of `graceful-fs@3.0.3`. ([@isaacs](https://github.com/isaacs))
+
+### v2.1.4 (2014-10-09):
+
+* [`3aeb440`](https://github.com/npm/npm/commit/3aeb4401444fad83cc7a8d11bf2507658afa5248)
+ [#6442](https://github.com/npm/npm/issues/6442) proxying git needs `GIT_SSL_CAINFO`
+ ([@wmertens](https://github.com/wmertens))
+* [`a8da8d6`](https://github.com/npm/npm/commit/a8da8d6e0cd56d97728c0b76b51604ee06ef6264)
+ [#6413](https://github.com/npm/npm/issues/6413) write builtin config on any
+ global npm install ([@isaacs](https://github.com/isaacs))
+* [`9e4d632`](https://github.com/npm/npm/commit/9e4d632c0142ba55df07d624667738b8727336fc)
+ [#6343](https://github.com/npm/npm/issues/6343) don't pass run arguments to
+ pre & post scripts ([@TheLudd](https://github.com/TheLudd))
+* [`d831b1f`](https://github.com/npm/npm/commit/d831b1f7ca1a9921ea5b394e39b7130ecbc6d7b4)
+ [#6399](https://github.com/npm/npm/issues/6399) race condition: inflight
+ installs, prevent `peerDependency` problems
+ ([@othiym23](https://github.com/othiym23))
+* [`82b775d`](https://github.com/npm/npm/commit/82b775d6ff34c4beb6c70b2344d491a9f2026577)
+ [#6384](https://github.com/npm/npm/issues/6384) race condition: inflight
+ caching by URL rather than semver range
+ ([@othiym23](https://github.com/othiym23))
+* [`7bee042`](https://github.com/npm/npm/commit/7bee0429066fedcc9e6e962c043eb740b3792809)
+ `inflight@1.0.4`: callback can take arbitrary number of parameters
+ ([@othiym23](https://github.com/othiym23))
+* [`3bff494`](https://github.com/npm/npm/commit/3bff494f4abf17d6d7e0e4a3a76cf7421ecec35a)
+ [#5195](https://github.com/npm/npm/issues/5195) fixed regex color regression
+ for `npm search` ([@chrismeyersfsu](https://github.com/chrismeyersfsu))
+* [`33ba2d5`](https://github.com/npm/npm/commit/33ba2d585160a0a2a322cb76c4cd989acadcc984)
+ [#6387](https://github.com/npm/npm/issues/6387) allow `npm view global` if
+ package is specified ([@evanlucas](https://github.com/evanlucas))
+* [`99c4cfc`](https://github.com/npm/npm/commit/99c4cfceed413396d952cf05f4e3c710f9682c23)
+ [#6388](https://github.com/npm/npm/issues/6388) npm-publish →
+ npm-developers(7) ([@kennydude](https://github.com/kennydude))
+
+TEST CLEANUP EXTRAVAGANZA:
+
+* [`8d6bfcb`](https://github.com/npm/npm/commit/8d6bfcb88408f5885a2a67409854c43e5c3a23f6)
+ tap tests run with no system-wide side effects
+ ([@chrismeyersfsu](https://github.com/chrismeyersfsu))
+* [`7a1472f`](https://github.com/npm/npm/commit/7a1472fbdbe99956ad19f629e7eb1cc07ba026ef)
+ added npm cache cleanup script
+ ([@chrismeyersfsu](https://github.com/chrismeyersfsu))
+* [`0ce6a37`](https://github.com/npm/npm/commit/0ce6a3752fa9119298df15671254db6bc1d8e64c)
+ stripped out dead test code (othiym23)
+* replace spawn with common.npm (@chrismeyersfsu):
+ * [`0dcd614`](https://github.com/npm/npm/commit/0dcd61446335eaf541bf5f2d5186ec1419f86a42)
+ test/tap/cache-shasum-fork.js
+ * [`97f861c`](https://github.com/npm/npm/commit/97f861c967606a7e51e3d5047cf805d9d1adea5a)
+ test/tap/false_name.js
+ * [`d01b3de`](https://github.com/npm/npm/commit/d01b3de6ce03f25bbf3db97bfcd3cc85830d6801)
+ test/tap/git-cache-locking.js
+ * [`7b63016`](https://github.com/npm/npm/commit/7b63016778124c6728d6bd89a045c841ae3900b6)
+ test/tap/pack-scoped.js
+ * [`c877553`](https://github.com/npm/npm/commit/c877553265c39673e03f0a97972f692af81a595d)
+ test/tap/scripts-whitespace-windows.js
+ * [`df98525`](https://github.com/npm/npm/commit/df98525331e964131299d457173c697cfb3d95b9)
+ test/tap/prepublish.js
+ * [`99c4cfc`](https://github.com/npm/npm/commit/99c4cfceed413396d952cf05f4e3c710f9682c23)
+ test/tap/prune.js
+
+### v2.1.3 (2014-10-02):
+
+BREAKING CHANGE FOR THE SQRT(i) PEOPLE ACTUALLY USING `npm submodule`:
+
+* [`1e64473`](https://github.com/npm/npm/commit/1e6447360207f45ad6188e5780fdf4517de6e23d)
+ `rm -rf npm submodule` command, which has been broken since the Carter
+ Administration ([@isaacs](https://github.com/isaacs))
+
+BREAKING CHANGE IF YOU ARE FOR SOME REASON STILL USING NODE 0.6 AND YOU SHOULD
+NOT BE DOING THAT CAN YOU NOT:
+
+* [`3e431f9`](https://github.com/npm/npm/commit/3e431f9d6884acb4cde8bcb8a0b122a76b33ee1d)
+ [joyent/node#8492](https://github.com/joyent/node/issues/8492) bye bye
+ customFds, hello stdio ([@othiym23](https://github.com/othiym23))
+
+Other changes:
+
+* [`ea607a8`](https://github.com/npm/npm/commit/ea607a8a20e891ad38eed11b5ce2c3c0a65484b9)
+ [#6372](https://github.com/npm/npm/issues/6372) noisily error (without
+ aborting) on multi-{install,build} ([@othiym23](https://github.com/othiym23))
+* [`3ee2799`](https://github.com/npm/npm/commit/3ee2799b629fd079d2db21d7e8f25fa7fa1660d0)
+ [#6372](https://github.com/npm/npm/issues/6372) only make cache creation
+ requests in flight ([@othiym23](https://github.com/othiym23))
+* [`1a90ec2`](https://github.com/npm/npm/commit/1a90ec2f2cfbefc8becc6ef0c480e5edacc8a4cb)
+ [#6372](https://github.com/npm/npm/issues/6372) wait to put Git URLs in
+ flight until normalized ([@othiym23](https://github.com/othiym23))
+* [`664795b`](https://github.com/npm/npm/commit/664795bb7d8da7142417b3f4ef5986db3a394071)
+ [#6372](https://github.com/npm/npm/issues/6372) log what is and isn't in
+ flight ([@othiym23](https://github.com/othiym23))
+* [`00ef580`](https://github.com/npm/npm/commit/00ef58025a1f52dfabf2c4dc3898621d16a6e062)
+ `inflight@1.0.3`: fix largely theoretical race condition, because we really
+ really hate race conditions ([@isaacs](https://github.com/isaacs))
+* [`1cde465`](https://github.com/npm/npm/commit/1cde4658d897ae0f93ff1d65b258e1571b391182)
+ [#6363](https://github.com/npm/npm/issues/6363)
+ `realize-package-specifier@1.1.0`: handle local dependencies better
+ ([@iarna](https://github.com/iarna))
+* [`86f084c`](https://github.com/npm/npm/commit/86f084c6c6d7935cd85d72d9d94b8784c914d51e)
+ `realize-package-specifier@1.0.2`: dependency realization! in its own module!
+ ([@iarna](https://github.com/iarna))
+* [`553d830`](https://github.com/npm/npm/commit/553d830334552b83606b6bebefd821c9ea71e964)
+ `npm-package-arg@2.1.3`: simplified semver, better tests
+ ([@iarna](https://github.com/iarna))
+* [`bec9b61`](https://github.com/npm/npm/commit/bec9b61a316c19f5240657594f0905a92a474352)
+ `readable-stream@1.0.32`: for some reason
+ ([@rvagg](https://github.com/rvagg))
+* [`ff08ec5`](https://github.com/npm/npm/commit/ff08ec5f6d717bdbd559de0b2ede769306a9a763)
+ `dezalgo@1.0.1`: use wrappy for instrumentability
+ ([@isaacs](https://github.com/isaacs))
+
+### v2.1.2 (2014-09-29):
+
+* [`a1aa20e`](https://github.com/npm/npm/commit/a1aa20e44bb8285c6be1e7fa63b9da920e3a70ed)
+ [#6282](https://github.com/npm/npm/issues/6282)
+ `normalize-package-data@1.0.3`: don't prune bundledDependencies
+ ([@isaacs](https://github.com/isaacs))
+* [`a1f5fe1`](https://github.com/npm/npm/commit/a1f5fe1005043ce20a06e8b17a3e201aa3215357)
+ move locks back into cache, now path-aware
+ ([@othiym23](https://github.com/othiym23))
+* [`a432c4b`](https://github.com/npm/npm/commit/a432c4b48c881294d6d79b5f41c2e1c16ad15a8a)
+ convert lib/utils/tar.js to use atomic streams
+ ([@othiym23](https://github.com/othiym23))
+* [`b8c3c74`](https://github.com/npm/npm/commit/b8c3c74a3c963564233204161cc263e0912c930b)
+ `fs-write-stream-atomic@1.0.2`: Now works with streams1 fs.WriteStreams.
+ ([@isaacs](https://github.com/isaacs))
+* [`c7ab76f`](https://github.com/npm/npm/commit/c7ab76f44cce5f42add5e3ba879bd10e7e00c3e6)
+ logging cleanup ([@othiym23](https://github.com/othiym23))
+* [`4b2d95d`](https://github.com/npm/npm/commit/4b2d95d0641435b09d047ae5cb2226f292bf38f0)
+ [#6329](https://github.com/npm/npm/issues/6329) efficiently validate tmp
+ tarballs safely ([@othiym23](https://github.com/othiym23))
+
+### v2.1.1 (2014-09-26):
+
+* [`563225d`](https://github.com/npm/npm/commit/563225d813ea4c12f46d4f7821ac7f76ba8ee2d6)
+ [#6318](https://github.com/npm/npm/issues/6318) clean up locking; prefix
+ lockfile with "." ([@othiym23](https://github.com/othiym23))
+* [`c7f30e4`](https://github.com/npm/npm/commit/c7f30e4550fea882d31fcd4a55b681cd30713c44)
+ [#6318](https://github.com/npm/npm/issues/6318) remove locking code around
+ tarball packing and unpacking ([@othiym23](https://github.com/othiym23))
+
+### v2.1.0 (2014-09-25):
+
+NEW FEATURE:
+
+* [`3635601`](https://github.com/npm/npm/commit/36356011b6f2e6a5a81490e85a0a44eb27199dd7)
+ [#5520](https://github.com/npm/npm/issues/5520) Add `'npm view .'`.
+ ([@evanlucas](https://github.com/evanlucas))
+
+Other changes:
+
+* [`f24b552`](https://github.com/npm/npm/commit/f24b552b596d0627549cdd7c2d68fcf9006ea50a)
+ [#6294](https://github.com/npm/npm/issues/6294) Lock cache → lock cache
+ target. ([@othiym23](https://github.com/othiym23))
+* [`ad54450`](https://github.com/npm/npm/commit/ad54450104f94c82c501138b4eee488ce3a4555e)
+ [#6296](https://github.com/npm/npm/issues/6296) Ensure that npm-debug.log
+ file is created when rollbacks are done.
+ ([@isaacs](https://github.com/isaacs))
+* [`6810071`](https://github.com/npm/npm/commit/681007155a40ac9d165293bd6ec5d8a1423ccfca)
+ docs: Default loglevel "http" → "warn".
+ ([@othiym23](https://github.com/othiym23))
+* [`35ac89a`](https://github.com/npm/npm/commit/35ac89a940f23db875e882ce2888208395130336)
+ Skip installation of installed scoped packages.
+ ([@timoxley](https://github.com/timoxley))
+* [`e468527`](https://github.com/npm/npm/commit/e468527256ec599892b9b88d61205e061d1ab735)
+ Ensure cleanup executes for scripts-whitespace-windows test.
+ ([@timoxley](https://github.com/timoxley))
+* [`ef9101b`](https://github.com/npm/npm/commit/ef9101b7f346797749415086956a0394528a12c4)
+ Ensure cleanup executes for packed-scope test.
+ ([@timoxley](https://github.com/timoxley))
+* [`69b4d18`](https://github.com/npm/npm/commit/69b4d18cdbc2ae04c9afaffbd273b436a394f398)
+ `fs-write-stream-atomic@1.0.1`: Fix a race condition in our race-condition
+ fixer. ([@isaacs](https://github.com/isaacs))
+* [`26b17ff`](https://github.com/npm/npm/commit/26b17ff2e3b21ee26c6fdbecc8273520cff45718)
+ [#6272](https://github.com/npm/npm/issues/6272) `npmconf` decides what the
+ default prefix is. ([@othiym23](https://github.com/othiym23))
+* [`846faca`](https://github.com/npm/npm/commit/846facacc6427dafcf5756dcd36d9036539938de)
+ Fix development dependency is preferred over dependency.
+ ([@andersjanmyr](https://github.com/andersjanmyr))
+* [`9d1a9db`](https://github.com/npm/npm/commit/9d1a9db3af5adc48a7158a5a053eeb89ee41a0e7)
+ [#3265](https://github.com/npm/npm/issues/3265) Re-apply a71615a. Fixes
+ [#3265](https://github.com/npm/npm/issues/3265) again, with a test!
+ ([@glasser](https://github.com/glasser))
+* [`1d41db0`](https://github.com/npm/npm/commit/1d41db0b2744a7bd50971c35cc060ea0600fb4bf)
+ `marked-man@0.1.4`: Fixes formatting of synopsis blocks in man docs.
+ ([@kapouer](https://github.com/kapouer))
+* [`a623da0`](https://github.com/npm/npm/commit/a623da01bea1b2d3f3a18b9117cfd2d8e3cbdd77)
+ [#5867](https://github.com/npm/npm/issues/5867) Specify dummy git template
+ dir when cloning to prevent copying hooks.
+ ([@boneskull](https://github.com/boneskull))
+
+### v2.0.2 (2014-09-19):
+
+* [`42c872b`](https://github.com/npm/npm/commit/42c872b32cadc0e555638fc78eab3a38a04401d8)
+ [#5920](https://github.com/npm/npm/issues/5920)
+ `fs-write-stream-atomic@1.0.0` ([@isaacs](https://github.com/isaacs))
+* [`6784767`](https://github.com/npm/npm/commit/6784767fe15e28b44c81a1d4bb1738c642a65d78)
+ [#5920](https://github.com/npm/npm/issues/5920) make all write streams atomic
+ ([@isaacs](https://github.com/isaacs))
+* [`f6fac00`](https://github.com/npm/npm/commit/f6fac000dd98ebdd5ea1d5921175735d463d328b)
+ [#5920](https://github.com/npm/npm/issues/5920) barf on 0-length cached
+ tarballs ([@isaacs](https://github.com/isaacs))
+* [`3b37592`](https://github.com/npm/npm/commit/3b37592a92ea98336505189ae8ca29248b0589f4)
+ `write-file-atomic@1.1.0`: use graceful-fs
+ ([@iarna](https://github.com/iarna))
+
+### v2.0.1 (2014-09-18):
+
+* [`74c5ab0`](https://github.com/npm/npm/commit/74c5ab0a676793c6dc19a3fd5fe149f85fecb261)
+ [#6201](https://github.com/npm/npm/issues/6201) `npmconf@2.1.0`: scope
+ always-auth to registry URI ([@othiym23](https://github.com/othiym23))
+* [`774b127`](https://github.com/npm/npm/commit/774b127da1dd6fefe2f1299e73505d9146f00294)
+ [#6201](https://github.com/npm/npm/issues/6201) `npm-registry-client@3.2.2`:
+ use scoped always-auth settings ([@othiym23](https://github.com/othiym23))
+* [`f2d2190`](https://github.com/npm/npm/commit/f2d2190aa365d22378d03afab0da13f95614a583)
+ [#6201](https://github.com/npm/npm/issues/6201) support saving
+ `--always-auth` when logging in ([@othiym23](https://github.com/othiym23))
+* [`17c941a`](https://github.com/npm/npm/commit/17c941a2d583210fe97ed47e2968d94ce9f774ba)
+ [#6163](https://github.com/npm/npm/issues/6163) use `write-file-atomic`
+ instead of `fs.writeFile()` ([@fiws](https://github.com/fiws))
+* [`fb5724f`](https://github.com/npm/npm/commit/fb5724fd98e1509c939693568df83d11417ea337)
+ [#5925](https://github.com/npm/npm/issues/5925) `npm init -f`: allow `npm
+ init` to run without prompting
+ ([@michaelnisi](https://github.com/michaelnisi))
+* [`b706d63`](https://github.com/npm/npm/commit/b706d637d5965dbf8f7ce07dc5c4bc80887f30d8)
+ [#3059](https://github.com/npm/npm/issues/3059) disable prepublish when
+ running `npm install --production`
+ ([@jussi](https://github.com/jussi)-kalliokoski)
+* [`119f068`](https://github.com/npm/npm/commit/119f068eae2a36fa8b9c9ca557c70377792243a4)
+ attach the node version used when publishing a package to its registry
+ metadata ([@othiym23](https://github.com/othiym23))
+* [`8fe0081`](https://github.com/npm/npm/commit/8fe008181665519c2ac201ee432a3ece9798c31f)
+ seriously, don't use `npm -g update npm`
+ ([@thomblake](https://github.com/thomblake))
+* [`ea5b3d4`](https://github.com/npm/npm/commit/ea5b3d446b86dcabb0dbc6dba374d3039342ecb3)
+ `request@2.44.0` ([@othiym23](https://github.com/othiym23))
+
### v2.0.0 (2014-09-12):
BREAKING CHANGES:
diff -Nru nodejs-0.11.14/deps/npm/doc/api/npm-bin.md nodejs-0.11.15/deps/npm/doc/api/npm-bin.md
--- nodejs-0.11.14/deps/npm/doc/api/npm-bin.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/doc/api/npm-bin.md 2015-01-20 21:22:17.000000000 +0000
@@ -10,4 +10,4 @@
Print the folder where npm will install executables.
This function should not be used programmatically. Instead, just refer
-to the `npm.bin` member.
+to the `npm.bin` property.
diff -Nru nodejs-0.11.14/deps/npm/doc/api/npm-help-search.md nodejs-0.11.15/deps/npm/doc/api/npm-help-search.md
--- nodejs-0.11.14/deps/npm/doc/api/npm-help-search.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/doc/api/npm-help-search.md 2015-01-20 21:22:17.000000000 +0000
@@ -27,4 +27,4 @@
* file:
Name of the file that matched
-The silent parameter is not neccessary not used, but it may in the future.
+The silent parameter is not necessary not used, but it may in the future.
diff -Nru nodejs-0.11.14/deps/npm/doc/api/npm-load.md nodejs-0.11.15/deps/npm/doc/api/npm-load.md
--- nodejs-0.11.14/deps/npm/doc/api/npm-load.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/doc/api/npm-load.md 2015-01-20 21:22:17.000000000 +0000
@@ -10,9 +10,9 @@
npm.load() must be called before any other function call. Both parameters are
optional, but the second is recommended.
-The first parameter is an object hash of command-line config params, and the
-second parameter is a callback that will be called when npm is loaded and
-ready to serve.
+The first parameter is an object containing command-line config params, and the
+second parameter is a callback that will be called when npm is loaded and ready
+to serve.
The first parameter should follow a similar structure as the package.json
config object.
diff -Nru nodejs-0.11.14/deps/npm/doc/api/npm.md nodejs-0.11.15/deps/npm/doc/api/npm.md
--- nodejs-0.11.14/deps/npm/doc/api/npm.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/doc/api/npm.md 2015-01-20 21:22:17.000000000 +0000
@@ -25,13 +25,12 @@
To find documentation of the command line
client, see `npm(1)`.
-Prior to using npm's commands, `npm.load()` must be called.
-If you provide `configObject` as an object hash of top-level
-configs, they override the values stored in the various config
-locations. In the npm command line client, this set of configs
-is parsed from the command line options. Additional configuration
-params are loaded from two configuration files. See `npm-config(1)`,
-`npm-config(7)`, and `npmrc(5)` for more information.
+Prior to using npm's commands, `npm.load()` must be called. If you provide
+`configObject` as an object map of top-level configs, they override the values
+stored in the various config locations. In the npm command line client, this
+set of configs is parsed from the command line options. Additional
+configuration params are loaded from two configuration files. See
+`npm-config(1)`, `npm-config(7)`, and `npmrc(5)` for more information.
After that, each of the functions are accessible in the
commands object: `npm.commands.`. See `npm-index(7)` for a list of
@@ -88,9 +87,9 @@
## MAGIC
-For each of the methods in the `npm.commands` hash, a method is added to
-the npm object, which takes a set of positional string arguments rather
-than an array and a callback.
+For each of the methods in the `npm.commands` object, a method is added to the
+npm object, which takes a set of positional string arguments rather than an
+array and a callback.
If the last argument is a callback, then it will use the supplied
callback. However, if no callback is provided, then it will print out
diff -Nru nodejs-0.11.14/deps/npm/doc/api/npm-submodule.md nodejs-0.11.15/deps/npm/doc/api/npm-submodule.md
--- nodejs-0.11.14/deps/npm/doc/api/npm-submodule.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/doc/api/npm-submodule.md 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-npm-submodule(3) -- Add a package as a git submodule
-====================================================
-
-## SYNOPSIS
-
- npm.commands.submodule(packages, callback)
-
-## DESCRIPTION
-
-For each package specified, npm will check if it has a git repository url
-in its package.json description then add it as a git submodule at
-`node_modules/`.
-
-This is a convenience only. From then on, it's up to you to manage
-updates by using the appropriate git commands. npm will stubbornly
-refuse to update, modify, or remove anything with a `.git` subfolder
-in it.
-
-This command also does not install missing dependencies, if the package
-does not include them in its git repository. If `npm ls` reports that
-things are missing, you can either install, link, or submodule them yourself,
-or you can do `npm explore -- npm install` to install the
-dependencies into the submodule folder.
-
-## SEE ALSO
-
-* npm help json
-* git help submodule
diff -Nru nodejs-0.11.14/deps/npm/doc/cli/npm-adduser.md nodejs-0.11.15/deps/npm/doc/cli/npm-adduser.md
--- nodejs-0.11.14/deps/npm/doc/cli/npm-adduser.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/doc/cli/npm-adduser.md 2015-01-20 21:22:17.000000000 +0000
@@ -3,7 +3,7 @@
## SYNOPSIS
- npm adduser [--registry=url] [--scope=@orgname]
+ npm adduser [--registry=url] [--scope=@orgname] [--always-auth]
## DESCRIPTION
@@ -45,6 +45,21 @@
This will set a registry for the given scope and login or create a user for
that registry at the same time.
+### always-auth
+
+Default: false
+
+If specified, save configuration indicating that all requests to the given
+registry should include authorization information. Useful for private
+registries. Can be used with `--registry` and / or `--scope`, e.g.
+
+ npm adduser --registry=http://private-registry.example.com --always-auth
+
+This will ensure that all requests to that registry (including for tarballs)
+include an authorization header. See `always-auth` in `npm-config(7)` for more
+details on always-auth. Registry-specific configuaration of `always-auth` takes
+precedence over any global configuration.
+
## SEE ALSO
* npm-registry(7)
diff -Nru nodejs-0.11.14/deps/npm/doc/cli/npm-explore.md nodejs-0.11.15/deps/npm/doc/cli/npm-explore.md
--- nodejs-0.11.14/deps/npm/doc/cli/npm-explore.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/doc/cli/npm-explore.md 2015-01-20 21:22:17.000000000 +0000
@@ -32,7 +32,6 @@
## SEE ALSO
-* npm-submodule(1)
* npm-folders(5)
* npm-edit(1)
* npm-rebuild(1)
diff -Nru nodejs-0.11.14/deps/npm/doc/cli/npm-init.md nodejs-0.11.15/deps/npm/doc/cli/npm-init.md
--- nodejs-0.11.14/deps/npm/doc/cli/npm-init.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/doc/cli/npm-init.md 2015-01-20 21:22:17.000000000 +0000
@@ -3,7 +3,7 @@
## SYNOPSIS
- npm init
+ npm init [-f|--force|-y|--yes]
## DESCRIPTION
@@ -18,6 +18,9 @@
It is strictly additive, so it does not delete options from your package.json
without a really good reason to do so.
+If you invoke it with `-f`, `--force`, `-y`, or `--yes`, it will use only
+defaults and not prompt you for any options.
+
## SEE ALSO
*
diff -Nru nodejs-0.11.14/deps/npm/doc/cli/npm-publish.md nodejs-0.11.15/deps/npm/doc/cli/npm-publish.md
--- nodejs-0.11.14/deps/npm/doc/cli/npm-publish.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/doc/cli/npm-publish.md 2015-01-20 21:22:17.000000000 +0000
@@ -9,7 +9,9 @@
## DESCRIPTION
-Publishes a package to the registry so that it can be installed by name.
+Publishes a package to the registry so that it can be installed by name. See
+`npm-developers(7)` for details on what's included in the published package, as
+well as details on how the package is built.
By default npm will publish to the public registry. This can be overridden by
specifying a different default registry or using a `npm-scope(7)` in the name
diff -Nru nodejs-0.11.14/deps/npm/doc/cli/npm-restart.md nodejs-0.11.15/deps/npm/doc/cli/npm-restart.md
--- nodejs-0.11.14/deps/npm/doc/cli/npm-restart.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/doc/cli/npm-restart.md 2015-01-20 21:22:17.000000000 +0000
@@ -7,11 +7,8 @@
## DESCRIPTION
-This runs a package's "restart" script, if one was provided.
-Otherwise it runs package's "stop" script, if one was provided, and then
-the "start" script.
-
-If no version is specified, then it restarts the "active" version.
+This runs a package's "restart" script, if one was provided. Otherwise it runs
+package's "stop" script, if one was provided, and then the "start" script.
## SEE ALSO
diff -Nru nodejs-0.11.14/deps/npm/doc/cli/npm-run-script.md nodejs-0.11.15/deps/npm/doc/cli/npm-run-script.md
--- nodejs-0.11.14/deps/npm/doc/cli/npm-run-script.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/doc/cli/npm-run-script.md 2015-01-20 21:22:17.000000000 +0000
@@ -16,6 +16,16 @@
It is used by the test, start, restart, and stop commands, but can be
called directly, as well.
+As of [`npm@2.0.0`](http://blog.npmjs.org/post/98131109725/npm-2-0-0), you can
+use custom arguments when executing scripts. The special option `--` is used by
+[getopt](http://goo.gl/KxMmtG) to delimit the end of the options. npm will pass
+all the arguments after the `--` directly to your script:
+
+ npm run test -- --grep="pattern"
+
+The arguments will only be passed to the script specified after ```npm run```
+and not to any pre or post script.
+
## SEE ALSO
* npm-scripts(7)
diff -Nru nodejs-0.11.14/deps/npm/doc/cli/npm-submodule.md nodejs-0.11.15/deps/npm/doc/cli/npm-submodule.md
--- nodejs-0.11.14/deps/npm/doc/cli/npm-submodule.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/doc/cli/npm-submodule.md 1970-01-01 00:00:00.000000000 +0000
@@ -1,28 +0,0 @@
-npm-submodule(1) -- Add a package as a git submodule
-====================================================
-
-## SYNOPSIS
-
- npm submodule
-
-## DESCRIPTION
-
-If the specified package has a git repository url in its package.json
-description, then this command will add it as a git submodule at
-`node_modules/`.
-
-This is a convenience only. From then on, it's up to you to manage
-updates by using the appropriate git commands. npm will stubbornly
-refuse to update, modify, or remove anything with a `.git` subfolder
-in it.
-
-This command also does not install missing dependencies, if the package
-does not include them in its git repository. If `npm ls` reports that
-things are missing, you can either install, link, or submodule them yourself,
-or you can do `npm explore -- npm install` to install the
-dependencies into the submodule folder.
-
-## SEE ALSO
-
-* package.json(5)
-* git help submodule
diff -Nru nodejs-0.11.14/deps/npm/doc/files/package.json.md nodejs-0.11.15/deps/npm/doc/files/package.json.md
--- nodejs-0.11.14/deps/npm/doc/files/package.json.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/doc/files/package.json.md 2015-01-20 21:22:17.000000000 +0000
@@ -219,7 +219,7 @@
The CommonJS [Packages](http://wiki.commonjs.org/wiki/Packages/1.0) spec details a
few ways that you can indicate the structure of your package using a `directories`
-hash. If you look at [npm's package.json](http://registry.npmjs.org/npm/latest),
+object. If you look at [npm's package.json](http://registry.npmjs.org/npm/latest),
you'll see that it has directories for doc, lib, and man.
In the future, this information may be used in other creative ways.
@@ -231,10 +231,10 @@
### directories.bin
-If you specify a "bin" directory, then all the files in that folder will
-be used as the "bin" hash.
+If you specify a `bin` directory, then all the files in that folder will
+be added as children of the `bin` path.
-If you have a "bin" hash already, then this has no effect.
+If you have a `bin` path already, then this has no effect.
### directories.man
@@ -274,7 +274,7 @@
## scripts
-The "scripts" member is an object hash of script commands that are run
+The "scripts" property is a dictionary containing script commands that are run
at various times in the lifecycle of your package. The key is the lifecycle
event, and the value is the command to run at that point.
@@ -282,9 +282,9 @@
## config
-A "config" hash can be used to set configuration
-parameters used in package scripts that persist across upgrades. For
-instance, if a package had the following:
+A "config" object can be used to set configuration parameters used in package
+scripts that persist across upgrades. For instance, if a package had the
+following:
{ "name" : "foo"
, "config" : { "port" : "8080" } }
@@ -298,13 +298,13 @@
## dependencies
-Dependencies are specified with a simple hash of package name to
+Dependencies are specified in a simple object that maps a package name to a
version range. The version range is a string which has one or more
-space-separated descriptors. Dependencies can also be identified with
-a tarball or git URL.
+space-separated descriptors. Dependencies can also be identified with a
+tarball or git URL.
**Please do not put test harnesses or transpilers in your
-`dependencies` hash.** See `devDependencies`, below.
+`dependencies` object.** See `devDependencies`, below.
See semver(7) for more details about specifying version ranges.
@@ -340,7 +340,7 @@
, "two" : "2.x"
, "thr" : "3.3.x"
, "lat" : "latest"
- , "dyl" : "~/projects/dyl"
+ , "dyl" : "file:../dyl"
}
}
@@ -378,14 +378,25 @@
## Local Paths
-As of version 2.0.0 you can provide a path to a local directory that
-contains a package. Local paths can be in the form:
+As of version 2.0.0 you can provide a path to a local directory that contains a
+package. Local paths can be saved using `npm install --save`, using any of
+these forms:
../foo/bar
~/foo/bar
./foo/bar
/foo/bar
+in which case they will be normalized to a relative path and added to your
+`package.json`. For example:
+
+ {
+ "name": "baz",
+ "dependencies": {
+ "bar": "file:../foo/bar"
+ }
+ }
+
This feature is helpful for local offline development and creating
tests that require npm installing where you don't want to hit an
external server, but should not be used when publishing packages
@@ -397,8 +408,8 @@
program, then they probably don't want or need to download and build
the external test or documentation framework that you use.
-In this case, it's best to list these additional items in a
-`devDependencies` hash.
+In this case, it's best to map these additional items in a `devDependencies`
+object.
These things will be installed when doing `npm link` or `npm install`
from the root of a package, and can be managed like any other npm
@@ -469,11 +480,11 @@
## optionalDependencies
-If a dependency can be used, but you would like npm to proceed if it
-cannot be found or fails to install, then you may put it in the
-`optionalDependencies` hash. This is a map of package name to version
-or url, just like the `dependencies` hash. The difference is that
-failure is tolerated.
+If a dependency can be used, but you would like npm to proceed if it cannot be
+found or fails to install, then you may put it in the `optionalDependencies`
+object. This is a map of package name to version or url, just like the
+`dependencies` object. The difference is that build failures do not cause
+installation to fail.
It is still your program's responsibility to handle the lack of the
dependency. For example, something like this:
@@ -521,12 +532,12 @@
## engineStrict
If you are sure that your module will *definitely not* run properly on
-versions of Node/npm other than those specified in the `engines` hash,
+versions of Node/npm other than those specified in the `engines` object,
then you can set `"engineStrict": true` in your package.json file.
This will override the user's `engine-strict` config setting.
Please do not do this unless you are really very very sure. If your
-engines hash is something overly restrictive, you can quite easily and
+engines object is something overly restrictive, you can quite easily and
inadvertently lock yourself into obscurity and prevent your users from
updating to new versions of Node. Consider this choice carefully. If
people abuse it, it will be removed in a future version of npm.
@@ -575,11 +586,11 @@
If you set `"private": true` in your package.json, then npm will refuse
to publish it.
-This is a way to prevent accidental publication of private repositories.
-If you would like to ensure that a given package is only ever published
-to a specific registry (for example, an internal registry),
-then use the `publishConfig` hash described below
-to override the `registry` config param at publish-time.
+This is a way to prevent accidental publication of private repositories. If
+you would like to ensure that a given package is only ever published to a
+specific registry (for example, an internal registry), then use the
+`publishConfig` dictionary described below to override the `registry` config
+param at publish-time.
## publishConfig
diff -Nru nodejs-0.11.14/deps/npm/doc/misc/npm-coding-style.md nodejs-0.11.15/deps/npm/doc/misc/npm-coding-style.md
--- nodejs-0.11.14/deps/npm/doc/misc/npm-coding-style.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/doc/misc/npm-coding-style.md 2015-01-20 21:22:17.000000000 +0000
@@ -147,7 +147,7 @@
## Case, naming, etc.
Use `lowerCamelCase` for multiword identifiers when they refer to objects,
-functions, methods, members, or anything not specified in this section.
+functions, methods, properties, or anything not specified in this section.
Use `UpperCamelCase` for class names (things that you'd pass to "new").
diff -Nru nodejs-0.11.14/deps/npm/doc/misc/npm-config.md nodejs-0.11.15/deps/npm/doc/misc/npm-config.md
--- nodejs-0.11.14/deps/npm/doc/misc/npm-config.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/doc/misc/npm-config.md 2015-01-20 21:22:17.000000000 +0000
@@ -384,35 +384,35 @@
[init-package-json](https://github.com/isaacs/init-package-json) module
for more information, or npm-init(1).
-### init.author.name
+### init-author-name
* Default: ""
* Type: String
The value `npm init` should use by default for the package author's name.
-### init.author.email
+### init-author-email
* Default: ""
* Type: String
The value `npm init` should use by default for the package author's email.
-### init.author.url
+### init-author-url
* Default: ""
* Type: String
The value `npm init` should use by default for the package author's homepage.
-### init.license
+### init-license
* Default: "ISC"
* Type: String
The value `npm init` should use by default for the package license.
-### init.version
+### init-version
* Default: "0.0.0"
* Type: semver
@@ -464,7 +464,7 @@
### loglevel
-* Default: "http"
+* Default: "warn"
* Type: String
* Values: "silent", "error", "warn", "http", "info", "verbose", "silly"
@@ -472,7 +472,7 @@
`npm-debug.log` in the current working directory.
Any logs of a higher level than the setting are shown.
-The default is "http", which shows http, warn, and error output.
+The default is "warn", which shows warn and error output.
### logstream
@@ -510,7 +510,7 @@
* Default: process.version
* Type: semver or false
-The node version to use when checking package's "engines" hash.
+The node version to use when checking a package's `engines` map.
### npat
@@ -532,7 +532,7 @@
* Default: true
* Type: Boolean
-Attempt to install packages in the `optionalDependencies` hash. Note
+Attempt to install packages in the `optionalDependencies` object. Note
that if these packages fail to install, the overall installation
process is not aborted.
@@ -610,8 +610,8 @@
Save installed packages to a package.json file as dependencies.
-When used with the `npm rm` command, it removes it from the dependencies
-hash.
+When used with the `npm rm` command, it removes it from the `dependencies`
+object.
Only works if there is already a package.json file present.
@@ -632,10 +632,10 @@
* Default: false
* Type: Boolean
-Save installed packages to a package.json file as devDependencies.
+Save installed packages to a package.json file as `devDependencies`.
When used with the `npm rm` command, it removes it from the
-devDependencies hash.
+`devDependencies` object.
Only works if there is already a package.json file present.
@@ -657,7 +657,7 @@
optionalDependencies.
When used with the `npm rm` command, it removes it from the
-devDependencies hash.
+`devDependencies` object.
Only works if there is already a package.json file present.
@@ -848,8 +848,8 @@
* Default: false
* Type: boolean
-If true, output the npm version as well as node's `process.versions`
-hash, and exit successfully.
+If true, output the npm version as well as node's `process.versions` map, and
+exit successfully.
Only relevant when specified explicitly on the command line.
diff -Nru nodejs-0.11.14/deps/npm/doc/misc/npm-developers.md nodejs-0.11.15/deps/npm/doc/misc/npm-developers.md
--- nodejs-0.11.14/deps/npm/doc/misc/npm-developers.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/doc/misc/npm-developers.md 2015-01-20 21:22:17.000000000 +0000
@@ -76,7 +76,7 @@
* scripts:
If you have a special compilation or installation script, then you
- should put it in the `scripts` hash. You should definitely have at
+ should put it in the `scripts` object. You should definitely have at
least a basic smoke-test command as the "scripts.test" field.
See npm-scripts(7).
@@ -86,8 +86,8 @@
then you need to specify that in the "main" field.
* directories:
- This is a hash of folders. The best ones to include are "lib" and
- "doc", but if you specify a folder full of man pages in "man", then
+ This is an object mapping names to folders. The best ones to include are
+ "lib" and "doc", but if you use "man" to specify a folder full of man pages,
they'll get installed just like these ones.
You can use `npm init` in the root of your package in order to get you
diff -Nru nodejs-0.11.14/deps/npm/doc/misc/npm-faq.md nodejs-0.11.15/deps/npm/doc/misc/npm-faq.md
--- nodejs-0.11.14/deps/npm/doc/misc/npm-faq.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/doc/misc/npm-faq.md 2015-01-20 21:22:17.000000000 +0000
@@ -135,7 +135,7 @@
## How do I update npm?
- npm update npm -g
+ npm install npm -g
You can also update all outdated local packages by doing `npm update` without
any arguments, or global packages by doing `npm update -g`.
diff -Nru nodejs-0.11.14/deps/npm/doc/misc/npm-index.md nodejs-0.11.15/deps/npm/doc/misc/npm-index.md
--- nodejs-0.11.14/deps/npm/doc/misc/npm-index.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/doc/misc/npm-index.md 2015-01-20 21:22:17.000000000 +0000
@@ -161,10 +161,6 @@
Stop a package
-### npm-submodule(1)
-
-Add a package as a git submodule
-
### npm-tag(1)
Tag a published version
@@ -325,10 +321,6 @@
Stop a package
-### npm-submodule(3)
-
-Add a package as a git submodule
-
### npm-tag(3)
Tag a published version
diff -Nru nodejs-0.11.14/deps/npm/doc/misc/npm-scope.md nodejs-0.11.15/deps/npm/doc/misc/npm-scope.md
--- nodejs-0.11.14/deps/npm/doc/misc/npm-scope.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/doc/misc/npm-scope.md 2015-01-20 21:22:17.000000000 +0000
@@ -25,8 +25,8 @@
(`@myorg`) is simply the name of the scope preceded by an @-symbol, and can
contain any number of scoped packages.
-A scoped package is install by referencing it by name, preceded by an @-symbol,
-in `npm install`:
+A scoped package is installed by referencing it by name, preceded by an
+@-symbol, in `npm install`:
npm install @myorg/mypackage
diff -Nru nodejs-0.11.14/deps/npm/doc/misc/npm-scripts.md nodejs-0.11.15/deps/npm/doc/misc/npm-scripts.md
--- nodejs-0.11.14/deps/npm/doc/misc/npm-scripts.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/doc/misc/npm-scripts.md 2015-01-20 21:22:17.000000000 +0000
@@ -3,7 +3,7 @@
## DESCRIPTION
-npm supports the "scripts" member of the package.json script, for the
+npm supports the "scripts" property of the package.json script, for the
following scripts:
* prepublish:
@@ -33,9 +33,10 @@
Run by the `npm restart` command. Note: `npm restart` will run the
stop and start scripts if no `restart` script is provided.
-Additionally, arbitrary scripts can be executed by running `npm run-script
- `. *Pre* and *post* commands with matching names will be run for
-those as well (e.g. `premyscript`, `myscript`, `postmyscript`).
+Additionally, arbitrary scripts can be executed by running `npm
+run-script `. *Pre* and *post* commands with matching
+names will be run for those as well (e.g. `premyscript`, `myscript`,
+`postmyscript`).
## NOTE: INSTALL SCRIPTS ARE AN ANTIPATTERN
@@ -136,7 +137,7 @@
`npm_config_` prefix. For instance, you can view the effective `root`
config by checking the `npm_config_root` environment variable.
-### Special: package.json "config" hash
+### Special: package.json "config" object
The package.json "config" keys are overwritten in the environment if
there is a config param of `[@]:`. For example,
diff -Nru nodejs-0.11.14/deps/npm/doc/misc/semver.md nodejs-0.11.15/deps/npm/doc/misc/semver.md
--- nodejs-0.11.14/deps/npm/doc/misc/semver.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/doc/misc/semver.md 2015-01-20 21:22:17.000000000 +0000
@@ -140,7 +140,7 @@
A partial version range is treated as an X-Range, so the special
character is in fact optional.
-* `` (empty string) := `*` := `>=0.0.0`
+* `""` (empty string) := `*` := `>=0.0.0`
* `1` := `1.x.x` := `>=1.0.0 <2.0.0`
* `1.2` := `1.2.x` := `>=1.2.0 <1.3.0`
diff -Nru nodejs-0.11.14/deps/npm/.eslintrc nodejs-0.11.15/deps/npm/.eslintrc
--- nodejs-0.11.14/deps/npm/.eslintrc 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/.eslintrc 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,17 @@
+{
+ "env" : {
+ "node" : true
+ },
+ "rules" : {
+ "semi": [2, "never"],
+ "strict": 0,
+ "quotes": [1, "double", "avoid-escape"],
+ "no-use-before-define": 0,
+ "curly": 0,
+ "no-underscore-dangle": 0,
+ "no-lonely-if": 1,
+ "no-unused-vars": [2, {"vars" : "all", "args" : "after-used"}],
+ "no-mixed-requires": 0,
+ "space-infix-ops": 0
+ }
+}
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-bin.html nodejs-0.11.15/deps/npm/html/doc/api/npm-bin.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-bin.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-bin.html 2015-01-20 21:22:17.000000000 +0000
@@ -15,7 +15,7 @@
DESCRIPTION
Print the folder where npm will install executables.
This function should not be used programmatically. Instead, just refer
-to the npm.bin
member.
+to the npm.bin
property.
@@ -28,5 +28,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-bugs.html nodejs-0.11.15/deps/npm/html/doc/api/npm-bugs.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-bugs.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-bugs.html 2015-01-20 21:22:17.000000000 +0000
@@ -33,5 +33,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-cache.html nodejs-0.11.15/deps/npm/html/doc/api/npm-cache.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-cache.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-cache.html 2015-01-20 21:22:17.000000000 +0000
@@ -18,7 +18,7 @@
npm.commands.cache.add([args], callback)
npm.commands.cache.read(name, version, forceBypass, callback)
DESCRIPTION
-This acts much the same ways as the npm-cache(1) command line
+
This acts much the same ways as the npm-cache(1) command line
functionality.
The callback is called with the package.json data of the thing that is
eventually added to or read from the cache.
@@ -42,5 +42,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-commands.html nodejs-0.11.15/deps/npm/html/doc/api/npm-commands.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-commands.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-commands.html 2015-01-20 21:22:17.000000000 +0000
@@ -22,7 +22,7 @@
usage, or man 3 npm-<command>
for programmatic usage.
SEE ALSO
@@ -36,5 +36,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-config.html nodejs-0.11.15/deps/npm/html/doc/api/npm-config.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-config.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-config.html 2015-01-20 21:22:17.000000000 +0000
@@ -43,7 +43,7 @@
functions instead.
SEE ALSO
@@ -57,5 +57,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-deprecate.html nodejs-0.11.15/deps/npm/html/doc/api/npm-deprecate.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-deprecate.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-deprecate.html 2015-01-20 21:22:17.000000000 +0000
@@ -31,9 +31,9 @@
To un-deprecate a package, specify an empty string (""
) for the message
argument.
SEE ALSO
@@ -47,5 +47,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-docs.html nodejs-0.11.15/deps/npm/html/doc/api/npm-docs.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-docs.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-docs.html 2015-01-20 21:22:17.000000000 +0000
@@ -33,5 +33,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-edit.html nodejs-0.11.15/deps/npm/html/doc/api/npm-edit.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-edit.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-edit.html 2015-01-20 21:22:17.000000000 +0000
@@ -36,5 +36,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-explore.html nodejs-0.11.15/deps/npm/html/doc/api/npm-explore.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-explore.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-explore.html 2015-01-20 21:22:17.000000000 +0000
@@ -31,5 +31,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-help-search.html nodejs-0.11.15/deps/npm/html/doc/api/npm-help-search.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-help-search.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-help-search.html 2015-01-20 21:22:17.000000000 +0000
@@ -31,7 +31,7 @@
file:
Name of the file that matched
-The silent parameter is not neccessary not used, but it may in the future.
+The silent parameter is not necessary not used, but it may in the future.
@@ -44,5 +44,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm.html nodejs-0.11.15/deps/npm/html/doc/api/npm.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm.html 2015-01-20 21:22:17.000000000 +0000
@@ -23,20 +23,19 @@
npm.commands.install(["package"], cb)
})
VERSION
-2.0.0
+2.1.6
DESCRIPTION
This is the API documentation for npm.
To find documentation of the command line
-client, see npm(1)
.
-Prior to using npm's commands, npm.load()
must be called.
-If you provide configObject
as an object hash of top-level
-configs, they override the values stored in the various config
-locations. In the npm command line client, this set of configs
-is parsed from the command line options. Additional configuration
-params are loaded from two configuration files. See npm-config(1)
,
-npm-config(7)
, and npmrc(5)
for more information.
+client, see npm(1)
.
+Prior to using npm's commands, npm.load()
must be called. If you provide
+configObject
as an object map of top-level configs, they override the values
+stored in the various config locations. In the npm command line client, this
+set of configs is parsed from the command line options. Additional
+configuration params are loaded from two configuration files. See
+npm-config(1)
, npm-config(7)
, and npmrc(5)
for more information.
After that, each of the functions are accessible in the
-commands object: npm.commands.<cmd>
. See npm-index(7)
for a list of
+commands object: npm.commands.<cmd>
. See npm-index(7)
for a list of
all possible commands.
All commands on the command object take an array of positional argument
strings . The last argument to any function is a callback. Some
@@ -80,9 +79,9 @@
MAGIC
-For each of the methods in the npm.commands
hash, a method is added to
-the npm object, which takes a set of positional string arguments rather
-than an array and a callback.
+For each of the methods in the npm.commands
object, a method is added to the
+npm object, which takes a set of positional string arguments rather than an
+array and a callback.
If the last argument is a callback, then it will use the supplied
callback. However, if no callback is provided, then it will print out
the error or results.
@@ -110,5 +109,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-init.html nodejs-0.11.15/deps/npm/html/doc/api/npm-init.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-init.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-init.html 2015-01-20 21:22:17.000000000 +0000
@@ -26,7 +26,7 @@
preferred method. If you're sure you want to handle command-line prompting,
then go ahead and use this programmatically.
SEE ALSO
-package.json(5)
+package.json(5)
@@ -39,5 +39,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-install.html nodejs-0.11.15/deps/npm/html/doc/api/npm-install.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-install.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-install.html 2015-01-20 21:22:17.000000000 +0000
@@ -32,5 +32,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-link.html nodejs-0.11.15/deps/npm/html/doc/api/npm-link.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-link.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-link.html 2015-01-20 21:22:17.000000000 +0000
@@ -42,5 +42,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-load.html nodejs-0.11.15/deps/npm/html/doc/api/npm-load.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-load.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-load.html 2015-01-20 21:22:17.000000000 +0000
@@ -15,9 +15,9 @@
DESCRIPTION
npm.load() must be called before any other function call. Both parameters are
optional, but the second is recommended.
-The first parameter is an object hash of command-line config params, and the
-second parameter is a callback that will be called when npm is loaded and
-ready to serve.
+The first parameter is an object containing command-line config params, and the
+second parameter is a callback that will be called when npm is loaded and ready
+to serve.
The first parameter should follow a similar structure as the package.json
config object.
For example, to emulate the --dev flag, pass an object that looks like this:
@@ -37,5 +37,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-ls.html nodejs-0.11.15/deps/npm/html/doc/api/npm-ls.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-ls.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-ls.html 2015-01-20 21:22:17.000000000 +0000
@@ -63,5 +63,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-outdated.html nodejs-0.11.15/deps/npm/html/doc/api/npm-outdated.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-outdated.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-outdated.html 2015-01-20 21:22:17.000000000 +0000
@@ -28,5 +28,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-owner.html nodejs-0.11.15/deps/npm/html/doc/api/npm-owner.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-owner.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-owner.html 2015-01-20 21:22:17.000000000 +0000
@@ -32,8 +32,8 @@
that is not implemented at this time.
SEE ALSO
@@ -47,5 +47,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-pack.html nodejs-0.11.15/deps/npm/html/doc/api/npm-pack.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-pack.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-pack.html 2015-01-20 21:22:17.000000000 +0000
@@ -33,5 +33,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-prefix.html nodejs-0.11.15/deps/npm/html/doc/api/npm-prefix.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-prefix.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-prefix.html 2015-01-20 21:22:17.000000000 +0000
@@ -29,5 +29,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-prune.html nodejs-0.11.15/deps/npm/html/doc/api/npm-prune.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-prune.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-prune.html 2015-01-20 21:22:17.000000000 +0000
@@ -30,5 +30,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-publish.html nodejs-0.11.15/deps/npm/html/doc/api/npm-publish.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-publish.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-publish.html 2015-01-20 21:22:17.000000000 +0000
@@ -30,9 +30,9 @@
the registry. Overwrites when the "force" environment variable is set.
SEE ALSO
@@ -46,5 +46,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-rebuild.html nodejs-0.11.15/deps/npm/html/doc/api/npm-rebuild.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-rebuild.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-rebuild.html 2015-01-20 21:22:17.000000000 +0000
@@ -30,5 +30,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-repo.html nodejs-0.11.15/deps/npm/html/doc/api/npm-repo.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-repo.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-repo.html 2015-01-20 21:22:17.000000000 +0000
@@ -33,5 +33,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-restart.html nodejs-0.11.15/deps/npm/html/doc/api/npm-restart.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-restart.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-restart.html 2015-01-20 21:22:17.000000000 +0000
@@ -21,8 +21,8 @@
in the packages
parameter.
SEE ALSO
@@ -36,5 +36,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-root.html nodejs-0.11.15/deps/npm/html/doc/api/npm-root.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-root.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-root.html 2015-01-20 21:22:17.000000000 +0000
@@ -29,5 +29,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-run-script.html nodejs-0.11.15/deps/npm/html/doc/api/npm-run-script.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-run-script.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-run-script.html 2015-01-20 21:22:17.000000000 +0000
@@ -23,11 +23,11 @@
assumed to be the command to run. All other elements are ignored.
SEE ALSO
@@ -41,5 +41,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-search.html nodejs-0.11.15/deps/npm/html/doc/api/npm-search.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-search.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-search.html 2015-01-20 21:22:17.000000000 +0000
@@ -53,5 +53,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-shrinkwrap.html nodejs-0.11.15/deps/npm/html/doc/api/npm-shrinkwrap.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-shrinkwrap.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-shrinkwrap.html 2015-01-20 21:22:17.000000000 +0000
@@ -33,5 +33,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-start.html nodejs-0.11.15/deps/npm/html/doc/api/npm-start.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-start.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-start.html 2015-01-20 21:22:17.000000000 +0000
@@ -28,5 +28,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-stop.html nodejs-0.11.15/deps/npm/html/doc/api/npm-stop.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-stop.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-stop.html 2015-01-20 21:22:17.000000000 +0000
@@ -28,5 +28,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-submodule.html nodejs-0.11.15/deps/npm/html/doc/api/npm-submodule.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-submodule.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-submodule.html 2015-01-20 21:22:17.000000000 +0000
@@ -42,5 +42,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-tag.html nodejs-0.11.15/deps/npm/html/doc/api/npm-tag.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-tag.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-tag.html 2015-01-20 21:22:17.000000000 +0000
@@ -36,5 +36,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-test.html nodejs-0.11.15/deps/npm/html/doc/api/npm-test.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-test.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-test.html 2015-01-20 21:22:17.000000000 +0000
@@ -30,5 +30,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-uninstall.html nodejs-0.11.15/deps/npm/html/doc/api/npm-uninstall.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-uninstall.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-uninstall.html 2015-01-20 21:22:17.000000000 +0000
@@ -30,5 +30,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-unpublish.html nodejs-0.11.15/deps/npm/html/doc/api/npm-unpublish.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-unpublish.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-unpublish.html 2015-01-20 21:22:17.000000000 +0000
@@ -33,5 +33,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-update.html nodejs-0.11.15/deps/npm/html/doc/api/npm-update.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-update.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-update.html 2015-01-20 21:22:17.000000000 +0000
@@ -27,5 +27,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-version.html nodejs-0.11.15/deps/npm/html/doc/api/npm-version.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-version.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-version.html 2015-01-20 21:22:17.000000000 +0000
@@ -32,5 +32,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-view.html nodejs-0.11.15/deps/npm/html/doc/api/npm-view.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-view.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-view.html 2015-01-20 21:22:17.000000000 +0000
@@ -81,5 +81,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/api/npm-whoami.html nodejs-0.11.15/deps/npm/html/doc/api/npm-whoami.html
--- nodejs-0.11.14/deps/npm/html/doc/api/npm-whoami.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/api/npm-whoami.html 2015-01-20 21:22:17.000000000 +0000
@@ -29,5 +29,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-adduser.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-adduser.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-adduser.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-adduser.html 2015-01-20 21:22:17.000000000 +0000
@@ -11,11 +11,11 @@
Add a registry user account
SYNOPSIS
-npm adduser [--registry=url] [--scope=@orgname]
+npm adduser [--registry=url] [--scope=@orgname] [--always-auth]
DESCRIPTION
Create or verify a user named <username>
in the specified registry, and
save the credentials to the .npmrc
file. If no registry is specified,
-the default registry will be used (see npm-config(7)
).
+the default registry will be used (see npm-config(7)
).
The username, password, and email are read in from prompts.
You may use this command to change your email address, but not username
or password.
@@ -27,23 +27,33 @@
registry
Default: http://registry.npmjs.org/
The base URL of the npm package registry. If scope
is also specified,
-this registry will only be used for packages with that scope. See npm-scope(7)
.
+this registry will only be used for packages with that scope. See npm-scope(7)
.
scope
Default: none
If specified, the user and login credentials given will be associated
-with the specified scope. See npm-scope(7)
. You can use both at the same time,
+with the specified scope. See npm-scope(7)
. You can use both at the same time,
e.g.
npm adduser --registry=http://myregistry.example.com --scope=@myco
This will set a registry for the given scope and login or create a user for
that registry at the same time.
+always-auth
+Default: false
+If specified, save configuration indicating that all requests to the given
+registry should include authorization information. Useful for private
+registries. Can be used with --registry
and / or --scope
, e.g.
+npm adduser --registry=http://private-registry.example.com --always-auth
+
This will ensure that all requests to that registry (including for tarballs)
+include an authorization header. See always-auth
in npm-config(7)
for more
+details on always-auth. Registry-specific configuaration of always-auth
takes
+precedence over any global configuration.
SEE ALSO
@@ -57,5 +67,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-bin.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-bin.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-bin.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-bin.html 2015-01-20 21:22:17.000000000 +0000
@@ -16,12 +16,12 @@
Print the folder where npm will install executables.
SEE ALSO
@@ -35,5 +35,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-bugs.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-bugs.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-bugs.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-bugs.html 2015-01-20 21:22:17.000000000 +0000
@@ -33,14 +33,14 @@
The base URL of the npm package registry.
SEE ALSO
@@ -54,5 +54,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-build.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-build.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-build.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-build.html 2015-01-20 21:22:17.000000000 +0000
@@ -21,10 +21,10 @@
It should generally not be called directly.
SEE ALSO
@@ -38,5 +38,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-bundle.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-bundle.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-bundle.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-bundle.html 2015-01-20 21:22:17.000000000 +0000
@@ -17,7 +17,7 @@
Just use npm install
now to do what npm bundle
used to do.
SEE ALSO
@@ -31,5 +31,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-cache.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-cache.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-cache.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-cache.html 2015-01-20 21:22:17.000000000 +0000
@@ -61,13 +61,13 @@
The root cache folder.
SEE ALSO
@@ -81,5 +81,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-completion.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-completion.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-completion.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-completion.html 2015-01-20 21:22:17.000000000 +0000
@@ -26,9 +26,9 @@
completions based on the arguments.
SEE ALSO
@@ -42,5 +42,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-config.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-config.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-config.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-config.html 2015-01-20 21:22:17.000000000 +0000
@@ -22,8 +22,8 @@
DESCRIPTION
npm gets its config settings from the command line, environment
variables, npmrc
files, and in some cases, the package.json
file.
-See npmrc(5) for more information about the npmrc files.
-See npm-config(7)
for a more thorough discussion of the mechanisms
+
See npmrc(5) for more information about the npmrc files.
+See npm-config(7)
for a more thorough discussion of the mechanisms
involved.
The npm config
command can be used to update and edit the contents
of the user and global npmrc files.
@@ -48,11 +48,11 @@
global config.
SEE ALSO
@@ -66,5 +66,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-dedupe.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-dedupe.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-dedupe.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-dedupe.html 2015-01-20 21:22:17.000000000 +0000
@@ -23,7 +23,7 @@
| `-- c@1.0.3
`-- d <-- depends on c@~1.0.9
`-- c@1.0.10
-In this case, npm-dedupe(1)
will transform the tree to:
+In this case, npm-dedupe(1)
will transform the tree to:
a
+-- b
+-- d
@@ -47,9 +47,9 @@
versions.
SEE ALSO
@@ -63,5 +63,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-deprecate.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-deprecate.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-deprecate.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-deprecate.html 2015-01-20 21:22:17.000000000 +0000
@@ -23,8 +23,8 @@
To un-deprecate a package, specify an empty string (""
) for the message
argument.
SEE ALSO
@@ -38,5 +38,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-docs.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-docs.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-docs.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-docs.html 2015-01-20 21:22:17.000000000 +0000
@@ -36,13 +36,13 @@
The base URL of the npm package registry.
SEE ALSO
@@ -56,5 +56,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-edit.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-edit.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-edit.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-edit.html 2015-01-20 21:22:17.000000000 +0000
@@ -14,7 +14,7 @@
npm edit <name>[@<version>]
DESCRIPTION
Opens the package folder in the default editor (or whatever you've
-configured as the npm editor
config -- see npm-config(7)
.)
+configured as the npm editor
config -- see npm-config(7)
.)
After it has been edited, the package is rebuilt so as to pick up any
changes in compiled packages.
For instance, you can do npm install connect
to install connect
@@ -30,12 +30,12 @@
The command to run for npm edit
or npm config edit
.
SEE ALSO
@@ -49,5 +49,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-explore.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-explore.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-explore.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-explore.html 2015-01-20 21:22:17.000000000 +0000
@@ -31,12 +31,11 @@
The shell to run for the npm explore
command.
SEE ALSO
@@ -50,5 +49,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-help.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-help.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-help.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-help.html 2015-01-20 21:22:17.000000000 +0000
@@ -29,16 +29,16 @@
Set to "browser"
to view html help content in the default web browser.
SEE ALSO
@@ -52,5 +52,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-help-search.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-help-search.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-help-search.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-help-search.html 2015-01-20 21:22:17.000000000 +0000
@@ -30,9 +30,9 @@
If false, then help-search will just list out the help topics found.
SEE ALSO
@@ -46,5 +46,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm.html nodejs-0.11.15/deps/npm/html/doc/cli/npm.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm.html 2015-01-20 21:22:17.000000000 +0000
@@ -13,7 +13,7 @@
SYNOPSIS
npm <command> [args]
VERSION
-2.0.0
+2.1.6
DESCRIPTION
npm is the package manager for the Node JavaScript platform. It puts
modules in place so that node can find them, and manages dependency
@@ -25,7 +25,7 @@
INTRODUCTION
You probably got npm because you want to install stuff.
Use npm install blerg
to install the latest version of "blerg". Check out
-npm-install(1)
for more info. It can do a lot of stuff.
+npm-install(1)
for more info. It can do a lot of stuff.
Use the npm search
command to show everything that's available.
Use npm ls
to show everything you've installed.
DEPENDENCIES
@@ -42,7 +42,7 @@
the node-gyp repository and
the node-gyp Wiki .
DIRECTORIES
-See npm-folders(5)
to learn about where npm puts stuff.
+See npm-folders(5)
to learn about where npm puts stuff.
In particular, npm has two modes of operation:
global mode: npm installs packages into the install prefix at
@@ -58,7 +58,7 @@
following help topics:
link:
For linking your current working code into Node's path, so that you
don't have to reinstall every time you make a change. Use
@@ -93,12 +93,12 @@
Defaults: npm's default configuration options are defined in
lib/utils/config-defs.js. These must not be changed.
-See npm-config(7)
for much much more information.
+See npm-config(7)
for much much more information.
CONTRIBUTIONS
Patches welcome!
Be sure to include all of the output from the npm command that didn't work
as expected. The npm-debug.log
file is also helpful to provide.
@@ -128,19 +128,19 @@
Isaac Z. Schlueter ::
isaacs ::
@izs ::
-i@izs.me
+i@izs.me
SEE ALSO
@@ -154,5 +154,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-init.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-init.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-init.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-init.html 2015-01-20 21:22:17.000000000 +0000
@@ -11,7 +11,7 @@
Interactively create a package.json file
SYNOPSIS
-npm init
+npm init [-f|--force|-y|--yes]
DESCRIPTION
This will ask you a bunch of questions, and then write a package.json for you.
It attempts to make reasonable guesses about what you want things to be set to,
@@ -20,11 +20,13 @@
the options in there.
It is strictly additive, so it does not delete options from your package.json
without a really good reason to do so.
+If you invoke it with -f
, --force
, -y
, or --yes
, it will use only
+defaults and not prompt you for any options.
SEE ALSO
@@ -38,5 +40,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-install.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-install.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-install.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-install.html 2015-01-20 21:22:17.000000000 +0000
@@ -23,13 +23,13 @@
DESCRIPTION
This command installs a package, and any packages that it depends on. If the
package has a shrinkwrap file, the installation of dependencies will be driven
-by that. See npm-shrinkwrap(1) .
+by that. See npm-shrinkwrap(1) .
A package
is:
a) a folder containing a program described by a package.json file
b) a gzipped tarball containing (a)
c) a url that resolves to (b)
-d) a <name>@<version>
that is published on the registry (see npm-registry(7)
) with (c)
+d) a <name>@<version>
that is published on the registry (see npm-registry(7)
) with (c)
e) a <name>@<tag>
that points to (d)
f) a <name>
that has a "latest" tag satisfying (e)
g) a <git remote url>
that resolves to (b)
@@ -66,7 +66,7 @@
npm install [@<scope>/]<name> [--save|--save-dev|--save-optional]
:
Do a <name>@<tag>
install, where <tag>
is the "tag" config. (See
- npm-config(7)
.)
+ npm-config(7)
.)
In most cases, this will install the latest version
of the module published on npm.
Example:
@@ -87,7 +87,7 @@
operator.
<scope>
is optional. The package will be downloaded from the registry
associated with the specified scope. If no registry is associated with
-the given scope the default registry is assumed. See npm-scope(7)
.
+the given scope the default registry is assumed. See npm-scope(7)
.
Note: if you do not include the @-symbol on your scope name, npm will
interpret this as a GitHub repository instead, see below. Scopes names
must also be followed by a slash.
@@ -123,7 +123,7 @@
npm install [@<scope>/]<name>@<version range>
:
Install a version of the package matching the specified version range. This
- will follow the same rules for resolving dependencies described in package.json(5)
.
+ will follow the same rules for resolving dependencies described in package.json(5)
.
Note that most version ranges must be put in quotes so that your shell will
treat it as a single argument.
Example:
@@ -161,7 +161,7 @@
local copy exists on disk.
npm install sax --force
The --global
argument will cause npm to install the package globally
-rather than locally. See npm-folders(5)
.
+rather than locally. See npm-folders(5)
.
The --link
argument will cause npm to link global installs into the
local space in some cases.
The --no-bin-links
argument will prevent npm from creating symlinks for
@@ -172,7 +172,7 @@
shrinkwrap file and use the package.json instead.
The --nodedir=/path/to/node/source
argument will allow npm to find the
node source code so that npm can compile native modules.
-See npm-config(7)
. Many of the configuration params have some
+
See npm-config(7)
. Many of the configuration params have some
effect on installation, since that's most of what npm does.
ALGORITHM
To install a package, npm uses the following algorithm:
@@ -193,7 +193,7 @@
`-- D
That is, the dependency from B to C is satisfied by the fact that A
already caused C to be installed at a higher level.
-See npm-folders(5) for a more detailed description of the specific
+
See npm-folders(5) for a more detailed description of the specific
folder structures that npm creates.
Limitations of npm's Install Algorithm
There are some very rare and pathological edge-cases where a cycle can
@@ -213,19 +213,19 @@
affects a real use-case, it will be investigated.
SEE ALSO
@@ -239,5 +239,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-link.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-link.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-link.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-link.html 2015-01-20 21:22:17.000000000 +0000
@@ -18,12 +18,12 @@
Package linking is a two-step process.
First, npm link
in a package folder will create a globally-installed
symbolic link from prefix/package-name
to the current folder (see
-npm-config(7)
for the value of prefix
).
+npm-config(7)
for the value of prefix
).
Next, in some other location, npm link package-name
will create a
symlink from the local node_modules
folder to the global symlink.
Note that package-name
is taken from package.json
,
not from directory name.
-The package name can be optionally prefixed with a scope. See npm-scope(7)
.
+
The package name can be optionally prefixed with a scope. See npm-scope(7)
.
The scope must by preceded by an @-symbol and followed by a slash.
When creating tarballs for npm publish
, the linked packages are
"snapshotted" to their current state by resolving the symbolic links.
@@ -45,19 +45,19 @@
npm link redis
That is, it first creates a global link, and then links the global
installation target into your project's node_modules
folder.
-If your linked package is scoped (see npm-scope(7)
) your link command must
+
If your linked package is scoped (see npm-scope(7)
) your link command must
include that scope, e.g.
npm link @myorg/privatepackage
SEE ALSO
@@ -71,5 +71,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-ls.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-ls.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-ls.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-ls.html 2015-01-20 21:22:17.000000000 +0000
@@ -22,7 +22,7 @@
limit the results to only the paths to the packages named. Note that
nested packages will also show the paths to the specified packages.
For example, running npm ls promzard
in npm's source tree will show:
-npm@2.0.0 /path/to/npm
+npm@2.1.6 /path/to/npm
└─┬ init-package-json@0.0.4
└── promzard@0.1.5
It will print out extraneous, missing, and invalid packages.
@@ -63,15 +63,15 @@
Max display depth of the dependency tree.
SEE ALSO
@@ -85,5 +85,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-outdated.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-outdated.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-outdated.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-outdated.html 2015-01-20 21:22:17.000000000 +0000
@@ -51,9 +51,9 @@
Max depth for checking dependency tree.
SEE ALSO
@@ -67,5 +67,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-owner.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-owner.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-owner.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-owner.html 2015-01-20 21:22:17.000000000 +0000
@@ -32,10 +32,10 @@
that is not implemented at this time.
SEE ALSO
@@ -49,5 +49,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-pack.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-pack.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-pack.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-pack.html 2015-01-20 21:22:17.000000000 +0000
@@ -23,11 +23,11 @@
If no arguments are supplied, then npm packs the current package folder.
SEE ALSO
@@ -41,5 +41,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-prefix.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-prefix.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-prefix.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-prefix.html 2015-01-20 21:22:17.000000000 +0000
@@ -16,15 +16,15 @@
Print the local prefix to standard out. This is the closest parent directory
to contain a package.json file unless -g
is also specified.
If -g
is specified, this will be the value of the global prefix. See
-npm-config(7)
for more detail.
+npm-config(7)
for more detail.
SEE ALSO
@@ -38,5 +38,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-prune.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-prune.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-prune.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-prune.html 2015-01-20 21:22:17.000000000 +0000
@@ -23,9 +23,9 @@
packages specified in your devDependencies
.
SEE ALSO
@@ -39,5 +39,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-publish.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-publish.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-publish.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-publish.html 2015-01-20 21:22:17.000000000 +0000
@@ -14,10 +14,12 @@
npm publish <tarball> [--tag <tag>]
npm publish <folder> [--tag <tag>]
DESCRIPTION
-Publishes a package to the registry so that it can be installed by name.
+Publishes a package to the registry so that it can be installed by name. See
+npm-developers(7)
for details on what's included in the published package, as
+well as details on how the package is built.
By default npm will publish to the public registry. This can be overridden by
-specifying a different default registry or using a npm-scope(7)
in the name
-(see package.json(5)
).
+specifying a different default registry or using a npm-scope(7)
in the name
+(see package.json(5)
).
<folder>
:
A folder containing a package.json file
@@ -36,14 +38,14 @@
the specified registry.
Once a package is published with a given name and version, that
specific name and version combination can never be used again, even if
-it is removed with npm-unpublish(1) .
+it is removed with npm-unpublish(1) .
SEE ALSO
@@ -57,5 +59,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-rebuild.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-rebuild.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-rebuild.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-rebuild.html 2015-01-20 21:22:17.000000000 +0000
@@ -23,8 +23,8 @@
the new binary.
SEE ALSO
@@ -38,5 +38,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-repo.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-repo.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-repo.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-repo.html 2015-01-20 21:22:17.000000000 +0000
@@ -27,8 +27,8 @@
The browser that is called by the npm repo
command to open websites.
SEE ALSO
@@ -42,5 +42,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-restart.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-restart.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-restart.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-restart.html 2015-01-20 21:22:17.000000000 +0000
@@ -13,17 +13,15 @@
SYNOPSIS
npm restart [-- <args>]
DESCRIPTION
-This runs a package's "restart" script, if one was provided.
-Otherwise it runs package's "stop" script, if one was provided, and then
-the "start" script.
-If no version is specified, then it restarts the "active" version.
+This runs a package's "restart" script, if one was provided. Otherwise it runs
+package's "stop" script, if one was provided, and then the "start" script.
SEE ALSO
@@ -37,5 +35,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-rm.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-rm.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-rm.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-rm.html 2015-01-20 21:22:17.000000000 +0000
@@ -20,12 +20,12 @@
on its behalf.
SEE ALSO
@@ -39,5 +39,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-root.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-root.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-root.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-root.html 2015-01-20 21:22:17.000000000 +0000
@@ -16,12 +16,12 @@
Print the effective node_modules
folder to standard out.
SEE ALSO
@@ -35,5 +35,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-run-script.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-run-script.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-run-script.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-run-script.html 2015-01-20 21:22:17.000000000 +0000
@@ -20,13 +20,20 @@
is provided, it will list the available top level scripts.
It is used by the test, start, restart, and stop commands, but can be
called directly, as well.
+As of npm@2.0.0
, you can
+use custom arguments when executing scripts. The special option --
is used by
+getopt to delimit the end of the options. npm will pass
+all the arguments after the --
directly to your script:
+npm run test -- --grep="pattern"
+
The arguments will only be passed to the script specified after npm run
+and not to any pre or post script.
SEE ALSO
@@ -40,5 +47,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-search.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-search.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-search.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-search.html 2015-01-20 21:22:17.000000000 +0000
@@ -31,11 +31,11 @@
fall on multiple lines.
SEE ALSO
@@ -49,5 +49,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-shrinkwrap.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-shrinkwrap.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-shrinkwrap.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-shrinkwrap.html 2015-01-20 21:22:17.000000000 +0000
@@ -120,7 +120,7 @@
Run "npm shrinkwrap", commit the new npm-shrinkwrap.json, and
publish your package.
-You can use npm-outdated(1) to view dependencies with newer versions
+
You can use npm-outdated(1) to view dependencies with newer versions
available.
Other Notes
A shrinkwrap file must be consistent with the package's package.json
@@ -148,9 +148,9 @@
contents rather than versions.
SEE ALSO
@@ -164,5 +164,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-star.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-star.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-star.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-star.html 2015-01-20 21:22:17.000000000 +0000
@@ -20,9 +20,9 @@
It's a boolean thing. Starring repeatedly has no additional effect.
SEE ALSO
@@ -36,5 +36,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-stars.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-stars.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-stars.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-stars.html 2015-01-20 21:22:17.000000000 +0000
@@ -20,10 +20,10 @@
you will most certainly enjoy this command.
SEE ALSO
@@ -37,5 +37,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-start.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-start.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-start.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-start.html 2015-01-20 21:22:17.000000000 +0000
@@ -16,11 +16,11 @@
This runs a package's "start" script, if one was provided.
SEE ALSO
@@ -34,5 +34,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-stop.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-stop.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-stop.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-stop.html 2015-01-20 21:22:17.000000000 +0000
@@ -16,11 +16,11 @@
This runs a package's "stop" script, if one was provided.
SEE ALSO
@@ -34,5 +34,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-submodule.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-submodule.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-submodule.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-submodule.html 2015-01-20 21:22:17.000000000 +0000
@@ -27,7 +27,7 @@
dependencies into the submodule folder.
SEE ALSO
@@ -42,5 +42,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-tag.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-tag.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-tag.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-tag.html 2015-01-20 21:22:17.000000000 +0000
@@ -24,13 +24,13 @@
Publishing a package always sets the "latest" tag to the published version.
SEE ALSO
@@ -44,5 +44,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-test.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-test.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-test.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-test.html 2015-01-20 21:22:17.000000000 +0000
@@ -19,11 +19,11 @@
true.
SEE ALSO
@@ -37,5 +37,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-uninstall.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-uninstall.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-uninstall.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-uninstall.html 2015-01-20 21:22:17.000000000 +0000
@@ -30,7 +30,7 @@
--save-optional
: Package will be removed from your optionalDependencies
.
-Scope is optional and follows the usual rules for npm-scope(7)
.
+Scope is optional and follows the usual rules for npm-scope(7)
.
Examples:
npm uninstall sax --save
npm uninstall @myorg/privatepackage --save
@@ -38,12 +38,12 @@
npm uninstall dtrace-provider --save-optional
SEE ALSO
@@ -57,5 +57,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-unpublish.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-unpublish.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-unpublish.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-unpublish.html 2015-01-20 21:22:17.000000000 +0000
@@ -26,14 +26,14 @@
Even if a package version is unpublished, that specific name and
version combination can never be reused. In order to publish the
package again, a new version number must be used.
-The scope is optional and follows the usual rules for npm-scope(7)
.
+The scope is optional and follows the usual rules for npm-scope(7)
.
SEE ALSO
@@ -47,5 +47,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-update.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-update.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-update.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-update.html 2015-01-20 21:22:17.000000000 +0000
@@ -22,11 +22,11 @@
or local) will be updated.
SEE ALSO
@@ -40,5 +40,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-version.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-version.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-version.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-version.html 2015-01-20 21:22:17.000000000 +0000
@@ -39,9 +39,9 @@
Enter passphrase:
SEE ALSO
@@ -55,5 +55,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-view.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-view.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-view.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-view.html 2015-01-20 21:22:17.000000000 +0000
@@ -46,7 +46,7 @@
npm view express contributors.name contributors.email
"Person" fields are shown as a string if they would be shown as an
object. So, for example, this will show the list of npm contributors in
-the shortened string format. (See package.json(5)
for more on this.)
+the shortened string format. (See package.json(5)
for more on this.)
npm view npm contributors
If a version range is provided, then data will be printed for every
matching version of the package. This will show which version of jsdom
@@ -63,12 +63,12 @@
the field name.
SEE ALSO
@@ -82,5 +82,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/cli/npm-whoami.html nodejs-0.11.15/deps/npm/html/doc/cli/npm-whoami.html
--- nodejs-0.11.14/deps/npm/html/doc/cli/npm-whoami.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/cli/npm-whoami.html 2015-01-20 21:22:17.000000000 +0000
@@ -16,10 +16,10 @@
Print the username
config to standard output.
SEE ALSO
@@ -33,5 +33,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/files/npm-folders.html nodejs-0.11.15/deps/npm/html/doc/files/npm-folders.html
--- nodejs-0.11.14/deps/npm/html/doc/files/npm-folders.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/files/npm-folders.html 2015-01-20 21:22:17.000000000 +0000
@@ -44,7 +44,7 @@
Scoped packages are installed the same way, except they are grouped together
in a sub-folder of the relevant node_modules
folder with the name of that
scope prefix by the @ symbol, e.g. npm install @myorg/package
would place
-the package in {prefix}/node_modules/@myorg/package
. See scopes(7)
for
+the package in {prefix}/node_modules/@myorg/package
. See scopes(7)
for
more details.
If you wish to require()
a package, then install it locally.
Executables
@@ -59,7 +59,7 @@
When in local mode, man pages are not installed.
Man pages are not installed on Windows systems.
Cache
-See npm-cache(1)
. Cache files are stored in ~/.npm
on Posix, or
+
See npm-cache(1)
. Cache files are stored in ~/.npm
on Posix, or
~/npm-cache
on Windows.
This is controlled by the cache
configuration param.
Temp Files
@@ -159,18 +159,18 @@
not be included in the package tarball.
This allows a package maintainer to install all of their dependencies
(and dev dependencies) locally, but only re-publish those items that
-cannot be found elsewhere. See package.json(5)
for more information.
+cannot be found elsewhere. See package.json(5)
for more information.
SEE ALSO
@@ -184,5 +184,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/files/npm-global.html nodejs-0.11.15/deps/npm/html/doc/files/npm-global.html
--- nodejs-0.11.14/deps/npm/html/doc/files/npm-global.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/files/npm-global.html 2015-01-20 21:22:17.000000000 +0000
@@ -1,9 +1,9 @@
- npm-folders
+ npm-global
-
+
@@ -44,7 +44,7 @@
Scoped packages are installed the same way, except they are grouped together
in a sub-folder of the relevant node_modules
folder with the name of that
scope prefix by the @ symbol, e.g. npm install @myorg/package
would place
-the package in {prefix}/node_modules/@myorg/package
. See scopes(7)
for
+the package in {prefix}/node_modules/@myorg/package
. See scopes(7)
for
more details.
If you wish to require()
a package, then install it locally.
Executables
@@ -59,7 +59,7 @@
When in local mode, man pages are not installed.
Man pages are not installed on Windows systems.
Cache
-See npm-cache(1)
. Cache files are stored in ~/.npm
on Posix, or
+
See npm-cache(1)
. Cache files are stored in ~/.npm
on Posix, or
~/npm-cache
on Windows.
This is controlled by the cache
configuration param.
Temp Files
@@ -159,18 +159,18 @@
not be included in the package tarball.
This allows a package maintainer to install all of their dependencies
(and dev dependencies) locally, but only re-publish those items that
-cannot be found elsewhere. See package.json(5)
for more information.
+cannot be found elsewhere. See package.json(5)
for more information.
SEE ALSO
@@ -184,5 +184,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/files/npm-json.html nodejs-0.11.15/deps/npm/html/doc/files/npm-json.html
--- nodejs-0.11.14/deps/npm/html/doc/files/npm-json.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/files/npm-json.html 2015-01-20 21:22:17.000000000 +0000
@@ -1,9 +1,9 @@
- package.json
+ npm-json
-
+
@@ -14,7 +14,7 @@
This document is all you need to know about what's required in your package.json
file. It must be actual JSON, not just a JavaScript object literal.
A lot of the behavior described in this document is affected by the config
-settings described in npm-config(7)
.
+settings described in npm-config(7)
.
name
The most important things in your package.json are the name and version fields.
Those are actually required, and your package won't install without
@@ -35,7 +35,7 @@
already, before you get too attached to it. http://registry.npmjs.org/
A name can be optionally prefixed by a scope, e.g. @myorg/mypackage
. See
-npm-scope(7)
for more detail.
+npm-scope(7)
for more detail.
version
The most important things in your package.json are the name and version fields.
Those are actually required, and your package won't install without
@@ -45,7 +45,7 @@
Version must be parseable by
node-semver , which is bundled
with npm as a dependency. (npm install semver
to use it yourself.)
-More on version numbers and ranges at semver(7) .
+More on version numbers and ranges at semver(7) .
description
Put a description in it. It's a string. This helps people discover your
package, as it's listed in npm search
.
@@ -161,16 +161,16 @@
directories
The CommonJS Packages spec details a
few ways that you can indicate the structure of your package using a directories
-hash. If you look at npm's package.json ,
+object. If you look at npm's package.json ,
you'll see that it has directories for doc, lib, and man.
In the future, this information may be used in other creative ways.
directories.lib
Tell people where the bulk of your library is. Nothing special is done
with the lib folder in any way, but it's useful meta info.
directories.bin
-If you specify a "bin" directory, then all the files in that folder will
-be used as the "bin" hash.
-If you have a "bin" hash already, then this has no effect.
+If you specify a bin
directory, then all the files in that folder will
+be added as children of the bin
path.
+If you have a bin
path already, then this has no effect.
directories.man
A folder that is full of man pages. Sugar to generate a "man" array by
walking the folder.
@@ -197,37 +197,37 @@
directly to a VCS program without any modification. It should not be a url to an
html project page that you put in your browser. It's for computers.
scripts
-The "scripts" member is an object hash of script commands that are run
+
The "scripts" property is a dictionary containing script commands that are run
at various times in the lifecycle of your package. The key is the lifecycle
event, and the value is the command to run at that point.
-See npm-scripts(7)
to find out more about writing package scripts.
+See npm-scripts(7)
to find out more about writing package scripts.
config
-A "config" hash can be used to set configuration
-parameters used in package scripts that persist across upgrades. For
-instance, if a package had the following:
+A "config" object can be used to set configuration parameters used in package
+scripts that persist across upgrades. For instance, if a package had the
+following:
{ "name" : "foo"
, "config" : { "port" : "8080" } }
and then had a "start" command that then referenced the
npm_package_config_port
environment variable, then the user could
override that by doing npm config set foo:port 8001
.
-See npm-config(7)
and npm-scripts(7)
for more on package
+
See npm-config(7)
and npm-scripts(7)
for more on package
configs.
dependencies
-Dependencies are specified with a simple hash of package name to
+
Dependencies are specified in a simple object that maps a package name to a
version range. The version range is a string which has one or more
-space-separated descriptors. Dependencies can also be identified with
-a tarball or git URL.
+space-separated descriptors. Dependencies can also be identified with a
+tarball or git URL.
Please do not put test harnesses or transpilers in your
-dependencies
hash. See devDependencies
, below.
-See semver(7) for more details about specifying version ranges.
+dependencies
object. See devDependencies
, below.
+See semver(7) for more details about specifying version ranges.
version
Must match version
exactly
>version
Must be greater than version
>=version
etc
<version
<=version
-~version
"Approximately equivalent to version" See semver(7)
-^version
"Compatible with version" See semver(7)
+~version
"Approximately equivalent to version" See semver(7)
+^version
"Compatible with version" See semver(7)
1.2.x
1.2.0, 1.2.1, etc., but not 1.3.0
http://...
See 'URLs as Dependencies' below
*
Matches any version
@@ -236,7 +236,7 @@
range1 || range2
Passes if either range1 or range2 are satisfied.
git...
See 'Git URLs as Dependencies' below
user/repo
See 'GitHub URLs' below
-tag
A specific version tagged and published as tag
See npm-tag(1)
+tag
A specific version tagged and published as tag
See npm-tag(1)
path/path/path
See Local Paths below
For example, these are all valid:
@@ -252,7 +252,7 @@
, "two" : "2.x"
, "thr" : "3.3.x"
, "lat" : "latest"
- , "dyl" : "~/projects/dyl"
+ , "dyl" : "file:../dyl"
}
}
URLs as Dependencies
@@ -278,12 +278,21 @@
}
}
Local Paths
-As of version 2.0.0 you can provide a path to a local directory that
-contains a package. Local paths can be in the form:
+As of version 2.0.0 you can provide a path to a local directory that contains a
+package. Local paths can be saved using npm install --save
, using any of
+these forms:
../foo/bar
~/foo/bar
./foo/bar
/foo/bar
+
in which case they will be normalized to a relative path and added to your
+package.json
. For example:
+{
+ "name": "baz",
+ "dependencies": {
+ "bar": "file:../foo/bar"
+ }
+}
This feature is helpful for local offline development and creating
tests that require npm installing where you don't want to hit an
external server, but should not be used when publishing packages
@@ -292,11 +301,11 @@
If someone is planning on downloading and using your module in their
program, then they probably don't want or need to download and build
the external test or documentation framework that you use.
-In this case, it's best to list these additional items in a
-devDependencies
hash.
+In this case, it's best to map these additional items in a devDependencies
+object.
These things will be installed when doing npm link
or npm install
from the root of a package, and can be managed like any other npm
-configuration param. See npm-config(7)
for more on the topic.
+configuration param. See npm-config(7)
for more on the topic.
For build steps that are not platform-specific, such as compiling
CoffeeScript or other languages to JavaScript, use the prepublish
script to do this, and make the required package a devDependency.
@@ -346,11 +355,11 @@
Array of package names that will be bundled when publishing the package.
If this is spelled "bundleDependencies"
, then that is also honorable.
optionalDependencies
-If a dependency can be used, but you would like npm to proceed if it
-cannot be found or fails to install, then you may put it in the
-optionalDependencies
hash. This is a map of package name to version
-or url, just like the dependencies
hash. The difference is that
-failure is tolerated.
+If a dependency can be used, but you would like npm to proceed if it cannot be
+found or fails to install, then you may put it in the optionalDependencies
+object. This is a map of package name to version or url, just like the
+dependencies
object. The difference is that build failures do not cause
+installation to fail.
It is still your program's responsibility to handle the lack of the
dependency. For example, something like this:
try {
@@ -385,11 +394,11 @@
field is advisory only.
engineStrict
If you are sure that your module will definitely not run properly on
-versions of Node/npm other than those specified in the engines
hash,
+versions of Node/npm other than those specified in the engines
object,
then you can set "engineStrict": true
in your package.json file.
This will override the user's engine-strict
config setting.
Please do not do this unless you are really very very sure. If your
-engines hash is something overly restrictive, you can quite easily and
+engines object is something overly restrictive, you can quite easily and
inadvertently lock yourself into obscurity and prevent your users from
updating to new versions of Node. Consider this choice carefully. If
people abuse it, it will be removed in a future version of npm.
@@ -419,11 +428,11 @@
private
If you set "private": true
in your package.json, then npm will refuse
to publish it.
-This is a way to prevent accidental publication of private repositories.
-If you would like to ensure that a given package is only ever published
-to a specific registry (for example, an internal registry),
-then use the publishConfig
hash described below
-to override the registry
config param at publish-time.
+This is a way to prevent accidental publication of private repositories. If
+you would like to ensure that a given package is only ever published to a
+specific registry (for example, an internal registry), then use the
+publishConfig
dictionary described below to override the registry
config
+param at publish-time.
publishConfig
This is a set of config values that will be used at publish-time. It's
especially handy if you want to set the tag or registry, so that you can
@@ -431,7 +440,7 @@
the global public registry by default.
Any config values can be overridden, but of course only "tag" and
"registry" probably matter for the purposes of publishing.
-See npm-config(7)
to see the list of config options that can be
+
See npm-config(7)
to see the list of config options that can be
overridden.
DEFAULT VALUES
npm will default some values based on package contents.
@@ -453,16 +462,16 @@
SEE ALSO
@@ -476,5 +485,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/files/npmrc.html nodejs-0.11.15/deps/npm/html/doc/files/npmrc.html
--- nodejs-0.11.14/deps/npm/html/doc/files/npmrc.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/files/npmrc.html 2015-01-20 21:22:17.000000000 +0000
@@ -15,7 +15,7 @@
variables, and npmrc
files.
The npm config
command can be used to update and edit the contents
of the user and global npmrc files.
-For a list of available configuration options, see npm-config(7) .
+For a list of available configuration options, see npm-config(7) .
FILES
The four relevant files are:
@@ -55,11 +55,11 @@
manner.
SEE ALSO
@@ -73,5 +73,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/files/package.json.html nodejs-0.11.15/deps/npm/html/doc/files/package.json.html
--- nodejs-0.11.14/deps/npm/html/doc/files/package.json.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/files/package.json.html 2015-01-20 21:22:17.000000000 +0000
@@ -14,7 +14,7 @@
This document is all you need to know about what's required in your package.json
file. It must be actual JSON, not just a JavaScript object literal.
A lot of the behavior described in this document is affected by the config
-settings described in npm-config(7)
.
+settings described in npm-config(7)
.
name
The most important things in your package.json are the name and version fields.
Those are actually required, and your package won't install without
@@ -35,7 +35,7 @@
already, before you get too attached to it. http://registry.npmjs.org/
A name can be optionally prefixed by a scope, e.g. @myorg/mypackage
. See
-npm-scope(7)
for more detail.
+npm-scope(7)
for more detail.
version
The most important things in your package.json are the name and version fields.
Those are actually required, and your package won't install without
@@ -45,7 +45,7 @@
Version must be parseable by
node-semver , which is bundled
with npm as a dependency. (npm install semver
to use it yourself.)
-More on version numbers and ranges at semver(7) .
+More on version numbers and ranges at semver(7) .
description
Put a description in it. It's a string. This helps people discover your
package, as it's listed in npm search
.
@@ -161,16 +161,16 @@
directories
The CommonJS Packages spec details a
few ways that you can indicate the structure of your package using a directories
-hash. If you look at npm's package.json ,
+object. If you look at npm's package.json ,
you'll see that it has directories for doc, lib, and man.
In the future, this information may be used in other creative ways.
directories.lib
Tell people where the bulk of your library is. Nothing special is done
with the lib folder in any way, but it's useful meta info.
directories.bin
-If you specify a "bin" directory, then all the files in that folder will
-be used as the "bin" hash.
-If you have a "bin" hash already, then this has no effect.
+If you specify a bin
directory, then all the files in that folder will
+be added as children of the bin
path.
+If you have a bin
path already, then this has no effect.
directories.man
A folder that is full of man pages. Sugar to generate a "man" array by
walking the folder.
@@ -197,37 +197,37 @@
directly to a VCS program without any modification. It should not be a url to an
html project page that you put in your browser. It's for computers.
scripts
-The "scripts" member is an object hash of script commands that are run
+
The "scripts" property is a dictionary containing script commands that are run
at various times in the lifecycle of your package. The key is the lifecycle
event, and the value is the command to run at that point.
-See npm-scripts(7)
to find out more about writing package scripts.
+See npm-scripts(7)
to find out more about writing package scripts.
config
-A "config" hash can be used to set configuration
-parameters used in package scripts that persist across upgrades. For
-instance, if a package had the following:
+A "config" object can be used to set configuration parameters used in package
+scripts that persist across upgrades. For instance, if a package had the
+following:
{ "name" : "foo"
, "config" : { "port" : "8080" } }
and then had a "start" command that then referenced the
npm_package_config_port
environment variable, then the user could
override that by doing npm config set foo:port 8001
.
-See npm-config(7)
and npm-scripts(7)
for more on package
+
See npm-config(7)
and npm-scripts(7)
for more on package
configs.
dependencies
-Dependencies are specified with a simple hash of package name to
+
Dependencies are specified in a simple object that maps a package name to a
version range. The version range is a string which has one or more
-space-separated descriptors. Dependencies can also be identified with
-a tarball or git URL.
+space-separated descriptors. Dependencies can also be identified with a
+tarball or git URL.
Please do not put test harnesses or transpilers in your
-dependencies
hash. See devDependencies
, below.
-See semver(7) for more details about specifying version ranges.
+dependencies
object. See devDependencies
, below.
+See semver(7) for more details about specifying version ranges.
version
Must match version
exactly
>version
Must be greater than version
>=version
etc
<version
<=version
-~version
"Approximately equivalent to version" See semver(7)
-^version
"Compatible with version" See semver(7)
+~version
"Approximately equivalent to version" See semver(7)
+^version
"Compatible with version" See semver(7)
1.2.x
1.2.0, 1.2.1, etc., but not 1.3.0
http://...
See 'URLs as Dependencies' below
*
Matches any version
@@ -236,7 +236,7 @@
range1 || range2
Passes if either range1 or range2 are satisfied.
git...
See 'Git URLs as Dependencies' below
user/repo
See 'GitHub URLs' below
-tag
A specific version tagged and published as tag
See npm-tag(1)
+tag
A specific version tagged and published as tag
See npm-tag(1)
path/path/path
See Local Paths below
For example, these are all valid:
@@ -252,7 +252,7 @@
, "two" : "2.x"
, "thr" : "3.3.x"
, "lat" : "latest"
- , "dyl" : "~/projects/dyl"
+ , "dyl" : "file:../dyl"
}
}
URLs as Dependencies
@@ -278,12 +278,21 @@
}
}
Local Paths
-As of version 2.0.0 you can provide a path to a local directory that
-contains a package. Local paths can be in the form:
+As of version 2.0.0 you can provide a path to a local directory that contains a
+package. Local paths can be saved using npm install --save
, using any of
+these forms:
../foo/bar
~/foo/bar
./foo/bar
/foo/bar
+
in which case they will be normalized to a relative path and added to your
+package.json
. For example:
+{
+ "name": "baz",
+ "dependencies": {
+ "bar": "file:../foo/bar"
+ }
+}
This feature is helpful for local offline development and creating
tests that require npm installing where you don't want to hit an
external server, but should not be used when publishing packages
@@ -292,11 +301,11 @@
If someone is planning on downloading and using your module in their
program, then they probably don't want or need to download and build
the external test or documentation framework that you use.
-In this case, it's best to list these additional items in a
-devDependencies
hash.
+In this case, it's best to map these additional items in a devDependencies
+object.
These things will be installed when doing npm link
or npm install
from the root of a package, and can be managed like any other npm
-configuration param. See npm-config(7)
for more on the topic.
+configuration param. See npm-config(7)
for more on the topic.
For build steps that are not platform-specific, such as compiling
CoffeeScript or other languages to JavaScript, use the prepublish
script to do this, and make the required package a devDependency.
@@ -346,11 +355,11 @@
Array of package names that will be bundled when publishing the package.
If this is spelled "bundleDependencies"
, then that is also honorable.
optionalDependencies
-If a dependency can be used, but you would like npm to proceed if it
-cannot be found or fails to install, then you may put it in the
-optionalDependencies
hash. This is a map of package name to version
-or url, just like the dependencies
hash. The difference is that
-failure is tolerated.
+If a dependency can be used, but you would like npm to proceed if it cannot be
+found or fails to install, then you may put it in the optionalDependencies
+object. This is a map of package name to version or url, just like the
+dependencies
object. The difference is that build failures do not cause
+installation to fail.
It is still your program's responsibility to handle the lack of the
dependency. For example, something like this:
try {
@@ -385,11 +394,11 @@
field is advisory only.
engineStrict
If you are sure that your module will definitely not run properly on
-versions of Node/npm other than those specified in the engines
hash,
+versions of Node/npm other than those specified in the engines
object,
then you can set "engineStrict": true
in your package.json file.
This will override the user's engine-strict
config setting.
Please do not do this unless you are really very very sure. If your
-engines hash is something overly restrictive, you can quite easily and
+engines object is something overly restrictive, you can quite easily and
inadvertently lock yourself into obscurity and prevent your users from
updating to new versions of Node. Consider this choice carefully. If
people abuse it, it will be removed in a future version of npm.
@@ -419,11 +428,11 @@
private
If you set "private": true
in your package.json, then npm will refuse
to publish it.
-This is a way to prevent accidental publication of private repositories.
-If you would like to ensure that a given package is only ever published
-to a specific registry (for example, an internal registry),
-then use the publishConfig
hash described below
-to override the registry
config param at publish-time.
+This is a way to prevent accidental publication of private repositories. If
+you would like to ensure that a given package is only ever published to a
+specific registry (for example, an internal registry), then use the
+publishConfig
dictionary described below to override the registry
config
+param at publish-time.
publishConfig
This is a set of config values that will be used at publish-time. It's
especially handy if you want to set the tag or registry, so that you can
@@ -431,7 +440,7 @@
the global public registry by default.
Any config values can be overridden, but of course only "tag" and
"registry" probably matter for the purposes of publishing.
-See npm-config(7)
to see the list of config options that can be
+
See npm-config(7)
to see the list of config options that can be
overridden.
DEFAULT VALUES
npm will default some values based on package contents.
@@ -453,16 +462,16 @@
SEE ALSO
@@ -476,5 +485,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/index.html nodejs-0.11.15/deps/npm/html/doc/index.html
--- nodejs-0.11.14/deps/npm/html/doc/index.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/index.html 2015-01-20 21:22:17.000000000 +0000
@@ -1,6 +1,6 @@
- npm-index
+ index
@@ -10,217 +10,213 @@
Index of all npm documentation
-
+
node package manager
Command Line Documentation
Using npm on the command line
-
+
node package manager
-
+
Add a registry user account
-
+
Display npm bin folder
-
+
Bugs for a package in a web browser maybe
-
+
Build a package
-
+
REMOVED
-
+
Manipulates packages cache
-
+
Tab Completion for npm
-
+
Manage the npm configuration files
-
+
Reduce duplication
-
+
Deprecate a version of a package
-
+
Docs for a package in a web browser maybe
-
+
Edit an installed package
-
+
Browse an installed package
-
+
Search npm help documentation
-
+
Get help on npm
-
+
Interactively create a package.json file
-
+
Install a package
-
+
Symlink a package folder
-
+
List installed packages
-
+
Check for outdated packages
-
+
Manage package owners
-
+
Create a tarball from a package
-
+
Display prefix
-
+
Remove extraneous packages
-
+
Publish a package
-
+
Rebuild a package
-
+
Open package repository page in the browser
-
+
Start a package
-
+
Remove a package
-
+
Display npm root
-
+
Run arbitrary package scripts
-
+
Search for packages
-
+
Lock down dependency versions
-
+
Mark your favorite packages
-
+
View packages marked as favorites
-
+
Start a package
-
+
Stop a package
-
-
Add a package as a git submodule
-
+
Tag a published version
-
+
Test a package
-
+
Remove a package
-
+
Remove a package from the registry
-
+
Update a package
-
+
Bump a package version
-
+
View registry info
-
+
Display npm username
API Documentation
Using npm in your Node programs
-
+
node package manager
-
+
Display npm bin folder
-
+
Bugs for a package in a web browser maybe
-
+
manage the npm cache programmatically
-
+
npm commands
-
+
Manage the npm configuration files
-
+
Deprecate a version of a package
-
+
Docs for a package in a web browser maybe
-
+
Edit an installed package
-
+
Browse an installed package
-
+
Search the help pages
-
+
Interactively create a package.json file
-
+
install a package programmatically
-
+
Symlink a package folder
-
+
Load config settings
-
+
List installed packages
-
+
Check for outdated packages
-
+
Manage package owners
-
+
Create a tarball from a package
-
+
Display prefix
-
+
Remove extraneous packages
-
+
Publish a package
-
+
Rebuild a package
-
+
Open package repository page in the browser
-
+
Start a package
-
+
Display npm root
-
+
Run arbitrary package scripts
-
+
Search for packages
-
+
programmatically generate package shrinkwrap file
-
+
Start a package
-
+
Stop a package
-
-
Add a package as a git submodule
-
+
Tag a published version
-
+
Test a package
-
+
uninstall a package programmatically
-
+
Remove a package from the registry
-
+
Update a package
-
+
Bump a package version
-
+
View registry info
-
+
Display npm username
Files
File system structures npm uses
-
+
Folder Structures Used by npm
-
+
The npm config files
-
+
Specifics of npm's package.json handling
Misc
Various other bits and bobs
-
+
npm's "funny" coding style
-
+
More than you probably want to know about npm configuration
-
+
Developer Guide
-
+
Handling Module Name Disputes
-
+
Frequently Asked Questions
-
+
Index of all npm documentation
-
+
The JavaScript Package Registry
-
+
Scoped packages
-
+
How npm handles the "scripts" field
-
+
Cleaning the Slate
-
+
The semantic versioner for npm
@@ -234,5 +230,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/misc/npm-coding-style.html nodejs-0.11.15/deps/npm/html/doc/misc/npm-coding-style.html
--- nodejs-0.11.14/deps/npm/html/doc/misc/npm-coding-style.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/misc/npm-coding-style.html 2015-01-20 21:22:17.000000000 +0000
@@ -109,11 +109,11 @@
logging the same object over and over again is not helpful. Logs should
report what's happening so that it's easier to track down where a fault
occurs.
-Use appropriate log levels. See npm-config(7)
and search for
+
Use appropriate log levels. See npm-config(7)
and search for
"loglevel".
Case, naming, etc.
Use lowerCamelCase
for multiword identifiers when they refer to objects,
-functions, methods, members, or anything not specified in this section.
+functions, methods, properties, or anything not specified in this section.
Use UpperCamelCase
for class names (things that you'd pass to "new").
Use all-lower-hyphen-css-case
for multiword filenames and config keys.
Use named functions. They make stack traces easier to follow.
@@ -131,9 +131,9 @@
Boolean objects are verboten.
SEE ALSO
@@ -147,5 +147,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/misc/npm-config.html nodejs-0.11.15/deps/npm/html/doc/misc/npm-config.html
--- nodejs-0.11.14/deps/npm/html/doc/misc/npm-config.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/misc/npm-config.html 2015-01-20 21:22:17.000000000 +0000
@@ -33,7 +33,7 @@
global config file ($PREFIX/npmrc)
npm builtin config file (/path/to/npm/npmrc)
-See npmrc(5) for more details.
+See npmrc(5) for more details.
Default Configs
A set of configuration parameters that are internal to npm, and are
defaults if nothing else is specified.
@@ -79,7 +79,7 @@
# same as:
npm ls --global --parseable --long --loglevel info
Per-Package Config Settings
-When running scripts (see npm-scripts(7)
) the package.json "config"
+
When running scripts (see npm-scripts(7)
) the package.json "config"
keys are overwritten in the environment if there is a config param of
<name>[@<version>]:<key>
. For example, if the package.json has
this:
@@ -90,7 +90,7 @@
http.createServer(...).listen(process.env.npm_package_config_port)
then the user could change the behavior by doing:
npm config set foo:port 80
-
See package.json(5) for more information.
+See package.json(5) for more information.
Config Settings
always-auth
@@ -138,7 +138,7 @@
Default: Windows: %AppData%\npm-cache
, Posix: ~/.npm
Type: path
-The location of npm's cache directory. See npm-cache(1)
+The location of npm's cache directory. See npm-cache(1)
cache-lock-stale
Default: 60000 (1 minute)
@@ -285,7 +285,7 @@
Operates in "global" mode, so that packages are installed into the
prefix
folder instead of the current working directory. See
-npm-folders(5)
for more on the differences in behavior.
+npm-folders(5)
for more on the differences in behavior.
packages are installed into the {prefix}/lib/node_modules
folder, instead of the
current working directory.
@@ -332,32 +332,32 @@
A module that will be loaded by the npm init
command. See the
documentation for the
init-package-json module
-for more information, or npm-init(1) .
-init.author.name
+for more information, or npm-init(1) .
+init-author-name
The value npm init
should use by default for the package author's name.
-init.author.email
+init-author-email
The value npm init
should use by default for the package author's email.
-init.author.url
+init-author-url
The value npm init
should use by default for the package author's homepage.
-init.license
+init-license
Default: "ISC"
Type: String
The value npm init
should use by default for the package license.
-init.version
+init-version
Default: "0.0.0"
Type: semver
@@ -403,14 +403,14 @@
to the npm registry. Must be IPv4 in versions of Node prior to 0.12.
loglevel
-Default: "http"
+Default: "warn"
Type: String
Values: "silent", "error", "warn", "http", "info", "verbose", "silly"
What level of logs to report. On failure, all logs are written to
npm-debug.log
in the current working directory.
Any logs of a higher level than the setting are shown.
-The default is "http", which shows http, warn, and error output.
+The default is "warn", which shows warn and error output.
logstream
Default: process.stderr
@@ -441,7 +441,7 @@
Default: process.version
Type: semver or false
-The node version to use when checking package's "engines" hash.
+The node version to use when checking a package's engines
map.
npat
Default: false
@@ -460,7 +460,7 @@
Default: true
Type: Boolean
-Attempt to install packages in the optionalDependencies
hash. Note
+
Attempt to install packages in the optionalDependencies
object. Note
that if these packages fail to install, the overall installation
process is not aborted.
parseable
@@ -472,7 +472,7 @@
standard output.
prefix
The location to install global items. If set on the command line, then
@@ -528,8 +528,8 @@
Type: Boolean
Save installed packages to a package.json file as dependencies.
-When used with the npm rm
command, it removes it from the dependencies
-hash.
+When used with the npm rm
command, it removes it from the dependencies
+object.
Only works if there is already a package.json file present.
save-bundle
@@ -546,9 +546,9 @@
Default: false
Type: Boolean
-Save installed packages to a package.json file as devDependencies.
+Save installed packages to a package.json file as devDependencies
.
When used with the npm rm
command, it removes it from the
-devDependencies hash.
+devDependencies
object.
Only works if there is already a package.json file present.
save-exact
@@ -566,7 +566,7 @@
Save installed packages to a package.json file as
optionalDependencies.
When used with the npm rm
command, it removes it from the
-devDependencies hash.
+devDependencies
object.
Only works if there is already a package.json file present.
save-prefix
@@ -687,7 +687,7 @@
Type: Boolean
Set to show short usage output (like the -H output)
-instead of complete help when doing npm-help(1)
.
+instead of complete help when doing npm-help(1)
.
user
Default: "nobody"
@@ -728,8 +728,8 @@
Default: false
Type: boolean
-If true, output the npm version as well as node's process.versions
-hash, and exit successfully.
+If true, output the npm version as well as node's process.versions
map, and
+exit successfully.
Only relevant when specified explicitly on the command line.
viewer
@@ -740,12 +740,12 @@
Set to "browser"
to view html help content in the default web browser.
SEE ALSO
@@ -759,5 +759,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/misc/npm-developers.html nodejs-0.11.15/deps/npm/html/doc/misc/npm-developers.html
--- nodejs-0.11.14/deps/npm/html/doc/misc/npm-developers.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/misc/npm-developers.html 2015-01-20 21:22:17.000000000 +0000
@@ -45,7 +45,7 @@
The package.json File
You need to have a package.json
file in the root of your project to do
much of anything with npm. That is basically the whole interface.
-See package.json(5)
for details about what goes in that file. At the very
+
See package.json(5)
for details about what goes in that file. At the very
least, you need:
name:
@@ -70,9 +70,9 @@
scripts:
If you have a special compilation or installation script, then you
-should put it in the scripts
hash. You should definitely have at
+should put it in the scripts
object. You should definitely have at
least a basic smoke-test command as the "scripts.test" field.
-See npm-scripts(7) .
+See npm-scripts(7) .
main:
If you have a single module that serves as the entry point to your
@@ -80,13 +80,13 @@
then you need to specify that in the "main" field.
directories:
-This is a hash of folders. The best ones to include are "lib" and
-"doc", but if you specify a folder full of man pages in "man", then
+This is an object mapping names to folders. The best ones to include are
+"lib" and "doc", but if you use "man" to specify a folder full of man pages,
they'll get installed just like these ones.
You can use npm init
in the root of your package in order to get you
-started with a pretty basic package.json file. See npm-init(1)
for
+started with a pretty basic package.json file. See npm-init(1)
for
more info.
Keeping files out of your package
Use a .npmignore
file to keep stuff out of your package. If there's
@@ -115,14 +115,14 @@
.npmignore
is pointless:
Link Packages
npm link
is designed to install a development package and see the
changes in real time without having to keep re-installing it. (You do
need to either re-link or npm rebuild -g
to update compiled packages,
of course.)
-More info at npm-link(1)
.
+More info at npm-link(1)
.
Before Publishing: Make Sure Your Package Installs and Works
This is important.
If you can not install it locally, you'll have
@@ -145,7 +145,7 @@
Create a user with the adduser command. It works like this:
npm adduser
and then follow the prompts.
-This is documented better in npm-adduser(1) .
+This is documented better in npm-adduser(1) .
Publish your package
This part's easy. IN the root of your folder, do this:
npm publish
@@ -160,14 +160,14 @@
Tell the world how easy it is to install your program!
SEE ALSO
@@ -181,5 +181,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/misc/npm-disputes.html nodejs-0.11.15/deps/npm/html/doc/misc/npm-disputes.html
--- nodejs-0.11.14/deps/npm/html/doc/misc/npm-disputes.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/misc/npm-disputes.html 2015-01-20 21:22:17.000000000 +0000
@@ -13,7 +13,7 @@
SYNOPSIS
Get the author email with npm owner ls <pkgname>
-Email the author, CC support@npmjs.com
+Email the author, CC support@npmjs.com
After a few weeks, if there's no resolution, we'll sort it out.
Don't squat on package names. Publish code or move out of the way.
@@ -51,12 +51,12 @@
owner (Bob).
Joe emails Bob, explaining the situation as respectfully as
possible , and what he would like to do with the module name. He
-adds the npm support staff support@npmjs.com to the CC list of
+adds the npm support staff support@npmjs.com to the CC list of
the email. Mention in the email that Bob can run npm owner add
joe foo
to add Joe as an owner of the foo
package.
After a reasonable amount of time, if Bob has not responded, or if
Bob and Joe can't come to any sort of resolution, email support
-support@npmjs.com and we'll sort it out. ("Reasonable" is
+support@npmjs.com and we'll sort it out. ("Reasonable" is
usually at least 4 weeks, but extra time is allowed around common
holidays.)
@@ -97,8 +97,8 @@
If you see bad behavior like this, please report it right away.
SEE ALSO
@@ -112,5 +112,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/misc/npm-faq.html nodejs-0.11.15/deps/npm/html/doc/misc/npm-faq.html
--- nodejs-0.11.14/deps/npm/html/doc/misc/npm-faq.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/misc/npm-faq.html 2015-01-20 21:22:17.000000000 +0000
@@ -21,7 +21,7 @@
Read the error output, and if you can't figure out what it means,
do what it says and post a bug with all the information it asks for.
Where does npm put stuff?
-See npm-folders(5)
+See npm-folders(5)
tl;dr:
Use the npm root
command to see where modules go, and the npm bin
@@ -48,7 +48,7 @@
problems than it solves.
It is much harder to avoid dependency conflicts without nesting
dependencies. This is fundamental to the way that npm works, and has
-proven to be an extremely successful approach. See npm-folders(5)
for
+proven to be an extremely successful approach. See npm-folders(5)
for
more details.
If you want a package to be installed in one place, and have all your
programs reference the same copy of it, then use the npm link
command.
@@ -100,7 +100,7 @@
npm search
Arguments are greps. npm search jsdom
shows jsdom packages.
How do I update npm?
-npm update npm -g
+npm install npm -g
You can also update all outdated local packages by doing npm update
without
any arguments, or global packages by doing npm update -g
.
Occasionally, the version of npm will progress such that the current
@@ -217,18 +217,18 @@
https://github.com/nanjingboy/nvmw
How can I use npm for development?
-See npm-developers(7)
and package.json(5)
.
+See npm-developers(7)
and package.json(5)
.
You'll most likely want to npm link
your development folder. That's
awesomely handy.
-To set up your own private registry, check out npm-registry(7)
.
+To set up your own private registry, check out npm-registry(7)
.
Can I list a url as a dependency?
Yes. It should be a url to a gzipped tarball containing a single folder
that has a package.json in its root, or a git url.
(See "what is a package?" above.)
How do I symlink to a dev folder so I don't have to keep re-installing?
-See npm-link(1)
+See npm-link(1)
The package registry website. What is that exactly?
-See npm-registry(7)
.
+See npm-registry(7)
.
I forgot my password, and can't publish. How do I reset it?
Go to https://npmjs.org/forgot .
I get ECONNREFUSED a lot. What's up?
@@ -236,7 +236,7 @@
To check if the registry is down, open up
https://registry.npmjs.org/ in a web browser. This will also tell
you if you are just unable to access the internet for some reason.
-If the registry IS down, let us know by emailing support@npmjs.com
+
If the registry IS down, let us know by emailing support@npmjs.com
or posting an issue at https://github.com/npm/npm/issues . If it's
down for the world (and not just on your local network) then we're
probably already being pinged about it.
@@ -263,14 +263,14 @@
npm is not capable of hatred. It loves everyone, especially you.
SEE ALSO
@@ -284,5 +284,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/misc/npm-index.html nodejs-0.11.15/deps/npm/html/doc/misc/npm-index.html
--- nodejs-0.11.14/deps/npm/html/doc/misc/npm-index.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/misc/npm-index.html 2015-01-20 21:22:17.000000000 +0000
@@ -10,217 +10,213 @@
Index of all npm documentation
-
+
node package manager
Command Line Documentation
Using npm on the command line
-
+
node package manager
-
+
Add a registry user account
-
+
Display npm bin folder
-
+
Bugs for a package in a web browser maybe
-
+
Build a package
-
+
REMOVED
-
+
Manipulates packages cache
-
+
Tab Completion for npm
-
+
Manage the npm configuration files
-
+
Reduce duplication
-
+
Deprecate a version of a package
-
+
Docs for a package in a web browser maybe
-
+
Edit an installed package
-
+
Browse an installed package
-
+
Search npm help documentation
-
+
Get help on npm
-
+
Interactively create a package.json file
-
+
Install a package
-
+
Symlink a package folder
-
+
List installed packages
-
+
Check for outdated packages
-
+
Manage package owners
-
+
Create a tarball from a package
-
+
Display prefix
-
+
Remove extraneous packages
-
+
Publish a package
-
+
Rebuild a package
-
+
Open package repository page in the browser
-
+
Start a package
-
+
Remove a package
-
+
Display npm root
-
+
Run arbitrary package scripts
-
+
Search for packages
-
+
Lock down dependency versions
-
+
Mark your favorite packages
-
+
View packages marked as favorites
-
+
Start a package
-
+
Stop a package
-
-
Add a package as a git submodule
-
+
Tag a published version
-
+
Test a package
-
+
Remove a package
-
+
Remove a package from the registry
-
+
Update a package
-
+
Bump a package version
-
+
View registry info
-
+
Display npm username
API Documentation
Using npm in your Node programs
-
+
node package manager
-
+
Display npm bin folder
-
+
Bugs for a package in a web browser maybe
-
+
manage the npm cache programmatically
-
+
npm commands
-
+
Manage the npm configuration files
-
+
Deprecate a version of a package
-
+
Docs for a package in a web browser maybe
-
+
Edit an installed package
-
+
Browse an installed package
-
+
Search the help pages
-
+
Interactively create a package.json file
-
+
install a package programmatically
-
+
Symlink a package folder
-
+
Load config settings
-
+
List installed packages
-
+
Check for outdated packages
-
+
Manage package owners
-
+
Create a tarball from a package
-
+
Display prefix
-
+
Remove extraneous packages
-
+
Publish a package
-
+
Rebuild a package
-
+
Open package repository page in the browser
-
+
Start a package
-
+
Display npm root
-
+
Run arbitrary package scripts
-
+
Search for packages
-
+
programmatically generate package shrinkwrap file
-
+
Start a package
-
+
Stop a package
-
-
Add a package as a git submodule
-
+
Tag a published version
-
+
Test a package
-
+
uninstall a package programmatically
-
+
Remove a package from the registry
-
+
Update a package
-
+
Bump a package version
-
+
View registry info
-
+
Display npm username
Files
File system structures npm uses
-
+
Folder Structures Used by npm
-
+
The npm config files
-
+
Specifics of npm's package.json handling
Misc
Various other bits and bobs
-
+
npm's "funny" coding style
-
+
More than you probably want to know about npm configuration
-
+
Developer Guide
-
+
Handling Module Name Disputes
-
+
Frequently Asked Questions
-
+
Index of all npm documentation
-
+
The JavaScript Package Registry
-
+
Scoped packages
-
+
How npm handles the "scripts" field
-
+
Cleaning the Slate
-
+
The semantic versioner for npm
@@ -234,5 +230,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/misc/npm-registry.html nodejs-0.11.15/deps/npm/html/doc/misc/npm-registry.html
--- nodejs-0.11.14/deps/npm/html/doc/misc/npm-registry.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/misc/npm-registry.html 2015-01-20 21:22:17.000000000 +0000
@@ -22,9 +22,9 @@
http://skimdb.npmjs.com/registry . The code for the couchapp is
available at http://github.com/npm/npm-registry-couchapp .
The registry URL used is determined by the scope of the package (see
-npm-scope(7)
). If no scope is specified, the default registry is used, which is
-supplied by the registry
config parameter. See npm-config(1)
,
-npmrc(5)
, and npm-config(7)
for more on managing npm's configuration.
+npm-scope(7)
). If no scope is specified, the default registry is used, which is
+supplied by the registry
config parameter. See npm-config(1)
,
+npmrc(5)
, and npm-config(7)
for more on managing npm's configuration.
Can I run my own private registry?
Yes!
The easiest way is to replicate the couch database, and use the same (or
@@ -40,7 +40,7 @@
published at all, or
"publishConfig":{"registry":"http://my-internal-registry.local"}
to force it to be published only to your internal registry.
-See package.json(5)
for more info on what goes in the package.json file.
+See package.json(5)
for more info on what goes in the package.json file.
Will you replicate from my registry into the public one?
No. If you want things to be public, then publish them into the public
registry using npm. What little security there is would be for nought
@@ -52,11 +52,11 @@
Yes, head over to https://npmjs.org/
SEE ALSO
@@ -70,5 +70,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/misc/npm-scope.html nodejs-0.11.15/deps/npm/html/doc/misc/npm-scope.html
--- nodejs-0.11.14/deps/npm/html/doc/misc/npm-scope.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/misc/npm-scope.html 2015-01-20 21:22:17.000000000 +0000
@@ -27,15 +27,15 @@
scoped modules will be in node_modules/@myorg/packagename
. The scope folder
(@myorg
) is simply the name of the scope preceded by an @-symbol, and can
contain any number of scoped packages.
-A scoped package is install by referencing it by name, preceded by an @-symbol,
-in npm install
:
+A scoped package is installed by referencing it by name, preceded by an
+@-symbol, in npm install
:
npm install @myorg/mypackage
Or in package.json
:
"dependencies": {
"@myorg/mypackage": "^1.3.0"
}
Note that if the @-symbol is omitted in either case npm will instead attempt to
-install from GitHub; see npm-install(1)
.
+install from GitHub; see npm-install(1)
.
Requiring scoped packages
Because scoped packages are installed into a scope folder, you have to
include the name of the scope when requiring them in your code, e.g.
@@ -63,8 +63,8 @@
that registry instead.
SEE ALSO
@@ -78,5 +78,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/misc/npm-scripts.html nodejs-0.11.15/deps/npm/html/doc/misc/npm-scripts.html
--- nodejs-0.11.14/deps/npm/html/doc/misc/npm-scripts.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/misc/npm-scripts.html 2015-01-20 21:22:17.000000000 +0000
@@ -11,7 +11,7 @@
How npm handles the "scripts" field
DESCRIPTION
-npm supports the "scripts" member of the package.json script, for the
+
npm supports the "scripts" property of the package.json script, for the
following scripts:
prepublish:
@@ -41,9 +41,10 @@
Run by the npm restart
command. Note: npm restart
will run the
stop and start scripts if no restart
script is provided.
-Additionally, arbitrary scripts can be executed by running `npm run-script
- . *Pre* and *post* commands with matching names will be run for
-those as well (e.g.
premyscript,
myscript,
postmyscript`).
+Additionally, arbitrary scripts can be executed by running npm
+run-script <pkg> <stage>
. Pre and post commands with matching
+names will be run for those as well (e.g. premyscript
, myscript
,
+postmyscript
).
NOTE: INSTALL SCRIPTS ARE AN ANTIPATTERN
tl;dr Don't use install
. Use a .gyp
file for compilation, and
prepublish
for anything else.
@@ -123,7 +124,7 @@
Configuration parameters are put in the environment with the
npm_config_
prefix. For instance, you can view the effective root
config by checking the npm_config_root
environment variable.
-Special: package.json "config" hash
+Special: package.json "config" object
The package.json "config" keys are overwritten in the environment if
there is a config param of <name>[@<version>]:<key>
. For example,
if the package.json has this:
@@ -189,7 +190,7 @@
only will prevent some optional features, then it's better to just
print a warning and exit successfully.
Try not to use scripts to do what npm can do for you. Read through
-package.json(5)
to see all the things that you can specify and enable
+package.json(5)
to see all the things that you can specify and enable
by simply describing your package appropriately. In general, this
will lead to a more robust and consistent state.
Inspect the env to determine where to put things. For instance, if
@@ -202,10 +203,10 @@
SEE ALSO
@@ -219,5 +220,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/misc/removing-npm.html nodejs-0.11.15/deps/npm/html/doc/misc/removing-npm.html
--- nodejs-0.11.14/deps/npm/html/doc/misc/removing-npm.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/misc/removing-npm.html 2015-01-20 21:22:17.000000000 +0000
@@ -38,12 +38,12 @@
Prior to version 0.3, npm used shim files for executables and node
modules. To track those down, you can do the following:
find /usr/local/{lib/node,bin} -exec grep -l npm \{\} \; ;
-
(This is also in the README file.)
+(This is also in the README file.)
SEE ALSO
@@ -57,5 +57,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/misc/semver.html nodejs-0.11.15/deps/npm/html/doc/misc/semver.html
--- nodejs-0.11.14/deps/npm/html/doc/misc/semver.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/misc/semver.html 2015-01-20 21:22:17.000000000 +0000
@@ -125,7 +125,7 @@
A partial version range is treated as an X-Range, so the special
character is in fact optional.
-` (empty string) :=
*:=
>=0.0.0`
+""
(empty string) := *
:= >=0.0.0
1
:= 1.x.x
:= >=1.0.0 <2.0.0
1.2
:= 1.2.x
:= >=1.2.0 <1.3.0
@@ -263,5 +263,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/doc/README.html nodejs-0.11.15/deps/npm/html/doc/README.html
--- nodejs-0.11.14/deps/npm/html/doc/README.html 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/doc/README.html 2015-01-20 21:22:17.000000000 +0000
@@ -108,7 +108,7 @@
if (er) return commandFailed(er)
// command succeeded, and data might have some info
})
- npm.on("log", function (message) { .... })
+ npm.registry.log.on("log", function (message) { .... })
})
The load
function takes an object hash of the command-line configs.
The various npm.commands.<cmd>
functions take an array of
@@ -141,7 +141,7 @@
If you have a complaint about a package in the public npm registry,
and cannot resolve it with the package
owner , please email
-support@npmjs.com and explain the situation.
+support@npmjs.com and explain the situation.
Any data published to The npm Registry (including user account
information) may be removed or modified at the sole discretion of the
npm server administrators.
@@ -161,7 +161,7 @@
web:
https://github.com/npm/npm/issues
email:
-npm-@googlegroups.com
+npm-@googlegroups.com
Be sure to include all of the output from the npm command that didn't work
as expected. The npm-debug.log
file is also helpful to provide.
@@ -169,10 +169,10 @@
will no doubt tell you to put the output in a gist or email.
SEE ALSO
@@ -186,5 +186,5 @@
-
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-bin.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-bin.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-bin.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-bin.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,8 @@
+ Display npm bin folder
+SYNOPSIS
+npm.commands.bin(args, cb)
+
DESCRIPTION
+Print the folder where npm will install executables.
+This function should not be used programmatically. Instead, just refer
+to the npm.bin
property.
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-bugs.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-bugs.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-bugs.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-bugs.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,13 @@
+ Bugs for a package in a web browser maybe
+SYNOPSIS
+npm.commands.bugs(package, callback)
+
DESCRIPTION
+This command tries to guess at the likely location of a package's
+bug tracker URL, and then tries to open it using the --browser
+config param.
+Like other commands, the first parameter is an array. This command only
+uses the first element, which is expected to be a package name with an
+optional version number.
+This command will launch a browser, so this command may not be the most
+friendly for programmatic use.
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-cache.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-cache.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-cache.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-cache.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,22 @@
+ manage the npm cache programmatically
+SYNOPSIS
+npm.commands.cache([args], callback)
+
+// helpers
+npm.commands.cache.clean([args], callback)
+npm.commands.cache.add([args], callback)
+npm.commands.cache.read(name, version, forceBypass, callback)
+
DESCRIPTION
+This acts much the same ways as the npm-cache(1) command line
+functionality.
+The callback is called with the package.json data of the thing that is
+eventually added to or read from the cache.
+The top level npm.commands.cache(...)
functionality is a public
+interface, and like all commands on the npm.commands
object, it will
+match the command line behavior exactly.
+However, the cache folder structure and the cache helper functions are
+considered internal API surface, and as such, may change in future
+releases of npm, potentially without warning or significant version
+incrementation.
+Use at your own risk.
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-commands.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-commands.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-commands.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-commands.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,16 @@
+ npm commands
+SYNOPSIS
+npm.commands[<command>](args, callback)
+
DESCRIPTION
+npm comes with a full set of commands, and each of the commands takes a
+similar set of arguments.
+In general, all commands on the command object take an array of positional
+argument strings . The last argument to any function is a callback. Some
+commands are special and take other optional arguments.
+All commands have their own man page. See man npm-<command>
for command-line
+usage, or man 3 npm-<command>
for programmatic usage.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-config.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-config.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-config.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-config.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,37 @@
+ Manage the npm configuration files
+SYNOPSIS
+npm.commands.config(args, callback)
+var val = npm.config.get(key)
+npm.config.set(key, val)
+
DESCRIPTION
+This function acts much the same way as the command-line version. The first
+element in the array tells config what to do. Possible values are:
+
+set
+ Sets a config parameter. The second element in args
is interpreted as the
+ key, and the third element is interpreted as the value.
+
+get
+ Gets the value of a config parameter. The second element in args
is the
+ key to get the value of.
+
+delete
(rm
or del
)
+ Deletes a parameter from the config. The second element in args
is the
+ key to delete.
+
+list
(ls
)
+ Show all configs that aren't secret. No parameters necessary.
+
+edit
:
+ Opens the config file in the default editor. This command isn't very useful
+ programmatically, but it is made available.
+
+
+To programmatically access npm configuration settings, or set them for
+the duration of a program, use the npm.config.set
and npm.config.get
+functions instead.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-deprecate.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-deprecate.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-deprecate.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-deprecate.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,27 @@
+ Deprecate a version of a package
+SYNOPSIS
+npm.commands.deprecate(args, callback)
+
DESCRIPTION
+This command will update the npm registry entry for a package, providing
+a deprecation warning to all who attempt to install it.
+The 'args' parameter must have exactly two elements:
+
+package[@version]
+ The version
portion is optional, and may be either a range, or a
+ specific version, or a tag.
+
+message
+ The warning message that will be printed whenever a user attempts to
+ install the package.
+
+
+Note that you must be the package owner to deprecate something. See the
+owner
and adduser
help topics.
+To un-deprecate a package, specify an empty string (""
) for the message
argument.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-docs.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-docs.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-docs.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-docs.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,13 @@
+ Docs for a package in a web browser maybe
+SYNOPSIS
+npm.commands.docs(package, callback)
+
DESCRIPTION
+This command tries to guess at the likely location of a package's
+documentation URL, and then tries to open it using the --browser
+config param.
+Like other commands, the first parameter is an array. This command only
+uses the first element, which is expected to be a package name with an
+optional version number.
+This command will launch a browser, so this command may not be the most
+friendly for programmatic use.
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-edit.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-edit.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-edit.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-edit.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,16 @@
+ Edit an installed package
+SYNOPSIS
+npm.commands.edit(package, callback)
+
DESCRIPTION
+Opens the package folder in the default editor (or whatever you've
+configured as the npm editor
config -- see npm help config
.)
+After it has been edited, the package is rebuilt so as to pick up any
+changes in compiled packages.
+For instance, you can do npm install connect
to install connect
+into your package, and then npm.commands.edit(["connect"], callback)
+to make a few changes to your locally installed copy.
+The first parameter is a string array with a single element, the package
+to open. The package can optionally have a version number attached.
+Since this command opens an editor in a new process, be careful about where
+and how this is used.
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-explore.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-explore.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-explore.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-explore.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,11 @@
+ Browse an installed package
+SYNOPSIS
+npm.commands.explore(args, callback)
+
DESCRIPTION
+Spawn a subshell in the directory of the installed package specified.
+If a command is specified, then it is run in the subshell, which then
+immediately terminates.
+Note that the package is not automatically rebuilt afterwards, so be
+sure to use npm rebuild <pkg>
if you make any changes.
+The first element in the 'args' parameter must be a package name. After that is the optional command, which can be any number of strings. All of the strings will be combined into one, space-delimited command.
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-help-search.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-help-search.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-help-search.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-help-search.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,24 @@
+ Search the help pages
+SYNOPSIS
+npm.commands.helpSearch(args, [silent,] callback)
+
DESCRIPTION
+This command is rarely useful, but it exists in the rare case that it is.
+This command takes an array of search terms and returns the help pages that
+match in order of best match.
+If there is only one match, then npm displays that help section. If there
+are multiple results, the results are printed to the screen formatted and the
+array of results is returned. Each result is an object with these properties:
+
+hits:
+A map of args to number of hits on that arg. For example, {"npm": 3}
+found:
+Total number of unique args that matched.
+totalHits:
+Total number of hits.
+lines:
+An array of all matching lines (and some adjacent lines).
+file:
+Name of the file that matched
+
+The silent parameter is not necessary not used, but it may in the future.
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,89 @@
+ node package manager
+SYNOPSIS
+var npm = require("npm")
+npm.load([configObject, ]function (er, npm) {
+ // use the npm object, now that it's loaded.
+
+ npm.config.set(key, val)
+ val = npm.config.get(key)
+
+ console.log("prefix = %s", npm.prefix)
+
+ npm.commands.install(["package"], cb)
+})
+
VERSION
+2.1.6
+DESCRIPTION
+This is the API documentation for npm.
+To find documentation of the command line
+client, see npm(1)
.
+Prior to using npm's commands, npm.load()
must be called. If you provide
+configObject
as an object map of top-level configs, they override the values
+stored in the various config locations. In the npm command line client, this
+set of configs is parsed from the command line options. Additional
+configuration params are loaded from two configuration files. See
+npm-config(1)
, npm-config(7)
, and npmrc(5)
for more information.
+After that, each of the functions are accessible in the
+commands object: npm.commands.<cmd>
. See npm-index(7)
for a list of
+all possible commands.
+All commands on the command object take an array of positional argument
+strings . The last argument to any function is a callback. Some
+commands take other optional arguments.
+Configs cannot currently be set on a per function basis, as each call to
+npm.config.set will change the value for all npm commands in that process.
+To find API documentation for a specific command, run the npm apihelp
+command.
+METHODS AND PROPERTIES
+
+npm.load(configs, cb)
+ Load the configuration params, and call the cb
function once the
+ globalconfig and userconfig files have been loaded as well, or on
+ nextTick if they've already been loaded.
+
+npm.config
+ An object for accessing npm configuration parameters.
+
+npm.config.get(key)
+npm.config.set(key, val)
+npm.config.del(key)
+
+
+npm.dir
or npm.root
+ The node_modules
directory where npm will operate.
+
+npm.prefix
+ The prefix where npm is operating. (Most often the current working
+ directory.)
+
+npm.cache
+ The place where npm keeps JSON and tarballs it fetches from the
+ registry (or uploads to the registry).
+
+npm.tmp
+ npm's temporary working directory.
+
+npm.deref
+ Get the "real" name for a command that has either an alias or
+ abbreviation.
+
+
+MAGIC
+For each of the methods in the npm.commands
object, a method is added to the
+npm object, which takes a set of positional string arguments rather than an
+array and a callback.
+If the last argument is a callback, then it will use the supplied
+callback. However, if no callback is provided, then it will print out
+the error or results.
+For example, this would work in a node repl:
+> npm = require("npm")
+> npm.load() // wait a sec...
+> npm.install("dnode", "express")
+
Note that that won't work in a node program, since the install
+method will get called before the configuration load is completed.
+ABBREVS
+In order to support npm ins foo
instead of npm install foo
, the
+npm.commands
object has a set of abbreviations as well as the full
+method names. Use the npm.deref
method to find the real name.
+For example:
+var cmd = npm.deref("unp") // cmd === "unpublish"
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-init.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-init.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-init.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-init.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,19 @@
+ Interactively create a package.json file
+SYNOPSIS
+npm.commands.init(args, callback)
+
DESCRIPTION
+This will ask you a bunch of questions, and then write a package.json for you.
+It attempts to make reasonable guesses about what you want things to be set to,
+and then writes a package.json file with the options you've selected.
+If you already have a package.json file, it'll read that first, and default to
+the options in there.
+It is strictly additive, so it does not delete options from your package.json
+without a really good reason to do so.
+Since this function expects to be run on the command-line, it doesn't work very
+well as a programmatically. The best option is to roll your own, and since
+JavaScript makes it stupid simple to output formatted JSON, that is the
+preferred method. If you're sure you want to handle command-line prompting,
+then go ahead and use this programmatically.
+SEE ALSO
+package.json(5)
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-install.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-install.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-install.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-install.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,12 @@
+ install a package programmatically
+SYNOPSIS
+npm.commands.install([where,] packages, callback)
+
DESCRIPTION
+This acts much the same ways as installing on the command-line.
+The 'where' parameter is optional and only used internally, and it specifies
+where the packages should be installed to.
+The 'packages' parameter is an array of strings. Each element in the array is
+the name of a package to be installed.
+Finally, 'callback' is a function that will be called when all packages have been
+installed or when an error has been encountered.
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-link.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-link.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-link.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-link.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,22 @@
+ Symlink a package folder
+SYNOPSIS
+npm.commands.link(callback)
+npm.commands.link(packages, callback)
+
DESCRIPTION
+Package linking is a two-step process.
+Without parameters, link will create a globally-installed
+symbolic link from prefix/package-name
to the current folder.
+With a parameters, link will create a symlink from the local node_modules
+folder to the global symlink.
+When creating tarballs for npm publish
, the linked packages are
+"snapshotted" to their current state by resolving the symbolic links.
+This is
+handy for installing your own stuff, so that you can work on it and test it
+iteratively without having to continually rebuild.
+For example:
+npm.commands.link(cb) # creates global link from the cwd
+ # (say redis package)
+npm.commands.link('redis', cb) # link-install the package
+
Now, any changes to the redis package will be reflected in
+the package in the current working directory
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-load.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-load.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-load.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-load.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,17 @@
+ Load config settings
+SYNOPSIS
+npm.load(conf, cb)
+
DESCRIPTION
+npm.load() must be called before any other function call. Both parameters are
+optional, but the second is recommended.
+The first parameter is an object containing command-line config params, and the
+second parameter is a callback that will be called when npm is loaded and ready
+to serve.
+The first parameter should follow a similar structure as the package.json
+config object.
+For example, to emulate the --dev flag, pass an object that looks like this:
+{
+ "dev": true
+}
+
For a list of all the available command-line configs, see npm help config
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-ls.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-ls.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-ls.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-ls.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,43 @@
+ List installed packages
+SYNOPSIS
+npm.commands.ls(args, [silent,] callback)
+
DESCRIPTION
+This command will print to stdout all the versions of packages that are
+installed, as well as their dependencies, in a tree-structure. It will also
+return that data using the callback.
+This command does not take any arguments, but args must be defined.
+Beyond that, if any arguments are passed in, npm will politely warn that it
+does not take positional arguments, though you may set config flags
+like with any other command, such as global
to list global packages.
+It will print out extraneous, missing, and invalid packages.
+If the silent parameter is set to true, nothing will be output to the screen,
+but the data will still be returned.
+Callback is provided an error if one occurred, the full data about which
+packages are installed and which dependencies they will receive, and a
+"lite" data object which just shows which versions are installed where.
+Note that the full data object is a circular structure, so care must be
+taken if it is serialized to JSON.
+CONFIGURATION
+long
+
+Default: false
+Type: Boolean
+
+Show extended information.
+parseable
+
+Default: false
+Type: Boolean
+
+Show parseable output instead of tree view.
+global
+
+Default: false
+Type: Boolean
+
+List packages in the global install prefix instead of in the current
+project.
+Note, if parseable is set or long isn't set, then duplicates will be trimmed.
+This means that if a submodule a same dependency as a parent module, then the
+dependency will only be output once.
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-outdated.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-outdated.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-outdated.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-outdated.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,8 @@
+ Check for outdated packages
+SYNOPSIS
+npm.commands.outdated([packages,] callback)
+
DESCRIPTION
+This command will check the registry to see if the specified packages are
+currently outdated.
+If the 'packages' parameter is left out, npm will check all packages.
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-owner.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-owner.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-owner.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-owner.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,27 @@
+ Manage package owners
+SYNOPSIS
+npm.commands.owner(args, callback)
+
DESCRIPTION
+The first element of the 'args' parameter defines what to do, and the subsequent
+elements depend on the action. Possible values for the action are (order of
+parameters are given in parenthesis):
+
+ls (package):
+List all the users who have access to modify a package and push new versions.
+Handy when you need to know who to bug for help.
+add (user, package):
+Add a new user as a maintainer of a package. This user is enabled to modify
+metadata, publish new versions, and add other owners.
+rm (user, package):
+Remove a user from the package owner list. This immediately revokes their
+privileges.
+
+Note that there is only one level of access. Either you can modify a package,
+or you can't. Future versions may contain more fine-grained access levels, but
+that is not implemented at this time.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-pack.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-pack.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-pack.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-pack.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,13 @@
+ Create a tarball from a package
+SYNOPSIS
+npm.commands.pack([packages,] callback)
+
DESCRIPTION
+For anything that's installable (that is, a package folder, tarball,
+tarball url, name@tag, name@version, or name), this command will fetch
+it to the cache, and then copy the tarball to the current working
+directory as <name>-<version>.tgz
, and then write the filenames out to
+stdout.
+If the same package is specified multiple times, then the file will be
+overwritten the second time.
+If no arguments are supplied, then npm packs the current package folder.
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-prefix.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-prefix.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-prefix.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-prefix.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,9 @@
+ Display prefix
+SYNOPSIS
+npm.commands.prefix(args, callback)
+
DESCRIPTION
+Print the prefix to standard out.
+'args' is never used and callback is never called with data.
+'args' must be present or things will break.
+This function is not useful programmatically
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-prune.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-prune.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-prune.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-prune.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,10 @@
+ Remove extraneous packages
+SYNOPSIS
+npm.commands.prune([packages,] callback)
+
DESCRIPTION
+This command removes "extraneous" packages.
+The first parameter is optional, and it specifies packages to be removed.
+No packages are specified, then all packages will be checked.
+Extraneous packages are packages that are not listed on the parent
+package's dependencies list.
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-publish.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-publish.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-publish.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-publish.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,26 @@
+ Publish a package
+SYNOPSIS
+npm.commands.publish([packages,] callback)
+
DESCRIPTION
+Publishes a package to the registry so that it can be installed by name.
+Possible values in the 'packages' array are:
+
+If the package array is empty, npm will try to publish something in the
+current working directory.
+This command could fails if one of the packages specified already exists in
+the registry. Overwrites when the "force" environment variable is set.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-rebuild.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-rebuild.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-rebuild.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-rebuild.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,10 @@
+ Rebuild a package
+SYNOPSIS
+npm.commands.rebuild([packages,] callback)
+
DESCRIPTION
+This command runs the npm build
command on each of the matched packages. This is useful
+when you install a new version of node, and must recompile all your C++ addons with
+the new binary. If no 'packages' parameter is specify, every package will be rebuilt.
+CONFIGURATION
+See npm help build
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-repo.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-repo.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-repo.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-repo.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,13 @@
+ Open package repository page in the browser
+SYNOPSIS
+npm.commands.repo(package, callback)
+
DESCRIPTION
+This command tries to guess at the likely location of a package's
+repository URL, and then tries to open it using the --browser
+config param.
+Like other commands, the first parameter is an array. This command only
+uses the first element, which is expected to be a package name with an
+optional version number.
+This command will launch a browser, so this command may not be the most
+friendly for programmatic use.
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-restart.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-restart.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-restart.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-restart.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,16 @@
+ Start a package
+SYNOPSIS
+npm.commands.restart(packages, callback)
+
DESCRIPTION
+This runs a package's "restart" script, if one was provided.
+Otherwise it runs package's "stop" script, if one was provided, and then
+the "start" script.
+If no version is specified, then it restarts the "active" version.
+npm can run tests on multiple packages. Just specify multiple packages
+in the packages
parameter.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-root.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-root.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-root.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-root.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,9 @@
+ Display npm root
+SYNOPSIS
+npm.commands.root(args, callback)
+
DESCRIPTION
+Print the effective node_modules
folder to standard out.
+'args' is never used and callback is never called with data.
+'args' must be present or things will break.
+This function is not useful programmatically.
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-run-script.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-run-script.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-run-script.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-run-script.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,21 @@
+ Run arbitrary package scripts
+SYNOPSIS
+npm.commands.run-script(args, callback)
+
DESCRIPTION
+This runs an arbitrary command from a package's "scripts" object.
+It is used by the test, start, restart, and stop commands, but can be
+called directly, as well.
+The 'args' parameter is an array of strings. Behavior depends on the number
+of elements. If there is only one element, npm assumes that the element
+represents a command to be run on the local repository. If there is more than
+one element, then the first is assumed to be the package and the second is
+assumed to be the command to run. All other elements are ignored.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-search.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-search.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-search.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-search.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,33 @@
+ Search for packages
+SYNOPSIS
+npm.commands.search(searchTerms, [silent,] [staleness,] callback)
+
DESCRIPTION
+Search the registry for packages matching the search terms. The available parameters are:
+
+searchTerms:
+Array of search terms. These terms are case-insensitive.
+silent:
+If true, npm will not log anything to the console.
+staleness:
+This is the threshold for stale packages. "Fresh" packages are not refreshed
+from the registry. This value is measured in seconds.
+callback:
+Returns an object where each key is the name of a package, and the value
+is information about that package along with a 'words' property, which is
+a space-delimited string of all of the interesting words in that package.
+The only properties included are those that are searched, which generally include:
+
+name
+description
+maintainers
+url
+keywords
+
+
+
+A search on the registry excludes any result that does not match all of the
+search terms. It also removes any items from the results that contain an
+excluded term (the "searchexclude" config). The search is case insensitive
+and doesn't try to read your mind (it doesn't do any verb tense matching or the
+like).
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-shrinkwrap.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-shrinkwrap.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-shrinkwrap.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-shrinkwrap.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,13 @@
+ programmatically generate package shrinkwrap file
+SYNOPSIS
+npm.commands.shrinkwrap(args, [silent,] callback)
+
DESCRIPTION
+This acts much the same ways as shrinkwrapping on the command-line.
+This command does not take any arguments, but 'args' must be defined.
+Beyond that, if any arguments are passed in, npm will politely warn that it
+does not take positional arguments.
+If the 'silent' parameter is set to true, nothing will be output to the screen,
+but the shrinkwrap file will still be written.
+Finally, 'callback' is a function that will be called when the shrinkwrap has
+been saved.
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-start.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-start.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-start.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-start.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,8 @@
+ Start a package
+SYNOPSIS
+npm.commands.start(packages, callback)
+
DESCRIPTION
+This runs a package's "start" script, if one was provided.
+npm can run tests on multiple packages. Just specify multiple packages
+in the packages
parameter.
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-stop.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-stop.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-stop.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-stop.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,8 @@
+ Stop a package
+SYNOPSIS
+npm.commands.stop(packages, callback)
+
DESCRIPTION
+This runs a package's "stop" script, if one was provided.
+npm can run stop on multiple packages. Just specify multiple packages
+in the packages
parameter.
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-submodule.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-submodule.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-submodule.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-submodule.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,22 @@
+ Add a package as a git submodule
+SYNOPSIS
+npm.commands.submodule(packages, callback)
+
DESCRIPTION
+For each package specified, npm will check if it has a git repository url
+in its package.json description then add it as a git submodule at
+node_modules/<pkg name>
.
+This is a convenience only. From then on, it's up to you to manage
+updates by using the appropriate git commands. npm will stubbornly
+refuse to update, modify, or remove anything with a .git
subfolder
+in it.
+This command also does not install missing dependencies, if the package
+does not include them in its git repository. If npm ls
reports that
+things are missing, you can either install, link, or submodule them yourself,
+or you can do npm explore <pkgname> -- npm install
to install the
+dependencies into the submodule folder.
+SEE ALSO
+
+npm help json
+git help submodule
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-tag.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-tag.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-tag.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-tag.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,16 @@
+ Tag a published version
+SYNOPSIS
+npm.commands.tag(package@version, tag, callback)
+
DESCRIPTION
+Tags the specified version of the package with the specified tag, or the
+--tag
config if not specified.
+The 'package@version' is an array of strings, but only the first two elements are
+currently used.
+The first element must be in the form package@version, where package
+is the package name and version is the version number (much like installing a
+specific version).
+The second element is the name of the tag to tag this version with. If this
+parameter is missing or falsey (empty), the default froom the config will be
+used. For more information about how to set this config, check
+man 3 npm-config
for programmatic usage or man npm-config
for cli usage.
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-test.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-test.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-test.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-test.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,10 @@
+ Test a package
+SYNOPSIS
+ npm.commands.test(packages, callback)
+
DESCRIPTION
+This runs a package's "test" script, if one was provided.
+To run tests as a condition of installation, set the npat
config to
+true.
+npm can run tests on multiple packages. Just specify multiple packages
+in the packages
parameter.
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-uninstall.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-uninstall.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-uninstall.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-uninstall.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,10 @@
+ uninstall a package programmatically
+SYNOPSIS
+npm.commands.uninstall(packages, callback)
+
DESCRIPTION
+This acts much the same ways as uninstalling on the command-line.
+The 'packages' parameter is an array of strings. Each element in the array is
+the name of a package to be uninstalled.
+Finally, 'callback' is a function that will be called when all packages have been
+uninstalled or when an error has been encountered.
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-unpublish.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-unpublish.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-unpublish.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-unpublish.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,13 @@
+ Remove a package from the registry
+SYNOPSIS
+npm.commands.unpublish(package, callback)
+
DESCRIPTION
+This removes a package version from the registry, deleting its
+entry and removing the tarball.
+The package parameter must be defined.
+Only the first element in the package parameter is used. If there is no first
+element, then npm assumes that the package at the current working directory
+is what is meant.
+If no version is specified, or if all versions are removed then
+the root package entry is removed from the registry entirely.
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-update.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-update.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-update.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-update.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,7 @@
+ Update a package
+SYNOPSIS
+npm.commands.update(packages, callback)
+
DESCRIPTION
+Updates a package, upgrading it to the latest version. It also installs any missing packages.
+The 'packages' argument is an array of packages to update. The 'callback' parameter will be called when done or when an error occurs.
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-version.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-version.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-version.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-version.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,12 @@
+ Bump a package version
+SYNOPSIS
+npm.commands.version(newversion, callback)
+
DESCRIPTION
+Run this in a package directory to bump the version and write the new
+data back to the package.json file.
+If run in a git repo, it will also create a version commit and tag, and
+fail if the repo is not clean.
+Like all other commands, this function takes a string array as its first
+parameter. The difference, however, is this function will fail if it does
+not have exactly one element. The only element should be a version number.
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-view.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-view.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-view.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-view.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,61 @@
+ View registry info
+SYNOPSIS
+npm.commands.view(args, [silent,] callback)
+
DESCRIPTION
+This command shows data about a package and prints it to the stream
+referenced by the outfd
config, which defaults to stdout.
+The "args" parameter is an ordered list that closely resembles the command-line
+usage. The elements should be ordered such that the first element is
+the package and version (package@version). The version is optional. After that,
+the rest of the parameters are fields with optional subfields ("field.subfield")
+which can be used to get only the information desired from the registry.
+The callback will be passed all of the data returned by the query.
+For example, to get the package registry entry for the connect
package,
+you can do this:
+npm.commands.view(["connect"], callback)
+
If no version is specified, "latest" is assumed.
+Field names can be specified after the package descriptor.
+For example, to show the dependencies of the ronn
package at version
+0.3.5, you could do the following:
+npm.commands.view(["ronn@0.3.5", "dependencies"], callback)
+
You can view child field by separating them with a period.
+To view the git repository URL for the latest version of npm, you could
+do this:
+npm.commands.view(["npm", "repository.url"], callback)
+
For fields that are arrays, requesting a non-numeric field will return
+all of the values from the objects in the list. For example, to get all
+the contributor names for the "express" project, you can do this:
+npm.commands.view(["express", "contributors.email"], callback)
+
You may also use numeric indices in square braces to specifically select
+an item in an array field. To just get the email address of the first
+contributor in the list, you can do this:
+npm.commands.view(["express", "contributors[0].email"], callback)
+
Multiple fields may be specified, and will be printed one after another.
+For exampls, to get all the contributor names and email addresses, you
+can do this:
+npm.commands.view(["express", "contributors.name", "contributors.email"], callback)
+
"Person" fields are shown as a string if they would be shown as an
+object. So, for example, this will show the list of npm contributors in
+the shortened string format. (See npm help json
for more on this.)
+npm.commands.view(["npm", "contributors"], callback)
+
If a version range is provided, then data will be printed for every
+matching version of the package. This will show which version of jsdom
+was required by each matching version of yui3:
+npm.commands.view(["yui3@'>0.5.4'", "dependencies.jsdom"], callback)
+
OUTPUT
+If only a single string field for a single version is output, then it
+will not be colorized or quoted, so as to enable piping the output to
+another command.
+If the version range matches multiple versions, than each printed value
+will be prefixed with the version it applies to.
+If multiple fields are requested, than each of them are prefixed with
+the field name.
+Console output can be disabled by setting the 'silent' parameter to true.
+RETURN VALUE
+The data returned will be an object in this formation:
+{ <version>:
+ { <field>: <value>
+ , ... }
+, ... }
+
corresponding to the list of fields selected.
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-whoami.html nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-whoami.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/api/npm-whoami.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/api/npm-whoami.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,9 @@
+ Display npm username
+SYNOPSIS
+npm.commands.whoami(args, callback)
+
DESCRIPTION
+Print the username
config to standard output.
+'args' is never used and callback is never called with data.
+'args' must be present or things will break.
+This function is not useful programmatically
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-adduser.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-adduser.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-adduser.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-adduser.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,47 @@
+ Add a registry user account
+SYNOPSIS
+npm adduser [--registry=url] [--scope=@orgname] [--always-auth]
+
DESCRIPTION
+Create or verify a user named <username>
in the specified registry, and
+save the credentials to the .npmrc
file. If no registry is specified,
+the default registry will be used (see npm-config(7)
).
+The username, password, and email are read in from prompts.
+You may use this command to change your email address, but not username
+or password.
+To reset your password, go to https://www.npmjs.org/forgot
+You may use this command multiple times with the same user account to
+authorize on a new machine.
+npm login
is an alias to adduser
and behaves exactly the same way.
+CONFIGURATION
+registry
+Default: http://registry.npmjs.org/
+The base URL of the npm package registry. If scope
is also specified,
+this registry will only be used for packages with that scope. See npm-scope(7)
.
+scope
+Default: none
+If specified, the user and login credentials given will be associated
+with the specified scope. See npm-scope(7)
. You can use both at the same time,
+e.g.
+npm adduser --registry=http://myregistry.example.com --scope=@myco
+
This will set a registry for the given scope and login or create a user for
+that registry at the same time.
+always-auth
+Default: false
+If specified, save configuration indicating that all requests to the given
+registry should include authorization information. Useful for private
+registries. Can be used with --registry
and / or --scope
, e.g.
+npm adduser --registry=http://private-registry.example.com --always-auth
+
This will ensure that all requests to that registry (including for tarballs)
+include an authorization header. See always-auth
in npm-config(7)
for more
+details on always-auth. Registry-specific configuaration of always-auth
takes
+precedence over any global configuration.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-bin.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-bin.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-bin.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-bin.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,15 @@
+ Display npm bin folder
+SYNOPSIS
+npm bin
+
DESCRIPTION
+Print the folder where npm will install executables.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-bugs.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-bugs.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-bugs.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-bugs.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,34 @@
+ Bugs for a package in a web browser maybe
+SYNOPSIS
+npm bugs <pkgname>
+npm bugs (with no args in a package dir)
+
DESCRIPTION
+This command tries to guess at the likely location of a package's
+bug tracker URL, and then tries to open it using the --browser
+config param. If no package name is provided, it will search for
+a package.json
in the current folder and use the name
property.
+CONFIGURATION
+browser
+
+Default: OS X: "open"
, Windows: "start"
, Others: "xdg-open"
+Type: String
+
+The browser that is called by the npm bugs
command to open websites.
+registry
+
+The base URL of the npm package registry.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-build.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-build.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-build.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-build.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,18 @@
+ Build a package
+SYNOPSIS
+npm build <package-folder>
+
+<package-folder>
:
+A folder containing a package.json
file in its root.
+
+DESCRIPTION
+This is the plumbing command called by npm link
and npm install
.
+It should generally not be called directly.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-bundle.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-bundle.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-bundle.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-bundle.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,11 @@
+ REMOVED
+DESCRIPTION
+The npm bundle
command has been removed in 1.0, for the simple reason
+that it is no longer necessary, as the default behavior is now to
+install packages into the local space.
+Just use npm install
now to do what npm bundle
used to do.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-cache.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-cache.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-cache.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-cache.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,61 @@
+ Manipulates packages cache
+SYNOPSIS
+npm cache add <tarball file>
+npm cache add <folder>
+npm cache add <tarball url>
+npm cache add <name>@<version>
+
+npm cache ls [<path>]
+
+npm cache clean [<path>]
+
DESCRIPTION
+Used to add, list, or clear the npm cache folder.
+
+add:
+Add the specified package to the local cache. This command is primarily
+intended to be used internally by npm, but it can provide a way to
+add data to the local installation cache explicitly.
+
+ls:
+Show the data in the cache. Argument is a path to show in the cache
+folder. Works a bit like the find
program, but limited by the
+depth
config.
+
+clean:
+Delete data out of the cache folder. If an argument is provided, then
+it specifies a subpath to delete. If no argument is provided, then
+the entire cache is cleared.
+
+
+DETAILS
+npm stores cache data in the directory specified in npm config get cache
.
+For each package that is added to the cache, three pieces of information are
+stored in {cache}/{name}/{version}
:
+
+.../package/package.json:
+The package.json file, as npm sees it.
+.../package.tgz:
+The tarball for that version.
+
+Additionally, whenever a registry request is made, a .cache.json
file
+is placed at the corresponding URI, to store the ETag and the requested
+data. This is stored in {cache}/{hostname}/{path}/.cache.json
.
+Commands that make non-essential registry requests (such as search
and
+view
, or the completion scripts) generally specify a minimum timeout.
+If the .cache.json
file is younger than the specified timeout, then
+they do not make an HTTP request to the registry.
+CONFIGURATION
+cache
+Default: ~/.npm
on Posix, or %AppData%/npm-cache
on Windows.
+The root cache folder.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-completion.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-completion.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-completion.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-completion.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,22 @@
+ Tab Completion for npm
+SYNOPSIS
+. <(npm completion)
+
DESCRIPTION
+Enables tab-completion in all npm commands.
+The synopsis above
+loads the completions into your current shell. Adding it to
+your ~/.bashrc or ~/.zshrc will make the completions available
+everywhere.
+You may of course also pipe the output of npm completion to a file
+such as /usr/local/etc/bash_completion.d/npm
if you have a system
+that will read that file for you.
+When COMP_CWORD
, COMP_LINE
, and COMP_POINT
are defined in the
+environment, npm completion
acts in "plumbing mode", and outputs
+completions based on the arguments.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-config.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-config.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-config.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-config.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,46 @@
+ Manage the npm configuration files
+SYNOPSIS
+npm config set <key> <value> [--global]
+npm config get <key>
+npm config delete <key>
+npm config list
+npm config edit
+npm c [set|get|delete|list]
+npm get <key>
+npm set <key> <value> [--global]
+
DESCRIPTION
+npm gets its config settings from the command line, environment
+variables, npmrc
files, and in some cases, the package.json
file.
+See npmrc(5) for more information about the npmrc files.
+See npm-config(7)
for a more thorough discussion of the mechanisms
+involved.
+The npm config
command can be used to update and edit the contents
+of the user and global npmrc files.
+Sub-commands
+Config supports the following sub-commands:
+set
+npm config set key value
+
Sets the config key to the value.
+If value is omitted, then it sets it to "true".
+get
+npm config get key
+
Echo the config value to stdout.
+list
+npm config list
+
Show all the config settings.
+delete
+npm config delete key
+
Deletes the key from all configuration files.
+edit
+npm config edit
+
Opens the config file in an editor. Use the --global
flag to edit the
+global config.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-dedupe.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-dedupe.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-dedupe.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-dedupe.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,43 @@
+ Reduce duplication
+SYNOPSIS
+npm dedupe [package names...]
+npm ddp [package names...]
+
DESCRIPTION
+Searches the local package tree and attempts to simplify the overall
+structure by moving dependencies further up the tree, where they can
+be more effectively shared by multiple dependent packages.
+For example, consider this dependency graph:
+a
++-- b <-- depends on c@1.0.x
+| `-- c@1.0.3
+`-- d <-- depends on c@~1.0.9
+ `-- c@1.0.10
+
In this case, npm-dedupe(1)
will transform the tree to:
+a
++-- b
++-- d
+`-- c@1.0.10
+
Because of the hierarchical nature of node's module lookup, b and d
+will both get their dependency met by the single c package at the root
+level of the tree.
+If a suitable version exists at the target location in the tree
+already, then it will be left untouched, but the other duplicates will
+be deleted.
+If no suitable version can be found, then a warning is printed, and
+nothing is done.
+If any arguments are supplied, then they are filters, and only the
+named packages will be touched.
+Note that this operation transforms the dependency tree, and may
+result in packages getting updated versions, perhaps from the npm
+registry.
+This feature is experimental, and may change in future versions.
+The --tag
argument will apply to all of the affected dependencies. If a
+tag with the given name exists, the tagged version is preferred over newer
+versions.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-deprecate.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-deprecate.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-deprecate.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-deprecate.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,18 @@
+ Deprecate a version of a package
+SYNOPSIS
+npm deprecate <name>[@<version>] <message>
+
DESCRIPTION
+This command will update the npm registry entry for a package, providing
+a deprecation warning to all who attempt to install it.
+It works on version ranges as well as specific versions, so you can do
+something like this:
+npm deprecate my-thing@"< 0.2.3" "critical bug fixed in v0.2.3"
+
Note that you must be the package owner to deprecate something. See the
+owner
and adduser
help topics.
+To un-deprecate a package, specify an empty string (""
) for the message
argument.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-docs.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-docs.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-docs.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-docs.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,36 @@
+ Docs for a package in a web browser maybe
+SYNOPSIS
+npm docs [<pkgname> [<pkgname> ...]]
+npm docs (with no args in a package dir)
+npm home [<pkgname> [<pkgname> ...]]
+npm home (with no args in a package dir)
+
DESCRIPTION
+This command tries to guess at the likely location of a package's
+documentation URL, and then tries to open it using the --browser
+config param. You can pass multiple package names at once. If no
+package name is provided, it will search for a package.json
in
+the current folder and use the name
property.
+CONFIGURATION
+browser
+
+Default: OS X: "open"
, Windows: "start"
, Others: "xdg-open"
+Type: String
+
+The browser that is called by the npm docs
command to open websites.
+registry
+
+The base URL of the npm package registry.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-edit.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-edit.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-edit.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-edit.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,29 @@
+ Edit an installed package
+SYNOPSIS
+npm edit <name>[@<version>]
+
DESCRIPTION
+Opens the package folder in the default editor (or whatever you've
+configured as the npm editor
config -- see npm-config(7)
.)
+After it has been edited, the package is rebuilt so as to pick up any
+changes in compiled packages.
+For instance, you can do npm install connect
to install connect
+into your package, and then npm edit connect
to make a few
+changes to your locally installed copy.
+CONFIGURATION
+editor
+
+Default: EDITOR
environment variable if set, or "vi"
on Posix,
+or "notepad"
on Windows.
+Type: path
+
+The command to run for npm edit
or npm config edit
.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-explore.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-explore.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-explore.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-explore.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,29 @@
+ Browse an installed package
+SYNOPSIS
+npm explore <name> [ -- <cmd>]
+
DESCRIPTION
+Spawn a subshell in the directory of the installed package specified.
+If a command is specified, then it is run in the subshell, which then
+immediately terminates.
+This is particularly handy in the case of git submodules in the
+node_modules
folder:
+npm explore some-dependency -- git pull origin master
+
Note that the package is not automatically rebuilt afterwards, so be
+sure to use npm rebuild <pkg>
if you make any changes.
+CONFIGURATION
+shell
+
+Default: SHELL environment variable, or "bash" on Posix, or "cmd" on
+Windows
+Type: path
+
+The shell to run for the npm explore
command.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-help.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-help.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-help.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-help.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,32 @@
+ Get help on npm
+SYNOPSIS
+npm help <topic>
+npm help some search terms
+
DESCRIPTION
+If supplied a topic, then show the appropriate documentation page.
+If the topic does not exist, or if multiple terms are provided, then run
+the help-search
command to find a match. Note that, if help-search
+finds a single subject, then it will run help
on that topic, so unique
+matches are equivalent to specifying a topic name.
+CONFIGURATION
+viewer
+
+Default: "man" on Posix, "browser" on Windows
+Type: path
+
+The program to use to view help content.
+Set to "browser"
to view html help content in the default web browser.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-help-search.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-help-search.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-help-search.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-help-search.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,26 @@
+ Search npm help documentation
+SYNOPSIS
+npm help-search some search terms
+
DESCRIPTION
+This command will search the npm markdown documentation files for the
+terms provided, and then list the results, sorted by relevance.
+If only one result is found, then it will show that help topic.
+If the argument to npm help
is not a known help topic, then it will
+call help-search
. It is rarely if ever necessary to call this
+command directly.
+CONFIGURATION
+long
+
+Type: Boolean
+Default false
+
+If true, the "long" flag will cause help-search to output context around
+where the terms were found in the documentation.
+If false, then help-search will just list out the help topics found.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,134 @@
+ node package manager
+SYNOPSIS
+npm <command> [args]
+
VERSION
+2.1.6
+DESCRIPTION
+npm is the package manager for the Node JavaScript platform. It puts
+modules in place so that node can find them, and manages dependency
+conflicts intelligently.
+It is extremely configurable to support a wide variety of use cases.
+Most commonly, it is used to publish, discover, install, and develop node
+programs.
+Run npm help
to get a list of available commands.
+INTRODUCTION
+You probably got npm because you want to install stuff.
+Use npm install blerg
to install the latest version of "blerg". Check out
+npm-install(1)
for more info. It can do a lot of stuff.
+Use the npm search
command to show everything that's available.
+Use npm ls
to show everything you've installed.
+DEPENDENCIES
+If a package references to another package with a git URL, npm depends
+on a preinstalled git.
+If one of the packages npm tries to install is a native node module and
+requires compiling of C++ Code, npm will use
+node-gyp for that task.
+For a Unix system, node-gyp
+needs Python, make and a buildchain like GCC. On Windows,
+Python and Microsoft Visual Studio C++ is needed. Python 3 is
+not supported by node-gyp .
+For more information visit
+the node-gyp repository and
+the node-gyp Wiki .
+DIRECTORIES
+See npm-folders(5)
to learn about where npm puts stuff.
+In particular, npm has two modes of operation:
+
+global mode: npm installs packages into the install prefix at
+prefix/lib/node_modules
and bins are installed in prefix/bin
.
+local mode: npm installs packages into the current project directory, which
+defaults to the current working directory. Packages are installed to
+./node_modules
, and bins are installed to ./node_modules/.bin
.
+
+Local mode is the default. Use --global
or -g
on any command to
+operate in global mode instead.
+DEVELOPER USAGE
+If you're using npm to develop and publish your code, check out the
+following help topics:
+
+json:
+Make a package.json file. See package.json(5)
.
+link:
+For linking your current working code into Node's path, so that you
+don't have to reinstall every time you make a change. Use
+npm link
to do this.
+install:
+It's a good idea to install things if you don't need the symbolic link.
+Especially, installing other peoples code from the registry is done via
+npm install
+adduser:
+Create an account or log in. Credentials are stored in the
+user config file.
+publish:
+Use the npm publish
command to upload your code to the registry.
+
+CONFIGURATION
+npm is extremely configurable. It reads its configuration options from
+5 places.
+
+Command line switches: Set a config with --key val
. All keys take a value, even if they
+are booleans (the config parser doesn't know what the options are at
+the time of parsing.) If no value is provided, then the option is set
+to boolean true
.
+Environment Variables: Set any config by prefixing the name in an environment variable with
+npm_config_
. For example, export npm_config_key=val
.
+User Configs: The file at $HOME/.npmrc is an ini-formatted list of configs. If
+present, it is parsed. If the userconfig
option is set in the cli
+or env, then that will be used instead.
+Global Configs: The file found at ../etc/npmrc (from the node executable, by default
+this resolves to /usr/local/etc/npmrc) will be parsed if it is found.
+If the globalconfig
option is set in the cli, env, or user config,
+then that file is parsed instead.
+Defaults: npm's default configuration options are defined in
+lib/utils/config-defs.js. These must not be changed.
+
+See npm-config(7)
for much much more information.
+CONTRIBUTIONS
+Patches welcome!
+
+code:
+Read through npm-coding-style(7)
if you plan to submit code.
+You don't have to agree with it, but you do have to follow it.
+docs:
+If you find an error in the documentation, edit the appropriate markdown
+file in the "doc" folder. (Don't worry about generating the man page.)
+
+Contributors are listed in npm's package.json
file. You can view them
+easily by doing npm view npm contributors
.
+If you would like to contribute, but don't know what to work on, check
+the issues list or ask on the mailing list.
+
+BUGS
+When you find issues, please report them:
+
+Be sure to include all of the output from the npm command that didn't work
+as expected. The npm-debug.log
file is also helpful to provide.
+You can also look for isaacs in #node.js on irc://irc.freenode.net. He
+will no doubt tell you to put the output in a gist or email.
+AUTHOR
+Isaac Z. Schlueter ::
+isaacs ::
+@izs ::
+i@izs.me
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-init.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-init.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-init.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-init.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,20 @@
+ Interactively create a package.json file
+SYNOPSIS
+npm init [-f|--force|-y|--yes]
+
DESCRIPTION
+This will ask you a bunch of questions, and then write a package.json for you.
+It attempts to make reasonable guesses about what you want things to be set to,
+and then writes a package.json file with the options you've selected.
+If you already have a package.json file, it'll read that first, and default to
+the options in there.
+It is strictly additive, so it does not delete options from your package.json
+without a really good reason to do so.
+If you invoke it with -f
, --force
, -y
, or --yes
, it will use only
+defaults and not prompt you for any options.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-install.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-install.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-install.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-install.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,219 @@
+ Install a package
+SYNOPSIS
+npm install (with no args in a package dir)
+npm install <tarball file>
+npm install <tarball url>
+npm install <folder>
+npm install [@<scope>/]<name> [--save|--save-dev|--save-optional] [--save-exact]
+npm install [@<scope>/]<name>@<tag>
+npm install [@<scope>/]<name>@<version>
+npm install [@<scope>/]<name>@<version range>
+npm i (with any of the previous argument usage)
+
DESCRIPTION
+This command installs a package, and any packages that it depends on. If the
+package has a shrinkwrap file, the installation of dependencies will be driven
+by that. See npm-shrinkwrap(1) .
+A package
is:
+
+a) a folder containing a program described by a package.json file
+b) a gzipped tarball containing (a)
+c) a url that resolves to (b)
+d) a <name>@<version>
that is published on the registry (see npm-registry(7)
) with (c)
+e) a <name>@<tag>
that points to (d)
+f) a <name>
that has a "latest" tag satisfying (e)
+g) a <git remote url>
that resolves to (b)
+
+Even if you never publish your package, you can still get a lot of
+benefits of using npm if you just want to write a node program (a), and
+perhaps if you also want to be able to easily install it elsewhere
+after packing it up into a tarball (b).
+
+npm install
(in package directory, no arguments):
+ Install the dependencies in the local node_modules folder.
+ In global mode (ie, with -g
or --global
appended to the command),
+ it installs the current package context (ie, the current working
+ directory) as a global package.
+ By default, npm install
will install all modules listed as
+ dependencies. With the --production
flag,
+ npm will not install modules listed in devDependencies
.
+
+npm install <folder>
:
+ Install a package that is sitting in a folder on the filesystem.
+
+npm install <tarball file>
:
+ Install a package that is sitting on the filesystem. Note: if you just want
+ to link a dev directory into your npm root, you can do this more easily by
+ using npm link
.
+ Example:
+ npm install ./package.tgz
+
+npm install <tarball url>
:
+ Fetch the tarball url, and then install it. In order to distinguish between
+ this and other options, the argument must start with "http://" or "https://"
+ Example:
+ npm install https://github.com/indexzero/forever/tarball/v0.5.6
+
+npm install [@<scope>/]<name> [--save|--save-dev|--save-optional]
:
+ Do a <name>@<tag>
install, where <tag>
is the "tag" config. (See
+ npm-config(7)
.)
+ In most cases, this will install the latest version
+ of the module published on npm.
+ Example:
+ npm install sax
+
npm install
takes 3 exclusive, optional flags which save or update
+ the package version in your main package.json:
+
+--save
: Package will appear in your dependencies
.
+
+--save-dev
: Package will appear in your devDependencies
.
+
+--save-optional
: Package will appear in your optionalDependencies
.
+When using any of the above options to save dependencies to your
+package.json, there is an additional, optional flag:
+
+--save-exact
: Saved dependencies will be configured with an
+exact version rather than using npm's default semver range
+operator.
+<scope>
is optional. The package will be downloaded from the registry
+associated with the specified scope. If no registry is associated with
+the given scope the default registry is assumed. See npm-scope(7)
.
+Note: if you do not include the @-symbol on your scope name, npm will
+interpret this as a GitHub repository instead, see below. Scopes names
+must also be followed by a slash.
+Examples:
+npm install sax --save
+npm install githubname/reponame
+npm install @myorg/privatepackage
+npm install node-tap --save-dev
+npm install dtrace-provider --save-optional
+npm install readable-stream --save --save-exact
+
+
+
+
+**Note**: If there is a file or folder named `<name>` in the current
+working directory, then it will try to install that, and only try to
+fetch the package by name if it is not valid.
+
+npm install [@<scope>/]<name>@<tag>
:
+ Install the version of the package that is referenced by the specified tag.
+ If the tag does not exist in the registry data for that package, then this
+ will fail.
+ Example:
+ npm install sax@latest
+ npm install @myorg/mypackage@latest
+
+npm install [@<scope>/]<name>@<version>
:
+ Install the specified version of the package. This will fail if the
+ version has not been published to the registry.
+ Example:
+ npm install sax@0.1.1
+ npm install @myorg/privatepackage@1.5.0
+
+npm install [@<scope>/]<name>@<version range>
:
+ Install a version of the package matching the specified version range. This
+ will follow the same rules for resolving dependencies described in package.json(5)
.
+ Note that most version ranges must be put in quotes so that your shell will
+ treat it as a single argument.
+ Example:
+ npm install sax@">=0.1.0 <0.2.0"
+ npm install @myorg/privatepackage@">=0.1.0 <0.2.0"
+
+npm install <githubname>/<githubrepo>
:
+ Install the package at https://github.com/githubname/githubrepo" by
+ attempting to clone it using
git`.
+ Example:
+ npm install mygithubuser/myproject
+
To reference a package in a git repo that is not on GitHub, see git
+ remote urls below.
+
+npm install <git remote url>
:
+ Install a package by cloning a git remote url. The format of the git
+ url is:
+ <protocol>://[<user>@]<hostname><separator><path>[#<commit-ish>]
+
<protocol>
is one of git
, git+ssh
, git+http
, or
+ git+https
. If no <commit-ish>
is specified, then master
is
+ used.
+ Examples:
+ git+ssh://git@github.com:npm/npm.git#v1.0.27
+ git+https://isaacs@github.com/npm/npm.git
+ git://github.com/npm/npm.git#v1.0.27
+
+
+You may combine multiple arguments, and even multiple types of arguments.
+For example:
+npm install sax@">=0.1.0 <0.2.0" bench supervisor
+
The --tag
argument will apply to all of the specified install targets. If a
+tag with the given name exists, the tagged version is preferred over newer
+versions.
+The --force
argument will force npm to fetch remote resources even if a
+local copy exists on disk.
+npm install sax --force
+
The --global
argument will cause npm to install the package globally
+rather than locally. See npm-folders(5)
.
+The --link
argument will cause npm to link global installs into the
+local space in some cases.
+The --no-bin-links
argument will prevent npm from creating symlinks for
+any binaries the package might contain.
+The --no-optional
argument will prevent optional dependencies from
+being installed.
+The --no-shrinkwrap
argument, which will ignore an available
+shrinkwrap file and use the package.json instead.
+The --nodedir=/path/to/node/source
argument will allow npm to find the
+node source code so that npm can compile native modules.
+See npm-config(7)
. Many of the configuration params have some
+effect on installation, since that's most of what npm does.
+ALGORITHM
+To install a package, npm uses the following algorithm:
+install(where, what, family, ancestors)
+fetch what, unpack to <where>/node_modules/<what>
+for each dep in what.dependencies
+ resolve dep to precise version
+for each dep@version in what.dependencies
+ not in <where>/node_modules/<what>/node_modules/*
+ and not in <family>
+ add precise version deps to <family>
+ install(<where>/node_modules/<what>, dep, family)
+
For this package{dep}
structure: A{B,C}, B{C}, C{D}
,
+this algorithm produces:
+A
++-- B
+`-- C
+ `-- D
+
That is, the dependency from B to C is satisfied by the fact that A
+already caused C to be installed at a higher level.
+See npm-folders(5) for a more detailed description of the specific
+folder structures that npm creates.
+Limitations of npm's Install Algorithm
+There are some very rare and pathological edge-cases where a cycle can
+cause npm to try to install a never-ending tree of packages. Here is
+the simplest case:
+A -> B -> A' -> B' -> A -> B -> A' -> B' -> A -> ...
+
where A
is some version of a package, and A'
is a different version
+of the same package. Because B
depends on a different version of A
+than the one that is already in the tree, it must install a separate
+copy. The same is true of A'
, which must install B'
. Because B'
+depends on the original version of A
, which has been overridden, the
+cycle falls into infinite regress.
+To avoid this situation, npm flat-out refuses to install any
+name@version
that is already present anywhere in the tree of package
+folder ancestors. A more correct, but more complex, solution would be
+to symlink the existing version into the new location. If this ever
+affects a real use-case, it will be investigated.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-link.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-link.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-link.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-link.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,51 @@
+ Symlink a package folder
+SYNOPSIS
+npm link (in package folder)
+npm link [@<scope>/]<pkgname>
+npm ln (with any of the previous argument usage)
+
DESCRIPTION
+Package linking is a two-step process.
+First, npm link
in a package folder will create a globally-installed
+symbolic link from prefix/package-name
to the current folder (see
+npm-config(7)
for the value of prefix
).
+Next, in some other location, npm link package-name
will create a
+symlink from the local node_modules
folder to the global symlink.
+Note that package-name
is taken from package.json
,
+not from directory name.
+The package name can be optionally prefixed with a scope. See npm-scope(7)
.
+The scope must by preceded by an @-symbol and followed by a slash.
+When creating tarballs for npm publish
, the linked packages are
+"snapshotted" to their current state by resolving the symbolic links.
+This is handy for installing your own stuff, so that you can work on it and
+test it iteratively without having to continually rebuild.
+For example:
+cd ~/projects/node-redis # go into the package directory
+npm link # creates global link
+cd ~/projects/node-bloggy # go into some other package directory.
+npm link redis # link-install the package
+
Now, any changes to ~/projects/node-redis will be reflected in
+~/projects/node-bloggy/node_modules/redis/
+You may also shortcut the two steps in one. For example, to do the
+above use-case in a shorter way:
+cd ~/projects/node-bloggy # go into the dir of your main project
+npm link ../node-redis # link the dir of your dependency
+
The second line is the equivalent of doing:
+(cd ../node-redis; npm link)
+npm link redis
+
That is, it first creates a global link, and then links the global
+installation target into your project's node_modules
folder.
+If your linked package is scoped (see npm-scope(7)
) your link command must
+include that scope, e.g.
+npm link @myorg/privatepackage
+
SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-ls.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-ls.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-ls.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-ls.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,65 @@
+ List installed packages
+SYNOPSIS
+npm list [[@<scope>/]<pkg> ...]
+npm ls [[@<scope>/]<pkg> ...]
+npm la [[@<scope>/]<pkg> ...]
+npm ll [[@<scope>/]<pkg> ...]
+
DESCRIPTION
+This command will print to stdout all the versions of packages that are
+installed, as well as their dependencies, in a tree-structure.
+Positional arguments are name@version-range
identifiers, which will
+limit the results to only the paths to the packages named. Note that
+nested packages will also show the paths to the specified packages.
+For example, running npm ls promzard
in npm's source tree will show:
+npm@2.1.6 /path/to/npm
+└─┬ init-package-json@0.0.4
+ └── promzard@0.1.5
+
It will print out extraneous, missing, and invalid packages.
+If a project specifies git urls for dependencies these are shown
+in parentheses after the name@version to make it easier for users to
+recognize potential forks of a project.
+When run as ll
or la
, it shows extended information by default.
+CONFIGURATION
+json
+
+Default: false
+Type: Boolean
+
+Show information in JSON format.
+long
+
+Default: false
+Type: Boolean
+
+Show extended information.
+parseable
+
+Default: false
+Type: Boolean
+
+Show parseable output instead of tree view.
+global
+
+Default: false
+Type: Boolean
+
+List packages in the global install prefix instead of in the current
+project.
+depth
+
+Max display depth of the dependency tree.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-outdated.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-outdated.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-outdated.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-outdated.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,47 @@
+ Check for outdated packages
+SYNOPSIS
+npm outdated [<name> [<name> ...]]
+
DESCRIPTION
+This command will check the registry to see if any (or, specific) installed
+packages are currently outdated.
+The resulting field 'wanted' shows the latest version according to the
+version specified in the package.json, the field 'latest' the very latest
+version of the package.
+CONFIGURATION
+json
+
+Default: false
+Type: Boolean
+
+Show information in JSON format.
+long
+
+Default: false
+Type: Boolean
+
+Show extended information.
+parseable
+
+Default: false
+Type: Boolean
+
+Show parseable output instead of tree view.
+global
+
+Default: false
+Type: Boolean
+
+Check packages in the global install prefix instead of in the current
+project.
+depth
+
+Max depth for checking dependency tree.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-owner.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-owner.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-owner.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-owner.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,29 @@
+ Manage package owners
+SYNOPSIS
+npm owner ls <package name>
+npm owner add <user> <package name>
+npm owner rm <user> <package name>
+
DESCRIPTION
+Manage ownership of published packages.
+
+ls:
+List all the users who have access to modify a package and push new versions.
+Handy when you need to know who to bug for help.
+add:
+Add a new user as a maintainer of a package. This user is enabled to modify
+metadata, publish new versions, and add other owners.
+rm:
+Remove a user from the package owner list. This immediately revokes their
+privileges.
+
+Note that there is only one level of access. Either you can modify a package,
+or you can't. Future versions may contain more fine-grained access levels, but
+that is not implemented at this time.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-pack.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-pack.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-pack.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-pack.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,21 @@
+ Create a tarball from a package
+SYNOPSIS
+npm pack [<pkg> [<pkg> ...]]
+
DESCRIPTION
+For anything that's installable (that is, a package folder, tarball,
+tarball url, name@tag, name@version, or name), this command will fetch
+it to the cache, and then copy the tarball to the current working
+directory as <name>-<version>.tgz
, and then write the filenames out to
+stdout.
+If the same package is specified multiple times, then the file will be
+overwritten the second time.
+If no arguments are supplied, then npm packs the current package folder.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-prefix.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-prefix.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-prefix.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-prefix.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,18 @@
+ Display prefix
+SYNOPSIS
+npm prefix [-g]
+
DESCRIPTION
+Print the local prefix to standard out. This is the closest parent directory
+to contain a package.json file unless -g
is also specified.
+If -g
is specified, this will be the value of the global prefix. See
+npm-config(7)
for more detail.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-prune.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-prune.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-prune.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-prune.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,19 @@
+ Remove extraneous packages
+SYNOPSIS
+npm prune [<name> [<name ...]]
+npm prune [<name> [<name ...]] [--production]
+
DESCRIPTION
+This command removes "extraneous" packages. If a package name is
+provided, then only packages matching one of the supplied names are
+removed.
+Extraneous packages are packages that are not listed on the parent
+package's dependencies list.
+If the --production
flag is specified, this command will remove the
+packages specified in your devDependencies
.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-publish.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-publish.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-publish.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-publish.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,39 @@
+ Publish a package
+SYNOPSIS
+npm publish <tarball> [--tag <tag>]
+npm publish <folder> [--tag <tag>]
+
DESCRIPTION
+Publishes a package to the registry so that it can be installed by name. See
+npm-developers(7)
for details on what's included in the published package, as
+well as details on how the package is built.
+By default npm will publish to the public registry. This can be overridden by
+specifying a different default registry or using a npm-scope(7)
in the name
+(see package.json(5)
).
+
+<folder>
:
+A folder containing a package.json file
+
+<tarball>
:
+A url or file path to a gzipped tar archive containing a single folder
+with a package.json file inside.
+
+[--tag <tag>]
+Registers the published package with the given tag, such that npm install
+<name>@<tag>
will install this version. By default, npm publish
updates
+and npm install
installs the latest
tag.
+
+
+Fails if the package name and version combination already exists in
+the specified registry.
+Once a package is published with a given name and version, that
+specific name and version combination can never be used again, even if
+it is removed with npm-unpublish(1) .
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-rebuild.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-rebuild.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-rebuild.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-rebuild.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,18 @@
+ Rebuild a package
+SYNOPSIS
+npm rebuild [<name> [<name> ...]]
+npm rb [<name> [<name> ...]]
+
+<name>
:
+The package to rebuild
+
+DESCRIPTION
+This command runs the npm build
command on the matched folders. This is useful
+when you install a new version of node, and must recompile all your C++ addons with
+the new binary.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-repo.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-repo.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-repo.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-repo.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,22 @@
+ Open package repository page in the browser
+SYNOPSIS
+npm repo <pkgname>
+npm repo (with no args in a package dir)
+
DESCRIPTION
+This command tries to guess at the likely location of a package's
+repository URL, and then tries to open it using the --browser
+config param. If no package name is provided, it will search for
+a package.json
in the current folder and use the name
property.
+CONFIGURATION
+browser
+
+Default: OS X: "open"
, Windows: "start"
, Others: "xdg-open"
+Type: String
+
+The browser that is called by the npm repo
command to open websites.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-restart.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-restart.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-restart.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-restart.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,15 @@
+ Start a package
+SYNOPSIS
+npm restart [-- <args>]
+
DESCRIPTION
+This runs a package's "restart" script, if one was provided. Otherwise it runs
+package's "stop" script, if one was provided, and then the "start" script.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-rm.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-rm.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-rm.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-rm.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,19 @@
+ Remove a package
+SYNOPSIS
+npm rm <name>
+npm r <name>
+npm uninstall <name>
+npm un <name>
+
DESCRIPTION
+This uninstalls a package, completely removing everything npm installed
+on its behalf.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-root.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-root.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-root.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-root.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,15 @@
+ Display npm root
+SYNOPSIS
+npm root
+
DESCRIPTION
+Print the effective node_modules
folder to standard out.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-run-script.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-run-script.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-run-script.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-run-script.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,27 @@
+ Run arbitrary package scripts
+SYNOPSIS
+npm run-script [command] [-- <args>]
+npm run [command] [-- <args>]
+
DESCRIPTION
+This runs an arbitrary command from a package's "scripts"
object.
+If no package name is provided, it will search for a package.json
+in the current folder and use its "scripts"
object. If no "command"
+is provided, it will list the available top level scripts.
+It is used by the test, start, restart, and stop commands, but can be
+called directly, as well.
+As of npm@2.0.0
, you can
+use custom arguments when executing scripts. The special option --
is used by
+getopt to delimit the end of the options. npm will pass
+all the arguments after the --
directly to your script:
+npm run test -- --grep="pattern"
+
The arguments will only be passed to the script specified after npm run
+and not to any pre or post script.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-search.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-search.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-search.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-search.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,29 @@
+ Search for packages
+SYNOPSIS
+npm search [--long] [search terms ...]
+npm s [search terms ...]
+npm se [search terms ...]
+
DESCRIPTION
+Search the registry for packages matching the search terms.
+If a term starts with /
, then it's interpreted as a regular expression.
+A trailing /
will be ignored in this case. (Note that many regular
+expression characters must be escaped or quoted in most shells.)
+CONFIGURATION
+long
+
+Default: false
+Type: Boolean
+
+Display full package descriptions and other long text across multiple
+lines. When disabled (default) search results are truncated to fit
+neatly on a single line. Modules with extremely long names will
+fall on multiple lines.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-shrinkwrap.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-shrinkwrap.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-shrinkwrap.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-shrinkwrap.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,144 @@
+ Lock down dependency versions
+SYNOPSIS
+npm shrinkwrap
+
DESCRIPTION
+This command locks down the versions of a package's dependencies so
+that you can control exactly which versions of each dependency will be
+used when your package is installed. The "package.json" file is still
+required if you want to use "npm install".
+By default, "npm install" recursively installs the target's
+dependencies (as specified in package.json), choosing the latest
+available version that satisfies the dependency's semver pattern. In
+some situations, particularly when shipping software where each change
+is tightly managed, it's desirable to fully specify each version of
+each dependency recursively so that subsequent builds and deploys do
+not inadvertently pick up newer versions of a dependency that satisfy
+the semver pattern. Specifying specific semver patterns in each
+dependency's package.json would facilitate this, but that's not always
+possible or desirable, as when another author owns the npm package.
+It's also possible to check dependencies directly into source control,
+but that may be undesirable for other reasons.
+As an example, consider package A:
+{
+ "name": "A",
+ "version": "0.1.0",
+ "dependencies": {
+ "B": "<0.1.0"
+ }
+}
+
package B:
+{
+ "name": "B",
+ "version": "0.0.1",
+ "dependencies": {
+ "C": "<0.1.0"
+ }
+}
+
and package C:
+{
+ "name": "C,
+ "version": "0.0.1"
+}
+
If these are the only versions of A, B, and C available in the
+registry, then a normal "npm install A" will install:
+A@0.1.0
+`-- B@0.0.1
+ `-- C@0.0.1
+
However, if B@0.0.2 is published, then a fresh "npm install A" will
+install:
+A@0.1.0
+`-- B@0.0.2
+ `-- C@0.0.1
+
assuming the new version did not modify B's dependencies. Of course,
+the new version of B could include a new version of C and any number
+of new dependencies. If such changes are undesirable, the author of A
+could specify a dependency on B@0.0.1. However, if A's author and B's
+author are not the same person, there's no way for A's author to say
+that he or she does not want to pull in newly published versions of C
+when B hasn't changed at all.
+In this case, A's author can run
+npm shrinkwrap
+
This generates npm-shrinkwrap.json, which will look something like this:
+{
+ "name": "A",
+ "version": "0.1.0",
+ "dependencies": {
+ "B": {
+ "version": "0.0.1",
+ "dependencies": {
+ "C": {
+ "version": "0.1.0"
+ }
+ }
+ }
+ }
+}
+
The shrinkwrap command has locked down the dependencies based on
+what's currently installed in node_modules. When "npm install"
+installs a package with a npm-shrinkwrap.json file in the package
+root, the shrinkwrap file (rather than package.json files) completely
+drives the installation of that package and all of its dependencies
+(recursively). So now the author publishes A@0.1.0, and subsequent
+installs of this package will use B@0.0.1 and C@0.1.0, regardless the
+dependencies and versions listed in A's, B's, and C's package.json
+files.
+Using shrinkwrapped packages
+Using a shrinkwrapped package is no different than using any other
+package: you can "npm install" it by hand, or add a dependency to your
+package.json file and "npm install" it.
+Building shrinkwrapped packages
+To shrinkwrap an existing package:
+
+Run "npm install" in the package root to install the current
+versions of all dependencies.
+Validate that the package works as expected with these versions.
+Run "npm shrinkwrap", add npm-shrinkwrap.json to git, and publish
+your package.
+
+To add or update a dependency in a shrinkwrapped package:
+
+Run "npm install" in the package root to install the current
+versions of all dependencies.
+Add or update dependencies. "npm install" each new or updated
+package individually and then update package.json. Note that they
+must be explicitly named in order to be installed: running npm
+install
with no arguments will merely reproduce the existing
+shrinkwrap.
+Validate that the package works as expected with the new
+dependencies.
+Run "npm shrinkwrap", commit the new npm-shrinkwrap.json, and
+publish your package.
+
+You can use npm-outdated(1) to view dependencies with newer versions
+available.
+Other Notes
+A shrinkwrap file must be consistent with the package's package.json
+file. "npm shrinkwrap" will fail if required dependencies are not
+already installed, since that would result in a shrinkwrap that
+wouldn't actually work. Similarly, the command will fail if there are
+extraneous packages (not referenced by package.json), since that would
+indicate that package.json is not correct.
+Since "npm shrinkwrap" is intended to lock down your dependencies for
+production use, devDependencies
will not be included unless you
+explicitly set the --dev
flag when you run npm shrinkwrap
. If
+installed devDependencies
are excluded, then npm will print a
+warning. If you want them to be installed with your module by
+default, please consider adding them to dependencies
instead.
+If shrinkwrapped package A depends on shrinkwrapped package B, B's
+shrinkwrap will not be used as part of the installation of A. However,
+because A's shrinkwrap is constructed from a valid installation of B
+and recursively specifies all dependencies, the contents of B's
+shrinkwrap will implicitly be included in A's shrinkwrap.
+Caveats
+If you wish to lock down the specific bytes included in a package, for
+example to have 100% confidence in being able to reproduce a
+deployment or build, then you ought to check your dependencies into
+source control, or pursue some other mechanism that can verify
+contents rather than versions.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-star.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-star.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-star.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-star.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,16 @@
+ Mark your favorite packages
+SYNOPSIS
+npm star <pkgname> [<pkg>, ...]
+npm unstar <pkgname> [<pkg>, ...]
+
DESCRIPTION
+"Starring" a package means that you have some interest in it. It's
+a vaguely positive way to show that you care.
+"Unstarring" is the same thing, but in reverse.
+It's a boolean thing. Starring repeatedly has no additional effect.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-stars.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-stars.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-stars.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-stars.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,17 @@
+ View packages marked as favorites
+SYNOPSIS
+npm stars
+npm stars [username]
+
DESCRIPTION
+If you have starred a lot of neat things and want to find them again
+quickly this command lets you do just that.
+You may also want to see your friend's favorite packages, in this case
+you will most certainly enjoy this command.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-start.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-start.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-start.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-start.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,14 @@
+ Start a package
+SYNOPSIS
+npm start [-- <args>]
+
DESCRIPTION
+This runs a package's "start" script, if one was provided.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-stop.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-stop.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-stop.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-stop.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,14 @@
+ Stop a package
+SYNOPSIS
+npm stop [-- <args>]
+
DESCRIPTION
+This runs a package's "stop" script, if one was provided.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-submodule.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-submodule.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-submodule.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-submodule.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,22 @@
+ Add a package as a git submodule
+SYNOPSIS
+npm submodule <pkg>
+
DESCRIPTION
+If the specified package has a git repository url in its package.json
+description, then this command will add it as a git submodule at
+node_modules/<pkg name>
.
+This is a convenience only. From then on, it's up to you to manage
+updates by using the appropriate git commands. npm will stubbornly
+refuse to update, modify, or remove anything with a .git
subfolder
+in it.
+This command also does not install missing dependencies, if the package
+does not include them in its git repository. If npm ls
reports that
+things are missing, you can either install, link, or submodule them yourself,
+or you can do npm explore <pkgname> -- npm install
to install the
+dependencies into the submodule folder.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-tag.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-tag.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-tag.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-tag.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,24 @@
+ Tag a published version
+SYNOPSIS
+npm tag <name>@<version> [<tag>]
+
DESCRIPTION
+Tags the specified version of the package with the specified tag, or the
+--tag
config if not specified.
+A tag can be used when installing packages as a reference to a version instead
+of using a specific version number:
+npm install <name>@<tag>
+
When installing dependencies, a preferred tagged version may be specified:
+npm install --tag <tag>
+
This also applies to npm dedupe
.
+Publishing a package always sets the "latest" tag to the published version.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-test.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-test.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-test.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-test.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,17 @@
+ Test a package
+SYNOPSIS
+ npm test [-- <args>]
+ npm tst [-- <args>]
+
DESCRIPTION
+This runs a package's "test" script, if one was provided.
+To run tests as a condition of installation, set the npat
config to
+true.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-uninstall.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-uninstall.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-uninstall.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-uninstall.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,37 @@
+ Remove a package
+SYNOPSIS
+npm uninstall [@<scope>/]<package> [--save|--save-dev|--save-optional]
+npm rm (with any of the previous argument usage)
+
DESCRIPTION
+This uninstalls a package, completely removing everything npm installed
+on its behalf.
+Example:
+npm uninstall sax
+
In global mode (ie, with -g
or --global
appended to the command),
+it uninstalls the current package context as a global package.
+npm uninstall
takes 3 exclusive, optional flags which save or update
+the package version in your main package.json:
+
+--save
: Package will be removed from your dependencies
.
+
+--save-dev
: Package will be removed from your devDependencies
.
+
+--save-optional
: Package will be removed from your optionalDependencies
.
+
+
+Scope is optional and follows the usual rules for npm-scope(7)
.
+Examples:
+npm uninstall sax --save
+npm uninstall @myorg/privatepackage --save
+npm uninstall node-tap --save-dev
+npm uninstall dtrace-provider --save-optional
+
SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-unpublish.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-unpublish.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-unpublish.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-unpublish.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,27 @@
+ Remove a package from the registry
+SYNOPSIS
+npm unpublish [@<scope>/]<name>[@<version>]
+
WARNING
+It is generally considered bad behavior to remove versions of a library
+that others are depending on!
+Consider using the deprecate
command
+instead, if your intent is to encourage users to upgrade.
+There is plenty of room on the registry.
+DESCRIPTION
+This removes a package version from the registry, deleting its
+entry and removing the tarball.
+If no version is specified, or if all versions are removed then
+the root package entry is removed from the registry entirely.
+Even if a package version is unpublished, that specific name and
+version combination can never be reused. In order to publish the
+package again, a new version number must be used.
+The scope is optional and follows the usual rules for npm-scope(7)
.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-update.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-update.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-update.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-update.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,20 @@
+ Update a package
+SYNOPSIS
+npm update [-g] [<name> [<name> ...]]
+
DESCRIPTION
+This command will update all the packages listed to the latest version
+(specified by the tag
config).
+It will also install missing packages.
+If the -g
flag is specified, this command will update globally installed
+packages.
+If no package name is specified, all packages in the specified location (global
+or local) will be updated.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-version.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-version.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-version.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-version.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,35 @@
+ Bump a package version
+SYNOPSIS
+npm version [<newversion> | major | minor | patch | premajor | preminor | prepatch | prerelease]
+
DESCRIPTION
+Run this in a package directory to bump the version and write the new
+data back to the package.json file.
+The newversion
argument should be a valid semver string, or a
+valid second argument to semver.inc (one of "patch", "minor", "major",
+"prepatch", "preminor", "premajor", "prerelease"). In the second case,
+the existing version will be incremented by 1 in the specified field.
+If run in a git repo, it will also create a version commit and tag, and
+fail if the repo is not clean.
+If supplied with --message
(shorthand: -m
) config option, npm will
+use it as a commit message when creating a version commit. If the
+message
config contains %s
then that will be replaced with the
+resulting version number. For example:
+npm version patch -m "Upgrade to %s for reasons"
+
If the sign-git-tag
config is set, then the tag will be signed using
+the -s
flag to git. Note that you must have a default GPG key set up
+in your git config for this to work properly. For example:
+$ npm config set sign-git-tag true
+$ npm version patch
+
+You need a passphrase to unlock the secret key for
+user: "isaacs (http://blog.izs.me/) <i@izs.me>"
+2048-bit RSA key, ID 6C481CF6, created 2010-08-31
+
+Enter passphrase:
+
SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-view.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-view.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-view.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-view.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,62 @@
+ View registry info
+SYNOPSIS
+npm view [@<scope>/]<name>[@<version>] [<field>[.<subfield>]...]
+npm v [@<scope>/]<name>[@<version>] [<field>[.<subfield>]...]
+
DESCRIPTION
+This command shows data about a package and prints it to the stream
+referenced by the outfd
config, which defaults to stdout.
+To show the package registry entry for the connect
package, you can do
+this:
+npm view connect
+
The default version is "latest" if unspecified.
+Field names can be specified after the package descriptor.
+For example, to show the dependencies of the ronn
package at version
+0.3.5, you could do the following:
+npm view ronn@0.3.5 dependencies
+
You can view child field by separating them with a period.
+To view the git repository URL for the latest version of npm, you could
+do this:
+npm view npm repository.url
+
This makes it easy to view information about a dependency with a bit of
+shell scripting. For example, to view all the data about the version of
+opts that ronn depends on, you can do this:
+npm view opts@$(npm view ronn dependencies.opts)
+
For fields that are arrays, requesting a non-numeric field will return
+all of the values from the objects in the list. For example, to get all
+the contributor names for the "express" project, you can do this:
+npm view express contributors.email
+
You may also use numeric indices in square braces to specifically select
+an item in an array field. To just get the email address of the first
+contributor in the list, you can do this:
+npm view express contributors[0].email
+
Multiple fields may be specified, and will be printed one after another.
+For exampls, to get all the contributor names and email addresses, you
+can do this:
+npm view express contributors.name contributors.email
+
"Person" fields are shown as a string if they would be shown as an
+object. So, for example, this will show the list of npm contributors in
+the shortened string format. (See package.json(5)
for more on this.)
+npm view npm contributors
+
If a version range is provided, then data will be printed for every
+matching version of the package. This will show which version of jsdom
+was required by each matching version of yui3:
+npm view yui3@'>0.5.4' dependencies.jsdom
+
OUTPUT
+If only a single string field for a single version is output, then it
+will not be colorized or quoted, so as to enable piping the output to
+another command. If the field is an object, it will be output as a JavaScript object literal.
+If the --json flag is given, the outputted fields will be JSON.
+If the version range matches multiple versions, than each printed value
+will be prefixed with the version it applies to.
+If multiple fields are requested, than each of them are prefixed with
+the field name.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-whoami.html nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-whoami.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/cli/npm-whoami.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/cli/npm-whoami.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,13 @@
+ Display npm username
+SYNOPSIS
+npm whoami
+
DESCRIPTION
+Print the username
config to standard output.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/files/npm-folders.html nodejs-0.11.15/deps/npm/html/partial/doc/files/npm-folders.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/files/npm-folders.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/files/npm-folders.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,164 @@
+ Folder Structures Used by npm
+DESCRIPTION
+npm puts various things on your computer. That's its job.
+This document will tell you what it puts where.
+tl;dr
+
+Local install (default): puts stuff in ./node_modules
of the current
+package root.
+Global install (with -g
): puts stuff in /usr/local or wherever node
+is installed.
+Install it locally if you're going to require()
it.
+Install it globally if you're going to run it on the command line.
+If you need both, then install it in both places, or use npm link
.
+
+prefix Configuration
+The prefix
config defaults to the location where node is installed.
+On most systems, this is /usr/local
, and most of the time is the same
+as node's process.installPrefix
.
+On windows, this is the exact location of the node.exe binary. On Unix
+systems, it's one level up, since node is typically installed at
+{prefix}/bin/node
rather than {prefix}/node.exe
.
+When the global
flag is set, npm installs things into this prefix.
+When it is not set, it uses the root of the current package, or the
+current working directory if not in a package already.
+Node Modules
+Packages are dropped into the node_modules
folder under the prefix
.
+When installing locally, this means that you can
+require("packagename")
to load its main module, or
+require("packagename/lib/path/to/sub/module")
to load other modules.
+Global installs on Unix systems go to {prefix}/lib/node_modules
.
+Global installs on Windows go to {prefix}/node_modules
(that is, no
+lib
folder.)
+Scoped packages are installed the same way, except they are grouped together
+in a sub-folder of the relevant node_modules
folder with the name of that
+scope prefix by the @ symbol, e.g. npm install @myorg/package
would place
+the package in {prefix}/node_modules/@myorg/package
. See scopes(7)
for
+more details.
+If you wish to require()
a package, then install it locally.
+Executables
+When in global mode, executables are linked into {prefix}/bin
on Unix,
+or directly into {prefix}
on Windows.
+When in local mode, executables are linked into
+./node_modules/.bin
so that they can be made available to scripts run
+through npm. (For example, so that a test runner will be in the path
+when you run npm test
.)
+Man Pages
+When in global mode, man pages are linked into {prefix}/share/man
.
+When in local mode, man pages are not installed.
+Man pages are not installed on Windows systems.
+Cache
+See npm-cache(1)
. Cache files are stored in ~/.npm
on Posix, or
+~/npm-cache
on Windows.
+This is controlled by the cache
configuration param.
+Temp Files
+Temporary files are stored by default in the folder specified by the
+tmp
config, which defaults to the TMPDIR, TMP, or TEMP environment
+variables, or /tmp
on Unix and c:\windows\temp
on Windows.
+Temp files are given a unique folder under this root for each run of the
+program, and are deleted upon successful exit.
+
+When installing locally, npm first tries to find an appropriate
+prefix
folder. This is so that npm install foo@1.2.3
will install
+to the sensible root of your package, even if you happen to have cd
ed
+into some other folder.
+Starting at the $PWD, npm will walk up the folder tree checking for a
+folder that contains either a package.json
file, or a node_modules
+folder. If such a thing is found, then that is treated as the effective
+"current directory" for the purpose of running npm commands. (This
+behavior is inspired by and similar to git's .git-folder seeking
+logic when running git commands in a working dir.)
+If no package root is found, then the current folder is used.
+When you run npm install foo@1.2.3
, then the package is loaded into
+the cache, and then unpacked into ./node_modules/foo
. Then, any of
+foo's dependencies are similarly unpacked into
+./node_modules/foo/node_modules/...
.
+Any bin files are symlinked to ./node_modules/.bin/
, so that they may
+be found by npm scripts when necessary.
+Global Installation
+If the global
configuration is set to true, then npm will
+install packages "globally".
+For global installation, packages are installed roughly the same way,
+but using the folders described above.
+Cycles, Conflicts, and Folder Parsimony
+Cycles are handled using the property of node's module system that it
+walks up the directories looking for node_modules
folders. So, at every
+stage, if a package is already installed in an ancestor node_modules
+folder, then it is not installed at the current location.
+Consider the case above, where foo -> bar -> baz
. Imagine if, in
+addition to that, baz depended on bar, so you'd have:
+foo -> bar -> baz -> bar -> baz ...
. However, since the folder
+structure is: foo/node_modules/bar/node_modules/baz
, there's no need to
+put another copy of bar into .../baz/node_modules
, since when it calls
+require("bar"), it will get the copy that is installed in
+foo/node_modules/bar
.
+This shortcut is only used if the exact same
+version would be installed in multiple nested node_modules
folders. It
+is still possible to have a/node_modules/b/node_modules/a
if the two
+"a" packages are different versions. However, without repeating the
+exact same package multiple times, an infinite regress will always be
+prevented.
+Another optimization can be made by installing dependencies at the
+highest level possible, below the localized "target" folder.
+Example
+Consider this dependency graph:
+foo
++-- blerg@1.2.5
++-- bar@1.2.3
+| +-- blerg@1.x (latest=1.3.7)
+| +-- baz@2.x
+| | `-- quux@3.x
+| | `-- bar@1.2.3 (cycle)
+| `-- asdf@*
+`-- baz@1.2.3
+ `-- quux@3.x
+ `-- bar
+
In this case, we might expect a folder structure like this:
+foo
++-- node_modules
+ +-- blerg (1.2.5) <---[A]
+ +-- bar (1.2.3) <---[B]
+ | `-- node_modules
+ | +-- baz (2.0.2) <---[C]
+ | | `-- node_modules
+ | | `-- quux (3.2.0)
+ | `-- asdf (2.3.4)
+ `-- baz (1.2.3) <---[D]
+ `-- node_modules
+ `-- quux (3.2.0) <---[E]
+
Since foo depends directly on bar@1.2.3
and baz@1.2.3
, those are
+installed in foo's node_modules
folder.
+Even though the latest copy of blerg is 1.3.7, foo has a specific
+dependency on version 1.2.5. So, that gets installed at [A]. Since the
+parent installation of blerg satisfies bar's dependency on blerg@1.x
,
+it does not install another copy under [B].
+Bar [B] also has dependencies on baz and asdf, so those are installed in
+bar's node_modules
folder. Because it depends on baz@2.x
, it cannot
+re-use the baz@1.2.3
installed in the parent node_modules
folder [D],
+and must install its own copy [C].
+Underneath bar, the baz -> quux -> bar
dependency creates a cycle.
+However, because bar is already in quux's ancestry [B], it does not
+unpack another copy of bar into that folder.
+Underneath foo -> baz
[D], quux's [E] folder tree is empty, because its
+dependency on bar is satisfied by the parent folder copy installed at [B].
+For a graphical breakdown of what is installed where, use npm ls
.
+Publishing
+Upon publishing, npm will look in the node_modules
folder. If any of
+the items there are not in the bundledDependencies
array, then they will
+not be included in the package tarball.
+This allows a package maintainer to install all of their dependencies
+(and dev dependencies) locally, but only re-publish those items that
+cannot be found elsewhere. See package.json(5)
for more information.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/files/npm-global.html nodejs-0.11.15/deps/npm/html/partial/doc/files/npm-global.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/files/npm-global.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/files/npm-global.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,164 @@
+ Folder Structures Used by npm
+DESCRIPTION
+npm puts various things on your computer. That's its job.
+This document will tell you what it puts where.
+tl;dr
+
+Local install (default): puts stuff in ./node_modules
of the current
+package root.
+Global install (with -g
): puts stuff in /usr/local or wherever node
+is installed.
+Install it locally if you're going to require()
it.
+Install it globally if you're going to run it on the command line.
+If you need both, then install it in both places, or use npm link
.
+
+prefix Configuration
+The prefix
config defaults to the location where node is installed.
+On most systems, this is /usr/local
, and most of the time is the same
+as node's process.installPrefix
.
+On windows, this is the exact location of the node.exe binary. On Unix
+systems, it's one level up, since node is typically installed at
+{prefix}/bin/node
rather than {prefix}/node.exe
.
+When the global
flag is set, npm installs things into this prefix.
+When it is not set, it uses the root of the current package, or the
+current working directory if not in a package already.
+Node Modules
+Packages are dropped into the node_modules
folder under the prefix
.
+When installing locally, this means that you can
+require("packagename")
to load its main module, or
+require("packagename/lib/path/to/sub/module")
to load other modules.
+Global installs on Unix systems go to {prefix}/lib/node_modules
.
+Global installs on Windows go to {prefix}/node_modules
(that is, no
+lib
folder.)
+Scoped packages are installed the same way, except they are grouped together
+in a sub-folder of the relevant node_modules
folder with the name of that
+scope prefix by the @ symbol, e.g. npm install @myorg/package
would place
+the package in {prefix}/node_modules/@myorg/package
. See scopes(7)
for
+more details.
+If you wish to require()
a package, then install it locally.
+Executables
+When in global mode, executables are linked into {prefix}/bin
on Unix,
+or directly into {prefix}
on Windows.
+When in local mode, executables are linked into
+./node_modules/.bin
so that they can be made available to scripts run
+through npm. (For example, so that a test runner will be in the path
+when you run npm test
.)
+Man Pages
+When in global mode, man pages are linked into {prefix}/share/man
.
+When in local mode, man pages are not installed.
+Man pages are not installed on Windows systems.
+Cache
+See npm-cache(1)
. Cache files are stored in ~/.npm
on Posix, or
+~/npm-cache
on Windows.
+This is controlled by the cache
configuration param.
+Temp Files
+Temporary files are stored by default in the folder specified by the
+tmp
config, which defaults to the TMPDIR, TMP, or TEMP environment
+variables, or /tmp
on Unix and c:\windows\temp
on Windows.
+Temp files are given a unique folder under this root for each run of the
+program, and are deleted upon successful exit.
+
+When installing locally, npm first tries to find an appropriate
+prefix
folder. This is so that npm install foo@1.2.3
will install
+to the sensible root of your package, even if you happen to have cd
ed
+into some other folder.
+Starting at the $PWD, npm will walk up the folder tree checking for a
+folder that contains either a package.json
file, or a node_modules
+folder. If such a thing is found, then that is treated as the effective
+"current directory" for the purpose of running npm commands. (This
+behavior is inspired by and similar to git's .git-folder seeking
+logic when running git commands in a working dir.)
+If no package root is found, then the current folder is used.
+When you run npm install foo@1.2.3
, then the package is loaded into
+the cache, and then unpacked into ./node_modules/foo
. Then, any of
+foo's dependencies are similarly unpacked into
+./node_modules/foo/node_modules/...
.
+Any bin files are symlinked to ./node_modules/.bin/
, so that they may
+be found by npm scripts when necessary.
+Global Installation
+If the global
configuration is set to true, then npm will
+install packages "globally".
+For global installation, packages are installed roughly the same way,
+but using the folders described above.
+Cycles, Conflicts, and Folder Parsimony
+Cycles are handled using the property of node's module system that it
+walks up the directories looking for node_modules
folders. So, at every
+stage, if a package is already installed in an ancestor node_modules
+folder, then it is not installed at the current location.
+Consider the case above, where foo -> bar -> baz
. Imagine if, in
+addition to that, baz depended on bar, so you'd have:
+foo -> bar -> baz -> bar -> baz ...
. However, since the folder
+structure is: foo/node_modules/bar/node_modules/baz
, there's no need to
+put another copy of bar into .../baz/node_modules
, since when it calls
+require("bar"), it will get the copy that is installed in
+foo/node_modules/bar
.
+This shortcut is only used if the exact same
+version would be installed in multiple nested node_modules
folders. It
+is still possible to have a/node_modules/b/node_modules/a
if the two
+"a" packages are different versions. However, without repeating the
+exact same package multiple times, an infinite regress will always be
+prevented.
+Another optimization can be made by installing dependencies at the
+highest level possible, below the localized "target" folder.
+Example
+Consider this dependency graph:
+foo
++-- blerg@1.2.5
++-- bar@1.2.3
+| +-- blerg@1.x (latest=1.3.7)
+| +-- baz@2.x
+| | `-- quux@3.x
+| | `-- bar@1.2.3 (cycle)
+| `-- asdf@*
+`-- baz@1.2.3
+ `-- quux@3.x
+ `-- bar
+
In this case, we might expect a folder structure like this:
+foo
++-- node_modules
+ +-- blerg (1.2.5) <---[A]
+ +-- bar (1.2.3) <---[B]
+ | `-- node_modules
+ | +-- baz (2.0.2) <---[C]
+ | | `-- node_modules
+ | | `-- quux (3.2.0)
+ | `-- asdf (2.3.4)
+ `-- baz (1.2.3) <---[D]
+ `-- node_modules
+ `-- quux (3.2.0) <---[E]
+
Since foo depends directly on bar@1.2.3
and baz@1.2.3
, those are
+installed in foo's node_modules
folder.
+Even though the latest copy of blerg is 1.3.7, foo has a specific
+dependency on version 1.2.5. So, that gets installed at [A]. Since the
+parent installation of blerg satisfies bar's dependency on blerg@1.x
,
+it does not install another copy under [B].
+Bar [B] also has dependencies on baz and asdf, so those are installed in
+bar's node_modules
folder. Because it depends on baz@2.x
, it cannot
+re-use the baz@1.2.3
installed in the parent node_modules
folder [D],
+and must install its own copy [C].
+Underneath bar, the baz -> quux -> bar
dependency creates a cycle.
+However, because bar is already in quux's ancestry [B], it does not
+unpack another copy of bar into that folder.
+Underneath foo -> baz
[D], quux's [E] folder tree is empty, because its
+dependency on bar is satisfied by the parent folder copy installed at [B].
+For a graphical breakdown of what is installed where, use npm ls
.
+Publishing
+Upon publishing, npm will look in the node_modules
folder. If any of
+the items there are not in the bundledDependencies
array, then they will
+not be included in the package tarball.
+This allows a package maintainer to install all of their dependencies
+(and dev dependencies) locally, but only re-publish those items that
+cannot be found elsewhere. See package.json(5)
for more information.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/files/npm-json.html nodejs-0.11.15/deps/npm/html/partial/doc/files/npm-json.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/files/npm-json.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/files/npm-json.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,465 @@
+ Specifics of npm's package.json handling
+DESCRIPTION
+This document is all you need to know about what's required in your package.json
+file. It must be actual JSON, not just a JavaScript object literal.
+A lot of the behavior described in this document is affected by the config
+settings described in npm-config(7)
.
+name
+The most important things in your package.json are the name and version fields.
+Those are actually required, and your package won't install without
+them. The name and version together form an identifier that is assumed
+to be completely unique. Changes to the package should come along with
+changes to the version.
+The name is what your thing is called. Some tips:
+
+Don't put "js" or "node" in the name. It's assumed that it's js, since you're
+writing a package.json file, and you can specify the engine using the "engines"
+field. (See below.)
+The name ends up being part of a URL, an argument on the command line, and a
+folder name. Any name with non-url-safe characters will be rejected.
+Also, it can't start with a dot or an underscore.
+The name will probably be passed as an argument to require(), so it should
+be something short, but also reasonably descriptive.
+You may want to check the npm registry to see if there's something by that name
+already, before you get too attached to it. http://registry.npmjs.org/
+
+A name can be optionally prefixed by a scope, e.g. @myorg/mypackage
. See
+npm-scope(7)
for more detail.
+version
+The most important things in your package.json are the name and version fields.
+Those are actually required, and your package won't install without
+them. The name and version together form an identifier that is assumed
+to be completely unique. Changes to the package should come along with
+changes to the version.
+Version must be parseable by
+node-semver , which is bundled
+with npm as a dependency. (npm install semver
to use it yourself.)
+More on version numbers and ranges at semver(7) .
+description
+Put a description in it. It's a string. This helps people discover your
+package, as it's listed in npm search
.
+keywords
+Put keywords in it. It's an array of strings. This helps people
+discover your package as it's listed in npm search
.
+homepage
+The url to the project homepage.
+NOTE : This is not the same as "url". If you put a "url" field,
+then the registry will think it's a redirection to your package that has
+been published somewhere else, and spit at you.
+Literally. Spit. I'm so not kidding.
+bugs
+The url to your project's issue tracker and / or the email address to which
+issues should be reported. These are helpful for people who encounter issues
+with your package.
+It should look like this:
+{ "url" : "http://github.com/owner/project/issues"
+, "email" : "project@hostname.com"
+}
+
You can specify either one or both values. If you want to provide only a url,
+you can specify the value for "bugs" as a simple string instead of an object.
+If a url is provided, it will be used by the npm bugs
command.
+license
+You should specify a license for your package so that people know how they are
+permitted to use it, and any restrictions you're placing on it.
+The simplest way, assuming you're using a common license such as BSD-3-Clause
+or MIT, is to just specify the standard SPDX ID of the license you're using,
+like this:
+{ "license" : "BSD-3-Clause" }
+
You can check the full list of SPDX license IDs .
+Ideally you should pick one that is
+OSI approved.
+It's also a good idea to include a LICENSE file at the top level in
+your package.
+people fields: author, contributors
+The "author" is one person. "contributors" is an array of people. A "person"
+is an object with a "name" field and optionally "url" and "email", like this:
+{ "name" : "Barney Rubble"
+, "email" : "b@rubble.com"
+, "url" : "http://barnyrubble.tumblr.com/"
+}
+
Or you can shorten that all into a single string, and npm will parse it for you:
+"Barney Rubble <b@rubble.com> (http://barnyrubble.tumblr.com/)
+
Both email and url are optional either way.
+npm also sets a top-level "maintainers" field with your npm user info.
+files
+The "files" field is an array of files to include in your project. If
+you name a folder in the array, then it will also include the files
+inside that folder. (Unless they would be ignored by another rule.)
+You can also provide a ".npmignore" file in the root of your package,
+which will keep files from being included, even if they would be picked
+up by the files array. The ".npmignore" file works just like a
+".gitignore".
+main
+The main field is a module ID that is the primary entry point to your program.
+That is, if your package is named foo
, and a user installs it, and then does
+require("foo")
, then your main module's exports object will be returned.
+This should be a module ID relative to the root of your package folder.
+For most modules, it makes the most sense to have a main script and often not
+much else.
+bin
+A lot of packages have one or more executable files that they'd like to
+install into the PATH. npm makes this pretty easy (in fact, it uses this
+feature to install the "npm" executable.)
+To use this, supply a bin
field in your package.json which is a map of
+command name to local file name. On install, npm will symlink that file into
+prefix/bin
for global installs, or ./node_modules/.bin/
for local
+installs.
+For example, npm has this:
+{ "bin" : { "npm" : "./cli.js" } }
+
So, when you install npm, it'll create a symlink from the cli.js
script to
+/usr/local/bin/npm
.
+If you have a single executable, and its name should be the name
+of the package, then you can just supply it as a string. For example:
+{ "name": "my-program"
+, "version": "1.2.5"
+, "bin": "./path/to/program" }
+
would be the same as this:
+{ "name": "my-program"
+, "version": "1.2.5"
+, "bin" : { "my-program" : "./path/to/program" } }
+
man
+Specify either a single file or an array of filenames to put in place for the
+man
program to find.
+If only a single file is provided, then it's installed such that it is the
+result from man <pkgname>
, regardless of its actual filename. For example:
+{ "name" : "foo"
+, "version" : "1.2.3"
+, "description" : "A packaged foo fooer for fooing foos"
+, "main" : "foo.js"
+, "man" : "./man/doc.1"
+}
+
would link the ./man/doc.1
file in such that it is the target for man foo
+If the filename doesn't start with the package name, then it's prefixed.
+So, this:
+{ "name" : "foo"
+, "version" : "1.2.3"
+, "description" : "A packaged foo fooer for fooing foos"
+, "main" : "foo.js"
+, "man" : [ "./man/foo.1", "./man/bar.1" ]
+}
+
will create files to do man foo
and man foo-bar
.
+Man files must end with a number, and optionally a .gz
suffix if they are
+compressed. The number dictates which man section the file is installed into.
+{ "name" : "foo"
+, "version" : "1.2.3"
+, "description" : "A packaged foo fooer for fooing foos"
+, "main" : "foo.js"
+, "man" : [ "./man/foo.1", "./man/foo.2" ]
+}
+
will create entries for man foo
and man 2 foo
+directories
+The CommonJS Packages spec details a
+few ways that you can indicate the structure of your package using a directories
+object. If you look at npm's package.json ,
+you'll see that it has directories for doc, lib, and man.
+In the future, this information may be used in other creative ways.
+directories.lib
+Tell people where the bulk of your library is. Nothing special is done
+with the lib folder in any way, but it's useful meta info.
+directories.bin
+If you specify a bin
directory, then all the files in that folder will
+be added as children of the bin
path.
+If you have a bin
path already, then this has no effect.
+directories.man
+A folder that is full of man pages. Sugar to generate a "man" array by
+walking the folder.
+directories.doc
+Put markdown files in here. Eventually, these will be displayed nicely,
+maybe, someday.
+directories.example
+Put example scripts in here. Someday, it might be exposed in some clever way.
+repository
+Specify the place where your code lives. This is helpful for people who
+want to contribute. If the git repo is on github, then the npm docs
+command will be able to find you.
+Do it like this:
+"repository" :
+ { "type" : "git"
+ , "url" : "http://github.com/npm/npm.git"
+ }
+
+"repository" :
+ { "type" : "svn"
+ , "url" : "http://v8.googlecode.com/svn/trunk/"
+ }
+
The URL should be a publicly available (perhaps read-only) url that can be handed
+directly to a VCS program without any modification. It should not be a url to an
+html project page that you put in your browser. It's for computers.
+scripts
+The "scripts" property is a dictionary containing script commands that are run
+at various times in the lifecycle of your package. The key is the lifecycle
+event, and the value is the command to run at that point.
+See npm-scripts(7)
to find out more about writing package scripts.
+config
+A "config" object can be used to set configuration parameters used in package
+scripts that persist across upgrades. For instance, if a package had the
+following:
+{ "name" : "foo"
+, "config" : { "port" : "8080" } }
+
and then had a "start" command that then referenced the
+npm_package_config_port
environment variable, then the user could
+override that by doing npm config set foo:port 8001
.
+See npm-config(7)
and npm-scripts(7)
for more on package
+configs.
+dependencies
+Dependencies are specified in a simple object that maps a package name to a
+version range. The version range is a string which has one or more
+space-separated descriptors. Dependencies can also be identified with a
+tarball or git URL.
+Please do not put test harnesses or transpilers in your
+dependencies
object. See devDependencies
, below.
+See semver(7) for more details about specifying version ranges.
+
+version
Must match version
exactly
+>version
Must be greater than version
+>=version
etc
+<version
+<=version
+~version
"Approximately equivalent to version" See semver(7)
+^version
"Compatible with version" See semver(7)
+1.2.x
1.2.0, 1.2.1, etc., but not 1.3.0
+http://...
See 'URLs as Dependencies' below
+*
Matches any version
+""
(just an empty string) Same as *
+version1 - version2
Same as >=version1 <=version2
.
+range1 || range2
Passes if either range1 or range2 are satisfied.
+git...
See 'Git URLs as Dependencies' below
+user/repo
See 'GitHub URLs' below
+tag
A specific version tagged and published as tag
See npm-tag(1)
+path/path/path
See Local Paths below
+
+For example, these are all valid:
+{ "dependencies" :
+ { "foo" : "1.0.0 - 2.9999.9999"
+ , "bar" : ">=1.0.2 <2.1.2"
+ , "baz" : ">1.0.2 <=2.3.4"
+ , "boo" : "2.0.1"
+ , "qux" : "<1.0.0 || >=2.3.1 <2.4.5 || >=2.5.2 <3.0.0"
+ , "asd" : "http://asdf.com/asdf.tar.gz"
+ , "til" : "~1.2"
+ , "elf" : "~1.2.3"
+ , "two" : "2.x"
+ , "thr" : "3.3.x"
+ , "lat" : "latest"
+ , "dyl" : "file:../dyl"
+ }
+}
+
URLs as Dependencies
+You may specify a tarball URL in place of a version range.
+This tarball will be downloaded and installed locally to your package at
+install time.
+Git URLs as Dependencies
+Git urls can be of the form:
+git://github.com/user/project.git#commit-ish
+git+ssh://user@hostname:project.git#commit-ish
+git+ssh://user@hostname/project.git#commit-ish
+git+http://user@hostname/project/blah.git#commit-ish
+git+https://user@hostname/project/blah.git#commit-ish
+
The commit-ish
can be any tag, sha, or branch which can be supplied as
+an argument to git checkout
. The default is master
.
+GitHub URLs
+As of version 1.1.65, you can refer to GitHub urls as just "foo": "user/foo-project". For example:
+{
+ "name": "foo",
+ "version": "0.0.0",
+ "dependencies": {
+ "express": "visionmedia/express"
+ }
+}
+
Local Paths
+As of version 2.0.0 you can provide a path to a local directory that contains a
+package. Local paths can be saved using npm install --save
, using any of
+these forms:
+../foo/bar
+~/foo/bar
+./foo/bar
+/foo/bar
+
in which case they will be normalized to a relative path and added to your
+package.json
. For example:
+{
+ "name": "baz",
+ "dependencies": {
+ "bar": "file:../foo/bar"
+ }
+}
+
This feature is helpful for local offline development and creating
+tests that require npm installing where you don't want to hit an
+external server, but should not be used when publishing packages
+to the public registry.
+devDependencies
+If someone is planning on downloading and using your module in their
+program, then they probably don't want or need to download and build
+the external test or documentation framework that you use.
+In this case, it's best to map these additional items in a devDependencies
+object.
+These things will be installed when doing npm link
or npm install
+from the root of a package, and can be managed like any other npm
+configuration param. See npm-config(7)
for more on the topic.
+For build steps that are not platform-specific, such as compiling
+CoffeeScript or other languages to JavaScript, use the prepublish
+script to do this, and make the required package a devDependency.
+For example:
+{ "name": "ethopia-waza",
+ "description": "a delightfully fruity coffee varietal",
+ "version": "1.2.3",
+ "devDependencies": {
+ "coffee-script": "~1.6.3"
+ },
+ "scripts": {
+ "prepublish": "coffee -o lib/ -c src/waza.coffee"
+ },
+ "main": "lib/waza.js"
+}
+
The prepublish
script will be run before publishing, so that users
+can consume the functionality without requiring them to compile it
+themselves. In dev mode (ie, locally running npm install
), it'll
+run this script as well, so that you can test it easily.
+peerDependencies
+In some cases, you want to express the compatibility of your package with an
+host tool or library, while not necessarily doing a require
of this host.
+This is usually refered to as a plugin . Notably, your module may be exposing
+a specific interface, expected and specified by the host documentation.
+For example:
+{
+ "name": "tea-latte",
+ "version": "1.3.5"
+ "peerDependencies": {
+ "tea": "2.x"
+ }
+}
+
This ensures your package tea-latte
can be installed along with the second
+major version of the host package tea
only. The host package is automatically
+installed if needed. npm install tea-latte
could possibly yield the following
+dependency graph:
+├── tea-latte@1.3.5
+└── tea@2.2.0
+
Trying to install another plugin with a conflicting requirement will cause an
+error. For this reason, make sure your plugin requirement is as broad as
+possible, and not to lock it down to specific patch versions.
+Assuming the host complies with semver , only changes in
+the host package's major version will break your plugin. Thus, if you've worked
+with every 1.x version of the host package, use "^1.0"
or "1.x"
to express
+this. If you depend on features introduced in 1.5.2, use ">= 1.5.2 < 2"
.
+bundledDependencies
+Array of package names that will be bundled when publishing the package.
+If this is spelled "bundleDependencies"
, then that is also honorable.
+optionalDependencies
+If a dependency can be used, but you would like npm to proceed if it cannot be
+found or fails to install, then you may put it in the optionalDependencies
+object. This is a map of package name to version or url, just like the
+dependencies
object. The difference is that build failures do not cause
+installation to fail.
+It is still your program's responsibility to handle the lack of the
+dependency. For example, something like this:
+try {
+ var foo = require('foo')
+ var fooVersion = require('foo/package.json').version
+} catch (er) {
+ foo = null
+}
+if ( notGoodFooVersion(fooVersion) ) {
+ foo = null
+}
+
+// .. then later in your program ..
+
+if (foo) {
+ foo.doFooThings()
+}
+
Entries in optionalDependencies
will override entries of the same name in
+dependencies
, so it's usually best to only put in one place.
+engines
+You can specify the version of node that your stuff works on:
+{ "engines" : { "node" : ">=0.10.3 <0.12" } }
+
And, like with dependencies, if you don't specify the version (or if you
+specify "*" as the version), then any version of node will do.
+If you specify an "engines" field, then npm will require that "node" be
+somewhere on that list. If "engines" is omitted, then npm will just assume
+that it works on node.
+You can also use the "engines" field to specify which versions of npm
+are capable of properly installing your program. For example:
+{ "engines" : { "npm" : "~1.0.20" } }
+
Note that, unless the user has set the engine-strict
config flag, this
+field is advisory only.
+engineStrict
+If you are sure that your module will definitely not run properly on
+versions of Node/npm other than those specified in the engines
object,
+then you can set "engineStrict": true
in your package.json file.
+This will override the user's engine-strict
config setting.
+Please do not do this unless you are really very very sure. If your
+engines object is something overly restrictive, you can quite easily and
+inadvertently lock yourself into obscurity and prevent your users from
+updating to new versions of Node. Consider this choice carefully. If
+people abuse it, it will be removed in a future version of npm.
+os
+You can specify which operating systems your
+module will run on:
+"os" : [ "darwin", "linux" ]
+
You can also blacklist instead of whitelist operating systems,
+just prepend the blacklisted os with a '!':
+"os" : [ "!win32" ]
+
The host operating system is determined by process.platform
+It is allowed to both blacklist, and whitelist, although there isn't any
+good reason to do this.
+cpu
+If your code only runs on certain cpu architectures,
+you can specify which ones.
+"cpu" : [ "x64", "ia32" ]
+
Like the os
option, you can also blacklist architectures:
+"cpu" : [ "!arm", "!mips" ]
+
The host architecture is determined by process.arch
+preferGlobal
+If your package is primarily a command-line application that should be
+installed globally, then set this value to true
to provide a warning
+if it is installed locally.
+It doesn't actually prevent users from installing it locally, but it
+does help prevent some confusion if it doesn't work as expected.
+private
+If you set "private": true
in your package.json, then npm will refuse
+to publish it.
+This is a way to prevent accidental publication of private repositories. If
+you would like to ensure that a given package is only ever published to a
+specific registry (for example, an internal registry), then use the
+publishConfig
dictionary described below to override the registry
config
+param at publish-time.
+publishConfig
+This is a set of config values that will be used at publish-time. It's
+especially handy if you want to set the tag or registry, so that you can
+ensure that a given package is not tagged with "latest" or published to
+the global public registry by default.
+Any config values can be overridden, but of course only "tag" and
+"registry" probably matter for the purposes of publishing.
+See npm-config(7)
to see the list of config options that can be
+overridden.
+DEFAULT VALUES
+npm will default some values based on package contents.
+
+"scripts": {"start": "node server.js"}
+If there is a server.js
file in the root of your package, then npm
+will default the start
command to node server.js
.
+
+"scripts":{"preinstall": "node-gyp rebuild"}
+If there is a binding.gyp
file in the root of your package, npm will
+default the preinstall
command to compile using node-gyp.
+
+"contributors": [...]
+If there is an AUTHORS
file in the root of your package, npm will
+treat each line as a Name <email> (url)
format, where email and url
+are optional. Lines which start with a #
or are blank, will be
+ignored.
+
+
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/files/npmrc.html nodejs-0.11.15/deps/npm/html/partial/doc/files/npmrc.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/files/npmrc.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/files/npmrc.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,53 @@
+ The npm config files
+DESCRIPTION
+npm gets its config settings from the command line, environment
+variables, and npmrc
files.
+The npm config
command can be used to update and edit the contents
+of the user and global npmrc files.
+For a list of available configuration options, see npm-config(7) .
+FILES
+The four relevant files are:
+
+per-project config file (/path/to/my/project/.npmrc)
+per-user config file (~/.npmrc)
+global config file ($PREFIX/npmrc)
+npm builtin config file (/path/to/npm/npmrc)
+
+All npm config files are an ini-formatted list of key = value
+parameters. Environment variables can be replaced using
+${VARIABLE_NAME}
. For example:
+prefix = ${HOME}/.npm-packages
+
Each of these files is loaded, and config options are resolved in
+priority order. For example, a setting in the userconfig file would
+override the setting in the globalconfig file.
+Per-project config file
+When working locally in a project, a .npmrc
file in the root of the
+project (ie, a sibling of node_modules
and package.json
) will set
+config values specific to this project.
+Note that this only applies to the root of the project that you're
+running npm in. It has no effect when your module is published. For
+example, you can't publish a module that forces itself to install
+globally, or in a different location.
+Per-user config file
+$HOME/.npmrc
(or the userconfig
param, if set in the environment
+or on the command line)
+Global config file
+$PREFIX/etc/npmrc
(or the globalconfig
param, if set above):
+This file is an ini-file formatted list of key = value
parameters.
+Environment variables can be replaced as above.
+Built-in config file
+path/to/npm/itself/npmrc
+This is an unchangeable "builtin" configuration file that npm keeps
+consistent across updates. Set fields in here using the ./configure
+script that comes with npm. This is primarily for distribution
+maintainers to override default configs in a standard and consistent
+manner.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/files/package.json.html nodejs-0.11.15/deps/npm/html/partial/doc/files/package.json.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/files/package.json.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/files/package.json.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,465 @@
+ Specifics of npm's package.json handling
+DESCRIPTION
+This document is all you need to know about what's required in your package.json
+file. It must be actual JSON, not just a JavaScript object literal.
+A lot of the behavior described in this document is affected by the config
+settings described in npm-config(7)
.
+name
+The most important things in your package.json are the name and version fields.
+Those are actually required, and your package won't install without
+them. The name and version together form an identifier that is assumed
+to be completely unique. Changes to the package should come along with
+changes to the version.
+The name is what your thing is called. Some tips:
+
+Don't put "js" or "node" in the name. It's assumed that it's js, since you're
+writing a package.json file, and you can specify the engine using the "engines"
+field. (See below.)
+The name ends up being part of a URL, an argument on the command line, and a
+folder name. Any name with non-url-safe characters will be rejected.
+Also, it can't start with a dot or an underscore.
+The name will probably be passed as an argument to require(), so it should
+be something short, but also reasonably descriptive.
+You may want to check the npm registry to see if there's something by that name
+already, before you get too attached to it. http://registry.npmjs.org/
+
+A name can be optionally prefixed by a scope, e.g. @myorg/mypackage
. See
+npm-scope(7)
for more detail.
+version
+The most important things in your package.json are the name and version fields.
+Those are actually required, and your package won't install without
+them. The name and version together form an identifier that is assumed
+to be completely unique. Changes to the package should come along with
+changes to the version.
+Version must be parseable by
+node-semver , which is bundled
+with npm as a dependency. (npm install semver
to use it yourself.)
+More on version numbers and ranges at semver(7) .
+description
+Put a description in it. It's a string. This helps people discover your
+package, as it's listed in npm search
.
+keywords
+Put keywords in it. It's an array of strings. This helps people
+discover your package as it's listed in npm search
.
+homepage
+The url to the project homepage.
+NOTE : This is not the same as "url". If you put a "url" field,
+then the registry will think it's a redirection to your package that has
+been published somewhere else, and spit at you.
+Literally. Spit. I'm so not kidding.
+bugs
+The url to your project's issue tracker and / or the email address to which
+issues should be reported. These are helpful for people who encounter issues
+with your package.
+It should look like this:
+{ "url" : "http://github.com/owner/project/issues"
+, "email" : "project@hostname.com"
+}
+
You can specify either one or both values. If you want to provide only a url,
+you can specify the value for "bugs" as a simple string instead of an object.
+If a url is provided, it will be used by the npm bugs
command.
+license
+You should specify a license for your package so that people know how they are
+permitted to use it, and any restrictions you're placing on it.
+The simplest way, assuming you're using a common license such as BSD-3-Clause
+or MIT, is to just specify the standard SPDX ID of the license you're using,
+like this:
+{ "license" : "BSD-3-Clause" }
+
You can check the full list of SPDX license IDs .
+Ideally you should pick one that is
+OSI approved.
+It's also a good idea to include a LICENSE file at the top level in
+your package.
+people fields: author, contributors
+The "author" is one person. "contributors" is an array of people. A "person"
+is an object with a "name" field and optionally "url" and "email", like this:
+{ "name" : "Barney Rubble"
+, "email" : "b@rubble.com"
+, "url" : "http://barnyrubble.tumblr.com/"
+}
+
Or you can shorten that all into a single string, and npm will parse it for you:
+"Barney Rubble <b@rubble.com> (http://barnyrubble.tumblr.com/)
+
Both email and url are optional either way.
+npm also sets a top-level "maintainers" field with your npm user info.
+files
+The "files" field is an array of files to include in your project. If
+you name a folder in the array, then it will also include the files
+inside that folder. (Unless they would be ignored by another rule.)
+You can also provide a ".npmignore" file in the root of your package,
+which will keep files from being included, even if they would be picked
+up by the files array. The ".npmignore" file works just like a
+".gitignore".
+main
+The main field is a module ID that is the primary entry point to your program.
+That is, if your package is named foo
, and a user installs it, and then does
+require("foo")
, then your main module's exports object will be returned.
+This should be a module ID relative to the root of your package folder.
+For most modules, it makes the most sense to have a main script and often not
+much else.
+bin
+A lot of packages have one or more executable files that they'd like to
+install into the PATH. npm makes this pretty easy (in fact, it uses this
+feature to install the "npm" executable.)
+To use this, supply a bin
field in your package.json which is a map of
+command name to local file name. On install, npm will symlink that file into
+prefix/bin
for global installs, or ./node_modules/.bin/
for local
+installs.
+For example, npm has this:
+{ "bin" : { "npm" : "./cli.js" } }
+
So, when you install npm, it'll create a symlink from the cli.js
script to
+/usr/local/bin/npm
.
+If you have a single executable, and its name should be the name
+of the package, then you can just supply it as a string. For example:
+{ "name": "my-program"
+, "version": "1.2.5"
+, "bin": "./path/to/program" }
+
would be the same as this:
+{ "name": "my-program"
+, "version": "1.2.5"
+, "bin" : { "my-program" : "./path/to/program" } }
+
man
+Specify either a single file or an array of filenames to put in place for the
+man
program to find.
+If only a single file is provided, then it's installed such that it is the
+result from man <pkgname>
, regardless of its actual filename. For example:
+{ "name" : "foo"
+, "version" : "1.2.3"
+, "description" : "A packaged foo fooer for fooing foos"
+, "main" : "foo.js"
+, "man" : "./man/doc.1"
+}
+
would link the ./man/doc.1
file in such that it is the target for man foo
+If the filename doesn't start with the package name, then it's prefixed.
+So, this:
+{ "name" : "foo"
+, "version" : "1.2.3"
+, "description" : "A packaged foo fooer for fooing foos"
+, "main" : "foo.js"
+, "man" : [ "./man/foo.1", "./man/bar.1" ]
+}
+
will create files to do man foo
and man foo-bar
.
+Man files must end with a number, and optionally a .gz
suffix if they are
+compressed. The number dictates which man section the file is installed into.
+{ "name" : "foo"
+, "version" : "1.2.3"
+, "description" : "A packaged foo fooer for fooing foos"
+, "main" : "foo.js"
+, "man" : [ "./man/foo.1", "./man/foo.2" ]
+}
+
will create entries for man foo
and man 2 foo
+directories
+The CommonJS Packages spec details a
+few ways that you can indicate the structure of your package using a directories
+object. If you look at npm's package.json ,
+you'll see that it has directories for doc, lib, and man.
+In the future, this information may be used in other creative ways.
+directories.lib
+Tell people where the bulk of your library is. Nothing special is done
+with the lib folder in any way, but it's useful meta info.
+directories.bin
+If you specify a bin
directory, then all the files in that folder will
+be added as children of the bin
path.
+If you have a bin
path already, then this has no effect.
+directories.man
+A folder that is full of man pages. Sugar to generate a "man" array by
+walking the folder.
+directories.doc
+Put markdown files in here. Eventually, these will be displayed nicely,
+maybe, someday.
+directories.example
+Put example scripts in here. Someday, it might be exposed in some clever way.
+repository
+Specify the place where your code lives. This is helpful for people who
+want to contribute. If the git repo is on github, then the npm docs
+command will be able to find you.
+Do it like this:
+"repository" :
+ { "type" : "git"
+ , "url" : "http://github.com/npm/npm.git"
+ }
+
+"repository" :
+ { "type" : "svn"
+ , "url" : "http://v8.googlecode.com/svn/trunk/"
+ }
+
The URL should be a publicly available (perhaps read-only) url that can be handed
+directly to a VCS program without any modification. It should not be a url to an
+html project page that you put in your browser. It's for computers.
+scripts
+The "scripts" property is a dictionary containing script commands that are run
+at various times in the lifecycle of your package. The key is the lifecycle
+event, and the value is the command to run at that point.
+See npm-scripts(7)
to find out more about writing package scripts.
+config
+A "config" object can be used to set configuration parameters used in package
+scripts that persist across upgrades. For instance, if a package had the
+following:
+{ "name" : "foo"
+, "config" : { "port" : "8080" } }
+
and then had a "start" command that then referenced the
+npm_package_config_port
environment variable, then the user could
+override that by doing npm config set foo:port 8001
.
+See npm-config(7)
and npm-scripts(7)
for more on package
+configs.
+dependencies
+Dependencies are specified in a simple object that maps a package name to a
+version range. The version range is a string which has one or more
+space-separated descriptors. Dependencies can also be identified with a
+tarball or git URL.
+Please do not put test harnesses or transpilers in your
+dependencies
object. See devDependencies
, below.
+See semver(7) for more details about specifying version ranges.
+
+version
Must match version
exactly
+>version
Must be greater than version
+>=version
etc
+<version
+<=version
+~version
"Approximately equivalent to version" See semver(7)
+^version
"Compatible with version" See semver(7)
+1.2.x
1.2.0, 1.2.1, etc., but not 1.3.0
+http://...
See 'URLs as Dependencies' below
+*
Matches any version
+""
(just an empty string) Same as *
+version1 - version2
Same as >=version1 <=version2
.
+range1 || range2
Passes if either range1 or range2 are satisfied.
+git...
See 'Git URLs as Dependencies' below
+user/repo
See 'GitHub URLs' below
+tag
A specific version tagged and published as tag
See npm-tag(1)
+path/path/path
See Local Paths below
+
+For example, these are all valid:
+{ "dependencies" :
+ { "foo" : "1.0.0 - 2.9999.9999"
+ , "bar" : ">=1.0.2 <2.1.2"
+ , "baz" : ">1.0.2 <=2.3.4"
+ , "boo" : "2.0.1"
+ , "qux" : "<1.0.0 || >=2.3.1 <2.4.5 || >=2.5.2 <3.0.0"
+ , "asd" : "http://asdf.com/asdf.tar.gz"
+ , "til" : "~1.2"
+ , "elf" : "~1.2.3"
+ , "two" : "2.x"
+ , "thr" : "3.3.x"
+ , "lat" : "latest"
+ , "dyl" : "file:../dyl"
+ }
+}
+
URLs as Dependencies
+You may specify a tarball URL in place of a version range.
+This tarball will be downloaded and installed locally to your package at
+install time.
+Git URLs as Dependencies
+Git urls can be of the form:
+git://github.com/user/project.git#commit-ish
+git+ssh://user@hostname:project.git#commit-ish
+git+ssh://user@hostname/project.git#commit-ish
+git+http://user@hostname/project/blah.git#commit-ish
+git+https://user@hostname/project/blah.git#commit-ish
+
The commit-ish
can be any tag, sha, or branch which can be supplied as
+an argument to git checkout
. The default is master
.
+GitHub URLs
+As of version 1.1.65, you can refer to GitHub urls as just "foo": "user/foo-project". For example:
+{
+ "name": "foo",
+ "version": "0.0.0",
+ "dependencies": {
+ "express": "visionmedia/express"
+ }
+}
+
Local Paths
+As of version 2.0.0 you can provide a path to a local directory that contains a
+package. Local paths can be saved using npm install --save
, using any of
+these forms:
+../foo/bar
+~/foo/bar
+./foo/bar
+/foo/bar
+
in which case they will be normalized to a relative path and added to your
+package.json
. For example:
+{
+ "name": "baz",
+ "dependencies": {
+ "bar": "file:../foo/bar"
+ }
+}
+
This feature is helpful for local offline development and creating
+tests that require npm installing where you don't want to hit an
+external server, but should not be used when publishing packages
+to the public registry.
+devDependencies
+If someone is planning on downloading and using your module in their
+program, then they probably don't want or need to download and build
+the external test or documentation framework that you use.
+In this case, it's best to map these additional items in a devDependencies
+object.
+These things will be installed when doing npm link
or npm install
+from the root of a package, and can be managed like any other npm
+configuration param. See npm-config(7)
for more on the topic.
+For build steps that are not platform-specific, such as compiling
+CoffeeScript or other languages to JavaScript, use the prepublish
+script to do this, and make the required package a devDependency.
+For example:
+{ "name": "ethopia-waza",
+ "description": "a delightfully fruity coffee varietal",
+ "version": "1.2.3",
+ "devDependencies": {
+ "coffee-script": "~1.6.3"
+ },
+ "scripts": {
+ "prepublish": "coffee -o lib/ -c src/waza.coffee"
+ },
+ "main": "lib/waza.js"
+}
+
The prepublish
script will be run before publishing, so that users
+can consume the functionality without requiring them to compile it
+themselves. In dev mode (ie, locally running npm install
), it'll
+run this script as well, so that you can test it easily.
+peerDependencies
+In some cases, you want to express the compatibility of your package with an
+host tool or library, while not necessarily doing a require
of this host.
+This is usually refered to as a plugin . Notably, your module may be exposing
+a specific interface, expected and specified by the host documentation.
+For example:
+{
+ "name": "tea-latte",
+ "version": "1.3.5"
+ "peerDependencies": {
+ "tea": "2.x"
+ }
+}
+
This ensures your package tea-latte
can be installed along with the second
+major version of the host package tea
only. The host package is automatically
+installed if needed. npm install tea-latte
could possibly yield the following
+dependency graph:
+├── tea-latte@1.3.5
+└── tea@2.2.0
+
Trying to install another plugin with a conflicting requirement will cause an
+error. For this reason, make sure your plugin requirement is as broad as
+possible, and not to lock it down to specific patch versions.
+Assuming the host complies with semver , only changes in
+the host package's major version will break your plugin. Thus, if you've worked
+with every 1.x version of the host package, use "^1.0"
or "1.x"
to express
+this. If you depend on features introduced in 1.5.2, use ">= 1.5.2 < 2"
.
+bundledDependencies
+Array of package names that will be bundled when publishing the package.
+If this is spelled "bundleDependencies"
, then that is also honorable.
+optionalDependencies
+If a dependency can be used, but you would like npm to proceed if it cannot be
+found or fails to install, then you may put it in the optionalDependencies
+object. This is a map of package name to version or url, just like the
+dependencies
object. The difference is that build failures do not cause
+installation to fail.
+It is still your program's responsibility to handle the lack of the
+dependency. For example, something like this:
+try {
+ var foo = require('foo')
+ var fooVersion = require('foo/package.json').version
+} catch (er) {
+ foo = null
+}
+if ( notGoodFooVersion(fooVersion) ) {
+ foo = null
+}
+
+// .. then later in your program ..
+
+if (foo) {
+ foo.doFooThings()
+}
+
Entries in optionalDependencies
will override entries of the same name in
+dependencies
, so it's usually best to only put in one place.
+engines
+You can specify the version of node that your stuff works on:
+{ "engines" : { "node" : ">=0.10.3 <0.12" } }
+
And, like with dependencies, if you don't specify the version (or if you
+specify "*" as the version), then any version of node will do.
+If you specify an "engines" field, then npm will require that "node" be
+somewhere on that list. If "engines" is omitted, then npm will just assume
+that it works on node.
+You can also use the "engines" field to specify which versions of npm
+are capable of properly installing your program. For example:
+{ "engines" : { "npm" : "~1.0.20" } }
+
Note that, unless the user has set the engine-strict
config flag, this
+field is advisory only.
+engineStrict
+If you are sure that your module will definitely not run properly on
+versions of Node/npm other than those specified in the engines
object,
+then you can set "engineStrict": true
in your package.json file.
+This will override the user's engine-strict
config setting.
+Please do not do this unless you are really very very sure. If your
+engines object is something overly restrictive, you can quite easily and
+inadvertently lock yourself into obscurity and prevent your users from
+updating to new versions of Node. Consider this choice carefully. If
+people abuse it, it will be removed in a future version of npm.
+os
+You can specify which operating systems your
+module will run on:
+"os" : [ "darwin", "linux" ]
+
You can also blacklist instead of whitelist operating systems,
+just prepend the blacklisted os with a '!':
+"os" : [ "!win32" ]
+
The host operating system is determined by process.platform
+It is allowed to both blacklist, and whitelist, although there isn't any
+good reason to do this.
+cpu
+If your code only runs on certain cpu architectures,
+you can specify which ones.
+"cpu" : [ "x64", "ia32" ]
+
Like the os
option, you can also blacklist architectures:
+"cpu" : [ "!arm", "!mips" ]
+
The host architecture is determined by process.arch
+preferGlobal
+If your package is primarily a command-line application that should be
+installed globally, then set this value to true
to provide a warning
+if it is installed locally.
+It doesn't actually prevent users from installing it locally, but it
+does help prevent some confusion if it doesn't work as expected.
+private
+If you set "private": true
in your package.json, then npm will refuse
+to publish it.
+This is a way to prevent accidental publication of private repositories. If
+you would like to ensure that a given package is only ever published to a
+specific registry (for example, an internal registry), then use the
+publishConfig
dictionary described below to override the registry
config
+param at publish-time.
+publishConfig
+This is a set of config values that will be used at publish-time. It's
+especially handy if you want to set the tag or registry, so that you can
+ensure that a given package is not tagged with "latest" or published to
+the global public registry by default.
+Any config values can be overridden, but of course only "tag" and
+"registry" probably matter for the purposes of publishing.
+See npm-config(7)
to see the list of config options that can be
+overridden.
+DEFAULT VALUES
+npm will default some values based on package contents.
+
+"scripts": {"start": "node server.js"}
+If there is a server.js
file in the root of your package, then npm
+will default the start
command to node server.js
.
+
+"scripts":{"preinstall": "node-gyp rebuild"}
+If there is a binding.gyp
file in the root of your package, npm will
+default the preinstall
command to compile using node-gyp.
+
+"contributors": [...]
+If there is an AUTHORS
file in the root of your package, npm will
+treat each line as a Name <email> (url)
format, where email and url
+are optional. Lines which start with a #
or are blank, will be
+ignored.
+
+
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/index.html nodejs-0.11.15/deps/npm/html/partial/doc/index.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/index.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/index.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,210 @@
+ Index of all npm documentation
+
+node package manager
+Command Line Documentation
+Using npm on the command line
+
+node package manager
+
+Add a registry user account
+
+Display npm bin folder
+
+Bugs for a package in a web browser maybe
+
+Build a package
+
+REMOVED
+
+Manipulates packages cache
+
+Tab Completion for npm
+
+Manage the npm configuration files
+
+Reduce duplication
+
+Deprecate a version of a package
+
+Docs for a package in a web browser maybe
+
+Edit an installed package
+
+Browse an installed package
+
+Search npm help documentation
+
+Get help on npm
+
+Interactively create a package.json file
+
+Install a package
+
+Symlink a package folder
+
+List installed packages
+
+Check for outdated packages
+
+Manage package owners
+
+Create a tarball from a package
+
+Display prefix
+
+Remove extraneous packages
+
+Publish a package
+
+Rebuild a package
+
+Open package repository page in the browser
+
+Start a package
+
+Remove a package
+
+Display npm root
+
+Run arbitrary package scripts
+
+Search for packages
+
+Lock down dependency versions
+
+Mark your favorite packages
+
+View packages marked as favorites
+
+Start a package
+
+Stop a package
+
+Tag a published version
+
+Test a package
+
+Remove a package
+
+Remove a package from the registry
+
+Update a package
+
+Bump a package version
+
+View registry info
+
+Display npm username
+API Documentation
+Using npm in your Node programs
+
+node package manager
+
+Display npm bin folder
+
+Bugs for a package in a web browser maybe
+
+manage the npm cache programmatically
+
+npm commands
+
+Manage the npm configuration files
+
+Deprecate a version of a package
+
+Docs for a package in a web browser maybe
+
+Edit an installed package
+
+Browse an installed package
+
+Search the help pages
+
+Interactively create a package.json file
+
+install a package programmatically
+
+Symlink a package folder
+
+Load config settings
+
+List installed packages
+
+Check for outdated packages
+
+Manage package owners
+
+Create a tarball from a package
+
+Display prefix
+
+Remove extraneous packages
+
+Publish a package
+
+Rebuild a package
+
+Open package repository page in the browser
+
+Start a package
+
+Display npm root
+
+Run arbitrary package scripts
+
+Search for packages
+
+programmatically generate package shrinkwrap file
+
+Start a package
+
+Stop a package
+
+Tag a published version
+
+Test a package
+
+uninstall a package programmatically
+
+Remove a package from the registry
+
+Update a package
+
+Bump a package version
+
+View registry info
+
+Display npm username
+Files
+File system structures npm uses
+
+Folder Structures Used by npm
+
+The npm config files
+
+Specifics of npm's package.json handling
+Misc
+Various other bits and bobs
+
+npm's "funny" coding style
+
+More than you probably want to know about npm configuration
+
+Developer Guide
+
+Handling Module Name Disputes
+
+Frequently Asked Questions
+
+Index of all npm documentation
+
+The JavaScript Package Registry
+
+Scoped packages
+
+How npm handles the "scripts" field
+
+Cleaning the Slate
+
+The semantic versioner for npm
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/misc/npm-coding-style.html nodejs-0.11.15/deps/npm/html/partial/doc/misc/npm-coding-style.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/misc/npm-coding-style.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/misc/npm-coding-style.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,127 @@
+ npm's "funny" coding style
+DESCRIPTION
+npm's coding style is a bit unconventional. It is not different for
+difference's sake, but rather a carefully crafted style that is
+designed to reduce visual clutter and make bugs more apparent.
+If you want to contribute to npm (which is very encouraged), you should
+make your code conform to npm's style.
+Note: this concerns npm's code not the specific packages at npmjs.org
+Line Length
+Keep lines shorter than 80 characters. It's better for lines to be
+too short than to be too long. Break up long lists, objects, and other
+statements onto multiple lines.
+Indentation
+Two-spaces. Tabs are better, but they look like hell in web browsers
+(and on github), and node uses 2 spaces, so that's that.
+Configure your editor appropriately.
+Curly braces
+Curly braces belong on the same line as the thing that necessitates them.
+Bad:
+function ()
+{
+
Good:
+function () {
+
If a block needs to wrap to the next line, use a curly brace. Don't
+use it if it doesn't.
+Bad:
+if (foo) { bar() }
+while (foo)
+ bar()
+
Good:
+if (foo) bar()
+while (foo) {
+ bar()
+}
+
Semicolons
+Don't use them except in four situations:
+
+for (;;)
loops. They're actually required.
+null loops like: while (something) ;
(But you'd better have a good
+reason for doing that.)
+case "foo": doSomething(); break
+In front of a leading (
or [
at the start of the line.
+This prevents the expression from being interpreted
+as a function call or property access, respectively.
+
+Some examples of good semicolon usage:
+;(x || y).doSomething()
+;[a, b, c].forEach(doSomething)
+for (var i = 0; i < 10; i ++) {
+ switch (state) {
+ case "begin": start(); continue
+ case "end": finish(); break
+ default: throw new Error("unknown state")
+ }
+ end()
+}
+
Note that starting lines with -
and +
also should be prefixed
+with a semicolon, but this is much less common.
+Comma First
+If there is a list of things separated by commas, and it wraps
+across multiple lines, put the comma at the start of the next
+line, directly below the token that starts the list. Put the
+final token in the list on a line by itself. For example:
+var magicWords = [ "abracadabra"
+ , "gesundheit"
+ , "ventrilo"
+ ]
+ , spells = { "fireball" : function () { setOnFire() }
+ , "water" : function () { putOut() }
+ }
+ , a = 1
+ , b = "abc"
+ , etc
+ , somethingElse
+
Whitespace
+Put a single space in front of ( for anything other than a function call.
+Also use a single space wherever it makes things more readable.
+Don't leave trailing whitespace at the end of lines. Don't indent empty
+lines. Don't use more spaces than are helpful.
+Functions
+Use named functions. They make stack traces a lot easier to read.
+Callbacks, Sync/async Style
+Use the asynchronous/non-blocking versions of things as much as possible.
+It might make more sense for npm to use the synchronous fs APIs, but this
+way, the fs and http and child process stuff all uses the same callback-passing
+methodology.
+The callback should always be the last argument in the list. Its first
+argument is the Error or null.
+Be very careful never to ever ever throw anything. It's worse than useless.
+Just send the error message back as the first argument to the callback.
+Errors
+Always create a new Error object with your message. Don't just return a
+string message to the callback. Stack traces are handy.
+Logging
+Logging is done using the npmlog
+utility.
+Please clean up logs when they are no longer helpful. In particular,
+logging the same object over and over again is not helpful. Logs should
+report what's happening so that it's easier to track down where a fault
+occurs.
+Use appropriate log levels. See npm-config(7)
and search for
+"loglevel".
+Case, naming, etc.
+Use lowerCamelCase
for multiword identifiers when they refer to objects,
+functions, methods, properties, or anything not specified in this section.
+Use UpperCamelCase
for class names (things that you'd pass to "new").
+Use all-lower-hyphen-css-case
for multiword filenames and config keys.
+Use named functions. They make stack traces easier to follow.
+Use CAPS_SNAKE_CASE
for constants, things that should never change
+and are rarely used.
+Use a single uppercase letter for function names where the function
+would normally be anonymous, but needs to call itself recursively. It
+makes it clear that it's a "throwaway" function.
+null, undefined, false, 0
+Boolean variables and functions should always be either true
or
+false
. Don't set it to 0 unless it's supposed to be a number.
+When something is intentionally missing or removed, set it to null
.
+Don't set things to undefined
. Reserve that value to mean "not yet
+set to anything."
+Boolean objects are verboten.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/misc/npm-config.html nodejs-0.11.15/deps/npm/html/partial/doc/misc/npm-config.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/misc/npm-config.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/misc/npm-config.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,739 @@
+ More than you probably want to know about npm configuration
+DESCRIPTION
+npm gets its configuration values from 6 sources, in this priority:
+Command Line Flags
+Putting --foo bar
on the command line sets the foo
configuration
+parameter to "bar"
. A --
argument tells the cli parser to stop
+reading flags. A --flag
parameter that is at the end of the
+command will be given the value of true
.
+Environment Variables
+Any environment variables that start with npm_config_
will be
+interpreted as a configuration parameter. For example, putting
+npm_config_foo=bar
in your environment will set the foo
+configuration parameter to bar
. Any environment configurations that
+are not given a value will be given the value of true
. Config
+values are case-insensitive, so NPM_CONFIG_FOO=bar
will work the
+same.
+npmrc Files
+The four relevant files are:
+
+per-project config file (/path/to/my/project/.npmrc)
+per-user config file (~/.npmrc)
+global config file ($PREFIX/npmrc)
+npm builtin config file (/path/to/npm/npmrc)
+
+See npmrc(5) for more details.
+Default Configs
+A set of configuration parameters that are internal to npm, and are
+defaults if nothing else is specified.
+Shorthands and Other CLI Niceties
+The following shorthands are parsed on the command-line:
+
+-v
: --version
+-h
, -?
, --help
, -H
: --usage
+-s
, --silent
: --loglevel silent
+-q
, --quiet
: --loglevel warn
+-d
: --loglevel info
+-dd
, --verbose
: --loglevel verbose
+-ddd
: --loglevel silly
+-g
: --global
+-C
: --prefix
+-l
: --long
+-m
: --message
+-p
, --porcelain
: --parseable
+-reg
: --registry
+-v
: --version
+-f
: --force
+-desc
: --description
+-S
: --save
+-D
: --save-dev
+-O
: --save-optional
+-B
: --save-bundle
+-E
: --save-exact
+-y
: --yes
+-n
: --yes false
+ll
and la
commands: ls --long
+
+If the specified configuration param resolves unambiguously to a known
+configuration parameter, then it is expanded to that configuration
+parameter. For example:
+npm ls --par
+# same as:
+npm ls --parseable
+
If multiple single-character shorthands are strung together, and the
+resulting combination is unambiguously not some other configuration
+param, then it is expanded to its various component pieces. For
+example:
+npm ls -gpld
+# same as:
+npm ls --global --parseable --long --loglevel info
+
Per-Package Config Settings
+When running scripts (see npm-scripts(7)
) the package.json "config"
+keys are overwritten in the environment if there is a config param of
+<name>[@<version>]:<key>
. For example, if the package.json has
+this:
+{ "name" : "foo"
+, "config" : { "port" : "8080" }
+, "scripts" : { "start" : "node server.js" } }
+
and the server.js is this:
+http.createServer(...).listen(process.env.npm_package_config_port)
+
then the user could change the behavior by doing:
+npm config set foo:port 80
+
See package.json(5) for more information.
+Config Settings
+always-auth
+
+Default: false
+Type: Boolean
+
+Force npm to always require authentication when accessing the registry,
+even for GET
requests.
+bin-links
+
+Default: true
+Type: Boolean
+
+Tells npm to create symlinks (or .cmd
shims on Windows) for package
+executables.
+Set to false to have it not do this. This can be used to work around
+the fact that some file systems don't support symlinks, even on
+ostensibly Unix systems.
+browser
+
+Default: OS X: "open"
, Windows: "start"
, Others: "xdg-open"
+Type: String
+
+The browser that is called by the npm docs
command to open websites.
+ca
+
+Default: The npm CA certificate
+Type: String or null
+
+The Certificate Authority signing certificate that is trusted for SSL
+connections to the registry.
+Set to null
to only allow "known" registrars, or to a specific CA cert
+to trust only that specific signing authority.
+See also the strict-ssl
config.
+cafile
+
+Default: null
+Type: path
+
+A path to a file containing one or multiple Certificate Authority signing
+certificates. Similar to the ca
setting, but allows for multiple CA's, as
+well as for the CA information to be stored in a file on disk.
+cache
+
+Default: Windows: %AppData%\npm-cache
, Posix: ~/.npm
+Type: path
+
+The location of npm's cache directory. See npm-cache(1)
+cache-lock-stale
+
+Default: 60000 (1 minute)
+Type: Number
+
+The number of ms before cache folder lockfiles are considered stale.
+cache-lock-retries
+
+Default: 10
+Type: Number
+
+Number of times to retry to acquire a lock on cache folder lockfiles.
+cache-lock-wait
+
+Default: 10000 (10 seconds)
+Type: Number
+
+Number of ms to wait for cache lock files to expire.
+cache-max
+
+Default: Infinity
+Type: Number
+
+The maximum time (in seconds) to keep items in the registry cache before
+re-checking against the registry.
+Note that no purging is done unless the npm cache clean
command is
+explicitly used, and that only GET requests use the cache.
+cache-min
+
+Default: 10
+Type: Number
+
+The minimum time (in seconds) to keep items in the registry cache before
+re-checking against the registry.
+Note that no purging is done unless the npm cache clean
command is
+explicitly used, and that only GET requests use the cache.
+cert
+
+Default: null
+Type: String
+
+A client certificate to pass when accessing the registry.
+color
+
+Default: true on Posix, false on Windows
+Type: Boolean or "always"
+
+If false, never shows colors. If "always"
then always shows colors.
+If true, then only prints color codes for tty file descriptors.
+depth
+
+Default: Infinity
+Type: Number
+
+The depth to go when recursing directories for npm ls
and
+npm cache ls
.
+description
+
+Default: true
+Type: Boolean
+
+Show the description in npm search
+dev
+
+Default: false
+Type: Boolean
+
+Install dev-dependencies
along with packages.
+Note that dev-dependencies
are also installed if the npat
flag is
+set.
+editor
+
+Default: EDITOR
environment variable if set, or "vi"
on Posix,
+or "notepad"
on Windows.
+Type: path
+
+The command to run for npm edit
or npm config edit
.
+engine-strict
+
+Default: false
+Type: Boolean
+
+If set to true, then npm will stubbornly refuse to install (or even
+consider installing) any package that claims to not be compatible with
+the current Node.js version.
+force
+
+Default: false
+Type: Boolean
+
+Makes various commands more forceful.
+
+lifecycle script failure does not block progress.
+publishing clobbers previously published versions.
+skips cache when requesting from the registry.
+prevents checks against clobbering non-npm files.
+
+fetch-retries
+
+Default: 2
+Type: Number
+
+The "retries" config for the retry
module to use when fetching
+packages from the registry.
+fetch-retry-factor
+
+Default: 10
+Type: Number
+
+The "factor" config for the retry
module to use when fetching
+packages.
+fetch-retry-mintimeout
+
+Default: 10000 (10 seconds)
+Type: Number
+
+The "minTimeout" config for the retry
module to use when fetching
+packages.
+fetch-retry-maxtimeout
+
+Default: 60000 (1 minute)
+Type: Number
+
+The "maxTimeout" config for the retry
module to use when fetching
+packages.
+git
+
+Default: "git"
+Type: String
+
+The command to use for git commands. If git is installed on the
+computer, but is not in the PATH
, then set this to the full path to
+the git binary.
+git-tag-version
+
+Default: true
+Type: Boolean
+
+Tag the commit when using the npm version
command.
+global
+
+Default: false
+Type: Boolean
+
+Operates in "global" mode, so that packages are installed into the
+prefix
folder instead of the current working directory. See
+npm-folders(5)
for more on the differences in behavior.
+
+packages are installed into the {prefix}/lib/node_modules
folder, instead of the
+current working directory.
+bin files are linked to {prefix}/bin
+man pages are linked to {prefix}/share/man
+
+globalconfig
+
+Default: {prefix}/etc/npmrc
+Type: path
+
+The config file to read for global config options.
+group
+
+Default: GID of the current process
+Type: String or Number
+
+The group to use when running package scripts in global mode as the root
+user.
+heading
+
+Default: "npm"
+Type: String
+
+The string that starts all the debugging log output.
+https-proxy
+
+Default: the HTTPS_PROXY
or https_proxy
or HTTP_PROXY
or
+http_proxy
environment variables.
+Type: url
+
+A proxy to use for outgoing https requests.
+ignore-scripts
+
+Default: false
+Type: Boolean
+
+If true, npm does not run scripts specified in package.json files.
+init-module
+
+Default: ~/.npm-init.js
+Type: path
+
+A module that will be loaded by the npm init
command. See the
+documentation for the
+init-package-json module
+for more information, or npm-init(1) .
+init-author-name
+
+Default: ""
+Type: String
+
+The value npm init
should use by default for the package author's name.
+init-author-email
+
+Default: ""
+Type: String
+
+The value npm init
should use by default for the package author's email.
+init-author-url
+
+Default: ""
+Type: String
+
+The value npm init
should use by default for the package author's homepage.
+init-license
+
+Default: "ISC"
+Type: String
+
+The value npm init
should use by default for the package license.
+init-version
+
+Default: "0.0.0"
+Type: semver
+
+The value that npm init
should use by default for the package
+version number, if not already set in package.json.
+json
+
+Default: false
+Type: Boolean
+
+Whether or not to output JSON data, rather than the normal output.
+This feature is currently experimental, and the output data structures
+for many commands is either not implemented in JSON yet, or subject to
+change. Only the output from npm ls --json
is currently valid.
+key
+
+Default: null
+Type: String
+
+A client key to pass when accessing the registry.
+link
+
+Default: false
+Type: Boolean
+
+If true, then local installs will link if there is a suitable globally
+installed package.
+Note that this means that local installs can cause things to be
+installed into the global space at the same time. The link is only done
+if one of the two conditions are met:
+
+The package is not already installed globally, or
+the globally installed version is identical to the version that is
+being installed locally.
+
+local-address
+
+Default: undefined
+Type: IP Address
+
+The IP address of the local interface to use when making connections
+to the npm registry. Must be IPv4 in versions of Node prior to 0.12.
+loglevel
+
+Default: "warn"
+Type: String
+Values: "silent", "error", "warn", "http", "info", "verbose", "silly"
+
+What level of logs to report. On failure, all logs are written to
+npm-debug.log
in the current working directory.
+Any logs of a higher level than the setting are shown.
+The default is "warn", which shows warn and error output.
+logstream
+
+Default: process.stderr
+Type: Stream
+
+This is the stream that is passed to the
+npmlog module at run time.
+It cannot be set from the command line, but if you are using npm
+programmatically, you may wish to send logs to somewhere other than
+stderr.
+If the color
config is set to true, then this stream will receive
+colored output if it is a TTY.
+long
+
+Default: false
+Type: Boolean
+
+Show extended information in npm ls
and npm search
.
+message
+
+Default: "%s"
+Type: String
+
+Commit message which is used by npm version
when creating version commit.
+Any "%s" in the message will be replaced with the version number.
+node-version
+
+Default: process.version
+Type: semver or false
+
+The node version to use when checking a package's engines
map.
+npat
+
+Default: false
+Type: Boolean
+
+Run tests on installation.
+onload-script
+
+Default: false
+Type: path
+
+A node module to require()
when npm loads. Useful for programmatic
+usage.
+optional
+
+Default: true
+Type: Boolean
+
+Attempt to install packages in the optionalDependencies
object. Note
+that if these packages fail to install, the overall installation
+process is not aborted.
+parseable
+
+Default: false
+Type: Boolean
+
+Output parseable results from commands that write to
+standard output.
+prefix
+
+The location to install global items. If set on the command line, then
+it forces non-global commands to run in the specified folder.
+production
+
+Default: false
+Type: Boolean
+
+Set to true to run in "production" mode.
+
+devDependencies are not installed at the topmost level when running
+local npm install
without any arguments.
+Set the NODE_ENV="production" for lifecycle scripts.
+
+proprietary-attribs
+
+Default: true
+Type: Boolean
+
+Whether or not to include proprietary extended attributes in the
+tarballs created by npm.
+Unless you are expecting to unpack package tarballs with something other
+than npm -- particularly a very outdated tar implementation -- leave
+this as true.
+proxy
+
+Default: HTTP_PROXY
or http_proxy
environment variable, or null
+Type: url
+
+A proxy to use for outgoing http requests.
+rebuild-bundle
+
+Default: true
+Type: Boolean
+
+Rebuild bundled dependencies after installation.
+registry
+
+The base URL of the npm package registry.
+rollback
+
+Default: true
+Type: Boolean
+
+Remove failed installs.
+save
+
+Default: false
+Type: Boolean
+
+Save installed packages to a package.json file as dependencies.
+When used with the npm rm
command, it removes it from the dependencies
+object.
+Only works if there is already a package.json file present.
+save-bundle
+
+Default: false
+Type: Boolean
+
+If a package would be saved at install time by the use of --save
,
+--save-dev
, or --save-optional
, then also put it in the
+bundleDependencies
list.
+When used with the npm rm
command, it removes it from the
+bundledDependencies list.
+save-dev
+
+Default: false
+Type: Boolean
+
+Save installed packages to a package.json file as devDependencies
.
+When used with the npm rm
command, it removes it from the
+devDependencies
object.
+Only works if there is already a package.json file present.
+save-exact
+
+Default: false
+Type: Boolean
+
+Dependencies saved to package.json using --save
, --save-dev
or
+--save-optional
will be configured with an exact version rather than
+using npm's default semver range operator.
+save-optional
+
+Default: false
+Type: Boolean
+
+Save installed packages to a package.json file as
+optionalDependencies.
+When used with the npm rm
command, it removes it from the
+devDependencies
object.
+Only works if there is already a package.json file present.
+save-prefix
+
+Default: '^'
+Type: String
+
+Configure how versions of packages installed to a package.json file via
+--save
or --save-dev
get prefixed.
+For example if a package has version 1.2.3
, by default it's version is
+set to ^1.2.3
which allows minor upgrades for that package, but after
+npm config set save-prefix='~'
it would be set to ~1.2.3
which only allows
+patch upgrades.
+scope
+
+Default: ""
+Type: String
+
+Associate an operation with a scope for a scoped registry. Useful when logging
+in to a private registry for the first time:
+npm login --scope=@organization --registry=registry.organization.com
, which
+will cause @organization
to be mapped to the registry for future installation
+of packages specified according to the pattern @organization/package
.
+searchopts
+
+Default: ""
+Type: String
+
+Space-separated options that are always passed to search.
+searchexclude
+
+Default: ""
+Type: String
+
+Space-separated options that limit the results from search.
+searchsort
+
+Default: "name"
+Type: String
+Values: "name", "-name", "date", "-date", "description",
+"-description", "keywords", "-keywords"
+
+Indication of which field to sort search results by. Prefix with a -
+character to indicate reverse sort.
+shell
+
+Default: SHELL environment variable, or "bash" on Posix, or "cmd" on
+Windows
+Type: path
+
+The shell to run for the npm explore
command.
+shrinkwrap
+
+Default: true
+Type: Boolean
+
+If set to false, then ignore npm-shrinkwrap.json
files when
+installing.
+sign-git-tag
+
+Default: false
+Type: Boolean
+
+If set to true, then the npm version
command will tag the version
+using -s
to add a signature.
+Note that git requires you to have set up GPG keys in your git configs
+for this to work properly.
+spin
+
+Default: true
+Type: Boolean or "always"
+
+When set to true
, npm will display an ascii spinner while it is doing
+things, if process.stderr
is a TTY.
+Set to false
to suppress the spinner, or set to always
to output
+the spinner even for non-TTY outputs.
+strict-ssl
+
+Default: true
+Type: Boolean
+
+Whether or not to do SSL key validation when making requests to the
+registry via https.
+See also the ca
config.
+tag
+
+Default: latest
+Type: String
+
+If you ask npm to install a package and don't tell it a specific version, then
+it will install the specified tag.
+Also the tag that is added to the package@version specified by the npm
+tag
command, if no explicit tag is given.
+tmp
+
+Default: TMPDIR environment variable, or "/tmp"
+Type: path
+
+Where to store temporary files and folders. All temp files are deleted
+on success, but left behind on failure for forensic purposes.
+unicode
+
+Default: true
+Type: Boolean
+
+When set to true, npm uses unicode characters in the tree output. When
+false, it uses ascii characters to draw trees.
+unsafe-perm
+
+Default: false if running as root, true otherwise
+Type: Boolean
+
+Set to true to suppress the UID/GID switching when running package
+scripts. If set explicitly to false, then installing as a non-root user
+will fail.
+usage
+
+Default: false
+Type: Boolean
+
+Set to show short usage output (like the -H output)
+instead of complete help when doing npm-help(1)
.
+user
+
+Default: "nobody"
+Type: String or Number
+
+The UID to set to when running package scripts as root.
+userconfig
+
+Default: ~/.npmrc
+Type: path
+
+The location of user-level configuration settings.
+umask
+
+Default: 022
+Type: Octal numeric string
+
+The "umask" value to use when setting the file creation mode on files
+and folders.
+Folders and executables are given a mode which is 0777
masked against
+this value. Other files are given a mode which is 0666
masked against
+this value. Thus, the defaults are 0755
and 0644
respectively.
+user-agent
+
+Default: node/{process.version} {process.platform} {process.arch}
+Type: String
+
+Sets a User-Agent to the request header
+version
+
+Default: false
+Type: boolean
+
+If true, output the npm version and exit successfully.
+Only relevant when specified explicitly on the command line.
+versions
+
+Default: false
+Type: boolean
+
+If true, output the npm version as well as node's process.versions
map, and
+exit successfully.
+Only relevant when specified explicitly on the command line.
+viewer
+
+Default: "man" on Posix, "browser" on Windows
+Type: path
+
+The program to use to view help content.
+Set to "browser"
to view html help content in the default web browser.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/misc/npm-developers.html nodejs-0.11.15/deps/npm/html/partial/doc/misc/npm-developers.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/misc/npm-developers.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/misc/npm-developers.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,161 @@
+ Developer Guide
+DESCRIPTION
+So, you've decided to use npm to develop (and maybe publish/deploy)
+your project.
+Fantastic!
+There are a few things that you need to do above the simple steps
+that your users will do to install your program.
+About These Documents
+These are man pages. If you install npm, you should be able to
+then do man npm-thing
to get the documentation on a particular
+topic, or npm help thing
to see the same information.
+What is a package
+A package is:
+
+a) a folder containing a program described by a package.json file
+b) a gzipped tarball containing (a)
+c) a url that resolves to (b)
+d) a <name>@<version>
that is published on the registry with (c)
+e) a <name>@<tag>
that points to (d)
+f) a <name>
that has a "latest" tag satisfying (e)
+g) a git
url that, when cloned, results in (a).
+
+Even if you never publish your package, you can still get a lot of
+benefits of using npm if you just want to write a node program (a), and
+perhaps if you also want to be able to easily install it elsewhere
+after packing it up into a tarball (b).
+Git urls can be of the form:
+git://github.com/user/project.git#commit-ish
+git+ssh://user@hostname:project.git#commit-ish
+git+http://user@hostname/project/blah.git#commit-ish
+git+https://user@hostname/project/blah.git#commit-ish
+
The commit-ish
can be any tag, sha, or branch which can be supplied as
+an argument to git checkout
. The default is master
.
+The package.json File
+You need to have a package.json
file in the root of your project to do
+much of anything with npm. That is basically the whole interface.
+See package.json(5)
for details about what goes in that file. At the very
+least, you need:
+
+name:
+This should be a string that identifies your project. Please do not
+use the name to specify that it runs on node, or is in JavaScript.
+You can use the "engines" field to explicitly state the versions of
+node (or whatever else) that your program requires, and it's pretty
+well assumed that it's javascript.
+It does not necessarily need to match your github repository name.
+So, node-foo
and bar-js
are bad names. foo
or bar
are better.
+
+version:
+A semver-compatible version.
+
+engines:
+Specify the versions of node (or whatever else) that your program
+runs on. The node API changes a lot, and there may be bugs or new
+functionality that you depend on. Be explicit.
+
+author:
+Take some credit.
+
+scripts:
+If you have a special compilation or installation script, then you
+should put it in the scripts
object. You should definitely have at
+least a basic smoke-test command as the "scripts.test" field.
+See npm-scripts(7) .
+
+main:
+If you have a single module that serves as the entry point to your
+program (like what the "foo" package gives you at require("foo")),
+then you need to specify that in the "main" field.
+
+directories:
+This is an object mapping names to folders. The best ones to include are
+"lib" and "doc", but if you use "man" to specify a folder full of man pages,
+they'll get installed just like these ones.
+
+
+You can use npm init
in the root of your package in order to get you
+started with a pretty basic package.json file. See npm-init(1)
for
+more info.
+Keeping files out of your package
+Use a .npmignore
file to keep stuff out of your package. If there's
+no .npmignore
file, but there is a .gitignore
file, then npm will
+ignore the stuff matched by the .gitignore
file. If you want to
+include something that is excluded by your .gitignore
file, you can
+create an empty .npmignore
file to override it.
+By default, the following paths and files are ignored, so there's no
+need to add them to .npmignore
explicitly:
+
+.*.swp
+._*
+.DS_Store
+.git
+.hg
+.lock-wscript
+.svn
+.wafpickle-*
+CVS
+npm-debug.log
+
+Additionally, everything in node_modules
is ignored, except for
+bundled dependencies. npm automatically handles this for you, so don't
+bother adding node_modules
to .npmignore
.
+The following paths and files are never ignored, so adding them to
+.npmignore
is pointless:
+
+Link Packages
+npm link
is designed to install a development package and see the
+changes in real time without having to keep re-installing it. (You do
+need to either re-link or npm rebuild -g
to update compiled packages,
+of course.)
+More info at npm-link(1)
.
+Before Publishing: Make Sure Your Package Installs and Works
+This is important.
+If you can not install it locally, you'll have
+problems trying to publish it. Or, worse yet, you'll be able to
+publish it, but you'll be publishing a broken or pointless package.
+So don't do that.
+In the root of your package, do this:
+npm install . -g
+
That'll show you that it's working. If you'd rather just create a symlink
+package that points to your working directory, then do this:
+npm link
+
Use npm ls -g
to see if it's there.
+To test a local install, go into some other folder, and then do:
+cd ../some-other-folder
+npm install ../my-package
+
to install it locally into the node_modules folder in that other place.
+Then go into the node-repl, and try using require("my-thing") to
+bring in your module's main module.
+Create a User Account
+Create a user with the adduser command. It works like this:
+npm adduser
+
and then follow the prompts.
+This is documented better in npm-adduser(1) .
+Publish your package
+This part's easy. IN the root of your folder, do this:
+npm publish
+
You can give publish a url to a tarball, or a filename of a tarball,
+or a path to a folder.
+Note that pretty much everything in that folder will be exposed
+by default. So, if you have secret stuff in there, use a
+.npmignore
file to list out the globs to ignore, or publish
+from a fresh checkout.
+Brag about it
+Send emails, write blogs, blab in IRC.
+Tell the world how easy it is to install your program!
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/misc/npm-disputes.html nodejs-0.11.15/deps/npm/html/partial/doc/misc/npm-disputes.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/misc/npm-disputes.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/misc/npm-disputes.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,92 @@
+ Handling Module Name Disputes
+SYNOPSIS
+
+Get the author email with npm owner ls <pkgname>
+Email the author, CC support@npmjs.com
+After a few weeks, if there's no resolution, we'll sort it out.
+
+Don't squat on package names. Publish code or move out of the way.
+DESCRIPTION
+There sometimes arise cases where a user publishes a module, and then
+later, some other user wants to use that name. Here are some common
+ways that happens (each of these is based on actual events.)
+
+Joe writes a JavaScript module foo
, which is not node-specific.
+Joe doesn't use node at all. Bob wants to use foo
in node, so he
+wraps it in an npm module. Some time later, Joe starts using node,
+and wants to take over management of his program.
+Bob writes an npm module foo
, and publishes it. Perhaps much
+later, Joe finds a bug in foo
, and fixes it. He sends a pull
+request to Bob, but Bob doesn't have the time to deal with it,
+because he has a new job and a new baby and is focused on his new
+erlang project, and kind of not involved with node any more. Joe
+would like to publish a new foo
, but can't, because the name is
+taken.
+Bob writes a 10-line flow-control library, and calls it foo
, and
+publishes it to the npm registry. Being a simple little thing, it
+never really has to be updated. Joe works for Foo Inc, the makers
+of the critically acclaimed and widely-marketed foo
JavaScript
+toolkit framework. They publish it to npm as foojs
, but people are
+routinely confused when npm install foo
is some different thing.
+Bob writes a parser for the widely-known foo
file format, because
+he needs it for work. Then, he gets a new job, and never updates the
+prototype. Later on, Joe writes a much more complete foo
parser,
+but can't publish, because Bob's foo
is in the way.
+
+The validity of Joe's claim in each situation can be debated. However,
+Joe's appropriate course of action in each case is the same.
+
+npm owner ls foo
. This will tell Joe the email address of the
+owner (Bob).
+Joe emails Bob, explaining the situation as respectfully as
+possible , and what he would like to do with the module name. He
+adds the npm support staff support@npmjs.com to the CC list of
+the email. Mention in the email that Bob can run npm owner add
+joe foo
to add Joe as an owner of the foo
package.
+After a reasonable amount of time, if Bob has not responded, or if
+Bob and Joe can't come to any sort of resolution, email support
+support@npmjs.com and we'll sort it out. ("Reasonable" is
+usually at least 4 weeks, but extra time is allowed around common
+holidays.)
+
+REASONING
+In almost every case so far, the parties involved have been able to reach
+an amicable resolution without any major intervention. Most people
+really do want to be reasonable, and are probably not even aware that
+they're in your way.
+Module ecosystems are most vibrant and powerful when they are as
+self-directed as possible. If an admin one day deletes something you
+had worked on, then that is going to make most people quite upset,
+regardless of the justification. When humans solve their problems by
+talking to other humans with respect, everyone has the chance to end up
+feeling good about the interaction.
+EXCEPTIONS
+Some things are not allowed, and will be removed without discussion if
+they are brought to the attention of the npm registry admins, including
+but not limited to:
+
+Malware (that is, a package designed to exploit or harm the machine on
+which it is installed).
+Violations of copyright or licenses (for example, cloning an
+MIT-licensed program, and then removing or changing the copyright and
+license statement).
+Illegal content.
+"Squatting" on a package name that you plan to use, but aren't
+actually using. Sorry, I don't care how great the name is, or how
+perfect a fit it is for the thing that someday might happen. If
+someone wants to use it today, and you're just taking up space with
+an empty tarball, you're going to be evicted.
+Putting empty packages in the registry. Packages must have SOME
+functionality. It can be silly, but it can't be nothing . (See
+also: squatting.)
+Doing weird things with the registry, like using it as your own
+personal application database or otherwise putting non-packagey
+things into it.
+
+If you see bad behavior like this, please report it right away.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/misc/npm-faq.html nodejs-0.11.15/deps/npm/html/partial/doc/misc/npm-faq.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/misc/npm-faq.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/misc/npm-faq.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,264 @@
+ Frequently Asked Questions
+Where can I find these docs in HTML?
+https://www.npmjs.org/doc/ , or run:
+npm config set viewer browser
+
to open these documents in your default web browser rather than man
.
+It didn't work.
+That's not really a question.
+Why didn't it work?
+I don't know yet.
+Read the error output, and if you can't figure out what it means,
+do what it says and post a bug with all the information it asks for.
+Where does npm put stuff?
+See npm-folders(5)
+tl;dr:
+
+Use the npm root
command to see where modules go, and the npm bin
+command to see where executables go
+Global installs are different from local installs. If you install
+something with the -g
flag, then its executables go in npm bin -g
+and its modules go in npm root -g
.
+
+How do I install something on my computer in a central location?
+Install it globally by tacking -g
or --global
to the command. (This
+is especially important for command line utilities that need to add
+their bins to the global system PATH
.)
+I installed something globally, but I can't require()
it
+Install it locally.
+The global install location is a place for command-line utilities
+to put their bins in the system PATH
. It's not for use with require()
.
+If you require()
a module in your code, then that means it's a
+dependency, and a part of your program. You need to install it locally
+in your program.
+Why can't npm just put everything in one place, like other package managers?
+Not every change is an improvement, but every improvement is a change.
+This would be like asking git to do network IO for every commit. It's
+not going to happen, because it's a terrible idea that causes more
+problems than it solves.
+It is much harder to avoid dependency conflicts without nesting
+dependencies. This is fundamental to the way that npm works, and has
+proven to be an extremely successful approach. See npm-folders(5)
for
+more details.
+If you want a package to be installed in one place, and have all your
+programs reference the same copy of it, then use the npm link
command.
+That's what it's for. Install it globally, then link it into each
+program that uses it.
+Whatever, I really want the old style 'everything global' style.
+Write your own package manager. You could probably even wrap up npm
+in a shell script if you really wanted to.
+npm will not help you do something that is known to be a bad idea.
+Should I check my node_modules
folder into git?
+Usually, no. Allow npm to resolve dependencies for your packages.
+For packages you deploy , such as websites and apps,
+you should use npm shrinkwrap to lock down your full dependency tree:
+https://www.npmjs.org/doc/cli/npm-shrinkwrap.html
+If you are paranoid about depending on the npm ecosystem,
+you should run a private npm mirror or a private cache.
+If you want 100% confidence in being able to reproduce the specific bytes
+included in a deployment, you should use an additional mechanism that can
+verify contents rather than versions. For example,
+Amazon machine images, DigitalOcean snapshots, Heroku slugs, or simple tarballs.
+Is it 'npm' or 'NPM' or 'Npm'?
+npm should never be capitalized unless it is being displayed in a
+location that is customarily all-caps (such as the title of man pages.)
+If 'npm' is an acronym, why is it never capitalized?
+Contrary to the belief of many, "npm" is not in fact an abbreviation for
+"Node Package Manager". It is a recursive bacronymic abbreviation for
+"npm is not an acronym". (If it was "ninaa", then it would be an
+acronym, and thus incorrectly named.)
+"NPM", however, is an acronym (more precisely, a capitonym) for the
+National Association of Pastoral Musicians. You can learn more
+about them at http://npm.org/ .
+In software, "NPM" is a Non-Parametric Mapping utility written by
+Chris Rorden. You can analyze pictures of brains with it. Learn more
+about the (capitalized) NPM program at http://www.cabiatl.com/mricro/npm/ .
+The first seed that eventually grew into this flower was a bash utility
+named "pm", which was a shortened descendent of "pkgmakeinst", a
+bash function that was used to install various different things on different
+platforms, most often using Yahoo's yinst
. If npm
was ever an
+acronym for anything, it was node pm
or maybe new pm
.
+So, in all seriousness, the "npm" project is named after its command-line
+utility, which was organically selected to be easily typed by a right-handed
+programmer using a US QWERTY keyboard layout, ending with the
+right-ring-finger in a postition to type the -
key for flags and
+other command-line arguments. That command-line utility is always
+lower-case, though it starts most sentences it is a part of.
+How do I list installed packages?
+npm ls
+How do I search for packages?
+npm search
+Arguments are greps. npm search jsdom
shows jsdom packages.
+How do I update npm?
+npm install npm -g
+
You can also update all outdated local packages by doing npm update
without
+any arguments, or global packages by doing npm update -g
.
+Occasionally, the version of npm will progress such that the current
+version cannot be properly installed with the version that you have
+installed already. (Consider, if there is ever a bug in the update
+command.)
+In those cases, you can do this:
+curl https://www.npmjs.org/install.sh | sh
+
What is a package
?
+A package is:
+
+a) a folder containing a program described by a package.json file
+b) a gzipped tarball containing (a)
+c) a url that resolves to (b)
+d) a <name>@<version>
that is published on the registry with (c)
+e) a <name>@<tag>
that points to (d)
+f) a <name>
that has a "latest" tag satisfying (e)
+g) a git
url that, when cloned, results in (a).
+
+Even if you never publish your package, you can still get a lot of
+benefits of using npm if you just want to write a node program (a), and
+perhaps if you also want to be able to easily install it elsewhere
+after packing it up into a tarball (b).
+Git urls can be of the form:
+git://github.com/user/project.git#commit-ish
+git+ssh://user@hostname:project.git#commit-ish
+git+http://user@hostname/project/blah.git#commit-ish
+git+https://user@hostname/project/blah.git#commit-ish
+
The commit-ish
can be any tag, sha, or branch which can be supplied as
+an argument to git checkout
. The default is master
.
+What is a module
?
+A module is anything that can be loaded with require()
in a Node.js
+program. The following things are all examples of things that can be
+loaded as modules:
+
+A folder with a package.json
file containing a main
field.
+A folder with an index.js
file in it.
+A JavaScript file.
+
+Most npm packages are modules, because they are libraries that you
+load with require
. However, there's no requirement that an npm
+package be a module! Some only contain an executable command-line
+interface, and don't provide a main
field for use in Node programs.
+Almost all npm packages (at least, those that are Node programs)
+contain many modules within them (because every file they load with
+require()
is a module).
+In the context of a Node program, the module
is also the thing that
+was loaded from a file. For example, in the following program:
+var req = require('request')
+
we might say that "The variable req
refers to the request
module".
+So, why is it the "node_modules
" folder, but "package.json
" file? Why not node_packages
or module.json
?
+The package.json
file defines the package. (See "What is a
+package?" above.)
+The node_modules
folder is the place Node.js looks for modules.
+(See "What is a module?" above.)
+For example, if you create a file at node_modules/foo.js
and then
+had a program that did var f = require('foo.js')
then it would load
+the module. However, foo.js
is not a "package" in this case,
+because it does not have a package.json.
+Alternatively, if you create a package which does not have an
+index.js
or a "main"
field in the package.json
file, then it is
+not a module. Even if it's installed in node_modules
, it can't be
+an argument to require()
.
+
+No. This will never happen. This question comes up sometimes,
+because it seems silly from the outside that npm couldn't just be
+configured to put stuff somewhere else, and then npm could load them
+from there. It's an arbitrary spelling choice, right? What's the big
+deal?
+At the time of this writing, the string 'node_modules'
appears 151
+times in 53 separate files in npm and node core (excluding tests and
+documentation).
+Some of these references are in node's built-in module loader. Since
+npm is not involved at all at run-time, node itself would have to
+be configured to know where you've decided to stick stuff. Complexity
+hurdle #1. Since the Node module system is locked, this cannot be
+changed, and is enough to kill this request. But I'll continue, in
+deference to your deity's delicate feelings regarding spelling.
+Many of the others are in dependencies that npm uses, which are not
+necessarily tightly coupled to npm (in the sense that they do not read
+npm's configuration files, etc.) Each of these would have to be
+configured to take the name of the node_modules
folder as a
+parameter. Complexity hurdle #2.
+Furthermore, npm has the ability to "bundle" dependencies by adding
+the dep names to the "bundledDependencies"
list in package.json,
+which causes the folder to be included in the package tarball. What
+if the author of a module bundles its dependencies, and they use a
+different spelling for node_modules
? npm would have to rename the
+folder at publish time, and then be smart enough to unpack it using
+your locally configured name. Complexity hurdle #3.
+Furthermore, what happens when you change this name? Fine, it's
+easy enough the first time, just rename the node_modules
folders to
+./blergyblerp/
or whatever name you choose. But what about when you
+change it again? npm doesn't currently track any state about past
+configuration settings, so this would be rather difficult to do
+properly. It would have to track every previous value for this
+config, and always accept any of them, or else yesterday's install may
+be broken tomorrow. Complexity hurdle #4.
+Never going to happen. The folder is named node_modules
. It is
+written indelibly in the Node Way, handed down from the ancient times
+of Node 0.3.
+How do I install node with npm?
+You don't. Try one of these node version managers:
+Unix:
+
+Windows:
+
+How can I use npm for development?
+See npm-developers(7)
and package.json(5)
.
+You'll most likely want to npm link
your development folder. That's
+awesomely handy.
+To set up your own private registry, check out npm-registry(7)
.
+Can I list a url as a dependency?
+Yes. It should be a url to a gzipped tarball containing a single folder
+that has a package.json in its root, or a git url.
+(See "what is a package?" above.)
+How do I symlink to a dev folder so I don't have to keep re-installing?
+See npm-link(1)
+The package registry website. What is that exactly?
+See npm-registry(7)
.
+I forgot my password, and can't publish. How do I reset it?
+Go to https://npmjs.org/forgot .
+I get ECONNREFUSED a lot. What's up?
+Either the registry is down, or node's DNS isn't able to reach out.
+To check if the registry is down, open up
+https://registry.npmjs.org/ in a web browser. This will also tell
+you if you are just unable to access the internet for some reason.
+If the registry IS down, let us know by emailing support@npmjs.com
+or posting an issue at https://github.com/npm/npm/issues . If it's
+down for the world (and not just on your local network) then we're
+probably already being pinged about it.
+You can also often get a faster response by visiting the #npm channel
+on Freenode IRC.
+Why no namespaces?
+Please see this discussion: https://github.com/npm/npm/issues/798
+tl;dr - It doesn't actually make things better, and can make them worse.
+If you want to namespace your own packages, you may: simply use the
+-
character to separate the names. npm is a mostly anarchic system.
+There is not sufficient need to impose namespace rules on everyone.
+Who does npm?
+npm was originally written by Isaac Z. Schlueter, and many others have
+contributed to it, some of them quite substantially.
+The npm open source project, The npm Registry, and the community
+website are maintained and operated by the
+good folks at npm, Inc.
+I have a question or request not addressed here. Where should I put it?
+Post an issue on the github project:
+
+Why does npm hate me?
+npm is not capable of hatred. It loves everyone, especially you.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/misc/npm-index.html nodejs-0.11.15/deps/npm/html/partial/doc/misc/npm-index.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/misc/npm-index.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/misc/npm-index.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,210 @@
+ Index of all npm documentation
+
+node package manager
+Command Line Documentation
+Using npm on the command line
+
+node package manager
+
+Add a registry user account
+
+Display npm bin folder
+
+Bugs for a package in a web browser maybe
+
+Build a package
+
+REMOVED
+
+Manipulates packages cache
+
+Tab Completion for npm
+
+Manage the npm configuration files
+
+Reduce duplication
+
+Deprecate a version of a package
+
+Docs for a package in a web browser maybe
+
+Edit an installed package
+
+Browse an installed package
+
+Search npm help documentation
+
+Get help on npm
+
+Interactively create a package.json file
+
+Install a package
+
+Symlink a package folder
+
+List installed packages
+
+Check for outdated packages
+
+Manage package owners
+
+Create a tarball from a package
+
+Display prefix
+
+Remove extraneous packages
+
+Publish a package
+
+Rebuild a package
+
+Open package repository page in the browser
+
+Start a package
+
+Remove a package
+
+Display npm root
+
+Run arbitrary package scripts
+
+Search for packages
+
+Lock down dependency versions
+
+Mark your favorite packages
+
+View packages marked as favorites
+
+Start a package
+
+Stop a package
+
+Tag a published version
+
+Test a package
+
+Remove a package
+
+Remove a package from the registry
+
+Update a package
+
+Bump a package version
+
+View registry info
+
+Display npm username
+API Documentation
+Using npm in your Node programs
+
+node package manager
+
+Display npm bin folder
+
+Bugs for a package in a web browser maybe
+
+manage the npm cache programmatically
+
+npm commands
+
+Manage the npm configuration files
+
+Deprecate a version of a package
+
+Docs for a package in a web browser maybe
+
+Edit an installed package
+
+Browse an installed package
+
+Search the help pages
+
+Interactively create a package.json file
+
+install a package programmatically
+
+Symlink a package folder
+
+Load config settings
+
+List installed packages
+
+Check for outdated packages
+
+Manage package owners
+
+Create a tarball from a package
+
+Display prefix
+
+Remove extraneous packages
+
+Publish a package
+
+Rebuild a package
+
+Open package repository page in the browser
+
+Start a package
+
+Display npm root
+
+Run arbitrary package scripts
+
+Search for packages
+
+programmatically generate package shrinkwrap file
+
+Start a package
+
+Stop a package
+
+Tag a published version
+
+Test a package
+
+uninstall a package programmatically
+
+Remove a package from the registry
+
+Update a package
+
+Bump a package version
+
+View registry info
+
+Display npm username
+Files
+File system structures npm uses
+
+Folder Structures Used by npm
+
+The npm config files
+
+Specifics of npm's package.json handling
+Misc
+Various other bits and bobs
+
+npm's "funny" coding style
+
+More than you probably want to know about npm configuration
+
+Developer Guide
+
+Handling Module Name Disputes
+
+Frequently Asked Questions
+
+Index of all npm documentation
+
+The JavaScript Package Registry
+
+Scoped packages
+
+How npm handles the "scripts" field
+
+Cleaning the Slate
+
+The semantic versioner for npm
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/misc/npm-registry.html nodejs-0.11.15/deps/npm/html/partial/doc/misc/npm-registry.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/misc/npm-registry.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/misc/npm-registry.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,50 @@
+ The JavaScript Package Registry
+DESCRIPTION
+To resolve packages by name and version, npm talks to a registry website
+that implements the CommonJS Package Registry specification for reading
+package info.
+Additionally, npm's package registry implementation supports several
+write APIs as well, to allow for publishing packages and managing user
+account information.
+The official public npm registry is at http://registry.npmjs.org/ . It
+is powered by a CouchDB database, of which there is a public mirror at
+http://skimdb.npmjs.com/registry . The code for the couchapp is
+available at http://github.com/npm/npm-registry-couchapp .
+The registry URL used is determined by the scope of the package (see
+npm-scope(7)
). If no scope is specified, the default registry is used, which is
+supplied by the registry
config parameter. See npm-config(1)
,
+npmrc(5)
, and npm-config(7)
for more on managing npm's configuration.
+Can I run my own private registry?
+Yes!
+The easiest way is to replicate the couch database, and use the same (or
+similar) design doc to implement the APIs.
+If you set up continuous replication from the official CouchDB, and then
+set your internal CouchDB as the registry config, then you'll be able
+to read any published packages, in addition to your private ones, and by
+default will only publish internally. If you then want to publish a
+package for the whole world to see, you can simply override the
+--registry
config for that command.
+I don't want my package published in the official registry. It's private.
+Set "private": true
in your package.json to prevent it from being
+published at all, or
+"publishConfig":{"registry":"http://my-internal-registry.local"}
+to force it to be published only to your internal registry.
+See package.json(5)
for more info on what goes in the package.json file.
+Will you replicate from my registry into the public one?
+No. If you want things to be public, then publish them into the public
+registry using npm. What little security there is would be for nought
+otherwise.
+Do I have to use couchdb to build a registry that npm can talk to?
+No, but it's way easier. Basically, yes, you do, or you have to
+effectively implement the entire CouchDB API anyway.
+Is there a website or something to see package docs and such?
+Yes, head over to https://npmjs.org/
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/misc/npm-scope.html nodejs-0.11.15/deps/npm/html/partial/doc/misc/npm-scope.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/misc/npm-scope.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/misc/npm-scope.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,58 @@
+ Scoped packages
+DESCRIPTION
+All npm packages have a name. Some package names also have a scope. A scope
+follows the usual rules for package names (url-safe characters, no leading dots
+or underscores). When used in package names, preceded by an @-symbol and
+followed by a slash, e.g.
+@somescope/somepackagename
+
Scopes are a way of grouping related packages together, and also affect a few
+things about the way npm treats the package.
+As of 2014-09-03, scoped packages are not supported by the public npm registry .
+However, the npm client is backwards-compatible with un-scoped registries, so
+it can be used to work with scoped and un-scoped registries at the same time.
+Installing scoped packages
+Scoped packages are installed to a sub-folder of the regular installation
+folder, e.g. if your other packages are installed in node_modules/packagename
,
+scoped modules will be in node_modules/@myorg/packagename
. The scope folder
+(@myorg
) is simply the name of the scope preceded by an @-symbol, and can
+contain any number of scoped packages.
+A scoped package is installed by referencing it by name, preceded by an
+@-symbol, in npm install
:
+npm install @myorg/mypackage
+
Or in package.json
:
+"dependencies": {
+ "@myorg/mypackage": "^1.3.0"
+}
+
Note that if the @-symbol is omitted in either case npm will instead attempt to
+install from GitHub; see npm-install(1)
.
+Requiring scoped packages
+Because scoped packages are installed into a scope folder, you have to
+include the name of the scope when requiring them in your code, e.g.
+require('@myorg/mypackage')
+
There is nothing special about the way Node treats scope folders, this is
+just specifying to require the module mypackage
in the folder called @myorg
.
+Publishing scoped packages
+Scoped packages can be published to any registry that supports them.
+As of 2014-09-03, the public npm registry does not support scoped packages ,
+so attempting to publish a scoped package to the registry will fail unless
+you have associated that scope with a different registry, see below.
+Associating a scope with a registry
+Scopes can be associated with a separate registry. This allows you to
+seamlessly use a mix of packages from the public npm registry and one or more
+private registries, such as npm Enterprise.
+You can associate a scope with a registry at login, e.g.
+npm login --registry=http://reg.example.com --scope=@myco
+
Scopes have a many-to-one relationship with registries: one registry can
+host multiple scopes, but a scope only ever points to one registry.
+You can also associate a scope with a registry using npm config
:
+npm config set @myco:registry http://reg.example.com
+
Once a scope is associated with a registry, any npm install
for a package
+with that scope will request packages from that registry instead. Any
+npm publish
for a package name that contains the scope will be published to
+that registry instead.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/misc/npm-scripts.html nodejs-0.11.15/deps/npm/html/partial/doc/misc/npm-scripts.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/misc/npm-scripts.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/misc/npm-scripts.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,200 @@
+ How npm handles the "scripts" field
+DESCRIPTION
+npm supports the "scripts" property of the package.json script, for the
+following scripts:
+
+prepublish:
+Run BEFORE the package is published. (Also run on local npm
+install
without any arguments.)
+publish, postpublish:
+Run AFTER the package is published.
+preinstall:
+Run BEFORE the package is installed
+install, postinstall:
+Run AFTER the package is installed.
+preuninstall, uninstall:
+Run BEFORE the package is uninstalled.
+postuninstall:
+Run AFTER the package is uninstalled.
+preupdate:
+Run BEFORE the package is updated with the update command.
+update, postupdate:
+Run AFTER the package is updated with the update command.
+pretest, test, posttest:
+Run by the npm test
command.
+prestop, stop, poststop:
+Run by the npm stop
command.
+prestart, start, poststart:
+Run by the npm start
command.
+prerestart, restart, postrestart:
+Run by the npm restart
command. Note: npm restart
will run the
+stop and start scripts if no restart
script is provided.
+
+Additionally, arbitrary scripts can be executed by running npm
+run-script <pkg> <stage>
. Pre and post commands with matching
+names will be run for those as well (e.g. premyscript
, myscript
,
+postmyscript
).
+NOTE: INSTALL SCRIPTS ARE AN ANTIPATTERN
+tl;dr Don't use install
. Use a .gyp
file for compilation, and
+prepublish
for anything else.
+You should almost never have to explicitly set a preinstall
or
+install
script. If you are doing this, please consider if there is
+another option.
+The only valid use of install
or preinstall
scripts is for
+compilation which must be done on the target architecture. In early
+versions of node, this was often done using the node-waf
scripts, or
+a standalone Makefile
, and early versions of npm required that it be
+explicitly set in package.json. This was not portable, and harder to
+do properly.
+In the current version of node, the standard way to do this is using a
+.gyp
file. If you have a file with a .gyp
extension in the root
+of your package, then npm will run the appropriate node-gyp
commands
+automatically at install time. This is the only officially supported
+method for compiling binary addons, and does not require that you add
+anything to your package.json file.
+If you have to do other things before your package is used, in a way
+that is not dependent on the operating system or architecture of the
+target system, then use a prepublish
script instead. This includes
+tasks such as:
+
+Compile CoffeeScript source code into JavaScript.
+Create minified versions of JavaScript source code.
+Fetching remote resources that your package will use.
+
+The advantage of doing these things at prepublish
time instead of
+preinstall
or install
time is that they can be done once, in a
+single place, and thus greatly reduce complexity and variability.
+Additionally, this means that:
+
+You can depend on coffee-script
as a devDependency
, and thus
+your users don't need to have it installed.
+You don't need to include the minifiers in your package, reducing
+the size for your users.
+You don't need to rely on your users having curl
or wget
or
+other system tools on the target machines.
+
+DEFAULT VALUES
+npm will default some script values based on package contents.
+
+"start": "node server.js"
:
+If there is a server.js
file in the root of your package, then npm
+will default the start
command to node server.js
.
+
+"preinstall": "node-waf clean || true; node-waf configure build"
:
+If there is a wscript
file in the root of your package, npm will
+default the preinstall
command to compile using node-waf.
+
+
+USER
+If npm was invoked with root privileges, then it will change the uid
+to the user account or uid specified by the user
config, which
+defaults to nobody
. Set the unsafe-perm
flag to run scripts with
+root privileges.
+ENVIRONMENT
+Package scripts run in an environment where many pieces of information
+are made available regarding the setup of npm and the current state of
+the process.
+path
+If you depend on modules that define executable scripts, like test
+suites, then those executables will be added to the PATH
for
+executing the scripts. So, if your package.json has this:
+{ "name" : "foo"
+, "dependencies" : { "bar" : "0.1.x" }
+, "scripts": { "start" : "bar ./test" } }
+
then you could run npm start
to execute the bar
script, which is
+exported into the node_modules/.bin
directory on npm install
.
+package.json vars
+The package.json fields are tacked onto the npm_package_
prefix. So,
+for instance, if you had {"name":"foo", "version":"1.2.5"}
in your
+package.json file, then your package scripts would have the
+npm_package_name
environment variable set to "foo", and the
+npm_package_version
set to "1.2.5"
+configuration
+Configuration parameters are put in the environment with the
+npm_config_
prefix. For instance, you can view the effective root
+config by checking the npm_config_root
environment variable.
+Special: package.json "config" object
+The package.json "config" keys are overwritten in the environment if
+there is a config param of <name>[@<version>]:<key>
. For example,
+if the package.json has this:
+{ "name" : "foo"
+, "config" : { "port" : "8080" }
+, "scripts" : { "start" : "node server.js" } }
+
and the server.js is this:
+http.createServer(...).listen(process.env.npm_package_config_port)
+
then the user could change the behavior by doing:
+npm config set foo:port 80
+
current lifecycle event
+Lastly, the npm_lifecycle_event
environment variable is set to
+whichever stage of the cycle is being executed. So, you could have a
+single script used for different parts of the process which switches
+based on what's currently happening.
+Objects are flattened following this format, so if you had
+{"scripts":{"install":"foo.js"}}
in your package.json, then you'd
+see this in the script:
+process.env.npm_package_scripts_install === "foo.js"
+
EXAMPLES
+For example, if your package.json contains this:
+{ "scripts" :
+ { "install" : "scripts/install.js"
+ , "postinstall" : "scripts/install.js"
+ , "uninstall" : "scripts/uninstall.js"
+ }
+}
+
then the scripts/install.js
will be called for the install,
+post-install, stages of the lifecycle, and the scripts/uninstall.js
+would be called when the package is uninstalled. Since
+scripts/install.js
is running for three different phases, it would
+be wise in this case to look at the npm_lifecycle_event
environment
+variable.
+If you want to run a make command, you can do so. This works just
+fine:
+{ "scripts" :
+ { "preinstall" : "./configure"
+ , "install" : "make && make install"
+ , "test" : "make test"
+ }
+}
+
EXITING
+Scripts are run by passing the line as a script argument to sh
.
+If the script exits with a code other than 0, then this will abort the
+process.
+Note that these script files don't have to be nodejs or even
+javascript programs. They just have to be some kind of executable
+file.
+HOOK SCRIPTS
+If you want to run a specific script at a specific lifecycle event for
+ALL packages, then you can use a hook script.
+Place an executable file at node_modules/.hooks/{eventname}
, and
+it'll get run for all packages when they are going through that point
+in the package lifecycle for any packages installed in that root.
+Hook scripts are run exactly the same way as package.json scripts.
+That is, they are in a separate child process, with the env described
+above.
+BEST PRACTICES
+
+Don't exit with a non-zero error code unless you really mean it.
+Except for uninstall scripts, this will cause the npm action to
+fail, and potentially be rolled back. If the failure is minor or
+only will prevent some optional features, then it's better to just
+print a warning and exit successfully.
+Try not to use scripts to do what npm can do for you. Read through
+package.json(5)
to see all the things that you can specify and enable
+by simply describing your package appropriately. In general, this
+will lead to a more robust and consistent state.
+Inspect the env to determine where to put things. For instance, if
+the npm_config_binroot
environ is set to /home/user/bin
, then
+don't try to install executables into /usr/local/bin
. The user
+probably set it up that way for a reason.
+Don't prefix your script commands with "sudo". If root permissions
+are required for some reason, then it'll fail with that error, and
+the user will sudo the npm command in question.
+
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/misc/removing-npm.html nodejs-0.11.15/deps/npm/html/partial/doc/misc/removing-npm.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/misc/removing-npm.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/misc/removing-npm.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,37 @@
+ Cleaning the Slate
+SYNOPSIS
+So sad to see you go.
+sudo npm uninstall npm -g
+
Or, if that fails, get the npm source code, and do:
+sudo make uninstall
+
More Severe Uninstalling
+Usually, the above instructions are sufficient. That will remove
+npm, but leave behind anything you've installed.
+If that doesn't work, or if you require more drastic measures,
+continue reading.
+Note that this is only necessary for globally-installed packages. Local
+installs are completely contained within a project's node_modules
+folder. Delete that folder, and everything is gone (unless a package's
+install script is particularly ill-behaved).
+This assumes that you installed node and npm in the default place. If
+you configured node with a different --prefix
, or installed npm with a
+different prefix setting, then adjust the paths accordingly, replacing
+/usr/local
with your install prefix.
+To remove everything npm-related manually:
+rm -rf /usr/local/{lib/node{,/.npm,_modules},bin,share/man}/npm*
+
If you installed things with npm, then your best bet is to uninstall
+them with npm first, and then install them again once you have a
+proper install. This can help find any symlinks that are lying
+around:
+ls -laF /usr/local/{lib/node{,/.npm},bin,share/man} | grep npm
+
Prior to version 0.3, npm used shim files for executables and node
+modules. To track those down, you can do the following:
+find /usr/local/{lib/node,bin} -exec grep -l npm \{\} \; ;
+
(This is also in the README file.)
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/misc/semver.html nodejs-0.11.15/deps/npm/html/partial/doc/misc/semver.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/misc/semver.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/misc/semver.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,243 @@
+ The semantic versioner for npm
+Usage
+$ npm install semver
+
+semver.valid('1.2.3') // '1.2.3'
+semver.valid('a.b.c') // null
+semver.clean(' =v1.2.3 ') // '1.2.3'
+semver.satisfies('1.2.3', '1.x || >=2.5.0 || 5.0.0 - 7.2.3') // true
+semver.gt('1.2.3', '9.8.7') // false
+semver.lt('1.2.3', '9.8.7') // true
+
As a command-line utility:
+$ semver -h
+
+Usage: semver <version> [<version> [...]] [-r <range> | -i <inc> | -d <dec>]
+Test if version(s) satisfy the supplied range(s), and sort them.
+
+Multiple versions or ranges may be supplied, unless increment
+or decrement options are specified. In that case, only a single
+version may be used, and it is incremented by the specified level
+
+Program exits successfully if any valid version satisfies
+all supplied ranges, and prints all satisfying versions.
+
+If no versions are valid, or ranges are not satisfied,
+then exits failure.
+
+Versions are printed in ascending order, so supplying
+multiple versions to the utility will just sort them.
+
Versions
+A "version" is described by the v2.0.0
specification found at
+http://semver.org/ .
+A leading "="
or "v"
character is stripped off and ignored.
+Ranges
+A version range
is a set of comparators
which specify versions
+that satisfy the range.
+A comparator
is composed of an operator
and a version
. The set
+of primitive operators
is:
+
+<
Less than
+<=
Less than or equal to
+>
Greater than
+>=
Greater than or equal to
+=
Equal. If no operator is specified, then equality is assumed,
+so this operator is optional, but MAY be included.
+
+For example, the comparator >=1.2.7
would match the versions
+1.2.7
, 1.2.8
, 2.5.3
, and 1.3.9
, but not the versions 1.2.6
+or 1.1.0
.
+Comparators can be joined by whitespace to form a comparator set
,
+which is satisfied by the intersection of all of the comparators
+it includes.
+A range is composed of one or more comparator sets, joined by ||
. A
+version matches a range if and only if every comparator in at least
+one of the ||
-separated comparator sets is satisfied by the version.
+For example, the range >=1.2.7 <1.3.0
would match the versions
+1.2.7
, 1.2.8
, and 1.2.99
, but not the versions 1.2.6
, 1.3.0
,
+or 1.1.0
.
+The range 1.2.7 || >=1.2.9 <2.0.0
would match the versions 1.2.7
,
+1.2.9
, and 1.4.6
, but not the versions 1.2.8
or 2.0.0
.
+
+If a version has a prerelease tag (for example, 1.2.3-alpha.3
) then
+it will only be allowed to satisfy comparator sets if at least one
+comparator with the same [major, minor, patch]
tuple also has a
+prerelease tag.
+For example, the range >1.2.3-alpha.3
would be allowed to match the
+version 1.2.3-alpha.7
, but it would not be satisfied by
+3.4.5-alpha.9
, even though 3.4.5-alpha.9
is technically "greater
+than" 1.2.3-alpha.3
according to the SemVer sort rules. The version
+range only accepts prerelease tags on the 1.2.3
version. The
+version 3.4.5
would satisfy the range, because it does not have a
+prerelease flag, and 3.4.5
is greater than 1.2.3-alpha.7
.
+The purpose for this behavior is twofold. First, prerelease versions
+frequently are updated very quickly, and contain many breaking changes
+that are (by the author's design) not yet fit for public consumption.
+Therefore, by default, they are excluded from range matching
+semantics.
+Second, a user who has opted into using a prerelease version has
+clearly indicated the intent to use that specific set of
+alpha/beta/rc versions. By including a prerelease tag in the range,
+the user is indicating that they are aware of the risk. However, it
+is still not appropriate to assume that they have opted into taking a
+similar risk on the next set of prerelease versions.
+Advanced Range Syntax
+Advanced range syntax desugars to primitive comparators in
+deterministic ways.
+Advanced ranges may be combined in the same way as primitive
+comparators using white space or ||
.
+Hyphen Ranges X.Y.Z - A.B.C
+Specifies an inclusive set.
+
+1.2.3 - 2.3.4
:= >=1.2.3 <=2.3.4
+
+If a partial version is provided as the first version in the inclusive
+range, then the missing pieces are replaced with zeroes.
+
+1.2 - 2.3.4
:= >=1.2.0 <=2.3.4
+
+If a partial version is provided as the second version in the
+inclusive range, then all versions that start with the supplied parts
+of the tuple are accepted, but nothing that would be greater than the
+provided tuple parts.
+
+1.2.3 - 2.3
:= >=1.2.3 <2.4.0
+1.2.3 - 2
:= >=1.2.3 <3.0.0
+
+X-Ranges 1.2.x
1.X
1.2.*
*
+Any of X
, x
, or *
may be used to "stand in" for one of the
+numeric values in the [major, minor, patch]
tuple.
+
+*
:= >=0.0.0
(Any version satisfies)
+1.x
:= >=1.0.0 <2.0.0
(Matching major version)
+1.2.x
:= >=1.2.0 <1.3.0
(Matching major and minor versions)
+
+A partial version range is treated as an X-Range, so the special
+character is in fact optional.
+
+""
(empty string) := *
:= >=0.0.0
+1
:= 1.x.x
:= >=1.0.0 <2.0.0
+1.2
:= 1.2.x
:= >=1.2.0 <1.3.0
+
+Tilde Ranges ~1.2.3
~1.2
~1
+Allows patch-level changes if a minor version is specified on the
+comparator. Allows minor-level changes if not.
+
+~1.2.3
:= >=1.2.3 <1.(2+1).0
:= >=1.2.3 <1.3.0
+~1.2
:= >=1.2.0 <1.(2+1).0
:= >=1.2.0 <1.3.0
(Same as 1.2.x
)
+~1
:= >=1.0.0 <(1+1).0.0
:= >=1.0.0 <2.0.0
(Same as 1.x
)
+~0.2.3
:= >=0.2.3 <0.(2+1).0
:= >=0.2.3 <0.3.0
+~0.2
:= >=0.2.0 <0.(2+1).0
:= >=0.2.0 <0.3.0
(Same as 0.2.x
)
+~0
:= >=0.0.0 <(0+1).0.0
:= >=0.0.0 <1.0.0
(Same as 0.x
)
+~1.2.3-beta.2
:= >=1.2.3-beta.2 <1.3.0
Note that prereleases in
+the 1.2.3
version will be allowed, if they are greater than or
+equal to beta.2
. So, 1.2.3-beta.4
would be allowed, but
+1.2.4-beta.2
would not, because it is a prerelease of a
+different [major, minor, patch]
tuple.
+
+Note: this is the same as the ~>
operator in rubygems.
+Caret Ranges ^1.2.3
^0.2.5
^0.0.4
+Allows changes that do not modify the left-most non-zero digit in the
+[major, minor, patch]
tuple. In other words, this allows patch and
+minor updates for versions 1.0.0
and above, patch updates for
+versions 0.X >=0.1.0
, and no updates for versions 0.0.X
.
+Many authors treat a 0.x
version as if the x
were the major
+"breaking-change" indicator.
+Caret ranges are ideal when an author may make breaking changes
+between 0.2.4
and 0.3.0
releases, which is a common practice.
+However, it presumes that there will not be breaking changes between
+0.2.4
and 0.2.5
. It allows for changes that are presumed to be
+additive (but non-breaking), according to commonly observed practices.
+
+^1.2.3
:= >=1.2.3 <2.0.0
+^0.2.3
:= >=0.2.3 <0.3.0
+^0.0.3
:= >=0.0.3 <0.0.4
+^1.2.3-beta.2
:= >=1.2.3-beta.2 <2.0.0
Note that prereleases in
+the 1.2.3
version will be allowed, if they are greater than or
+equal to beta.2
. So, 1.2.3-beta.4
would be allowed, but
+1.2.4-beta.2
would not, because it is a prerelease of a
+different [major, minor, patch]
tuple.
+^0.0.3-beta
:= >=0.0.3-beta <0.0.4
Note that prereleases in the
+0.0.3
version only will be allowed, if they are greater than or
+equal to beta
. So, 0.0.3-pr.2
would be allowed.
+
+When parsing caret ranges, a missing patch
value desugars to the
+number 0
, but will allow flexibility within that value, even if the
+major and minor versions are both 0
.
+
+^1.2.x
:= >=1.2.0 <2.0.0
+^0.0.x
:= >=0.0.0 <0.1.0
+^0.0
:= >=0.0.0 <0.1.0
+
+A missing minor
and patch
values will desugar to zero, but also
+allow flexibility within those values, even if the major version is
+zero.
+
+^1.x
:= >=1.0.0 <2.0.0
+^0.x
:= >=0.0.0 <1.0.0
+
+Functions
+All methods and classes take a final loose
boolean argument that, if
+true, will be more forgiving about not-quite-valid semver strings.
+The resulting output will always be 100% strict, of course.
+Strict-mode Comparators and Ranges will be strict about the SemVer
+strings that they parse.
+
+valid(v)
: Return the parsed version, or null if it's not valid.
+inc(v, release)
: Return the version incremented by the release
+type (major
, premajor
, minor
, preminor
, patch
,
+prepatch
, or prerelease
), or null if it's not valid
+premajor
in one call will bump the version up to the next major
+version and down to a prerelease of that major version.
+preminor
, and prepatch
work the same way.
+If called from a non-prerelease version, the prerelease
will work the
+same as prepatch
. It increments the patch version, then makes a
+prerelease. If the input version is already a prerelease it simply
+increments it.
+
+
+
+Comparison
+
+gt(v1, v2)
: v1 > v2
+gte(v1, v2)
: v1 >= v2
+lt(v1, v2)
: v1 < v2
+lte(v1, v2)
: v1 <= v2
+eq(v1, v2)
: v1 == v2
This is true if they're logically equivalent,
+even if they're not the exact same string. You already know how to
+compare strings.
+neq(v1, v2)
: v1 != v2
The opposite of eq
.
+cmp(v1, comparator, v2)
: Pass in a comparison string, and it'll call
+the corresponding function above. "==="
and "!=="
do simple
+string comparison, but are included for completeness. Throws if an
+invalid comparison string is provided.
+compare(v1, v2)
: Return 0
if v1 == v2
, or 1
if v1
is greater, or -1
if
+v2
is greater. Sorts in ascending order if passed to Array.sort()
.
+rcompare(v1, v2)
: The reverse of compare. Sorts an array of versions
+in descending order when passed to Array.sort()
.
+
+Ranges
+
+validRange(range)
: Return the valid range or null if it's not valid
+satisfies(version, range)
: Return true if the version satisfies the
+range.
+maxSatisfying(versions, range)
: Return the highest version in the list
+that satisfies the range, or null
if none of them do.
+gtr(version, range)
: Return true
if version is greater than all the
+versions possible in the range.
+ltr(version, range)
: Return true
if version is less than all the
+versions possible in the range.
+outside(version, range, hilo)
: Return true if the version is outside
+the bounds of the range in either the high or low direction. The
+hilo
argument must be either the string '>'
or '<'
. (This is
+the function called by gtr
and ltr
.)
+
+Note that, since ranges may be non-contiguous, a version might not be
+greater than a range, less than a range, or satisfy a range! For
+example, the range 1.2 <1.2.9 || >2.0.0
would have a hole from 1.2.9
+until 2.0.0
, so the version 1.2.10
would not be greater than the
+range (because 2.0.1
satisfies, which is higher), nor less than the
+range (since 1.2.8
satisfies, which is lower), and it also does not
+satisfy the range.
+If you want to know if a version satisfies or does not satisfy a
+range, use the satisfies(version, range)
function.
+
diff -Nru nodejs-0.11.14/deps/npm/html/partial/doc/README.html nodejs-0.11.15/deps/npm/html/partial/doc/README.html
--- nodejs-0.11.14/deps/npm/html/partial/doc/README.html 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/html/partial/doc/README.html 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,166 @@
+ node package manager
+
+SYNOPSIS
+This is just enough info to get you up and running.
+Much more info available via npm help
once it's installed.
+IMPORTANT
+You need node v0.8 or higher to run this program.
+To install an old and unsupported version of npm that works on node 0.3
+and prior, clone the git repo and dig through the old tags and branches.
+Super Easy Install
+npm comes with node now.
+Windows Computers
+Get the MSI . npm is in it.
+Apple Macintosh Computers
+Get the pkg . npm is in it.
+Other Sorts of Unices
+Run make install
. npm will be installed with node.
+If you want a more fancy pants install (a different version, customized
+paths, etc.) then read on.
+Fancy Install (Unix)
+There's a pretty robust install script at
+https://www.npmjs.org/install.sh . You can download that and run it.
+Here's an example using curl:
+curl -L https://npmjs.org/install.sh | sh
+
Slightly Fancier
+You can set any npm configuration params with that script:
+npm_config_prefix=/some/path sh install.sh
+
Or, you can run it in uber-debuggery mode:
+npm_debug=1 sh install.sh
+
Even Fancier
+Get the code with git. Use make
to build the docs and do other stuff.
+If you plan on hacking on npm, make link
is your friend.
+If you've got the npm source code, you can also semi-permanently set
+arbitrary config keys using the ./configure --key=val ...
, and then
+run npm commands by doing node cli.js <cmd> <args>
. (This is helpful
+for testing, or running stuff without actually installing npm itself.)
+Fancy Windows Install
+You can download a zip file from https://npmjs.org/dist/ , and unpack it
+in the same folder where node.exe lives.
+If that's not fancy enough for you, then you can fetch the code with
+git, and mess with it directly.
+Installing on Cygwin
+No.
+Permissions when Using npm to Install Other Stuff
+tl;dr
+
+Use sudo
for greater safety. Or don't, if you prefer not to.
+npm will downgrade permissions if it's root before running any build
+scripts that package authors specified.
+
+More details...
+As of version 0.3, it is recommended to run npm as root.
+This allows npm to change the user identifier to the nobody
user prior
+to running any package build or test commands.
+If you are not the root user, or if you are on a platform that does not
+support uid switching, then npm will not attempt to change the userid.
+If you would like to ensure that npm always runs scripts as the
+"nobody" user, and have it fail if it cannot downgrade permissions, then
+set the following configuration param:
+npm config set unsafe-perm false
+
This will prevent running in unsafe mode, even as non-root users.
+Uninstalling
+So sad to see you go.
+sudo npm uninstall npm -g
+
Or, if that fails,
+sudo make uninstall
+
More Severe Uninstalling
+Usually, the above instructions are sufficient. That will remove
+npm, but leave behind anything you've installed.
+If you would like to remove all the packages that you have installed,
+then you can use the npm ls
command to find them, and then npm rm
to
+remove them.
+To remove cruft left behind by npm 0.x, you can use the included
+clean-old.sh
script file. You can run it conveniently like this:
+npm explore npm -g -- sh scripts/clean-old.sh
+
npm uses two configuration files, one for per-user configs, and another
+for global (every-user) configs. You can view them by doing:
+npm config get userconfig # defaults to ~/.npmrc
+npm config get globalconfig # defaults to /usr/local/etc/npmrc
+
Uninstalling npm does not remove configuration files by default. You
+must remove them yourself manually if you want them gone. Note that
+this means that future npm installs will not remember the settings that
+you have chosen.
+Using npm Programmatically
+If you would like to use npm programmatically, you can do that.
+It's not very well documented, but it is rather simple.
+Most of the time, unless you actually want to do all the things that
+npm does, you should try using one of npm's dependencies rather than
+using npm itself, if possible.
+Eventually, npm will be just a thin cli wrapper around the modules
+that it depends on, but for now, there are some things that you must
+use npm itself to do.
+var npm = require("npm")
+npm.load(myConfigObject, function (er) {
+ if (er) return handlError(er)
+ npm.commands.install(["some", "args"], function (er, data) {
+ if (er) return commandFailed(er)
+ // command succeeded, and data might have some info
+ })
+ npm.registry.log.on("log", function (message) { .... })
+})
+
The load
function takes an object hash of the command-line configs.
+The various npm.commands.<cmd>
functions take an array of
+positional argument strings . The last argument to any
+npm.commands.<cmd>
function is a callback. Some commands take other
+optional arguments. Read the source.
+You cannot set configs individually for any single npm function at this
+time. Since npm
is a singleton, any call to npm.config.set
will
+change the value for all npm commands in that process.
+See ./bin/npm-cli.js
for an example of pulling config values off of the
+command line arguments using nopt. You may also want to check out npm
+help config
to learn about all the options you can set there.
+More Docs
+Check out the docs ,
+especially the faq .
+You can use the npm help
command to read any of them.
+If you're a developer, and you want to use npm to publish your program,
+you should read this
+Legal Stuff
+"npm" and "The npm Registry" are owned by npm, Inc.
+All rights reserved. See the included LICENSE file for more details.
+"Node.js" and "node" are trademarks owned by Joyent, Inc.
+Modules published on the npm registry are not officially endorsed by
+npm, Inc. or the Node.js project.
+Data published to the npm registry is not part of npm itself, and is
+the sole property of the publisher. While every effort is made to
+ensure accountability, there is absolutely no guarantee, warrantee, or
+assertion expressed or implied as to the quality, fitness for a
+specific purpose, or lack of malice in any given npm package.
+If you have a complaint about a package in the public npm registry,
+and cannot resolve it with the package
+owner , please email
+support@npmjs.com and explain the situation.
+Any data published to The npm Registry (including user account
+information) may be removed or modified at the sole discretion of the
+npm server administrators.
+In plainer english
+npm is the property of npm, Inc.
+If you publish something, it's yours, and you are solely accountable
+for it.
+If other people publish something, it's theirs.
+Users can publish Bad Stuff. It will be removed promptly if reported.
+But there is no vetting process for published modules, and you use
+them at your own risk. Please inspect the source.
+If you publish Bad Stuff, we may delete it from the registry, or even
+ban your account in extreme cases. So don't do that.
+BUGS
+When you find issues, please report them:
+
+Be sure to include all of the output from the npm command that didn't work
+as expected. The npm-debug.log
file is also helpful to provide.
+You can also look for isaacs in #node.js on irc://irc.freenode.net. He
+will no doubt tell you to put the output in a gist or email.
+SEE ALSO
+
+
diff -Nru nodejs-0.11.14/deps/npm/lib/adduser.js nodejs-0.11.15/deps/npm/lib/adduser.js
--- nodejs-0.11.14/deps/npm/lib/adduser.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/adduser.js 2015-01-20 21:22:17.000000000 +0000
@@ -166,9 +166,10 @@
}
else {
npm.config.setCredentialsByURI(uri, {
- username : u.u,
- password : u.p,
- email : u.e
+ username : u.u,
+ password : u.p,
+ email : u.e,
+ alwaysAuth : npm.config.get("always-auth")
})
}
diff -Nru nodejs-0.11.14/deps/npm/lib/build.js nodejs-0.11.15/deps/npm/lib/build.js
--- nodejs-0.11.14/deps/npm/lib/build.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/build.js 2015-01-20 21:22:17.000000000 +0000
@@ -19,6 +19,8 @@
, cmdShim = require("cmd-shim")
, cmdShimIfExists = cmdShim.ifExists
, asyncMap = require("slide").asyncMap
+ , ini = require("ini")
+ , writeFile = require("write-file-atomic")
module.exports = build
build.usage = "npm build \n(this is plumbing)"
@@ -41,6 +43,7 @@
function build_ (global, didPre, didRB) { return function (folder, cb) {
folder = path.resolve(folder)
+ if (build._didBuild[folder]) log.error("build", "already built", folder)
build._didBuild[folder] = true
log.info("build", folder)
readJson(path.resolve(folder, "package.json"), function (er, pkg) {
@@ -48,7 +51,7 @@
chain
( [ !didPre && [lifecycle, pkg, "preinstall", folder]
, [linkStuff, pkg, folder, global, didRB]
- , pkg.name === "npm" && [writeBuiltinConf, folder]
+ , [writeBuiltinConf, pkg, folder]
, didPre !== build._noLC && [lifecycle, pkg, "install", folder]
, didPre !== build._noLC && [lifecycle, pkg, "postinstall", folder]
, didPre !== build._noLC
@@ -58,14 +61,21 @@
})
}}
-function writeBuiltinConf (folder, cb) {
- // the builtin config is "sticky". Any time npm installs itself,
- // it puts its builtin config file there, as well.
- if (!npm.config.usingBuiltin
- || folder !== path.dirname(__dirname)) {
+function writeBuiltinConf (pkg, folder, cb) {
+ // the builtin config is "sticky". Any time npm installs
+ // itself globally, it puts its builtin config file there
+ var parent = path.dirname(folder)
+ var dir = npm.globalDir
+
+ if (pkg.name !== "npm" ||
+ !npm.config.get("global") ||
+ !npm.config.usingBuiltin ||
+ dir !== parent) {
return cb()
}
- npm.config.save("builtin", cb)
+
+ var data = ini.stringify(npm.config.sources.builtin.data)
+ writeFile(path.resolve(folder, "npmrc"), data, cb)
}
function linkStuff (pkg, folder, global, didRB, cb) {
diff -Nru nodejs-0.11.14/deps/npm/lib/cache/add-local.js nodejs-0.11.15/deps/npm/lib/cache/add-local.js
--- nodejs-0.11.14/deps/npm/lib/cache/add-local.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/cache/add-local.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,5 +1,4 @@
-var fs = require("graceful-fs")
- , assert = require("assert")
+var assert = require("assert")
, path = require("path")
, mkdir = require("mkdirp")
, chownr = require("chownr")
@@ -9,44 +8,36 @@
, npm = require("../npm.js")
, tar = require("../utils/tar.js")
, deprCheck = require("../utils/depr-check.js")
- , locker = require("../utils/locker.js")
- , lock = locker.lock
- , unlock = locker.unlock
, getCacheStat = require("./get-stat.js")
+ , cachedPackageRoot = require("./cached-package-root.js")
, addLocalTarball = require("./add-local-tarball.js")
, sha = require("sha")
module.exports = addLocal
function addLocal (p, pkgData, cb_) {
- assert(typeof p === "string", "must have path")
+ assert(typeof p === "object", "must have spec info")
assert(typeof cb === "function", "must have callback")
pkgData = pkgData || {}
function cb (er, data) {
- unlock(p, function () {
- if (er) {
- log.error("addLocal", "Could not install %s", p)
- return cb_(er)
- }
- if (data && !data._fromGithub) {
- data._from = path.relative(npm.prefix, p) || "."
- }
- return cb_(er, data)
- })
+ if (er) {
+ log.error("addLocal", "Could not install %s", p.spec)
+ return cb_(er)
+ }
+ if (data && !data._fromGithub) {
+ data._from = path.relative(npm.prefix, p.spec) || "."
+ }
+ return cb_(er, data)
}
- lock(p, function (er) {
- if (er) return cb(er)
- // figure out if this is a folder or file.
- fs.stat(p, function (er, s) {
- if (er) return cb(er)
-
- if (s.isDirectory()) addLocalDirectory(p, pkgData, null, cb)
- else addLocalTarball(p, pkgData, null, cb)
- })
- })
+ if (p.type === "directory") {
+ addLocalDirectory(p.spec, pkgData, null, cb)
+ }
+ else {
+ addLocalTarball(p.spec, pkgData, null, cb)
+ }
}
// At this point, if shasum is set, it's something that we've already
@@ -61,30 +52,33 @@
"Adding a cache directory to the cache will make the world implode."))
readJson(path.join(p, "package.json"), false, function (er, data) {
- er = needName(er, data)
- er = needVersion(er, data)
+ if (er) return cb(er)
- // check that this is what we expected.
- if (!er && pkgData.name && pkgData.name !== data.name) {
- er = new Error( "Invalid Package: expected "
- + pkgData.name + " but found "
- + data.name )
+ if (!data.name) {
+ return cb(new Error("No name provided in package.json"))
+ }
+ else if (pkgData.name && pkgData.name !== data.name) {
+ return cb(new Error(
+ "Invalid package: expected " + pkgData.name + " but found " + data.name
+ ))
}
- if (!er && pkgData.version && pkgData.version !== data.version) {
- er = new Error( "Invalid Package: expected "
- + pkgData.name + "@" + pkgData.version
- + " but found "
- + data.name + "@" + data.version )
+ if (!data.version) {
+ return cb(new Error("No version provided in package.json"))
+ }
+ else if (pkgData.version && pkgData.version !== data.version) {
+ return cb(new Error(
+ "Invalid package: expected " + pkgData.name + "@" + pkgData.version +
+ " but found " + data.name + "@" + data.version
+ ))
}
- if (er) return cb(er)
deprCheck(data)
// pack to {cache}/name/ver/package.tgz
- var croot = path.resolve(npm.cache, data.name, data.version)
- var tgz = path.resolve(croot, "package.tgz")
- var pj = path.resolve(croot, "package/package.json")
+ var root = cachedPackageRoot(data)
+ var tgz = path.resolve(root, "package.tgz")
+ var pj = path.resolve(root, "package/package.json")
getCacheStat(function (er, cs) {
mkdir(path.dirname(pj), function (er, made) {
if (er) return cb(er)
@@ -120,15 +114,3 @@
}
})
}
-
-function needName(er, data) {
- return er ? er
- : (data && !data.name) ? new Error("No name provided")
- : null
-}
-
-function needVersion(er, data) {
- return er ? er
- : (data && !data.version) ? new Error("No version provided")
- : null
-}
diff -Nru nodejs-0.11.14/deps/npm/lib/cache/add-local-tarball.js nodejs-0.11.15/deps/npm/lib/cache/add-local-tarball.js
--- nodejs-0.11.14/deps/npm/lib/cache/add-local-tarball.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/cache/add-local-tarball.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,80 +1,52 @@
var mkdir = require("mkdirp")
, assert = require("assert")
, fs = require("graceful-fs")
- , readJson = require("read-package-json")
- , log = require("npmlog")
+ , writeFileAtomic = require("write-file-atomic")
, path = require("path")
, sha = require("sha")
, npm = require("../npm.js")
+ , log = require("npmlog")
, tar = require("../utils/tar.js")
, pathIsInside = require("path-is-inside")
- , locker = require("../utils/locker.js")
- , lock = locker.lock
- , unlock = locker.unlock
, getCacheStat = require("./get-stat.js")
+ , cachedPackageRoot = require("./cached-package-root.js")
, chownr = require("chownr")
, inflight = require("inflight")
, once = require("once")
+ , writeStream = require("fs-write-stream-atomic")
+ , randomBytes = require("crypto").pseudoRandomBytes // only need uniqueness
module.exports = addLocalTarball
-function addLocalTarball (p, pkgData, shasum, cb_) {
+function addLocalTarball (p, pkgData, shasum, cb) {
assert(typeof p === "string", "must have path")
- assert(typeof cb_ === "function", "must have callback")
+ assert(typeof cb === "function", "must have callback")
if (!pkgData) pkgData = {}
- var name = pkgData.name || ""
- // If we don't have a shasum yet, then get the shasum now.
+ // If we don't have a shasum yet, compute it.
if (!shasum) {
return sha.get(p, function (er, shasum) {
- if (er) return cb_(er)
- addLocalTarball(p, pkgData, shasum, cb_)
+ if (er) return cb(er)
+ log.silly("addLocalTarball", "shasum (computed)", shasum)
+ addLocalTarball(p, pkgData, shasum, cb)
})
}
- // if it's a tar, and not in place,
- // then unzip to .tmp, add the tmp folder, and clean up tmp
- if (pathIsInside(p, npm.tmp))
- return addTmpTarball(p, pkgData, shasum, cb_)
-
if (pathIsInside(p, npm.cache)) {
- if (path.basename(p) !== "package.tgz") return cb_(new Error(
- "Not a valid cache tarball name: "+p))
- return addPlacedTarball(p, pkgData, shasum, cb_)
+ if (path.basename(p) !== "package.tgz") {
+ return cb(new Error("Not a valid cache tarball name: "+p))
+ }
+ log.verbose("addLocalTarball", "adding from inside cache", p)
+ return addPlacedTarball(p, pkgData, shasum, cb)
}
- function cb (er, data) {
+ addTmpTarball(p, pkgData, shasum, function (er, data) {
if (data) {
data._resolved = p
data._shasum = data._shasum || shasum
}
- return cb_(er, data)
- }
-
- // just copy it over and then add the temp tarball file.
- var tmp = path.join(npm.tmp, name + Date.now()
- + "-" + Math.random(), "tmp.tgz")
- mkdir(path.dirname(tmp), function (er) {
- if (er) return cb(er)
- var from = fs.createReadStream(p)
- , to = fs.createWriteStream(tmp)
- , errState = null
- function errHandler (er) {
- if (errState) return
- return cb(errState = er)
- }
- from.on("error", errHandler)
- to.on("error", errHandler)
- to.on("close", function () {
- if (errState) return
- log.verbose("chmod", tmp, npm.modes.file.toString(8))
- fs.chmod(tmp, npm.modes.file, function (er) {
- if (er) return cb(er)
- addTmpTarball(tmp, pkgData, shasum, cb)
- })
- })
- from.pipe(to)
+ return cb(er, data)
})
}
@@ -89,10 +61,7 @@
}
function addPlacedTarball_ (p, pkgData, uid, gid, resolvedSum, cb) {
- // now we know it's in place already as .cache/name/ver/package.tgz
- var name = pkgData.name
- , version = pkgData.version
- , folder = path.join(npm.cache, name, version, "package")
+ var folder = path.join(cachedPackageRoot(pkgData), "package")
// First, make sure we have the shasum, if we don't already.
if (!resolvedSum) {
@@ -103,90 +72,85 @@
return
}
- lock(folder, function (er) {
+ mkdir(folder, function (er) {
if (er) return cb(er)
-
- // async try/finally
- var originalCb = cb
- cb = function (er, data) {
- unlock(folder, function (er2) {
- return originalCb(er || er2, data)
- })
- }
-
- mkdir(folder, function (er) {
- if (er) return cb(er)
- var pj = path.join(folder, "package.json")
- var json = JSON.stringify(pkgData, null, 2)
- fs.writeFile(pj, json, "utf8", function (er) {
- cb(er, pkgData)
- })
+ var pj = path.join(folder, "package.json")
+ var json = JSON.stringify(pkgData, null, 2)
+ writeFileAtomic(pj, json, function (er) {
+ cb(er, pkgData)
})
})
}
function addTmpTarball (tgz, pkgData, shasum, cb) {
assert(typeof cb === "function", "must have callback function")
- assert(shasum, "should have shasum by now")
+ assert(shasum, "must have shasum by now")
cb = inflight("addTmpTarball:" + tgz, cb)
- if (!cb) return
+ if (!cb) return log.verbose("addTmpTarball", tgz, "already in flight; not adding")
+ log.verbose("addTmpTarball", tgz, "not in flight; adding")
// we already have the package info, so just move into place
if (pkgData && pkgData.name && pkgData.version) {
+ log.verbose(
+ "addTmpTarball",
+ "already have metadata; skipping unpack for",
+ pkgData.name + "@" + pkgData.version
+ )
return addTmpTarball_(tgz, pkgData, shasum, cb)
}
- // This is a tarball we probably downloaded from the internet.
- // The shasum's already been checked, but we haven't ever had
- // a peek inside, so we unpack it here just to make sure it is
- // what it says it is.
- // Note: we might not have any clue what we think it is, for
- // example if the user just did `npm install ./foo.tgz`
+ // This is a tarball we probably downloaded from the internet. The shasum's
+ // already been checked, but we haven't ever had a peek inside, so we unpack
+ // it here just to make sure it is what it says it is.
+ //
+ // NOTE: we might not have any clue what we think it is, for example if the
+ // user just did `npm install ./foo.tgz`
- var target = tgz + "-unpack"
- getCacheStat(function (er, cs) {
- tar.unpack(tgz, target, null, null, cs.uid, cs.gid, next)
- })
-
- function next (er) {
+ // generate a unique filename
+ randomBytes(6, function (er, random) {
if (er) return cb(er)
- var pj = path.join(target, "package.json")
- readJson(pj, function (er, data) {
- // XXX dry with similar stanza in add-local.js
- er = needName(er, data)
- er = needVersion(er, data)
- // check that this is what we expected.
- if (!er && pkgData.name && pkgData.name !== data.name) {
- er = new Error( "Invalid Package: expected "
- + pkgData.name + " but found "
- + data.name )
- }
-
- if (!er && pkgData.version && pkgData.version !== data.version) {
- er = new Error( "Invalid Package: expected "
- + pkgData.name + "@" + pkgData.version
- + " but found "
- + data.name + "@" + data.version )
- }
+ var target = path.join(npm.tmp, "unpack-" + random.toString("hex"))
+ getCacheStat(function (er, cs) {
if (er) return cb(er)
- addTmpTarball_(tgz, data, shasum, cb)
+ log.verbose("addTmpTarball", "validating metadata from", tgz)
+ tar.unpack(tgz, target, null, null, cs.uid, cs.gid, function (er, data) {
+ if (er) return cb(er)
+
+ // check that this is what we expected.
+ if (!data.name) {
+ return cb(new Error("No name provided"))
+ }
+ else if (pkgData.name && data.name !== pkgData.name) {
+ return cb(new Error("Invalid Package: expected " + pkgData.name +
+ " but found " + data.name))
+ }
+
+ if (!data.version) {
+ return cb(new Error("No version provided"))
+ }
+ else if (pkgData.version && data.version !== pkgData.version) {
+ return cb(new Error("Invalid Package: expected " +
+ pkgData.name + "@" + pkgData.version +
+ " but found " + data.name + "@" + data.version))
+ }
+
+ addTmpTarball_(tgz, data, shasum, cb)
+ })
})
- }
+ })
}
function addTmpTarball_ (tgz, data, shasum, cb) {
assert(typeof cb === "function", "must have callback function")
cb = once(cb)
- var name = data.name
- var version = data.version
- assert(name, "should have package name by now")
- assert(version, "should have package version by now")
+ assert(data.name, "should have package name by now")
+ assert(data.version, "should have package version by now")
- var root = path.resolve(npm.cache, name, version)
+ var root = cachedPackageRoot(data)
var pkg = path.resolve(root, "package")
var target = path.resolve(root, "package.tgz")
getCacheStat(function (er, cs) {
@@ -196,13 +160,13 @@
// chown starting from the first dir created by mkdirp,
// or the root dir, if none had to be created, so that
// we know that we get all the children.
- function chown (er) {
+ function chown () {
chownr(created || root, cs.uid, cs.gid, done)
}
if (er) return cb(er)
var read = fs.createReadStream(tgz)
- var write = fs.createWriteStream(target)
+ var write = writeStream(target, { mode: npm.modes.file })
var fin = cs.uid && cs.gid ? chown : done
read.on("error", cb).pipe(write).on("error", cb).on("close", fin)
})
@@ -214,15 +178,3 @@
cb(null, data)
}
}
-
-function needName(er, data) {
- return er ? er
- : (data && !data.name) ? new Error("No name provided")
- : null
-}
-
-function needVersion(er, data) {
- return er ? er
- : (data && !data.version) ? new Error("No version provided")
- : null
-}
diff -Nru nodejs-0.11.14/deps/npm/lib/cache/add-named.js nodejs-0.11.15/deps/npm/lib/cache/add-named.js
--- nodejs-0.11.14/deps/npm/lib/cache/add-named.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/cache/add-named.js 2015-01-20 21:22:17.000000000 +0000
@@ -10,42 +10,45 @@
, registry = npm.registry
, deprCheck = require("../utils/depr-check.js")
, inflight = require("inflight")
- , locker = require("../utils/locker.js")
- , lock = locker.lock
- , unlock = locker.unlock
, addRemoteTarball = require("./add-remote-tarball.js")
+ , cachedPackageRoot = require("./cached-package-root.js")
, mapToRegistry = require("../utils/map-to-registry.js")
module.exports = addNamed
-var NAME_PREFIX = "addName:"
+function getOnceFromRegistry (name, from, next, done) {
+ mapToRegistry(name, npm.config, function (er, uri) {
+ if (er) return done(er)
+
+ var key = "registry:" + uri
+ next = inflight(key, next)
+ if (!next) return log.verbose(from, key, "already in flight; waiting")
+ else log.verbose(from, key, "not in flight; fetching")
+
+ registry.get(uri, null, next)
+ })
+}
+
function addNamed (name, version, data, cb_) {
assert(typeof name === "string", "must have module name")
assert(typeof cb_ === "function", "must have callback")
- log.verbose("addNamed", [name, version])
-
var key = name + "@" + version
+ log.verbose("addNamed", key)
+
function cb (er, data) {
if (data && !data._fromGithub) data._from = key
- unlock(key, function () { cb_(er, data) })
+ cb_(er, data)
}
- cb_ = inflight(NAME_PREFIX + key, cb_)
-
- if (!cb_) return
-
- log.verbose("addNamed", [semver.valid(version), semver.validRange(version)])
- lock(key, function (er) {
- if (er) return cb(er)
-
- var fn = ( semver.valid(version, true) ? addNameVersion
- : semver.validRange(version, true) ? addNameRange
- : addNameTag
- )
- fn(name, version, data, cb)
- })
+ log.silly("addNamed", "semver.valid", semver.valid(version))
+ log.silly("addNamed", "semver.validRange", semver.validRange(version))
+ var fn = ( semver.valid(version, true) ? addNameVersion
+ : semver.validRange(version, true) ? addNameRange
+ : addNameTag
+ )
+ fn(name, version, data, cb)
}
function addNameTag (name, tag, data, cb) {
@@ -56,17 +59,14 @@
tag = npm.config.get("tag")
}
- mapToRegistry(name, npm.config, function (er, uri) {
- if (er) return cb(er)
-
- registry.get(uri, null, next)
- })
+ getOnceFromRegistry(name, "addNameTag", next, cb)
function next (er, data, json, resp) {
- if (!er) {
- er = errorResponse(name, resp)
- }
+ if (!er) er = errorResponse(name, resp)
if (er) return cb(er)
+
+ log.silly("addNameTag", "next cb for", name, "with tag", tag)
+
engineFilter(data)
if (data["dist-tags"] && data["dist-tags"][tag]
&& data.versions[data["dist-tags"][tag]]) {
@@ -111,11 +111,7 @@
return next()
}
- mapToRegistry(name, npm.config, function (er, uri) {
- if (er) return cb(er)
-
- registry.get(uri, null, setData)
- })
+ getOnceFromRegistry(name, "addNameVersion", setData, cb)
function setData (er, d, json, resp) {
if (!er) {
@@ -147,18 +143,27 @@
}
// we got cached data, so let's see if we have a tarball.
- var pkgroot = path.join(npm.cache, name, ver)
+ var pkgroot = cachedPackageRoot({name : name, version : ver})
var pkgtgz = path.join(pkgroot, "package.tgz")
var pkgjson = path.join(pkgroot, "package", "package.json")
fs.stat(pkgtgz, function (er) {
if (!er) {
readJson(pkgjson, function (er, data) {
- er = needName(er, data)
- er = needVersion(er, data)
- if (er && er.code !== "ENOENT" && er.code !== "ENOTDIR")
- return cb(er)
+ if (er && er.code !== "ENOENT" && er.code !== "ENOTDIR") return cb(er)
+
+ if (data) {
+ if (!data.name) return cb(new Error("No name provided"))
+ if (!data.version) return cb(new Error("No version provided"))
+
+ // check the SHA of the package we have, to ensure it wasn't installed
+ // from somewhere other than the registry (eg, a fork)
+ if (data._shasum && dist.shasum && data._shasum !== dist.shasum) {
+ return fetchit()
+ }
+ }
+
if (er) return fetchit()
- return cb(null, data)
+ else return cb(null, data)
})
} else return fetchit()
})
@@ -193,17 +198,14 @@
function addNameRange (name, range, data, cb) {
range = semver.validRange(range, true)
if (range === null) return cb(new Error(
- "Invalid version range: "+range))
+ "Invalid version range: " + range
+ ))
log.silly("addNameRange", {name:name, range:range, hasData:!!data})
if (data) return next()
- mapToRegistry(name, npm.config, function (er, uri) {
- if (er) return cb(er)
-
- registry.get(uri, null, setData)
- })
+ getOnceFromRegistry(name, "addNameRange", setData, cb)
function setData (er, d, json, resp) {
if (!er) {
@@ -271,15 +273,3 @@
}
return er
}
-
-function needName(er, data) {
- return er ? er
- : (data && !data.name) ? new Error("No name provided")
- : null
-}
-
-function needVersion(er, data) {
- return er ? er
- : (data && !data.version) ? new Error("No version provided")
- : null
-}
diff -Nru nodejs-0.11.14/deps/npm/lib/cache/add-remote-git.js nodejs-0.11.15/deps/npm/lib/cache/add-remote-git.js
--- nodejs-0.11.14/deps/npm/lib/cache/add-remote-git.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/cache/add-remote-git.js 2015-01-20 21:22:17.000000000 +0000
@@ -12,11 +12,9 @@
, npm = require("../npm.js")
, rm = require("../utils/gently-rm.js")
, inflight = require("inflight")
- , locker = require("../utils/locker.js")
- , lock = locker.lock
- , unlock = locker.unlock
, getCacheStat = require("./get-stat.js")
, addLocalTarball = require("./add-local-tarball.js")
+ , writeStream = require("fs-write-stream-atomic")
// 1. cacheDir = path.join(cache,'_git-remotes',sha1(u))
@@ -26,17 +24,9 @@
// 5. git archive /tmp/random.tgz
// 6. addLocalTarball(/tmp/random.tgz) --format=tar --prefix=package/
// silent flag is used if this should error quietly
-module.exports = function addRemoteGit (u, silent, cb_) {
+module.exports = function addRemoteGit (u, silent, cb) {
assert(typeof u === "string", "must have git URL")
- assert(typeof cb_ === "function", "must have callback")
-
- function cb (er, data) {
- unlock(u, function () { cb_(er, data) })
- }
-
- cb_ = inflight(u, cb_)
-
- if (!cb_) return
+ assert(typeof cb === "function", "must have callback")
log.verbose("addRemoteGit", "u=%j silent=%j", u, silent)
var parsed = url.parse(u, true)
@@ -56,23 +46,28 @@
u = u.replace(/^ssh:\/\//, "")
}
- lock(u, function (er) {
- if (er) return cb(er)
+ cb = inflight(u, cb)
+ if (!cb) return log.verbose("addRemoteGit", u, "already in flight; waiting")
+ log.verbose("addRemoteGit", u, "not in flight; cloning")
+
+ // figure out what we should check out.
+ var co = parsed.hash && parsed.hash.substr(1) || "master"
- // figure out what we should check out.
- var co = parsed.hash && parsed.hash.substr(1) || "master"
+ var v = crypto.createHash("sha1").update(u).digest("hex").slice(0, 8)
+ v = u.replace(/[^a-zA-Z0-9]+/g, "-")+"-"+v
- var v = crypto.createHash("sha1").update(u).digest("hex").slice(0, 8)
- v = u.replace(/[^a-zA-Z0-9]+/g, "-")+"-"+v
+ log.verbose("addRemoteGit", [u, co])
- log.verbose("addRemoteGit", [u, co])
+ var p = path.join(npm.config.get("cache"), "_git-remotes", v)
- var p = path.join(npm.config.get("cache"), "_git-remotes", v)
+ // we don't need global templates when cloning. use this empty dir to specify as template dir
+ mkdir(path.join(npm.config.get("cache"), "_git-remotes", "_templates"), function (er) {
+ if (er) return cb(er)
+ checkGitDir(p, u, co, origUrl, silent, function (er, data) {
+ if (er) return cb(er, data)
- checkGitDir(p, u, co, origUrl, silent, function(er, data) {
- addModeRecursive(p, npm.modes.file, function(erAddMode) {
- if (er) return cb(er, data)
- return cb(erAddMode, data)
+ addModeRecursive(p, npm.modes.file, function (er) {
+ return cb(er, data)
})
})
})
@@ -110,7 +105,8 @@
mkdir(p, function (er) {
if (er) return cb(er)
- var args = [ "clone", "--mirror", u, p ]
+ var args = [ "clone", "--template=" + path.join(npm.config.get("cache"),
+ "_git_remotes", "_templates"), "--mirror", u, p ]
var env = gitEnv()
// check for git
@@ -146,10 +142,7 @@
}
log.verbose("git fetch -a origin ("+u+")", stdout)
tmp = path.join(npm.tmp, Date.now()+"-"+Math.random(), "tmp.tgz")
- verifyOwnership()
- })
- function verifyOwnership() {
if (process.platform === "win32") {
log.silly("verifyOwnership", "skipping for windows")
resolveHead()
@@ -168,7 +161,7 @@
})
})
}
- }
+ })
function resolveHead () {
git.whichAndExec(resolve, {cwd: p, env: env}, function (er, stdout, stderr) {
@@ -205,7 +198,7 @@
if (er) return cb(er)
var gzip = zlib.createGzip({ level: 9 })
var args = ["archive", co, "--format=tar", "--prefix=package/"]
- var out = fs.createWriteStream(tmp)
+ var out = writeStream(tmp)
var env = gitEnv()
cb = once(cb)
var cp = git.spawn(args, { env: env, cwd: p })
@@ -231,7 +224,7 @@
if (gitEnv_) return gitEnv_
gitEnv_ = {}
for (var k in process.env) {
- if (!~["GIT_PROXY_COMMAND","GIT_SSH","GIT_SSL_NO_VERIFY"].indexOf(k) && k.match(/^GIT/)) continue
+ if (!~["GIT_PROXY_COMMAND","GIT_SSH","GIT_SSL_NO_VERIFY","GIT_SSL_CAINFO"].indexOf(k) && k.match(/^GIT/)) continue
gitEnv_[k] = process.env[k]
}
return gitEnv_
@@ -261,11 +254,11 @@
}
function addMode(p, mode, cb) {
- fs.stat(p, function (er, stats) {
- if (er) return cb(er)
- mode = stats.mode | mode
- fs.chmod(p, mode, cb)
- })
+ fs.stat(p, function (er, stats) {
+ if (er) return cb(er)
+ mode = stats.mode | mode
+ fs.chmod(p, mode, cb)
+ })
}
// taken from https://github.com/isaacs/chmodr/blob/master/chmodr.js
@@ -275,4 +268,3 @@
if (mode & parseInt( "04", 8)) mode |= parseInt( "01", 8)
return mode
}
-
diff -Nru nodejs-0.11.14/deps/npm/lib/cache/add-remote-tarball.js nodejs-0.11.15/deps/npm/lib/cache/add-remote-tarball.js
--- nodejs-0.11.14/deps/npm/lib/cache/add-remote-tarball.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/cache/add-remote-tarball.js 2015-01-20 21:22:17.000000000 +0000
@@ -4,13 +4,10 @@
, path = require("path")
, sha = require("sha")
, retry = require("retry")
- , createWriteStream = require("graceful-fs").createWriteStream
+ , createWriteStream = require("fs-write-stream-atomic")
, npm = require("../npm.js")
, registry = npm.registry
, inflight = require("inflight")
- , locker = require("../utils/locker.js")
- , lock = locker.lock
- , unlock = locker.unlock
, addLocalTarball = require("./add-local-tarball.js")
, cacheFile = require("npm-cache-filename")
@@ -26,14 +23,12 @@
data._shasum = data._shasum || shasum
data._resolved = u
}
- unlock(u, function () {
- cb_(er, data)
- })
+ cb_(er, data)
}
cb_ = inflight(u, cb_)
-
- if (!cb_) return
+ if (!cb_) return log.verbose("addRemoteTarball", u, "already in flight; waiting")
+ log.verbose("addRemoteTarball", u, "not in flight; adding")
// XXX Fetch direct to cache location, store tarballs under
// ${cache}/registry.npmjs.org/pkg/-/pkg-1.2.3.tgz
@@ -44,25 +39,22 @@
addLocalTarball(tmp, pkgData, shasum, cb)
}
- lock(u, function (er) {
+ log.verbose("addRemoteTarball", [u, shasum])
+ mkdir(path.dirname(tmp), function (er) {
if (er) return cb(er)
-
- log.verbose("addRemoteTarball", [u, shasum])
- mkdir(path.dirname(tmp), function (er) {
- if (er) return cb(er)
- addRemoteTarball_(u, tmp, shasum, next)
- })
+ addRemoteTarball_(u, tmp, shasum, next)
})
}
function addRemoteTarball_(u, tmp, shasum, cb) {
// Tuned to spread 3 attempts over about a minute.
// See formula at .
- var operation = retry.operation
- ( { retries: npm.config.get("fetch-retries")
- , factor: npm.config.get("fetch-retry-factor")
- , minTimeout: npm.config.get("fetch-retry-mintimeout")
- , maxTimeout: npm.config.get("fetch-retry-maxtimeout") })
+ var operation = retry.operation({
+ retries: npm.config.get("fetch-retries")
+ , factor: npm.config.get("fetch-retry-factor")
+ , minTimeout: npm.config.get("fetch-retry-mintimeout")
+ , maxTimeout: npm.config.get("fetch-retry-maxtimeout")
+ })
operation.attempt(function (currentAttempt) {
log.info("retry", "fetch attempt " + currentAttempt
diff -Nru nodejs-0.11.14/deps/npm/lib/cache/cached-package-root.js nodejs-0.11.15/deps/npm/lib/cache/cached-package-root.js
--- nodejs-0.11.14/deps/npm/lib/cache/cached-package-root.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/cache/cached-package-root.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,14 @@
+var assert = require("assert")
+var resolve = require("path").resolve
+
+var npm = require("../npm.js")
+
+module.exports = getCacheRoot
+
+function getCacheRoot (data) {
+ assert(data, "must pass package metadata")
+ assert(data.name, "package metadata must include name")
+ assert(data.version, "package metadata must include version")
+
+ return resolve(npm.cache, data.name, data.version)
+}
diff -Nru nodejs-0.11.14/deps/npm/lib/cache/get-stat.js nodejs-0.11.15/deps/npm/lib/cache/get-stat.js
--- nodejs-0.11.14/deps/npm/lib/cache/get-stat.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/cache/get-stat.js 2015-01-20 21:22:17.000000000 +0000
@@ -10,9 +10,6 @@
module.exports = function getCacheStat (cb) {
if (cacheStat) return cb(null, cacheStat)
- cb = inflight("getCacheStat", cb)
- if (!cb) return
-
fs.stat(npm.cache, function (er, st) {
if (er) return makeCacheDir(cb)
if (!st.isDirectory()) {
@@ -24,6 +21,10 @@
}
function makeCacheDir (cb) {
+ cb = inflight("makeCacheDir", cb)
+ if (!cb) return log.verbose("getCacheStat", "cache creation already in flight; waiting")
+ log.verbose("getCacheStat", "cache creation not in flight; initializing")
+
if (!process.getuid) return mkdir(npm.cache, function (er) {
return cb(er, {})
})
diff -Nru nodejs-0.11.14/deps/npm/lib/cache.js nodejs-0.11.15/deps/npm/lib/cache.js
--- nodejs-0.11.14/deps/npm/lib/cache.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/cache.js 2015-01-20 21:22:17.000000000 +0000
@@ -62,6 +62,7 @@
var npm = require("./npm.js")
, fs = require("graceful-fs")
+ , writeFileAtomic = require("write-file-atomic")
, assert = require("assert")
, rm = require("./utils/gently-rm.js")
, readJson = require("read-package-json")
@@ -77,8 +78,10 @@
, addRemoteGit = require("./cache/add-remote-git.js")
, maybeGithub = require("./cache/maybe-github.js")
, inflight = require("inflight")
+ , realizePackageSpecifier = require("realize-package-specifier")
, npa = require("npm-package-arg")
, getStat = require("./cache/get-stat.js")
+ , cachedPackageRoot = require("./cache/cached-package-root.js")
cache.usage = "npm cache add "
+ "\nnpm cache add "
@@ -129,8 +132,11 @@
if (forceBypass === undefined || forceBypass === null) forceBypass = true
- var jsonFile = path.join(npm.cache, name, ver, "package", "package.json")
+ var root = cachedPackageRoot({name : name, version : ver})
function c (er, data) {
+ log.silly("cache", "addNamed cb", name+"@"+ver)
+ if (er) log.verbose("cache", "addNamed error for", name+"@"+ver, er)
+
if (data) deprCheck(data)
return cb(er, data)
@@ -141,15 +147,16 @@
return addNamed(name, ver, null, c)
}
- readJson(jsonFile, function (er, data) {
- er = needName(er, data)
- er = needVersion(er, data)
+ readJson(path.join(root, "package", "package.json"), function (er, data) {
if (er && er.code !== "ENOENT" && er.code !== "ENOTDIR") return cb(er)
- if (er) return addNamed(name, ver, null, c)
- deprCheck(data)
+ if (data) {
+ if (!data.name) return cb(new Error("No name provided"))
+ if (!data.version) return cb(new Error("No version provided"))
+ }
- c(er, data)
+ if (er) return addNamed(name, ver, null, c)
+ else c(er, data)
})
}
@@ -223,7 +230,6 @@
add([pkg, ver], where, cb)
})
}
- log.verbose("cache add", [pkg, ver])
return add([pkg, ver], where, cb)
}
@@ -246,7 +252,8 @@
+ " npm cache add \n"
+ " npm cache add \n"
, spec
- , p
+
+ log.silly("cache add", "args", args)
if (args[1] === undefined) args[1] = null
@@ -257,43 +264,26 @@
spec = args[0]
}
- log.verbose("cache add", "spec=%j args=%j", spec, args)
+ log.verbose("cache add", "spec", spec)
if (!spec) return cb(usage)
if (adding <= 0) {
npm.spinner.start()
}
- adding ++
+ adding++
cb = afterAdd(cb)
- // package.json can have local URI ("file:") dependencies which require
- // normalization
- p = npa(spec)
- if (p.type === "local" && where) spec = path.resolve(where, p.spec)
- log.verbose("parsed spec", p)
-
- // short-circuit local installs
- fs.stat(spec, function (er, s) {
- if (er) return addNonLocal(spec, cb)
- if (!s.isDirectory()) return addAndLogLocal(spec, cb)
- fs.stat(path.join(spec, "package.json"), function (er) {
- if (er) return addNonLocal(spec, cb)
- addAndLogLocal(spec, cb)
- })
- })
-}
+ realizePackageSpecifier(spec, where, function (err, p) {
+ if (err) return cb(err)
-function addAndLogLocal (spec, cb) {
- log.verbose("cache add", "local package", path.resolve(spec))
- return addLocal(spec, null, cb)
-}
-
-function addNonLocal (spec, cb) {
- var p = npa(spec)
- log.verbose("parsed spec", p)
+ log.silly("cache add", "parsed spec", p)
switch (p.type) {
+ case "local":
+ case "directory":
+ addLocal(p, null, cb)
+ break
case "remote":
addRemoteTarball(p.spec, {name : p.name}, null, cb)
break
@@ -308,6 +298,7 @@
cb(new Error("couldn't figure out how to install " + spec))
}
+ })
}
function unpack (pkg, ver, unpackTarget, dMode, fMode, uid, gid, cb) {
@@ -323,7 +314,7 @@
}
npm.commands.unbuild([unpackTarget], true, function (er) {
if (er) return cb(er)
- tar.unpack( path.join(npm.cache, pkg, ver, "package.tgz")
+ tar.unpack( path.join(cachedPackageRoot({name : pkg, version : ver}), "package.tgz")
, unpackTarget
, dMode, fMode
, uid, gid
@@ -333,50 +324,25 @@
}
function afterAdd (cb) { return function (er, data) {
- adding --
- if (adding <= 0) {
- npm.spinner.stop()
- }
- if (er || !data || !data.name || !data.version) {
- return cb(er, data)
- }
+ adding--
+ if (adding <= 0) npm.spinner.stop()
+
+ if (er || !data || !data.name || !data.version) return cb(er, data)
+ log.silly("cache", "afterAdd", data.name+"@"+data.version)
// Save the resolved, shasum, etc. into the data so that the next
// time we load from this cached data, we have all the same info.
- var name = data.name
- var ver = data.version
- var pj = path.join(npm.cache, name, ver, "package", "package.json")
- var tmp = pj + "." + process.pid
+ var pj = path.join(cachedPackageRoot(data), "package", "package.json")
var done = inflight(pj, cb)
+ if (!done) return log.verbose("afterAdd", pj, "already in flight; not writing")
+ log.verbose("afterAdd", pj, "not in flight; writing")
- if (!done) return undefined
-
- fs.writeFile(tmp, JSON.stringify(data), "utf8", function (er) {
+ getStat(function (er, cs) {
if (er) return done(er)
- getStat(function (er, cs) {
- if (er) return done(er)
- fs.rename(tmp, pj, function (er) {
- if (cs.uid && cs.gid) {
- fs.chown(pj, cs.uid, cs.gid, function (er) {
- return done(er, data)
- })
- } else {
- done(er, data)
- }
- })
+ writeFileAtomic(pj, JSON.stringify(data), {chown : cs}, function (er) {
+ if (!er) log.verbose("afterAdd", pj, "written")
+ return done(er, data)
})
})
}}
-
-function needName (er, data) {
- return er ? er
- : (data && !data.name) ? new Error("No name provided")
- : null
-}
-
-function needVersion (er, data) {
- return er ? er
- : (data && !data.version) ? new Error("No version provided")
- : null
-}
diff -Nru nodejs-0.11.14/deps/npm/lib/completion.js nodejs-0.11.15/deps/npm/lib/completion.js
--- nodejs-0.11.14/deps/npm/lib/completion.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/completion.js 2015-01-20 21:22:17.000000000 +0000
@@ -6,7 +6,7 @@
+ "source <(npm completion)"
var npm = require("./npm.js")
- , npmconf = require("npmconf")
+ , npmconf = require("./config/core.js")
, configDefs = npmconf.defs
, configTypes = configDefs.types
, shorthands = configDefs.shorthands
@@ -229,7 +229,7 @@
// expand with the valid values of various config values.
// not yet implemented.
function configValueCompl (opts, cb) {
- console.error('configValue', opts)
+ console.error("configValue", opts)
return cb(null, [])
}
diff -Nru nodejs-0.11.14/deps/npm/lib/config/core.js nodejs-0.11.15/deps/npm/lib/config/core.js
--- nodejs-0.11.14/deps/npm/lib/config/core.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/config/core.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,427 @@
+
+var CC = require("config-chain").ConfigChain
+var inherits = require("inherits")
+var configDefs = require("./defaults.js")
+var types = configDefs.types
+var once = require("once")
+var fs = require("fs")
+var path = require("path")
+var nopt = require("nopt")
+var ini = require("ini")
+var Octal = configDefs.Octal
+var mkdirp = require("mkdirp")
+
+exports.load = load
+exports.Conf = Conf
+exports.loaded = false
+exports.rootConf = null
+exports.usingBuiltin = false
+exports.defs = configDefs
+
+Object.defineProperty(exports, "defaults", { get: function () {
+ return configDefs.defaults
+}, enumerable: true })
+
+Object.defineProperty(exports, "types", { get: function () {
+ return configDefs.types
+}, enumerable: true })
+
+exports.validate = validate
+
+var myUid = process.env.SUDO_UID !== undefined
+ ? process.env.SUDO_UID : (process.getuid && process.getuid())
+var myGid = process.env.SUDO_GID !== undefined
+ ? process.env.SUDO_GID : (process.getgid && process.getgid())
+
+
+var loading = false
+var loadCbs = []
+function load () {
+ var cli, builtin, cb
+ for (var i = 0; i < arguments.length; i++)
+ switch (typeof arguments[i]) {
+ case "string": builtin = arguments[i]; break
+ case "object": cli = arguments[i]; break
+ case "function": cb = arguments[i]; break
+ }
+
+ if (!cb)
+ cb = function () {}
+
+ if (exports.loaded) {
+ var ret = exports.loaded
+ if (cli) {
+ ret = new Conf(ret)
+ ret.unshift(cli)
+ }
+ return process.nextTick(cb.bind(null, null, ret))
+ }
+
+ // either a fresh object, or a clone of the passed in obj
+ if (!cli)
+ cli = {}
+ else
+ cli = Object.keys(cli).reduce(function (c, k) {
+ c[k] = cli[k]
+ return c
+ }, {})
+
+ loadCbs.push(cb)
+ if (loading)
+ return
+
+ loading = true
+
+ cb = once(function (er, conf) {
+ if (!er)
+ exports.loaded = conf
+ loadCbs.forEach(function (fn) {
+ fn(er, conf)
+ })
+ loadCbs.length = 0
+ })
+
+ // check for a builtin if provided.
+ exports.usingBuiltin = !!builtin
+ var rc = exports.rootConf = new Conf()
+ if (builtin)
+ rc.addFile(builtin, "builtin")
+ else
+ rc.add({}, "builtin")
+
+ rc.on("load", function () {
+ load_(builtin, rc, cli, cb)
+ })
+ rc.on("error", cb)
+}
+
+function load_(builtin, rc, cli, cb) {
+ var defaults = configDefs.defaults
+ var conf = new Conf(rc)
+
+ conf.usingBuiltin = !!builtin
+ conf.add(cli, "cli")
+ conf.addEnv()
+
+ conf.loadPrefix(function(er) {
+ if (er)
+ return cb(er)
+
+ // If you're doing `npm --userconfig=~/foo.npmrc` then you'd expect
+ // that ~/.npmrc won't override the stuff in ~/foo.npmrc (or, indeed
+ // be used at all).
+ //
+ // However, if the cwd is ~, then ~/.npmrc is the home for the project
+ // config, and will override the userconfig.
+ //
+ // If you're not setting the userconfig explicitly, then it will be loaded
+ // twice, which is harmless but excessive. If you *are* setting the
+ // userconfig explicitly then it will override your explicit intent, and
+ // that IS harmful and unexpected.
+ //
+ // Solution: Do not load project config file that is the same as either
+ // the default or resolved userconfig value. npm will log a "verbose"
+ // message about this when it happens, but it is a rare enough edge case
+ // that we don't have to be super concerned about it.
+ var projectConf = path.resolve(conf.localPrefix, ".npmrc")
+ var defaultUserConfig = rc.get("userconfig")
+ var resolvedUserConfig = conf.get("userconfig")
+ if (!conf.get("global") &&
+ projectConf !== defaultUserConfig &&
+ projectConf !== resolvedUserConfig) {
+ conf.addFile(projectConf, "project")
+ conf.once("load", afterPrefix)
+ } else {
+ conf.add({}, "project")
+ afterPrefix()
+ }
+ })
+
+ function afterPrefix() {
+ conf.addFile(conf.get("userconfig"), "user")
+ conf.once("error", cb)
+ conf.once("load", afterUser)
+ }
+
+ function afterUser () {
+ // globalconfig and globalignorefile defaults
+ // need to respond to the 'prefix' setting up to this point.
+ // Eg, `npm config get globalconfig --prefix ~/local` should
+ // return `~/local/etc/npmrc`
+ // annoying humans and their expectations!
+ if (conf.get("prefix")) {
+ var etc = path.resolve(conf.get("prefix"), "etc")
+ defaults.globalconfig = path.resolve(etc, "npmrc")
+ defaults.globalignorefile = path.resolve(etc, "npmignore")
+ }
+
+ conf.addFile(conf.get("globalconfig"), "global")
+
+ // move the builtin into the conf stack now.
+ conf.root = defaults
+ conf.add(rc.shift(), "builtin")
+ conf.once("load", function () {
+ conf.loadExtras(afterExtras)
+ })
+ }
+
+ function afterExtras(er) {
+ if (er)
+ return cb(er)
+
+ // warn about invalid bits.
+ validate(conf)
+
+ var cafile = conf.get("cafile")
+
+ if (cafile) {
+ return conf.loadCAFile(cafile, finalize)
+ }
+
+ finalize()
+ }
+
+ function finalize(er) {
+ if (er) {
+ return cb(er)
+ }
+
+ exports.loaded = conf
+ cb(er, conf)
+ }
+}
+
+// Basically the same as CC, but:
+// 1. Always ini
+// 2. Parses environment variable names in field values
+// 3. Field values that start with ~/ are replaced with process.env.HOME
+// 4. Can inherit from another Conf object, using it as the base.
+inherits(Conf, CC)
+function Conf (base) {
+ if (!(this instanceof Conf))
+ return new Conf(base)
+
+ CC.apply(this)
+
+ if (base)
+ if (base instanceof Conf)
+ this.root = base.list[0] || base.root
+ else
+ this.root = base
+ else
+ this.root = configDefs.defaults
+}
+
+Conf.prototype.loadPrefix = require("./load-prefix.js")
+Conf.prototype.loadCAFile = require("./load-cafile.js")
+Conf.prototype.loadUid = require("./load-uid.js")
+Conf.prototype.setUser = require("./set-user.js")
+Conf.prototype.findPrefix = require("./find-prefix.js")
+Conf.prototype.getCredentialsByURI = require("./get-credentials-by-uri.js")
+Conf.prototype.setCredentialsByURI = require("./set-credentials-by-uri.js")
+
+Conf.prototype.loadExtras = function(cb) {
+ this.setUser(function(er) {
+ if (er)
+ return cb(er)
+ this.loadUid(function(er) {
+ if (er)
+ return cb(er)
+ // Without prefix, nothing will ever work
+ mkdirp(this.prefix, cb)
+ }.bind(this))
+ }.bind(this))
+}
+
+Conf.prototype.save = function (where, cb) {
+ var target = this.sources[where]
+ if (!target || !(target.path || target.source) || !target.data) {
+ if (where !== "builtin")
+ var er = new Error("bad save target: " + where)
+ if (cb) {
+ process.nextTick(cb.bind(null, er))
+ return this
+ }
+ return this.emit("error", er)
+ }
+
+ if (target.source) {
+ var pref = target.prefix || ""
+ Object.keys(target.data).forEach(function (k) {
+ target.source[pref + k] = target.data[k]
+ })
+ if (cb) process.nextTick(cb)
+ return this
+ }
+
+ var data = ini.stringify(target.data)
+
+ then = then.bind(this)
+ done = done.bind(this)
+ this._saving ++
+
+ var mode = where === "user" ? "0600" : "0666"
+ if (!data.trim()) {
+ fs.unlink(target.path, function () {
+ // ignore the possible error (e.g. the file doesn't exist)
+ done(null)
+ })
+ } else {
+ mkdirp(path.dirname(target.path), function (er) {
+ if (er)
+ return then(er)
+ fs.writeFile(target.path, data, "utf8", function (er) {
+ if (er)
+ return then(er)
+ if (where === "user" && myUid && myGid)
+ fs.chown(target.path, +myUid, +myGid, then)
+ else
+ then()
+ })
+ })
+ }
+
+ function then (er) {
+ if (er)
+ return done(er)
+ fs.chmod(target.path, mode, done)
+ }
+
+ function done (er) {
+ if (er) {
+ if (cb) return cb(er)
+ else return this.emit("error", er)
+ }
+ this._saving --
+ if (this._saving === 0) {
+ if (cb) cb()
+ this.emit("save")
+ }
+ }
+
+ return this
+}
+
+Conf.prototype.addFile = function (file, name) {
+ name = name || file
+ var marker = {__source__:name}
+ this.sources[name] = { path: file, type: "ini" }
+ this.push(marker)
+ this._await()
+ fs.readFile(file, "utf8", function (er, data) {
+ if (er) // just ignore missing files.
+ return this.add({}, marker)
+ this.addString(data, file, "ini", marker)
+ }.bind(this))
+ return this
+}
+
+// always ini files.
+Conf.prototype.parse = function (content, file) {
+ return CC.prototype.parse.call(this, content, file, "ini")
+}
+
+Conf.prototype.add = function (data, marker) {
+ try {
+ Object.keys(data).forEach(function (k) {
+ data[k] = parseField(data[k], k)
+ })
+ }
+ catch (e) {
+ this.emit("error", e)
+ return this
+ }
+ return CC.prototype.add.call(this, data, marker)
+}
+
+Conf.prototype.addEnv = function (env) {
+ env = env || process.env
+ var conf = {}
+ Object.keys(env)
+ .filter(function (k) { return k.match(/^npm_config_/i) })
+ .forEach(function (k) {
+ if (!env[k])
+ return
+
+ // leave first char untouched, even if
+ // it is a "_" - convert all other to "-"
+ var p = k.toLowerCase()
+ .replace(/^npm_config_/, "")
+ .replace(/(?!^)_/g, "-")
+ conf[p] = env[k]
+ })
+ return CC.prototype.addEnv.call(this, "", conf, "env")
+}
+
+function parseField (f, k) {
+ if (typeof f !== "string" && !(f instanceof String))
+ return f
+
+ // type can be an array or single thing.
+ var typeList = [].concat(types[k])
+ var isPath = -1 !== typeList.indexOf(path)
+ var isBool = -1 !== typeList.indexOf(Boolean)
+ var isString = -1 !== typeList.indexOf(String)
+ var isOctal = -1 !== typeList.indexOf(Octal)
+ var isNumber = isOctal || (-1 !== typeList.indexOf(Number))
+
+ f = (""+f).trim()
+
+ if (f.match(/^".*"$/)) {
+ try {
+ f = JSON.parse(f)
+ }
+ catch (e) {
+ throw new Error("Failed parsing JSON config key " + k + ": " + f)
+ }
+ }
+
+ if (isBool && !isString && f === "")
+ return true
+
+ switch (f) {
+ case "true": return true
+ case "false": return false
+ case "null": return null
+ case "undefined": return undefined
+ }
+
+ f = envReplace(f)
+
+ if (isPath) {
+ var homePattern = process.platform === "win32" ? /^~(\/|\\)/ : /^~\//
+ if (f.match(homePattern) && process.env.HOME) {
+ f = path.resolve(process.env.HOME, f.substr(2))
+ }
+ f = path.resolve(f)
+ }
+
+ if (isNumber && !isNaN(f))
+ f = isOctal ? parseInt(f, 8) : +f
+
+ return f
+}
+
+function envReplace (f) {
+ if (typeof f !== "string" || !f) return f
+
+ // replace any ${ENV} values with the appropriate environ.
+ var envExpr = /(\\*)\$\{([^}]+)\}/g
+ return f.replace(envExpr, function (orig, esc, name) {
+ esc = esc.length && esc.length % 2
+ if (esc)
+ return orig
+ if (undefined === process.env[name])
+ throw new Error("Failed to replace env in config: "+orig)
+ return process.env[name]
+ })
+}
+
+function validate (cl) {
+ // warn about invalid configs at every level.
+ cl.list.forEach(function (conf) {
+ nopt.clean(conf, configDefs.types)
+ })
+
+ nopt.clean(cl.root, configDefs.types)
+}
diff -Nru nodejs-0.11.14/deps/npm/lib/config/defaults.js nodejs-0.11.15/deps/npm/lib/config/defaults.js
--- nodejs-0.11.14/deps/npm/lib/config/defaults.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/config/defaults.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,383 @@
+// defaults, types, and shorthands.
+
+
+var path = require("path")
+ , url = require("url")
+ , Stream = require("stream").Stream
+ , semver = require("semver")
+ , stableFamily = semver.parse(process.version)
+ , nopt = require("nopt")
+ , os = require("os")
+ , osenv = require("osenv")
+
+var log
+try {
+ log = require("npmlog")
+} catch (er) {
+ var util = require("util")
+ log = { warn: function (m) {
+ console.warn(m + " " + util.format.apply(util, [].slice.call(arguments, 1)))
+ } }
+}
+
+exports.Octal = Octal
+function Octal () {}
+function validateOctal (data, k, val) {
+ // must be either an integer or an octal string.
+ if (typeof val === "number") {
+ data[k] = val
+ return true
+ }
+
+ if (typeof val === "string") {
+ if (val.charAt(0) !== "0" || isNaN(val)) return false
+ data[k] = parseInt(val, 8).toString(8)
+ }
+}
+
+function validateSemver (data, k, val) {
+ if (!semver.valid(val)) return false
+ data[k] = semver.valid(val)
+}
+
+function validateTag (data, k, val) {
+ val = ("" + val).trim()
+ if (!val || semver.validRange(val)) return false
+ data[k] = val
+}
+
+function validateStream (data, k, val) {
+ if (!(val instanceof Stream)) return false
+ data[k] = val
+}
+
+nopt.typeDefs.semver = { type: semver, validate: validateSemver }
+nopt.typeDefs.Octal = { type: Octal, validate: validateOctal }
+nopt.typeDefs.Stream = { type: Stream, validate: validateStream }
+
+// Don't let --tag=1.2.3 ever be a thing
+var tag = {}
+nopt.typeDefs.tag = { type: tag, validate: validateTag }
+
+nopt.invalidHandler = function (k, val, type) {
+ log.warn("invalid config", k + "=" + JSON.stringify(val))
+
+ if (Array.isArray(type)) {
+ if (type.indexOf(url) !== -1) type = url
+ else if (type.indexOf(path) !== -1) type = path
+ }
+
+ switch (type) {
+ case tag:
+ log.warn("invalid config", "Tag must not be a SemVer range")
+ break
+ case Octal:
+ log.warn("invalid config", "Must be octal number, starting with 0")
+ break
+ case url:
+ log.warn("invalid config", "Must be a full url with 'http://'")
+ break
+ case path:
+ log.warn("invalid config", "Must be a valid filesystem path")
+ break
+ case Number:
+ log.warn("invalid config", "Must be a numeric value")
+ break
+ case Stream:
+ log.warn("invalid config", "Must be an instance of the Stream class")
+ break
+ }
+}
+
+if (!stableFamily || (+stableFamily.minor % 2)) stableFamily = null
+else stableFamily = stableFamily.major + "." + stableFamily.minor
+
+var defaults
+
+var temp = osenv.tmpdir()
+var home = osenv.home()
+
+var uidOrPid = process.getuid ? process.getuid() : process.pid
+
+if (home) process.env.HOME = home
+else home = path.resolve(temp, "npm-" + uidOrPid)
+
+var cacheExtra = process.platform === "win32" ? "npm-cache" : ".npm"
+var cacheRoot = process.platform === "win32" && process.env.APPDATA || home
+var cache = path.resolve(cacheRoot, cacheExtra)
+
+
+var globalPrefix
+Object.defineProperty(exports, "defaults", {get: function () {
+ if (defaults) return defaults
+
+ if (process.env.PREFIX) {
+ globalPrefix = process.env.PREFIX
+ } else if (process.platform === "win32") {
+ // c:\node\node.exe --> prefix=c:\node\
+ globalPrefix = path.dirname(process.execPath)
+ } else {
+ // /usr/local/bin/node --> prefix=/usr/local
+ globalPrefix = path.dirname(path.dirname(process.execPath))
+
+ // destdir only is respected on Unix
+ if (process.env.DESTDIR) {
+ globalPrefix = path.join(process.env.DESTDIR, globalPrefix)
+ }
+ }
+
+ defaults = {
+ "always-auth" : false
+ , "bin-links" : true
+ , browser : null
+
+ , ca: null
+ , cafile: null
+
+ , cache : cache
+
+ , "cache-lock-stale": 60000
+ , "cache-lock-retries": 10
+ , "cache-lock-wait": 10000
+
+ , "cache-max": Infinity
+ , "cache-min": 10
+
+ , cert: null
+
+ , color : true
+ , depth: Infinity
+ , description : true
+ , dev : false
+ , editor : osenv.editor()
+ , "engine-strict": false
+ , force : false
+
+ , "fetch-retries": 2
+ , "fetch-retry-factor": 10
+ , "fetch-retry-mintimeout": 10000
+ , "fetch-retry-maxtimeout": 60000
+
+ , git: "git"
+ , "git-tag-version": true
+
+ , global : false
+ , globalconfig : path.resolve(globalPrefix, "etc", "npmrc")
+ , group : process.platform === "win32" ? 0
+ : process.env.SUDO_GID || (process.getgid && process.getgid())
+ , heading: "npm"
+ , "ignore-scripts": false
+ , "init-module": path.resolve(home, ".npm-init.js")
+ , "init-author-name" : ""
+ , "init-author-email" : ""
+ , "init-author-url" : ""
+ , "init-version": "1.0.0"
+ , "init-license": "ISC"
+ , json: false
+ , key: null
+ , link: false
+ , "local-address" : undefined
+ , loglevel : "warn"
+ , logstream : process.stderr
+ , long : false
+ , message : "%s"
+ , "node-version" : process.version
+ , npat : false
+ , "onload-script" : false
+ , optional: true
+ , parseable : false
+ , prefix : globalPrefix
+ , production: process.env.NODE_ENV === "production"
+ , "proprietary-attribs": true
+ , proxy : process.env.HTTP_PROXY || process.env.http_proxy || null
+ , "https-proxy" : process.env.HTTPS_PROXY || process.env.https_proxy ||
+ process.env.HTTP_PROXY || process.env.http_proxy || null
+ , "user-agent" : "npm/{npm-version} "
+ + "node/{node-version} "
+ + "{platform} "
+ + "{arch}"
+ , "rebuild-bundle" : true
+ , registry : "https://registry.npmjs.org/"
+ , rollback : true
+ , save : false
+ , "save-bundle": false
+ , "save-dev" : false
+ , "save-exact" : false
+ , "save-optional" : false
+ , "save-prefix": "^"
+ , scope : ""
+ , searchopts: ""
+ , searchexclude: null
+ , searchsort: "name"
+ , shell : osenv.shell()
+ , shrinkwrap: true
+ , "sign-git-tag": false
+ , spin: true
+ , "strict-ssl": true
+ , tag : "latest"
+ , tmp : temp
+ , unicode : true
+ , "unsafe-perm" : process.platform === "win32"
+ || process.platform === "cygwin"
+ || !( process.getuid && process.setuid
+ && process.getgid && process.setgid )
+ || process.getuid() !== 0
+ , usage : false
+ , user : process.platform === "win32" ? 0 : "nobody"
+ , userconfig : path.resolve(home, ".npmrc")
+ , umask: process.umask ? process.umask() : parseInt("022", 8)
+ , version : false
+ , versions : false
+ , viewer: process.platform === "win32" ? "browser" : "man"
+
+ , _exit : true
+ }
+
+ return defaults
+}})
+
+exports.types =
+ { "always-auth" : Boolean
+ , "bin-links": Boolean
+ , browser : [null, String]
+ , ca: [null, String, Array]
+ , cafile : path
+ , cache : path
+ , "cache-lock-stale": Number
+ , "cache-lock-retries": Number
+ , "cache-lock-wait": Number
+ , "cache-max": Number
+ , "cache-min": Number
+ , cert: [null, String]
+ , color : ["always", Boolean]
+ , depth : Number
+ , description : Boolean
+ , dev : Boolean
+ , editor : String
+ , "engine-strict": Boolean
+ , force : Boolean
+ , "fetch-retries": Number
+ , "fetch-retry-factor": Number
+ , "fetch-retry-mintimeout": Number
+ , "fetch-retry-maxtimeout": Number
+ , git: String
+ , "git-tag-version": Boolean
+ , global : Boolean
+ , globalconfig : path
+ , group : [Number, String]
+ , "https-proxy" : [null, url]
+ , "user-agent" : String
+ , "heading": String
+ , "ignore-scripts": Boolean
+ , "init-module": path
+ , "init-author-name" : String
+ , "init-author-email" : String
+ , "init-author-url" : ["", url]
+ , "init-license": String
+ , "init-version": semver
+ , json: Boolean
+ , key: [null, String]
+ , link: Boolean
+ // local-address must be listed as an IP for a local network interface
+ // must be IPv4 due to node bug
+ , "local-address" : getLocalAddresses()
+ , loglevel : ["silent","error","warn","http","info","verbose","silly"]
+ , logstream : Stream
+ , long : Boolean
+ , message: String
+ , "node-version" : [null, semver]
+ , npat : Boolean
+ , "onload-script" : [null, String]
+ , optional: Boolean
+ , parseable : Boolean
+ , prefix: path
+ , production: Boolean
+ , "proprietary-attribs": Boolean
+ , proxy : [null, url]
+ , "rebuild-bundle" : Boolean
+ , registry : [null, url]
+ , rollback : Boolean
+ , save : Boolean
+ , "save-bundle": Boolean
+ , "save-dev" : Boolean
+ , "save-exact" : Boolean
+ , "save-optional" : Boolean
+ , "save-prefix": String
+ , scope : String
+ , searchopts : String
+ , searchexclude: [null, String]
+ , searchsort: [ "name", "-name"
+ , "description", "-description"
+ , "author", "-author"
+ , "date", "-date"
+ , "keywords", "-keywords" ]
+ , shell : String
+ , shrinkwrap: Boolean
+ , "sign-git-tag": Boolean
+ , spin: ["always", Boolean]
+ , "strict-ssl": Boolean
+ , tag : tag
+ , tmp : path
+ , unicode : Boolean
+ , "unsafe-perm" : Boolean
+ , usage : Boolean
+ , user : [Number, String]
+ , userconfig : path
+ , umask: Octal
+ , version : Boolean
+ , versions : Boolean
+ , viewer: String
+ , _exit : Boolean
+ }
+
+function getLocalAddresses() {
+ Object.keys(os.networkInterfaces()).map(function (nic) {
+ return os.networkInterfaces()[nic].filter(function (addr) {
+ return addr.family === "IPv4"
+ })
+ .map(function (addr) {
+ return addr.address
+ })
+ }).reduce(function (curr, next) {
+ return curr.concat(next)
+ }, []).concat(undefined)
+}
+
+exports.shorthands =
+ { s : ["--loglevel", "silent"]
+ , d : ["--loglevel", "info"]
+ , dd : ["--loglevel", "verbose"]
+ , ddd : ["--loglevel", "silly"]
+ , noreg : ["--no-registry"]
+ , N : ["--no-registry"]
+ , reg : ["--registry"]
+ , "no-reg" : ["--no-registry"]
+ , silent : ["--loglevel", "silent"]
+ , verbose : ["--loglevel", "verbose"]
+ , quiet: ["--loglevel", "warn"]
+ , q: ["--loglevel", "warn"]
+ , h : ["--usage"]
+ , H : ["--usage"]
+ , "?" : ["--usage"]
+ , help : ["--usage"]
+ , v : ["--version"]
+ , f : ["--force"]
+ , gangster : ["--force"]
+ , gangsta : ["--force"]
+ , desc : ["--description"]
+ , "no-desc" : ["--no-description"]
+ , "local" : ["--no-global"]
+ , l : ["--long"]
+ , m : ["--message"]
+ , p : ["--parseable"]
+ , porcelain : ["--parseable"]
+ , g : ["--global"]
+ , S : ["--save"]
+ , D : ["--save-dev"]
+ , E : ["--save-exact"]
+ , O : ["--save-optional"]
+ , y : ["--yes"]
+ , n : ["--no-yes"]
+ , B : ["--save-bundle"]
+ , C : ["--prefix"]
+ }
diff -Nru nodejs-0.11.14/deps/npm/lib/config/find-prefix.js nodejs-0.11.15/deps/npm/lib/config/find-prefix.js
--- nodejs-0.11.14/deps/npm/lib/config/find-prefix.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/config/find-prefix.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,56 @@
+// try to find the most reasonable prefix to use
+
+module.exports = findPrefix
+
+var fs = require("fs")
+var path = require("path")
+
+function findPrefix (p, cb_) {
+ function cb (er, p) {
+ process.nextTick(function () {
+ cb_(er, p)
+ })
+ }
+
+ p = path.resolve(p)
+ // if there's no node_modules folder, then
+ // walk up until we hopefully find one.
+ // if none anywhere, then use cwd.
+ var walkedUp = false
+ while (path.basename(p) === "node_modules") {
+ p = path.dirname(p)
+ walkedUp = true
+ }
+ if (walkedUp) return cb(null, p)
+
+ findPrefix_(p, p, cb)
+}
+
+function findPrefix_ (p, original, cb) {
+ if (p === "/"
+ || (process.platform === "win32" && p.match(/^[a-zA-Z]:(\\|\/)?$/))) {
+ return cb(null, original)
+ }
+ fs.readdir(p, function (er, files) {
+ // an error right away is a bad sign.
+ // unless the prefix was simply a non
+ // existent directory.
+ if (er && p === original) {
+ if (er.code === "ENOENT") return cb(null, original);
+ return cb(er)
+ }
+
+ // walked up too high or something.
+ if (er) return cb(null, original)
+
+ if (files.indexOf("node_modules") !== -1
+ || files.indexOf("package.json") !== -1) {
+ return cb(null, p)
+ }
+
+ var d = path.dirname(p)
+ if (d === p) return cb(null, original)
+
+ return findPrefix_(d, original, cb)
+ })
+}
diff -Nru nodejs-0.11.14/deps/npm/lib/config/get-credentials-by-uri.js nodejs-0.11.15/deps/npm/lib/config/get-credentials-by-uri.js
--- nodejs-0.11.14/deps/npm/lib/config/get-credentials-by-uri.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/config/get-credentials-by-uri.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,73 @@
+var assert = require("assert")
+
+var toNerfDart = require("./nerf-dart.js")
+
+module.exports = getCredentialsByURI
+
+function getCredentialsByURI (uri) {
+ assert(uri && typeof uri === "string", "registry URL is required")
+ var nerfed = toNerfDart(uri)
+ var defnerf = toNerfDart(this.get("registry"))
+
+ // hidden class micro-optimization
+ var c = {
+ scope : nerfed,
+ token : undefined,
+ password : undefined,
+ username : undefined,
+ email : undefined,
+ auth : undefined,
+ alwaysAuth : undefined
+ }
+
+ if (this.get(nerfed + ":_authToken")) {
+ c.token = this.get(nerfed + ":_authToken")
+ // the bearer token is enough, don't confuse things
+ return c
+ }
+
+ // Handle the old-style _auth= style for the default
+ // registry, if set.
+ //
+ // XXX(isaacs): Remove when npm 1.4 is no longer relevant
+ var authDef = this.get("_auth")
+ var userDef = this.get("username")
+ var passDef = this.get("_password")
+ if (authDef && !(userDef && passDef)) {
+ authDef = new Buffer(authDef, "base64").toString()
+ authDef = authDef.split(":")
+ userDef = authDef.shift()
+ passDef = authDef.join(":")
+ }
+
+ if (this.get(nerfed + ":_password")) {
+ c.password = new Buffer(this.get(nerfed + ":_password"), "base64").toString("utf8")
+ } else if (nerfed === defnerf && passDef) {
+ c.password = passDef
+ }
+
+ if (this.get(nerfed + ":username")) {
+ c.username = this.get(nerfed + ":username")
+ } else if (nerfed === defnerf && userDef) {
+ c.username = userDef
+ }
+
+ if (this.get(nerfed + ":email")) {
+ c.email = this.get(nerfed + ":email")
+ } else if (this.get("email")) {
+ c.email = this.get("email")
+ }
+
+ if (this.get(nerfed + ":always-auth") !== undefined) {
+ var val = this.get(nerfed + ":always-auth")
+ c.alwaysAuth = val === "false" ? false : !!val
+ } else if (this.get("always-auth") !== undefined) {
+ c.alwaysAuth = this.get("always-auth")
+ }
+
+ if (c.username && c.password) {
+ c.auth = new Buffer(c.username + ":" + c.password).toString("base64")
+ }
+
+ return c
+}
diff -Nru nodejs-0.11.14/deps/npm/lib/config/load-cafile.js nodejs-0.11.15/deps/npm/lib/config/load-cafile.js
--- nodejs-0.11.14/deps/npm/lib/config/load-cafile.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/config/load-cafile.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,30 @@
+module.exports = loadCAFile
+
+var fs = require("fs")
+
+function loadCAFile(cafilePath, cb) {
+ if (!cafilePath)
+ return process.nextTick(cb)
+
+ fs.readFile(cafilePath, "utf8", afterCARead.bind(this))
+
+ function afterCARead(er, cadata) {
+ if (er)
+ return cb(er)
+
+ var delim = "-----END CERTIFICATE-----"
+ var output
+
+ output = cadata
+ .split(delim)
+ .filter(function(xs) {
+ return !!xs.trim()
+ })
+ .map(function(xs) {
+ return xs.trimLeft() + delim
+ })
+
+ this.set("ca", output)
+ cb(null)
+ }
+}
diff -Nru nodejs-0.11.14/deps/npm/lib/config/load-prefix.js nodejs-0.11.15/deps/npm/lib/config/load-prefix.js
--- nodejs-0.11.14/deps/npm/lib/config/load-prefix.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/config/load-prefix.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,49 @@
+module.exports = loadPrefix
+
+var findPrefix = require("./find-prefix.js")
+var path = require("path")
+
+function loadPrefix (cb) {
+ var cli = this.list[0]
+
+ Object.defineProperty(this, "prefix",
+ { set : function (prefix) {
+ var g = this.get("global")
+ this[g ? "globalPrefix" : "localPrefix"] = prefix
+ }.bind(this)
+ , get : function () {
+ var g = this.get("global")
+ return g ? this.globalPrefix : this.localPrefix
+ }.bind(this)
+ , enumerable : true
+ })
+
+ Object.defineProperty(this, "globalPrefix",
+ { set : function (prefix) {
+ this.set("prefix", prefix)
+ }.bind(this)
+ , get : function () {
+ return path.resolve(this.get("prefix"))
+ }.bind(this)
+ , enumerable : true
+ })
+
+ var p
+ Object.defineProperty(this, "localPrefix",
+ { set : function (prefix) { p = prefix },
+ get : function () { return p }
+ , enumerable: true })
+
+ // try to guess at a good node_modules location.
+ // If we are *explicitly* given a prefix on the cli, then
+ // always use that. otherwise, infer local prefix from cwd.
+ if (Object.prototype.hasOwnProperty.call(cli, "prefix")) {
+ p = path.resolve(cli.prefix)
+ process.nextTick(cb)
+ } else {
+ findPrefix(process.cwd(), function (er, found) {
+ p = found
+ cb(er)
+ })
+ }
+}
diff -Nru nodejs-0.11.14/deps/npm/lib/config/load-uid.js nodejs-0.11.15/deps/npm/lib/config/load-uid.js
--- nodejs-0.11.14/deps/npm/lib/config/load-uid.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/config/load-uid.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,15 @@
+module.exports = loadUid
+
+var getUid = require("uid-number")
+
+// Call in the context of a npmconf object
+
+function loadUid (cb) {
+ // if we're not in unsafe-perm mode, then figure out who
+ // to run stuff as. Do this first, to support `npm update npm -g`
+ if (!this.get("unsafe-perm")) {
+ getUid(this.get("user"), this.get("group"), cb)
+ } else {
+ process.nextTick(cb)
+ }
+}
diff -Nru nodejs-0.11.14/deps/npm/lib/config/nerf-dart.js nodejs-0.11.15/deps/npm/lib/config/nerf-dart.js
--- nodejs-0.11.14/deps/npm/lib/config/nerf-dart.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/config/nerf-dart.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,21 @@
+var url = require("url")
+
+module.exports = toNerfDart
+
+/**
+ * Maps a URL to an identifier.
+ *
+ * Name courtesy schiffertronix media LLC, a New Jersey corporation
+ *
+ * @param {String} uri The URL to be nerfed.
+ *
+ * @returns {String} A nerfed URL.
+ */
+function toNerfDart(uri) {
+ var parsed = url.parse(uri)
+ parsed.pathname = "/"
+ delete parsed.protocol
+ delete parsed.auth
+
+ return url.format(parsed)
+}
diff -Nru nodejs-0.11.14/deps/npm/lib/config/set-credentials-by-uri.js nodejs-0.11.15/deps/npm/lib/config/set-credentials-by-uri.js
--- nodejs-0.11.14/deps/npm/lib/config/set-credentials-by-uri.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/config/set-credentials-by-uri.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,42 @@
+var assert = require("assert")
+
+var toNerfDart = require("./nerf-dart.js")
+
+module.exports = setCredentialsByURI
+
+function setCredentialsByURI (uri, c) {
+ assert(uri && typeof uri === "string", "registry URL is required")
+ assert(c && typeof c === "object", "credentials are required")
+
+ var nerfed = toNerfDart(uri)
+
+ if (c.token) {
+ this.set(nerfed + ":_authToken", c.token, "user")
+ this.del(nerfed + ":_password", "user")
+ this.del(nerfed + ":username", "user")
+ this.del(nerfed + ":email", "user")
+ this.del(nerfed + ":always-auth", "user")
+ }
+ else if (c.username || c.password || c.email) {
+ assert(c.username, "must include username")
+ assert(c.password, "must include password")
+ assert(c.email, "must include email address")
+
+ this.del(nerfed + ":_authToken", "user")
+
+ var encoded = new Buffer(c.password, "utf8").toString("base64")
+ this.set(nerfed + ":_password", encoded, "user")
+ this.set(nerfed + ":username", c.username, "user")
+ this.set(nerfed + ":email", c.email, "user")
+
+ if (c.alwaysAuth !== undefined) {
+ this.set(nerfed + ":always-auth", c.alwaysAuth, "user")
+ }
+ else {
+ this.del(nerfed + ":always-auth", "user")
+ }
+ }
+ else {
+ throw new Error("No credentials to set.")
+ }
+}
diff -Nru nodejs-0.11.14/deps/npm/lib/config/set-user.js nodejs-0.11.15/deps/npm/lib/config/set-user.js
--- nodejs-0.11.14/deps/npm/lib/config/set-user.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/config/set-user.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,29 @@
+module.exports = setUser
+
+var assert = require("assert")
+var path = require("path")
+var fs = require("fs")
+var mkdirp = require("mkdirp")
+
+function setUser (cb) {
+ var defaultConf = this.root
+ assert(defaultConf !== Object.prototype)
+
+ // If global, leave it as-is.
+ // If not global, then set the user to the owner of the prefix folder.
+ // Just set the default, so it can be overridden.
+ if (this.get("global")) return cb()
+ if (process.env.SUDO_UID) {
+ defaultConf.user = +(process.env.SUDO_UID)
+ return cb()
+ }
+
+ var prefix = path.resolve(this.get("prefix"))
+ mkdirp(prefix, function (er) {
+ if (er) return cb(er)
+ fs.stat(prefix, function (er, st) {
+ defaultConf.user = st && st.uid
+ return cb(er)
+ })
+ })
+}
diff -Nru nodejs-0.11.14/deps/npm/lib/config.js nodejs-0.11.15/deps/npm/lib/config.js
--- nodejs-0.11.14/deps/npm/lib/config.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/config.js 2015-01-20 21:22:17.000000000 +0000
@@ -11,8 +11,9 @@
var log = require("npmlog")
, npm = require("./npm.js")
+ , npmconf = require("./config/core.js")
, fs = require("graceful-fs")
- , npmconf = require("npmconf")
+ , writeFileAtomic = require("write-file-atomic")
, types = npmconf.defs.types
, ini = require("ini")
, editor = require("editor")
@@ -88,17 +89,16 @@
if (key === "logstream") return arr
return arr.concat(
ini.stringify(obj)
- .replace(/\n$/m, '')
- .replace(/^/g, '; ')
- .replace(/\n/g, '\n; ')
- .split('\n'))
+ .replace(/\n$/m, "")
+ .replace(/^/g, "; ")
+ .replace(/\n/g, "\n; ")
+ .split("\n"))
}, []))
.concat([""])
.join(os.EOL)
- fs.writeFile
+ writeFileAtomic
( f
, data
- , "utf8"
, function (er) {
if (er) return cb(er)
editor(f, { editor: e }, cb)
diff -Nru nodejs-0.11.14/deps/npm/lib/explore.js nodejs-0.11.15/deps/npm/lib/explore.js
--- nodejs-0.11.14/deps/npm/lib/explore.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/explore.js 2015-01-20 21:22:17.000000000 +0000
@@ -27,7 +27,7 @@
"Type 'exit' or ^D when finished\n")
npm.spinner.stop()
- var shell = spawn(sh, args, { cwd: cwd, customFds: [0, 1, 2] })
+ var shell = spawn(sh, args, { cwd: cwd, stdio: "inherit" })
shell.on("close", function (er) {
// only fail if non-interactive.
if (!args.length) return cb()
diff -Nru nodejs-0.11.14/deps/npm/lib/help.js nodejs-0.11.15/deps/npm/lib/help.js
--- nodejs-0.11.14/deps/npm/lib/help.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/help.js 2015-01-20 21:22:17.000000000 +0000
@@ -31,7 +31,7 @@
// npm help : show basic usage
if (!section) {
- var valid = argv[0] === 'help' ? 0 : 1
+ var valid = argv[0] === "help" ? 0 : 1
return npmUsage(valid, cb)
}
@@ -111,7 +111,7 @@
switch (viewer) {
case "woman":
var a = ["-e", "(woman-find-file \"" + man + "\")"]
- conf = { env: env, customFds: [ 0, 1, 2] }
+ conf = { env: env, stdio: "inherit" }
var woman = spawn("emacsclient", a, conf)
woman.on("close", cb)
break
@@ -121,7 +121,7 @@
break
default:
- conf = { env: env, customFds: [ 0, 1, 2] }
+ conf = { env: env, stdio: "inherit" }
var manProcess = spawn("man", [num, section], conf)
manProcess.on("close", cb)
break
@@ -153,8 +153,8 @@
function npmUsage (valid, cb) {
npm.config.set("loglevel", "silent")
log.level = "silent"
- console.log
- ( ["\nUsage: npm "
+ console.log(
+ [ "\nUsage: npm "
, ""
, "where is one of:"
, npm.config.get("long") ? usages()
@@ -196,7 +196,7 @@
function wrap (arr) {
- var out = ['']
+ var out = [""]
, l = 0
, line
@@ -209,9 +209,9 @@
arr.sort(function (a,b) { return a --save` afterwards to install a package and"
- ,"save it as a dependency in the package.json file."
- ,""
- ,"Press ^C at any time to quit."
- ].join("\n"))
-
+ var initFile = npm.config.get("init-module")
+ if (!initJson.yes(npm.config)) {
+ console.log(
+ ["This utility will walk you through creating a package.json file."
+ ,"It only covers the most common items, and tries to guess sane defaults."
+ ,""
+ ,"See `npm help json` for definitive documentation on these fields"
+ ,"and exactly what they do."
+ ,""
+ ,"Use `npm install --save` afterwards to install a package and"
+ ,"save it as a dependency in the package.json file."
+ ,""
+ ,"Press ^C at any time to quit."
+ ].join("\n"))
+ }
initJson(dir, initFile, npm.config, function (er, data) {
log.resume()
- log.silly('package data', data)
- log.info('init', 'written successfully')
- if (er && er.message === 'canceled') {
- log.warn('init', 'canceled')
+ log.silly("package data", data)
+ log.info("init", "written successfully")
+ if (er && er.message === "canceled") {
+ log.warn("init", "canceled")
return cb(null, data)
}
cb(er, data)
diff -Nru nodejs-0.11.14/deps/npm/lib/install.js nodejs-0.11.15/deps/npm/lib/install.js
--- nodejs-0.11.14/deps/npm/lib/install.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/install.js 2015-01-20 21:22:17.000000000 +0000
@@ -73,6 +73,7 @@
, log = require("npmlog")
, path = require("path")
, fs = require("graceful-fs")
+ , writeFileAtomic = require("write-file-atomic")
, cache = require("./cache.js")
, asyncMap = require("slide").asyncMap
, chain = require("slide").chain
@@ -84,6 +85,10 @@
, sortedObject = require("sorted-object")
, mapToRegistry = require("./utils/map-to-registry.js")
, npa = require("npm-package-arg")
+ , inflight = require("inflight")
+ , locker = require("./utils/locker.js")
+ , lock = locker.lock
+ , unlock = locker.unlock
function install (args, cb_) {
var hasArguments = !!args.length
@@ -143,6 +148,22 @@
}
var deps = Object.keys(data.dependencies || {})
log.verbose("install", "where, deps", [where, deps])
+
+ // FIXME: Install peerDependencies as direct dependencies, but only at
+ // the top level. Should only last until peerDependencies are nerfed to
+ // no longer implicitly install themselves.
+ var peers = []
+ Object.keys(data.peerDependencies || {}).forEach(function (dep) {
+ if (!data.dependencies[dep]) {
+ log.verbose(
+ "install",
+ "peerDependency", dep, "wasn't going to be installed; adding"
+ )
+ peers.push(dep)
+ }
+ })
+ log.verbose("install", "where, peers", [where, peers])
+
var context = { family: {}
, ancestors: {}
, explicit: false
@@ -160,10 +181,12 @@
installManyTop(deps.map(function (dep) {
var target = data.dependencies[dep]
- target = dep + "@" + target
- return target
- }), where, context, function(er, results) {
- if (er) return cb(er, results)
+ return dep + "@" + target
+ }).concat(peers.map(function (dep) {
+ var target = data.peerDependencies[dep]
+ return dep + "@" + target
+ })), where, context, function(er, results) {
+ if (er || npm.config.get("production")) return cb(er, results)
lifecycle(data, "prepublish", where, function(er) {
return cb(er, results)
})
@@ -205,7 +228,7 @@
function findPeerInvalid_ (packageMap, fpiList) {
if (fpiList.indexOf(packageMap) !== -1)
- return
+ return undefined
fpiList.push(packageMap)
@@ -260,7 +283,13 @@
if (opts && opts.dev) {
if (!data.dependencies) data.dependencies = {}
Object.keys(data.devDependencies || {}).forEach(function (k) {
- data.dependencies[k] = data.devDependencies[k]
+ if (data.dependencies[k]) {
+ log.warn("package.json", "Dependency '%s' exists in both dependencies " +
+ "and devDependencies, using '%s@%s' from dependencies",
+ k, k, data.dependencies[k])
+ } else {
+ data.dependencies[k] = data.devDependencies[k]
+ }
})
}
@@ -292,11 +321,9 @@
var wrapfile = path.resolve(where, "npm-shrinkwrap.json")
fs.readFile(wrapfile, "utf8", function (er, wrapjson) {
- if (er) {
- log.verbose("readDependencies", "using package.json deps")
- return cb(null, data, null)
- }
+ if (er) return cb(null, data, null)
+ log.verbose("readDependencies", "npm-shrinkwrap.json is overriding dependencies")
var newwrap
try {
newwrap = JSON.parse(wrapjson)
@@ -346,7 +373,7 @@
}
var saveBundle = npm.config.get("save-bundle")
- var savePrefix = npm.config.get("save-prefix") || "^"
+ var savePrefix = npm.config.get("save-prefix")
// each item in the tree is a top-level thing that should be saved
// to the package.json file.
@@ -420,7 +447,7 @@
data[deps] = sortedObject(data[deps])
data = JSON.stringify(data, null, 2) + "\n"
- fs.writeFile(saveTarget, data, function (er) {
+ writeFileAtomic(saveTarget, data, function (er) {
cb(er, installed, tree, pretty)
})
})
@@ -551,30 +578,58 @@
fs.readdir(nm, function (er, pkgs) {
if (er) return installMany(what, where, context, cb)
- pkgs = pkgs.filter(function (p) {
+
+ var scopes = [], unscoped = []
+ pkgs.filter(function (p) {
return !p.match(/^[\._-]/)
+ }).forEach(function (p) {
+ // @names deserve deeper investigation
+ if (p[0] === "@") {
+ scopes.push(p)
+ }
+ else {
+ unscoped.push(p)
+ }
})
- asyncMap(pkgs.map(function (p) {
- return path.resolve(nm, p, "package.json")
- }), function (jsonfile, cb) {
- readJson(jsonfile, log.warn, function (er, data) {
- if (er && er.code !== "ENOENT" && er.code !== "ENOTDIR") return cb(er)
- if (er) return cb(null, [])
- return cb(null, [[data.name, data.version]])
- })
- }, function (er, packages) {
- // if there's nothing in node_modules, then don't freak out.
- if (er) packages = []
- // add all the existing packages to the family list.
- // however, do not add to the ancestors list.
- packages.forEach(function (p) {
- context.family[p[0]] = p[1]
+
+ maybeScoped(scopes, nm, function (er, scoped) {
+ if (er && er.code !== "ENOENT" && er.code !== "ENOTDIR") return cb(er)
+ // recombine unscoped with @scope/package packages
+ asyncMap(unscoped.concat(scoped).map(function (p) {
+ return path.resolve(nm, p, "package.json")
+ }), function (jsonfile, cb) {
+ readJson(jsonfile, log.warn, function (er, data) {
+ if (er && er.code !== "ENOENT" && er.code !== "ENOTDIR") return cb(er)
+ if (er) return cb(null, [])
+ cb(null, [[data.name, data.version]])
+ })
+ }, function (er, packages) {
+ // if there's nothing in node_modules, then don't freak out.
+ if (er) packages = []
+ // add all the existing packages to the family list.
+ // however, do not add to the ancestors list.
+ packages.forEach(function (p) {
+ context.family[p[0]] = p[1]
+ })
+ installMany(what, where, context, cb)
})
- return installMany(what, where, context, cb)
})
})
}
+function maybeScoped (scopes, where, cb) {
+ // find packages in scopes
+ asyncMap(scopes, function (scope, cb) {
+ fs.readdir(path.resolve(where, scope), function (er, scoped) {
+ if (er) return cb(er)
+ var paths = scoped.map(function (p) {
+ return path.join(scope, p)
+ })
+ cb(null, paths)
+ })
+ }, cb)
+}
+
function installMany (what, where, context, cb) {
// readDependencies takes care of figuring out whether the list of
// dependencies we'll iterate below comes from an existing shrinkwrap from a
@@ -614,7 +669,7 @@
targets.forEach(function (t) {
newPrev[t.name] = t.version
})
- log.silly("resolved", targets)
+ log.silly("install resolved", targets)
targets.filter(function (t) { return t }).forEach(function (t) {
log.info("install", "%s into %s", t._id, where)
})
@@ -652,9 +707,8 @@
// don't even mess with non-package looking things
inst = inst.filter(function (p) {
if (!p.match(/^[@\._-]/)) return true
- // scope pacakges
- var scopepath = path.join(name, p)
- readdir(scopepath)
+ // scoped packages
+ readdir(path.join(name, p))
})
asyncMap(inst, function (pkg, cb) {
@@ -847,15 +901,9 @@
, target._from ]
}
-// name => install locations
-var installOnesInProgress = Object.create(null)
-
-function isIncompatibleInstallOneInProgress(target, where) {
- return target.name in installOnesInProgress &&
- installOnesInProgress[target.name].indexOf(where) !== -1
-}
+var installed = Object.create(null)
-function installOne_ (target, where, context, cb) {
+function installOne_ (target, where, context, cb_) {
var nm = path.resolve(where, "node_modules")
, targetFolder = path.resolve(nm, target.name)
, prettyWhere = path.relative(process.cwd(), where)
@@ -863,37 +911,55 @@
if (prettyWhere === ".") prettyWhere = null
- if (isIncompatibleInstallOneInProgress(target, where)) {
- // just call back, with no error. the error will be detected in the
- // final check for peer-invalid dependencies
- return cb()
- }
-
- if (!(target.name in installOnesInProgress)) {
- installOnesInProgress[target.name] = []
- }
- installOnesInProgress[target.name].push(where)
- var indexOfIOIP = installOnesInProgress[target.name].length - 1
- , force = npm.config.get("force")
- , nodeVersion = npm.config.get("node-version")
- , strict = npm.config.get("engine-strict")
- , c = npmInstallChecks
-
- chain
- ( [ [c.checkEngine, target, npm.version, nodeVersion, force, strict]
- , [c.checkPlatform, target, force]
- , [c.checkCycle, target, context.ancestors]
- , [c.checkGit, targetFolder]
- , [write, target, targetFolder, context] ]
- , function (er, d) {
- installOnesInProgress[target.name].splice(indexOfIOIP, 1)
+ cb_ = inflight(target.name + ":" + where, cb_)
+ if (!cb_) return log.verbose(
+ "installOne",
+ "of", target.name,
+ "to", where,
+ "already in flight; waiting"
+ )
+ else log.verbose(
+ "installOne",
+ "of", target.name,
+ "to", where,
+ "not in flight; installing"
+ )
- if (er) return cb(er)
+ function cb(er, data) {
+ unlock(nm, target.name, function () { cb_(er, data) })
+ }
- d.push(resultList(target, where, parent && parent._id))
- cb(er, d)
- }
- )
+ lock(nm, target.name, function (er) {
+ if (er) return cb(er)
+
+ if (targetFolder in installed) {
+ log.error("install", "trying to install", target.version, "to", targetFolder)
+ log.error("install", "but already installed versions", installed[targetFolder])
+ installed[targetFolder].push(target.version)
+ }
+ else {
+ installed[targetFolder] = [target.version]
+ }
+
+ var force = npm.config.get("force")
+ , nodeVersion = npm.config.get("node-version")
+ , strict = npm.config.get("engine-strict")
+ , c = npmInstallChecks
+
+ chain(
+ [ [c.checkEngine, target, npm.version, nodeVersion, force, strict]
+ , [c.checkPlatform, target, force]
+ , [c.checkCycle, target, context.ancestors]
+ , [c.checkGit, targetFolder]
+ , [write, target, targetFolder, context] ]
+ , function (er, d) {
+ if (er) return cb(er)
+
+ d.push(resultList(target, where, parent && parent._id))
+ cb(er, d)
+ }
+ )
+ })
}
function write (target, targetFolder, context, cb_) {
@@ -907,15 +973,16 @@
// is the list of installed packages from that last thing.
if (!er) return cb_(er, data)
- if (false === npm.config.get("rollback")) return cb_(er)
+ if (npm.config.get("rollback") === false) return cb_(er)
npm.rollbacks.push(targetFolder)
cb_(er, data)
}
var bundled = []
- chain
- ( [ [ cache.unpack, target.name, target.version, targetFolder
+ log.silly("install write", "writing", target.name, target.version, "to", targetFolder)
+ chain(
+ [ [ cache.unpack, target.name, target.version, targetFolder
, null, null, user, group ]
, [ fs, "writeFile"
, path.resolve(targetFolder, "package.json")
@@ -950,14 +1017,27 @@
, explicit: false
, wrap: wrap }
+ var actions =
+ [ [ installManyAndBuild, deps, depsTargetFolder, depsContext ] ]
+
+ // FIXME: This is an accident waiting to happen!
+ //
+ // 1. If multiple children at the same level of the tree share a
+ // peerDependency that's not in the parent's dependencies, because
+ // the peerDeps don't get added to the family, they will keep
+ // getting reinstalled (worked around by inflighting installOne).
+ // 2. The installer can't safely build at the parent level because
+ // that's already being done by the parent's installAndBuild. This
+ // runs the risk of the peerDependency never getting built.
+ //
+ // The fix: Don't install peerDependencies; require them to be
+ // included as explicit dependencies / devDependencies, and warn
+ // or error when they're missing. See #5080 for more arguments in
+ // favor of killing implicit peerDependency installs with fire.
var peerDeps = prepareForInstallMany(data, "peerDependencies", bundled,
wrap, family)
var pdTargetFolder = path.resolve(targetFolder, "..", "..")
var pdContext = context
-
- var actions =
- [ [ installManyAndBuild, deps, depsTargetFolder, depsContext ] ]
-
if (peerDeps.length > 0) {
actions.push(
[ installMany, peerDeps, pdTargetFolder, pdContext ]
@@ -1000,8 +1080,9 @@
return !semver.satisfies(family[d], packageData[depsKey][d], true)
return true
}).map(function (d) {
- var t = packageData[depsKey][d]
- t = d + "@" + t
+ var v = packageData[depsKey][d]
+ var t = d + "@" + v
+ log.silly("prepareForInstallMany", "adding", t, "from", packageData.name, depsKey)
return t
})
}
diff -Nru nodejs-0.11.14/deps/npm/lib/npm.js nodejs-0.11.15/deps/npm/lib/npm.js
--- nodejs-0.11.14/deps/npm/lib/npm.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/npm.js 2015-01-20 21:22:17.000000000 +0000
@@ -16,7 +16,7 @@
var EventEmitter = require("events").EventEmitter
, npm = module.exports = new EventEmitter()
- , npmconf = require("npmconf")
+ , npmconf = require("./config/core.js")
, log = require("npmlog")
, fs = require("graceful-fs")
, path = require("path")
@@ -99,7 +99,6 @@
, "update"
, "outdated"
, "prune"
- , "submodule"
, "pack"
, "dedupe"
@@ -424,11 +423,7 @@
})
var tmpFolder
-var crypto = require("crypto")
-var rand = crypto.randomBytes(6)
- .toString("base64")
- .replace(/\//g, '_')
- .replace(/\+/, '-')
+var rand = require("crypto").randomBytes(4).toString("hex")
Object.defineProperty(npm, "tmp",
{ get : function () {
if (!tmpFolder) tmpFolder = "npm-" + process.pid + "-" + rand
diff -Nru nodejs-0.11.14/deps/npm/lib/pack.js nodejs-0.11.15/deps/npm/lib/pack.js
--- nodejs-0.11.14/deps/npm/lib/pack.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/pack.js 2015-01-20 21:22:17.000000000 +0000
@@ -11,6 +11,8 @@
, chain = require("slide").chain
, path = require("path")
, cwd = process.cwd()
+ , writeStream = require('fs-write-stream-atomic')
+ , cachedPackageRoot = require("./cache/cached-package-root.js")
pack.usage = "npm pack "
@@ -43,17 +45,14 @@
cache.add(pkg, null, null, false, function (er, data) {
if (er) return cb(er)
- var name = data.name
// scoped packages get special treatment
+ var name = data.name
if (name[0] === "@") name = name.substr(1).replace(/\//g, "-")
-
var fname = name + "-" + data.version + ".tgz"
- , cached = path.resolve( npm.cache
- , data.name
- , data.version
- , "package.tgz" )
+
+ var cached = path.join(cachedPackageRoot(data), "package.tgz")
, from = fs.createReadStream(cached)
- , to = fs.createWriteStream(fname)
+ , to = writeStream(fname)
, errState = null
from.on("error", cb_)
diff -Nru nodejs-0.11.14/deps/npm/lib/publish.js nodejs-0.11.15/deps/npm/lib/publish.js
--- nodejs-0.11.14/deps/npm/lib/publish.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/publish.js 2015-01-20 21:22:17.000000000 +0000
@@ -8,9 +8,10 @@
, readJson = require("read-package-json")
, lifecycle = require("./utils/lifecycle.js")
, chain = require("slide").chain
- , Conf = require("npmconf").Conf
+ , Conf = require("./config/core.js").Conf
, RegClient = require("npm-registry-client")
, mapToRegistry = require("./utils/map-to-registry.js")
+ , cachedPackageRoot = require("./cache/cached-package-root.js")
publish.usage = "npm publish "
+ "\nnpm publish "
@@ -35,14 +36,18 @@
var arg = args[0]
// if it's a local folder, then run the prepublish there, first.
readJson(path.resolve(arg, "package.json"), function (er, data) {
- er = needVersion(er, data)
if (er && er.code !== "ENOENT" && er.code !== "ENOTDIR") return cb(er)
- // error is ok. could be publishing a url or tarball
- // however, that means that we will not have automatically run
- // the prepublish script, since that gets run when adding a folder
- // to the cache.
+
+ if (data) {
+ if (!data.name) return cb(new Error("No name provided"))
+ if (!data.version) return cb(new Error("No version provided"))
+ }
+
+ // Error is OK. Could be publishing a URL or tarball, however, that means
+ // that we will not have automatically run the prepublish script, since
+ // that gets run when adding a folder to the cache.
if (er) return cacheAddPublish(arg, false, isRetry, cb)
- cacheAddPublish(arg, true, isRetry, cb)
+ else cacheAddPublish(arg, true, isRetry, cb)
})
}
@@ -55,10 +60,7 @@
npm.commands.cache.add(dir, null, null, false, function (er, data) {
if (er) return cb(er)
log.silly("publish", data)
- var cachedir = path.resolve( npm.cache
- , data.name
- , data.version
- , "package" )
+ var cachedir = path.resolve(cachedPackageRoot(data), "package")
chain([ !didPre &&
[lifecycle, data, "prepublish", cachedir]
, [publish_, dir, data, isRetry, cachedir]
@@ -88,7 +90,8 @@
registry = new RegClient(config)
}
- data._npmVersion = npm.version
+ data._npmVersion = npm.version
+ data._nodeVersion = process.versions.node
delete data.modules
if (data.private) return cb(
@@ -128,9 +131,3 @@
})
})
}
-
-function needVersion(er, data) {
- return er ? er
- : (data && !data.version) ? new Error("No version provided")
- : null
-}
diff -Nru nodejs-0.11.14/deps/npm/lib/run-script.js nodejs-0.11.15/deps/npm/lib/run-script.js
--- nodejs-0.11.14/deps/npm/lib/run-script.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/run-script.js 2015-01-20 21:22:17.000000000 +0000
@@ -53,7 +53,10 @@
next()
})
- if (npm.config.get("global")) scripts = [], next()
+ if (npm.config.get("global")) {
+ scripts = []
+ next()
+ }
else readJson(path.join(npm.localPrefix, "package.json"), function (er, d) {
if (er && er.code !== "ENOENT" && er.code !== "ENOTDIR") return cb(er)
d = d || {}
@@ -63,7 +66,8 @@
function next () {
if (!installed || !scripts) return
- return cb(null, scripts.concat(installed))
+
+ cb(null, scripts.concat(installed))
}
}
@@ -80,9 +84,9 @@
}
function list(cb) {
- var json = path.join(npm.localPrefix, 'package.json')
+ var json = path.join(npm.localPrefix, "package.json")
return readJson(json, function(er, d) {
- if (er && er.code !== 'ENOENT' && er.code !== 'ENOTDIR') return cb(er)
+ if (er && er.code !== "ENOENT" && er.code !== "ENOTDIR") return cb(er)
if (er) d = {}
var scripts = Object.keys(d.scripts || {})
@@ -110,22 +114,27 @@
}
function run (pkg, wd, cmd, args, cb) {
- var cmds = []
if (!pkg.scripts) pkg.scripts = {}
+
+ var cmds
if (cmd === "restart") {
- cmds = ["prestop","stop","poststop"
- ,"restart"
- ,"prestart","start","poststart"]
+ cmds = [
+ "prestop", "stop", "poststop",
+ "restart",
+ "prestart", "start", "poststart"
+ ]
} else {
cmds = [cmd]
}
+
if (!cmd.match(/^(pre|post)/)) {
cmds = ["pre"+cmd].concat(cmds).concat("post"+cmd)
}
+
log.verbose("run-script", cmds)
chain(cmds.map(function (c) {
// pass cli arguments after -- to script.
- if (pkg.scripts[c]) pkg.scripts[c] = pkg.scripts[c] + joinArgs(args)
+ if (pkg.scripts[c] && c === cmd) pkg.scripts[c] = pkg.scripts[c] + joinArgs(args)
// when running scripts explicitly, assume that they're trusted.
return [lifecycle, pkg, c, wd, true]
@@ -135,10 +144,10 @@
// join arguments after '--' and pass them to script,
// handle special characters such as ', ", ' '.
function joinArgs (args) {
- var joinedArgs = ''
- args.forEach(function(arg, i) {
+ var joinedArgs = ""
+ args.forEach(function(arg) {
if (arg.match(/[ '"]/)) arg = '"' + arg.replace(/"/g, '\\"') + '"'
- joinedArgs += ' ' + arg
+ joinedArgs += " " + arg
})
return joinedArgs
}
diff -Nru nodejs-0.11.14/deps/npm/lib/search.js nodejs-0.11.15/deps/npm/lib/search.js
--- nodejs-0.11.14/deps/npm/lib/search.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/search.js 2015-01-20 21:22:17.000000000 +0000
@@ -218,7 +218,7 @@
if (arg.charAt(0) === "/") {
//arg = arg.replace(/\/$/, "")
- return str.replace( new RegExp(arg.substr(1, arg.length - 1), "gi")
+ return str.replace( new RegExp(arg.substr(1, arg.length - 2), "gi")
, function (bit) { return markStart + bit + markEnd } )
}
diff -Nru nodejs-0.11.14/deps/npm/lib/shrinkwrap.js nodejs-0.11.15/deps/npm/lib/shrinkwrap.js
--- nodejs-0.11.14/deps/npm/lib/shrinkwrap.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/shrinkwrap.js 2015-01-20 21:22:17.000000000 +0000
@@ -6,6 +6,7 @@
var npm = require("./npm.js")
, log = require("npmlog")
, fs = require("fs")
+ , writeFileAtomic = require("write-file-atomic")
, path = require("path")
, readJson = require("read-package-json")
, sortedObject = require("sorted-object")
@@ -70,7 +71,7 @@
var file = path.resolve(npm.prefix, "npm-shrinkwrap.json")
- fs.writeFile(file, swdata, function (er) {
+ writeFileAtomic(file, swdata, function (er) {
if (er) return cb(er)
if (silent) return cb(null, pkginfo)
console.log("wrote npm-shrinkwrap.json")
diff -Nru nodejs-0.11.14/deps/npm/lib/submodule.js nodejs-0.11.15/deps/npm/lib/submodule.js
--- nodejs-0.11.14/deps/npm/lib/submodule.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/submodule.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,90 +0,0 @@
-// npm submodule
-// Check the package contents for a git repository url.
-// If there is one, then create a git submodule in the node_modules folder.
-
-module.exports = submodule
-
-var npm = require("./npm.js")
- , cache = require("./cache.js")
- , git = require("./utils/git.js")
- , asyncMap = require("slide").asyncMap
- , chain = require("slide").chain
-
-submodule.usage = "npm submodule "
-
-submodule.completion = require("./docs.js").completion
-
-function submodule (args, cb) {
- if (npm.config.get("global")) {
- return cb(new Error("Cannot use submodule command in global mode."))
- }
-
- if (args.length === 0) return cb(submodule.usage)
-
- asyncMap(args, function (arg, cb) {
- cache.add(arg, null, null, false, cb)
- }, function (er, pkgs) {
- if (er) return cb(er)
- chain(pkgs.map(function (pkg) { return function (cb) {
- submodule_(pkg, cb)
- }}), cb)
- })
-
-}
-
-function submodule_ (pkg, cb) {
- if (!pkg.repository
- || pkg.repository.type !== "git"
- || !pkg.repository.url) {
- return cb(new Error(pkg._id + ": No git repository listed"))
- }
-
- // prefer https:// github urls
- pkg.repository.url = pkg.repository.url
- .replace(/^(git:\/\/)?(git@)?github.com[:\/]/, "https://github.com/")
-
- // first get the list of submodules, and update if it's already there.
- getSubmodules(function (er, modules) {
- if (er) return cb(er)
- // if there's already a submodule, then just update it.
- if (modules.indexOf(pkg.name) !== -1) {
- return updateSubmodule(pkg.name, cb)
- }
- addSubmodule(pkg.name, pkg.repository.url, cb)
- })
-}
-
-function updateSubmodule (name, cb) {
- var args = [ "submodule", "update", "--init", "node_modules/", name ]
-
- git.whichAndExec(args, cb)
-}
-
-function addSubmodule (name, url, cb) {
- var args = [ "submodule", "add", url, "node_modules/", name ]
-
- git.whichAndExec(args, cb)
-}
-
-
-var getSubmodules = function (cb) {
- var args = [ "submodule", "status" ]
-
-
- git.whichAndExec(args, function _(er, stdout) {
- if (er) return cb(er)
- var res = stdout.trim().split(/\n/).map(function (line) {
- return line.trim().split(/\s+/)[1]
- }).filter(function (line) {
- // only care about submodules in the node_modules folder.
- return line && line.match(/^node_modules\//)
- }).map(function (line) {
- return line.replace(/^node_modules\//g, "")
- })
-
- // memoize.
- getSubmodules = function (cb) { return cb(null, res) }
-
- cb(null, res)
- })
-}
diff -Nru nodejs-0.11.14/deps/npm/lib/unbuild.js nodejs-0.11.15/deps/npm/lib/unbuild.js
--- nodejs-0.11.14/deps/npm/lib/unbuild.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/unbuild.js 2015-01-20 21:22:17.000000000 +0000
@@ -24,7 +24,7 @@
}
folder = path.resolve(folder)
delete build._didBuild[folder]
- log.verbose(folder.substr(npm.prefix.length + 1), "unbuild")
+ log.verbose("unbuild", folder.substr(npm.prefix.length + 1))
readJson(path.resolve(folder, "package.json"), function (er, pkg) {
// if no json, then just trash it, but no scripts or whatever.
if (er) return gentlyRm(folder, false, cb)
@@ -53,7 +53,8 @@
readJson.cache.del(path.resolve(folder, "package.json"))
- log.verbose([top, gnm, parent], "unbuild " + pkg._id)
+ log.verbose("unbuild rmStuff", pkg._id, "from", gnm)
+ if (!top) log.verbose("unbuild rmStuff", "in", parent)
asyncMap([rmBins, rmMans], function (fn, cb) {
fn(pkg, folder, parent, top, cb)
}, cb)
diff -Nru nodejs-0.11.14/deps/npm/lib/uninstall.js nodejs-0.11.15/deps/npm/lib/uninstall.js
--- nodejs-0.11.14/deps/npm/lib/uninstall.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/uninstall.js 2015-01-20 21:22:17.000000000 +0000
@@ -9,6 +9,7 @@
uninstall.completion = require("./utils/completion/installed-shallow.js")
var fs = require("graceful-fs")
+ , writeFileAtomic = require("write-file-atomic")
, log = require("npmlog")
, readJson = require("read-package-json")
, path = require("path")
@@ -120,7 +121,7 @@
}
}
- fs.writeFile(pj, JSON.stringify(pkg, null, 2) + "\n", function (er) {
+ writeFileAtomic(pj, JSON.stringify(pkg, null, 2) + "\n", function (er) {
return cb_(er, data)
})
})
diff -Nru nodejs-0.11.14/deps/npm/lib/utils/error-handler.js nodejs-0.11.15/deps/npm/lib/utils/error-handler.js
--- nodejs-0.11.14/deps/npm/lib/utils/error-handler.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/utils/error-handler.js 2015-01-20 21:22:17.000000000 +0000
@@ -11,6 +11,7 @@
, exitCode = 0
, rollbacks = npm.rollbacks
, chain = require("slide").chain
+ , writeStream = require("fs-write-stream-atomic")
process.on("exit", function (code) {
@@ -66,17 +67,21 @@
if (er) {
log.error("error rolling back", er)
if (!code) errorHandler(er)
- else reallyExit(er)
+ else if (noLog) rm("npm-debug.log", reallyExit.bind(null, er))
+ else writeLogFile(reallyExit.bind(this, er))
} else {
- rm("npm-debug.log", reallyExit)
+ if (!noLog && code) writeLogFile(reallyExit)
+ else rm("npm-debug.log", reallyExit)
}
})
rollbacks.length = 0
}
else if (code && !noLog) writeLogFile(reallyExit)
- else reallyExit()
+ else rm("npm-debug.log", reallyExit)
+
+ function reallyExit (er) {
+ if (er && !code) code = typeof er.errno === "number" ? er.errno : 1
- function reallyExit() {
// truncate once it's been written.
log.record.length = 0
@@ -351,8 +356,7 @@
writingLogFile = true
wroteLogFile = true
- var fs = require("graceful-fs")
- , fstr = fs.createWriteStream("npm-debug.log")
+ var fstr = writeStream("npm-debug.log")
, os = require("os")
, out = ""
diff -Nru nodejs-0.11.14/deps/npm/lib/utils/git.js nodejs-0.11.15/deps/npm/lib/utils/git.js
--- nodejs-0.11.14/deps/npm/lib/utils/git.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/utils/git.js 2015-01-20 21:22:17.000000000 +0000
@@ -10,16 +10,20 @@
, npm = require("../npm.js")
, which = require("which")
, git = npm.config.get("git")
+ , assert = require("assert")
+ , log = require("npmlog")
function prefixGitArgs() {
return process.platform === "win32" ? ["-c", "core.longpaths=true"] : []
}
function execGit(args, options, cb) {
+ log.info("git", args)
return exec(git, prefixGitArgs().concat(args || []), options, cb)
}
function spawnGit(args, options, cb) {
+ log.info("git", args)
return spawn(git, prefixGitArgs().concat(args || []), options)
}
@@ -33,6 +37,7 @@
}
function whichAndExec(args, options, cb) {
+ assert.equal(typeof cb, "function", "no callback provided")
// check for git
whichGit(function (err) {
if (err) {
diff -Nru nodejs-0.11.14/deps/npm/lib/utils/locker.js nodejs-0.11.15/deps/npm/lib/utils/locker.js
--- nodejs-0.11.14/deps/npm/lib/utils/locker.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/utils/locker.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,52 +1,75 @@
var crypto = require("crypto")
-var path = require("path")
+var resolve = require("path").resolve
-var npm = require("../npm.js")
-var lockFile = require("lockfile")
+var lockfile = require("lockfile")
var log = require("npmlog")
-var getCacheStat = require("../cache/get-stat.js")
+var mkdirp = require("mkdirp")
+
+var npm = require("../npm.js")
+var getStat = require("../cache/get-stat.js")
+
+var installLocks = {}
-function lockFileName (u) {
- var c = u.replace(/[^a-zA-Z0-9]+/g, "-").replace(/^-+|-+$/g, "")
- , h = crypto.createHash("sha1").update(u).digest("hex")
- h = h.substr(0, 8)
- c = c.substr(-32)
- log.silly("lockFile", h + "-" + c, u)
- return path.resolve(npm.config.get("cache"), h + "-" + c + ".lock")
+function lockFileName (base, name) {
+ var c = name.replace(/[^a-zA-Z0-9]+/g, "-").replace(/^-+|-+$/g, "")
+ , p = resolve(base, name)
+ , h = crypto.createHash("sha1").update(p).digest("hex")
+ , l = resolve(npm.cache, "_locks")
+
+ return resolve(l, c.substr(0, 24)+"-"+h.substr(0, 16)+".lock")
}
-var myLocks = {}
-function lock (u, cb) {
- // the cache dir needs to exist already for this.
- getCacheStat(function (er, cs) {
- if (er) return cb(er)
- var opts = { stale: npm.config.get("cache-lock-stale")
- , retries: npm.config.get("cache-lock-retries")
- , wait: npm.config.get("cache-lock-wait") }
- var lf = lockFileName(u)
- log.verbose("lock", u, lf)
- lockFile.lock(lf, opts, function(er) {
- if (!er) myLocks[lf] = true
- cb(er)
+function lock (base, name, cb) {
+ getStat(function (er) {
+ var lockDir = resolve(npm.cache, "_locks")
+ mkdirp(lockDir, function () {
+ if (er) return cb(er)
+
+ var opts = { stale: npm.config.get("cache-lock-stale")
+ , retries: npm.config.get("cache-lock-retries")
+ , wait: npm.config.get("cache-lock-wait") }
+ var lf = lockFileName(base, name)
+ lockfile.lock(lf, opts, function (er) {
+ if (er) log.warn("locking", lf, "failed", er)
+
+ if (!er) {
+ log.verbose("lock", "using", lf, "for", resolve(base, name))
+ installLocks[lf] = true
+ }
+
+ cb(er)
+ })
})
})
}
-function unlock (u, cb) {
- var lf = lockFileName(u)
- , locked = myLocks[lf]
+function unlock (base, name, cb) {
+ var lf = lockFileName(base, name)
+ , locked = installLocks[lf]
if (locked === false) {
return process.nextTick(cb)
- } else if (locked === true) {
- myLocks[lf] = false
- lockFile.unlock(lockFileName(u), cb)
- } else {
- throw new Error("Attempt to unlock " + u + ", which hasn't been locked")
+ }
+ else if (locked === true) {
+ lockfile.unlock(lf, function (er) {
+ if (er) {
+ log.warn("unlocking", lf, "failed", er)
+ }
+ else {
+ installLocks[lf] = false
+ log.verbose("unlock", "done using", lf, "for", resolve(base, name))
+ }
+
+ cb(er)
+ })
+ }
+ else {
+ throw new Error(
+ "Attempt to unlock " + resolve(base, name) + ", which hasn't been locked"
+ )
}
}
module.exports = {
- lock: lock,
- unlock: unlock,
- _lockFileName: lockFileName
+ lock : lock,
+ unlock : unlock
}
diff -Nru nodejs-0.11.14/deps/npm/lib/utils/tar.js nodejs-0.11.15/deps/npm/lib/utils/tar.js
--- nodejs-0.11.14/deps/npm/lib/utils/tar.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/utils/tar.js 2015-01-20 21:22:17.000000000 +0000
@@ -3,6 +3,7 @@
var npm = require("../npm.js")
, fs = require("graceful-fs")
+ , writeFileAtomic = require("write-file-atomic")
, path = require("path")
, log = require("npmlog")
, uidNumber = require("uid-number")
@@ -15,15 +16,6 @@
, fstream = require("fstream")
, Packer = require("fstream-npm")
, lifecycle = require("./lifecycle.js")
- , locker = require("./locker.js")
-
-function lock(path, cb) {
- return locker.lock('tar://' + path, cb)
-}
-
-function unlock(path, cb) {
- return locker.unlock('tar://' + path, cb)
-}
if (process.env.SUDO_UID && myUid === 0) {
if (!isNaN(process.env.SUDO_UID)) myUid = +process.env.SUDO_UID
@@ -51,73 +43,40 @@
}
}
-function pack_ (tarball, folder, pkg, cb_) {
- var tarballLock = false
- , folderLock = false
-
- function cb (er) {
- if (folderLock)
- unlock(folder, function() {
- folderLock = false
- cb(er)
- })
- else if (tarballLock)
- unlock(tarball, function() {
- tarballLock = false
- cb(er)
- })
- else
- cb_(er)
- }
-
- lock(folder, function(er) {
- if (er) return cb(er)
- folderLock = true
- next()
- })
-
- lock(tarball, function (er) {
- if (er) return cb(er)
- tarballLock = true
- next()
- })
-
- function next () {
- if (!tarballLock || !folderLock) return
+function pack_ (tarball, folder, pkg, cb) {
+ new Packer({ path: folder, type: "Directory", isDirectory: true })
+ .on("error", function (er) {
+ if (er) log.error("tar pack", "Error reading " + folder)
+ return cb(er)
+ })
- new Packer({ path: folder, type: "Directory", isDirectory: true })
- .on("error", function (er) {
- if (er) log.error("tar pack", "Error reading " + folder)
- return cb(er)
- })
-
- // By default, npm includes some proprietary attributes in the
- // package tarball. This is sane, and allowed by the spec.
- // However, npm *itself* excludes these from its own package,
- // so that it can be more easily bootstrapped using old and
- // non-compliant tar implementations.
- .pipe(tar.Pack({ noProprietary: !npm.config.get("proprietary-attribs") }))
- .on("error", function (er) {
- if (er) log.error("tar.pack", "tar creation error", tarball)
- cb(er)
- })
- .pipe(zlib.Gzip())
- .on("error", function (er) {
- if (er) log.error("tar.pack", "gzip error "+tarball)
- cb(er)
- })
- .pipe(fstream.Writer({ type: "File", path: tarball }))
- .on("error", function (er) {
- if (er) log.error("tar.pack", "Could not write "+tarball)
- cb(er)
- })
- .on("close", cb)
- }
+ // By default, npm includes some proprietary attributes in the
+ // package tarball. This is sane, and allowed by the spec.
+ // However, npm *itself* excludes these from its own package,
+ // so that it can be more easily bootstrapped using old and
+ // non-compliant tar implementations.
+ .pipe(tar.Pack({ noProprietary: !npm.config.get("proprietary-attribs") }))
+ .on("error", function (er) {
+ if (er) log.error("tar.pack", "tar creation error", tarball)
+ cb(er)
+ })
+ .pipe(zlib.Gzip())
+ .on("error", function (er) {
+ if (er) log.error("tar.pack", "gzip error "+tarball)
+ cb(er)
+ })
+ .pipe(fstream.Writer({ type: "File", path: tarball }))
+ .on("error", function (er) {
+ if (er) log.error("tar.pack", "Could not write "+tarball)
+ cb(er)
+ })
+ .on("close", cb)
}
function unpack (tarball, unpackTarget, dMode, fMode, uid, gid, cb) {
- log.verbose("tar unpack", tarball)
+ log.verbose("tar", "unpack", tarball)
+ log.verbose("tar", "unpacking to", unpackTarget)
if (typeof cb !== "function") cb = gid, gid = null
if (typeof cb !== "function") cb = uid, uid = null
if (typeof cb !== "function") cb = fMode, fMode = npm.modes.file
@@ -129,52 +88,9 @@
})
}
-function unpack_ ( tarball, unpackTarget, dMode, fMode, uid, gid, cb_ ) {
- var parent = path.dirname(unpackTarget)
- , base = path.basename(unpackTarget)
- , folderLock
- , tarballLock
-
- function cb (er) {
- if (folderLock)
- unlock(unpackTarget, function() {
- folderLock = false
- cb(er)
- })
- else if (tarballLock)
- unlock(tarball, function() {
- tarballLock = false
- cb(er)
- })
- else
- cb_(er)
- }
-
- lock(unpackTarget, function (er) {
- if (er) return cb(er)
- folderLock = true
- next()
- })
-
- lock(tarball, function (er) {
+function unpack_ ( tarball, unpackTarget, dMode, fMode, uid, gid, cb ) {
+ rm(unpackTarget, function (er) {
if (er) return cb(er)
- tarballLock = true
- next()
- })
-
- function next() {
- if (!tarballLock || !folderLock) return
- rmGunz()
- }
-
- function rmGunz () {
- rm(unpackTarget, function (er) {
- if (er) return cb(er)
- gtp()
- })
- }
-
- function gtp () {
// gzip {tarball} --decompress --stdout \
// | tar -mvxpf - --strip-components=1 -C {unpackTarget}
gunzTarPerm( tarball, unpackTarget
@@ -184,7 +100,7 @@
if (er) return cb(er)
readJson(path.resolve(folder, "package.json"), cb)
})
- }
+ })
}
@@ -202,6 +118,17 @@
var fst = fs.createReadStream(tarball)
+ fst.on("open", function (fd) {
+ fs.fstat(fd, function (er, st) {
+ if (er) return fst.emit("error", er)
+ if (st.size === 0) {
+ er = new Error("0-byte tarball\n" +
+ "Please run `npm cache clean`")
+ fst.emit("error", er)
+ }
+ })
+ })
+
// figure out who we're supposed to be, if we're not pretending
// to be a specific user.
if (npm.config.get("unsafe-perm") && process.platform !== "win32") {
@@ -275,73 +202,74 @@
}
- fst.on("error", function (er) {
- if (er) log.error("tar.unpack", "error reading "+tarball)
- cb(er)
- })
- fst.on("data", function OD (c) {
- // detect what it is.
- // Then, depending on that, we'll figure out whether it's
- // a single-file module, gzipped tarball, or naked tarball.
- // gzipped files all start with 1f8b08
- if (c[0] === 0x1F &&
- c[1] === 0x8B &&
- c[2] === 0x08) {
- fst
- .pipe(zlib.Unzip())
- .on("error", function (er) {
- if (er) log.error("tar.unpack", "unzip error "+tarball)
- cb(er)
- })
- .pipe(tar.Extract(extractOpts))
- .on("entry", extractEntry)
- .on("error", function (er) {
- if (er) log.error("tar.unpack", "untar error "+tarball)
- cb(er)
- })
- .on("close", cb)
- } else if (c.toString().match(/^package\//) ||
- c.toString().match(/^pax_global_header/)) {
- // naked tar
- fst
- .pipe(tar.Extract(extractOpts))
- .on("entry", extractEntry)
- .on("error", function (er) {
- if (er) log.error("tar.unpack", "untar error "+tarball)
- cb(er)
- })
- .on("close", cb)
- } else {
- // naked js file
- var jsOpts = { path: path.resolve(target, "index.js") }
-
- if (process.platform !== "win32" &&
- typeof uid === "number" &&
- typeof gid === "number") {
- jsOpts.uid = uid
- jsOpts.gid = gid
- }
+ fst
+ .on("error", function (er) {
+ if (er) log.error("tar.unpack", "error reading "+tarball)
+ cb(er)
+ })
+ .on("data", function OD (c) {
+ // detect what it is.
+ // Then, depending on that, we'll figure out whether it's
+ // a single-file module, gzipped tarball, or naked tarball.
+ // gzipped files all start with 1f8b08
+ if (c[0] === 0x1F &&
+ c[1] === 0x8B &&
+ c[2] === 0x08) {
+ fst
+ .pipe(zlib.Unzip())
+ .on("error", function (er) {
+ if (er) log.error("tar.unpack", "unzip error "+tarball)
+ cb(er)
+ })
+ .pipe(tar.Extract(extractOpts))
+ .on("entry", extractEntry)
+ .on("error", function (er) {
+ if (er) log.error("tar.unpack", "untar error "+tarball)
+ cb(er)
+ })
+ .on("close", cb)
+ } else if (c.toString().match(/^package\//) ||
+ c.toString().match(/^pax_global_header/)) {
+ // naked tar
+ fst
+ .pipe(tar.Extract(extractOpts))
+ .on("entry", extractEntry)
+ .on("error", function (er) {
+ if (er) log.error("tar.unpack", "untar error "+tarball)
+ cb(er)
+ })
+ .on("close", cb)
+ } else {
+ // naked js file
+ var jsOpts = { path: path.resolve(target, "index.js") }
+
+ if (process.platform !== "win32" &&
+ typeof uid === "number" &&
+ typeof gid === "number") {
+ jsOpts.uid = uid
+ jsOpts.gid = gid
+ }
- fst
- .pipe(fstream.Writer(jsOpts))
- .on("error", function (er) {
- if (er) log.error("tar.unpack", "copy error "+tarball)
- cb(er)
- })
- .on("close", function () {
- var j = path.resolve(target, "package.json")
- readJson(j, function (er, d) {
- if (er) {
- log.error("not a package", tarball)
- return cb(er)
- }
- fs.writeFile(j, JSON.stringify(d) + "\n", cb)
+ fst
+ .pipe(fstream.Writer(jsOpts))
+ .on("error", function (er) {
+ if (er) log.error("tar.unpack", "copy error "+tarball)
+ cb(er)
})
- })
- }
+ .on("close", function () {
+ var j = path.resolve(target, "package.json")
+ readJson(j, function (er, d) {
+ if (er) {
+ log.error("not a package", tarball)
+ return cb(er)
+ }
+ writeFileAtomic(j, JSON.stringify(d) + "\n", cb)
+ })
+ })
+ }
- // now un-hook, and re-emit the chunk
- fst.removeListener("data", OD)
- fst.emit("data", c)
- })
+ // now un-hook, and re-emit the chunk
+ fst.removeListener("data", OD)
+ fst.emit("data", c)
+ })
}
diff -Nru nodejs-0.11.14/deps/npm/lib/version.js nodejs-0.11.15/deps/npm/lib/version.js
--- nodejs-0.11.14/deps/npm/lib/version.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/version.js 2015-01-20 21:22:17.000000000 +0000
@@ -6,6 +6,7 @@
, semver = require("semver")
, path = require("path")
, fs = require("graceful-fs")
+ , writeFileAtomic = require("write-file-atomic")
, chain = require("slide").chain
, log = require("npmlog")
, which = require("which")
@@ -83,6 +84,15 @@
// check for git
git.whichAndExec(args, options, function (er, stdout) {
+ if (er && er.code === "ENOGIT") {
+ log.warn(
+ "version",
+ "This is a Git checkout, but the git command was not found.",
+ "npm could not create a Git tag for this release!"
+ )
+ return write(data, cb)
+ }
+
var lines = stdout.trim().split("\n").filter(function (line) {
return line.trim() && !line.match(/^\?\? /)
}).map(function (line) {
@@ -111,7 +121,7 @@
}
function write (data, cb) {
- fs.writeFile( path.join(npm.localPrefix, "package.json")
+ writeFileAtomic( path.join(npm.localPrefix, "package.json")
, new Buffer(JSON.stringify(data, null, 2) + "\n")
, cb )
}
diff -Nru nodejs-0.11.14/deps/npm/lib/view.js nodejs-0.11.15/deps/npm/lib/view.js
--- nodejs-0.11.14/deps/npm/lib/view.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/lib/view.js 2015-01-20 21:22:17.000000000 +0000
@@ -35,11 +35,12 @@
var p = pref.concat(k).join(".")
f.push(p)
if (Array.isArray(d[k])) {
- return d[k].forEach(function (val, i) {
+ d[k].forEach(function (val, i) {
var pi = p + "[" + i + "]"
if (val && typeof val === "object") getFields(val, f, [p])
else f.push(pi)
})
+ return
}
if (typeof d[k] === "object") getFields(d[k], f, [p])
})
@@ -48,24 +49,54 @@
}
var npm = require("./npm.js")
+ , readJson = require("read-package-json")
, registry = npm.registry
, log = require("npmlog")
, util = require("util")
, semver = require("semver")
, mapToRegistry = require("./utils/map-to-registry.js")
, npa = require("npm-package-arg")
+ , path = require("path")
function view (args, silent, cb) {
if (typeof cb !== "function") cb = silent, silent = false
- if (!args.length) return cb("Usage: "+view.usage)
+
+ if (!args.length) args = ["."]
+
var pkg = args.shift()
, nv = npa(pkg)
, name = nv.name
- , version = nv.rawSpec || npm.config.get("tag")
+ , local = (name === "." || !name)
+
+ if (npm.config.get("global") && local) {
+ return cb(new Error("Cannot use view command in global mode."))
+ }
+
+ if (local) {
+ var dir = npm.prefix
+ readJson(path.resolve(dir, "package.json"), function (er, d) {
+ d = d || {}
+ if (er && er.code !== "ENOENT" && er.code !== "ENOTDIR") return cb(er)
+ if (!d.name) return cb(new Error("Invalid package.json"))
+
+ var p = d.name
+ nv = npa(p)
+ if (pkg && ~pkg.indexOf("@")) {
+ nv.rawSpec = pkg.split("@")[pkg.indexOf("@")]
+ }
- if (name === ".") return cb(view.usage)
+ fetchAndRead(nv, args, silent, cb)
+ })
+ } else {
+ fetchAndRead(nv, args, silent, cb)
+ }
+}
+function fetchAndRead (nv, args, silent, cb) {
// get the data about this package
+ var name = nv.name
+ , version = nv.rawSpec || npm.config.get("tag")
+
mapToRegistry(name, npm.config, function (er, uri) {
if (er) return cb(er)
@@ -184,9 +215,7 @@
results = results.reduce(reducer, {})
return results
}
- if (!data.hasOwnProperty(field)) {
- return
- }
+ if (!data.hasOwnProperty(field)) return undefined
data = data[field]
if (tail.length) {
if (typeof data === "object") {
@@ -205,15 +234,15 @@
function printData (data, name, cb) {
var versions = Object.keys(data)
, msg = ""
- , showVersions = versions.length > 1
- , showFields
+ , includeVersions = versions.length > 1
+ , includeFields
versions.forEach(function (v) {
var fields = Object.keys(data[v])
- showFields = showFields || (fields.length > 1)
+ includeFields = includeFields || (fields.length > 1)
fields.forEach(function (f) {
var d = cleanup(data[v][f])
- if (showVersions || showFields || typeof d !== "string") {
+ if (includeVersions || includeFields || typeof d !== "string") {
d = cleanup(data[v][f])
d = npm.config.get("json")
? JSON.stringify(d, null, 2)
@@ -221,10 +250,10 @@
} else if (typeof d === "string" && npm.config.get("json")) {
d = JSON.stringify(d)
}
- if (f && showFields) f += " = "
+ if (f && includeFields) f += " = "
if (d.indexOf("\n") !== -1) d = " \n" + d
- msg += (showVersions ? name + "@" + v + " " : "")
- + (showFields ? f : "") + d + "\n"
+ msg += (includeVersions ? name + "@" + v + " " : "")
+ + (includeFields ? f : "") + d + "\n"
})
})
@@ -268,4 +297,3 @@
+ (d.email ? " <"+d.email+">" : "")
+ (d.url ? " ("+d.url+")" : "")
}
-
diff -Nru nodejs-0.11.14/deps/npm/Makefile nodejs-0.11.15/deps/npm/Makefile
--- nodejs-0.11.14/deps/npm/Makefile 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/Makefile 2015-01-20 21:22:17.000000000 +0000
@@ -31,6 +31,28 @@
|sed 's|doc/misc/|man/man7/|g' ) \
man/man7/npm-index.7
+
+cli_partdocs = $(shell find doc/cli -name '*.md' \
+ |sed 's|.md|.html|g' \
+ |sed 's|doc/cli/|html/partial/doc/cli/|g' ) \
+ html/partial/doc/README.html
+
+api_partdocs = $(shell find doc/api -name '*.md' \
+ |sed 's|.md|.html|g' \
+ |sed 's|doc/api/|html/partial/doc/api/|g' )
+
+files_partdocs = $(shell find doc/files -name '*.md' \
+ |sed 's|.md|.html|g' \
+ |sed 's|doc/files/|html/partial/doc/files/|g' ) \
+ html/partial/doc/files/npm-json.html \
+ html/partial/doc/files/npm-global.html
+
+misc_partdocs = $(shell find doc/misc -name '*.md' \
+ |sed 's|.md|.html|g' \
+ |sed 's|doc/misc/|html/partial/doc/misc/|g' ) \
+ html/partial/doc/index.html
+
+
cli_htmldocs = $(shell find doc/cli -name '*.md' \
|sed 's|.md|.html|g' \
|sed 's|doc/cli/|html/doc/cli/|g' ) \
@@ -53,6 +75,8 @@
mandocs = $(api_mandocs) $(cli_mandocs) $(files_mandocs) $(misc_mandocs)
+partdocs = $(api_partdocs) $(cli_partdocs) $(files_partdocs) $(misc_partdocs)
+
htmldocs = $(api_htmldocs) $(cli_htmldocs) $(files_htmldocs) $(misc_htmldocs)
all: doc
@@ -63,7 +87,7 @@
@echo "in this folder that you're looking at right now."
node cli.js install -g -f npm
-install: docclean all
+install: all
node cli.js install -g -f
# backwards compat
@@ -79,7 +103,7 @@
uninstall:
node cli.js rm npm -g -f
-doc: $(mandocs) $(htmldocs)
+doc: $(mandocs) $(htmldocs) $(partdocs)
markedclean:
rm -rf node_modules/marked node_modules/.bin/marked .building_marked
@@ -119,43 +143,73 @@
@[ -d man/man5 ] || mkdir -p man/man5
scripts/doc-build.sh $< $@
+man/man7/%.7: doc/misc/%.md scripts/doc-build.sh package.json
+ @[ -d man/man7 ] || mkdir -p man/man7
+ scripts/doc-build.sh $< $@
+
+
doc/misc/npm-index.md: scripts/index-build.js package.json
node scripts/index-build.js > $@
-html/doc/index.html: doc/misc/npm-index.md $(html_docdeps)
- @[ -d html/doc ] || mkdir -p html/doc
- scripts/doc-build.sh $< $@
-man/man7/%.7: doc/misc/%.md scripts/doc-build.sh package.json
- @[ -d man/man7 ] || mkdir -p man/man7
+# html/doc depends on html/partial/doc
+html/doc/%.html: html/partial/doc/%.html
+ @[ -d html/doc ] || mkdir -p html/doc
scripts/doc-build.sh $< $@
-html/doc/README.html: README.md $(html_docdeps)
+html/doc/README.html: html/partial/doc/README.html
@[ -d html/doc ] || mkdir -p html/doc
scripts/doc-build.sh $< $@
-html/doc/cli/%.html: doc/cli/%.md $(html_docdeps)
+html/doc/cli/%.html: html/partial/doc/cli/%.html
@[ -d html/doc/cli ] || mkdir -p html/doc/cli
scripts/doc-build.sh $< $@
-html/doc/api/%.html: doc/api/%.md $(html_docdeps)
+html/doc/misc/%.html: html/partial/doc/misc/%.html
+ @[ -d html/doc/misc ] || mkdir -p html/doc/misc
+ scripts/doc-build.sh $< $@
+
+html/doc/files/%.html: html/partial/doc/files/%.html
+ @[ -d html/doc/files ] || mkdir -p html/doc/files
+ scripts/doc-build.sh $< $@
+
+html/doc/api/%.html: html/partial/doc/api/%.html
@[ -d html/doc/api ] || mkdir -p html/doc/api
scripts/doc-build.sh $< $@
-html/doc/files/npm-json.html: html/doc/files/package.json.html
+
+html/partial/doc/index.html: doc/misc/npm-index.md $(html_docdeps)
+ @[ -d html/partial/doc ] || mkdir -p html/partial/doc
+ scripts/doc-build.sh $< $@
+
+html/partial/doc/README.html: README.md $(html_docdeps)
+ @[ -d html/partial/doc ] || mkdir -p html/partial/doc
+ scripts/doc-build.sh $< $@
+
+html/partial/doc/cli/%.html: doc/cli/%.md $(html_docdeps)
+ @[ -d html/partial/doc/cli ] || mkdir -p html/partial/doc/cli
+ scripts/doc-build.sh $< $@
+
+html/partial/doc/api/%.html: doc/api/%.md $(html_docdeps)
+ @[ -d html/partial/doc/api ] || mkdir -p html/partial/doc/api
+ scripts/doc-build.sh $< $@
+
+html/partial/doc/files/npm-json.html: html/partial/doc/files/package.json.html
cp $< $@
-html/doc/files/npm-global.html: html/doc/files/npm-folders.html
+html/partial/doc/files/npm-global.html: html/partial/doc/files/npm-folders.html
cp $< $@
-html/doc/files/%.html: doc/files/%.md $(html_docdeps)
- @[ -d html/doc/files ] || mkdir -p html/doc/files
+html/partial/doc/files/%.html: doc/files/%.md $(html_docdeps)
+ @[ -d html/partial/doc/files ] || mkdir -p html/partial/doc/files
scripts/doc-build.sh $< $@
-html/doc/misc/%.html: doc/misc/%.md $(html_docdeps)
- @[ -d html/doc/misc ] || mkdir -p html/doc/misc
+html/partial/doc/misc/%.html: doc/misc/%.md $(html_docdeps)
+ @[ -d html/partial/doc/misc ] || mkdir -p html/partial/doc/misc
scripts/doc-build.sh $< $@
+
+
marked: node_modules/.bin/marked
node_modules/.bin/marked:
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm.1 nodejs-0.11.15/deps/npm/man/man1/npm.1
--- nodejs-0.11.14/deps/npm/man/man1/npm.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,16 +1,16 @@
-.TH "NPM" "1" "September 2014" "" ""
+.TH "NPM" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm\fR \- node package manager
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm [args]
-.EE
+.fi
.RE
.SH VERSION
.P
-2.0.0
+2.1.6
.SH DESCRIPTION
.P
npm is the package manager for the Node JavaScript platform\. It puts
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-adduser.1 nodejs-0.11.15/deps/npm/man/man1/npm-adduser.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-adduser.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-adduser.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-ADDUSER" "1" "September 2014" "" ""
+.TH "NPM\-ADDUSER" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-adduser\fR \- Add a registry user account
.SH SYNOPSIS
.P
.RS 2
-.EX
-npm adduser [\-\-registry=url] [\-\-scope=@orgname]
-.EE
+.nf
+npm adduser [\-\-registry=url] [\-\-scope=@orgname] [\-\-always\-auth]
+.fi
.RE
.SH DESCRIPTION
.P
@@ -41,13 +41,31 @@
e\.g\.
.P
.RS 2
-.EX
+.nf
npm adduser \-\-registry=http://myregistry\.example\.com \-\-scope=@myco
-.EE
+.fi
.RE
.P
This will set a registry for the given scope and login or create a user for
that registry at the same time\.
+.SS always\-auth
+.P
+Default: false
+.P
+If specified, save configuration indicating that all requests to the given
+registry should include authorization information\. Useful for private
+registries\. Can be used with \fB\-\-registry\fR and / or \fB\-\-scope\fR, e\.g\.
+.P
+.RS 2
+.nf
+npm adduser \-\-registry=http://private\-registry\.example\.com \-\-always\-auth
+.fi
+.RE
+.P
+This will ensure that all requests to that registry (including for tarballs)
+include an authorization header\. See \fBalways\-auth\fR in npm help 7 \fBnpm\-config\fR for more
+details on always\-auth\. Registry\-specific configuaration of \fBalways\-auth\fR takes
+precedence over any global configuration\.
.SH SEE ALSO
.RS 0
.IP \(bu 2
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-bin.1 nodejs-0.11.15/deps/npm/man/man1/npm-bin.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-bin.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-bin.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-BIN" "1" "September 2014" "" ""
+.TH "NPM\-BIN" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-bin\fR \- Display npm bin folder
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm bin
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-bugs.1 nodejs-0.11.15/deps/npm/man/man1/npm-bugs.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-bugs.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-bugs.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,13 +1,13 @@
-.TH "NPM\-BUGS" "1" "September 2014" "" ""
+.TH "NPM\-BUGS" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-bugs\fR \- Bugs for a package in a web browser maybe
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm bugs
npm bugs (with no args in a package dir)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-build.1 nodejs-0.11.15/deps/npm/man/man1/npm-build.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-build.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-build.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-BUILD" "1" "September 2014" "" ""
+.TH "NPM\-BUILD" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-build\fR \- Build a package
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm build
-.EE
+.fi
.RE
.RS 0
.IP \(bu 2
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-bundle.1 nodejs-0.11.15/deps/npm/man/man1/npm-bundle.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-bundle.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-bundle.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,4 +1,4 @@
-.TH "NPM\-BUNDLE" "1" "September 2014" "" ""
+.TH "NPM\-BUNDLE" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-bundle\fR \- REMOVED
.SH DESCRIPTION
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-cache.1 nodejs-0.11.15/deps/npm/man/man1/npm-cache.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-cache.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-cache.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,10 +1,10 @@
-.TH "NPM\-CACHE" "1" "September 2014" "" ""
+.TH "NPM\-CACHE" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-cache\fR \- Manipulates packages cache
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm cache add
npm cache add
npm cache add
@@ -13,7 +13,7 @@
npm cache ls []
npm cache clean []
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-completion.1 nodejs-0.11.15/deps/npm/man/man1/npm-completion.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-completion.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-completion.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-COMPLETION" "1" "September 2014" "" ""
+.TH "NPM\-COMPLETION" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-completion\fR \- Tab Completion for npm
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
\|\. <(npm completion)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-config.1 nodejs-0.11.15/deps/npm/man/man1/npm-config.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-config.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-config.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,10 +1,10 @@
-.TH "NPM\-CONFIG" "1" "September 2014" "" ""
+.TH "NPM\-CONFIG" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-config\fR \- Manage the npm configuration files
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm config set [\-\-global]
npm config get
npm config delete
@@ -13,7 +13,7 @@
npm c [set|get|delete|list]
npm get
npm set [\-\-global]
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
@@ -33,9 +33,9 @@
.SS set
.P
.RS 2
-.EX
+.nf
npm config set key value
-.EE
+.fi
.RE
.P
Sets the config key to the value\.
@@ -44,36 +44,36 @@
.SS get
.P
.RS 2
-.EX
+.nf
npm config get key
-.EE
+.fi
.RE
.P
Echo the config value to stdout\.
.SS list
.P
.RS 2
-.EX
+.nf
npm config list
-.EE
+.fi
.RE
.P
Show all the config settings\.
.SS delete
.P
.RS 2
-.EX
+.nf
npm config delete key
-.EE
+.fi
.RE
.P
Deletes the key from all configuration files\.
.SS edit
.P
.RS 2
-.EX
+.nf
npm config edit
-.EE
+.fi
.RE
.P
Opens the config file in an editor\. Use the \fB\-\-global\fR flag to edit the
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-dedupe.1 nodejs-0.11.15/deps/npm/man/man1/npm-dedupe.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-dedupe.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-dedupe.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,13 +1,13 @@
-.TH "NPM\-DEDUPE" "1" "September 2014" "" ""
+.TH "NPM\-DEDUPE" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-dedupe\fR \- Reduce duplication
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm dedupe [package names\.\.\.]
npm ddp [package names\.\.\.]
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
@@ -18,24 +18,24 @@
For example, consider this dependency graph:
.P
.RS 2
-.EX
+.nf
a
+\-\- b <\-\- depends on c@1\.0\.x
| `\-\- c@1\.0\.3
`\-\- d <\-\- depends on c@~1\.0\.9
`\-\- c@1\.0\.10
-.EE
+.fi
.RE
.P
In this case, npm help \fBnpm\-dedupe\fR will transform the tree to:
.P
.RS 2
-.EX
+.nf
a
+\-\- b
+\-\- d
`\-\- c@1\.0\.10
-.EE
+.fi
.RE
.P
Because of the hierarchical nature of node's module lookup, b and d
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-deprecate.1 nodejs-0.11.15/deps/npm/man/man1/npm-deprecate.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-deprecate.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-deprecate.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-DEPRECATE" "1" "September 2014" "" ""
+.TH "NPM\-DEPRECATE" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-deprecate\fR \- Deprecate a version of a package
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm deprecate [@]
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
@@ -17,9 +17,9 @@
something like this:
.P
.RS 2
-.EX
+.nf
npm deprecate my\-thing@"< 0\.2\.3" "critical bug fixed in v0\.2\.3"
-.EE
+.fi
.RE
.P
Note that you must be the package owner to deprecate something\. See the
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-docs.1 nodejs-0.11.15/deps/npm/man/man1/npm-docs.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-docs.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-docs.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,15 +1,15 @@
-.TH "NPM\-DOCS" "1" "September 2014" "" ""
+.TH "NPM\-DOCS" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-docs\fR \- Docs for a package in a web browser maybe
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm docs [ [ \.\.\.]]
npm docs (with no args in a package dir)
npm home [ [ \.\.\.]]
npm home (with no args in a package dir)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-edit.1 nodejs-0.11.15/deps/npm/man/man1/npm-edit.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-edit.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-edit.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-EDIT" "1" "September 2014" "" ""
+.TH "NPM\-EDIT" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-edit\fR \- Edit an installed package
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm edit [@]
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-explore.1 nodejs-0.11.15/deps/npm/man/man1/npm-explore.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-explore.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-explore.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-EXPLORE" "1" "September 2014" "" ""
+.TH "NPM\-EXPLORE" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-explore\fR \- Browse an installed package
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm explore [ \-\- ]
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
@@ -19,9 +19,9 @@
\fBnode_modules\fR folder:
.P
.RS 2
-.EX
+.nf
npm explore some\-dependency \-\- git pull origin master
-.EE
+.fi
.RE
.P
Note that the package is \fInot\fR automatically rebuilt afterwards, so be
@@ -41,8 +41,6 @@
.SH SEE ALSO
.RS 0
.IP \(bu 2
-npm help submodule
-.IP \(bu 2
npm help 5 folders
.IP \(bu 2
npm help edit
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-help.1 nodejs-0.11.15/deps/npm/man/man1/npm-help.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-help.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-help.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,13 +1,13 @@
-.TH "NPM\-HELP" "1" "September 2014" "" ""
+.TH "NPM\-HELP" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-help\fR \- Get help on npm
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm help
npm help some search terms
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-help-search.1 nodejs-0.11.15/deps/npm/man/man1/npm-help-search.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-help-search.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-help-search.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-HELP\-SEARCH" "1" "September 2014" "" ""
+.TH "NPM\-HELP\-SEARCH" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-help-search\fR \- Search npm help documentation
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm help\-search some search terms
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-init.1 nodejs-0.11.15/deps/npm/man/man1/npm-init.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-init.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-init.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-INIT" "1" "September 2014" "" ""
+.TH "NPM\-INIT" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-init\fR \- Interactively create a package\.json file
.SH SYNOPSIS
.P
.RS 2
-.EX
-npm init
-.EE
+.nf
+npm init [\-f|\-\-force|\-y|\-\-yes]
+.fi
.RE
.SH DESCRIPTION
.P
@@ -20,6 +20,9 @@
.P
It is strictly additive, so it does not delete options from your package\.json
without a really good reason to do so\.
+.P
+If you invoke it with \fB\-f\fR, \fB\-\-force\fR, \fB\-y\fR, or \fB\-\-yes\fR, it will use only
+defaults and not prompt you for any options\.
.SH SEE ALSO
.RS 0
.IP \(bu 2
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-install.1 nodejs-0.11.15/deps/npm/man/man1/npm-install.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-install.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-install.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,10 +1,10 @@
-.TH "NPM\-INSTALL" "1" "September 2014" "" ""
+.TH "NPM\-INSTALL" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-install\fR \- Install a package
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm install (with no args in a package dir)
npm install
npm install
@@ -14,7 +14,7 @@
npm install [@/]@
npm install [@/]@
npm i (with any of the previous argument usage)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
@@ -66,9 +66,9 @@
Example:
.P
.RS 2
-.EX
+.nf
npm install \./package\.tgz
-.EE
+.fi
.RE
.IP \(bu 2
\fBnpm install \fR:
@@ -77,9 +77,9 @@
Example:
.P
.RS 2
-.EX
+.nf
npm install https://github\.com/indexzero/forever/tarball/v0\.5\.6
-.EE
+.fi
.RE
.IP \(bu 2
\fBnpm install [@/] [\-\-save|\-\-save\-dev|\-\-save\-optional]\fR:
@@ -90,9 +90,9 @@
Example:
.P
.RS 2
-.EX
+.nf
npm install sax
-.EE
+.fi
.RE
\fBnpm install\fR takes 3 exclusive, optional flags which save or update
the package version in your main package\.json:
@@ -118,14 +118,14 @@
Examples:
.P
.RS 2
-.EX
+.nf
npm install sax \-\-save
npm install githubname/reponame
npm install @myorg/privatepackage
npm install node\-tap \-\-save\-dev
npm install dtrace\-provider \-\-save\-optional
npm install readable\-stream \-\-save \-\-save\-exact
-.EE
+.fi
.RE
.RE
@@ -133,11 +133,11 @@
.RE
.P
.RS 2
-.EX
+.nf
**Note**: If there is a file or folder named `` in the current
working directory, then it will try to install that, and only try to
fetch the package by name if it is not valid\.
-.EE
+.fi
.RE
.RS 0
.IP \(bu 2
@@ -148,10 +148,10 @@
Example:
.P
.RS 2
-.EX
+.nf
npm install sax@latest
npm install @myorg/mypackage@latest
-.EE
+.fi
.RE
.IP \(bu 2
\fBnpm install [@/]@\fR:
@@ -160,10 +160,10 @@
Example:
.P
.RS 2
-.EX
+.nf
npm install sax@0\.1\.1
npm install @myorg/privatepackage@1\.5\.0
-.EE
+.fi
.RE
.IP \(bu 2
\fBnpm install [@/]@\fR:
@@ -174,10 +174,10 @@
Example:
.P
.RS 2
-.EX
+.nf
npm install sax@">=0\.1\.0 <0\.2\.0"
npm install @myorg/privatepackage@">=0\.1\.0 <0\.2\.0"
-.EE
+.fi
.RE
.IP \(bu 2
\fBnpm install /\fR:
@@ -186,9 +186,9 @@
Example:
.P
.RS 2
-.EX
+.nf
npm install mygithubuser/myproject
-.EE
+.fi
.RE
To reference a package in a git repo that is not on GitHub, see git
remote urls below\.
@@ -198,9 +198,9 @@
url is:
.P
.RS 2
-.EX
+.nf
://[@][#]
-.EE
+.fi
.RE
\fB\fR is one of \fBgit\fR, \fBgit+ssh\fR, \fBgit+http\fR, or
\fBgit+https\fR\|\. If no \fB\fR is specified, then \fBmaster\fR is
@@ -208,11 +208,11 @@
Examples:
.P
.RS 2
-.EX
+.nf
git+ssh://git@github\.com:npm/npm\.git#v1\.0\.27
git+https://isaacs@github\.com/npm/npm\.git
git://github\.com/npm/npm\.git#v1\.0\.27
-.EE
+.fi
.RE
.RE
@@ -221,9 +221,9 @@
For example:
.P
.RS 2
-.EX
+.nf
npm install sax@">=0\.1\.0 <0\.2\.0" bench supervisor
-.EE
+.fi
.RE
.P
The \fB\-\-tag\fR argument will apply to all of the specified install targets\. If a
@@ -234,9 +234,9 @@
local copy exists on disk\.
.P
.RS 2
-.EX
+.nf
npm install sax \-\-force
-.EE
+.fi
.RE
.P
The \fB\-\-global\fR argument will cause npm to install the package globally
@@ -264,7 +264,7 @@
To install a package, npm uses the following algorithm:
.P
.RS 2
-.EX
+.nf
install(where, what, family, ancestors)
fetch what, unpack to /node_modules/
for each dep in what\.dependencies
@@ -274,19 +274,19 @@
and not in
add precise version deps to
install(/node_modules/, dep, family)
-.EE
+.fi
.RE
.P
For this \fBpackage{dep}\fR structure: \fBA{B,C}, B{C}, C{D}\fR,
this algorithm produces:
.P
.RS 2
-.EX
+.nf
A
+\-\- B
`\-\- C
`\-\- D
-.EE
+.fi
.RE
.P
That is, the dependency from B to C is satisfied by the fact that A
@@ -301,9 +301,9 @@
the simplest case:
.P
.RS 2
-.EX
+.nf
A \-> B \-> A' \-> B' \-> A \-> B \-> A' \-> B' \-> A \-> \.\.\.
-.EE
+.fi
.RE
.P
where \fBA\fR is some version of a package, and \fBA'\fR is a different version
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-link.1 nodejs-0.11.15/deps/npm/man/man1/npm-link.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-link.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-link.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,14 +1,14 @@
-.TH "NPM\-LINK" "1" "September 2014" "" ""
+.TH "NPM\-LINK" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-link\fR \- Symlink a package folder
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm link (in package folder)
npm link [@/]
npm ln (with any of the previous argument usage)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
@@ -36,12 +36,12 @@
For example:
.P
.RS 2
-.EX
+.nf
cd ~/projects/node\-redis # go into the package directory
npm link # creates global link
cd ~/projects/node\-bloggy # go into some other package directory\.
npm link redis # link\-install the package
-.EE
+.fi
.RE
.P
Now, any changes to ~/projects/node\-redis will be reflected in
@@ -51,19 +51,19 @@
above use\-case in a shorter way:
.P
.RS 2
-.EX
+.nf
cd ~/projects/node\-bloggy # go into the dir of your main project
npm link \.\./node\-redis # link the dir of your dependency
-.EE
+.fi
.RE
.P
The second line is the equivalent of doing:
.P
.RS 2
-.EX
+.nf
(cd \.\./node\-redis; npm link)
npm link redis
-.EE
+.fi
.RE
.P
That is, it first creates a global link, and then links the global
@@ -73,9 +73,9 @@
include that scope, e\.g\.
.P
.RS 2
-.EX
+.nf
npm link @myorg/privatepackage
-.EE
+.fi
.RE
.SH SEE ALSO
.RS 0
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-ls.1 nodejs-0.11.15/deps/npm/man/man1/npm-ls.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-ls.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-ls.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,15 +1,15 @@
-.TH "NPM\-LS" "1" "September 2014" "" ""
+.TH "NPM\-LS" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-ls\fR \- List installed packages
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm list [[@/] \.\.\.]
npm ls [[@/] \.\.\.]
npm la [[@/] \.\.\.]
npm ll [[@/] \.\.\.]
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
@@ -22,11 +22,11 @@
For example, running \fBnpm ls promzard\fR in npm's source tree will show:
.P
.RS 2
-.EX
-npm@2.0.0 /path/to/npm
+.nf
+npm@2.1.6 /path/to/npm
└─┬ init\-package\-json@0\.0\.4
└── promzard@0\.1\.5
-.EE
+.fi
.RE
.P
It will print out extraneous, missing, and invalid packages\.
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-outdated.1 nodejs-0.11.15/deps/npm/man/man1/npm-outdated.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-outdated.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-outdated.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-OUTDATED" "1" "September 2014" "" ""
+.TH "NPM\-OUTDATED" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-outdated\fR \- Check for outdated packages
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm outdated [ [ \.\.\.]]
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-owner.1 nodejs-0.11.15/deps/npm/man/man1/npm-owner.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-owner.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-owner.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,14 +1,14 @@
-.TH "NPM\-OWNER" "1" "September 2014" "" ""
+.TH "NPM\-OWNER" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-owner\fR \- Manage package owners
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm owner ls
npm owner add
npm owner rm
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-pack.1 nodejs-0.11.15/deps/npm/man/man1/npm-pack.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-pack.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-pack.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-PACK" "1" "September 2014" "" ""
+.TH "NPM\-PACK" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-pack\fR \- Create a tarball from a package
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm pack [ [ \.\.\.]]
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-prefix.1 nodejs-0.11.15/deps/npm/man/man1/npm-prefix.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-prefix.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-prefix.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-PREFIX" "1" "September 2014" "" ""
+.TH "NPM\-PREFIX" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-prefix\fR \- Display prefix
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm prefix [\-g]
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-prune.1 nodejs-0.11.15/deps/npm/man/man1/npm-prune.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-prune.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-prune.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,13 +1,13 @@
-.TH "NPM\-PRUNE" "1" "September 2014" "" ""
+.TH "NPM\-PRUNE" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-prune\fR \- Remove extraneous packages
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm prune [ [ [ [\-\-tag ]
npm publish [\-\-tag ]
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
-Publishes a package to the registry so that it can be installed by name\.
+Publishes a package to the registry so that it can be installed by name\. See
+npm help 7 \fBnpm\-developers\fR for details on what's included in the published package, as
+well as details on how the package is built\.
.P
By default npm will publish to the public registry\. This can be overridden by
specifying a different default registry or using a npm help 7 \fBnpm\-scope\fR in the name
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-README.1 nodejs-0.11.15/deps/npm/man/man1/npm-README.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-README.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-README.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,4 +1,4 @@
-.TH "NPM" "1" "September 2014" "" ""
+.TH "NPM" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm\fR \- node package manager
.P
@@ -37,26 +37,26 @@
Here's an example using curl:
.P
.RS 2
-.EX
+.nf
curl \-L https://npmjs\.org/install\.sh | sh
-.EE
+.fi
.RE
.SS Slightly Fancier
.P
You can set any npm configuration params with that script:
.P
.RS 2
-.EX
+.nf
npm_config_prefix=/some/path sh install\.sh
-.EE
+.fi
.RE
.P
Or, you can run it in uber\-debuggery mode:
.P
.RS 2
-.EX
+.nf
npm_debug=1 sh install\.sh
-.EE
+.fi
.RE
.SS Even Fancier
.P
@@ -102,9 +102,9 @@
set the following configuration param:
.P
.RS 2
-.EX
+.nf
npm config set unsafe\-perm false
-.EE
+.fi
.RE
.P
This will prevent running in unsafe mode, even as non\-root users\.
@@ -113,17 +113,17 @@
So sad to see you go\.
.P
.RS 2
-.EX
+.nf
sudo npm uninstall npm \-g
-.EE
+.fi
.RE
.P
Or, if that fails,
.P
.RS 2
-.EX
+.nf
sudo make uninstall
-.EE
+.fi
.RE
.SH More Severe Uninstalling
.P
@@ -138,19 +138,19 @@
\fBclean\-old\.sh\fR script file\. You can run it conveniently like this:
.P
.RS 2
-.EX
+.nf
npm explore npm \-g \-\- sh scripts/clean\-old\.sh
-.EE
+.fi
.RE
.P
npm uses two configuration files, one for per\-user configs, and another
for global (every\-user) configs\. You can view them by doing:
.P
.RS 2
-.EX
+.nf
npm config get userconfig # defaults to ~/\.npmrc
npm config get globalconfig # defaults to /usr/local/etc/npmrc
-.EE
+.fi
.RE
.P
Uninstalling npm does not remove configuration files by default\. You
@@ -171,7 +171,7 @@
use npm itself to do\.
.P
.RS 2
-.EX
+.nf
var npm = require("npm")
npm\.load(myConfigObject, function (er) {
if (er) return handlError(er)
@@ -179,9 +179,9 @@
if (er) return commandFailed(er)
// command succeeded, and data might have some info
})
- npm\.on("log", function (message) { \.\.\.\. })
+ npm\.registry\.log\.on("log", function (message) { \.\.\.\. })
})
-.EE
+.fi
.RE
.P
The \fBload\fR function takes an object hash of the command\-line configs\.
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-rebuild.1 nodejs-0.11.15/deps/npm/man/man1/npm-rebuild.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-rebuild.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-rebuild.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,13 +1,13 @@
-.TH "NPM\-REBUILD" "1" "September 2014" "" ""
+.TH "NPM\-REBUILD" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-rebuild\fR \- Rebuild a package
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm rebuild [ [ \.\.\.]]
npm rb [ [ \.\.\.]]
-.EE
+.fi
.RE
.RS 0
.IP \(bu 2
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-repo.1 nodejs-0.11.15/deps/npm/man/man1/npm-repo.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-repo.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-repo.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,13 +1,13 @@
-.TH "NPM\-REPO" "1" "September 2014" "" ""
+.TH "NPM\-REPO" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-repo\fR \- Open package repository page in the browser
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm repo
npm repo (with no args in a package dir)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-restart.1 nodejs-0.11.15/deps/npm/man/man1/npm-restart.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-restart.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-restart.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,20 +1,17 @@
-.TH "NPM\-RESTART" "1" "September 2014" "" ""
+.TH "NPM\-RESTART" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-restart\fR \- Start a package
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm restart [\-\- ]
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
-This runs a package's "restart" script, if one was provided\.
-Otherwise it runs package's "stop" script, if one was provided, and then
-the "start" script\.
-.P
-If no version is specified, then it restarts the "active" version\.
+This runs a package's "restart" script, if one was provided\. Otherwise it runs
+package's "stop" script, if one was provided, and then the "start" script\.
.SH SEE ALSO
.RS 0
.IP \(bu 2
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-rm.1 nodejs-0.11.15/deps/npm/man/man1/npm-rm.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-rm.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-rm.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,15 +1,15 @@
-.TH "NPM\-RM" "1" "September 2014" "" ""
+.TH "NPM\-RM" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-rm\fR \- Remove a package
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm rm
npm r
npm uninstall
npm un
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-root.1 nodejs-0.11.15/deps/npm/man/man1/npm-root.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-root.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-root.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-ROOT" "1" "September 2014" "" ""
+.TH "NPM\-ROOT" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-root\fR \- Display npm root
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm root
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-run-script.1 nodejs-0.11.15/deps/npm/man/man1/npm-run-script.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-run-script.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-run-script.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,13 +1,13 @@
-.TH "NPM\-RUN\-SCRIPT" "1" "September 2014" "" ""
+.TH "NPM\-RUN\-SCRIPT" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-run-script\fR \- Run arbitrary package scripts
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm run\-script [command] [\-\- ]
npm run [command] [\-\- ]
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
@@ -18,6 +18,20 @@
.P
It is used by the test, start, restart, and stop commands, but can be
called directly, as well\.
+.P
+As of \fBnpm@2\.0\.0\fR \fIhttp://blog\.npmjs\.org/post/98131109725/npm\-2\-0\-0\fR, you can
+use custom arguments when executing scripts\. The special option \fB\-\-\fR is used by
+getopt \fIhttp://goo\.gl/KxMmtG\fR to delimit the end of the options\. npm will pass
+all the arguments after the \fB\-\-\fR directly to your script:
+.P
+.RS 2
+.nf
+npm run test \-\- \-\-grep="pattern"
+.fi
+.RE
+.P
+The arguments will only be passed to the script specified after \fBnpm run\fR
+and not to any pre or post script\.
.SH SEE ALSO
.RS 0
.IP \(bu 2
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-search.1 nodejs-0.11.15/deps/npm/man/man1/npm-search.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-search.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-search.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,14 +1,14 @@
-.TH "NPM\-SEARCH" "1" "September 2014" "" ""
+.TH "NPM\-SEARCH" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-search\fR \- Search for packages
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm search [\-\-long] [search terms \.\.\.]
npm s [search terms \.\.\.]
npm se [search terms \.\.\.]
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-shrinkwrap.1 nodejs-0.11.15/deps/npm/man/man1/npm-shrinkwrap.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-shrinkwrap.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-shrinkwrap.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-SHRINKWRAP" "1" "September 2014" "" ""
+.TH "NPM\-SHRINKWRAP" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-shrinkwrap\fR \- Lock down dependency versions
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm shrinkwrap
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
@@ -31,7 +31,7 @@
As an example, consider package A:
.P
.RS 2
-.EX
+.nf
{
"name": "A",
"version": "0\.1\.0",
@@ -39,13 +39,13 @@
"B": "<0\.1\.0"
}
}
-.EE
+.fi
.RE
.P
package B:
.P
.RS 2
-.EX
+.nf
{
"name": "B",
"version": "0\.0\.1",
@@ -53,40 +53,40 @@
"C": "<0\.1\.0"
}
}
-.EE
+.fi
.RE
.P
and package C:
.P
.RS 2
-.EX
+.nf
{
"name": "C,
"version": "0\.0\.1"
}
-.EE
+.fi
.RE
.P
If these are the only versions of A, B, and C available in the
registry, then a normal "npm install A" will install:
.P
.RS 2
-.EX
+.nf
A@0\.1\.0
`\-\- B@0\.0\.1
`\-\- C@0\.0\.1
-.EE
+.fi
.RE
.P
However, if B@0\.0\.2 is published, then a fresh "npm install A" will
install:
.P
.RS 2
-.EX
+.nf
A@0\.1\.0
`\-\- B@0\.0\.2
`\-\- C@0\.0\.1
-.EE
+.fi
.RE
.P
assuming the new version did not modify B's dependencies\. Of course,
@@ -100,15 +100,15 @@
In this case, A's author can run
.P
.RS 2
-.EX
+.nf
npm shrinkwrap
-.EE
+.fi
.RE
.P
This generates npm\-shrinkwrap\.json, which will look something like this:
.P
.RS 2
-.EX
+.nf
{
"name": "A",
"version": "0\.1\.0",
@@ -123,7 +123,7 @@
}
}
}
-.EE
+.fi
.RE
.P
The shrinkwrap command has locked down the dependencies based on
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-star.1 nodejs-0.11.15/deps/npm/man/man1/npm-star.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-star.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-star.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,13 +1,13 @@
-.TH "NPM\-STAR" "1" "September 2014" "" ""
+.TH "NPM\-STAR" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-star\fR \- Mark your favorite packages
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm star [, \.\.\.]
npm unstar [, \.\.\.]
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-stars.1 nodejs-0.11.15/deps/npm/man/man1/npm-stars.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-stars.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-stars.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,13 +1,13 @@
-.TH "NPM\-STARS" "1" "September 2014" "" ""
+.TH "NPM\-STARS" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-stars\fR \- View packages marked as favorites
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm stars
npm stars [username]
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-start.1 nodejs-0.11.15/deps/npm/man/man1/npm-start.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-start.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-start.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-START" "1" "September 2014" "" ""
+.TH "NPM\-START" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-start\fR \- Start a package
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm start [\-\- ]
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-stop.1 nodejs-0.11.15/deps/npm/man/man1/npm-stop.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-stop.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-stop.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-STOP" "1" "September 2014" "" ""
+.TH "NPM\-STOP" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-stop\fR \- Stop a package
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm stop [\-\- ]
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-submodule.1 nodejs-0.11.15/deps/npm/man/man1/npm-submodule.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-submodule.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-submodule.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-SUBMODULE" "1" "September 2014" "" ""
+.TH "NPM\-SUBMODULE" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-submodule\fR \- Add a package as a git submodule
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm submodule
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-tag.1 nodejs-0.11.15/deps/npm/man/man1/npm-tag.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-tag.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-tag.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-TAG" "1" "September 2014" "" ""
+.TH "NPM\-TAG" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-tag\fR \- Tag a published version
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm tag @ []
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
@@ -17,17 +17,17 @@
of using a specific version number:
.P
.RS 2
-.EX
+.nf
npm install @
-.EE
+.fi
.RE
.P
When installing dependencies, a preferred tagged version may be specified:
.P
.RS 2
-.EX
+.nf
npm install \-\-tag
-.EE
+.fi
.RE
.P
This also applies to \fBnpm dedupe\fR\|\.
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-test.1 nodejs-0.11.15/deps/npm/man/man1/npm-test.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-test.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-test.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,13 +1,13 @@
-.TH "NPM\-TEST" "1" "September 2014" "" ""
+.TH "NPM\-TEST" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-test\fR \- Test a package
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm test [\-\- ]
npm tst [\-\- ]
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-uninstall.1 nodejs-0.11.15/deps/npm/man/man1/npm-uninstall.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-uninstall.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-uninstall.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,13 +1,13 @@
-.TH "NPM\-RM" "1" "September 2014" "" ""
+.TH "NPM\-RM" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-rm\fR \- Remove a package
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm uninstall [@/] [\-\-save|\-\-save\-dev|\-\-save\-optional]
npm rm (with any of the previous argument usage)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
@@ -17,9 +17,9 @@
Example:
.P
.RS 2
-.EX
+.nf
npm uninstall sax
-.EE
+.fi
.RE
.P
In global mode (ie, with \fB\-g\fR or \fB\-\-global\fR appended to the command),
@@ -42,12 +42,12 @@
Examples:
.P
.RS 2
-.EX
+.nf
npm uninstall sax \-\-save
npm uninstall @myorg/privatepackage \-\-save
npm uninstall node\-tap \-\-save\-dev
npm uninstall dtrace\-provider \-\-save\-optional
-.EE
+.fi
.RE
.SH SEE ALSO
.RS 0
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-unpublish.1 nodejs-0.11.15/deps/npm/man/man1/npm-unpublish.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-unpublish.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-unpublish.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-UNPUBLISH" "1" "September 2014" "" ""
+.TH "NPM\-UNPUBLISH" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-unpublish\fR \- Remove a package from the registry
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm unpublish [@/][@]
-.EE
+.fi
.RE
.SH WARNING
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-update.1 nodejs-0.11.15/deps/npm/man/man1/npm-update.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-update.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-update.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-UPDATE" "1" "September 2014" "" ""
+.TH "NPM\-UPDATE" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-update\fR \- Update a package
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm update [\-g] [ [ \.\.\.]]
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-version.1 nodejs-0.11.15/deps/npm/man/man1/npm-version.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-version.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-version.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-VERSION" "1" "September 2014" "" ""
+.TH "NPM\-VERSION" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-version\fR \- Bump a package version
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm version [ | major | minor | patch | premajor | preminor | prepatch | prerelease]
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
@@ -27,9 +27,9 @@
resulting version number\. For example:
.P
.RS 2
-.EX
+.nf
npm version patch \-m "Upgrade to %s for reasons"
-.EE
+.fi
.RE
.P
If the \fBsign\-git\-tag\fR config is set, then the tag will be signed using
@@ -37,7 +37,7 @@
in your git config for this to work properly\. For example:
.P
.RS 2
-.EX
+.nf
$ npm config set sign\-git\-tag true
$ npm version patch
@@ -46,7 +46,7 @@
2048\-bit RSA key, ID 6C481CF6, created 2010\-08\-31
Enter passphrase:
-.EE
+.fi
.RE
.SH SEE ALSO
.RS 0
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-view.1 nodejs-0.11.15/deps/npm/man/man1/npm-view.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-view.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-view.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,13 +1,13 @@
-.TH "NPM\-VIEW" "1" "September 2014" "" ""
+.TH "NPM\-VIEW" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-view\fR \- View registry info
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm view [@/][@] [[\.]\.\.\.]
npm v [@/][@] [[\.]\.\.\.]
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
@@ -18,9 +18,9 @@
this:
.P
.RS 2
-.EX
+.nf
npm view connect
-.EE
+.fi
.RE
.P
The default version is "latest" if unspecified\.
@@ -30,9 +30,9 @@
0\.3\.5, you could do the following:
.P
.RS 2
-.EX
+.nf
npm view ronn@0\.3\.5 dependencies
-.EE
+.fi
.RE
.P
You can view child field by separating them with a period\.
@@ -40,9 +40,9 @@
do this:
.P
.RS 2
-.EX
+.nf
npm view npm repository\.url
-.EE
+.fi
.RE
.P
This makes it easy to view information about a dependency with a bit of
@@ -50,9 +50,9 @@
opts that ronn depends on, you can do this:
.P
.RS 2
-.EX
+.nf
npm view opts@$(npm view ronn dependencies\.opts)
-.EE
+.fi
.RE
.P
For fields that are arrays, requesting a non\-numeric field will return
@@ -60,9 +60,9 @@
the contributor names for the "express" project, you can do this:
.P
.RS 2
-.EX
+.nf
npm view express contributors\.email
-.EE
+.fi
.RE
.P
You may also use numeric indices in square braces to specifically select
@@ -70,9 +70,9 @@
contributor in the list, you can do this:
.P
.RS 2
-.EX
+.nf
npm view express contributors[0]\.email
-.EE
+.fi
.RE
.P
Multiple fields may be specified, and will be printed one after another\.
@@ -80,9 +80,9 @@
can do this:
.P
.RS 2
-.EX
+.nf
npm view express contributors\.name contributors\.email
-.EE
+.fi
.RE
.P
"Person" fields are shown as a string if they would be shown as an
@@ -90,9 +90,9 @@
the shortened string format\. (See npm help 5 \fBpackage\.json\fR for more on this\.)
.P
.RS 2
-.EX
+.nf
npm view npm contributors
-.EE
+.fi
.RE
.P
If a version range is provided, then data will be printed for every
@@ -100,9 +100,9 @@
was required by each matching version of yui3:
.P
.RS 2
-.EX
+.nf
npm view yui3@'>0\.5\.4' dependencies\.jsdom
-.EE
+.fi
.RE
.SH OUTPUT
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man1/npm-whoami.1 nodejs-0.11.15/deps/npm/man/man1/npm-whoami.1
--- nodejs-0.11.14/deps/npm/man/man1/npm-whoami.1 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man1/npm-whoami.1 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-WHOAMI" "1" "September 2014" "" ""
+.TH "NPM\-WHOAMI" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-whoami\fR \- Display npm username
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm whoami
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm.3 nodejs-0.11.15/deps/npm/man/man3/npm.3
--- nodejs-0.11.14/deps/npm/man/man3/npm.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,10 +1,10 @@
-.TH "NPM" "3" "September 2014" "" ""
+.TH "NPM" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm\fR \- node package manager
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
var npm = require("npm")
npm\.load([configObject, ]function (er, npm) {
// use the npm object, now that it's loaded\.
@@ -16,24 +16,23 @@
npm\.commands\.install(["package"], cb)
})
-.EE
+.fi
.RE
.SH VERSION
.P
-2.0.0
+2.1.6
.SH DESCRIPTION
.P
This is the API documentation for npm\.
To find documentation of the command line
client, see npm help \fBnpm\fR\|\.
.P
-Prior to using npm's commands, \fBnpm\.load()\fR must be called\.
-If you provide \fBconfigObject\fR as an object hash of top\-level
-configs, they override the values stored in the various config
-locations\. In the npm command line client, this set of configs
-is parsed from the command line options\. Additional configuration
-params are loaded from two configuration files\. See npm help \fBnpm\-config\fR,
-npm help 7 \fBnpm\-config\fR, and npm help 5 \fBnpmrc\fR for more information\.
+Prior to using npm's commands, \fBnpm\.load()\fR must be called\. If you provide
+\fBconfigObject\fR as an object map of top\-level configs, they override the values
+stored in the various config locations\. In the npm command line client, this
+set of configs is parsed from the command line options\. Additional
+configuration params are loaded from two configuration files\. See
+npm help \fBnpm\-config\fR, npm help 7 \fBnpm\-config\fR, and npm help 5 \fBnpmrc\fR for more information\.
.P
After that, each of the functions are accessible in the
commands object: \fBnpm\.commands\.\fR\|\. See npm help 7 \fBnpm\-index\fR for a list of
@@ -89,9 +88,9 @@
.RE
.SH MAGIC
.P
-For each of the methods in the \fBnpm\.commands\fR hash, a method is added to
-the npm object, which takes a set of positional string arguments rather
-than an array and a callback\.
+For each of the methods in the \fBnpm\.commands\fR object, a method is added to the
+npm object, which takes a set of positional string arguments rather than an
+array and a callback\.
.P
If the last argument is a callback, then it will use the supplied
callback\. However, if no callback is provided, then it will print out
@@ -100,11 +99,11 @@
For example, this would work in a node repl:
.P
.RS 2
-.EX
+.nf
> npm = require("npm")
> npm\.load() // wait a sec\.\.\.
> npm\.install("dnode", "express")
-.EE
+.fi
.RE
.P
Note that that \fIwon't\fR work in a node program, since the \fBinstall\fR
@@ -118,8 +117,8 @@
For example:
.P
.RS 2
-.EX
+.nf
var cmd = npm\.deref("unp") // cmd === "unpublish"
-.EE
+.fi
.RE
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-bin.3 nodejs-0.11.15/deps/npm/man/man3/npm-bin.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-bin.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-bin.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,17 +1,17 @@
-.TH "NPM\-BIN" "3" "September 2014" "" ""
+.TH "NPM\-BIN" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-bin\fR \- Display npm bin folder
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.bin(args, cb)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
Print the folder where npm will install executables\.
.P
This function should not be used programmatically\. Instead, just refer
-to the \fBnpm\.bin\fR member\.
+to the \fBnpm\.bin\fR property\.
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-bugs.3 nodejs-0.11.15/deps/npm/man/man3/npm-bugs.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-bugs.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-bugs.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-BUGS" "3" "September 2014" "" ""
+.TH "NPM\-BUGS" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-bugs\fR \- Bugs for a package in a web browser maybe
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.bugs(package, callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-cache.3 nodejs-0.11.15/deps/npm/man/man3/npm-cache.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-cache.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-cache.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,17 +1,17 @@
-.TH "NPM\-CACHE" "3" "September 2014" "" ""
+.TH "NPM\-CACHE" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-cache\fR \- manage the npm cache programmatically
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.cache([args], callback)
// helpers
npm\.commands\.cache\.clean([args], callback)
npm\.commands\.cache\.add([args], callback)
npm\.commands\.cache\.read(name, version, forceBypass, callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-commands.3 nodejs-0.11.15/deps/npm/man/man3/npm-commands.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-commands.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-commands.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-COMMANDS" "3" "September 2014" "" ""
+.TH "NPM\-COMMANDS" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-commands\fR \- npm commands
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands[](args, callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-config.3 nodejs-0.11.15/deps/npm/man/man3/npm-config.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-config.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-config.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,14 +1,14 @@
-.TH "NPM\-CONFIG" "3" "September 2014" "" ""
+.TH "NPM\-CONFIG" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-config\fR \- Manage the npm configuration files
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.config(args, callback)
var val = npm\.config\.get(key)
npm\.config\.set(key, val)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-deprecate.3 nodejs-0.11.15/deps/npm/man/man3/npm-deprecate.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-deprecate.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-deprecate.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-DEPRECATE" "3" "September 2014" "" ""
+.TH "NPM\-DEPRECATE" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-deprecate\fR \- Deprecate a version of a package
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.deprecate(args, callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-docs.3 nodejs-0.11.15/deps/npm/man/man3/npm-docs.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-docs.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-docs.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-DOCS" "3" "September 2014" "" ""
+.TH "NPM\-DOCS" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-docs\fR \- Docs for a package in a web browser maybe
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.docs(package, callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-edit.3 nodejs-0.11.15/deps/npm/man/man3/npm-edit.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-edit.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-edit.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-EDIT" "3" "September 2014" "" ""
+.TH "NPM\-EDIT" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-edit\fR \- Edit an installed package
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.edit(package, callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-explore.3 nodejs-0.11.15/deps/npm/man/man3/npm-explore.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-explore.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-explore.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-EXPLORE" "3" "September 2014" "" ""
+.TH "NPM\-EXPLORE" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-explore\fR \- Browse an installed package
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.explore(args, callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-help-search.3 nodejs-0.11.15/deps/npm/man/man3/npm-help-search.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-help-search.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-help-search.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-HELP\-SEARCH" "3" "September 2014" "" ""
+.TH "NPM\-HELP\-SEARCH" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-help-search\fR \- Search the help pages
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.helpSearch(args, [silent,] callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
@@ -37,5 +37,5 @@
.RE
.P
-The silent parameter is not neccessary not used, but it may in the future\.
+The silent parameter is not necessary not used, but it may in the future\.
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-init.3 nodejs-0.11.15/deps/npm/man/man3/npm-init.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-init.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-init.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM" "" "September 2014" "" ""
+.TH "NPM" "" "October 2014" "" ""
.SH "NAME"
\fBnpm\fR
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.init(args, callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-install.3 nodejs-0.11.15/deps/npm/man/man3/npm-install.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-install.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-install.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-INSTALL" "3" "September 2014" "" ""
+.TH "NPM\-INSTALL" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-install\fR \- install a package programmatically
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.install([where,] packages, callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-link.3 nodejs-0.11.15/deps/npm/man/man3/npm-link.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-link.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-link.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,13 +1,13 @@
-.TH "NPM\-LINK" "3" "September 2014" "" ""
+.TH "NPM\-LINK" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-link\fR \- Symlink a package folder
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.link(callback)
npm\.commands\.link(packages, callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
@@ -29,11 +29,11 @@
For example:
.P
.RS 2
-.EX
+.nf
npm\.commands\.link(cb) # creates global link from the cwd
# (say redis package)
npm\.commands\.link('redis', cb) # link\-install the package
-.EE
+.fi
.RE
.P
Now, any changes to the redis package will be reflected in
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-load.3 nodejs-0.11.15/deps/npm/man/man3/npm-load.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-load.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-load.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,21 +1,21 @@
-.TH "NPM\-LOAD" "3" "September 2014" "" ""
+.TH "NPM\-LOAD" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-load\fR \- Load config settings
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.load(conf, cb)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
npm\.load() must be called before any other function call\. Both parameters are
optional, but the second is recommended\.
.P
-The first parameter is an object hash of command\-line config params, and the
-second parameter is a callback that will be called when npm is loaded and
-ready to serve\.
+The first parameter is an object containing command\-line config params, and the
+second parameter is a callback that will be called when npm is loaded and ready
+to serve\.
.P
The first parameter should follow a similar structure as the package\.json
config object\.
@@ -23,11 +23,11 @@
For example, to emulate the \-\-dev flag, pass an object that looks like this:
.P
.RS 2
-.EX
+.nf
{
"dev": true
}
-.EE
+.fi
.RE
.P
For a list of all the available command\-line configs, see \fBnpm help config\fR
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-ls.3 nodejs-0.11.15/deps/npm/man/man3/npm-ls.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-ls.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-ls.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-LS" "3" "September 2014" "" ""
+.TH "NPM\-LS" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-ls\fR \- List installed packages
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.ls(args, [silent,] callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-outdated.3 nodejs-0.11.15/deps/npm/man/man3/npm-outdated.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-outdated.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-outdated.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-OUTDATED" "3" "September 2014" "" ""
+.TH "NPM\-OUTDATED" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-outdated\fR \- Check for outdated packages
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.outdated([packages,] callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-owner.3 nodejs-0.11.15/deps/npm/man/man3/npm-owner.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-owner.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-owner.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-OWNER" "3" "September 2014" "" ""
+.TH "NPM\-OWNER" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-owner\fR \- Manage package owners
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.owner(args, callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-pack.3 nodejs-0.11.15/deps/npm/man/man3/npm-pack.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-pack.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-pack.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-PACK" "3" "September 2014" "" ""
+.TH "NPM\-PACK" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-pack\fR \- Create a tarball from a package
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.pack([packages,] callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-prefix.3 nodejs-0.11.15/deps/npm/man/man3/npm-prefix.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-prefix.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-prefix.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-PREFIX" "3" "September 2014" "" ""
+.TH "NPM\-PREFIX" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-prefix\fR \- Display prefix
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.prefix(args, callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-prune.3 nodejs-0.11.15/deps/npm/man/man3/npm-prune.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-prune.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-prune.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-PRUNE" "3" "September 2014" "" ""
+.TH "NPM\-PRUNE" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-prune\fR \- Remove extraneous packages
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.prune([packages,] callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-publish.3 nodejs-0.11.15/deps/npm/man/man3/npm-publish.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-publish.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-publish.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-PUBLISH" "3" "September 2014" "" ""
+.TH "NPM\-PUBLISH" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-publish\fR \- Publish a package
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.publish([packages,] callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-rebuild.3 nodejs-0.11.15/deps/npm/man/man3/npm-rebuild.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-rebuild.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-rebuild.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-REBUILD" "3" "September 2014" "" ""
+.TH "NPM\-REBUILD" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-rebuild\fR \- Rebuild a package
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.rebuild([packages,] callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-repo.3 nodejs-0.11.15/deps/npm/man/man3/npm-repo.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-repo.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-repo.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-REPO" "3" "September 2014" "" ""
+.TH "NPM\-REPO" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-repo\fR \- Open package repository page in the browser
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.repo(package, callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-restart.3 nodejs-0.11.15/deps/npm/man/man3/npm-restart.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-restart.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-restart.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-RESTART" "3" "September 2014" "" ""
+.TH "NPM\-RESTART" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-restart\fR \- Start a package
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.restart(packages, callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-root.3 nodejs-0.11.15/deps/npm/man/man3/npm-root.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-root.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-root.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-ROOT" "3" "September 2014" "" ""
+.TH "NPM\-ROOT" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-root\fR \- Display npm root
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.root(args, callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-run-script.3 nodejs-0.11.15/deps/npm/man/man3/npm-run-script.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-run-script.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-run-script.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-RUN\-SCRIPT" "3" "September 2014" "" ""
+.TH "NPM\-RUN\-SCRIPT" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-run-script\fR \- Run arbitrary package scripts
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.run\-script(args, callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-search.3 nodejs-0.11.15/deps/npm/man/man3/npm-search.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-search.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-search.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-SEARCH" "3" "September 2014" "" ""
+.TH "NPM\-SEARCH" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-search\fR \- Search for packages
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.search(searchTerms, [silent,] [staleness,] callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-shrinkwrap.3 nodejs-0.11.15/deps/npm/man/man3/npm-shrinkwrap.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-shrinkwrap.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-shrinkwrap.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-SHRINKWRAP" "3" "September 2014" "" ""
+.TH "NPM\-SHRINKWRAP" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-shrinkwrap\fR \- programmatically generate package shrinkwrap file
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.shrinkwrap(args, [silent,] callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-start.3 nodejs-0.11.15/deps/npm/man/man3/npm-start.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-start.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-start.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-START" "3" "September 2014" "" ""
+.TH "NPM\-START" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-start\fR \- Start a package
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.start(packages, callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-stop.3 nodejs-0.11.15/deps/npm/man/man3/npm-stop.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-stop.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-stop.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-STOP" "3" "September 2014" "" ""
+.TH "NPM\-STOP" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-stop\fR \- Stop a package
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.stop(packages, callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-submodule.3 nodejs-0.11.15/deps/npm/man/man3/npm-submodule.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-submodule.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-submodule.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-SUBMODULE" "3" "September 2014" "" ""
+.TH "NPM\-SUBMODULE" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-submodule\fR \- Add a package as a git submodule
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.submodule(packages, callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-tag.3 nodejs-0.11.15/deps/npm/man/man3/npm-tag.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-tag.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-tag.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-TAG" "3" "September 2014" "" ""
+.TH "NPM\-TAG" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-tag\fR \- Tag a published version
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.tag(package@version, tag, callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-test.3 nodejs-0.11.15/deps/npm/man/man3/npm-test.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-test.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-test.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-TEST" "3" "September 2014" "" ""
+.TH "NPM\-TEST" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-test\fR \- Test a package
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.test(packages, callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-uninstall.3 nodejs-0.11.15/deps/npm/man/man3/npm-uninstall.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-uninstall.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-uninstall.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-UNINSTALL" "3" "September 2014" "" ""
+.TH "NPM\-UNINSTALL" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-uninstall\fR \- uninstall a package programmatically
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.uninstall(packages, callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-unpublish.3 nodejs-0.11.15/deps/npm/man/man3/npm-unpublish.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-unpublish.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-unpublish.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-UNPUBLISH" "3" "September 2014" "" ""
+.TH "NPM\-UNPUBLISH" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-unpublish\fR \- Remove a package from the registry
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.unpublish(package, callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-update.3 nodejs-0.11.15/deps/npm/man/man3/npm-update.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-update.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-update.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,14 +1,14 @@
-.TH "NPM\-UPDATE" "3" "September 2014" "" ""
+.TH "NPM\-UPDATE" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-update\fR \- Update a package
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.update(packages, callback)
-.EE
+.fi
.RE
-.TH "DESCRIPTION" "" "September 2014" "" ""
+.TH "DESCRIPTION" "" "October 2014" "" ""
.SH "NAME"
\fBDESCRIPTION\fR
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-version.3 nodejs-0.11.15/deps/npm/man/man3/npm-version.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-version.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-version.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-VERSION" "3" "September 2014" "" ""
+.TH "NPM\-VERSION" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-version\fR \- Bump a package version
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.version(newversion, callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-view.3 nodejs-0.11.15/deps/npm/man/man3/npm-view.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-view.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-view.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-VIEW" "3" "September 2014" "" ""
+.TH "NPM\-VIEW" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-view\fR \- View registry info
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.view(args, [silent,] callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
@@ -25,9 +25,9 @@
you can do this:
.P
.RS 2
-.EX
+.nf
npm\.commands\.view(["connect"], callback)
-.EE
+.fi
.RE
.P
If no version is specified, "latest" is assumed\.
@@ -37,9 +37,9 @@
0\.3\.5, you could do the following:
.P
.RS 2
-.EX
+.nf
npm\.commands\.view(["ronn@0\.3\.5", "dependencies"], callback)
-.EE
+.fi
.RE
.P
You can view child field by separating them with a period\.
@@ -47,9 +47,9 @@
do this:
.P
.RS 2
-.EX
+.nf
npm\.commands\.view(["npm", "repository\.url"], callback)
-.EE
+.fi
.RE
.P
For fields that are arrays, requesting a non\-numeric field will return
@@ -57,9 +57,9 @@
the contributor names for the "express" project, you can do this:
.P
.RS 2
-.EX
+.nf
npm\.commands\.view(["express", "contributors\.email"], callback)
-.EE
+.fi
.RE
.P
You may also use numeric indices in square braces to specifically select
@@ -67,9 +67,9 @@
contributor in the list, you can do this:
.P
.RS 2
-.EX
+.nf
npm\.commands\.view(["express", "contributors[0]\.email"], callback)
-.EE
+.fi
.RE
.P
Multiple fields may be specified, and will be printed one after another\.
@@ -77,9 +77,9 @@
can do this:
.P
.RS 2
-.EX
+.nf
npm\.commands\.view(["express", "contributors\.name", "contributors\.email"], callback)
-.EE
+.fi
.RE
.P
"Person" fields are shown as a string if they would be shown as an
@@ -87,9 +87,9 @@
the shortened string format\. (See \fBnpm help json\fR for more on this\.)
.P
.RS 2
-.EX
+.nf
npm\.commands\.view(["npm", "contributors"], callback)
-.EE
+.fi
.RE
.P
If a version range is provided, then data will be printed for every
@@ -97,9 +97,9 @@
was required by each matching version of yui3:
.P
.RS 2
-.EX
+.nf
npm\.commands\.view(["yui3@'>0\.5\.4'", "dependencies\.jsdom"], callback)
-.EE
+.fi
.RE
.SH OUTPUT
.P
@@ -119,12 +119,12 @@
The data returned will be an object in this formation:
.P
.RS 2
-.EX
+.nf
{ :
{ :
, \.\.\. }
, \.\.\. }
-.EE
+.fi
.RE
.P
corresponding to the list of fields selected\.
diff -Nru nodejs-0.11.14/deps/npm/man/man3/npm-whoami.3 nodejs-0.11.15/deps/npm/man/man3/npm-whoami.3
--- nodejs-0.11.14/deps/npm/man/man3/npm-whoami.3 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man3/npm-whoami.3 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-.TH "NPM\-WHOAMI" "3" "September 2014" "" ""
+.TH "NPM\-WHOAMI" "3" "October 2014" "" ""
.SH "NAME"
\fBnpm-whoami\fR \- Display npm username
.SH SYNOPSIS
.P
.RS 2
-.EX
+.nf
npm\.commands\.whoami(args, callback)
-.EE
+.fi
.RE
.SH DESCRIPTION
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man5/npm-folders.5 nodejs-0.11.15/deps/npm/man/man5/npm-folders.5
--- nodejs-0.11.14/deps/npm/man/man5/npm-folders.5 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man5/npm-folders.5 2015-01-20 21:22:17.000000000 +0000
@@ -1,4 +1,4 @@
-.TH "NPM\-FOLDERS" "5" "September 2014" "" ""
+.TH "NPM\-FOLDERS" "5" "October 2014" "" ""
.SH "NAME"
\fBnpm-folders\fR \- Folder Structures Used by npm
.SH DESCRIPTION
@@ -142,7 +142,7 @@
Consider this dependency graph:
.P
.RS 2
-.EX
+.nf
foo
+\-\- blerg@1\.2\.5
+\-\- bar@1\.2\.3
@@ -154,13 +154,13 @@
`\-\- baz@1\.2\.3
`\-\- quux@3\.x
`\-\- bar
-.EE
+.fi
.RE
.P
In this case, we might expect a folder structure like this:
.P
.RS 2
-.EX
+.nf
foo
+\-\- node_modules
+\-\- blerg (1\.2\.5) <\-\-\-[A]
@@ -173,7 +173,7 @@
`\-\- baz (1\.2\.3) <\-\-\-[D]
`\-\- node_modules
`\-\- quux (3\.2\.0) <\-\-\-[E]
-.EE
+.fi
.RE
.P
Since foo depends directly on \fBbar@1\.2\.3\fR and \fBbaz@1\.2\.3\fR, those are
diff -Nru nodejs-0.11.14/deps/npm/man/man5/npm-global.5 nodejs-0.11.15/deps/npm/man/man5/npm-global.5
--- nodejs-0.11.14/deps/npm/man/man5/npm-global.5 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man5/npm-global.5 2015-01-20 21:22:17.000000000 +0000
@@ -1,4 +1,4 @@
-.TH "NPM\-FOLDERS" "5" "September 2014" "" ""
+.TH "NPM\-FOLDERS" "5" "October 2014" "" ""
.SH "NAME"
\fBnpm-folders\fR \- Folder Structures Used by npm
.SH DESCRIPTION
@@ -142,7 +142,7 @@
Consider this dependency graph:
.P
.RS 2
-.EX
+.nf
foo
+\-\- blerg@1\.2\.5
+\-\- bar@1\.2\.3
@@ -154,13 +154,13 @@
`\-\- baz@1\.2\.3
`\-\- quux@3\.x
`\-\- bar
-.EE
+.fi
.RE
.P
In this case, we might expect a folder structure like this:
.P
.RS 2
-.EX
+.nf
foo
+\-\- node_modules
+\-\- blerg (1\.2\.5) <\-\-\-[A]
@@ -173,7 +173,7 @@
`\-\- baz (1\.2\.3) <\-\-\-[D]
`\-\- node_modules
`\-\- quux (3\.2\.0) <\-\-\-[E]
-.EE
+.fi
.RE
.P
Since foo depends directly on \fBbar@1\.2\.3\fR and \fBbaz@1\.2\.3\fR, those are
diff -Nru nodejs-0.11.14/deps/npm/man/man5/npm-json.5 nodejs-0.11.15/deps/npm/man/man5/npm-json.5
--- nodejs-0.11.14/deps/npm/man/man5/npm-json.5 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man5/npm-json.5 2015-01-20 21:22:17.000000000 +0000
@@ -1,4 +1,4 @@
-.TH "PACKAGE\.JSON" "5" "September 2014" "" ""
+.TH "PACKAGE\.JSON" "5" "October 2014" "" ""
.SH "NAME"
\fBpackage.json\fR \- Specifics of npm's package\.json handling
.SH DESCRIPTION
@@ -76,11 +76,11 @@
It should look like this:
.P
.RS 2
-.EX
+.nf
{ "url" : "http://github\.com/owner/project/issues"
, "email" : "project@hostname\.com"
}
-.EE
+.fi
.RE
.P
You can specify either one or both values\. If you want to provide only a url,
@@ -97,9 +97,9 @@
like this:
.P
.RS 2
-.EX
+.nf
{ "license" : "BSD\-3\-Clause" }
-.EE
+.fi
.RE
.P
You can check the full list of SPDX license IDs \fIhttps://spdx\.org/licenses/\fR\|\.
@@ -114,20 +114,20 @@
is an object with a "name" field and optionally "url" and "email", like this:
.P
.RS 2
-.EX
+.nf
{ "name" : "Barney Rubble"
, "email" : "b@rubble\.com"
, "url" : "http://barnyrubble\.tumblr\.com/"
}
-.EE
+.fi
.RE
.P
Or you can shorten that all into a single string, and npm will parse it for you:
.P
.RS 2
-.EX
+.nf
"Barney Rubble (http://barnyrubble\.tumblr\.com/)
-.EE
+.fi
.RE
.P
Both email and url are optional either way\.
@@ -167,9 +167,9 @@
For example, npm has this:
.P
.RS 2
-.EX
+.nf
{ "bin" : { "npm" : "\./cli\.js" } }
-.EE
+.fi
.RE
.P
So, when you install npm, it'll create a symlink from the \fBcli\.js\fR script to
@@ -179,21 +179,21 @@
of the package, then you can just supply it as a string\. For example:
.P
.RS 2
-.EX
+.nf
{ "name": "my\-program"
, "version": "1\.2\.5"
, "bin": "\./path/to/program" }
-.EE
+.fi
.RE
.P
would be the same as this:
.P
.RS 2
-.EX
+.nf
{ "name": "my\-program"
, "version": "1\.2\.5"
, "bin" : { "my\-program" : "\./path/to/program" } }
-.EE
+.fi
.RE
.SH man
.P
@@ -204,14 +204,14 @@
result from \fBman \fR, regardless of its actual filename\. For example:
.P
.RS 2
-.EX
+.nf
{ "name" : "foo"
, "version" : "1\.2\.3"
, "description" : "A packaged foo fooer for fooing foos"
, "main" : "foo\.js"
, "man" : "\./man/doc\.1"
}
-.EE
+.fi
.RE
.P
would link the \fB\|\./man/doc\.1\fR file in such that it is the target for \fBman foo\fR
@@ -220,14 +220,14 @@
So, this:
.P
.RS 2
-.EX
+.nf
{ "name" : "foo"
, "version" : "1\.2\.3"
, "description" : "A packaged foo fooer for fooing foos"
, "main" : "foo\.js"
, "man" : [ "\./man/foo\.1", "\./man/bar\.1" ]
}
-.EE
+.fi
.RE
.P
will create files to do \fBman foo\fR and \fBman foo\-bar\fR\|\.
@@ -236,14 +236,14 @@
compressed\. The number dictates which man section the file is installed into\.
.P
.RS 2
-.EX
+.nf
{ "name" : "foo"
, "version" : "1\.2\.3"
, "description" : "A packaged foo fooer for fooing foos"
, "main" : "foo\.js"
, "man" : [ "\./man/foo\.1", "\./man/foo\.2" ]
}
-.EE
+.fi
.RE
.P
will create entries for \fBman foo\fR and \fBman 2 foo\fR
@@ -251,7 +251,7 @@
.P
The CommonJS Packages \fIhttp://wiki\.commonjs\.org/wiki/Packages/1\.0\fR spec details a
few ways that you can indicate the structure of your package using a \fBdirectories\fR
-hash\. If you look at npm's package\.json \fIhttp://registry\.npmjs\.org/npm/latest\fR,
+object\. If you look at npm's package\.json \fIhttp://registry\.npmjs\.org/npm/latest\fR,
you'll see that it has directories for doc, lib, and man\.
.P
In the future, this information may be used in other creative ways\.
@@ -261,10 +261,10 @@
with the lib folder in any way, but it's useful meta info\.
.SS directories\.bin
.P
-If you specify a "bin" directory, then all the files in that folder will
-be used as the "bin" hash\.
+If you specify a \fBbin\fR directory, then all the files in that folder will
+be added as children of the \fBbin\fR path\.
.P
-If you have a "bin" hash already, then this has no effect\.
+If you have a \fBbin\fR path already, then this has no effect\.
.SS directories\.man
.P
A folder that is full of man pages\. Sugar to generate a "man" array by
@@ -285,7 +285,7 @@
Do it like this:
.P
.RS 2
-.EX
+.nf
"repository" :
{ "type" : "git"
, "url" : "http://github\.com/npm/npm\.git"
@@ -295,7 +295,7 @@
{ "type" : "svn"
, "url" : "http://v8\.googlecode\.com/svn/trunk/"
}
-.EE
+.fi
.RE
.P
The URL should be a publicly available (perhaps read\-only) url that can be handed
@@ -303,22 +303,22 @@
html project page that you put in your browser\. It's for computers\.
.SH scripts
.P
-The "scripts" member is an object hash of script commands that are run
+The "scripts" property is a dictionary containing script commands that are run
at various times in the lifecycle of your package\. The key is the lifecycle
event, and the value is the command to run at that point\.
.P
See npm help 7 \fBnpm\-scripts\fR to find out more about writing package scripts\.
.SH config
.P
-A "config" hash can be used to set configuration
-parameters used in package scripts that persist across upgrades\. For
-instance, if a package had the following:
+A "config" object can be used to set configuration parameters used in package
+scripts that persist across upgrades\. For instance, if a package had the
+following:
.P
.RS 2
-.EX
+.nf
{ "name" : "foo"
, "config" : { "port" : "8080" } }
-.EE
+.fi
.RE
.P
and then had a "start" command that then referenced the
@@ -329,13 +329,13 @@
configs\.
.SH dependencies
.P
-Dependencies are specified with a simple hash of package name to
+Dependencies are specified in a simple object that maps a package name to a
version range\. The version range is a string which has one or more
-space\-separated descriptors\. Dependencies can also be identified with
-a tarball or git URL\.
+space\-separated descriptors\. Dependencies can also be identified with a
+tarball or git URL\.
.P
\fBPlease do not put test harnesses or transpilers in your
-\fBdependencies\fR hash\.\fR See \fBdevDependencies\fR, below\.
+\fBdependencies\fR object\.\fR See \fBdevDependencies\fR, below\.
.P
See npm help 7 semver for more details about specifying version ranges\.
.RS 0
@@ -379,7 +379,7 @@
For example, these are all valid:
.P
.RS 2
-.EX
+.nf
{ "dependencies" :
{ "foo" : "1\.0\.0 \- 2\.9999\.9999"
, "bar" : ">=1\.0\.2 <2\.1\.2"
@@ -392,10 +392,10 @@
, "two" : "2\.x"
, "thr" : "3\.3\.x"
, "lat" : "latest"
- , "dyl" : "~/projects/dyl"
+ , "dyl" : "file:\.\./dyl"
}
}
-.EE
+.fi
.RE
.SS URLs as Dependencies
.P
@@ -408,13 +408,13 @@
Git urls can be of the form:
.P
.RS 2
-.EX
+.nf
git://github\.com/user/project\.git#commit\-ish
git+ssh://user@hostname:project\.git#commit\-ish
git+ssh://user@hostname/project\.git#commit\-ish
git+http://user@hostname/project/blah\.git#commit\-ish
git+https://user@hostname/project/blah\.git#commit\-ish
-.EE
+.fi
.RE
.P
The \fBcommit\-ish\fR can be any tag, sha, or branch which can be supplied as
@@ -424,7 +424,7 @@
As of version 1\.1\.65, you can refer to GitHub urls as just "foo": "user/foo\-project"\. For example:
.P
.RS 2
-.EX
+.nf
{
"name": "foo",
"version": "0\.0\.0",
@@ -432,20 +432,35 @@
"express": "visionmedia/express"
}
}
-.EE
+.fi
.RE
.SH Local Paths
.P
-As of version 2\.0\.0 you can provide a path to a local directory that
-contains a package\. Local paths can be in the form:
+As of version 2\.0\.0 you can provide a path to a local directory that contains a
+package\. Local paths can be saved using \fBnpm install \-\-save\fR, using any of
+these forms:
.P
.RS 2
-.EX
+.nf
\|\.\./foo/bar
~/foo/bar
\|\./foo/bar
/foo/bar
-.EE
+.fi
+.RE
+.P
+in which case they will be normalized to a relative path and added to your
+\fBpackage\.json\fR\|\. For example:
+.P
+.RS 2
+.nf
+{
+ "name": "baz",
+ "dependencies": {
+ "bar": "file:\.\./foo/bar"
+ }
+}
+.fi
.RE
.P
This feature is helpful for local offline development and creating
@@ -458,8 +473,8 @@
program, then they probably don't want or need to download and build
the external test or documentation framework that you use\.
.P
-In this case, it's best to list these additional items in a
-\fBdevDependencies\fR hash\.
+In this case, it's best to map these additional items in a \fBdevDependencies\fR
+object\.
.P
These things will be installed when doing \fBnpm link\fR or \fBnpm install\fR
from the root of a package, and can be managed like any other npm
@@ -472,7 +487,7 @@
For example:
.P
.RS 2
-.EX
+.nf
{ "name": "ethopia\-waza",
"description": "a delightfully fruity coffee varietal",
"version": "1\.2\.3",
@@ -484,7 +499,7 @@
},
"main": "lib/waza\.js"
}
-.EE
+.fi
.RE
.P
The \fBprepublish\fR script will be run before publishing, so that users
@@ -501,7 +516,7 @@
For example:
.P
.RS 2
-.EX
+.nf
{
"name": "tea\-latte",
"version": "1\.3\.5"
@@ -509,7 +524,7 @@
"tea": "2\.x"
}
}
-.EE
+.fi
.RE
.P
This ensures your package \fBtea\-latte\fR can be installed \fIalong\fR with the second
@@ -518,10 +533,10 @@
dependency graph:
.P
.RS 2
-.EX
+.nf
├── tea\-latte@1\.3\.5
└── tea@2\.2\.0
-.EE
+.fi
.RE
.P
Trying to install another plugin with a conflicting requirement will cause an
@@ -539,17 +554,17 @@
If this is spelled \fB"bundleDependencies"\fR, then that is also honorable\.
.SH optionalDependencies
.P
-If a dependency can be used, but you would like npm to proceed if it
-cannot be found or fails to install, then you may put it in the
-\fBoptionalDependencies\fR hash\. This is a map of package name to version
-or url, just like the \fBdependencies\fR hash\. The difference is that
-failure is tolerated\.
+If a dependency can be used, but you would like npm to proceed if it cannot be
+found or fails to install, then you may put it in the \fBoptionalDependencies\fR
+object\. This is a map of package name to version or url, just like the
+\fBdependencies\fR object\. The difference is that build failures do not cause
+installation to fail\.
.P
It is still your program's responsibility to handle the lack of the
dependency\. For example, something like this:
.P
.RS 2
-.EX
+.nf
try {
var foo = require('foo')
var fooVersion = require('foo/package\.json')\.version
@@ -565,7 +580,7 @@
if (foo) {
foo\.doFooThings()
}
-.EE
+.fi
.RE
.P
Entries in \fBoptionalDependencies\fR will override entries of the same name in
@@ -575,9 +590,9 @@
You can specify the version of node that your stuff works on:
.P
.RS 2
-.EX
+.nf
{ "engines" : { "node" : ">=0\.10\.3 <0\.12" } }
-.EE
+.fi
.RE
.P
And, like with dependencies, if you don't specify the version (or if you
@@ -591,9 +606,9 @@
are capable of properly installing your program\. For example:
.P
.RS 2
-.EX
+.nf
{ "engines" : { "npm" : "~1\.0\.20" } }
-.EE
+.fi
.RE
.P
Note that, unless the user has set the \fBengine\-strict\fR config flag, this
@@ -601,12 +616,12 @@
.SH engineStrict
.P
If you are sure that your module will \fIdefinitely not\fR run properly on
-versions of Node/npm other than those specified in the \fBengines\fR hash,
+versions of Node/npm other than those specified in the \fBengines\fR object,
then you can set \fB"engineStrict": true\fR in your package\.json file\.
This will override the user's \fBengine\-strict\fR config setting\.
.P
Please do not do this unless you are really very very sure\. If your
-engines hash is something overly restrictive, you can quite easily and
+engines object is something overly restrictive, you can quite easily and
inadvertently lock yourself into obscurity and prevent your users from
updating to new versions of Node\. Consider this choice carefully\. If
people abuse it, it will be removed in a future version of npm\.
@@ -616,18 +631,18 @@
module will run on:
.P
.RS 2
-.EX
+.nf
"os" : [ "darwin", "linux" ]
-.EE
+.fi
.RE
.P
You can also blacklist instead of whitelist operating systems,
just prepend the blacklisted os with a '!':
.P
.RS 2
-.EX
+.nf
"os" : [ "!win32" ]
-.EE
+.fi
.RE
.P
The host operating system is determined by \fBprocess\.platform\fR
@@ -640,17 +655,17 @@
you can specify which ones\.
.P
.RS 2
-.EX
+.nf
"cpu" : [ "x64", "ia32" ]
-.EE
+.fi
.RE
.P
Like the \fBos\fR option, you can also blacklist architectures:
.P
.RS 2
-.EX
+.nf
"cpu" : [ "!arm", "!mips" ]
-.EE
+.fi
.RE
.P
The host architecture is determined by \fBprocess\.arch\fR
@@ -667,11 +682,11 @@
If you set \fB"private": true\fR in your package\.json, then npm will refuse
to publish it\.
.P
-This is a way to prevent accidental publication of private repositories\.
-If you would like to ensure that a given package is only ever published
-to a specific registry (for example, an internal registry),
-then use the \fBpublishConfig\fR hash described below
-to override the \fBregistry\fR config param at publish\-time\.
+This is a way to prevent accidental publication of private repositories\. If
+you would like to ensure that a given package is only ever published to a
+specific registry (for example, an internal registry), then use the
+\fBpublishConfig\fR dictionary described below to override the \fBregistry\fR config
+param at publish\-time\.
.SH publishConfig
.P
This is a set of config values that will be used at publish\-time\. It's
diff -Nru nodejs-0.11.14/deps/npm/man/man5/npmrc.5 nodejs-0.11.15/deps/npm/man/man5/npmrc.5
--- nodejs-0.11.14/deps/npm/man/man5/npmrc.5 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man5/npmrc.5 2015-01-20 21:22:17.000000000 +0000
@@ -1,4 +1,4 @@
-.TH "NPMRC" "5" "September 2014" "" ""
+.TH "NPMRC" "5" "October 2014" "" ""
.SH "NAME"
\fBnpmrc\fR \- The npm config files
.SH DESCRIPTION
@@ -30,9 +30,9 @@
\fB${VARIABLE_NAME}\fR\|\. For example:
.P
.RS 2
-.EX
+.nf
prefix = ${HOME}/\.npm\-packages
-.EE
+.fi
.RE
.P
Each of these files is loaded, and config options are resolved in
diff -Nru nodejs-0.11.14/deps/npm/man/man5/package.json.5 nodejs-0.11.15/deps/npm/man/man5/package.json.5
--- nodejs-0.11.14/deps/npm/man/man5/package.json.5 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man5/package.json.5 2015-01-20 21:22:17.000000000 +0000
@@ -1,4 +1,4 @@
-.TH "PACKAGE\.JSON" "5" "September 2014" "" ""
+.TH "PACKAGE\.JSON" "5" "October 2014" "" ""
.SH "NAME"
\fBpackage.json\fR \- Specifics of npm's package\.json handling
.SH DESCRIPTION
@@ -76,11 +76,11 @@
It should look like this:
.P
.RS 2
-.EX
+.nf
{ "url" : "http://github\.com/owner/project/issues"
, "email" : "project@hostname\.com"
}
-.EE
+.fi
.RE
.P
You can specify either one or both values\. If you want to provide only a url,
@@ -97,9 +97,9 @@
like this:
.P
.RS 2
-.EX
+.nf
{ "license" : "BSD\-3\-Clause" }
-.EE
+.fi
.RE
.P
You can check the full list of SPDX license IDs \fIhttps://spdx\.org/licenses/\fR\|\.
@@ -114,20 +114,20 @@
is an object with a "name" field and optionally "url" and "email", like this:
.P
.RS 2
-.EX
+.nf
{ "name" : "Barney Rubble"
, "email" : "b@rubble\.com"
, "url" : "http://barnyrubble\.tumblr\.com/"
}
-.EE
+.fi
.RE
.P
Or you can shorten that all into a single string, and npm will parse it for you:
.P
.RS 2
-.EX
+.nf
"Barney Rubble (http://barnyrubble\.tumblr\.com/)
-.EE
+.fi
.RE
.P
Both email and url are optional either way\.
@@ -167,9 +167,9 @@
For example, npm has this:
.P
.RS 2
-.EX
+.nf
{ "bin" : { "npm" : "\./cli\.js" } }
-.EE
+.fi
.RE
.P
So, when you install npm, it'll create a symlink from the \fBcli\.js\fR script to
@@ -179,21 +179,21 @@
of the package, then you can just supply it as a string\. For example:
.P
.RS 2
-.EX
+.nf
{ "name": "my\-program"
, "version": "1\.2\.5"
, "bin": "\./path/to/program" }
-.EE
+.fi
.RE
.P
would be the same as this:
.P
.RS 2
-.EX
+.nf
{ "name": "my\-program"
, "version": "1\.2\.5"
, "bin" : { "my\-program" : "\./path/to/program" } }
-.EE
+.fi
.RE
.SH man
.P
@@ -204,14 +204,14 @@
result from \fBman \fR, regardless of its actual filename\. For example:
.P
.RS 2
-.EX
+.nf
{ "name" : "foo"
, "version" : "1\.2\.3"
, "description" : "A packaged foo fooer for fooing foos"
, "main" : "foo\.js"
, "man" : "\./man/doc\.1"
}
-.EE
+.fi
.RE
.P
would link the \fB\|\./man/doc\.1\fR file in such that it is the target for \fBman foo\fR
@@ -220,14 +220,14 @@
So, this:
.P
.RS 2
-.EX
+.nf
{ "name" : "foo"
, "version" : "1\.2\.3"
, "description" : "A packaged foo fooer for fooing foos"
, "main" : "foo\.js"
, "man" : [ "\./man/foo\.1", "\./man/bar\.1" ]
}
-.EE
+.fi
.RE
.P
will create files to do \fBman foo\fR and \fBman foo\-bar\fR\|\.
@@ -236,14 +236,14 @@
compressed\. The number dictates which man section the file is installed into\.
.P
.RS 2
-.EX
+.nf
{ "name" : "foo"
, "version" : "1\.2\.3"
, "description" : "A packaged foo fooer for fooing foos"
, "main" : "foo\.js"
, "man" : [ "\./man/foo\.1", "\./man/foo\.2" ]
}
-.EE
+.fi
.RE
.P
will create entries for \fBman foo\fR and \fBman 2 foo\fR
@@ -251,7 +251,7 @@
.P
The CommonJS Packages \fIhttp://wiki\.commonjs\.org/wiki/Packages/1\.0\fR spec details a
few ways that you can indicate the structure of your package using a \fBdirectories\fR
-hash\. If you look at npm's package\.json \fIhttp://registry\.npmjs\.org/npm/latest\fR,
+object\. If you look at npm's package\.json \fIhttp://registry\.npmjs\.org/npm/latest\fR,
you'll see that it has directories for doc, lib, and man\.
.P
In the future, this information may be used in other creative ways\.
@@ -261,10 +261,10 @@
with the lib folder in any way, but it's useful meta info\.
.SS directories\.bin
.P
-If you specify a "bin" directory, then all the files in that folder will
-be used as the "bin" hash\.
+If you specify a \fBbin\fR directory, then all the files in that folder will
+be added as children of the \fBbin\fR path\.
.P
-If you have a "bin" hash already, then this has no effect\.
+If you have a \fBbin\fR path already, then this has no effect\.
.SS directories\.man
.P
A folder that is full of man pages\. Sugar to generate a "man" array by
@@ -285,7 +285,7 @@
Do it like this:
.P
.RS 2
-.EX
+.nf
"repository" :
{ "type" : "git"
, "url" : "http://github\.com/npm/npm\.git"
@@ -295,7 +295,7 @@
{ "type" : "svn"
, "url" : "http://v8\.googlecode\.com/svn/trunk/"
}
-.EE
+.fi
.RE
.P
The URL should be a publicly available (perhaps read\-only) url that can be handed
@@ -303,22 +303,22 @@
html project page that you put in your browser\. It's for computers\.
.SH scripts
.P
-The "scripts" member is an object hash of script commands that are run
+The "scripts" property is a dictionary containing script commands that are run
at various times in the lifecycle of your package\. The key is the lifecycle
event, and the value is the command to run at that point\.
.P
See npm help 7 \fBnpm\-scripts\fR to find out more about writing package scripts\.
.SH config
.P
-A "config" hash can be used to set configuration
-parameters used in package scripts that persist across upgrades\. For
-instance, if a package had the following:
+A "config" object can be used to set configuration parameters used in package
+scripts that persist across upgrades\. For instance, if a package had the
+following:
.P
.RS 2
-.EX
+.nf
{ "name" : "foo"
, "config" : { "port" : "8080" } }
-.EE
+.fi
.RE
.P
and then had a "start" command that then referenced the
@@ -329,13 +329,13 @@
configs\.
.SH dependencies
.P
-Dependencies are specified with a simple hash of package name to
+Dependencies are specified in a simple object that maps a package name to a
version range\. The version range is a string which has one or more
-space\-separated descriptors\. Dependencies can also be identified with
-a tarball or git URL\.
+space\-separated descriptors\. Dependencies can also be identified with a
+tarball or git URL\.
.P
\fBPlease do not put test harnesses or transpilers in your
-\fBdependencies\fR hash\.\fR See \fBdevDependencies\fR, below\.
+\fBdependencies\fR object\.\fR See \fBdevDependencies\fR, below\.
.P
See npm help 7 semver for more details about specifying version ranges\.
.RS 0
@@ -379,7 +379,7 @@
For example, these are all valid:
.P
.RS 2
-.EX
+.nf
{ "dependencies" :
{ "foo" : "1\.0\.0 \- 2\.9999\.9999"
, "bar" : ">=1\.0\.2 <2\.1\.2"
@@ -392,10 +392,10 @@
, "two" : "2\.x"
, "thr" : "3\.3\.x"
, "lat" : "latest"
- , "dyl" : "~/projects/dyl"
+ , "dyl" : "file:\.\./dyl"
}
}
-.EE
+.fi
.RE
.SS URLs as Dependencies
.P
@@ -408,13 +408,13 @@
Git urls can be of the form:
.P
.RS 2
-.EX
+.nf
git://github\.com/user/project\.git#commit\-ish
git+ssh://user@hostname:project\.git#commit\-ish
git+ssh://user@hostname/project\.git#commit\-ish
git+http://user@hostname/project/blah\.git#commit\-ish
git+https://user@hostname/project/blah\.git#commit\-ish
-.EE
+.fi
.RE
.P
The \fBcommit\-ish\fR can be any tag, sha, or branch which can be supplied as
@@ -424,7 +424,7 @@
As of version 1\.1\.65, you can refer to GitHub urls as just "foo": "user/foo\-project"\. For example:
.P
.RS 2
-.EX
+.nf
{
"name": "foo",
"version": "0\.0\.0",
@@ -432,20 +432,35 @@
"express": "visionmedia/express"
}
}
-.EE
+.fi
.RE
.SH Local Paths
.P
-As of version 2\.0\.0 you can provide a path to a local directory that
-contains a package\. Local paths can be in the form:
+As of version 2\.0\.0 you can provide a path to a local directory that contains a
+package\. Local paths can be saved using \fBnpm install \-\-save\fR, using any of
+these forms:
.P
.RS 2
-.EX
+.nf
\|\.\./foo/bar
~/foo/bar
\|\./foo/bar
/foo/bar
-.EE
+.fi
+.RE
+.P
+in which case they will be normalized to a relative path and added to your
+\fBpackage\.json\fR\|\. For example:
+.P
+.RS 2
+.nf
+{
+ "name": "baz",
+ "dependencies": {
+ "bar": "file:\.\./foo/bar"
+ }
+}
+.fi
.RE
.P
This feature is helpful for local offline development and creating
@@ -458,8 +473,8 @@
program, then they probably don't want or need to download and build
the external test or documentation framework that you use\.
.P
-In this case, it's best to list these additional items in a
-\fBdevDependencies\fR hash\.
+In this case, it's best to map these additional items in a \fBdevDependencies\fR
+object\.
.P
These things will be installed when doing \fBnpm link\fR or \fBnpm install\fR
from the root of a package, and can be managed like any other npm
@@ -472,7 +487,7 @@
For example:
.P
.RS 2
-.EX
+.nf
{ "name": "ethopia\-waza",
"description": "a delightfully fruity coffee varietal",
"version": "1\.2\.3",
@@ -484,7 +499,7 @@
},
"main": "lib/waza\.js"
}
-.EE
+.fi
.RE
.P
The \fBprepublish\fR script will be run before publishing, so that users
@@ -501,7 +516,7 @@
For example:
.P
.RS 2
-.EX
+.nf
{
"name": "tea\-latte",
"version": "1\.3\.5"
@@ -509,7 +524,7 @@
"tea": "2\.x"
}
}
-.EE
+.fi
.RE
.P
This ensures your package \fBtea\-latte\fR can be installed \fIalong\fR with the second
@@ -518,10 +533,10 @@
dependency graph:
.P
.RS 2
-.EX
+.nf
├── tea\-latte@1\.3\.5
└── tea@2\.2\.0
-.EE
+.fi
.RE
.P
Trying to install another plugin with a conflicting requirement will cause an
@@ -539,17 +554,17 @@
If this is spelled \fB"bundleDependencies"\fR, then that is also honorable\.
.SH optionalDependencies
.P
-If a dependency can be used, but you would like npm to proceed if it
-cannot be found or fails to install, then you may put it in the
-\fBoptionalDependencies\fR hash\. This is a map of package name to version
-or url, just like the \fBdependencies\fR hash\. The difference is that
-failure is tolerated\.
+If a dependency can be used, but you would like npm to proceed if it cannot be
+found or fails to install, then you may put it in the \fBoptionalDependencies\fR
+object\. This is a map of package name to version or url, just like the
+\fBdependencies\fR object\. The difference is that build failures do not cause
+installation to fail\.
.P
It is still your program's responsibility to handle the lack of the
dependency\. For example, something like this:
.P
.RS 2
-.EX
+.nf
try {
var foo = require('foo')
var fooVersion = require('foo/package\.json')\.version
@@ -565,7 +580,7 @@
if (foo) {
foo\.doFooThings()
}
-.EE
+.fi
.RE
.P
Entries in \fBoptionalDependencies\fR will override entries of the same name in
@@ -575,9 +590,9 @@
You can specify the version of node that your stuff works on:
.P
.RS 2
-.EX
+.nf
{ "engines" : { "node" : ">=0\.10\.3 <0\.12" } }
-.EE
+.fi
.RE
.P
And, like with dependencies, if you don't specify the version (or if you
@@ -591,9 +606,9 @@
are capable of properly installing your program\. For example:
.P
.RS 2
-.EX
+.nf
{ "engines" : { "npm" : "~1\.0\.20" } }
-.EE
+.fi
.RE
.P
Note that, unless the user has set the \fBengine\-strict\fR config flag, this
@@ -601,12 +616,12 @@
.SH engineStrict
.P
If you are sure that your module will \fIdefinitely not\fR run properly on
-versions of Node/npm other than those specified in the \fBengines\fR hash,
+versions of Node/npm other than those specified in the \fBengines\fR object,
then you can set \fB"engineStrict": true\fR in your package\.json file\.
This will override the user's \fBengine\-strict\fR config setting\.
.P
Please do not do this unless you are really very very sure\. If your
-engines hash is something overly restrictive, you can quite easily and
+engines object is something overly restrictive, you can quite easily and
inadvertently lock yourself into obscurity and prevent your users from
updating to new versions of Node\. Consider this choice carefully\. If
people abuse it, it will be removed in a future version of npm\.
@@ -616,18 +631,18 @@
module will run on:
.P
.RS 2
-.EX
+.nf
"os" : [ "darwin", "linux" ]
-.EE
+.fi
.RE
.P
You can also blacklist instead of whitelist operating systems,
just prepend the blacklisted os with a '!':
.P
.RS 2
-.EX
+.nf
"os" : [ "!win32" ]
-.EE
+.fi
.RE
.P
The host operating system is determined by \fBprocess\.platform\fR
@@ -640,17 +655,17 @@
you can specify which ones\.
.P
.RS 2
-.EX
+.nf
"cpu" : [ "x64", "ia32" ]
-.EE
+.fi
.RE
.P
Like the \fBos\fR option, you can also blacklist architectures:
.P
.RS 2
-.EX
+.nf
"cpu" : [ "!arm", "!mips" ]
-.EE
+.fi
.RE
.P
The host architecture is determined by \fBprocess\.arch\fR
@@ -667,11 +682,11 @@
If you set \fB"private": true\fR in your package\.json, then npm will refuse
to publish it\.
.P
-This is a way to prevent accidental publication of private repositories\.
-If you would like to ensure that a given package is only ever published
-to a specific registry (for example, an internal registry),
-then use the \fBpublishConfig\fR hash described below
-to override the \fBregistry\fR config param at publish\-time\.
+This is a way to prevent accidental publication of private repositories\. If
+you would like to ensure that a given package is only ever published to a
+specific registry (for example, an internal registry), then use the
+\fBpublishConfig\fR dictionary described below to override the \fBregistry\fR config
+param at publish\-time\.
.SH publishConfig
.P
This is a set of config values that will be used at publish\-time\. It's
diff -Nru nodejs-0.11.14/deps/npm/man/man7/npm-coding-style.7 nodejs-0.11.15/deps/npm/man/man7/npm-coding-style.7
--- nodejs-0.11.14/deps/npm/man/man7/npm-coding-style.7 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man7/npm-coding-style.7 2015-01-20 21:22:17.000000000 +0000
@@ -1,4 +1,4 @@
-.TH "NPM\-CODING\-STYLE" "7" "September 2014" "" ""
+.TH "NPM\-CODING\-STYLE" "7" "October 2014" "" ""
.SH "NAME"
\fBnpm-coding-style\fR \- npm's "funny" coding style
.SH DESCRIPTION
@@ -29,18 +29,18 @@
Bad:
.P
.RS 2
-.EX
+.nf
function ()
{
-.EE
+.fi
.RE
.P
Good:
.P
.RS 2
-.EX
+.nf
function () {
-.EE
+.fi
.RE
.P
If a block needs to wrap to the next line, use a curly brace\. Don't
@@ -49,22 +49,22 @@
Bad:
.P
.RS 2
-.EX
+.nf
if (foo) { bar() }
while (foo)
bar()
-.EE
+.fi
.RE
.P
Good:
.P
.RS 2
-.EX
+.nf
if (foo) bar()
while (foo) {
bar()
}
-.EE
+.fi
.RE
.SH Semicolons
.P
@@ -87,7 +87,7 @@
Some examples of good semicolon usage:
.P
.RS 2
-.EX
+.nf
;(x || y)\.doSomething()
;[a, b, c]\.forEach(doSomething)
for (var i = 0; i < 10; i ++) {
@@ -98,7 +98,7 @@
}
end()
}
-.EE
+.fi
.RE
.P
Note that starting lines with \fB\-\fR and \fB+\fR also should be prefixed
@@ -111,7 +111,7 @@
final token in the list on a line by itself\. For example:
.P
.RS 2
-.EX
+.nf
var magicWords = [ "abracadabra"
, "gesundheit"
, "ventrilo"
@@ -123,7 +123,7 @@
, b = "abc"
, etc
, somethingElse
-.EE
+.fi
.RE
.SH Whitespace
.P
@@ -166,7 +166,7 @@
.SH Case, naming, etc\.
.P
Use \fBlowerCamelCase\fR for multiword identifiers when they refer to objects,
-functions, methods, members, or anything not specified in this section\.
+functions, methods, properties, or anything not specified in this section\.
.P
Use \fBUpperCamelCase\fR for class names (things that you'd pass to "new")\.
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man7/npm-config.7 nodejs-0.11.15/deps/npm/man/man7/npm-config.7
--- nodejs-0.11.14/deps/npm/man/man7/npm-config.7 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man7/npm-config.7 2015-01-20 21:22:17.000000000 +0000
@@ -1,4 +1,4 @@
-.TH "NPM\-CONFIG" "7" "September 2014" "" ""
+.TH "NPM\-CONFIG" "7" "October 2014" "" ""
.SH "NAME"
\fBnpm-config\fR \- More than you probably want to know about npm configuration
.SH DESCRIPTION
@@ -99,11 +99,11 @@
parameter\. For example:
.P
.RS 2
-.EX
+.nf
npm ls \-\-par
# same as:
npm ls \-\-parseable
-.EE
+.fi
.RE
.P
If multiple single\-character shorthands are strung together, and the
@@ -112,11 +112,11 @@
example:
.P
.RS 2
-.EX
+.nf
npm ls \-gpld
# same as:
npm ls \-\-global \-\-parseable \-\-long \-\-loglevel info
-.EE
+.fi
.RE
.SH Per\-Package Config Settings
.P
@@ -126,27 +126,27 @@
this:
.P
.RS 2
-.EX
+.nf
{ "name" : "foo"
, "config" : { "port" : "8080" }
, "scripts" : { "start" : "node server\.js" } }
-.EE
+.fi
.RE
.P
and the server\.js is this:
.P
.RS 2
-.EX
+.nf
http\.createServer(\.\.\.)\.listen(process\.env\.npm_package_config_port)
-.EE
+.fi
.RE
.P
then the user could change the behavior by doing:
.P
.RS 2
-.EX
+.nf
npm config set foo:port 80
-.EE
+.fi
.RE
.P
See npm help 5 package\.json for more information\.
@@ -535,7 +535,7 @@
documentation for the
init\-package\-json \fIhttps://github\.com/isaacs/init\-package\-json\fR module
for more information, or npm help init\.
-.SS init\.author\.name
+.SS init\-author\-name
.RS 0
.IP \(bu 2
Default: ""
@@ -545,7 +545,7 @@
.RE
.P
The value \fBnpm init\fR should use by default for the package author's name\.
-.SS init\.author\.email
+.SS init\-author\-email
.RS 0
.IP \(bu 2
Default: ""
@@ -555,7 +555,7 @@
.RE
.P
The value \fBnpm init\fR should use by default for the package author's email\.
-.SS init\.author\.url
+.SS init\-author\-url
.RS 0
.IP \(bu 2
Default: ""
@@ -565,7 +565,7 @@
.RE
.P
The value \fBnpm init\fR should use by default for the package author's homepage\.
-.SS init\.license
+.SS init\-license
.RS 0
.IP \(bu 2
Default: "ISC"
@@ -575,7 +575,7 @@
.RE
.P
The value \fBnpm init\fR should use by default for the package license\.
-.SS init\.version
+.SS init\-version
.RS 0
.IP \(bu 2
Default: "0\.0\.0"
@@ -647,7 +647,7 @@
.SS loglevel
.RS 0
.IP \(bu 2
-Default: "http"
+Default: "warn"
.IP \(bu 2
Type: String
.IP \(bu 2
@@ -659,7 +659,7 @@
\fBnpm\-debug\.log\fR in the current working directory\.
.P
Any logs of a higher level than the setting are shown\.
-The default is "http", which shows http, warn, and error output\.
+The default is "warn", which shows warn and error output\.
.SS logstream
.RS 0
.IP \(bu 2
@@ -709,7 +709,7 @@
.RE
.P
-The node version to use when checking package's "engines" hash\.
+The node version to use when checking a package's \fBengines\fR map\.
.SS npat
.RS 0
.IP \(bu 2
@@ -740,7 +740,7 @@
.RE
.P
-Attempt to install packages in the \fBoptionalDependencies\fR hash\. Note
+Attempt to install packages in the \fBoptionalDependencies\fR object\. Note
that if these packages fail to install, the overall installation
process is not aborted\.
.SS parseable
@@ -849,8 +849,8 @@
.P
Save installed packages to a package\.json file as dependencies\.
.P
-When used with the \fBnpm rm\fR command, it removes it from the dependencies
-hash\.
+When used with the \fBnpm rm\fR command, it removes it from the \fBdependencies\fR
+object\.
.P
Only works if there is already a package\.json file present\.
.SS save\-bundle
@@ -877,10 +877,10 @@
.RE
.P
-Save installed packages to a package\.json file as devDependencies\.
+Save installed packages to a package\.json file as \fBdevDependencies\fR\|\.
.P
When used with the \fBnpm rm\fR command, it removes it from the
-devDependencies hash\.
+\fBdevDependencies\fR object\.
.P
Only works if there is already a package\.json file present\.
.SS save\-exact
@@ -908,7 +908,7 @@
optionalDependencies\.
.P
When used with the \fBnpm rm\fR command, it removes it from the
-devDependencies hash\.
+\fBdevDependencies\fR object\.
.P
Only works if there is already a package\.json file present\.
.SS save\-prefix
@@ -1163,8 +1163,8 @@
.RE
.P
-If true, output the npm version as well as node's \fBprocess\.versions\fR
-hash, and exit successfully\.
+If true, output the npm version as well as node's \fBprocess\.versions\fR map, and
+exit successfully\.
.P
Only relevant when specified explicitly on the command line\.
.SS viewer
diff -Nru nodejs-0.11.14/deps/npm/man/man7/npm-developers.7 nodejs-0.11.15/deps/npm/man/man7/npm-developers.7
--- nodejs-0.11.14/deps/npm/man/man7/npm-developers.7 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man7/npm-developers.7 2015-01-20 21:22:17.000000000 +0000
@@ -1,4 +1,4 @@
-.TH "NPM\-DEVELOPERS" "7" "September 2014" "" ""
+.TH "NPM\-DEVELOPERS" "7" "October 2014" "" ""
.SH "NAME"
\fBnpm-developers\fR \- Developer Guide
.SH DESCRIPTION
@@ -44,12 +44,12 @@
Git urls can be of the form:
.P
.RS 2
-.EX
+.nf
git://github\.com/user/project\.git#commit\-ish
git+ssh://user@hostname:project\.git#commit\-ish
git+http://user@hostname/project/blah\.git#commit\-ish
git+https://user@hostname/project/blah\.git#commit\-ish
-.EE
+.fi
.RE
.P
The \fBcommit\-ish\fR can be any tag, sha, or branch which can be supplied as
@@ -85,7 +85,7 @@
.IP \(bu 2
scripts:
If you have a special compilation or installation script, then you
-should put it in the \fBscripts\fR hash\. You should definitely have at
+should put it in the \fBscripts\fR object\. You should definitely have at
least a basic smoke\-test command as the "scripts\.test" field\.
See npm help 7 scripts\.
.IP \(bu 2
@@ -95,8 +95,8 @@
then you need to specify that in the "main" field\.
.IP \(bu 2
directories:
-This is a hash of folders\. The best ones to include are "lib" and
-"doc", but if you specify a folder full of man pages in "man", then
+This is an object mapping names to folders\. The best ones to include are
+"lib" and "doc", but if you use "man" to specify a folder full of man pages,
they'll get installed just like these ones\.
.RE
@@ -171,18 +171,18 @@
In the root of your package, do this:
.P
.RS 2
-.EX
+.nf
npm install \. \-g
-.EE
+.fi
.RE
.P
That'll show you that it's working\. If you'd rather just create a symlink
package that points to your working directory, then do this:
.P
.RS 2
-.EX
+.nf
npm link
-.EE
+.fi
.RE
.P
Use \fBnpm ls \-g\fR to see if it's there\.
@@ -190,10 +190,10 @@
To test a local install, go into some other folder, and then do:
.P
.RS 2
-.EX
+.nf
cd \.\./some\-other\-folder
npm install \.\./my\-package
-.EE
+.fi
.RE
.P
to install it locally into the node_modules folder in that other place\.
@@ -205,9 +205,9 @@
Create a user with the adduser command\. It works like this:
.P
.RS 2
-.EX
+.nf
npm adduser
-.EE
+.fi
.RE
.P
and then follow the prompts\.
@@ -218,9 +218,9 @@
This part's easy\. IN the root of your folder, do this:
.P
.RS 2
-.EX
+.nf
npm publish
-.EE
+.fi
.RE
.P
You can give publish a url to a tarball, or a filename of a tarball,
diff -Nru nodejs-0.11.14/deps/npm/man/man7/npm-disputes.7 nodejs-0.11.15/deps/npm/man/man7/npm-disputes.7
--- nodejs-0.11.14/deps/npm/man/man7/npm-disputes.7 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man7/npm-disputes.7 2015-01-20 21:22:17.000000000 +0000
@@ -1,4 +1,4 @@
-.TH "NPM\-DISPUTES" "7" "September 2014" "" ""
+.TH "NPM\-DISPUTES" "7" "October 2014" "" ""
.SH "NAME"
\fBnpm-disputes\fR \- Handling Module Name Disputes
.SH SYNOPSIS
diff -Nru nodejs-0.11.14/deps/npm/man/man7/npm-faq.7 nodejs-0.11.15/deps/npm/man/man7/npm-faq.7
--- nodejs-0.11.14/deps/npm/man/man7/npm-faq.7 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man7/npm-faq.7 2015-01-20 21:22:17.000000000 +0000
@@ -1,4 +1,4 @@
-.TH "NPM\-FAQ" "7" "September 2014" "" ""
+.TH "NPM\-FAQ" "7" "October 2014" "" ""
.SH "NAME"
\fBnpm-faq\fR \- Frequently Asked Questions
.SH Where can I find these docs in HTML?
@@ -6,9 +6,9 @@
https://www\.npmjs\.org/doc/, or run:
.P
.RS 2
-.EX
+.nf
npm config set viewer browser
-.EE
+.fi
.RE
.P
to open these documents in your default web browser rather than \fBman\fR\|\.
@@ -131,9 +131,9 @@
.SH How do I update npm?
.P
.RS 2
-.EX
-npm update npm \-g
-.EE
+.nf
+npm install npm \-g
+.fi
.RE
.P
You can also update all outdated local packages by doing \fBnpm update\fR without
@@ -147,9 +147,9 @@
In those cases, you can do this:
.P
.RS 2
-.EX
+.nf
curl https://www\.npmjs\.org/install\.sh | sh
-.EE
+.fi
.RE
.SH What is a \fBpackage\fR?
.P
@@ -180,12 +180,12 @@
Git urls can be of the form:
.P
.RS 2
-.EX
+.nf
git://github\.com/user/project\.git#commit\-ish
git+ssh://user@hostname:project\.git#commit\-ish
git+http://user@hostname/project/blah\.git#commit\-ish
git+https://user@hostname/project/blah\.git#commit\-ish
-.EE
+.fi
.RE
.P
The \fBcommit\-ish\fR can be any tag, sha, or branch which can be supplied as
@@ -218,9 +218,9 @@
was loaded \fIfrom\fR a file\. For example, in the following program:
.P
.RS 2
-.EX
+.nf
var req = require('request')
-.EE
+.fi
.RE
.P
we might say that "The variable \fBreq\fR refers to the \fBrequest\fR module"\.
diff -Nru nodejs-0.11.14/deps/npm/man/man7/npm-index.7 nodejs-0.11.15/deps/npm/man/man7/npm-index.7
--- nodejs-0.11.14/deps/npm/man/man7/npm-index.7 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man7/npm-index.7 2015-01-20 21:22:17.000000000 +0000
@@ -1,4 +1,4 @@
-.TH "NPM\-INDEX" "7" "September 2014" "" ""
+.TH "NPM\-INDEX" "7" "October 2014" "" ""
.SH "NAME"
\fBnpm-index\fR \- Index of all npm documentation
.SS npm help README
@@ -121,9 +121,6 @@
.SS npm help stop
.P
Stop a package
-.SS npm help submodule
-.P
-Add a package as a git submodule
.SS npm help tag
.P
Tag a published version
@@ -244,9 +241,6 @@
.SS npm apihelp stop
.P
Stop a package
-.SS npm apihelp submodule
-.P
-Add a package as a git submodule
.SS npm apihelp tag
.P
Tag a published version
diff -Nru nodejs-0.11.14/deps/npm/man/man7/npm-registry.7 nodejs-0.11.15/deps/npm/man/man7/npm-registry.7
--- nodejs-0.11.14/deps/npm/man/man7/npm-registry.7 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man7/npm-registry.7 2015-01-20 21:22:17.000000000 +0000
@@ -1,4 +1,4 @@
-.TH "NPM\-REGISTRY" "7" "September 2014" "" ""
+.TH "NPM\-REGISTRY" "7" "October 2014" "" ""
.SH "NAME"
\fBnpm-registry\fR \- The JavaScript Package Registry
.SH DESCRIPTION
diff -Nru nodejs-0.11.14/deps/npm/man/man7/npm-scope.7 nodejs-0.11.15/deps/npm/man/man7/npm-scope.7
--- nodejs-0.11.14/deps/npm/man/man7/npm-scope.7 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man7/npm-scope.7 2015-01-20 21:22:17.000000000 +0000
@@ -1,4 +1,4 @@
-.TH "NPM\-SCOPE" "7" "September 2014" "" ""
+.TH "NPM\-SCOPE" "7" "October 2014" "" ""
.SH "NAME"
\fBnpm-scope\fR \- Scoped packages
.SH DESCRIPTION
@@ -9,9 +9,9 @@
followed by a slash, e\.g\.
.P
.RS 2
-.EX
+.nf
@somescope/somepackagename
-.EE
+.fi
.RE
.P
Scopes are a way of grouping related packages together, and also affect a few
@@ -28,23 +28,23 @@
(\fB@myorg\fR) is simply the name of the scope preceded by an @\-symbol, and can
contain any number of scoped packages\.
.P
-A scoped package is install by referencing it by name, preceded by an @\-symbol,
-in \fBnpm install\fR:
+A scoped package is installed by referencing it by name, preceded by an
+@\-symbol, in \fBnpm install\fR:
.P
.RS 2
-.EX
+.nf
npm install @myorg/mypackage
-.EE
+.fi
.RE
.P
Or in \fBpackage\.json\fR:
.P
.RS 2
-.EX
+.nf
"dependencies": {
"@myorg/mypackage": "^1\.3\.0"
}
-.EE
+.fi
.RE
.P
Note that if the @\-symbol is omitted in either case npm will instead attempt to
@@ -55,9 +55,9 @@
include the name of the scope when requiring them in your code, e\.g\.
.P
.RS 2
-.EX
+.nf
require('@myorg/mypackage')
-.EE
+.fi
.RE
.P
There is nothing special about the way Node treats scope folders, this is
@@ -77,9 +77,9 @@
You can associate a scope with a registry at login, e\.g\.
.P
.RS 2
-.EX
+.nf
npm login \-\-registry=http://reg\.example\.com \-\-scope=@myco
-.EE
+.fi
.RE
.P
Scopes have a many\-to\-one relationship with registries: one registry can
@@ -88,9 +88,9 @@
You can also associate a scope with a registry using \fBnpm config\fR:
.P
.RS 2
-.EX
+.nf
npm config set @myco:registry http://reg\.example\.com
-.EE
+.fi
.RE
.P
Once a scope is associated with a registry, any \fBnpm install\fR for a package
diff -Nru nodejs-0.11.14/deps/npm/man/man7/npm-scripts.7 nodejs-0.11.15/deps/npm/man/man7/npm-scripts.7
--- nodejs-0.11.14/deps/npm/man/man7/npm-scripts.7 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man7/npm-scripts.7 2015-01-20 21:22:17.000000000 +0000
@@ -1,9 +1,9 @@
-.TH "NPM\-SCRIPTS" "7" "September 2014" "" ""
+.TH "NPM\-SCRIPTS" "7" "October 2014" "" ""
.SH "NAME"
\fBnpm-scripts\fR \- How npm handles the "scripts" field
.SH DESCRIPTION
.P
-npm supports the "scripts" member of the package\.json script, for the
+npm supports the "scripts" property of the package\.json script, for the
following scripts:
.RS 0
.IP \(bu 2
@@ -47,10 +47,10 @@
.RE
.P
-Additionally, arbitrary scripts can be executed by running `npm run\-script
-.P
- \fB\|\. *Pre* and *post* commands with matching names will be run for
-those as well (e\.g\.\fRpremyscript\fB,\fRmyscript\fB,\fRpostmyscript`)\.
+Additionally, arbitrary scripts can be executed by running \fBnpm
+run\-script \fR\|\. \fIPre\fR and \fIpost\fR commands with matching
+names will be run for those as well (e\.g\. \fBpremyscript\fR, \fBmyscript\fR,
+\fBpostmyscript\fR)\.
.SH NOTE: INSTALL SCRIPTS ARE AN ANTIPATTERN
.P
\fBtl;dr\fR Don't use \fBinstall\fR\|\. Use a \fB\|\.gyp\fR file for compilation, and
@@ -136,11 +136,11 @@
executing the scripts\. So, if your package\.json has this:
.P
.RS 2
-.EX
+.nf
{ "name" : "foo"
, "dependencies" : { "bar" : "0\.1\.x" }
, "scripts": { "start" : "bar \./test" } }
-.EE
+.fi
.RE
.P
then you could run \fBnpm start\fR to execute the \fBbar\fR script, which is
@@ -157,34 +157,34 @@
Configuration parameters are put in the environment with the
\fBnpm_config_\fR prefix\. For instance, you can view the effective \fBroot\fR
config by checking the \fBnpm_config_root\fR environment variable\.
-.SS Special: package\.json "config" hash
+.SS Special: package\.json "config" object
.P
The package\.json "config" keys are overwritten in the environment if
there is a config param of \fB[@]:\fR\|\. For example,
if the package\.json has this:
.P
.RS 2
-.EX
+.nf
{ "name" : "foo"
, "config" : { "port" : "8080" }
, "scripts" : { "start" : "node server\.js" } }
-.EE
+.fi
.RE
.P
and the server\.js is this:
.P
.RS 2
-.EX
+.nf
http\.createServer(\.\.\.)\.listen(process\.env\.npm_package_config_port)
-.EE
+.fi
.RE
.P
then the user could change the behavior by doing:
.P
.RS 2
-.EX
+.nf
npm config set foo:port 80
-.EE
+.fi
.RE
.SS current lifecycle event
.P
@@ -198,23 +198,23 @@
see this in the script:
.P
.RS 2
-.EX
+.nf
process\.env\.npm_package_scripts_install === "foo\.js"
-.EE
+.fi
.RE
.SH EXAMPLES
.P
For example, if your package\.json contains this:
.P
.RS 2
-.EX
+.nf
{ "scripts" :
{ "install" : "scripts/install\.js"
, "postinstall" : "scripts/install\.js"
, "uninstall" : "scripts/uninstall\.js"
}
}
-.EE
+.fi
.RE
.P
then the \fBscripts/install\.js\fR will be called for the install,
@@ -228,14 +228,14 @@
fine:
.P
.RS 2
-.EX
+.nf
{ "scripts" :
{ "preinstall" : "\./configure"
, "install" : "make && make install"
, "test" : "make test"
}
}
-.EE
+.fi
.RE
.SH EXITING
.P
diff -Nru nodejs-0.11.14/deps/npm/man/man7/removing-npm.7 nodejs-0.11.15/deps/npm/man/man7/removing-npm.7
--- nodejs-0.11.14/deps/npm/man/man7/removing-npm.7 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man7/removing-npm.7 2015-01-20 21:22:17.000000000 +0000
@@ -1,4 +1,4 @@
-.TH "NPM\-REMOVAL" "1" "September 2014" "" ""
+.TH "NPM\-REMOVAL" "1" "October 2014" "" ""
.SH "NAME"
\fBnpm-removal\fR \- Cleaning the Slate
.SH SYNOPSIS
@@ -6,17 +6,17 @@
So sad to see you go\.
.P
.RS 2
-.EX
+.nf
sudo npm uninstall npm \-g
-.EE
+.fi
.RE
.P
Or, if that fails, get the npm source code, and do:
.P
.RS 2
-.EX
+.nf
sudo make uninstall
-.EE
+.fi
.RE
.SH More Severe Uninstalling
.P
@@ -39,9 +39,9 @@
To remove everything npm\-related manually:
.P
.RS 2
-.EX
+.nf
rm \-rf /usr/local/{lib/node{,/\.npm,_modules},bin,share/man}/npm*
-.EE
+.fi
.RE
.P
If you installed things \fIwith\fR npm, then your best bet is to uninstall
@@ -50,18 +50,18 @@
around:
.P
.RS 2
-.EX
+.nf
ls \-laF /usr/local/{lib/node{,/\.npm},bin,share/man} | grep npm
-.EE
+.fi
.RE
.P
Prior to version 0\.3, npm used shim files for executables and node
modules\. To track those down, you can do the following:
.P
.RS 2
-.EX
+.nf
find /usr/local/{lib/node,bin} \-exec grep \-l npm \\{\\} \\; ;
-.EE
+.fi
.RE
.P
(This is also in the README file\.)
diff -Nru nodejs-0.11.14/deps/npm/man/man7/semver.7 nodejs-0.11.15/deps/npm/man/man7/semver.7
--- nodejs-0.11.14/deps/npm/man/man7/semver.7 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/man/man7/semver.7 2015-01-20 21:22:17.000000000 +0000
@@ -1,10 +1,10 @@
-.TH "SEMVER" "7" "September 2014" "" ""
+.TH "SEMVER" "7" "October 2014" "" ""
.SH "NAME"
\fBsemver\fR \- The semantic versioner for npm
.SH Usage
.P
.RS 2
-.EX
+.nf
$ npm install semver
semver\.valid('1\.2\.3') // '1\.2\.3'
@@ -13,13 +13,13 @@
semver\.satisfies('1\.2\.3', '1\.x || >=2\.5\.0 || 5\.0\.0 \- 7\.2\.3') // true
semver\.gt('1\.2\.3', '9\.8\.7') // false
semver\.lt('1\.2\.3', '9\.8\.7') // true
-.EE
+.fi
.RE
.P
As a command\-line utility:
.P
.RS 2
-.EX
+.nf
$ semver \-h
Usage: semver [ [\.\.\.]] [\-r | \-i | \-d ]
@@ -37,7 +37,7 @@
Versions are printed in ascending order, so supplying
multiple versions to the utility will just sort them\.
-.EE
+.fi
.RE
.SH Versions
.P
@@ -165,7 +165,7 @@
character is in fact optional\.
.RS 0
.IP \(bu 2
-\fB` (empty string) :=\fR*\fB:=\fR>=0\.0\.0`
+\fB""\fR (empty string) := \fB*\fR := \fB>=0\.0\.0\fR
.IP \(bu 2
\fB1\fR := \fB1\.x\.x\fR := \fB>=1\.0\.0 <2\.0\.0\fR
.IP \(bu 2
diff -Nru nodejs-0.11.14/deps/npm/node_modules/archy/examples/beep.js nodejs-0.11.15/deps/npm/node_modules/archy/examples/beep.js
--- nodejs-0.11.14/deps/npm/node_modules/archy/examples/beep.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/archy/examples/beep.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,24 @@
+var archy = require('../');
+var s = archy({
+ label : 'beep',
+ nodes : [
+ 'ity',
+ {
+ label : 'boop',
+ nodes : [
+ {
+ label : 'o_O',
+ nodes : [
+ {
+ label : 'oh',
+ nodes : [ 'hello', 'puny' ]
+ },
+ 'human'
+ ]
+ },
+ 'party\ntime!'
+ ]
+ }
+ ]
+});
+console.log(s);
diff -Nru nodejs-0.11.14/deps/npm/node_modules/archy/examples/multi_line.js nodejs-0.11.15/deps/npm/node_modules/archy/examples/multi_line.js
--- nodejs-0.11.14/deps/npm/node_modules/archy/examples/multi_line.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/archy/examples/multi_line.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,25 @@
+var archy = require('../');
+
+var s = archy({
+ label : 'beep\none\ntwo',
+ nodes : [
+ 'ity',
+ {
+ label : 'boop',
+ nodes : [
+ {
+ label : 'o_O\nwheee',
+ nodes : [
+ {
+ label : 'oh',
+ nodes : [ 'hello', 'puny\nmeat' ]
+ },
+ 'creature'
+ ]
+ },
+ 'party\ntime!'
+ ]
+ }
+ ]
+});
+console.log(s);
diff -Nru nodejs-0.11.14/deps/npm/node_modules/archy/LICENSE nodejs-0.11.15/deps/npm/node_modules/archy/LICENSE
--- nodejs-0.11.14/deps/npm/node_modules/archy/LICENSE 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/archy/LICENSE 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,18 @@
+This software is released under the MIT license:
+
+Permission is hereby granted, free of charge, to any person obtaining a copy of
+this software and associated documentation files (the "Software"), to deal in
+the Software without restriction, including without limitation the rights to
+use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
+the Software, and to permit persons to whom the Software is furnished to do so,
+subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
+FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
+COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
+IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
+CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
diff -Nru nodejs-0.11.14/deps/npm/node_modules/archy/package.json nodejs-0.11.15/deps/npm/node_modules/archy/package.json
--- nodejs-0.11.14/deps/npm/node_modules/archy/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/archy/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -1,22 +1,42 @@
{
"name": "archy",
- "version": "0.0.2",
+ "version": "1.0.0",
"description": "render nested hierarchies `npm ls` style with unicode pipes",
"main": "index.js",
- "directories": {
- "lib": ".",
- "example": "example",
- "test": "test"
- },
"devDependencies": {
- "tap": "~0.2.3"
+ "tap": "~0.3.3",
+ "tape": "~0.1.1"
},
"scripts": {
"test": "tap test"
},
+ "testling": {
+ "files": "test/*.js",
+ "browsers": {
+ "iexplore": [
+ "6.0",
+ "7.0",
+ "8.0",
+ "9.0"
+ ],
+ "chrome": [
+ "20.0"
+ ],
+ "firefox": [
+ "10.0",
+ "15.0"
+ ],
+ "safari": [
+ "5.1"
+ ],
+ "opera": [
+ "12.0"
+ ]
+ }
+ },
"repository": {
"type": "git",
- "url": "git://github.com/substack/node-archy.git"
+ "url": "http://github.com/substack/node-archy.git"
},
"keywords": [
"hierarchy",
@@ -30,23 +50,30 @@
"email": "mail@substack.net",
"url": "http://substack.net"
},
- "license": "MIT/X11",
- "engine": {
- "node": ">=0.4"
- },
+ "license": "MIT",
+ "gitHead": "30223c16191e877bf027b15b12daf077b9b55b84",
+ "bugs": {
+ "url": "https://github.com/substack/node-archy/issues"
+ },
+ "homepage": "https://github.com/substack/node-archy",
+ "_id": "archy@1.0.0",
+ "_shasum": "f9c8c13757cc1dd7bc379ac77b2c62a5c2868c40",
+ "_from": "archy@>=1.0.0 <2.0.0",
+ "_npmVersion": "1.4.25",
"_npmUser": {
- "name": "isaacs",
- "email": "i@izs.me"
+ "name": "substack",
+ "email": "mail@substack.net"
+ },
+ "maintainers": [
+ {
+ "name": "substack",
+ "email": "mail@substack.net"
+ }
+ ],
+ "dist": {
+ "shasum": "f9c8c13757cc1dd7bc379ac77b2c62a5c2868c40",
+ "tarball": "http://registry.npmjs.org/archy/-/archy-1.0.0.tgz"
},
- "_id": "archy@0.0.2",
- "dependencies": {},
- "optionalDependencies": {},
- "engines": {
- "node": "*"
- },
- "_engineSupported": true,
- "_npmVersion": "1.1.13",
- "_nodeVersion": "v0.7.7-pre",
- "_defaultsLoaded": true,
- "_from": "archy@0.0.2"
+ "directories": {},
+ "_resolved": "https://registry.npmjs.org/archy/-/archy-1.0.0.tgz"
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/archy/README.markdown nodejs-0.11.15/deps/npm/node_modules/archy/README.markdown
--- nodejs-0.11.14/deps/npm/node_modules/archy/README.markdown 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/archy/README.markdown 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
-archy
-=====
+# archy
Render nested hierarchies `npm ls` style with unicode pipes.
+[![browser support](http://ci.testling.com/substack/node-archy.png)](http://ci.testling.com/substack/node-archy)
+
[![build status](https://secure.travis-ci.org/substack/node-archy.png)](http://travis-ci.org/substack/node-archy)
-example
-=======
+# example
``` js
var archy = require('archy');
@@ -50,13 +50,11 @@
time!
```
-methods
-=======
+# methods
var archy = require('archy')
-archy(obj, prefix='', opts={})
-------------------------------
+## archy(obj, prefix='', opts={})
Return a string representation of `obj` with unicode pipe characters like how
`npm ls` looks.
@@ -77,8 +75,7 @@
To disable unicode results in favor of all-ansi output set `opts.unicode` to
`false`.
-install
-=======
+# install
With [npm](http://npmjs.org) do:
@@ -86,7 +83,6 @@
npm install archy
```
-license
-=======
+# license
-MIT/X11
+MIT
diff -Nru nodejs-0.11.14/deps/npm/node_modules/archy/test/beep.js nodejs-0.11.15/deps/npm/node_modules/archy/test/beep.js
--- nodejs-0.11.14/deps/npm/node_modules/archy/test/beep.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/archy/test/beep.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,40 @@
+var test = require('tape');
+var archy = require('../');
+
+test('beep', function (t) {
+ var s = archy({
+ label : 'beep',
+ nodes : [
+ 'ity',
+ {
+ label : 'boop',
+ nodes : [
+ {
+ label : 'o_O',
+ nodes : [
+ {
+ label : 'oh',
+ nodes : [ 'hello', 'puny' ]
+ },
+ 'human'
+ ]
+ },
+ 'party!'
+ ]
+ }
+ ]
+ });
+ t.equal(s, [
+ 'beep',
+ '├── ity',
+ '└─┬ boop',
+ ' ├─┬ o_O',
+ ' │ ├─┬ oh',
+ ' │ │ ├── hello',
+ ' │ │ └── puny',
+ ' │ └── human',
+ ' └── party!',
+ ''
+ ].join('\n'));
+ t.end();
+});
diff -Nru nodejs-0.11.14/deps/npm/node_modules/archy/test/multi_line.js nodejs-0.11.15/deps/npm/node_modules/archy/test/multi_line.js
--- nodejs-0.11.14/deps/npm/node_modules/archy/test/multi_line.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/archy/test/multi_line.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,45 @@
+var test = require('tape');
+var archy = require('../');
+
+test('multi-line', function (t) {
+ var s = archy({
+ label : 'beep\none\ntwo',
+ nodes : [
+ 'ity',
+ {
+ label : 'boop',
+ nodes : [
+ {
+ label : 'o_O\nwheee',
+ nodes : [
+ {
+ label : 'oh',
+ nodes : [ 'hello', 'puny\nmeat' ]
+ },
+ 'creature'
+ ]
+ },
+ 'party\ntime!'
+ ]
+ }
+ ]
+ });
+ t.equal(s, [
+ 'beep',
+ '│ one',
+ '│ two',
+ '├── ity',
+ '└─┬ boop',
+ ' ├─┬ o_O',
+ ' │ │ wheee',
+ ' │ ├─┬ oh',
+ ' │ │ ├── hello',
+ ' │ │ └── puny',
+ ' │ │ meat',
+ ' │ └── creature',
+ ' └── party',
+ ' time!',
+ ''
+ ].join('\n'));
+ t.end();
+});
diff -Nru nodejs-0.11.14/deps/npm/node_modules/archy/test/non_unicode.js nodejs-0.11.15/deps/npm/node_modules/archy/test/non_unicode.js
--- nodejs-0.11.14/deps/npm/node_modules/archy/test/non_unicode.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/archy/test/non_unicode.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,40 @@
+var test = require('tape');
+var archy = require('../');
+
+test('beep', function (t) {
+ var s = archy({
+ label : 'beep',
+ nodes : [
+ 'ity',
+ {
+ label : 'boop',
+ nodes : [
+ {
+ label : 'o_O',
+ nodes : [
+ {
+ label : 'oh',
+ nodes : [ 'hello', 'puny' ]
+ },
+ 'human'
+ ]
+ },
+ 'party!'
+ ]
+ }
+ ]
+ }, '', { unicode : false });
+ t.equal(s, [
+ 'beep',
+ '+-- ity',
+ '`-- boop',
+ ' +-- o_O',
+ ' | +-- oh',
+ ' | | +-- hello',
+ ' | | `-- puny',
+ ' | `-- human',
+ ' `-- party!',
+ ''
+ ].join('\n'));
+ t.end();
+});
diff -Nru nodejs-0.11.14/deps/npm/node_modules/config-chain/index.js nodejs-0.11.15/deps/npm/node_modules/config-chain/index.js
--- nodejs-0.11.14/deps/npm/node_modules/config-chain/index.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/config-chain/index.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,282 @@
+var ProtoList = require('proto-list')
+ , path = require('path')
+ , fs = require('fs')
+ , ini = require('ini')
+ , EE = require('events').EventEmitter
+ , url = require('url')
+ , http = require('http')
+
+var exports = module.exports = function () {
+ var args = [].slice.call(arguments)
+ , conf = new ConfigChain()
+
+ while(args.length) {
+ var a = args.shift()
+ if(a) conf.push
+ ( 'string' === typeof a
+ ? json(a)
+ : a )
+ }
+
+ return conf
+}
+
+//recursively find a file...
+
+var find = exports.find = function () {
+ var rel = path.join.apply(null, [].slice.call(arguments))
+
+ function find(start, rel) {
+ var file = path.join(start, rel)
+ try {
+ fs.statSync(file)
+ return file
+ } catch (err) {
+ if(path.dirname(start) !== start) // root
+ return find(path.dirname(start), rel)
+ }
+ }
+ return find(__dirname, rel)
+}
+
+var parse = exports.parse = function (content, file, type) {
+ content = '' + content
+ // if we don't know what it is, try json and fall back to ini
+ // if we know what it is, then it must be that.
+ if (!type) {
+ try { return JSON.parse(content) }
+ catch (er) { return ini.parse(content) }
+ } else if (type === 'json') {
+ if (this.emit) {
+ try { return JSON.parse(content) }
+ catch (er) { this.emit('error', er) }
+ } else {
+ return JSON.parse(content)
+ }
+ } else {
+ return ini.parse(content)
+ }
+}
+
+var json = exports.json = function () {
+ var args = [].slice.call(arguments).filter(function (arg) { return arg != null })
+ var file = path.join.apply(null, args)
+ var content
+ try {
+ content = fs.readFileSync(file,'utf-8')
+ } catch (err) {
+ return
+ }
+ return parse(content, file, 'json')
+}
+
+var env = exports.env = function (prefix, env) {
+ env = env || process.env
+ var obj = {}
+ var l = prefix.length
+ for(var k in env) {
+ if(k.indexOf(prefix) === 0)
+ obj[k.substring(l)] = env[k]
+ }
+
+ return obj
+}
+
+exports.ConfigChain = ConfigChain
+function ConfigChain () {
+ EE.apply(this)
+ ProtoList.apply(this, arguments)
+ this._awaiting = 0
+ this._saving = 0
+ this.sources = {}
+}
+
+// multi-inheritance-ish
+var extras = {
+ constructor: { value: ConfigChain }
+}
+Object.keys(EE.prototype).forEach(function (k) {
+ extras[k] = Object.getOwnPropertyDescriptor(EE.prototype, k)
+})
+ConfigChain.prototype = Object.create(ProtoList.prototype, extras)
+
+ConfigChain.prototype.del = function (key, where) {
+ // if not specified where, then delete from the whole chain, scorched
+ // earth style
+ if (where) {
+ var target = this.sources[where]
+ target = target && target.data
+ if (!target) {
+ return this.emit('error', new Error('not found '+where))
+ }
+ delete target[key]
+ } else {
+ for (var i = 0, l = this.list.length; i < l; i ++) {
+ delete this.list[i][key]
+ }
+ }
+ return this
+}
+
+ConfigChain.prototype.set = function (key, value, where) {
+ var target
+
+ if (where) {
+ target = this.sources[where]
+ target = target && target.data
+ if (!target) {
+ return this.emit('error', new Error('not found '+where))
+ }
+ } else {
+ target = this.list[0]
+ if (!target) {
+ return this.emit('error', new Error('cannot set, no confs!'))
+ }
+ }
+ target[key] = value
+ return this
+}
+
+ConfigChain.prototype.get = function (key, where) {
+ if (where) {
+ where = this.sources[where]
+ if (where) where = where.data
+ if (where && Object.hasOwnProperty.call(where, key)) return where[key]
+ return undefined
+ }
+ return this.list[0][key]
+}
+
+ConfigChain.prototype.save = function (where, type, cb) {
+ if (typeof type === 'function') cb = type, type = null
+ var target = this.sources[where]
+ if (!target || !(target.path || target.source) || !target.data) {
+ // TODO: maybe save() to a url target could be a PUT or something?
+ // would be easy to swap out with a reddis type thing, too
+ return this.emit('error', new Error('bad save target: '+where))
+ }
+
+ if (target.source) {
+ var pref = target.prefix || ''
+ Object.keys(target.data).forEach(function (k) {
+ target.source[pref + k] = target.data[k]
+ })
+ return this
+ }
+
+ var type = type || target.type
+ var data = target.data
+ if (target.type === 'json') {
+ data = JSON.stringify(data)
+ } else {
+ data = ini.stringify(data)
+ }
+
+ this._saving ++
+ fs.writeFile(target.path, data, 'utf8', function (er) {
+ this._saving --
+ if (er) {
+ if (cb) return cb(er)
+ else return this.emit('error', er)
+ }
+ if (this._saving === 0) {
+ if (cb) cb()
+ this.emit('save')
+ }
+ }.bind(this))
+ return this
+}
+
+ConfigChain.prototype.addFile = function (file, type, name) {
+ name = name || file
+ var marker = {__source__:name}
+ this.sources[name] = { path: file, type: type }
+ this.push(marker)
+ this._await()
+ fs.readFile(file, 'utf8', function (er, data) {
+ if (er) this.emit('error', er)
+ this.addString(data, file, type, marker)
+ }.bind(this))
+ return this
+}
+
+ConfigChain.prototype.addEnv = function (prefix, env, name) {
+ name = name || 'env'
+ var data = exports.env(prefix, env)
+ this.sources[name] = { data: data, source: env, prefix: prefix }
+ return this.add(data, name)
+}
+
+ConfigChain.prototype.addUrl = function (req, type, name) {
+ this._await()
+ var href = url.format(req)
+ name = name || href
+ var marker = {__source__:name}
+ this.sources[name] = { href: href, type: type }
+ this.push(marker)
+ http.request(req, function (res) {
+ var c = []
+ var ct = res.headers['content-type']
+ if (!type) {
+ type = ct.indexOf('json') !== -1 ? 'json'
+ : ct.indexOf('ini') !== -1 ? 'ini'
+ : href.match(/\.json$/) ? 'json'
+ : href.match(/\.ini$/) ? 'ini'
+ : null
+ marker.type = type
+ }
+
+ res.on('data', c.push.bind(c))
+ .on('end', function () {
+ this.addString(Buffer.concat(c), href, type, marker)
+ }.bind(this))
+ .on('error', this.emit.bind(this, 'error'))
+
+ }.bind(this))
+ .on('error', this.emit.bind(this, 'error'))
+ .end()
+
+ return this
+}
+
+ConfigChain.prototype.addString = function (data, file, type, marker) {
+ data = this.parse(data, file, type)
+ this.add(data, marker)
+ return this
+}
+
+ConfigChain.prototype.add = function (data, marker) {
+ if (marker && typeof marker === 'object') {
+ var i = this.list.indexOf(marker)
+ if (i === -1) {
+ return this.emit('error', new Error('bad marker'))
+ }
+ this.splice(i, 1, data)
+ marker = marker.__source__
+ this.sources[marker] = this.sources[marker] || {}
+ this.sources[marker].data = data
+ // we were waiting for this. maybe emit 'load'
+ this._resolve()
+ } else {
+ if (typeof marker === 'string') {
+ this.sources[marker] = this.sources[marker] || {}
+ this.sources[marker].data = data
+ }
+ // trigger the load event if nothing was already going to do so.
+ this._await()
+ this.push(data)
+ process.nextTick(this._resolve.bind(this))
+ }
+ return this
+}
+
+ConfigChain.prototype.parse = exports.parse
+
+ConfigChain.prototype._await = function () {
+ this._awaiting++
+}
+
+ConfigChain.prototype._resolve = function () {
+ this._awaiting--
+ if (this._awaiting === 0) this.emit('load', this)
+}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/config-chain/LICENCE nodejs-0.11.15/deps/npm/node_modules/config-chain/LICENCE
--- nodejs-0.11.14/deps/npm/node_modules/config-chain/LICENCE 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/config-chain/LICENCE 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,22 @@
+Copyright (c) 2011 Dominic Tarr
+
+Permission is hereby granted, free of charge,
+to any person obtaining a copy of this software and
+associated documentation files (the "Software"), to
+deal in the Software without restriction, including
+without limitation the rights to use, copy, modify,
+merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom
+the Software is furnished to do so,
+subject to the following conditions:
+
+The above copyright notice and this permission notice
+shall be included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR
+ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
\ No newline at end of file
diff -Nru nodejs-0.11.14/deps/npm/node_modules/config-chain/node_modules/proto-list/LICENSE nodejs-0.11.15/deps/npm/node_modules/config-chain/node_modules/proto-list/LICENSE
--- nodejs-0.11.14/deps/npm/node_modules/config-chain/node_modules/proto-list/LICENSE 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/config-chain/node_modules/proto-list/LICENSE 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,23 @@
+Copyright 2009, 2010, 2011 Isaac Z. Schlueter.
+All rights reserved.
+
+Permission is hereby granted, free of charge, to any person
+obtaining a copy of this software and associated documentation
+files (the "Software"), to deal in the Software without
+restriction, including without limitation the rights to use,
+copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the
+Software is furnished to do so, subject to the following
+conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+OTHER DEALINGS IN THE SOFTWARE.
diff -Nru nodejs-0.11.14/deps/npm/node_modules/config-chain/node_modules/proto-list/package.json nodejs-0.11.15/deps/npm/node_modules/config-chain/node_modules/proto-list/package.json
--- nodejs-0.11.14/deps/npm/node_modules/config-chain/node_modules/proto-list/package.json 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/config-chain/node_modules/proto-list/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,51 @@
+{
+ "name": "proto-list",
+ "version": "1.2.3",
+ "description": "A utility for managing a prototype chain",
+ "main": "./proto-list.js",
+ "author": {
+ "name": "Isaac Z. Schlueter",
+ "email": "i@izs.me",
+ "url": "http://blog.izs.me/"
+ },
+ "scripts": {
+ "test": "tap test/*.js"
+ },
+ "repository": {
+ "type": "git",
+ "url": "https://github.com/isaacs/proto-list"
+ },
+ "license": {
+ "type": "MIT",
+ "url": "https://github.com/isaacs/proto-list/blob/master/LICENSE"
+ },
+ "devDependencies": {
+ "tap": "0"
+ },
+ "gitHead": "44d76897176861d176a53ed3f3fc5e05cdee7643",
+ "bugs": {
+ "url": "https://github.com/isaacs/proto-list/issues"
+ },
+ "homepage": "https://github.com/isaacs/proto-list",
+ "_id": "proto-list@1.2.3",
+ "_shasum": "6235554a1bca1f0d15e3ca12ca7329d5def42bd9",
+ "_from": "proto-list@~1.2.1",
+ "_npmVersion": "1.4.14",
+ "_npmUser": {
+ "name": "isaacs",
+ "email": "i@izs.me"
+ },
+ "maintainers": [
+ {
+ "name": "isaacs",
+ "email": "i@izs.me"
+ }
+ ],
+ "dist": {
+ "shasum": "6235554a1bca1f0d15e3ca12ca7329d5def42bd9",
+ "tarball": "http://registry.npmjs.org/proto-list/-/proto-list-1.2.3.tgz"
+ },
+ "directories": {},
+ "_resolved": "https://registry.npmjs.org/proto-list/-/proto-list-1.2.3.tgz",
+ "readme": "ERROR: No README data found!"
+}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/config-chain/node_modules/proto-list/proto-list.js nodejs-0.11.15/deps/npm/node_modules/config-chain/node_modules/proto-list/proto-list.js
--- nodejs-0.11.14/deps/npm/node_modules/config-chain/node_modules/proto-list/proto-list.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/config-chain/node_modules/proto-list/proto-list.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,88 @@
+
+module.exports = ProtoList
+
+function setProto(obj, proto) {
+ if (typeof Object.setPrototypeOf === "function")
+ return Object.setPrototypeOf(obj, proto)
+ else
+ obj.__proto__ = proto
+}
+
+function ProtoList () {
+ this.list = []
+ var root = null
+ Object.defineProperty(this, 'root', {
+ get: function () { return root },
+ set: function (r) {
+ root = r
+ if (this.list.length) {
+ setProto(this.list[this.list.length - 1], r)
+ }
+ },
+ enumerable: true,
+ configurable: true
+ })
+}
+
+ProtoList.prototype =
+ { get length () { return this.list.length }
+ , get keys () {
+ var k = []
+ for (var i in this.list[0]) k.push(i)
+ return k
+ }
+ , get snapshot () {
+ var o = {}
+ this.keys.forEach(function (k) { o[k] = this.get(k) }, this)
+ return o
+ }
+ , get store () {
+ return this.list[0]
+ }
+ , push : function (obj) {
+ if (typeof obj !== "object") obj = {valueOf:obj}
+ if (this.list.length >= 1) {
+ setProto(this.list[this.list.length - 1], obj)
+ }
+ setProto(obj, this.root)
+ return this.list.push(obj)
+ }
+ , pop : function () {
+ if (this.list.length >= 2) {
+ setProto(this.list[this.list.length - 2], this.root)
+ }
+ return this.list.pop()
+ }
+ , unshift : function (obj) {
+ setProto(obj, this.list[0] || this.root)
+ return this.list.unshift(obj)
+ }
+ , shift : function () {
+ if (this.list.length === 1) {
+ setProto(this.list[0], this.root)
+ }
+ return this.list.shift()
+ }
+ , get : function (key) {
+ return this.list[0][key]
+ }
+ , set : function (key, val, save) {
+ if (!this.length) this.push({})
+ if (save && this.list[0].hasOwnProperty(key)) this.push({})
+ return this.list[0][key] = val
+ }
+ , forEach : function (fn, thisp) {
+ for (var key in this.list[0]) fn.call(thisp, key, this.list[0][key])
+ }
+ , slice : function () {
+ return this.list.slice.apply(this.list, arguments)
+ }
+ , splice : function () {
+ // handle injections
+ var ret = this.list.splice.apply(this.list, arguments)
+ for (var i = 0, l = this.list.length; i < l; i++) {
+ setProto(this.list[i], this.list[i + 1] || this.root)
+ }
+ return ret
+ }
+ }
diff -Nru nodejs-0.11.14/deps/npm/node_modules/config-chain/node_modules/proto-list/README.md nodejs-0.11.15/deps/npm/node_modules/config-chain/node_modules/proto-list/README.md
--- nodejs-0.11.14/deps/npm/node_modules/config-chain/node_modules/proto-list/README.md 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/config-chain/node_modules/proto-list/README.md 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,3 @@
+A list of objects, bound by their prototype chain.
+
+Used in npm's config stuff.
diff -Nru nodejs-0.11.14/deps/npm/node_modules/config-chain/node_modules/proto-list/test/basic.js nodejs-0.11.15/deps/npm/node_modules/config-chain/node_modules/proto-list/test/basic.js
--- nodejs-0.11.14/deps/npm/node_modules/config-chain/node_modules/proto-list/test/basic.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/config-chain/node_modules/proto-list/test/basic.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,61 @@
+var tap = require("tap")
+ , test = tap.test
+ , ProtoList = require("../proto-list.js")
+
+tap.plan(1)
+
+tap.test("protoList tests", function (t) {
+ var p = new ProtoList
+ p.push({foo:"bar"})
+ p.push({})
+ p.set("foo", "baz")
+ t.equal(p.get("foo"), "baz")
+
+ var p = new ProtoList
+ p.push({foo:"bar"})
+ p.set("foo", "baz")
+ t.equal(p.get("foo"), "baz")
+ t.equal(p.length, 1)
+ p.pop()
+ t.equal(p.length, 0)
+ p.set("foo", "asdf")
+ t.equal(p.length, 1)
+ t.equal(p.get("foo"), "asdf")
+ p.push({bar:"baz"})
+ t.equal(p.length, 2)
+ t.equal(p.get("foo"), "asdf")
+ p.shift()
+ t.equal(p.length, 1)
+ t.equal(p.get("foo"), undefined)
+
+
+ p.unshift({foo:"blo", bar:"rab"})
+ p.unshift({foo:"boo"})
+ t.equal(p.length, 3)
+ t.equal(p.get("foo"), "boo")
+ t.equal(p.get("bar"), "rab")
+
+ var ret = p.splice(1, 1, {bar:"bar"})
+ t.same(ret, [{foo:"blo", bar:"rab"}])
+ t.equal(p.get("bar"), "bar")
+
+ // should not inherit default object properties
+ t.equal(p.get('hasOwnProperty'), undefined)
+
+ // unless we give it those.
+ p.root = {}
+ t.equal(p.get('hasOwnProperty'), {}.hasOwnProperty)
+
+ p.root = {default:'monkey'}
+ t.equal(p.get('default'), 'monkey')
+
+ p.push({red:'blue'})
+ p.push({red:'blue'})
+ p.push({red:'blue'})
+ while (p.length) {
+ t.equal(p.get('default'), 'monkey')
+ p.shift()
+ }
+
+ t.end()
+})
diff -Nru nodejs-0.11.14/deps/npm/node_modules/config-chain/.npmignore nodejs-0.11.15/deps/npm/node_modules/config-chain/.npmignore
--- nodejs-0.11.14/deps/npm/node_modules/config-chain/.npmignore 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/config-chain/.npmignore 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,3 @@
+node_modules
+node_modules/*
+npm_debug.log
diff -Nru nodejs-0.11.14/deps/npm/node_modules/config-chain/package.json nodejs-0.11.15/deps/npm/node_modules/config-chain/package.json
--- nodejs-0.11.14/deps/npm/node_modules/config-chain/package.json 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/config-chain/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,54 @@
+{
+ "name": "config-chain",
+ "version": "1.1.8",
+ "description": "HANDLE CONFIGURATION ONCE AND FOR ALL",
+ "homepage": "http://github.com/dominictarr/config-chain",
+ "repository": {
+ "type": "git",
+ "url": "https://github.com/dominictarr/config-chain.git"
+ },
+ "dependencies": {
+ "proto-list": "~1.2.1",
+ "ini": "1"
+ },
+ "devDependencies": {
+ "tap": "0.3.0"
+ },
+ "author": {
+ "name": "Dominic Tarr",
+ "email": "dominic.tarr@gmail.com",
+ "url": "http://dominictarr.com"
+ },
+ "scripts": {
+ "test": "tap test/"
+ },
+ "readme": "#config-chain\n\nUSE THIS MODULE TO LOAD ALL YOUR CONFIGURATIONS\n\n``` js\n\n //npm install config-chain\n\n var cc = require('config-chain')\n , opts = require('optimist').argv //ALWAYS USE OPTIMIST FOR COMMAND LINE OPTIONS.\n , env = opts.env || process.env.YOUR_APP_ENV || 'dev' //SET YOUR ENV LIKE THIS.\n\n // EACH ARG TO CONFIGURATOR IS LOADED INTO CONFIGURATION CHAIN\n // EARLIER ITEMS OVERIDE LATER ITEMS\n // PUTS COMMAND LINE OPTS FIRST, AND DEFAULTS LAST!\n\n //strings are interpereted as filenames.\n //will be loaded synchronously\n\n var conf =\n cc(\n //OVERRIDE SETTINGS WITH COMMAND LINE OPTS\n opts,\n\n //ENV VARS IF PREFIXED WITH 'myApp_'\n\n cc.env('myApp_'), //myApp_foo = 'like this'\n\n //FILE NAMED BY ENV\n path.join(__dirname, 'config.' + env + '.json'),\n\n //IF `env` is PRODUCTION\n env === 'prod'\n ? path.join(__dirname, 'special.json') //load a special file\n : null //NULL IS IGNORED!\n\n //SUBDIR FOR ENV CONFIG\n path.join(__dirname, 'config', env, 'config.json'),\n\n //SEARCH PARENT DIRECTORIES FROM CURRENT DIR FOR FILE\n cc.find('config.json'),\n\n //PUT DEFAULTS LAST\n {\n host: 'localhost'\n port: 8000\n })\n\n var host = conf.get('host')\n\n // or\n\n var host = conf.store.host\n\n```\n\nFINALLY, EASY FLEXIBLE CONFIGURATIONS!\n\n##see also: [proto-list](https://github.com/isaacs/proto-list/)\n\nWHATS THAT YOU SAY?\n\nYOU WANT A \"CLASS\" SO THAT YOU CAN DO CRAYCRAY JQUERY CRAPS?\n\nEXTEND WITH YOUR OWN FUNCTIONALTY!?\n\n## CONFIGCHAIN LIVES TO SERVE ONLY YOU!\n\n```javascript\nvar cc = require('config-chain')\n\n// all the stuff you did before\nvar config = cc({\n some: 'object'\n },\n cc.find('config.json'),\n cc.env('myApp_')\n )\n // CONFIGS AS A SERVICE, aka \"CaaS\", aka EVERY DEVOPS DREAM OMG!\n .addUrl('http://configurator:1234/my-configs')\n // ASYNC FTW!\n .addFile('/path/to/file.json')\n\n // OBJECTS ARE OK TOO, they're SYNC but they still ORDER RIGHT\n // BECAUSE PROMISES ARE USED BUT NO, NOT *THOSE* PROMISES, JUST\n // ACTUAL PROMISES LIKE YOU MAKE TO YOUR MOM, KEPT OUT OF LOVE\n .add({ another: 'object' })\n\n // DIE A THOUSAND DEATHS IF THIS EVER HAPPENS!!\n .on('error', function (er) {\n // IF ONLY THERE WAS SOMETHIGN HARDER THAN THROW\n // MY SORROW COULD BE ADEQUATELY EXPRESSED. /o\\\n throw er\n })\n\n // THROW A PARTY IN YOUR FACE WHEN ITS ALL LOADED!!\n .on('load', function (config) {\n console.awesome('HOLY SHIT!')\n })\n```\n\n# BORING API DOCS\n\n## cc(...args)\n\nMAKE A CHAIN AND ADD ALL THE ARGS.\n\nIf the arg is a STRING, then it shall be a JSON FILENAME.\n\nSYNC I/O!\n\nRETURN THE CHAIN!\n\n## cc.json(...args)\n\nJoin the args INTO A JSON FILENAME!\n\nSYNC I/O!\n\n## cc.find(relativePath)\n\nSEEK the RELATIVE PATH by climbing the TREE OF DIRECTORIES.\n\nRETURN THE FOUND PATH!\n\nSYNC I/O!\n\n## cc.parse(content, file, type)\n\nParse the content string, and guess the type from either the\nspecified type or the filename.\n\nRETURN THE RESULTING OBJECT!\n\nNO I/O!\n\n## cc.env(prefix, env=process.env)\n\nGet all the keys on the provided env object (or process.env) which are\nprefixed by the specified prefix, and put the values on a new object.\n\nRETURN THE RESULTING OBJECT!\n\nNO I/O!\n\n## cc.ConfigChain()\n\nThe ConfigChain class for CRAY CRAY JQUERY STYLE METHOD CHAINING!\n\nOne of these is returned by the main exported function, as well.\n\nIt inherits (prototypically) from\n[ProtoList](https://github.com/isaacs/proto-list/), and also inherits\n(parasitically) from\n[EventEmitter](http://nodejs.org/api/events.html#events_class_events_eventemitter)\n\nIt has all the methods from both, and except where noted, they are\nunchanged.\n\n### LET IT BE KNOWN THAT chain IS AN INSTANCE OF ConfigChain.\n\n## chain.sources\n\nA list of all the places where it got stuff. The keys are the names\npassed to addFile or addUrl etc, and the value is an object with some\ninfo about the data source.\n\n## chain.addFile(filename, type, [name=filename])\n\nFilename is the name of the file. Name is an arbitrary string to be\nused later if you desire. Type is either 'ini' or 'json', and will\ntry to guess intelligently if omitted.\n\nLoaded files can be saved later.\n\n## chain.addUrl(url, type, [name=url])\n\nSame as the filename thing, but with a url.\n\nCan't be saved later.\n\n## chain.addEnv(prefix, env, [name='env'])\n\nAdd all the keys from the env object that start with the prefix.\n\n## chain.addString(data, file, type, [name])\n\nParse the string and add it to the set. (Mainly used internally.)\n\n## chain.add(object, [name])\n\nAdd the object to the set.\n\n## chain.root {Object}\n\nThe root from which all the other config objects in the set descend\nprototypically.\n\nPut your defaults here.\n\n## chain.set(key, value, name)\n\nSet the key to the value on the named config object. If name is\nunset, then set it on the first config object in the set. (That is,\nthe one with the highest priority, which was added first.)\n\n## chain.get(key, [name])\n\nGet the key from the named config object explicitly, or from the\nresolved configs if not specified.\n\n## chain.save(name, type)\n\nWrite the named config object back to its origin.\n\nCurrently only supported for env and file config types.\n\nFor files, encode the data according to the type.\n\n## chain.on('save', function () {})\n\nWhen one or more files are saved, emits `save` event when they're all\nsaved.\n\n## chain.on('load', function (chain) {})\n\nWhen the config chain has loaded all the specified files and urls and\nsuch, the 'load' event fires.\n",
+ "readmeFilename": "readme.markdown",
+ "bugs": {
+ "url": "https://github.com/dominictarr/config-chain/issues"
+ },
+ "_id": "config-chain@1.1.8",
+ "dist": {
+ "shasum": "0943d0b7227213a20d4eaff4434f4a1c0a052cad",
+ "tarball": "http://registry.npmjs.org/config-chain/-/config-chain-1.1.8.tgz"
+ },
+ "_from": "config-chain@^1.1.8",
+ "_npmVersion": "1.3.6",
+ "_npmUser": {
+ "name": "dominictarr",
+ "email": "dominic.tarr@gmail.com"
+ },
+ "maintainers": [
+ {
+ "name": "dominictarr",
+ "email": "dominic.tarr@gmail.com"
+ },
+ {
+ "name": "isaacs",
+ "email": "i@izs.me"
+ }
+ ],
+ "directories": {},
+ "_shasum": "0943d0b7227213a20d4eaff4434f4a1c0a052cad",
+ "_resolved": "https://registry.npmjs.org/config-chain/-/config-chain-1.1.8.tgz"
+}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/config-chain/readme.markdown nodejs-0.11.15/deps/npm/node_modules/config-chain/readme.markdown
--- nodejs-0.11.14/deps/npm/node_modules/config-chain/readme.markdown 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/config-chain/readme.markdown 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,228 @@
+#config-chain
+
+USE THIS MODULE TO LOAD ALL YOUR CONFIGURATIONS
+
+``` js
+
+ //npm install config-chain
+
+ var cc = require('config-chain')
+ , opts = require('optimist').argv //ALWAYS USE OPTIMIST FOR COMMAND LINE OPTIONS.
+ , env = opts.env || process.env.YOUR_APP_ENV || 'dev' //SET YOUR ENV LIKE THIS.
+
+ // EACH ARG TO CONFIGURATOR IS LOADED INTO CONFIGURATION CHAIN
+ // EARLIER ITEMS OVERIDE LATER ITEMS
+ // PUTS COMMAND LINE OPTS FIRST, AND DEFAULTS LAST!
+
+ //strings are interpereted as filenames.
+ //will be loaded synchronously
+
+ var conf =
+ cc(
+ //OVERRIDE SETTINGS WITH COMMAND LINE OPTS
+ opts,
+
+ //ENV VARS IF PREFIXED WITH 'myApp_'
+
+ cc.env('myApp_'), //myApp_foo = 'like this'
+
+ //FILE NAMED BY ENV
+ path.join(__dirname, 'config.' + env + '.json'),
+
+ //IF `env` is PRODUCTION
+ env === 'prod'
+ ? path.join(__dirname, 'special.json') //load a special file
+ : null //NULL IS IGNORED!
+
+ //SUBDIR FOR ENV CONFIG
+ path.join(__dirname, 'config', env, 'config.json'),
+
+ //SEARCH PARENT DIRECTORIES FROM CURRENT DIR FOR FILE
+ cc.find('config.json'),
+
+ //PUT DEFAULTS LAST
+ {
+ host: 'localhost'
+ port: 8000
+ })
+
+ var host = conf.get('host')
+
+ // or
+
+ var host = conf.store.host
+
+```
+
+FINALLY, EASY FLEXIBLE CONFIGURATIONS!
+
+##see also: [proto-list](https://github.com/isaacs/proto-list/)
+
+WHATS THAT YOU SAY?
+
+YOU WANT A "CLASS" SO THAT YOU CAN DO CRAYCRAY JQUERY CRAPS?
+
+EXTEND WITH YOUR OWN FUNCTIONALTY!?
+
+## CONFIGCHAIN LIVES TO SERVE ONLY YOU!
+
+```javascript
+var cc = require('config-chain')
+
+// all the stuff you did before
+var config = cc({
+ some: 'object'
+ },
+ cc.find('config.json'),
+ cc.env('myApp_')
+ )
+ // CONFIGS AS A SERVICE, aka "CaaS", aka EVERY DEVOPS DREAM OMG!
+ .addUrl('http://configurator:1234/my-configs')
+ // ASYNC FTW!
+ .addFile('/path/to/file.json')
+
+ // OBJECTS ARE OK TOO, they're SYNC but they still ORDER RIGHT
+ // BECAUSE PROMISES ARE USED BUT NO, NOT *THOSE* PROMISES, JUST
+ // ACTUAL PROMISES LIKE YOU MAKE TO YOUR MOM, KEPT OUT OF LOVE
+ .add({ another: 'object' })
+
+ // DIE A THOUSAND DEATHS IF THIS EVER HAPPENS!!
+ .on('error', function (er) {
+ // IF ONLY THERE WAS SOMETHIGN HARDER THAN THROW
+ // MY SORROW COULD BE ADEQUATELY EXPRESSED. /o\
+ throw er
+ })
+
+ // THROW A PARTY IN YOUR FACE WHEN ITS ALL LOADED!!
+ .on('load', function (config) {
+ console.awesome('HOLY SHIT!')
+ })
+```
+
+# BORING API DOCS
+
+## cc(...args)
+
+MAKE A CHAIN AND ADD ALL THE ARGS.
+
+If the arg is a STRING, then it shall be a JSON FILENAME.
+
+SYNC I/O!
+
+RETURN THE CHAIN!
+
+## cc.json(...args)
+
+Join the args INTO A JSON FILENAME!
+
+SYNC I/O!
+
+## cc.find(relativePath)
+
+SEEK the RELATIVE PATH by climbing the TREE OF DIRECTORIES.
+
+RETURN THE FOUND PATH!
+
+SYNC I/O!
+
+## cc.parse(content, file, type)
+
+Parse the content string, and guess the type from either the
+specified type or the filename.
+
+RETURN THE RESULTING OBJECT!
+
+NO I/O!
+
+## cc.env(prefix, env=process.env)
+
+Get all the keys on the provided env object (or process.env) which are
+prefixed by the specified prefix, and put the values on a new object.
+
+RETURN THE RESULTING OBJECT!
+
+NO I/O!
+
+## cc.ConfigChain()
+
+The ConfigChain class for CRAY CRAY JQUERY STYLE METHOD CHAINING!
+
+One of these is returned by the main exported function, as well.
+
+It inherits (prototypically) from
+[ProtoList](https://github.com/isaacs/proto-list/), and also inherits
+(parasitically) from
+[EventEmitter](http://nodejs.org/api/events.html#events_class_events_eventemitter)
+
+It has all the methods from both, and except where noted, they are
+unchanged.
+
+### LET IT BE KNOWN THAT chain IS AN INSTANCE OF ConfigChain.
+
+## chain.sources
+
+A list of all the places where it got stuff. The keys are the names
+passed to addFile or addUrl etc, and the value is an object with some
+info about the data source.
+
+## chain.addFile(filename, type, [name=filename])
+
+Filename is the name of the file. Name is an arbitrary string to be
+used later if you desire. Type is either 'ini' or 'json', and will
+try to guess intelligently if omitted.
+
+Loaded files can be saved later.
+
+## chain.addUrl(url, type, [name=url])
+
+Same as the filename thing, but with a url.
+
+Can't be saved later.
+
+## chain.addEnv(prefix, env, [name='env'])
+
+Add all the keys from the env object that start with the prefix.
+
+## chain.addString(data, file, type, [name])
+
+Parse the string and add it to the set. (Mainly used internally.)
+
+## chain.add(object, [name])
+
+Add the object to the set.
+
+## chain.root {Object}
+
+The root from which all the other config objects in the set descend
+prototypically.
+
+Put your defaults here.
+
+## chain.set(key, value, name)
+
+Set the key to the value on the named config object. If name is
+unset, then set it on the first config object in the set. (That is,
+the one with the highest priority, which was added first.)
+
+## chain.get(key, [name])
+
+Get the key from the named config object explicitly, or from the
+resolved configs if not specified.
+
+## chain.save(name, type)
+
+Write the named config object back to its origin.
+
+Currently only supported for env and file config types.
+
+For files, encode the data according to the type.
+
+## chain.on('save', function () {})
+
+When one or more files are saved, emits `save` event when they're all
+saved.
+
+## chain.on('load', function (chain) {})
+
+When the config chain has loaded all the specified files and urls and
+such, the 'load' event fires.
diff -Nru nodejs-0.11.14/deps/npm/node_modules/config-chain/test/broken.js nodejs-0.11.15/deps/npm/node_modules/config-chain/test/broken.js
--- nodejs-0.11.14/deps/npm/node_modules/config-chain/test/broken.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/config-chain/test/broken.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,10 @@
+
+
+var cc = require('..')
+var assert = require('assert')
+
+
+//throw on invalid json
+assert.throws(function () {
+ cc(__dirname + '/broken.json')
+})
diff -Nru nodejs-0.11.14/deps/npm/node_modules/config-chain/test/broken.json nodejs-0.11.15/deps/npm/node_modules/config-chain/test/broken.json
--- nodejs-0.11.14/deps/npm/node_modules/config-chain/test/broken.json 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/config-chain/test/broken.json 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,21 @@
+{
+ "name": "config-chain",
+ "version": "0.3.0",
+ "description": "HANDLE CONFIGURATION ONCE AND FOR ALL",
+ "homepage": "http://github.com/dominictarr/config-chain",
+ "repository": {
+ "type": "git",
+ "url": "https://github.com/dominictarr/config-chain.git"
+ }
+ //missing , and then this comment. this json is intensionally invalid
+ "dependencies": {
+ "proto-list": "1",
+ "ini": "~1.0.2"
+ },
+ "bundleDependencies": ["ini"],
+ "REM": "REMEMBER TO REMOVE BUNDLING WHEN/IF ISAACS MERGES ini#7",
+ "author": "Dominic Tarr (http://dominictarr.com)",
+ "scripts": {
+ "test": "node test/find-file.js && node test/ini.js && node test/env.js"
+ }
+}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/config-chain/test/chain-class.js nodejs-0.11.15/deps/npm/node_modules/config-chain/test/chain-class.js
--- nodejs-0.11.14/deps/npm/node_modules/config-chain/test/chain-class.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/config-chain/test/chain-class.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,100 @@
+var test = require('tap').test
+var CC = require('../index.js').ConfigChain
+
+var env = { foo_blaz : 'blzaa', foo_env : 'myenv' }
+var jsonObj = { blaz: 'json', json: true }
+var iniObj = { 'x.y.z': 'xyz', blaz: 'ini' }
+
+var fs = require('fs')
+var ini = require('ini')
+
+fs.writeFileSync('/tmp/config-chain-class.json', JSON.stringify(jsonObj))
+fs.writeFileSync('/tmp/config-chain-class.ini', ini.stringify(iniObj))
+
+var http = require('http')
+var reqs = 0
+http.createServer(function (q, s) {
+ if (++reqs === 2) this.close()
+ if (q.url === '/json') {
+ // make sure that the requests come back from the server
+ // out of order. they should still be ordered properly
+ // in the resulting config object set.
+ setTimeout(function () {
+ s.setHeader('content-type', 'application/json')
+ s.end(JSON.stringify({
+ blaz: 'http',
+ http: true,
+ json: true
+ }))
+ }, 200)
+ } else {
+ s.setHeader('content-type', 'application/ini')
+ s.end(ini.stringify({
+ blaz: 'http',
+ http: true,
+ ini: true,
+ json: false
+ }))
+ }
+}).listen(1337)
+
+test('basic class test', function (t) {
+ var cc = new CC()
+ var expectlist =
+ [ { blaz: 'json', json: true },
+ { 'x.y.z': 'xyz', blaz: 'ini' },
+ { blaz: 'blzaa', env: 'myenv' },
+ { blaz: 'http', http: true, json: true },
+ { blaz: 'http', http: true, ini: true, json: false } ]
+
+ cc.addFile('/tmp/config-chain-class.json')
+ .addFile('/tmp/config-chain-class.ini')
+ .addEnv('foo_', env)
+ .addUrl('http://localhost:1337/json')
+ .addUrl('http://localhost:1337/ini')
+ .on('load', function () {
+ t.same(cc.list, expectlist)
+ t.same(cc.snapshot, { blaz: 'json',
+ json: true,
+ 'x.y.z': 'xyz',
+ env: 'myenv',
+ http: true,
+ ini: true })
+
+ cc.del('blaz', '/tmp/config-chain-class.json')
+ t.same(cc.snapshot, { blaz: 'ini',
+ json: true,
+ 'x.y.z': 'xyz',
+ env: 'myenv',
+ http: true,
+ ini: true })
+ cc.del('blaz')
+ t.same(cc.snapshot, { json: true,
+ 'x.y.z': 'xyz',
+ env: 'myenv',
+ http: true,
+ ini: true })
+ cc.shift()
+ t.same(cc.snapshot, { 'x.y.z': 'xyz',
+ env: 'myenv',
+ http: true,
+ json: true,
+ ini: true })
+ cc.shift()
+ t.same(cc.snapshot, { env: 'myenv',
+ http: true,
+ json: true,
+ ini: true })
+ cc.shift()
+ t.same(cc.snapshot, { http: true,
+ json: true,
+ ini: true })
+ cc.shift()
+ t.same(cc.snapshot, { http: true,
+ ini: true,
+ json: false })
+ cc.shift()
+ t.same(cc.snapshot, {})
+ t.end()
+ })
+})
diff -Nru nodejs-0.11.14/deps/npm/node_modules/config-chain/test/env.js nodejs-0.11.15/deps/npm/node_modules/config-chain/test/env.js
--- nodejs-0.11.14/deps/npm/node_modules/config-chain/test/env.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/config-chain/test/env.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,10 @@
+var cc = require('..')
+var assert = require('assert')
+
+assert.deepEqual({
+ hello: true
+}, cc.env('test_', {
+ 'test_hello': true,
+ 'ignore_this': 4,
+ 'ignore_test_this_too': []
+}))
diff -Nru nodejs-0.11.14/deps/npm/node_modules/config-chain/test/find-file.js nodejs-0.11.15/deps/npm/node_modules/config-chain/test/find-file.js
--- nodejs-0.11.14/deps/npm/node_modules/config-chain/test/find-file.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/config-chain/test/find-file.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,13 @@
+
+var fs = require('fs')
+ , assert = require('assert')
+ , objx = {
+ rand: Math.random()
+ }
+
+fs.writeFileSync('/tmp/random-test-config.json', JSON.stringify(objx))
+
+var cc = require('../')
+var path = cc.find('tmp/random-test-config.json')
+
+assert.equal(path, '/tmp/random-test-config.json')
\ No newline at end of file
diff -Nru nodejs-0.11.14/deps/npm/node_modules/config-chain/test/get.js nodejs-0.11.15/deps/npm/node_modules/config-chain/test/get.js
--- nodejs-0.11.14/deps/npm/node_modules/config-chain/test/get.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/config-chain/test/get.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,15 @@
+var cc = require("../");
+
+var chain = cc()
+ , name = "forFun";
+
+chain
+ .add({
+ __sample:"for fun only"
+ }, name)
+ .on("load", function() {
+ //It throw exception here
+ console.log(chain.get("__sample", name));
+ //But if I drop the name param, it run normally and return as expected: "for fun only"
+ //console.log(chain.get("__sample"));
+ });
diff -Nru nodejs-0.11.14/deps/npm/node_modules/config-chain/test/ignore-unfound-file.js nodejs-0.11.15/deps/npm/node_modules/config-chain/test/ignore-unfound-file.js
--- nodejs-0.11.14/deps/npm/node_modules/config-chain/test/ignore-unfound-file.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/config-chain/test/ignore-unfound-file.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,5 @@
+
+var cc = require('..')
+
+//should not throw
+cc(__dirname, 'non_existing_file')
diff -Nru nodejs-0.11.14/deps/npm/node_modules/config-chain/test/ini.js nodejs-0.11.15/deps/npm/node_modules/config-chain/test/ini.js
--- nodejs-0.11.14/deps/npm/node_modules/config-chain/test/ini.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/config-chain/test/ini.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,18 @@
+
+
+var cc =require('..')
+var INI = require('ini')
+var assert = require('assert')
+
+function test(obj) {
+
+ var _json, _ini
+ var json = cc.parse (_json = JSON.stringify(obj))
+ var ini = cc.parse (_ini = INI.stringify(obj))
+console.log(_ini, _json)
+ assert.deepEqual(json, ini)
+}
+
+
+test({hello: true})
+
diff -Nru nodejs-0.11.14/deps/npm/node_modules/config-chain/test/save.js nodejs-0.11.15/deps/npm/node_modules/config-chain/test/save.js
--- nodejs-0.11.14/deps/npm/node_modules/config-chain/test/save.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/config-chain/test/save.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,59 @@
+var CC = require('../index.js').ConfigChain
+var test = require('tap').test
+
+var f1 = '/tmp/f1.ini'
+var f2 = '/tmp/f2.json'
+
+var ini = require('ini')
+
+var f1data = {foo: {bar: 'baz'}, bloo: 'jaus'}
+var f2data = {oof: {rab: 'zab'}, oolb: 'suaj'}
+
+var fs = require('fs')
+
+fs.writeFileSync(f1, ini.stringify(f1data), 'utf8')
+fs.writeFileSync(f2, JSON.stringify(f2data), 'utf8')
+
+test('test saving and loading ini files', function (t) {
+ new CC()
+ .add({grelb:'blerg'}, 'opt')
+ .addFile(f1, 'ini', 'inifile')
+ .addFile(f2, 'json', 'jsonfile')
+ .on('load', function (cc) {
+
+ t.same(cc.snapshot, { grelb: 'blerg',
+ bloo: 'jaus',
+ foo: { bar: 'baz' },
+ oof: { rab: 'zab' },
+ oolb: 'suaj' })
+
+ t.same(cc.list, [ { grelb: 'blerg' },
+ { bloo: 'jaus', foo: { bar: 'baz' } },
+ { oof: { rab: 'zab' }, oolb: 'suaj' } ])
+
+ cc.set('grelb', 'brelg', 'opt')
+ .set('foo', 'zoo', 'inifile')
+ .set('oof', 'ooz', 'jsonfile')
+ .save('inifile')
+ .save('jsonfile')
+ .on('save', function () {
+ t.equal(fs.readFileSync(f1, 'utf8'),
+ "bloo = jaus\nfoo = zoo\n")
+ t.equal(fs.readFileSync(f2, 'utf8'),
+ "{\"oof\":\"ooz\",\"oolb\":\"suaj\"}")
+
+ t.same(cc.snapshot, { grelb: 'brelg',
+ bloo: 'jaus',
+ foo: 'zoo',
+ oof: 'ooz',
+ oolb: 'suaj' })
+
+ t.same(cc.list, [ { grelb: 'brelg' },
+ { bloo: 'jaus', foo: 'zoo' },
+ { oof: 'ooz', oolb: 'suaj' } ])
+
+ t.pass('ok')
+ t.end()
+ })
+ })
+})
diff -Nru nodejs-0.11.14/deps/npm/node_modules/dezalgo/dezalgo.js nodejs-0.11.15/deps/npm/node_modules/dezalgo/dezalgo.js
--- nodejs-0.11.14/deps/npm/node_modules/dezalgo/dezalgo.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/dezalgo/dezalgo.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,4 +1,5 @@
-module.exports = dezalgo
+var wrappy = require('wrappy')
+module.exports = wrappy(dezalgo)
var asap = require('asap')
diff -Nru nodejs-0.11.14/deps/npm/node_modules/dezalgo/node_modules/asap/package.json nodejs-0.11.15/deps/npm/node_modules/dezalgo/node_modules/asap/package.json
--- nodejs-0.11.14/deps/npm/node_modules/dezalgo/node_modules/asap/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/dezalgo/node_modules/asap/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -21,7 +21,7 @@
"shasum": "b2a45da5fdfa20b0496fc3768cc27c12fa916a7d",
"tarball": "http://registry.npmjs.org/asap/-/asap-1.0.0.tgz"
},
- "_from": "asap@>=1.0.0-0 <2.0.0-0",
+ "_from": "asap@>=1.0.0 <2.0.0",
"_npmVersion": "1.2.15",
"_npmUser": {
"name": "kriskowal",
diff -Nru nodejs-0.11.14/deps/npm/node_modules/dezalgo/package.json nodejs-0.11.15/deps/npm/node_modules/dezalgo/package.json
--- nodejs-0.11.14/deps/npm/node_modules/dezalgo/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/dezalgo/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -1,13 +1,14 @@
{
"name": "dezalgo",
- "version": "1.0.0",
+ "version": "1.0.1",
"description": "Contain async insanity so that the dark pony lord doesn't eat souls",
"main": "dezalgo.js",
"directories": {
"test": "test"
},
"dependencies": {
- "asap": "^1.0.0"
+ "asap": "^1.0.0",
+ "wrappy": "1"
},
"devDependencies": {
"tap": "^0.4.11"
@@ -42,11 +43,12 @@
"url": "https://github.com/npm/dezalgo/issues"
},
"homepage": "https://github.com/npm/dezalgo",
- "gitHead": "b10ea8ae0096d0e60c1acaa88d5334a9b372e4b0",
- "_id": "dezalgo@1.0.0",
- "_shasum": "050bb723f18b5617b309f26c2dc8fe6f2573b6fc",
- "_from": "dezalgo@1.0.0",
- "_npmVersion": "1.4.18",
+ "gitHead": "0a5eee75c179611f8b67f663015d68bb517e57d2",
+ "_id": "dezalgo@1.0.1",
+ "_shasum": "12bde135060807900d5a7aebb607c2abb7c76937",
+ "_from": "dezalgo@latest",
+ "_npmVersion": "2.0.0",
+ "_nodeVersion": "0.10.31",
"_npmUser": {
"name": "isaacs",
"email": "i@izs.me"
@@ -58,9 +60,8 @@
}
],
"dist": {
- "shasum": "050bb723f18b5617b309f26c2dc8fe6f2573b6fc",
- "tarball": "http://registry.npmjs.org/dezalgo/-/dezalgo-1.0.0.tgz"
+ "shasum": "12bde135060807900d5a7aebb607c2abb7c76937",
+ "tarball": "http://registry.npmjs.org/dezalgo/-/dezalgo-1.0.1.tgz"
},
- "_resolved": "https://registry.npmjs.org/dezalgo/-/dezalgo-1.0.0.tgz",
- "readme": "ERROR: No README data found!"
+ "_resolved": "https://registry.npmjs.org/dezalgo/-/dezalgo-1.0.1.tgz"
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/dezalgo/test/basic.js nodejs-0.11.15/deps/npm/node_modules/dezalgo/test/basic.js
--- nodejs-0.11.14/deps/npm/node_modules/dezalgo/test/basic.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/dezalgo/test/basic.js 2015-01-20 21:22:17.000000000 +0000
@@ -4,15 +4,19 @@
test('the dark pony', function(t) {
var n = 0
- function foo(cb) {
+ function foo(i, cb) {
cb = dz(cb)
- if (++n % 2) cb()
- else process.nextTick(cb)
+ if (++n % 2) cb(true, i)
+ else process.nextTick(cb.bind(null, false, i))
}
var called = 0
+ var order = [0, 2, 4, 6, 8, 1, 3, 5, 7, 9]
+ var o = 0
for (var i = 0; i < 10; i++) {
- foo(function() {
+ foo(i, function(cached, i) {
+ t.equal(i, order[o++])
+ t.equal(i % 2, cached ? 0 : 1)
called++
})
t.equal(called, 0)
diff -Nru nodejs-0.11.14/deps/npm/node_modules/fstream-npm/fstream-npm.js nodejs-0.11.15/deps/npm/node_modules/fstream-npm/fstream-npm.js
--- nodejs-0.11.14/deps/npm/node_modules/fstream-npm/fstream-npm.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/fstream-npm/fstream-npm.js 2015-01-20 21:22:17.000000000 +0000
@@ -93,6 +93,12 @@
// readme files should never be ignored.
if (entry.match(/^readme(\.[^\.]*)$/i)) return true
+ // license files should never be ignored.
+ if (entry.match(/^(license|licence)(\.[^\.]*)?$/i)) return true
+
+ // changelogs should never be ignored.
+ if (entry.match(/^(changes|changelog|history)(\.[^\.]*)?$/i)) return true
+
// special rules. see below.
if (entry === "node_modules" && this.packageRoot) return true
diff -Nru nodejs-0.11.14/deps/npm/node_modules/fstream-npm/node_modules/fstream-ignore/package.json nodejs-0.11.15/deps/npm/node_modules/fstream-npm/node_modules/fstream-ignore/package.json
--- nodejs-0.11.14/deps/npm/node_modules/fstream-npm/node_modules/fstream-ignore/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/fstream-npm/node_modules/fstream-ignore/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -26,8 +26,6 @@
"mkdirp": ""
},
"license": "ISC",
- "readme": "# fstream-ignore\n\nA fstream DirReader that filters out files that match globs in `.ignore`\nfiles throughout the tree, like how git ignores files based on a\n`.gitignore` file.\n\nHere's an example:\n\n```javascript\nvar Ignore = require(\"fstream-ignore\")\nIgnore({ path: __dirname\n , ignoreFiles: [\".ignore\", \".gitignore\"]\n })\n .on(\"child\", function (c) {\n console.error(c.path.substr(c.root.path.length + 1))\n })\n .pipe(tar.Pack())\n .pipe(fs.createWriteStream(\"foo.tar\"))\n```\n\nThis will tar up the files in __dirname into `foo.tar`, ignoring\nanything matched by the globs in any .iginore or .gitignore file.\n",
- "readmeFilename": "README.md",
"gitHead": "290f2b621fa4f8fe3eec97307d22527fa2065375",
"bugs": {
"url": "https://github.com/isaacs/fstream-ignore/issues"
@@ -35,5 +33,23 @@
"homepage": "https://github.com/isaacs/fstream-ignore",
"_id": "fstream-ignore@1.0.1",
"_shasum": "153df36c4fa2cb006fb915dc71ac9d75f6a17c82",
- "_from": "fstream-ignore@^1.0.0"
+ "_from": "fstream-ignore@>=1.0.0 <2.0.0",
+ "_npmVersion": "1.4.22",
+ "_npmUser": {
+ "name": "isaacs",
+ "email": "i@izs.me"
+ },
+ "maintainers": [
+ {
+ "name": "isaacs",
+ "email": "i@izs.me"
+ }
+ ],
+ "dist": {
+ "shasum": "153df36c4fa2cb006fb915dc71ac9d75f6a17c82",
+ "tarball": "http://registry.npmjs.org/fstream-ignore/-/fstream-ignore-1.0.1.tgz"
+ },
+ "directories": {},
+ "_resolved": "https://registry.npmjs.org/fstream-ignore/-/fstream-ignore-1.0.1.tgz",
+ "readme": "ERROR: No README data found!"
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/fstream-npm/package.json nodejs-0.11.15/deps/npm/node_modules/fstream-npm/package.json
--- nodejs-0.11.14/deps/npm/node_modules/fstream-npm/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/fstream-npm/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -6,7 +6,7 @@
},
"name": "fstream-npm",
"description": "fstream class for creating npm packages",
- "version": "1.0.0",
+ "version": "1.0.1",
"repository": {
"type": "git",
"url": "git://github.com/isaacs/fstream-npm.git"
@@ -17,15 +17,31 @@
"inherits": "2"
},
"license": "ISC",
- "readme": "# fstream-npm\n\nThis is an fstream DirReader class that will read a directory and filter\nthings according to the semantics of what goes in an npm package.\n\nFor example:\n\n```javascript\n// This will print out all the files that would be included\n// by 'npm publish' or 'npm install' of this directory.\n\nvar FN = require(\"fstream-npm\")\nFN({ path: \"./\" })\n .on(\"child\", function (e) {\n console.error(e.path.substr(e.root.path.length + 1))\n })\n```\n\n",
- "readmeFilename": "README.md",
- "gitHead": "807e0a8653ab793dc2e1b3b798e6256d09f972e7",
+ "gitHead": "4a95e1903f93dc122320349bb55e367ddd08ad6b",
"bugs": {
"url": "https://github.com/isaacs/fstream-npm/issues"
},
"homepage": "https://github.com/isaacs/fstream-npm",
- "_id": "fstream-npm@1.0.0",
+ "_id": "fstream-npm@1.0.1",
"scripts": {},
- "_shasum": "0262c95c771d393e7cf59fcfeabce621703f3d27",
- "_from": "fstream-npm@latest"
+ "_shasum": "1e35c77f0fa24f5d6367e6d447ae7d6ddb482db2",
+ "_from": "fstream-npm@>=1.0.1 <1.1.0",
+ "_npmVersion": "2.1.3",
+ "_nodeVersion": "0.10.31",
+ "_npmUser": {
+ "name": "isaacs",
+ "email": "i@izs.me"
+ },
+ "maintainers": [
+ {
+ "name": "isaacs",
+ "email": "i@izs.me"
+ }
+ ],
+ "dist": {
+ "shasum": "1e35c77f0fa24f5d6367e6d447ae7d6ddb482db2",
+ "tarball": "http://registry.npmjs.org/fstream-npm/-/fstream-npm-1.0.1.tgz"
+ },
+ "directories": {},
+ "_resolved": "https://registry.npmjs.org/fstream-npm/-/fstream-npm-1.0.1.tgz"
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/fs-write-stream-atomic/index.js nodejs-0.11.15/deps/npm/node_modules/fs-write-stream-atomic/index.js
--- nodejs-0.11.14/deps/npm/node_modules/fs-write-stream-atomic/index.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/fs-write-stream-atomic/index.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,96 @@
+var fs = require('graceful-fs')
+var util = require('util')
+var crypto = require('crypto')
+
+function md5hex () {
+ var hash = crypto.createHash('md5')
+ for (var ii=0; ii=1.0.2 <1.1.0",
+ "_npmVersion": "2.1.0",
+ "_nodeVersion": "0.10.31",
+ "_npmUser": {
+ "name": "isaacs",
+ "email": "i@izs.me"
+ },
+ "maintainers": [
+ {
+ "name": "isaacs",
+ "email": "i@izs.me"
+ }
+ ],
+ "dist": {
+ "shasum": "fe0c6cec75256072b2fef8180d97e309fe3f5efb",
+ "tarball": "http://registry.npmjs.org/fs-write-stream-atomic/-/fs-write-stream-atomic-1.0.2.tgz"
+ },
+ "_resolved": "https://registry.npmjs.org/fs-write-stream-atomic/-/fs-write-stream-atomic-1.0.2.tgz"
+}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/fs-write-stream-atomic/README.md nodejs-0.11.15/deps/npm/node_modules/fs-write-stream-atomic/README.md
--- nodejs-0.11.14/deps/npm/node_modules/fs-write-stream-atomic/README.md 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/fs-write-stream-atomic/README.md 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,35 @@
+# fs-write-stream-atomic
+
+Like `fs.createWriteStream(...)`, but atomic.
+
+Writes to a tmp file and does an atomic `fs.rename` to move it into
+place when it's done.
+
+First rule of debugging: **It's always a race condition.**
+
+## USAGE
+
+```javascript
+var fsWriteStreamAtomic = require('fs-write-stream-atomic')
+// options are optional.
+var write = fsWriteStreamAtomic('output.txt', options)
+var read = fs.createReadStream('input.txt')
+read.pipe(write)
+
+// When the write stream emits a 'finish' or 'close' event,
+// you can be sure that it is moved into place, and contains
+// all the bytes that were written to it, even if something else
+// was writing to `output.txt` at the same time.
+```
+
+### `fsWriteStreamAtomic(filename, [options])`
+
+* `filename` {String} The file we want to write to
+* `options` {Object}
+ * `chown` {Object} User and group to set ownership after write
+ * `uid` {Number}
+ * `gid` {Number}
+ * `encoding` {String} default = 'utf8'
+ * `mode` {Number} default = `0666`
+ * `flags` {String} default = `'w'`
+
diff -Nru nodejs-0.11.14/deps/npm/node_modules/fs-write-stream-atomic/test/basic.js nodejs-0.11.15/deps/npm/node_modules/fs-write-stream-atomic/test/basic.js
--- nodejs-0.11.14/deps/npm/node_modules/fs-write-stream-atomic/test/basic.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/fs-write-stream-atomic/test/basic.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,89 @@
+var test = require('tap').test
+var writeStream = require('../index.js')
+var fs = require('fs')
+var path = require('path')
+
+test('basic', function (t) {
+ // open 10 write streams to the same file.
+ // then write to each of them, and to the target
+ // and verify at the end that each of them does their thing
+ var target = path.resolve(__dirname, 'test.txt')
+ var n = 10
+
+ var streams = []
+ for (var i = 0; i < n; i++) {
+ var s = writeStream(target)
+ s.on('finish', verifier('finish'))
+ s.on('close', verifier('close'))
+ streams.push(s)
+ }
+
+ var verifierCalled = 0
+ function verifier (ev) { return function () {
+ if (ev === 'close')
+ t.equal(this.__emittedFinish, true)
+ else {
+ this.__emittedFinish = true
+ t.equal(ev, 'finish')
+ }
+
+ // make sure that one of the atomic streams won.
+ var res = fs.readFileSync(target, 'utf8')
+ var lines = res.trim().split(/\n/)
+ lines.forEach(function (line) {
+ var first = lines[0].match(/\d+$/)[0]
+ var cur = line.match(/\d+$/)[0]
+ t.equal(cur, first)
+ })
+
+ var resExpr = /^first write \d+\nsecond write \d+\nthird write \d+\nfinal write \d+\n$/
+ t.similar(res, resExpr)
+
+ // should be called once for each close, and each finish
+ if (++verifierCalled === n * 2) {
+ t.end()
+ }
+ }}
+
+ // now write something to each stream.
+ streams.forEach(function (stream, i) {
+ stream.write('first write ' + i + '\n')
+ })
+
+ // wait a sec for those writes to go out.
+ setTimeout(function () {
+ // write something else to the target.
+ fs.writeFileSync(target, 'brutality!\n')
+
+ // write some more stuff.
+ streams.forEach(function (stream, i) {
+ stream.write('second write ' + i + '\n')
+ })
+
+ setTimeout(function () {
+ // Oops! Deleted the file!
+ fs.unlinkSync(target)
+
+ // write some more stuff.
+ streams.forEach(function (stream, i) {
+ stream.write('third write ' + i + '\n')
+ })
+
+ setTimeout(function () {
+ fs.writeFileSync(target, 'brutality TWO!\n')
+ streams.forEach(function (stream, i) {
+ stream.end('final write ' + i + '\n')
+ })
+ }, 50)
+ }, 50)
+ }, 50)
+})
+
+test('cleanup', function (t) {
+ fs.readdirSync(__dirname).filter(function (f) {
+ return f.match(/^test.txt/)
+ }).forEach(function (file) {
+ fs.unlinkSync(path.resolve(__dirname, file))
+ })
+ t.end()
+})
diff -Nru nodejs-0.11.14/deps/npm/node_modules/glob/glob.js nodejs-0.11.15/deps/npm/node_modules/glob/glob.js
--- nodejs-0.11.14/deps/npm/node_modules/glob/glob.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/glob/glob.js 2015-01-20 21:22:17.000000000 +0000
@@ -36,10 +36,8 @@
module.exports = glob
-var fs
-try { fs = require("graceful-fs") } catch (e) { fs = require("fs") }
-
-var minimatch = require("minimatch")
+var fs = require("graceful-fs")
+, minimatch = require("minimatch")
, Minimatch = minimatch.Minimatch
, inherits = require("inherits")
, EE = require("events").EventEmitter
Binary files /tmp/Mhog4P8ZHE/nodejs-0.11.14/deps/npm/node_modules/glob/oh-my-glob.gif and /tmp/Z_ez7cGlqC/nodejs-0.11.15/deps/npm/node_modules/glob/oh-my-glob.gif differ
diff -Nru nodejs-0.11.14/deps/npm/node_modules/glob/package.json nodejs-0.11.15/deps/npm/node_modules/glob/package.json
--- nodejs-0.11.14/deps/npm/node_modules/glob/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/glob/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -6,7 +6,7 @@
},
"name": "glob",
"description": "a little globber",
- "version": "4.0.5",
+ "version": "4.0.6",
"repository": {
"type": "git",
"url": "git://github.com/isaacs/node-glob.git"
@@ -15,14 +15,11 @@
"engines": {
"node": "*"
},
- "optionalDependencies": {
- "graceful-fs": "^3.0.2"
- },
"dependencies": {
+ "graceful-fs": "^3.0.2",
"inherits": "2",
"minimatch": "^1.0.0",
- "once": "^1.3.0",
- "graceful-fs": "^3.0.2"
+ "once": "^1.3.0"
},
"devDependencies": {
"tap": "~0.4.0",
@@ -34,15 +31,16 @@
"test-regen": "TEST_REGEN=1 node test/00-setup.js"
},
"license": "ISC",
- "gitHead": "a7d85acf4e89fa26d17396ab022ef98fbe1f8a4b",
+ "gitHead": "6825c425e738eaffa315d8cdb1a4c3255ededcb3",
"bugs": {
"url": "https://github.com/isaacs/node-glob/issues"
},
"homepage": "https://github.com/isaacs/node-glob",
- "_id": "glob@4.0.5",
- "_shasum": "95e42c9efdb3ab1f4788fd7793dfded4a3378063",
- "_from": "glob@latest",
- "_npmVersion": "1.4.21",
+ "_id": "glob@4.0.6",
+ "_shasum": "695c50bdd4e2fb5c5d370b091f388d3707e291a7",
+ "_from": "glob@>=4.0.6 <5.0.0",
+ "_npmVersion": "2.0.0",
+ "_nodeVersion": "0.10.31",
"_npmUser": {
"name": "isaacs",
"email": "i@izs.me"
@@ -54,9 +52,10 @@
}
],
"dist": {
- "shasum": "95e42c9efdb3ab1f4788fd7793dfded4a3378063",
- "tarball": "http://registry.npmjs.org/glob/-/glob-4.0.5.tgz"
+ "shasum": "695c50bdd4e2fb5c5d370b091f388d3707e291a7",
+ "tarball": "http://registry.npmjs.org/glob/-/glob-4.0.6.tgz"
},
"directories": {},
- "_resolved": "https://registry.npmjs.org/glob/-/glob-4.0.5.tgz"
+ "_resolved": "https://registry.npmjs.org/glob/-/glob-4.0.6.tgz",
+ "readme": "ERROR: No README data found!"
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/glob/README.md nodejs-0.11.15/deps/npm/node_modules/glob/README.md
--- nodejs-0.11.14/deps/npm/node_modules/glob/README.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/glob/README.md 2015-01-20 21:22:17.000000000 +0000
@@ -5,16 +5,7 @@
This is a glob implementation in JavaScript. It uses the `minimatch`
library to do its matching.
-## Attention: node-glob users!
-
-The API has changed dramatically between 2.x and 3.x. This library is
-now 100% JavaScript, and the integer flags have been replaced with an
-options object.
-
-Also, there's an event emitter class, proper tests, and all the other
-things you've come to expect from node modules.
-
-And best of all, no compilation!
+![](oh-my-glob.gif)
## Usage
diff -Nru nodejs-0.11.14/deps/npm/node_modules/glob/test/negation-test.js nodejs-0.11.15/deps/npm/node_modules/glob/test/negation-test.js
--- nodejs-0.11.14/deps/npm/node_modules/glob/test/negation-test.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/glob/test/negation-test.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,16 @@
+// Negation test
+// Show that glob respect's minimatch's negate flag
+
+var glob = require('../glob.js')
+var test = require('tap').test
+
+test('glob respects minimatch negate flag when activated with leading !', function(t) {
+ var expect = ["abcdef/g", "abcfed/g", "c/d", "cb/e", "symlink/a"]
+ var results = glob("!b**/*", {cwd: 'a'}, function (er, results) {
+ if (er)
+ throw er
+
+ t.same(results, expect)
+ t.end()
+ });
+});
diff -Nru nodejs-0.11.14/deps/npm/node_modules/graceful-fs/package.json nodejs-0.11.15/deps/npm/node_modules/graceful-fs/package.json
--- nodejs-0.11.14/deps/npm/node_modules/graceful-fs/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/graceful-fs/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -6,7 +6,7 @@
},
"name": "graceful-fs",
"description": "A drop-in replacement for fs, making various improvements.",
- "version": "3.0.2",
+ "version": "3.0.4",
"repository": {
"type": "git",
"url": "git://github.com/isaacs/node-graceful-fs.git"
@@ -38,15 +38,20 @@
"EACCESS"
],
"license": "BSD",
- "gitHead": "0caa11544c0c9001db78bf593cf0c5805d149a41",
+ "devDependencies": {
+ "mkdirp": "^0.5.0",
+ "rimraf": "^2.2.8",
+ "tap": "^0.4.13"
+ },
+ "gitHead": "d3fd03247ccc4fa8a3eee399307fd266c70efb06",
"bugs": {
"url": "https://github.com/isaacs/node-graceful-fs/issues"
},
"homepage": "https://github.com/isaacs/node-graceful-fs",
- "_id": "graceful-fs@3.0.2",
- "_shasum": "2cb5bf7f742bea8ad47c754caeee032b7e71a577",
- "_from": "graceful-fs@~3.0.0",
- "_npmVersion": "1.4.14",
+ "_id": "graceful-fs@3.0.4",
+ "_shasum": "a0306d9b0940e0fc512d33b5df1014e88e0637a3",
+ "_from": "graceful-fs@>=3.0.4 <4.0.0",
+ "_npmVersion": "1.4.28",
"_npmUser": {
"name": "isaacs",
"email": "i@izs.me"
@@ -58,8 +63,9 @@
}
],
"dist": {
- "shasum": "2cb5bf7f742bea8ad47c754caeee032b7e71a577",
- "tarball": "http://registry.npmjs.org/graceful-fs/-/graceful-fs-3.0.2.tgz"
+ "shasum": "a0306d9b0940e0fc512d33b5df1014e88e0637a3",
+ "tarball": "http://registry.npmjs.org/graceful-fs/-/graceful-fs-3.0.4.tgz"
},
- "_resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-3.0.2.tgz"
+ "_resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-3.0.4.tgz",
+ "readme": "ERROR: No README data found!"
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/graceful-fs/test/max-open.js nodejs-0.11.15/deps/npm/node_modules/graceful-fs/test/max-open.js
--- nodejs-0.11.14/deps/npm/node_modules/graceful-fs/test/max-open.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/graceful-fs/test/max-open.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,69 @@
+var test = require('tap').test
+var fs = require('../')
+
+test('open lots of stuff', function (t) {
+ // Get around EBADF from libuv by making sure that stderr is opened
+ // Otherwise Darwin will refuse to give us a FD for stderr!
+ process.stderr.write('')
+
+ // How many parallel open()'s to do
+ var n = 1024
+ var opens = 0
+ var fds = []
+ var going = true
+ var closing = false
+ var doneCalled = 0
+
+ for (var i = 0; i < n; i++) {
+ go()
+ }
+
+ function go() {
+ opens++
+ fs.open(__filename, 'r', function (er, fd) {
+ if (er) throw er
+ fds.push(fd)
+ if (going) go()
+ })
+ }
+
+ // should hit ulimit pretty fast
+ setTimeout(function () {
+ going = false
+ t.equal(opens - fds.length, n)
+ done()
+ }, 100)
+
+
+ function done () {
+ if (closing) return
+ doneCalled++
+
+ if (fds.length === 0) {
+ //console.error('done called %d times', doneCalled)
+ // First because of the timeout
+ // Then to close the fd's opened afterwards
+ // Then this time, to complete.
+ // Might take multiple passes, depending on CPU speed
+ // and ulimit, but at least 3 in every case.
+ t.ok(doneCalled >= 3)
+ return t.end()
+ }
+
+ closing = true
+ setTimeout(function () {
+ // console.error('do closing again')
+ closing = false
+ done()
+ }, 100)
+
+ // console.error('closing time')
+ var closes = fds.slice(0)
+ fds.length = 0
+ closes.forEach(function (fd) {
+ fs.close(fd, function (er) {
+ if (er) throw er
+ })
+ })
+ }
+})
diff -Nru nodejs-0.11.14/deps/npm/node_modules/graceful-fs/test/readdir-sort.js nodejs-0.11.15/deps/npm/node_modules/graceful-fs/test/readdir-sort.js
--- nodejs-0.11.14/deps/npm/node_modules/graceful-fs/test/readdir-sort.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/graceful-fs/test/readdir-sort.js 2015-01-20 21:22:17.000000000 +0000
@@ -14,7 +14,6 @@
g.readdir("whatevers", function (er, files) {
if (er)
throw er
- console.error(files)
t.same(files, [ "a", "b", "z" ])
t.end()
})
diff -Nru nodejs-0.11.14/deps/npm/node_modules/graceful-fs/test/write-then-read.js nodejs-0.11.15/deps/npm/node_modules/graceful-fs/test/write-then-read.js
--- nodejs-0.11.14/deps/npm/node_modules/graceful-fs/test/write-then-read.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/graceful-fs/test/write-then-read.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,45 @@
+var fs = require('../');
+var rimraf = require('rimraf');
+var mkdirp = require('mkdirp');
+var test = require('tap').test;
+var p = require('path').resolve(__dirname, 'files');
+
+// Make sure to reserve the stderr fd
+process.stderr.write('');
+
+var num = 4097;
+var paths = new Array(num);
+
+test('make files', function (t) {
+ rimraf.sync(p);
+ mkdirp.sync(p);
+
+ for (var i = 0; i < num; ++i) {
+ paths[i] = 'files/file-' + i;
+ fs.writeFileSync(paths[i], 'content');
+ }
+
+ t.end();
+})
+
+test('read files', function (t) {
+ // now read them
+ var done = 0;
+ for (var i = 0; i < num; ++i) {
+ fs.readFile(paths[i], function(err, data) {
+ if (err)
+ throw err;
+
+ ++done;
+ if (done === num) {
+ t.pass('success');
+ t.end()
+ }
+ });
+ }
+});
+
+test('cleanup', function (t) {
+ rimraf.sync(p);
+ t.end();
+});
diff -Nru nodejs-0.11.14/deps/npm/node_modules/inflight/.eslintrc nodejs-0.11.15/deps/npm/node_modules/inflight/.eslintrc
--- nodejs-0.11.14/deps/npm/node_modules/inflight/.eslintrc 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/inflight/.eslintrc 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,17 @@
+{
+ "env" : {
+ "node" : true
+ },
+ "rules" : {
+ "semi": [2, "never"],
+ "strict": 0,
+ "quotes": [1, "single", "avoid-escape"],
+ "no-use-before-define": 0,
+ "curly": 0,
+ "no-underscore-dangle": 0,
+ "no-lonely-if": 1,
+ "no-unused-vars": [2, {"vars" : "all", "args" : "after-used"}],
+ "no-mixed-requires": 0,
+ "space-infix-ops": 0
+ }
+}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/inflight/inflight.js nodejs-0.11.15/deps/npm/node_modules/inflight/inflight.js
--- nodejs-0.11.14/deps/npm/node_modules/inflight/inflight.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/inflight/inflight.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,8 +1,9 @@
-module.exports = inflight
-
+var wrappy = require('wrappy')
var reqs = Object.create(null)
var once = require('once')
+module.exports = wrappy(inflight)
+
function inflight (key, cb) {
if (reqs[key]) {
reqs[key].push(cb)
@@ -13,13 +14,31 @@
}
}
-function makeres(key) {
- return once(res)
- function res(error, data) {
+function makeres (key) {
+ return once(function RES () {
var cbs = reqs[key]
- delete reqs[key]
- cbs.forEach(function(cb) {
- cb(error, data)
- })
- }
+ var len = cbs.length
+ var args = slice(arguments)
+ for (var i = 0; i < len; i++) {
+ cbs[i].apply(null, args)
+ }
+ if (cbs.length > len) {
+ // added more in the interim.
+ // de-zalgo, just in case, but don't call again.
+ cbs.splice(0, len)
+ process.nextTick(function () {
+ RES.apply(null, args)
+ })
+ } else {
+ delete reqs[key]
+ }
+ })
+}
+
+function slice (args) {
+ var length = args.length
+ var array = []
+
+ for (var i = 0; i < length; i++) array[i] = args[i]
+ return array
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/inflight/package.json nodejs-0.11.15/deps/npm/node_modules/inflight/package.json
--- nodejs-0.11.14/deps/npm/node_modules/inflight/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/inflight/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -1,10 +1,11 @@
{
"name": "inflight",
- "version": "1.0.1",
+ "version": "1.0.4",
"description": "Add callbacks to requests in flight to avoid async duplication",
"main": "inflight.js",
"dependencies": {
- "once": "^1.3.0"
+ "once": "^1.3.0",
+ "wrappy": "1"
},
"devDependencies": {
"tap": "^0.4.10"
@@ -26,25 +27,10 @@
},
"homepage": "https://github.com/isaacs/inflight",
"license": "ISC",
- "_id": "inflight@1.0.1",
- "_shasum": "01f6911821535243c790ac0f998f54e9023ffb6f",
- "_from": "inflight@~1.0.1",
- "_npmVersion": "1.4.9",
- "_npmUser": {
- "name": "isaacs",
- "email": "i@izs.me"
- },
- "maintainers": [
- {
- "name": "isaacs",
- "email": "i@izs.me"
- }
- ],
- "dist": {
- "shasum": "01f6911821535243c790ac0f998f54e9023ffb6f",
- "tarball": "http://registry.npmjs.org/inflight/-/inflight-1.0.1.tgz"
- },
- "directories": {},
- "_resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.1.tgz",
- "readme": "ERROR: No README data found!"
+ "readme": "# inflight\n\nAdd callbacks to requests in flight to avoid async duplication\n\n## USAGE\n\n```javascript\nvar inflight = require('inflight')\n\n// some request that does some stuff\nfunction req(key, callback) {\n // key is any random string. like a url or filename or whatever.\n //\n // will return either a falsey value, indicating that the\n // request for this key is already in flight, or a new callback\n // which when called will call all callbacks passed to inflightk\n // with the same key\n callback = inflight(key, callback)\n\n // If we got a falsey value back, then there's already a req going\n if (!callback) return\n\n // this is where you'd fetch the url or whatever\n // callback is also once()-ified, so it can safely be assigned\n // to multiple events etc. First call wins.\n setTimeout(function() {\n callback(null, key)\n }, 100)\n}\n\n// only assigns a single setTimeout\n// when it dings, all cbs get called\nreq('foo', cb1)\nreq('foo', cb2)\nreq('foo', cb3)\nreq('foo', cb4)\n```\n",
+ "readmeFilename": "README.md",
+ "gitHead": "c7b5531d572a867064d4a1da9e013e8910b7d1ba",
+ "_id": "inflight@1.0.4",
+ "_shasum": "6cbb4521ebd51ce0ec0a936bfd7657ef7e9b172a",
+ "_from": "inflight@>=1.0.4 <1.1.0"
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/inflight/test.js nodejs-0.11.15/deps/npm/node_modules/inflight/test.js
--- nodejs-0.11.14/deps/npm/node_modules/inflight/test.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/inflight/test.js 2015-01-20 21:22:17.000000000 +0000
@@ -31,3 +31,67 @@
t.notOk(b, 'second should get falsey inflight response')
})
+
+test('timing', function (t) {
+ var expect = [
+ 'method one',
+ 'start one',
+ 'end one',
+ 'two',
+ 'tick',
+ 'three'
+ ]
+ var i = 0
+
+ function log (m) {
+ t.equal(m, expect[i], m + ' === ' + expect[i])
+ ++i
+ if (i === expect.length)
+ t.end()
+ }
+
+ function method (name, cb) {
+ log('method ' + name)
+ process.nextTick(cb)
+ }
+
+ var one = inf('foo', function () {
+ log('start one')
+ var three = inf('foo', function () {
+ log('three')
+ })
+ if (three) method('three', three)
+ log('end one')
+ })
+
+ method('one', one)
+
+ var two = inf('foo', function () {
+ log('two')
+ })
+ if (two) method('one', two)
+
+ process.nextTick(log.bind(null, 'tick'))
+})
+
+test('parameters', function (t) {
+ t.plan(8)
+
+ var a = inf('key', function (first, second, third) {
+ t.equal(first, 1)
+ t.equal(second, 2)
+ t.equal(third, 3)
+ })
+ t.ok(a, 'first returned cb function')
+
+ var b = inf('key', function (first, second, third) {
+ t.equal(first, 1)
+ t.equal(second, 2)
+ t.equal(third, 3)
+ })
+ t.notOk(b, 'second should get falsey inflight response')
+
+ setTimeout(function () {
+ a(1, 2, 3)
+ })
+})
diff -Nru nodejs-0.11.14/deps/npm/node_modules/inherits/package.json nodejs-0.11.15/deps/npm/node_modules/inherits/package.json
--- nodejs-0.11.14/deps/npm/node_modules/inherits/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/inherits/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -28,5 +28,24 @@
"url": "https://github.com/isaacs/inherits/issues"
},
"_id": "inherits@2.0.1",
- "_from": "inherits@"
+ "dist": {
+ "shasum": "b17d08d326b4423e568eff719f91b0b1cbdf69f1",
+ "tarball": "http://registry.npmjs.org/inherits/-/inherits-2.0.1.tgz"
+ },
+ "_from": "inherits@latest",
+ "_npmVersion": "1.3.8",
+ "_npmUser": {
+ "name": "isaacs",
+ "email": "i@izs.me"
+ },
+ "maintainers": [
+ {
+ "name": "isaacs",
+ "email": "i@izs.me"
+ }
+ ],
+ "directories": {},
+ "_shasum": "b17d08d326b4423e568eff719f91b0b1cbdf69f1",
+ "_resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.1.tgz",
+ "homepage": "https://github.com/isaacs/inherits"
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/ini/ini.js nodejs-0.11.15/deps/npm/node_modules/ini/ini.js
--- nodejs-0.11.14/deps/npm/node_modules/ini/ini.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/ini/ini.js 2015-01-20 21:22:17.000000000 +0000
@@ -7,31 +7,47 @@
var eol = process.platform === "win32" ? "\r\n" : "\n"
-function encode (obj, section) {
+function encode (obj, opt) {
var children = []
, out = ""
+ if (typeof opt === "string") {
+ opt = {
+ section: opt,
+ whitespace: false
+ }
+ } else {
+ opt = opt || {}
+ opt.whitespace = opt.whitespace === true
+ }
+
+ var separator = opt.whitespace ? " = " : "="
+
Object.keys(obj).forEach(function (k, _, __) {
var val = obj[k]
if (val && Array.isArray(val)) {
val.forEach(function(item) {
- out += safe(k + "[]") + "=" + safe(item) + "\n"
+ out += safe(k + "[]") + separator + safe(item) + "\n"
})
}
else if (val && typeof val === "object") {
children.push(k)
} else {
- out += safe(k) + "=" + safe(val) + eol
+ out += safe(k) + separator + safe(val) + eol
}
})
- if (section && out.length) {
- out = "[" + safe(section) + "]" + eol + out
+ if (opt.section && out.length) {
+ out = "[" + safe(opt.section) + "]" + eol + out
}
children.forEach(function (k, _, __) {
var nk = dotSplit(k).join('\\.')
- var child = encode(obj[k], (section ? section + "." : "") + nk)
+ var section = (opt.section ? opt.section + "." : "") + nk
+ var child = encode(obj[k], {
+ section: section,
+ whitespace: opt.whitespace
+ })
if (out.length && child.length) {
out += eol
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/ini/package.json nodejs-0.11.15/deps/npm/node_modules/ini/package.json
--- nodejs-0.11.14/deps/npm/node_modules/ini/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/ini/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -6,7 +6,7 @@
},
"name": "ini",
"description": "An ini encoder/decoder for node",
- "version": "1.2.1",
+ "version": "1.3.0",
"repository": {
"type": "git",
"url": "git://github.com/isaacs/ini.git"
@@ -22,15 +22,15 @@
"devDependencies": {
"tap": "~0.4.0"
},
- "gitHead": "13498ce1ba5a6a20cd77ed2b55de0e714786f70c",
+ "gitHead": "6c314944d0201f3199e1189aeb5687d0aaf1c575",
"bugs": {
"url": "https://github.com/isaacs/ini/issues"
},
"homepage": "https://github.com/isaacs/ini",
- "_id": "ini@1.2.1",
- "_shasum": "7f774e2f22752cd1dacbf9c63323df2a164ebca3",
- "_from": "ini@latest",
- "_npmVersion": "1.4.11",
+ "_id": "ini@1.3.0",
+ "_shasum": "625483e56c643a7721014c76604d3353f44bd429",
+ "_from": "ini@>=1.3.0 <2.0.0",
+ "_npmVersion": "2.0.0",
"_npmUser": {
"name": "isaacs",
"email": "i@izs.me"
@@ -42,9 +42,10 @@
}
],
"dist": {
- "shasum": "7f774e2f22752cd1dacbf9c63323df2a164ebca3",
- "tarball": "http://registry.npmjs.org/ini/-/ini-1.2.1.tgz"
+ "shasum": "625483e56c643a7721014c76604d3353f44bd429",
+ "tarball": "http://registry.npmjs.org/ini/-/ini-1.3.0.tgz"
},
"directories": {},
- "_resolved": "https://registry.npmjs.org/ini/-/ini-1.2.1.tgz"
+ "_resolved": "https://registry.npmjs.org/ini/-/ini-1.3.0.tgz",
+ "readme": "ERROR: No README data found!"
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/ini/README.md nodejs-0.11.15/deps/npm/node_modules/ini/README.md
--- nodejs-0.11.14/deps/npm/node_modules/ini/README.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/ini/README.md 2015-01-20 21:22:17.000000000 +0000
@@ -1,7 +1,7 @@
An ini format parser and serializer for node.
-Sections are treated as nested objects. Items before the first heading
-are saved on the object directly.
+Sections are treated as nested objects. Items before the first
+heading are saved on the object directly.
## Usage
@@ -34,40 +34,62 @@
delete config.paths.default.datadir
config.paths.default.array.push('fourth value')
- fs.writeFileSync('./config_modified.ini', ini.stringify(config, 'section'))
+ fs.writeFileSync('./config_modified.ini', ini.stringify(config, { section: 'section' }))
-This will result in a file called `config_modified.ini` being written to the filesystem with the following content:
+This will result in a file called `config_modified.ini` being written
+to the filesystem with the following content:
[section]
- scope = local
+ scope=local
[section.database]
- user = dbuser
- password = dbpassword
- database = use_another_database
+ user=dbuser
+ password=dbpassword
+ database=use_another_database
[section.paths.default]
- tmpdir = /tmp
- array[] = first value
- array[] = second value
- array[] = third value
- array[] = fourth value
+ tmpdir=/tmp
+ array[]=first value
+ array[]=second value
+ array[]=third value
+ array[]=fourth value
## API
### decode(inistring)
+
Decode the ini-style formatted `inistring` into a nested object.
### parse(inistring)
+
Alias for `decode(inistring)`
-### encode(object, [section])
-Encode the object `object` into an ini-style formatted string. If the optional parameter `section` is given, then all top-level properties of the object are put into this section and the `section`-string is prepended to all sub-sections, see the usage example above.
+### encode(object, [options])
-### stringify(object, [section])
-Alias for `encode(object, [section])`
+Encode the object `object` into an ini-style formatted string. If the
+optional parameter `section` is given, then all top-level properties
+of the object are put into this section and the `section`-string is
+prepended to all sub-sections, see the usage example above.
+
+The `options` object may contain the following:
+
+* `section` A string which will be the first `section` in the encoded
+ ini data. Defaults to none.
+* `whitespace` Boolean to specify whether to put whitespace around the
+ `=` character. By default, whitespace is omitted, to be friendly to
+ some persnickety old parsers that don't tolerate it well. But some
+ find that it's more human-readable and pretty with the whitespace.
+
+For backwards compatibility reasons, if a `string` options is passed
+in, then it is assumed to be the `section` value.
+
+### stringify(object, [options])
+
+Alias for `encode(object, [options])`
### safe(val)
-Escapes the string `val` such that it is safe to be used as a key or value in an ini-file. Basically escapes quotes. For example
+
+Escapes the string `val` such that it is safe to be used as a key or
+value in an ini-file. Basically escapes quotes. For example
ini.safe('"unsafe string"')
@@ -76,4 +98,5 @@
"\"unsafe string\""
### unsafe(val)
+
Unescapes the string `val`
diff -Nru nodejs-0.11.14/deps/npm/node_modules/ini/test/foo.js nodejs-0.11.15/deps/npm/node_modules/ini/test/foo.js
--- nodejs-0.11.14/deps/npm/node_modules/ini/test/foo.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/ini/test/foo.js 2015-01-20 21:22:17.000000000 +0000
@@ -59,6 +59,16 @@
}
}
}
+ , expectF = '[prefix.log]\n'
+ + 'type=file\n\n'
+ + '[prefix.log.level]\n'
+ + 'label=debug\n'
+ + 'value=10\n'
+ , expectG = '[log]\n'
+ + 'type = file\n\n'
+ + '[log.level]\n'
+ + 'label = debug\n'
+ + 'value = 10\n'
test("decode from file", function (t) {
var d = i.decode(data)
@@ -77,3 +87,19 @@
t.end()
})
+
+test("encode with option", function (t) {
+ var obj = {log: { type:'file', level: {label:'debug', value:10} } }
+ e = i.encode(obj, {section: 'prefix'})
+
+ t.equal(e, expectF)
+ t.end()
+})
+
+test("encode with whitespace", function (t) {
+ var obj = {log: { type:'file', level: {label:'debug', value:10} } }
+ e = i.encode(obj, {whitespace: true})
+
+ t.equal(e, expectG)
+ t.end()
+})
diff -Nru nodejs-0.11.14/deps/npm/node_modules/init-package-json/default-input.js nodejs-0.11.15/deps/npm/node_modules/init-package-json/default-input.js
--- nodejs-0.11.14/deps/npm/node_modules/init-package-json/default-input.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/init-package-json/default-input.js 2015-01-20 21:22:17.000000000 +0000
@@ -38,11 +38,14 @@
})
}}
+var name = package.name || basename
+exports.name = yes ? name : prompt('name', name)
+
+var version = package.version || config.get('init-version') || '1.0.0'
+exports.version = yes ? version : prompt('version', version)
-exports.name = prompt('name', package.name || basename)
-exports.version = prompt('version', package.version || config.get('init.version') || '1.0.0')
if (!package.description) {
- exports.description = prompt('description')
+ exports.description = yes ? '' : prompt('description')
}
if (!package.main) {
@@ -63,7 +66,8 @@
else
f = f[0]
- return cb(null, prompt('entry point', f || 'index.js'))
+ var index = f || 'index.js'
+ return cb(null, yes ? index : prompt('entry point', index))
})
}
}
@@ -121,26 +125,32 @@
function tx (test) {
return test || notest
}
-
if (!s.test || s.test === notest) {
- if (d.indexOf('tap') !== -1)
- s.test = prompt('test command', 'tap test/*.js', tx)
- else if (d.indexOf('expresso') !== -1)
- s.test = prompt('test command', 'expresso test', tx)
- else if (d.indexOf('mocha') !== -1)
- s.test = prompt('test command', 'mocha', tx)
- else
- s.test = prompt('test command', tx)
+ var commands = {
+ 'tap':'tap test/*.js'
+ , 'expresso':'expresso test'
+ , 'mocha':'mocha'
+ }
+ var command
+ Object.keys(commands).forEach(function (k) {
+ if (d.indexOf(k) !== -1) command = commands[k]
+ })
+ var ps = 'test command'
+ if (yes) {
+ s.test = command || notest
+ } else {
+ s.test = command ? prompt(ps, command, tx) : prompt(ps, tx)
+ }
}
-
return cb(null, s)
}
if (!package.repository) {
exports.repository = function (cb) {
fs.readFile('.git/config', 'utf8', function (er, gconf) {
- if (er || !gconf) return cb(null, prompt('git repository'))
-
+ if (er || !gconf) {
+ return cb(null, yes ? '' : prompt('git repository'))
+ }
gconf = gconf.split(/\r?\n/)
var i = gconf.indexOf('[remote "origin"]')
if (i !== -1) {
@@ -152,13 +162,13 @@
if (u && u.match(/^git@github.com:/))
u = u.replace(/^git@github.com:/, 'https://github.com/')
- return cb(null, prompt('git repository', u))
+ return cb(null, yes ? u : prompt('git repository', u))
})
}
}
if (!package.keywords) {
- exports.keywords = prompt('keywords', function (s) {
+ exports.keywords = yes ? '' : prompt('keywords', function (s) {
if (!s) return undefined
if (Array.isArray(s)) s = s.join(' ')
if (typeof s !== 'string') return s
@@ -167,15 +177,14 @@
}
if (!package.author) {
- exports.author = config.get('init.author.name')
+ exports.author = config.get('init-author-name')
? {
- "name" : config.get('init.author.name'),
- "email" : config.get('init.author.email'),
- "url" : config.get('init.author.url')
+ "name" : config.get('init-author-name'),
+ "email" : config.get('init-author-email'),
+ "url" : config.get('init-author-url')
}
: prompt('author')
}
-exports.license = prompt('license', package.license ||
- config.get('init.license') ||
- 'ISC')
+var license = package.license || config.get('init-license') || 'ISC'
+exports.license = yes ? license : prompt('license', license)
diff -Nru nodejs-0.11.14/deps/npm/node_modules/init-package-json/init-package-json.js nodejs-0.11.15/deps/npm/node_modules/init-package-json/init-package-json.js
--- nodejs-0.11.14/deps/npm/node_modules/init-package-json/init-package-json.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/init-package-json/init-package-json.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,5 +1,6 @@
module.exports = init
+module.exports.yes = yes
var PZ = require('promzard').PromZard
var path = require('path')
@@ -14,6 +15,13 @@
// readJson.extras(file, data, cb)
var readJson = require('read-package-json')
+function yes (conf) {
+ return !!(
+ conf.get('yes') || conf.get('y') ||
+ conf.get('force') || conf.get('f')
+ )
+}
+
function init (dir, input, config, cb) {
if (typeof config === 'function')
cb = config, config = {}
@@ -35,7 +43,7 @@
var package = path.resolve(dir, 'package.json')
input = path.resolve(input)
var pkg
- var ctx = {}
+ var ctx = { yes: yes(config) }
var es = readJson.extraSet
readJson.extraSet = es.filter(function (fn) {
@@ -91,14 +99,21 @@
delete pkg.repository
var d = JSON.stringify(pkg, null, 2) + '\n'
+ function write (yes) {
+ fs.writeFile(package, d, 'utf8', function (er) {
+ if (!er && yes) console.log('Wrote to %s:\n\n%s\n', package, d)
+ return cb(er, pkg)
+ })
+ }
+ if (ctx.yes) {
+ return write(true)
+ }
console.log('About to write to %s:\n\n%s\n', package, d)
read({prompt:'Is this ok? ', default: 'yes'}, function (er, ok) {
if (!ok || ok.toLowerCase().charAt(0) !== 'y') {
console.log('Aborted.')
} else {
- fs.writeFile(package, d, 'utf8', function (er) {
- return cb(er, pkg)
- })
+ return write()
}
})
})
diff -Nru nodejs-0.11.14/deps/npm/node_modules/init-package-json/node_modules/promzard/package.json nodejs-0.11.15/deps/npm/node_modules/init-package-json/node_modules/promzard/package.json
--- nodejs-0.11.14/deps/npm/node_modules/init-package-json/node_modules/promzard/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/init-package-json/node_modules/promzard/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -27,7 +27,7 @@
"homepage": "https://github.com/isaacs/promzard",
"_id": "promzard@0.2.2",
"_shasum": "918b9f2b29458cb001781a8856502e4a79b016e0",
- "_from": "promzard@>=0.2.0-0 <0.3.0-0",
+ "_from": "promzard@>=0.2.0 <0.3.0",
"_npmVersion": "1.4.10",
"_npmUser": {
"name": "isaacs",
@@ -44,5 +44,6 @@
"tarball": "http://registry.npmjs.org/promzard/-/promzard-0.2.2.tgz"
},
"directories": {},
- "_resolved": "https://registry.npmjs.org/promzard/-/promzard-0.2.2.tgz"
+ "_resolved": "https://registry.npmjs.org/promzard/-/promzard-0.2.2.tgz",
+ "readme": "ERROR: No README data found!"
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/init-package-json/.npmignore nodejs-0.11.15/deps/npm/node_modules/init-package-json/.npmignore
--- nodejs-0.11.14/deps/npm/node_modules/init-package-json/.npmignore 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/init-package-json/.npmignore 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,2 @@
+node_modules/
+.eslintrc
diff -Nru nodejs-0.11.14/deps/npm/node_modules/init-package-json/package.json nodejs-0.11.15/deps/npm/node_modules/init-package-json/package.json
--- nodejs-0.11.14/deps/npm/node_modules/init-package-json/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/init-package-json/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -1,6 +1,6 @@
{
"name": "init-package-json",
- "version": "1.0.1",
+ "version": "1.1.1",
"main": "init-package-json.js",
"scripts": {
"test": "tap test/*.js"
@@ -24,8 +24,9 @@
"semver": "2.x || 3.x || 4"
},
"devDependencies": {
- "tap": "~0.2.5",
- "rimraf": "~2.0.2"
+ "npm": "^2.1.4",
+ "rimraf": "^2.1.4",
+ "tap": "^0.4.13"
},
"keywords": [
"init",
@@ -37,29 +38,14 @@
"prompt",
"start"
],
- "gitHead": "e1a5917ba1723ab5dcedacbffb5b10208d203e2f",
+ "readme": "# init-package-json\n\nA node module to get your node module started.\n\n## Usage\n\n```javascript\nvar init = require('init-package-json')\nvar path = require('path')\n\n// a path to a promzard module. In the event that this file is\n// not found, one will be provided for you.\nvar initFile = path.resolve(process.env.HOME, '.npm-init')\n\n// the dir where we're doin stuff.\nvar dir = process.cwd()\n\n// extra stuff that gets put into the PromZard module's context.\n// In npm, this is the resolved config object. Exposed as 'config'\n// Optional.\nvar configData = { some: 'extra stuff' }\n\n// Any existing stuff from the package.json file is also exposed in the\n// PromZard module as the `package` object. There will also be free\n// vars for:\n// * `filename` path to the package.json file\n// * `basename` the tip of the package dir\n// * `dirname` the parent of the package dir\n\ninit(dir, initFile, configData, function (er, data) {\n // the data's already been written to {dir}/package.json\n // now you can do stuff with it\n})\n```\n\nOr from the command line:\n\n```\n$ npm-init\n```\n\nSee [PromZard](https://github.com/isaacs/promzard) for details about\nwhat can go in the config file.\n",
+ "readmeFilename": "README.md",
+ "gitHead": "a4df4e57f9b6a2bf906ad50612dbed7dcb2f2c2b",
"bugs": {
"url": "https://github.com/isaacs/init-package-json/issues"
},
"homepage": "https://github.com/isaacs/init-package-json",
- "_id": "init-package-json@1.0.1",
- "_shasum": "c01b08cc90504ebc448d57b468e66fc08293e8a8",
- "_from": "init-package-json@>=1.0.0-0 <1.1.0-0",
- "_npmVersion": "2.0.0-beta.3",
- "_npmUser": {
- "name": "isaacs",
- "email": "i@izs.me"
- },
- "maintainers": [
- {
- "name": "isaacs",
- "email": "i@izs.me"
- }
- ],
- "dist": {
- "shasum": "c01b08cc90504ebc448d57b468e66fc08293e8a8",
- "tarball": "http://registry.npmjs.org/init-package-json/-/init-package-json-1.0.1.tgz"
- },
- "directories": {},
- "_resolved": "https://registry.npmjs.org/init-package-json/-/init-package-json-1.0.1.tgz"
+ "_id": "init-package-json@1.1.1",
+ "_shasum": "e09e9f1fb541e0fddc9175c5ce1736fd45ff4bf8",
+ "_from": "init-package-json@>=1.1.1 <2.0.0"
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/init-package-json/test/npm-defaults.js nodejs-0.11.15/deps/npm/node_modules/init-package-json/test/npm-defaults.js
--- nodejs-0.11.14/deps/npm/node_modules/init-package-json/test/npm-defaults.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/init-package-json/test/npm-defaults.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,49 @@
+var test = require("tap").test
+var rimraf = require("rimraf")
+var resolve = require("path").resolve
+
+var npm = require("npm")
+var init = require("../")
+
+var EXPECTED = {
+ name : "test",
+ version : "3.1.4",
+ description : "",
+ main : "basic.js",
+ scripts : {
+ test : 'echo "Error: no test specified" && exit 1'
+ },
+ keywords : [],
+ author : "npmbot (http://npm.im)",
+ license : "WTFPL"
+}
+
+test("npm configuration values pulled from environment", function (t) {
+ /*eslint camelcase:0 */
+ process.env.npm_config_yes = "yes"
+
+ process.env.npm_config_init_author_name = "npmbot"
+ process.env.npm_config_init_author_email = "n@p.m"
+ process.env.npm_config_init_author_url = "http://npm.im"
+
+ process.env.npm_config_init_license = EXPECTED.license
+ process.env.npm_config_init_version = EXPECTED.version
+
+ npm.load({}, function (err) {
+ t.ifError(err, "npm loaded successfully")
+
+ process.chdir(resolve(__dirname))
+ init(__dirname, __dirname, npm.config, function (er, data) {
+ t.ifError(err, "init ran successfully")
+
+ t.same(data, EXPECTED, "got the package data from the environment")
+ t.end()
+ })
+ })
+})
+
+test("cleanup", function (t) {
+ rimraf.sync(resolve(__dirname, "package.json"))
+ t.pass("cleaned up")
+ t.end()
+})
diff -Nru nodejs-0.11.14/deps/npm/node_modules/normalize-package-data/lib/fixer.js nodejs-0.11.15/deps/npm/node_modules/normalize-package-data/lib/fixer.js
--- nodejs-0.11.14/deps/npm/node_modules/normalize-package-data/lib/fixer.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/normalize-package-data/lib/fixer.js 2015-01-20 21:22:17.000000000 +0000
@@ -111,6 +111,13 @@
this.warn("nonStringBundleDependency", bd)
return false
} else {
+ if (!data.dependencies) {
+ data.dependencies = {}
+ }
+ if (!data.dependencies.hasOwnProperty(bd)) {
+ this.warn("nonDependencyBundleDependency", bd)
+ data.dependencies[bd] = "*"
+ }
return true
}
}, this)
diff -Nru nodejs-0.11.14/deps/npm/node_modules/normalize-package-data/lib/warning_messages.json nodejs-0.11.15/deps/npm/node_modules/normalize-package-data/lib/warning_messages.json
--- nodejs-0.11.14/deps/npm/node_modules/normalize-package-data/lib/warning_messages.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/normalize-package-data/lib/warning_messages.json 2015-01-20 21:22:17.000000000 +0000
@@ -8,6 +8,7 @@
,"invalidFilename": "Invalid filename in 'files' list: %s"
,"nonArrayBundleDependencies": "Invalid 'bundleDependencies' list. Must be array of package names"
,"nonStringBundleDependency": "Invalid bundleDependencies member: %s"
+ ,"nonDependencyBundleDependency": "Non-dependency in bundleDependencies: %s"
,"nonObjectDependencies": "%s field must be an object"
,"nonStringDependency": "Invalid dependency: %s %s"
,"deprecatedArrayDependencies": "specifying %s as array is deprecated"
@@ -25,4 +26,4 @@
,"nonUrlHomepage": "homepage field must be a string url. Deleted."
,"missingProtocolHomepage": "homepage field must start with a protocol."
,"typo": "%s should probably be %s."
-}
\ No newline at end of file
+}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/normalize-package-data/package.json nodejs-0.11.15/deps/npm/node_modules/normalize-package-data/package.json
--- nodejs-0.11.14/deps/npm/node_modules/normalize-package-data/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/normalize-package-data/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -1,6 +1,6 @@
{
"name": "normalize-package-data",
- "version": "1.0.2",
+ "version": "1.0.3",
"author": {
"name": "Meryn Stol",
"email": "merynstol@gmail.com"
@@ -38,15 +38,16 @@
"email": "rok@kowalski.gd"
}
],
- "gitHead": "05fafb91466ac634fa7d591d0796d64b0b432dc0",
+ "gitHead": "8c30091c83b1a41e113757148c4543ef61ff863d",
"bugs": {
"url": "https://github.com/meryn/normalize-package-data/issues"
},
"homepage": "https://github.com/meryn/normalize-package-data",
- "_id": "normalize-package-data@1.0.2",
- "_shasum": "32a902ad3cad3286f1106b9b9550062f44ee2118",
- "_from": "normalize-package-data@>=1.0.1-0 <1.1.0-0",
- "_npmVersion": "2.0.0-beta.3",
+ "_id": "normalize-package-data@1.0.3",
+ "_shasum": "8be955b8907af975f1a4584ea8bb9b41492312f5",
+ "_from": "normalize-package-data@>=1.0.3 <1.1.0",
+ "_npmVersion": "2.1.0",
+ "_nodeVersion": "0.10.31",
"_npmUser": {
"name": "isaacs",
"email": "i@izs.me"
@@ -66,9 +67,9 @@
}
],
"dist": {
- "shasum": "32a902ad3cad3286f1106b9b9550062f44ee2118",
- "tarball": "http://registry.npmjs.org/normalize-package-data/-/normalize-package-data-1.0.2.tgz"
+ "shasum": "8be955b8907af975f1a4584ea8bb9b41492312f5",
+ "tarball": "http://registry.npmjs.org/normalize-package-data/-/normalize-package-data-1.0.3.tgz"
},
"directories": {},
- "_resolved": "https://registry.npmjs.org/normalize-package-data/-/normalize-package-data-1.0.2.tgz"
+ "_resolved": "https://registry.npmjs.org/normalize-package-data/-/normalize-package-data-1.0.3.tgz"
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/normalize-package-data/README.md nodejs-0.11.15/deps/npm/node_modules/normalize-package-data/README.md
--- nodejs-0.11.14/deps/npm/node_modules/normalize-package-data/README.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/normalize-package-data/README.md 2015-01-20 21:22:17.000000000 +0000
@@ -16,7 +16,7 @@
```javascript
normalizeData = require('normalize-package-data')
-packageData = fs.readfileSync("package.json")
+packageData = fs.readFileSync("package.json")
normalizeData(packageData)
// packageData is now normalized
```
@@ -27,7 +27,7 @@
```javascript
normalizeData = require('normalize-package-data')
-packageData = fs.readfileSync("package.json")
+packageData = fs.readFileSync("package.json")
warnFn = function(msg) { console.error(msg) }
normalizeData(packageData, true)
// packageData is now normalized
@@ -41,7 +41,7 @@
```javascript
normalizeData = require('normalize-package-data')
-packageData = fs.readfileSync("package.json")
+packageData = fs.readFileSync("package.json")
warnFn = function(msg) { console.error(msg) }
normalizeData(packageData, warnFn)
// packageData is now normalized. Any number of warnings may have been logged.
diff -Nru nodejs-0.11.14/deps/npm/node_modules/normalize-package-data/test/dependencies.js nodejs-0.11.15/deps/npm/node_modules/normalize-package-data/test/dependencies.js
--- nodejs-0.11.14/deps/npm/node_modules/normalize-package-data/test/dependencies.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/normalize-package-data/test/dependencies.js 2015-01-20 21:22:17.000000000 +0000
@@ -37,7 +37,8 @@
var wanted1 = safeFormat(warningMessages.nonStringBundleDependency, 123)
var wanted2 = safeFormat(warningMessages.nonStringBundleDependency, {foo:"bar"})
+ var wanted2 = safeFormat(warningMessages.nonDependencyBundleDependency, "abc")
t.ok(~warnings.indexOf(wanted1), wanted1)
t.ok(~warnings.indexOf(wanted2), wanted2)
t.end()
-})
\ No newline at end of file
+})
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/config-defs.js nodejs-0.11.15/deps/npm/node_modules/npmconf/config-defs.js
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/config-defs.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/config-defs.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,381 +0,0 @@
-// defaults, types, and shorthands.
-
-
-var path = require("path")
- , url = require("url")
- , Stream = require("stream").Stream
- , semver = require("semver")
- , stableFamily = semver.parse(process.version)
- , nopt = require("nopt")
- , os = require("os")
- , osenv = require("osenv")
-
-var log
-try {
- log = require("npmlog")
-} catch (er) {
- var util = require("util")
- log = { warn: function (m) {
- console.warn(m + ' ' + util.format.apply(util, [].slice.call(arguments, 1)))
- } }
-}
-
-exports.Octal = Octal
-function Octal () {}
-function validateOctal (data, k, val) {
- // must be either an integer or an octal string.
- if (typeof val === "number") {
- data[k] = val
- return true
- }
-
- if (typeof val === "string") {
- if (val.charAt(0) !== "0" || isNaN(val)) return false
- data[k] = parseInt(val, 8).toString(8)
- }
-}
-
-function validateSemver (data, k, val) {
- if (!semver.valid(val)) return false
- data[k] = semver.valid(val)
-}
-
-function validateTag (data, k, val) {
- val = ('' + val).trim()
- if (!val || semver.validRange(val)) return false
- data[k] = val
-}
-
-function validateStream (data, k, val) {
- if (!(val instanceof Stream)) return false
- data[k] = val
-}
-
-nopt.typeDefs.semver = { type: semver, validate: validateSemver }
-nopt.typeDefs.Octal = { type: Octal, validate: validateOctal }
-nopt.typeDefs.Stream = { type: Stream, validate: validateStream }
-
-// Don't let --tag=1.2.3 ever be a thing
-var tag = {}
-nopt.typeDefs.tag = { type: tag, validate: validateTag }
-
-nopt.invalidHandler = function (k, val, type) {
- log.warn("invalid config", k + "=" + JSON.stringify(val))
-
- if (Array.isArray(type)) {
- if (type.indexOf(url) !== -1) type = url
- else if (type.indexOf(path) !== -1) type = path
- }
-
- switch (type) {
- case tag:
- log.warn("invalid config", "Tag must not be a SemVer range")
- break
- case Octal:
- log.warn("invalid config", "Must be octal number, starting with 0")
- break
- case url:
- log.warn("invalid config", "Must be a full url with 'http://'")
- break
- case path:
- log.warn("invalid config", "Must be a valid filesystem path")
- break
- case Number:
- log.warn("invalid config", "Must be a numeric value")
- break
- case Stream:
- log.warn("invalid config", "Must be an instance of the Stream class")
- break
- }
-}
-
-if (!stableFamily || (+stableFamily.minor % 2)) stableFamily = null
-else stableFamily = stableFamily.major + "." + stableFamily.minor
-
-var defaults
-
-var temp = osenv.tmpdir()
-var home = osenv.home()
-
-var uidOrPid = process.getuid ? process.getuid() : process.pid
-
-if (home) process.env.HOME = home
-else home = path.resolve(temp, "npm-" + uidOrPid)
-
-var cacheExtra = process.platform === "win32" ? "npm-cache" : ".npm"
-var cacheRoot = process.platform === "win32" && process.env.APPDATA || home
-var cache = path.resolve(cacheRoot, cacheExtra)
-
-
-var globalPrefix
-Object.defineProperty(exports, "defaults", {get: function () {
- if (defaults) return defaults
-
- if (process.env.PREFIX) {
- globalPrefix = process.env.PREFIX
- } else if (process.platform === "win32") {
- // c:\node\node.exe --> prefix=c:\node\
- globalPrefix = path.dirname(process.execPath)
- } else {
- // /usr/local/bin/node --> prefix=/usr/local
- globalPrefix = path.dirname(path.dirname(process.execPath))
-
- // destdir only is respected on Unix
- if (process.env.DESTDIR) {
- globalPrefix = path.join(process.env.DESTDIR, globalPrefix)
- }
- }
-
- return defaults =
- { "always-auth" : false
- , "bin-links" : true
- , browser : null
-
- , ca: null
- , cafile: null
-
- , cache : cache
-
- , "cache-lock-stale": 60000
- , "cache-lock-retries": 10
- , "cache-lock-wait": 10000
-
- , "cache-max": Infinity
- , "cache-min": 10
-
- , cert: null
-
- , color : true
- , depth: Infinity
- , description : true
- , dev : false
- , editor : osenv.editor()
- , "engine-strict": false
- , force : false
-
- , "fetch-retries": 2
- , "fetch-retry-factor": 10
- , "fetch-retry-mintimeout": 10000
- , "fetch-retry-maxtimeout": 60000
-
- , git: "git"
- , "git-tag-version": true
-
- , global : false
- , globalconfig : path.resolve(globalPrefix, "etc", "npmrc")
- , group : process.platform === "win32" ? 0
- : process.env.SUDO_GID || (process.getgid && process.getgid())
- , heading: "npm"
- , "ignore-scripts": false
- , "init-module": path.resolve(home, ".npm-init.js")
- , "init.author.name" : ""
- , "init.author.email" : ""
- , "init.author.url" : ""
- , "init.version": "1.0.0"
- , "init.license": "ISC"
- , json: false
- , key: null
- , link: false
- , "local-address" : undefined
- , loglevel : "warn"
- , logstream : process.stderr
- , long : false
- , message : "%s"
- , "node-version" : process.version
- , npat : false
- , "onload-script" : false
- , optional: true
- , parseable : false
- , prefix : globalPrefix
- , production: process.env.NODE_ENV === "production"
- , "proprietary-attribs": true
- , proxy : process.env.HTTP_PROXY || process.env.http_proxy || null
- , "https-proxy" : process.env.HTTPS_PROXY || process.env.https_proxy ||
- process.env.HTTP_PROXY || process.env.http_proxy || null
- , "user-agent" : "npm/{npm-version} "
- + "node/{node-version} "
- + "{platform} "
- + "{arch}"
- , "rebuild-bundle" : true
- , registry : "https://registry.npmjs.org/"
- , rollback : true
- , save : false
- , "save-bundle": false
- , "save-dev" : false
- , "save-exact" : false
- , "save-optional" : false
- , "save-prefix": "^"
- , scope : ""
- , searchopts: ""
- , searchexclude: null
- , searchsort: "name"
- , shell : osenv.shell()
- , shrinkwrap: true
- , "sign-git-tag": false
- , spin: true
- , "strict-ssl": true
- , tag : "latest"
- , tmp : temp
- , unicode : true
- , "unsafe-perm" : process.platform === "win32"
- || process.platform === "cygwin"
- || !( process.getuid && process.setuid
- && process.getgid && process.setgid )
- || process.getuid() !== 0
- , usage : false
- , user : process.platform === "win32" ? 0 : "nobody"
- , userconfig : path.resolve(home, ".npmrc")
- , umask: process.umask ? process.umask() : parseInt("022", 8)
- , version : false
- , versions : false
- , viewer: process.platform === "win32" ? "browser" : "man"
-
- , _exit : true
- }
-}})
-
-exports.types =
- { "always-auth" : Boolean
- , "bin-links": Boolean
- , browser : [null, String]
- , ca: [null, String, Array]
- , cafile : path
- , cache : path
- , "cache-lock-stale": Number
- , "cache-lock-retries": Number
- , "cache-lock-wait": Number
- , "cache-max": Number
- , "cache-min": Number
- , cert: [null, String]
- , color : ["always", Boolean]
- , depth : Number
- , description : Boolean
- , dev : Boolean
- , editor : String
- , "engine-strict": Boolean
- , force : Boolean
- , "fetch-retries": Number
- , "fetch-retry-factor": Number
- , "fetch-retry-mintimeout": Number
- , "fetch-retry-maxtimeout": Number
- , git: String
- , "git-tag-version": Boolean
- , global : Boolean
- , globalconfig : path
- , group : [Number, String]
- , "https-proxy" : [null, url]
- , "user-agent" : String
- , "heading": String
- , "ignore-scripts": Boolean
- , "init-module": path
- , "init.author.name" : String
- , "init.author.email" : String
- , "init.author.url" : ["", url]
- , "init.license": String
- , "init.version": semver
- , json: Boolean
- , key: [null, String]
- , link: Boolean
- // local-address must be listed as an IP for a local network interface
- // must be IPv4 due to node bug
- , "local-address" : getLocalAddresses()
- , loglevel : ["silent","error","warn","http","info","verbose","silly"]
- , logstream : Stream
- , long : Boolean
- , message: String
- , "node-version" : [null, semver]
- , npat : Boolean
- , "onload-script" : [null, String]
- , optional: Boolean
- , parseable : Boolean
- , prefix: path
- , production: Boolean
- , "proprietary-attribs": Boolean
- , proxy : [null, url]
- , "rebuild-bundle" : Boolean
- , registry : [null, url]
- , rollback : Boolean
- , save : Boolean
- , "save-bundle": Boolean
- , "save-dev" : Boolean
- , "save-exact" : Boolean
- , "save-optional" : Boolean
- , "save-prefix": String
- , scope : String
- , searchopts : String
- , searchexclude: [null, String]
- , searchsort: [ "name", "-name"
- , "description", "-description"
- , "author", "-author"
- , "date", "-date"
- , "keywords", "-keywords" ]
- , shell : String
- , shrinkwrap: Boolean
- , "sign-git-tag": Boolean
- , spin: ["always", Boolean]
- , "strict-ssl": Boolean
- , tag : tag
- , tmp : path
- , unicode : Boolean
- , "unsafe-perm" : Boolean
- , usage : Boolean
- , user : [Number, String]
- , userconfig : path
- , umask: Octal
- , version : Boolean
- , versions : Boolean
- , viewer: String
- , _exit : Boolean
- }
-
-function getLocalAddresses() {
- Object.keys(os.networkInterfaces()).map(function (nic) {
- return os.networkInterfaces()[nic].filter(function (addr) {
- return addr.family === "IPv4"
- })
- .map(function (addr) {
- return addr.address
- })
- }).reduce(function (curr, next) {
- return curr.concat(next)
- }, []).concat(undefined)
-}
-
-exports.shorthands =
- { s : ["--loglevel", "silent"]
- , d : ["--loglevel", "info"]
- , dd : ["--loglevel", "verbose"]
- , ddd : ["--loglevel", "silly"]
- , noreg : ["--no-registry"]
- , N : ["--no-registry"]
- , reg : ["--registry"]
- , "no-reg" : ["--no-registry"]
- , silent : ["--loglevel", "silent"]
- , verbose : ["--loglevel", "verbose"]
- , quiet: ["--loglevel", "warn"]
- , q: ["--loglevel", "warn"]
- , h : ["--usage"]
- , H : ["--usage"]
- , "?" : ["--usage"]
- , help : ["--usage"]
- , v : ["--version"]
- , f : ["--force"]
- , gangster : ["--force"]
- , gangsta : ["--force"]
- , desc : ["--description"]
- , "no-desc" : ["--no-description"]
- , "local" : ["--no-global"]
- , l : ["--long"]
- , m : ["--message"]
- , p : ["--parseable"]
- , porcelain : ["--parseable"]
- , g : ["--global"]
- , S : ["--save"]
- , D : ["--save-dev"]
- , E : ["--save-exact"]
- , O : ["--save-optional"]
- , y : ["--yes"]
- , n : ["--no-yes"]
- , B : ["--save-bundle"]
- , C : ["--prefix"]
- }
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/lib/find-prefix.js nodejs-0.11.15/deps/npm/node_modules/npmconf/lib/find-prefix.js
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/lib/find-prefix.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/lib/find-prefix.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,56 +0,0 @@
-// try to find the most reasonable prefix to use
-
-module.exports = findPrefix
-
-var fs = require("fs")
-var path = require("path")
-
-function findPrefix (p, cb_) {
- function cb (er, p) {
- process.nextTick(function () {
- cb_(er, p)
- })
- }
-
- p = path.resolve(p)
- // if there's no node_modules folder, then
- // walk up until we hopefully find one.
- // if none anywhere, then use cwd.
- var walkedUp = false
- while (path.basename(p) === "node_modules") {
- p = path.dirname(p)
- walkedUp = true
- }
- if (walkedUp) return cb(null, p)
-
- findPrefix_(p, p, cb)
-}
-
-function findPrefix_ (p, original, cb) {
- if (p === "/"
- || (process.platform === "win32" && p.match(/^[a-zA-Z]:(\\|\/)?$/))) {
- return cb(null, original)
- }
- fs.readdir(p, function (er, files) {
- // an error right away is a bad sign.
- // unless the prefix was simply a non
- // existent directory.
- if (er && p === original) {
- if (er.code === "ENOENT") return cb(null, original);
- return cb(er)
- }
-
- // walked up too high or something.
- if (er) return cb(null, original)
-
- if (files.indexOf("node_modules") !== -1
- || files.indexOf("package.json") !== -1) {
- return cb(null, p)
- }
-
- var d = path.dirname(p)
- if (d === p) return cb(null, original)
-
- return findPrefix_(d, original, cb)
- })
-}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/lib/get-credentials-by-uri.js nodejs-0.11.15/deps/npm/node_modules/npmconf/lib/get-credentials-by-uri.js
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/lib/get-credentials-by-uri.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/lib/get-credentials-by-uri.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,57 +0,0 @@
-var assert = require("assert")
-
-var toNerfDart = require("./nerf-dart.js")
-
-module.exports = getCredentialsByURI
-
-function getCredentialsByURI (uri) {
- assert(uri && typeof uri === "string", "registry URL is required")
- var nerfed = toNerfDart(uri)
- var defnerf = toNerfDart(this.get("registry"))
-
- var c = {scope : nerfed}
-
- if (this.get(nerfed + ":_authToken")) {
- c.token = this.get(nerfed + ":_authToken")
- // the bearer token is enough, don't confuse things
- return c
- }
-
- // Handle the old-style _auth= style for the default
- // registry, if set.
- //
- // XXX(isaacs): Remove when npm 1.4 is no longer relevant
- var authDef = this.get("_auth")
- var userDef = this.get("username")
- var passDef = this.get("_password")
- if (authDef && !(userDef && passDef)) {
- authDef = new Buffer(authDef, "base64").toString()
- authDef = authDef.split(":")
- userDef = authDef.shift()
- passDef = authDef.join(":")
- }
-
- if (this.get(nerfed + ":_password")) {
- c.password = new Buffer(this.get(nerfed + ":_password"), "base64").toString("utf8")
- } else if (nerfed === defnerf && passDef) {
- c.password = passDef
- }
-
- if (this.get(nerfed + ":username")) {
- c.username = this.get(nerfed + ":username")
- } else if (nerfed === defnerf && userDef) {
- c.username = userDef
- }
-
- if (this.get(nerfed + ":email")) {
- c.email = this.get(nerfed + ":email")
- } else if (this.get("email")) {
- c.email = this.get("email")
- }
-
- if (c.username && c.password) {
- c.auth = new Buffer(c.username + ":" + c.password).toString("base64")
- }
-
- return c
-}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/lib/load-cafile.js nodejs-0.11.15/deps/npm/node_modules/npmconf/lib/load-cafile.js
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/lib/load-cafile.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/lib/load-cafile.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,31 +0,0 @@
-module.exports = loadCAFile
-
-var fs = require('fs')
-
-function loadCAFile(cafilePath, cb) {
- if (!cafilePath)
- return process.nextTick(cb)
-
- fs.readFile(cafilePath, 'utf8', afterCARead.bind(this))
-
- function afterCARead(er, cadata) {
- if (er)
- return cb(er)
-
- var delim = '-----END CERTIFICATE-----'
- var output
-
- output = cadata
- .split(delim)
- .filter(function(xs) {
- return !!xs.trim()
- })
- .map(function(xs) {
- return xs.trimLeft() + delim
- })
-
- this.set('ca', output)
- cb(null)
- }
-
-}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/lib/load-prefix.js nodejs-0.11.15/deps/npm/node_modules/npmconf/lib/load-prefix.js
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/lib/load-prefix.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/lib/load-prefix.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,49 +0,0 @@
-module.exports = loadPrefix
-
-var findPrefix = require("./find-prefix.js")
-var path = require('path')
-
-function loadPrefix (cb) {
- var cli = this.list[0]
-
- Object.defineProperty(this, "prefix",
- { set : function (prefix) {
- var g = this.get("global")
- this[g ? 'globalPrefix' : 'localPrefix'] = prefix
- }.bind(this)
- , get : function () {
- var g = this.get("global")
- return g ? this.globalPrefix : this.localPrefix
- }.bind(this)
- , enumerable : true
- })
-
- Object.defineProperty(this, "globalPrefix",
- { set : function (prefix) {
- this.set('prefix', prefix)
- }.bind(this)
- , get : function () {
- return path.resolve(this.get("prefix"))
- }.bind(this)
- , enumerable : true
- })
-
- var p
- Object.defineProperty(this, "localPrefix",
- { set : function (prefix) { p = prefix },
- get : function () { return p }
- , enumerable: true })
-
- // try to guess at a good node_modules location.
- // If we are *explicitly* given a prefix on the cli, then
- // always use that. otherwise, infer local prefix from cwd.
- if (Object.prototype.hasOwnProperty.call(cli, "prefix")) {
- p = path.resolve(cli.prefix)
- process.nextTick(cb)
- } else {
- findPrefix(process.cwd(), function (er, found) {
- p = found
- cb(er)
- }.bind(this))
- }
-}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/lib/load-uid.js nodejs-0.11.15/deps/npm/node_modules/npmconf/lib/load-uid.js
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/lib/load-uid.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/lib/load-uid.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,15 +0,0 @@
-module.exports = loadUid
-
-var getUid = require("uid-number")
-
-// Call in the context of a npmconf object
-
-function loadUid (cb) {
- // if we're not in unsafe-perm mode, then figure out who
- // to run stuff as. Do this first, to support `npm update npm -g`
- if (!this.get("unsafe-perm")) {
- getUid(this.get("user"), this.get("group"), cb)
- } else {
- process.nextTick(cb)
- }
-}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/lib/nerf-dart.js nodejs-0.11.15/deps/npm/node_modules/npmconf/lib/nerf-dart.js
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/lib/nerf-dart.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/lib/nerf-dart.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,21 +0,0 @@
-var url = require("url")
-
-module.exports = toNerfDart
-
-/**
- * Maps a URL to an identifier.
- *
- * Name courtesy schiffertronix media LLC, a New Jersey corporation
- *
- * @param {String} uri The URL to be nerfed.
- *
- * @returns {String} A nerfed URL.
- */
-function toNerfDart(uri) {
- var parsed = url.parse(uri)
- parsed.pathname = "/"
- delete parsed.protocol
- delete parsed.auth
-
- return url.format(parsed)
-}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/lib/set-credentials-by-uri.js nodejs-0.11.15/deps/npm/node_modules/npmconf/lib/set-credentials-by-uri.js
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/lib/set-credentials-by-uri.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/lib/set-credentials-by-uri.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,34 +0,0 @@
-var assert = require("assert")
-
-var toNerfDart = require("./nerf-dart.js")
-
-module.exports = setCredentialsByURI
-
-function setCredentialsByURI (uri, c) {
- assert(uri && typeof uri === "string", "registry URL is required")
- assert(c && typeof c === "object", "credentials are required")
-
- var nerfed = toNerfDart(uri)
-
- if (c.token) {
- this.set(nerfed + ":_authToken", c.token, "user")
- this.del(nerfed + ":_password", "user")
- this.del(nerfed + ":username", "user")
- this.del(nerfed + ":email", "user")
- }
- else if (c.username || c.password || c.email) {
- assert(c.username, "must include username")
- assert(c.password, "must include password")
- assert(c.email, "must include email address")
-
- this.del(nerfed + ":_authToken", "user")
-
- var encoded = new Buffer(c.password, "utf8").toString("base64")
- this.set(nerfed + ":_password", encoded, "user")
- this.set(nerfed + ":username", c.username, "user")
- this.set(nerfed + ":email", c.email, "user")
- }
- else {
- throw new Error("No credentials to set.")
- }
-}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/lib/set-user.js nodejs-0.11.15/deps/npm/node_modules/npmconf/lib/set-user.js
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/lib/set-user.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/lib/set-user.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,26 +0,0 @@
-module.exports = setUser
-
-var Conf = require('../npmconf.js').Conf
-var assert = require('assert')
-var path = require('path')
-var fs = require('fs')
-
-function setUser (cb) {
- var defaultConf = this.root
- assert(defaultConf !== Object.prototype)
-
- // If global, leave it as-is.
- // If not global, then set the user to the owner of the prefix folder.
- // Just set the default, so it can be overridden.
- if (this.get("global")) return cb()
- if (process.env.SUDO_UID) {
- defaultConf.user = +(process.env.SUDO_UID)
- return cb()
- }
-
- var prefix = path.resolve(this.get("prefix"))
- fs.stat(prefix, function (er, st) {
- defaultConf.user = st && st.uid
- return cb(er)
- })
-}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/LICENSE nodejs-0.11.15/deps/npm/node_modules/npmconf/LICENSE
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/LICENSE 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/LICENSE 1970-01-01 00:00:00.000000000 +0000
@@ -1,27 +0,0 @@
-Copyright (c) Isaac Z. Schlueter ("Author")
-All rights reserved.
-
-The BSD License
-
-Redistribution and use in source and binary forms, with or without
-modification, are permitted provided that the following conditions
-are met:
-
-1. Redistributions of source code must retain the above copyright
- notice, this list of conditions and the following disclaimer.
-
-2. Redistributions in binary form must reproduce the above copyright
- notice, this list of conditions and the following disclaimer in the
- documentation and/or other materials provided with the distribution.
-
-THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
-PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS
-BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
-CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
-SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
-BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
-WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
-OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
-IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/index.js nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/index.js
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/index.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/index.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,282 +0,0 @@
-var ProtoList = require('proto-list')
- , path = require('path')
- , fs = require('fs')
- , ini = require('ini')
- , EE = require('events').EventEmitter
- , url = require('url')
- , http = require('http')
-
-var exports = module.exports = function () {
- var args = [].slice.call(arguments)
- , conf = new ConfigChain()
-
- while(args.length) {
- var a = args.shift()
- if(a) conf.push
- ( 'string' === typeof a
- ? json(a)
- : a )
- }
-
- return conf
-}
-
-//recursively find a file...
-
-var find = exports.find = function () {
- var rel = path.join.apply(null, [].slice.call(arguments))
-
- function find(start, rel) {
- var file = path.join(start, rel)
- try {
- fs.statSync(file)
- return file
- } catch (err) {
- if(path.dirname(start) !== start) // root
- return find(path.dirname(start), rel)
- }
- }
- return find(__dirname, rel)
-}
-
-var parse = exports.parse = function (content, file, type) {
- content = '' + content
- // if we don't know what it is, try json and fall back to ini
- // if we know what it is, then it must be that.
- if (!type) {
- try { return JSON.parse(content) }
- catch (er) { return ini.parse(content) }
- } else if (type === 'json') {
- if (this.emit) {
- try { return JSON.parse(content) }
- catch (er) { this.emit('error', er) }
- } else {
- return JSON.parse(content)
- }
- } else {
- return ini.parse(content)
- }
-}
-
-var json = exports.json = function () {
- var args = [].slice.call(arguments).filter(function (arg) { return arg != null })
- var file = path.join.apply(null, args)
- var content
- try {
- content = fs.readFileSync(file,'utf-8')
- } catch (err) {
- return
- }
- return parse(content, file, 'json')
-}
-
-var env = exports.env = function (prefix, env) {
- env = env || process.env
- var obj = {}
- var l = prefix.length
- for(var k in env) {
- if(k.indexOf(prefix) === 0)
- obj[k.substring(l)] = env[k]
- }
-
- return obj
-}
-
-exports.ConfigChain = ConfigChain
-function ConfigChain () {
- EE.apply(this)
- ProtoList.apply(this, arguments)
- this._awaiting = 0
- this._saving = 0
- this.sources = {}
-}
-
-// multi-inheritance-ish
-var extras = {
- constructor: { value: ConfigChain }
-}
-Object.keys(EE.prototype).forEach(function (k) {
- extras[k] = Object.getOwnPropertyDescriptor(EE.prototype, k)
-})
-ConfigChain.prototype = Object.create(ProtoList.prototype, extras)
-
-ConfigChain.prototype.del = function (key, where) {
- // if not specified where, then delete from the whole chain, scorched
- // earth style
- if (where) {
- var target = this.sources[where]
- target = target && target.data
- if (!target) {
- return this.emit('error', new Error('not found '+where))
- }
- delete target[key]
- } else {
- for (var i = 0, l = this.list.length; i < l; i ++) {
- delete this.list[i][key]
- }
- }
- return this
-}
-
-ConfigChain.prototype.set = function (key, value, where) {
- var target
-
- if (where) {
- target = this.sources[where]
- target = target && target.data
- if (!target) {
- return this.emit('error', new Error('not found '+where))
- }
- } else {
- target = this.list[0]
- if (!target) {
- return this.emit('error', new Error('cannot set, no confs!'))
- }
- }
- target[key] = value
- return this
-}
-
-ConfigChain.prototype.get = function (key, where) {
- if (where) {
- where = this.sources[where]
- if (where) where = where.data
- if (where && Object.hasOwnProperty.call(where, key)) return where[key]
- return undefined
- }
- return this.list[0][key]
-}
-
-ConfigChain.prototype.save = function (where, type, cb) {
- if (typeof type === 'function') cb = type, type = null
- var target = this.sources[where]
- if (!target || !(target.path || target.source) || !target.data) {
- // TODO: maybe save() to a url target could be a PUT or something?
- // would be easy to swap out with a reddis type thing, too
- return this.emit('error', new Error('bad save target: '+where))
- }
-
- if (target.source) {
- var pref = target.prefix || ''
- Object.keys(target.data).forEach(function (k) {
- target.source[pref + k] = target.data[k]
- })
- return this
- }
-
- var type = type || target.type
- var data = target.data
- if (target.type === 'json') {
- data = JSON.stringify(data)
- } else {
- data = ini.stringify(data)
- }
-
- this._saving ++
- fs.writeFile(target.path, data, 'utf8', function (er) {
- this._saving --
- if (er) {
- if (cb) return cb(er)
- else return this.emit('error', er)
- }
- if (this._saving === 0) {
- if (cb) cb()
- this.emit('save')
- }
- }.bind(this))
- return this
-}
-
-ConfigChain.prototype.addFile = function (file, type, name) {
- name = name || file
- var marker = {__source__:name}
- this.sources[name] = { path: file, type: type }
- this.push(marker)
- this._await()
- fs.readFile(file, 'utf8', function (er, data) {
- if (er) this.emit('error', er)
- this.addString(data, file, type, marker)
- }.bind(this))
- return this
-}
-
-ConfigChain.prototype.addEnv = function (prefix, env, name) {
- name = name || 'env'
- var data = exports.env(prefix, env)
- this.sources[name] = { data: data, source: env, prefix: prefix }
- return this.add(data, name)
-}
-
-ConfigChain.prototype.addUrl = function (req, type, name) {
- this._await()
- var href = url.format(req)
- name = name || href
- var marker = {__source__:name}
- this.sources[name] = { href: href, type: type }
- this.push(marker)
- http.request(req, function (res) {
- var c = []
- var ct = res.headers['content-type']
- if (!type) {
- type = ct.indexOf('json') !== -1 ? 'json'
- : ct.indexOf('ini') !== -1 ? 'ini'
- : href.match(/\.json$/) ? 'json'
- : href.match(/\.ini$/) ? 'ini'
- : null
- marker.type = type
- }
-
- res.on('data', c.push.bind(c))
- .on('end', function () {
- this.addString(Buffer.concat(c), href, type, marker)
- }.bind(this))
- .on('error', this.emit.bind(this, 'error'))
-
- }.bind(this))
- .on('error', this.emit.bind(this, 'error'))
- .end()
-
- return this
-}
-
-ConfigChain.prototype.addString = function (data, file, type, marker) {
- data = this.parse(data, file, type)
- this.add(data, marker)
- return this
-}
-
-ConfigChain.prototype.add = function (data, marker) {
- if (marker && typeof marker === 'object') {
- var i = this.list.indexOf(marker)
- if (i === -1) {
- return this.emit('error', new Error('bad marker'))
- }
- this.splice(i, 1, data)
- marker = marker.__source__
- this.sources[marker] = this.sources[marker] || {}
- this.sources[marker].data = data
- // we were waiting for this. maybe emit 'load'
- this._resolve()
- } else {
- if (typeof marker === 'string') {
- this.sources[marker] = this.sources[marker] || {}
- this.sources[marker].data = data
- }
- // trigger the load event if nothing was already going to do so.
- this._await()
- this.push(data)
- process.nextTick(this._resolve.bind(this))
- }
- return this
-}
-
-ConfigChain.prototype.parse = exports.parse
-
-ConfigChain.prototype._await = function () {
- this._awaiting++
-}
-
-ConfigChain.prototype._resolve = function () {
- this._awaiting--
- if (this._awaiting === 0) this.emit('load', this)
-}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/LICENCE nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/LICENCE
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/LICENCE 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/LICENCE 1970-01-01 00:00:00.000000000 +0000
@@ -1,22 +0,0 @@
-Copyright (c) 2011 Dominic Tarr
-
-Permission is hereby granted, free of charge,
-to any person obtaining a copy of this software and
-associated documentation files (the "Software"), to
-deal in the Software without restriction, including
-without limitation the rights to use, copy, modify,
-merge, publish, distribute, sublicense, and/or sell
-copies of the Software, and to permit persons to whom
-the Software is furnished to do so,
-subject to the following conditions:
-
-The above copyright notice and this permission notice
-shall be included in all copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
-OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
-IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR
-ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
-SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
\ No newline at end of file
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/node_modules/proto-list/LICENSE nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/node_modules/proto-list/LICENSE
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/node_modules/proto-list/LICENSE 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/node_modules/proto-list/LICENSE 1970-01-01 00:00:00.000000000 +0000
@@ -1,23 +0,0 @@
-Copyright 2009, 2010, 2011 Isaac Z. Schlueter.
-All rights reserved.
-
-Permission is hereby granted, free of charge, to any person
-obtaining a copy of this software and associated documentation
-files (the "Software"), to deal in the Software without
-restriction, including without limitation the rights to use,
-copy, modify, merge, publish, distribute, sublicense, and/or sell
-copies of the Software, and to permit persons to whom the
-Software is furnished to do so, subject to the following
-conditions:
-
-The above copyright notice and this permission notice shall be
-included in all copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
-OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
-HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
-WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
-FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
-OTHER DEALINGS IN THE SOFTWARE.
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/node_modules/proto-list/package.json nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/node_modules/proto-list/package.json
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/node_modules/proto-list/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/node_modules/proto-list/package.json 1970-01-01 00:00:00.000000000 +0000
@@ -1,50 +0,0 @@
-{
- "name": "proto-list",
- "version": "1.2.3",
- "description": "A utility for managing a prototype chain",
- "main": "./proto-list.js",
- "author": {
- "name": "Isaac Z. Schlueter",
- "email": "i@izs.me",
- "url": "http://blog.izs.me/"
- },
- "scripts": {
- "test": "tap test/*.js"
- },
- "repository": {
- "type": "git",
- "url": "https://github.com/isaacs/proto-list"
- },
- "license": {
- "type": "MIT",
- "url": "https://github.com/isaacs/proto-list/blob/master/LICENSE"
- },
- "devDependencies": {
- "tap": "0"
- },
- "gitHead": "44d76897176861d176a53ed3f3fc5e05cdee7643",
- "bugs": {
- "url": "https://github.com/isaacs/proto-list/issues"
- },
- "homepage": "https://github.com/isaacs/proto-list",
- "_id": "proto-list@1.2.3",
- "_shasum": "6235554a1bca1f0d15e3ca12ca7329d5def42bd9",
- "_from": "proto-list@>=1.2.1-0 <1.3.0-0",
- "_npmVersion": "1.4.14",
- "_npmUser": {
- "name": "isaacs",
- "email": "i@izs.me"
- },
- "maintainers": [
- {
- "name": "isaacs",
- "email": "i@izs.me"
- }
- ],
- "dist": {
- "shasum": "6235554a1bca1f0d15e3ca12ca7329d5def42bd9",
- "tarball": "http://registry.npmjs.org/proto-list/-/proto-list-1.2.3.tgz"
- },
- "directories": {},
- "_resolved": "https://registry.npmjs.org/proto-list/-/proto-list-1.2.3.tgz"
-}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/node_modules/proto-list/proto-list.js nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/node_modules/proto-list/proto-list.js
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/node_modules/proto-list/proto-list.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/node_modules/proto-list/proto-list.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,88 +0,0 @@
-
-module.exports = ProtoList
-
-function setProto(obj, proto) {
- if (typeof Object.setPrototypeOf === "function")
- return Object.setPrototypeOf(obj, proto)
- else
- obj.__proto__ = proto
-}
-
-function ProtoList () {
- this.list = []
- var root = null
- Object.defineProperty(this, 'root', {
- get: function () { return root },
- set: function (r) {
- root = r
- if (this.list.length) {
- setProto(this.list[this.list.length - 1], r)
- }
- },
- enumerable: true,
- configurable: true
- })
-}
-
-ProtoList.prototype =
- { get length () { return this.list.length }
- , get keys () {
- var k = []
- for (var i in this.list[0]) k.push(i)
- return k
- }
- , get snapshot () {
- var o = {}
- this.keys.forEach(function (k) { o[k] = this.get(k) }, this)
- return o
- }
- , get store () {
- return this.list[0]
- }
- , push : function (obj) {
- if (typeof obj !== "object") obj = {valueOf:obj}
- if (this.list.length >= 1) {
- setProto(this.list[this.list.length - 1], obj)
- }
- setProto(obj, this.root)
- return this.list.push(obj)
- }
- , pop : function () {
- if (this.list.length >= 2) {
- setProto(this.list[this.list.length - 2], this.root)
- }
- return this.list.pop()
- }
- , unshift : function (obj) {
- setProto(obj, this.list[0] || this.root)
- return this.list.unshift(obj)
- }
- , shift : function () {
- if (this.list.length === 1) {
- setProto(this.list[0], this.root)
- }
- return this.list.shift()
- }
- , get : function (key) {
- return this.list[0][key]
- }
- , set : function (key, val, save) {
- if (!this.length) this.push({})
- if (save && this.list[0].hasOwnProperty(key)) this.push({})
- return this.list[0][key] = val
- }
- , forEach : function (fn, thisp) {
- for (var key in this.list[0]) fn.call(thisp, key, this.list[0][key])
- }
- , slice : function () {
- return this.list.slice.apply(this.list, arguments)
- }
- , splice : function () {
- // handle injections
- var ret = this.list.splice.apply(this.list, arguments)
- for (var i = 0, l = this.list.length; i < l; i++) {
- setProto(this.list[i], this.list[i + 1] || this.root)
- }
- return ret
- }
- }
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/node_modules/proto-list/README.md nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/node_modules/proto-list/README.md
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/node_modules/proto-list/README.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/node_modules/proto-list/README.md 1970-01-01 00:00:00.000000000 +0000
@@ -1,3 +0,0 @@
-A list of objects, bound by their prototype chain.
-
-Used in npm's config stuff.
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/node_modules/proto-list/test/basic.js nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/node_modules/proto-list/test/basic.js
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/node_modules/proto-list/test/basic.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/node_modules/proto-list/test/basic.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,61 +0,0 @@
-var tap = require("tap")
- , test = tap.test
- , ProtoList = require("../proto-list.js")
-
-tap.plan(1)
-
-tap.test("protoList tests", function (t) {
- var p = new ProtoList
- p.push({foo:"bar"})
- p.push({})
- p.set("foo", "baz")
- t.equal(p.get("foo"), "baz")
-
- var p = new ProtoList
- p.push({foo:"bar"})
- p.set("foo", "baz")
- t.equal(p.get("foo"), "baz")
- t.equal(p.length, 1)
- p.pop()
- t.equal(p.length, 0)
- p.set("foo", "asdf")
- t.equal(p.length, 1)
- t.equal(p.get("foo"), "asdf")
- p.push({bar:"baz"})
- t.equal(p.length, 2)
- t.equal(p.get("foo"), "asdf")
- p.shift()
- t.equal(p.length, 1)
- t.equal(p.get("foo"), undefined)
-
-
- p.unshift({foo:"blo", bar:"rab"})
- p.unshift({foo:"boo"})
- t.equal(p.length, 3)
- t.equal(p.get("foo"), "boo")
- t.equal(p.get("bar"), "rab")
-
- var ret = p.splice(1, 1, {bar:"bar"})
- t.same(ret, [{foo:"blo", bar:"rab"}])
- t.equal(p.get("bar"), "bar")
-
- // should not inherit default object properties
- t.equal(p.get('hasOwnProperty'), undefined)
-
- // unless we give it those.
- p.root = {}
- t.equal(p.get('hasOwnProperty'), {}.hasOwnProperty)
-
- p.root = {default:'monkey'}
- t.equal(p.get('default'), 'monkey')
-
- p.push({red:'blue'})
- p.push({red:'blue'})
- p.push({red:'blue'})
- while (p.length) {
- t.equal(p.get('default'), 'monkey')
- p.shift()
- }
-
- t.end()
-})
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/.npmignore nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/.npmignore
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/.npmignore 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/.npmignore 1970-01-01 00:00:00.000000000 +0000
@@ -1,3 +0,0 @@
-node_modules
-node_modules/*
-npm_debug.log
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/package.json nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/package.json
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/package.json 1970-01-01 00:00:00.000000000 +0000
@@ -1,54 +0,0 @@
-{
- "name": "config-chain",
- "version": "1.1.8",
- "description": "HANDLE CONFIGURATION ONCE AND FOR ALL",
- "homepage": "http://github.com/dominictarr/config-chain",
- "repository": {
- "type": "git",
- "url": "https://github.com/dominictarr/config-chain.git"
- },
- "dependencies": {
- "proto-list": "~1.2.1",
- "ini": "1"
- },
- "devDependencies": {
- "tap": "0.3.0"
- },
- "author": {
- "name": "Dominic Tarr",
- "email": "dominic.tarr@gmail.com",
- "url": "http://dominictarr.com"
- },
- "scripts": {
- "test": "tap test/"
- },
- "readme": "#config-chain\n\nUSE THIS MODULE TO LOAD ALL YOUR CONFIGURATIONS\n\n``` js\n\n //npm install config-chain\n\n var cc = require('config-chain')\n , opts = require('optimist').argv //ALWAYS USE OPTIMIST FOR COMMAND LINE OPTIONS.\n , env = opts.env || process.env.YOUR_APP_ENV || 'dev' //SET YOUR ENV LIKE THIS.\n\n // EACH ARG TO CONFIGURATOR IS LOADED INTO CONFIGURATION CHAIN\n // EARLIER ITEMS OVERIDE LATER ITEMS\n // PUTS COMMAND LINE OPTS FIRST, AND DEFAULTS LAST!\n\n //strings are interpereted as filenames.\n //will be loaded synchronously\n\n var conf =\n cc(\n //OVERRIDE SETTINGS WITH COMMAND LINE OPTS\n opts,\n\n //ENV VARS IF PREFIXED WITH 'myApp_'\n\n cc.env('myApp_'), //myApp_foo = 'like this'\n\n //FILE NAMED BY ENV\n path.join(__dirname, 'config.' + env + '.json'),\n\n //IF `env` is PRODUCTION\n env === 'prod'\n ? path.join(__dirname, 'special.json') //load a special file\n : null //NULL IS IGNORED!\n\n //SUBDIR FOR ENV CONFIG\n path.join(__dirname, 'config', env, 'config.json'),\n\n //SEARCH PARENT DIRECTORIES FROM CURRENT DIR FOR FILE\n cc.find('config.json'),\n\n //PUT DEFAULTS LAST\n {\n host: 'localhost'\n port: 8000\n })\n\n var host = conf.get('host')\n\n // or\n\n var host = conf.store.host\n\n```\n\nFINALLY, EASY FLEXIBLE CONFIGURATIONS!\n\n##see also: [proto-list](https://github.com/isaacs/proto-list/)\n\nWHATS THAT YOU SAY?\n\nYOU WANT A \"CLASS\" SO THAT YOU CAN DO CRAYCRAY JQUERY CRAPS?\n\nEXTEND WITH YOUR OWN FUNCTIONALTY!?\n\n## CONFIGCHAIN LIVES TO SERVE ONLY YOU!\n\n```javascript\nvar cc = require('config-chain')\n\n// all the stuff you did before\nvar config = cc({\n some: 'object'\n },\n cc.find('config.json'),\n cc.env('myApp_')\n )\n // CONFIGS AS A SERVICE, aka \"CaaS\", aka EVERY DEVOPS DREAM OMG!\n .addUrl('http://configurator:1234/my-configs')\n // ASYNC FTW!\n .addFile('/path/to/file.json')\n\n // OBJECTS ARE OK TOO, they're SYNC but they still ORDER RIGHT\n // BECAUSE PROMISES ARE USED BUT NO, NOT *THOSE* PROMISES, JUST\n // ACTUAL PROMISES LIKE YOU MAKE TO YOUR MOM, KEPT OUT OF LOVE\n .add({ another: 'object' })\n\n // DIE A THOUSAND DEATHS IF THIS EVER HAPPENS!!\n .on('error', function (er) {\n // IF ONLY THERE WAS SOMETHIGN HARDER THAN THROW\n // MY SORROW COULD BE ADEQUATELY EXPRESSED. /o\\\n throw er\n })\n\n // THROW A PARTY IN YOUR FACE WHEN ITS ALL LOADED!!\n .on('load', function (config) {\n console.awesome('HOLY SHIT!')\n })\n```\n\n# BORING API DOCS\n\n## cc(...args)\n\nMAKE A CHAIN AND ADD ALL THE ARGS.\n\nIf the arg is a STRING, then it shall be a JSON FILENAME.\n\nSYNC I/O!\n\nRETURN THE CHAIN!\n\n## cc.json(...args)\n\nJoin the args INTO A JSON FILENAME!\n\nSYNC I/O!\n\n## cc.find(relativePath)\n\nSEEK the RELATIVE PATH by climbing the TREE OF DIRECTORIES.\n\nRETURN THE FOUND PATH!\n\nSYNC I/O!\n\n## cc.parse(content, file, type)\n\nParse the content string, and guess the type from either the\nspecified type or the filename.\n\nRETURN THE RESULTING OBJECT!\n\nNO I/O!\n\n## cc.env(prefix, env=process.env)\n\nGet all the keys on the provided env object (or process.env) which are\nprefixed by the specified prefix, and put the values on a new object.\n\nRETURN THE RESULTING OBJECT!\n\nNO I/O!\n\n## cc.ConfigChain()\n\nThe ConfigChain class for CRAY CRAY JQUERY STYLE METHOD CHAINING!\n\nOne of these is returned by the main exported function, as well.\n\nIt inherits (prototypically) from\n[ProtoList](https://github.com/isaacs/proto-list/), and also inherits\n(parasitically) from\n[EventEmitter](http://nodejs.org/api/events.html#events_class_events_eventemitter)\n\nIt has all the methods from both, and except where noted, they are\nunchanged.\n\n### LET IT BE KNOWN THAT chain IS AN INSTANCE OF ConfigChain.\n\n## chain.sources\n\nA list of all the places where it got stuff. The keys are the names\npassed to addFile or addUrl etc, and the value is an object with some\ninfo about the data source.\n\n## chain.addFile(filename, type, [name=filename])\n\nFilename is the name of the file. Name is an arbitrary string to be\nused later if you desire. Type is either 'ini' or 'json', and will\ntry to guess intelligently if omitted.\n\nLoaded files can be saved later.\n\n## chain.addUrl(url, type, [name=url])\n\nSame as the filename thing, but with a url.\n\nCan't be saved later.\n\n## chain.addEnv(prefix, env, [name='env'])\n\nAdd all the keys from the env object that start with the prefix.\n\n## chain.addString(data, file, type, [name])\n\nParse the string and add it to the set. (Mainly used internally.)\n\n## chain.add(object, [name])\n\nAdd the object to the set.\n\n## chain.root {Object}\n\nThe root from which all the other config objects in the set descend\nprototypically.\n\nPut your defaults here.\n\n## chain.set(key, value, name)\n\nSet the key to the value on the named config object. If name is\nunset, then set it on the first config object in the set. (That is,\nthe one with the highest priority, which was added first.)\n\n## chain.get(key, [name])\n\nGet the key from the named config object explicitly, or from the\nresolved configs if not specified.\n\n## chain.save(name, type)\n\nWrite the named config object back to its origin.\n\nCurrently only supported for env and file config types.\n\nFor files, encode the data according to the type.\n\n## chain.on('save', function () {})\n\nWhen one or more files are saved, emits `save` event when they're all\nsaved.\n\n## chain.on('load', function (chain) {})\n\nWhen the config chain has loaded all the specified files and urls and\nsuch, the 'load' event fires.\n",
- "readmeFilename": "readme.markdown",
- "bugs": {
- "url": "https://github.com/dominictarr/config-chain/issues"
- },
- "_id": "config-chain@1.1.8",
- "dist": {
- "shasum": "0943d0b7227213a20d4eaff4434f4a1c0a052cad",
- "tarball": "http://registry.npmjs.org/config-chain/-/config-chain-1.1.8.tgz"
- },
- "_from": "config-chain@>=1.1.8-0 <1.2.0-0",
- "_npmVersion": "1.3.6",
- "_npmUser": {
- "name": "dominictarr",
- "email": "dominic.tarr@gmail.com"
- },
- "maintainers": [
- {
- "name": "dominictarr",
- "email": "dominic.tarr@gmail.com"
- },
- {
- "name": "isaacs",
- "email": "i@izs.me"
- }
- ],
- "directories": {},
- "_shasum": "0943d0b7227213a20d4eaff4434f4a1c0a052cad",
- "_resolved": "https://registry.npmjs.org/config-chain/-/config-chain-1.1.8.tgz"
-}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/readme.markdown nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/readme.markdown
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/readme.markdown 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/readme.markdown 1970-01-01 00:00:00.000000000 +0000
@@ -1,228 +0,0 @@
-#config-chain
-
-USE THIS MODULE TO LOAD ALL YOUR CONFIGURATIONS
-
-``` js
-
- //npm install config-chain
-
- var cc = require('config-chain')
- , opts = require('optimist').argv //ALWAYS USE OPTIMIST FOR COMMAND LINE OPTIONS.
- , env = opts.env || process.env.YOUR_APP_ENV || 'dev' //SET YOUR ENV LIKE THIS.
-
- // EACH ARG TO CONFIGURATOR IS LOADED INTO CONFIGURATION CHAIN
- // EARLIER ITEMS OVERIDE LATER ITEMS
- // PUTS COMMAND LINE OPTS FIRST, AND DEFAULTS LAST!
-
- //strings are interpereted as filenames.
- //will be loaded synchronously
-
- var conf =
- cc(
- //OVERRIDE SETTINGS WITH COMMAND LINE OPTS
- opts,
-
- //ENV VARS IF PREFIXED WITH 'myApp_'
-
- cc.env('myApp_'), //myApp_foo = 'like this'
-
- //FILE NAMED BY ENV
- path.join(__dirname, 'config.' + env + '.json'),
-
- //IF `env` is PRODUCTION
- env === 'prod'
- ? path.join(__dirname, 'special.json') //load a special file
- : null //NULL IS IGNORED!
-
- //SUBDIR FOR ENV CONFIG
- path.join(__dirname, 'config', env, 'config.json'),
-
- //SEARCH PARENT DIRECTORIES FROM CURRENT DIR FOR FILE
- cc.find('config.json'),
-
- //PUT DEFAULTS LAST
- {
- host: 'localhost'
- port: 8000
- })
-
- var host = conf.get('host')
-
- // or
-
- var host = conf.store.host
-
-```
-
-FINALLY, EASY FLEXIBLE CONFIGURATIONS!
-
-##see also: [proto-list](https://github.com/isaacs/proto-list/)
-
-WHATS THAT YOU SAY?
-
-YOU WANT A "CLASS" SO THAT YOU CAN DO CRAYCRAY JQUERY CRAPS?
-
-EXTEND WITH YOUR OWN FUNCTIONALTY!?
-
-## CONFIGCHAIN LIVES TO SERVE ONLY YOU!
-
-```javascript
-var cc = require('config-chain')
-
-// all the stuff you did before
-var config = cc({
- some: 'object'
- },
- cc.find('config.json'),
- cc.env('myApp_')
- )
- // CONFIGS AS A SERVICE, aka "CaaS", aka EVERY DEVOPS DREAM OMG!
- .addUrl('http://configurator:1234/my-configs')
- // ASYNC FTW!
- .addFile('/path/to/file.json')
-
- // OBJECTS ARE OK TOO, they're SYNC but they still ORDER RIGHT
- // BECAUSE PROMISES ARE USED BUT NO, NOT *THOSE* PROMISES, JUST
- // ACTUAL PROMISES LIKE YOU MAKE TO YOUR MOM, KEPT OUT OF LOVE
- .add({ another: 'object' })
-
- // DIE A THOUSAND DEATHS IF THIS EVER HAPPENS!!
- .on('error', function (er) {
- // IF ONLY THERE WAS SOMETHIGN HARDER THAN THROW
- // MY SORROW COULD BE ADEQUATELY EXPRESSED. /o\
- throw er
- })
-
- // THROW A PARTY IN YOUR FACE WHEN ITS ALL LOADED!!
- .on('load', function (config) {
- console.awesome('HOLY SHIT!')
- })
-```
-
-# BORING API DOCS
-
-## cc(...args)
-
-MAKE A CHAIN AND ADD ALL THE ARGS.
-
-If the arg is a STRING, then it shall be a JSON FILENAME.
-
-SYNC I/O!
-
-RETURN THE CHAIN!
-
-## cc.json(...args)
-
-Join the args INTO A JSON FILENAME!
-
-SYNC I/O!
-
-## cc.find(relativePath)
-
-SEEK the RELATIVE PATH by climbing the TREE OF DIRECTORIES.
-
-RETURN THE FOUND PATH!
-
-SYNC I/O!
-
-## cc.parse(content, file, type)
-
-Parse the content string, and guess the type from either the
-specified type or the filename.
-
-RETURN THE RESULTING OBJECT!
-
-NO I/O!
-
-## cc.env(prefix, env=process.env)
-
-Get all the keys on the provided env object (or process.env) which are
-prefixed by the specified prefix, and put the values on a new object.
-
-RETURN THE RESULTING OBJECT!
-
-NO I/O!
-
-## cc.ConfigChain()
-
-The ConfigChain class for CRAY CRAY JQUERY STYLE METHOD CHAINING!
-
-One of these is returned by the main exported function, as well.
-
-It inherits (prototypically) from
-[ProtoList](https://github.com/isaacs/proto-list/), and also inherits
-(parasitically) from
-[EventEmitter](http://nodejs.org/api/events.html#events_class_events_eventemitter)
-
-It has all the methods from both, and except where noted, they are
-unchanged.
-
-### LET IT BE KNOWN THAT chain IS AN INSTANCE OF ConfigChain.
-
-## chain.sources
-
-A list of all the places where it got stuff. The keys are the names
-passed to addFile or addUrl etc, and the value is an object with some
-info about the data source.
-
-## chain.addFile(filename, type, [name=filename])
-
-Filename is the name of the file. Name is an arbitrary string to be
-used later if you desire. Type is either 'ini' or 'json', and will
-try to guess intelligently if omitted.
-
-Loaded files can be saved later.
-
-## chain.addUrl(url, type, [name=url])
-
-Same as the filename thing, but with a url.
-
-Can't be saved later.
-
-## chain.addEnv(prefix, env, [name='env'])
-
-Add all the keys from the env object that start with the prefix.
-
-## chain.addString(data, file, type, [name])
-
-Parse the string and add it to the set. (Mainly used internally.)
-
-## chain.add(object, [name])
-
-Add the object to the set.
-
-## chain.root {Object}
-
-The root from which all the other config objects in the set descend
-prototypically.
-
-Put your defaults here.
-
-## chain.set(key, value, name)
-
-Set the key to the value on the named config object. If name is
-unset, then set it on the first config object in the set. (That is,
-the one with the highest priority, which was added first.)
-
-## chain.get(key, [name])
-
-Get the key from the named config object explicitly, or from the
-resolved configs if not specified.
-
-## chain.save(name, type)
-
-Write the named config object back to its origin.
-
-Currently only supported for env and file config types.
-
-For files, encode the data according to the type.
-
-## chain.on('save', function () {})
-
-When one or more files are saved, emits `save` event when they're all
-saved.
-
-## chain.on('load', function (chain) {})
-
-When the config chain has loaded all the specified files and urls and
-such, the 'load' event fires.
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/test/broken.js nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/test/broken.js
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/test/broken.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/test/broken.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,10 +0,0 @@
-
-
-var cc = require('..')
-var assert = require('assert')
-
-
-//throw on invalid json
-assert.throws(function () {
- cc(__dirname + '/broken.json')
-})
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/test/broken.json nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/test/broken.json
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/test/broken.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/test/broken.json 1970-01-01 00:00:00.000000000 +0000
@@ -1,21 +0,0 @@
-{
- "name": "config-chain",
- "version": "0.3.0",
- "description": "HANDLE CONFIGURATION ONCE AND FOR ALL",
- "homepage": "http://github.com/dominictarr/config-chain",
- "repository": {
- "type": "git",
- "url": "https://github.com/dominictarr/config-chain.git"
- }
- //missing , and then this comment. this json is intensionally invalid
- "dependencies": {
- "proto-list": "1",
- "ini": "~1.0.2"
- },
- "bundleDependencies": ["ini"],
- "REM": "REMEMBER TO REMOVE BUNDLING WHEN/IF ISAACS MERGES ini#7",
- "author": "Dominic Tarr (http://dominictarr.com)",
- "scripts": {
- "test": "node test/find-file.js && node test/ini.js && node test/env.js"
- }
-}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/test/chain-class.js nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/test/chain-class.js
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/test/chain-class.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/test/chain-class.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,100 +0,0 @@
-var test = require('tap').test
-var CC = require('../index.js').ConfigChain
-
-var env = { foo_blaz : 'blzaa', foo_env : 'myenv' }
-var jsonObj = { blaz: 'json', json: true }
-var iniObj = { 'x.y.z': 'xyz', blaz: 'ini' }
-
-var fs = require('fs')
-var ini = require('ini')
-
-fs.writeFileSync('/tmp/config-chain-class.json', JSON.stringify(jsonObj))
-fs.writeFileSync('/tmp/config-chain-class.ini', ini.stringify(iniObj))
-
-var http = require('http')
-var reqs = 0
-http.createServer(function (q, s) {
- if (++reqs === 2) this.close()
- if (q.url === '/json') {
- // make sure that the requests come back from the server
- // out of order. they should still be ordered properly
- // in the resulting config object set.
- setTimeout(function () {
- s.setHeader('content-type', 'application/json')
- s.end(JSON.stringify({
- blaz: 'http',
- http: true,
- json: true
- }))
- }, 200)
- } else {
- s.setHeader('content-type', 'application/ini')
- s.end(ini.stringify({
- blaz: 'http',
- http: true,
- ini: true,
- json: false
- }))
- }
-}).listen(1337)
-
-test('basic class test', function (t) {
- var cc = new CC()
- var expectlist =
- [ { blaz: 'json', json: true },
- { 'x.y.z': 'xyz', blaz: 'ini' },
- { blaz: 'blzaa', env: 'myenv' },
- { blaz: 'http', http: true, json: true },
- { blaz: 'http', http: true, ini: true, json: false } ]
-
- cc.addFile('/tmp/config-chain-class.json')
- .addFile('/tmp/config-chain-class.ini')
- .addEnv('foo_', env)
- .addUrl('http://localhost:1337/json')
- .addUrl('http://localhost:1337/ini')
- .on('load', function () {
- t.same(cc.list, expectlist)
- t.same(cc.snapshot, { blaz: 'json',
- json: true,
- 'x.y.z': 'xyz',
- env: 'myenv',
- http: true,
- ini: true })
-
- cc.del('blaz', '/tmp/config-chain-class.json')
- t.same(cc.snapshot, { blaz: 'ini',
- json: true,
- 'x.y.z': 'xyz',
- env: 'myenv',
- http: true,
- ini: true })
- cc.del('blaz')
- t.same(cc.snapshot, { json: true,
- 'x.y.z': 'xyz',
- env: 'myenv',
- http: true,
- ini: true })
- cc.shift()
- t.same(cc.snapshot, { 'x.y.z': 'xyz',
- env: 'myenv',
- http: true,
- json: true,
- ini: true })
- cc.shift()
- t.same(cc.snapshot, { env: 'myenv',
- http: true,
- json: true,
- ini: true })
- cc.shift()
- t.same(cc.snapshot, { http: true,
- json: true,
- ini: true })
- cc.shift()
- t.same(cc.snapshot, { http: true,
- ini: true,
- json: false })
- cc.shift()
- t.same(cc.snapshot, {})
- t.end()
- })
-})
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/test/env.js nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/test/env.js
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/test/env.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/test/env.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,10 +0,0 @@
-var cc = require('..')
-var assert = require('assert')
-
-assert.deepEqual({
- hello: true
-}, cc.env('test_', {
- 'test_hello': true,
- 'ignore_this': 4,
- 'ignore_test_this_too': []
-}))
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/test/find-file.js nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/test/find-file.js
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/test/find-file.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/test/find-file.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,13 +0,0 @@
-
-var fs = require('fs')
- , assert = require('assert')
- , objx = {
- rand: Math.random()
- }
-
-fs.writeFileSync('/tmp/random-test-config.json', JSON.stringify(objx))
-
-var cc = require('../')
-var path = cc.find('tmp/random-test-config.json')
-
-assert.equal(path, '/tmp/random-test-config.json')
\ No newline at end of file
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/test/get.js nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/test/get.js
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/test/get.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/test/get.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,15 +0,0 @@
-var cc = require("../");
-
-var chain = cc()
- , name = "forFun";
-
-chain
- .add({
- __sample:"for fun only"
- }, name)
- .on("load", function() {
- //It throw exception here
- console.log(chain.get("__sample", name));
- //But if I drop the name param, it run normally and return as expected: "for fun only"
- //console.log(chain.get("__sample"));
- });
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/test/ignore-unfound-file.js nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/test/ignore-unfound-file.js
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/test/ignore-unfound-file.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/test/ignore-unfound-file.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,5 +0,0 @@
-
-var cc = require('..')
-
-//should not throw
-cc(__dirname, 'non_existing_file')
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/test/ini.js nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/test/ini.js
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/test/ini.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/test/ini.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,18 +0,0 @@
-
-
-var cc =require('..')
-var INI = require('ini')
-var assert = require('assert')
-
-function test(obj) {
-
- var _json, _ini
- var json = cc.parse (_json = JSON.stringify(obj))
- var ini = cc.parse (_ini = INI.stringify(obj))
-console.log(_ini, _json)
- assert.deepEqual(json, ini)
-}
-
-
-test({hello: true})
-
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/test/save.js nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/test/save.js
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/node_modules/config-chain/test/save.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/node_modules/config-chain/test/save.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,59 +0,0 @@
-var CC = require('../index.js').ConfigChain
-var test = require('tap').test
-
-var f1 = '/tmp/f1.ini'
-var f2 = '/tmp/f2.json'
-
-var ini = require('ini')
-
-var f1data = {foo: {bar: 'baz'}, bloo: 'jaus'}
-var f2data = {oof: {rab: 'zab'}, oolb: 'suaj'}
-
-var fs = require('fs')
-
-fs.writeFileSync(f1, ini.stringify(f1data), 'utf8')
-fs.writeFileSync(f2, JSON.stringify(f2data), 'utf8')
-
-test('test saving and loading ini files', function (t) {
- new CC()
- .add({grelb:'blerg'}, 'opt')
- .addFile(f1, 'ini', 'inifile')
- .addFile(f2, 'json', 'jsonfile')
- .on('load', function (cc) {
-
- t.same(cc.snapshot, { grelb: 'blerg',
- bloo: 'jaus',
- foo: { bar: 'baz' },
- oof: { rab: 'zab' },
- oolb: 'suaj' })
-
- t.same(cc.list, [ { grelb: 'blerg' },
- { bloo: 'jaus', foo: { bar: 'baz' } },
- { oof: { rab: 'zab' }, oolb: 'suaj' } ])
-
- cc.set('grelb', 'brelg', 'opt')
- .set('foo', 'zoo', 'inifile')
- .set('oof', 'ooz', 'jsonfile')
- .save('inifile')
- .save('jsonfile')
- .on('save', function () {
- t.equal(fs.readFileSync(f1, 'utf8'),
- "bloo = jaus\nfoo = zoo\n")
- t.equal(fs.readFileSync(f2, 'utf8'),
- "{\"oof\":\"ooz\",\"oolb\":\"suaj\"}")
-
- t.same(cc.snapshot, { grelb: 'brelg',
- bloo: 'jaus',
- foo: 'zoo',
- oof: 'ooz',
- oolb: 'suaj' })
-
- t.same(cc.list, [ { grelb: 'brelg' },
- { bloo: 'jaus', foo: 'zoo' },
- { oof: 'ooz', oolb: 'suaj' } ])
-
- t.pass('ok')
- t.end()
- })
- })
-})
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/npmconf.js nodejs-0.11.15/deps/npm/node_modules/npmconf/npmconf.js
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/npmconf.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/npmconf.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,414 +0,0 @@
-
-var CC = require('config-chain').ConfigChain
-var inherits = require('inherits')
-var configDefs = require('./config-defs.js')
-var types = configDefs.types
-var once = require('once')
-var fs = require('fs')
-var path = require('path')
-var nopt = require('nopt')
-var ini = require('ini')
-var Octal = configDefs.Octal
-var mkdirp = require('mkdirp')
-
-exports.load = load
-exports.Conf = Conf
-exports.loaded = false
-exports.rootConf = null
-exports.usingBuiltin = false
-exports.defs = configDefs
-
-Object.defineProperty(exports, 'defaults', { get: function () {
- return configDefs.defaults
-}, enumerable: true })
-
-Object.defineProperty(exports, 'types', { get: function () {
- return configDefs.types
-}, enumerable: true })
-
-exports.validate = validate
-
-var myUid = process.env.SUDO_UID !== undefined
- ? process.env.SUDO_UID : (process.getuid && process.getuid())
-var myGid = process.env.SUDO_GID !== undefined
- ? process.env.SUDO_GID : (process.getgid && process.getgid())
-
-
-var loading = false
-var loadCbs = []
-function load (cli_, builtin_, cb_) {
- var cli, builtin, cb
- for (var i = 0; i < arguments.length; i++)
- switch (typeof arguments[i]) {
- case 'string': builtin = arguments[i]; break
- case 'object': cli = arguments[i]; break
- case 'function': cb = arguments[i]; break
- }
-
- if (!cb)
- cb = function () {}
-
- if (exports.loaded) {
- var ret = exports.loaded
- if (cli) {
- ret = new Conf(ret)
- ret.unshift(cli)
- }
- return process.nextTick(cb.bind(null, null, ret))
- }
-
- // either a fresh object, or a clone of the passed in obj
- if (!cli)
- cli = {}
- else
- cli = Object.keys(cli).reduce(function (c, k) {
- c[k] = cli[k]
- return c
- }, {})
-
- loadCbs.push(cb)
- if (loading)
- return
-
- loading = true
-
- cb = once(function (er, conf) {
- if (!er)
- exports.loaded = conf
- loadCbs.forEach(function (fn) {
- fn(er, conf)
- })
- loadCbs.length = 0
- })
-
- // check for a builtin if provided.
- exports.usingBuiltin = !!builtin
- var rc = exports.rootConf = new Conf()
- if (builtin)
- rc.addFile(builtin, 'builtin')
- else
- rc.add({}, 'builtin')
-
- rc.on('load', function () {
- load_(builtin, rc, cli, cb)
- })
-}
-
-function load_(builtin, rc, cli, cb) {
- var defaults = configDefs.defaults
- var conf = new Conf(rc)
-
- conf.usingBuiltin = !!builtin
- conf.add(cli, 'cli')
- conf.addEnv()
-
- conf.loadPrefix(function(er) {
- if (er)
- return cb(er)
-
- // If you're doing `npm --userconfig=~/foo.npmrc` then you'd expect
- // that ~/.npmrc won't override the stuff in ~/foo.npmrc (or, indeed
- // be used at all).
- //
- // However, if the cwd is ~, then ~/.npmrc is the home for the project
- // config, and will override the userconfig.
- //
- // If you're not setting the userconfig explicitly, then it will be loaded
- // twice, which is harmless but excessive. If you *are* setting the
- // userconfig explicitly then it will override your explicit intent, and
- // that IS harmful and unexpected.
- //
- // Solution: Do not load project config file that is the same as either
- // the default or resolved userconfig value. npm will log a "verbose"
- // message about this when it happens, but it is a rare enough edge case
- // that we don't have to be super concerned about it.
- var projectConf = path.resolve(conf.localPrefix, '.npmrc')
- var defaultUserConfig = rc.get('userconfig')
- var resolvedUserConfig = conf.get('userconfig')
- if (!conf.get('global') &&
- projectConf !== defaultUserConfig &&
- projectConf !== resolvedUserConfig) {
- conf.addFile(projectConf, 'project')
- conf.once('load', afterPrefix)
- } else {
- conf.add({}, 'project')
- afterPrefix()
- }
- })
-
- function afterPrefix() {
- conf.addFile(conf.get('userconfig'), 'user')
- conf.once('error', cb)
- conf.once('load', afterUser)
- }
-
- function afterUser () {
- // globalconfig and globalignorefile defaults
- // need to respond to the 'prefix' setting up to this point.
- // Eg, `npm config get globalconfig --prefix ~/local` should
- // return `~/local/etc/npmrc`
- // annoying humans and their expectations!
- if (conf.get('prefix')) {
- var etc = path.resolve(conf.get('prefix'), 'etc')
- defaults.globalconfig = path.resolve(etc, 'npmrc')
- defaults.globalignorefile = path.resolve(etc, 'npmignore')
- }
-
- conf.addFile(conf.get('globalconfig'), 'global')
-
- // move the builtin into the conf stack now.
- conf.root = defaults
- conf.add(rc.shift(), 'builtin')
- conf.once('load', function () {
- conf.loadExtras(afterExtras)
- })
- }
-
- function afterExtras(er) {
- if (er)
- return cb(er)
-
- // warn about invalid bits.
- validate(conf)
-
- var cafile = conf.get('cafile')
-
- if (cafile) {
- return conf.loadCAFile(cafile, finalize)
- }
-
- finalize()
- }
-
- function finalize(er) {
- if (er) {
- return cb(er)
- }
-
- exports.loaded = conf
- cb(er, conf)
- }
-}
-
-// Basically the same as CC, but:
-// 1. Always ini
-// 2. Parses environment variable names in field values
-// 3. Field values that start with ~/ are replaced with process.env.HOME
-// 4. Can inherit from another Conf object, using it as the base.
-inherits(Conf, CC)
-function Conf (base) {
- if (!(this instanceof Conf))
- return new Conf(base)
-
- CC.apply(this)
-
- if (base)
- if (base instanceof Conf)
- this.root = base.list[0] || base.root
- else
- this.root = base
- else
- this.root = configDefs.defaults
-}
-
-Conf.prototype.loadPrefix = require('./lib/load-prefix.js')
-Conf.prototype.loadCAFile = require('./lib/load-cafile.js')
-Conf.prototype.loadUid = require('./lib/load-uid.js')
-Conf.prototype.setUser = require('./lib/set-user.js')
-Conf.prototype.findPrefix = require('./lib/find-prefix.js')
-Conf.prototype.getCredentialsByURI = require('./lib/get-credentials-by-uri.js')
-Conf.prototype.setCredentialsByURI = require('./lib/set-credentials-by-uri.js')
-
-Conf.prototype.loadExtras = function(cb) {
- this.setUser(function(er) {
- if (er)
- return cb(er)
- this.loadUid(function(er) {
- if (er)
- return cb(er)
- // Without prefix, nothing will ever work
- mkdirp(this.prefix, cb)
- }.bind(this))
- }.bind(this))
-}
-
-Conf.prototype.save = function (where, cb) {
- var target = this.sources[where]
- if (!target || !(target.path || target.source) || !target.data) {
- if (where !== 'builtin')
- var er = new Error('bad save target: ' + where)
- if (cb) {
- process.nextTick(cb.bind(null, er))
- return this
- }
- return this.emit('error', er)
- }
-
- if (target.source) {
- var pref = target.prefix || ''
- Object.keys(target.data).forEach(function (k) {
- target.source[pref + k] = target.data[k]
- })
- if (cb) process.nextTick(cb)
- return this
- }
-
- var data = ini.stringify(target.data)
-
- then = then.bind(this)
- done = done.bind(this)
- this._saving ++
-
- var mode = where === 'user' ? "0600" : "0666"
- if (!data.trim()) {
- fs.unlink(target.path, function (er) {
- // ignore the possible error (e.g. the file doesn't exist)
- done(null)
- })
- } else {
- mkdirp(path.dirname(target.path), function (er) {
- if (er)
- return then(er)
- fs.writeFile(target.path, data, 'utf8', function (er) {
- if (er)
- return then(er)
- if (where === 'user' && myUid && myGid)
- fs.chown(target.path, +myUid, +myGid, then)
- else
- then()
- })
- })
- }
-
- function then (er) {
- if (er)
- return done(er)
- fs.chmod(target.path, mode, done)
- }
-
- function done (er) {
- if (er) {
- if (cb) return cb(er)
- else return this.emit('error', er)
- }
- this._saving --
- if (this._saving === 0) {
- if (cb) cb()
- this.emit('save')
- }
- }
-
- return this
-}
-
-Conf.prototype.addFile = function (file, name) {
- name = name || file
- var marker = {__source__:name}
- this.sources[name] = { path: file, type: 'ini' }
- this.push(marker)
- this._await()
- fs.readFile(file, 'utf8', function (er, data) {
- if (er) // just ignore missing files.
- return this.add({}, marker)
- this.addString(data, file, 'ini', marker)
- }.bind(this))
- return this
-}
-
-// always ini files.
-Conf.prototype.parse = function (content, file) {
- return CC.prototype.parse.call(this, content, file, 'ini')
-}
-
-Conf.prototype.add = function (data, marker) {
- Object.keys(data).forEach(function (k) {
- data[k] = parseField(data[k], k)
- })
- return CC.prototype.add.call(this, data, marker)
-}
-
-Conf.prototype.addEnv = function (env) {
- env = env || process.env
- var conf = {}
- Object.keys(env)
- .filter(function (k) { return k.match(/^npm_config_/i) })
- .forEach(function (k) {
- if (!env[k])
- return
-
- // leave first char untouched, even if
- // it is a "_" - convert all other to "-"
- var p = k.toLowerCase()
- .replace(/^npm_config_/, '')
- .replace(/(?!^)_/g, '-')
- conf[p] = env[k]
- })
- return CC.prototype.addEnv.call(this, '', conf, 'env')
-}
-
-function parseField (f, k) {
- if (typeof f !== 'string' && !(f instanceof String))
- return f
-
- // type can be an array or single thing.
- var typeList = [].concat(types[k])
- var isPath = -1 !== typeList.indexOf(path)
- var isBool = -1 !== typeList.indexOf(Boolean)
- var isString = -1 !== typeList.indexOf(String)
- var isOctal = -1 !== typeList.indexOf(Octal)
- var isNumber = isOctal || (-1 !== typeList.indexOf(Number))
-
- f = (''+f).trim()
-
- if (f.match(/^".*"$/))
- f = JSON.parse(f)
-
- if (isBool && !isString && f === '')
- return true
-
- switch (f) {
- case 'true': return true
- case 'false': return false
- case 'null': return null
- case 'undefined': return undefined
- }
-
- f = envReplace(f)
-
- if (isPath) {
- var homePattern = process.platform === 'win32' ? /^~(\/|\\)/ : /^~\//
- if (f.match(homePattern) && process.env.HOME) {
- f = path.resolve(process.env.HOME, f.substr(2))
- }
- f = path.resolve(f)
- }
-
- if (isNumber && !isNaN(f))
- f = isOctal ? parseInt(f, 8) : +f
-
- return f
-}
-
-function envReplace (f) {
- if (typeof f !== 'string' || !f) return f
-
- // replace any ${ENV} values with the appropriate environ.
- var envExpr = /(\\*)\$\{([^}]+)\}/g
- return f.replace(envExpr, function (orig, esc, name) {
- esc = esc.length && esc.length % 2
- if (esc)
- return orig
- if (undefined === process.env[name])
- throw new Error('Failed to replace env in config: '+orig)
- return process.env[name]
- })
-}
-
-function validate (cl) {
- // warn about invalid configs at every level.
- cl.list.forEach(function (conf) {
- nopt.clean(conf, configDefs.types)
- })
-
- nopt.clean(cl.root, configDefs.types)
-}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/.npmignore nodejs-0.11.15/deps/npm/node_modules/npmconf/.npmignore
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/.npmignore 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/.npmignore 1970-01-01 00:00:00.000000000 +0000
@@ -1,3 +0,0 @@
-/test/fixtures/userconfig-with-gc
-.eslintrc
-.jshintrc
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/package.json nodejs-0.11.15/deps/npm/node_modules/npmconf/package.json
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/package.json 1970-01-01 00:00:00.000000000 +0000
@@ -1,71 +0,0 @@
-{
- "name": "npmconf",
- "version": "2.0.9",
- "description": "The config thing npm uses",
- "main": "npmconf.js",
- "directories": {
- "test": "test"
- },
- "dependencies": {
- "config-chain": "~1.1.8",
- "inherits": "~2.0.0",
- "ini": "^1.2.0",
- "mkdirp": "^0.5.0",
- "nopt": "~3.0.1",
- "once": "~1.3.0",
- "osenv": "^0.1.0",
- "semver": "2 || 3 || 4",
- "uid-number": "0.0.5"
- },
- "devDependencies": {
- "tap": "~0.4.0"
- },
- "scripts": {
- "test": "tap test/*.js"
- },
- "repository": {
- "type": "git",
- "url": "git://github.com/isaacs/npmconf"
- },
- "keywords": [
- "npm",
- "config",
- "config-chain",
- "conf",
- "ini"
- ],
- "author": {
- "name": "Isaac Z. Schlueter",
- "email": "i@izs.me",
- "url": "http://blog.izs.me"
- },
- "license": "BSD",
- "gitHead": "1f07a91b86f3bbba00967d7079dc6a456e746734",
- "bugs": {
- "url": "https://github.com/isaacs/npmconf/issues"
- },
- "homepage": "https://github.com/isaacs/npmconf",
- "_id": "npmconf@2.0.9",
- "_shasum": "5c87e5fb308104eceeca781e3d9115d216351ef2",
- "_from": "npmconf@>=2.0.8-0 <2.1.0-0",
- "_npmVersion": "2.0.0-beta.3",
- "_npmUser": {
- "name": "isaacs",
- "email": "i@izs.me"
- },
- "maintainers": [
- {
- "name": "isaacs",
- "email": "i@izs.me"
- },
- {
- "name": "othiym23",
- "email": "ogd@aoaioxxysz.net"
- }
- ],
- "dist": {
- "shasum": "5c87e5fb308104eceeca781e3d9115d216351ef2",
- "tarball": "http://registry.npmjs.org/npmconf/-/npmconf-2.0.9.tgz"
- },
- "_resolved": "https://registry.npmjs.org/npmconf/-/npmconf-2.0.9.tgz"
-}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/README.md nodejs-0.11.15/deps/npm/node_modules/npmconf/README.md
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/README.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/README.md 1970-01-01 00:00:00.000000000 +0000
@@ -1,33 +0,0 @@
-# npmconf
-
-The config thing npm uses
-
-If you are interested in interacting with the config settings that npm
-uses, then use this module.
-
-However, if you are writing a new Node.js program, and want
-configuration functionality similar to what npm has, but for your
-own thing, then I'd recommend using [rc](https://github.com/dominictarr/rc),
-which is probably what you want.
-
-If I were to do it all over again, that's what I'd do for npm. But,
-alas, there are many systems depending on many of the particulars of
-npm's configuration setup, so it's not worth the cost of changing.
-
-## USAGE
-
-```javascript
-var npmconf = require('npmconf')
-
-// pass in the cli options that you read from the cli
-// or whatever top-level configs you want npm to use for now.
-npmconf.load({some:'configs'}, function (er, conf) {
- // do stuff with conf
- conf.get('some', 'cli') // 'configs'
- conf.get('username') // 'joebobwhatevers'
- conf.set('foo', 'bar', 'user')
- conf.save('user', function (er) {
- // foo = bar is now saved to ~/.npmrc or wherever
- })
-})
-```
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/test/00-setup.js nodejs-0.11.15/deps/npm/node_modules/npmconf/test/00-setup.js
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/test/00-setup.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/test/00-setup.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,67 +0,0 @@
-var path = require('path')
-var userconfigSrc = path.resolve(__dirname, 'fixtures', 'userconfig')
-exports.userconfig = userconfigSrc + '-with-gc'
-exports.globalconfig = path.resolve(__dirname, 'fixtures', 'globalconfig')
-exports.builtin = path.resolve(__dirname, 'fixtures', 'builtin')
-exports.ucData =
- { globalconfig: exports.globalconfig,
- email: 'i@izs.me',
- 'env-thing': 'asdf',
- 'init.author.name': 'Isaac Z. Schlueter',
- 'init.author.email': 'i@izs.me',
- 'init.author.url': 'http://blog.izs.me/',
- 'init.version': '1.2.3',
- 'proprietary-attribs': false,
- 'npm:publishtest': true,
- '_npmjs.org:couch': 'https://admin:password@localhost:5984/registry',
- 'npm-www:nocache': '1',
- nodedir: '/Users/isaacs/dev/js/node-v0.8',
- 'sign-git-tag': true,
- message: 'v%s',
- 'strict-ssl': false,
- 'tmp': process.env.HOME + '/.tmp',
- _auth: 'dXNlcm5hbWU6cGFzc3dvcmQ=',
- _token:
- { AuthSession: 'yabba-dabba-doodle',
- version: '1',
- expires: '1345001053415',
- path: '/',
- httponly: true } }
-
-// set the userconfig in the env
-// unset anything else that npm might be trying to foist on us
-Object.keys(process.env).forEach(function (k) {
- if (k.match(/^npm_config_/i)) {
- delete process.env[k]
- }
-})
-process.env.npm_config_userconfig = exports.userconfig
-process.env.npm_config_other_env_thing = 1000
-process.env.random_env_var = 'asdf'
-process.env.npm_config__underbar_env_thing = 'underful'
-process.env.NPM_CONFIG_UPPERCASE_ENV_THING = 42
-
-exports.envData = {
- userconfig: exports.userconfig,
- '_underbar-env-thing': 'underful',
- 'uppercase-env-thing': '42',
- 'other-env-thing': '1000'
-}
-exports.envDataFix = {
- userconfig: exports.userconfig,
- '_underbar-env-thing': 'underful',
- 'uppercase-env-thing': 42,
- 'other-env-thing': 1000,
-}
-
-
-if (module === require.main) {
- // set the globalconfig in the userconfig
- var fs = require('fs')
- var uc = fs.readFileSync(userconfigSrc)
- var gcini = 'globalconfig = ' + exports.globalconfig + '\n'
- fs.writeFileSync(exports.userconfig, gcini + uc)
-
- console.log('0..1')
- console.log('ok 1 setup done')
-}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/test/basic.js nodejs-0.11.15/deps/npm/node_modules/npmconf/test/basic.js
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/test/basic.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/test/basic.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,58 +0,0 @@
-var test = require('tap').test
-var npmconf = require('../npmconf.js')
-var common = require('./00-setup.js')
-var path = require('path')
-
-var projectData = {}
-
-var ucData = common.ucData
-var envData = common.envData
-var envDataFix = common.envDataFix
-
-var gcData = { 'package-config:foo': 'boo' }
-
-var biData = {}
-
-var cli = { foo: 'bar', umask: 022 }
-
-var expectList =
-[ cli,
- envDataFix,
- projectData,
- ucData,
- gcData,
- biData ]
-
-var expectSources =
-{ cli: { data: cli },
- env:
- { data: envDataFix,
- source: envData,
- prefix: '' },
- project:
- { path: path.resolve(__dirname, '..', '.npmrc'),
- type: 'ini',
- data: projectData },
- user:
- { path: common.userconfig,
- type: 'ini',
- data: ucData },
- global:
- { path: common.globalconfig,
- type: 'ini',
- data: gcData },
- builtin: { data: biData } }
-
-test('no builtin', function (t) {
- npmconf.load(cli, function (er, conf) {
- if (er) throw er
- t.same(conf.list, expectList)
- t.same(conf.sources, expectSources)
- t.same(npmconf.rootConf.list, [])
- t.equal(npmconf.rootConf.root, npmconf.defs.defaults)
- t.equal(conf.root, npmconf.defs.defaults)
- t.equal(conf.get('umask'), 022)
- t.equal(conf.get('heading'), 'npm')
- t.end()
- })
-})
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/test/builtin.js nodejs-0.11.15/deps/npm/node_modules/npmconf/test/builtin.js
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/test/builtin.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/test/builtin.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,59 +0,0 @@
-var test = require('tap').test
-var npmconf = require('../npmconf.js')
-var common = require('./00-setup.js')
-var path = require('path')
-
-var ucData = common.ucData
-
-var envData = common.envData
-var envDataFix = common.envDataFix
-
-var gcData = { 'package-config:foo': 'boo' }
-
-var biData = { 'builtin-config': true }
-
-var cli = { foo: 'bar', heading: 'foo', 'git-tag-version': false }
-
-var projectData = {}
-
-var expectList =
-[ cli,
- envDataFix,
- projectData,
- ucData,
- gcData,
- biData ]
-
-var expectSources =
-{ cli: { data: cli },
- env:
- { data: envDataFix,
- source: envData,
- prefix: '' },
- project:
- { path: path.resolve(__dirname, '..', '.npmrc'),
- type: 'ini',
- data: projectData },
- user:
- { path: common.userconfig,
- type: 'ini',
- data: ucData },
- global:
- { path: common.globalconfig,
- type: 'ini',
- data: gcData },
- builtin: { data: biData } }
-
-test('with builtin', function (t) {
- npmconf.load(cli, common.builtin, function (er, conf) {
- if (er) throw er
- t.same(conf.list, expectList)
- t.same(conf.sources, expectSources)
- t.same(npmconf.rootConf.list, [])
- t.equal(npmconf.rootConf.root, npmconf.defs.defaults)
- t.equal(conf.root, npmconf.defs.defaults)
- t.equal(conf.get('heading'), 'foo')
- t.equal(conf.get('git-tag-version'), false)
- t.end()
- })
-})
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/test/certfile.js nodejs-0.11.15/deps/npm/node_modules/npmconf/test/certfile.js
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/test/certfile.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/test/certfile.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,17 +0,0 @@
-var test = require('tap').test
-var npmconf = require('../npmconf.js')
-var common = require('./00-setup.js')
-var path = require('path')
-var fs = require('fs')
-
-test('cafile loads as ca', function (t) {
- var cafile = path.join(__dirname, 'fixtures', 'multi-ca')
-
- npmconf.load({cafile: cafile}, function (er, conf) {
- if (er) throw er
-
- t.same(conf.get('cafile'), cafile)
- t.same(conf.get('ca').join('\n'), fs.readFileSync(cafile, 'utf8').trim())
- t.end()
- })
-})
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/test/credentials.js nodejs-0.11.15/deps/npm/node_modules/npmconf/test/credentials.js
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/test/credentials.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/test/credentials.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,166 +0,0 @@
-var test = require("tap").test
-
-var npmconf = require("../npmconf.js")
-var common = require("./00-setup.js")
-
-var URI = "https://registry.lvh.me:8661/"
-
-test("getting scope with no credentials set", function (t) {
- npmconf.load({}, function (er, conf) {
- t.ifError(er, "configuration loaded")
-
- var basic = conf.getCredentialsByURI(URI)
- t.equal(basic.scope, "//registry.lvh.me:8661/", "nerfed URL extracted")
-
- t.end()
- })
-})
-
-test("trying to set credentials with no URI", function (t) {
- npmconf.load(common.builtin, function (er, conf) {
- t.ifError(er, "configuration loaded")
-
- t.throws(function () {
- conf.setCredentialsByURI()
- }, "enforced missing URI")
-
- t.end()
- })
-})
-
-test("set with missing credentials object", function (t) {
- npmconf.load(common.builtin, function (er, conf) {
- t.ifError(er, "configuration loaded")
-
- t.throws(function () {
- conf.setCredentialsByURI(URI)
- }, "enforced missing credentials")
-
- t.end()
- })
-})
-
-test("set with empty credentials object", function (t) {
- npmconf.load(common.builtin, function (er, conf) {
- t.ifError(er, "configuration loaded")
-
- t.throws(function () {
- conf.setCredentialsByURI(URI, {})
- }, "enforced missing credentials")
-
- t.end()
- })
-})
-
-test("set with token", function (t) {
- npmconf.load(common.builtin, function (er, conf) {
- t.ifError(er, "configuration loaded")
-
- t.doesNotThrow(function () {
- conf.setCredentialsByURI(URI, {token : "simple-token"})
- }, "needs only token")
-
- var expected = {
- scope : "//registry.lvh.me:8661/",
- token : "simple-token"
- }
-
- t.same(conf.getCredentialsByURI(URI), expected, "got bearer token and scope")
-
- t.end()
- })
-})
-
-test("set with missing username", function (t) {
- npmconf.load(common.builtin, function (er, conf) {
- t.ifError(er, "configuration loaded")
-
- var credentials = {
- password : "password",
- email : "ogd@aoaioxxysz.net"
- }
-
- t.throws(function () {
- conf.setCredentialsByURI(URI, credentials)
- }, "enforced missing email")
-
- t.end()
- })
-})
-
-test("set with missing password", function (t) {
- npmconf.load(common.builtin, function (er, conf) {
- t.ifError(er, "configuration loaded")
-
- var credentials = {
- username : "username",
- email : "ogd@aoaioxxysz.net"
- }
-
- t.throws(function () {
- conf.setCredentialsByURI(URI, credentials)
- }, "enforced missing email")
-
- t.end()
- })
-})
-
-test("set with missing email", function (t) {
- npmconf.load(common.builtin, function (er, conf) {
- t.ifError(er, "configuration loaded")
-
- var credentials = {
- username : "username",
- password : "password"
- }
-
- t.throws(function () {
- conf.setCredentialsByURI(URI, credentials)
- }, "enforced missing email")
-
- t.end()
- })
-})
-
-test("set with old-style credentials", function (t) {
- npmconf.load(common.builtin, function (er, conf) {
- t.ifError(er, "configuration loaded")
-
- var credentials = {
- username : "username",
- password : "password",
- email : "ogd@aoaioxxysz.net"
- }
-
- t.doesNotThrow(function () {
- conf.setCredentialsByURI(URI, credentials)
- }, "requires all of username, password, and email")
-
- var expected = {
- scope : "//registry.lvh.me:8661/",
- username : "username",
- password : "password",
- email : "ogd@aoaioxxysz.net",
- auth : "dXNlcm5hbWU6cGFzc3dvcmQ="
- }
-
- t.same(conf.getCredentialsByURI(URI), expected, "got credentials")
-
- t.end()
- })
-})
-
-test("get old-style credentials for default registry", function (t) {
- npmconf.load(common.builtin, function (er, conf) {
- var actual = conf.getCredentialsByURI(conf.get("registry"))
- var expected = {
- scope: '//registry.npmjs.org/',
- password: 'password',
- username: 'username',
- email: 'i@izs.me',
- auth: 'dXNlcm5hbWU6cGFzc3dvcmQ='
- }
- t.same(actual, expected)
- t.end()
- })
-})
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/test/fixtures/builtin nodejs-0.11.15/deps/npm/node_modules/npmconf/test/fixtures/builtin
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/test/fixtures/builtin 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/test/fixtures/builtin 1970-01-01 00:00:00.000000000 +0000
@@ -1 +0,0 @@
-builtin-config = true
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/test/fixtures/globalconfig nodejs-0.11.15/deps/npm/node_modules/npmconf/test/fixtures/globalconfig
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/test/fixtures/globalconfig 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/test/fixtures/globalconfig 1970-01-01 00:00:00.000000000 +0000
@@ -1 +0,0 @@
-package-config:foo = boo
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/test/fixtures/multi-ca nodejs-0.11.15/deps/npm/node_modules/npmconf/test/fixtures/multi-ca
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/test/fixtures/multi-ca 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/test/fixtures/multi-ca 1970-01-01 00:00:00.000000000 +0000
@@ -1,32 +0,0 @@
------BEGIN CERTIFICATE-----
-MIICjTCCAfigAwIBAgIEMaYgRzALBgkqhkiG9w0BAQQwRTELMAkGA1UEBhMCVVMx
-NjA0BgNVBAoTLU5hdGlvbmFsIEFlcm9uYXV0aWNzIGFuZCBTcGFjZSBBZG1pbmlz
-dHJhdGlvbjAmFxE5NjA1MjgxMzQ5MDUrMDgwMBcROTgwNTI4MTM0OTA1KzA4MDAw
-ZzELMAkGA1UEBhMCVVMxNjA0BgNVBAoTLU5hdGlvbmFsIEFlcm9uYXV0aWNzIGFu
-ZCBTcGFjZSBBZG1pbmlzdHJhdGlvbjEgMAkGA1UEBRMCMTYwEwYDVQQDEwxTdGV2
-ZSBTY2hvY2gwWDALBgkqhkiG9w0BAQEDSQAwRgJBALrAwyYdgxmzNP/ts0Uyf6Bp
-miJYktU/w4NG67ULaN4B5CnEz7k57s9o3YY3LecETgQ5iQHmkwlYDTL2fTgVfw0C
-AQOjgaswgagwZAYDVR0ZAQH/BFowWDBWMFQxCzAJBgNVBAYTAlVTMTYwNAYDVQQK
-Ey1OYXRpAAAAACBBZXJvbmF1dGljcyBhbmQgU3BhY2UgQWRtaW5pc3RyYXRpb24x
-DTALBgNVBAMTBENSTDEwFwYDVR0BAQH/BA0wC4AJODMyOTcwODEwMBgGA1UdAgQR
-MA8ECTgzMjk3MDgyM4ACBSAwDQYDVR0KBAYwBAMCBkAwCwYJKoZIhvcNAQEEA4GB
-AH2y1VCEw/A4zaXzSYZJTTUi3uawbbFiS2yxHvgf28+8Js0OHXk1H1w2d6qOHH21
-X82tZXd/0JtG0g1T9usFFBDvYK8O0ebgz/P5ELJnBL2+atObEuJy1ZZ0pBDWINR3
-WkDNLCGiTkCKp0F5EWIrVDwh54NNevkCQRZita+z4IBO
------END CERTIFICATE-----
------BEGIN CERTIFICATE-----
-AAAAAACCAfigAwIBAgIEMaYgRzALBgkqhkiG9w0BAQQwRTELMAkGA1UEBhMCVVMx
-NjA0BgNVBAoTLU5hdGlvbmFsIEFlcm9uYXV0aWNzIGFuZCBTcGFjZSBBZG1pbmlz
-dHJhdGlvbjAmFxE5NjA1MjgxMzQ5MDUrMDgwMBcROTgwNTI4MTM0OTA1KzA4MDAw
-ZzELMAkGA1UEBhMCVVMxNjA0BgNVBAoTLU5hdGlvbmFsIEFlcm9uYXV0aWNzIGFu
-ZCBTcGFjZSBBZG1pbmlzdHJhdGlvbjEgMAkGA1UEBRMCMTYwEwYDVQQDEwxTdGV2
-ZSBTY2hvY2gwWDALBgkqhkiG9w0BAQEDSQAwRgJBALrAwyYdgxmzNP/ts0Uyf6Bp
-miJYktU/w4NG67ULaN4B5CnEz7k57s9o3YY3LecETgQ5iQHmkwlYDTL2fTgVfw0C
-AQOjgaswgagwZAYDVR0ZAQH/BFowWDBWMFQxCzAJBgNVBAYTAlVTMTYwNAYDVQQK
-Ey1OYXRpb25hbCBBZXJvbmF1dGljcyBhbmQgU3BhY2UgQWRtaW5pc3RyYXRpb24x
-DTALBgNVBAMTBENSTDEwFwYDVR0BAQH/BA0wC4AJODMyOTcwODEwMBgGA1UdAgQR
-MA8ECTgzMjk3MDgyM4ACBSAwDQYDVR0KBAYwBAMCBkAwCwYJKoZIhvcNAQEEA4GB
-AH2y1VCEw/A4zaXzSYZJTTUi3uawbbFiS2yxHvgf28+8Js0OHXk1H1w2d6qOHH21
-X82tZXd/0JtG0g1T9usFFBDvYK8O0ebgz/P5ELJnBL2+atObEuJy1ZZ0pBDWINR3
-WkDNLCGiTkCKp0F5EWIrVDwh54NNevkCQRZita+z4IBO
------END CERTIFICATE-----
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/test/fixtures/.npmrc nodejs-0.11.15/deps/npm/node_modules/npmconf/test/fixtures/.npmrc
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/test/fixtures/.npmrc 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/test/fixtures/.npmrc 1970-01-01 00:00:00.000000000 +0000
@@ -1 +0,0 @@
-just = testing
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/test/fixtures/userconfig nodejs-0.11.15/deps/npm/node_modules/npmconf/test/fixtures/userconfig
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/test/fixtures/userconfig 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/test/fixtures/userconfig 1970-01-01 00:00:00.000000000 +0000
@@ -1,23 +0,0 @@
-email = i@izs.me
-env-thing = ${random_env_var}
-init.author.name = Isaac Z. Schlueter
-init.author.email = i@izs.me
-init.author.url = http://blog.izs.me/
-init.version = 1.2.3
-proprietary-attribs = false
-npm:publishtest = true
-_npmjs.org:couch = https://admin:password@localhost:5984/registry
-npm-www:nocache = 1
-nodedir = /Users/isaacs/dev/js/node-v0.8
-sign-git-tag = true
-message = v%s
-strict-ssl = false
-tmp = ~/.tmp
-_auth = dXNlcm5hbWU6cGFzc3dvcmQ=
-
-[_token]
-AuthSession = yabba-dabba-doodle
-version = 1
-expires = 1345001053415
-path = /
-httponly = true
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/test/project.js nodejs-0.11.15/deps/npm/node_modules/npmconf/test/project.js
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/test/project.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/test/project.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,60 +0,0 @@
-var test = require('tap').test
-var npmconf = require('../npmconf.js')
-var common = require('./00-setup.js')
-var path = require('path')
-var fix = path.resolve(__dirname, 'fixtures')
-var projectRc = path.resolve(fix, '.npmrc')
-
-var projectData = { just: 'testing' }
-
-var ucData = common.ucData
-var envData = common.envData
-var envDataFix = common.envDataFix
-
-var gcData = { 'package-config:foo': 'boo' }
-
-var biData = {}
-
-var cli = { foo: 'bar', umask: 022, prefix: fix }
-
-var expectList =
-[ cli,
- envDataFix,
- projectData,
- ucData,
- gcData,
- biData ]
-
-var expectSources =
-{ cli: { data: cli },
- env:
- { data: envDataFix,
- source: envData,
- prefix: '' },
- project:
- { path: projectRc,
- type: 'ini',
- data: projectData },
- user:
- { path: common.userconfig,
- type: 'ini',
- data: ucData },
- global:
- { path: common.globalconfig,
- type: 'ini',
- data: gcData },
- builtin: { data: biData } }
-
-test('no builtin', function (t) {
- npmconf.load(cli, function (er, conf) {
- if (er) throw er
- t.same(conf.list, expectList)
- t.same(conf.sources, expectSources)
- t.same(npmconf.rootConf.list, [])
- t.equal(npmconf.rootConf.root, npmconf.defs.defaults)
- t.equal(conf.root, npmconf.defs.defaults)
- t.equal(conf.get('umask'), 022)
- t.equal(conf.get('heading'), 'npm')
- t.end()
- })
-})
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/test/save.js nodejs-0.11.15/deps/npm/node_modules/npmconf/test/save.js
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/test/save.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/test/save.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,84 +0,0 @@
-var test = require('tap').test
-var npmconf = require('../npmconf.js')
-var common = require('./00-setup.js')
-var fs = require('fs')
-var ini = require('ini')
-var expectConf =
- [ 'globalconfig = ' + common.globalconfig,
- 'email = i@izs.me',
- 'env-thing = asdf',
- 'init.author.name = Isaac Z. Schlueter',
- 'init.author.email = i@izs.me',
- 'init.author.url = http://blog.izs.me/',
- 'init.version = 1.2.3',
- 'proprietary-attribs = false',
- 'npm:publishtest = true',
- '_npmjs.org:couch = https://admin:password@localhost:5984/registry',
- 'npm-www:nocache = 1',
- 'sign-git-tag = false',
- 'message = v%s',
- 'strict-ssl = false',
- '_auth = dXNlcm5hbWU6cGFzc3dvcmQ=',
- '',
- '[_token]',
- 'AuthSession = yabba-dabba-doodle',
- 'version = 1',
- 'expires = 1345001053415',
- 'path = /',
- 'httponly = true',
- '' ].join('\n')
-var expectFile =
- [ 'globalconfig = ' + common.globalconfig,
- 'email = i@izs.me',
- 'env-thing = asdf',
- 'init.author.name = Isaac Z. Schlueter',
- 'init.author.email = i@izs.me',
- 'init.author.url = http://blog.izs.me/',
- 'init.version = 1.2.3',
- 'proprietary-attribs = false',
- 'npm:publishtest = true',
- '_npmjs.org:couch = https://admin:password@localhost:5984/registry',
- 'npm-www:nocache = 1',
- 'sign-git-tag = false',
- 'message = v%s',
- 'strict-ssl = false',
- '_auth = dXNlcm5hbWU6cGFzc3dvcmQ=',
- '',
- '[_token]',
- 'AuthSession = yabba-dabba-doodle',
- 'version = 1',
- 'expires = 1345001053415',
- 'path = /',
- 'httponly = true',
- '' ].join('\n')
-
-test('saving configs', function (t) {
- npmconf.load(function (er, conf) {
- if (er)
- throw er
- conf.set('sign-git-tag', false, 'user')
- conf.del('nodedir')
- conf.del('tmp')
- var foundConf = ini.stringify(conf.sources.user.data)
- t.same(ini.parse(foundConf), ini.parse(expectConf))
- fs.unlinkSync(common.userconfig)
- conf.save('user', function (er) {
- if (er)
- throw er
- var uc = fs.readFileSync(conf.get('userconfig'), 'utf8')
- t.same(ini.parse(uc), ini.parse(expectFile))
- t.end()
- })
- })
-})
-
-test('setting prefix', function (t) {
- npmconf.load(function (er, conf) {
- if (er)
- throw er
-
- conf.prefix = 'newvalue'
- t.same(conf.prefix, 'newvalue');
- t.end();
- })
-})
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npmconf/test/semver-tag.js nodejs-0.11.15/deps/npm/node_modules/npmconf/test/semver-tag.js
--- nodejs-0.11.14/deps/npm/node_modules/npmconf/test/semver-tag.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npmconf/test/semver-tag.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,65 +0,0 @@
-var test = require('tap').test
-var npmconf = require('../npmconf.js')
-var common = require('./00-setup.js')
-var path = require('path')
-
-var ucData = common.ucData
-
-var envData = common.envData
-var envDataFix = common.envDataFix
-
-var gcData = { 'package-config:foo': 'boo' }
-
-var biData = { 'builtin-config': true }
-
-var cli = { tag: 'v2.x' }
-
-var projectData = {}
-
-var expectList =
-[ cli,
- envDataFix,
- projectData,
- ucData,
- gcData,
- biData ]
-
-
-var expectSources =
-{ cli: { data: cli },
- env:
- { data: envDataFix,
- source: envData,
- prefix: '' },
- project:
- { path: path.resolve(__dirname, '..', '.npmrc'),
- type: 'ini',
- data: projectData },
- user:
- { path: common.userconfig,
- type: 'ini',
- data: ucData },
- global:
- { path: common.globalconfig,
- type: 'ini',
- data: gcData },
- builtin: { data: biData } }
-
-test('tag cannot be a SemVer', function (t) {
- var messages = []
- console.warn = function (m) {
- messages.push(m)
- }
-
- var expect = [
- 'invalid config tag="v2.x"',
- 'invalid config Tag must not be a SemVer range'
- ]
-
- npmconf.load(cli, common.builtin, function (er, conf) {
- if (er) throw er
- t.equal(conf.get('tag'), 'latest')
- t.same(messages, expect)
- t.end()
- })
-})
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npm-package-arg/package.json nodejs-0.11.15/deps/npm/node_modules/npm-package-arg/package.json
--- nodejs-0.11.14/deps/npm/node_modules/npm-package-arg/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npm-package-arg/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -1,13 +1,13 @@
{
"name": "npm-package-arg",
- "version": "2.1.2",
+ "version": "2.1.3",
"description": "Parse the things that can be arguments to `npm install`",
"main": "npa.js",
"directories": {
"test": "test"
},
"dependencies": {
- "semver": "^2.3.0 || 3.x || 4"
+ "semver": "4"
},
"devDependencies": {
"tap": "^0.4.9"
@@ -31,8 +31,8 @@
"homepage": "https://github.com/npm/npm-package-arg",
"readme": "# npm-package-arg\n\nParse the things that can be arguments to `npm install`\n\nTakes an argument like `foo@1.2`, or `foo@user/foo`, or\n`http://x.com/foo.tgz`, or `git+https://github.com/user/foo`, and\nfigures out what type of thing it is.\n\n## USAGE\n\n```javascript\nvar assert = require(\"assert\")\nvar npa = require(\"npm-package-arg\")\n\n// Pass in the descriptor, and it'll return an object\nvar parsed = npa(\"foo@1.2\")\n\n// Returns an object like:\n// {\n// name: \"foo\", // The bit in front of the @\n// type: \"range\", // the type of descriptor this is\n// spec: \"1.2\" // the specifier for this descriptor\n// }\n\n// Completely unreasonable invalid garbage throws an error\n// Make sure you wrap this in a try/catch if you have not\n// already sanitized the inputs!\nassert.throws(function() {\n npa(\"this is not \\0 a valid package name or url\")\n})\n```\n\nFor more examples, see the test file.\n\n## Result Objects\n\nThe objects that are returned by npm-package-arg contain the following\nfields:\n\n* `name` - If known, the `name` field expected in the resulting pkg.\n* `type` - One of the following strings:\n * `git` - A git repo\n * `github` - A github shorthand, like `user/project`\n * `tag` - A tagged version, like `\"foo@latest\"`\n * `version` - A specific version number, like `\"foo@1.2.3\"`\n * `range` - A version range, like `\"foo@2.x\"`\n * `local` - A local file or folder path\n * `remote` - An http url (presumably to a tgz)\n* `spec` - The \"thing\". URL, the range, git repo, etc.\n* `raw` - The original un-modified string that was provided.\n* `rawSpec` - The part after the `name@...`, as it was originally\n provided.\n* `scope` - If a name is something like `@org/module` then the `scope`\n field will be set to `org`. If it doesn't have a scoped name, then\n scope is `null`.\n",
"readmeFilename": "README.md",
- "gitHead": "ebb3c5ee4c362aca5722cf805adf871f86b5c4f2",
- "_id": "npm-package-arg@2.1.2",
- "_shasum": "14f9be32e203a77977dd8120cf749d0db8c93761",
- "_from": "npm-package-arg@>=2.1.2 <2.2.0"
+ "gitHead": "9aaabc2aae746371a05f54cdb57a5f9ada003d8f",
+ "_id": "npm-package-arg@2.1.3",
+ "_shasum": "dfba34bd82dd327c10cb43a65c8db6ef0b812bf7",
+ "_from": "npm-package-arg@~2.1.3"
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npm-package-arg/test/basic.js nodejs-0.11.15/deps/npm/node_modules/npm-package-arg/test/basic.js
--- nodejs-0.11.14/deps/npm/node_modules/npm-package-arg/test/basic.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npm-package-arg/test/basic.js 2015-01-20 21:22:17.000000000 +0000
@@ -8,7 +8,7 @@
"foo@1.2": {
name: "foo",
type: "range",
- spec: ">=1.2.0-0 <1.3.0-0",
+ spec: ">=1.2.0 <1.3.0",
raw: "foo@1.2",
rawSpec: "1.2"
},
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npm-registry-client/lib/fetch.js nodejs-0.11.15/deps/npm/node_modules/npm-registry-client/lib/fetch.js
--- nodejs-0.11.14/deps/npm/node_modules/npm-registry-client/lib/fetch.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npm-registry-client/lib/fetch.js 2015-01-20 21:22:17.000000000 +0000
@@ -69,7 +69,11 @@
var parsed = url.parse(remote)
this.log.http("fetch", "GET", parsed.href)
- var er = this.authify(this.conf.get("always-auth"), parsed, headers)
+ var er = this.authify(
+ this.conf.getCredentialsByURI(remote).alwaysAuth,
+ parsed,
+ headers
+ )
if (er) return cb(er)
var opts = this.initialize(
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npm-registry-client/lib/request.js nodejs-0.11.15/deps/npm/node_modules/npm-registry-client/lib/request.js
--- nodejs-0.11.14/deps/npm/node_modules/npm-registry-client/lib/request.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npm-registry-client/lib/request.js 2015-01-20 21:22:17.000000000 +0000
@@ -44,7 +44,8 @@
, isUserChange = where.match(adduserChange)
, adduserNew = /^\/?-\/user\/org\.couchdb\.user:([^\/]+)$/
, isNewUser = where.match(adduserNew)
- , alwaysAuth = this.conf.get("always-auth")
+ , registry = url.format(parsed)
+ , alwaysAuth = this.conf.getCredentialsByURI(registry).alwaysAuth
, isDelete = method === "DELETE"
, isWrite = what || isDelete
@@ -70,9 +71,7 @@
}).join("/")
if (q) where += "?" + q
- var registry = url.format(parsed)
this.log.verbose("request", "resolving registry", [registry, where])
-
where = url.resolve(registry, where)
this.log.verbose("request", "after pass 2, where is", where)
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npm-registry-client/package.json nodejs-0.11.15/deps/npm/node_modules/npm-registry-client/package.json
--- nodejs-0.11.14/deps/npm/node_modules/npm-registry-client/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npm-registry-client/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -6,7 +6,7 @@
},
"name": "npm-registry-client",
"description": "Client for the npm registry",
- "version": "3.2.1",
+ "version": "3.2.4",
"repository": {
"url": "git://github.com/isaacs/npm-registry-client"
},
@@ -22,7 +22,7 @@
"npm-cache-filename": "^1.0.0",
"once": "^1.3.0",
"request": "2 >=2.25.0",
- "retry": "0.6.0",
+ "retry": "^0.6.1",
"rimraf": "2",
"semver": "2 >=2.2.1 || 3.x || 4",
"slide": "^1.1.3",
@@ -30,6 +30,7 @@
},
"devDependencies": {
"concat-stream": "^1.4.6",
+ "npmconf": "^2.1.0",
"tap": ""
},
"optionalDependencies": {
@@ -38,12 +39,12 @@
"license": "ISC",
"readme": "# npm-registry-client\n\nThe code that npm uses to talk to the registry.\n\nIt handles all the caching and HTTP calls.\n\n## Usage\n\n```javascript\nvar RegClient = require('npm-registry-client')\nvar client = new RegClient(config)\nvar uri = \"npm://registry.npmjs.org/npm\"\nvar options = {timeout: 1000}\n\nclient.get(uri, options, function (error, data, raw, res) {\n // error is an error if there was a problem.\n // data is the parsed data object\n // raw is the json string\n // res is the response from couch\n})\n```\n\n# Registry URLs\n\nThe registry calls take either a full URL pointing to a resource in the\nregistry, or a base URL for the registry as a whole (for the base URL, any path\nwill be ignored). In addition to `http` and `https`, `npm` URLs are allowed.\n`npm` URLs are `https` URLs with the additional restrictions that they will\nalways include authorization credentials, and the response is always registry\nmetadata (and not tarballs or other attachments).\n\n# Configuration\n\nThis program is designed to work with\n[npmconf](https://npmjs.org/package/npmconf), but you can also pass in\na plain-jane object with the appropriate configs, and it'll shim it\nfor you. Any configuration thingie that has get/set/del methods will\nalso be accepted.\n\n* `cache` **Required** {String} Path to the cache folder\n* `always-auth` {Boolean} Auth even for GET requests.\n* `auth` {String} A base64-encoded `username:password`\n* `email` {String} User's email address\n* `tag` {String} The default tag to use when publishing new packages.\n Default = `\"latest\"`\n* `ca` {String} Cerficate signing authority certificates to trust.\n* `cert` {String} Client certificate (PEM encoded). Enable access\n to servers that require client certificates\n* `key` {String} Private key (PEM encoded) for client certificate 'cert'\n* `strict-ssl` {Boolean} Whether or not to be strict with SSL\n certificates. Default = `true`\n* `user-agent` {String} User agent header to send. Default =\n `\"node/{process.version} {process.platform} {process.arch}\"`\n* `log` {Object} The logger to use. Defaults to `require(\"npmlog\")` if\n that works, otherwise logs are disabled.\n* `fetch-retries` {Number} Number of times to retry on GET failures.\n Default=2\n* `fetch-retry-factor` {Number} `factor` setting for `node-retry`. Default=10\n* `fetch-retry-mintimeout` {Number} `minTimeout` setting for `node-retry`.\n Default=10000 (10 seconds)\n* `fetch-retry-maxtimeout` {Number} `maxTimeout` setting for `node-retry`.\n Default=60000 (60 seconds)\n* `proxy` {URL} The url to proxy requests through.\n* `https-proxy` {URL} The url to proxy https requests through.\n Defaults to be the same as `proxy` if unset.\n* `_auth` {String} The base64-encoded authorization header.\n* `username` `_password` {String} Username/password to use to generate\n `_auth` if not supplied.\n* `_token` {Object} A token for use with\n [couch-login](https://npmjs.org/package/couch-login)\n\n# client.request(method, uri, options, cb)\n\n* `method` {String} HTTP method\n* `uri` {String} URI pointing to the resource to request\n* `options` {Object} Object containing optional per-request properties.\n * `what` {Stream | Buffer | String | Object} The request body. Objects\n that are not Buffers or Streams are encoded as JSON.\n * `etag` {String} The cached ETag\n * `follow` {Boolean} Follow 302/301 responses (defaults to true)\n* `cb` {Function}\n * `error` {Error | null}\n * `data` {Object} the parsed data object\n * `raw` {String} the json\n * `res` {Response Object} response from couch\n\nMake a request to the registry. All the other methods are wrappers around\n`request`.\n\n# client.adduser(base, username, password, email, cb)\n\n* `base` {String} Base registry URL\n* `username` {String}\n* `password` {String}\n* `email` {String}\n* `cb` {Function}\n\nAdd a user account to the registry, or verify the credentials.\n\n# client.deprecate(uri, version, message, cb)\n\n* `uri` {String} Full registry URI for the deprecated package\n* `version` {String} Semver version range\n* `message` {String} The message to use as a deprecation warning\n* `cb` {Function}\n\nDeprecate a version of a package in the registry.\n\n# client.bugs(uri, cb)\n\n* `uri` {String} Full registry URI for the package\n* `cb` {Function}\n\nGet the url for bugs of a package\n\n# client.get(uri, options, cb)\n\n* `uri` {String} The complete registry URI to fetch\n* `options` {Object} Object containing optional per-request properties.\n * `timeout` {Number} Duration before the request times out.\n * `follow` {Boolean} Follow 302/301 responses (defaults to true)\n * `staleOk` {Boolean} If there's cached data available, then return that\n to the callback quickly, and update the cache the background.\n\nFetches data from the registry via a GET request, saving it in the cache folder\nwith the ETag.\n\n# client.publish(uri, data, tarball, cb)\n\n* `uri` {String} The registry URI to publish to\n* `data` {Object} Package data\n* `tarball` {String | Stream} Filename or stream of the package tarball\n* `cb` {Function}\n\nPublish a package to the registry.\n\nNote that this does not create the tarball from a folder. However, it can\naccept a gzipped tar stream or a filename to a tarball.\n\n# client.star(uri, starred, cb)\n\n* `uri` {String} The complete registry URI to star\n* `starred` {Boolean} True to star the package, false to unstar it.\n* `cb` {Function}\n\nStar or unstar a package.\n\nNote that the user does not have to be the package owner to star or unstar a\npackage, though other writes do require that the user be the package owner.\n\n# client.stars(base, username, cb)\n\n* `base` {String} The base URL for the registry\n* `username` {String} Name of user to fetch starred packages for.\n* `cb` {Function}\n\nView your own or another user's starred packages.\n\n# client.tag(uri, version, tag, cb)\n\n* `uri` {String} The complete registry URI to tag\n* `version` {String} Version to tag\n* `tag` {String} Tag name to apply\n* `cb` {Function}\n\nMark a version in the `dist-tags` hash, so that `pkg@tag` will fetch the\nspecified version.\n\n# client.unpublish(uri, [ver], cb)\n\n* `uri` {String} The complete registry URI to unpublish\n* `ver` {String} version to unpublish. Leave blank to unpublish all\n versions.\n* `cb` {Function}\n\nRemove a version of a package (or all versions) from the registry. When the\nlast version us unpublished, the entire document is removed from the database.\n\n# client.upload(uri, file, [etag], [nofollow], cb)\n\n* `uri` {String} The complete registry URI to upload to\n* `file` {String | Stream} Either the filename or a readable stream\n* `etag` {String} Cache ETag\n* `nofollow` {Boolean} Do not follow 301/302 responses\n* `cb` {Function}\n\nUpload an attachment. Mostly used by `client.publish()`.\n",
"readmeFilename": "README.md",
- "gitHead": "c60d91b1e8dceba21e33ec40eeaf1b0d02cac8c6",
+ "gitHead": "ddafd4913bdca30a1f9111660767f71653604b57",
"bugs": {
"url": "https://github.com/isaacs/npm-registry-client/issues"
},
"homepage": "https://github.com/isaacs/npm-registry-client",
- "_id": "npm-registry-client@3.2.1",
- "_shasum": "a502a818de273085e8e1a931ff7beac6e3fe2a7a",
- "_from": "npm-registry-client@>=3.2.1-0 <3.3.0-0"
+ "_id": "npm-registry-client@3.2.4",
+ "_shasum": "8659b3449e1c9a9f8181dad142cadb048bfe521f",
+ "_from": "npm-registry-client@>=3.2.4 <3.3.0"
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npm-registry-client/test/fetch-authed.js nodejs-0.11.15/deps/npm/node_modules/npm-registry-client/test/fetch-authed.js
--- nodejs-0.11.14/deps/npm/node_modules/npm-registry-client/test/fetch-authed.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npm-registry-client/test/fetch-authed.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,56 @@
+var resolve = require("path").resolve
+var createReadStream = require("graceful-fs").createReadStream
+var readFileSync = require("graceful-fs").readFileSync
+
+var tap = require("tap")
+var cat = require("concat-stream")
+
+var server = require("./lib/server.js")
+var common = require("./lib/common.js")
+
+var tgz = resolve(__dirname, "./fixtures/underscore/1.3.3/package.tgz")
+
+tap.test("basic fetch with scoped always-auth enabled", function (t) {
+ server.expect("/underscore/-/underscore-1.3.3.tgz", function (req, res) {
+ t.equal(req.method, "GET", "got expected method")
+ t.equal(
+ req.headers.authorization,
+ "Basic dXNlcm5hbWU6JTEyMzRAYXNkZiU=",
+ "got expected auth header"
+ )
+
+ res.writeHead(200, {
+ "content-type" : "application/x-tar",
+ "content-encoding" : "gzip"
+ })
+
+ createReadStream(tgz).pipe(res)
+ })
+
+ var nerfed = "//localhost:" + server.port + "/:"
+ var configuration = {}
+ configuration[nerfed + "username"] = "username"
+ configuration[nerfed + "_password"] = new Buffer("%1234@asdf%").toString("base64")
+ configuration[nerfed + "email"] = "i@izs.me"
+ configuration[nerfed + "always-auth"] = true
+
+ var client = common.freshClient(configuration)
+ client.fetch(
+ "http://localhost:1337/underscore/-/underscore-1.3.3.tgz",
+ null,
+ function (er, res) {
+ t.ifError(er, "loaded successfully")
+
+ var sink = cat(function (data) {
+ t.deepEqual(data, readFileSync(tgz))
+ t.end()
+ })
+
+ res.on("error", function (error) {
+ t.ifError(error, "no errors on stream")
+ })
+
+ res.pipe(sink)
+ }
+ )
+})
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npm-registry-client/test/fetch-not-authed.js nodejs-0.11.15/deps/npm/node_modules/npm-registry-client/test/fetch-not-authed.js
--- nodejs-0.11.14/deps/npm/node_modules/npm-registry-client/test/fetch-not-authed.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npm-registry-client/test/fetch-not-authed.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,52 @@
+var resolve = require("path").resolve
+var createReadStream = require("graceful-fs").createReadStream
+var readFileSync = require("graceful-fs").readFileSync
+
+var tap = require("tap")
+var cat = require("concat-stream")
+
+var server = require("./lib/server.js")
+var common = require("./lib/common.js")
+
+var tgz = resolve(__dirname, "./fixtures/underscore/1.3.3/package.tgz")
+
+tap.test("basic fetch with scoped always-auth disabled", function (t) {
+ server.expect("/underscore/-/underscore-1.3.3.tgz", function (req, res) {
+ t.equal(req.method, "GET", "got expected method")
+ t.notOk(req.headers.authorization, "received no auth header")
+
+ res.writeHead(200, {
+ "content-type" : "application/x-tar",
+ "content-encoding" : "gzip"
+ })
+
+ createReadStream(tgz).pipe(res)
+ })
+
+ var nerfed = "//localhost:" + server.port + "/:"
+ var configuration = {}
+ configuration[nerfed + "username"] = "username"
+ configuration[nerfed + "_password"] = new Buffer("%1234@asdf%").toString("base64")
+ configuration[nerfed + "email"] = "i@izs.me"
+ configuration[nerfed + "always-auth"] = false
+
+ var client = common.freshClient(configuration)
+ client.fetch(
+ "http://localhost:1337/underscore/-/underscore-1.3.3.tgz",
+ null,
+ function (er, res) {
+ t.ifError(er, "loaded successfully")
+
+ var sink = cat(function (data) {
+ t.deepEqual(data, readFileSync(tgz))
+ t.end()
+ })
+
+ res.on("error", function (error) {
+ t.ifError(error, "no errors on stream")
+ })
+
+ res.pipe(sink)
+ }
+ )
+})
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npm-registry-client/test/fixtures/@npm/npm-registry-client/cache.json nodejs-0.11.15/deps/npm/node_modules/npm-registry-client/test/fixtures/@npm/npm-registry-client/cache.json
--- nodejs-0.11.14/deps/npm/node_modules/npm-registry-client/test/fixtures/@npm/npm-registry-client/cache.json 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npm-registry-client/test/fixtures/@npm/npm-registry-client/cache.json 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1 @@
+{"_id":"@npm%2fnpm-registry-client","_rev":"213-0a1049cf56172b7d9a1184742c6477b9","name":"@npm/npm-registry-client","description":"Client for the npm registry","dist-tags":{"latest":"2.0.4","v2.0":"2.0.3"},"versions":{"0.0.1":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.0.1","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"node-uuid":"~1.3.3","request":"~2.9.202","graceful-fs":"~1.1.8","semver":"~1.0.14","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2.0.1","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"engines":{"node":"*"},"_npmUser":{"name":"isaacs","email":"i@izs.me"},"_id":"@npm%2fnpm-registry-client@0.0.1","_engineSupported":true,"_npmVersion":"1.1.24","_nodeVersion":"v0.7.10-pre","_defaultsLoaded":true,"dist":{"shasum":"693a08f6d2faea22bbd2bf412508a63d3e6229a7","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.0.1.tgz"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.0.2":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.0.2","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"node-uuid":"~1.3.3","request":"~2.9.202","graceful-fs":"~1.1.8","semver":"~1.0.14","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2.0.1","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"engines":{"node":"*"},"_npmUser":{"name":"isaacs","email":"i@izs.me"},"_id":"@npm%2fnpm-registry-client@0.0.2","_engineSupported":true,"_npmVersion":"1.1.24","_nodeVersion":"v0.7.10-pre","_defaultsLoaded":true,"dist":{"shasum":"b48c0ec5563c6a6fdc253454fc56d2c60c5a26f4","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.0.2.tgz"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.0.3":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.0.3","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"node-uuid":"~1.3.3","request":"~2.9.202","graceful-fs":"~1.1.8","semver":"~1.0.14","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2.0.1","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"engines":{"node":"*"},"_npmUser":{"name":"isaacs","email":"i@izs.me"},"_id":"@npm%2fnpm-registry-client@0.0.3","_engineSupported":true,"_npmVersion":"1.1.24","_nodeVersion":"v0.7.10-pre","_defaultsLoaded":true,"dist":{"shasum":"ccc0254c2d59e3ea9b9050e2b16edef78df1a1e8","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.0.3.tgz"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.0.4":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.0.4","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"node-uuid":"~1.3.3","request":"~2.9.202","graceful-fs":"~1.1.8","semver":"~1.0.14","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2.0.1","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"engines":{"node":"*"},"_npmUser":{"name":"isaacs","email":"i@izs.me"},"_id":"@npm%2fnpm-registry-client@0.0.4","_engineSupported":true,"_npmVersion":"1.1.25","_nodeVersion":"v0.7.10-pre","_defaultsLoaded":true,"dist":{"shasum":"faabd25ef477521c74ac21e0f4cf3a2f66d18fb3","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.0.4.tgz"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.0.5":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.0.5","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"node-uuid":"~1.3.3","request":"~2.9.202","graceful-fs":"~1.1.8","semver":"~1.0.14","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2.0.1","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"engines":{"node":"*"},"_id":"@npm%2fnpm-registry-client@0.0.5","dist":{"shasum":"85219810c9d89ae8d28ea766e7cf74efbd9f1e52","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.0.5.tgz"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.0.6":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"The code that npm uses to talk to the registry","version":"0.0.6","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"node-uuid":"~1.3.3","request":"~2.9.202","graceful-fs":"~1.1.8","semver":"~1.0.14","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2.0.1","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"engines":{"node":"*"},"_id":"@npm%2fnpm-registry-client@0.0.6","dist":{"shasum":"cc6533b3b41df65e6e9db2601fbbf1a509a7e94c","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.0.6.tgz"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.0.7":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"The code that npm uses to talk to the registry","version":"0.0.7","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"node-uuid":"~1.3.3","request":"~2.9.202","graceful-fs":"~1.1.8","semver":"~1.0.14","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2.0.1","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"engines":{"node":"*"},"_id":"@npm%2fnpm-registry-client@0.0.7","dist":{"shasum":"0cee1d1c61f1c8e483774fe1f7bbb81c4f394a3a","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.0.7.tgz"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.0.8":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.0.8","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"node-uuid":"~1.3.3","request":"~2.9.202","graceful-fs":"~1.1.8","semver":"~1.0.14","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2.0.1","retry":"0.6.0","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","_id":"@npm%2fnpm-registry-client@0.0.8","dist":{"shasum":"1b7411c3f7310ec2a96b055b00e7ca606e47bd07","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.0.8.tgz"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.0.9":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.0.9","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"node-uuid":"~1.3.3","request":"~2.9.202","graceful-fs":"~1.1.8","semver":"~1.0.14","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2.0.1","retry":"0.6.0","couch-login":"~0.1.6","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","_id":"@npm%2fnpm-registry-client@0.0.9","dist":{"shasum":"6d5bfde431559ac9e2e52a7db85f5839b874f022","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.0.9.tgz"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.0.10":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.0.10","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"node-uuid":"~1.3.3","request":"~2.9.202","graceful-fs":"~1.1.8","semver":"~1.0.14","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2.0.1","retry":"0.6.0","couch-login":"~0.1.6","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","_id":"@npm%2fnpm-registry-client@0.0.10","dist":{"shasum":"0c8b6a4615bce82aa6cc04a0d1f7dc89921f7a38","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.0.10.tgz"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.0.11":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.0.11","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"node-uuid":"~1.3.3","request":"~2.9.202","graceful-fs":"~1.1.8","semver":"~1.0.14","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2.0.1","retry":"0.6.0","couch-login":"~0.1.6","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","_id":"@npm%2fnpm-registry-client@0.0.11","dist":{"shasum":"afab40be5bed1faa946d8e1827844698f2ec1db7","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.0.11.tgz"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.1.0":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.1.0","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"node-uuid":"~1.3.3","request":"~2.9.202","graceful-fs":"~1.1.8","semver":"~1.0.14","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2.0.1","retry":"0.6.0","couch-login":"~0.1.6","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","_id":"@npm%2fnpm-registry-client@0.1.0","dist":{"shasum":"1077d6bbb5e432450239dc6622a59474953ffbea","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.1.0.tgz"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.1.1":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.1.1","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"node-uuid":"~1.3.3","request":"~2.9.202","graceful-fs":"~1.1.8","semver":"~1.0.14","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2.0.1","retry":"0.6.0","couch-login":"~0.1.6","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","_id":"@npm%2fnpm-registry-client@0.1.1","dist":{"shasum":"759765361d09b715270f59cf50f10908e4e9c5fc","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.1.1.tgz"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.1.2":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.1.2","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"node-uuid":"~1.3.3","request":"~2.9.202","graceful-fs":"~1.1.8","semver":"~1.0.14","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2.0.1","retry":"0.6.0","couch-login":"~0.1.6","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","_id":"@npm%2fnpm-registry-client@0.1.2","dist":{"shasum":"541ce93abb3d35f5c325545c718dd3bbeaaa9ff0","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.1.2.tgz"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.1.3":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.1.3","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"node-uuid":"~1.3.3","request":"~2.9.202","graceful-fs":"~1.1.8","semver":"~1.0.14","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2.0.1","retry":"0.6.0","couch-login":"~0.1.6","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","_id":"@npm%2fnpm-registry-client@0.1.3","dist":{"shasum":"e9a40d7031e8f809af5fd85aa9aac979e17efc97","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.1.3.tgz"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.1.4":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.1.4","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"node-uuid":"~1.3.3","request":"~2.9.202","graceful-fs":"~1.1.8","semver":"~1.0.14","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2.0.1","retry":"0.6.0","couch-login":"~0.1.6","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","_id":"@npm%2fnpm-registry-client@0.1.4","dist":{"shasum":"b211485b046191a1085362376530316f0cab0420","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.1.4.tgz"},"_npmVersion":"1.1.48","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.2.0":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.2.0","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"node-uuid":"~1.3.3","request":"~2.9.202","graceful-fs":"~1.1.8","semver":"~1.0.14","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2.0.1","retry":"0.6.0","couch-login":"~0.1.6","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","_id":"@npm%2fnpm-registry-client@0.2.0","dist":{"shasum":"6508a4b4d96f31057d5200ca5779531bafd2b840","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.2.0.tgz"},"_npmVersion":"1.1.49","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.2.1":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.2.1","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"node-uuid":"~1.3.3","request":"~2.9.202","graceful-fs":"~1.1.8","semver":"~1.0.14","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2.0.1","retry":"0.6.0","couch-login":"~0.1.6","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","_id":"@npm%2fnpm-registry-client@0.2.1","dist":{"shasum":"1bc8c4576c368cd88253d8a52daf40c55b89bb1a","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.2.1.tgz"},"_npmVersion":"1.1.49","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.2.5":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.2.5","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"~2.9.202","graceful-fs":"~1.1.8","semver":"~1.0.14","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2.0.1","retry":"0.6.0","couch-login":"~0.1.6","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","_id":"@npm%2fnpm-registry-client@0.2.5","dist":{"shasum":"2f55d675dfb977403b1ad0d96874c1d30e8058d7","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.2.5.tgz"},"_npmVersion":"1.1.51","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.2.6":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.2.6","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"~2.9.202","graceful-fs":"~1.1.8","semver":"~1.0.14","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2.0.1","retry":"0.6.0","couch-login":"~0.1.6","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","_id":"@npm%2fnpm-registry-client@0.2.6","dist":{"shasum":"f05df6695360360ad220e6e13a6a7bace7165fbe","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.2.6.tgz"},"_npmVersion":"1.1.56","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.2.7":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.2.7","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"~2.9.202","graceful-fs":"~1.1.8","semver":"~1.0.14","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2.0.1","retry":"0.6.0","couch-login":"~0.1.6","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","_id":"@npm%2fnpm-registry-client@0.2.7","dist":{"shasum":"867bad8854cae82ed89ee3b7f1d391af59491671","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.2.7.tgz"},"_npmVersion":"1.1.59","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.2.8":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.2.8","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"~2.9.202","graceful-fs":"~1.1.8","semver":"~1.1.0","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2.0.1","retry":"0.6.0","couch-login":"~0.1.6","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","_id":"@npm%2fnpm-registry-client@0.2.8","dist":{"shasum":"ef194cdb70f1ea03a576cff2c97392fa96e36563","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.2.8.tgz"},"_npmVersion":"1.1.62","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.2.9":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.2.9","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"~2.9.202","graceful-fs":"~1.1.8","semver":"~1.1.0","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2.0.1","retry":"0.6.0","couch-login":"~0.1.15","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","_id":"@npm%2fnpm-registry-client@0.2.9","dist":{"shasum":"3cec10431dfed1594adaf99c50f482ee56ecf9e4","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.2.9.tgz"},"_npmVersion":"1.1.59","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.2.10":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.2.10","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"~2.9.202","graceful-fs":"~1.1.8","semver":"~1.1.0","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2.0.1","retry":"0.6.0","couch-login":"~0.1.15","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","_id":"@npm%2fnpm-registry-client@0.2.10","dist":{"shasum":"1e69726dae0944e78562fd77243f839c6a2ced1e","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.2.10.tgz"},"_npmVersion":"1.1.64","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.2.11":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.2.11","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"~2.9.202","graceful-fs":"~1.1.8","semver":"~1.1.0","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","couch-login":"~0.1.15","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","_id":"@npm%2fnpm-registry-client@0.2.11","dist":{"shasum":"d92f33c297eb1bbd57fd597c3d8f5f7e9340a0b5","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.2.11.tgz"},"_npmVersion":"1.1.70","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.2.12":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.2.12","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"~2.9.202","graceful-fs":"~1.1.8","semver":"~1.1.0","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","couch-login":"~0.1.15","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","_id":"@npm%2fnpm-registry-client@0.2.12","dist":{"shasum":"3bfb6fc0e4b131d665580cd1481c341fe521bfd3","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.2.12.tgz"},"_from":".","_npmVersion":"1.2.2","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.2.13":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.2.13","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"~2.9.202","graceful-fs":"~1.2.0","semver":"~1.1.0","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","couch-login":"~0.1.15","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","_id":"@npm%2fnpm-registry-client@0.2.13","dist":{"shasum":"e03f2a4340065511b7184a3e2862cd5d459ef027","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.2.13.tgz"},"_from":".","_npmVersion":"1.2.4","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.2.14":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.2.14","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"~2.9.202","graceful-fs":"~1.2.0","semver":"~1.1.0","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","couch-login":"~0.1.15","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","_id":"@npm%2fnpm-registry-client@0.2.14","dist":{"shasum":"186874a7790417a340d582b1cd4a7c338087ee12","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.2.14.tgz"},"_from":".","_npmVersion":"1.2.10","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.2.15":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.2.15","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"~2.9.202","graceful-fs":"~1.2.0","semver":"~1.1.0","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","couch-login":"~0.1.15","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","_id":"@npm%2fnpm-registry-client@0.2.15","dist":{"shasum":"f71f32b7185855f1f8b7a5ef49e49d2357c2c552","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.2.15.tgz"},"_from":".","_npmVersion":"1.2.10","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.2.16":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.2.16","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"~2.9.202","graceful-fs":"~1.2.0","semver":"~1.1.0","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","couch-login":"~0.1.15","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","_id":"@npm%2fnpm-registry-client@0.2.16","dist":{"shasum":"3331323b5050fc5afdf77c3a35913c16f3e43964","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.2.16.tgz"},"_from":".","_npmVersion":"1.2.10","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.2.17":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.2.17","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"~2.9.202","graceful-fs":"~1.2.0","semver":"~1.1.0","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","couch-login":"~0.1.15","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","_id":"@npm%2fnpm-registry-client@0.2.17","dist":{"shasum":"1df2bbecac6751f5d9600fb43722aef96d956773","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.2.17.tgz"},"_from":".","_npmVersion":"1.2.11","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.2.18":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.2.18","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"~2.9.202","graceful-fs":"~1.2.0","semver":"~1.1.0","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","couch-login":"~0.1.15","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","_id":"@npm%2fnpm-registry-client@0.2.18","dist":{"shasum":"198c8d15ed9b1ed546faf6e431eb63a6b18193ad","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.2.18.tgz"},"_from":".","_npmVersion":"1.2.13","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.2.19":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.2.19","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"~2.16","graceful-fs":"~1.2.0","semver":"~1.1.0","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","couch-login":"~0.1.15","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","_id":"@npm%2fnpm-registry-client@0.2.19","dist":{"shasum":"106da826f0d2007f6e081f2b68fb6f26fa951b20","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.2.19.tgz"},"_from":".","_npmVersion":"1.2.14","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.2.20":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.2.20","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"~2.16","graceful-fs":"~1.2.0","semver":"~1.1.0","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","couch-login":"~0.1.15","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","_id":"@npm%2fnpm-registry-client@0.2.20","dist":{"shasum":"3fff194331e26660be2cf8ebf45ddf7d36add5f6","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.2.20.tgz"},"_from":".","_npmVersion":"1.2.15","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.2.21":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.2.21","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"~2.16","graceful-fs":"~1.2.0","semver":"~1.1.0","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","couch-login":"~0.1.15","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"_id":"@npm%2fnpm-registry-client@0.2.21","dist":{"shasum":"d85dd32525f193925c46ff9eb0e0f529dfd1b254","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.2.21.tgz"},"_from":".","_npmVersion":"1.2.18","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.2.22":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.2.22","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"~2.20.0","graceful-fs":"~1.2.0","semver":"~1.1.0","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","couch-login":"~0.1.15","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"_id":"@npm%2fnpm-registry-client@0.2.22","dist":{"shasum":"caa22ff40a1ccd632a660b8b80c333c8f92d5a17","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.2.22.tgz"},"_from":".","_npmVersion":"1.2.18","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.2.23":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.2.23","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"2 >=2.20.0","graceful-fs":"~1.2.0","semver":"~1.1.0","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","couch-login":"~0.1.15","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"_id":"@npm%2fnpm-registry-client@0.2.23","dist":{"shasum":"a320ab2b1d048b4f7b88e40bd86974ca322b4c24","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.2.23.tgz"},"_from":".","_npmVersion":"1.2.19","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.2.24":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.2.24","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"2 >=2.20.0","graceful-fs":"~1.2.0","semver":"~1.1.0","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","couch-login":"~0.1.15","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"_id":"@npm%2fnpm-registry-client@0.2.24","dist":{"shasum":"e12f644338619319ee7f233363a1714a87f3c72d","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.2.24.tgz"},"_from":".","_npmVersion":"1.2.22","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.2.25":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.2.25","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"2 >=2.20.0","graceful-fs":"~1.2.0","semver":"~2.0.5","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","couch-login":"~0.1.15","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"_id":"@npm%2fnpm-registry-client@0.2.25","dist":{"shasum":"c2caeb1dcf937d6fcc4a187765d401f5e2f54027","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.2.25.tgz"},"_from":".","_npmVersion":"1.2.32","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.2.26":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.2.26","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"2 >=2.20.0","graceful-fs":"~1.2.0","semver":"~2.0.5","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","couch-login":"~0.1.15","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"_id":"@npm%2fnpm-registry-client@0.2.26","dist":{"shasum":"4c5a2b3de946e383032f10fa497d0c15ee5f4c60","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.2.26.tgz"},"_from":".","_npmVersion":"1.3.1","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.2.27":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.2.27","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"2 >=2.20.0","graceful-fs":"~2.0.0","semver":"~2.0.5","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","couch-login":"~0.1.15","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"_id":"@npm%2fnpm-registry-client@0.2.27","dist":{"shasum":"8f338189d32769267886a07ad7b7fd2267446adf","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.2.27.tgz"},"_from":".","_npmVersion":"1.3.2","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.2.28":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.2.28","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"2 >=2.25.0","graceful-fs":"~2.0.0","semver":"~2.1.0","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","couch-login":"~0.1.18","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"_id":"@npm%2fnpm-registry-client@0.2.28","dist":{"shasum":"959141fc0180d7b1ad089e87015a8a2142a8bffc","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.2.28.tgz"},"_from":".","_npmVersion":"1.3.6","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.2.29":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.2.29","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"2 >=2.25.0","graceful-fs":"~2.0.0","semver":"^2.2.1","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","couch-login":"~0.1.18","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@0.2.29","dist":{"shasum":"66ff2766f0c61d41e8a6139d3692d8833002c686","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.2.29.tgz"},"_from":".","_npmVersion":"1.3.12","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.2.30":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.2.30","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"2 >=2.25.0","graceful-fs":"~2.0.0","semver":"^2.2.1","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","couch-login":"~0.1.18","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@0.2.30","dist":{"shasum":"f01cae5c51aa0a1c5dc2516cbad3ebde068d3eaa","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.2.30.tgz"},"_from":".","_npmVersion":"1.3.14","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.2.31":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.2.31","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"2 >=2.25.0","graceful-fs":"~2.0.0","semver":"^2.2.1","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","couch-login":"~0.1.18","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@0.2.31","dist":{"shasum":"24a23e24e43246677cb485f8391829e9536563d4","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.2.31.tgz"},"_from":".","_npmVersion":"1.3.17","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.3.0":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.3.0","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"2 >=2.25.0","graceful-fs":"~2.0.0","semver":"^2.2.1","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","couch-login":"~0.1.18","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@0.3.0","dist":{"shasum":"66eab02a69be67f232ac14023eddfb8308c2eccd","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.3.0.tgz"},"_from":".","_npmVersion":"1.3.18","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.3.1":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.3.1","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"2 >=2.25.0","graceful-fs":"~2.0.0","semver":"^2.2.1","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","couch-login":"~0.1.18","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@0.3.1","dist":{"shasum":"16dba07cc304442edcece378218672d0a1258ef8","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.3.1.tgz"},"_from":".","_npmVersion":"1.3.18","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.3.2":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.3.2","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"2 >=2.25.0","graceful-fs":"~2.0.0","semver":"^2.2.1","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","couch-login":"~0.1.18","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@0.3.2","dist":{"shasum":"ea3060bd0a87fb1d97b87433b50f38f7272b1686","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.3.2.tgz"},"_from":".","_npmVersion":"1.3.20","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.3.3":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.3.3","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"2 >=2.25.0","graceful-fs":"~2.0.0","semver":"^2.2.1","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","couch-login":"~0.1.18","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@0.3.3","dist":{"shasum":"da08bb681fb24aa5c988ca71f8c10f27f09daf4a","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.3.3.tgz"},"_from":".","_npmVersion":"1.3.21","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.3.4":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.3.4","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"2 >=2.25.0","graceful-fs":"~2.0.0","semver":"^2.2.1","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","couch-login":"~0.1.18","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@0.3.4","dist":{"shasum":"25d771771590b1ca39277aea4506af234c5f4342","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.3.4.tgz"},"_from":".","_npmVersion":"1.3.25","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.3.5":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.3.5","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"2 >=2.25.0","graceful-fs":"~2.0.0","semver":"^2.2.1","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","couch-login":"~0.1.18","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@0.3.5","dist":{"shasum":"98ba1ac851a3939a3fb9917c28fa8da522dc635f","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.3.5.tgz"},"_from":".","_npmVersion":"1.3.25","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.3.6":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.3.6","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"2 >=2.25.0","graceful-fs":"~2.0.0","semver":"^2.2.1","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@0.3.6","dist":{"shasum":"c48a2a03643769acc49672860f7920ec6bffac6e","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.3.6.tgz"},"_from":".","_npmVersion":"1.3.26","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.4.0":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.4.0","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"2 >=2.25.0","graceful-fs":"~2.0.0","semver":"^2.2.1","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@0.4.0","dist":{"shasum":"30d0c178b7f2e54183a6a3fc9fe4071eb10290bf","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.4.0.tgz"},"_from":".","_npmVersion":"1.3.26","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.4.1":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.4.1","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"2 >=2.25.0","graceful-fs":"~2.0.0","semver":"^2.2.1","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@0.4.1","dist":{"shasum":"9c49b3e44558e2072158fb085be8a083c5f83537","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.4.1.tgz"},"_from":".","_npmVersion":"1.4.0","_npmUser":{"name":"npm-www","email":"npm@npmjs.com"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.4.2":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.4.2","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"2 >=2.25.0","graceful-fs":"~2.0.0","semver":"^2.2.1","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@0.4.2","dist":{"shasum":"d9568a9413bee14951201ce73f3b3992ec6658c0","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.4.2.tgz"},"_from":".","_npmVersion":"1.4.1","_npmUser":{"name":"npm-www","email":"npm@npmjs.com"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.4.3":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.4.3","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"2 >=2.25.0","graceful-fs":"~2.0.0","semver":"^2.2.1","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@0.4.3","dist":{"shasum":"aa188fc5067158e991a57f4697c54994108f5389","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.4.3.tgz"},"_from":".","_npmVersion":"1.4.2","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.4.4":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.4.4","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"2 >=2.25.0","graceful-fs":"~2.0.0","semver":"^2.2.1","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@0.4.4","dist":{"shasum":"f9dbc383a49069d8c7f67755a3ff6e424aff584f","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.4.4.tgz"},"_from":".","_npmVersion":"1.4.2","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.4.5":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.4.5","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"2 >=2.25.0","graceful-fs":"~2.0.0","semver":"^2.2.1","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@0.4.5","dist":{"shasum":"7d6fdca46139470715f9477ddb5ad3e770d4de7b","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.4.5.tgz"},"_from":".","_npmVersion":"1.4.4","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.4.6":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.4.6","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"2 >=2.25.0","graceful-fs":"~2.0.0","semver":"^2.2.1","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@0.4.6","_from":".","_npmVersion":"1.4.6","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"dist":{"shasum":"657f69a79543fc4cc264c3b2de958bd15f7140fe","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.4.6.tgz"},"directories":{}},"0.4.7":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.4.7","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"2 >=2.25.0","graceful-fs":"~2.0.0","semver":"^2.2.1","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@0.4.7","dist":{"shasum":"f4369b59890da7882527eb7c427dd95d43707afb","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.4.7.tgz"},"_from":".","_npmVersion":"1.4.6","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"directories":{}},"0.4.8":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.4.8","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"2 >=2.25.0","graceful-fs":"~2.0.0","semver":"^2.2.1","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@0.4.8","_shasum":"a6685a161033101be6064b7af887ab440e8695d0","_from":".","_npmVersion":"1.4.8","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"dist":{"shasum":"a6685a161033101be6064b7af887ab440e8695d0","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.4.8.tgz"},"directories":{}},"0.4.9":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.4.9","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"2 >=2.25.0","graceful-fs":"~2.0.0","semver":"^2.2.1","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@0.4.9","_shasum":"304d3d4726a58e33d8cc965afdc9ed70b996580c","_from":".","_npmVersion":"1.4.10","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"dist":{"shasum":"304d3d4726a58e33d8cc965afdc9ed70b996580c","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.4.9.tgz"},"directories":{}},"0.4.10":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.4.10","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"2 >=2.25.0","graceful-fs":"~2.0.0","semver":"^2.2.1","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@0.4.10","_shasum":"ab7bf1be3ba07d769eaf74dee3c9347e02283116","_from":".","_npmVersion":"1.4.10","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"dist":{"shasum":"ab7bf1be3ba07d769eaf74dee3c9347e02283116","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.4.10.tgz"},"directories":{}},"0.4.11":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.4.11","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"2 >=2.25.0","graceful-fs":"~2.0.0","semver":"2 >=2.2.1","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@0.4.11","_shasum":"032e9b6b050ed052ee9441841a945a184ea6bc33","_from":".","_npmVersion":"1.4.10","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"dist":{"shasum":"032e9b6b050ed052ee9441841a945a184ea6bc33","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.4.11.tgz"},"directories":{}},"0.4.12":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"0.4.12","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"request":"2 >=2.25.0","graceful-fs":"~2.0.0","semver":"2 >=2.2.1","slide":"~1.1.3","chownr":"0","mkdirp":"~0.3.3","rimraf":"~2","retry":"0.6.0","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@0.4.12","_shasum":"34303422f6a3da93ca3a387a2650d707c8595b99","_from":".","_npmVersion":"1.4.10","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"dist":{"shasum":"34303422f6a3da93ca3a387a2650d707c8595b99","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-0.4.12.tgz"},"directories":{}},"1.0.0":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"1.0.0","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"chownr":"0","graceful-fs":"~2.0.0","mkdirp":"~0.3.3","npm-cache-filename":"^1.0.0","request":"2 >=2.25.0","retry":"0.6.0","rimraf":"~2","semver":"2 >=2.2.1","slide":"~1.1.3","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@1.0.0","_shasum":"2a6f9dfdce5f8ebf4b9af4dbfd738384d25014e5","_from":".","_npmVersion":"1.4.10","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"dist":{"shasum":"2a6f9dfdce5f8ebf4b9af4dbfd738384d25014e5","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-1.0.0.tgz"},"directories":{}},"1.0.1":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"1.0.1","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"chownr":"0","graceful-fs":"~2.0.0","mkdirp":"~0.3.3","npm-cache-filename":"^1.0.0","request":"2 >=2.25.0","retry":"0.6.0","rimraf":"~2","semver":"2 >=2.2.1","slide":"~1.1.3","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","gitHead":"98b1278c230cf6c159f189e2f8c69daffa727ab8","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@1.0.1","_shasum":"c5f6a87d285f2005a35d3f67d9c724bce551b0f1","_from":".","_npmVersion":"1.4.13","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"dist":{"shasum":"c5f6a87d285f2005a35d3f67d9c724bce551b0f1","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-1.0.1.tgz"},"directories":{}},"2.0.0":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"2.0.0","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"chownr":"0","graceful-fs":"~2.0.0","mkdirp":"~0.3.3","npm-cache-filename":"^1.0.0","request":"2 >=2.25.0","retry":"0.6.0","rimraf":"~2","semver":"2 >=2.2.1","slide":"~1.1.3","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","gitHead":"47a98069b6a34e751cbd5b84ce92858cae5abe70","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@2.0.0","_shasum":"88810dac2d534c0df1d905c79e723392fcfc791a","_from":".","_npmVersion":"1.4.14","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"}],"dist":{"shasum":"88810dac2d534c0df1d905c79e723392fcfc791a","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-2.0.0.tgz"},"directories":{}},"2.0.1":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"2.0.1","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"chownr":"0","graceful-fs":"^3.0.0","mkdirp":"~0.3.3","npm-cache-filename":"^1.0.0","request":"2 >=2.25.0","retry":"0.6.0","rimraf":"~2","semver":"2 >=2.2.1","slide":"~1.1.3","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","gitHead":"123e40131f83f7265f66ecd2a558cce44a3aea86","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@2.0.1","_shasum":"611c7cb7c8f7ff22be2ebc6398423b5de10db0e2","_from":".","_npmVersion":"1.4.14","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"},{"name":"othiym23","email":"ogd@aoaioxxysz.net"}],"dist":{"shasum":"611c7cb7c8f7ff22be2ebc6398423b5de10db0e2","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-2.0.1.tgz"},"directories":{}},"2.0.2":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"2.0.2","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"chownr":"0","graceful-fs":"^3.0.0","mkdirp":"~0.3.3","npm-cache-filename":"^1.0.0","request":"2 >=2.25.0","retry":"0.6.0","rimraf":"~2","semver":"2 >=2.2.1","slide":"~1.1.3","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","gitHead":"6ecc311c9dd4890f2d9b6bae60447070a3321e12","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@2.0.2","_shasum":"a82b000354c7f830114fb18444764bc477d5740f","_from":".","_npmVersion":"1.4.15","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"},{"name":"othiym23","email":"ogd@aoaioxxysz.net"}],"dist":{"shasum":"a82b000354c7f830114fb18444764bc477d5740f","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-2.0.2.tgz"},"directories":{}},"3.0.0":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"3.0.0","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"chownr":"0","graceful-fs":"^3.0.0","mkdirp":"~0.3.3","normalize-package-data":"^0.4.0","npm-cache-filename":"^1.0.0","request":"2 >=2.25.0","retry":"0.6.0","rimraf":"~2","semver":"2 >=2.2.1","slide":"~1.1.3","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","gitHead":"6bb1aec1e85fa82ee075bd997d6fb9f2dbb7f643","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@3.0.0","_shasum":"4febc5cdb274e9fa06bc3008910e3fa1ec007994","_from":".","_npmVersion":"1.5.0-pre","_npmUser":{"name":"othiym23","email":"ogd@aoaioxxysz.net"},"maintainers":[{"name":"isaacs","email":"i@izs.me"},{"name":"othiym23","email":"ogd@aoaioxxysz.net"}],"dist":{"shasum":"4febc5cdb274e9fa06bc3008910e3fa1ec007994","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-3.0.0.tgz"},"directories":{}},"3.0.1":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"3.0.1","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"chownr":"0","graceful-fs":"^3.0.0","mkdirp":"~0.3.3","normalize-package-data":"^0.4.0","npm-cache-filename":"^1.0.0","request":"2 >=2.25.0","retry":"0.6.0","rimraf":"~2","semver":"2 >=2.2.1","slide":"~1.1.3","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","gitHead":"fe8382dde609ea1e3580fcdc5bc3d0bba119cfc6","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@3.0.1","_shasum":"5f3ee362ce5c237cfb798fce22c77875fc1a63c2","_from":".","_npmVersion":"1.5.0-alpha-1","_npmUser":{"name":"othiym23","email":"ogd@aoaioxxysz.net"},"maintainers":[{"name":"isaacs","email":"i@izs.me"},{"name":"othiym23","email":"ogd@aoaioxxysz.net"}],"dist":{"shasum":"5f3ee362ce5c237cfb798fce22c77875fc1a63c2","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-3.0.1.tgz"},"directories":{}},"2.0.3":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"2.0.3","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"chownr":"0","graceful-fs":"^3.0.0","mkdirp":"~0.3.3","npm-cache-filename":"^1.0.0","request":"2 >=2.25.0","retry":"0.6.0","rimraf":"~2","semver":"2 >=2.2.1","slide":"~1.1.3","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","gitHead":"2578fb9a807d77417554ba235ba8fac39405e832","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@2.0.3","_shasum":"93dad3d9a162c99404badb71739c622c0f3b9a72","_from":".","_npmVersion":"1.5.0-alpha-1","_npmUser":{"name":"othiym23","email":"ogd@aoaioxxysz.net"},"maintainers":[{"name":"isaacs","email":"i@izs.me"},{"name":"othiym23","email":"ogd@aoaioxxysz.net"}],"dist":{"shasum":"93dad3d9a162c99404badb71739c622c0f3b9a72","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-2.0.3.tgz"},"directories":{}},"3.0.2":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"3.0.2","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"chownr":"0","graceful-fs":"^3.0.0","mkdirp":"~0.3.3","normalize-package-data":"^0.4.0","npm-cache-filename":"^1.0.0","request":"2 >=2.25.0","retry":"0.6.0","rimraf":"~2","semver":"2 >=2.2.1","slide":"~1.1.3","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","gitHead":"15343019160ace0b9874cf0ec186b3425dbc7301","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@3.0.2","_shasum":"5dd0910157ce55f4286a1871d39f9a2128cd3c99","_from":".","_npmVersion":"1.5.0-alpha-2","_npmUser":{"name":"othiym23","email":"ogd@aoaioxxysz.net"},"maintainers":[{"name":"isaacs","email":"i@izs.me"},{"name":"othiym23","email":"ogd@aoaioxxysz.net"}],"dist":{"shasum":"5dd0910157ce55f4286a1871d39f9a2128cd3c99","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-3.0.2.tgz"},"directories":{}},"3.0.3":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"3.0.3","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"chownr":"0","graceful-fs":"^3.0.0","mkdirp":"~0.3.3","normalize-package-data":"^0.4.0","npm-cache-filename":"^1.0.0","request":"2 >=2.25.0","retry":"0.6.0","rimraf":"~2","semver":"2 >=2.2.1 || 3.x","slide":"~1.1.3","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","gitHead":"b18a780d1185f27c06c27812147b83aba0d4a2f5","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@3.0.3","_shasum":"2377dc1cf69b4d374b3a95fb7feba8c804d8cb30","_from":".","_npmVersion":"2.0.0-alpha-5","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"},{"name":"othiym23","email":"ogd@aoaioxxysz.net"}],"dist":{"shasum":"2377dc1cf69b4d374b3a95fb7feba8c804d8cb30","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-3.0.3.tgz"},"directories":{}},"3.0.4":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"3.0.4","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"chownr":"0","graceful-fs":"^3.0.0","mkdirp":"~0.5.0","normalize-package-data":"^0.4.0","npm-cache-filename":"^1.0.0","request":"2 >=2.25.0","retry":"0.6.0","rimraf":"~2","semver":"2 >=2.2.1 || 3.x","slide":"~1.1.3","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","gitHead":"54900fe4b2eb5b99ee6dfe173f145732fdfae80e","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@3.0.4","_shasum":"d4a177d1f25615cfaef9b6844fa366ffbf5f578a","_from":".","_npmVersion":"2.0.0-alpha-5","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"},{"name":"othiym23","email":"ogd@aoaioxxysz.net"}],"dist":{"shasum":"d4a177d1f25615cfaef9b6844fa366ffbf5f578a","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-3.0.4.tgz"},"directories":{}},"3.0.5":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"3.0.5","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"chownr":"0","graceful-fs":"^3.0.0","mkdirp":"0.5","normalize-package-data":"0.4","npm-cache-filename":"^1.0.0","request":"2 >=2.25.0","retry":"0.6.0","rimraf":"2","semver":"2 >=2.2.1 || 3.x","slide":"^1.1.3","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"BSD","gitHead":"635db1654346bc86473df7b39626601425f46177","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@3.0.5","_shasum":"cdabaefa399b81ac8a86a48718aefd80e7b19ff3","_from":".","_npmVersion":"2.0.0-alpha-5","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"},{"name":"othiym23","email":"ogd@aoaioxxysz.net"}],"dist":{"shasum":"cdabaefa399b81ac8a86a48718aefd80e7b19ff3","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-3.0.5.tgz"},"directories":{}},"3.0.6":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"3.0.6","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"chownr":"0","graceful-fs":"^3.0.0","mkdirp":"^0.5.0","normalize-package-data":"0.4","npm-cache-filename":"^1.0.0","request":"2 >=2.25.0","retry":"0.6.0","rimraf":"2","semver":"2 >=2.2.1 || 3.x","slide":"^1.1.3","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"ISC","gitHead":"eba30fadd724ed5cad1aec95ac3ee907a59b7317","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@3.0.6","_shasum":"14a17d9a60ed2a80b04edcbc596dbce0d96540ee","_from":".","_npmVersion":"1.4.22","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"},{"name":"othiym23","email":"ogd@aoaioxxysz.net"}],"dist":{"shasum":"14a17d9a60ed2a80b04edcbc596dbce0d96540ee","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-3.0.6.tgz"},"directories":{}},"2.0.4":{"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"name":"@npm/npm-registry-client","description":"Client for the npm registry","version":"2.0.4","repository":{"url":"git://github.com/isaacs/npm-registry-client"},"main":"index.js","scripts":{"test":"tap test/*.js"},"dependencies":{"chownr":"0","graceful-fs":"^3.0.0","mkdirp":"^0.5.0","npm-cache-filename":"^1.0.0","request":"2 >=2.25.0","retry":"0.6.0","rimraf":"~2","semver":"2 >=2.2.1","slide":"~1.1.3","npmlog":""},"devDependencies":{"tap":""},"optionalDependencies":{"npmlog":""},"license":"ISC","gitHead":"a10f621d9cdc813b9d3092a14b661f65bfa6d40d","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"homepage":"https://github.com/isaacs/npm-registry-client","_id":"@npm%2fnpm-registry-client@2.0.4","_shasum":"528e08900d7655c12096d1637d1c3a7a5b451019","_from":".","_npmVersion":"1.4.22","_npmUser":{"name":"isaacs","email":"i@izs.me"},"maintainers":[{"name":"isaacs","email":"i@izs.me"},{"name":"othiym23","email":"ogd@aoaioxxysz.net"}],"dist":{"shasum":"528e08900d7655c12096d1637d1c3a7a5b451019","tarball":"http://registry.npmjs.org/@npm%2fnpm-registry-client/-/@npm%2fnpm-registry-client-2.0.4.tgz"},"directories":{}}},"readme":"# npm-registry-client\u000a\u000aThe code that npm uses to talk to the registry.\u000a\u000aIt handles all the caching and HTTP calls.\u000a\u000a## Usage\u000a\u000a```javascript\u000avar RegClient = require('npm-registry-client')\u000avar client = new RegClient(config)\u000avar uri = \"npm://registry.npmjs.org/npm\"\u000avar options = {timeout: 1000}\u000a\u000aclient.get(uri, options, function (error, data, raw, res) {\u000a // error is an error if there was a problem.\u000a // data is the parsed data object\u000a // raw is the json string\u000a // res is the response from couch\u000a})\u000a```\u000a\u000a# Registry URLs\u000a\u000aThe registry calls take either a full URL pointing to a resource in the\u000aregistry, or a base URL for the registry as a whole (for the base URL, any path\u000awill be ignored). In addition to `http` and `https`, `npm` URLs are allowed.\u000a`npm` URLs are `https` URLs with the additional restrictions that they will\u000aalways include authorization credentials, and the response is always registry\u000ametadata (and not tarballs or other attachments).\u000a\u000a# Configuration\u000a\u000aThis program is designed to work with\u000a[npmconf](https://npmjs.org/package/npmconf), but you can also pass in\u000aa plain-jane object with the appropriate configs, and it'll shim it\u000afor you. Any configuration thingie that has get/set/del methods will\u000aalso be accepted.\u000a\u000a* `cache` **Required** {String} Path to the cache folder\u000a* `always-auth` {Boolean} Auth even for GET requests.\u000a* `auth` {String} A base64-encoded `username:password`\u000a* `email` {String} User's email address\u000a* `tag` {String} The default tag to use when publishing new packages.\u000a Default = `\"latest\"`\u000a* `ca` {String} Cerficate signing authority certificates to trust.\u000a* `cert` {String} Client certificate (PEM encoded). Enable access\u000a to servers that require client certificates\u000a* `key` {String} Private key (PEM encoded) for client certificate 'cert'\u000a* `strict-ssl` {Boolean} Whether or not to be strict with SSL\u000a certificates. Default = `true`\u000a* `user-agent` {String} User agent header to send. Default =\u000a `\"node/{process.version} {process.platform} {process.arch}\"`\u000a* `log` {Object} The logger to use. Defaults to `require(\"npmlog\")` if\u000a that works, otherwise logs are disabled.\u000a* `fetch-retries` {Number} Number of times to retry on GET failures.\u000a Default=2\u000a* `fetch-retry-factor` {Number} `factor` setting for `node-retry`. Default=10\u000a* `fetch-retry-mintimeout` {Number} `minTimeout` setting for `node-retry`.\u000a Default=10000 (10 seconds)\u000a* `fetch-retry-maxtimeout` {Number} `maxTimeout` setting for `node-retry`.\u000a Default=60000 (60 seconds)\u000a* `proxy` {URL} The url to proxy requests through.\u000a* `https-proxy` {URL} The url to proxy https requests through.\u000a Defaults to be the same as `proxy` if unset.\u000a* `_auth` {String} The base64-encoded authorization header.\u000a* `username` `_password` {String} Username/password to use to generate\u000a `_auth` if not supplied.\u000a* `_token` {Object} A token for use with\u000a [couch-login](https://npmjs.org/package/couch-login)\u000a\u000a# client.request(method, uri, options, cb)\u000a\u000a* `method` {String} HTTP method\u000a* `uri` {String} URI pointing to the resource to request\u000a* `options` {Object} Object containing optional per-request properties.\u000a * `what` {Stream | Buffer | String | Object} The request body. Objects\u000a that are not Buffers or Streams are encoded as JSON.\u000a * `etag` {String} The cached ETag\u000a * `follow` {Boolean} Follow 302/301 responses (defaults to true)\u000a* `cb` {Function}\u000a * `error` {Error | null}\u000a * `data` {Object} the parsed data object\u000a * `raw` {String} the json\u000a * `res` {Response Object} response from couch\u000a\u000aMake a request to the registry. All the other methods are wrappers around\u000a`request`.\u000a\u000a# client.adduser(base, username, password, email, cb)\u000a\u000a* `base` {String} Base registry URL\u000a* `username` {String}\u000a* `password` {String}\u000a* `email` {String}\u000a* `cb` {Function}\u000a\u000aAdd a user account to the registry, or verify the credentials.\u000a\u000a# client.deprecate(uri, version, message, cb)\u000a\u000a* `uri` {String} Full registry URI for the deprecated package\u000a* `version` {String} Semver version range\u000a* `message` {String} The message to use as a deprecation warning\u000a* `cb` {Function}\u000a\u000aDeprecate a version of a package in the registry.\u000a\u000a# client.bugs(uri, cb)\u000a\u000a* `uri` {String} Full registry URI for the package\u000a* `cb` {Function}\u000a\u000aGet the url for bugs of a package\u000a\u000a# client.get(uri, options, cb)\u000a\u000a* `uri` {String} The complete registry URI to fetch\u000a* `options` {Object} Object containing optional per-request properties.\u000a * `timeout` {Number} Duration before the request times out.\u000a * `follow` {Boolean} Follow 302/301 responses (defaults to true)\u000a * `staleOk` {Boolean} If there's cached data available, then return that\u000a to the callback quickly, and update the cache the background.\u000a\u000aFetches data from the registry via a GET request, saving it in the cache folder\u000awith the ETag.\u000a\u000a# client.publish(uri, data, tarball, cb)\u000a\u000a* `uri` {String} The registry URI to publish to\u000a* `data` {Object} Package data\u000a* `tarball` {String | Stream} Filename or stream of the package tarball\u000a* `cb` {Function}\u000a\u000aPublish a package to the registry.\u000a\u000aNote that this does not create the tarball from a folder. However, it can\u000aaccept a gzipped tar stream or a filename to a tarball.\u000a\u000a# client.star(uri, starred, cb)\u000a\u000a* `uri` {String} The complete registry URI to star\u000a* `starred` {Boolean} True to star the package, false to unstar it.\u000a* `cb` {Function}\u000a\u000aStar or unstar a package.\u000a\u000aNote that the user does not have to be the package owner to star or unstar a\u000apackage, though other writes do require that the user be the package owner.\u000a\u000a# client.stars(base, username, cb)\u000a\u000a* `base` {String} The base URL for the registry\u000a* `username` {String} Name of user to fetch starred packages for.\u000a* `cb` {Function}\u000a\u000aView your own or another user's starred packages.\u000a\u000a# client.tag(uri, version, tag, cb)\u000a\u000a* `uri` {String} The complete registry URI to tag\u000a* `version` {String} Version to tag\u000a* `tag` {String} Tag name to apply\u000a* `cb` {Function}\u000a\u000aMark a version in the `dist-tags` hash, so that `pkg@tag` will fetch the\u000aspecified version.\u000a\u000a# client.unpublish(uri, [ver], cb)\u000a\u000a* `uri` {String} The complete registry URI to unpublish\u000a* `ver` {String} version to unpublish. Leave blank to unpublish all\u000a versions.\u000a* `cb` {Function}\u000a\u000aRemove a version of a package (or all versions) from the registry. When the\u000alast version us unpublished, the entire document is removed from the database.\u000a\u000a# client.upload(uri, file, [etag], [nofollow], cb)\u000a\u000a* `uri` {String} The complete registry URI to upload to\u000a* `file` {String | Stream} Either the filename or a readable stream\u000a* `etag` {String} Cache ETag\u000a* `nofollow` {Boolean} Do not follow 301/302 responses\u000a* `cb` {Function}\u000a\u000aUpload an attachment. Mostly used by `client.publish()`.\u000a","maintainers":[{"name":"isaacs","email":"i@izs.me"},{"name":"othiym23","email":"ogd@aoaioxxysz.net"}],"time":{"modified":"2014-07-31T21:59:52.896Z","created":"2012-06-07T04:43:36.581Z","0.0.1":"2012-06-07T04:43:38.123Z","0.0.2":"2012-06-07T05:35:05.937Z","0.0.3":"2012-06-09T00:55:25.861Z","0.0.4":"2012-06-11T03:53:26.548Z","0.0.5":"2012-06-11T23:48:11.235Z","0.0.6":"2012-06-17T06:23:27.320Z","0.0.7":"2012-06-18T19:19:38.315Z","0.0.8":"2012-06-28T20:40:20.563Z","0.0.9":"2012-07-10T03:28:04.651Z","0.0.10":"2012-07-11T17:03:45.151Z","0.0.11":"2012-07-17T14:06:37.489Z","0.1.0":"2012-07-23T18:17:38.007Z","0.1.1":"2012-07-23T21:21:28.196Z","0.1.2":"2012-07-24T06:14:12.831Z","0.1.3":"2012-08-07T02:02:20.564Z","0.1.4":"2012-08-15T03:04:52.822Z","0.1.5":"2012-08-17T21:59:33.310Z","0.2.0":"2012-08-17T22:00:18.081Z","0.2.1":"2012-08-17T22:07:28.827Z","0.2.2":"2012-08-17T22:37:24.352Z","0.2.3":"2012-08-19T19:16:44.808Z","0.2.4":"2012-08-19T19:18:51.792Z","0.2.5":"2012-08-20T16:54:50.794Z","0.2.6":"2012-08-22T00:25:04.766Z","0.2.7":"2012-08-27T19:07:34.829Z","0.2.8":"2012-10-02T19:53:50.661Z","0.2.9":"2012-10-03T22:09:50.766Z","0.2.10":"2012-10-25T14:55:54.216Z","0.2.11":"2012-12-21T16:26:38.094Z","0.2.12":"2013-01-18T22:22:41.668Z","0.2.13":"2013-02-06T00:16:35.939Z","0.2.14":"2013-02-10T02:44:02.764Z","0.2.15":"2013-02-11T19:18:55.678Z","0.2.16":"2013-02-15T17:09:03.249Z","0.2.17":"2013-02-16T03:47:13.898Z","0.2.18":"2013-03-06T22:09:23.536Z","0.2.19":"2013-03-20T06:27:39.128Z","0.2.20":"2013-03-28T00:43:07.558Z","0.2.21":"2013-04-29T15:46:54.094Z","0.2.22":"2013-04-29T15:51:02.178Z","0.2.23":"2013-05-11T00:28:14.198Z","0.2.24":"2013-05-24T21:27:50.693Z","0.2.25":"2013-06-20T15:36:46.277Z","0.2.26":"2013-07-06T17:12:54.670Z","0.2.27":"2013-07-11T07:14:45.740Z","0.2.28":"2013-08-02T20:27:41.732Z","0.2.29":"2013-10-28T18:23:24.477Z","0.2.30":"2013-11-18T23:12:00.540Z","0.2.31":"2013-12-16T08:36:43.044Z","0.3.0":"2013-12-17T07:03:10.699Z","0.3.1":"2013-12-17T16:53:27.867Z","0.3.2":"2013-12-17T22:25:14.882Z","0.3.3":"2013-12-21T16:07:06.773Z","0.3.4":"2014-01-29T15:24:05.163Z","0.3.5":"2014-01-31T01:53:19.656Z","0.3.6":"2014-02-07T00:17:21.362Z","0.4.0":"2014-02-13T01:17:18.973Z","0.4.1":"2014-02-13T23:47:37.892Z","0.4.2":"2014-02-14T00:29:13.086Z","0.4.3":"2014-02-16T03:40:54.640Z","0.4.4":"2014-02-16T03:41:48.856Z","0.4.5":"2014-03-12T05:09:17.474Z","0.4.6":"2014-03-29T19:44:15.041Z","0.4.7":"2014-04-02T19:41:07.149Z","0.4.8":"2014-05-01T22:24:54.980Z","0.4.9":"2014-05-12T21:52:55.127Z","0.4.10":"2014-05-13T16:44:29.801Z","0.4.11":"2014-05-13T20:33:04.738Z","0.4.12":"2014-05-14T06:14:22.842Z","1.0.0":"2014-05-14T23:04:37.188Z","1.0.1":"2014-06-03T00:55:54.448Z","2.0.0":"2014-06-06T04:23:46.579Z","2.0.1":"2014-06-06T06:25:14.419Z","2.0.2":"2014-06-14T00:33:10.205Z","3.0.0":"2014-07-02T00:30:29.154Z","3.0.1":"2014-07-14T23:29:05.057Z","2.0.3":"2014-07-15T00:09:36.043Z","3.0.2":"2014-07-17T06:30:02.659Z","3.0.3":"2014-07-23T21:20:42.406Z","3.0.4":"2014-07-25T00:27:26.007Z","3.0.5":"2014-07-25T00:28:48.007Z","3.0.6":"2014-07-31T21:57:49.043Z","2.0.4":"2014-07-31T21:59:52.896Z"},"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"repository":{"url":"git://github.com/isaacs/npm-registry-client"},"users":{"fgribreau":true,"fengmk2":true},"readmeFilename":"README.md","homepage":"https://github.com/isaacs/npm-registry-client","bugs":{"url":"https://github.com/isaacs/npm-registry-client/issues"},"license":"ISC","_attachments":{}}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npm-registry-client/test/fixtures/underscore/1.3.3/cache.json nodejs-0.11.15/deps/npm/node_modules/npm-registry-client/test/fixtures/underscore/1.3.3/cache.json
--- nodejs-0.11.14/deps/npm/node_modules/npm-registry-client/test/fixtures/underscore/1.3.3/cache.json 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npm-registry-client/test/fixtures/underscore/1.3.3/cache.json 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1 @@
+{"name":"underscore","description":"JavaScript's functional programming helper library.","homepage":"http://documentcloud.github.com/underscore/","keywords":["util","functional","server","client","browser"],"author":{"name":"Jeremy Ashkenas","email":"jeremy@documentcloud.org"},"repository":{"type":"git","url":"git://github.com/documentcloud/underscore.git"},"main":"underscore.js","version":"1.3.3","_npmUser":{"name":"jashkenas","email":"jashkenas@gmail.com"},"_id":"underscore@1.3.3","dependencies":{},"devDependencies":{},"optionalDependencies":{},"engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.1.1","_nodeVersion":"v0.6.11","_defaultsLoaded":true,"dist":{"shasum":"47ac53683daf832bfa952e1774417da47817ae42","tarball":"http://registry.npmjs.org/underscore/-/underscore-1.3.3.tgz"},"readme":" __ \n /\\ \\ __ \n __ __ ___ \\_\\ \\ __ _ __ ____ ___ ___ _ __ __ /\\_\\ ____ \n /\\ \\/\\ \\ /' _ `\\ /'_ \\ /'__`\\/\\ __\\/ ,__\\ / ___\\ / __`\\/\\ __\\/'__`\\ \\/\\ \\ /',__\\ \n \\ \\ \\_\\ \\/\\ \\/\\ \\/\\ \\ \\ \\/\\ __/\\ \\ \\//\\__, `\\/\\ \\__//\\ \\ \\ \\ \\ \\//\\ __/ __ \\ \\ \\/\\__, `\\\n \\ \\____/\\ \\_\\ \\_\\ \\___,_\\ \\____\\\\ \\_\\\\/\\____/\\ \\____\\ \\____/\\ \\_\\\\ \\____\\/\\_\\ _\\ \\ \\/\\____/\n \\/___/ \\/_/\\/_/\\/__,_ /\\/____/ \\/_/ \\/___/ \\/____/\\/___/ \\/_/ \\/____/\\/_//\\ \\_\\ \\/___/ \n \\ \\____/ \n \\/___/\n \nUnderscore.js is a utility-belt library for JavaScript that provides \nsupport for the usual functional suspects (each, map, reduce, filter...) \nwithout extending any core JavaScript objects.\n\nFor Docs, License, Tests, and pre-packed downloads, see:\nhttp://documentcloud.github.com/underscore/\n\nMany thanks to our contributors:\nhttps://github.com/documentcloud/underscore/contributors\n","maintainers":[{"name":"documentcloud","email":"jeremy@documentcloud.org"},{"name":"jashkenas","email":"jashkenas@gmail.com"}],"directories":{}}
\ No newline at end of file
Binary files /tmp/Mhog4P8ZHE/nodejs-0.11.14/deps/npm/node_modules/npm-registry-client/test/fixtures/underscore/1.3.3/package.tgz and /tmp/Z_ez7cGlqC/nodejs-0.11.15/deps/npm/node_modules/npm-registry-client/test/fixtures/underscore/1.3.3/package.tgz differ
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npm-registry-client/test/fixtures/underscore/cache.json nodejs-0.11.15/deps/npm/node_modules/npm-registry-client/test/fixtures/underscore/cache.json
--- nodejs-0.11.14/deps/npm/node_modules/npm-registry-client/test/fixtures/underscore/cache.json 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npm-registry-client/test/fixtures/underscore/cache.json 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1 @@
+{"_id":"underscore","_rev":"72-47f2986bfd8e8b55068b204588bbf484","name":"underscore","description":"JavaScript's functional programming helper library.","dist-tags":{"latest":"1.3.3","stable":"1.3.3"},"versions":{"1.0.3":{"name":"underscore","description":"Functional programming aid for JavaScript. Works well with jQuery.","url":"http://documentcloud.github.com/underscore/","keywords":["util","functional","server","client","browser"],"author":{"name":"Jeremy Ashkenas","email":"jeremy@documentcloud.org"},"contributors":[],"dependencies":{},"lib":".","main":"underscore","version":"1.0.3","_id":"underscore@1.0.3","engines":{"node":"*"},"_nodeSupported":true,"_npmVersion":"0.2.7-2","_nodeVersion":"v0.3.1-pre","dist":{"tarball":"http://registry.npmjs.org/underscore/-/underscore-1.0.3.tgz"},"directories":{},"_npmUser":{"name":"jashkenas","email":"jashkenas@gmail.com"},"maintainers":[{"name":"documentcloud","email":"jeremy@documentcloud.org"},{"name":"jashkenas","email":"jashkenas@gmail.com"}]},"1.0.4":{"name":"underscore","description":"Functional programming aid for JavaScript. Works well with jQuery.","url":"http://documentcloud.github.com/underscore/","keywords":["util","functional","server","client","browser"],"author":{"name":"Jeremy Ashkenas","email":"jeremy@documentcloud.org"},"contributors":[],"dependencies":{},"lib":".","main":"underscore","version":"1.0.4","_id":"underscore@1.0.4","engines":{"node":"*"},"_nodeSupported":true,"_npmVersion":"0.2.7-2","_nodeVersion":"v0.3.1-pre","dist":{"tarball":"http://registry.npmjs.org/underscore/-/underscore-1.0.4.tgz"},"directories":{},"_npmUser":{"name":"jashkenas","email":"jashkenas@gmail.com"},"maintainers":[{"name":"documentcloud","email":"jeremy@documentcloud.org"},{"name":"jashkenas","email":"jashkenas@gmail.com"}]},"1.1.0":{"name":"underscore","description":"Functional programming aid for JavaScript. Works well with jQuery.","url":"http://documentcloud.github.com/underscore/","keywords":["util","functional","server","client","browser"],"author":{"name":"Jeremy Ashkenas","email":"jeremy@documentcloud.org"},"contributors":[],"dependencies":{},"lib":".","main":"underscore","version":"1.1.0","_id":"underscore@1.1.0","engines":{"node":"*"},"_nodeSupported":true,"_npmVersion":"0.2.7-2","_nodeVersion":"v0.3.1-pre","dist":{"tarball":"http://registry.npmjs.org/underscore/-/underscore-1.1.0.tgz"},"directories":{},"_npmUser":{"name":"jashkenas","email":"jashkenas@gmail.com"},"maintainers":[{"name":"documentcloud","email":"jeremy@documentcloud.org"},{"name":"jashkenas","email":"jashkenas@gmail.com"}]},"1.1.1":{"name":"underscore","description":"Functional programming aid for JavaScript. Works well with jQuery.","url":"http://documentcloud.github.com/underscore/","keywords":["util","functional","server","client","browser"],"author":{"name":"Jeremy Ashkenas","email":"jeremy@documentcloud.org"},"contributors":[],"dependencies":{},"lib":".","main":"underscore","version":"1.1.1","_id":"underscore@1.1.1","engines":{"node":"*"},"_nodeSupported":true,"_npmVersion":"0.2.7-2","_nodeVersion":"v0.3.1-pre","dist":{"tarball":"http://registry.npmjs.org/underscore/-/underscore-1.1.1.tgz"},"directories":{},"_npmUser":{"name":"jashkenas","email":"jashkenas@gmail.com"},"maintainers":[{"name":"documentcloud","email":"jeremy@documentcloud.org"},{"name":"jashkenas","email":"jashkenas@gmail.com"}]},"1.1.2":{"name":"underscore","description":"Functional programming aid for JavaScript. Works well with jQuery.","url":"http://documentcloud.github.com/underscore/","keywords":["util","functional","server","client","browser"],"author":{"name":"Jeremy Ashkenas","email":"jeremy@documentcloud.org"},"contributors":[],"dependencies":{},"lib":".","main":"underscore","version":"1.1.2","_id":"underscore@1.1.2","engines":{"node":"*"},"_nodeSupported":true,"_npmVersion":"0.2.7-2","_nodeVersion":"v0.3.1-pre","dist":{"tarball":"http://registry.npmjs.org/underscore/-/underscore-1.1.2.tgz"},"directories":{},"_npmUser":{"name":"jashkenas","email":"jashkenas@gmail.com"},"maintainers":[{"name":"documentcloud","email":"jeremy@documentcloud.org"},{"name":"jashkenas","email":"jashkenas@gmail.com"}]},"1.1.3":{"name":"underscore","description":"Functional programming aid for JavaScript. Works well with jQuery.","url":"http://documentcloud.github.com/underscore/","keywords":["util","functional","server","client","browser"],"author":{"name":"Jeremy Ashkenas","email":"jeremy@documentcloud.org"},"contributors":[],"dependencies":{},"lib":".","main":"underscore","version":"1.1.3","_id":"underscore@1.1.3","engines":{"node":"*"},"_nodeSupported":true,"_npmVersion":"0.2.8-1","_nodeVersion":"v0.2.5","dist":{"tarball":"http://registry.npmjs.org/underscore/-/underscore-1.1.3.tgz"},"directories":{},"_npmUser":{"name":"jashkenas","email":"jashkenas@gmail.com"},"maintainers":[{"name":"documentcloud","email":"jeremy@documentcloud.org"},{"name":"jashkenas","email":"jashkenas@gmail.com"}]},"1.1.4":{"name":"underscore","description":"Functional programming aid for JavaScript. Works well with jQuery.","url":"http://documentcloud.github.com/underscore/","keywords":["util","functional","server","client","browser"],"author":{"name":"Jeremy Ashkenas","email":"jeremy@documentcloud.org"},"contributors":[],"dependencies":{},"lib":".","main":"underscore.js","version":"1.1.4","_id":"underscore@1.1.4","engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"0.3.9","_nodeVersion":"v0.5.0-pre","dist":{"shasum":"9e82274902865625b3a6d4c315a38ffd80047dae","tarball":"http://registry.npmjs.org/underscore/-/underscore-1.1.4.tgz"},"_npmUser":{"name":"jashkenas","email":"jashkenas@gmail.com"},"maintainers":[{"name":"documentcloud","email":"jeremy@documentcloud.org"},{"name":"jashkenas","email":"jashkenas@gmail.com"}],"directories":{}},"1.1.5":{"name":"underscore","description":"JavaScript's functional programming helper library.","homepage":"http://documentcloud.github.com/underscore/","keywords":["util","functional","server","client","browser"],"author":{"name":"Jeremy Ashkenas","email":"jeremy@documentcloud.org"},"contributors":[],"dependencies":{},"repository":{"type":"git","url":"git://github.com/documentcloud/underscore.git"},"main":"underscore.js","version":"1.1.5","_id":"underscore@1.1.5","engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"0.3.16","_nodeVersion":"v0.4.2","directories":{},"files":[""],"_defaultsLoaded":true,"dist":{"shasum":"23601d62c75619998b2f0db24938102793336a56","tarball":"http://registry.npmjs.org/underscore/-/underscore-1.1.5.tgz"},"_npmUser":{"name":"jashkenas","email":"jashkenas@gmail.com"},"maintainers":[{"name":"documentcloud","email":"jeremy@documentcloud.org"},{"name":"jashkenas","email":"jashkenas@gmail.com"}]},"1.1.6":{"name":"underscore","description":"JavaScript's functional programming helper library.","homepage":"http://documentcloud.github.com/underscore/","keywords":["util","functional","server","client","browser"],"author":{"name":"Jeremy Ashkenas","email":"jeremy@documentcloud.org"},"contributors":[],"dependencies":{},"repository":{"type":"git","url":"git://github.com/documentcloud/underscore.git"},"main":"underscore.js","version":"1.1.6","_id":"underscore@1.1.6","engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"0.3.18","_nodeVersion":"v0.4.2","directories":{},"files":[""],"_defaultsLoaded":true,"dist":{"shasum":"6868da1bdd72d75285be0b4e50f228e70d001a2c","tarball":"http://registry.npmjs.org/underscore/-/underscore-1.1.6.tgz"},"_npmUser":{"name":"jashkenas","email":"jashkenas@gmail.com"},"maintainers":[{"name":"documentcloud","email":"jeremy@documentcloud.org"},{"name":"jashkenas","email":"jashkenas@gmail.com"}]},"1.1.7":{"name":"underscore","description":"JavaScript's functional programming helper library.","homepage":"http://documentcloud.github.com/underscore/","keywords":["util","functional","server","client","browser"],"author":{"name":"Jeremy Ashkenas","email":"jeremy@documentcloud.org"},"contributors":[],"dependencies":{},"repository":{"type":"git","url":"git://github.com/documentcloud/underscore.git"},"main":"underscore.js","version":"1.1.7","devDependencies":{},"_id":"underscore@1.1.7","engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.0.3","_nodeVersion":"v0.4.7","_defaultsLoaded":true,"dist":{"shasum":"40bab84bad19d230096e8d6ef628bff055d83db0","tarball":"http://registry.npmjs.org/underscore/-/underscore-1.1.7.tgz"},"scripts":{},"_npmUser":{"name":"jashkenas","email":"jashkenas@gmail.com"},"maintainers":[{"name":"documentcloud","email":"jeremy@documentcloud.org"},{"name":"jashkenas","email":"jashkenas@gmail.com"}],"directories":{}},"1.2.0":{"name":"underscore","description":"JavaScript's functional programming helper library.","homepage":"http://documentcloud.github.com/underscore/","keywords":["util","functional","server","client","browser"],"author":{"name":"Jeremy Ashkenas","email":"jeremy@documentcloud.org"},"contributors":[],"dependencies":{},"repository":{"type":"git","url":"git://github.com/documentcloud/underscore.git"},"main":"underscore.js","version":"1.2.0","_npmJsonOpts":{"file":"/Users/jashkenas/.npm/underscore/1.2.0/package/package.json","wscript":false,"contributors":false,"serverjs":false},"_id":"underscore@1.2.0","devDependencies":{},"engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.0.22","_nodeVersion":"v0.4.10","_defaultsLoaded":true,"dist":{"shasum":"b32ce32c8c118caa8031c10b54c7f65ab3b557fd","tarball":"http://registry.npmjs.org/underscore/-/underscore-1.2.0.tgz"},"scripts":{},"maintainers":[{"name":"documentcloud","email":"jeremy@documentcloud.org"},{"name":"jashkenas","email":"jashkenas@gmail.com"}],"_npmUser":{"name":"jashkenas","email":"jashkenas@gmail.com"},"directories":{}},"1.2.1":{"name":"underscore","description":"JavaScript's functional programming helper library.","homepage":"http://documentcloud.github.com/underscore/","keywords":["util","functional","server","client","browser"],"author":{"name":"Jeremy Ashkenas","email":"jeremy@documentcloud.org"},"contributors":[],"dependencies":{},"repository":{"type":"git","url":"git://github.com/documentcloud/underscore.git"},"main":"underscore.js","version":"1.2.1","_npmJsonOpts":{"file":"/Users/jashkenas/.npm/underscore/1.2.1/package/package.json","wscript":false,"contributors":false,"serverjs":false},"_id":"underscore@1.2.1","devDependencies":{},"engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.0.22","_nodeVersion":"v0.4.10","_defaultsLoaded":true,"dist":{"shasum":"fc5c6b0765673d92a2d4ac8b4dc0aa88702e2bd4","tarball":"http://registry.npmjs.org/underscore/-/underscore-1.2.1.tgz"},"scripts":{},"maintainers":[{"name":"documentcloud","email":"jeremy@documentcloud.org"},{"name":"jashkenas","email":"jashkenas@gmail.com"}],"_npmUser":{"name":"jashkenas","email":"jashkenas@gmail.com"},"directories":{}},"1.2.2":{"name":"underscore","description":"JavaScript's functional programming helper library.","homepage":"http://documentcloud.github.com/underscore/","keywords":["util","functional","server","client","browser"],"author":{"name":"Jeremy Ashkenas","email":"jeremy@documentcloud.org"},"contributors":[],"dependencies":{},"repository":{"type":"git","url":"git://github.com/documentcloud/underscore.git"},"main":"underscore.js","version":"1.2.2","_npmUser":{"name":"jashkenas","email":"jashkenas@gmail.com"},"_id":"underscore@1.2.2","devDependencies":{},"engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.0.104","_nodeVersion":"v0.6.0","_defaultsLoaded":true,"dist":{"shasum":"74dd40e9face84e724eb2edae945b8aedc233ba3","tarball":"http://registry.npmjs.org/underscore/-/underscore-1.2.2.tgz"},"maintainers":[{"name":"documentcloud","email":"jeremy@documentcloud.org"},{"name":"jashkenas","email":"jashkenas@gmail.com"}],"directories":{}},"1.2.3":{"name":"underscore","description":"JavaScript's functional programming helper library.","homepage":"http://documentcloud.github.com/underscore/","keywords":["util","functional","server","client","browser"],"author":{"name":"Jeremy Ashkenas","email":"jeremy@documentcloud.org"},"contributors":[],"dependencies":{},"repository":{"type":"git","url":"git://github.com/documentcloud/underscore.git"},"main":"underscore.js","version":"1.2.3","_npmUser":{"name":"jashkenas","email":"jashkenas@gmail.com"},"_id":"underscore@1.2.3","devDependencies":{},"engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.0.104","_nodeVersion":"v0.6.0","_defaultsLoaded":true,"dist":{"shasum":"11b874da70f4683d7d48bba2b44be1e600d2f6cf","tarball":"http://registry.npmjs.org/underscore/-/underscore-1.2.3.tgz"},"maintainers":[{"name":"documentcloud","email":"jeremy@documentcloud.org"},{"name":"jashkenas","email":"jashkenas@gmail.com"}],"directories":{}},"1.2.4":{"name":"underscore","description":"JavaScript's functional programming helper library.","homepage":"http://documentcloud.github.com/underscore/","keywords":["util","functional","server","client","browser"],"author":{"name":"Jeremy Ashkenas","email":"jeremy@documentcloud.org"},"contributors":[],"repository":{"type":"git","url":"git://github.com/documentcloud/underscore.git"},"main":"underscore.js","version":"1.2.4","_npmUser":{"name":"jashkenas","email":"jashkenas@gmail.com"},"_id":"underscore@1.2.4","dependencies":{},"devDependencies":{},"engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.0.104","_nodeVersion":"v0.6.6","_defaultsLoaded":true,"dist":{"shasum":"e8da6241aa06f64df2473bb2590b8c17c84c3c7e","tarball":"http://registry.npmjs.org/underscore/-/underscore-1.2.4.tgz"},"maintainers":[{"name":"documentcloud","email":"jeremy@documentcloud.org"},{"name":"jashkenas","email":"jashkenas@gmail.com"}],"directories":{}},"1.3.0":{"name":"underscore","description":"JavaScript's functional programming helper library.","homepage":"http://documentcloud.github.com/underscore/","keywords":["util","functional","server","client","browser"],"author":{"name":"Jeremy Ashkenas","email":"jeremy@documentcloud.org"},"contributors":[],"repository":{"type":"git","url":"git://github.com/documentcloud/underscore.git"},"main":"underscore.js","version":"1.3.0","_npmUser":{"name":"jashkenas","email":"jashkenas@gmail.com"},"_id":"underscore@1.3.0","dependencies":{},"devDependencies":{},"engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.0.104","_nodeVersion":"v0.6.6","_defaultsLoaded":true,"dist":{"shasum":"253b2d79b7bb67943ced0fc744eb18267963ede8","tarball":"http://registry.npmjs.org/underscore/-/underscore-1.3.0.tgz"},"maintainers":[{"name":"documentcloud","email":"jeremy@documentcloud.org"},{"name":"jashkenas","email":"jashkenas@gmail.com"}],"directories":{}},"1.3.1":{"name":"underscore","description":"JavaScript's functional programming helper library.","homepage":"http://documentcloud.github.com/underscore/","keywords":["util","functional","server","client","browser"],"author":{"name":"Jeremy Ashkenas","email":"jeremy@documentcloud.org"},"repository":{"type":"git","url":"git://github.com/documentcloud/underscore.git"},"main":"underscore.js","version":"1.3.1","_npmUser":{"name":"jashkenas","email":"jashkenas@gmail.com"},"_id":"underscore@1.3.1","dependencies":{},"devDependencies":{},"engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.0.104","_nodeVersion":"v0.6.6","_defaultsLoaded":true,"dist":{"shasum":"6cb8aad0e77eb5dbbfb54b22bcd8697309cf9641","tarball":"http://registry.npmjs.org/underscore/-/underscore-1.3.1.tgz"},"maintainers":[{"name":"documentcloud","email":"jeremy@documentcloud.org"},{"name":"jashkenas","email":"jashkenas@gmail.com"}],"directories":{}},"1.3.2":{"name":"underscore","description":"JavaScript's functional programming helper library.","homepage":"http://documentcloud.github.com/underscore/","keywords":["util","functional","server","client","browser"],"author":{"name":"Jeremy Ashkenas","email":"jeremy@documentcloud.org"},"repository":{"type":"git","url":"git://github.com/documentcloud/underscore.git"},"main":"underscore.js","version":"1.3.2","_npmUser":{"name":"jashkenas","email":"jashkenas@gmail.com"},"_id":"underscore@1.3.2","dependencies":{},"devDependencies":{},"optionalDependencies":{},"engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.1.1","_nodeVersion":"v0.6.11","_defaultsLoaded":true,"dist":{"shasum":"1b4e455089ab1d1d38ab6794ffe6cf08f764394a","tarball":"http://registry.npmjs.org/underscore/-/underscore-1.3.2.tgz"},"readme":" __ \n /\\ \\ __ \n __ __ ___ \\_\\ \\ __ _ __ ____ ___ ___ _ __ __ /\\_\\ ____ \n /\\ \\/\\ \\ /' _ `\\ /'_ \\ /'__`\\/\\ __\\/ ,__\\ / ___\\ / __`\\/\\ __\\/'__`\\ \\/\\ \\ /',__\\ \n \\ \\ \\_\\ \\/\\ \\/\\ \\/\\ \\ \\ \\/\\ __/\\ \\ \\//\\__, `\\/\\ \\__//\\ \\ \\ \\ \\ \\//\\ __/ __ \\ \\ \\/\\__, `\\\n \\ \\____/\\ \\_\\ \\_\\ \\___,_\\ \\____\\\\ \\_\\\\/\\____/\\ \\____\\ \\____/\\ \\_\\\\ \\____\\/\\_\\ _\\ \\ \\/\\____/\n \\/___/ \\/_/\\/_/\\/__,_ /\\/____/ \\/_/ \\/___/ \\/____/\\/___/ \\/_/ \\/____/\\/_//\\ \\_\\ \\/___/ \n \\ \\____/ \n \\/___/\n \nUnderscore.js is a utility-belt library for JavaScript that provides \nsupport for the usual functional suspects (each, map, reduce, filter...) \nwithout extending any core JavaScript objects.\n\nFor Docs, License, Tests, and pre-packed downloads, see:\nhttp://documentcloud.github.com/underscore/\n\nMany thanks to our contributors:\nhttps://github.com/documentcloud/underscore/contributors\n","maintainers":[{"name":"documentcloud","email":"jeremy@documentcloud.org"},{"name":"jashkenas","email":"jashkenas@gmail.com"}],"directories":{}},"1.3.3":{"name":"underscore","description":"JavaScript's functional programming helper library.","homepage":"http://documentcloud.github.com/underscore/","keywords":["util","functional","server","client","browser"],"author":{"name":"Jeremy Ashkenas","email":"jeremy@documentcloud.org"},"repository":{"type":"git","url":"git://github.com/documentcloud/underscore.git"},"main":"underscore.js","version":"1.3.3","_npmUser":{"name":"jashkenas","email":"jashkenas@gmail.com"},"_id":"underscore@1.3.3","dependencies":{},"devDependencies":{},"optionalDependencies":{},"engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.1.1","_nodeVersion":"v0.6.11","_defaultsLoaded":true,"dist":{"shasum":"47ac53683daf832bfa952e1774417da47817ae42","tarball":"http://registry.npmjs.org/underscore/-/underscore-1.3.3.tgz"},"readme":" __ \n /\\ \\ __ \n __ __ ___ \\_\\ \\ __ _ __ ____ ___ ___ _ __ __ /\\_\\ ____ \n /\\ \\/\\ \\ /' _ `\\ /'_ \\ /'__`\\/\\ __\\/ ,__\\ / ___\\ / __`\\/\\ __\\/'__`\\ \\/\\ \\ /',__\\ \n \\ \\ \\_\\ \\/\\ \\/\\ \\/\\ \\ \\ \\/\\ __/\\ \\ \\//\\__, `\\/\\ \\__//\\ \\ \\ \\ \\ \\//\\ __/ __ \\ \\ \\/\\__, `\\\n \\ \\____/\\ \\_\\ \\_\\ \\___,_\\ \\____\\\\ \\_\\\\/\\____/\\ \\____\\ \\____/\\ \\_\\\\ \\____\\/\\_\\ _\\ \\ \\/\\____/\n \\/___/ \\/_/\\/_/\\/__,_ /\\/____/ \\/_/ \\/___/ \\/____/\\/___/ \\/_/ \\/____/\\/_//\\ \\_\\ \\/___/ \n \\ \\____/ \n \\/___/\n \nUnderscore.js is a utility-belt library for JavaScript that provides \nsupport for the usual functional suspects (each, map, reduce, filter...) \nwithout extending any core JavaScript objects.\n\nFor Docs, License, Tests, and pre-packed downloads, see:\nhttp://documentcloud.github.com/underscore/\n\nMany thanks to our contributors:\nhttps://github.com/documentcloud/underscore/contributors\n","maintainers":[{"name":"documentcloud","email":"jeremy@documentcloud.org"},{"name":"jashkenas","email":"jashkenas@gmail.com"}],"directories":{}}},"maintainers":[{"name":"documentcloud","email":"jeremy@documentcloud.org"},{"name":"jashkenas","email":"jashkenas@gmail.com"}],"author":{"name":"Jeremy Ashkenas","email":"jeremy@documentcloud.org"},"time":{"1.0.3":"2011-12-07T15:12:18.045Z","1.0.4":"2011-12-07T15:12:18.045Z","1.1.0":"2011-12-07T15:12:18.045Z","1.1.1":"2011-12-07T15:12:18.045Z","1.1.2":"2011-12-07T15:12:18.045Z","1.1.3":"2011-12-07T15:12:18.045Z","1.1.4":"2011-12-07T15:12:18.045Z","1.1.5":"2011-12-07T15:12:18.045Z","1.1.6":"2011-12-07T15:12:18.045Z","1.1.7":"2011-12-07T15:12:18.045Z","1.2.0":"2011-12-07T15:12:18.045Z","1.2.1":"2011-12-07T15:12:18.045Z","1.2.2":"2011-11-14T20:28:47.115Z","1.2.3":"2011-12-07T15:12:18.045Z","1.2.4":"2012-01-09T17:23:14.818Z","1.3.0":"2012-01-11T16:41:38.459Z","1.3.1":"2012-01-23T22:57:36.474Z","1.3.2":"2012-04-09T18:38:14.345Z","1.3.3":"2012-04-10T14:43:48.089Z"},"repository":{"type":"git","url":"git://github.com/documentcloud/underscore.git"},"users":{"vesln":true,"mvolkmann":true,"lancehunt":true,"mikl":true,"linus":true,"vasc":true,"bat":true,"dmalam":true,"mbrevoort":true,"danielr":true,"rsimoes":true,"thlorenz":true}}
\ No newline at end of file
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npm-registry-client/test/lib/common.js nodejs-0.11.15/deps/npm/node_modules/npm-registry-client/test/lib/common.js
--- nodejs-0.11.14/deps/npm/node_modules/npm-registry-client/test/lib/common.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npm-registry-client/test/lib/common.js 2015-01-20 21:22:17.000000000 +0000
@@ -39,6 +39,10 @@
c.email = this.get(nerfed + ":email")
}
+ if (this.get(nerfed + ":always-auth") !== undefined) {
+ c.alwaysAuth = this.get(nerfed + ":always-auth")
+ }
+
if (c.username && c.password) {
c.auth = new Buffer(c.username + ":" + c.password).toString("base64")
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/npm-user-validate/package.json nodejs-0.11.15/deps/npm/node_modules/npm-user-validate/package.json
--- nodejs-0.11.14/deps/npm/node_modules/npm-user-validate/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/npm-user-validate/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -1,6 +1,6 @@
{
"name": "npm-user-validate",
- "version": "0.1.0",
+ "version": "0.1.1",
"description": "User validations for npm",
"main": "npm-user-validate.js",
"devDependencies": {
@@ -11,7 +11,7 @@
},
"repository": {
"type": "git",
- "url": "git://github.com/npm/npm-registry-mock.git"
+ "url": "git://github.com/npm/npm-user-validate.git"
},
"keywords": [
"npm",
@@ -23,13 +23,34 @@
"email": "rok@kowalski.gd"
},
"license": "BSD",
- "readme": "[![Build Status](https://travis-ci.org/npm/npm-user-validate.png?branch=master)](https://travis-ci.org/npm/npm-user-validate)\n[![devDependency Status](https://david-dm.org/npm/npm-user-validate/dev-status.png)](https://david-dm.org/npm/npm-user-validate#info=devDependencies)\n\n# npm-user-validate\n\nValidation for the npm client and npm-www (and probably other npm projects)\n",
- "readmeFilename": "README.md",
+ "gitHead": "64c9bd4ded742c41afdb3a8414fbbfdbfdcdf6b7",
"bugs": {
- "url": "https://github.com/npm/npm-registry-mock/issues"
+ "url": "https://github.com/npm/npm-user-validate/issues"
},
- "homepage": "https://github.com/npm/npm-registry-mock",
- "_id": "npm-user-validate@0.1.0",
- "_shasum": "358a5b5148ed3f79771d980388c6e34c4a61f638",
- "_from": "npm-user-validate@latest"
+ "homepage": "https://github.com/npm/npm-user-validate",
+ "_id": "npm-user-validate@0.1.1",
+ "_shasum": "ea7774636c3c8fe6d01e174bd9f2ee0e22eeed57",
+ "_from": "npm-user-validate@>=0.1.1 <0.2.0",
+ "_npmVersion": "2.1.3",
+ "_nodeVersion": "0.10.31",
+ "_npmUser": {
+ "name": "isaacs",
+ "email": "i@izs.me"
+ },
+ "maintainers": [
+ {
+ "name": "robertkowalski",
+ "email": "rok@kowalski.gd"
+ },
+ {
+ "name": "isaacs",
+ "email": "i@izs.me"
+ }
+ ],
+ "dist": {
+ "shasum": "ea7774636c3c8fe6d01e174bd9f2ee0e22eeed57",
+ "tarball": "http://registry.npmjs.org/npm-user-validate/-/npm-user-validate-0.1.1.tgz"
+ },
+ "directories": {},
+ "_resolved": "https://registry.npmjs.org/npm-user-validate/-/npm-user-validate-0.1.1.tgz"
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/once/once.js nodejs-0.11.15/deps/npm/node_modules/once/once.js
--- nodejs-0.11.14/deps/npm/node_modules/once/once.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/once/once.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,4 +1,5 @@
-module.exports = once
+var wrappy = require('wrappy')
+module.exports = wrappy(once)
once.proto = once(function () {
Object.defineProperty(Function.prototype, 'once', {
diff -Nru nodejs-0.11.14/deps/npm/node_modules/once/package.json nodejs-0.11.15/deps/npm/node_modules/once/package.json
--- nodejs-0.11.14/deps/npm/node_modules/once/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/once/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,14 @@
{
"name": "once",
- "version": "1.3.0",
+ "version": "1.3.1",
"description": "Run a function exactly one time",
"main": "once.js",
"directories": {
"test": "test"
},
- "dependencies": {},
+ "dependencies": {
+ "wrappy": "1"
+ },
"devDependencies": {
"tap": "~0.3.0"
},
@@ -29,11 +31,30 @@
"url": "http://blog.izs.me/"
},
"license": "BSD",
- "readme": "# once\n\nOnly call a function once.\n\n## usage\n\n```javascript\nvar once = require('once')\n\nfunction load (file, cb) {\n cb = once(cb)\n loader.load('file')\n loader.once('load', cb)\n loader.once('error', cb)\n}\n```\n\nOr add to the Function.prototype in a responsible way:\n\n```javascript\n// only has to be done once\nrequire('once').proto()\n\nfunction load (file, cb) {\n cb = cb.once()\n loader.load('file')\n loader.once('load', cb)\n loader.once('error', cb)\n}\n```\n\nIronically, the prototype feature makes this module twice as\ncomplicated as necessary.\n\nTo check whether you function has been called, use `fn.called`. Once the\nfunction is called for the first time the return value of the original\nfunction is saved in `fn.value` and subsequent calls will continue to\nreturn this value.\n\n```javascript\nvar once = require('once')\n\nfunction load (cb) {\n cb = once(cb)\n var stream = createStream()\n stream.once('data', cb)\n stream.once('end', function () {\n if (!cb.called) cb(new Error('not found'))\n })\n}\n```\n",
- "readmeFilename": "README.md",
+ "gitHead": "c90ac02a74f433ce47f6938869e68dd6196ffc2c",
"bugs": {
"url": "https://github.com/isaacs/once/issues"
},
- "_id": "once@1.3.0",
- "_from": "once@latest"
+ "homepage": "https://github.com/isaacs/once",
+ "_id": "once@1.3.1",
+ "_shasum": "f3f3e4da5b7d27b5c732969ee3e67e729457b31f",
+ "_from": "once@>=1.3.1 <2.0.0",
+ "_npmVersion": "2.0.0",
+ "_nodeVersion": "0.10.31",
+ "_npmUser": {
+ "name": "isaacs",
+ "email": "i@izs.me"
+ },
+ "maintainers": [
+ {
+ "name": "isaacs",
+ "email": "i@izs.me"
+ }
+ ],
+ "dist": {
+ "shasum": "f3f3e4da5b7d27b5c732969ee3e67e729457b31f",
+ "tarball": "http://registry.npmjs.org/once/-/once-1.3.1.tgz"
+ },
+ "_resolved": "https://registry.npmjs.org/once/-/once-1.3.1.tgz",
+ "readme": "ERROR: No README data found!"
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/once/test/once.js nodejs-0.11.15/deps/npm/node_modules/once/test/once.js
--- nodejs-0.11.14/deps/npm/node_modules/once/test/once.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/once/test/once.js 2015-01-20 21:22:17.000000000 +0000
@@ -3,11 +3,14 @@
test('once', function (t) {
var f = 0
- var foo = once(function (g) {
+ function fn (g) {
t.equal(f, 0)
f ++
return f + g + this
- })
+ }
+ fn.ownProperty = {}
+ var foo = once(fn)
+ t.equal(fn.ownProperty, foo.ownProperty)
t.notOk(foo.called)
for (var i = 0; i < 1E3; i++) {
t.same(f, i === 0 ? 0 : 1)
diff -Nru nodejs-0.11.14/deps/npm/node_modules/opener/LICENSE.txt nodejs-0.11.15/deps/npm/node_modules/opener/LICENSE.txt
--- nodejs-0.11.14/deps/npm/node_modules/opener/LICENSE.txt 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/opener/LICENSE.txt 2015-01-20 21:22:17.000000000 +0000
@@ -1,14 +1,19 @@
- DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
- Version 2, December 2004
-
- Copyright (C) 2012 Domenic Denicola
-
- Everyone is permitted to copy and distribute verbatim or modified
- copies of this license document, and changing it is allowed as long
- as the name is changed.
-
- DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
- TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
-
- 0. You just DO WHAT THE FUCK YOU WANT TO.
-
+Copyright © 2012–2014 Domenic Denicola
+
+This work is free. You can redistribute it and/or modify it under the
+terms of the Do What The Fuck You Want To Public License, Version 2,
+as published by Sam Hocevar. See below for more details.
+
+ DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
+ Version 2, December 2004
+
+ Copyright (C) 2004 Sam Hocevar
+
+ Everyone is permitted to copy and distribute verbatim or modified
+ copies of this license document, and changing it is allowed as long
+ as the name is changed.
+
+ DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
+ TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
+
+ 0. You just DO WHAT THE FUCK YOU WANT TO.
diff -Nru nodejs-0.11.14/deps/npm/node_modules/opener/opener.js nodejs-0.11.15/deps/npm/node_modules/opener/opener.js
--- nodejs-0.11.14/deps/npm/node_modules/opener/opener.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/opener/opener.js 2015-01-20 21:22:17.000000000 +0000
@@ -38,7 +38,7 @@
args = ["/c", "start", '""'].concat(args);
}
- childProcess.execFile(command, args, options, callback);
+ return childProcess.execFile(command, args, options, callback);
}
// Export `opener` for programmatic access.
diff -Nru nodejs-0.11.14/deps/npm/node_modules/opener/package.json nodejs-0.11.15/deps/npm/node_modules/opener/package.json
--- nodejs-0.11.14/deps/npm/node_modules/opener/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/opener/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -1,11 +1,11 @@
{
"name": "opener",
"description": "Opens stuff, like webpages and files and executables, cross-platform",
- "version": "1.3.0",
+ "version": "1.4.0",
"author": {
"name": "Domenic Denicola",
"email": "domenic@domenicdenicola.com",
- "url": "http://domenicdenicola.com"
+ "url": "http://domenic.me/"
},
"license": "WTFPL",
"repository": {
@@ -23,12 +23,28 @@
"lint": "jshint opener.js"
},
"devDependencies": {
- "jshint": ">= 0.9.0"
+ "jshint": "^2.5.4"
},
- "readme": "# It Opens Stuff\r\n\r\nThat is, in your desktop environment. This will make *actual windows pop up*, with stuff in them:\r\n\r\n```bash\r\nnpm install opener -g\r\n\r\nopener http://google.com\r\nopener ./my-file.txt\r\nopener firefox\r\nopener npm run lint\r\n```\r\n\r\nAlso if you want to use it programmatically you can do that too:\r\n\r\n```js\r\nvar opener = require(\"opener\");\r\n\r\nopener(\"http://google.com\");\r\nopener(\"./my-file.txt\");\r\nopener(\"firefox\");\r\nopener(\"npm run lint\");\r\n```\r\n\r\n## Use It for Good\r\n\r\nLike opening the user's browser with a test harness in your package's test script:\r\n\r\n```json\r\n{\r\n \"scripts\": {\r\n \"test\": \"opener ./test/runner.html\"\r\n },\r\n \"devDependencies\": {\r\n \"opener\": \"*\"\r\n }\r\n}\r\n```\r\n\r\n## Why\r\n\r\nBecause Windows has `start`, Macs have `open`, and *nix has `xdg-open`. At least\r\n[according to some guy on StackOverflow](http://stackoverflow.com/q/1480971/3191). And I like things that work on all\r\nthree. Like Node.js. And Opener.\r\n",
- "_id": "opener@1.3.0",
+ "gitHead": "b9d36d4f82c26560acdadbabbb10ddba46a30dc5",
+ "homepage": "https://github.com/domenic/opener",
+ "_id": "opener@1.4.0",
+ "_shasum": "d11f86eeeb076883735c9d509f538fe82d10b941",
+ "_from": "opener@>=1.4.0 <1.5.0",
+ "_npmVersion": "1.4.23",
+ "_npmUser": {
+ "name": "domenic",
+ "email": "domenic@domenicdenicola.com"
+ },
+ "maintainers": [
+ {
+ "name": "domenic",
+ "email": "domenic@domenicdenicola.com"
+ }
+ ],
"dist": {
- "shasum": "d72b4b2e61b0a4ca7822a7554070620002fb90d9"
+ "shasum": "d11f86eeeb076883735c9d509f538fe82d10b941",
+ "tarball": "http://registry.npmjs.org/opener/-/opener-1.4.0.tgz"
},
- "_from": "opener@latest"
+ "directories": {},
+ "_resolved": "https://registry.npmjs.org/opener/-/opener-1.4.0.tgz"
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/opener/README.md nodejs-0.11.15/deps/npm/node_modules/opener/README.md
--- nodejs-0.11.14/deps/npm/node_modules/opener/README.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/opener/README.md 2015-01-20 21:22:17.000000000 +0000
@@ -1,44 +1,57 @@
-# It Opens Stuff
-
-That is, in your desktop environment. This will make *actual windows pop up*, with stuff in them:
-
-```bash
-npm install opener -g
-
-opener http://google.com
-opener ./my-file.txt
-opener firefox
-opener npm run lint
-```
-
-Also if you want to use it programmatically you can do that too:
-
-```js
-var opener = require("opener");
-
-opener("http://google.com");
-opener("./my-file.txt");
-opener("firefox");
-opener("npm run lint");
-```
-
-## Use It for Good
-
-Like opening the user's browser with a test harness in your package's test script:
-
-```json
-{
- "scripts": {
- "test": "opener ./test/runner.html"
- },
- "devDependencies": {
- "opener": "*"
- }
-}
-```
-
-## Why
-
-Because Windows has `start`, Macs have `open`, and *nix has `xdg-open`. At least
-[according to some guy on StackOverflow](http://stackoverflow.com/q/1480971/3191). And I like things that work on all
-three. Like Node.js. And Opener.
+# It Opens Stuff
+
+That is, in your desktop environment. This will make *actual windows pop up*, with stuff in them:
+
+```bash
+npm install opener -g
+
+opener http://google.com
+opener ./my-file.txt
+opener firefox
+opener npm run lint
+```
+
+Also if you want to use it programmatically you can do that too:
+
+```js
+var opener = require("opener");
+
+opener("http://google.com");
+opener("./my-file.txt");
+opener("firefox");
+opener("npm run lint");
+```
+
+Plus, it returns the child process created, so you can do things like let your script exit while the window stays open:
+
+```js
+var editor = opener("documentation.odt");
+editor.unref();
+// These other unrefs may be necessary if your OS's opener process
+// exits before the process it started is complete.
+editor.stdin.unref();
+editor.stdout.unref();
+editor.stderr.unref();
+```
+
+
+## Use It for Good
+
+Like opening the user's browser with a test harness in your package's test script:
+
+```json
+{
+ "scripts": {
+ "test": "opener ./test/runner.html"
+ },
+ "devDependencies": {
+ "opener": "*"
+ }
+}
+```
+
+## Why
+
+Because Windows has `start`, Macs have `open`, and *nix has `xdg-open`. At least
+[according to some guy on StackOverflow](http://stackoverflow.com/q/1480971/3191). And I like things that work on all
+three. Like Node.js. And Opener.
diff -Nru nodejs-0.11.14/deps/npm/node_modules/readable-stream/duplex.js nodejs-0.11.15/deps/npm/node_modules/readable-stream/duplex.js
--- nodejs-0.11.14/deps/npm/node_modules/readable-stream/duplex.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/readable-stream/duplex.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1 @@
+module.exports = require("./lib/_stream_duplex.js")
diff -Nru nodejs-0.11.14/deps/npm/node_modules/readable-stream/lib/_stream_duplex.js nodejs-0.11.15/deps/npm/node_modules/readable-stream/lib/_stream_duplex.js
--- nodejs-0.11.14/deps/npm/node_modules/readable-stream/lib/_stream_duplex.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/readable-stream/lib/_stream_duplex.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,89 @@
+// Copyright Joyent, Inc. and other Node contributors.
+//
+// Permission is hereby granted, free of charge, to any person obtaining a
+// copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to permit
+// persons to whom the Software is furnished to do so, subject to the
+// following conditions:
+//
+// The above copyright notice and this permission notice shall be included
+// in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
+// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
+// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
+// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
+// USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+// a duplex stream is just a stream that is both readable and writable.
+// Since JS doesn't have multiple prototypal inheritance, this class
+// prototypally inherits from Readable, and then parasitically from
+// Writable.
+
+module.exports = Duplex;
+
+/**/
+var objectKeys = Object.keys || function (obj) {
+ var keys = [];
+ for (var key in obj) keys.push(key);
+ return keys;
+}
+/* */
+
+
+/**/
+var util = require('core-util-is');
+util.inherits = require('inherits');
+/* */
+
+var Readable = require('./_stream_readable');
+var Writable = require('./_stream_writable');
+
+util.inherits(Duplex, Readable);
+
+forEach(objectKeys(Writable.prototype), function(method) {
+ if (!Duplex.prototype[method])
+ Duplex.prototype[method] = Writable.prototype[method];
+});
+
+function Duplex(options) {
+ if (!(this instanceof Duplex))
+ return new Duplex(options);
+
+ Readable.call(this, options);
+ Writable.call(this, options);
+
+ if (options && options.readable === false)
+ this.readable = false;
+
+ if (options && options.writable === false)
+ this.writable = false;
+
+ this.allowHalfOpen = true;
+ if (options && options.allowHalfOpen === false)
+ this.allowHalfOpen = false;
+
+ this.once('end', onend);
+}
+
+// the no-half-open enforcer
+function onend() {
+ // if we allow half-open state, or if the writable side ended,
+ // then we're ok.
+ if (this.allowHalfOpen || this._writableState.ended)
+ return;
+
+ // no more data can be written.
+ // But allow more writes to happen in this tick.
+ process.nextTick(this.end.bind(this));
+}
+
+function forEach (xs, f) {
+ for (var i = 0, l = xs.length; i < l; i++) {
+ f(xs[i], i);
+ }
+}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/readable-stream/lib/_stream_passthrough.js nodejs-0.11.15/deps/npm/node_modules/readable-stream/lib/_stream_passthrough.js
--- nodejs-0.11.14/deps/npm/node_modules/readable-stream/lib/_stream_passthrough.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/readable-stream/lib/_stream_passthrough.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,46 @@
+// Copyright Joyent, Inc. and other Node contributors.
+//
+// Permission is hereby granted, free of charge, to any person obtaining a
+// copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to permit
+// persons to whom the Software is furnished to do so, subject to the
+// following conditions:
+//
+// The above copyright notice and this permission notice shall be included
+// in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
+// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
+// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
+// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
+// USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+// a passthrough stream.
+// basically just the most minimal sort of Transform stream.
+// Every written chunk gets output as-is.
+
+module.exports = PassThrough;
+
+var Transform = require('./_stream_transform');
+
+/**/
+var util = require('core-util-is');
+util.inherits = require('inherits');
+/* */
+
+util.inherits(PassThrough, Transform);
+
+function PassThrough(options) {
+ if (!(this instanceof PassThrough))
+ return new PassThrough(options);
+
+ Transform.call(this, options);
+}
+
+PassThrough.prototype._transform = function(chunk, encoding, cb) {
+ cb(null, chunk);
+};
diff -Nru nodejs-0.11.14/deps/npm/node_modules/readable-stream/lib/_stream_readable.js nodejs-0.11.15/deps/npm/node_modules/readable-stream/lib/_stream_readable.js
--- nodejs-0.11.14/deps/npm/node_modules/readable-stream/lib/_stream_readable.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/readable-stream/lib/_stream_readable.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,982 @@
+// Copyright Joyent, Inc. and other Node contributors.
+//
+// Permission is hereby granted, free of charge, to any person obtaining a
+// copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to permit
+// persons to whom the Software is furnished to do so, subject to the
+// following conditions:
+//
+// The above copyright notice and this permission notice shall be included
+// in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
+// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
+// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
+// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
+// USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+module.exports = Readable;
+
+/**/
+var isArray = require('isarray');
+/* */
+
+
+/**/
+var Buffer = require('buffer').Buffer;
+/* */
+
+Readable.ReadableState = ReadableState;
+
+var EE = require('events').EventEmitter;
+
+/**/
+if (!EE.listenerCount) EE.listenerCount = function(emitter, type) {
+ return emitter.listeners(type).length;
+};
+/* */
+
+var Stream = require('stream');
+
+/**/
+var util = require('core-util-is');
+util.inherits = require('inherits');
+/* */
+
+var StringDecoder;
+
+util.inherits(Readable, Stream);
+
+function ReadableState(options, stream) {
+ options = options || {};
+
+ // the point at which it stops calling _read() to fill the buffer
+ // Note: 0 is a valid value, means "don't call _read preemptively ever"
+ var hwm = options.highWaterMark;
+ this.highWaterMark = (hwm || hwm === 0) ? hwm : 16 * 1024;
+
+ // cast to ints.
+ this.highWaterMark = ~~this.highWaterMark;
+
+ this.buffer = [];
+ this.length = 0;
+ this.pipes = null;
+ this.pipesCount = 0;
+ this.flowing = false;
+ this.ended = false;
+ this.endEmitted = false;
+ this.reading = false;
+
+ // In streams that never have any data, and do push(null) right away,
+ // the consumer can miss the 'end' event if they do some I/O before
+ // consuming the stream. So, we don't emit('end') until some reading
+ // happens.
+ this.calledRead = false;
+
+ // a flag to be able to tell if the onwrite cb is called immediately,
+ // or on a later tick. We set this to true at first, becuase any
+ // actions that shouldn't happen until "later" should generally also
+ // not happen before the first write call.
+ this.sync = true;
+
+ // whenever we return null, then we set a flag to say
+ // that we're awaiting a 'readable' event emission.
+ this.needReadable = false;
+ this.emittedReadable = false;
+ this.readableListening = false;
+
+
+ // object stream flag. Used to make read(n) ignore n and to
+ // make all the buffer merging and length checks go away
+ this.objectMode = !!options.objectMode;
+
+ // Crypto is kind of old and crusty. Historically, its default string
+ // encoding is 'binary' so we have to make this configurable.
+ // Everything else in the universe uses 'utf8', though.
+ this.defaultEncoding = options.defaultEncoding || 'utf8';
+
+ // when piping, we only care about 'readable' events that happen
+ // after read()ing all the bytes and not getting any pushback.
+ this.ranOut = false;
+
+ // the number of writers that are awaiting a drain event in .pipe()s
+ this.awaitDrain = 0;
+
+ // if true, a maybeReadMore has been scheduled
+ this.readingMore = false;
+
+ this.decoder = null;
+ this.encoding = null;
+ if (options.encoding) {
+ if (!StringDecoder)
+ StringDecoder = require('string_decoder/').StringDecoder;
+ this.decoder = new StringDecoder(options.encoding);
+ this.encoding = options.encoding;
+ }
+}
+
+function Readable(options) {
+ if (!(this instanceof Readable))
+ return new Readable(options);
+
+ this._readableState = new ReadableState(options, this);
+
+ // legacy
+ this.readable = true;
+
+ Stream.call(this);
+}
+
+// Manually shove something into the read() buffer.
+// This returns true if the highWaterMark has not been hit yet,
+// similar to how Writable.write() returns true if you should
+// write() some more.
+Readable.prototype.push = function(chunk, encoding) {
+ var state = this._readableState;
+
+ if (typeof chunk === 'string' && !state.objectMode) {
+ encoding = encoding || state.defaultEncoding;
+ if (encoding !== state.encoding) {
+ chunk = new Buffer(chunk, encoding);
+ encoding = '';
+ }
+ }
+
+ return readableAddChunk(this, state, chunk, encoding, false);
+};
+
+// Unshift should *always* be something directly out of read()
+Readable.prototype.unshift = function(chunk) {
+ var state = this._readableState;
+ return readableAddChunk(this, state, chunk, '', true);
+};
+
+function readableAddChunk(stream, state, chunk, encoding, addToFront) {
+ var er = chunkInvalid(state, chunk);
+ if (er) {
+ stream.emit('error', er);
+ } else if (chunk === null || chunk === undefined) {
+ state.reading = false;
+ if (!state.ended)
+ onEofChunk(stream, state);
+ } else if (state.objectMode || chunk && chunk.length > 0) {
+ if (state.ended && !addToFront) {
+ var e = new Error('stream.push() after EOF');
+ stream.emit('error', e);
+ } else if (state.endEmitted && addToFront) {
+ var e = new Error('stream.unshift() after end event');
+ stream.emit('error', e);
+ } else {
+ if (state.decoder && !addToFront && !encoding)
+ chunk = state.decoder.write(chunk);
+
+ // update the buffer info.
+ state.length += state.objectMode ? 1 : chunk.length;
+ if (addToFront) {
+ state.buffer.unshift(chunk);
+ } else {
+ state.reading = false;
+ state.buffer.push(chunk);
+ }
+
+ if (state.needReadable)
+ emitReadable(stream);
+
+ maybeReadMore(stream, state);
+ }
+ } else if (!addToFront) {
+ state.reading = false;
+ }
+
+ return needMoreData(state);
+}
+
+
+
+// if it's past the high water mark, we can push in some more.
+// Also, if we have no data yet, we can stand some
+// more bytes. This is to work around cases where hwm=0,
+// such as the repl. Also, if the push() triggered a
+// readable event, and the user called read(largeNumber) such that
+// needReadable was set, then we ought to push more, so that another
+// 'readable' event will be triggered.
+function needMoreData(state) {
+ return !state.ended &&
+ (state.needReadable ||
+ state.length < state.highWaterMark ||
+ state.length === 0);
+}
+
+// backwards compatibility.
+Readable.prototype.setEncoding = function(enc) {
+ if (!StringDecoder)
+ StringDecoder = require('string_decoder/').StringDecoder;
+ this._readableState.decoder = new StringDecoder(enc);
+ this._readableState.encoding = enc;
+};
+
+// Don't raise the hwm > 128MB
+var MAX_HWM = 0x800000;
+function roundUpToNextPowerOf2(n) {
+ if (n >= MAX_HWM) {
+ n = MAX_HWM;
+ } else {
+ // Get the next highest power of 2
+ n--;
+ for (var p = 1; p < 32; p <<= 1) n |= n >> p;
+ n++;
+ }
+ return n;
+}
+
+function howMuchToRead(n, state) {
+ if (state.length === 0 && state.ended)
+ return 0;
+
+ if (state.objectMode)
+ return n === 0 ? 0 : 1;
+
+ if (n === null || isNaN(n)) {
+ // only flow one buffer at a time
+ if (state.flowing && state.buffer.length)
+ return state.buffer[0].length;
+ else
+ return state.length;
+ }
+
+ if (n <= 0)
+ return 0;
+
+ // If we're asking for more than the target buffer level,
+ // then raise the water mark. Bump up to the next highest
+ // power of 2, to prevent increasing it excessively in tiny
+ // amounts.
+ if (n > state.highWaterMark)
+ state.highWaterMark = roundUpToNextPowerOf2(n);
+
+ // don't have that much. return null, unless we've ended.
+ if (n > state.length) {
+ if (!state.ended) {
+ state.needReadable = true;
+ return 0;
+ } else
+ return state.length;
+ }
+
+ return n;
+}
+
+// you can override either this method, or the async _read(n) below.
+Readable.prototype.read = function(n) {
+ var state = this._readableState;
+ state.calledRead = true;
+ var nOrig = n;
+ var ret;
+
+ if (typeof n !== 'number' || n > 0)
+ state.emittedReadable = false;
+
+ // if we're doing read(0) to trigger a readable event, but we
+ // already have a bunch of data in the buffer, then just trigger
+ // the 'readable' event and move on.
+ if (n === 0 &&
+ state.needReadable &&
+ (state.length >= state.highWaterMark || state.ended)) {
+ emitReadable(this);
+ return null;
+ }
+
+ n = howMuchToRead(n, state);
+
+ // if we've ended, and we're now clear, then finish it up.
+ if (n === 0 && state.ended) {
+ ret = null;
+
+ // In cases where the decoder did not receive enough data
+ // to produce a full chunk, then immediately received an
+ // EOF, state.buffer will contain [, ].
+ // howMuchToRead will see this and coerce the amount to
+ // read to zero (because it's looking at the length of the
+ // first in state.buffer), and we'll end up here.
+ //
+ // This can only happen via state.decoder -- no other venue
+ // exists for pushing a zero-length chunk into state.buffer
+ // and triggering this behavior. In this case, we return our
+ // remaining data and end the stream, if appropriate.
+ if (state.length > 0 && state.decoder) {
+ ret = fromList(n, state);
+ state.length -= ret.length;
+ }
+
+ if (state.length === 0)
+ endReadable(this);
+
+ return ret;
+ }
+
+ // All the actual chunk generation logic needs to be
+ // *below* the call to _read. The reason is that in certain
+ // synthetic stream cases, such as passthrough streams, _read
+ // may be a completely synchronous operation which may change
+ // the state of the read buffer, providing enough data when
+ // before there was *not* enough.
+ //
+ // So, the steps are:
+ // 1. Figure out what the state of things will be after we do
+ // a read from the buffer.
+ //
+ // 2. If that resulting state will trigger a _read, then call _read.
+ // Note that this may be asynchronous, or synchronous. Yes, it is
+ // deeply ugly to write APIs this way, but that still doesn't mean
+ // that the Readable class should behave improperly, as streams are
+ // designed to be sync/async agnostic.
+ // Take note if the _read call is sync or async (ie, if the read call
+ // has returned yet), so that we know whether or not it's safe to emit
+ // 'readable' etc.
+ //
+ // 3. Actually pull the requested chunks out of the buffer and return.
+
+ // if we need a readable event, then we need to do some reading.
+ var doRead = state.needReadable;
+
+ // if we currently have less than the highWaterMark, then also read some
+ if (state.length - n <= state.highWaterMark)
+ doRead = true;
+
+ // however, if we've ended, then there's no point, and if we're already
+ // reading, then it's unnecessary.
+ if (state.ended || state.reading)
+ doRead = false;
+
+ if (doRead) {
+ state.reading = true;
+ state.sync = true;
+ // if the length is currently zero, then we *need* a readable event.
+ if (state.length === 0)
+ state.needReadable = true;
+ // call internal read method
+ this._read(state.highWaterMark);
+ state.sync = false;
+ }
+
+ // If _read called its callback synchronously, then `reading`
+ // will be false, and we need to re-evaluate how much data we
+ // can return to the user.
+ if (doRead && !state.reading)
+ n = howMuchToRead(nOrig, state);
+
+ if (n > 0)
+ ret = fromList(n, state);
+ else
+ ret = null;
+
+ if (ret === null) {
+ state.needReadable = true;
+ n = 0;
+ }
+
+ state.length -= n;
+
+ // If we have nothing in the buffer, then we want to know
+ // as soon as we *do* get something into the buffer.
+ if (state.length === 0 && !state.ended)
+ state.needReadable = true;
+
+ // If we happened to read() exactly the remaining amount in the
+ // buffer, and the EOF has been seen at this point, then make sure
+ // that we emit 'end' on the very next tick.
+ if (state.ended && !state.endEmitted && state.length === 0)
+ endReadable(this);
+
+ return ret;
+};
+
+function chunkInvalid(state, chunk) {
+ var er = null;
+ if (!Buffer.isBuffer(chunk) &&
+ 'string' !== typeof chunk &&
+ chunk !== null &&
+ chunk !== undefined &&
+ !state.objectMode) {
+ er = new TypeError('Invalid non-string/buffer chunk');
+ }
+ return er;
+}
+
+
+function onEofChunk(stream, state) {
+ if (state.decoder && !state.ended) {
+ var chunk = state.decoder.end();
+ if (chunk && chunk.length) {
+ state.buffer.push(chunk);
+ state.length += state.objectMode ? 1 : chunk.length;
+ }
+ }
+ state.ended = true;
+
+ // if we've ended and we have some data left, then emit
+ // 'readable' now to make sure it gets picked up.
+ if (state.length > 0)
+ emitReadable(stream);
+ else
+ endReadable(stream);
+}
+
+// Don't emit readable right away in sync mode, because this can trigger
+// another read() call => stack overflow. This way, it might trigger
+// a nextTick recursion warning, but that's not so bad.
+function emitReadable(stream) {
+ var state = stream._readableState;
+ state.needReadable = false;
+ if (state.emittedReadable)
+ return;
+
+ state.emittedReadable = true;
+ if (state.sync)
+ process.nextTick(function() {
+ emitReadable_(stream);
+ });
+ else
+ emitReadable_(stream);
+}
+
+function emitReadable_(stream) {
+ stream.emit('readable');
+}
+
+
+// at this point, the user has presumably seen the 'readable' event,
+// and called read() to consume some data. that may have triggered
+// in turn another _read(n) call, in which case reading = true if
+// it's in progress.
+// However, if we're not ended, or reading, and the length < hwm,
+// then go ahead and try to read some more preemptively.
+function maybeReadMore(stream, state) {
+ if (!state.readingMore) {
+ state.readingMore = true;
+ process.nextTick(function() {
+ maybeReadMore_(stream, state);
+ });
+ }
+}
+
+function maybeReadMore_(stream, state) {
+ var len = state.length;
+ while (!state.reading && !state.flowing && !state.ended &&
+ state.length < state.highWaterMark) {
+ stream.read(0);
+ if (len === state.length)
+ // didn't get any data, stop spinning.
+ break;
+ else
+ len = state.length;
+ }
+ state.readingMore = false;
+}
+
+// abstract method. to be overridden in specific implementation classes.
+// call cb(er, data) where data is <= n in length.
+// for virtual (non-string, non-buffer) streams, "length" is somewhat
+// arbitrary, and perhaps not very meaningful.
+Readable.prototype._read = function(n) {
+ this.emit('error', new Error('not implemented'));
+};
+
+Readable.prototype.pipe = function(dest, pipeOpts) {
+ var src = this;
+ var state = this._readableState;
+
+ switch (state.pipesCount) {
+ case 0:
+ state.pipes = dest;
+ break;
+ case 1:
+ state.pipes = [state.pipes, dest];
+ break;
+ default:
+ state.pipes.push(dest);
+ break;
+ }
+ state.pipesCount += 1;
+
+ var doEnd = (!pipeOpts || pipeOpts.end !== false) &&
+ dest !== process.stdout &&
+ dest !== process.stderr;
+
+ var endFn = doEnd ? onend : cleanup;
+ if (state.endEmitted)
+ process.nextTick(endFn);
+ else
+ src.once('end', endFn);
+
+ dest.on('unpipe', onunpipe);
+ function onunpipe(readable) {
+ if (readable !== src) return;
+ cleanup();
+ }
+
+ function onend() {
+ dest.end();
+ }
+
+ // when the dest drains, it reduces the awaitDrain counter
+ // on the source. This would be more elegant with a .once()
+ // handler in flow(), but adding and removing repeatedly is
+ // too slow.
+ var ondrain = pipeOnDrain(src);
+ dest.on('drain', ondrain);
+
+ function cleanup() {
+ // cleanup event handlers once the pipe is broken
+ dest.removeListener('close', onclose);
+ dest.removeListener('finish', onfinish);
+ dest.removeListener('drain', ondrain);
+ dest.removeListener('error', onerror);
+ dest.removeListener('unpipe', onunpipe);
+ src.removeListener('end', onend);
+ src.removeListener('end', cleanup);
+
+ // if the reader is waiting for a drain event from this
+ // specific writer, then it would cause it to never start
+ // flowing again.
+ // So, if this is awaiting a drain, then we just call it now.
+ // If we don't know, then assume that we are waiting for one.
+ if (!dest._writableState || dest._writableState.needDrain)
+ ondrain();
+ }
+
+ // if the dest has an error, then stop piping into it.
+ // however, don't suppress the throwing behavior for this.
+ function onerror(er) {
+ unpipe();
+ dest.removeListener('error', onerror);
+ if (EE.listenerCount(dest, 'error') === 0)
+ dest.emit('error', er);
+ }
+ // This is a brutally ugly hack to make sure that our error handler
+ // is attached before any userland ones. NEVER DO THIS.
+ if (!dest._events || !dest._events.error)
+ dest.on('error', onerror);
+ else if (isArray(dest._events.error))
+ dest._events.error.unshift(onerror);
+ else
+ dest._events.error = [onerror, dest._events.error];
+
+
+
+ // Both close and finish should trigger unpipe, but only once.
+ function onclose() {
+ dest.removeListener('finish', onfinish);
+ unpipe();
+ }
+ dest.once('close', onclose);
+ function onfinish() {
+ dest.removeListener('close', onclose);
+ unpipe();
+ }
+ dest.once('finish', onfinish);
+
+ function unpipe() {
+ src.unpipe(dest);
+ }
+
+ // tell the dest that it's being piped to
+ dest.emit('pipe', src);
+
+ // start the flow if it hasn't been started already.
+ if (!state.flowing) {
+ // the handler that waits for readable events after all
+ // the data gets sucked out in flow.
+ // This would be easier to follow with a .once() handler
+ // in flow(), but that is too slow.
+ this.on('readable', pipeOnReadable);
+
+ state.flowing = true;
+ process.nextTick(function() {
+ flow(src);
+ });
+ }
+
+ return dest;
+};
+
+function pipeOnDrain(src) {
+ return function() {
+ var dest = this;
+ var state = src._readableState;
+ state.awaitDrain--;
+ if (state.awaitDrain === 0)
+ flow(src);
+ };
+}
+
+function flow(src) {
+ var state = src._readableState;
+ var chunk;
+ state.awaitDrain = 0;
+
+ function write(dest, i, list) {
+ var written = dest.write(chunk);
+ if (false === written) {
+ state.awaitDrain++;
+ }
+ }
+
+ while (state.pipesCount && null !== (chunk = src.read())) {
+
+ if (state.pipesCount === 1)
+ write(state.pipes, 0, null);
+ else
+ forEach(state.pipes, write);
+
+ src.emit('data', chunk);
+
+ // if anyone needs a drain, then we have to wait for that.
+ if (state.awaitDrain > 0)
+ return;
+ }
+
+ // if every destination was unpiped, either before entering this
+ // function, or in the while loop, then stop flowing.
+ //
+ // NB: This is a pretty rare edge case.
+ if (state.pipesCount === 0) {
+ state.flowing = false;
+
+ // if there were data event listeners added, then switch to old mode.
+ if (EE.listenerCount(src, 'data') > 0)
+ emitDataEvents(src);
+ return;
+ }
+
+ // at this point, no one needed a drain, so we just ran out of data
+ // on the next readable event, start it over again.
+ state.ranOut = true;
+}
+
+function pipeOnReadable() {
+ if (this._readableState.ranOut) {
+ this._readableState.ranOut = false;
+ flow(this);
+ }
+}
+
+
+Readable.prototype.unpipe = function(dest) {
+ var state = this._readableState;
+
+ // if we're not piping anywhere, then do nothing.
+ if (state.pipesCount === 0)
+ return this;
+
+ // just one destination. most common case.
+ if (state.pipesCount === 1) {
+ // passed in one, but it's not the right one.
+ if (dest && dest !== state.pipes)
+ return this;
+
+ if (!dest)
+ dest = state.pipes;
+
+ // got a match.
+ state.pipes = null;
+ state.pipesCount = 0;
+ this.removeListener('readable', pipeOnReadable);
+ state.flowing = false;
+ if (dest)
+ dest.emit('unpipe', this);
+ return this;
+ }
+
+ // slow case. multiple pipe destinations.
+
+ if (!dest) {
+ // remove all.
+ var dests = state.pipes;
+ var len = state.pipesCount;
+ state.pipes = null;
+ state.pipesCount = 0;
+ this.removeListener('readable', pipeOnReadable);
+ state.flowing = false;
+
+ for (var i = 0; i < len; i++)
+ dests[i].emit('unpipe', this);
+ return this;
+ }
+
+ // try to find the right one.
+ var i = indexOf(state.pipes, dest);
+ if (i === -1)
+ return this;
+
+ state.pipes.splice(i, 1);
+ state.pipesCount -= 1;
+ if (state.pipesCount === 1)
+ state.pipes = state.pipes[0];
+
+ dest.emit('unpipe', this);
+
+ return this;
+};
+
+// set up data events if they are asked for
+// Ensure readable listeners eventually get something
+Readable.prototype.on = function(ev, fn) {
+ var res = Stream.prototype.on.call(this, ev, fn);
+
+ if (ev === 'data' && !this._readableState.flowing)
+ emitDataEvents(this);
+
+ if (ev === 'readable' && this.readable) {
+ var state = this._readableState;
+ if (!state.readableListening) {
+ state.readableListening = true;
+ state.emittedReadable = false;
+ state.needReadable = true;
+ if (!state.reading) {
+ this.read(0);
+ } else if (state.length) {
+ emitReadable(this, state);
+ }
+ }
+ }
+
+ return res;
+};
+Readable.prototype.addListener = Readable.prototype.on;
+
+// pause() and resume() are remnants of the legacy readable stream API
+// If the user uses them, then switch into old mode.
+Readable.prototype.resume = function() {
+ emitDataEvents(this);
+ this.read(0);
+ this.emit('resume');
+};
+
+Readable.prototype.pause = function() {
+ emitDataEvents(this, true);
+ this.emit('pause');
+};
+
+function emitDataEvents(stream, startPaused) {
+ var state = stream._readableState;
+
+ if (state.flowing) {
+ // https://github.com/isaacs/readable-stream/issues/16
+ throw new Error('Cannot switch to old mode now.');
+ }
+
+ var paused = startPaused || false;
+ var readable = false;
+
+ // convert to an old-style stream.
+ stream.readable = true;
+ stream.pipe = Stream.prototype.pipe;
+ stream.on = stream.addListener = Stream.prototype.on;
+
+ stream.on('readable', function() {
+ readable = true;
+
+ var c;
+ while (!paused && (null !== (c = stream.read())))
+ stream.emit('data', c);
+
+ if (c === null) {
+ readable = false;
+ stream._readableState.needReadable = true;
+ }
+ });
+
+ stream.pause = function() {
+ paused = true;
+ this.emit('pause');
+ };
+
+ stream.resume = function() {
+ paused = false;
+ if (readable)
+ process.nextTick(function() {
+ stream.emit('readable');
+ });
+ else
+ this.read(0);
+ this.emit('resume');
+ };
+
+ // now make it start, just in case it hadn't already.
+ stream.emit('readable');
+}
+
+// wrap an old-style stream as the async data source.
+// This is *not* part of the readable stream interface.
+// It is an ugly unfortunate mess of history.
+Readable.prototype.wrap = function(stream) {
+ var state = this._readableState;
+ var paused = false;
+
+ var self = this;
+ stream.on('end', function() {
+ if (state.decoder && !state.ended) {
+ var chunk = state.decoder.end();
+ if (chunk && chunk.length)
+ self.push(chunk);
+ }
+
+ self.push(null);
+ });
+
+ stream.on('data', function(chunk) {
+ if (state.decoder)
+ chunk = state.decoder.write(chunk);
+
+ // don't skip over falsy values in objectMode
+ //if (state.objectMode && util.isNullOrUndefined(chunk))
+ if (state.objectMode && (chunk === null || chunk === undefined))
+ return;
+ else if (!state.objectMode && (!chunk || !chunk.length))
+ return;
+
+ var ret = self.push(chunk);
+ if (!ret) {
+ paused = true;
+ stream.pause();
+ }
+ });
+
+ // proxy all the other methods.
+ // important when wrapping filters and duplexes.
+ for (var i in stream) {
+ if (typeof stream[i] === 'function' &&
+ typeof this[i] === 'undefined') {
+ this[i] = function(method) { return function() {
+ return stream[method].apply(stream, arguments);
+ }}(i);
+ }
+ }
+
+ // proxy certain important events.
+ var events = ['error', 'close', 'destroy', 'pause', 'resume'];
+ forEach(events, function(ev) {
+ stream.on(ev, self.emit.bind(self, ev));
+ });
+
+ // when we try to consume some more bytes, simply unpause the
+ // underlying stream.
+ self._read = function(n) {
+ if (paused) {
+ paused = false;
+ stream.resume();
+ }
+ };
+
+ return self;
+};
+
+
+
+// exposed for testing purposes only.
+Readable._fromList = fromList;
+
+// Pluck off n bytes from an array of buffers.
+// Length is the combined lengths of all the buffers in the list.
+function fromList(n, state) {
+ var list = state.buffer;
+ var length = state.length;
+ var stringMode = !!state.decoder;
+ var objectMode = !!state.objectMode;
+ var ret;
+
+ // nothing in the list, definitely empty.
+ if (list.length === 0)
+ return null;
+
+ if (length === 0)
+ ret = null;
+ else if (objectMode)
+ ret = list.shift();
+ else if (!n || n >= length) {
+ // read it all, truncate the array.
+ if (stringMode)
+ ret = list.join('');
+ else
+ ret = Buffer.concat(list, length);
+ list.length = 0;
+ } else {
+ // read just some of it.
+ if (n < list[0].length) {
+ // just take a part of the first list item.
+ // slice is the same for buffers and strings.
+ var buf = list[0];
+ ret = buf.slice(0, n);
+ list[0] = buf.slice(n);
+ } else if (n === list[0].length) {
+ // first list is a perfect match
+ ret = list.shift();
+ } else {
+ // complex case.
+ // we have enough to cover it, but it spans past the first buffer.
+ if (stringMode)
+ ret = '';
+ else
+ ret = new Buffer(n);
+
+ var c = 0;
+ for (var i = 0, l = list.length; i < l && c < n; i++) {
+ var buf = list[0];
+ var cpy = Math.min(n - c, buf.length);
+
+ if (stringMode)
+ ret += buf.slice(0, cpy);
+ else
+ buf.copy(ret, c, 0, cpy);
+
+ if (cpy < buf.length)
+ list[0] = buf.slice(cpy);
+ else
+ list.shift();
+
+ c += cpy;
+ }
+ }
+ }
+
+ return ret;
+}
+
+function endReadable(stream) {
+ var state = stream._readableState;
+
+ // If we get here before consuming all the bytes, then that is a
+ // bug in node. Should never happen.
+ if (state.length > 0)
+ throw new Error('endReadable called on non-empty stream');
+
+ if (!state.endEmitted && state.calledRead) {
+ state.ended = true;
+ process.nextTick(function() {
+ // Check that we didn't get one last unshift.
+ if (!state.endEmitted && state.length === 0) {
+ state.endEmitted = true;
+ stream.readable = false;
+ stream.emit('end');
+ }
+ });
+ }
+}
+
+function forEach (xs, f) {
+ for (var i = 0, l = xs.length; i < l; i++) {
+ f(xs[i], i);
+ }
+}
+
+function indexOf (xs, x) {
+ for (var i = 0, l = xs.length; i < l; i++) {
+ if (xs[i] === x) return i;
+ }
+ return -1;
+}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/readable-stream/lib/_stream_transform.js nodejs-0.11.15/deps/npm/node_modules/readable-stream/lib/_stream_transform.js
--- nodejs-0.11.14/deps/npm/node_modules/readable-stream/lib/_stream_transform.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/readable-stream/lib/_stream_transform.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,210 @@
+// Copyright Joyent, Inc. and other Node contributors.
+//
+// Permission is hereby granted, free of charge, to any person obtaining a
+// copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to permit
+// persons to whom the Software is furnished to do so, subject to the
+// following conditions:
+//
+// The above copyright notice and this permission notice shall be included
+// in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
+// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
+// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
+// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
+// USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+
+// a transform stream is a readable/writable stream where you do
+// something with the data. Sometimes it's called a "filter",
+// but that's not a great name for it, since that implies a thing where
+// some bits pass through, and others are simply ignored. (That would
+// be a valid example of a transform, of course.)
+//
+// While the output is causally related to the input, it's not a
+// necessarily symmetric or synchronous transformation. For example,
+// a zlib stream might take multiple plain-text writes(), and then
+// emit a single compressed chunk some time in the future.
+//
+// Here's how this works:
+//
+// The Transform stream has all the aspects of the readable and writable
+// stream classes. When you write(chunk), that calls _write(chunk,cb)
+// internally, and returns false if there's a lot of pending writes
+// buffered up. When you call read(), that calls _read(n) until
+// there's enough pending readable data buffered up.
+//
+// In a transform stream, the written data is placed in a buffer. When
+// _read(n) is called, it transforms the queued up data, calling the
+// buffered _write cb's as it consumes chunks. If consuming a single
+// written chunk would result in multiple output chunks, then the first
+// outputted bit calls the readcb, and subsequent chunks just go into
+// the read buffer, and will cause it to emit 'readable' if necessary.
+//
+// This way, back-pressure is actually determined by the reading side,
+// since _read has to be called to start processing a new chunk. However,
+// a pathological inflate type of transform can cause excessive buffering
+// here. For example, imagine a stream where every byte of input is
+// interpreted as an integer from 0-255, and then results in that many
+// bytes of output. Writing the 4 bytes {ff,ff,ff,ff} would result in
+// 1kb of data being output. In this case, you could write a very small
+// amount of input, and end up with a very large amount of output. In
+// such a pathological inflating mechanism, there'd be no way to tell
+// the system to stop doing the transform. A single 4MB write could
+// cause the system to run out of memory.
+//
+// However, even in such a pathological case, only a single written chunk
+// would be consumed, and then the rest would wait (un-transformed) until
+// the results of the previous transformed chunk were consumed.
+
+module.exports = Transform;
+
+var Duplex = require('./_stream_duplex');
+
+/**/
+var util = require('core-util-is');
+util.inherits = require('inherits');
+/* */
+
+util.inherits(Transform, Duplex);
+
+
+function TransformState(options, stream) {
+ this.afterTransform = function(er, data) {
+ return afterTransform(stream, er, data);
+ };
+
+ this.needTransform = false;
+ this.transforming = false;
+ this.writecb = null;
+ this.writechunk = null;
+}
+
+function afterTransform(stream, er, data) {
+ var ts = stream._transformState;
+ ts.transforming = false;
+
+ var cb = ts.writecb;
+
+ if (!cb)
+ return stream.emit('error', new Error('no writecb in Transform class'));
+
+ ts.writechunk = null;
+ ts.writecb = null;
+
+ if (data !== null && data !== undefined)
+ stream.push(data);
+
+ if (cb)
+ cb(er);
+
+ var rs = stream._readableState;
+ rs.reading = false;
+ if (rs.needReadable || rs.length < rs.highWaterMark) {
+ stream._read(rs.highWaterMark);
+ }
+}
+
+
+function Transform(options) {
+ if (!(this instanceof Transform))
+ return new Transform(options);
+
+ Duplex.call(this, options);
+
+ var ts = this._transformState = new TransformState(options, this);
+
+ // when the writable side finishes, then flush out anything remaining.
+ var stream = this;
+
+ // start out asking for a readable event once data is transformed.
+ this._readableState.needReadable = true;
+
+ // we have implemented the _read method, and done the other things
+ // that Readable wants before the first _read call, so unset the
+ // sync guard flag.
+ this._readableState.sync = false;
+
+ this.once('finish', function() {
+ if ('function' === typeof this._flush)
+ this._flush(function(er) {
+ done(stream, er);
+ });
+ else
+ done(stream);
+ });
+}
+
+Transform.prototype.push = function(chunk, encoding) {
+ this._transformState.needTransform = false;
+ return Duplex.prototype.push.call(this, chunk, encoding);
+};
+
+// This is the part where you do stuff!
+// override this function in implementation classes.
+// 'chunk' is an input chunk.
+//
+// Call `push(newChunk)` to pass along transformed output
+// to the readable side. You may call 'push' zero or more times.
+//
+// Call `cb(err)` when you are done with this chunk. If you pass
+// an error, then that'll put the hurt on the whole operation. If you
+// never call cb(), then you'll never get another chunk.
+Transform.prototype._transform = function(chunk, encoding, cb) {
+ throw new Error('not implemented');
+};
+
+Transform.prototype._write = function(chunk, encoding, cb) {
+ var ts = this._transformState;
+ ts.writecb = cb;
+ ts.writechunk = chunk;
+ ts.writeencoding = encoding;
+ if (!ts.transforming) {
+ var rs = this._readableState;
+ if (ts.needTransform ||
+ rs.needReadable ||
+ rs.length < rs.highWaterMark)
+ this._read(rs.highWaterMark);
+ }
+};
+
+// Doesn't matter what the args are here.
+// _transform does all the work.
+// That we got here means that the readable side wants more data.
+Transform.prototype._read = function(n) {
+ var ts = this._transformState;
+
+ if (ts.writechunk !== null && ts.writecb && !ts.transforming) {
+ ts.transforming = true;
+ this._transform(ts.writechunk, ts.writeencoding, ts.afterTransform);
+ } else {
+ // mark that we need a transform, so that any data that comes in
+ // will get processed, now that we've asked for it.
+ ts.needTransform = true;
+ }
+};
+
+
+function done(stream, er) {
+ if (er)
+ return stream.emit('error', er);
+
+ // if there's nothing in the write buffer, then that means
+ // that nothing more will ever be provided
+ var ws = stream._writableState;
+ var rs = stream._readableState;
+ var ts = stream._transformState;
+
+ if (ws.length)
+ throw new Error('calling transform done when ws.length != 0');
+
+ if (ts.transforming)
+ throw new Error('calling transform done when still transforming');
+
+ return stream.push(null);
+}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/readable-stream/lib/_stream_writable.js nodejs-0.11.15/deps/npm/node_modules/readable-stream/lib/_stream_writable.js
--- nodejs-0.11.14/deps/npm/node_modules/readable-stream/lib/_stream_writable.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/readable-stream/lib/_stream_writable.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,386 @@
+// Copyright Joyent, Inc. and other Node contributors.
+//
+// Permission is hereby granted, free of charge, to any person obtaining a
+// copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to permit
+// persons to whom the Software is furnished to do so, subject to the
+// following conditions:
+//
+// The above copyright notice and this permission notice shall be included
+// in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
+// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
+// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
+// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
+// USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+// A bit simpler than readable streams.
+// Implement an async ._write(chunk, cb), and it'll handle all
+// the drain event emission and buffering.
+
+module.exports = Writable;
+
+/**/
+var Buffer = require('buffer').Buffer;
+/* */
+
+Writable.WritableState = WritableState;
+
+
+/**/
+var util = require('core-util-is');
+util.inherits = require('inherits');
+/* */
+
+var Stream = require('stream');
+
+util.inherits(Writable, Stream);
+
+function WriteReq(chunk, encoding, cb) {
+ this.chunk = chunk;
+ this.encoding = encoding;
+ this.callback = cb;
+}
+
+function WritableState(options, stream) {
+ options = options || {};
+
+ // the point at which write() starts returning false
+ // Note: 0 is a valid value, means that we always return false if
+ // the entire buffer is not flushed immediately on write()
+ var hwm = options.highWaterMark;
+ this.highWaterMark = (hwm || hwm === 0) ? hwm : 16 * 1024;
+
+ // object stream flag to indicate whether or not this stream
+ // contains buffers or objects.
+ this.objectMode = !!options.objectMode;
+
+ // cast to ints.
+ this.highWaterMark = ~~this.highWaterMark;
+
+ this.needDrain = false;
+ // at the start of calling end()
+ this.ending = false;
+ // when end() has been called, and returned
+ this.ended = false;
+ // when 'finish' is emitted
+ this.finished = false;
+
+ // should we decode strings into buffers before passing to _write?
+ // this is here so that some node-core streams can optimize string
+ // handling at a lower level.
+ var noDecode = options.decodeStrings === false;
+ this.decodeStrings = !noDecode;
+
+ // Crypto is kind of old and crusty. Historically, its default string
+ // encoding is 'binary' so we have to make this configurable.
+ // Everything else in the universe uses 'utf8', though.
+ this.defaultEncoding = options.defaultEncoding || 'utf8';
+
+ // not an actual buffer we keep track of, but a measurement
+ // of how much we're waiting to get pushed to some underlying
+ // socket or file.
+ this.length = 0;
+
+ // a flag to see when we're in the middle of a write.
+ this.writing = false;
+
+ // a flag to be able to tell if the onwrite cb is called immediately,
+ // or on a later tick. We set this to true at first, becuase any
+ // actions that shouldn't happen until "later" should generally also
+ // not happen before the first write call.
+ this.sync = true;
+
+ // a flag to know if we're processing previously buffered items, which
+ // may call the _write() callback in the same tick, so that we don't
+ // end up in an overlapped onwrite situation.
+ this.bufferProcessing = false;
+
+ // the callback that's passed to _write(chunk,cb)
+ this.onwrite = function(er) {
+ onwrite(stream, er);
+ };
+
+ // the callback that the user supplies to write(chunk,encoding,cb)
+ this.writecb = null;
+
+ // the amount that is being written when _write is called.
+ this.writelen = 0;
+
+ this.buffer = [];
+
+ // True if the error was already emitted and should not be thrown again
+ this.errorEmitted = false;
+}
+
+function Writable(options) {
+ var Duplex = require('./_stream_duplex');
+
+ // Writable ctor is applied to Duplexes, though they're not
+ // instanceof Writable, they're instanceof Readable.
+ if (!(this instanceof Writable) && !(this instanceof Duplex))
+ return new Writable(options);
+
+ this._writableState = new WritableState(options, this);
+
+ // legacy.
+ this.writable = true;
+
+ Stream.call(this);
+}
+
+// Otherwise people can pipe Writable streams, which is just wrong.
+Writable.prototype.pipe = function() {
+ this.emit('error', new Error('Cannot pipe. Not readable.'));
+};
+
+
+function writeAfterEnd(stream, state, cb) {
+ var er = new Error('write after end');
+ // TODO: defer error events consistently everywhere, not just the cb
+ stream.emit('error', er);
+ process.nextTick(function() {
+ cb(er);
+ });
+}
+
+// If we get something that is not a buffer, string, null, or undefined,
+// and we're not in objectMode, then that's an error.
+// Otherwise stream chunks are all considered to be of length=1, and the
+// watermarks determine how many objects to keep in the buffer, rather than
+// how many bytes or characters.
+function validChunk(stream, state, chunk, cb) {
+ var valid = true;
+ if (!Buffer.isBuffer(chunk) &&
+ 'string' !== typeof chunk &&
+ chunk !== null &&
+ chunk !== undefined &&
+ !state.objectMode) {
+ var er = new TypeError('Invalid non-string/buffer chunk');
+ stream.emit('error', er);
+ process.nextTick(function() {
+ cb(er);
+ });
+ valid = false;
+ }
+ return valid;
+}
+
+Writable.prototype.write = function(chunk, encoding, cb) {
+ var state = this._writableState;
+ var ret = false;
+
+ if (typeof encoding === 'function') {
+ cb = encoding;
+ encoding = null;
+ }
+
+ if (Buffer.isBuffer(chunk))
+ encoding = 'buffer';
+ else if (!encoding)
+ encoding = state.defaultEncoding;
+
+ if (typeof cb !== 'function')
+ cb = function() {};
+
+ if (state.ended)
+ writeAfterEnd(this, state, cb);
+ else if (validChunk(this, state, chunk, cb))
+ ret = writeOrBuffer(this, state, chunk, encoding, cb);
+
+ return ret;
+};
+
+function decodeChunk(state, chunk, encoding) {
+ if (!state.objectMode &&
+ state.decodeStrings !== false &&
+ typeof chunk === 'string') {
+ chunk = new Buffer(chunk, encoding);
+ }
+ return chunk;
+}
+
+// if we're already writing something, then just put this
+// in the queue, and wait our turn. Otherwise, call _write
+// If we return false, then we need a drain event, so set that flag.
+function writeOrBuffer(stream, state, chunk, encoding, cb) {
+ chunk = decodeChunk(state, chunk, encoding);
+ if (Buffer.isBuffer(chunk))
+ encoding = 'buffer';
+ var len = state.objectMode ? 1 : chunk.length;
+
+ state.length += len;
+
+ var ret = state.length < state.highWaterMark;
+ // we must ensure that previous needDrain will not be reset to false.
+ if (!ret)
+ state.needDrain = true;
+
+ if (state.writing)
+ state.buffer.push(new WriteReq(chunk, encoding, cb));
+ else
+ doWrite(stream, state, len, chunk, encoding, cb);
+
+ return ret;
+}
+
+function doWrite(stream, state, len, chunk, encoding, cb) {
+ state.writelen = len;
+ state.writecb = cb;
+ state.writing = true;
+ state.sync = true;
+ stream._write(chunk, encoding, state.onwrite);
+ state.sync = false;
+}
+
+function onwriteError(stream, state, sync, er, cb) {
+ if (sync)
+ process.nextTick(function() {
+ cb(er);
+ });
+ else
+ cb(er);
+
+ stream._writableState.errorEmitted = true;
+ stream.emit('error', er);
+}
+
+function onwriteStateUpdate(state) {
+ state.writing = false;
+ state.writecb = null;
+ state.length -= state.writelen;
+ state.writelen = 0;
+}
+
+function onwrite(stream, er) {
+ var state = stream._writableState;
+ var sync = state.sync;
+ var cb = state.writecb;
+
+ onwriteStateUpdate(state);
+
+ if (er)
+ onwriteError(stream, state, sync, er, cb);
+ else {
+ // Check if we're actually ready to finish, but don't emit yet
+ var finished = needFinish(stream, state);
+
+ if (!finished && !state.bufferProcessing && state.buffer.length)
+ clearBuffer(stream, state);
+
+ if (sync) {
+ process.nextTick(function() {
+ afterWrite(stream, state, finished, cb);
+ });
+ } else {
+ afterWrite(stream, state, finished, cb);
+ }
+ }
+}
+
+function afterWrite(stream, state, finished, cb) {
+ if (!finished)
+ onwriteDrain(stream, state);
+ cb();
+ if (finished)
+ finishMaybe(stream, state);
+}
+
+// Must force callback to be called on nextTick, so that we don't
+// emit 'drain' before the write() consumer gets the 'false' return
+// value, and has a chance to attach a 'drain' listener.
+function onwriteDrain(stream, state) {
+ if (state.length === 0 && state.needDrain) {
+ state.needDrain = false;
+ stream.emit('drain');
+ }
+}
+
+
+// if there's something in the buffer waiting, then process it
+function clearBuffer(stream, state) {
+ state.bufferProcessing = true;
+
+ for (var c = 0; c < state.buffer.length; c++) {
+ var entry = state.buffer[c];
+ var chunk = entry.chunk;
+ var encoding = entry.encoding;
+ var cb = entry.callback;
+ var len = state.objectMode ? 1 : chunk.length;
+
+ doWrite(stream, state, len, chunk, encoding, cb);
+
+ // if we didn't call the onwrite immediately, then
+ // it means that we need to wait until it does.
+ // also, that means that the chunk and cb are currently
+ // being processed, so move the buffer counter past them.
+ if (state.writing) {
+ c++;
+ break;
+ }
+ }
+
+ state.bufferProcessing = false;
+ if (c < state.buffer.length)
+ state.buffer = state.buffer.slice(c);
+ else
+ state.buffer.length = 0;
+}
+
+Writable.prototype._write = function(chunk, encoding, cb) {
+ cb(new Error('not implemented'));
+};
+
+Writable.prototype.end = function(chunk, encoding, cb) {
+ var state = this._writableState;
+
+ if (typeof chunk === 'function') {
+ cb = chunk;
+ chunk = null;
+ encoding = null;
+ } else if (typeof encoding === 'function') {
+ cb = encoding;
+ encoding = null;
+ }
+
+ if (typeof chunk !== 'undefined' && chunk !== null)
+ this.write(chunk, encoding);
+
+ // ignore unnecessary end() calls.
+ if (!state.ending && !state.finished)
+ endWritable(this, state, cb);
+};
+
+
+function needFinish(stream, state) {
+ return (state.ending &&
+ state.length === 0 &&
+ !state.finished &&
+ !state.writing);
+}
+
+function finishMaybe(stream, state) {
+ var need = needFinish(stream, state);
+ if (need) {
+ state.finished = true;
+ stream.emit('finish');
+ }
+ return need;
+}
+
+function endWritable(stream, state, cb) {
+ state.ending = true;
+ finishMaybe(stream, state);
+ if (cb) {
+ if (state.finished)
+ process.nextTick(cb);
+ else
+ stream.once('finish', cb);
+ }
+ state.ended = true;
+}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/readable-stream/LICENSE nodejs-0.11.15/deps/npm/node_modules/readable-stream/LICENSE
--- nodejs-0.11.14/deps/npm/node_modules/readable-stream/LICENSE 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/readable-stream/LICENSE 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,27 @@
+Copyright (c) Isaac Z. Schlueter ("Author")
+All rights reserved.
+
+The BSD License
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions
+are met:
+
+1. Redistributions of source code must retain the above copyright
+ notice, this list of conditions and the following disclaimer.
+
+2. Redistributions in binary form must reproduce the above copyright
+ notice, this list of conditions and the following disclaimer in the
+ documentation and/or other materials provided with the distribution.
+
+THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
+ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS
+BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
+BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
+OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
+IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
diff -Nru nodejs-0.11.14/deps/npm/node_modules/readable-stream/node_modules/core-util-is/float.patch nodejs-0.11.15/deps/npm/node_modules/readable-stream/node_modules/core-util-is/float.patch
--- nodejs-0.11.14/deps/npm/node_modules/readable-stream/node_modules/core-util-is/float.patch 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/readable-stream/node_modules/core-util-is/float.patch 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,604 @@
+diff --git a/lib/util.js b/lib/util.js
+index a03e874..9074e8e 100644
+--- a/lib/util.js
++++ b/lib/util.js
+@@ -19,430 +19,6 @@
+ // OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
+ // USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+-var formatRegExp = /%[sdj%]/g;
+-exports.format = function(f) {
+- if (!isString(f)) {
+- var objects = [];
+- for (var i = 0; i < arguments.length; i++) {
+- objects.push(inspect(arguments[i]));
+- }
+- return objects.join(' ');
+- }
+-
+- var i = 1;
+- var args = arguments;
+- var len = args.length;
+- var str = String(f).replace(formatRegExp, function(x) {
+- if (x === '%%') return '%';
+- if (i >= len) return x;
+- switch (x) {
+- case '%s': return String(args[i++]);
+- case '%d': return Number(args[i++]);
+- case '%j':
+- try {
+- return JSON.stringify(args[i++]);
+- } catch (_) {
+- return '[Circular]';
+- }
+- default:
+- return x;
+- }
+- });
+- for (var x = args[i]; i < len; x = args[++i]) {
+- if (isNull(x) || !isObject(x)) {
+- str += ' ' + x;
+- } else {
+- str += ' ' + inspect(x);
+- }
+- }
+- return str;
+-};
+-
+-
+-// Mark that a method should not be used.
+-// Returns a modified function which warns once by default.
+-// If --no-deprecation is set, then it is a no-op.
+-exports.deprecate = function(fn, msg) {
+- // Allow for deprecating things in the process of starting up.
+- if (isUndefined(global.process)) {
+- return function() {
+- return exports.deprecate(fn, msg).apply(this, arguments);
+- };
+- }
+-
+- if (process.noDeprecation === true) {
+- return fn;
+- }
+-
+- var warned = false;
+- function deprecated() {
+- if (!warned) {
+- if (process.throwDeprecation) {
+- throw new Error(msg);
+- } else if (process.traceDeprecation) {
+- console.trace(msg);
+- } else {
+- console.error(msg);
+- }
+- warned = true;
+- }
+- return fn.apply(this, arguments);
+- }
+-
+- return deprecated;
+-};
+-
+-
+-var debugs = {};
+-var debugEnviron;
+-exports.debuglog = function(set) {
+- if (isUndefined(debugEnviron))
+- debugEnviron = process.env.NODE_DEBUG || '';
+- set = set.toUpperCase();
+- if (!debugs[set]) {
+- if (new RegExp('\\b' + set + '\\b', 'i').test(debugEnviron)) {
+- var pid = process.pid;
+- debugs[set] = function() {
+- var msg = exports.format.apply(exports, arguments);
+- console.error('%s %d: %s', set, pid, msg);
+- };
+- } else {
+- debugs[set] = function() {};
+- }
+- }
+- return debugs[set];
+-};
+-
+-
+-/**
+- * Echos the value of a value. Trys to print the value out
+- * in the best way possible given the different types.
+- *
+- * @param {Object} obj The object to print out.
+- * @param {Object} opts Optional options object that alters the output.
+- */
+-/* legacy: obj, showHidden, depth, colors*/
+-function inspect(obj, opts) {
+- // default options
+- var ctx = {
+- seen: [],
+- stylize: stylizeNoColor
+- };
+- // legacy...
+- if (arguments.length >= 3) ctx.depth = arguments[2];
+- if (arguments.length >= 4) ctx.colors = arguments[3];
+- if (isBoolean(opts)) {
+- // legacy...
+- ctx.showHidden = opts;
+- } else if (opts) {
+- // got an "options" object
+- exports._extend(ctx, opts);
+- }
+- // set default options
+- if (isUndefined(ctx.showHidden)) ctx.showHidden = false;
+- if (isUndefined(ctx.depth)) ctx.depth = 2;
+- if (isUndefined(ctx.colors)) ctx.colors = false;
+- if (isUndefined(ctx.customInspect)) ctx.customInspect = true;
+- if (ctx.colors) ctx.stylize = stylizeWithColor;
+- return formatValue(ctx, obj, ctx.depth);
+-}
+-exports.inspect = inspect;
+-
+-
+-// http://en.wikipedia.org/wiki/ANSI_escape_code#graphics
+-inspect.colors = {
+- 'bold' : [1, 22],
+- 'italic' : [3, 23],
+- 'underline' : [4, 24],
+- 'inverse' : [7, 27],
+- 'white' : [37, 39],
+- 'grey' : [90, 39],
+- 'black' : [30, 39],
+- 'blue' : [34, 39],
+- 'cyan' : [36, 39],
+- 'green' : [32, 39],
+- 'magenta' : [35, 39],
+- 'red' : [31, 39],
+- 'yellow' : [33, 39]
+-};
+-
+-// Don't use 'blue' not visible on cmd.exe
+-inspect.styles = {
+- 'special': 'cyan',
+- 'number': 'yellow',
+- 'boolean': 'yellow',
+- 'undefined': 'grey',
+- 'null': 'bold',
+- 'string': 'green',
+- 'date': 'magenta',
+- // "name": intentionally not styling
+- 'regexp': 'red'
+-};
+-
+-
+-function stylizeWithColor(str, styleType) {
+- var style = inspect.styles[styleType];
+-
+- if (style) {
+- return '\u001b[' + inspect.colors[style][0] + 'm' + str +
+- '\u001b[' + inspect.colors[style][1] + 'm';
+- } else {
+- return str;
+- }
+-}
+-
+-
+-function stylizeNoColor(str, styleType) {
+- return str;
+-}
+-
+-
+-function arrayToHash(array) {
+- var hash = {};
+-
+- array.forEach(function(val, idx) {
+- hash[val] = true;
+- });
+-
+- return hash;
+-}
+-
+-
+-function formatValue(ctx, value, recurseTimes) {
+- // Provide a hook for user-specified inspect functions.
+- // Check that value is an object with an inspect function on it
+- if (ctx.customInspect &&
+- value &&
+- isFunction(value.inspect) &&
+- // Filter out the util module, it's inspect function is special
+- value.inspect !== exports.inspect &&
+- // Also filter out any prototype objects using the circular check.
+- !(value.constructor && value.constructor.prototype === value)) {
+- var ret = value.inspect(recurseTimes, ctx);
+- if (!isString(ret)) {
+- ret = formatValue(ctx, ret, recurseTimes);
+- }
+- return ret;
+- }
+-
+- // Primitive types cannot have properties
+- var primitive = formatPrimitive(ctx, value);
+- if (primitive) {
+- return primitive;
+- }
+-
+- // Look up the keys of the object.
+- var keys = Object.keys(value);
+- var visibleKeys = arrayToHash(keys);
+-
+- if (ctx.showHidden) {
+- keys = Object.getOwnPropertyNames(value);
+- }
+-
+- // Some type of object without properties can be shortcutted.
+- if (keys.length === 0) {
+- if (isFunction(value)) {
+- var name = value.name ? ': ' + value.name : '';
+- return ctx.stylize('[Function' + name + ']', 'special');
+- }
+- if (isRegExp(value)) {
+- return ctx.stylize(RegExp.prototype.toString.call(value), 'regexp');
+- }
+- if (isDate(value)) {
+- return ctx.stylize(Date.prototype.toString.call(value), 'date');
+- }
+- if (isError(value)) {
+- return formatError(value);
+- }
+- }
+-
+- var base = '', array = false, braces = ['{', '}'];
+-
+- // Make Array say that they are Array
+- if (isArray(value)) {
+- array = true;
+- braces = ['[', ']'];
+- }
+-
+- // Make functions say that they are functions
+- if (isFunction(value)) {
+- var n = value.name ? ': ' + value.name : '';
+- base = ' [Function' + n + ']';
+- }
+-
+- // Make RegExps say that they are RegExps
+- if (isRegExp(value)) {
+- base = ' ' + RegExp.prototype.toString.call(value);
+- }
+-
+- // Make dates with properties first say the date
+- if (isDate(value)) {
+- base = ' ' + Date.prototype.toUTCString.call(value);
+- }
+-
+- // Make error with message first say the error
+- if (isError(value)) {
+- base = ' ' + formatError(value);
+- }
+-
+- if (keys.length === 0 && (!array || value.length == 0)) {
+- return braces[0] + base + braces[1];
+- }
+-
+- if (recurseTimes < 0) {
+- if (isRegExp(value)) {
+- return ctx.stylize(RegExp.prototype.toString.call(value), 'regexp');
+- } else {
+- return ctx.stylize('[Object]', 'special');
+- }
+- }
+-
+- ctx.seen.push(value);
+-
+- var output;
+- if (array) {
+- output = formatArray(ctx, value, recurseTimes, visibleKeys, keys);
+- } else {
+- output = keys.map(function(key) {
+- return formatProperty(ctx, value, recurseTimes, visibleKeys, key, array);
+- });
+- }
+-
+- ctx.seen.pop();
+-
+- return reduceToSingleString(output, base, braces);
+-}
+-
+-
+-function formatPrimitive(ctx, value) {
+- if (isUndefined(value))
+- return ctx.stylize('undefined', 'undefined');
+- if (isString(value)) {
+- var simple = '\'' + JSON.stringify(value).replace(/^"|"$/g, '')
+- .replace(/'/g, "\\'")
+- .replace(/\\"/g, '"') + '\'';
+- return ctx.stylize(simple, 'string');
+- }
+- if (isNumber(value)) {
+- // Format -0 as '-0'. Strict equality won't distinguish 0 from -0,
+- // so instead we use the fact that 1 / -0 < 0 whereas 1 / 0 > 0 .
+- if (value === 0 && 1 / value < 0)
+- return ctx.stylize('-0', 'number');
+- return ctx.stylize('' + value, 'number');
+- }
+- if (isBoolean(value))
+- return ctx.stylize('' + value, 'boolean');
+- // For some reason typeof null is "object", so special case here.
+- if (isNull(value))
+- return ctx.stylize('null', 'null');
+-}
+-
+-
+-function formatError(value) {
+- return '[' + Error.prototype.toString.call(value) + ']';
+-}
+-
+-
+-function formatArray(ctx, value, recurseTimes, visibleKeys, keys) {
+- var output = [];
+- for (var i = 0, l = value.length; i < l; ++i) {
+- if (hasOwnProperty(value, String(i))) {
+- output.push(formatProperty(ctx, value, recurseTimes, visibleKeys,
+- String(i), true));
+- } else {
+- output.push('');
+- }
+- }
+- keys.forEach(function(key) {
+- if (!key.match(/^\d+$/)) {
+- output.push(formatProperty(ctx, value, recurseTimes, visibleKeys,
+- key, true));
+- }
+- });
+- return output;
+-}
+-
+-
+-function formatProperty(ctx, value, recurseTimes, visibleKeys, key, array) {
+- var name, str, desc;
+- desc = Object.getOwnPropertyDescriptor(value, key) || { value: value[key] };
+- if (desc.get) {
+- if (desc.set) {
+- str = ctx.stylize('[Getter/Setter]', 'special');
+- } else {
+- str = ctx.stylize('[Getter]', 'special');
+- }
+- } else {
+- if (desc.set) {
+- str = ctx.stylize('[Setter]', 'special');
+- }
+- }
+- if (!hasOwnProperty(visibleKeys, key)) {
+- name = '[' + key + ']';
+- }
+- if (!str) {
+- if (ctx.seen.indexOf(desc.value) < 0) {
+- if (isNull(recurseTimes)) {
+- str = formatValue(ctx, desc.value, null);
+- } else {
+- str = formatValue(ctx, desc.value, recurseTimes - 1);
+- }
+- if (str.indexOf('\n') > -1) {
+- if (array) {
+- str = str.split('\n').map(function(line) {
+- return ' ' + line;
+- }).join('\n').substr(2);
+- } else {
+- str = '\n' + str.split('\n').map(function(line) {
+- return ' ' + line;
+- }).join('\n');
+- }
+- }
+- } else {
+- str = ctx.stylize('[Circular]', 'special');
+- }
+- }
+- if (isUndefined(name)) {
+- if (array && key.match(/^\d+$/)) {
+- return str;
+- }
+- name = JSON.stringify('' + key);
+- if (name.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)) {
+- name = name.substr(1, name.length - 2);
+- name = ctx.stylize(name, 'name');
+- } else {
+- name = name.replace(/'/g, "\\'")
+- .replace(/\\"/g, '"')
+- .replace(/(^"|"$)/g, "'");
+- name = ctx.stylize(name, 'string');
+- }
+- }
+-
+- return name + ': ' + str;
+-}
+-
+-
+-function reduceToSingleString(output, base, braces) {
+- var numLinesEst = 0;
+- var length = output.reduce(function(prev, cur) {
+- numLinesEst++;
+- if (cur.indexOf('\n') >= 0) numLinesEst++;
+- return prev + cur.replace(/\u001b\[\d\d?m/g, '').length + 1;
+- }, 0);
+-
+- if (length > 60) {
+- return braces[0] +
+- (base === '' ? '' : base + '\n ') +
+- ' ' +
+- output.join(',\n ') +
+- ' ' +
+- braces[1];
+- }
+-
+- return braces[0] + base + ' ' + output.join(', ') + ' ' + braces[1];
+-}
+-
+-
+ // NOTE: These type checking functions intentionally don't use `instanceof`
+ // because it is fragile and can be easily faked with `Object.create()`.
+ function isArray(ar) {
+@@ -522,166 +98,10 @@ function isPrimitive(arg) {
+ exports.isPrimitive = isPrimitive;
+
+ function isBuffer(arg) {
+- return arg instanceof Buffer;
++ return Buffer.isBuffer(arg);
+ }
+ exports.isBuffer = isBuffer;
+
+ function objectToString(o) {
+ return Object.prototype.toString.call(o);
+-}
+-
+-
+-function pad(n) {
+- return n < 10 ? '0' + n.toString(10) : n.toString(10);
+-}
+-
+-
+-var months = ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep',
+- 'Oct', 'Nov', 'Dec'];
+-
+-// 26 Feb 16:19:34
+-function timestamp() {
+- var d = new Date();
+- var time = [pad(d.getHours()),
+- pad(d.getMinutes()),
+- pad(d.getSeconds())].join(':');
+- return [d.getDate(), months[d.getMonth()], time].join(' ');
+-}
+-
+-
+-// log is just a thin wrapper to console.log that prepends a timestamp
+-exports.log = function() {
+- console.log('%s - %s', timestamp(), exports.format.apply(exports, arguments));
+-};
+-
+-
+-/**
+- * Inherit the prototype methods from one constructor into another.
+- *
+- * The Function.prototype.inherits from lang.js rewritten as a standalone
+- * function (not on Function.prototype). NOTE: If this file is to be loaded
+- * during bootstrapping this function needs to be rewritten using some native
+- * functions as prototype setup using normal JavaScript does not work as
+- * expected during bootstrapping (see mirror.js in r114903).
+- *
+- * @param {function} ctor Constructor function which needs to inherit the
+- * prototype.
+- * @param {function} superCtor Constructor function to inherit prototype from.
+- */
+-exports.inherits = function(ctor, superCtor) {
+- ctor.super_ = superCtor;
+- ctor.prototype = Object.create(superCtor.prototype, {
+- constructor: {
+- value: ctor,
+- enumerable: false,
+- writable: true,
+- configurable: true
+- }
+- });
+-};
+-
+-exports._extend = function(origin, add) {
+- // Don't do anything if add isn't an object
+- if (!add || !isObject(add)) return origin;
+-
+- var keys = Object.keys(add);
+- var i = keys.length;
+- while (i--) {
+- origin[keys[i]] = add[keys[i]];
+- }
+- return origin;
+-};
+-
+-function hasOwnProperty(obj, prop) {
+- return Object.prototype.hasOwnProperty.call(obj, prop);
+-}
+-
+-
+-// Deprecated old stuff.
+-
+-exports.p = exports.deprecate(function() {
+- for (var i = 0, len = arguments.length; i < len; ++i) {
+- console.error(exports.inspect(arguments[i]));
+- }
+-}, 'util.p: Use console.error() instead');
+-
+-
+-exports.exec = exports.deprecate(function() {
+- return require('child_process').exec.apply(this, arguments);
+-}, 'util.exec is now called `child_process.exec`.');
+-
+-
+-exports.print = exports.deprecate(function() {
+- for (var i = 0, len = arguments.length; i < len; ++i) {
+- process.stdout.write(String(arguments[i]));
+- }
+-}, 'util.print: Use console.log instead');
+-
+-
+-exports.puts = exports.deprecate(function() {
+- for (var i = 0, len = arguments.length; i < len; ++i) {
+- process.stdout.write(arguments[i] + '\n');
+- }
+-}, 'util.puts: Use console.log instead');
+-
+-
+-exports.debug = exports.deprecate(function(x) {
+- process.stderr.write('DEBUG: ' + x + '\n');
+-}, 'util.debug: Use console.error instead');
+-
+-
+-exports.error = exports.deprecate(function(x) {
+- for (var i = 0, len = arguments.length; i < len; ++i) {
+- process.stderr.write(arguments[i] + '\n');
+- }
+-}, 'util.error: Use console.error instead');
+-
+-
+-exports.pump = exports.deprecate(function(readStream, writeStream, callback) {
+- var callbackCalled = false;
+-
+- function call(a, b, c) {
+- if (callback && !callbackCalled) {
+- callback(a, b, c);
+- callbackCalled = true;
+- }
+- }
+-
+- readStream.addListener('data', function(chunk) {
+- if (writeStream.write(chunk) === false) readStream.pause();
+- });
+-
+- writeStream.addListener('drain', function() {
+- readStream.resume();
+- });
+-
+- readStream.addListener('end', function() {
+- writeStream.end();
+- });
+-
+- readStream.addListener('close', function() {
+- call();
+- });
+-
+- readStream.addListener('error', function(err) {
+- writeStream.end();
+- call(err);
+- });
+-
+- writeStream.addListener('error', function(err) {
+- readStream.destroy();
+- call(err);
+- });
+-}, 'util.pump(): Use readableStream.pipe() instead');
+-
+-
+-var uv;
+-exports._errnoException = function(err, syscall) {
+- if (isUndefined(uv)) uv = process.binding('uv');
+- var errname = uv.errname(err);
+- var e = new Error(syscall + ' ' + errname);
+- e.code = errname;
+- e.errno = errname;
+- e.syscall = syscall;
+- return e;
+-};
++}
\ No newline at end of file
diff -Nru nodejs-0.11.14/deps/npm/node_modules/readable-stream/node_modules/core-util-is/lib/util.js nodejs-0.11.15/deps/npm/node_modules/readable-stream/node_modules/core-util-is/lib/util.js
--- nodejs-0.11.14/deps/npm/node_modules/readable-stream/node_modules/core-util-is/lib/util.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/readable-stream/node_modules/core-util-is/lib/util.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,107 @@
+// Copyright Joyent, Inc. and other Node contributors.
+//
+// Permission is hereby granted, free of charge, to any person obtaining a
+// copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to permit
+// persons to whom the Software is furnished to do so, subject to the
+// following conditions:
+//
+// The above copyright notice and this permission notice shall be included
+// in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
+// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
+// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
+// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
+// USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+// NOTE: These type checking functions intentionally don't use `instanceof`
+// because it is fragile and can be easily faked with `Object.create()`.
+function isArray(ar) {
+ return Array.isArray(ar);
+}
+exports.isArray = isArray;
+
+function isBoolean(arg) {
+ return typeof arg === 'boolean';
+}
+exports.isBoolean = isBoolean;
+
+function isNull(arg) {
+ return arg === null;
+}
+exports.isNull = isNull;
+
+function isNullOrUndefined(arg) {
+ return arg == null;
+}
+exports.isNullOrUndefined = isNullOrUndefined;
+
+function isNumber(arg) {
+ return typeof arg === 'number';
+}
+exports.isNumber = isNumber;
+
+function isString(arg) {
+ return typeof arg === 'string';
+}
+exports.isString = isString;
+
+function isSymbol(arg) {
+ return typeof arg === 'symbol';
+}
+exports.isSymbol = isSymbol;
+
+function isUndefined(arg) {
+ return arg === void 0;
+}
+exports.isUndefined = isUndefined;
+
+function isRegExp(re) {
+ return isObject(re) && objectToString(re) === '[object RegExp]';
+}
+exports.isRegExp = isRegExp;
+
+function isObject(arg) {
+ return typeof arg === 'object' && arg !== null;
+}
+exports.isObject = isObject;
+
+function isDate(d) {
+ return isObject(d) && objectToString(d) === '[object Date]';
+}
+exports.isDate = isDate;
+
+function isError(e) {
+ return isObject(e) &&
+ (objectToString(e) === '[object Error]' || e instanceof Error);
+}
+exports.isError = isError;
+
+function isFunction(arg) {
+ return typeof arg === 'function';
+}
+exports.isFunction = isFunction;
+
+function isPrimitive(arg) {
+ return arg === null ||
+ typeof arg === 'boolean' ||
+ typeof arg === 'number' ||
+ typeof arg === 'string' ||
+ typeof arg === 'symbol' || // ES6 symbol
+ typeof arg === 'undefined';
+}
+exports.isPrimitive = isPrimitive;
+
+function isBuffer(arg) {
+ return Buffer.isBuffer(arg);
+}
+exports.isBuffer = isBuffer;
+
+function objectToString(o) {
+ return Object.prototype.toString.call(o);
+}
\ No newline at end of file
diff -Nru nodejs-0.11.14/deps/npm/node_modules/readable-stream/node_modules/core-util-is/package.json nodejs-0.11.15/deps/npm/node_modules/readable-stream/node_modules/core-util-is/package.json
--- nodejs-0.11.14/deps/npm/node_modules/readable-stream/node_modules/core-util-is/package.json 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/readable-stream/node_modules/core-util-is/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,54 @@
+{
+ "name": "core-util-is",
+ "version": "1.0.1",
+ "description": "The `util.is*` functions introduced in Node v0.12.",
+ "main": "lib/util.js",
+ "repository": {
+ "type": "git",
+ "url": "git://github.com/isaacs/core-util-is"
+ },
+ "keywords": [
+ "util",
+ "isBuffer",
+ "isArray",
+ "isNumber",
+ "isString",
+ "isRegExp",
+ "isThis",
+ "isThat",
+ "polyfill"
+ ],
+ "author": {
+ "name": "Isaac Z. Schlueter",
+ "email": "i@izs.me",
+ "url": "http://blog.izs.me/"
+ },
+ "license": "MIT",
+ "bugs": {
+ "url": "https://github.com/isaacs/core-util-is/issues"
+ },
+ "readme": "# core-util-is\n\nThe `util.is*` functions introduced in Node v0.12.\n",
+ "readmeFilename": "README.md",
+ "homepage": "https://github.com/isaacs/core-util-is",
+ "_id": "core-util-is@1.0.1",
+ "dist": {
+ "shasum": "6b07085aef9a3ccac6ee53bf9d3df0c1521a5538",
+ "tarball": "http://registry.npmjs.org/core-util-is/-/core-util-is-1.0.1.tgz"
+ },
+ "_from": "core-util-is@>=1.0.0 <1.1.0",
+ "_npmVersion": "1.3.23",
+ "_npmUser": {
+ "name": "isaacs",
+ "email": "i@izs.me"
+ },
+ "maintainers": [
+ {
+ "name": "isaacs",
+ "email": "i@izs.me"
+ }
+ ],
+ "directories": {},
+ "_shasum": "6b07085aef9a3ccac6ee53bf9d3df0c1521a5538",
+ "_resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.1.tgz",
+ "scripts": {}
+}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/readable-stream/node_modules/core-util-is/README.md nodejs-0.11.15/deps/npm/node_modules/readable-stream/node_modules/core-util-is/README.md
--- nodejs-0.11.14/deps/npm/node_modules/readable-stream/node_modules/core-util-is/README.md 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/readable-stream/node_modules/core-util-is/README.md 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,3 @@
+# core-util-is
+
+The `util.is*` functions introduced in Node v0.12.
diff -Nru nodejs-0.11.14/deps/npm/node_modules/readable-stream/node_modules/core-util-is/util.js nodejs-0.11.15/deps/npm/node_modules/readable-stream/node_modules/core-util-is/util.js
--- nodejs-0.11.14/deps/npm/node_modules/readable-stream/node_modules/core-util-is/util.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/readable-stream/node_modules/core-util-is/util.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,106 @@
+// Copyright Joyent, Inc. and other Node contributors.
+//
+// Permission is hereby granted, free of charge, to any person obtaining a
+// copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to permit
+// persons to whom the Software is furnished to do so, subject to the
+// following conditions:
+//
+// The above copyright notice and this permission notice shall be included
+// in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
+// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
+// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
+// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
+// USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+// NOTE: These type checking functions intentionally don't use `instanceof`
+// because it is fragile and can be easily faked with `Object.create()`.
+function isArray(ar) {
+ return Array.isArray(ar);
+}
+exports.isArray = isArray;
+
+function isBoolean(arg) {
+ return typeof arg === 'boolean';
+}
+exports.isBoolean = isBoolean;
+
+function isNull(arg) {
+ return arg === null;
+}
+exports.isNull = isNull;
+
+function isNullOrUndefined(arg) {
+ return arg == null;
+}
+exports.isNullOrUndefined = isNullOrUndefined;
+
+function isNumber(arg) {
+ return typeof arg === 'number';
+}
+exports.isNumber = isNumber;
+
+function isString(arg) {
+ return typeof arg === 'string';
+}
+exports.isString = isString;
+
+function isSymbol(arg) {
+ return typeof arg === 'symbol';
+}
+exports.isSymbol = isSymbol;
+
+function isUndefined(arg) {
+ return arg === void 0;
+}
+exports.isUndefined = isUndefined;
+
+function isRegExp(re) {
+ return isObject(re) && objectToString(re) === '[object RegExp]';
+}
+exports.isRegExp = isRegExp;
+
+function isObject(arg) {
+ return typeof arg === 'object' && arg !== null;
+}
+exports.isObject = isObject;
+
+function isDate(d) {
+ return isObject(d) && objectToString(d) === '[object Date]';
+}
+exports.isDate = isDate;
+
+function isError(e) {
+ return isObject(e) && objectToString(e) === '[object Error]';
+}
+exports.isError = isError;
+
+function isFunction(arg) {
+ return typeof arg === 'function';
+}
+exports.isFunction = isFunction;
+
+function isPrimitive(arg) {
+ return arg === null ||
+ typeof arg === 'boolean' ||
+ typeof arg === 'number' ||
+ typeof arg === 'string' ||
+ typeof arg === 'symbol' || // ES6 symbol
+ typeof arg === 'undefined';
+}
+exports.isPrimitive = isPrimitive;
+
+function isBuffer(arg) {
+ return arg instanceof Buffer;
+}
+exports.isBuffer = isBuffer;
+
+function objectToString(o) {
+ return Object.prototype.toString.call(o);
+}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/readable-stream/node_modules/isarray/build/build.js nodejs-0.11.15/deps/npm/node_modules/readable-stream/node_modules/isarray/build/build.js
--- nodejs-0.11.14/deps/npm/node_modules/readable-stream/node_modules/isarray/build/build.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/readable-stream/node_modules/isarray/build/build.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,209 @@
+
+/**
+ * Require the given path.
+ *
+ * @param {String} path
+ * @return {Object} exports
+ * @api public
+ */
+
+function require(path, parent, orig) {
+ var resolved = require.resolve(path);
+
+ // lookup failed
+ if (null == resolved) {
+ orig = orig || path;
+ parent = parent || 'root';
+ var err = new Error('Failed to require "' + orig + '" from "' + parent + '"');
+ err.path = orig;
+ err.parent = parent;
+ err.require = true;
+ throw err;
+ }
+
+ var module = require.modules[resolved];
+
+ // perform real require()
+ // by invoking the module's
+ // registered function
+ if (!module.exports) {
+ module.exports = {};
+ module.client = module.component = true;
+ module.call(this, module.exports, require.relative(resolved), module);
+ }
+
+ return module.exports;
+}
+
+/**
+ * Registered modules.
+ */
+
+require.modules = {};
+
+/**
+ * Registered aliases.
+ */
+
+require.aliases = {};
+
+/**
+ * Resolve `path`.
+ *
+ * Lookup:
+ *
+ * - PATH/index.js
+ * - PATH.js
+ * - PATH
+ *
+ * @param {String} path
+ * @return {String} path or null
+ * @api private
+ */
+
+require.resolve = function(path) {
+ if (path.charAt(0) === '/') path = path.slice(1);
+ var index = path + '/index.js';
+
+ var paths = [
+ path,
+ path + '.js',
+ path + '.json',
+ path + '/index.js',
+ path + '/index.json'
+ ];
+
+ for (var i = 0; i < paths.length; i++) {
+ var path = paths[i];
+ if (require.modules.hasOwnProperty(path)) return path;
+ }
+
+ if (require.aliases.hasOwnProperty(index)) {
+ return require.aliases[index];
+ }
+};
+
+/**
+ * Normalize `path` relative to the current path.
+ *
+ * @param {String} curr
+ * @param {String} path
+ * @return {String}
+ * @api private
+ */
+
+require.normalize = function(curr, path) {
+ var segs = [];
+
+ if ('.' != path.charAt(0)) return path;
+
+ curr = curr.split('/');
+ path = path.split('/');
+
+ for (var i = 0; i < path.length; ++i) {
+ if ('..' == path[i]) {
+ curr.pop();
+ } else if ('.' != path[i] && '' != path[i]) {
+ segs.push(path[i]);
+ }
+ }
+
+ return curr.concat(segs).join('/');
+};
+
+/**
+ * Register module at `path` with callback `definition`.
+ *
+ * @param {String} path
+ * @param {Function} definition
+ * @api private
+ */
+
+require.register = function(path, definition) {
+ require.modules[path] = definition;
+};
+
+/**
+ * Alias a module definition.
+ *
+ * @param {String} from
+ * @param {String} to
+ * @api private
+ */
+
+require.alias = function(from, to) {
+ if (!require.modules.hasOwnProperty(from)) {
+ throw new Error('Failed to alias "' + from + '", it does not exist');
+ }
+ require.aliases[to] = from;
+};
+
+/**
+ * Return a require function relative to the `parent` path.
+ *
+ * @param {String} parent
+ * @return {Function}
+ * @api private
+ */
+
+require.relative = function(parent) {
+ var p = require.normalize(parent, '..');
+
+ /**
+ * lastIndexOf helper.
+ */
+
+ function lastIndexOf(arr, obj) {
+ var i = arr.length;
+ while (i--) {
+ if (arr[i] === obj) return i;
+ }
+ return -1;
+ }
+
+ /**
+ * The relative require() itself.
+ */
+
+ function localRequire(path) {
+ var resolved = localRequire.resolve(path);
+ return require(resolved, parent, path);
+ }
+
+ /**
+ * Resolve relative to the parent.
+ */
+
+ localRequire.resolve = function(path) {
+ var c = path.charAt(0);
+ if ('/' == c) return path.slice(1);
+ if ('.' == c) return require.normalize(p, path);
+
+ // resolve deps by returning
+ // the dep in the nearest "deps"
+ // directory
+ var segs = parent.split('/');
+ var i = lastIndexOf(segs, 'deps') + 1;
+ if (!i) i = 0;
+ path = segs.slice(0, i + 1).join('/') + '/deps/' + path;
+ return path;
+ };
+
+ /**
+ * Check if module is defined at `path`.
+ */
+
+ localRequire.exists = function(path) {
+ return require.modules.hasOwnProperty(localRequire.resolve(path));
+ };
+
+ return localRequire;
+};
+require.register("isarray/index.js", function(exports, require, module){
+module.exports = Array.isArray || function (arr) {
+ return Object.prototype.toString.call(arr) == '[object Array]';
+};
+
+});
+require.alias("isarray/index.js", "isarray/index.js");
+
diff -Nru nodejs-0.11.14/deps/npm/node_modules/readable-stream/node_modules/isarray/component.json nodejs-0.11.15/deps/npm/node_modules/readable-stream/node_modules/isarray/component.json
--- nodejs-0.11.14/deps/npm/node_modules/readable-stream/node_modules/isarray/component.json 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/readable-stream/node_modules/isarray/component.json 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,19 @@
+{
+ "name" : "isarray",
+ "description" : "Array#isArray for older browsers",
+ "version" : "0.0.1",
+ "repository" : "juliangruber/isarray",
+ "homepage": "https://github.com/juliangruber/isarray",
+ "main" : "index.js",
+ "scripts" : [
+ "index.js"
+ ],
+ "dependencies" : {},
+ "keywords": ["browser","isarray","array"],
+ "author": {
+ "name": "Julian Gruber",
+ "email": "mail@juliangruber.com",
+ "url": "http://juliangruber.com"
+ },
+ "license": "MIT"
+}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/readable-stream/node_modules/isarray/index.js nodejs-0.11.15/deps/npm/node_modules/readable-stream/node_modules/isarray/index.js
--- nodejs-0.11.14/deps/npm/node_modules/readable-stream/node_modules/isarray/index.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/readable-stream/node_modules/isarray/index.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,3 @@
+module.exports = Array.isArray || function (arr) {
+ return Object.prototype.toString.call(arr) == '[object Array]';
+};
diff -Nru nodejs-0.11.14/deps/npm/node_modules/readable-stream/node_modules/isarray/package.json nodejs-0.11.15/deps/npm/node_modules/readable-stream/node_modules/isarray/package.json
--- nodejs-0.11.14/deps/npm/node_modules/readable-stream/node_modules/isarray/package.json 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/readable-stream/node_modules/isarray/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,54 @@
+{
+ "name": "isarray",
+ "description": "Array#isArray for older browsers",
+ "version": "0.0.1",
+ "repository": {
+ "type": "git",
+ "url": "git://github.com/juliangruber/isarray.git"
+ },
+ "homepage": "https://github.com/juliangruber/isarray",
+ "main": "index.js",
+ "scripts": {
+ "test": "tap test/*.js"
+ },
+ "dependencies": {},
+ "devDependencies": {
+ "tap": "*"
+ },
+ "keywords": [
+ "browser",
+ "isarray",
+ "array"
+ ],
+ "author": {
+ "name": "Julian Gruber",
+ "email": "mail@juliangruber.com",
+ "url": "http://juliangruber.com"
+ },
+ "license": "MIT",
+ "readme": "\n# isarray\n\n`Array#isArray` for older browsers.\n\n## Usage\n\n```js\nvar isArray = require('isarray');\n\nconsole.log(isArray([])); // => true\nconsole.log(isArray({})); // => false\n```\n\n## Installation\n\nWith [npm](http://npmjs.org) do\n\n```bash\n$ npm install isarray\n```\n\nThen bundle for the browser with\n[browserify](https://github.com/substack/browserify).\n\nWith [component](http://component.io) do\n\n```bash\n$ component install juliangruber/isarray\n```\n\n## License\n\n(MIT)\n\nCopyright (c) 2013 Julian Gruber <julian@juliangruber.com>\n\nPermission is hereby granted, free of charge, to any person obtaining a copy of\nthis software and associated documentation files (the \"Software\"), to deal in\nthe Software without restriction, including without limitation the rights to\nuse, copy, modify, merge, publish, distribute, sublicense, and/or sell copies\nof the Software, and to permit persons to whom the Software is furnished to do\nso, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.\n",
+ "readmeFilename": "README.md",
+ "_id": "isarray@0.0.1",
+ "dist": {
+ "shasum": "8a18acfca9a8f4177e09abfc6038939b05d1eedf",
+ "tarball": "http://registry.npmjs.org/isarray/-/isarray-0.0.1.tgz"
+ },
+ "_from": "isarray@0.0.1",
+ "_npmVersion": "1.2.18",
+ "_npmUser": {
+ "name": "juliangruber",
+ "email": "julian@juliangruber.com"
+ },
+ "maintainers": [
+ {
+ "name": "juliangruber",
+ "email": "julian@juliangruber.com"
+ }
+ ],
+ "directories": {},
+ "_shasum": "8a18acfca9a8f4177e09abfc6038939b05d1eedf",
+ "_resolved": "https://registry.npmjs.org/isarray/-/isarray-0.0.1.tgz",
+ "bugs": {
+ "url": "https://github.com/juliangruber/isarray/issues"
+ }
+}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/readable-stream/node_modules/isarray/README.md nodejs-0.11.15/deps/npm/node_modules/readable-stream/node_modules/isarray/README.md
--- nodejs-0.11.14/deps/npm/node_modules/readable-stream/node_modules/isarray/README.md 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/readable-stream/node_modules/isarray/README.md 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,54 @@
+
+# isarray
+
+`Array#isArray` for older browsers.
+
+## Usage
+
+```js
+var isArray = require('isarray');
+
+console.log(isArray([])); // => true
+console.log(isArray({})); // => false
+```
+
+## Installation
+
+With [npm](http://npmjs.org) do
+
+```bash
+$ npm install isarray
+```
+
+Then bundle for the browser with
+[browserify](https://github.com/substack/browserify).
+
+With [component](http://component.io) do
+
+```bash
+$ component install juliangruber/isarray
+```
+
+## License
+
+(MIT)
+
+Copyright (c) 2013 Julian Gruber <julian@juliangruber.com>
+
+Permission is hereby granted, free of charge, to any person obtaining a copy of
+this software and associated documentation files (the "Software"), to deal in
+the Software without restriction, including without limitation the rights to
+use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
+of the Software, and to permit persons to whom the Software is furnished to do
+so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+SOFTWARE.
diff -Nru nodejs-0.11.14/deps/npm/node_modules/readable-stream/node_modules/string_decoder/index.js nodejs-0.11.15/deps/npm/node_modules/readable-stream/node_modules/string_decoder/index.js
--- nodejs-0.11.14/deps/npm/node_modules/readable-stream/node_modules/string_decoder/index.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/readable-stream/node_modules/string_decoder/index.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,221 @@
+// Copyright Joyent, Inc. and other Node contributors.
+//
+// Permission is hereby granted, free of charge, to any person obtaining a
+// copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to permit
+// persons to whom the Software is furnished to do so, subject to the
+// following conditions:
+//
+// The above copyright notice and this permission notice shall be included
+// in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
+// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
+// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
+// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
+// USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+var Buffer = require('buffer').Buffer;
+
+var isBufferEncoding = Buffer.isEncoding
+ || function(encoding) {
+ switch (encoding && encoding.toLowerCase()) {
+ case 'hex': case 'utf8': case 'utf-8': case 'ascii': case 'binary': case 'base64': case 'ucs2': case 'ucs-2': case 'utf16le': case 'utf-16le': case 'raw': return true;
+ default: return false;
+ }
+ }
+
+
+function assertEncoding(encoding) {
+ if (encoding && !isBufferEncoding(encoding)) {
+ throw new Error('Unknown encoding: ' + encoding);
+ }
+}
+
+// StringDecoder provides an interface for efficiently splitting a series of
+// buffers into a series of JS strings without breaking apart multi-byte
+// characters. CESU-8 is handled as part of the UTF-8 encoding.
+//
+// @TODO Handling all encodings inside a single object makes it very difficult
+// to reason about this code, so it should be split up in the future.
+// @TODO There should be a utf8-strict encoding that rejects invalid UTF-8 code
+// points as used by CESU-8.
+var StringDecoder = exports.StringDecoder = function(encoding) {
+ this.encoding = (encoding || 'utf8').toLowerCase().replace(/[-_]/, '');
+ assertEncoding(encoding);
+ switch (this.encoding) {
+ case 'utf8':
+ // CESU-8 represents each of Surrogate Pair by 3-bytes
+ this.surrogateSize = 3;
+ break;
+ case 'ucs2':
+ case 'utf16le':
+ // UTF-16 represents each of Surrogate Pair by 2-bytes
+ this.surrogateSize = 2;
+ this.detectIncompleteChar = utf16DetectIncompleteChar;
+ break;
+ case 'base64':
+ // Base-64 stores 3 bytes in 4 chars, and pads the remainder.
+ this.surrogateSize = 3;
+ this.detectIncompleteChar = base64DetectIncompleteChar;
+ break;
+ default:
+ this.write = passThroughWrite;
+ return;
+ }
+
+ // Enough space to store all bytes of a single character. UTF-8 needs 4
+ // bytes, but CESU-8 may require up to 6 (3 bytes per surrogate).
+ this.charBuffer = new Buffer(6);
+ // Number of bytes received for the current incomplete multi-byte character.
+ this.charReceived = 0;
+ // Number of bytes expected for the current incomplete multi-byte character.
+ this.charLength = 0;
+};
+
+
+// write decodes the given buffer and returns it as JS string that is
+// guaranteed to not contain any partial multi-byte characters. Any partial
+// character found at the end of the buffer is buffered up, and will be
+// returned when calling write again with the remaining bytes.
+//
+// Note: Converting a Buffer containing an orphan surrogate to a String
+// currently works, but converting a String to a Buffer (via `new Buffer`, or
+// Buffer#write) will replace incomplete surrogates with the unicode
+// replacement character. See https://codereview.chromium.org/121173009/ .
+StringDecoder.prototype.write = function(buffer) {
+ var charStr = '';
+ // if our last write ended with an incomplete multibyte character
+ while (this.charLength) {
+ // determine how many remaining bytes this buffer has to offer for this char
+ var available = (buffer.length >= this.charLength - this.charReceived) ?
+ this.charLength - this.charReceived :
+ buffer.length;
+
+ // add the new bytes to the char buffer
+ buffer.copy(this.charBuffer, this.charReceived, 0, available);
+ this.charReceived += available;
+
+ if (this.charReceived < this.charLength) {
+ // still not enough chars in this buffer? wait for more ...
+ return '';
+ }
+
+ // remove bytes belonging to the current character from the buffer
+ buffer = buffer.slice(available, buffer.length);
+
+ // get the character that was split
+ charStr = this.charBuffer.slice(0, this.charLength).toString(this.encoding);
+
+ // CESU-8: lead surrogate (D800-DBFF) is also the incomplete character
+ var charCode = charStr.charCodeAt(charStr.length - 1);
+ if (charCode >= 0xD800 && charCode <= 0xDBFF) {
+ this.charLength += this.surrogateSize;
+ charStr = '';
+ continue;
+ }
+ this.charReceived = this.charLength = 0;
+
+ // if there are no more bytes in this buffer, just emit our char
+ if (buffer.length === 0) {
+ return charStr;
+ }
+ break;
+ }
+
+ // determine and set charLength / charReceived
+ this.detectIncompleteChar(buffer);
+
+ var end = buffer.length;
+ if (this.charLength) {
+ // buffer the incomplete character bytes we got
+ buffer.copy(this.charBuffer, 0, buffer.length - this.charReceived, end);
+ end -= this.charReceived;
+ }
+
+ charStr += buffer.toString(this.encoding, 0, end);
+
+ var end = charStr.length - 1;
+ var charCode = charStr.charCodeAt(end);
+ // CESU-8: lead surrogate (D800-DBFF) is also the incomplete character
+ if (charCode >= 0xD800 && charCode <= 0xDBFF) {
+ var size = this.surrogateSize;
+ this.charLength += size;
+ this.charReceived += size;
+ this.charBuffer.copy(this.charBuffer, size, 0, size);
+ buffer.copy(this.charBuffer, 0, 0, size);
+ return charStr.substring(0, end);
+ }
+
+ // or just emit the charStr
+ return charStr;
+};
+
+// detectIncompleteChar determines if there is an incomplete UTF-8 character at
+// the end of the given buffer. If so, it sets this.charLength to the byte
+// length that character, and sets this.charReceived to the number of bytes
+// that are available for this character.
+StringDecoder.prototype.detectIncompleteChar = function(buffer) {
+ // determine how many bytes we have to check at the end of this buffer
+ var i = (buffer.length >= 3) ? 3 : buffer.length;
+
+ // Figure out if one of the last i bytes of our buffer announces an
+ // incomplete char.
+ for (; i > 0; i--) {
+ var c = buffer[buffer.length - i];
+
+ // See http://en.wikipedia.org/wiki/UTF-8#Description
+
+ // 110XXXXX
+ if (i == 1 && c >> 5 == 0x06) {
+ this.charLength = 2;
+ break;
+ }
+
+ // 1110XXXX
+ if (i <= 2 && c >> 4 == 0x0E) {
+ this.charLength = 3;
+ break;
+ }
+
+ // 11110XXX
+ if (i <= 3 && c >> 3 == 0x1E) {
+ this.charLength = 4;
+ break;
+ }
+ }
+ this.charReceived = i;
+};
+
+StringDecoder.prototype.end = function(buffer) {
+ var res = '';
+ if (buffer && buffer.length)
+ res = this.write(buffer);
+
+ if (this.charReceived) {
+ var cr = this.charReceived;
+ var buf = this.charBuffer;
+ var enc = this.encoding;
+ res += buf.slice(0, cr).toString(enc);
+ }
+
+ return res;
+};
+
+function passThroughWrite(buffer) {
+ return buffer.toString(this.encoding);
+}
+
+function utf16DetectIncompleteChar(buffer) {
+ this.charReceived = buffer.length % 2;
+ this.charLength = this.charReceived ? 2 : 0;
+}
+
+function base64DetectIncompleteChar(buffer) {
+ this.charReceived = buffer.length % 3;
+ this.charLength = this.charReceived ? 3 : 0;
+}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/readable-stream/node_modules/string_decoder/LICENSE nodejs-0.11.15/deps/npm/node_modules/readable-stream/node_modules/string_decoder/LICENSE
--- nodejs-0.11.14/deps/npm/node_modules/readable-stream/node_modules/string_decoder/LICENSE 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/readable-stream/node_modules/string_decoder/LICENSE 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,20 @@
+Copyright Joyent, Inc. and other Node contributors.
+
+Permission is hereby granted, free of charge, to any person obtaining a
+copy of this software and associated documentation files (the
+"Software"), to deal in the Software without restriction, including
+without limitation the rights to use, copy, modify, merge, publish,
+distribute, sublicense, and/or sell copies of the Software, and to permit
+persons to whom the Software is furnished to do so, subject to the
+following conditions:
+
+The above copyright notice and this permission notice shall be included
+in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
+NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
+DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
+OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
+USE OR OTHER DEALINGS IN THE SOFTWARE.
diff -Nru nodejs-0.11.14/deps/npm/node_modules/readable-stream/node_modules/string_decoder/.npmignore nodejs-0.11.15/deps/npm/node_modules/readable-stream/node_modules/string_decoder/.npmignore
--- nodejs-0.11.14/deps/npm/node_modules/readable-stream/node_modules/string_decoder/.npmignore 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/readable-stream/node_modules/string_decoder/.npmignore 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,2 @@
+build
+test
diff -Nru nodejs-0.11.14/deps/npm/node_modules/readable-stream/node_modules/string_decoder/package.json nodejs-0.11.15/deps/npm/node_modules/readable-stream/node_modules/string_decoder/package.json
--- nodejs-0.11.14/deps/npm/node_modules/readable-stream/node_modules/string_decoder/package.json 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/readable-stream/node_modules/string_decoder/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,54 @@
+{
+ "name": "string_decoder",
+ "version": "0.10.31",
+ "description": "The string_decoder module from Node core",
+ "main": "index.js",
+ "dependencies": {},
+ "devDependencies": {
+ "tap": "~0.4.8"
+ },
+ "scripts": {
+ "test": "tap test/simple/*.js"
+ },
+ "repository": {
+ "type": "git",
+ "url": "git://github.com/rvagg/string_decoder.git"
+ },
+ "homepage": "https://github.com/rvagg/string_decoder",
+ "keywords": [
+ "string",
+ "decoder",
+ "browser",
+ "browserify"
+ ],
+ "license": "MIT",
+ "gitHead": "d46d4fd87cf1d06e031c23f1ba170ca7d4ade9a0",
+ "bugs": {
+ "url": "https://github.com/rvagg/string_decoder/issues"
+ },
+ "_id": "string_decoder@0.10.31",
+ "_shasum": "62e203bc41766c6c28c9fc84301dab1c5310fa94",
+ "_from": "string_decoder@>=0.10.0 <0.11.0",
+ "_npmVersion": "1.4.23",
+ "_npmUser": {
+ "name": "rvagg",
+ "email": "rod@vagg.org"
+ },
+ "maintainers": [
+ {
+ "name": "substack",
+ "email": "mail@substack.net"
+ },
+ {
+ "name": "rvagg",
+ "email": "rod@vagg.org"
+ }
+ ],
+ "dist": {
+ "shasum": "62e203bc41766c6c28c9fc84301dab1c5310fa94",
+ "tarball": "http://registry.npmjs.org/string_decoder/-/string_decoder-0.10.31.tgz"
+ },
+ "directories": {},
+ "_resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-0.10.31.tgz",
+ "readme": "ERROR: No README data found!"
+}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/readable-stream/node_modules/string_decoder/README.md nodejs-0.11.15/deps/npm/node_modules/readable-stream/node_modules/string_decoder/README.md
--- nodejs-0.11.14/deps/npm/node_modules/readable-stream/node_modules/string_decoder/README.md 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/readable-stream/node_modules/string_decoder/README.md 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,7 @@
+**string_decoder.js** (`require('string_decoder')`) from Node.js core
+
+Copyright Joyent, Inc. and other Node contributors. See LICENCE file for details.
+
+Version numbers match the versions found in Node core, e.g. 0.10.24 matches Node 0.10.24, likewise 0.11.10 matches Node 0.11.10. **Prefer the stable version over the unstable.**
+
+The *build/* directory contains a build script that will scrape the source from the [joyent/node](https://github.com/joyent/node) repo given a specific Node version.
\ No newline at end of file
diff -Nru nodejs-0.11.14/deps/npm/node_modules/readable-stream/.npmignore nodejs-0.11.15/deps/npm/node_modules/readable-stream/.npmignore
--- nodejs-0.11.14/deps/npm/node_modules/readable-stream/.npmignore 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/readable-stream/.npmignore 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,5 @@
+build/
+test/
+examples/
+fs.js
+zlib.js
\ No newline at end of file
diff -Nru nodejs-0.11.14/deps/npm/node_modules/readable-stream/package.json nodejs-0.11.15/deps/npm/node_modules/readable-stream/package.json
--- nodejs-0.11.14/deps/npm/node_modules/readable-stream/package.json 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/readable-stream/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,71 @@
+{
+ "name": "readable-stream",
+ "version": "1.0.32",
+ "description": "Streams2, a user-land copy of the stream library from Node.js v0.10.x",
+ "main": "readable.js",
+ "dependencies": {
+ "core-util-is": "~1.0.0",
+ "isarray": "0.0.1",
+ "string_decoder": "~0.10.x",
+ "inherits": "~2.0.1"
+ },
+ "devDependencies": {
+ "tap": "~0.2.6"
+ },
+ "scripts": {
+ "test": "tap test/simple/*.js"
+ },
+ "repository": {
+ "type": "git",
+ "url": "git://github.com/isaacs/readable-stream"
+ },
+ "keywords": [
+ "readable",
+ "stream",
+ "pipe"
+ ],
+ "browser": {
+ "util": false
+ },
+ "author": {
+ "name": "Isaac Z. Schlueter",
+ "email": "i@izs.me",
+ "url": "http://blog.izs.me/"
+ },
+ "license": "MIT",
+ "gitHead": "2024ad52b1e475465488b4ad39eb41d067ffcbb9",
+ "bugs": {
+ "url": "https://github.com/isaacs/readable-stream/issues"
+ },
+ "homepage": "https://github.com/isaacs/readable-stream",
+ "_id": "readable-stream@1.0.32",
+ "_shasum": "6b44a88ba984cd0ec0834ae7d59a47c39aef48ec",
+ "_from": "readable-stream@*",
+ "_npmVersion": "2.0.2",
+ "_nodeVersion": "0.10.31",
+ "_npmUser": {
+ "name": "rvagg",
+ "email": "rod@vagg.org"
+ },
+ "maintainers": [
+ {
+ "name": "isaacs",
+ "email": "i@izs.me"
+ },
+ {
+ "name": "tootallnate",
+ "email": "nathan@tootallnate.net"
+ },
+ {
+ "name": "rvagg",
+ "email": "rod@vagg.org"
+ }
+ ],
+ "dist": {
+ "shasum": "6b44a88ba984cd0ec0834ae7d59a47c39aef48ec",
+ "tarball": "http://registry.npmjs.org/readable-stream/-/readable-stream-1.0.32.tgz"
+ },
+ "directories": {},
+ "_resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-1.0.32.tgz",
+ "readme": "ERROR: No README data found!"
+}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/readable-stream/passthrough.js nodejs-0.11.15/deps/npm/node_modules/readable-stream/passthrough.js
--- nodejs-0.11.14/deps/npm/node_modules/readable-stream/passthrough.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/readable-stream/passthrough.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1 @@
+module.exports = require("./lib/_stream_passthrough.js")
diff -Nru nodejs-0.11.14/deps/npm/node_modules/readable-stream/readable.js nodejs-0.11.15/deps/npm/node_modules/readable-stream/readable.js
--- nodejs-0.11.14/deps/npm/node_modules/readable-stream/readable.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/readable-stream/readable.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,6 @@
+exports = module.exports = require('./lib/_stream_readable.js');
+exports.Readable = exports;
+exports.Writable = require('./lib/_stream_writable.js');
+exports.Duplex = require('./lib/_stream_duplex.js');
+exports.Transform = require('./lib/_stream_transform.js');
+exports.PassThrough = require('./lib/_stream_passthrough.js');
diff -Nru nodejs-0.11.14/deps/npm/node_modules/readable-stream/README.md nodejs-0.11.15/deps/npm/node_modules/readable-stream/README.md
--- nodejs-0.11.14/deps/npm/node_modules/readable-stream/README.md 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/readable-stream/README.md 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,15 @@
+# readable-stream
+
+***Node-core streams for userland***
+
+[![NPM](https://nodei.co/npm/readable-stream.png?downloads=true)](https://nodei.co/npm/readable-stream/)
+[![NPM](https://nodei.co/npm-dl/readable-stream.png)](https://nodei.co/npm/readable-stream/)
+
+This package is a mirror of the Streams2 and Streams3 implementations in Node-core.
+
+If you want to guarantee a stable streams base, regardless of what version of Node you, or the users of your libraries are using, use **readable-stream** *only* and avoid the *"stream"* module in Node-core.
+
+**readable-stream** comes in two major versions, v1.0.x and v1.1.x. The former tracks the Streams2 implementation in Node 0.10, including bug-fixes and minor improvements as they are added. The latter tracks Streams3 as it develops in Node 0.11; we will likely see a v1.2.x branch for Node 0.12.
+
+**readable-stream** uses proper patch-level versioning so if you pin to `"~1.0.0"` you’ll get the latest Node 0.10 Streams2 implementation, including any fixes and minor non-breaking improvements. The patch-level versions of 1.0.x and 1.1.x should mirror the patch-level versions of Node-core releases. You should prefer the **1.0.x** releases for now and when you’re ready to start using Streams3, pin to `"~1.1.0"`
+
diff -Nru nodejs-0.11.14/deps/npm/node_modules/readable-stream/transform.js nodejs-0.11.15/deps/npm/node_modules/readable-stream/transform.js
--- nodejs-0.11.14/deps/npm/node_modules/readable-stream/transform.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/readable-stream/transform.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1 @@
+module.exports = require("./lib/_stream_transform.js")
diff -Nru nodejs-0.11.14/deps/npm/node_modules/readable-stream/writable.js nodejs-0.11.15/deps/npm/node_modules/readable-stream/writable.js
--- nodejs-0.11.14/deps/npm/node_modules/readable-stream/writable.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/readable-stream/writable.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1 @@
+module.exports = require("./lib/_stream_writable.js")
diff -Nru nodejs-0.11.14/deps/npm/node_modules/realize-package-specifier/index.js nodejs-0.11.15/deps/npm/node_modules/realize-package-specifier/index.js
--- nodejs-0.11.14/deps/npm/node_modules/realize-package-specifier/index.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/realize-package-specifier/index.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,38 @@
+"use strict"
+var fs = require("fs")
+var path = require("path")
+var dz = require("dezalgo")
+var npa = require("npm-package-arg")
+
+module.exports = function (spec, where, cb) {
+ if (where instanceof Function) { cb = where; where = null }
+ if (where == null) where = "."
+ cb = dz(cb)
+ try {
+ var dep = npa(spec)
+ }
+ catch (e) {
+ return cb(e)
+ }
+ var specpath = dep.type == "local"
+ ? path.resolve(where, dep.spec)
+ : path.resolve(dep.rawSpec? dep.rawSpec: dep.name)
+ fs.stat(specpath, function (er, s) {
+ if (er) return finalize()
+ if (!s.isDirectory()) return finalize("local")
+ fs.stat(path.join(specpath, "package.json"), function (er) {
+ finalize(er ? null : "directory")
+ })
+ })
+ function finalize(type) {
+ if (type != null && type != dep.type) {
+ dep.type = type
+ if (! dep.rawSpec) {
+ dep.rawSpec = dep.name
+ dep.name = null
+ }
+ }
+ if (dep.type == "local" || dep.type == "directory") dep.spec = specpath
+ cb(null, dep)
+ }
+}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/realize-package-specifier/.npmignore nodejs-0.11.15/deps/npm/node_modules/realize-package-specifier/.npmignore
--- nodejs-0.11.14/deps/npm/node_modules/realize-package-specifier/.npmignore 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/realize-package-specifier/.npmignore 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,3 @@
+*~
+.#*
+node_modules
diff -Nru nodejs-0.11.14/deps/npm/node_modules/realize-package-specifier/package.json nodejs-0.11.15/deps/npm/node_modules/realize-package-specifier/package.json
--- nodejs-0.11.14/deps/npm/node_modules/realize-package-specifier/package.json 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/realize-package-specifier/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,53 @@
+{
+ "name": "realize-package-specifier",
+ "version": "1.2.0",
+ "description": "Like npm-package-arg, but more so, producing full file paths and differentiating local tar and directory sources.",
+ "main": "index.js",
+ "scripts": {
+ "test": "tap test/*.js"
+ },
+ "license": "ISC",
+ "repository": {
+ "type": "git",
+ "url": "https://github.com/npm/realize-package-specifier.git"
+ },
+ "author": {
+ "name": "Rebecca Turner",
+ "email": "me@re-becca.org",
+ "url": "http://re-becca.org"
+ },
+ "homepage": "https://github.com/npm/realize-package-specifier",
+ "dependencies": {
+ "dezalgo": "^1.0.1",
+ "npm-package-arg": "^2.1.3"
+ },
+ "devDependencies": {
+ "require-inject": "^1.1.0",
+ "tap": "^0.4.12"
+ },
+ "gitHead": "39016343d5bd5572ab39374323e9588e54985910",
+ "bugs": {
+ "url": "https://github.com/npm/realize-package-specifier/issues"
+ },
+ "_id": "realize-package-specifier@1.2.0",
+ "_shasum": "93364e40dee38369f92e9b0c76124500342132f2",
+ "_from": "realize-package-specifier@>=1.2.0 <1.3.0",
+ "_npmVersion": "2.1.2",
+ "_nodeVersion": "0.10.32",
+ "_npmUser": {
+ "name": "iarna",
+ "email": "me@re-becca.org"
+ },
+ "maintainers": [
+ {
+ "name": "iarna",
+ "email": "me@re-becca.org"
+ }
+ ],
+ "dist": {
+ "shasum": "93364e40dee38369f92e9b0c76124500342132f2",
+ "tarball": "http://registry.npmjs.org/realize-package-specifier/-/realize-package-specifier-1.2.0.tgz"
+ },
+ "directories": {},
+ "_resolved": "https://registry.npmjs.org/realize-package-specifier/-/realize-package-specifier-1.2.0.tgz"
+}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/realize-package-specifier/README.md nodejs-0.11.15/deps/npm/node_modules/realize-package-specifier/README.md
--- nodejs-0.11.14/deps/npm/node_modules/realize-package-specifier/README.md 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/realize-package-specifier/README.md 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,58 @@
+realize-package-specifier
+-------------------------
+
+Parse a package specifier, peeking at the disk to differentiate between
+local tarballs, directories and named modules. This implements the logic
+used by `npm install` and `npm cache` to determine where to get packages
+from.
+
+```javascript
+var realizePackageSpecifier = require("realize-package-specifier")
+realizePackageSpecifier("foo.tar.gz", ".", function (err, package) {
+ …
+})
+```
+
+* realizePackageSpecifier(*spec*, [*where*,] *callback*)
+
+Parses *spec* using `npm-package-arg` and then uses stat to check to see if
+it refers to a local tarball or package directory. Stats are done relative
+to *where*. If it does then the local module is loaded. If it doesn't then
+target is left as a remote package specifier. Package directories are
+recognized by the presence of a package.json in them.
+
+*spec* -- a package specifier, like: `foo@1.2`, or `foo@user/foo`, or
+`http://x.com/foo.tgz`, or `git+https://github.com/user/foo`
+
+*where* (optional, default: .) -- The directory in which we should look for
+local tarballs or package directories.
+
+*callback* function(*err*, *result*) -- Called once we've determined what
+kind of specifier this is. The *result* object will be very like the one
+returned by `npm-package-arg` except with three differences: 1) There's a
+new type of `directory`. 2) The `local` type only refers to tarballs. 2)
+For all `local` and `directory` type results spec will contain the full path of
+the local package.
+
+## Result Objects
+
+The full definition of the result object is:
+
+* `name` - If known, the `name` field expected in the resulting pkg.
+* `type` - One of the following strings:
+ * `git` - A git repo
+ * `github` - A github shorthand, like `user/project`
+ * `tag` - A tagged version, like `"foo@latest"`
+ * `version` - A specific version number, like `"foo@1.2.3"`
+ * `range` - A version range, like `"foo@2.x"`
+ * `local` - A local file path
+ * `directory` - A local package directory
+ * `remote` - An http url (presumably to a tgz)
+* `spec` - The "thing". URL, the range, git repo, etc.
+* `raw` - The original un-modified string that was provided.
+* `rawSpec` - The part after the `name@...`, as it was originally
+ provided.
+* `scope` - If a name is something like `@org/module` then the `scope`
+ field will be set to `org`. If it doesn't have a scoped name, then
+ scope is `null`.
+
diff -Nru nodejs-0.11.14/deps/npm/node_modules/realize-package-specifier/test/basic.js nodejs-0.11.15/deps/npm/node_modules/realize-package-specifier/test/basic.js
--- nodejs-0.11.14/deps/npm/node_modules/realize-package-specifier/test/basic.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/realize-package-specifier/test/basic.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,121 @@
+"use strict"
+var test = require("tap").test
+var requireInject = require("require-inject")
+var path = require("path")
+
+var re = {
+ tarball: /[\/\\]a.tar.gz$/,
+ packagedir: /[\/\\]b$/,
+ packagejson: /[\/\\]b[\/\\]package.json$/,
+ nonpackagedir: /[\/\\]c$/,
+ nopackagejson: /[\/\\]c[\/\\]package.json$/,
+ remotename: /[\/\\]d$/,
+ packagedirlikegithub: /[\/\\]e[\/\\]1$/,
+ packagejsonlikegithub: /[\/\\]e[\/\\]1[\/\\]package.json$/,
+ github: /[\/\\]e[\/\\]2$/
+}
+
+var rps = requireInject("../index", {
+ "fs": {
+ "stat": function (path, callback) {
+ if (re.tarball.test(path)) {
+ callback(null,{isDirectory:function(){ return false }})
+ }
+ else if (re.packagedir.test(path)) {
+ callback(null,{isDirectory:function(){ return true }})
+ }
+ else if (re.packagejson.test(path)) {
+ callback(null,{})
+ }
+ else if (re.nonpackagedir.test(path)) {
+ callback(null,{isDirectory:function(){ return true }})
+ }
+ else if (re.nopackagejson.test(path)) {
+ callback(new Error("EFILENOTFOUND"))
+ }
+ else if (re.remotename.test(path)) {
+ callback(new Error("EFILENOTFOUND"))
+ }
+ else if (re.packagedirlikegithub.test(path)) {
+ callback(null,{isDirectory:function(){ return true }})
+ }
+ else if (re.packagejsonlikegithub.test(path)) {
+ callback(null,{})
+ }
+ else if (re.github.test(path)) {
+ callback(new Error("EFILENOTFOUND"))
+ }
+ else {
+ throw new Error("Unknown stat fixture path: "+path)
+ }
+ }
+ }
+})
+
+test("realize-package-specifier", function (t) {
+ t.plan(10)
+ rps("a.tar.gz", function (err, result) {
+ t.is(result.type, "local", "local tarball")
+ })
+ rps("b", function (err, result) {
+ t.is(result.type, "directory", "local package directory")
+ })
+ rps("c", function (err, result) {
+ t.is(result.type, "range", "remote package, non-package local directory")
+ })
+ rps("d", function (err, result) {
+ t.is(result.type, "range", "remote package, no local directory")
+ })
+ rps("file:./a.tar.gz", function (err, result) {
+ t.is(result.type, "local", "local tarball")
+ })
+ rps("file:./b", function (err, result) {
+ t.is(result.type, "directory", "local package directory")
+ })
+ rps("file:./c", function (err, result) {
+ t.is(result.type, "local", "non-package local directory, specified with a file URL")
+ })
+ rps("file:./d", function (err, result) {
+ t.is(result.type, "local", "no local directory, specified with a file URL")
+ })
+ rps("e/1", function (err, result) {
+ t.is(result.type, "directory", "local package directory")
+ })
+ rps("e/2", function (err, result) {
+ t.is(result.type, "github", "github package dependency")
+ })
+})
+test("named realize-package-specifier", function (t) {
+ t.plan(10)
+
+ rps("a@a.tar.gz", function (err, result) {
+ t.is(result.type, "local", "named local tarball")
+ })
+ rps("b@b", function (err, result) {
+ t.is(result.type, "directory", "named local package directory")
+ })
+ rps("c@c", function (err, result) {
+ t.is(result.type, "tag", "remote package, non-package local directory")
+ })
+ rps("d@d", function (err, result) {
+ t.is(result.type, "tag", "remote package, no local directory")
+ })
+ rps("a@file:./a.tar.gz", function (err, result) {
+ t.is(result.type, "local", "local tarball")
+ })
+ rps("b@file:./b", function (err, result) {
+ t.is(result.type, "directory", "local package directory")
+ })
+ rps("c@file:./c", function (err, result) {
+ t.is(result.type, "local", "non-package local directory, specified with a file URL")
+ })
+ rps("d@file:./d", function (err, result) {
+ t.is(result.type, "local", "no local directory, specified with a file URL")
+ })
+ rps("e@e/1", function (err, result) {
+ t.is(result.type, "directory", "local package directory")
+ })
+ rps("e@e/2", function (err, result) {
+ t.is(result.type, "github", "github package dependency")
+ })
+})
diff -Nru nodejs-0.11.14/deps/npm/node_modules/realize-package-specifier/test/npa-basic.js nodejs-0.11.15/deps/npm/node_modules/realize-package-specifier/test/npa-basic.js
--- nodejs-0.11.14/deps/npm/node_modules/realize-package-specifier/test/npa-basic.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/realize-package-specifier/test/npa-basic.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,207 @@
+var test = require("tap").test;
+var rps = require("../index.js")
+var path = require("path")
+
+test("npa-basic", function (t) {
+ t.setMaxListeners(999)
+
+ var tests = {
+ "foo@1.2": {
+ name: "foo",
+ type: "range",
+ spec: ">=1.2.0 <1.3.0",
+ raw: "foo@1.2",
+ rawSpec: "1.2"
+ },
+
+ "@foo/bar": {
+ raw: "@foo/bar",
+ name: "@foo/bar",
+ scope: "@foo",
+ rawSpec: "",
+ spec: "*",
+ type: "range"
+ },
+
+ "@foo/bar@": {
+ raw: "@foo/bar@",
+ name: "@foo/bar",
+ scope: "@foo",
+ rawSpec: "",
+ spec: "*",
+ type: "range"
+ },
+
+ "@foo/bar@baz": {
+ raw: "@foo/bar@baz",
+ name: "@foo/bar",
+ scope: "@foo",
+ rawSpec: "baz",
+ spec: "baz",
+ type: "tag"
+ },
+
+ "@f fo o al/ a d s ;f ": {
+ raw: "@f fo o al/ a d s ;f",
+ name: null,
+ rawSpec: "@f fo o al/ a d s ;f",
+ spec: path.resolve("@f fo o al/ a d s ;f"),
+ type: "local"
+ },
+
+ "foo@1.2.3": {
+ name: "foo",
+ type: "version",
+ spec: "1.2.3",
+ raw: "foo@1.2.3"
+ },
+
+ "foo@=v1.2.3": {
+ name: "foo",
+ type: "version",
+ spec: "1.2.3",
+ raw: "foo@=v1.2.3",
+ rawSpec: "=v1.2.3"
+ },
+
+ "git+ssh://git@github.com/user/foo#1.2.3": {
+ name: null,
+ type: "git",
+ spec: "ssh://git@github.com/user/foo#1.2.3",
+ raw: "git+ssh://git@github.com/user/foo#1.2.3"
+ },
+
+ "git+file://path/to/repo#1.2.3": {
+ name: null,
+ type: "git",
+ spec: "file://path/to/repo#1.2.3",
+ raw: "git+file://path/to/repo#1.2.3"
+ },
+
+ "git://github.com/user/foo": {
+ name: null,
+ type: "git",
+ spec: "git://github.com/user/foo",
+ raw: "git://github.com/user/foo"
+ },
+
+ "@foo/bar@git+ssh://github.com/user/foo": {
+ name: "@foo/bar",
+ scope: "@foo",
+ spec: "ssh://github.com/user/foo",
+ rawSpec: "git+ssh://github.com/user/foo",
+ raw: "@foo/bar@git+ssh://github.com/user/foo"
+ },
+
+ "/path/to/foo": {
+ name: null,
+ type: "local",
+ spec: "/path/to/foo",
+ raw: "/path/to/foo"
+ },
+
+ "file:path/to/foo": {
+ name: null,
+ type: "local",
+ spec: path.resolve(__dirname,"..","path/to/foo"),
+ raw: "file:path/to/foo"
+ },
+
+ "file:~/path/to/foo": {
+ name: null,
+ type: "local",
+ spec: path.resolve(__dirname,"..","~/path/to/foo"),
+ raw: "file:~/path/to/foo"
+ },
+
+ "file:../path/to/foo": {
+ name: null,
+ type: "local",
+ spec: path.resolve(__dirname,"..","../path/to/foo"),
+ raw: "file:../path/to/foo"
+ },
+
+ "file:///path/to/foo": {
+ name: null,
+ type: "local",
+ spec: "/path/to/foo",
+ raw: "file:///path/to/foo"
+ },
+
+ "https://server.com/foo.tgz": {
+ name: null,
+ type: "remote",
+ spec: "https://server.com/foo.tgz",
+ raw: "https://server.com/foo.tgz"
+ },
+
+ "user/foo-js": {
+ name: null,
+ type: "github",
+ spec: "user/foo-js",
+ raw: "user/foo-js"
+ },
+
+ "user/foo-js#bar/baz": {
+ name: null,
+ type: "github",
+ spec: "user/foo-js#bar/baz",
+ raw: "user/foo-js#bar/baz"
+ },
+
+ "user..blerg--/..foo-js# . . . . . some . tags / / /": {
+ name: null,
+ type: "github",
+ spec: "user..blerg--/..foo-js# . . . . . some . tags / / /",
+ raw: "user..blerg--/..foo-js# . . . . . some . tags / / /"
+ },
+
+ "user/foo-js#bar/baz/bin": {
+ name: null,
+ type: "github",
+ spec: "user/foo-js#bar/baz/bin",
+ raw: "user/foo-js#bar/baz/bin"
+ },
+
+ "foo@user/foo-js": {
+ name: "foo",
+ type: "github",
+ spec: "user/foo-js",
+ raw: "foo@user/foo-js"
+ },
+
+ "foo@latest": {
+ name: "foo",
+ type: "tag",
+ spec: "latest",
+ raw: "foo@latest"
+ },
+
+ "foo": {
+ name: "foo",
+ type: "range",
+ spec: "*",
+ raw: "foo"
+ }
+ }
+
+ t.plan( 2 + Object.keys(tests).length * 3 )
+
+ Object.keys(tests).forEach(function (arg) {
+ rps(arg, path.resolve(__dirname,'..'), function(err, res) {
+ t.notOk(err, "No error")
+ t.type(res, "Result")
+ t.has(res, tests[arg])
+ })
+ })
+
+ // Completely unreasonable invalid garbage throws an error
+ rps("this is not a \0 valid package name or url", path.resolve(__dirname,'..'), function (err) {
+ t.ok(err, "error")
+ })
+
+ rps("gopher://yea right", path.resolve(__dirname,'..'), function (err) {
+ t.ok(err, "Unsupported URL Type: gopher://yea right")
+ })
+
+})
diff -Nru nodejs-0.11.14/deps/npm/node_modules/realize-package-specifier/test/npa-windows.js nodejs-0.11.15/deps/npm/node_modules/realize-package-specifier/test/npa-windows.js
--- nodejs-0.11.14/deps/npm/node_modules/realize-package-specifier/test/npa-windows.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/realize-package-specifier/test/npa-windows.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,42 @@
+global.FAKE_WINDOWS = true
+
+var rps = require('../index.js')
+var test = require("tap").test
+var path = require("path")
+
+var cases = {
+ "C:\\x\\y\\z": {
+ raw: 'C:\\x\\y\\z',
+ scope: null,
+ name: null,
+ rawSpec: 'C:\\x\\y\\z',
+ spec: path.resolve('C:\\x\\y\\z'),
+ type: 'local'
+ },
+ "foo@C:\\x\\y\\z": {
+ raw: 'foo@C:\\x\\y\\z',
+ scope: null,
+ name: 'foo',
+ rawSpec: 'C:\\x\\y\\z',
+ spec: path.resolve('C:\\x\\y\\z'),
+ type: 'local'
+ },
+ "foo@/foo/bar/baz": {
+ raw: 'foo@/foo/bar/baz',
+ scope: null,
+ name: 'foo',
+ rawSpec: '/foo/bar/baz',
+ spec: path.resolve('/foo/bar/baz'),
+ type: 'local'
+ }
+}
+
+test("parse a windows path", function (t) {
+ t.plan( Object.keys(cases).length )
+ Object.keys(cases).forEach(function (c) {
+ var expect = cases[c]
+ rps(c, function(err, actual) {
+ t.same(actual, expect, c)
+ })
+ })
+})
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/CONTRIBUTING.md nodejs-0.11.15/deps/npm/node_modules/request/CONTRIBUTING.md
--- nodejs-0.11.14/deps/npm/node_modules/request/CONTRIBUTING.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/CONTRIBUTING.md 2015-01-20 21:22:17.000000000 +0000
@@ -4,7 +4,9 @@
## What?
-Individuals making significant and valuable contributions are given commit-access to the project to contribute as they see fit. This project is more like an open wiki than a standard guarded open source project.
+Individuals making significant and valuable contributions are given
+commit-access to the project to contribute as they see fit. This project is
+more like an open wiki than a standard guarded open source project.
## Rules
@@ -12,10 +14,21 @@
1. **No `--force` pushes** or modifying the Git history in any way.
1. **Non-master branches** ought to be used for ongoing work.
-1. **External API changes and significant modifications** ought to be subject to an **internal pull-request** to solicit feedback from other contributors.
-1. Internal pull-requests to solicit feedback are *encouraged* for any other non-trivial contribution but left to the discretion of the contributor.
-1. For significant changes wait a full 24 hours before merging so that active contributors who are distributed throughout the world have a chance to weigh in.
+1. **External API changes and significant modifications** ought to be subject
+ to an **internal pull-request** to solicit feedback from other contributors.
+1. Internal pull-requests to solicit feedback are *encouraged* for any other
+ non-trivial contribution but left to the discretion of the contributor.
+1. For significant changes wait a full 24 hours before merging so that active
+ contributors who are distributed throughout the world have a chance to weigh
+ in.
1. Contributors should attempt to adhere to the prevailing code-style.
+1. Run `npm test` locally before submitting your PR, to catch any easy to miss
+ style & testing issues. To diagnose test failures, there are two ways to
+ run a single test file:
+ - `node_modules/.bin/taper tests/test-file.js` - run using the default
+ [`taper`](/nylen/taper) test reporter.
+ - `node tests/test-file.js` - view the raw
+ [tap](https://testanything.org/) output.
## Releases
@@ -24,6 +37,8 @@
## Changes to this arrangement
-This is an experiment and feedback is welcome! This document may also be subject to pull-requests or changes by contributors where you believe you have something valuable to add or change.
+This is an experiment and feedback is welcome! This document may also be
+subject to pull-requests or changes by contributors where you believe you have
+something valuable to add or change.
-----------------------------------------
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/.eslintrc nodejs-0.11.15/deps/npm/node_modules/request/.eslintrc
--- nodejs-0.11.14/deps/npm/node_modules/request/.eslintrc 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/.eslintrc 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,22 @@
+{
+ "env": {
+ "node": true
+ },
+ "rules": {
+ // Disallow semi-colons, unless needed to disambiguate statement
+ "semi": [2, "never"],
+ // Require strings to use single quotes
+ "quotes": [2, "single"],
+ // Require curly braces for all control statements
+ "curly": 2,
+ // Disallow using variables and functions before they've been defined
+ "no-use-before-define": 2,
+ // Allow any case for variable naming
+ "camelcase": 0,
+ // Disallow unused variables, except as function arguments
+ "no-unused-vars": [2, {"args":"none"}],
+ // Allow leading underscores for method names
+ // REASON: we use underscores to denote private methods
+ "no-underscore-dangle": 0
+ }
+}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/index.js nodejs-0.11.15/deps/npm/node_modules/request/index.js
--- nodejs-0.11.14/deps/npm/node_modules/request/index.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/index.js 2015-01-20 21:22:17.000000000 +0000
@@ -12,16 +12,18 @@
// See the License for the specific language governing permissions and
// limitations under the License.
+'use strict'
+
var extend = require('util')._extend
, cookies = require('./lib/cookies')
- , copy = require('./lib/copy')
, helpers = require('./lib/helpers')
- , isFunction = helpers.isFunction
+
+var isFunction = helpers.isFunction
, constructObject = helpers.constructObject
, filterForCallback = helpers.filterForCallback
, constructOptionsFrom = helpers.constructOptionsFrom
, paramsHaveRequestBody = helpers.paramsHaveRequestBody
- ;
+
// organize params for patch, post, put, head, del
function initParams(uri, options, callback) {
@@ -36,8 +38,9 @@
}
function request (uri, options, callback) {
- if (typeof uri === 'undefined')
+ if (typeof uri === 'undefined') {
throw new Error('undefined is not a valid uri or options object.')
+ }
var params = initParams(uri, options, callback)
options = params.options
@@ -48,8 +51,9 @@
}
function requester(params) {
- if(typeof params.options._requester === 'function')
+ if(typeof params.options._requester === 'function') {
return params.options._requester
+ }
return request
}
@@ -63,8 +67,9 @@
var params = initParams(uri, options, callback)
params.options.method = 'HEAD'
- if (paramsHaveRequestBody(params))
- throw new Error("HTTP HEAD requests MUST NOT include a request body.")
+ if (paramsHaveRequestBody(params)) {
+ throw new Error('HTTP HEAD requests MUST NOT include a request body.')
+ }
return requester(params)(params.uri || null, params.options, params.callback)
}
@@ -102,7 +107,7 @@
}
request.defaults = function (options, requester) {
-
+ var self = this
var wrap = function (method) {
var headerlessOptions = function (options) {
options = extend({}, options)
@@ -119,13 +124,14 @@
return function (uri, opts, callback) {
var params = initParams(uri, opts, callback)
- params.options = extend(params.options, headerlessOptions(options))
+ params.options = extend(headerlessOptions(options), params.options)
- if (options.headers)
+ if (options.headers) {
params.options.headers = getHeaders(params, options)
+ }
if (isFunction(requester)) {
- if (method === request) {
+ if (method === self) {
method = requester
} else {
params.options._requester = requester
@@ -136,23 +142,27 @@
}
}
- defaults = wrap(this)
- defaults.get = wrap(this.get)
- defaults.patch = wrap(this.patch)
- defaults.post = wrap(this.post)
- defaults.put = wrap(this.put)
- defaults.head = wrap(this.head)
- defaults.del = wrap(this.del)
- defaults.cookie = wrap(this.cookie)
- defaults.jar = this.jar
- defaults.defaults = this.defaults
+ var defaults = wrap(self)
+ defaults.get = wrap(self.get)
+ defaults.patch = wrap(self.patch)
+ defaults.post = wrap(self.post)
+ defaults.put = wrap(self.put)
+ defaults.head = wrap(self.head)
+ defaults.del = wrap(self.del)
+ defaults.cookie = wrap(self.cookie)
+ defaults.jar = self.jar
+ defaults.defaults = self.defaults
return defaults
}
request.forever = function (agentOptions, optionsArg) {
var options = constructObject()
- if (optionsArg) options.extend(optionsArg)
- if (agentOptions) options.agentOptions = agentOptions
+ if (optionsArg) {
+ options.extend(optionsArg)
+ }
+ if (agentOptions) {
+ options.agentOptions = agentOptions
+ }
options.extend({forever: true})
return request.defaults(options.done())
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/lib/cookies.js nodejs-0.11.15/deps/npm/node_modules/request/lib/cookies.js
--- nodejs-0.11.14/deps/npm/node_modules/request/lib/cookies.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/lib/cookies.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,31 +1,41 @@
-var optional = require('./optional')
- , tough = optional('tough-cookie')
- , Cookie = tough && tough.Cookie
- , CookieJar = tough && tough.CookieJar
- ;
+'use strict'
+
+var tough = require('tough-cookie')
+
+var Cookie = tough.Cookie
+ , CookieJar = tough.CookieJar
+
exports.parse = function(str) {
- if (str && str.uri) str = str.uri
- if (typeof str !== 'string') throw new Error("The cookie function only accepts STRING as param")
+ if (str && str.uri) {
+ str = str.uri
+ }
+ if (typeof str !== 'string') {
+ throw new Error('The cookie function only accepts STRING as param')
+ }
if (!Cookie) {
- return null;
+ return null
}
return Cookie.parse(str)
-};
+}
// Adapt the sometimes-Async api of tough.CookieJar to our requirements
function RequestJar() {
- this._jar = new CookieJar();
+ var self = this
+ self._jar = new CookieJar()
}
RequestJar.prototype.setCookie = function(cookieOrStr, uri, options) {
- return this._jar.setCookieSync(cookieOrStr, uri, options || {});
-};
+ var self = this
+ return self._jar.setCookieSync(cookieOrStr, uri, options || {})
+}
RequestJar.prototype.getCookieString = function(uri) {
- return this._jar.getCookieStringSync(uri);
-};
+ var self = this
+ return self._jar.getCookieStringSync(uri)
+}
RequestJar.prototype.getCookies = function(uri) {
- return this._jar.getCookiesSync(uri);
-};
+ var self = this
+ return self._jar.getCookiesSync(uri)
+}
exports.jar = function() {
if (!CookieJar) {
@@ -34,7 +44,7 @@
setCookie: function(){},
getCookieString: function(){},
getCookies: function(){}
- };
+ }
}
- return new RequestJar();
-};
+ return new RequestJar()
+}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/lib/copy.js nodejs-0.11.15/deps/npm/node_modules/request/lib/copy.js
--- nodejs-0.11.14/deps/npm/node_modules/request/lib/copy.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/lib/copy.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,3 +1,5 @@
+'use strict'
+
module.exports =
function copy (obj) {
var o = {}
@@ -5,4 +7,4 @@
o[i] = obj[i]
})
return o
-}
\ No newline at end of file
+}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/lib/debug.js nodejs-0.11.15/deps/npm/node_modules/request/lib/debug.js
--- nodejs-0.11.14/deps/npm/node_modules/request/lib/debug.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/lib/debug.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,6 +1,8 @@
+'use strict'
+
var util = require('util')
, request = require('../index')
- ;
+
module.exports = function debug() {
if (request.debug) {
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/lib/helpers.js nodejs-0.11.15/deps/npm/node_modules/request/lib/helpers.js
--- nodejs-0.11.14/deps/npm/node_modules/request/lib/helpers.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/lib/helpers.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,4 +1,16 @@
+'use strict'
+
var extend = require('util')._extend
+ , jsonSafeStringify = require('json-stringify-safe')
+ , crypto = require('crypto')
+
+function deferMethod() {
+ if(typeof setImmediate === 'undefined') {
+ return process.nextTick
+ }
+
+ return setImmediate
+}
function constructObject(initialObject) {
initialObject = initialObject || {}
@@ -15,21 +27,25 @@
function constructOptionsFrom(uri, options) {
var params = constructObject()
- if (typeof uri === 'object') params.extend(uri)
- if (typeof uri === 'string') params.extend({uri: uri})
- params.extend(options)
+ if (typeof options === 'object') {
+ params.extend(options).extend({uri: uri})
+ } else if (typeof uri === 'string') {
+ params.extend({uri: uri})
+ } else {
+ params.extend(uri)
+ }
return params.done()
}
+function isFunction(value) {
+ return typeof value === 'function'
+}
+
function filterForCallback(values) {
var callbacks = values.filter(isFunction)
return callbacks[0]
}
-function isFunction(value) {
- return typeof value === 'function'
-}
-
function paramsHaveRequestBody(params) {
return (
params.options.body ||
@@ -39,8 +55,35 @@
)
}
+function safeStringify (obj) {
+ var ret
+ try {
+ ret = JSON.stringify(obj)
+ } catch (e) {
+ ret = jsonSafeStringify(obj)
+ }
+ return ret
+}
+
+function md5 (str) {
+ return crypto.createHash('md5').update(str).digest('hex')
+}
+
+function isReadStream (rs) {
+ return rs.readable && rs.path && rs.mode
+}
+
+function toBase64 (str) {
+ return (new Buffer(str || '', 'ascii')).toString('base64')
+}
+
exports.isFunction = isFunction
exports.constructObject = constructObject
exports.constructOptionsFrom = constructOptionsFrom
exports.filterForCallback = filterForCallback
exports.paramsHaveRequestBody = paramsHaveRequestBody
+exports.safeStringify = safeStringify
+exports.md5 = md5
+exports.isReadStream = isReadStream
+exports.toBase64 = toBase64
+exports.defer = deferMethod()
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/lib/optional.js nodejs-0.11.15/deps/npm/node_modules/request/lib/optional.js
--- nodejs-0.11.14/deps/npm/node_modules/request/lib/optional.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/lib/optional.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,13 +0,0 @@
-module.exports = function(moduleName) {
- try {
- return module.parent.require(moduleName);
- } catch (e) {
- // This could mean that we are in a browser context.
- // Add another try catch like it used to be, for backwards compability
- // and browserify reasons.
- try {
- return require(moduleName);
- }
- catch (e) {}
- }
-};
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/aws-sign2/package.json nodejs-0.11.15/deps/npm/node_modules/request/node_modules/aws-sign2/package.json
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/aws-sign2/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/aws-sign2/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -27,7 +27,7 @@
"shasum": "c57103f7a17fc037f02d7c2e64b602ea223f7d63",
"tarball": "http://registry.npmjs.org/aws-sign2/-/aws-sign2-0.5.0.tgz"
},
- "_from": "aws-sign2@>=0.5.0-0 <0.6.0-0",
+ "_from": "aws-sign2@>=0.5.0 <0.6.0",
"_npmVersion": "1.3.2",
"_npmUser": {
"name": "mikeal",
@@ -42,5 +42,6 @@
"directories": {},
"_shasum": "c57103f7a17fc037f02d7c2e64b602ea223f7d63",
"_resolved": "https://registry.npmjs.org/aws-sign2/-/aws-sign2-0.5.0.tgz",
- "homepage": "https://github.com/mikeal/aws-sign"
+ "homepage": "https://github.com/mikeal/aws-sign",
+ "scripts": {}
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/.jshintrc nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/.jshintrc
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/.jshintrc 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/.jshintrc 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,59 @@
+{
+ "predef": [ ]
+ , "bitwise": false
+ , "camelcase": false
+ , "curly": false
+ , "eqeqeq": false
+ , "forin": false
+ , "immed": false
+ , "latedef": false
+ , "noarg": true
+ , "noempty": true
+ , "nonew": true
+ , "plusplus": false
+ , "quotmark": true
+ , "regexp": false
+ , "undef": true
+ , "unused": true
+ , "strict": false
+ , "trailing": true
+ , "maxlen": 120
+ , "asi": true
+ , "boss": true
+ , "debug": true
+ , "eqnull": true
+ , "esnext": true
+ , "evil": true
+ , "expr": true
+ , "funcscope": false
+ , "globalstrict": false
+ , "iterator": false
+ , "lastsemic": true
+ , "laxbreak": true
+ , "laxcomma": true
+ , "loopfunc": true
+ , "multistr": false
+ , "onecase": false
+ , "proto": false
+ , "regexdash": false
+ , "scripturl": true
+ , "smarttabs": false
+ , "shadow": false
+ , "sub": true
+ , "supernew": false
+ , "validthis": true
+ , "browser": true
+ , "couch": false
+ , "devel": false
+ , "dojo": false
+ , "mootools": false
+ , "node": true
+ , "nonstandard": true
+ , "prototypejs": false
+ , "rhino": false
+ , "worker": true
+ , "wsh": false
+ , "nomen": false
+ , "onevar": false
+ , "passfail": false
+}
\ No newline at end of file
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/LICENSE nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/LICENSE
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/LICENSE 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/LICENSE 1970-01-01 00:00:00.000000000 +0000
@@ -1,39 +0,0 @@
-Copyright 2013, Rod Vagg (the "Original Author")
-All rights reserved.
-
-MIT +no-false-attribs License
-
-Permission is hereby granted, free of charge, to any person
-obtaining a copy of this software and associated documentation
-files (the "Software"), to deal in the Software without
-restriction, including without limitation the rights to use,
-copy, modify, merge, publish, distribute, sublicense, and/or sell
-copies of the Software, and to permit persons to whom the
-Software is furnished to do so, subject to the following
-conditions:
-
-The above copyright notice and this permission notice shall be
-included in all copies or substantial portions of the Software.
-
-Distributions of all or part of the Software intended to be used
-by the recipients as they would use the unmodified Software,
-containing modifications that substantially alter, remove, or
-disable functionality of the Software, outside of the documented
-configuration mechanisms provided by the Software, shall be
-modified such that the Original Author's bug reporting email
-addresses and urls are either replaced with the contact information
-of the parties responsible for the changes, or removed entirely.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
-EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
-OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
-NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
-HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
-WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
-FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
-OTHER DEALINGS IN THE SOFTWARE.
-
-
-Except where noted, this license applies to any and all software
-programs and associated documentation files created by the
-Original Author, when distributed with the Software.
\ No newline at end of file
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/LICENSE.md nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/LICENSE.md
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/LICENSE.md 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/LICENSE.md 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,13 @@
+The MIT License (MIT)
+=====================
+
+Copyright (c) 2014 bl contributors
+----------------------------------
+
+*bl contributors listed at *
+
+Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/duplex.js nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/duplex.js
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/duplex.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/duplex.js 1970-01-01 00:00:00.000000000 +0000
@@ -1 +0,0 @@
-module.exports = require("./lib/_stream_duplex.js")
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/lib/_stream_duplex.js nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/lib/_stream_duplex.js
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/lib/_stream_duplex.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/lib/_stream_duplex.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,89 +0,0 @@
-// Copyright Joyent, Inc. and other Node contributors.
-//
-// Permission is hereby granted, free of charge, to any person obtaining a
-// copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to permit
-// persons to whom the Software is furnished to do so, subject to the
-// following conditions:
-//
-// The above copyright notice and this permission notice shall be included
-// in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
-// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
-// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
-// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
-// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
-// USE OR OTHER DEALINGS IN THE SOFTWARE.
-
-// a duplex stream is just a stream that is both readable and writable.
-// Since JS doesn't have multiple prototypal inheritance, this class
-// prototypally inherits from Readable, and then parasitically from
-// Writable.
-
-module.exports = Duplex;
-
-/**/
-var objectKeys = Object.keys || function (obj) {
- var keys = [];
- for (var key in obj) keys.push(key);
- return keys;
-}
-/* */
-
-
-/**/
-var util = require('core-util-is');
-util.inherits = require('inherits');
-/* */
-
-var Readable = require('./_stream_readable');
-var Writable = require('./_stream_writable');
-
-util.inherits(Duplex, Readable);
-
-forEach(objectKeys(Writable.prototype), function(method) {
- if (!Duplex.prototype[method])
- Duplex.prototype[method] = Writable.prototype[method];
-});
-
-function Duplex(options) {
- if (!(this instanceof Duplex))
- return new Duplex(options);
-
- Readable.call(this, options);
- Writable.call(this, options);
-
- if (options && options.readable === false)
- this.readable = false;
-
- if (options && options.writable === false)
- this.writable = false;
-
- this.allowHalfOpen = true;
- if (options && options.allowHalfOpen === false)
- this.allowHalfOpen = false;
-
- this.once('end', onend);
-}
-
-// the no-half-open enforcer
-function onend() {
- // if we allow half-open state, or if the writable side ended,
- // then we're ok.
- if (this.allowHalfOpen || this._writableState.ended)
- return;
-
- // no more data can be written.
- // But allow more writes to happen in this tick.
- process.nextTick(this.end.bind(this));
-}
-
-function forEach (xs, f) {
- for (var i = 0, l = xs.length; i < l; i++) {
- f(xs[i], i);
- }
-}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/lib/_stream_passthrough.js nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/lib/_stream_passthrough.js
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/lib/_stream_passthrough.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/lib/_stream_passthrough.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,46 +0,0 @@
-// Copyright Joyent, Inc. and other Node contributors.
-//
-// Permission is hereby granted, free of charge, to any person obtaining a
-// copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to permit
-// persons to whom the Software is furnished to do so, subject to the
-// following conditions:
-//
-// The above copyright notice and this permission notice shall be included
-// in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
-// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
-// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
-// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
-// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
-// USE OR OTHER DEALINGS IN THE SOFTWARE.
-
-// a passthrough stream.
-// basically just the most minimal sort of Transform stream.
-// Every written chunk gets output as-is.
-
-module.exports = PassThrough;
-
-var Transform = require('./_stream_transform');
-
-/**/
-var util = require('core-util-is');
-util.inherits = require('inherits');
-/* */
-
-util.inherits(PassThrough, Transform);
-
-function PassThrough(options) {
- if (!(this instanceof PassThrough))
- return new PassThrough(options);
-
- Transform.call(this, options);
-}
-
-PassThrough.prototype._transform = function(chunk, encoding, cb) {
- cb(null, chunk);
-};
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/lib/_stream_readable.js nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/lib/_stream_readable.js
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/lib/_stream_readable.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/lib/_stream_readable.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,982 +0,0 @@
-// Copyright Joyent, Inc. and other Node contributors.
-//
-// Permission is hereby granted, free of charge, to any person obtaining a
-// copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to permit
-// persons to whom the Software is furnished to do so, subject to the
-// following conditions:
-//
-// The above copyright notice and this permission notice shall be included
-// in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
-// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
-// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
-// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
-// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
-// USE OR OTHER DEALINGS IN THE SOFTWARE.
-
-module.exports = Readable;
-
-/**/
-var isArray = require('isarray');
-/* */
-
-
-/**/
-var Buffer = require('buffer').Buffer;
-/* */
-
-Readable.ReadableState = ReadableState;
-
-var EE = require('events').EventEmitter;
-
-/**/
-if (!EE.listenerCount) EE.listenerCount = function(emitter, type) {
- return emitter.listeners(type).length;
-};
-/* */
-
-var Stream = require('stream');
-
-/**/
-var util = require('core-util-is');
-util.inherits = require('inherits');
-/* */
-
-var StringDecoder;
-
-util.inherits(Readable, Stream);
-
-function ReadableState(options, stream) {
- options = options || {};
-
- // the point at which it stops calling _read() to fill the buffer
- // Note: 0 is a valid value, means "don't call _read preemptively ever"
- var hwm = options.highWaterMark;
- this.highWaterMark = (hwm || hwm === 0) ? hwm : 16 * 1024;
-
- // cast to ints.
- this.highWaterMark = ~~this.highWaterMark;
-
- this.buffer = [];
- this.length = 0;
- this.pipes = null;
- this.pipesCount = 0;
- this.flowing = false;
- this.ended = false;
- this.endEmitted = false;
- this.reading = false;
-
- // In streams that never have any data, and do push(null) right away,
- // the consumer can miss the 'end' event if they do some I/O before
- // consuming the stream. So, we don't emit('end') until some reading
- // happens.
- this.calledRead = false;
-
- // a flag to be able to tell if the onwrite cb is called immediately,
- // or on a later tick. We set this to true at first, becuase any
- // actions that shouldn't happen until "later" should generally also
- // not happen before the first write call.
- this.sync = true;
-
- // whenever we return null, then we set a flag to say
- // that we're awaiting a 'readable' event emission.
- this.needReadable = false;
- this.emittedReadable = false;
- this.readableListening = false;
-
-
- // object stream flag. Used to make read(n) ignore n and to
- // make all the buffer merging and length checks go away
- this.objectMode = !!options.objectMode;
-
- // Crypto is kind of old and crusty. Historically, its default string
- // encoding is 'binary' so we have to make this configurable.
- // Everything else in the universe uses 'utf8', though.
- this.defaultEncoding = options.defaultEncoding || 'utf8';
-
- // when piping, we only care about 'readable' events that happen
- // after read()ing all the bytes and not getting any pushback.
- this.ranOut = false;
-
- // the number of writers that are awaiting a drain event in .pipe()s
- this.awaitDrain = 0;
-
- // if true, a maybeReadMore has been scheduled
- this.readingMore = false;
-
- this.decoder = null;
- this.encoding = null;
- if (options.encoding) {
- if (!StringDecoder)
- StringDecoder = require('string_decoder/').StringDecoder;
- this.decoder = new StringDecoder(options.encoding);
- this.encoding = options.encoding;
- }
-}
-
-function Readable(options) {
- if (!(this instanceof Readable))
- return new Readable(options);
-
- this._readableState = new ReadableState(options, this);
-
- // legacy
- this.readable = true;
-
- Stream.call(this);
-}
-
-// Manually shove something into the read() buffer.
-// This returns true if the highWaterMark has not been hit yet,
-// similar to how Writable.write() returns true if you should
-// write() some more.
-Readable.prototype.push = function(chunk, encoding) {
- var state = this._readableState;
-
- if (typeof chunk === 'string' && !state.objectMode) {
- encoding = encoding || state.defaultEncoding;
- if (encoding !== state.encoding) {
- chunk = new Buffer(chunk, encoding);
- encoding = '';
- }
- }
-
- return readableAddChunk(this, state, chunk, encoding, false);
-};
-
-// Unshift should *always* be something directly out of read()
-Readable.prototype.unshift = function(chunk) {
- var state = this._readableState;
- return readableAddChunk(this, state, chunk, '', true);
-};
-
-function readableAddChunk(stream, state, chunk, encoding, addToFront) {
- var er = chunkInvalid(state, chunk);
- if (er) {
- stream.emit('error', er);
- } else if (chunk === null || chunk === undefined) {
- state.reading = false;
- if (!state.ended)
- onEofChunk(stream, state);
- } else if (state.objectMode || chunk && chunk.length > 0) {
- if (state.ended && !addToFront) {
- var e = new Error('stream.push() after EOF');
- stream.emit('error', e);
- } else if (state.endEmitted && addToFront) {
- var e = new Error('stream.unshift() after end event');
- stream.emit('error', e);
- } else {
- if (state.decoder && !addToFront && !encoding)
- chunk = state.decoder.write(chunk);
-
- // update the buffer info.
- state.length += state.objectMode ? 1 : chunk.length;
- if (addToFront) {
- state.buffer.unshift(chunk);
- } else {
- state.reading = false;
- state.buffer.push(chunk);
- }
-
- if (state.needReadable)
- emitReadable(stream);
-
- maybeReadMore(stream, state);
- }
- } else if (!addToFront) {
- state.reading = false;
- }
-
- return needMoreData(state);
-}
-
-
-
-// if it's past the high water mark, we can push in some more.
-// Also, if we have no data yet, we can stand some
-// more bytes. This is to work around cases where hwm=0,
-// such as the repl. Also, if the push() triggered a
-// readable event, and the user called read(largeNumber) such that
-// needReadable was set, then we ought to push more, so that another
-// 'readable' event will be triggered.
-function needMoreData(state) {
- return !state.ended &&
- (state.needReadable ||
- state.length < state.highWaterMark ||
- state.length === 0);
-}
-
-// backwards compatibility.
-Readable.prototype.setEncoding = function(enc) {
- if (!StringDecoder)
- StringDecoder = require('string_decoder/').StringDecoder;
- this._readableState.decoder = new StringDecoder(enc);
- this._readableState.encoding = enc;
-};
-
-// Don't raise the hwm > 128MB
-var MAX_HWM = 0x800000;
-function roundUpToNextPowerOf2(n) {
- if (n >= MAX_HWM) {
- n = MAX_HWM;
- } else {
- // Get the next highest power of 2
- n--;
- for (var p = 1; p < 32; p <<= 1) n |= n >> p;
- n++;
- }
- return n;
-}
-
-function howMuchToRead(n, state) {
- if (state.length === 0 && state.ended)
- return 0;
-
- if (state.objectMode)
- return n === 0 ? 0 : 1;
-
- if (n === null || isNaN(n)) {
- // only flow one buffer at a time
- if (state.flowing && state.buffer.length)
- return state.buffer[0].length;
- else
- return state.length;
- }
-
- if (n <= 0)
- return 0;
-
- // If we're asking for more than the target buffer level,
- // then raise the water mark. Bump up to the next highest
- // power of 2, to prevent increasing it excessively in tiny
- // amounts.
- if (n > state.highWaterMark)
- state.highWaterMark = roundUpToNextPowerOf2(n);
-
- // don't have that much. return null, unless we've ended.
- if (n > state.length) {
- if (!state.ended) {
- state.needReadable = true;
- return 0;
- } else
- return state.length;
- }
-
- return n;
-}
-
-// you can override either this method, or the async _read(n) below.
-Readable.prototype.read = function(n) {
- var state = this._readableState;
- state.calledRead = true;
- var nOrig = n;
- var ret;
-
- if (typeof n !== 'number' || n > 0)
- state.emittedReadable = false;
-
- // if we're doing read(0) to trigger a readable event, but we
- // already have a bunch of data in the buffer, then just trigger
- // the 'readable' event and move on.
- if (n === 0 &&
- state.needReadable &&
- (state.length >= state.highWaterMark || state.ended)) {
- emitReadable(this);
- return null;
- }
-
- n = howMuchToRead(n, state);
-
- // if we've ended, and we're now clear, then finish it up.
- if (n === 0 && state.ended) {
- ret = null;
-
- // In cases where the decoder did not receive enough data
- // to produce a full chunk, then immediately received an
- // EOF, state.buffer will contain [, ].
- // howMuchToRead will see this and coerce the amount to
- // read to zero (because it's looking at the length of the
- // first in state.buffer), and we'll end up here.
- //
- // This can only happen via state.decoder -- no other venue
- // exists for pushing a zero-length chunk into state.buffer
- // and triggering this behavior. In this case, we return our
- // remaining data and end the stream, if appropriate.
- if (state.length > 0 && state.decoder) {
- ret = fromList(n, state);
- state.length -= ret.length;
- }
-
- if (state.length === 0)
- endReadable(this);
-
- return ret;
- }
-
- // All the actual chunk generation logic needs to be
- // *below* the call to _read. The reason is that in certain
- // synthetic stream cases, such as passthrough streams, _read
- // may be a completely synchronous operation which may change
- // the state of the read buffer, providing enough data when
- // before there was *not* enough.
- //
- // So, the steps are:
- // 1. Figure out what the state of things will be after we do
- // a read from the buffer.
- //
- // 2. If that resulting state will trigger a _read, then call _read.
- // Note that this may be asynchronous, or synchronous. Yes, it is
- // deeply ugly to write APIs this way, but that still doesn't mean
- // that the Readable class should behave improperly, as streams are
- // designed to be sync/async agnostic.
- // Take note if the _read call is sync or async (ie, if the read call
- // has returned yet), so that we know whether or not it's safe to emit
- // 'readable' etc.
- //
- // 3. Actually pull the requested chunks out of the buffer and return.
-
- // if we need a readable event, then we need to do some reading.
- var doRead = state.needReadable;
-
- // if we currently have less than the highWaterMark, then also read some
- if (state.length - n <= state.highWaterMark)
- doRead = true;
-
- // however, if we've ended, then there's no point, and if we're already
- // reading, then it's unnecessary.
- if (state.ended || state.reading)
- doRead = false;
-
- if (doRead) {
- state.reading = true;
- state.sync = true;
- // if the length is currently zero, then we *need* a readable event.
- if (state.length === 0)
- state.needReadable = true;
- // call internal read method
- this._read(state.highWaterMark);
- state.sync = false;
- }
-
- // If _read called its callback synchronously, then `reading`
- // will be false, and we need to re-evaluate how much data we
- // can return to the user.
- if (doRead && !state.reading)
- n = howMuchToRead(nOrig, state);
-
- if (n > 0)
- ret = fromList(n, state);
- else
- ret = null;
-
- if (ret === null) {
- state.needReadable = true;
- n = 0;
- }
-
- state.length -= n;
-
- // If we have nothing in the buffer, then we want to know
- // as soon as we *do* get something into the buffer.
- if (state.length === 0 && !state.ended)
- state.needReadable = true;
-
- // If we happened to read() exactly the remaining amount in the
- // buffer, and the EOF has been seen at this point, then make sure
- // that we emit 'end' on the very next tick.
- if (state.ended && !state.endEmitted && state.length === 0)
- endReadable(this);
-
- return ret;
-};
-
-function chunkInvalid(state, chunk) {
- var er = null;
- if (!Buffer.isBuffer(chunk) &&
- 'string' !== typeof chunk &&
- chunk !== null &&
- chunk !== undefined &&
- !state.objectMode) {
- er = new TypeError('Invalid non-string/buffer chunk');
- }
- return er;
-}
-
-
-function onEofChunk(stream, state) {
- if (state.decoder && !state.ended) {
- var chunk = state.decoder.end();
- if (chunk && chunk.length) {
- state.buffer.push(chunk);
- state.length += state.objectMode ? 1 : chunk.length;
- }
- }
- state.ended = true;
-
- // if we've ended and we have some data left, then emit
- // 'readable' now to make sure it gets picked up.
- if (state.length > 0)
- emitReadable(stream);
- else
- endReadable(stream);
-}
-
-// Don't emit readable right away in sync mode, because this can trigger
-// another read() call => stack overflow. This way, it might trigger
-// a nextTick recursion warning, but that's not so bad.
-function emitReadable(stream) {
- var state = stream._readableState;
- state.needReadable = false;
- if (state.emittedReadable)
- return;
-
- state.emittedReadable = true;
- if (state.sync)
- process.nextTick(function() {
- emitReadable_(stream);
- });
- else
- emitReadable_(stream);
-}
-
-function emitReadable_(stream) {
- stream.emit('readable');
-}
-
-
-// at this point, the user has presumably seen the 'readable' event,
-// and called read() to consume some data. that may have triggered
-// in turn another _read(n) call, in which case reading = true if
-// it's in progress.
-// However, if we're not ended, or reading, and the length < hwm,
-// then go ahead and try to read some more preemptively.
-function maybeReadMore(stream, state) {
- if (!state.readingMore) {
- state.readingMore = true;
- process.nextTick(function() {
- maybeReadMore_(stream, state);
- });
- }
-}
-
-function maybeReadMore_(stream, state) {
- var len = state.length;
- while (!state.reading && !state.flowing && !state.ended &&
- state.length < state.highWaterMark) {
- stream.read(0);
- if (len === state.length)
- // didn't get any data, stop spinning.
- break;
- else
- len = state.length;
- }
- state.readingMore = false;
-}
-
-// abstract method. to be overridden in specific implementation classes.
-// call cb(er, data) where data is <= n in length.
-// for virtual (non-string, non-buffer) streams, "length" is somewhat
-// arbitrary, and perhaps not very meaningful.
-Readable.prototype._read = function(n) {
- this.emit('error', new Error('not implemented'));
-};
-
-Readable.prototype.pipe = function(dest, pipeOpts) {
- var src = this;
- var state = this._readableState;
-
- switch (state.pipesCount) {
- case 0:
- state.pipes = dest;
- break;
- case 1:
- state.pipes = [state.pipes, dest];
- break;
- default:
- state.pipes.push(dest);
- break;
- }
- state.pipesCount += 1;
-
- var doEnd = (!pipeOpts || pipeOpts.end !== false) &&
- dest !== process.stdout &&
- dest !== process.stderr;
-
- var endFn = doEnd ? onend : cleanup;
- if (state.endEmitted)
- process.nextTick(endFn);
- else
- src.once('end', endFn);
-
- dest.on('unpipe', onunpipe);
- function onunpipe(readable) {
- if (readable !== src) return;
- cleanup();
- }
-
- function onend() {
- dest.end();
- }
-
- // when the dest drains, it reduces the awaitDrain counter
- // on the source. This would be more elegant with a .once()
- // handler in flow(), but adding and removing repeatedly is
- // too slow.
- var ondrain = pipeOnDrain(src);
- dest.on('drain', ondrain);
-
- function cleanup() {
- // cleanup event handlers once the pipe is broken
- dest.removeListener('close', onclose);
- dest.removeListener('finish', onfinish);
- dest.removeListener('drain', ondrain);
- dest.removeListener('error', onerror);
- dest.removeListener('unpipe', onunpipe);
- src.removeListener('end', onend);
- src.removeListener('end', cleanup);
-
- // if the reader is waiting for a drain event from this
- // specific writer, then it would cause it to never start
- // flowing again.
- // So, if this is awaiting a drain, then we just call it now.
- // If we don't know, then assume that we are waiting for one.
- if (!dest._writableState || dest._writableState.needDrain)
- ondrain();
- }
-
- // if the dest has an error, then stop piping into it.
- // however, don't suppress the throwing behavior for this.
- function onerror(er) {
- unpipe();
- dest.removeListener('error', onerror);
- if (EE.listenerCount(dest, 'error') === 0)
- dest.emit('error', er);
- }
- // This is a brutally ugly hack to make sure that our error handler
- // is attached before any userland ones. NEVER DO THIS.
- if (!dest._events || !dest._events.error)
- dest.on('error', onerror);
- else if (isArray(dest._events.error))
- dest._events.error.unshift(onerror);
- else
- dest._events.error = [onerror, dest._events.error];
-
-
-
- // Both close and finish should trigger unpipe, but only once.
- function onclose() {
- dest.removeListener('finish', onfinish);
- unpipe();
- }
- dest.once('close', onclose);
- function onfinish() {
- dest.removeListener('close', onclose);
- unpipe();
- }
- dest.once('finish', onfinish);
-
- function unpipe() {
- src.unpipe(dest);
- }
-
- // tell the dest that it's being piped to
- dest.emit('pipe', src);
-
- // start the flow if it hasn't been started already.
- if (!state.flowing) {
- // the handler that waits for readable events after all
- // the data gets sucked out in flow.
- // This would be easier to follow with a .once() handler
- // in flow(), but that is too slow.
- this.on('readable', pipeOnReadable);
-
- state.flowing = true;
- process.nextTick(function() {
- flow(src);
- });
- }
-
- return dest;
-};
-
-function pipeOnDrain(src) {
- return function() {
- var dest = this;
- var state = src._readableState;
- state.awaitDrain--;
- if (state.awaitDrain === 0)
- flow(src);
- };
-}
-
-function flow(src) {
- var state = src._readableState;
- var chunk;
- state.awaitDrain = 0;
-
- function write(dest, i, list) {
- var written = dest.write(chunk);
- if (false === written) {
- state.awaitDrain++;
- }
- }
-
- while (state.pipesCount && null !== (chunk = src.read())) {
-
- if (state.pipesCount === 1)
- write(state.pipes, 0, null);
- else
- forEach(state.pipes, write);
-
- src.emit('data', chunk);
-
- // if anyone needs a drain, then we have to wait for that.
- if (state.awaitDrain > 0)
- return;
- }
-
- // if every destination was unpiped, either before entering this
- // function, or in the while loop, then stop flowing.
- //
- // NB: This is a pretty rare edge case.
- if (state.pipesCount === 0) {
- state.flowing = false;
-
- // if there were data event listeners added, then switch to old mode.
- if (EE.listenerCount(src, 'data') > 0)
- emitDataEvents(src);
- return;
- }
-
- // at this point, no one needed a drain, so we just ran out of data
- // on the next readable event, start it over again.
- state.ranOut = true;
-}
-
-function pipeOnReadable() {
- if (this._readableState.ranOut) {
- this._readableState.ranOut = false;
- flow(this);
- }
-}
-
-
-Readable.prototype.unpipe = function(dest) {
- var state = this._readableState;
-
- // if we're not piping anywhere, then do nothing.
- if (state.pipesCount === 0)
- return this;
-
- // just one destination. most common case.
- if (state.pipesCount === 1) {
- // passed in one, but it's not the right one.
- if (dest && dest !== state.pipes)
- return this;
-
- if (!dest)
- dest = state.pipes;
-
- // got a match.
- state.pipes = null;
- state.pipesCount = 0;
- this.removeListener('readable', pipeOnReadable);
- state.flowing = false;
- if (dest)
- dest.emit('unpipe', this);
- return this;
- }
-
- // slow case. multiple pipe destinations.
-
- if (!dest) {
- // remove all.
- var dests = state.pipes;
- var len = state.pipesCount;
- state.pipes = null;
- state.pipesCount = 0;
- this.removeListener('readable', pipeOnReadable);
- state.flowing = false;
-
- for (var i = 0; i < len; i++)
- dests[i].emit('unpipe', this);
- return this;
- }
-
- // try to find the right one.
- var i = indexOf(state.pipes, dest);
- if (i === -1)
- return this;
-
- state.pipes.splice(i, 1);
- state.pipesCount -= 1;
- if (state.pipesCount === 1)
- state.pipes = state.pipes[0];
-
- dest.emit('unpipe', this);
-
- return this;
-};
-
-// set up data events if they are asked for
-// Ensure readable listeners eventually get something
-Readable.prototype.on = function(ev, fn) {
- var res = Stream.prototype.on.call(this, ev, fn);
-
- if (ev === 'data' && !this._readableState.flowing)
- emitDataEvents(this);
-
- if (ev === 'readable' && this.readable) {
- var state = this._readableState;
- if (!state.readableListening) {
- state.readableListening = true;
- state.emittedReadable = false;
- state.needReadable = true;
- if (!state.reading) {
- this.read(0);
- } else if (state.length) {
- emitReadable(this, state);
- }
- }
- }
-
- return res;
-};
-Readable.prototype.addListener = Readable.prototype.on;
-
-// pause() and resume() are remnants of the legacy readable stream API
-// If the user uses them, then switch into old mode.
-Readable.prototype.resume = function() {
- emitDataEvents(this);
- this.read(0);
- this.emit('resume');
-};
-
-Readable.prototype.pause = function() {
- emitDataEvents(this, true);
- this.emit('pause');
-};
-
-function emitDataEvents(stream, startPaused) {
- var state = stream._readableState;
-
- if (state.flowing) {
- // https://github.com/isaacs/readable-stream/issues/16
- throw new Error('Cannot switch to old mode now.');
- }
-
- var paused = startPaused || false;
- var readable = false;
-
- // convert to an old-style stream.
- stream.readable = true;
- stream.pipe = Stream.prototype.pipe;
- stream.on = stream.addListener = Stream.prototype.on;
-
- stream.on('readable', function() {
- readable = true;
-
- var c;
- while (!paused && (null !== (c = stream.read())))
- stream.emit('data', c);
-
- if (c === null) {
- readable = false;
- stream._readableState.needReadable = true;
- }
- });
-
- stream.pause = function() {
- paused = true;
- this.emit('pause');
- };
-
- stream.resume = function() {
- paused = false;
- if (readable)
- process.nextTick(function() {
- stream.emit('readable');
- });
- else
- this.read(0);
- this.emit('resume');
- };
-
- // now make it start, just in case it hadn't already.
- stream.emit('readable');
-}
-
-// wrap an old-style stream as the async data source.
-// This is *not* part of the readable stream interface.
-// It is an ugly unfortunate mess of history.
-Readable.prototype.wrap = function(stream) {
- var state = this._readableState;
- var paused = false;
-
- var self = this;
- stream.on('end', function() {
- if (state.decoder && !state.ended) {
- var chunk = state.decoder.end();
- if (chunk && chunk.length)
- self.push(chunk);
- }
-
- self.push(null);
- });
-
- stream.on('data', function(chunk) {
- if (state.decoder)
- chunk = state.decoder.write(chunk);
-
- // don't skip over falsy values in objectMode
- //if (state.objectMode && util.isNullOrUndefined(chunk))
- if (state.objectMode && (chunk === null || chunk === undefined))
- return;
- else if (!state.objectMode && (!chunk || !chunk.length))
- return;
-
- var ret = self.push(chunk);
- if (!ret) {
- paused = true;
- stream.pause();
- }
- });
-
- // proxy all the other methods.
- // important when wrapping filters and duplexes.
- for (var i in stream) {
- if (typeof stream[i] === 'function' &&
- typeof this[i] === 'undefined') {
- this[i] = function(method) { return function() {
- return stream[method].apply(stream, arguments);
- }}(i);
- }
- }
-
- // proxy certain important events.
- var events = ['error', 'close', 'destroy', 'pause', 'resume'];
- forEach(events, function(ev) {
- stream.on(ev, self.emit.bind(self, ev));
- });
-
- // when we try to consume some more bytes, simply unpause the
- // underlying stream.
- self._read = function(n) {
- if (paused) {
- paused = false;
- stream.resume();
- }
- };
-
- return self;
-};
-
-
-
-// exposed for testing purposes only.
-Readable._fromList = fromList;
-
-// Pluck off n bytes from an array of buffers.
-// Length is the combined lengths of all the buffers in the list.
-function fromList(n, state) {
- var list = state.buffer;
- var length = state.length;
- var stringMode = !!state.decoder;
- var objectMode = !!state.objectMode;
- var ret;
-
- // nothing in the list, definitely empty.
- if (list.length === 0)
- return null;
-
- if (length === 0)
- ret = null;
- else if (objectMode)
- ret = list.shift();
- else if (!n || n >= length) {
- // read it all, truncate the array.
- if (stringMode)
- ret = list.join('');
- else
- ret = Buffer.concat(list, length);
- list.length = 0;
- } else {
- // read just some of it.
- if (n < list[0].length) {
- // just take a part of the first list item.
- // slice is the same for buffers and strings.
- var buf = list[0];
- ret = buf.slice(0, n);
- list[0] = buf.slice(n);
- } else if (n === list[0].length) {
- // first list is a perfect match
- ret = list.shift();
- } else {
- // complex case.
- // we have enough to cover it, but it spans past the first buffer.
- if (stringMode)
- ret = '';
- else
- ret = new Buffer(n);
-
- var c = 0;
- for (var i = 0, l = list.length; i < l && c < n; i++) {
- var buf = list[0];
- var cpy = Math.min(n - c, buf.length);
-
- if (stringMode)
- ret += buf.slice(0, cpy);
- else
- buf.copy(ret, c, 0, cpy);
-
- if (cpy < buf.length)
- list[0] = buf.slice(cpy);
- else
- list.shift();
-
- c += cpy;
- }
- }
- }
-
- return ret;
-}
-
-function endReadable(stream) {
- var state = stream._readableState;
-
- // If we get here before consuming all the bytes, then that is a
- // bug in node. Should never happen.
- if (state.length > 0)
- throw new Error('endReadable called on non-empty stream');
-
- if (!state.endEmitted && state.calledRead) {
- state.ended = true;
- process.nextTick(function() {
- // Check that we didn't get one last unshift.
- if (!state.endEmitted && state.length === 0) {
- state.endEmitted = true;
- stream.readable = false;
- stream.emit('end');
- }
- });
- }
-}
-
-function forEach (xs, f) {
- for (var i = 0, l = xs.length; i < l; i++) {
- f(xs[i], i);
- }
-}
-
-function indexOf (xs, x) {
- for (var i = 0, l = xs.length; i < l; i++) {
- if (xs[i] === x) return i;
- }
- return -1;
-}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/lib/_stream_transform.js nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/lib/_stream_transform.js
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/lib/_stream_transform.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/lib/_stream_transform.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,210 +0,0 @@
-// Copyright Joyent, Inc. and other Node contributors.
-//
-// Permission is hereby granted, free of charge, to any person obtaining a
-// copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to permit
-// persons to whom the Software is furnished to do so, subject to the
-// following conditions:
-//
-// The above copyright notice and this permission notice shall be included
-// in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
-// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
-// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
-// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
-// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
-// USE OR OTHER DEALINGS IN THE SOFTWARE.
-
-
-// a transform stream is a readable/writable stream where you do
-// something with the data. Sometimes it's called a "filter",
-// but that's not a great name for it, since that implies a thing where
-// some bits pass through, and others are simply ignored. (That would
-// be a valid example of a transform, of course.)
-//
-// While the output is causally related to the input, it's not a
-// necessarily symmetric or synchronous transformation. For example,
-// a zlib stream might take multiple plain-text writes(), and then
-// emit a single compressed chunk some time in the future.
-//
-// Here's how this works:
-//
-// The Transform stream has all the aspects of the readable and writable
-// stream classes. When you write(chunk), that calls _write(chunk,cb)
-// internally, and returns false if there's a lot of pending writes
-// buffered up. When you call read(), that calls _read(n) until
-// there's enough pending readable data buffered up.
-//
-// In a transform stream, the written data is placed in a buffer. When
-// _read(n) is called, it transforms the queued up data, calling the
-// buffered _write cb's as it consumes chunks. If consuming a single
-// written chunk would result in multiple output chunks, then the first
-// outputted bit calls the readcb, and subsequent chunks just go into
-// the read buffer, and will cause it to emit 'readable' if necessary.
-//
-// This way, back-pressure is actually determined by the reading side,
-// since _read has to be called to start processing a new chunk. However,
-// a pathological inflate type of transform can cause excessive buffering
-// here. For example, imagine a stream where every byte of input is
-// interpreted as an integer from 0-255, and then results in that many
-// bytes of output. Writing the 4 bytes {ff,ff,ff,ff} would result in
-// 1kb of data being output. In this case, you could write a very small
-// amount of input, and end up with a very large amount of output. In
-// such a pathological inflating mechanism, there'd be no way to tell
-// the system to stop doing the transform. A single 4MB write could
-// cause the system to run out of memory.
-//
-// However, even in such a pathological case, only a single written chunk
-// would be consumed, and then the rest would wait (un-transformed) until
-// the results of the previous transformed chunk were consumed.
-
-module.exports = Transform;
-
-var Duplex = require('./_stream_duplex');
-
-/**/
-var util = require('core-util-is');
-util.inherits = require('inherits');
-/* */
-
-util.inherits(Transform, Duplex);
-
-
-function TransformState(options, stream) {
- this.afterTransform = function(er, data) {
- return afterTransform(stream, er, data);
- };
-
- this.needTransform = false;
- this.transforming = false;
- this.writecb = null;
- this.writechunk = null;
-}
-
-function afterTransform(stream, er, data) {
- var ts = stream._transformState;
- ts.transforming = false;
-
- var cb = ts.writecb;
-
- if (!cb)
- return stream.emit('error', new Error('no writecb in Transform class'));
-
- ts.writechunk = null;
- ts.writecb = null;
-
- if (data !== null && data !== undefined)
- stream.push(data);
-
- if (cb)
- cb(er);
-
- var rs = stream._readableState;
- rs.reading = false;
- if (rs.needReadable || rs.length < rs.highWaterMark) {
- stream._read(rs.highWaterMark);
- }
-}
-
-
-function Transform(options) {
- if (!(this instanceof Transform))
- return new Transform(options);
-
- Duplex.call(this, options);
-
- var ts = this._transformState = new TransformState(options, this);
-
- // when the writable side finishes, then flush out anything remaining.
- var stream = this;
-
- // start out asking for a readable event once data is transformed.
- this._readableState.needReadable = true;
-
- // we have implemented the _read method, and done the other things
- // that Readable wants before the first _read call, so unset the
- // sync guard flag.
- this._readableState.sync = false;
-
- this.once('finish', function() {
- if ('function' === typeof this._flush)
- this._flush(function(er) {
- done(stream, er);
- });
- else
- done(stream);
- });
-}
-
-Transform.prototype.push = function(chunk, encoding) {
- this._transformState.needTransform = false;
- return Duplex.prototype.push.call(this, chunk, encoding);
-};
-
-// This is the part where you do stuff!
-// override this function in implementation classes.
-// 'chunk' is an input chunk.
-//
-// Call `push(newChunk)` to pass along transformed output
-// to the readable side. You may call 'push' zero or more times.
-//
-// Call `cb(err)` when you are done with this chunk. If you pass
-// an error, then that'll put the hurt on the whole operation. If you
-// never call cb(), then you'll never get another chunk.
-Transform.prototype._transform = function(chunk, encoding, cb) {
- throw new Error('not implemented');
-};
-
-Transform.prototype._write = function(chunk, encoding, cb) {
- var ts = this._transformState;
- ts.writecb = cb;
- ts.writechunk = chunk;
- ts.writeencoding = encoding;
- if (!ts.transforming) {
- var rs = this._readableState;
- if (ts.needTransform ||
- rs.needReadable ||
- rs.length < rs.highWaterMark)
- this._read(rs.highWaterMark);
- }
-};
-
-// Doesn't matter what the args are here.
-// _transform does all the work.
-// That we got here means that the readable side wants more data.
-Transform.prototype._read = function(n) {
- var ts = this._transformState;
-
- if (ts.writechunk !== null && ts.writecb && !ts.transforming) {
- ts.transforming = true;
- this._transform(ts.writechunk, ts.writeencoding, ts.afterTransform);
- } else {
- // mark that we need a transform, so that any data that comes in
- // will get processed, now that we've asked for it.
- ts.needTransform = true;
- }
-};
-
-
-function done(stream, er) {
- if (er)
- return stream.emit('error', er);
-
- // if there's nothing in the write buffer, then that means
- // that nothing more will ever be provided
- var ws = stream._writableState;
- var rs = stream._readableState;
- var ts = stream._transformState;
-
- if (ws.length)
- throw new Error('calling transform done when ws.length != 0');
-
- if (ts.transforming)
- throw new Error('calling transform done when still transforming');
-
- return stream.push(null);
-}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/lib/_stream_writable.js nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/lib/_stream_writable.js
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/lib/_stream_writable.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/lib/_stream_writable.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,386 +0,0 @@
-// Copyright Joyent, Inc. and other Node contributors.
-//
-// Permission is hereby granted, free of charge, to any person obtaining a
-// copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to permit
-// persons to whom the Software is furnished to do so, subject to the
-// following conditions:
-//
-// The above copyright notice and this permission notice shall be included
-// in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
-// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
-// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
-// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
-// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
-// USE OR OTHER DEALINGS IN THE SOFTWARE.
-
-// A bit simpler than readable streams.
-// Implement an async ._write(chunk, cb), and it'll handle all
-// the drain event emission and buffering.
-
-module.exports = Writable;
-
-/**/
-var Buffer = require('buffer').Buffer;
-/* */
-
-Writable.WritableState = WritableState;
-
-
-/**/
-var util = require('core-util-is');
-util.inherits = require('inherits');
-/* */
-
-var Stream = require('stream');
-
-util.inherits(Writable, Stream);
-
-function WriteReq(chunk, encoding, cb) {
- this.chunk = chunk;
- this.encoding = encoding;
- this.callback = cb;
-}
-
-function WritableState(options, stream) {
- options = options || {};
-
- // the point at which write() starts returning false
- // Note: 0 is a valid value, means that we always return false if
- // the entire buffer is not flushed immediately on write()
- var hwm = options.highWaterMark;
- this.highWaterMark = (hwm || hwm === 0) ? hwm : 16 * 1024;
-
- // object stream flag to indicate whether or not this stream
- // contains buffers or objects.
- this.objectMode = !!options.objectMode;
-
- // cast to ints.
- this.highWaterMark = ~~this.highWaterMark;
-
- this.needDrain = false;
- // at the start of calling end()
- this.ending = false;
- // when end() has been called, and returned
- this.ended = false;
- // when 'finish' is emitted
- this.finished = false;
-
- // should we decode strings into buffers before passing to _write?
- // this is here so that some node-core streams can optimize string
- // handling at a lower level.
- var noDecode = options.decodeStrings === false;
- this.decodeStrings = !noDecode;
-
- // Crypto is kind of old and crusty. Historically, its default string
- // encoding is 'binary' so we have to make this configurable.
- // Everything else in the universe uses 'utf8', though.
- this.defaultEncoding = options.defaultEncoding || 'utf8';
-
- // not an actual buffer we keep track of, but a measurement
- // of how much we're waiting to get pushed to some underlying
- // socket or file.
- this.length = 0;
-
- // a flag to see when we're in the middle of a write.
- this.writing = false;
-
- // a flag to be able to tell if the onwrite cb is called immediately,
- // or on a later tick. We set this to true at first, becuase any
- // actions that shouldn't happen until "later" should generally also
- // not happen before the first write call.
- this.sync = true;
-
- // a flag to know if we're processing previously buffered items, which
- // may call the _write() callback in the same tick, so that we don't
- // end up in an overlapped onwrite situation.
- this.bufferProcessing = false;
-
- // the callback that's passed to _write(chunk,cb)
- this.onwrite = function(er) {
- onwrite(stream, er);
- };
-
- // the callback that the user supplies to write(chunk,encoding,cb)
- this.writecb = null;
-
- // the amount that is being written when _write is called.
- this.writelen = 0;
-
- this.buffer = [];
-
- // True if the error was already emitted and should not be thrown again
- this.errorEmitted = false;
-}
-
-function Writable(options) {
- var Duplex = require('./_stream_duplex');
-
- // Writable ctor is applied to Duplexes, though they're not
- // instanceof Writable, they're instanceof Readable.
- if (!(this instanceof Writable) && !(this instanceof Duplex))
- return new Writable(options);
-
- this._writableState = new WritableState(options, this);
-
- // legacy.
- this.writable = true;
-
- Stream.call(this);
-}
-
-// Otherwise people can pipe Writable streams, which is just wrong.
-Writable.prototype.pipe = function() {
- this.emit('error', new Error('Cannot pipe. Not readable.'));
-};
-
-
-function writeAfterEnd(stream, state, cb) {
- var er = new Error('write after end');
- // TODO: defer error events consistently everywhere, not just the cb
- stream.emit('error', er);
- process.nextTick(function() {
- cb(er);
- });
-}
-
-// If we get something that is not a buffer, string, null, or undefined,
-// and we're not in objectMode, then that's an error.
-// Otherwise stream chunks are all considered to be of length=1, and the
-// watermarks determine how many objects to keep in the buffer, rather than
-// how many bytes or characters.
-function validChunk(stream, state, chunk, cb) {
- var valid = true;
- if (!Buffer.isBuffer(chunk) &&
- 'string' !== typeof chunk &&
- chunk !== null &&
- chunk !== undefined &&
- !state.objectMode) {
- var er = new TypeError('Invalid non-string/buffer chunk');
- stream.emit('error', er);
- process.nextTick(function() {
- cb(er);
- });
- valid = false;
- }
- return valid;
-}
-
-Writable.prototype.write = function(chunk, encoding, cb) {
- var state = this._writableState;
- var ret = false;
-
- if (typeof encoding === 'function') {
- cb = encoding;
- encoding = null;
- }
-
- if (Buffer.isBuffer(chunk))
- encoding = 'buffer';
- else if (!encoding)
- encoding = state.defaultEncoding;
-
- if (typeof cb !== 'function')
- cb = function() {};
-
- if (state.ended)
- writeAfterEnd(this, state, cb);
- else if (validChunk(this, state, chunk, cb))
- ret = writeOrBuffer(this, state, chunk, encoding, cb);
-
- return ret;
-};
-
-function decodeChunk(state, chunk, encoding) {
- if (!state.objectMode &&
- state.decodeStrings !== false &&
- typeof chunk === 'string') {
- chunk = new Buffer(chunk, encoding);
- }
- return chunk;
-}
-
-// if we're already writing something, then just put this
-// in the queue, and wait our turn. Otherwise, call _write
-// If we return false, then we need a drain event, so set that flag.
-function writeOrBuffer(stream, state, chunk, encoding, cb) {
- chunk = decodeChunk(state, chunk, encoding);
- if (Buffer.isBuffer(chunk))
- encoding = 'buffer';
- var len = state.objectMode ? 1 : chunk.length;
-
- state.length += len;
-
- var ret = state.length < state.highWaterMark;
- // we must ensure that previous needDrain will not be reset to false.
- if (!ret)
- state.needDrain = true;
-
- if (state.writing)
- state.buffer.push(new WriteReq(chunk, encoding, cb));
- else
- doWrite(stream, state, len, chunk, encoding, cb);
-
- return ret;
-}
-
-function doWrite(stream, state, len, chunk, encoding, cb) {
- state.writelen = len;
- state.writecb = cb;
- state.writing = true;
- state.sync = true;
- stream._write(chunk, encoding, state.onwrite);
- state.sync = false;
-}
-
-function onwriteError(stream, state, sync, er, cb) {
- if (sync)
- process.nextTick(function() {
- cb(er);
- });
- else
- cb(er);
-
- stream._writableState.errorEmitted = true;
- stream.emit('error', er);
-}
-
-function onwriteStateUpdate(state) {
- state.writing = false;
- state.writecb = null;
- state.length -= state.writelen;
- state.writelen = 0;
-}
-
-function onwrite(stream, er) {
- var state = stream._writableState;
- var sync = state.sync;
- var cb = state.writecb;
-
- onwriteStateUpdate(state);
-
- if (er)
- onwriteError(stream, state, sync, er, cb);
- else {
- // Check if we're actually ready to finish, but don't emit yet
- var finished = needFinish(stream, state);
-
- if (!finished && !state.bufferProcessing && state.buffer.length)
- clearBuffer(stream, state);
-
- if (sync) {
- process.nextTick(function() {
- afterWrite(stream, state, finished, cb);
- });
- } else {
- afterWrite(stream, state, finished, cb);
- }
- }
-}
-
-function afterWrite(stream, state, finished, cb) {
- if (!finished)
- onwriteDrain(stream, state);
- cb();
- if (finished)
- finishMaybe(stream, state);
-}
-
-// Must force callback to be called on nextTick, so that we don't
-// emit 'drain' before the write() consumer gets the 'false' return
-// value, and has a chance to attach a 'drain' listener.
-function onwriteDrain(stream, state) {
- if (state.length === 0 && state.needDrain) {
- state.needDrain = false;
- stream.emit('drain');
- }
-}
-
-
-// if there's something in the buffer waiting, then process it
-function clearBuffer(stream, state) {
- state.bufferProcessing = true;
-
- for (var c = 0; c < state.buffer.length; c++) {
- var entry = state.buffer[c];
- var chunk = entry.chunk;
- var encoding = entry.encoding;
- var cb = entry.callback;
- var len = state.objectMode ? 1 : chunk.length;
-
- doWrite(stream, state, len, chunk, encoding, cb);
-
- // if we didn't call the onwrite immediately, then
- // it means that we need to wait until it does.
- // also, that means that the chunk and cb are currently
- // being processed, so move the buffer counter past them.
- if (state.writing) {
- c++;
- break;
- }
- }
-
- state.bufferProcessing = false;
- if (c < state.buffer.length)
- state.buffer = state.buffer.slice(c);
- else
- state.buffer.length = 0;
-}
-
-Writable.prototype._write = function(chunk, encoding, cb) {
- cb(new Error('not implemented'));
-};
-
-Writable.prototype.end = function(chunk, encoding, cb) {
- var state = this._writableState;
-
- if (typeof chunk === 'function') {
- cb = chunk;
- chunk = null;
- encoding = null;
- } else if (typeof encoding === 'function') {
- cb = encoding;
- encoding = null;
- }
-
- if (typeof chunk !== 'undefined' && chunk !== null)
- this.write(chunk, encoding);
-
- // ignore unnecessary end() calls.
- if (!state.ending && !state.finished)
- endWritable(this, state, cb);
-};
-
-
-function needFinish(stream, state) {
- return (state.ending &&
- state.length === 0 &&
- !state.finished &&
- !state.writing);
-}
-
-function finishMaybe(stream, state) {
- var need = needFinish(stream, state);
- if (need) {
- state.finished = true;
- stream.emit('finish');
- }
- return need;
-}
-
-function endWritable(stream, state, cb) {
- state.ending = true;
- finishMaybe(stream, state);
- if (cb) {
- if (state.finished)
- process.nextTick(cb);
- else
- stream.once('finish', cb);
- }
- state.ended = true;
-}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/LICENSE nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/LICENSE
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/LICENSE 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/LICENSE 1970-01-01 00:00:00.000000000 +0000
@@ -1,27 +0,0 @@
-Copyright (c) Isaac Z. Schlueter ("Author")
-All rights reserved.
-
-The BSD License
-
-Redistribution and use in source and binary forms, with or without
-modification, are permitted provided that the following conditions
-are met:
-
-1. Redistributions of source code must retain the above copyright
- notice, this list of conditions and the following disclaimer.
-
-2. Redistributions in binary form must reproduce the above copyright
- notice, this list of conditions and the following disclaimer in the
- documentation and/or other materials provided with the distribution.
-
-THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
-PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS
-BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
-CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
-SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
-BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
-WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
-OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
-IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/core-util-is/float.patch nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/core-util-is/float.patch
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/core-util-is/float.patch 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/core-util-is/float.patch 1970-01-01 00:00:00.000000000 +0000
@@ -1,604 +0,0 @@
-diff --git a/lib/util.js b/lib/util.js
-index a03e874..9074e8e 100644
---- a/lib/util.js
-+++ b/lib/util.js
-@@ -19,430 +19,6 @@
- // OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
- // USE OR OTHER DEALINGS IN THE SOFTWARE.
-
--var formatRegExp = /%[sdj%]/g;
--exports.format = function(f) {
-- if (!isString(f)) {
-- var objects = [];
-- for (var i = 0; i < arguments.length; i++) {
-- objects.push(inspect(arguments[i]));
-- }
-- return objects.join(' ');
-- }
--
-- var i = 1;
-- var args = arguments;
-- var len = args.length;
-- var str = String(f).replace(formatRegExp, function(x) {
-- if (x === '%%') return '%';
-- if (i >= len) return x;
-- switch (x) {
-- case '%s': return String(args[i++]);
-- case '%d': return Number(args[i++]);
-- case '%j':
-- try {
-- return JSON.stringify(args[i++]);
-- } catch (_) {
-- return '[Circular]';
-- }
-- default:
-- return x;
-- }
-- });
-- for (var x = args[i]; i < len; x = args[++i]) {
-- if (isNull(x) || !isObject(x)) {
-- str += ' ' + x;
-- } else {
-- str += ' ' + inspect(x);
-- }
-- }
-- return str;
--};
--
--
--// Mark that a method should not be used.
--// Returns a modified function which warns once by default.
--// If --no-deprecation is set, then it is a no-op.
--exports.deprecate = function(fn, msg) {
-- // Allow for deprecating things in the process of starting up.
-- if (isUndefined(global.process)) {
-- return function() {
-- return exports.deprecate(fn, msg).apply(this, arguments);
-- };
-- }
--
-- if (process.noDeprecation === true) {
-- return fn;
-- }
--
-- var warned = false;
-- function deprecated() {
-- if (!warned) {
-- if (process.throwDeprecation) {
-- throw new Error(msg);
-- } else if (process.traceDeprecation) {
-- console.trace(msg);
-- } else {
-- console.error(msg);
-- }
-- warned = true;
-- }
-- return fn.apply(this, arguments);
-- }
--
-- return deprecated;
--};
--
--
--var debugs = {};
--var debugEnviron;
--exports.debuglog = function(set) {
-- if (isUndefined(debugEnviron))
-- debugEnviron = process.env.NODE_DEBUG || '';
-- set = set.toUpperCase();
-- if (!debugs[set]) {
-- if (new RegExp('\\b' + set + '\\b', 'i').test(debugEnviron)) {
-- var pid = process.pid;
-- debugs[set] = function() {
-- var msg = exports.format.apply(exports, arguments);
-- console.error('%s %d: %s', set, pid, msg);
-- };
-- } else {
-- debugs[set] = function() {};
-- }
-- }
-- return debugs[set];
--};
--
--
--/**
-- * Echos the value of a value. Trys to print the value out
-- * in the best way possible given the different types.
-- *
-- * @param {Object} obj The object to print out.
-- * @param {Object} opts Optional options object that alters the output.
-- */
--/* legacy: obj, showHidden, depth, colors*/
--function inspect(obj, opts) {
-- // default options
-- var ctx = {
-- seen: [],
-- stylize: stylizeNoColor
-- };
-- // legacy...
-- if (arguments.length >= 3) ctx.depth = arguments[2];
-- if (arguments.length >= 4) ctx.colors = arguments[3];
-- if (isBoolean(opts)) {
-- // legacy...
-- ctx.showHidden = opts;
-- } else if (opts) {
-- // got an "options" object
-- exports._extend(ctx, opts);
-- }
-- // set default options
-- if (isUndefined(ctx.showHidden)) ctx.showHidden = false;
-- if (isUndefined(ctx.depth)) ctx.depth = 2;
-- if (isUndefined(ctx.colors)) ctx.colors = false;
-- if (isUndefined(ctx.customInspect)) ctx.customInspect = true;
-- if (ctx.colors) ctx.stylize = stylizeWithColor;
-- return formatValue(ctx, obj, ctx.depth);
--}
--exports.inspect = inspect;
--
--
--// http://en.wikipedia.org/wiki/ANSI_escape_code#graphics
--inspect.colors = {
-- 'bold' : [1, 22],
-- 'italic' : [3, 23],
-- 'underline' : [4, 24],
-- 'inverse' : [7, 27],
-- 'white' : [37, 39],
-- 'grey' : [90, 39],
-- 'black' : [30, 39],
-- 'blue' : [34, 39],
-- 'cyan' : [36, 39],
-- 'green' : [32, 39],
-- 'magenta' : [35, 39],
-- 'red' : [31, 39],
-- 'yellow' : [33, 39]
--};
--
--// Don't use 'blue' not visible on cmd.exe
--inspect.styles = {
-- 'special': 'cyan',
-- 'number': 'yellow',
-- 'boolean': 'yellow',
-- 'undefined': 'grey',
-- 'null': 'bold',
-- 'string': 'green',
-- 'date': 'magenta',
-- // "name": intentionally not styling
-- 'regexp': 'red'
--};
--
--
--function stylizeWithColor(str, styleType) {
-- var style = inspect.styles[styleType];
--
-- if (style) {
-- return '\u001b[' + inspect.colors[style][0] + 'm' + str +
-- '\u001b[' + inspect.colors[style][1] + 'm';
-- } else {
-- return str;
-- }
--}
--
--
--function stylizeNoColor(str, styleType) {
-- return str;
--}
--
--
--function arrayToHash(array) {
-- var hash = {};
--
-- array.forEach(function(val, idx) {
-- hash[val] = true;
-- });
--
-- return hash;
--}
--
--
--function formatValue(ctx, value, recurseTimes) {
-- // Provide a hook for user-specified inspect functions.
-- // Check that value is an object with an inspect function on it
-- if (ctx.customInspect &&
-- value &&
-- isFunction(value.inspect) &&
-- // Filter out the util module, it's inspect function is special
-- value.inspect !== exports.inspect &&
-- // Also filter out any prototype objects using the circular check.
-- !(value.constructor && value.constructor.prototype === value)) {
-- var ret = value.inspect(recurseTimes, ctx);
-- if (!isString(ret)) {
-- ret = formatValue(ctx, ret, recurseTimes);
-- }
-- return ret;
-- }
--
-- // Primitive types cannot have properties
-- var primitive = formatPrimitive(ctx, value);
-- if (primitive) {
-- return primitive;
-- }
--
-- // Look up the keys of the object.
-- var keys = Object.keys(value);
-- var visibleKeys = arrayToHash(keys);
--
-- if (ctx.showHidden) {
-- keys = Object.getOwnPropertyNames(value);
-- }
--
-- // Some type of object without properties can be shortcutted.
-- if (keys.length === 0) {
-- if (isFunction(value)) {
-- var name = value.name ? ': ' + value.name : '';
-- return ctx.stylize('[Function' + name + ']', 'special');
-- }
-- if (isRegExp(value)) {
-- return ctx.stylize(RegExp.prototype.toString.call(value), 'regexp');
-- }
-- if (isDate(value)) {
-- return ctx.stylize(Date.prototype.toString.call(value), 'date');
-- }
-- if (isError(value)) {
-- return formatError(value);
-- }
-- }
--
-- var base = '', array = false, braces = ['{', '}'];
--
-- // Make Array say that they are Array
-- if (isArray(value)) {
-- array = true;
-- braces = ['[', ']'];
-- }
--
-- // Make functions say that they are functions
-- if (isFunction(value)) {
-- var n = value.name ? ': ' + value.name : '';
-- base = ' [Function' + n + ']';
-- }
--
-- // Make RegExps say that they are RegExps
-- if (isRegExp(value)) {
-- base = ' ' + RegExp.prototype.toString.call(value);
-- }
--
-- // Make dates with properties first say the date
-- if (isDate(value)) {
-- base = ' ' + Date.prototype.toUTCString.call(value);
-- }
--
-- // Make error with message first say the error
-- if (isError(value)) {
-- base = ' ' + formatError(value);
-- }
--
-- if (keys.length === 0 && (!array || value.length == 0)) {
-- return braces[0] + base + braces[1];
-- }
--
-- if (recurseTimes < 0) {
-- if (isRegExp(value)) {
-- return ctx.stylize(RegExp.prototype.toString.call(value), 'regexp');
-- } else {
-- return ctx.stylize('[Object]', 'special');
-- }
-- }
--
-- ctx.seen.push(value);
--
-- var output;
-- if (array) {
-- output = formatArray(ctx, value, recurseTimes, visibleKeys, keys);
-- } else {
-- output = keys.map(function(key) {
-- return formatProperty(ctx, value, recurseTimes, visibleKeys, key, array);
-- });
-- }
--
-- ctx.seen.pop();
--
-- return reduceToSingleString(output, base, braces);
--}
--
--
--function formatPrimitive(ctx, value) {
-- if (isUndefined(value))
-- return ctx.stylize('undefined', 'undefined');
-- if (isString(value)) {
-- var simple = '\'' + JSON.stringify(value).replace(/^"|"$/g, '')
-- .replace(/'/g, "\\'")
-- .replace(/\\"/g, '"') + '\'';
-- return ctx.stylize(simple, 'string');
-- }
-- if (isNumber(value)) {
-- // Format -0 as '-0'. Strict equality won't distinguish 0 from -0,
-- // so instead we use the fact that 1 / -0 < 0 whereas 1 / 0 > 0 .
-- if (value === 0 && 1 / value < 0)
-- return ctx.stylize('-0', 'number');
-- return ctx.stylize('' + value, 'number');
-- }
-- if (isBoolean(value))
-- return ctx.stylize('' + value, 'boolean');
-- // For some reason typeof null is "object", so special case here.
-- if (isNull(value))
-- return ctx.stylize('null', 'null');
--}
--
--
--function formatError(value) {
-- return '[' + Error.prototype.toString.call(value) + ']';
--}
--
--
--function formatArray(ctx, value, recurseTimes, visibleKeys, keys) {
-- var output = [];
-- for (var i = 0, l = value.length; i < l; ++i) {
-- if (hasOwnProperty(value, String(i))) {
-- output.push(formatProperty(ctx, value, recurseTimes, visibleKeys,
-- String(i), true));
-- } else {
-- output.push('');
-- }
-- }
-- keys.forEach(function(key) {
-- if (!key.match(/^\d+$/)) {
-- output.push(formatProperty(ctx, value, recurseTimes, visibleKeys,
-- key, true));
-- }
-- });
-- return output;
--}
--
--
--function formatProperty(ctx, value, recurseTimes, visibleKeys, key, array) {
-- var name, str, desc;
-- desc = Object.getOwnPropertyDescriptor(value, key) || { value: value[key] };
-- if (desc.get) {
-- if (desc.set) {
-- str = ctx.stylize('[Getter/Setter]', 'special');
-- } else {
-- str = ctx.stylize('[Getter]', 'special');
-- }
-- } else {
-- if (desc.set) {
-- str = ctx.stylize('[Setter]', 'special');
-- }
-- }
-- if (!hasOwnProperty(visibleKeys, key)) {
-- name = '[' + key + ']';
-- }
-- if (!str) {
-- if (ctx.seen.indexOf(desc.value) < 0) {
-- if (isNull(recurseTimes)) {
-- str = formatValue(ctx, desc.value, null);
-- } else {
-- str = formatValue(ctx, desc.value, recurseTimes - 1);
-- }
-- if (str.indexOf('\n') > -1) {
-- if (array) {
-- str = str.split('\n').map(function(line) {
-- return ' ' + line;
-- }).join('\n').substr(2);
-- } else {
-- str = '\n' + str.split('\n').map(function(line) {
-- return ' ' + line;
-- }).join('\n');
-- }
-- }
-- } else {
-- str = ctx.stylize('[Circular]', 'special');
-- }
-- }
-- if (isUndefined(name)) {
-- if (array && key.match(/^\d+$/)) {
-- return str;
-- }
-- name = JSON.stringify('' + key);
-- if (name.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)) {
-- name = name.substr(1, name.length - 2);
-- name = ctx.stylize(name, 'name');
-- } else {
-- name = name.replace(/'/g, "\\'")
-- .replace(/\\"/g, '"')
-- .replace(/(^"|"$)/g, "'");
-- name = ctx.stylize(name, 'string');
-- }
-- }
--
-- return name + ': ' + str;
--}
--
--
--function reduceToSingleString(output, base, braces) {
-- var numLinesEst = 0;
-- var length = output.reduce(function(prev, cur) {
-- numLinesEst++;
-- if (cur.indexOf('\n') >= 0) numLinesEst++;
-- return prev + cur.replace(/\u001b\[\d\d?m/g, '').length + 1;
-- }, 0);
--
-- if (length > 60) {
-- return braces[0] +
-- (base === '' ? '' : base + '\n ') +
-- ' ' +
-- output.join(',\n ') +
-- ' ' +
-- braces[1];
-- }
--
-- return braces[0] + base + ' ' + output.join(', ') + ' ' + braces[1];
--}
--
--
- // NOTE: These type checking functions intentionally don't use `instanceof`
- // because it is fragile and can be easily faked with `Object.create()`.
- function isArray(ar) {
-@@ -522,166 +98,10 @@ function isPrimitive(arg) {
- exports.isPrimitive = isPrimitive;
-
- function isBuffer(arg) {
-- return arg instanceof Buffer;
-+ return Buffer.isBuffer(arg);
- }
- exports.isBuffer = isBuffer;
-
- function objectToString(o) {
- return Object.prototype.toString.call(o);
--}
--
--
--function pad(n) {
-- return n < 10 ? '0' + n.toString(10) : n.toString(10);
--}
--
--
--var months = ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep',
-- 'Oct', 'Nov', 'Dec'];
--
--// 26 Feb 16:19:34
--function timestamp() {
-- var d = new Date();
-- var time = [pad(d.getHours()),
-- pad(d.getMinutes()),
-- pad(d.getSeconds())].join(':');
-- return [d.getDate(), months[d.getMonth()], time].join(' ');
--}
--
--
--// log is just a thin wrapper to console.log that prepends a timestamp
--exports.log = function() {
-- console.log('%s - %s', timestamp(), exports.format.apply(exports, arguments));
--};
--
--
--/**
-- * Inherit the prototype methods from one constructor into another.
-- *
-- * The Function.prototype.inherits from lang.js rewritten as a standalone
-- * function (not on Function.prototype). NOTE: If this file is to be loaded
-- * during bootstrapping this function needs to be rewritten using some native
-- * functions as prototype setup using normal JavaScript does not work as
-- * expected during bootstrapping (see mirror.js in r114903).
-- *
-- * @param {function} ctor Constructor function which needs to inherit the
-- * prototype.
-- * @param {function} superCtor Constructor function to inherit prototype from.
-- */
--exports.inherits = function(ctor, superCtor) {
-- ctor.super_ = superCtor;
-- ctor.prototype = Object.create(superCtor.prototype, {
-- constructor: {
-- value: ctor,
-- enumerable: false,
-- writable: true,
-- configurable: true
-- }
-- });
--};
--
--exports._extend = function(origin, add) {
-- // Don't do anything if add isn't an object
-- if (!add || !isObject(add)) return origin;
--
-- var keys = Object.keys(add);
-- var i = keys.length;
-- while (i--) {
-- origin[keys[i]] = add[keys[i]];
-- }
-- return origin;
--};
--
--function hasOwnProperty(obj, prop) {
-- return Object.prototype.hasOwnProperty.call(obj, prop);
--}
--
--
--// Deprecated old stuff.
--
--exports.p = exports.deprecate(function() {
-- for (var i = 0, len = arguments.length; i < len; ++i) {
-- console.error(exports.inspect(arguments[i]));
-- }
--}, 'util.p: Use console.error() instead');
--
--
--exports.exec = exports.deprecate(function() {
-- return require('child_process').exec.apply(this, arguments);
--}, 'util.exec is now called `child_process.exec`.');
--
--
--exports.print = exports.deprecate(function() {
-- for (var i = 0, len = arguments.length; i < len; ++i) {
-- process.stdout.write(String(arguments[i]));
-- }
--}, 'util.print: Use console.log instead');
--
--
--exports.puts = exports.deprecate(function() {
-- for (var i = 0, len = arguments.length; i < len; ++i) {
-- process.stdout.write(arguments[i] + '\n');
-- }
--}, 'util.puts: Use console.log instead');
--
--
--exports.debug = exports.deprecate(function(x) {
-- process.stderr.write('DEBUG: ' + x + '\n');
--}, 'util.debug: Use console.error instead');
--
--
--exports.error = exports.deprecate(function(x) {
-- for (var i = 0, len = arguments.length; i < len; ++i) {
-- process.stderr.write(arguments[i] + '\n');
-- }
--}, 'util.error: Use console.error instead');
--
--
--exports.pump = exports.deprecate(function(readStream, writeStream, callback) {
-- var callbackCalled = false;
--
-- function call(a, b, c) {
-- if (callback && !callbackCalled) {
-- callback(a, b, c);
-- callbackCalled = true;
-- }
-- }
--
-- readStream.addListener('data', function(chunk) {
-- if (writeStream.write(chunk) === false) readStream.pause();
-- });
--
-- writeStream.addListener('drain', function() {
-- readStream.resume();
-- });
--
-- readStream.addListener('end', function() {
-- writeStream.end();
-- });
--
-- readStream.addListener('close', function() {
-- call();
-- });
--
-- readStream.addListener('error', function(err) {
-- writeStream.end();
-- call(err);
-- });
--
-- writeStream.addListener('error', function(err) {
-- readStream.destroy();
-- call(err);
-- });
--}, 'util.pump(): Use readableStream.pipe() instead');
--
--
--var uv;
--exports._errnoException = function(err, syscall) {
-- if (isUndefined(uv)) uv = process.binding('uv');
-- var errname = uv.errname(err);
-- var e = new Error(syscall + ' ' + errname);
-- e.code = errname;
-- e.errno = errname;
-- e.syscall = syscall;
-- return e;
--};
-+}
\ No newline at end of file
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/core-util-is/lib/util.js nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/core-util-is/lib/util.js
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/core-util-is/lib/util.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/core-util-is/lib/util.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,107 +0,0 @@
-// Copyright Joyent, Inc. and other Node contributors.
-//
-// Permission is hereby granted, free of charge, to any person obtaining a
-// copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to permit
-// persons to whom the Software is furnished to do so, subject to the
-// following conditions:
-//
-// The above copyright notice and this permission notice shall be included
-// in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
-// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
-// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
-// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
-// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
-// USE OR OTHER DEALINGS IN THE SOFTWARE.
-
-// NOTE: These type checking functions intentionally don't use `instanceof`
-// because it is fragile and can be easily faked with `Object.create()`.
-function isArray(ar) {
- return Array.isArray(ar);
-}
-exports.isArray = isArray;
-
-function isBoolean(arg) {
- return typeof arg === 'boolean';
-}
-exports.isBoolean = isBoolean;
-
-function isNull(arg) {
- return arg === null;
-}
-exports.isNull = isNull;
-
-function isNullOrUndefined(arg) {
- return arg == null;
-}
-exports.isNullOrUndefined = isNullOrUndefined;
-
-function isNumber(arg) {
- return typeof arg === 'number';
-}
-exports.isNumber = isNumber;
-
-function isString(arg) {
- return typeof arg === 'string';
-}
-exports.isString = isString;
-
-function isSymbol(arg) {
- return typeof arg === 'symbol';
-}
-exports.isSymbol = isSymbol;
-
-function isUndefined(arg) {
- return arg === void 0;
-}
-exports.isUndefined = isUndefined;
-
-function isRegExp(re) {
- return isObject(re) && objectToString(re) === '[object RegExp]';
-}
-exports.isRegExp = isRegExp;
-
-function isObject(arg) {
- return typeof arg === 'object' && arg !== null;
-}
-exports.isObject = isObject;
-
-function isDate(d) {
- return isObject(d) && objectToString(d) === '[object Date]';
-}
-exports.isDate = isDate;
-
-function isError(e) {
- return isObject(e) &&
- (objectToString(e) === '[object Error]' || e instanceof Error);
-}
-exports.isError = isError;
-
-function isFunction(arg) {
- return typeof arg === 'function';
-}
-exports.isFunction = isFunction;
-
-function isPrimitive(arg) {
- return arg === null ||
- typeof arg === 'boolean' ||
- typeof arg === 'number' ||
- typeof arg === 'string' ||
- typeof arg === 'symbol' || // ES6 symbol
- typeof arg === 'undefined';
-}
-exports.isPrimitive = isPrimitive;
-
-function isBuffer(arg) {
- return Buffer.isBuffer(arg);
-}
-exports.isBuffer = isBuffer;
-
-function objectToString(o) {
- return Object.prototype.toString.call(o);
-}
\ No newline at end of file
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/core-util-is/package.json nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/core-util-is/package.json
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/core-util-is/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/core-util-is/package.json 1970-01-01 00:00:00.000000000 +0000
@@ -1,53 +0,0 @@
-{
- "name": "core-util-is",
- "version": "1.0.1",
- "description": "The `util.is*` functions introduced in Node v0.12.",
- "main": "lib/util.js",
- "repository": {
- "type": "git",
- "url": "git://github.com/isaacs/core-util-is"
- },
- "keywords": [
- "util",
- "isBuffer",
- "isArray",
- "isNumber",
- "isString",
- "isRegExp",
- "isThis",
- "isThat",
- "polyfill"
- ],
- "author": {
- "name": "Isaac Z. Schlueter",
- "email": "i@izs.me",
- "url": "http://blog.izs.me/"
- },
- "license": "MIT",
- "bugs": {
- "url": "https://github.com/isaacs/core-util-is/issues"
- },
- "readme": "# core-util-is\n\nThe `util.is*` functions introduced in Node v0.12.\n",
- "readmeFilename": "README.md",
- "homepage": "https://github.com/isaacs/core-util-is",
- "_id": "core-util-is@1.0.1",
- "dist": {
- "shasum": "6b07085aef9a3ccac6ee53bf9d3df0c1521a5538",
- "tarball": "http://registry.npmjs.org/core-util-is/-/core-util-is-1.0.1.tgz"
- },
- "_from": "core-util-is@>=1.0.0-0 <1.1.0-0",
- "_npmVersion": "1.3.23",
- "_npmUser": {
- "name": "isaacs",
- "email": "i@izs.me"
- },
- "maintainers": [
- {
- "name": "isaacs",
- "email": "i@izs.me"
- }
- ],
- "directories": {},
- "_shasum": "6b07085aef9a3ccac6ee53bf9d3df0c1521a5538",
- "_resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.1.tgz"
-}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/core-util-is/README.md nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/core-util-is/README.md
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/core-util-is/README.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/core-util-is/README.md 1970-01-01 00:00:00.000000000 +0000
@@ -1,3 +0,0 @@
-# core-util-is
-
-The `util.is*` functions introduced in Node v0.12.
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/core-util-is/util.js nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/core-util-is/util.js
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/core-util-is/util.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/core-util-is/util.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,106 +0,0 @@
-// Copyright Joyent, Inc. and other Node contributors.
-//
-// Permission is hereby granted, free of charge, to any person obtaining a
-// copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to permit
-// persons to whom the Software is furnished to do so, subject to the
-// following conditions:
-//
-// The above copyright notice and this permission notice shall be included
-// in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
-// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
-// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
-// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
-// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
-// USE OR OTHER DEALINGS IN THE SOFTWARE.
-
-// NOTE: These type checking functions intentionally don't use `instanceof`
-// because it is fragile and can be easily faked with `Object.create()`.
-function isArray(ar) {
- return Array.isArray(ar);
-}
-exports.isArray = isArray;
-
-function isBoolean(arg) {
- return typeof arg === 'boolean';
-}
-exports.isBoolean = isBoolean;
-
-function isNull(arg) {
- return arg === null;
-}
-exports.isNull = isNull;
-
-function isNullOrUndefined(arg) {
- return arg == null;
-}
-exports.isNullOrUndefined = isNullOrUndefined;
-
-function isNumber(arg) {
- return typeof arg === 'number';
-}
-exports.isNumber = isNumber;
-
-function isString(arg) {
- return typeof arg === 'string';
-}
-exports.isString = isString;
-
-function isSymbol(arg) {
- return typeof arg === 'symbol';
-}
-exports.isSymbol = isSymbol;
-
-function isUndefined(arg) {
- return arg === void 0;
-}
-exports.isUndefined = isUndefined;
-
-function isRegExp(re) {
- return isObject(re) && objectToString(re) === '[object RegExp]';
-}
-exports.isRegExp = isRegExp;
-
-function isObject(arg) {
- return typeof arg === 'object' && arg !== null;
-}
-exports.isObject = isObject;
-
-function isDate(d) {
- return isObject(d) && objectToString(d) === '[object Date]';
-}
-exports.isDate = isDate;
-
-function isError(e) {
- return isObject(e) && objectToString(e) === '[object Error]';
-}
-exports.isError = isError;
-
-function isFunction(arg) {
- return typeof arg === 'function';
-}
-exports.isFunction = isFunction;
-
-function isPrimitive(arg) {
- return arg === null ||
- typeof arg === 'boolean' ||
- typeof arg === 'number' ||
- typeof arg === 'string' ||
- typeof arg === 'symbol' || // ES6 symbol
- typeof arg === 'undefined';
-}
-exports.isPrimitive = isPrimitive;
-
-function isBuffer(arg) {
- return arg instanceof Buffer;
-}
-exports.isBuffer = isBuffer;
-
-function objectToString(o) {
- return Object.prototype.toString.call(o);
-}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/isarray/build/build.js nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/isarray/build/build.js
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/isarray/build/build.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/isarray/build/build.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,209 +0,0 @@
-
-/**
- * Require the given path.
- *
- * @param {String} path
- * @return {Object} exports
- * @api public
- */
-
-function require(path, parent, orig) {
- var resolved = require.resolve(path);
-
- // lookup failed
- if (null == resolved) {
- orig = orig || path;
- parent = parent || 'root';
- var err = new Error('Failed to require "' + orig + '" from "' + parent + '"');
- err.path = orig;
- err.parent = parent;
- err.require = true;
- throw err;
- }
-
- var module = require.modules[resolved];
-
- // perform real require()
- // by invoking the module's
- // registered function
- if (!module.exports) {
- module.exports = {};
- module.client = module.component = true;
- module.call(this, module.exports, require.relative(resolved), module);
- }
-
- return module.exports;
-}
-
-/**
- * Registered modules.
- */
-
-require.modules = {};
-
-/**
- * Registered aliases.
- */
-
-require.aliases = {};
-
-/**
- * Resolve `path`.
- *
- * Lookup:
- *
- * - PATH/index.js
- * - PATH.js
- * - PATH
- *
- * @param {String} path
- * @return {String} path or null
- * @api private
- */
-
-require.resolve = function(path) {
- if (path.charAt(0) === '/') path = path.slice(1);
- var index = path + '/index.js';
-
- var paths = [
- path,
- path + '.js',
- path + '.json',
- path + '/index.js',
- path + '/index.json'
- ];
-
- for (var i = 0; i < paths.length; i++) {
- var path = paths[i];
- if (require.modules.hasOwnProperty(path)) return path;
- }
-
- if (require.aliases.hasOwnProperty(index)) {
- return require.aliases[index];
- }
-};
-
-/**
- * Normalize `path` relative to the current path.
- *
- * @param {String} curr
- * @param {String} path
- * @return {String}
- * @api private
- */
-
-require.normalize = function(curr, path) {
- var segs = [];
-
- if ('.' != path.charAt(0)) return path;
-
- curr = curr.split('/');
- path = path.split('/');
-
- for (var i = 0; i < path.length; ++i) {
- if ('..' == path[i]) {
- curr.pop();
- } else if ('.' != path[i] && '' != path[i]) {
- segs.push(path[i]);
- }
- }
-
- return curr.concat(segs).join('/');
-};
-
-/**
- * Register module at `path` with callback `definition`.
- *
- * @param {String} path
- * @param {Function} definition
- * @api private
- */
-
-require.register = function(path, definition) {
- require.modules[path] = definition;
-};
-
-/**
- * Alias a module definition.
- *
- * @param {String} from
- * @param {String} to
- * @api private
- */
-
-require.alias = function(from, to) {
- if (!require.modules.hasOwnProperty(from)) {
- throw new Error('Failed to alias "' + from + '", it does not exist');
- }
- require.aliases[to] = from;
-};
-
-/**
- * Return a require function relative to the `parent` path.
- *
- * @param {String} parent
- * @return {Function}
- * @api private
- */
-
-require.relative = function(parent) {
- var p = require.normalize(parent, '..');
-
- /**
- * lastIndexOf helper.
- */
-
- function lastIndexOf(arr, obj) {
- var i = arr.length;
- while (i--) {
- if (arr[i] === obj) return i;
- }
- return -1;
- }
-
- /**
- * The relative require() itself.
- */
-
- function localRequire(path) {
- var resolved = localRequire.resolve(path);
- return require(resolved, parent, path);
- }
-
- /**
- * Resolve relative to the parent.
- */
-
- localRequire.resolve = function(path) {
- var c = path.charAt(0);
- if ('/' == c) return path.slice(1);
- if ('.' == c) return require.normalize(p, path);
-
- // resolve deps by returning
- // the dep in the nearest "deps"
- // directory
- var segs = parent.split('/');
- var i = lastIndexOf(segs, 'deps') + 1;
- if (!i) i = 0;
- path = segs.slice(0, i + 1).join('/') + '/deps/' + path;
- return path;
- };
-
- /**
- * Check if module is defined at `path`.
- */
-
- localRequire.exists = function(path) {
- return require.modules.hasOwnProperty(localRequire.resolve(path));
- };
-
- return localRequire;
-};
-require.register("isarray/index.js", function(exports, require, module){
-module.exports = Array.isArray || function (arr) {
- return Object.prototype.toString.call(arr) == '[object Array]';
-};
-
-});
-require.alias("isarray/index.js", "isarray/index.js");
-
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/isarray/component.json nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/isarray/component.json
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/isarray/component.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/isarray/component.json 1970-01-01 00:00:00.000000000 +0000
@@ -1,19 +0,0 @@
-{
- "name" : "isarray",
- "description" : "Array#isArray for older browsers",
- "version" : "0.0.1",
- "repository" : "juliangruber/isarray",
- "homepage": "https://github.com/juliangruber/isarray",
- "main" : "index.js",
- "scripts" : [
- "index.js"
- ],
- "dependencies" : {},
- "keywords": ["browser","isarray","array"],
- "author": {
- "name": "Julian Gruber",
- "email": "mail@juliangruber.com",
- "url": "http://juliangruber.com"
- },
- "license": "MIT"
-}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/isarray/index.js nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/isarray/index.js
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/isarray/index.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/isarray/index.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,3 +0,0 @@
-module.exports = Array.isArray || function (arr) {
- return Object.prototype.toString.call(arr) == '[object Array]';
-};
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/isarray/package.json nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/isarray/package.json
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/isarray/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/isarray/package.json 1970-01-01 00:00:00.000000000 +0000
@@ -1,54 +0,0 @@
-{
- "name": "isarray",
- "description": "Array#isArray for older browsers",
- "version": "0.0.1",
- "repository": {
- "type": "git",
- "url": "git://github.com/juliangruber/isarray.git"
- },
- "homepage": "https://github.com/juliangruber/isarray",
- "main": "index.js",
- "scripts": {
- "test": "tap test/*.js"
- },
- "dependencies": {},
- "devDependencies": {
- "tap": "*"
- },
- "keywords": [
- "browser",
- "isarray",
- "array"
- ],
- "author": {
- "name": "Julian Gruber",
- "email": "mail@juliangruber.com",
- "url": "http://juliangruber.com"
- },
- "license": "MIT",
- "readme": "\n# isarray\n\n`Array#isArray` for older browsers.\n\n## Usage\n\n```js\nvar isArray = require('isarray');\n\nconsole.log(isArray([])); // => true\nconsole.log(isArray({})); // => false\n```\n\n## Installation\n\nWith [npm](http://npmjs.org) do\n\n```bash\n$ npm install isarray\n```\n\nThen bundle for the browser with\n[browserify](https://github.com/substack/browserify).\n\nWith [component](http://component.io) do\n\n```bash\n$ component install juliangruber/isarray\n```\n\n## License\n\n(MIT)\n\nCopyright (c) 2013 Julian Gruber <julian@juliangruber.com>\n\nPermission is hereby granted, free of charge, to any person obtaining a copy of\nthis software and associated documentation files (the \"Software\"), to deal in\nthe Software without restriction, including without limitation the rights to\nuse, copy, modify, merge, publish, distribute, sublicense, and/or sell copies\nof the Software, and to permit persons to whom the Software is furnished to do\nso, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.\n",
- "readmeFilename": "README.md",
- "_id": "isarray@0.0.1",
- "dist": {
- "shasum": "8a18acfca9a8f4177e09abfc6038939b05d1eedf",
- "tarball": "http://registry.npmjs.org/isarray/-/isarray-0.0.1.tgz"
- },
- "_from": "isarray@0.0.1",
- "_npmVersion": "1.2.18",
- "_npmUser": {
- "name": "juliangruber",
- "email": "julian@juliangruber.com"
- },
- "maintainers": [
- {
- "name": "juliangruber",
- "email": "julian@juliangruber.com"
- }
- ],
- "directories": {},
- "_shasum": "8a18acfca9a8f4177e09abfc6038939b05d1eedf",
- "_resolved": "https://registry.npmjs.org/isarray/-/isarray-0.0.1.tgz",
- "bugs": {
- "url": "https://github.com/juliangruber/isarray/issues"
- }
-}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/isarray/README.md nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/isarray/README.md
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/isarray/README.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/isarray/README.md 1970-01-01 00:00:00.000000000 +0000
@@ -1,54 +0,0 @@
-
-# isarray
-
-`Array#isArray` for older browsers.
-
-## Usage
-
-```js
-var isArray = require('isarray');
-
-console.log(isArray([])); // => true
-console.log(isArray({})); // => false
-```
-
-## Installation
-
-With [npm](http://npmjs.org) do
-
-```bash
-$ npm install isarray
-```
-
-Then bundle for the browser with
-[browserify](https://github.com/substack/browserify).
-
-With [component](http://component.io) do
-
-```bash
-$ component install juliangruber/isarray
-```
-
-## License
-
-(MIT)
-
-Copyright (c) 2013 Julian Gruber <julian@juliangruber.com>
-
-Permission is hereby granted, free of charge, to any person obtaining a copy of
-this software and associated documentation files (the "Software"), to deal in
-the Software without restriction, including without limitation the rights to
-use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
-of the Software, and to permit persons to whom the Software is furnished to do
-so, subject to the following conditions:
-
-The above copyright notice and this permission notice shall be included in all
-copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
-SOFTWARE.
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/string_decoder/index.js nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/string_decoder/index.js
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/string_decoder/index.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/string_decoder/index.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,221 +0,0 @@
-// Copyright Joyent, Inc. and other Node contributors.
-//
-// Permission is hereby granted, free of charge, to any person obtaining a
-// copy of this software and associated documentation files (the
-// "Software"), to deal in the Software without restriction, including
-// without limitation the rights to use, copy, modify, merge, publish,
-// distribute, sublicense, and/or sell copies of the Software, and to permit
-// persons to whom the Software is furnished to do so, subject to the
-// following conditions:
-//
-// The above copyright notice and this permission notice shall be included
-// in all copies or substantial portions of the Software.
-//
-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
-// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
-// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
-// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
-// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
-// USE OR OTHER DEALINGS IN THE SOFTWARE.
-
-var Buffer = require('buffer').Buffer;
-
-var isBufferEncoding = Buffer.isEncoding
- || function(encoding) {
- switch (encoding && encoding.toLowerCase()) {
- case 'hex': case 'utf8': case 'utf-8': case 'ascii': case 'binary': case 'base64': case 'ucs2': case 'ucs-2': case 'utf16le': case 'utf-16le': case 'raw': return true;
- default: return false;
- }
- }
-
-
-function assertEncoding(encoding) {
- if (encoding && !isBufferEncoding(encoding)) {
- throw new Error('Unknown encoding: ' + encoding);
- }
-}
-
-// StringDecoder provides an interface for efficiently splitting a series of
-// buffers into a series of JS strings without breaking apart multi-byte
-// characters. CESU-8 is handled as part of the UTF-8 encoding.
-//
-// @TODO Handling all encodings inside a single object makes it very difficult
-// to reason about this code, so it should be split up in the future.
-// @TODO There should be a utf8-strict encoding that rejects invalid UTF-8 code
-// points as used by CESU-8.
-var StringDecoder = exports.StringDecoder = function(encoding) {
- this.encoding = (encoding || 'utf8').toLowerCase().replace(/[-_]/, '');
- assertEncoding(encoding);
- switch (this.encoding) {
- case 'utf8':
- // CESU-8 represents each of Surrogate Pair by 3-bytes
- this.surrogateSize = 3;
- break;
- case 'ucs2':
- case 'utf16le':
- // UTF-16 represents each of Surrogate Pair by 2-bytes
- this.surrogateSize = 2;
- this.detectIncompleteChar = utf16DetectIncompleteChar;
- break;
- case 'base64':
- // Base-64 stores 3 bytes in 4 chars, and pads the remainder.
- this.surrogateSize = 3;
- this.detectIncompleteChar = base64DetectIncompleteChar;
- break;
- default:
- this.write = passThroughWrite;
- return;
- }
-
- // Enough space to store all bytes of a single character. UTF-8 needs 4
- // bytes, but CESU-8 may require up to 6 (3 bytes per surrogate).
- this.charBuffer = new Buffer(6);
- // Number of bytes received for the current incomplete multi-byte character.
- this.charReceived = 0;
- // Number of bytes expected for the current incomplete multi-byte character.
- this.charLength = 0;
-};
-
-
-// write decodes the given buffer and returns it as JS string that is
-// guaranteed to not contain any partial multi-byte characters. Any partial
-// character found at the end of the buffer is buffered up, and will be
-// returned when calling write again with the remaining bytes.
-//
-// Note: Converting a Buffer containing an orphan surrogate to a String
-// currently works, but converting a String to a Buffer (via `new Buffer`, or
-// Buffer#write) will replace incomplete surrogates with the unicode
-// replacement character. See https://codereview.chromium.org/121173009/ .
-StringDecoder.prototype.write = function(buffer) {
- var charStr = '';
- // if our last write ended with an incomplete multibyte character
- while (this.charLength) {
- // determine how many remaining bytes this buffer has to offer for this char
- var available = (buffer.length >= this.charLength - this.charReceived) ?
- this.charLength - this.charReceived :
- buffer.length;
-
- // add the new bytes to the char buffer
- buffer.copy(this.charBuffer, this.charReceived, 0, available);
- this.charReceived += available;
-
- if (this.charReceived < this.charLength) {
- // still not enough chars in this buffer? wait for more ...
- return '';
- }
-
- // remove bytes belonging to the current character from the buffer
- buffer = buffer.slice(available, buffer.length);
-
- // get the character that was split
- charStr = this.charBuffer.slice(0, this.charLength).toString(this.encoding);
-
- // CESU-8: lead surrogate (D800-DBFF) is also the incomplete character
- var charCode = charStr.charCodeAt(charStr.length - 1);
- if (charCode >= 0xD800 && charCode <= 0xDBFF) {
- this.charLength += this.surrogateSize;
- charStr = '';
- continue;
- }
- this.charReceived = this.charLength = 0;
-
- // if there are no more bytes in this buffer, just emit our char
- if (buffer.length === 0) {
- return charStr;
- }
- break;
- }
-
- // determine and set charLength / charReceived
- this.detectIncompleteChar(buffer);
-
- var end = buffer.length;
- if (this.charLength) {
- // buffer the incomplete character bytes we got
- buffer.copy(this.charBuffer, 0, buffer.length - this.charReceived, end);
- end -= this.charReceived;
- }
-
- charStr += buffer.toString(this.encoding, 0, end);
-
- var end = charStr.length - 1;
- var charCode = charStr.charCodeAt(end);
- // CESU-8: lead surrogate (D800-DBFF) is also the incomplete character
- if (charCode >= 0xD800 && charCode <= 0xDBFF) {
- var size = this.surrogateSize;
- this.charLength += size;
- this.charReceived += size;
- this.charBuffer.copy(this.charBuffer, size, 0, size);
- buffer.copy(this.charBuffer, 0, 0, size);
- return charStr.substring(0, end);
- }
-
- // or just emit the charStr
- return charStr;
-};
-
-// detectIncompleteChar determines if there is an incomplete UTF-8 character at
-// the end of the given buffer. If so, it sets this.charLength to the byte
-// length that character, and sets this.charReceived to the number of bytes
-// that are available for this character.
-StringDecoder.prototype.detectIncompleteChar = function(buffer) {
- // determine how many bytes we have to check at the end of this buffer
- var i = (buffer.length >= 3) ? 3 : buffer.length;
-
- // Figure out if one of the last i bytes of our buffer announces an
- // incomplete char.
- for (; i > 0; i--) {
- var c = buffer[buffer.length - i];
-
- // See http://en.wikipedia.org/wiki/UTF-8#Description
-
- // 110XXXXX
- if (i == 1 && c >> 5 == 0x06) {
- this.charLength = 2;
- break;
- }
-
- // 1110XXXX
- if (i <= 2 && c >> 4 == 0x0E) {
- this.charLength = 3;
- break;
- }
-
- // 11110XXX
- if (i <= 3 && c >> 3 == 0x1E) {
- this.charLength = 4;
- break;
- }
- }
- this.charReceived = i;
-};
-
-StringDecoder.prototype.end = function(buffer) {
- var res = '';
- if (buffer && buffer.length)
- res = this.write(buffer);
-
- if (this.charReceived) {
- var cr = this.charReceived;
- var buf = this.charBuffer;
- var enc = this.encoding;
- res += buf.slice(0, cr).toString(enc);
- }
-
- return res;
-};
-
-function passThroughWrite(buffer) {
- return buffer.toString(this.encoding);
-}
-
-function utf16DetectIncompleteChar(buffer) {
- this.charReceived = buffer.length % 2;
- this.charLength = this.charReceived ? 2 : 0;
-}
-
-function base64DetectIncompleteChar(buffer) {
- this.charReceived = buffer.length % 3;
- this.charLength = this.charReceived ? 3 : 0;
-}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/string_decoder/LICENSE nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/string_decoder/LICENSE
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/string_decoder/LICENSE 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/string_decoder/LICENSE 1970-01-01 00:00:00.000000000 +0000
@@ -1,20 +0,0 @@
-Copyright Joyent, Inc. and other Node contributors.
-
-Permission is hereby granted, free of charge, to any person obtaining a
-copy of this software and associated documentation files (the
-"Software"), to deal in the Software without restriction, including
-without limitation the rights to use, copy, modify, merge, publish,
-distribute, sublicense, and/or sell copies of the Software, and to permit
-persons to whom the Software is furnished to do so, subject to the
-following conditions:
-
-The above copyright notice and this permission notice shall be included
-in all copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
-OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
-NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
-DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
-OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
-USE OR OTHER DEALINGS IN THE SOFTWARE.
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/string_decoder/.npmignore nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/string_decoder/.npmignore
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/string_decoder/.npmignore 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/string_decoder/.npmignore 1970-01-01 00:00:00.000000000 +0000
@@ -1,2 +0,0 @@
-build
-test
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/string_decoder/package.json nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/string_decoder/package.json
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/string_decoder/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/string_decoder/package.json 1970-01-01 00:00:00.000000000 +0000
@@ -1,54 +0,0 @@
-{
- "name": "string_decoder",
- "version": "0.10.31",
- "description": "The string_decoder module from Node core",
- "main": "index.js",
- "dependencies": {},
- "devDependencies": {
- "tap": "~0.4.8"
- },
- "scripts": {
- "test": "tap test/simple/*.js"
- },
- "repository": {
- "type": "git",
- "url": "git://github.com/rvagg/string_decoder.git"
- },
- "homepage": "https://github.com/rvagg/string_decoder",
- "keywords": [
- "string",
- "decoder",
- "browser",
- "browserify"
- ],
- "license": "MIT",
- "gitHead": "d46d4fd87cf1d06e031c23f1ba170ca7d4ade9a0",
- "bugs": {
- "url": "https://github.com/rvagg/string_decoder/issues"
- },
- "_id": "string_decoder@0.10.31",
- "_shasum": "62e203bc41766c6c28c9fc84301dab1c5310fa94",
- "_from": "string_decoder@>=0.10.0-0 <0.11.0-0",
- "_npmVersion": "1.4.23",
- "_npmUser": {
- "name": "rvagg",
- "email": "rod@vagg.org"
- },
- "maintainers": [
- {
- "name": "substack",
- "email": "mail@substack.net"
- },
- {
- "name": "rvagg",
- "email": "rod@vagg.org"
- }
- ],
- "dist": {
- "shasum": "62e203bc41766c6c28c9fc84301dab1c5310fa94",
- "tarball": "http://registry.npmjs.org/string_decoder/-/string_decoder-0.10.31.tgz"
- },
- "directories": {},
- "_resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-0.10.31.tgz",
- "readme": "ERROR: No README data found!"
-}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/string_decoder/README.md nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/string_decoder/README.md
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/string_decoder/README.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/string_decoder/README.md 1970-01-01 00:00:00.000000000 +0000
@@ -1,7 +0,0 @@
-**string_decoder.js** (`require('string_decoder')`) from Node.js core
-
-Copyright Joyent, Inc. and other Node contributors. See LICENCE file for details.
-
-Version numbers match the versions found in Node core, e.g. 0.10.24 matches Node 0.10.24, likewise 0.11.10 matches Node 0.11.10. **Prefer the stable version over the unstable.**
-
-The *build/* directory contains a build script that will scrape the source from the [joyent/node](https://github.com/joyent/node) repo given a specific Node version.
\ No newline at end of file
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/.npmignore nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/.npmignore
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/.npmignore 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/.npmignore 1970-01-01 00:00:00.000000000 +0000
@@ -1,5 +0,0 @@
-build/
-test/
-examples/
-fs.js
-zlib.js
\ No newline at end of file
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/package.json nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/package.json
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/package.json 1970-01-01 00:00:00.000000000 +0000
@@ -1,69 +0,0 @@
-{
- "name": "readable-stream",
- "version": "1.0.31",
- "description": "Streams2, a user-land copy of the stream library from Node.js v0.10.x",
- "main": "readable.js",
- "dependencies": {
- "core-util-is": "~1.0.0",
- "isarray": "0.0.1",
- "string_decoder": "~0.10.x",
- "inherits": "~2.0.1"
- },
- "devDependencies": {
- "tap": "~0.2.6"
- },
- "scripts": {
- "test": "tap test/simple/*.js"
- },
- "repository": {
- "type": "git",
- "url": "git://github.com/isaacs/readable-stream"
- },
- "keywords": [
- "readable",
- "stream",
- "pipe"
- ],
- "browser": {
- "util": false
- },
- "author": {
- "name": "Isaac Z. Schlueter",
- "email": "i@izs.me",
- "url": "http://blog.izs.me/"
- },
- "license": "MIT",
- "bugs": {
- "url": "https://github.com/isaacs/readable-stream/issues"
- },
- "homepage": "https://github.com/isaacs/readable-stream",
- "_id": "readable-stream@1.0.31",
- "_shasum": "8f2502e0bc9e3b0da1b94520aabb4e2603ecafae",
- "_from": "readable-stream@>=1.0.26-0 <1.1.0-0",
- "_npmVersion": "1.4.9",
- "_npmUser": {
- "name": "rvagg",
- "email": "rod@vagg.org"
- },
- "maintainers": [
- {
- "name": "isaacs",
- "email": "i@izs.me"
- },
- {
- "name": "tootallnate",
- "email": "nathan@tootallnate.net"
- },
- {
- "name": "rvagg",
- "email": "rod@vagg.org"
- }
- ],
- "dist": {
- "shasum": "8f2502e0bc9e3b0da1b94520aabb4e2603ecafae",
- "tarball": "http://registry.npmjs.org/readable-stream/-/readable-stream-1.0.31.tgz"
- },
- "directories": {},
- "_resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-1.0.31.tgz",
- "readme": "ERROR: No README data found!"
-}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/passthrough.js nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/passthrough.js
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/passthrough.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/passthrough.js 1970-01-01 00:00:00.000000000 +0000
@@ -1 +0,0 @@
-module.exports = require("./lib/_stream_passthrough.js")
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/readable.js nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/readable.js
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/readable.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/readable.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,6 +0,0 @@
-exports = module.exports = require('./lib/_stream_readable.js');
-exports.Readable = exports;
-exports.Writable = require('./lib/_stream_writable.js');
-exports.Duplex = require('./lib/_stream_duplex.js');
-exports.Transform = require('./lib/_stream_transform.js');
-exports.PassThrough = require('./lib/_stream_passthrough.js');
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/README.md nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/README.md
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/README.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/README.md 1970-01-01 00:00:00.000000000 +0000
@@ -1,15 +0,0 @@
-# readable-stream
-
-***Node-core streams for userland***
-
-[![NPM](https://nodei.co/npm/readable-stream.png?downloads=true)](https://nodei.co/npm/readable-stream/)
-[![NPM](https://nodei.co/npm-dl/readable-stream.png)](https://nodei.co/npm/readable-stream/)
-
-This package is a mirror of the Streams2 and Streams3 implementations in Node-core.
-
-If you want to guarantee a stable streams base, regardless of what version of Node you, or the users of your libraries are using, use **readable-stream** *only* and avoid the *"stream"* module in Node-core.
-
-**readable-stream** comes in two major versions, v1.0.x and v1.1.x. The former tracks the Streams2 implementation in Node 0.10, including bug-fixes and minor improvements as they are added. The latter tracks Streams3 as it develops in Node 0.11; we will likely see a v1.2.x branch for Node 0.12.
-
-**readable-stream** uses proper patch-level versioning so if you pin to `"~1.0.0"` you’ll get the latest Node 0.10 Streams2 implementation, including any fixes and minor non-breaking improvements. The patch-level versions of 1.0.x and 1.1.x should mirror the patch-level versions of Node-core releases. You should prefer the **1.0.x** releases for now and when you’re ready to start using Streams3, pin to `"~1.1.0"`
-
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/transform.js nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/transform.js
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/transform.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/transform.js 1970-01-01 00:00:00.000000000 +0000
@@ -1 +0,0 @@
-module.exports = require("./lib/_stream_transform.js")
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/writable.js nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/writable.js
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/writable.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/writable.js 1970-01-01 00:00:00.000000000 +0000
@@ -1 +0,0 @@
-module.exports = require("./lib/_stream_writable.js")
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/package.json nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/package.json
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -1,6 +1,6 @@
{
"name": "bl",
- "version": "0.9.1",
+ "version": "0.9.3",
"description": "Buffer List: collect buffers and access with a standard readable Buffer interface, streamable too!",
"main": "bl.js",
"scripts": {
@@ -14,7 +14,8 @@
"homepage": "https://github.com/rvagg/bl",
"authors": [
"Rod Vagg (https://github.com/rvagg)",
- "Matteo Collina (https://github.com/mcollina)"
+ "Matteo Collina (https://github.com/mcollina)",
+ "Jarett Cruger (https://github.com/jcrugzz)"
],
"keywords": [
"buffer",
@@ -32,14 +33,14 @@
"faucet": "~0.0.1",
"brtapsauce": "~0.3.0"
},
- "gitHead": "53d3d10e39be326feb049ab27437173b3ce47ec4",
+ "gitHead": "4987a76bf6bafd7616e62c7023c955e62f3a9461",
"bugs": {
"url": "https://github.com/rvagg/bl/issues"
},
- "_id": "bl@0.9.1",
- "_shasum": "d262c5b83aa5cf4386cea1d998c82b36d7ae2942",
- "_from": "bl@>=0.9.0-0 <0.10.0-0",
- "_npmVersion": "1.4.21",
+ "_id": "bl@0.9.3",
+ "_shasum": "c41eff3e7cb31bde107c8f10076d274eff7f7d44",
+ "_from": "bl@>=0.9.0 <0.10.0",
+ "_npmVersion": "1.4.27",
"_npmUser": {
"name": "rvagg",
"email": "rod@vagg.org"
@@ -51,10 +52,10 @@
}
],
"dist": {
- "shasum": "d262c5b83aa5cf4386cea1d998c82b36d7ae2942",
- "tarball": "http://registry.npmjs.org/bl/-/bl-0.9.1.tgz"
+ "shasum": "c41eff3e7cb31bde107c8f10076d274eff7f7d44",
+ "tarball": "http://registry.npmjs.org/bl/-/bl-0.9.3.tgz"
},
"directories": {},
- "_resolved": "https://registry.npmjs.org/bl/-/bl-0.9.1.tgz",
+ "_resolved": "https://registry.npmjs.org/bl/-/bl-0.9.3.tgz",
"readme": "ERROR: No README data found!"
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/README.md nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/README.md
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/bl/README.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/bl/README.md 2015-01-20 21:22:17.000000000 +0000
@@ -1,7 +1,5 @@
# bl *(BufferList)*
-[![Build Status](https://secure.travis-ci.org/rvagg/bl.png)](http://travis-ci.org/rvagg/bl)
-
**A Node.js Buffer list collector, reader and streamer thingy.**
[![NPM](https://nodei.co/npm/bl.png?downloads=true&downloadRank=true)](https://nodei.co/npm/bl/)
@@ -169,7 +167,7 @@
--------------------------------------------------------
-### bl.readDoubleBE()
, bl.readDoubleLE()
, bl.readFloatBE()
, bl.readFloatLE()
, bl.readInt32BE()
, bl.readInt32LE()
, bl.readUInt32BE()
, bl.readUInt32LE()
, bl.readInt16BE()
, bl.readInt16LE()
, bl.readUInt16BE()
, bl.readUInt16LE()
, bl.readInt8()
, bl.readUInt8()
+### bl.readDoubleBE(), bl.readDoubleLE(), bl.readFloatBE(), bl.readFloatLE(), bl.readInt32BE(), bl.readInt32LE(), bl.readUInt32BE(), bl.readUInt32LE(), bl.readInt16BE(), bl.readInt16LE(), bl.readUInt16BE(), bl.readUInt16LE(), bl.readInt8(), bl.readUInt8()
All of the standard byte-reading methods of the `Buffer` interface are implemented and will operate across internal Buffer boundaries transparently.
@@ -188,9 +186,10 @@
* [Rod Vagg](https://github.com/rvagg)
* [Matteo Collina](https://github.com/mcollina)
+ * [Jarett Cruger](https://github.com/jcrugzz)
=======
## License
-**bl** is Copyright (c) 2013 Rod Vagg [@rvagg](https://twitter.com/rvagg) and licenced under the MIT licence. All rights not explicitly granted in the MIT license are reserved. See the included LICENSE file for more details.
+**bl** is Copyright (c) 2013 Rod Vagg [@rvagg](https://twitter.com/rvagg) and licenced under the MIT licence. All rights not explicitly granted in the MIT license are reserved. See the included LICENSE.md file for more details.
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/caseless/package.json nodejs-0.11.15/deps/npm/node_modules/request/node_modules/caseless/package.json
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/caseless/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/caseless/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -30,7 +30,7 @@
"homepage": "https://github.com/mikeal/caseless",
"_id": "caseless@0.6.0",
"_shasum": "8167c1ab8397fb5bb95f96d28e5a81c50f247ac4",
- "_from": "caseless@>=0.6.0-0 <0.7.0-0",
+ "_from": "caseless@>=0.6.0 <0.7.0",
"_npmVersion": "1.4.9",
"_npmUser": {
"name": "mikeal",
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/forever-agent/package.json nodejs-0.11.15/deps/npm/node_modules/request/node_modules/forever-agent/package.json
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/forever-agent/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/forever-agent/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -26,7 +26,7 @@
"shasum": "6d0e09c4921f94a27f63d3b49c5feff1ea4c5130",
"tarball": "http://registry.npmjs.org/forever-agent/-/forever-agent-0.5.2.tgz"
},
- "_from": "forever-agent@>=0.5.0-0 <0.6.0-0",
+ "_from": "forever-agent@>=0.5.0 <0.6.0",
"_npmVersion": "1.3.21",
"_npmUser": {
"name": "mikeal",
@@ -41,5 +41,6 @@
"directories": {},
"_shasum": "6d0e09c4921f94a27f63d3b49c5feff1ea4c5130",
"_resolved": "https://registry.npmjs.org/forever-agent/-/forever-agent-0.5.2.tgz",
- "readme": "ERROR: No README data found!"
+ "readme": "ERROR: No README data found!",
+ "scripts": {}
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/form-data/node_modules/async/package.json nodejs-0.11.15/deps/npm/node_modules/request/node_modules/form-data/node_modules/async/package.json
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/form-data/node_modules/async/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/form-data/node_modules/async/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -41,7 +41,7 @@
"shasum": "ac3613b1da9bed1b47510bb4651b8931e47146c7",
"tarball": "http://registry.npmjs.org/async/-/async-0.9.0.tgz"
},
- "_from": "async@>=0.9.0-0 <0.10.0-0",
+ "_from": "async@>=0.9.0 <0.10.0",
"_npmVersion": "1.4.3",
"_npmUser": {
"name": "caolan",
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/form-data/node_modules/combined-stream/node_modules/delayed-stream/package.json nodejs-0.11.15/deps/npm/node_modules/request/node_modules/form-data/node_modules/combined-stream/node_modules/delayed-stream/package.json
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/form-data/node_modules/combined-stream/node_modules/delayed-stream/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/form-data/node_modules/combined-stream/node_modules/delayed-stream/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -33,8 +33,8 @@
"scripts": {},
"directories": {},
"_shasum": "d4b1f43a93e8296dfe02694f4680bc37a313c73f",
- "_from": "delayed-stream@0.0.5",
"_resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-0.0.5.tgz",
+ "_from": "delayed-stream@0.0.5",
"bugs": {
"url": "https://github.com/felixge/node-delayed-stream/issues"
},
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/form-data/node_modules/combined-stream/package.json nodejs-0.11.15/deps/npm/node_modules/request/node_modules/form-data/node_modules/combined-stream/package.json
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/form-data/node_modules/combined-stream/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/form-data/node_modules/combined-stream/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -31,7 +31,7 @@
},
"_id": "combined-stream@0.0.5",
"_shasum": "29ed76e5c9aad07c4acf9ca3d32601cce28697a2",
- "_from": "combined-stream@>=0.0.4-0 <0.1.0-0",
+ "_from": "combined-stream@>=0.0.4 <0.1.0",
"_npmVersion": "1.4.14",
"_npmUser": {
"name": "alexindigo",
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/form-data/node_modules/mime/package.json nodejs-0.11.15/deps/npm/node_modules/request/node_modules/form-data/node_modules/mime/package.json
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/form-data/node_modules/mime/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/form-data/node_modules/mime/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -35,7 +35,7 @@
"shasum": "58203eed86e3a5ef17aed2b7d9ebd47f0a60dd10",
"tarball": "http://registry.npmjs.org/mime/-/mime-1.2.11.tgz"
},
- "_from": "mime@>=1.2.11-0 <1.3.0-0",
+ "_from": "mime@>=1.2.11 <1.3.0",
"_npmVersion": "1.3.6",
"_npmUser": {
"name": "broofa",
@@ -54,5 +54,6 @@
"directories": {},
"_shasum": "58203eed86e3a5ef17aed2b7d9ebd47f0a60dd10",
"_resolved": "https://registry.npmjs.org/mime/-/mime-1.2.11.tgz",
- "homepage": "https://github.com/broofa/node-mime"
+ "homepage": "https://github.com/broofa/node-mime",
+ "scripts": {}
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/form-data/package.json nodejs-0.11.15/deps/npm/node_modules/request/node_modules/form-data/package.json
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/form-data/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/form-data/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -42,7 +42,7 @@
"homepage": "https://github.com/felixge/node-form-data",
"_id": "form-data@0.1.4",
"_shasum": "91abd788aba9702b1aabfa8bc01031a2ac9e3b12",
- "_from": "form-data@>=0.1.0-0 <0.2.0-0",
+ "_from": "form-data@>=0.1.0 <0.2.0",
"_npmVersion": "1.4.14",
"_npmUser": {
"name": "alexindigo",
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/hawk/node_modules/boom/package.json nodejs-0.11.15/deps/npm/node_modules/request/node_modules/hawk/node_modules/boom/package.json
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/hawk/node_modules/boom/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/hawk/node_modules/boom/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -41,7 +41,7 @@
"shasum": "7a636e9ded4efcefb19cef4947a3c67dfaee911b",
"tarball": "http://registry.npmjs.org/boom/-/boom-0.4.2.tgz"
},
- "_from": "boom@>=0.4.0-0 <0.5.0-0",
+ "_from": "boom@>=0.4.0 <0.5.0",
"_npmVersion": "1.2.18",
"_npmUser": {
"name": "hueniverse",
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/hawk/node_modules/cryptiles/package.json nodejs-0.11.15/deps/npm/node_modules/request/node_modules/hawk/node_modules/cryptiles/package.json
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/hawk/node_modules/cryptiles/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/hawk/node_modules/cryptiles/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -45,7 +45,7 @@
"shasum": "ed91ff1f17ad13d3748288594f8a48a0d26f325c",
"tarball": "http://registry.npmjs.org/cryptiles/-/cryptiles-0.2.2.tgz"
},
- "_from": "cryptiles@>=0.2.0-0 <0.3.0-0",
+ "_from": "cryptiles@>=0.2.0 <0.3.0",
"_npmVersion": "1.2.24",
"_npmUser": {
"name": "hueniverse",
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/hawk/node_modules/hoek/package.json nodejs-0.11.15/deps/npm/node_modules/request/node_modules/hawk/node_modules/hoek/package.json
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/hawk/node_modules/hoek/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/hawk/node_modules/hoek/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -43,7 +43,7 @@
"shasum": "3d322462badf07716ea7eb85baf88079cddce505",
"tarball": "http://registry.npmjs.org/hoek/-/hoek-0.9.1.tgz"
},
- "_from": "hoek@>=0.9.0-0 <0.10.0-0",
+ "_from": "hoek@>=0.9.0 <0.10.0",
"_npmVersion": "1.2.18",
"_npmUser": {
"name": "hueniverse",
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/hawk/node_modules/sntp/package.json nodejs-0.11.15/deps/npm/node_modules/request/node_modules/hawk/node_modules/sntp/package.json
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/hawk/node_modules/sntp/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/hawk/node_modules/sntp/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -42,7 +42,7 @@
"shasum": "fb885f18b0f3aad189f824862536bceeec750900",
"tarball": "http://registry.npmjs.org/sntp/-/sntp-0.2.4.tgz"
},
- "_from": "sntp@>=0.2.0-0 <0.3.0-0",
+ "_from": "sntp@>=0.2.0 <0.3.0",
"_npmVersion": "1.2.18",
"_npmUser": {
"name": "hueniverse",
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/http-signature/node_modules/asn1/package.json nodejs-0.11.15/deps/npm/node_modules/request/node_modules/http-signature/node_modules/asn1/package.json
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/http-signature/node_modules/asn1/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/http-signature/node_modules/asn1/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -53,8 +53,8 @@
],
"directories": {},
"_shasum": "559be18376d08a4ec4dbe80877d27818639b2df7",
- "_from": "asn1@0.1.11",
"_resolved": "https://registry.npmjs.org/asn1/-/asn1-0.1.11.tgz",
+ "_from": "asn1@0.1.11",
"bugs": {
"url": "https://github.com/mcavage/node-asn1/issues"
},
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/http-signature/node_modules/assert-plus/package.json nodejs-0.11.15/deps/npm/node_modules/request/node_modules/http-signature/node_modules/assert-plus/package.json
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/http-signature/node_modules/assert-plus/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/http-signature/node_modules/assert-plus/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -13,7 +13,6 @@
"engines": {
"node": ">=0.6"
},
- "readme": "# node-assert-plus\n\nThis library is a super small wrapper over node's assert module that has two\nthings: (1) the ability to disable assertions with the environment variable\nNODE_NDEBUG, and (2) some API wrappers for argument testing. Like\n`assert.string(myArg, 'myArg')`. As a simple example, most of my code looks\nlike this:\n\n var assert = require('assert-plus');\n\n function fooAccount(options, callback) {\n\t assert.object(options, 'options');\n\t\tassert.number(options.id, 'options.id);\n\t\tassert.bool(options.isManager, 'options.isManager');\n\t\tassert.string(options.name, 'options.name');\n\t\tassert.arrayOfString(options.email, 'options.email');\n\t\tassert.func(callback, 'callback');\n\n // Do stuff\n\t\tcallback(null, {});\n }\n\n# API\n\nAll methods that *aren't* part of node's core assert API are simply assumed to\ntake an argument, and then a string 'name' that's not a message; `AssertionError`\nwill be thrown if the assertion fails with a message like:\n\n AssertionError: foo (string) is required\n\tat test (/home/mark/work/foo/foo.js:3:9)\n\tat Object. (/home/mark/work/foo/foo.js:15:1)\n\tat Module._compile (module.js:446:26)\n\tat Object..js (module.js:464:10)\n\tat Module.load (module.js:353:31)\n\tat Function._load (module.js:311:12)\n\tat Array.0 (module.js:484:10)\n\tat EventEmitter._tickCallback (node.js:190:38)\n\nfrom:\n\n function test(foo) {\n\t assert.string(foo, 'foo');\n }\n\nThere you go. You can check that arrays are of a homogenous type with `Arrayof$Type`:\n\n function test(foo) {\n\t assert.arrayOfString(foo, 'foo');\n }\n\nYou can assert IFF an argument is not `undefined` (i.e., an optional arg):\n\n assert.optionalString(foo, 'foo');\n\nLastly, you can opt-out of assertion checking altogether by setting the\nenvironment variable `NODE_NDEBUG=1`. This is pseudo-useful if you have\nlots of assertions, and don't want to pay `typeof ()` taxes to v8 in\nproduction.\n\nThe complete list of APIs is:\n\n* assert.bool\n* assert.buffer\n* assert.func\n* assert.number\n* assert.object\n* assert.string\n* assert.arrayOfBool\n* assert.arrayOfFunc\n* assert.arrayOfNumber\n* assert.arrayOfObject\n* assert.arrayOfString\n* assert.optionalBool\n* assert.optionalBuffer\n* assert.optionalFunc\n* assert.optionalNumber\n* assert.optionalObject\n* assert.optionalString\n* assert.optionalArrayOfBool\n* assert.optionalArrayOfFunc\n* assert.optionalArrayOfNumber\n* assert.optionalArrayOfObject\n* assert.optionalArrayOfString\n* assert.AssertionError\n* assert.fail\n* assert.ok\n* assert.equal\n* assert.notEqual\n* assert.deepEqual\n* assert.notDeepEqual\n* assert.strictEqual\n* assert.notStrictEqual\n* assert.throws\n* assert.doesNotThrow\n* assert.ifError\n\n# Installation\n\n npm install assert-plus\n\n## License\n\nThe MIT License (MIT)\nCopyright (c) 2012 Mark Cavage\n\nPermission is hereby granted, free of charge, to any person obtaining a copy of\nthis software and associated documentation files (the \"Software\"), to deal in\nthe Software without restriction, including without limitation the rights to\nuse, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of\nthe Software, and to permit persons to whom the Software is furnished to do so,\nsubject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.\n\n## Bugs\n\nSee .\n",
"_id": "assert-plus@0.1.2",
"dist": {
"shasum": "d93ffdbb67ac5507779be316a7d65146417beef8",
@@ -32,6 +31,8 @@
],
"directories": {},
"_shasum": "d93ffdbb67ac5507779be316a7d65146417beef8",
+ "_resolved": "https://registry.npmjs.org/assert-plus/-/assert-plus-0.1.2.tgz",
"_from": "assert-plus@0.1.2",
- "_resolved": "https://registry.npmjs.org/assert-plus/-/assert-plus-0.1.2.tgz"
+ "readme": "ERROR: No README data found!",
+ "scripts": {}
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/package.json nodejs-0.11.15/deps/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/package.json
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -29,7 +29,8 @@
],
"directories": {},
"_shasum": "fe8091d468a373a0b0c9ff8bbfb3425c00973a1d",
- "_from": "ctype@0.5.2",
"_resolved": "https://registry.npmjs.org/ctype/-/ctype-0.5.2.tgz",
- "readme": "ERROR: No README data found!"
+ "_from": "ctype@0.5.2",
+ "readme": "ERROR: No README data found!",
+ "scripts": {}
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/http-signature/package.json nodejs-0.11.15/deps/npm/node_modules/request/node_modules/http-signature/package.json
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/http-signature/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/http-signature/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -32,7 +32,7 @@
"shasum": "1494e4f5000a83c0f11bcc12d6007c530cb99582",
"tarball": "http://registry.npmjs.org/http-signature/-/http-signature-0.10.0.tgz"
},
- "_from": "http-signature@>=0.10.0-0 <0.11.0-0",
+ "_from": "http-signature@>=0.10.0 <0.11.0",
"_npmVersion": "1.2.18",
"_npmUser": {
"name": "mcavage",
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/json-stringify-safe/package.json nodejs-0.11.15/deps/npm/node_modules/request/node_modules/json-stringify-safe/package.json
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/json-stringify-safe/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/json-stringify-safe/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -22,8 +22,6 @@
"url": "http://blog.izs.me"
},
"license": "BSD",
- "readmeFilename": "README.md",
- "readme": "# json-stringify-safe\n\nLike JSON.stringify, but doesn't throw on circular references.\n\n## Usage\n\nTakes the same arguments as `JSON.stringify`.\n\n```javascript\nvar stringify = require('json-stringify-safe');\nvar circularObj = {};\ncircularObj.circularRef = circularObj;\ncircularObj.list = [ circularObj, circularObj ];\nconsole.log(stringify(circularObj, null, 2));\n```\n\nOutput:\n\n```json\n{\n \"circularRef\": \"[Circular]\",\n \"list\": [\n \"[Circular]\",\n \"[Circular]\"\n ]\n}\n```\n\n## Details\n\n```\nstringify(obj, serializer, indent, decycler)\n```\n\nThe first three arguments are the same as to JSON.stringify. The last\nis an argument that's only used when the object has been seen already.\n\nThe default `decycler` function returns the string `'[Circular]'`.\nIf, for example, you pass in `function(k,v){}` (return nothing) then it\nwill prune cycles. If you pass in `function(k,v){ return {foo: 'bar'}}`,\nthen cyclical objects will always be represented as `{\"foo\":\"bar\"}` in\nthe result.\n\n```\nstringify.getSerialize(serializer, decycler)\n```\n\nReturns a serializer that can be used elsewhere. This is the actual\nfunction that's passed to JSON.stringify.\n",
"bugs": {
"url": "https://github.com/isaacs/json-stringify-safe/issues"
},
@@ -32,7 +30,7 @@
"shasum": "4c1f228b5050837eba9d21f50c2e6e320624566e",
"tarball": "http://registry.npmjs.org/json-stringify-safe/-/json-stringify-safe-5.0.0.tgz"
},
- "_from": "json-stringify-safe@>=5.0.0-0 <5.1.0-0",
+ "_from": "json-stringify-safe@>=5.0.0 <5.1.0",
"_npmVersion": "1.3.6",
"_npmUser": {
"name": "isaacs",
@@ -47,5 +45,6 @@
"directories": {},
"_shasum": "4c1f228b5050837eba9d21f50c2e6e320624566e",
"_resolved": "https://registry.npmjs.org/json-stringify-safe/-/json-stringify-safe-5.0.0.tgz",
+ "readme": "ERROR: No README data found!",
"homepage": "https://github.com/isaacs/json-stringify-safe"
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/mime-types/package.json nodejs-0.11.15/deps/npm/node_modules/request/node_modules/mime-types/package.json
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/mime-types/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/mime-types/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -39,7 +39,7 @@
"homepage": "https://github.com/expressjs/mime-types",
"_id": "mime-types@1.0.2",
"_shasum": "995ae1392ab8affcbfcb2641dd054e943c0d5dce",
- "_from": "mime-types@>=1.0.1-0 <1.1.0-0",
+ "_from": "mime-types@>=1.0.1 <1.1.0",
"_npmVersion": "1.4.21",
"_npmUser": {
"name": "dougwilson",
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/node-uuid/package.json nodejs-0.11.15/deps/npm/node_modules/request/node_modules/node-uuid/package.json
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/node-uuid/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/node-uuid/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -34,7 +34,7 @@
"shasum": "39aef510e5889a3dca9c895b506c73aae1bac048",
"tarball": "http://registry.npmjs.org/node-uuid/-/node-uuid-1.4.1.tgz"
},
- "_from": "node-uuid@>=1.4.0-0 <1.5.0-0",
+ "_from": "node-uuid@>=1.4.0 <1.5.0",
"_npmVersion": "1.3.6",
"_npmUser": {
"name": "broofa",
@@ -49,5 +49,6 @@
"directories": {},
"_shasum": "39aef510e5889a3dca9c895b506c73aae1bac048",
"_resolved": "https://registry.npmjs.org/node-uuid/-/node-uuid-1.4.1.tgz",
- "homepage": "https://github.com/broofa/node-uuid"
+ "homepage": "https://github.com/broofa/node-uuid",
+ "scripts": {}
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/oauth-sign/package.json nodejs-0.11.15/deps/npm/node_modules/request/node_modules/oauth-sign/package.json
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/oauth-sign/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/oauth-sign/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -30,7 +30,7 @@
"shasum": "f22956f31ea7151a821e5f2fb32c113cad8b9f69",
"tarball": "http://registry.npmjs.org/oauth-sign/-/oauth-sign-0.4.0.tgz"
},
- "_from": "oauth-sign@>=0.4.0-0 <0.5.0-0",
+ "_from": "oauth-sign@>=0.4.0 <0.5.0",
"_npmVersion": "1.3.2",
"_npmUser": {
"name": "mikeal",
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/qs/.jshintrc nodejs-0.11.15/deps/npm/node_modules/request/node_modules/qs/.jshintrc
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/qs/.jshintrc 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/qs/.jshintrc 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,10 @@
+{
+ "node": true,
+
+ "curly": true,
+ "latedef": true,
+ "quotmark": true,
+ "undef": true,
+ "unused": true,
+ "trailing": true
+}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/qs/package.json nodejs-0.11.15/deps/npm/node_modules/request/node_modules/qs/package.json
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/qs/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/qs/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -35,7 +35,7 @@
},
"_id": "qs@1.2.2",
"_shasum": "19b57ff24dc2a99ce1f8bdf6afcda59f8ef61f88",
- "_from": "qs@>=1.2.0-0 <1.3.0-0",
+ "_from": "qs@>=1.2.0 <1.3.0",
"_npmVersion": "1.4.21",
"_npmUser": {
"name": "hueniverse",
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/stringstream/package.json nodejs-0.11.15/deps/npm/node_modules/request/node_modules/stringstream/package.json
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/stringstream/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/stringstream/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -39,10 +39,11 @@
],
"directories": {},
"_shasum": "0f0e3423f942960b5692ac324a57dd093bc41a92",
- "_from": "stringstream@>=0.0.4-0 <0.1.0-0",
"_resolved": "https://registry.npmjs.org/stringstream/-/stringstream-0.0.4.tgz",
+ "_from": "stringstream@>=0.0.4 <0.1.0",
"bugs": {
"url": "https://github.com/mhart/StringStream/issues"
},
- "homepage": "https://github.com/mhart/StringStream"
+ "homepage": "https://github.com/mhart/StringStream",
+ "scripts": {}
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/tough-cookie/node_modules/punycode/LICENSE-MIT.txt nodejs-0.11.15/deps/npm/node_modules/request/node_modules/tough-cookie/node_modules/punycode/LICENSE-MIT.txt
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/tough-cookie/node_modules/punycode/LICENSE-MIT.txt 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/tough-cookie/node_modules/punycode/LICENSE-MIT.txt 2015-01-20 21:22:17.000000000 +0000
@@ -1,4 +1,4 @@
-Copyright Mathias Bynens
+Copyright Mathias Bynens
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/tough-cookie/node_modules/punycode/package.json nodejs-0.11.15/deps/npm/node_modules/request/node_modules/tough-cookie/node_modules/punycode/package.json
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/tough-cookie/node_modules/punycode/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/tough-cookie/node_modules/punycode/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -1,8 +1,8 @@
{
"name": "punycode",
- "version": "1.3.1",
+ "version": "1.3.2",
"description": "A robust Punycode converter that fully complies to RFC 3492 and RFC 5891, and works on nearly all JavaScript platforms.",
- "homepage": "http://mths.be/punycode",
+ "homepage": "https://mths.be/punycode",
"main": "punycode.js",
"keywords": [
"punycode",
@@ -13,20 +13,15 @@
"url",
"domain"
],
- "licenses": [
- {
- "type": "MIT",
- "url": "http://mths.be/mit"
- }
- ],
+ "license": "MIT",
"author": {
"name": "Mathias Bynens",
- "url": "http://mathiasbynens.be/"
+ "url": "https://mathiasbynens.be/"
},
"contributors": [
{
"name": "Mathias Bynens",
- "url": "http://mathiasbynens.be/"
+ "url": "https://mathiasbynens.be/"
},
{
"name": "John-David Dalton",
@@ -44,9 +39,6 @@
"LICENSE-MIT.txt",
"punycode.js"
],
- "directories": {
- "test": "tests"
- },
"scripts": {
"test": "node tests/tests.js"
},
@@ -60,10 +52,11 @@
"qunitjs": "~1.11.0",
"requirejs": "^2.1.14"
},
- "_id": "punycode@1.3.1",
- "_shasum": "710afe5123c20a1530b712e3e682b9118fe8058e",
+ "gitHead": "38c8d3131a82567bfef18da09f7f4db68c84f8a3",
+ "_id": "punycode@1.3.2",
+ "_shasum": "9653a036fb7c1ee42342f2325cceefea3926c48d",
"_from": "punycode@>=0.2.0",
- "_npmVersion": "1.4.9",
+ "_npmVersion": "1.4.28",
"_npmUser": {
"name": "mathias",
"email": "mathias@qiwi.be"
@@ -79,9 +72,10 @@
}
],
"dist": {
- "shasum": "710afe5123c20a1530b712e3e682b9118fe8058e",
- "tarball": "http://registry.npmjs.org/punycode/-/punycode-1.3.1.tgz"
+ "shasum": "9653a036fb7c1ee42342f2325cceefea3926c48d",
+ "tarball": "http://registry.npmjs.org/punycode/-/punycode-1.3.2.tgz"
},
- "_resolved": "https://registry.npmjs.org/punycode/-/punycode-1.3.1.tgz",
+ "directories": {},
+ "_resolved": "https://registry.npmjs.org/punycode/-/punycode-1.3.2.tgz",
"readme": "ERROR: No README data found!"
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/tough-cookie/node_modules/punycode/punycode.js nodejs-0.11.15/deps/npm/node_modules/request/node_modules/tough-cookie/node_modules/punycode/punycode.js
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/tough-cookie/node_modules/punycode/punycode.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/tough-cookie/node_modules/punycode/punycode.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,4 +1,4 @@
-/*! http://mths.be/punycode v1.3.1 by @mathias */
+/*! https://mths.be/punycode v1.3.2 by @mathias */
;(function(root) {
/** Detect free variables */
@@ -103,7 +103,9 @@
result = parts[0] + '@';
string = parts[1];
}
- var labels = string.split(regexSeparators);
+ // Avoid `split(regex)` for IE8 compatibility. See #17.
+ string = string.replace(regexSeparators, '\x2E');
+ var labels = string.split('.');
var encoded = map(labels, fn).join('.');
return result + encoded;
}
@@ -115,7 +117,7 @@
* UCS-2 exposes as separate characters) into a single code point,
* matching UTF-16.
* @see `punycode.ucs2.encode`
- * @see
+ * @see
* @memberOf punycode.ucs2
* @name decode
* @param {String} string The Unicode input string (UCS-2).
@@ -484,11 +486,11 @@
* @memberOf punycode
* @type String
*/
- 'version': '1.3.1',
+ 'version': '1.3.2',
/**
* An object of methods to convert from JavaScript's internal character
* representation (UCS-2) to Unicode code points, and back.
- * @see
+ * @see
* @memberOf punycode
* @type Object
*/
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/tough-cookie/node_modules/punycode/README.md nodejs-0.11.15/deps/npm/node_modules/request/node_modules/tough-cookie/node_modules/punycode/README.md
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/tough-cookie/node_modules/punycode/README.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/tough-cookie/node_modules/punycode/README.md 2015-01-20 21:22:17.000000000 +0000
@@ -124,7 +124,7 @@
#### `punycode.ucs2.decode(string)`
-Creates an array containing the numeric code point values of each Unicode symbol in the string. While [JavaScript uses UCS-2 internally](http://mathiasbynens.be/notes/javascript-encoding), this function will convert a pair of surrogate halves (each of which UCS-2 exposes as separate characters) into a single code point, matching UTF-16.
+Creates an array containing the numeric code point values of each Unicode symbol in the string. While [JavaScript uses UCS-2 internally](https://mathiasbynens.be/notes/javascript-encoding), this function will convert a pair of surrogate halves (each of which UCS-2 exposes as separate characters) into a single code point, matching UTF-16.
```js
punycode.ucs2.decode('abc');
@@ -163,7 +163,7 @@
| [![twitter/mathias](https://gravatar.com/avatar/24e08a9ea84deb17ae121074d0f17125?s=70)](https://twitter.com/mathias "Follow @mathias on Twitter") |
|---|
-| [Mathias Bynens](http://mathiasbynens.be/) |
+| [Mathias Bynens](https://mathiasbynens.be/) |
## Contributors
@@ -173,4 +173,4 @@
## License
-Punycode.js is available under the [MIT](http://mths.be/mit) license.
+Punycode.js is available under the [MIT](https://mths.be/mit) license.
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/tunnel-agent/.jshintrc nodejs-0.11.15/deps/npm/node_modules/request/node_modules/tunnel-agent/.jshintrc
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/tunnel-agent/.jshintrc 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/tunnel-agent/.jshintrc 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,5 @@
+{
+ "node": true,
+ "asi": true,
+ "laxcomma": true
+}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/node_modules/tunnel-agent/package.json nodejs-0.11.15/deps/npm/node_modules/request/node_modules/tunnel-agent/package.json
--- nodejs-0.11.14/deps/npm/node_modules/request/node_modules/tunnel-agent/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/node_modules/tunnel-agent/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -26,7 +26,7 @@
"shasum": "b1184e312ffbcf70b3b4c78e8c219de7ebb1c550",
"tarball": "http://registry.npmjs.org/tunnel-agent/-/tunnel-agent-0.4.0.tgz"
},
- "_from": "tunnel-agent@>=0.4.0-0 <0.5.0-0",
+ "_from": "tunnel-agent@>=0.4.0 <0.5.0",
"_npmVersion": "1.3.21",
"_npmUser": {
"name": "mikeal",
@@ -41,5 +41,6 @@
"directories": {},
"_shasum": "b1184e312ffbcf70b3b4c78e8c219de7ebb1c550",
"_resolved": "https://registry.npmjs.org/tunnel-agent/-/tunnel-agent-0.4.0.tgz",
- "readme": "ERROR: No README data found!"
+ "readme": "ERROR: No README data found!",
+ "scripts": {}
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/package.json nodejs-0.11.15/deps/npm/node_modules/request/package.json
--- nodejs-0.11.14/deps/npm/node_modules/request/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -7,7 +7,7 @@
"util",
"utility"
],
- "version": "2.42.0",
+ "version": "2.46.0",
"author": {
"name": "Mikeal Rogers",
"email": "mikeal.rogers@gmail.com"
@@ -20,30 +20,21 @@
"url": "http://github.com/mikeal/request/issues"
},
"license": "Apache-2.0",
- "engines": [
- "node >= 0.8.0"
- ],
+ "engines": {
+ "node": ">=0.8.0"
+ },
"main": "index.js",
"dependencies": {
"bl": "~0.9.0",
"caseless": "~0.6.0",
"forever-agent": "~0.5.0",
- "qs": "~1.2.0",
+ "form-data": "~0.1.0",
"json-stringify-safe": "~5.0.0",
"mime-types": "~1.0.1",
"node-uuid": "~1.4.0",
+ "qs": "~1.2.0",
"tunnel-agent": "~0.4.0",
"tough-cookie": ">=0.12.0",
- "form-data": "~0.1.0",
- "http-signature": "~0.10.0",
- "oauth-sign": "~0.4.0",
- "hawk": "1.1.1",
- "aws-sign2": "~0.5.0",
- "stringstream": "~0.0.4"
- },
- "optionalDependencies": {
- "tough-cookie": ">=0.12.0",
- "form-data": "~0.1.0",
"http-signature": "~0.10.0",
"oauth-sign": "~0.4.0",
"hawk": "1.1.1",
@@ -51,31 +42,40 @@
"stringstream": "~0.0.4"
},
"scripts": {
- "test": "node tests/run.js"
+ "test": "npm run lint && node node_modules/.bin/taper tests/test-*.js",
+ "lint": "node node_modules/.bin/eslint lib/ *.js tests/ && echo Lint passed."
},
"devDependencies": {
- "rimraf": "~2.2.8"
+ "eslint": "0.5.1",
+ "rimraf": "~2.2.8",
+ "tape": "~3.0.0",
+ "taper": "~0.3.0"
},
+ "gitHead": "7cdd75ec184868bba3be88a780bfb6e10fe33be4",
"homepage": "https://github.com/mikeal/request",
- "_id": "request@2.42.0",
- "_shasum": "572bd0148938564040ac7ab148b96423a063304a",
- "_from": "request@>=2.42.0-0 <3.0.0-0",
- "_npmVersion": "1.4.9",
+ "_id": "request@2.46.0",
+ "_shasum": "359195d52eaf720bc69742579d04ad6d265a8274",
+ "_from": "request@>=2.46.0 <2.47.0",
+ "_npmVersion": "1.4.14",
"_npmUser": {
- "name": "mikeal",
- "email": "mikeal.rogers@gmail.com"
+ "name": "nylen",
+ "email": "jnylen@gmail.com"
},
"maintainers": [
{
"name": "mikeal",
"email": "mikeal.rogers@gmail.com"
+ },
+ {
+ "name": "nylen",
+ "email": "jnylen@gmail.com"
}
],
"dist": {
- "shasum": "572bd0148938564040ac7ab148b96423a063304a",
- "tarball": "http://registry.npmjs.org/request/-/request-2.42.0.tgz"
+ "shasum": "359195d52eaf720bc69742579d04ad6d265a8274",
+ "tarball": "http://registry.npmjs.org/request/-/request-2.46.0.tgz"
},
"directories": {},
- "_resolved": "https://registry.npmjs.org/request/-/request-2.42.0.tgz",
+ "_resolved": "https://registry.npmjs.org/request/-/request-2.46.0.tgz",
"readme": "ERROR: No README data found!"
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/README.md nodejs-0.11.15/deps/npm/node_modules/request/README.md
--- nodejs-0.11.14/deps/npm/node_modules/request/README.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/README.md 2015-01-20 21:22:17.000000000 +0000
@@ -1,4 +1,5 @@
# Request — Simplified HTTP client
+[![Gitter](https://badges.gitter.im/Join Chat.svg)](https://gitter.im/mikeal/request?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
[![NPM](https://nodei.co/npm/request.png?downloads=true&downloadRank=true&stars=true)](https://nodei.co/npm/request/)
@@ -35,6 +36,18 @@
request.get('http://google.com/img.png').pipe(request.put('http://mysite.com/img.png'))
```
+Request emits a "response" event when a response is received. The `response` argument will be an instance of [http.IncomingMessage](http://nodejs.org/api/http.html#http_http_incomingmessage).
+
+```javascript
+request
+ .get('http://google.com/img.png')
+ .on('response', function(response) {
+ console.log(response.statusCode) // 200
+ console.log(response.headers['content-type']) // 'image/png'
+ })
+ .pipe(request.put('http://mysite.com/img.png'))
+```
+
Now let’s get fancy.
```javascript
@@ -108,9 +121,8 @@
At this point, the connection is left open, and the client is
communicating directly with the `endpoint-server.com` machine.
-See (the wikipedia page on HTTP
-Tunneling)[http://en.wikipedia.org/wiki/HTTP_tunnel] for more
-information.
+See [the wikipedia page on HTTP Tunneling](http://en.wikipedia.org/wiki/HTTP_tunnel)
+for more information.
By default, when proxying `http` traffic, request will simply make a
standard proxied `http` request. This is done by making the `url`
@@ -169,48 +181,128 @@
server. All other headers are sent as-is over the established
connection.
-## UNIX Socket
+### Controlling proxy behaviour using environment variables
+
+The following environment variables are respected by `request`:
+
+ * `HTTP_PROXY` / `http_proxy`
+ * `HTTPS_PROXY` / `https_proxy`
+ * `NO_PROXY` / `no_proxy`
+
+When `HTTP_PROXY` / `http_proxy` are set, they will be used to proxy non-SSL requests that do not have an explicit `proxy` configuration option present. Similarly, `HTTPS_PROXY` / `https_proxy` will be respected for SSL requests that do not have an explicit `proxy` configuration option. It is valid to define a proxy in one of the environment variables, but then override it for a specific request, using the `proxy` configuration option. Furthermore, the `proxy` configuration option can be explicitly set to false / null to opt out of proxying altogether for that request.
+
+`request` is also aware of the `NO_PROXY`/`no_proxy` environment variables. These variables provide a granular way to opt out of proxying, on a per-host basis. It should contain a comma separated list of hosts to opt out of proxying. It is also possible to opt of proxying when a particular destination port is used. Finally, the variable may be set to `*` to opt out of the implicit proxy configuration of the other environment variables.
+
+Here's some examples of valid `no_proxy` values:
-`request` supports the `unix://` protocol for all requests. The path is assumed to be absolute to the root of the host file system.
+ * `google.com` - don't proxy HTTP/HTTPS requests to Google.
+ * `google.com:443` - don't proxy HTTPS requests to Google, but *do* proxy HTTP requests to Google.
+ * `google.com:443, yahoo.com:80` - don't proxy HTTPS requests to Google, and don't proxy HTTP requests to Yahoo!
+ * `*` - ignore `https_proxy`/`http_proxy` environment variables altogether.
-HTTP paths are extracted from the supplied URL by testing each level of the full URL against net.connect for a socket response.
+## UNIX Socket
-Thus the following request will GET `/httppath` from the HTTP server listening on `/tmp/unix.socket`
+`request` supports making requests to [UNIX Domain Sockets](http://en.wikipedia.org/wiki/Unix_domain_socket). To make one, use the following URL scheme:
```javascript
-request.get('unix://tmp/unix.socket/httppath')
+/* Pattern */ 'http://unix:SOCKET:PATH'
+/* Example */ request.get('http://unix:/absolute/path/to/unix.socket:/request/path')
```
+Note: The `SOCKET` path is assumed to be absolute to the root of the host file system.
+
+
## Forms
`request` supports `application/x-www-form-urlencoded` and `multipart/form-data` form uploads. For `multipart/related` refer to the `multipart` API.
+#### application/x-www-form-urlencoded (URL-Encoded Forms)
+
URL-encoded forms are simple.
```javascript
request.post('http://service.com/upload', {form:{key:'value'}})
// or
request.post('http://service.com/upload').form({key:'value'})
+// or
+request.post({url:'http://service.com/upload', form: {key:'value'}}, function(err,httpResponse,body){ /* ... */ })
```
-For `multipart/form-data` we use the [form-data](https://github.com/felixge/node-form-data) library by [@felixge](https://github.com/felixge). You don’t need to worry about piping the form object or setting the headers, `request` will handle that for you.
+#### multipart/form-data (Multipart Form Uploads)
+
+For `multipart/form-data` we use the [form-data](https://github.com/felixge/node-form-data) library by [@felixge](https://github.com/felixge). For the most cases, you can pass your upload form data via the `formData` option.
+
```javascript
-var r = request.post('http://service.com/upload', function optionalCallback (err, httpResponse, body) {
+var formData = {
+ // Pass a simple key-value pair
+ my_field: 'my_value',
+ // Pass data via Buffers
+ my_buffer: new Buffer([1, 2, 3]),
+ // Pass data via Streams
+ my_file: fs.createReadStream(__dirname + '/unicycle.jpg'),
+ // Pass multiple values /w an Array
+ attachments: [
+ fs.createReadStream(__dirname + '/attacment1.jpg')
+ fs.createReadStream(__dirname + '/attachment2.jpg')
+ ],
+ // Pass optional meta-data with an 'options' object with style: {value: DATA, options: OPTIONS}
+ // See the `form-data` README for more information about options: https://github.com/felixge/node-form-data
+ custom_file: {
+ value: fs.createReadStream('/dev/urandom'),
+ options: {
+ filename: 'topsecret.jpg',
+ contentType: 'image/jpg'
+ }
+ }
+};
+request.post({url:'http://service.com/upload', formData: formData}, function optionalCallback(err, httpResponse, body) {
if (err) {
return console.error('upload failed:', err);
}
console.log('Upload successful! Server responded with:', body);
-})
-var form = r.form()
-form.append('my_field', 'my_value')
-form.append('my_buffer', new Buffer([1, 2, 3]))
-form.append('my_file', fs.createReadStream(path.join(__dirname, 'doodle.png')))
-form.append('remote_file', request('http://google.com/doodle.png'))
+});
+```
+
+For advanced cases, you can the form-data object itself via `r.form()`. This can be modified until the request is fired on the next cycle of the event-loop. (Note that this calling `form()` will clear the currently set form data for that request.)
+
+```javascript
+// NOTE: Advanced use-case, for normal use see 'formData' usage above
+var r = request.post('http://service.com/upload', function optionalCallback(err, httpResponse, body) { // ...
-// Just like always, `r` is a writable stream, and can be used as such (you have until nextTick to pipe it, etc.)
-// Alternatively, you can provide a callback (that's what this example does — see `optionalCallback` above).
+var form = r.form();
+form.append('my_field', 'my_value');
+form.append('my_buffer', new Buffer([1, 2, 3]));
+form.append('custom_file', fs.createReadStream(__dirname + '/unicycle.jpg'), {filename: 'unicycle.jpg'});
```
+See the [form-data README](https://github.com/felixge/node-form-data) for more information & examples.
+
+#### multipart/related
+
+Some variations in different HTTP implementations require a newline/CRLF before, after, or both before and after the boundary of a `multipart/related` request (using the multipart option). This has been observed in the .NET WebAPI version 4.0. You can turn on a boundary preambleCRLF or postamble by passing them as `true` to your request options.
+
+```javascript
+ request(
+ { method: 'PUT'
+ , preambleCRLF: true
+ , postambleCRLF: true
+ , uri: 'http://service.com/upload'
+ , multipart:
+ [ { 'content-type': 'application/json'
+ , body: JSON.stringify({foo: 'bar', _attachments: {'message.txt': {follows: true, length: 18, 'content_type': 'text/plain' }}})
+ }
+ , { body: 'I am an attachment' }
+ ]
+ }
+ , function (error, response, body) {
+ if (err) {
+ return console.error('upload failed:', err);
+ }
+ console.log('Upload successful! Server responded with:', body);
+ }
+ )
+```
+
## HTTP Authentication
@@ -238,7 +330,7 @@
`sendImmediately` defaults to `true`, which causes a basic authentication header to be sent. If `sendImmediately` is `false`, then `request` will retry with a proper authentication header after receiving a `401` response from the server (which must contain a `WWW-Authenticate` header indicating the required authentication method).
-Note that you can also use for basic authentication a trick using the URL itself, as specified in [RFC 1738](http://www.ietf.org/rfc/rfc1738.txt).
+Note that you can also use for basic authentication a trick using the URL itself, as specified in [RFC 1738](http://www.ietf.org/rfc/rfc1738.txt).
Simply pass the `user:password` before the host with an `@` sign.
```javascript
@@ -331,35 +423,86 @@
request(options, callback);
```
+## TLS/SSL Protocol
+
+TLS/SSL Protocol options, such as `cert`, `key` and `passphrase`, can be
+set in the `agentOptions` property of the `options` object.
+In the example below, we call an API requires client side SSL certificate
+(in PEM format) with passphrase protected private key (in PEM format) and disable the SSLv3 protocol:
+
+```javascript
+var fs = require('fs')
+ , path = require('path')
+ , certFile = path.resolve(__dirname, 'ssl/client.crt')
+ , keyFile = path.resolve(__dirname, 'ssl/client.key')
+ , request = require('request');
+
+var options = {
+ url: 'https://api.some-server.com/',
+ agentOptions: {
+ 'cert': fs.readFileSync(certFile),
+ 'key': fs.readFileSync(keyFile),
+ // Or use `pfx` property replacing `cert` and `key` when using private key, certificate and CA certs in PFX or PKCS12 format:
+ // 'pfx': fs.readFileSync(pfxFilePath),
+ 'passphrase': 'password',
+ 'securityOptions': 'SSL_OP_NO_SSLv3'
+ }
+};
+
+request.get(options);
+```
+
+It is able to force using SSLv3 only by specifying `secureProtocol`:
+
+```javascript
+
+request.get({
+ url: 'https://api.some-server.com/',
+ agentOptions: {
+ 'secureProtocol': 'SSLv3_method'
+ }
+});
+```
+
## request(options, callback)
The first argument can be either a `url` or an `options` object. The only required option is `uri`; all others are optional.
* `uri` || `url` - fully qualified uri or a parsed url object from `url.parse()`
* `qs` - object containing querystring values to be appended to the `uri`
+* `useQuerystring` - If true, use `querystring` to stringify and parse
+ querystrings, otherwise use `qs` (default: `false`). Set this option to
+ `true` if you need arrays to be serialized as `foo=bar&foo=baz` instead of the
+ default `foo[0]=bar&foo[1]=baz`.
* `method` - http method (default: `"GET"`)
* `headers` - http headers (default: `{}`)
-* `body` - entity body for PATCH, POST and PUT requests. Must be a `Buffer` or `String`.
-* `form` - when passed an object or a querystring, this sets `body` to a querystring representation of value, and adds `Content-type: application/x-www-form-urlencoded; charset=utf-8` header. When passed no options, a `FormData` instance is returned (and is piped to request).
+* `body` - entity body for PATCH, POST and PUT requests. Must be a `Buffer` or `String`, unless `json` is `true`. If `json` is `true`, then `body` must be a JSON-serializable object.
+* `form` - when passed an object or a querystring, this sets `body` to a querystring representation of value, and adds `Content-type: application/x-www-form-urlencoded` header. When passed no options, a `FormData` instance is returned (and is piped to request). See "Forms" section above.
+* `formData` - Data to pass for a `multipart/form-data` request. See "Forms" section above.
+* `multipart` - (experimental) Data to pass for a `multipart/related` request. See "Forms" section above
* `auth` - A hash containing values `user` || `username`, `pass` || `password`, and `sendImmediately` (optional). See documentation above.
* `json` - sets `body` but to JSON representation of value and adds `Content-type: application/json` header. Additionally, parses the response body as JSON.
* `multipart` - (experimental) array of objects which contains their own headers and `body` attribute. Sends `multipart/related` request. See example below.
+* `preambleCRLF` - append a newline/CRLF before the boundary of your `multipart/form-data` request.
+* `postambleCRLF` - append a newline/CRLF at the end of the boundary of your `multipart/form-data` request.
* `followRedirect` - follow HTTP 3xx responses as redirects (default: `true`). This property can also be implemented as function which gets `response` object as a single argument and should return `true` if redirects should continue or `false` otherwise.
* `followAllRedirects` - follow non-GET HTTP 3xx responses as redirects (default: `false`)
* `maxRedirects` - the maximum number of redirects to follow (default: `10`)
-* `encoding` - Encoding to be used on `setEncoding` of response data. If `null`, the `body` is returned as a `Buffer`.
-* `pool` - A hash object containing the agents for these requests. If omitted, the request will use the global pool (which is set to node's default `maxSockets`)
-* `pool.maxSockets` - Integer containing the maximum amount of sockets in the pool.
+* `encoding` - Encoding to be used on `setEncoding` of response data. If `null`, the `body` is returned as a `Buffer`. Anything else **(including the default value of `undefined`)** will be passed as the [encoding](http://nodejs.org/api/buffer.html#buffer_buffer) parameter to `toString()` (meaning this is effectively `utf8` by default).
+* `pool` - An object describing which agents to use for the request. If this option is omitted the request will use the global agent (as long as [your options allow for it](request.js#L747)). Otherwise, request will search the pool for your custom agent. If no custom agent is found, a new agent will be created and added to the pool.
+ * A `maxSockets` property can also be provided on the `pool` object to set the max number of sockets for all agents created (ex: `pool: {maxSockets: Infinity}`).
* `timeout` - Integer containing the number of milliseconds to wait for a request to respond before aborting the request
* `proxy` - An HTTP proxy to be used. Supports proxy Auth with Basic Auth, identical to support for the `url` parameter (by embedding the auth info in the `uri`)
* `oauth` - Options for OAuth HMAC-SHA1 signing. See documentation above.
* `hawk` - Options for [Hawk signing](https://github.com/hueniverse/hawk). The `credentials` key must contain the necessary signing info, [see hawk docs for details](https://github.com/hueniverse/hawk#usage-example).
* `strictSSL` - If `true`, requires SSL certificates be valid. **Note:** to use your own certificate authority, you need to specify an agent that was created with that CA as an option.
+* `agentOptions` - Object containing user agent options. See documentation above. **Note:** [see tls API doc for TLS/SSL options](http://nodejs.org/api/tls.html#tls_tls_connect_options_callback).
+
* `jar` - If `true` and `tough-cookie` is installed, remember cookies for future use (or define your custom cookie jar; see examples section)
* `aws` - `object` containing AWS signing information. Should have the properties `key`, `secret`. Also requires the property `bucket`, unless you’re specifying your `bucket` as part of the path, or the request doesn’t use a bucket (i.e. GET Services)
* `httpSignature` - Options for the [HTTP Signature Scheme](https://github.com/joyent/node-http-signature/blob/master/http_signing.md) using [Joyent's library](https://github.com/joyent/node-http-signature). The `keyId` and `key` properties must be specified. See the docs for other options.
* `localAddress` - Local interface to bind for network connections.
-* `gzip` - If `true`, add an `Accept-Encoding` header to request compressed content encodings from the server (if not already present) and decode supported content encodings in the response.
+* `gzip` - If `true`, add an `Accept-Encoding` header to request compressed content encodings from the server (if not already present) and decode supported content encodings in the response. **Note:** Automatic decoding of the response content is performed on the body data returned through `request` (both through the `request` stream and passed to the callback function) but is not performed on the `response` stream (available from the `response` event) which is the unmodified `http.IncomingMessage` object which may contain compressed data. See example below.
* `tunnel` - If `true`, then *always* use a tunneling proxy. If
`false` (default), then tunneling will only be used if the
destination is `https`, or if a previous request in the redirect
@@ -368,7 +511,7 @@
tunneling proxy.
-The callback argument gets 3 arguments:
+The callback argument gets 3 arguments:
1. An `error` when applicable (usually from [`http.ClientRequest`](http://nodejs.org/api/http.html#http_class_http_clientrequest) object)
2. An [`http.IncomingMessage`](http://nodejs.org/api/http.html#http_http_incomingmessage) object
@@ -382,7 +525,7 @@
This method returns a wrapper around the normal request API that defaults to whatever options you pass in to it.
-**Note:** You can call `.defaults()` on the wrapper that is returned from `request.defaults` to add/override defaults that were previously defaulted.
+**Note:** You can call `.defaults()` on the wrapper that is returned from `request.defaults` to add/override defaults that were previously defaulted.
For example:
```javascript
@@ -450,7 +593,7 @@
Function that creates a new cookie.
```javascript
-request.cookie('cookie_string_here')
+request.cookie('key1=value1')
```
### request.jar
@@ -488,6 +631,37 @@
)
```
+For backwards-compatibility, response compression is not supported by default.
+To accept gzip-compressed responses, set the `gzip` option to `true`. Note
+that the body data passed through `request` is automatically decompressed
+while the response object is unmodified and will contain compressed data if
+the server sent a compressed response.
+
+```javascript
+ var request = require('request')
+ request(
+ { method: 'GET'
+ , uri: 'http://www.google.com'
+ , gzip: true
+ }
+ , function (error, response, body) {
+ // body is the decompressed response body
+ console.log('server encoded the data as: ' + (response.headers['content-encoding'] || 'identity'))
+ console.log('the decoded data is: ' + body)
+ }
+ ).on('data', function(data) {
+ // decompressed data as it is received
+ console.log('decoded chunk: ' + data)
+ })
+ .on('response', function(response) {
+ // unmodified http.IncomingMessage object
+ response.on('data', function(data) {
+ // compressed data as it is received
+ console.log('received ' + data.length + ' bytes of compressed data')
+ })
+ })
+```
+
Cookies are disabled by default (else, they would be used in subsequent requests). To enable cookies, set `jar` to `true` (either in `defaults` or `options`) and install `tough-cookie`.
```javascript
@@ -511,10 +685,11 @@
```javascript
// `npm install --save tough-cookie` before this works
-var j = request.jar()
-var cookie = request.cookie('your_cookie_here')
-j.setCookie(cookie, uri);
-request({url: 'http://www.google.com', jar: j}, function () {
+var j = request.jar();
+var cookie = request.cookie('key1=value1');
+var url = 'http://www.google.com';
+j.setCookie(cookie, url);
+request({url: url, jar: j}, function () {
request('http://images.google.com')
})
```
@@ -522,10 +697,10 @@
To inspect your cookie jar after a request
```javascript
-var j = request.jar()
+var j = request.jar()
request({url: 'http://www.google.com', jar: j}, function () {
var cookie_string = j.getCookieString(uri); // "key1=value1; key2=value2; ..."
- var cookies = j.getCookies(uri);
+ var cookies = j.getCookies(uri);
// [{key: 'key1', value: 'value1', domain: "www.google.com", ...}, ...]
})
```
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/release.sh nodejs-0.11.15/deps/npm/node_modules/request/release.sh
--- nodejs-0.11.14/deps/npm/node_modules/request/release.sh 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/release.sh 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,3 @@
+#!/bin/sh
+
+npm version minor && npm publish && npm version patch && git push --tags && git push origin master
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/request.js nodejs-0.11.15/deps/npm/node_modules/request/request.js
--- nodejs-0.11.14/deps/npm/node_modules/request/request.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/request.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,47 +1,41 @@
-var optional = require('./lib/optional')
- , http = require('http')
- , https = optional('https')
- , tls = optional('tls')
+'use strict'
+
+var http = require('http')
+ , https = require('https')
, url = require('url')
, util = require('util')
, stream = require('stream')
, qs = require('qs')
, querystring = require('querystring')
- , crypto = require('crypto')
, zlib = require('zlib')
-
+ , helpers = require('./lib/helpers')
, bl = require('bl')
- , oauth = optional('oauth-sign')
- , hawk = optional('hawk')
- , aws = optional('aws-sign2')
- , httpSignature = optional('http-signature')
+ , oauth = require('oauth-sign')
+ , hawk = require('hawk')
+ , aws = require('aws-sign2')
+ , httpSignature = require('http-signature')
, uuid = require('node-uuid')
, mime = require('mime-types')
, tunnel = require('tunnel-agent')
- , _safeStringify = require('json-stringify-safe')
- , stringstream = optional('stringstream')
+ , stringstream = require('stringstream')
, caseless = require('caseless')
-
, ForeverAgent = require('forever-agent')
- , FormData = optional('form-data')
-
+ , FormData = require('form-data')
, cookies = require('./lib/cookies')
- , globalCookieJar = cookies.jar()
-
, copy = require('./lib/copy')
, debug = require('./lib/debug')
, net = require('net')
- ;
-function safeStringify (obj) {
- var ret
- try { ret = JSON.stringify(obj) }
- catch (e) { ret = _safeStringify(obj) }
- return ret
-}
+var safeStringify = helpers.safeStringify
+ , md5 = helpers.md5
+ , isReadStream = helpers.isReadStream
+ , toBase64 = helpers.toBase64
+ , defer = helpers.defer
+ , globalCookieJar = cookies.jar()
+
var globalPool = {}
-var isUrl = /^https?:|^unix:/
+ , isUrl = /^https?:/
var defaultProxyHeaderWhiteList = [
'accept',
@@ -70,148 +64,272 @@
'via'
]
-function isReadStream (rs) {
- return rs.readable && rs.path && rs.mode;
+function filterForNonReserved(reserved, options) {
+ // Filter out properties that are not reserved.
+ // Reserved values are passed in at call site.
+
+ var object = {}
+ for (var i in options) {
+ var notReserved = (reserved.indexOf(i) === -1)
+ if (notReserved) {
+ object[i] = options[i]
+ }
+ }
+ return object
+}
+
+function filterOutReservedFunctions(reserved, options) {
+ // Filter out properties that are functions and are reserved.
+ // Reserved values are passed in at call site.
+
+ var object = {}
+ for (var i in options) {
+ var isReserved = !(reserved.indexOf(i) === -1)
+ var isFunction = (typeof options[i] === 'function')
+ if (!(isReserved && isFunction)) {
+ object[i] = options[i]
+ }
+ }
+ return object
+
+}
+
+function constructProxyHost(uriObject) {
+ var port = uriObject.portA
+ , protocol = uriObject.protocol
+ , proxyHost = uriObject.hostname + ':'
+
+ if (port) {
+ proxyHost += port
+ } else if (protocol === 'https:') {
+ proxyHost += '443'
+ } else {
+ proxyHost += '80'
+ }
+
+ return proxyHost
+}
+
+function constructProxyHeaderWhiteList(headers, proxyHeaderWhiteList) {
+ return Object.keys(headers)
+ .filter(function (header) {
+ return proxyHeaderWhiteList.indexOf(header.toLowerCase()) !== -1
+ })
+ .reduce(function (set, header) {
+ set[header] = headers[header]
+ return set
+ }, {})
+}
+
+function construcTunnelOptions(request) {
+ var proxy = request.proxy
+ var proxyHeaders = request.proxyHeaders
+ var proxyAuth
+
+ if (proxy.auth) {
+ proxyAuth = proxy.auth
+ }
+
+ if (!proxy.auth && request.proxyAuthorization) {
+ proxyHeaders['Proxy-Authorization'] = request.proxyAuthorization
+ }
+
+ var tunnelOptions = {
+ proxy: {
+ host: proxy.hostname,
+ port: +proxy.port,
+ proxyAuth: proxyAuth,
+ headers: proxyHeaders
+ },
+ rejectUnauthorized: request.rejectUnauthorized,
+ headers: request.headers,
+ ca: request.ca,
+ cert: request.cert,
+ key: request.key
+ }
+
+ return tunnelOptions
}
-function toBase64 (str) {
- return (new Buffer(str || "", "ascii")).toString("base64")
+function constructTunnelFnName(uri, proxy) {
+ var uriProtocol = (uri.protocol === 'https:' ? 'https' : 'http')
+ var proxyProtocol = (proxy.protocol === 'https:' ? 'Https' : 'Http')
+ return [uriProtocol, proxyProtocol].join('Over')
}
-function md5 (str) {
- return crypto.createHash('md5').update(str).digest('hex')
+function getTunnelFn(request) {
+ var uri = request.uri
+ var proxy = request.proxy
+ var tunnelFnName = constructTunnelFnName(uri, proxy)
+ return tunnel[tunnelFnName]
+}
+
+// Decide the proper request proxy to use based on the request URI object and the
+// environmental variables (NO_PROXY, HTTP_PROXY, etc.)
+function getProxyFromURI(uri) {
+ // respect NO_PROXY environment variables (see: http://lynx.isc.org/current/breakout/lynx_help/keystrokes/environments.html)
+ var noProxy = process.env.NO_PROXY || process.env.no_proxy || null
+
+ // easy case first - if NO_PROXY is '*'
+ if (noProxy === '*') {
+ return null
+ }
+
+ // otherwise, parse the noProxy value to see if it applies to the URL
+ if (noProxy !== null) {
+ var noProxyItem, hostname, port, noProxyItemParts, noProxyHost, noProxyPort, noProxyList
+
+ // canonicalize the hostname, so that 'oogle.com' won't match 'google.com'
+ hostname = uri.hostname.replace(/^\.*/, '.').toLowerCase()
+ noProxyList = noProxy.split(',')
+
+ for (var i = 0, len = noProxyList.length; i < len; i++) {
+ noProxyItem = noProxyList[i].trim().toLowerCase()
+
+ // no_proxy can be granular at the port level, which complicates things a bit.
+ if (noProxyItem.indexOf(':') > -1) {
+ noProxyItemParts = noProxyItem.split(':', 2)
+ noProxyHost = noProxyItemParts[0].replace(/^\.*/, '.')
+ noProxyPort = noProxyItemParts[1]
+ port = uri.port || (uri.protocol === 'https:' ? '443' : '80')
+
+ // we've found a match - ports are same and host ends with no_proxy entry.
+ if (port === noProxyPort && hostname.indexOf(noProxyHost) === hostname.length - noProxyHost.length) {
+ return null
+ }
+ } else {
+ noProxyItem = noProxyItem.replace(/^\.*/, '.')
+ if (hostname.indexOf(noProxyItem) === hostname.length - noProxyItem.length) {
+ return null
+ }
+ }
+ }
+ }
+
+ // check for HTTP(S)_PROXY environment variables
+ if (uri.protocol === 'http:') {
+ return process.env.HTTP_PROXY || process.env.http_proxy || null
+ } else if (uri.protocol === 'https:') {
+ return process.env.HTTPS_PROXY || process.env.https_proxy || process.env.HTTP_PROXY || process.env.http_proxy || null
+ }
+
+ // return null if all else fails (What uri protocol are you using then?)
+ return null
+}
+
+// Function for properly handling a connection error
+function connectionErrorHandler(error) {
+ var socket = this
+ if (socket.res) {
+ if (socket.res.request) {
+ socket.res.request.emit('error', error)
+ } else {
+ socket.res.emit('error', error)
+ }
+ } else {
+ socket._httpMessage.emit('error', error)
+ }
}
// Return a simpler request object to allow serialization
function requestToJSON() {
+ var self = this
return {
- uri: this.uri,
- method: this.method,
- headers: this.headers
+ uri: self.uri,
+ method: self.method,
+ headers: self.headers
}
}
// Return a simpler response object to allow serialization
function responseToJSON() {
+ var self = this
return {
- statusCode: this.statusCode,
- body: this.body,
- headers: this.headers,
- request: requestToJSON.call(this.request)
+ statusCode: self.statusCode,
+ body: self.body,
+ headers: self.headers,
+ request: requestToJSON.call(self.request)
}
}
function Request (options) {
- stream.Stream.call(this)
- this.readable = true
- this.writable = true
+ // if tunnel property of options was not given default to false
+ // if given the method property in options, set property explicitMethod to true
- if (typeof options === 'string') {
- options = {uri:options}
- }
+ // extend the Request instance with any non-reserved properties
+ // remove any reserved functions from the options object
+ // set Request instance to be readable and writable
+ // call init
+ var self = this
+ stream.Stream.call(self)
var reserved = Object.keys(Request.prototype)
- for (var i in options) {
- if (reserved.indexOf(i) === -1) {
- this[i] = options[i]
- } else {
- if (typeof options[i] === 'function') {
- delete options[i]
- }
- }
- }
+ var nonReserved = filterForNonReserved(reserved, options)
+ stream.Stream.call(self)
+ util._extend(self, nonReserved)
+ options = filterOutReservedFunctions(reserved, options)
+
+ self.readable = true
+ self.writable = true
+ if (typeof options.tunnel === 'undefined') {
+ options.tunnel = false
+ }
if (options.method) {
- this.explicitMethod = true
+ self.explicitMethod = true
}
-
- // Assume that we're not going to tunnel unless we need to
- if (typeof options.tunnel === 'undefined') options.tunnel = false
-
- this.init(options)
+ self.canTunnel = options.tunnel !== false && tunnel
+ self.init(options)
}
-util.inherits(Request, stream.Stream)
+util.inherits(Request, stream.Stream)
-// Set up the tunneling agent if necessary
Request.prototype.setupTunnel = function () {
- var self = this
- if (typeof self.proxy == 'string') self.proxy = url.parse(self.proxy)
+ // Set up the tunneling agent if necessary
+ // Only send the proxy whitelisted header names.
+ // Turn on tunneling for the rest of request.
- if (!self.proxy) return false
+ var self = this
- // Don't need to use a tunneling proxy
- if (!self.tunnel && self.uri.protocol !== 'https:')
- return
+ if (typeof self.proxy === 'string') {
+ self.proxy = url.parse(self.proxy)
+ }
- // do the HTTP CONNECT dance using koichik/node-tunnel
+ if (!self.proxy) {
+ return false
+ }
- // The host to tell the proxy to CONNECT to
- var proxyHost = self.uri.hostname + ':'
- if (self.uri.port)
- proxyHost += self.uri.port
- else if (self.uri.protocol === 'https:')
- proxyHost += '443'
- else
- proxyHost += '80'
+ if (!self.tunnel && self.uri.protocol !== 'https:') {
+ return false
+ }
- if (!self.proxyHeaderWhiteList)
+ if (!self.proxyHeaderWhiteList) {
self.proxyHeaderWhiteList = defaultProxyHeaderWhiteList
+ }
- // Only send the proxy the whitelisted header names.
- var proxyHeaders = Object.keys(self.headers).filter(function (h) {
- return self.proxyHeaderWhiteList.indexOf(h.toLowerCase()) !== -1
- }).reduce(function (set, h) {
- set[h] = self.headers[h]
- return set
- }, {})
-
- proxyHeaders.host = proxyHost
-
- var tunnelFnName =
- (self.uri.protocol === 'https:' ? 'https' : 'http') +
- 'Over' +
- (self.proxy.protocol === 'https:' ? 'Https' : 'Http')
-
- var tunnelFn = tunnel[tunnelFnName]
+ var proxyHost = constructProxyHost(self.uri)
+ self.proxyHeaders = constructProxyHeaderWhiteList(self.headers, self.proxyHeaderWhiteList)
+ self.proxyHeaders.host = proxyHost
- var proxyAuth
- if (self.proxy.auth)
- proxyAuth = self.proxy.auth
- else if (self.proxyAuthorization)
- proxyHeaders['Proxy-Authorization'] = self.proxyAuthorization
-
- var tunnelOptions = { proxy: { host: self.proxy.hostname
- , port: +self.proxy.port
- , proxyAuth: proxyAuth
- , headers: proxyHeaders }
- , rejectUnauthorized: self.rejectUnauthorized
- , headers: self.headers
- , ca: self.ca
- , cert: self.cert
- , key: self.key}
+ var tunnelFn = getTunnelFn(self)
+ var tunnelOptions = construcTunnelOptions(self)
self.agent = tunnelFn(tunnelOptions)
-
- // At this point, we know that the proxy will support tunneling
- // (or fail miserably), so we're going to tunnel all proxied requests
- // from here on out.
self.tunnel = true
-
return true
}
-
-
-
Request.prototype.init = function (options) {
// init() contains all the code to setup the request object.
// the actual outgoing request is not started until start() is called
// this function is called from both the constructor and on redirect.
var self = this
- if (!options) options = {}
+ if (!options) {
+ options = {}
+ }
+ self.headers = self.headers ? copy(self.headers) : {}
- caseless.httpify(self, self.headers || {})
+ caseless.httpify(self, self.headers)
// Never send proxy-auth to the endpoint!
if (self.hasHeader('proxy-authorization')) {
@@ -219,11 +337,19 @@
self.removeHeader('proxy-authorization')
}
- if (!self.method) self.method = options.method || 'GET'
+ if (!self.method) {
+ self.method = options.method || 'GET'
+ }
self.localAddress = options.localAddress
+ if (!self.qsLib) {
+ self.qsLib = (options.useQuerystring ? querystring : qs)
+ }
+
debug(options)
- if (!self.pool && self.pool !== false) self.pool = globalPool
+ if (!self.pool && self.pool !== false) {
+ self.pool = globalPool
+ }
self.dests = self.dests || []
self.__isRequestRequest = true
@@ -231,7 +357,9 @@
if (!self._callback && self.callback) {
self._callback = self.callback
self.callback = function () {
- if (self._callbackCalled) return // Print a warning maybe?
+ if (self._callbackCalled) {
+ return // Print a warning maybe?
+ }
self._callbackCalled = true
self._callback.apply(self, arguments)
}
@@ -239,17 +367,40 @@
self.on('complete', self.callback.bind(self, null))
}
- if (self.url && !self.uri) {
- // People use this property instead all the time so why not just support it.
+ // People use this property instead all the time, so support it
+ if (!self.uri && self.url) {
self.uri = self.url
delete self.url
}
+ // A URI is needed by this point, throw if we haven't been able to get one
if (!self.uri) {
- // this will throw if unhandled but is handleable when in a redirect
- return self.emit('error', new Error("options.uri is a required argument"))
- } else {
- if (typeof self.uri == "string") self.uri = url.parse(self.uri)
+ return self.emit('error', new Error('options.uri is a required argument'))
+ }
+
+ // If a string URI/URL was given, parse it into a URL object
+ if(typeof self.uri === 'string') {
+ self.uri = url.parse(self.uri)
+ }
+
+ // DEPRECATED: Warning for users of the old Unix Sockets URL Scheme
+ if (self.uri.protocol === 'unix:') {
+ return self.emit('error', new Error('`unix://` URL scheme is no longer supported. Please use the format `http://unix:SOCKET:PATH`'))
+ }
+
+ // Support Unix Sockets
+ if(self.uri.host === 'unix') {
+ // Get the socket & request paths from the URL
+ var unixParts = self.uri.path.split(':')
+ , host = unixParts[0]
+ , path = unixParts[1]
+ // Apply unix properties to request
+ self.socketPath = host
+ self.uri.pathname = path
+ self.uri.path = path
+ self.uri.host = host
+ self.uri.hostname = host
+ self.uri.isUnix = true
}
if (self.strictSSL === false) {
@@ -257,13 +408,7 @@
}
if(!self.hasOwnProperty('proxy')) {
- // check for HTTP(S)_PROXY environment variables
- if(self.uri.protocol == "http:") {
- self.proxy = process.env.HTTP_PROXY || process.env.http_proxy || null;
- } else if(self.uri.protocol == "https:") {
- self.proxy = process.env.HTTPS_PROXY || process.env.https_proxy ||
- process.env.HTTP_PROXY || process.env.http_proxy || null;
- }
+ self.proxy = getProxyFromURI(self.uri)
}
// Pass in `tunnel:true` to *always* tunnel through proxies
@@ -274,8 +419,8 @@
if (!self.uri.pathname) {self.uri.pathname = '/'}
- if (!self.uri.host && !self.protocol=='unix:') {
- // Invalid URI: it may generate lot of bad errors, like "TypeError: Cannot call method 'indexOf' of undefined" in CookieJar
+ if (!(self.uri.host || (self.uri.hostname && self.uri.port)) && !self.uri.isUnix) {
+ // Invalid URI: it may generate lot of bad errors, like 'TypeError: Cannot call method `indexOf` of undefined' in CookieJar
// Detect and reject it as soon as possible
var faultyUri = url.format(self.uri)
var message = 'Invalid URI "' + faultyUri + '"'
@@ -285,27 +430,29 @@
// they should be warned that it can be caused by a redirection (can save some hair)
message += '. This can be caused by a crappy redirection.'
}
- self.emit('error', new Error(message))
- return // This error was fatal
+ // This error was fatal
+ return self.emit('error', new Error(message))
}
self._redirectsFollowed = self._redirectsFollowed || 0
self.maxRedirects = (self.maxRedirects !== undefined) ? self.maxRedirects : 10
self.allowRedirect = (typeof self.followRedirect === 'function') ? self.followRedirect : function(response) {
- return true;
- };
- self.followRedirect = (self.followRedirect !== undefined) ? !!self.followRedirect : true
+ return true
+ }
+ self.followRedirects = (self.followRedirect !== undefined) ? !!self.followRedirect : true
self.followAllRedirects = (self.followAllRedirects !== undefined) ? self.followAllRedirects : false
- if (self.followRedirect || self.followAllRedirects)
+ if (self.followRedirects || self.followAllRedirects) {
self.redirects = self.redirects || []
+ }
self.setHost = false
if (!self.hasHeader('host')) {
self.setHeader('host', self.uri.hostname)
if (self.uri.port) {
if ( !(self.uri.port === 80 && self.uri.protocol === 'http:') &&
- !(self.uri.port === 443 && self.uri.protocol === 'https:') )
- self.setHeader('host', self.getHeader('host') + (':'+self.uri.port) )
+ !(self.uri.port === 443 && self.uri.protocol === 'https:') ) {
+ self.setHeader('host', self.getHeader('host') + (':' + self.uri.port) )
+ }
}
self.setHost = true
}
@@ -313,8 +460,8 @@
self.jar(self._jar || options.jar)
if (!self.uri.port) {
- if (self.uri.protocol == 'http:') {self.uri.port = 80}
- else if (self.uri.protocol == 'https:') {self.uri.port = 443}
+ if (self.uri.protocol === 'http:') {self.uri.port = 80}
+ else if (self.uri.protocol === 'https:') {self.uri.port = 443}
}
if (self.proxy && !self.tunnel) {
@@ -325,317 +472,253 @@
self.host = self.uri.hostname
}
- self.clientErrorHandler = function (error) {
- if (self._aborted) return
- if (self.req && self.req._reusedSocket && error.code === 'ECONNRESET'
- && self.agent.addRequestNoreuse) {
- self.agent = { addRequest: self.agent.addRequestNoreuse.bind(self.agent) }
- self.start()
- self.req.end()
- return
- }
- if (self.timeout && self.timeoutTimer) {
- clearTimeout(self.timeoutTimer)
- self.timeoutTimer = null
- }
- self.emit('error', error)
+ if (options.form) {
+ self.form(options.form)
}
- self._parserErrorHandler = function (error) {
- if (this.res) {
- if (this.res.request) {
- this.res.request.emit('error', error)
+ if (options.formData) {
+ var formData = options.formData
+ var requestForm = self.form()
+ var appendFormValue = function (key, value) {
+ if (value.hasOwnProperty('value') && value.hasOwnProperty('options')) {
+ requestForm.append(key, value.value, value.options)
} else {
- this.res.emit('error', error)
+ requestForm.append(key, value)
+ }
+ }
+ for (var formKey in formData) {
+ if (formData.hasOwnProperty(formKey)) {
+ var formValue = formData[formKey]
+ if (formValue instanceof Array) {
+ for (var j = 0; j < formValue.length; j++) {
+ appendFormValue(formKey, formValue[j])
+ }
+ } else {
+ appendFormValue(formKey, formValue)
+ }
}
- } else {
- this._httpMessage.emit('error', error)
}
}
- self._buildRequest = function(){
- var self = this;
-
- if (options.form) {
- self.form(options.form)
- }
+ if (options.qs) {
+ self.qs(options.qs)
+ }
- if (options.qs) self.qs(options.qs)
+ if (self.uri.path) {
+ self.path = self.uri.path
+ } else {
+ self.path = self.uri.pathname + (self.uri.search || '')
+ }
- if (self.uri.path) {
- self.path = self.uri.path
- } else {
- self.path = self.uri.pathname + (self.uri.search || "")
- }
+ if (self.path.length === 0) {
+ self.path = '/'
+ }
- if (self.path.length === 0) self.path = '/'
+ // Auth must happen last in case signing is dependent on other headers
+ if (options.oauth) {
+ self.oauth(options.oauth)
+ }
+ if (options.aws) {
+ self.aws(options.aws)
+ }
- // Auth must happen last in case signing is dependent on other headers
- if (options.oauth) {
- self.oauth(options.oauth)
- }
+ if (options.hawk) {
+ self.hawk(options.hawk)
+ }
- if (options.aws) {
- self.aws(options.aws)
- }
+ if (options.httpSignature) {
+ self.httpSignature(options.httpSignature)
+ }
- if (options.hawk) {
- self.hawk(options.hawk)
+ if (options.auth) {
+ if (Object.prototype.hasOwnProperty.call(options.auth, 'username')) {
+ options.auth.user = options.auth.username
}
-
- if (options.httpSignature) {
- self.httpSignature(options.httpSignature)
+ if (Object.prototype.hasOwnProperty.call(options.auth, 'password')) {
+ options.auth.pass = options.auth.password
}
- if (options.auth) {
- if (Object.prototype.hasOwnProperty.call(options.auth, 'username')) options.auth.user = options.auth.username
- if (Object.prototype.hasOwnProperty.call(options.auth, 'password')) options.auth.pass = options.auth.password
+ self.auth(
+ options.auth.user,
+ options.auth.pass,
+ options.auth.sendImmediately,
+ options.auth.bearer
+ )
+ }
- self.auth(
- options.auth.user,
- options.auth.pass,
- options.auth.sendImmediately,
- options.auth.bearer
- )
- }
+ if (self.gzip && !self.hasHeader('accept-encoding')) {
+ self.setHeader('accept-encoding', 'gzip')
+ }
- if (self.gzip && !self.hasHeader('accept-encoding')) {
- self.setHeader('accept-encoding', 'gzip')
- }
+ if (self.uri.auth && !self.hasHeader('authorization')) {
+ var uriAuthPieces = self.uri.auth.split(':').map(function(item){ return querystring.unescape(item) })
+ self.auth(uriAuthPieces[0], uriAuthPieces.slice(1).join(':'), true)
+ }
- if (self.uri.auth && !self.hasHeader('authorization')) {
- var authPieces = self.uri.auth.split(':').map(function(item){ return querystring.unescape(item) })
- self.auth(authPieces[0], authPieces.slice(1).join(':'), true)
+ if (self.proxy && !self.tunnel) {
+ if (self.proxy.auth && !self.proxyAuthorization) {
+ var proxyAuthPieces = self.proxy.auth.split(':').map(function(item){
+ return querystring.unescape(item)
+ })
+ var authHeader = 'Basic ' + toBase64(proxyAuthPieces.join(':'))
+ self.proxyAuthorization = authHeader
}
-
- if (self.proxy && !self.tunnel) {
- if (self.proxy.auth && !self.proxyAuthorization) {
- var authPieces = self.proxy.auth.split(':').map(function(item){
- return querystring.unescape(item)
- })
- var authHeader = 'Basic ' + toBase64(authPieces.join(':'))
- self.proxyAuthorization = authHeader
- }
- if (self.proxyAuthorization)
- self.setHeader('proxy-authorization', self.proxyAuthorization)
+ if (self.proxyAuthorization) {
+ self.setHeader('proxy-authorization', self.proxyAuthorization)
}
+ }
- if (self.proxy && !self.tunnel) self.path = (self.uri.protocol + '//' + self.uri.host + self.path)
-
- if (options.json) {
- self.json(options.json)
- } else if (options.multipart) {
- self.boundary = uuid()
- self.multipart(options.multipart)
- }
+ if (self.proxy && !self.tunnel) {
+ self.path = (self.uri.protocol + '//' + self.uri.host + self.path)
+ }
- if (self.body) {
- var length = 0
- if (!Buffer.isBuffer(self.body)) {
- if (Array.isArray(self.body)) {
- for (var i = 0; i < self.body.length; i++) {
- length += self.body[i].length
- }
- } else {
- self.body = new Buffer(self.body)
- length = self.body.length
+ if (options.json) {
+ self.json(options.json)
+ } else if (options.multipart) {
+ self.boundary = uuid()
+ self.multipart(options.multipart)
+ }
+
+ if (self.body) {
+ var length = 0
+ if (!Buffer.isBuffer(self.body)) {
+ if (Array.isArray(self.body)) {
+ for (var i = 0; i < self.body.length; i++) {
+ length += self.body[i].length
}
} else {
+ self.body = new Buffer(self.body)
length = self.body.length
}
- if (length) {
- if (!self.hasHeader('content-length')) self.setHeader('content-length', length)
- } else {
- throw new Error('Argument error, options.body.')
+ } else {
+ length = self.body.length
+ }
+ if (length) {
+ if (!self.hasHeader('content-length')) {
+ self.setHeader('content-length', length)
}
+ } else {
+ throw new Error('Argument error, options.body.')
}
+ }
- var protocol = self.proxy && !self.tunnel ? self.proxy.protocol : self.uri.protocol
- , defaultModules = {'http:':http, 'https:':https, 'unix:':http}
- , httpModules = self.httpModules || {}
- ;
- self.httpModule = httpModules[protocol] || defaultModules[protocol]
+ var protocol = self.proxy && !self.tunnel ? self.proxy.protocol : self.uri.protocol
+ , defaultModules = {'http:':http, 'https:':https}
+ , httpModules = self.httpModules || {}
- if (!self.httpModule) return this.emit('error', new Error("Invalid protocol: " + protocol))
+ self.httpModule = httpModules[protocol] || defaultModules[protocol]
- if (options.ca) self.ca = options.ca
+ if (!self.httpModule) {
+ return self.emit('error', new Error('Invalid protocol: ' + protocol))
+ }
- if (!self.agent) {
- if (options.agentOptions) self.agentOptions = options.agentOptions
+ if (options.ca) {
+ self.ca = options.ca
+ }
- if (options.agentClass) {
- self.agentClass = options.agentClass
- } else if (options.forever) {
- self.agentClass = protocol === 'http:' ? ForeverAgent : ForeverAgent.SSL
- } else {
- self.agentClass = self.httpModule.Agent
- }
+ if (!self.agent) {
+ if (options.agentOptions) {
+ self.agentOptions = options.agentOptions
}
- if (self.pool === false) {
- self.agent = false
+ if (options.agentClass) {
+ self.agentClass = options.agentClass
+ } else if (options.forever) {
+ self.agentClass = protocol === 'http:' ? ForeverAgent : ForeverAgent.SSL
} else {
- self.agent = self.agent || self.getAgent()
- if (self.maxSockets) {
- // Don't use our pooling if node has the refactored client
- self.agent.maxSockets = self.maxSockets
- }
- if (self.pool.maxSockets) {
- // Don't use our pooling if node has the refactored client
- self.agent.maxSockets = self.pool.maxSockets
- }
+ self.agentClass = self.httpModule.Agent
}
+ }
- self.on('pipe', function (src) {
- if (self.ntick && self._started) throw new Error("You cannot pipe to this stream after the outbound request has started.")
- self.src = src
- if (isReadStream(src)) {
- if (!self.hasHeader('content-type')) self.setHeader('content-type', mime.lookup(src.path))
- } else {
- if (src.headers) {
- for (var i in src.headers) {
- if (!self.hasHeader(i)) {
- self.setHeader(i, src.headers[i])
- }
- }
- }
- if (self._json && !self.hasHeader('content-type'))
- self.setHeader('content-type', 'application/json')
- if (src.method && !self.explicitMethod) {
- self.method = src.method
- }
- }
-
- // self.on('pipe', function () {
- // console.error("You have already piped to this stream. Pipeing twice is likely to break the request.")
- // })
- })
-
- process.nextTick(function () {
- if (self._aborted) return
+ if (self.pool === false) {
+ self.agent = false
+ } else {
+ self.agent = self.agent || self.getAgent()
+ if (self.maxSockets) {
+ // Don't use our pooling if node has the refactored client
+ self.agent.maxSockets = self.maxSockets
+ }
+ if (self.pool.maxSockets) {
+ // Don't use our pooling if node has the refactored client
+ self.agent.maxSockets = self.pool.maxSockets
+ }
+ }
- var end = function () {
- if (self._form) {
- self._form.pipe(self)
- }
- if (self.body) {
- if (Array.isArray(self.body)) {
- self.body.forEach(function (part) {
- self.write(part)
- })
- } else {
- self.write(self.body)
- }
- self.end()
- } else if (self.requestBodyStream) {
- console.warn("options.requestBodyStream is deprecated, please pass the request object to stream.pipe.")
- self.requestBodyStream.pipe(self)
- } else if (!self.src) {
- if (self.method !== 'GET' && typeof self.method !== 'undefined') {
- self.setHeader('content-length', 0)
+ self.on('pipe', function (src) {
+ if (self.ntick && self._started) {
+ throw new Error('You cannot pipe to this stream after the outbound request has started.')
+ }
+ self.src = src
+ if (isReadStream(src)) {
+ if (!self.hasHeader('content-type')) {
+ self.setHeader('content-type', mime.lookup(src.path))
+ }
+ } else {
+ if (src.headers) {
+ for (var i in src.headers) {
+ if (!self.hasHeader(i)) {
+ self.setHeader(i, src.headers[i])
}
- self.end()
}
}
-
- if (self._form && !self.hasHeader('content-length')) {
- // Before ending the request, we had to compute the length of the whole form, asyncly
- self.setHeader(self._form.getHeaders())
- self._form.getLength(function (err, length) {
- if (!err) {
- self.setHeader('content-length', length)
- }
- end()
- })
- } else {
- end()
+ if (self._json && !self.hasHeader('content-type')) {
+ self.setHeader('content-type', 'application/json')
+ }
+ if (src.method && !self.explicitMethod) {
+ self.method = src.method
}
-
- self.ntick = true
- })
-
- } // End _buildRequest
-
- self._handleUnixSocketURI = function(self){
- // Parse URI and extract a socket path (tested as a valid socket using net.connect), and a http style path suffix
- // Thus http requests can be made to a socket using the uri unix://tmp/my.socket/urlpath
- // and a request for '/urlpath' will be sent to the unix socket at /tmp/my.socket
-
- self.unixsocket = true;
-
- var full_path = self.uri.href.replace(self.uri.protocol+'/', '');
-
- var lookup = full_path.split('/');
- var error_connecting = true;
-
- var lookup_table = {};
- do { lookup_table[lookup.join('/')]={} } while(lookup.pop())
- for (r in lookup_table){
- try_next(r);
- }
-
- function try_next(table_row){
- var client = net.connect( table_row );
- client.path = table_row
- client.on('error', function(){ lookup_table[this.path].error_connecting=true; this.end(); });
- client.on('connect', function(){ lookup_table[this.path].error_connecting=false; this.end(); });
- table_row.client = client;
}
- wait_for_socket_response();
-
- response_counter = 0;
+ // self.on('pipe', function () {
+ // console.error('You have already piped to this stream. Pipeing twice is likely to break the request.')
+ // })
+ })
- function wait_for_socket_response(){
- var detach;
- if('undefined' == typeof setImmediate ) detach = process.nextTick
- else detach = setImmediate;
- detach(function(){
- // counter to prevent infinite blocking waiting for an open socket to be found.
- response_counter++;
- var trying = false;
- for (r in lookup_table){
- if('undefined' == typeof lookup_table[r].error_connecting)
- trying = true;
- }
- if(trying && response_counter<1000)
- wait_for_socket_response()
- else
- set_socket_properties();
- })
+ defer(function () {
+ if (self._aborted) {
+ return
}
- function set_socket_properties(){
- var host;
- for (r in lookup_table){
- if(lookup_table[r].error_connecting === false){
- host = r
- }
+ var end = function () {
+ if (self._form) {
+ self._form.pipe(self)
}
- if(!host){
- self.emit('error', new Error("Failed to connect to any socket in "+full_path))
+ if (self.body) {
+ if (Array.isArray(self.body)) {
+ self.body.forEach(function (part) {
+ self.write(part)
+ })
+ } else {
+ self.write(self.body)
+ }
+ self.end()
+ } else if (self.requestBodyStream) {
+ console.warn('options.requestBodyStream is deprecated, please pass the request object to stream.pipe.')
+ self.requestBodyStream.pipe(self)
+ } else if (!self.src) {
+ if (self.method !== 'GET' && typeof self.method !== 'undefined') {
+ self.setHeader('content-length', 0)
+ }
+ self.end()
}
- var path = full_path.replace(host, '')
+ }
- self.socketPath = host
- self.uri.pathname = path
- self.uri.href = path
- self.uri.path = path
- self.host = ''
- self.hostname = ''
- delete self.host
- delete self.hostname
- self._buildRequest();
+ if (self._form && !self.hasHeader('content-length')) {
+ // Before ending the request, we had to compute the length of the whole form, asyncly
+ self.setHeader(self._form.getHeaders())
+ self._form.getLength(function (err, length) {
+ if (!err) {
+ self.setHeader('content-length', length)
+ }
+ end()
+ })
+ } else {
+ end()
}
- }
- // Intercept UNIX protocol requests to change properties to match socket
- if(/^unix:/.test(self.uri.protocol)){
- self._handleUnixSocketURI(self);
- } else {
- self._buildRequest();
- }
+ self.ntick = true
+ })
}
@@ -650,7 +733,9 @@
// previously was doing http, now doing https
// if it's https, then we might need to tunnel now.
if (self.proxy) {
- if (self.setupTunnel()) return
+ if (self.setupTunnel()) {
+ return
+ }
}
self.httpModule = https
@@ -667,7 +752,9 @@
}
// if there's an agent, we need to get a new one.
- if (self.agent) self.agent = self.getAgent()
+ if (self.agent) {
+ self.agent = self.getAgent()
+ }
} else {
// previously was doing https, now doing http
@@ -693,85 +780,114 @@
}
Request.prototype.getAgent = function () {
- var Agent = this.agentClass
+ var self = this
+ var Agent = self.agentClass
var options = {}
- if (this.agentOptions) {
- for (var i in this.agentOptions) {
- options[i] = this.agentOptions[i]
+ if (self.agentOptions) {
+ for (var i in self.agentOptions) {
+ options[i] = self.agentOptions[i]
}
}
- if (this.ca) options.ca = this.ca
- if (this.ciphers) options.ciphers = this.ciphers
- if (this.secureProtocol) options.secureProtocol = this.secureProtocol
- if (this.secureOptions) options.secureOptions = this.secureOptions
- if (typeof this.rejectUnauthorized !== 'undefined') options.rejectUnauthorized = this.rejectUnauthorized
-
- if (this.cert && this.key) {
- options.key = this.key
- options.cert = this.cert
+ if (self.ca) {
+ options.ca = self.ca
+ }
+ if (self.ciphers) {
+ options.ciphers = self.ciphers
+ }
+ if (self.secureProtocol) {
+ options.secureProtocol = self.secureProtocol
+ }
+ if (self.secureOptions) {
+ options.secureOptions = self.secureOptions
+ }
+ if (typeof self.rejectUnauthorized !== 'undefined') {
+ options.rejectUnauthorized = self.rejectUnauthorized
+ }
+
+ if (self.cert && self.key) {
+ options.key = self.key
+ options.cert = self.cert
}
var poolKey = ''
// different types of agents are in different pools
- if (Agent !== this.httpModule.Agent) {
+ if (Agent !== self.httpModule.Agent) {
poolKey += Agent.name
}
- if (!this.httpModule.globalAgent) {
+ if (!self.httpModule.globalAgent) {
// node 0.4.x
- options.host = this.host
- options.port = this.port
- if (poolKey) poolKey += ':'
- poolKey += this.host + ':' + this.port
+ options.host = self.host
+ options.port = self.port
+ if (poolKey) {
+ poolKey += ':'
+ }
+ poolKey += self.host + ':' + self.port
}
// ca option is only relevant if proxy or destination are https
- var proxy = this.proxy
- if (typeof proxy === 'string') proxy = url.parse(proxy)
+ var proxy = self.proxy
+ if (typeof proxy === 'string') {
+ proxy = url.parse(proxy)
+ }
var isHttps = (proxy && proxy.protocol === 'https:') || this.uri.protocol === 'https:'
+
if (isHttps) {
if (options.ca) {
- if (poolKey) poolKey += ':'
+ if (poolKey) {
+ poolKey += ':'
+ }
poolKey += options.ca
}
if (typeof options.rejectUnauthorized !== 'undefined') {
- if (poolKey) poolKey += ':'
+ if (poolKey) {
+ poolKey += ':'
+ }
poolKey += options.rejectUnauthorized
}
- if (options.cert)
+ if (options.cert) {
poolKey += options.cert.toString('ascii') + options.key.toString('ascii')
+ }
if (options.ciphers) {
- if (poolKey) poolKey += ':'
+ if (poolKey) {
+ poolKey += ':'
+ }
poolKey += options.ciphers
}
if (options.secureProtocol) {
- if (poolKey) poolKey += ':'
+ if (poolKey) {
+ poolKey += ':'
+ }
poolKey += options.secureProtocol
}
if (options.secureOptions) {
- if (poolKey) poolKey += ':'
+ if (poolKey) {
+ poolKey += ':'
+ }
poolKey += options.secureOptions
}
}
- if (this.pool === globalPool && !poolKey && Object.keys(options).length === 0 && this.httpModule.globalAgent) {
+ if (self.pool === globalPool && !poolKey && Object.keys(options).length === 0 && self.httpModule.globalAgent) {
// not doing anything special. Use the globalAgent
- return this.httpModule.globalAgent
+ return self.httpModule.globalAgent
}
// we're using a stored agent. Make sure it's protocol-specific
- poolKey = this.uri.protocol + poolKey
+ poolKey = self.uri.protocol + poolKey
- // already generated an agent for this setting
- if (this.pool[poolKey]) return this.pool[poolKey]
+ // generate a new agent for this setting if none yet exists
+ if (!self.pool[poolKey]) {
+ self.pool[poolKey] = new Agent(options)
+ }
- return this.pool[poolKey] = new Agent(options)
+ return self.pool[poolKey]
}
Request.prototype.start = function () {
@@ -779,7 +895,9 @@
// this is usually called on the first write(), end() or on nextTick()
var self = this
- if (self._aborted) return
+ if (self._aborted) {
+ return
+ }
self._started = true
self.method = self.method || 'GET'
@@ -798,14 +916,14 @@
delete reqOptions.auth
debug('make request', self.uri.href)
- self.req = self.httpModule.request(reqOptions, self.onResponse.bind(self))
+ self.req = self.httpModule.request(reqOptions)
if (self.timeout && !self.timeoutTimer) {
self.timeoutTimer = setTimeout(function () {
- self.req.abort()
- var e = new Error("ETIMEDOUT")
- e.code = "ETIMEDOUT"
- self.emit("error", e)
+ self.abort()
+ var e = new Error('ETIMEDOUT')
+ e.code = 'ETIMEDOUT'
+ self.emit('error', e)
}, self.timeout)
// Set additional timeout on socket - in case if remote
@@ -814,43 +932,73 @@
self.req.setTimeout(self.timeout, function () {
if (self.req) {
self.req.abort()
- var e = new Error("ESOCKETTIMEDOUT")
- e.code = "ESOCKETTIMEDOUT"
- self.emit("error", e)
+ var e = new Error('ESOCKETTIMEDOUT')
+ e.code = 'ESOCKETTIMEDOUT'
+ self.emit('error', e)
}
})
}
}
- self.req.on('error', self.clientErrorHandler)
+ self.req.on('response', self.onRequestResponse.bind(self))
+ self.req.on('error', self.onRequestError.bind(self))
self.req.on('drain', function() {
self.emit('drain')
})
+ self.req.on('socket', function(socket) {
+ self.emit('socket', socket)
+ })
+
self.on('end', function() {
- if ( self.req.connection ) self.req.connection.removeListener('error', self._parserErrorHandler)
+ if ( self.req.connection ) {
+ self.req.connection.removeListener('error', connectionErrorHandler)
+ }
})
self.emit('request', self.req)
}
-Request.prototype.onResponse = function (response) {
+
+Request.prototype.onRequestError = function (error) {
var self = this
- debug('onResponse', self.uri.href, response.statusCode, response.headers)
+ if (self._aborted) {
+ return
+ }
+ if (self.req && self.req._reusedSocket && error.code === 'ECONNRESET'
+ && self.agent.addRequestNoreuse) {
+ self.agent = { addRequest: self.agent.addRequestNoreuse.bind(self.agent) }
+ self.start()
+ self.req.end()
+ return
+ }
+ if (self.timeout && self.timeoutTimer) {
+ clearTimeout(self.timeoutTimer)
+ self.timeoutTimer = null
+ }
+ self.emit('error', error)
+}
+
+Request.prototype.onRequestResponse = function (response) {
+ var self = this
+ debug('onRequestResponse', self.uri.href, response.statusCode, response.headers)
response.on('end', function() {
debug('response end', self.uri.href, response.statusCode, response.headers)
- });
+ })
// The check on response.connection is a workaround for browserify.
- if (response.connection && response.connection.listeners('error').indexOf(self._parserErrorHandler) === -1) {
+ if (response.connection && response.connection.listeners('error').indexOf(connectionErrorHandler) === -1) {
response.connection.setMaxListeners(0)
- response.connection.once('error', self._parserErrorHandler)
+ response.connection.once('error', connectionErrorHandler)
}
if (self._aborted) {
debug('aborted', self.uri.href)
response.resume()
return
}
- if (self._paused) response.pause()
- // Check that response.resume is defined. Workaround for browserify.
- else response.resume && response.resume()
+ if (self._paused) {
+ response.pause()
+ } else if (response.resume) {
+ // response.resume should be defined, but check anyway before calling. Workaround for browserify.
+ response.resume()
+ }
self.response = response
response.request = self
@@ -861,24 +1009,29 @@
self.strictSSL && (!response.hasOwnProperty('client') ||
!response.client.authorized)) {
debug('strict ssl error', self.uri.href)
- var sslErr = response.hasOwnProperty('client') ? response.client.authorizationError : self.uri.href + " does not support SSL";
- self.emit('error', new Error('SSL Error: '+ sslErr))
+ var sslErr = response.hasOwnProperty('client') ? response.client.authorizationError : self.uri.href + ' does not support SSL'
+ self.emit('error', new Error('SSL Error: ' + sslErr))
return
}
- if (self.setHost) self.removeHeader('host')
+ // Save the original host before any redirect (if it changes, we need to
+ // remove any authorization headers)
+ self.originalHost = self.headers.host
+ if (self.setHost) {
+ self.removeHeader('host')
+ }
if (self.timeout && self.timeoutTimer) {
clearTimeout(self.timeoutTimer)
self.timeoutTimer = null
}
- var targetCookieJar = (self._jar && self._jar.setCookie)?self._jar:globalCookieJar;
+ var targetCookieJar = (self._jar && self._jar.setCookie) ? self._jar : globalCookieJar
var addCookie = function (cookie) {
//set the cookie if it's domain in the href's domain.
try {
- targetCookieJar.setCookie(cookie, self.uri.href, {ignoreError: true});
+ targetCookieJar.setCookie(cookie, self.uri.href, {ignoreError: true})
} catch (e) {
- self.emit('error', e);
+ self.emit('error', e)
}
}
@@ -886,8 +1039,11 @@
if (response.caseless.has('set-cookie') && (!self._disableCookies)) {
var headerName = response.caseless.has('set-cookie')
- if (Array.isArray(response.headers[headerName])) response.headers[headerName].forEach(addCookie)
- else addCookie(response.headers[headerName])
+ if (Array.isArray(response.headers[headerName])) {
+ response.headers[headerName].forEach(addCookie)
+ } else {
+ addCookie(response.headers[headerName])
+ }
}
var redirectTo = null
@@ -897,7 +1053,7 @@
if (self.followAllRedirects) {
redirectTo = location
- } else if (self.followRedirect) {
+ } else if (self.followRedirects) {
switch (self.method) {
case 'PATCH':
case 'PUT':
@@ -910,7 +1066,7 @@
break
}
}
- } else if (response.statusCode == 401 && self._hasAuth && !self._sentAuth) {
+ } else if (response.statusCode === 401 && self._hasAuth && !self._sentAuth) {
var authHeader = response.caseless.get('www-authenticate')
var authVerb = authHeader && authHeader.split(' ')[0].toLowerCase()
debug('reauth', authVerb)
@@ -943,8 +1099,10 @@
var re = /([a-z0-9_-]+)=(?:"([^"]+)"|([a-z0-9_-]+))/gi
for (;;) {
var match = re.exec(authHeader)
- if (!match) break
- challenge[match[1]] = match[2] || match[3];
+ if (!match) {
+ break
+ }
+ challenge[match[1]] = match[2] || match[3]
}
var ha1 = md5(self._user + ':' + challenge.realm + ':' + self._pass)
@@ -968,12 +1126,12 @@
authHeader = []
for (var k in authValues) {
- if (!authValues[k]) {
- //ignore
- } else if (k === 'qop' || k === 'nc' || k === 'algorithm') {
- authHeader.push(k + '=' + authValues[k])
- } else {
- authHeader.push(k + '="' + authValues[k] + '"')
+ if (authValues[k]) {
+ if (k === 'qop' || k === 'nc' || k === 'algorithm') {
+ authHeader.push(k + '=' + authValues[k])
+ } else {
+ authHeader.push(k + '="' + authValues[k] + '"')
+ }
}
}
authHeader = 'Digest ' + authHeader.join(', ')
@@ -990,10 +1148,12 @@
// ignore any potential response body. it cannot possibly be useful
// to us at this point.
- if (self._paused) response.resume()
+ if (self._paused) {
+ response.resume()
+ }
if (self._redirectsFollowed >= self.maxRedirects) {
- self.emit('error', new Error("Exceeded maxRedirects. Probably stuck in a redirect loop "+self.uri.href))
+ self.emit('error', new Error('Exceeded maxRedirects. Probably stuck in a redirect loop ' + self.uri.href))
return
}
self._redirectsFollowed += 1
@@ -1015,13 +1175,15 @@
, redirectUri: redirectTo
}
)
- if (self.followAllRedirects && response.statusCode != 401 && response.statusCode != 307) self.method = 'GET'
+ if (self.followAllRedirects && response.statusCode !== 401 && response.statusCode !== 307) {
+ self.method = 'GET'
+ }
// self.method = 'GET' // Force all redirects to use GET || commented out fixes #215
delete self.src
delete self.req
delete self.agent
delete self._started
- if (response.statusCode != 401 && response.statusCode != 307) {
+ if (response.statusCode !== 401 && response.statusCode !== 307) {
// Remove parameters from the previous response, unless this is the second request
// for a server that requires digest authentication.
delete self.body
@@ -1030,10 +1192,16 @@
self.removeHeader('host')
self.removeHeader('content-type')
self.removeHeader('content-length')
+ if (self.uri.hostname !== self.originalHost.split(':')[0]) {
+ // Remove authorization if changing hostnames (but not if just
+ // changing ports or protocols). This matches the behavior of curl:
+ // https://github.com/bagder/curl/blob/6beb0eee/lib/http.c#L710
+ self.removeHeader('authorization')
+ }
}
}
- self.emit('redirect');
+ self.emit('redirect')
self.init()
return // Ignore the rest of the response
@@ -1042,7 +1210,9 @@
// Be a good stream and emit end when the response is finished.
// Hack to emit end on close because of a core bug that never fires end
response.on('close', function () {
- if (!self._ended) self.response.emit('end')
+ if (!self._ended) {
+ self.response.emit('end')
+ }
})
response.on('end', function () {
@@ -1051,17 +1221,17 @@
var dataStream
if (self.gzip) {
- var contentEncoding = response.headers["content-encoding"] || "identity"
+ var contentEncoding = response.headers['content-encoding'] || 'identity'
contentEncoding = contentEncoding.trim().toLowerCase()
- if (contentEncoding === "gzip") {
+ if (contentEncoding === 'gzip') {
dataStream = zlib.createGunzip()
response.pipe(dataStream)
} else {
// Since previous versions didn't check for Content-Encoding header,
// ignore any invalid values to preserve backwards-compatibility
- if (contentEncoding !== "identity") {
- debug("ignoring unrecognized Content-Encoding " + contentEncoding)
+ if (contentEncoding !== 'identity') {
+ debug('ignoring unrecognized Content-Encoding ' + contentEncoding)
}
dataStream = response
}
@@ -1071,7 +1241,7 @@
if (self.encoding) {
if (self.dests.length !== 0) {
- console.error("Ignoring encoding parameter as this stream is being piped to another stream which makes the encoding option invalid.")
+ console.error('Ignoring encoding parameter as this stream is being piped to another stream which makes the encoding option invalid.')
} else if (dataStream.setEncoding) {
dataStream.setEncoding(self.encoding)
} else {
@@ -1088,24 +1258,30 @@
self.pipeDest(dest)
})
- dataStream.on("data", function (chunk) {
+ dataStream.on('data', function (chunk) {
self._destdata = true
- self.emit("data", chunk)
+ self.emit('data', chunk)
})
- dataStream.on("end", function (chunk) {
- self.emit("end", chunk)
+ dataStream.on('end', function (chunk) {
+ self.emit('end', chunk)
})
- dataStream.on("close", function () {self.emit("close")})
+ dataStream.on('error', function (error) {
+ self.emit('error', error)
+ })
+ dataStream.on('close', function () {self.emit('close')})
if (self.callback) {
var buffer = bl()
, strings = []
- ;
- self.on("data", function (chunk) {
- if (Buffer.isBuffer(chunk)) buffer.append(chunk)
- else strings.push(chunk)
+
+ self.on('data', function (chunk) {
+ if (Buffer.isBuffer(chunk)) {
+ buffer.append(chunk)
+ } else {
+ strings.push(chunk)
+ }
})
- self.on("end", function () {
+ self.on('end', function () {
debug('end event', self.uri.href)
if (self._aborted) {
debug('aborted', self.uri.href)
@@ -1124,7 +1300,7 @@
} else if (strings.length) {
// The UTF8 BOM [0xEF,0xBB,0xBF] is converted to [0xFE,0xFF] in the JS UTC16/UCS2 representation.
// Strip this value out when the encoding is set to 'utf8', as upstream consumers won't expect it and it breaks JSON.parse().
- if (self.encoding === 'utf8' && strings[0].length > 0 && strings[0][0] === "\uFEFF") {
+ if (self.encoding === 'utf8' && strings[0].length > 0 && strings[0][0] === '\uFEFF') {
strings[0] = strings[0].substring(1)
}
response.body = strings.join('')
@@ -1136,96 +1312,112 @@
} catch (e) {}
}
debug('emitting complete', self.uri.href)
- if(response.body == undefined && !self._json) {
- response.body = "";
+ if(typeof response.body === 'undefined' && !self._json) {
+ response.body = ''
}
self.emit('complete', response, response.body)
})
}
//if no callback
else{
- self.on("end", function () {
+ self.on('end', function () {
if (self._aborted) {
debug('aborted', self.uri.href)
return
}
- self.emit('complete', response);
- });
+ self.emit('complete', response)
+ })
}
}
debug('finish init function', self.uri.href)
}
Request.prototype.abort = function () {
- this._aborted = true
+ var self = this
+ self._aborted = true
- if (this.req) {
- this.req.abort()
+ if (self.req) {
+ self.req.abort()
}
- else if (this.response) {
- this.response.abort()
+ else if (self.response) {
+ self.response.abort()
}
- this.emit("abort")
+ self.emit('abort')
}
Request.prototype.pipeDest = function (dest) {
- var response = this.response
+ var self = this
+ var response = self.response
// Called after the response is received
if (dest.headers && !dest.headersSent) {
if (response.caseless.has('content-type')) {
var ctname = response.caseless.has('content-type')
- if (dest.setHeader) dest.setHeader(ctname, response.headers[ctname])
- else dest.headers[ctname] = response.headers[ctname]
+ if (dest.setHeader) {
+ dest.setHeader(ctname, response.headers[ctname])
+ }
+ else {
+ dest.headers[ctname] = response.headers[ctname]
+ }
}
if (response.caseless.has('content-length')) {
var clname = response.caseless.has('content-length')
- if (dest.setHeader) dest.setHeader(clname, response.headers[clname])
- else dest.headers[clname] = response.headers[clname]
+ if (dest.setHeader) {
+ dest.setHeader(clname, response.headers[clname])
+ } else {
+ dest.headers[clname] = response.headers[clname]
+ }
}
}
if (dest.setHeader && !dest.headersSent) {
for (var i in response.headers) {
// If the response content is being decoded, the Content-Encoding header
// of the response doesn't represent the piped content, so don't pass it.
- if (!this.gzip || i !== 'content-encoding') {
+ if (!self.gzip || i !== 'content-encoding') {
dest.setHeader(i, response.headers[i])
}
}
dest.statusCode = response.statusCode
}
- if (this.pipefilter) this.pipefilter(response, dest)
+ if (self.pipefilter) {
+ self.pipefilter(response, dest)
+ }
}
Request.prototype.qs = function (q, clobber) {
+ var self = this
var base
- if (!clobber && this.uri.query) base = qs.parse(this.uri.query)
- else base = {}
+ if (!clobber && self.uri.query) {
+ base = self.qsLib.parse(self.uri.query)
+ } else {
+ base = {}
+ }
for (var i in q) {
base[i] = q[i]
}
- if (qs.stringify(base) === ''){
- return this
+ if (self.qsLib.stringify(base) === ''){
+ return self
}
- this.uri = url.parse(this.uri.href.split('?')[0] + '?' + qs.stringify(base))
- this.url = this.uri
- this.path = this.uri.path
+ self.uri = url.parse(self.uri.href.split('?')[0] + '?' + self.qsLib.stringify(base))
+ self.url = self.uri
+ self.path = self.uri.path
- return this
+ return self
}
Request.prototype.form = function (form) {
+ var self = this
if (form) {
- this.setHeader('content-type', 'application/x-www-form-urlencoded; charset=utf-8')
- this.body = (typeof form === 'string') ? form.toString('utf8') : qs.stringify(form).toString('utf8')
- return this
+ self.setHeader('content-type', 'application/x-www-form-urlencoded')
+ self.body = (typeof form === 'string') ? form.toString('utf8') : self.qsLib.stringify(form).toString('utf8')
+ return self
}
// create form-data object
- this._form = new FormData()
- return this._form
+ self._form = new FormData()
+ return self._form
}
Request.prototype.multipart = function (multipart) {
var self = this
@@ -1234,11 +1426,13 @@
if (!self.hasHeader('content-type')) {
self.setHeader('content-type', 'multipart/related; boundary=' + self.boundary)
} else {
- var headerName = self.hasHeader('content-type');
+ var headerName = self.hasHeader('content-type')
self.setHeader(headerName, self.headers[headerName].split(';')[0] + '; boundary=' + self.boundary)
}
- if (!multipart.forEach) throw new Error('Argument error, options.multipart.')
+ if (!multipart.forEach) {
+ throw new Error('Argument error, options.multipart.')
+ }
if (self.preambleCRLF) {
self.body.push(new Buffer('\r\n'))
@@ -1246,7 +1440,9 @@
multipart.forEach(function (part) {
var body = part.body
- if(body == null) throw Error('Body attribute missing in multipart.')
+ if(typeof body === 'undefined') {
+ throw new Error('Body attribute missing in multipart.')
+ }
delete part.body
var preamble = '--' + self.boundary + '\r\n'
Object.keys(part).forEach(function (key) {
@@ -1258,85 +1454,104 @@
self.body.push(new Buffer('\r\n'))
})
self.body.push(new Buffer('--' + self.boundary + '--'))
+
+ if (self.postambleCRLF) {
+ self.body.push(new Buffer('\r\n'))
+ }
+
return self
}
Request.prototype.json = function (val) {
var self = this
- if (!self.hasHeader('accept')) self.setHeader('accept', 'application/json')
+ if (!self.hasHeader('accept')) {
+ self.setHeader('accept', 'application/json')
+ }
- this._json = true
+ self._json = true
if (typeof val === 'boolean') {
- if (typeof this.body === 'object') {
- this.body = safeStringify(this.body)
- if (!self.hasHeader('content-type'))
+ if (typeof self.body === 'object') {
+ self.body = safeStringify(self.body)
+ if (!self.hasHeader('content-type')) {
self.setHeader('content-type', 'application/json')
+ }
}
} else {
- this.body = safeStringify(val)
- if (!self.hasHeader('content-type'))
+ self.body = safeStringify(val)
+ if (!self.hasHeader('content-type')) {
self.setHeader('content-type', 'application/json')
+ }
}
- return this
+ return self
}
Request.prototype.getHeader = function (name, headers) {
+ var self = this
var result, re, match
- if (!headers) headers = this.headers
+ if (!headers) {
+ headers = self.headers
+ }
Object.keys(headers).forEach(function (key) {
- if (key.length !== name.length) return
+ if (key.length !== name.length) {
+ return
+ }
re = new RegExp(name, 'i')
match = key.match(re)
- if (match) result = headers[key]
+ if (match) {
+ result = headers[key]
+ }
})
return result
}
var getHeader = Request.prototype.getHeader
Request.prototype.auth = function (user, pass, sendImmediately, bearer) {
+ var self = this
if (bearer !== undefined) {
- this._bearer = bearer
- this._hasAuth = true
- if (sendImmediately || typeof sendImmediately == 'undefined') {
+ self._bearer = bearer
+ self._hasAuth = true
+ if (sendImmediately || typeof sendImmediately === 'undefined') {
if (typeof bearer === 'function') {
bearer = bearer()
}
- this.setHeader('authorization', 'Bearer ' + bearer)
- this._sentAuth = true
+ self.setHeader('authorization', 'Bearer ' + bearer)
+ self._sentAuth = true
}
- return this
+ return self
}
if (typeof user !== 'string' || (pass !== undefined && typeof pass !== 'string')) {
throw new Error('auth() received invalid user or password')
}
- this._user = user
- this._pass = pass
- this._hasAuth = true
+ self._user = user
+ self._pass = pass
+ self._hasAuth = true
var header = typeof pass !== 'undefined' ? user + ':' + pass : user
- if (sendImmediately || typeof sendImmediately == 'undefined') {
- this.setHeader('authorization', 'Basic ' + toBase64(header))
- this._sentAuth = true
+ if (sendImmediately || typeof sendImmediately === 'undefined') {
+ self.setHeader('authorization', 'Basic ' + toBase64(header))
+ self._sentAuth = true
}
- return this
+ return self
}
Request.prototype.aws = function (opts, now) {
+ var self = this
+
if (!now) {
- this._aws = opts
- return this
+ self._aws = opts
+ return self
}
var date = new Date()
- this.setHeader('date', date.toUTCString())
+ self.setHeader('date', date.toUTCString())
var auth =
{ key: opts.key
, secret: opts.secret
- , verb: this.method.toUpperCase()
+ , verb: self.method.toUpperCase()
, date: date
- , contentType: this.getHeader('content-type') || ''
- , md5: this.getHeader('content-md5') || ''
- , amazonHeaders: aws.canonicalizeHeaders(this.headers)
+ , contentType: self.getHeader('content-type') || ''
+ , md5: self.getHeader('content-md5') || ''
+ , amazonHeaders: aws.canonicalizeHeaders(self.headers)
}
- var path = this.uri.path;
+ var path = self.uri.path
if (opts.bucket && path) {
auth.resource = '/' + opts.bucket + path
} else if (opts.bucket && !path) {
@@ -1347,50 +1562,61 @@
auth.resource = '/'
}
auth.resource = aws.canonicalizeResource(auth.resource)
- this.setHeader('authorization', aws.authorization(auth))
+ self.setHeader('authorization', aws.authorization(auth))
- return this
+ return self
}
Request.prototype.httpSignature = function (opts) {
- var req = this
+ var self = this
httpSignature.signRequest({
getHeader: function(header) {
- return getHeader(header, req.headers)
+ return getHeader(header, self.headers)
},
setHeader: function(header, value) {
- req.setHeader(header, value)
+ self.setHeader(header, value)
},
- method: this.method,
- path: this.path
+ method: self.method,
+ path: self.path
}, opts)
- debug('httpSignature authorization', this.getHeader('authorization'))
+ debug('httpSignature authorization', self.getHeader('authorization'))
- return this
+ return self
}
Request.prototype.hawk = function (opts) {
- this.setHeader('Authorization', hawk.client.header(this.uri, this.method, opts).field)
+ var self = this
+ self.setHeader('Authorization', hawk.client.header(self.uri, self.method, opts).field)
}
Request.prototype.oauth = function (_oauth) {
+ var self = this
var form, query
- if (this.hasHeader('content-type') &&
- this.getHeader('content-type').slice(0, 'application/x-www-form-urlencoded'.length) ===
+ if (self.hasHeader('content-type') &&
+ self.getHeader('content-type').slice(0, 'application/x-www-form-urlencoded'.length) ===
'application/x-www-form-urlencoded'
) {
- form = this.body
+ form = self.body
}
- if (this.uri.query) {
- query = this.uri.query
+ if (self.uri.query) {
+ query = self.uri.query
}
var oa = {}
- for (var i in _oauth) oa['oauth_'+i] = _oauth[i]
- if ('oauth_realm' in oa) delete oa.oauth_realm
-
- if (!oa.oauth_version) oa.oauth_version = '1.0'
- if (!oa.oauth_timestamp) oa.oauth_timestamp = Math.floor( Date.now() / 1000 ).toString()
- if (!oa.oauth_nonce) oa.oauth_nonce = uuid().replace(/-/g, '')
+ for (var i in _oauth) {
+ oa['oauth_' + i] = _oauth[i]
+ }
+ if ('oauth_realm' in oa) {
+ delete oa.oauth_realm
+ }
+ if (!oa.oauth_version) {
+ oa.oauth_version = '1.0'
+ }
+ if (!oa.oauth_timestamp) {
+ oa.oauth_timestamp = Math.floor( Date.now() / 1000 ).toString()
+ }
+ if (!oa.oauth_nonce) {
+ oa.oauth_nonce = uuid().replace(/-/g, '')
+ }
oa.oauth_signature_method = 'HMAC-SHA1'
@@ -1399,95 +1625,118 @@
var token_secret = oa.oauth_token_secret
delete oa.oauth_token_secret
- var baseurl = this.uri.protocol + '//' + this.uri.host + this.uri.pathname
- var params = qs.parse([].concat(query, form, qs.stringify(oa)).join('&'))
- var signature = oauth.hmacsign(this.method, baseurl, params, consumer_secret, token_secret)
+ var baseurl = self.uri.protocol + '//' + self.uri.host + self.uri.pathname
+ var params = self.qsLib.parse([].concat(query, form, self.qsLib.stringify(oa)).join('&'))
+ var signature = oauth.hmacsign(self.method, baseurl, params, consumer_secret, token_secret)
- var realm = _oauth.realm ? 'realm="' + _oauth.realm + '",' : '';
+ var realm = _oauth.realm ? 'realm="' + _oauth.realm + '",' : ''
var authHeader = 'OAuth ' + realm +
- Object.keys(oa).sort().map(function (i) {return i+'="'+oauth.rfc3986(oa[i])+'"'}).join(',')
+ Object.keys(oa).sort().map(function (i) {return i + '="' + oauth.rfc3986(oa[i]) + '"'}).join(',')
authHeader += ',oauth_signature="' + oauth.rfc3986(signature) + '"'
- this.setHeader('Authorization', authHeader)
- return this
+ self.setHeader('Authorization', authHeader)
+ return self
}
Request.prototype.jar = function (jar) {
+ var self = this
var cookies
- if (this._redirectsFollowed === 0) {
- this.originalCookieHeader = this.getHeader('cookie')
+ if (self._redirectsFollowed === 0) {
+ self.originalCookieHeader = self.getHeader('cookie')
}
if (!jar) {
// disable cookies
cookies = false
- this._disableCookies = true
+ self._disableCookies = true
} else {
- var targetCookieJar = (jar && jar.getCookieString)?jar:globalCookieJar;
- var urihref = this.uri.href
+ var targetCookieJar = (jar && jar.getCookieString) ? jar : globalCookieJar
+ var urihref = self.uri.href
//fetch cookie in the Specified host
if (targetCookieJar) {
- cookies = targetCookieJar.getCookieString(urihref);
+ cookies = targetCookieJar.getCookieString(urihref)
}
}
//if need cookie and cookie is not empty
if (cookies && cookies.length) {
- if (this.originalCookieHeader) {
+ if (self.originalCookieHeader) {
// Don't overwrite existing Cookie header
- this.setHeader('cookie', this.originalCookieHeader + '; ' + cookies)
+ self.setHeader('cookie', self.originalCookieHeader + '; ' + cookies)
} else {
- this.setHeader('cookie', cookies)
+ self.setHeader('cookie', cookies)
}
}
- this._jar = jar
- return this
+ self._jar = jar
+ return self
}
// Stream API
Request.prototype.pipe = function (dest, opts) {
- if (this.response) {
- if (this._destdata) {
- throw new Error("You cannot pipe after data has been emitted from the response.")
- } else if (this._ended) {
- throw new Error("You cannot pipe after the response has been ended.")
+ var self = this
+
+ if (self.response) {
+ if (self._destdata) {
+ throw new Error('You cannot pipe after data has been emitted from the response.')
+ } else if (self._ended) {
+ throw new Error('You cannot pipe after the response has been ended.')
} else {
- stream.Stream.prototype.pipe.call(this, dest, opts)
- this.pipeDest(dest)
+ stream.Stream.prototype.pipe.call(self, dest, opts)
+ self.pipeDest(dest)
return dest
}
} else {
- this.dests.push(dest)
- stream.Stream.prototype.pipe.call(this, dest, opts)
+ self.dests.push(dest)
+ stream.Stream.prototype.pipe.call(self, dest, opts)
return dest
}
}
Request.prototype.write = function () {
- if (!this._started) this.start()
- return this.req.write.apply(this.req, arguments)
+ var self = this
+ if (!self._started) {
+ self.start()
+ }
+ return self.req.write.apply(self.req, arguments)
}
Request.prototype.end = function (chunk) {
- if (chunk) this.write(chunk)
- if (!this._started) this.start()
- this.req.end()
+ var self = this
+ if (chunk) {
+ self.write(chunk)
+ }
+ if (!self._started) {
+ self.start()
+ }
+ self.req.end()
}
Request.prototype.pause = function () {
- if (!this.response) this._paused = true
- else this.response.pause.apply(this.response, arguments)
+ var self = this
+ if (!self.response) {
+ self._paused = true
+ } else {
+ self.response.pause.apply(self.response, arguments)
+ }
}
Request.prototype.resume = function () {
- if (!this.response) this._paused = false
- else this.response.resume.apply(this.response, arguments)
+ var self = this
+ if (!self.response) {
+ self._paused = false
+ } else {
+ self.response.resume.apply(self.response, arguments)
+ }
}
Request.prototype.destroy = function () {
- if (!this._ended) this.end()
- else if (this.response) this.response.destroy()
+ var self = this
+ if (!self._ended) {
+ self.end()
+ } else if (self.response) {
+ self.response.destroy()
+ }
}
-Request.prototype.toJSON = requestToJSON
-
Request.defaultProxyHeaderWhiteList =
defaultProxyHeaderWhiteList.slice()
+// Exports
+Request.prototype.toJSON = requestToJSON
module.exports = Request
diff -Nru nodejs-0.11.14/deps/npm/node_modules/request/.travis.yml nodejs-0.11.15/deps/npm/node_modules/request/.travis.yml
--- nodejs-0.11.14/deps/npm/node_modules/request/.travis.yml 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/request/.travis.yml 2015-01-20 21:22:17.000000000 +0000
@@ -2,11 +2,8 @@
node_js:
- "0.8"
- "0.10"
-
-env:
- - OPTIONALS=Y
- - OPTIONALS=N
-
-install:
- - if [[ "$OPTIONALS" == "Y" ]]; then npm install; fi
- - if [[ "$OPTIONALS" == "N" ]]; then npm install --no-optional; fi
+webhooks:
+ urls: https://webhooks.gitter.im/e/237280ed4796c19cc626
+ on_success: change # options: [always|never|change] default: always
+ on_failure: always # options: [always|never|change] default: always
+ on_start: false # default: false
diff -Nru nodejs-0.11.14/deps/npm/node_modules/retry/package.json nodejs-0.11.15/deps/npm/node_modules/retry/package.json
--- nodejs-0.11.14/deps/npm/node_modules/retry/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/retry/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -6,11 +6,11 @@
},
"name": "retry",
"description": "Abstraction for exponential and custom retry strategies for failed operations.",
- "version": "0.6.0",
+ "version": "0.6.1",
"homepage": "https://github.com/tim-kos/node-retry",
"repository": {
"type": "git",
- "url": "git://github.com/felixge/node-retry.git"
+ "url": "git://github.com/tim-kos/node-retry.git"
},
"directories": {
"lib": "./lib"
@@ -24,6 +24,26 @@
"fake": "0.2.0",
"far": "0.0.1"
},
- "_id": "retry@0.6.0",
- "_from": "retry"
+ "bugs": {
+ "url": "https://github.com/tim-kos/node-retry/issues"
+ },
+ "_id": "retry@0.6.1",
+ "_shasum": "fdc90eed943fde11b893554b8cc63d0e899ba918",
+ "_from": "retry@>=0.6.1 <0.7.0",
+ "_npmVersion": "1.4.9",
+ "_npmUser": {
+ "name": "tim-kos",
+ "email": "tim@debuggable.com"
+ },
+ "maintainers": [
+ {
+ "name": "tim-kos",
+ "email": "tim@debuggable.com"
+ }
+ ],
+ "dist": {
+ "shasum": "fdc90eed943fde11b893554b8cc63d0e899ba918",
+ "tarball": "http://registry.npmjs.org/retry/-/retry-0.6.1.tgz"
+ },
+ "_resolved": "https://registry.npmjs.org/retry/-/retry-0.6.1.tgz"
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/retry/Readme.md nodejs-0.11.15/deps/npm/node_modules/retry/Readme.md
--- nodejs-0.11.14/deps/npm/node_modules/retry/Readme.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/retry/Readme.md 2015-01-20 21:22:17.000000000 +0000
@@ -14,7 +14,7 @@
The example below will retry a potentially failing `dns.resolve` operation
`10` times using an exponential backoff strategy. With the default settings, this
-means the last attempt is made after `34 minutes and 7 seconds`.
+means the last attempt is made after `17 minutes and 3 seconds`.
``` javascript
var dns = require('dns');
@@ -29,7 +29,7 @@
return;
}
- cb(operation.mainError(), addresses);
+ cb(err ? operation.mainError() : null, addresses);
});
});
}
@@ -69,8 +69,8 @@
* `retries`: The maximum amount of times to retry the operation. Default is `10`.
* `factor`: The exponential factor to use. Default is `2`.
-* `minTimeout`: The amount of time before starting the first retry. Default is `1000`.
-* `maxTimeout`: The maximum amount of time between two retries. Default is `Infinity`.
+* `minTimeout`: The number of milliseconds before starting the first retry. Default is `1000`.
+* `maxTimeout`: The maximum number of milliseconds between two retries. Default is `Infinity`.
* `randomize`: Randomizes the timeouts by multiplying with a factor between `1` to `2`. Default is `false`.
The formula used to calculate the individual timeouts is:
diff -Nru nodejs-0.11.14/deps/npm/node_modules/semver/bin/semver nodejs-0.11.15/deps/npm/node_modules/semver/bin/semver
--- nodejs-0.11.14/deps/npm/node_modules/semver/bin/semver 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/semver/bin/semver 2015-01-20 21:22:17.000000000 +0000
@@ -12,6 +12,7 @@
, inc = null
, version = require("../package.json").version
, loose = false
+ , identifier = undefined
, semver = require("../semver")
, reverse = false
@@ -47,6 +48,9 @@
break
}
break
+ case "--preid":
+ identifier = argv.shift()
+ break
case "-r": case "--range":
range.push(argv.shift())
break
@@ -88,7 +92,7 @@
}).map(function (v) {
return semver.clean(v, loose)
}).map(function (v) {
- return inc ? semver.inc(v, inc, loose) : v
+ return inc ? semver.inc(v, inc, loose, identifier) : v
}).forEach(function (v,i,_) { console.log(v) })
}
@@ -111,6 +115,10 @@
," prepatch, or prerelease. Default level is 'patch'."
," Only one version may be specified."
,""
+ ,"--preid "
+ ," Identifier to be used to prefix premajor, preminor,"
+ ," prepatch or prerelease version increments."
+ ,""
,"-l --loose"
," Interpret versions and ranges loosely"
,""
diff -Nru nodejs-0.11.14/deps/npm/node_modules/semver/package.json nodejs-0.11.15/deps/npm/node_modules/semver/package.json
--- nodejs-0.11.14/deps/npm/node_modules/semver/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/semver/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -1,6 +1,6 @@
{
"name": "semver",
- "version": "4.0.0",
+ "version": "4.1.0",
"description": "The semantic version parser used by npm.",
"main": "semver.js",
"browser": "semver.browser.js",
@@ -21,15 +21,16 @@
"bin": {
"semver": "./bin/semver"
},
- "gitHead": "f71a46b52f5d413aff1cb3afa7d2f940b23ab1a0",
+ "gitHead": "f8db569b9fd00788d14064aaf81854ed81e1337a",
"bugs": {
"url": "https://github.com/isaacs/node-semver/issues"
},
"homepage": "https://github.com/isaacs/node-semver",
- "_id": "semver@4.0.0",
- "_shasum": "7be868416a5e669923a8e3af8bafa5faf62a151a",
- "_from": "semver@>=4.0.0-0 <5.0.0-0",
- "_npmVersion": "2.0.0-beta.3",
+ "_id": "semver@4.1.0",
+ "_shasum": "bc80a9ff68532814362cc3cfda3c7b75ed9c321c",
+ "_from": "semver@>=4.1.0 <5.0.0",
+ "_npmVersion": "2.1.3",
+ "_nodeVersion": "0.10.31",
"_npmUser": {
"name": "isaacs",
"email": "i@izs.me"
@@ -38,13 +39,17 @@
{
"name": "isaacs",
"email": "i@izs.me"
+ },
+ {
+ "name": "othiym23",
+ "email": "ogd@aoaioxxysz.net"
}
],
"dist": {
- "shasum": "7be868416a5e669923a8e3af8bafa5faf62a151a",
- "tarball": "http://registry.npmjs.org/semver/-/semver-4.0.0.tgz"
+ "shasum": "bc80a9ff68532814362cc3cfda3c7b75ed9c321c",
+ "tarball": "http://registry.npmjs.org/semver/-/semver-4.1.0.tgz"
},
"directories": {},
- "_resolved": "https://registry.npmjs.org/semver/-/semver-4.0.0.tgz",
+ "_resolved": "https://registry.npmjs.org/semver/-/semver-4.1.0.tgz",
"readme": "ERROR: No README data found!"
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/semver/README.md nodejs-0.11.15/deps/npm/node_modules/semver/README.md
--- nodejs-0.11.14/deps/npm/node_modules/semver/README.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/semver/README.md 2015-01-20 21:22:17.000000000 +0000
@@ -140,7 +140,7 @@
A partial version range is treated as an X-Range, so the special
character is in fact optional.
-* `` (empty string) := `*` := `>=0.0.0`
+* `""` (empty string) := `*` := `>=0.0.0`
* `1` := `1.x.x` := `>=1.0.0 <2.0.0`
* `1.2` := `1.2.x` := `>=1.2.0 <1.3.0`
diff -Nru nodejs-0.11.14/deps/npm/node_modules/semver/semver.browser.js nodejs-0.11.15/deps/npm/node_modules/semver/semver.browser.js
--- nodejs-0.11.14/deps/npm/node_modules/semver/semver.browser.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/semver/semver.browser.js 2015-01-20 21:22:17.000000000 +0000
@@ -345,35 +345,35 @@
// preminor will bump the version up to the next minor release, and immediately
// down to pre-release. premajor and prepatch work the same way.
-SemVer.prototype.inc = function(release) {
+SemVer.prototype.inc = function(release, identifier) {
switch (release) {
case 'premajor':
this.prerelease.length = 0;
this.patch = 0;
this.minor = 0;
this.major++;
- this.inc('pre');
+ this.inc('pre', identifier);
break;
case 'preminor':
this.prerelease.length = 0;
this.patch = 0;
this.minor++;
- this.inc('pre');
+ this.inc('pre', identifier);
break;
case 'prepatch':
// If this is already a prerelease, it will bump to the next version
// drop any prereleases that might already exist, since they are not
// relevant at this point.
this.prerelease.length = 0;
- this.inc('patch');
- this.inc('pre');
+ this.inc('patch', identifier);
+ this.inc('pre', identifier);
break;
// If the input is a non-prerelease version, this acts the same as
// prepatch.
case 'prerelease':
if (this.prerelease.length === 0)
- this.inc('patch');
- this.inc('pre');
+ this.inc('patch', identifier);
+ this.inc('pre', identifier);
break;
case 'major':
@@ -407,7 +407,7 @@
this.prerelease = [];
break;
// This probably shouldn't be used publicly.
- // 1.0.0 "pre" would become 1.0.0 which is the wrong direction.
+ // 1.0.0 "pre" would become 1.0.0-0 which is the wrong direction.
case 'pre':
if (this.prerelease.length === 0)
this.prerelease = [0];
@@ -422,6 +422,15 @@
if (i === -1) // didn't increment anything
this.prerelease.push(0);
}
+ if (identifier) {
+ // 1.2.0-beta.1 bumps to 1.2.0-beta.2,
+ // 1.2.0-beta.fooblz or 1.2.0-beta bumps to 1.2.0-beta.0
+ if (this.prerelease[0] === identifier) {
+ if (isNaN(this.prerelease[1]))
+ this.prerelease = [identifier, 0];
+ } else
+ this.prerelease = [identifier, 0];
+ }
break;
default:
@@ -432,9 +441,14 @@
};
exports.inc = inc;
-function inc(version, release, loose) {
+function inc(version, release, loose, identifier) {
+ if (typeof(loose) === 'string') {
+ identifier = loose;
+ loose = undefined;
+ }
+
try {
- return new SemVer(version, loose).inc(release).version;
+ return new SemVer(version, loose).inc(release, identifier).version;
} catch (er) {
return null;
}
@@ -846,10 +860,16 @@
if (gtlt === '=' && anyX)
gtlt = '';
- if (gtlt && anyX) {
+ if (xM) {
+ if (gtlt === '>' || gtlt === '<') {
+ // nothing is allowed
+ ret = '<0.0.0';
+ } else {
+ // nothing is forbidden
+ ret = '*';
+ }
+ } else if (gtlt && anyX) {
// replace X with 0
- if (xM)
- M = 0;
if (xm)
m = 0;
if (xp)
@@ -860,9 +880,7 @@
// >1.2 => >=1.3.0
// >1.2.3 => >= 1.2.4
gtlt = '>=';
- if (xM) {
- // no change
- } else if (xm) {
+ if (xm) {
M = +M + 1;
m = 0;
p = 0;
@@ -870,13 +888,17 @@
m = +m + 1;
p = 0;
}
+ } else if (gtlt === '<=') {
+ // <=0.7.x is actually <0.8.0, since any 0.7.x should
+ // pass. Similarly, <=7.x is actually <8.0.0, etc.
+ gtlt = '<'
+ if (xm)
+ M = +M + 1
+ else
+ m = +m + 1
}
-
ret = gtlt + M + '.' + m + '.' + p;
- } else if (xM) {
- // allow any
- ret = '*';
} else if (xm) {
ret = '>=' + M + '.0.0 <' + (+M + 1) + '.0.0';
} else if (xp) {
Binary files /tmp/Mhog4P8ZHE/nodejs-0.11.14/deps/npm/node_modules/semver/semver.browser.js.gz and /tmp/Z_ez7cGlqC/nodejs-0.11.15/deps/npm/node_modules/semver/semver.browser.js.gz differ
diff -Nru nodejs-0.11.14/deps/npm/node_modules/semver/semver.js nodejs-0.11.15/deps/npm/node_modules/semver/semver.js
--- nodejs-0.11.14/deps/npm/node_modules/semver/semver.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/semver/semver.js 2015-01-20 21:22:17.000000000 +0000
@@ -355,35 +355,35 @@
// preminor will bump the version up to the next minor release, and immediately
// down to pre-release. premajor and prepatch work the same way.
-SemVer.prototype.inc = function(release) {
+SemVer.prototype.inc = function(release, identifier) {
switch (release) {
case 'premajor':
this.prerelease.length = 0;
this.patch = 0;
this.minor = 0;
this.major++;
- this.inc('pre');
+ this.inc('pre', identifier);
break;
case 'preminor':
this.prerelease.length = 0;
this.patch = 0;
this.minor++;
- this.inc('pre');
+ this.inc('pre', identifier);
break;
case 'prepatch':
// If this is already a prerelease, it will bump to the next version
// drop any prereleases that might already exist, since they are not
// relevant at this point.
this.prerelease.length = 0;
- this.inc('patch');
- this.inc('pre');
+ this.inc('patch', identifier);
+ this.inc('pre', identifier);
break;
// If the input is a non-prerelease version, this acts the same as
// prepatch.
case 'prerelease':
if (this.prerelease.length === 0)
- this.inc('patch');
- this.inc('pre');
+ this.inc('patch', identifier);
+ this.inc('pre', identifier);
break;
case 'major':
@@ -417,7 +417,7 @@
this.prerelease = [];
break;
// This probably shouldn't be used publicly.
- // 1.0.0 "pre" would become 1.0.0 which is the wrong direction.
+ // 1.0.0 "pre" would become 1.0.0-0 which is the wrong direction.
case 'pre':
if (this.prerelease.length === 0)
this.prerelease = [0];
@@ -432,6 +432,15 @@
if (i === -1) // didn't increment anything
this.prerelease.push(0);
}
+ if (identifier) {
+ // 1.2.0-beta.1 bumps to 1.2.0-beta.2,
+ // 1.2.0-beta.fooblz or 1.2.0-beta bumps to 1.2.0-beta.0
+ if (this.prerelease[0] === identifier) {
+ if (isNaN(this.prerelease[1]))
+ this.prerelease = [identifier, 0];
+ } else
+ this.prerelease = [identifier, 0];
+ }
break;
default:
@@ -442,9 +451,14 @@
};
exports.inc = inc;
-function inc(version, release, loose) {
+function inc(version, release, loose, identifier) {
+ if (typeof(loose) === 'string') {
+ identifier = loose;
+ loose = undefined;
+ }
+
try {
- return new SemVer(version, loose).inc(release).version;
+ return new SemVer(version, loose).inc(release, identifier).version;
} catch (er) {
return null;
}
@@ -856,10 +870,16 @@
if (gtlt === '=' && anyX)
gtlt = '';
- if (gtlt && anyX) {
+ if (xM) {
+ if (gtlt === '>' || gtlt === '<') {
+ // nothing is allowed
+ ret = '<0.0.0';
+ } else {
+ // nothing is forbidden
+ ret = '*';
+ }
+ } else if (gtlt && anyX) {
// replace X with 0
- if (xM)
- M = 0;
if (xm)
m = 0;
if (xp)
@@ -870,9 +890,7 @@
// >1.2 => >=1.3.0
// >1.2.3 => >= 1.2.4
gtlt = '>=';
- if (xM) {
- // no change
- } else if (xm) {
+ if (xm) {
M = +M + 1;
m = 0;
p = 0;
@@ -880,13 +898,17 @@
m = +m + 1;
p = 0;
}
+ } else if (gtlt === '<=') {
+ // <=0.7.x is actually <0.8.0, since any 0.7.x should
+ // pass. Similarly, <=7.x is actually <8.0.0, etc.
+ gtlt = '<'
+ if (xm)
+ M = +M + 1
+ else
+ m = +m + 1
}
-
ret = gtlt + M + '.' + m + '.' + p;
- } else if (xM) {
- // allow any
- ret = '*';
} else if (xm) {
ret = '>=' + M + '.0.0 <' + (+M + 1) + '.0.0';
} else if (xp) {
diff -Nru nodejs-0.11.14/deps/npm/node_modules/semver/semver.min.js nodejs-0.11.15/deps/npm/node_modules/semver/semver.min.js
--- nodejs-0.11.14/deps/npm/node_modules/semver/semver.min.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/semver/semver.min.js 2015-01-20 21:22:17.000000000 +0000
@@ -1 +1 @@
-(function(e){if(typeof module==="object"&&module.exports===e)e=module.exports=H;e.SEMVER_SPEC_VERSION="2.0.0";var r=e.re=[];var t=e.src=[];var n=0;var i=n++;t[i]="0|[1-9]\\d*";var s=n++;t[s]="[0-9]+";var o=n++;t[o]="\\d*[a-zA-Z-][a-zA-Z0-9-]*";var a=n++;t[a]="("+t[i]+")\\."+"("+t[i]+")\\."+"("+t[i]+")";var f=n++;t[f]="("+t[s]+")\\."+"("+t[s]+")\\."+"("+t[s]+")";var u=n++;t[u]="(?:"+t[i]+"|"+t[o]+")";var l=n++;t[l]="(?:"+t[s]+"|"+t[o]+")";var c=n++;t[c]="(?:-("+t[u]+"(?:\\."+t[u]+")*))";var p=n++;t[p]="(?:-?("+t[l]+"(?:\\."+t[l]+")*))";var h=n++;t[h]="[0-9A-Za-z-]+";var v=n++;t[v]="(?:\\+("+t[h]+"(?:\\."+t[h]+")*))";var m=n++;var g="v?"+t[a]+t[c]+"?"+t[v]+"?";t[m]="^"+g+"$";var w="[v=\\s]*"+t[f]+t[p]+"?"+t[v]+"?";var y=n++;t[y]="^"+w+"$";var d=n++;t[d]="((?:<|>)?=?)";var b=n++;t[b]=t[s]+"|x|X|\\*";var j=n++;t[j]=t[i]+"|x|X|\\*";var $=n++;t[$]="[v=\\s]*("+t[j]+")"+"(?:\\.("+t[j]+")"+"(?:\\.("+t[j]+")"+"(?:"+t[c]+")?"+t[v]+"?"+")?)?";var k=n++;t[k]="[v=\\s]*("+t[b]+")"+"(?:\\.("+t[b]+")"+"(?:\\.("+t[b]+")"+"(?:"+t[p]+")?"+t[v]+"?"+")?)?";var E=n++;t[E]="^"+t[d]+"\\s*"+t[$]+"$";var x=n++;t[x]="^"+t[d]+"\\s*"+t[k]+"$";var R=n++;t[R]="(?:~>?)";var S=n++;t[S]="(\\s*)"+t[R]+"\\s+";r[S]=new RegExp(t[S],"g");var V="$1~";var I=n++;t[I]="^"+t[R]+t[$]+"$";var T=n++;t[T]="^"+t[R]+t[k]+"$";var A=n++;t[A]="(?:\\^)";var C=n++;t[C]="(\\s*)"+t[A]+"\\s+";r[C]=new RegExp(t[C],"g");var M="$1^";var z=n++;t[z]="^"+t[A]+t[$]+"$";var P=n++;t[P]="^"+t[A]+t[k]+"$";var Z=n++;t[Z]="^"+t[d]+"\\s*("+w+")$|^$";var q=n++;t[q]="^"+t[d]+"\\s*("+g+")$|^$";var L=n++;t[L]="(\\s*)"+t[d]+"\\s*("+w+"|"+t[$]+")";r[L]=new RegExp(t[L],"g");var X="$1$2$3";var _=n++;t[_]="^\\s*("+t[$]+")"+"\\s+-\\s+"+"("+t[$]+")"+"\\s*$";var N=n++;t[N]="^\\s*("+t[k]+")"+"\\s+-\\s+"+"("+t[k]+")"+"\\s*$";var O=n++;t[O]="(<|>)?=?\\s*\\*";for(var B=0;B'};H.prototype.toString=function(){return this.version};H.prototype.compare=function(e){if(!(e instanceof H))e=new H(e,this.loose);return this.compareMain(e)||this.comparePre(e)};H.prototype.compareMain=function(e){if(!(e instanceof H))e=new H(e,this.loose);return Q(this.major,e.major)||Q(this.minor,e.minor)||Q(this.patch,e.patch)};H.prototype.comparePre=function(e){if(!(e instanceof H))e=new H(e,this.loose);if(this.prerelease.length&&!e.prerelease.length)return-1;else if(!this.prerelease.length&&e.prerelease.length)return 1;else if(!this.prerelease.length&&!e.prerelease.length)return 0;var r=0;do{var t=this.prerelease[r];var n=e.prerelease[r];if(t===undefined&&n===undefined)return 0;else if(n===undefined)return 1;else if(t===undefined)return-1;else if(t===n)continue;else return Q(t,n)}while(++r)};H.prototype.inc=function(e){switch(e){case"premajor":this.prerelease.length=0;this.patch=0;this.minor=0;this.major++;this.inc("pre");break;case"preminor":this.prerelease.length=0;this.patch=0;this.minor++;this.inc("pre");break;case"prepatch":this.prerelease.length=0;this.inc("patch");this.inc("pre");break;case"prerelease":if(this.prerelease.length===0)this.inc("patch");this.inc("pre");break;case"major":if(this.minor!==0||this.patch!==0||this.prerelease.length===0)this.major++;this.minor=0;this.patch=0;this.prerelease=[];break;case"minor":if(this.patch!==0||this.prerelease.length===0)this.minor++;this.patch=0;this.prerelease=[];break;case"patch":if(this.prerelease.length===0)this.patch++;this.prerelease=[];break;case"pre":if(this.prerelease.length===0)this.prerelease=[0];else{var r=this.prerelease.length;while(--r>=0){if(typeof this.prerelease[r]==="number"){this.prerelease[r]++;r=-2}}if(r===-1)this.prerelease.push(0)}break;default:throw new Error("invalid increment argument: "+e)}this.format();return this};e.inc=J;function J(e,r,t){try{return new H(e,t).inc(r).version}catch(n){return null}}e.compareIdentifiers=Q;var K=/^[0-9]+$/;function Q(e,r){var t=K.test(e);var n=K.test(r);if(t&&n){e=+e;r=+r}return t&&!n?-1:n&&!t?1:er?1:0}e.rcompareIdentifiers=U;function U(e,r){return Q(r,e)}e.compare=W;function W(e,r,t){return new H(e,t).compare(r)}e.compareLoose=Y;function Y(e,r){return W(e,r,true)}e.rcompare=er;function er(e,r,t){return W(r,e,t)}e.sort=rr;function rr(r,t){return r.sort(function(r,n){return e.compare(r,n,t)})}e.rsort=tr;function tr(r,t){return r.sort(function(r,n){return e.rcompare(r,n,t)})}e.gt=nr;function nr(e,r,t){return W(e,r,t)>0}e.lt=ir;function ir(e,r,t){return W(e,r,t)<0}e.eq=sr;function sr(e,r,t){return W(e,r,t)===0}e.neq=or;function or(e,r,t){return W(e,r,t)!==0}e.gte=ar;function ar(e,r,t){return W(e,r,t)>=0}e.lte=fr;function fr(e,r,t){return W(e,r,t)<=0}e.cmp=ur;function ur(e,r,t,n){var i;switch(r){case"===":if(typeof e==="object")e=e.version;if(typeof t==="object")t=t.version;i=e===t;break;case"!==":if(typeof e==="object")e=e.version;if(typeof t==="object")t=t.version;i=e!==t;break;case"":case"=":case"==":i=sr(e,t,n);break;case"!=":i=or(e,t,n);break;case">":i=nr(e,t,n);break;case">=":i=ar(e,t,n);break;case"<":i=ir(e,t,n);break;case"<=":i=fr(e,t,n);break;default:throw new TypeError("Invalid operator: "+r)}return i}e.Comparator=lr;function lr(e,r){if(e instanceof lr){if(e.loose===r)return e;else e=e.value}if(!(this instanceof lr))return new lr(e,r);this.loose=r;this.parse(e);if(this.semver===cr)this.value="";else this.value=this.operator+this.semver.version}var cr={};lr.prototype.parse=function(e){var t=this.loose?r[Z]:r[q];var n=e.match(t);if(!n)throw new TypeError("Invalid comparator: "+e);this.operator=n[1];if(this.operator==="=")this.operator="";if(!n[2])this.semver=cr;else this.semver=new H(n[2],this.loose)};lr.prototype.inspect=function(){return''};lr.prototype.toString=function(){return this.value};lr.prototype.test=function(e){if(this.semver===cr)return true;if(typeof e==="string")e=new H(e,this.loose);return ur(e,this.operator,this.semver,this.loose)};e.Range=pr;function pr(e,r){if(e instanceof pr&&e.loose===r)return e;if(!(this instanceof pr))return new pr(e,r);this.loose=r;this.raw=e;this.set=e.split(/\s*\|\|\s*/).map(function(e){return this.parseRange(e.trim())},this).filter(function(e){return e.length});if(!this.set.length){throw new TypeError("Invalid SemVer Range: "+e)}this.format()}pr.prototype.inspect=function(){return''};pr.prototype.format=function(){this.range=this.set.map(function(e){return e.join(" ").trim()}).join("||").trim();return this.range};pr.prototype.toString=function(){return this.range};pr.prototype.parseRange=function(e){var t=this.loose;e=e.trim();var n=t?r[N]:r[_];e=e.replace(n,kr);e=e.replace(r[L],X);e=e.replace(r[S],V);e=e.replace(r[C],M);e=e.split(/\s+/).join(" ");var i=t?r[Z]:r[q];var s=e.split(" ").map(function(e){return vr(e,t)}).join(" ").split(/\s+/);if(this.loose){s=s.filter(function(e){return!!e.match(i)})}s=s.map(function(e){return new lr(e,t)});return s};e.toComparators=hr;function hr(e,r){return new pr(e,r).set.map(function(e){return e.map(function(e){return e.value}).join(" ").trim().split(" ")})}function vr(e,r){e=yr(e,r);e=gr(e,r);e=br(e,r);e=$r(e,r);return e}function mr(e){return!e||e.toLowerCase()==="x"||e==="*"}function gr(e,r){return e.trim().split(/\s+/).map(function(e){return wr(e,r)}).join(" ")}function wr(e,t){var n=t?r[T]:r[I];return e.replace(n,function(e,r,t,n,i){var s;if(mr(r))s="";else if(mr(t))s=">="+r+".0.0 <"+(+r+1)+".0.0";else if(mr(n))s=">="+r+"."+t+".0 <"+r+"."+(+t+1)+".0";else if(i){if(i.charAt(0)!=="-")i="-"+i;s=">="+r+"."+t+"."+n+i+" <"+r+"."+(+t+1)+".0"}else s=">="+r+"."+t+"."+n+" <"+r+"."+(+t+1)+".0";return s})}function yr(e,r){return e.trim().split(/\s+/).map(function(e){return dr(e,r)}).join(" ")}function dr(e,t){var n=t?r[P]:r[z];return e.replace(n,function(e,r,t,n,i){var s;if(mr(r))s="";else if(mr(t))s=">="+r+".0.0 <"+(+r+1)+".0.0";else if(mr(n)){if(r==="0")s=">="+r+"."+t+".0 <"+r+"."+(+t+1)+".0";else s=">="+r+"."+t+".0 <"+(+r+1)+".0.0"}else if(i){if(i.charAt(0)!=="-")i="-"+i;if(r==="0"){if(t==="0")s=">="+r+"."+t+"."+n+i+" <"+r+"."+t+"."+(+n+1);else s=">="+r+"."+t+"."+n+i+" <"+r+"."+(+t+1)+".0"}else s=">="+r+"."+t+"."+n+i+" <"+(+r+1)+".0.0"}else{if(r==="0"){if(t==="0")s=">="+r+"."+t+"."+n+" <"+r+"."+t+"."+(+n+1);else s=">="+r+"."+t+"."+n+" <"+r+"."+(+t+1)+".0"}else s=">="+r+"."+t+"."+n+" <"+(+r+1)+".0.0"}return s})}function br(e,r){return e.split(/\s+/).map(function(e){return jr(e,r)}).join(" ")}function jr(e,t){e=e.trim();var n=t?r[x]:r[E];return e.replace(n,function(e,r,t,n,i,s){var o=mr(t);var a=o||mr(n);var f=a||mr(i);var u=f;if(r==="="&&u)r="";if(r&&u){if(o)t=0;if(a)n=0;if(f)i=0;if(r===">"){r=">=";if(o){}else if(a){t=+t+1;n=0;i=0}else if(f){n=+n+1;i=0}}e=r+t+"."+n+"."+i}else if(o){e="*"}else if(a){e=">="+t+".0.0 <"+(+t+1)+".0.0"}else if(f){e=">="+t+"."+n+".0 <"+t+"."+(+n+1)+".0"}return e})}function $r(e,t){return e.trim().replace(r[O],"")}function kr(e,r,t,n,i,s,o,a,f,u,l,c,p){if(mr(t))r="";else if(mr(n))r=">="+t+".0.0";else if(mr(i))r=">="+t+"."+n+".0";else r=">="+r;if(mr(f))a="";else if(mr(u))a="<"+(+f+1)+".0.0";else if(mr(l))a="<"+f+"."+(+u+1)+".0";else if(c)a="<="+f+"."+u+"."+l+"-"+c;else a="<="+a;return(r+" "+a).trim()}pr.prototype.test=function(e){if(!e)return false;if(typeof e==="string")e=new H(e,this.loose);for(var r=0;r0){var n=e[t].semver;if(n.major===r.major&&n.minor===r.minor&&n.patch===r.patch)return true}}return false}return true}e.satisfies=xr;function xr(e,r,t){try{r=new pr(r,t)}catch(n){return false}return r.test(e)}e.maxSatisfying=Rr;function Rr(e,r,t){return e.filter(function(e){return xr(e,r,t)}).sort(function(e,r){return er(e,r,t)})[0]||null}e.validRange=Sr;function Sr(e,r){try{return new pr(e,r).range||"*"}catch(t){return null}}e.ltr=Vr;function Vr(e,r,t){return Tr(e,r,"<",t)}e.gtr=Ir;function Ir(e,r,t){return Tr(e,r,">",t)}e.outside=Tr;function Tr(e,r,t,n){e=new H(e,n);r=new pr(r,n);var i,s,o,a,f;switch(t){case">":i=nr;s=fr;o=ir;a=">";f=">=";break;case"<":i=ir;s=ar;o=nr;a="<";f="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(xr(e,r,n)){return false}for(var u=0;u)?=?)";var b=n++;t[b]=t[s]+"|x|X|\\*";var j=n++;t[j]=t[i]+"|x|X|\\*";var $=n++;t[$]="[v=\\s]*("+t[j]+")"+"(?:\\.("+t[j]+")"+"(?:\\.("+t[j]+")"+"(?:"+t[p]+")?"+t[v]+"?"+")?)?";var k=n++;t[k]="[v=\\s]*("+t[b]+")"+"(?:\\.("+t[b]+")"+"(?:\\.("+t[b]+")"+"(?:"+t[c]+")?"+t[v]+"?"+")?)?";var E=n++;t[E]="^"+t[y]+"\\s*"+t[$]+"$";var x=n++;t[x]="^"+t[y]+"\\s*"+t[k]+"$";var R=n++;t[R]="(?:~>?)";var S=n++;t[S]="(\\s*)"+t[R]+"\\s+";r[S]=new RegExp(t[S],"g");var V="$1~";var I=n++;t[I]="^"+t[R]+t[$]+"$";var T=n++;t[T]="^"+t[R]+t[k]+"$";var A=n++;t[A]="(?:\\^)";var C=n++;t[C]="(\\s*)"+t[A]+"\\s+";r[C]=new RegExp(t[C],"g");var M="$1^";var z=n++;t[z]="^"+t[A]+t[$]+"$";var N=n++;t[N]="^"+t[A]+t[k]+"$";var P=n++;t[P]="^"+t[y]+"\\s*("+w+")$|^$";var Z=n++;t[Z]="^"+t[y]+"\\s*("+g+")$|^$";var q=n++;t[q]="(\\s*)"+t[y]+"\\s*("+w+"|"+t[$]+")";r[q]=new RegExp(t[q],"g");var L="$1$2$3";var X=n++;t[X]="^\\s*("+t[$]+")"+"\\s+-\\s+"+"("+t[$]+")"+"\\s*$";var _=n++;t[_]="^\\s*("+t[k]+")"+"\\s+-\\s+"+"("+t[k]+")"+"\\s*$";var O=n++;t[O]="(<|>)?=?\\s*\\*";for(var B=0;B'};H.prototype.toString=function(){return this.version};H.prototype.compare=function(e){if(!(e instanceof H))e=new H(e,this.loose);return this.compareMain(e)||this.comparePre(e)};H.prototype.compareMain=function(e){if(!(e instanceof H))e=new H(e,this.loose);return Q(this.major,e.major)||Q(this.minor,e.minor)||Q(this.patch,e.patch)};H.prototype.comparePre=function(e){if(!(e instanceof H))e=new H(e,this.loose);if(this.prerelease.length&&!e.prerelease.length)return-1;else if(!this.prerelease.length&&e.prerelease.length)return 1;else if(!this.prerelease.length&&!e.prerelease.length)return 0;var r=0;do{var t=this.prerelease[r];var n=e.prerelease[r];if(t===undefined&&n===undefined)return 0;else if(n===undefined)return 1;else if(t===undefined)return-1;else if(t===n)continue;else return Q(t,n)}while(++r)};H.prototype.inc=function(e,r){switch(e){case"premajor":this.prerelease.length=0;this.patch=0;this.minor=0;this.major++;this.inc("pre",r);break;case"preminor":this.prerelease.length=0;this.patch=0;this.minor++;this.inc("pre",r);break;case"prepatch":this.prerelease.length=0;this.inc("patch",r);this.inc("pre",r);break;case"prerelease":if(this.prerelease.length===0)this.inc("patch",r);this.inc("pre",r);break;case"major":if(this.minor!==0||this.patch!==0||this.prerelease.length===0)this.major++;this.minor=0;this.patch=0;this.prerelease=[];break;case"minor":if(this.patch!==0||this.prerelease.length===0)this.minor++;this.patch=0;this.prerelease=[];break;case"patch":if(this.prerelease.length===0)this.patch++;this.prerelease=[];break;case"pre":if(this.prerelease.length===0)this.prerelease=[0];else{var t=this.prerelease.length;while(--t>=0){if(typeof this.prerelease[t]==="number"){this.prerelease[t]++;t=-2}}if(t===-1)this.prerelease.push(0)}if(r){if(this.prerelease[0]===r){if(isNaN(this.prerelease[1]))this.prerelease=[r,0]}else this.prerelease=[r,0]}break;default:throw new Error("invalid increment argument: "+e)}this.format();return this};e.inc=J;function J(e,r,t,n){if(typeof t==="string"){n=t;t=undefined}try{return new H(e,t).inc(r,n).version}catch(i){return null}}e.compareIdentifiers=Q;var K=/^[0-9]+$/;function Q(e,r){var t=K.test(e);var n=K.test(r);if(t&&n){e=+e;r=+r}return t&&!n?-1:n&&!t?1:er?1:0}e.rcompareIdentifiers=U;function U(e,r){return Q(r,e)}e.compare=W;function W(e,r,t){return new H(e,t).compare(r)}e.compareLoose=Y;function Y(e,r){return W(e,r,true)}e.rcompare=er;function er(e,r,t){return W(r,e,t)}e.sort=rr;function rr(r,t){return r.sort(function(r,n){return e.compare(r,n,t)})}e.rsort=tr;function tr(r,t){return r.sort(function(r,n){return e.rcompare(r,n,t)})}e.gt=nr;function nr(e,r,t){return W(e,r,t)>0}e.lt=ir;function ir(e,r,t){return W(e,r,t)<0}e.eq=sr;function sr(e,r,t){return W(e,r,t)===0}e.neq=ar;function ar(e,r,t){return W(e,r,t)!==0}e.gte=or;function or(e,r,t){return W(e,r,t)>=0}e.lte=fr;function fr(e,r,t){return W(e,r,t)<=0}e.cmp=ur;function ur(e,r,t,n){var i;switch(r){case"===":if(typeof e==="object")e=e.version;if(typeof t==="object")t=t.version;i=e===t;break;case"!==":if(typeof e==="object")e=e.version;if(typeof t==="object")t=t.version;i=e!==t;break;case"":case"=":case"==":i=sr(e,t,n);break;case"!=":i=ar(e,t,n);break;case">":i=nr(e,t,n);break;case">=":i=or(e,t,n);break;case"<":i=ir(e,t,n);break;case"<=":i=fr(e,t,n);break;default:throw new TypeError("Invalid operator: "+r)}return i}e.Comparator=lr;function lr(e,r){if(e instanceof lr){if(e.loose===r)return e;else e=e.value}if(!(this instanceof lr))return new lr(e,r);this.loose=r;this.parse(e);if(this.semver===pr)this.value="";else this.value=this.operator+this.semver.version}var pr={};lr.prototype.parse=function(e){var t=this.loose?r[P]:r[Z];var n=e.match(t);if(!n)throw new TypeError("Invalid comparator: "+e);this.operator=n[1];if(this.operator==="=")this.operator="";if(!n[2])this.semver=pr;else this.semver=new H(n[2],this.loose)};lr.prototype.inspect=function(){return''};lr.prototype.toString=function(){return this.value};lr.prototype.test=function(e){if(this.semver===pr)return true;if(typeof e==="string")e=new H(e,this.loose);return ur(e,this.operator,this.semver,this.loose)};e.Range=cr;function cr(e,r){if(e instanceof cr&&e.loose===r)return e;if(!(this instanceof cr))return new cr(e,r);this.loose=r;this.raw=e;this.set=e.split(/\s*\|\|\s*/).map(function(e){return this.parseRange(e.trim())},this).filter(function(e){return e.length});if(!this.set.length){throw new TypeError("Invalid SemVer Range: "+e)}this.format()}cr.prototype.inspect=function(){return''};cr.prototype.format=function(){this.range=this.set.map(function(e){return e.join(" ").trim()}).join("||").trim();return this.range};cr.prototype.toString=function(){return this.range};cr.prototype.parseRange=function(e){var t=this.loose;e=e.trim();var n=t?r[_]:r[X];e=e.replace(n,kr);e=e.replace(r[q],L);e=e.replace(r[S],V);e=e.replace(r[C],M);e=e.split(/\s+/).join(" ");var i=t?r[P]:r[Z];var s=e.split(" ").map(function(e){return vr(e,t)}).join(" ").split(/\s+/);if(this.loose){s=s.filter(function(e){return!!e.match(i)})}s=s.map(function(e){return new lr(e,t)});return s};e.toComparators=hr;function hr(e,r){return new cr(e,r).set.map(function(e){return e.map(function(e){return e.value}).join(" ").trim().split(" ")})}function vr(e,r){e=dr(e,r);e=gr(e,r);e=br(e,r);e=$r(e,r);return e}function mr(e){return!e||e.toLowerCase()==="x"||e==="*"}function gr(e,r){return e.trim().split(/\s+/).map(function(e){return wr(e,r)}).join(" ")}function wr(e,t){var n=t?r[T]:r[I];return e.replace(n,function(e,r,t,n,i){var s;if(mr(r))s="";else if(mr(t))s=">="+r+".0.0 <"+(+r+1)+".0.0";else if(mr(n))s=">="+r+"."+t+".0 <"+r+"."+(+t+1)+".0";else if(i){if(i.charAt(0)!=="-")i="-"+i;s=">="+r+"."+t+"."+n+i+" <"+r+"."+(+t+1)+".0"}else s=">="+r+"."+t+"."+n+" <"+r+"."+(+t+1)+".0";return s})}function dr(e,r){return e.trim().split(/\s+/).map(function(e){return yr(e,r)}).join(" ")}function yr(e,t){var n=t?r[N]:r[z];return e.replace(n,function(e,r,t,n,i){var s;if(mr(r))s="";else if(mr(t))s=">="+r+".0.0 <"+(+r+1)+".0.0";else if(mr(n)){if(r==="0")s=">="+r+"."+t+".0 <"+r+"."+(+t+1)+".0";else s=">="+r+"."+t+".0 <"+(+r+1)+".0.0"}else if(i){if(i.charAt(0)!=="-")i="-"+i;if(r==="0"){if(t==="0")s=">="+r+"."+t+"."+n+i+" <"+r+"."+t+"."+(+n+1);else s=">="+r+"."+t+"."+n+i+" <"+r+"."+(+t+1)+".0"}else s=">="+r+"."+t+"."+n+i+" <"+(+r+1)+".0.0"}else{if(r==="0"){if(t==="0")s=">="+r+"."+t+"."+n+" <"+r+"."+t+"."+(+n+1);else s=">="+r+"."+t+"."+n+" <"+r+"."+(+t+1)+".0"}else s=">="+r+"."+t+"."+n+" <"+(+r+1)+".0.0"}return s})}function br(e,r){return e.split(/\s+/).map(function(e){return jr(e,r)}).join(" ")}function jr(e,t){e=e.trim();var n=t?r[x]:r[E];return e.replace(n,function(e,r,t,n,i,s){var a=mr(t);var o=a||mr(n);var f=o||mr(i);var u=f;if(r==="="&&u)r="";if(a){if(r===">"||r==="<"){e="<0.0.0"}else{e="*"}}else if(r&&u){if(o)n=0;if(f)i=0;if(r===">"){r=">=";if(o){t=+t+1;n=0;i=0}else if(f){n=+n+1;i=0}}else if(r==="<="){r="<";if(o)t=+t+1;else n=+n+1}e=r+t+"."+n+"."+i}else if(o){e=">="+t+".0.0 <"+(+t+1)+".0.0"}else if(f){e=">="+t+"."+n+".0 <"+t+"."+(+n+1)+".0"}return e})}function $r(e,t){return e.trim().replace(r[O],"")}function kr(e,r,t,n,i,s,a,o,f,u,l,p,c){if(mr(t))r="";else if(mr(n))r=">="+t+".0.0";else if(mr(i))r=">="+t+"."+n+".0";else r=">="+r;if(mr(f))o="";else if(mr(u))o="<"+(+f+1)+".0.0";else if(mr(l))o="<"+f+"."+(+u+1)+".0";else if(p)o="<="+f+"."+u+"."+l+"-"+p;else o="<="+o;return(r+" "+o).trim()}cr.prototype.test=function(e){if(!e)return false;if(typeof e==="string")e=new H(e,this.loose);for(var r=0;r0){var n=e[t].semver;if(n.major===r.major&&n.minor===r.minor&&n.patch===r.patch)return true}}return false}return true}e.satisfies=xr;function xr(e,r,t){try{r=new cr(r,t)}catch(n){return false}return r.test(e)}e.maxSatisfying=Rr;function Rr(e,r,t){return e.filter(function(e){return xr(e,r,t)}).sort(function(e,r){return er(e,r,t)})[0]||null}e.validRange=Sr;function Sr(e,r){try{return new cr(e,r).range||"*"}catch(t){return null}}e.ltr=Vr;function Vr(e,r,t){return Tr(e,r,"<",t)}e.gtr=Ir;function Ir(e,r,t){return Tr(e,r,">",t)}e.outside=Tr;function Tr(e,r,t,n){e=new H(e,n);r=new cr(r,n);var i,s,a,o,f;switch(t){case">":i=nr;s=fr;a=ir;o=">";f=">=";break;case"<":i=ir;s=or;a=nr;o="<";f="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(xr(e,r,n)){return false}for(var u=0;u1.2.3', null],
+ ['~1.2.3', null],
+ ['<=1.2.3', null],
+ ['1.2.x', null]
].forEach(function(tuple) {
var range = tuple[0];
var version = tuple[1];
diff -Nru nodejs-0.11.14/deps/npm/node_modules/semver/test/gtr.js nodejs-0.11.15/deps/npm/node_modules/semver/test/gtr.js
--- nodejs-0.11.14/deps/npm/node_modules/semver/test/gtr.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/semver/test/gtr.js 2015-01-20 21:22:17.000000000 +0000
@@ -66,7 +66,7 @@
['<1', '1.0.0beta', true],
['< 1', '1.0.0beta', true],
['=0.7.x', '0.8.2'],
- ['<=0.7.x', '0.7.2']
+ ['<0.7.x', '0.7.2']
].forEach(function(tuple) {
var range = tuple[0];
var version = tuple[1];
diff -Nru nodejs-0.11.14/deps/npm/node_modules/semver/test/index.js nodejs-0.11.15/deps/npm/node_modules/semver/test/index.js
--- nodejs-0.11.14/deps/npm/node_modules/semver/test/index.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/semver/test/index.js 2015-01-20 21:22:17.000000000 +0000
@@ -201,6 +201,7 @@
['~v0.5.4-pre', '0.5.5'],
['~v0.5.4-pre', '0.5.4'],
['=0.7.x', '0.7.2'],
+ ['<=0.7.x', '0.7.2'],
['>=0.7.x', '0.7.2'],
['<=0.7.x', '0.6.2'],
['~1.2.1 >=1.2.3', '1.2.3'],
@@ -290,7 +291,7 @@
['~v0.5.4-beta', '0.5.4-alpha'],
['=0.7.x', '0.8.2'],
['>=0.7.x', '0.6.2'],
- ['<=0.7.x', '0.7.2'],
+ ['<0.7.x', '0.7.2'],
['<1.2.3', '1.2.3-beta'],
['=1.2.3', '1.2.3-beta'],
['>1.2', '1.2.8'],
@@ -312,8 +313,8 @@
});
test('\nincrement versions test', function(t) {
- // [version, inc, result]
- // inc(version, inc) -> result
+// [version, inc, result, identifier]
+// inc(version, inc) -> result
[['1.2.3', 'major', '2.0.0'],
['1.2.3', 'minor', '1.3.0'],
['1.2.3', 'patch', '1.2.4'],
@@ -352,14 +353,59 @@
['1.2.0', 'premajor', '2.0.0-0'],
['1.2.3-1', 'premajor', '2.0.0-0'],
['1.2.0-1', 'minor', '1.2.0'],
- ['1.0.0-1', 'major', '1.0.0']
+ ['1.0.0-1', 'major', '1.0.0'],
+
+ ['1.2.3', 'major', '2.0.0', false, 'dev'],
+ ['1.2.3', 'minor', '1.3.0', false, 'dev'],
+ ['1.2.3', 'patch', '1.2.4', false, 'dev'],
+ ['1.2.3tag', 'major', '2.0.0', true, 'dev'],
+ ['1.2.3-tag', 'major', '2.0.0', false, 'dev'],
+ ['1.2.3', 'fake', null, false, 'dev'],
+ ['1.2.0-0', 'patch', '1.2.0', false, 'dev'],
+ ['fake', 'major', null, false, 'dev'],
+ ['1.2.3-4', 'major', '2.0.0', false, 'dev'],
+ ['1.2.3-4', 'minor', '1.3.0', false, 'dev'],
+ ['1.2.3-4', 'patch', '1.2.3', false, 'dev'],
+ ['1.2.3-alpha.0.beta', 'major', '2.0.0', false, 'dev'],
+ ['1.2.3-alpha.0.beta', 'minor', '1.3.0', false, 'dev'],
+ ['1.2.3-alpha.0.beta', 'patch', '1.2.3', false, 'dev'],
+ ['1.2.4', 'prerelease', '1.2.5-dev.0', false, 'dev'],
+ ['1.2.3-0', 'prerelease', '1.2.3-dev.0', false, 'dev'],
+ ['1.2.3-alpha.0', 'prerelease', '1.2.3-dev.0', false, 'dev'],
+ ['1.2.3-alpha.0', 'prerelease', '1.2.3-alpha.1', false, 'alpha'],
+ ['1.2.3-alpha.0.beta', 'prerelease', '1.2.3-dev.0', false, 'dev'],
+ ['1.2.3-alpha.0.beta', 'prerelease', '1.2.3-alpha.1.beta', false, 'alpha'],
+ ['1.2.3-alpha.10.0.beta', 'prerelease', '1.2.3-dev.0', false, 'dev'],
+ ['1.2.3-alpha.10.0.beta', 'prerelease', '1.2.3-alpha.10.1.beta', false, 'alpha'],
+ ['1.2.3-alpha.10.1.beta', 'prerelease', '1.2.3-alpha.10.2.beta', false, 'alpha'],
+ ['1.2.3-alpha.10.2.beta', 'prerelease', '1.2.3-alpha.10.3.beta', false, 'alpha'],
+ ['1.2.3-alpha.10.beta.0', 'prerelease', '1.2.3-dev.0', false, 'dev'],
+ ['1.2.3-alpha.10.beta.0', 'prerelease', '1.2.3-alpha.10.beta.1', false, 'alpha'],
+ ['1.2.3-alpha.10.beta.1', 'prerelease', '1.2.3-alpha.10.beta.2', false, 'alpha'],
+ ['1.2.3-alpha.10.beta.2', 'prerelease', '1.2.3-alpha.10.beta.3', false, 'alpha'],
+ ['1.2.3-alpha.9.beta', 'prerelease', '1.2.3-dev.0', false, 'dev'],
+ ['1.2.3-alpha.9.beta', 'prerelease', '1.2.3-alpha.10.beta', false, 'alpha'],
+ ['1.2.3-alpha.10.beta', 'prerelease', '1.2.3-alpha.11.beta', false, 'alpha'],
+ ['1.2.3-alpha.11.beta', 'prerelease', '1.2.3-alpha.12.beta', false, 'alpha'],
+ ['1.2.0', 'prepatch', '1.2.1-dev.0', 'dev'],
+ ['1.2.0-1', 'prepatch', '1.2.1-dev.0', 'dev'],
+ ['1.2.0', 'preminor', '1.3.0-dev.0', 'dev'],
+ ['1.2.3-1', 'preminor', '1.3.0-dev.0', 'dev'],
+ ['1.2.0', 'premajor', '2.0.0-dev.0', 'dev'],
+ ['1.2.3-1', 'premajor', '2.0.0-dev.0', 'dev'],
+ ['1.2.0-1', 'minor', '1.2.0', 'dev'],
+ ['1.0.0-1', 'major', '1.0.0', 'dev'],
+ ['1.2.3-dev.bar', 'prerelease', '1.2.3-dev.0', false, 'dev']
+
].forEach(function(v) {
var pre = v[0];
var what = v[1];
var wanted = v[2];
var loose = v[3];
- var found = inc(pre, what, loose);
- t.equal(found, wanted, 'inc(' + pre + ', ' + what + ') === ' + wanted);
+ var id = v[4];
+ var found = inc(pre, what, loose, id);
+ var cmd = 'inc(' + pre + ', ' + what + ', ' + id + ')';
+ t.equal(found, wanted, cmd + ' === ' + wanted);
});
t.end();
@@ -371,7 +417,7 @@
// translate ranges into their canonical form
[['1.0.0 - 2.0.0', '>=1.0.0 <=2.0.0'],
['1.0.0', '1.0.0'],
- ['>=*', '>=0.0.0'],
+ ['>=*', '*'],
['', '*'],
['*', '*'],
['*', '*'],
@@ -458,7 +504,7 @@
// turn range into a set of individual comparators
[['1.0.0 - 2.0.0', [['>=1.0.0', '<=2.0.0']]],
['1.0.0', [['1.0.0']]],
- ['>=*', [['>=0.0.0']]],
+ ['>=*', [['']]],
['', [['']]],
['*', [['']]],
['*', [['']]],
@@ -522,7 +568,9 @@
['1 2', [['>=1.0.0', '<2.0.0', '>=2.0.0', '<3.0.0']]],
['1.2 - 3.4.5', [['>=1.2.0', '<=3.4.5']]],
['1.2.3 - 3.4', [['>=1.2.3', '<3.5.0']]],
- ['1.2.3 - 3', [['>=1.2.3', '<4.0.0']]]
+ ['1.2.3 - 3', [['>=1.2.3', '<4.0.0']]],
+ ['>*', [['<0.0.0']]],
+ ['<*', [['<0.0.0']]]
].forEach(function(v) {
var pre = v[0];
var wanted = v[1];
diff -Nru nodejs-0.11.14/deps/npm/node_modules/sha/index.js nodejs-0.11.15/deps/npm/node_modules/sha/index.js
--- nodejs-0.11.14/deps/npm/node_modules/sha/index.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/sha/index.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,120 +1,120 @@
-'use strict'
-
-var Transform = require('stream').Transform || require('readable-stream').Transform
-var crypto = require('crypto')
-var fs
-try {
- fs = require('graceful-fs')
-} catch (ex) {
- fs = require('fs')
-}
-try {
- process.binding('crypto')
-} catch (e) {
- var er = new Error( 'crypto binding not found.\n'
- + 'Please build node with openssl.\n'
- + e.message )
- throw er
-}
-
-exports.check = check
-exports.checkSync = checkSync
-exports.get = get
-exports.getSync = getSync
-exports.stream = stream
-
-function check(file, expected, options, cb) {
- if (typeof options === 'function') {
- cb = options
- options = undefined
- }
- expected = expected.toLowerCase().trim()
- get(file, options, function (er, actual) {
- if (er) {
- if (er.message) er.message += ' while getting shasum for ' + file
- return cb(er)
- }
- if (actual === expected) return cb(null)
- cb(new Error(
- 'shasum check failed for ' + file + '\n'
- + 'Expected: ' + expected + '\n'
- + 'Actual: ' + actual))
- })
-}
-function checkSync(file, expected, options) {
- expected = expected.toLowerCase().trim()
- var actual
- try {
- actual = getSync(file, options)
- } catch (er) {
- if (er.message) er.message += ' while getting shasum for ' + file
- throw er
- }
- if (actual !== expected) {
- var ex = new Error(
- 'shasum check failed for ' + file + '\n'
- + 'Expected: ' + expected + '\n'
- + 'Actual: ' + actual)
- throw ex
- }
-}
-
-
-function get(file, options, cb) {
- if (typeof options === 'function') {
- cb = options
- options = undefined
- }
- options = options || {}
- var algorithm = options.algorithm || 'sha1'
- var hash = crypto.createHash(algorithm)
- var source = fs.createReadStream(file)
- var errState = null
- source
- .on('error', function (er) {
- if (errState) return
- return cb(errState = er)
- })
- .on('data', function (chunk) {
- if (errState) return
- hash.update(chunk)
- })
- .on('end', function () {
- if (errState) return
- var actual = hash.digest("hex").toLowerCase().trim()
- cb(null, actual)
- })
-}
-
-function getSync(file, options) {
- options = options || {}
- var algorithm = options.algorithm || 'sha1'
- var hash = crypto.createHash(algorithm)
- var source = fs.readFileSync(file)
- hash.update(source)
- return hash.digest("hex").toLowerCase().trim()
-}
-
-function stream(expected, options) {
- expected = expected.toLowerCase().trim()
- options = options || {}
- var algorithm = options.algorithm || 'sha1'
- var hash = crypto.createHash(algorithm)
-
- var stream = new Transform()
- stream._transform = function (chunk, encoding, callback) {
- hash.update(chunk)
- stream.push(chunk)
- callback()
- }
- stream._flush = function (cb) {
- var actual = hash.digest("hex").toLowerCase().trim()
- if (actual === expected) return cb(null)
- cb(new Error(
- 'shasum check failed for:\n'
- + ' Expected: ' + expected + '\n'
- + ' Actual: ' + actual))
- this.push(null)
- }
- return stream
+'use strict'
+
+var Transform = require('stream').Transform || require('readable-stream').Transform
+var crypto = require('crypto')
+var fs
+try {
+ fs = require('graceful-fs')
+} catch (ex) {
+ fs = require('fs')
+}
+try {
+ process.binding('crypto')
+} catch (e) {
+ var er = new Error( 'crypto binding not found.\n'
+ + 'Please build node with openssl.\n'
+ + e.message )
+ throw er
+}
+
+exports.check = check
+exports.checkSync = checkSync
+exports.get = get
+exports.getSync = getSync
+exports.stream = stream
+
+function check(file, expected, options, cb) {
+ if (typeof options === 'function') {
+ cb = options
+ options = undefined
+ }
+ expected = expected.toLowerCase().trim()
+ get(file, options, function (er, actual) {
+ if (er) {
+ if (er.message) er.message += ' while getting shasum for ' + file
+ return cb(er)
+ }
+ if (actual === expected) return cb(null)
+ cb(new Error(
+ 'shasum check failed for ' + file + '\n'
+ + 'Expected: ' + expected + '\n'
+ + 'Actual: ' + actual))
+ })
+}
+function checkSync(file, expected, options) {
+ expected = expected.toLowerCase().trim()
+ var actual
+ try {
+ actual = getSync(file, options)
+ } catch (er) {
+ if (er.message) er.message += ' while getting shasum for ' + file
+ throw er
+ }
+ if (actual !== expected) {
+ var ex = new Error(
+ 'shasum check failed for ' + file + '\n'
+ + 'Expected: ' + expected + '\n'
+ + 'Actual: ' + actual)
+ throw ex
+ }
+}
+
+
+function get(file, options, cb) {
+ if (typeof options === 'function') {
+ cb = options
+ options = undefined
+ }
+ options = options || {}
+ var algorithm = options.algorithm || 'sha1'
+ var hash = crypto.createHash(algorithm)
+ var source = fs.createReadStream(file)
+ var errState = null
+ source
+ .on('error', function (er) {
+ if (errState) return
+ return cb(errState = er)
+ })
+ .on('data', function (chunk) {
+ if (errState) return
+ hash.update(chunk)
+ })
+ .on('end', function () {
+ if (errState) return
+ var actual = hash.digest("hex").toLowerCase().trim()
+ cb(null, actual)
+ })
+}
+
+function getSync(file, options) {
+ options = options || {}
+ var algorithm = options.algorithm || 'sha1'
+ var hash = crypto.createHash(algorithm)
+ var source = fs.readFileSync(file)
+ hash.update(source)
+ return hash.digest("hex").toLowerCase().trim()
+}
+
+function stream(expected, options) {
+ expected = expected.toLowerCase().trim()
+ options = options || {}
+ var algorithm = options.algorithm || 'sha1'
+ var hash = crypto.createHash(algorithm)
+
+ var stream = new Transform()
+ stream._transform = function (chunk, encoding, callback) {
+ hash.update(chunk)
+ stream.push(chunk)
+ callback()
+ }
+ stream._flush = function (cb) {
+ var actual = hash.digest("hex").toLowerCase().trim()
+ if (actual === expected) return cb(null)
+ cb(new Error(
+ 'shasum check failed for:\n'
+ + ' Expected: ' + expected + '\n'
+ + ' Actual: ' + actual))
+ this.push(null)
+ }
+ return stream
}
\ No newline at end of file
diff -Nru nodejs-0.11.14/deps/npm/node_modules/sha/LICENSE nodejs-0.11.15/deps/npm/node_modules/sha/LICENSE
--- nodejs-0.11.14/deps/npm/node_modules/sha/LICENSE 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/sha/LICENSE 2015-01-20 21:22:17.000000000 +0000
@@ -1,46 +1,46 @@
-Copyright (c) 2013 Forbes Lindesay
-
-The BSD License
-
-Redistribution and use in source and binary forms, with or without
-modification, are permitted provided that the following conditions
-are met:
-
-1. Redistributions of source code must retain the above copyright
- notice, this list of conditions and the following disclaimer.
-
-2. Redistributions in binary form must reproduce the above copyright
- notice, this list of conditions and the following disclaimer in the
- documentation and/or other materials provided with the distribution.
-
-THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
-PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS
-BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
-CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
-SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
-BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
-WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
-OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
-IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-
-The MIT License (MIT)
-
-Permission is hereby granted, free of charge, to any person obtaining a copy
-of this software and associated documentation files (the "Software"), to deal
-in the Software without restriction, including without limitation the rights
-to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-copies of the Software, and to permit persons to whom the Software is
-furnished to do so, subject to the following conditions:
-
-The above copyright notice and this permission notice shall be included in
-all copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+Copyright (c) 2013 Forbes Lindesay
+
+The BSD License
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions
+are met:
+
+1. Redistributions of source code must retain the above copyright
+ notice, this list of conditions and the following disclaimer.
+
+2. Redistributions in binary form must reproduce the above copyright
+ notice, this list of conditions and the following disclaimer in the
+ documentation and/or other materials provided with the distribution.
+
+THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
+ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS
+BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
+BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
+OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
+IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+The MIT License (MIT)
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
\ No newline at end of file
diff -Nru nodejs-0.11.14/deps/npm/node_modules/sha/node_modules/readable-stream/float.patch nodejs-0.11.15/deps/npm/node_modules/sha/node_modules/readable-stream/float.patch
--- nodejs-0.11.14/deps/npm/node_modules/sha/node_modules/readable-stream/float.patch 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/sha/node_modules/readable-stream/float.patch 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,923 @@
+diff --git a/lib/_stream_duplex.js b/lib/_stream_duplex.js
+index c5a741c..a2e0d8e 100644
+--- a/lib/_stream_duplex.js
++++ b/lib/_stream_duplex.js
+@@ -26,8 +26,8 @@
+
+ module.exports = Duplex;
+ var util = require('util');
+-var Readable = require('_stream_readable');
+-var Writable = require('_stream_writable');
++var Readable = require('./_stream_readable');
++var Writable = require('./_stream_writable');
+
+ util.inherits(Duplex, Readable);
+
+diff --git a/lib/_stream_passthrough.js b/lib/_stream_passthrough.js
+index a5e9864..330c247 100644
+--- a/lib/_stream_passthrough.js
++++ b/lib/_stream_passthrough.js
+@@ -25,7 +25,7 @@
+
+ module.exports = PassThrough;
+
+-var Transform = require('_stream_transform');
++var Transform = require('./_stream_transform');
+ var util = require('util');
+ util.inherits(PassThrough, Transform);
+
+diff --git a/lib/_stream_readable.js b/lib/_stream_readable.js
+index 0c3fe3e..90a8298 100644
+--- a/lib/_stream_readable.js
++++ b/lib/_stream_readable.js
+@@ -23,10 +23,34 @@ module.exports = Readable;
+ Readable.ReadableState = ReadableState;
+
+ var EE = require('events').EventEmitter;
++if (!EE.listenerCount) EE.listenerCount = function(emitter, type) {
++ return emitter.listeners(type).length;
++};
++
++if (!global.setImmediate) global.setImmediate = function setImmediate(fn) {
++ return setTimeout(fn, 0);
++};
++if (!global.clearImmediate) global.clearImmediate = function clearImmediate(i) {
++ return clearTimeout(i);
++};
++
+ var Stream = require('stream');
+ var util = require('util');
++if (!util.isUndefined) {
++ var utilIs = require('core-util-is');
++ for (var f in utilIs) {
++ util[f] = utilIs[f];
++ }
++}
+ var StringDecoder;
+-var debug = util.debuglog('stream');
++var debug;
++if (util.debuglog)
++ debug = util.debuglog('stream');
++else try {
++ debug = require('debuglog')('stream');
++} catch (er) {
++ debug = function() {};
++}
+
+ util.inherits(Readable, Stream);
+
+@@ -380,7 +404,7 @@ function chunkInvalid(state, chunk) {
+
+
+ function onEofChunk(stream, state) {
+- if (state.decoder && !state.ended) {
++ if (state.decoder && !state.ended && state.decoder.end) {
+ var chunk = state.decoder.end();
+ if (chunk && chunk.length) {
+ state.buffer.push(chunk);
+diff --git a/lib/_stream_transform.js b/lib/_stream_transform.js
+index b1f9fcc..b0caf57 100644
+--- a/lib/_stream_transform.js
++++ b/lib/_stream_transform.js
+@@ -64,8 +64,14 @@
+
+ module.exports = Transform;
+
+-var Duplex = require('_stream_duplex');
++var Duplex = require('./_stream_duplex');
+ var util = require('util');
++if (!util.isUndefined) {
++ var utilIs = require('core-util-is');
++ for (var f in utilIs) {
++ util[f] = utilIs[f];
++ }
++}
+ util.inherits(Transform, Duplex);
+
+
+diff --git a/lib/_stream_writable.js b/lib/_stream_writable.js
+index ba2e920..f49288b 100644
+--- a/lib/_stream_writable.js
++++ b/lib/_stream_writable.js
+@@ -27,6 +27,12 @@ module.exports = Writable;
+ Writable.WritableState = WritableState;
+
+ var util = require('util');
++if (!util.isUndefined) {
++ var utilIs = require('core-util-is');
++ for (var f in utilIs) {
++ util[f] = utilIs[f];
++ }
++}
+ var Stream = require('stream');
+
+ util.inherits(Writable, Stream);
+@@ -119,7 +125,7 @@ function WritableState(options, stream) {
+ function Writable(options) {
+ // Writable ctor is applied to Duplexes, though they're not
+ // instanceof Writable, they're instanceof Readable.
+- if (!(this instanceof Writable) && !(this instanceof Stream.Duplex))
++ if (!(this instanceof Writable) && !(this instanceof require('./_stream_duplex')))
+ return new Writable(options);
+
+ this._writableState = new WritableState(options, this);
+diff --git a/test/simple/test-stream-big-push.js b/test/simple/test-stream-big-push.js
+index e3787e4..8cd2127 100644
+--- a/test/simple/test-stream-big-push.js
++++ b/test/simple/test-stream-big-push.js
+@@ -21,7 +21,7 @@
+
+ var common = require('../common');
+ var assert = require('assert');
+-var stream = require('stream');
++var stream = require('../../');
+ var str = 'asdfasdfasdfasdfasdf';
+
+ var r = new stream.Readable({
+diff --git a/test/simple/test-stream-end-paused.js b/test/simple/test-stream-end-paused.js
+index bb73777..d40efc7 100644
+--- a/test/simple/test-stream-end-paused.js
++++ b/test/simple/test-stream-end-paused.js
+@@ -25,7 +25,7 @@ var gotEnd = false;
+
+ // Make sure we don't miss the end event for paused 0-length streams
+
+-var Readable = require('stream').Readable;
++var Readable = require('../../').Readable;
+ var stream = new Readable();
+ var calledRead = false;
+ stream._read = function() {
+diff --git a/test/simple/test-stream-pipe-after-end.js b/test/simple/test-stream-pipe-after-end.js
+index b46ee90..0be8366 100644
+--- a/test/simple/test-stream-pipe-after-end.js
++++ b/test/simple/test-stream-pipe-after-end.js
+@@ -22,8 +22,8 @@
+ var common = require('../common');
+ var assert = require('assert');
+
+-var Readable = require('_stream_readable');
+-var Writable = require('_stream_writable');
++var Readable = require('../../lib/_stream_readable');
++var Writable = require('../../lib/_stream_writable');
+ var util = require('util');
+
+ util.inherits(TestReadable, Readable);
+diff --git a/test/simple/test-stream-pipe-cleanup.js b/test/simple/test-stream-pipe-cleanup.js
+deleted file mode 100644
+index f689358..0000000
+--- a/test/simple/test-stream-pipe-cleanup.js
++++ /dev/null
+@@ -1,122 +0,0 @@
+-// Copyright Joyent, Inc. and other Node contributors.
+-//
+-// Permission is hereby granted, free of charge, to any person obtaining a
+-// copy of this software and associated documentation files (the
+-// "Software"), to deal in the Software without restriction, including
+-// without limitation the rights to use, copy, modify, merge, publish,
+-// distribute, sublicense, and/or sell copies of the Software, and to permit
+-// persons to whom the Software is furnished to do so, subject to the
+-// following conditions:
+-//
+-// The above copyright notice and this permission notice shall be included
+-// in all copies or substantial portions of the Software.
+-//
+-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+-// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
+-// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
+-// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
+-// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
+-// USE OR OTHER DEALINGS IN THE SOFTWARE.
+-
+-// This test asserts that Stream.prototype.pipe does not leave listeners
+-// hanging on the source or dest.
+-
+-var common = require('../common');
+-var stream = require('stream');
+-var assert = require('assert');
+-var util = require('util');
+-
+-function Writable() {
+- this.writable = true;
+- this.endCalls = 0;
+- stream.Stream.call(this);
+-}
+-util.inherits(Writable, stream.Stream);
+-Writable.prototype.end = function() {
+- this.endCalls++;
+-};
+-
+-Writable.prototype.destroy = function() {
+- this.endCalls++;
+-};
+-
+-function Readable() {
+- this.readable = true;
+- stream.Stream.call(this);
+-}
+-util.inherits(Readable, stream.Stream);
+-
+-function Duplex() {
+- this.readable = true;
+- Writable.call(this);
+-}
+-util.inherits(Duplex, Writable);
+-
+-var i = 0;
+-var limit = 100;
+-
+-var w = new Writable();
+-
+-var r;
+-
+-for (i = 0; i < limit; i++) {
+- r = new Readable();
+- r.pipe(w);
+- r.emit('end');
+-}
+-assert.equal(0, r.listeners('end').length);
+-assert.equal(limit, w.endCalls);
+-
+-w.endCalls = 0;
+-
+-for (i = 0; i < limit; i++) {
+- r = new Readable();
+- r.pipe(w);
+- r.emit('close');
+-}
+-assert.equal(0, r.listeners('close').length);
+-assert.equal(limit, w.endCalls);
+-
+-w.endCalls = 0;
+-
+-r = new Readable();
+-
+-for (i = 0; i < limit; i++) {
+- w = new Writable();
+- r.pipe(w);
+- w.emit('close');
+-}
+-assert.equal(0, w.listeners('close').length);
+-
+-r = new Readable();
+-w = new Writable();
+-var d = new Duplex();
+-r.pipe(d); // pipeline A
+-d.pipe(w); // pipeline B
+-assert.equal(r.listeners('end').length, 2); // A.onend, A.cleanup
+-assert.equal(r.listeners('close').length, 2); // A.onclose, A.cleanup
+-assert.equal(d.listeners('end').length, 2); // B.onend, B.cleanup
+-assert.equal(d.listeners('close').length, 3); // A.cleanup, B.onclose, B.cleanup
+-assert.equal(w.listeners('end').length, 0);
+-assert.equal(w.listeners('close').length, 1); // B.cleanup
+-
+-r.emit('end');
+-assert.equal(d.endCalls, 1);
+-assert.equal(w.endCalls, 0);
+-assert.equal(r.listeners('end').length, 0);
+-assert.equal(r.listeners('close').length, 0);
+-assert.equal(d.listeners('end').length, 2); // B.onend, B.cleanup
+-assert.equal(d.listeners('close').length, 2); // B.onclose, B.cleanup
+-assert.equal(w.listeners('end').length, 0);
+-assert.equal(w.listeners('close').length, 1); // B.cleanup
+-
+-d.emit('end');
+-assert.equal(d.endCalls, 1);
+-assert.equal(w.endCalls, 1);
+-assert.equal(r.listeners('end').length, 0);
+-assert.equal(r.listeners('close').length, 0);
+-assert.equal(d.listeners('end').length, 0);
+-assert.equal(d.listeners('close').length, 0);
+-assert.equal(w.listeners('end').length, 0);
+-assert.equal(w.listeners('close').length, 0);
+diff --git a/test/simple/test-stream-pipe-error-handling.js b/test/simple/test-stream-pipe-error-handling.js
+index c5d724b..c7d6b7d 100644
+--- a/test/simple/test-stream-pipe-error-handling.js
++++ b/test/simple/test-stream-pipe-error-handling.js
+@@ -21,7 +21,7 @@
+
+ var common = require('../common');
+ var assert = require('assert');
+-var Stream = require('stream').Stream;
++var Stream = require('../../').Stream;
+
+ (function testErrorListenerCatches() {
+ var source = new Stream();
+diff --git a/test/simple/test-stream-pipe-event.js b/test/simple/test-stream-pipe-event.js
+index cb9d5fe..56f8d61 100644
+--- a/test/simple/test-stream-pipe-event.js
++++ b/test/simple/test-stream-pipe-event.js
+@@ -20,7 +20,7 @@
+ // USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+ var common = require('../common');
+-var stream = require('stream');
++var stream = require('../../');
+ var assert = require('assert');
+ var util = require('util');
+
+diff --git a/test/simple/test-stream-push-order.js b/test/simple/test-stream-push-order.js
+index f2e6ec2..a5c9bf9 100644
+--- a/test/simple/test-stream-push-order.js
++++ b/test/simple/test-stream-push-order.js
+@@ -20,7 +20,7 @@
+ // USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+ var common = require('../common.js');
+-var Readable = require('stream').Readable;
++var Readable = require('../../').Readable;
+ var assert = require('assert');
+
+ var s = new Readable({
+diff --git a/test/simple/test-stream-push-strings.js b/test/simple/test-stream-push-strings.js
+index 06f43dc..1701a9a 100644
+--- a/test/simple/test-stream-push-strings.js
++++ b/test/simple/test-stream-push-strings.js
+@@ -22,7 +22,7 @@
+ var common = require('../common');
+ var assert = require('assert');
+
+-var Readable = require('stream').Readable;
++var Readable = require('../../').Readable;
+ var util = require('util');
+
+ util.inherits(MyStream, Readable);
+diff --git a/test/simple/test-stream-readable-event.js b/test/simple/test-stream-readable-event.js
+index ba6a577..a8e6f7b 100644
+--- a/test/simple/test-stream-readable-event.js
++++ b/test/simple/test-stream-readable-event.js
+@@ -22,7 +22,7 @@
+ var common = require('../common');
+ var assert = require('assert');
+
+-var Readable = require('stream').Readable;
++var Readable = require('../../').Readable;
+
+ (function first() {
+ // First test, not reading when the readable is added.
+diff --git a/test/simple/test-stream-readable-flow-recursion.js b/test/simple/test-stream-readable-flow-recursion.js
+index 2891ad6..11689ba 100644
+--- a/test/simple/test-stream-readable-flow-recursion.js
++++ b/test/simple/test-stream-readable-flow-recursion.js
+@@ -27,7 +27,7 @@ var assert = require('assert');
+ // more data continuously, but without triggering a nextTick
+ // warning or RangeError.
+
+-var Readable = require('stream').Readable;
++var Readable = require('../../').Readable;
+
+ // throw an error if we trigger a nextTick warning.
+ process.throwDeprecation = true;
+diff --git a/test/simple/test-stream-unshift-empty-chunk.js b/test/simple/test-stream-unshift-empty-chunk.js
+index 0c96476..7827538 100644
+--- a/test/simple/test-stream-unshift-empty-chunk.js
++++ b/test/simple/test-stream-unshift-empty-chunk.js
+@@ -24,7 +24,7 @@ var assert = require('assert');
+
+ // This test verifies that stream.unshift(Buffer(0)) or
+ // stream.unshift('') does not set state.reading=false.
+-var Readable = require('stream').Readable;
++var Readable = require('../../').Readable;
+
+ var r = new Readable();
+ var nChunks = 10;
+diff --git a/test/simple/test-stream-unshift-read-race.js b/test/simple/test-stream-unshift-read-race.js
+index 83fd9fa..17c18aa 100644
+--- a/test/simple/test-stream-unshift-read-race.js
++++ b/test/simple/test-stream-unshift-read-race.js
+@@ -29,7 +29,7 @@ var assert = require('assert');
+ // 3. push() after the EOF signaling null is an error.
+ // 4. _read() is not called after pushing the EOF null chunk.
+
+-var stream = require('stream');
++var stream = require('../../');
+ var hwm = 10;
+ var r = stream.Readable({ highWaterMark: hwm });
+ var chunks = 10;
+@@ -51,7 +51,14 @@ r._read = function(n) {
+
+ function push(fast) {
+ assert(!pushedNull, 'push() after null push');
+- var c = pos >= data.length ? null : data.slice(pos, pos + n);
++ var c;
++ if (pos >= data.length)
++ c = null;
++ else {
++ if (n + pos > data.length)
++ n = data.length - pos;
++ c = data.slice(pos, pos + n);
++ }
+ pushedNull = c === null;
+ if (fast) {
+ pos += n;
+diff --git a/test/simple/test-stream-writev.js b/test/simple/test-stream-writev.js
+index 5b49e6e..b5321f3 100644
+--- a/test/simple/test-stream-writev.js
++++ b/test/simple/test-stream-writev.js
+@@ -22,7 +22,7 @@
+ var common = require('../common');
+ var assert = require('assert');
+
+-var stream = require('stream');
++var stream = require('../../');
+
+ var queue = [];
+ for (var decode = 0; decode < 2; decode++) {
+diff --git a/test/simple/test-stream2-basic.js b/test/simple/test-stream2-basic.js
+index 3814bf0..248c1be 100644
+--- a/test/simple/test-stream2-basic.js
++++ b/test/simple/test-stream2-basic.js
+@@ -21,7 +21,7 @@
+
+
+ var common = require('../common.js');
+-var R = require('_stream_readable');
++var R = require('../../lib/_stream_readable');
+ var assert = require('assert');
+
+ var util = require('util');
+diff --git a/test/simple/test-stream2-compatibility.js b/test/simple/test-stream2-compatibility.js
+index 6cdd4e9..f0fa84b 100644
+--- a/test/simple/test-stream2-compatibility.js
++++ b/test/simple/test-stream2-compatibility.js
+@@ -21,7 +21,7 @@
+
+
+ var common = require('../common.js');
+-var R = require('_stream_readable');
++var R = require('../../lib/_stream_readable');
+ var assert = require('assert');
+
+ var util = require('util');
+diff --git a/test/simple/test-stream2-finish-pipe.js b/test/simple/test-stream2-finish-pipe.js
+index 39b274f..006a19b 100644
+--- a/test/simple/test-stream2-finish-pipe.js
++++ b/test/simple/test-stream2-finish-pipe.js
+@@ -20,7 +20,7 @@
+ // USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+ var common = require('../common.js');
+-var stream = require('stream');
++var stream = require('../../');
+ var Buffer = require('buffer').Buffer;
+
+ var r = new stream.Readable();
+diff --git a/test/simple/test-stream2-fs.js b/test/simple/test-stream2-fs.js
+deleted file mode 100644
+index e162406..0000000
+--- a/test/simple/test-stream2-fs.js
++++ /dev/null
+@@ -1,72 +0,0 @@
+-// Copyright Joyent, Inc. and other Node contributors.
+-//
+-// Permission is hereby granted, free of charge, to any person obtaining a
+-// copy of this software and associated documentation files (the
+-// "Software"), to deal in the Software without restriction, including
+-// without limitation the rights to use, copy, modify, merge, publish,
+-// distribute, sublicense, and/or sell copies of the Software, and to permit
+-// persons to whom the Software is furnished to do so, subject to the
+-// following conditions:
+-//
+-// The above copyright notice and this permission notice shall be included
+-// in all copies or substantial portions of the Software.
+-//
+-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+-// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
+-// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
+-// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
+-// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
+-// USE OR OTHER DEALINGS IN THE SOFTWARE.
+-
+-
+-var common = require('../common.js');
+-var R = require('_stream_readable');
+-var assert = require('assert');
+-
+-var fs = require('fs');
+-var FSReadable = fs.ReadStream;
+-
+-var path = require('path');
+-var file = path.resolve(common.fixturesDir, 'x1024.txt');
+-
+-var size = fs.statSync(file).size;
+-
+-var expectLengths = [1024];
+-
+-var util = require('util');
+-var Stream = require('stream');
+-
+-util.inherits(TestWriter, Stream);
+-
+-function TestWriter() {
+- Stream.apply(this);
+- this.buffer = [];
+- this.length = 0;
+-}
+-
+-TestWriter.prototype.write = function(c) {
+- this.buffer.push(c.toString());
+- this.length += c.length;
+- return true;
+-};
+-
+-TestWriter.prototype.end = function(c) {
+- if (c) this.buffer.push(c.toString());
+- this.emit('results', this.buffer);
+-}
+-
+-var r = new FSReadable(file);
+-var w = new TestWriter();
+-
+-w.on('results', function(res) {
+- console.error(res, w.length);
+- assert.equal(w.length, size);
+- var l = 0;
+- assert.deepEqual(res.map(function (c) {
+- return c.length;
+- }), expectLengths);
+- console.log('ok');
+-});
+-
+-r.pipe(w);
+diff --git a/test/simple/test-stream2-httpclient-response-end.js b/test/simple/test-stream2-httpclient-response-end.js
+deleted file mode 100644
+index 15cffc2..0000000
+--- a/test/simple/test-stream2-httpclient-response-end.js
++++ /dev/null
+@@ -1,52 +0,0 @@
+-// Copyright Joyent, Inc. and other Node contributors.
+-//
+-// Permission is hereby granted, free of charge, to any person obtaining a
+-// copy of this software and associated documentation files (the
+-// "Software"), to deal in the Software without restriction, including
+-// without limitation the rights to use, copy, modify, merge, publish,
+-// distribute, sublicense, and/or sell copies of the Software, and to permit
+-// persons to whom the Software is furnished to do so, subject to the
+-// following conditions:
+-//
+-// The above copyright notice and this permission notice shall be included
+-// in all copies or substantial portions of the Software.
+-//
+-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+-// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
+-// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
+-// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
+-// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
+-// USE OR OTHER DEALINGS IN THE SOFTWARE.
+-
+-var common = require('../common.js');
+-var assert = require('assert');
+-var http = require('http');
+-var msg = 'Hello';
+-var readable_event = false;
+-var end_event = false;
+-var server = http.createServer(function(req, res) {
+- res.writeHead(200, {'Content-Type': 'text/plain'});
+- res.end(msg);
+-}).listen(common.PORT, function() {
+- http.get({port: common.PORT}, function(res) {
+- var data = '';
+- res.on('readable', function() {
+- console.log('readable event');
+- readable_event = true;
+- data += res.read();
+- });
+- res.on('end', function() {
+- console.log('end event');
+- end_event = true;
+- assert.strictEqual(msg, data);
+- server.close();
+- });
+- });
+-});
+-
+-process.on('exit', function() {
+- assert(readable_event);
+- assert(end_event);
+-});
+-
+diff --git a/test/simple/test-stream2-large-read-stall.js b/test/simple/test-stream2-large-read-stall.js
+index 2fbfbca..667985b 100644
+--- a/test/simple/test-stream2-large-read-stall.js
++++ b/test/simple/test-stream2-large-read-stall.js
+@@ -30,7 +30,7 @@ var PUSHSIZE = 20;
+ var PUSHCOUNT = 1000;
+ var HWM = 50;
+
+-var Readable = require('stream').Readable;
++var Readable = require('../../').Readable;
+ var r = new Readable({
+ highWaterMark: HWM
+ });
+@@ -39,23 +39,23 @@ var rs = r._readableState;
+ r._read = push;
+
+ r.on('readable', function() {
+- console.error('>> readable');
++ //console.error('>> readable');
+ do {
+- console.error(' > read(%d)', READSIZE);
++ //console.error(' > read(%d)', READSIZE);
+ var ret = r.read(READSIZE);
+- console.error(' < %j (%d remain)', ret && ret.length, rs.length);
++ //console.error(' < %j (%d remain)', ret && ret.length, rs.length);
+ } while (ret && ret.length === READSIZE);
+
+- console.error('<< after read()',
+- ret && ret.length,
+- rs.needReadable,
+- rs.length);
++ //console.error('<< after read()',
++ // ret && ret.length,
++ // rs.needReadable,
++ // rs.length);
+ });
+
+ var endEmitted = false;
+ r.on('end', function() {
+ endEmitted = true;
+- console.error('end');
++ //console.error('end');
+ });
+
+ var pushes = 0;
+@@ -64,11 +64,11 @@ function push() {
+ return;
+
+ if (pushes++ === PUSHCOUNT) {
+- console.error(' push(EOF)');
++ //console.error(' push(EOF)');
+ return r.push(null);
+ }
+
+- console.error(' push #%d', pushes);
++ //console.error(' push #%d', pushes);
+ if (r.push(new Buffer(PUSHSIZE)))
+ setTimeout(push);
+ }
+diff --git a/test/simple/test-stream2-objects.js b/test/simple/test-stream2-objects.js
+index 3e6931d..ff47d89 100644
+--- a/test/simple/test-stream2-objects.js
++++ b/test/simple/test-stream2-objects.js
+@@ -21,8 +21,8 @@
+
+
+ var common = require('../common.js');
+-var Readable = require('_stream_readable');
+-var Writable = require('_stream_writable');
++var Readable = require('../../lib/_stream_readable');
++var Writable = require('../../lib/_stream_writable');
+ var assert = require('assert');
+
+ // tiny node-tap lookalike.
+diff --git a/test/simple/test-stream2-pipe-error-handling.js b/test/simple/test-stream2-pipe-error-handling.js
+index cf7531c..e3f3e4e 100644
+--- a/test/simple/test-stream2-pipe-error-handling.js
++++ b/test/simple/test-stream2-pipe-error-handling.js
+@@ -21,7 +21,7 @@
+
+ var common = require('../common');
+ var assert = require('assert');
+-var stream = require('stream');
++var stream = require('../../');
+
+ (function testErrorListenerCatches() {
+ var count = 1000;
+diff --git a/test/simple/test-stream2-pipe-error-once-listener.js b/test/simple/test-stream2-pipe-error-once-listener.js
+index 5e8e3cb..53b2616 100755
+--- a/test/simple/test-stream2-pipe-error-once-listener.js
++++ b/test/simple/test-stream2-pipe-error-once-listener.js
+@@ -24,7 +24,7 @@ var common = require('../common.js');
+ var assert = require('assert');
+
+ var util = require('util');
+-var stream = require('stream');
++var stream = require('../../');
+
+
+ var Read = function() {
+diff --git a/test/simple/test-stream2-push.js b/test/simple/test-stream2-push.js
+index b63edc3..eb2b0e9 100644
+--- a/test/simple/test-stream2-push.js
++++ b/test/simple/test-stream2-push.js
+@@ -20,7 +20,7 @@
+ // USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+ var common = require('../common.js');
+-var stream = require('stream');
++var stream = require('../../');
+ var Readable = stream.Readable;
+ var Writable = stream.Writable;
+ var assert = require('assert');
+diff --git a/test/simple/test-stream2-read-sync-stack.js b/test/simple/test-stream2-read-sync-stack.js
+index e8a7305..9740a47 100644
+--- a/test/simple/test-stream2-read-sync-stack.js
++++ b/test/simple/test-stream2-read-sync-stack.js
+@@ -21,7 +21,7 @@
+
+ var common = require('../common');
+ var assert = require('assert');
+-var Readable = require('stream').Readable;
++var Readable = require('../../').Readable;
+ var r = new Readable();
+ var N = 256 * 1024;
+
+diff --git a/test/simple/test-stream2-readable-empty-buffer-no-eof.js b/test/simple/test-stream2-readable-empty-buffer-no-eof.js
+index cd30178..4b1659d 100644
+--- a/test/simple/test-stream2-readable-empty-buffer-no-eof.js
++++ b/test/simple/test-stream2-readable-empty-buffer-no-eof.js
+@@ -22,10 +22,9 @@
+ var common = require('../common');
+ var assert = require('assert');
+
+-var Readable = require('stream').Readable;
++var Readable = require('../../').Readable;
+
+ test1();
+-test2();
+
+ function test1() {
+ var r = new Readable();
+@@ -88,31 +87,3 @@ function test1() {
+ console.log('ok');
+ });
+ }
+-
+-function test2() {
+- var r = new Readable({ encoding: 'base64' });
+- var reads = 5;
+- r._read = function(n) {
+- if (!reads--)
+- return r.push(null); // EOF
+- else
+- return r.push(new Buffer('x'));
+- };
+-
+- var results = [];
+- function flow() {
+- var chunk;
+- while (null !== (chunk = r.read()))
+- results.push(chunk + '');
+- }
+- r.on('readable', flow);
+- r.on('end', function() {
+- results.push('EOF');
+- });
+- flow();
+-
+- process.on('exit', function() {
+- assert.deepEqual(results, [ 'eHh4', 'eHg=', 'EOF' ]);
+- console.log('ok');
+- });
+-}
+diff --git a/test/simple/test-stream2-readable-from-list.js b/test/simple/test-stream2-readable-from-list.js
+index 7c96ffe..04a96f5 100644
+--- a/test/simple/test-stream2-readable-from-list.js
++++ b/test/simple/test-stream2-readable-from-list.js
+@@ -21,7 +21,7 @@
+
+ var assert = require('assert');
+ var common = require('../common.js');
+-var fromList = require('_stream_readable')._fromList;
++var fromList = require('../../lib/_stream_readable')._fromList;
+
+ // tiny node-tap lookalike.
+ var tests = [];
+diff --git a/test/simple/test-stream2-readable-legacy-drain.js b/test/simple/test-stream2-readable-legacy-drain.js
+index 675da8e..51fd3d5 100644
+--- a/test/simple/test-stream2-readable-legacy-drain.js
++++ b/test/simple/test-stream2-readable-legacy-drain.js
+@@ -22,7 +22,7 @@
+ var common = require('../common');
+ var assert = require('assert');
+
+-var Stream = require('stream');
++var Stream = require('../../');
+ var Readable = Stream.Readable;
+
+ var r = new Readable();
+diff --git a/test/simple/test-stream2-readable-non-empty-end.js b/test/simple/test-stream2-readable-non-empty-end.js
+index 7314ae7..c971898 100644
+--- a/test/simple/test-stream2-readable-non-empty-end.js
++++ b/test/simple/test-stream2-readable-non-empty-end.js
+@@ -21,7 +21,7 @@
+
+ var assert = require('assert');
+ var common = require('../common.js');
+-var Readable = require('_stream_readable');
++var Readable = require('../../lib/_stream_readable');
+
+ var len = 0;
+ var chunks = new Array(10);
+diff --git a/test/simple/test-stream2-readable-wrap-empty.js b/test/simple/test-stream2-readable-wrap-empty.js
+index 2e5cf25..fd8a3dc 100644
+--- a/test/simple/test-stream2-readable-wrap-empty.js
++++ b/test/simple/test-stream2-readable-wrap-empty.js
+@@ -22,7 +22,7 @@
+ var common = require('../common');
+ var assert = require('assert');
+
+-var Readable = require('_stream_readable');
++var Readable = require('../../lib/_stream_readable');
+ var EE = require('events').EventEmitter;
+
+ var oldStream = new EE();
+diff --git a/test/simple/test-stream2-readable-wrap.js b/test/simple/test-stream2-readable-wrap.js
+index 90eea01..6b177f7 100644
+--- a/test/simple/test-stream2-readable-wrap.js
++++ b/test/simple/test-stream2-readable-wrap.js
+@@ -22,8 +22,8 @@
+ var common = require('../common');
+ var assert = require('assert');
+
+-var Readable = require('_stream_readable');
+-var Writable = require('_stream_writable');
++var Readable = require('../../lib/_stream_readable');
++var Writable = require('../../lib/_stream_writable');
+ var EE = require('events').EventEmitter;
+
+ var testRuns = 0, completedRuns = 0;
+diff --git a/test/simple/test-stream2-set-encoding.js b/test/simple/test-stream2-set-encoding.js
+index 5d2c32a..685531b 100644
+--- a/test/simple/test-stream2-set-encoding.js
++++ b/test/simple/test-stream2-set-encoding.js
+@@ -22,7 +22,7 @@
+
+ var common = require('../common.js');
+ var assert = require('assert');
+-var R = require('_stream_readable');
++var R = require('../../lib/_stream_readable');
+ var util = require('util');
+
+ // tiny node-tap lookalike.
+diff --git a/test/simple/test-stream2-transform.js b/test/simple/test-stream2-transform.js
+index 9c9ddd8..a0cacc6 100644
+--- a/test/simple/test-stream2-transform.js
++++ b/test/simple/test-stream2-transform.js
+@@ -21,8 +21,8 @@
+
+ var assert = require('assert');
+ var common = require('../common.js');
+-var PassThrough = require('_stream_passthrough');
+-var Transform = require('_stream_transform');
++var PassThrough = require('../../').PassThrough;
++var Transform = require('../../').Transform;
+
+ // tiny node-tap lookalike.
+ var tests = [];
+diff --git a/test/simple/test-stream2-unpipe-drain.js b/test/simple/test-stream2-unpipe-drain.js
+index d66dc3c..365b327 100644
+--- a/test/simple/test-stream2-unpipe-drain.js
++++ b/test/simple/test-stream2-unpipe-drain.js
+@@ -22,7 +22,7 @@
+
+ var common = require('../common.js');
+ var assert = require('assert');
+-var stream = require('stream');
++var stream = require('../../');
+ var crypto = require('crypto');
+
+ var util = require('util');
+diff --git a/test/simple/test-stream2-unpipe-leak.js b/test/simple/test-stream2-unpipe-leak.js
+index 99f8746..17c92ae 100644
+--- a/test/simple/test-stream2-unpipe-leak.js
++++ b/test/simple/test-stream2-unpipe-leak.js
+@@ -22,7 +22,7 @@
+
+ var common = require('../common.js');
+ var assert = require('assert');
+-var stream = require('stream');
++var stream = require('../../');
+
+ var chunk = new Buffer('hallo');
+
+diff --git a/test/simple/test-stream2-writable.js b/test/simple/test-stream2-writable.js
+index 704100c..209c3a6 100644
+--- a/test/simple/test-stream2-writable.js
++++ b/test/simple/test-stream2-writable.js
+@@ -20,8 +20,8 @@
+ // USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+ var common = require('../common.js');
+-var W = require('_stream_writable');
+-var D = require('_stream_duplex');
++var W = require('../../').Writable;
++var D = require('../../').Duplex;
+ var assert = require('assert');
+
+ var util = require('util');
+diff --git a/test/simple/test-stream3-pause-then-read.js b/test/simple/test-stream3-pause-then-read.js
+index b91bde3..2f72c15 100644
+--- a/test/simple/test-stream3-pause-then-read.js
++++ b/test/simple/test-stream3-pause-then-read.js
+@@ -22,7 +22,7 @@
+ var common = require('../common');
+ var assert = require('assert');
+
+-var stream = require('stream');
++var stream = require('../../');
+ var Readable = stream.Readable;
+ var Writable = stream.Writable;
+
diff -Nru nodejs-0.11.14/deps/npm/node_modules/sha/node_modules/readable-stream/lib/_stream_readable.js nodejs-0.11.15/deps/npm/node_modules/sha/node_modules/readable-stream/lib/_stream_readable.js
--- nodejs-0.11.14/deps/npm/node_modules/sha/node_modules/readable-stream/lib/_stream_readable.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/sha/node_modules/readable-stream/lib/_stream_readable.js 2015-01-20 21:22:17.000000000 +0000
@@ -49,15 +49,29 @@
var StringDecoder;
+
+/**/
+var debug = require('util');
+if (debug && debug.debuglog) {
+ debug = debug.debuglog('stream');
+} else {
+ debug = function () {};
+}
+/* */
+
+
util.inherits(Readable, Stream);
function ReadableState(options, stream) {
+ var Duplex = require('./_stream_duplex');
+
options = options || {};
// the point at which it stops calling _read() to fill the buffer
// Note: 0 is a valid value, means "don't call _read preemptively ever"
var hwm = options.highWaterMark;
- this.highWaterMark = (hwm || hwm === 0) ? hwm : 16 * 1024;
+ var defaultHwm = options.objectMode ? 16 : 16 * 1024;
+ this.highWaterMark = (hwm || hwm === 0) ? hwm : defaultHwm;
// cast to ints.
this.highWaterMark = ~~this.highWaterMark;
@@ -66,19 +80,13 @@
this.length = 0;
this.pipes = null;
this.pipesCount = 0;
- this.flowing = false;
+ this.flowing = null;
this.ended = false;
this.endEmitted = false;
this.reading = false;
- // In streams that never have any data, and do push(null) right away,
- // the consumer can miss the 'end' event if they do some I/O before
- // consuming the stream. So, we don't emit('end') until some reading
- // happens.
- this.calledRead = false;
-
// a flag to be able to tell if the onwrite cb is called immediately,
- // or on a later tick. We set this to true at first, becuase any
+ // or on a later tick. We set this to true at first, because any
// actions that shouldn't happen until "later" should generally also
// not happen before the first write call.
this.sync = true;
@@ -94,6 +102,9 @@
// make all the buffer merging and length checks go away
this.objectMode = !!options.objectMode;
+ if (stream instanceof Duplex)
+ this.objectMode = this.objectMode || !!options.readableObjectMode;
+
// Crypto is kind of old and crusty. Historically, its default string
// encoding is 'binary' so we have to make this configurable.
// Everything else in the universe uses 'utf8', though.
@@ -120,6 +131,8 @@
}
function Readable(options) {
+ var Duplex = require('./_stream_duplex');
+
if (!(this instanceof Readable))
return new Readable(options);
@@ -138,7 +151,7 @@
Readable.prototype.push = function(chunk, encoding) {
var state = this._readableState;
- if (typeof chunk === 'string' && !state.objectMode) {
+ if (util.isString(chunk) && !state.objectMode) {
encoding = encoding || state.defaultEncoding;
if (encoding !== state.encoding) {
chunk = new Buffer(chunk, encoding);
@@ -159,7 +172,7 @@
var er = chunkInvalid(state, chunk);
if (er) {
stream.emit('error', er);
- } else if (chunk === null || chunk === undefined) {
+ } else if (util.isNullOrUndefined(chunk)) {
state.reading = false;
if (!state.ended)
onEofChunk(stream, state);
@@ -174,17 +187,24 @@
if (state.decoder && !addToFront && !encoding)
chunk = state.decoder.write(chunk);
- // update the buffer info.
- state.length += state.objectMode ? 1 : chunk.length;
- if (addToFront) {
- state.buffer.unshift(chunk);
- } else {
+ if (!addToFront)
state.reading = false;
- state.buffer.push(chunk);
- }
- if (state.needReadable)
- emitReadable(stream);
+ // if we want the data now, just emit it.
+ if (state.flowing && state.length === 0 && !state.sync) {
+ stream.emit('data', chunk);
+ stream.read(0);
+ } else {
+ // update the buffer info.
+ state.length += state.objectMode ? 1 : chunk.length;
+ if (addToFront)
+ state.buffer.unshift(chunk);
+ else
+ state.buffer.push(chunk);
+
+ if (state.needReadable)
+ emitReadable(stream);
+ }
maybeReadMore(stream, state);
}
@@ -217,6 +237,7 @@
StringDecoder = require('string_decoder/').StringDecoder;
this._readableState.decoder = new StringDecoder(enc);
this._readableState.encoding = enc;
+ return this;
};
// Don't raise the hwm > 128MB
@@ -240,7 +261,7 @@
if (state.objectMode)
return n === 0 ? 0 : 1;
- if (n === null || isNaN(n)) {
+ if (isNaN(n) || util.isNull(n)) {
// only flow one buffer at a time
if (state.flowing && state.buffer.length)
return state.buffer[0].length;
@@ -272,12 +293,11 @@
// you can override either this method, or the async _read(n) below.
Readable.prototype.read = function(n) {
+ debug('read', n);
var state = this._readableState;
- state.calledRead = true;
var nOrig = n;
- var ret;
- if (typeof n !== 'number' || n > 0)
+ if (!util.isNumber(n) || n > 0)
state.emittedReadable = false;
// if we're doing read(0) to trigger a readable event, but we
@@ -286,7 +306,11 @@
if (n === 0 &&
state.needReadable &&
(state.length >= state.highWaterMark || state.ended)) {
- emitReadable(this);
+ debug('read: emitReadable', state.length, state.ended);
+ if (state.length === 0 && state.ended)
+ endReadable(this);
+ else
+ emitReadable(this);
return null;
}
@@ -294,28 +318,9 @@
// if we've ended, and we're now clear, then finish it up.
if (n === 0 && state.ended) {
- ret = null;
-
- // In cases where the decoder did not receive enough data
- // to produce a full chunk, then immediately received an
- // EOF, state.buffer will contain [, ].
- // howMuchToRead will see this and coerce the amount to
- // read to zero (because it's looking at the length of the
- // first in state.buffer), and we'll end up here.
- //
- // This can only happen via state.decoder -- no other venue
- // exists for pushing a zero-length chunk into state.buffer
- // and triggering this behavior. In this case, we return our
- // remaining data and end the stream, if appropriate.
- if (state.length > 0 && state.decoder) {
- ret = fromList(n, state);
- state.length -= ret.length;
- }
-
if (state.length === 0)
endReadable(this);
-
- return ret;
+ return null;
}
// All the actual chunk generation logic needs to be
@@ -342,17 +347,23 @@
// if we need a readable event, then we need to do some reading.
var doRead = state.needReadable;
+ debug('need readable', doRead);
// if we currently have less than the highWaterMark, then also read some
- if (state.length - n <= state.highWaterMark)
+ if (state.length === 0 || state.length - n < state.highWaterMark) {
doRead = true;
+ debug('length less than watermark', doRead);
+ }
// however, if we've ended, then there's no point, and if we're already
// reading, then it's unnecessary.
- if (state.ended || state.reading)
+ if (state.ended || state.reading) {
doRead = false;
+ debug('reading or ended', doRead);
+ }
if (doRead) {
+ debug('do read');
state.reading = true;
state.sync = true;
// if the length is currently zero, then we *need* a readable event.
@@ -363,18 +374,18 @@
state.sync = false;
}
- // If _read called its callback synchronously, then `reading`
- // will be false, and we need to re-evaluate how much data we
- // can return to the user.
+ // If _read pushed data synchronously, then `reading` will be false,
+ // and we need to re-evaluate how much data we can return to the user.
if (doRead && !state.reading)
n = howMuchToRead(nOrig, state);
+ var ret;
if (n > 0)
ret = fromList(n, state);
else
ret = null;
- if (ret === null) {
+ if (util.isNull(ret)) {
state.needReadable = true;
n = 0;
}
@@ -386,21 +397,21 @@
if (state.length === 0 && !state.ended)
state.needReadable = true;
- // If we happened to read() exactly the remaining amount in the
- // buffer, and the EOF has been seen at this point, then make sure
- // that we emit 'end' on the very next tick.
- if (state.ended && !state.endEmitted && state.length === 0)
+ // If we tried to read() past the EOF, then emit end on the next tick.
+ if (nOrig !== n && state.ended && state.length === 0)
endReadable(this);
+ if (!util.isNull(ret))
+ this.emit('data', ret);
+
return ret;
};
function chunkInvalid(state, chunk) {
var er = null;
- if (!Buffer.isBuffer(chunk) &&
- 'string' !== typeof chunk &&
- chunk !== null &&
- chunk !== undefined &&
+ if (!util.isBuffer(chunk) &&
+ !util.isString(chunk) &&
+ !util.isNullOrUndefined(chunk) &&
!state.objectMode) {
er = new TypeError('Invalid non-string/buffer chunk');
}
@@ -418,12 +429,8 @@
}
state.ended = true;
- // if we've ended and we have some data left, then emit
- // 'readable' now to make sure it gets picked up.
- if (state.length > 0)
- emitReadable(stream);
- else
- endReadable(stream);
+ // emit 'readable' now to make sure it gets picked up.
+ emitReadable(stream);
}
// Don't emit readable right away in sync mode, because this can trigger
@@ -432,20 +439,22 @@
function emitReadable(stream) {
var state = stream._readableState;
state.needReadable = false;
- if (state.emittedReadable)
- return;
-
- state.emittedReadable = true;
- if (state.sync)
- process.nextTick(function() {
+ if (!state.emittedReadable) {
+ debug('emitReadable', state.flowing);
+ state.emittedReadable = true;
+ if (state.sync)
+ process.nextTick(function() {
+ emitReadable_(stream);
+ });
+ else
emitReadable_(stream);
- });
- else
- emitReadable_(stream);
+ }
}
function emitReadable_(stream) {
+ debug('emit readable');
stream.emit('readable');
+ flow(stream);
}
@@ -468,6 +477,7 @@
var len = state.length;
while (!state.reading && !state.flowing && !state.ended &&
state.length < state.highWaterMark) {
+ debug('maybeReadMore read 0');
stream.read(0);
if (len === state.length)
// didn't get any data, stop spinning.
@@ -502,6 +512,7 @@
break;
}
state.pipesCount += 1;
+ debug('pipe count=%d opts=%j', state.pipesCount, pipeOpts);
var doEnd = (!pipeOpts || pipeOpts.end !== false) &&
dest !== process.stdout &&
@@ -515,11 +526,14 @@
dest.on('unpipe', onunpipe);
function onunpipe(readable) {
- if (readable !== src) return;
- cleanup();
+ debug('onunpipe');
+ if (readable === src) {
+ cleanup();
+ }
}
function onend() {
+ debug('onend');
dest.end();
}
@@ -531,6 +545,7 @@
dest.on('drain', ondrain);
function cleanup() {
+ debug('cleanup');
// cleanup event handlers once the pipe is broken
dest.removeListener('close', onclose);
dest.removeListener('finish', onfinish);
@@ -539,19 +554,34 @@
dest.removeListener('unpipe', onunpipe);
src.removeListener('end', onend);
src.removeListener('end', cleanup);
+ src.removeListener('data', ondata);
// if the reader is waiting for a drain event from this
// specific writer, then it would cause it to never start
// flowing again.
// So, if this is awaiting a drain, then we just call it now.
// If we don't know, then assume that we are waiting for one.
- if (!dest._writableState || dest._writableState.needDrain)
+ if (state.awaitDrain &&
+ (!dest._writableState || dest._writableState.needDrain))
ondrain();
}
+ src.on('data', ondata);
+ function ondata(chunk) {
+ debug('ondata');
+ var ret = dest.write(chunk);
+ if (false === ret) {
+ debug('false write response, pause',
+ src._readableState.awaitDrain);
+ src._readableState.awaitDrain++;
+ src.pause();
+ }
+ }
+
// if the dest has an error, then stop piping into it.
// however, don't suppress the throwing behavior for this.
function onerror(er) {
+ debug('onerror', er);
unpipe();
dest.removeListener('error', onerror);
if (EE.listenerCount(dest, 'error') === 0)
@@ -575,12 +605,14 @@
}
dest.once('close', onclose);
function onfinish() {
+ debug('onfinish');
dest.removeListener('close', onclose);
unpipe();
}
dest.once('finish', onfinish);
function unpipe() {
+ debug('unpipe');
src.unpipe(dest);
}
@@ -589,16 +621,8 @@
// start the flow if it hasn't been started already.
if (!state.flowing) {
- // the handler that waits for readable events after all
- // the data gets sucked out in flow.
- // This would be easier to follow with a .once() handler
- // in flow(), but that is too slow.
- this.on('readable', pipeOnReadable);
-
- state.flowing = true;
- process.nextTick(function() {
- flow(src);
- });
+ debug('pipe resume');
+ src.resume();
}
return dest;
@@ -606,63 +630,15 @@
function pipeOnDrain(src) {
return function() {
- var dest = this;
var state = src._readableState;
- state.awaitDrain--;
- if (state.awaitDrain === 0)
+ debug('pipeOnDrain', state.awaitDrain);
+ if (state.awaitDrain)
+ state.awaitDrain--;
+ if (state.awaitDrain === 0 && EE.listenerCount(src, 'data')) {
+ state.flowing = true;
flow(src);
- };
-}
-
-function flow(src) {
- var state = src._readableState;
- var chunk;
- state.awaitDrain = 0;
-
- function write(dest, i, list) {
- var written = dest.write(chunk);
- if (false === written) {
- state.awaitDrain++;
}
- }
-
- while (state.pipesCount && null !== (chunk = src.read())) {
-
- if (state.pipesCount === 1)
- write(state.pipes, 0, null);
- else
- forEach(state.pipes, write);
-
- src.emit('data', chunk);
-
- // if anyone needs a drain, then we have to wait for that.
- if (state.awaitDrain > 0)
- return;
- }
-
- // if every destination was unpiped, either before entering this
- // function, or in the while loop, then stop flowing.
- //
- // NB: This is a pretty rare edge case.
- if (state.pipesCount === 0) {
- state.flowing = false;
-
- // if there were data event listeners added, then switch to old mode.
- if (EE.listenerCount(src, 'data') > 0)
- emitDataEvents(src);
- return;
- }
-
- // at this point, no one needed a drain, so we just ran out of data
- // on the next readable event, start it over again.
- state.ranOut = true;
-}
-
-function pipeOnReadable() {
- if (this._readableState.ranOut) {
- this._readableState.ranOut = false;
- flow(this);
- }
+ };
}
@@ -685,7 +661,6 @@
// got a match.
state.pipes = null;
state.pipesCount = 0;
- this.removeListener('readable', pipeOnReadable);
state.flowing = false;
if (dest)
dest.emit('unpipe', this);
@@ -700,7 +675,6 @@
var len = state.pipesCount;
state.pipes = null;
state.pipesCount = 0;
- this.removeListener('readable', pipeOnReadable);
state.flowing = false;
for (var i = 0; i < len; i++)
@@ -728,8 +702,11 @@
Readable.prototype.on = function(ev, fn) {
var res = Stream.prototype.on.call(this, ev, fn);
- if (ev === 'data' && !this._readableState.flowing)
- emitDataEvents(this);
+ // If listening to data, and it has not explicitly been paused,
+ // then call resume to start the flow of data on the next tick.
+ if (ev === 'data' && false !== this._readableState.flowing) {
+ this.resume();
+ }
if (ev === 'readable' && this.readable) {
var state = this._readableState;
@@ -738,7 +715,11 @@
state.emittedReadable = false;
state.needReadable = true;
if (!state.reading) {
- this.read(0);
+ var self = this;
+ process.nextTick(function() {
+ debug('readable nexttick read 0');
+ self.read(0);
+ });
} else if (state.length) {
emitReadable(this, state);
}
@@ -752,63 +733,54 @@
// pause() and resume() are remnants of the legacy readable stream API
// If the user uses them, then switch into old mode.
Readable.prototype.resume = function() {
- emitDataEvents(this);
- this.read(0);
- this.emit('resume');
+ var state = this._readableState;
+ if (!state.flowing) {
+ debug('resume');
+ state.flowing = true;
+ if (!state.reading) {
+ debug('resume read 0');
+ this.read(0);
+ }
+ resume(this, state);
+ }
+ return this;
};
+function resume(stream, state) {
+ if (!state.resumeScheduled) {
+ state.resumeScheduled = true;
+ process.nextTick(function() {
+ resume_(stream, state);
+ });
+ }
+}
+
+function resume_(stream, state) {
+ state.resumeScheduled = false;
+ stream.emit('resume');
+ flow(stream);
+ if (state.flowing && !state.reading)
+ stream.read(0);
+}
+
Readable.prototype.pause = function() {
- emitDataEvents(this, true);
- this.emit('pause');
+ debug('call pause flowing=%j', this._readableState.flowing);
+ if (false !== this._readableState.flowing) {
+ debug('pause');
+ this._readableState.flowing = false;
+ this.emit('pause');
+ }
+ return this;
};
-function emitDataEvents(stream, startPaused) {
+function flow(stream) {
var state = stream._readableState;
-
+ debug('flow', state.flowing);
if (state.flowing) {
- // https://github.com/isaacs/readable-stream/issues/16
- throw new Error('Cannot switch to old mode now.');
+ do {
+ var chunk = stream.read();
+ } while (null !== chunk && state.flowing);
}
-
- var paused = startPaused || false;
- var readable = false;
-
- // convert to an old-style stream.
- stream.readable = true;
- stream.pipe = Stream.prototype.pipe;
- stream.on = stream.addListener = Stream.prototype.on;
-
- stream.on('readable', function() {
- readable = true;
-
- var c;
- while (!paused && (null !== (c = stream.read())))
- stream.emit('data', c);
-
- if (c === null) {
- readable = false;
- stream._readableState.needReadable = true;
- }
- });
-
- stream.pause = function() {
- paused = true;
- this.emit('pause');
- };
-
- stream.resume = function() {
- paused = false;
- if (readable)
- process.nextTick(function() {
- stream.emit('readable');
- });
- else
- this.read(0);
- this.emit('resume');
- };
-
- // now make it start, just in case it hadn't already.
- stream.emit('readable');
}
// wrap an old-style stream as the async data source.
@@ -820,6 +792,7 @@
var self = this;
stream.on('end', function() {
+ debug('wrapped end');
if (state.decoder && !state.ended) {
var chunk = state.decoder.end();
if (chunk && chunk.length)
@@ -830,14 +803,10 @@
});
stream.on('data', function(chunk) {
+ debug('wrapped data');
if (state.decoder)
chunk = state.decoder.write(chunk);
-
- // don't skip over falsy values in objectMode
- //if (state.objectMode && util.isNullOrUndefined(chunk))
- if (state.objectMode && (chunk === null || chunk === undefined))
- return;
- else if (!state.objectMode && (!chunk || !chunk.length))
+ if (!chunk || !state.objectMode && !chunk.length)
return;
var ret = self.push(chunk);
@@ -850,8 +819,7 @@
// proxy all the other methods.
// important when wrapping filters and duplexes.
for (var i in stream) {
- if (typeof stream[i] === 'function' &&
- typeof this[i] === 'undefined') {
+ if (util.isFunction(stream[i]) && util.isUndefined(this[i])) {
this[i] = function(method) { return function() {
return stream[method].apply(stream, arguments);
}}(i);
@@ -867,6 +835,7 @@
// when we try to consume some more bytes, simply unpause the
// underlying stream.
self._read = function(n) {
+ debug('wrapped _read', n);
if (paused) {
paused = false;
stream.resume();
@@ -955,7 +924,7 @@
if (state.length > 0)
throw new Error('endReadable called on non-empty stream');
- if (!state.endEmitted && state.calledRead) {
+ if (!state.endEmitted) {
state.ended = true;
process.nextTick(function() {
// Check that we didn't get one last unshift.
diff -Nru nodejs-0.11.14/deps/npm/node_modules/sha/node_modules/readable-stream/lib/_stream_transform.js nodejs-0.11.15/deps/npm/node_modules/sha/node_modules/readable-stream/lib/_stream_transform.js
--- nodejs-0.11.14/deps/npm/node_modules/sha/node_modules/readable-stream/lib/_stream_transform.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/sha/node_modules/readable-stream/lib/_stream_transform.js 2015-01-20 21:22:17.000000000 +0000
@@ -97,7 +97,7 @@
ts.writechunk = null;
ts.writecb = null;
- if (data !== null && data !== undefined)
+ if (!util.isNullOrUndefined(data))
stream.push(data);
if (cb)
@@ -117,7 +117,7 @@
Duplex.call(this, options);
- var ts = this._transformState = new TransformState(options, this);
+ this._transformState = new TransformState(options, this);
// when the writable side finishes, then flush out anything remaining.
var stream = this;
@@ -130,8 +130,8 @@
// sync guard flag.
this._readableState.sync = false;
- this.once('finish', function() {
- if ('function' === typeof this._flush)
+ this.once('prefinish', function() {
+ if (util.isFunction(this._flush))
this._flush(function(er) {
done(stream, er);
});
@@ -179,7 +179,7 @@
Transform.prototype._read = function(n) {
var ts = this._transformState;
- if (ts.writechunk !== null && ts.writecb && !ts.transforming) {
+ if (!util.isNull(ts.writechunk) && ts.writecb && !ts.transforming) {
ts.transforming = true;
this._transform(ts.writechunk, ts.writeencoding, ts.afterTransform);
} else {
@@ -197,7 +197,6 @@
// if there's nothing in the write buffer, then that means
// that nothing more will ever be provided
var ws = stream._writableState;
- var rs = stream._readableState;
var ts = stream._transformState;
if (ws.length)
diff -Nru nodejs-0.11.14/deps/npm/node_modules/sha/node_modules/readable-stream/lib/_stream_writable.js nodejs-0.11.15/deps/npm/node_modules/sha/node_modules/readable-stream/lib/_stream_writable.js
--- nodejs-0.11.14/deps/npm/node_modules/sha/node_modules/readable-stream/lib/_stream_writable.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/sha/node_modules/readable-stream/lib/_stream_writable.js 2015-01-20 21:22:17.000000000 +0000
@@ -48,18 +48,24 @@
}
function WritableState(options, stream) {
+ var Duplex = require('./_stream_duplex');
+
options = options || {};
// the point at which write() starts returning false
// Note: 0 is a valid value, means that we always return false if
// the entire buffer is not flushed immediately on write()
var hwm = options.highWaterMark;
- this.highWaterMark = (hwm || hwm === 0) ? hwm : 16 * 1024;
+ var defaultHwm = options.objectMode ? 16 : 16 * 1024;
+ this.highWaterMark = (hwm || hwm === 0) ? hwm : defaultHwm;
// object stream flag to indicate whether or not this stream
// contains buffers or objects.
this.objectMode = !!options.objectMode;
+ if (stream instanceof Duplex)
+ this.objectMode = this.objectMode || !!options.writableObjectMode;
+
// cast to ints.
this.highWaterMark = ~~this.highWaterMark;
@@ -90,8 +96,11 @@
// a flag to see when we're in the middle of a write.
this.writing = false;
+ // when true all writes will be buffered until .uncork() call
+ this.corked = 0;
+
// a flag to be able to tell if the onwrite cb is called immediately,
- // or on a later tick. We set this to true at first, becuase any
+ // or on a later tick. We set this to true at first, because any
// actions that shouldn't happen until "later" should generally also
// not happen before the first write call.
this.sync = true;
@@ -114,6 +123,14 @@
this.buffer = [];
+ // number of pending user-supplied write callbacks
+ // this must be 0 before 'finish' can be emitted
+ this.pendingcb = 0;
+
+ // emit prefinish if the only thing we're waiting for is _write cbs
+ // This is relevant for synchronous Transform streams
+ this.prefinished = false;
+
// True if the error was already emitted and should not be thrown again
this.errorEmitted = false;
}
@@ -156,10 +173,9 @@
// how many bytes or characters.
function validChunk(stream, state, chunk, cb) {
var valid = true;
- if (!Buffer.isBuffer(chunk) &&
- 'string' !== typeof chunk &&
- chunk !== null &&
- chunk !== undefined &&
+ if (!util.isBuffer(chunk) &&
+ !util.isString(chunk) &&
+ !util.isNullOrUndefined(chunk) &&
!state.objectMode) {
var er = new TypeError('Invalid non-string/buffer chunk');
stream.emit('error', er);
@@ -175,31 +191,54 @@
var state = this._writableState;
var ret = false;
- if (typeof encoding === 'function') {
+ if (util.isFunction(encoding)) {
cb = encoding;
encoding = null;
}
- if (Buffer.isBuffer(chunk))
+ if (util.isBuffer(chunk))
encoding = 'buffer';
else if (!encoding)
encoding = state.defaultEncoding;
- if (typeof cb !== 'function')
+ if (!util.isFunction(cb))
cb = function() {};
if (state.ended)
writeAfterEnd(this, state, cb);
- else if (validChunk(this, state, chunk, cb))
+ else if (validChunk(this, state, chunk, cb)) {
+ state.pendingcb++;
ret = writeOrBuffer(this, state, chunk, encoding, cb);
+ }
return ret;
};
+Writable.prototype.cork = function() {
+ var state = this._writableState;
+
+ state.corked++;
+};
+
+Writable.prototype.uncork = function() {
+ var state = this._writableState;
+
+ if (state.corked) {
+ state.corked--;
+
+ if (!state.writing &&
+ !state.corked &&
+ !state.finished &&
+ !state.bufferProcessing &&
+ state.buffer.length)
+ clearBuffer(this, state);
+ }
+};
+
function decodeChunk(state, chunk, encoding) {
if (!state.objectMode &&
state.decodeStrings !== false &&
- typeof chunk === 'string') {
+ util.isString(chunk)) {
chunk = new Buffer(chunk, encoding);
}
return chunk;
@@ -210,7 +249,7 @@
// If we return false, then we need a drain event, so set that flag.
function writeOrBuffer(stream, state, chunk, encoding, cb) {
chunk = decodeChunk(state, chunk, encoding);
- if (Buffer.isBuffer(chunk))
+ if (util.isBuffer(chunk))
encoding = 'buffer';
var len = state.objectMode ? 1 : chunk.length;
@@ -221,30 +260,36 @@
if (!ret)
state.needDrain = true;
- if (state.writing)
+ if (state.writing || state.corked)
state.buffer.push(new WriteReq(chunk, encoding, cb));
else
- doWrite(stream, state, len, chunk, encoding, cb);
+ doWrite(stream, state, false, len, chunk, encoding, cb);
return ret;
}
-function doWrite(stream, state, len, chunk, encoding, cb) {
+function doWrite(stream, state, writev, len, chunk, encoding, cb) {
state.writelen = len;
state.writecb = cb;
state.writing = true;
state.sync = true;
- stream._write(chunk, encoding, state.onwrite);
+ if (writev)
+ stream._writev(chunk, state.onwrite);
+ else
+ stream._write(chunk, encoding, state.onwrite);
state.sync = false;
}
function onwriteError(stream, state, sync, er, cb) {
if (sync)
process.nextTick(function() {
+ state.pendingcb--;
cb(er);
});
- else
+ else {
+ state.pendingcb--;
cb(er);
+ }
stream._writableState.errorEmitted = true;
stream.emit('error', er);
@@ -270,8 +315,12 @@
// Check if we're actually ready to finish, but don't emit yet
var finished = needFinish(stream, state);
- if (!finished && !state.bufferProcessing && state.buffer.length)
+ if (!finished &&
+ !state.corked &&
+ !state.bufferProcessing &&
+ state.buffer.length) {
clearBuffer(stream, state);
+ }
if (sync) {
process.nextTick(function() {
@@ -286,9 +335,9 @@
function afterWrite(stream, state, finished, cb) {
if (!finished)
onwriteDrain(stream, state);
+ state.pendingcb--;
cb();
- if (finished)
- finishMaybe(stream, state);
+ finishMaybe(stream, state);
}
// Must force callback to be called on nextTick, so that we don't
@@ -306,51 +355,82 @@
function clearBuffer(stream, state) {
state.bufferProcessing = true;
- for (var c = 0; c < state.buffer.length; c++) {
- var entry = state.buffer[c];
- var chunk = entry.chunk;
- var encoding = entry.encoding;
- var cb = entry.callback;
- var len = state.objectMode ? 1 : chunk.length;
-
- doWrite(stream, state, len, chunk, encoding, cb);
-
- // if we didn't call the onwrite immediately, then
- // it means that we need to wait until it does.
- // also, that means that the chunk and cb are currently
- // being processed, so move the buffer counter past them.
- if (state.writing) {
- c++;
- break;
+ if (stream._writev && state.buffer.length > 1) {
+ // Fast case, write everything using _writev()
+ var cbs = [];
+ for (var c = 0; c < state.buffer.length; c++)
+ cbs.push(state.buffer[c].callback);
+
+ // count the one we are adding, as well.
+ // TODO(isaacs) clean this up
+ state.pendingcb++;
+ doWrite(stream, state, true, state.length, state.buffer, '', function(err) {
+ for (var i = 0; i < cbs.length; i++) {
+ state.pendingcb--;
+ cbs[i](err);
+ }
+ });
+
+ // Clear buffer
+ state.buffer = [];
+ } else {
+ // Slow case, write chunks one-by-one
+ for (var c = 0; c < state.buffer.length; c++) {
+ var entry = state.buffer[c];
+ var chunk = entry.chunk;
+ var encoding = entry.encoding;
+ var cb = entry.callback;
+ var len = state.objectMode ? 1 : chunk.length;
+
+ doWrite(stream, state, false, len, chunk, encoding, cb);
+
+ // if we didn't call the onwrite immediately, then
+ // it means that we need to wait until it does.
+ // also, that means that the chunk and cb are currently
+ // being processed, so move the buffer counter past them.
+ if (state.writing) {
+ c++;
+ break;
+ }
}
+
+ if (c < state.buffer.length)
+ state.buffer = state.buffer.slice(c);
+ else
+ state.buffer.length = 0;
}
state.bufferProcessing = false;
- if (c < state.buffer.length)
- state.buffer = state.buffer.slice(c);
- else
- state.buffer.length = 0;
}
Writable.prototype._write = function(chunk, encoding, cb) {
cb(new Error('not implemented'));
+
};
+Writable.prototype._writev = null;
+
Writable.prototype.end = function(chunk, encoding, cb) {
var state = this._writableState;
- if (typeof chunk === 'function') {
+ if (util.isFunction(chunk)) {
cb = chunk;
chunk = null;
encoding = null;
- } else if (typeof encoding === 'function') {
+ } else if (util.isFunction(encoding)) {
cb = encoding;
encoding = null;
}
- if (typeof chunk !== 'undefined' && chunk !== null)
+ if (!util.isNullOrUndefined(chunk))
this.write(chunk, encoding);
+ // .end() fully uncorks
+ if (state.corked) {
+ state.corked = 1;
+ this.uncork();
+ }
+
// ignore unnecessary end() calls.
if (!state.ending && !state.finished)
endWritable(this, state, cb);
@@ -364,11 +444,22 @@
!state.writing);
}
+function prefinish(stream, state) {
+ if (!state.prefinished) {
+ state.prefinished = true;
+ stream.emit('prefinish');
+ }
+}
+
function finishMaybe(stream, state) {
var need = needFinish(stream, state);
if (need) {
- state.finished = true;
- stream.emit('finish');
+ if (state.pendingcb === 0) {
+ prefinish(stream, state);
+ state.finished = true;
+ stream.emit('finish');
+ } else
+ prefinish(stream, state);
}
return need;
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/sha/node_modules/readable-stream/LICENSE nodejs-0.11.15/deps/npm/node_modules/sha/node_modules/readable-stream/LICENSE
--- nodejs-0.11.14/deps/npm/node_modules/sha/node_modules/readable-stream/LICENSE 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/sha/node_modules/readable-stream/LICENSE 2015-01-20 21:22:17.000000000 +0000
@@ -1,27 +1,18 @@
-Copyright (c) Isaac Z. Schlueter ("Author")
-All rights reserved.
+Copyright Joyent, Inc. and other Node contributors. All rights reserved.
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to
+deal in the Software without restriction, including without limitation the
+rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
+sell copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
-The BSD License
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
-Redistribution and use in source and binary forms, with or without
-modification, are permitted provided that the following conditions
-are met:
-
-1. Redistributions of source code must retain the above copyright
- notice, this list of conditions and the following disclaimer.
-
-2. Redistributions in binary form must reproduce the above copyright
- notice, this list of conditions and the following disclaimer in the
- documentation and/or other materials provided with the distribution.
-
-THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
-ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
-PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS
-BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
-CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
-SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
-BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
-WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
-OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
-IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
+IN THE SOFTWARE.
diff -Nru nodejs-0.11.14/deps/npm/node_modules/sha/node_modules/readable-stream/node_modules/core-util-is/package.json nodejs-0.11.15/deps/npm/node_modules/sha/node_modules/readable-stream/node_modules/core-util-is/package.json
--- nodejs-0.11.14/deps/npm/node_modules/sha/node_modules/readable-stream/node_modules/core-util-is/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/sha/node_modules/readable-stream/node_modules/core-util-is/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -49,5 +49,6 @@
],
"directories": {},
"_shasum": "6b07085aef9a3ccac6ee53bf9d3df0c1521a5538",
- "_resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.1.tgz"
+ "_resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.1.tgz",
+ "scripts": {}
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/sha/node_modules/readable-stream/node_modules/isarray/package.json nodejs-0.11.15/deps/npm/node_modules/sha/node_modules/readable-stream/node_modules/isarray/package.json
--- nodejs-0.11.14/deps/npm/node_modules/sha/node_modules/readable-stream/node_modules/isarray/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/sha/node_modules/readable-stream/node_modules/isarray/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -47,5 +47,8 @@
],
"directories": {},
"_shasum": "8a18acfca9a8f4177e09abfc6038939b05d1eedf",
- "_resolved": "https://registry.npmjs.org/isarray/-/isarray-0.0.1.tgz"
+ "_resolved": "https://registry.npmjs.org/isarray/-/isarray-0.0.1.tgz",
+ "bugs": {
+ "url": "https://github.com/juliangruber/isarray/issues"
+ }
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/sha/node_modules/readable-stream/node_modules/string_decoder/package.json nodejs-0.11.15/deps/npm/node_modules/sha/node_modules/readable-stream/node_modules/string_decoder/package.json
--- nodejs-0.11.14/deps/npm/node_modules/sha/node_modules/readable-stream/node_modules/string_decoder/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/sha/node_modules/readable-stream/node_modules/string_decoder/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -49,5 +49,6 @@
"tarball": "http://registry.npmjs.org/string_decoder/-/string_decoder-0.10.31.tgz"
},
"directories": {},
- "_resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-0.10.31.tgz"
+ "_resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-0.10.31.tgz",
+ "readme": "ERROR: No README data found!"
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/sha/node_modules/readable-stream/package.json nodejs-0.11.15/deps/npm/node_modules/sha/node_modules/readable-stream/package.json
--- nodejs-0.11.14/deps/npm/node_modules/sha/node_modules/readable-stream/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/sha/node_modules/readable-stream/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -1,7 +1,7 @@
{
"name": "readable-stream",
- "version": "1.0.31",
- "description": "Streams2, a user-land copy of the stream library from Node.js v0.10.x",
+ "version": "1.1.13",
+ "description": "Streams3, a user-land copy of the stream library from Node.js v0.11.x",
"main": "readable.js",
"dependencies": {
"core-util-is": "~1.0.0",
@@ -33,14 +33,15 @@
"url": "http://blog.izs.me/"
},
"license": "MIT",
+ "gitHead": "3b672fd7ae92acf5b4ffdbabf74b372a0a56b051",
"bugs": {
"url": "https://github.com/isaacs/readable-stream/issues"
},
"homepage": "https://github.com/isaacs/readable-stream",
- "_id": "readable-stream@1.0.31",
- "_shasum": "8f2502e0bc9e3b0da1b94520aabb4e2603ecafae",
- "_from": "readable-stream@>=1.0.0 <1.1.0",
- "_npmVersion": "1.4.9",
+ "_id": "readable-stream@1.1.13",
+ "_shasum": "f6eef764f514c89e2b9e23146a75ba106756d23e",
+ "_from": "readable-stream@>=1.1.0 <1.2.0",
+ "_npmVersion": "1.4.23",
"_npmUser": {
"name": "rvagg",
"email": "rod@vagg.org"
@@ -60,9 +61,10 @@
}
],
"dist": {
- "shasum": "8f2502e0bc9e3b0da1b94520aabb4e2603ecafae",
- "tarball": "http://registry.npmjs.org/readable-stream/-/readable-stream-1.0.31.tgz"
+ "shasum": "f6eef764f514c89e2b9e23146a75ba106756d23e",
+ "tarball": "http://registry.npmjs.org/readable-stream/-/readable-stream-1.1.13.tgz"
},
"directories": {},
- "_resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-1.0.31.tgz"
+ "_resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-1.1.13.tgz",
+ "readme": "ERROR: No README data found!"
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/sha/node_modules/readable-stream/readable.js nodejs-0.11.15/deps/npm/node_modules/sha/node_modules/readable-stream/readable.js
--- nodejs-0.11.14/deps/npm/node_modules/sha/node_modules/readable-stream/readable.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/sha/node_modules/readable-stream/readable.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,4 +1,5 @@
exports = module.exports = require('./lib/_stream_readable.js');
+exports.Stream = require('stream');
exports.Readable = exports;
exports.Writable = require('./lib/_stream_writable.js');
exports.Duplex = require('./lib/_stream_duplex.js');
diff -Nru nodejs-0.11.14/deps/npm/node_modules/sha/node_modules/readable-stream/README.md nodejs-0.11.15/deps/npm/node_modules/sha/node_modules/readable-stream/README.md
--- nodejs-0.11.14/deps/npm/node_modules/sha/node_modules/readable-stream/README.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/sha/node_modules/readable-stream/README.md 2015-01-20 21:22:17.000000000 +0000
@@ -2,8 +2,8 @@
***Node-core streams for userland***
-[![NPM](https://nodei.co/npm/readable-stream.png?downloads=true)](https://nodei.co/npm/readable-stream/)
-[![NPM](https://nodei.co/npm-dl/readable-stream.png)](https://nodei.co/npm/readable-stream/)
+[![NPM](https://nodei.co/npm/readable-stream.png?downloads=true&downloadRank=true)](https://nodei.co/npm/readable-stream/)
+[![NPM](https://nodei.co/npm-dl/readable-stream.png&months=6&height=3)](https://nodei.co/npm/readable-stream/)
This package is a mirror of the Streams2 and Streams3 implementations in Node-core.
diff -Nru nodejs-0.11.14/deps/npm/node_modules/sha/.npmignore nodejs-0.11.15/deps/npm/node_modules/sha/.npmignore
--- nodejs-0.11.14/deps/npm/node_modules/sha/.npmignore 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/sha/.npmignore 2015-01-20 21:22:17.000000000 +0000
@@ -1,4 +1,4 @@
-node_modules
-test
-.gitignore
+node_modules
+test
+.gitignore
.travis.yml
\ No newline at end of file
diff -Nru nodejs-0.11.14/deps/npm/node_modules/sha/package.json nodejs-0.11.15/deps/npm/node_modules/sha/package.json
--- nodejs-0.11.14/deps/npm/node_modules/sha/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/sha/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -1,6 +1,6 @@
{
"name": "sha",
- "version": "1.2.4",
+ "version": "1.3.0",
"description": "Check and get file hashes",
"scripts": {
"test": "mocha -R spec"
@@ -12,29 +12,27 @@
"license": "BSD",
"optionalDependencies": {
"graceful-fs": "2 || 3",
- "readable-stream": "1.0"
+ "readable-stream": "~1.1"
},
"devDependencies": {
"mocha": "~1.9.0"
},
+ "gitHead": "f1985eefbf7538e5809a2157c728d2f740901600",
"bugs": {
"url": "https://github.com/ForbesLindesay/sha/issues"
},
"homepage": "https://github.com/ForbesLindesay/sha",
"dependencies": {
"graceful-fs": "2 || 3",
- "readable-stream": "1.0"
+ "readable-stream": "~1.1"
},
- "_id": "sha@1.2.4",
- "dist": {
- "shasum": "1f9a377f27b6fdee409b9b858e43da702be48a4d",
- "tarball": "http://registry.npmjs.org/sha/-/sha-1.2.4.tgz"
- },
- "_from": "sha@>=1.2.1 <1.3.0",
- "_npmVersion": "1.4.3",
+ "_id": "sha@1.3.0",
+ "_shasum": "79f4787045d0ede7327d702c25c443460dbc6764",
+ "_from": "sha@>=1.3.0 <1.4.0",
+ "_npmVersion": "1.5.0-alpha-4",
"_npmUser": {
"name": "forbeslindesay",
- "email": "forbes@lindeay.co.uk"
+ "email": "forbes@lindesay.co.uk"
},
"maintainers": [
{
@@ -42,7 +40,10 @@
"email": "forbes@lindesay.co.uk"
}
],
+ "dist": {
+ "shasum": "79f4787045d0ede7327d702c25c443460dbc6764",
+ "tarball": "http://registry.npmjs.org/sha/-/sha-1.3.0.tgz"
+ },
"directories": {},
- "_shasum": "1f9a377f27b6fdee409b9b858e43da702be48a4d",
- "_resolved": "https://registry.npmjs.org/sha/-/sha-1.2.4.tgz"
+ "_resolved": "https://registry.npmjs.org/sha/-/sha-1.3.0.tgz"
}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/sha/README.md nodejs-0.11.15/deps/npm/node_modules/sha/README.md
--- nodejs-0.11.14/deps/npm/node_modules/sha/README.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/sha/README.md 2015-01-20 21:22:17.000000000 +0000
@@ -1,49 +1,49 @@
-# sha
-
-Check and get file hashes (using any algorithm)
-
-[![Build Status](https://img.shields.io/travis/ForbesLindesay/sha/master.svg)](https://travis-ci.org/ForbesLindesay/sha)
-[![Dependency Status](https://img.shields.io/gemnasium/ForbesLindesay/sha.svg)](https://gemnasium.com/ForbesLindesay/sha)
-[![NPM version](https://img.shields.io/npm/v/sha.svg)](http://badge.fury.io/js/sha)
-
-## Installation
-
- $ npm install sha
-
-## API
-
-### check(fileName, expected, [options,] cb) / checkSync(filename, expected, [options])
-
-Asynchronously check that `fileName` has a "hash" of `expected`. The callback will be called with either `null` or an error (indicating that they did not match).
-
-Options:
-
-- algorithm: defaults to `sha1` and can be any of the algorithms supported by `crypto.createHash`
-
-### get(fileName, [options,] cb) / getSync(filename, [options])
-
-Asynchronously get the "hash" of `fileName`. The callback will be called with an optional `error` object and the (lower cased) hex digest of the hash.
-
-Options:
-
-- algorithm: defaults to `sha1` and can be any of the algorithms supported by `crypto.createHash`
-
-### stream(expected, [options])
-
-Check the hash of a stream without ever buffering it. This is a pass through stream so you can do things like:
-
-```js
-fs.createReadStream('src')
- .pipe(sha.stream('expected'))
- .pipe(fs.createWriteStream('dest'))
-```
-
-`dest` will be a complete copy of `src` and an error will be emitted if the hash did not match `'expected'`.
-
-Options:
-
-- algorithm: defaults to `sha1` and can be any of the algorithms supported by `crypto.createHash`
-
-## License
-
+# sha
+
+Check and get file hashes (using any algorithm)
+
+[![Build Status](https://img.shields.io/travis/ForbesLindesay/sha/master.svg)](https://travis-ci.org/ForbesLindesay/sha)
+[![Dependency Status](https://img.shields.io/gemnasium/ForbesLindesay/sha.svg)](https://gemnasium.com/ForbesLindesay/sha)
+[![NPM version](https://img.shields.io/npm/v/sha.svg)](http://badge.fury.io/js/sha)
+
+## Installation
+
+ $ npm install sha
+
+## API
+
+### check(fileName, expected, [options,] cb) / checkSync(filename, expected, [options])
+
+Asynchronously check that `fileName` has a "hash" of `expected`. The callback will be called with either `null` or an error (indicating that they did not match).
+
+Options:
+
+- algorithm: defaults to `sha1` and can be any of the algorithms supported by `crypto.createHash`
+
+### get(fileName, [options,] cb) / getSync(filename, [options])
+
+Asynchronously get the "hash" of `fileName`. The callback will be called with an optional `error` object and the (lower cased) hex digest of the hash.
+
+Options:
+
+- algorithm: defaults to `sha1` and can be any of the algorithms supported by `crypto.createHash`
+
+### stream(expected, [options])
+
+Check the hash of a stream without ever buffering it. This is a pass through stream so you can do things like:
+
+```js
+fs.createReadStream('src')
+ .pipe(sha.stream('expected'))
+ .pipe(fs.createWriteStream('dest'))
+```
+
+`dest` will be a complete copy of `src` and an error will be emitted if the hash did not match `'expected'`.
+
+Options:
+
+- algorithm: defaults to `sha1` and can be any of the algorithms supported by `crypto.createHash`
+
+## License
+
You may use this software under the BSD or MIT. Take your pick. If you want me to release it under another license, open a pull request.
\ No newline at end of file
diff -Nru nodejs-0.11.14/deps/npm/node_modules/wrappy/LICENSE nodejs-0.11.15/deps/npm/node_modules/wrappy/LICENSE
--- nodejs-0.11.14/deps/npm/node_modules/wrappy/LICENSE 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/wrappy/LICENSE 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,15 @@
+The ISC License
+
+Copyright (c) Isaac Z. Schlueter and Contributors
+
+Permission to use, copy, modify, and/or distribute this software for any
+purpose with or without fee is hereby granted, provided that the above
+copyright notice and this permission notice appear in all copies.
+
+THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
+WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
+ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
+WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
+ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR
+IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
diff -Nru nodejs-0.11.14/deps/npm/node_modules/wrappy/package.json nodejs-0.11.15/deps/npm/node_modules/wrappy/package.json
--- nodejs-0.11.14/deps/npm/node_modules/wrappy/package.json 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/wrappy/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,52 @@
+{
+ "name": "wrappy",
+ "version": "1.0.1",
+ "description": "Callback wrapping utility",
+ "main": "wrappy.js",
+ "directories": {
+ "test": "test"
+ },
+ "dependencies": {},
+ "devDependencies": {
+ "tap": "^0.4.12"
+ },
+ "scripts": {
+ "test": "tap test/*.js"
+ },
+ "repository": {
+ "type": "git",
+ "url": "https://github.com/npm/wrappy"
+ },
+ "author": {
+ "name": "Isaac Z. Schlueter",
+ "email": "i@izs.me",
+ "url": "http://blog.izs.me/"
+ },
+ "license": "ISC",
+ "bugs": {
+ "url": "https://github.com/npm/wrappy/issues"
+ },
+ "homepage": "https://github.com/npm/wrappy",
+ "gitHead": "006a8cbac6b99988315834c207896eed71fd069a",
+ "_id": "wrappy@1.0.1",
+ "_shasum": "1e65969965ccbc2db4548c6b84a6f2c5aedd4739",
+ "_from": "wrappy@1.0.1",
+ "_npmVersion": "2.0.0",
+ "_nodeVersion": "0.10.31",
+ "_npmUser": {
+ "name": "isaacs",
+ "email": "i@izs.me"
+ },
+ "maintainers": [
+ {
+ "name": "isaacs",
+ "email": "i@izs.me"
+ }
+ ],
+ "dist": {
+ "shasum": "1e65969965ccbc2db4548c6b84a6f2c5aedd4739",
+ "tarball": "http://registry.npmjs.org/wrappy/-/wrappy-1.0.1.tgz"
+ },
+ "_resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.1.tgz",
+ "readme": "ERROR: No README data found!"
+}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/wrappy/README.md nodejs-0.11.15/deps/npm/node_modules/wrappy/README.md
--- nodejs-0.11.14/deps/npm/node_modules/wrappy/README.md 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/wrappy/README.md 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,36 @@
+# wrappy
+
+Callback wrapping utility
+
+## USAGE
+
+```javascript
+var wrappy = require("wrappy")
+
+// var wrapper = wrappy(wrapperFunction)
+
+// make sure a cb is called only once
+// See also: http://npm.im/once for this specific use case
+var once = wrappy(function (cb) {
+ var called = false
+ return function () {
+ if (called) return
+ called = true
+ return cb.apply(this, arguments)
+ }
+})
+
+function printBoo () {
+ console.log('boo')
+}
+// has some rando property
+printBoo.iAmBooPrinter = true
+
+var onlyPrintOnce = once(printBoo)
+
+onlyPrintOnce() // prints 'boo'
+onlyPrintOnce() // does nothing
+
+// random property is retained!
+assert.equal(onlyPrintOnce.iAmBooPrinter, true)
+```
diff -Nru nodejs-0.11.14/deps/npm/node_modules/wrappy/test/basic.js nodejs-0.11.15/deps/npm/node_modules/wrappy/test/basic.js
--- nodejs-0.11.14/deps/npm/node_modules/wrappy/test/basic.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/wrappy/test/basic.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,51 @@
+var test = require('tap').test
+var wrappy = require('../wrappy.js')
+
+test('basic', function (t) {
+ function onceifier (cb) {
+ var called = false
+ return function () {
+ if (called) return
+ called = true
+ return cb.apply(this, arguments)
+ }
+ }
+ onceifier.iAmOnce = {}
+ var once = wrappy(onceifier)
+ t.equal(once.iAmOnce, onceifier.iAmOnce)
+
+ var called = 0
+ function boo () {
+ t.equal(called, 0)
+ called++
+ }
+ // has some rando property
+ boo.iAmBoo = true
+
+ var onlyPrintOnce = once(boo)
+
+ onlyPrintOnce() // prints 'boo'
+ onlyPrintOnce() // does nothing
+ t.equal(called, 1)
+
+ // random property is retained!
+ t.equal(onlyPrintOnce.iAmBoo, true)
+
+ var logs = []
+ var logwrap = wrappy(function (msg, cb) {
+ logs.push(msg + ' wrapping cb')
+ return function () {
+ logs.push(msg + ' before cb')
+ var ret = cb.apply(this, arguments)
+ logs.push(msg + ' after cb')
+ }
+ })
+
+ var c = logwrap('foo', function () {
+ t.same(logs, [ 'foo wrapping cb', 'foo before cb' ])
+ })
+ c()
+ t.same(logs, [ 'foo wrapping cb', 'foo before cb', 'foo after cb' ])
+
+ t.end()
+})
diff -Nru nodejs-0.11.14/deps/npm/node_modules/wrappy/wrappy.js nodejs-0.11.15/deps/npm/node_modules/wrappy/wrappy.js
--- nodejs-0.11.14/deps/npm/node_modules/wrappy/wrappy.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/wrappy/wrappy.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,33 @@
+// Returns a wrapper function that returns a wrapped callback
+// The wrapper function should do some stuff, and return a
+// presumably different callback function.
+// This makes sure that own properties are retained, so that
+// decorations and such are not lost along the way.
+module.exports = wrappy
+function wrappy (fn, cb) {
+ if (fn && cb) return wrappy(fn)(cb)
+
+ if (typeof fn !== 'function')
+ throw new TypeError('need wrapper function')
+
+ Object.keys(fn).forEach(function (k) {
+ wrapper[k] = fn[k]
+ })
+
+ return wrapper
+
+ function wrapper() {
+ var args = new Array(arguments.length)
+ for (var i = 0; i < args.length; i++) {
+ args[i] = arguments[i]
+ }
+ var ret = fn.apply(this, args)
+ var cb = args[args.length-1]
+ if (typeof ret === 'function' && ret !== cb) {
+ Object.keys(cb).forEach(function (k) {
+ ret[k] = cb[k]
+ })
+ }
+ return ret
+ }
+}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/write-file-atomic/index.js nodejs-0.11.15/deps/npm/node_modules/write-file-atomic/index.js
--- nodejs-0.11.14/deps/npm/node_modules/write-file-atomic/index.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/write-file-atomic/index.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,45 @@
+'use strict'
+var fs = require('graceful-fs');
+var chain = require('slide').chain;
+var crypto = require('crypto');
+
+var md5hex = function () {
+ var hash = crypto.createHash('md5');
+ for (var ii=0; ii=1.1.0 <2.0.0",
+ "_npmVersion": "1.4.28",
+ "_npmUser": {
+ "name": "iarna",
+ "email": "me@re-becca.org"
+ },
+ "maintainers": [
+ {
+ "name": "iarna",
+ "email": "me@re-becca.org"
+ }
+ ],
+ "dist": {
+ "shasum": "e114cfb8f82188353f98217c5945451c9b4dc060",
+ "tarball": "http://registry.npmjs.org/write-file-atomic/-/write-file-atomic-1.1.0.tgz"
+ },
+ "directories": {},
+ "_resolved": "https://registry.npmjs.org/write-file-atomic/-/write-file-atomic-1.1.0.tgz"
+}
diff -Nru nodejs-0.11.14/deps/npm/node_modules/write-file-atomic/README.md nodejs-0.11.15/deps/npm/node_modules/write-file-atomic/README.md
--- nodejs-0.11.14/deps/npm/node_modules/write-file-atomic/README.md 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/write-file-atomic/README.md 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,44 @@
+write-file-atomic
+-----------------
+
+This is an extension for node's `fs.writeFile` that makes its operation
+atomic and allows you set ownership (uid/gid of the file).
+
+### var writeFileAtomic = require('write-file-atomic') writeFileAtomic(filename, data, [options], callback)
+
+* filename **String**
+* data **String** | **Buffer**
+* options **Object**
+ * chown **Object**
+ * uid **Number**
+ * gid **Number**
+ * encoding **String** | **Null** default = 'utf8'
+ * mode **Number** default = 438 (aka 0666 in Octal)
+callback **Function**
+
+Atomically and asynchronously writes data to a file, replacing the file if it already
+exists. data can be a string or a buffer.
+
+The file is initially named `filename + "." + md5hex(__filename, process.pid, ++invocations)`.
+If writeFile completes successfully then, if passed the **chown** option it will change
+the ownership of the file. Finally it renames the file back to the filename you specified. If
+it encounters errors at any of these steps it will attempt to unlink the temporary file and then
+pass the error back to the caller.
+
+If provided, the **chown** option requires both **uid** and **gid** properties or else
+you'll get an error.
+
+The **encoding** option is ignored if **data** is a buffer. It defaults to 'utf8'.
+
+Example:
+
+```javascript
+writeFileAtomic('message.txt', 'Hello Node', {chown:{uid:100,gid:50}}, function (err) {
+ if (err) throw err;
+ console.log('It\'s saved!');
+});
+```
+
+### var writeFileAtomicSync = require('write-file-atomic').sync writeFileAtomicSync(filename, data, [options])
+
+The synchronous version of **writeFileAtomic**.
diff -Nru nodejs-0.11.14/deps/npm/node_modules/write-file-atomic/test/basic.js nodejs-0.11.15/deps/npm/node_modules/write-file-atomic/test/basic.js
--- nodejs-0.11.14/deps/npm/node_modules/write-file-atomic/test/basic.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/node_modules/write-file-atomic/test/basic.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,97 @@
+"use strict";
+var test = require('tap').test;
+var requireInject = require('require-inject');
+var writeFileAtomic = requireInject('../index', {
+ 'graceful-fs': {
+ writeFile: function (tmpfile, data, options, cb) {
+ if (/nowrite/.test(tmpfile)) return cb('ENOWRITE');
+ cb();
+ },
+ chown: function (tmpfile, uid, gid, cb) {
+ if (/nochown/.test(tmpfile)) return cb('ENOCHOWN');
+ cb();
+ },
+ rename: function (tmpfile, filename, cb) {
+ if (/norename/.test(tmpfile)) return cb('ENORENAME');
+ cb();
+ },
+ unlink: function (tmpfile, cb) {
+ if (/nounlink/.test(tmpfile)) return cb('ENOUNLINK');
+ cb();
+ },
+ writeFileSync: function (tmpfile, data, options) {
+ if (/nowrite/.test(tmpfile)) throw 'ENOWRITE';
+ },
+ chownSync: function (tmpfile, uid, gid) {
+ if (/nochown/.test(tmpfile)) throw 'ENOCHOWN';
+ },
+ renameSync: function (tmpfile, filename) {
+ if (/norename/.test(tmpfile)) throw 'ENORENAME';
+ },
+ unlinkSync: function (tmpfile) {
+ if (/nounlink/.test(tmpfile)) throw 'ENOUNLINK';
+ },
+ }
+});
+var writeFileAtomicSync = writeFileAtomic.sync;
+
+test('async tests', function (t) {
+ t.plan(7);
+ writeFileAtomic('good', 'test', {mode: '0777'}, function (err) {
+ t.notOk(err, 'No errors occur when passing in options');
+ });
+ writeFileAtomic('good', 'test', function (err) {
+ t.notOk(err, 'No errors occur when NOT passing in options');
+ });
+ writeFileAtomic('nowrite', 'test', function (err) {
+ t.is(err, 'ENOWRITE', 'writeFile failures propagate');
+ });
+ writeFileAtomic('nochown', 'test', {chown: {uid:100,gid:100}}, function (err) {
+ t.is(err, 'ENOCHOWN', 'Chown failures propagate');
+ });
+ writeFileAtomic('nochown', 'test', function (err) {
+ t.notOk(err, 'No attempt to chown when no uid/gid passed in');
+ });
+ writeFileAtomic('norename', 'test', function (err) {
+ t.is(err, 'ENORENAME', 'Rename errors propagate');
+ });
+ writeFileAtomic('norename nounlink', 'test', function (err) {
+ t.is(err, 'ENORENAME', 'Failure to unlink the temp file does not clobber the original error');
+ });
+});
+
+test('sync tests', function (t) {
+ t.plan(7);
+ var throws = function (shouldthrow, msg, todo) {
+ var err;
+ try { todo() } catch (e) { err = e }
+ t.is(shouldthrow,err,msg);
+ }
+ var noexception = function (msg, todo) {
+ var err;
+ try { todo() } catch (e) { err = e }
+ t.notOk(err,msg);
+ }
+
+ noexception('No errors occur when passing in options',function (){
+ writeFileAtomicSync('good', 'test', {mode: '0777'});
+ })
+ noexception('No errors occur when NOT passing in options',function (){
+ writeFileAtomicSync('good', 'test');
+ });
+ throws('ENOWRITE', 'writeFile failures propagate', function () {
+ writeFileAtomicSync('nowrite', 'test');
+ });
+ throws('ENOCHOWN', 'Chown failures propagate', function () {
+ writeFileAtomicSync('nochown', 'test', {chown: {uid:100,gid:100}});
+ });
+ noexception('No attempt to chown when no uid/gid passed in', function (){
+ writeFileAtomicSync('nochown', 'test');
+ });
+ throws('ENORENAME', 'Rename errors propagate', function (){
+ writeFileAtomicSync('norename', 'test');
+ });
+ throws('ENORENAME', 'Failure to unlink the temp file does not clobber the original error', function (){
+ writeFileAtomicSync('norename nounlink', 'test');
+ });
+});
diff -Nru nodejs-0.11.14/deps/npm/.npmignore nodejs-0.11.15/deps/npm/.npmignore
--- nodejs-0.11.14/deps/npm/.npmignore 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/.npmignore 2015-01-20 21:22:17.000000000 +0000
@@ -25,3 +25,5 @@
/npm-*.tgz
*.pyc
+
+/test/tap/builtin-config
diff -Nru nodejs-0.11.14/deps/npm/package.json nodejs-0.11.15/deps/npm/package.json
--- nodejs-0.11.14/deps/npm/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -1,5 +1,5 @@
{
- "version": "2.0.0",
+ "version": "2.1.6",
"name": "npm",
"description": "A package manager for node",
"keywords": [
@@ -35,7 +35,7 @@
"ansi": "~0.3.0",
"ansicolors": "~0.3.2",
"ansistyles": "~0.1.3",
- "archy": "0",
+ "archy": "~1.0.0",
"async-some": "~1.0.1",
"block-stream": "0.0.7",
"char-spinner": "~1.0.1",
@@ -44,49 +44,56 @@
"chownr": "0",
"cmd-shim": "~2.0.1",
"columnify": "~1.2.1",
+ "config-chain": "~1.1.8",
+ "dezalgo": "~1.0.1",
"editor": "~0.1.0",
"fs-vacuum": "~1.2.1",
+ "fs-write-stream-atomic": "~1.0.2",
"fstream": "~1.0.2",
- "fstream-npm": "~1.0.0",
+ "fstream-npm": "~1.0.1",
"github-url-from-git": "~1.4.0",
"github-url-from-username-repo": "~1.0.2",
- "glob": "~4.0.5",
- "graceful-fs": "~3.0.0",
- "inflight": "~1.0.1",
- "ini": "~1.2.0",
- "init-package-json": "~1.0.0",
+ "glob": "~4.0.6",
+ "graceful-fs": "~3.0.4",
+ "inflight": "~1.0.4",
+ "inherits": "~2.0.1",
+ "ini": "~1.3.0",
+ "init-package-json": "~1.1.1",
"lockfile": "~1.0.0",
"lru-cache": "~2.5.0",
"minimatch": "~1.0.0",
"mkdirp": "~0.5.0",
"node-gyp": "~1.0.1",
"nopt": "~3.0.1",
- "normalize-package-data": "~1.0.1",
+ "normalize-package-data": "~1.0.3",
"npm-cache-filename": "~1.0.1",
"npm-install-checks": "~1.0.2",
- "npm-package-arg": "~2.1.2",
- "npm-registry-client": "~3.2.1",
- "npm-user-validate": "~0.1.0",
- "npmconf": "~2.0.8",
+ "npm-package-arg": "~2.1.3",
+ "npm-registry-client": "~3.2.4",
+ "npm-user-validate": "~0.1.1",
"npmlog": "~0.1.1",
- "once": "~1.3.0",
- "opener": "~1.3.0",
+ "once": "~1.3.1",
+ "opener": "~1.4.0",
"osenv": "~0.1.0",
"path-is-inside": "~1.0.0",
"read": "~1.0.4",
"read-installed": "~3.1.2",
"read-package-json": "~1.2.7",
- "request": "~2.42.0",
- "retry": "~0.6.0",
+ "readable-stream": "~1.0.32",
+ "realize-package-specifier": "~1.2.0",
+ "request": "~2.46.0",
+ "retry": "~0.6.1",
"rimraf": "~2.2.8",
- "semver": "~4.0.0",
- "sha": "~1.2.1",
+ "semver": "~4.1.0",
+ "sha": "~1.3.0",
"slide": "~1.1.6",
"sorted-object": "~1.0.0",
"tar": "~1.0.1",
"text-table": "~0.2.0",
"uid-number": "0.0.5",
- "which": "1"
+ "which": "1",
+ "wrappy": "~1.0.1",
+ "write-file-atomic": "~1.1.0"
},
"bundleDependencies": [
"abbrev",
@@ -102,9 +109,11 @@
"chownr",
"cmd-shim",
"columnify",
+ "config-chain",
"dezalgo",
"editor",
"fs-vacuum",
+ "fs-write-stream-atomic",
"fstream",
"fstream-npm",
"github-url-from-git",
@@ -127,7 +136,6 @@
"npm-package-arg",
"npm-registry-client",
"npm-user-validate",
- "npmconf",
"npmlog",
"once",
"opener",
@@ -136,6 +144,8 @@
"read",
"read-installed",
"read-package-json",
+ "readable-stream",
+ "realize-package-specifier",
"request",
"retry",
"rimraf",
@@ -146,15 +156,17 @@
"tar",
"text-table",
"uid-number",
- "which"
+ "which",
+ "wrappy",
+ "write-file-atomic"
],
"devDependencies": {
"marked": "~0.3.2",
- "marked-man": "~0.1.3",
- "nock": "~0.34.1",
- "npm-registry-couchapp": "~2.5.3",
+ "marked-man": "~0.1.4",
+ "nock": "~0.48.1",
+ "npm-registry-couchapp": "~2.6.2",
"npm-registry-mock": "~0.6.3",
- "require-inject": "~1.0.0",
+ "require-inject": "~1.1.0",
"tap": "~0.4.12"
},
"scripts": {
diff -Nru nodejs-0.11.14/deps/npm/README.md nodejs-0.11.15/deps/npm/README.md
--- nodejs-0.11.14/deps/npm/README.md 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/README.md 2015-01-20 21:22:17.000000000 +0000
@@ -154,7 +154,7 @@
if (er) return commandFailed(er)
// command succeeded, and data might have some info
})
- npm.on("log", function (message) { .... })
+ npm.registry.log.on("log", function (message) { .... })
})
The `load` function takes an object hash of the command-line configs.
diff -Nru nodejs-0.11.14/deps/npm/scripts/doc-build.sh nodejs-0.11.15/deps/npm/scripts/doc-build.sh
--- nodejs-0.11.14/deps/npm/scripts/doc-build.sh 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/scripts/doc-build.sh 2015-01-20 21:22:17.000000000 +0000
@@ -66,44 +66,59 @@
mkdir -p $(dirname $dest)
+html_replace_tokens () {
+ local url=$1
+ sed "s|@NAME@|$name|g" \
+ | sed "s|@DATE@|$date|g" \
+ | sed "s|@URL@|$url|g" \
+ | sed "s|@VERSION@|$version|g" \
+ | perl -p -e 's/]*)>([^\(]*\([0-9]\)) -- (.*?)<\/h1>/\2<\/h1> \3<\/p>/g' \
+ | perl -p -e 's/npm-npm/npm/g' \
+ | perl -p -e 's/([^"-])(npm-)?README(?!\.html)(\(1\))?/\1README<\/a>/g' \
+ | perl -p -e 's/README<\/a><\/title>/README<\/title>/g' \
+ | perl -p -e 's/([^"-])([^\(> ]+)(\(1\))/\1\2\3<\/a>/g' \
+ | perl -p -e 's/([^"-])([^\(> ]+)(\(3\))/\1 \2\3<\/a>/g' \
+ | perl -p -e 's/([^"-])([^\(> ]+)(\(5\))/\1 \2\3<\/a>/g' \
+ | perl -p -e 's/([^"-])([^\(> ]+)(\(7\))/\1 \2\3<\/a>/g' \
+ | perl -p -e 's/\([1357]\)<\/a><\/h1>/<\/a><\/h1>/g' \
+ | (if [ $(basename $(dirname $dest)) == "doc" ]; then
+ perl -p -e 's/ href="\.\.\// href="/g'
+ else
+ cat
+ fi)
+}
+
+man_replace_tokens () {
+ sed "s|@VERSION@|$version|g" \
+ | perl -p -e 's/(npm\\-)?([a-zA-Z\\\.\-]*)\(1\)/npm help \2/g' \
+ | perl -p -e 's/(npm\\-)?([a-zA-Z\\\.\-]*)\(([57])\)/npm help \3 \2/g' \
+ | perl -p -e 's/(npm\\-)?([a-zA-Z\\\.\-]*)\(3\)/npm apihelp \2/g' \
+ | perl -p -e 's/npm\(1\)/npm help npm/g' \
+ | perl -p -e 's/npm\(3\)/npm apihelp npm/g'
+}
+
case $dest in
*.[1357])
./node_modules/.bin/marked-man --roff $src \
- | sed "s|@VERSION@|$version|g" \
- | perl -pi -e 's/(npm\\-)?([a-zA-Z\\\.\-]*)\(1\)/npm help \2/g' \
- | perl -pi -e 's/(npm\\-)?([a-zA-Z\\\.\-]*)\(([57])\)/npm help \3 \2/g' \
- | perl -pi -e 's/(npm\\-)?([a-zA-Z\\\.\-]*)\(3\)/npm apihelp \2/g' \
- | perl -pi -e 's/npm\(1\)/npm help npm/g' \
- | perl -pi -e 's/npm\(3\)/npm apihelp npm/g' \
- > $dest
+ | man_replace_tokens > $dest
exit $?
;;
- *.html)
+
+ html/partial/*.html)
+ url=${dest/html\/partial\//}
+ cat $src | ./node_modules/.bin/marked | html_replace_tokens $url > $dest
+ ;;
+
+ html/*.html)
url=${dest/html\//}
(cat html/dochead.html && \
- cat $src | ./node_modules/.bin/marked &&
+ cat $src && \
cat html/docfoot.html)\
- | sed "s|@NAME@|$name|g" \
- | sed "s|@DATE@|$date|g" \
- | sed "s|@URL@|$url|g" \
- | sed "s|@VERSION@|$version|g" \
- | perl -pi -e 's/]*)>([^\(]*\([0-9]\)) -- (.*?)<\/h1>/\2<\/h1> \3<\/p>/g' \
- | perl -pi -e 's/npm-npm/npm/g' \
- | perl -pi -e 's/([^"-])(npm-)?README(?!\.html)(\(1\))?/\1README<\/a>/g' \
- | perl -pi -e 's/README<\/a><\/title>/README<\/title>/g' \
- | perl -pi -e 's/([^"-])([^\(> ]+)(\(1\))/\1\2\3<\/a>/g' \
- | perl -pi -e 's/([^"-])([^\(> ]+)(\(3\))/\1 \2\3<\/a>/g' \
- | perl -pi -e 's/([^"-])([^\(> ]+)(\(5\))/\1 \2\3<\/a>/g' \
- | perl -pi -e 's/([^"-])([^\(> ]+)(\(7\))/\1 \2\3<\/a>/g' \
- | perl -pi -e 's/\([1357]\)<\/a><\/h1>/<\/a><\/h1>/g' \
- | (if [ $(basename $(dirname $dest)) == "doc" ]; then
- perl -pi -e 's/ href="\.\.\// href="/g'
- else
- cat
- fi) \
+ | html_replace_tokens $url \
> $dest
exit $?
;;
+
*)
echo "Invalid destination type: $dest" >&2
exit 1
diff -Nru nodejs-0.11.14/deps/npm/test/common-tap.js nodejs-0.11.15/deps/npm/test/common-tap.js
--- nodejs-0.11.14/deps/npm/test/common-tap.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/common-tap.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,16 +1,27 @@
var spawn = require("child_process").spawn
+var path = require("path")
+var fs = require("fs")
var port = exports.port = 1337
exports.registry = "http://localhost:" + port
process.env.npm_config_loglevel = "error"
+var npm_config_cache = path.resolve(__dirname, "npm_cache")
+exports.npm_config_cache = npm_config_cache
+
var bin = exports.bin = require.resolve("../bin/npm-cli.js")
var once = require("once")
+
exports.npm = function (cmd, opts, cb) {
cb = once(cb)
cmd = [bin].concat(cmd)
opts = opts || {}
+ opts.env = opts.env ? opts.env : process.env
+ if (!opts.env.npm_config_cache) {
+ opts.env.npm_config_cache = npm_config_cache
+ }
+
var stdout = ""
, stderr = ""
, node = process.execPath
@@ -29,4 +40,28 @@
child.on("close", function (code) {
cb(null, code, stdout, stderr)
})
+ return child
+}
+
+// based on http://bit.ly/1tkI6DJ
+function deleteNpmCacheRecursivelySync(cache) {
+ cache = cache ? cache : npm_config_cache
+ var files = []
+ var res
+ if( fs.existsSync(cache) ) {
+ files = fs.readdirSync(cache)
+ files.forEach(function(file,index) {
+ var curPath = path.resolve(cache, file)
+ if(fs.lstatSync(curPath).isDirectory()) { // recurse
+ deleteNpmCacheRecursivelySync(curPath)
+ } else { // delete file
+ if (res = fs.unlinkSync(curPath))
+ throw Error("Failed to delete file " + curPath + ", error " + res)
+ }
+ })
+ if (res = fs.rmdirSync(cache))
+ throw Error("Failed to delete directory " + cache + ", error " + res)
+ }
+ return 0
}
+exports.deleteNpmCacheRecursivelySync = deleteNpmCacheRecursivelySync
\ No newline at end of file
diff -Nru nodejs-0.11.14/deps/npm/test/fixtures/config/builtin nodejs-0.11.15/deps/npm/test/fixtures/config/builtin
--- nodejs-0.11.14/deps/npm/test/fixtures/config/builtin 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/fixtures/config/builtin 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1 @@
+builtin-config = true
diff -Nru nodejs-0.11.14/deps/npm/test/fixtures/config/globalconfig nodejs-0.11.15/deps/npm/test/fixtures/config/globalconfig
--- nodejs-0.11.14/deps/npm/test/fixtures/config/globalconfig 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/fixtures/config/globalconfig 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1 @@
+package-config:foo = boo
diff -Nru nodejs-0.11.14/deps/npm/test/fixtures/config/malformed nodejs-0.11.15/deps/npm/test/fixtures/config/malformed
--- nodejs-0.11.14/deps/npm/test/fixtures/config/malformed 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/fixtures/config/malformed 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1 @@
+email = """
\ No newline at end of file
diff -Nru nodejs-0.11.14/deps/npm/test/fixtures/config/multi-ca nodejs-0.11.15/deps/npm/test/fixtures/config/multi-ca
--- nodejs-0.11.14/deps/npm/test/fixtures/config/multi-ca 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/fixtures/config/multi-ca 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,32 @@
+-----BEGIN CERTIFICATE-----
+MIICjTCCAfigAwIBAgIEMaYgRzALBgkqhkiG9w0BAQQwRTELMAkGA1UEBhMCVVMx
+NjA0BgNVBAoTLU5hdGlvbmFsIEFlcm9uYXV0aWNzIGFuZCBTcGFjZSBBZG1pbmlz
+dHJhdGlvbjAmFxE5NjA1MjgxMzQ5MDUrMDgwMBcROTgwNTI4MTM0OTA1KzA4MDAw
+ZzELMAkGA1UEBhMCVVMxNjA0BgNVBAoTLU5hdGlvbmFsIEFlcm9uYXV0aWNzIGFu
+ZCBTcGFjZSBBZG1pbmlzdHJhdGlvbjEgMAkGA1UEBRMCMTYwEwYDVQQDEwxTdGV2
+ZSBTY2hvY2gwWDALBgkqhkiG9w0BAQEDSQAwRgJBALrAwyYdgxmzNP/ts0Uyf6Bp
+miJYktU/w4NG67ULaN4B5CnEz7k57s9o3YY3LecETgQ5iQHmkwlYDTL2fTgVfw0C
+AQOjgaswgagwZAYDVR0ZAQH/BFowWDBWMFQxCzAJBgNVBAYTAlVTMTYwNAYDVQQK
+Ey1OYXRpAAAAACBBZXJvbmF1dGljcyBhbmQgU3BhY2UgQWRtaW5pc3RyYXRpb24x
+DTALBgNVBAMTBENSTDEwFwYDVR0BAQH/BA0wC4AJODMyOTcwODEwMBgGA1UdAgQR
+MA8ECTgzMjk3MDgyM4ACBSAwDQYDVR0KBAYwBAMCBkAwCwYJKoZIhvcNAQEEA4GB
+AH2y1VCEw/A4zaXzSYZJTTUi3uawbbFiS2yxHvgf28+8Js0OHXk1H1w2d6qOHH21
+X82tZXd/0JtG0g1T9usFFBDvYK8O0ebgz/P5ELJnBL2+atObEuJy1ZZ0pBDWINR3
+WkDNLCGiTkCKp0F5EWIrVDwh54NNevkCQRZita+z4IBO
+-----END CERTIFICATE-----
+-----BEGIN CERTIFICATE-----
+AAAAAACCAfigAwIBAgIEMaYgRzALBgkqhkiG9w0BAQQwRTELMAkGA1UEBhMCVVMx
+NjA0BgNVBAoTLU5hdGlvbmFsIEFlcm9uYXV0aWNzIGFuZCBTcGFjZSBBZG1pbmlz
+dHJhdGlvbjAmFxE5NjA1MjgxMzQ5MDUrMDgwMBcROTgwNTI4MTM0OTA1KzA4MDAw
+ZzELMAkGA1UEBhMCVVMxNjA0BgNVBAoTLU5hdGlvbmFsIEFlcm9uYXV0aWNzIGFu
+ZCBTcGFjZSBBZG1pbmlzdHJhdGlvbjEgMAkGA1UEBRMCMTYwEwYDVQQDEwxTdGV2
+ZSBTY2hvY2gwWDALBgkqhkiG9w0BAQEDSQAwRgJBALrAwyYdgxmzNP/ts0Uyf6Bp
+miJYktU/w4NG67ULaN4B5CnEz7k57s9o3YY3LecETgQ5iQHmkwlYDTL2fTgVfw0C
+AQOjgaswgagwZAYDVR0ZAQH/BFowWDBWMFQxCzAJBgNVBAYTAlVTMTYwNAYDVQQK
+Ey1OYXRpb25hbCBBZXJvbmF1dGljcyBhbmQgU3BhY2UgQWRtaW5pc3RyYXRpb24x
+DTALBgNVBAMTBENSTDEwFwYDVR0BAQH/BA0wC4AJODMyOTcwODEwMBgGA1UdAgQR
+MA8ECTgzMjk3MDgyM4ACBSAwDQYDVR0KBAYwBAMCBkAwCwYJKoZIhvcNAQEEA4GB
+AH2y1VCEw/A4zaXzSYZJTTUi3uawbbFiS2yxHvgf28+8Js0OHXk1H1w2d6qOHH21
+X82tZXd/0JtG0g1T9usFFBDvYK8O0ebgz/P5ELJnBL2+atObEuJy1ZZ0pBDWINR3
+WkDNLCGiTkCKp0F5EWIrVDwh54NNevkCQRZita+z4IBO
+-----END CERTIFICATE-----
diff -Nru nodejs-0.11.14/deps/npm/test/fixtures/config/.npmrc nodejs-0.11.15/deps/npm/test/fixtures/config/.npmrc
--- nodejs-0.11.14/deps/npm/test/fixtures/config/.npmrc 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/fixtures/config/.npmrc 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1 @@
+just = testing
diff -Nru nodejs-0.11.14/deps/npm/test/fixtures/config/userconfig nodejs-0.11.15/deps/npm/test/fixtures/config/userconfig
--- nodejs-0.11.14/deps/npm/test/fixtures/config/userconfig 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/fixtures/config/userconfig 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,23 @@
+email = i@izs.me
+env-thing = ${random_env_var}
+init.author.name = Isaac Z. Schlueter
+init.author.email = i@izs.me
+init.author.url = http://blog.izs.me/
+init.version = 1.2.3
+proprietary-attribs = false
+npm:publishtest = true
+_npmjs.org:couch = https://admin:password@localhost:5984/registry
+npm-www:nocache = 1
+nodedir = /Users/isaacs/dev/js/node-v0.8
+sign-git-tag = true
+message = v%s
+strict-ssl = false
+tmp = ~/.tmp
+_auth = dXNlcm5hbWU6cGFzc3dvcmQ=
+
+[_token]
+AuthSession = yabba-dabba-doodle
+version = 1
+expires = 1345001053415
+path = /
+httponly = true
diff -Nru nodejs-0.11.14/deps/npm/test/fixtures/config/userconfig-with-gc nodejs-0.11.15/deps/npm/test/fixtures/config/userconfig-with-gc
--- nodejs-0.11.14/deps/npm/test/fixtures/config/userconfig-with-gc 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/fixtures/config/userconfig-with-gc 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,22 @@
+globalconfig=/Users/ogd/Documents/projects/npm/npm/test/fixtures/config/globalconfig
+email=i@izs.me
+env-thing=asdf
+init.author.name=Isaac Z. Schlueter
+init.author.email=i@izs.me
+init.author.url=http://blog.izs.me/
+init.version=1.2.3
+proprietary-attribs=false
+npm:publishtest=true
+_npmjs.org:couch=https://admin:password@localhost:5984/registry
+npm-www:nocache=1
+sign-git-tag=false
+message=v%s
+strict-ssl=false
+_auth=dXNlcm5hbWU6cGFzc3dvcmQ=
+
+[_token]
+AuthSession=yabba-dabba-doodle
+version=1
+expires=1345001053415
+path=/
+httponly=true
diff -Nru nodejs-0.11.14/deps/npm/test/tap/00-check-mock-dep.js nodejs-0.11.15/deps/npm/test/tap/00-check-mock-dep.js
--- nodejs-0.11.14/deps/npm/test/tap/00-check-mock-dep.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/00-check-mock-dep.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,6 +1,7 @@
console.log("TAP Version 13")
-process.on("uncaughtException", function(er) {
+process.on("uncaughtException", function (er) {
+ if (er) { throw er }
console.log("not ok - Failed checking mock registry dep. Expect much fail!")
console.log("1..1")
process.exit(1)
@@ -10,6 +11,7 @@
var semver = require("semver")
var mock = require("npm-registry-mock/package.json").version
var req = require("../../package.json").devDependencies["npm-registry-mock"]
+
assert(semver.satisfies(mock, req))
console.log("ok")
console.log("1..1")
diff -Nru nodejs-0.11.14/deps/npm/test/tap/00-config-setup.js nodejs-0.11.15/deps/npm/test/tap/00-config-setup.js
--- nodejs-0.11.14/deps/npm/test/tap/00-config-setup.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/00-config-setup.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,68 @@
+var path = require("path")
+var userconfigSrc = path.resolve(__dirname, "..", "fixtures", "config", "userconfig")
+exports.userconfig = userconfigSrc + "-with-gc"
+exports.globalconfig = path.resolve(__dirname, "..", "fixtures", "config", "globalconfig")
+exports.builtin = path.resolve(__dirname, "..", "fixtures", "config", "builtin")
+exports.malformed = path.resolve(__dirname, "..", "fixtures", "config", "malformed")
+exports.ucData =
+ { globalconfig: exports.globalconfig,
+ email: "i@izs.me",
+ "env-thing": "asdf",
+ "init.author.name": "Isaac Z. Schlueter",
+ "init.author.email": "i@izs.me",
+ "init.author.url": "http://blog.izs.me/",
+ "init.version": "1.2.3",
+ "proprietary-attribs": false,
+ "npm:publishtest": true,
+ "_npmjs.org:couch": "https://admin:password@localhost:5984/registry",
+ "npm-www:nocache": "1",
+ nodedir: "/Users/isaacs/dev/js/node-v0.8",
+ "sign-git-tag": true,
+ message: "v%s",
+ "strict-ssl": false,
+ "tmp": process.env.HOME + "/.tmp",
+ _auth: "dXNlcm5hbWU6cGFzc3dvcmQ=",
+ _token:
+ { AuthSession: "yabba-dabba-doodle",
+ version: "1",
+ expires: "1345001053415",
+ path: "/",
+ httponly: true } }
+
+// set the userconfig in the env
+// unset anything else that npm might be trying to foist on us
+Object.keys(process.env).forEach(function (k) {
+ if (k.match(/^npm_config_/i)) {
+ delete process.env[k]
+ }
+})
+process.env.npm_config_userconfig = exports.userconfig
+process.env.npm_config_other_env_thing = 1000
+process.env.random_env_var = "asdf"
+process.env.npm_config__underbar_env_thing = "underful"
+process.env.NPM_CONFIG_UPPERCASE_ENV_THING = 42
+
+exports.envData = {
+ userconfig: exports.userconfig,
+ "_underbar-env-thing": "underful",
+ "uppercase-env-thing": "42",
+ "other-env-thing": "1000"
+}
+exports.envDataFix = {
+ userconfig: exports.userconfig,
+ "_underbar-env-thing": "underful",
+ "uppercase-env-thing": 42,
+ "other-env-thing": 1000
+}
+
+
+if (module === require.main) {
+ // set the globalconfig in the userconfig
+ var fs = require("fs")
+ var uc = fs.readFileSync(userconfigSrc)
+ var gcini = "globalconfig = " + exports.globalconfig + "\n"
+ fs.writeFileSync(exports.userconfig, gcini + uc)
+
+ console.log("0..1")
+ console.log("ok 1 setup done")
+}
diff -Nru nodejs-0.11.14/deps/npm/test/tap/00-verify-bundle-deps.js nodejs-0.11.15/deps/npm/test/tap/00-verify-bundle-deps.js
--- nodejs-0.11.14/deps/npm/test/tap/00-verify-bundle-deps.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/00-verify-bundle-deps.js 2015-01-20 21:22:17.000000000 +0000
@@ -16,7 +16,7 @@
})
t.same(
- fs.readdirSync(path.resolve(__dirname, '../../node_modules')).filter(function (name) {
+ fs.readdirSync(path.resolve(__dirname, "../../node_modules")).filter(function (name) {
return (dev.indexOf(name) === -1) && (name !== ".bin")
}).sort(),
bundled.sort(),
diff -Nru nodejs-0.11.14/deps/npm/test/tap/00-verify-ls-ok.js nodejs-0.11.15/deps/npm/test/tap/00-verify-ls-ok.js
--- nodejs-0.11.14/deps/npm/test/tap/00-verify-ls-ok.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/00-verify-ls-ok.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,15 +1,18 @@
+var common = require("../common-tap")
var test = require("tap").test
-var node = process.execPath
var path = require("path")
var cwd = path.resolve(__dirname, "..", "..")
-var npm = path.resolve(cwd, "cli.js")
-var spawn = require("child_process").spawn
+var fs = require("fs")
test("npm ls in npm", function (t) {
+ t.ok(fs.existsSync(cwd), "ensure that the path we are calling ls within exists")
+ var files = fs.readdirSync(cwd)
+ t.notEqual(files.length, 0, "ensure there are files in the directory we are to ls")
+
var opt = { cwd: cwd, stdio: [ "ignore", "ignore", 2 ] }
- var child = spawn(node, [npm, "ls"], opt)
- child.on("close", function (code) {
- t.notOk(code)
+ common.npm(["ls"], opt, function (err, code) {
+ t.ifError(err, "error should not exist")
+ t.equal(code, 0, "npm ls exited with code")
t.end()
})
})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/404-parent.js nodejs-0.11.15/deps/npm/test/tap/404-parent.js
--- nodejs-0.11.14/deps/npm/test/tap/404-parent.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/404-parent.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,26 +1,25 @@
-var common = require('../common-tap.js')
-var test = require('tap').test
-var npm = require('../../')
-var osenv = require('osenv')
-var path = require('path')
-var fs = require('fs')
-var rimraf = require('rimraf')
-var mkdirp = require('mkdirp')
-var pkg = path.resolve(__dirname, '404-parent')
+var common = require("../common-tap.js")
+var test = require("tap").test
+var npm = require("../../")
+var osenv = require("osenv")
+var path = require("path")
+var fs = require("fs")
+var rimraf = require("rimraf")
+var mkdirp = require("mkdirp")
+var pkg = path.resolve(__dirname, "404-parent")
var mr = require("npm-registry-mock")
-test('404-parent: if parent exists, specify parent in error message', function(t) {
+test("404-parent: if parent exists, specify parent in error message", function (t) {
setup()
- rimraf.sync(path.resolve(pkg, 'node_modules'))
- performInstall(function(err) {
- t.ok(err instanceof Error)
- t.pass('error was returned')
- t.ok(err.parent === '404-parent-test')
+ rimraf.sync(path.resolve(pkg, "node_modules"))
+ performInstall(function (err) {
+ t.ok(err instanceof Error, "error was returned")
+ t.ok(err.parent === "404-parent-test", "error's parent set")
t.end()
})
})
-test('cleanup', function(t) {
+test("cleanup", function (t) {
process.chdir(osenv.tmpdir())
rimraf.sync(pkg)
t.end()
@@ -28,23 +27,23 @@
function setup() {
mkdirp.sync(pkg)
- mkdirp.sync(path.resolve(pkg, 'cache'))
- fs.writeFileSync(path.resolve(pkg, 'package.json'), JSON.stringify({
- author: 'Evan Lucas',
- name: '404-parent-test',
- version: '0.0.0',
- description: 'Test for 404-parent',
+ mkdirp.sync(path.resolve(pkg, "cache"))
+ fs.writeFileSync(path.resolve(pkg, "package.json"), JSON.stringify({
+ author: "Evan Lucas",
+ name: "404-parent-test",
+ version: "0.0.0",
+ description: "Test for 404-parent",
dependencies: {
- 'test-npm-404-parent-test': '*'
+ "test-npm-404-parent-test": "*"
}
- }), 'utf8')
+ }), "utf8")
process.chdir(pkg)
}
function performInstall(cb) {
mr(common.port, function (s) { // create mock registry.
- npm.load({registry: common.registry}, function() {
- npm.commands.install(pkg, [], function(err) {
+ npm.load({registry: common.registry}, function () {
+ npm.commands.install(pkg, [], function (err) {
cb(err)
s.close() // shutdown mock npm server.
})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/builtin-config.js nodejs-0.11.15/deps/npm/test/tap/builtin-config.js
--- nodejs-0.11.14/deps/npm/test/tap/builtin-config.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/builtin-config.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,125 @@
+var fs = require("fs")
+
+if (process.argv[2] === "write-builtin") {
+ var pid = process.argv[3]
+ fs.writeFileSync("npmrc", "foo=bar\npid=" + pid + "\n")
+ return
+}
+
+var rcdata = "foo=bar\npid=" + process.pid + "\n"
+var common = require("../common-tap.js")
+var path = require("path")
+var rimraf = require("rimraf")
+var mkdirp = require("mkdirp")
+var folder = path.resolve(__dirname, "builtin-config")
+var test = require("tap").test
+var npm = path.resolve(__dirname, "../..")
+var spawn = require("child_process").spawn
+var node = process.execPath
+
+test("setup", function (t) {
+ rimraf.sync(folder)
+ mkdirp.sync(folder + "/first")
+ mkdirp.sync(folder + "/second")
+ mkdirp.sync(folder + "/cache")
+ mkdirp.sync(folder + "/tmp")
+
+ t.pass("finished setup")
+ t.end()
+})
+
+
+test("install npm into first folder", function (t) {
+ var args = ["install", npm, "-g",
+ "--prefix=" + folder + "/first",
+ "--cache=" + folder + "/cache",
+ "--no-spin",
+ "--loglevel=silent",
+ "--tmp=" + folder + "/tmp"]
+ common.npm(args, {stdio: "inherit"}, function (er, code) {
+ if (er) throw er
+ t.equal(code, 0)
+ t.end()
+ })
+})
+
+test("write npmrc file", function (t) {
+ common.npm(["explore", "npm", "-g",
+ "--prefix=" + folder + "/first",
+ "--cache=" + folder + "/cache",
+ "--tmp=" + folder + "/tmp",
+ "--no-spin",
+ "--",
+ node, __filename, "write-builtin", process.pid
+ ],
+ {"stdio": "inherit"},
+ function (er, code) {
+ if (er) throw er
+ t.equal(code, 0)
+ t.end()
+ })
+})
+
+test("use first npm to install second npm", function (t) {
+ // get the root location
+ common.npm([ "root", "-g",
+ "--prefix=" + folder + "/first",
+ "--cache=" + folder + "/cache",
+ "--tmp=" + folder + "/tmp",
+ "--no-spin"
+ ], {}, function (er, code, so) {
+ if (er) throw er
+ t.equal(code, 0)
+ var root = so.trim()
+ t.ok(fs.statSync(root).isDirectory())
+
+ var bin = path.resolve(root, "npm/bin/npm-cli.js")
+ spawn( node
+ , [ bin
+ , "install", npm
+ , "-g"
+ , "--prefix=" + folder + "/second"
+ , "--cache=" + folder + "/cache"
+ , "--tmp=" + folder + "/tmp"
+ , "--no-spin"
+ ])
+ .on("error", function (er) { throw er })
+ .on("close", function (code) {
+ t.equal(code, 0, "code is zero")
+ t.end()
+ })
+ })
+})
+
+test("verify that the builtin config matches", function (t) {
+ common.npm([ "root", "-g",
+ "--prefix=" + folder + "/first",
+ "--cache=" + folder + "/cache",
+ "--tmp=" + folder + "/tmp"
+ ], {}, function (er, code, so) {
+ if (er) throw er
+ t.equal(code, 0)
+ var firstRoot = so.trim()
+ common.npm([ "root", "-g",
+ "--prefix=" + folder + "/second",
+ "--cache=" + folder + "/cache",
+ "--tmp=" + folder + "/tmp"
+ ], {}, function (er, code, so) {
+ if (er) throw er
+ t.equal(code, 0)
+ var secondRoot = so.trim()
+ var firstRc = path.resolve(firstRoot, "npm", "npmrc")
+ var secondRc = path.resolve(secondRoot, "npm", "npmrc")
+ var firstData = fs.readFileSync(firstRc, "utf8")
+ var secondData = fs.readFileSync(secondRc, "utf8")
+ t.equal(firstData, secondData)
+ t.end()
+ })
+ })
+})
+
+
+test("clean", function (t) {
+ rimraf.sync(folder)
+ t.end()
+})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/cache-add-localdir-fallback.js nodejs-0.11.15/deps/npm/test/tap/cache-add-localdir-fallback.js
--- nodejs-0.11.14/deps/npm/test/tap/cache-add-localdir-fallback.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/cache-add-localdir-fallback.js 2015-01-20 21:22:17.000000000 +0000
@@ -3,45 +3,49 @@
var npm = require("../../lib/npm.js")
var requireInject = require("require-inject")
-npm.load({loglevel : "silent"}, function () {
- var resolved = path.resolve(__dirname, "dir-with-package")
- var resolvedPackage = path.join(resolved, "package.json")
+var realizePackageSpecifier = requireInject("realize-package-specifier", {
+ "fs": {
+ stat: function (file, cb) {
+ process.nextTick(function () {
+ switch (file) {
+ case path.resolve("named"):
+ cb(new Error("ENOENT"))
+ break
+ case path.resolve("file.tgz"):
+ cb(null, { isDirectory: function () { return false } })
+ break
+ case path.resolve("dir-no-package"):
+ cb(null, { isDirectory: function () { return true } })
+ break
+ case path.resolve("dir-no-package/package.json"):
+ cb(new Error("ENOENT"))
+ break
+ case path.resolve("dir-with-package"):
+ cb(null, { isDirectory: function () { return true } })
+ break
+ case path.resolve("dir-with-package/package.json"):
+ cb(null, {})
+ break
+ case path.resolve(__dirname, "dir-with-package"):
+ cb(null, { isDirectory: function () { return true } })
+ break
+ case path.join(__dirname, "dir-with-package", "package.json"):
+ cb(null, {})
+ break
+ case path.resolve(__dirname, "file.tgz"):
+ cb(null, { isDirectory: function () { return false } })
+ break
+ default:
+ throw new Error("Unknown test file passed to stat: " + file)
+ }
+ })
+ }
+ }
+})
+npm.load({loglevel : "silent"}, function () {
var cache = requireInject("../../lib/cache.js", {
- "graceful-fs": {
- stat: function (file, cb) {
- process.nextTick(function () {
- switch (file) {
- case "named":
- cb(new Error("ENOENT"))
- break
- case "file.tgz":
- cb(null, { isDirectory: function () { return false } })
- break
- case "dir-no-package":
- cb(null, { isDirectory: function () { return true } })
- break
- case "dir-no-package/package.json":
- cb(new Error("ENOENT"))
- break
- case "dir-with-package":
- cb(null, { isDirectory: function () { return true } })
- break
- case "dir-with-package/package.json":
- cb(null, {})
- break
- case resolved:
- cb(null, { isDirectory: function () { return true } })
- break
- case resolvedPackage:
- cb(null, {})
- break
- default:
- throw new Error("Unknown test file passed to stat: " + file)
- }
- })
- }
- },
+ "realize-package-specifier": realizePackageSpecifier,
"../../lib/cache/add-named.js": function addNamed (name, version, data, cb) {
cb(null, "addNamed")
},
@@ -51,7 +55,7 @@
})
test("npm install localdir fallback", function (t) {
- t.plan(10)
+ t.plan(12)
cache.add("named", null, null, false, function (er, which) {
t.ifError(er, "named was cached")
t.is(which, "addNamed", "registry package name")
@@ -72,5 +76,9 @@
t.ifError(er, "local directory (as URI) with package was cached")
t.is(which, "addLocal", "file: URI to local directory with package.json")
})
+ cache.add("file:./file.tgz", null, __dirname, false, function (er, which) {
+ t.ifError(er, "local file (as URI) with package was cached")
+ t.is(which, "addLocal", "file: URI to local file with package.json")
+ })
})
})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/cache-add-unpublished.js nodejs-0.11.15/deps/npm/test/tap/cache-add-unpublished.js
--- nodejs-0.11.14/deps/npm/test/tap/cache-add-unpublished.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/cache-add-unpublished.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,61 +1,12 @@
-var common = require('../common-tap.js')
-var test = require('tap').test
-
-var server
-
-var port = common.port
-var http = require("http")
-
-var doc = {
- "_id": "superfoo",
- "_rev": "5-d11adeec0fdfea6b96b120610d2bed71",
- "name": "superfoo",
- "time": {
- "modified": "2014-02-18T18:35:02.930Z",
- "created": "2014-02-18T18:34:08.437Z",
- "1.1.0": "2014-02-18T18:34:08.437Z",
- "unpublished": {
- "name": "isaacs",
- "time": "2014-04-30T18:26:45.584Z",
- "tags": {
- "latest": "1.1.0"
- },
- "maintainers": [
- {
- "name": "foo",
- "email": "foo@foo.com"
- }
- ],
- "description": "do lots a foo",
- "versions": [
- "1.1.0"
- ]
- }
- },
- "_attachments": {}
-}
-
-test("setup", function (t) {
- server = http.createServer(function(req, res) {
- res.end(JSON.stringify(doc))
- })
- server.listen(port, function() {
- t.end()
- })
-})
+var common = require("../common-tap.js")
+var test = require("tap").test
test("cache add", function (t) {
common.npm(["cache", "add", "superfoo"], {}, function (er, c, so, se) {
if (er) throw er
- t.ok(c)
- t.equal(so, "")
- t.similar(se, /404 Not Found: superfoo/)
- t.end()
- })
-})
-
-test("cleanup", function (t) {
- server.close(function() {
+ t.ok(c, "got non-zero exit code")
+ t.equal(so, "", "nothing printed to stdout")
+ t.similar(se, /404 Not Found: superfoo/, "got expected error")
t.end()
})
})
Binary files /tmp/Mhog4P8ZHE/nodejs-0.11.14/deps/npm/test/tap/cache-shasum-fork/underscore-1.5.1.tgz and /tmp/Z_ez7cGlqC/nodejs-0.11.15/deps/npm/test/tap/cache-shasum-fork/underscore-1.5.1.tgz differ
diff -Nru nodejs-0.11.14/deps/npm/test/tap/cache-shasum-fork.js nodejs-0.11.15/deps/npm/test/tap/cache-shasum-fork.js
--- nodejs-0.11.14/deps/npm/test/tap/cache-shasum-fork.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/cache-shasum-fork.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,83 @@
+var test = require("tap").test
+var path = require("path")
+var fs = require("fs")
+var rimraf = require("rimraf")
+var mkdirp = require("mkdirp")
+var mr = require("npm-registry-mock")
+var common = require("../common-tap.js")
+var cache = path.resolve(__dirname, "cache-shasum-fork", "CACHE")
+var cwd = path.resolve(__dirname, "cache-shasum-fork", "CWD")
+var server
+
+// Test for https://github.com/npm/npm/issues/3265
+
+test("mock reg", function (t) {
+ rimraf.sync(cache)
+ mkdirp.sync(cache)
+ rimraf.sync(cwd)
+ mkdirp.sync(path.join(cwd, "node_modules"))
+ mr(common.port, function (s) {
+ server = s
+ t.pass("ok")
+ t.end()
+ })
+})
+
+test("npm cache - install from fork", function (t) {
+ // Install from a tarball that thinks it is underscore@1.5.1
+ // (but is actually a fork)
+ var forkPath = path.resolve(
+ __dirname, "cache-shasum-fork", "underscore-1.5.1.tgz")
+ common.npm(["install", forkPath], {
+ cwd: cwd,
+ env: {
+ "npm_config_cache" : cache,
+ "npm_config_registry" : common.registry,
+ "npm_config_loglevel" : "silent"
+ }
+ }, function (err, code, stdout, stderr) {
+ t.ifErr(err, "install finished without error")
+ t.notOk(stderr, "Should not get data on stderr: " + stderr)
+ t.equal(code, 0, "install finished successfully")
+
+ t.equal(stdout, "underscore@1.5.1 node_modules/underscore\n")
+ var index = fs.readFileSync(
+ path.join(cwd, "node_modules", "underscore", "index.js"),
+ "utf8"
+ )
+ t.equal(index, 'console.log("This is the fork");\n\n')
+ t.end()
+ })
+})
+
+test("npm cache - install from origin", function (t) {
+ // Now install the real 1.5.1.
+ rimraf.sync(path.join(cwd, "node_modules"))
+ mkdirp.sync(path.join(cwd, "node_modules"))
+ common.npm(["install", "underscore"], {
+ cwd: cwd,
+ env: {
+ "npm_config_cache" : cache,
+ "npm_config_registry" : common.registry,
+ "npm_config_loglevel" : "silent"
+ }
+ }, function (err, code, stdout, stderr) {
+ t.ifErr(err, "install finished without error")
+ t.equal(code, 0, "install finished successfully")
+ t.notOk(stderr, "Should not get data on stderr: " + stderr)
+ t.equal(stdout, "underscore@1.5.1 node_modules/underscore\n")
+ var index = fs.readFileSync(
+ path.join(cwd, "node_modules", "underscore", "index.js"),
+ "utf8"
+ )
+ t.equal(index, "module.exports = require('./underscore');\n")
+ t.end()
+ })
+})
+
+test("cleanup", function (t) {
+ server.close()
+ rimraf.sync(cache)
+ rimraf.sync(cwd)
+ t.end()
+})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/cache-shasum.js nodejs-0.11.15/deps/npm/test/tap/cache-shasum.js
--- nodejs-0.11.14/deps/npm/test/tap/cache-shasum.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/cache-shasum.js 2015-01-20 21:22:17.000000000 +0000
@@ -10,7 +10,7 @@
var sha = require("sha")
var server
-test("mock reg", function(t) {
+test("mock reg", function (t) {
rimraf.sync(cache)
mkdirp.sync(cache)
mr(common.port, function (s) {
@@ -20,7 +20,7 @@
})
})
-test("npm cache add request", function(t) {
+test("npm cache add request", function (t) {
var c = spawn(process.execPath, [
npm, "cache", "add", "request@2.27.0",
"--cache=" + cache,
@@ -29,17 +29,17 @@
])
c.stderr.pipe(process.stderr)
- c.stdout.on("data", function(d) {
+ c.stdout.on("data", function (d) {
t.fail("Should not get data on stdout: " + d)
})
- c.on("close", function(code) {
+ c.on("close", function (code) {
t.notOk(code, "exit ok")
t.end()
})
})
-test("compare", function(t) {
+test("compare", function (t) {
var d = path.resolve(__dirname, "cache-shasum/request")
var p = path.resolve(d, "2.27.0/package.tgz")
var r = require("./cache-shasum/localhost_1337/request/.cache.json")
@@ -52,7 +52,7 @@
})
})
-test("cleanup", function(t) {
+test("cleanup", function (t) {
server.close()
rimraf.sync(cache)
t.end()
diff -Nru nodejs-0.11.14/deps/npm/test/tap/circular-dep.js nodejs-0.11.15/deps/npm/test/tap/circular-dep.js
--- nodejs-0.11.14/deps/npm/test/tap/circular-dep.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/circular-dep.js 2015-01-20 21:22:17.000000000 +0000
@@ -17,12 +17,12 @@
setup(function () {
npm.install("optimist", function (err) {
if (err) return t.fail(err)
- npm.dedupe(function(err) {
+ npm.dedupe(function (err) {
if (err) return t.fail(err)
t.ok(existsSync(path.resolve(pkg,
"minimist", "node_modules", "optimist",
"node_modules", "minimist"
- )))
+ )), "circular dependency uncircled")
cleanup()
server.close()
})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/config-basic.js nodejs-0.11.15/deps/npm/test/tap/config-basic.js
--- nodejs-0.11.14/deps/npm/test/tap/config-basic.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/config-basic.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,66 @@
+var test = require("tap").test
+var npmconf = require("../../lib/config/core.js")
+var common = require("./00-config-setup.js")
+var path = require("path")
+
+var projectData = {
+ "save-prefix": "~",
+ "proprietary-attribs": false
+}
+
+var ucData = common.ucData
+var envData = common.envData
+var envDataFix = common.envDataFix
+
+var gcData = { "package-config:foo": "boo" }
+
+var biData = {}
+
+var cli = { foo: "bar", umask: 022 }
+
+var expectList =
+[ cli,
+ envDataFix,
+ projectData,
+ ucData,
+ gcData,
+ biData ]
+
+var expectSources = {
+ cli: { data: cli },
+ env: {
+ data: envDataFix,
+ source: envData,
+ prefix: ""
+ },
+ project: {
+ path: path.resolve(__dirname, "..", "..", ".npmrc"),
+ type: "ini",
+ data: projectData
+ },
+ user: {
+ path: common.userconfig,
+ type: "ini",
+ data: ucData
+ },
+ global: {
+ path: common.globalconfig,
+ type: "ini",
+ data: gcData
+ },
+ builtin: { data: biData }
+}
+
+test("no builtin", function (t) {
+ npmconf.load(cli, function (er, conf) {
+ if (er) throw er
+ t.same(conf.list, expectList)
+ t.same(conf.sources, expectSources)
+ t.same(npmconf.rootConf.list, [])
+ t.equal(npmconf.rootConf.root, npmconf.defs.defaults)
+ t.equal(conf.root, npmconf.defs.defaults)
+ t.equal(conf.get("umask"), 022)
+ t.equal(conf.get("heading"), "npm")
+ t.end()
+ })
+})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/config-builtin.js nodejs-0.11.15/deps/npm/test/tap/config-builtin.js
--- nodejs-0.11.14/deps/npm/test/tap/config-builtin.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/config-builtin.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,68 @@
+var test = require("tap").test
+var npmconf = require("../../lib/config/core.js")
+var common = require("./00-config-setup.js")
+var path = require("path")
+
+var ucData = common.ucData
+
+var envData = common.envData
+var envDataFix = common.envDataFix
+
+var gcData = { "package-config:foo": "boo" }
+
+var biData = { "builtin-config": true }
+
+var cli = { foo: "bar", heading: "foo", "git-tag-version": false }
+
+var projectData = {
+ "save-prefix": "~",
+ "proprietary-attribs": false
+}
+
+var expectList = [
+ cli,
+ envDataFix,
+ projectData,
+ ucData,
+ gcData,
+ biData
+]
+
+var expectSources = {
+ cli: { data: cli },
+ env: {
+ data: envDataFix,
+ source: envData,
+ prefix: ""
+ },
+ project: {
+ path: path.resolve(__dirname, "..", "..", ".npmrc"),
+ type: "ini",
+ data: projectData
+ },
+ user: {
+ path: common.userconfig,
+ type: "ini",
+ data: ucData
+ },
+ global: {
+ path: common.globalconfig,
+ type: "ini",
+ data: gcData
+ },
+ builtin: { data: biData }
+}
+
+test("with builtin", function (t) {
+ npmconf.load(cli, common.builtin, function (er, conf) {
+ if (er) throw er
+ t.same(conf.list, expectList)
+ t.same(conf.sources, expectSources)
+ t.same(npmconf.rootConf.list, [])
+ t.equal(npmconf.rootConf.root, npmconf.defs.defaults)
+ t.equal(conf.root, npmconf.defs.defaults)
+ t.equal(conf.get("heading"), "foo")
+ t.equal(conf.get("git-tag-version"), false)
+ t.end()
+ })
+})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/config-certfile.js nodejs-0.11.15/deps/npm/test/tap/config-certfile.js
--- nodejs-0.11.14/deps/npm/test/tap/config-certfile.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/config-certfile.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,18 @@
+require("./00-config-setup.js")
+
+var path = require("path")
+var fs = require("fs")
+var test = require("tap").test
+var npmconf = require("../../lib/config/core.js")
+
+test("cafile loads as ca", function (t) {
+ var cafile = path.join(__dirname, "..", "fixtures", "config", "multi-ca")
+
+ npmconf.load({cafile: cafile}, function (er, conf) {
+ if (er) throw er
+
+ t.same(conf.get("cafile"), cafile)
+ t.same(conf.get("ca").join("\n"), fs.readFileSync(cafile, "utf8").trim())
+ t.end()
+ })
+})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/config-credentials.js nodejs-0.11.15/deps/npm/test/tap/config-credentials.js
--- nodejs-0.11.14/deps/npm/test/tap/config-credentials.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/config-credentials.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,295 @@
+var test = require("tap").test
+
+var npmconf = require("../../lib/config/core.js")
+var common = require("./00-config-setup.js")
+
+var URI = "https://registry.lvh.me:8661/"
+
+test("getting scope with no credentials set", function (t) {
+ npmconf.load({}, function (er, conf) {
+ t.ifError(er, "configuration loaded")
+
+ var basic = conf.getCredentialsByURI(URI)
+ t.equal(basic.scope, "//registry.lvh.me:8661/", "nerfed URL extracted")
+
+ t.end()
+ })
+})
+
+test("trying to set credentials with no URI", function (t) {
+ npmconf.load(common.builtin, function (er, conf) {
+ t.ifError(er, "configuration loaded")
+
+ t.throws(function () {
+ conf.setCredentialsByURI()
+ }, "enforced missing URI")
+
+ t.end()
+ })
+})
+
+test("set with missing credentials object", function (t) {
+ npmconf.load(common.builtin, function (er, conf) {
+ t.ifError(er, "configuration loaded")
+
+ t.throws(function () {
+ conf.setCredentialsByURI(URI)
+ }, "enforced missing credentials")
+
+ t.end()
+ })
+})
+
+test("set with empty credentials object", function (t) {
+ npmconf.load(common.builtin, function (er, conf) {
+ t.ifError(er, "configuration loaded")
+
+ t.throws(function () {
+ conf.setCredentialsByURI(URI, {})
+ }, "enforced missing credentials")
+
+ t.end()
+ })
+})
+
+test("set with token", function (t) {
+ npmconf.load(common.builtin, function (er, conf) {
+ t.ifError(er, "configuration loaded")
+
+ t.doesNotThrow(function () {
+ conf.setCredentialsByURI(URI, {token : "simple-token"})
+ }, "needs only token")
+
+ var expected = {
+ scope : "//registry.lvh.me:8661/",
+ token : "simple-token",
+ username : undefined,
+ password : undefined,
+ email : undefined,
+ auth : undefined,
+ alwaysAuth : undefined
+ }
+
+ t.same(conf.getCredentialsByURI(URI), expected, "got bearer token and scope")
+
+ t.end()
+ })
+})
+
+test("set with missing username", function (t) {
+ npmconf.load(common.builtin, function (er, conf) {
+ t.ifError(er, "configuration loaded")
+
+ var credentials = {
+ password : "password",
+ email : "ogd@aoaioxxysz.net"
+ }
+
+ t.throws(function () {
+ conf.setCredentialsByURI(URI, credentials)
+ }, "enforced missing email")
+
+ t.end()
+ })
+})
+
+test("set with missing password", function (t) {
+ npmconf.load(common.builtin, function (er, conf) {
+ t.ifError(er, "configuration loaded")
+
+ var credentials = {
+ username : "username",
+ email : "ogd@aoaioxxysz.net"
+ }
+
+ t.throws(function () {
+ conf.setCredentialsByURI(URI, credentials)
+ }, "enforced missing email")
+
+ t.end()
+ })
+})
+
+test("set with missing email", function (t) {
+ npmconf.load(common.builtin, function (er, conf) {
+ t.ifError(er, "configuration loaded")
+
+ var credentials = {
+ username : "username",
+ password : "password"
+ }
+
+ t.throws(function () {
+ conf.setCredentialsByURI(URI, credentials)
+ }, "enforced missing email")
+
+ t.end()
+ })
+})
+
+test("set with old-style credentials", function (t) {
+ npmconf.load(common.builtin, function (er, conf) {
+ t.ifError(er, "configuration loaded")
+
+ var credentials = {
+ username : "username",
+ password : "password",
+ email : "ogd@aoaioxxysz.net"
+ }
+
+ t.doesNotThrow(function () {
+ conf.setCredentialsByURI(URI, credentials)
+ }, "requires all of username, password, and email")
+
+ var expected = {
+ scope : "//registry.lvh.me:8661/",
+ token : undefined,
+ username : "username",
+ password : "password",
+ email : "ogd@aoaioxxysz.net",
+ auth : "dXNlcm5hbWU6cGFzc3dvcmQ=",
+ alwaysAuth : false
+ }
+
+ t.same(conf.getCredentialsByURI(URI), expected, "got credentials")
+
+ t.end()
+ })
+})
+
+test("get old-style credentials for default registry", function (t) {
+ npmconf.load(common.builtin, function (er, conf) {
+ var actual = conf.getCredentialsByURI(conf.get("registry"))
+ var expected = {
+ scope : "//registry.npmjs.org/",
+ token : undefined,
+ password : "password",
+ username : "username",
+ email : "i@izs.me",
+ auth : "dXNlcm5hbWU6cGFzc3dvcmQ=",
+ alwaysAuth : false
+ }
+ t.same(actual, expected)
+ t.end()
+ })
+})
+
+test("set with always-auth enabled", function (t) {
+ npmconf.load(common.builtin, function (er, conf) {
+ t.ifError(er, "configuration loaded")
+
+ var credentials = {
+ username : "username",
+ password : "password",
+ email : "ogd@aoaioxxysz.net",
+ alwaysAuth : true
+ }
+
+ conf.setCredentialsByURI(URI, credentials)
+
+ var expected = {
+ scope : "//registry.lvh.me:8661/",
+ token : undefined,
+ username : "username",
+ password : "password",
+ email : "ogd@aoaioxxysz.net",
+ auth : "dXNlcm5hbWU6cGFzc3dvcmQ=",
+ alwaysAuth : true
+ }
+
+ t.same(conf.getCredentialsByURI(URI), expected, "got credentials")
+
+ t.end()
+ })
+})
+
+test("set with always-auth disabled", function (t) {
+ npmconf.load(common.builtin, function (er, conf) {
+ t.ifError(er, "configuration loaded")
+
+ var credentials = {
+ username : "username",
+ password : "password",
+ email : "ogd@aoaioxxysz.net",
+ alwaysAuth : false
+ }
+
+ conf.setCredentialsByURI(URI, credentials)
+
+ var expected = {
+ scope : "//registry.lvh.me:8661/",
+ token : undefined,
+ username : "username",
+ password : "password",
+ email : "ogd@aoaioxxysz.net",
+ auth : "dXNlcm5hbWU6cGFzc3dvcmQ=",
+ alwaysAuth : false
+ }
+
+ t.same(conf.getCredentialsByURI(URI), expected, "got credentials")
+
+ t.end()
+ })
+})
+
+test("set with global always-auth enabled", function (t) {
+ npmconf.load(common.builtin, function (er, conf) {
+ t.ifError(er, "configuration loaded")
+ var original = conf.get("always-auth")
+ conf.set("always-auth", true)
+
+ var credentials = {
+ username : "username",
+ password : "password",
+ email : "ogd@aoaioxxysz.net"
+ }
+
+ conf.setCredentialsByURI(URI, credentials)
+
+ var expected = {
+ scope : "//registry.lvh.me:8661/",
+ token : undefined,
+ username : "username",
+ password : "password",
+ email : "ogd@aoaioxxysz.net",
+ auth : "dXNlcm5hbWU6cGFzc3dvcmQ=",
+ alwaysAuth : true
+ }
+
+ t.same(conf.getCredentialsByURI(URI), expected, "got credentials")
+
+ conf.set("always-auth", original)
+ t.end()
+ })
+})
+
+test("set with global always-auth disabled", function (t) {
+ npmconf.load(common.builtin, function (er, conf) {
+ t.ifError(er, "configuration loaded")
+ var original = conf.get("always-auth")
+ conf.set("always-auth", false)
+
+ var credentials = {
+ username : "username",
+ password : "password",
+ email : "ogd@aoaioxxysz.net"
+ }
+
+ conf.setCredentialsByURI(URI, credentials)
+
+ var expected = {
+ scope : "//registry.lvh.me:8661/",
+ token : undefined,
+ username : "username",
+ password : "password",
+ email : "ogd@aoaioxxysz.net",
+ auth : "dXNlcm5hbWU6cGFzc3dvcmQ=",
+ alwaysAuth : false
+ }
+
+ t.same(conf.getCredentialsByURI(URI), expected, "got credentials")
+
+ conf.set("always-auth", original)
+ t.end()
+ })
+})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/config-malformed.js nodejs-0.11.15/deps/npm/test/tap/config-malformed.js
--- nodejs-0.11.14/deps/npm/test/tap/config-malformed.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/config-malformed.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,14 @@
+var test = require('tap').test
+
+var npmconf = require("../../lib/config/core.js")
+var common = require("./00-config-setup.js")
+
+test('with malformed', function (t) {
+ npmconf.load({}, common.malformed, function (er, conf) {
+ t.ok(er, 'Expected parse error')
+ if (!(er && /Failed parsing JSON config key email/.test(er.message))) {
+ throw er
+ }
+ t.end()
+ })
+})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/config-meta.js nodejs-0.11.15/deps/npm/test/tap/config-meta.js
--- nodejs-0.11.14/deps/npm/test/tap/config-meta.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/config-meta.js 2015-01-20 21:22:17.000000000 +0000
@@ -51,16 +51,16 @@
test("get lines", function (t) {
FILES.forEach(function (f) {
- var lines = fs.readFileSync(f, 'utf8').split(/\r|\n/)
+ var lines = fs.readFileSync(f, "utf8").split(/\r|\n/)
lines.forEach(function (l, i) {
var matches = l.split(/conf(?:ig)?\.get\(/g)
matches.shift()
matches.forEach(function (m) {
- m = m.split(')').shift()
+ m = m.split(")").shift()
var literal = m.match(/^['"].+['"]$/)
if (literal) {
m = m.slice(1, -1)
- if (!m.match(/^\_/) && m !== 'argv')
+ if (!m.match(/^\_/) && m !== "argv")
CONFS[m] = {
file: f,
line: i
@@ -81,48 +81,46 @@
for (var i = 0; i < d.length && d[i] !== "## Config Settings"; i++);
i++
// now gather up all the ^###\s lines until the next ^##\s
- var doclines = []
for (; i < d.length && !d[i].match(/^## /); i++) {
if (d[i].match(/^### /))
- DOC[ d[i].replace(/^### /, '').trim() ] = true
+ DOC[ d[i].replace(/^### /, "").trim() ] = true
}
t.pass("read the docs")
t.end()
})
test("check configs", function (t) {
- var defs = require("npmconf/config-defs.js")
+ var defs = require("../../lib/config/defaults.js")
var types = Object.keys(defs.types)
var defaults = Object.keys(defs.defaults)
-
- for (var c in CONFS) {
- if (CONFS[c].file.indexOf(lib) === 0) {
- t.ok(DOC[c], "should be documented " + c + " "
- + CONFS[c].file + ":" + CONFS[c].line)
- t.ok(types.indexOf(c) !== -1, "should be defined in npmconf " + c)
- t.ok(defaults.indexOf(c) !== -1, "should have default in npmconf " + c)
+ for (var c1 in CONFS) {
+ if (CONFS[c1].file.indexOf(lib) === 0) {
+ t.ok(DOC[c1], "should be documented " + c1 + " "
+ + CONFS[c1].file + ":" + CONFS[c1].line)
+ t.ok(types.indexOf(c1) !== -1, "should be defined in npmconf " + c1)
+ t.ok(defaults.indexOf(c1) !== -1, "should have default in npmconf " + c1)
}
}
- for (var c in DOC) {
- if (c !== "versions" && c !== "version" && c !== "init.version") {
- t.ok(CONFS[c], "config in doc should be used somewhere " + c)
- t.ok(types.indexOf(c) !== -1, "should be defined in npmconf " + c)
- t.ok(defaults.indexOf(c) !== -1, "should have default in npmconf " + c)
+ for (var c2 in DOC) {
+ if (c2 !== "versions" && c2 !== "version" && c2 !== "init.version") {
+ t.ok(CONFS[c2], "config in doc should be used somewhere " + c2)
+ t.ok(types.indexOf(c2) !== -1, "should be defined in npmconf " + c2)
+ t.ok(defaults.indexOf(c2) !== -1, "should have default in npmconf " + c2)
}
}
- types.forEach(function(c) {
- if (!c.match(/^\_/) && c !== 'argv' && !c.match(/^versions?$/)) {
- t.ok(DOC[c], 'defined type should be documented ' + c)
- t.ok(CONFS[c], 'defined type should be used ' + c)
+ types.forEach(function (c) {
+ if (!c.match(/^\_/) && c !== "argv" && !c.match(/^versions?$/)) {
+ t.ok(DOC[c], "defined type should be documented " + c)
+ t.ok(CONFS[c], "defined type should be used " + c)
}
})
- defaults.forEach(function(c) {
- if (!c.match(/^\_/) && c !== 'argv' && !c.match(/^versions?$/)) {
- t.ok(DOC[c], 'defaulted type should be documented ' + c)
- t.ok(CONFS[c], 'defaulted type should be used ' + c)
+ defaults.forEach(function (c) {
+ if (!c.match(/^\_/) && c !== "argv" && !c.match(/^versions?$/)) {
+ t.ok(DOC[c], "defaulted type should be documented " + c)
+ t.ok(CONFS[c], "defaulted type should be used " + c)
}
})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/config-project.js nodejs-0.11.15/deps/npm/test/tap/config-project.js
--- nodejs-0.11.14/deps/npm/test/tap/config-project.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/config-project.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,66 @@
+var test = require("tap").test
+var path = require("path")
+var fix = path.resolve(__dirname, "..", "fixtures", "config")
+var projectRc = path.resolve(fix, ".npmrc")
+var npmconf = require("../../lib/config/core.js")
+var common = require("./00-config-setup.js")
+
+var projectData = { just: "testing" }
+
+var ucData = common.ucData
+var envData = common.envData
+var envDataFix = common.envDataFix
+
+var gcData = { "package-config:foo": "boo" }
+
+var biData = {}
+
+var cli = { foo: "bar", umask: 022, prefix: fix }
+
+var expectList = [
+ cli,
+ envDataFix,
+ projectData,
+ ucData,
+ gcData,
+ biData
+]
+
+var expectSources = {
+ cli: { data: cli },
+ env: {
+ data: envDataFix,
+ source: envData,
+ prefix: ""
+ },
+ project: {
+ path: projectRc,
+ type: "ini",
+ data: projectData
+ },
+ user: {
+ path: common.userconfig,
+ type: "ini",
+ data: ucData
+ },
+ global: {
+ path: common.globalconfig,
+ type: "ini",
+ data: gcData
+ },
+ builtin: { data: biData }
+}
+
+test("no builtin", function (t) {
+ npmconf.load(cli, function (er, conf) {
+ if (er) throw er
+ t.same(conf.list, expectList)
+ t.same(conf.sources, expectSources)
+ t.same(npmconf.rootConf.list, [])
+ t.equal(npmconf.rootConf.root, npmconf.defs.defaults)
+ t.equal(conf.root, npmconf.defs.defaults)
+ t.equal(conf.get("umask"), 022)
+ t.equal(conf.get("heading"), "npm")
+ t.end()
+ })
+})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/config-save.js nodejs-0.11.15/deps/npm/test/tap/config-save.js
--- nodejs-0.11.14/deps/npm/test/tap/config-save.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/config-save.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,88 @@
+var fs = require("fs")
+var ini = require("ini")
+var test = require("tap").test
+var npmconf = require("../../lib/config/core.js")
+var common = require("./00-config-setup.js")
+
+var expectConf = [
+ "globalconfig = " + common.globalconfig,
+ "email = i@izs.me",
+ "env-thing = asdf",
+ "init.author.name = Isaac Z. Schlueter",
+ "init.author.email = i@izs.me",
+ "init.author.url = http://blog.izs.me/",
+ "init.version = 1.2.3",
+ "proprietary-attribs = false",
+ "npm:publishtest = true",
+ "_npmjs.org:couch = https://admin:password@localhost:5984/registry",
+ "npm-www:nocache = 1",
+ "sign-git-tag = false",
+ "message = v%s",
+ "strict-ssl = false",
+ "_auth = dXNlcm5hbWU6cGFzc3dvcmQ=",
+ "",
+ "[_token]",
+ "AuthSession = yabba-dabba-doodle",
+ "version = 1",
+ "expires = 1345001053415",
+ "path = /",
+ "httponly = true",
+ ""
+].join("\n")
+
+var expectFile = [
+ "globalconfig = " + common.globalconfig,
+ "email = i@izs.me",
+ "env-thing = asdf",
+ "init.author.name = Isaac Z. Schlueter",
+ "init.author.email = i@izs.me",
+ "init.author.url = http://blog.izs.me/",
+ "init.version = 1.2.3",
+ "proprietary-attribs = false",
+ "npm:publishtest = true",
+ "_npmjs.org:couch = https://admin:password@localhost:5984/registry",
+ "npm-www:nocache = 1",
+ "sign-git-tag = false",
+ "message = v%s",
+ "strict-ssl = false",
+ "_auth = dXNlcm5hbWU6cGFzc3dvcmQ=",
+ "",
+ "[_token]",
+ "AuthSession = yabba-dabba-doodle",
+ "version = 1",
+ "expires = 1345001053415",
+ "path = /",
+ "httponly = true",
+ ""
+].join("\n")
+
+test("saving configs", function (t) {
+ npmconf.load(function (er, conf) {
+ if (er)
+ throw er
+ conf.set("sign-git-tag", false, "user")
+ conf.del("nodedir")
+ conf.del("tmp")
+ var foundConf = ini.stringify(conf.sources.user.data)
+ t.same(ini.parse(foundConf), ini.parse(expectConf))
+ fs.unlinkSync(common.userconfig)
+ conf.save("user", function (er) {
+ if (er)
+ throw er
+ var uc = fs.readFileSync(conf.get("userconfig"), "utf8")
+ t.same(ini.parse(uc), ini.parse(expectFile))
+ t.end()
+ })
+ })
+})
+
+test("setting prefix", function (t) {
+ npmconf.load(function (er, conf) {
+ if (er)
+ throw er
+
+ conf.prefix = "newvalue"
+ t.same(conf.prefix, "newvalue")
+ t.end()
+ })
+})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/config-semver-tag.js nodejs-0.11.15/deps/npm/test/tap/config-semver-tag.js
--- nodejs-0.11.14/deps/npm/test/tap/config-semver-tag.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/config-semver-tag.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,27 @@
+var util = require("util")
+var test = require("tap").test
+var npmconf = require("../../lib/config/core.js")
+var common = require("./00-config-setup.js")
+
+var cli = { tag: "v2.x" }
+
+var log = require("npmlog")
+
+test("tag cannot be a SemVer", function (t) {
+ var messages = []
+ log.warn = function (m) {
+ messages.push(m + " " + util.format.apply(util, [].slice.call(arguments, 1)))
+ }
+
+ var expect = [
+ 'invalid config tag="v2.x"',
+ "invalid config Tag must not be a SemVer range"
+ ]
+
+ npmconf.load(cli, common.builtin, function (er, conf) {
+ if (er) throw er
+ t.equal(conf.get("tag"), "latest")
+ t.same(messages, expect)
+ t.end()
+ })
+})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/dedupe.js nodejs-0.11.15/deps/npm/test/tap/dedupe.js
--- nodejs-0.11.14/deps/npm/test/tap/dedupe.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/dedupe.js 2015-01-20 21:22:17.000000000 +0000
@@ -2,17 +2,26 @@
, fs = require("fs")
, path = require("path")
, existsSync = fs.existsSync || path.existsSync
- , npm = require("../../")
, rimraf = require("rimraf")
, mr = require("npm-registry-mock")
- , common = require('../common-tap.js')
+ , common = require("../common-tap.js")
+
+var EXEC_OPTS = {}
test("dedupe finds the common module and moves it up one level", function (t) {
setup(function (s) {
- npm.install(".", function (err) {
- if (err) return t.fail(err)
- npm.dedupe(function(err) {
- if (err) return t.fail(err)
+ common.npm(
+ [
+ "install", ".",
+ "--registry", common.registry
+ ],
+ EXEC_OPTS,
+ function (err, code) {
+ t.ifError(err, "successfully installed directory")
+ t.equal(code, 0, "npm install exited with code")
+ common.npm(["dedupe"], {}, function (err, code) {
+ t.ifError(err, "successfully deduped against previous install")
+ t.notOk(code, "npm dedupe exited with code")
t.ok(existsSync(path.join(__dirname, "dedupe", "node_modules", "minimist")))
t.ok(!existsSync(path.join(__dirname, "dedupe", "node_modules", "checker")))
s.close() // shutdown mock registry.
@@ -25,10 +34,8 @@
function setup (cb) {
process.chdir(path.join(__dirname, "dedupe"))
mr(common.port, function (s) { // create mock registry.
- npm.load({registry: common.registry}, function() {
- rimraf.sync(path.join(__dirname, "dedupe", "node_modules"))
- fs.mkdirSync(path.join(__dirname, "dedupe", "node_modules"))
- cb(s)
- })
+ rimraf.sync(path.join(__dirname, "dedupe", "node_modules"))
+ fs.mkdirSync(path.join(__dirname, "dedupe", "node_modules"))
+ cb(s)
})
}
diff -Nru nodejs-0.11.14/deps/npm/test/tap/dev-dep-duplicate/desired-ls-results.json nodejs-0.11.15/deps/npm/test/tap/dev-dep-duplicate/desired-ls-results.json
--- nodejs-0.11.14/deps/npm/test/tap/dev-dep-duplicate/desired-ls-results.json 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/dev-dep-duplicate/desired-ls-results.json 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,9 @@
+{
+ "name": "dev-dep-duplicate",
+ "version": "0.0.0",
+ "dependencies": {
+ "underscore": {
+ "version": "1.5.1"
+ }
+ }
+}
diff -Nru nodejs-0.11.14/deps/npm/test/tap/dev-dep-duplicate/package.json nodejs-0.11.15/deps/npm/test/tap/dev-dep-duplicate/package.json
--- nodejs-0.11.14/deps/npm/test/tap/dev-dep-duplicate/package.json 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/dev-dep-duplicate/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,11 @@
+{
+ "author": "Anders Janmyr",
+ "name": "dev-dep-duplicate",
+ "version": "0.0.0",
+ "dependencies": {
+ "underscore": "1.5.1"
+ },
+ "devDependencies": {
+ "underscore": "1.3.1"
+ }
+}
diff -Nru nodejs-0.11.14/deps/npm/test/tap/false_name.js nodejs-0.11.15/deps/npm/test/tap/false_name.js
--- nodejs-0.11.14/deps/npm/test/tap/false_name.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/false_name.js 2015-01-20 21:22:17.000000000 +0000
@@ -11,41 +11,45 @@
, fs = require("fs")
, path = require("path")
, existsSync = fs.existsSync || path.existsSync
- , spawn = require("child_process").spawn
- , npm = require("../../")
, rimraf = require("rimraf")
, common = require("../common-tap.js")
, mr = require("npm-registry-mock")
- , pkg = __dirname + "/false_name"
+ , pkg = path.resolve(__dirname, "false_name")
+ , cache = path.resolve(pkg, "cache")
+ , nodeModules = path.resolve(pkg, "node_modules")
-test("not every pkg.name can be required", function (t) {
- rimraf.sync(pkg + "/cache")
+var EXEC_OPTS = { cwd: pkg }
- t.plan(1)
+test("setup", function(t) {
+ cleanup()
+ fs.mkdirSync(nodeModules)
+ t.end()
+})
+
+test("not every pkg.name can be required", function (t) {
+ t.plan(3)
mr(common.port, function (s) {
- setup(function () {
- npm.install(".", function (err) {
- if (err) return t.fail(err)
- s.close()
- t.ok(existsSync(pkg + "/node_modules/test-package-with-one-dep/" +
- "node_modules/test-package"))
- })
+ common.npm([
+ "install", ".",
+ "--cache", cache,
+ "--registry", common.registry
+ ], EXEC_OPTS, function (err, code) {
+ s.close()
+ t.ifErr(err, "install finished without error")
+ t.equal(code, 0, "install exited ok")
+ t.ok(existsSync(path.resolve(pkg,
+ "node_modules/test-package-with-one-dep",
+ "node_modules/test-package")))
})
})
})
+function cleanup() {
+ rimraf.sync(cache)
+ rimraf.sync(nodeModules)
+}
+
test("cleanup", function (t) {
- rimraf.sync(pkg + "/cache")
- rimraf.sync(pkg + "/node_modules")
+ cleanup()
t.end()
})
-
-function setup (cb) {
- process.chdir(pkg)
- npm.load({cache: pkg + "/cache", registry: common.registry},
- function () {
- rimraf.sync(pkg + "/node_modules")
- fs.mkdirSync(pkg + "/node_modules")
- cb()
- })
-}
diff -Nru nodejs-0.11.14/deps/npm/test/tap/git-cache-locking.js nodejs-0.11.15/deps/npm/test/tap/git-cache-locking.js
--- nodejs-0.11.14/deps/npm/test/tap/git-cache-locking.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/git-cache-locking.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,10 +1,8 @@
var test = require("tap").test
+ , common = require("../common-tap")
, path = require("path")
, rimraf = require("rimraf")
, mkdirp = require("mkdirp")
- , spawn = require("child_process").spawn
- , npm = require.resolve("../../bin/npm-cli.js")
- , node = process.execPath
, pkg = path.resolve(__dirname, "git-cache-locking")
, tmp = path.join(pkg, "tmp")
, cache = path.join(pkg, "cache")
@@ -12,10 +10,7 @@
test("setup", function (t) {
rimraf.sync(pkg)
- mkdirp.sync(pkg)
- mkdirp.sync(cache)
- mkdirp.sync(tmp)
- mkdirp.sync(path.resolve(pkg, 'node_modules'))
+ mkdirp.sync(path.resolve(pkg, "node_modules"))
t.end()
})
@@ -26,27 +21,28 @@
// package c depends on a.git#master and b.git#master
// package b depends on a.git#master
- var child = spawn(node, [npm, "install", "git://github.com/nigelzor/npm-4503-c.git"], {
+ common.npm([
+ "install",
+ "git://github.com/nigelzor/npm-4503-c.git"
+ ], {
cwd: pkg,
env: {
- npm_config_cache: cache,
- npm_config_tmp: tmp,
- npm_config_prefix: pkg,
- npm_config_global: "false",
+ "npm_config_cache": cache,
+ "npm_config_tmp": tmp,
+ "npm_config_prefix": pkg,
+ "npm_config_global": "false",
HOME: process.env.HOME,
Path: process.env.PATH,
PATH: process.env.PATH
- },
- stdio: "inherit"
- })
-
- child.on("close", function (code) {
+ }
+ }, function (err, code) {
+ t.ifErr(err, "npm install finished without error")
t.equal(0, code, "npm install should succeed")
t.end()
})
})
-test('cleanup', function(t) {
+test("cleanup", function(t) {
rimraf.sync(pkg)
t.end()
})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/git-cache-no-hooks.js nodejs-0.11.15/deps/npm/test/tap/git-cache-no-hooks.js
--- nodejs-0.11.14/deps/npm/test/tap/git-cache-no-hooks.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/git-cache-no-hooks.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,63 @@
+var test = require("tap").test
+ , fs = require("fs")
+ , path = require("path")
+ , rimraf = require("rimraf")
+ , mkdirp = require("mkdirp")
+ , spawn = require("child_process").spawn
+ , npmCli = require.resolve("../../bin/npm-cli.js")
+ , node = process.execPath
+ , pkg = path.resolve(__dirname, "git-cache-no-hooks")
+ , tmp = path.join(pkg, "tmp")
+ , cache = path.join(pkg, "cache")
+
+
+test("setup", function (t) {
+ rimraf.sync(pkg)
+ mkdirp.sync(pkg)
+ mkdirp.sync(cache)
+ mkdirp.sync(tmp)
+ mkdirp.sync(path.resolve(pkg, "node_modules"))
+ t.end()
+})
+
+test("git-cache-no-hooks: install a git dependency", function (t) {
+
+ // disable git integration tests on Travis.
+ if (process.env.TRAVIS) return t.end()
+
+ var command = [ npmCli
+ , "install"
+ , "git://github.com/nigelzor/npm-4503-a.git"
+ ]
+ var child = spawn(node, command, {
+ cwd: pkg,
+ env: {
+ "npm_config_cache" : cache,
+ "npm_config_tmp" : tmp,
+ "npm_config_prefix" : pkg,
+ "npm_config_global" : "false",
+ "npm_config_umask" : "00",
+ HOME : process.env.HOME,
+ Path : process.env.PATH,
+ PATH : process.env.PATH
+ },
+ stdio: "inherit"
+ })
+
+ child.on("close", function (code) {
+ t.equal(code, 0, "npm install should succeed")
+
+ // verify permissions on git hooks
+ var repoDir = "git-github-com-nigelzor-npm-4503-a-git-40c5cb24"
+ var hooksPath = path.join(cache, "_git-remotes", repoDir, "hooks")
+ fs.readdir(hooksPath, function (err) {
+ t.equal(err && err.code, "ENOENT", "hooks are not brought along with repo")
+ t.end()
+ })
+ })
+})
+
+test("cleanup", function (t) {
+ rimraf.sync(pkg)
+ t.end()
+})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/git-cache-permissions.js nodejs-0.11.15/deps/npm/test/tap/git-cache-permissions.js
--- nodejs-0.11.14/deps/npm/test/tap/git-cache-permissions.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/git-cache-permissions.js 1970-01-01 00:00:00.000000000 +0000
@@ -1,80 +0,0 @@
-var test = require("tap").test
- , fs = require("fs")
- , path = require("path")
- , rimraf = require("rimraf")
- , mkdirp = require("mkdirp")
- , spawn = require("child_process").spawn
- , npm = require("../../lib/npm")
- , npmCli = require.resolve("../../bin/npm-cli.js")
- , node = process.execPath
- , pkg = path.resolve(__dirname, "git-cache-permissions")
- , tmp = path.join(pkg, "tmp")
- , cache = path.join(pkg, "cache")
-
-
-test("setup", function (t) {
- rimraf.sync(pkg)
- mkdirp.sync(pkg)
- mkdirp.sync(cache)
- mkdirp.sync(tmp)
- mkdirp.sync(path.resolve(pkg, 'node_modules'))
- t.end()
-})
-
-test("git-cache-permissions: install a git dependency", function (t) {
-
- // disable git integration tests on Travis.
- if (process.env.TRAVIS) return t.end()
-
- var command = [ npmCli
- , "install"
- , "git://github.com/nigelzor/npm-4503-a.git"
- ]
- var child = spawn(node, command, {
- cwd: pkg,
- env: {
- npm_config_cache: cache,
- npm_config_tmp: tmp,
- npm_config_prefix: pkg,
- npm_config_global: "false",
- npm_config_umask: "00",
- HOME: process.env.HOME,
- Path: process.env.PATH,
- PATH: process.env.PATH
- },
- stdio: "inherit"
- })
-
- child.on("close", function (code) {
- t.equal(code, 0, "npm install should succeed")
-
- // verify permissions on git hooks
- var repoDir = "git-github-com-nigelzor-npm-4503-a-git-40c5cb24"
- var hooksPath = path.join(cache, "_git-remotes", repoDir, "hooks")
- fs.readdir(hooksPath, function (err, files) {
- if (err) {
- t.ok(false, "error reading hooks: " + err)
- t.end()
- }
-
- files.forEach(function (file) {
- var stats = fs.statSync(path.join(hooksPath, file))
- var message = "hook [" + file + "] should have correct permissions"
-
- // Possible error conditions and the resulting file modes on hooks
- // npm.modes.file is used directly -> "100666"
- // permissions are left untouched -> "100755"
- // we do not want permissions left untouched because of
- // https://github.com/npm/npm/issues/3117
- t.equal(stats.mode.toString(8), "100777", message)
- })
-
- t.end()
- })
- })
-})
-
-test('cleanup', function(t) {
- rimraf.sync(pkg)
- t.end()
-})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/global-prefix-set-in-userconfig.js nodejs-0.11.15/deps/npm/test/tap/global-prefix-set-in-userconfig.js
--- nodejs-0.11.14/deps/npm/test/tap/global-prefix-set-in-userconfig.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/global-prefix-set-in-userconfig.js 2015-01-20 21:22:17.000000000 +0000
@@ -15,9 +15,9 @@
test("run command", function (t) {
var args = ["prefix", "-g", "--userconfig=" + rcfile]
- common.npm(args, {env: {}}, function (er, code, so, se) {
+ common.npm(args, {env: {}}, function (er, code, so) {
if (er) throw er
- t.equal(code, 0)
+ t.notOk(code, "npm prefix exited with code 0")
t.equal(so.trim(), prefix)
t.end()
})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/ignore-install-link.js nodejs-0.11.15/deps/npm/test/tap/ignore-install-link.js
--- nodejs-0.11.14/deps/npm/test/tap/ignore-install-link.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/ignore-install-link.js 2015-01-20 21:22:17.000000000 +0000
@@ -52,7 +52,7 @@
stdio: "inherit"
}, function (er, code) {
if (er) throw er
- t.equal(code, 0)
+ t.equal(code, 0, "npm install exited with code")
t.end()
})
})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/ignore-scripts.js nodejs-0.11.15/deps/npm/test/tap/ignore-scripts.js
--- nodejs-0.11.14/deps/npm/test/tap/ignore-scripts.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/ignore-scripts.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,24 +1,24 @@
+var common = require("../common-tap")
var test = require("tap").test
-var npm = require.resolve("../../bin/npm-cli.js")
-
-var spawn = require("child_process").spawn
-var node = process.execPath
+var path = require("path")
// ignore-scripts/package.json has scripts that always exit with non-zero error
// codes. The "install" script is omitted so that npm tries to run node-gyp,
// which should also fail.
-var pkg = __dirname + "/ignore-scripts"
+var pkg = path.resolve(__dirname, "ignore-scripts")
-test("ignore-scripts: install using the option", function(t) {
- createChild([npm, "install", "--ignore-scripts"]).on("close", function(code) {
- t.equal(code, 0)
+test("ignore-scripts: install using the option", function (t) {
+ createChild(["install", "--ignore-scripts"], function (err, code) {
+ t.ifError(err, "install with scripts ignored finished successfully")
+ t.equal(code, 0, "npm install exited with code")
t.end()
})
})
-test("ignore-scripts: install NOT using the option", function(t) {
- createChild([npm, "install"]).on("close", function(code) {
- t.notEqual(code, 0)
+test("ignore-scripts: install NOT using the option", function (t) {
+ createChild(["install"], function (err, code) {
+ t.ifError(err, "install with scripts successful")
+ t.notEqual(code, 0, "npm install exited with code")
t.end()
})
})
@@ -34,39 +34,40 @@
"prerestart", "restart", "postrestart"
]
-scripts.forEach(function(script) {
- test("ignore-scripts: run-script "+script+" using the option", function(t) {
- createChild([npm, "--ignore-scripts", "run-script", script])
- .on("close", function(code) {
- t.equal(code, 0)
- t.end()
- })
+scripts.forEach(function (script) {
+ test("ignore-scripts: run-script "+script+" using the option", function (t) {
+ createChild(["--ignore-scripts", "run-script", script], function (err, code) {
+ t.ifError(err, "run-script " + script + " with ignore-scripts successful")
+ t.equal(code, 0, "npm run-script exited with code")
+ t.end()
+ })
})
})
-scripts.forEach(function(script) {
- test("ignore-scripts: run-script "+script+" NOT using the option", function(t) {
- createChild([npm, "run-script", script]).on("close", function(code) {
- t.notEqual(code, 0)
+scripts.forEach(function (script) {
+ test("ignore-scripts: run-script "+script+" NOT using the option", function (t) {
+ createChild(["run-script", script], function (err, code) {
+ t.ifError(err, "run-script " + script + " finished successfully")
+ t.notEqual(code, 0, "npm run-script exited with code")
t.end()
})
})
})
-function createChild (args) {
+function createChild (args, cb) {
var env = {
HOME: process.env.HOME,
Path: process.env.PATH,
PATH: process.env.PATH,
- npm_config_loglevel: "silent"
+ "npm_config_loglevel": "silent"
}
if (process.platform === "win32")
env.npm_config_cache = "%APPDATA%\\npm-cache"
- return spawn(node, args, {
+ return common.npm(args, {
cwd: pkg,
stdio: "inherit",
env: env
- })
+ }, cb)
}
diff -Nru nodejs-0.11.14/deps/npm/test/tap/ignore-shrinkwrap.js nodejs-0.11.15/deps/npm/test/tap/ignore-shrinkwrap.js
--- nodejs-0.11.14/deps/npm/test/tap/ignore-shrinkwrap.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/ignore-shrinkwrap.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,10 +1,9 @@
var common = require("../common-tap.js")
var test = require("tap").test
-var pkg = './ignore-shrinkwrap'
+var pkg = require("path").join(__dirname,"ignore-shrinkwrap")
var mr = require("npm-registry-mock")
-var child
var spawn = require("child_process").spawn
var npm = require.resolve("../../bin/npm-cli.js")
var node = process.execPath
@@ -18,7 +17,7 @@
test("ignore-shrinkwrap: using the option", function (t) {
mr({port: common.port, mocks: customMocks}, function (s) {
- s._server.on("request", function (req, res) {
+ s._server.on("request", function (req) {
switch (req.url) {
case "/shrinkwrap.js":
t.fail()
@@ -28,7 +27,7 @@
}
})
var child = createChild(true)
- child.on("close", function (m) {
+ child.on("close", function () {
s.close()
t.end()
})
@@ -37,7 +36,7 @@
test("ignore-shrinkwrap: NOT using the option", function (t) {
mr({port: common.port, mocks: customMocks}, function (s) {
- s._server.on("request", function (req, res) {
+ s._server.on("request", function (req) {
switch (req.url) {
case "/shrinkwrap.js":
t.pass("shrinkwrap used")
@@ -47,7 +46,7 @@
}
})
var child = createChild(false)
- child.on("close", function (m) {
+ child.on("close", function () {
s.close()
t.end()
})
@@ -65,13 +64,12 @@
return spawn(node, args, {
cwd: pkg,
env: {
- npm_config_registry: common.registry,
- npm_config_cache_lock_stale: 1000,
- npm_config_cache_lock_wait: 1000,
+ "npm_config_registry": common.registry,
+ "npm_config_cache_lock_stale": 1000,
+ "npm_config_cache_lock_wait": 1000,
HOME: process.env.HOME,
Path: process.env.PATH,
PATH: process.env.PATH
}
})
-
}
diff -Nru nodejs-0.11.14/deps/npm/test/tap/install-at-locally.js nodejs-0.11.15/deps/npm/test/tap/install-at-locally.js
--- nodejs-0.11.14/deps/npm/test/tap/install-at-locally.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/install-at-locally.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,42 +1,42 @@
-var common = require('../common-tap.js')
-var test = require('tap').test
-var npm = require('../../')
-var path = require('path')
-var fs = require('fs')
-var rimraf = require('rimraf')
-var mkdirp = require('mkdirp')
-var pkg = path.join(__dirname, 'install-at-locally')
+var common = require("../common-tap.js")
+var test = require("tap").test
+var path = require("path")
+var fs = require("fs")
+var rimraf = require("rimraf")
+var mkdirp = require("mkdirp")
+var pkg = path.join(__dirname, "install-at-locally")
+
+var EXEC_OPTS = { }
test("setup", function (t) {
mkdirp.sync(pkg)
- mkdirp.sync(path.resolve(pkg, 'node_modules'))
+ mkdirp.sync(path.resolve(pkg, "node_modules"))
process.chdir(pkg)
t.end()
})
-test('"npm install ./package@1.2.3" should install local pkg', function(t) {
- npm.load(function() {
- npm.commands.install(['./package@1.2.3'], function(err) {
- var p = path.resolve(pkg, 'node_modules/install-at-locally/package.json')
- t.ok(JSON.parse(fs.readFileSync(p, 'utf8')))
- t.end()
- })
+test("\"npm install ./package@1.2.3\" should install local pkg", function(t) {
+ common.npm(["install", "./package@1.2.3"], EXEC_OPTS, function(err, code) {
+ var p = path.resolve(pkg, "node_modules/install-at-locally/package.json")
+ t.ifError(err, "install local package successful")
+ t.equal(code, 0, "npm install exited with code")
+ t.ok(JSON.parse(fs.readFileSync(p, "utf8")))
+ t.end()
})
})
-test('"npm install install/at/locally@./package@1.2.3" should install local pkg', function(t) {
- npm.load(function() {
- npm.commands.install(['./package@1.2.3'], function(err) {
- var p = path.resolve(pkg, 'node_modules/install-at-locally/package.json')
- t.ok(JSON.parse(fs.readFileSync(p, 'utf8')))
- t.end()
- })
+test("\"npm install install/at/locally@./package@1.2.3\" should install local pkg", function(t) {
+ common.npm(["install", "./package@1.2.3"], EXEC_OPTS, function(err, code) {
+ var p = path.resolve(pkg, "node_modules/install-at-locally/package.json")
+ t.ifError(err, "install local package in explicit directory successful")
+ t.equal(code, 0, "npm install exited with code")
+ t.ok(JSON.parse(fs.readFileSync(p, "utf8")))
+ t.end()
})
})
-test('cleanup', function(t) {
+test("cleanup", function(t) {
process.chdir(__dirname)
- rimraf.sync(path.resolve(pkg, 'node_modules'))
+ rimraf.sync(path.resolve(pkg, "node_modules"))
t.end()
})
-
diff -Nru nodejs-0.11.14/deps/npm/test/tap/install-cli-production/dependency/package.json nodejs-0.11.15/deps/npm/test/tap/install-cli-production/dependency/package.json
--- nodejs-0.11.14/deps/npm/test/tap/install-cli-production/dependency/package.json 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/install-cli-production/dependency/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,5 @@
+{
+ "name": "dependency",
+ "description": "fixture",
+ "version": "0.0.0"
+}
diff -Nru nodejs-0.11.14/deps/npm/test/tap/install-cli-production/dev-dependency/package.json nodejs-0.11.15/deps/npm/test/tap/install-cli-production/dev-dependency/package.json
--- nodejs-0.11.14/deps/npm/test/tap/install-cli-production/dev-dependency/package.json 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/install-cli-production/dev-dependency/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,5 @@
+{
+ "name": "dev-dependency",
+ "description": "fixture",
+ "version": "0.0.0"
+}
diff -Nru nodejs-0.11.14/deps/npm/test/tap/install-cli-production/package.json nodejs-0.11.15/deps/npm/test/tap/install-cli-production/package.json
--- nodejs-0.11.14/deps/npm/test/tap/install-cli-production/package.json 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/install-cli-production/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,14 @@
+{
+ "name": "install-cli-production",
+ "description": "fixture",
+ "version": "0.0.0",
+ "scripts": {
+ "prepublish": "exit 123"
+ },
+ "dependencies": {
+ "dependency": "file:./dependency"
+ },
+ "devDependencies": {
+ "dev-dependency": "file:./dev-dependency"
+ }
+}
diff -Nru nodejs-0.11.14/deps/npm/test/tap/install-cli-production.js nodejs-0.11.15/deps/npm/test/tap/install-cli-production.js
--- nodejs-0.11.14/deps/npm/test/tap/install-cli-production.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/install-cli-production.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,44 @@
+var common = require("../common-tap.js")
+var test = require("tap").test
+var path = require("path")
+var fs = require("fs")
+var rimraf = require("rimraf")
+var mkdirp = require("mkdirp")
+var pkg = path.join(__dirname, "install-cli-production")
+
+var EXEC_OPTS = {
+ cwd: pkg
+}
+
+test("setup", function(t) {
+ mkdirp.sync(pkg)
+ mkdirp.sync(path.resolve(pkg, "node_modules"))
+ process.chdir(pkg)
+ t.end()
+})
+
+test("\"npm install --production\" should install dependencies", function(t) {
+ common.npm(["install", "--production"], EXEC_OPTS, function(err, code) {
+ t.ifError(err, "install production successful")
+ t.equal(code, 0, "npm install exited with code")
+ var p = path.resolve(pkg, "node_modules/dependency/package.json")
+ t.ok(JSON.parse(fs.readFileSync(p, "utf8")))
+ t.end()
+ })
+})
+
+test("\"npm install --production\" should not install dev dependencies", function(t) {
+ common.npm(["install", "--production"], EXEC_OPTS, function(err, code) {
+ t.ifError(err, "install production successful")
+ t.equal(code, 0, "npm install exited with code")
+ var p = path.resolve(pkg, "node_modules/dev-dependency/package.json")
+ t.ok(!fs.existsSync(p), "")
+ t.end()
+ })
+})
+
+test("cleanup", function(t) {
+ process.chdir(__dirname)
+ rimraf.sync(path.resolve(pkg, "node_modules"))
+ t.end()
+})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/install-cli-unicode.js nodejs-0.11.15/deps/npm/test/tap/install-cli-unicode.js
--- nodejs-0.11.14/deps/npm/test/tap/install-cli-unicode.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/install-cli-unicode.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,23 +1,24 @@
-var common = require('../common-tap.js')
-var test = require('tap').test
-var npm = require('../../')
-var mkdirp = require('mkdirp')
-var mr = require('npm-registry-mock')
-var exec = require('child_process').exec
+var common = require("../common-tap.js")
+var test = require("tap").test
+var mr = require("npm-registry-mock")
+var path = require("path")
-var pkg = __dirname + '/install-cli'
-var NPM_BIN = __dirname + '/../../bin/npm-cli.js'
+var pkg = path.resolve(__dirname, "install-cli")
function hasOnlyAscii (s) {
- return /^[\000-\177]*$/.test(s) ;
+ return /^[\000-\177]*$/.test(s)
}
-test('does not use unicode with --unicode false', function (t) {
- t.plan(3)
+var EXEC_OPTS = {
+ cwd : pkg
+}
+
+test("does not use unicode with --unicode false", function (t) {
+ t.plan(5)
mr(common.port, function (s) {
- exec('node ' + NPM_BIN + ' install --unicode false read', {
- cwd: pkg
- }, function(err, stdout) {
+ common.npm(["install", "--unicode", "false", "read"], EXEC_OPTS, function (err, code, stdout) {
+ t.ifError(err, "install package read without unicode success")
+ t.notOk(code, "npm install exited with code 0")
t.ifError(err)
t.ok(stdout, stdout.length)
t.ok(hasOnlyAscii(stdout))
@@ -26,11 +27,11 @@
})
})
-test('cleanup', function (t) {
+test("cleanup", function (t) {
mr(common.port, function (s) {
- exec('node ' + NPM_BIN + ' uninstall read', {
- cwd: pkg
- }, function(err, stdout) {
+ common.npm(["uninstall", "read"], EXEC_OPTS, function (err, code) {
+ t.ifError(err, "uninstall read package success")
+ t.notOk(code, "npm uninstall exited with code 0")
s.close()
})
})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/install-from-local/package-scoped-dependency/package.json nodejs-0.11.15/deps/npm/test/tap/install-from-local/package-scoped-dependency/package.json
--- nodejs-0.11.14/deps/npm/test/tap/install-from-local/package-scoped-dependency/package.json 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/install-from-local/package-scoped-dependency/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,5 @@
+{
+ "name": "@scoped/package",
+ "version": "0.0.0",
+ "description": "Test for local installs"
+}
diff -Nru nodejs-0.11.14/deps/npm/test/tap/install-from-local/package-with-scoped-paths/package.json nodejs-0.11.15/deps/npm/test/tap/install-from-local/package-with-scoped-paths/package.json
--- nodejs-0.11.14/deps/npm/test/tap/install-from-local/package-with-scoped-paths/package.json 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/install-from-local/package-with-scoped-paths/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,8 @@
+{
+ "name": "package-with-scoped-paths",
+ "version": "0.0.0",
+ "dependencies": {
+ "package-local-dependency": "file:../package-local-dependency",
+ "@scoped/package-scoped-dependency": "file:../package-scoped-dependency"
+ }
+}
diff -Nru nodejs-0.11.14/deps/npm/test/tap/install-from-local.js nodejs-0.11.15/deps/npm/test/tap/install-from-local.js
--- nodejs-0.11.14/deps/npm/test/tap/install-from-local.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/install-from-local.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,33 +1,34 @@
+var common = require("../common-tap")
var test = require("tap").test
-var npm = require("../../")
var path = require("path")
var fs = require("fs")
var rimraf = require("rimraf")
var pkg = path.join(__dirname, "install-from-local", "package-with-local-paths")
+var EXEC_OPTS = { }
+
test("setup", function (t) {
process.chdir(pkg)
t.end()
})
test('"npm install" should install local packages', function (t) {
- npm.load({loglevel : "silent"}, function () {
- npm.commands.install(["."], function (err) {
- t.ifError(err, "local packages installed")
- var dependencyPackageJson = path.resolve(pkg, "node_modules/package-local-dependency/package.json")
- t.ok(
- JSON.parse(fs.readFileSync(dependencyPackageJson, "utf8")),
- "package with local dependency installed"
- )
-
- var devDependencyPackageJson = path.resolve(pkg, "node_modules/package-local-dev-dependency/package.json")
- t.ok(
- JSON.parse(fs.readFileSync(devDependencyPackageJson, "utf8")),
- "package with local dev dependency installed"
- )
+ common.npm(["install", "."], EXEC_OPTS, function (err, code) {
+ t.ifError(err, "error should not exist")
+ t.notOk(code, "npm install exited with code 0")
+ var dependencyPackageJson = path.resolve(pkg, "node_modules/package-local-dependency/package.json")
+ t.ok(
+ JSON.parse(fs.readFileSync(dependencyPackageJson, "utf8")),
+ "package with local dependency installed"
+ )
+
+ var devDependencyPackageJson = path.resolve(pkg, "node_modules/package-local-dev-dependency/package.json")
+ t.ok(
+ JSON.parse(fs.readFileSync(devDependencyPackageJson, "utf8")),
+ "package with local dev dependency installed"
+ )
- t.end()
- })
+ t.end()
})
})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/install-save-exact.js nodejs-0.11.15/deps/npm/test/tap/install-save-exact.js
--- nodejs-0.11.14/deps/npm/test/tap/install-save-exact.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/install-save-exact.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,40 +1,41 @@
-var common = require('../common-tap.js')
-var test = require('tap').test
-var npm = require('../../')
-var path = require('path')
-var fs = require('fs')
-var rimraf = require('rimraf')
-var mkdirp = require('mkdirp')
-var pkg = path.join(__dirname, 'install-save-exact')
+var common = require("../common-tap.js")
+var test = require("tap").test
+var npm = require("../../")
+var path = require("path")
+var fs = require("fs")
+var rimraf = require("rimraf")
+var mkdirp = require("mkdirp")
+var pkg = path.join(__dirname, "install-save-exact")
var mr = require("npm-registry-mock")
test("setup", function (t) {
mkdirp.sync(pkg)
- mkdirp.sync(path.resolve(pkg, 'node_modules'))
+ mkdirp.sync(path.resolve(pkg, "node_modules"))
process.chdir(pkg)
t.end()
})
-test('"npm install --save --save-exact should install local pkg', function(t) {
+test("\"npm install --save --save-exact\" should install local pkg", function (t) {
resetPackageJSON(pkg)
mr(common.port, function (s) {
npm.load({
cache: pkg + "/cache",
- loglevel: 'silent',
- registry: common.registry }, function(err) {
+ loglevel: "silent",
+ registry: common.registry }, function (err) {
t.ifError(err)
- npm.config.set('save', true)
- npm.config.set('save-exact', true)
- npm.commands.install(['underscore@1.3.1'], function(err) {
+ npm.config.set("save", true)
+ npm.config.set("save-exact", true)
+ npm.commands.install(["underscore@1.3.1"], function (err) {
t.ifError(err)
- var p = path.resolve(pkg, 'node_modules/underscore/package.json')
+ var p = path.resolve(pkg, "node_modules/underscore/package.json")
t.ok(JSON.parse(fs.readFileSync(p)))
- var pkgJson = JSON.parse(fs.readFileSync(pkg + '/package.json', 'utf8'))
+ p = path.resolve(pkg, "package.json")
+ var pkgJson = JSON.parse(fs.readFileSync(p, "utf8"))
t.deepEqual(pkgJson.dependencies, {
- 'underscore': '1.3.1'
- }, 'Underscore dependency should specify exactly 1.3.1')
- npm.config.set('save', undefined)
- npm.config.set('save-exact', undefined)
+ "underscore": "1.3.1"
+ }, "Underscore dependency should specify exactly 1.3.1")
+ npm.config.set("save", undefined)
+ npm.config.set("save-exact", undefined)
s.close()
t.end()
})
@@ -42,50 +43,50 @@
})
})
-test('"npm install --save-dev --save-exact should install local pkg', function(t) {
+test("\"npm install --save-dev --save-exact\" should install local pkg", function (t) {
resetPackageJSON(pkg)
mr(common.port, function (s) {
npm.load({
cache: pkg + "/cache",
- loglevel: 'silent',
- registry: common.registry }, function(err) {
+ loglevel: "silent",
+ registry: common.registry }, function (err) {
t.ifError(err)
- npm.config.set('save-dev', true)
- npm.config.set('save-exact', true)
- npm.commands.install(['underscore@1.3.1'], function(err) {
+ npm.config.set("save-dev", true)
+ npm.config.set("save-exact", true)
+ npm.commands.install(["underscore@1.3.1"], function (err) {
t.ifError(err)
- var p = path.resolve(pkg, 'node_modules/underscore/package.json')
+ var p = path.resolve(pkg, "node_modules/underscore/package.json")
t.ok(JSON.parse(fs.readFileSync(p)))
- var pkgJson = JSON.parse(fs.readFileSync(pkg + '/package.json', 'utf8'))
+ p = path.resolve(pkg, "package.json")
+ var pkgJson = JSON.parse(fs.readFileSync(p, "utf8"))
console.log(pkgJson)
t.deepEqual(pkgJson.devDependencies, {
- 'underscore': '1.3.1'
- }, 'underscore devDependency should specify exactly 1.3.1')
+ "underscore": "1.3.1"
+ }, "underscore devDependency should specify exactly 1.3.1")
s.close()
- npm.config.set('save-dev', undefined)
- npm.config.set('save-exact', undefined)
+ npm.config.set("save-dev", undefined)
+ npm.config.set("save-exact", undefined)
t.end()
})
})
})
})
-test('cleanup', function(t) {
+test("cleanup", function (t) {
process.chdir(__dirname)
- rimraf.sync(path.resolve(pkg, 'node_modules'))
- rimraf.sync(path.resolve(pkg, 'cache'))
+ rimraf.sync(path.resolve(pkg, "node_modules"))
+ rimraf.sync(path.resolve(pkg, "cache"))
resetPackageJSON(pkg)
t.end()
})
function resetPackageJSON(pkg) {
- var pkgJson = JSON.parse(fs.readFileSync(pkg + '/package.json', 'utf8'))
+ var pkgJson = JSON.parse(fs.readFileSync(pkg + "/package.json", "utf8"))
delete pkgJson.dependencies
delete pkgJson.devDependencies
delete pkgJson.optionalDependencies
var json = JSON.stringify(pkgJson, null, 2) + "\n"
- fs.writeFileSync(pkg + '/package.json', json, "ascii")
+ var p = path.resolve(pkg, "package.json")
+ fs.writeFileSync(p, json, "ascii")
}
-
-
diff -Nru nodejs-0.11.14/deps/npm/test/tap/install-save-local.js nodejs-0.11.15/deps/npm/test/tap/install-save-local.js
--- nodejs-0.11.14/deps/npm/test/tap/install-save-local.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/install-save-local.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,58 +1,55 @@
+var common = require("../common-tap.js")
var test = require("tap").test
-var npm = require("../../")
var path = require("path")
var fs = require("fs")
var rimraf = require("rimraf")
var pkg = path.join(__dirname, "install-save-local", "package")
+var EXEC_OPTS = { }
+
test("setup", function (t) {
resetPackageJSON(pkg)
process.chdir(pkg)
t.end()
})
-test('"npm install --save ../local/path" should install local package and save to package.json', function(t) {
- resetPackageJSON(pkg)
- npm.load({loglevel : "silent"}, function() {
- npm.config.set("save", true)
- npm.commands.install(["../package-local-dependency"], function(err) {
- t.ifError(err)
-
- var dependencyPackageJson = path.resolve(pkg, "node_modules/package-local-dependency/package.json")
- t.ok(JSON.parse(fs.readFileSync(dependencyPackageJson, "utf8")))
-
- var pkgJson = JSON.parse(fs.readFileSync(pkg + "/package.json", "utf8"))
- t.deepEqual(pkgJson.dependencies, {
- "package-local-dependency": "file:../package-local-dependency"
- })
- npm.config.set("save", undefined)
- t.end()
- })
+test('"npm install --save ../local/path" should install local package and save to package.json', function (t) {
+ resetPackageJSON(pkg)
+ common.npm(["install", "--save", "../package-local-dependency"], EXEC_OPTS, function (err, code) {
+ t.ifError(err)
+ t.notOk(code, "npm install exited with code 0")
+
+ var dependencyPackageJson = path.resolve(pkg, "node_modules/package-local-dependency/package.json")
+ t.ok(JSON.parse(fs.readFileSync(dependencyPackageJson, "utf8")))
+
+ var pkgJson = JSON.parse(fs.readFileSync(pkg + "/package.json", "utf8"))
+ t.deepEqual(pkgJson.dependencies, {
+ "package-local-dependency": "file:../package-local-dependency"
+ })
+ t.end()
})
})
-test('"npm install --save-dev ../local/path" should install local package and save to package.json', function(t) {
+test('"npm install --save-dev ../local/path" should install local package and save to package.json', function (t) {
resetPackageJSON(pkg)
- npm.load({loglevel : "silent"}, function() {
- npm.config.set("save-dev", true)
- npm.commands.install(["../package-local-dev-dependency"], function(err) {
- t.ifError(err)
-
- var dependencyPackageJson = path.resolve(pkg, "node_modules/package-local-dev-dependency/package.json")
- t.ok(JSON.parse(fs.readFileSync(dependencyPackageJson, "utf8")))
-
- var pkgJson = JSON.parse(fs.readFileSync(pkg + "/package.json", "utf8"))
- t.deepEqual(pkgJson.devDependencies, {
- "package-local-dev-dependency": "file:../package-local-dev-dependency"
- })
- npm.config.set("save", undefined)
+ common.npm(["install", "--save-dev", "../package-local-dev-dependency"], EXEC_OPTS, function (err, code) {
+ t.ifError(err)
+ t.notOk(code, "npm install exited with code 0")
+
+ var dependencyPackageJson = path.resolve(pkg, "node_modules/package-local-dev-dependency/package.json")
+ t.ok(JSON.parse(fs.readFileSync(dependencyPackageJson, "utf8")))
+
+ var pkgJson = JSON.parse(fs.readFileSync(pkg + "/package.json", "utf8"))
+ t.deepEqual(pkgJson.devDependencies, {
+ "package-local-dev-dependency": "file:../package-local-dev-dependency"
+ })
- t.end()
- })
+ t.end()
})
})
-test("cleanup", function(t) {
+
+test("cleanup", function (t) {
resetPackageJSON(pkg)
process.chdir(__dirname)
rimraf.sync(path.resolve(pkg, "node_modules"))
diff -Nru nodejs-0.11.14/deps/npm/test/tap/install-save-prefix.js nodejs-0.11.15/deps/npm/test/tap/install-save-prefix.js
--- nodejs-0.11.14/deps/npm/test/tap/install-save-prefix.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/install-save-prefix.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,39 +1,39 @@
-var common = require('../common-tap.js')
-var test = require('tap').test
-var npm = require('../../')
-var path = require('path')
-var fs = require('fs')
-var rimraf = require('rimraf')
-var mkdirp = require('mkdirp')
-var pkg = path.join(__dirname, 'install-save-prefix')
+var common = require("../common-tap.js")
+var test = require("tap").test
+var npm = require("../../")
+var path = require("path")
+var fs = require("fs")
+var rimraf = require("rimraf")
+var mkdirp = require("mkdirp")
+var pkg = path.join(__dirname, "install-save-prefix")
var mr = require("npm-registry-mock")
test("setup", function (t) {
mkdirp.sync(pkg)
- mkdirp.sync(path.resolve(pkg, 'node_modules'))
+ mkdirp.sync(path.resolve(pkg, "node_modules"))
process.chdir(pkg)
t.end()
})
-test('"npm install --save with default save-prefix should install local pkg versioned to allow minor updates', function(t) {
+test("npm install --save with default save-prefix should install local pkg versioned to allow minor updates", function (t) {
resetPackageJSON(pkg)
mr(common.port, function (s) {
npm.load({
cache: pkg + "/cache",
- loglevel: 'silent',
- 'save-prefix': '^',
- registry: common.registry }, function(err) {
+ loglevel: "silent",
+ "save-prefix": "^",
+ registry: common.registry }, function (err) {
t.ifError(err)
- npm.config.set('save', true)
- npm.commands.install(['underscore@latest'], function(err) {
+ npm.config.set("save", true)
+ npm.commands.install(["underscore@latest"], function (err) {
t.ifError(err)
- var p = path.resolve(pkg, 'node_modules/underscore/package.json')
+ var p = path.resolve(pkg, "node_modules/underscore/package.json")
t.ok(JSON.parse(fs.readFileSync(p)))
- var pkgJson = JSON.parse(fs.readFileSync(pkg + '/package.json', 'utf8'))
+ var pkgJson = JSON.parse(fs.readFileSync(pkg + "/package.json", "utf8"))
t.deepEqual(pkgJson.dependencies, {
- 'underscore': '^1.5.1'
- }, 'Underscore dependency should specify ^1.5.1')
- npm.config.set('save', undefined)
+ "underscore": "^1.5.1"
+ }, "Underscore dependency should specify ^1.5.1")
+ npm.config.set("save", undefined)
s.close()
t.end()
})
@@ -41,25 +41,25 @@
})
})
-test('"npm install --save-dev with default save-prefix should install local pkg to dev dependencies versioned to allow minor updates', function(t) {
+test("npm install --save-dev with default save-prefix should install local pkg to dev dependencies versioned to allow minor updates", function (t) {
resetPackageJSON(pkg)
mr(common.port, function (s) {
npm.load({
cache: pkg + "/cache",
- loglevel: 'silent',
- 'save-prefix': '^',
- registry: common.registry }, function(err) {
+ loglevel: "silent",
+ "save-prefix": "^",
+ registry: common.registry }, function (err) {
t.ifError(err)
- npm.config.set('save-dev', true)
- npm.commands.install(['underscore@1.3.1'], function(err) {
+ npm.config.set("save-dev", true)
+ npm.commands.install(["underscore@1.3.1"], function (err) {
t.ifError(err)
- var p = path.resolve(pkg, 'node_modules/underscore/package.json')
+ var p = path.resolve(pkg, "node_modules/underscore/package.json")
t.ok(JSON.parse(fs.readFileSync(p)))
- var pkgJson = JSON.parse(fs.readFileSync(pkg + '/package.json', 'utf8'))
+ var pkgJson = JSON.parse(fs.readFileSync(pkg + "/package.json", "utf8"))
t.deepEqual(pkgJson.devDependencies, {
- 'underscore': '^1.3.1'
- }, 'Underscore devDependency should specify ^1.3.1')
- npm.config.set('save-dev', undefined)
+ "underscore": "^1.3.1"
+ }, "Underscore devDependency should specify ^1.3.1")
+ npm.config.set("save-dev", undefined)
s.close()
t.end()
})
@@ -67,26 +67,26 @@
})
})
-test('"npm install --save with "~" save-prefix should install local pkg versioned to allow patch updates', function(t) {
+test("npm install --save with \"~\" save-prefix should install local pkg versioned to allow patch updates", function (t) {
resetPackageJSON(pkg)
mr(common.port, function (s) {
npm.load({
cache: pkg + "/cache",
- loglevel: 'silent',
- registry: common.registry }, function(err) {
+ loglevel: "silent",
+ registry: common.registry }, function (err) {
t.ifError(err)
- npm.config.set('save', true)
- npm.config.set('save-prefix', '~')
- npm.commands.install(['underscore@1.3.1'], function(err) {
+ npm.config.set("save", true)
+ npm.config.set("save-prefix", "~")
+ npm.commands.install(["underscore@1.3.1"], function (err) {
t.ifError(err)
- var p = path.resolve(pkg, 'node_modules/underscore/package.json')
+ var p = path.resolve(pkg, "node_modules/underscore/package.json")
t.ok(JSON.parse(fs.readFileSync(p)))
- var pkgJson = JSON.parse(fs.readFileSync(pkg + '/package.json', 'utf8'))
+ var pkgJson = JSON.parse(fs.readFileSync(pkg + "/package.json", "utf8"))
t.deepEqual(pkgJson.dependencies, {
- 'underscore': '~1.3.1'
- }, 'Underscore dependency should specify ~1.3.1')
- npm.config.set('save', undefined)
- npm.config.set('save-prefix', undefined)
+ "underscore": "~1.3.1"
+ }, "Underscore dependency should specify ~1.3.1")
+ npm.config.set("save", undefined)
+ npm.config.set("save-prefix", undefined)
s.close()
t.end()
})
@@ -94,26 +94,26 @@
})
})
-test('"npm install --save-dev with "~" save-prefix should install local pkg to dev dependencies versioned to allow patch updates', function(t) {
+test("npm install --save-dev with \"~\" save-prefix should install local pkg to dev dependencies versioned to allow patch updates", function (t) {
resetPackageJSON(pkg)
mr(common.port, function (s) {
npm.load({
cache: pkg + "/cache",
- loglevel: 'silent',
- registry: common.registry }, function(err) {
+ loglevel: "silent",
+ registry: common.registry }, function (err) {
t.ifError(err)
- npm.config.set('save-dev', true)
- npm.config.set('save-prefix', '~')
- npm.commands.install(['underscore@1.3.1'], function(err) {
+ npm.config.set("save-dev", true)
+ npm.config.set("save-prefix", "~")
+ npm.commands.install(["underscore@1.3.1"], function (err) {
t.ifError(err)
- var p = path.resolve(pkg, 'node_modules/underscore/package.json')
+ var p = path.resolve(pkg, "node_modules/underscore/package.json")
t.ok(JSON.parse(fs.readFileSync(p)))
- var pkgJson = JSON.parse(fs.readFileSync(pkg + '/package.json', 'utf8'))
+ var pkgJson = JSON.parse(fs.readFileSync(pkg + "/package.json", "utf8"))
t.deepEqual(pkgJson.devDependencies, {
- 'underscore': '~1.3.1'
- }, 'Underscore devDependency should specify ~1.3.1')
- npm.config.set('save-dev', undefined)
- npm.config.set('save-prefix', undefined)
+ "underscore": "~1.3.1"
+ }, "Underscore devDependency should specify ~1.3.1")
+ npm.config.set("save-dev", undefined)
+ npm.config.set("save-prefix", undefined)
s.close()
t.end()
})
@@ -121,21 +121,19 @@
})
})
-test('cleanup', function(t) {
+test("cleanup", function (t) {
process.chdir(__dirname)
- rimraf.sync(path.resolve(pkg, 'node_modules'))
- rimraf.sync(path.resolve(pkg, 'cache'))
+ rimraf.sync(path.resolve(pkg, "node_modules"))
+ rimraf.sync(path.resolve(pkg, "cache"))
resetPackageJSON(pkg)
t.end()
})
function resetPackageJSON(pkg) {
- var pkgJson = JSON.parse(fs.readFileSync(pkg + '/package.json', 'utf8'))
+ var pkgJson = JSON.parse(fs.readFileSync(pkg + "/package.json", "utf8"))
delete pkgJson.dependencies
delete pkgJson.devDependencies
delete pkgJson.optionalDependencies
var json = JSON.stringify(pkgJson, null, 2) + "\n"
- fs.writeFileSync(pkg + '/package.json', json, "ascii")
+ fs.writeFileSync(pkg + "/package.json", json, "ascii")
}
-
-
diff -Nru nodejs-0.11.14/deps/npm/test/tap/install-scoped-already-installed.js nodejs-0.11.15/deps/npm/test/tap/install-scoped-already-installed.js
--- nodejs-0.11.14/deps/npm/test/tap/install-scoped-already-installed.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/install-scoped-already-installed.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,86 @@
+var common = require("../common-tap")
+var existsSync = require("fs").existsSync
+var join = require("path").join
+
+var test = require("tap").test
+var rimraf = require("rimraf")
+var mkdirp = require("mkdirp")
+
+var pkg = join(__dirname, "install-from-local", "package-with-scoped-paths")
+var modules = join(pkg, "node_modules")
+
+var EXEC_OPTS = {
+ cwd : pkg
+}
+
+test("setup", function (t) {
+ rimraf.sync(modules)
+ rimraf.sync(join(pkg, "cache"))
+ process.chdir(pkg)
+ mkdirp.sync(modules)
+ t.end()
+})
+
+test("installing already installed local scoped package", function (t) {
+ common.npm(["install", "--loglevel", "silent"], EXEC_OPTS, function (err, code, stdout) {
+ var installed = parseNpmInstallOutput(stdout)
+ t.ifError(err, "error should not exist")
+ t.notOk(code, "npm install exited with code 0")
+ t.ifError(err, "install ran to completion without error")
+ t.ok(
+ existsSync(join(modules, "@scoped", "package", "package.json")),
+ "package installed"
+ )
+ t.ok(
+ contains(installed, "node_modules/@scoped/package"),
+ "installed @scoped/package"
+ )
+ t.ok(
+ contains(installed, "node_modules/package-local-dependency"),
+ "installed package-local-dependency"
+ )
+
+ common.npm(["install", "--loglevel", "silent"], EXEC_OPTS, function (err, code, stdout) {
+ installed = parseNpmInstallOutput(stdout)
+ t.ifError(err, "error should not exist")
+ t.notOk(code, "npm install exited with code 0")
+
+ t.ifError(err, "install ran to completion without error")
+
+ t.ok(
+ existsSync(join(modules, "@scoped", "package", "package.json")),
+ "package installed"
+ )
+
+ t.notOk(
+ contains(installed, "node_modules/@scoped/package"),
+ "did not reinstall @scoped/package"
+ )
+ t.notOk(
+ contains(installed, "node_modules/package-local-dependency"),
+ "did not reinstall package-local-dependency"
+ )
+ t.end()
+ })
+ })
+})
+
+test("cleanup", function (t) {
+ process.chdir(__dirname)
+ rimraf.sync(join(modules))
+ rimraf.sync(join(pkg, "cache"))
+ t.end()
+})
+
+function contains(list, element) {
+ for (var i=0; i < list.length; ++i) {
+ if (list[i] === element) {
+ return true
+ }
+ }
+ return false
+}
+
+function parseNpmInstallOutput(stdout) {
+ return stdout.trim().split(/\n\n|\s+/)
+}
diff -Nru nodejs-0.11.14/deps/npm/test/tap/install-scoped-link.js nodejs-0.11.15/deps/npm/test/tap/install-scoped-link.js
--- nodejs-0.11.14/deps/npm/test/tap/install-scoped-link.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/install-scoped-link.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,18 +1,18 @@
-var exec = require("child_process").exec
+var common = require("../common-tap.js")
var existsSync = require("fs").existsSync
var join = require("path").join
-// var resolve = require("path").resolve
+var exec = require("child_process").exec
var test = require("tap").test
var rimraf = require("rimraf")
var mkdirp = require("mkdirp")
-var npm = require("../../")
-
var pkg = join(__dirname, "install-scoped")
var work = join(__dirname, "install-scoped-TEST")
var modules = join(work, "node_modules")
+var EXEC_OPTS = {}
+
test("setup", function (t) {
mkdirp.sync(modules)
process.chdir(work)
@@ -21,31 +21,30 @@
})
test("installing package with links", function (t) {
- npm.load(function() {
- npm.commands.install([pkg], function (err) {
- t.ifError(err, "install ran to completion without error")
-
- t.ok(
- existsSync(join(modules, "@scoped", "package", "package.json")),
- "package installed"
- )
- t.ok(existsSync(join(modules, ".bin")), "binary link directory exists")
-
- var hello = join(modules, ".bin", "hello")
- t.ok(existsSync(hello), "binary link exists")
-
- exec("node " + hello, function (err, stdout, stderr) {
- t.ifError(err, "command ran fine")
- t.notOk(stderr, "got no error output back")
- t.equal(stdout, "hello blrbld\n", "output was as expected")
+ common.npm(["install", pkg], EXEC_OPTS, function (err, code) {
+ t.ifError(err, "install ran to completion without error")
+ t.notOk(code, "npm install exited with code 0")
+
+ t.ok(
+ existsSync(join(modules, "@scoped", "package", "package.json")),
+ "package installed"
+ )
+ t.ok(existsSync(join(modules, ".bin")), "binary link directory exists")
+
+ var hello = join(modules, ".bin", "hello")
+ t.ok(existsSync(hello), "binary link exists")
+
+ exec("node " + hello, function (err, stdout, stderr) {
+ t.ifError(err, "command ran fine")
+ t.notOk(stderr, "got no error output back")
+ t.equal(stdout, "hello blrbld\n", "output was as expected")
- t.end()
- })
+ t.end()
})
})
})
-test("cleanup", function(t) {
+test("cleanup", function (t) {
process.chdir(__dirname)
rimraf.sync(work)
t.end()
diff -Nru nodejs-0.11.14/deps/npm/test/tap/install-with-dev-dep-duplicate.js nodejs-0.11.15/deps/npm/test/tap/install-with-dev-dep-duplicate.js
--- nodejs-0.11.14/deps/npm/test/tap/install-with-dev-dep-duplicate.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/install-with-dev-dep-duplicate.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,57 @@
+var npm = npm = require("../../")
+var test = require("tap").test
+var path = require("path")
+var fs = require("fs")
+var osenv = require("osenv")
+var rimraf = require("rimraf")
+var mr = require("npm-registry-mock")
+var common = require("../common-tap.js")
+
+var pkg = path.resolve(__dirname, "dev-dep-duplicate")
+var desiredResultsPath = path.resolve(pkg, "desired-ls-results.json")
+
+test("prefers version from dependencies over devDependencies", function (t) {
+ t.plan(1)
+
+ mr(common.port, function (s) {
+ setup(function (err) {
+ if (err) return t.fail(err)
+
+ npm.install(".", function (err) {
+ if (err) return t.fail(err)
+
+ npm.commands.ls([], true, function (err, _, results) {
+ if (err) return t.fail(err)
+
+ fs.readFile(desiredResultsPath, function (err, desired) {
+ if (err) return t.fail(err)
+
+ t.deepEqual(results, JSON.parse(desired))
+ s.close()
+ t.end()
+ })
+ })
+ })
+ })
+ })
+})
+
+test("cleanup", function (t) {
+ cleanup()
+ t.end()
+})
+
+
+function setup (cb) {
+ cleanup()
+ process.chdir(pkg)
+
+ var opts = { cache: path.resolve(pkg, "cache"), registry: common.registry}
+ npm.load(opts, cb)
+}
+
+function cleanup () {
+ process.chdir(osenv.tmpdir())
+ rimraf.sync(path.resolve(pkg, "node_modules"))
+ rimraf.sync(path.resolve(pkg, "cache"))
+}
diff -Nru nodejs-0.11.14/deps/npm/test/tap/invalid-cmd-exit-code.js nodejs-0.11.15/deps/npm/test/tap/invalid-cmd-exit-code.js
--- nodejs-0.11.14/deps/npm/test/tap/invalid-cmd-exit-code.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/invalid-cmd-exit-code.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,10 +1,9 @@
var test = require("tap").test
-var node = process.execPath
var common = require("../common-tap.js")
var opts = { cwd: process.cwd() }
-test("npm asdf should return exit code 1", function(t) {
+test("npm asdf should return exit code 1", function (t) {
common.npm(["asdf"], opts, function (er, c) {
if (er) throw er
t.ok(c, "exit code should not be zero")
@@ -12,7 +11,7 @@
})
})
-test("npm help should return exit code 0", function(t) {
+test("npm help should return exit code 0", function (t) {
common.npm(["help"], opts, function (er, c) {
if (er) throw er
t.equal(c, 0, "exit code should be 0")
@@ -20,7 +19,7 @@
})
})
-test("npm help fadf should return exit code 0", function(t) {
+test("npm help fadf should return exit code 0", function (t) {
common.npm(["help", "fadf"], opts, function (er, c) {
if (er) throw er
t.equal(c, 0, "exit code should be 0")
diff -Nru nodejs-0.11.14/deps/npm/test/tap/lifecycle.js nodejs-0.11.15/deps/npm/test/tap/lifecycle.js
--- nodejs-0.11.14/deps/npm/test/tap/lifecycle.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/lifecycle.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,12 +1,12 @@
var test = require("tap").test
-var npm = require('../../')
-var lifecycle = require('../../lib/utils/lifecycle')
+var npm = require("../../")
+var lifecycle = require("../../lib/utils/lifecycle")
test("lifecycle: make env correctly", function (t) {
- npm.load({enteente: Infinity}, function() {
+ npm.load({enteente: Infinity}, function () {
var env = lifecycle.makeEnv({}, null, process.env)
- t.equal('Infinity', env.npm_config_enteente)
+ t.equal("Infinity", env.npm_config_enteente)
t.end()
})
})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/lifecycle-path.js nodejs-0.11.15/deps/npm/test/tap/lifecycle-path.js
--- nodejs-0.11.14/deps/npm/test/tap/lifecycle-path.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/lifecycle-path.js 2015-01-20 21:22:17.000000000 +0000
@@ -2,7 +2,6 @@
var common = require("../common-tap.js")
var path = require("path")
var rimraf = require("rimraf")
-var mkdirp = require("mkdirp")
var pkg = path.resolve(__dirname, "lifecycle-path")
var fs = require("fs")
var link = path.resolve(pkg, "node-bin")
@@ -28,7 +27,7 @@
PATH: PATH,
stdio: [ 0, "pipe", 2 ]
}
- }, function (er, code, stdout, stderr) {
+ }, function (er, code, stdout) {
if (er) throw er
t.equal(code, 0, "exit code")
// remove the banner, we just care about the last line
@@ -58,4 +57,3 @@
rimraf.sync(link)
t.end()
})
-
diff -Nru nodejs-0.11.14/deps/npm/test/tap/locker.js nodejs-0.11.15/deps/npm/test/tap/locker.js
--- nodejs-0.11.14/deps/npm/test/tap/locker.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/locker.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,89 @@
+var test = require("tap").test
+ , path = require("path")
+ , fs = require("graceful-fs")
+ , crypto = require("crypto")
+ , rimraf = require("rimraf")
+ , osenv = require("osenv")
+ , mkdirp = require("mkdirp")
+ , npm = require("../../")
+ , locker = require("../../lib/utils/locker.js")
+ , lock = locker.lock
+ , unlock = locker.unlock
+
+var pkg = path.join(__dirname, "/locker")
+ , cache = path.join(pkg, "/cache")
+ , tmp = path.join(pkg, "/tmp")
+ , nm = path.join(pkg, "/node_modules")
+
+function cleanup () {
+ process.chdir(osenv.tmpdir())
+ rimraf.sync(pkg)
+}
+
+test("setup", function (t) {
+ cleanup()
+ mkdirp.sync(cache)
+ mkdirp.sync(tmp)
+ t.end()
+})
+
+test("locking file puts lock in correct place", function (t) {
+ npm.load({cache: cache, tmpdir: tmp}, function (er) {
+ t.ifError(er, "npm bootstrapped OK")
+
+ var n = "correct"
+ , c = n.replace(/[^a-zA-Z0-9]+/g, "-").replace(/^-+|-+$/g, "")
+ , p = path.resolve(nm, n)
+ , h = crypto.createHash("sha1").update(p).digest("hex")
+ , l = c.substr(0, 24)+"-"+h.substr(0, 16)+".lock"
+ , v = path.join(cache, "_locks", l)
+
+ lock(nm, n, function (er) {
+ t.ifError(er, "locked path")
+
+ fs.exists(v, function (found) {
+ t.ok(found, "lock found OK")
+
+ unlock(nm, n, function (er) {
+ t.ifError(er, "unlocked path")
+
+ fs.exists(v, function (found) {
+ t.notOk(found, "lock deleted OK")
+ t.end()
+ })
+ })
+ })
+ })
+ })
+})
+
+test("unlocking out of order errors out", function (t) {
+ npm.load({cache: cache, tmpdir: tmp}, function (er) {
+ t.ifError(er, "npm bootstrapped OK")
+
+ var n = "busted"
+ , c = n.replace(/[^a-zA-Z0-9]+/g, "-").replace(/^-+|-+$/g, "")
+ , p = path.resolve(nm, n)
+ , h = crypto.createHash("sha1").update(p).digest("hex")
+ , l = c.substr(0, 24)+"-"+h.substr(0, 16)+".lock"
+ , v = path.join(cache, "_locks", l)
+
+ fs.exists(v, function (found) {
+ t.notOk(found, "no lock to unlock")
+
+ t.throws(function () {
+ unlock(nm, n, function () {
+ t.fail("shouldn't get here")
+ t.end()
+ })
+ }, "blew up as expected")
+
+ t.end()
+ })
+ })
+})
+
+test("cleanup", function (t) {
+ cleanup()
+ t.end()
+})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/login-always-auth.js nodejs-0.11.15/deps/npm/test/tap/login-always-auth.js
--- nodejs-0.11.14/deps/npm/test/tap/login-always-auth.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/login-always-auth.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,142 @@
+var fs = require("fs")
+var path = require("path")
+var rimraf = require("rimraf")
+var mr = require("npm-registry-mock")
+
+var test = require("tap").test
+var common = require("../common-tap.js")
+
+var opts = {cwd : __dirname}
+var outfile = path.resolve(__dirname, "_npmrc")
+var responses = {
+ "Username" : "u\n",
+ "Password" : "p\n",
+ "Email" : "u@p.me\n"
+}
+
+function mocks(server) {
+ server.filteringRequestBody(function (r) {
+ if (r.match(/\"_id\":\"org\.couchdb\.user:u\"/)) {
+ return "auth"
+ }
+ })
+ server.put("/-/user/org.couchdb.user:u", "auth")
+ .reply(201, {username : "u", password : "p", email : "u@p.me"})
+}
+
+test("npm login", function (t) {
+ mr({port : common.port, mocks : mocks}, function (s) {
+ var runner = common.npm(
+ [
+ "login",
+ "--registry", common.registry,
+ "--loglevel", "silent",
+ "--userconfig", outfile
+ ],
+ opts,
+ function (err, code) {
+ t.notOk(code, "exited OK")
+ t.notOk(err, "no error output")
+ var config = fs.readFileSync(outfile, "utf8")
+ t.like(config, /:always-auth=false/, "always-auth is scoped and false (by default)")
+ s.close()
+ rimraf(outfile, function (err) {
+ t.ifError(err, "removed config file OK")
+ t.end()
+ })
+ })
+
+ var o = "", e = "", remaining = Object.keys(responses).length
+ runner.stdout.on("data", function (chunk) {
+ remaining--
+ o += chunk
+
+ var label = chunk.toString("utf8").split(":")[0]
+ runner.stdin.write(responses[label])
+
+ if (remaining === 0) runner.stdin.end()
+ })
+ runner.stderr.on("data", function (chunk) { e += chunk })
+ })
+})
+
+test("npm login --always-auth", function (t) {
+ mr({port : common.port, mocks : mocks}, function (s) {
+ var runner = common.npm(
+ [
+ "login",
+ "--registry", common.registry,
+ "--loglevel", "silent",
+ "--userconfig", outfile,
+ "--always-auth"
+ ],
+ opts,
+ function (err, code) {
+ t.notOk(code, "exited OK")
+ t.notOk(err, "no error output")
+ var config = fs.readFileSync(outfile, "utf8")
+ t.like(config, /:always-auth=true/, "always-auth is scoped and true")
+ s.close()
+ rimraf(outfile, function (err) {
+ t.ifError(err, "removed config file OK")
+ t.end()
+ })
+ })
+
+ var o = "", e = "", remaining = Object.keys(responses).length
+ runner.stdout.on("data", function (chunk) {
+ remaining--
+ o += chunk
+
+ var label = chunk.toString("utf8").split(":")[0]
+ runner.stdin.write(responses[label])
+
+ if (remaining === 0) runner.stdin.end()
+ })
+ runner.stderr.on("data", function (chunk) { e += chunk })
+ })
+})
+
+test("npm login --no-always-auth", function (t) {
+ mr({port : common.port, mocks : mocks}, function (s) {
+ var runner = common.npm(
+ [
+ "login",
+ "--registry", common.registry,
+ "--loglevel", "silent",
+ "--userconfig", outfile,
+ "--no-always-auth"
+ ],
+ opts,
+ function (err, code) {
+ t.notOk(code, "exited OK")
+ t.notOk(err, "no error output")
+ var config = fs.readFileSync(outfile, "utf8")
+ t.like(config, /:always-auth=false/, "always-auth is scoped and false")
+ s.close()
+ rimraf(outfile, function (err) {
+ t.ifError(err, "removed config file OK")
+ t.end()
+ })
+ })
+
+ var o = "", e = "", remaining = Object.keys(responses).length
+ runner.stdout.on("data", function (chunk) {
+ remaining--
+ o += chunk
+
+ var label = chunk.toString("utf8").split(":")[0]
+ runner.stdin.write(responses[label])
+
+ if (remaining === 0) runner.stdin.end()
+ })
+ runner.stderr.on("data", function (chunk) { e += chunk })
+ })
+})
+
+
+test("cleanup", function (t) {
+ rimraf.sync(outfile)
+ t.pass("cleaned up")
+ t.end()
+})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/ls-depth-cli.js nodejs-0.11.15/deps/npm/test/tap/ls-depth-cli.js
--- nodejs-0.11.14/deps/npm/test/tap/ls-depth-cli.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/ls-depth-cli.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,31 +1,27 @@
-var common = require('../common-tap')
- , test = require('tap').test
- , path = require('path')
- , rimraf = require('rimraf')
- , osenv = require('osenv')
- , mkdirp = require('mkdirp')
- , pkg = __dirname + '/ls-depth'
- , cache = pkg + '/cache'
- , tmp = pkg + '/tmp'
- , node = process.execPath
- , npm = path.resolve(__dirname, '../../cli.js')
- , mr = require('npm-registry-mock')
+var common = require("../common-tap")
+ , test = require("tap").test
+ , path = require("path")
+ , rimraf = require("rimraf")
+ , osenv = require("osenv")
+ , mkdirp = require("mkdirp")
+ , pkg = path.resolve(__dirname, "ls-depth")
+ , mr = require("npm-registry-mock")
, opts = {cwd: pkg}
function cleanup () {
process.chdir(osenv.tmpdir())
- rimraf.sync(pkg + '/cache')
- rimraf.sync(pkg + '/tmp')
- rimraf.sync(pkg + '/node_modules')
+ rimraf.sync(pkg + "/cache")
+ rimraf.sync(pkg + "/tmp")
+ rimraf.sync(pkg + "/node_modules")
}
-test('setup', function (t) {
+test("setup", function (t) {
cleanup()
- mkdirp.sync(pkg + '/cache')
- mkdirp.sync(pkg + '/tmp')
+ mkdirp.sync(pkg + "/cache")
+ mkdirp.sync(pkg + "/tmp")
mr(common.port, function (s) {
- var cmd = ['install', '--registry=' + common.registry]
+ var cmd = ["install", "--registry=" + common.registry]
common.npm(cmd, opts, function (er, c) {
if (er) throw er
t.equal(c, 0)
@@ -35,8 +31,8 @@
})
})
-test('npm ls --depth=0', function (t) {
- common.npm(['ls', '--depth=0'], opts, function (er, c, out) {
+test("npm ls --depth=0", function (t) {
+ common.npm(["ls", "--depth=0"], opts, function (er, c, out) {
if (er) throw er
t.equal(c, 0)
t.has(out, /test-package-with-one-dep@0\.0\.0/
@@ -47,8 +43,8 @@
})
})
-test('npm ls --depth=1', function (t) {
- common.npm(['ls', '--depth=1'], opts, function (er, c, out) {
+test("npm ls --depth=1", function (t) {
+ common.npm(["ls", "--depth=1"], opts, function (er, c, out) {
if (er) throw er
t.equal(c, 0)
t.has(out, /test-package-with-one-dep@0\.0\.0/
@@ -59,10 +55,10 @@
})
})
-test('npm ls --depth=Infinity', function (t) {
+test("npm ls --depth=Infinity", function (t) {
// travis has a preconfigured depth=0, in general we can not depend
// on the default value in all environments, so explictly set it here
- common.npm(['ls', '--depth=Infinity'], opts, function (er, c, out) {
+ common.npm(["ls", "--depth=Infinity"], opts, function (er, c, out) {
if (er) throw er
t.equal(c, 0)
t.has(out, /test-package-with-one-dep@0\.0\.0/
@@ -73,7 +69,7 @@
})
})
-test('cleanup', function (t) {
+test("cleanup", function (t) {
cleanup()
t.end()
})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/ls-depth-unmet.js nodejs-0.11.15/deps/npm/test/tap/ls-depth-unmet.js
--- nodejs-0.11.14/deps/npm/test/tap/ls-depth-unmet.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/ls-depth-unmet.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,31 +1,30 @@
-var common = require('../common-tap')
- , test = require('tap').test
- , path = require('path')
- , rimraf = require('rimraf')
- , osenv = require('osenv')
- , mkdirp = require('mkdirp')
- , pkg = __dirname + '/ls-depth-unmet'
- , cache = pkg + '/cache'
- , tmp = pkg + '/tmp'
- , node = process.execPath
- , npm = path.resolve(__dirname, '../../cli.js')
- , mr = require('npm-registry-mock')
+var common = require("../common-tap")
+ , test = require("tap").test
+ , path = require("path")
+ , rimraf = require("rimraf")
+ , osenv = require("osenv")
+ , mkdirp = require("mkdirp")
+ , pkg = path.resolve(__dirname, "ls-depth-unmet")
+ , mr = require("npm-registry-mock")
, opts = {cwd: pkg}
+ , cache = path.resolve(pkg, "cache")
+ , tmp = path.resolve(pkg, "tmp")
+ , nodeModules = path.resolve(pkg, "node_modules")
function cleanup () {
process.chdir(osenv.tmpdir())
- rimraf.sync(pkg + '/cache')
- rimraf.sync(pkg + '/tmp')
- rimraf.sync(pkg + '/node_modules')
+ rimraf.sync(cache)
+ rimraf.sync(tmp)
+ rimraf.sync(nodeModules)
}
-test('setup', function (t) {
+test("setup", function (t) {
cleanup()
- mkdirp.sync(pkg + '/cache')
- mkdirp.sync(pkg + '/tmp')
+ mkdirp.sync(cache)
+ mkdirp.sync(tmp)
mr(common.port, function (s) {
- var cmd = ['install', 'underscore@1.3.1', 'mkdirp', 'test-package-with-one-dep', '--registry=' + common.registry]
+ var cmd = ["install", "underscore@1.3.1", "mkdirp", "test-package-with-one-dep", "--registry=" + common.registry]
common.npm(cmd, opts, function (er, c) {
if (er) throw er
t.equal(c, 0)
@@ -35,8 +34,8 @@
})
})
-test('npm ls --depth=0', function (t) {
- common.npm(['ls', '--depth=0'], opts, function (er, c, out) {
+test("npm ls --depth=0", function (t) {
+ common.npm(["ls", "--depth=0"], opts, function (er, c, out) {
if (er) throw er
t.equal(c, 1)
t.has(out, /UNMET DEPENDENCY optimist@0\.6\.0/
@@ -53,8 +52,8 @@
})
})
-test('npm ls --depth=1', function (t) {
- common.npm(['ls', '--depth=1'], opts, function (er, c, out) {
+test("npm ls --depth=1", function (t) {
+ common.npm(["ls", "--depth=1"], opts, function (er, c, out) {
if (er) throw er
t.equal(c, 1)
t.has(out, /UNMET DEPENDENCY optimist@0\.6\.0/
@@ -71,10 +70,10 @@
})
})
-test('npm ls --depth=Infinity', function (t) {
+test("npm ls --depth=Infinity", function (t) {
// travis has a preconfigured depth=0, in general we can not depend
// on the default value in all environments, so explictly set it here
- common.npm(['ls', '--depth=Infinity'], opts, function (er, c, out) {
+ common.npm(["ls", "--depth=Infinity"], opts, function (er, c, out) {
if (er) throw er
t.equal(c, 1)
t.has(out, /UNMET DEPENDENCY optimist@0\.6\.0/
@@ -91,7 +90,7 @@
})
})
-test('cleanup', function (t) {
+test("cleanup", function (t) {
cleanup()
t.end()
})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/ls-no-results.js nodejs-0.11.15/deps/npm/test/tap/ls-no-results.js
--- nodejs-0.11.14/deps/npm/test/tap/ls-no-results.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/ls-no-results.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,11 +1,11 @@
-var test = require('tap').test
-var spawn = require('child_process').spawn
+var test = require("tap").test
+var spawn = require("child_process").spawn
var node = process.execPath
-var npm = require.resolve('../../')
-var args = [ npm, 'ls', 'ceci n’est pas une package' ]
-test('ls exits non-zero when nothing found', function (t) {
+var npm = require.resolve("../../")
+var args = [ npm, "ls", "ceci n’est pas une package" ]
+test("ls exits non-zero when nothing found", function (t) {
var child = spawn(node, args)
- child.on('exit', function (code) {
+ child.on("exit", function (code) {
t.notEqual(code, 0)
t.end()
})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/noargs-install-config-save.js nodejs-0.11.15/deps/npm/test/tap/noargs-install-config-save.js
--- nodejs-0.11.14/deps/npm/test/tap/noargs-install-config-save.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/noargs-install-config-save.js 2015-01-20 21:22:17.000000000 +0000
@@ -11,8 +11,8 @@
var spawn = require("child_process").spawn
var node = process.execPath
-var pkg = process.env.npm_config_tmp || "/tmp"
-pkg += path.sep + "noargs-install-config-save"
+var pkg = path.resolve(process.env.npm_config_tmp || "/tmp",
+ "noargs-install-config-save")
function writePackageJson() {
rimraf.sync(pkg)
@@ -26,14 +26,14 @@
"devDependencies": {
"underscore": "1.3.1"
}
- }), 'utf8')
+ }), "utf8")
}
function createChild (args) {
var env = {
- npm_config_save: true,
- npm_config_registry: common.registry,
- npm_config_cache: pkg + "/cache",
+ "npm_config_save": true,
+ "npm_config_registry": common.registry,
+ "npm_config_cache": pkg + "/cache",
HOME: process.env.HOME,
Path: process.env.PATH,
PATH: process.env.PATH
@@ -56,7 +56,7 @@
var child = createChild([npm, "install"])
child.on("close", function () {
var text = JSON.stringify(fs.readFileSync(pkg + "/package.json", "utf8"))
- t.ok(text.indexOf('"dependencies') === -1)
+ t.ok(text.indexOf("\"dependencies") === -1)
s.close()
t.end()
})
@@ -71,7 +71,7 @@
var child = createChild([npm, "install", "underscore"])
child.on("close", function () {
var text = JSON.stringify(fs.readFileSync(pkg + "/package.json", "utf8"))
- t.ok(text.indexOf('"dependencies') !== -1)
+ t.ok(text.indexOf("\"dependencies") !== -1)
s.close()
t.end()
})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/npm-api-not-loaded-error.js nodejs-0.11.15/deps/npm/test/tap/npm-api-not-loaded-error.js
--- nodejs-0.11.14/deps/npm/test/tap/npm-api-not-loaded-error.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/npm-api-not-loaded-error.js 2015-01-20 21:22:17.000000000 +0000
@@ -21,7 +21,7 @@
t.ok(threw, "get before load should throw")
}
- var threw = true
+ threw = true
try {
npm.config.set("foo", "bar")
threw = false
diff -Nru nodejs-0.11.14/deps/npm/test/tap/optional-metadep-rollback-collision.js nodejs-0.11.15/deps/npm/test/tap/optional-metadep-rollback-collision.js
--- nodejs-0.11.14/deps/npm/test/tap/optional-metadep-rollback-collision.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/optional-metadep-rollback-collision.js 2015-01-20 21:22:17.000000000 +0000
@@ -25,7 +25,7 @@
stdio: [ 0, "pipe", 2 ]
}, function (er, code, sout) {
if (er) throw er
- t.equal(code, 0)
+ t.notOk(code, "npm install exited with code 0")
t.equal(sout, "ok\nok\n")
t.notOk(/not ok/.test(sout), "should not contain the string 'not ok'")
t.end()
diff -Nru nodejs-0.11.14/deps/npm/test/tap/outdated-color.js nodejs-0.11.15/deps/npm/test/tap/outdated-color.js
--- nodejs-0.11.14/deps/npm/test/tap/outdated-color.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/outdated-color.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,15 +1,17 @@
var common = require("../common-tap.js")
var test = require("tap").test
-var npm = require("../../")
var mkdirp = require("mkdirp")
var rimraf = require("rimraf")
var mr = require("npm-registry-mock")
-var exec = require('child_process').exec
-var mr = require("npm-registry-mock")
+var path = require("path")
+
+var pkg = path.resolve(__dirname, "outdated")
+var cache = path.resolve(pkg, "cache")
+mkdirp.sync(cache)
-var pkg = __dirname + '/outdated'
-var NPM_BIN = __dirname + '/../../bin/npm-cli.js'
-mkdirp.sync(pkg + "/cache")
+var EXEC_OPTS = {
+ cwd: pkg
+}
function hasControlCodes(str) {
return str.length !== ansiTrim(str).length
@@ -17,20 +19,26 @@
function ansiTrim (str) {
var r = new RegExp("\x1b(?:\\[(?:\\d+[ABCDEFGJKSTm]|\\d+;\\d+[Hfm]|" +
- "\\d+;\\d+;\\d+m|6n|s|u|\\?25[lh])|\\w)", "g");
+ "\\d+;\\d+;\\d+m|6n|s|u|\\?25[lh])|\\w)", "g")
return str.replace(r, "")
}
// note hard to automate tests for color = true
// as npm kills the color config when it detects
-// it's not running in a tty
+// it"s not running in a tty
test("does not use ansi styling", function (t) {
- t.plan(3)
+ t.plan(4)
mr(common.port, function (s) { // create mock registry.
- exec('node ' + NPM_BIN + ' outdated --registry ' + common.registry + ' --color false underscore', {
- cwd: pkg
- }, function(err, stdout) {
+ common.npm(
+ [
+ "outdated",
+ "--registry", common.registry,
+ "underscore"
+ ],
+ EXEC_OPTS,
+ function (err, code, stdout) {
t.ifError(err)
+ t.notOk(code, "npm outdated exited with code 0")
t.ok(stdout, stdout.length)
t.ok(!hasControlCodes(stdout))
s.close()
@@ -39,6 +47,6 @@
})
test("cleanup", function (t) {
- rimraf.sync(pkg + "/cache")
+ rimraf.sync(cache)
t.end()
})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/outdated-depth.js nodejs-0.11.15/deps/npm/test/tap/outdated-depth.js
--- nodejs-0.11.14/deps/npm/test/tap/outdated-depth.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/outdated-depth.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,37 +1,39 @@
-var common = require('../common-tap')
- , path = require('path')
- , test = require('tap').test
- , rimraf = require('rimraf')
- , npm = require('../../')
- , mr = require('npm-registry-mock')
- , pkg = path.resolve(__dirname, 'outdated-depth')
+var common = require("../common-tap")
+ , path = require("path")
+ , test = require("tap").test
+ , rimraf = require("rimraf")
+ , npm = require("../../")
+ , mr = require("npm-registry-mock")
+ , pkg = path.resolve(__dirname, "outdated-depth")
+ , cache = path.resolve(pkg, "cache")
+ , nodeModules = path.resolve(pkg, "node_modules")
function cleanup () {
- rimraf.sync(pkg + '/node_modules')
- rimraf.sync(pkg + '/cache')
+ rimraf.sync(nodeModules)
+ rimraf.sync(cache)
}
-test('outdated depth zero', function (t) {
+test("outdated depth zero", function (t) {
var expected = [
pkg,
- 'underscore',
- '1.3.1',
- '1.3.1',
- '1.5.1',
- '1.3.1'
+ "underscore",
+ "1.3.1",
+ "1.3.1",
+ "1.5.1",
+ "1.3.1"
]
process.chdir(pkg)
mr(common.port, function (s) {
npm.load({
- cache: pkg + '/cache'
- , loglevel: 'silent'
+ cache: cache
+ , loglevel: "silent"
, registry: common.registry
, depth: 0
}
, function () {
- npm.install('.', function (er) {
+ npm.install(".", function (er) {
if (er) throw new Error(er)
npm.outdated(function (err, d) {
if (err) throw new Error(err)
diff -Nru nodejs-0.11.14/deps/npm/test/tap/outdated-git.js nodejs-0.11.15/deps/npm/test/tap/outdated-git.js
--- nodejs-0.11.14/deps/npm/test/tap/outdated-git.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/outdated-git.js 2015-01-20 21:22:17.000000000 +0000
@@ -3,28 +3,29 @@
var npm = require("../../")
var mkdirp = require("mkdirp")
var rimraf = require("rimraf")
-var mr = require("npm-registry-mock")
+var path = require("path")
// config
-var pkg = __dirname + "/outdated-git"
-mkdirp.sync(pkg + "/cache")
+var pkg = path.resolve(__dirname, "outdated-git")
+var cache = path.resolve(pkg, "cache")
+mkdirp.sync(cache)
test("dicovers new versions in outdated", function (t) {
process.chdir(pkg)
t.plan(5)
- npm.load({cache: pkg + "/cache", registry: common.registry}, function () {
+ npm.load({cache: cache, registry: common.registry}, function () {
npm.commands.outdated([], function (er, d) {
- t.equal('git', d[0][3])
- t.equal('git', d[0][4])
- t.equal('git://github.com/robertkowalski/foo-private.git', d[0][5])
- t.equal('git://user:pass@github.com/robertkowalski/foo-private.git', d[1][5])
- t.equal('git+https://github.com/robertkowalski/foo', d[2][5])
+ t.equal("git", d[0][3])
+ t.equal("git", d[0][4])
+ t.equal("git://github.com/robertkowalski/foo-private.git", d[0][5])
+ t.equal("git://user:pass@github.com/robertkowalski/foo-private.git", d[1][5])
+ t.equal("git+https://github.com/robertkowalski/foo", d[2][5])
})
})
})
test("cleanup", function (t) {
- rimraf.sync(pkg + "/cache")
+ rimraf.sync(cache)
t.end()
})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/outdated-include-devdependencies.js nodejs-0.11.15/deps/npm/test/tap/outdated-include-devdependencies.js
--- nodejs-0.11.14/deps/npm/test/tap/outdated-include-devdependencies.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/outdated-include-devdependencies.js 2015-01-20 21:22:17.000000000 +0000
@@ -4,15 +4,17 @@
var mkdirp = require("mkdirp")
var rimraf = require("rimraf")
var mr = require("npm-registry-mock")
+var path = require("path")
// config
-var pkg = __dirname + '/outdated-include-devdependencies'
-mkdirp.sync(pkg + "/cache")
+var pkg = path.resolve(__dirname, "outdated-include-devdependencies")
+var cache = path.resolve(pkg, "cache")
+mkdirp.sync(cache)
test("includes devDependencies in outdated", function (t) {
process.chdir(pkg)
mr(common.port, function (s) {
- npm.load({cache: pkg + "/cache", registry: common.registry}, function () {
+ npm.load({cache: cache, registry: common.registry}, function () {
npm.outdated(function (er, d) {
t.equal("1.5.1", d[0][3])
s.close()
@@ -23,6 +25,6 @@
})
test("cleanup", function (t) {
- rimraf.sync(pkg + "/cache")
+ rimraf.sync(cache)
t.end()
})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/outdated.js nodejs-0.11.15/deps/npm/test/tap/outdated.js
--- nodejs-0.11.14/deps/npm/test/tap/outdated.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/outdated.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,14 +1,14 @@
var common = require("../common-tap.js")
-var fs = require("fs")
var test = require("tap").test
var rimraf = require("rimraf")
var npm = require("../../")
+var path = require("path")
var mr = require("npm-registry-mock")
// config
-var pkg = __dirname + '/outdated'
-
-var path = require("path")
+var pkg = path.resolve(__dirname, "outdated")
+var cache = path.resolve(pkg, "cache")
+var nodeModules = path.resolve(pkg, "node_modules")
test("it should not throw", function (t) {
cleanup()
@@ -33,13 +33,15 @@
}
mr(common.port, function (s) {
npm.load({
- cache: pkg + "/cache",
- loglevel: 'silent',
+ cache: "cache",
+ loglevel: "silent",
parseable: true,
registry: common.registry }
, function () {
npm.install(".", function (err) {
+ t.ifError(err, "install success")
npm.outdated(function (er, d) {
+ t.ifError(er, "outdated success")
console.log = originalLog
t.same(output, expOut)
t.same(d, expData)
@@ -57,6 +59,6 @@
})
function cleanup () {
- rimraf.sync(pkg + "/node_modules")
- rimraf.sync(pkg + "/cache")
+ rimraf.sync(nodeModules)
+ rimraf.sync(cache)
}
diff -Nru nodejs-0.11.14/deps/npm/test/tap/outdated-json.js nodejs-0.11.15/deps/npm/test/tap/outdated-json.js
--- nodejs-0.11.14/deps/npm/test/tap/outdated-json.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/outdated-json.js 2015-01-20 21:22:17.000000000 +0000
@@ -5,29 +5,29 @@
, mr = require("npm-registry-mock")
, path = require("path")
, osenv = require("osenv")
- , spawn = require('child_process').spawn
+ , spawn = require("child_process").spawn
, node = process.execPath
- , npmc = require.resolve('../../')
- , pkg = path.resolve(__dirname, 'outdated-new-versions')
+ , npmc = require.resolve("../../")
+ , pkg = path.resolve(__dirname, "outdated-new-versions")
, args = [ npmc
- , 'outdated'
- , '--json'
- , '--silent'
- , '--registry=' + common.registry
- , '--cache=' + pkg + '/cache'
+ , "outdated"
+ , "--json"
+ , "--silent"
+ , "--registry=" + common.registry
+ , "--cache=" + pkg + "/cache"
]
var expected = { underscore:
- { current: '1.3.3'
- , wanted: '1.3.3'
- , latest: '1.5.1'
- , location: 'node_modules' + path.sep + 'underscore'
+ { current: "1.3.3"
+ , wanted: "1.3.3"
+ , latest: "1.5.1"
+ , location: "node_modules" + path.sep + "underscore"
}
, request:
- { current: '0.9.5'
- , wanted: '0.9.5'
- , latest: '2.27.0'
- , location: 'node_modules' + path.sep + 'request'
+ { current: "0.9.5"
+ , wanted: "0.9.5"
+ , latest: "2.27.0"
+ , location: "node_modules" + path.sep + "request"
}
}
@@ -38,18 +38,19 @@
mr(common.port, function (s) {
npm.load({
cache: pkg + "/cache",
- loglevel: 'silent',
+ loglevel: "silent",
registry: common.registry }
, function () {
npm.install(".", function (err) {
+ t.ifError(err, "error should not exist")
var child = spawn(node, args)
- , out = ''
+ , out = ""
child.stdout
- .on('data', function (buf) {
+ .on("data", function (buf) {
out += buf.toString()
})
.pipe(process.stdout)
- child.on('exit', function () {
+ child.on("exit", function () {
out = JSON.parse(out)
t.deepEqual(out, expected)
s.close()
diff -Nru nodejs-0.11.14/deps/npm/test/tap/outdated-new-versions.js nodejs-0.11.15/deps/npm/test/tap/outdated-new-versions.js
--- nodejs-0.11.14/deps/npm/test/tap/outdated-new-versions.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/outdated-new-versions.js 2015-01-20 21:22:17.000000000 +0000
@@ -3,11 +3,13 @@
var npm = require("../../")
var mkdirp = require("mkdirp")
var rimraf = require("rimraf")
+var path = require("path")
var mr = require("npm-registry-mock")
-var pkg = __dirname + "/outdated-new-versions"
-mkdirp.sync(pkg + "/cache")
+var pkg = path.resolve(__dirname, "outdated-new-versions")
+var cache = path.resolve(pkg, "cache")
+mkdirp.sync(cache)
test("dicovers new versions in outdated", function (t) {
@@ -15,7 +17,7 @@
t.plan(2)
mr(common.port, function (s) {
- npm.load({cache: pkg + "/cache", registry: common.registry}, function () {
+ npm.load({cache: cache, registry: common.registry}, function () {
npm.outdated(function (er, d) {
for (var i = 0; i < d.length; i++) {
if (d[i][1] === "underscore")
@@ -31,6 +33,6 @@
})
test("cleanup", function (t) {
- rimraf.sync(pkg + "/cache")
+ rimraf.sync(cache)
t.end()
})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/outdated-notarget.js nodejs-0.11.15/deps/npm/test/tap/outdated-notarget.js
--- nodejs-0.11.14/deps/npm/test/tap/outdated-notarget.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/outdated-notarget.js 2015-01-20 21:22:17.000000000 +0000
@@ -11,12 +11,12 @@
var cache = path.resolve(pkg, "cache")
var mr = require("npm-registry-mock")
-test("outdated-target: if no viable version is found, show error", function(t) {
+test("outdated-target: if no viable version is found, show error", function (t) {
t.plan(1)
setup()
- mr({port: common.port}, function(s) {
- npm.load({ cache: cache, registry: common.registry}, function() {
- npm.commands.update(function(er) {
+ mr({port: common.port}, function (s) {
+ npm.load({ cache: cache, registry: common.registry}, function () {
+ npm.commands.update(function (er) {
t.equal(er.code, "ETARGET")
s.close()
t.end()
@@ -25,7 +25,7 @@
})
})
-test("cleanup", function(t) {
+test("cleanup", function (t) {
process.chdir(osenv.tmpdir())
rimraf.sync(pkg)
t.end()
diff -Nru nodejs-0.11.14/deps/npm/test/tap/pack-scoped.js nodejs-0.11.15/deps/npm/test/tap/pack-scoped.js
--- nodejs-0.11.14/deps/npm/test/tap/pack-scoped.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/pack-scoped.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,10 +1,10 @@
// verify that prepublish runs on pack and publish
var test = require("tap").test
+var common = require("../common-tap")
var fs = require("graceful-fs")
var join = require("path").join
var mkdirp = require("mkdirp")
var rimraf = require("rimraf")
-var path = require("path")
var pkg = join(__dirname, "scoped_package")
var manifest = join(pkg, "package.json")
@@ -19,6 +19,8 @@
test("setup", function (t) {
var n = 0
+ rimraf.sync(pkg)
+
mkdirp(pkg, then())
mkdirp(cache, then())
mkdirp(tmp, then())
@@ -26,7 +28,7 @@
function then () {
n++
return function (er) {
- if (er) throw er
+ t.ifError(er)
if (--n === 0) next()
}
}
@@ -36,7 +38,7 @@
}
function done (er) {
- if (er) throw er
+ t.ifError(er)
t.pass("setup done")
t.end()
@@ -44,9 +46,6 @@
})
test("test", function (t) {
- var spawn = require("child_process").spawn
- var node = process.execPath
- var npm = path.resolve(__dirname, "../../cli.js")
var env = {
"npm_config_cache" : cache,
"npm_config_tmp" : tmp,
@@ -58,34 +57,25 @@
if (!/^npm_config_/.test(i)) env[i] = process.env[i]
}
- var child = spawn(node, [npm, "pack"], {cwd : pkg, env : env})
-
- child.stdout.setEncoding("utf8")
- child.stderr.on("data", onerr)
- child.stdout.on("data", ondata)
- child.on("close", onend)
-
- var c = "", e = ""
- function ondata (chunk) { c += chunk }
- function onerr (chunk) { e += chunk }
-
- function onend () {
- if (e) {
- throw new Error("got stderr data: " + JSON.stringify("" + e))
- }
- c = c.trim()
+ common.npm([
+ "pack",
+ "--loglevel", "warn"
+ ], {
+ cwd: pkg,
+ env: env
+ }, function(err, code, stdout, stderr) {
+ t.ifErr(err, "npm pack finished without error")
+ t.equal(code, 0, "npm pack exited ok")
+ t.notOk(stderr, "got stderr data: " + JSON.stringify("" + stderr))
+ stdout = stdout.trim()
var regex = new RegExp("scope-generic-package-90000.100001.5.tgz", "ig")
-
- t.ok(c.match(regex), "found package")
+ t.ok(stdout.match(regex), "found package")
t.end()
- }
+ })
})
test("cleanup", function (t) {
- rimraf(pkg, function (er) {
- if (er) throw er
-
- t.pass("cleaned up")
- t.end()
- })
+ rimraf.sync(pkg)
+ t.pass("cleaned up")
+ t.end()
})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/peer-deps-invalid.js nodejs-0.11.15/deps/npm/test/tap/peer-deps-invalid.js
--- nodejs-0.11.14/deps/npm/test/tap/peer-deps-invalid.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/peer-deps-invalid.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,18 +1,20 @@
-var common = require('../common-tap.js')
+var common = require("../common-tap")
var fs = require("fs")
var path = require("path")
var test = require("tap").test
var rimraf = require("rimraf")
var npm = require("../../")
var mr = require("npm-registry-mock")
-var pkg = __dirname + "/peer-deps-invalid"
+var pkg = path.resolve(__dirname, "peer-deps-invalid")
+var cache = path.resolve(pkg, "cache")
+var nodeModules = path.resolve(pkg, "node_modules")
var okFile = fs.readFileSync(path.join(pkg, "file-ok.js"), "utf8")
var failFile = fs.readFileSync(path.join(pkg, "file-fail.js"), "utf8")
test("installing dependencies that have conflicting peerDependencies", function (t) {
- rimraf.sync(pkg + "/node_modules")
- rimraf.sync(pkg + "/cache")
+ rimraf.sync(nodeModules)
+ rimraf.sync(cache)
process.chdir(pkg)
var customMocks = {
@@ -23,7 +25,7 @@
}
mr({port: common.port, mocks: customMocks}, function (s) { // create mock registry.
npm.load({
- cache: pkg + "/cache",
+ cache: cache,
registry: common.registry
}, function () {
npm.commands.install([], function (err) {
@@ -40,7 +42,7 @@
})
test("cleanup", function (t) {
- rimraf.sync(pkg + "/node_modules")
- rimraf.sync(pkg + "/cache")
+ rimraf.sync(nodeModules)
+ rimraf.sync(cache)
t.end()
})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/peer-deps.js nodejs-0.11.15/deps/npm/test/tap/peer-deps.js
--- nodejs-0.11.14/deps/npm/test/tap/peer-deps.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/peer-deps.js 2015-01-20 21:22:17.000000000 +0000
@@ -11,8 +11,6 @@
var desiredResultsPath = path.resolve(pkg, "desired-ls-results.json")
test("installs the peer dependency directory structure", function (t) {
- t.plan(1)
-
mr(common.port, function (s) {
setup(function (err) {
if (err) return t.fail(err)
@@ -46,7 +44,7 @@
cleanup()
process.chdir(pkg)
- var opts = { cache: path.resolve(pkg, "cache"), registry: common.registry};
+ var opts = { cache: path.resolve(pkg, "cache"), registry: common.registry}
npm.load(opts, cb)
}
diff -Nru nodejs-0.11.14/deps/npm/test/tap/peer-deps-toplevel/desired-ls-results.json nodejs-0.11.15/deps/npm/test/tap/peer-deps-toplevel/desired-ls-results.json
--- nodejs-0.11.14/deps/npm/test/tap/peer-deps-toplevel/desired-ls-results.json 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/peer-deps-toplevel/desired-ls-results.json 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,20 @@
+{
+ "name": "npm-test-peer-deps-toplevel",
+ "version": "0.0.0",
+ "dependencies": {
+ "npm-test-peer-deps": {
+ "version": "0.0.0",
+ "dependencies": {
+ "underscore": {
+ "version": "1.3.1"
+ }
+ }
+ },
+ "mkdirp": {
+ "version": "0.3.5"
+ },
+ "request": {
+ "version": "0.9.5"
+ }
+ }
+}
diff -Nru nodejs-0.11.14/deps/npm/test/tap/peer-deps-toplevel/package.json nodejs-0.11.15/deps/npm/test/tap/peer-deps-toplevel/package.json
--- nodejs-0.11.14/deps/npm/test/tap/peer-deps-toplevel/package.json 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/peer-deps-toplevel/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,11 @@
+{
+ "author": "Domenic Denicola",
+ "name": "npm-test-peer-deps-toplevel",
+ "version": "0.0.0",
+ "dependencies": {
+ "npm-test-peer-deps": "*"
+ },
+ "peerDependencies": {
+ "mkdirp": "*"
+ }
+}
diff -Nru nodejs-0.11.14/deps/npm/test/tap/peer-deps-toplevel.js nodejs-0.11.15/deps/npm/test/tap/peer-deps-toplevel.js
--- nodejs-0.11.14/deps/npm/test/tap/peer-deps-toplevel.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/peer-deps-toplevel.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,55 @@
+var npm = npm = require("../../")
+var test = require("tap").test
+var path = require("path")
+var fs = require("fs")
+var osenv = require("osenv")
+var rimraf = require("rimraf")
+var mr = require("npm-registry-mock")
+var common = require("../common-tap.js")
+
+var pkg = path.resolve(__dirname, "peer-deps-toplevel")
+var desiredResultsPath = path.resolve(pkg, "desired-ls-results.json")
+
+test("installs the peer dependency directory structure", function (t) {
+ mr(common.port, function (s) {
+ setup(function (err) {
+ t.ifError(err, "setup ran successfully")
+
+ npm.install(".", function (err) {
+ t.ifError(err, "packages were installed")
+
+ npm.commands.ls([], true, function (err, _, results) {
+ t.ifError(err, "listed tree without problems")
+
+ fs.readFile(desiredResultsPath, function (err, desired) {
+ t.ifError(err, "read desired results")
+
+ t.deepEqual(results, JSON.parse(desired), "got expected output from ls")
+ s.close()
+ t.end()
+ })
+ })
+ })
+ })
+ })
+})
+
+test("cleanup", function (t) {
+ cleanup()
+ t.end()
+})
+
+
+function setup (cb) {
+ cleanup()
+ process.chdir(pkg)
+
+ var opts = { cache: path.resolve(pkg, "cache"), registry: common.registry}
+ npm.load(opts, cb)
+}
+
+function cleanup () {
+ process.chdir(osenv.tmpdir())
+ rimraf.sync(path.resolve(pkg, "node_modules"))
+ rimraf.sync(path.resolve(pkg, "cache"))
+}
diff -Nru nodejs-0.11.14/deps/npm/test/tap/peer-deps-without-package-json.js nodejs-0.11.15/deps/npm/test/tap/peer-deps-without-package-json.js
--- nodejs-0.11.14/deps/npm/test/tap/peer-deps-without-package-json.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/peer-deps-without-package-json.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,37 +1,39 @@
-var common = require('../common-tap.js')
+var common = require("../common-tap")
var fs = require("fs")
var path = require("path")
var test = require("tap").test
var rimraf = require("rimraf")
var npm = require("../../")
var mr = require("npm-registry-mock")
-var pkg = __dirname + "/peer-deps-without-package-json"
+var pkg = path.resolve(__dirname, "peer-deps-without-package-json")
+var cache = path.resolve(pkg, "cache")
+var nodeModules = path.resolve(pkg, "node_modules")
var js = fs.readFileSync(path.join(pkg, "file-js.js"), "utf8")
test("installing a peerDependencies-using package without a package.json present (GH-3049)", function (t) {
- rimraf.sync(pkg + "/node_modules")
- rimraf.sync(pkg + "/cache")
+ rimraf.sync(nodeModules)
+ rimraf.sync(cache)
- fs.mkdirSync(pkg + "/node_modules")
+ fs.mkdirSync(nodeModules)
process.chdir(pkg)
var customMocks = {
"get": {
- "/ok.js": [200, js],
+ "/ok.js": [200, js]
}
}
mr({port: common.port, mocks: customMocks}, function (s) { // create mock registry.
npm.load({
registry: common.registry,
- cache: pkg + "/cache"
+ cache: cache
}, function () {
npm.install(common.registry + "/ok.js", function (err) {
if (err) {
t.fail(err)
} else {
- t.ok(fs.existsSync(pkg + "/node_modules/npm-test-peer-deps-file"))
- t.ok(fs.existsSync(pkg + "/node_modules/underscore"))
+ t.ok(fs.existsSync(path.join(nodeModules, "/npm-test-peer-deps-file")))
+ t.ok(fs.existsSync(path.join(nodeModules, "/underscore")))
}
t.end()
s.close() // shutdown mock registry.
@@ -41,7 +43,7 @@
})
test("cleanup", function (t) {
- rimraf.sync(pkg + "/node_modules")
- rimraf.sync(pkg + "/cache")
+ rimraf.sync(nodeModules)
+ rimraf.sync(cache)
t.end()
})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/prepublish.js nodejs-0.11.15/deps/npm/test/tap/prepublish.js
--- nodejs-0.11.14/deps/npm/test/tap/prepublish.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/prepublish.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,10 +1,10 @@
// verify that prepublish runs on pack and publish
+var common = require("../common-tap")
var test = require("tap").test
var fs = require("graceful-fs")
var join = require("path").join
var mkdirp = require("mkdirp")
var rimraf = require("rimraf")
-var path = require("path")
var pkg = join(__dirname, "prepublish_package")
var tmp = join(pkg, "tmp")
@@ -12,6 +12,7 @@
test("setup", function (t) {
var n = 0
+ cleanup()
mkdirp(pkg, then())
mkdirp(cache, then())
mkdirp(tmp, then())
@@ -38,9 +39,6 @@
})
test("test", function (t) {
- var spawn = require("child_process").spawn
- var node = process.execPath
- var npm = path.resolve(__dirname, "../../cli.js")
var env = {
"npm_config_cache" : cache,
"npm_config_tmp" : tmp,
@@ -51,27 +49,16 @@
if (!/^npm_config_/.test(i))
env[i] = process.env[i]
}
- var child = spawn(node, [npm, "pack"], {
- cwd: pkg,
- env: env
- })
- child.stdout.setEncoding("utf8")
- child.stderr.on("data", onerr)
- child.stdout.on("data", ondata)
- child.on("close", onend)
- var c = ""
- , e = ""
- function ondata (chunk) {
- c += chunk
- }
- function onerr (chunk) {
- e += chunk
- }
- function onend () {
- if (e) {
- throw new Error("got stderr data: " + JSON.stringify("" + e))
- }
- c = c.trim()
+
+ common.npm([
+ "pack",
+ "--loglevel", "warn"
+ ], { cwd: pkg, env: env }, function(err, code, stdout, stderr) {
+ t.equal(code, 0, "pack finished successfully")
+ t.ifErr(err, "pack finished successfully")
+
+ t.notOk(stderr, "got stderr data:" + JSON.stringify("" + stderr))
+ var c = stdout.trim()
var regex = new RegExp("" +
"> npm-test-prepublish@1.2.5 prepublish [^\\r\\n]+\\r?\\n" +
"> echo ok\\r?\\n" +
@@ -81,14 +68,15 @@
t.ok(c.match(regex))
t.end()
- }
+ })
})
test("cleanup", function (t) {
- rimraf(pkg, function (er) {
- if (er) throw er
-
- t.pass("cleaned up")
- t.end()
- })
+ cleanup()
+ t.pass("cleaned up")
+ t.end()
})
+
+function cleanup() {
+ rimraf.sync(pkg)
+}
diff -Nru nodejs-0.11.14/deps/npm/test/tap/prune.js nodejs-0.11.15/deps/npm/test/tap/prune.js
--- nodejs-0.11.14/deps/npm/test/tap/prune.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/prune.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,16 +1,17 @@
var test = require("tap").test
+var common = require("../common-tap")
var fs = require("fs")
-var node = process.execPath
-var npm = require.resolve("../../bin/npm-cli.js")
var rimraf = require("rimraf")
var mr = require("npm-registry-mock")
-var common = require("../common-tap.js")
-var spawn = require("child_process").spawn
var env = process.env
-process.env.npm_config_depth = "Infinity"
+var path = require("path")
-var pkg = __dirname + "/prune"
-var cache = pkg + "/cache"
+var pkg = path.resolve(__dirname, "prune")
+var cache = path.resolve(pkg, "cache")
+var nodeModules = path.resolve(pkg, "node_modules")
+
+var EXEC_OPTS = { cwd: pkg, env: env }
+EXEC_OPTS.env.npm_config_depth = "Infinity"
var server
@@ -22,38 +23,43 @@
})
})
+function cleanup () {
+ rimraf.sync(cache)
+ rimraf.sync(nodeModules)
+}
+
+test("setup", function (t) {
+ cleanup()
+ t.pass("setup")
+ t.end()
+})
test("npm install", function (t) {
- rimraf.sync(pkg + "/node_modules")
- var c = spawn(node, [
- npm, "install",
- "--cache=" + cache,
- "--registry=" + common.registry,
- "--loglevel=silent",
- "--production=false"
- ], { cwd: pkg, env: env })
- c.stderr.on("data", function(d) {
- t.fail("Should not get data on stderr: " + d)
- })
- c.on("close", function(code) {
+ common.npm([
+ "install",
+ "--cache", cache,
+ "--registry", common.registry,
+ "--loglevel", "silent",
+ "--production", "false"
+ ], EXEC_OPTS, function (err, code, stdout, stderr) {
+ t.ifErr(err, "install finished successfully")
t.notOk(code, "exit ok")
+ t.notOk(stderr, "Should not get data on stderr: " + stderr)
t.end()
})
})
test("npm install test-package", function (t) {
- var c = spawn(node, [
- npm, "install", "test-package",
- "--cache=" + cache,
- "--registry=" + common.registry,
- "--loglevel=silent",
- "--production=false"
- ], { cwd: pkg, env: env })
- c.stderr.on("data", function(d) {
- t.fail("Should not get data on stderr: " + d)
- })
- c.on("close", function(code) {
+ common.npm([
+ "install", "test-package",
+ "--cache", cache,
+ "--registry", common.registry,
+ "--loglevel", "silent",
+ "--production", "false"
+ ], EXEC_OPTS, function (err, code, stdout, stderr) {
+ t.ifErr(err, "install finished successfully")
t.notOk(code, "exit ok")
+ t.notOk(stderr, "Should not get data on stderr: " + stderr)
t.end()
})
})
@@ -65,16 +71,14 @@
})
test("npm prune", function (t) {
- var c = spawn(node, [
- npm, "prune",
- "--loglevel=silent",
- "--production=false"
- ], { cwd: pkg, env: env })
- c.stderr.on("data", function(d) {
- t.fail("Should not get data on stderr: " + d)
- })
- c.on("close", function(code) {
+ common.npm([
+ "prune",
+ "--loglevel", "silent",
+ "--production", "false"
+ ], EXEC_OPTS, function (err, code, stdout, stderr) {
+ t.ifErr(err, "prune finished successfully")
t.notOk(code, "exit ok")
+ t.notOk(stderr, "Should not get data on stderr: " + stderr)
t.end()
})
})
@@ -86,16 +90,14 @@
})
test("npm prune", function (t) {
- var c = spawn(node, [
- npm, "prune",
- "--loglevel=silent",
+ common.npm([
+ "prune",
+ "--loglevel", "silent",
"--production"
- ], { cwd: pkg, env: env })
- c.stderr.on("data", function(d) {
- t.fail("Should not get data on stderr: " + d)
- })
- c.on("close", function(code) {
+ ], EXEC_OPTS, function (err, code, stderr) {
+ t.ifErr(err, "prune finished successfully")
t.notOk(code, "exit ok")
+ t.equal(stderr, "unbuild mkdirp@0.3.5\n")
t.end()
})
})
@@ -108,8 +110,7 @@
test("cleanup", function (t) {
server.close()
- rimraf.sync(pkg + "/node_modules")
- rimraf.sync(pkg + "/cache")
+ cleanup()
t.pass("cleaned up")
t.end()
})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/publish-config.js nodejs-0.11.15/deps/npm/test/tap/publish-config.js
--- nodejs-0.11.14/deps/npm/test/tap/publish-config.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/publish-config.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,11 +1,11 @@
-var common = require('../common-tap.js')
-var test = require('tap').test
-var fs = require('fs')
-var osenv = require('osenv')
-var pkg = process.env.npm_config_tmp || '/tmp'
-pkg += '/npm-test-publish-config'
+var common = require("../common-tap.js")
+var test = require("tap").test
+var fs = require("fs")
+var osenv = require("osenv")
+var pkg = process.env.npm_config_tmp || "/tmp"
+pkg += "/npm-test-publish-config"
-require('mkdirp').sync(pkg)
+require("mkdirp").sync(pkg)
fs.writeFileSync(pkg + "/package.json", JSON.stringify({
name: "npm-test-publish-config",
@@ -19,21 +19,19 @@
"//localhost:1337/:_password = " + new Buffer("feast").toString("base64") + "\n" +
"registry = http://localhost:1337/")
-var spawn = require('child_process').spawn
-var npm = require.resolve('../../bin/npm-cli.js')
-var node = process.execPath
-
test(function (t) {
var child
- require('http').createServer(function (req, res) {
- t.pass('got request on the fakey fake registry')
+ require("http").createServer(function (req, res) {
+ t.pass("got request on the fakey fake registry")
t.end()
this.close()
res.statusCode = 500
- res.end('{"error":"sshhh. naptime nao. \\^O^/ <(YAWWWWN!)"}')
+ res.end(JSON.stringify({
+ error: "sshhh. naptime nao. \\^O^/ <(YAWWWWN!)"
+ }))
child.kill()
}).listen(common.port, function () {
- t.pass('server is listening')
+ t.pass("server is listening")
// don't much care about listening to the child's results
// just wanna make sure it hits the server we just set up.
@@ -42,17 +40,20 @@
// itself functions normally.
//
// Make sure that we don't sit around waiting for lock files
- child = spawn(node, [npm, "publish", "--userconfig=" + pkg + "/fixture_npmrc"], {
+ child = common.npm(["publish", "--userconfig=" + pkg + "/fixture_npmrc"], {
cwd: pkg,
stdio: "inherit",
env: {
- npm_config_cache_lock_stale: 1000,
- npm_config_cache_lock_wait: 1000,
+ "npm_config_cache_lock_stale": 1000,
+ "npm_config_cache_lock_wait": 1000,
HOME: process.env.HOME,
Path: process.env.PATH,
PATH: process.env.PATH,
USERPROFILE: osenv.home()
}
+ }, function (err, code) {
+ t.ifError(err, "publish command finished successfully")
+ t.notOk(code, "npm install exited with code 0")
})
})
})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/publish-scoped.js nodejs-0.11.15/deps/npm/test/tap/publish-scoped.js
--- nodejs-0.11.14/deps/npm/test/tap/publish-scoped.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/publish-scoped.js 2015-01-20 21:22:17.000000000 +0000
@@ -11,6 +11,14 @@
var pkg = path.join(__dirname, "prepublish_package")
+// TODO: nock uses setImmediate, breaks 0.8: replace with mockRegistry
+if (!global.setImmediate) {
+ global.setImmediate = function () {
+ var args = [arguments[0], 0].concat([].slice.call(arguments, 1))
+ setTimeout.apply(this, args)
+ }
+}
+
test("setup", function (t) {
mkdirp(path.join(pkg, "cache"), next)
@@ -34,7 +42,9 @@
})
test("npm publish should honor scoping", function (t) {
- var put = nock(common.registry).put("/@bigco%2fpublish-organized").reply(201, {ok: true})
+ var put = nock(common.registry)
+ .put("/@bigco%2fpublish-organized")
+ .reply(201, verify)
var configuration = {
cache : path.join(pkg, "cache"),
@@ -59,9 +69,29 @@
t.end()
})
}
+
+ function verify (_, body) {
+ t.doesNotThrow(function () {
+ var parsed = JSON.parse(body)
+ var current = parsed.versions["1.2.5"]
+ t.equal(
+ current._npmVersion,
+ require(path.resolve(__dirname, "../../package.json")).version,
+ "npm version is correct"
+ )
+
+ t.equal(
+ current._nodeVersion,
+ process.versions.node,
+ "node version is correct"
+ )
+ }, "converted body back into object")
+
+ return {ok: true}
+ }
})
-test("cleanup", function(t) {
+test("cleanup", function (t) {
process.chdir(__dirname)
rimraf(pkg, function (er) {
t.ifError(er)
diff -Nru nodejs-0.11.14/deps/npm/test/tap/pwd-prefix.js nodejs-0.11.15/deps/npm/test/tap/pwd-prefix.js
--- nodejs-0.11.14/deps/npm/test/tap/pwd-prefix.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/pwd-prefix.js 2015-01-20 21:22:17.000000000 +0000
@@ -14,9 +14,9 @@
var stdout, stderr
test(cmd + " in root", function (t) {
- common.npm([cmd], {cwd: root}, function(er, code, so, se) {
+ common.npm([cmd], {cwd: root}, function (er, code, so, se) {
if (er) throw er
- t.equal(code, 0)
+ t.notOk(code, "npm " + cmd + " exited with code 0")
stdout = so
stderr = se
t.end()
@@ -24,9 +24,9 @@
})
test(cmd + " in lib", function (t) {
- common.npm([cmd], {cwd: lib}, function(er, code, so, se) {
+ common.npm([cmd], {cwd: lib}, function (er, code, so, se) {
if (er) throw er
- t.equal(code, 0)
+ t.notOk(code, "npm " + cmd + " exited with code 0")
t.equal(so, stdout)
t.equal(se, stderr)
t.end()
diff -Nru nodejs-0.11.14/deps/npm/test/tap/referer.js nodejs-0.11.15/deps/npm/test/tap/referer.js
--- nodejs-0.11.14/deps/npm/test/tap/referer.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/referer.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,18 +1,17 @@
var common = require("../common-tap.js")
var test = require("tap").test
var http = require("http")
-var server
test("should send referer http header", function (t) {
- var server = http.createServer(function (q, s) {
+ http.createServer(function (q, s) {
t.equal(q.headers.referer, "install foo")
s.statusCode = 404
s.end(JSON.stringify({error: "whatever"}))
this.close()
}).listen(common.port, function () {
- var reg = "--registry=http://localhost:" + common.port
- var args = [ "install", "foo", reg ]
- common.npm(args, {}, function (er, code, so, se) {
+ var reg = "http://localhost:" + common.port
+ var args = [ "install", "foo", "--registry", reg ]
+ common.npm(args, {}, function (er, code) {
if (er) {
throw er
}
diff -Nru nodejs-0.11.14/deps/npm/test/tap/registry.js nodejs-0.11.15/deps/npm/test/tap/registry.js
--- nodejs-0.11.14/deps/npm/test/tap/registry.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/registry.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,63 +1,75 @@
// Run all the tests in the `npm-registry-couchapp` suite
// This verifies that the server-side stuff still works.
+var common = require("../common-tap")
var test = require("tap").test
-var spawn = require("child_process").spawn
var npmExec = require.resolve("../../bin/npm-cli.js")
var path = require("path")
var ca = path.resolve(__dirname, "../../node_modules/npm-registry-couchapp")
var which = require("which")
-which("couchdb", function(er, couch) {
- if (er) {
- return test("need couchdb", function (t) {
- t.fail("need couch to run test: " + er.message)
- t.end()
- })
- } else {
- runTests()
- }
-})
+var v = process.versions.node.split(".").map(function (n) { return parseInt(n, 10) })
+if (v[0] === 0 && v[1] < 10) {
+ console.error(
+ "WARNING: need a recent Node for npm-registry-couchapp tests to run, have",
+ process.versions.node
+ )
+}
+else {
+ which("couchdb", function (er) {
+ if (er) {
+ console.error("WARNING: need couch to run test: " + er.message)
+ }
+ else {
+ runTests()
+ }
+ })
+}
+
function runTests () {
var env = {}
for (var i in process.env) env[i] = process.env[i]
env.npm = npmExec
- spawn(process.execPath, [
- npmExec, "install"
- ], {
+ var opts = {
cwd: ca,
stdio: "inherit"
- }).on("close", function (code, sig) {
- if (code || sig) {
+ }
+ common.npm(["install"], opts, function (err, code) {
+ if (err) { throw err }
+ if (code) {
return test("need install to work", function (t) {
- t.fail("install failed with: " + (code || sig))
+ t.fail("install failed with: " + code)
t.end()
})
} else {
-
- spawn(process.execPath, [
- npmExec, "test"
- ], {
+ opts = {
cwd: ca,
env: env,
stdio: "inherit"
- }).on("close", function (code, sig) {
- spawn(process.execPath, [
- npmExec, "prune", "--production"
- ], {
+ }
+ common.npm(["test"], opts, function (err, code) {
+ if (err) { throw err }
+ if (code) {
+ return test("need test to work", function (t) {
+ t.fail("test failed with: " + code)
+ t.end()
+ })
+ }
+ opts = {
cwd: ca,
env: env,
stdio: "inherit"
- }).on("close", function (code2, sig2) {
- process.exit(code || code2 || 0)
+ }
+ common.npm(["prune", "--production"], opts, function (err, code) {
+ if (err) { throw err }
+ process.exit(code || 0)
})
})
}
-
})
}
diff -Nru nodejs-0.11.14/deps/npm/test/tap/repo.js nodejs-0.11.15/deps/npm/test/tap/repo.js
--- nodejs-0.11.14/deps/npm/test/tap/repo.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/repo.js 2015-01-20 21:22:17.000000000 +0000
@@ -33,7 +33,7 @@
'--registry=' + common.registry,
'--loglevel=silent',
'--browser=' + __dirname + '/_script.sh'
- ], opts, function(err, code, stdout, stderr) {
+ ], opts, function (err, code, stdout, stderr) {
t.equal(code, 0, 'exit ok')
var res = fs.readFileSync(outFile, 'ascii')
s.close()
@@ -52,7 +52,7 @@
'--registry=' + common.registry,
'--loglevel=silent',
'--browser=' + __dirname + '/_script.sh'
- ], opts, function(err, code, stdout, stderr) {
+ ], opts, function (err, code, stdout, stderr) {
t.equal(code, 0, 'exit ok')
var res = fs.readFileSync(outFile, 'ascii')
s.close()
@@ -70,7 +70,7 @@
'--registry=' + common.registry,
'--loglevel=silent',
'--browser=' + __dirname + '/_script.sh'
- ], opts, function(err, code, stdout, stderr) {
+ ], opts, function (err, code, stdout, stderr) {
t.equal(code, 1, 'exit not ok')
s.close()
t.end()
@@ -85,7 +85,7 @@
'--registry=' + common.registry,
'--loglevel=silent',
'--browser=' + __dirname + '/_script.sh'
- ], opts, function(err, code, stdout, stderr) {
+ ], opts, function (err, code, stdout, stderr) {
t.equal(code, 0, 'exit ok')
var res = fs.readFileSync(outFile, 'ascii')
s.close()
@@ -103,7 +103,7 @@
'--registry=' + common.registry,
'--loglevel=silent',
'--browser=' + __dirname + '/_script.sh'
- ], opts, function(err, code, stdout, stderr) {
+ ], opts, function (err, code, stdout, stderr) {
t.equal(code, 0, 'exit ok')
var res = fs.readFileSync(outFile, 'ascii')
s.close()
@@ -121,7 +121,7 @@
'--registry=' + common.registry,
'--loglevel=silent',
'--browser=' + __dirname + '/_script.sh'
- ], opts, function(err, code, stdout, stderr) {
+ ], opts, function (err, code, stdout, stderr) {
t.equal(code, 0, 'exit ok')
var res = fs.readFileSync(outFile, 'ascii')
s.close()
diff -Nru nodejs-0.11.14/deps/npm/test/tap/run-script/package.json nodejs-0.11.15/deps/npm/test/tap/run-script/package.json
--- nodejs-0.11.14/deps/npm/test/tap/run-script/package.json 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/run-script/package.json 2015-01-20 21:22:17.000000000 +0000
@@ -1,6 +1,13 @@
{"name":"runscript"
,"version":"1.2.3"
,"scripts":{
- "start":"node -e 'console.log(process.argv[1] || \"start\")'"
+ "start":"node -e 'console.log(process.argv[1] || \"start\")'",
+ "prewith-pre":"node -e 'console.log(process.argv[1] || \"pre\")'",
+ "with-pre":"node -e 'console.log(process.argv[1] || \"main\")'",
+ "with-post":"node -e 'console.log(process.argv[1] || \"main\")'",
+ "postwith-post":"node -e 'console.log(process.argv[1] || \"post\")'",
+ "prewith-both":"node -e 'console.log(process.argv[1] || \"pre\")'",
+ "with-both":"node -e 'console.log(process.argv[1] || \"main\")'",
+ "postwith-both":"node -e 'console.log(process.argv[1] || \"post\")'"
}
}
diff -Nru nodejs-0.11.14/deps/npm/test/tap/run-script.js nodejs-0.11.15/deps/npm/test/tap/run-script.js
--- nodejs-0.11.14/deps/npm/test/tap/run-script.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/run-script.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,62 +1,84 @@
-var common = require('../common-tap')
- , test = require('tap').test
- , path = require('path')
- , spawn = require('child_process').spawn
- , rimraf = require('rimraf')
- , mkdirp = require('mkdirp')
- , pkg = __dirname + '/run-script'
- , cache = pkg + '/cache'
- , tmp = pkg + '/tmp'
- , node = process.execPath
- , npm = path.resolve(__dirname, '../../cli.js')
+var common = require("../common-tap")
+ , test = require("tap").test
+ , path = require("path")
+ , rimraf = require("rimraf")
+ , mkdirp = require("mkdirp")
+ , pkg = path.resolve(__dirname, "run-script")
+ , cache = path.resolve(pkg, "cache")
+ , tmp = path.resolve(pkg, "tmp")
, opts = { cwd: pkg }
function testOutput (t, command, er, code, stdout, stderr) {
+ var lines
+
if (er)
throw er
if (stderr)
- throw new Error('npm ' + command + ' stderr: ' + stderr.toString())
+ throw new Error("npm " + command + " stderr: " + stderr.toString())
+
+ lines = stdout.trim().split("\n")
+ stdout = lines.filter(function(line) {
+ return line.trim() !== "" && line[0] !== '>'
+ }).join(';')
- stdout = stdout.trim().split('\n')
- stdout = stdout[stdout.length - 1]
t.equal(stdout, command)
t.end()
}
function cleanup () {
- rimraf.sync(pkg + '/cache')
- rimraf.sync(pkg + '/tmp')
+ rimraf.sync(cache)
+ rimraf.sync(tmp)
}
-test('setup', function (t) {
+test("setup", function (t) {
cleanup()
- mkdirp.sync(pkg + '/cache')
- mkdirp.sync(pkg + '/tmp')
+ mkdirp.sync(cache)
+ mkdirp.sync(tmp)
t.end()
})
-test('npm run-script', function (t) {
- common.npm(['run-script', 'start'], opts, testOutput.bind(null, t, "start"))
+test("npm run-script", function (t) {
+ common.npm(["run-script", "start"], opts, testOutput.bind(null, t, "start"))
})
-test('npm run-script with args', function (t) {
+test("npm run-script with args", function (t) {
common.npm(["run-script", "start", "--", "stop"], opts, testOutput.bind(null, t, "stop"))
})
-test('npm run-script with args that contain spaces', function(t) {
+test("npm run-script with args that contain spaces", function (t) {
common.npm(["run-script", "start", "--", "hello world"], opts, testOutput.bind(null, t, "hello world"))
})
-test('npm run-script with args that contain single quotes', function(t) {
+test("npm run-script with args that contain single quotes", function (t) {
common.npm(["run-script", "start", "--", "they're awesome"], opts, testOutput.bind(null, t, "they're awesome"))
})
-test('npm run-script with args that contain double quotes', function(t) {
+test("npm run-script with args that contain double quotes", function (t) {
common.npm(["run-script", "start", "--", "what's \"up\"?"], opts, testOutput.bind(null, t, "what's \"up\"?"))
})
-test('cleanup', function (t) {
+test("npm run-script with pre script", function (t) {
+ common.npm(["run-script", "with-post"], opts, testOutput.bind(null, t, "main;post"))
+})
+
+test("npm run-script with post script", function (t) {
+ common.npm(["run-script", "with-pre"], opts, testOutput.bind(null, t, "pre;main"))
+})
+
+test("npm run-script with both pre and post script", function (t) {
+ common.npm(["run-script", "with-both"], opts, testOutput.bind(null, t, "pre;main;post"))
+})
+
+test("npm run-script with both pre and post script and with args", function (t) {
+ common.npm(["run-script", "with-both", "--", "an arg"], opts, testOutput.bind(null, t, "pre;an arg;post"))
+})
+
+test("npm run-script explicitly call pre script with arg", function (t) {
+ common.npm(["run-script", "prewith-pre", "--", "an arg"], opts, testOutput.bind(null, t, "an arg"))
+})
+
+test("cleanup", function (t) {
cleanup()
t.end()
})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/scripts-whitespace-windows.js nodejs-0.11.15/deps/npm/test/tap/scripts-whitespace-windows.js
--- nodejs-0.11.14/deps/npm/test/tap/scripts-whitespace-windows.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/scripts-whitespace-windows.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,71 +1,54 @@
-var test = require('tap').test
-var path = require('path')
-var npm = path.resolve(__dirname, '../../cli.js')
-var pkg = __dirname + '/scripts-whitespace-windows'
-var tmp = pkg + '/tmp'
-var cache = pkg + '/cache'
-var modules = pkg + '/node_modules'
-var dep = pkg + '/dep'
-
-var mkdirp = require('mkdirp')
-var rimraf = require('rimraf')
-var node = process.execPath
-var spawn = require('child_process').spawn
+var test = require("tap").test
+var common = require("../common-tap")
+var path = require("path")
+var pkg = path.resolve(__dirname, "scripts-whitespace-windows")
+var tmp = path.resolve(pkg, "tmp")
+var cache = path.resolve(pkg, "cache")
+var modules = path.resolve(pkg, "node_modules")
+var dep = path.resolve(pkg, "dep")
-test('setup', function (t) {
+var mkdirp = require("mkdirp")
+var rimraf = require("rimraf")
+
+test("setup", function (t) {
+ cleanup()
mkdirp.sync(cache)
mkdirp.sync(tmp)
- rimraf.sync(modules)
- var env = {
- npm_config_cache: cache,
- npm_config_tmp: tmp,
- npm_config_prefix: pkg,
- npm_config_global: 'false'
- }
-
- var child = spawn(node, [npm, 'i', dep], {
+ common.npm(["i", dep], {
cwd: pkg,
- env: env
- })
-
- child.stdout.setEncoding('utf8')
- child.stderr.on('data', function(chunk) {
- throw new Error('got stderr data: ' + JSON.stringify('' + chunk))
- })
- child.on('close', function () {
+ env: {
+ "npm_config_cache": cache,
+ "npm_config_tmp": tmp,
+ "npm_config_prefix": pkg,
+ "npm_config_global": "false"
+ }
+ }, function (err, code, stdout, stderr) {
+ t.ifErr(err, "npm i " + dep + " finished without error")
+ t.equal(code, 0, "npm i " + dep + " exited ok")
+ t.notOk(stderr, "no output stderr")
t.end()
})
})
-test('test', function (t) {
-
- var child = spawn(node, [npm, 'run', 'foo'], {
- cwd: pkg,
- env: process.env
- })
-
- child.stdout.setEncoding('utf8')
- child.stderr.on('data', function(chunk) {
- throw new Error('got stderr data: ' + JSON.stringify('' + chunk))
+test("test", function (t) {
+ common.npm(["run", "foo"], { cwd: pkg }, function (err, code, stdout, stderr) {
+ t.ifErr(err, "npm run finished without error")
+ t.equal(code, 0, "npm run exited ok")
+ t.notOk(stderr, "no output stderr: ", stderr)
+ stdout = stdout.trim()
+ t.ok(/npm-test-fine/.test(stdout))
+ t.end()
})
- child.stdout.on('data', ondata)
- child.on('close', onend)
- var c = ''
- function ondata (chunk) {
- c += chunk
- }
- function onend () {
- c = c.trim()
+})
- t.ok(/npm-test-fine/.test(c))
- t.end()
- }
+test("cleanup", function (t) {
+ cleanup()
+ t.end()
})
-test('cleanup', function (t) {
+function cleanup() {
rimraf.sync(cache)
rimraf.sync(tmp)
rimraf.sync(modules)
- t.end()
-})
+}
diff -Nru nodejs-0.11.14/deps/npm/test/tap/search.js nodejs-0.11.15/deps/npm/test/tap/search.js
--- nodejs-0.11.14/deps/npm/test/tap/search.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/search.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,265 @@
+var common = require("../common-tap.js")
+var test = require("tap").test
+var rimraf = require("rimraf")
+var mr = require("npm-registry-mock")
+var fs = require("fs")
+var path = require("path")
+var pkg = path.resolve(__dirname, "search")
+var cache = path.resolve(pkg, "cache")
+var registryCache = path.resolve(cache, "localhost_1337", "-", "all")
+var cacheJsonFile = path.resolve(registryCache, ".cache.json")
+var mkdirp = require("mkdirp")
+
+var timeMock = {
+ epoch: 1411727900,
+ future: 1411727900+100,
+ all: 1411727900+25,
+ since: 0 // filled by since server callback
+}
+
+var EXEC_OPTS = {}
+
+function cleanupCache() {
+ rimraf.sync(cache)
+}
+function cleanup () { cleanupCache() }
+
+function setupCache() {
+ mkdirp.sync(cache)
+ mkdirp.sync(registryCache)
+ var res = fs.writeFileSync(cacheJsonFile, stringifyUpdated(timeMock.epoch))
+ if (res) throw new Error("Creating cache file failed")
+}
+
+var mocks = {
+ /* Since request, always response with an _update time > the time requested */
+ sinceFuture: function(server) {
+ server.filteringPathRegEx(/startkey=[^&]*/g, function(s) {
+ var _allMock = JSON.parse(JSON.stringify(allMock))
+ timeMock.since = _allMock._updated = s.replace("startkey=", "")
+ server.get("/-/all/since?stale=update_after&" + s)
+ .reply(200, _allMock)
+ return s
+ })
+ },
+ allFutureUpdatedOnly: function(server) {
+ server.get("/-/all")
+ .reply(200, stringifyUpdated(timeMock.future))
+ },
+ all: function(server) {
+ server.get("/-/all")
+ .reply(200, allMock)
+ }
+}
+
+
+test("No previous cache, init cache triggered by first search", function(t) {
+ cleanupCache()
+
+ mr({ port: common.port, mocks: mocks.allFutureUpdatedOnly }, function (s) {
+ common.npm([
+ "search", "do not do extra search work on my behalf",
+ "--registry", common.registry,
+ "--cache", cache,
+ "--loglevel", "silent",
+ "--color", "always"
+ ],
+ EXEC_OPTS,
+ function(err, code) {
+ s.close()
+ t.equal(code, 0, "search finished successfully")
+ t.ifErr(err, "search finished successfully")
+
+ t.ok(fs.existsSync(cacheJsonFile),
+ cacheJsonFile + " expected to have been created")
+ var cacheData = JSON.parse(fs.readFileSync(cacheJsonFile, "utf8"))
+ t.equal(cacheData._updated, String(timeMock.future))
+ t.end()
+ })
+ })
+})
+
+test("previous cache, _updated set, should trigger since request", function(t) {
+ cleanupCache()
+ setupCache()
+
+ function m(server) {
+ [ mocks.all, mocks.sinceFuture ].forEach(function(m) {
+ m(server)
+ })
+ }
+ mr({ port: common.port, mocks: m }, function (s) {
+ common.npm([
+ "search", "do not do extra search work on my behalf",
+ "--registry", common.registry,
+ "--cache", cache,
+ "--loglevel", "silly",
+ "--color", "always"
+ ],
+ EXEC_OPTS,
+ function(err, code) {
+ s.close()
+ t.equal(code, 0, "search finished successfully")
+ t.ifErr(err, "search finished successfully")
+
+ var cacheData = JSON.parse(fs.readFileSync(cacheJsonFile, "utf8"))
+ t.equal(cacheData._updated,
+ timeMock.since,
+ "cache update time gotten from since response")
+ cleanupCache()
+ t.end()
+ })
+ })
+})
+
+
+var searches = [
+ {
+ term: "f36b6a6123da50959741e2ce4d634f96ec668c56",
+ description: "non-regex",
+ location: 241
+ },
+ {
+ term: "/f36b6a6123da50959741e2ce4d634f96ec668c56/",
+ description: "regex",
+ location: 241
+ }
+]
+
+searches.forEach(function(search) {
+ test(search.description + " search in color", function(t) {
+ cleanupCache()
+ mr({ port: common.port, mocks: mocks.all }, function (s) {
+ common.npm([
+ "search", search.term,
+ "--registry", common.registry,
+ "--cache", cache,
+ "--loglevel", "silent",
+ "--color", "always"
+ ],
+ EXEC_OPTS,
+ function(err, code, stdout) {
+ s.close()
+ t.equal(code, 0, "search finished successfully")
+ t.ifErr(err, "search finished successfully")
+ // \033 == \u001B
+ var markStart = "\u001B\\[[0-9][0-9]m"
+ var markEnd = "\u001B\\[0m"
+
+ var re = new RegExp(markStart + ".*?" + markEnd)
+
+ var cnt = stdout.search(re)
+ t.equal(cnt, search.location,
+ search.description + " search for " + search.term)
+ t.end()
+ })
+ })
+ })
+})
+
+test("cleanup", function (t) {
+ cleanup()
+ t.end()
+})
+
+function stringifyUpdated(time) {
+ return JSON.stringify({ _updated : String(time) })
+}
+
+var allMock = {
+ "_updated": timeMock.all,
+ "generator-frontcow": {
+ "name": "generator-frontcow",
+ "description": "f36b6a6123da50959741e2ce4d634f96ec668c56 This is a fake description to ensure we do not accidentally search the real npm registry or use some kind of cache",
+ "dist-tags": {
+ "latest": "0.1.19"
+ },
+ "maintainers": [
+ {
+ "name": "bcabanes",
+ "email": "contact@benjamincabanes.com"
+ }
+ ],
+ "homepage": "https://github.com/bcabanes/generator-frontcow",
+ "keywords": [
+ "sass",
+ "frontend",
+ "yeoman-generator",
+ "atomic",
+ "design",
+ "sass",
+ "foundation",
+ "foundation5",
+ "atomic design",
+ "bourbon",
+ "polyfill",
+ "font awesome"
+ ],
+ "repository": {
+ "type": "git",
+ "url": "https://github.com/bcabanes/generator-frontcow"
+ },
+ "author": {
+ "name": "ben",
+ "email": "contact@benjamincabanes.com",
+ "url": "https://github.com/bcabanes"
+ },
+ "bugs": {
+ "url": "https://github.com/bcabanes/generator-frontcow/issues"
+ },
+ "license": "MIT",
+ "readmeFilename": "README.md",
+ "time": {
+ "modified": "2014-10-03T02:26:18.406Z"
+ },
+ "versions": {
+ "0.1.19": "latest"
+ }
+ },
+ "marko": {
+ "name": "marko",
+ "description": "Marko is an extensible, streaming, asynchronous, high performance, HTML-based templating language that can be used in Node.js or in the browser.",
+ "dist-tags": {
+ "latest": "1.2.16"
+ },
+ "maintainers": [
+ {
+ "name": "pnidem",
+ "email": "pnidem@gmail.com"
+ },
+ {
+ "name": "philidem",
+ "email": "phillip.idem@gmail.com"
+ }
+ ],
+ "homepage": "https://github.com/raptorjs/marko",
+ "keywords": [
+ "templating",
+ "template",
+ "async",
+ "streaming"
+ ],
+ "repository": {
+ "type": "git",
+ "url": "https://github.com/raptorjs/marko.git"
+ },
+ "author": {
+ "name": "Patrick Steele-Idem",
+ "email": "pnidem@gmail.com"
+ },
+ "bugs": {
+ "url": "https://github.com/raptorjs/marko/issues"
+ },
+ "license": "Apache License v2.0",
+ "readmeFilename": "README.md",
+ "users": {
+ "pnidem": true
+ },
+ "time": {
+ "modified": "2014-10-03T02:27:31.775Z"
+ },
+ "versions": {
+ "1.2.16": "latest"
+ }
+ }
+}
diff -Nru nodejs-0.11.14/deps/npm/test/tap/semver-doc.js nodejs-0.11.15/deps/npm/test/tap/semver-doc.js
--- nodejs-0.11.14/deps/npm/test/tap/semver-doc.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/semver-doc.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,11 +1,11 @@
var test = require("tap").test
-test("semver doc is up to date", function(t) {
+test("semver doc is up to date", function (t) {
var path = require("path")
var moddoc = path.join(__dirname, "../../node_modules/semver/README.md")
var mydoc = path.join(__dirname, "../../doc/misc/semver.md")
var fs = require("fs")
- var mod = fs.readFileSync(moddoc, "utf8").replace(/semver\(1\)/, 'semver(7)')
+ var mod = fs.readFileSync(moddoc, "utf8").replace(/semver\(1\)/, "semver(7)")
var my = fs.readFileSync(mydoc, "utf8")
t.equal(my, mod)
t.end()
diff -Nru nodejs-0.11.14/deps/npm/test/tap/semver-tag.js nodejs-0.11.15/deps/npm/test/tap/semver-tag.js
--- nodejs-0.11.14/deps/npm/test/tap/semver-tag.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/semver-tag.js 2015-01-20 21:22:17.000000000 +0000
@@ -5,7 +5,7 @@
test("try to tag with semver range as tag name", function (t) {
var cmd = ["tag", "zzzz@1.2.3", "v2.x", "--registry=http://localhost"]
common.npm(cmd, {
- stdio: "pipe",
+ stdio: "pipe"
}, function (er, code, so, se) {
if (er) throw er
t.similar(se, /Tag name must not be a valid SemVer range: v2.x\n/)
diff -Nru nodejs-0.11.14/deps/npm/test/tap/shrinkwrap-empty-deps.js nodejs-0.11.15/deps/npm/test/tap/shrinkwrap-empty-deps.js
--- nodejs-0.11.14/deps/npm/test/tap/shrinkwrap-empty-deps.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/shrinkwrap-empty-deps.js 2015-01-20 21:22:17.000000000 +0000
@@ -6,7 +6,8 @@
, fs = require("fs")
, osenv = require("osenv")
, rimraf = require("rimraf")
- , pkg = __dirname + "/shrinkwrap-empty-deps"
+ , pkg = path.resolve(__dirname, "shrinkwrap-empty-deps")
+ , cache = path.resolve(pkg, "cache")
test("returns a list of removed items", function (t) {
var desiredResultsPath = path.resolve(pkg, "npm-shrinkwrap.json")
@@ -36,7 +37,7 @@
function setup (cb) {
cleanup()
process.chdir(pkg)
- npm.load({cache: pkg + "/cache", registry: common.registry}, function () {
+ npm.load({cache: cache, registry: common.registry}, function () {
cb()
})
}
diff -Nru nodejs-0.11.14/deps/npm/test/tap/sorted-package-json.js nodejs-0.11.15/deps/npm/test/tap/sorted-package-json.js
--- nodejs-0.11.14/deps/npm/test/tap/sorted-package-json.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/sorted-package-json.js 2015-01-20 21:22:17.000000000 +0000
@@ -30,11 +30,11 @@
var child = spawn(node, [npm, "install", "--save", "underscore@1.3.3"], {
cwd: pkg,
env: {
- npm_config_registry: common.registry,
- npm_config_cache: cache,
- npm_config_tmp: tmp,
- npm_config_prefix: pkg,
- npm_config_global: "false",
+ "npm_config_registry": common.registry,
+ "npm_config_cache": cache,
+ "npm_config_tmp": tmp,
+ "npm_config_prefix": pkg,
+ "npm_config_global": "false",
HOME: process.env.HOME,
Path: process.env.PATH,
PATH: process.env.PATH
@@ -42,6 +42,7 @@
})
child.on("close", function (code) {
+ t.equal(code, 0, "npm install exited with code")
var result = fs.readFileSync(packageJson).toString()
, resultAsJson = JSON.parse(result)
@@ -83,7 +84,7 @@
"underscore": "^1.3.3",
"request": "^0.9.0"
}
- }, null, 2), 'utf8')
+ }, null, 2), "utf8")
}
function cleanup() {
diff -Nru nodejs-0.11.14/deps/npm/test/tap/spawn-enoent.js nodejs-0.11.15/deps/npm/test/tap/spawn-enoent.js
--- nodejs-0.11.14/deps/npm/test/tap/spawn-enoent.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/spawn-enoent.js 2015-01-20 21:22:17.000000000 +0000
@@ -26,7 +26,7 @@
env: {
PATH: process.env.PATH,
Path: process.env.Path,
- npm_config_loglevel: "warn"
+ "npm_config_loglevel": "warn"
}
}, function (er, code, sout, serr) {
t.similar(serr, /npm ERR! Failed at the x@1\.2\.3 start script\./)
diff -Nru nodejs-0.11.14/deps/npm/test/tap/startstop.js nodejs-0.11.15/deps/npm/test/tap/startstop.js
--- nodejs-0.11.14/deps/npm/test/tap/startstop.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/startstop.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,22 +1,18 @@
-var common = require('../common-tap')
- , test = require('tap').test
- , path = require('path')
- , spawn = require('child_process').spawn
- , rimraf = require('rimraf')
- , mkdirp = require('mkdirp')
- , pkg = __dirname + '/startstop'
- , cache = pkg + '/cache'
- , tmp = pkg + '/tmp'
- , node = process.execPath
- , npm = path.resolve(__dirname, '../../cli.js')
+var common = require("../common-tap")
+ , test = require("tap").test
+ , path = require("path")
+ , rimraf = require("rimraf")
+ , mkdirp = require("mkdirp")
+ , pkg = path.resolve(__dirname, "startstop")
+ , cache = path.resolve(pkg, "cache")
+ , tmp = path.resolve(pkg, "tmp")
, opts = { cwd: pkg }
function testOutput (t, command, er, code, stdout, stderr) {
- if (er)
- throw er
+ t.notOk(code, "npm " + command + " exited with code 0")
if (stderr)
- throw new Error('npm ' + command + ' stderr: ' + stderr.toString())
+ throw new Error("npm " + command + " stderr: " + stderr.toString())
stdout = stdout.trim().split(/\n|\r/)
stdout = stdout[stdout.length - 1]
@@ -25,40 +21,40 @@
}
function cleanup () {
- rimraf.sync(pkg + '/cache')
- rimraf.sync(pkg + '/tmp')
+ rimraf.sync(cache)
+ rimraf.sync(tmp)
}
-test('setup', function (t) {
+test("setup", function (t) {
cleanup()
- mkdirp.sync(pkg + '/cache')
- mkdirp.sync(pkg + '/tmp')
+ mkdirp.sync(cache)
+ mkdirp.sync(tmp)
t.end()
})
-test('npm start', function (t) {
- common.npm(['start'], opts, testOutput.bind(null, t, "start"))
+test("npm start", function (t) {
+ common.npm(["start"], opts, testOutput.bind(null, t, "start"))
})
-test('npm stop', function (t) {
- common.npm(['stop'], opts, testOutput.bind(null, t, "stop"))
+test("npm stop", function (t) {
+ common.npm(["stop"], opts, testOutput.bind(null, t, "stop"))
})
-test('npm restart', function (t) {
- common.npm(['restart'], opts, function (er, c, stdout, stderr) {
+test("npm restart", function (t) {
+ common.npm(["restart"], opts, function (er, c, stdout) {
if (er)
throw er
- var output = stdout.split('\n').filter(function (val) {
+ var output = stdout.split("\n").filter(function (val) {
return val.match(/^s/)
})
- t.same(output.sort(), ['start', 'stop'].sort())
+ t.same(output.sort(), ["start", "stop"].sort())
t.end()
})
})
-test('cleanup', function (t) {
+test("cleanup", function (t) {
cleanup()
t.end()
})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/test-run-ls.js nodejs-0.11.15/deps/npm/test/tap/test-run-ls.js
--- nodejs-0.11.14/deps/npm/test/tap/test-run-ls.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/test-run-ls.js 2015-01-20 21:22:17.000000000 +0000
@@ -6,7 +6,7 @@
var tsregexp = testscript.replace(/([\[\.\*\]])/g, "\\$1")
test("default", function (t) {
- common.npm(["run"], { cwd: cwd }, function (er, code, so, se) {
+ common.npm(["run"], { cwd: cwd }, function (er, code, so) {
if (er) throw er
t.notOk(code)
t.similar(so, new RegExp("\\n test\\n " + tsregexp + "\\n"))
@@ -15,7 +15,7 @@
})
test("parseable", function (t) {
- common.npm(["run", "-p"], { cwd: cwd }, function (er, code, so, se) {
+ common.npm(["run", "-p"], { cwd: cwd }, function (er, code, so) {
if (er) throw er
t.notOk(code)
t.similar(so, new RegExp("\\ntest:" + tsregexp + "\\n"))
@@ -24,7 +24,7 @@
})
test("parseable", function (t) {
- common.npm(["run", "--json"], { cwd: cwd }, function (er, code, so, se) {
+ common.npm(["run", "--json"], { cwd: cwd }, function (er, code, so) {
if (er) throw er
t.notOk(code)
t.equal(JSON.parse(so).test, testscript)
diff -Nru nodejs-0.11.14/deps/npm/test/tap/uninstall-package.js nodejs-0.11.15/deps/npm/test/tap/uninstall-package.js
--- nodejs-0.11.14/deps/npm/test/tap/uninstall-package.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/uninstall-package.js 2015-01-20 21:22:17.000000000 +0000
@@ -3,7 +3,8 @@
, rimraf = require("rimraf")
, mr = require("npm-registry-mock")
, common = require("../common-tap.js")
- , pkg = __dirname + "/uninstall-package"
+ , path = require("path")
+ , pkg = path.join(__dirname, "uninstall-package")
test("returns a list of removed items", function (t) {
t.plan(1)
diff -Nru nodejs-0.11.14/deps/npm/test/tap/unpack-foreign-tarball.js nodejs-0.11.15/deps/npm/test/tap/unpack-foreign-tarball.js
--- nodejs-0.11.14/deps/npm/test/tap/unpack-foreign-tarball.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/unpack-foreign-tarball.js 2015-01-20 21:22:17.000000000 +0000
@@ -12,8 +12,8 @@
var pkg = path.resolve(nm, "npm-test-gitignore")
var env = {
- npm_config_cache: cache,
- npm_config_tmp: tmp
+ "npm_config_cache": cache,
+ "npm_config_tmp": tmp
}
var conf = {
@@ -22,36 +22,39 @@
stdio: [ "pipe", "pipe", 2 ]
}
+function verify (t, files, err, code) {
+ if (code) {
+ t.fail("exited with failure: " + code)
+ return t.end()
+ }
+ var actual = fs.readdirSync(pkg).sort()
+ var expect = files.concat([".npmignore", "package.json"]).sort()
+ t.same(actual, expect)
+ t.end()
+}
+
test("npmignore only", function (t) {
setup()
var file = path.resolve(dir, "npmignore.tgz")
- common.npm(["install", file], conf, function (code, stdout, stderr) {
- verify(t, code, ["foo"])
- })
+ common.npm(["install", file], conf, verify.bind(null, t, ["foo"]))
})
test("gitignore only", function (t) {
setup()
var file = path.resolve(dir, "gitignore.tgz")
- common.npm(["install", file], conf, function (code, stdout, stderr) {
- verify(t, code, ["foo"])
- })
+ common.npm(["install", file], conf, verify.bind(null, t, ["foo"]))
})
test("gitignore and npmignore", function (t) {
setup()
var file = path.resolve(dir, "gitignore-and-npmignore.tgz")
- common.npm(["install", file], conf, function (code, stdout, stderr) {
- verify(t, code, ["foo", "bar"])
- })
+ common.npm(["install", file], conf, verify.bind(null, t, ["foo", "bar"]))
})
test("gitignore and npmignore, not gzipped", function (t) {
setup()
var file = path.resolve(dir, "gitignore-and-npmignore.tar")
- common.npm(["install", file], conf, function (code, stdout, stderr) {
- verify(t, code, ["foo", "bar"])
- })
+ common.npm(["install", file], conf, verify.bind(null, t, ["foo", "bar"]))
})
test("clean", function (t) {
@@ -59,17 +62,6 @@
t.end()
})
-function verify (t, code, files) {
- if (code) {
- t.fail("exited with failure: " + code)
- return t.end()
- }
- var actual = fs.readdirSync(pkg).sort()
- var expect = files.concat([".npmignore", "package.json"]).sort()
- t.same(actual, expect)
- t.end()
-}
-
function setup () {
clean()
mkdirp.sync(nm)
diff -Nru nodejs-0.11.14/deps/npm/test/tap/update-save.js nodejs-0.11.15/deps/npm/test/tap/update-save.js
--- nodejs-0.11.14/deps/npm/test/tap/update-save.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/update-save.js 2015-01-20 21:22:17.000000000 +0000
@@ -3,8 +3,8 @@
var npm = require("../../")
var mkdirp = require("mkdirp")
var rimraf = require("rimraf")
-var fs = require('fs')
-var path = require('path')
+var fs = require("fs")
+var path = require("path")
var mr = require("npm-registry-mock")
var PKG_DIR = path.resolve(__dirname, "update-save")
@@ -14,10 +14,10 @@
var EXEC_OPTS = {
cwd: PKG_DIR,
- stdio: 'ignore',
+ stdio: "ignore",
env: {
- npm_config_registry: common.registry,
- npm_config_loglevel: 'verbose'
+ "npm_config_registry": common.registry,
+ "npm_config_loglevel": "verbose"
}
}
@@ -32,9 +32,9 @@
}
}
-var s = undefined // mock server reference
+var s // mock server reference
-test('setup', function (t) {
+test("setup", function (t) {
resetPackage()
mr(common.port, function (server) {
@@ -49,14 +49,14 @@
test("update regular dependencies only", function (t) {
resetPackage()
- common.npm(['update', '--save'], EXEC_OPTS, function (err, code) {
+ common.npm(["update", "--save"], EXEC_OPTS, function (err, code) {
t.ifError(err)
- t.equal(code, 0)
+ t.notOk(code, "npm update exited with code 0")
- var pkgdata = JSON.parse(fs.readFileSync(PKG, 'utf8'))
- t.deepEqual(pkgdata.dependencies, {mkdirp: '^0.3.5'}, 'only dependencies updated')
- t.deepEqual(pkgdata.devDependencies, DEFAULT_PKG.devDependencies, 'dev dependencies should be untouched')
- t.deepEqual(pkgdata.optionalDependencies, DEFAULT_PKG.optionalDependencies, 'optional dependencies should be untouched')
+ var pkgdata = JSON.parse(fs.readFileSync(PKG, "utf8"))
+ t.deepEqual(pkgdata.dependencies, {mkdirp: "^0.3.5"}, "only dependencies updated")
+ t.deepEqual(pkgdata.devDependencies, DEFAULT_PKG.devDependencies, "dev dependencies should be untouched")
+ t.deepEqual(pkgdata.optionalDependencies, DEFAULT_PKG.optionalDependencies, "optional dependencies should be untouched")
t.end()
})
})
@@ -64,14 +64,14 @@
test("update devDependencies only", function (t) {
resetPackage()
- common.npm(['update', '--save-dev'], EXEC_OPTS, function (err, code, stdout, stderr) {
+ common.npm(["update", "--save-dev"], EXEC_OPTS, function (err, code) {
t.ifError(err)
- t.equal(code, 0)
+ t.notOk(code, "npm update exited with code 0")
- var pkgdata = JSON.parse(fs.readFileSync(PKG, 'utf8'))
- t.deepEqual(pkgdata.dependencies, DEFAULT_PKG.dependencies, 'dependencies should be untouched')
- t.deepEqual(pkgdata.devDependencies, {underscore: '^1.3.3'}, 'dev dependencies should be updated')
- t.deepEqual(pkgdata.optionalDependencies, DEFAULT_PKG.optionalDependencies, 'optional dependencies should be untouched')
+ var pkgdata = JSON.parse(fs.readFileSync(PKG, "utf8"))
+ t.deepEqual(pkgdata.dependencies, DEFAULT_PKG.dependencies, "dependencies should be untouched")
+ t.deepEqual(pkgdata.devDependencies, {underscore: "^1.3.3"}, "dev dependencies should be updated")
+ t.deepEqual(pkgdata.optionalDependencies, DEFAULT_PKG.optionalDependencies, "optional dependencies should be untouched")
t.end()
})
})
@@ -83,14 +83,14 @@
}
})
- common.npm(['update', '--save-optional'], EXEC_OPTS, function (err, code) {
+ common.npm(["update", "--save-optional"], EXEC_OPTS, function (err, code) {
t.ifError(err)
- t.equal(code, 0)
+ t.notOk(code, "npm update exited with code 0")
- var pkgdata = JSON.parse(fs.readFileSync(PKG, 'utf8'))
- t.deepEqual(pkgdata.dependencies, DEFAULT_PKG.dependencies, 'dependencies should be untouched')
- t.deepEqual(pkgdata.devDependencies, DEFAULT_PKG.devDependencies, 'dev dependencies should be untouched')
- t.deepEqual(pkgdata.optionalDependencies, {underscore: '^1.3.3'}, 'optional dependencies should be updated')
+ var pkgdata = JSON.parse(fs.readFileSync(PKG, "utf8"))
+ t.deepEqual(pkgdata.dependencies, DEFAULT_PKG.dependencies, "dependencies should be untouched")
+ t.deepEqual(pkgdata.devDependencies, DEFAULT_PKG.devDependencies, "dev dependencies should be untouched")
+ t.deepEqual(pkgdata.optionalDependencies, {underscore: "^1.3.3"}, "optional dependencies should be updated")
t.end()
})
})
@@ -102,14 +102,14 @@
}
})
- common.npm(['update', '--save'], EXEC_OPTS, function (err, code) {
+ common.npm(["update", "--save"], EXEC_OPTS, function (err, code) {
t.ifError(err)
- t.equal(code, 0)
+ t.notOk(code, "npm update exited with code 0")
- var pkgdata = JSON.parse(fs.readFileSync(PKG, 'utf8'))
- t.deepEqual(pkgdata.dependencies, {mkdirp: '^0.3.5'}, 'dependencies should not include optional dependencies')
- t.deepEqual(pkgdata.devDependencies, pkg.devDependencies, 'dev dependencies should be untouched')
- t.deepEqual(pkgdata.optionalDependencies, pkg.optionalDependencies, 'optional dependencies should be untouched')
+ var pkgdata = JSON.parse(fs.readFileSync(PKG, "utf8"))
+ t.deepEqual(pkgdata.dependencies, {mkdirp: "^0.3.5"}, "dependencies should not include optional dependencies")
+ t.deepEqual(pkgdata.devDependencies, pkg.devDependencies, "dev dependencies should be untouched")
+ t.deepEqual(pkgdata.optionalDependencies, pkg.optionalDependencies, "optional dependencies should be untouched")
t.end()
})
})
@@ -117,16 +117,16 @@
test("semver prefix is replaced with configured save-prefix", function (t) {
resetPackage()
- common.npm(['update', '--save', '--save-prefix', '~'], EXEC_OPTS, function (err, code) {
+ common.npm(["update", "--save", "--save-prefix", "~"], EXEC_OPTS, function (err, code) {
t.ifError(err)
- t.equal(code, 0)
+ t.notOk(code, "npm update exited with code 0")
- var pkgdata = JSON.parse(fs.readFileSync(PKG, 'utf8'))
+ var pkgdata = JSON.parse(fs.readFileSync(PKG, "utf8"))
t.deepEqual(pkgdata.dependencies, {
- mkdirp: '~0.3.5'
- }, 'dependencies should be updated')
- t.deepEqual(pkgdata.devDependencies, DEFAULT_PKG.devDependencies, 'dev dependencies should be untouched')
- t.deepEqual(pkgdata.optionalDependencies, DEFAULT_PKG.optionalDependencies, 'optional dependencies should be updated')
+ mkdirp: "~0.3.5"
+ }, "dependencies should be updated")
+ t.deepEqual(pkgdata.devDependencies, DEFAULT_PKG.devDependencies, "dev dependencies should be untouched")
+ t.deepEqual(pkgdata.optionalDependencies, DEFAULT_PKG.optionalDependencies, "optional dependencies should be updated")
t.end()
})
})
@@ -137,8 +137,8 @@
mkdirp.sync(CACHE_DIR)
var pkg = clone(DEFAULT_PKG)
extend(pkg, extendWith)
- for (key in extend) { pkg[key] = extend[key]}
- fs.writeFileSync(PKG, JSON.stringify(pkg, null, 2), 'ascii')
+ for (var key in extend) { pkg[key] = extend[key]}
+ fs.writeFileSync(PKG, JSON.stringify(pkg, null, 2), "ascii")
return pkg
}
@@ -155,6 +155,6 @@
}
function extend(a, b) {
- for (key in b) { a[key] = b[key]}
+ for (var key in b) { a[key] = b[key]}
return a
}
diff -Nru nodejs-0.11.14/deps/npm/test/tap/url-dependencies.js nodejs-0.11.15/deps/npm/test/tap/url-dependencies.js
--- nodejs-0.11.14/deps/npm/test/tap/url-dependencies.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/url-dependencies.js 2015-01-20 21:22:17.000000000 +0000
@@ -3,9 +3,6 @@
var path = require("path")
var osenv = require("osenv")
var mr = require("npm-registry-mock")
-var spawn = require("child_process").spawn
-var npm = require.resolve("../../bin/npm-cli.js")
-var node = process.execPath
var pkg = path.resolve(__dirname, "url-dependencies")
var common = require("../common-tap")
@@ -15,10 +12,10 @@
}
}
-test("url-dependencies: download first time", function(t) {
+test("url-dependencies: download first time", function (t) {
cleanup()
- performInstall(function(output){
+ performInstall(t, function (output){
if (!tarballWasFetched(output)){
t.fail("Tarball was not fetched")
} else {
@@ -28,11 +25,11 @@
})
})
-test("url-dependencies: do not download subsequent times", function(t) {
+test("url-dependencies: do not download subsequent times", function (t) {
cleanup()
- performInstall(function(){
- performInstall(function(output){
+ performInstall(t, function () {
+ performInstall(t, function (output) {
if (tarballWasFetched(output)){
t.fail("Tarball was fetched second time around")
} else {
@@ -47,28 +44,25 @@
return output.indexOf("http fetch GET " + common.registry + "/underscore/-/underscore-1.3.1.tgz") > -1
}
-function performInstall (cb) {
- mr({port: common.port, mocks: mockRoutes}, function(s){
- var output = ""
- , child = spawn(node, [npm, "install"], {
- cwd: pkg,
- env: {
- "npm_config_registry": common.registry,
- "npm_config_cache_lock_stale": 1000,
- "npm_config_cache_lock_wait": 1000,
- "npm_config_loglevel": "http",
- HOME: process.env.HOME,
- Path: process.env.PATH,
- PATH: process.env.PATH
- }
- })
-
- child.stderr.on("data", function(data){
- output += data.toString()
- })
- child.on("close", function () {
+function performInstall (t, cb) {
+ mr({port: common.port, mocks: mockRoutes}, function (s) {
+ var opts = {
+ cwd : pkg,
+ env: {
+ "npm_config_registry": common.registry,
+ "npm_config_cache_lock_stale": 1000,
+ "npm_config_cache_lock_wait": 1000,
+ "npm_config_loglevel": "http",
+ HOME: process.env.HOME,
+ Path: process.env.PATH,
+ PATH: process.env.PATH
+ }
+ }
+ common.npm(["install"], opts, function (err, code, stdout, stderr) {
+ t.ifError(err, "install success")
+ t.notOk(code, "npm install exited with code 0")
s.close()
- cb(output)
+ cb(stderr)
})
})
}
diff -Nru nodejs-0.11.14/deps/npm/test/tap/version-no-git.js nodejs-0.11.15/deps/npm/test/tap/version-no-git.js
--- nodejs-0.11.14/deps/npm/test/tap/version-no-git.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/version-no-git.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,54 @@
+var common = require("../common-tap.js")
+var test = require("tap").test
+var npm = require("../../")
+var osenv = require("osenv")
+var path = require("path")
+var fs = require("fs")
+var mkdirp = require("mkdirp")
+var rimraf = require("rimraf")
+var requireInject = require("require-inject")
+
+var pkg = path.resolve(__dirname, "version-no-git")
+var cache = path.resolve(pkg, "cache")
+var gitDir = path.resolve(pkg, ".git")
+
+test("npm version in a git repo without the git binary", function(t) {
+ setup()
+ npm.load({cache: cache, registry: common.registry}, function() {
+ var version = requireInject("../../lib/version", {
+ which: function(cmd, cb) {
+ process.nextTick(function() {
+ cb(new Error('ENOGIT!'))
+ })
+ }
+ })
+
+ version(["patch"], function(err) {
+ if (err) return t.fail("Error performing version patch")
+ var p = path.resolve(pkg, "package")
+ var testPkg = require(p)
+ t.equal("0.0.1", testPkg.version, "\"" + testPkg.version+"\" === \"0.0.1\"")
+ t.end()
+ })
+ })
+})
+
+test("cleanup", function(t) {
+ process.chdir(osenv.tmpdir())
+
+ rimraf.sync(pkg)
+ t.end()
+})
+
+function setup() {
+ mkdirp.sync(pkg)
+ mkdirp.sync(cache)
+ mkdirp.sync(gitDir)
+ fs.writeFileSync(path.resolve(pkg, "package.json"), JSON.stringify({
+ author: "Terin Stock",
+ name: "version-no-git-test",
+ version: "0.0.0",
+ description: "Test for npm version if git binary doesn't exist"
+ }), "utf8")
+ process.chdir(pkg)
+}
diff -Nru nodejs-0.11.14/deps/npm/test/tap/version-no-tags.js nodejs-0.11.15/deps/npm/test/tap/version-no-tags.js
--- nodejs-0.11.14/deps/npm/test/tap/version-no-tags.js 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/version-no-tags.js 2015-01-20 21:22:17.000000000 +0000
@@ -1,49 +1,47 @@
-var common = require('../common-tap.js')
-var test = require('tap').test
-var npm = require('../../')
-var npmc = require.resolve('../../')
-var osenv = require('osenv')
-var path = require('path')
-var fs = require('fs')
-var rimraf = require('rimraf')
-var mkdirp = require('mkdirp')
-var which = require('which')
-var util = require('util')
-var spawn = require('child_process').spawn
-var args = [ npmc
- , 'version'
- , 'patch'
- , '--no-git-tag-version'
- ]
-var pkg = __dirname + '/version-no-tags'
+var common = require("../common-tap.js")
+var test = require("tap").test
+var npm = require("../../")
+var osenv = require("osenv")
+var path = require("path")
+var fs = require("fs")
+var rimraf = require("rimraf")
+var mkdirp = require("mkdirp")
+var which = require("which")
+var spawn = require("child_process").spawn
+
+var pkg = path.resolve(__dirname, "version-no-tags")
+var cache = path.resolve(pkg, "cache")
test("npm version without git tag", function (t) {
setup()
- npm.load({ cache: pkg + '/cache', registry: common.registry}, function () {
- which('git', function(err, git) {
+ npm.load({ cache: cache, registry: common.registry}, function () {
+ which("git", function (err, git) {
+ t.ifError(err, "git found on system")
function tagExists(tag, _cb) {
- var child = spawn(git, ['tag', '-l', tag])
- var out = ''
- child.stdout.on('data', function(d) {
- out += data.toString()
+ var child1 = spawn(git, ["tag", "-l", tag])
+ var out = ""
+ child1.stdout.on("data", function (d) {
+ out += d.toString()
})
- child.on('exit', function() {
+ child1.on("exit", function () {
return _cb(null, Boolean(~out.indexOf(tag)))
})
}
- var child = spawn(git, ['init'])
- child.stdout.pipe(process.stdout)
- child.on('exit', function() {
- npm.config.set('git-tag-version', false)
- npm.commands.version(['patch'], function(err) {
- if (err) return t.fail('Error perform version patch')
- var testPkg = require(pkg+'/package')
- if (testPkg.version !== '0.0.1') t.fail(testPkg.version+' !== \'0.0.1\'')
- t.ok('0.0.1' === testPkg.version)
- tagExists('v0.0.1', function(err, exists) {
- t.equal(exists, false, 'git tag DOES exist')
- t.pass('git tag does not exist')
+ var child2 = spawn(git, ["init"])
+ child2.stdout.pipe(process.stdout)
+ child2.on("exit", function () {
+ npm.config.set("git-tag-version", false)
+ npm.commands.version(["patch"], function (err) {
+ if (err) return t.fail("Error perform version patch")
+ var p = path.resolve(pkg, "package")
+ var testPkg = require(p)
+ if (testPkg.version !== "0.0.1") t.fail(testPkg.version+" !== \"0.0.1\"")
+ t.equal("0.0.1", testPkg.version)
+ tagExists("v0.0.1", function (err, exists) {
+ t.ifError(err, "tag found to exist")
+ t.equal(exists, false, "git tag DOES exist")
+ t.pass("git tag does not exist")
t.end()
})
})
@@ -52,7 +50,7 @@
})
})
-test('cleanup', function(t) {
+test("cleanup", function (t) {
// windows fix for locked files
process.chdir(osenv.tmpdir())
@@ -62,12 +60,12 @@
function setup() {
mkdirp.sync(pkg)
- mkdirp.sync(pkg + '/cache')
- fs.writeFileSync(pkg + '/package.json', JSON.stringify({
+ mkdirp.sync(cache)
+ fs.writeFileSync(path.resolve(pkg, "package.json"), JSON.stringify({
author: "Evan Lucas",
name: "version-no-tags-test",
version: "0.0.0",
description: "Test for git-tag-version flag"
- }), 'utf8')
+ }), "utf8")
process.chdir(pkg)
}
diff -Nru nodejs-0.11.14/deps/npm/test/tap/view.js nodejs-0.11.15/deps/npm/test/tap/view.js
--- nodejs-0.11.14/deps/npm/test/tap/view.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/view.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,253 @@
+var common = require("../common-tap.js")
+var test = require("tap").test
+var osenv = require("osenv")
+var path = require("path")
+var fs = require("fs")
+var rimraf = require("rimraf")
+var mkdirp = require("mkdirp")
+var tmp = osenv.tmpdir()
+var t1dir = path.resolve(tmp, "view-local-no-pkg")
+var t2dir = path.resolve(tmp, "view-local-notmine")
+var t3dir = path.resolve(tmp, "view-local-mine")
+var mr = require("npm-registry-mock")
+
+test("setup", function (t) {
+ mkdirp.sync(t1dir)
+ mkdirp.sync(t2dir)
+ mkdirp.sync(t3dir)
+
+ fs.writeFileSync(t2dir + "/package.json", JSON.stringify({
+ author: "Evan Lucas"
+ , name: "test-repo-url-https"
+ , version: "0.0.1"
+ }), "utf8")
+
+ fs.writeFileSync(t3dir + "/package.json", JSON.stringify({
+ author: "Evan Lucas"
+ , name: "biscuits"
+ , version: "0.0.1"
+ }), "utf8")
+
+ t.pass("created fixtures")
+ t.end()
+})
+
+test("npm view . in global mode", function (t) {
+ process.chdir(t1dir)
+ common.npm([
+ "view"
+ , "."
+ , "--registry=" + common.registry
+ , "--global"
+ ], { cwd: t1dir }, function (err, code, stdout, stderr) {
+ t.ifError(err, "view command finished successfully")
+ t.equal(code, 1, "exit not ok")
+ t.similar(stderr, /Cannot use view command in global mode./m)
+ t.end()
+ })
+})
+
+test("npm view --global", function(t) {
+ process.chdir(t1dir)
+ common.npm([
+ "view"
+ , "--registry=" + common.registry
+ , "--global"
+ ], { cwd: t1dir }, function(err, code, stdout, stderr) {
+ t.ifError(err, "view command finished successfully")
+ t.equal(code, 1, "exit not ok")
+ t.similar(stderr, /Cannot use view command in global mode./m)
+ t.end()
+ })
+})
+
+test("npm view . with no package.json", function(t) {
+ process.chdir(t1dir)
+ common.npm([
+ "view"
+ , "."
+ , "--registry=" + common.registry
+ ], { cwd: t1dir }, function (err, code, stdout, stderr) {
+ t.ifError(err, "view command finished successfully")
+ t.equal(code, 1, "exit not ok")
+ t.similar(stderr, /Invalid package.json/m)
+ t.end()
+ })
+})
+
+test("npm view . with no published package", function (t) {
+ process.chdir(t3dir)
+ mr(common.port, function (s) {
+ common.npm([
+ "view"
+ , "."
+ , "--registry=" + common.registry
+ ], { cwd: t3dir }, function (err, code, stdout, stderr) {
+ t.ifError(err, "view command finished successfully")
+ t.equal(code, 1, "exit not ok")
+ t.similar(stderr, /version not found/m)
+ s.close()
+ t.end()
+ })
+ })
+})
+
+test("npm view .", function (t) {
+ process.chdir(t2dir)
+ mr(common.port, function (s) {
+ common.npm([
+ "view"
+ , "."
+ , "--registry=" + common.registry
+ ], { cwd: t2dir }, function (err, code, stdout) {
+ t.ifError(err, "view command finished successfully")
+ t.equal(code, 0, "exit ok")
+ var re = new RegExp("name: 'test-repo-url-https'")
+ t.similar(stdout, re)
+ s.close()
+ t.end()
+ })
+ })
+})
+
+test("npm view . select fields", function (t) {
+ process.chdir(t2dir)
+ mr(common.port, function (s) {
+ common.npm([
+ "view"
+ , "."
+ , "main"
+ , "--registry=" + common.registry
+ ], { cwd: t2dir }, function (err, code, stdout) {
+ t.ifError(err, "view command finished successfully")
+ t.equal(code, 0, "exit ok")
+ t.equal(stdout.trim(), "index.js", "should print `index.js`")
+ s.close()
+ t.end()
+ })
+ })
+})
+
+test("npm view .@", function (t) {
+ process.chdir(t2dir)
+ mr(common.port, function (s) {
+ common.npm([
+ "view"
+ , ".@0.0.0"
+ , "version"
+ , "--registry=" + common.registry
+ ], { cwd: t2dir }, function (err, code, stdout) {
+ t.ifError(err, "view command finished successfully")
+ t.equal(code, 0, "exit ok")
+ t.equal(stdout.trim(), "0.0.0", "should print `0.0.0`")
+ s.close()
+ t.end()
+ })
+ })
+})
+
+test("npm view .@ --json", function (t) {
+ process.chdir(t2dir)
+ mr(common.port, function (s) {
+ common.npm([
+ "view"
+ , ".@0.0.0"
+ , "version"
+ , "--json"
+ , "--registry=" + common.registry
+ ], { cwd: t2dir }, function (err, code, stdout) {
+ t.ifError(err, "view command finished successfully")
+ t.equal(code, 0, "exit ok")
+ t.equal(stdout.trim(), "\"0.0.0\"", "should print `\"0.0.0\"`")
+ s.close()
+ t.end()
+ })
+ })
+})
+
+test("npm view ", function (t) {
+ mr(common.port, function (s) {
+ common.npm([
+ "view"
+ , "underscore"
+ , "--registry=" + common.registry
+ ], { cwd: t2dir }, function (err, code, stdout) {
+ t.ifError(err, "view command finished successfully")
+ t.equal(code, 0, "exit ok")
+ var re = new RegExp("name: 'underscore'")
+ t.similar(stdout, re, "should have name `underscore`")
+ s.close()
+ t.end()
+ })
+ })
+})
+
+test("npm view --global", function(t) {
+ mr(common.port, function(s) {
+ common.npm([
+ "view"
+ , "underscore"
+ , "--global"
+ , "--registry=" + common.registry
+ ], { cwd: t2dir }, function(err, code, stdout) {
+ t.ifError(err, "view command finished successfully")
+ t.equal(code, 0, "exit ok")
+ var re = new RegExp("name: 'underscore'")
+ t.similar(stdout, re, "should have name `underscore`")
+ s.close()
+ t.end()
+ })
+ })
+})
+
+test("npm view --json", function(t) {
+ t.plan(3)
+ mr(common.port, function (s) {
+ common.npm([
+ "view"
+ , "underscore"
+ , "--json"
+ , "--registry=" + common.registry
+ ], { cwd: t2dir }, function (err, code, stdout) {
+ t.ifError(err, "view command finished successfully")
+ t.equal(code, 0, "exit ok")
+ s.close()
+ try {
+ var out = JSON.parse(stdout.trim())
+ t.similar(out, {
+ maintainers: "jashkenas "
+ }, "should have the same maintainer")
+ }
+ catch (er) {
+ t.fail("Unable to parse JSON")
+ }
+ })
+ })
+})
+
+test("npm view ", function (t) {
+ mr(common.port, function (s) {
+ common.npm([
+ "view"
+ , "underscore"
+ , "homepage"
+ , "--registry=" + common.registry
+ ], { cwd: t2dir }, function (err, code, stdout) {
+ t.ifError(err, "view command finished successfully")
+ t.equal(code, 0, "exit ok")
+ t.equal(stdout.trim(), "http://underscorejs.org",
+ "homepage should equal `http://underscorejs.org`")
+ s.close()
+ t.end()
+ })
+ })
+})
+
+test("cleanup", function (t) {
+ process.chdir(osenv.tmpdir())
+ rimraf.sync(t1dir)
+ rimraf.sync(t2dir)
+ rimraf.sync(t3dir)
+ t.pass("cleaned up")
+ t.end()
+})
diff -Nru nodejs-0.11.14/deps/npm/test/tap/zz-cleanup.js nodejs-0.11.15/deps/npm/test/tap/zz-cleanup.js
--- nodejs-0.11.14/deps/npm/test/tap/zz-cleanup.js 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/npm/test/tap/zz-cleanup.js 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,15 @@
+var common = require("../common-tap")
+var test = require("tap").test
+var fs = require("fs")
+
+test("cleanup", function (t) {
+ var res = common.deleteNpmCacheRecursivelySync()
+ t.equal(res, 0, "Deleted test npm cache successfully")
+
+ // ensure cache is clean
+ fs.readdir(common.npm_config_cache, function (err) {
+ t.ok(err, "error expected")
+ t.equal(err.code, "ENOENT", "npm cache directory no longer exists")
+ t.end()
+ })
+})
diff -Nru nodejs-0.11.14/deps/openssl/asm/x64-win32-masm/aes/aesni-x86_64.asm nodejs-0.11.15/deps/openssl/asm/x64-win32-masm/aes/aesni-x86_64.asm
--- nodejs-0.11.14/deps/openssl/asm/x64-win32-masm/aes/aesni-x86_64.asm 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/asm/x64-win32-masm/aes/aesni-x86_64.asm 2015-01-20 21:22:17.000000000 +0000
@@ -454,6 +454,12 @@
mov r8,QWORD PTR[40+rsp]
+ lea rsp,QWORD PTR[((-88))+rsp]
+ movaps XMMWORD PTR[rsp],xmm6
+ movaps XMMWORD PTR[16+rsp],xmm7
+ movaps XMMWORD PTR[32+rsp],xmm8
+ movaps XMMWORD PTR[48+rsp],xmm9
+$L$ecb_enc_body::
and rdx,-16
jz $L$ecb_ret
@@ -752,6 +758,12 @@
movups XMMWORD PTR[80+rsi],xmm7
$L$ecb_ret::
+ movaps xmm6,XMMWORD PTR[rsp]
+ movaps xmm7,XMMWORD PTR[16+rsp]
+ movaps xmm8,XMMWORD PTR[32+rsp]
+ movaps xmm9,XMMWORD PTR[48+rsp]
+ lea rsp,QWORD PTR[88+rsp]
+$L$ecb_enc_ret::
mov rdi,QWORD PTR[8+rsp] ;WIN64 epilogue
mov rsi,QWORD PTR[16+rsp]
DB 0F3h,0C3h ;repret
@@ -2766,26 +2778,7 @@
EXTERN __imp_RtlVirtualUnwind:NEAR
ALIGN 16
-ecb_se_handler PROC PRIVATE
- push rsi
- push rdi
- push rbx
- push rbp
- push r12
- push r13
- push r14
- push r15
- pushfq
- sub rsp,64
-
- mov rax,QWORD PTR[152+r8]
-
- jmp $L$common_seh_tail
-ecb_se_handler ENDP
-
-
-ALIGN 16
-ccm64_se_handler PROC PRIVATE
+ecb_ccm64_se_handler PROC PRIVATE
push rsi
push rdi
push rbx
@@ -2823,7 +2816,7 @@
lea rax,QWORD PTR[88+rax]
jmp $L$common_seh_tail
-ccm64_se_handler ENDP
+ecb_ccm64_se_handler ENDP
ALIGN 16
@@ -3026,15 +3019,17 @@
ALIGN 8
$L$SEH_info_ecb::
DB 9,0,0,0
- DD imagerel ecb_se_handler
+ DD imagerel ecb_ccm64_se_handler
+ DD imagerel $L$ecb_enc_body,imagerel $L$ecb_enc_ret
+
$L$SEH_info_ccm64_enc::
DB 9,0,0,0
- DD imagerel ccm64_se_handler
+ DD imagerel ecb_ccm64_se_handler
DD imagerel $L$ccm64_enc_body,imagerel $L$ccm64_enc_ret
$L$SEH_info_ccm64_dec::
DB 9,0,0,0
- DD imagerel ccm64_se_handler
+ DD imagerel ecb_ccm64_se_handler
DD imagerel $L$ccm64_dec_body,imagerel $L$ccm64_dec_ret
$L$SEH_info_ctr32::
diff -Nru nodejs-0.11.14/deps/openssl/openssl/apps/makeapps.com nodejs-0.11.15/deps/openssl/openssl/apps/makeapps.com
--- nodejs-0.11.14/deps/openssl/openssl/apps/makeapps.com 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/apps/makeapps.com 2015-01-20 21:22:17.000000000 +0000
@@ -773,9 +773,12 @@
$ IF F$TYPE(USER_CCDEFS) .NES. "" THEN CCDEFS = CCDEFS + "," + USER_CCDEFS
$ CCEXTRAFLAGS = ""
$ IF F$TYPE(USER_CCFLAGS) .NES. "" THEN CCEXTRAFLAGS = USER_CCFLAGS
-$ CCDISABLEWARNINGS = "" !!! "LONGLONGTYPE,LONGLONGSUFX,FOUNDCR"
-$ IF F$TYPE(USER_CCDISABLEWARNINGS) .NES. "" THEN -
- CCDISABLEWARNINGS = CCDISABLEWARNINGS + "," + USER_CCDISABLEWARNINGS
+$ CCDISABLEWARNINGS = "" !!! "MAYLOSEDATA3" !!! "LONGLONGTYPE,LONGLONGSUFX,FOUNDCR"
+$ IF F$TYPE(USER_CCDISABLEWARNINGS) .NES. ""
+$ THEN
+$ IF CCDISABLEWARNINGS .NES. "" THEN CCDISABLEWARNINGS = CCDISABLEWARNINGS + ","
+$ CCDISABLEWARNINGS = CCDISABLEWARNINGS + USER_CCDISABLEWARNINGS
+$ ENDIF
$!
$! Check To See If We Have A ZLIB Option.
$!
@@ -1064,6 +1067,18 @@
$!
$ IF COMPILER .EQS. "DECC"
$ THEN
+$! Not all compiler versions support MAYLOSEDATA3.
+$ OPT_TEST = "MAYLOSEDATA3"
+$ DEFINE /USER_MODE SYS$ERROR NL:
+$ DEFINE /USER_MODE SYS$OUTPUT NL:
+$ 'CC' /NOCROSS_REFERENCE /NOLIST /NOOBJECT -
+ /WARNINGS = DISABLE = ('OPT_TEST', EMPTYFILE) NL:
+$ IF ($SEVERITY)
+$ THEN
+$ IF CCDISABLEWARNINGS .NES. "" THEN -
+ CCDISABLEWARNINGS = CCDISABLEWARNINGS+ ","
+$ CCDISABLEWARNINGS = CCDISABLEWARNINGS+ OPT_TEST
+$ ENDIF
$ IF CCDISABLEWARNINGS .NES. ""
$ THEN
$ CCDISABLEWARNINGS = " /WARNING=(DISABLE=(" + CCDISABLEWARNINGS + "))"
diff -Nru nodejs-0.11.14/deps/openssl/openssl/apps/s_client.c nodejs-0.11.15/deps/openssl/openssl/apps/s_client.c
--- nodejs-0.11.14/deps/openssl/openssl/apps/s_client.c 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/apps/s_client.c 2015-01-20 21:22:17.000000000 +0000
@@ -344,6 +344,7 @@
BIO_printf(bio_err," -tls1_1 - just use TLSv1.1\n");
BIO_printf(bio_err," -tls1 - just use TLSv1\n");
BIO_printf(bio_err," -dtls1 - just use DTLSv1\n");
+ BIO_printf(bio_err," -fallback_scsv - send TLS_FALLBACK_SCSV\n");
BIO_printf(bio_err," -mtu - set the link layer MTU\n");
BIO_printf(bio_err," -no_tls1_2/-no_tls1_1/-no_tls1/-no_ssl3/-no_ssl2 - turn off that protocol\n");
BIO_printf(bio_err," -bugs - Switch on all SSL implementation bug workarounds\n");
@@ -624,6 +625,7 @@
char *sess_out = NULL;
struct sockaddr peer;
int peerlen = sizeof(peer);
+ int fallback_scsv = 0;
int enable_timeouts = 0 ;
long socket_mtu = 0;
#ifndef OPENSSL_NO_JPAKE
@@ -830,6 +832,10 @@
meth=DTLSv1_client_method();
socket_type=SOCK_DGRAM;
}
+ else if (strcmp(*argv,"-fallback_scsv") == 0)
+ {
+ fallback_scsv = 1;
+ }
else if (strcmp(*argv,"-timeout") == 0)
enable_timeouts=1;
else if (strcmp(*argv,"-mtu") == 0)
@@ -1242,6 +1248,10 @@
SSL_set_session(con, sess);
SSL_SESSION_free(sess);
}
+
+ if (fallback_scsv)
+ SSL_set_mode(con, SSL_MODE_SEND_FALLBACK_SCSV);
+
#ifndef OPENSSL_NO_TLSEXT
if (servername != NULL)
{
diff -Nru nodejs-0.11.14/deps/openssl/openssl/CHANGES nodejs-0.11.15/deps/openssl/openssl/CHANGES
--- nodejs-0.11.14/deps/openssl/openssl/CHANGES 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/CHANGES 2015-01-20 21:22:17.000000000 +0000
@@ -2,6 +2,57 @@
OpenSSL CHANGES
_______________
+ Changes between 1.0.1i and 1.0.1j [15 Oct 2014]
+
+ *) SRTP Memory Leak.
+
+ A flaw in the DTLS SRTP extension parsing code allows an attacker, who
+ sends a carefully crafted handshake message, to cause OpenSSL to fail
+ to free up to 64k of memory causing a memory leak. This could be
+ exploited in a Denial Of Service attack. This issue affects OpenSSL
+ 1.0.1 server implementations for both SSL/TLS and DTLS regardless of
+ whether SRTP is used or configured. Implementations of OpenSSL that
+ have been compiled with OPENSSL_NO_SRTP defined are not affected.
+
+ The fix was developed by the OpenSSL team.
+ (CVE-2014-3513)
+ [OpenSSL team]
+
+ *) Session Ticket Memory Leak.
+
+ When an OpenSSL SSL/TLS/DTLS server receives a session ticket the
+ integrity of that ticket is first verified. In the event of a session
+ ticket integrity check failing, OpenSSL will fail to free memory
+ causing a memory leak. By sending a large number of invalid session
+ tickets an attacker could exploit this issue in a Denial Of Service
+ attack.
+ (CVE-2014-3567)
+ [Steve Henson]
+
+ *) Build option no-ssl3 is incomplete.
+
+ When OpenSSL is configured with "no-ssl3" as a build option, servers
+ could accept and complete a SSL 3.0 handshake, and clients could be
+ configured to send them.
+ (CVE-2014-3568)
+ [Akamai and the OpenSSL team]
+
+ *) Add support for TLS_FALLBACK_SCSV.
+ Client applications doing fallback retries should call
+ SSL_set_mode(s, SSL_MODE_SEND_FALLBACK_SCSV).
+ (CVE-2014-3566)
+ [Adam Langley, Bodo Moeller]
+
+ *) Add additional DigestInfo checks.
+
+ Reencode DigestInto in DER and check against the original when
+ verifying RSA signature: this will reject any improperly encoded
+ DigestInfo structures.
+
+ Note: this is a precautionary measure and no attacks are currently known.
+
+ [Steve Henson]
+
Changes between 1.0.1h and 1.0.1i [6 Aug 2014]
*) Fix SRP buffer overrun vulnerability. Invalid parameters passed to the
diff -Nru nodejs-0.11.14/deps/openssl/openssl/Configure nodejs-0.11.15/deps/openssl/openssl/Configure
--- nodejs-0.11.14/deps/openssl/openssl/Configure 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/Configure 2015-01-20 21:22:17.000000000 +0000
@@ -1767,6 +1767,9 @@
print OUT "/* opensslconf.h */\n";
print OUT "/* WARNING: Generated automatically from opensslconf.h.in by Configure. */\n\n";
+print OUT "#ifdef __cplusplus\n";
+print OUT "extern \"C\" {\n";
+print OUT "#endif\n";
print OUT "/* OpenSSL was configured with the following options: */\n";
my $openssl_algorithm_defines_trans = $openssl_algorithm_defines;
$openssl_experimental_defines =~ s/^\s*#\s*define\s+OPENSSL_NO_(.*)/#ifndef OPENSSL_EXPERIMENTAL_$1\n# ifndef OPENSSL_NO_$1\n# define OPENSSL_NO_$1\n# endif\n#endif/mg;
@@ -1871,6 +1874,9 @@
{ print OUT $_; }
}
close(IN);
+print OUT "#ifdef __cplusplus\n";
+print OUT "}\n";
+print OUT "#endif\n";
close(OUT);
rename("crypto/opensslconf.h","crypto/opensslconf.h.bak") || die "unable to rename crypto/opensslconf.h\n" if -e "crypto/opensslconf.h";
rename("crypto/opensslconf.h.new","crypto/opensslconf.h") || die "unable to rename crypto/opensslconf.h.new\n";
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/aes/asm/aesni-x86_64.pl nodejs-0.11.15/deps/openssl/openssl/crypto/aes/asm/aesni-x86_64.pl
--- nodejs-0.11.14/deps/openssl/openssl/crypto/aes/asm/aesni-x86_64.pl 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/aes/asm/aesni-x86_64.pl 2015-01-20 21:22:17.000000000 +0000
@@ -525,6 +525,16 @@
.type aesni_ecb_encrypt,\@function,5
.align 16
aesni_ecb_encrypt:
+___
+$code.=<<___ if ($win64);
+ lea -0x58(%rsp),%rsp
+ movaps %xmm6,(%rsp)
+ movaps %xmm7,0x10(%rsp)
+ movaps %xmm8,0x20(%rsp)
+ movaps %xmm9,0x30(%rsp)
+.Lecb_enc_body:
+___
+$code.=<<___;
and \$-16,$len
jz .Lecb_ret
@@ -805,6 +815,16 @@
movups $inout5,0x50($out)
.Lecb_ret:
+___
+$code.=<<___ if ($win64);
+ movaps (%rsp),%xmm6
+ movaps 0x10(%rsp),%xmm7
+ movaps 0x20(%rsp),%xmm8
+ movaps 0x30(%rsp),%xmm9
+ lea 0x58(%rsp),%rsp
+.Lecb_enc_ret:
+___
+$code.=<<___;
ret
.size aesni_ecb_encrypt,.-aesni_ecb_encrypt
___
@@ -2730,28 +2750,9 @@
.extern __imp_RtlVirtualUnwind
___
$code.=<<___ if ($PREFIX eq "aesni");
-.type ecb_se_handler,\@abi-omnipotent
-.align 16
-ecb_se_handler:
- push %rsi
- push %rdi
- push %rbx
- push %rbp
- push %r12
- push %r13
- push %r14
- push %r15
- pushfq
- sub \$64,%rsp
-
- mov 152($context),%rax # pull context->Rsp
-
- jmp .Lcommon_seh_tail
-.size ecb_se_handler,.-ecb_se_handler
-
-.type ccm64_se_handler,\@abi-omnipotent
+.type ecb_ccm64_se_handler,\@abi-omnipotent
.align 16
-ccm64_se_handler:
+ecb_ccm64_se_handler:
push %rsi
push %rdi
push %rbx
@@ -2788,7 +2789,7 @@
lea 0x58(%rax),%rax # adjust stack pointer
jmp .Lcommon_seh_tail
-.size ccm64_se_handler,.-ccm64_se_handler
+.size ecb_ccm64_se_handler,.-ecb_ccm64_se_handler
.type ctr32_se_handler,\@abi-omnipotent
.align 16
@@ -2993,14 +2994,15 @@
$code.=<<___ if ($PREFIX eq "aesni");
.LSEH_info_ecb:
.byte 9,0,0,0
- .rva ecb_se_handler
+ .rva ecb_ccm64_se_handler
+ .rva .Lecb_enc_body,.Lecb_enc_ret # HandlerData[]
.LSEH_info_ccm64_enc:
.byte 9,0,0,0
- .rva ccm64_se_handler
+ .rva ecb_ccm64_se_handler
.rva .Lccm64_enc_body,.Lccm64_enc_ret # HandlerData[]
.LSEH_info_ccm64_dec:
.byte 9,0,0,0
- .rva ccm64_se_handler
+ .rva ecb_ccm64_se_handler
.rva .Lccm64_dec_body,.Lccm64_dec_ret # HandlerData[]
.LSEH_info_ctr32:
.byte 9,0,0,0
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/asn1/a_strex.c nodejs-0.11.15/deps/openssl/openssl/crypto/asn1/a_strex.c
--- nodejs-0.11.14/deps/openssl/openssl/crypto/asn1/a_strex.c 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/asn1/a_strex.c 2015-01-20 21:22:17.000000000 +0000
@@ -568,6 +568,7 @@
mbflag |= MBSTRING_FLAG;
stmp.data = NULL;
stmp.length = 0;
+ stmp.flags = 0;
ret = ASN1_mbstring_copy(&str, in->data, in->length, mbflag, B_ASN1_UTF8STRING);
if(ret < 0) return ret;
*out = stmp.data;
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/bn/asm/x86_64-gcc.c nodejs-0.11.15/deps/openssl/openssl/crypto/bn/asm/x86_64-gcc.c
--- nodejs-0.11.14/deps/openssl/openssl/crypto/bn/asm/x86_64-gcc.c 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/bn/asm/x86_64-gcc.c 2015-01-20 21:22:17.000000000 +0000
@@ -189,7 +189,7 @@
if (n <= 0) return 0;
- asm (
+ asm volatile (
" subq %2,%2 \n"
".p2align 4 \n"
"1: movq (%4,%2,8),%0 \n"
@@ -200,7 +200,7 @@
" sbbq %0,%0 \n"
: "=&a"(ret),"+c"(n),"=&r"(i)
: "r"(rp),"r"(ap),"r"(bp)
- : "cc"
+ : "cc", "memory"
);
return ret&1;
@@ -212,7 +212,7 @@
if (n <= 0) return 0;
- asm (
+ asm volatile (
" subq %2,%2 \n"
".p2align 4 \n"
"1: movq (%4,%2,8),%0 \n"
@@ -223,7 +223,7 @@
" sbbq %0,%0 \n"
: "=&a"(ret),"+c"(n),"=&r"(i)
: "r"(rp),"r"(ap),"r"(bp)
- : "cc"
+ : "cc", "memory"
);
return ret&1;
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/bn/bn_exp.c nodejs-0.11.15/deps/openssl/openssl/crypto/bn/bn_exp.c
--- nodejs-0.11.14/deps/openssl/openssl/crypto/bn/bn_exp.c 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/bn/bn_exp.c 2015-01-20 21:22:17.000000000 +0000
@@ -874,7 +874,14 @@
bits = BN_num_bits(p);
if (bits == 0)
{
- ret = BN_one(rr);
+ /* x**0 mod 1 is still zero. */
+ if (BN_is_one(m))
+ {
+ ret = 1;
+ BN_zero(rr);
+ }
+ else
+ ret = BN_one(rr);
return ret;
}
if (a == 0)
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/bn/bn_nist.c nodejs-0.11.15/deps/openssl/openssl/crypto/bn/bn_nist.c
--- nodejs-0.11.14/deps/openssl/openssl/crypto/bn/bn_nist.c 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/bn/bn_nist.c 2015-01-20 21:22:17.000000000 +0000
@@ -1088,9 +1088,9 @@
/* ... and right shift */
for (val=t_d[0],i=0; i>BN_NIST_521_RSHIFT;
- val = t_d[i+1];
- t_d[i] = (tmp | val<>BN_NIST_521_RSHIFT |
+ (tmp=t_d[i+1])<>BN_NIST_521_RSHIFT;
/* lower 521 bits */
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/bn/exptest.c nodejs-0.11.15/deps/openssl/openssl/crypto/bn/exptest.c
--- nodejs-0.11.14/deps/openssl/openssl/crypto/bn/exptest.c 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/bn/exptest.c 2015-01-20 21:22:17.000000000 +0000
@@ -71,6 +71,43 @@
static const char rnd_seed[] = "string to make the random number generator think it has entropy";
+/* test_exp_mod_zero tests that x**0 mod 1 == 0. It returns zero on success. */
+static int test_exp_mod_zero() {
+ BIGNUM a, p, m;
+ BIGNUM r;
+ BN_CTX *ctx = BN_CTX_new();
+ int ret = 1;
+
+ BN_init(&m);
+ BN_one(&m);
+
+ BN_init(&a);
+ BN_one(&a);
+
+ BN_init(&p);
+ BN_zero(&p);
+
+ BN_init(&r);
+ BN_mod_exp(&r, &a, &p, &m, ctx);
+ BN_CTX_free(ctx);
+
+ if (BN_is_zero(&r))
+ ret = 0;
+ else
+ {
+ printf("1**0 mod 1 = ");
+ BN_print_fp(stdout, &r);
+ printf(", should be 0\n");
+ }
+
+ BN_free(&r);
+ BN_free(&a);
+ BN_free(&p);
+ BN_free(&m);
+
+ return ret;
+}
+
int main(int argc, char *argv[])
{
BN_CTX *ctx;
@@ -190,7 +227,13 @@
ERR_remove_thread_state(NULL);
CRYPTO_mem_leaks(out);
BIO_free(out);
- printf(" done\n");
+ printf("\n");
+
+ if (test_exp_mod_zero() != 0)
+ goto err;
+
+ printf("done\n");
+
EXIT(0);
err:
ERR_load_crypto_strings();
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/constant_time_locl.h nodejs-0.11.15/deps/openssl/openssl/crypto/constant_time_locl.h
--- nodejs-0.11.14/deps/openssl/openssl/crypto/constant_time_locl.h 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/constant_time_locl.h 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,216 @@
+/* crypto/constant_time_locl.h */
+/*
+ * Utilities for constant-time cryptography.
+ *
+ * Author: Emilia Kasper (emilia@openssl.org)
+ * Based on previous work by Bodo Moeller, Emilia Kasper, Adam Langley
+ * (Google).
+ * ====================================================================
+ * Copyright (c) 2014 The OpenSSL Project. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * 3. All advertising materials mentioning features or use of this software
+ * must display the following acknowledgement:
+ * "This product includes cryptographic software written by
+ * Eric Young (eay@cryptsoft.com)"
+ * The word 'cryptographic' can be left out if the rouines from the library
+ * being used are not cryptographic related :-).
+ * 4. If you include any Windows specific code (or a derivative thereof) from
+ * the apps directory (application code) you must include an acknowledgement:
+ * "This product includes software written by Tim Hudson (tjh@cryptsoft.com)"
+ *
+ * THIS SOFTWARE IS PROVIDED BY ERIC YOUNG ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ *
+ * The licence and distribution terms for any publically available version or
+ * derivative of this code cannot be changed. i.e. this code cannot simply be
+ * copied and put under another distribution licence
+ * [including the GNU Public Licence.]
+ */
+
+#ifndef HEADER_CONSTANT_TIME_LOCL_H
+#define HEADER_CONSTANT_TIME_LOCL_H
+
+#include "e_os.h" /* For 'inline' */
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+/*
+ * The boolean methods return a bitmask of all ones (0xff...f) for true
+ * and 0 for false. This is useful for choosing a value based on the result
+ * of a conditional in constant time. For example,
+ *
+ * if (a < b) {
+ * c = a;
+ * } else {
+ * c = b;
+ * }
+ *
+ * can be written as
+ *
+ * unsigned int lt = constant_time_lt(a, b);
+ * c = constant_time_select(lt, a, b);
+ */
+
+/*
+ * Returns the given value with the MSB copied to all the other
+ * bits. Uses the fact that arithmetic shift shifts-in the sign bit.
+ * However, this is not ensured by the C standard so you may need to
+ * replace this with something else on odd CPUs.
+ */
+static inline unsigned int constant_time_msb(unsigned int a);
+
+/*
+ * Returns 0xff..f if a < b and 0 otherwise.
+ */
+static inline unsigned int constant_time_lt(unsigned int a, unsigned int b);
+/* Convenience method for getting an 8-bit mask. */
+static inline unsigned char constant_time_lt_8(unsigned int a, unsigned int b);
+
+/*
+ * Returns 0xff..f if a >= b and 0 otherwise.
+ */
+static inline unsigned int constant_time_ge(unsigned int a, unsigned int b);
+/* Convenience method for getting an 8-bit mask. */
+static inline unsigned char constant_time_ge_8(unsigned int a, unsigned int b);
+
+/*
+ * Returns 0xff..f if a == 0 and 0 otherwise.
+ */
+static inline unsigned int constant_time_is_zero(unsigned int a);
+/* Convenience method for getting an 8-bit mask. */
+static inline unsigned char constant_time_is_zero_8(unsigned int a);
+
+
+/*
+ * Returns 0xff..f if a == b and 0 otherwise.
+ */
+static inline unsigned int constant_time_eq(unsigned int a, unsigned int b);
+/* Convenience method for getting an 8-bit mask. */
+static inline unsigned char constant_time_eq_8(unsigned int a, unsigned int b);
+/* Signed integers. */
+static inline unsigned int constant_time_eq_int(int a, int b);
+/* Convenience method for getting an 8-bit mask. */
+static inline unsigned char constant_time_eq_int_8(int a, int b);
+
+
+/*
+ * Returns (mask & a) | (~mask & b).
+ *
+ * When |mask| is all 1s or all 0s (as returned by the methods above),
+ * the select methods return either |a| (if |mask| is nonzero) or |b|
+ * (if |mask| is zero).
+ */
+static inline unsigned int constant_time_select(unsigned int mask,
+ unsigned int a, unsigned int b);
+/* Convenience method for unsigned chars. */
+static inline unsigned char constant_time_select_8(unsigned char mask,
+ unsigned char a, unsigned char b);
+/* Convenience method for signed integers. */
+static inline int constant_time_select_int(unsigned int mask, int a, int b);
+
+static inline unsigned int constant_time_msb(unsigned int a)
+ {
+ return (unsigned int)((int)(a) >> (sizeof(int) * 8 - 1));
+ }
+
+static inline unsigned int constant_time_lt(unsigned int a, unsigned int b)
+ {
+ unsigned int lt;
+ /* Case 1: msb(a) == msb(b). a < b iff the MSB of a - b is set.*/
+ lt = ~(a ^ b) & (a - b);
+ /* Case 2: msb(a) != msb(b). a < b iff the MSB of b is set. */
+ lt |= ~a & b;
+ return constant_time_msb(lt);
+ }
+
+static inline unsigned char constant_time_lt_8(unsigned int a, unsigned int b)
+ {
+ return (unsigned char)(constant_time_lt(a, b));
+ }
+
+static inline unsigned int constant_time_ge(unsigned int a, unsigned int b)
+ {
+ unsigned int ge;
+ /* Case 1: msb(a) == msb(b). a >= b iff the MSB of a - b is not set.*/
+ ge = ~((a ^ b) | (a - b));
+ /* Case 2: msb(a) != msb(b). a >= b iff the MSB of a is set. */
+ ge |= a & ~b;
+ return constant_time_msb(ge);
+ }
+
+static inline unsigned char constant_time_ge_8(unsigned int a, unsigned int b)
+ {
+ return (unsigned char)(constant_time_ge(a, b));
+ }
+
+static inline unsigned int constant_time_is_zero(unsigned int a)
+ {
+ return constant_time_msb(~a & (a - 1));
+ }
+
+static inline unsigned char constant_time_is_zero_8(unsigned int a)
+ {
+ return (unsigned char)(constant_time_is_zero(a));
+ }
+
+static inline unsigned int constant_time_eq(unsigned int a, unsigned int b)
+ {
+ return constant_time_is_zero(a ^ b);
+ }
+
+static inline unsigned char constant_time_eq_8(unsigned int a, unsigned int b)
+ {
+ return (unsigned char)(constant_time_eq(a, b));
+ }
+
+static inline unsigned int constant_time_eq_int(int a, int b)
+ {
+ return constant_time_eq((unsigned)(a), (unsigned)(b));
+ }
+
+static inline unsigned char constant_time_eq_int_8(int a, int b)
+ {
+ return constant_time_eq_8((unsigned)(a), (unsigned)(b));
+ }
+
+static inline unsigned int constant_time_select(unsigned int mask,
+ unsigned int a, unsigned int b)
+ {
+ return (mask & a) | (~mask & b);
+ }
+
+static inline unsigned char constant_time_select_8(unsigned char mask,
+ unsigned char a, unsigned char b)
+ {
+ return (unsigned char)(constant_time_select(mask, a, b));
+ }
+
+inline int constant_time_select_int(unsigned int mask, int a, int b)
+ {
+ return (int)(constant_time_select(mask, (unsigned)(a), (unsigned)(b)));
+ }
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* HEADER_CONSTANT_TIME_LOCL_H */
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/constant_time_test.c nodejs-0.11.15/deps/openssl/openssl/crypto/constant_time_test.c
--- nodejs-0.11.14/deps/openssl/openssl/crypto/constant_time_test.c 1970-01-01 00:00:00.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/constant_time_test.c 2015-01-20 21:22:17.000000000 +0000
@@ -0,0 +1,330 @@
+/* crypto/constant_time_test.c */
+/*
+ * Utilities for constant-time cryptography.
+ *
+ * Author: Emilia Kasper (emilia@openssl.org)
+ * Based on previous work by Bodo Moeller, Emilia Kasper, Adam Langley
+ * (Google).
+ * ====================================================================
+ * Copyright (c) 2014 The OpenSSL Project. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * 3. All advertising materials mentioning features or use of this software
+ * must display the following acknowledgement:
+ * "This product includes cryptographic software written by
+ * Eric Young (eay@cryptsoft.com)"
+ * The word 'cryptographic' can be left out if the rouines from the library
+ * being used are not cryptographic related :-).
+ * 4. If you include any Windows specific code (or a derivative thereof) from
+ * the apps directory (application code) you must include an acknowledgement:
+ * "This product includes software written by Tim Hudson (tjh@cryptsoft.com)"
+ *
+ * THIS SOFTWARE IS PROVIDED BY ERIC YOUNG ``AS IS'' AND
+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ * SUCH DAMAGE.
+ *
+ * The licence and distribution terms for any publically available version or
+ * derivative of this code cannot be changed. i.e. this code cannot simply be
+ * copied and put under another distribution licence
+ * [including the GNU Public Licence.]
+ */
+
+#include "../crypto/constant_time_locl.h"
+
+#include
+#include
+#include
+
+static const unsigned int CONSTTIME_TRUE = (unsigned)(~0);
+static const unsigned int CONSTTIME_FALSE = 0;
+static const unsigned char CONSTTIME_TRUE_8 = 0xff;
+static const unsigned char CONSTTIME_FALSE_8 = 0;
+
+static int test_binary_op(unsigned int (*op)(unsigned int a, unsigned int b),
+ const char* op_name, unsigned int a, unsigned int b, int is_true)
+ {
+ unsigned c = op(a, b);
+ if (is_true && c != CONSTTIME_TRUE)
+ {
+ fprintf(stderr, "Test failed for %s(%du, %du): expected %du "
+ "(TRUE), got %du\n", op_name, a, b, CONSTTIME_TRUE, c);
+ return 1;
+ }
+ else if (!is_true && c != CONSTTIME_FALSE)
+ {
+ fprintf(stderr, "Test failed for %s(%du, %du): expected %du "
+ "(FALSE), got %du\n", op_name, a, b, CONSTTIME_FALSE,
+ c);
+ return 1;
+ }
+ return 0;
+ }
+
+static int test_binary_op_8(unsigned char (*op)(unsigned int a, unsigned int b),
+ const char* op_name, unsigned int a, unsigned int b, int is_true)
+ {
+ unsigned char c = op(a, b);
+ if (is_true && c != CONSTTIME_TRUE_8)
+ {
+ fprintf(stderr, "Test failed for %s(%du, %du): expected %u "
+ "(TRUE), got %u\n", op_name, a, b, CONSTTIME_TRUE_8, c);
+ return 1;
+ }
+ else if (!is_true && c != CONSTTIME_FALSE_8)
+ {
+ fprintf(stderr, "Test failed for %s(%du, %du): expected %u "
+ "(FALSE), got %u\n", op_name, a, b, CONSTTIME_FALSE_8,
+ c);
+ return 1;
+ }
+ return 0;
+ }
+
+static int test_is_zero(unsigned int a)
+ {
+ unsigned int c = constant_time_is_zero(a);
+ if (a == 0 && c != CONSTTIME_TRUE)
+ {
+ fprintf(stderr, "Test failed for constant_time_is_zero(%du): "
+ "expected %du (TRUE), got %du\n", a, CONSTTIME_TRUE, c);
+ return 1;
+ }
+ else if (a != 0 && c != CONSTTIME_FALSE)
+ {
+ fprintf(stderr, "Test failed for constant_time_is_zero(%du): "
+ "expected %du (FALSE), got %du\n", a, CONSTTIME_FALSE,
+ c);
+ return 1;
+ }
+ return 0;
+ }
+
+static int test_is_zero_8(unsigned int a)
+ {
+ unsigned char c = constant_time_is_zero_8(a);
+ if (a == 0 && c != CONSTTIME_TRUE_8)
+ {
+ fprintf(stderr, "Test failed for constant_time_is_zero(%du): "
+ "expected %u (TRUE), got %u\n", a, CONSTTIME_TRUE_8, c);
+ return 1;
+ }
+ else if (a != 0 && c != CONSTTIME_FALSE)
+ {
+ fprintf(stderr, "Test failed for constant_time_is_zero(%du): "
+ "expected %u (FALSE), got %u\n", a, CONSTTIME_FALSE_8,
+ c);
+ return 1;
+ }
+ return 0;
+ }
+
+static int test_select(unsigned int a, unsigned int b)
+ {
+ unsigned int selected = constant_time_select(CONSTTIME_TRUE, a, b);
+ if (selected != a)
+ {
+ fprintf(stderr, "Test failed for constant_time_select(%du, %du,"
+ "%du): expected %du(first value), got %du\n",
+ CONSTTIME_TRUE, a, b, a, selected);
+ return 1;
+ }
+ selected = constant_time_select(CONSTTIME_FALSE, a, b);
+ if (selected != b)
+ {
+ fprintf(stderr, "Test failed for constant_time_select(%du, %du,"
+ "%du): expected %du(second value), got %du\n",
+ CONSTTIME_FALSE, a, b, b, selected);
+ return 1;
+ }
+ return 0;
+ }
+
+static int test_select_8(unsigned char a, unsigned char b)
+ {
+ unsigned char selected = constant_time_select_8(CONSTTIME_TRUE_8, a, b);
+ if (selected != a)
+ {
+ fprintf(stderr, "Test failed for constant_time_select(%u, %u,"
+ "%u): expected %u(first value), got %u\n",
+ CONSTTIME_TRUE, a, b, a, selected);
+ return 1;
+ }
+ selected = constant_time_select_8(CONSTTIME_FALSE_8, a, b);
+ if (selected != b)
+ {
+ fprintf(stderr, "Test failed for constant_time_select(%u, %u,"
+ "%u): expected %u(second value), got %u\n",
+ CONSTTIME_FALSE, a, b, b, selected);
+ return 1;
+ }
+ return 0;
+ }
+
+static int test_select_int(int a, int b)
+ {
+ int selected = constant_time_select_int(CONSTTIME_TRUE, a, b);
+ if (selected != a)
+ {
+ fprintf(stderr, "Test failed for constant_time_select(%du, %d,"
+ "%d): expected %d(first value), got %d\n",
+ CONSTTIME_TRUE, a, b, a, selected);
+ return 1;
+ }
+ selected = constant_time_select_int(CONSTTIME_FALSE, a, b);
+ if (selected != b)
+ {
+ fprintf(stderr, "Test failed for constant_time_select(%du, %d,"
+ "%d): expected %d(second value), got %d\n",
+ CONSTTIME_FALSE, a, b, b, selected);
+ return 1;
+ }
+ return 0;
+ }
+
+static int test_eq_int(int a, int b)
+ {
+ unsigned int equal = constant_time_eq_int(a, b);
+ if (a == b && equal != CONSTTIME_TRUE)
+ {
+ fprintf(stderr, "Test failed for constant_time_eq_int(%d, %d): "
+ "expected %du(TRUE), got %du\n",
+ a, b, CONSTTIME_TRUE, equal);
+ return 1;
+ }
+ else if (a != b && equal != CONSTTIME_FALSE)
+ {
+ fprintf(stderr, "Test failed for constant_time_eq_int(%d, %d): "
+ "expected %du(FALSE), got %du\n",
+ a, b, CONSTTIME_FALSE, equal);
+ return 1;
+ }
+ return 0;
+ }
+
+static int test_eq_int_8(int a, int b)
+ {
+ unsigned char equal = constant_time_eq_int_8(a, b);
+ if (a == b && equal != CONSTTIME_TRUE_8)
+ {
+ fprintf(stderr, "Test failed for constant_time_eq_int_8(%d, %d): "
+ "expected %u(TRUE), got %u\n",
+ a, b, CONSTTIME_TRUE_8, equal);
+ return 1;
+ }
+ else if (a != b && equal != CONSTTIME_FALSE_8)
+ {
+ fprintf(stderr, "Test failed for constant_time_eq_int_8(%d, %d): "
+ "expected %u(FALSE), got %u\n",
+ a, b, CONSTTIME_FALSE_8, equal);
+ return 1;
+ }
+ return 0;
+ }
+
+static unsigned int test_values[] = {0, 1, 1024, 12345, 32000, UINT_MAX/2-1,
+ UINT_MAX/2, UINT_MAX/2+1, UINT_MAX-1,
+ UINT_MAX};
+
+static unsigned char test_values_8[] = {0, 1, 2, 20, 32, 127, 128, 129, 255};
+
+static int signed_test_values[] = {0, 1, -1, 1024, -1024, 12345, -12345,
+ 32000, -32000, INT_MAX, INT_MIN, INT_MAX-1,
+ INT_MIN+1};
+
+
+int main(int argc, char *argv[])
+ {
+ unsigned int a, b, i, j;
+ int c, d;
+ unsigned char e, f;
+ int num_failed = 0, num_all = 0;
+ fprintf(stdout, "Testing constant time operations...\n");
+
+ for (i = 0; i < sizeof(test_values)/sizeof(int); ++i)
+ {
+ a = test_values[i];
+ num_failed += test_is_zero(a);
+ num_failed += test_is_zero_8(a);
+ num_all += 2;
+ for (j = 0; j < sizeof(test_values)/sizeof(int); ++j)
+ {
+ b = test_values[j];
+ num_failed += test_binary_op(&constant_time_lt,
+ "constant_time_lt", a, b, a < b);
+ num_failed += test_binary_op_8(&constant_time_lt_8,
+ "constant_time_lt_8", a, b, a < b);
+ num_failed += test_binary_op(&constant_time_lt,
+ "constant_time_lt_8", b, a, b < a);
+ num_failed += test_binary_op_8(&constant_time_lt_8,
+ "constant_time_lt_8", b, a, b < a);
+ num_failed += test_binary_op(&constant_time_ge,
+ "constant_time_ge", a, b, a >= b);
+ num_failed += test_binary_op_8(&constant_time_ge_8,
+ "constant_time_ge_8", a, b, a >= b);
+ num_failed += test_binary_op(&constant_time_ge,
+ "constant_time_ge", b, a, b >= a);
+ num_failed += test_binary_op_8(&constant_time_ge_8,
+ "constant_time_ge_8", b, a, b >= a);
+ num_failed += test_binary_op(&constant_time_eq,
+ "constant_time_eq", a, b, a == b);
+ num_failed += test_binary_op_8(&constant_time_eq_8,
+ "constant_time_eq_8", a, b, a == b);
+ num_failed += test_binary_op(&constant_time_eq,
+ "constant_time_eq", b, a, b == a);
+ num_failed += test_binary_op_8(&constant_time_eq_8,
+ "constant_time_eq_8", b, a, b == a);
+ num_failed += test_select(a, b);
+ num_all += 13;
+ }
+ }
+
+ for (i = 0; i < sizeof(signed_test_values)/sizeof(int); ++i)
+ {
+ c = signed_test_values[i];
+ for (j = 0; j < sizeof(signed_test_values)/sizeof(int); ++j)
+ {
+ d = signed_test_values[j];
+ num_failed += test_select_int(c, d);
+ num_failed += test_eq_int(c, d);
+ num_failed += test_eq_int_8(c, d);
+ num_all += 3;
+ }
+ }
+
+ for (i = 0; i < sizeof(test_values_8); ++i)
+ {
+ e = test_values_8[i];
+ for (j = 0; j < sizeof(test_values_8); ++j)
+ {
+ f = test_values_8[j];
+ num_failed += test_select_8(e, f);
+ num_all += 1;
+ }
+ }
+
+ if (!num_failed)
+ {
+ fprintf(stdout, "ok (ran %d tests)\n", num_all);
+ return EXIT_SUCCESS;
+ }
+ else
+ {
+ fprintf(stdout, "%d of %d tests failed!\n", num_failed, num_all);
+ return EXIT_FAILURE;
+ }
+ }
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/crypto-lib.com nodejs-0.11.15/deps/openssl/openssl/crypto/crypto-lib.com
--- nodejs-0.11.14/deps/openssl/openssl/crypto/crypto-lib.com 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/crypto-lib.com 2015-01-20 21:22:17.000000000 +0000
@@ -111,8 +111,8 @@
$ IF ARCH .EQS. "VAX" THEN ET_WHIRLPOOL = ""
$ ENCRYPT_TYPES = "Basic,"+ -
"OBJECTS,"+ -
- "MD2,MD4,MD5,SHA,MDC2,HMAC,RIPEMD,"+ET_WHIRLPOOL+","+ -
- "DES,AES,RC2,RC4,RC5,IDEA,BF,CAST,CAMELLIA,SEED,MODES,"+ -
+ "MD4,MD5,SHA,MDC2,HMAC,RIPEMD,"+ET_WHIRLPOOL+","+ -
+ "DES,AES,RC2,RC4,IDEA,BF,CAST,CAMELLIA,SEED,MODES,"+ -
"BN,EC,RSA,DSA,ECDSA,DH,ECDH,DSO,ENGINE,"+ -
"BUFFER,BIO,STACK,LHASH,RAND,ERR,"+ -
"EVP,EVP_2,EVP_3,ASN1,ASN1_2,PEM,X509,X509V3,"+ -
@@ -204,11 +204,18 @@
$!
$! Define The Different Encryption "library" Strings.
$!
-$ APPS_DES = "DES/DES,CBC3_ENC"
-$ APPS_PKCS7 = "ENC/ENC;DEC/DEC;SIGN/SIGN;VERIFY/VERIFY,EXAMPLE"
+$!!! Test apps disabled, as they aren't supported at all,
+$!!! not even in the unix build
+$!!! APPS_DES = "DES/DES,CBC3_ENC"
+$!!! APPS_PKCS7 = "ENC/ENC;DEC/DEC;SIGN/SIGN;VERIFY/VERIFY,EXAMPLE"
$
-$ LIB_ = "cryptlib,mem,mem_clr,mem_dbg,cversion,ex_data,cpt_err,"+ -
- "ebcdic,uid,o_time,o_str,o_dir,o_fips.c,o_init,fips_ers"
+$! These variables are ordered as the SDIRS variable from the top Makefile.org
+$! The contents of these variables are copied from the LIBOBJ variable in the
+$! corresponding Makefile from each corresponding subdirectory, with .o stripped
+$! and spaces replaced with commas.
+$ LIB_ = "cryptlib,mem,mem_dbg,cversion,ex_data,cpt_err,ebcdic,"+ -
+ "uid,o_time,o_str,o_dir,o_fips.c,o_init,fips_ers,mem_clr"
+$ LIB_OBJECTS = "o_names,obj_dat,obj_lib,obj_err,obj_xref"
$ LIB_MD2 = "md2_dgst,md2_one"
$ LIB_MD4 = "md4_dgst,md4_one"
$ LIB_MD5 = "md5_dgst,md5_one"
@@ -225,13 +232,13 @@
"fcrypt,xcbc_enc,rpc_enc,cbc_cksm,"+ -
"ede_cbcm_enc,des_old,des_old2,read2pwd"
$ LIB_RC2 = "rc2_ecb,rc2_skey,rc2_cbc,rc2cfb64,rc2ofb64"
-$ LIB_RC4 = "rc4_skey,rc4_enc,rc4_utl"
+$ LIB_RC4 = "rc4_enc,rc4_skey,rc4_utl"
$ LIB_RC5 = "rc5_skey,rc5_ecb,rc5_enc,rc5cfb64,rc5ofb64"
$ LIB_IDEA = "i_cbc,i_cfb64,i_ofb64,i_ecb,i_skey"
$ LIB_BF = "bf_skey,bf_ecb,bf_enc,bf_cfb64,bf_ofb64"
$ LIB_CAST = "c_skey,c_ecb,c_enc,c_cfb64,c_ofb64"
-$ LIB_CAMELLIA = "camellia,cmll_misc,cmll_ecb,cmll_cbc,cmll_ofb,"+ -
- "cmll_cfb,cmll_ctr,cmll_utl"
+$ LIB_CAMELLIA = "cmll_ecb,cmll_ofb,cmll_cfb,cmll_ctr,cmll_utl,"+ -
+ "camellia,cmll_misc,cmll_cbc"
$ LIB_SEED = "seed,seed_ecb,seed_cbc,seed_cfb,seed_ofb"
$ LIB_MODES = "cbc128,ctr128,cts128,cfb128,ofb128,gcm128,"+ -
"ccm128,xts128"
@@ -264,24 +271,23 @@
"eng_table,eng_pkey,eng_fat,eng_all,"+ -
"tb_rsa,tb_dsa,tb_ecdsa,tb_dh,tb_ecdh,tb_rand,tb_store,"+ -
"tb_cipher,tb_digest,tb_pkmeth,tb_asnmth,"+ -
- "eng_openssl,eng_dyn,eng_cnf,eng_cryptodev,"+ -
+ "eng_openssl,eng_cnf,eng_dyn,eng_cryptodev,"+ -
"eng_rsax,eng_rdrand"
-$ LIB_AES = "aes_core,aes_misc,aes_ecb,aes_cbc,aes_cfb,aes_ofb,aes_ctr,"+ -
- "aes_ige,aes_wrap"
+$ LIB_AES = "aes_misc,aes_ecb,aes_cfb,aes_ofb,aes_ctr,aes_ige,aes_wrap,"+ -
+ "aes_core,aes_cbc"
$ LIB_BUFFER = "buffer,buf_str,buf_err"
$ LIB_BIO = "bio_lib,bio_cb,bio_err,"+ -
"bss_mem,bss_null,bss_fd,"+ -
"bss_file,bss_sock,bss_conn,"+ -
"bf_null,bf_buff,b_print,b_dump,"+ -
- "b_sock,bss_acpt,bf_nbio,bss_rtcp,bss_bio,bss_log,"+ -
+ "b_sock,bss_acpt,bf_nbio,bss_log,bss_bio,"+ -
"bss_dgram,"+ -
- "bf_lbuf"
+ "bf_lbuf,bss_rtcp" ! The last two are VMS specific
$ LIB_STACK = "stack"
$ LIB_LHASH = "lhash,lh_stats"
$ LIB_RAND = "md_rand,randfile,rand_lib,rand_err,rand_egd,"+ -
- "rand_vms"
+ "rand_vms" ! The last one is VMS specific
$ LIB_ERR = "err,err_all,err_prn"
-$ LIB_OBJECTS = "o_names,obj_dat,obj_lib,obj_err,obj_xref"
$ LIB_EVP = "encode,digest,evp_enc,evp_key,evp_acnf,evp_cnf,"+ -
"e_des,e_bf,e_idea,e_des3,e_camellia,"+ -
"e_rc4,e_aes,names,e_seed,"+ -
@@ -345,7 +351,7 @@
$ LIB_JPAKE = "jpake,jpake_err"
$ LIB_SRP = "srp_lib,srp_vfy"
$ LIB_STORE = "str_err,str_lib,str_meth,str_mem"
-$ LIB_CMAC = "cmac,cm_ameth.c,cm_pmeth"
+$ LIB_CMAC = "cmac,cm_ameth,cm_pmeth"
$!
$! Setup exceptional compilations
$!
@@ -381,7 +387,7 @@
$!
$! Extract The Module Name From The Encryption List.
$!
-$ MODULE_NAME = F$ELEMENT(MODULE_COUNTER,",",ENCRYPT_TYPES)
+$ MODULE_NAME = F$EDIT(F$ELEMENT(MODULE_COUNTER,",",ENCRYPT_TYPES),"COLLAPSE")
$ IF MODULE_NAME.EQS."Basic" THEN MODULE_NAME = ""
$ MODULE_NAME1 = MODULE_NAME
$!
@@ -465,7 +471,7 @@
$!
$! O.K, Extract The File Name From The File List.
$!
-$ FILE_NAME = F$ELEMENT(FILE_COUNTER,",",'LIB_MODULE')
+$ FILE_NAME = F$EDIT(F$ELEMENT(FILE_COUNTER,",",'LIB_MODULE'),"COLLAPSE")
$!
$! else
$!
@@ -492,7 +498,7 @@
$!
$ IF APPLICATION .NES. ";"
$ THEN
-$ FILE_NAME = F$ELEMENT(FILE_COUNTER,",",APPLICATION_OBJECTS)
+$ FILE_NAME = F$EDIT(F$ELEMENT(FILE_COUNTER,",",APPLICATION_OBJECTS),"COLLAPSE")
$ IF FILE_NAME .EQS. ","
$ THEN
$ APPLICATION = ""
@@ -1132,9 +1138,12 @@
$ IF F$TYPE(USER_CCDEFS) .NES. "" THEN CCDEFS = CCDEFS + "," + USER_CCDEFS
$ CCEXTRAFLAGS = ""
$ IF F$TYPE(USER_CCFLAGS) .NES. "" THEN CCEXTRAFLAGS = USER_CCFLAGS
-$ CCDISABLEWARNINGS = "" !!! "LONGLONGTYPE,LONGLONGSUFX,FOUNDCR"
-$ IF F$TYPE(USER_CCDISABLEWARNINGS) .NES. "" THEN -
- CCDISABLEWARNINGS = CCDISABLEWARNINGS + "," + USER_CCDISABLEWARNINGS
+$ CCDISABLEWARNINGS = "" !!! "MAYLOSEDATA3" !!! "LONGLONGTYPE,LONGLONGSUFX,FOUNDCR"
+$ IF F$TYPE(USER_CCDISABLEWARNINGS) .NES. ""
+$ THEN
+$ IF CCDISABLEWARNINGS .NES. "" THEN CCDISABLEWARNINGS = CCDISABLEWARNINGS + ","
+$ CCDISABLEWARNINGS = CCDISABLEWARNINGS + USER_CCDISABLEWARNINGS
+$ ENDIF
$!
$! Check To See If We Have A ZLIB Option.
$!
@@ -1299,6 +1308,18 @@
$!
$ IF COMPILER .EQS. "DECC"
$ THEN
+$! Not all compiler versions support MAYLOSEDATA3.
+$ OPT_TEST = "MAYLOSEDATA3"
+$ DEFINE /USER_MODE SYS$ERROR NL:
+$ DEFINE /USER_MODE SYS$OUTPUT NL:
+$ 'CC' /NOCROSS_REFERENCE /NOLIST /NOOBJECT -
+ /WARNINGS = DISABLE = ('OPT_TEST', EMPTYFILE) NL:
+$ IF ($SEVERITY)
+$ THEN
+$ IF CCDISABLEWARNINGS .NES. "" THEN -
+ CCDISABLEWARNINGS = CCDISABLEWARNINGS+ ","
+$ CCDISABLEWARNINGS = CCDISABLEWARNINGS+ OPT_TEST
+$ ENDIF
$ IF CCDISABLEWARNINGS .EQS. ""
$ THEN
$ CC4DISABLEWARNINGS = "DOLLARID"
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/dsa/dsa_ameth.c nodejs-0.11.15/deps/openssl/openssl/crypto/dsa/dsa_ameth.c
--- nodejs-0.11.14/deps/openssl/openssl/crypto/dsa/dsa_ameth.c 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/dsa/dsa_ameth.c 2015-01-20 21:22:17.000000000 +0000
@@ -307,6 +307,12 @@
unsigned char *dp = NULL;
int dplen;
+ if (!pkey->pkey.dsa || !pkey->pkey.dsa->priv_key)
+ {
+ DSAerr(DSA_F_DSA_PRIV_ENCODE,DSA_R_MISSING_PARAMETERS);
+ goto err;
+ }
+
params = ASN1_STRING_new();
if (!params)
@@ -701,4 +707,3 @@
old_dsa_priv_encode
}
};
-
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/ebcdic.h nodejs-0.11.15/deps/openssl/openssl/crypto/ebcdic.h
--- nodejs-0.11.14/deps/openssl/openssl/crypto/ebcdic.h 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/ebcdic.h 2015-01-20 21:22:17.000000000 +0000
@@ -5,6 +5,10 @@
#include
+#ifdef __cplusplus
+extern "C" {
+#endif
+
/* Avoid name clashes with other applications */
#define os_toascii _openssl_os_toascii
#define os_toebcdic _openssl_os_toebcdic
@@ -16,4 +20,7 @@
void *ebcdic2ascii(void *dest, const void *srce, size_t count);
void *ascii2ebcdic(void *dest, const void *srce, size_t count);
+#ifdef __cplusplus
+}
+#endif
#endif
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/ec/ec2_smpl.c nodejs-0.11.15/deps/openssl/openssl/crypto/ec/ec2_smpl.c
--- nodejs-0.11.14/deps/openssl/openssl/crypto/ec/ec2_smpl.c 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/ec/ec2_smpl.c 2015-01-20 21:22:17.000000000 +0000
@@ -80,9 +80,6 @@
const EC_METHOD *EC_GF2m_simple_method(void)
{
-#ifdef OPENSSL_FIPS
- return fips_ec_gf2m_simple_method();
-#else
static const EC_METHOD ret = {
EC_FLAGS_DEFAULT_OCT,
NID_X9_62_characteristic_two_field,
@@ -125,8 +122,12 @@
0 /* field_decode */,
0 /* field_set_to_one */ };
- return &ret;
+#ifdef OPENSSL_FIPS
+ if (FIPS_mode())
+ return fips_ec_gf2m_simple_method();
#endif
+
+ return &ret;
}
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/ec/ec_ameth.c nodejs-0.11.15/deps/openssl/openssl/crypto/ec/ec_ameth.c
--- nodejs-0.11.14/deps/openssl/openssl/crypto/ec/ec_ameth.c 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/ec/ec_ameth.c 2015-01-20 21:22:17.000000000 +0000
@@ -453,14 +453,16 @@
if (ktype > 0)
{
public_key = EC_KEY_get0_public_key(x);
- if ((pub_key = EC_POINT_point2bn(group, public_key,
- EC_KEY_get_conv_form(x), NULL, ctx)) == NULL)
+ if (public_key != NULL)
{
- reason = ERR_R_EC_LIB;
- goto err;
- }
- if (pub_key)
+ if ((pub_key = EC_POINT_point2bn(group, public_key,
+ EC_KEY_get_conv_form(x), NULL, ctx)) == NULL)
+ {
+ reason = ERR_R_EC_LIB;
+ goto err;
+ }
buf_len = (size_t)BN_num_bytes(pub_key);
+ }
}
if (ktype == 2)
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/ec/ec_asn1.c nodejs-0.11.15/deps/openssl/openssl/crypto/ec/ec_asn1.c
--- nodejs-0.11.14/deps/openssl/openssl/crypto/ec/ec_asn1.c 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/ec/ec_asn1.c 2015-01-20 21:22:17.000000000 +0000
@@ -1183,29 +1183,46 @@
goto err;
}
+ if (ret->pub_key)
+ EC_POINT_clear_free(ret->pub_key);
+ ret->pub_key = EC_POINT_new(ret->group);
+ if (ret->pub_key == NULL)
+ {
+ ECerr(EC_F_D2I_ECPRIVATEKEY, ERR_R_EC_LIB);
+ goto err;
+ }
+
if (priv_key->publicKey)
{
const unsigned char *pub_oct;
- size_t pub_oct_len;
+ int pub_oct_len;
- if (ret->pub_key)
- EC_POINT_clear_free(ret->pub_key);
- ret->pub_key = EC_POINT_new(ret->group);
- if (ret->pub_key == NULL)
+ pub_oct = M_ASN1_STRING_data(priv_key->publicKey);
+ pub_oct_len = M_ASN1_STRING_length(priv_key->publicKey);
+ /* The first byte - point conversion form - must be present. */
+ if (pub_oct_len <= 0)
{
- ECerr(EC_F_D2I_ECPRIVATEKEY, ERR_R_EC_LIB);
+ ECerr(EC_F_D2I_ECPRIVATEKEY, EC_R_BUFFER_TOO_SMALL);
goto err;
}
- pub_oct = M_ASN1_STRING_data(priv_key->publicKey);
- pub_oct_len = M_ASN1_STRING_length(priv_key->publicKey);
- /* save the point conversion form */
+ /* Save the point conversion form. */
ret->conv_form = (point_conversion_form_t)(pub_oct[0] & ~0x01);
if (!EC_POINT_oct2point(ret->group, ret->pub_key,
- pub_oct, pub_oct_len, NULL))
+ pub_oct, (size_t)(pub_oct_len), NULL))
+ {
+ ECerr(EC_F_D2I_ECPRIVATEKEY, ERR_R_EC_LIB);
+ goto err;
+ }
+ }
+ else
+ {
+ if (!EC_POINT_mul(ret->group, ret->pub_key, ret->priv_key, NULL, NULL, NULL))
{
ECerr(EC_F_D2I_ECPRIVATEKEY, ERR_R_EC_LIB);
goto err;
}
+ /* Remember the original private-key-only encoding. */
+ ret->enc_flag |= EC_PKEY_NO_PUBKEY;
}
ok = 1;
@@ -1230,7 +1247,8 @@
size_t buf_len=0, tmp_len;
EC_PRIVATEKEY *priv_key=NULL;
- if (a == NULL || a->group == NULL || a->priv_key == NULL)
+ if (a == NULL || a->group == NULL || a->priv_key == NULL ||
+ (!(a->enc_flag & EC_PKEY_NO_PUBKEY) && a->pub_key == NULL))
{
ECerr(EC_F_I2D_ECPRIVATEKEY,
ERR_R_PASSED_NULL_PARAMETER);
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/ec/ec.h nodejs-0.11.15/deps/openssl/openssl/crypto/ec/ec.h
--- nodejs-0.11.14/deps/openssl/openssl/crypto/ec/ec.h 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/ec/ec.h 2015-01-20 21:22:17.000000000 +0000
@@ -629,7 +629,7 @@
int EC_POINT_make_affine(const EC_GROUP *group, EC_POINT *point, BN_CTX *ctx);
int EC_POINTs_make_affine(const EC_GROUP *group, size_t num, EC_POINT *points[], BN_CTX *ctx);
-/** Computes r = generator * n sum_{i=0}^num p[i] * m[i]
+/** Computes r = generator * n sum_{i=0}^{num-1} p[i] * m[i]
* \param group underlying EC_GROUP object
* \param r EC_POINT object for the result
* \param n BIGNUM with the multiplier for the group generator (optional)
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/ec/ecp_mont.c nodejs-0.11.15/deps/openssl/openssl/crypto/ec/ecp_mont.c
--- nodejs-0.11.14/deps/openssl/openssl/crypto/ec/ecp_mont.c 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/ec/ecp_mont.c 2015-01-20 21:22:17.000000000 +0000
@@ -72,9 +72,6 @@
const EC_METHOD *EC_GFp_mont_method(void)
{
-#ifdef OPENSSL_FIPS
- return fips_ec_gfp_mont_method();
-#else
static const EC_METHOD ret = {
EC_FLAGS_DEFAULT_OCT,
NID_X9_62_prime_field,
@@ -114,8 +111,12 @@
ec_GFp_mont_field_decode,
ec_GFp_mont_field_set_to_one };
- return &ret;
+#ifdef OPENSSL_FIPS
+ if (FIPS_mode())
+ return fips_ec_gfp_mont_method();
#endif
+
+ return &ret;
}
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/ec/ecp_nist.c nodejs-0.11.15/deps/openssl/openssl/crypto/ec/ecp_nist.c
--- nodejs-0.11.14/deps/openssl/openssl/crypto/ec/ecp_nist.c 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/ec/ecp_nist.c 2015-01-20 21:22:17.000000000 +0000
@@ -73,9 +73,6 @@
const EC_METHOD *EC_GFp_nist_method(void)
{
-#ifdef OPENSSL_FIPS
- return fips_ec_gfp_nist_method();
-#else
static const EC_METHOD ret = {
EC_FLAGS_DEFAULT_OCT,
NID_X9_62_prime_field,
@@ -115,8 +112,12 @@
0 /* field_decode */,
0 /* field_set_to_one */ };
- return &ret;
+#ifdef OPENSSL_FIPS
+ if (FIPS_mode())
+ return fips_ec_gfp_nist_method();
#endif
+
+ return &ret;
}
int ec_GFp_nist_group_copy(EC_GROUP *dest, const EC_GROUP *src)
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/ec/ecp_smpl.c nodejs-0.11.15/deps/openssl/openssl/crypto/ec/ecp_smpl.c
--- nodejs-0.11.14/deps/openssl/openssl/crypto/ec/ecp_smpl.c 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/ec/ecp_smpl.c 2015-01-20 21:22:17.000000000 +0000
@@ -73,9 +73,6 @@
const EC_METHOD *EC_GFp_simple_method(void)
{
-#ifdef OPENSSL_FIPS
- return fips_ec_gfp_simple_method();
-#else
static const EC_METHOD ret = {
EC_FLAGS_DEFAULT_OCT,
NID_X9_62_prime_field,
@@ -115,8 +112,12 @@
0 /* field_decode */,
0 /* field_set_to_one */ };
- return &ret;
+#ifdef OPENSSL_FIPS
+ if (FIPS_mode())
+ return fips_ec_gfp_simple_method();
#endif
+
+ return &ret;
}
@@ -1317,8 +1318,8 @@
{
for (i = 0; i < num; i++)
{
- if (prod_Z[i] != NULL)
- BN_clear_free(prod_Z[i]);
+ if (prod_Z[i] == NULL) break;
+ BN_clear_free(prod_Z[i]);
}
OPENSSL_free(prod_Z);
}
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/ec/ectest.c nodejs-0.11.15/deps/openssl/openssl/crypto/ec/ectest.c
--- nodejs-0.11.14/deps/openssl/openssl/crypto/ec/ectest.c 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/ec/ectest.c 2015-01-20 21:22:17.000000000 +0000
@@ -251,14 +251,15 @@
if (!EC_POINT_is_at_infinity(group, Q)) ABORT;
/* Exercise EC_POINTs_mul, including corner cases. */
+ if (EC_POINT_is_at_infinity(group, P)) ABORT;
scalars[0] = n1; points[0] = Q; /* => infinity */
scalars[1] = n2; points[1] = P; /* => -P */
scalars[2] = n1; points[2] = Q; /* => infinity */
scalars[3] = n2; points[3] = Q; /* => infinity */
scalars[4] = n1; points[4] = P; /* => P */
scalars[5] = n2; points[5] = Q; /* => infinity */
- if (!EC_POINTs_mul(group, Q, NULL, 5, points, scalars, ctx)) ABORT;
- if (!EC_POINT_is_at_infinity(group, Q)) ABORT;
+ if (!EC_POINTs_mul(group, P, NULL, 6, points, scalars, ctx)) ABORT;
+ if (!EC_POINT_is_at_infinity(group, P)) ABORT;
}
fprintf(stdout, "ok\n");
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/err/openssl.ec nodejs-0.11.15/deps/openssl/openssl/crypto/err/openssl.ec
--- nodejs-0.11.14/deps/openssl/openssl/crypto/err/openssl.ec 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/err/openssl.ec 2015-01-20 21:22:17.000000000 +0000
@@ -71,6 +71,7 @@
R SSL_R_TLSV1_ALERT_PROTOCOL_VERSION 1070
R SSL_R_TLSV1_ALERT_INSUFFICIENT_SECURITY 1071
R SSL_R_TLSV1_ALERT_INTERNAL_ERROR 1080
+R SSL_R_TLSV1_ALERT_INAPPROPRIATE_FALLBACK 1086
R SSL_R_TLSV1_ALERT_USER_CANCELLED 1090
R SSL_R_TLSV1_ALERT_NO_RENEGOTIATION 1100
R SSL_R_TLSV1_UNSUPPORTED_EXTENSION 1110
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/evp/e_aes.c nodejs-0.11.15/deps/openssl/openssl/crypto/evp/e_aes.c
--- nodejs-0.11.14/deps/openssl/openssl/crypto/evp/e_aes.c 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/evp/e_aes.c 2015-01-20 21:22:17.000000000 +0000
@@ -166,7 +166,7 @@
#define VPAES_CAPABLE (OPENSSL_ia32cap_P[1]&(1<<(41-32)))
#endif
#ifdef BSAES_ASM
-#define BSAES_CAPABLE VPAES_CAPABLE
+#define BSAES_CAPABLE (OPENSSL_ia32cap_P[1]&(1<<(41-32)))
#endif
/*
* AES-NI section
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/evp/evp_enc.c nodejs-0.11.15/deps/openssl/openssl/crypto/evp/evp_enc.c
--- nodejs-0.11.14/deps/openssl/openssl/crypto/evp/evp_enc.c 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/evp/evp_enc.c 2015-01-20 21:22:17.000000000 +0000
@@ -67,6 +67,7 @@
#ifdef OPENSSL_FIPS
#include
#endif
+#include "constant_time_locl.h"
#include "evp_locl.h"
#ifdef OPENSSL_FIPS
@@ -500,21 +501,21 @@
int EVP_DecryptFinal_ex(EVP_CIPHER_CTX *ctx, unsigned char *out, int *outl)
{
- int i,n;
- unsigned int b;
+ unsigned int i, b;
+ unsigned char pad, padding_good;
*outl=0;
if (ctx->cipher->flags & EVP_CIPH_FLAG_CUSTOM_CIPHER)
{
- i = M_do_cipher(ctx, out, NULL, 0);
- if (i < 0)
+ int ret = M_do_cipher(ctx, out, NULL, 0);
+ if (ret < 0)
return 0;
else
- *outl = i;
+ *outl = ret;
return 1;
}
- b=ctx->cipher->block_size;
+ b=(unsigned int)(ctx->cipher->block_size);
if (ctx->flags & EVP_CIPH_NO_PADDING)
{
if(ctx->buf_len)
@@ -533,28 +534,34 @@
return(0);
}
OPENSSL_assert(b <= sizeof ctx->final);
- n=ctx->final[b-1];
- if (n == 0 || n > (int)b)
- {
- EVPerr(EVP_F_EVP_DECRYPTFINAL_EX,EVP_R_BAD_DECRYPT);
- return(0);
- }
- for (i=0; ifinal[b-1];
+
+ padding_good = (unsigned char)(~constant_time_is_zero_8(pad));
+ padding_good &= constant_time_ge_8(b, pad);
+
+ for (i = 1; i < b; ++i)
{
- if (ctx->final[--b] != n)
- {
- EVPerr(EVP_F_EVP_DECRYPTFINAL_EX,EVP_R_BAD_DECRYPT);
- return(0);
- }
- }
- n=ctx->cipher->block_size-n;
- for (i=0; ifinal[i];
- *outl=n;
+ unsigned char is_pad_index = constant_time_lt_8(i, pad);
+ unsigned char pad_byte_good = constant_time_eq_8(ctx->final[b-i-1], pad);
+ padding_good &= constant_time_select_8(is_pad_index, pad_byte_good, 0xff);
+ }
+
+ /*
+ * At least 1 byte is always padding, so we always write b - 1
+ * bytes to avoid a timing leak. The caller is required to have |b|
+ * bytes space in |out| by the API contract.
+ */
+ for (i = 0; i < b - 1; ++i)
+ out[i] = ctx->final[i] & padding_good;
+ /* Safe cast: for a good padding, EVP_MAX_IV_LENGTH >= b >= pad */
+ *outl = padding_good & ((unsigned char)(b - pad));
+ return padding_good & 1;
}
else
- *outl=0;
- return(1);
+ {
+ *outl = 0;
+ return 1;
+ }
}
void EVP_CIPHER_CTX_free(EVP_CIPHER_CTX *ctx)
@@ -678,4 +685,3 @@
return in->cipher->ctrl((EVP_CIPHER_CTX *)in, EVP_CTRL_COPY, 0, out);
return 1;
}
-
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/evp/Makefile nodejs-0.11.15/deps/openssl/openssl/crypto/evp/Makefile
--- nodejs-0.11.14/deps/openssl/openssl/crypto/evp/Makefile 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/evp/Makefile 2015-01-20 21:22:17.000000000 +0000
@@ -383,7 +383,7 @@
evp_enc.o: ../../include/openssl/safestack.h ../../include/openssl/sha.h
evp_enc.o: ../../include/openssl/stack.h ../../include/openssl/symhacks.h
evp_enc.o: ../../include/openssl/x509.h ../../include/openssl/x509_vfy.h
-evp_enc.o: ../cryptlib.h evp_enc.c evp_locl.h
+evp_enc.o: ../constant_time_locl.h ../cryptlib.h evp_enc.c evp_locl.h
evp_err.o: ../../include/openssl/asn1.h ../../include/openssl/bio.h
evp_err.o: ../../include/openssl/crypto.h ../../include/openssl/e_os2.h
evp_err.o: ../../include/openssl/err.h ../../include/openssl/evp.h
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/install-crypto.com nodejs-0.11.15/deps/openssl/openssl/crypto/install-crypto.com
--- nodejs-0.11.14/deps/openssl/openssl/crypto/install-crypto.com 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/install-crypto.com 2015-01-20 21:22:17.000000000 +0000
@@ -75,13 +75,13 @@
$ sdirs := , -
'archd', -
objects, -
- md2, md4, md5, sha, mdc2, hmac, ripemd, whrlpool, -
- des, aes, rc2, rc4, rc5, idea, bf, cast, camellia, seed, -
+ md4, md5, sha, mdc2, hmac, ripemd, whrlpool, -
+ des, aes, rc2, rc4, idea, bf, cast, camellia, seed, -
bn, ec, rsa, dsa, ecdsa, dh, ecdh, dso, engine, -
buffer, bio, stack, lhash, rand, err, -
evp, asn1, pem, x509, x509v3, conf, txt_db, pkcs7, pkcs12, comp, ocsp, -
ui, krb5, -
- store, cms, pqueue, ts, jpake
+ cms, pqueue, ts, jpake, srp, store, cmac
$!
$ exheader_ := crypto.h, opensslv.h, ebcdic.h, symhacks.h, ossl_typ.h
$ exheader_'archd' := opensslconf.h
@@ -139,6 +139,9 @@
$ exheader_pqueue := pqueue.h
$ exheader_ts := ts.h
$ exheader_jpake := jpake.h
+$ exheader_srp := srp.h
+$ exheader_store := store.h
+$ exheader_cmac := cmac.h
$ libs := ssl_libcrypto
$!
$ exe_dir := [-.'archd'.exe.crypto]
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/LPdir_vms.c nodejs-0.11.15/deps/openssl/openssl/crypto/LPdir_vms.c
--- nodejs-0.11.14/deps/openssl/openssl/crypto/LPdir_vms.c 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/LPdir_vms.c 2015-01-20 21:22:17.000000000 +0000
@@ -1,4 +1,3 @@
-/* $LP: LPlib/source/LPdir_vms.c,v 1.20 2004/08/26 13:36:05 _cvs_levitte Exp $ */
/*
* Copyright (c) 2004, Richard Levitte
* All rights reserved.
@@ -88,6 +87,12 @@
size_t filespeclen = strlen(directory);
char *filespec = NULL;
+ if (filespeclen == 0)
+ {
+ errno = ENOENT;
+ return 0;
+ }
+
/* MUST be a VMS directory specification! Let's estimate if it is. */
if (directory[filespeclen-1] != ']'
&& directory[filespeclen-1] != '>'
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/LPdir_win.c nodejs-0.11.15/deps/openssl/openssl/crypto/LPdir_win.c
--- nodejs-0.11.14/deps/openssl/openssl/crypto/LPdir_win.c 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/LPdir_win.c 2015-01-20 21:22:17.000000000 +0000
@@ -1,4 +1,3 @@
-/* $LP: LPlib/source/LPdir_win.c,v 1.10 2004/08/26 13:36:05 _cvs_levitte Exp $ */
/*
* Copyright (c) 2004, Richard Levitte
* All rights reserved.
@@ -63,6 +62,16 @@
errno = 0;
if (*ctx == NULL)
{
+ const char *extdir = directory;
+ char *extdirbuf = NULL;
+ size_t dirlen = strlen (directory);
+
+ if (dirlen == 0)
+ {
+ errno = ENOENT;
+ return 0;
+ }
+
*ctx = (LP_DIR_CTX *)malloc(sizeof(LP_DIR_CTX));
if (*ctx == NULL)
{
@@ -71,15 +80,35 @@
}
memset(*ctx, '\0', sizeof(LP_DIR_CTX));
+ if (directory[dirlen-1] != '*')
+ {
+ extdirbuf = (char *)malloc(dirlen + 3);
+ if (extdirbuf == NULL)
+ {
+ free(*ctx);
+ *ctx = NULL;
+ errno = ENOMEM;
+ return 0;
+ }
+ if (directory[dirlen-1] != '/' && directory[dirlen-1] != '\\')
+ extdir = strcat(strcpy (extdirbuf,directory),"/*");
+ else
+ extdir = strcat(strcpy (extdirbuf,directory),"*");
+ }
+
if (sizeof(TCHAR) != sizeof(char))
{
TCHAR *wdir = NULL;
/* len_0 denotes string length *with* trailing 0 */
- size_t index = 0,len_0 = strlen(directory) + 1;
+ size_t index = 0,len_0 = strlen(extdir) + 1;
- wdir = (TCHAR *)malloc(len_0 * sizeof(TCHAR));
+ wdir = (TCHAR *)calloc(len_0, sizeof(TCHAR));
if (wdir == NULL)
{
+ if (extdirbuf != NULL)
+ {
+ free (extdirbuf);
+ }
free(*ctx);
*ctx = NULL;
errno = ENOMEM;
@@ -87,17 +116,23 @@
}
#ifdef LP_MULTIBYTE_AVAILABLE
- if (!MultiByteToWideChar(CP_ACP, 0, directory, len_0, (WCHAR *)wdir, len_0))
+ if (!MultiByteToWideChar(CP_ACP, 0, extdir, len_0, (WCHAR *)wdir, len_0))
#endif
for (index = 0; index < len_0; index++)
- wdir[index] = (TCHAR)directory[index];
+ wdir[index] = (TCHAR)extdir[index];
(*ctx)->handle = FindFirstFile(wdir, &(*ctx)->ctx);
free(wdir);
}
else
- (*ctx)->handle = FindFirstFile((TCHAR *)directory, &(*ctx)->ctx);
+ {
+ (*ctx)->handle = FindFirstFile((TCHAR *)extdir, &(*ctx)->ctx);
+ }
+ if (extdirbuf != NULL)
+ {
+ free (extdirbuf);
+ }
if ((*ctx)->handle == INVALID_HANDLE_VALUE)
{
@@ -114,7 +149,6 @@
return 0;
}
}
-
if (sizeof(TCHAR) != sizeof(char))
{
TCHAR *wdir = (*ctx)->ctx.cFileName;
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/Makefile nodejs-0.11.15/deps/openssl/openssl/crypto/Makefile
--- nodejs-0.11.14/deps/openssl/openssl/crypto/Makefile 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/Makefile 2015-01-20 21:22:17.000000000 +0000
@@ -31,6 +31,7 @@
LIBS=
GENERAL=Makefile README crypto-lib.com install.com
+TEST=constant_time_test.c
LIB= $(TOP)/libcrypto.a
SHARED_LIB= libcrypto$(SHLIB_EXT)
@@ -43,7 +44,8 @@
EXHEADER= crypto.h opensslv.h opensslconf.h ebcdic.h symhacks.h \
ossl_typ.h
-HEADER= cryptlib.h buildinf.h md32_common.h o_time.h o_str.h o_dir.h $(EXHEADER)
+HEADER= cryptlib.h buildinf.h md32_common.h o_time.h o_str.h o_dir.h \
+ constant_time_locl.h $(EXHEADER)
ALL= $(GENERAL) $(SRC) $(HEADER)
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/md5/asm/md5-x86_64.pl nodejs-0.11.15/deps/openssl/openssl/crypto/md5/asm/md5-x86_64.pl
--- nodejs-0.11.14/deps/openssl/openssl/crypto/md5/asm/md5-x86_64.pl 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/md5/asm/md5-x86_64.pl 2015-01-20 21:22:17.000000000 +0000
@@ -108,6 +108,7 @@
EOF
}
+no warnings qw(uninitialized);
my $flavour = shift;
my $output = shift;
if ($flavour =~ /\./) { $output = $flavour; undef $flavour; }
@@ -119,7 +120,6 @@
( $xlate="${dir}../../perlasm/x86_64-xlate.pl" and -f $xlate) or
die "can't locate x86_64-xlate.pl";
-no warnings qw(uninitialized);
open OUT,"| \"$^X\" $xlate $flavour $output";
*STDOUT=*OUT;
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/modes/modes.h nodejs-0.11.15/deps/openssl/openssl/crypto/modes/modes.h
--- nodejs-0.11.14/deps/openssl/openssl/crypto/modes/modes.h 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/modes/modes.h 2015-01-20 21:22:17.000000000 +0000
@@ -7,6 +7,9 @@
#include
+#ifdef __cplusplus
+extern "C" {
+#endif
typedef void (*block128_f)(const unsigned char in[16],
unsigned char out[16],
const void *key);
@@ -133,3 +136,6 @@
int CRYPTO_xts128_encrypt(const XTS128_CONTEXT *ctx, const unsigned char iv[16],
const unsigned char *inp, unsigned char *out, size_t len, int enc);
+#ifdef __cplusplus
+}
+#endif
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/ocsp/ocsp_vfy.c nodejs-0.11.15/deps/openssl/openssl/crypto/ocsp/ocsp_vfy.c
--- nodejs-0.11.14/deps/openssl/openssl/crypto/ocsp/ocsp_vfy.c 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/ocsp/ocsp_vfy.c 2015-01-20 21:22:17.000000000 +0000
@@ -436,8 +436,11 @@
if(!(flags & OCSP_NOINTERN))
{
signer = X509_find_by_subject(req->optionalSignature->certs, nm);
- *psigner = signer;
- return 1;
+ if (signer)
+ {
+ *psigner = signer;
+ return 1;
+ }
}
signer = X509_find_by_subject(certs, nm);
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/opensslv.h nodejs-0.11.15/deps/openssl/openssl/crypto/opensslv.h
--- nodejs-0.11.14/deps/openssl/openssl/crypto/opensslv.h 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/opensslv.h 2015-01-20 21:22:17.000000000 +0000
@@ -1,6 +1,10 @@
#ifndef HEADER_OPENSSLV_H
#define HEADER_OPENSSLV_H
+#ifdef __cplusplus
+extern "C" {
+#endif
+
/* Numeric release version identifier:
* MNNFFPPS: major minor fix patch status
* The status nibble has one of the values 0 for development, 1 to e for betas
@@ -25,11 +29,11 @@
* (Prior to 0.9.5a beta1, a different scheme was used: MMNNFFRBB for
* major minor fix final patch/beta)
*/
-#define OPENSSL_VERSION_NUMBER 0x1000109fL
+#define OPENSSL_VERSION_NUMBER 0x100010afL
#ifdef OPENSSL_FIPS
-#define OPENSSL_VERSION_TEXT "OpenSSL 1.0.1i-fips 6 Aug 2014"
+#define OPENSSL_VERSION_TEXT "OpenSSL 1.0.1j-fips 15 Oct 2014"
#else
-#define OPENSSL_VERSION_TEXT "OpenSSL 1.0.1i 6 Aug 2014"
+#define OPENSSL_VERSION_TEXT "OpenSSL 1.0.1j 15 Oct 2014"
#endif
#define OPENSSL_VERSION_PTEXT " part of " OPENSSL_VERSION_TEXT
@@ -86,4 +90,7 @@
#define SHLIB_VERSION_NUMBER "1.0.0"
+#ifdef __cplusplus
+}
+#endif
#endif /* HEADER_OPENSSLV_H */
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/ossl_typ.h nodejs-0.11.15/deps/openssl/openssl/crypto/ossl_typ.h
--- nodejs-0.11.14/deps/openssl/openssl/crypto/ossl_typ.h 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/ossl_typ.h 2015-01-20 21:22:17.000000000 +0000
@@ -55,6 +55,10 @@
#ifndef HEADER_OPENSSL_TYPES_H
#define HEADER_OPENSSL_TYPES_H
+#ifdef __cplusplus
+extern "C" {
+#endif
+
#include
#ifdef NO_ASN1_TYPEDEFS
@@ -199,4 +203,7 @@
typedef struct ocsp_response_st OCSP_RESPONSE;
typedef struct ocsp_responder_id_st OCSP_RESPID;
+#ifdef __cplusplus
+}
+#endif
#endif /* def HEADER_OPENSSL_TYPES_H */
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/pkcs7/pkcs7.h nodejs-0.11.15/deps/openssl/openssl/crypto/pkcs7/pkcs7.h
--- nodejs-0.11.14/deps/openssl/openssl/crypto/pkcs7/pkcs7.h 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/pkcs7/pkcs7.h 2015-01-20 21:22:17.000000000 +0000
@@ -233,10 +233,6 @@
(OBJ_obj2nid((a)->type) == NID_pkcs7_signedAndEnveloped)
#define PKCS7_type_is_data(a) (OBJ_obj2nid((a)->type) == NID_pkcs7_data)
#define PKCS7_type_is_digest(a) (OBJ_obj2nid((a)->type) == NID_pkcs7_digest)
-#define PKCS7_type_is_encrypted(a) \
- (OBJ_obj2nid((a)->type) == NID_pkcs7_encrypted)
-
-#define PKCS7_type_is_digest(a) (OBJ_obj2nid((a)->type) == NID_pkcs7_digest)
#define PKCS7_set_detached(p,v) \
PKCS7_ctrl(p,PKCS7_OP_SET_DETACHED_SIGNATURE,v,NULL)
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/pqueue/pqueue.h nodejs-0.11.15/deps/openssl/openssl/crypto/pqueue/pqueue.h
--- nodejs-0.11.14/deps/openssl/openssl/crypto/pqueue/pqueue.h 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/pqueue/pqueue.h 2015-01-20 21:22:17.000000000 +0000
@@ -64,6 +64,9 @@
#include
#include
+#ifdef __cplusplus
+extern "C" {
+#endif
typedef struct _pqueue *pqueue;
typedef struct _pitem
@@ -91,4 +94,7 @@
void pqueue_print(pqueue pq);
int pqueue_size(pqueue pq);
+#ifdef __cplusplus
+}
+#endif
#endif /* ! HEADER_PQUEUE_H */
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/rsa/Makefile nodejs-0.11.15/deps/openssl/openssl/crypto/rsa/Makefile
--- nodejs-0.11.14/deps/openssl/openssl/crypto/rsa/Makefile 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/rsa/Makefile 2015-01-20 21:22:17.000000000 +0000
@@ -212,7 +212,7 @@
rsa_oaep.o: ../../include/openssl/rand.h ../../include/openssl/rsa.h
rsa_oaep.o: ../../include/openssl/safestack.h ../../include/openssl/sha.h
rsa_oaep.o: ../../include/openssl/stack.h ../../include/openssl/symhacks.h
-rsa_oaep.o: ../cryptlib.h rsa_oaep.c
+rsa_oaep.o: ../constant_time_locl.h ../cryptlib.h rsa_oaep.c
rsa_pk1.o: ../../e_os.h ../../include/openssl/asn1.h
rsa_pk1.o: ../../include/openssl/bio.h ../../include/openssl/bn.h
rsa_pk1.o: ../../include/openssl/buffer.h ../../include/openssl/crypto.h
@@ -221,7 +221,8 @@
rsa_pk1.o: ../../include/openssl/opensslv.h ../../include/openssl/ossl_typ.h
rsa_pk1.o: ../../include/openssl/rand.h ../../include/openssl/rsa.h
rsa_pk1.o: ../../include/openssl/safestack.h ../../include/openssl/stack.h
-rsa_pk1.o: ../../include/openssl/symhacks.h ../cryptlib.h rsa_pk1.c
+rsa_pk1.o: ../../include/openssl/symhacks.h ../constant_time_locl.h
+rsa_pk1.o: ../cryptlib.h rsa_pk1.c
rsa_pmeth.o: ../../e_os.h ../../include/openssl/asn1.h
rsa_pmeth.o: ../../include/openssl/asn1t.h ../../include/openssl/bio.h
rsa_pmeth.o: ../../include/openssl/bn.h ../../include/openssl/buffer.h
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/rsa/rsa_err.c nodejs-0.11.15/deps/openssl/openssl/crypto/rsa/rsa_err.c
--- nodejs-0.11.14/deps/openssl/openssl/crypto/rsa/rsa_err.c 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/rsa/rsa_err.c 2015-01-20 21:22:17.000000000 +0000
@@ -175,6 +175,7 @@
{ERR_REASON(RSA_R_OPERATION_NOT_ALLOWED_IN_FIPS_MODE),"operation not allowed in fips mode"},
{ERR_REASON(RSA_R_OPERATION_NOT_SUPPORTED_FOR_THIS_KEYTYPE),"operation not supported for this keytype"},
{ERR_REASON(RSA_R_PADDING_CHECK_FAILED) ,"padding check failed"},
+{ERR_REASON(RSA_R_PKCS_DECODING_ERROR) ,"pkcs decoding error"},
{ERR_REASON(RSA_R_P_NOT_PRIME) ,"p not prime"},
{ERR_REASON(RSA_R_Q_NOT_PRIME) ,"q not prime"},
{ERR_REASON(RSA_R_RSA_OPERATIONS_NOT_SUPPORTED),"rsa operations not supported"},
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/rsa/rsa.h nodejs-0.11.15/deps/openssl/openssl/crypto/rsa/rsa.h
--- nodejs-0.11.14/deps/openssl/openssl/crypto/rsa/rsa.h 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/rsa/rsa.h 2015-01-20 21:22:17.000000000 +0000
@@ -559,6 +559,7 @@
#define RSA_R_OPERATION_NOT_ALLOWED_IN_FIPS_MODE 158
#define RSA_R_OPERATION_NOT_SUPPORTED_FOR_THIS_KEYTYPE 148
#define RSA_R_PADDING_CHECK_FAILED 114
+#define RSA_R_PKCS_DECODING_ERROR 159
#define RSA_R_P_NOT_PRIME 128
#define RSA_R_Q_NOT_PRIME 129
#define RSA_R_RSA_OPERATIONS_NOT_SUPPORTED 130
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/rsa/rsa_oaep.c nodejs-0.11.15/deps/openssl/openssl/crypto/rsa/rsa_oaep.c
--- nodejs-0.11.14/deps/openssl/openssl/crypto/rsa/rsa_oaep.c 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/rsa/rsa_oaep.c 2015-01-20 21:22:17.000000000 +0000
@@ -18,6 +18,7 @@
* an equivalent notion.
*/
+#include "constant_time_locl.h"
#if !defined(OPENSSL_NO_SHA) && !defined(OPENSSL_NO_SHA1)
#include
@@ -95,92 +96,117 @@
const unsigned char *from, int flen, int num,
const unsigned char *param, int plen)
{
- int i, dblen, mlen = -1;
- const unsigned char *maskeddb;
- int lzero;
- unsigned char *db = NULL, seed[SHA_DIGEST_LENGTH], phash[SHA_DIGEST_LENGTH];
- unsigned char *padded_from;
- int bad = 0;
-
- if (--num < 2 * SHA_DIGEST_LENGTH + 1)
- /* 'num' is the length of the modulus, i.e. does not depend on the
- * particular ciphertext. */
+ int i, dblen, mlen = -1, one_index = 0, msg_index;
+ unsigned int good, found_one_byte;
+ const unsigned char *maskedseed, *maskeddb;
+ /* |em| is the encoded message, zero-padded to exactly |num| bytes:
+ * em = Y || maskedSeed || maskedDB */
+ unsigned char *db = NULL, *em = NULL, seed[EVP_MAX_MD_SIZE],
+ phash[EVP_MAX_MD_SIZE];
+
+ if (tlen <= 0 || flen <= 0)
+ return -1;
+
+ /*
+ * |num| is the length of the modulus; |flen| is the length of the
+ * encoded message. Therefore, for any |from| that was obtained by
+ * decrypting a ciphertext, we must have |flen| <= |num|. Similarly,
+ * num < 2 * SHA_DIGEST_LENGTH + 2 must hold for the modulus
+ * irrespective of the ciphertext, see PKCS #1 v2.2, section 7.1.2.
+ * This does not leak any side-channel information.
+ */
+ if (num < flen || num < 2 * SHA_DIGEST_LENGTH + 2)
goto decoding_err;
- lzero = num - flen;
- if (lzero < 0)
- {
- /* signalling this error immediately after detection might allow
- * for side-channel attacks (e.g. timing if 'plen' is huge
- * -- cf. James H. Manger, "A Chosen Ciphertext Attack on RSA Optimal
- * Asymmetric Encryption Padding (OAEP) [...]", CRYPTO 2001),
- * so we use a 'bad' flag */
- bad = 1;
- lzero = 0;
- flen = num; /* don't overflow the memcpy to padded_from */
- }
-
- dblen = num - SHA_DIGEST_LENGTH;
- db = OPENSSL_malloc(dblen + num);
- if (db == NULL)
+ dblen = num - SHA_DIGEST_LENGTH - 1;
+ db = OPENSSL_malloc(dblen);
+ em = OPENSSL_malloc(num);
+ if (db == NULL || em == NULL)
{
RSAerr(RSA_F_RSA_PADDING_CHECK_PKCS1_OAEP, ERR_R_MALLOC_FAILURE);
- return -1;
+ goto cleanup;
}
- /* Always do this zero-padding copy (even when lzero == 0)
- * to avoid leaking timing info about the value of lzero. */
- padded_from = db + dblen;
- memset(padded_from, 0, lzero);
- memcpy(padded_from + lzero, from, flen);
+ /*
+ * Always do this zero-padding copy (even when num == flen) to avoid
+ * leaking that information. The copy still leaks some side-channel
+ * information, but it's impossible to have a fixed memory access
+ * pattern since we can't read out of the bounds of |from|.
+ *
+ * TODO(emilia): Consider porting BN_bn2bin_padded from BoringSSL.
+ */
+ memset(em, 0, num);
+ memcpy(em + num - flen, from, flen);
+
+ /*
+ * The first byte must be zero, however we must not leak if this is
+ * true. See James H. Manger, "A Chosen Ciphertext Attack on RSA
+ * Optimal Asymmetric Encryption Padding (OAEP) [...]", CRYPTO 2001).
+ */
+ good = constant_time_is_zero(em[0]);
- maskeddb = padded_from + SHA_DIGEST_LENGTH;
+ maskedseed = em + 1;
+ maskeddb = em + 1 + SHA_DIGEST_LENGTH;
if (MGF1(seed, SHA_DIGEST_LENGTH, maskeddb, dblen))
- return -1;
+ goto cleanup;
for (i = 0; i < SHA_DIGEST_LENGTH; i++)
- seed[i] ^= padded_from[i];
-
+ seed[i] ^= maskedseed[i];
+
if (MGF1(db, dblen, seed, SHA_DIGEST_LENGTH))
- return -1;
+ goto cleanup;
for (i = 0; i < dblen; i++)
db[i] ^= maskeddb[i];
if (!EVP_Digest((void *)param, plen, phash, NULL, EVP_sha1(), NULL))
- return -1;
+ goto cleanup;
- if (CRYPTO_memcmp(db, phash, SHA_DIGEST_LENGTH) != 0 || bad)
+ good &= constant_time_is_zero(CRYPTO_memcmp(db, phash, SHA_DIGEST_LENGTH));
+
+ found_one_byte = 0;
+ for (i = SHA_DIGEST_LENGTH; i < dblen; i++)
+ {
+ /* Padding consists of a number of 0-bytes, followed by a 1. */
+ unsigned int equals1 = constant_time_eq(db[i], 1);
+ unsigned int equals0 = constant_time_is_zero(db[i]);
+ one_index = constant_time_select_int(~found_one_byte & equals1,
+ i, one_index);
+ found_one_byte |= equals1;
+ good &= (found_one_byte | equals0);
+ }
+
+ good &= found_one_byte;
+
+ /*
+ * At this point |good| is zero unless the plaintext was valid,
+ * so plaintext-awareness ensures timing side-channels are no longer a
+ * concern.
+ */
+ if (!good)
goto decoding_err;
+
+ msg_index = one_index + 1;
+ mlen = dblen - msg_index;
+
+ if (tlen < mlen)
+ {
+ RSAerr(RSA_F_RSA_PADDING_CHECK_PKCS1_OAEP, RSA_R_DATA_TOO_LARGE);
+ mlen = -1;
+ }
else
{
- for (i = SHA_DIGEST_LENGTH; i < dblen; i++)
- if (db[i] != 0x00)
- break;
- if (i == dblen || db[i] != 0x01)
- goto decoding_err;
- else
- {
- /* everything looks OK */
-
- mlen = dblen - ++i;
- if (tlen < mlen)
- {
- RSAerr(RSA_F_RSA_PADDING_CHECK_PKCS1_OAEP, RSA_R_DATA_TOO_LARGE);
- mlen = -1;
- }
- else
- memcpy(to, db + i, mlen);
- }
+ memcpy(to, db + msg_index, mlen);
+ goto cleanup;
}
- OPENSSL_free(db);
- return mlen;
decoding_err:
- /* to avoid chosen ciphertext attacks, the error message should not reveal
- * which kind of decoding error happened */
+ /* To avoid chosen ciphertext attacks, the error message should not reveal
+ * which kind of decoding error happened. */
RSAerr(RSA_F_RSA_PADDING_CHECK_PKCS1_OAEP, RSA_R_OAEP_DECODING_ERROR);
+cleanup:
if (db != NULL) OPENSSL_free(db);
- return -1;
+ if (em != NULL) OPENSSL_free(em);
+ return mlen;
}
int PKCS1_MGF1(unsigned char *mask, long len,
diff -Nru nodejs-0.11.14/deps/openssl/openssl/crypto/rsa/rsa_pk1.c nodejs-0.11.15/deps/openssl/openssl/crypto/rsa/rsa_pk1.c
--- nodejs-0.11.14/deps/openssl/openssl/crypto/rsa/rsa_pk1.c 2014-09-24 21:46:41.000000000 +0000
+++ nodejs-0.11.15/deps/openssl/openssl/crypto/rsa/rsa_pk1.c 2015-01-20 21:22:17.000000000 +0000
@@ -56,6 +56,8 @@
* [including the GNU Public Licence.]
*/
+#include "constant_time_locl.h"
+
#include
#include "cryptlib.h"
#include