deps: upgrade to npm 2.13.3
authorKat Marchán <kzm@sykosomatic.org>
Sat, 1 Aug 2015 00:08:03 +0000 (17:08 -0700)
committerJeremiah Senkpiel <fishrock123@rocketmail.com>
Sat, 1 Aug 2015 16:45:44 +0000 (09:45 -0700)
PR-URL: https://github.com/nodejs/io.js/pull/2284
Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
320 files changed:
deps/npm/AUTHORS
deps/npm/CHANGELOG.md
deps/npm/doc/files/package.json.md
deps/npm/html/doc/README.html
deps/npm/html/doc/api/npm-bin.html
deps/npm/html/doc/api/npm-bugs.html
deps/npm/html/doc/api/npm-cache.html
deps/npm/html/doc/api/npm-commands.html
deps/npm/html/doc/api/npm-config.html
deps/npm/html/doc/api/npm-deprecate.html
deps/npm/html/doc/api/npm-docs.html
deps/npm/html/doc/api/npm-edit.html
deps/npm/html/doc/api/npm-explore.html
deps/npm/html/doc/api/npm-help-search.html
deps/npm/html/doc/api/npm-init.html
deps/npm/html/doc/api/npm-install.html
deps/npm/html/doc/api/npm-link.html
deps/npm/html/doc/api/npm-load.html
deps/npm/html/doc/api/npm-ls.html
deps/npm/html/doc/api/npm-outdated.html
deps/npm/html/doc/api/npm-owner.html
deps/npm/html/doc/api/npm-pack.html
deps/npm/html/doc/api/npm-ping.html
deps/npm/html/doc/api/npm-prefix.html
deps/npm/html/doc/api/npm-prune.html
deps/npm/html/doc/api/npm-publish.html
deps/npm/html/doc/api/npm-rebuild.html
deps/npm/html/doc/api/npm-repo.html
deps/npm/html/doc/api/npm-restart.html
deps/npm/html/doc/api/npm-root.html
deps/npm/html/doc/api/npm-run-script.html
deps/npm/html/doc/api/npm-search.html
deps/npm/html/doc/api/npm-shrinkwrap.html
deps/npm/html/doc/api/npm-start.html
deps/npm/html/doc/api/npm-stop.html
deps/npm/html/doc/api/npm-tag.html
deps/npm/html/doc/api/npm-test.html
deps/npm/html/doc/api/npm-uninstall.html
deps/npm/html/doc/api/npm-unpublish.html
deps/npm/html/doc/api/npm-update.html
deps/npm/html/doc/api/npm-version.html
deps/npm/html/doc/api/npm-view.html
deps/npm/html/doc/api/npm-whoami.html
deps/npm/html/doc/api/npm.html
deps/npm/html/doc/cli/npm-access.html
deps/npm/html/doc/cli/npm-adduser.html
deps/npm/html/doc/cli/npm-bin.html
deps/npm/html/doc/cli/npm-bugs.html
deps/npm/html/doc/cli/npm-build.html
deps/npm/html/doc/cli/npm-bundle.html
deps/npm/html/doc/cli/npm-cache.html
deps/npm/html/doc/cli/npm-completion.html
deps/npm/html/doc/cli/npm-config.html
deps/npm/html/doc/cli/npm-dedupe.html
deps/npm/html/doc/cli/npm-deprecate.html
deps/npm/html/doc/cli/npm-dist-tag.html
deps/npm/html/doc/cli/npm-docs.html
deps/npm/html/doc/cli/npm-edit.html
deps/npm/html/doc/cli/npm-explore.html
deps/npm/html/doc/cli/npm-help-search.html
deps/npm/html/doc/cli/npm-help.html
deps/npm/html/doc/cli/npm-init.html
deps/npm/html/doc/cli/npm-install.html
deps/npm/html/doc/cli/npm-link.html
deps/npm/html/doc/cli/npm-logout.html
deps/npm/html/doc/cli/npm-ls.html
deps/npm/html/doc/cli/npm-outdated.html
deps/npm/html/doc/cli/npm-owner.html
deps/npm/html/doc/cli/npm-pack.html
deps/npm/html/doc/cli/npm-ping.html
deps/npm/html/doc/cli/npm-prefix.html
deps/npm/html/doc/cli/npm-prune.html
deps/npm/html/doc/cli/npm-publish.html
deps/npm/html/doc/cli/npm-rebuild.html
deps/npm/html/doc/cli/npm-repo.html
deps/npm/html/doc/cli/npm-restart.html
deps/npm/html/doc/cli/npm-rm.html
deps/npm/html/doc/cli/npm-root.html
deps/npm/html/doc/cli/npm-run-script.html
deps/npm/html/doc/cli/npm-search.html
deps/npm/html/doc/cli/npm-shrinkwrap.html
deps/npm/html/doc/cli/npm-star.html
deps/npm/html/doc/cli/npm-stars.html
deps/npm/html/doc/cli/npm-start.html
deps/npm/html/doc/cli/npm-stop.html
deps/npm/html/doc/cli/npm-tag.html
deps/npm/html/doc/cli/npm-test.html
deps/npm/html/doc/cli/npm-uninstall.html
deps/npm/html/doc/cli/npm-unpublish.html
deps/npm/html/doc/cli/npm-update.html
deps/npm/html/doc/cli/npm-version.html
deps/npm/html/doc/cli/npm-view.html
deps/npm/html/doc/cli/npm-whoami.html
deps/npm/html/doc/cli/npm.html
deps/npm/html/doc/files/npm-folders.html
deps/npm/html/doc/files/npm-global.html
deps/npm/html/doc/files/npm-json.html
deps/npm/html/doc/files/npmrc.html
deps/npm/html/doc/files/package.json.html
deps/npm/html/doc/index.html
deps/npm/html/doc/misc/npm-coding-style.html
deps/npm/html/doc/misc/npm-config.html
deps/npm/html/doc/misc/npm-developers.html
deps/npm/html/doc/misc/npm-disputes.html
deps/npm/html/doc/misc/npm-faq.html
deps/npm/html/doc/misc/npm-index.html
deps/npm/html/doc/misc/npm-registry.html
deps/npm/html/doc/misc/npm-scope.html
deps/npm/html/doc/misc/npm-scripts.html
deps/npm/html/doc/misc/removing-npm.html
deps/npm/html/doc/misc/semver.html
deps/npm/html/partial/doc/README.html
deps/npm/html/partial/doc/api/npm.html
deps/npm/html/partial/doc/cli/npm-ls.html
deps/npm/html/partial/doc/cli/npm.html
deps/npm/html/partial/doc/files/npm-json.html
deps/npm/html/partial/doc/files/package.json.html
deps/npm/html/partial/doc/misc/npm-disputes.html
deps/npm/html/partial/doc/misc/npm-faq.html
deps/npm/man/man1/npm-ls.1
deps/npm/man/man1/npm.1
deps/npm/man/man3/npm.3
deps/npm/man/man5/npm-json.5
deps/npm/man/man5/package.json.5
deps/npm/node_modules/init-package-json/package.json
deps/npm/node_modules/minimatch/browser.js
deps/npm/node_modules/minimatch/minimatch.js
deps/npm/node_modules/minimatch/node_modules/brace-expansion/node_modules/concat-map/package.json
deps/npm/node_modules/minimatch/package.json
deps/npm/node_modules/node-gyp/addon.gypi
deps/npm/node_modules/node-gyp/lib/build.js
deps/npm/node_modules/node-gyp/lib/install.js
deps/npm/node_modules/node-gyp/node_modules/path-array/node_modules/array-index/.jshintrc [deleted file]
deps/npm/node_modules/node-gyp/node_modules/path-array/node_modules/array-index/node_modules/debug/.jshintrc [deleted file]
deps/npm/node_modules/node-gyp/node_modules/semver/.npmignore [new file with mode: 0644]
deps/npm/node_modules/node-gyp/node_modules/semver/.travis.yml [new file with mode: 0644]
deps/npm/node_modules/node-gyp/node_modules/semver/LICENSE [moved from deps/npm/node_modules/rimraf/node_modules/glob/LICENSE with 100% similarity]
deps/npm/node_modules/node-gyp/node_modules/semver/Makefile [moved from deps/npm/node_modules/semver/Makefile with 100% similarity]
deps/npm/node_modules/node-gyp/node_modules/semver/README.md [new file with mode: 0644]
deps/npm/node_modules/node-gyp/node_modules/semver/bin/semver [new file with mode: 0755]
deps/npm/node_modules/node-gyp/node_modules/semver/foot.js.txt [moved from deps/npm/node_modules/semver/foot.js.txt with 100% similarity]
deps/npm/node_modules/node-gyp/node_modules/semver/head.js.txt [moved from deps/npm/node_modules/semver/head.js.txt with 95% similarity]
deps/npm/node_modules/node-gyp/node_modules/semver/package.json [new file with mode: 0644]
deps/npm/node_modules/node-gyp/node_modules/semver/semver.browser.js [moved from deps/npm/node_modules/semver/semver.browser.js with 100% similarity]
deps/npm/node_modules/node-gyp/node_modules/semver/semver.browser.js.gz [moved from deps/npm/node_modules/semver/semver.browser.js.gz with 100% similarity]
deps/npm/node_modules/node-gyp/node_modules/semver/semver.js [new file with mode: 0644]
deps/npm/node_modules/node-gyp/node_modules/semver/semver.min.js [moved from deps/npm/node_modules/semver/semver.min.js with 100% similarity]
deps/npm/node_modules/node-gyp/node_modules/semver/semver.min.js.gz [moved from deps/npm/node_modules/semver/semver.min.js.gz with 100% similarity]
deps/npm/node_modules/node-gyp/node_modules/semver/test/amd.js [moved from deps/npm/node_modules/semver/test/amd.js with 100% similarity]
deps/npm/node_modules/node-gyp/node_modules/semver/test/big-numbers.js [new file with mode: 0644]
deps/npm/node_modules/node-gyp/node_modules/semver/test/clean.js [new file with mode: 0644]
deps/npm/node_modules/node-gyp/node_modules/semver/test/gtr.js [new file with mode: 0644]
deps/npm/node_modules/node-gyp/node_modules/semver/test/index.js [new file with mode: 0644]
deps/npm/node_modules/node-gyp/node_modules/semver/test/ltr.js [new file with mode: 0644]
deps/npm/node_modules/node-gyp/node_modules/semver/test/major-minor-patch.js [new file with mode: 0644]
deps/npm/node_modules/node-gyp/node_modules/semver/test/no-module.js [moved from deps/npm/node_modules/semver/test/no-module.js with 99% similarity]
deps/npm/node_modules/normalize-package-data/package.json
deps/npm/node_modules/npm-install-checks/package.json
deps/npm/node_modules/npm-package-arg/package.json
deps/npm/node_modules/npm-registry-client/node_modules/concat-stream/node_modules/readable-stream/lib/_stream_readable.js
deps/npm/node_modules/npm-registry-client/node_modules/concat-stream/node_modules/readable-stream/lib/_stream_writable.js
deps/npm/node_modules/npm-registry-client/node_modules/concat-stream/node_modules/readable-stream/node_modules/core-util-is/package.json
deps/npm/node_modules/npm-registry-client/node_modules/concat-stream/node_modules/readable-stream/node_modules/isarray/package.json
deps/npm/node_modules/npm-registry-client/node_modules/concat-stream/node_modules/readable-stream/node_modules/process-nextick-args/package.json
deps/npm/node_modules/npm-registry-client/node_modules/concat-stream/node_modules/readable-stream/node_modules/process-nextick-args/readme.md
deps/npm/node_modules/npm-registry-client/node_modules/concat-stream/node_modules/readable-stream/node_modules/string_decoder/package.json
deps/npm/node_modules/npm-registry-client/node_modules/concat-stream/node_modules/readable-stream/package.json
deps/npm/node_modules/npm-registry-client/node_modules/concat-stream/node_modules/typedarray/package.json
deps/npm/node_modules/npm-registry-client/node_modules/graceful-fs/package.json
deps/npm/node_modules/npm-registry-client/package.json
deps/npm/node_modules/read-installed/node_modules/graceful-fs/package.json
deps/npm/node_modules/read-installed/package.json
deps/npm/node_modules/request/.eslintrc [deleted file]
deps/npm/node_modules/request/CHANGELOG.md
deps/npm/node_modules/request/README.md
deps/npm/node_modules/request/lib/helpers.js
deps/npm/node_modules/request/lib/oauth.js
deps/npm/node_modules/request/lib/redirect.js
deps/npm/node_modules/request/node_modules/aws-sign2/package.json
deps/npm/node_modules/request/node_modules/bl/.jshintrc [deleted file]
deps/npm/node_modules/request/node_modules/bl/.travis.yml
deps/npm/node_modules/request/node_modules/bl/README.md
deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/.travis.yml [new file with mode: 0644]
deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/.zuul.yml [new file with mode: 0644]
deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/README.md
deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/doc/stream.markdown [new file with mode: 0644]
deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/doc/wg-meetings/2015-01-30.md [new file with mode: 0644]
deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/lib/_stream_duplex.js
deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/lib/_stream_passthrough.js
deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/lib/_stream_readable.js
deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/lib/_stream_transform.js
deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/lib/_stream_writable.js
deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/core-util-is/package.json
deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/isarray/package.json
deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/process-nextick-args/.travis.yml [new file with mode: 0644]
deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/process-nextick-args/index.js [new file with mode: 0644]
deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/process-nextick-args/package.json [new file with mode: 0644]
deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/process-nextick-args/readme.md [new file with mode: 0644]
deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/process-nextick-args/test.js [new file with mode: 0644]
deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/string_decoder/package.json
deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/util-deprecate/History.md [new file with mode: 0644]
deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/util-deprecate/LICENSE [new file with mode: 0644]
deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/util-deprecate/README.md [new file with mode: 0644]
deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/util-deprecate/browser.js [new file with mode: 0644]
deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/util-deprecate/node.js [new file with mode: 0644]
deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/util-deprecate/package.json [new file with mode: 0644]
deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/package.json
deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/readable.js
deps/npm/node_modules/request/node_modules/bl/package.json
deps/npm/node_modules/request/node_modules/caseless/LICENSE [new file with mode: 0644]
deps/npm/node_modules/request/node_modules/caseless/index.js
deps/npm/node_modules/request/node_modules/caseless/package.json
deps/npm/node_modules/request/node_modules/extend/.eslintrc [deleted file]
deps/npm/node_modules/request/node_modules/extend/.jscs.json
deps/npm/node_modules/request/node_modules/extend/.travis.yml
deps/npm/node_modules/request/node_modules/extend/CHANGELOG.md
deps/npm/node_modules/request/node_modules/extend/component.json
deps/npm/node_modules/request/node_modules/extend/index.js
deps/npm/node_modules/request/node_modules/extend/package.json
deps/npm/node_modules/request/node_modules/forever-agent/package.json
deps/npm/node_modules/request/node_modules/form-data/lib/browser.js [new file with mode: 0644]
deps/npm/node_modules/request/node_modules/form-data/lib/form_data.js
deps/npm/node_modules/request/node_modules/form-data/node_modules/async/.jscsrc [new file with mode: 0644]
deps/npm/node_modules/request/node_modules/form-data/node_modules/async/README.md
deps/npm/node_modules/request/node_modules/form-data/node_modules/async/lib/async.js
deps/npm/node_modules/request/node_modules/form-data/node_modules/async/package.json
deps/npm/node_modules/request/node_modules/form-data/node_modules/mime-types/HISTORY.md [deleted file]
deps/npm/node_modules/request/node_modules/form-data/node_modules/mime-types/LICENSE [deleted file]
deps/npm/node_modules/request/node_modules/form-data/node_modules/mime-types/README.md [deleted file]
deps/npm/node_modules/request/node_modules/form-data/node_modules/mime-types/index.js [deleted file]
deps/npm/node_modules/request/node_modules/form-data/node_modules/mime-types/node_modules/mime-db/HISTORY.md [deleted file]
deps/npm/node_modules/request/node_modules/form-data/node_modules/mime-types/node_modules/mime-db/LICENSE [deleted file]
deps/npm/node_modules/request/node_modules/form-data/node_modules/mime-types/node_modules/mime-db/README.md [deleted file]
deps/npm/node_modules/request/node_modules/form-data/node_modules/mime-types/node_modules/mime-db/db.json [deleted file]
deps/npm/node_modules/request/node_modules/form-data/node_modules/mime-types/node_modules/mime-db/index.js [deleted file]
deps/npm/node_modules/request/node_modules/form-data/node_modules/mime-types/node_modules/mime-db/package.json [deleted file]
deps/npm/node_modules/request/node_modules/form-data/node_modules/mime-types/package.json [deleted file]
deps/npm/node_modules/request/node_modules/form-data/package.json
deps/npm/node_modules/request/node_modules/har-validator/node_modules/bluebird/LICENSE
deps/npm/node_modules/request/node_modules/har-validator/node_modules/bluebird/changelog.md
deps/npm/node_modules/request/node_modules/har-validator/node_modules/bluebird/js/browser/bluebird.js
deps/npm/node_modules/request/node_modules/har-validator/node_modules/bluebird/js/browser/bluebird.min.js
deps/npm/node_modules/request/node_modules/har-validator/node_modules/bluebird/js/main/bind.js
deps/npm/node_modules/request/node_modules/har-validator/node_modules/bluebird/js/main/catch_filter.js
deps/npm/node_modules/request/node_modules/har-validator/node_modules/bluebird/js/main/finally.js
deps/npm/node_modules/request/node_modules/har-validator/node_modules/bluebird/js/main/map.js
deps/npm/node_modules/request/node_modules/har-validator/node_modules/bluebird/js/main/nodeify.js
deps/npm/node_modules/request/node_modules/har-validator/node_modules/bluebird/js/main/promise.js
deps/npm/node_modules/request/node_modules/har-validator/node_modules/bluebird/js/main/reduce.js
deps/npm/node_modules/request/node_modules/har-validator/node_modules/bluebird/package.json
deps/npm/node_modules/request/node_modules/har-validator/node_modules/chalk/node_modules/escape-string-regexp/package.json
deps/npm/node_modules/request/node_modules/har-validator/node_modules/commander/node_modules/graceful-readlink/package.json
deps/npm/node_modules/request/node_modules/har-validator/node_modules/is-my-json-valid/node_modules/generate-function/package.json
deps/npm/node_modules/request/node_modules/har-validator/node_modules/is-my-json-valid/node_modules/generate-object-property/node_modules/is-property/package.json
deps/npm/node_modules/request/node_modules/har-validator/node_modules/is-my-json-valid/node_modules/jsonpointer/package.json
deps/npm/node_modules/request/node_modules/har-validator/node_modules/is-my-json-valid/node_modules/xtend/.jshintrc [deleted file]
deps/npm/node_modules/request/node_modules/har-validator/node_modules/is-my-json-valid/node_modules/xtend/package.json
deps/npm/node_modules/request/node_modules/hawk/.npmignore
deps/npm/node_modules/request/node_modules/hawk/.travis.yml
deps/npm/node_modules/request/node_modules/hawk/Makefile [deleted file]
deps/npm/node_modules/request/node_modules/hawk/README.md
deps/npm/node_modules/request/node_modules/hawk/example/usage.js
deps/npm/node_modules/request/node_modules/hawk/index.js [deleted file]
deps/npm/node_modules/request/node_modules/hawk/lib/browser.js
deps/npm/node_modules/request/node_modules/hawk/lib/client.js
deps/npm/node_modules/request/node_modules/hawk/lib/server.js
deps/npm/node_modules/request/node_modules/hawk/lib/utils.js
deps/npm/node_modules/request/node_modules/hawk/node_modules/boom/package.json
deps/npm/node_modules/request/node_modules/hawk/node_modules/cryptiles/package.json
deps/npm/node_modules/request/node_modules/hawk/node_modules/sntp/package.json
deps/npm/node_modules/request/node_modules/hawk/package.json
deps/npm/node_modules/request/node_modules/hawk/test/browser.js
deps/npm/node_modules/request/node_modules/hawk/test/client.js
deps/npm/node_modules/request/node_modules/hawk/test/crypto.js
deps/npm/node_modules/request/node_modules/hawk/test/message.js [deleted file]
deps/npm/node_modules/request/node_modules/hawk/test/readme.js
deps/npm/node_modules/request/node_modules/hawk/test/server.js
deps/npm/node_modules/request/node_modules/hawk/test/uri.js
deps/npm/node_modules/request/node_modules/hawk/test/utils.js
deps/npm/node_modules/request/node_modules/http-signature/node_modules/asn1/package.json
deps/npm/node_modules/request/node_modules/http-signature/node_modules/assert-plus/package.json
deps/npm/node_modules/request/node_modules/http-signature/node_modules/ctype/package.json
deps/npm/node_modules/request/node_modules/isstream/.jshintrc [deleted file]
deps/npm/node_modules/request/node_modules/isstream/package.json
deps/npm/node_modules/request/node_modules/mime-types/HISTORY.md
deps/npm/node_modules/request/node_modules/mime-types/LICENSE
deps/npm/node_modules/request/node_modules/mime-types/README.md
deps/npm/node_modules/request/node_modules/mime-types/index.js
deps/npm/node_modules/request/node_modules/mime-types/node_modules/mime-db/HISTORY.md
deps/npm/node_modules/request/node_modules/mime-types/node_modules/mime-db/README.md
deps/npm/node_modules/request/node_modules/mime-types/node_modules/mime-db/db.json
deps/npm/node_modules/request/node_modules/mime-types/node_modules/mime-db/package.json
deps/npm/node_modules/request/node_modules/mime-types/package.json
deps/npm/node_modules/request/node_modules/qs/.jshintignore [deleted file]
deps/npm/node_modules/request/node_modules/qs/Makefile [deleted file]
deps/npm/node_modules/request/node_modules/qs/Readme.md
deps/npm/node_modules/request/node_modules/qs/index.js [deleted file]
deps/npm/node_modules/request/node_modules/qs/lib/parse.js
deps/npm/node_modules/request/node_modules/qs/lib/utils.js
deps/npm/node_modules/request/node_modules/qs/package.json
deps/npm/node_modules/request/node_modules/qs/test/parse.js
deps/npm/node_modules/request/node_modules/qs/test/stringify.js
deps/npm/node_modules/request/node_modules/stringstream/package.json
deps/npm/node_modules/request/node_modules/tunnel-agent/.jshintrc [deleted file]
deps/npm/node_modules/request/package.json
deps/npm/node_modules/request/request.js
deps/npm/node_modules/rimraf/README.md
deps/npm/node_modules/rimraf/node_modules/glob/README.md [deleted file]
deps/npm/node_modules/rimraf/node_modules/glob/common.js [deleted file]
deps/npm/node_modules/rimraf/node_modules/glob/glob.js [deleted file]
deps/npm/node_modules/rimraf/node_modules/glob/package.json [deleted file]
deps/npm/node_modules/rimraf/node_modules/glob/sync.js [deleted file]
deps/npm/node_modules/rimraf/package.json
deps/npm/node_modules/semver/package.json
deps/npm/node_modules/semver/semver.js
deps/npm/package.json
deps/npm/scripts/release.sh
deps/npm/test/npm_cache/npm-test-preferglobal-dep/0.0.0/package.tgz [new file with mode: 0644]
deps/npm/test/npm_cache/npm-test-preferglobal-dep/0.0.0/package/package.json [new file with mode: 0644]
deps/npm/test/npm_cache/registry.npmjs.org/jshint/.cache.json [new file with mode: 0644]

index 16bda38..9f48c3b 100644 (file)
@@ -298,3 +298,6 @@ Joseph Dykstra <josephdykstra@gmail.com>
 Joshua Egan <josh-egan@users.noreply.github.com>
 Thomas Cort <thomasc@ssimicro.com>
 Thaddee Tyl <thaddee.tyl@gmail.com>
+Steve Klabnik <steve@steveklabnik.com>
+Andrew Murray <radarhere@gmail.com>
+Stephan Bönnemann <stephan@excellenteasy.com>
index 5cc9c3c..3db382c 100644 (file)
@@ -1,3 +1,104 @@
+### v2.13.3 (2015-07-23):
+
+#### I'M SAVING THE GOOD JOKES FOR MORE INTERESTING RELEASES
+
+It's pretty hard to outdo last week's release buuuuut~ I promise I'll have a
+treat when we release our shiny new **Teams and Organizations** feature! :D
+(Coming Soon™). It'll be a real *gem*.
+
+That means it's a pretty low-key release this week. We got some nice
+documentation tweaks, a few bugfixes, and other such things, though!
+
+Oh, and a _bunch of version bumps_. Thanks, `semver`!
+
+#### IT'S THE LITTLE THINGS THAT MATTER
+
+* [`2fac6ae`](https://github.com/npm/npm/commit/2fac6aeffefba2934c3db395b525d931599c34d8)
+  [#9012](https://github.com/npm/npm/issues/9012) A convenience for releases --
+  using the globally-installed npm before now was causing minor annoyances, so
+  we just use the exact same npm we're releasing to build the new release.
+  ([@zkat](https://github.com/zkat))
+
+#### WHAT DOES THIS BUTTON DO?
+
+There's a couple of doc updates! The last one might be interesting.
+
+* [`4cd3205`](https://github.com/npm/npm/commit/4cd32050c0f89b7f1ae486354fa2c35eea302ba5)
+  [#9002](https://github.com/npm/npm/issues/9002) Updated docs to list the
+  various files that npm automatically includes and excludes, regardless of
+  settings.
+  ([@SimenB](https://github.com/SimenB))
+* [`cf09e75`](https://github.com/npm/npm/commit/cf09e754931739af32647d667b671e72a4c79081)
+
+  [#9022](https://github.com/npm/npm/issues/9022) Document the `"access"` field
+  in `"publishConfig"`. Did you know you don't need to use `--access=public`
+  when publishing scoped packages?! Just put it in your `package.json`!
+  Go refresh yourself on scopes packages by [checking our docs](https://docs.npmjs.com/getting-started/scoped-packages) on them.
+
+  ([@boennemann](https://github.com/boennemann))
+* [`bfd73da`](https://github.com/npm/npm/commit/bfd73da33349cc2afb8278953b2ae16ea95023de)
+  [#9013](https://github.com/npm/npm/issues/9013) fixed typo in changelog
+  ([@radarhere](https://github.com/radarhere))
+
+#### THE SEMVER MAJOR VERSION APOCALYPSE IS UPON US
+
+Basically, `semver` is up to `@5`, and that meant we needed to go in an update a
+bunch of our dependencies manually. `node-gyp` is still pending update, since
+it's not ours, though!
+
+* [`9232e58`](https://github.com/npm/npm/commit/9232e58d54c032c23716ef976023d36a42bfdcc9)
+  [#8972](https://github.com/npm/npm/issues/8972) `init-package-json@1.7.1`
+  ([@othiym23](https://github.com/othiym23))
+* [`ba44f6b`](https://github.com/npm/npm/commit/ba44f6b4201a4faee025341b123e372d8f45b6d9)
+  [#8972](https://github.com/npm/npm/issues/8972) `normalize-package-data@2.3.1`
+  ([@othiym23](https://github.com/othiym23))
+* [`3901d3c`](https://github.com/npm/npm/commit/3901d3cf191880bb4420b1d6b8aedbcd8fc26cdf)
+  [#8972](https://github.com/npm/npm/issues/8972) `npm-install-checks@1.0.6`
+  ([@othiym23](https://github.com/othiym23))
+* [`ffcc7dd`](https://github.com/npm/npm/commit/ffcc7dd12f8bb94ff0f64c465c57e460b3f24a24)
+  [#8972](https://github.com/npm/npm/issues/8972) `npm-package-arg@4.0.2`
+  ([@othiym23](https://github.com/othiym23))
+* [`7128f9e`](https://github.com/npm/npm/commit/7128f9ec10c0c8482087511b716dbddb54249626)
+  [#8972](https://github.com/npm/npm/issues/8972) `npm-registry-client@6.5.1`
+  ([@othiym23](https://github.com/othiym23))
+* [`af28911`](https://github.com/npm/npm/commit/af28911ecd54a844f848c6ae41887097d6aa2f3b)
+  [#8972](https://github.com/npm/npm/issues/8972) `read-installed@4.0.2`
+  ([@othiym23](https://github.com/othiym23))
+* [`3cc817a`](https://github.com/npm/npm/commit/3cc817a0f34f698b580ff6ff02308700efc54f7c)
+  [#8972](https://github.com/npm/npm/issues/8972) node-gyp needs its own version
+  of semver
+  ([@othiym23](https://github.com/othiym23))
+* [`f98eccc`](https://github.com/npm/npm/commit/f98eccc6e3a6699ca0aa9ecbad93a3b995583871)
+  [#8972](https://github.com/npm/npm/issues/8972) `semver@5.0.1`: Stop including
+  browser builds.
+  ([@isaacs](https://github.com/isaacs))
+
+#### \*BUMP\*
+
+And some other version bumps for good measure.
+
+* [`254ecfb`](https://github.com/npm/npm/commit/254ecfb04f026c2fd16427db01a53600c1892c8b)
+  [#8990](https://github.com/npm/npm/issues/8990) `marked-man@0.1.5`: Fixes an
+  issue with documentation rendering where backticks in 2nd-level headers would
+  break rendering (?!?!)
+  ([@steveklabnik](https://github.com/steveklabnik))
+* [`79efd79`](https://github.com/npm/npm/commit/79efd79ac216da8cee8636fb2ed926b0196a4eb6)
+  `minimatch@2.0.10`: A pattern like `'*.!(x).!(y)'` should not match a name
+  like `'a.xyz.yab'`.
+  ([@isaacs](https://github.com/isaacs))
+* [`39c7dc9`](https://github.com/npm/npm/commit/39c7dc9a4e17cd35a5ed882ba671821c9a900f9e)
+  `request@2.60.0`: A few bug fixes and doc updates.
+  ([@simov](https://github.com/simov))
+* [`72d3c3a`](https://github.com/npm/npm/commit/72d3c3a9e1e461608aa21b14c01a650333330da9)
+  `rimraf@2.4.2`: Minor doc and dep updates
+  ([@isaacs](https://github.com/isaacs))
+* [`7513035`](https://github.com/npm/npm/commit/75130356a06f5f4fbec3786aac9f9f0b36dfe010)
+  `nock@2.9.1`
+  ([@pgte](https://github.com/pgte))
+* [`3d9aa82`](https://github.com/npm/npm/commit/3d9aa82260f0643a32c13d0c1ed16f644b6fd4ab)
+  Fixes this thing where Kat decided to save `nock` as a regular dependency ;)
+  ([@othiym23](https://github.com/othiym23))
+
 ### v2.13.2 (2015-07-16):
 
 #### HOLD ON TO YOUR TENTACLES... IT'S NPM RELEASE TIME!
@@ -138,7 +239,7 @@ right back. This should help out folks dealing with things like proxy issues or
 other registry-access debugging issues. Give it a shot!
 
 This addresses [#5750](https://github.com/npm/npm/issues/5750), and will help
-with the `npm doctor` stuff descripbed in
+with the `npm doctor` stuff described in
 [#6756](https://github.com/npm/npm/issues/6756).
 
 * [`f1f7a85`](https://github.com/npm/npm/commit/f1f7a85)
index a63b758..b0d86d9 100644 (file)
@@ -183,6 +183,26 @@ 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".
 
+Certain files are always included, regardless of settings:
+
+* `package.json`
+* `README` (and its variants)
+* `CHANGELOG` (and its variants)
+* `LICENSE` / `LICENCE`
+
+Conversely, some files are always ignored:
+
+* `.git`
+* `CVS`
+* `.svn`
+* `.hg`
+* `.lock-wscript`
+* `.wafpickle-N`
+* `*.swp`
+* `.DS_Store`
+* `._*`
+* `npm-debug.log`
+
 ## main
 
 The main field is a module ID that is the primary entry point to your program.
@@ -670,13 +690,13 @@ 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.
+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, registry or access, so that
+you can ensure that a given package is not tagged with "latest", published
+to the global public registry or that a scoped module is private by default.
 
-Any config values can be overridden, but of course only "tag" and
-"registry" probably matter for the purposes of publishing.
+Any config values can be overridden, but of course only "tag", "registry" and
+"access" probably matter for the purposes of publishing.
 
 See `npm-config(7)` to see the list of config options that can be
 overridden.
index 5086edc..0ad6f04 100644 (file)
@@ -140,7 +140,7 @@ specific purpose, or lack of malice in any given npm package.</p>
 <p>If you have a complaint about a package in the public npm registry,
 and cannot <a href="https://docs.npmjs.com/misc/disputes">resolve it with the package
 owner</a>, please email
-<a href="&#109;&#97;&#105;&#x6c;&#x74;&#x6f;&#x3a;&#x73;&#x75;&#112;&#x70;&#x6f;&#114;&#116;&#x40;&#x6e;&#112;&#x6d;&#x6a;&#115;&#46;&#99;&#x6f;&#x6d;">&#x73;&#x75;&#112;&#x70;&#x6f;&#114;&#116;&#x40;&#x6e;&#112;&#x6d;&#x6a;&#115;&#46;&#99;&#x6f;&#x6d;</a> and explain the situation.</p>
+<a href="&#109;&#97;&#x69;&#108;&#116;&#x6f;&#58;&#x73;&#x75;&#x70;&#x70;&#111;&#x72;&#x74;&#64;&#x6e;&#112;&#109;&#106;&#x73;&#x2e;&#99;&#111;&#x6d;">&#x73;&#x75;&#x70;&#x70;&#111;&#x72;&#x74;&#64;&#x6e;&#112;&#109;&#106;&#x73;&#x2e;&#99;&#111;&#x6d;</a> and explain the situation.</p>
 <p>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.</p>
@@ -183,5 +183,5 @@ will no doubt tell you to put the output in a gist or email.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer"><a href="../doc/README.html">README</a> &mdash; npm@2.13.2</p>
+<p id="footer"><a href="../doc/README.html">README</a> &mdash; npm@2.13.3</p>
 
index 41f8f97..5dbec20 100644 (file)
@@ -28,5 +28,5 @@ to the <code>npm.bin</code> property.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-bin &mdash; npm@2.13.2</p>
+<p id="footer">npm-bin &mdash; npm@2.13.3</p>
 
index c98f00f..e86f384 100644 (file)
@@ -33,5 +33,5 @@ friendly for programmatic use.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-bugs &mdash; npm@2.13.2</p>
+<p id="footer">npm-bugs &mdash; npm@2.13.3</p>
 
index 056740b..5419551 100644 (file)
@@ -42,5 +42,5 @@ incrementation.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-cache &mdash; npm@2.13.2</p>
+<p id="footer">npm-cache &mdash; npm@2.13.3</p>
 
index c69be73..bdff581 100644 (file)
@@ -36,5 +36,5 @@ usage, or <code>man 3 npm-&lt;command&gt;</code> for programmatic usage.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-commands &mdash; npm@2.13.2</p>
+<p id="footer">npm-commands &mdash; npm@2.13.3</p>
 
index 32cd128..5185aa8 100644 (file)
@@ -57,5 +57,5 @@ functions instead.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-config &mdash; npm@2.13.2</p>
+<p id="footer">npm-config &mdash; npm@2.13.3</p>
 
index bbc6f6f..965d468 100644 (file)
@@ -47,5 +47,5 @@ a deprecation warning to all who attempt to install it.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-deprecate &mdash; npm@2.13.2</p>
+<p id="footer">npm-deprecate &mdash; npm@2.13.3</p>
 
index efe7b45..b3d061a 100644 (file)
@@ -33,5 +33,5 @@ friendly for programmatic use.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-docs &mdash; npm@2.13.2</p>
+<p id="footer">npm-docs &mdash; npm@2.13.3</p>
 
index 9f57abf..7de6185 100644 (file)
@@ -36,5 +36,5 @@ and how this is used.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-edit &mdash; npm@2.13.2</p>
+<p id="footer">npm-edit &mdash; npm@2.13.3</p>
 
index 54c1121..a764537 100644 (file)
@@ -31,5 +31,5 @@ sure to use <code>npm rebuild &lt;pkg&gt;</code> if you make any changes.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-explore &mdash; npm@2.13.2</p>
+<p id="footer">npm-explore &mdash; npm@2.13.3</p>
 
index 689405b..550240f 100644 (file)
@@ -44,5 +44,5 @@ Name of the file that matched</li>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-help-search &mdash; npm@2.13.2</p>
+<p id="footer">npm-help-search &mdash; npm@2.13.3</p>
 
index ab81d03..899e877 100644 (file)
@@ -39,5 +39,5 @@ then go ahead and use this programmatically.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-init &mdash; npm@2.13.2</p>
+<p id="footer">npm-init &mdash; npm@2.13.3</p>
 
index ff39406..1bb1043 100644 (file)
@@ -32,5 +32,5 @@ installed or when an error has been encountered.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-install &mdash; npm@2.13.2</p>
+<p id="footer">npm-install &mdash; npm@2.13.3</p>
 
index c748606..7eac566 100644 (file)
@@ -42,5 +42,5 @@ the package in the current working directory</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-link &mdash; npm@2.13.2</p>
+<p id="footer">npm-link &mdash; npm@2.13.3</p>
 
index c78bb6d..320d1d3 100644 (file)
@@ -37,5 +37,5 @@ config object.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-load &mdash; npm@2.13.2</p>
+<p id="footer">npm-load &mdash; npm@2.13.3</p>
 
index cdc1640..e65c192 100644 (file)
@@ -63,5 +63,5 @@ dependency will only be output once.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-ls &mdash; npm@2.13.2</p>
+<p id="footer">npm-ls &mdash; npm@2.13.3</p>
 
index 16ade45..3327649 100644 (file)
@@ -28,5 +28,5 @@ currently outdated.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-outdated &mdash; npm@2.13.2</p>
+<p id="footer">npm-outdated &mdash; npm@2.13.3</p>
 
index e9e0412..aeea030 100644 (file)
@@ -47,5 +47,5 @@ that is not implemented at this time.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-owner &mdash; npm@2.13.2</p>
+<p id="footer">npm-owner &mdash; npm@2.13.3</p>
 
index d807c19..4518abf 100644 (file)
@@ -33,5 +33,5 @@ overwritten the second time.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-pack &mdash; npm@2.13.2</p>
+<p id="footer">npm-pack &mdash; npm@2.13.3</p>
 
index 4c664c8..f3a4e7a 100644 (file)
@@ -29,4 +29,4 @@ to npm registries.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-ping &mdash; npm@2.13.2</p>
+<p id="footer">npm-ping &mdash; npm@2.13.3</p>
index adafe21..45f4bdb 100644 (file)
@@ -29,5 +29,5 @@
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-prefix &mdash; npm@2.13.2</p>
+<p id="footer">npm-prefix &mdash; npm@2.13.3</p>
 
index e6b056a..9a24066 100644 (file)
@@ -30,5 +30,5 @@ package&#39;s dependencies list.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-prune &mdash; npm@2.13.2</p>
+<p id="footer">npm-prune &mdash; npm@2.13.3</p>
 
index 6f1701f..92302a1 100644 (file)
@@ -46,5 +46,5 @@ the registry.  Overwrites when the &quot;force&quot; environment variable is set
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-publish &mdash; npm@2.13.2</p>
+<p id="footer">npm-publish &mdash; npm@2.13.3</p>
 
index 09b9d01..65d10c5 100644 (file)
@@ -30,5 +30,5 @@ the new binary. If no &#39;packages&#39; parameter is specify, every package wil
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-rebuild &mdash; npm@2.13.2</p>
+<p id="footer">npm-rebuild &mdash; npm@2.13.3</p>
 
index fa4c357..84956f1 100644 (file)
@@ -33,5 +33,5 @@ friendly for programmatic use.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-repo &mdash; npm@2.13.2</p>
+<p id="footer">npm-repo &mdash; npm@2.13.3</p>
 
index 1b9885c..fdbcdfa 100644 (file)
@@ -52,5 +52,5 @@ behavior will be accompanied by an increase in major version number</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-restart &mdash; npm@2.13.2</p>
+<p id="footer">npm-restart &mdash; npm@2.13.3</p>
 
index c597620..7c6223f 100644 (file)
@@ -29,5 +29,5 @@
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-root &mdash; npm@2.13.2</p>
+<p id="footer">npm-root &mdash; npm@2.13.3</p>
 
index e09cdba..fdd705d 100644 (file)
@@ -41,5 +41,5 @@ assumed to be the command to run. All other elements are ignored.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-run-script &mdash; npm@2.13.2</p>
+<p id="footer">npm-run-script &mdash; npm@2.13.3</p>
 
index d264ac9..55b50b9 100644 (file)
@@ -53,5 +53,5 @@ like).</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-search &mdash; npm@2.13.2</p>
+<p id="footer">npm-search &mdash; npm@2.13.3</p>
 
index c83be9b..eb11548 100644 (file)
@@ -33,5 +33,5 @@ been saved.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-shrinkwrap &mdash; npm@2.13.2</p>
+<p id="footer">npm-shrinkwrap &mdash; npm@2.13.3</p>
 
index 8b42d79..e885248 100644 (file)
@@ -28,5 +28,5 @@
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-start &mdash; npm@2.13.2</p>
+<p id="footer">npm-start &mdash; npm@2.13.3</p>
 
index f29f898..222c23b 100644 (file)
@@ -28,5 +28,5 @@ in the <code>packages</code> parameter.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-stop &mdash; npm@2.13.2</p>
+<p id="footer">npm-stop &mdash; npm@2.13.3</p>
 
index e71dca3..6d2e657 100644 (file)
@@ -36,5 +36,5 @@ used. For more information about how to set this config, check
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-tag &mdash; npm@2.13.2</p>
+<p id="footer">npm-tag &mdash; npm@2.13.3</p>
 
index 0c9cdf3..a41cf64 100644 (file)
@@ -30,5 +30,5 @@ in the <code>packages</code> parameter.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-test &mdash; npm@2.13.2</p>
+<p id="footer">npm-test &mdash; npm@2.13.3</p>
 
index 00b1810..193ba12 100644 (file)
@@ -30,5 +30,5 @@ uninstalled or when an error has been encountered.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-uninstall &mdash; npm@2.13.2</p>
+<p id="footer">npm-uninstall &mdash; npm@2.13.3</p>
 
index de5ed3a..5ee64a9 100644 (file)
@@ -33,5 +33,5 @@ the root package entry is removed from the registry entirely.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-unpublish &mdash; npm@2.13.2</p>
+<p id="footer">npm-unpublish &mdash; npm@2.13.3</p>
 
index 29114e0..6e964f0 100644 (file)
@@ -33,5 +33,5 @@ parameter will be called when done or when an error occurs.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-update &mdash; npm@2.13.2</p>
+<p id="footer">npm-update &mdash; npm@2.13.3</p>
 
index 9edb49f..12e4c94 100644 (file)
@@ -32,5 +32,5 @@ not have exactly one element. The only element should be a version number.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-version &mdash; npm@2.13.2</p>
+<p id="footer">npm-version &mdash; npm@2.13.3</p>
 
index 6f548f5..4c515ff 100644 (file)
@@ -81,5 +81,5 @@ the field name.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-view &mdash; npm@2.13.2</p>
+<p id="footer">npm-view &mdash; npm@2.13.3</p>
 
index 7810195..5d347fb 100644 (file)
@@ -29,5 +29,5 @@
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-whoami &mdash; npm@2.13.2</p>
+<p id="footer">npm-whoami &mdash; npm@2.13.3</p>
 
index 073af66..1d17da1 100644 (file)
@@ -23,7 +23,7 @@ npm.load([configObject, ]function (er, npm) {
   npm.commands.install([&quot;package&quot;], cb)
 })
 </code></pre><h2 id="version">VERSION</h2>
-<p>2.13.2</p>
+<p>2.13.3</p>
 <h2 id="description">DESCRIPTION</h2>
 <p>This is the API documentation for npm.
 To find documentation of the command line
@@ -109,5 +109,5 @@ method names.  Use the <code>npm.deref</code> method to find the real name.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm &mdash; npm@2.13.2</p>
+<p id="footer">npm &mdash; npm@2.13.3</p>
 
index 681926f..7588c31 100644 (file)
@@ -75,5 +75,5 @@ with an HTTP 402 status code (logically enough), unless you use
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-access &mdash; npm@2.13.2</p>
+<p id="footer">npm-access &mdash; npm@2.13.3</p>
 
index 8d82b02..1fd0b1c 100644 (file)
@@ -68,5 +68,5 @@ precedence over any global configuration.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-adduser &mdash; npm@2.13.2</p>
+<p id="footer">npm-adduser &mdash; npm@2.13.3</p>
 
index 3d26c5f..345188c 100644 (file)
@@ -35,5 +35,5 @@
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-bin &mdash; npm@2.13.2</p>
+<p id="footer">npm-bin &mdash; npm@2.13.3</p>
 
index 470a8ff..db8b253 100644 (file)
@@ -54,5 +54,5 @@ a <code>package.json</code> in the current folder and use the <code>name</code>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-bugs &mdash; npm@2.13.2</p>
+<p id="footer">npm-bugs &mdash; npm@2.13.3</p>
 
index 6c68ba8..03169c7 100644 (file)
@@ -40,5 +40,5 @@ directly, run:</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-build &mdash; npm@2.13.2</p>
+<p id="footer">npm-build &mdash; npm@2.13.3</p>
 
index 05fa00a..4cbf952 100644 (file)
@@ -31,5 +31,5 @@ install packages into the local space.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-bundle &mdash; npm@2.13.2</p>
+<p id="footer">npm-bundle &mdash; npm@2.13.3</p>
 
index 2272e7b..1bfe9a7 100644 (file)
@@ -81,5 +81,5 @@ they do not make an HTTP request to the registry.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-cache &mdash; npm@2.13.2</p>
+<p id="footer">npm-cache &mdash; npm@2.13.3</p>
 
index 5505b51..458e2f8 100644 (file)
@@ -42,5 +42,5 @@ completions based on the arguments.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-completion &mdash; npm@2.13.2</p>
+<p id="footer">npm-completion &mdash; npm@2.13.3</p>
 
index 46fc5e4..1a887e2 100644 (file)
@@ -66,5 +66,5 @@ global config.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-config &mdash; npm@2.13.2</p>
+<p id="footer">npm-config &mdash; npm@2.13.3</p>
 
index ad1fe17..7d1653e 100644 (file)
@@ -63,5 +63,5 @@ versions.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-dedupe &mdash; npm@2.13.2</p>
+<p id="footer">npm-dedupe &mdash; npm@2.13.3</p>
 
index 5f27661..cd2bc56 100644 (file)
@@ -38,5 +38,5 @@ something like this:</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-deprecate &mdash; npm@2.13.2</p>
+<p id="footer">npm-deprecate &mdash; npm@2.13.3</p>
 
index 0c6c83b..c910e08 100644 (file)
@@ -77,5 +77,5 @@ begin with a number or the letter <code>v</code>.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-dist-tag &mdash; npm@2.13.2</p>
+<p id="footer">npm-dist-tag &mdash; npm@2.13.3</p>
 
index 48d598f..95fdcd7 100644 (file)
@@ -56,5 +56,5 @@ the current folder and use the <code>name</code> property.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-docs &mdash; npm@2.13.2</p>
+<p id="footer">npm-docs &mdash; npm@2.13.3</p>
 
index db0a74b..6062218 100644 (file)
@@ -49,5 +49,5 @@ or <code>&quot;notepad&quot;</code> on Windows.</li>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-edit &mdash; npm@2.13.2</p>
+<p id="footer">npm-edit &mdash; npm@2.13.3</p>
 
index c9ece35..08848c0 100644 (file)
@@ -49,5 +49,5 @@ Windows</li>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-explore &mdash; npm@2.13.2</p>
+<p id="footer">npm-explore &mdash; npm@2.13.3</p>
 
index 087769f..b50aa66 100644 (file)
@@ -46,5 +46,5 @@ where the terms were found in the documentation.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-help-search &mdash; npm@2.13.2</p>
+<p id="footer">npm-help-search &mdash; npm@2.13.3</p>
 
index 2335357..a8598ca 100644 (file)
@@ -52,5 +52,5 @@ matches are equivalent to specifying a topic name.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-help &mdash; npm@2.13.2</p>
+<p id="footer">npm-help &mdash; npm@2.13.3</p>
 
index dc31b29..6387d82 100644 (file)
@@ -48,5 +48,5 @@ defaults and not prompt you for any options.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-init &mdash; npm@2.13.2</p>
+<p id="footer">npm-init &mdash; npm@2.13.3</p>
 
index 7145167..cb01884 100644 (file)
@@ -277,5 +277,5 @@ affects a real use-case, it will be investigated.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-install &mdash; npm@2.13.2</p>
+<p id="footer">npm-install &mdash; npm@2.13.3</p>
 
index 9722436..ca622a5 100644 (file)
@@ -72,5 +72,5 @@ include that scope, e.g.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-link &mdash; npm@2.13.2</p>
+<p id="footer">npm-link &mdash; npm@2.13.3</p>
 
index b92bb47..d538a93 100644 (file)
@@ -55,5 +55,5 @@ that registry at the same time.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-logout &mdash; npm@2.13.2</p>
+<p id="footer">npm-logout &mdash; npm@2.13.3</p>
 
index 1dec381..399d6a9 100644 (file)
@@ -22,7 +22,7 @@ installed, as well as their dependencies, in a tree-structure.</p>
 limit the results to only the paths to the packages named.  Note that
 nested packages will <em>also</em> show the paths to the specified packages.
 For example, running <code>npm ls promzard</code> in npm&#39;s source tree will show:</p>
-<pre><code>npm@2.13.2 /path/to/npm
+<pre><code>npm@2.13.3 /path/to/npm
 └─┬ init-package-json@0.0.4
   └── promzard@0.1.5
 </code></pre><p>It will print out extraneous, missing, and invalid packages.</p>
@@ -97,5 +97,5 @@ project.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-ls &mdash; npm@2.13.2</p>
+<p id="footer">npm-ls &mdash; npm@2.13.3</p>
 
index 25b5ef8..cc4c239 100644 (file)
@@ -67,5 +67,5 @@ project.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-outdated &mdash; npm@2.13.2</p>
+<p id="footer">npm-outdated &mdash; npm@2.13.3</p>
 
index bcb0dfd..ab83369 100644 (file)
@@ -49,5 +49,5 @@ that is not implemented at this time.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-owner &mdash; npm@2.13.2</p>
+<p id="footer">npm-owner &mdash; npm@2.13.3</p>
 
index 8f51eac..2df3394 100644 (file)
@@ -41,5 +41,5 @@ overwritten the second time.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-pack &mdash; npm@2.13.2</p>
+<p id="footer">npm-pack &mdash; npm@2.13.3</p>
 
index 86c388a..c4865c0 100644 (file)
@@ -32,4 +32,4 @@
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-ping &mdash; npm@2.13.2</p>
+<p id="footer">npm-ping &mdash; npm@2.13.3</p>
index de5fc89..c999e7d 100644 (file)
@@ -38,5 +38,5 @@ to contain a package.json file unless <code>-g</code> is also specified.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-prefix &mdash; npm@2.13.2</p>
+<p id="footer">npm-prefix &mdash; npm@2.13.3</p>
 
index 5ec7b90..9a130e5 100644 (file)
@@ -41,5 +41,5 @@ negate <code>NODE_ENV</code> being set to <code>production</code>.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-prune &mdash; npm@2.13.2</p>
+<p id="footer">npm-prune &mdash; npm@2.13.3</p>
 
index c1e44c9..61d10cc 100644 (file)
@@ -66,5 +66,5 @@ it is removed with <a href="../cli/npm-unpublish.html"><a href="../cli/npm-unpub
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-publish &mdash; npm@2.13.2</p>
+<p id="footer">npm-publish &mdash; npm@2.13.3</p>
 
index 98ae782..af56a92 100644 (file)
@@ -38,5 +38,5 @@ the new binary.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-rebuild &mdash; npm@2.13.2</p>
+<p id="footer">npm-rebuild &mdash; npm@2.13.3</p>
 
index 12f745c..39dc1a0 100644 (file)
@@ -42,5 +42,5 @@ a <code>package.json</code> in the current folder and use the <code>name</code>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-repo &mdash; npm@2.13.2</p>
+<p id="footer">npm-repo &mdash; npm@2.13.3</p>
 
index 7eb0097..0ff0f93 100644 (file)
@@ -53,5 +53,5 @@ behavior will be accompanied by an increase in major version number</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-restart &mdash; npm@2.13.2</p>
+<p id="footer">npm-restart &mdash; npm@2.13.3</p>
 
index 15793f6..23bd040 100644 (file)
@@ -39,5 +39,5 @@ on its behalf.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-rm &mdash; npm@2.13.2</p>
+<p id="footer">npm-rm &mdash; npm@2.13.3</p>
 
index 467cd95..34fb1cd 100644 (file)
@@ -35,5 +35,5 @@
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-root &mdash; npm@2.13.2</p>
+<p id="footer">npm-root &mdash; npm@2.13.3</p>
 
index ec2abf0..3503be3 100644 (file)
@@ -57,5 +57,5 @@ you should write:</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-run-script &mdash; npm@2.13.2</p>
+<p id="footer">npm-run-script &mdash; npm@2.13.3</p>
 
index e380f90..96ce6d9 100644 (file)
@@ -49,5 +49,5 @@ fall on multiple lines.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-search &mdash; npm@2.13.2</p>
+<p id="footer">npm-search &mdash; npm@2.13.3</p>
 
index 87cea63..3a80e8f 100644 (file)
@@ -164,5 +164,5 @@ contents rather than versions.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-shrinkwrap &mdash; npm@2.13.2</p>
+<p id="footer">npm-shrinkwrap &mdash; npm@2.13.3</p>
 
index a00e75c..481782e 100644 (file)
@@ -36,5 +36,5 @@ a vaguely positive way to show that you care.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-star &mdash; npm@2.13.2</p>
+<p id="footer">npm-star &mdash; npm@2.13.3</p>
 
index 2f20f1d..51b8458 100644 (file)
@@ -37,5 +37,5 @@ you will most certainly enjoy this command.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-stars &mdash; npm@2.13.2</p>
+<p id="footer">npm-stars &mdash; npm@2.13.3</p>
 
index f94b171..bd6c881 100644 (file)
@@ -34,5 +34,5 @@
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-start &mdash; npm@2.13.2</p>
+<p id="footer">npm-start &mdash; npm@2.13.3</p>
 
index 1e1a617..c2034c6 100644 (file)
@@ -34,5 +34,5 @@
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-stop &mdash; npm@2.13.2</p>
+<p id="footer">npm-stop &mdash; npm@2.13.3</p>
 
index 02c7c07..a758ac1 100644 (file)
@@ -62,5 +62,5 @@ that do not begin with a number or the letter <code>v</code>.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-tag &mdash; npm@2.13.2</p>
+<p id="footer">npm-tag &mdash; npm@2.13.3</p>
 
index 635e92c..380491a 100644 (file)
@@ -37,5 +37,5 @@ true.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-test &mdash; npm@2.13.2</p>
+<p id="footer">npm-test &mdash; npm@2.13.3</p>
 
index 52bb318..6947e65 100644 (file)
@@ -57,5 +57,5 @@ npm uninstall dtrace-provider --save-optional
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-uninstall &mdash; npm@2.13.2</p>
+<p id="footer">npm-uninstall &mdash; npm@2.13.3</p>
 
index c72b443..ecf13ea 100644 (file)
@@ -47,5 +47,5 @@ package again, a new version number must be used.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-unpublish &mdash; npm@2.13.2</p>
+<p id="footer">npm-unpublish &mdash; npm@2.13.3</p>
 
index a062871..3285f6e 100644 (file)
@@ -119,5 +119,5 @@ be <em>downgraded</em>.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-update &mdash; npm@2.13.2</p>
+<p id="footer">npm-update &mdash; npm@2.13.3</p>
 
index e1aa092..fbbe2b9 100644 (file)
@@ -95,5 +95,5 @@ and tag up to the server, and deletes the <code>build/temp</code> directory.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-version &mdash; npm@2.13.2</p>
+<p id="footer">npm-version &mdash; npm@2.13.3</p>
 
index 367e4a1..8ad404d 100644 (file)
@@ -82,5 +82,5 @@ the field name.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-view &mdash; npm@2.13.2</p>
+<p id="footer">npm-view &mdash; npm@2.13.3</p>
 
index 5642b0d..bfb6e8c 100644 (file)
@@ -33,5 +33,5 @@
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-whoami &mdash; npm@2.13.2</p>
+<p id="footer">npm-whoami &mdash; npm@2.13.3</p>
 
index a531abf..5dd95b8 100644 (file)
@@ -13,7 +13,7 @@
 <h2 id="synopsis">SYNOPSIS</h2>
 <pre><code>npm &lt;command&gt; [args]
 </code></pre><h2 id="version">VERSION</h2>
-<p>2.13.2</p>
+<p>2.13.3</p>
 <h2 id="description">DESCRIPTION</h2>
 <p>npm is the package manager for the Node JavaScript platform.  It puts
 modules in place so that node can find them, and manages dependency
@@ -110,7 +110,7 @@ easily by doing <code>npm view npm contributors</code>.</p>
 the issues list or ask on the mailing list.</p>
 <ul>
 <li><a href="http://github.com/npm/npm/issues">http://github.com/npm/npm/issues</a></li>
-<li><a href="&#x6d;&#97;&#x69;&#x6c;&#x74;&#111;&#x3a;&#110;&#112;&#x6d;&#x2d;&#64;&#103;&#111;&#x6f;&#103;&#108;&#101;&#x67;&#x72;&#111;&#x75;&#112;&#115;&#x2e;&#99;&#x6f;&#x6d;">&#110;&#112;&#x6d;&#x2d;&#64;&#103;&#111;&#x6f;&#103;&#108;&#101;&#x67;&#x72;&#111;&#x75;&#112;&#115;&#x2e;&#99;&#x6f;&#x6d;</a></li>
+<li><a href="&#109;&#x61;&#x69;&#108;&#116;&#x6f;&#58;&#110;&#x70;&#109;&#45;&#x40;&#103;&#x6f;&#x6f;&#x67;&#108;&#101;&#x67;&#114;&#111;&#x75;&#112;&#115;&#x2e;&#99;&#x6f;&#109;">&#110;&#x70;&#109;&#45;&#x40;&#103;&#x6f;&#x6f;&#x67;&#108;&#101;&#x67;&#114;&#111;&#x75;&#112;&#115;&#x2e;&#99;&#x6f;&#109;</a></li>
 </ul>
 <h2 id="bugs">BUGS</h2>
 <p>When you find issues, please report them:</p>
@@ -118,7 +118,7 @@ the issues list or ask on the mailing list.</p>
 <li>web:
 <a href="http://github.com/npm/npm/issues">http://github.com/npm/npm/issues</a></li>
 <li>email:
-<a href="&#x6d;&#x61;&#x69;&#108;&#116;&#x6f;&#58;&#110;&#112;&#109;&#x2d;&#64;&#x67;&#111;&#111;&#103;&#x6c;&#x65;&#103;&#x72;&#x6f;&#117;&#x70;&#115;&#x2e;&#x63;&#111;&#109;">&#110;&#112;&#109;&#x2d;&#64;&#x67;&#111;&#111;&#103;&#x6c;&#x65;&#103;&#x72;&#x6f;&#117;&#x70;&#115;&#x2e;&#x63;&#111;&#109;</a></li>
+<a href="&#109;&#97;&#105;&#x6c;&#116;&#x6f;&#58;&#x6e;&#112;&#109;&#45;&#x40;&#103;&#x6f;&#111;&#103;&#x6c;&#101;&#103;&#114;&#x6f;&#x75;&#112;&#x73;&#46;&#x63;&#x6f;&#x6d;">&#x6e;&#112;&#109;&#45;&#x40;&#103;&#x6f;&#111;&#103;&#x6c;&#101;&#103;&#114;&#x6f;&#x75;&#112;&#x73;&#46;&#x63;&#x6f;&#x6d;</a></li>
 </ul>
 <p>Be sure to include <em>all</em> of the output from the npm command that didn&#39;t work
 as expected.  The <code>npm-debug.log</code> file is also helpful to provide.</p>
@@ -128,7 +128,7 @@ will no doubt tell you to put the output in a gist or email.</p>
 <p><a href="http://blog.izs.me/">Isaac Z. Schlueter</a> ::
 <a href="https://github.com/isaacs/">isaacs</a> ::
 <a href="http://twitter.com/izs">@izs</a> ::
-<a href="&#x6d;&#97;&#105;&#x6c;&#116;&#x6f;&#x3a;&#x69;&#x40;&#x69;&#122;&#115;&#x2e;&#x6d;&#x65;">&#x69;&#x40;&#x69;&#122;&#115;&#x2e;&#x6d;&#x65;</a></p>
+<a href="&#109;&#97;&#x69;&#108;&#116;&#111;&#x3a;&#105;&#x40;&#x69;&#x7a;&#x73;&#46;&#x6d;&#101;">&#105;&#x40;&#x69;&#x7a;&#x73;&#46;&#x6d;&#101;</a></p>
 <h2 id="see-also">SEE ALSO</h2>
 <ul>
 <li><a href="../cli/npm-help.html"><a href="../cli/npm-help.html">npm-help(1)</a></a></li>
@@ -154,5 +154,5 @@ will no doubt tell you to put the output in a gist or email.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm &mdash; npm@2.13.2</p>
+<p id="footer">npm &mdash; npm@2.13.3</p>
 
index f29eedc..29b9677 100644 (file)
@@ -184,5 +184,5 @@ cannot be found elsewhere.  See <code><a href="../files/package.json.html"><a hr
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-folders &mdash; npm@2.13.2</p>
+<p id="footer">npm-folders &mdash; npm@2.13.3</p>
 
index 8876b98..7caf28c 100644 (file)
@@ -184,5 +184,5 @@ cannot be found elsewhere.  See <code><a href="../files/package.json.html"><a hr
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-global &mdash; npm@2.13.2</p>
+<p id="footer">npm-global &mdash; npm@2.13.3</p>
 
index 1b7cd7a..2fcc8a7 100644 (file)
@@ -140,6 +140,26 @@ inside that folder. (Unless they would be ignored by another rule.)</p>
 which will keep files from being included, even if they would be picked
 up by the files array.  The &quot;.npmignore&quot; file works just like a
 &quot;.gitignore&quot;.</p>
+<p>Certain files are always included, regardless of settings:</p>
+<ul>
+<li><code>package.json</code></li>
+<li><code><a href="../../doc/README.html"><a href="../../doc/README.html">README</a></a></code> (and its variants)</li>
+<li><code>CHANGELOG</code> (and its variants)</li>
+<li><code>LICENSE</code> / <code>LICENCE</code></li>
+</ul>
+<p>Conversely, some files are always ignored:</p>
+<ul>
+<li><code>.git</code></li>
+<li><code>CVS</code></li>
+<li><code>.svn</code></li>
+<li><code>.hg</code></li>
+<li><code>.lock-wscript</code></li>
+<li><code>.wafpickle-N</code></li>
+<li><code>*.swp</code></li>
+<li><code>.DS_Store</code></li>
+<li><code>._*</code></li>
+<li><code>npm-debug.log</code></li>
+</ul>
 <h2 id="main">main</h2>
 <p>The main field is a module ID that is the primary entry point to your program.
 That is, if your package is named <code>foo</code>, and a user installs it, and then does
@@ -494,12 +514,12 @@ specific registry (for example, an internal registry), then use the
 <code>publishConfig</code> dictionary described below to override the <code>registry</code> config
 param at publish-time.</p>
 <h2 id="publishconfig">publishConfig</h2>
-<p>This is a set of config values that will be used at publish-time.  It&#39;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 &quot;latest&quot; or published to
-the global public registry by default.</p>
-<p>Any config values can be overridden, but of course only &quot;tag&quot; and
-&quot;registry&quot; probably matter for the purposes of publishing.</p>
+<p>This is a set of config values that will be used at publish-time. It&#39;s
+especially handy if you want to set the tag, registry or access, so that
+you can ensure that a given package is not tagged with &quot;latest&quot;, published
+to the global public registry or that a scoped module is private by default.</p>
+<p>Any config values can be overridden, but of course only &quot;tag&quot;, &quot;registry&quot; and
+&quot;access&quot; probably matter for the purposes of publishing.</p>
 <p>See <code><a href="../misc/npm-config.html"><a href="../misc/npm-config.html">npm-config(7)</a></a></code> to see the list of config options that can be
 overridden.</p>
 <h2 id="default-values">DEFAULT VALUES</h2>
@@ -545,5 +565,5 @@ ignored.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-json &mdash; npm@2.13.2</p>
+<p id="footer">npm-json &mdash; npm@2.13.3</p>
 
index 2d43774..42e23dc 100644 (file)
@@ -83,5 +83,5 @@ manner.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npmrc &mdash; npm@2.13.2</p>
+<p id="footer">npmrc &mdash; npm@2.13.3</p>
 
index 0e7328d..6b6d7b1 100644 (file)
@@ -140,6 +140,26 @@ inside that folder. (Unless they would be ignored by another rule.)</p>
 which will keep files from being included, even if they would be picked
 up by the files array.  The &quot;.npmignore&quot; file works just like a
 &quot;.gitignore&quot;.</p>
+<p>Certain files are always included, regardless of settings:</p>
+<ul>
+<li><code>package.json</code></li>
+<li><code><a href="../../doc/README.html"><a href="../../doc/README.html">README</a></a></code> (and its variants)</li>
+<li><code>CHANGELOG</code> (and its variants)</li>
+<li><code>LICENSE</code> / <code>LICENCE</code></li>
+</ul>
+<p>Conversely, some files are always ignored:</p>
+<ul>
+<li><code>.git</code></li>
+<li><code>CVS</code></li>
+<li><code>.svn</code></li>
+<li><code>.hg</code></li>
+<li><code>.lock-wscript</code></li>
+<li><code>.wafpickle-N</code></li>
+<li><code>*.swp</code></li>
+<li><code>.DS_Store</code></li>
+<li><code>._*</code></li>
+<li><code>npm-debug.log</code></li>
+</ul>
 <h2 id="main">main</h2>
 <p>The main field is a module ID that is the primary entry point to your program.
 That is, if your package is named <code>foo</code>, and a user installs it, and then does
@@ -494,12 +514,12 @@ specific registry (for example, an internal registry), then use the
 <code>publishConfig</code> dictionary described below to override the <code>registry</code> config
 param at publish-time.</p>
 <h2 id="publishconfig">publishConfig</h2>
-<p>This is a set of config values that will be used at publish-time.  It&#39;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 &quot;latest&quot; or published to
-the global public registry by default.</p>
-<p>Any config values can be overridden, but of course only &quot;tag&quot; and
-&quot;registry&quot; probably matter for the purposes of publishing.</p>
+<p>This is a set of config values that will be used at publish-time. It&#39;s
+especially handy if you want to set the tag, registry or access, so that
+you can ensure that a given package is not tagged with &quot;latest&quot;, published
+to the global public registry or that a scoped module is private by default.</p>
+<p>Any config values can be overridden, but of course only &quot;tag&quot;, &quot;registry&quot; and
+&quot;access&quot; probably matter for the purposes of publishing.</p>
 <p>See <code><a href="../misc/npm-config.html"><a href="../misc/npm-config.html">npm-config(7)</a></a></code> to see the list of config options that can be
 overridden.</p>
 <h2 id="default-values">DEFAULT VALUES</h2>
@@ -545,5 +565,5 @@ ignored.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">package.json &mdash; npm@2.13.2</p>
+<p id="footer">package.json &mdash; npm@2.13.3</p>
 
index e132b67..aec8a77 100644 (file)
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">index &mdash; npm@2.13.2</p>
+<p id="footer">index &mdash; npm@2.13.3</p>
 
index 1d523e1..e1fc4ba 100644 (file)
@@ -147,5 +147,5 @@ set to anything.&quot;</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-coding-style &mdash; npm@2.13.2</p>
+<p id="footer">npm-coding-style &mdash; npm@2.13.3</p>
 
index 165e4ce..abd1fce 100644 (file)
@@ -799,5 +799,5 @@ exit successfully.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-config &mdash; npm@2.13.2</p>
+<p id="footer">npm-config &mdash; npm@2.13.3</p>
 
index d57c848..9afdcd9 100644 (file)
@@ -189,5 +189,5 @@ from a fresh checkout.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-developers &mdash; npm@2.13.2</p>
+<p id="footer">npm-developers &mdash; npm@2.13.3</p>
 
index bd00bb5..1b343d9 100644 (file)
@@ -13,7 +13,7 @@
 <h2 id="synopsis">SYNOPSIS</h2>
 <ol>
 <li>Get the author email with <code>npm owner ls &lt;pkgname&gt;</code></li>
-<li>Email the author, CC <a href="&#x6d;&#x61;&#105;&#x6c;&#116;&#111;&#58;&#x73;&#117;&#112;&#112;&#111;&#114;&#116;&#64;&#110;&#112;&#x6d;&#x6a;&#x73;&#x2e;&#x63;&#111;&#x6d;">&#x73;&#117;&#112;&#112;&#111;&#114;&#116;&#64;&#110;&#112;&#x6d;&#x6a;&#x73;&#x2e;&#x63;&#111;&#x6d;</a></li>
+<li>Email the author, CC <a href="&#109;&#97;&#x69;&#x6c;&#x74;&#111;&#x3a;&#x73;&#117;&#x70;&#x70;&#x6f;&#x72;&#116;&#x40;&#x6e;&#112;&#x6d;&#x6a;&#x73;&#46;&#99;&#x6f;&#109;">&#x73;&#117;&#x70;&#x70;&#x6f;&#x72;&#116;&#x40;&#x6e;&#112;&#x6d;&#x6a;&#x73;&#46;&#99;&#x6f;&#109;</a></li>
 <li>After a few weeks, if there&#39;s no resolution, we&#39;ll sort it out.</li>
 </ol>
 <p>Don&#39;t squat on package names.  Publish code or move out of the way.</p>
@@ -51,12 +51,12 @@ Joe&#39;s appropriate course of action in each case is the same.</p>
 owner (Bob).</li>
 <li>Joe emails Bob, explaining the situation <strong>as respectfully as
 possible</strong>, and what he would like to do with the module name.  He
-adds the npm support staff <a href="&#x6d;&#x61;&#105;&#x6c;&#x74;&#111;&#58;&#x73;&#117;&#x70;&#112;&#111;&#x72;&#116;&#64;&#110;&#112;&#x6d;&#x6a;&#115;&#x2e;&#99;&#x6f;&#109;">&#x73;&#117;&#x70;&#112;&#111;&#x72;&#116;&#64;&#110;&#112;&#x6d;&#x6a;&#115;&#x2e;&#99;&#x6f;&#109;</a> to the CC list of
+adds the npm support staff <a href="&#109;&#97;&#105;&#x6c;&#x74;&#111;&#x3a;&#115;&#x75;&#x70;&#x70;&#111;&#114;&#x74;&#64;&#110;&#x70;&#x6d;&#106;&#115;&#x2e;&#x63;&#x6f;&#x6d;">&#115;&#x75;&#x70;&#x70;&#111;&#114;&#x74;&#64;&#110;&#x70;&#x6d;&#106;&#115;&#x2e;&#x63;&#x6f;&#x6d;</a> to the CC list of
 the email.  Mention in the email that Bob can run <code>npm owner add
 joe foo</code> to add Joe as an owner of the <code>foo</code> package.</li>
 <li>After a reasonable amount of time, if Bob has not responded, or if
 Bob and Joe can&#39;t come to any sort of resolution, email support
-<a href="&#x6d;&#x61;&#x69;&#108;&#x74;&#111;&#x3a;&#x73;&#117;&#x70;&#x70;&#x6f;&#114;&#116;&#64;&#x6e;&#112;&#109;&#x6a;&#x73;&#46;&#x63;&#111;&#109;">&#x73;&#117;&#x70;&#x70;&#x6f;&#114;&#116;&#64;&#x6e;&#112;&#109;&#x6a;&#x73;&#46;&#x63;&#111;&#109;</a> and we&#39;ll sort it out.  (&quot;Reasonable&quot; is
+<a href="&#109;&#x61;&#105;&#x6c;&#x74;&#111;&#x3a;&#x73;&#117;&#112;&#x70;&#x6f;&#x72;&#x74;&#x40;&#x6e;&#112;&#109;&#x6a;&#x73;&#x2e;&#99;&#x6f;&#109;">&#x73;&#117;&#112;&#x70;&#x6f;&#x72;&#x74;&#x40;&#x6e;&#112;&#109;&#x6a;&#x73;&#x2e;&#99;&#x6f;&#109;</a> and we&#39;ll sort it out.  (&quot;Reasonable&quot; is
 usually at least 4 weeks, but extra time is allowed around common
 holidays.)</li>
 </ol>
@@ -112,5 +112,5 @@ things into it.</li>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-disputes &mdash; npm@2.13.2</p>
+<p id="footer">npm-disputes &mdash; npm@2.13.3</p>
 
index 2df5f12..ca3d1e1 100644 (file)
@@ -237,7 +237,7 @@ that has a package.json in its root, or a git url.
 <p>To check if the registry is down, open up
 <a href="https://registry.npmjs.org/">https://registry.npmjs.org/</a> in a web browser.  This will also tell
 you if you are just unable to access the internet for some reason.</p>
-<p>If the registry IS down, let us know by emailing <a href="&#x6d;&#97;&#x69;&#108;&#116;&#x6f;&#58;&#115;&#117;&#112;&#112;&#x6f;&#114;&#116;&#64;&#x6e;&#x70;&#109;&#x6a;&#x73;&#x2e;&#99;&#x6f;&#x6d;">&#115;&#117;&#112;&#112;&#x6f;&#114;&#116;&#64;&#x6e;&#x70;&#109;&#x6a;&#x73;&#x2e;&#99;&#x6f;&#x6d;</a>
+<p>If the registry IS down, let us know by emailing <a href="&#x6d;&#x61;&#105;&#x6c;&#x74;&#111;&#x3a;&#115;&#x75;&#112;&#112;&#x6f;&#114;&#116;&#x40;&#110;&#x70;&#109;&#x6a;&#x73;&#46;&#99;&#x6f;&#x6d;">&#115;&#x75;&#112;&#112;&#x6f;&#114;&#116;&#x40;&#110;&#x70;&#109;&#x6a;&#x73;&#46;&#99;&#x6f;&#x6d;</a>
 or posting an issue at <a href="https://github.com/npm/npm/issues">https://github.com/npm/npm/issues</a>.  If it&#39;s
 down for the world (and not just on your local network) then we&#39;re
 probably already being pinged about it.</p>
@@ -308,5 +308,5 @@ good folks at <a href="http://www.npmjs.com">npm, Inc.</a></p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-faq &mdash; npm@2.13.2</p>
+<p id="footer">npm-faq &mdash; npm@2.13.3</p>
 
index 24f590b..6695bab 100644 (file)
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-index &mdash; npm@2.13.2</p>
+<p id="footer">npm-index &mdash; npm@2.13.3</p>
 
index 67fde99..1d66dd3 100644 (file)
@@ -70,5 +70,5 @@ effectively implement the entire CouchDB API anyway.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-registry &mdash; npm@2.13.2</p>
+<p id="footer">npm-registry &mdash; npm@2.13.3</p>
 
index 4366b64..3d3cbb6 100644 (file)
@@ -91,5 +91,5 @@ that registry instead.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-scope &mdash; npm@2.13.2</p>
+<p id="footer">npm-scope &mdash; npm@2.13.3</p>
 
index 6423d6e..b879065 100644 (file)
@@ -207,5 +207,5 @@ scripts is for compilation which must be done on the target architecture.</li>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">npm-scripts &mdash; npm@2.13.2</p>
+<p id="footer">npm-scripts &mdash; npm@2.13.3</p>
 
index 77220ca..64aaefc 100644 (file)
@@ -57,5 +57,5 @@ modules.  To track those down, you can do the following:</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">removing-npm &mdash; npm@2.13.2</p>
+<p id="footer">removing-npm &mdash; npm@2.13.3</p>
 
index c4f2442..3dd74b3 100644 (file)
@@ -282,5 +282,5 @@ range, use the <code>satisfies(version, range)</code> function.</p>
 <tr><td style="width:60px;height:10px;background:rgb(237,127,127)" colspan=6>&nbsp;</td><td colspan=10 style="width:10px;height:10px;background:rgb(237,127,127)">&nbsp;</td></tr>
 <tr><td colspan=5 style="width:50px;height:10px;background:#fff">&nbsp;</td><td style="width:40px;height:10px;background:rgb(237,127,127)" colspan=4>&nbsp;</td><td style="width:90px;height:10px;background:#fff" colspan=9>&nbsp;</td></tr>
 </table>
-<p id="footer">semver &mdash; npm@2.13.2</p>
+<p id="footer">semver &mdash; npm@2.13.3</p>
 
index cf6e65a..265dc19 100644 (file)
@@ -129,7 +129,7 @@ specific purpose, or lack of malice in any given npm package.</p>
 <p>If you have a complaint about a package in the public npm registry,
 and cannot <a href="https://docs.npmjs.com/misc/disputes">resolve it with the package
 owner</a>, please email
-<a href="&#109;&#97;&#105;&#x6c;&#x74;&#x6f;&#x3a;&#x73;&#x75;&#112;&#x70;&#x6f;&#114;&#116;&#x40;&#x6e;&#112;&#x6d;&#x6a;&#115;&#46;&#99;&#x6f;&#x6d;">&#x73;&#x75;&#112;&#x70;&#x6f;&#114;&#116;&#x40;&#x6e;&#112;&#x6d;&#x6a;&#115;&#46;&#99;&#x6f;&#x6d;</a> and explain the situation.</p>
+<a href="&#109;&#97;&#x69;&#108;&#116;&#x6f;&#58;&#x73;&#x75;&#x70;&#x70;&#111;&#x72;&#x74;&#64;&#x6e;&#112;&#109;&#106;&#x73;&#x2e;&#99;&#111;&#x6d;">&#x73;&#x75;&#x70;&#x70;&#111;&#x72;&#x74;&#64;&#x6e;&#112;&#109;&#106;&#x73;&#x2e;&#99;&#111;&#x6d;</a> and explain the situation.</p>
 <p>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.</p>
index 33a5d2a..5c57fd4 100644 (file)
@@ -12,7 +12,7 @@ npm.load([configObject, ]function (er, npm) {
   npm.commands.install([&quot;package&quot;], cb)
 })
 </code></pre><h2 id="version">VERSION</h2>
-<p>2.13.2</p>
+<p>2.13.3</p>
 <h2 id="description">DESCRIPTION</h2>
 <p>This is the API documentation for npm.
 To find documentation of the command line
index a762571..9674a41 100644 (file)
@@ -11,7 +11,7 @@ installed, as well as their dependencies, in a tree-structure.</p>
 limit the results to only the paths to the packages named.  Note that
 nested packages will <em>also</em> show the paths to the specified packages.
 For example, running <code>npm ls promzard</code> in npm&#39;s source tree will show:</p>
-<pre><code>npm@2.13.2 /path/to/npm
+<pre><code>npm@2.13.3 /path/to/npm
 └─┬ init-package-json@0.0.4
   └── promzard@0.1.5
 </code></pre><p>It will print out extraneous, missing, and invalid packages.</p>
index 5e02c43..683606b 100644 (file)
@@ -2,7 +2,7 @@
 <h2 id="synopsis">SYNOPSIS</h2>
 <pre><code>npm &lt;command&gt; [args]
 </code></pre><h2 id="version">VERSION</h2>
-<p>2.13.2</p>
+<p>2.13.3</p>
 <h2 id="description">DESCRIPTION</h2>
 <p>npm is the package manager for the Node JavaScript platform.  It puts
 modules in place so that node can find them, and manages dependency
@@ -99,7 +99,7 @@ easily by doing <code>npm view npm contributors</code>.</p>
 the issues list or ask on the mailing list.</p>
 <ul>
 <li><a href="http://github.com/npm/npm/issues">http://github.com/npm/npm/issues</a></li>
-<li><a href="&#x6d;&#97;&#x69;&#x6c;&#x74;&#111;&#x3a;&#110;&#112;&#x6d;&#x2d;&#64;&#103;&#111;&#x6f;&#103;&#108;&#101;&#x67;&#x72;&#111;&#x75;&#112;&#115;&#x2e;&#99;&#x6f;&#x6d;">&#110;&#112;&#x6d;&#x2d;&#64;&#103;&#111;&#x6f;&#103;&#108;&#101;&#x67;&#x72;&#111;&#x75;&#112;&#115;&#x2e;&#99;&#x6f;&#x6d;</a></li>
+<li><a href="&#109;&#x61;&#x69;&#108;&#116;&#x6f;&#58;&#110;&#x70;&#109;&#45;&#x40;&#103;&#x6f;&#x6f;&#x67;&#108;&#101;&#x67;&#114;&#111;&#x75;&#112;&#115;&#x2e;&#99;&#x6f;&#109;">&#110;&#x70;&#109;&#45;&#x40;&#103;&#x6f;&#x6f;&#x67;&#108;&#101;&#x67;&#114;&#111;&#x75;&#112;&#115;&#x2e;&#99;&#x6f;&#109;</a></li>
 </ul>
 <h2 id="bugs">BUGS</h2>
 <p>When you find issues, please report them:</p>
@@ -107,7 +107,7 @@ the issues list or ask on the mailing list.</p>
 <li>web:
 <a href="http://github.com/npm/npm/issues">http://github.com/npm/npm/issues</a></li>
 <li>email:
-<a href="&#x6d;&#x61;&#x69;&#108;&#116;&#x6f;&#58;&#110;&#112;&#109;&#x2d;&#64;&#x67;&#111;&#111;&#103;&#x6c;&#x65;&#103;&#x72;&#x6f;&#117;&#x70;&#115;&#x2e;&#x63;&#111;&#109;">&#110;&#112;&#109;&#x2d;&#64;&#x67;&#111;&#111;&#103;&#x6c;&#x65;&#103;&#x72;&#x6f;&#117;&#x70;&#115;&#x2e;&#x63;&#111;&#109;</a></li>
+<a href="&#109;&#97;&#105;&#x6c;&#116;&#x6f;&#58;&#x6e;&#112;&#109;&#45;&#x40;&#103;&#x6f;&#111;&#103;&#x6c;&#101;&#103;&#114;&#x6f;&#x75;&#112;&#x73;&#46;&#x63;&#x6f;&#x6d;">&#x6e;&#112;&#109;&#45;&#x40;&#103;&#x6f;&#111;&#103;&#x6c;&#101;&#103;&#114;&#x6f;&#x75;&#112;&#x73;&#46;&#x63;&#x6f;&#x6d;</a></li>
 </ul>
 <p>Be sure to include <em>all</em> of the output from the npm command that didn&#39;t work
 as expected.  The <code>npm-debug.log</code> file is also helpful to provide.</p>
@@ -117,7 +117,7 @@ will no doubt tell you to put the output in a gist or email.</p>
 <p><a href="http://blog.izs.me/">Isaac Z. Schlueter</a> ::
 <a href="https://github.com/isaacs/">isaacs</a> ::
 <a href="http://twitter.com/izs">@izs</a> ::
-<a href="&#x6d;&#97;&#105;&#x6c;&#116;&#x6f;&#x3a;&#x69;&#x40;&#x69;&#122;&#115;&#x2e;&#x6d;&#x65;">&#x69;&#x40;&#x69;&#122;&#115;&#x2e;&#x6d;&#x65;</a></p>
+<a href="&#109;&#97;&#x69;&#108;&#116;&#111;&#x3a;&#105;&#x40;&#x69;&#x7a;&#x73;&#46;&#x6d;&#101;">&#105;&#x40;&#x69;&#x7a;&#x73;&#46;&#x6d;&#101;</a></p>
 <h2 id="see-also">SEE ALSO</h2>
 <ul>
 <li><a href="../cli/npm-help.html">npm-help(1)</a></li>
index a9877dc..b2e54ba 100644 (file)
@@ -129,6 +129,26 @@ inside that folder. (Unless they would be ignored by another rule.)</p>
 which will keep files from being included, even if they would be picked
 up by the files array.  The &quot;.npmignore&quot; file works just like a
 &quot;.gitignore&quot;.</p>
+<p>Certain files are always included, regardless of settings:</p>
+<ul>
+<li><code>package.json</code></li>
+<li><code><a href="../../doc/README.html">README</a></code> (and its variants)</li>
+<li><code>CHANGELOG</code> (and its variants)</li>
+<li><code>LICENSE</code> / <code>LICENCE</code></li>
+</ul>
+<p>Conversely, some files are always ignored:</p>
+<ul>
+<li><code>.git</code></li>
+<li><code>CVS</code></li>
+<li><code>.svn</code></li>
+<li><code>.hg</code></li>
+<li><code>.lock-wscript</code></li>
+<li><code>.wafpickle-N</code></li>
+<li><code>*.swp</code></li>
+<li><code>.DS_Store</code></li>
+<li><code>._*</code></li>
+<li><code>npm-debug.log</code></li>
+</ul>
 <h2 id="main">main</h2>
 <p>The main field is a module ID that is the primary entry point to your program.
 That is, if your package is named <code>foo</code>, and a user installs it, and then does
@@ -483,12 +503,12 @@ specific registry (for example, an internal registry), then use the
 <code>publishConfig</code> dictionary described below to override the <code>registry</code> config
 param at publish-time.</p>
 <h2 id="publishconfig">publishConfig</h2>
-<p>This is a set of config values that will be used at publish-time.  It&#39;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 &quot;latest&quot; or published to
-the global public registry by default.</p>
-<p>Any config values can be overridden, but of course only &quot;tag&quot; and
-&quot;registry&quot; probably matter for the purposes of publishing.</p>
+<p>This is a set of config values that will be used at publish-time. It&#39;s
+especially handy if you want to set the tag, registry or access, so that
+you can ensure that a given package is not tagged with &quot;latest&quot;, published
+to the global public registry or that a scoped module is private by default.</p>
+<p>Any config values can be overridden, but of course only &quot;tag&quot;, &quot;registry&quot; and
+&quot;access&quot; probably matter for the purposes of publishing.</p>
 <p>See <code><a href="../misc/npm-config.html">npm-config(7)</a></code> to see the list of config options that can be
 overridden.</p>
 <h2 id="default-values">DEFAULT VALUES</h2>
index a9877dc..b2e54ba 100644 (file)
@@ -129,6 +129,26 @@ inside that folder. (Unless they would be ignored by another rule.)</p>
 which will keep files from being included, even if they would be picked
 up by the files array.  The &quot;.npmignore&quot; file works just like a
 &quot;.gitignore&quot;.</p>
+<p>Certain files are always included, regardless of settings:</p>
+<ul>
+<li><code>package.json</code></li>
+<li><code><a href="../../doc/README.html">README</a></code> (and its variants)</li>
+<li><code>CHANGELOG</code> (and its variants)</li>
+<li><code>LICENSE</code> / <code>LICENCE</code></li>
+</ul>
+<p>Conversely, some files are always ignored:</p>
+<ul>
+<li><code>.git</code></li>
+<li><code>CVS</code></li>
+<li><code>.svn</code></li>
+<li><code>.hg</code></li>
+<li><code>.lock-wscript</code></li>
+<li><code>.wafpickle-N</code></li>
+<li><code>*.swp</code></li>
+<li><code>.DS_Store</code></li>
+<li><code>._*</code></li>
+<li><code>npm-debug.log</code></li>
+</ul>
 <h2 id="main">main</h2>
 <p>The main field is a module ID that is the primary entry point to your program.
 That is, if your package is named <code>foo</code>, and a user installs it, and then does
@@ -483,12 +503,12 @@ specific registry (for example, an internal registry), then use the
 <code>publishConfig</code> dictionary described below to override the <code>registry</code> config
 param at publish-time.</p>
 <h2 id="publishconfig">publishConfig</h2>
-<p>This is a set of config values that will be used at publish-time.  It&#39;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 &quot;latest&quot; or published to
-the global public registry by default.</p>
-<p>Any config values can be overridden, but of course only &quot;tag&quot; and
-&quot;registry&quot; probably matter for the purposes of publishing.</p>
+<p>This is a set of config values that will be used at publish-time. It&#39;s
+especially handy if you want to set the tag, registry or access, so that
+you can ensure that a given package is not tagged with &quot;latest&quot;, published
+to the global public registry or that a scoped module is private by default.</p>
+<p>Any config values can be overridden, but of course only &quot;tag&quot;, &quot;registry&quot; and
+&quot;access&quot; probably matter for the purposes of publishing.</p>
 <p>See <code><a href="../misc/npm-config.html">npm-config(7)</a></code> to see the list of config options that can be
 overridden.</p>
 <h2 id="default-values">DEFAULT VALUES</h2>
index 04f8a7b..15f6506 100644 (file)
@@ -2,7 +2,7 @@
 <h2 id="synopsis">SYNOPSIS</h2>
 <ol>
 <li>Get the author email with <code>npm owner ls &lt;pkgname&gt;</code></li>
-<li>Email the author, CC <a href="&#x6d;&#x61;&#105;&#x6c;&#116;&#111;&#58;&#x73;&#117;&#112;&#112;&#111;&#114;&#116;&#64;&#110;&#112;&#x6d;&#x6a;&#x73;&#x2e;&#x63;&#111;&#x6d;">&#x73;&#117;&#112;&#112;&#111;&#114;&#116;&#64;&#110;&#112;&#x6d;&#x6a;&#x73;&#x2e;&#x63;&#111;&#x6d;</a></li>
+<li>Email the author, CC <a href="&#109;&#97;&#x69;&#x6c;&#x74;&#111;&#x3a;&#x73;&#117;&#x70;&#x70;&#x6f;&#x72;&#116;&#x40;&#x6e;&#112;&#x6d;&#x6a;&#x73;&#46;&#99;&#x6f;&#109;">&#x73;&#117;&#x70;&#x70;&#x6f;&#x72;&#116;&#x40;&#x6e;&#112;&#x6d;&#x6a;&#x73;&#46;&#99;&#x6f;&#109;</a></li>
 <li>After a few weeks, if there&#39;s no resolution, we&#39;ll sort it out.</li>
 </ol>
 <p>Don&#39;t squat on package names.  Publish code or move out of the way.</p>
@@ -40,12 +40,12 @@ Joe&#39;s appropriate course of action in each case is the same.</p>
 owner (Bob).</li>
 <li>Joe emails Bob, explaining the situation <strong>as respectfully as
 possible</strong>, and what he would like to do with the module name.  He
-adds the npm support staff <a href="&#x6d;&#x61;&#105;&#x6c;&#x74;&#111;&#58;&#x73;&#117;&#x70;&#112;&#111;&#x72;&#116;&#64;&#110;&#112;&#x6d;&#x6a;&#115;&#x2e;&#99;&#x6f;&#109;">&#x73;&#117;&#x70;&#112;&#111;&#x72;&#116;&#64;&#110;&#112;&#x6d;&#x6a;&#115;&#x2e;&#99;&#x6f;&#109;</a> to the CC list of
+adds the npm support staff <a href="&#109;&#97;&#105;&#x6c;&#x74;&#111;&#x3a;&#115;&#x75;&#x70;&#x70;&#111;&#114;&#x74;&#64;&#110;&#x70;&#x6d;&#106;&#115;&#x2e;&#x63;&#x6f;&#x6d;">&#115;&#x75;&#x70;&#x70;&#111;&#114;&#x74;&#64;&#110;&#x70;&#x6d;&#106;&#115;&#x2e;&#x63;&#x6f;&#x6d;</a> to the CC list of
 the email.  Mention in the email that Bob can run <code>npm owner add
 joe foo</code> to add Joe as an owner of the <code>foo</code> package.</li>
 <li>After a reasonable amount of time, if Bob has not responded, or if
 Bob and Joe can&#39;t come to any sort of resolution, email support
-<a href="&#x6d;&#x61;&#x69;&#108;&#x74;&#111;&#x3a;&#x73;&#117;&#x70;&#x70;&#x6f;&#114;&#116;&#64;&#x6e;&#112;&#109;&#x6a;&#x73;&#46;&#x63;&#111;&#109;">&#x73;&#117;&#x70;&#x70;&#x6f;&#114;&#116;&#64;&#x6e;&#112;&#109;&#x6a;&#x73;&#46;&#x63;&#111;&#109;</a> and we&#39;ll sort it out.  (&quot;Reasonable&quot; is
+<a href="&#109;&#x61;&#105;&#x6c;&#x74;&#111;&#x3a;&#x73;&#117;&#112;&#x70;&#x6f;&#x72;&#x74;&#x40;&#x6e;&#112;&#109;&#x6a;&#x73;&#x2e;&#99;&#x6f;&#109;">&#x73;&#117;&#112;&#x70;&#x6f;&#x72;&#x74;&#x40;&#x6e;&#112;&#109;&#x6a;&#x73;&#x2e;&#99;&#x6f;&#109;</a> and we&#39;ll sort it out.  (&quot;Reasonable&quot; is
 usually at least 4 weeks, but extra time is allowed around common
 holidays.)</li>
 </ol>
index d91930e..f9a13cf 100644 (file)
@@ -226,7 +226,7 @@ that has a package.json in its root, or a git url.
 <p>To check if the registry is down, open up
 <a href="https://registry.npmjs.org/">https://registry.npmjs.org/</a> in a web browser.  This will also tell
 you if you are just unable to access the internet for some reason.</p>
-<p>If the registry IS down, let us know by emailing <a href="&#x6d;&#97;&#x69;&#108;&#116;&#x6f;&#58;&#115;&#117;&#112;&#112;&#x6f;&#114;&#116;&#64;&#x6e;&#x70;&#109;&#x6a;&#x73;&#x2e;&#99;&#x6f;&#x6d;">&#115;&#117;&#112;&#112;&#x6f;&#114;&#116;&#64;&#x6e;&#x70;&#109;&#x6a;&#x73;&#x2e;&#99;&#x6f;&#x6d;</a>
+<p>If the registry IS down, let us know by emailing <a href="&#x6d;&#x61;&#105;&#x6c;&#x74;&#111;&#x3a;&#115;&#x75;&#112;&#112;&#x6f;&#114;&#116;&#x40;&#110;&#x70;&#109;&#x6a;&#x73;&#46;&#99;&#x6f;&#x6d;">&#115;&#x75;&#112;&#112;&#x6f;&#114;&#116;&#x40;&#110;&#x70;&#109;&#x6a;&#x73;&#46;&#99;&#x6f;&#x6d;</a>
 or posting an issue at <a href="https://github.com/npm/npm/issues">https://github.com/npm/npm/issues</a>.  If it&#39;s
 down for the world (and not just on your local network) then we&#39;re
 probably already being pinged about it.</p>
index a052542..b777537 100644 (file)
@@ -23,7 +23,7 @@ For example, running \fBnpm ls promzard\fP in npm's source tree will show:
 .P
 .RS 2
 .nf
-npm@2.13.2 /path/to/npm
+npm@2.13.3 /path/to/npm
 └─┬ init\-package\-json@0\.0\.4
   └── promzard@0\.1\.5
 .fi
index 5bf8c09..cb0814d 100644 (file)
@@ -10,7 +10,7 @@ npm <command> [args]
 .RE
 .SH VERSION
 .P
-2.13.2
+2.13.3
 .SH DESCRIPTION
 .P
 npm is the package manager for the Node JavaScript platform\.  It puts
index dd56636..ddb2025 100644 (file)
@@ -20,7 +20,7 @@ npm\.load([configObject, ]function (er, npm) {
 .RE
 .SH VERSION
 .P
-2.13.2
+2.13.3
 .SH DESCRIPTION
 .P
 This is the API documentation for npm\.
index d2c7419..3f1754e 100644 (file)
@@ -221,6 +221,44 @@ 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"\.
+.P
+Certain files are always included, regardless of settings:
+.RS 0
+.IP \(bu 2
+\fBpackage\.json\fP
+.IP \(bu 2
+\fBREADME\fP (and its variants)
+.IP \(bu 2
+\fBCHANGELOG\fP (and its variants)
+.IP \(bu 2
+\fBLICENSE\fP / \fBLICENCE\fP
+
+.RE
+.P
+Conversely, some files are always ignored:
+.RS 0
+.IP \(bu 2
+\fB\|\.git\fP
+.IP \(bu 2
+\fBCVS\fP
+.IP \(bu 2
+\fB\|\.svn\fP
+.IP \(bu 2
+\fB\|\.hg\fP
+.IP \(bu 2
+\fB\|\.lock\-wscript\fP
+.IP \(bu 2
+\fB\|\.wafpickle\-N\fP
+.IP \(bu 2
+\fB*\.swp\fP
+.IP \(bu 2
+\fB\|\.DS_Store\fP
+.IP \(bu 2
+\fB\|\._*\fP
+.IP \(bu 2
+\fBnpm\-debug\.log\fP
+
+.RE
 .SH main
 .P
 The main field is a module ID that is the primary entry point to your program\.
@@ -795,13 +833,13 @@ specific registry (for example, an internal registry), then use the
 param at publish\-time\.
 .SH publishConfig
 .P
-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\.
+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, registry or access, so that
+you can ensure that a given package is not tagged with "latest", published
+to the global public registry or that a scoped module is private by default\.
 .P
-Any config values can be overridden, but of course only "tag" and
-"registry" probably matter for the purposes of publishing\.
+Any config values can be overridden, but of course only "tag", "registry" and
+"access" probably matter for the purposes of publishing\.
 .P
 See npm help 7 \fBnpm\-config\fP to see the list of config options that can be
 overridden\.
index d2c7419..3f1754e 100644 (file)
@@ -221,6 +221,44 @@ 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"\.
+.P
+Certain files are always included, regardless of settings:
+.RS 0
+.IP \(bu 2
+\fBpackage\.json\fP
+.IP \(bu 2
+\fBREADME\fP (and its variants)
+.IP \(bu 2
+\fBCHANGELOG\fP (and its variants)
+.IP \(bu 2
+\fBLICENSE\fP / \fBLICENCE\fP
+
+.RE
+.P
+Conversely, some files are always ignored:
+.RS 0
+.IP \(bu 2
+\fB\|\.git\fP
+.IP \(bu 2
+\fBCVS\fP
+.IP \(bu 2
+\fB\|\.svn\fP
+.IP \(bu 2
+\fB\|\.hg\fP
+.IP \(bu 2
+\fB\|\.lock\-wscript\fP
+.IP \(bu 2
+\fB\|\.wafpickle\-N\fP
+.IP \(bu 2
+\fB*\.swp\fP
+.IP \(bu 2
+\fB\|\.DS_Store\fP
+.IP \(bu 2
+\fB\|\._*\fP
+.IP \(bu 2
+\fBnpm\-debug\.log\fP
+
+.RE
 .SH main
 .P
 The main field is a module ID that is the primary entry point to your program\.
@@ -795,13 +833,13 @@ specific registry (for example, an internal registry), then use the
 param at publish\-time\.
 .SH publishConfig
 .P
-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\.
+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, registry or access, so that
+you can ensure that a given package is not tagged with "latest", published
+to the global public registry or that a scoped module is private by default\.
 .P
-Any config values can be overridden, but of course only "tag" and
-"registry" probably matter for the purposes of publishing\.
+Any config values can be overridden, but of course only "tag", "registry" and
+"access" probably matter for the purposes of publishing\.
 .P
 See npm help 7 \fBnpm\-config\fP to see the list of config options that can be
 overridden\.
index 05a2df5..ad9fab8 100644 (file)
@@ -1,6 +1,6 @@
 {
   "name": "init-package-json",
-  "version": "1.7.0",
+  "version": "1.7.1",
   "main": "init-package-json.js",
   "scripts": {
     "test": "tap test/*.js"
@@ -22,7 +22,7 @@
     "promzard": "^0.3.0",
     "read": "~1.0.1",
     "read-package-json": "1 || 2",
-    "semver": "2.x || 3.x || 4",
+    "semver": "2.x || 3.x || 4 || 5",
     "validate-npm-package-license": "^2.0.0",
     "validate-npm-package-name": "^2.0.1"
   },
   ],
   "readme": "# init-package-json\n\nA node module to get your node module started.\n\n[![Build Status](https://secure.travis-ci.org/npm/init-package-json.svg)](http://travis-ci.org/npm/init-package-json)\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": "04acc558503c6a133a1704aeec276d817617fa12",
+  "gitHead": "443031e837c81bb10548212a7b3700b5dde94cfb",
   "bugs": {
     "url": "https://github.com/isaacs/init-package-json/issues"
   },
   "homepage": "https://github.com/isaacs/init-package-json#readme",
-  "_id": "init-package-json@1.7.0",
-  "_shasum": "dc573523777fa4f83eca808976735ce5d7cfac77",
-  "_from": "init-package-json@>=1.7.0 <1.8.0"
+  "_id": "init-package-json@1.7.1",
+  "_shasum": "32a8643779c91732d901a6fdc7505de7119fb7ad",
+  "_from": "init-package-json@>=1.7.1 <1.8.0"
 }
index 967b45c..7d05159 100644 (file)
@@ -1,4 +1,4 @@
-(function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){
+(function(f){if(typeof exports==="object"&&typeof module!=="undefined"){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}g.minimatch = f()}})(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){
 module.exports = minimatch
 minimatch.Minimatch = Minimatch
 
@@ -273,6 +273,7 @@ function parse (pattern, isSub) {
   var escaping = false
   // ? => one single character
   var patternListStack = []
+  var negativeLists = []
   var plType
   var stateChar
   var inClass = false
@@ -373,9 +374,13 @@ function parse (pattern, isSub) {
         }
 
         plType = stateChar
-        patternListStack.push({ type: plType, start: i - 1, reStart: re.length })
+        patternListStack.push({
+          type: plType,
+          start: i - 1,
+          reStart: re.length
+        })
         // negation is (?:(?!js)[^/]*)
-        re += stateChar === '!' ? '(?:(?!' : '(?:'
+        re += stateChar === '!' ? '(?:(?!(?:' : '(?:'
         this.debug('plType %j %j', stateChar, re)
         stateChar = false
       continue
@@ -389,12 +394,15 @@ function parse (pattern, isSub) {
         clearStateChar()
         hasMagic = true
         re += ')'
-        plType = patternListStack.pop().type
+        var pl = patternListStack.pop()
+        plType = pl.type
         // negation is (?:(?!js)[^/]*)
         // The others are (?:<pattern>)<type>
         switch (plType) {
           case '!':
-            re += '[^/]*?)'
+            negativeLists.push(pl)
+            re += ')[^/]*?)'
+            pl.reEnd = re.length
             break
           case '?':
           case '+':
@@ -508,7 +516,7 @@ function parse (pattern, isSub) {
   // and escape any | chars that were passed through as-is for the regexp.
   // Go through and escape them, taking care not to double-escape any
   // | chars that were already escaped.
-  for (var pl = patternListStack.pop(); pl; pl = patternListStack.pop()) {
+  for (pl = patternListStack.pop(); pl; pl = patternListStack.pop()) {
     var tail = re.slice(pl.reStart + 3)
     // maybe some even number of \, then maybe 1 \, followed by a |
     tail = tail.replace(/((?:\\{2})*)(\\?)\|/g, function (_, $1, $2) {
@@ -551,12 +559,49 @@ function parse (pattern, isSub) {
     case '(': addPatternStart = true
   }
 
+  // Hack to work around lack of negative lookbehind in JS
+  // A pattern like: *.!(x).!(y|z) needs to ensure that a name
+  // like 'a.xyz.yz' doesn't match.  So, the first negative
+  // lookahead, has to look ALL the way ahead, to the end of
+  // the pattern.
+  for (var n = negativeLists.length - 1; n > -1; n--) {
+    var nl = negativeLists[n]
+
+    var nlBefore = re.slice(0, nl.reStart)
+    var nlFirst = re.slice(nl.reStart, nl.reEnd - 8)
+    var nlLast = re.slice(nl.reEnd - 8, nl.reEnd)
+    var nlAfter = re.slice(nl.reEnd)
+
+    nlLast += nlAfter
+
+    // Handle nested stuff like *(*.js|!(*.json)), where open parens
+    // mean that we should *not* include the ) in the bit that is considered
+    // "after" the negated section.
+    var openParensBefore = nlBefore.split('(').length - 1
+    var cleanAfter = nlAfter
+    for (i = 0; i < openParensBefore; i++) {
+      cleanAfter = cleanAfter.replace(/\)[+*?]?/, '')
+    }
+    nlAfter = cleanAfter
+
+    var dollar = ''
+    if (nlAfter === '' && isSub !== SUBPARSE) {
+      dollar = '$'
+    }
+    var newRe = nlBefore + nlFirst + nlAfter + dollar + nlLast
+    re = newRe
+  }
+
   // if the re is not "" at this point, then we need to make sure
   // it doesn't match against an empty path part.
   // Otherwise a/* will match a/, which it should not.
-  if (re !== '' && hasMagic) re = '(?=.)' + re
+  if (re !== '' && hasMagic) {
+    re = '(?=.)' + re
+  }
 
-  if (addPatternStart) re = patternStart + re
+  if (addPatternStart) {
+    re = patternStart + re
+  }
 
   // parsing just a piece of a larger pattern.
   if (isSub === SUBPARSE) {
@@ -1110,4 +1155,5 @@ module.exports = function (xs, fn) {
     return res;
 };
 
-},{}]},{},[1]);
+},{}]},{},[1])(1)
+});
\ No newline at end of file
index 5e13d6d..ec4c05c 100644 (file)
@@ -272,6 +272,7 @@ function parse (pattern, isSub) {
   var escaping = false
   // ? => one single character
   var patternListStack = []
+  var negativeLists = []
   var plType
   var stateChar
   var inClass = false
@@ -372,9 +373,13 @@ function parse (pattern, isSub) {
         }
 
         plType = stateChar
-        patternListStack.push({ type: plType, start: i - 1, reStart: re.length })
+        patternListStack.push({
+          type: plType,
+          start: i - 1,
+          reStart: re.length
+        })
         // negation is (?:(?!js)[^/]*)
-        re += stateChar === '!' ? '(?:(?!' : '(?:'
+        re += stateChar === '!' ? '(?:(?!(?:' : '(?:'
         this.debug('plType %j %j', stateChar, re)
         stateChar = false
       continue
@@ -388,12 +393,15 @@ function parse (pattern, isSub) {
         clearStateChar()
         hasMagic = true
         re += ')'
-        plType = patternListStack.pop().type
+        var pl = patternListStack.pop()
+        plType = pl.type
         // negation is (?:(?!js)[^/]*)
         // The others are (?:<pattern>)<type>
         switch (plType) {
           case '!':
-            re += '[^/]*?)'
+            negativeLists.push(pl)
+            re += ')[^/]*?)'
+            pl.reEnd = re.length
             break
           case '?':
           case '+':
@@ -507,7 +515,7 @@ function parse (pattern, isSub) {
   // and escape any | chars that were passed through as-is for the regexp.
   // Go through and escape them, taking care not to double-escape any
   // | chars that were already escaped.
-  for (var pl = patternListStack.pop(); pl; pl = patternListStack.pop()) {
+  for (pl = patternListStack.pop(); pl; pl = patternListStack.pop()) {
     var tail = re.slice(pl.reStart + 3)
     // maybe some even number of \, then maybe 1 \, followed by a |
     tail = tail.replace(/((?:\\{2})*)(\\?)\|/g, function (_, $1, $2) {
@@ -550,12 +558,49 @@ function parse (pattern, isSub) {
     case '(': addPatternStart = true
   }
 
+  // Hack to work around lack of negative lookbehind in JS
+  // A pattern like: *.!(x).!(y|z) needs to ensure that a name
+  // like 'a.xyz.yz' doesn't match.  So, the first negative
+  // lookahead, has to look ALL the way ahead, to the end of
+  // the pattern.
+  for (var n = negativeLists.length - 1; n > -1; n--) {
+    var nl = negativeLists[n]
+
+    var nlBefore = re.slice(0, nl.reStart)
+    var nlFirst = re.slice(nl.reStart, nl.reEnd - 8)
+    var nlLast = re.slice(nl.reEnd - 8, nl.reEnd)
+    var nlAfter = re.slice(nl.reEnd)
+
+    nlLast += nlAfter
+
+    // Handle nested stuff like *(*.js|!(*.json)), where open parens
+    // mean that we should *not* include the ) in the bit that is considered
+    // "after" the negated section.
+    var openParensBefore = nlBefore.split('(').length - 1
+    var cleanAfter = nlAfter
+    for (i = 0; i < openParensBefore; i++) {
+      cleanAfter = cleanAfter.replace(/\)[+*?]?/, '')
+    }
+    nlAfter = cleanAfter
+
+    var dollar = ''
+    if (nlAfter === '' && isSub !== SUBPARSE) {
+      dollar = '$'
+    }
+    var newRe = nlBefore + nlFirst + nlAfter + dollar + nlLast
+    re = newRe
+  }
+
   // if the re is not "" at this point, then we need to make sure
   // it doesn't match against an empty path part.
   // Otherwise a/* will match a/, which it should not.
-  if (re !== '' && hasMagic) re = '(?=.)' + re
+  if (re !== '' && hasMagic) {
+    re = '(?=.)' + re
+  }
 
-  if (addPatternStart) re = patternStart + re
+  if (addPatternStart) {
+    re = patternStart + re
+  }
 
   // parsing just a piece of a larger pattern.
   if (isSub === SUBPARSE) {
index b516138..2f1bd3d 100644 (file)
@@ -63,7 +63,7 @@
   "_id": "concat-map@0.0.1",
   "dist": {
     "shasum": "d8a96bd77fd68df7793a73036a3ba0d5405d477b",
-    "tarball": "http://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz"
+    "tarball": "https://registrytwo.npmjs.com/concat-map/-/concat-map-0.0.1.tgz"
   },
   "_from": "concat-map@0.0.1",
   "_npmVersion": "1.3.21",
@@ -78,6 +78,6 @@
     }
   ],
   "_shasum": "d8a96bd77fd68df7793a73036a3ba0d5405d477b",
-  "_resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz",
+  "_resolved": "https://registrytwo.npmjs.com/concat-map/-/concat-map-0.0.1.tgz",
   "readme": "ERROR: No README data found!"
 }
index 2cacae2..c7c9a08 100644 (file)
@@ -6,16 +6,16 @@
   },
   "name": "minimatch",
   "description": "a glob matcher in javascript",
-  "version": "2.0.8",
+  "version": "2.0.10",
   "repository": {
     "type": "git",
     "url": "git://github.com/isaacs/minimatch.git"
   },
   "main": "minimatch.js",
   "scripts": {
-    "pretest": "standard minimatch.js test/*.js",
+    "posttest": "standard minimatch.js test/*.js",
     "test": "tap test/*.js",
-    "prepublish": "browserify -o browser.js -e minimatch.js --bare"
+    "prepublish": "browserify -o browser.js -e minimatch.js -s minimatch --bare"
   },
   "engines": {
     "node": "*"
   "devDependencies": {
     "browserify": "^9.0.3",
     "standard": "^3.7.2",
-    "tap": ""
+    "tap": "^1.2.0"
   },
   "license": "ISC",
   "files": [
     "minimatch.js",
     "browser.js"
   ],
-  "gitHead": "0bc7d9c4b2bc816502184862b45bd090de3406a3",
+  "gitHead": "6afb85f0c324b321f76a38df81891e562693e257",
   "bugs": {
     "url": "https://github.com/isaacs/minimatch/issues"
   },
   "homepage": "https://github.com/isaacs/minimatch#readme",
-  "_id": "minimatch@2.0.8",
-  "_shasum": "0bc20f6bf3570a698ef0ddff902063c6cabda6bf",
-  "_from": "minimatch@>=2.0.8 <2.1.0",
-  "_npmVersion": "2.10.0",
-  "_nodeVersion": "2.0.1",
+  "_id": "minimatch@2.0.10",
+  "_shasum": "8d087c39c6b38c001b97fca7ce6d0e1e80afbac7",
+  "_from": "minimatch@2.0.10",
+  "_npmVersion": "3.1.0",
+  "_nodeVersion": "2.2.1",
   "_npmUser": {
     "name": "isaacs",
     "email": "isaacs@npmjs.com"
   },
   "dist": {
-    "shasum": "0bc20f6bf3570a698ef0ddff902063c6cabda6bf",
-    "tarball": "http://registry.npmjs.org/minimatch/-/minimatch-2.0.8.tgz"
+    "shasum": "8d087c39c6b38c001b97fca7ce6d0e1e80afbac7",
+    "tarball": "http://registry.npmjs.org/minimatch/-/minimatch-2.0.10.tgz"
   },
   "maintainers": [
     {
@@ -58,6 +58,5 @@
     }
   ],
   "directories": {},
-  "_resolved": "https://registry.npmjs.org/minimatch/-/minimatch-2.0.8.tgz",
-  "readme": "ERROR: No README data found!"
+  "_resolved": "https://registry.npmjs.org/minimatch/-/minimatch-2.0.10.tgz"
 }
index 57215fc..3377942 100644 (file)
@@ -1,7 +1,7 @@
 {
   'target_defaults': {
     'type': 'loadable_module',
-    'win_delay_load_hook': 'true',
+    'win_delay_load_hook': 'false',
     'product_prefix': '',
 
     'include_dirs': [
@@ -78,7 +78,7 @@
           '-luuid.lib',
           '-lodbc32.lib',
           '-lDelayImp.lib',
-          '-l"<(node_root_dir)/$(ConfigurationName)/iojs.lib"'
+          '-l"<(node_root_dir)/$(ConfigurationName)/node.lib"'
         ],
         'msvs_disabled_warnings': [
           # warning C4251: 'node::ObjectWrap::handle_' : class 'v8::Persistent<T>'
index b35ca01..eeeb602 100644 (file)
@@ -173,7 +173,7 @@ function build (gyp, argv, callback) {
   }
 
   /**
-   * Copies the iojs.lib file for the current target architecture into the
+   * Copies the node.lib file for the current target architecture into the
    * current proper dev dir location.
    */
 
@@ -181,15 +181,15 @@ function build (gyp, argv, callback) {
     if (!win || !copyDevLib) return doBuild()
 
     var buildDir = path.resolve(nodeDir, buildType)
-      , archNodeLibPath = path.resolve(nodeDir, arch, 'iojs.lib')
-      , buildNodeLibPath = path.resolve(buildDir, 'iojs.lib')
+      , archNodeLibPath = path.resolve(nodeDir, arch, 'node.lib')
+      , buildNodeLibPath = path.resolve(buildDir, 'node.lib')
 
     mkdirp(buildDir, function (err, isNew) {
       if (err) return callback(err)
       log.verbose('"' + buildType + '" dir needed to be created?', isNew)
       var rs = fs.createReadStream(archNodeLibPath)
         , ws = fs.createWriteStream(buildNodeLibPath)
-      log.verbose('copying "iojs.lib" for ' + arch, buildNodeLibPath)
+      log.verbose('copying "node.lib" for ' + arch, buildNodeLibPath)
       rs.pipe(ws)
       rs.on('error', callback)
       ws.on('error', callback)
index cdee86e..6cbcdb8 100644 (file)
@@ -39,7 +39,7 @@ function install (gyp, argv, callback) {
     }
   }
 
-  var distUrl = gyp.opts['dist-url'] || gyp.opts.disturl || 'https://iojs.org/dist'
+  var distUrl = gyp.opts['dist-url'] || gyp.opts.disturl || 'https://nodejs.org/dist'
 
 
   // Determine which node dev files version we are installing
@@ -185,7 +185,7 @@ function install (gyp, argv, callback) {
 
       // now download the node tarball
       var tarPath = gyp.opts['tarball']
-      var tarballUrl = tarPath ? tarPath : distUrl + '/v' + version + '/iojs-v' + version + '.tar.gz'
+      var tarballUrl = tarPath ? tarPath : distUrl + '/v' + version + '/node-v' + version + '.tar.gz'
         , badDownload = false
         , extractCount = 0
         , gunzip = zlib.createGunzip()
@@ -272,7 +272,7 @@ function install (gyp, argv, callback) {
         var async = 0
 
         if (win) {
-          // need to download iojs.lib
+          // need to download node.lib
           async++
           downloadNodeLib(deref)
         }
@@ -351,36 +351,36 @@ function install (gyp, argv, callback) {
       }
 
       function downloadNodeLib (done) {
-        log.verbose('on Windows; need to download `iojs.lib`...')
+        log.verbose('on Windows; need to download `node.lib`...')
         var dir32 = path.resolve(devDir, 'ia32')
           , dir64 = path.resolve(devDir, 'x64')
-          , nodeLibPath32 = path.resolve(dir32, 'iojs.lib')
-          , nodeLibPath64 = path.resolve(dir64, 'iojs.lib')
-          , nodeLibUrl32 = distUrl + '/v' + version + '/win-x86/iojs.lib'
-          , nodeLibUrl64 = distUrl + '/v' + version + '/win-x64/iojs.lib'
+          , nodeLibPath32 = path.resolve(dir32, 'node.lib')
+          , nodeLibPath64 = path.resolve(dir64, 'node.lib')
+          , nodeLibUrl32 = distUrl + '/v' + version + '/node.lib'
+          , nodeLibUrl64 = distUrl + '/v' + version + '/x64/node.lib'
 
-        log.verbose('32-bit iojs.lib dir', dir32)
-        log.verbose('64-bit iojs.lib dir', dir64)
-        log.verbose('`iojs.lib` 32-bit url', nodeLibUrl32)
-        log.verbose('`iojs.lib` 64-bit url', nodeLibUrl64)
+        log.verbose('32-bit node.lib dir', dir32)
+        log.verbose('64-bit node.lib dir', dir64)
+        log.verbose('`node.lib` 32-bit url', nodeLibUrl32)
+        log.verbose('`node.lib` 64-bit url', nodeLibUrl64)
 
         var async = 2
         mkdir(dir32, function (err) {
           if (err) return done(err)
-          log.verbose('streaming 32-bit iojs.lib to:', nodeLibPath32)
+          log.verbose('streaming 32-bit node.lib to:', nodeLibPath32)
 
           var req = download(nodeLibUrl32)
           if (!req) return
           req.on('error', done)
           req.on('response', function (res) {
             if (res.statusCode !== 200) {
-              done(new Error(res.statusCode + ' status code downloading 32-bit iojs.lib'))
+              done(new Error(res.statusCode + ' status code downloading 32-bit node.lib'))
               return
             }
 
             getContentSha(res, function (_, checksum) {
-              contentShasums['win-x86/iojs.lib'] = checksum
-              log.verbose('content checksum', 'win-x86/iojs.lib', checksum)
+              contentShasums['node.lib'] = checksum
+              log.verbose('content checksum', 'node.lib', checksum)
             })
 
             var ws = fs.createWriteStream(nodeLibPath32)
@@ -393,20 +393,20 @@ function install (gyp, argv, callback) {
         })
         mkdir(dir64, function (err) {
           if (err) return done(err)
-          log.verbose('streaming 64-bit iojs.lib to:', nodeLibPath64)
+          log.verbose('streaming 64-bit node.lib to:', nodeLibPath64)
 
           var req = download(nodeLibUrl64)
           if (!req) return
           req.on('error', done)
           req.on('response', function (res) {
             if (res.statusCode !== 200) {
-              done(new Error(res.statusCode + ' status code downloading 64-bit iojs.lib'))
+              done(new Error(res.statusCode + ' status code downloading 64-bit node.lib'))
               return
             }
 
             getContentSha(res, function (_, checksum) {
-              contentShasums['win-x64/iojs.lib'] = checksum
-              log.verbose('content checksum', 'win-x64/iojs.lib', checksum)
+              contentShasums['x64/node.lib'] = checksum
+              log.verbose('content checksum', 'x64/node.lib', checksum)
             })
 
             var ws = fs.createWriteStream(nodeLibPath64)
diff --git a/deps/npm/node_modules/node-gyp/node_modules/path-array/node_modules/array-index/.jshintrc b/deps/npm/node_modules/node-gyp/node_modules/path-array/node_modules/array-index/.jshintrc
deleted file mode 100644 (file)
index 182e34d..0000000
+++ /dev/null
@@ -1,4 +0,0 @@
-{
-  "asi": true,
-  "laxcomma": true
-}
diff --git a/deps/npm/node_modules/node-gyp/node_modules/path-array/node_modules/array-index/node_modules/debug/.jshintrc b/deps/npm/node_modules/node-gyp/node_modules/path-array/node_modules/array-index/node_modules/debug/.jshintrc
deleted file mode 100644 (file)
index 299877f..0000000
+++ /dev/null
@@ -1,3 +0,0 @@
-{
-  "laxbreak": true
-}
diff --git a/deps/npm/node_modules/node-gyp/node_modules/semver/.npmignore b/deps/npm/node_modules/node-gyp/node_modules/semver/.npmignore
new file mode 100644 (file)
index 0000000..534108e
--- /dev/null
@@ -0,0 +1,4 @@
+node_modules/
+coverage/
+.nyc_output/
+nyc_output/
diff --git a/deps/npm/node_modules/node-gyp/node_modules/semver/.travis.yml b/deps/npm/node_modules/node-gyp/node_modules/semver/.travis.yml
new file mode 100644 (file)
index 0000000..991d04b
--- /dev/null
@@ -0,0 +1,5 @@
+language: node_js
+node_js:
+  - '0.10'
+  - '0.12'
+  - 'iojs'
diff --git a/deps/npm/node_modules/node-gyp/node_modules/semver/README.md b/deps/npm/node_modules/node-gyp/node_modules/semver/README.md
new file mode 100644 (file)
index 0000000..b5e35ff
--- /dev/null
@@ -0,0 +1,303 @@
+semver(1) -- 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> | --preid <identifier> | -l | -rv]
+    Test if version(s) satisfy the supplied range(s), and sort them.
+
+    Multiple versions or ranges may be supplied, unless increment
+    option is 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`.
+
+### Prerelease Tags
+
+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.
+
+#### Prerelease Identifiers
+
+The method `.inc` takes an additional `identifier` string argument that
+will append the value of the string as a prerelease identifier:
+
+```javascript
+> semver.inc('1.2.3', 'pre', 'beta')
+'1.2.4-beta.0'
+```
+
+command-line example:
+
+```shell
+$ semver 1.2.3 -i prerelease --preid beta
+1.2.4-beta.0
+```
+
+Which then can be used to increment further:
+
+```shell
+$ semver 1.2.4-beta.0 -i prerelease
+1.2.4-beta.1
+```
+
+### 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.
+
+#### 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.
+* `major(v)`: Return the major version number.
+* `minor(v)`: Return the minor version number.
+* `patch(v)`: Return the patch version number.
+
+### 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()`.
+* `diff(v1, v2)`: Returns difference between two versions by the release type
+  (`major`, `premajor`, `minor`, `preminor`, `patch`, `prepatch`, or `prerelease`),
+  or null if the versions are the same.
+
+
+### 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 --git a/deps/npm/node_modules/node-gyp/node_modules/semver/bin/semver b/deps/npm/node_modules/node-gyp/node_modules/semver/bin/semver
new file mode 100755 (executable)
index 0000000..c5f2e85
--- /dev/null
@@ -0,0 +1,133 @@
+#!/usr/bin/env node
+// Standalone semver comparison program.
+// Exits successfully and prints matching version(s) if
+// any supplied version is valid and passes all tests.
+
+var argv = process.argv.slice(2)
+  , versions = []
+  , range = []
+  , gt = []
+  , lt = []
+  , eq = []
+  , inc = null
+  , version = require("../package.json").version
+  , loose = false
+  , identifier = undefined
+  , semver = require("../semver")
+  , reverse = false
+
+main()
+
+function main () {
+  if (!argv.length) return help()
+  while (argv.length) {
+    var a = argv.shift()
+    var i = a.indexOf('=')
+    if (i !== -1) {
+      a = a.slice(0, i)
+      argv.unshift(a.slice(i + 1))
+    }
+    switch (a) {
+      case "-rv": case "-rev": case "--rev": case "--reverse":
+        reverse = true
+        break
+      case "-l": case "--loose":
+        loose = true
+        break
+      case "-v": case "--version":
+        versions.push(argv.shift())
+        break
+      case "-i": case "--inc": case "--increment":
+        switch (argv[0]) {
+          case "major": case "minor": case "patch": case "prerelease":
+          case "premajor": case "preminor": case "prepatch":
+            inc = argv.shift()
+            break
+          default:
+            inc = "patch"
+            break
+        }
+        break
+      case "--preid":
+        identifier = argv.shift()
+        break
+      case "-r": case "--range":
+        range.push(argv.shift())
+        break
+      case "-h": case "--help": case "-?":
+        return help()
+      default:
+        versions.push(a)
+        break
+    }
+  }
+
+  versions = versions.filter(function (v) {
+    return semver.valid(v, loose)
+  })
+  if (!versions.length) return fail()
+  if (inc && (versions.length !== 1 || range.length))
+    return failInc()
+
+  for (var i = 0, l = range.length; i < l ; i ++) {
+    versions = versions.filter(function (v) {
+      return semver.satisfies(v, range[i], loose)
+    })
+    if (!versions.length) return fail()
+  }
+  return success(versions)
+}
+
+function failInc () {
+  console.error("--inc can only be used on a single version with no range")
+  fail()
+}
+
+function fail () { process.exit(1) }
+
+function success () {
+  var compare = reverse ? "rcompare" : "compare"
+  versions.sort(function (a, b) {
+    return semver[compare](a, b, loose)
+  }).map(function (v) {
+    return semver.clean(v, loose)
+  }).map(function (v) {
+    return inc ? semver.inc(v, inc, loose, identifier) : v
+  }).forEach(function (v,i,_) { console.log(v) })
+}
+
+function help () {
+  console.log(["SemVer " + version
+              ,""
+              ,"A JavaScript implementation of the http://semver.org/ specification"
+              ,"Copyright Isaac Z. Schlueter"
+              ,""
+              ,"Usage: semver [options] <version> [<version> [...]]"
+              ,"Prints valid versions sorted by SemVer precedence"
+              ,""
+              ,"Options:"
+              ,"-r --range <range>"
+              ,"        Print versions that match the specified range."
+              ,""
+              ,"-i --increment [<level>]"
+              ,"        Increment a version by the specified level.  Level can"
+              ,"        be one of: major, minor, patch, premajor, preminor,"
+              ,"        prepatch, or prerelease.  Default level is 'patch'."
+              ,"        Only one version may be specified."
+              ,""
+              ,"--preid <identifier>"
+              ,"        Identifier to be used to prefix premajor, preminor,"
+              ,"        prepatch or prerelease version increments."
+              ,""
+              ,"-l --loose"
+              ,"        Interpret versions and ranges loosely"
+              ,""
+              ,"Program exits successfully if any valid version satisfies"
+              ,"all supplied ranges, and prints all satisfying versions."
+              ,""
+              ,"If no satisfying versions are found, then exits failure."
+              ,""
+              ,"Versions are printed in ascending order, so supplying"
+              ,"multiple versions to the utility will just sort them."
+              ].join("\n"))
+}
diff --git a/deps/npm/node_modules/node-gyp/node_modules/semver/package.json b/deps/npm/node_modules/node-gyp/node_modules/semver/package.json
new file mode 100644 (file)
index 0000000..e9b6abe
--- /dev/null
@@ -0,0 +1,55 @@
+{
+  "name": "semver",
+  "version": "4.3.6",
+  "description": "The semantic version parser used by npm.",
+  "main": "semver.js",
+  "browser": "semver.browser.js",
+  "min": "semver.min.js",
+  "scripts": {
+    "test": "tap test/*.js",
+    "prepublish": "make"
+  },
+  "devDependencies": {
+    "tap": "^1.2.0",
+    "uglify-js": "~2.3.6"
+  },
+  "license": "ISC",
+  "repository": {
+    "type": "git",
+    "url": "git://github.com/npm/node-semver.git"
+  },
+  "bin": {
+    "semver": "./bin/semver"
+  },
+  "gitHead": "63c48296ca5da3ba6a88c743bb8c92effc789811",
+  "bugs": {
+    "url": "https://github.com/npm/node-semver/issues"
+  },
+  "homepage": "https://github.com/npm/node-semver#readme",
+  "_id": "semver@4.3.6",
+  "_shasum": "300bc6e0e86374f7ba61068b5b1ecd57fc6532da",
+  "_from": "semver@>=2.0.0 <3.0.0||>=3.0.0 <4.0.0||>=4.0.0 <5.0.0",
+  "_npmVersion": "2.10.1",
+  "_nodeVersion": "2.0.1",
+  "_npmUser": {
+    "name": "isaacs",
+    "email": "isaacs@npmjs.com"
+  },
+  "dist": {
+    "shasum": "300bc6e0e86374f7ba61068b5b1ecd57fc6532da",
+    "tarball": "http://registry.npmjs.org/semver/-/semver-4.3.6.tgz"
+  },
+  "maintainers": [
+    {
+      "name": "isaacs",
+      "email": "isaacs@npmjs.com"
+    },
+    {
+      "name": "othiym23",
+      "email": "ogd@aoaioxxysz.net"
+    }
+  ],
+  "directories": {},
+  "_resolved": "https://registry.npmjs.org/semver/-/semver-4.3.6.tgz",
+  "readme": "ERROR: No README data found!"
+}
diff --git a/deps/npm/node_modules/node-gyp/node_modules/semver/semver.js b/deps/npm/node_modules/node-gyp/node_modules/semver/semver.js
new file mode 100644 (file)
index 0000000..cafcc00
--- /dev/null
@@ -0,0 +1,1205 @@
+// export the class if we are in a Node-like system.
+if (typeof module === 'object' && module.exports === exports)
+  exports = module.exports = SemVer;
+
+// The debug function is excluded entirely from the minified version.
+/* nomin */ var debug;
+/* nomin */ if (typeof process === 'object' &&
+    /* nomin */ process.env &&
+    /* nomin */ process.env.NODE_DEBUG &&
+    /* nomin */ /\bsemver\b/i.test(process.env.NODE_DEBUG))
+  /* nomin */ debug = function() {
+    /* nomin */ var args = Array.prototype.slice.call(arguments, 0);
+    /* nomin */ args.unshift('SEMVER');
+    /* nomin */ console.log.apply(console, args);
+    /* nomin */ };
+/* nomin */ else
+  /* nomin */ debug = function() {};
+
+// Note: this is the semver.org version of the spec that it implements
+// Not necessarily the package version of this code.
+exports.SEMVER_SPEC_VERSION = '2.0.0';
+
+var MAX_LENGTH = 256;
+var MAX_SAFE_INTEGER = Number.MAX_SAFE_INTEGER || 9007199254740991;
+
+// The actual regexps go on exports.re
+var re = exports.re = [];
+var src = exports.src = [];
+var R = 0;
+
+// The following Regular Expressions can be used for tokenizing,
+// validating, and parsing SemVer version strings.
+
+// ## Numeric Identifier
+// A single `0`, or a non-zero digit followed by zero or more digits.
+
+var NUMERICIDENTIFIER = R++;
+src[NUMERICIDENTIFIER] = '0|[1-9]\\d*';
+var NUMERICIDENTIFIERLOOSE = R++;
+src[NUMERICIDENTIFIERLOOSE] = '[0-9]+';
+
+
+// ## Non-numeric Identifier
+// Zero or more digits, followed by a letter or hyphen, and then zero or
+// more letters, digits, or hyphens.
+
+var NONNUMERICIDENTIFIER = R++;
+src[NONNUMERICIDENTIFIER] = '\\d*[a-zA-Z-][a-zA-Z0-9-]*';
+
+
+// ## Main Version
+// Three dot-separated numeric identifiers.
+
+var MAINVERSION = R++;
+src[MAINVERSION] = '(' + src[NUMERICIDENTIFIER] + ')\\.' +
+                   '(' + src[NUMERICIDENTIFIER] + ')\\.' +
+                   '(' + src[NUMERICIDENTIFIER] + ')';
+
+var MAINVERSIONLOOSE = R++;
+src[MAINVERSIONLOOSE] = '(' + src[NUMERICIDENTIFIERLOOSE] + ')\\.' +
+                        '(' + src[NUMERICIDENTIFIERLOOSE] + ')\\.' +
+                        '(' + src[NUMERICIDENTIFIERLOOSE] + ')';
+
+// ## Pre-release Version Identifier
+// A numeric identifier, or a non-numeric identifier.
+
+var PRERELEASEIDENTIFIER = R++;
+src[PRERELEASEIDENTIFIER] = '(?:' + src[NUMERICIDENTIFIER] +
+                            '|' + src[NONNUMERICIDENTIFIER] + ')';
+
+var PRERELEASEIDENTIFIERLOOSE = R++;
+src[PRERELEASEIDENTIFIERLOOSE] = '(?:' + src[NUMERICIDENTIFIERLOOSE] +
+                                 '|' + src[NONNUMERICIDENTIFIER] + ')';
+
+
+// ## Pre-release Version
+// Hyphen, followed by one or more dot-separated pre-release version
+// identifiers.
+
+var PRERELEASE = R++;
+src[PRERELEASE] = '(?:-(' + src[PRERELEASEIDENTIFIER] +
+                  '(?:\\.' + src[PRERELEASEIDENTIFIER] + ')*))';
+
+var PRERELEASELOOSE = R++;
+src[PRERELEASELOOSE] = '(?:-?(' + src[PRERELEASEIDENTIFIERLOOSE] +
+                       '(?:\\.' + src[PRERELEASEIDENTIFIERLOOSE] + ')*))';
+
+// ## Build Metadata Identifier
+// Any combination of digits, letters, or hyphens.
+
+var BUILDIDENTIFIER = R++;
+src[BUILDIDENTIFIER] = '[0-9A-Za-z-]+';
+
+// ## Build Metadata
+// Plus sign, followed by one or more period-separated build metadata
+// identifiers.
+
+var BUILD = R++;
+src[BUILD] = '(?:\\+(' + src[BUILDIDENTIFIER] +
+             '(?:\\.' + src[BUILDIDENTIFIER] + ')*))';
+
+
+// ## Full Version String
+// A main version, followed optionally by a pre-release version and
+// build metadata.
+
+// Note that the only major, minor, patch, and pre-release sections of
+// the version string are capturing groups.  The build metadata is not a
+// capturing group, because it should not ever be used in version
+// comparison.
+
+var FULL = R++;
+var FULLPLAIN = 'v?' + src[MAINVERSION] +
+                src[PRERELEASE] + '?' +
+                src[BUILD] + '?';
+
+src[FULL] = '^' + FULLPLAIN + '$';
+
+// like full, but allows v1.2.3 and =1.2.3, which people do sometimes.
+// also, 1.0.0alpha1 (prerelease without the hyphen) which is pretty
+// common in the npm registry.
+var LOOSEPLAIN = '[v=\\s]*' + src[MAINVERSIONLOOSE] +
+                 src[PRERELEASELOOSE] + '?' +
+                 src[BUILD] + '?';
+
+var LOOSE = R++;
+src[LOOSE] = '^' + LOOSEPLAIN + '$';
+
+var GTLT = R++;
+src[GTLT] = '((?:<|>)?=?)';
+
+// Something like "2.*" or "1.2.x".
+// Note that "x.x" is a valid xRange identifer, meaning "any version"
+// Only the first item is strictly required.
+var XRANGEIDENTIFIERLOOSE = R++;
+src[XRANGEIDENTIFIERLOOSE] = src[NUMERICIDENTIFIERLOOSE] + '|x|X|\\*';
+var XRANGEIDENTIFIER = R++;
+src[XRANGEIDENTIFIER] = src[NUMERICIDENTIFIER] + '|x|X|\\*';
+
+var XRANGEPLAIN = R++;
+src[XRANGEPLAIN] = '[v=\\s]*(' + src[XRANGEIDENTIFIER] + ')' +
+                   '(?:\\.(' + src[XRANGEIDENTIFIER] + ')' +
+                   '(?:\\.(' + src[XRANGEIDENTIFIER] + ')' +
+                   '(?:' + src[PRERELEASE] + ')?' +
+                   src[BUILD] + '?' +
+                   ')?)?';
+
+var XRANGEPLAINLOOSE = R++;
+src[XRANGEPLAINLOOSE] = '[v=\\s]*(' + src[XRANGEIDENTIFIERLOOSE] + ')' +
+                        '(?:\\.(' + src[XRANGEIDENTIFIERLOOSE] + ')' +
+                        '(?:\\.(' + src[XRANGEIDENTIFIERLOOSE] + ')' +
+                        '(?:' + src[PRERELEASELOOSE] + ')?' +
+                        src[BUILD] + '?' +
+                        ')?)?';
+
+var XRANGE = R++;
+src[XRANGE] = '^' + src[GTLT] + '\\s*' + src[XRANGEPLAIN] + '$';
+var XRANGELOOSE = R++;
+src[XRANGELOOSE] = '^' + src[GTLT] + '\\s*' + src[XRANGEPLAINLOOSE] + '$';
+
+// Tilde ranges.
+// Meaning is "reasonably at or greater than"
+var LONETILDE = R++;
+src[LONETILDE] = '(?:~>?)';
+
+var TILDETRIM = R++;
+src[TILDETRIM] = '(\\s*)' + src[LONETILDE] + '\\s+';
+re[TILDETRIM] = new RegExp(src[TILDETRIM], 'g');
+var tildeTrimReplace = '$1~';
+
+var TILDE = R++;
+src[TILDE] = '^' + src[LONETILDE] + src[XRANGEPLAIN] + '$';
+var TILDELOOSE = R++;
+src[TILDELOOSE] = '^' + src[LONETILDE] + src[XRANGEPLAINLOOSE] + '$';
+
+// Caret ranges.
+// Meaning is "at least and backwards compatible with"
+var LONECARET = R++;
+src[LONECARET] = '(?:\\^)';
+
+var CARETTRIM = R++;
+src[CARETTRIM] = '(\\s*)' + src[LONECARET] + '\\s+';
+re[CARETTRIM] = new RegExp(src[CARETTRIM], 'g');
+var caretTrimReplace = '$1^';
+
+var CARET = R++;
+src[CARET] = '^' + src[LONECARET] + src[XRANGEPLAIN] + '$';
+var CARETLOOSE = R++;
+src[CARETLOOSE] = '^' + src[LONECARET] + src[XRANGEPLAINLOOSE] + '$';
+
+// A simple gt/lt/eq thing, or just "" to indicate "any version"
+var COMPARATORLOOSE = R++;
+src[COMPARATORLOOSE] = '^' + src[GTLT] + '\\s*(' + LOOSEPLAIN + ')$|^$';
+var COMPARATOR = R++;
+src[COMPARATOR] = '^' + src[GTLT] + '\\s*(' + FULLPLAIN + ')$|^$';
+
+
+// An expression to strip any whitespace between the gtlt and the thing
+// it modifies, so that `> 1.2.3` ==> `>1.2.3`
+var COMPARATORTRIM = R++;
+src[COMPARATORTRIM] = '(\\s*)' + src[GTLT] +
+                      '\\s*(' + LOOSEPLAIN + '|' + src[XRANGEPLAIN] + ')';
+
+// this one has to use the /g flag
+re[COMPARATORTRIM] = new RegExp(src[COMPARATORTRIM], 'g');
+var comparatorTrimReplace = '$1$2$3';
+
+
+// Something like `1.2.3 - 1.2.4`
+// Note that these all use the loose form, because they'll be
+// checked against either the strict or loose comparator form
+// later.
+var HYPHENRANGE = R++;
+src[HYPHENRANGE] = '^\\s*(' + src[XRANGEPLAIN] + ')' +
+                   '\\s+-\\s+' +
+                   '(' + src[XRANGEPLAIN] + ')' +
+                   '\\s*$';
+
+var HYPHENRANGELOOSE = R++;
+src[HYPHENRANGELOOSE] = '^\\s*(' + src[XRANGEPLAINLOOSE] + ')' +
+                        '\\s+-\\s+' +
+                        '(' + src[XRANGEPLAINLOOSE] + ')' +
+                        '\\s*$';
+
+// Star ranges basically just allow anything at all.
+var STAR = R++;
+src[STAR] = '(<|>)?=?\\s*\\*';
+
+// Compile to actual regexp objects.
+// All are flag-free, unless they were created above with a flag.
+for (var i = 0; i < R; i++) {
+  debug(i, src[i]);
+  if (!re[i])
+    re[i] = new RegExp(src[i]);
+}
+
+exports.parse = parse;
+function parse(version, loose) {
+  if (version instanceof SemVer)
+    return version;
+
+  if (typeof version !== 'string')
+    return null;
+
+  if (version.length > MAX_LENGTH)
+    return null;
+
+  var r = loose ? re[LOOSE] : re[FULL];
+  if (!r.test(version))
+    return null;
+
+  try {
+    return new SemVer(version, loose);
+  } catch (er) {
+    return null;
+  }
+}
+
+exports.valid = valid;
+function valid(version, loose) {
+  var v = parse(version, loose);
+  return v ? v.version : null;
+}
+
+
+exports.clean = clean;
+function clean(version, loose) {
+  var s = parse(version.trim().replace(/^[=v]+/, ''), loose);
+  return s ? s.version : null;
+}
+
+exports.SemVer = SemVer;
+
+function SemVer(version, loose) {
+  if (version instanceof SemVer) {
+    if (version.loose === loose)
+      return version;
+    else
+      version = version.version;
+  } else if (typeof version !== 'string') {
+    throw new TypeError('Invalid Version: ' + version);
+  }
+
+  if (version.length > MAX_LENGTH)
+    throw new TypeError('version is longer than ' + MAX_LENGTH + ' characters')
+
+  if (!(this instanceof SemVer))
+    return new SemVer(version, loose);
+
+  debug('SemVer', version, loose);
+  this.loose = loose;
+  var m = version.trim().match(loose ? re[LOOSE] : re[FULL]);
+
+  if (!m)
+    throw new TypeError('Invalid Version: ' + version);
+
+  this.raw = version;
+
+  // these are actually numbers
+  this.major = +m[1];
+  this.minor = +m[2];
+  this.patch = +m[3];
+
+  if (this.major > MAX_SAFE_INTEGER || this.major < 0)
+    throw new TypeError('Invalid major version')
+
+  if (this.minor > MAX_SAFE_INTEGER || this.minor < 0)
+    throw new TypeError('Invalid minor version')
+
+  if (this.patch > MAX_SAFE_INTEGER || this.patch < 0)
+    throw new TypeError('Invalid patch version')
+
+  // numberify any prerelease numeric ids
+  if (!m[4])
+    this.prerelease = [];
+  else
+    this.prerelease = m[4].split('.').map(function(id) {
+      if (/^[0-9]+$/.test(id)) {
+        var num = +id
+        if (num >= 0 && num < MAX_SAFE_INTEGER)
+          return num
+      }
+      return id;
+    });
+
+  this.build = m[5] ? m[5].split('.') : [];
+  this.format();
+}
+
+SemVer.prototype.format = function() {
+  this.version = this.major + '.' + this.minor + '.' + this.patch;
+  if (this.prerelease.length)
+    this.version += '-' + this.prerelease.join('.');
+  return this.version;
+};
+
+SemVer.prototype.inspect = function() {
+  return '<SemVer "' + this + '">';
+};
+
+SemVer.prototype.toString = function() {
+  return this.version;
+};
+
+SemVer.prototype.compare = function(other) {
+  debug('SemVer.compare', this.version, this.loose, other);
+  if (!(other instanceof SemVer))
+    other = new SemVer(other, this.loose);
+
+  return this.compareMain(other) || this.comparePre(other);
+};
+
+SemVer.prototype.compareMain = function(other) {
+  if (!(other instanceof SemVer))
+    other = new SemVer(other, this.loose);
+
+  return compareIdentifiers(this.major, other.major) ||
+         compareIdentifiers(this.minor, other.minor) ||
+         compareIdentifiers(this.patch, other.patch);
+};
+
+SemVer.prototype.comparePre = function(other) {
+  if (!(other instanceof SemVer))
+    other = new SemVer(other, this.loose);
+
+  // NOT having a prerelease is > having one
+  if (this.prerelease.length && !other.prerelease.length)
+    return -1;
+  else if (!this.prerelease.length && other.prerelease.length)
+    return 1;
+  else if (!this.prerelease.length && !other.prerelease.length)
+    return 0;
+
+  var i = 0;
+  do {
+    var a = this.prerelease[i];
+    var b = other.prerelease[i];
+    debug('prerelease compare', i, a, b);
+    if (a === undefined && b === undefined)
+      return 0;
+    else if (b === undefined)
+      return 1;
+    else if (a === undefined)
+      return -1;
+    else if (a === b)
+      continue;
+    else
+      return compareIdentifiers(a, b);
+  } while (++i);
+};
+
+// 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, identifier) {
+  switch (release) {
+    case 'premajor':
+      this.prerelease.length = 0;
+      this.patch = 0;
+      this.minor = 0;
+      this.major++;
+      this.inc('pre', identifier);
+      break;
+    case 'preminor':
+      this.prerelease.length = 0;
+      this.patch = 0;
+      this.minor++;
+      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', 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', identifier);
+      this.inc('pre', identifier);
+      break;
+
+    case 'major':
+      // If this is a pre-major version, bump up to the same major version.
+      // Otherwise increment major.
+      // 1.0.0-5 bumps to 1.0.0
+      // 1.1.0 bumps to 2.0.0
+      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 is a pre-minor version, bump up to the same minor version.
+      // Otherwise increment minor.
+      // 1.2.0-5 bumps to 1.2.0
+      // 1.2.1 bumps to 1.3.0
+      if (this.patch !== 0 || this.prerelease.length === 0)
+        this.minor++;
+      this.patch = 0;
+      this.prerelease = [];
+      break;
+    case 'patch':
+      // If this is not a pre-release version, it will increment the patch.
+      // If it is a pre-release it will bump up to the same patch version.
+      // 1.2.0-5 patches to 1.2.0
+      // 1.2.0 patches to 1.2.1
+      if (this.prerelease.length === 0)
+        this.patch++;
+      this.prerelease = [];
+      break;
+    // This probably shouldn't be used publicly.
+    // 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];
+      else {
+        var i = this.prerelease.length;
+        while (--i >= 0) {
+          if (typeof this.prerelease[i] === 'number') {
+            this.prerelease[i]++;
+            i = -2;
+          }
+        }
+        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:
+      throw new Error('invalid increment argument: ' + release);
+  }
+  this.format();
+  return this;
+};
+
+exports.inc = inc;
+function inc(version, release, loose, identifier) {
+  if (typeof(loose) === 'string') {
+    identifier = loose;
+    loose = undefined;
+  }
+
+  try {
+    return new SemVer(version, loose).inc(release, identifier).version;
+  } catch (er) {
+    return null;
+  }
+}
+
+exports.diff = diff;
+function diff(version1, version2) {
+  if (eq(version1, version2)) {
+    return null;
+  } else {
+    var v1 = parse(version1);
+    var v2 = parse(version2);
+    if (v1.prerelease.length || v2.prerelease.length) {
+      for (var key in v1) {
+        if (key === 'major' || key === 'minor' || key === 'patch') {
+          if (v1[key] !== v2[key]) {
+            return 'pre'+key;
+          }
+        }
+      }
+      return 'prerelease';
+    }
+    for (var key in v1) {
+      if (key === 'major' || key === 'minor' || key === 'patch') {
+        if (v1[key] !== v2[key]) {
+          return key;
+        }
+      }
+    }
+  }
+}
+
+exports.compareIdentifiers = compareIdentifiers;
+
+var numeric = /^[0-9]+$/;
+function compareIdentifiers(a, b) {
+  var anum = numeric.test(a);
+  var bnum = numeric.test(b);
+
+  if (anum && bnum) {
+    a = +a;
+    b = +b;
+  }
+
+  return (anum && !bnum) ? -1 :
+         (bnum && !anum) ? 1 :
+         a < b ? -1 :
+         a > b ? 1 :
+         0;
+}
+
+exports.rcompareIdentifiers = rcompareIdentifiers;
+function rcompareIdentifiers(a, b) {
+  return compareIdentifiers(b, a);
+}
+
+exports.major = major;
+function major(a, loose) {
+  return new SemVer(a, loose).major;
+}
+
+exports.minor = minor;
+function minor(a, loose) {
+  return new SemVer(a, loose).minor;
+}
+
+exports.patch = patch;
+function patch(a, loose) {
+  return new SemVer(a, loose).patch;
+}
+
+exports.compare = compare;
+function compare(a, b, loose) {
+  return new SemVer(a, loose).compare(b);
+}
+
+exports.compareLoose = compareLoose;
+function compareLoose(a, b) {
+  return compare(a, b, true);
+}
+
+exports.rcompare = rcompare;
+function rcompare(a, b, loose) {
+  return compare(b, a, loose);
+}
+
+exports.sort = sort;
+function sort(list, loose) {
+  return list.sort(function(a, b) {
+    return exports.compare(a, b, loose);
+  });
+}
+
+exports.rsort = rsort;
+function rsort(list, loose) {
+  return list.sort(function(a, b) {
+    return exports.rcompare(a, b, loose);
+  });
+}
+
+exports.gt = gt;
+function gt(a, b, loose) {
+  return compare(a, b, loose) > 0;
+}
+
+exports.lt = lt;
+function lt(a, b, loose) {
+  return compare(a, b, loose) < 0;
+}
+
+exports.eq = eq;
+function eq(a, b, loose) {
+  return compare(a, b, loose) === 0;
+}
+
+exports.neq = neq;
+function neq(a, b, loose) {
+  return compare(a, b, loose) !== 0;
+}
+
+exports.gte = gte;
+function gte(a, b, loose) {
+  return compare(a, b, loose) >= 0;
+}
+
+exports.lte = lte;
+function lte(a, b, loose) {
+  return compare(a, b, loose) <= 0;
+}
+
+exports.cmp = cmp;
+function cmp(a, op, b, loose) {
+  var ret;
+  switch (op) {
+    case '===':
+      if (typeof a === 'object') a = a.version;
+      if (typeof b === 'object') b = b.version;
+      ret = a === b;
+      break;
+    case '!==':
+      if (typeof a === 'object') a = a.version;
+      if (typeof b === 'object') b = b.version;
+      ret = a !== b;
+      break;
+    case '': case '=': case '==': ret = eq(a, b, loose); break;
+    case '!=': ret = neq(a, b, loose); break;
+    case '>': ret = gt(a, b, loose); break;
+    case '>=': ret = gte(a, b, loose); break;
+    case '<': ret = lt(a, b, loose); break;
+    case '<=': ret = lte(a, b, loose); break;
+    default: throw new TypeError('Invalid operator: ' + op);
+  }
+  return ret;
+}
+
+exports.Comparator = Comparator;
+function Comparator(comp, loose) {
+  if (comp instanceof Comparator) {
+    if (comp.loose === loose)
+      return comp;
+    else
+      comp = comp.value;
+  }
+
+  if (!(this instanceof Comparator))
+    return new Comparator(comp, loose);
+
+  debug('comparator', comp, loose);
+  this.loose = loose;
+  this.parse(comp);
+
+  if (this.semver === ANY)
+    this.value = '';
+  else
+    this.value = this.operator + this.semver.version;
+
+  debug('comp', this);
+}
+
+var ANY = {};
+Comparator.prototype.parse = function(comp) {
+  var r = this.loose ? re[COMPARATORLOOSE] : re[COMPARATOR];
+  var m = comp.match(r);
+
+  if (!m)
+    throw new TypeError('Invalid comparator: ' + comp);
+
+  this.operator = m[1];
+  if (this.operator === '=')
+    this.operator = '';
+
+  // if it literally is just '>' or '' then allow anything.
+  if (!m[2])
+    this.semver = ANY;
+  else
+    this.semver = new SemVer(m[2], this.loose);
+};
+
+Comparator.prototype.inspect = function() {
+  return '<SemVer Comparator "' + this + '">';
+};
+
+Comparator.prototype.toString = function() {
+  return this.value;
+};
+
+Comparator.prototype.test = function(version) {
+  debug('Comparator.test', version, this.loose);
+
+  if (this.semver === ANY)
+    return true;
+
+  if (typeof version === 'string')
+    version = new SemVer(version, this.loose);
+
+  return cmp(version, this.operator, this.semver, this.loose);
+};
+
+
+exports.Range = Range;
+function Range(range, loose) {
+  if ((range instanceof Range) && range.loose === loose)
+    return range;
+
+  if (!(this instanceof Range))
+    return new Range(range, loose);
+
+  this.loose = loose;
+
+  // First, split based on boolean or ||
+  this.raw = range;
+  this.set = range.split(/\s*\|\|\s*/).map(function(range) {
+    return this.parseRange(range.trim());
+  }, this).filter(function(c) {
+    // throw out any that are not relevant for whatever reason
+    return c.length;
+  });
+
+  if (!this.set.length) {
+    throw new TypeError('Invalid SemVer Range: ' + range);
+  }
+
+  this.format();
+}
+
+Range.prototype.inspect = function() {
+  return '<SemVer Range "' + this.range + '">';
+};
+
+Range.prototype.format = function() {
+  this.range = this.set.map(function(comps) {
+    return comps.join(' ').trim();
+  }).join('||').trim();
+  return this.range;
+};
+
+Range.prototype.toString = function() {
+  return this.range;
+};
+
+Range.prototype.parseRange = function(range) {
+  var loose = this.loose;
+  range = range.trim();
+  debug('range', range, loose);
+  // `1.2.3 - 1.2.4` => `>=1.2.3 <=1.2.4`
+  var hr = loose ? re[HYPHENRANGELOOSE] : re[HYPHENRANGE];
+  range = range.replace(hr, hyphenReplace);
+  debug('hyphen replace', range);
+  // `> 1.2.3 < 1.2.5` => `>1.2.3 <1.2.5`
+  range = range.replace(re[COMPARATORTRIM], comparatorTrimReplace);
+  debug('comparator trim', range, re[COMPARATORTRIM]);
+
+  // `~ 1.2.3` => `~1.2.3`
+  range = range.replace(re[TILDETRIM], tildeTrimReplace);
+
+  // `^ 1.2.3` => `^1.2.3`
+  range = range.replace(re[CARETTRIM], caretTrimReplace);
+
+  // normalize spaces
+  range = range.split(/\s+/).join(' ');
+
+  // At this point, the range is completely trimmed and
+  // ready to be split into comparators.
+
+  var compRe = loose ? re[COMPARATORLOOSE] : re[COMPARATOR];
+  var set = range.split(' ').map(function(comp) {
+    return parseComparator(comp, loose);
+  }).join(' ').split(/\s+/);
+  if (this.loose) {
+    // in loose mode, throw out any that are not valid comparators
+    set = set.filter(function(comp) {
+      return !!comp.match(compRe);
+    });
+  }
+  set = set.map(function(comp) {
+    return new Comparator(comp, loose);
+  });
+
+  return set;
+};
+
+// Mostly just for testing and legacy API reasons
+exports.toComparators = toComparators;
+function toComparators(range, loose) {
+  return new Range(range, loose).set.map(function(comp) {
+    return comp.map(function(c) {
+      return c.value;
+    }).join(' ').trim().split(' ');
+  });
+}
+
+// comprised of xranges, tildes, stars, and gtlt's at this point.
+// already replaced the hyphen ranges
+// turn into a set of JUST comparators.
+function parseComparator(comp, loose) {
+  debug('comp', comp);
+  comp = replaceCarets(comp, loose);
+  debug('caret', comp);
+  comp = replaceTildes(comp, loose);
+  debug('tildes', comp);
+  comp = replaceXRanges(comp, loose);
+  debug('xrange', comp);
+  comp = replaceStars(comp, loose);
+  debug('stars', comp);
+  return comp;
+}
+
+function isX(id) {
+  return !id || id.toLowerCase() === 'x' || id === '*';
+}
+
+// ~, ~> --> * (any, kinda silly)
+// ~2, ~2.x, ~2.x.x, ~>2, ~>2.x ~>2.x.x --> >=2.0.0 <3.0.0
+// ~2.0, ~2.0.x, ~>2.0, ~>2.0.x --> >=2.0.0 <2.1.0
+// ~1.2, ~1.2.x, ~>1.2, ~>1.2.x --> >=1.2.0 <1.3.0
+// ~1.2.3, ~>1.2.3 --> >=1.2.3 <1.3.0
+// ~1.2.0, ~>1.2.0 --> >=1.2.0 <1.3.0
+function replaceTildes(comp, loose) {
+  return comp.trim().split(/\s+/).map(function(comp) {
+    return replaceTilde(comp, loose);
+  }).join(' ');
+}
+
+function replaceTilde(comp, loose) {
+  var r = loose ? re[TILDELOOSE] : re[TILDE];
+  return comp.replace(r, function(_, M, m, p, pr) {
+    debug('tilde', comp, _, M, m, p, pr);
+    var ret;
+
+    if (isX(M))
+      ret = '';
+    else if (isX(m))
+      ret = '>=' + M + '.0.0 <' + (+M + 1) + '.0.0';
+    else if (isX(p))
+      // ~1.2 == >=1.2.0- <1.3.0-
+      ret = '>=' + M + '.' + m + '.0 <' + M + '.' + (+m + 1) + '.0';
+    else if (pr) {
+      debug('replaceTilde pr', pr);
+      if (pr.charAt(0) !== '-')
+        pr = '-' + pr;
+      ret = '>=' + M + '.' + m + '.' + p + pr +
+            ' <' + M + '.' + (+m + 1) + '.0';
+    } else
+      // ~1.2.3 == >=1.2.3 <1.3.0
+      ret = '>=' + M + '.' + m + '.' + p +
+            ' <' + M + '.' + (+m + 1) + '.0';
+
+    debug('tilde return', ret);
+    return ret;
+  });
+}
+
+// ^ --> * (any, kinda silly)
+// ^2, ^2.x, ^2.x.x --> >=2.0.0 <3.0.0
+// ^2.0, ^2.0.x --> >=2.0.0 <3.0.0
+// ^1.2, ^1.2.x --> >=1.2.0 <2.0.0
+// ^1.2.3 --> >=1.2.3 <2.0.0
+// ^1.2.0 --> >=1.2.0 <2.0.0
+function replaceCarets(comp, loose) {
+  return comp.trim().split(/\s+/).map(function(comp) {
+    return replaceCaret(comp, loose);
+  }).join(' ');
+}
+
+function replaceCaret(comp, loose) {
+  debug('caret', comp, loose);
+  var r = loose ? re[CARETLOOSE] : re[CARET];
+  return comp.replace(r, function(_, M, m, p, pr) {
+    debug('caret', comp, _, M, m, p, pr);
+    var ret;
+
+    if (isX(M))
+      ret = '';
+    else if (isX(m))
+      ret = '>=' + M + '.0.0 <' + (+M + 1) + '.0.0';
+    else if (isX(p)) {
+      if (M === '0')
+        ret = '>=' + M + '.' + m + '.0 <' + M + '.' + (+m + 1) + '.0';
+      else
+        ret = '>=' + M + '.' + m + '.0 <' + (+M + 1) + '.0.0';
+    } else if (pr) {
+      debug('replaceCaret pr', pr);
+      if (pr.charAt(0) !== '-')
+        pr = '-' + pr;
+      if (M === '0') {
+        if (m === '0')
+          ret = '>=' + M + '.' + m + '.' + p + pr +
+                ' <' + M + '.' + m + '.' + (+p + 1);
+        else
+          ret = '>=' + M + '.' + m + '.' + p + pr +
+                ' <' + M + '.' + (+m + 1) + '.0';
+      } else
+        ret = '>=' + M + '.' + m + '.' + p + pr +
+              ' <' + (+M + 1) + '.0.0';
+    } else {
+      debug('no pr');
+      if (M === '0') {
+        if (m === '0')
+          ret = '>=' + M + '.' + m + '.' + p +
+                ' <' + M + '.' + m + '.' + (+p + 1);
+        else
+          ret = '>=' + M + '.' + m + '.' + p +
+                ' <' + M + '.' + (+m + 1) + '.0';
+      } else
+        ret = '>=' + M + '.' + m + '.' + p +
+              ' <' + (+M + 1) + '.0.0';
+    }
+
+    debug('caret return', ret);
+    return ret;
+  });
+}
+
+function replaceXRanges(comp, loose) {
+  debug('replaceXRanges', comp, loose);
+  return comp.split(/\s+/).map(function(comp) {
+    return replaceXRange(comp, loose);
+  }).join(' ');
+}
+
+function replaceXRange(comp, loose) {
+  comp = comp.trim();
+  var r = loose ? re[XRANGELOOSE] : re[XRANGE];
+  return comp.replace(r, function(ret, gtlt, M, m, p, pr) {
+    debug('xRange', comp, ret, gtlt, M, m, p, pr);
+    var xM = isX(M);
+    var xm = xM || isX(m);
+    var xp = xm || isX(p);
+    var anyX = xp;
+
+    if (gtlt === '=' && anyX)
+      gtlt = '';
+
+    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 (xp)
+        p = 0;
+
+      if (gtlt === '>') {
+        // >1 => >=2.0.0
+        // >1.2 => >=1.3.0
+        // >1.2.3 => >= 1.2.4
+        gtlt = '>=';
+        if (xm) {
+          M = +M + 1;
+          m = 0;
+          p = 0;
+        } else if (xp) {
+          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) {
+      ret = '>=' + M + '.0.0 <' + (+M + 1) + '.0.0';
+    } else if (xp) {
+      ret = '>=' + M + '.' + m + '.0 <' + M + '.' + (+m + 1) + '.0';
+    }
+
+    debug('xRange return', ret);
+
+    return ret;
+  });
+}
+
+// Because * is AND-ed with everything else in the comparator,
+// and '' means "any version", just remove the *s entirely.
+function replaceStars(comp, loose) {
+  debug('replaceStars', comp, loose);
+  // Looseness is ignored here.  star is always as loose as it gets!
+  return comp.trim().replace(re[STAR], '');
+}
+
+// This function is passed to string.replace(re[HYPHENRANGE])
+// M, m, patch, prerelease, build
+// 1.2 - 3.4.5 => >=1.2.0 <=3.4.5
+// 1.2.3 - 3.4 => >=1.2.0 <3.5.0 Any 3.4.x will do
+// 1.2 - 3.4 => >=1.2.0 <3.5.0
+function hyphenReplace($0,
+                       from, fM, fm, fp, fpr, fb,
+                       to, tM, tm, tp, tpr, tb) {
+
+  if (isX(fM))
+    from = '';
+  else if (isX(fm))
+    from = '>=' + fM + '.0.0';
+  else if (isX(fp))
+    from = '>=' + fM + '.' + fm + '.0';
+  else
+    from = '>=' + from;
+
+  if (isX(tM))
+    to = '';
+  else if (isX(tm))
+    to = '<' + (+tM + 1) + '.0.0';
+  else if (isX(tp))
+    to = '<' + tM + '.' + (+tm + 1) + '.0';
+  else if (tpr)
+    to = '<=' + tM + '.' + tm + '.' + tp + '-' + tpr;
+  else
+    to = '<=' + to;
+
+  return (from + ' ' + to).trim();
+}
+
+
+// if ANY of the sets match ALL of its comparators, then pass
+Range.prototype.test = function(version) {
+  if (!version)
+    return false;
+
+  if (typeof version === 'string')
+    version = new SemVer(version, this.loose);
+
+  for (var i = 0; i < this.set.length; i++) {
+    if (testSet(this.set[i], version))
+      return true;
+  }
+  return false;
+};
+
+function testSet(set, version) {
+  for (var i = 0; i < set.length; i++) {
+    if (!set[i].test(version))
+      return false;
+  }
+
+  if (version.prerelease.length) {
+    // Find the set of versions that are allowed to have prereleases
+    // For example, ^1.2.3-pr.1 desugars to >=1.2.3-pr.1 <2.0.0
+    // That should allow `1.2.3-pr.2` to pass.
+    // However, `1.2.4-alpha.notready` should NOT be allowed,
+    // even though it's within the range set by the comparators.
+    for (var i = 0; i < set.length; i++) {
+      debug(set[i].semver);
+      if (set[i].semver === ANY)
+        continue;
+
+      if (set[i].semver.prerelease.length > 0) {
+        var allowed = set[i].semver;
+        if (allowed.major === version.major &&
+            allowed.minor === version.minor &&
+            allowed.patch === version.patch)
+          return true;
+      }
+    }
+
+    // Version has a -pre, but it's not one of the ones we like.
+    return false;
+  }
+
+  return true;
+}
+
+exports.satisfies = satisfies;
+function satisfies(version, range, loose) {
+  try {
+    range = new Range(range, loose);
+  } catch (er) {
+    return false;
+  }
+  return range.test(version);
+}
+
+exports.maxSatisfying = maxSatisfying;
+function maxSatisfying(versions, range, loose) {
+  return versions.filter(function(version) {
+    return satisfies(version, range, loose);
+  }).sort(function(a, b) {
+    return rcompare(a, b, loose);
+  })[0] || null;
+}
+
+exports.validRange = validRange;
+function validRange(range, loose) {
+  try {
+    // Return '*' instead of '' so that truthiness works.
+    // This will throw if it's invalid anyway
+    return new Range(range, loose).range || '*';
+  } catch (er) {
+    return null;
+  }
+}
+
+// Determine if version is less than all the versions possible in the range
+exports.ltr = ltr;
+function ltr(version, range, loose) {
+  return outside(version, range, '<', loose);
+}
+
+// Determine if version is greater than all the versions possible in the range.
+exports.gtr = gtr;
+function gtr(version, range, loose) {
+  return outside(version, range, '>', loose);
+}
+
+exports.outside = outside;
+function outside(version, range, hilo, loose) {
+  version = new SemVer(version, loose);
+  range = new Range(range, loose);
+
+  var gtfn, ltefn, ltfn, comp, ecomp;
+  switch (hilo) {
+    case '>':
+      gtfn = gt;
+      ltefn = lte;
+      ltfn = lt;
+      comp = '>';
+      ecomp = '>=';
+      break;
+    case '<':
+      gtfn = lt;
+      ltefn = gte;
+      ltfn = gt;
+      comp = '<';
+      ecomp = '<=';
+      break;
+    default:
+      throw new TypeError('Must provide a hilo val of "<" or ">"');
+  }
+
+  // If it satisifes the range it is not outside
+  if (satisfies(version, range, loose)) {
+    return false;
+  }
+
+  // From now on, variable terms are as if we're in "gtr" mode.
+  // but note that everything is flipped for the "ltr" function.
+
+  for (var i = 0; i < range.set.length; ++i) {
+    var comparators = range.set[i];
+
+    var high = null;
+    var low = null;
+
+    comparators.forEach(function(comparator) {
+      if (comparator.semver === ANY) {
+        comparator = new Comparator('>=0.0.0')
+      }
+      high = high || comparator;
+      low = low || comparator;
+      if (gtfn(comparator.semver, high.semver, loose)) {
+        high = comparator;
+      } else if (ltfn(comparator.semver, low.semver, loose)) {
+        low = comparator;
+      }
+    });
+
+    // If the edge version comparator has a operator then our version
+    // isn't outside it
+    if (high.operator === comp || high.operator === ecomp) {
+      return false;
+    }
+
+    // If the lowest version comparator has an operator and our version
+    // is less than it then it isn't higher than the range
+    if ((!low.operator || low.operator === comp) &&
+        ltefn(version, low.semver)) {
+      return false;
+    } else if (low.operator === ecomp && ltfn(version, low.semver)) {
+      return false;
+    }
+  }
+  return true;
+}
+
+// Use the define() function if we're in AMD land
+if (typeof define === 'function' && define.amd)
+  define(exports);
diff --git a/deps/npm/node_modules/node-gyp/node_modules/semver/test/big-numbers.js b/deps/npm/node_modules/node-gyp/node_modules/semver/test/big-numbers.js
new file mode 100644 (file)
index 0000000..c051864
--- /dev/null
@@ -0,0 +1,31 @@
+var test = require('tap').test
+var semver = require('../')
+
+test('long version is too long', function (t) {
+  var v = '1.2.' + new Array(256).join('1')
+  t.throws(function () {
+    new semver.SemVer(v)
+  })
+  t.equal(semver.valid(v, false), null)
+  t.equal(semver.valid(v, true), null)
+  t.equal(semver.inc(v, 'patch'), null)
+  t.end()
+})
+
+test('big number is like too long version', function (t) {
+  var v = '1.2.' + new Array(100).join('1')
+  t.throws(function () {
+    new semver.SemVer(v)
+  })
+  t.equal(semver.valid(v, false), null)
+  t.equal(semver.valid(v, true), null)
+  t.equal(semver.inc(v, 'patch'), null)
+  t.end()
+})
+
+test('parsing null does not throw', function (t) {
+  t.equal(semver.parse(null), null)
+  t.equal(semver.parse({}), null)
+  t.equal(semver.parse(new semver.SemVer('1.2.3')).version, '1.2.3')
+  t.end()
+})
diff --git a/deps/npm/node_modules/node-gyp/node_modules/semver/test/clean.js b/deps/npm/node_modules/node-gyp/node_modules/semver/test/clean.js
new file mode 100644 (file)
index 0000000..9e268de
--- /dev/null
@@ -0,0 +1,29 @@
+var tap = require('tap');
+var test = tap.test;
+var semver = require('../semver.js');
+var clean = semver.clean;
+
+test('\nclean tests', function(t) {
+       // [range, version]
+       // Version should be detectable despite extra characters
+       [
+               ['1.2.3', '1.2.3'],
+               [' 1.2.3 ', '1.2.3'],
+               [' 1.2.3-4 ', '1.2.3-4'],
+               [' 1.2.3-pre ', '1.2.3-pre'],
+               ['  =v1.2.3   ', '1.2.3'],
+               ['v1.2.3', '1.2.3'],
+               [' v1.2.3 ', '1.2.3'],
+               ['\t1.2.3', '1.2.3'],
+               ['>1.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];
+                       var msg = 'clean(' + range + ') = ' + version;
+                       t.equal(clean(range), version, msg);
+               });
+       t.end();
+});
diff --git a/deps/npm/node_modules/node-gyp/node_modules/semver/test/gtr.js b/deps/npm/node_modules/node-gyp/node_modules/semver/test/gtr.js
new file mode 100644 (file)
index 0000000..bbb8789
--- /dev/null
@@ -0,0 +1,173 @@
+var tap = require('tap');
+var test = tap.test;
+var semver = require('../semver.js');
+var gtr = semver.gtr;
+
+test('\ngtr tests', function(t) {
+  // [range, version, loose]
+  // Version should be greater than range
+  [
+    ['~1.2.2', '1.3.0'],
+    ['~0.6.1-1', '0.7.1-1'],
+    ['1.0.0 - 2.0.0', '2.0.1'],
+    ['1.0.0', '1.0.1-beta1'],
+    ['1.0.0', '2.0.0'],
+    ['<=2.0.0', '2.1.1'],
+    ['<=2.0.0', '3.2.9'],
+    ['<2.0.0', '2.0.0'],
+    ['0.1.20 || 1.2.4', '1.2.5'],
+    ['2.x.x', '3.0.0'],
+    ['1.2.x', '1.3.0'],
+    ['1.2.x || 2.x', '3.0.0'],
+    ['2.*.*', '5.0.1'],
+    ['1.2.*', '1.3.3'],
+    ['1.2.* || 2.*', '4.0.0'],
+    ['2', '3.0.0'],
+    ['2.3', '2.4.2'],
+    ['~2.4', '2.5.0'], // >=2.4.0 <2.5.0
+    ['~2.4', '2.5.5'],
+    ['~>3.2.1', '3.3.0'], // >=3.2.1 <3.3.0
+    ['~1', '2.2.3'], // >=1.0.0 <2.0.0
+    ['~>1', '2.2.4'],
+    ['~> 1', '3.2.3'],
+    ['~1.0', '1.1.2'], // >=1.0.0 <1.1.0
+    ['~ 1.0', '1.1.0'],
+    ['<1.2', '1.2.0'],
+    ['< 1.2', '1.2.1'],
+    ['1', '2.0.0beta', true],
+    ['~v0.5.4-pre', '0.6.0'],
+    ['~v0.5.4-pre', '0.6.1-pre'],
+    ['=0.7.x', '0.8.0'],
+    ['=0.7.x', '0.8.0-asdf'],
+    ['<0.7.x', '0.7.0'],
+    ['~1.2.2', '1.3.0'],
+    ['1.0.0 - 2.0.0', '2.2.3'],
+    ['1.0.0', '1.0.1'],
+    ['<=2.0.0', '3.0.0'],
+    ['<=2.0.0', '2.9999.9999'],
+    ['<=2.0.0', '2.2.9'],
+    ['<2.0.0', '2.9999.9999'],
+    ['<2.0.0', '2.2.9'],
+    ['2.x.x', '3.1.3'],
+    ['1.2.x', '1.3.3'],
+    ['1.2.x || 2.x', '3.1.3'],
+    ['2.*.*', '3.1.3'],
+    ['1.2.*', '1.3.3'],
+    ['1.2.* || 2.*', '3.1.3'],
+    ['2', '3.1.2'],
+    ['2.3', '2.4.1'],
+    ['~2.4', '2.5.0'], // >=2.4.0 <2.5.0
+    ['~>3.2.1', '3.3.2'], // >=3.2.1 <3.3.0
+    ['~1', '2.2.3'], // >=1.0.0 <2.0.0
+    ['~>1', '2.2.3'],
+    ['~1.0', '1.1.0'], // >=1.0.0 <1.1.0
+    ['<1', '1.0.0'],
+    ['1', '2.0.0beta', true],
+    ['<1', '1.0.0beta', true],
+    ['< 1', '1.0.0beta', true],
+    ['=0.7.x', '0.8.2'],
+    ['<0.7.x', '0.7.2']
+  ].forEach(function(tuple) {
+    var range = tuple[0];
+    var version = tuple[1];
+    var loose = tuple[2] || false;
+    var msg = 'gtr(' + version + ', ' + range + ', ' + loose + ')';
+    t.ok(gtr(version, range, loose), msg);
+  });
+  t.end();
+});
+
+test('\nnegative gtr tests', function(t) {
+  // [range, version, loose]
+  // Version should NOT be greater than range
+  [
+    ['~0.6.1-1', '0.6.1-1'],
+    ['1.0.0 - 2.0.0', '1.2.3'],
+    ['1.0.0 - 2.0.0', '0.9.9'],
+    ['1.0.0', '1.0.0'],
+    ['>=*', '0.2.4'],
+    ['', '1.0.0', true],
+    ['*', '1.2.3'],
+    ['*', 'v1.2.3-foo'],
+    ['>=1.0.0', '1.0.0'],
+    ['>=1.0.0', '1.0.1'],
+    ['>=1.0.0', '1.1.0'],
+    ['>1.0.0', '1.0.1'],
+    ['>1.0.0', '1.1.0'],
+    ['<=2.0.0', '2.0.0'],
+    ['<=2.0.0', '1.9999.9999'],
+    ['<=2.0.0', '0.2.9'],
+    ['<2.0.0', '1.9999.9999'],
+    ['<2.0.0', '0.2.9'],
+    ['>= 1.0.0', '1.0.0'],
+    ['>=  1.0.0', '1.0.1'],
+    ['>=   1.0.0', '1.1.0'],
+    ['> 1.0.0', '1.0.1'],
+    ['>  1.0.0', '1.1.0'],
+    ['<=   2.0.0', '2.0.0'],
+    ['<= 2.0.0', '1.9999.9999'],
+    ['<=  2.0.0', '0.2.9'],
+    ['<    2.0.0', '1.9999.9999'],
+    ['<\t2.0.0', '0.2.9'],
+    ['>=0.1.97', 'v0.1.97'],
+    ['>=0.1.97', '0.1.97'],
+    ['0.1.20 || 1.2.4', '1.2.4'],
+    ['0.1.20 || >1.2.4', '1.2.4'],
+    ['0.1.20 || 1.2.4', '1.2.3'],
+    ['0.1.20 || 1.2.4', '0.1.20'],
+    ['>=0.2.3 || <0.0.1', '0.0.0'],
+    ['>=0.2.3 || <0.0.1', '0.2.3'],
+    ['>=0.2.3 || <0.0.1', '0.2.4'],
+    ['||', '1.3.4'],
+    ['2.x.x', '2.1.3'],
+    ['1.2.x', '1.2.3'],
+    ['1.2.x || 2.x', '2.1.3'],
+    ['1.2.x || 2.x', '1.2.3'],
+    ['x', '1.2.3'],
+    ['2.*.*', '2.1.3'],
+    ['1.2.*', '1.2.3'],
+    ['1.2.* || 2.*', '2.1.3'],
+    ['1.2.* || 2.*', '1.2.3'],
+    ['1.2.* || 2.*', '1.2.3'],
+    ['*', '1.2.3'],
+    ['2', '2.1.2'],
+    ['2.3', '2.3.1'],
+    ['~2.4', '2.4.0'], // >=2.4.0 <2.5.0
+    ['~2.4', '2.4.5'],
+    ['~>3.2.1', '3.2.2'], // >=3.2.1 <3.3.0
+    ['~1', '1.2.3'], // >=1.0.0 <2.0.0
+    ['~>1', '1.2.3'],
+    ['~> 1', '1.2.3'],
+    ['~1.0', '1.0.2'], // >=1.0.0 <1.1.0
+    ['~ 1.0', '1.0.2'],
+    ['>=1', '1.0.0'],
+    ['>= 1', '1.0.0'],
+    ['<1.2', '1.1.1'],
+    ['< 1.2', '1.1.1'],
+    ['1', '1.0.0beta', true],
+    ['~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.0-asdf'],
+    ['>=0.7.x', '0.7.0-asdf'],
+    ['<=0.7.x', '0.6.2'],
+    ['>0.2.3 >0.2.4 <=0.2.5', '0.2.5'],
+    ['>=0.2.3 <=0.2.4', '0.2.4'],
+    ['1.0.0 - 2.0.0', '2.0.0'],
+    ['^1', '0.0.0-0'],
+    ['^3.0.0', '2.0.0'],
+    ['^1.0.0 || ~2.0.1', '2.0.0'],
+    ['^0.1.0 || ~3.0.1 || 5.0.0', '3.2.0'],
+    ['^0.1.0 || ~3.0.1 || 5.0.0', '1.0.0beta', true],
+    ['^0.1.0 || ~3.0.1 || 5.0.0', '5.0.0-0', true],
+    ['^0.1.0 || ~3.0.1 || >4 <=5.0.0', '3.5.0']
+  ].forEach(function(tuple) {
+    var range = tuple[0];
+    var version = tuple[1];
+    var loose = tuple[2] || false;
+    var msg = '!gtr(' + version + ', ' + range + ', ' + loose + ')';
+    t.notOk(gtr(version, range, loose), msg);
+  });
+  t.end();
+});
diff --git a/deps/npm/node_modules/node-gyp/node_modules/semver/test/index.js b/deps/npm/node_modules/node-gyp/node_modules/semver/test/index.js
new file mode 100644 (file)
index 0000000..c256c79
--- /dev/null
@@ -0,0 +1,685 @@
+'use strict';
+
+var tap = require('tap');
+var test = tap.test;
+var semver = require('../semver.js');
+var eq = semver.eq;
+var gt = semver.gt;
+var lt = semver.lt;
+var neq = semver.neq;
+var cmp = semver.cmp;
+var gte = semver.gte;
+var lte = semver.lte;
+var satisfies = semver.satisfies;
+var validRange = semver.validRange;
+var inc = semver.inc;
+var diff = semver.diff;
+var replaceStars = semver.replaceStars;
+var toComparators = semver.toComparators;
+var SemVer = semver.SemVer;
+var Range = semver.Range;
+
+test('\ncomparison tests', function(t) {
+  // [version1, version2]
+  // version1 should be greater than version2
+  [['0.0.0', '0.0.0-foo'],
+    ['0.0.1', '0.0.0'],
+    ['1.0.0', '0.9.9'],
+    ['0.10.0', '0.9.0'],
+    ['0.99.0', '0.10.0'],
+    ['2.0.0', '1.2.3'],
+    ['v0.0.0', '0.0.0-foo', true],
+    ['v0.0.1', '0.0.0', true],
+    ['v1.0.0', '0.9.9', true],
+    ['v0.10.0', '0.9.0', true],
+    ['v0.99.0', '0.10.0', true],
+    ['v2.0.0', '1.2.3', true],
+    ['0.0.0', 'v0.0.0-foo', true],
+    ['0.0.1', 'v0.0.0', true],
+    ['1.0.0', 'v0.9.9', true],
+    ['0.10.0', 'v0.9.0', true],
+    ['0.99.0', 'v0.10.0', true],
+    ['2.0.0', 'v1.2.3', true],
+    ['1.2.3', '1.2.3-asdf'],
+    ['1.2.3', '1.2.3-4'],
+    ['1.2.3', '1.2.3-4-foo'],
+    ['1.2.3-5-foo', '1.2.3-5'],
+    ['1.2.3-5', '1.2.3-4'],
+    ['1.2.3-5-foo', '1.2.3-5-Foo'],
+    ['3.0.0', '2.7.2+asdf'],
+    ['1.2.3-a.10', '1.2.3-a.5'],
+    ['1.2.3-a.b', '1.2.3-a.5'],
+    ['1.2.3-a.b', '1.2.3-a'],
+    ['1.2.3-a.b.c.10.d.5', '1.2.3-a.b.c.5.d.100'],
+    ['1.2.3-r2', '1.2.3-r100'],
+    ['1.2.3-r100', '1.2.3-R2']
+  ].forEach(function(v) {
+    var v0 = v[0];
+    var v1 = v[1];
+    var loose = v[2];
+    t.ok(gt(v0, v1, loose), "gt('" + v0 + "', '" + v1 + "')");
+    t.ok(lt(v1, v0, loose), "lt('" + v1 + "', '" + v0 + "')");
+    t.ok(!gt(v1, v0, loose), "!gt('" + v1 + "', '" + v0 + "')");
+    t.ok(!lt(v0, v1, loose), "!lt('" + v0 + "', '" + v1 + "')");
+    t.ok(eq(v0, v0, loose), "eq('" + v0 + "', '" + v0 + "')");
+    t.ok(eq(v1, v1, loose), "eq('" + v1 + "', '" + v1 + "')");
+    t.ok(neq(v0, v1, loose), "neq('" + v0 + "', '" + v1 + "')");
+    t.ok(cmp(v1, '==', v1, loose), "cmp('" + v1 + "' == '" + v1 + "')");
+    t.ok(cmp(v0, '>=', v1, loose), "cmp('" + v0 + "' >= '" + v1 + "')");
+    t.ok(cmp(v1, '<=', v0, loose), "cmp('" + v1 + "' <= '" + v0 + "')");
+    t.ok(cmp(v0, '!=', v1, loose), "cmp('" + v0 + "' != '" + v1 + "')");
+  });
+  t.end();
+});
+
+test('\nequality tests', function(t) {
+  // [version1, version2]
+  // version1 should be equivalent to version2
+  [['1.2.3', 'v1.2.3', true],
+    ['1.2.3', '=1.2.3', true],
+    ['1.2.3', 'v 1.2.3', true],
+    ['1.2.3', '= 1.2.3', true],
+    ['1.2.3', ' v1.2.3', true],
+    ['1.2.3', ' =1.2.3', true],
+    ['1.2.3', ' v 1.2.3', true],
+    ['1.2.3', ' = 1.2.3', true],
+    ['1.2.3-0', 'v1.2.3-0', true],
+    ['1.2.3-0', '=1.2.3-0', true],
+    ['1.2.3-0', 'v 1.2.3-0', true],
+    ['1.2.3-0', '= 1.2.3-0', true],
+    ['1.2.3-0', ' v1.2.3-0', true],
+    ['1.2.3-0', ' =1.2.3-0', true],
+    ['1.2.3-0', ' v 1.2.3-0', true],
+    ['1.2.3-0', ' = 1.2.3-0', true],
+    ['1.2.3-1', 'v1.2.3-1', true],
+    ['1.2.3-1', '=1.2.3-1', true],
+    ['1.2.3-1', 'v 1.2.3-1', true],
+    ['1.2.3-1', '= 1.2.3-1', true],
+    ['1.2.3-1', ' v1.2.3-1', true],
+    ['1.2.3-1', ' =1.2.3-1', true],
+    ['1.2.3-1', ' v 1.2.3-1', true],
+    ['1.2.3-1', ' = 1.2.3-1', true],
+    ['1.2.3-beta', 'v1.2.3-beta', true],
+    ['1.2.3-beta', '=1.2.3-beta', true],
+    ['1.2.3-beta', 'v 1.2.3-beta', true],
+    ['1.2.3-beta', '= 1.2.3-beta', true],
+    ['1.2.3-beta', ' v1.2.3-beta', true],
+    ['1.2.3-beta', ' =1.2.3-beta', true],
+    ['1.2.3-beta', ' v 1.2.3-beta', true],
+    ['1.2.3-beta', ' = 1.2.3-beta', true],
+    ['1.2.3-beta+build', ' = 1.2.3-beta+otherbuild', true],
+    ['1.2.3+build', ' = 1.2.3+otherbuild', true],
+    ['1.2.3-beta+build', '1.2.3-beta+otherbuild'],
+    ['1.2.3+build', '1.2.3+otherbuild'],
+    ['  v1.2.3+build', '1.2.3+otherbuild']
+  ].forEach(function(v) {
+    var v0 = v[0];
+    var v1 = v[1];
+    var loose = v[2];
+    t.ok(eq(v0, v1, loose), "eq('" + v0 + "', '" + v1 + "')");
+    t.ok(!neq(v0, v1, loose), "!neq('" + v0 + "', '" + v1 + "')");
+    t.ok(cmp(v0, '==', v1, loose), 'cmp(' + v0 + '==' + v1 + ')');
+    t.ok(!cmp(v0, '!=', v1, loose), '!cmp(' + v0 + '!=' + v1 + ')');
+    t.ok(!cmp(v0, '===', v1, loose), '!cmp(' + v0 + '===' + v1 + ')');
+    t.ok(cmp(v0, '!==', v1, loose), 'cmp(' + v0 + '!==' + v1 + ')');
+    t.ok(!gt(v0, v1, loose), "!gt('" + v0 + "', '" + v1 + "')");
+    t.ok(gte(v0, v1, loose), "gte('" + v0 + "', '" + v1 + "')");
+    t.ok(!lt(v0, v1, loose), "!lt('" + v0 + "', '" + v1 + "')");
+    t.ok(lte(v0, v1, loose), "lte('" + v0 + "', '" + v1 + "')");
+  });
+  t.end();
+});
+
+
+test('\nrange tests', function(t) {
+  // [range, version]
+  // version should be included by range
+  [['1.0.0 - 2.0.0', '1.2.3'],
+    ['^1.2.3+build', '1.2.3'],
+    ['^1.2.3+build', '1.3.0'],
+    ['1.2.3-pre+asdf - 2.4.3-pre+asdf', '1.2.3'],
+    ['1.2.3pre+asdf - 2.4.3-pre+asdf', '1.2.3', true],
+    ['1.2.3-pre+asdf - 2.4.3pre+asdf', '1.2.3', true],
+    ['1.2.3pre+asdf - 2.4.3pre+asdf', '1.2.3', true],
+    ['1.2.3-pre+asdf - 2.4.3-pre+asdf', '1.2.3-pre.2'],
+    ['1.2.3-pre+asdf - 2.4.3-pre+asdf', '2.4.3-alpha'],
+    ['1.2.3+asdf - 2.4.3+asdf', '1.2.3'],
+    ['1.0.0', '1.0.0'],
+    ['>=*', '0.2.4'],
+    ['', '1.0.0'],
+    ['*', '1.2.3'],
+    ['*', 'v1.2.3', true],
+    ['>=1.0.0', '1.0.0'],
+    ['>=1.0.0', '1.0.1'],
+    ['>=1.0.0', '1.1.0'],
+    ['>1.0.0', '1.0.1'],
+    ['>1.0.0', '1.1.0'],
+    ['<=2.0.0', '2.0.0'],
+    ['<=2.0.0', '1.9999.9999'],
+    ['<=2.0.0', '0.2.9'],
+    ['<2.0.0', '1.9999.9999'],
+    ['<2.0.0', '0.2.9'],
+    ['>= 1.0.0', '1.0.0'],
+    ['>=  1.0.0', '1.0.1'],
+    ['>=   1.0.0', '1.1.0'],
+    ['> 1.0.0', '1.0.1'],
+    ['>  1.0.0', '1.1.0'],
+    ['<=   2.0.0', '2.0.0'],
+    ['<= 2.0.0', '1.9999.9999'],
+    ['<=  2.0.0', '0.2.9'],
+    ['<    2.0.0', '1.9999.9999'],
+    ['<\t2.0.0', '0.2.9'],
+    ['>=0.1.97', 'v0.1.97', true],
+    ['>=0.1.97', '0.1.97'],
+    ['0.1.20 || 1.2.4', '1.2.4'],
+    ['>=0.2.3 || <0.0.1', '0.0.0'],
+    ['>=0.2.3 || <0.0.1', '0.2.3'],
+    ['>=0.2.3 || <0.0.1', '0.2.4'],
+    ['||', '1.3.4'],
+    ['2.x.x', '2.1.3'],
+    ['1.2.x', '1.2.3'],
+    ['1.2.x || 2.x', '2.1.3'],
+    ['1.2.x || 2.x', '1.2.3'],
+    ['x', '1.2.3'],
+    ['2.*.*', '2.1.3'],
+    ['1.2.*', '1.2.3'],
+    ['1.2.* || 2.*', '2.1.3'],
+    ['1.2.* || 2.*', '1.2.3'],
+    ['*', '1.2.3'],
+    ['2', '2.1.2'],
+    ['2.3', '2.3.1'],
+    ['~2.4', '2.4.0'], // >=2.4.0 <2.5.0
+    ['~2.4', '2.4.5'],
+    ['~>3.2.1', '3.2.2'], // >=3.2.1 <3.3.0,
+    ['~1', '1.2.3'], // >=1.0.0 <2.0.0
+    ['~>1', '1.2.3'],
+    ['~> 1', '1.2.3'],
+    ['~1.0', '1.0.2'], // >=1.0.0 <1.1.0,
+    ['~ 1.0', '1.0.2'],
+    ['~ 1.0.3', '1.0.12'],
+    ['>=1', '1.0.0'],
+    ['>= 1', '1.0.0'],
+    ['<1.2', '1.1.1'],
+    ['< 1.2', '1.1.1'],
+    ['~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'],
+    ['~1.2.1 =1.2.3', '1.2.3'],
+    ['~1.2.1 1.2.3', '1.2.3'],
+    ['~1.2.1 >=1.2.3 1.2.3', '1.2.3'],
+    ['~1.2.1 1.2.3 >=1.2.3', '1.2.3'],
+    ['~1.2.1 1.2.3', '1.2.3'],
+    ['>=1.2.1 1.2.3', '1.2.3'],
+    ['1.2.3 >=1.2.1', '1.2.3'],
+    ['>=1.2.3 >=1.2.1', '1.2.3'],
+    ['>=1.2.1 >=1.2.3', '1.2.3'],
+    ['>=1.2', '1.2.8'],
+    ['^1.2.3', '1.8.1'],
+    ['^0.1.2', '0.1.2'],
+    ['^0.1', '0.1.2'],
+    ['^1.2', '1.4.2'],
+    ['^1.2 ^1', '1.4.2'],
+    ['^1.2.3-alpha', '1.2.3-pre'],
+    ['^1.2.0-alpha', '1.2.0-pre'],
+    ['^0.0.1-alpha', '0.0.1-beta']
+  ].forEach(function(v) {
+    var range = v[0];
+    var ver = v[1];
+    var loose = v[2];
+    t.ok(satisfies(ver, range, loose), range + ' satisfied by ' + ver);
+  });
+  t.end();
+});
+
+test('\nnegative range tests', function(t) {
+  // [range, version]
+  // version should not be included by range
+  [['1.0.0 - 2.0.0', '2.2.3'],
+    ['1.2.3+asdf - 2.4.3+asdf', '1.2.3-pre.2'],
+    ['1.2.3+asdf - 2.4.3+asdf', '2.4.3-alpha'],
+    ['^1.2.3+build', '2.0.0'],
+    ['^1.2.3+build', '1.2.0'],
+    ['^1.2.3', '1.2.3-pre'],
+    ['^1.2', '1.2.0-pre'],
+    ['>1.2', '1.3.0-beta'],
+    ['<=1.2.3', '1.2.3-beta'],
+    ['^1.2.3', '1.2.3-beta'],
+    ['=0.7.x', '0.7.0-asdf'],
+    ['>=0.7.x', '0.7.0-asdf'],
+    ['1', '1.0.0beta', true],
+    ['<1', '1.0.0beta', true],
+    ['< 1', '1.0.0beta', true],
+    ['1.0.0', '1.0.1'],
+    ['>=1.0.0', '0.0.0'],
+    ['>=1.0.0', '0.0.1'],
+    ['>=1.0.0', '0.1.0'],
+    ['>1.0.0', '0.0.1'],
+    ['>1.0.0', '0.1.0'],
+    ['<=2.0.0', '3.0.0'],
+    ['<=2.0.0', '2.9999.9999'],
+    ['<=2.0.0', '2.2.9'],
+    ['<2.0.0', '2.9999.9999'],
+    ['<2.0.0', '2.2.9'],
+    ['>=0.1.97', 'v0.1.93', true],
+    ['>=0.1.97', '0.1.93'],
+    ['0.1.20 || 1.2.4', '1.2.3'],
+    ['>=0.2.3 || <0.0.1', '0.0.3'],
+    ['>=0.2.3 || <0.0.1', '0.2.2'],
+    ['2.x.x', '1.1.3'],
+    ['2.x.x', '3.1.3'],
+    ['1.2.x', '1.3.3'],
+    ['1.2.x || 2.x', '3.1.3'],
+    ['1.2.x || 2.x', '1.1.3'],
+    ['2.*.*', '1.1.3'],
+    ['2.*.*', '3.1.3'],
+    ['1.2.*', '1.3.3'],
+    ['1.2.* || 2.*', '3.1.3'],
+    ['1.2.* || 2.*', '1.1.3'],
+    ['2', '1.1.2'],
+    ['2.3', '2.4.1'],
+    ['~2.4', '2.5.0'], // >=2.4.0 <2.5.0
+    ['~2.4', '2.3.9'],
+    ['~>3.2.1', '3.3.2'], // >=3.2.1 <3.3.0
+    ['~>3.2.1', '3.2.0'], // >=3.2.1 <3.3.0
+    ['~1', '0.2.3'], // >=1.0.0 <2.0.0
+    ['~>1', '2.2.3'],
+    ['~1.0', '1.1.0'], // >=1.0.0 <1.1.0
+    ['<1', '1.0.0'],
+    ['>=1.2', '1.1.1'],
+    ['1', '2.0.0beta', true],
+    ['~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'],
+    ['<1.2.3', '1.2.3-beta'],
+    ['=1.2.3', '1.2.3-beta'],
+    ['>1.2', '1.2.8'],
+    ['^1.2.3', '2.0.0-alpha'],
+    ['^1.2.3', '1.2.2'],
+    ['^1.2', '1.1.9'],
+    ['*', 'v1.2.3-foo', true],
+    // invalid ranges never satisfied!
+    ['blerg', '1.2.3'],
+    ['git+https://user:password0123@github.com/foo', '123.0.0', true],
+    ['^1.2.3', '2.0.0-pre']
+  ].forEach(function(v) {
+    var range = v[0];
+    var ver = v[1];
+    var loose = v[2];
+    var found = satisfies(ver, range, loose);
+    t.ok(!found, ver + ' not satisfied by ' + range);
+  });
+  t.end();
+});
+
+test('\nincrement versions test', function(t) {
+//  [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'],
+    ['1.2.3tag', 'major', '2.0.0', true],
+    ['1.2.3-tag', 'major', '2.0.0'],
+    ['1.2.3', 'fake', null],
+    ['1.2.0-0', 'patch', '1.2.0'],
+    ['fake', 'major', null],
+    ['1.2.3-4', 'major', '2.0.0'],
+    ['1.2.3-4', 'minor', '1.3.0'],
+    ['1.2.3-4', 'patch', '1.2.3'],
+    ['1.2.3-alpha.0.beta', 'major', '2.0.0'],
+    ['1.2.3-alpha.0.beta', 'minor', '1.3.0'],
+    ['1.2.3-alpha.0.beta', 'patch', '1.2.3'],
+    ['1.2.4', 'prerelease', '1.2.5-0'],
+    ['1.2.3-0', 'prerelease', '1.2.3-1'],
+    ['1.2.3-alpha.0', 'prerelease', '1.2.3-alpha.1'],
+    ['1.2.3-alpha.1', 'prerelease', '1.2.3-alpha.2'],
+    ['1.2.3-alpha.2', 'prerelease', '1.2.3-alpha.3'],
+    ['1.2.3-alpha.0.beta', 'prerelease', '1.2.3-alpha.1.beta'],
+    ['1.2.3-alpha.1.beta', 'prerelease', '1.2.3-alpha.2.beta'],
+    ['1.2.3-alpha.2.beta', 'prerelease', '1.2.3-alpha.3.beta'],
+    ['1.2.3-alpha.10.0.beta', 'prerelease', '1.2.3-alpha.10.1.beta'],
+    ['1.2.3-alpha.10.1.beta', 'prerelease', '1.2.3-alpha.10.2.beta'],
+    ['1.2.3-alpha.10.2.beta', 'prerelease', '1.2.3-alpha.10.3.beta'],
+    ['1.2.3-alpha.10.beta.0', 'prerelease', '1.2.3-alpha.10.beta.1'],
+    ['1.2.3-alpha.10.beta.1', 'prerelease', '1.2.3-alpha.10.beta.2'],
+    ['1.2.3-alpha.10.beta.2', 'prerelease', '1.2.3-alpha.10.beta.3'],
+    ['1.2.3-alpha.9.beta', 'prerelease', '1.2.3-alpha.10.beta'],
+    ['1.2.3-alpha.10.beta', 'prerelease', '1.2.3-alpha.11.beta'],
+    ['1.2.3-alpha.11.beta', 'prerelease', '1.2.3-alpha.12.beta'],
+    ['1.2.0', 'prepatch', '1.2.1-0'],
+    ['1.2.0-1', 'prepatch', '1.2.1-0'],
+    ['1.2.0', 'preminor', '1.3.0-0'],
+    ['1.2.3-1', 'preminor', '1.3.0-0'],
+    ['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.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 id = v[4];
+    var found = inc(pre, what, loose, id);
+    var cmd = 'inc(' + pre + ', ' + what + ', ' + id + ')';
+    t.equal(found, wanted, cmd + ' === ' + wanted);
+  });
+
+  t.end();
+});
+
+test('\ndiff versions test', function(t) {
+//  [version1, version2, result]
+//  diff(version1, version2) -> result
+  [['1.2.3', '0.2.3', 'major'],
+    ['1.4.5', '0.2.3', 'major'],
+    ['1.2.3', '2.0.0-pre', 'premajor'],
+    ['1.2.3', '1.3.3', 'minor'],
+    ['1.0.1', '1.1.0-pre', 'preminor'],
+    ['1.2.3', '1.2.4', 'patch'],
+    ['1.2.3', '1.2.4-pre', 'prepatch'],
+    ['0.0.1', '0.0.1-pre', 'prerelease'],
+    ['0.0.1', '0.0.1-pre-2', 'prerelease'],
+    ['1.1.0', '1.1.0-pre', 'prerelease'],
+    ['1.1.0-pre-1', '1.1.0-pre-2', 'prerelease'],
+    ['1.0.0', '1.0.0', null]
+
+  ].forEach(function(v) {
+    var version1 = v[0];
+    var version2 = v[1];
+    var wanted = v[2];
+    var found = diff(version1, version2);
+    var cmd = 'diff(' + version1 + ', ' + version2 + ')';
+    t.equal(found, wanted, cmd + ' === ' + wanted);
+  });
+
+  t.end();
+});
+
+test('\nvalid range test', function(t) {
+  // [range, result]
+  // validRange(range) -> result
+  // translate ranges into their canonical form
+  [['1.0.0 - 2.0.0', '>=1.0.0 <=2.0.0'],
+    ['1.0.0', '1.0.0'],
+    ['>=*', '*'],
+    ['', '*'],
+    ['*', '*'],
+    ['*', '*'],
+    ['>=1.0.0', '>=1.0.0'],
+    ['>1.0.0', '>1.0.0'],
+    ['<=2.0.0', '<=2.0.0'],
+    ['1', '>=1.0.0 <2.0.0'],
+    ['<=2.0.0', '<=2.0.0'],
+    ['<=2.0.0', '<=2.0.0'],
+    ['<2.0.0', '<2.0.0'],
+    ['<2.0.0', '<2.0.0'],
+    ['>= 1.0.0', '>=1.0.0'],
+    ['>=  1.0.0', '>=1.0.0'],
+    ['>=   1.0.0', '>=1.0.0'],
+    ['> 1.0.0', '>1.0.0'],
+    ['>  1.0.0', '>1.0.0'],
+    ['<=   2.0.0', '<=2.0.0'],
+    ['<= 2.0.0', '<=2.0.0'],
+    ['<=  2.0.0', '<=2.0.0'],
+    ['<    2.0.0', '<2.0.0'],
+    ['<        2.0.0', '<2.0.0'],
+    ['>=0.1.97', '>=0.1.97'],
+    ['>=0.1.97', '>=0.1.97'],
+    ['0.1.20 || 1.2.4', '0.1.20||1.2.4'],
+    ['>=0.2.3 || <0.0.1', '>=0.2.3||<0.0.1'],
+    ['>=0.2.3 || <0.0.1', '>=0.2.3||<0.0.1'],
+    ['>=0.2.3 || <0.0.1', '>=0.2.3||<0.0.1'],
+    ['||', '||'],
+    ['2.x.x', '>=2.0.0 <3.0.0'],
+    ['1.2.x', '>=1.2.0 <1.3.0'],
+    ['1.2.x || 2.x', '>=1.2.0 <1.3.0||>=2.0.0 <3.0.0'],
+    ['1.2.x || 2.x', '>=1.2.0 <1.3.0||>=2.0.0 <3.0.0'],
+    ['x', '*'],
+    ['2.*.*', '>=2.0.0 <3.0.0'],
+    ['1.2.*', '>=1.2.0 <1.3.0'],
+    ['1.2.* || 2.*', '>=1.2.0 <1.3.0||>=2.0.0 <3.0.0'],
+    ['*', '*'],
+    ['2', '>=2.0.0 <3.0.0'],
+    ['2.3', '>=2.3.0 <2.4.0'],
+    ['~2.4', '>=2.4.0 <2.5.0'],
+    ['~2.4', '>=2.4.0 <2.5.0'],
+    ['~>3.2.1', '>=3.2.1 <3.3.0'],
+    ['~1', '>=1.0.0 <2.0.0'],
+    ['~>1', '>=1.0.0 <2.0.0'],
+    ['~> 1', '>=1.0.0 <2.0.0'],
+    ['~1.0', '>=1.0.0 <1.1.0'],
+    ['~ 1.0', '>=1.0.0 <1.1.0'],
+    ['^0', '>=0.0.0 <1.0.0'],
+    ['^ 1', '>=1.0.0 <2.0.0'],
+    ['^0.1', '>=0.1.0 <0.2.0'],
+    ['^1.0', '>=1.0.0 <2.0.0'],
+    ['^1.2', '>=1.2.0 <2.0.0'],
+    ['^0.0.1', '>=0.0.1 <0.0.2'],
+    ['^0.0.1-beta', '>=0.0.1-beta <0.0.2'],
+    ['^0.1.2', '>=0.1.2 <0.2.0'],
+    ['^1.2.3', '>=1.2.3 <2.0.0'],
+    ['^1.2.3-beta.4', '>=1.2.3-beta.4 <2.0.0'],
+    ['<1', '<1.0.0'],
+    ['< 1', '<1.0.0'],
+    ['>=1', '>=1.0.0'],
+    ['>= 1', '>=1.0.0'],
+    ['<1.2', '<1.2.0'],
+    ['< 1.2', '<1.2.0'],
+    ['1', '>=1.0.0 <2.0.0'],
+    ['>01.02.03', '>1.2.3', true],
+    ['>01.02.03', null],
+    ['~1.2.3beta', '>=1.2.3-beta <1.3.0', true],
+    ['~1.2.3beta', null],
+    ['^ 1.2 ^ 1', '>=1.2.0 <2.0.0 >=1.0.0 <2.0.0']
+  ].forEach(function(v) {
+    var pre = v[0];
+    var wanted = v[1];
+    var loose = v[2];
+    var found = validRange(pre, loose);
+
+    t.equal(found, wanted, 'validRange(' + pre + ') === ' + wanted);
+  });
+
+  t.end();
+});
+
+test('\ncomparators test', function(t) {
+  // [range, comparators]
+  // 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']]],
+    ['>=*', [['']]],
+    ['', [['']]],
+    ['*', [['']]],
+    ['*', [['']]],
+    ['>=1.0.0', [['>=1.0.0']]],
+    ['>=1.0.0', [['>=1.0.0']]],
+    ['>=1.0.0', [['>=1.0.0']]],
+    ['>1.0.0', [['>1.0.0']]],
+    ['>1.0.0', [['>1.0.0']]],
+    ['<=2.0.0', [['<=2.0.0']]],
+    ['1', [['>=1.0.0', '<2.0.0']]],
+    ['<=2.0.0', [['<=2.0.0']]],
+    ['<=2.0.0', [['<=2.0.0']]],
+    ['<2.0.0', [['<2.0.0']]],
+    ['<2.0.0', [['<2.0.0']]],
+    ['>= 1.0.0', [['>=1.0.0']]],
+    ['>=  1.0.0', [['>=1.0.0']]],
+    ['>=   1.0.0', [['>=1.0.0']]],
+    ['> 1.0.0', [['>1.0.0']]],
+    ['>  1.0.0', [['>1.0.0']]],
+    ['<=   2.0.0', [['<=2.0.0']]],
+    ['<= 2.0.0', [['<=2.0.0']]],
+    ['<=  2.0.0', [['<=2.0.0']]],
+    ['<    2.0.0', [['<2.0.0']]],
+    ['<\t2.0.0', [['<2.0.0']]],
+    ['>=0.1.97', [['>=0.1.97']]],
+    ['>=0.1.97', [['>=0.1.97']]],
+    ['0.1.20 || 1.2.4', [['0.1.20'], ['1.2.4']]],
+    ['>=0.2.3 || <0.0.1', [['>=0.2.3'], ['<0.0.1']]],
+    ['>=0.2.3 || <0.0.1', [['>=0.2.3'], ['<0.0.1']]],
+    ['>=0.2.3 || <0.0.1', [['>=0.2.3'], ['<0.0.1']]],
+    ['||', [[''], ['']]],
+    ['2.x.x', [['>=2.0.0', '<3.0.0']]],
+    ['1.2.x', [['>=1.2.0', '<1.3.0']]],
+    ['1.2.x || 2.x', [['>=1.2.0', '<1.3.0'], ['>=2.0.0', '<3.0.0']]],
+    ['1.2.x || 2.x', [['>=1.2.0', '<1.3.0'], ['>=2.0.0', '<3.0.0']]],
+    ['x', [['']]],
+    ['2.*.*', [['>=2.0.0', '<3.0.0']]],
+    ['1.2.*', [['>=1.2.0', '<1.3.0']]],
+    ['1.2.* || 2.*', [['>=1.2.0', '<1.3.0'], ['>=2.0.0', '<3.0.0']]],
+    ['1.2.* || 2.*', [['>=1.2.0', '<1.3.0'], ['>=2.0.0', '<3.0.0']]],
+    ['*', [['']]],
+    ['2', [['>=2.0.0', '<3.0.0']]],
+    ['2.3', [['>=2.3.0', '<2.4.0']]],
+    ['~2.4', [['>=2.4.0', '<2.5.0']]],
+    ['~2.4', [['>=2.4.0', '<2.5.0']]],
+    ['~>3.2.1', [['>=3.2.1', '<3.3.0']]],
+    ['~1', [['>=1.0.0', '<2.0.0']]],
+    ['~>1', [['>=1.0.0', '<2.0.0']]],
+    ['~> 1', [['>=1.0.0', '<2.0.0']]],
+    ['~1.0', [['>=1.0.0', '<1.1.0']]],
+    ['~ 1.0', [['>=1.0.0', '<1.1.0']]],
+    ['~ 1.0.3', [['>=1.0.3', '<1.1.0']]],
+    ['~> 1.0.3', [['>=1.0.3', '<1.1.0']]],
+    ['<1', [['<1.0.0']]],
+    ['< 1', [['<1.0.0']]],
+    ['>=1', [['>=1.0.0']]],
+    ['>= 1', [['>=1.0.0']]],
+    ['<1.2', [['<1.2.0']]],
+    ['< 1.2', [['<1.2.0']]],
+    ['1', [['>=1.0.0', '<2.0.0']]],
+    ['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']]],
+    ['>*', [['<0.0.0']]],
+    ['<*', [['<0.0.0']]]
+  ].forEach(function(v) {
+    var pre = v[0];
+    var wanted = v[1];
+    var found = toComparators(v[0]);
+    var jw = JSON.stringify(wanted);
+    t.equivalent(found, wanted, 'toComparators(' + pre + ') === ' + jw);
+  });
+
+  t.end();
+});
+
+test('\ninvalid version numbers', function(t) {
+  ['1.2.3.4',
+   'NOT VALID',
+   1.2,
+   null,
+   'Infinity.NaN.Infinity'
+  ].forEach(function(v) {
+    t.throws(function() {
+      new SemVer(v);
+    }, {name:'TypeError', message:'Invalid Version: ' + v});
+  });
+
+  t.end();
+});
+
+test('\nstrict vs loose version numbers', function(t) {
+  [['=1.2.3', '1.2.3'],
+    ['01.02.03', '1.2.3'],
+    ['1.2.3-beta.01', '1.2.3-beta.1'],
+    ['   =1.2.3', '1.2.3'],
+    ['1.2.3foo', '1.2.3-foo']
+  ].forEach(function(v) {
+    var loose = v[0];
+    var strict = v[1];
+    t.throws(function() {
+      new SemVer(loose);
+    });
+    var lv = new SemVer(loose, true);
+    t.equal(lv.version, strict);
+    t.ok(eq(loose, strict, true));
+    t.throws(function() {
+      eq(loose, strict);
+    });
+    t.throws(function() {
+      new SemVer(strict).compare(loose);
+    });
+  });
+  t.end();
+});
+
+test('\nstrict vs loose ranges', function(t) {
+  [['>=01.02.03', '>=1.2.3'],
+    ['~1.02.03beta', '>=1.2.3-beta <1.3.0']
+  ].forEach(function(v) {
+    var loose = v[0];
+    var comps = v[1];
+    t.throws(function() {
+      new Range(loose);
+    });
+    t.equal(new Range(loose, true).range, comps);
+  });
+  t.end();
+});
+
+test('\nmax satisfying', function(t) {
+  [[['1.2.3', '1.2.4'], '1.2', '1.2.4'],
+    [['1.2.4', '1.2.3'], '1.2', '1.2.4'],
+    [['1.2.3', '1.2.4', '1.2.5', '1.2.6'], '~1.2.3', '1.2.6'],
+    [['1.1.0', '1.2.0', '1.2.1', '1.3.0', '2.0.0b1', '2.0.0b2', '2.0.0b3', '2.0.0', '2.1.0'], '~2.0.0', '2.0.0', true]
+  ].forEach(function(v) {
+    var versions = v[0];
+    var range = v[1];
+    var expect = v[2];
+    var loose = v[3];
+    var actual = semver.maxSatisfying(versions, range, loose);
+    t.equal(actual, expect);
+  });
+  t.end();
+});
diff --git a/deps/npm/node_modules/node-gyp/node_modules/semver/test/ltr.js b/deps/npm/node_modules/node-gyp/node_modules/semver/test/ltr.js
new file mode 100644 (file)
index 0000000..0f7167d
--- /dev/null
@@ -0,0 +1,181 @@
+var tap = require('tap');
+var test = tap.test;
+var semver = require('../semver.js');
+var ltr = semver.ltr;
+
+test('\nltr tests', function(t) {
+  // [range, version, loose]
+  // Version should be less than range
+  [
+    ['~1.2.2', '1.2.1'],
+    ['~0.6.1-1', '0.6.1-0'],
+    ['1.0.0 - 2.0.0', '0.0.1'],
+    ['1.0.0-beta.2', '1.0.0-beta.1'],
+    ['1.0.0', '0.0.0'],
+    ['>=2.0.0', '1.1.1'],
+    ['>=2.0.0', '1.2.9'],
+    ['>2.0.0', '2.0.0'],
+    ['0.1.20 || 1.2.4', '0.1.5'],
+    ['2.x.x', '1.0.0'],
+    ['1.2.x', '1.1.0'],
+    ['1.2.x || 2.x', '1.0.0'],
+    ['2.*.*', '1.0.1'],
+    ['1.2.*', '1.1.3'],
+    ['1.2.* || 2.*', '1.1.9999'],
+    ['2', '1.0.0'],
+    ['2.3', '2.2.2'],
+    ['~2.4', '2.3.0'], // >=2.4.0 <2.5.0
+    ['~2.4', '2.3.5'],
+    ['~>3.2.1', '3.2.0'], // >=3.2.1 <3.3.0
+    ['~1', '0.2.3'], // >=1.0.0 <2.0.0
+    ['~>1', '0.2.4'],
+    ['~> 1', '0.2.3'],
+    ['~1.0', '0.1.2'], // >=1.0.0 <1.1.0
+    ['~ 1.0', '0.1.0'],
+    ['>1.2', '1.2.0'],
+    ['> 1.2', '1.2.1'],
+    ['1', '0.0.0beta', true],
+    ['~v0.5.4-pre', '0.5.4-alpha'],
+    ['~v0.5.4-pre', '0.5.4-alpha'],
+    ['=0.7.x', '0.6.0'],
+    ['=0.7.x', '0.6.0-asdf'],
+    ['>=0.7.x', '0.6.0'],
+    ['~1.2.2', '1.2.1'],
+    ['1.0.0 - 2.0.0', '0.2.3'],
+    ['1.0.0', '0.0.1'],
+    ['>=2.0.0', '1.0.0'],
+    ['>=2.0.0', '1.9999.9999'],
+    ['>=2.0.0', '1.2.9'],
+    ['>2.0.0', '2.0.0'],
+    ['>2.0.0', '1.2.9'],
+    ['2.x.x', '1.1.3'],
+    ['1.2.x', '1.1.3'],
+    ['1.2.x || 2.x', '1.1.3'],
+    ['2.*.*', '1.1.3'],
+    ['1.2.*', '1.1.3'],
+    ['1.2.* || 2.*', '1.1.3'],
+    ['2', '1.9999.9999'],
+    ['2.3', '2.2.1'],
+    ['~2.4', '2.3.0'], // >=2.4.0 <2.5.0
+    ['~>3.2.1', '2.3.2'], // >=3.2.1 <3.3.0
+    ['~1', '0.2.3'], // >=1.0.0 <2.0.0
+    ['~>1', '0.2.3'],
+    ['~1.0', '0.0.0'], // >=1.0.0 <1.1.0
+    ['>1', '1.0.0'],
+    ['2', '1.0.0beta', true],
+    ['>1', '1.0.0beta', true],
+    ['> 1', '1.0.0beta', true],
+    ['=0.7.x', '0.6.2'],
+    ['=0.7.x', '0.7.0-asdf'],
+    ['^1', '1.0.0-0'],
+    ['>=0.7.x', '0.7.0-asdf'],
+    ['1', '1.0.0beta', true],
+    ['>=0.7.x', '0.6.2'],
+    ['>1.2.3', '1.3.0-alpha']
+  ].forEach(function(tuple) {
+    var range = tuple[0];
+    var version = tuple[1];
+    var loose = tuple[2] || false;
+    var msg = 'ltr(' + version + ', ' + range + ', ' + loose + ')';
+    t.ok(ltr(version, range, loose), msg);
+  });
+  t.end();
+});
+
+test('\nnegative ltr tests', function(t) {
+  // [range, version, loose]
+  // Version should NOT be less than range
+  [
+    ['~ 1.0', '1.1.0'],
+    ['~0.6.1-1', '0.6.1-1'],
+    ['1.0.0 - 2.0.0', '1.2.3'],
+    ['1.0.0 - 2.0.0', '2.9.9'],
+    ['1.0.0', '1.0.0'],
+    ['>=*', '0.2.4'],
+    ['', '1.0.0', true],
+    ['*', '1.2.3'],
+    ['>=1.0.0', '1.0.0'],
+    ['>=1.0.0', '1.0.1'],
+    ['>=1.0.0', '1.1.0'],
+    ['>1.0.0', '1.0.1'],
+    ['>1.0.0', '1.1.0'],
+    ['<=2.0.0', '2.0.0'],
+    ['<=2.0.0', '1.9999.9999'],
+    ['<=2.0.0', '0.2.9'],
+    ['<2.0.0', '1.9999.9999'],
+    ['<2.0.0', '0.2.9'],
+    ['>= 1.0.0', '1.0.0'],
+    ['>=  1.0.0', '1.0.1'],
+    ['>=   1.0.0', '1.1.0'],
+    ['> 1.0.0', '1.0.1'],
+    ['>  1.0.0', '1.1.0'],
+    ['<=   2.0.0', '2.0.0'],
+    ['<= 2.0.0', '1.9999.9999'],
+    ['<=  2.0.0', '0.2.9'],
+    ['<    2.0.0', '1.9999.9999'],
+    ['<\t2.0.0', '0.2.9'],
+    ['>=0.1.97', 'v0.1.97'],
+    ['>=0.1.97', '0.1.97'],
+    ['0.1.20 || 1.2.4', '1.2.4'],
+    ['0.1.20 || >1.2.4', '1.2.4'],
+    ['0.1.20 || 1.2.4', '1.2.3'],
+    ['0.1.20 || 1.2.4', '0.1.20'],
+    ['>=0.2.3 || <0.0.1', '0.0.0'],
+    ['>=0.2.3 || <0.0.1', '0.2.3'],
+    ['>=0.2.3 || <0.0.1', '0.2.4'],
+    ['||', '1.3.4'],
+    ['2.x.x', '2.1.3'],
+    ['1.2.x', '1.2.3'],
+    ['1.2.x || 2.x', '2.1.3'],
+    ['1.2.x || 2.x', '1.2.3'],
+    ['x', '1.2.3'],
+    ['2.*.*', '2.1.3'],
+    ['1.2.*', '1.2.3'],
+    ['1.2.* || 2.*', '2.1.3'],
+    ['1.2.* || 2.*', '1.2.3'],
+    ['1.2.* || 2.*', '1.2.3'],
+    ['*', '1.2.3'],
+    ['2', '2.1.2'],
+    ['2.3', '2.3.1'],
+    ['~2.4', '2.4.0'], // >=2.4.0 <2.5.0
+    ['~2.4', '2.4.5'],
+    ['~>3.2.1', '3.2.2'], // >=3.2.1 <3.3.0
+    ['~1', '1.2.3'], // >=1.0.0 <2.0.0
+    ['~>1', '1.2.3'],
+    ['~> 1', '1.2.3'],
+    ['~1.0', '1.0.2'], // >=1.0.0 <1.1.0
+    ['~ 1.0', '1.0.2'],
+    ['>=1', '1.0.0'],
+    ['>= 1', '1.0.0'],
+    ['<1.2', '1.1.1'],
+    ['< 1.2', '1.1.1'],
+    ['~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.6.2'],
+    ['>0.2.3 >0.2.4 <=0.2.5', '0.2.5'],
+    ['>=0.2.3 <=0.2.4', '0.2.4'],
+    ['1.0.0 - 2.0.0', '2.0.0'],
+    ['^3.0.0', '4.0.0'],
+    ['^1.0.0 || ~2.0.1', '2.0.0'],
+    ['^0.1.0 || ~3.0.1 || 5.0.0', '3.2.0'],
+    ['^0.1.0 || ~3.0.1 || 5.0.0', '1.0.0beta', true],
+    ['^0.1.0 || ~3.0.1 || 5.0.0', '5.0.0-0', true],
+    ['^0.1.0 || ~3.0.1 || >4 <=5.0.0', '3.5.0'],
+    ['^1.0.0alpha', '1.0.0beta', true],
+    ['~1.0.0alpha', '1.0.0beta', true],
+    ['^1.0.0-alpha', '1.0.0beta', true],
+    ['~1.0.0-alpha', '1.0.0beta', true],
+    ['^1.0.0-alpha', '1.0.0-beta'],
+    ['~1.0.0-alpha', '1.0.0-beta'],
+    ['=0.1.0', '1.0.0']
+  ].forEach(function(tuple) {
+    var range = tuple[0];
+    var version = tuple[1];
+    var loose = tuple[2] || false;
+    var msg = '!ltr(' + version + ', ' + range + ', ' + loose + ')';
+    t.notOk(ltr(version, range, loose), msg);
+  });
+  t.end();
+});
diff --git a/deps/npm/node_modules/node-gyp/node_modules/semver/test/major-minor-patch.js b/deps/npm/node_modules/node-gyp/node_modules/semver/test/major-minor-patch.js
new file mode 100644 (file)
index 0000000..e9d4039
--- /dev/null
@@ -0,0 +1,72 @@
+var tap = require('tap');
+var test = tap.test;
+var semver = require('../semver.js');
+
+test('\nmajor tests', function(t) {
+  // [range, version]
+  // Version should be detectable despite extra characters
+  [
+    ['1.2.3', 1],
+    [' 1.2.3 ', 1],
+    [' 2.2.3-4 ', 2],
+    [' 3.2.3-pre ', 3],
+    ['v5.2.3', 5],
+    [' v8.2.3 ', 8],
+    ['\t13.2.3', 13],
+    ['=21.2.3', 21, true],
+    ['v=34.2.3', 34, true]
+  ].forEach(function(tuple) {
+    var range = tuple[0];
+    var version = tuple[1];
+    var loose = tuple[2] || false;
+    var msg = 'major(' + range + ') = ' + version;
+    t.equal(semver.major(range, loose), version, msg);
+  });
+  t.end();
+});
+
+test('\nminor tests', function(t) {
+  // [range, version]
+  // Version should be detectable despite extra characters
+  [
+    ['1.1.3', 1],
+    [' 1.1.3 ', 1],
+    [' 1.2.3-4 ', 2],
+    [' 1.3.3-pre ', 3],
+    ['v1.5.3', 5],
+    [' v1.8.3 ', 8],
+    ['\t1.13.3', 13],
+    ['=1.21.3', 21, true],
+    ['v=1.34.3', 34, true]
+  ].forEach(function(tuple) {
+    var range = tuple[0];
+    var version = tuple[1];
+    var loose = tuple[2] || false;
+    var msg = 'minor(' + range + ') = ' + version;
+    t.equal(semver.minor(range, loose), version, msg);
+  });
+  t.end();
+});
+
+test('\npatch tests', function(t) {
+  // [range, version]
+  // Version should be detectable despite extra characters
+  [
+    ['1.2.1', 1],
+    [' 1.2.1 ', 1],
+    [' 1.2.2-4 ', 2],
+    [' 1.2.3-pre ', 3],
+    ['v1.2.5', 5],
+    [' v1.2.8 ', 8],
+    ['\t1.2.13', 13],
+    ['=1.2.21', 21, true],
+    ['v=1.2.34', 34, true]
+  ].forEach(function(tuple) {
+    var range = tuple[0];
+    var version = tuple[1];
+    var loose = tuple[2] || false;
+    var msg = 'patch(' + range + ') = ' + version;
+    t.equal(semver.patch(range, loose), version, msg);
+  });
+  t.end();
+});
index f81f30f..0ea7c54 100644 (file)
@@ -1,6 +1,6 @@
 {
   "name": "normalize-package-data",
-  "version": "2.3.0",
+  "version": "2.3.1",
   "author": {
     "name": "Meryn Stol",
     "email": "merynstol@gmail.com"
@@ -17,7 +17,7 @@
   },
   "dependencies": {
     "hosted-git-info": "^2.0.2",
-    "semver": "2 || 3 || 4",
+    "semver": "2 || 3 || 4 || 5",
     "validate-npm-package-license": "^2.0.0"
   },
   "devDependencies": {
   ],
   "readme": "# normalize-package-data [![Build Status](https://travis-ci.org/npm/normalize-package-data.png?branch=master)](https://travis-ci.org/npm/normalize-package-data)\n\nnormalize-package data exports a function that normalizes package metadata. This data is typically found in a package.json file, but in principle could come from any source - for example the npm registry.\n\nnormalize-package-data is used by [read-package-json](https://npmjs.org/package/read-package-json) to normalize the data it reads from a package.json file. In turn, read-package-json is used by [npm](https://npmjs.org/package/npm) and various npm-related tools.\n\n## Installation\n\n```\nnpm install normalize-package-data\n```\n\n## Usage\n\nBasic usage is really simple. You call the function that normalize-package-data exports. Let's call it `normalizeData`.\n\n```javascript\nnormalizeData = require('normalize-package-data')\npackageData = fs.readFileSync(\"package.json\")\nnormalizeData(packageData)\n// packageData is now normalized\n```\n\n#### Strict mode\n\nYou may activate strict validation by passing true as the second argument.\n\n```javascript\nnormalizeData = require('normalize-package-data')\npackageData = fs.readFileSync(\"package.json\")\nwarnFn = function(msg) { console.error(msg) }\nnormalizeData(packageData, true)\n// packageData is now normalized\n```\n\nIf strict mode is activated, only Semver 2.0 version strings are accepted. Otherwise, Semver 1.0 strings are accepted as well. Packages must have a name, and the name field must not have contain leading or trailing whitespace.\n\n#### Warnings\n\nOptionally, you may pass a \"warning\" function. It gets called whenever the `normalizeData` function encounters something that doesn't look right. It indicates less than perfect input data.\n\n```javascript\nnormalizeData = require('normalize-package-data')\npackageData = fs.readFileSync(\"package.json\")\nwarnFn = function(msg) { console.error(msg) }\nnormalizeData(packageData, warnFn)\n// packageData is now normalized. Any number of warnings may have been logged.\n```\n\nYou may combine strict validation with warnings by passing `true` as the second argument, and `warnFn` as third.\n\nWhen `private` field is set to `true`, warnings will be suppressed.\n\n### Potential exceptions\n\nIf the supplied data has an invalid name or version vield, `normalizeData` will throw an error. Depending on where you call `normalizeData`, you may want to catch these errors so can pass them to a callback.\n\n## What normalization (currently) entails\n\n* The value of `name` field gets trimmed (unless in strict mode).\n* The value of the `version` field gets cleaned by `semver.clean`. See [documentation for the semver module](https://github.com/isaacs/node-semver).\n* If `name` and/or `version` fields are missing, they are set to empty strings.\n* If `files` field is not an array, it will be removed.\n* If `bin` field is a string, then `bin` field will become an object with `name` set to the value of the `name` field, and `bin` set to the original string value.\n* If `man` field is a string, it will become an array with the original string as its sole member.\n* If `keywords` field is string, it is considered to be a list of keywords separated by one or more white-space characters. It gets converted to an array by splitting on `\\s+`.\n* All people fields (`author`, `maintainers`, `contributors`) get converted into objects with name, email and url properties.\n* If `bundledDependencies` field (a typo) exists and `bundleDependencies` field does not, `bundledDependencies` will get renamed to `bundleDependencies`.\n* If the value of any of the dependencies fields  (`dependencies`, `devDependencies`, `optionalDependencies`) is a string, it gets converted into an object with familiar `name=>value` pairs.\n* The values in `optionalDependencies` get added to `dependencies`. The `optionalDependencies` array is left untouched.\n* As of v2: Dependencies that point at known hosted git providers (currently: github, bitbucket, gitlab) will have their URLs canonicalized, but protocols will be preserved.\n* As of v2: Dependencies that use shortcuts for hosted git providers (`org/proj`, `github:org/proj`, `bitbucket:org/proj`, `gitlab:org/proj`, `gist:docid`) will have the shortcut left in place. (In the case of github, the `org/proj` form will be expanded to `github:org/proj`.) THIS MARKS A BREAKING CHANGE FROM V1, where the shorcut was previously expanded to a URL.\n* If `description` field does not exist, but `readme` field does, then (more or less) the first paragraph of text that's found in the readme is taken as value for `description`.\n* If `repository` field is a string, it will become an object with `url` set to the original string value, and `type` set to `\"git\"`.\n* If `repository.url` is not a valid url, but in the style of \"[owner-name]/[repo-name]\", `repository.url` will be set to https://github.com/[owner-name]/[repo-name]\n* If `bugs` field is a string, the value of `bugs` field is changed into an object with `url` set to the original string value.\n* If `bugs` field does not exist, but `repository` field points to a repository hosted on GitHub, the value of the `bugs` field gets set to an url in the form of https://github.com/[owner-name]/[repo-name]/issues . If the repository field points to a GitHub Gist repo url, the associated http url is chosen.\n* If `bugs` field is an object, the resulting value only has email and url properties. If email and url properties are not strings, they are ignored. If no valid values for either email or url is found, bugs field will be removed.\n* If `homepage` field is not a string, it will be removed.\n* If the url in the `homepage` field does not specify a protocol, then http is assumed. For example, `myproject.org` will be changed to `http://myproject.org`.\n* If `homepage` field does not exist, but `repository` field points to a repository hosted on GitHub, the value of the `homepage` field gets set to an url in the form of https://github.com/[owner-name]/[repo-name]/ . If the repository field points to a GitHub Gist repo url, the associated http url is chosen.\n\n### Rules for name field\n\nIf `name` field is given, the value of the name field must be a string. The string may not:\n\n* start with a period.\n* contain the following characters: `/@\\s+%`\n* contain and characters that would need to be encoded for use in urls.\n* resemble the word `node_modules` or `favicon.ico` (case doesn't matter).\n\n### Rules for version field\n\nIf `version` field is given, the value of the version field must be a valid *semver* string, as determined by the `semver.valid` method. See [documentation for the semver module](https://github.com/isaacs/node-semver).\n\n### Rules for license field\n\nThe `license` field should be a valid *SDPDX license expression* or one of the special values allowed by [validate-npm-package-license](https://npmjs.com/packages/validate-npm-package-license). See [documentation for the license field in package.json](https://docs.npmjs.com/files/package.json#license).\n\n## Credits\n\nThis package contains code based on read-package-json written by Isaac Z. Schlueter. Used with permisson.\n\n## License\n\nnormalize-package-data is released under the [BSD 2-Clause License](http://opensource.org/licenses/MIT).  \nCopyright (c) 2013 Meryn Stol  \n",
   "readmeFilename": "README.md",
-  "gitHead": "2b006a6d53490fc053ba5ee727d36fbb4ff64868",
+  "gitHead": "43b844bd37aac28d204be7567b731d9c55025871",
   "bugs": {
     "url": "https://github.com/npm/normalize-package-data/issues"
   },
   "homepage": "https://github.com/npm/normalize-package-data#readme",
-  "_id": "normalize-package-data@2.3.0",
-  "_shasum": "5a81b77a6bc2edcea5fceb380d3e34ae28059f51",
-  "_from": "normalize-package-data@>=2.3.0 <2.4.0"
+  "_id": "normalize-package-data@2.3.1",
+  "_shasum": "e2d24a5ab38a90b22cd697753407d8564f49a890",
+  "_from": "normalize-package-data@>=2.3.1 <2.4.0"
 }
index cc9f206..3e7203c 100644 (file)
@@ -1,16 +1,16 @@
 {
   "name": "npm-install-checks",
-  "version": "1.0.5",
+  "version": "1.0.6",
   "description": "checks that npm runs during the installation of a module",
   "main": "index.js",
   "dependencies": {
     "npmlog": "0.1 || 1",
-    "semver": "^2.3.0 || 3.x || 4"
+    "semver": "^2.3.0 || 3.x || 4 || 5"
   },
   "devDependencies": {
-    "tap": "~0.4.8",
+    "mkdirp": "~0.3.5",
     "rimraf": "~2.2.5",
-    "mkdirp": "~0.3.5"
+    "tap": "^1.2.0"
   },
   "scripts": {
     "test": "tap test/*.js"
   "bugs": {
     "url": "https://github.com/npm/npm-install-checks/issues"
   },
-  "gitHead": "c36e052a0a54ad82932689fa86fd59197277f80d",
-  "_id": "npm-install-checks@1.0.5",
-  "_shasum": "a1b5beabfd60e0535b14f763157c410cb6bdae56",
-  "_from": "npm-install-checks@>=1.0.5 <1.1.0",
-  "_npmVersion": "2.1.11",
-  "_nodeVersion": "0.10.33",
-  "_npmUser": {
-    "name": "iarna",
-    "email": "me@re-becca.org"
-  },
-  "maintainers": [
-    {
-      "name": "robertkowalski",
-      "email": "rok@kowalski.gd"
-    },
-    {
-      "name": "isaacs",
-      "email": "i@izs.me"
-    },
-    {
-      "name": "iarna",
-      "email": "me@re-becca.org"
-    }
-  ],
-  "dist": {
-    "shasum": "a1b5beabfd60e0535b14f763157c410cb6bdae56",
-    "tarball": "http://registry.npmjs.org/npm-install-checks/-/npm-install-checks-1.0.5.tgz"
-  },
-  "directories": {},
-  "_resolved": "https://registry.npmjs.org/npm-install-checks/-/npm-install-checks-1.0.5.tgz"
+  "readme": "# npm-install-checks\n\nA package that contains checks that npm runs during the installation.\n\n## API\n\n### .checkEngine(target, npmVer, nodeVer, force, strict, cb)\nCheck if node/npm version is supported by the package.\n\nError type: `ENOTSUP`\n\n### .checkPlatform(target, force, cb)\nCheck if OS/Arch is supported by the package.\n\nError type: `EBADPLATFORM`\n\n### .checkCycle(target, ancestors, cb)\nCheck for cyclic dependencies.\n\nError type: `ECYCLE`\n\n### .checkGit(folder, cb)\nCheck if a folder is a .git folder.\n\nError type: `EISGIT`\n",
+  "readmeFilename": "README.md",
+  "gitHead": "f28aebca7f5df0ddb13161b0f04d069004f6c367",
+  "_id": "npm-install-checks@1.0.6",
+  "_shasum": "8d4c1e852806e4e2d66601ab787be5841550d0cb",
+  "_from": "npm-install-checks@>=1.0.6 <1.1.0"
 }
index 0be06bb..9caed85 100644 (file)
@@ -1,6 +1,6 @@
 {
   "name": "npm-package-arg",
-  "version": "4.0.1",
+  "version": "4.0.2",
   "description": "Parse the things that can be arguments to `npm install`",
   "main": "npa.js",
   "directories": {
@@ -8,10 +8,10 @@
   },
   "dependencies": {
     "hosted-git-info": "^2.1.4",
-    "semver": "4"
+    "semver": "4 || 5"
   },
   "devDependencies": {
-    "tap": "^0.4.9"
+    "tap": "^1.2.0"
   },
   "scripts": {
     "test": "tap test/*.js"
@@ -32,8 +32,8 @@
   "homepage": "https://github.com/npm/npm-package-arg",
   "readme": "# npm-package-arg\n\nParse package name and specifier passed to commands like `npm install` or\n`npm cache add`.  This just parses the text given-- it's worth noting that\n`npm` has further logic it applies by looking at your disk to figure out\nwhat ambiguous specifiers are.  If you want that logic, please see\n[realize-package-specifier].\n\n[realize-package-specifier]: https://www.npmjs.org/package/realize-package-specifier\n\nArguments look like: `foo@1.2`, `@bar/foo@1.2`, `foo@user/foo`, `http://x.com/foo.tgz`,\n`git+https://github.com/user/foo`, `bitbucket:user/foo`, `foo.tar.gz` or `bar`\n\n## EXAMPLES\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(\"@bar/foo@1.2\")\n\n// Returns an object like:\n{\n  raw: '@bar/foo@1.2',   // what was passed in\n  name: \"@bar/foo\",      // the name of the package\n  scope: \"@bar\",         // the private scope of the package, or null\n  type: \"range\",         // the type of specifier this is\n  spec: \">=1.2.0 <1.3.0\" // the expanded specifier\n  rawSpec: \"1.2\"         // the specifier as passed in\n }\n\n// Parsing urls pointing at hosted git services produces a variation:\nvar parsed = npa(\"git+https://github.com/user/foo\")\n\n// Returns an object like:\n{\n  raw: 'git+https://github.com/user/foo',\n  scope: null,\n  name: null,\n  rawSpec: 'git+https://github.com/user/foo',\n  spec: 'user/foo',\n  type: 'hosted',\n  hosted: {\n    type: 'github',\n    ssh: 'git@github.com:user/foo.git',\n    sshurl: 'git+ssh://git@github.com/user/foo.git',\n    https: 'https://github.com/user/foo.git',\n    directUrl: 'https://raw.githubusercontent.com/user/foo/master/package.json'\n  }\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\n## USING\n\n`var npa = require('npm-package-arg')`\n\n* var result = npa(*arg*)\n\nParses *arg* and returns a result object detailing what *arg* is.\n\n*arg* -- a package descriptor, like: `foo@1.2`, or `foo@user/foo`, or\n`http://x.com/foo.tgz`, or `git+https://github.com/user/foo`\n\n## RESULT OBJECT\n\nThe objects that are returned by npm-package-arg contain the following\nkeys:\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  * `hosted` - A hosted project, from github, bitbucket or gitlab. Originally\n    either a full url pointing at one of these services or a shorthand like\n    `user/project` or `github:user/project` for github or `bitbucket:user/project`\n    for bitbucket.\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* `hosted` - If type=hosted this will be an object with the following keys:\n  * `type` - github, bitbucket or gitlab\n  * `ssh` - The ssh path for this git repo\n  * `sshUrl` - The ssh URL for this git repo\n  * `httpsUrl` - The HTTPS URL for this git repo\n  * `directUrl` - The URL for the package.json in this git repo\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": "794c9981033bb16bd4a88c7ba45c109107439172",
-  "_id": "npm-package-arg@4.0.1",
-  "_shasum": "bfbea17cd2b9fdc4fca2f02796794173dbf1877c",
-  "_from": "npm-package-arg@>=4.0.0 <4.1.0"
+  "gitHead": "8d3c51c33807fabde4db86a3811831b756eaf2eb",
+  "_id": "npm-package-arg@4.0.2",
+  "_shasum": "3f28235f9f6428e54bfeca73629e27d6c81a7e82",
+  "_from": "npm-package-arg@>=4.0.2 <4.1.0"
 }
index 8070e03..eef3d82 100644 (file)
@@ -30,9 +30,12 @@ if (!EE.listenerCount) EE.listenerCount = function(emitter, type) {
 
 /*<replacement>*/
 var Stream;
- (function (){try{
-Stream = require('st' + 'ream');
-}catch(_){Stream = require('events').EventEmitter;}}())
+(function (){try{
+  Stream = require('st' + 'ream');
+}catch(_){}finally{
+  if (!Stream)
+    Stream = require('events').EventEmitter;
+}}())
 /*</replacement>*/
 
 var Buffer = require('buffer').Buffer;
index 41b866d..b232952 100644 (file)
@@ -27,9 +27,12 @@ util.inherits = require('inherits');
 
 /*<replacement>*/
 var Stream;
- (function (){try{
-Stream = require('st' + 'ream');
-}catch(_){Stream = require('events').EventEmitter;}}())
+(function (){try{
+  Stream = require('st' + 'ream');
+}catch(_){}finally{
+  if (!Stream)
+    Stream = require('events').EventEmitter;
+}}())
 /*</replacement>*/
 
 var Buffer = require('buffer').Buffer;
index 89ff535..b673333 100644 (file)
@@ -29,8 +29,9 @@
   },
   "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",
+  "homepage": "https://github.com/isaacs/core-util-is#readme",
   "_id": "core-util-is@1.0.1",
-  "_from": "core-util-is@>=1.0.0 <1.1.0",
-  "scripts": {}
+  "_shasum": "6b07085aef9a3ccac6ee53bf9d3df0c1521a5538",
+  "_resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.1.tgz",
+  "_from": "core-util-is@>=1.0.0 <1.1.0"
 }
index 25c8581..fb1eb37 100644 (file)
     "url": "http://juliangruber.com"
   },
   "license": "MIT",
-  "_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",
   "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 &lt;julian@juliangruber.com&gt;\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",
   "bugs": {
     "url": "https://github.com/juliangruber/isarray/issues"
-  }
+  },
+  "_id": "isarray@0.0.1",
+  "_shasum": "8a18acfca9a8f4177e09abfc6038939b05d1eedf",
+  "_resolved": "https://registry.npmjs.org/isarray/-/isarray-0.0.1.tgz",
+  "_from": "isarray@0.0.1"
 }
index 02e4a2c..9be9ed5 100644 (file)
@@ -1,6 +1,6 @@
 {
   "name": "process-nextick-args",
-  "version": "1.0.1",
+  "version": "1.0.2",
   "description": "process.nextTick but always with args",
   "main": "index.js",
   "scripts": {
   "devDependencies": {
     "tap": "~0.2.6"
   },
-  "gitHead": "b7c95b21096503e76a1b7f4f60920d32d8378eeb",
-  "_id": "process-nextick-args@1.0.1",
-  "_shasum": "918a5ab4a7744340b83ff416101ba53c5c531879",
+  "gitHead": "295707643b4ed6667c1afb71ffb6101669b5dac2",
+  "_id": "process-nextick-args@1.0.2",
+  "_shasum": "8b4d3fc586668bd5b6573e732edf2b71c1c1d8aa",
   "_from": "process-nextick-args@>=1.0.0 <1.1.0",
-  "_npmVersion": "2.0.0",
+  "_npmVersion": "2.11.1",
+  "_nodeVersion": "2.3.0",
   "_npmUser": {
     "name": "cwmma",
     "email": "calvin.metcalf@gmail.com"
   },
+  "dist": {
+    "shasum": "8b4d3fc586668bd5b6573e732edf2b71c1c1d8aa",
+    "tarball": "http://registry.npmjs.org/process-nextick-args/-/process-nextick-args-1.0.2.tgz"
+  },
   "maintainers": [
     {
       "name": "cwmma",
       "email": "calvin.metcalf@gmail.com"
     }
   ],
-  "dist": {
-    "shasum": "918a5ab4a7744340b83ff416101ba53c5c531879",
-    "tarball": "http://registry.npmjs.org/process-nextick-args/-/process-nextick-args-1.0.1.tgz"
-  },
   "directories": {},
-  "_resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-1.0.1.tgz",
+  "_resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-1.0.2.tgz",
   "readme": "ERROR: No README data found!"
 }
index 71390ef..78e7cfa 100644 (file)
@@ -1,16 +1,16 @@
-process-nexttick-args
+process-nextick-args
 =====
 
 [![Build Status](https://travis-ci.org/calvinmetcalf/process-nextick-args.svg?branch=master)](https://travis-ci.org/calvinmetcalf/process-nextick-args)
 
 ```bash
-npm install --save process-nexttick-args
+npm install --save process-nextick-args
 ```
 
 Always be able to pass arguments to process.nextTick, no matter the platform
 
 ```js
-var nextTick = require('process-nexttick-args');
+var nextTick = require('process-nextick-args');
 
 nextTick(function (a, b, c) {
   console.log(a, b, c);
index 1b3c171..70ad998 100644 (file)
@@ -1,6 +1,6 @@
 {
   "name": "readable-stream",
-  "version": "2.0.1",
+  "version": "2.0.2",
   "description": "Streams3, a user-land copy of the stream library from iojs v2.x",
   "main": "readable.js",
   "dependencies": {
     "util": false
   },
   "license": "MIT",
-  "gitHead": "d175d0f68745a5014fc9c41b25b8e0e959269126",
+  "gitHead": "1a70134a71196eeabb5e27bc7580faaa68d30513",
   "bugs": {
     "url": "https://github.com/nodejs/readable-stream/issues"
   },
   "homepage": "https://github.com/nodejs/readable-stream#readme",
-  "_id": "readable-stream@2.0.1",
-  "_shasum": "633479b7bd2fbe7a1e869825b40a0b333b9f2bfc",
+  "_id": "readable-stream@2.0.2",
+  "_shasum": "bec81beae8cf455168bc2e5b2b31f5bcfaed9b1b",
   "_from": "readable-stream@>=2.0.0 <2.1.0",
   "_npmVersion": "2.11.1",
   "_nodeVersion": "2.3.0",
@@ -48,8 +48,8 @@
     "email": "calvin.metcalf@gmail.com"
   },
   "dist": {
-    "shasum": "633479b7bd2fbe7a1e869825b40a0b333b9f2bfc",
-    "tarball": "http://registry.npmjs.org/readable-stream/-/readable-stream-2.0.1.tgz"
+    "shasum": "bec81beae8cf455168bc2e5b2b31f5bcfaed9b1b",
+    "tarball": "http://registry.npmjs.org/readable-stream/-/readable-stream-2.0.2.tgz"
   },
   "maintainers": [
     {
@@ -70,6 +70,6 @@
     }
   ],
   "directories": {},
-  "_resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.0.1.tgz",
+  "_resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.0.2.tgz",
   "readme": "ERROR: No README data found!"
 }
index 8823b1c..b8b59f5 100644 (file)
       "android-browser/4.2..latest"
     ]
   },
-  "readme": "# typedarray\n\nTypedArray polyfill ripped from [this\nmodule](https://raw.github.com/inexorabletash/polyfill).\n\n[![build status](https://secure.travis-ci.org/substack/typedarray.png)](http://travis-ci.org/substack/typedarray)\n\n[![testling badge](https://ci.testling.com/substack/typedarray.png)](https://ci.testling.com/substack/typedarray)\n\n# example\n\n``` js\nvar Uint8Array = require('typedarray').Uint8Array;\nvar ua = new Uint8Array(5);\nua[1] = 256 + 55;\nconsole.log(ua[1]);\n```\n\noutput:\n\n```\n55\n```\n\n# methods\n\n``` js\nvar TA = require('typedarray')\n```\n\nThe `TA` object has the following constructors:\n\n* TA.ArrayBuffer\n* TA.DataView\n* TA.Float32Array\n* TA.Float64Array\n* TA.Int8Array\n* TA.Int16Array\n* TA.Int32Array\n* TA.Uint8Array\n* TA.Uint8ClampedArray\n* TA.Uint16Array\n* TA.Uint32Array\n\n# install\n\nWith [npm](https://npmjs.org) do:\n\n```\nnpm install typedarray\n```\n\nTo use this module in the browser, compile with\n[browserify](http://browserify.org)\nor download a UMD build from browserify CDN:\n\nhttp://wzrd.in/standalone/typedarray@latest\n\n# license\n\nMIT\n",
-  "readmeFilename": "readme.markdown",
   "bugs": {
     "url": "https://github.com/substack/typedarray/issues"
   },
   "_id": "typedarray@0.0.6",
-  "_from": "typedarray@>=0.0.5 <0.1.0"
+  "dist": {
+    "shasum": "867ac74e3864187b1d3d47d996a78ec5c8830777",
+    "tarball": "http://registry.npmjs.org/typedarray/-/typedarray-0.0.6.tgz"
+  },
+  "_from": "typedarray@>=0.0.5 <0.1.0",
+  "_npmVersion": "1.4.3",
+  "_npmUser": {
+    "name": "substack",
+    "email": "mail@substack.net"
+  },
+  "maintainers": [
+    {
+      "name": "substack",
+      "email": "mail@substack.net"
+    }
+  ],
+  "directories": {},
+  "_shasum": "867ac74e3864187b1d3d47d996a78ec5c8830777",
+  "_resolved": "https://registry.npmjs.org/typedarray/-/typedarray-0.0.6.tgz",
+  "readme": "ERROR: No README data found!"
 }
index 1ffcb9e..9add3d3 100644 (file)
@@ -1,96 +1,72 @@
 {
-  "_args": [
-    [
-      "graceful-fs@^3.0.0",
-      "/Users/isaacs/dev/npm/npm/node_modules/npm-registry-client"
-    ]
-  ],
-  "_from": "graceful-fs@>=3.0.0 <4.0.0",
-  "_id": "graceful-fs@3.0.8",
-  "_inCache": true,
-  "_location": "/npm-registry-client/graceful-fs",
-  "_nodeVersion": "2.0.1",
-  "_npmUser": {
-    "email": "isaacs@npmjs.com",
-    "name": "isaacs"
-  },
-  "_npmVersion": "2.10.1",
-  "_phantomChildren": {},
-  "_requested": {
-    "name": "graceful-fs",
-    "raw": "graceful-fs@^3.0.0",
-    "rawSpec": "^3.0.0",
-    "scope": null,
-    "spec": ">=3.0.0 <4.0.0",
-    "type": "range"
-  },
-  "_requiredBy": [
-    "/npm-registry-client"
-  ],
-  "_resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-3.0.8.tgz",
-  "_shasum": "ce813e725fa82f7e6147d51c9a5ca68270551c22",
-  "_shrinkwrap": null,
-  "_spec": "graceful-fs@^3.0.0",
-  "_where": "/Users/isaacs/dev/npm/npm/node_modules/npm-registry-client",
   "author": {
-    "email": "i@izs.me",
     "name": "Isaac Z. Schlueter",
+    "email": "i@izs.me",
     "url": "http://blog.izs.me"
   },
-  "bugs": {
-    "url": "https://github.com/isaacs/node-graceful-fs/issues"
-  },
-  "dependencies": {},
+  "name": "graceful-fs",
   "description": "A drop-in replacement for fs, making various improvements.",
-  "devDependencies": {
-    "mkdirp": "^0.5.0",
-    "rimraf": "^2.2.8",
-    "tap": "^1.2.0"
+  "version": "3.0.8",
+  "repository": {
+    "type": "git",
+    "url": "git://github.com/isaacs/node-graceful-fs.git"
+  },
+  "main": "graceful-fs.js",
+  "engines": {
+    "node": ">=0.4.0"
   },
   "directories": {
     "test": "test"
   },
-  "dist": {
-    "shasum": "ce813e725fa82f7e6147d51c9a5ca68270551c22",
-    "tarball": "http://registry.npmjs.org/graceful-fs/-/graceful-fs-3.0.8.tgz"
-  },
-  "engines": {
-    "node": ">=0.4.0"
+  "scripts": {
+    "test": "tap test/*.js"
   },
-  "gitHead": "45c57aa5e323c35a985a525de6f0c9a6ef59e1f8",
-  "homepage": "https://github.com/isaacs/node-graceful-fs#readme",
   "keywords": [
-    "EACCESS",
-    "EAGAIN",
-    "EINVAL",
-    "EMFILE",
-    "EPERM",
-    "error",
-    "errors",
     "fs",
-    "handling",
     "module",
-    "queue",
     "reading",
+    "retry",
     "retries",
-    "retry"
+    "queue",
+    "error",
+    "errors",
+    "handling",
+    "EMFILE",
+    "EAGAIN",
+    "EINVAL",
+    "EPERM",
+    "EACCESS"
   ],
   "license": "ISC",
-  "main": "graceful-fs.js",
+  "devDependencies": {
+    "mkdirp": "^0.5.0",
+    "rimraf": "^2.2.8",
+    "tap": "^1.2.0"
+  },
+  "gitHead": "45c57aa5e323c35a985a525de6f0c9a6ef59e1f8",
+  "bugs": {
+    "url": "https://github.com/isaacs/node-graceful-fs/issues"
+  },
+  "homepage": "https://github.com/isaacs/node-graceful-fs#readme",
+  "_id": "graceful-fs@3.0.8",
+  "_shasum": "ce813e725fa82f7e6147d51c9a5ca68270551c22",
+  "_from": "graceful-fs@>=3.0.0 <4.0.0",
+  "_npmVersion": "2.10.1",
+  "_nodeVersion": "2.0.1",
+  "_npmUser": {
+    "name": "isaacs",
+    "email": "isaacs@npmjs.com"
+  },
+  "dist": {
+    "shasum": "ce813e725fa82f7e6147d51c9a5ca68270551c22",
+    "tarball": "http://registry.npmjs.org/graceful-fs/-/graceful-fs-3.0.8.tgz"
+  },
   "maintainers": [
     {
       "name": "isaacs",
       "email": "i@izs.me"
     }
   ],
-  "name": "graceful-fs",
-  "optionalDependencies": {},
-  "repository": {
-    "type": "git",
-    "url": "git://github.com/isaacs/node-graceful-fs.git"
-  },
-  "scripts": {
-    "test": "tap test/*.js"
-  },
-  "version": "3.0.8"
+  "_resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-3.0.8.tgz",
+  "readme": "ERROR: No README data found!"
 }
index 8f93dd7..ffcccd8 100644 (file)
@@ -6,7 +6,7 @@
   },
   "name": "npm-registry-client",
   "description": "Client for the npm registry",
-  "version": "6.5.0",
+  "version": "6.5.1",
   "repository": {
     "url": "git://github.com/isaacs/npm-registry-client.git"
   },
@@ -25,7 +25,7 @@
     "request": "^2.47.0",
     "retry": "^0.6.1",
     "rimraf": "2",
-    "semver": "2 >=2.2.1 || 3.x || 4",
+    "semver": "2 >=2.2.1 || 3.x || 4 || 5",
     "slide": "^1.1.3",
     "npmlog": ""
   },
   "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 = \"https://registry.npmjs.org/npm\"\nvar params = {timeout: 1000}\n\nclient.get(uri, params, 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 (including the registry\npath – but be sure to terminate the path with `/`). `http` and `https` URLs are\nthe only ones supported.\n\n## Using the client\n\nEvery call to the client follows the same pattern:\n\n* `uri` {String} The *fully-qualified* URI of the registry API method being\n  invoked.\n* `params` {Object} Per-request parameters.\n* `callback` {Function} Callback to be invoked when the call is complete.\n\n### Credentials\n\nMany requests to the registry can by authenticated, and require credentials\nfor authorization. These credentials always look the same:\n\n* `username` {String}\n* `password` {String}\n* `email` {String}\n* `alwaysAuth` {Boolean} Whether calls to the target registry are always\n  authed.\n\n**or**\n\n* `token` {String}\n* `alwaysAuth` {Boolean} Whether calls to the target registry are always\n  authed.\n\n## API\n\n### client.access(uri, params, cb)\n\n* `uri` {String} Registry URL for the package's access API endpoint.\n  Looks like `/-/package/<package name>/access`.\n* `params` {Object} Object containing per-request properties.\n  * `access` {String} New access level for the package. Can be either\n    `public` or `restricted`. Registry will raise an error if trying\n    to change the access level of an unscoped package.\n  * `auth` {Credentials}\n\nSet the access level for scoped packages. For now, there are only two\naccess levels: \"public\" and \"restricted\".\n\n### client.adduser(uri, params, cb)\n\n* `uri` {String} Base registry URL.\n* `params` {Object} Object containing per-request properties.\n  * `auth` {Credentials}\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\nAdd a user account to the registry, or verify the credentials.\n\n### client.deprecate(uri, params, cb)\n\n* `uri` {String} Full registry URI for the deprecated package.\n* `params` {Object} Object containing per-request properties.\n  * `version` {String} Semver version range.\n  * `message` {String} The message to use as a deprecation warning.\n  * `auth` {Credentials}\n* `cb` {Function}\n\nDeprecate a version of a package in the registry.\n\n### client.distTags.fetch(uri, params, cb)\n\n* `uri` {String} Base URL for the registry.\n* `params` {Object} Object containing per-request properties.\n  * `package` {String} Name of the package.\n  * `auth` {Credentials}\n* `cb` {Function}\n\nFetch all of the `dist-tags` for the named package.\n\n### client.distTags.add(uri, params, cb)\n\n* `uri` {String} Base URL for the registry.\n* `params` {Object} Object containing per-request properties.\n  * `package` {String} Name of the package.\n  * `distTag` {String} Name of the new `dist-tag`.\n  * `version` {String} Exact version to be mapped to the `dist-tag`.\n  * `auth` {Credentials}\n* `cb` {Function}\n\nAdd (or replace) a single dist-tag onto the named package.\n\n### client.distTags.set(uri, params, cb)\n\n* `uri` {String} Base URL for the registry.\n* `params` {Object} Object containing per-request properties.\n  * `package` {String} Name of the package.\n  * `distTags` {Object} Object containing a map from tag names to package\n     versions.\n  * `auth` {Credentials}\n* `cb` {Function}\n\nSet all of the `dist-tags` for the named package at once, creating any\n`dist-tags` that do not already exit. Any `dist-tags` not included in the\n`distTags` map will be removed.\n\n### client.distTags.update(uri, params, cb)\n\n* `uri` {String} Base URL for the registry.\n* `params` {Object} Object containing per-request properties.\n  * `package` {String} Name of the package.\n  * `distTags` {Object} Object containing a map from tag names to package\n     versions.\n  * `auth` {Credentials}\n* `cb` {Function}\n\nUpdate the values of multiple `dist-tags`, creating any `dist-tags` that do\nnot already exist. Any pre-existing `dist-tags` not included in the `distTags`\nmap will be left alone.\n\n### client.distTags.rm(uri, params, cb)\n\n* `uri` {String} Base URL for the registry.\n* `params` {Object} Object containing per-request properties.\n  * `package` {String} Name of the package.\n  * `distTag` {String} Name of the new `dist-tag`.\n  * `auth` {Credentials}\n* `cb` {Function}\n\nRemove a single `dist-tag` from the named package.\n\n### client.get(uri, params, cb)\n\n* `uri` {String} The complete registry URI to fetch\n* `params` {Object} Object containing per-request properties.\n  * `timeout` {Number} Duration before the request times out. Optional\n    (default: never).\n  * `follow` {Boolean} Follow 302/301 responses. Optional (default: true).\n  * `staleOk` {Boolean} If there's cached data available, then return that to\n    the callback quickly, and update the cache the background. Optional\n    (default: false).\n  * `auth` {Credentials} Optional.\n* `cb` {Function}\n\nFetches data from the registry via a GET request, saving it in the cache folder\nwith the ETag or the \"Last Modified\" timestamp.\n\n### client.publish(uri, params, cb)\n\n* `uri` {String} The registry URI for the package to publish.\n* `params` {Object} Object containing per-request properties.\n  * `metadata` {Object} Package metadata.\n  * `access` {String} Access for the package. Can be `public` or `restricted` (no default).\n  * `body` {Stream} Stream of the package body / tarball.\n  * `auth` {Credentials}\n* `cb` {Function}\n\nPublish a package to the registry.\n\nNote that this does not create the tarball from a folder.\n\n### client.star(uri, params, cb)\n\n* `uri` {String} The complete registry URI for the package to star.\n* `params` {Object} Object containing per-request properties.\n  * `starred` {Boolean} True to star the package, false to unstar it. Optional\n    (default: false).\n  * `auth` {Credentials}\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(uri, params, cb)\n\n* `uri` {String} The base URL for the registry.\n* `params` {Object} Object containing per-request properties.\n  * `username` {String} Name of user to fetch starred packages for. Optional\n    (default: user in `auth`).\n  * `auth` {Credentials} Optional (required if `username` is omitted).\n* `cb` {Function}\n\nView your own or another user's starred packages.\n\n### client.tag(uri, params, cb)\n\n* `uri` {String} The complete registry URI to tag\n* `params` {Object} Object containing per-request properties.\n  * `version` {String} Version to tag.\n  * `tag` {String} Tag name to apply.\n  * `auth` {Credentials}\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, params, cb)\n\n* `uri` {String} The complete registry URI of the package to unpublish.\n* `params` {Object} Object containing per-request properties.\n  * `version` {String} version to unpublish. Optional – omit to unpublish all\n    versions.\n  * `auth` {Credentials}\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.whoami(uri, params, cb)\n\n* `uri` {String} The base registry for the URI.\n* `params` {Object} Object containing per-request properties.\n  * `auth` {Credentials}\n* `cb` {Function}\n\nSimple call to see who the registry thinks you are. Especially useful with\ntoken-based auth.\n\n\n## PLUMBING\n\nThe below are primarily intended for use by the rest of the API, or by the npm\ncaching logic directly.\n\n### client.request(uri, params, cb)\n\n* `uri` {String} URI pointing to the resource to request.\n* `params` {Object} Object containing per-request properties.\n  * `method` {String} HTTP method. Optional (default: \"GET\").\n  * `body` {Stream | Buffer | String | Object} The request body.  Objects\n    that are not Buffers or Streams are encoded as JSON. Optional – body\n    only used for write operations.\n  * `etag` {String} The cached ETag. Optional.\n  * `lastModified` {String} The cached Last-Modified timestamp. Optional.\n  * `follow` {Boolean} Follow 302/301 responses. Optional (default: true).\n  * `auth` {Credentials} Optional.\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 generic request to the registry. All the other methods are wrappers\naround `client.request`.\n\n### client.fetch(uri, params, cb)\n\n* `uri` {String} The complete registry URI to upload to\n* `params` {Object} Object containing per-request properties.\n  * `headers` {Stream} HTTP headers to be included with the request. Optional.\n  * `auth` {Credentials} Optional.\n* `cb` {Function}\n\nFetch a package from a URL, with auth set appropriately if included. Used to\ncache remote tarballs as well as request package tarballs from the registry.\n\n# Configuration\n\nThe client uses its own configuration, which is just passed in as a simple\nnested object. The following are the supported values (with their defaults, if\nany):\n\n* `proxy.http` {URL} The URL to proxy HTTP requests through.\n* `proxy.https` {URL} The URL to proxy HTTPS requests through. Defaults to be\n  the same as `proxy.http` if unset.\n* `proxy.localAddress` {IP} The local address to use on multi-homed systems.\n* `ssl.ca` {String} Certificate signing authority certificates to trust.\n* `ssl.certificate` {String} Client certificate (PEM encoded). Enable access\n  to servers that require client certificates.\n* `ssl.key` {String} Private key (PEM encoded) for client certificate.\n* `ssl.strict` {Boolean} Whether or not to be strict with SSL certificates.\n  Default = `true`\n* `retry.count` {Number} Number of times to retry on GET failures. Default = 2.\n* `retry.factor` {Number} `factor` setting for `node-retry`. Default = 10.\n* `retry.minTimeout` {Number} `minTimeout` setting for `node-retry`.\n  Default = 10000 (10 seconds)\n* `retry.maxTimeout` {Number} `maxTimeout` setting for `node-retry`.\n  Default = 60000 (60 seconds)\n* `userAgent` {String} User agent header to send. Default =\n  `\"node/{process.version}\"`\n* `log` {Object} The logger to use.  Defaults to `require(\"npmlog\")` if\n  that works, otherwise logs are disabled.\n* `defaultTag` {String} The default tag to use when publishing new packages.\n  Default = `\"latest\"`\n* `couchToken` {Object} A token for use with\n  [couch-login](https://npmjs.org/package/couch-login).\n* `sessionToken` {string} A random identifier for this set of client requests.\n  Default = 8 random hexadecimal bytes.\n",
   "readmeFilename": "README.md",
-  "gitHead": "f7370148e6aa015d560941a8192d35ad97823411",
+  "gitHead": "dbb351ae906f40be03f21bbe28bd392a380dc7bb",
   "bugs": {
     "url": "https://github.com/isaacs/npm-registry-client/issues"
   },
   "homepage": "https://github.com/isaacs/npm-registry-client#readme",
-  "_id": "npm-registry-client@6.5.0",
-  "_shasum": "a1ef783581b5996135be18581b031c043fc80998",
-  "_from": "npm-registry-client@6.5.0"
+  "_id": "npm-registry-client@6.5.1",
+  "_shasum": "328d2088252b69fa541c3dd9f7690288661592a1",
+  "_from": "npm-registry-client@>=6.5.1 <6.6.0"
 }
index fdc307d..40b65a3 100644 (file)
@@ -1,96 +1,72 @@
 {
-  "_args": [
-    [
-      "graceful-fs@2 || 3",
-      "/Users/isaacs/dev/npm/npm/node_modules/read-installed"
-    ]
-  ],
-  "_from": "graceful-fs@>=2.0.0 <3.0.0||>=3.0.0 <4.0.0",
-  "_id": "graceful-fs@3.0.8",
-  "_inCache": true,
-  "_location": "/read-installed/graceful-fs",
-  "_nodeVersion": "2.0.1",
-  "_npmUser": {
-    "email": "isaacs@npmjs.com",
-    "name": "isaacs"
-  },
-  "_npmVersion": "2.10.1",
-  "_phantomChildren": {},
-  "_requested": {
-    "name": "graceful-fs",
-    "raw": "graceful-fs@2 || 3",
-    "rawSpec": "2 || 3",
-    "scope": null,
-    "spec": ">=2.0.0 <3.0.0||>=3.0.0 <4.0.0",
-    "type": "range"
-  },
-  "_requiredBy": [
-    "/read-installed"
-  ],
-  "_resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-3.0.8.tgz",
-  "_shasum": "ce813e725fa82f7e6147d51c9a5ca68270551c22",
-  "_shrinkwrap": null,
-  "_spec": "graceful-fs@2 || 3",
-  "_where": "/Users/isaacs/dev/npm/npm/node_modules/read-installed",
   "author": {
-    "email": "i@izs.me",
     "name": "Isaac Z. Schlueter",
+    "email": "i@izs.me",
     "url": "http://blog.izs.me"
   },
-  "bugs": {
-    "url": "https://github.com/isaacs/node-graceful-fs/issues"
-  },
-  "dependencies": {},
+  "name": "graceful-fs",
   "description": "A drop-in replacement for fs, making various improvements.",
-  "devDependencies": {
-    "mkdirp": "^0.5.0",
-    "rimraf": "^2.2.8",
-    "tap": "^1.2.0"
+  "version": "3.0.8",
+  "repository": {
+    "type": "git",
+    "url": "git://github.com/isaacs/node-graceful-fs.git"
+  },
+  "main": "graceful-fs.js",
+  "engines": {
+    "node": ">=0.4.0"
   },
   "directories": {
     "test": "test"
   },
-  "dist": {
-    "shasum": "ce813e725fa82f7e6147d51c9a5ca68270551c22",
-    "tarball": "http://registry.npmjs.org/graceful-fs/-/graceful-fs-3.0.8.tgz"
-  },
-  "engines": {
-    "node": ">=0.4.0"
+  "scripts": {
+    "test": "tap test/*.js"
   },
-  "gitHead": "45c57aa5e323c35a985a525de6f0c9a6ef59e1f8",
-  "homepage": "https://github.com/isaacs/node-graceful-fs#readme",
   "keywords": [
-    "EACCESS",
-    "EAGAIN",
-    "EINVAL",
-    "EMFILE",
-    "EPERM",
-    "error",
-    "errors",
     "fs",
-    "handling",
     "module",
-    "queue",
     "reading",
+    "retry",
     "retries",
-    "retry"
+    "queue",
+    "error",
+    "errors",
+    "handling",
+    "EMFILE",
+    "EAGAIN",
+    "EINVAL",
+    "EPERM",
+    "EACCESS"
   ],
   "license": "ISC",
-  "main": "graceful-fs.js",
+  "devDependencies": {
+    "mkdirp": "^0.5.0",
+    "rimraf": "^2.2.8",
+    "tap": "^1.2.0"
+  },
+  "gitHead": "45c57aa5e323c35a985a525de6f0c9a6ef59e1f8",
+  "bugs": {
+    "url": "https://github.com/isaacs/node-graceful-fs/issues"
+  },
+  "homepage": "https://github.com/isaacs/node-graceful-fs#readme",
+  "_id": "graceful-fs@3.0.8",
+  "_shasum": "ce813e725fa82f7e6147d51c9a5ca68270551c22",
+  "_from": "graceful-fs@>=2.0.0 <3.0.0||>=3.0.0 <4.0.0",
+  "_npmVersion": "2.10.1",
+  "_nodeVersion": "2.0.1",
+  "_npmUser": {
+    "name": "isaacs",
+    "email": "isaacs@npmjs.com"
+  },
+  "dist": {
+    "shasum": "ce813e725fa82f7e6147d51c9a5ca68270551c22",
+    "tarball": "http://registry.npmjs.org/graceful-fs/-/graceful-fs-3.0.8.tgz"
+  },
   "maintainers": [
     {
       "name": "isaacs",
       "email": "i@izs.me"
     }
   ],
-  "name": "graceful-fs",
-  "optionalDependencies": {},
-  "repository": {
-    "type": "git",
-    "url": "git://github.com/isaacs/node-graceful-fs.git"
-  },
-  "scripts": {
-    "test": "tap test/*.js"
-  },
-  "version": "3.0.8"
+  "_resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-3.0.8.tgz",
+  "readme": "ERROR: No README data found!"
 }
index 4ea89c4..a7e0932 100644 (file)
@@ -1,7 +1,7 @@
 {
   "name": "read-installed",
   "description": "Read all the installed packages in a folder, and return a tree structure with all the data.",
-  "version": "4.0.1",
+  "version": "4.0.2",
   "repository": {
     "type": "git",
     "url": "git://github.com/isaacs/read-installed.git"
@@ -14,7 +14,7 @@
     "debuglog": "^1.0.1",
     "read-package-json": "^2.0.0",
     "readdir-scoped-modules": "^1.0.0",
-    "semver": "2 || 3 || 4",
+    "semver": "2 || 3 || 4 || 5",
     "slide": "~1.1.3",
     "util-extend": "^1.0.1",
     "graceful-fs": "2 || 3"
     "rimraf": "^2.2.8",
     "tap": "^1.2.0"
   },
-  "gitHead": "8547e3e176098051615651481f402d22e1f33c9d",
+  "readme": "# read-installed\n\nRead all the installed packages in a folder, and return a tree\nstructure with all the data.\n\nnpm uses this.\n\n## 2.0.0\n\nBreaking changes in `2.0.0`:\n\nThe second argument is now an `Object` that contains the following keys:\n\n * `depth` optional, defaults to Infinity\n * `log` optional log Function\n * `dev` optional, default false, set to true to include devDependencies\n\n## Usage\n\n```javascript\nvar readInstalled = require(\"read-installed\")\n// optional options\nvar options = { dev: false, log: fn, depth: 2 }\nreadInstalled(folder, options, function (er, data) {\n  ...\n})\n```\n",
+  "readmeFilename": "README.md",
+  "gitHead": "e683eb7f2bb8e9b7b40c1e26192b385b92a3192f",
   "bugs": {
     "url": "https://github.com/isaacs/read-installed/issues"
   },
   "homepage": "https://github.com/isaacs/read-installed#readme",
-  "_id": "read-installed@4.0.1",
-  "_shasum": "b8d8f8034159586fea57d606a9aaba3df74284c3",
-  "_from": "read-installed@>=4.0.1 <4.1.0",
-  "_npmVersion": "2.11.3",
-  "_nodeVersion": "2.3.1",
-  "_npmUser": {
-    "name": "iarna",
-    "email": "me@re-becca.org"
-  },
-  "dist": {
-    "shasum": "b8d8f8034159586fea57d606a9aaba3df74284c3",
-    "tarball": "http://registry.npmjs.org/read-installed/-/read-installed-4.0.1.tgz"
-  },
-  "maintainers": [
-    {
-      "name": "isaacs",
-      "email": "i@izs.me"
-    },
-    {
-      "name": "othiym23",
-      "email": "ogd@aoaioxxysz.net"
-    },
-    {
-      "name": "iarna",
-      "email": "me@re-becca.org"
-    }
-  ],
-  "directories": {},
-  "_resolved": "https://registry.npmjs.org/read-installed/-/read-installed-4.0.1.tgz"
+  "_id": "read-installed@4.0.2",
+  "_shasum": "4e8b18be974ccb75654b28ddcc9aac686404690e",
+  "_from": "read-installed@>=4.0.2 <4.1.0"
 }
diff --git a/deps/npm/node_modules/request/.eslintrc b/deps/npm/node_modules/request/.eslintrc
deleted file mode 100644 (file)
index e79f481..0000000
+++ /dev/null
@@ -1,45 +0,0 @@
-{
-  "env": {
-    "node": true
-  },
-  "rules": {
-    // 2-space indentation
-    "indent": [2, 2],
-    // 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,
-    // Allow multi spaces around operators since they are
-    // used for alignment.  This is not consistent in the
-    // code.
-    "no-multi-spaces": 0,
-    // Style rule is: most objects use { beforeColon: false, afterColon: true }, unless aligning which uses:
-    //
-    // {
-    //   beforeColon : true,
-    //   afterColon  : true
-    // }
-    //
-    // eslint can't handle this, so the check is disabled.
-    "key-spacing": 0,
-    // Allow shadowing vars in outer scope (needs discussion)
-    "no-shadow": 0,
-    // Use if () { }
-    //       ^ space
-    "space-after-keywords": [2, "always"],
-    // Use if () { }
-    //          ^ space
-    "space-before-blocks": [2, "always"]
-  }
-}
index 6b3905e..4cc1fcb 100644 (file)
@@ -1,5 +1,18 @@
 ## Change Log
 
+### v2.60.0 (2015/07/21)
+- [#1687](https://github.com/request/request/pull/1687) Fix caseless bug - content-type not being set for multipart/form-data (@simov, @garymathews)
+
+### v2.59.0 (2015/07/20)
+- [#1671](https://github.com/request/request/pull/1671) Add tests and docs for using the agent, agentClass, agentOptions and forever options.\r Forever option defaults to using http(s).Agent in node 0.12+ (@simov)
+- [#1679](https://github.com/request/request/pull/1679) Fix - do not remove OAuth param when using OAuth realm (@simov, @jhalickman)
+- [#1668](https://github.com/request/request/pull/1668) updated dependencies (@deamme)
+- [#1656](https://github.com/request/request/pull/1656) Fix form method (@simov)
+- [#1651](https://github.com/request/request/pull/1651) Preserve HEAD method when using followAllRedirects (@simov)
+- [#1652](https://github.com/request/request/pull/1652) Update `encoding` option documentation in README.md (@daniel347x)
+- [#1650](https://github.com/request/request/pull/1650) Allow content-type overriding when using the `form` option (@simov)
+- [#1646](https://github.com/request/request/pull/1646) Clarify the nature of setting `ca` in `agentOptions` (@jeffcharles)
+
 ### v2.58.0 (2015/06/16)
 - [#1638](https://github.com/request/request/pull/1638) Use the `extend` module to deep extend in the defaults method (@simov)
 - [#1631](https://github.com/request/request/pull/1631) Move tunnel logic into separate module (@simov)
@@ -74,7 +87,7 @@
 - [#1392](https://github.com/request/request/pull/1392) Improve `timeout` option description (@watson)
 
 ### v2.52.0 (2015/02/02)
-- [#1383](https://github.com/request/request/pull/1383) Add missing HTTPS options that were not being passed to tunnel (@brichard19) (@nylen, @brichard19)
+- [#1383](https://github.com/request/request/pull/1383) Add missing HTTPS options that were not being passed to tunnel (@brichard19) (@nylen)
 - [#1388](https://github.com/request/request/pull/1388) Upgrade mime-types package version (@roderickhsiao)
 - [#1389](https://github.com/request/request/pull/1389) Revise Setup Tunnel Function (@seanstrom)
 - [#1374](https://github.com/request/request/pull/1374) Allow explicitly disabling tunneling for proxied https destinations (@nylen)
 - [#121](https://github.com/request/request/pull/121) Another patch for cookie handling regression (@jhurliman)
 - [#117](https://github.com/request/request/pull/117) Remove the global `i` (@3rd-Eden)
 - [#110](https://github.com/request/request/pull/110) Update to Iris Couch URL (@jhs)
-- [#86](https://github.com/request/request/pull/86) Can't post binary to multipart requests (@developmentseed)
+- [#86](https://github.com/request/request/pull/86) Can't post binary to multipart requests (@kkaefer)
 - [#105](https://github.com/request/request/pull/105) added test for proxy option. (@dominictarr)
 - [#102](https://github.com/request/request/pull/102) Implemented cookies - closes issue 82: https://github.com/mikeal/request/issues/82 (@alessioalex)
 - [#97](https://github.com/request/request/pull/97) Typo in previous pull causes TypeError in non-0.5.11 versions (@isaacs)
index 8530d10..b722767 100644 (file)
@@ -646,7 +646,8 @@ request.get({
 
 It is possible to accept other certificates than those signed by generally allowed Certificate Authorities (CAs).
 This can be useful, for example,  when using self-signed certificates.
-To allow a different certificate, you can specify the signing CA by adding the contents of the CA's certificate file to the `agentOptions`:
+To require a different root certificate, you can specify the signing CA by adding the contents of the CA's certificate file to the `agentOptions`.
+The certificate the domain presents must be signed by the root certificate specified:
 
 ```js
 request.get({
@@ -765,13 +766,17 @@ The first argument can be either a `url` or an `options` object. The only requir
 
 ---
 
-- `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).
+- `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). (**Note:** if you expect binary data, you should set `encoding: null`.)
 - `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.
 - `jar` - If `true` and `tough-cookie` is installed, remember cookies for future use (or define your custom cookie jar; see examples section)
 
 ---
 
-- `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.
+- `agent` - `http(s).Agent` instance to use
+- `agentClass` - alternatively specify your agent's class name
+- `agentOptions` - and pass its options. **Note:** for HTTPS see [tls API doc for TLS/SSL options](http://nodejs.org/api/tls.html#tls_tls_connect_options_callback) and the [documentation above](#using-optionsagentoptions).
+- `forever` - set to `true` to use the [forever-agent](https://github.com/request/forever-agent) **Note:** Defaults to `http(s).Agent({keepAlive:true})` in node 0.12+
+- `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). 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. **Note:** `pool` is used only when the `agent` option is not specified.
   - 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}`).
   - Note that if you are sending multiple requests in a loop and creating
     multiple new `pool` objects, `maxSockets` will not work as intended.  To
@@ -782,10 +787,12 @@ The first argument can be either a `url` or an `options` object. The only requir
   request to respond before aborting the request.  Note that if the underlying
   TCP connection cannot be established, the OS-wide TCP connection timeout will
   overrule the `timeout` option ([the default in Linux is around 20 seconds](http://www.sekuda.com/overriding_the_default_linux_kernel_20_second_tcp_socket_connect_timeout)).
+
+---
+
 - `localAddress` - Local interface to bind for network connections.
 - `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`)
 - `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).
 - `tunnel` - controls the behavior of
   [HTTP `CONNECT` tunneling](https://en.wikipedia.org/wiki/HTTP_tunnel#HTTP_CONNECT_tunneling)
   as follows:
@@ -802,9 +809,6 @@ The first argument can be either a `url` or an `options` object. The only requir
 ---
 
 - `time` - If `true`, the request-response cycle (including all redirects) is timed at millisecond resolution, and the result provided on the response's `elapsedTime` property.
-
----
-
 - `har` - A [HAR 1.2 Request Object](http://www.softwareishard.com/blog/har-12-spec/#request), will be processed from HAR format into options overwriting matching values *(see the [HAR 1.2 section](#support-for-har-1.2) for details)*
 
 The callback argument gets 3 arguments:
index 5cc79da..5e85946 100644 (file)
@@ -54,6 +54,15 @@ function copy (obj) {
   return o
 }
 
+function version () {
+  var numbers = process.version.replace('v', '').split('.')
+  return {
+    major: parseInt(numbers[0], 10),
+    minor: parseInt(numbers[1], 10),
+    patch: parseInt(numbers[2], 10)
+  }
+}
+
 exports.isFunction            = isFunction
 exports.paramsHaveRequestBody = paramsHaveRequestBody
 exports.safeStringify         = safeStringify
@@ -61,4 +70,5 @@ exports.md5                   = md5
 exports.isReadStream          = isReadStream
 exports.toBase64              = toBase64
 exports.copy                  = copy
+exports.version               = version
 exports.defer                 = deferMethod()
index b0f7ab8..c24209b 100644 (file)
@@ -81,7 +81,7 @@ OAuth.prototype.concatParams = function (oa, sep, wrap) {
   }).sort()
 
   if (oa.realm) {
-    params.splice(0, 1, 'realm')
+    params.splice(0, 0, 'realm')
   }
   params.push('oauth_signature')
 
index 1d46502..b2d0f61 100644 (file)
@@ -113,7 +113,8 @@ Redirect.prototype.onResponse = function (response) {
     , redirectUri: redirectTo
     }
   )
-  if (self.followAllRedirects && response.statusCode !== 401 && response.statusCode !== 307) {
+  if (self.followAllRedirects && request.method !== 'HEAD'
+    && response.statusCode !== 401 && response.statusCode !== 307) {
     request.method = 'GET'
   }
   // request.method = 'GET' // Force all redirects to use GET || commented out fixes #215
index 89adc7d..b454fe4 100644 (file)
   "bugs": {
     "url": "https://github.com/mikeal/aws-sign/issues"
   },
-  "homepage": "https://github.com/mikeal/aws-sign#readme",
   "_id": "aws-sign2@0.5.0",
+  "dist": {
+    "shasum": "c57103f7a17fc037f02d7c2e64b602ea223f7d63",
+    "tarball": "http://registry.npmjs.org/aws-sign2/-/aws-sign2-0.5.0.tgz"
+  },
+  "_from": "aws-sign2@>=0.5.0 <0.6.0",
+  "_npmVersion": "1.3.2",
+  "_npmUser": {
+    "name": "mikeal",
+    "email": "mikeal.rogers@gmail.com"
+  },
+  "maintainers": [
+    {
+      "name": "mikeal",
+      "email": "mikeal.rogers@gmail.com"
+    }
+  ],
+  "directories": {},
   "_shasum": "c57103f7a17fc037f02d7c2e64b602ea223f7d63",
   "_resolved": "https://registry.npmjs.org/aws-sign2/-/aws-sign2-0.5.0.tgz",
-  "_from": "aws-sign2@>=0.5.0 <0.6.0"
+  "homepage": "https://github.com/mikeal/aws-sign#readme"
 }
diff --git a/deps/npm/node_modules/request/node_modules/bl/.jshintrc b/deps/npm/node_modules/request/node_modules/bl/.jshintrc
deleted file mode 100644 (file)
index c8ef3ca..0000000
+++ /dev/null
@@ -1,59 +0,0 @@
-{
-    "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
index 7ddb9c9..81c0814 100644 (file)
@@ -1,11 +1,14 @@
 language: node_js
+before_install:
+  - curl --location http://git.io/1OcIZA | bash -s
 node_js:
   - 0.8
-  - "0.10"
+  - 0.10
+  - 0.11
 branches:
   only:
     - master
 notifications:
   email:
     - rod@vagg.org
-script: npm test
\ No newline at end of file
+script: npm test
index 6b7fb6d..4d87866 100644 (file)
@@ -1,5 +1,7 @@
 # bl *(BufferList)*
 
+[![Build Status](https://travis-ci.org/rvagg/bl.svg?branch=master)](https://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/)
diff --git a/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/.travis.yml b/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/.travis.yml
new file mode 100644 (file)
index 0000000..a2870df
--- /dev/null
@@ -0,0 +1,39 @@
+sudo: false
+language: node_js
+before_install:
+  - npm install -g npm
+notifications:
+  email: false
+matrix:
+  include:
+  - node_js: '0.8'
+    env: TASK=test
+  - node_js: '0.10'
+    env: TASK=test
+  - node_js: '0.11'
+    env: TASK=test
+  - node_js: '0.12'
+    env: TASK=test
+  - node_js: 'iojs'
+    env: TASK=test
+  - node_js: 'iojs'
+    env: TASK=browser BROWSER_NAME=opera BROWSER_VERSION="11..latest"
+  - node_js: 'iojs'
+    env: TASK=browser BROWSER_NAME=ie BROWSER_VERSION="9..latest"
+  - node_js: 'iojs'
+    env: TASK=browser BROWSER_NAME=chrome BROWSER_VERSION="39..beta"
+  - node_js: 'iojs'
+    env: TASK=browser BROWSER_NAME=firefox BROWSER_VERSION="34..beta"
+  - node_js: 'iojs'
+    env: TASK=browser BROWSER_NAME=ipad BROWSER_VERSION="6.0..latest"
+  - node_js: 'iojs'
+    env: TASK=browser BROWSER_NAME=iphone BROWSER_VERSION="6.0..latest"
+  - node_js: 'iojs'
+    env: TASK=browser BROWSER_NAME=safari BROWSER_VERSION="5..latest"
+  - node_js: 'iojs'
+    env: TASK=browser BROWSER_NAME=android BROWSER_VERSION="4.0..latest"
+script: "npm run $TASK"
+env:
+  global:
+  - secure: rE2Vvo7vnjabYNULNyLFxOyt98BoJexDqsiOnfiD6kLYYsiQGfr/sbZkPMOFm9qfQG7pjqx+zZWZjGSswhTt+626C0t/njXqug7Yps4c3dFblzGfreQHp7wNX5TFsvrxd6dAowVasMp61sJcRnB2w8cUzoe3RAYUDHyiHktwqMc=
+  - secure: g9YINaKAdMatsJ28G9jCGbSaguXCyxSTy+pBO6Ch0Cf57ZLOTka3HqDj8p3nV28LUIHZ3ut5WO43CeYKwt4AUtLpBS3a0dndHdY6D83uY6b2qh5hXlrcbeQTq2cvw2y95F7hm4D1kwrgZ7ViqaKggRcEupAL69YbJnxeUDKWEdI=
diff --git a/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/.zuul.yml b/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/.zuul.yml
new file mode 100644 (file)
index 0000000..96d9cfb
--- /dev/null
@@ -0,0 +1 @@
+ui: tape
index 5c455f4..77fafa3 100644 (file)
@@ -1,14 +1,36 @@
 # readable-stream
 
-***Node-core streams for userland***
+***Node-core streams for userland*** [![Build Status](https://travis-ci.org/nodejs/readable-stream.svg?branch=master)](https://travis-ci.org/nodejs/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.
 
-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.
+[![Sauce Test Status](https://saucelabs.com/browser-matrix/readable-stream.svg)](https://saucelabs.com/u/readable-stream)
+
+```bash
+npm install --save readable-stream
+```
+
+***Node-core streams for userland***
+
+This package is a mirror of the Streams2 and Streams3 implementations in
+Node-core, including [documentation](doc/stream.markdown).
+
+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, for background see [this blogpost](http://r.va.gg/2014/06/why-i-dont-use-nodes-core-stream-module.html).
+
+As of version 2.0.0 **readable-stream** uses semantic versioning.
 
-**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.
+# Streams WG Team Members
 
-**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"`
+* **Chris Dickinson** ([@chrisdickinson](https://github.com/chrisdickinson)) &lt;christopher.s.dickinson@gmail.com&gt;
+  - Release GPG key: 9554F04D7259F04124DE6B476D5A82AC7E37093B
+* **Calvin Metcalf** ([@calvinmetcalf](https://github.com/calvinmetcalf)) &lt;calvin.metcalf@gmail.com&gt;
+  - Release GPG key: F3EF5F62A87FC27A22E643F714CE4FF5015AA242
+* **Rod Vagg** ([@rvagg](https://github.com/rvagg)) &lt;rod@vagg.org&gt;
+  - Release GPG key: DD8F2338BAE7501E3DD5AC78C273792F7D83545D
+* **Sam Newman** ([@sonewman](https://github.com/sonewman)) &lt;newmansam@outlook.com&gt;
+* **Mathias Buus** ([@mafintosh](https://github.com/mafintosh)) &lt;mathiasbuus@gmail.com&gt;
+* **Domenic Denicola** ([@domenic](https://github.com/domenic)) &lt;d@domenic.me&gt;
diff --git a/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/doc/stream.markdown b/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/doc/stream.markdown
new file mode 100644 (file)
index 0000000..a2270c8
--- /dev/null
@@ -0,0 +1,1651 @@
+# Stream
+
+    Stability: 2 - Stable
+
+A stream is an abstract interface implemented by various objects in
+io.js.  For example a [request to an HTTP
+server](https://iojs.org/dist/v2.3.0/doc/api/http.html#http_http_incomingmessage) is a stream, as is
+[stdout][]. Streams are readable, writable, or both. All streams are
+instances of [EventEmitter][]
+
+You can load the Stream base classes by doing `require('stream')`.
+There are base classes provided for [Readable][] streams, [Writable][]
+streams, [Duplex][] streams, and [Transform][] streams.
+
+This document is split up into 3 sections.  The first explains the
+parts of the API that you need to be aware of to use streams in your
+programs.  If you never implement a streaming API yourself, you can
+stop there.
+
+The second section explains the parts of the API that you need to use
+if you implement your own custom streams yourself.  The API is
+designed to make this easy for you to do.
+
+The third section goes into more depth about how streams work,
+including some of the internal mechanisms and functions that you
+should probably not modify unless you definitely know what you are
+doing.
+
+
+## API for Stream Consumers
+
+<!--type=misc-->
+
+Streams can be either [Readable][], [Writable][], or both ([Duplex][]).
+
+All streams are EventEmitters, but they also have other custom methods
+and properties depending on whether they are Readable, Writable, or
+Duplex.
+
+If a stream is both Readable and Writable, then it implements all of
+the methods and events below.  So, a [Duplex][] or [Transform][] stream is
+fully described by this API, though their implementation may be
+somewhat different.
+
+It is not necessary to implement Stream interfaces in order to consume
+streams in your programs.  If you **are** implementing streaming
+interfaces in your own program, please also refer to
+[API for Stream Implementors][] below.
+
+Almost all io.js programs, no matter how simple, use Streams in some
+way.  Here is an example of using Streams in an io.js program:
+
+```javascript
+var http = require('http');
+
+var server = http.createServer(function (req, res) {
+  // req is an http.IncomingMessage, which is a Readable Stream
+  // res is an http.ServerResponse, which is a Writable Stream
+
+  var body = '';
+  // we want to get the data as utf8 strings
+  // If you don't set an encoding, then you'll get Buffer objects
+  req.setEncoding('utf8');
+
+  // Readable streams emit 'data' events once a listener is added
+  req.on('data', function (chunk) {
+    body += chunk;
+  });
+
+  // the end event tells you that you have entire body
+  req.on('end', function () {
+    try {
+      var data = JSON.parse(body);
+    } catch (er) {
+      // uh oh!  bad json!
+      res.statusCode = 400;
+      return res.end('error: ' + er.message);
+    }
+
+    // write back something interesting to the user:
+    res.write(typeof data);
+    res.end();
+  });
+});
+
+server.listen(1337);
+
+// $ curl localhost:1337 -d '{}'
+// object
+// $ curl localhost:1337 -d '"foo"'
+// string
+// $ curl localhost:1337 -d 'not json'
+// error: Unexpected token o
+```
+
+### Class: stream.Readable
+
+<!--type=class-->
+
+The Readable stream interface is the abstraction for a *source* of
+data that you are reading from.  In other words, data comes *out* of a
+Readable stream.
+
+A Readable stream will not start emitting data until you indicate that
+you are ready to receive it.
+
+Readable streams have two "modes": a **flowing mode** and a **paused
+mode**.  When in flowing mode, data is read from the underlying system
+and provided to your program as fast as possible.  In paused mode, you
+must explicitly call `stream.read()` to get chunks of data out.
+Streams start out in paused mode.
+
+**Note**: If no data event handlers are attached, and there are no
+[`pipe()`][] destinations, and the stream is switched into flowing
+mode, then data will be lost.
+
+You can switch to flowing mode by doing any of the following:
+
+* Adding a [`'data'` event][] handler to listen for data.
+* Calling the [`resume()`][] method to explicitly open the flow.
+* Calling the [`pipe()`][] method to send the data to a [Writable][].
+
+You can switch back to paused mode by doing either of the following:
+
+* If there are no pipe destinations, by calling the [`pause()`][]
+  method.
+* If there are pipe destinations, by removing any [`'data'` event][]
+  handlers, and removing all pipe destinations by calling the
+  [`unpipe()`][] method.
+
+Note that, for backwards compatibility reasons, removing `'data'`
+event handlers will **not** automatically pause the stream.  Also, if
+there are piped destinations, then calling `pause()` will not
+guarantee that the stream will *remain* paused once those
+destinations drain and ask for more data.
+
+Examples of readable streams include:
+
+* [http responses, on the client](https://iojs.org/dist/v2.3.0/doc/api/http.html#http_http_incomingmessage)
+* [http requests, on the server](https://iojs.org/dist/v2.3.0/doc/api/http.html#http_http_incomingmessage)
+* [fs read streams](https://iojs.org/dist/v2.3.0/doc/api/fs.html#fs_class_fs_readstream)
+* [zlib streams][]
+* [crypto streams][]
+* [tcp sockets][]
+* [child process stdout and stderr][]
+* [process.stdin][]
+
+#### Event: 'readable'
+
+When a chunk of data can be read from the stream, it will emit a
+`'readable'` event.
+
+In some cases, listening for a `'readable'` event will cause some data
+to be read into the internal buffer from the underlying system, if it
+hadn't already.
+
+```javascript
+var readable = getReadableStreamSomehow();
+readable.on('readable', function() {
+  // there is some data to read now
+});
+```
+
+Once the internal buffer is drained, a `readable` event will fire
+again when more data is available.
+
+#### Event: 'data'
+
+* `chunk` {Buffer | String} The chunk of data.
+
+Attaching a `data` event listener to a stream that has not been
+explicitly paused will switch the stream into flowing mode. Data will
+then be passed as soon as it is available.
+
+If you just want to get all the data out of the stream as fast as
+possible, this is the best way to do so.
+
+```javascript
+var readable = getReadableStreamSomehow();
+readable.on('data', function(chunk) {
+  console.log('got %d bytes of data', chunk.length);
+});
+```
+
+#### Event: 'end'
+
+This event fires when there will be no more data to read.
+
+Note that the `end` event **will not fire** unless the data is
+completely consumed.  This can be done by switching into flowing mode,
+or by calling `read()` repeatedly until you get to the end.
+
+```javascript
+var readable = getReadableStreamSomehow();
+readable.on('data', function(chunk) {
+  console.log('got %d bytes of data', chunk.length);
+});
+readable.on('end', function() {
+  console.log('there will be no more data.');
+});
+```
+
+#### Event: 'close'
+
+Emitted when the underlying resource (for example, the backing file
+descriptor) has been closed. Not all streams will emit this.
+
+#### Event: 'error'
+
+* {Error Object}
+
+Emitted if there was an error receiving data.
+
+#### readable.read([size])
+
+* `size` {Number} Optional argument to specify how much data to read.
+* Return {String | Buffer | null}
+
+The `read()` method pulls some data out of the internal buffer and
+returns it.  If there is no data available, then it will return
+`null`.
+
+If you pass in a `size` argument, then it will return that many
+bytes.  If `size` bytes are not available, then it will return `null`.
+
+If you do not specify a `size` argument, then it will return all the
+data in the internal buffer.
+
+This method should only be called in paused mode.  In flowing mode,
+this method is called automatically until the internal buffer is
+drained.
+
+```javascript
+var readable = getReadableStreamSomehow();
+readable.on('readable', function() {
+  var chunk;
+  while (null !== (chunk = readable.read())) {
+    console.log('got %d bytes of data', chunk.length);
+  }
+});
+```
+
+If this method returns a data chunk, then it will also trigger the
+emission of a [`'data'` event][].
+
+#### readable.setEncoding(encoding)
+
+* `encoding` {String} The encoding to use.
+* Return: `this`
+
+Call this function to cause the stream to return strings of the
+specified encoding instead of Buffer objects.  For example, if you do
+`readable.setEncoding('utf8')`, then the output data will be
+interpreted as UTF-8 data, and returned as strings.  If you do
+`readable.setEncoding('hex')`, then the data will be encoded in
+hexadecimal string format.
+
+This properly handles multi-byte characters that would otherwise be
+potentially mangled if you simply pulled the Buffers directly and
+called `buf.toString(encoding)` on them.  If you want to read the data
+as strings, always use this method.
+
+```javascript
+var readable = getReadableStreamSomehow();
+readable.setEncoding('utf8');
+readable.on('data', function(chunk) {
+  assert.equal(typeof chunk, 'string');
+  console.log('got %d characters of string data', chunk.length);
+});
+```
+
+#### readable.resume()
+
+* Return: `this`
+
+This method will cause the readable stream to resume emitting `data`
+events.
+
+This method will switch the stream into flowing mode.  If you do *not*
+want to consume the data from a stream, but you *do* want to get to
+its `end` event, you can call [`readable.resume()`][] to open the flow of
+data.
+
+```javascript
+var readable = getReadableStreamSomehow();
+readable.resume();
+readable.on('end', function() {
+  console.log('got to the end, but did not read anything');
+});
+```
+
+#### readable.pause()
+
+* Return: `this`
+
+This method will cause a stream in flowing mode to stop emitting
+`data` events, switching out of flowing mode.  Any data that becomes
+available will remain in the internal buffer.
+
+```javascript
+var readable = getReadableStreamSomehow();
+readable.on('data', function(chunk) {
+  console.log('got %d bytes of data', chunk.length);
+  readable.pause();
+  console.log('there will be no more data for 1 second');
+  setTimeout(function() {
+    console.log('now data will start flowing again');
+    readable.resume();
+  }, 1000);
+});
+```
+
+#### readable.isPaused()
+
+* Return: `Boolean`
+
+This method returns whether or not the `readable` has been **explicitly**
+paused by client code (using `readable.pause()` without a corresponding
+`readable.resume()`).
+
+```javascript
+var readable = new stream.Readable
+
+readable.isPaused() // === false
+readable.pause()
+readable.isPaused() // === true
+readable.resume()
+readable.isPaused() // === false
+```
+
+#### readable.pipe(destination[, options])
+
+* `destination` {[Writable][] Stream} The destination for writing data
+* `options` {Object} Pipe options
+  * `end` {Boolean} End the writer when the reader ends. Default = `true`
+
+This method pulls all the data out of a readable stream, and writes it
+to the supplied destination, automatically managing the flow so that
+the destination is not overwhelmed by a fast readable stream.
+
+Multiple destinations can be piped to safely.
+
+```javascript
+var readable = getReadableStreamSomehow();
+var writable = fs.createWriteStream('file.txt');
+// All the data from readable goes into 'file.txt'
+readable.pipe(writable);
+```
+
+This function returns the destination stream, so you can set up pipe
+chains like so:
+
+```javascript
+var r = fs.createReadStream('file.txt');
+var z = zlib.createGzip();
+var w = fs.createWriteStream('file.txt.gz');
+r.pipe(z).pipe(w);
+```
+
+For example, emulating the Unix `cat` command:
+
+```javascript
+process.stdin.pipe(process.stdout);
+```
+
+By default [`end()`][] is called on the destination when the source stream
+emits `end`, so that `destination` is no longer writable. Pass `{ end:
+false }` as `options` to keep the destination stream open.
+
+This keeps `writer` open so that "Goodbye" can be written at the
+end.
+
+```javascript
+reader.pipe(writer, { end: false });
+reader.on('end', function() {
+  writer.end('Goodbye\n');
+});
+```
+
+Note that `process.stderr` and `process.stdout` are never closed until
+the process exits, regardless of the specified options.
+
+#### readable.unpipe([destination])
+
+* `destination` {[Writable][] Stream} Optional specific stream to unpipe
+
+This method will remove the hooks set up for a previous `pipe()` call.
+
+If the destination is not specified, then all pipes are removed.
+
+If the destination is specified, but no pipe is set up for it, then
+this is a no-op.
+
+```javascript
+var readable = getReadableStreamSomehow();
+var writable = fs.createWriteStream('file.txt');
+// All the data from readable goes into 'file.txt',
+// but only for the first second
+readable.pipe(writable);
+setTimeout(function() {
+  console.log('stop writing to file.txt');
+  readable.unpipe(writable);
+  console.log('manually close the file stream');
+  writable.end();
+}, 1000);
+```
+
+#### readable.unshift(chunk)
+
+* `chunk` {Buffer | String} Chunk of data to unshift onto the read queue
+
+This is useful in certain cases where a stream is being consumed by a
+parser, which needs to "un-consume" some data that it has
+optimistically pulled out of the source, so that the stream can be
+passed on to some other party.
+
+If you find that you must often call `stream.unshift(chunk)` in your
+programs, consider implementing a [Transform][] stream instead.  (See API
+for Stream Implementors, below.)
+
+```javascript
+// Pull off a header delimited by \n\n
+// use unshift() if we get too much
+// Call the callback with (error, header, stream)
+var StringDecoder = require('string_decoder').StringDecoder;
+function parseHeader(stream, callback) {
+  stream.on('error', callback);
+  stream.on('readable', onReadable);
+  var decoder = new StringDecoder('utf8');
+  var header = '';
+  function onReadable() {
+    var chunk;
+    while (null !== (chunk = stream.read())) {
+      var str = decoder.write(chunk);
+      if (str.match(/\n\n/)) {
+        // found the header boundary
+        var split = str.split(/\n\n/);
+        header += split.shift();
+        var remaining = split.join('\n\n');
+        var buf = new Buffer(remaining, 'utf8');
+        if (buf.length)
+          stream.unshift(buf);
+        stream.removeListener('error', callback);
+        stream.removeListener('readable', onReadable);
+        // now the body of the message can be read from the stream.
+        callback(null, header, stream);
+      } else {
+        // still reading the header.
+        header += str;
+      }
+    }
+  }
+}
+```
+
+#### readable.wrap(stream)
+
+* `stream` {Stream} An "old style" readable stream
+
+Versions of Node.js prior to v0.10 had streams that did not implement the
+entire Streams API as it is today.  (See "Compatibility" below for
+more information.)
+
+If you are using an older io.js library that emits `'data'` events and
+has a [`pause()`][] method that is advisory only, then you can use the
+`wrap()` method to create a [Readable][] stream that uses the old stream
+as its data source.
+
+You will very rarely ever need to call this function, but it exists
+as a convenience for interacting with old io.js programs and libraries.
+
+For example:
+
+```javascript
+var OldReader = require('./old-api-module.js').OldReader;
+var oreader = new OldReader;
+var Readable = require('stream').Readable;
+var myReader = new Readable().wrap(oreader);
+
+myReader.on('readable', function() {
+  myReader.read(); // etc.
+});
+```
+
+
+### Class: stream.Writable
+
+<!--type=class-->
+
+The Writable stream interface is an abstraction for a *destination*
+that you are writing data *to*.
+
+Examples of writable streams include:
+
+* [http requests, on the client](https://iojs.org/dist/v2.3.0/doc/api/http.html#http_class_http_clientrequest)
+* [http responses, on the server](https://iojs.org/dist/v2.3.0/doc/api/http.html#http_class_http_serverresponse)
+* [fs write streams](https://iojs.org/dist/v2.3.0/doc/api/fs.html#fs_class_fs_writestream)
+* [zlib streams][]
+* [crypto streams][]
+* [tcp sockets][]
+* [child process stdin](https://iojs.org/dist/v2.3.0/doc/api/child_process.html#child_process_child_stdin)
+* [process.stdout][], [process.stderr][]
+
+#### writable.write(chunk[, encoding][, callback])
+
+* `chunk` {String | Buffer} The data to write
+* `encoding` {String} The encoding, if `chunk` is a String
+* `callback` {Function} Callback for when this chunk of data is flushed
+* Returns: {Boolean} True if the data was handled completely.
+
+This method writes some data to the underlying system, and calls the
+supplied callback once the data has been fully handled.
+
+The return value indicates if you should continue writing right now.
+If the data had to be buffered internally, then it will return
+`false`.  Otherwise, it will return `true`.
+
+This return value is strictly advisory.  You MAY continue to write,
+even if it returns `false`.  However, writes will be buffered in
+memory, so it is best not to do this excessively.  Instead, wait for
+the `drain` event before writing more data.
+
+#### Event: 'drain'
+
+If a [`writable.write(chunk)`][] call returns false, then the `drain`
+event will indicate when it is appropriate to begin writing more data
+to the stream.
+
+```javascript
+// Write the data to the supplied writable stream 1MM times.
+// Be attentive to back-pressure.
+function writeOneMillionTimes(writer, data, encoding, callback) {
+  var i = 1000000;
+  write();
+  function write() {
+    var ok = true;
+    do {
+      i -= 1;
+      if (i === 0) {
+        // last time!
+        writer.write(data, encoding, callback);
+      } else {
+        // see if we should continue, or wait
+        // don't pass the callback, because we're not done yet.
+        ok = writer.write(data, encoding);
+      }
+    } while (i > 0 && ok);
+    if (i > 0) {
+      // had to stop early!
+      // write some more once it drains
+      writer.once('drain', write);
+    }
+  }
+}
+```
+
+#### writable.cork()
+
+Forces buffering of all writes.
+
+Buffered data will be flushed either at `.uncork()` or at `.end()` call.
+
+#### writable.uncork()
+
+Flush all data, buffered since `.cork()` call.
+
+#### writable.setDefaultEncoding(encoding)
+
+* `encoding` {String} The new default encoding
+
+Sets the default encoding for a writable stream.
+
+#### writable.end([chunk][, encoding][, callback])
+
+* `chunk` {String | Buffer} Optional data to write
+* `encoding` {String} The encoding, if `chunk` is a String
+* `callback` {Function} Optional callback for when the stream is finished
+
+Call this method when no more data will be written to the stream.  If
+supplied, the callback is attached as a listener on the `finish` event.
+
+Calling [`write()`][] after calling [`end()`][] will raise an error.
+
+```javascript
+// write 'hello, ' and then end with 'world!'
+var file = fs.createWriteStream('example.txt');
+file.write('hello, ');
+file.end('world!');
+// writing more now is not allowed!
+```
+
+#### Event: 'finish'
+
+When the [`end()`][] method has been called, and all data has been flushed
+to the underlying system, this event is emitted.
+
+```javascript
+var writer = getWritableStreamSomehow();
+for (var i = 0; i < 100; i ++) {
+  writer.write('hello, #' + i + '!\n');
+}
+writer.end('this is the end\n');
+writer.on('finish', function() {
+  console.error('all writes are now complete.');
+});
+```
+
+#### Event: 'pipe'
+
+* `src` {[Readable][] Stream} source stream that is piping to this writable
+
+This is emitted whenever the `pipe()` method is called on a readable
+stream, adding this writable to its set of destinations.
+
+```javascript
+var writer = getWritableStreamSomehow();
+var reader = getReadableStreamSomehow();
+writer.on('pipe', function(src) {
+  console.error('something is piping into the writer');
+  assert.equal(src, reader);
+});
+reader.pipe(writer);
+```
+
+#### Event: 'unpipe'
+
+* `src` {[Readable][] Stream} The source stream that [unpiped][] this writable
+
+This is emitted whenever the [`unpipe()`][] method is called on a
+readable stream, removing this writable from its set of destinations.
+
+```javascript
+var writer = getWritableStreamSomehow();
+var reader = getReadableStreamSomehow();
+writer.on('unpipe', function(src) {
+  console.error('something has stopped piping into the writer');
+  assert.equal(src, reader);
+});
+reader.pipe(writer);
+reader.unpipe(writer);
+```
+
+#### Event: 'error'
+
+* {Error object}
+
+Emitted if there was an error when writing or piping data.
+
+### Class: stream.Duplex
+
+Duplex streams are streams that implement both the [Readable][] and
+[Writable][] interfaces.  See above for usage.
+
+Examples of Duplex streams include:
+
+* [tcp sockets][]
+* [zlib streams][]
+* [crypto streams][]
+
+
+### Class: stream.Transform
+
+Transform streams are [Duplex][] streams where the output is in some way
+computed from the input.  They implement both the [Readable][] and
+[Writable][] interfaces.  See above for usage.
+
+Examples of Transform streams include:
+
+* [zlib streams][]
+* [crypto streams][]
+
+
+## API for Stream Implementors
+
+<!--type=misc-->
+
+To implement any sort of stream, the pattern is the same:
+
+1. Extend the appropriate parent class in your own subclass.  (The
+   [`util.inherits`][] method is particularly helpful for this.)
+2. Call the appropriate parent class constructor in your constructor,
+   to be sure that the internal mechanisms are set up properly.
+2. Implement one or more specific methods, as detailed below.
+
+The class to extend and the method(s) to implement depend on the sort
+of stream class you are writing:
+
+<table>
+  <thead>
+    <tr>
+      <th>
+        <p>Use-case</p>
+      </th>
+      <th>
+        <p>Class</p>
+      </th>
+      <th>
+        <p>Method(s) to implement</p>
+      </th>
+    </tr>
+  </thead>
+  <tr>
+    <td>
+      <p>Reading only</p>
+    </td>
+    <td>
+      <p>[Readable](#stream_class_stream_readable_1)</p>
+    </td>
+    <td>
+      <p><code>[_read][]</code></p>
+    </td>
+  </tr>
+  <tr>
+    <td>
+      <p>Writing only</p>
+    </td>
+    <td>
+      <p>[Writable](#stream_class_stream_writable_1)</p>
+    </td>
+    <td>
+      <p><code>[_write][]</code>, <code>_writev</code></p>
+    </td>
+  </tr>
+  <tr>
+    <td>
+      <p>Reading and writing</p>
+    </td>
+    <td>
+      <p>[Duplex](#stream_class_stream_duplex_1)</p>
+    </td>
+    <td>
+      <p><code>[_read][]</code>, <code>[_write][]</code>, <code>_writev</code></p>
+    </td>
+  </tr>
+  <tr>
+    <td>
+      <p>Operate on written data, then read the result</p>
+    </td>
+    <td>
+      <p>[Transform](#stream_class_stream_transform_1)</p>
+    </td>
+    <td>
+      <p><code>_transform</code>, <code>_flush</code></p>
+    </td>
+  </tr>
+</table>
+
+In your implementation code, it is very important to never call the
+methods described in [API for Stream Consumers][] above.  Otherwise, you
+can potentially cause adverse side effects in programs that consume
+your streaming interfaces.
+
+### Class: stream.Readable
+
+<!--type=class-->
+
+`stream.Readable` is an abstract class designed to be extended with an
+underlying implementation of the [`_read(size)`][] method.
+
+Please see above under [API for Stream Consumers][] for how to consume
+streams in your programs.  What follows is an explanation of how to
+implement Readable streams in your programs.
+
+#### Example: A Counting Stream
+
+<!--type=example-->
+
+This is a basic example of a Readable stream.  It emits the numerals
+from 1 to 1,000,000 in ascending order, and then ends.
+
+```javascript
+var Readable = require('stream').Readable;
+var util = require('util');
+util.inherits(Counter, Readable);
+
+function Counter(opt) {
+  Readable.call(this, opt);
+  this._max = 1000000;
+  this._index = 1;
+}
+
+Counter.prototype._read = function() {
+  var i = this._index++;
+  if (i > this._max)
+    this.push(null);
+  else {
+    var str = '' + i;
+    var buf = new Buffer(str, 'ascii');
+    this.push(buf);
+  }
+};
+```
+
+#### Example: SimpleProtocol v1 (Sub-optimal)
+
+This is similar to the `parseHeader` function described above, but
+implemented as a custom stream.  Also, note that this implementation
+does not convert the incoming data to a string.
+
+However, this would be better implemented as a [Transform][] stream.  See
+below for a better implementation.
+
+```javascript
+// A parser for a simple data protocol.
+// The "header" is a JSON object, followed by 2 \n characters, and
+// then a message body.
+//
+// NOTE: This can be done more simply as a Transform stream!
+// Using Readable directly for this is sub-optimal.  See the
+// alternative example below under the Transform section.
+
+var Readable = require('stream').Readable;
+var util = require('util');
+
+util.inherits(SimpleProtocol, Readable);
+
+function SimpleProtocol(source, options) {
+  if (!(this instanceof SimpleProtocol))
+    return new SimpleProtocol(source, options);
+
+  Readable.call(this, options);
+  this._inBody = false;
+  this._sawFirstCr = false;
+
+  // source is a readable stream, such as a socket or file
+  this._source = source;
+
+  var self = this;
+  source.on('end', function() {
+    self.push(null);
+  });
+
+  // give it a kick whenever the source is readable
+  // read(0) will not consume any bytes
+  source.on('readable', function() {
+    self.read(0);
+  });
+
+  this._rawHeader = [];
+  this.header = null;
+}
+
+SimpleProtocol.prototype._read = function(n) {
+  if (!this._inBody) {
+    var chunk = this._source.read();
+
+    // if the source doesn't have data, we don't have data yet.
+    if (chunk === null)
+      return this.push('');
+
+    // check if the chunk has a \n\n
+    var split = -1;
+    for (var i = 0; i < chunk.length; i++) {
+      if (chunk[i] === 10) { // '\n'
+        if (this._sawFirstCr) {
+          split = i;
+          break;
+        } else {
+          this._sawFirstCr = true;
+        }
+      } else {
+        this._sawFirstCr = false;
+      }
+    }
+
+    if (split === -1) {
+      // still waiting for the \n\n
+      // stash the chunk, and try again.
+      this._rawHeader.push(chunk);
+      this.push('');
+    } else {
+      this._inBody = true;
+      var h = chunk.slice(0, split);
+      this._rawHeader.push(h);
+      var header = Buffer.concat(this._rawHeader).toString();
+      try {
+        this.header = JSON.parse(header);
+      } catch (er) {
+        this.emit('error', new Error('invalid simple protocol data'));
+        return;
+      }
+      // now, because we got some extra data, unshift the rest
+      // back into the read queue so that our consumer will see it.
+      var b = chunk.slice(split);
+      this.unshift(b);
+
+      // and let them know that we are done parsing the header.
+      this.emit('header', this.header);
+    }
+  } else {
+    // from there on, just provide the data to our consumer.
+    // careful not to push(null), since that would indicate EOF.
+    var chunk = this._source.read();
+    if (chunk) this.push(chunk);
+  }
+};
+
+// Usage:
+// var parser = new SimpleProtocol(source);
+// Now parser is a readable stream that will emit 'header'
+// with the parsed header data.
+```
+
+
+#### new stream.Readable([options])
+
+* `options` {Object}
+  * `highWaterMark` {Number} The maximum number of bytes to store in
+    the internal buffer before ceasing to read from the underlying
+    resource.  Default=16kb, or 16 for `objectMode` streams
+  * `encoding` {String} If specified, then buffers will be decoded to
+    strings using the specified encoding.  Default=null
+  * `objectMode` {Boolean} Whether this stream should behave
+    as a stream of objects. Meaning that stream.read(n) returns
+    a single value instead of a Buffer of size n.  Default=false
+
+In classes that extend the Readable class, make sure to call the
+Readable constructor so that the buffering settings can be properly
+initialized.
+
+#### readable.\_read(size)
+
+* `size` {Number} Number of bytes to read asynchronously
+
+Note: **Implement this function, but do NOT call it directly.**
+
+This function should NOT be called directly.  It should be implemented
+by child classes, and only called by the internal Readable class
+methods.
+
+All Readable stream implementations must provide a `_read` method to
+fetch data from the underlying resource.
+
+This method is prefixed with an underscore because it is internal to
+the class that defines it, and should not be called directly by user
+programs.  However, you **are** expected to override this method in
+your own extension classes.
+
+When data is available, put it into the read queue by calling
+`readable.push(chunk)`.  If `push` returns false, then you should stop
+reading.  When `_read` is called again, you should start pushing more
+data.
+
+The `size` argument is advisory.  Implementations where a "read" is a
+single call that returns data can use this to know how much data to
+fetch.  Implementations where that is not relevant, such as TCP or
+TLS, may ignore this argument, and simply provide data whenever it
+becomes available.  There is no need, for example to "wait" until
+`size` bytes are available before calling [`stream.push(chunk)`][].
+
+#### readable.push(chunk[, encoding])
+
+* `chunk` {Buffer | null | String} Chunk of data to push into the read queue
+* `encoding` {String} Encoding of String chunks.  Must be a valid
+  Buffer encoding, such as `'utf8'` or `'ascii'`
+* return {Boolean} Whether or not more pushes should be performed
+
+Note: **This function should be called by Readable implementors, NOT
+by consumers of Readable streams.**
+
+The `_read()` function will not be called again until at least one
+`push(chunk)` call is made.
+
+The `Readable` class works by putting data into a read queue to be
+pulled out later by calling the `read()` method when the `'readable'`
+event fires.
+
+The `push()` method will explicitly insert some data into the read
+queue.  If it is called with `null` then it will signal the end of the
+data (EOF).
+
+This API is designed to be as flexible as possible.  For example,
+you may be wrapping a lower-level source which has some sort of
+pause/resume mechanism, and a data callback.  In those cases, you
+could wrap the low-level source object by doing something like this:
+
+```javascript
+// source is an object with readStop() and readStart() methods,
+// and an `ondata` member that gets called when it has data, and
+// an `onend` member that gets called when the data is over.
+
+util.inherits(SourceWrapper, Readable);
+
+function SourceWrapper(options) {
+  Readable.call(this, options);
+
+  this._source = getLowlevelSourceObject();
+  var self = this;
+
+  // Every time there's data, we push it into the internal buffer.
+  this._source.ondata = function(chunk) {
+    // if push() returns false, then we need to stop reading from source
+    if (!self.push(chunk))
+      self._source.readStop();
+  };
+
+  // When the source ends, we push the EOF-signaling `null` chunk
+  this._source.onend = function() {
+    self.push(null);
+  };
+}
+
+// _read will be called when the stream wants to pull more data in
+// the advisory size argument is ignored in this case.
+SourceWrapper.prototype._read = function(size) {
+  this._source.readStart();
+};
+```
+
+
+### Class: stream.Writable
+
+<!--type=class-->
+
+`stream.Writable` is an abstract class designed to be extended with an
+underlying implementation of the [`_write(chunk, encoding, callback)`][] method.
+
+Please see above under [API for Stream Consumers][] for how to consume
+writable streams in your programs.  What follows is an explanation of
+how to implement Writable streams in your programs.
+
+#### new stream.Writable([options])
+
+* `options` {Object}
+  * `highWaterMark` {Number} Buffer level when [`write()`][] starts
+    returning false. Default=16kb, or 16 for `objectMode` streams
+  * `decodeStrings` {Boolean} Whether or not to decode strings into
+    Buffers before passing them to [`_write()`][].  Default=true
+  * `objectMode` {Boolean} Whether or not the `write(anyObj)` is
+    a valid operation. If set you can write arbitrary data instead
+    of only `Buffer` / `String` data.  Default=false
+
+In classes that extend the Writable class, make sure to call the
+constructor so that the buffering settings can be properly
+initialized.
+
+#### writable.\_write(chunk, encoding, callback)
+
+* `chunk` {Buffer | String} The chunk to be written. Will **always**
+  be a buffer unless the `decodeStrings` option was set to `false`.
+* `encoding` {String} If the chunk is a string, then this is the
+  encoding type. If chunk is a buffer, then this is the special
+  value - 'buffer', ignore it in this case.
+* `callback` {Function} Call this function (optionally with an error
+  argument) when you are done processing the supplied chunk.
+
+All Writable stream implementations must provide a [`_write()`][]
+method to send data to the underlying resource.
+
+Note: **This function MUST NOT be called directly.**  It should be
+implemented by child classes, and called by the internal Writable
+class methods only.
+
+Call the callback using the standard `callback(error)` pattern to
+signal that the write completed successfully or with an error.
+
+If the `decodeStrings` flag is set in the constructor options, then
+`chunk` may be a string rather than a Buffer, and `encoding` will
+indicate the sort of string that it is.  This is to support
+implementations that have an optimized handling for certain string
+data encodings.  If you do not explicitly set the `decodeStrings`
+option to `false`, then you can safely ignore the `encoding` argument,
+and assume that `chunk` will always be a Buffer.
+
+This method is prefixed with an underscore because it is internal to
+the class that defines it, and should not be called directly by user
+programs.  However, you **are** expected to override this method in
+your own extension classes.
+
+#### writable.\_writev(chunks, callback)
+
+* `chunks` {Array} The chunks to be written.  Each chunk has following
+  format: `{ chunk: ..., encoding: ... }`.
+* `callback` {Function} Call this function (optionally with an error
+  argument) when you are done processing the supplied chunks.
+
+Note: **This function MUST NOT be called directly.**  It may be
+implemented by child classes, and called by the internal Writable
+class methods only.
+
+This function is completely optional to implement. In most cases it is
+unnecessary.  If implemented, it will be called with all the chunks
+that are buffered in the write queue.
+
+
+### Class: stream.Duplex
+
+<!--type=class-->
+
+A "duplex" stream is one that is both Readable and Writable, such as a
+TCP socket connection.
+
+Note that `stream.Duplex` is an abstract class designed to be extended
+with an underlying implementation of the `_read(size)` and
+[`_write(chunk, encoding, callback)`][] methods as you would with a
+Readable or Writable stream class.
+
+Since JavaScript doesn't have multiple prototypal inheritance, this
+class prototypally inherits from Readable, and then parasitically from
+Writable.  It is thus up to the user to implement both the lowlevel
+`_read(n)` method as well as the lowlevel
+[`_write(chunk, encoding, callback)`][] method on extension duplex classes.
+
+#### new stream.Duplex(options)
+
+* `options` {Object} Passed to both Writable and Readable
+  constructors. Also has the following fields:
+  * `allowHalfOpen` {Boolean} Default=true.  If set to `false`, then
+    the stream will automatically end the readable side when the
+    writable side ends and vice versa.
+  * `readableObjectMode` {Boolean} Default=false. Sets `objectMode`
+    for readable side of the stream. Has no effect if `objectMode`
+    is `true`.
+  * `writableObjectMode` {Boolean} Default=false. Sets `objectMode`
+    for writable side of the stream. Has no effect if `objectMode`
+    is `true`.
+
+In classes that extend the Duplex class, make sure to call the
+constructor so that the buffering settings can be properly
+initialized.
+
+
+### Class: stream.Transform
+
+A "transform" stream is a duplex stream where the output is causally
+connected in some way to the input, such as a [zlib][] stream or a
+[crypto][] stream.
+
+There is no requirement that the output be the same size as the input,
+the same number of chunks, or arrive at the same time.  For example, a
+Hash stream will only ever have a single chunk of output which is
+provided when the input is ended.  A zlib stream will produce output
+that is either much smaller or much larger than its input.
+
+Rather than implement the [`_read()`][] and [`_write()`][] methods, Transform
+classes must implement the `_transform()` method, and may optionally
+also implement the `_flush()` method.  (See below.)
+
+#### new stream.Transform([options])
+
+* `options` {Object} Passed to both Writable and Readable
+  constructors.
+
+In classes that extend the Transform class, make sure to call the
+constructor so that the buffering settings can be properly
+initialized.
+
+#### transform.\_transform(chunk, encoding, callback)
+
+* `chunk` {Buffer | String} The chunk to be transformed. Will **always**
+  be a buffer unless the `decodeStrings` option was set to `false`.
+* `encoding` {String} If the chunk is a string, then this is the
+  encoding type. If chunk is a buffer, then this is the special
+  value - 'buffer', ignore it in this case.
+* `callback` {Function} Call this function (optionally with an error
+  argument and data) when you are done processing the supplied chunk.
+
+Note: **This function MUST NOT be called directly.**  It should be
+implemented by child classes, and called by the internal Transform
+class methods only.
+
+All Transform stream implementations must provide a `_transform`
+method to accept input and produce output.
+
+`_transform` should do whatever has to be done in this specific
+Transform class, to handle the bytes being written, and pass them off
+to the readable portion of the interface.  Do asynchronous I/O,
+process things, and so on.
+
+Call `transform.push(outputChunk)` 0 or more times to generate output
+from this input chunk, depending on how much data you want to output
+as a result of this chunk.
+
+Call the callback function only when the current chunk is completely
+consumed.  Note that there may or may not be output as a result of any
+particular input chunk. If you supply output as the second argument to the
+callback, it will be passed to push method, in other words the following are
+equivalent:
+
+```javascript
+transform.prototype._transform = function (data, encoding, callback) {
+  this.push(data);
+  callback();
+}
+
+transform.prototype._transform = function (data, encoding, callback) {
+  callback(null, data);
+}
+```
+
+This method is prefixed with an underscore because it is internal to
+the class that defines it, and should not be called directly by user
+programs.  However, you **are** expected to override this method in
+your own extension classes.
+
+#### transform.\_flush(callback)
+
+* `callback` {Function} Call this function (optionally with an error
+  argument) when you are done flushing any remaining data.
+
+Note: **This function MUST NOT be called directly.**  It MAY be implemented
+by child classes, and if so, will be called by the internal Transform
+class methods only.
+
+In some cases, your transform operation may need to emit a bit more
+data at the end of the stream.  For example, a `Zlib` compression
+stream will store up some internal state so that it can optimally
+compress the output.  At the end, however, it needs to do the best it
+can with what is left, so that the data will be complete.
+
+In those cases, you can implement a `_flush` method, which will be
+called at the very end, after all the written data is consumed, but
+before emitting `end` to signal the end of the readable side.  Just
+like with `_transform`, call `transform.push(chunk)` zero or more
+times, as appropriate, and call `callback` when the flush operation is
+complete.
+
+This method is prefixed with an underscore because it is internal to
+the class that defines it, and should not be called directly by user
+programs.  However, you **are** expected to override this method in
+your own extension classes.
+
+#### Events: 'finish' and 'end'
+
+The [`finish`][] and [`end`][] events are from the parent Writable
+and Readable classes respectively. The `finish` event is fired after
+`.end()` is called and all chunks have been processed by `_transform`,
+`end` is fired after all data has been output which is after the callback
+in `_flush` has been called.
+
+#### Example: `SimpleProtocol` parser v2
+
+The example above of a simple protocol parser can be implemented
+simply by using the higher level [Transform][] stream class, similar to
+the `parseHeader` and `SimpleProtocol v1` examples above.
+
+In this example, rather than providing the input as an argument, it
+would be piped into the parser, which is a more idiomatic io.js stream
+approach.
+
+```javascript
+var util = require('util');
+var Transform = require('stream').Transform;
+util.inherits(SimpleProtocol, Transform);
+
+function SimpleProtocol(options) {
+  if (!(this instanceof SimpleProtocol))
+    return new SimpleProtocol(options);
+
+  Transform.call(this, options);
+  this._inBody = false;
+  this._sawFirstCr = false;
+  this._rawHeader = [];
+  this.header = null;
+}
+
+SimpleProtocol.prototype._transform = function(chunk, encoding, done) {
+  if (!this._inBody) {
+    // check if the chunk has a \n\n
+    var split = -1;
+    for (var i = 0; i < chunk.length; i++) {
+      if (chunk[i] === 10) { // '\n'
+        if (this._sawFirstCr) {
+          split = i;
+          break;
+        } else {
+          this._sawFirstCr = true;
+        }
+      } else {
+        this._sawFirstCr = false;
+      }
+    }
+
+    if (split === -1) {
+      // still waiting for the \n\n
+      // stash the chunk, and try again.
+      this._rawHeader.push(chunk);
+    } else {
+      this._inBody = true;
+      var h = chunk.slice(0, split);
+      this._rawHeader.push(h);
+      var header = Buffer.concat(this._rawHeader).toString();
+      try {
+        this.header = JSON.parse(header);
+      } catch (er) {
+        this.emit('error', new Error('invalid simple protocol data'));
+        return;
+      }
+      // and let them know that we are done parsing the header.
+      this.emit('header', this.header);
+
+      // now, because we got some extra data, emit this first.
+      this.push(chunk.slice(split));
+    }
+  } else {
+    // from there on, just provide the data to our consumer as-is.
+    this.push(chunk);
+  }
+  done();
+};
+
+// Usage:
+// var parser = new SimpleProtocol();
+// source.pipe(parser)
+// Now parser is a readable stream that will emit 'header'
+// with the parsed header data.
+```
+
+
+### Class: stream.PassThrough
+
+This is a trivial implementation of a [Transform][] stream that simply
+passes the input bytes across to the output.  Its purpose is mainly
+for examples and testing, but there are occasionally use cases where
+it can come in handy as a building block for novel sorts of streams.
+
+
+## Simplified Constructor API
+
+<!--type=misc-->
+
+In simple cases there is now the added benefit of being able to construct a stream without inheritance.
+
+This can be done by passing the appropriate methods as constructor options:
+
+Examples:
+
+### Readable
+```javascript
+var readable = new stream.Readable({
+  read: function(n) {
+    // sets this._read under the hood
+  }
+});
+```
+
+### Writable
+```javascript
+var writable = new stream.Writable({
+  write: function(chunk, encoding, next) {
+    // sets this._write under the hood
+  }
+});
+
+// or
+
+var writable = new stream.Writable({
+  writev: function(chunks, next) {
+    // sets this._writev under the hood
+  }
+});
+```
+
+### Duplex
+```javascript
+var duplex = new stream.Duplex({
+  read: function(n) {
+    // sets this._read under the hood
+  },
+  write: function(chunk, encoding, next) {
+    // sets this._write under the hood
+  }
+});
+
+// or
+
+var duplex = new stream.Duplex({
+  read: function(n) {
+    // sets this._read under the hood
+  },
+  writev: function(chunks, next) {
+    // sets this._writev under the hood
+  }
+});
+```
+
+### Transform
+```javascript
+var transform = new stream.Transform({
+  transform: function(chunk, encoding, next) {
+    // sets this._transform under the hood
+  },
+  flush: function(done) {
+    // sets this._flush under the hood
+  }
+});
+```
+
+## Streams: Under the Hood
+
+<!--type=misc-->
+
+### Buffering
+
+<!--type=misc-->
+
+Both Writable and Readable streams will buffer data on an internal
+object called `_writableState.buffer` or `_readableState.buffer`,
+respectively.
+
+The amount of data that will potentially be buffered depends on the
+`highWaterMark` option which is passed into the constructor.
+
+Buffering in Readable streams happens when the implementation calls
+[`stream.push(chunk)`][].  If the consumer of the Stream does not call
+`stream.read()`, then the data will sit in the internal queue until it
+is consumed.
+
+Buffering in Writable streams happens when the user calls
+[`stream.write(chunk)`][] repeatedly, even when `write()` returns `false`.
+
+The purpose of streams, especially with the `pipe()` method, is to
+limit the buffering of data to acceptable levels, so that sources and
+destinations of varying speed will not overwhelm the available memory.
+
+### `stream.read(0)`
+
+There are some cases where you want to trigger a refresh of the
+underlying readable stream mechanisms, without actually consuming any
+data.  In that case, you can call `stream.read(0)`, which will always
+return null.
+
+If the internal read buffer is below the `highWaterMark`, and the
+stream is not currently reading, then calling `read(0)` will trigger
+a low-level `_read` call.
+
+There is almost never a need to do this.  However, you will see some
+cases in io.js's internals where this is done, particularly in the
+Readable stream class internals.
+
+### `stream.push('')`
+
+Pushing a zero-byte string or Buffer (when not in [Object mode][]) has an
+interesting side effect.  Because it *is* a call to
+[`stream.push()`][], it will end the `reading` process.  However, it
+does *not* add any data to the readable buffer, so there's nothing for
+a user to consume.
+
+Very rarely, there are cases where you have no data to provide now,
+but the consumer of your stream (or, perhaps, another bit of your own
+code) will know when to check again, by calling `stream.read(0)`.  In
+those cases, you *may* call `stream.push('')`.
+
+So far, the only use case for this functionality is in the
+[tls.CryptoStream][] class, which is deprecated in io.js v1.0.  If you
+find that you have to use `stream.push('')`, please consider another
+approach, because it almost certainly indicates that something is
+horribly wrong.
+
+### Compatibility with Older Node.js Versions
+
+<!--type=misc-->
+
+In versions of Node.js prior to v0.10, the Readable stream interface was
+simpler, but also less powerful and less useful.
+
+* Rather than waiting for you to call the `read()` method, `'data'`
+  events would start emitting immediately.  If you needed to do some
+  I/O to decide how to handle data, then you had to store the chunks
+  in some kind of buffer so that they would not be lost.
+* The [`pause()`][] method was advisory, rather than guaranteed.  This
+  meant that you still had to be prepared to receive `'data'` events
+  even when the stream was in a paused state.
+
+In io.js v1.0 and Node.js v0.10, the Readable class described below was added.
+For backwards compatibility with older Node.js programs, Readable streams
+switch into "flowing mode" when a `'data'` event handler is added, or
+when the [`resume()`][] method is called.  The effect is that, even if
+you are not using the new `read()` method and `'readable'` event, you
+no longer have to worry about losing `'data'` chunks.
+
+Most programs will continue to function normally.  However, this
+introduces an edge case in the following conditions:
+
+* No [`'data'` event][] handler is added.
+* The [`resume()`][] method is never called.
+* The stream is not piped to any writable destination.
+
+For example, consider the following code:
+
+```javascript
+// WARNING!  BROKEN!
+net.createServer(function(socket) {
+
+  // we add an 'end' method, but never consume the data
+  socket.on('end', function() {
+    // It will never get here.
+    socket.end('I got your message (but didnt read it)\n');
+  });
+
+}).listen(1337);
+```
+
+In versions of Node.js prior to v0.10, the incoming message data would be
+simply discarded.  However, in io.js v1.0 and Node.js v0.10 and beyond,
+the socket will remain paused forever.
+
+The workaround in this situation is to call the `resume()` method to
+start the flow of data:
+
+```javascript
+// Workaround
+net.createServer(function(socket) {
+
+  socket.on('end', function() {
+    socket.end('I got your message (but didnt read it)\n');
+  });
+
+  // start the flow of data, discarding it.
+  socket.resume();
+
+}).listen(1337);
+```
+
+In addition to new Readable streams switching into flowing mode,
+pre-v0.10 style streams can be wrapped in a Readable class using the
+`wrap()` method.
+
+
+### Object Mode
+
+<!--type=misc-->
+
+Normally, Streams operate on Strings and Buffers exclusively.
+
+Streams that are in **object mode** can emit generic JavaScript values
+other than Buffers and Strings.
+
+A Readable stream in object mode will always return a single item from
+a call to `stream.read(size)`, regardless of what the size argument
+is.
+
+A Writable stream in object mode will always ignore the `encoding`
+argument to `stream.write(data, encoding)`.
+
+The special value `null` still retains its special value for object
+mode streams.  That is, for object mode readable streams, `null` as a
+return value from `stream.read()` indicates that there is no more
+data, and [`stream.push(null)`][] will signal the end of stream data
+(`EOF`).
+
+No streams in io.js core are object mode streams.  This pattern is only
+used by userland streaming libraries.
+
+You should set `objectMode` in your stream child class constructor on
+the options object.  Setting `objectMode` mid-stream is not safe.
+
+For Duplex streams `objectMode` can be set exclusively for readable or
+writable side with `readableObjectMode` and `writableObjectMode`
+respectively. These options can be used to implement parsers and
+serializers with Transform streams.
+
+```javascript
+var util = require('util');
+var StringDecoder = require('string_decoder').StringDecoder;
+var Transform = require('stream').Transform;
+util.inherits(JSONParseStream, Transform);
+
+// Gets \n-delimited JSON string data, and emits the parsed objects
+function JSONParseStream() {
+  if (!(this instanceof JSONParseStream))
+    return new JSONParseStream();
+
+  Transform.call(this, { readableObjectMode : true });
+
+  this._buffer = '';
+  this._decoder = new StringDecoder('utf8');
+}
+
+JSONParseStream.prototype._transform = function(chunk, encoding, cb) {
+  this._buffer += this._decoder.write(chunk);
+  // split on newlines
+  var lines = this._buffer.split(/\r?\n/);
+  // keep the last partial line buffered
+  this._buffer = lines.pop();
+  for (var l = 0; l < lines.length; l++) {
+    var line = lines[l];
+    try {
+      var obj = JSON.parse(line);
+    } catch (er) {
+      this.emit('error', er);
+      return;
+    }
+    // push the parsed object out to the readable consumer
+    this.push(obj);
+  }
+  cb();
+};
+
+JSONParseStream.prototype._flush = function(cb) {
+  // Just handle any leftover
+  var rem = this._buffer.trim();
+  if (rem) {
+    try {
+      var obj = JSON.parse(rem);
+    } catch (er) {
+      this.emit('error', er);
+      return;
+    }
+    // push the parsed object out to the readable consumer
+    this.push(obj);
+  }
+  cb();
+};
+```
+
+
+[EventEmitter]: https://iojs.org/dist/v2.3.0/doc/api/events.html#events_class_events_eventemitter
+[Object mode]: #stream_object_mode
+[`stream.push(chunk)`]: #stream_readable_push_chunk_encoding
+[`stream.push(null)`]: #stream_readable_push_chunk_encoding
+[`stream.push()`]: #stream_readable_push_chunk_encoding
+[`unpipe()`]: #stream_readable_unpipe_destination
+[unpiped]: #stream_readable_unpipe_destination
+[tcp sockets]: https://iojs.org/dist/v2.3.0/doc/api/net.html#net_class_net_socket
+[zlib streams]: zlib.html
+[zlib]: zlib.html
+[crypto streams]: crypto.html
+[crypto]: crypto.html
+[tls.CryptoStream]: https://iojs.org/dist/v2.3.0/doc/api/tls.html#tls_class_cryptostream
+[process.stdin]: https://iojs.org/dist/v2.3.0/doc/api/process.html#process_process_stdin
+[stdout]: https://iojs.org/dist/v2.3.0/doc/api/process.html#process_process_stdout
+[process.stdout]: https://iojs.org/dist/v2.3.0/doc/api/process.html#process_process_stdout
+[process.stderr]: https://iojs.org/dist/v2.3.0/doc/api/process.html#process_process_stderr
+[child process stdout and stderr]: https://iojs.org/dist/v2.3.0/doc/api/child_process.html#child_process_child_stdout
+[API for Stream Consumers]: #stream_api_for_stream_consumers
+[API for Stream Implementors]: #stream_api_for_stream_implementors
+[Readable]: #stream_class_stream_readable
+[Writable]: #stream_class_stream_writable
+[Duplex]: #stream_class_stream_duplex
+[Transform]: #stream_class_stream_transform
+[`end`]: #stream_event_end
+[`finish`]: #stream_event_finish
+[`_read(size)`]: #stream_readable_read_size_1
+[`_read()`]: #stream_readable_read_size_1
+[_read]: #stream_readable_read_size_1
+[`writable.write(chunk)`]: #stream_writable_write_chunk_encoding_callback
+[`write(chunk, encoding, callback)`]: #stream_writable_write_chunk_encoding_callback
+[`write()`]: #stream_writable_write_chunk_encoding_callback
+[`stream.write(chunk)`]: #stream_writable_write_chunk_encoding_callback
+[`_write(chunk, encoding, callback)`]: #stream_writable_write_chunk_encoding_callback_1
+[`_write()`]: #stream_writable_write_chunk_encoding_callback_1
+[_write]: #stream_writable_write_chunk_encoding_callback_1
+[`util.inherits`]: https://iojs.org/dist/v2.3.0/doc/api/util.html#util_util_inherits_constructor_superconstructor
+[`end()`]: #stream_writable_end_chunk_encoding_callback
+[`'data'` event]: #stream_event_data
+[`resume()`]: #stream_readable_resume
+[`readable.resume()`]: #stream_readable_resume
+[`pause()`]: #stream_readable_pause
+[`unpipe()`]: #stream_readable_unpipe_destination
+[`pipe()`]: #stream_readable_pipe_destination_options
diff --git a/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/doc/wg-meetings/2015-01-30.md b/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/doc/wg-meetings/2015-01-30.md
new file mode 100644 (file)
index 0000000..c141a99
--- /dev/null
@@ -0,0 +1,58 @@
+# streams WG Meeting 2015-01-30
+
+## Links
+
+* **Google Hangouts Video**: http://www.youtube.com/watch?v=I9nDOSGfwZg
+* **GitHub Issue**: https://github.com/iojs/readable-stream/issues/106
+* **Original Minutes Google Doc**: https://docs.google.com/document/d/17aTgLnjMXIrfjgNaTUnHQO7m3xgzHR2VXBTmi03Qii4/
+
+## Agenda
+
+Extracted from https://github.com/iojs/readable-stream/labels/wg-agenda prior to meeting.
+
+* adopt a charter [#105](https://github.com/iojs/readable-stream/issues/105)
+* release and versioning strategy [#101](https://github.com/iojs/readable-stream/issues/101)
+* simpler stream creation [#102](https://github.com/iojs/readable-stream/issues/102)
+* proposal: deprecate implicit flowing of streams [#99](https://github.com/iojs/readable-stream/issues/99)
+
+## Minutes
+
+### adopt a charter
+
+* group: +1's all around
+
+### What versioning scheme should be adopted?
+* group: +1’s 3.0.0
+* domenic+group: pulling in patches from other sources where appropriate
+* mikeal: version independently, suggesting versions for io.js
+* mikeal+domenic: work with TC to notify in advance of changes
+simpler stream creation
+
+### streamline creation of streams
+* sam: streamline creation of streams
+* domenic: nice simple solution posted
+  but, we lose the opportunity to change the model
+  may not be backwards incompatible (double check keys)
+
+  **action item:** domenic will check
+
+### remove implicit flowing of streams on(‘data’)
+* add isFlowing / isPaused
+* mikeal: worrying that we’re documenting polyfill methods – confuses users
+* domenic: more reflective API is probably good, with warning labels for users
+* new section for mad scientists (reflective stream access)
+* calvin: name the “third state”
+* mikeal: maybe borrow the name from whatwg?
+* domenic: we’re missing the “third state”
+* consensus: kind of difficult to name the third state
+* mikeal: figure out differences in states / compat
+* mathias: always flow on data – eliminates third state
+  * explore what it breaks
+
+**action items:**
+* ask isaac for ability to list packages by what public io.js APIs they use (esp. Stream)
+* ask rod/build for infrastructure
+* **chris**: explore the “flow on data” approach
+* add isPaused/isFlowing
+* add new docs section
+* move isPaused to that section
index b513d61..69558af 100644 (file)
@@ -1,30 +1,9 @@
-// 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;
+'use strict';
 
 /*<replacement>*/
 var objectKeys = Object.keys || function (obj) {
@@ -35,6 +14,14 @@ var objectKeys = Object.keys || function (obj) {
 /*</replacement>*/
 
 
+module.exports = Duplex;
+
+/*<replacement>*/
+var processNextTick = require('process-nextick-args');
+/*</replacement>*/
+
+
+
 /*<replacement>*/
 var util = require('core-util-is');
 util.inherits = require('inherits');
@@ -45,10 +32,12 @@ var Writable = require('./_stream_writable');
 
 util.inherits(Duplex, Readable);
 
-forEach(objectKeys(Writable.prototype), function(method) {
+var keys = objectKeys(Writable.prototype);
+for (var v = 0; v < keys.length; v++) {
+  var method = keys[v];
   if (!Duplex.prototype[method])
     Duplex.prototype[method] = Writable.prototype[method];
-});
+}
 
 function Duplex(options) {
   if (!(this instanceof Duplex))
@@ -79,7 +68,11 @@ function onend() {
 
   // no more data can be written.
   // But allow more writes to happen in this tick.
-  process.nextTick(this.end.bind(this));
+  processNextTick(onEndNT, this);
+}
+
+function onEndNT(self) {
+  self.end();
 }
 
 function forEach (xs, f) {
index 895ca50..bddfdd0 100644 (file)
@@ -1,28 +1,9 @@
-// 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.
 
+'use strict';
+
 module.exports = PassThrough;
 
 var Transform = require('./_stream_transform');
index 6307220..eef3d82 100644 (file)
@@ -1,27 +1,13 @@
-// 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.
+'use strict';
 
 module.exports = Readable;
 
 /*<replacement>*/
+var processNextTick = require('process-nextick-args');
+/*</replacement>*/
+
+
+/*<replacement>*/
 var isArray = require('isarray');
 /*</replacement>*/
 
@@ -40,24 +26,57 @@ if (!EE.listenerCount) EE.listenerCount = function(emitter, type) {
 };
 /*</replacement>*/
 
-var Stream = require('stream');
+
+
+/*<replacement>*/
+var Stream;
+(function (){try{
+  Stream = require('st' + 'ream');
+}catch(_){}finally{
+  if (!Stream)
+    Stream = require('events').EventEmitter;
+}}())
+/*</replacement>*/
+
+var Buffer = require('buffer').Buffer;
 
 /*<replacement>*/
 var util = require('core-util-is');
 util.inherits = require('inherits');
 /*</replacement>*/
 
+
+
+/*<replacement>*/
+var debug = require('util');
+if (debug && debug.debuglog) {
+  debug = debug.debuglog('stream');
+} else {
+  debug = function () {};
+}
+/*</replacement>*/
+
 var StringDecoder;
 
 util.inherits(Readable, Stream);
 
 function ReadableState(options, stream) {
+  var Duplex = require('./_stream_duplex');
+
   options = options || {};
 
+  // 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;
+
+  if (stream instanceof Duplex)
+    this.objectMode = this.objectMode || !!options.readableObjectMode;
+
   // 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 = this.objectMode ? 16 : 16 * 1024;
+  this.highWaterMark = (hwm || hwm === 0) ? hwm : defaultHwm;
 
   // cast to ints.
   this.highWaterMark = ~~this.highWaterMark;
@@ -66,19 +85,13 @@ function ReadableState(options, stream) {
   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;
@@ -89,11 +102,6 @@ function ReadableState(options, stream) {
   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.
@@ -120,6 +128,8 @@ function ReadableState(options, stream) {
 }
 
 function Readable(options) {
+  var Duplex = require('./_stream_duplex');
+
   if (!(this instanceof Readable))
     return new Readable(options);
 
@@ -128,6 +138,9 @@ function Readable(options) {
   // legacy
   this.readable = true;
 
+  if (options && typeof options.read === 'function')
+    this._read = options.read;
+
   Stream.call(this);
 }
 
@@ -138,7 +151,7 @@ function Readable(options) {
 Readable.prototype.push = function(chunk, encoding) {
   var state = this._readableState;
 
-  if (typeof chunk === 'string' && !state.objectMode) {
+  if (!state.objectMode && typeof chunk === 'string') {
     encoding = encoding || state.defaultEncoding;
     if (encoding !== state.encoding) {
       chunk = new Buffer(chunk, encoding);
@@ -155,14 +168,17 @@ Readable.prototype.unshift = function(chunk) {
   return readableAddChunk(this, state, chunk, '', true);
 };
 
+Readable.prototype.isPaused = function() {
+  return this._readableState.flowing === false;
+};
+
 function readableAddChunk(stream, state, chunk, encoding, addToFront) {
   var er = chunkInvalid(state, chunk);
   if (er) {
     stream.emit('error', er);
-  } else if (chunk === null || chunk === undefined) {
+  } else if (chunk === null) {
     state.reading = false;
-    if (!state.ended)
-      onEofChunk(stream, state);
+    onEofChunk(stream, state);
   } else if (state.objectMode || chunk && chunk.length > 0) {
     if (state.ended && !addToFront) {
       var e = new Error('stream.push() after EOF');
@@ -174,17 +190,24 @@ function readableAddChunk(stream, state, chunk, encoding, addToFront) {
       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 +240,7 @@ Readable.prototype.setEncoding = function(enc) {
     StringDecoder = require('string_decoder/').StringDecoder;
   this._readableState.decoder = new StringDecoder(enc);
   this._readableState.encoding = enc;
+  return this;
 };
 
 // Don't raise the hwm > 128MB
@@ -263,8 +287,9 @@ function howMuchToRead(n, state) {
     if (!state.ended) {
       state.needReadable = true;
       return 0;
-    } else
+    } else {
       return state.length;
+    }
   }
 
   return n;
@@ -272,10 +297,9 @@ function howMuchToRead(n, state) {
 
 // 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)
     state.emittedReadable = false;
@@ -286,7 +310,11 @@ Readable.prototype.read = function(n) {
   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 +322,9 @@ Readable.prototype.read = function(n) {
 
   // 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 [<Buffer >, <Buffer 00 ...>].
-    // howMuchToRead will see this and coerce the amount to
-    // read to zero (because it's looking at the length of the
-    // first <Buffer > 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 +351,23 @@ Readable.prototype.read = function(n) {
 
   // 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,12 +378,12 @@ Readable.prototype.read = function(n) {
     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
@@ -386,19 +401,20 @@ Readable.prototype.read = function(n) {
   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 (ret !== null)
+    this.emit('data', ret);
+
   return ret;
 };
 
 function chunkInvalid(state, chunk) {
   var er = null;
-  if (!Buffer.isBuffer(chunk) &&
-      'string' !== typeof chunk &&
+  if (!(Buffer.isBuffer(chunk)) &&
+      typeof chunk !== 'string' &&
       chunk !== null &&
       chunk !== undefined &&
       !state.objectMode) {
@@ -409,7 +425,8 @@ function chunkInvalid(state, chunk) {
 
 
 function onEofChunk(stream, state) {
-  if (state.decoder && !state.ended) {
+  if (state.ended) return;
+  if (state.decoder) {
     var chunk = state.decoder.end();
     if (chunk && chunk.length) {
       state.buffer.push(chunk);
@@ -418,12 +435,8 @@ function onEofChunk(stream, state) {
   }
   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 +445,20 @@ function onEofChunk(stream, state) {
 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)
+      processNextTick(emitReadable_, stream);
+    else
       emitReadable_(stream);
-    });
-  else
-    emitReadable_(stream);
+  }
 }
 
 function emitReadable_(stream) {
+  debug('emit readable');
   stream.emit('readable');
+  flow(stream);
 }
 
 
@@ -458,9 +471,7 @@ function emitReadable_(stream) {
 function maybeReadMore(stream, state) {
   if (!state.readingMore) {
     state.readingMore = true;
-    process.nextTick(function() {
-      maybeReadMore_(stream, state);
-    });
+    processNextTick(maybeReadMore_, stream, state);
   }
 }
 
@@ -468,6 +479,7 @@ function maybeReadMore_(stream, state) {
   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 +514,7 @@ Readable.prototype.pipe = function(dest, pipeOpts) {
       break;
   }
   state.pipesCount += 1;
+  debug('pipe count=%d opts=%j', state.pipesCount, pipeOpts);
 
   var doEnd = (!pipeOpts || pipeOpts.end !== false) &&
               dest !== process.stdout &&
@@ -509,17 +522,20 @@ Readable.prototype.pipe = function(dest, pipeOpts) {
 
   var endFn = doEnd ? onend : cleanup;
   if (state.endEmitted)
-    process.nextTick(endFn);
+    processNextTick(endFn);
   else
     src.once('end', endFn);
 
   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 +547,7 @@ Readable.prototype.pipe = function(dest, pipeOpts) {
   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 +556,34 @@ Readable.prototype.pipe = function(dest, pipeOpts) {
     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 +607,14 @@ Readable.prototype.pipe = function(dest, pipeOpts) {
   }
   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 +623,8 @@ Readable.prototype.pipe = function(dest, pipeOpts) {
 
   // 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 +632,15 @@ Readable.prototype.pipe = function(dest, pipeOpts) {
 
 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 +663,6 @@ Readable.prototype.unpipe = function(dest) {
     // got a match.
     state.pipes = null;
     state.pipesCount = 0;
-    this.removeListener('readable', pipeOnReadable);
     state.flowing = false;
     if (dest)
       dest.emit('unpipe', this);
@@ -700,7 +677,6 @@ Readable.prototype.unpipe = function(dest) {
     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 +704,11 @@ Readable.prototype.unpipe = function(dest) {
 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 +717,7 @@ Readable.prototype.on = function(ev, fn) {
       state.emittedReadable = false;
       state.needReadable = true;
       if (!state.reading) {
-        this.read(0);
+        processNextTick(nReadingNextTick, this);
       } else if (state.length) {
         emitReadable(this, state);
       }
@@ -749,66 +728,61 @@ Readable.prototype.on = function(ev, fn) {
 };
 Readable.prototype.addListener = Readable.prototype.on;
 
+function nReadingNextTick(self) {
+  debug('readable nexttick read 0');
+  self.read(0);
+}
+
 // 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');
+  var state = this._readableState;
+  if (!state.flowing) {
+    debug('resume');
+    state.flowing = true;
+    resume(this, state);
+  }
+  return this;
 };
 
-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.');
+function resume(stream, state) {
+  if (!state.resumeScheduled) {
+    state.resumeScheduled = true;
+    processNextTick(resume_, stream, state);
   }
+}
 
-  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);
+function resume_(stream, state) {
+  if (!state.reading) {
+    debug('resume read 0');
+    stream.read(0);
+  }
 
-    if (c === null) {
-      readable = false;
-      stream._readableState.needReadable = true;
-    }
-  });
+  state.resumeScheduled = false;
+  stream.emit('resume');
+  flow(stream);
+  if (state.flowing && !state.reading)
+    stream.read(0);
+}
 
-  stream.pause = function() {
-    paused = true;
+Readable.prototype.pause = function() {
+  debug('call pause flowing=%j', this._readableState.flowing);
+  if (false !== this._readableState.flowing) {
+    debug('pause');
+    this._readableState.flowing = false;
     this.emit('pause');
-  };
-
-  stream.resume = function() {
-    paused = false;
-    if (readable)
-      process.nextTick(function() {
-        stream.emit('readable');
-      });
-    else
-      this.read(0);
-    this.emit('resume');
-  };
+  }
+  return this;
+};
 
-  // now make it start, just in case it hadn't already.
-  stream.emit('readable');
+function flow(stream) {
+  var state = stream._readableState;
+  debug('flow', state.flowing);
+  if (state.flowing) {
+    do {
+      var chunk = stream.read();
+    } while (null !== chunk && state.flowing);
+  }
 }
 
 // wrap an old-style stream as the async data source.
@@ -820,6 +794,7 @@ Readable.prototype.wrap = function(stream) {
 
   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,11 +805,11 @@ Readable.prototype.wrap = function(stream) {
   });
 
   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))
@@ -850,11 +825,10 @@ Readable.prototype.wrap = function(stream) {
   // 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 (this[i] === undefined && typeof stream[i] === 'function') {
       this[i] = function(method) { return function() {
         return stream[method].apply(stream, arguments);
-      }}(i);
+      }}(i);
     }
   }
 
@@ -867,6 +841,7 @@ Readable.prototype.wrap = function(stream) {
   // 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,16 +930,18 @@ function endReadable(stream) {
   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.
-      if (!state.endEmitted && state.length === 0) {
-        state.endEmitted = true;
-        stream.readable = false;
-        stream.emit('end');
-      }
-    });
+    processNextTick(endReadableNT, state, stream);
+  }
+}
+
+function endReadableNT(state, stream) {
+  // Check that we didn't get one last unshift.
+  if (!state.endEmitted && state.length === 0) {
+    state.endEmitted = true;
+    stream.readable = false;
+    stream.emit('end');
   }
 }
 
index eb188df..3675d18 100644 (file)
@@ -1,25 +1,3 @@
-// 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
@@ -62,6 +40,8 @@
 // would be consumed, and then the rest would wait (un-transformed) until
 // the results of the previous transformed chunk were consumed.
 
+'use strict';
+
 module.exports = Transform;
 
 var Duplex = require('./_stream_duplex');
@@ -74,7 +54,7 @@ util.inherits = require('inherits');
 util.inherits(Transform, Duplex);
 
 
-function TransformState(options, stream) {
+function TransformState(stream) {
   this.afterTransform = function(er, data) {
     return afterTransform(stream, er, data);
   };
@@ -117,7 +97,7 @@ function Transform(options) {
 
   Duplex.call(this, options);
 
-  var ts = this._transformState = new TransformState(options, this);
+  this._transformState = new TransformState(this);
 
   // when the writable side finishes, then flush out anything remaining.
   var stream = this;
@@ -130,8 +110,16 @@ function Transform(options) {
   // sync guard flag.
   this._readableState.sync = false;
 
-  this.once('finish', function() {
-    if ('function' === typeof this._flush)
+  if (options) {
+    if (typeof options.transform === 'function')
+      this._transform = options.transform;
+
+    if (typeof options.flush === 'function')
+      this._flush = options.flush;
+  }
+
+  this.once('prefinish', function() {
+    if (typeof this._flush === 'function')
       this._flush(function(er) {
         done(stream, er);
       });
@@ -197,7 +185,6 @@ function done(stream, 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)
index 4bdaa4f..b232952 100644 (file)
@@ -1,31 +1,17 @@
-// 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.
 
+'use strict';
+
 module.exports = Writable;
 
 /*<replacement>*/
+var processNextTick = require('process-nextick-args');
+/*</replacement>*/
+
+
+/*<replacement>*/
 var Buffer = require('buffer').Buffer;
 /*</replacement>*/
 
@@ -37,28 +23,49 @@ var util = require('core-util-is');
 util.inherits = require('inherits');
 /*</replacement>*/
 
-var Stream = require('stream');
+
+
+/*<replacement>*/
+var Stream;
+(function (){try{
+  Stream = require('st' + 'ream');
+}catch(_){}finally{
+  if (!Stream)
+    Stream = require('events').EventEmitter;
+}}())
+/*</replacement>*/
+
+var Buffer = require('buffer').Buffer;
 
 util.inherits(Writable, Stream);
 
+function nop() {}
+
 function WriteReq(chunk, encoding, cb) {
   this.chunk = chunk;
   this.encoding = encoding;
   this.callback = cb;
+  this.next = null;
 }
 
 function WritableState(options, stream) {
+  var Duplex = require('./_stream_duplex');
+
   options = options || {};
 
+  // 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;
+
   // 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;
+  var defaultHwm = this.objectMode ? 16 : 16 * 1024;
+  this.highWaterMark = (hwm || hwm === 0) ? hwm : defaultHwm;
 
   // cast to ints.
   this.highWaterMark = ~~this.highWaterMark;
@@ -90,8 +97,11 @@ function WritableState(options, stream) {
   // 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;
@@ -112,12 +122,41 @@ function WritableState(options, stream) {
   // the amount that is being written when _write is called.
   this.writelen = 0;
 
-  this.buffer = [];
+  this.bufferedRequest = null;
+  this.lastBufferedRequest = null;
+
+  // 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;
 }
 
+WritableState.prototype.getBuffer = function writableStateGetBuffer() {
+  var current = this.bufferedRequest;
+  var out = [];
+  while (current) {
+    out.push(current);
+    current = current.next;
+  }
+  return out;
+};
+
+(function (){try {
+Object.defineProperty(WritableState.prototype, 'buffer', {
+  get: require('util-deprecate')(function() {
+    return this.getBuffer();
+  }, '_writableState.buffer is deprecated. Use ' +
+      '_writableState.getBuffer() instead.')
+});
+}catch(_){}}());
+
+
 function Writable(options) {
   var Duplex = require('./_stream_duplex');
 
@@ -131,6 +170,14 @@ function Writable(options) {
   // legacy.
   this.writable = true;
 
+  if (options) {
+    if (typeof options.write === 'function')
+      this._write = options.write;
+
+    if (typeof options.writev === 'function')
+      this._writev = options.writev;
+  }
+
   Stream.call(this);
 }
 
@@ -140,13 +187,11 @@ Writable.prototype.pipe = function() {
 };
 
 
-function writeAfterEnd(stream, state, cb) {
+function writeAfterEnd(stream, 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);
-  });
+  processNextTick(cb, er);
 }
 
 // If we get something that is not a buffer, string, null, or undefined,
@@ -156,16 +201,15 @@ function writeAfterEnd(stream, state, cb) {
 // how many bytes or characters.
 function validChunk(stream, state, chunk, cb) {
   var valid = true;
-  if (!Buffer.isBuffer(chunk) &&
-      'string' !== typeof chunk &&
+
+  if (!(Buffer.isBuffer(chunk)) &&
+      typeof chunk !== 'string' &&
       chunk !== null &&
       chunk !== undefined &&
       !state.objectMode) {
     var er = new TypeError('Invalid non-string/buffer chunk');
     stream.emit('error', er);
-    process.nextTick(function() {
-      cb(er);
-    });
+    processNextTick(cb, er);
     valid = false;
   }
   return valid;
@@ -186,16 +230,50 @@ Writable.prototype.write = function(chunk, encoding, cb) {
     encoding = state.defaultEncoding;
 
   if (typeof cb !== 'function')
-    cb = function() {};
+    cb = nop;
 
   if (state.ended)
-    writeAfterEnd(this, state, cb);
-  else if (validChunk(this, state, chunk, cb))
+    writeAfterEnd(this, 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.bufferedRequest)
+      clearBuffer(this, state);
+  }
+};
+
+Writable.prototype.setDefaultEncoding = function setDefaultEncoding(encoding) {
+  // node::ParseEncoding() requires lower case.
+  if (typeof encoding === 'string')
+    encoding = encoding.toLowerCase();
+  if (!(['hex', 'utf8', 'utf-8', 'ascii', 'binary', 'base64',
+'ucs2', 'ucs-2','utf16le', 'utf-16le', 'raw']
+.indexOf((encoding + '').toLowerCase()) > -1))
+    throw new TypeError('Unknown encoding: ' + encoding);
+  this._writableState.defaultEncoding = encoding;
+};
+
 function decodeChunk(state, chunk, encoding) {
   if (!state.objectMode &&
       state.decodeStrings !== false &&
@@ -210,6 +288,7 @@ function decodeChunk(state, chunk, encoding) {
 // 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;
@@ -221,28 +300,37 @@ function writeOrBuffer(stream, state, chunk, encoding, cb) {
   if (!ret)
     state.needDrain = true;
 
-  if (state.writing)
-    state.buffer.push(new WriteReq(chunk, encoding, cb));
-  else
-    doWrite(stream, state, len, chunk, encoding, cb);
+  if (state.writing || state.corked) {
+    var last = state.lastBufferedRequest;
+    state.lastBufferedRequest = new WriteReq(chunk, encoding, cb);
+    if (last) {
+      last.next = state.lastBufferedRequest;
+    } else {
+      state.bufferedRequest = state.lastBufferedRequest;
+    }
+  } else {
+    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) {
+  --state.pendingcb;
   if (sync)
-    process.nextTick(function() {
-      cb(er);
-    });
+    processNextTick(cb, er);
   else
     cb(er);
 
@@ -268,15 +356,17 @@ function onwrite(stream, 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);
+    var finished = needFinish(state);
 
-    if (!finished && !state.bufferProcessing && state.buffer.length)
+    if (!finished &&
+        !state.corked &&
+        !state.bufferProcessing &&
+        state.bufferedRequest) {
       clearBuffer(stream, state);
+    }
 
     if (sync) {
-      process.nextTick(function() {
-        afterWrite(stream, state, finished, cb);
-      });
+      processNextTick(afterWrite, stream, state, finished, cb);
     } else {
       afterWrite(stream, state, finished, cb);
     }
@@ -286,9 +376,9 @@ function onwrite(stream, er) {
 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
@@ -305,37 +395,62 @@ function onwriteDrain(stream, state) {
 // if there's something in the buffer waiting, then process it
 function clearBuffer(stream, state) {
   state.bufferProcessing = true;
+  var entry = state.bufferedRequest;
+
+  if (stream._writev && entry && entry.next) {
+    // Fast case, write everything using _writev()
+    var buffer = [];
+    var cbs = [];
+    while (entry) {
+      cbs.push(entry.callback);
+      buffer.push(entry);
+      entry = entry.next;
+    }
 
-  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;
+    // count the one we are adding, as well.
+    // TODO(isaacs) clean this up
+    state.pendingcb++;
+    state.lastBufferedRequest = null;
+    doWrite(stream, state, true, state.length, buffer, '', function(err) {
+      for (var i = 0; i < cbs.length; i++) {
+        state.pendingcb--;
+        cbs[i](err);
+      }
+    });
+
+    // Clear buffer
+  } else {
+    // Slow case, write chunks one-by-one
+    while (entry) {
+      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);
+      entry = entry.next;
+      // 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) {
+        break;
+      }
     }
-  }
 
+    if (entry === null)
+      state.lastBufferedRequest = null;
+  }
+  state.bufferedRequest = entry;
   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;
 
@@ -348,27 +463,46 @@ Writable.prototype.end = function(chunk, encoding, cb) {
     encoding = null;
   }
 
-  if (typeof chunk !== 'undefined' && chunk !== null)
+  if (chunk !== null && chunk !== undefined)
     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);
 };
 
 
-function needFinish(stream, state) {
+function needFinish(state) {
   return (state.ending &&
           state.length === 0 &&
+          state.bufferedRequest === null &&
           !state.finished &&
           !state.writing);
 }
 
+function prefinish(stream, state) {
+  if (!state.prefinished) {
+    state.prefinished = true;
+    stream.emit('prefinish');
+  }
+}
+
 function finishMaybe(stream, state) {
-  var need = needFinish(stream, state);
+  var need = needFinish(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;
 }
@@ -378,7 +512,7 @@ function endWritable(stream, state, cb) {
   finishMaybe(stream, state);
   if (cb) {
     if (state.finished)
-      process.nextTick(cb);
+      processNextTick(cb);
     else
       stream.once('finish', cb);
   }
index b673333..466dfdf 100644 (file)
   },
   "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#readme",
+  "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",
-  "_from": "core-util-is@>=1.0.0 <1.1.0"
+  "_resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.1.tgz"
 }
index fb1eb37..19228ab 100644 (file)
     "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 &lt;julian@juliangruber.com&gt;\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",
-  "bugs": {
-    "url": "https://github.com/juliangruber/isarray/issues"
-  },
   "_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",
-  "_from": "isarray@0.0.1"
+  "bugs": {
+    "url": "https://github.com/juliangruber/isarray/issues"
+  },
+  "readme": "ERROR: No README data found!"
 }
diff --git a/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/process-nextick-args/.travis.yml b/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/process-nextick-args/.travis.yml
new file mode 100644 (file)
index 0000000..5ac9885
--- /dev/null
@@ -0,0 +1,7 @@
+language: node_js
+node_js:
+  - "0.8"
+  - "0.10"
+  - "0.11"
+  - "0.12"
+  - "iojs"
diff --git a/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/process-nextick-args/index.js b/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/process-nextick-args/index.js
new file mode 100644 (file)
index 0000000..3eb2f33
--- /dev/null
@@ -0,0 +1,13 @@
+'use strict';
+module.exports = nextTick;
+
+function nextTick(fn) {
+  var args = new Array(arguments.length - 1);
+  var i = 0;
+  while (i < arguments.length) {
+    args[i++] = arguments[i];
+  }
+  process.nextTick(function afterTick() {
+    fn.apply(null, args);
+  });
+}
diff --git a/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/process-nextick-args/package.json b/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/process-nextick-args/package.json
new file mode 100644 (file)
index 0000000..9be9ed5
--- /dev/null
@@ -0,0 +1,45 @@
+{
+  "name": "process-nextick-args",
+  "version": "1.0.2",
+  "description": "process.nextTick but always with args",
+  "main": "index.js",
+  "scripts": {
+    "test": "node test.js"
+  },
+  "repository": {
+    "type": "git",
+    "url": "git+https://github.com/calvinmetcalf/process-nextick-args.git"
+  },
+  "author": "",
+  "license": "MIT",
+  "bugs": {
+    "url": "https://github.com/calvinmetcalf/process-nextick-args/issues"
+  },
+  "homepage": "https://github.com/calvinmetcalf/process-nextick-args",
+  "devDependencies": {
+    "tap": "~0.2.6"
+  },
+  "gitHead": "295707643b4ed6667c1afb71ffb6101669b5dac2",
+  "_id": "process-nextick-args@1.0.2",
+  "_shasum": "8b4d3fc586668bd5b6573e732edf2b71c1c1d8aa",
+  "_from": "process-nextick-args@>=1.0.0 <1.1.0",
+  "_npmVersion": "2.11.1",
+  "_nodeVersion": "2.3.0",
+  "_npmUser": {
+    "name": "cwmma",
+    "email": "calvin.metcalf@gmail.com"
+  },
+  "dist": {
+    "shasum": "8b4d3fc586668bd5b6573e732edf2b71c1c1d8aa",
+    "tarball": "http://registry.npmjs.org/process-nextick-args/-/process-nextick-args-1.0.2.tgz"
+  },
+  "maintainers": [
+    {
+      "name": "cwmma",
+      "email": "calvin.metcalf@gmail.com"
+    }
+  ],
+  "directories": {},
+  "_resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-1.0.2.tgz",
+  "readme": "ERROR: No README data found!"
+}
diff --git a/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/process-nextick-args/readme.md b/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/process-nextick-args/readme.md
new file mode 100644 (file)
index 0000000..78e7cfa
--- /dev/null
@@ -0,0 +1,18 @@
+process-nextick-args
+=====
+
+[![Build Status](https://travis-ci.org/calvinmetcalf/process-nextick-args.svg?branch=master)](https://travis-ci.org/calvinmetcalf/process-nextick-args)
+
+```bash
+npm install --save process-nextick-args
+```
+
+Always be able to pass arguments to process.nextTick, no matter the platform
+
+```js
+var nextTick = require('process-nextick-args');
+
+nextTick(function (a, b, c) {
+  console.log(a, b, c);
+}, 'step', 3,  'profit');
+```
diff --git a/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/process-nextick-args/test.js b/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/process-nextick-args/test.js
new file mode 100644 (file)
index 0000000..729f775
--- /dev/null
@@ -0,0 +1,17 @@
+var test = require("tap").test;
+var nextTick = require('./');
+
+test('should work', function (t) {
+  t.plan(5);
+  nextTick(function (a) {
+    t.ok(a);
+    nextTick(function (thing) {
+      t.equals(thing, 7);
+    }, 7);
+  }, true);
+  nextTick(function (a, b, c) {
+    t.equals(a, 'step');
+    t.equals(b, 3);
+    t.equals(c, 'profit');
+  }, 'step', 3,  'profit');
+});
index ee70702..0364d54 100644 (file)
     "browserify"
   ],
   "license": "MIT",
-  "readme": "**string_decoder.js** (`require('string_decoder')`) from Node.js core\n\nCopyright Joyent, Inc. and other Node contributors. See LICENCE file for details.\n\nVersion 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.**\n\nThe *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.",
-  "readmeFilename": "README.md",
+  "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",
-  "_from": "string_decoder@>=0.10.0 <0.11.0"
+  "readme": "ERROR: No README data found!"
 }
diff --git a/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/util-deprecate/History.md b/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/util-deprecate/History.md
new file mode 100644 (file)
index 0000000..ec01029
--- /dev/null
@@ -0,0 +1,11 @@
+
+1.0.1 / 2014-11-25
+==================
+
+  * browser: use `console.warn()` for deprecation calls
+  * browser: more jsdocs
+
+1.0.0 / 2014-04-30
+==================
+
+  * initial commit
diff --git a/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/util-deprecate/LICENSE b/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/util-deprecate/LICENSE
new file mode 100644 (file)
index 0000000..6a60e8c
--- /dev/null
@@ -0,0 +1,24 @@
+(The MIT License)
+
+Copyright (c) 2014 Nathan Rajlich <nathan@tootallnate.net>
+
+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 --git a/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/util-deprecate/README.md b/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/util-deprecate/README.md
new file mode 100644 (file)
index 0000000..75622fa
--- /dev/null
@@ -0,0 +1,53 @@
+util-deprecate
+==============
+### The Node.js `util.deprecate()` function with browser support
+
+In Node.js, this module simply re-exports the `util.deprecate()` function.
+
+In the web browser (i.e. via browserify), a browser-specific implementation
+of the `util.deprecate()` function is used.
+
+
+## API
+
+A `deprecate()` function is the only thing exposed by this module.
+
+``` javascript
+// setup:
+exports.foo = deprecate(foo, 'foo() is deprecated, use bar() instead');
+
+
+// users see:
+foo();
+// foo() is deprecated, use bar() instead
+foo();
+foo();
+```
+
+
+## License
+
+(The MIT License)
+
+Copyright (c) 2014 Nathan Rajlich <nathan@tootallnate.net>
+
+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 --git a/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/util-deprecate/browser.js b/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/util-deprecate/browser.js
new file mode 100644 (file)
index 0000000..55fa5a4
--- /dev/null
@@ -0,0 +1,62 @@
+
+/**
+ * Module exports.
+ */
+
+module.exports = deprecate;
+
+/**
+ * Mark that a method should not be used.
+ * Returns a modified function which warns once by default.
+ *
+ * If `localStorage.noDeprecation = true` is set, then it is a no-op.
+ *
+ * If `localStorage.throwDeprecation = true` is set, then deprecated functions
+ * will throw an Error when invoked.
+ *
+ * If `localStorage.traceDeprecation = true` is set, then deprecated functions
+ * will invoke `console.trace()` instead of `console.error()`.
+ *
+ * @param {Function} fn - the function to deprecate
+ * @param {String} msg - the string to print to the console when `fn` is invoked
+ * @returns {Function} a new "deprecated" version of `fn`
+ * @api public
+ */
+
+function deprecate (fn, msg) {
+  if (config('noDeprecation')) {
+    return fn;
+  }
+
+  var warned = false;
+  function deprecated() {
+    if (!warned) {
+      if (config('throwDeprecation')) {
+        throw new Error(msg);
+      } else if (config('traceDeprecation')) {
+        console.trace(msg);
+      } else {
+        console.warn(msg);
+      }
+      warned = true;
+    }
+    return fn.apply(this, arguments);
+  }
+
+  return deprecated;
+}
+
+/**
+ * Checks `localStorage` for boolean values for the given `name`.
+ *
+ * @param {String} name
+ * @returns {Boolean}
+ * @api private
+ */
+
+function config (name) {
+  if (!global.localStorage) return false;
+  var val = global.localStorage[name];
+  if (null == val) return false;
+  return String(val).toLowerCase() === 'true';
+}
diff --git a/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/util-deprecate/node.js b/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/util-deprecate/node.js
new file mode 100644 (file)
index 0000000..5e6fcff
--- /dev/null
@@ -0,0 +1,6 @@
+
+/**
+ * For Node.js, simply re-export the core `util.deprecate` function.
+ */
+
+module.exports = require('util').deprecate;
diff --git a/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/util-deprecate/package.json b/deps/npm/node_modules/request/node_modules/bl/node_modules/readable-stream/node_modules/util-deprecate/package.json
new file mode 100644 (file)
index 0000000..ea487da
--- /dev/null
@@ -0,0 +1,53 @@
+{
+  "name": "util-deprecate",
+  "version": "1.0.1",
+  "description": "The Node.js `util.deprecate()` function with browser support",
+  "main": "node.js",
+  "browser": "browser.js",
+  "scripts": {
+    "test": "echo \"Error: no test specified\" && exit 1"
+  },
+  "repository": {
+    "type": "git",
+    "url": "git://github.com/TooTallNate/util-deprecate.git"
+  },
+  "keywords": [
+    "util",
+    "deprecate",
+    "browserify",
+    "browser",
+    "node"
+  ],
+  "author": {
+    "name": "Nathan Rajlich",
+    "email": "nathan@tootallnate.net",
+    "url": "http://n8.io/"
+  },
+  "license": "MIT",
+  "bugs": {
+    "url": "https://github.com/TooTallNate/util-deprecate/issues"
+  },
+  "homepage": "https://github.com/TooTallNate/util-deprecate",
+  "gitHead": "6e923f7d98a0afbe5b9c7db9d0f0029c1936746c",
+  "_id": "util-deprecate@1.0.1",
+  "_shasum": "3556a3d13c4c6aa7983d7e2425478197199b7881",
+  "_from": "util-deprecate@>=1.0.1 <1.1.0",
+  "_npmVersion": "1.4.28",
+  "_npmUser": {
+    "name": "tootallnate",
+    "email": "nathan@tootallnate.net"
+  },
+  "maintainers": [
+    {
+      "name": "tootallnate",
+      "email": "nathan@tootallnate.net"
+    }
+  ],
+  "dist": {
+    "shasum": "3556a3d13c4c6aa7983d7e2425478197199b7881",
+    "tarball": "http://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.1.tgz"
+  },
+  "directories": {},
+  "_resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.1.tgz",
+  "readme": "ERROR: No README data found!"
+}
index d4c12ca..70ad998 100644 (file)
@@ -1,23 +1,28 @@
 {
   "name": "readable-stream",
-  "version": "1.0.33",
-  "description": "Streams2, a user-land copy of the stream library from Node.js v0.10.x",
+  "version": "2.0.2",
+  "description": "Streams3, a user-land copy of the stream library from iojs v2.x",
   "main": "readable.js",
   "dependencies": {
     "core-util-is": "~1.0.0",
+    "inherits": "~2.0.1",
     "isarray": "0.0.1",
+    "process-nextick-args": "~1.0.0",
     "string_decoder": "~0.10.x",
-    "inherits": "~2.0.1"
+    "util-deprecate": "~1.0.1"
   },
   "devDependencies": {
-    "tap": "~0.2.6"
+    "tap": "~0.2.6",
+    "tape": "~4.0.0",
+    "zuul": "~3.0.0"
   },
   "scripts": {
-    "test": "tap test/simple/*.js"
+    "test": "tap test/parallel/*.js",
+    "browser": "zuul --browser-name $BROWSER_NAME --browser-version $BROWSER_VERSION -- test/browser.js"
   },
   "repository": {
     "type": "git",
-    "url": "git://github.com/isaacs/readable-stream.git"
+    "url": "git://github.com/nodejs/readable-stream.git"
   },
   "keywords": [
     "readable",
   "browser": {
     "util": false
   },
-  "author": {
-    "name": "Isaac Z. Schlueter",
-    "email": "i@izs.me",
-    "url": "http://blog.izs.me/"
-  },
   "license": "MIT",
-  "readme": "# readable-stream\n\n***Node-core streams for userland***\n\n[![NPM](https://nodei.co/npm/readable-stream.png?downloads=true&downloadRank=true)](https://nodei.co/npm/readable-stream/)\n[![NPM](https://nodei.co/npm-dl/readable-stream.png?&months=6&height=3)](https://nodei.co/npm/readable-stream/)\n\nThis package is a mirror of the Streams2 and Streams3 implementations in Node-core.\n\nIf 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.\n\n**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.\n\n**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\"`\n\n",
-  "readmeFilename": "README.md",
+  "gitHead": "1a70134a71196eeabb5e27bc7580faaa68d30513",
   "bugs": {
-    "url": "https://github.com/isaacs/readable-stream/issues"
+    "url": "https://github.com/nodejs/readable-stream/issues"
+  },
+  "homepage": "https://github.com/nodejs/readable-stream#readme",
+  "_id": "readable-stream@2.0.2",
+  "_shasum": "bec81beae8cf455168bc2e5b2b31f5bcfaed9b1b",
+  "_from": "readable-stream@>=2.0.0 <2.1.0",
+  "_npmVersion": "2.11.1",
+  "_nodeVersion": "2.3.0",
+  "_npmUser": {
+    "name": "cwmma",
+    "email": "calvin.metcalf@gmail.com"
   },
-  "homepage": "https://github.com/isaacs/readable-stream#readme",
-  "_id": "readable-stream@1.0.33",
-  "_shasum": "3a360dd66c1b1d7fd4705389860eda1d0f61126c",
-  "_resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-1.0.33.tgz",
-  "_from": "readable-stream@>=1.0.26 <1.1.0"
+  "dist": {
+    "shasum": "bec81beae8cf455168bc2e5b2b31f5bcfaed9b1b",
+    "tarball": "http://registry.npmjs.org/readable-stream/-/readable-stream-2.0.2.tgz"
+  },
+  "maintainers": [
+    {
+      "name": "isaacs",
+      "email": "isaacs@npmjs.com"
+    },
+    {
+      "name": "tootallnate",
+      "email": "nathan@tootallnate.net"
+    },
+    {
+      "name": "rvagg",
+      "email": "rod@vagg.org"
+    },
+    {
+      "name": "cwmma",
+      "email": "calvin.metcalf@gmail.com"
+    }
+  ],
+  "directories": {},
+  "_resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.0.2.tgz",
+  "readme": "ERROR: No README data found!"
 }
index 8b5337b..6222a57 100644 (file)
@@ -1,6 +1,10 @@
-var Stream = require('stream'); // hack to fix a circular dependency issue when used with browserify
+var Stream = (function (){
+  try {
+    return require('st' + 'ream'); // hack to fix a circular dependency issue when used with browserify
+  } catch(_){}
+}());
 exports = module.exports = require('./lib/_stream_readable.js');
-exports.Stream = Stream;
+exports.Stream = Stream || exports;
 exports.Readable = exports;
 exports.Writable = require('./lib/_stream_writable.js');
 exports.Duplex = require('./lib/_stream_duplex.js');
index d693008..1513847 100644 (file)
@@ -1,6 +1,6 @@
 {
   "name": "bl",
-  "version": "0.9.4",
+  "version": "1.0.0",
   "description": "Buffer List: collect buffers and access with a standard readable Buffer interface, streamable too!",
   "main": "bl.js",
   "scripts": {
@@ -25,7 +25,7 @@
   ],
   "license": "MIT",
   "dependencies": {
-    "readable-stream": "~1.0.26"
+    "readable-stream": "~2.0.0"
   },
   "devDependencies": {
     "tape": "~2.12.3",
     "faucet": "~0.0.1",
     "brtapsauce": "~0.3.0"
   },
-  "readme": "# bl *(BufferList)*\n\n**A Node.js Buffer list collector, reader and streamer thingy.**\n\n[![NPM](https://nodei.co/npm/bl.png?downloads=true&downloadRank=true)](https://nodei.co/npm/bl/)\n[![NPM](https://nodei.co/npm-dl/bl.png?months=6&height=3)](https://nodei.co/npm/bl/)\n\n**bl** is a storage object for collections of Node Buffers, exposing them with the main Buffer readable API. Also works as a duplex stream so you can collect buffers from a stream that emits them and emit buffers to a stream that consumes them!\n\nThe original buffers are kept intact and copies are only done as necessary. Any reads that require the use of a single original buffer will return a slice of that buffer only (which references the same memory as the original buffer). Reads that span buffers perform concatenation as required and return the results transparently.\n\n```js\nconst BufferList = require('bl')\n\nvar bl = new BufferList()\nbl.append(new Buffer('abcd'))\nbl.append(new Buffer('efg'))\nbl.append('hi')                     // bl will also accept & convert Strings\nbl.append(new Buffer('j'))\nbl.append(new Buffer([ 0x3, 0x4 ]))\n\nconsole.log(bl.length) // 12\n\nconsole.log(bl.slice(0, 10).toString('ascii')) // 'abcdefghij'\nconsole.log(bl.slice(3, 10).toString('ascii')) // 'defghij'\nconsole.log(bl.slice(3, 6).toString('ascii'))  // 'def'\nconsole.log(bl.slice(3, 8).toString('ascii'))  // 'defgh'\nconsole.log(bl.slice(5, 10).toString('ascii')) // 'fghij'\n\n// or just use toString!\nconsole.log(bl.toString())               // 'abcdefghij\\u0003\\u0004'\nconsole.log(bl.toString('ascii', 3, 8))  // 'defgh'\nconsole.log(bl.toString('ascii', 5, 10)) // 'fghij'\n\n// other standard Buffer readables\nconsole.log(bl.readUInt16BE(10)) // 0x0304\nconsole.log(bl.readUInt16LE(10)) // 0x0403\n```\n\nGive it a callback in the constructor and use it just like **[concat-stream](https://github.com/maxogden/node-concat-stream)**:\n\n```js\nconst bl = require('bl')\n    , fs = require('fs')\n\nfs.createReadStream('README.md')\n  .pipe(bl(function (err, data) { // note 'new' isn't strictly required\n    // `data` is a complete Buffer object containing the full data\n    console.log(data.toString())\n  }))\n```\n\nNote that when you use the *callback* method like this, the resulting `data` parameter is a concatenation of all `Buffer` objects in the list. If you want to avoid the overhead of this concatenation (in cases of extreme performance consciousness), then avoid the *callback* method and just listen to `'end'` instead, like a standard Stream.\n\nOr to fetch a URL using [hyperquest](https://github.com/substack/hyperquest) (should work with [request](http://github.com/mikeal/request) and even plain Node http too!):\n```js\nconst hyperquest = require('hyperquest')\n    , bl         = require('bl')\n    , url        = 'https://raw.github.com/rvagg/bl/master/README.md'\n\nhyperquest(url).pipe(bl(function (err, data) {\n  console.log(data.toString())\n}))\n```\n\nOr, use it as a readable stream to recompose a list of Buffers to an output source:\n\n```js\nconst BufferList = require('bl')\n    , fs         = require('fs')\n\nvar bl = new BufferList()\nbl.append(new Buffer('abcd'))\nbl.append(new Buffer('efg'))\nbl.append(new Buffer('hi'))\nbl.append(new Buffer('j'))\n\nbl.pipe(fs.createWriteStream('gibberish.txt'))\n```\n\n## API\n\n  * <a href=\"#ctor\"><code><b>new BufferList([ callback ])</b></code></a>\n  * <a href=\"#length\"><code>bl.<b>length</b></code></a>\n  * <a href=\"#append\"><code>bl.<b>append(buffer)</b></code></a>\n  * <a href=\"#get\"><code>bl.<b>get(index)</b></code></a>\n  * <a href=\"#slice\"><code>bl.<b>slice([ start[, end ] ])</b></code></a>\n  * <a href=\"#copy\"><code>bl.<b>copy(dest, [ destStart, [ srcStart [, srcEnd ] ] ])</b></code></a>\n  * <a href=\"#duplicate\"><code>bl.<b>duplicate()</b></code></a>\n  * <a href=\"#consume\"><code>bl.<b>consume(bytes)</b></code></a>\n  * <a href=\"#toString\"><code>bl.<b>toString([encoding, [ start, [ end ]]])</b></code></a>\n  * <a href=\"#readXX\"><code>bl.<b>readDoubleBE()</b></code>, <code>bl.<b>readDoubleLE()</b></code>, <code>bl.<b>readFloatBE()</b></code>, <code>bl.<b>readFloatLE()</b></code>, <code>bl.<b>readInt32BE()</b></code>, <code>bl.<b>readInt32LE()</b></code>, <code>bl.<b>readUInt32BE()</b></code>, <code>bl.<b>readUInt32LE()</b></code>, <code>bl.<b>readInt16BE()</b></code>, <code>bl.<b>readInt16LE()</b></code>, <code>bl.<b>readUInt16BE()</b></code>, <code>bl.<b>readUInt16LE()</b></code>, <code>bl.<b>readInt8()</b></code>, <code>bl.<b>readUInt8()</b></code></a>\n  * <a href=\"#streams\">Streams</a>\n\n--------------------------------------------------------\n<a name=\"ctor\"></a>\n### new BufferList([ callback | buffer | buffer array ])\nThe constructor takes an optional callback, if supplied, the callback will be called with an error argument followed by a reference to the **bl** instance, when `bl.end()` is called (i.e. from a piped stream). This is a convenient method of collecting the entire contents of a stream, particularly when the stream is *chunky*, such as a network stream.\n\nNormally, no arguments are required for the constructor, but you can initialise the list by passing in a single `Buffer` object or an array of `Buffer` object.\n\n`new` is not strictly required, if you don't instantiate a new object, it will be done automatically for you so you can create a new instance simply with:\n\n```js\nvar bl = require('bl')\nvar myinstance = bl()\n\n// equivilant to:\n\nvar BufferList = require('bl')\nvar myinstance = new BufferList()\n```\n\n--------------------------------------------------------\n<a name=\"length\"></a>\n### bl.length\nGet the length of the list in bytes. This is the sum of the lengths of all of the buffers contained in the list, minus any initial offset for a semi-consumed buffer at the beginning. Should accurately represent the total number of bytes that can be read from the list.\n\n--------------------------------------------------------\n<a name=\"append\"></a>\n### bl.append(buffer)\n`append(buffer)` adds an additional buffer or BufferList to the internal list.\n\n--------------------------------------------------------\n<a name=\"get\"></a>\n### bl.get(index)\n`get()` will return the byte at the specified index.\n\n--------------------------------------------------------\n<a name=\"slice\"></a>\n### bl.slice([ start, [ end ] ])\n`slice()` returns a new `Buffer` object containing the bytes within the range specified. Both `start` and `end` are optional and will default to the beginning and end of the list respectively.\n\nIf the requested range spans a single internal buffer then a slice of that buffer will be returned which shares the original memory range of that Buffer. If the range spans multiple buffers then copy operations will likely occur to give you a uniform Buffer.\n\n--------------------------------------------------------\n<a name=\"copy\"></a>\n### bl.copy(dest, [ destStart, [ srcStart [, srcEnd ] ] ])\n`copy()` copies the content of the list in the `dest` buffer, starting from `destStart` and containing the bytes within the range specified with `srcStart` to `srcEnd`. `destStart`, `start` and `end` are optional and will default to the beginning of the `dest` buffer, and the beginning and end of the list respectively.\n\n--------------------------------------------------------\n<a name=\"duplicate\"></a>\n### bl.duplicate()\n`duplicate()` performs a **shallow-copy** of the list. The internal Buffers remains the same, so if you change the underlying Buffers, the change will be reflected in both the original and the duplicate. This method is needed if you want to call `consume()` or `pipe()` and still keep the original list.Example:\n\n```js\nvar bl = new BufferList()\n\nbl.append('hello')\nbl.append(' world')\nbl.append('\\n')\n\nbl.duplicate().pipe(process.stdout, { end: false })\n\nconsole.log(bl.toString())\n```\n\n--------------------------------------------------------\n<a name=\"consume\"></a>\n### bl.consume(bytes)\n`consume()` will shift bytes *off the start of the list*. The number of bytes consumed don't need to line up with the sizes of the internal Buffers&mdash;initial offsets will be calculated accordingly in order to give you a consistent view of the data.\n\n--------------------------------------------------------\n<a name=\"toString\"></a>\n### bl.toString([encoding, [ start, [ end ]]])\n`toString()` will return a string representation of the buffer. The optional `start` and `end` arguments are passed on to `slice()`, while the `encoding` is passed on to `toString()` of the resulting Buffer. See the [Buffer#toString()](http://nodejs.org/docs/latest/api/buffer.html#buffer_buf_tostring_encoding_start_end) documentation for more information.\n\n--------------------------------------------------------\n<a name=\"readXX\"></a>\n### 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()\n\nAll of the standard byte-reading methods of the `Buffer` interface are implemented and will operate across internal Buffer boundaries transparently.\n\nSee the <b><code>[Buffer](http://nodejs.org/docs/latest/api/buffer.html)</code></b> documentation for how these work.\n\n--------------------------------------------------------\n<a name=\"streams\"></a>\n### Streams\n**bl** is a Node **[Duplex Stream](http://nodejs.org/docs/latest/api/stream.html#stream_class_stream_duplex)**, so it can be read from and written to like a standard Node stream. You can also `pipe()` to and from a **bl** instance.\n\n--------------------------------------------------------\n\n## Contributors\n\n**bl** is brought to you by the following hackers:\n\n * [Rod Vagg](https://github.com/rvagg)\n * [Matteo Collina](https://github.com/mcollina)\n * [Jarett Cruger](https://github.com/jcrugzz)\n\n=======\n\n<a name=\"license\"></a>\n## License &amp; copyright\n\nCopyright (c) 2013-2014 bl contributors (listed above).\n\nbl is licensed under the MIT license. All rights not explicitly granted in the MIT license are reserved. See the included LICENSE.md file for more details.\n",
-  "readmeFilename": "README.md",
+  "gitHead": "1794938be6697a6d1e02cd942a4eea59b353347a",
   "bugs": {
     "url": "https://github.com/rvagg/bl/issues"
   },
-  "_id": "bl@0.9.4",
-  "_shasum": "4702ddf72fbe0ecd82787c00c113aea1935ad0e7",
-  "_resolved": "https://registry.npmjs.org/bl/-/bl-0.9.4.tgz",
-  "_from": "bl@>=0.9.0 <0.10.0"
+  "_id": "bl@1.0.0",
+  "_shasum": "ada9a8a89a6d7ac60862f7dec7db207873e0c3f5",
+  "_from": "bl@>=1.0.0 <1.1.0",
+  "_npmVersion": "2.9.0",
+  "_nodeVersion": "2.0.1-nightly20150618d2e4e03444",
+  "_npmUser": {
+    "name": "rvagg",
+    "email": "rod@vagg.org"
+  },
+  "maintainers": [
+    {
+      "name": "rvagg",
+      "email": "rod@vagg.org"
+    }
+  ],
+  "dist": {
+    "shasum": "ada9a8a89a6d7ac60862f7dec7db207873e0c3f5",
+    "tarball": "http://registry.npmjs.org/bl/-/bl-1.0.0.tgz"
+  },
+  "directories": {},
+  "_resolved": "https://registry.npmjs.org/bl/-/bl-1.0.0.tgz",
+  "readme": "ERROR: No README data found!"
 }
diff --git a/deps/npm/node_modules/request/node_modules/caseless/LICENSE b/deps/npm/node_modules/request/node_modules/caseless/LICENSE
new file mode 100644 (file)
index 0000000..61789f4
--- /dev/null
@@ -0,0 +1,28 @@
+Apache License
+Version 2.0, January 2004
+http://www.apache.org/licenses/
+TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
+1. Definitions.
+"License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document.
+"Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License.
+"Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity.
+"You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License.
+"Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files.
+"Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types.
+"Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below).
+"Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof.
+"Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution."
+"Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work.
+2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form.
+3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed.
+4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions:
+You must give any other recipients of the Work or Derivative Works a copy of this License; and
+You must cause any modified files to carry prominent notices stating that You changed the files; and
+You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and
+If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License. You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License.
+5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions.
+6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file.
+7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License.
+8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages.
+9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability.
+END OF TERMS AND CONDITIONS
\ No newline at end of file
index ba711f6..d86a70e 100644 (file)
@@ -49,6 +49,7 @@ module.exports = function (dict) {return new Caseless(dict)}
 module.exports.httpify = function (resp, headers) {
   var c = new Caseless(headers)
   resp.setHeader = function (key, value, clobber) {
+    if (typeof value === 'undefined') return
     return c.set(key, value, clobber)
   }
   resp.hasHeader = function (key) {
index d4c0177..2cd79ea 100644 (file)
@@ -1,6 +1,6 @@
 {
   "name": "caseless",
-  "version": "0.10.0",
+  "version": "0.11.0",
   "description": "Caseless object set/get/has, very useful when working with HTTP headers.",
   "main": "index.js",
   "scripts": {
     "name": "Mikeal Rogers",
     "email": "mikeal.rogers@gmail.com"
   },
-  "license": "BSD",
+  "license": "Apache-2.0",
   "bugs": {
     "url": "https://github.com/mikeal/caseless/issues"
   },
   "devDependencies": {
     "tape": "^2.10.2"
   },
-  "gitHead": "9c85efef6c37d48923b79f3f282441414dd691c9",
-  "homepage": "https://github.com/mikeal/caseless",
-  "_id": "caseless@0.10.0",
-  "_shasum": "ed6b2719adcd1fd18f58dc081c0f1a5b43963909",
-  "_from": "caseless@>=0.10.0 <0.11.0",
-  "_npmVersion": "1.4.14",
+  "gitHead": "c578232a02cc2b46b6da8851caf57fdbfac89ff5",
+  "homepage": "https://github.com/mikeal/caseless#readme",
+  "_id": "caseless@0.11.0",
+  "_shasum": "715b96ea9841593cc33067923f5ec60ebda4f7d7",
+  "_from": "caseless@>=0.11.0 <0.12.0",
+  "_npmVersion": "2.8.3",
+  "_nodeVersion": "1.8.1",
   "_npmUser": {
-    "name": "nylen",
-    "email": "jnylen@gmail.com"
+    "name": "mikeal",
+    "email": "mikeal.rogers@gmail.com"
   },
   "maintainers": [
     {
     {
       "name": "nylen",
       "email": "jnylen@gmail.com"
+    },
+    {
+      "name": "simov",
+      "email": "simeonvelichkov@gmail.com"
     }
   ],
   "dist": {
-    "shasum": "ed6b2719adcd1fd18f58dc081c0f1a5b43963909",
-    "tarball": "http://registry.npmjs.org/caseless/-/caseless-0.10.0.tgz"
+    "shasum": "715b96ea9841593cc33067923f5ec60ebda4f7d7",
+    "tarball": "http://registry.npmjs.org/caseless/-/caseless-0.11.0.tgz"
   },
   "directories": {},
-  "_resolved": "https://registry.npmjs.org/caseless/-/caseless-0.10.0.tgz",
+  "_resolved": "https://registry.npmjs.org/caseless/-/caseless-0.11.0.tgz",
   "readme": "ERROR: No README data found!"
 }
diff --git a/deps/npm/node_modules/request/node_modules/extend/.eslintrc b/deps/npm/node_modules/request/node_modules/extend/.eslintrc
deleted file mode 100644 (file)
index d49f173..0000000
+++ /dev/null
@@ -1,192 +0,0 @@
-{
-       "env": {
-               "browser": false,
-               "node": true,
-               "amd": false,
-               "mocha": false,
-               "jasmine": false
-       },
-
-       "rules": {
-               "accessor-pairs": [2, { getWithoutSet: false, setWithoutGet: true }],
-               "array-bracket-spacing": [2, "never", {
-                       "singleValue": false,
-                       "objectsInArrays": false,
-                       "arraysInArrays": false
-               }],
-               "block-scoped-var": [0],
-               "brace-style": [2, "1tbs", { "allowSingleLine": true }],
-               "camelcase": [2],
-               "comma-dangle": [2, "never"],
-               "comma-spacing": [2],
-               "comma-style": [2, "last"],
-               "complexity": [2, 15],
-               "computed-property-spacing": [2, "never"],
-               "consistent-return": [2],
-               "consistent-this": [0, "that"],
-               "constructor-super": [2],
-               "curly": [2, "all"],
-               "default-case": [2],
-               "dot-notation": [2, { "allowKeywords": true }],
-               "eol-last": [2],
-               "eqeqeq": [2],
-               "func-names": [0],
-               "func-style": [2, "expression"],
-               "generator-star-spacing": [2, { "before": false, "after": true }],
-               "global-strict": [0, "never"],
-               "guard-for-in": [0],
-               "handle-callback-err": [0],
-               "key-spacing": [2, { "beforeColon": false, "afterColon": true }],
-               "linebreak-style": [2, "unix"],
-               "lines-around-comment": [2, {
-                       "beforeBlockComment": false,
-                       "afterBlockComment": false,
-                       "beforeLineComment": false,
-                       "beforeLineComment": false,
-                       "allowBlockStart": true,
-                       "allowBlockEnd": true
-               }],
-               "quotes": [2, "single", "avoid-escape"],
-               "max-depth": [1, 4],
-               "max-len": [0, 80, 4],
-               "max-nested-callbacks": [2, 2],
-               "max-params": [2, 2],
-               "max-statements": [2, 21],
-               "new-parens": [2],
-               "new-cap": [2],
-               "newline-after-var": [0],
-               "no-alert": [2],
-               "no-array-constructor": [2],
-               "no-bitwise": [0],
-               "no-caller": [2],
-               "no-catch-shadow": [2],
-               "no-cond-assign": [2],
-               "no-console": [2],
-               "no-constant-condition": [2],
-               "no-continue": [2],
-               "no-control-regex": [2],
-               "no-debugger": [2],
-               "no-delete-var": [2],
-               "no-div-regex": [0],
-               "no-dupe-args": [2],
-               "no-dupe-keys": [2],
-               "no-duplicate-case": [2],
-               "no-else-return": [0],
-               "no-empty": [2],
-               "no-empty-character-class": [2],
-               "no-empty-label": [2],
-               "no-eq-null": [0],
-               "no-eval": [2],
-               "no-ex-assign": [2],
-               "no-extend-native": [2],
-               "no-extra-bind": [2],
-               "no-extra-boolean-cast": [2],
-               "no-extra-parens": [0],
-               "no-extra-semi": [2],
-               "no-fallthrough": [2],
-               "no-floating-decimal": [2],
-               "no-func-assign": [2],
-               "no-implied-eval": [2],
-               "no-inline-comments": [0],
-               "no-inner-declarations": [2, "functions"],
-               "no-invalid-regexp": [2],
-               "no-irregular-whitespace": [2],
-               "no-iterator": [2],
-               "no-label-var": [2],
-               "no-labels": [2],
-               "no-lone-blocks": [2],
-               "no-lonely-if": [2],
-               "no-loop-func": [2],
-               "no-mixed-requires": [0, false],
-               "no-mixed-spaces-and-tabs": [2, false],
-               "no-multi-spaces": [2],
-               "no-multi-str": [2],
-               "no-multiple-empty-lines": [2, {"max": 1}],
-               "no-native-reassign": [2],
-               "no-negated-in-lhs": [2],
-               "no-nested-ternary": [0],
-               "no-new": [2],
-               "no-new-func": [2],
-               "no-new-object": [2],
-               "no-new-require": [0],
-               "no-new-wrappers": [2],
-               "no-obj-calls": [2],
-               "no-octal": [2],
-               "no-octal-escape": [2],
-               "no-param-reassign": [2],
-               "no-path-concat": [0],
-               "no-plusplus": [0],
-               "no-process-env": [0],
-               "no-process-exit": [2],
-               "no-proto": [2],
-               "no-redeclare": [2],
-               "no-regex-spaces": [2],
-               "no-reserved-keys": [2],
-               "no-restricted-modules": [0],
-               "no-return-assign": [2, "always"],
-               "no-script-url": [2],
-               "no-self-compare": [0],
-               "no-sequences": [2],
-               "no-shadow": [2],
-               "no-shadow-restricted-names": [2],
-               "no-space-before-semi": [2],
-               "no-spaced-func": [2],
-               "no-sparse-arrays": [2],
-               "no-sync": [0],
-               "no-ternary": [0],
-               "no-this-before-super": [2],
-               "no-throw-literal": [2],
-               "no-trailing-spaces": [2, { "skipBlankLines": false }],
-               "no-undef": [2],
-               "no-undef-init": [2],
-               "no-undefined": [0],
-               "no-underscore-dangle": [2],
-               "no-unexpected-multiline": [2],
-               "no-unneeded-ternary": [2],
-               "no-unreachable": [2],
-               "no-unused-expressions": [2],
-               "no-unused-vars": [2, { "vars": "all", "args": "after-used" }],
-               "no-use-before-define": [2],
-               "no-void": [0],
-               "no-warning-comments": [0, { "terms": ["todo", "fixme", "xxx"], "location": "start" }],
-               "no-with": [2],
-               "no-wrap-func": [2],
-               "object-curly-spacing": [2, "always"],
-               "object-shorthand": [2, "never"],
-               "one-var": [0],
-               "operator-assignment": [0, "always"],
-               "operator-linebreak": [2, "none"],
-               "padded-blocks": [0],
-               "prefer-const": [0],
-               "quote-props": [0],
-               "radix": [0],
-               "semi": [2],
-               "semi-spacing": [2, { "before": false, "after": true }],
-               "sort-vars": [0],
-               "space-after-keywords": [2, "always"],
-               "space-before-function-paren": [2, { "anonymous": "always", "named": "never" }],
-               "space-before-blocks": [0, "always"],
-               "space-in-brackets": [0, "never", {
-                       "singleValue": true,
-                       "arraysInArrays": false,
-                       "arraysInObjects": false,
-                       "objectsInArrays": true,
-                       "objectsInObjects": true,
-                       "propertyName": false
-               }],
-               "space-in-parens": [2, "never"],
-               "space-infix-ops": [2],
-               "space-return-throw-case": [2],
-               "space-unary-ops": [2, { "words": true, "nonwords": false }],
-               "spaced-comment": [2, "always"],
-               "spaced-line-comment": [0, "always"],
-               "strict": [2, "global"],
-               "use-isnan": [2],
-               "valid-jsdoc": [0],
-               "valid-typeof": [2],
-               "vars-on-top": [0],
-               "wrap-iife": [2],
-               "wrap-regex": [2],
-               "yoda": [2, "never", { "exceptRange": true, "onlyEquality": false }]
-       }
-}
index 97e6d12..59faa8b 100644 (file)
@@ -1,6 +1,12 @@
 {
        "additionalRules": [],
 
+       "requireSemicolons": true,
+
+       "disallowMultipleSpaces": true,
+
+       "disallowIdentifierNames": [],
+
        "requireCurlyBraces": ["if", "else", "for", "while", "do", "try", "catch"],
 
        "requireSpaceAfterKeywords": ["if", "else", "for", "while", "do", "switch", "return", "try", "catch", "function"],
        "validateQuoteMarks": {
                "escape": true,
                "mark": "'"
-       }
+       },
+
+       "disallowOperatorBeforeLineBreak": [],
+
+       "requireSpaceBeforeKeywords": [
+               "do",
+               "for",
+               "if",
+               "else",
+               "switch",
+               "case",
+               "try",
+               "catch",
+               "finally",
+               "while",
+               "with",
+               "return"
+       ],
+
+       "validateAlignedFunctionParameters": {
+               "lineBreakAfterOpeningBraces": true,
+               "lineBreakBeforeClosingBraces": true
+       },
+
+       "requirePaddingNewLinesBeforeExport": true,
+
+       "validateNewlineAfterArrayElements": {
+               "maximum": 6
+       },
+
+       "requirePaddingNewLinesAfterUseStrict": true
 }
index e6f69e8..ebef644 100644 (file)
@@ -1,5 +1,9 @@
 language: node_js
 node_js:
+  - "iojs-v2.3"
+  - "iojs-v2.2"
+  - "iojs-v2.1"
+  - "iojs-v2.0"
   - "iojs-v1.8"
   - "iojs-v1.7"
   - "iojs-v1.6"
@@ -17,10 +21,15 @@ node_js:
   - "0.6"
   - "0.4"
 before_install:
-  - '[ "${TRAVIS_NODE_VERSION}" == "0.6" ] || npm install -g npm@~1.4.6'
+  - '[ "${TRAVIS_NODE_VERSION}" = "0.6" ] || npm install -g npm@1.4.28 && npm install -g npm'
+sudo: false
 matrix:
   fast_finish: true
   allow_failures:
+    - node_js: "iojs-v2.2"
+    - node_js: "iojs-v2.1"
+    - node_js: "iojs-v2.0"
+    - node_js: "iojs-v1.7"
     - node_js: "iojs-v1.6"
     - node_js: "iojs-v1.5"
     - node_js: "iojs-v1.4"
@@ -33,4 +42,3 @@ matrix:
     - node_js: "0.8"
     - node_js: "0.6"
     - node_js: "0.4"
-sudo: false
index 3a224fc..2874d2e 100644 (file)
@@ -1,3 +1,11 @@
+3.0.0 / 2015-07-01
+==================
+  * [Possible breaking change] Use global "strict" directive (#32)
+  * [Tests] `int` is an ES3 reserved word
+  * [Tests] Test up to `io.js` `v2.3`
+  * [Tests] Add `npm run eslint`
+  * [Dev Deps] Update `covert`, `jscs`
+
 2.0.1 / 2015-04-25
 ==================
   * Use an inline `isArray` check, for ES3 browsers. (#27)
index cd3956c..0f76b59 100644 (file)
@@ -1,7 +1,7 @@
 {
        "name": "extend",
        "author": "Stefan Thomas <justmoon@members.fsf.org> (http://www.justmoon.net)",
-       "version": "2.0.1",
+       "version": "3.0.0",
        "description": "Port of jQuery.extend for node.js and the browser.",
        "scripts": [
                "index.js"
index e489a8f..2f95748 100644 (file)
@@ -1,6 +1,7 @@
+'use strict';
+
 var hasOwn = Object.prototype.hasOwnProperty;
 var toStr = Object.prototype.toString;
-var undefined;
 
 var isArray = function isArray(arr) {
        if (typeof Array.isArray === 'function') {
@@ -11,28 +12,26 @@ var isArray = function isArray(arr) {
 };
 
 var isPlainObject = function isPlainObject(obj) {
-       'use strict';
        if (!obj || toStr.call(obj) !== '[object Object]') {
                return false;
        }
 
-       var has_own_constructor = hasOwn.call(obj, 'constructor');
-       var has_is_property_of_method = obj.constructor && obj.constructor.prototype && hasOwn.call(obj.constructor.prototype, 'isPrototypeOf');
+       var hasOwnConstructor = hasOwn.call(obj, 'constructor');
+       var hasIsPrototypeOf = obj.constructor && obj.constructor.prototype && hasOwn.call(obj.constructor.prototype, 'isPrototypeOf');
        // Not own constructor property must be Object
-       if (obj.constructor && !has_own_constructor && !has_is_property_of_method) {
+       if (obj.constructor && !hasOwnConstructor && !hasIsPrototypeOf) {
                return false;
        }
 
        // Own properties are enumerated firstly, so to speed up,
        // if last one is own, then all properties are own.
        var key;
-       for (key in obj) {}
+       for (key in obj) {/**/}
 
-       return key === undefined || hasOwn.call(obj, key);
+       return typeof key === 'undefined' || hasOwn.call(obj, key);
 };
 
 module.exports = function extend() {
-       'use strict';
        var options, name, src, copy, copyIsArray, clone,
                target = arguments[0],
                i = 1,
@@ -59,25 +58,23 @@ module.exports = function extend() {
                                copy = options[name];
 
                                // Prevent never-ending loop
-                               if (target === copy) {
-                                       continue;
-                               }
+                               if (target !== copy) {
+                                       // Recurse if we're merging plain objects or arrays
+                                       if (deep && copy && (isPlainObject(copy) || (copyIsArray = isArray(copy)))) {
+                                               if (copyIsArray) {
+                                                       copyIsArray = false;
+                                                       clone = src && isArray(src) ? src : [];
+                                               } else {
+                                                       clone = src && isPlainObject(src) ? src : {};
+                                               }
 
-                               // Recurse if we're merging plain objects or arrays
-                               if (deep && copy && (isPlainObject(copy) || (copyIsArray = isArray(copy)))) {
-                                       if (copyIsArray) {
-                                               copyIsArray = false;
-                                               clone = src && isArray(src) ? src : [];
-                                       } else {
-                                               clone = src && isPlainObject(src) ? src : {};
-                                       }
+                                               // Never move original objects, clone them
+                                               target[name] = extend(deep, clone, copy);
 
-                                       // Never move original objects, clone them
-                                       target[name] = extend(deep, clone, copy);
-
-                               // Don't bring in undefined values
-                               } else if (copy !== undefined) {
-                                       target[name] = copy;
+                                       // Don't bring in undefined values
+                                       } else if (typeof copy !== 'undefined') {
+                                               target[name] = copy;
+                                       }
                                }
                        }
                }
index 8eb102f..c8c7cac 100644 (file)
@@ -5,14 +5,16 @@
     "email": "justmoon@members.fsf.org",
     "url": "http://www.justmoon.net"
   },
-  "version": "2.0.1",
+  "version": "3.0.0",
   "description": "Port of jQuery.extend for node.js and the browser",
   "main": "index",
   "scripts": {
     "test": "npm run lint && node test/index.js && npm run coverage-quiet",
     "coverage": "covert test/index.js",
     "coverage-quiet": "covert test/index.js --quiet",
-    "lint": "jscs *.js */*.js"
+    "lint": "npm run jscs && npm run eslint",
+    "jscs": "jscs *.js */*.js",
+    "eslint": "eslint *.js */*.js"
   },
   "contributors": [
     {
   "dependencies": {},
   "devDependencies": {
     "tape": "^4.0.0",
-    "covert": "^1.0.1",
-    "jscs": "^1.11.3"
+    "covert": "^1.1.0",
+    "jscs": "^1.13.1",
+    "eslint": "^0.24.0"
   },
   "license": "MIT",
-  "gitHead": "ce3790222d3d2051f728f74be9565f155ed599c3",
+  "gitHead": "148e7270cab2e9413af2cd0cab147070d755ed6d",
   "bugs": {
     "url": "https://github.com/justmoon/node-extend/issues"
   },
   "homepage": "https://github.com/justmoon/node-extend#readme",
-  "_id": "extend@2.0.1",
-  "_shasum": "1ee8010689e7395ff9448241c98652bc759a8260",
-  "_from": "extend@>=2.0.1 <2.1.0",
-  "_npmVersion": "2.8.3",
-  "_nodeVersion": "1.8.1",
+  "_id": "extend@3.0.0",
+  "_shasum": "5a474353b9f3353ddd8176dfd37b91c83a46f1d4",
+  "_from": "extend@>=3.0.0 <3.1.0",
+  "_npmVersion": "2.11.3",
+  "_nodeVersion": "2.3.1",
   "_npmUser": {
     "name": "ljharb",
     "email": "ljharb@gmail.com"
   },
   "dist": {
-    "shasum": "1ee8010689e7395ff9448241c98652bc759a8260",
-    "tarball": "http://registry.npmjs.org/extend/-/extend-2.0.1.tgz"
+    "shasum": "5a474353b9f3353ddd8176dfd37b91c83a46f1d4",
+    "tarball": "http://registry.npmjs.org/extend/-/extend-3.0.0.tgz"
   },
   "maintainers": [
     {
@@ -65,6 +68,6 @@
     }
   ],
   "directories": {},
-  "_resolved": "https://registry.npmjs.org/extend/-/extend-2.0.1.tgz",
+  "_resolved": "https://registry.npmjs.org/extend/-/extend-3.0.0.tgz",
   "readme": "ERROR: No README data found!"
 }
index 7bdaaaf..ef074a5 100644 (file)
   "engines": {
     "node": "*"
   },
-  "readme": "forever-agent\n=============\n\nHTTP Agent that keeps socket connections alive between keep-alive requests. Formerly part of mikeal/request, now a standalone module.\n",
-  "readmeFilename": "README.md",
+  "gitHead": "1b3b6163f2b3c2c4122bbfa288c1325c0df9871d",
   "bugs": {
     "url": "https://github.com/mikeal/forever-agent/issues"
   },
-  "homepage": "https://github.com/mikeal/forever-agent#readme",
+  "homepage": "https://github.com/mikeal/forever-agent",
   "_id": "forever-agent@0.6.1",
+  "scripts": {},
   "_shasum": "fbc71f0c41adeb37f96c577ad1ed42d8fdacca91",
+  "_from": "forever-agent@>=0.6.0 <0.7.0",
+  "_npmVersion": "1.4.28",
+  "_npmUser": {
+    "name": "simov",
+    "email": "simeonvelichkov@gmail.com"
+  },
+  "maintainers": [
+    {
+      "name": "mikeal",
+      "email": "mikeal.rogers@gmail.com"
+    },
+    {
+      "name": "nylen",
+      "email": "jnylen@gmail.com"
+    },
+    {
+      "name": "simov",
+      "email": "simeonvelichkov@gmail.com"
+    }
+  ],
+  "dist": {
+    "shasum": "fbc71f0c41adeb37f96c577ad1ed42d8fdacca91",
+    "tarball": "http://registry.npmjs.org/forever-agent/-/forever-agent-0.6.1.tgz"
+  },
+  "directories": {},
   "_resolved": "https://registry.npmjs.org/forever-agent/-/forever-agent-0.6.1.tgz",
-  "_from": "forever-agent@>=0.6.0 <0.7.0"
+  "readme": "ERROR: No README data found!"
 }
diff --git a/deps/npm/node_modules/request/node_modules/form-data/lib/browser.js b/deps/npm/node_modules/request/node_modules/form-data/lib/browser.js
new file mode 100644 (file)
index 0000000..1e7717d
--- /dev/null
@@ -0,0 +1 @@
+module.exports = FormData;
\ No newline at end of file
index b960dce..89505f6 100644 (file)
@@ -180,7 +180,7 @@ FormData.prototype._multiPartFooter = function(field, value, options) {
 };
 
 FormData.prototype._lastBoundary = function() {
-  return '--' + this.getBoundary() + '--';
+  return '--' + this.getBoundary() + '--' + FormData.LINE_BREAK;
 };
 
 FormData.prototype.getHeaders = function(userHeaders) {
diff --git a/deps/npm/node_modules/request/node_modules/form-data/node_modules/async/.jscsrc b/deps/npm/node_modules/request/node_modules/form-data/node_modules/async/.jscsrc
new file mode 100644 (file)
index 0000000..b8cfa17
--- /dev/null
@@ -0,0 +1,3 @@
+{
+  "validateIndentation": 4
+}
\ No newline at end of file
index f237d59..c0a93c1 100644 (file)
@@ -52,9 +52,7 @@ There are many more functions available so take a look at the docs below for a
 full list. This module aims to be comprehensive, so if you feel anything is
 missing please create a GitHub issue for it.
 
-## Common Pitfalls
-
-<a name="stack-overflow">
+## Common Pitfalls <sub>[(StackOverflow)](http://stackoverflow.com/questions/tagged/async.js)</sub>
 ### Synchronous iteration functions
 
 If you get an error like `RangeError: Maximum call stack size exceeded.` or other stack overflow issues when using async, you are likely using a synchronous iterator.  By *synchronous* we mean a function that calls its callback on the same tick in the javascript event loop, without doing any I/O or using any timers.  Calling many callbacks iteratively will quickly overflow the stack. If you run into this issue, just defer your callback with `async.nextTick` to start a new call stack on the next tick of the event loop.
@@ -91,6 +89,30 @@ Async guards against synchronous functions in some, but not all, cases.  If you
 If javascript's event loop is still a bit nebulous, check out [this article](http://blog.carbonfive.com/2013/10/27/the-javascript-event-loop-explained/) or [this talk](http://2014.jsconf.eu/speakers/philip-roberts-what-the-heck-is-the-event-loop-anyway.html) for more detailed information about how it works.
 
 
+### Multiple callbacks
+
+Make sure to always `return` when calling a callback early, otherwise you will cause multiple callbacks and unpredictable behavior in many cases.
+
+```js
+async.waterfall([
+    function (callback) {
+        getSomething(options, function (err, result) {
+          if (err) {
+            callback(new Error("failed getting something:" + err.message));
+            // we should return here
+          }
+          // since we did not return, this callback still will be called and
+          // `processData` will be called twice
+          callback(result);
+        });
+    },
+    processData
+], done)
+```
+
+It is always good practice to `return callback(err, result)`  whenever a callback call is not the last statement of a function.
+
+
 ### Binding a context to an iterator
 
 This section is really about `bind`, not about `async`. If you are wondering how to
@@ -158,57 +180,42 @@ Usage:
 
 ## Documentation
 
+Some functions are also available in the following forms:
+* `<name>Series` - the same as `<name>` but runs only a single async operation at a time
+* `<name>Limit` - the same as `<name>` but runs a maximum of `limit` async operations at a time
+
 ### Collections
 
-* [`each`](#each)
-* [`eachSeries`](#eachSeries)
-* [`eachLimit`](#eachLimit)
-* [`forEachOf`](#forEachOf)
-* [`forEachOfSeries`](#forEachOfSeries)
-* [`forEachOfLimit`](#forEachOfLimit)
-* [`map`](#map)
-* [`mapSeries`](#mapSeries)
-* [`mapLimit`](#mapLimit)
-* [`filter`](#filter)
-* [`filterSeries`](#filterSeries)
-* [`reject`](#reject)
-* [`rejectSeries`](#rejectSeries)
-* [`reduce`](#reduce)
-* [`reduceRight`](#reduceRight)
-* [`detect`](#detect)
-* [`detectSeries`](#detectSeries)
+* [`each`](#each), `eachSeries`, `eachLimit`
+* [`forEachOf`](#forEachOf), `forEachOfSeries`, `forEachOfLimit`
+* [`map`](#map), `mapSeries`, `mapLimit`
+* [`filter`](#filter), `filterSeries`, `filterLimit`
+* [`reject`](#reject), `rejectSeries`, `rejectLimit`
+* [`reduce`](#reduce), [`reduceRight`](#reduceRight)
+* [`detect`](#detect), `detectSeries`, `detectLimit`
 * [`sortBy`](#sortBy)
-* [`some`](#some)
-* [`every`](#every)
-* [`concat`](#concat)
-* [`concatSeries`](#concatSeries)
+* [`some`](#some), `someLimit`
+* [`every`](#every), `everyLimit`
+* [`concat`](#concat), `concatSeries`
 
 ### Control Flow
 
 * [`series`](#seriestasks-callback)
-* [`parallel`](#parallel)
-* [`parallelLimit`](#parallellimittasks-limit-callback)
-* [`whilst`](#whilst)
-* [`doWhilst`](#doWhilst)
-* [`until`](#until)
-* [`doUntil`](#doUntil)
-* [`during`](#during)
-* [`doDuring`](#doDuring)
+* [`parallel`](#parallel), `parallelLimit`
+* [`whilst`](#whilst), [`doWhilst`](#doWhilst)
+* [`until`](#until), [`doUntil`](#doUntil)
+* [`during`](#during), [`doDuring`](#doDuring)
 * [`forever`](#forever)
 * [`waterfall`](#waterfall)
 * [`compose`](#compose)
 * [`seq`](#seq)
-* [`applyEach`](#applyEach)
-* [`applyEachSeries`](#applyEachSeries)
-* [`queue`](#queue)
-* [`priorityQueue`](#priorityQueue)
+* [`applyEach`](#applyEach), `applyEachSeries`
+* [`queue`](#queue), [`priorityQueue`](#priorityQueue)
 * [`cargo`](#cargo)
 * [`auto`](#auto)
 * [`retry`](#retry)
 * [`iterator`](#iterator)
-* [`times`](#times)
-* [`timesSeries`](#timesSeries)
-* [`timesLimit`](#timesLimit)
+* [`times`](#times), `timesSeries`, `timesLimit`
 
 ### Utils
 
@@ -224,7 +231,6 @@ Usage:
 * [`dir`](#dir)
 * [`noConflict`](#noConflict)
 
-
 ## Collections
 
 <a name="forEach" />
@@ -290,50 +296,10 @@ async.each(openFiles, function(file, callback) {
 });
 ```
 
----------------------------------------
-
-<a name="forEachSeries" />
-<a name="eachSeries" />
-### eachSeries(arr, iterator, [callback])
-
-The same as [`each`](#each), only `iterator` is applied to each item in `arr` in
-series. The next `iterator` is only called once the current one has completed.
-This means the `iterator` functions will complete in order.
+__Related__
 
-
----------------------------------------
-
-<a name="forEachLimit" />
-<a name="eachLimit" />
-### eachLimit(arr, limit, iterator, [callback])
-
-The same as [`each`](#each), only no more than `limit` `iterator`s will be simultaneously
-running at any time.
-
-Note that the items in `arr` are not processed in batches, so there is no guarantee that
-the first `limit` `iterator` functions will complete before any others are started.
-
-__Arguments__
-
-* `arr` - An array to iterate over.
-* `limit` - The maximum number of `iterator`s to run at any time.
-* `iterator(item, callback)` - A function to apply to each item in `arr`.
-  The iterator is passed a `callback(err)` which must be called once it has
-  completed. If no error has occurred, the callback should be run without
-  arguments or with an explicit `null` argument.
-* `callback(err)` - *Optional* A callback which is called when all `iterator` functions
-  have finished, or an error occurs.
-
-__Example__
-
-```js
-// Assume documents is an array of JSON objects and requestApi is a
-// function that interacts with a rate-limited REST api.
-
-async.eachLimit(documents, 20, requestApi, function(err){
-    // if any of the saves produced an error, err would equal that error
-});
-```
+* eachSeries(arr, iterator, [callback])
+* eachLimit(arr, limit, iterator, [callback])
 
 ---------------------------------------
 
@@ -377,24 +343,10 @@ async.forEachOf(obj, function (value, key, callback) {
 })
 ```
 
----------------------------------------
-
-<a name="forEachOfSeries" />
-<a name="eachOfSeries" />
-
-### forEachOfSeries(obj, iterator, [callback])
-
-Like [`forEachOf`](#forEachOf), except only one `iterator` is run at a time.  The order of execution is not guaranteed for objects, but it will be guaranteed for arrays.
-
----------------------------------------
-
-<a name="forEachOfLimit" />
-<a name="eachOfLimit" />
-
-### forEachOfLimit(obj, limit, iterator, [callback])
-
-Like [`forEachOf`](#forEachOf), except the number of `iterator`s running at a given time is controlled by `limit`.
+__Related__
 
+* forEachOfSeries(obj, iterator, [callback])
+* forEachOfLimit(obj, limit, iterator, [callback])
 
 ---------------------------------------
 
@@ -429,45 +381,9 @@ async.map(['file1','file2','file3'], fs.stat, function(err, results){
 });
 ```
 
----------------------------------------
-
-<a name="mapSeries" />
-### mapSeries(arr, iterator, [callback])
-
-The same as [`map`](#map), only the `iterator` is applied to each item in `arr` in
-series. The next `iterator` is only called once the current one has completed.
-The results array will be in the same order as the original.
-
-
----------------------------------------
-
-<a name="mapLimit" />
-### mapLimit(arr, limit, iterator, [callback])
-
-The same as [`map`](#map), only no more than `limit` `iterator`s will be simultaneously
-running at any time.
-
-Note that the items are not processed in batches, so there is no guarantee that
-the first `limit` `iterator` functions will complete before any others are started.
-
-__Arguments__
-
-* `arr` - An array to iterate over.
-* `limit` - The maximum number of `iterator`s to run at any time.
-* `iterator(item, callback)` - A function to apply to each item in `arr`.
-  The iterator is passed a `callback(err, transformed)` which must be called once
-  it has completed with an error (which can be `null`) and a transformed item.
-* `callback(err, results)` - A callback which is called when all `iterator`
-  calls have finished, or an error occurs. The result is an array of the
-  transformed items from the original `arr`.
-
-__Example__
-
-```js
-async.mapLimit(['file1','file2','file3'], 1, fs.stat, function(err, results){
-    // results is now an array of stats for each file
-});
-```
+__Related__
+* mapSeries(arr, iterator, [callback])
+* mapLimit(arr, limit, iterator, [callback])
 
 ---------------------------------------
 
@@ -501,17 +417,10 @@ async.filter(['file1','file2','file3'], fs.exists, function(results){
 });
 ```
 
----------------------------------------
-
-<a name="selectSeries" />
-<a name="filterSeries" />
-### filterSeries(arr, iterator, [callback])
-
-__Alias:__ `selectSeries`
+__Related__
 
-The same as [`filter`](#filter) only the `iterator` is applied to each item in `arr` in
-series. The next `iterator` is only called once the current one has completed.
-The results array will be in the same order as the original.
+* filterSeries(arr, iterator, [callback])
+* filterLimit(arr, limit, iterator, [callback])
 
 ---------------------------------------
 
@@ -520,14 +429,10 @@ The results array will be in the same order as the original.
 
 The opposite of [`filter`](#filter). Removes values that pass an `async` truth test.
 
----------------------------------------
-
-<a name="rejectSeries" />
-### rejectSeries(arr, iterator, [callback])
-
-The same as [`reject`](#reject), only the `iterator` is applied to each item in `arr`
-in series.
+__Related__
 
+* rejectSeries(arr, iterator, [callback])
+* rejectLimit(arr, limit, iterator, [callback])
 
 ---------------------------------------
 
@@ -612,15 +517,10 @@ async.detect(['file1','file2','file3'], fs.exists, function(result){
 });
 ```
 
----------------------------------------
-
-<a name="detectSeries" />
-### detectSeries(arr, iterator, [callback])
-
-The same as [`detect`](#detect), only the `iterator` is applied to each item in `arr`
-in series. This means the result is always the first in the original `arr` (in
-terms of array order) that passes the truth test.
+__Related__
 
+* detectSeries(arr, iterator, [callback])
+* detectLimit(arr, limit, iterator, [callback])
 
 ---------------------------------------
 
@@ -705,6 +605,10 @@ async.some(['file1','file2','file3'], fs.exists, function(result){
 });
 ```
 
+__Related__
+
+* someLimit(arr, limit, iterator, callback)
+
 ---------------------------------------
 
 <a name="every" />
@@ -737,6 +641,10 @@ async.every(['file1','file2','file3'], fs.exists, function(result){
 });
 ```
 
+__Related__
+
+* everyLimit(arr, limit, iterator, callback)
+
 ---------------------------------------
 
 <a name="concat" />
@@ -765,12 +673,9 @@ async.concat(['dir1','dir2','dir3'], fs.readdir, function(err, files){
 });
 ```
 
----------------------------------------
+__Related__
 
-<a name="concatSeries" />
-### concatSeries(arr, iterator, [callback])
-
-Same as [`concat`](#concat), but executes in series instead of parallel.
+* concatSeries(arr, iterator, [callback])
 
 
 ## Control Flow
@@ -854,6 +759,8 @@ callback, the main `callback` is immediately called with the value of the error.
 Once the `tasks` have completed, the results are passed to the final `callback` as an
 array.
 
+**Note:** `parallel` is about kicking-off I/O tasks in parallel, not about parallel execution of code.  If your tasks do not use any timers or perform any I/O, they will actually be executed in series.  Any synchronous setup sections for each task will happen one after the other.  JavaScript remains single-threaded.
+
 It is also possible to use an object instead of an array. Each property will be
 run as a function and the results will be passed to the final `callback` as an object
 instead of an array. This can be a more readable way of handling results from
@@ -909,26 +816,9 @@ function(err, results) {
 });
 ```
 
----------------------------------------
-
-<a name="parallelLimit" />
-### parallelLimit(tasks, limit, [callback])
-
-The same as [`parallel`](#parallel), only `tasks` are executed in parallel
-with a maximum of `limit` tasks executing at any time.
+__Related__
 
-Note that the `tasks` are not executed in batches, so there is no guarantee that
-the first `limit` tasks will complete before any others are started.
-
-__Arguments__
-
-* `tasks` - An array or object containing functions to run, each function is passed
-  a `callback(err, result)` it must call on completion with an error `err` (which can
-  be `null`) and an optional `result` value.
-* `limit` - The maximum number of `tasks` to run at any time.
-* `callback(err, results)` - An optional callback to run once all the functions
-  have completed. This function gets a results array (or object) containing all
-  the result arguments passed to the `task` callbacks.
+* parallelLimit(tasks, limit, [callback])
 
 ---------------------------------------
 
@@ -1200,12 +1090,9 @@ async.each(
 );
 ```
 
----------------------------------------
-
-<a name="applyEachSeries" />
-### applyEachSeries(arr, args..., callback)
+__Related__
 
-The same as [`applyEach`](#applyEach) only the functions are applied in series.
+* applyEachSeries(tasks, args..., [callback])
 
 ---------------------------------------
 
@@ -1371,14 +1258,9 @@ cargo.push({name: 'baz'}, function (err) {
 <a name="auto" />
 ### auto(tasks, [callback])
 
-Determines the best order for running the functions in `tasks`, based on their
-requirements. Each function can optionally depend on other functions being completed
-first, and each function is run as soon as its requirements are satisfied.
+Determines the best order for running the functions in `tasks`, based on their requirements. Each function can optionally depend on other functions being completed first, and each function is run as soon as its requirements are satisfied.
 
-If any of the functions pass an error to their callback, it will not
-complete (so any other functions depending on it will not run), and the main
-`callback` is immediately called with the error. Functions also receive an
-object containing the results of functions which have completed so far.
+If any of the functions pass an error to their callback, the `auto` sequence will stop. Further tasks will not execute (so any other functions depending on it will not run), and the main `callback` is immediately called with the error.  Functions also receive an object containing the results of functions which have completed so far.
 
 Note, all functions are called with a `results` object as a second argument,
 so it is unsafe to pass functions in the `tasks` object which cannot handle the
@@ -1693,17 +1575,10 @@ async.times(5, function(n, next){
 });
 ```
 
-<a name="timesSeries" />
-### timesSeries(n, iterator, [callback])
-
-The same as [`times`](#times), only the iterator is applied in series.
-The next `iterator` is only called once the current one has completed.
-The results array will be in the same order as the original.
-
-<a name="timesLimit" />
-### timesLimit(n, limit, iterator, [callback])
+__Related__
 
-The same as [`times`](#times), except a maximum of `limit` iterators are run at a given time, similar to [`mapLimit`](#mapLimit).
+* timesSeries(n, iterator, [callback])
+* timesLimit(n, limit, iterator, [callback])
 
 
 ## Utils
@@ -1829,7 +1704,7 @@ async.auto({
 <a name="wrapSync">
 ### asyncify(func)
 
-*Alias: wrapSync*
+__Alias:__ `wrapSync`
 
 Take a sync function and make it async, passing its return value to a callback. This is useful for plugging sync functions into a waterfall, series, or other async functions. Any arguments passed to the generated function will be passed to the wrapped function (except for the final callback argument). Errors thrown will be passed to the callback.
 
index abddcd9..f3cfb80 100644 (file)
@@ -9,6 +9,15 @@
 
     var async = {};
     function noop() {}
+    function identity(v) {
+        return v;
+    }
+    function toBool(v) {
+        return !!v;
+    }
+    function notId(v) {
+        return !v;
+    }
 
     // global on the server, window in the browser
     var previous_async;
     };
 
     function only_once(fn) {
-        var called = false;
         return function() {
-            if (called) throw new Error("Callback was already called.");
-            called = true;
+            if (fn === null) throw new Error("Callback was already called.");
             fn.apply(this, arguments);
+            fn = null;
         };
     }
 
     function _once(fn) {
-        var called = false;
         return function() {
-            if (called) return;
-            called = true;
+            if (fn === null) return;
             fn.apply(this, arguments);
+            fn = null;
         };
     }
 
         });
     }
 
+    function _indexOf(arr, item) {
+        for (var i = 0; i < arr.length; i++) {
+            if (arr[i] === item) return i;
+        }
+        return -1;
+    }
+
     var _keys = Object.keys || function (obj) {
         var keys = [];
         for (var k in obj) {
         }
     }
 
-    function _baseSlice(arr, start) {
-        start = start || 0;
-        var index = -1;
-        var length = arr.length;
-
-        if (start) {
-            length -= start;
-            length = length < 0 ? 0 : length;
-        }
-        var result = Array(length);
-
-        while (++index < length) {
-            result[index] = arr[index + start];
-        }
-        return result;
+    // Similar to ES6's rest param (http://ariya.ofilabs.com/2013/03/es6-and-rest-parameter.html)
+    // This accumulates the arguments passed into an array, after a given index.
+    // From underscore.js (https://github.com/jashkenas/underscore/pull/2140).
+    function _restParam(func, startIndex) {
+        startIndex = startIndex == null ? func.length - 1 : +startIndex;
+        return function() {
+            var length = Math.max(arguments.length - startIndex, 0);
+            var rest = Array(length);
+            for (var index = 0; index < length; index++) {
+                rest[index] = arguments[index + startIndex];
+            }
+            switch (startIndex) {
+                case 0: return func.call(this, rest);
+                case 1: return func.call(this, arguments[0], rest);
+                case 2: return func.call(this, arguments[0], arguments[1], rest);
+            }
+            // Currently unused but handle cases outside of the switch statement:
+            // var args = Array(startIndex + 1);
+            // for (index = 0; index < startIndex; index++) {
+            //     args[index] = arguments[index];
+            // }
+            // args[startIndex] = rest;
+            // return func.apply(this, args);
+        };
     }
 
     function _withoutIndex(iterator) {
     //// nextTick implementation with browser-compatible fallback ////
 
     // capture the global reference to guard against fakeTimer mocks
-    var _setImmediate;
-    if (typeof setImmediate === 'function') {
-        _setImmediate = setImmediate;
-    }
+    var _setImmediate = typeof setImmediate === 'function' && setImmediate;
 
-    if (typeof process === 'undefined' || !(process.nextTick)) {
-        if (_setImmediate) {
-            async.nextTick = function (fn) {
-                // not a direct alias for IE10 compatibility
-                _setImmediate(fn);
-            };
-            async.setImmediate = async.nextTick;
-        }
-        else {
-            async.nextTick = function (fn) {
-                setTimeout(fn, 0);
-            };
-            async.setImmediate = async.nextTick;
-        }
-    }
-    else {
+    var _delay = _setImmediate ? function(fn) {
+        // not a direct alias for IE10 compatibility
+        _setImmediate(fn);
+    } : function(fn) {
+        setTimeout(fn, 0);
+    };
+
+    if (typeof process === 'object' && typeof process.nextTick === 'function') {
         async.nextTick = process.nextTick;
-        if (_setImmediate) {
-            async.setImmediate = function (fn) {
-              // not a direct alias for IE10 compatibility
-                _setImmediate(fn);
-            };
-        }
-        else {
-            async.setImmediate = async.nextTick;
-        }
+    } else {
+        async.nextTick = _delay;
     }
+    async.setImmediate = _setImmediate ? _delay : async.nextTick;
+
 
     async.forEach =
     async.each = function (arr, iterator, callback) {
             return fn(async.eachOf, obj, iterator, callback);
         };
     }
-    function doParallelLimit(limit, fn) {
-        return function (obj, iterator, callback) {
+    function doParallelLimit(fn) {
+        return function (obj, limit, iterator, callback) {
             return fn(_eachOfLimit(limit), obj, iterator, callback);
         };
     }
 
     async.map = doParallel(_asyncMap);
     async.mapSeries = doSeries(_asyncMap);
-    async.mapLimit = function (arr, limit, iterator, callback) {
-        return _mapLimit(limit)(arr, iterator, callback);
-    };
-
-    function _mapLimit(limit) {
-        return doParallelLimit(limit, _asyncMap);
-    }
+    async.mapLimit = doParallelLimit(_asyncMap);
 
     // reduce only has a series version, as doing reduce in parallel won't
     // work in many situations.
 
     async.foldr =
     async.reduceRight = function (arr, memo, iterator, callback) {
-        var reversed = _map(arr, function (x) {
-            return x;
-        }).reverse();
+        var reversed = _map(arr, identity).reverse();
         async.reduce(reversed, memo, iterator, callback);
     };
 
     function _filter(eachfn, arr, iterator, callback) {
         var results = [];
-        arr = _map(arr, function (x, i) {
-            return {index: i, value: x};
-        });
         eachfn(arr, function (x, index, callback) {
-            iterator(x.value, function (v) {
+            iterator(x, function (v) {
                 if (v) {
-                    results.push(x);
+                    results.push({index: index, value: x});
                 }
                 callback();
             });
     async.select =
     async.filter = doParallel(_filter);
 
+    async.selectLimit =
+    async.filterLimit = doParallelLimit(_filter);
+
     async.selectSeries =
     async.filterSeries = doSeries(_filter);
 
         }, callback);
     }
     async.reject = doParallel(_reject);
+    async.rejectLimit = doParallelLimit(_reject);
     async.rejectSeries = doSeries(_reject);
 
-    function _detect(eachfn, arr, iterator, main_callback) {
-        eachfn(arr, function (x, index, callback) {
-            iterator(x, function (result) {
-                if (result) {
-                    main_callback(x);
-                    main_callback = noop;
-                }
-                else {
+    function _createTester(eachfn, check, getResult) {
+        return function(arr, limit, iterator, cb) {
+            function done() {
+                if (cb) cb(getResult(false, void 0));
+            }
+            function iteratee(x, _, callback) {
+                if (!cb) return callback();
+                iterator(x, function (v) {
+                    if (cb && check(v)) {
+                        cb(getResult(true, x));
+                        cb = iterator = false;
+                    }
                     callback();
-                }
-            });
-        }, function () {
-            main_callback();
-        });
+                });
+            }
+            if (arguments.length > 3) {
+                eachfn(arr, limit, iteratee, done);
+            } else {
+                cb = iterator;
+                iterator = limit;
+                eachfn(arr, iteratee, done);
+            }
+        };
     }
-    async.detect = doParallel(_detect);
-    async.detectSeries = doSeries(_detect);
 
     async.any =
-    async.some = function (arr, iterator, main_callback) {
-        async.eachOf(arr, function (x, _, callback) {
-            iterator(x, function (v) {
-                if (v) {
-                    main_callback(true);
-                    main_callback = noop;
-                }
-                callback();
-            });
-        }, function () {
-            main_callback(false);
-        });
-    };
+    async.some = _createTester(async.eachOf, toBool, identity);
+
+    async.someLimit = _createTester(async.eachOfLimit, toBool, identity);
 
     async.all =
-    async.every = function (arr, iterator, main_callback) {
-        async.eachOf(arr, function (x, _, callback) {
-            iterator(x, function (v) {
-                if (!v) {
-                    main_callback(false);
-                    main_callback = noop;
-                }
-                callback();
-            });
-        }, function () {
-            main_callback(true);
-        });
-    };
+    async.every = _createTester(async.eachOf, notId, notId);
+
+    async.everyLimit = _createTester(async.eachOfLimit, notId, notId);
+
+    function _findGetResult(v, x) {
+        return x;
+    }
+    async.detect = _createTester(async.eachOf, identity, _findGetResult);
+    async.detectSeries = _createTester(async.eachOfSeries, identity, _findGetResult);
 
     async.sortBy = function (arr, iterator, callback) {
         async.map(arr, function (x, callback) {
             listeners.unshift(fn);
         }
         function removeListener(fn) {
-            for (var i = 0; i < listeners.length; i += 1) {
-                if (listeners[i] === fn) {
-                    listeners.splice(i, 1);
-                    return;
-                }
-            }
+            var idx = _indexOf(listeners, fn);
+            if (idx >= 0) listeners.splice(idx, 1);
         }
         function taskComplete() {
             remainingTasks--;
 
         _arrayEach(keys, function (k) {
             var task = _isArray(tasks[k]) ? tasks[k]: [tasks[k]];
-            function taskCallback(err) {
-                var args = _baseSlice(arguments, 1);
+            var taskCallback = _restParam(function(err, args) {
                 if (args.length <= 1) {
                     args = args[0];
                 }
                 if (err) {
                     var safeResults = {};
-                    _arrayEach(_keys(results), function(rkey) {
-                        safeResults[rkey] = results[rkey];
+                    _forEachOf(results, function(val, rkey) {
+                        safeResults[rkey] = val;
                     });
                     safeResults[k] = args;
                     callback(err, safeResults);
                     results[k] = args;
                     async.setImmediate(taskComplete);
                 }
-            }
-            var requires = task.slice(0, Math.abs(task.length - 1)) || [];
+            });
+            var requires = task.slice(0, task.length - 1);
             // prevent dead-locks
             var len = requires.length;
             var dep;
                 if (!(dep = tasks[requires[len]])) {
                     throw new Error('Has inexistant dependency');
                 }
-                if (_isArray(dep) && !!~dep.indexOf(k)) {
+                if (_isArray(dep) && _indexOf(dep, k) >= 0) {
                     throw new Error('Has cyclic dependencies');
                 }
             }
 
 
 
-    async.retry = function(/*[times,] task [, callback]*/) {
+    async.retry = function(times, task, callback) {
         var DEFAULT_TIMES = 5;
         var DEFAULT_INTERVAL = 0;
 
         var attempts = [];
 
         var opts = {
-          times: DEFAULT_TIMES,
-          interval: DEFAULT_INTERVAL
+            times: DEFAULT_TIMES,
+            interval: DEFAULT_INTERVAL
         };
 
         function parseTimes(acc, t){
-          if(typeof t === 'number'){
-            acc.times = parseInt(t, 10) || DEFAULT_TIMES;
-          } else if(typeof t === 'object'){
-            acc.times = parseInt(t.times, 10) || DEFAULT_TIMES;
-            acc.interval = parseInt(t.interval, 10) || DEFAULT_INTERVAL;
-          } else {
-            throw new Error('Unsupported argument type for \'times\': ' + typeof(t));
-          }
+            if(typeof t === 'number'){
+                acc.times = parseInt(t, 10) || DEFAULT_TIMES;
+            } else if(typeof t === 'object'){
+                acc.times = parseInt(t.times, 10) || DEFAULT_TIMES;
+                acc.interval = parseInt(t.interval, 10) || DEFAULT_INTERVAL;
+            } else {
+                throw new Error('Unsupported argument type for \'times\': ' + typeof(t));
+            }
         }
 
-        switch(arguments.length){
-            case 1: {
-              opts.task = arguments[0];
-              break;
-            }
-            case 2 : {
-              if(typeof arguments[0] === 'number' || typeof arguments[0] === 'object'){
-                parseTimes(opts, arguments[0]);
-                opts.task = arguments[1];
-              } else {
-                opts.task = arguments[0];
-                opts.callback = arguments[1];
-              }
-              break;
-            }
-            case 3: {
-              parseTimes(opts, arguments[0]);
-              opts.task = arguments[1];
-              opts.callback = arguments[2];
-              break;
-            }
-            default: {
-              throw new Error('Invalid arguments - must be either (task), (task, callback), (times, task) or (times, task, callback)');
-            }
-          }
+        var length = arguments.length;
+        if (length < 1 || length > 3) {
+            throw new Error('Invalid arguments - must be either (task), (task, callback), (times, task) or (times, task, callback)');
+        } else if (length <= 2 && typeof times === 'function') {
+            callback = task;
+            task = times;
+        }
+        if (typeof times !== 'function') {
+            parseTimes(opts, times);
+        }
+        opts.callback = callback;
+        opts.task = task;
 
         function wrappedTask(wrappedCallback, wrappedResults) {
             function retryAttempt(task, finalAttempt) {
             }
 
             function retryInterval(interval){
-              return function(seriesCallback){
-                setTimeout(function(){
-                  seriesCallback(null);
-                }, interval);
-              };
+                return function(seriesCallback){
+                    setTimeout(function(){
+                        seriesCallback(null);
+                    }, interval);
+                };
             }
 
             while (opts.times) {
                 var finalAttempt = !(opts.times-=1);
                 attempts.push(retryAttempt(opts.task, finalAttempt));
                 if(!finalAttempt && opts.interval > 0){
-                  attempts.push(retryInterval(opts.interval));
+                    attempts.push(retryInterval(opts.interval));
                 }
             }
 
             return callback();
         }
         function wrapIterator(iterator) {
-            return function (err) {
+            return _restParam(function (err, args) {
                 if (err) {
-                    callback.apply(null, arguments);
+                    callback.apply(null, [err].concat(args));
                 }
                 else {
-                    var args = _baseSlice(arguments, 1);
                     var next = iterator.next();
                     if (next) {
                         args.push(wrapIterator(next));
                     }
                     ensureAsync(iterator).apply(null, args);
                 }
-            };
+            });
         }
         wrapIterator(async.iterator(tasks))();
     };
         var results = _isArrayLike(tasks) ? [] : {};
 
         eachfn(tasks, function (task, key, callback) {
-            task(function (err) {
-                var args = _baseSlice(arguments, 1);
+            task(_restParam(function (err, args) {
                 if (args.length <= 1) {
                     args = args[0];
                 }
                 results[key] = args;
                 callback(err);
-            });
+            }));
         }, function (err) {
             callback(err, results);
         });
         _parallel(_eachOfLimit(limit), tasks, callback);
     };
 
-    async.series = function (tasks, callback) {
-        callback = callback || noop;
-        var results = _isArrayLike(tasks) ? [] : {};
-
-        async.eachOfSeries(tasks, function (task, key, callback) {
-            task(function (err) {
-                var args = _baseSlice(arguments, 1);
-                if (args.length <= 1) {
-                    args = args[0];
-                }
-                results[key] = args;
-                callback(err);
-            });
-        }, function (err) {
-            callback(err, results);
-        });
+    async.series = function(tasks, callback) {
+        _parallel(async.eachOfSeries, tasks, callback);
     };
 
     async.iterator = function (tasks) {
         return makeCallback(0);
     };
 
-    async.apply = function (fn) {
-        var args = _baseSlice(arguments, 1);
-        return function () {
+    async.apply = _restParam(function (fn, args) {
+        return _restParam(function (callArgs) {
             return fn.apply(
-                null, args.concat(_baseSlice(arguments))
+                null, args.concat(callArgs)
             );
-        };
-    };
+        });
+    });
 
     function _concat(eachfn, arr, fn, callback) {
         var result = [];
     async.whilst = function (test, iterator, callback) {
         callback = callback || noop;
         if (test()) {
-            iterator(function (err) {
+            var next = _restParam(function(err, args) {
                 if (err) {
-                    return callback(err);
+                    callback(err);
+                } else if (test.apply(this, args)) {
+                    iterator(next);
+                } else {
+                    callback(null);
                 }
-                async.whilst(test, iterator, callback);
             });
-        }
-        else {
+            iterator(next);
+        else {
             callback(null);
         }
     };
 
     async.doWhilst = function (iterator, test, callback) {
-        callback = callback || noop;
-        iterator(function (err) {
-            if (err) {
-                return callback(err);
-            }
-            var args = _baseSlice(arguments, 1);
-            if (test.apply(null, args)) {
-                async.doWhilst(iterator, test, callback);
-            }
-            else {
-                callback(null);
-            }
-        });
+        var calls = 0;
+        return async.whilst(function() {
+            return ++calls <= 1 || test.apply(this, arguments);
+        }, iterator, callback);
     };
 
     async.until = function (test, iterator, callback) {
-        callback = callback || noop;
-        if (!test()) {
-            iterator(function (err) {
-                if (err) {
-                    return callback(err);
-                }
-                async.until(test, iterator, callback);
-            });
-        }
-        else {
-            callback(null);
-        }
+        return async.whilst(function() {
+            return !test.apply(this, arguments);
+        }, iterator, callback);
     };
 
     async.doUntil = function (iterator, test, callback) {
-        callback = callback || noop;
-        iterator(function (err) {
-            if (err) {
-                return callback(err);
-            }
-            var args = _baseSlice(arguments, 1);
-            if (!test.apply(null, args)) {
-                async.doUntil(iterator, test, callback);
-            }
-            else {
-                callback(null);
-            }
-        });
+        return async.doWhilst(iterator, function() {
+            return !test.apply(this, arguments);
+        }, callback);
     };
 
     async.during = function (test, iterator, callback) {
         callback = callback || noop;
-        test(function(err, truth) {
+
+        var next = _restParam(function(err, args) {
             if (err) {
-                return callback(err);
-            }
-            if (truth) {
-                iterator(function (err) {
-                    if (err) {
-                        return callback(err);
-                    }
-                    async.during(test, iterator, callback);
-                });
+                callback(err);
+            } else {
+                args.push(check);
+                test.apply(this, args);
             }
-            else {
+        });
+
+        var check = function(err, truth) {
+            if (err) {
+                callback(err);
+            } else if (truth) {
+                iterator(next);
+            } else {
                 callback(null);
             }
-        });
+        };
+
+        test(check);
     };
 
     async.doDuring = function (iterator, test, callback) {
-        callback = callback || noop;
-        iterator(function (err) {
-            if (err) {
-                return callback(err);
+        var calls = 0;
+        async.during(function(next) {
+            if (calls++ < 1) {
+                next(null, true);
+            } else {
+                test.apply(this, arguments);
             }
-            var args = _baseSlice(arguments, 1);
-            args.push(function (err, truth) {
-                if (err) {
-                   return callback(err);
-                }
-                if (truth) {
-                    async.doDuring(iterator, test, callback);
-                }
-                else {
-                    callback(null);
-                }
-            });
-            test.apply(null, args);
-        });
+        }, iterator, callback);
     };
 
     function _queue(worker, concurrency, payload) {
             if(data.length === 0 && q.idle()) {
                 // call drain immediately if there are no tasks
                 return async.setImmediate(function() {
-                   q.drain();
+                    q.drain();
                 });
             }
             _arrayEach(data, function(task) {
         }
 
         function _binarySearch(sequence, item, compare) {
-          var beg = -1,
-              end = sequence.length - 1;
-          while (beg < end) {
-              var mid = beg + ((end - beg + 1) >>> 1);
-              if (compare(item, sequence[mid]) >= 0) {
-                  beg = mid;
-              } else {
-                  end = mid - 1;
-              }
-          }
-          return beg;
+            var beg = -1,
+                end = sequence.length - 1;
+            while (beg < end) {
+                var mid = beg + ((end - beg + 1) >>> 1);
+                if (compare(item, sequence[mid]) >= 0) {
+                    beg = mid;
+                } else {
+                    end = mid - 1;
+                }
+            }
+            return beg;
         }
 
         function _insert(q, data, priority, callback) {
     };
 
     function _console_fn(name) {
-        return function (fn) {
-            var args = _baseSlice(arguments, 1);
-            fn.apply(null, args.concat([function (err) {
-                var args = _baseSlice(arguments, 1);
+        return _restParam(function (fn, args) {
+            fn.apply(null, args.concat([_restParam(function (err, args) {
                 if (typeof console !== 'undefined') {
                     if (err) {
                         if (console.error) {
                         });
                     }
                 }
-            }]));
-        };
+            })]));
+        });
     }
     async.log = _console_fn('log');
     async.dir = _console_fn('dir');
     async.memoize = function (fn, hasher) {
         var memo = {};
         var queues = {};
-        hasher = hasher || function (x) {
-            return x;
-        };
-        function memoized() {
-            var args = _baseSlice(arguments);
+        hasher = hasher || identity;
+        var memoized = _restParam(function memoized(args) {
             var callback = args.pop();
             var key = hasher.apply(null, args);
             if (key in memo) {
             }
             else {
                 queues[key] = [callback];
-                fn.apply(null, args.concat([function () {
-                    memo[key] = _baseSlice(arguments);
+                fn.apply(null, args.concat([_restParam(function (args) {
+                    memo[key] = args;
                     var q = queues[key];
                     delete queues[key];
                     for (var i = 0, l = q.length; i < l; i++) {
-                      q[i].apply(null, arguments);
+                        q[i].apply(null, args);
                     }
-                }]));
+                })]));
             }
-        }
+        });
         memoized.memo = memo;
         memoized.unmemoized = fn;
         return memoized;
 
     async.seq = function (/* functions... */) {
         var fns = arguments;
-        return function () {
+        return _restParam(function (args) {
             var that = this;
-            var args = _baseSlice(arguments);
 
-            var callback = args.slice(-1)[0];
+            var callback = args[args.length - 1];
             if (typeof callback == 'function') {
                 args.pop();
             } else {
             }
 
             async.reduce(fns, args, function (newargs, fn, cb) {
-                fn.apply(that, newargs.concat([function () {
-                    var err = arguments[0];
-                    var nextargs = _baseSlice(arguments, 1);
+                fn.apply(that, newargs.concat([_restParam(function (err, nextargs) {
                     cb(err, nextargs);
-                }]));
+                })]));
             },
             function (err, results) {
                 callback.apply(that, [err].concat(results));
             });
-        };
+        });
     };
 
     async.compose = function (/* functions... */) {
     };
 
 
-    function _applyEach(eachfn, fns /*args...*/) {
-        function go() {
-            var that = this;
-            var args = _baseSlice(arguments);
-            var callback = args.pop();
-            return eachfn(fns, function (fn, _, cb) {
-                fn.apply(that, args.concat([cb]));
-            },
-            callback);
-        }
-        if (arguments.length > 2) {
-            var args = _baseSlice(arguments, 2);
-            return go.apply(this, args);
-        }
-        else {
-            return go;
-        }
+    function _applyEach(eachfn) {
+        return _restParam(function(fns, args) {
+            var go = _restParam(function(args) {
+                var that = this;
+                var callback = args.pop();
+                return eachfn(fns, function (fn, _, cb) {
+                    fn.apply(that, args.concat([cb]));
+                },
+                callback);
+            });
+            if (args.length) {
+                return go.apply(this, args);
+            }
+            else {
+                return go;
+            }
+        });
     }
 
-    async.applyEach = function (/*fns, args...*/) {
-        var args = _baseSlice(arguments);
-        return _applyEach.apply(null, [async.eachOf].concat(args));
-    };
-    async.applyEachSeries = function (/*fns, args...*/) {
-        var args = _baseSlice(arguments);
-        return _applyEach.apply(null, [async.eachOfSeries].concat(args));
-    };
+    async.applyEach = _applyEach(async.eachOf);
+    async.applyEachSeries = _applyEach(async.eachOfSeries);
 
 
     async.forever = function (fn, callback) {
     };
 
     function ensureAsync(fn) {
-        return function (/*...args, callback*/) {
-            var args = _baseSlice(arguments);
+        return _restParam(function (args) {
             var callback = args.pop();
             args.push(function () {
                 var innerArgs = arguments;
             var sync = true;
             fn.apply(this, args);
             sync = false;
-        };
+        });
     }
 
     async.ensureAsync = ensureAsync;
 
-    async.constant = function constant(/*values...*/) {
-        var args = [null].concat(_baseSlice(arguments));
+    async.constant = _restParam(function(values) {
+        var args = [null].concat(values);
         return function (callback) {
             return callback.apply(this, args);
         };
-    };
+    });
 
     async.wrapSync =
     async.asyncify = function asyncify(func) {
-        return function (/*args..., callback*/) {
-            var args = _baseSlice(arguments);
+        return _restParam(function (args) {
             var callback = args.pop();
             var result;
             try {
             } catch (e) {
                 return callback(e);
             }
-            callback(null, result);
-        };
+            // if result is Promise object
+            if (typeof result !== 'undefined' && typeof result.then === "function") {
+                result.then(function(value) {
+                    callback(null, value);
+                }).catch(function(err) {
+                    callback(err.message ? err : new Error(err));
+                });
+            } else {
+                callback(null, result);
+            }
+        });
     };
 
     // Node.js
index 7ef0bbe..2b8128b 100644 (file)
@@ -5,7 +5,7 @@
   "author": {
     "name": "Caolan McMahon"
   },
-  "version": "1.3.0",
+  "version": "1.4.0",
   "keywords": [
     "async",
     "callback",
   "license": "MIT",
   "devDependencies": {
     "benchmark": "github:bestiejs/benchmark.js",
+    "bluebird": "^2.9.32",
     "coveralls": "^2.11.2",
+    "es6-promise": "^2.3.0",
+    "jscs": "^1.13.1",
     "jshint": "~2.8.0",
     "lodash": "^3.9.0",
     "mkdirp": "~0.5.1",
+    "native-promise-only": "^0.8.0-a",
     "nodeunit": ">0.0.0",
     "nyc": "^2.1.0",
+    "rsvp": "^3.0.18",
     "uglify-js": "~2.4.0",
     "xyz": "^0.5.0",
     "yargs": "~3.9.1"
@@ -45,7 +50,7 @@
   },
   "scripts": {
     "test": "npm run-script lint && nodeunit test/test-async.js",
-    "lint": "jshint lib/*.js test/*.js perf/*.js",
+    "lint": "jshint lib/*.js test/*.js perf/*.js && jscs lib/*.js test/*.js perf/*.js",
     "coverage": "nyc npm test && nyc report",
     "coveralls": "nyc npm test && nyc report --reporter=text-lcov | coveralls"
   },
       "tests"
     ]
   },
-  "gitHead": "71fa2638973dafd8761fa5457c472a312cc820fe",
+  "gitHead": "5bfcd31c72e003f96df025e75753463da61f49f9",
   "homepage": "https://github.com/caolan/async#readme",
-  "_id": "async@1.3.0",
-  "_shasum": "a6f1631e8a595a663496d0a5586bd12007d4871d",
+  "_id": "async@1.4.0",
+  "_shasum": "35f86f83c59e0421d099cd9a91d8278fb578c00d",
   "_from": "async@>=1.2.1 <2.0.0",
-  "_npmVersion": "2.9.1",
-  "_nodeVersion": "0.12.3",
+  "_npmVersion": "2.13.0",
+  "_nodeVersion": "2.4.0",
   "_npmUser": {
-    "name": "aearly",
-    "email": "alexander.early@gmail.com"
+    "name": "megawac",
+    "email": "megawac@gmail.com"
+  },
+  "dist": {
+    "shasum": "35f86f83c59e0421d099cd9a91d8278fb578c00d",
+    "tarball": "http://registry.npmjs.org/async/-/async-1.4.0.tgz"
   },
   "maintainers": [
     {
     {
       "name": "aearly",
       "email": "alexander.early@gmail.com"
+    },
+    {
+      "name": "megawac",
+      "email": "megawac@gmail.com"
     }
   ],
-  "dist": {
-    "shasum": "a6f1631e8a595a663496d0a5586bd12007d4871d",
-    "tarball": "http://registry.npmjs.org/async/-/async-1.3.0.tgz"
-  },
   "directories": {},
-  "_resolved": "https://registry.npmjs.org/async/-/async-1.3.0.tgz",
+  "_resolved": "https://registry.npmjs.org/async/-/async-1.4.0.tgz",
   "readme": "ERROR: No README data found!"
 }
diff --git a/deps/npm/node_modules/request/node_modules/form-data/node_modules/mime-types/HISTORY.md b/deps/npm/node_modules/request/node_modules/form-data/node_modules/mime-types/HISTORY.md
deleted file mode 100644 (file)
index 30c1726..0000000
+++ /dev/null
@@ -1,141 +0,0 @@
-2.1.2 / 2015-06-25
-==================
-
-  * deps: mime-db@~1.14.0
-    - Add new mime types
-
-2.1.1 / 2015-06-08
-==================
-
-  * perf: fix deopt during mapping
-
-2.1.0 / 2015-06-07
-==================
-
-  * Fix incorrectly treating extension-less file name as extension
-    - i.e. `'path/to/json'` will no longer return `application/json`
-  * Fix `.charset(type)` to accept parameters
-  * Fix `.charset(type)` to match case-insensitive
-  * Improve generation of extension to MIME mapping
-  * Refactor internals for readability and no argument reassignment
-  * Prefer `application/*` MIME types from the same source
-  * Prefer any type over `application/octet-stream`
-  * deps: mime-db@~1.13.0
-    - Add nginx as a source
-    - Add new mime types
-
-2.0.14 / 2015-06-06
-===================
-
-  * deps: mime-db@~1.12.0
-    - Add new mime types
-
-2.0.13 / 2015-05-31
-===================
-
-  * deps: mime-db@~1.11.0
-    - Add new mime types
-
-2.0.12 / 2015-05-19
-===================
-
-  * deps: mime-db@~1.10.0
-    - Add new mime types
-
-2.0.11 / 2015-05-05
-===================
-
-  * deps: mime-db@~1.9.1
-    - Add new mime types
-
-2.0.10 / 2015-03-13
-===================
-
-  * deps: mime-db@~1.8.0
-    - Add new mime types
-
-2.0.9 / 2015-02-09
-==================
-
-  * deps: mime-db@~1.7.0
-    - Add new mime types
-    - Community extensions ownership transferred from `node-mime`
-
-2.0.8 / 2015-01-29
-==================
-
-  * deps: mime-db@~1.6.0
-    - Add new mime types
-
-2.0.7 / 2014-12-30
-==================
-
-  * deps: mime-db@~1.5.0
-    - Add new mime types
-    - Fix various invalid MIME type entries
-
-2.0.6 / 2014-12-30
-==================
-
-  * deps: mime-db@~1.4.0
-    - Add new mime types
-    - Fix various invalid MIME type entries
-    - Remove example template MIME types
-
-2.0.5 / 2014-12-29
-==================
-
-  * deps: mime-db@~1.3.1
-    - Fix missing extensions
-
-2.0.4 / 2014-12-10
-==================
-
-  * deps: mime-db@~1.3.0
-    - Add new mime types
-
-2.0.3 / 2014-11-09
-==================
-
-  * deps: mime-db@~1.2.0
-    - Add new mime types
-
-2.0.2 / 2014-09-28
-==================
-
-  * deps: mime-db@~1.1.0
-    - Add new mime types
-    - Add additional compressible
-    - Update charsets
-
-2.0.1 / 2014-09-07
-==================
-
-  * Support Node.js 0.6
-
-2.0.0 / 2014-09-02
-==================
-
-  * Use `mime-db`
-  * Remove `.define()`
-
-1.0.2 / 2014-08-04
-==================
-
-  * Set charset=utf-8 for `text/javascript`
-
-1.0.1 / 2014-06-24
-==================
-
-  * Add `text/jsx` type
-
-1.0.0 / 2014-05-12
-==================
-
-  * Return `false` for unknown types
-  * Set charset=utf-8 for `application/json`
-
-0.1.0 / 2014-05-02
-==================
-
-  * Initial release
diff --git a/deps/npm/node_modules/request/node_modules/form-data/node_modules/mime-types/LICENSE b/deps/npm/node_modules/request/node_modules/form-data/node_modules/mime-types/LICENSE
deleted file mode 100644 (file)
index 0616607..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-(The MIT License)
-
-Copyright (c) 2014 Jonathan Ong <me@jongleberry.com>
-Copyright (c) 2015 Douglas Christopher Wilson <doug@somethingdoug.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 --git a/deps/npm/node_modules/request/node_modules/form-data/node_modules/mime-types/README.md b/deps/npm/node_modules/request/node_modules/form-data/node_modules/mime-types/README.md
deleted file mode 100644 (file)
index e26295d..0000000
+++ /dev/null
@@ -1,103 +0,0 @@
-# mime-types
-
-[![NPM Version][npm-image]][npm-url]
-[![NPM Downloads][downloads-image]][downloads-url]
-[![Node.js Version][node-version-image]][node-version-url]
-[![Build Status][travis-image]][travis-url]
-[![Test Coverage][coveralls-image]][coveralls-url]
-
-The ultimate javascript content-type utility.
-
-Similar to [node-mime](https://github.com/broofa/node-mime), except:
-
-- __No fallbacks.__ Instead of naively returning the first available type, `mime-types` simply returns `false`,
-  so do `var type = mime.lookup('unrecognized') || 'application/octet-stream'`.
-- No `new Mime()` business, so you could do `var lookup = require('mime-types').lookup`.
-- Additional mime types are added such as jade and stylus via [mime-db](https://github.com/jshttp/mime-db)
-- No `.define()` functionality
-
-Otherwise, the API is compatible.
-
-## Install
-
-```sh
-$ npm install mime-types
-```
-
-## Adding Types
-
-All mime types are based on [mime-db](https://github.com/jshttp/mime-db),
-so open a PR there if you'd like to add mime types.
-
-## API
-
-```js
-var mime = require('mime-types')
-```
-
-All functions return `false` if input is invalid or not found.
-
-### mime.lookup(path)
-
-Lookup the content-type associated with a file.
-
-```js
-mime.lookup('json')             // 'application/json'
-mime.lookup('.md')              // 'text/x-markdown'
-mime.lookup('file.html')        // 'text/html'
-mime.lookup('folder/file.js')   // 'application/javascript'
-mime.lookup('folder/.htaccess') // false
-
-mime.lookup('cats') // false
-```
-
-### mime.contentType(type)
-
-Create a full content-type header given a content-type or extension.
-
-```js
-mime.contentType('markdown')  // 'text/x-markdown; charset=utf-8'
-mime.contentType('file.json') // 'application/json; charset=utf-8'
-
-// from a full path
-mime.contentType(path.extname('/path/to/file.json')) // 'application/json; charset=utf-8'
-```
-
-### mime.extension(type)
-
-Get the default extension for a content-type.
-
-```js
-mime.extension('application/octet-stream') // 'bin'
-```
-
-### mime.charset(type)
-
-Lookup the implied default charset of a content-type.
-
-```js
-mime.charset('text/x-markdown') // 'UTF-8'
-```
-
-### var type = mime.types[extension]
-
-A map of content-types by extension.
-
-### [extensions...] = mime.extensions[type]
-
-A map of extensions by content-type.
-
-## License
-
-[MIT](LICENSE)
-
-[npm-image]: https://img.shields.io/npm/v/mime-types.svg
-[npm-url]: https://npmjs.org/package/mime-types
-[node-version-image]: https://img.shields.io/node/v/mime-types.svg
-[node-version-url]: http://nodejs.org/download/
-[travis-image]: https://img.shields.io/travis/jshttp/mime-types/master.svg
-[travis-url]: https://travis-ci.org/jshttp/mime-types
-[coveralls-image]: https://img.shields.io/coveralls/jshttp/mime-types/master.svg
-[coveralls-url]: https://coveralls.io/r/jshttp/mime-types
-[downloads-image]: https://img.shields.io/npm/dm/mime-types.svg
-[downloads-url]: https://npmjs.org/package/mime-types
diff --git a/deps/npm/node_modules/request/node_modules/form-data/node_modules/mime-types/index.js b/deps/npm/node_modules/request/node_modules/form-data/node_modules/mime-types/index.js
deleted file mode 100644 (file)
index 9edf72b..0000000
+++ /dev/null
@@ -1,188 +0,0 @@
-/*!
- * mime-types
- * Copyright(c) 2014 Jonathan Ong
- * Copyright(c) 2015 Douglas Christopher Wilson
- * MIT Licensed
- */
-
-'use strict'
-
-/**
- * Module dependencies.
- * @private
- */
-
-var db = require('mime-db')
-var extname = require('path').extname
-
-/**
- * Module variables.
- * @private
- */
-
-var extractTypeRegExp = /^\s*([^;\s]*)(?:;|\s|$)/
-var textTypeRegExp = /^text\//i
-
-/**
- * Module exports.
- * @public
- */
-
-exports.charset = charset
-exports.charsets = { lookup: charset }
-exports.contentType = contentType
-exports.extension = extension
-exports.extensions = Object.create(null)
-exports.lookup = lookup
-exports.types = Object.create(null)
-
-// Populate the extensions/types maps
-populateMaps(exports.extensions, exports.types)
-
-/**
- * Get the default charset for a MIME type.
- *
- * @param {string} type
- * @return {boolean|string}
- */
-
-function charset(type) {
-  if (!type || typeof type !== 'string') {
-    return false
-  }
-
-  // TODO: use media-typer
-  var match = extractTypeRegExp.exec(type)
-  var mime = match && db[match[1].toLowerCase()]
-
-  if (mime && mime.charset) {
-    return mime.charset
-  }
-
-  // default text/* to utf-8
-  if (match && textTypeRegExp.test(match[1])) {
-    return 'UTF-8'
-  }
-
-  return false
-}
-
-/**
- * Create a full Content-Type header given a MIME type or extension.
- *
- * @param {string} str
- * @return {boolean|string}
- */
-
-function contentType(str) {
-  // TODO: should this even be in this module?
-  if (!str || typeof str !== 'string') {
-    return false
-  }
-
-  var mime = str.indexOf('/') === -1
-    ? exports.lookup(str)
-    : str
-
-  if (!mime) {
-    return false
-  }
-
-  // TODO: use content-type or other module
-  if (mime.indexOf('charset') === -1) {
-    var charset = exports.charset(mime)
-    if (charset) mime += '; charset=' + charset.toLowerCase()
-  }
-
-  return mime
-}
-
-/**
- * Get the default extension for a MIME type.
- *
- * @param {string} type
- * @return {boolean|string}
- */
-
-function extension(type) {
-  if (!type || typeof type !== 'string') {
-    return false
-  }
-
-  // TODO: use media-typer
-  var match = extractTypeRegExp.exec(type)
-
-  // get extensions
-  var exts = match && exports.extensions[match[1].toLowerCase()]
-
-  if (!exts || !exts.length) {
-    return false
-  }
-
-  return exts[0]
-}
-
-/**
- * Lookup the MIME type for a file path/extension.
- *
- * @param {string} path
- * @return {boolean|string}
- */
-
-function lookup(path) {
-  if (!path || typeof path !== 'string') {
-    return false
-  }
-
-  // get the extension ("ext" or ".ext" or full path)
-  var extension = extname('x.' + path)
-    .toLowerCase()
-    .substr(1)
-
-  if (!extension) {
-    return false
-  }
-
-  return exports.types[extension] || false
-}
-
-/**
- * Populate the extensions and types maps.
- * @private
- */
-
-function populateMaps(extensions, types) {
-  // source preference (least -> most)
-  var preference = ['nginx', 'apache', undefined, 'iana']
-
-  Object.keys(db).forEach(function forEachMimeType(type) {
-    var mime = db[type]
-    var exts = mime.extensions
-
-    if (!exts || !exts.length) {
-      return
-    }
-
-    // mime -> extensions
-    extensions[type] = exts
-
-    // extension -> mime
-    for (var i = 0; i < exts.length; i++) {
-      var extension = exts[i]
-
-      if (types[extension]) {
-        var from = preference.indexOf(db[types[extension]].source)
-        var to = preference.indexOf(mime.source)
-
-        if (types[extension] !== 'application/octet-stream'
-          && from > to || (from === to && types[extension].substr(0, 12) === 'application/')) {
-          // skip the remapping
-          return
-        }
-      }
-
-      // set the extension -> mime
-      types[extension] = type
-    }
-  })
-}
diff --git a/deps/npm/node_modules/request/node_modules/form-data/node_modules/mime-types/node_modules/mime-db/HISTORY.md b/deps/npm/node_modules/request/node_modules/form-data/node_modules/mime-types/node_modules/mime-db/HISTORY.md
deleted file mode 100644 (file)
index c7db14e..0000000
+++ /dev/null
@@ -1,236 +0,0 @@
-1.14.0 / 2015-06-25
-===================
-
-  * Add `application/scim+json`
-  * Add `application/vnd.3gpp.ussd+xml`
-  * Add `application/vnd.biopax.rdf+xml`
-  * Add `text/x-processing`
-
-1.13.0 / 2015-06-07
-===================
-
-  * Add nginx as a source
-  * Add `application/x-cocoa`
-  * Add `application/x-java-archive-diff`
-  * Add `application/x-makeself`
-  * Add `application/x-perl`
-  * Add `application/x-pilot`
-  * Add `application/x-redhat-package-manager`
-  * Add `application/x-sea`
-  * Add `audio/x-m4a`
-  * Add `audio/x-realaudio`
-  * Add `image/x-jng`
-  * Add `text/mathml`
-
-1.12.0 / 2015-06-05
-===================
-
-  * Add `application/bdoc`
-  * Add `application/vnd.hyperdrive+json`
-  * Add `application/x-bdoc`
-  * Add extension `.rtf` to `text/rtf`
-
-1.11.0 / 2015-05-31
-===================
-
-  * Add `audio/wav`
-  * Add `audio/wave`
-  * Add extension `.litcoffee` to `text/coffeescript`
-  * Add extension `.sfd-hdstx` to `application/vnd.hydrostatix.sof-data`
-  * Add extension `.n-gage` to `application/vnd.nokia.n-gage.symbian.install`
-
-1.10.0 / 2015-05-19
-===================
-
-  * Add `application/vnd.balsamiq.bmpr`
-  * Add `application/vnd.microsoft.portable-executable`
-  * Add `application/x-ns-proxy-autoconfig`
-
-1.9.1 / 2015-04-19
-==================
-
-  * Remove `.json` extension from `application/manifest+json`
-    - This is causing bugs downstream
-
-1.9.0 / 2015-04-19
-==================
-
-  * Add `application/manifest+json`
-  * Add `application/vnd.micro+json`
-  * Add `image/vnd.zbrush.pcx`
-  * Add `image/x-ms-bmp`
-
-1.8.0 / 2015-03-13
-==================
-
-  * Add `application/vnd.citationstyles.style+xml`
-  * Add `application/vnd.fastcopy-disk-image`
-  * Add `application/vnd.gov.sk.xmldatacontainer+xml`
-  * Add extension `.jsonld` to `application/ld+json`
-
-1.7.0 / 2015-02-08
-==================
-
-  * Add `application/vnd.gerber`
-  * Add `application/vnd.msa-disk-image`
-
-1.6.1 / 2015-02-05
-==================
-
-  * Community extensions ownership transferred from `node-mime`
-
-1.6.0 / 2015-01-29
-==================
-
-  * Add `application/jose`
-  * Add `application/jose+json`
-  * Add `application/json-seq`
-  * Add `application/jwk+json`
-  * Add `application/jwk-set+json`
-  * Add `application/jwt`
-  * Add `application/rdap+json`
-  * Add `application/vnd.gov.sk.e-form+xml`
-  * Add `application/vnd.ims.imsccv1p3`
-
-1.5.0 / 2014-12-30
-==================
-
-  * Add `application/vnd.oracle.resource+json`
-  * Fix various invalid MIME type entries
-    - `application/mbox+xml`
-    - `application/oscp-response`
-    - `application/vwg-multiplexed`
-    - `audio/g721`
-
-1.4.0 / 2014-12-21
-==================
-
-  * Add `application/vnd.ims.imsccv1p2`
-  * Fix various invalid MIME type entries
-    - `application/vnd-acucobol`
-    - `application/vnd-curl`
-    - `application/vnd-dart`
-    - `application/vnd-dxr`
-    - `application/vnd-fdf`
-    - `application/vnd-mif`
-    - `application/vnd-sema`
-    - `application/vnd-wap-wmlc`
-    - `application/vnd.adobe.flash-movie`
-    - `application/vnd.dece-zip`
-    - `application/vnd.dvb_service`
-    - `application/vnd.micrografx-igx`
-    - `application/vnd.sealed-doc`
-    - `application/vnd.sealed-eml`
-    - `application/vnd.sealed-mht`
-    - `application/vnd.sealed-ppt`
-    - `application/vnd.sealed-tiff`
-    - `application/vnd.sealed-xls`
-    - `application/vnd.sealedmedia.softseal-html`
-    - `application/vnd.sealedmedia.softseal-pdf`
-    - `application/vnd.wap-slc`
-    - `application/vnd.wap-wbxml`
-    - `audio/vnd.sealedmedia.softseal-mpeg`
-    - `image/vnd-djvu`
-    - `image/vnd-svf`
-    - `image/vnd-wap-wbmp`
-    - `image/vnd.sealed-png`
-    - `image/vnd.sealedmedia.softseal-gif`
-    - `image/vnd.sealedmedia.softseal-jpg`
-    - `model/vnd-dwf`
-    - `model/vnd.parasolid.transmit-binary`
-    - `model/vnd.parasolid.transmit-text`
-    - `text/vnd-a`
-    - `text/vnd-curl`
-    - `text/vnd.wap-wml`
-  * Remove example template MIME types
-    - `application/example`
-    - `audio/example`
-    - `image/example`
-    - `message/example`
-    - `model/example`
-    - `multipart/example`
-    - `text/example`
-    - `video/example`
-
-1.3.1 / 2014-12-16
-==================
-
-  * Fix missing extensions
-    - `application/json5`
-    - `text/hjson`
-
-1.3.0 / 2014-12-07
-==================
-
-  * Add `application/a2l`
-  * Add `application/aml`
-  * Add `application/atfx`
-  * Add `application/atxml`
-  * Add `application/cdfx+xml`
-  * Add `application/dii`
-  * Add `application/json5`
-  * Add `application/lxf`
-  * Add `application/mf4`
-  * Add `application/vnd.apache.thrift.compact`
-  * Add `application/vnd.apache.thrift.json`
-  * Add `application/vnd.coffeescript`
-  * Add `application/vnd.enphase.envoy`
-  * Add `application/vnd.ims.imsccv1p1`
-  * Add `text/csv-schema`
-  * Add `text/hjson`
-  * Add `text/markdown`
-  * Add `text/yaml`
-
-1.2.0 / 2014-11-09
-==================
-
-  * Add `application/cea`
-  * Add `application/dit`
-  * Add `application/vnd.gov.sk.e-form+zip`
-  * Add `application/vnd.tmd.mediaflex.api+xml`
-  * Type `application/epub+zip` is now IANA-registered
-
-1.1.2 / 2014-10-23
-==================
-
-  * Rebuild database for `application/x-www-form-urlencoded` change
-
-1.1.1 / 2014-10-20
-==================
-
-  * Mark `application/x-www-form-urlencoded` as compressible.
-
-1.1.0 / 2014-09-28
-==================
-
-  * Add `application/font-woff2`
-
-1.0.3 / 2014-09-25
-==================
-
-  * Fix engine requirement in package
-
-1.0.2 / 2014-09-25
-==================
-
-  * Add `application/coap-group+json`
-  * Add `application/dcd`
-  * Add `application/vnd.apache.thrift.binary`
-  * Add `image/vnd.tencent.tap`
-  * Mark all JSON-derived types as compressible
-  * Update `text/vtt` data
-
-1.0.1 / 2014-08-30
-==================
-
-  * Fix extension ordering
-
-1.0.0 / 2014-08-30
-==================
-
-  * Add `application/atf`
-  * Add `application/merge-patch+json`
-  * Add `multipart/x-mixed-replace`
-  * Add `source: 'apache'` metadata
-  * Add `source: 'iana'` metadata
-  * Remove badly-assumed charset data
diff --git a/deps/npm/node_modules/request/node_modules/form-data/node_modules/mime-types/node_modules/mime-db/LICENSE b/deps/npm/node_modules/request/node_modules/form-data/node_modules/mime-types/node_modules/mime-db/LICENSE
deleted file mode 100644 (file)
index a7ae8ee..0000000
+++ /dev/null
@@ -1,22 +0,0 @@
-
-The MIT License (MIT)
-
-Copyright (c) 2014 Jonathan Ong me@jongleberry.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 --git a/deps/npm/node_modules/request/node_modules/form-data/node_modules/mime-types/node_modules/mime-db/README.md b/deps/npm/node_modules/request/node_modules/form-data/node_modules/mime-types/node_modules/mime-db/README.md
deleted file mode 100644 (file)
index faf387f..0000000
+++ /dev/null
@@ -1,82 +0,0 @@
-# mime-db
-
-[![NPM Version][npm-version-image]][npm-url]
-[![NPM Downloads][npm-downloads-image]][npm-url]
-[![Node.js Version][node-image]][node-url]
-[![Build Status][travis-image]][travis-url]
-[![Coverage Status][coveralls-image]][coveralls-url]
-
-This is a database of all mime types.
-It consists of a single, public JSON file and does not include any logic,
-allowing it to remain as un-opinionated as possible with an API.
-It aggregates data from the following sources:
-
-- http://www.iana.org/assignments/media-types/media-types.xhtml
-- http://svn.apache.org/repos/asf/httpd/httpd/trunk/docs/conf/mime.types
-- http://hg.nginx.org/nginx/raw-file/default/conf/mime.types
-
-## Installation
-
-```bash
-npm install mime-db
-```
-
-### Database Download
-
-If you're crazy enough to use this in the browser, you can just grab the
-JSON file using [RawGit](https://rawgit.com/). It is recommended to replace
-`master` with [a release tag](https://github.com/jshttp/mime-db/tags) as the
-JSON format may change in the future.
-
-```
-https://cdn.rawgit.com/jshttp/mime-db/master/db.json
-```
-
-## Usage
-
-```js
-var db = require('mime-db');
-
-// grab data on .js files
-var data = db['application/javascript'];
-```
-
-## Data Structure
-
-The JSON file is a map lookup for lowercased mime types.
-Each mime type has the following properties:
-
-- `.source` - where the mime type is defined.
-    If not set, it's probably a custom media type.
-    - `apache` - [Apache common media types](http://svn.apache.org/repos/asf/httpd/httpd/trunk/docs/conf/mime.types)
-    - `iana` - [IANA-defined media types](http://www.iana.org/assignments/media-types/media-types.xhtml)
-    - `nginx` - [nginx media types](http://hg.nginx.org/nginx/raw-file/default/conf/mime.types)
-- `.extensions[]` - known extensions associated with this mime type.
-- `.compressible` - whether a file of this type is can be gzipped.
-- `.charset` - the default charset associated with this type, if any.
-
-If unknown, every property could be `undefined`.
-
-## Contributing
-
-To edit the database, only make PRs against `src/custom.json` or
-`src/custom-suffix.json`.
-
-To update the build, run `npm run update`.
-
-## Adding Custom Media Types
-
-The best way to get new media types included in this library is to register
-them with the IANA. The community registration procedure is outlined in
-[RFC 6838 section 5](http://tools.ietf.org/html/rfc6838#section-5). Types
-registered with the IANA are automatically pulled into this library.
-
-[npm-version-image]: https://img.shields.io/npm/v/mime-db.svg
-[npm-downloads-image]: https://img.shields.io/npm/dm/mime-db.svg
-[npm-url]: https://npmjs.org/package/mime-db
-[travis-image]: https://img.shields.io/travis/jshttp/mime-db/master.svg
-[travis-url]: https://travis-ci.org/jshttp/mime-db
-[coveralls-image]: https://img.shields.io/coveralls/jshttp/mime-db/master.svg
-[coveralls-url]: https://coveralls.io/r/jshttp/mime-db?branch=master
-[node-image]: https://img.shields.io/node/v/mime-db.svg
-[node-url]: http://nodejs.org/download/
diff --git a/deps/npm/node_modules/request/node_modules/form-data/node_modules/mime-types/node_modules/mime-db/db.json b/deps/npm/node_modules/request/node_modules/form-data/node_modules/mime-types/node_modules/mime-db/db.json
deleted file mode 100644 (file)
index e217166..0000000
+++ /dev/null
@@ -1,6420 +0,0 @@
-{
-  "application/1d-interleaved-parityfec": {
-    "source": "iana"
-  },
-  "application/3gpdash-qoe-report+xml": {
-    "source": "iana"
-  },
-  "application/3gpp-ims+xml": {
-    "source": "iana"
-  },
-  "application/a2l": {
-    "source": "iana"
-  },
-  "application/activemessage": {
-    "source": "iana"
-  },
-  "application/alto-costmap+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/alto-costmapfilter+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/alto-directory+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/alto-endpointcost+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/alto-endpointcostparams+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/alto-endpointprop+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/alto-endpointpropparams+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/alto-error+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/alto-networkmap+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/alto-networkmapfilter+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/aml": {
-    "source": "iana"
-  },
-  "application/andrew-inset": {
-    "source": "iana",
-    "extensions": ["ez"]
-  },
-  "application/applefile": {
-    "source": "iana"
-  },
-  "application/applixware": {
-    "source": "apache",
-    "extensions": ["aw"]
-  },
-  "application/atf": {
-    "source": "iana"
-  },
-  "application/atfx": {
-    "source": "iana"
-  },
-  "application/atom+xml": {
-    "source": "iana",
-    "compressible": true,
-    "extensions": ["atom"]
-  },
-  "application/atomcat+xml": {
-    "source": "iana",
-    "extensions": ["atomcat"]
-  },
-  "application/atomdeleted+xml": {
-    "source": "iana"
-  },
-  "application/atomicmail": {
-    "source": "iana"
-  },
-  "application/atomsvc+xml": {
-    "source": "iana",
-    "extensions": ["atomsvc"]
-  },
-  "application/atxml": {
-    "source": "iana"
-  },
-  "application/auth-policy+xml": {
-    "source": "iana"
-  },
-  "application/bacnet-xdd+zip": {
-    "source": "iana"
-  },
-  "application/batch-smtp": {
-    "source": "iana"
-  },
-  "application/bdoc": {
-    "compressible": false,
-    "extensions": ["bdoc"]
-  },
-  "application/beep+xml": {
-    "source": "iana"
-  },
-  "application/calendar+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/calendar+xml": {
-    "source": "iana"
-  },
-  "application/call-completion": {
-    "source": "iana"
-  },
-  "application/cals-1840": {
-    "source": "iana"
-  },
-  "application/cbor": {
-    "source": "iana"
-  },
-  "application/ccmp+xml": {
-    "source": "iana"
-  },
-  "application/ccxml+xml": {
-    "source": "iana",
-    "extensions": ["ccxml"]
-  },
-  "application/cdfx+xml": {
-    "source": "iana"
-  },
-  "application/cdmi-capability": {
-    "source": "iana",
-    "extensions": ["cdmia"]
-  },
-  "application/cdmi-container": {
-    "source": "iana",
-    "extensions": ["cdmic"]
-  },
-  "application/cdmi-domain": {
-    "source": "iana",
-    "extensions": ["cdmid"]
-  },
-  "application/cdmi-object": {
-    "source": "iana",
-    "extensions": ["cdmio"]
-  },
-  "application/cdmi-queue": {
-    "source": "iana",
-    "extensions": ["cdmiq"]
-  },
-  "application/cea": {
-    "source": "iana"
-  },
-  "application/cea-2018+xml": {
-    "source": "iana"
-  },
-  "application/cellml+xml": {
-    "source": "iana"
-  },
-  "application/cfw": {
-    "source": "iana"
-  },
-  "application/cms": {
-    "source": "iana"
-  },
-  "application/cnrp+xml": {
-    "source": "iana"
-  },
-  "application/coap-group+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/commonground": {
-    "source": "iana"
-  },
-  "application/conference-info+xml": {
-    "source": "iana"
-  },
-  "application/cpl+xml": {
-    "source": "iana"
-  },
-  "application/csrattrs": {
-    "source": "iana"
-  },
-  "application/csta+xml": {
-    "source": "iana"
-  },
-  "application/cstadata+xml": {
-    "source": "iana"
-  },
-  "application/cu-seeme": {
-    "source": "apache",
-    "extensions": ["cu"]
-  },
-  "application/cybercash": {
-    "source": "iana"
-  },
-  "application/dart": {
-    "compressible": true
-  },
-  "application/dash+xml": {
-    "source": "iana",
-    "extensions": ["mdp"]
-  },
-  "application/dashdelta": {
-    "source": "iana"
-  },
-  "application/davmount+xml": {
-    "source": "iana",
-    "extensions": ["davmount"]
-  },
-  "application/dca-rft": {
-    "source": "iana"
-  },
-  "application/dcd": {
-    "source": "iana"
-  },
-  "application/dec-dx": {
-    "source": "iana"
-  },
-  "application/dialog-info+xml": {
-    "source": "iana"
-  },
-  "application/dicom": {
-    "source": "iana"
-  },
-  "application/dii": {
-    "source": "iana"
-  },
-  "application/dit": {
-    "source": "iana"
-  },
-  "application/dns": {
-    "source": "iana"
-  },
-  "application/docbook+xml": {
-    "source": "apache",
-    "extensions": ["dbk"]
-  },
-  "application/dskpp+xml": {
-    "source": "iana"
-  },
-  "application/dssc+der": {
-    "source": "iana",
-    "extensions": ["dssc"]
-  },
-  "application/dssc+xml": {
-    "source": "iana",
-    "extensions": ["xdssc"]
-  },
-  "application/dvcs": {
-    "source": "iana"
-  },
-  "application/ecmascript": {
-    "source": "iana",
-    "compressible": true,
-    "extensions": ["ecma"]
-  },
-  "application/edi-consent": {
-    "source": "iana"
-  },
-  "application/edi-x12": {
-    "source": "iana",
-    "compressible": false
-  },
-  "application/edifact": {
-    "source": "iana",
-    "compressible": false
-  },
-  "application/emma+xml": {
-    "source": "iana",
-    "extensions": ["emma"]
-  },
-  "application/emotionml+xml": {
-    "source": "iana"
-  },
-  "application/encaprtp": {
-    "source": "iana"
-  },
-  "application/epp+xml": {
-    "source": "iana"
-  },
-  "application/epub+zip": {
-    "source": "iana",
-    "extensions": ["epub"]
-  },
-  "application/eshop": {
-    "source": "iana"
-  },
-  "application/exi": {
-    "source": "iana",
-    "extensions": ["exi"]
-  },
-  "application/fastinfoset": {
-    "source": "iana"
-  },
-  "application/fastsoap": {
-    "source": "iana"
-  },
-  "application/fdt+xml": {
-    "source": "iana"
-  },
-  "application/fits": {
-    "source": "iana"
-  },
-  "application/font-sfnt": {
-    "source": "iana"
-  },
-  "application/font-tdpfr": {
-    "source": "iana",
-    "extensions": ["pfr"]
-  },
-  "application/font-woff": {
-    "source": "iana",
-    "compressible": false,
-    "extensions": ["woff"]
-  },
-  "application/font-woff2": {
-    "compressible": false,
-    "extensions": ["woff2"]
-  },
-  "application/framework-attributes+xml": {
-    "source": "iana"
-  },
-  "application/gml+xml": {
-    "source": "apache",
-    "extensions": ["gml"]
-  },
-  "application/gpx+xml": {
-    "source": "apache",
-    "extensions": ["gpx"]
-  },
-  "application/gxf": {
-    "source": "apache",
-    "extensions": ["gxf"]
-  },
-  "application/gzip": {
-    "source": "iana",
-    "compressible": false
-  },
-  "application/h224": {
-    "source": "iana"
-  },
-  "application/held+xml": {
-    "source": "iana"
-  },
-  "application/http": {
-    "source": "iana"
-  },
-  "application/hyperstudio": {
-    "source": "iana",
-    "extensions": ["stk"]
-  },
-  "application/ibe-key-request+xml": {
-    "source": "iana"
-  },
-  "application/ibe-pkg-reply+xml": {
-    "source": "iana"
-  },
-  "application/ibe-pp-data": {
-    "source": "iana"
-  },
-  "application/iges": {
-    "source": "iana"
-  },
-  "application/im-iscomposing+xml": {
-    "source": "iana"
-  },
-  "application/index": {
-    "source": "iana"
-  },
-  "application/index.cmd": {
-    "source": "iana"
-  },
-  "application/index.obj": {
-    "source": "iana"
-  },
-  "application/index.response": {
-    "source": "iana"
-  },
-  "application/index.vnd": {
-    "source": "iana"
-  },
-  "application/inkml+xml": {
-    "source": "iana",
-    "extensions": ["ink","inkml"]
-  },
-  "application/iotp": {
-    "source": "iana"
-  },
-  "application/ipfix": {
-    "source": "iana",
-    "extensions": ["ipfix"]
-  },
-  "application/ipp": {
-    "source": "iana"
-  },
-  "application/isup": {
-    "source": "iana"
-  },
-  "application/its+xml": {
-    "source": "iana"
-  },
-  "application/java-archive": {
-    "source": "apache",
-    "compressible": false,
-    "extensions": ["jar","war","ear"]
-  },
-  "application/java-serialized-object": {
-    "source": "apache",
-    "compressible": false,
-    "extensions": ["ser"]
-  },
-  "application/java-vm": {
-    "source": "apache",
-    "compressible": false,
-    "extensions": ["class"]
-  },
-  "application/javascript": {
-    "source": "iana",
-    "charset": "UTF-8",
-    "compressible": true,
-    "extensions": ["js"]
-  },
-  "application/jose": {
-    "source": "iana"
-  },
-  "application/jose+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/jrd+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/json": {
-    "source": "iana",
-    "charset": "UTF-8",
-    "compressible": true,
-    "extensions": ["json","map"]
-  },
-  "application/json-patch+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/json-seq": {
-    "source": "iana"
-  },
-  "application/json5": {
-    "extensions": ["json5"]
-  },
-  "application/jsonml+json": {
-    "source": "apache",
-    "compressible": true,
-    "extensions": ["jsonml"]
-  },
-  "application/jwk+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/jwk-set+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/jwt": {
-    "source": "iana"
-  },
-  "application/kpml-request+xml": {
-    "source": "iana"
-  },
-  "application/kpml-response+xml": {
-    "source": "iana"
-  },
-  "application/ld+json": {
-    "source": "iana",
-    "compressible": true,
-    "extensions": ["jsonld"]
-  },
-  "application/link-format": {
-    "source": "iana"
-  },
-  "application/load-control+xml": {
-    "source": "iana"
-  },
-  "application/lost+xml": {
-    "source": "iana",
-    "extensions": ["lostxml"]
-  },
-  "application/lostsync+xml": {
-    "source": "iana"
-  },
-  "application/lxf": {
-    "source": "iana"
-  },
-  "application/mac-binhex40": {
-    "source": "iana",
-    "extensions": ["hqx"]
-  },
-  "application/mac-compactpro": {
-    "source": "apache",
-    "extensions": ["cpt"]
-  },
-  "application/macwriteii": {
-    "source": "iana"
-  },
-  "application/mads+xml": {
-    "source": "iana",
-    "extensions": ["mads"]
-  },
-  "application/manifest+json": {
-    "charset": "UTF-8",
-    "compressible": true,
-    "extensions": ["webmanifest"]
-  },
-  "application/marc": {
-    "source": "iana",
-    "extensions": ["mrc"]
-  },
-  "application/marcxml+xml": {
-    "source": "iana",
-    "extensions": ["mrcx"]
-  },
-  "application/mathematica": {
-    "source": "iana",
-    "extensions": ["ma","nb","mb"]
-  },
-  "application/mathml+xml": {
-    "source": "iana",
-    "extensions": ["mathml"]
-  },
-  "application/mathml-content+xml": {
-    "source": "iana"
-  },
-  "application/mathml-presentation+xml": {
-    "source": "iana"
-  },
-  "application/mbms-associated-procedure-description+xml": {
-    "source": "iana"
-  },
-  "application/mbms-deregister+xml": {
-    "source": "iana"
-  },
-  "application/mbms-envelope+xml": {
-    "source": "iana"
-  },
-  "application/mbms-msk+xml": {
-    "source": "iana"
-  },
-  "application/mbms-msk-response+xml": {
-    "source": "iana"
-  },
-  "application/mbms-protection-description+xml": {
-    "source": "iana"
-  },
-  "application/mbms-reception-report+xml": {
-    "source": "iana"
-  },
-  "application/mbms-register+xml": {
-    "source": "iana"
-  },
-  "application/mbms-register-response+xml": {
-    "source": "iana"
-  },
-  "application/mbms-schedule+xml": {
-    "source": "iana"
-  },
-  "application/mbms-user-service-description+xml": {
-    "source": "iana"
-  },
-  "application/mbox": {
-    "source": "iana",
-    "extensions": ["mbox"]
-  },
-  "application/media-policy-dataset+xml": {
-    "source": "iana"
-  },
-  "application/media_control+xml": {
-    "source": "iana"
-  },
-  "application/mediaservercontrol+xml": {
-    "source": "iana",
-    "extensions": ["mscml"]
-  },
-  "application/merge-patch+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/metalink+xml": {
-    "source": "apache",
-    "extensions": ["metalink"]
-  },
-  "application/metalink4+xml": {
-    "source": "iana",
-    "extensions": ["meta4"]
-  },
-  "application/mets+xml": {
-    "source": "iana",
-    "extensions": ["mets"]
-  },
-  "application/mf4": {
-    "source": "iana"
-  },
-  "application/mikey": {
-    "source": "iana"
-  },
-  "application/mods+xml": {
-    "source": "iana",
-    "extensions": ["mods"]
-  },
-  "application/moss-keys": {
-    "source": "iana"
-  },
-  "application/moss-signature": {
-    "source": "iana"
-  },
-  "application/mosskey-data": {
-    "source": "iana"
-  },
-  "application/mosskey-request": {
-    "source": "iana"
-  },
-  "application/mp21": {
-    "source": "iana",
-    "extensions": ["m21","mp21"]
-  },
-  "application/mp4": {
-    "source": "iana",
-    "extensions": ["mp4s","m4p"]
-  },
-  "application/mpeg4-generic": {
-    "source": "iana"
-  },
-  "application/mpeg4-iod": {
-    "source": "iana"
-  },
-  "application/mpeg4-iod-xmt": {
-    "source": "iana"
-  },
-  "application/mrb-consumer+xml": {
-    "source": "iana"
-  },
-  "application/mrb-publish+xml": {
-    "source": "iana"
-  },
-  "application/msc-ivr+xml": {
-    "source": "iana"
-  },
-  "application/msc-mixer+xml": {
-    "source": "iana"
-  },
-  "application/msword": {
-    "source": "iana",
-    "compressible": false,
-    "extensions": ["doc","dot"]
-  },
-  "application/mxf": {
-    "source": "iana",
-    "extensions": ["mxf"]
-  },
-  "application/nasdata": {
-    "source": "iana"
-  },
-  "application/news-checkgroups": {
-    "source": "iana"
-  },
-  "application/news-groupinfo": {
-    "source": "iana"
-  },
-  "application/news-transmission": {
-    "source": "iana"
-  },
-  "application/nlsml+xml": {
-    "source": "iana"
-  },
-  "application/nss": {
-    "source": "iana"
-  },
-  "application/ocsp-request": {
-    "source": "iana"
-  },
-  "application/ocsp-response": {
-    "source": "iana"
-  },
-  "application/octet-stream": {
-    "source": "iana",
-    "compressible": false,
-    "extensions": ["bin","dms","lrf","mar","so","dist","distz","pkg","bpk","dump","elc","deploy","exe","dll","deb","dmg","iso","img","msi","msp","msm","buffer"]
-  },
-  "application/oda": {
-    "source": "iana",
-    "extensions": ["oda"]
-  },
-  "application/odx": {
-    "source": "iana"
-  },
-  "application/oebps-package+xml": {
-    "source": "iana",
-    "extensions": ["opf"]
-  },
-  "application/ogg": {
-    "source": "iana",
-    "compressible": false,
-    "extensions": ["ogx"]
-  },
-  "application/omdoc+xml": {
-    "source": "apache",
-    "extensions": ["omdoc"]
-  },
-  "application/onenote": {
-    "source": "apache",
-    "extensions": ["onetoc","onetoc2","onetmp","onepkg"]
-  },
-  "application/oxps": {
-    "source": "iana",
-    "extensions": ["oxps"]
-  },
-  "application/p2p-overlay+xml": {
-    "source": "iana"
-  },
-  "application/parityfec": {
-    "source": "iana"
-  },
-  "application/patch-ops-error+xml": {
-    "source": "iana",
-    "extensions": ["xer"]
-  },
-  "application/pdf": {
-    "source": "iana",
-    "compressible": false,
-    "extensions": ["pdf"]
-  },
-  "application/pdx": {
-    "source": "iana"
-  },
-  "application/pgp-encrypted": {
-    "source": "iana",
-    "compressible": false,
-    "extensions": ["pgp"]
-  },
-  "application/pgp-keys": {
-    "source": "iana"
-  },
-  "application/pgp-signature": {
-    "source": "iana",
-    "extensions": ["asc","sig"]
-  },
-  "application/pics-rules": {
-    "source": "apache",
-    "extensions": ["prf"]
-  },
-  "application/pidf+xml": {
-    "source": "iana"
-  },
-  "application/pidf-diff+xml": {
-    "source": "iana"
-  },
-  "application/pkcs10": {
-    "source": "iana",
-    "extensions": ["p10"]
-  },
-  "application/pkcs7-mime": {
-    "source": "iana",
-    "extensions": ["p7m","p7c"]
-  },
-  "application/pkcs7-signature": {
-    "source": "iana",
-    "extensions": ["p7s"]
-  },
-  "application/pkcs8": {
-    "source": "iana",
-    "extensions": ["p8"]
-  },
-  "application/pkix-attr-cert": {
-    "source": "iana",
-    "extensions": ["ac"]
-  },
-  "application/pkix-cert": {
-    "source": "iana",
-    "extensions": ["cer"]
-  },
-  "application/pkix-crl": {
-    "source": "iana",
-    "extensions": ["crl"]
-  },
-  "application/pkix-pkipath": {
-    "source": "iana",
-    "extensions": ["pkipath"]
-  },
-  "application/pkixcmp": {
-    "source": "iana",
-    "extensions": ["pki"]
-  },
-  "application/pls+xml": {
-    "source": "iana",
-    "extensions": ["pls"]
-  },
-  "application/poc-settings+xml": {
-    "source": "iana"
-  },
-  "application/postscript": {
-    "source": "iana",
-    "compressible": true,
-    "extensions": ["ai","eps","ps"]
-  },
-  "application/provenance+xml": {
-    "source": "iana"
-  },
-  "application/prs.alvestrand.titrax-sheet": {
-    "source": "iana"
-  },
-  "application/prs.cww": {
-    "source": "iana",
-    "extensions": ["cww"]
-  },
-  "application/prs.hpub+zip": {
-    "source": "iana"
-  },
-  "application/prs.nprend": {
-    "source": "iana"
-  },
-  "application/prs.plucker": {
-    "source": "iana"
-  },
-  "application/prs.rdf-xml-crypt": {
-    "source": "iana"
-  },
-  "application/prs.xsf+xml": {
-    "source": "iana"
-  },
-  "application/pskc+xml": {
-    "source": "iana",
-    "extensions": ["pskcxml"]
-  },
-  "application/qsig": {
-    "source": "iana"
-  },
-  "application/raptorfec": {
-    "source": "iana"
-  },
-  "application/rdap+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/rdf+xml": {
-    "source": "iana",
-    "compressible": true,
-    "extensions": ["rdf"]
-  },
-  "application/reginfo+xml": {
-    "source": "iana",
-    "extensions": ["rif"]
-  },
-  "application/relax-ng-compact-syntax": {
-    "source": "iana",
-    "extensions": ["rnc"]
-  },
-  "application/remote-printing": {
-    "source": "iana"
-  },
-  "application/reputon+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/resource-lists+xml": {
-    "source": "iana",
-    "extensions": ["rl"]
-  },
-  "application/resource-lists-diff+xml": {
-    "source": "iana",
-    "extensions": ["rld"]
-  },
-  "application/riscos": {
-    "source": "iana"
-  },
-  "application/rlmi+xml": {
-    "source": "iana"
-  },
-  "application/rls-services+xml": {
-    "source": "iana",
-    "extensions": ["rs"]
-  },
-  "application/rpki-ghostbusters": {
-    "source": "iana",
-    "extensions": ["gbr"]
-  },
-  "application/rpki-manifest": {
-    "source": "iana",
-    "extensions": ["mft"]
-  },
-  "application/rpki-roa": {
-    "source": "iana",
-    "extensions": ["roa"]
-  },
-  "application/rpki-updown": {
-    "source": "iana"
-  },
-  "application/rsd+xml": {
-    "source": "apache",
-    "extensions": ["rsd"]
-  },
-  "application/rss+xml": {
-    "source": "apache",
-    "compressible": true,
-    "extensions": ["rss"]
-  },
-  "application/rtf": {
-    "source": "iana",
-    "compressible": true,
-    "extensions": ["rtf"]
-  },
-  "application/rtploopback": {
-    "source": "iana"
-  },
-  "application/rtx": {
-    "source": "iana"
-  },
-  "application/samlassertion+xml": {
-    "source": "iana"
-  },
-  "application/samlmetadata+xml": {
-    "source": "iana"
-  },
-  "application/sbml+xml": {
-    "source": "iana",
-    "extensions": ["sbml"]
-  },
-  "application/scaip+xml": {
-    "source": "iana"
-  },
-  "application/scim+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/scvp-cv-request": {
-    "source": "iana",
-    "extensions": ["scq"]
-  },
-  "application/scvp-cv-response": {
-    "source": "iana",
-    "extensions": ["scs"]
-  },
-  "application/scvp-vp-request": {
-    "source": "iana",
-    "extensions": ["spq"]
-  },
-  "application/scvp-vp-response": {
-    "source": "iana",
-    "extensions": ["spp"]
-  },
-  "application/sdp": {
-    "source": "iana",
-    "extensions": ["sdp"]
-  },
-  "application/sep+xml": {
-    "source": "iana"
-  },
-  "application/sep-exi": {
-    "source": "iana"
-  },
-  "application/session-info": {
-    "source": "iana"
-  },
-  "application/set-payment": {
-    "source": "iana"
-  },
-  "application/set-payment-initiation": {
-    "source": "iana",
-    "extensions": ["setpay"]
-  },
-  "application/set-registration": {
-    "source": "iana"
-  },
-  "application/set-registration-initiation": {
-    "source": "iana",
-    "extensions": ["setreg"]
-  },
-  "application/sgml": {
-    "source": "iana"
-  },
-  "application/sgml-open-catalog": {
-    "source": "iana"
-  },
-  "application/shf+xml": {
-    "source": "iana",
-    "extensions": ["shf"]
-  },
-  "application/sieve": {
-    "source": "iana"
-  },
-  "application/simple-filter+xml": {
-    "source": "iana"
-  },
-  "application/simple-message-summary": {
-    "source": "iana"
-  },
-  "application/simplesymbolcontainer": {
-    "source": "iana"
-  },
-  "application/slate": {
-    "source": "iana"
-  },
-  "application/smil": {
-    "source": "iana"
-  },
-  "application/smil+xml": {
-    "source": "iana",
-    "extensions": ["smi","smil"]
-  },
-  "application/smpte336m": {
-    "source": "iana"
-  },
-  "application/soap+fastinfoset": {
-    "source": "iana"
-  },
-  "application/soap+xml": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/sparql-query": {
-    "source": "iana",
-    "extensions": ["rq"]
-  },
-  "application/sparql-results+xml": {
-    "source": "iana",
-    "extensions": ["srx"]
-  },
-  "application/spirits-event+xml": {
-    "source": "iana"
-  },
-  "application/sql": {
-    "source": "iana"
-  },
-  "application/srgs": {
-    "source": "iana",
-    "extensions": ["gram"]
-  },
-  "application/srgs+xml": {
-    "source": "iana",
-    "extensions": ["grxml"]
-  },
-  "application/sru+xml": {
-    "source": "iana",
-    "extensions": ["sru"]
-  },
-  "application/ssdl+xml": {
-    "source": "apache",
-    "extensions": ["ssdl"]
-  },
-  "application/ssml+xml": {
-    "source": "iana",
-    "extensions": ["ssml"]
-  },
-  "application/tamp-apex-update": {
-    "source": "iana"
-  },
-  "application/tamp-apex-update-confirm": {
-    "source": "iana"
-  },
-  "application/tamp-community-update": {
-    "source": "iana"
-  },
-  "application/tamp-community-update-confirm": {
-    "source": "iana"
-  },
-  "application/tamp-error": {
-    "source": "iana"
-  },
-  "application/tamp-sequence-adjust": {
-    "source": "iana"
-  },
-  "application/tamp-sequence-adjust-confirm": {
-    "source": "iana"
-  },
-  "application/tamp-status-query": {
-    "source": "iana"
-  },
-  "application/tamp-status-response": {
-    "source": "iana"
-  },
-  "application/tamp-update": {
-    "source": "iana"
-  },
-  "application/tamp-update-confirm": {
-    "source": "iana"
-  },
-  "application/tar": {
-    "compressible": true
-  },
-  "application/tei+xml": {
-    "source": "iana",
-    "extensions": ["tei","teicorpus"]
-  },
-  "application/thraud+xml": {
-    "source": "iana",
-    "extensions": ["tfi"]
-  },
-  "application/timestamp-query": {
-    "source": "iana"
-  },
-  "application/timestamp-reply": {
-    "source": "iana"
-  },
-  "application/timestamped-data": {
-    "source": "iana",
-    "extensions": ["tsd"]
-  },
-  "application/ttml+xml": {
-    "source": "iana"
-  },
-  "application/tve-trigger": {
-    "source": "iana"
-  },
-  "application/ulpfec": {
-    "source": "iana"
-  },
-  "application/urc-grpsheet+xml": {
-    "source": "iana"
-  },
-  "application/urc-ressheet+xml": {
-    "source": "iana"
-  },
-  "application/urc-targetdesc+xml": {
-    "source": "iana"
-  },
-  "application/urc-uisocketdesc+xml": {
-    "source": "iana"
-  },
-  "application/vcard+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/vcard+xml": {
-    "source": "iana"
-  },
-  "application/vemmi": {
-    "source": "iana"
-  },
-  "application/vividence.scriptfile": {
-    "source": "apache"
-  },
-  "application/vnd.3gpp.bsf+xml": {
-    "source": "iana"
-  },
-  "application/vnd.3gpp.pic-bw-large": {
-    "source": "iana",
-    "extensions": ["plb"]
-  },
-  "application/vnd.3gpp.pic-bw-small": {
-    "source": "iana",
-    "extensions": ["psb"]
-  },
-  "application/vnd.3gpp.pic-bw-var": {
-    "source": "iana",
-    "extensions": ["pvb"]
-  },
-  "application/vnd.3gpp.sms": {
-    "source": "iana"
-  },
-  "application/vnd.3gpp.ussd+xml": {
-    "source": "iana"
-  },
-  "application/vnd.3gpp2.bcmcsinfo+xml": {
-    "source": "iana"
-  },
-  "application/vnd.3gpp2.sms": {
-    "source": "iana"
-  },
-  "application/vnd.3gpp2.tcap": {
-    "source": "iana",
-    "extensions": ["tcap"]
-  },
-  "application/vnd.3m.post-it-notes": {
-    "source": "iana",
-    "extensions": ["pwn"]
-  },
-  "application/vnd.accpac.simply.aso": {
-    "source": "iana",
-    "extensions": ["aso"]
-  },
-  "application/vnd.accpac.simply.imp": {
-    "source": "iana",
-    "extensions": ["imp"]
-  },
-  "application/vnd.acucobol": {
-    "source": "iana",
-    "extensions": ["acu"]
-  },
-  "application/vnd.acucorp": {
-    "source": "iana",
-    "extensions": ["atc","acutc"]
-  },
-  "application/vnd.adobe.air-application-installer-package+zip": {
-    "source": "apache",
-    "extensions": ["air"]
-  },
-  "application/vnd.adobe.flash.movie": {
-    "source": "iana"
-  },
-  "application/vnd.adobe.formscentral.fcdt": {
-    "source": "iana",
-    "extensions": ["fcdt"]
-  },
-  "application/vnd.adobe.fxp": {
-    "source": "iana",
-    "extensions": ["fxp","fxpl"]
-  },
-  "application/vnd.adobe.partial-upload": {
-    "source": "iana"
-  },
-  "application/vnd.adobe.xdp+xml": {
-    "source": "iana",
-    "extensions": ["xdp"]
-  },
-  "application/vnd.adobe.xfdf": {
-    "source": "iana",
-    "extensions": ["xfdf"]
-  },
-  "application/vnd.aether.imp": {
-    "source": "iana"
-  },
-  "application/vnd.ah-barcode": {
-    "source": "iana"
-  },
-  "application/vnd.ahead.space": {
-    "source": "iana",
-    "extensions": ["ahead"]
-  },
-  "application/vnd.airzip.filesecure.azf": {
-    "source": "iana",
-    "extensions": ["azf"]
-  },
-  "application/vnd.airzip.filesecure.azs": {
-    "source": "iana",
-    "extensions": ["azs"]
-  },
-  "application/vnd.amazon.ebook": {
-    "source": "apache",
-    "extensions": ["azw"]
-  },
-  "application/vnd.americandynamics.acc": {
-    "source": "iana",
-    "extensions": ["acc"]
-  },
-  "application/vnd.amiga.ami": {
-    "source": "iana",
-    "extensions": ["ami"]
-  },
-  "application/vnd.amundsen.maze+xml": {
-    "source": "iana"
-  },
-  "application/vnd.android.package-archive": {
-    "source": "apache",
-    "compressible": false,
-    "extensions": ["apk"]
-  },
-  "application/vnd.anser-web-certificate-issue-initiation": {
-    "source": "iana",
-    "extensions": ["cii"]
-  },
-  "application/vnd.anser-web-funds-transfer-initiation": {
-    "source": "apache",
-    "extensions": ["fti"]
-  },
-  "application/vnd.antix.game-component": {
-    "source": "iana",
-    "extensions": ["atx"]
-  },
-  "application/vnd.apache.thrift.binary": {
-    "source": "iana"
-  },
-  "application/vnd.apache.thrift.compact": {
-    "source": "iana"
-  },
-  "application/vnd.apache.thrift.json": {
-    "source": "iana"
-  },
-  "application/vnd.api+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/vnd.apple.installer+xml": {
-    "source": "iana",
-    "extensions": ["mpkg"]
-  },
-  "application/vnd.apple.mpegurl": {
-    "source": "iana",
-    "extensions": ["m3u8"]
-  },
-  "application/vnd.arastra.swi": {
-    "source": "iana"
-  },
-  "application/vnd.aristanetworks.swi": {
-    "source": "iana",
-    "extensions": ["swi"]
-  },
-  "application/vnd.artsquare": {
-    "source": "iana"
-  },
-  "application/vnd.astraea-software.iota": {
-    "source": "iana",
-    "extensions": ["iota"]
-  },
-  "application/vnd.audiograph": {
-    "source": "iana",
-    "extensions": ["aep"]
-  },
-  "application/vnd.autopackage": {
-    "source": "iana"
-  },
-  "application/vnd.avistar+xml": {
-    "source": "iana"
-  },
-  "application/vnd.balsamiq.bmml+xml": {
-    "source": "iana"
-  },
-  "application/vnd.balsamiq.bmpr": {
-    "source": "iana"
-  },
-  "application/vnd.bekitzur-stech+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/vnd.biopax.rdf+xml": {
-    "source": "iana"
-  },
-  "application/vnd.blueice.multipass": {
-    "source": "iana",
-    "extensions": ["mpm"]
-  },
-  "application/vnd.bluetooth.ep.oob": {
-    "source": "iana"
-  },
-  "application/vnd.bluetooth.le.oob": {
-    "source": "iana"
-  },
-  "application/vnd.bmi": {
-    "source": "iana",
-    "extensions": ["bmi"]
-  },
-  "application/vnd.businessobjects": {
-    "source": "iana",
-    "extensions": ["rep"]
-  },
-  "application/vnd.cab-jscript": {
-    "source": "iana"
-  },
-  "application/vnd.canon-cpdl": {
-    "source": "iana"
-  },
-  "application/vnd.canon-lips": {
-    "source": "iana"
-  },
-  "application/vnd.cendio.thinlinc.clientconf": {
-    "source": "iana"
-  },
-  "application/vnd.century-systems.tcp_stream": {
-    "source": "iana"
-  },
-  "application/vnd.chemdraw+xml": {
-    "source": "iana",
-    "extensions": ["cdxml"]
-  },
-  "application/vnd.chipnuts.karaoke-mmd": {
-    "source": "iana",
-    "extensions": ["mmd"]
-  },
-  "application/vnd.cinderella": {
-    "source": "iana",
-    "extensions": ["cdy"]
-  },
-  "application/vnd.cirpack.isdn-ext": {
-    "source": "iana"
-  },
-  "application/vnd.citationstyles.style+xml": {
-    "source": "iana"
-  },
-  "application/vnd.claymore": {
-    "source": "iana",
-    "extensions": ["cla"]
-  },
-  "application/vnd.cloanto.rp9": {
-    "source": "iana",
-    "extensions": ["rp9"]
-  },
-  "application/vnd.clonk.c4group": {
-    "source": "iana",
-    "extensions": ["c4g","c4d","c4f","c4p","c4u"]
-  },
-  "application/vnd.cluetrust.cartomobile-config": {
-    "source": "iana",
-    "extensions": ["c11amc"]
-  },
-  "application/vnd.cluetrust.cartomobile-config-pkg": {
-    "source": "iana",
-    "extensions": ["c11amz"]
-  },
-  "application/vnd.coffeescript": {
-    "source": "iana"
-  },
-  "application/vnd.collection+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/vnd.collection.doc+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/vnd.collection.next+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/vnd.commerce-battelle": {
-    "source": "iana"
-  },
-  "application/vnd.commonspace": {
-    "source": "iana",
-    "extensions": ["csp"]
-  },
-  "application/vnd.contact.cmsg": {
-    "source": "iana",
-    "extensions": ["cdbcmsg"]
-  },
-  "application/vnd.cosmocaller": {
-    "source": "iana",
-    "extensions": ["cmc"]
-  },
-  "application/vnd.crick.clicker": {
-    "source": "iana",
-    "extensions": ["clkx"]
-  },
-  "application/vnd.crick.clicker.keyboard": {
-    "source": "iana",
-    "extensions": ["clkk"]
-  },
-  "application/vnd.crick.clicker.palette": {
-    "source": "iana",
-    "extensions": ["clkp"]
-  },
-  "application/vnd.crick.clicker.template": {
-    "source": "iana",
-    "extensions": ["clkt"]
-  },
-  "application/vnd.crick.clicker.wordbank": {
-    "source": "iana",
-    "extensions": ["clkw"]
-  },
-  "application/vnd.criticaltools.wbs+xml": {
-    "source": "iana",
-    "extensions": ["wbs"]
-  },
-  "application/vnd.ctc-posml": {
-    "source": "iana",
-    "extensions": ["pml"]
-  },
-  "application/vnd.ctct.ws+xml": {
-    "source": "iana"
-  },
-  "application/vnd.cups-pdf": {
-    "source": "iana"
-  },
-  "application/vnd.cups-postscript": {
-    "source": "iana"
-  },
-  "application/vnd.cups-ppd": {
-    "source": "iana",
-    "extensions": ["ppd"]
-  },
-  "application/vnd.cups-raster": {
-    "source": "iana"
-  },
-  "application/vnd.cups-raw": {
-    "source": "iana"
-  },
-  "application/vnd.curl": {
-    "source": "iana"
-  },
-  "application/vnd.curl.car": {
-    "source": "apache",
-    "extensions": ["car"]
-  },
-  "application/vnd.curl.pcurl": {
-    "source": "apache",
-    "extensions": ["pcurl"]
-  },
-  "application/vnd.cyan.dean.root+xml": {
-    "source": "iana"
-  },
-  "application/vnd.cybank": {
-    "source": "iana"
-  },
-  "application/vnd.dart": {
-    "source": "iana",
-    "compressible": true,
-    "extensions": ["dart"]
-  },
-  "application/vnd.data-vision.rdz": {
-    "source": "iana",
-    "extensions": ["rdz"]
-  },
-  "application/vnd.debian.binary-package": {
-    "source": "iana"
-  },
-  "application/vnd.dece.data": {
-    "source": "iana",
-    "extensions": ["uvf","uvvf","uvd","uvvd"]
-  },
-  "application/vnd.dece.ttml+xml": {
-    "source": "iana",
-    "extensions": ["uvt","uvvt"]
-  },
-  "application/vnd.dece.unspecified": {
-    "source": "iana",
-    "extensions": ["uvx","uvvx"]
-  },
-  "application/vnd.dece.zip": {
-    "source": "iana",
-    "extensions": ["uvz","uvvz"]
-  },
-  "application/vnd.denovo.fcselayout-link": {
-    "source": "iana",
-    "extensions": ["fe_launch"]
-  },
-  "application/vnd.desmume-movie": {
-    "source": "iana"
-  },
-  "application/vnd.dir-bi.plate-dl-nosuffix": {
-    "source": "iana"
-  },
-  "application/vnd.dm.delegation+xml": {
-    "source": "iana"
-  },
-  "application/vnd.dna": {
-    "source": "iana",
-    "extensions": ["dna"]
-  },
-  "application/vnd.document+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/vnd.dolby.mlp": {
-    "source": "apache",
-    "extensions": ["mlp"]
-  },
-  "application/vnd.dolby.mobile.1": {
-    "source": "iana"
-  },
-  "application/vnd.dolby.mobile.2": {
-    "source": "iana"
-  },
-  "application/vnd.doremir.scorecloud-binary-document": {
-    "source": "iana"
-  },
-  "application/vnd.dpgraph": {
-    "source": "iana",
-    "extensions": ["dpg"]
-  },
-  "application/vnd.dreamfactory": {
-    "source": "iana",
-    "extensions": ["dfac"]
-  },
-  "application/vnd.ds-keypoint": {
-    "source": "apache",
-    "extensions": ["kpxx"]
-  },
-  "application/vnd.dtg.local": {
-    "source": "iana"
-  },
-  "application/vnd.dtg.local.flash": {
-    "source": "iana"
-  },
-  "application/vnd.dtg.local.html": {
-    "source": "iana"
-  },
-  "application/vnd.dvb.ait": {
-    "source": "iana",
-    "extensions": ["ait"]
-  },
-  "application/vnd.dvb.dvbj": {
-    "source": "iana"
-  },
-  "application/vnd.dvb.esgcontainer": {
-    "source": "iana"
-  },
-  "application/vnd.dvb.ipdcdftnotifaccess": {
-    "source": "iana"
-  },
-  "application/vnd.dvb.ipdcesgaccess": {
-    "source": "iana"
-  },
-  "application/vnd.dvb.ipdcesgaccess2": {
-    "source": "iana"
-  },
-  "application/vnd.dvb.ipdcesgpdd": {
-    "source": "iana"
-  },
-  "application/vnd.dvb.ipdcroaming": {
-    "source": "iana"
-  },
-  "application/vnd.dvb.iptv.alfec-base": {
-    "source": "iana"
-  },
-  "application/vnd.dvb.iptv.alfec-enhancement": {
-    "source": "iana"
-  },
-  "application/vnd.dvb.notif-aggregate-root+xml": {
-    "source": "iana"
-  },
-  "application/vnd.dvb.notif-container+xml": {
-    "source": "iana"
-  },
-  "application/vnd.dvb.notif-generic+xml": {
-    "source": "iana"
-  },
-  "application/vnd.dvb.notif-ia-msglist+xml": {
-    "source": "iana"
-  },
-  "application/vnd.dvb.notif-ia-registration-request+xml": {
-    "source": "iana"
-  },
-  "application/vnd.dvb.notif-ia-registration-response+xml": {
-    "source": "iana"
-  },
-  "application/vnd.dvb.notif-init+xml": {
-    "source": "iana"
-  },
-  "application/vnd.dvb.pfr": {
-    "source": "iana"
-  },
-  "application/vnd.dvb.service": {
-    "source": "iana",
-    "extensions": ["svc"]
-  },
-  "application/vnd.dxr": {
-    "source": "iana"
-  },
-  "application/vnd.dynageo": {
-    "source": "iana",
-    "extensions": ["geo"]
-  },
-  "application/vnd.dzr": {
-    "source": "iana"
-  },
-  "application/vnd.easykaraoke.cdgdownload": {
-    "source": "iana"
-  },
-  "application/vnd.ecdis-update": {
-    "source": "iana"
-  },
-  "application/vnd.ecowin.chart": {
-    "source": "iana",
-    "extensions": ["mag"]
-  },
-  "application/vnd.ecowin.filerequest": {
-    "source": "iana"
-  },
-  "application/vnd.ecowin.fileupdate": {
-    "source": "iana"
-  },
-  "application/vnd.ecowin.series": {
-    "source": "iana"
-  },
-  "application/vnd.ecowin.seriesrequest": {
-    "source": "iana"
-  },
-  "application/vnd.ecowin.seriesupdate": {
-    "source": "iana"
-  },
-  "application/vnd.emclient.accessrequest+xml": {
-    "source": "iana"
-  },
-  "application/vnd.enliven": {
-    "source": "iana",
-    "extensions": ["nml"]
-  },
-  "application/vnd.enphase.envoy": {
-    "source": "iana"
-  },
-  "application/vnd.eprints.data+xml": {
-    "source": "iana"
-  },
-  "application/vnd.epson.esf": {
-    "source": "iana",
-    "extensions": ["esf"]
-  },
-  "application/vnd.epson.msf": {
-    "source": "iana",
-    "extensions": ["msf"]
-  },
-  "application/vnd.epson.quickanime": {
-    "source": "iana",
-    "extensions": ["qam"]
-  },
-  "application/vnd.epson.salt": {
-    "source": "iana",
-    "extensions": ["slt"]
-  },
-  "application/vnd.epson.ssf": {
-    "source": "iana",
-    "extensions": ["ssf"]
-  },
-  "application/vnd.ericsson.quickcall": {
-    "source": "iana"
-  },
-  "application/vnd.eszigno3+xml": {
-    "source": "iana",
-    "extensions": ["es3","et3"]
-  },
-  "application/vnd.etsi.aoc+xml": {
-    "source": "iana"
-  },
-  "application/vnd.etsi.asic-e+zip": {
-    "source": "iana"
-  },
-  "application/vnd.etsi.asic-s+zip": {
-    "source": "iana"
-  },
-  "application/vnd.etsi.cug+xml": {
-    "source": "iana"
-  },
-  "application/vnd.etsi.iptvcommand+xml": {
-    "source": "iana"
-  },
-  "application/vnd.etsi.iptvdiscovery+xml": {
-    "source": "iana"
-  },
-  "application/vnd.etsi.iptvprofile+xml": {
-    "source": "iana"
-  },
-  "application/vnd.etsi.iptvsad-bc+xml": {
-    "source": "iana"
-  },
-  "application/vnd.etsi.iptvsad-cod+xml": {
-    "source": "iana"
-  },
-  "application/vnd.etsi.iptvsad-npvr+xml": {
-    "source": "iana"
-  },
-  "application/vnd.etsi.iptvservice+xml": {
-    "source": "iana"
-  },
-  "application/vnd.etsi.iptvsync+xml": {
-    "source": "iana"
-  },
-  "application/vnd.etsi.iptvueprofile+xml": {
-    "source": "iana"
-  },
-  "application/vnd.etsi.mcid+xml": {
-    "source": "iana"
-  },
-  "application/vnd.etsi.mheg5": {
-    "source": "iana"
-  },
-  "application/vnd.etsi.overload-control-policy-dataset+xml": {
-    "source": "iana"
-  },
-  "application/vnd.etsi.pstn+xml": {
-    "source": "iana"
-  },
-  "application/vnd.etsi.sci+xml": {
-    "source": "iana"
-  },
-  "application/vnd.etsi.simservs+xml": {
-    "source": "iana"
-  },
-  "application/vnd.etsi.timestamp-token": {
-    "source": "iana"
-  },
-  "application/vnd.etsi.tsl+xml": {
-    "source": "iana"
-  },
-  "application/vnd.etsi.tsl.der": {
-    "source": "iana"
-  },
-  "application/vnd.eudora.data": {
-    "source": "iana"
-  },
-  "application/vnd.ezpix-album": {
-    "source": "iana",
-    "extensions": ["ez2"]
-  },
-  "application/vnd.ezpix-package": {
-    "source": "iana",
-    "extensions": ["ez3"]
-  },
-  "application/vnd.f-secure.mobile": {
-    "source": "iana"
-  },
-  "application/vnd.fastcopy-disk-image": {
-    "source": "iana"
-  },
-  "application/vnd.fdf": {
-    "source": "iana",
-    "extensions": ["fdf"]
-  },
-  "application/vnd.fdsn.mseed": {
-    "source": "iana",
-    "extensions": ["mseed"]
-  },
-  "application/vnd.fdsn.seed": {
-    "source": "iana",
-    "extensions": ["seed","dataless"]
-  },
-  "application/vnd.ffsns": {
-    "source": "iana"
-  },
-  "application/vnd.fints": {
-    "source": "iana"
-  },
-  "application/vnd.flographit": {
-    "source": "iana",
-    "extensions": ["gph"]
-  },
-  "application/vnd.fluxtime.clip": {
-    "source": "iana",
-    "extensions": ["ftc"]
-  },
-  "application/vnd.font-fontforge-sfd": {
-    "source": "iana"
-  },
-  "application/vnd.framemaker": {
-    "source": "iana",
-    "extensions": ["fm","frame","maker","book"]
-  },
-  "application/vnd.frogans.fnc": {
-    "source": "iana",
-    "extensions": ["fnc"]
-  },
-  "application/vnd.frogans.ltf": {
-    "source": "iana",
-    "extensions": ["ltf"]
-  },
-  "application/vnd.fsc.weblaunch": {
-    "source": "iana",
-    "extensions": ["fsc"]
-  },
-  "application/vnd.fujitsu.oasys": {
-    "source": "iana",
-    "extensions": ["oas"]
-  },
-  "application/vnd.fujitsu.oasys2": {
-    "source": "iana",
-    "extensions": ["oa2"]
-  },
-  "application/vnd.fujitsu.oasys3": {
-    "source": "iana",
-    "extensions": ["oa3"]
-  },
-  "application/vnd.fujitsu.oasysgp": {
-    "source": "iana",
-    "extensions": ["fg5"]
-  },
-  "application/vnd.fujitsu.oasysprs": {
-    "source": "iana",
-    "extensions": ["bh2"]
-  },
-  "application/vnd.fujixerox.art-ex": {
-    "source": "iana"
-  },
-  "application/vnd.fujixerox.art4": {
-    "source": "iana"
-  },
-  "application/vnd.fujixerox.ddd": {
-    "source": "iana",
-    "extensions": ["ddd"]
-  },
-  "application/vnd.fujixerox.docuworks": {
-    "source": "iana",
-    "extensions": ["xdw"]
-  },
-  "application/vnd.fujixerox.docuworks.binder": {
-    "source": "iana",
-    "extensions": ["xbd"]
-  },
-  "application/vnd.fujixerox.docuworks.container": {
-    "source": "iana"
-  },
-  "application/vnd.fujixerox.hbpl": {
-    "source": "iana"
-  },
-  "application/vnd.fut-misnet": {
-    "source": "iana"
-  },
-  "application/vnd.fuzzysheet": {
-    "source": "iana",
-    "extensions": ["fzs"]
-  },
-  "application/vnd.genomatix.tuxedo": {
-    "source": "iana",
-    "extensions": ["txd"]
-  },
-  "application/vnd.geo+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/vnd.geocube+xml": {
-    "source": "iana"
-  },
-  "application/vnd.geogebra.file": {
-    "source": "iana",
-    "extensions": ["ggb"]
-  },
-  "application/vnd.geogebra.tool": {
-    "source": "iana",
-    "extensions": ["ggt"]
-  },
-  "application/vnd.geometry-explorer": {
-    "source": "iana",
-    "extensions": ["gex","gre"]
-  },
-  "application/vnd.geonext": {
-    "source": "iana",
-    "extensions": ["gxt"]
-  },
-  "application/vnd.geoplan": {
-    "source": "iana",
-    "extensions": ["g2w"]
-  },
-  "application/vnd.geospace": {
-    "source": "iana",
-    "extensions": ["g3w"]
-  },
-  "application/vnd.gerber": {
-    "source": "iana"
-  },
-  "application/vnd.globalplatform.card-content-mgt": {
-    "source": "iana"
-  },
-  "application/vnd.globalplatform.card-content-mgt-response": {
-    "source": "iana"
-  },
-  "application/vnd.gmx": {
-    "source": "iana",
-    "extensions": ["gmx"]
-  },
-  "application/vnd.google-earth.kml+xml": {
-    "source": "iana",
-    "compressible": true,
-    "extensions": ["kml"]
-  },
-  "application/vnd.google-earth.kmz": {
-    "source": "iana",
-    "compressible": false,
-    "extensions": ["kmz"]
-  },
-  "application/vnd.gov.sk.e-form+xml": {
-    "source": "iana"
-  },
-  "application/vnd.gov.sk.e-form+zip": {
-    "source": "iana"
-  },
-  "application/vnd.gov.sk.xmldatacontainer+xml": {
-    "source": "iana"
-  },
-  "application/vnd.grafeq": {
-    "source": "iana",
-    "extensions": ["gqf","gqs"]
-  },
-  "application/vnd.gridmp": {
-    "source": "iana"
-  },
-  "application/vnd.groove-account": {
-    "source": "iana",
-    "extensions": ["gac"]
-  },
-  "application/vnd.groove-help": {
-    "source": "iana",
-    "extensions": ["ghf"]
-  },
-  "application/vnd.groove-identity-message": {
-    "source": "iana",
-    "extensions": ["gim"]
-  },
-  "application/vnd.groove-injector": {
-    "source": "iana",
-    "extensions": ["grv"]
-  },
-  "application/vnd.groove-tool-message": {
-    "source": "iana",
-    "extensions": ["gtm"]
-  },
-  "application/vnd.groove-tool-template": {
-    "source": "iana",
-    "extensions": ["tpl"]
-  },
-  "application/vnd.groove-vcard": {
-    "source": "iana",
-    "extensions": ["vcg"]
-  },
-  "application/vnd.hal+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/vnd.hal+xml": {
-    "source": "iana",
-    "extensions": ["hal"]
-  },
-  "application/vnd.handheld-entertainment+xml": {
-    "source": "iana",
-    "extensions": ["zmm"]
-  },
-  "application/vnd.hbci": {
-    "source": "iana",
-    "extensions": ["hbci"]
-  },
-  "application/vnd.hcl-bireports": {
-    "source": "iana"
-  },
-  "application/vnd.heroku+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/vnd.hhe.lesson-player": {
-    "source": "iana",
-    "extensions": ["les"]
-  },
-  "application/vnd.hp-hpgl": {
-    "source": "iana",
-    "extensions": ["hpgl"]
-  },
-  "application/vnd.hp-hpid": {
-    "source": "iana",
-    "extensions": ["hpid"]
-  },
-  "application/vnd.hp-hps": {
-    "source": "iana",
-    "extensions": ["hps"]
-  },
-  "application/vnd.hp-jlyt": {
-    "source": "iana",
-    "extensions": ["jlt"]
-  },
-  "application/vnd.hp-pcl": {
-    "source": "iana",
-    "extensions": ["pcl"]
-  },
-  "application/vnd.hp-pclxl": {
-    "source": "iana",
-    "extensions": ["pclxl"]
-  },
-  "application/vnd.httphone": {
-    "source": "iana"
-  },
-  "application/vnd.hydrostatix.sof-data": {
-    "source": "iana",
-    "extensions": ["sfd-hdstx"]
-  },
-  "application/vnd.hyperdrive+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/vnd.hzn-3d-crossword": {
-    "source": "iana"
-  },
-  "application/vnd.ibm.afplinedata": {
-    "source": "iana"
-  },
-  "application/vnd.ibm.electronic-media": {
-    "source": "iana"
-  },
-  "application/vnd.ibm.minipay": {
-    "source": "iana",
-    "extensions": ["mpy"]
-  },
-  "application/vnd.ibm.modcap": {
-    "source": "iana",
-    "extensions": ["afp","listafp","list3820"]
-  },
-  "application/vnd.ibm.rights-management": {
-    "source": "iana",
-    "extensions": ["irm"]
-  },
-  "application/vnd.ibm.secure-container": {
-    "source": "iana",
-    "extensions": ["sc"]
-  },
-  "application/vnd.iccprofile": {
-    "source": "iana",
-    "extensions": ["icc","icm"]
-  },
-  "application/vnd.ieee.1905": {
-    "source": "iana"
-  },
-  "application/vnd.igloader": {
-    "source": "iana",
-    "extensions": ["igl"]
-  },
-  "application/vnd.immervision-ivp": {
-    "source": "iana",
-    "extensions": ["ivp"]
-  },
-  "application/vnd.immervision-ivu": {
-    "source": "iana",
-    "extensions": ["ivu"]
-  },
-  "application/vnd.ims.imsccv1p1": {
-    "source": "iana"
-  },
-  "application/vnd.ims.imsccv1p2": {
-    "source": "iana"
-  },
-  "application/vnd.ims.imsccv1p3": {
-    "source": "iana"
-  },
-  "application/vnd.ims.lis.v2.result+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/vnd.ims.lti.v2.toolconsumerprofile+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/vnd.ims.lti.v2.toolproxy+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/vnd.ims.lti.v2.toolproxy.id+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/vnd.ims.lti.v2.toolsettings+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/vnd.ims.lti.v2.toolsettings.simple+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/vnd.informedcontrol.rms+xml": {
-    "source": "iana"
-  },
-  "application/vnd.informix-visionary": {
-    "source": "iana"
-  },
-  "application/vnd.infotech.project": {
-    "source": "iana"
-  },
-  "application/vnd.infotech.project+xml": {
-    "source": "iana"
-  },
-  "application/vnd.innopath.wamp.notification": {
-    "source": "iana"
-  },
-  "application/vnd.insors.igm": {
-    "source": "iana",
-    "extensions": ["igm"]
-  },
-  "application/vnd.intercon.formnet": {
-    "source": "iana",
-    "extensions": ["xpw","xpx"]
-  },
-  "application/vnd.intergeo": {
-    "source": "iana",
-    "extensions": ["i2g"]
-  },
-  "application/vnd.intertrust.digibox": {
-    "source": "iana"
-  },
-  "application/vnd.intertrust.nncp": {
-    "source": "iana"
-  },
-  "application/vnd.intu.qbo": {
-    "source": "iana",
-    "extensions": ["qbo"]
-  },
-  "application/vnd.intu.qfx": {
-    "source": "iana",
-    "extensions": ["qfx"]
-  },
-  "application/vnd.iptc.g2.catalogitem+xml": {
-    "source": "iana"
-  },
-  "application/vnd.iptc.g2.conceptitem+xml": {
-    "source": "iana"
-  },
-  "application/vnd.iptc.g2.knowledgeitem+xml": {
-    "source": "iana"
-  },
-  "application/vnd.iptc.g2.newsitem+xml": {
-    "source": "iana"
-  },
-  "application/vnd.iptc.g2.newsmessage+xml": {
-    "source": "iana"
-  },
-  "application/vnd.iptc.g2.packageitem+xml": {
-    "source": "iana"
-  },
-  "application/vnd.iptc.g2.planningitem+xml": {
-    "source": "iana"
-  },
-  "application/vnd.ipunplugged.rcprofile": {
-    "source": "iana",
-    "extensions": ["rcprofile"]
-  },
-  "application/vnd.irepository.package+xml": {
-    "source": "iana",
-    "extensions": ["irp"]
-  },
-  "application/vnd.is-xpr": {
-    "source": "iana",
-    "extensions": ["xpr"]
-  },
-  "application/vnd.isac.fcs": {
-    "source": "iana",
-    "extensions": ["fcs"]
-  },
-  "application/vnd.jam": {
-    "source": "iana",
-    "extensions": ["jam"]
-  },
-  "application/vnd.japannet-directory-service": {
-    "source": "iana"
-  },
-  "application/vnd.japannet-jpnstore-wakeup": {
-    "source": "iana"
-  },
-  "application/vnd.japannet-payment-wakeup": {
-    "source": "iana"
-  },
-  "application/vnd.japannet-registration": {
-    "source": "iana"
-  },
-  "application/vnd.japannet-registration-wakeup": {
-    "source": "iana"
-  },
-  "application/vnd.japannet-setstore-wakeup": {
-    "source": "iana"
-  },
-  "application/vnd.japannet-verification": {
-    "source": "iana"
-  },
-  "application/vnd.japannet-verification-wakeup": {
-    "source": "iana"
-  },
-  "application/vnd.jcp.javame.midlet-rms": {
-    "source": "iana",
-    "extensions": ["rms"]
-  },
-  "application/vnd.jisp": {
-    "source": "iana",
-    "extensions": ["jisp"]
-  },
-  "application/vnd.joost.joda-archive": {
-    "source": "iana",
-    "extensions": ["joda"]
-  },
-  "application/vnd.jsk.isdn-ngn": {
-    "source": "iana"
-  },
-  "application/vnd.kahootz": {
-    "source": "iana",
-    "extensions": ["ktz","ktr"]
-  },
-  "application/vnd.kde.karbon": {
-    "source": "iana",
-    "extensions": ["karbon"]
-  },
-  "application/vnd.kde.kchart": {
-    "source": "iana",
-    "extensions": ["chrt"]
-  },
-  "application/vnd.kde.kformula": {
-    "source": "iana",
-    "extensions": ["kfo"]
-  },
-  "application/vnd.kde.kivio": {
-    "source": "iana",
-    "extensions": ["flw"]
-  },
-  "application/vnd.kde.kontour": {
-    "source": "iana",
-    "extensions": ["kon"]
-  },
-  "application/vnd.kde.kpresenter": {
-    "source": "iana",
-    "extensions": ["kpr","kpt"]
-  },
-  "application/vnd.kde.kspread": {
-    "source": "iana",
-    "extensions": ["ksp"]
-  },
-  "application/vnd.kde.kword": {
-    "source": "iana",
-    "extensions": ["kwd","kwt"]
-  },
-  "application/vnd.kenameaapp": {
-    "source": "iana",
-    "extensions": ["htke"]
-  },
-  "application/vnd.kidspiration": {
-    "source": "iana",
-    "extensions": ["kia"]
-  },
-  "application/vnd.kinar": {
-    "source": "iana",
-    "extensions": ["kne","knp"]
-  },
-  "application/vnd.koan": {
-    "source": "iana",
-    "extensions": ["skp","skd","skt","skm"]
-  },
-  "application/vnd.kodak-descriptor": {
-    "source": "iana",
-    "extensions": ["sse"]
-  },
-  "application/vnd.las.las+xml": {
-    "source": "iana",
-    "extensions": ["lasxml"]
-  },
-  "application/vnd.liberty-request+xml": {
-    "source": "iana"
-  },
-  "application/vnd.llamagraphics.life-balance.desktop": {
-    "source": "iana",
-    "extensions": ["lbd"]
-  },
-  "application/vnd.llamagraphics.life-balance.exchange+xml": {
-    "source": "iana",
-    "extensions": ["lbe"]
-  },
-  "application/vnd.lotus-1-2-3": {
-    "source": "iana",
-    "extensions": ["123"]
-  },
-  "application/vnd.lotus-approach": {
-    "source": "iana",
-    "extensions": ["apr"]
-  },
-  "application/vnd.lotus-freelance": {
-    "source": "iana",
-    "extensions": ["pre"]
-  },
-  "application/vnd.lotus-notes": {
-    "source": "iana",
-    "extensions": ["nsf"]
-  },
-  "application/vnd.lotus-organizer": {
-    "source": "iana",
-    "extensions": ["org"]
-  },
-  "application/vnd.lotus-screencam": {
-    "source": "iana",
-    "extensions": ["scm"]
-  },
-  "application/vnd.lotus-wordpro": {
-    "source": "iana",
-    "extensions": ["lwp"]
-  },
-  "application/vnd.macports.portpkg": {
-    "source": "iana",
-    "extensions": ["portpkg"]
-  },
-  "application/vnd.marlin.drm.actiontoken+xml": {
-    "source": "iana"
-  },
-  "application/vnd.marlin.drm.conftoken+xml": {
-    "source": "iana"
-  },
-  "application/vnd.marlin.drm.license+xml": {
-    "source": "iana"
-  },
-  "application/vnd.marlin.drm.mdcf": {
-    "source": "iana"
-  },
-  "application/vnd.mason+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/vnd.maxmind.maxmind-db": {
-    "source": "iana"
-  },
-  "application/vnd.mcd": {
-    "source": "iana",
-    "extensions": ["mcd"]
-  },
-  "application/vnd.medcalcdata": {
-    "source": "iana",
-    "extensions": ["mc1"]
-  },
-  "application/vnd.mediastation.cdkey": {
-    "source": "iana",
-    "extensions": ["cdkey"]
-  },
-  "application/vnd.meridian-slingshot": {
-    "source": "iana"
-  },
-  "application/vnd.mfer": {
-    "source": "iana",
-    "extensions": ["mwf"]
-  },
-  "application/vnd.mfmp": {
-    "source": "iana",
-    "extensions": ["mfm"]
-  },
-  "application/vnd.micro+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/vnd.micrografx.flo": {
-    "source": "iana",
-    "extensions": ["flo"]
-  },
-  "application/vnd.micrografx.igx": {
-    "source": "iana",
-    "extensions": ["igx"]
-  },
-  "application/vnd.microsoft.portable-executable": {
-    "source": "iana"
-  },
-  "application/vnd.miele+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/vnd.mif": {
-    "source": "iana",
-    "extensions": ["mif"]
-  },
-  "application/vnd.minisoft-hp3000-save": {
-    "source": "iana"
-  },
-  "application/vnd.mitsubishi.misty-guard.trustweb": {
-    "source": "iana"
-  },
-  "application/vnd.mobius.daf": {
-    "source": "iana",
-    "extensions": ["daf"]
-  },
-  "application/vnd.mobius.dis": {
-    "source": "iana",
-    "extensions": ["dis"]
-  },
-  "application/vnd.mobius.mbk": {
-    "source": "iana",
-    "extensions": ["mbk"]
-  },
-  "application/vnd.mobius.mqy": {
-    "source": "iana",
-    "extensions": ["mqy"]
-  },
-  "application/vnd.mobius.msl": {
-    "source": "iana",
-    "extensions": ["msl"]
-  },
-  "application/vnd.mobius.plc": {
-    "source": "iana",
-    "extensions": ["plc"]
-  },
-  "application/vnd.mobius.txf": {
-    "source": "iana",
-    "extensions": ["txf"]
-  },
-  "application/vnd.mophun.application": {
-    "source": "iana",
-    "extensions": ["mpn"]
-  },
-  "application/vnd.mophun.certificate": {
-    "source": "iana",
-    "extensions": ["mpc"]
-  },
-  "application/vnd.motorola.flexsuite": {
-    "source": "iana"
-  },
-  "application/vnd.motorola.flexsuite.adsi": {
-    "source": "iana"
-  },
-  "application/vnd.motorola.flexsuite.fis": {
-    "source": "iana"
-  },
-  "application/vnd.motorola.flexsuite.gotap": {
-    "source": "iana"
-  },
-  "application/vnd.motorola.flexsuite.kmr": {
-    "source": "iana"
-  },
-  "application/vnd.motorola.flexsuite.ttc": {
-    "source": "iana"
-  },
-  "application/vnd.motorola.flexsuite.wem": {
-    "source": "iana"
-  },
-  "application/vnd.motorola.iprm": {
-    "source": "iana"
-  },
-  "application/vnd.mozilla.xul+xml": {
-    "source": "iana",
-    "compressible": true,
-    "extensions": ["xul"]
-  },
-  "application/vnd.ms-3mfdocument": {
-    "source": "iana"
-  },
-  "application/vnd.ms-artgalry": {
-    "source": "iana",
-    "extensions": ["cil"]
-  },
-  "application/vnd.ms-asf": {
-    "source": "iana"
-  },
-  "application/vnd.ms-cab-compressed": {
-    "source": "iana",
-    "extensions": ["cab"]
-  },
-  "application/vnd.ms-color.iccprofile": {
-    "source": "apache"
-  },
-  "application/vnd.ms-excel": {
-    "source": "iana",
-    "compressible": false,
-    "extensions": ["xls","xlm","xla","xlc","xlt","xlw"]
-  },
-  "application/vnd.ms-excel.addin.macroenabled.12": {
-    "source": "iana",
-    "extensions": ["xlam"]
-  },
-  "application/vnd.ms-excel.sheet.binary.macroenabled.12": {
-    "source": "iana",
-    "extensions": ["xlsb"]
-  },
-  "application/vnd.ms-excel.sheet.macroenabled.12": {
-    "source": "iana",
-    "extensions": ["xlsm"]
-  },
-  "application/vnd.ms-excel.template.macroenabled.12": {
-    "source": "iana",
-    "extensions": ["xltm"]
-  },
-  "application/vnd.ms-fontobject": {
-    "source": "iana",
-    "compressible": true,
-    "extensions": ["eot"]
-  },
-  "application/vnd.ms-htmlhelp": {
-    "source": "iana",
-    "extensions": ["chm"]
-  },
-  "application/vnd.ms-ims": {
-    "source": "iana",
-    "extensions": ["ims"]
-  },
-  "application/vnd.ms-lrm": {
-    "source": "iana",
-    "extensions": ["lrm"]
-  },
-  "application/vnd.ms-office.activex+xml": {
-    "source": "iana"
-  },
-  "application/vnd.ms-officetheme": {
-    "source": "iana",
-    "extensions": ["thmx"]
-  },
-  "application/vnd.ms-opentype": {
-    "source": "apache",
-    "compressible": true
-  },
-  "application/vnd.ms-package.obfuscated-opentype": {
-    "source": "apache"
-  },
-  "application/vnd.ms-pki.seccat": {
-    "source": "apache",
-    "extensions": ["cat"]
-  },
-  "application/vnd.ms-pki.stl": {
-    "source": "apache",
-    "extensions": ["stl"]
-  },
-  "application/vnd.ms-playready.initiator+xml": {
-    "source": "iana"
-  },
-  "application/vnd.ms-powerpoint": {
-    "source": "iana",
-    "compressible": false,
-    "extensions": ["ppt","pps","pot"]
-  },
-  "application/vnd.ms-powerpoint.addin.macroenabled.12": {
-    "source": "iana",
-    "extensions": ["ppam"]
-  },
-  "application/vnd.ms-powerpoint.presentation.macroenabled.12": {
-    "source": "iana",
-    "extensions": ["pptm"]
-  },
-  "application/vnd.ms-powerpoint.slide.macroenabled.12": {
-    "source": "iana",
-    "extensions": ["sldm"]
-  },
-  "application/vnd.ms-powerpoint.slideshow.macroenabled.12": {
-    "source": "iana",
-    "extensions": ["ppsm"]
-  },
-  "application/vnd.ms-powerpoint.template.macroenabled.12": {
-    "source": "iana",
-    "extensions": ["potm"]
-  },
-  "application/vnd.ms-printing.printticket+xml": {
-    "source": "apache"
-  },
-  "application/vnd.ms-project": {
-    "source": "iana",
-    "extensions": ["mpp","mpt"]
-  },
-  "application/vnd.ms-tnef": {
-    "source": "iana"
-  },
-  "application/vnd.ms-windows.printerpairing": {
-    "source": "iana"
-  },
-  "application/vnd.ms-wmdrm.lic-chlg-req": {
-    "source": "iana"
-  },
-  "application/vnd.ms-wmdrm.lic-resp": {
-    "source": "iana"
-  },
-  "application/vnd.ms-wmdrm.meter-chlg-req": {
-    "source": "iana"
-  },
-  "application/vnd.ms-wmdrm.meter-resp": {
-    "source": "iana"
-  },
-  "application/vnd.ms-word.document.macroenabled.12": {
-    "source": "iana",
-    "extensions": ["docm"]
-  },
-  "application/vnd.ms-word.template.macroenabled.12": {
-    "source": "iana",
-    "extensions": ["dotm"]
-  },
-  "application/vnd.ms-works": {
-    "source": "iana",
-    "extensions": ["wps","wks","wcm","wdb"]
-  },
-  "application/vnd.ms-wpl": {
-    "source": "iana",
-    "extensions": ["wpl"]
-  },
-  "application/vnd.ms-xpsdocument": {
-    "source": "iana",
-    "compressible": false,
-    "extensions": ["xps"]
-  },
-  "application/vnd.msa-disk-image": {
-    "source": "iana"
-  },
-  "application/vnd.mseq": {
-    "source": "iana",
-    "extensions": ["mseq"]
-  },
-  "application/vnd.msign": {
-    "source": "iana"
-  },
-  "application/vnd.multiad.creator": {
-    "source": "iana"
-  },
-  "application/vnd.multiad.creator.cif": {
-    "source": "iana"
-  },
-  "application/vnd.music-niff": {
-    "source": "iana"
-  },
-  "application/vnd.musician": {
-    "source": "iana",
-    "extensions": ["mus"]
-  },
-  "application/vnd.muvee.style": {
-    "source": "iana",
-    "extensions": ["msty"]
-  },
-  "application/vnd.mynfc": {
-    "source": "iana",
-    "extensions": ["taglet"]
-  },
-  "application/vnd.ncd.control": {
-    "source": "iana"
-  },
-  "application/vnd.ncd.reference": {
-    "source": "iana"
-  },
-  "application/vnd.nervana": {
-    "source": "iana"
-  },
-  "application/vnd.netfpx": {
-    "source": "iana"
-  },
-  "application/vnd.neurolanguage.nlu": {
-    "source": "iana",
-    "extensions": ["nlu"]
-  },
-  "application/vnd.nintendo.nitro.rom": {
-    "source": "iana"
-  },
-  "application/vnd.nintendo.snes.rom": {
-    "source": "iana"
-  },
-  "application/vnd.nitf": {
-    "source": "iana",
-    "extensions": ["ntf","nitf"]
-  },
-  "application/vnd.noblenet-directory": {
-    "source": "iana",
-    "extensions": ["nnd"]
-  },
-  "application/vnd.noblenet-sealer": {
-    "source": "iana",
-    "extensions": ["nns"]
-  },
-  "application/vnd.noblenet-web": {
-    "source": "iana",
-    "extensions": ["nnw"]
-  },
-  "application/vnd.nokia.catalogs": {
-    "source": "iana"
-  },
-  "application/vnd.nokia.conml+wbxml": {
-    "source": "iana"
-  },
-  "application/vnd.nokia.conml+xml": {
-    "source": "iana"
-  },
-  "application/vnd.nokia.iptv.config+xml": {
-    "source": "iana"
-  },
-  "application/vnd.nokia.isds-radio-presets": {
-    "source": "iana"
-  },
-  "application/vnd.nokia.landmark+wbxml": {
-    "source": "iana"
-  },
-  "application/vnd.nokia.landmark+xml": {
-    "source": "iana"
-  },
-  "application/vnd.nokia.landmarkcollection+xml": {
-    "source": "iana"
-  },
-  "application/vnd.nokia.n-gage.ac+xml": {
-    "source": "iana"
-  },
-  "application/vnd.nokia.n-gage.data": {
-    "source": "iana",
-    "extensions": ["ngdat"]
-  },
-  "application/vnd.nokia.n-gage.symbian.install": {
-    "source": "iana",
-    "extensions": ["n-gage"]
-  },
-  "application/vnd.nokia.ncd": {
-    "source": "iana"
-  },
-  "application/vnd.nokia.pcd+wbxml": {
-    "source": "iana"
-  },
-  "application/vnd.nokia.pcd+xml": {
-    "source": "iana"
-  },
-  "application/vnd.nokia.radio-preset": {
-    "source": "iana",
-    "extensions": ["rpst"]
-  },
-  "application/vnd.nokia.radio-presets": {
-    "source": "iana",
-    "extensions": ["rpss"]
-  },
-  "application/vnd.novadigm.edm": {
-    "source": "iana",
-    "extensions": ["edm"]
-  },
-  "application/vnd.novadigm.edx": {
-    "source": "iana",
-    "extensions": ["edx"]
-  },
-  "application/vnd.novadigm.ext": {
-    "source": "iana",
-    "extensions": ["ext"]
-  },
-  "application/vnd.ntt-local.content-share": {
-    "source": "iana"
-  },
-  "application/vnd.ntt-local.file-transfer": {
-    "source": "iana"
-  },
-  "application/vnd.ntt-local.ogw_remote-access": {
-    "source": "iana"
-  },
-  "application/vnd.ntt-local.sip-ta_remote": {
-    "source": "iana"
-  },
-  "application/vnd.ntt-local.sip-ta_tcp_stream": {
-    "source": "iana"
-  },
-  "application/vnd.oasis.opendocument.chart": {
-    "source": "iana",
-    "extensions": ["odc"]
-  },
-  "application/vnd.oasis.opendocument.chart-template": {
-    "source": "iana",
-    "extensions": ["otc"]
-  },
-  "application/vnd.oasis.opendocument.database": {
-    "source": "iana",
-    "extensions": ["odb"]
-  },
-  "application/vnd.oasis.opendocument.formula": {
-    "source": "iana",
-    "extensions": ["odf"]
-  },
-  "application/vnd.oasis.opendocument.formula-template": {
-    "source": "iana",
-    "extensions": ["odft"]
-  },
-  "application/vnd.oasis.opendocument.graphics": {
-    "source": "iana",
-    "compressible": false,
-    "extensions": ["odg"]
-  },
-  "application/vnd.oasis.opendocument.graphics-template": {
-    "source": "iana",
-    "extensions": ["otg"]
-  },
-  "application/vnd.oasis.opendocument.image": {
-    "source": "iana",
-    "extensions": ["odi"]
-  },
-  "application/vnd.oasis.opendocument.image-template": {
-    "source": "iana",
-    "extensions": ["oti"]
-  },
-  "application/vnd.oasis.opendocument.presentation": {
-    "source": "iana",
-    "compressible": false,
-    "extensions": ["odp"]
-  },
-  "application/vnd.oasis.opendocument.presentation-template": {
-    "source": "iana",
-    "extensions": ["otp"]
-  },
-  "application/vnd.oasis.opendocument.spreadsheet": {
-    "source": "iana",
-    "compressible": false,
-    "extensions": ["ods"]
-  },
-  "application/vnd.oasis.opendocument.spreadsheet-template": {
-    "source": "iana",
-    "extensions": ["ots"]
-  },
-  "application/vnd.oasis.opendocument.text": {
-    "source": "iana",
-    "compressible": false,
-    "extensions": ["odt"]
-  },
-  "application/vnd.oasis.opendocument.text-master": {
-    "source": "iana",
-    "extensions": ["odm"]
-  },
-  "application/vnd.oasis.opendocument.text-template": {
-    "source": "iana",
-    "extensions": ["ott"]
-  },
-  "application/vnd.oasis.opendocument.text-web": {
-    "source": "iana",
-    "extensions": ["oth"]
-  },
-  "application/vnd.obn": {
-    "source": "iana"
-  },
-  "application/vnd.oftn.l10n+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/vnd.oipf.contentaccessdownload+xml": {
-    "source": "iana"
-  },
-  "application/vnd.oipf.contentaccessstreaming+xml": {
-    "source": "iana"
-  },
-  "application/vnd.oipf.cspg-hexbinary": {
-    "source": "iana"
-  },
-  "application/vnd.oipf.dae.svg+xml": {
-    "source": "iana"
-  },
-  "application/vnd.oipf.dae.xhtml+xml": {
-    "source": "iana"
-  },
-  "application/vnd.oipf.mippvcontrolmessage+xml": {
-    "source": "iana"
-  },
-  "application/vnd.oipf.pae.gem": {
-    "source": "iana"
-  },
-  "application/vnd.oipf.spdiscovery+xml": {
-    "source": "iana"
-  },
-  "application/vnd.oipf.spdlist+xml": {
-    "source": "iana"
-  },
-  "application/vnd.oipf.ueprofile+xml": {
-    "source": "iana"
-  },
-  "application/vnd.oipf.userprofile+xml": {
-    "source": "iana"
-  },
-  "application/vnd.olpc-sugar": {
-    "source": "iana",
-    "extensions": ["xo"]
-  },
-  "application/vnd.oma-scws-config": {
-    "source": "iana"
-  },
-  "application/vnd.oma-scws-http-request": {
-    "source": "iana"
-  },
-  "application/vnd.oma-scws-http-response": {
-    "source": "iana"
-  },
-  "application/vnd.oma.bcast.associated-procedure-parameter+xml": {
-    "source": "iana"
-  },
-  "application/vnd.oma.bcast.drm-trigger+xml": {
-    "source": "iana"
-  },
-  "application/vnd.oma.bcast.imd+xml": {
-    "source": "iana"
-  },
-  "application/vnd.oma.bcast.ltkm": {
-    "source": "iana"
-  },
-  "application/vnd.oma.bcast.notification+xml": {
-    "source": "iana"
-  },
-  "application/vnd.oma.bcast.provisioningtrigger": {
-    "source": "iana"
-  },
-  "application/vnd.oma.bcast.sgboot": {
-    "source": "iana"
-  },
-  "application/vnd.oma.bcast.sgdd+xml": {
-    "source": "iana"
-  },
-  "application/vnd.oma.bcast.sgdu": {
-    "source": "iana"
-  },
-  "application/vnd.oma.bcast.simple-symbol-container": {
-    "source": "iana"
-  },
-  "application/vnd.oma.bcast.smartcard-trigger+xml": {
-    "source": "iana"
-  },
-  "application/vnd.oma.bcast.sprov+xml": {
-    "source": "iana"
-  },
-  "application/vnd.oma.bcast.stkm": {
-    "source": "iana"
-  },
-  "application/vnd.oma.cab-address-book+xml": {
-    "source": "iana"
-  },
-  "application/vnd.oma.cab-feature-handler+xml": {
-    "source": "iana"
-  },
-  "application/vnd.oma.cab-pcc+xml": {
-    "source": "iana"
-  },
-  "application/vnd.oma.cab-subs-invite+xml": {
-    "source": "iana"
-  },
-  "application/vnd.oma.cab-user-prefs+xml": {
-    "source": "iana"
-  },
-  "application/vnd.oma.dcd": {
-    "source": "iana"
-  },
-  "application/vnd.oma.dcdc": {
-    "source": "iana"
-  },
-  "application/vnd.oma.dd2+xml": {
-    "source": "iana",
-    "extensions": ["dd2"]
-  },
-  "application/vnd.oma.drm.risd+xml": {
-    "source": "iana"
-  },
-  "application/vnd.oma.group-usage-list+xml": {
-    "source": "iana"
-  },
-  "application/vnd.oma.pal+xml": {
-    "source": "iana"
-  },
-  "application/vnd.oma.poc.detailed-progress-report+xml": {
-    "source": "iana"
-  },
-  "application/vnd.oma.poc.final-report+xml": {
-    "source": "iana"
-  },
-  "application/vnd.oma.poc.groups+xml": {
-    "source": "iana"
-  },
-  "application/vnd.oma.poc.invocation-descriptor+xml": {
-    "source": "iana"
-  },
-  "application/vnd.oma.poc.optimized-progress-report+xml": {
-    "source": "iana"
-  },
-  "application/vnd.oma.push": {
-    "source": "iana"
-  },
-  "application/vnd.oma.scidm.messages+xml": {
-    "source": "iana"
-  },
-  "application/vnd.oma.xcap-directory+xml": {
-    "source": "iana"
-  },
-  "application/vnd.omads-email+xml": {
-    "source": "iana"
-  },
-  "application/vnd.omads-file+xml": {
-    "source": "iana"
-  },
-  "application/vnd.omads-folder+xml": {
-    "source": "iana"
-  },
-  "application/vnd.omaloc-supl-init": {
-    "source": "iana"
-  },
-  "application/vnd.openeye.oeb": {
-    "source": "iana"
-  },
-  "application/vnd.openofficeorg.extension": {
-    "source": "apache",
-    "extensions": ["oxt"]
-  },
-  "application/vnd.openxmlformats-officedocument.custom-properties+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.customxmlproperties+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.drawing+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.drawingml.chart+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.drawingml.chartshapes+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.drawingml.diagramcolors+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.drawingml.diagramdata+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.drawingml.diagramlayout+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.drawingml.diagramstyle+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.extended-properties+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.presentationml-template": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.presentationml.commentauthors+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.presentationml.comments+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.presentationml.handoutmaster+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.presentationml.notesmaster+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.presentationml.notesslide+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.presentationml.presentation": {
-    "source": "iana",
-    "compressible": false,
-    "extensions": ["pptx"]
-  },
-  "application/vnd.openxmlformats-officedocument.presentationml.presentation.main+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.presentationml.presprops+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.presentationml.slide": {
-    "source": "iana",
-    "extensions": ["sldx"]
-  },
-  "application/vnd.openxmlformats-officedocument.presentationml.slide+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.presentationml.slidelayout+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.presentationml.slidemaster+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.presentationml.slideshow": {
-    "source": "iana",
-    "extensions": ["ppsx"]
-  },
-  "application/vnd.openxmlformats-officedocument.presentationml.slideshow.main+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.presentationml.slideupdateinfo+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.presentationml.tablestyles+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.presentationml.tags+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.presentationml.template": {
-    "source": "apache",
-    "extensions": ["potx"]
-  },
-  "application/vnd.openxmlformats-officedocument.presentationml.template.main+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.presentationml.viewprops+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.spreadsheetml-template": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.spreadsheetml.calcchain+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.spreadsheetml.chartsheet+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.spreadsheetml.comments+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.spreadsheetml.connections+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.spreadsheetml.dialogsheet+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.spreadsheetml.externallink+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.spreadsheetml.pivotcachedefinition+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.spreadsheetml.pivotcacherecords+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.spreadsheetml.pivottable+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.spreadsheetml.querytable+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.spreadsheetml.revisionheaders+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.spreadsheetml.revisionlog+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.spreadsheetml.sharedstrings+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet": {
-    "source": "iana",
-    "compressible": false,
-    "extensions": ["xlsx"]
-  },
-  "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.spreadsheetml.sheetmetadata+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.spreadsheetml.styles+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.spreadsheetml.table+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.spreadsheetml.tablesinglecells+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.spreadsheetml.template": {
-    "source": "apache",
-    "extensions": ["xltx"]
-  },
-  "application/vnd.openxmlformats-officedocument.spreadsheetml.template.main+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.spreadsheetml.usernames+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.spreadsheetml.volatiledependencies+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.spreadsheetml.worksheet+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.theme+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.themeoverride+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.vmldrawing": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.wordprocessingml-template": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.wordprocessingml.comments+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.wordprocessingml.document": {
-    "source": "iana",
-    "compressible": false,
-    "extensions": ["docx"]
-  },
-  "application/vnd.openxmlformats-officedocument.wordprocessingml.document.glossary+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.wordprocessingml.document.main+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.wordprocessingml.endnotes+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.wordprocessingml.fonttable+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.wordprocessingml.footer+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.wordprocessingml.footnotes+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.wordprocessingml.numbering+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.wordprocessingml.settings+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.wordprocessingml.styles+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.wordprocessingml.template": {
-    "source": "apache",
-    "extensions": ["dotx"]
-  },
-  "application/vnd.openxmlformats-officedocument.wordprocessingml.template.main+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-officedocument.wordprocessingml.websettings+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-package.core-properties+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-package.digital-signature-xmlsignature+xml": {
-    "source": "iana"
-  },
-  "application/vnd.openxmlformats-package.relationships+xml": {
-    "source": "iana"
-  },
-  "application/vnd.oracle.resource+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/vnd.orange.indata": {
-    "source": "iana"
-  },
-  "application/vnd.osa.netdeploy": {
-    "source": "iana"
-  },
-  "application/vnd.osgeo.mapguide.package": {
-    "source": "iana",
-    "extensions": ["mgp"]
-  },
-  "application/vnd.osgi.bundle": {
-    "source": "iana"
-  },
-  "application/vnd.osgi.dp": {
-    "source": "iana",
-    "extensions": ["dp"]
-  },
-  "application/vnd.osgi.subsystem": {
-    "source": "iana",
-    "extensions": ["esa"]
-  },
-  "application/vnd.otps.ct-kip+xml": {
-    "source": "iana"
-  },
-  "application/vnd.palm": {
-    "source": "iana",
-    "extensions": ["pdb","pqa","oprc"]
-  },
-  "application/vnd.panoply": {
-    "source": "iana"
-  },
-  "application/vnd.paos+xml": {
-    "source": "iana"
-  },
-  "application/vnd.paos.xml": {
-    "source": "apache"
-  },
-  "application/vnd.pawaafile": {
-    "source": "iana",
-    "extensions": ["paw"]
-  },
-  "application/vnd.pcos": {
-    "source": "iana"
-  },
-  "application/vnd.pg.format": {
-    "source": "iana",
-    "extensions": ["str"]
-  },
-  "application/vnd.pg.osasli": {
-    "source": "iana",
-    "extensions": ["ei6"]
-  },
-  "application/vnd.piaccess.application-licence": {
-    "source": "iana"
-  },
-  "application/vnd.picsel": {
-    "source": "iana",
-    "extensions": ["efif"]
-  },
-  "application/vnd.pmi.widget": {
-    "source": "iana",
-    "extensions": ["wg"]
-  },
-  "application/vnd.poc.group-advertisement+xml": {
-    "source": "iana"
-  },
-  "application/vnd.pocketlearn": {
-    "source": "iana",
-    "extensions": ["plf"]
-  },
-  "application/vnd.powerbuilder6": {
-    "source": "iana",
-    "extensions": ["pbd"]
-  },
-  "application/vnd.powerbuilder6-s": {
-    "source": "iana"
-  },
-  "application/vnd.powerbuilder7": {
-    "source": "iana"
-  },
-  "application/vnd.powerbuilder7-s": {
-    "source": "iana"
-  },
-  "application/vnd.powerbuilder75": {
-    "source": "iana"
-  },
-  "application/vnd.powerbuilder75-s": {
-    "source": "iana"
-  },
-  "application/vnd.preminet": {
-    "source": "iana"
-  },
-  "application/vnd.previewsystems.box": {
-    "source": "iana",
-    "extensions": ["box"]
-  },
-  "application/vnd.proteus.magazine": {
-    "source": "iana",
-    "extensions": ["mgz"]
-  },
-  "application/vnd.publishare-delta-tree": {
-    "source": "iana",
-    "extensions": ["qps"]
-  },
-  "application/vnd.pvi.ptid1": {
-    "source": "iana",
-    "extensions": ["ptid"]
-  },
-  "application/vnd.pwg-multiplexed": {
-    "source": "iana"
-  },
-  "application/vnd.pwg-xhtml-print+xml": {
-    "source": "iana"
-  },
-  "application/vnd.qualcomm.brew-app-res": {
-    "source": "iana"
-  },
-  "application/vnd.quark.quarkxpress": {
-    "source": "iana",
-    "extensions": ["qxd","qxt","qwd","qwt","qxl","qxb"]
-  },
-  "application/vnd.quobject-quoxdocument": {
-    "source": "iana"
-  },
-  "application/vnd.radisys.moml+xml": {
-    "source": "iana"
-  },
-  "application/vnd.radisys.msml+xml": {
-    "source": "iana"
-  },
-  "application/vnd.radisys.msml-audit+xml": {
-    "source": "iana"
-  },
-  "application/vnd.radisys.msml-audit-conf+xml": {
-    "source": "iana"
-  },
-  "application/vnd.radisys.msml-audit-conn+xml": {
-    "source": "iana"
-  },
-  "application/vnd.radisys.msml-audit-dialog+xml": {
-    "source": "iana"
-  },
-  "application/vnd.radisys.msml-audit-stream+xml": {
-    "source": "iana"
-  },
-  "application/vnd.radisys.msml-conf+xml": {
-    "source": "iana"
-  },
-  "application/vnd.radisys.msml-dialog+xml": {
-    "source": "iana"
-  },
-  "application/vnd.radisys.msml-dialog-base+xml": {
-    "source": "iana"
-  },
-  "application/vnd.radisys.msml-dialog-fax-detect+xml": {
-    "source": "iana"
-  },
-  "application/vnd.radisys.msml-dialog-fax-sendrecv+xml": {
-    "source": "iana"
-  },
-  "application/vnd.radisys.msml-dialog-group+xml": {
-    "source": "iana"
-  },
-  "application/vnd.radisys.msml-dialog-speech+xml": {
-    "source": "iana"
-  },
-  "application/vnd.radisys.msml-dialog-transform+xml": {
-    "source": "iana"
-  },
-  "application/vnd.rainstor.data": {
-    "source": "iana"
-  },
-  "application/vnd.rapid": {
-    "source": "iana"
-  },
-  "application/vnd.realvnc.bed": {
-    "source": "iana",
-    "extensions": ["bed"]
-  },
-  "application/vnd.recordare.musicxml": {
-    "source": "iana",
-    "extensions": ["mxl"]
-  },
-  "application/vnd.recordare.musicxml+xml": {
-    "source": "iana",
-    "extensions": ["musicxml"]
-  },
-  "application/vnd.renlearn.rlprint": {
-    "source": "iana"
-  },
-  "application/vnd.rig.cryptonote": {
-    "source": "iana",
-    "extensions": ["cryptonote"]
-  },
-  "application/vnd.rim.cod": {
-    "source": "apache",
-    "extensions": ["cod"]
-  },
-  "application/vnd.rn-realmedia": {
-    "source": "apache",
-    "extensions": ["rm"]
-  },
-  "application/vnd.rn-realmedia-vbr": {
-    "source": "apache",
-    "extensions": ["rmvb"]
-  },
-  "application/vnd.route66.link66+xml": {
-    "source": "iana",
-    "extensions": ["link66"]
-  },
-  "application/vnd.rs-274x": {
-    "source": "iana"
-  },
-  "application/vnd.ruckus.download": {
-    "source": "iana"
-  },
-  "application/vnd.s3sms": {
-    "source": "iana"
-  },
-  "application/vnd.sailingtracker.track": {
-    "source": "iana",
-    "extensions": ["st"]
-  },
-  "application/vnd.sbm.cid": {
-    "source": "iana"
-  },
-  "application/vnd.sbm.mid2": {
-    "source": "iana"
-  },
-  "application/vnd.scribus": {
-    "source": "iana"
-  },
-  "application/vnd.sealed.3df": {
-    "source": "iana"
-  },
-  "application/vnd.sealed.csf": {
-    "source": "iana"
-  },
-  "application/vnd.sealed.doc": {
-    "source": "iana"
-  },
-  "application/vnd.sealed.eml": {
-    "source": "iana"
-  },
-  "application/vnd.sealed.mht": {
-    "source": "iana"
-  },
-  "application/vnd.sealed.net": {
-    "source": "iana"
-  },
-  "application/vnd.sealed.ppt": {
-    "source": "iana"
-  },
-  "application/vnd.sealed.tiff": {
-    "source": "iana"
-  },
-  "application/vnd.sealed.xls": {
-    "source": "iana"
-  },
-  "application/vnd.sealedmedia.softseal.html": {
-    "source": "iana"
-  },
-  "application/vnd.sealedmedia.softseal.pdf": {
-    "source": "iana"
-  },
-  "application/vnd.seemail": {
-    "source": "iana",
-    "extensions": ["see"]
-  },
-  "application/vnd.sema": {
-    "source": "iana",
-    "extensions": ["sema"]
-  },
-  "application/vnd.semd": {
-    "source": "iana",
-    "extensions": ["semd"]
-  },
-  "application/vnd.semf": {
-    "source": "iana",
-    "extensions": ["semf"]
-  },
-  "application/vnd.shana.informed.formdata": {
-    "source": "iana",
-    "extensions": ["ifm"]
-  },
-  "application/vnd.shana.informed.formtemplate": {
-    "source": "iana",
-    "extensions": ["itp"]
-  },
-  "application/vnd.shana.informed.interchange": {
-    "source": "iana",
-    "extensions": ["iif"]
-  },
-  "application/vnd.shana.informed.package": {
-    "source": "iana",
-    "extensions": ["ipk"]
-  },
-  "application/vnd.simtech-mindmapper": {
-    "source": "iana",
-    "extensions": ["twd","twds"]
-  },
-  "application/vnd.siren+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/vnd.smaf": {
-    "source": "iana",
-    "extensions": ["mmf"]
-  },
-  "application/vnd.smart.notebook": {
-    "source": "iana"
-  },
-  "application/vnd.smart.teacher": {
-    "source": "iana",
-    "extensions": ["teacher"]
-  },
-  "application/vnd.software602.filler.form+xml": {
-    "source": "iana"
-  },
-  "application/vnd.software602.filler.form-xml-zip": {
-    "source": "iana"
-  },
-  "application/vnd.solent.sdkm+xml": {
-    "source": "iana",
-    "extensions": ["sdkm","sdkd"]
-  },
-  "application/vnd.spotfire.dxp": {
-    "source": "iana",
-    "extensions": ["dxp"]
-  },
-  "application/vnd.spotfire.sfs": {
-    "source": "iana",
-    "extensions": ["sfs"]
-  },
-  "application/vnd.sss-cod": {
-    "source": "iana"
-  },
-  "application/vnd.sss-dtf": {
-    "source": "iana"
-  },
-  "application/vnd.sss-ntf": {
-    "source": "iana"
-  },
-  "application/vnd.stardivision.calc": {
-    "source": "apache",
-    "extensions": ["sdc"]
-  },
-  "application/vnd.stardivision.draw": {
-    "source": "apache",
-    "extensions": ["sda"]
-  },
-  "application/vnd.stardivision.impress": {
-    "source": "apache",
-    "extensions": ["sdd"]
-  },
-  "application/vnd.stardivision.math": {
-    "source": "apache",
-    "extensions": ["smf"]
-  },
-  "application/vnd.stardivision.writer": {
-    "source": "apache",
-    "extensions": ["sdw","vor"]
-  },
-  "application/vnd.stardivision.writer-global": {
-    "source": "apache",
-    "extensions": ["sgl"]
-  },
-  "application/vnd.stepmania.package": {
-    "source": "iana",
-    "extensions": ["smzip"]
-  },
-  "application/vnd.stepmania.stepchart": {
-    "source": "iana",
-    "extensions": ["sm"]
-  },
-  "application/vnd.street-stream": {
-    "source": "iana"
-  },
-  "application/vnd.sun.wadl+xml": {
-    "source": "iana"
-  },
-  "application/vnd.sun.xml.calc": {
-    "source": "apache",
-    "extensions": ["sxc"]
-  },
-  "application/vnd.sun.xml.calc.template": {
-    "source": "apache",
-    "extensions": ["stc"]
-  },
-  "application/vnd.sun.xml.draw": {
-    "source": "apache",
-    "extensions": ["sxd"]
-  },
-  "application/vnd.sun.xml.draw.template": {
-    "source": "apache",
-    "extensions": ["std"]
-  },
-  "application/vnd.sun.xml.impress": {
-    "source": "apache",
-    "extensions": ["sxi"]
-  },
-  "application/vnd.sun.xml.impress.template": {
-    "source": "apache",
-    "extensions": ["sti"]
-  },
-  "application/vnd.sun.xml.math": {
-    "source": "apache",
-    "extensions": ["sxm"]
-  },
-  "application/vnd.sun.xml.writer": {
-    "source": "apache",
-    "extensions": ["sxw"]
-  },
-  "application/vnd.sun.xml.writer.global": {
-    "source": "apache",
-    "extensions": ["sxg"]
-  },
-  "application/vnd.sun.xml.writer.template": {
-    "source": "apache",
-    "extensions": ["stw"]
-  },
-  "application/vnd.sus-calendar": {
-    "source": "iana",
-    "extensions": ["sus","susp"]
-  },
-  "application/vnd.svd": {
-    "source": "iana",
-    "extensions": ["svd"]
-  },
-  "application/vnd.swiftview-ics": {
-    "source": "iana"
-  },
-  "application/vnd.symbian.install": {
-    "source": "apache",
-    "extensions": ["sis","sisx"]
-  },
-  "application/vnd.syncml+xml": {
-    "source": "iana",
-    "extensions": ["xsm"]
-  },
-  "application/vnd.syncml.dm+wbxml": {
-    "source": "iana",
-    "extensions": ["bdm"]
-  },
-  "application/vnd.syncml.dm+xml": {
-    "source": "iana",
-    "extensions": ["xdm"]
-  },
-  "application/vnd.syncml.dm.notification": {
-    "source": "iana"
-  },
-  "application/vnd.syncml.dmddf+wbxml": {
-    "source": "iana"
-  },
-  "application/vnd.syncml.dmddf+xml": {
-    "source": "iana"
-  },
-  "application/vnd.syncml.dmtnds+wbxml": {
-    "source": "iana"
-  },
-  "application/vnd.syncml.dmtnds+xml": {
-    "source": "iana"
-  },
-  "application/vnd.syncml.ds.notification": {
-    "source": "iana"
-  },
-  "application/vnd.tao.intent-module-archive": {
-    "source": "iana",
-    "extensions": ["tao"]
-  },
-  "application/vnd.tcpdump.pcap": {
-    "source": "iana",
-    "extensions": ["pcap","cap","dmp"]
-  },
-  "application/vnd.tmd.mediaflex.api+xml": {
-    "source": "iana"
-  },
-  "application/vnd.tmobile-livetv": {
-    "source": "iana",
-    "extensions": ["tmo"]
-  },
-  "application/vnd.trid.tpt": {
-    "source": "iana",
-    "extensions": ["tpt"]
-  },
-  "application/vnd.triscape.mxs": {
-    "source": "iana",
-    "extensions": ["mxs"]
-  },
-  "application/vnd.trueapp": {
-    "source": "iana",
-    "extensions": ["tra"]
-  },
-  "application/vnd.truedoc": {
-    "source": "iana"
-  },
-  "application/vnd.ubisoft.webplayer": {
-    "source": "iana"
-  },
-  "application/vnd.ufdl": {
-    "source": "iana",
-    "extensions": ["ufd","ufdl"]
-  },
-  "application/vnd.uiq.theme": {
-    "source": "iana",
-    "extensions": ["utz"]
-  },
-  "application/vnd.umajin": {
-    "source": "iana",
-    "extensions": ["umj"]
-  },
-  "application/vnd.unity": {
-    "source": "iana",
-    "extensions": ["unityweb"]
-  },
-  "application/vnd.uoml+xml": {
-    "source": "iana",
-    "extensions": ["uoml"]
-  },
-  "application/vnd.uplanet.alert": {
-    "source": "iana"
-  },
-  "application/vnd.uplanet.alert-wbxml": {
-    "source": "iana"
-  },
-  "application/vnd.uplanet.bearer-choice": {
-    "source": "iana"
-  },
-  "application/vnd.uplanet.bearer-choice-wbxml": {
-    "source": "iana"
-  },
-  "application/vnd.uplanet.cacheop": {
-    "source": "iana"
-  },
-  "application/vnd.uplanet.cacheop-wbxml": {
-    "source": "iana"
-  },
-  "application/vnd.uplanet.channel": {
-    "source": "iana"
-  },
-  "application/vnd.uplanet.channel-wbxml": {
-    "source": "iana"
-  },
-  "application/vnd.uplanet.list": {
-    "source": "iana"
-  },
-  "application/vnd.uplanet.list-wbxml": {
-    "source": "iana"
-  },
-  "application/vnd.uplanet.listcmd": {
-    "source": "iana"
-  },
-  "application/vnd.uplanet.listcmd-wbxml": {
-    "source": "iana"
-  },
-  "application/vnd.uplanet.signal": {
-    "source": "iana"
-  },
-  "application/vnd.valve.source.material": {
-    "source": "iana"
-  },
-  "application/vnd.vcx": {
-    "source": "iana",
-    "extensions": ["vcx"]
-  },
-  "application/vnd.vd-study": {
-    "source": "iana"
-  },
-  "application/vnd.vectorworks": {
-    "source": "iana"
-  },
-  "application/vnd.verimatrix.vcas": {
-    "source": "iana"
-  },
-  "application/vnd.vidsoft.vidconference": {
-    "source": "iana"
-  },
-  "application/vnd.visio": {
-    "source": "iana",
-    "extensions": ["vsd","vst","vss","vsw"]
-  },
-  "application/vnd.visionary": {
-    "source": "iana",
-    "extensions": ["vis"]
-  },
-  "application/vnd.vividence.scriptfile": {
-    "source": "iana"
-  },
-  "application/vnd.vsf": {
-    "source": "iana",
-    "extensions": ["vsf"]
-  },
-  "application/vnd.wap.sic": {
-    "source": "iana"
-  },
-  "application/vnd.wap.slc": {
-    "source": "iana"
-  },
-  "application/vnd.wap.wbxml": {
-    "source": "iana",
-    "extensions": ["wbxml"]
-  },
-  "application/vnd.wap.wmlc": {
-    "source": "iana",
-    "extensions": ["wmlc"]
-  },
-  "application/vnd.wap.wmlscriptc": {
-    "source": "iana",
-    "extensions": ["wmlsc"]
-  },
-  "application/vnd.webturbo": {
-    "source": "iana",
-    "extensions": ["wtb"]
-  },
-  "application/vnd.wfa.p2p": {
-    "source": "iana"
-  },
-  "application/vnd.wfa.wsc": {
-    "source": "iana"
-  },
-  "application/vnd.windows.devicepairing": {
-    "source": "iana"
-  },
-  "application/vnd.wmc": {
-    "source": "iana"
-  },
-  "application/vnd.wmf.bootstrap": {
-    "source": "iana"
-  },
-  "application/vnd.wolfram.mathematica": {
-    "source": "iana"
-  },
-  "application/vnd.wolfram.mathematica.package": {
-    "source": "iana"
-  },
-  "application/vnd.wolfram.player": {
-    "source": "iana",
-    "extensions": ["nbp"]
-  },
-  "application/vnd.wordperfect": {
-    "source": "iana",
-    "extensions": ["wpd"]
-  },
-  "application/vnd.wqd": {
-    "source": "iana",
-    "extensions": ["wqd"]
-  },
-  "application/vnd.wrq-hp3000-labelled": {
-    "source": "iana"
-  },
-  "application/vnd.wt.stf": {
-    "source": "iana",
-    "extensions": ["stf"]
-  },
-  "application/vnd.wv.csp+wbxml": {
-    "source": "iana"
-  },
-  "application/vnd.wv.csp+xml": {
-    "source": "iana"
-  },
-  "application/vnd.wv.ssp+xml": {
-    "source": "iana"
-  },
-  "application/vnd.xacml+json": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/vnd.xara": {
-    "source": "iana",
-    "extensions": ["xar"]
-  },
-  "application/vnd.xfdl": {
-    "source": "iana",
-    "extensions": ["xfdl"]
-  },
-  "application/vnd.xfdl.webform": {
-    "source": "iana"
-  },
-  "application/vnd.xmi+xml": {
-    "source": "iana"
-  },
-  "application/vnd.xmpie.cpkg": {
-    "source": "iana"
-  },
-  "application/vnd.xmpie.dpkg": {
-    "source": "iana"
-  },
-  "application/vnd.xmpie.plan": {
-    "source": "iana"
-  },
-  "application/vnd.xmpie.ppkg": {
-    "source": "iana"
-  },
-  "application/vnd.xmpie.xlim": {
-    "source": "iana"
-  },
-  "application/vnd.yamaha.hv-dic": {
-    "source": "iana",
-    "extensions": ["hvd"]
-  },
-  "application/vnd.yamaha.hv-script": {
-    "source": "iana",
-    "extensions": ["hvs"]
-  },
-  "application/vnd.yamaha.hv-voice": {
-    "source": "iana",
-    "extensions": ["hvp"]
-  },
-  "application/vnd.yamaha.openscoreformat": {
-    "source": "iana",
-    "extensions": ["osf"]
-  },
-  "application/vnd.yamaha.openscoreformat.osfpvg+xml": {
-    "source": "iana",
-    "extensions": ["osfpvg"]
-  },
-  "application/vnd.yamaha.remote-setup": {
-    "source": "iana"
-  },
-  "application/vnd.yamaha.smaf-audio": {
-    "source": "iana",
-    "extensions": ["saf"]
-  },
-  "application/vnd.yamaha.smaf-phrase": {
-    "source": "iana",
-    "extensions": ["spf"]
-  },
-  "application/vnd.yamaha.through-ngn": {
-    "source": "iana"
-  },
-  "application/vnd.yamaha.tunnel-udpencap": {
-    "source": "iana"
-  },
-  "application/vnd.yaoweme": {
-    "source": "iana"
-  },
-  "application/vnd.yellowriver-custom-menu": {
-    "source": "iana",
-    "extensions": ["cmp"]
-  },
-  "application/vnd.zul": {
-    "source": "iana",
-    "extensions": ["zir","zirz"]
-  },
-  "application/vnd.zzazz.deck+xml": {
-    "source": "iana",
-    "extensions": ["zaz"]
-  },
-  "application/voicexml+xml": {
-    "source": "iana",
-    "extensions": ["vxml"]
-  },
-  "application/vq-rtcpxr": {
-    "source": "iana"
-  },
-  "application/watcherinfo+xml": {
-    "source": "iana"
-  },
-  "application/whoispp-query": {
-    "source": "iana"
-  },
-  "application/whoispp-response": {
-    "source": "iana"
-  },
-  "application/widget": {
-    "source": "iana",
-    "extensions": ["wgt"]
-  },
-  "application/winhlp": {
-    "source": "apache",
-    "extensions": ["hlp"]
-  },
-  "application/wita": {
-    "source": "iana"
-  },
-  "application/wordperfect5.1": {
-    "source": "iana"
-  },
-  "application/wsdl+xml": {
-    "source": "iana",
-    "extensions": ["wsdl"]
-  },
-  "application/wspolicy+xml": {
-    "source": "iana",
-    "extensions": ["wspolicy"]
-  },
-  "application/x-7z-compressed": {
-    "source": "apache",
-    "compressible": false,
-    "extensions": ["7z"]
-  },
-  "application/x-abiword": {
-    "source": "apache",
-    "extensions": ["abw"]
-  },
-  "application/x-ace-compressed": {
-    "source": "apache",
-    "extensions": ["ace"]
-  },
-  "application/x-amf": {
-    "source": "apache"
-  },
-  "application/x-apple-diskimage": {
-    "source": "apache",
-    "extensions": ["dmg"]
-  },
-  "application/x-authorware-bin": {
-    "source": "apache",
-    "extensions": ["aab","x32","u32","vox"]
-  },
-  "application/x-authorware-map": {
-    "source": "apache",
-    "extensions": ["aam"]
-  },
-  "application/x-authorware-seg": {
-    "source": "apache",
-    "extensions": ["aas"]
-  },
-  "application/x-bcpio": {
-    "source": "apache",
-    "extensions": ["bcpio"]
-  },
-  "application/x-bdoc": {
-    "compressible": false,
-    "extensions": ["bdoc"]
-  },
-  "application/x-bittorrent": {
-    "source": "apache",
-    "extensions": ["torrent"]
-  },
-  "application/x-blorb": {
-    "source": "apache",
-    "extensions": ["blb","blorb"]
-  },
-  "application/x-bzip": {
-    "source": "apache",
-    "compressible": false,
-    "extensions": ["bz"]
-  },
-  "application/x-bzip2": {
-    "source": "apache",
-    "compressible": false,
-    "extensions": ["bz2","boz"]
-  },
-  "application/x-cbr": {
-    "source": "apache",
-    "extensions": ["cbr","cba","cbt","cbz","cb7"]
-  },
-  "application/x-cdlink": {
-    "source": "apache",
-    "extensions": ["vcd"]
-  },
-  "application/x-cfs-compressed": {
-    "source": "apache",
-    "extensions": ["cfs"]
-  },
-  "application/x-chat": {
-    "source": "apache",
-    "extensions": ["chat"]
-  },
-  "application/x-chess-pgn": {
-    "source": "apache",
-    "extensions": ["pgn"]
-  },
-  "application/x-chrome-extension": {
-    "extensions": ["crx"]
-  },
-  "application/x-cocoa": {
-    "source": "nginx",
-    "extensions": ["cco"]
-  },
-  "application/x-compress": {
-    "source": "apache"
-  },
-  "application/x-conference": {
-    "source": "apache",
-    "extensions": ["nsc"]
-  },
-  "application/x-cpio": {
-    "source": "apache",
-    "extensions": ["cpio"]
-  },
-  "application/x-csh": {
-    "source": "apache",
-    "extensions": ["csh"]
-  },
-  "application/x-deb": {
-    "compressible": false
-  },
-  "application/x-debian-package": {
-    "source": "apache",
-    "extensions": ["deb","udeb"]
-  },
-  "application/x-dgc-compressed": {
-    "source": "apache",
-    "extensions": ["dgc"]
-  },
-  "application/x-director": {
-    "source": "apache",
-    "extensions": ["dir","dcr","dxr","cst","cct","cxt","w3d","fgd","swa"]
-  },
-  "application/x-doom": {
-    "source": "apache",
-    "extensions": ["wad"]
-  },
-  "application/x-dtbncx+xml": {
-    "source": "apache",
-    "extensions": ["ncx"]
-  },
-  "application/x-dtbook+xml": {
-    "source": "apache",
-    "extensions": ["dtb"]
-  },
-  "application/x-dtbresource+xml": {
-    "source": "apache",
-    "extensions": ["res"]
-  },
-  "application/x-dvi": {
-    "source": "apache",
-    "compressible": false,
-    "extensions": ["dvi"]
-  },
-  "application/x-envoy": {
-    "source": "apache",
-    "extensions": ["evy"]
-  },
-  "application/x-eva": {
-    "source": "apache",
-    "extensions": ["eva"]
-  },
-  "application/x-font-bdf": {
-    "source": "apache",
-    "extensions": ["bdf"]
-  },
-  "application/x-font-dos": {
-    "source": "apache"
-  },
-  "application/x-font-framemaker": {
-    "source": "apache"
-  },
-  "application/x-font-ghostscript": {
-    "source": "apache",
-    "extensions": ["gsf"]
-  },
-  "application/x-font-libgrx": {
-    "source": "apache"
-  },
-  "application/x-font-linux-psf": {
-    "source": "apache",
-    "extensions": ["psf"]
-  },
-  "application/x-font-otf": {
-    "source": "apache",
-    "compressible": true,
-    "extensions": ["otf"]
-  },
-  "application/x-font-pcf": {
-    "source": "apache",
-    "extensions": ["pcf"]
-  },
-  "application/x-font-snf": {
-    "source": "apache",
-    "extensions": ["snf"]
-  },
-  "application/x-font-speedo": {
-    "source": "apache"
-  },
-  "application/x-font-sunos-news": {
-    "source": "apache"
-  },
-  "application/x-font-ttf": {
-    "source": "apache",
-    "compressible": true,
-    "extensions": ["ttf","ttc"]
-  },
-  "application/x-font-type1": {
-    "source": "apache",
-    "extensions": ["pfa","pfb","pfm","afm"]
-  },
-  "application/x-font-vfont": {
-    "source": "apache"
-  },
-  "application/x-freearc": {
-    "source": "apache",
-    "extensions": ["arc"]
-  },
-  "application/x-futuresplash": {
-    "source": "apache",
-    "extensions": ["spl"]
-  },
-  "application/x-gca-compressed": {
-    "source": "apache",
-    "extensions": ["gca"]
-  },
-  "application/x-glulx": {
-    "source": "apache",
-    "extensions": ["ulx"]
-  },
-  "application/x-gnumeric": {
-    "source": "apache",
-    "extensions": ["gnumeric"]
-  },
-  "application/x-gramps-xml": {
-    "source": "apache",
-    "extensions": ["gramps"]
-  },
-  "application/x-gtar": {
-    "source": "apache",
-    "extensions": ["gtar"]
-  },
-  "application/x-gzip": {
-    "source": "apache"
-  },
-  "application/x-hdf": {
-    "source": "apache",
-    "extensions": ["hdf"]
-  },
-  "application/x-install-instructions": {
-    "source": "apache",
-    "extensions": ["install"]
-  },
-  "application/x-iso9660-image": {
-    "source": "apache",
-    "extensions": ["iso"]
-  },
-  "application/x-java-archive-diff": {
-    "source": "nginx",
-    "extensions": ["jardiff"]
-  },
-  "application/x-java-jnlp-file": {
-    "source": "apache",
-    "compressible": false,
-    "extensions": ["jnlp"]
-  },
-  "application/x-javascript": {
-    "compressible": true
-  },
-  "application/x-latex": {
-    "source": "apache",
-    "compressible": false,
-    "extensions": ["latex"]
-  },
-  "application/x-lua-bytecode": {
-    "extensions": ["luac"]
-  },
-  "application/x-lzh-compressed": {
-    "source": "apache",
-    "extensions": ["lzh","lha"]
-  },
-  "application/x-makeself": {
-    "source": "nginx",
-    "extensions": ["run"]
-  },
-  "application/x-mie": {
-    "source": "apache",
-    "extensions": ["mie"]
-  },
-  "application/x-mobipocket-ebook": {
-    "source": "apache",
-    "extensions": ["prc","mobi"]
-  },
-  "application/x-mpegurl": {
-    "compressible": false
-  },
-  "application/x-ms-application": {
-    "source": "apache",
-    "extensions": ["application"]
-  },
-  "application/x-ms-shortcut": {
-    "source": "apache",
-    "extensions": ["lnk"]
-  },
-  "application/x-ms-wmd": {
-    "source": "apache",
-    "extensions": ["wmd"]
-  },
-  "application/x-ms-wmz": {
-    "source": "apache",
-    "extensions": ["wmz"]
-  },
-  "application/x-ms-xbap": {
-    "source": "apache",
-    "extensions": ["xbap"]
-  },
-  "application/x-msaccess": {
-    "source": "apache",
-    "extensions": ["mdb"]
-  },
-  "application/x-msbinder": {
-    "source": "apache",
-    "extensions": ["obd"]
-  },
-  "application/x-mscardfile": {
-    "source": "apache",
-    "extensions": ["crd"]
-  },
-  "application/x-msclip": {
-    "source": "apache",
-    "extensions": ["clp"]
-  },
-  "application/x-msdownload": {
-    "source": "apache",
-    "extensions": ["exe","dll","com","bat","msi"]
-  },
-  "application/x-msmediaview": {
-    "source": "apache",
-    "extensions": ["mvb","m13","m14"]
-  },
-  "application/x-msmetafile": {
-    "source": "apache",
-    "extensions": ["wmf","wmz","emf","emz"]
-  },
-  "application/x-msmoney": {
-    "source": "apache",
-    "extensions": ["mny"]
-  },
-  "application/x-mspublisher": {
-    "source": "apache",
-    "extensions": ["pub"]
-  },
-  "application/x-msschedule": {
-    "source": "apache",
-    "extensions": ["scd"]
-  },
-  "application/x-msterminal": {
-    "source": "apache",
-    "extensions": ["trm"]
-  },
-  "application/x-mswrite": {
-    "source": "apache",
-    "extensions": ["wri"]
-  },
-  "application/x-netcdf": {
-    "source": "apache",
-    "extensions": ["nc","cdf"]
-  },
-  "application/x-ns-proxy-autoconfig": {
-    "compressible": true,
-    "extensions": ["pac"]
-  },
-  "application/x-nzb": {
-    "source": "apache",
-    "extensions": ["nzb"]
-  },
-  "application/x-perl": {
-    "source": "nginx",
-    "extensions": ["pl","pm"]
-  },
-  "application/x-pilot": {
-    "source": "nginx",
-    "extensions": ["prc","pdb"]
-  },
-  "application/x-pkcs12": {
-    "source": "apache",
-    "compressible": false,
-    "extensions": ["p12","pfx"]
-  },
-  "application/x-pkcs7-certificates": {
-    "source": "apache",
-    "extensions": ["p7b","spc"]
-  },
-  "application/x-pkcs7-certreqresp": {
-    "source": "apache",
-    "extensions": ["p7r"]
-  },
-  "application/x-rar-compressed": {
-    "source": "apache",
-    "compressible": false,
-    "extensions": ["rar"]
-  },
-  "application/x-redhat-package-manager": {
-    "source": "nginx",
-    "extensions": ["rpm"]
-  },
-  "application/x-research-info-systems": {
-    "source": "apache",
-    "extensions": ["ris"]
-  },
-  "application/x-sea": {
-    "source": "nginx",
-    "extensions": ["sea"]
-  },
-  "application/x-sh": {
-    "source": "apache",
-    "compressible": true,
-    "extensions": ["sh"]
-  },
-  "application/x-shar": {
-    "source": "apache",
-    "extensions": ["shar"]
-  },
-  "application/x-shockwave-flash": {
-    "source": "apache",
-    "compressible": false,
-    "extensions": ["swf"]
-  },
-  "application/x-silverlight-app": {
-    "source": "apache",
-    "extensions": ["xap"]
-  },
-  "application/x-sql": {
-    "source": "apache",
-    "extensions": ["sql"]
-  },
-  "application/x-stuffit": {
-    "source": "apache",
-    "compressible": false,
-    "extensions": ["sit"]
-  },
-  "application/x-stuffitx": {
-    "source": "apache",
-    "extensions": ["sitx"]
-  },
-  "application/x-subrip": {
-    "source": "apache",
-    "extensions": ["srt"]
-  },
-  "application/x-sv4cpio": {
-    "source": "apache",
-    "extensions": ["sv4cpio"]
-  },
-  "application/x-sv4crc": {
-    "source": "apache",
-    "extensions": ["sv4crc"]
-  },
-  "application/x-t3vm-image": {
-    "source": "apache",
-    "extensions": ["t3"]
-  },
-  "application/x-tads": {
-    "source": "apache",
-    "extensions": ["gam"]
-  },
-  "application/x-tar": {
-    "source": "apache",
-    "compressible": true,
-    "extensions": ["tar"]
-  },
-  "application/x-tcl": {
-    "source": "apache",
-    "extensions": ["tcl","tk"]
-  },
-  "application/x-tex": {
-    "source": "apache",
-    "extensions": ["tex"]
-  },
-  "application/x-tex-tfm": {
-    "source": "apache",
-    "extensions": ["tfm"]
-  },
-  "application/x-texinfo": {
-    "source": "apache",
-    "extensions": ["texinfo","texi"]
-  },
-  "application/x-tgif": {
-    "source": "apache",
-    "extensions": ["obj"]
-  },
-  "application/x-ustar": {
-    "source": "apache",
-    "extensions": ["ustar"]
-  },
-  "application/x-wais-source": {
-    "source": "apache",
-    "extensions": ["src"]
-  },
-  "application/x-web-app-manifest+json": {
-    "compressible": true,
-    "extensions": ["webapp"]
-  },
-  "application/x-www-form-urlencoded": {
-    "source": "iana",
-    "compressible": true
-  },
-  "application/x-x509-ca-cert": {
-    "source": "apache",
-    "extensions": ["der","crt","pem"]
-  },
-  "application/x-xfig": {
-    "source": "apache",
-    "extensions": ["fig"]
-  },
-  "application/x-xliff+xml": {
-    "source": "apache",
-    "extensions": ["xlf"]
-  },
-  "application/x-xpinstall": {
-    "source": "apache",
-    "compressible": false,
-    "extensions": ["xpi"]
-  },
-  "application/x-xz": {
-    "source": "apache",
-    "extensions": ["xz"]
-  },
-  "application/x-zmachine": {
-    "source": "apache",
-    "extensions": ["z1","z2","z3","z4","z5","z6","z7","z8"]
-  },
-  "application/x400-bp": {
-    "source": "iana"
-  },
-  "application/xacml+xml": {
-    "source": "iana"
-  },
-  "application/xaml+xml": {
-    "source": "apache",
-    "extensions": ["xaml"]
-  },
-  "application/xcap-att+xml": {
-    "source": "iana"
-  },
-  "application/xcap-caps+xml": {
-    "source": "iana"
-  },
-  "application/xcap-diff+xml": {
-    "source": "iana",
-    "extensions": ["xdf"]
-  },
-  "application/xcap-el+xml": {
-    "source": "iana"
-  },
-  "application/xcap-error+xml": {
-    "source": "iana"
-  },
-  "application/xcap-ns+xml": {
-    "source": "iana"
-  },
-  "application/xcon-conference-info+xml": {
-    "source": "iana"
-  },
-  "application/xcon-conference-info-diff+xml": {
-    "source": "iana"
-  },
-  "application/xenc+xml": {
-    "source": "iana",
-    "extensions": ["xenc"]
-  },
-  "application/xhtml+xml": {
-    "source": "iana",
-    "compressible": true,
-    "extensions": ["xhtml","xht"]
-  },
-  "application/xhtml-voice+xml": {
-    "source": "apache"
-  },
-  "application/xml": {
-    "source": "iana",
-    "compressible": true,
-    "extensions": ["xml","xsl","xsd"]
-  },
-  "application/xml-dtd": {
-    "source": "iana",
-    "compressible": true,
-    "extensions": ["dtd"]
-  },
-  "application/xml-external-parsed-entity": {
-    "source": "iana"
-  },
-  "application/xml-patch+xml": {
-    "source": "iana"
-  },
-  "application/xmpp+xml": {
-    "source": "iana"
-  },
-  "application/xop+xml": {
-    "source": "iana",
-    "compressible": true,
-    "extensions": ["xop"]
-  },
-  "application/xproc+xml": {
-    "source": "apache",
-    "extensions": ["xpl"]
-  },
-  "application/xslt+xml": {
-    "source": "iana",
-    "extensions": ["xslt"]
-  },
-  "application/xspf+xml": {
-    "source": "apache",
-    "extensions": ["xspf"]
-  },
-  "application/xv+xml": {
-    "source": "iana",
-    "extensions": ["mxml","xhvml","xvml","xvm"]
-  },
-  "application/yang": {
-    "source": "iana",
-    "extensions": ["yang"]
-  },
-  "application/yin+xml": {
-    "source": "iana",
-    "extensions": ["yin"]
-  },
-  "application/zip": {
-    "source": "iana",
-    "compressible": false,
-    "extensions": ["zip"]
-  },
-  "application/zlib": {
-    "source": "iana"
-  },
-  "audio/1d-interleaved-parityfec": {
-    "source": "iana"
-  },
-  "audio/32kadpcm": {
-    "source": "iana"
-  },
-  "audio/3gpp": {
-    "source": "iana"
-  },
-  "audio/3gpp2": {
-    "source": "iana"
-  },
-  "audio/ac3": {
-    "source": "iana"
-  },
-  "audio/adpcm": {
-    "source": "apache",
-    "extensions": ["adp"]
-  },
-  "audio/amr": {
-    "source": "iana"
-  },
-  "audio/amr-wb": {
-    "source": "iana"
-  },
-  "audio/amr-wb+": {
-    "source": "iana"
-  },
-  "audio/aptx": {
-    "source": "iana"
-  },
-  "audio/asc": {
-    "source": "iana"
-  },
-  "audio/atrac-advanced-lossless": {
-    "source": "iana"
-  },
-  "audio/atrac-x": {
-    "source": "iana"
-  },
-  "audio/atrac3": {
-    "source": "iana"
-  },
-  "audio/basic": {
-    "source": "iana",
-    "compressible": false,
-    "extensions": ["au","snd"]
-  },
-  "audio/bv16": {
-    "source": "iana"
-  },
-  "audio/bv32": {
-    "source": "iana"
-  },
-  "audio/clearmode": {
-    "source": "iana"
-  },
-  "audio/cn": {
-    "source": "iana"
-  },
-  "audio/dat12": {
-    "source": "iana"
-  },
-  "audio/dls": {
-    "source": "iana"
-  },
-  "audio/dsr-es201108": {
-    "source": "iana"
-  },
-  "audio/dsr-es202050": {
-    "source": "iana"
-  },
-  "audio/dsr-es202211": {
-    "source": "iana"
-  },
-  "audio/dsr-es202212": {
-    "source": "iana"
-  },
-  "audio/dv": {
-    "source": "iana"
-  },
-  "audio/dvi4": {
-    "source": "iana"
-  },
-  "audio/eac3": {
-    "source": "iana"
-  },
-  "audio/encaprtp": {
-    "source": "iana"
-  },
-  "audio/evrc": {
-    "source": "iana"
-  },
-  "audio/evrc-qcp": {
-    "source": "iana"
-  },
-  "audio/evrc0": {
-    "source": "iana"
-  },
-  "audio/evrc1": {
-    "source": "iana"
-  },
-  "audio/evrcb": {
-    "source": "iana"
-  },
-  "audio/evrcb0": {
-    "source": "iana"
-  },
-  "audio/evrcb1": {
-    "source": "iana"
-  },
-  "audio/evrcnw": {
-    "source": "iana"
-  },
-  "audio/evrcnw0": {
-    "source": "iana"
-  },
-  "audio/evrcnw1": {
-    "source": "iana"
-  },
-  "audio/evrcwb": {
-    "source": "iana"
-  },
-  "audio/evrcwb0": {
-    "source": "iana"
-  },
-  "audio/evrcwb1": {
-    "source": "iana"
-  },
-  "audio/fwdred": {
-    "source": "iana"
-  },
-  "audio/g719": {
-    "source": "iana"
-  },
-  "audio/g722": {
-    "source": "iana"
-  },
-  "audio/g7221": {
-    "source": "iana"
-  },
-  "audio/g723": {
-    "source": "iana"
-  },
-  "audio/g726-16": {
-    "source": "iana"
-  },
-  "audio/g726-24": {
-    "source": "iana"
-  },
-  "audio/g726-32": {
-    "source": "iana"
-  },
-  "audio/g726-40": {
-    "source": "iana"
-  },
-  "audio/g728": {
-    "source": "iana"
-  },
-  "audio/g729": {
-    "source": "iana"
-  },
-  "audio/g7291": {
-    "source": "iana"
-  },
-  "audio/g729d": {
-    "source": "iana"
-  },
-  "audio/g729e": {
-    "source": "iana"
-  },
-  "audio/gsm": {
-    "source": "iana"
-  },
-  "audio/gsm-efr": {
-    "source": "iana"
-  },
-  "audio/gsm-hr-08": {
-    "source": "iana"
-  },
-  "audio/ilbc": {
-    "source": "iana"
-  },
-  "audio/ip-mr_v2.5": {
-    "source": "iana"
-  },
-  "audio/isac": {
-    "source": "apache"
-  },
-  "audio/l16": {
-    "source": "iana"
-  },
-  "audio/l20": {
-    "source": "iana"
-  },
-  "audio/l24": {
-    "source": "iana",
-    "compressible": false
-  },
-  "audio/l8": {
-    "source": "iana"
-  },
-  "audio/lpc": {
-    "source": "iana"
-  },
-  "audio/midi": {
-    "source": "apache",
-    "extensions": ["mid","midi","kar","rmi"]
-  },
-  "audio/mobile-xmf": {
-    "source": "iana"
-  },
-  "audio/mp4": {
-    "source": "iana",
-    "compressible": false,
-    "extensions": ["mp4a","m4a"]
-  },
-  "audio/mp4a-latm": {
-    "source": "iana"
-  },
-  "audio/mpa": {
-    "source": "iana"
-  },
-  "audio/mpa-robust": {
-    "source": "iana"
-  },
-  "audio/mpeg": {
-    "source": "iana",
-    "compressible": false,
-    "extensions": ["mpga","mp2","mp2a","mp3","m2a","m3a"]
-  },
-  "audio/mpeg4-generic": {
-    "source": "iana"
-  },
-  "audio/musepack": {
-    "source": "apache"
-  },
-  "audio/ogg": {
-    "source": "iana",
-    "compressible": false,
-    "extensions": ["oga","ogg","spx"]
-  },
-  "audio/opus": {
-    "source": "iana"
-  },
-  "audio/parityfec": {
-    "source": "iana"
-  },
-  "audio/pcma": {
-    "source": "iana"
-  },
-  "audio/pcma-wb": {
-    "source": "iana"
-  },
-  "audio/pcmu": {
-    "source": "iana"
-  },
-  "audio/pcmu-wb": {
-    "source": "iana"
-  },
-  "audio/prs.sid": {
-    "source": "iana"
-  },
-  "audio/qcelp": {
-    "source": "iana"
-  },
-  "audio/raptorfec": {
-    "source": "iana"
-  },
-  "audio/red": {
-    "source": "iana"
-  },
-  "audio/rtp-enc-aescm128": {
-    "source": "iana"
-  },
-  "audio/rtp-midi": {
-    "source": "iana"
-  },
-  "audio/rtploopback": {
-    "source": "iana"
-  },
-  "audio/rtx": {
-    "source": "iana"
-  },
-  "audio/s3m": {
-    "source": "apache",
-    "extensions": ["s3m"]
-  },
-  "audio/silk": {
-    "source": "apache",
-    "extensions": ["sil"]
-  },
-  "audio/smv": {
-    "source": "iana"
-  },
-  "audio/smv-qcp": {
-    "source": "iana"
-  },
-  "audio/smv0": {
-    "source": "iana"
-  },
-  "audio/sp-midi": {
-    "source": "iana"
-  },
-  "audio/speex": {
-    "source": "iana"
-  },
-  "audio/t140c": {
-    "source": "iana"
-  },
-  "audio/t38": {
-    "source": "iana"
-  },
-  "audio/telephone-event": {
-    "source": "iana"
-  },
-  "audio/tone": {
-    "source": "iana"
-  },
-  "audio/uemclip": {
-    "source": "iana"
-  },
-  "audio/ulpfec": {
-    "source": "iana"
-  },
-  "audio/vdvi": {
-    "source": "iana"
-  },
-  "audio/vmr-wb": {
-    "source": "iana"
-  },
-  "audio/vnd.3gpp.iufp": {
-    "source": "iana"
-  },
-  "audio/vnd.4sb": {
-    "source": "iana"
-  },
-  "audio/vnd.audiokoz": {
-    "source": "iana"
-  },
-  "audio/vnd.celp": {
-    "source": "iana"
-  },
-  "audio/vnd.cisco.nse": {
-    "source": "iana"
-  },
-  "audio/vnd.cmles.radio-events": {
-    "source": "iana"
-  },
-  "audio/vnd.cns.anp1": {
-    "source": "iana"
-  },
-  "audio/vnd.cns.inf1": {
-    "source": "iana"
-  },
-  "audio/vnd.dece.audio": {
-    "source": "iana",
-    "extensions": ["uva","uvva"]
-  },
-  "audio/vnd.digital-winds": {
-    "source": "iana",
-    "extensions": ["eol"]
-  },
-  "audio/vnd.dlna.adts": {
-    "source": "iana"
-  },
-  "audio/vnd.dolby.heaac.1": {
-    "source": "iana"
-  },
-  "audio/vnd.dolby.heaac.2": {
-    "source": "iana"
-  },
-  "audio/vnd.dolby.mlp": {
-    "source": "iana"
-  },
-  "audio/vnd.dolby.mps": {
-    "source": "iana"
-  },
-  "audio/vnd.dolby.pl2": {
-    "source": "iana"
-  },
-  "audio/vnd.dolby.pl2x": {
-    "source": "iana"
-  },
-  "audio/vnd.dolby.pl2z": {
-    "source": "iana"
-  },
-  "audio/vnd.dolby.pulse.1": {
-    "source": "iana"
-  },
-  "audio/vnd.dra": {
-    "source": "iana",
-    "extensions": ["dra"]
-  },
-  "audio/vnd.dts": {
-    "source": "iana",
-    "extensions": ["dts"]
-  },
-  "audio/vnd.dts.hd": {
-    "source": "iana",
-    "extensions": ["dtshd"]
-  },
-  "audio/vnd.dvb.file": {
-    "source": "iana"
-  },
-  "audio/vnd.everad.plj": {
-    "source": "iana"
-  },
-  "audio/vnd.hns.audio": {
-    "source": "iana"
-  },
-  "audio/vnd.lucent.voice": {
-    "source": "iana",
-    "extensions": ["lvp"]
-  },
-  "audio/vnd.ms-playready.media.pya": {
-    "source": "iana",
-    "extensions": ["pya"]
-  },
-  "audio/vnd.nokia.mobile-xmf": {
-    "source": "iana"
-  },
-  "audio/vnd.nortel.vbk": {
-    "source": "iana"
-  },
-  "audio/vnd.nuera.ecelp4800": {
-    "source": "iana",
-    "extensions": ["ecelp4800"]
-  },
-  "audio/vnd.nuera.ecelp7470": {
-    "source": "iana",
-    "extensions": ["ecelp7470"]
-  },
-  "audio/vnd.nuera.ecelp9600": {
-    "source": "iana",
-    "extensions": ["ecelp9600"]
-  },
-  "audio/vnd.octel.sbc": {
-    "source": "iana"
-  },
-  "audio/vnd.qcelp": {
-    "source": "iana"
-  },
-  "audio/vnd.rhetorex.32kadpcm": {
-    "source": "iana"
-  },
-  "audio/vnd.rip": {
-    "source": "iana",
-    "extensions": ["rip"]
-  },
-  "audio/vnd.rn-realaudio": {
-    "compressible": false
-  },
-  "audio/vnd.sealedmedia.softseal.mpeg": {
-    "source": "iana"
-  },
-  "audio/vnd.vmx.cvsd": {
-    "source": "iana"
-  },
-  "audio/vnd.wave": {
-    "compressible": false
-  },
-  "audio/vorbis": {
-    "source": "iana",
-    "compressible": false
-  },
-  "audio/vorbis-config": {
-    "source": "iana"
-  },
-  "audio/wav": {
-    "compressible": false,
-    "extensions": ["wav"]
-  },
-  "audio/wave": {
-    "compressible": false,
-    "extensions": ["wav"]
-  },
-  "audio/webm": {
-    "source": "apache",
-    "compressible": false,
-    "extensions": ["weba"]
-  },
-  "audio/x-aac": {
-    "source": "apache",
-    "compressible": false,
-    "extensions": ["aac"]
-  },
-  "audio/x-aiff": {
-    "source": "apache",
-    "extensions": ["aif","aiff","aifc"]
-  },
-  "audio/x-caf": {
-    "source": "apache",
-    "compressible": false,
-    "extensions": ["caf"]
-  },
-  "audio/x-flac": {
-    "source": "apache",
-    "extensions": ["flac"]
-  },
-  "audio/x-m4a": {
-    "source": "nginx",
-    "extensions": ["m4a"]
-  },
-  "audio/x-matroska": {
-    "source": "apache",
-    "extensions": ["mka"]
-  },
-  "audio/x-mpegurl": {
-    "source": "apache",
-    "extensions": ["m3u"]
-  },
-  "audio/x-ms-wax": {
-    "source": "apache",
-    "extensions": ["wax"]
-  },
-  "audio/x-ms-wma": {
-    "source": "apache",
-    "extensions": ["wma"]
-  },
-  "audio/x-pn-realaudio": {
-    "source": "apache",
-    "extensions": ["ram","ra"]
-  },
-  "audio/x-pn-realaudio-plugin": {
-    "source": "apache",
-    "extensions": ["rmp"]
-  },
-  "audio/x-realaudio": {
-    "source": "nginx",
-    "extensions": ["ra"]
-  },
-  "audio/x-tta": {
-    "source": "apache"
-  },
-  "audio/x-wav": {
-    "source": "apache",
-    "extensions": ["wav"]
-  },
-  "audio/xm": {
-    "source": "apache",
-    "extensions": ["xm"]
-  },
-  "chemical/x-cdx": {
-    "source": "apache",
-    "extensions": ["cdx"]
-  },
-  "chemical/x-cif": {
-    "source": "apache",
-    "extensions": ["cif"]
-  },
-  "chemical/x-cmdf": {
-    "source": "apache",
-    "extensions": ["cmdf"]
-  },
-  "chemical/x-cml": {
-    "source": "apache",
-    "extensions": ["cml"]
-  },
-  "chemical/x-csml": {
-    "source": "apache",
-    "extensions": ["csml"]
-  },
-  "chemical/x-pdb": {
-    "source": "apache"
-  },
-  "chemical/x-xyz": {
-    "source": "apache",
-    "extensions": ["xyz"]
-  },
-  "font/opentype": {
-    "compressible": true,
-    "extensions": ["otf"]
-  },
-  "image/bmp": {
-    "source": "apache",
-    "compressible": true,
-    "extensions": ["bmp"]
-  },
-  "image/cgm": {
-    "source": "iana",
-    "extensions": ["cgm"]
-  },
-  "image/fits": {
-    "source": "iana"
-  },
-  "image/g3fax": {
-    "source": "iana",
-    "extensions": ["g3"]
-  },
-  "image/gif": {
-    "source": "iana",
-    "compressible": false,
-    "extensions": ["gif"]
-  },
-  "image/ief": {
-    "source": "iana",
-    "extensions": ["ief"]
-  },
-  "image/jp2": {
-    "source": "iana"
-  },
-  "image/jpeg": {
-    "source": "iana",
-    "compressible": false,
-    "extensions": ["jpeg","jpg","jpe"]
-  },
-  "image/jpm": {
-    "source": "iana"
-  },
-  "image/jpx": {
-    "source": "iana"
-  },
-  "image/ktx": {
-    "source": "iana",
-    "extensions": ["ktx"]
-  },
-  "image/naplps": {
-    "source": "iana"
-  },
-  "image/pjpeg": {
-    "compressible": false
-  },
-  "image/png": {
-    "source": "iana",
-    "compressible": false,
-    "extensions": ["png"]
-  },
-  "image/prs.btif": {
-    "source": "iana",
-    "extensions": ["btif"]
-  },
-  "image/prs.pti": {
-    "source": "iana"
-  },
-  "image/pwg-raster": {
-    "source": "iana"
-  },
-  "image/sgi": {
-    "source": "apache",
-    "extensions": ["sgi"]
-  },
-  "image/svg+xml": {
-    "source": "iana",
-    "compressible": true,
-    "extensions": ["svg","svgz"]
-  },
-  "image/t38": {
-    "source": "iana"
-  },
-  "image/tiff": {
-    "source": "iana",
-    "compressible": false,
-    "extensions": ["tiff","tif"]
-  },
-  "image/tiff-fx": {
-    "source": "iana"
-  },
-  "image/vnd.adobe.photoshop": {
-    "source": "iana",
-    "compressible": true,
-    "extensions": ["psd"]
-  },
-  "image/vnd.airzip.accelerator.azv": {
-    "source": "iana"
-  },
-  "image/vnd.cns.inf2": {
-    "source": "iana"
-  },
-  "image/vnd.dece.graphic": {
-    "source": "iana",
-    "extensions": ["uvi","uvvi","uvg","uvvg"]
-  },
-  "image/vnd.djvu": {
-    "source": "iana",
-    "extensions": ["djvu","djv"]
-  },
-  "image/vnd.dvb.subtitle": {
-    "source": "iana",
-    "extensions": ["sub"]
-  },
-  "image/vnd.dwg": {
-    "source": "iana",
-    "extensions": ["dwg"]
-  },
-  "image/vnd.dxf": {
-    "source": "iana",
-    "extensions": ["dxf"]
-  },
-  "image/vnd.fastbidsheet": {
-    "source": "iana",
-    "extensions": ["fbs"]
-  },
-  "image/vnd.fpx": {
-    "source": "iana",
-    "extensions": ["fpx"]
-  },
-  "image/vnd.fst": {
-    "source": "iana",
-    "extensions": ["fst"]
-  },
-  "image/vnd.fujixerox.edmics-mmr": {
-    "source": "iana",
-    "extensions": ["mmr"]
-  },
-  "image/vnd.fujixerox.edmics-rlc": {
-    "source": "iana",
-    "extensions": ["rlc"]
-  },
-  "image/vnd.globalgraphics.pgb": {
-    "source": "iana"
-  },
-  "image/vnd.microsoft.icon": {
-    "source": "iana"
-  },
-  "image/vnd.mix": {
-    "source": "iana"
-  },
-  "image/vnd.ms-modi": {
-    "source": "iana",
-    "extensions": ["mdi"]
-  },
-  "image/vnd.ms-photo": {
-    "source": "apache",
-    "extensions": ["wdp"]
-  },
-  "image/vnd.net-fpx": {
-    "source": "iana",
-    "extensions": ["npx"]
-  },
-  "image/vnd.radiance": {
-    "source": "iana"
-  },
-  "image/vnd.sealed.png": {
-    "source": "iana"
-  },
-  "image/vnd.sealedmedia.softseal.gif": {
-    "source": "iana"
-  },
-  "image/vnd.sealedmedia.softseal.jpg": {
-    "source": "iana"
-  },
-  "image/vnd.svf": {
-    "source": "iana"
-  },
-  "image/vnd.tencent.tap": {
-    "source": "iana"
-  },
-  "image/vnd.valve.source.texture": {
-    "source": "iana"
-  },
-  "image/vnd.wap.wbmp": {
-    "source": "iana",
-    "extensions": ["wbmp"]
-  },
-  "image/vnd.xiff": {
-    "source": "iana",
-    "extensions": ["xif"]
-  },
-  "image/vnd.zbrush.pcx": {
-    "source": "iana"
-  },
-  "image/webp": {
-    "source": "apache",
-    "extensions": ["webp"]
-  },
-  "image/x-3ds": {
-    "source": "apache",
-    "extensions": ["3ds"]
-  },
-  "image/x-cmu-raster": {
-    "source": "apache",
-    "extensions": ["ras"]
-  },
-  "image/x-cmx": {
-    "source": "apache",
-    "extensions": ["cmx"]
-  },
-  "image/x-freehand": {
-    "source": "apache",
-    "extensions": ["fh","fhc","fh4","fh5","fh7"]
-  },
-  "image/x-icon": {
-    "source": "apache",
-    "compressible": true,
-    "extensions": ["ico"]
-  },
-  "image/x-jng": {
-    "source": "nginx",
-    "extensions": ["jng"]
-  },
-  "image/x-mrsid-image": {
-    "source": "apache",
-    "extensions": ["sid"]
-  },
-  "image/x-ms-bmp": {
-    "source": "nginx",
-    "compressible": true,
-    "extensions": ["bmp"]
-  },
-  "image/x-pcx": {
-    "source": "apache",
-    "extensions": ["pcx"]
-  },
-  "image/x-pict": {
-    "source": "apache",
-    "extensions": ["pic","pct"]
-  },
-  "image/x-portable-anymap": {
-    "source": "apache",
-    "extensions": ["pnm"]
-  },
-  "image/x-portable-bitmap": {
-    "source": "apache",
-    "extensions": ["pbm"]
-  },
-  "image/x-portable-graymap": {
-    "source": "apache",
-    "extensions": ["pgm"]
-  },
-  "image/x-portable-pixmap": {
-    "source": "apache",
-    "extensions": ["ppm"]
-  },
-  "image/x-rgb": {
-    "source": "apache",
-    "extensions": ["rgb"]
-  },
-  "image/x-tga": {
-    "source": "apache",
-    "extensions": ["tga"]
-  },
-  "image/x-xbitmap": {
-    "source": "apache",
-    "extensions": ["xbm"]
-  },
-  "image/x-xcf": {
-    "compressible": false
-  },
-  "image/x-xpixmap": {
-    "source": "apache",
-    "extensions": ["xpm"]
-  },
-  "image/x-xwindowdump": {
-    "source": "apache",
-    "extensions": ["xwd"]
-  },
-  "message/cpim": {
-    "source": "iana"
-  },
-  "message/delivery-status": {
-    "source": "iana"
-  },
-  "message/disposition-notification": {
-    "source": "iana"
-  },
-  "message/external-body": {
-    "source": "iana"
-  },
-  "message/feedback-report": {
-    "source": "iana"
-  },
-  "message/global": {
-    "source": "iana"
-  },
-  "message/global-delivery-status": {
-    "source": "iana"
-  },
-  "message/global-disposition-notification": {
-    "source": "iana"
-  },
-  "message/global-headers": {
-    "source": "iana"
-  },
-  "message/http": {
-    "source": "iana",
-    "compressible": false
-  },
-  "message/imdn+xml": {
-    "source": "iana",
-    "compressible": true
-  },
-  "message/news": {
-    "source": "iana"
-  },
-  "message/partial": {
-    "source": "iana",
-    "compressible": false
-  },
-  "message/rfc822": {
-    "source": "iana",
-    "compressible": true,
-    "extensions": ["eml","mime"]
-  },
-  "message/s-http": {
-    "source": "iana"
-  },
-  "message/sip": {
-    "source": "iana"
-  },
-  "message/sipfrag": {
-    "source": "iana"
-  },
-  "message/tracking-status": {
-    "source": "iana"
-  },
-  "message/vnd.si.simp": {
-    "source": "iana"
-  },
-  "message/vnd.wfa.wsc": {
-    "source": "iana"
-  },
-  "model/iges": {
-    "source": "iana",
-    "compressible": false,
-    "extensions": ["igs","iges"]
-  },
-  "model/mesh": {
-    "source": "iana",
-    "compressible": false,
-    "extensions": ["msh","mesh","silo"]
-  },
-  "model/vnd.collada+xml": {
-    "source": "iana",
-    "extensions": ["dae"]
-  },
-  "model/vnd.dwf": {
-    "source": "iana",
-    "extensions": ["dwf"]
-  },
-  "model/vnd.flatland.3dml": {
-    "source": "iana"
-  },
-  "model/vnd.gdl": {
-    "source": "iana",
-    "extensions": ["gdl"]
-  },
-  "model/vnd.gs-gdl": {
-    "source": "apache"
-  },
-  "model/vnd.gs.gdl": {
-    "source": "iana"
-  },
-  "model/vnd.gtw": {
-    "source": "iana",
-    "extensions": ["gtw"]
-  },
-  "model/vnd.moml+xml": {
-    "source": "iana"
-  },
-  "model/vnd.mts": {
-    "source": "iana",
-    "extensions": ["mts"]
-  },
-  "model/vnd.opengex": {
-    "source": "iana"
-  },
-  "model/vnd.parasolid.transmit.binary": {
-    "source": "iana"
-  },
-  "model/vnd.parasolid.transmit.text": {
-    "source": "iana"
-  },
-  "model/vnd.valve.source.compiled-map": {
-    "source": "iana"
-  },
-  "model/vnd.vtu": {
-    "source": "iana",
-    "extensions": ["vtu"]
-  },
-  "model/vrml": {
-    "source": "iana",
-    "compressible": false,
-    "extensions": ["wrl","vrml"]
-  },
-  "model/x3d+binary": {
-    "source": "apache",
-    "compressible": false,
-    "extensions": ["x3db","x3dbz"]
-  },
-  "model/x3d+fastinfoset": {
-    "source": "iana"
-  },
-  "model/x3d+vrml": {
-    "source": "apache",
-    "compressible": false,
-    "extensions": ["x3dv","x3dvz"]
-  },
-  "model/x3d+xml": {
-    "source": "iana",
-    "compressible": true,
-    "extensions": ["x3d","x3dz"]
-  },
-  "model/x3d-vrml": {
-    "source": "iana"
-  },
-  "multipart/alternative": {
-    "source": "iana",
-    "compressible": false
-  },
-  "multipart/appledouble": {
-    "source": "iana"
-  },
-  "multipart/byteranges": {
-    "source": "iana"
-  },
-  "multipart/digest": {
-    "source": "iana"
-  },
-  "multipart/encrypted": {
-    "source": "iana",
-    "compressible": false
-  },
-  "multipart/form-data": {
-    "source": "iana",
-    "compressible": false
-  },
-  "multipart/header-set": {
-    "source": "iana"
-  },
-  "multipart/mixed": {
-    "source": "iana",
-    "compressible": false
-  },
-  "multipart/parallel": {
-    "source": "iana"
-  },
-  "multipart/related": {
-    "source": "iana",
-    "compressible": false
-  },
-  "multipart/report": {
-    "source": "iana"
-  },
-  "multipart/signed": {
-    "source": "iana",
-    "compressible": false
-  },
-  "multipart/voice-message": {
-    "source": "iana"
-  },
-  "multipart/x-mixed-replace": {
-    "source": "iana"
-  },
-  "text/1d-interleaved-parityfec": {
-    "source": "iana"
-  },
-  "text/cache-manifest": {
-    "source": "iana",
-    "compressible": true,
-    "extensions": ["appcache","manifest"]
-  },
-  "text/calendar": {
-    "source": "iana",
-    "extensions": ["ics","ifb"]
-  },
-  "text/calender": {
-    "compressible": true
-  },
-  "text/cmd": {
-    "compressible": true
-  },
-  "text/coffeescript": {
-    "extensions": ["coffee","litcoffee"]
-  },
-  "text/css": {
-    "source": "iana",
-    "compressible": true,
-    "extensions": ["css"]
-  },
-  "text/csv": {
-    "source": "iana",
-    "compressible": true,
-    "extensions": ["csv"]
-  },
-  "text/csv-schema": {
-    "source": "iana"
-  },
-  "text/directory": {
-    "source": "iana"
-  },
-  "text/dns": {
-    "source": "iana"
-  },
-  "text/ecmascript": {
-    "source": "iana"
-  },
-  "text/encaprtp": {
-    "source": "iana"
-  },
-  "text/enriched": {
-    "source": "iana"
-  },
-  "text/fwdred": {
-    "source": "iana"
-  },
-  "text/grammar-ref-list": {
-    "source": "iana"
-  },
-  "text/hjson": {
-    "extensions": ["hjson"]
-  },
-  "text/html": {
-    "source": "iana",
-    "compressible": true,
-    "extensions": ["html","htm","shtml"]
-  },
-  "text/jade": {
-    "extensions": ["jade"]
-  },
-  "text/javascript": {
-    "source": "iana",
-    "compressible": true
-  },
-  "text/jcr-cnd": {
-    "source": "iana"
-  },
-  "text/jsx": {
-    "compressible": true,
-    "extensions": ["jsx"]
-  },
-  "text/less": {
-    "extensions": ["less"]
-  },
-  "text/markdown": {
-    "source": "iana"
-  },
-  "text/mathml": {
-    "source": "nginx",
-    "extensions": ["mml"]
-  },
-  "text/mizar": {
-    "source": "iana"
-  },
-  "text/n3": {
-    "source": "iana",
-    "compressible": true,
-    "extensions": ["n3"]
-  },
-  "text/parameters": {
-    "source": "iana"
-  },
-  "text/parityfec": {
-    "source": "iana"
-  },
-  "text/plain": {
-    "source": "iana",
-    "compressible": true,
-    "extensions": ["txt","text","conf","def","list","log","in","ini"]
-  },
-  "text/provenance-notation": {
-    "source": "iana"
-  },
-  "text/prs.fallenstein.rst": {
-    "source": "iana"
-  },
-  "text/prs.lines.tag": {
-    "source": "iana",
-    "extensions": ["dsc"]
-  },
-  "text/raptorfec": {
-    "source": "iana"
-  },
-  "text/red": {
-    "source": "iana"
-  },
-  "text/rfc822-headers": {
-    "source": "iana"
-  },
-  "text/richtext": {
-    "source": "iana",
-    "compressible": true,
-    "extensions": ["rtx"]
-  },
-  "text/rtf": {
-    "source": "iana",
-    "compressible": true,
-    "extensions": ["rtf"]
-  },
-  "text/rtp-enc-aescm128": {
-    "source": "iana"
-  },
-  "text/rtploopback": {
-    "source": "iana"
-  },
-  "text/rtx": {
-    "source": "iana"
-  },
-  "text/sgml": {
-    "source": "iana",
-    "extensions": ["sgml","sgm"]
-  },
-  "text/stylus": {
-    "extensions": ["stylus","styl"]
-  },
-  "text/t140": {
-    "source": "iana"
-  },
-  "text/tab-separated-values": {
-    "source": "iana",
-    "compressible": true,
-    "extensions": ["tsv"]
-  },
-  "text/troff": {
-    "source": "iana",
-    "extensions": ["t","tr","roff","man","me","ms"]
-  },
-  "text/turtle": {
-    "source": "iana",
-    "extensions": ["ttl"]
-  },
-  "text/ulpfec": {
-    "source": "iana"
-  },
-  "text/uri-list": {
-    "source": "iana",
-    "compressible": true,
-    "extensions": ["uri","uris","urls"]
-  },
-  "text/vcard": {
-    "source": "iana",
-    "compressible": true,
-    "extensions": ["vcard"]
-  },
-  "text/vnd.a": {
-    "source": "iana"
-  },
-  "text/vnd.abc": {
-    "source": "iana"
-  },
-  "text/vnd.curl": {
-    "source": "iana",
-    "extensions": ["curl"]
-  },
-  "text/vnd.curl.dcurl": {
-    "source": "apache",
-    "extensions": ["dcurl"]
-  },
-  "text/vnd.curl.mcurl": {
-    "source": "apache",
-    "extensions": ["mcurl"]
-  },
-  "text/vnd.curl.scurl": {
-    "source": "apache",
-    "extensions": ["scurl"]
-  },
-  "text/vnd.debian.copyright": {
-    "source": "iana"
-  },
-  "text/vnd.dmclientscript": {
-    "source": "iana"
-  },
-  "text/vnd.dvb.subtitle": {
-    "source": "iana",
-    "extensions": ["sub"]
-  },
-  "text/vnd.esmertec.theme-descriptor": {
-    "source": "iana"
-  },
-  "text/vnd.fly": {
-    "source": "iana",
-    "extensions": ["fly"]
-  },
-  "text/vnd.fmi.flexstor": {
-    "source": "iana",
-    "extensions": ["flx"]
-  },
-  "text/vnd.graphviz": {
-    "source": "iana",
-    "extensions": ["gv"]
-  },
-  "text/vnd.in3d.3dml": {
-    "source": "iana",
-    "extensions": ["3dml"]
-  },
-  "text/vnd.in3d.spot": {
-    "source": "iana",
-    "extensions": ["spot"]
-  },
-  "text/vnd.iptc.newsml": {
-    "source": "iana"
-  },
-  "text/vnd.iptc.nitf": {
-    "source": "iana"
-  },
-  "text/vnd.latex-z": {
-    "source": "iana"
-  },
-  "text/vnd.motorola.reflex": {
-    "source": "iana"
-  },
-  "text/vnd.ms-mediapackage": {
-    "source": "iana"
-  },
-  "text/vnd.net2phone.commcenter.command": {
-    "source": "iana"
-  },
-  "text/vnd.radisys.msml-basic-layout": {
-    "source": "iana"
-  },
-  "text/vnd.si.uricatalogue": {
-    "source": "iana"
-  },
-  "text/vnd.sun.j2me.app-descriptor": {
-    "source": "iana",
-    "extensions": ["jad"]
-  },
-  "text/vnd.trolltech.linguist": {
-    "source": "iana"
-  },
-  "text/vnd.wap.si": {
-    "source": "iana"
-  },
-  "text/vnd.wap.sl": {
-    "source": "iana"
-  },
-  "text/vnd.wap.wml": {
-    "source": "iana",
-    "extensions": ["wml"]
-  },
-  "text/vnd.wap.wmlscript": {
-    "source": "iana",
-    "extensions": ["wmls"]
-  },
-  "text/vtt": {
-    "charset": "UTF-8",
-    "compressible": true,
-    "extensions": ["vtt"]
-  },
-  "text/x-asm": {
-    "source": "apache",
-    "extensions": ["s","asm"]
-  },
-  "text/x-c": {
-    "source": "apache",
-    "extensions": ["c","cc","cxx","cpp","h","hh","dic"]
-  },
-  "text/x-component": {
-    "source": "nginx",
-    "extensions": ["htc"]
-  },
-  "text/x-fortran": {
-    "source": "apache",
-    "extensions": ["f","for","f77","f90"]
-  },
-  "text/x-gwt-rpc": {
-    "compressible": true
-  },
-  "text/x-handlebars-template": {
-    "extensions": ["hbs"]
-  },
-  "text/x-java-source": {
-    "source": "apache",
-    "extensions": ["java"]
-  },
-  "text/x-jquery-tmpl": {
-    "compressible": true
-  },
-  "text/x-lua": {
-    "extensions": ["lua"]
-  },
-  "text/x-markdown": {
-    "compressible": true,
-    "extensions": ["markdown","md","mkd"]
-  },
-  "text/x-nfo": {
-    "source": "apache",
-    "extensions": ["nfo"]
-  },
-  "text/x-opml": {
-    "source": "apache",
-    "extensions": ["opml"]
-  },
-  "text/x-pascal": {
-    "source": "apache",
-    "extensions": ["p","pas"]
-  },
-  "text/x-processing": {
-    "compressible": true,
-    "extensions": ["pde"]
-  },
-  "text/x-sass": {
-    "extensions": ["sass"]
-  },
-  "text/x-scss": {
-    "extensions": ["scss"]
-  },
-  "text/x-setext": {
-    "source": "apache",
-    "extensions": ["etx"]
-  },
-  "text/x-sfv": {
-    "source": "apache",
-    "extensions": ["sfv"]
-  },
-  "text/x-uuencode": {
-    "source": "apache",
-    "extensions": ["uu"]
-  },
-  "text/x-vcalendar": {
-    "source": "apache",
-    "extensions": ["vcs"]
-  },
-  "text/x-vcard": {
-    "source": "apache",
-    "extensions": ["vcf"]
-  },
-  "text/xml": {
-    "source": "iana",
-    "compressible": true,
-    "extensions": ["xml"]
-  },
-  "text/xml-external-parsed-entity": {
-    "source": "iana"
-  },
-  "text/yaml": {
-    "extensions": ["yaml","yml"]
-  },
-  "video/1d-interleaved-parityfec": {
-    "source": "apache"
-  },
-  "video/3gpp": {
-    "source": "apache",
-    "extensions": ["3gp","3gpp"]
-  },
-  "video/3gpp-tt": {
-    "source": "apache"
-  },
-  "video/3gpp2": {
-    "source": "apache",
-    "extensions": ["3g2"]
-  },
-  "video/bmpeg": {
-    "source": "apache"
-  },
-  "video/bt656": {
-    "source": "apache"
-  },
-  "video/celb": {
-    "source": "apache"
-  },
-  "video/dv": {
-    "source": "apache"
-  },
-  "video/h261": {
-    "source": "apache",
-    "extensions": ["h261"]
-  },
-  "video/h263": {
-    "source": "apache",
-    "extensions": ["h263"]
-  },
-  "video/h263-1998": {
-    "source": "apache"
-  },
-  "video/h263-2000": {
-    "source": "apache"
-  },
-  "video/h264": {
-    "source": "apache",
-    "extensions": ["h264"]
-  },
-  "video/h264-rcdo": {
-    "source": "apache"
-  },
-  "video/h264-svc": {
-    "source": "apache"
-  },
-  "video/jpeg": {
-    "source": "apache",
-    "extensions": ["jpgv"]
-  },
-  "video/jpeg2000": {
-    "source": "apache"
-  },
-  "video/jpm": {
-    "source": "apache",
-    "extensions": ["jpm","jpgm"]
-  },
-  "video/mj2": {
-    "source": "apache",
-    "extensions": ["mj2","mjp2"]
-  },
-  "video/mp1s": {
-    "source": "apache"
-  },
-  "video/mp2p": {
-    "source": "apache"
-  },
-  "video/mp2t": {
-    "source": "apache",
-    "extensions": ["ts"]
-  },
-  "video/mp4": {
-    "source": "apache",
-    "compressible": false,
-    "extensions": ["mp4","mp4v","mpg4"]
-  },
-  "video/mp4v-es": {
-    "source": "apache"
-  },
-  "video/mpeg": {
-    "source": "apache",
-    "compressible": false,
-    "extensions": ["mpeg","mpg","mpe","m1v","m2v"]
-  },
-  "video/mpeg4-generic": {
-    "source": "apache"
-  },
-  "video/mpv": {
-    "source": "apache"
-  },
-  "video/nv": {
-    "source": "apache"
-  },
-  "video/ogg": {
-    "source": "apache",
-    "compressible": false,
-    "extensions": ["ogv"]
-  },
-  "video/parityfec": {
-    "source": "apache"
-  },
-  "video/pointer": {
-    "source": "apache"
-  },
-  "video/quicktime": {
-    "source": "apache",
-    "compressible": false,
-    "extensions": ["qt","mov"]
-  },
-  "video/raw": {
-    "source": "apache"
-  },
-  "video/rtp-enc-aescm128": {
-    "source": "apache"
-  },
-  "video/rtx": {
-    "source": "apache"
-  },
-  "video/smpte292m": {
-    "source": "apache"
-  },
-  "video/ulpfec": {
-    "source": "apache"
-  },
-  "video/vc1": {
-    "source": "apache"
-  },
-  "video/vnd.cctv": {
-    "source": "apache"
-  },
-  "video/vnd.dece.hd": {
-    "source": "apache",
-    "extensions": ["uvh","uvvh"]
-  },
-  "video/vnd.dece.mobile": {
-    "source": "apache",
-    "extensions": ["uvm","uvvm"]
-  },
-  "video/vnd.dece.mp4": {
-    "source": "apache"
-  },
-  "video/vnd.dece.pd": {
-    "source": "apache",
-    "extensions": ["uvp","uvvp"]
-  },
-  "video/vnd.dece.sd": {
-    "source": "apache",
-    "extensions": ["uvs","uvvs"]
-  },
-  "video/vnd.dece.video": {
-    "source": "apache",
-    "extensions": ["uvv","uvvv"]
-  },
-  "video/vnd.directv.mpeg": {
-    "source": "apache"
-  },
-  "video/vnd.directv.mpeg-tts": {
-    "source": "apache"
-  },
-  "video/vnd.dlna.mpeg-tts": {
-    "source": "apache"
-  },
-  "video/vnd.dvb.file": {
-    "source": "apache",
-    "extensions": ["dvb"]
-  },
-  "video/vnd.fvt": {
-    "source": "apache",
-    "extensions": ["fvt"]
-  },
-  "video/vnd.hns.video": {
-    "source": "apache"
-  },
-  "video/vnd.iptvforum.1dparityfec-1010": {
-    "source": "apache"
-  },
-  "video/vnd.iptvforum.1dparityfec-2005": {
-    "source": "apache"
-  },
-  "video/vnd.iptvforum.2dparityfec-1010": {
-    "source": "apache"
-  },
-  "video/vnd.iptvforum.2dparityfec-2005": {
-    "source": "apache"
-  },
-  "video/vnd.iptvforum.ttsavc": {
-    "source": "apache"
-  },
-  "video/vnd.iptvforum.ttsmpeg2": {
-    "source": "apache"
-  },
-  "video/vnd.motorola.video": {
-    "source": "apache"
-  },
-  "video/vnd.motorola.videop": {
-    "source": "apache"
-  },
-  "video/vnd.mpegurl": {
-    "source": "apache",
-    "extensions": ["mxu","m4u"]
-  },
-  "video/vnd.ms-playready.media.pyv": {
-    "source": "apache",
-    "extensions": ["pyv"]
-  },
-  "video/vnd.nokia.interleaved-multimedia": {
-    "source": "apache"
-  },
-  "video/vnd.nokia.videovoip": {
-    "source": "apache"
-  },
-  "video/vnd.objectvideo": {
-    "source": "apache"
-  },
-  "video/vnd.sealed.mpeg1": {
-    "source": "apache"
-  },
-  "video/vnd.sealed.mpeg4": {
-    "source": "apache"
-  },
-  "video/vnd.sealed.swf": {
-    "source": "apache"
-  },
-  "video/vnd.sealedmedia.softseal.mov": {
-    "source": "apache"
-  },
-  "video/vnd.uvvu.mp4": {
-    "source": "apache",
-    "extensions": ["uvu","uvvu"]
-  },
-  "video/vnd.vivo": {
-    "source": "apache",
-    "extensions": ["viv"]
-  },
-  "video/webm": {
-    "source": "apache",
-    "compressible": false,
-    "extensions": ["webm"]
-  },
-  "video/x-f4v": {
-    "source": "apache",
-    "extensions": ["f4v"]
-  },
-  "video/x-fli": {
-    "source": "apache",
-    "extensions": ["fli"]
-  },
-  "video/x-flv": {
-    "source": "apache",
-    "compressible": false,
-    "extensions": ["flv"]
-  },
-  "video/x-m4v": {
-    "source": "apache",
-    "extensions": ["m4v"]
-  },
-  "video/x-matroska": {
-    "source": "apache",
-    "compressible": false,
-    "extensions": ["mkv","mk3d","mks"]
-  },
-  "video/x-mng": {
-    "source": "apache",
-    "extensions": ["mng"]
-  },
-  "video/x-ms-asf": {
-    "source": "apache",
-    "extensions": ["asf","asx"]
-  },
-  "video/x-ms-vob": {
-    "source": "apache",
-    "extensions": ["vob"]
-  },
-  "video/x-ms-wm": {
-    "source": "apache",
-    "extensions": ["wm"]
-  },
-  "video/x-ms-wmv": {
-    "source": "apache",
-    "compressible": false,
-    "extensions": ["wmv"]
-  },
-  "video/x-ms-wmx": {
-    "source": "apache",
-    "extensions": ["wmx"]
-  },
-  "video/x-ms-wvx": {
-    "source": "apache",
-    "extensions": ["wvx"]
-  },
-  "video/x-msvideo": {
-    "source": "apache",
-    "extensions": ["avi"]
-  },
-  "video/x-sgi-movie": {
-    "source": "apache",
-    "extensions": ["movie"]
-  },
-  "video/x-smv": {
-    "source": "apache",
-    "extensions": ["smv"]
-  },
-  "x-conference/x-cooltalk": {
-    "source": "apache",
-    "extensions": ["ice"]
-  },
-  "x-shader/x-fragment": {
-    "compressible": true
-  },
-  "x-shader/x-vertex": {
-    "compressible": true
-  }
-}
diff --git a/deps/npm/node_modules/request/node_modules/form-data/node_modules/mime-types/node_modules/mime-db/index.js b/deps/npm/node_modules/request/node_modules/form-data/node_modules/mime-types/node_modules/mime-db/index.js
deleted file mode 100644 (file)
index 551031f..0000000
+++ /dev/null
@@ -1,11 +0,0 @@
-/*!
- * mime-db
- * Copyright(c) 2014 Jonathan Ong
- * MIT Licensed
- */
-
-/**
- * Module exports.
- */
-
-module.exports = require('./db.json')
diff --git a/deps/npm/node_modules/request/node_modules/form-data/node_modules/mime-types/node_modules/mime-db/package.json b/deps/npm/node_modules/request/node_modules/form-data/node_modules/mime-types/node_modules/mime-db/package.json
deleted file mode 100644 (file)
index 9203164..0000000
+++ /dev/null
@@ -1,94 +0,0 @@
-{
-  "name": "mime-db",
-  "description": "Media Type Database",
-  "version": "1.14.0",
-  "contributors": [
-    {
-      "name": "Douglas Christopher Wilson",
-      "email": "doug@somethingdoug.com"
-    },
-    {
-      "name": "Jonathan Ong",
-      "email": "me@jongleberry.com",
-      "url": "http://jongleberry.com"
-    },
-    {
-      "name": "Robert Kieffer",
-      "email": "robert@broofa.com",
-      "url": "http://github.com/broofa"
-    }
-  ],
-  "license": "MIT",
-  "keywords": [
-    "mime",
-    "db",
-    "type",
-    "types",
-    "database",
-    "charset",
-    "charsets"
-  ],
-  "repository": {
-    "type": "git",
-    "url": "git+https://github.com/jshttp/mime-db.git"
-  },
-  "devDependencies": {
-    "bluebird": "2.9.30",
-    "co": "4.5.4",
-    "cogent": "1.0.1",
-    "csv-parse": "0.1.3",
-    "gnode": "0.1.1",
-    "istanbul": "0.3.16",
-    "mocha": "1.21.5",
-    "raw-body": "2.1.1",
-    "stream-to-array": "2"
-  },
-  "files": [
-    "HISTORY.md",
-    "LICENSE",
-    "README.md",
-    "db.json",
-    "index.js"
-  ],
-  "engines": {
-    "node": ">= 0.6"
-  },
-  "scripts": {
-    "build": "node scripts/build",
-    "fetch": "gnode scripts/fetch-apache && gnode scripts/fetch-iana && gnode scripts/fetch-nginx",
-    "test": "mocha --reporter spec --bail --check-leaks test/",
-    "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks test/",
-    "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks test/",
-    "update": "npm run fetch && npm run build"
-  },
-  "gitHead": "9803c407b6621daba9363f534cfab18255c945a8",
-  "bugs": {
-    "url": "https://github.com/jshttp/mime-db/issues"
-  },
-  "homepage": "https://github.com/jshttp/mime-db",
-  "_id": "mime-db@1.14.0",
-  "_shasum": "d561f10b6ee66db51f94ae657a2951a74217ed83",
-  "_from": "mime-db@>=1.14.0 <1.15.0",
-  "_npmVersion": "1.4.28",
-  "_npmUser": {
-    "name": "dougwilson",
-    "email": "doug@somethingdoug.com"
-  },
-  "maintainers": [
-    {
-      "name": "jongleberry",
-      "email": "jonathanrichardong@gmail.com"
-    },
-    {
-      "name": "dougwilson",
-      "email": "doug@somethingdoug.com"
-    }
-  ],
-  "dist": {
-    "shasum": "d561f10b6ee66db51f94ae657a2951a74217ed83",
-    "tarball": "http://registry.npmjs.org/mime-db/-/mime-db-1.14.0.tgz"
-  },
-  "directories": {},
-  "_resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.14.0.tgz",
-  "readme": "ERROR: No README data found!"
-}
diff --git a/deps/npm/node_modules/request/node_modules/form-data/node_modules/mime-types/package.json b/deps/npm/node_modules/request/node_modules/form-data/node_modules/mime-types/package.json
deleted file mode 100644 (file)
index 99ebf6f..0000000
+++ /dev/null
@@ -1,84 +0,0 @@
-{
-  "name": "mime-types",
-  "description": "The ultimate javascript content-type utility.",
-  "version": "2.1.2",
-  "contributors": [
-    {
-      "name": "Douglas Christopher Wilson",
-      "email": "doug@somethingdoug.com"
-    },
-    {
-      "name": "Jeremiah Senkpiel",
-      "email": "fishrock123@rocketmail.com",
-      "url": "https://searchbeam.jit.su"
-    },
-    {
-      "name": "Jonathan Ong",
-      "email": "me@jongleberry.com",
-      "url": "http://jongleberry.com"
-    }
-  ],
-  "license": "MIT",
-  "keywords": [
-    "mime",
-    "types"
-  ],
-  "repository": {
-    "type": "git",
-    "url": "git+https://github.com/jshttp/mime-types.git"
-  },
-  "dependencies": {
-    "mime-db": "~1.14.0"
-  },
-  "devDependencies": {
-    "istanbul": "0.3.16",
-    "mocha": "~1.21.5"
-  },
-  "files": [
-    "HISTORY.md",
-    "LICENSE",
-    "index.js"
-  ],
-  "engines": {
-    "node": ">= 0.6"
-  },
-  "scripts": {
-    "test": "mocha --reporter spec test/test.js",
-    "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot test/test.js",
-    "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter dot test/test.js"
-  },
-  "gitHead": "5704d7bb0cf90f14b442f0b954ace6c1dbc5f435",
-  "bugs": {
-    "url": "https://github.com/jshttp/mime-types/issues"
-  },
-  "homepage": "https://github.com/jshttp/mime-types",
-  "_id": "mime-types@2.1.2",
-  "_shasum": "6545ccd95afe77b9c655d81c2e6ceace36257227",
-  "_from": "mime-types@>=2.1.1 <3.0.0",
-  "_npmVersion": "1.4.28",
-  "_npmUser": {
-    "name": "dougwilson",
-    "email": "doug@somethingdoug.com"
-  },
-  "maintainers": [
-    {
-      "name": "jongleberry",
-      "email": "jonathanrichardong@gmail.com"
-    },
-    {
-      "name": "fishrock123",
-      "email": "fishrock123@rocketmail.com"
-    },
-    {
-      "name": "dougwilson",
-      "email": "doug@somethingdoug.com"
-    }
-  ],
-  "dist": {
-    "shasum": "6545ccd95afe77b9c655d81c2e6ceace36257227",
-    "tarball": "http://registry.npmjs.org/mime-types/-/mime-types-2.1.2.tgz"
-  },
-  "directories": {},
-  "_resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.2.tgz",
-  "readme": "ERROR: No README data found!"
-}
index e2cec42..9835d49 100644 (file)
@@ -6,12 +6,13 @@
   },
   "name": "form-data",
   "description": "A module to create readable \"multipart/form-data\" streams.  Can be used to submit forms and file uploads to other web applications.",
-  "version": "1.0.0-rc1",
+  "version": "1.0.0-rc2",
   "repository": {
     "type": "git",
     "url": "git://github.com/felixge/node-form-data.git"
   },
   "main": "./lib/form_data",
+  "browser": "./lib/browser",
   "scripts": {
     "test": "node test/run.js"
   },
     "combined-stream": "^1.0.3",
     "mime-types": "^2.1.1"
   },
-  "licenses": [
-    {
-      "type": "MIT",
-      "url": "https://raw.github.com/felixge/node-form-data/master/License"
-    }
-  ],
+  "license": "MIT",
   "devDependencies": {
     "fake": "^0.2.2",
     "far": "^0.0.7",
     "formidable": "^1.0.17",
     "request": "^2.57.0"
   },
-  "gitHead": "e6650a4c078fd09c130ed712848d71d8609c6518",
+  "gitHead": "9f29fefe9633f3adae72d6416fd6822c060ff6b6",
   "bugs": {
     "url": "https://github.com/felixge/node-form-data/issues"
   },
   "homepage": "https://github.com/felixge/node-form-data#readme",
-  "_id": "form-data@1.0.0-rc1",
-  "_shasum": "de5d87ff28439596f4f5500bff58d1244d54793a",
+  "_id": "form-data@1.0.0-rc2",
+  "_shasum": "5bc9c9b3dd3dec1977b0abf58790192081d95235",
   "_from": "form-data@>=1.0.0-rc1 <1.1.0",
   "_npmVersion": "2.10.1",
   "_nodeVersion": "0.12.4",
@@ -50,8 +46,8 @@
     "email": "iam@alexindigo.com"
   },
   "dist": {
-    "shasum": "de5d87ff28439596f4f5500bff58d1244d54793a",
-    "tarball": "http://registry.npmjs.org/form-data/-/form-data-1.0.0-rc1.tgz"
+    "shasum": "5bc9c9b3dd3dec1977b0abf58790192081d95235",
+    "tarball": "http://registry.npmjs.org/form-data/-/form-data-1.0.0-rc2.tgz"
   },
   "maintainers": [
     {
@@ -76,6 +72,5 @@
     }
   ],
   "directories": {},
-  "_resolved": "https://registry.npmjs.org/form-data/-/form-data-1.0.0-rc1.tgz",
-  "readme": "ERROR: No README data found!"
+  "_resolved": "https://registry.npmjs.org/form-data/-/form-data-1.0.0-rc2.tgz"
 }
index a3966cf..8d4ca28 100644 (file)
@@ -7,7 +7,7 @@ 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:</p>
+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.
index 37d389e..1b1ac11 100644 (file)
@@ -1,3 +1,10 @@
+## 2.9.34 (2015-07-15)
+
+Bugfixes:
+
+-  Correct domain for .map, .each, .filter, .reduce callbacks ([#701](.)).
+ - Preserve bound-with-promise promises across the entire chain ([#702](.)).
+
 ## 2.9.33 (2015-07-09)
 
 Bugfixes:
index 6b9f1c3..ddd6a8a 100644 (file)
@@ -8,7 +8,7 @@
  * 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:</p>
+ * 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.
@@ -23,7 +23,7 @@
  * 
  */
 /**
- * bluebird build version 2.9.33
+ * bluebird build version 2.9.34
  * Features enabled: core, race, call_get, generators, map, nodeify, promisify, props, reduce, settle, some, cancel, using, filter, any, each, timers
 */
 !function(e){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var f;"undefined"!=typeof window?f=window:"undefined"!=typeof global?f=global:"undefined"!=typeof self&&(f=self),f.Promise=e()}}(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof _dereq_=="function"&&_dereq_;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof _dereq_=="function"&&_dereq_;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(_dereq_,module,exports){
@@ -214,7 +214,6 @@ var targetRejected = function(e, context) {
 };
 
 var bindingResolved = function(thisArg, context) {
-    this._setBoundTo(thisArg);
     if (this._isPending()) {
         this._resolveCallback(context.target);
     }
@@ -229,6 +228,8 @@ Promise.prototype.bind = function (thisArg) {
     var ret = new Promise(INTERNAL);
     ret._propagateFrom(this, 1);
     var target = this._target();
+
+    ret._setBoundTo(maybePromise);
     if (maybePromise instanceof Promise) {
         var context = {
             promiseRejectionQueued: false,
@@ -240,7 +241,6 @@ Promise.prototype.bind = function (thisArg) {
         maybePromise._then(
             bindingResolved, bindingRejected, ret._progress, ret, context);
     } else {
-        ret._setBoundTo(thisArg);
         ret._resolveCallback(target);
     }
     return ret;
@@ -263,13 +263,12 @@ Promise.bind = function (thisArg, value) {
     var maybePromise = tryConvertToPromise(thisArg);
     var ret = new Promise(INTERNAL);
 
+    ret._setBoundTo(maybePromise);
     if (maybePromise instanceof Promise) {
-        maybePromise._then(function(thisArg) {
-            ret._setBoundTo(thisArg);
+        maybePromise._then(function() {
             ret._resolveCallback(value);
         }, ret._reject, ret._progress, ret, null);
     } else {
-        ret._setBoundTo(thisArg);
         ret._resolveCallback(value);
     }
     return ret;
@@ -992,7 +991,7 @@ function safePredicate(predicate, e) {
 CatchFilter.prototype.doFilter = function (e) {
     var cb = this._callback;
     var promise = this._promise;
-    var boundTo = promise._boundTo;
+    var boundTo = promise._boundValue();
     for (var i = 0, len = this._instances.length; i < len; ++i) {
         var item = this._instances[i];
         var itemIsErrorType = item === Error ||
@@ -1553,7 +1552,7 @@ function finallyHandler(reasonOrValue) {
     var handler = this.handler;
 
     var ret = promise._isBound()
-                    ? handler.call(promise._boundTo)
+                    ? handler.call(promise._boundValue())
                     : handler();
 
     if (ret !== undefined) {
@@ -1578,7 +1577,7 @@ function tapHandler(value) {
     var handler = this.handler;
 
     var ret = promise._isBound()
-                    ? handler.call(promise._boundTo, value)
+                    ? handler.call(promise._boundValue(), value)
                     : handler(value);
 
     if (ret !== undefined) {
@@ -1869,6 +1868,7 @@ module.exports = function(Promise,
                           apiRejection,
                           tryConvertToPromise,
                           INTERNAL) {
+var getDomain = Promise._getDomain;
 var async = _dereq_("./async.js");
 var util = _dereq_("./util.js");
 var tryCatch = util.tryCatch;
@@ -1879,7 +1879,8 @@ var EMPTY_ARRAY = [];
 function MappingPromiseArray(promises, fn, limit, _filter) {
     this.constructor$(promises);
     this._promise._captureStackTrace();
-    this._callback = fn;
+    var domain = getDomain();
+    this._callback = domain === null ? fn : domain.bind(fn);
     this._preservedValues = _filter === INTERNAL
         ? new Array(this.length())
         : null;
@@ -1914,7 +1915,7 @@ MappingPromiseArray.prototype._promiseFulfilled = function (value, index) {
         if (preservedValues !== null) preservedValues[index] = value;
 
         var callback = this._callback;
-        var receiver = this._promise._boundTo;
+        var receiver = this._promise._boundValue();
         this._promise._pushContext();
         var ret = tryCatch(callback).call(receiver, value, index, length);
         this._promise._popContext();
@@ -2052,7 +2053,8 @@ var errorObj = util.errorObj;
 function spreadAdapter(val, nodeback) {
     var promise = this;
     if (!util.isArray(val)) return successAdapter.call(promise, val, nodeback);
-    var ret = tryCatch(nodeback).apply(promise._boundTo, [null].concat(val));
+    var ret =
+        tryCatch(nodeback).apply(promise._boundValue(), [null].concat(val));
     if (ret === errorObj) {
         async.throwLater(ret.e);
     }
@@ -2060,7 +2062,7 @@ function spreadAdapter(val, nodeback) {
 
 function successAdapter(val, nodeback) {
     var promise = this;
-    var receiver = promise._boundTo;
+    var receiver = promise._boundValue();
     var ret = val === undefined
         ? tryCatch(nodeback).call(receiver, null)
         : tryCatch(nodeback).call(receiver, null, val);
@@ -2076,13 +2078,13 @@ function errorAdapter(reason, nodeback) {
         newReason.cause = reason;
         reason = newReason;
     }
-    var ret = tryCatch(nodeback).call(promise._boundTo, reason);
+    var ret = tryCatch(nodeback).call(promise._boundValue(), reason);
     if (ret === errorObj) {
         async.throwLater(ret.e);
     }
 }
 
-Promise.prototype.asCallback = 
+Promise.prototype.asCallback =
 Promise.prototype.nodeify = function (nodeback, options) {
     if (typeof nodeback == "function") {
         var adapter = successAdapter;
@@ -2493,7 +2495,7 @@ Promise.prototype._receiverAt = function (index) {
         : this[
             index * 5 - 5 + 4];
     if (ret === undefined && this._isBound()) {
-        return this._boundTo;
+        return this._boundValue();
     }
     return ret;
 };
@@ -2516,6 +2518,20 @@ Promise.prototype._rejectionHandlerAt = function (index) {
         : this[index * 5 - 5 + 1];
 };
 
+Promise.prototype._boundValue = function() {
+    var ret = this._boundTo;
+    if (ret !== undefined) {
+        if (ret instanceof Promise) {
+            if (ret.isFulfilled()) {
+                return ret.value();
+            } else {
+                return undefined;
+            }
+        }
+    }
+    return ret;
+};
+
 Promise.prototype._migrateCallbacks = function (follower, index) {
     var fulfill = follower._fulfillmentHandlerAt(index);
     var reject = follower._rejectionHandlerAt(index);
@@ -2666,7 +2682,7 @@ Promise.prototype._settlePromiseFromHandler = function (
     promise._pushContext();
     var x;
     if (receiver === APPLY && !this._isRejected()) {
-        x = tryCatch(handler).apply(this._boundTo, value);
+        x = tryCatch(handler).apply(this._boundValue(), value);
     } else {
         x = tryCatch(handler).call(receiver, value);
     }
@@ -2736,8 +2752,6 @@ Promise.prototype._settlePromiseAt = function (index) {
         this._isCarryingStackTrace() ? this._getCarriedStackTrace() : undefined;
     var value = this._settledValue;
     var receiver = this._receiverAt(index);
-
-
     this._clearCallbackDataAtIndex(index);
 
     if (typeof handler === "function") {
@@ -3721,6 +3735,7 @@ module.exports = function(Promise,
                           apiRejection,
                           tryConvertToPromise,
                           INTERNAL) {
+var getDomain = Promise._getDomain;
 var async = _dereq_("./async.js");
 var util = _dereq_("./util.js");
 var tryCatch = util.tryCatch;
@@ -3749,7 +3764,8 @@ function ReductionPromiseArray(promises, fn, accum, _each) {
         }
     }
     if (!(isPromise || this._zerothIsAccum)) this._gotAccum = true;
-    this._callback = fn;
+    var domain = getDomain();
+    this._callback = domain === null ? fn : domain.bind(fn);
     this._accum = accum;
     if (!rejected) async.invoke(init, this, undefined);
 }
@@ -3803,7 +3819,7 @@ ReductionPromiseArray.prototype._promiseFulfilled = function (value, index) {
     if (!gotAccum) return;
 
     var callback = this._callback;
-    var receiver = this._promise._boundTo;
+    var receiver = this._promise._boundValue();
     var ret;
 
     for (var i = this._reducingIndex; i < length; ++i) {
index 97282c7..6c33b1b 100644 (file)
@@ -8,7 +8,7 @@
  * 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:</p>
+ * 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.
@@ -23,9 +23,9 @@
  * 
  */
 /**
- * bluebird build version 2.9.33
+ * bluebird build version 2.9.34
  * Features enabled: core, race, call_get, generators, map, nodeify, promisify, props, reduce, settle, some, cancel, using, filter, any, each, timers
 */
-!function(t){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var e;"undefined"!=typeof window?e=window:"undefined"!=typeof global?e=global:"undefined"!=typeof self&&(e=self),e.Promise=t()}}(function(){var t,e,r;return function n(t,e,r){function i(s,a){if(!e[s]){if(!t[s]){var u="function"==typeof _dereq_&&_dereq_;if(!a&&u)return u(s,!0);if(o)return o(s,!0);var c=new Error("Cannot find module '"+s+"'");throw c.code="MODULE_NOT_FOUND",c}var l=e[s]={exports:{}};t[s][0].call(l.exports,function(e){var r=t[s][1][e];return i(r?r:e)},l,l.exports,n,t,e,r)}return e[s].exports}for(var o="function"==typeof _dereq_&&_dereq_,s=0;s<r.length;s++)i(r[s]);return i}({1:[function(t,e){"use strict";e.exports=function(t){function e(t){var e=new r(t),n=e.promise();return e.setHowMany(1),e.setUnwrap(),e.init(),n}var r=t._SomePromiseArray;t.any=function(t){return e(t)},t.prototype.any=function(){return e(this)}}},{}],2:[function(t,e){"use strict";function r(){this._isTickUsed=!1,this._lateQueue=new c(16),this._normalQueue=new c(16),this._trampolineEnabled=!0;var t=this;this.drainQueues=function(){t._drainQueues()},this._schedule=u.isStatic?u(this.drainQueues):u}function n(t,e,r){this._lateQueue.push(t,e,r),this._queueTick()}function i(t,e,r){this._normalQueue.push(t,e,r),this._queueTick()}function o(t){this._normalQueue._pushOne(t),this._queueTick()}var s;try{throw new Error}catch(a){s=a}var u=t("./schedule.js"),c=t("./queue.js"),l=t("./util.js");r.prototype.disableTrampolineIfNecessary=function(){l.hasDevTools&&(this._trampolineEnabled=!1)},r.prototype.enableTrampoline=function(){this._trampolineEnabled||(this._trampolineEnabled=!0,this._schedule=function(t){setTimeout(t,0)})},r.prototype.haveItemsQueued=function(){return this._normalQueue.length()>0},r.prototype.throwLater=function(t,e){if(1===arguments.length&&(e=t,t=function(){throw e}),"undefined"!=typeof setTimeout)setTimeout(function(){t(e)},0);else try{this._schedule(function(){t(e)})}catch(r){throw new Error("No async scheduler available\n\n    See http://goo.gl/m3OTXk\n")}},l.hasDevTools?(u.isStatic&&(u=function(t){setTimeout(t,0)}),r.prototype.invokeLater=function(t,e,r){this._trampolineEnabled?n.call(this,t,e,r):this._schedule(function(){setTimeout(function(){t.call(e,r)},100)})},r.prototype.invoke=function(t,e,r){this._trampolineEnabled?i.call(this,t,e,r):this._schedule(function(){t.call(e,r)})},r.prototype.settlePromises=function(t){this._trampolineEnabled?o.call(this,t):this._schedule(function(){t._settlePromises()})}):(r.prototype.invokeLater=n,r.prototype.invoke=i,r.prototype.settlePromises=o),r.prototype.invokeFirst=function(t,e,r){this._normalQueue.unshift(t,e,r),this._queueTick()},r.prototype._drainQueue=function(t){for(;t.length()>0;){var e=t.shift();if("function"==typeof e){var r=t.shift(),n=t.shift();e.call(r,n)}else e._settlePromises()}},r.prototype._drainQueues=function(){this._drainQueue(this._normalQueue),this._reset(),this._drainQueue(this._lateQueue)},r.prototype._queueTick=function(){this._isTickUsed||(this._isTickUsed=!0,this._schedule(this.drainQueues))},r.prototype._reset=function(){this._isTickUsed=!1},e.exports=new r,e.exports.firstLineError=s},{"./queue.js":28,"./schedule.js":31,"./util.js":38}],3:[function(t,e){"use strict";e.exports=function(t,e,r){var n=function(t,e){this._reject(e)},i=function(t,e){e.promiseRejectionQueued=!0,e.bindingPromise._then(n,n,null,this,t)},o=function(t,e){this._setBoundTo(t),this._isPending()&&this._resolveCallback(e.target)},s=function(t,e){e.promiseRejectionQueued||this._reject(t)};t.prototype.bind=function(n){var a=r(n),u=new t(e);u._propagateFrom(this,1);var c=this._target();if(a instanceof t){var l={promiseRejectionQueued:!1,promise:u,target:c,bindingPromise:a};c._then(e,i,u._progress,u,l),a._then(o,s,u._progress,u,l)}else u._setBoundTo(n),u._resolveCallback(c);return u},t.prototype._setBoundTo=function(t){void 0!==t?(this._bitField=131072|this._bitField,this._boundTo=t):this._bitField=-131073&this._bitField},t.prototype._isBound=function(){return 131072===(131072&this._bitField)},t.bind=function(n,i){var o=r(n),s=new t(e);return o instanceof t?o._then(function(t){s._setBoundTo(t),s._resolveCallback(i)},s._reject,s._progress,s,null):(s._setBoundTo(n),s._resolveCallback(i)),s}}},{}],4:[function(t,e){"use strict";function r(){try{Promise===i&&(Promise=n)}catch(t){}return i}var n;"undefined"!=typeof Promise&&(n=Promise);var i=t("./promise.js")();i.noConflict=r,e.exports=i},{"./promise.js":23}],5:[function(t,e){"use strict";var r=Object.create;if(r){var n=r(null),i=r(null);n[" size"]=i[" size"]=0}e.exports=function(e){function r(t,r){var n;if(null!=t&&(n=t[r]),"function"!=typeof n){var i="Object "+a.classString(t)+" has no method '"+a.toString(r)+"'";throw new e.TypeError(i)}return n}function n(t){var e=this.pop(),n=r(t,e);return n.apply(t,this)}function i(t){return t[this]}function o(t){var e=+this;return 0>e&&(e=Math.max(0,e+t.length)),t[e]}{var s,a=t("./util.js"),u=a.canEvaluate;a.isIdentifier}e.prototype.call=function(t){for(var e=arguments.length,r=new Array(e-1),i=1;e>i;++i)r[i-1]=arguments[i];return r.push(t),this._then(n,void 0,void 0,r,void 0)},e.prototype.get=function(t){var e,r="number"==typeof t;if(r)e=o;else if(u){var n=s(t);e=null!==n?n:i}else e=i;return this._then(e,void 0,void 0,t,void 0)}}},{"./util.js":38}],6:[function(t,e){"use strict";e.exports=function(e){var r=t("./errors.js"),n=t("./async.js"),i=r.CancellationError;e.prototype._cancel=function(t){if(!this.isCancellable())return this;for(var e,r=this;void 0!==(e=r._cancellationParent)&&e.isCancellable();)r=e;this._unsetCancellable(),r._target()._rejectCallback(t,!1,!0)},e.prototype.cancel=function(t){return this.isCancellable()?(void 0===t&&(t=new i),n.invokeLater(this._cancel,this,t),this):this},e.prototype.cancellable=function(){return this._cancellable()?this:(n.enableTrampoline(),this._setCancellable(),this._cancellationParent=void 0,this)},e.prototype.uncancellable=function(){var t=this.then();return t._unsetCancellable(),t},e.prototype.fork=function(t,e,r){var n=this._then(t,e,r,void 0,void 0);return n._setCancellable(),n._cancellationParent=void 0,n}}},{"./async.js":2,"./errors.js":13}],7:[function(t,e){"use strict";e.exports=function(){function e(t){this._parent=t;var r=this._length=1+(void 0===t?0:t._length);j(this,e),r>32&&this.uncycle()}function r(t,e){for(var r=0;r<e.length-1;++r)e[r].push("From previous event:"),e[r]=e[r].join("\n");return r<e.length&&(e[r]=e[r].join("\n")),t+"\n"+e.join("\n")}function n(t){for(var e=0;e<t.length;++e)(0===t[e].length||e+1<t.length&&t[e][0]===t[e+1][0])&&(t.splice(e,1),e--)}function i(t){for(var e=t[0],r=1;r<t.length;++r){for(var n=t[r],i=e.length-1,o=e[i],s=-1,a=n.length-1;a>=0;--a)if(n[a]===o){s=a;break}for(var a=s;a>=0;--a){var u=n[a];if(e[i]!==u)break;e.pop(),i--}e=n}}function o(t){for(var e=[],r=0;r<t.length;++r){var n=t[r],i=_.test(n)||"    (No stack trace)"===n,o=i&&y(n);i&&!o&&(v&&" "!==n.charAt(0)&&(n="    "+n),e.push(n))}return e}function s(t){for(var e=t.stack.replace(/\s+$/g,"").split("\n"),r=0;r<e.length;++r){var n=e[r];if("    (No stack trace)"===n||_.test(n))break}return r>0&&(e=e.slice(r)),e}function a(t){var e;if("function"==typeof t)e="[function "+(t.name||"anonymous")+"]";else{e=t.toString();var r=/\[object [a-zA-Z0-9$_]+\]/;if(r.test(e))try{var n=JSON.stringify(t);e=n}catch(i){}0===e.length&&(e="(empty array)")}return"(<"+u(e)+">, no stack trace)"}function u(t){var e=41;return t.length<e?t:t.substr(0,e-3)+"..."}function c(t){var e=t.match(g);return e?{fileName:e[1],line:parseInt(e[2],10)}:void 0}var l,h=t("./async.js"),p=t("./util.js"),f=/[\\\/]bluebird[\\\/]js[\\\/](main|debug|zalgo|instrumented)/,_=null,d=null,v=!1;p.inherits(e,Error),e.prototype.uncycle=function(){var t=this._length;if(!(2>t)){for(var e=[],r={},n=0,i=this;void 0!==i;++n)e.push(i),i=i._parent;t=this._length=n;for(var n=t-1;n>=0;--n){var o=e[n].stack;void 0===r[o]&&(r[o]=n)}for(var n=0;t>n;++n){var s=e[n].stack,a=r[s];if(void 0!==a&&a!==n){a>0&&(e[a-1]._parent=void 0,e[a-1]._length=1),e[n]._parent=void 0,e[n]._length=1;var u=n>0?e[n-1]:this;t-1>a?(u._parent=e[a+1],u._parent.uncycle(),u._length=u._parent._length+1):(u._parent=void 0,u._length=1);for(var c=u._length+1,l=n-2;l>=0;--l)e[l]._length=c,c++;return}}}},e.prototype.parent=function(){return this._parent},e.prototype.hasParent=function(){return void 0!==this._parent},e.prototype.attachExtraTrace=function(t){if(!t.__stackCleaned__){this.uncycle();for(var s=e.parseStackAndMessage(t),a=s.message,u=[s.stack],c=this;void 0!==c;)u.push(o(c.stack.split("\n"))),c=c._parent;i(u),n(u),p.notEnumerableProp(t,"stack",r(a,u)),p.notEnumerableProp(t,"__stackCleaned__",!0)}},e.parseStackAndMessage=function(t){var e=t.stack,r=t.toString();return e="string"==typeof e&&e.length>0?s(t):["    (No stack trace)"],{message:r,stack:o(e)}},e.formatAndLogError=function(t,e){if("undefined"!=typeof console){var r;if("object"==typeof t||"function"==typeof t){var n=t.stack;r=e+d(n,t)}else r=e+String(t);"function"==typeof l?l(r):("function"==typeof console.log||"object"==typeof console.log)&&console.log(r)}},e.unhandledRejection=function(t){e.formatAndLogError(t,"^--- With additional stack trace: ")},e.isSupported=function(){return"function"==typeof j},e.fireRejectionEvent=function(t,r,n,i){var o=!1;try{"function"==typeof r&&(o=!0,"rejectionHandled"===t?r(i):r(n,i))}catch(s){h.throwLater(s)}var a=!1;try{a=b(t,n,i)}catch(s){a=!0,h.throwLater(s)}var u=!1;if(m)try{u=m(t.toLowerCase(),{reason:n,promise:i})}catch(s){u=!0,h.throwLater(s)}a||o||u||"unhandledRejection"!==t||e.formatAndLogError(n,"Unhandled rejection ")};var y=function(){return!1},g=/[\/<\(]([^:\/]+):(\d+):(?:\d+)\)?\s*$/;e.setBounds=function(t,r){if(e.isSupported()){for(var n,i,o=t.stack.split("\n"),s=r.stack.split("\n"),a=-1,u=-1,l=0;l<o.length;++l){var h=c(o[l]);if(h){n=h.fileName,a=h.line;break}}for(var l=0;l<s.length;++l){var h=c(s[l]);if(h){i=h.fileName,u=h.line;break}}0>a||0>u||!n||!i||n!==i||a>=u||(y=function(t){if(f.test(t))return!0;var e=c(t);return e&&e.fileName===n&&a<=e.line&&e.line<=u?!0:!1})}};var m,j=function(){var t=/^\s*at\s*/,e=function(t,e){return"string"==typeof t?t:void 0!==e.name&&void 0!==e.message?e.toString():a(e)};if("number"==typeof Error.stackTraceLimit&&"function"==typeof Error.captureStackTrace){Error.stackTraceLimit=Error.stackTraceLimit+6,_=t,d=e;var r=Error.captureStackTrace;return y=function(t){return f.test(t)},function(t,e){Error.stackTraceLimit=Error.stackTraceLimit+6,r(t,e),Error.stackTraceLimit=Error.stackTraceLimit-6}}var n=new Error;if("string"==typeof n.stack&&n.stack.split("\n")[0].indexOf("stackDetection@")>=0)return _=/@/,d=e,v=!0,function(t){t.stack=(new Error).stack};var i;try{throw new Error}catch(o){i="stack"in o}return"stack"in n||!i||"number"!=typeof Error.stackTraceLimit?(d=function(t,e){return"string"==typeof t?t:"object"!=typeof e&&"function"!=typeof e||void 0===e.name||void 0===e.message?a(e):e.toString()},null):(_=t,d=e,function(t){Error.stackTraceLimit=Error.stackTraceLimit+6;try{throw new Error}catch(e){t.stack=e.stack}Error.stackTraceLimit=Error.stackTraceLimit-6})}([]),b=function(){if(p.isNode)return function(t,e,r){return"rejectionHandled"===t?process.emit(t,r):process.emit(t,e,r)};var t=!1,e=!0;try{var r=new self.CustomEvent("test");t=r instanceof CustomEvent}catch(n){}if(!t)try{var i=document.createEvent("CustomEvent");i.initCustomEvent("testingtheevent",!1,!0,{}),self.dispatchEvent(i)}catch(n){e=!1}e&&(m=function(e,r){var n;return t?n=new self.CustomEvent(e,{detail:r,bubbles:!1,cancelable:!0}):self.dispatchEvent&&(n=document.createEvent("CustomEvent"),n.initCustomEvent(e,!1,!0,r)),n?!self.dispatchEvent(n):!1});var o={};return o.unhandledRejection="onunhandledRejection".toLowerCase(),o.rejectionHandled="onrejectionHandled".toLowerCase(),function(t,e,r){var n=o[t],i=self[n];return i?("rejectionHandled"===t?i.call(self,r):i.call(self,e,r),!0):!1}}();return"undefined"!=typeof console&&"undefined"!=typeof console.warn&&(l=function(t){console.warn(t)},p.isNode&&process.stderr.isTTY?l=function(t){process.stderr.write("\e[31m"+t+"\e[39m\n")}:p.isNode||"string"!=typeof(new Error).stack||(l=function(t){console.warn("%c"+t,"color: red")})),e}},{"./async.js":2,"./util.js":38}],8:[function(t,e){"use strict";e.exports=function(e){function r(t,e,r){this._instances=t,this._callback=e,this._promise=r}function n(t,e){var r={},n=s(t).call(r,e);if(n===a)return n;var i=u(r);return i.length?(a.e=new c("Catch filter must inherit from Error or be a simple predicate function\n\n    See http://goo.gl/o84o68\n"),a):n}var i=t("./util.js"),o=t("./errors.js"),s=i.tryCatch,a=i.errorObj,u=t("./es5.js").keys,c=o.TypeError;return r.prototype.doFilter=function(t){for(var r=this._callback,i=this._promise,o=i._boundTo,u=0,c=this._instances.length;c>u;++u){var l=this._instances[u],h=l===Error||null!=l&&l.prototype instanceof Error;if(h&&t instanceof l){var p=s(r).call(o,t);return p===a?(e.e=p.e,e):p}if("function"==typeof l&&!h){var f=n(l,t);if(f===a){t=a.e;break}if(f){var p=s(r).call(o,t);return p===a?(e.e=p.e,e):p}}}return e.e=t,e},r}},{"./errors.js":13,"./es5.js":14,"./util.js":38}],9:[function(t,e){"use strict";e.exports=function(t,e,r){function n(){this._trace=new e(o())}function i(){return r()?new n:void 0}function o(){var t=s.length-1;return t>=0?s[t]:void 0}var s=[];return n.prototype._pushContext=function(){r()&&void 0!==this._trace&&s.push(this._trace)},n.prototype._popContext=function(){r()&&void 0!==this._trace&&s.pop()},t.prototype._peekContext=o,t.prototype._pushContext=n.prototype._pushContext,t.prototype._popContext=n.prototype._popContext,i}},{}],10:[function(t,e){"use strict";e.exports=function(e,r){var n,i,o=e._getDomain,s=t("./async.js"),a=t("./errors.js").Warning,u=t("./util.js"),c=u.canAttachTrace,l=!1||u.isNode&&(!!process.env.BLUEBIRD_DEBUG||"development"===process.env.NODE_ENV);return l&&s.disableTrampolineIfNecessary(),e.prototype._ignoreRejections=function(){this._unsetRejectionIsUnhandled(),this._bitField=16777216|this._bitField},e.prototype._ensurePossibleRejectionHandled=function(){0===(16777216&this._bitField)&&(this._setRejectionIsUnhandled(),s.invokeLater(this._notifyUnhandledRejection,this,void 0))},e.prototype._notifyUnhandledRejectionIsHandled=function(){r.fireRejectionEvent("rejectionHandled",n,void 0,this)},e.prototype._notifyUnhandledRejection=function(){if(this._isRejectionUnhandled()){var t=this._getCarriedStackTrace()||this._settledValue;this._setUnhandledRejectionIsNotified(),r.fireRejectionEvent("unhandledRejection",i,t,this)}},e.prototype._setUnhandledRejectionIsNotified=function(){this._bitField=524288|this._bitField},e.prototype._unsetUnhandledRejectionIsNotified=function(){this._bitField=-524289&this._bitField},e.prototype._isUnhandledRejectionNotified=function(){return(524288&this._bitField)>0},e.prototype._setRejectionIsUnhandled=function(){this._bitField=2097152|this._bitField},e.prototype._unsetRejectionIsUnhandled=function(){this._bitField=-2097153&this._bitField,this._isUnhandledRejectionNotified()&&(this._unsetUnhandledRejectionIsNotified(),this._notifyUnhandledRejectionIsHandled())},e.prototype._isRejectionUnhandled=function(){return(2097152&this._bitField)>0},e.prototype._setCarriedStackTrace=function(t){this._bitField=1048576|this._bitField,this._fulfillmentHandler0=t},e.prototype._isCarryingStackTrace=function(){return(1048576&this._bitField)>0},e.prototype._getCarriedStackTrace=function(){return this._isCarryingStackTrace()?this._fulfillmentHandler0:void 0},e.prototype._captureStackTrace=function(){return l&&(this._trace=new r(this._peekContext())),this},e.prototype._attachExtraTrace=function(t,e){if(l&&c(t)){var n=this._trace;if(void 0!==n&&e&&(n=n._parent),void 0!==n)n.attachExtraTrace(t);else if(!t.__stackCleaned__){var i=r.parseStackAndMessage(t);u.notEnumerableProp(t,"stack",i.message+"\n"+i.stack.join("\n")),u.notEnumerableProp(t,"__stackCleaned__",!0)}}},e.prototype._warn=function(t){var e=new a(t),n=this._peekContext();if(n)n.attachExtraTrace(e);else{var i=r.parseStackAndMessage(e);e.stack=i.message+"\n"+i.stack.join("\n")}r.formatAndLogError(e,"")},e.onPossiblyUnhandledRejection=function(t){var e=o();i="function"==typeof t?null===e?t:e.bind(t):void 0},e.onUnhandledRejectionHandled=function(t){var e=o();n="function"==typeof t?null===e?t:e.bind(t):void 0},e.longStackTraces=function(){if(s.haveItemsQueued()&&l===!1)throw new Error("cannot enable long stack traces after promises have been created\n\n    See http://goo.gl/DT1qyG\n");l=r.isSupported(),l&&s.disableTrampolineIfNecessary()},e.hasLongStackTraces=function(){return l&&r.isSupported()},r.isSupported()||(e.longStackTraces=function(){},l=!1),function(){return l}}},{"./async.js":2,"./errors.js":13,"./util.js":38}],11:[function(t,e){"use strict";var r=t("./util.js"),n=r.isPrimitive;e.exports=function(t){var e=function(){return this},r=function(){throw this},i=function(){},o=function(){throw void 0},s=function(t,e){return 1===e?function(){throw t}:2===e?function(){return t}:void 0};t.prototype["return"]=t.prototype.thenReturn=function(t){return void 0===t?this.then(i):n(t)?this._then(s(t,2),void 0,void 0,void 0,void 0):this._then(e,void 0,void 0,t,void 0)},t.prototype["throw"]=t.prototype.thenThrow=function(t){return void 0===t?this.then(o):n(t)?this._then(s(t,1),void 0,void 0,void 0,void 0):this._then(r,void 0,void 0,t,void 0)}}},{"./util.js":38}],12:[function(t,e){"use strict";e.exports=function(t,e){var r=t.reduce;t.prototype.each=function(t){return r(this,t,null,e)},t.each=function(t,n){return r(t,n,null,e)}}},{}],13:[function(t,e){"use strict";function r(t,e){function r(n){return this instanceof r?(l(this,"message","string"==typeof n?n:e),l(this,"name",t),void(Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):Error.call(this))):new r(n)}return c(r,Error),r}function n(t){return this instanceof n?(l(this,"name","OperationalError"),l(this,"message",t),this.cause=t,this.isOperational=!0,void(t instanceof Error?(l(this,"message",t.message),l(this,"stack",t.stack)):Error.captureStackTrace&&Error.captureStackTrace(this,this.constructor))):new n(t)}var i,o,s=t("./es5.js"),a=s.freeze,u=t("./util.js"),c=u.inherits,l=u.notEnumerableProp,h=r("Warning","warning"),p=r("CancellationError","cancellation error"),f=r("TimeoutError","timeout error"),_=r("AggregateError","aggregate error");try{i=TypeError,o=RangeError}catch(d){i=r("TypeError","type error"),o=r("RangeError","range error")}for(var v="join pop push shift unshift slice filter forEach some every map indexOf lastIndexOf reduce reduceRight sort reverse".split(" "),y=0;y<v.length;++y)"function"==typeof Array.prototype[v[y]]&&(_.prototype[v[y]]=Array.prototype[v[y]]);s.defineProperty(_.prototype,"length",{value:0,configurable:!1,writable:!0,enumerable:!0}),_.prototype.isOperational=!0;var g=0;_.prototype.toString=function(){var t=Array(4*g+1).join(" "),e="\n"+t+"AggregateError of:\n";g++,t=Array(4*g+1).join(" ");for(var r=0;r<this.length;++r){for(var n=this[r]===this?"[Circular AggregateError]":this[r]+"",i=n.split("\n"),o=0;o<i.length;++o)i[o]=t+i[o];n=i.join("\n"),e+=n+"\n"}return g--,e},c(n,Error);var m=Error.__BluebirdErrorTypes__;m||(m=a({CancellationError:p,TimeoutError:f,OperationalError:n,RejectionError:n,AggregateError:_}),l(Error,"__BluebirdErrorTypes__",m)),e.exports={Error:Error,TypeError:i,RangeError:o,CancellationError:m.CancellationError,OperationalError:m.OperationalError,TimeoutError:m.TimeoutError,AggregateError:m.AggregateError,Warning:h}},{"./es5.js":14,"./util.js":38}],14:[function(t,e){var r=function(){"use strict";return void 0===this}();if(r)e.exports={freeze:Object.freeze,defineProperty:Object.defineProperty,getDescriptor:Object.getOwnPropertyDescriptor,keys:Object.keys,names:Object.getOwnPropertyNames,getPrototypeOf:Object.getPrototypeOf,isArray:Array.isArray,isES5:r,propertyIsWritable:function(t,e){var r=Object.getOwnPropertyDescriptor(t,e);return!(r&&!r.writable&&!r.set)}};else{var n={}.hasOwnProperty,i={}.toString,o={}.constructor.prototype,s=function(t){var e=[];for(var r in t)n.call(t,r)&&e.push(r);return e},a=function(t,e){return{value:t[e]}},u=function(t,e,r){return t[e]=r.value,t},c=function(t){return t},l=function(t){try{return Object(t).constructor.prototype}catch(e){return o}},h=function(t){try{return"[object Array]"===i.call(t)}catch(e){return!1}};e.exports={isArray:h,keys:s,names:s,defineProperty:u,getDescriptor:a,freeze:c,getPrototypeOf:l,isES5:r,propertyIsWritable:function(){return!0}}}},{}],15:[function(t,e){"use strict";e.exports=function(t,e){var r=t.map;t.prototype.filter=function(t,n){return r(this,t,n,e)},t.filter=function(t,n,i){return r(t,n,i,e)}}},{}],16:[function(t,e){"use strict";e.exports=function(e,r,n){function i(){return this}function o(){throw this}function s(t){return function(){return t}}function a(t){return function(){throw t}}function u(t,e,r){var n;return n=p(e)?r?s(e):a(e):r?i:o,t._then(n,f,void 0,e,void 0)}function c(t){var i=this.promise,o=this.handler,s=i._isBound()?o.call(i._boundTo):o();if(void 0!==s){var a=n(s,i);if(a instanceof e)return a=a._target(),u(a,t,i.isFulfilled())}return i.isRejected()?(r.e=t,r):t}function l(t){var r=this.promise,i=this.handler,o=r._isBound()?i.call(r._boundTo,t):i(t);if(void 0!==o){var s=n(o,r);if(s instanceof e)return s=s._target(),u(s,t,!0)}return t}var h=t("./util.js"),p=h.isPrimitive,f=h.thrower;e.prototype._passThroughHandler=function(t,e){if("function"!=typeof t)return this.then();var r={promise:this,handler:t};return this._then(e?c:l,e?c:void 0,void 0,r,void 0)},e.prototype.lastly=e.prototype["finally"]=function(t){return this._passThroughHandler(t,!0)},e.prototype.tap=function(t){return this._passThroughHandler(t,!1)}}},{"./util.js":38}],17:[function(t,e){"use strict";e.exports=function(e,r,n,i){function o(t,r,n){for(var o=0;o<r.length;++o){n._pushContext();var s=h(r[o])(t);if(n._popContext(),s===l){n._pushContext();var a=e.reject(l.e);return n._popContext(),a}var u=i(s,n);if(u instanceof e)return u}return null}function s(t,r,i,o){var s=this._promise=new e(n);s._captureStackTrace(),this._stack=o,this._generatorFunction=t,this._receiver=r,this._generator=void 0,this._yieldHandlers="function"==typeof i?[i].concat(p):p}var a=t("./errors.js"),u=a.TypeError,c=t("./util.js"),l=c.errorObj,h=c.tryCatch,p=[];s.prototype.promise=function(){return this._promise},s.prototype._run=function(){this._generator=this._generatorFunction.call(this._receiver),this._receiver=this._generatorFunction=void 0,this._next(void 0)},s.prototype._continue=function(t){if(t===l)return this._promise._rejectCallback(t.e,!1,!0);var r=t.value;if(t.done===!0)this._promise._resolveCallback(r);else{var n=i(r,this._promise);if(!(n instanceof e)&&(n=o(n,this._yieldHandlers,this._promise),null===n))return void this._throw(new u("A value %s was yielded that could not be treated as a promise\n\n    See http://goo.gl/4Y4pDk\n\n".replace("%s",r)+"From coroutine:\n"+this._stack.split("\n").slice(1,-7).join("\n")));n._then(this._next,this._throw,void 0,this,null)}},s.prototype._throw=function(t){this._promise._attachExtraTrace(t),this._promise._pushContext();var e=h(this._generator["throw"]).call(this._generator,t);this._promise._popContext(),this._continue(e)},s.prototype._next=function(t){this._promise._pushContext();var e=h(this._generator.next).call(this._generator,t);this._promise._popContext(),this._continue(e)},e.coroutine=function(t,e){if("function"!=typeof t)throw new u("generatorFunction must be a function\n\n    See http://goo.gl/6Vqhm0\n");var r=Object(e).yieldHandler,n=s,i=(new Error).stack;return function(){var e=t.apply(this,arguments),o=new n(void 0,void 0,r,i);return o._generator=e,o._next(void 0),o.promise()}},e.coroutine.addYieldHandler=function(t){if("function"!=typeof t)throw new u("fn must be a function\n\n    See http://goo.gl/916lJJ\n");p.push(t)},e.spawn=function(t){if("function"!=typeof t)return r("generatorFunction must be a function\n\n    See http://goo.gl/6Vqhm0\n");var n=new s(t,this),i=n.promise();return n._run(e.spawn),i}}},{"./errors.js":13,"./util.js":38}],18:[function(t,e){"use strict";e.exports=function(e,r,n,i){{var o=t("./util.js");o.canEvaluate,o.tryCatch,o.errorObj}e.join=function(){var t,e=arguments.length-1;if(e>0&&"function"==typeof arguments[e]){t=arguments[e];var n}for(var i=arguments.length,o=new Array(i),s=0;i>s;++s)o[s]=arguments[s];t&&o.pop();var n=new r(o).promise();return void 0!==t?n.spread(t):n}}},{"./util.js":38}],19:[function(t,e){"use strict";e.exports=function(e,r,n,i,o){function s(t,e,r,n){this.constructor$(t),this._promise._captureStackTrace(),this._callback=e,this._preservedValues=n===o?new Array(this.length()):null,this._limit=r,this._inFlight=0,this._queue=r>=1?[]:_,c.invoke(a,this,void 0)}function a(){this._init$(void 0,-2)}function u(t,e,r,n){var i="object"==typeof r&&null!==r?r.concurrency:0;return i="number"==typeof i&&isFinite(i)&&i>=1?i:0,new s(t,e,i,n)}var c=t("./async.js"),l=t("./util.js"),h=l.tryCatch,p=l.errorObj,f={},_=[];l.inherits(s,r),s.prototype._init=function(){},s.prototype._promiseFulfilled=function(t,r){var n=this._values,o=this.length(),s=this._preservedValues,a=this._limit;if(n[r]===f){if(n[r]=t,a>=1&&(this._inFlight--,this._drainQueue(),this._isResolved()))return}else{if(a>=1&&this._inFlight>=a)return n[r]=t,void this._queue.push(r);null!==s&&(s[r]=t);var u=this._callback,c=this._promise._boundTo;this._promise._pushContext();var l=h(u).call(c,t,r,o);if(this._promise._popContext(),l===p)return this._reject(l.e);var _=i(l,this._promise);if(_ instanceof e){if(_=_._target(),_._isPending())return a>=1&&this._inFlight++,n[r]=f,_._proxyPromiseArray(this,r);if(!_._isFulfilled())return this._reject(_._reason());l=_._value()}n[r]=l}var d=++this._totalResolved;d>=o&&(null!==s?this._filter(n,s):this._resolve(n))},s.prototype._drainQueue=function(){for(var t=this._queue,e=this._limit,r=this._values;t.length>0&&this._inFlight<e;){if(this._isResolved())return;var n=t.pop();this._promiseFulfilled(r[n],n)}},s.prototype._filter=function(t,e){for(var r=e.length,n=new Array(r),i=0,o=0;r>o;++o)t[o]&&(n[i++]=e[o]);n.length=i,this._resolve(n)},s.prototype.preservedValues=function(){return this._preservedValues},e.prototype.map=function(t,e){return"function"!=typeof t?n("fn must be a function\n\n    See http://goo.gl/916lJJ\n"):u(this,t,e,null).promise()},e.map=function(t,e,r,i){return"function"!=typeof e?n("fn must be a function\n\n    See http://goo.gl/916lJJ\n"):u(t,e,r,i).promise()}}},{"./async.js":2,"./util.js":38}],20:[function(t,e){"use strict";e.exports=function(e,r,n,i){var o=t("./util.js"),s=o.tryCatch;e.method=function(t){if("function"!=typeof t)throw new e.TypeError("fn must be a function\n\n    See http://goo.gl/916lJJ\n");return function(){var n=new e(r);n._captureStackTrace(),n._pushContext();var i=s(t).apply(this,arguments);return n._popContext(),n._resolveFromSyncValue(i),n}},e.attempt=e["try"]=function(t,n,a){if("function"!=typeof t)return i("fn must be a function\n\n    See http://goo.gl/916lJJ\n");var u=new e(r);u._captureStackTrace(),u._pushContext();var c=o.isArray(n)?s(t).apply(a,n):s(t).call(a,n);return u._popContext(),u._resolveFromSyncValue(c),u},e.prototype._resolveFromSyncValue=function(t){t===o.errorObj?this._rejectCallback(t.e,!1,!0):this._resolveCallback(t,!0)}}},{"./util.js":38}],21:[function(t,e){"use strict";e.exports=function(e){function r(t,e){var r=this;if(!o.isArray(t))return n.call(r,t,e);var i=a(e).apply(r._boundTo,[null].concat(t));i===u&&s.throwLater(i.e)}function n(t,e){var r=this,n=r._boundTo,i=void 0===t?a(e).call(n,null):a(e).call(n,null,t);i===u&&s.throwLater(i.e)}function i(t,e){var r=this;if(!t){var n=r._target(),i=n._getCarriedStackTrace();i.cause=t,t=i}var o=a(e).call(r._boundTo,t);o===u&&s.throwLater(o.e)}var o=t("./util.js"),s=t("./async.js"),a=o.tryCatch,u=o.errorObj;e.prototype.asCallback=e.prototype.nodeify=function(t,e){if("function"==typeof t){var o=n;void 0!==e&&Object(e).spread&&(o=r),this._then(o,i,void 0,this,t)}return this}}},{"./async.js":2,"./util.js":38}],22:[function(t,e){"use strict";e.exports=function(e,r){var n=t("./util.js"),i=t("./async.js"),o=n.tryCatch,s=n.errorObj;e.prototype.progressed=function(t){return this._then(void 0,void 0,t,void 0,void 0)},e.prototype._progress=function(t){this._isFollowingOrFulfilledOrRejected()||this._target()._progressUnchecked(t)},e.prototype._progressHandlerAt=function(t){return 0===t?this._progressHandler0:this[(t<<2)+t-5+2]},e.prototype._doProgressWith=function(t){var r=t.value,i=t.handler,a=t.promise,u=t.receiver,c=o(i).call(u,r);if(c===s){if(null!=c.e&&"StopProgressPropagation"!==c.e.name){var l=n.canAttachTrace(c.e)?c.e:new Error(n.toString(c.e));a._attachExtraTrace(l),a._progress(c.e)}}else c instanceof e?c._then(a._progress,null,null,a,void 0):a._progress(c)},e.prototype._progressUnchecked=function(t){for(var n=this._length(),o=this._progress,s=0;n>s;s++){var a=this._progressHandlerAt(s),u=this._promiseAt(s);if(u instanceof e)"function"==typeof a?i.invoke(this._doProgressWith,this,{handler:a,promise:u,receiver:this._receiverAt(s),value:t}):i.invoke(o,u,t);else{var c=this._receiverAt(s);"function"==typeof a?a.call(c,t,u):c instanceof r&&!c._isResolved()&&c._promiseProgressed(t,u)}}}}},{"./async.js":2,"./util.js":38}],23:[function(t,e){"use strict";e.exports=function(){function e(t){if("function"!=typeof t)throw new l("the promise constructor requires a resolver function\n\n    See http://goo.gl/EC22Yn\n");if(this.constructor!==e)throw new l("the promise constructor cannot be invoked directly\n\n    See http://goo.gl/KsIlge\n");this._bitField=0,this._fulfillmentHandler0=void 0,this._rejectionHandler0=void 0,this._progressHandler0=void 0,this._promise0=void 0,this._receiver0=void 0,this._settledValue=void 0,t!==h&&this._resolveFromResolver(t)}function r(t){var r=new e(h);r._fulfillmentHandler0=t,r._rejectionHandler0=t,r._progressHandler0=t,r._promise0=t,r._receiver0=t,r._settledValue=t}var n,i=function(){return new l("circular promise resolution chain\n\n    See http://goo.gl/LhFpo0\n")},o=function(){return new e.PromiseInspection(this._target())},s=function(t){return e.reject(new l(t))},a=t("./util.js");n=a.isNode?function(){var t=process.domain;return void 0===t&&(t=null),t}:function(){return null},a.notEnumerableProp(e,"_getDomain",n);var u=t("./async.js"),c=t("./errors.js"),l=e.TypeError=c.TypeError;e.RangeError=c.RangeError,e.CancellationError=c.CancellationError,e.TimeoutError=c.TimeoutError,e.OperationalError=c.OperationalError,e.RejectionError=c.OperationalError,e.AggregateError=c.AggregateError;var h=function(){},p={},f={e:null},_=t("./thenables.js")(e,h),d=t("./promise_array.js")(e,h,_,s),v=t("./captured_trace.js")(),y=t("./debuggability.js")(e,v),g=t("./context.js")(e,v,y),m=t("./catch_filter.js")(f),j=t("./promise_resolver.js"),b=j._nodebackForPromise,w=a.errorObj,k=a.tryCatch;return e.prototype.toString=function(){return"[object Promise]"},e.prototype.caught=e.prototype["catch"]=function(t){var r=arguments.length;if(r>1){var n,i=new Array(r-1),o=0;for(n=0;r-1>n;++n){var s=arguments[n];if("function"!=typeof s)return e.reject(new l("Catch filter must inherit from Error or be a simple predicate function\n\n    See http://goo.gl/o84o68\n"));i[o++]=s}i.length=o,t=arguments[n];var a=new m(i,t,this);return this._then(void 0,a.doFilter,void 0,a,void 0)}return this._then(void 0,t,void 0,void 0,void 0)},e.prototype.reflect=function(){return this._then(o,o,void 0,this,void 0)},e.prototype.then=function(t,e,r){if(y()&&arguments.length>0&&"function"!=typeof t&&"function"!=typeof e){var n=".then() only accepts functions but was passed: "+a.classString(t);arguments.length>1&&(n+=", "+a.classString(e)),this._warn(n)}return this._then(t,e,r,void 0,void 0)},e.prototype.done=function(t,e,r){var n=this._then(t,e,r,void 0,void 0);n._setIsFinal()},e.prototype.spread=function(t,e){return this.all()._then(t,e,void 0,p,void 0)
-},e.prototype.isCancellable=function(){return!this.isResolved()&&this._cancellable()},e.prototype.toJSON=function(){var t={isFulfilled:!1,isRejected:!1,fulfillmentValue:void 0,rejectionReason:void 0};return this.isFulfilled()?(t.fulfillmentValue=this.value(),t.isFulfilled=!0):this.isRejected()&&(t.rejectionReason=this.reason(),t.isRejected=!0),t},e.prototype.all=function(){return new d(this).promise()},e.prototype.error=function(t){return this.caught(a.originatesFromRejection,t)},e.is=function(t){return t instanceof e},e.fromNode=function(t){var r=new e(h),n=k(t)(b(r));return n===w&&r._rejectCallback(n.e,!0,!0),r},e.all=function(t){return new d(t).promise()},e.defer=e.pending=function(){var t=new e(h);return new j(t)},e.cast=function(t){var r=_(t);if(!(r instanceof e)){var n=r;r=new e(h),r._fulfillUnchecked(n)}return r},e.resolve=e.fulfilled=e.cast,e.reject=e.rejected=function(t){var r=new e(h);return r._captureStackTrace(),r._rejectCallback(t,!0),r},e.setScheduler=function(t){if("function"!=typeof t)throw new l("fn must be a function\n\n    See http://goo.gl/916lJJ\n");var e=u._schedule;return u._schedule=t,e},e.prototype._then=function(t,r,i,o,s){var a=void 0!==s,c=a?s:new e(h);a||(c._propagateFrom(this,5),c._captureStackTrace());var l=this._target();l!==this&&(void 0===o&&(o=this._boundTo),a||c._setIsMigrated());var p=l._addCallbacks(t,r,i,c,o,n());return l._isResolved()&&!l._isSettlePromisesQueued()&&u.invoke(l._settlePromiseAtPostResolution,l,p),c},e.prototype._settlePromiseAtPostResolution=function(t){this._isRejectionUnhandled()&&this._unsetRejectionIsUnhandled(),this._settlePromiseAt(t)},e.prototype._length=function(){return 131071&this._bitField},e.prototype._isFollowingOrFulfilledOrRejected=function(){return(939524096&this._bitField)>0},e.prototype._isFollowing=function(){return 536870912===(536870912&this._bitField)},e.prototype._setLength=function(t){this._bitField=-131072&this._bitField|131071&t},e.prototype._setFulfilled=function(){this._bitField=268435456|this._bitField},e.prototype._setRejected=function(){this._bitField=134217728|this._bitField},e.prototype._setFollowing=function(){this._bitField=536870912|this._bitField},e.prototype._setIsFinal=function(){this._bitField=33554432|this._bitField},e.prototype._isFinal=function(){return(33554432&this._bitField)>0},e.prototype._cancellable=function(){return(67108864&this._bitField)>0},e.prototype._setCancellable=function(){this._bitField=67108864|this._bitField},e.prototype._unsetCancellable=function(){this._bitField=-67108865&this._bitField},e.prototype._setIsMigrated=function(){this._bitField=4194304|this._bitField},e.prototype._unsetIsMigrated=function(){this._bitField=-4194305&this._bitField},e.prototype._isMigrated=function(){return(4194304&this._bitField)>0},e.prototype._receiverAt=function(t){var e=0===t?this._receiver0:this[5*t-5+4];return void 0===e&&this._isBound()?this._boundTo:e},e.prototype._promiseAt=function(t){return 0===t?this._promise0:this[5*t-5+3]},e.prototype._fulfillmentHandlerAt=function(t){return 0===t?this._fulfillmentHandler0:this[5*t-5+0]},e.prototype._rejectionHandlerAt=function(t){return 0===t?this._rejectionHandler0:this[5*t-5+1]},e.prototype._migrateCallbacks=function(t,r){var n=t._fulfillmentHandlerAt(r),i=t._rejectionHandlerAt(r),o=t._progressHandlerAt(r),s=t._promiseAt(r),a=t._receiverAt(r);s instanceof e&&s._setIsMigrated(),this._addCallbacks(n,i,o,s,a,null)},e.prototype._addCallbacks=function(t,e,r,n,i,o){var s=this._length();if(s>=131066&&(s=0,this._setLength(0)),0===s)this._promise0=n,void 0!==i&&(this._receiver0=i),"function"!=typeof t||this._isCarryingStackTrace()||(this._fulfillmentHandler0=null===o?t:o.bind(t)),"function"==typeof e&&(this._rejectionHandler0=null===o?e:o.bind(e)),"function"==typeof r&&(this._progressHandler0=null===o?r:o.bind(r));else{var a=5*s-5;this[a+3]=n,this[a+4]=i,"function"==typeof t&&(this[a+0]=null===o?t:o.bind(t)),"function"==typeof e&&(this[a+1]=null===o?e:o.bind(e)),"function"==typeof r&&(this[a+2]=null===o?r:o.bind(r))}return this._setLength(s+1),s},e.prototype._setProxyHandlers=function(t,e){var r=this._length();if(r>=131066&&(r=0,this._setLength(0)),0===r)this._promise0=e,this._receiver0=t;else{var n=5*r-5;this[n+3]=e,this[n+4]=t}this._setLength(r+1)},e.prototype._proxyPromiseArray=function(t,e){this._setProxyHandlers(t,e)},e.prototype._resolveCallback=function(t,r){if(!this._isFollowingOrFulfilledOrRejected()){if(t===this)return this._rejectCallback(i(),!1,!0);var n=_(t,this);if(!(n instanceof e))return this._fulfill(t);var o=1|(r?4:0);this._propagateFrom(n,o);var s=n._target();if(s._isPending()){for(var a=this._length(),u=0;a>u;++u)s._migrateCallbacks(this,u);this._setFollowing(),this._setLength(0),this._setFollowee(s)}else s._isFulfilled()?this._fulfillUnchecked(s._value()):this._rejectUnchecked(s._reason(),s._getCarriedStackTrace())}},e.prototype._rejectCallback=function(t,e,r){r||a.markAsOriginatingFromRejection(t);var n=a.ensureErrorObject(t),i=n===t;this._attachExtraTrace(n,e?i:!1),this._reject(t,i?void 0:n)},e.prototype._resolveFromResolver=function(t){var e=this;this._captureStackTrace(),this._pushContext();var r=!0,n=k(t)(function(t){null!==e&&(e._resolveCallback(t),e=null)},function(t){null!==e&&(e._rejectCallback(t,r),e=null)});r=!1,this._popContext(),void 0!==n&&n===w&&null!==e&&(e._rejectCallback(n.e,!0,!0),e=null)},e.prototype._settlePromiseFromHandler=function(t,e,r,n){if(!n._isRejected()){n._pushContext();var o;if(o=e!==p||this._isRejected()?k(t).call(e,r):k(t).apply(this._boundTo,r),n._popContext(),o===w||o===n||o===f){var s=o===n?i():o.e;n._rejectCallback(s,!1,!0)}else n._resolveCallback(o)}},e.prototype._target=function(){for(var t=this;t._isFollowing();)t=t._followee();return t},e.prototype._followee=function(){return this._rejectionHandler0},e.prototype._setFollowee=function(t){this._rejectionHandler0=t},e.prototype._cleanValues=function(){this._cancellable()&&(this._cancellationParent=void 0)},e.prototype._propagateFrom=function(t,e){(1&e)>0&&t._cancellable()&&(this._setCancellable(),this._cancellationParent=t),(4&e)>0&&t._isBound()&&this._setBoundTo(t._boundTo)},e.prototype._fulfill=function(t){this._isFollowingOrFulfilledOrRejected()||this._fulfillUnchecked(t)},e.prototype._reject=function(t,e){this._isFollowingOrFulfilledOrRejected()||this._rejectUnchecked(t,e)},e.prototype._settlePromiseAt=function(t){var r=this._promiseAt(t),n=r instanceof e;if(n&&r._isMigrated())return r._unsetIsMigrated(),u.invoke(this._settlePromiseAt,this,t);var i=this._isFulfilled()?this._fulfillmentHandlerAt(t):this._rejectionHandlerAt(t),o=this._isCarryingStackTrace()?this._getCarriedStackTrace():void 0,s=this._settledValue,a=this._receiverAt(t);this._clearCallbackDataAtIndex(t),"function"==typeof i?n?this._settlePromiseFromHandler(i,a,s,r):i.call(a,s,r):a instanceof d?a._isResolved()||(this._isFulfilled()?a._promiseFulfilled(s,r):a._promiseRejected(s,r)):n&&(this._isFulfilled()?r._fulfill(s):r._reject(s,o)),t>=4&&4===(31&t)&&u.invokeLater(this._setLength,this,0)},e.prototype._clearCallbackDataAtIndex=function(t){if(0===t)this._isCarryingStackTrace()||(this._fulfillmentHandler0=void 0),this._rejectionHandler0=this._progressHandler0=this._receiver0=this._promise0=void 0;else{var e=5*t-5;this[e+3]=this[e+4]=this[e+0]=this[e+1]=this[e+2]=void 0}},e.prototype._isSettlePromisesQueued=function(){return-1073741824===(-1073741824&this._bitField)},e.prototype._setSettlePromisesQueued=function(){this._bitField=-1073741824|this._bitField},e.prototype._unsetSettlePromisesQueued=function(){this._bitField=1073741823&this._bitField},e.prototype._queueSettlePromises=function(){u.settlePromises(this),this._setSettlePromisesQueued()},e.prototype._fulfillUnchecked=function(t){if(t===this){var e=i();return this._attachExtraTrace(e),this._rejectUnchecked(e,void 0)}this._setFulfilled(),this._settledValue=t,this._cleanValues(),this._length()>0&&this._queueSettlePromises()},e.prototype._rejectUncheckedCheckError=function(t){var e=a.ensureErrorObject(t);this._rejectUnchecked(t,e===t?void 0:e)},e.prototype._rejectUnchecked=function(t,e){if(t===this){var r=i();return this._attachExtraTrace(r),this._rejectUnchecked(r)}return this._setRejected(),this._settledValue=t,this._cleanValues(),this._isFinal()?void u.throwLater(function(t){throw"stack"in t&&u.invokeFirst(v.unhandledRejection,void 0,t),t},void 0===e?t:e):(void 0!==e&&e!==t&&this._setCarriedStackTrace(e),void(this._length()>0?this._queueSettlePromises():this._ensurePossibleRejectionHandled()))},e.prototype._settlePromises=function(){this._unsetSettlePromisesQueued();for(var t=this._length(),e=0;t>e;e++)this._settlePromiseAt(e)},a.notEnumerableProp(e,"_makeSelfResolutionError",i),t("./progress.js")(e,d),t("./method.js")(e,h,_,s),t("./bind.js")(e,h,_),t("./finally.js")(e,f,_),t("./direct_resolve.js")(e),t("./synchronous_inspection.js")(e),t("./join.js")(e,d,_,h),e.Promise=e,t("./map.js")(e,d,s,_,h),t("./cancel.js")(e),t("./using.js")(e,s,_,g),t("./generators.js")(e,s,h,_),t("./nodeify.js")(e),t("./call_get.js")(e),t("./props.js")(e,d,_,s),t("./race.js")(e,h,_,s),t("./reduce.js")(e,d,s,_,h),t("./settle.js")(e,d),t("./some.js")(e,d,s),t("./promisify.js")(e,h),t("./any.js")(e),t("./each.js")(e,h),t("./timers.js")(e,h),t("./filter.js")(e,h),a.toFastProperties(e),a.toFastProperties(e.prototype),r({a:1}),r({b:2}),r({c:3}),r(1),r(function(){}),r(void 0),r(!1),r(new e(h)),v.setBounds(u.firstLineError,a.lastLineError),e}},{"./any.js":1,"./async.js":2,"./bind.js":3,"./call_get.js":5,"./cancel.js":6,"./captured_trace.js":7,"./catch_filter.js":8,"./context.js":9,"./debuggability.js":10,"./direct_resolve.js":11,"./each.js":12,"./errors.js":13,"./filter.js":15,"./finally.js":16,"./generators.js":17,"./join.js":18,"./map.js":19,"./method.js":20,"./nodeify.js":21,"./progress.js":22,"./promise_array.js":24,"./promise_resolver.js":25,"./promisify.js":26,"./props.js":27,"./race.js":29,"./reduce.js":30,"./settle.js":32,"./some.js":33,"./synchronous_inspection.js":34,"./thenables.js":35,"./timers.js":36,"./using.js":37,"./util.js":38}],24:[function(t,e){"use strict";e.exports=function(e,r,n,i){function o(t){switch(t){case-2:return[];case-3:return{}}}function s(t){var n,i=this._promise=new e(r);t instanceof e&&(n=t,i._propagateFrom(n,5)),this._values=t,this._length=0,this._totalResolved=0,this._init(void 0,-2)}var a=t("./util.js"),u=a.isArray;return s.prototype.length=function(){return this._length},s.prototype.promise=function(){return this._promise},s.prototype._init=function c(t,r){var s=n(this._values,this._promise);if(s instanceof e){if(s=s._target(),this._values=s,!s._isFulfilled())return s._isPending()?void s._then(c,this._reject,void 0,this,r):void this._reject(s._reason());if(s=s._value(),!u(s)){var a=new e.TypeError("expecting an array, a promise or a thenable\n\n    See http://goo.gl/s8MMhc\n");return void this.__hardReject__(a)}}else if(!u(s))return void this._promise._reject(i("expecting an array, a promise or a thenable\n\n    See http://goo.gl/s8MMhc\n")._reason());if(0===s.length)return void(-5===r?this._resolveEmptyArray():this._resolve(o(r)));var l=this.getActualLength(s.length);this._length=l,this._values=this.shouldCopyValues()?new Array(l):this._values;for(var h=this._promise,p=0;l>p;++p){var f=this._isResolved(),_=n(s[p],h);_ instanceof e?(_=_._target(),f?_._ignoreRejections():_._isPending()?_._proxyPromiseArray(this,p):_._isFulfilled()?this._promiseFulfilled(_._value(),p):this._promiseRejected(_._reason(),p)):f||this._promiseFulfilled(_,p)}},s.prototype._isResolved=function(){return null===this._values},s.prototype._resolve=function(t){this._values=null,this._promise._fulfill(t)},s.prototype.__hardReject__=s.prototype._reject=function(t){this._values=null,this._promise._rejectCallback(t,!1,!0)},s.prototype._promiseProgressed=function(t,e){this._promise._progress({index:e,value:t})},s.prototype._promiseFulfilled=function(t,e){this._values[e]=t;var r=++this._totalResolved;r>=this._length&&this._resolve(this._values)},s.prototype._promiseRejected=function(t){this._totalResolved++,this._reject(t)},s.prototype.shouldCopyValues=function(){return!0},s.prototype.getActualLength=function(t){return t},s}},{"./util.js":38}],25:[function(t,e){"use strict";function r(t){return t instanceof Error&&p.getPrototypeOf(t)===Error.prototype}function n(t){var e;if(r(t)){e=new l(t),e.name=t.name,e.message=t.message,e.stack=t.stack;for(var n=p.keys(t),i=0;i<n.length;++i){var o=n[i];f.test(o)||(e[o]=t[o])}return e}return s.markAsOriginatingFromRejection(t),t}function i(t){return function(e,r){if(null!==t){if(e){var i=n(a(e));t._attachExtraTrace(i),t._reject(i)}else if(arguments.length>2){for(var o=arguments.length,s=new Array(o-1),u=1;o>u;++u)s[u-1]=arguments[u];t._fulfill(s)}else t._fulfill(r);t=null}}}var o,s=t("./util.js"),a=s.maybeWrapAsError,u=t("./errors.js"),c=u.TimeoutError,l=u.OperationalError,h=s.haveGetters,p=t("./es5.js"),f=/^(?:name|message|stack|cause)$/;if(o=h?function(t){this.promise=t}:function(t){this.promise=t,this.asCallback=i(t),this.callback=this.asCallback},h){var _={get:function(){return i(this.promise)}};p.defineProperty(o.prototype,"asCallback",_),p.defineProperty(o.prototype,"callback",_)}o._nodebackForPromise=i,o.prototype.toString=function(){return"[object PromiseResolver]"},o.prototype.resolve=o.prototype.fulfill=function(t){if(!(this instanceof o))throw new TypeError("Illegal invocation, resolver resolve/reject must be called within a resolver context. Consider using the promise constructor instead.\n\n    See http://goo.gl/sdkXL9\n");this.promise._resolveCallback(t)},o.prototype.reject=function(t){if(!(this instanceof o))throw new TypeError("Illegal invocation, resolver resolve/reject must be called within a resolver context. Consider using the promise constructor instead.\n\n    See http://goo.gl/sdkXL9\n");this.promise._rejectCallback(t)},o.prototype.progress=function(t){if(!(this instanceof o))throw new TypeError("Illegal invocation, resolver resolve/reject must be called within a resolver context. Consider using the promise constructor instead.\n\n    See http://goo.gl/sdkXL9\n");this.promise._progress(t)},o.prototype.cancel=function(t){this.promise.cancel(t)},o.prototype.timeout=function(){this.reject(new c("timeout"))},o.prototype.isResolved=function(){return this.promise.isResolved()},o.prototype.toJSON=function(){return this.promise.toJSON()},e.exports=o},{"./errors.js":13,"./es5.js":14,"./util.js":38}],26:[function(t,e){"use strict";e.exports=function(e,r){function n(t){return!w.test(t)}function i(t){try{return t.__isPromisified__===!0}catch(e){return!1}}function o(t,e,r){var n=f.getDataPropertyOrDefault(t,e+r,j);return n?i(n):!1}function s(t,e,r){for(var n=0;n<t.length;n+=2){var i=t[n];if(r.test(i))for(var o=i.replace(r,""),s=0;s<t.length;s+=2)if(t[s]===o)throw new g("Cannot promisify an API that has normal methods with '%s'-suffix\n\n    See http://goo.gl/iWrZbw\n".replace("%s",e))}}function a(t,e,r,n){for(var a=f.inheritedDataKeys(t),u=[],c=0;c<a.length;++c){var l=a[c],h=t[l],p=n===k?!0:k(l,h,t);"function"!=typeof h||i(h)||o(t,l,e)||!n(l,h,t,p)||u.push(l,h)}return s(u,e,r),u}function u(t,n,i,o){function s(){var i=n;n===p&&(i=this);var o=new e(r);o._captureStackTrace();var s="string"==typeof u&&this!==a?this[u]:t,c=_(o);try{s.apply(i,d(arguments,c))}catch(l){o._rejectCallback(v(l),!0,!0)}return o}var a=function(){return this}(),u=t;return"string"==typeof u&&(t=o),f.notEnumerableProp(s,"__isPromisified__",!0),s}function c(t,e,r,n){for(var i=new RegExp(E(e)+"$"),o=a(t,e,i,r),s=0,u=o.length;u>s;s+=2){var c=o[s],l=o[s+1],h=c+e;t[h]=n===F?F(c,p,c,l,e):n(l,function(){return F(c,p,c,l,e)})}return f.toFastProperties(t),t}function l(t,e){return F(t,e,void 0,t)}var h,p={},f=t("./util.js"),_=t("./promise_resolver.js")._nodebackForPromise,d=f.withAppended,v=f.maybeWrapAsError,y=f.canEvaluate,g=t("./errors").TypeError,m="Async",j={__isPromisified__:!0},b=["arity","length","name","arguments","caller","callee","prototype","__isPromisified__"],w=new RegExp("^(?:"+b.join("|")+")$"),k=function(t){return f.isIdentifier(t)&&"_"!==t.charAt(0)&&"constructor"!==t},E=function(t){return t.replace(/([$])/,"\\$")},F=y?h:u;e.promisify=function(t,e){if("function"!=typeof t)throw new g("fn must be a function\n\n    See http://goo.gl/916lJJ\n");if(i(t))return t;var r=l(t,arguments.length<2?p:e);return f.copyDescriptors(t,r,n),r},e.promisifyAll=function(t,e){if("function"!=typeof t&&"object"!=typeof t)throw new g("the target of promisifyAll must be an object or a function\n\n    See http://goo.gl/9ITlV0\n");e=Object(e);var r=e.suffix;"string"!=typeof r&&(r=m);var n=e.filter;"function"!=typeof n&&(n=k);var i=e.promisifier;if("function"!=typeof i&&(i=F),!f.isIdentifier(r))throw new RangeError("suffix must be a valid identifier\n\n    See http://goo.gl/8FZo5V\n");for(var o=f.inheritedDataKeys(t),s=0;s<o.length;++s){var a=t[o[s]];"constructor"!==o[s]&&f.isClass(a)&&(c(a.prototype,r,n,i),c(a,r,n,i))}return c(t,r,n,i)}}},{"./errors":13,"./promise_resolver.js":25,"./util.js":38}],27:[function(t,e){"use strict";e.exports=function(e,r,n,i){function o(t){for(var e=c.keys(t),r=e.length,n=new Array(2*r),i=0;r>i;++i){var o=e[i];n[i]=t[o],n[i+r]=o}this.constructor$(n)}function s(t){var r,s=n(t);return u(s)?(r=s instanceof e?s._then(e.props,void 0,void 0,void 0,void 0):new o(s).promise(),s instanceof e&&r._propagateFrom(s,4),r):i("cannot await properties of a non-object\n\n    See http://goo.gl/OsFKC8\n")}var a=t("./util.js"),u=a.isObject,c=t("./es5.js");a.inherits(o,r),o.prototype._init=function(){this._init$(void 0,-3)},o.prototype._promiseFulfilled=function(t,e){this._values[e]=t;var r=++this._totalResolved;if(r>=this._length){for(var n={},i=this.length(),o=0,s=this.length();s>o;++o)n[this._values[o+i]]=this._values[o];this._resolve(n)}},o.prototype._promiseProgressed=function(t,e){this._promise._progress({key:this._values[e+this.length()],value:t})},o.prototype.shouldCopyValues=function(){return!1},o.prototype.getActualLength=function(t){return t>>1},e.prototype.props=function(){return s(this)},e.props=function(t){return s(t)}}},{"./es5.js":14,"./util.js":38}],28:[function(t,e){"use strict";function r(t,e,r,n,i){for(var o=0;i>o;++o)r[o+n]=t[o+e],t[o+e]=void 0}function n(t){this._capacity=t,this._length=0,this._front=0}n.prototype._willBeOverCapacity=function(t){return this._capacity<t},n.prototype._pushOne=function(t){var e=this.length();this._checkCapacity(e+1);var r=this._front+e&this._capacity-1;this[r]=t,this._length=e+1},n.prototype._unshiftOne=function(t){var e=this._capacity;this._checkCapacity(this.length()+1);var r=this._front,n=(r-1&e-1^e)-e;this[n]=t,this._front=n,this._length=this.length()+1},n.prototype.unshift=function(t,e,r){this._unshiftOne(r),this._unshiftOne(e),this._unshiftOne(t)},n.prototype.push=function(t,e,r){var n=this.length()+3;if(this._willBeOverCapacity(n))return this._pushOne(t),this._pushOne(e),void this._pushOne(r);var i=this._front+n-3;this._checkCapacity(n);var o=this._capacity-1;this[i+0&o]=t,this[i+1&o]=e,this[i+2&o]=r,this._length=n},n.prototype.shift=function(){var t=this._front,e=this[t];return this[t]=void 0,this._front=t+1&this._capacity-1,this._length--,e},n.prototype.length=function(){return this._length},n.prototype._checkCapacity=function(t){this._capacity<t&&this._resizeTo(this._capacity<<1)},n.prototype._resizeTo=function(t){var e=this._capacity;this._capacity=t;var n=this._front,i=this._length,o=n+i&e-1;r(this,0,this,e,o)},e.exports=n},{}],29:[function(t,e){"use strict";e.exports=function(e,r,n,i){function o(t,o){var u=n(t);if(u instanceof e)return a(u);if(!s(t))return i("expecting an array, a promise or a thenable\n\n    See http://goo.gl/s8MMhc\n");var c=new e(r);void 0!==o&&c._propagateFrom(o,5);for(var l=c._fulfill,h=c._reject,p=0,f=t.length;f>p;++p){var _=t[p];(void 0!==_||p in t)&&e.cast(_)._then(l,h,void 0,c,null)}return c}var s=t("./util.js").isArray,a=function(t){return t.then(function(e){return o(e,t)})};e.race=function(t){return o(t,void 0)},e.prototype.race=function(){return o(this,void 0)}}},{"./util.js":38}],30:[function(t,e){"use strict";e.exports=function(e,r,n,i,o){function s(t,r,n,s){this.constructor$(t),this._promise._captureStackTrace(),this._preservedValues=s===o?[]:null,this._zerothIsAccum=void 0===n,this._gotAccum=!1,this._reducingIndex=this._zerothIsAccum?1:0,this._valuesPhase=void 0;var u=i(n,this._promise),l=!1,h=u instanceof e;h&&(u=u._target(),u._isPending()?u._proxyPromiseArray(this,-1):u._isFulfilled()?(n=u._value(),this._gotAccum=!0):(this._reject(u._reason()),l=!0)),h||this._zerothIsAccum||(this._gotAccum=!0),this._callback=r,this._accum=n,l||c.invoke(a,this,void 0)}function a(){this._init$(void 0,-5)}function u(t,e,r,i){if("function"!=typeof e)return n("fn must be a function\n\n    See http://goo.gl/916lJJ\n");var o=new s(t,e,r,i);return o.promise()}var c=t("./async.js"),l=t("./util.js"),h=l.tryCatch,p=l.errorObj;l.inherits(s,r),s.prototype._init=function(){},s.prototype._resolveEmptyArray=function(){(this._gotAccum||this._zerothIsAccum)&&this._resolve(null!==this._preservedValues?[]:this._accum)},s.prototype._promiseFulfilled=function(t,r){var n=this._values;n[r]=t;var o,s=this.length(),a=this._preservedValues,u=null!==a,c=this._gotAccum,l=this._valuesPhase;if(!l)for(l=this._valuesPhase=new Array(s),o=0;s>o;++o)l[o]=0;if(o=l[r],0===r&&this._zerothIsAccum?(this._accum=t,this._gotAccum=c=!0,l[r]=0===o?1:2):-1===r?(this._accum=t,this._gotAccum=c=!0):0===o?l[r]=1:(l[r]=2,this._accum=t),c){for(var f,_=this._callback,d=this._promise._boundTo,v=this._reducingIndex;s>v;++v)if(o=l[v],2!==o){if(1!==o)return;if(t=n[v],this._promise._pushContext(),u?(a.push(t),f=h(_).call(d,t,v,s)):f=h(_).call(d,this._accum,t,v,s),this._promise._popContext(),f===p)return this._reject(f.e);var y=i(f,this._promise);if(y instanceof e){if(y=y._target(),y._isPending())return l[v]=4,y._proxyPromiseArray(this,v);if(!y._isFulfilled())return this._reject(y._reason());f=y._value()}this._reducingIndex=v+1,this._accum=f}else this._reducingIndex=v+1;this._resolve(u?a:this._accum)}},e.prototype.reduce=function(t,e){return u(this,t,e,null)},e.reduce=function(t,e,r,n){return u(t,e,r,n)}}},{"./async.js":2,"./util.js":38}],31:[function(t,e){"use strict";var r,n=t("./util"),i=function(){throw new Error("No async scheduler available\n\n    See http://goo.gl/m3OTXk\n")};if(n.isNode&&"undefined"==typeof MutationObserver){var o=global.setImmediate,s=process.nextTick;r=n.isRecentNode?function(t){o.call(global,t)}:function(t){s.call(process,t)}}else"undefined"==typeof MutationObserver||"undefined"!=typeof window&&window.navigator&&window.navigator.standalone?r="undefined"!=typeof setImmediate?function(t){setImmediate(t)}:"undefined"!=typeof setTimeout?function(t){setTimeout(t,0)}:i:(r=function(t){var e=document.createElement("div"),r=new MutationObserver(t);return r.observe(e,{attributes:!0}),function(){e.classList.toggle("foo")}},r.isStatic=!0);e.exports=r},{"./util":38}],32:[function(t,e){"use strict";e.exports=function(e,r){function n(t){this.constructor$(t)}var i=e.PromiseInspection,o=t("./util.js");o.inherits(n,r),n.prototype._promiseResolved=function(t,e){this._values[t]=e;var r=++this._totalResolved;r>=this._length&&this._resolve(this._values)},n.prototype._promiseFulfilled=function(t,e){var r=new i;r._bitField=268435456,r._settledValue=t,this._promiseResolved(e,r)},n.prototype._promiseRejected=function(t,e){var r=new i;r._bitField=134217728,r._settledValue=t,this._promiseResolved(e,r)},e.settle=function(t){return new n(t).promise()},e.prototype.settle=function(){return new n(this).promise()}}},{"./util.js":38}],33:[function(t,e){"use strict";e.exports=function(e,r,n){function i(t){this.constructor$(t),this._howMany=0,this._unwrap=!1,this._initialized=!1}function o(t,e){if((0|e)!==e||0>e)return n("expecting a positive integer\n\n    See http://goo.gl/1wAmHx\n");var r=new i(t),o=r.promise();return r.setHowMany(e),r.init(),o}var s=t("./util.js"),a=t("./errors.js").RangeError,u=t("./errors.js").AggregateError,c=s.isArray;s.inherits(i,r),i.prototype._init=function(){if(this._initialized){if(0===this._howMany)return void this._resolve([]);this._init$(void 0,-5);var t=c(this._values);!this._isResolved()&&t&&this._howMany>this._canPossiblyFulfill()&&this._reject(this._getRangeError(this.length()))}},i.prototype.init=function(){this._initialized=!0,this._init()},i.prototype.setUnwrap=function(){this._unwrap=!0},i.prototype.howMany=function(){return this._howMany},i.prototype.setHowMany=function(t){this._howMany=t},i.prototype._promiseFulfilled=function(t){this._addFulfilled(t),this._fulfilled()===this.howMany()&&(this._values.length=this.howMany(),this._resolve(1===this.howMany()&&this._unwrap?this._values[0]:this._values))},i.prototype._promiseRejected=function(t){if(this._addRejected(t),this.howMany()>this._canPossiblyFulfill()){for(var e=new u,r=this.length();r<this._values.length;++r)e.push(this._values[r]);this._reject(e)}},i.prototype._fulfilled=function(){return this._totalResolved},i.prototype._rejected=function(){return this._values.length-this.length()},i.prototype._addRejected=function(t){this._values.push(t)},i.prototype._addFulfilled=function(t){this._values[this._totalResolved++]=t},i.prototype._canPossiblyFulfill=function(){return this.length()-this._rejected()},i.prototype._getRangeError=function(t){var e="Input array must contain at least "+this._howMany+" items but contains only "+t+" items";return new a(e)},i.prototype._resolveEmptyArray=function(){this._reject(this._getRangeError(0))},e.some=function(t,e){return o(t,e)},e.prototype.some=function(t){return o(this,t)},e._SomePromiseArray=i}},{"./errors.js":13,"./util.js":38}],34:[function(t,e){"use strict";e.exports=function(t){function e(t){void 0!==t?(t=t._target(),this._bitField=t._bitField,this._settledValue=t._settledValue):(this._bitField=0,this._settledValue=void 0)}e.prototype.value=function(){if(!this.isFulfilled())throw new TypeError("cannot get fulfillment value of a non-fulfilled promise\n\n    See http://goo.gl/hc1DLj\n");return this._settledValue},e.prototype.error=e.prototype.reason=function(){if(!this.isRejected())throw new TypeError("cannot get rejection reason of a non-rejected promise\n\n    See http://goo.gl/hPuiwB\n");return this._settledValue},e.prototype.isFulfilled=t.prototype._isFulfilled=function(){return(268435456&this._bitField)>0},e.prototype.isRejected=t.prototype._isRejected=function(){return(134217728&this._bitField)>0},e.prototype.isPending=t.prototype._isPending=function(){return 0===(402653184&this._bitField)},e.prototype.isResolved=t.prototype._isResolved=function(){return(402653184&this._bitField)>0},t.prototype.isPending=function(){return this._target()._isPending()},t.prototype.isRejected=function(){return this._target()._isRejected()},t.prototype.isFulfilled=function(){return this._target()._isFulfilled()},t.prototype.isResolved=function(){return this._target()._isResolved()},t.prototype._value=function(){return this._settledValue},t.prototype._reason=function(){return this._unsetRejectionIsUnhandled(),this._settledValue},t.prototype.value=function(){var t=this._target();if(!t.isFulfilled())throw new TypeError("cannot get fulfillment value of a non-fulfilled promise\n\n    See http://goo.gl/hc1DLj\n");return t._settledValue},t.prototype.reason=function(){var t=this._target();if(!t.isRejected())throw new TypeError("cannot get rejection reason of a non-rejected promise\n\n    See http://goo.gl/hPuiwB\n");return t._unsetRejectionIsUnhandled(),t._settledValue},t.PromiseInspection=e}},{}],35:[function(t,e){"use strict";e.exports=function(e,r){function n(t,n){if(c(t)){if(t instanceof e)return t;if(o(t)){var l=new e(r);return t._then(l._fulfillUnchecked,l._rejectUncheckedCheckError,l._progressUnchecked,l,null),l}var h=a.tryCatch(i)(t);if(h===u){n&&n._pushContext();var l=e.reject(h.e);return n&&n._popContext(),l}if("function"==typeof h)return s(t,h,n)}return t}function i(t){return t.then}function o(t){return l.call(t,"_promise0")}function s(t,n,i){function o(t){l&&(l._resolveCallback(t),l=null)}function s(t){l&&(l._rejectCallback(t,p,!0),l=null)}function c(t){l&&"function"==typeof l._progress&&l._progress(t)}var l=new e(r),h=l;i&&i._pushContext(),l._captureStackTrace(),i&&i._popContext();var p=!0,f=a.tryCatch(n).call(t,o,s,c);return p=!1,l&&f===u&&(l._rejectCallback(f.e,!0,!0),l=null),h}var a=t("./util.js"),u=a.errorObj,c=a.isObject,l={}.hasOwnProperty;return n}},{"./util.js":38}],36:[function(t,e){"use strict";e.exports=function(e,r){function n(t){var e=this;return e instanceof Number&&(e=+e),clearTimeout(e),t}function i(t){var e=this;throw e instanceof Number&&(e=+e),clearTimeout(e),t}var o=t("./util.js"),s=e.TimeoutError,a=function(t,e){if(t.isPending()){"string"!=typeof e&&(e="operation timed out");var r=new s(e);o.markAsOriginatingFromRejection(r),t._attachExtraTrace(r),t._cancel(r)}},u=function(t){return c(+this).thenReturn(t)},c=e.delay=function(t,n){if(void 0===n){n=t,t=void 0;var i=new e(r);return setTimeout(function(){i._fulfill()},n),i}return n=+n,e.resolve(t)._then(u,null,null,n,void 0)};e.prototype.delay=function(t){return c(this,t)},e.prototype.timeout=function(t,e){t=+t;var r=this.then().cancellable();r._cancellationParent=this;var o=setTimeout(function(){a(r,e)},t);return r._then(n,i,void 0,o,void 0)}}},{"./util.js":38}],37:[function(t,e){"use strict";e.exports=function(e,r,n,i){function o(t){for(var r=t.length,n=0;r>n;++n){var i=t[n];if(i.isRejected())return e.reject(i.error());t[n]=i._settledValue}return t}function s(t){setTimeout(function(){throw t},0)}function a(t){var e=n(t);return e!==t&&"function"==typeof t._isDisposable&&"function"==typeof t._getDisposer&&t._isDisposable()&&e._setDisposable(t._getDisposer()),e}function u(t,r){function i(){if(o>=u)return c.resolve();var l=a(t[o++]);if(l instanceof e&&l._isDisposable()){try{l=n(l._getDisposer().tryDispose(r),t.promise)}catch(h){return s(h)}if(l instanceof e)return l._then(i,s,null,null,null)}i()}var o=0,u=t.length,c=e.defer();return i(),c.promise}function c(t){var e=new v;return e._settledValue=t,e._bitField=268435456,u(this,e).thenReturn(t)}function l(t){var e=new v;return e._settledValue=t,e._bitField=134217728,u(this,e).thenThrow(t)}function h(t,e,r){this._data=t,this._promise=e,this._context=r}function p(t,e,r){this.constructor$(t,e,r)}function f(t){return h.isDisposer(t)?(this.resources[this.index]._setDisposable(t),t.promise()):t}var _=t("./errors.js").TypeError,d=t("./util.js").inherits,v=e.PromiseInspection;h.prototype.data=function(){return this._data},h.prototype.promise=function(){return this._promise},h.prototype.resource=function(){return this.promise().isFulfilled()?this.promise().value():null},h.prototype.tryDispose=function(t){var e=this.resource(),r=this._context;void 0!==r&&r._pushContext();var n=null!==e?this.doDispose(e,t):null;return void 0!==r&&r._popContext(),this._promise._unsetDisposable(),this._data=null,n},h.isDisposer=function(t){return null!=t&&"function"==typeof t.resource&&"function"==typeof t.tryDispose},d(p,h),p.prototype.doDispose=function(t,e){var r=this.data();return r.call(t,t,e)},e.using=function(){var t=arguments.length;if(2>t)return r("you must pass at least 2 arguments to Promise.using");var i=arguments[t-1];if("function"!=typeof i)return r("fn must be a function\n\n    See http://goo.gl/916lJJ\n");t--;for(var s=new Array(t),a=0;t>a;++a){var u=arguments[a];if(h.isDisposer(u)){var p=u;u=u.promise(),u._setDisposable(p)}else{var _=n(u);_ instanceof e&&(u=_._then(f,null,null,{resources:s,index:a},void 0))}s[a]=u}var d=e.settle(s).then(o).then(function(t){d._pushContext();var e;try{e=i.apply(void 0,t)}finally{d._popContext()}return e})._then(c,l,void 0,s,void 0);return s.promise=d,d},e.prototype._setDisposable=function(t){this._bitField=262144|this._bitField,this._disposer=t},e.prototype._isDisposable=function(){return(262144&this._bitField)>0},e.prototype._getDisposer=function(){return this._disposer},e.prototype._unsetDisposable=function(){this._bitField=-262145&this._bitField,this._disposer=void 0
-},e.prototype.disposer=function(t){if("function"==typeof t)return new p(t,this,i());throw new _}}},{"./errors.js":13,"./util.js":38}],38:[function(t,e,r){"use strict";function n(){try{var t=C;return C=null,t.apply(this,arguments)}catch(e){return F.e=e,F}}function i(t){return C=t,n}function o(t){return null==t||t===!0||t===!1||"string"==typeof t||"number"==typeof t}function s(t){return!o(t)}function a(t){return o(t)?new Error(v(t)):t}function u(t,e){var r,n=t.length,i=new Array(n+1);for(r=0;n>r;++r)i[r]=t[r];return i[r]=e,i}function c(t,e,r){if(!w.isES5)return{}.hasOwnProperty.call(t,e)?t[e]:void 0;var n=Object.getOwnPropertyDescriptor(t,e);return null!=n?null==n.get&&null==n.set?n.value:r:void 0}function l(t,e,r){if(o(t))return t;var n={value:r,configurable:!0,enumerable:!1,writable:!0};return w.defineProperty(t,e,n),t}function h(t){throw t}function p(t){try{if("function"==typeof t){var e=w.names(t.prototype),r=w.isES5&&e.length>1,n=e.length>0&&!(1===e.length&&"constructor"===e[0]),i=x.test(t+"")&&w.names(t).length>0;if(r||n||i)return!0}return!1}catch(o){return!1}}function f(t){function e(){}e.prototype=t;for(var r=8;r--;)new e;return t}function _(t){return R.test(t)}function d(t,e,r){for(var n=new Array(t),i=0;t>i;++i)n[i]=e+i+r;return n}function v(t){try{return t+""}catch(e){return"[no string representation]"}}function y(t){try{l(t,"isOperational",!0)}catch(e){}}function g(t){return null==t?!1:t instanceof Error.__BluebirdErrorTypes__.OperationalError||t.isOperational===!0}function m(t){return t instanceof Error&&w.propertyIsWritable(t,"stack")}function j(t){return{}.toString.call(t)}function b(t,e,r){for(var n=w.names(t),i=0;i<n.length;++i){var o=n[i];if(r(o))try{w.defineProperty(e,o,w.getDescriptor(t,o))}catch(s){}}}var w=t("./es5.js"),k="undefined"==typeof navigator,E=function(){try{var t={};return w.defineProperty(t,"f",{get:function(){return 3}}),3===t.f}catch(e){return!1}}(),F={e:{}},C,T=function(t,e){function r(){this.constructor=t,this.constructor$=e;for(var r in e.prototype)n.call(e.prototype,r)&&"$"!==r.charAt(r.length-1)&&(this[r+"$"]=e.prototype[r])}var n={}.hasOwnProperty;return r.prototype=e.prototype,t.prototype=new r,t.prototype},P=function(){var t=[Array.prototype,Object.prototype,Function.prototype],e=function(e){for(var r=0;r<t.length;++r)if(t[r]===e)return!0;return!1};if(w.isES5){var r=Object.getOwnPropertyNames;return function(t){for(var n=[],i=Object.create(null);null!=t&&!e(t);){var o;try{o=r(t)}catch(s){return n}for(var a=0;a<o.length;++a){var u=o[a];if(!i[u]){i[u]=!0;var c=Object.getOwnPropertyDescriptor(t,u);null!=c&&null==c.get&&null==c.set&&n.push(u)}}t=w.getPrototypeOf(t)}return n}}var n={}.hasOwnProperty;return function(r){if(e(r))return[];var i=[];t:for(var o in r)if(n.call(r,o))i.push(o);else{for(var s=0;s<t.length;++s)if(n.call(t[s],o))continue t;i.push(o)}return i}}(),x=/this\s*\.\s*\S+\s*=/,R=/^[a-z$_][a-z$_0-9]*$/i,S=function(){return"stack"in new Error?function(t){return m(t)?t:new Error(v(t))}:function(t){if(m(t))return t;try{throw new Error(v(t))}catch(e){return e}}}(),A={isClass:p,isIdentifier:_,inheritedDataKeys:P,getDataPropertyOrDefault:c,thrower:h,isArray:w.isArray,haveGetters:E,notEnumerableProp:l,isPrimitive:o,isObject:s,canEvaluate:k,errorObj:F,tryCatch:i,inherits:T,withAppended:u,maybeWrapAsError:a,toFastProperties:f,filledRange:d,toString:v,canAttachTrace:m,ensureErrorObject:S,originatesFromRejection:g,markAsOriginatingFromRejection:y,classString:j,copyDescriptors:b,hasDevTools:"undefined"!=typeof chrome&&chrome&&"function"==typeof chrome.loadTimes,isNode:"undefined"!=typeof process&&"[object process]"===j(process).toLowerCase()};A.isRecentNode=A.isNode&&function(){var t=process.versions.node.split(".").map(Number);return 0===t[0]&&t[1]>10||t[0]>0}(),A.isNode&&A.toFastProperties(process);try{throw new Error}catch(O){A.lastLineError=O}e.exports=A},{"./es5.js":14}]},{},[4])(4)}),"undefined"!=typeof window&&null!==window?window.P=window.Promise:"undefined"!=typeof self&&null!==self&&(self.P=self.Promise);
\ No newline at end of file
+!function(t){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var e;"undefined"!=typeof window?e=window:"undefined"!=typeof global?e=global:"undefined"!=typeof self&&(e=self),e.Promise=t()}}(function(){var t,e,r;return function n(t,e,r){function i(s,a){if(!e[s]){if(!t[s]){var u="function"==typeof _dereq_&&_dereq_;if(!a&&u)return u(s,!0);if(o)return o(s,!0);var c=new Error("Cannot find module '"+s+"'");throw c.code="MODULE_NOT_FOUND",c}var l=e[s]={exports:{}};t[s][0].call(l.exports,function(e){var r=t[s][1][e];return i(r?r:e)},l,l.exports,n,t,e,r)}return e[s].exports}for(var o="function"==typeof _dereq_&&_dereq_,s=0;s<r.length;s++)i(r[s]);return i}({1:[function(t,e){"use strict";e.exports=function(t){function e(t){var e=new r(t),n=e.promise();return e.setHowMany(1),e.setUnwrap(),e.init(),n}var r=t._SomePromiseArray;t.any=function(t){return e(t)},t.prototype.any=function(){return e(this)}}},{}],2:[function(t,e){"use strict";function r(){this._isTickUsed=!1,this._lateQueue=new c(16),this._normalQueue=new c(16),this._trampolineEnabled=!0;var t=this;this.drainQueues=function(){t._drainQueues()},this._schedule=u.isStatic?u(this.drainQueues):u}function n(t,e,r){this._lateQueue.push(t,e,r),this._queueTick()}function i(t,e,r){this._normalQueue.push(t,e,r),this._queueTick()}function o(t){this._normalQueue._pushOne(t),this._queueTick()}var s;try{throw new Error}catch(a){s=a}var u=t("./schedule.js"),c=t("./queue.js"),l=t("./util.js");r.prototype.disableTrampolineIfNecessary=function(){l.hasDevTools&&(this._trampolineEnabled=!1)},r.prototype.enableTrampoline=function(){this._trampolineEnabled||(this._trampolineEnabled=!0,this._schedule=function(t){setTimeout(t,0)})},r.prototype.haveItemsQueued=function(){return this._normalQueue.length()>0},r.prototype.throwLater=function(t,e){if(1===arguments.length&&(e=t,t=function(){throw e}),"undefined"!=typeof setTimeout)setTimeout(function(){t(e)},0);else try{this._schedule(function(){t(e)})}catch(r){throw new Error("No async scheduler available\n\n    See http://goo.gl/m3OTXk\n")}},l.hasDevTools?(u.isStatic&&(u=function(t){setTimeout(t,0)}),r.prototype.invokeLater=function(t,e,r){this._trampolineEnabled?n.call(this,t,e,r):this._schedule(function(){setTimeout(function(){t.call(e,r)},100)})},r.prototype.invoke=function(t,e,r){this._trampolineEnabled?i.call(this,t,e,r):this._schedule(function(){t.call(e,r)})},r.prototype.settlePromises=function(t){this._trampolineEnabled?o.call(this,t):this._schedule(function(){t._settlePromises()})}):(r.prototype.invokeLater=n,r.prototype.invoke=i,r.prototype.settlePromises=o),r.prototype.invokeFirst=function(t,e,r){this._normalQueue.unshift(t,e,r),this._queueTick()},r.prototype._drainQueue=function(t){for(;t.length()>0;){var e=t.shift();if("function"==typeof e){var r=t.shift(),n=t.shift();e.call(r,n)}else e._settlePromises()}},r.prototype._drainQueues=function(){this._drainQueue(this._normalQueue),this._reset(),this._drainQueue(this._lateQueue)},r.prototype._queueTick=function(){this._isTickUsed||(this._isTickUsed=!0,this._schedule(this.drainQueues))},r.prototype._reset=function(){this._isTickUsed=!1},e.exports=new r,e.exports.firstLineError=s},{"./queue.js":28,"./schedule.js":31,"./util.js":38}],3:[function(t,e){"use strict";e.exports=function(t,e,r){var n=function(t,e){this._reject(e)},i=function(t,e){e.promiseRejectionQueued=!0,e.bindingPromise._then(n,n,null,this,t)},o=function(t,e){this._isPending()&&this._resolveCallback(e.target)},s=function(t,e){e.promiseRejectionQueued||this._reject(t)};t.prototype.bind=function(n){var a=r(n),u=new t(e);u._propagateFrom(this,1);var c=this._target();if(u._setBoundTo(a),a instanceof t){var l={promiseRejectionQueued:!1,promise:u,target:c,bindingPromise:a};c._then(e,i,u._progress,u,l),a._then(o,s,u._progress,u,l)}else u._resolveCallback(c);return u},t.prototype._setBoundTo=function(t){void 0!==t?(this._bitField=131072|this._bitField,this._boundTo=t):this._bitField=-131073&this._bitField},t.prototype._isBound=function(){return 131072===(131072&this._bitField)},t.bind=function(n,i){var o=r(n),s=new t(e);return s._setBoundTo(o),o instanceof t?o._then(function(){s._resolveCallback(i)},s._reject,s._progress,s,null):s._resolveCallback(i),s}}},{}],4:[function(t,e){"use strict";function r(){try{Promise===i&&(Promise=n)}catch(t){}return i}var n;"undefined"!=typeof Promise&&(n=Promise);var i=t("./promise.js")();i.noConflict=r,e.exports=i},{"./promise.js":23}],5:[function(t,e){"use strict";var r=Object.create;if(r){var n=r(null),i=r(null);n[" size"]=i[" size"]=0}e.exports=function(e){function r(t,r){var n;if(null!=t&&(n=t[r]),"function"!=typeof n){var i="Object "+a.classString(t)+" has no method '"+a.toString(r)+"'";throw new e.TypeError(i)}return n}function n(t){var e=this.pop(),n=r(t,e);return n.apply(t,this)}function i(t){return t[this]}function o(t){var e=+this;return 0>e&&(e=Math.max(0,e+t.length)),t[e]}{var s,a=t("./util.js"),u=a.canEvaluate;a.isIdentifier}e.prototype.call=function(t){for(var e=arguments.length,r=new Array(e-1),i=1;e>i;++i)r[i-1]=arguments[i];return r.push(t),this._then(n,void 0,void 0,r,void 0)},e.prototype.get=function(t){var e,r="number"==typeof t;if(r)e=o;else if(u){var n=s(t);e=null!==n?n:i}else e=i;return this._then(e,void 0,void 0,t,void 0)}}},{"./util.js":38}],6:[function(t,e){"use strict";e.exports=function(e){var r=t("./errors.js"),n=t("./async.js"),i=r.CancellationError;e.prototype._cancel=function(t){if(!this.isCancellable())return this;for(var e,r=this;void 0!==(e=r._cancellationParent)&&e.isCancellable();)r=e;this._unsetCancellable(),r._target()._rejectCallback(t,!1,!0)},e.prototype.cancel=function(t){return this.isCancellable()?(void 0===t&&(t=new i),n.invokeLater(this._cancel,this,t),this):this},e.prototype.cancellable=function(){return this._cancellable()?this:(n.enableTrampoline(),this._setCancellable(),this._cancellationParent=void 0,this)},e.prototype.uncancellable=function(){var t=this.then();return t._unsetCancellable(),t},e.prototype.fork=function(t,e,r){var n=this._then(t,e,r,void 0,void 0);return n._setCancellable(),n._cancellationParent=void 0,n}}},{"./async.js":2,"./errors.js":13}],7:[function(t,e){"use strict";e.exports=function(){function e(t){this._parent=t;var r=this._length=1+(void 0===t?0:t._length);j(this,e),r>32&&this.uncycle()}function r(t,e){for(var r=0;r<e.length-1;++r)e[r].push("From previous event:"),e[r]=e[r].join("\n");return r<e.length&&(e[r]=e[r].join("\n")),t+"\n"+e.join("\n")}function n(t){for(var e=0;e<t.length;++e)(0===t[e].length||e+1<t.length&&t[e][0]===t[e+1][0])&&(t.splice(e,1),e--)}function i(t){for(var e=t[0],r=1;r<t.length;++r){for(var n=t[r],i=e.length-1,o=e[i],s=-1,a=n.length-1;a>=0;--a)if(n[a]===o){s=a;break}for(var a=s;a>=0;--a){var u=n[a];if(e[i]!==u)break;e.pop(),i--}e=n}}function o(t){for(var e=[],r=0;r<t.length;++r){var n=t[r],i=_.test(n)||"    (No stack trace)"===n,o=i&&y(n);i&&!o&&(v&&" "!==n.charAt(0)&&(n="    "+n),e.push(n))}return e}function s(t){for(var e=t.stack.replace(/\s+$/g,"").split("\n"),r=0;r<e.length;++r){var n=e[r];if("    (No stack trace)"===n||_.test(n))break}return r>0&&(e=e.slice(r)),e}function a(t){var e;if("function"==typeof t)e="[function "+(t.name||"anonymous")+"]";else{e=t.toString();var r=/\[object [a-zA-Z0-9$_]+\]/;if(r.test(e))try{var n=JSON.stringify(t);e=n}catch(i){}0===e.length&&(e="(empty array)")}return"(<"+u(e)+">, no stack trace)"}function u(t){var e=41;return t.length<e?t:t.substr(0,e-3)+"..."}function c(t){var e=t.match(g);return e?{fileName:e[1],line:parseInt(e[2],10)}:void 0}var l,h=t("./async.js"),p=t("./util.js"),f=/[\\\/]bluebird[\\\/]js[\\\/](main|debug|zalgo|instrumented)/,_=null,d=null,v=!1;p.inherits(e,Error),e.prototype.uncycle=function(){var t=this._length;if(!(2>t)){for(var e=[],r={},n=0,i=this;void 0!==i;++n)e.push(i),i=i._parent;t=this._length=n;for(var n=t-1;n>=0;--n){var o=e[n].stack;void 0===r[o]&&(r[o]=n)}for(var n=0;t>n;++n){var s=e[n].stack,a=r[s];if(void 0!==a&&a!==n){a>0&&(e[a-1]._parent=void 0,e[a-1]._length=1),e[n]._parent=void 0,e[n]._length=1;var u=n>0?e[n-1]:this;t-1>a?(u._parent=e[a+1],u._parent.uncycle(),u._length=u._parent._length+1):(u._parent=void 0,u._length=1);for(var c=u._length+1,l=n-2;l>=0;--l)e[l]._length=c,c++;return}}}},e.prototype.parent=function(){return this._parent},e.prototype.hasParent=function(){return void 0!==this._parent},e.prototype.attachExtraTrace=function(t){if(!t.__stackCleaned__){this.uncycle();for(var s=e.parseStackAndMessage(t),a=s.message,u=[s.stack],c=this;void 0!==c;)u.push(o(c.stack.split("\n"))),c=c._parent;i(u),n(u),p.notEnumerableProp(t,"stack",r(a,u)),p.notEnumerableProp(t,"__stackCleaned__",!0)}},e.parseStackAndMessage=function(t){var e=t.stack,r=t.toString();return e="string"==typeof e&&e.length>0?s(t):["    (No stack trace)"],{message:r,stack:o(e)}},e.formatAndLogError=function(t,e){if("undefined"!=typeof console){var r;if("object"==typeof t||"function"==typeof t){var n=t.stack;r=e+d(n,t)}else r=e+String(t);"function"==typeof l?l(r):("function"==typeof console.log||"object"==typeof console.log)&&console.log(r)}},e.unhandledRejection=function(t){e.formatAndLogError(t,"^--- With additional stack trace: ")},e.isSupported=function(){return"function"==typeof j},e.fireRejectionEvent=function(t,r,n,i){var o=!1;try{"function"==typeof r&&(o=!0,"rejectionHandled"===t?r(i):r(n,i))}catch(s){h.throwLater(s)}var a=!1;try{a=b(t,n,i)}catch(s){a=!0,h.throwLater(s)}var u=!1;if(m)try{u=m(t.toLowerCase(),{reason:n,promise:i})}catch(s){u=!0,h.throwLater(s)}a||o||u||"unhandledRejection"!==t||e.formatAndLogError(n,"Unhandled rejection ")};var y=function(){return!1},g=/[\/<\(]([^:\/]+):(\d+):(?:\d+)\)?\s*$/;e.setBounds=function(t,r){if(e.isSupported()){for(var n,i,o=t.stack.split("\n"),s=r.stack.split("\n"),a=-1,u=-1,l=0;l<o.length;++l){var h=c(o[l]);if(h){n=h.fileName,a=h.line;break}}for(var l=0;l<s.length;++l){var h=c(s[l]);if(h){i=h.fileName,u=h.line;break}}0>a||0>u||!n||!i||n!==i||a>=u||(y=function(t){if(f.test(t))return!0;var e=c(t);return e&&e.fileName===n&&a<=e.line&&e.line<=u?!0:!1})}};var m,j=function(){var t=/^\s*at\s*/,e=function(t,e){return"string"==typeof t?t:void 0!==e.name&&void 0!==e.message?e.toString():a(e)};if("number"==typeof Error.stackTraceLimit&&"function"==typeof Error.captureStackTrace){Error.stackTraceLimit=Error.stackTraceLimit+6,_=t,d=e;var r=Error.captureStackTrace;return y=function(t){return f.test(t)},function(t,e){Error.stackTraceLimit=Error.stackTraceLimit+6,r(t,e),Error.stackTraceLimit=Error.stackTraceLimit-6}}var n=new Error;if("string"==typeof n.stack&&n.stack.split("\n")[0].indexOf("stackDetection@")>=0)return _=/@/,d=e,v=!0,function(t){t.stack=(new Error).stack};var i;try{throw new Error}catch(o){i="stack"in o}return"stack"in n||!i||"number"!=typeof Error.stackTraceLimit?(d=function(t,e){return"string"==typeof t?t:"object"!=typeof e&&"function"!=typeof e||void 0===e.name||void 0===e.message?a(e):e.toString()},null):(_=t,d=e,function(t){Error.stackTraceLimit=Error.stackTraceLimit+6;try{throw new Error}catch(e){t.stack=e.stack}Error.stackTraceLimit=Error.stackTraceLimit-6})}([]),b=function(){if(p.isNode)return function(t,e,r){return"rejectionHandled"===t?process.emit(t,r):process.emit(t,e,r)};var t=!1,e=!0;try{var r=new self.CustomEvent("test");t=r instanceof CustomEvent}catch(n){}if(!t)try{var i=document.createEvent("CustomEvent");i.initCustomEvent("testingtheevent",!1,!0,{}),self.dispatchEvent(i)}catch(n){e=!1}e&&(m=function(e,r){var n;return t?n=new self.CustomEvent(e,{detail:r,bubbles:!1,cancelable:!0}):self.dispatchEvent&&(n=document.createEvent("CustomEvent"),n.initCustomEvent(e,!1,!0,r)),n?!self.dispatchEvent(n):!1});var o={};return o.unhandledRejection="onunhandledRejection".toLowerCase(),o.rejectionHandled="onrejectionHandled".toLowerCase(),function(t,e,r){var n=o[t],i=self[n];return i?("rejectionHandled"===t?i.call(self,r):i.call(self,e,r),!0):!1}}();return"undefined"!=typeof console&&"undefined"!=typeof console.warn&&(l=function(t){console.warn(t)},p.isNode&&process.stderr.isTTY?l=function(t){process.stderr.write("\e[31m"+t+"\e[39m\n")}:p.isNode||"string"!=typeof(new Error).stack||(l=function(t){console.warn("%c"+t,"color: red")})),e}},{"./async.js":2,"./util.js":38}],8:[function(t,e){"use strict";e.exports=function(e){function r(t,e,r){this._instances=t,this._callback=e,this._promise=r}function n(t,e){var r={},n=s(t).call(r,e);if(n===a)return n;var i=u(r);return i.length?(a.e=new c("Catch filter must inherit from Error or be a simple predicate function\n\n    See http://goo.gl/o84o68\n"),a):n}var i=t("./util.js"),o=t("./errors.js"),s=i.tryCatch,a=i.errorObj,u=t("./es5.js").keys,c=o.TypeError;return r.prototype.doFilter=function(t){for(var r=this._callback,i=this._promise,o=i._boundValue(),u=0,c=this._instances.length;c>u;++u){var l=this._instances[u],h=l===Error||null!=l&&l.prototype instanceof Error;if(h&&t instanceof l){var p=s(r).call(o,t);return p===a?(e.e=p.e,e):p}if("function"==typeof l&&!h){var f=n(l,t);if(f===a){t=a.e;break}if(f){var p=s(r).call(o,t);return p===a?(e.e=p.e,e):p}}}return e.e=t,e},r}},{"./errors.js":13,"./es5.js":14,"./util.js":38}],9:[function(t,e){"use strict";e.exports=function(t,e,r){function n(){this._trace=new e(o())}function i(){return r()?new n:void 0}function o(){var t=s.length-1;return t>=0?s[t]:void 0}var s=[];return n.prototype._pushContext=function(){r()&&void 0!==this._trace&&s.push(this._trace)},n.prototype._popContext=function(){r()&&void 0!==this._trace&&s.pop()},t.prototype._peekContext=o,t.prototype._pushContext=n.prototype._pushContext,t.prototype._popContext=n.prototype._popContext,i}},{}],10:[function(t,e){"use strict";e.exports=function(e,r){var n,i,o=e._getDomain,s=t("./async.js"),a=t("./errors.js").Warning,u=t("./util.js"),c=u.canAttachTrace,l=!1||u.isNode&&(!!process.env.BLUEBIRD_DEBUG||"development"===process.env.NODE_ENV);return l&&s.disableTrampolineIfNecessary(),e.prototype._ignoreRejections=function(){this._unsetRejectionIsUnhandled(),this._bitField=16777216|this._bitField},e.prototype._ensurePossibleRejectionHandled=function(){0===(16777216&this._bitField)&&(this._setRejectionIsUnhandled(),s.invokeLater(this._notifyUnhandledRejection,this,void 0))},e.prototype._notifyUnhandledRejectionIsHandled=function(){r.fireRejectionEvent("rejectionHandled",n,void 0,this)},e.prototype._notifyUnhandledRejection=function(){if(this._isRejectionUnhandled()){var t=this._getCarriedStackTrace()||this._settledValue;this._setUnhandledRejectionIsNotified(),r.fireRejectionEvent("unhandledRejection",i,t,this)}},e.prototype._setUnhandledRejectionIsNotified=function(){this._bitField=524288|this._bitField},e.prototype._unsetUnhandledRejectionIsNotified=function(){this._bitField=-524289&this._bitField},e.prototype._isUnhandledRejectionNotified=function(){return(524288&this._bitField)>0},e.prototype._setRejectionIsUnhandled=function(){this._bitField=2097152|this._bitField},e.prototype._unsetRejectionIsUnhandled=function(){this._bitField=-2097153&this._bitField,this._isUnhandledRejectionNotified()&&(this._unsetUnhandledRejectionIsNotified(),this._notifyUnhandledRejectionIsHandled())},e.prototype._isRejectionUnhandled=function(){return(2097152&this._bitField)>0},e.prototype._setCarriedStackTrace=function(t){this._bitField=1048576|this._bitField,this._fulfillmentHandler0=t},e.prototype._isCarryingStackTrace=function(){return(1048576&this._bitField)>0},e.prototype._getCarriedStackTrace=function(){return this._isCarryingStackTrace()?this._fulfillmentHandler0:void 0},e.prototype._captureStackTrace=function(){return l&&(this._trace=new r(this._peekContext())),this},e.prototype._attachExtraTrace=function(t,e){if(l&&c(t)){var n=this._trace;if(void 0!==n&&e&&(n=n._parent),void 0!==n)n.attachExtraTrace(t);else if(!t.__stackCleaned__){var i=r.parseStackAndMessage(t);u.notEnumerableProp(t,"stack",i.message+"\n"+i.stack.join("\n")),u.notEnumerableProp(t,"__stackCleaned__",!0)}}},e.prototype._warn=function(t){var e=new a(t),n=this._peekContext();if(n)n.attachExtraTrace(e);else{var i=r.parseStackAndMessage(e);e.stack=i.message+"\n"+i.stack.join("\n")}r.formatAndLogError(e,"")},e.onPossiblyUnhandledRejection=function(t){var e=o();i="function"==typeof t?null===e?t:e.bind(t):void 0},e.onUnhandledRejectionHandled=function(t){var e=o();n="function"==typeof t?null===e?t:e.bind(t):void 0},e.longStackTraces=function(){if(s.haveItemsQueued()&&l===!1)throw new Error("cannot enable long stack traces after promises have been created\n\n    See http://goo.gl/DT1qyG\n");l=r.isSupported(),l&&s.disableTrampolineIfNecessary()},e.hasLongStackTraces=function(){return l&&r.isSupported()},r.isSupported()||(e.longStackTraces=function(){},l=!1),function(){return l}}},{"./async.js":2,"./errors.js":13,"./util.js":38}],11:[function(t,e){"use strict";var r=t("./util.js"),n=r.isPrimitive;e.exports=function(t){var e=function(){return this},r=function(){throw this},i=function(){},o=function(){throw void 0},s=function(t,e){return 1===e?function(){throw t}:2===e?function(){return t}:void 0};t.prototype["return"]=t.prototype.thenReturn=function(t){return void 0===t?this.then(i):n(t)?this._then(s(t,2),void 0,void 0,void 0,void 0):this._then(e,void 0,void 0,t,void 0)},t.prototype["throw"]=t.prototype.thenThrow=function(t){return void 0===t?this.then(o):n(t)?this._then(s(t,1),void 0,void 0,void 0,void 0):this._then(r,void 0,void 0,t,void 0)}}},{"./util.js":38}],12:[function(t,e){"use strict";e.exports=function(t,e){var r=t.reduce;t.prototype.each=function(t){return r(this,t,null,e)},t.each=function(t,n){return r(t,n,null,e)}}},{}],13:[function(t,e){"use strict";function r(t,e){function r(n){return this instanceof r?(l(this,"message","string"==typeof n?n:e),l(this,"name",t),void(Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):Error.call(this))):new r(n)}return c(r,Error),r}function n(t){return this instanceof n?(l(this,"name","OperationalError"),l(this,"message",t),this.cause=t,this.isOperational=!0,void(t instanceof Error?(l(this,"message",t.message),l(this,"stack",t.stack)):Error.captureStackTrace&&Error.captureStackTrace(this,this.constructor))):new n(t)}var i,o,s=t("./es5.js"),a=s.freeze,u=t("./util.js"),c=u.inherits,l=u.notEnumerableProp,h=r("Warning","warning"),p=r("CancellationError","cancellation error"),f=r("TimeoutError","timeout error"),_=r("AggregateError","aggregate error");try{i=TypeError,o=RangeError}catch(d){i=r("TypeError","type error"),o=r("RangeError","range error")}for(var v="join pop push shift unshift slice filter forEach some every map indexOf lastIndexOf reduce reduceRight sort reverse".split(" "),y=0;y<v.length;++y)"function"==typeof Array.prototype[v[y]]&&(_.prototype[v[y]]=Array.prototype[v[y]]);s.defineProperty(_.prototype,"length",{value:0,configurable:!1,writable:!0,enumerable:!0}),_.prototype.isOperational=!0;var g=0;_.prototype.toString=function(){var t=Array(4*g+1).join(" "),e="\n"+t+"AggregateError of:\n";g++,t=Array(4*g+1).join(" ");for(var r=0;r<this.length;++r){for(var n=this[r]===this?"[Circular AggregateError]":this[r]+"",i=n.split("\n"),o=0;o<i.length;++o)i[o]=t+i[o];n=i.join("\n"),e+=n+"\n"}return g--,e},c(n,Error);var m=Error.__BluebirdErrorTypes__;m||(m=a({CancellationError:p,TimeoutError:f,OperationalError:n,RejectionError:n,AggregateError:_}),l(Error,"__BluebirdErrorTypes__",m)),e.exports={Error:Error,TypeError:i,RangeError:o,CancellationError:m.CancellationError,OperationalError:m.OperationalError,TimeoutError:m.TimeoutError,AggregateError:m.AggregateError,Warning:h}},{"./es5.js":14,"./util.js":38}],14:[function(t,e){var r=function(){"use strict";return void 0===this}();if(r)e.exports={freeze:Object.freeze,defineProperty:Object.defineProperty,getDescriptor:Object.getOwnPropertyDescriptor,keys:Object.keys,names:Object.getOwnPropertyNames,getPrototypeOf:Object.getPrototypeOf,isArray:Array.isArray,isES5:r,propertyIsWritable:function(t,e){var r=Object.getOwnPropertyDescriptor(t,e);return!(r&&!r.writable&&!r.set)}};else{var n={}.hasOwnProperty,i={}.toString,o={}.constructor.prototype,s=function(t){var e=[];for(var r in t)n.call(t,r)&&e.push(r);return e},a=function(t,e){return{value:t[e]}},u=function(t,e,r){return t[e]=r.value,t},c=function(t){return t},l=function(t){try{return Object(t).constructor.prototype}catch(e){return o}},h=function(t){try{return"[object Array]"===i.call(t)}catch(e){return!1}};e.exports={isArray:h,keys:s,names:s,defineProperty:u,getDescriptor:a,freeze:c,getPrototypeOf:l,isES5:r,propertyIsWritable:function(){return!0}}}},{}],15:[function(t,e){"use strict";e.exports=function(t,e){var r=t.map;t.prototype.filter=function(t,n){return r(this,t,n,e)},t.filter=function(t,n,i){return r(t,n,i,e)}}},{}],16:[function(t,e){"use strict";e.exports=function(e,r,n){function i(){return this}function o(){throw this}function s(t){return function(){return t}}function a(t){return function(){throw t}}function u(t,e,r){var n;return n=p(e)?r?s(e):a(e):r?i:o,t._then(n,f,void 0,e,void 0)}function c(t){var i=this.promise,o=this.handler,s=i._isBound()?o.call(i._boundValue()):o();if(void 0!==s){var a=n(s,i);if(a instanceof e)return a=a._target(),u(a,t,i.isFulfilled())}return i.isRejected()?(r.e=t,r):t}function l(t){var r=this.promise,i=this.handler,o=r._isBound()?i.call(r._boundValue(),t):i(t);if(void 0!==o){var s=n(o,r);if(s instanceof e)return s=s._target(),u(s,t,!0)}return t}var h=t("./util.js"),p=h.isPrimitive,f=h.thrower;e.prototype._passThroughHandler=function(t,e){if("function"!=typeof t)return this.then();var r={promise:this,handler:t};return this._then(e?c:l,e?c:void 0,void 0,r,void 0)},e.prototype.lastly=e.prototype["finally"]=function(t){return this._passThroughHandler(t,!0)},e.prototype.tap=function(t){return this._passThroughHandler(t,!1)}}},{"./util.js":38}],17:[function(t,e){"use strict";e.exports=function(e,r,n,i){function o(t,r,n){for(var o=0;o<r.length;++o){n._pushContext();var s=h(r[o])(t);if(n._popContext(),s===l){n._pushContext();var a=e.reject(l.e);return n._popContext(),a}var u=i(s,n);if(u instanceof e)return u}return null}function s(t,r,i,o){var s=this._promise=new e(n);s._captureStackTrace(),this._stack=o,this._generatorFunction=t,this._receiver=r,this._generator=void 0,this._yieldHandlers="function"==typeof i?[i].concat(p):p}var a=t("./errors.js"),u=a.TypeError,c=t("./util.js"),l=c.errorObj,h=c.tryCatch,p=[];s.prototype.promise=function(){return this._promise},s.prototype._run=function(){this._generator=this._generatorFunction.call(this._receiver),this._receiver=this._generatorFunction=void 0,this._next(void 0)},s.prototype._continue=function(t){if(t===l)return this._promise._rejectCallback(t.e,!1,!0);var r=t.value;if(t.done===!0)this._promise._resolveCallback(r);else{var n=i(r,this._promise);if(!(n instanceof e)&&(n=o(n,this._yieldHandlers,this._promise),null===n))return void this._throw(new u("A value %s was yielded that could not be treated as a promise\n\n    See http://goo.gl/4Y4pDk\n\n".replace("%s",r)+"From coroutine:\n"+this._stack.split("\n").slice(1,-7).join("\n")));n._then(this._next,this._throw,void 0,this,null)}},s.prototype._throw=function(t){this._promise._attachExtraTrace(t),this._promise._pushContext();var e=h(this._generator["throw"]).call(this._generator,t);this._promise._popContext(),this._continue(e)},s.prototype._next=function(t){this._promise._pushContext();var e=h(this._generator.next).call(this._generator,t);this._promise._popContext(),this._continue(e)},e.coroutine=function(t,e){if("function"!=typeof t)throw new u("generatorFunction must be a function\n\n    See http://goo.gl/6Vqhm0\n");var r=Object(e).yieldHandler,n=s,i=(new Error).stack;return function(){var e=t.apply(this,arguments),o=new n(void 0,void 0,r,i);return o._generator=e,o._next(void 0),o.promise()}},e.coroutine.addYieldHandler=function(t){if("function"!=typeof t)throw new u("fn must be a function\n\n    See http://goo.gl/916lJJ\n");p.push(t)},e.spawn=function(t){if("function"!=typeof t)return r("generatorFunction must be a function\n\n    See http://goo.gl/6Vqhm0\n");var n=new s(t,this),i=n.promise();return n._run(e.spawn),i}}},{"./errors.js":13,"./util.js":38}],18:[function(t,e){"use strict";e.exports=function(e,r,n,i){{var o=t("./util.js");o.canEvaluate,o.tryCatch,o.errorObj}e.join=function(){var t,e=arguments.length-1;if(e>0&&"function"==typeof arguments[e]){t=arguments[e];var n}for(var i=arguments.length,o=new Array(i),s=0;i>s;++s)o[s]=arguments[s];t&&o.pop();var n=new r(o).promise();return void 0!==t?n.spread(t):n}}},{"./util.js":38}],19:[function(t,e){"use strict";e.exports=function(e,r,n,i,o){function s(t,e,r,n){this.constructor$(t),this._promise._captureStackTrace();var i=c();this._callback=null===i?e:i.bind(e),this._preservedValues=n===o?new Array(this.length()):null,this._limit=r,this._inFlight=0,this._queue=r>=1?[]:d,l.invoke(a,this,void 0)}function a(){this._init$(void 0,-2)}function u(t,e,r,n){var i="object"==typeof r&&null!==r?r.concurrency:0;return i="number"==typeof i&&isFinite(i)&&i>=1?i:0,new s(t,e,i,n)}var c=e._getDomain,l=t("./async.js"),h=t("./util.js"),p=h.tryCatch,f=h.errorObj,_={},d=[];h.inherits(s,r),s.prototype._init=function(){},s.prototype._promiseFulfilled=function(t,r){var n=this._values,o=this.length(),s=this._preservedValues,a=this._limit;if(n[r]===_){if(n[r]=t,a>=1&&(this._inFlight--,this._drainQueue(),this._isResolved()))return}else{if(a>=1&&this._inFlight>=a)return n[r]=t,void this._queue.push(r);null!==s&&(s[r]=t);var u=this._callback,c=this._promise._boundValue();this._promise._pushContext();var l=p(u).call(c,t,r,o);if(this._promise._popContext(),l===f)return this._reject(l.e);var h=i(l,this._promise);if(h instanceof e){if(h=h._target(),h._isPending())return a>=1&&this._inFlight++,n[r]=_,h._proxyPromiseArray(this,r);if(!h._isFulfilled())return this._reject(h._reason());l=h._value()}n[r]=l}var d=++this._totalResolved;d>=o&&(null!==s?this._filter(n,s):this._resolve(n))},s.prototype._drainQueue=function(){for(var t=this._queue,e=this._limit,r=this._values;t.length>0&&this._inFlight<e;){if(this._isResolved())return;var n=t.pop();this._promiseFulfilled(r[n],n)}},s.prototype._filter=function(t,e){for(var r=e.length,n=new Array(r),i=0,o=0;r>o;++o)t[o]&&(n[i++]=e[o]);n.length=i,this._resolve(n)},s.prototype.preservedValues=function(){return this._preservedValues},e.prototype.map=function(t,e){return"function"!=typeof t?n("fn must be a function\n\n    See http://goo.gl/916lJJ\n"):u(this,t,e,null).promise()},e.map=function(t,e,r,i){return"function"!=typeof e?n("fn must be a function\n\n    See http://goo.gl/916lJJ\n"):u(t,e,r,i).promise()}}},{"./async.js":2,"./util.js":38}],20:[function(t,e){"use strict";e.exports=function(e,r,n,i){var o=t("./util.js"),s=o.tryCatch;e.method=function(t){if("function"!=typeof t)throw new e.TypeError("fn must be a function\n\n    See http://goo.gl/916lJJ\n");return function(){var n=new e(r);n._captureStackTrace(),n._pushContext();var i=s(t).apply(this,arguments);return n._popContext(),n._resolveFromSyncValue(i),n}},e.attempt=e["try"]=function(t,n,a){if("function"!=typeof t)return i("fn must be a function\n\n    See http://goo.gl/916lJJ\n");var u=new e(r);u._captureStackTrace(),u._pushContext();var c=o.isArray(n)?s(t).apply(a,n):s(t).call(a,n);return u._popContext(),u._resolveFromSyncValue(c),u},e.prototype._resolveFromSyncValue=function(t){t===o.errorObj?this._rejectCallback(t.e,!1,!0):this._resolveCallback(t,!0)}}},{"./util.js":38}],21:[function(t,e){"use strict";e.exports=function(e){function r(t,e){var r=this;if(!o.isArray(t))return n.call(r,t,e);var i=a(e).apply(r._boundValue(),[null].concat(t));i===u&&s.throwLater(i.e)}function n(t,e){var r=this,n=r._boundValue(),i=void 0===t?a(e).call(n,null):a(e).call(n,null,t);i===u&&s.throwLater(i.e)}function i(t,e){var r=this;if(!t){var n=r._target(),i=n._getCarriedStackTrace();i.cause=t,t=i}var o=a(e).call(r._boundValue(),t);o===u&&s.throwLater(o.e)}var o=t("./util.js"),s=t("./async.js"),a=o.tryCatch,u=o.errorObj;e.prototype.asCallback=e.prototype.nodeify=function(t,e){if("function"==typeof t){var o=n;void 0!==e&&Object(e).spread&&(o=r),this._then(o,i,void 0,this,t)}return this}}},{"./async.js":2,"./util.js":38}],22:[function(t,e){"use strict";e.exports=function(e,r){var n=t("./util.js"),i=t("./async.js"),o=n.tryCatch,s=n.errorObj;e.prototype.progressed=function(t){return this._then(void 0,void 0,t,void 0,void 0)},e.prototype._progress=function(t){this._isFollowingOrFulfilledOrRejected()||this._target()._progressUnchecked(t)},e.prototype._progressHandlerAt=function(t){return 0===t?this._progressHandler0:this[(t<<2)+t-5+2]},e.prototype._doProgressWith=function(t){var r=t.value,i=t.handler,a=t.promise,u=t.receiver,c=o(i).call(u,r);if(c===s){if(null!=c.e&&"StopProgressPropagation"!==c.e.name){var l=n.canAttachTrace(c.e)?c.e:new Error(n.toString(c.e));a._attachExtraTrace(l),a._progress(c.e)}}else c instanceof e?c._then(a._progress,null,null,a,void 0):a._progress(c)},e.prototype._progressUnchecked=function(t){for(var n=this._length(),o=this._progress,s=0;n>s;s++){var a=this._progressHandlerAt(s),u=this._promiseAt(s);if(u instanceof e)"function"==typeof a?i.invoke(this._doProgressWith,this,{handler:a,promise:u,receiver:this._receiverAt(s),value:t}):i.invoke(o,u,t);else{var c=this._receiverAt(s);"function"==typeof a?a.call(c,t,u):c instanceof r&&!c._isResolved()&&c._promiseProgressed(t,u)}}}}},{"./async.js":2,"./util.js":38}],23:[function(t,e){"use strict";e.exports=function(){function e(t){if("function"!=typeof t)throw new l("the promise constructor requires a resolver function\n\n    See http://goo.gl/EC22Yn\n");if(this.constructor!==e)throw new l("the promise constructor cannot be invoked directly\n\n    See http://goo.gl/KsIlge\n");this._bitField=0,this._fulfillmentHandler0=void 0,this._rejectionHandler0=void 0,this._progressHandler0=void 0,this._promise0=void 0,this._receiver0=void 0,this._settledValue=void 0,t!==h&&this._resolveFromResolver(t)}function r(t){var r=new e(h);r._fulfillmentHandler0=t,r._rejectionHandler0=t,r._progressHandler0=t,r._promise0=t,r._receiver0=t,r._settledValue=t}var n,i=function(){return new l("circular promise resolution chain\n\n    See http://goo.gl/LhFpo0\n")},o=function(){return new e.PromiseInspection(this._target())},s=function(t){return e.reject(new l(t))},a=t("./util.js");n=a.isNode?function(){var t=process.domain;return void 0===t&&(t=null),t}:function(){return null},a.notEnumerableProp(e,"_getDomain",n);var u=t("./async.js"),c=t("./errors.js"),l=e.TypeError=c.TypeError;e.RangeError=c.RangeError,e.CancellationError=c.CancellationError,e.TimeoutError=c.TimeoutError,e.OperationalError=c.OperationalError,e.RejectionError=c.OperationalError,e.AggregateError=c.AggregateError;var h=function(){},p={},f={e:null},_=t("./thenables.js")(e,h),d=t("./promise_array.js")(e,h,_,s),v=t("./captured_trace.js")(),y=t("./debuggability.js")(e,v),g=t("./context.js")(e,v,y),m=t("./catch_filter.js")(f),j=t("./promise_resolver.js"),b=j._nodebackForPromise,w=a.errorObj,k=a.tryCatch;return e.prototype.toString=function(){return"[object Promise]"},e.prototype.caught=e.prototype["catch"]=function(t){var r=arguments.length;if(r>1){var n,i=new Array(r-1),o=0;for(n=0;r-1>n;++n){var s=arguments[n];if("function"!=typeof s)return e.reject(new l("Catch filter must inherit from Error or be a simple predicate function\n\n    See http://goo.gl/o84o68\n"));i[o++]=s}i.length=o,t=arguments[n];var a=new m(i,t,this);return this._then(void 0,a.doFilter,void 0,a,void 0)}return this._then(void 0,t,void 0,void 0,void 0)},e.prototype.reflect=function(){return this._then(o,o,void 0,this,void 0)},e.prototype.then=function(t,e,r){if(y()&&arguments.length>0&&"function"!=typeof t&&"function"!=typeof e){var n=".then() only accepts functions but was passed: "+a.classString(t);arguments.length>1&&(n+=", "+a.classString(e)),this._warn(n)}return this._then(t,e,r,void 0,void 0)},e.prototype.done=function(t,e,r){var n=this._then(t,e,r,void 0,void 0);n._setIsFinal()},e.prototype.spread=function(t,e){return this.all()._then(t,e,void 0,p,void 0)
+},e.prototype.isCancellable=function(){return!this.isResolved()&&this._cancellable()},e.prototype.toJSON=function(){var t={isFulfilled:!1,isRejected:!1,fulfillmentValue:void 0,rejectionReason:void 0};return this.isFulfilled()?(t.fulfillmentValue=this.value(),t.isFulfilled=!0):this.isRejected()&&(t.rejectionReason=this.reason(),t.isRejected=!0),t},e.prototype.all=function(){return new d(this).promise()},e.prototype.error=function(t){return this.caught(a.originatesFromRejection,t)},e.is=function(t){return t instanceof e},e.fromNode=function(t){var r=new e(h),n=k(t)(b(r));return n===w&&r._rejectCallback(n.e,!0,!0),r},e.all=function(t){return new d(t).promise()},e.defer=e.pending=function(){var t=new e(h);return new j(t)},e.cast=function(t){var r=_(t);if(!(r instanceof e)){var n=r;r=new e(h),r._fulfillUnchecked(n)}return r},e.resolve=e.fulfilled=e.cast,e.reject=e.rejected=function(t){var r=new e(h);return r._captureStackTrace(),r._rejectCallback(t,!0),r},e.setScheduler=function(t){if("function"!=typeof t)throw new l("fn must be a function\n\n    See http://goo.gl/916lJJ\n");var e=u._schedule;return u._schedule=t,e},e.prototype._then=function(t,r,i,o,s){var a=void 0!==s,c=a?s:new e(h);a||(c._propagateFrom(this,5),c._captureStackTrace());var l=this._target();l!==this&&(void 0===o&&(o=this._boundTo),a||c._setIsMigrated());var p=l._addCallbacks(t,r,i,c,o,n());return l._isResolved()&&!l._isSettlePromisesQueued()&&u.invoke(l._settlePromiseAtPostResolution,l,p),c},e.prototype._settlePromiseAtPostResolution=function(t){this._isRejectionUnhandled()&&this._unsetRejectionIsUnhandled(),this._settlePromiseAt(t)},e.prototype._length=function(){return 131071&this._bitField},e.prototype._isFollowingOrFulfilledOrRejected=function(){return(939524096&this._bitField)>0},e.prototype._isFollowing=function(){return 536870912===(536870912&this._bitField)},e.prototype._setLength=function(t){this._bitField=-131072&this._bitField|131071&t},e.prototype._setFulfilled=function(){this._bitField=268435456|this._bitField},e.prototype._setRejected=function(){this._bitField=134217728|this._bitField},e.prototype._setFollowing=function(){this._bitField=536870912|this._bitField},e.prototype._setIsFinal=function(){this._bitField=33554432|this._bitField},e.prototype._isFinal=function(){return(33554432&this._bitField)>0},e.prototype._cancellable=function(){return(67108864&this._bitField)>0},e.prototype._setCancellable=function(){this._bitField=67108864|this._bitField},e.prototype._unsetCancellable=function(){this._bitField=-67108865&this._bitField},e.prototype._setIsMigrated=function(){this._bitField=4194304|this._bitField},e.prototype._unsetIsMigrated=function(){this._bitField=-4194305&this._bitField},e.prototype._isMigrated=function(){return(4194304&this._bitField)>0},e.prototype._receiverAt=function(t){var e=0===t?this._receiver0:this[5*t-5+4];return void 0===e&&this._isBound()?this._boundValue():e},e.prototype._promiseAt=function(t){return 0===t?this._promise0:this[5*t-5+3]},e.prototype._fulfillmentHandlerAt=function(t){return 0===t?this._fulfillmentHandler0:this[5*t-5+0]},e.prototype._rejectionHandlerAt=function(t){return 0===t?this._rejectionHandler0:this[5*t-5+1]},e.prototype._boundValue=function(){var t=this._boundTo;return void 0!==t&&t instanceof e?t.isFulfilled()?t.value():void 0:t},e.prototype._migrateCallbacks=function(t,r){var n=t._fulfillmentHandlerAt(r),i=t._rejectionHandlerAt(r),o=t._progressHandlerAt(r),s=t._promiseAt(r),a=t._receiverAt(r);s instanceof e&&s._setIsMigrated(),this._addCallbacks(n,i,o,s,a,null)},e.prototype._addCallbacks=function(t,e,r,n,i,o){var s=this._length();if(s>=131066&&(s=0,this._setLength(0)),0===s)this._promise0=n,void 0!==i&&(this._receiver0=i),"function"!=typeof t||this._isCarryingStackTrace()||(this._fulfillmentHandler0=null===o?t:o.bind(t)),"function"==typeof e&&(this._rejectionHandler0=null===o?e:o.bind(e)),"function"==typeof r&&(this._progressHandler0=null===o?r:o.bind(r));else{var a=5*s-5;this[a+3]=n,this[a+4]=i,"function"==typeof t&&(this[a+0]=null===o?t:o.bind(t)),"function"==typeof e&&(this[a+1]=null===o?e:o.bind(e)),"function"==typeof r&&(this[a+2]=null===o?r:o.bind(r))}return this._setLength(s+1),s},e.prototype._setProxyHandlers=function(t,e){var r=this._length();if(r>=131066&&(r=0,this._setLength(0)),0===r)this._promise0=e,this._receiver0=t;else{var n=5*r-5;this[n+3]=e,this[n+4]=t}this._setLength(r+1)},e.prototype._proxyPromiseArray=function(t,e){this._setProxyHandlers(t,e)},e.prototype._resolveCallback=function(t,r){if(!this._isFollowingOrFulfilledOrRejected()){if(t===this)return this._rejectCallback(i(),!1,!0);var n=_(t,this);if(!(n instanceof e))return this._fulfill(t);var o=1|(r?4:0);this._propagateFrom(n,o);var s=n._target();if(s._isPending()){for(var a=this._length(),u=0;a>u;++u)s._migrateCallbacks(this,u);this._setFollowing(),this._setLength(0),this._setFollowee(s)}else s._isFulfilled()?this._fulfillUnchecked(s._value()):this._rejectUnchecked(s._reason(),s._getCarriedStackTrace())}},e.prototype._rejectCallback=function(t,e,r){r||a.markAsOriginatingFromRejection(t);var n=a.ensureErrorObject(t),i=n===t;this._attachExtraTrace(n,e?i:!1),this._reject(t,i?void 0:n)},e.prototype._resolveFromResolver=function(t){var e=this;this._captureStackTrace(),this._pushContext();var r=!0,n=k(t)(function(t){null!==e&&(e._resolveCallback(t),e=null)},function(t){null!==e&&(e._rejectCallback(t,r),e=null)});r=!1,this._popContext(),void 0!==n&&n===w&&null!==e&&(e._rejectCallback(n.e,!0,!0),e=null)},e.prototype._settlePromiseFromHandler=function(t,e,r,n){if(!n._isRejected()){n._pushContext();var o;if(o=e!==p||this._isRejected()?k(t).call(e,r):k(t).apply(this._boundValue(),r),n._popContext(),o===w||o===n||o===f){var s=o===n?i():o.e;n._rejectCallback(s,!1,!0)}else n._resolveCallback(o)}},e.prototype._target=function(){for(var t=this;t._isFollowing();)t=t._followee();return t},e.prototype._followee=function(){return this._rejectionHandler0},e.prototype._setFollowee=function(t){this._rejectionHandler0=t},e.prototype._cleanValues=function(){this._cancellable()&&(this._cancellationParent=void 0)},e.prototype._propagateFrom=function(t,e){(1&e)>0&&t._cancellable()&&(this._setCancellable(),this._cancellationParent=t),(4&e)>0&&t._isBound()&&this._setBoundTo(t._boundTo)},e.prototype._fulfill=function(t){this._isFollowingOrFulfilledOrRejected()||this._fulfillUnchecked(t)},e.prototype._reject=function(t,e){this._isFollowingOrFulfilledOrRejected()||this._rejectUnchecked(t,e)},e.prototype._settlePromiseAt=function(t){var r=this._promiseAt(t),n=r instanceof e;if(n&&r._isMigrated())return r._unsetIsMigrated(),u.invoke(this._settlePromiseAt,this,t);var i=this._isFulfilled()?this._fulfillmentHandlerAt(t):this._rejectionHandlerAt(t),o=this._isCarryingStackTrace()?this._getCarriedStackTrace():void 0,s=this._settledValue,a=this._receiverAt(t);this._clearCallbackDataAtIndex(t),"function"==typeof i?n?this._settlePromiseFromHandler(i,a,s,r):i.call(a,s,r):a instanceof d?a._isResolved()||(this._isFulfilled()?a._promiseFulfilled(s,r):a._promiseRejected(s,r)):n&&(this._isFulfilled()?r._fulfill(s):r._reject(s,o)),t>=4&&4===(31&t)&&u.invokeLater(this._setLength,this,0)},e.prototype._clearCallbackDataAtIndex=function(t){if(0===t)this._isCarryingStackTrace()||(this._fulfillmentHandler0=void 0),this._rejectionHandler0=this._progressHandler0=this._receiver0=this._promise0=void 0;else{var e=5*t-5;this[e+3]=this[e+4]=this[e+0]=this[e+1]=this[e+2]=void 0}},e.prototype._isSettlePromisesQueued=function(){return-1073741824===(-1073741824&this._bitField)},e.prototype._setSettlePromisesQueued=function(){this._bitField=-1073741824|this._bitField},e.prototype._unsetSettlePromisesQueued=function(){this._bitField=1073741823&this._bitField},e.prototype._queueSettlePromises=function(){u.settlePromises(this),this._setSettlePromisesQueued()},e.prototype._fulfillUnchecked=function(t){if(t===this){var e=i();return this._attachExtraTrace(e),this._rejectUnchecked(e,void 0)}this._setFulfilled(),this._settledValue=t,this._cleanValues(),this._length()>0&&this._queueSettlePromises()},e.prototype._rejectUncheckedCheckError=function(t){var e=a.ensureErrorObject(t);this._rejectUnchecked(t,e===t?void 0:e)},e.prototype._rejectUnchecked=function(t,e){if(t===this){var r=i();return this._attachExtraTrace(r),this._rejectUnchecked(r)}return this._setRejected(),this._settledValue=t,this._cleanValues(),this._isFinal()?void u.throwLater(function(t){throw"stack"in t&&u.invokeFirst(v.unhandledRejection,void 0,t),t},void 0===e?t:e):(void 0!==e&&e!==t&&this._setCarriedStackTrace(e),void(this._length()>0?this._queueSettlePromises():this._ensurePossibleRejectionHandled()))},e.prototype._settlePromises=function(){this._unsetSettlePromisesQueued();for(var t=this._length(),e=0;t>e;e++)this._settlePromiseAt(e)},a.notEnumerableProp(e,"_makeSelfResolutionError",i),t("./progress.js")(e,d),t("./method.js")(e,h,_,s),t("./bind.js")(e,h,_),t("./finally.js")(e,f,_),t("./direct_resolve.js")(e),t("./synchronous_inspection.js")(e),t("./join.js")(e,d,_,h),e.Promise=e,t("./map.js")(e,d,s,_,h),t("./cancel.js")(e),t("./using.js")(e,s,_,g),t("./generators.js")(e,s,h,_),t("./nodeify.js")(e),t("./call_get.js")(e),t("./props.js")(e,d,_,s),t("./race.js")(e,h,_,s),t("./reduce.js")(e,d,s,_,h),t("./settle.js")(e,d),t("./some.js")(e,d,s),t("./promisify.js")(e,h),t("./any.js")(e),t("./each.js")(e,h),t("./timers.js")(e,h),t("./filter.js")(e,h),a.toFastProperties(e),a.toFastProperties(e.prototype),r({a:1}),r({b:2}),r({c:3}),r(1),r(function(){}),r(void 0),r(!1),r(new e(h)),v.setBounds(u.firstLineError,a.lastLineError),e}},{"./any.js":1,"./async.js":2,"./bind.js":3,"./call_get.js":5,"./cancel.js":6,"./captured_trace.js":7,"./catch_filter.js":8,"./context.js":9,"./debuggability.js":10,"./direct_resolve.js":11,"./each.js":12,"./errors.js":13,"./filter.js":15,"./finally.js":16,"./generators.js":17,"./join.js":18,"./map.js":19,"./method.js":20,"./nodeify.js":21,"./progress.js":22,"./promise_array.js":24,"./promise_resolver.js":25,"./promisify.js":26,"./props.js":27,"./race.js":29,"./reduce.js":30,"./settle.js":32,"./some.js":33,"./synchronous_inspection.js":34,"./thenables.js":35,"./timers.js":36,"./using.js":37,"./util.js":38}],24:[function(t,e){"use strict";e.exports=function(e,r,n,i){function o(t){switch(t){case-2:return[];case-3:return{}}}function s(t){var n,i=this._promise=new e(r);t instanceof e&&(n=t,i._propagateFrom(n,5)),this._values=t,this._length=0,this._totalResolved=0,this._init(void 0,-2)}var a=t("./util.js"),u=a.isArray;return s.prototype.length=function(){return this._length},s.prototype.promise=function(){return this._promise},s.prototype._init=function c(t,r){var s=n(this._values,this._promise);if(s instanceof e){if(s=s._target(),this._values=s,!s._isFulfilled())return s._isPending()?void s._then(c,this._reject,void 0,this,r):void this._reject(s._reason());if(s=s._value(),!u(s)){var a=new e.TypeError("expecting an array, a promise or a thenable\n\n    See http://goo.gl/s8MMhc\n");return void this.__hardReject__(a)}}else if(!u(s))return void this._promise._reject(i("expecting an array, a promise or a thenable\n\n    See http://goo.gl/s8MMhc\n")._reason());if(0===s.length)return void(-5===r?this._resolveEmptyArray():this._resolve(o(r)));var l=this.getActualLength(s.length);this._length=l,this._values=this.shouldCopyValues()?new Array(l):this._values;for(var h=this._promise,p=0;l>p;++p){var f=this._isResolved(),_=n(s[p],h);_ instanceof e?(_=_._target(),f?_._ignoreRejections():_._isPending()?_._proxyPromiseArray(this,p):_._isFulfilled()?this._promiseFulfilled(_._value(),p):this._promiseRejected(_._reason(),p)):f||this._promiseFulfilled(_,p)}},s.prototype._isResolved=function(){return null===this._values},s.prototype._resolve=function(t){this._values=null,this._promise._fulfill(t)},s.prototype.__hardReject__=s.prototype._reject=function(t){this._values=null,this._promise._rejectCallback(t,!1,!0)},s.prototype._promiseProgressed=function(t,e){this._promise._progress({index:e,value:t})},s.prototype._promiseFulfilled=function(t,e){this._values[e]=t;var r=++this._totalResolved;r>=this._length&&this._resolve(this._values)},s.prototype._promiseRejected=function(t){this._totalResolved++,this._reject(t)},s.prototype.shouldCopyValues=function(){return!0},s.prototype.getActualLength=function(t){return t},s}},{"./util.js":38}],25:[function(t,e){"use strict";function r(t){return t instanceof Error&&p.getPrototypeOf(t)===Error.prototype}function n(t){var e;if(r(t)){e=new l(t),e.name=t.name,e.message=t.message,e.stack=t.stack;for(var n=p.keys(t),i=0;i<n.length;++i){var o=n[i];f.test(o)||(e[o]=t[o])}return e}return s.markAsOriginatingFromRejection(t),t}function i(t){return function(e,r){if(null!==t){if(e){var i=n(a(e));t._attachExtraTrace(i),t._reject(i)}else if(arguments.length>2){for(var o=arguments.length,s=new Array(o-1),u=1;o>u;++u)s[u-1]=arguments[u];t._fulfill(s)}else t._fulfill(r);t=null}}}var o,s=t("./util.js"),a=s.maybeWrapAsError,u=t("./errors.js"),c=u.TimeoutError,l=u.OperationalError,h=s.haveGetters,p=t("./es5.js"),f=/^(?:name|message|stack|cause)$/;if(o=h?function(t){this.promise=t}:function(t){this.promise=t,this.asCallback=i(t),this.callback=this.asCallback},h){var _={get:function(){return i(this.promise)}};p.defineProperty(o.prototype,"asCallback",_),p.defineProperty(o.prototype,"callback",_)}o._nodebackForPromise=i,o.prototype.toString=function(){return"[object PromiseResolver]"},o.prototype.resolve=o.prototype.fulfill=function(t){if(!(this instanceof o))throw new TypeError("Illegal invocation, resolver resolve/reject must be called within a resolver context. Consider using the promise constructor instead.\n\n    See http://goo.gl/sdkXL9\n");this.promise._resolveCallback(t)},o.prototype.reject=function(t){if(!(this instanceof o))throw new TypeError("Illegal invocation, resolver resolve/reject must be called within a resolver context. Consider using the promise constructor instead.\n\n    See http://goo.gl/sdkXL9\n");this.promise._rejectCallback(t)},o.prototype.progress=function(t){if(!(this instanceof o))throw new TypeError("Illegal invocation, resolver resolve/reject must be called within a resolver context. Consider using the promise constructor instead.\n\n    See http://goo.gl/sdkXL9\n");this.promise._progress(t)},o.prototype.cancel=function(t){this.promise.cancel(t)},o.prototype.timeout=function(){this.reject(new c("timeout"))},o.prototype.isResolved=function(){return this.promise.isResolved()},o.prototype.toJSON=function(){return this.promise.toJSON()},e.exports=o},{"./errors.js":13,"./es5.js":14,"./util.js":38}],26:[function(t,e){"use strict";e.exports=function(e,r){function n(t){return!w.test(t)}function i(t){try{return t.__isPromisified__===!0}catch(e){return!1}}function o(t,e,r){var n=f.getDataPropertyOrDefault(t,e+r,j);return n?i(n):!1}function s(t,e,r){for(var n=0;n<t.length;n+=2){var i=t[n];if(r.test(i))for(var o=i.replace(r,""),s=0;s<t.length;s+=2)if(t[s]===o)throw new g("Cannot promisify an API that has normal methods with '%s'-suffix\n\n    See http://goo.gl/iWrZbw\n".replace("%s",e))}}function a(t,e,r,n){for(var a=f.inheritedDataKeys(t),u=[],c=0;c<a.length;++c){var l=a[c],h=t[l],p=n===k?!0:k(l,h,t);"function"!=typeof h||i(h)||o(t,l,e)||!n(l,h,t,p)||u.push(l,h)}return s(u,e,r),u}function u(t,n,i,o){function s(){var i=n;n===p&&(i=this);var o=new e(r);o._captureStackTrace();var s="string"==typeof u&&this!==a?this[u]:t,c=_(o);try{s.apply(i,d(arguments,c))}catch(l){o._rejectCallback(v(l),!0,!0)}return o}var a=function(){return this}(),u=t;return"string"==typeof u&&(t=o),f.notEnumerableProp(s,"__isPromisified__",!0),s}function c(t,e,r,n){for(var i=new RegExp(E(e)+"$"),o=a(t,e,i,r),s=0,u=o.length;u>s;s+=2){var c=o[s],l=o[s+1],h=c+e;t[h]=n===F?F(c,p,c,l,e):n(l,function(){return F(c,p,c,l,e)})}return f.toFastProperties(t),t}function l(t,e){return F(t,e,void 0,t)}var h,p={},f=t("./util.js"),_=t("./promise_resolver.js")._nodebackForPromise,d=f.withAppended,v=f.maybeWrapAsError,y=f.canEvaluate,g=t("./errors").TypeError,m="Async",j={__isPromisified__:!0},b=["arity","length","name","arguments","caller","callee","prototype","__isPromisified__"],w=new RegExp("^(?:"+b.join("|")+")$"),k=function(t){return f.isIdentifier(t)&&"_"!==t.charAt(0)&&"constructor"!==t},E=function(t){return t.replace(/([$])/,"\\$")},F=y?h:u;e.promisify=function(t,e){if("function"!=typeof t)throw new g("fn must be a function\n\n    See http://goo.gl/916lJJ\n");if(i(t))return t;var r=l(t,arguments.length<2?p:e);return f.copyDescriptors(t,r,n),r},e.promisifyAll=function(t,e){if("function"!=typeof t&&"object"!=typeof t)throw new g("the target of promisifyAll must be an object or a function\n\n    See http://goo.gl/9ITlV0\n");e=Object(e);var r=e.suffix;"string"!=typeof r&&(r=m);var n=e.filter;"function"!=typeof n&&(n=k);var i=e.promisifier;if("function"!=typeof i&&(i=F),!f.isIdentifier(r))throw new RangeError("suffix must be a valid identifier\n\n    See http://goo.gl/8FZo5V\n");for(var o=f.inheritedDataKeys(t),s=0;s<o.length;++s){var a=t[o[s]];"constructor"!==o[s]&&f.isClass(a)&&(c(a.prototype,r,n,i),c(a,r,n,i))}return c(t,r,n,i)}}},{"./errors":13,"./promise_resolver.js":25,"./util.js":38}],27:[function(t,e){"use strict";e.exports=function(e,r,n,i){function o(t){for(var e=c.keys(t),r=e.length,n=new Array(2*r),i=0;r>i;++i){var o=e[i];n[i]=t[o],n[i+r]=o}this.constructor$(n)}function s(t){var r,s=n(t);return u(s)?(r=s instanceof e?s._then(e.props,void 0,void 0,void 0,void 0):new o(s).promise(),s instanceof e&&r._propagateFrom(s,4),r):i("cannot await properties of a non-object\n\n    See http://goo.gl/OsFKC8\n")}var a=t("./util.js"),u=a.isObject,c=t("./es5.js");a.inherits(o,r),o.prototype._init=function(){this._init$(void 0,-3)},o.prototype._promiseFulfilled=function(t,e){this._values[e]=t;var r=++this._totalResolved;if(r>=this._length){for(var n={},i=this.length(),o=0,s=this.length();s>o;++o)n[this._values[o+i]]=this._values[o];this._resolve(n)}},o.prototype._promiseProgressed=function(t,e){this._promise._progress({key:this._values[e+this.length()],value:t})},o.prototype.shouldCopyValues=function(){return!1},o.prototype.getActualLength=function(t){return t>>1},e.prototype.props=function(){return s(this)},e.props=function(t){return s(t)}}},{"./es5.js":14,"./util.js":38}],28:[function(t,e){"use strict";function r(t,e,r,n,i){for(var o=0;i>o;++o)r[o+n]=t[o+e],t[o+e]=void 0}function n(t){this._capacity=t,this._length=0,this._front=0}n.prototype._willBeOverCapacity=function(t){return this._capacity<t},n.prototype._pushOne=function(t){var e=this.length();this._checkCapacity(e+1);var r=this._front+e&this._capacity-1;this[r]=t,this._length=e+1},n.prototype._unshiftOne=function(t){var e=this._capacity;this._checkCapacity(this.length()+1);var r=this._front,n=(r-1&e-1^e)-e;this[n]=t,this._front=n,this._length=this.length()+1},n.prototype.unshift=function(t,e,r){this._unshiftOne(r),this._unshiftOne(e),this._unshiftOne(t)},n.prototype.push=function(t,e,r){var n=this.length()+3;if(this._willBeOverCapacity(n))return this._pushOne(t),this._pushOne(e),void this._pushOne(r);var i=this._front+n-3;this._checkCapacity(n);var o=this._capacity-1;this[i+0&o]=t,this[i+1&o]=e,this[i+2&o]=r,this._length=n},n.prototype.shift=function(){var t=this._front,e=this[t];return this[t]=void 0,this._front=t+1&this._capacity-1,this._length--,e},n.prototype.length=function(){return this._length},n.prototype._checkCapacity=function(t){this._capacity<t&&this._resizeTo(this._capacity<<1)},n.prototype._resizeTo=function(t){var e=this._capacity;this._capacity=t;var n=this._front,i=this._length,o=n+i&e-1;r(this,0,this,e,o)},e.exports=n},{}],29:[function(t,e){"use strict";e.exports=function(e,r,n,i){function o(t,o){var u=n(t);if(u instanceof e)return a(u);if(!s(t))return i("expecting an array, a promise or a thenable\n\n    See http://goo.gl/s8MMhc\n");var c=new e(r);void 0!==o&&c._propagateFrom(o,5);for(var l=c._fulfill,h=c._reject,p=0,f=t.length;f>p;++p){var _=t[p];(void 0!==_||p in t)&&e.cast(_)._then(l,h,void 0,c,null)}return c}var s=t("./util.js").isArray,a=function(t){return t.then(function(e){return o(e,t)})};e.race=function(t){return o(t,void 0)},e.prototype.race=function(){return o(this,void 0)}}},{"./util.js":38}],30:[function(t,e){"use strict";e.exports=function(e,r,n,i,o){function s(t,r,n,s){this.constructor$(t),this._promise._captureStackTrace(),this._preservedValues=s===o?[]:null,this._zerothIsAccum=void 0===n,this._gotAccum=!1,this._reducingIndex=this._zerothIsAccum?1:0,this._valuesPhase=void 0;var u=i(n,this._promise),h=!1,p=u instanceof e;p&&(u=u._target(),u._isPending()?u._proxyPromiseArray(this,-1):u._isFulfilled()?(n=u._value(),this._gotAccum=!0):(this._reject(u._reason()),h=!0)),p||this._zerothIsAccum||(this._gotAccum=!0);var f=c();this._callback=null===f?r:f.bind(r),this._accum=n,h||l.invoke(a,this,void 0)}function a(){this._init$(void 0,-5)}function u(t,e,r,i){if("function"!=typeof e)return n("fn must be a function\n\n    See http://goo.gl/916lJJ\n");var o=new s(t,e,r,i);return o.promise()}var c=e._getDomain,l=t("./async.js"),h=t("./util.js"),p=h.tryCatch,f=h.errorObj;h.inherits(s,r),s.prototype._init=function(){},s.prototype._resolveEmptyArray=function(){(this._gotAccum||this._zerothIsAccum)&&this._resolve(null!==this._preservedValues?[]:this._accum)},s.prototype._promiseFulfilled=function(t,r){var n=this._values;n[r]=t;var o,s=this.length(),a=this._preservedValues,u=null!==a,c=this._gotAccum,l=this._valuesPhase;if(!l)for(l=this._valuesPhase=new Array(s),o=0;s>o;++o)l[o]=0;if(o=l[r],0===r&&this._zerothIsAccum?(this._accum=t,this._gotAccum=c=!0,l[r]=0===o?1:2):-1===r?(this._accum=t,this._gotAccum=c=!0):0===o?l[r]=1:(l[r]=2,this._accum=t),c){for(var h,_=this._callback,d=this._promise._boundValue(),v=this._reducingIndex;s>v;++v)if(o=l[v],2!==o){if(1!==o)return;if(t=n[v],this._promise._pushContext(),u?(a.push(t),h=p(_).call(d,t,v,s)):h=p(_).call(d,this._accum,t,v,s),this._promise._popContext(),h===f)return this._reject(h.e);var y=i(h,this._promise);if(y instanceof e){if(y=y._target(),y._isPending())return l[v]=4,y._proxyPromiseArray(this,v);if(!y._isFulfilled())return this._reject(y._reason());h=y._value()}this._reducingIndex=v+1,this._accum=h}else this._reducingIndex=v+1;this._resolve(u?a:this._accum)}},e.prototype.reduce=function(t,e){return u(this,t,e,null)},e.reduce=function(t,e,r,n){return u(t,e,r,n)}}},{"./async.js":2,"./util.js":38}],31:[function(t,e){"use strict";var r,n=t("./util"),i=function(){throw new Error("No async scheduler available\n\n    See http://goo.gl/m3OTXk\n")};if(n.isNode&&"undefined"==typeof MutationObserver){var o=global.setImmediate,s=process.nextTick;r=n.isRecentNode?function(t){o.call(global,t)}:function(t){s.call(process,t)}}else"undefined"==typeof MutationObserver||"undefined"!=typeof window&&window.navigator&&window.navigator.standalone?r="undefined"!=typeof setImmediate?function(t){setImmediate(t)}:"undefined"!=typeof setTimeout?function(t){setTimeout(t,0)}:i:(r=function(t){var e=document.createElement("div"),r=new MutationObserver(t);return r.observe(e,{attributes:!0}),function(){e.classList.toggle("foo")}},r.isStatic=!0);e.exports=r},{"./util":38}],32:[function(t,e){"use strict";e.exports=function(e,r){function n(t){this.constructor$(t)}var i=e.PromiseInspection,o=t("./util.js");o.inherits(n,r),n.prototype._promiseResolved=function(t,e){this._values[t]=e;var r=++this._totalResolved;r>=this._length&&this._resolve(this._values)},n.prototype._promiseFulfilled=function(t,e){var r=new i;r._bitField=268435456,r._settledValue=t,this._promiseResolved(e,r)},n.prototype._promiseRejected=function(t,e){var r=new i;r._bitField=134217728,r._settledValue=t,this._promiseResolved(e,r)},e.settle=function(t){return new n(t).promise()},e.prototype.settle=function(){return new n(this).promise()}}},{"./util.js":38}],33:[function(t,e){"use strict";e.exports=function(e,r,n){function i(t){this.constructor$(t),this._howMany=0,this._unwrap=!1,this._initialized=!1}function o(t,e){if((0|e)!==e||0>e)return n("expecting a positive integer\n\n    See http://goo.gl/1wAmHx\n");var r=new i(t),o=r.promise();return r.setHowMany(e),r.init(),o}var s=t("./util.js"),a=t("./errors.js").RangeError,u=t("./errors.js").AggregateError,c=s.isArray;s.inherits(i,r),i.prototype._init=function(){if(this._initialized){if(0===this._howMany)return void this._resolve([]);this._init$(void 0,-5);var t=c(this._values);!this._isResolved()&&t&&this._howMany>this._canPossiblyFulfill()&&this._reject(this._getRangeError(this.length()))}},i.prototype.init=function(){this._initialized=!0,this._init()},i.prototype.setUnwrap=function(){this._unwrap=!0},i.prototype.howMany=function(){return this._howMany},i.prototype.setHowMany=function(t){this._howMany=t},i.prototype._promiseFulfilled=function(t){this._addFulfilled(t),this._fulfilled()===this.howMany()&&(this._values.length=this.howMany(),this._resolve(1===this.howMany()&&this._unwrap?this._values[0]:this._values))},i.prototype._promiseRejected=function(t){if(this._addRejected(t),this.howMany()>this._canPossiblyFulfill()){for(var e=new u,r=this.length();r<this._values.length;++r)e.push(this._values[r]);this._reject(e)}},i.prototype._fulfilled=function(){return this._totalResolved},i.prototype._rejected=function(){return this._values.length-this.length()},i.prototype._addRejected=function(t){this._values.push(t)},i.prototype._addFulfilled=function(t){this._values[this._totalResolved++]=t},i.prototype._canPossiblyFulfill=function(){return this.length()-this._rejected()},i.prototype._getRangeError=function(t){var e="Input array must contain at least "+this._howMany+" items but contains only "+t+" items";return new a(e)},i.prototype._resolveEmptyArray=function(){this._reject(this._getRangeError(0))},e.some=function(t,e){return o(t,e)},e.prototype.some=function(t){return o(this,t)},e._SomePromiseArray=i}},{"./errors.js":13,"./util.js":38}],34:[function(t,e){"use strict";e.exports=function(t){function e(t){void 0!==t?(t=t._target(),this._bitField=t._bitField,this._settledValue=t._settledValue):(this._bitField=0,this._settledValue=void 0)}e.prototype.value=function(){if(!this.isFulfilled())throw new TypeError("cannot get fulfillment value of a non-fulfilled promise\n\n    See http://goo.gl/hc1DLj\n");return this._settledValue},e.prototype.error=e.prototype.reason=function(){if(!this.isRejected())throw new TypeError("cannot get rejection reason of a non-rejected promise\n\n    See http://goo.gl/hPuiwB\n");return this._settledValue},e.prototype.isFulfilled=t.prototype._isFulfilled=function(){return(268435456&this._bitField)>0},e.prototype.isRejected=t.prototype._isRejected=function(){return(134217728&this._bitField)>0},e.prototype.isPending=t.prototype._isPending=function(){return 0===(402653184&this._bitField)},e.prototype.isResolved=t.prototype._isResolved=function(){return(402653184&this._bitField)>0},t.prototype.isPending=function(){return this._target()._isPending()},t.prototype.isRejected=function(){return this._target()._isRejected()},t.prototype.isFulfilled=function(){return this._target()._isFulfilled()},t.prototype.isResolved=function(){return this._target()._isResolved()},t.prototype._value=function(){return this._settledValue},t.prototype._reason=function(){return this._unsetRejectionIsUnhandled(),this._settledValue},t.prototype.value=function(){var t=this._target();if(!t.isFulfilled())throw new TypeError("cannot get fulfillment value of a non-fulfilled promise\n\n    See http://goo.gl/hc1DLj\n");return t._settledValue},t.prototype.reason=function(){var t=this._target();if(!t.isRejected())throw new TypeError("cannot get rejection reason of a non-rejected promise\n\n    See http://goo.gl/hPuiwB\n");return t._unsetRejectionIsUnhandled(),t._settledValue},t.PromiseInspection=e}},{}],35:[function(t,e){"use strict";e.exports=function(e,r){function n(t,n){if(c(t)){if(t instanceof e)return t;if(o(t)){var l=new e(r);return t._then(l._fulfillUnchecked,l._rejectUncheckedCheckError,l._progressUnchecked,l,null),l}var h=a.tryCatch(i)(t);if(h===u){n&&n._pushContext();var l=e.reject(h.e);return n&&n._popContext(),l}if("function"==typeof h)return s(t,h,n)}return t}function i(t){return t.then}function o(t){return l.call(t,"_promise0")}function s(t,n,i){function o(t){l&&(l._resolveCallback(t),l=null)}function s(t){l&&(l._rejectCallback(t,p,!0),l=null)}function c(t){l&&"function"==typeof l._progress&&l._progress(t)}var l=new e(r),h=l;i&&i._pushContext(),l._captureStackTrace(),i&&i._popContext();var p=!0,f=a.tryCatch(n).call(t,o,s,c);return p=!1,l&&f===u&&(l._rejectCallback(f.e,!0,!0),l=null),h}var a=t("./util.js"),u=a.errorObj,c=a.isObject,l={}.hasOwnProperty;return n}},{"./util.js":38}],36:[function(t,e){"use strict";e.exports=function(e,r){function n(t){var e=this;return e instanceof Number&&(e=+e),clearTimeout(e),t}function i(t){var e=this;throw e instanceof Number&&(e=+e),clearTimeout(e),t}var o=t("./util.js"),s=e.TimeoutError,a=function(t,e){if(t.isPending()){"string"!=typeof e&&(e="operation timed out");var r=new s(e);o.markAsOriginatingFromRejection(r),t._attachExtraTrace(r),t._cancel(r)}},u=function(t){return c(+this).thenReturn(t)},c=e.delay=function(t,n){if(void 0===n){n=t,t=void 0;var i=new e(r);return setTimeout(function(){i._fulfill()},n),i}return n=+n,e.resolve(t)._then(u,null,null,n,void 0)};e.prototype.delay=function(t){return c(this,t)},e.prototype.timeout=function(t,e){t=+t;var r=this.then().cancellable();r._cancellationParent=this;var o=setTimeout(function(){a(r,e)},t);return r._then(n,i,void 0,o,void 0)}}},{"./util.js":38}],37:[function(t,e){"use strict";e.exports=function(e,r,n,i){function o(t){for(var r=t.length,n=0;r>n;++n){var i=t[n];if(i.isRejected())return e.reject(i.error());t[n]=i._settledValue}return t}function s(t){setTimeout(function(){throw t},0)}function a(t){var e=n(t);return e!==t&&"function"==typeof t._isDisposable&&"function"==typeof t._getDisposer&&t._isDisposable()&&e._setDisposable(t._getDisposer()),e}function u(t,r){function i(){if(o>=u)return c.resolve();var l=a(t[o++]);if(l instanceof e&&l._isDisposable()){try{l=n(l._getDisposer().tryDispose(r),t.promise)}catch(h){return s(h)}if(l instanceof e)return l._then(i,s,null,null,null)}i()}var o=0,u=t.length,c=e.defer();return i(),c.promise}function c(t){var e=new v;return e._settledValue=t,e._bitField=268435456,u(this,e).thenReturn(t)}function l(t){var e=new v;return e._settledValue=t,e._bitField=134217728,u(this,e).thenThrow(t)}function h(t,e,r){this._data=t,this._promise=e,this._context=r}function p(t,e,r){this.constructor$(t,e,r)}function f(t){return h.isDisposer(t)?(this.resources[this.index]._setDisposable(t),t.promise()):t}var _=t("./errors.js").TypeError,d=t("./util.js").inherits,v=e.PromiseInspection;h.prototype.data=function(){return this._data},h.prototype.promise=function(){return this._promise},h.prototype.resource=function(){return this.promise().isFulfilled()?this.promise().value():null},h.prototype.tryDispose=function(t){var e=this.resource(),r=this._context;void 0!==r&&r._pushContext();var n=null!==e?this.doDispose(e,t):null;return void 0!==r&&r._popContext(),this._promise._unsetDisposable(),this._data=null,n},h.isDisposer=function(t){return null!=t&&"function"==typeof t.resource&&"function"==typeof t.tryDispose},d(p,h),p.prototype.doDispose=function(t,e){var r=this.data();return r.call(t,t,e)},e.using=function(){var t=arguments.length;if(2>t)return r("you must pass at least 2 arguments to Promise.using");var i=arguments[t-1];if("function"!=typeof i)return r("fn must be a function\n\n    See http://goo.gl/916lJJ\n");t--;for(var s=new Array(t),a=0;t>a;++a){var u=arguments[a];if(h.isDisposer(u)){var p=u;u=u.promise(),u._setDisposable(p)}else{var _=n(u);_ instanceof e&&(u=_._then(f,null,null,{resources:s,index:a},void 0))}s[a]=u}var d=e.settle(s).then(o).then(function(t){d._pushContext();var e;try{e=i.apply(void 0,t)}finally{d._popContext()}return e})._then(c,l,void 0,s,void 0);return s.promise=d,d},e.prototype._setDisposable=function(t){this._bitField=262144|this._bitField,this._disposer=t
+},e.prototype._isDisposable=function(){return(262144&this._bitField)>0},e.prototype._getDisposer=function(){return this._disposer},e.prototype._unsetDisposable=function(){this._bitField=-262145&this._bitField,this._disposer=void 0},e.prototype.disposer=function(t){if("function"==typeof t)return new p(t,this,i());throw new _}}},{"./errors.js":13,"./util.js":38}],38:[function(t,e,r){"use strict";function n(){try{var t=C;return C=null,t.apply(this,arguments)}catch(e){return F.e=e,F}}function i(t){return C=t,n}function o(t){return null==t||t===!0||t===!1||"string"==typeof t||"number"==typeof t}function s(t){return!o(t)}function a(t){return o(t)?new Error(v(t)):t}function u(t,e){var r,n=t.length,i=new Array(n+1);for(r=0;n>r;++r)i[r]=t[r];return i[r]=e,i}function c(t,e,r){if(!w.isES5)return{}.hasOwnProperty.call(t,e)?t[e]:void 0;var n=Object.getOwnPropertyDescriptor(t,e);return null!=n?null==n.get&&null==n.set?n.value:r:void 0}function l(t,e,r){if(o(t))return t;var n={value:r,configurable:!0,enumerable:!1,writable:!0};return w.defineProperty(t,e,n),t}function h(t){throw t}function p(t){try{if("function"==typeof t){var e=w.names(t.prototype),r=w.isES5&&e.length>1,n=e.length>0&&!(1===e.length&&"constructor"===e[0]),i=x.test(t+"")&&w.names(t).length>0;if(r||n||i)return!0}return!1}catch(o){return!1}}function f(t){function e(){}e.prototype=t;for(var r=8;r--;)new e;return t}function _(t){return R.test(t)}function d(t,e,r){for(var n=new Array(t),i=0;t>i;++i)n[i]=e+i+r;return n}function v(t){try{return t+""}catch(e){return"[no string representation]"}}function y(t){try{l(t,"isOperational",!0)}catch(e){}}function g(t){return null==t?!1:t instanceof Error.__BluebirdErrorTypes__.OperationalError||t.isOperational===!0}function m(t){return t instanceof Error&&w.propertyIsWritable(t,"stack")}function j(t){return{}.toString.call(t)}function b(t,e,r){for(var n=w.names(t),i=0;i<n.length;++i){var o=n[i];if(r(o))try{w.defineProperty(e,o,w.getDescriptor(t,o))}catch(s){}}}var w=t("./es5.js"),k="undefined"==typeof navigator,E=function(){try{var t={};return w.defineProperty(t,"f",{get:function(){return 3}}),3===t.f}catch(e){return!1}}(),F={e:{}},C,P=function(t,e){function r(){this.constructor=t,this.constructor$=e;for(var r in e.prototype)n.call(e.prototype,r)&&"$"!==r.charAt(r.length-1)&&(this[r+"$"]=e.prototype[r])}var n={}.hasOwnProperty;return r.prototype=e.prototype,t.prototype=new r,t.prototype},T=function(){var t=[Array.prototype,Object.prototype,Function.prototype],e=function(e){for(var r=0;r<t.length;++r)if(t[r]===e)return!0;return!1};if(w.isES5){var r=Object.getOwnPropertyNames;return function(t){for(var n=[],i=Object.create(null);null!=t&&!e(t);){var o;try{o=r(t)}catch(s){return n}for(var a=0;a<o.length;++a){var u=o[a];if(!i[u]){i[u]=!0;var c=Object.getOwnPropertyDescriptor(t,u);null!=c&&null==c.get&&null==c.set&&n.push(u)}}t=w.getPrototypeOf(t)}return n}}var n={}.hasOwnProperty;return function(r){if(e(r))return[];var i=[];t:for(var o in r)if(n.call(r,o))i.push(o);else{for(var s=0;s<t.length;++s)if(n.call(t[s],o))continue t;i.push(o)}return i}}(),x=/this\s*\.\s*\S+\s*=/,R=/^[a-z$_][a-z$_0-9]*$/i,S=function(){return"stack"in new Error?function(t){return m(t)?t:new Error(v(t))}:function(t){if(m(t))return t;try{throw new Error(v(t))}catch(e){return e}}}(),A={isClass:p,isIdentifier:_,inheritedDataKeys:T,getDataPropertyOrDefault:c,thrower:h,isArray:w.isArray,haveGetters:E,notEnumerableProp:l,isPrimitive:o,isObject:s,canEvaluate:k,errorObj:F,tryCatch:i,inherits:P,withAppended:u,maybeWrapAsError:a,toFastProperties:f,filledRange:d,toString:v,canAttachTrace:m,ensureErrorObject:S,originatesFromRejection:g,markAsOriginatingFromRejection:y,classString:j,copyDescriptors:b,hasDevTools:"undefined"!=typeof chrome&&chrome&&"function"==typeof chrome.loadTimes,isNode:"undefined"!=typeof process&&"[object process]"===j(process).toLowerCase()};A.isRecentNode=A.isNode&&function(){var t=process.versions.node.split(".").map(Number);return 0===t[0]&&t[1]>10||t[0]>0}(),A.isNode&&A.toFastProperties(process);try{throw new Error}catch(O){A.lastLineError=O}e.exports=A},{"./es5.js":14}]},{},[4])(4)}),"undefined"!=typeof window&&null!==window?window.P=window.Promise:"undefined"!=typeof self&&null!==self&&(self.P=self.Promise);
\ No newline at end of file
index d6f6da2..9d8257a 100644 (file)
@@ -10,7 +10,6 @@ var targetRejected = function(e, context) {
 };
 
 var bindingResolved = function(thisArg, context) {
-    this._setBoundTo(thisArg);
     if (this._isPending()) {
         this._resolveCallback(context.target);
     }
@@ -25,6 +24,8 @@ Promise.prototype.bind = function (thisArg) {
     var ret = new Promise(INTERNAL);
     ret._propagateFrom(this, 1);
     var target = this._target();
+
+    ret._setBoundTo(maybePromise);
     if (maybePromise instanceof Promise) {
         var context = {
             promiseRejectionQueued: false,
@@ -36,7 +37,6 @@ Promise.prototype.bind = function (thisArg) {
         maybePromise._then(
             bindingResolved, bindingRejected, ret._progress, ret, context);
     } else {
-        ret._setBoundTo(thisArg);
         ret._resolveCallback(target);
     }
     return ret;
@@ -59,13 +59,12 @@ Promise.bind = function (thisArg, value) {
     var maybePromise = tryConvertToPromise(thisArg);
     var ret = new Promise(INTERNAL);
 
+    ret._setBoundTo(maybePromise);
     if (maybePromise instanceof Promise) {
-        maybePromise._then(function(thisArg) {
-            ret._setBoundTo(thisArg);
+        maybePromise._then(function() {
             ret._resolveCallback(value);
         }, ret._reject, ret._progress, ret, null);
     } else {
-        ret._setBoundTo(thisArg);
         ret._resolveCallback(value);
     }
     return ret;
index 040f057..df12733 100644 (file)
@@ -30,7 +30,7 @@ function safePredicate(predicate, e) {
 CatchFilter.prototype.doFilter = function (e) {
     var cb = this._callback;
     var promise = this._promise;
-    var boundTo = promise._boundTo;
+    var boundTo = promise._boundValue();
     for (var i = 0, len = this._instances.length; i < len; ++i) {
         var item = this._instances[i];
         var itemIsErrorType = item === Error ||
index 07fdce2..c9342bc 100644 (file)
@@ -35,7 +35,7 @@ function finallyHandler(reasonOrValue) {
     var handler = this.handler;
 
     var ret = promise._isBound()
-                    ? handler.call(promise._boundTo)
+                    ? handler.call(promise._boundValue())
                     : handler();
 
     if (ret !== undefined) {
@@ -60,7 +60,7 @@ function tapHandler(value) {
     var handler = this.handler;
 
     var ret = promise._isBound()
-                    ? handler.call(promise._boundTo, value)
+                    ? handler.call(promise._boundValue(), value)
                     : handler(value);
 
     if (ret !== undefined) {
index 66a5b17..2f40efd 100644 (file)
@@ -4,6 +4,7 @@ module.exports = function(Promise,
                           apiRejection,
                           tryConvertToPromise,
                           INTERNAL) {
+var getDomain = Promise._getDomain;
 var async = require("./async.js");
 var util = require("./util.js");
 var tryCatch = util.tryCatch;
@@ -14,7 +15,8 @@ var EMPTY_ARRAY = [];
 function MappingPromiseArray(promises, fn, limit, _filter) {
     this.constructor$(promises);
     this._promise._captureStackTrace();
-    this._callback = fn;
+    var domain = getDomain();
+    this._callback = domain === null ? fn : domain.bind(fn);
     this._preservedValues = _filter === INTERNAL
         ? new Array(this.length())
         : null;
@@ -49,7 +51,7 @@ MappingPromiseArray.prototype._promiseFulfilled = function (value, index) {
         if (preservedValues !== null) preservedValues[index] = value;
 
         var callback = this._callback;
-        var receiver = this._promise._boundTo;
+        var receiver = this._promise._boundValue();
         this._promise._pushContext();
         var ret = tryCatch(callback).call(receiver, value, index, length);
         this._promise._popContext();
index f305b93..257565d 100644 (file)
@@ -8,7 +8,8 @@ var errorObj = util.errorObj;
 function spreadAdapter(val, nodeback) {
     var promise = this;
     if (!util.isArray(val)) return successAdapter.call(promise, val, nodeback);
-    var ret = tryCatch(nodeback).apply(promise._boundTo, [null].concat(val));
+    var ret =
+        tryCatch(nodeback).apply(promise._boundValue(), [null].concat(val));
     if (ret === errorObj) {
         async.throwLater(ret.e);
     }
@@ -16,7 +17,7 @@ function spreadAdapter(val, nodeback) {
 
 function successAdapter(val, nodeback) {
     var promise = this;
-    var receiver = promise._boundTo;
+    var receiver = promise._boundValue();
     var ret = val === undefined
         ? tryCatch(nodeback).call(receiver, null)
         : tryCatch(nodeback).call(receiver, null, val);
@@ -32,13 +33,13 @@ function errorAdapter(reason, nodeback) {
         newReason.cause = reason;
         reason = newReason;
     }
-    var ret = tryCatch(nodeback).call(promise._boundTo, reason);
+    var ret = tryCatch(nodeback).call(promise._boundValue(), reason);
     if (ret === errorObj) {
         async.throwLater(ret.e);
     }
 }
 
-Promise.prototype.asCallback = 
+Promise.prototype.asCallback =
 Promise.prototype.nodeify = function (nodeback, options) {
     if (typeof nodeback == "function") {
         var adapter = successAdapter;
index 28dc1f7..eb08118 100644 (file)
@@ -311,7 +311,7 @@ Promise.prototype._receiverAt = function (index) {
         : this[
             index * 5 - 5 + 4];
     if (ret === undefined && this._isBound()) {
-        return this._boundTo;
+        return this._boundValue();
     }
     return ret;
 };
@@ -334,6 +334,20 @@ Promise.prototype._rejectionHandlerAt = function (index) {
         : this[index * 5 - 5 + 1];
 };
 
+Promise.prototype._boundValue = function() {
+    var ret = this._boundTo;
+    if (ret !== undefined) {
+        if (ret instanceof Promise) {
+            if (ret.isFulfilled()) {
+                return ret.value();
+            } else {
+                return undefined;
+            }
+        }
+    }
+    return ret;
+};
+
 Promise.prototype._migrateCallbacks = function (follower, index) {
     var fulfill = follower._fulfillmentHandlerAt(index);
     var reject = follower._rejectionHandlerAt(index);
@@ -484,7 +498,7 @@ Promise.prototype._settlePromiseFromHandler = function (
     promise._pushContext();
     var x;
     if (receiver === APPLY && !this._isRejected()) {
-        x = tryCatch(handler).apply(this._boundTo, value);
+        x = tryCatch(handler).apply(this._boundValue(), value);
     } else {
         x = tryCatch(handler).call(receiver, value);
     }
@@ -554,8 +568,6 @@ Promise.prototype._settlePromiseAt = function (index) {
         this._isCarryingStackTrace() ? this._getCarriedStackTrace() : undefined;
     var value = this._settledValue;
     var receiver = this._receiverAt(index);
-
-
     this._clearCallbackDataAtIndex(index);
 
     if (typeof handler === "function") {
index 3192220..1f92daf 100644 (file)
@@ -4,6 +4,7 @@ module.exports = function(Promise,
                           apiRejection,
                           tryConvertToPromise,
                           INTERNAL) {
+var getDomain = Promise._getDomain;
 var async = require("./async.js");
 var util = require("./util.js");
 var tryCatch = util.tryCatch;
@@ -32,7 +33,8 @@ function ReductionPromiseArray(promises, fn, accum, _each) {
         }
     }
     if (!(isPromise || this._zerothIsAccum)) this._gotAccum = true;
-    this._callback = fn;
+    var domain = getDomain();
+    this._callback = domain === null ? fn : domain.bind(fn);
     this._accum = accum;
     if (!rejected) async.invoke(init, this, undefined);
 }
@@ -86,7 +88,7 @@ ReductionPromiseArray.prototype._promiseFulfilled = function (value, index) {
     if (!gotAccum) return;
 
     var callback = this._callback;
-    var receiver = this._promise._boundTo;
+    var receiver = this._promise._boundValue();
     var ret;
 
     for (var i = this._reducingIndex; i < length; ++i) {
index c55cd23..2b598a1 100644 (file)
@@ -1,7 +1,7 @@
 {
   "name": "bluebird",
   "description": "Full featured Promises/A+ implementation with exceptionally good performance",
-  "version": "2.9.33",
+  "version": "2.9.34",
   "keywords": [
     "promise",
     "performance",
@@ -74,9 +74,9 @@
     "js/zalgo",
     "zalgo.js"
   ],
-  "gitHead": "91d6254f5863304cb9989fca5587122437e9648d",
-  "_id": "bluebird@2.9.33",
-  "_shasum": "c8bc26cebacfa8293124199d927b4c7de8ce801d",
+  "gitHead": "386ba4f7d588693e5d675290a6b7fade08e0d626",
+  "_id": "bluebird@2.9.34",
+  "_shasum": "2f7b4ec80216328a9fddebdf69c8d4942feff7d8",
   "_from": "bluebird@>=2.9.30 <3.0.0",
   "_npmVersion": "2.11.1",
   "_nodeVersion": "2.3.0",
     }
   ],
   "dist": {
-    "shasum": "c8bc26cebacfa8293124199d927b4c7de8ce801d",
-    "tarball": "http://registry.npmjs.org/bluebird/-/bluebird-2.9.33.tgz"
+    "shasum": "2f7b4ec80216328a9fddebdf69c8d4942feff7d8",
+    "tarball": "http://registry.npmjs.org/bluebird/-/bluebird-2.9.34.tgz"
   },
   "directories": {},
-  "_resolved": "https://registry.npmjs.org/bluebird/-/bluebird-2.9.33.tgz",
+  "_resolved": "https://registry.npmjs.org/bluebird/-/bluebird-2.9.34.tgz",
   "readme": "ERROR: No README data found!"
 }
index b2bafb2..813c908 100644 (file)
   },
   "maintainers": [
     {
-      "name": "Sindre Sorhus",
-      "email": "sindresorhus@gmail.com",
-      "url": "http://sindresorhus.com"
+      "name": "sindresorhus",
+      "email": "sindresorhus@gmail.com"
     },
     {
-      "name": "Joshua Appelman",
-      "email": "jappelman@xebia.com",
-      "url": "http://jbnicolai.com"
+      "name": "jbnicolai",
+      "email": "jappelman@xebia.com"
     }
   ],
   "engines": {
   "devDependencies": {
     "mocha": "*"
   },
-  "readme": "# escape-string-regexp [![Build Status](https://travis-ci.org/sindresorhus/escape-string-regexp.svg?branch=master)](https://travis-ci.org/sindresorhus/escape-string-regexp)\n\n> Escape RegExp special characters\n\n\n## Install\n\n```sh\n$ npm install --save escape-string-regexp\n```\n\n\n## Usage\n\n```js\nvar escapeStringRegexp = require('escape-string-regexp');\n\nvar escapedString = escapeStringRegexp('how much $ for a unicorn?');\n//=> how much \\$ for a unicorn\\?\n\nnew RegExp(escapedString);\n```\n\n\n## License\n\nMIT © [Sindre Sorhus](http://sindresorhus.com)\n",
-  "readmeFilename": "readme.md",
+  "gitHead": "1e446e6b4449b5f1f8868cd31bf8fd25ee37fb4b",
   "bugs": {
     "url": "https://github.com/sindresorhus/escape-string-regexp/issues"
   },
-  "homepage": "https://github.com/sindresorhus/escape-string-regexp#readme",
+  "homepage": "https://github.com/sindresorhus/escape-string-regexp",
   "_id": "escape-string-regexp@1.0.3",
   "_shasum": "9e2d8b25bc2555c3336723750e03f099c2735bb5",
+  "_from": "escape-string-regexp@>=1.0.2 <2.0.0",
+  "_npmVersion": "2.1.16",
+  "_nodeVersion": "0.10.35",
+  "_npmUser": {
+    "name": "jbnicolai",
+    "email": "jappelman@xebia.com"
+  },
+  "dist": {
+    "shasum": "9e2d8b25bc2555c3336723750e03f099c2735bb5",
+    "tarball": "http://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.3.tgz"
+  },
+  "directories": {},
   "_resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.3.tgz",
-  "_from": "escape-string-regexp@>=1.0.2 <2.0.0"
+  "readme": "ERROR: No README data found!"
 }
index 64d7d64..5b8486a 100644 (file)
   "scripts": {
     "test": "echo \"Error: no test specified\" && exit 1"
   },
-  "readme": "# graceful-readlink\n[![NPM Version](http://img.shields.io/npm/v/graceful-readlink.svg?style=flat)](https://www.npmjs.org/package/graceful-readlink)\n[![NPM Downloads](https://img.shields.io/npm/dm/graceful-readlink.svg?style=flat)](https://www.npmjs.org/package/graceful-readlink)\n\n\n## Usage\n\n```js\nvar readlinkSync = require('graceful-readlink').readlinkSync;\nconsole.log(readlinkSync(f));\n// output\n//  the file pointed to when `f` is a symbolic link\n//  the `f` itself when `f` is not a symbolic link\n```\n## Licence\n\nMIT License\n",
-  "readmeFilename": "README.md",
+  "gitHead": "f6655275bebef706fb63fd01b5f062a7052419a5",
   "_id": "graceful-readlink@1.0.1",
   "_shasum": "4cafad76bc62f02fa039b2f94e9a3dd3a391a725",
+  "_from": "graceful-readlink@>=1.0.0",
+  "_npmVersion": "2.1.17",
+  "_nodeVersion": "0.11.14",
+  "_npmUser": {
+    "name": "zhiyelee",
+    "email": "zhiyelee@gmail.com"
+  },
+  "maintainers": [
+    {
+      "name": "zhiyelee",
+      "email": "zhiyelee@gmail.com"
+    }
+  ],
+  "dist": {
+    "shasum": "4cafad76bc62f02fa039b2f94e9a3dd3a391a725",
+    "tarball": "http://registry.npmjs.org/graceful-readlink/-/graceful-readlink-1.0.1.tgz"
+  },
+  "directories": {},
   "_resolved": "https://registry.npmjs.org/graceful-readlink/-/graceful-readlink-1.0.1.tgz",
-  "_from": "graceful-readlink@>=1.0.0"
+  "readme": "ERROR: No README data found!"
 }
index e2bc772..db1ac2a 100644 (file)
   "devDependencies": {
     "tape": "^2.13.4"
   },
-  "readme": "# generate-function\n\nModule that helps you write generated functions in Node\n\n```\nnpm install generate-function\n```\n\n[![build status](http://img.shields.io/travis/mafintosh/generate-function.svg?style=flat)](http://travis-ci.org/mafintosh/generate-function)\n\n## Disclamer\n\nWriting code that generates code is hard.\nYou should only use this if you really, really, really need this for performance reasons (like schema validators / parsers etc).\n\n## Usage\n\n``` js\nvar genfun = require('generate-function')\n\nvar addNumber = function(val) {\n  var fn = genfun()\n    ('function add(n) {')\n      ('return n + %d', val) // supports format strings to insert values\n    ('}')\n\n  return fn.toFunction() // will compile the function\n}\n\nvar add2 = addNumber(2)\n\nconsole.log('1+2=', add2(1))\nconsole.log(add2.toString()) // prints the generated function\n```\n\nIf you need to close over variables in your generated function pass them to `toFunction(scope)`\n\n``` js\nvar multiply = function(a, b) {\n  return a * b\n}\n\nvar addAndMultiplyNumber = function(val) {\n  var fn = genfun()\n    ('function(n) {')\n      ('if (typeof n !== \"number\") {') // ending a line with { will indent the source\n        ('throw new Error(\"argument should be a number\")')\n      ('}')\n      ('var result = multiply(%d, n+%d)', val, val)\n      ('return result')\n    ('}')\n\n  // use fn.toString() if you want to see the generated source\n\n  return fn.toFunction({\n    multiply: multiply\n  })\n}\n\nvar addAndMultiply2 = addAndMultiplyNumber(2)\n\nconsole.log('(3 + 2) * 2 =', addAndMultiply2(3))\n```\n\n## Related\n\nSee [generate-object-property](https://github.com/mafintosh/generate-object-property) if you need to safely generate code that\ncan be used to reference an object property\n\n## License\n\nMIT",
-  "readmeFilename": "README.md",
+  "gitHead": "3d5fc8de5859be95f58e3af9bfb5f663edd95149",
   "_id": "generate-function@2.0.0",
   "_shasum": "6858fe7c0969b7d4e9093337647ac79f60dfbe74",
+  "_from": "generate-function@>=2.0.0 <3.0.0",
+  "_npmVersion": "1.4.23",
+  "_npmUser": {
+    "name": "mafintosh",
+    "email": "mathiasbuus@gmail.com"
+  },
+  "maintainers": [
+    {
+      "name": "mafintosh",
+      "email": "mathiasbuus@gmail.com"
+    }
+  ],
+  "dist": {
+    "shasum": "6858fe7c0969b7d4e9093337647ac79f60dfbe74",
+    "tarball": "http://registry.npmjs.org/generate-function/-/generate-function-2.0.0.tgz"
+  },
+  "directories": {},
   "_resolved": "https://registry.npmjs.org/generate-function/-/generate-function-2.0.0.tgz",
-  "_from": "generate-function@>=2.0.0 <3.0.0"
+  "readme": "ERROR: No README data found!"
 }
index 41225e2..9f23619 100644 (file)
     "name": "Mikola Lysenko"
   },
   "license": "MIT",
-  "readmeFilename": "README.md",
   "gitHead": "0a85ea5b6b1264ea1cdecc6e5cf186adbb3ffc50",
   "bugs": {
     "url": "https://github.com/mikolalysenko/is-property/issues"
   },
-  "readme": "is-property\n===========\nTests if a property of a JavaScript object can be accessed using the dot (.) notation or if it must be enclosed in brackets, (ie use x[\" ... \"])\n\nExample\n-------\n\n```javascript\nvar isProperty = require(\"is-property\")\n\nconsole.log(isProperty(\"foo\"))  //Prints true\nconsole.log(isProperty(\"0\"))    //Prints false\n```\n\nInstall\n-------\n\n    npm install is-property\n    \n### `require(\"is-property\")(str)`\nChecks if str is a property\n\n* `str` is a string which we will test if it is a property or not\n\n**Returns** true or false depending if str is a property\n\n## Credits\n(c) 2013 Mikola Lysenko. MIT License",
-  "homepage": "https://github.com/mikolalysenko/is-property#readme",
+  "homepage": "https://github.com/mikolalysenko/is-property",
   "_id": "is-property@1.0.2",
   "_shasum": "57fe1c4e48474edd65b09911f26b1cd4095dda84",
+  "_from": "is-property@>=1.0.0 <2.0.0",
+  "_npmVersion": "2.1.4",
+  "_nodeVersion": "0.10.26",
+  "_npmUser": {
+    "name": "mikolalysenko",
+    "email": "mikolalysenko@gmail.com"
+  },
+  "maintainers": [
+    {
+      "name": "mikolalysenko",
+      "email": "mikolalysenko@gmail.com"
+    }
+  ],
+  "dist": {
+    "shasum": "57fe1c4e48474edd65b09911f26b1cd4095dda84",
+    "tarball": "http://registry.npmjs.org/is-property/-/is-property-1.0.2.tgz"
+  },
   "_resolved": "https://registry.npmjs.org/is-property/-/is-property-1.0.2.tgz",
-  "_from": "is-property@>=1.0.0 <2.0.0"
+  "readme": "ERROR: No README data found!"
 }
index 64e45bd..a86a787 100644 (file)
   "scripts": {
     "test": "node test.js"
   },
-  "readme": "# JSON Pointer for nodejs\n\nThis is an implementation of [JSON Pointer](http://tools.ietf.org/html/draft-ietf-appsawg-json-pointer-08).\n\n## Usage\n\n    var jsonpointer = require(\"jsonpointer\");\n    var obj = { foo: 1, bar: { baz: 2}, qux: [3, 4, 5]};\n    var one = jsonpointer.get(obj, \"/foo\");\n    var two = jsonpointer.get(obj, \"/bar/baz\");\n    var three = jsonpointer.get(obj, \"/qux/0\");\n    var four = jsonpointer.get(obj, \"/qux/1\");\n    var five = jsonpointer.get(obj, \"/qux/2\");\n\n    jsonpointer.set(obj, \"/foo\", 6); // obj.foo = 6;\n\n## Testing\n\n    $ node test.js\n    All tests pass.\n    $\n\n[![Build Status](https://travis-ci.org/janl/node-jsonpointer.png?branch=master)](undefined)\n\n## Author\n\n(c) 2011 Jan Lehnardt <jan@apache.org>\n\n## License\n\nMIT License.",
-  "readmeFilename": "README.md",
-  "homepage": "https://github.com/janl/node-jsonpointer#readme",
   "_id": "jsonpointer@1.1.0",
+  "dist": {
+    "shasum": "c3c72efaed3b97154163dc01dd349e1cfe0f80fc",
+    "tarball": "http://registry.npmjs.org/jsonpointer/-/jsonpointer-1.1.0.tgz"
+  },
+  "_npmVersion": "1.1.69",
+  "_npmUser": {
+    "name": "jan",
+    "email": "jan@apache.org"
+  },
+  "maintainers": [
+    {
+      "name": "jan",
+      "email": "jan@apache.org"
+    }
+  ],
+  "directories": {},
   "_shasum": "c3c72efaed3b97154163dc01dd349e1cfe0f80fc",
   "_resolved": "https://registry.npmjs.org/jsonpointer/-/jsonpointer-1.1.0.tgz",
-  "_from": "jsonpointer@>=1.1.0 <2.0.0"
+  "_from": "jsonpointer@>=1.1.0 <2.0.0",
+  "readme": "ERROR: No README data found!",
+  "homepage": "https://github.com/janl/node-jsonpointer#readme"
 }
diff --git a/deps/npm/node_modules/request/node_modules/har-validator/node_modules/is-my-json-valid/node_modules/xtend/.jshintrc b/deps/npm/node_modules/request/node_modules/har-validator/node_modules/is-my-json-valid/node_modules/xtend/.jshintrc
deleted file mode 100644 (file)
index 77887b5..0000000
+++ /dev/null
@@ -1,30 +0,0 @@
-{
-    "maxdepth": 4,
-    "maxstatements": 200,
-    "maxcomplexity": 12,
-    "maxlen": 80,
-    "maxparams": 5,
-
-    "curly": true,
-    "eqeqeq": true,
-    "immed": true,
-    "latedef": false,
-    "noarg": true,
-    "noempty": true,
-    "nonew": true,
-    "undef": true,
-    "unused": "vars",
-    "trailing": true,
-
-    "quotmark": true,
-    "expr": true,
-    "asi": true,
-
-    "browser": false,
-    "esnext": true,
-    "devel": false,
-    "node": false,
-    "nonstandard": false,
-
-    "predef": ["require", "module", "__dirname", "__filename"]
-}
index c087642..907a720 100644 (file)
   "engines": {
     "node": ">=0.4"
   },
-  "readme": "# xtend\n\n[![browser support][3]][4]\n\n[![locked](http://badges.github.io/stability-badges/dist/locked.svg)](http://github.com/badges/stability-badges)\n\nExtend like a boss\n\nxtend is a basic utility library which allows you to extend an object by appending all of the properties from each object in a list. When there are identical properties, the right-most property takes precedence.\n\n## Examples\n\n```js\nvar extend = require(\"xtend\")\n\n// extend returns a new object. Does not mutate arguments\nvar combination = extend({\n    a: \"a\",\n    b: 'c'\n}, {\n    b: \"b\"\n})\n// { a: \"a\", b: \"b\" }\n```\n\n## Stability status: Locked\n\n## MIT Licenced\n\n\n  [3]: http://ci.testling.com/Raynos/xtend.png\n  [4]: http://ci.testling.com/Raynos/xtend\n",
-  "readmeFilename": "README.md",
+  "gitHead": "94a95d76154103290533b2c55ffa0fe4be16bfef",
   "_id": "xtend@4.0.0",
   "_shasum": "8bc36ff87aedbe7ce9eaf0bca36b2354a743840f",
+  "_from": "xtend@>=4.0.0 <5.0.0",
+  "_npmVersion": "1.4.15",
+  "_npmUser": {
+    "name": "raynos",
+    "email": "raynos2@gmail.com"
+  },
+  "maintainers": [
+    {
+      "name": "raynos",
+      "email": "raynos2@gmail.com"
+    }
+  ],
+  "dist": {
+    "shasum": "8bc36ff87aedbe7ce9eaf0bca36b2354a743840f",
+    "tarball": "http://registry.npmjs.org/xtend/-/xtend-4.0.0.tgz"
+  },
+  "directories": {},
   "_resolved": "https://registry.npmjs.org/xtend/-/xtend-4.0.0.tgz",
-  "_from": "xtend@>=4.0.0 <5.0.0"
+  "readme": "ERROR: No README data found!"
 }
diff --git a/deps/npm/node_modules/request/node_modules/hawk/Makefile b/deps/npm/node_modules/request/node_modules/hawk/Makefile
deleted file mode 100755 (executable)
index b102d5a..0000000
+++ /dev/null
@@ -1,8 +0,0 @@
-test:
-       @node node_modules/lab/bin/lab -a code
-test-cov: 
-       @node node_modules/lab/bin/lab -a code -t 100
-test-cov-html:
-       @node node_modules/lab/bin/lab -a code -r html -o coverage.html
-
-.PHONY: test test-cov test-cov-html
index 0bcd287..4aff23f 100755 (executable)
@@ -3,10 +3,9 @@
 <img align="right" src="https://raw.github.com/hueniverse/hawk/master/images/logo.png" /> **Hawk** is an HTTP authentication scheme using a message authentication code (MAC) algorithm to provide partial
 HTTP request cryptographic verification. For more complex use cases such as access delegation, see [Oz](https://github.com/hueniverse/oz).
 
-Current version: **2.3**
+Current version: **3.x**
 
-Note: 2.x is the same exact protocol as 1.1. The version increment reflects a change in the internal error format
-used by the module and used by the node API.
+Note: 3.x and 2.x are the same exact protocol as 1.1. The version increments reflect changes in the node API.
 
 [![Build Status](https://secure.travis-ci.org/hueniverse/hawk.png)](http://travis-ci.org/hueniverse/hawk)
 
index 8c063f6..13b860b 100755 (executable)
@@ -10,7 +10,7 @@ var Hawk = require('../lib');
 var internals = {
     credentials: {
         dh37fgj492je: {
-            id: 'dh37fgj492je',                                             // Required by Hawk.client.header 
+            id: 'dh37fgj492je',                                             // Required by Hawk.client.header
             key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
             algorithm: 'sha256',
             user: 'Steve'
diff --git a/deps/npm/node_modules/request/node_modules/hawk/index.js b/deps/npm/node_modules/request/node_modules/hawk/index.js
deleted file mode 100755 (executable)
index 4cc88b3..0000000
+++ /dev/null
@@ -1 +0,0 @@
-module.exports = require('./lib');
\ No newline at end of file
index 3307fa2..7ccacf6 100755 (executable)
@@ -238,18 +238,18 @@ hawk.client = {
 
             // Parse HTTP WWW-Authenticate header
 
-            var attributes = hawk.utils.parseAuthorizationHeader(wwwAuthenticate, ['ts', 'tsm', 'error']);
-            if (!attributes) {
+            var wwwAttributes = hawk.utils.parseAuthorizationHeader(wwwAuthenticate, ['ts', 'tsm', 'error']);
+            if (!wwwAttributes) {
                 return false;
             }
 
-            if (attributes.ts) {
-                var tsm = hawk.crypto.calculateTsMac(attributes.ts, credentials);
-                if (tsm !== attributes.tsm) {
+            if (wwwAttributes.ts) {
+                var tsm = hawk.crypto.calculateTsMac(wwwAttributes.ts, credentials);
+                if (tsm !== wwwAttributes.tsm) {
                     return false;
                 }
 
-                hawk.utils.setNtpOffset(attributes.ts - Math.floor((new Date()).getTime() / 1000));     // Keep offset at 1 second precision
+                hawk.utils.setNtpOffset(wwwAttributes.ts - Math.floor((new Date()).getTime() / 1000));     // Keep offset at 1 second precision
             }
         }
 
@@ -617,6 +617,7 @@ hawk.utils = {
 
 
 // $lab:coverage:off$
+/* eslint-disable */
 
 // Based on: Crypto-JS v3.1.2
 // Copyright (c) 2009-2013, Jeff Mott. All rights reserved.
@@ -638,4 +639,5 @@ if (typeof module !== 'undefined' && module.exports) {
     module.exports = hawk;
 }
 
+/* eslint-enable */
 // $lab:coverage:on$
index 7fdd484..b3e8649 100755 (executable)
@@ -153,16 +153,16 @@ exports.authenticate = function (res, credentials, artifacts, options) {
 
         // Parse HTTP WWW-Authenticate header
 
-        var attributes = Utils.parseAuthorizationHeader(res.headers['www-authenticate'], ['ts', 'tsm', 'error']);
-        if (attributes instanceof Error) {
+        var wwwAttributes = Utils.parseAuthorizationHeader(res.headers['www-authenticate'], ['ts', 'tsm', 'error']);
+        if (wwwAttributes instanceof Error) {
             return false;
         }
 
         // Validate server timestamp (not used to update clock since it is done via the SNPT client)
 
-        if (attributes.ts) {
-            var tsm = Crypto.calculateTsMac(attributes.ts, credentials);
-            if (tsm !== attributes.tsm) {
+        if (wwwAttributes.ts) {
+            var tsm = Crypto.calculateTsMac(wwwAttributes.ts, credentials);
+            if (tsm !== wwwAttributes.tsm) {
                 return false;
             }
         }
index a803930..a325d56 100755 (executable)
@@ -16,7 +16,7 @@ var internals = {};
 
 /*
    req:                 node's HTTP request object or an object as follows:
-  
+
                         var request = {
                             method: 'GET',
                             url: '/resource/4?a=1&b=2',
@@ -24,21 +24,21 @@ var internals = {};
                             port: 8080,
                             authorization: 'Hawk id="dh37fgj492je", ts="1353832234", nonce="j4h3g2", ext="some-app-ext-data", mac="6R4rV5iE+NPoym+WwjeHzjAGXUtLNIxmo1vpMofpLAE="'
                         };
-  
+
    credentialsFunc:     required function to lookup the set of Hawk credentials based on the provided credentials id.
                         The credentials include the MAC key, MAC algorithm, and other attributes (such as username)
                         needed by the application. This function is the equivalent of verifying the username and
                         password in Basic authentication.
-  
+
                         var credentialsFunc = function (id, callback) {
-    
+
                             // Lookup credentials in database
                             db.lookup(id, function (err, item) {
-    
+
                                 if (err || !item) {
                                     return callback(err);
                                 }
-    
+
                                 var credentials = {
                                     // Required
                                     key: item.key,
@@ -46,27 +46,27 @@ var internals = {};
                                     // Application specific
                                     user: item.user
                                 };
-    
+
                                 return callback(null, credentials);
                             });
                         };
-  
+
    options: {
 
         hostHeaderName:        optional header field name, used to override the default 'Host' header when used
                                behind a cache of a proxy. Apache2 changes the value of the 'Host' header while preserving
                                the original (which is what the module must verify) in the 'x-forwarded-host' header field.
                                Only used when passed a node Http.ServerRequest object.
-  
-        nonceFunc:             optional nonce validation function. The function signature is function(nonce, ts, callback)
+
+        nonceFunc:             optional nonce validation function. The function signature is function(key, nonce, ts, callback)
                                where 'callback' must be called using the signature function(err).
-  
+
         timestampSkewSec:      optional number of seconds of permitted clock skew for incoming timestamps. Defaults to 60 seconds.
                                Provides a +/- skew which means actual allowed window is double the number of seconds.
-  
+
         localtimeOffsetMsec:   optional local clock time offset express in a number of milliseconds (positive or negative).
                                Defaults to 0.
-  
+
         payload:               optional payload for validation. The client calculates the hash value and includes it via the 'hash'
                                header attribute. The server always ensures the value provided has been included in the request
                                MAC. When this option is provided, it validates the hash value itself. Validation is done by calculating
@@ -85,10 +85,10 @@ var internals = {};
 exports.authenticate = function (req, credentialsFunc, options, callback) {
 
     callback = Hoek.nextTick(callback);
-    
+
     // Default options
 
-    options.nonceFunc = options.nonceFunc || function (nonce, ts, nonceCallback) { return nonceCallback(); };   // No validation
+    options.nonceFunc = options.nonceFunc || internals.nonceFunc;
     options.timestampSkewSec = options.timestampSkewSec || 60;                                                  // 60 seconds
 
     // Application time
@@ -182,7 +182,7 @@ exports.authenticate = function (req, credentialsFunc, options, callback) {
 
         // Check nonce
 
-        options.nonceFunc(attributes.nonce, attributes.ts, function (err) {
+        options.nonceFunc(credentials.key, attributes.nonce, attributes.ts, function (err) {
 
             if (err) {
                 return callback(Boom.unauthorized('Invalid nonce', 'Hawk'), credentials, artifacts);
@@ -325,7 +325,7 @@ exports.authenticateBewit = function (req, credentialsFunc, options, callback) {
 
     // Extract bewit
 
-    //                                 1     2             3           4     
+    //                                 1     2             3           4
     var resource = request.url.match(/^(\/.*)([\?&])bewit\=([^&$]*)(?:&(.+))?$/);
     if (!resource) {
         return callback(Boom.unauthorized(null, 'Hawk'));
@@ -445,10 +445,10 @@ exports.authenticateBewit = function (req, credentialsFunc, options, callback) {
 exports.authenticateMessage = function (host, port, message, authorization, credentialsFunc, options, callback) {
 
     callback = Hoek.nextTick(callback);
-    
+
     // Default options
 
-    options.nonceFunc = options.nonceFunc || function (nonce, ts, nonceCallback) { return nonceCallback(); };   // No validation
+    options.nonceFunc = options.nonceFunc || internals.nonceFunc;
     options.timestampSkewSec = options.timestampSkewSec || 60;                                                  // 60 seconds
 
     // Application time
@@ -456,14 +456,14 @@ exports.authenticateMessage = function (host, port, message, authorization, cred
     var now = Utils.now(options.localtimeOffsetMsec);                       // Measure now before any other processing
 
     // Validate authorization
-    
+
     if (!authorization.id ||
         !authorization.ts ||
         !authorization.nonce ||
         !authorization.hash ||
         !authorization.mac) {
-        
-            return callback(Boom.badRequest('Invalid authorization'))
+
+        return callback(Boom.badRequest('Invalid authorization'));
     }
 
     // Fetch Hawk credentials
@@ -514,7 +514,7 @@ exports.authenticateMessage = function (host, port, message, authorization, cred
 
         // Check nonce
 
-        options.nonceFunc(authorization.nonce, authorization.ts, function (err) {
+        options.nonceFunc(credentials.key, authorization.nonce, authorization.ts, function (err) {
 
             if (err) {
                 return callback(Boom.unauthorized('Invalid nonce', 'Hawk'), credentials);
@@ -532,3 +532,9 @@ exports.authenticateMessage = function (host, port, message, authorization, cred
         });
     });
 };
+
+
+internals.nonceFunc = function (key, nonce, ts, nonceCallback) {
+
+    return nonceCallback();         // No validation
+};
index de74606..8d2719a 100755 (executable)
@@ -60,7 +60,7 @@ exports.parseRequest = function (req, options) {
     if (!req.headers) {
         return req;
     }
-    
+
     // Obtain host and port information
 
     if (!options.host || !options.port) {
@@ -157,8 +157,8 @@ exports.parseAuthorizationHeader = function (header, keys) {
 };
 
 
-exports.unauthorized = function (message) {
+exports.unauthorized = function (message, attributes) {
 
-    return Boom.unauthorized(message, 'Hawk');
+    return Boom.unauthorized(message, 'Hawk', attributes);
 };
 
index df8da9f..4e6eb34 100644 (file)
@@ -33,7 +33,7 @@
   "homepage": "https://github.com/hapijs/boom#readme",
   "_id": "boom@2.8.0",
   "_shasum": "317bdfd47018fe7dd79b0e9da73efe244119fdf1",
-  "_from": "boom@>=2.0.0 <3.0.0",
+  "_from": "boom@>=2.8.0 <3.0.0",
   "_npmVersion": "2.11.1",
   "_nodeVersion": "0.10.38",
   "_npmUser": {
index 3a25386..31dbaba 100644 (file)
       "url": "http://github.com/hapijs/cryptiles/raw/master/LICENSE"
     }
   ],
-  "readme": "cryptiles\n=========\n\nGeneral purpose crypto utilities\n\n[![Build Status](https://secure.travis-ci.org/hapijs/cryptiles.png)](http://travis-ci.org/hapijs/cryptiles)\n\n## Methods\n\n### `randomString(<Number> size)`\nReturns a cryptographically strong pseudo-random data string. Takes a size argument for the length of the string.\n\n### `fixedTimeComparison(<String> a, <String> b)`\nCompare two strings using fixed time algorithm (to prevent time-based analysis of MAC digest match). Returns `true` if the strings match, `false` if they differ.\n",
-  "readmeFilename": "README.md",
+  "gitHead": "944263dbb628b9b3da542d35600d587f861eeaf0",
   "bugs": {
     "url": "https://github.com/hapijs/cryptiles/issues"
   },
-  "homepage": "https://github.com/hapijs/cryptiles#readme",
+  "homepage": "https://github.com/hapijs/cryptiles",
   "_id": "cryptiles@2.0.4",
   "_shasum": "09ea1775b9e1c7de7e60a99d42ab6f08ce1a1285",
+  "_from": "cryptiles@>=2.0.0 <3.0.0",
+  "_npmVersion": "1.4.23",
+  "_npmUser": {
+    "name": "hueniverse",
+    "email": "eran@hueniverse.com"
+  },
+  "maintainers": [
+    {
+      "name": "hueniverse",
+      "email": "eran@hueniverse.com"
+    }
+  ],
+  "dist": {
+    "shasum": "09ea1775b9e1c7de7e60a99d42ab6f08ce1a1285",
+    "tarball": "http://registry.npmjs.org/cryptiles/-/cryptiles-2.0.4.tgz"
+  },
+  "directories": {},
   "_resolved": "https://registry.npmjs.org/cryptiles/-/cryptiles-2.0.4.tgz",
-  "_from": "cryptiles@>=2.0.0 <3.0.0"
+  "readme": "ERROR: No README data found!"
 }
index 9ae1b92..8b664b6 100644 (file)
       "url": "http://github.com/hueniverse/sntp/raw/master/LICENSE"
     }
   ],
-  "readme": "# sntp\n\nAn SNTP v4 client (RFC4330) for node. Simpy connects to the NTP or SNTP server requested and returns the server time\nalong with the roundtrip duration and clock offset. To adjust the local time to the NTP time, add the returned `t` offset\nto the local time.\n\n[![Build Status](https://secure.travis-ci.org/hueniverse/sntp.png)](http://travis-ci.org/hueniverse/sntp)\n\n# Usage\n\n```javascript\nvar Sntp = require('sntp');\n\n// All options are optional\n\nvar options = {\n    host: 'nist1-sj.ustiming.org',  // Defaults to pool.ntp.org\n    port: 123,                      // Defaults to 123 (NTP)\n    resolveReference: true,         // Default to false (not resolving)\n    timeout: 1000                   // Defaults to zero (no timeout)\n};\n\n// Request server time\n\nSntp.time(options, function (err, time) {\n\n    if (err) {\n        console.log('Failed: ' + err.message);\n        process.exit(1);\n    }\n\n    console.log('Local clock is off by: ' + time.t + ' milliseconds');\n    process.exit(0);\n});\n```\n\nIf an application needs to maintain continuous time synchronization, the module provides a stateful method for\nquerying the current offset only when the last one is too old (defaults to daily).\n\n```javascript\n// Request offset once\n\nSntp.offset(function (err, offset) {\n\n    console.log(offset);                    // New (served fresh)\n\n    // Request offset again\n\n    Sntp.offset(function (err, offset) {\n\n        console.log(offset);                // Identical (served from cache)\n    });\n});\n```\n\nTo set a background offset refresh, start the interval and use the provided now() method. If for any reason the\nclient fails to obtain an up-to-date offset, the current system clock is used.\n\n```javascript\nvar before = Sntp.now();                    // System time without offset\n\nSntp.start(function () {\n\n    var now = Sntp.now();                   // With offset\n    Sntp.stop();\n});\n```\n\n",
-  "readmeFilename": "README.md",
+  "gitHead": "ee2e35284f684609990681734d39010cd356d7da",
   "bugs": {
     "url": "https://github.com/hueniverse/sntp/issues"
   },
-  "homepage": "https://github.com/hueniverse/sntp#readme",
+  "homepage": "https://github.com/hueniverse/sntp",
   "_id": "sntp@1.0.9",
   "_shasum": "6541184cc90aeea6c6e7b35e2659082443c66198",
+  "_from": "sntp@>=1.0.0 <2.0.0",
+  "_npmVersion": "1.4.23",
+  "_npmUser": {
+    "name": "hueniverse",
+    "email": "eran@hueniverse.com"
+  },
+  "maintainers": [
+    {
+      "name": "hueniverse",
+      "email": "eran@hueniverse.com"
+    }
+  ],
+  "dist": {
+    "shasum": "6541184cc90aeea6c6e7b35e2659082443c66198",
+    "tarball": "http://registry.npmjs.org/sntp/-/sntp-1.0.9.tgz"
+  },
+  "directories": {},
   "_resolved": "https://registry.npmjs.org/sntp/-/sntp-1.0.9.tgz",
-  "_from": "sntp@>=1.0.0 <2.0.0"
+  "readme": "ERROR: No README data found!"
 }
index b7077b3..5a835b2 100644 (file)
@@ -1,7 +1,7 @@
 {
   "name": "hawk",
   "description": "HTTP Hawk Authentication Scheme",
-  "version": "2.3.1",
+  "version": "3.1.0",
   "author": {
     "name": "Eran Hammer",
     "email": "eran@hammer.io",
@@ -12,7 +12,7 @@
     "type": "git",
     "url": "git://github.com/hueniverse/hawk.git"
   },
-  "main": "index",
+  "main": "lib/index.js",
   "keywords": [
     "http",
     "authentication",
     "hawk"
   ],
   "engines": {
-    "node": ">=0.8.0"
+    "node": ">=0.10.32"
   },
   "browser": "./lib/browser.js",
   "dependencies": {
     "hoek": "2.x.x",
-    "boom": "2.x.x",
+    "boom": "^2.8.x",
     "cryptiles": "2.x.x",
     "sntp": "1.x.x"
   },
     "lab": "5.x.x"
   },
   "scripts": {
-    "test": "make test-cov"
+    "test": "lab -a code -t 100 -L",
+    "test-cov-html": "lab -a code -r html -o coverage.html"
   },
-  "licenses": [
-    {
-      "type": "BSD",
-      "url": "http://github.com/hueniverse/hawk/raw/master/LICENSE"
-    }
-  ],
-  "readme": "![hawk Logo](https://raw.github.com/hueniverse/hawk/master/images/hawk.png)\n\n<img align=\"right\" src=\"https://raw.github.com/hueniverse/hawk/master/images/logo.png\" /> **Hawk** is an HTTP authentication scheme using a message authentication code (MAC) algorithm to provide partial\nHTTP request cryptographic verification. For more complex use cases such as access delegation, see [Oz](https://github.com/hueniverse/oz).\n\nCurrent version: **2.3**\n\nNote: 2.x is the same exact protocol as 1.1. The version increment reflects a change in the internal error format\nused by the module and used by the node API.\n\n[![Build Status](https://secure.travis-ci.org/hueniverse/hawk.png)](http://travis-ci.org/hueniverse/hawk)\n\n# Table of Content\n\n- [**Introduction**](#introduction)\n  - [Replay Protection](#replay-protection)\n  - [Usage Example](#usage-example)\n  - [Protocol Example](#protocol-example)\n    - [Payload Validation](#payload-validation)\n    - [Response Payload Validation](#response-payload-validation)\n  - [Browser Support and Considerations](#browser-support-and-considerations)\n<p></p>\n- [**Single URI Authorization**](#single-uri-authorization)\n  - [Usage Example](#bewit-usage-example)\n<p></p>\n- [**Security Considerations**](#security-considerations)\n  - [MAC Keys Transmission](#mac-keys-transmission)\n  - [Confidentiality of Requests](#confidentiality-of-requests)\n  - [Spoofing by Counterfeit Servers](#spoofing-by-counterfeit-servers)\n  - [Plaintext Storage of Credentials](#plaintext-storage-of-credentials)\n  - [Entropy of Keys](#entropy-of-keys)\n  - [Coverage Limitations](#coverage-limitations)\n  - [Future Time Manipulation](#future-time-manipulation)\n  - [Client Clock Poisoning](#client-clock-poisoning)\n  - [Bewit Limitations](#bewit-limitations)\n  - [Host Header Forgery](#host-header-forgery)\n<p></p>\n- [**Frequently Asked Questions**](#frequently-asked-questions)\n<p></p>\n- [**Implementations**](#implementations)\n- [**Acknowledgements**](#acknowledgements)\n\n# Introduction\n\n**Hawk** is an HTTP authentication scheme providing mechanisms for making authenticated HTTP requests with\npartial cryptographic verification of the request and response, covering the HTTP method, request URI, host,\nand optionally the request payload.\n\nSimilar to the HTTP [Digest access authentication schemes](http://www.ietf.org/rfc/rfc2617.txt), **Hawk** uses a set of\nclient credentials which include an identifier (e.g. username) and key (e.g. password). Likewise, just as with the Digest scheme,\nthe key is never included in authenticated requests. Instead, it is used to calculate a request MAC value which is\nincluded in its place.\n\nHowever, **Hawk** has several differences from Digest. In particular, while both use a nonce to limit the possibility of\nreplay attacks, in **Hawk** the client generates the nonce and uses it in combination with a timestamp, leading to less\n\"chattiness\" (interaction with the server).\n\nAlso unlike Digest, this scheme is not intended to protect the key itself (the password in Digest) because\nthe client and server must both have access to the key material in the clear.\n\nThe primary design goals of this scheme are to:\n* simplify and improve HTTP authentication for services that are unwilling or unable to deploy TLS for all resources,\n* secure credentials against leakage (e.g., when the client uses some form of dynamic configuration to determine where\n  to send an authenticated request), and\n* avoid the exposure of credentials sent to a malicious server over an unauthenticated secure channel due to client\n  failure to validate the server's identity as part of its TLS handshake.\n\nIn addition, **Hawk** supports a method for granting third-parties temporary access to individual resources using\na query parameter called _bewit_ (in falconry, a leather strap used to attach a tracking device to the leg of a hawk).\n\nThe **Hawk** scheme requires the establishment of a shared symmetric key between the client and the server,\nwhich is beyond the scope of this module. Typically, the shared credentials are established via an initial\nTLS-protected phase or derived from some other shared confidential information available to both the client\nand the server.\n\n\n## Replay Protection\n\nWithout replay protection, an attacker can use a compromised (but otherwise valid and authenticated) request more \nthan once, gaining access to a protected resource. To mitigate this, clients include both a nonce and a timestamp when \nmaking requests. This gives the server enough information to prevent replay attacks.\n\nThe nonce is generated by the client, and is a string unique across all requests with the same timestamp and\nkey identifier combination. \n\nThe timestamp enables the server to restrict the validity period of the credentials where requests occuring afterwards\nare rejected. It also removes the need for the server to retain an unbounded number of nonce values for future checks.\nBy default, **Hawk** uses a time window of 1 minute to allow for time skew between the client and server (which in\npractice translates to a maximum of 2 minutes as the skew can be positive or negative).\n\nUsing a timestamp requires the client's clock to be in sync with the server's clock. **Hawk** requires both the client\nclock and the server clock to use NTP to ensure synchronization. However, given the limitations of some client types\n(e.g. browsers) to deploy NTP, the server provides the client with its current time (in seconds precision) in response\nto a bad timestamp.\n\nThere is no expectation that the client will adjust its system clock to match the server (in fact, this would be a\npotential attack vector). Instead, the client only uses the server's time to calculate an offset used only\nfor communications with that particular server. The protocol rewards clients with synchronized clocks by reducing\nthe number of round trips required to authenticate the first request.\n\n\n## Usage Example\n\nServer code:\n\n```javascript\nvar Http = require('http');\nvar Hawk = require('hawk');\n\n\n// Credentials lookup function\n\nvar credentialsFunc = function (id, callback) {\n\n    var credentials = {\n        key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',\n        algorithm: 'sha256',\n        user: 'Steve'\n    };\n\n    return callback(null, credentials);\n};\n\n// Create HTTP server\n\nvar handler = function (req, res) {\n\n    // Authenticate incoming request\n\n    Hawk.server.authenticate(req, credentialsFunc, {}, function (err, credentials, artifacts) {\n\n        // Prepare response\n\n        var payload = (!err ? 'Hello ' + credentials.user + ' ' + artifacts.ext : 'Shoosh!');\n        var headers = { 'Content-Type': 'text/plain' };\n\n        // Generate Server-Authorization response header\n\n        var header = Hawk.server.header(credentials, artifacts, { payload: payload, contentType: headers['Content-Type'] });\n        headers['Server-Authorization'] = header;\n\n        // Send the response back\n\n        res.writeHead(!err ? 200 : 401, headers);\n        res.end(payload);\n    });\n};\n\n// Start server\n\nHttp.createServer(handler).listen(8000, 'example.com');\n```\n\nClient code:\n\n```javascript\nvar Request = require('request');\nvar Hawk = require('hawk');\n\n\n// Client credentials\n\nvar credentials = {\n    id: 'dh37fgj492je',\n    key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',\n    algorithm: 'sha256'\n}\n\n// Request options\n\nvar requestOptions = {\n    uri: 'http://example.com:8000/resource/1?b=1&a=2',\n    method: 'GET',\n    headers: {}\n};\n\n// Generate Authorization request header\n\nvar header = Hawk.client.header('http://example.com:8000/resource/1?b=1&a=2', 'GET', { credentials: credentials, ext: 'some-app-data' });\nrequestOptions.headers.Authorization = header.field;\n\n// Send authenticated request\n\nRequest(requestOptions, function (error, response, body) {\n\n    // Authenticate the server's response\n\n    var isValid = Hawk.client.authenticate(response, credentials, header.artifacts, { payload: body });\n\n    // Output results\n\n    console.log(response.statusCode + ': ' + body + (isValid ? ' (valid)' : ' (invalid)'));\n});\n```\n\n**Hawk** utilized the [**SNTP**](https://github.com/hueniverse/sntp) module for time sync management. By default, the local\nmachine time is used. To automatically retrieve and synchronice the clock within the application, use the SNTP 'start()' method.\n\n```javascript\nHawk.sntp.start();\n```\n\n\n## Protocol Example\n\nThe client attempts to access a protected resource without authentication, sending the following HTTP request to\nthe resource server:\n\n```\nGET /resource/1?b=1&a=2 HTTP/1.1\nHost: example.com:8000\n```\n\nThe resource server returns an authentication challenge.\n\n```\nHTTP/1.1 401 Unauthorized\nWWW-Authenticate: Hawk\n```\n\nThe client has previously obtained a set of **Hawk** credentials for accessing resources on the \"http://example.com/\"\nserver. The **Hawk** credentials issued to the client include the following attributes:\n\n* Key identifier: dh37fgj492je\n* Key: werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn\n* Algorithm: sha256\n\nThe client generates the authentication header by calculating a timestamp (e.g. the number of seconds since January 1,\n1970 00:00:00 GMT), generating a nonce, and constructing the normalized request string (each value followed by a newline\ncharacter):\n\n```\nhawk.1.header\n1353832234\nj4h3g2\nGET\n/resource/1?b=1&a=2\nexample.com\n8000\n\nsome-app-ext-data\n\n```\n\nThe request MAC is calculated using HMAC with the specified hash algorithm \"sha256\" and the key over the normalized request string.\nThe result is base64-encoded to produce the request MAC:\n\n```\n6R4rV5iE+NPoym+WwjeHzjAGXUtLNIxmo1vpMofpLAE=\n```\n\nThe client includes the **Hawk** key identifier, timestamp, nonce, application specific data, and request MAC with the request using\nthe HTTP `Authorization` request header field:\n\n```\nGET /resource/1?b=1&a=2 HTTP/1.1\nHost: example.com:8000\nAuthorization: Hawk id=\"dh37fgj492je\", ts=\"1353832234\", nonce=\"j4h3g2\", ext=\"some-app-ext-data\", mac=\"6R4rV5iE+NPoym+WwjeHzjAGXUtLNIxmo1vpMofpLAE=\"\n```\n\nThe server validates the request by calculating the request MAC again based on the request received and verifies the validity\nand scope of the **Hawk** credentials. If valid, the server responds with the requested resource.\n\n\n### Payload Validation\n\n**Hawk** provides optional payload validation. When generating the authentication header, the client calculates a payload hash\nusing the specified hash algorithm. The hash is calculated over the concatenated value of (each followed by a newline character):\n* `hawk.1.payload`\n* the content-type in lowercase, without any parameters (e.g. `application/json`)\n* the request payload prior to any content encoding (the exact representation requirements should be specified by the server for payloads other than simple single-part ascii to ensure interoperability)\n\nFor example:\n\n* Payload: `Thank you for flying Hawk`\n* Content Type: `text/plain`\n* Hash (sha256): `Yi9LfIIFRtBEPt74PVmbTF/xVAwPn7ub15ePICfgnuY=`\n\nResults in the following input to the payload hash function (newline terminated values):\n\n```\nhawk.1.payload\ntext/plain\nThank you for flying Hawk\n\n```\n\nWhich produces the following hash value:\n\n```\nYi9LfIIFRtBEPt74PVmbTF/xVAwPn7ub15ePICfgnuY=\n```\n\nThe client constructs the normalized request string (newline terminated values):\n\n```\nhawk.1.header\n1353832234\nj4h3g2\nPOST\n/resource/1?a=1&b=2\nexample.com\n8000\nYi9LfIIFRtBEPt74PVmbTF/xVAwPn7ub15ePICfgnuY=\nsome-app-ext-data\n\n```\n\nThen calculates the request MAC and includes the **Hawk** key identifier, timestamp, nonce, payload hash, application specific data,\nand request MAC, with the request using the HTTP `Authorization` request header field:\n\n```\nPOST /resource/1?a=1&b=2 HTTP/1.1\nHost: example.com:8000\nAuthorization: Hawk id=\"dh37fgj492je\", ts=\"1353832234\", nonce=\"j4h3g2\", hash=\"Yi9LfIIFRtBEPt74PVmbTF/xVAwPn7ub15ePICfgnuY=\", ext=\"some-app-ext-data\", mac=\"aSe1DERmZuRl3pI36/9BdZmnErTw3sNzOOAUlfeKjVw=\"\n```\n\nIt is up to the server if and when it validates the payload for any given request, based solely on it's security policy\nand the nature of the data included.\n\nIf the payload is available at the time of authentication, the server uses the hash value provided by the client to construct\nthe normalized string and validates the MAC. If the MAC is valid, the server calculates the payload hash and compares the value\nwith the provided payload hash in the header. In many cases, checking the MAC first is faster than calculating the payload hash.\n\nHowever, if the payload is not available at authentication time (e.g. too large to fit in memory, streamed elsewhere, or processed\nat a different stage in the application), the server may choose to defer payload validation for later by retaining the hash value\nprovided by the client after validating the MAC.\n\nIt is important to note that MAC validation does not mean the hash value provided by the client is valid, only that the value\nincluded in the header was not modified. Without calculating the payload hash on the server and comparing it to the value provided\nby the client, the payload may be modified by an attacker.\n\n\n## Response Payload Validation\n\n**Hawk** provides partial response payload validation. The server includes the `Server-Authorization` response header which enables the\nclient to authenticate the response and ensure it is talking to the right server. **Hawk** defines the HTTP `Server-Authorization` header\nas a response header using the exact same syntax as the `Authorization` request header field.\n\nThe header is contructed using the same process as the client's request header. The server uses the same credentials and other\nartifacts provided by the client to constructs the normalized request string. The `ext` and `hash` values are replaced with\nnew values based on the server response. The rest as identical to those used by the client.\n\nThe result MAC digest is included with the optional `hash` and `ext` values:\n\n```\nServer-Authorization: Hawk mac=\"XIJRsMl/4oL+nn+vKoeVZPdCHXB4yJkNnBbTbHFZUYE=\", hash=\"f9cDF/TDm7TkYRLnGwRMfeDzT6LixQVLvrIKhh0vgmM=\", ext=\"response-specific\"\n```\n\n\n## Browser Support and Considerations\n\nA browser script is provided for including using a `<script>` tag in [lib/browser.js](/lib/browser.js). It's also a [component](http://component.io/hueniverse/hawk).\n\n**Hawk** relies on the _Server-Authorization_ and _WWW-Authenticate_ headers in its response to communicate with the client.\nTherefore, in case of CORS requests, it is important to consider sending _Access-Control-Expose-Headers_ with the value\n_\"WWW-Authenticate, Server-Authorization\"_ on each response from your server. As explained in the\n[specifications](http://www.w3.org/TR/cors/#access-control-expose-headers-response-header), it will indicate that these headers\ncan safely be accessed by the client (using getResponseHeader() on the XmlHttpRequest object). Otherwise you will be met with a\n[\"simple response header\"](http://www.w3.org/TR/cors/#simple-response-header) which excludes these fields and would prevent the\nHawk client from authenticating the requests.You can read more about the why and how in this\n[article](http://www.html5rocks.com/en/tutorials/cors/#toc-adding-cors-support-to-the-server)\n\n\n# Single URI Authorization\n\nThere are cases in which limited and short-term access to a protected resource is granted to a third party which does not\nhave access to the shared credentials. For example, displaying a protected image on a web page accessed by anyone. **Hawk**\nprovides limited support for such URIs in the form of a _bewit_ - a URI query parameter appended to the request URI which contains\nthe necessary credentials to authenticate the request.\n\nBecause of the significant security risks involved in issuing such access, bewit usage is purposely limited only to GET requests\nand for a finite period of time. Both the client and server can issue bewit credentials, however, the server should not use the same\ncredentials as the client to maintain clear traceability as to who issued which credentials.\n\nIn order to simplify implementation, bewit credentials do not support single-use policy and can be replayed multiple times within\nthe granted access timeframe. \n\n\n## Bewit Usage Example\n\nServer code:\n\n```javascript\nvar Http = require('http');\nvar Hawk = require('hawk');\n\n\n// Credentials lookup function\n\nvar credentialsFunc = function (id, callback) {\n\n    var credentials = {\n        key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',\n        algorithm: 'sha256'\n    };\n\n    return callback(null, credentials);\n};\n\n// Create HTTP server\n\nvar handler = function (req, res) {\n\n    Hawk.uri.authenticate(req, credentialsFunc, {}, function (err, credentials, attributes) {\n\n        res.writeHead(!err ? 200 : 401, { 'Content-Type': 'text/plain' });\n        res.end(!err ? 'Access granted' : 'Shoosh!');\n    });\n};\n\nHttp.createServer(handler).listen(8000, 'example.com');\n```\n\nBewit code generation:\n\n```javascript\nvar Request = require('request');\nvar Hawk = require('hawk');\n\n\n// Client credentials\n\nvar credentials = {\n    id: 'dh37fgj492je',\n    key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',\n    algorithm: 'sha256'\n}\n\n// Generate bewit\n\nvar duration = 60 * 5;      // 5 Minutes\nvar bewit = Hawk.uri.getBewit('http://example.com:8080/resource/1?b=1&a=2', { credentials: credentials, ttlSec: duration, ext: 'some-app-data' });\nvar uri = 'http://example.com:8000/resource/1?b=1&a=2' + '&bewit=' + bewit;\n```\n\n\n# Security Considerations\n\nThe greatest sources of security risks are usually found not in **Hawk** but in the policies and procedures surrounding its use.\nImplementers are strongly encouraged to assess how this module addresses their security requirements. This section includes\nan incomplete list of security considerations that must be reviewed and understood before deploying **Hawk** on the server.\nMany of the protections provided in **Hawk** depends on whether and how they are used.\n\n### MAC Keys Transmission\n\n**Hawk** does not provide any mechanism for obtaining or transmitting the set of shared credentials required. Any mechanism used\nto obtain **Hawk** credentials must ensure that these transmissions are protected using transport-layer mechanisms such as TLS.\n\n### Confidentiality of Requests\n\nWhile **Hawk** provides a mechanism for verifying the integrity of HTTP requests, it provides no guarantee of request\nconfidentiality. Unless other precautions are taken, eavesdroppers will have full access to the request content. Servers should\ncarefully consider the types of data likely to be sent as part of such requests, and employ transport-layer security mechanisms\nto protect sensitive resources.\n\n### Spoofing by Counterfeit Servers\n\n**Hawk** provides limited verification of the server authenticity. When receiving a response back from the server, the server\nmay choose to include a response `Server-Authorization` header which the client can use to verify the response. However, it is up to\nthe server to determine when such measure is included, to up to the client to enforce that policy.\n\nA hostile party could take advantage of this by intercepting the client's requests and returning misleading or otherwise\nincorrect responses. Service providers should consider such attacks when developing services using this protocol, and should\nrequire transport-layer security for any requests where the authenticity of the resource server or of server responses is an issue.\n\n### Plaintext Storage of Credentials\n\nThe **Hawk** key functions the same way passwords do in traditional authentication systems. In order to compute the request MAC,\nthe server must have access to the key in plaintext form. This is in contrast, for example, to modern operating systems, which\nstore only a one-way hash of user credentials.\n\nIf an attacker were to gain access to these keys - or worse, to the server's database of all such keys - he or she would be able\nto perform any action on behalf of any resource owner. Accordingly, it is critical that servers protect these keys from unauthorized\naccess.\n\n### Entropy of Keys\n\nUnless a transport-layer security protocol is used, eavesdroppers will have full access to authenticated requests and request\nMAC values, and will thus be able to mount offline brute-force attacks to recover the key used. Servers should be careful to\nassign keys which are long enough, and random enough, to resist such attacks for at least the length of time that the **Hawk**\ncredentials are valid.\n\nFor example, if the credentials are valid for two weeks, servers should ensure that it is not possible to mount a brute force\nattack that recovers the key in less than two weeks. Of course, servers are urged to err on the side of caution, and use the\nlongest key reasonable.\n\nIt is equally important that the pseudo-random number generator (PRNG) used to generate these keys be of sufficiently high\nquality. Many PRNG implementations generate number sequences that may appear to be random, but which nevertheless exhibit\npatterns or other weaknesses which make cryptanalysis or brute force attacks easier. Implementers should be careful to use\ncryptographically secure PRNGs to avoid these problems.\n\n### Coverage Limitations\n\nThe request MAC only covers the HTTP `Host` header and optionally the `Content-Type` header. It does not cover any other headers\nwhich can often affect how the request body is interpreted by the server. If the server behavior is influenced by the presence\nor value of such headers, an attacker can manipulate the request headers without being detected. Implementers should use the\n`ext` feature to pass application-specific information via the `Authorization` header which is protected by the request MAC.\n\nThe response authentication, when performed, only covers the response payload, content-type, and the request information \nprovided by the client in it's request (method, resource, timestamp, nonce, etc.). It does not cover the HTTP status code or\nany other response header field (e.g. Location) which can affect the client's behaviour.\n\n### Future Time Manipulation\n\nThe protocol relies on a clock sync between the client and server. To accomplish this, the server informs the client of its\ncurrent time when an invalid timestamp is received.\n\nIf an attacker is able to manipulate this information and cause the client to use an incorrect time, it would be able to cause\nthe client to generate authenticated requests using time in the future. Such requests will fail when sent by the client, and will\nnot likely leave a trace on the server (given the common implementation of nonce, if at all enforced). The attacker will then\nbe able to replay the request at the correct time without detection.\n\nThe client must only use the time information provided by the server if:\n* it was delivered over a TLS connection and the server identity has been verified, or\n* the `tsm` MAC digest calculated using the same client credentials over the timestamp has been verified.\n\n### Client Clock Poisoning\n\nWhen receiving a request with a bad timestamp, the server provides the client with its current time. The client must never use\nthe time received from the server to adjust its own clock, and must only use it to calculate an offset for communicating with\nthat particular server.\n\n### Bewit Limitations\n\nSpecial care must be taken when issuing bewit credentials to third parties. Bewit credentials are valid until expiration and cannot\nbe revoked or limited without using other means. Whatever resource they grant access to will be completely exposed to anyone with\naccess to the bewit credentials which act as bearer credentials for that particular resource. While bewit usage is limited to GET\nrequests only and therefore cannot be used to perform transactions or change server state, it can still be used to expose private\nand sensitive information.\n\n### Host Header Forgery\n\nHawk validates the incoming request MAC against the incoming HTTP Host header. However, unless the optional `host` and `port`\noptions are used with `server.authenticate()`, a malicous client can mint new host names pointing to the server's IP address and\nuse that to craft an attack by sending a valid request that's meant for another hostname than the one used by the server. Server\nimplementors must manually verify that the host header received matches their expectation (or use the options mentioned above).\n\n# Frequently Asked Questions\n\n### Where is the protocol specification?\n\nIf you are looking for some prose explaining how all this works, **this is it**. **Hawk** is being developed as an open source\nproject instead of a standard. In other words, the [code](/hueniverse/hawk/tree/master/lib) is the specification. Not sure about\nsomething? Open an issue!\n\n### Is it done?\n\nAs of version 0.10.0, **Hawk** is feature-complete. However, until this module reaches version 1.0.0 it is considered experimental\nand is likely to change. This also means your feedback and contribution are very welcome. Feel free to open issues with questions\nand suggestions.\n\n### Where can I find **Hawk** implementations in other languages?\n\n**Hawk**'s only reference implementation is provided in JavaScript as a node.js module. However, it has been ported to other languages.\nThe full list is maintained [here](https://github.com/hueniverse/hawk/issues?labels=port&state=closed). Please add an issue if you are\nworking on another port. A cross-platform test-suite is in the works.\n\n### Why isn't the algorithm part of the challenge or dynamically negotiated?\n\nThe algorithm used is closely related to the key issued as different algorithms require different key sizes (and other\nrequirements). While some keys can be used for multiple algorithm, the protocol is designed to closely bind the key and algorithm\ntogether as part of the issued credentials.\n\n### Why is Host and Content-Type the only headers covered by the request MAC?\n\nIt is really hard to include other headers. Headers can be changed by proxies and other intermediaries and there is no\nwell-established way to normalize them. Many platforms change the case of header field names and values. The only\nstraight-forward solution is to include the headers in some blob (say, base64 encoded JSON) and include that with the request,\nan approach taken by JWT and other such formats. However, that design violates the HTTP header boundaries, repeats information,\nand introduces other security issues because firewalls will not be aware of these \"hidden\" headers. In addition, any information\nrepeated must be compared to the duplicated information in the header and therefore only moves the problem elsewhere.\n\n### Why not just use HTTP Digest?\n\nDigest requires pre-negotiation to establish a nonce. This means you can't just make a request - you must first send\na protocol handshake to the server. This pattern has become unacceptable for most web services, especially mobile\nwhere extra round-trip are costly.\n\n### Why bother with all this nonce and timestamp business?\n\n**Hawk** is an attempt to find a reasonable, practical compromise between security and usability. OAuth 1.0 got timestamp\nand nonces halfway right but failed when it came to scalability and consistent developer experience. **Hawk** addresses\nit by requiring the client to sync its clock, but provides it with tools to accomplish it.\n\nIn general, replay protection is a matter of application-specific threat model. It is less of an issue on a TLS-protected\nsystem where the clients are implemented using best practices and are under the control of the server. Instead of dropping\nreplay protection, **Hawk** offers a required time window and an optional nonce verification. Together, it provides developers\nwith the ability to decide how to enforce their security policy without impacting the client's implementation.\n\n### What are `app` and `dlg` in the authorization header and normalized mac string?\n\nThe original motivation for **Hawk** was to replace the OAuth 1.0 use cases. This included both a simple client-server mode which\nthis module is specifically designed for, and a delegated access mode which is being developed separately in\n[Oz](https://github.com/hueniverse/oz). In addition to the **Hawk** use cases, Oz requires another attribute: the application id `app`.\nThis provides binding between the credentials and the application in a way that prevents an attacker from tricking an application\nto use credentials issued to someone else. It also has an optional 'delegated-by' attribute `dlg` which is the application id of the\napplication the credentials were directly issued to. The goal of these two additions is to allow Oz to utilize **Hawk** directly,\nbut with the additional security of delegated credentials.\n\n### What is the purpose of the static strings used in each normalized MAC input?\n\nWhen calculating a hash or MAC, a static prefix (tag) is added. The prefix is used to prevent MAC values from being\nused or reused for a purpose other than what they were created for (i.e. prevents switching MAC values between a request,\nresponse, and a bewit use cases). It also protects against exploits created after a potential change in how the protocol\ncreates the normalized string. For example, if a future version would switch the order of nonce and timestamp, it\ncan create an exploit opportunity for cases where the nonce is similar in format to a timestamp.\n\n### Does **Hawk** have anything to do with OAuth?\n\nShort answer: no.\n\n**Hawk** was originally proposed as the OAuth MAC Token specification. However, the OAuth working group in its consistent\nincompetence failed to produce a final, usable solution to address one of the most popular use cases of OAuth 1.0 - using it\nto authenticate simple client-server transactions (i.e. two-legged). As you can guess, the OAuth working group is still hard\nat work to produce more garbage.\n\n**Hawk** provides a simple HTTP authentication scheme for making client-server requests. It does not address the OAuth use case\nof delegating access to a third party. If you are looking for an OAuth alternative, check out [Oz](https://github.com/hueniverse/oz).\n\n# Implementations\n\n- [Logibit Hawk in F#/.Net](https://github.com/logibit/logibit.hawk/)\n- [Tent Hawk in Ruby](https://github.com/tent/hawk-ruby)\n- [Wealdtech in Java](https://github.com/wealdtech/hawk)\n- [Kumar's Mohawk in Python](https://github.com/kumar303/mohawk/)\n\n# Acknowledgements\n\n**Hawk** is a derivative work of the [HTTP MAC Authentication Scheme](http://tools.ietf.org/html/draft-hammer-oauth-v2-mac-token-05) proposal\nco-authored by Ben Adida, Adam Barth, and Eran Hammer, which in turn was based on the OAuth 1.0 community specification.\n\nSpecial thanks to Ben Laurie for his always insightful feedback and advice.\n\nThe **Hawk** logo was created by [Chris Carrasco](http://chriscarrasco.com).\n",
-  "readmeFilename": "README.md",
+  "license": "BSD-3-Clause",
+  "gitHead": "fdb9d05e383d5237631eaddc4f51422e54fa8b52",
   "bugs": {
     "url": "https://github.com/hueniverse/hawk/issues"
   },
   "homepage": "https://github.com/hueniverse/hawk#readme",
-  "_id": "hawk@2.3.1",
-  "_shasum": "1e731ce39447fa1d0f6d707f7bceebec0fd1ec1f",
-  "_resolved": "https://registry.npmjs.org/hawk/-/hawk-2.3.1.tgz",
-  "_from": "hawk@>=2.3.0 <2.4.0"
+  "_id": "hawk@3.1.0",
+  "_shasum": "8a13ae19977ec607602f3f0b9fd676f18c384e44",
+  "_from": "hawk@>=3.1.0 <3.2.0",
+  "_npmVersion": "2.10.0",
+  "_nodeVersion": "0.10.38",
+  "_npmUser": {
+    "name": "hueniverse",
+    "email": "eran@hammer.io"
+  },
+  "dist": {
+    "shasum": "8a13ae19977ec607602f3f0b9fd676f18c384e44",
+    "tarball": "http://registry.npmjs.org/hawk/-/hawk-3.1.0.tgz"
+  },
+  "maintainers": [
+    {
+      "name": "hueniverse",
+      "email": "eran@hueniverse.com"
+    }
+  ],
+  "directories": {},
+  "_resolved": "https://registry.npmjs.org/hawk/-/hawk-3.1.0.tgz",
+  "readme": "ERROR: No README data found!"
 }
index a452413..49dc4ca 100755 (executable)
@@ -82,7 +82,7 @@ describe('Browser', function () {
         });
     });
 
-    describe('#bewit', function () {
+    describe('bewit()', function () {
 
         it('returns a valid bewit value', function (done) {
 
@@ -516,7 +516,7 @@ describe('Browser', function () {
 
             var localStorage = new Browser.internals.LocalStorage();
 
-            Browser.utils.setStorage(localStorage)
+            Browser.utils.setStorage(localStorage);
 
             Browser.utils.setNtpOffset(60 * 60 * 1000);
             var header = Browser.client.header('http://example.com:8080/resource/4?filter=a', req.method, { credentials: credentials, ext: 'some-app-data' });
@@ -741,7 +741,7 @@ describe('Browser', function () {
 
     describe('client', function () {
 
-        describe('#header', function () {
+        describe('header()', function () {
 
             it('returns a valid authorization header (sha1)', function (done) {
 
@@ -950,7 +950,7 @@ describe('Browser', function () {
             });
         });
 
-        describe('#authenticate', function () {
+        describe('authenticate()', function () {
 
             it('skips tsm validation when missing ts', function (done) {
 
@@ -1119,7 +1119,7 @@ describe('Browser', function () {
             });
         });
 
-        describe('#message', function () {
+        describe('message()', function () {
 
             it('generates an authorization then successfully parse it', function (done) {
 
@@ -1270,7 +1270,7 @@ describe('Browser', function () {
             });
         });
 
-        describe('#authenticateTimestamp', function (done) {
+        describe('authenticateTimestamp()', function (done) {
 
             it('validates a timestamp', function (done) {
 
@@ -1342,7 +1342,7 @@ describe('Browser', function () {
 
     describe('utils', function () {
 
-        describe('#setStorage', function () {
+        describe('setStorage()', function () {
 
             it('sets storage for the first time', function (done) {
 
@@ -1358,21 +1358,29 @@ describe('Browser', function () {
             });
         });
 
-        describe('#setNtpOffset', function (done) {
+        describe('setNtpOffset()', function (done) {
 
-            it('catches localStorage errors', function (done) {
+            it('catches localStorage errors', { parallel: false }, function (done) {
 
                 var orig = Browser.utils.storage.setItem;
-                var error = console.error;
+                var consoleOrig = console.error;
                 var count = 0;
-                console.error = function () { if (count++ === 2) { console.error = error; } };
+                console.error = function () {
+
+                    if (count++ === 2) {
+
+                        console.error = consoleOrig;
+                    }
+                };
+
                 Browser.utils.storage.setItem = function () {
 
                     Browser.utils.storage.setItem = orig;
-                    throw new Error()
+                    throw new Error();
                 };
 
                 expect(function () {
+
                     Browser.utils.setNtpOffset(100);
                 }).not.to.throw();
 
@@ -1380,7 +1388,7 @@ describe('Browser', function () {
             });
         });
 
-        describe('#parseAuthorizationHeader', function (done) {
+        describe('parseAuthorizationHeader()', function (done) {
 
             it('returns null on missing header', function (done) {
 
@@ -1419,7 +1427,7 @@ describe('Browser', function () {
             });
         });
 
-        describe('#parseUri', function () {
+        describe('parseUri()', function () {
 
             it('returns empty port when unknown scheme', function (done) {
 
@@ -1436,18 +1444,16 @@ describe('Browser', function () {
             });
         });
 
-        var str = "https://www.google.ca/webhp?sourceid=chrome-instant&ion=1&espv=2&ie=UTF-8#q=url";
-        var base64str = "aHR0cHM6Ly93d3cuZ29vZ2xlLmNhL3dlYmhwP3NvdXJjZWlkPWNocm9tZS1pbnN0YW50Jmlvbj0xJmVzcHY9MiZpZT1VVEYtOCNxPXVybA";
+        var str = 'https://www.google.ca/webhp?sourceid=chrome-instant&ion=1&espv=2&ie=UTF-8#q=url';
+        var base64str = 'aHR0cHM6Ly93d3cuZ29vZ2xlLmNhL3dlYmhwP3NvdXJjZWlkPWNocm9tZS1pbnN0YW50Jmlvbj0xJmVzcHY9MiZpZT1VVEYtOCNxPXVybA';
 
-        describe('#base64urlEncode', function () {
+        describe('base64urlEncode()', function () {
 
             it('should base64 URL-safe decode a string', function (done) {
 
                 expect(Browser.utils.base64urlEncode(str)).to.equal(base64str);
                 done();
             });
-
         });
-
     });
 });
index 5983897..d6be231 100755 (executable)
@@ -19,425 +19,422 @@ var it = lab.test;
 var expect = Code.expect;
 
 
-describe('Hawk', function () {
+describe('Client', function () {
 
-    describe('client', function () {
+    describe('header()', function () {
 
-        describe('#header', function () {
+        it('returns a valid authorization header (sha1)', function (done) {
 
-            it('returns a valid authorization header (sha1)', function (done) {
-
-                var credentials = {
-                    id: '123456',
-                    key: '2983d45yun89q',
-                    algorithm: 'sha1'
-                };
+            var credentials = {
+                id: '123456',
+                key: '2983d45yun89q',
+                algorithm: 'sha1'
+            };
 
-                var header = Hawk.client.header('http://example.net/somewhere/over/the/rainbow', 'POST', { credentials: credentials, ext: 'Bazinga!', timestamp: 1353809207, nonce: 'Ygvqdz', payload: 'something to write about' }).field;
-                expect(header).to.equal('Hawk id="123456", ts="1353809207", nonce="Ygvqdz", hash="bsvY3IfUllw6V5rvk4tStEvpBhE=", ext="Bazinga!", mac="qbf1ZPG/r/e06F4ht+T77LXi5vw="');
-                done();
-            });
+            var header = Hawk.client.header('http://example.net/somewhere/over/the/rainbow', 'POST', { credentials: credentials, ext: 'Bazinga!', timestamp: 1353809207, nonce: 'Ygvqdz', payload: 'something to write about' }).field;
+            expect(header).to.equal('Hawk id="123456", ts="1353809207", nonce="Ygvqdz", hash="bsvY3IfUllw6V5rvk4tStEvpBhE=", ext="Bazinga!", mac="qbf1ZPG/r/e06F4ht+T77LXi5vw="');
+            done();
+        });
+
+        it('returns a valid authorization header (sha256)', function (done) {
+
+            var credentials = {
+                id: '123456',
+                key: '2983d45yun89q',
+                algorithm: 'sha256'
+            };
+
+            var header = Hawk.client.header('https://example.net/somewhere/over/the/rainbow', 'POST', { credentials: credentials, ext: 'Bazinga!', timestamp: 1353809207, nonce: 'Ygvqdz', payload: 'something to write about', contentType: 'text/plain' }).field;
+            expect(header).to.equal('Hawk id="123456", ts="1353809207", nonce="Ygvqdz", hash="2QfCt3GuY9HQnHWyWD3wX68ZOKbynqlfYmuO2ZBRqtY=", ext="Bazinga!", mac="q1CwFoSHzPZSkbIvl0oYlD+91rBUEvFk763nMjMndj8="');
+            done();
+        });
+
+        it('returns a valid authorization header (no ext)', function (done) {
+
+            var credentials = {
+                id: '123456',
+                key: '2983d45yun89q',
+                algorithm: 'sha256'
+            };
+
+            var header = Hawk.client.header('https://example.net/somewhere/over/the/rainbow', 'POST', { credentials: credentials, timestamp: 1353809207, nonce: 'Ygvqdz', payload: 'something to write about', contentType: 'text/plain' }).field;
+            expect(header).to.equal('Hawk id="123456", ts="1353809207", nonce="Ygvqdz", hash="2QfCt3GuY9HQnHWyWD3wX68ZOKbynqlfYmuO2ZBRqtY=", mac="HTgtd0jPI6E4izx8e4OHdO36q00xFCU0FolNq3RiCYs="');
+            done();
+        });
+
+        it('returns a valid authorization header (null ext)', function (done) {
+
+            var credentials = {
+                id: '123456',
+                key: '2983d45yun89q',
+                algorithm: 'sha256'
+            };
+
+            var header = Hawk.client.header('https://example.net/somewhere/over/the/rainbow', 'POST', { credentials: credentials, timestamp: 1353809207, nonce: 'Ygvqdz', payload: 'something to write about', contentType: 'text/plain', ext: null }).field;
+            expect(header).to.equal('Hawk id="123456", ts="1353809207", nonce="Ygvqdz", hash="2QfCt3GuY9HQnHWyWD3wX68ZOKbynqlfYmuO2ZBRqtY=", mac="HTgtd0jPI6E4izx8e4OHdO36q00xFCU0FolNq3RiCYs="');
+            done();
+        });
+
+        it('returns a valid authorization header (empty payload)', function (done) {
+
+            var credentials = {
+                id: '123456',
+                key: '2983d45yun89q',
+                algorithm: 'sha256'
+            };
+
+            var header = Hawk.client.header('https://example.net/somewhere/over/the/rainbow', 'POST', { credentials: credentials, timestamp: 1353809207, nonce: 'Ygvqdz', payload: '', contentType: 'text/plain' }).field;
+            expect(header).to.equal('Hawk id=\"123456\", ts=\"1353809207\", nonce=\"Ygvqdz\", hash=\"q/t+NNAkQZNlq/aAD6PlexImwQTxwgT2MahfTa9XRLA=\", mac=\"U5k16YEzn3UnBHKeBzsDXn067Gu3R4YaY6xOt9PYRZM=\"');
+            done();
+        });
+
+        it('returns a valid authorization header (pre hashed payload)', function (done) {
+
+            var credentials = {
+                id: '123456',
+                key: '2983d45yun89q',
+                algorithm: 'sha256'
+            };
+
+            var options = { credentials: credentials, timestamp: 1353809207, nonce: 'Ygvqdz', payload: 'something to write about', contentType: 'text/plain' };
+            options.hash = Hawk.crypto.calculatePayloadHash(options.payload, credentials.algorithm, options.contentType);
+            var header = Hawk.client.header('https://example.net/somewhere/over/the/rainbow', 'POST', options).field;
+            expect(header).to.equal('Hawk id="123456", ts="1353809207", nonce="Ygvqdz", hash="2QfCt3GuY9HQnHWyWD3wX68ZOKbynqlfYmuO2ZBRqtY=", mac="HTgtd0jPI6E4izx8e4OHdO36q00xFCU0FolNq3RiCYs="');
+            done();
+        });
+
+        it('errors on missing uri', function (done) {
+
+            var header = Hawk.client.header('', 'POST');
+            expect(header.field).to.equal('');
+            expect(header.err).to.equal('Invalid argument type');
+            done();
+        });
+
+        it('errors on invalid uri', function (done) {
+
+            var header = Hawk.client.header(4, 'POST');
+            expect(header.field).to.equal('');
+            expect(header.err).to.equal('Invalid argument type');
+            done();
+        });
+
+        it('errors on missing method', function (done) {
+
+            var header = Hawk.client.header('https://example.net/somewhere/over/the/rainbow', '');
+            expect(header.field).to.equal('');
+            expect(header.err).to.equal('Invalid argument type');
+            done();
+        });
+
+        it('errors on invalid method', function (done) {
+
+            var header = Hawk.client.header('https://example.net/somewhere/over/the/rainbow', 5);
+            expect(header.field).to.equal('');
+            expect(header.err).to.equal('Invalid argument type');
+            done();
+        });
+
+        it('errors on missing options', function (done) {
+
+            var header = Hawk.client.header('https://example.net/somewhere/over/the/rainbow', 'POST');
+            expect(header.field).to.equal('');
+            expect(header.err).to.equal('Invalid argument type');
+            done();
+        });
+
+        it('errors on invalid credentials (id)', function (done) {
+
+            var credentials = {
+                key: '2983d45yun89q',
+                algorithm: 'sha256'
+            };
+
+            var header = Hawk.client.header('https://example.net/somewhere/over/the/rainbow', 'POST', { credentials: credentials, ext: 'Bazinga!', timestamp: 1353809207 });
+            expect(header.field).to.equal('');
+            expect(header.err).to.equal('Invalid credential object');
+            done();
+        });
+
+        it('errors on missing credentials', function (done) {
+
+            var header = Hawk.client.header('https://example.net/somewhere/over/the/rainbow', 'POST', { ext: 'Bazinga!', timestamp: 1353809207 });
+            expect(header.field).to.equal('');
+            expect(header.err).to.equal('Invalid credential object');
+            done();
+        });
+
+        it('errors on invalid credentials', function (done) {
+
+            var credentials = {
+                id: '123456',
+                algorithm: 'sha256'
+            };
+
+            var header = Hawk.client.header('https://example.net/somewhere/over/the/rainbow', 'POST', { credentials: credentials, ext: 'Bazinga!', timestamp: 1353809207 });
+            expect(header.field).to.equal('');
+            expect(header.err).to.equal('Invalid credential object');
+            done();
+        });
+
+        it('errors on invalid algorithm', function (done) {
+
+            var credentials = {
+                id: '123456',
+                key: '2983d45yun89q',
+                algorithm: 'hmac-sha-0'
+            };
+
+            var header = Hawk.client.header('https://example.net/somewhere/over/the/rainbow', 'POST', { credentials: credentials, payload: 'something, anything!', ext: 'Bazinga!', timestamp: 1353809207 });
+            expect(header.field).to.equal('');
+            expect(header.err).to.equal('Unknown algorithm');
+            done();
+        });
+    });
+
+    describe('authenticate()', function () {
+
+        it('returns false on invalid header', function (done) {
+
+            var res = {
+                headers: {
+                    'server-authorization': 'Hawk mac="abc", bad="xyz"'
+                }
+            };
+
+            expect(Hawk.client.authenticate(res, {})).to.equal(false);
+            done();
+        });
+
+        it('returns false on invalid mac', function (done) {
+
+            var res = {
+                headers: {
+                    'content-type': 'text/plain',
+                    'server-authorization': 'Hawk mac="_IJRsMl/4oL+nn+vKoeVZPdCHXB4yJkNnBbTbHFZUYE=", hash="f9cDF/TDm7TkYRLnGwRMfeDzT6LixQVLvrIKhh0vgmM=", ext="response-specific"'
+                }
+            };
+
+            var artifacts = {
+                method: 'POST',
+                host: 'example.com',
+                port: '8080',
+                resource: '/resource/4?filter=a',
+                ts: '1362336900',
+                nonce: 'eb5S_L',
+                hash: 'nJjkVtBE5Y/Bk38Aiokwn0jiJxt/0S2WRSUwWLCf5xk=',
+                ext: 'some-app-data',
+                app: undefined,
+                dlg: undefined,
+                mac: 'BlmSe8K+pbKIb6YsZCnt4E1GrYvY1AaYayNR82dGpIk=',
+                id: '123456'
+            };
+
+            var credentials = {
+                id: '123456',
+                key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
+                algorithm: 'sha256',
+                user: 'steve'
+            };
+
+            expect(Hawk.client.authenticate(res, credentials, artifacts)).to.equal(false);
+            done();
+        });
+
+        it('returns true on ignoring hash', function (done) {
+
+            var res = {
+                headers: {
+                    'content-type': 'text/plain',
+                    'server-authorization': 'Hawk mac="XIJRsMl/4oL+nn+vKoeVZPdCHXB4yJkNnBbTbHFZUYE=", hash="f9cDF/TDm7TkYRLnGwRMfeDzT6LixQVLvrIKhh0vgmM=", ext="response-specific"'
+                }
+            };
+
+            var artifacts = {
+                method: 'POST',
+                host: 'example.com',
+                port: '8080',
+                resource: '/resource/4?filter=a',
+                ts: '1362336900',
+                nonce: 'eb5S_L',
+                hash: 'nJjkVtBE5Y/Bk38Aiokwn0jiJxt/0S2WRSUwWLCf5xk=',
+                ext: 'some-app-data',
+                app: undefined,
+                dlg: undefined,
+                mac: 'BlmSe8K+pbKIb6YsZCnt4E1GrYvY1AaYayNR82dGpIk=',
+                id: '123456'
+            };
+
+            var credentials = {
+                id: '123456',
+                key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
+                algorithm: 'sha256',
+                user: 'steve'
+            };
+
+            expect(Hawk.client.authenticate(res, credentials, artifacts)).to.equal(true);
+            done();
+        });
+
+        it('fails on invalid WWW-Authenticate header format', function (done) {
+
+            var header = 'Hawk ts="1362346425875", tsm="PhwayS28vtnn3qbv0mqRBYSXebN/zggEtucfeZ620Zo=", x="Stale timestamp"';
+            expect(Hawk.client.authenticate({ headers: { 'www-authenticate': header } }, {})).to.equal(false);
+            done();
+        });
 
-            it('returns a valid authorization header (sha256)', function (done) {
+        it('fails on invalid WWW-Authenticate header format', function (done) {
 
-                var credentials = {
-                    id: '123456',
-                    key: '2983d45yun89q',
-                    algorithm: 'sha256'
-                };
+            var credentials = {
+                id: '123456',
+                key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
+                algorithm: 'sha256',
+                user: 'steve'
+            };
 
-                var header = Hawk.client.header('https://example.net/somewhere/over/the/rainbow', 'POST', { credentials: credentials, ext: 'Bazinga!', timestamp: 1353809207, nonce: 'Ygvqdz', payload: 'something to write about', contentType: 'text/plain' }).field;
-                expect(header).to.equal('Hawk id="123456", ts="1353809207", nonce="Ygvqdz", hash="2QfCt3GuY9HQnHWyWD3wX68ZOKbynqlfYmuO2ZBRqtY=", ext="Bazinga!", mac="q1CwFoSHzPZSkbIvl0oYlD+91rBUEvFk763nMjMndj8="');
-                done();
-            });
-
-            it('returns a valid authorization header (no ext)', function (done) {
+            var header = 'Hawk ts="1362346425875", tsm="hwayS28vtnn3qbv0mqRBYSXebN/zggEtucfeZ620Zo=", error="Stale timestamp"';
+            expect(Hawk.client.authenticate({ headers: { 'www-authenticate': header } }, credentials)).to.equal(false);
+            done();
+        });
+
+        it('skips tsm validation when missing ts', function (done) {
+
+            var header = 'Hawk error="Stale timestamp"';
+            expect(Hawk.client.authenticate({ headers: { 'www-authenticate': header } }, {})).to.equal(true);
+            done();
+        });
+    });
+
+    describe('message()', function () {
+
+        it('generates authorization', function (done) {
 
-                var credentials = {
-                    id: '123456',
-                    key: '2983d45yun89q',
-                    algorithm: 'sha256'
-                };
-
-                var header = Hawk.client.header('https://example.net/somewhere/over/the/rainbow', 'POST', { credentials: credentials, timestamp: 1353809207, nonce: 'Ygvqdz', payload: 'something to write about', contentType: 'text/plain' }).field;
-                expect(header).to.equal('Hawk id="123456", ts="1353809207", nonce="Ygvqdz", hash="2QfCt3GuY9HQnHWyWD3wX68ZOKbynqlfYmuO2ZBRqtY=", mac="HTgtd0jPI6E4izx8e4OHdO36q00xFCU0FolNq3RiCYs="');
-                done();
-            });
-
-            it('returns a valid authorization header (null ext)', function (done) {
+            var credentials = {
+                id: '123456',
+                key: '2983d45yun89q',
+                algorithm: 'sha1'
+            };
 
-                var credentials = {
-                    id: '123456',
-                    key: '2983d45yun89q',
-                    algorithm: 'sha256'
-                };
-
-                var header = Hawk.client.header('https://example.net/somewhere/over/the/rainbow', 'POST', { credentials: credentials, timestamp: 1353809207, nonce: 'Ygvqdz', payload: 'something to write about', contentType: 'text/plain', ext: null }).field;
-                expect(header).to.equal('Hawk id="123456", ts="1353809207", nonce="Ygvqdz", hash="2QfCt3GuY9HQnHWyWD3wX68ZOKbynqlfYmuO2ZBRqtY=", mac="HTgtd0jPI6E4izx8e4OHdO36q00xFCU0FolNq3RiCYs="');
-                done();
-            });
-
-            it('returns a valid authorization header (empty payload)', function (done) {
-
-                var credentials = {
-                    id: '123456',
-                    key: '2983d45yun89q',
-                    algorithm: 'sha256'
-                };
-
-                var header = Hawk.client.header('https://example.net/somewhere/over/the/rainbow', 'POST', { credentials: credentials, timestamp: 1353809207, nonce: 'Ygvqdz', payload: '', contentType: 'text/plain' }).field;
-                expect(header).to.equal('Hawk id=\"123456\", ts=\"1353809207\", nonce=\"Ygvqdz\", hash=\"q/t+NNAkQZNlq/aAD6PlexImwQTxwgT2MahfTa9XRLA=\", mac=\"U5k16YEzn3UnBHKeBzsDXn067Gu3R4YaY6xOt9PYRZM=\"');
-                done();
-            });
-
-            it('returns a valid authorization header (pre hashed payload)', function (done) {
-
-                var credentials = {
-                    id: '123456',
-                    key: '2983d45yun89q',
-                    algorithm: 'sha256'
-                };
-
-                var options = { credentials: credentials, timestamp: 1353809207, nonce: 'Ygvqdz', payload: 'something to write about', contentType: 'text/plain' };
-                options.hash = Hawk.crypto.calculatePayloadHash(options.payload, credentials.algorithm, options.contentType);
-                var header = Hawk.client.header('https://example.net/somewhere/over/the/rainbow', 'POST', options).field;
-                expect(header).to.equal('Hawk id="123456", ts="1353809207", nonce="Ygvqdz", hash="2QfCt3GuY9HQnHWyWD3wX68ZOKbynqlfYmuO2ZBRqtY=", mac="HTgtd0jPI6E4izx8e4OHdO36q00xFCU0FolNq3RiCYs="');
-                done();
-            });
-
-            it('errors on missing uri', function (done) {
-
-                var header = Hawk.client.header('', 'POST');
-                expect(header.field).to.equal('');
-                expect(header.err).to.equal('Invalid argument type');
-                done();
-            });
-
-            it('errors on invalid uri', function (done) {
-
-                var header = Hawk.client.header(4, 'POST');
-                expect(header.field).to.equal('');
-                expect(header.err).to.equal('Invalid argument type');
-                done();
-            });
-
-            it('errors on missing method', function (done) {
-
-                var header = Hawk.client.header('https://example.net/somewhere/over/the/rainbow', '');
-                expect(header.field).to.equal('');
-                expect(header.err).to.equal('Invalid argument type');
-                done();
-            });
-
-            it('errors on invalid method', function (done) {
-
-                var header = Hawk.client.header('https://example.net/somewhere/over/the/rainbow', 5);
-                expect(header.field).to.equal('');
-                expect(header.err).to.equal('Invalid argument type');
-                done();
-            });
-
-            it('errors on missing options', function (done) {
-
-                var header = Hawk.client.header('https://example.net/somewhere/over/the/rainbow', 'POST');
-                expect(header.field).to.equal('');
-                expect(header.err).to.equal('Invalid argument type');
-                done();
-            });
-
-            it('errors on invalid credentials (id)', function (done) {
-
-                var credentials = {
-                    key: '2983d45yun89q',
-                    algorithm: 'sha256'
-                };
-
-                var header = Hawk.client.header('https://example.net/somewhere/over/the/rainbow', 'POST', { credentials: credentials, ext: 'Bazinga!', timestamp: 1353809207 });
-                expect(header.field).to.equal('');
-                expect(header.err).to.equal('Invalid credential object');
-                done();
-            });
-
-            it('errors on missing credentials', function (done) {
-
-                var header = Hawk.client.header('https://example.net/somewhere/over/the/rainbow', 'POST', { ext: 'Bazinga!', timestamp: 1353809207 });
-                expect(header.field).to.equal('');
-                expect(header.err).to.equal('Invalid credential object');
-                done();
-            });
-
-            it('errors on invalid credentials', function (done) {
-
-                var credentials = {
-                    id: '123456',
-                    algorithm: 'sha256'
-                };
-
-                var header = Hawk.client.header('https://example.net/somewhere/over/the/rainbow', 'POST', { credentials: credentials, ext: 'Bazinga!', timestamp: 1353809207 });
-                expect(header.field).to.equal('');
-                expect(header.err).to.equal('Invalid credential object');
-                done();
-            });
-
-            it('errors on invalid algorithm', function (done) {
-
-                var credentials = {
-                    id: '123456',
-                    key: '2983d45yun89q',
-                    algorithm: 'hmac-sha-0'
-                };
-
-                var header = Hawk.client.header('https://example.net/somewhere/over/the/rainbow', 'POST', { credentials: credentials, payload: 'something, anything!', ext: 'Bazinga!', timestamp: 1353809207 });
-                expect(header.field).to.equal('');
-                expect(header.err).to.equal('Unknown algorithm');
-                done();
-            });
+            var auth = Hawk.client.message('example.com', 80, 'I am the boodyman', { credentials: credentials, timestamp: 1353809207, nonce: 'abc123' });
+            expect(auth).to.exist();
+            expect(auth.ts).to.equal(1353809207);
+            expect(auth.nonce).to.equal('abc123');
+            done();
         });
 
-        describe('#authenticate', function () {
-
-            it('returns false on invalid header', function (done) {
-
-                var res = {
-                    headers: {
-                        'server-authorization': 'Hawk mac="abc", bad="xyz"'
-                    }
-                };
-
-                expect(Hawk.client.authenticate(res, {})).to.equal(false);
-                done();
-            });
-
-            it('returns false on invalid mac', function (done) {
-
-                var res = {
-                    headers: {
-                        'content-type': 'text/plain',
-                        'server-authorization': 'Hawk mac="_IJRsMl/4oL+nn+vKoeVZPdCHXB4yJkNnBbTbHFZUYE=", hash="f9cDF/TDm7TkYRLnGwRMfeDzT6LixQVLvrIKhh0vgmM=", ext="response-specific"'
-                    }
-                };
-
-                var artifacts = {
-                    method: 'POST',
-                    host: 'example.com',
-                    port: '8080',
-                    resource: '/resource/4?filter=a',
-                    ts: '1362336900',
-                    nonce: 'eb5S_L',
-                    hash: 'nJjkVtBE5Y/Bk38Aiokwn0jiJxt/0S2WRSUwWLCf5xk=',
-                    ext: 'some-app-data',
-                    app: undefined,
-                    dlg: undefined,
-                    mac: 'BlmSe8K+pbKIb6YsZCnt4E1GrYvY1AaYayNR82dGpIk=',
-                    id: '123456'
-                };
-
-                var credentials = {
-                    id: '123456',
-                    key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
-                    algorithm: 'sha256',
-                    user: 'steve'
-                };
-
-                expect(Hawk.client.authenticate(res, credentials, artifacts)).to.equal(false);
-                done();
-            });
-
-            it('returns true on ignoring hash', function (done) {
-
-                var res = {
-                    headers: {
-                        'content-type': 'text/plain',
-                        'server-authorization': 'Hawk mac="XIJRsMl/4oL+nn+vKoeVZPdCHXB4yJkNnBbTbHFZUYE=", hash="f9cDF/TDm7TkYRLnGwRMfeDzT6LixQVLvrIKhh0vgmM=", ext="response-specific"'
-                    }
-                };
-
-                var artifacts = {
-                    method: 'POST',
-                    host: 'example.com',
-                    port: '8080',
-                    resource: '/resource/4?filter=a',
-                    ts: '1362336900',
-                    nonce: 'eb5S_L',
-                    hash: 'nJjkVtBE5Y/Bk38Aiokwn0jiJxt/0S2WRSUwWLCf5xk=',
-                    ext: 'some-app-data',
-                    app: undefined,
-                    dlg: undefined,
-                    mac: 'BlmSe8K+pbKIb6YsZCnt4E1GrYvY1AaYayNR82dGpIk=',
-                    id: '123456'
-                };
-
-                var credentials = {
-                    id: '123456',
-                    key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
-                    algorithm: 'sha256',
-                    user: 'steve'
-                };
-
-                expect(Hawk.client.authenticate(res, credentials, artifacts)).to.equal(true);
-                done();
-            });
-
-            it('fails on invalid WWW-Authenticate header format', function (done) {
-
-                var header = 'Hawk ts="1362346425875", tsm="PhwayS28vtnn3qbv0mqRBYSXebN/zggEtucfeZ620Zo=", x="Stale timestamp"';
-                expect(Hawk.client.authenticate({ headers: { 'www-authenticate': header } }, {})).to.equal(false);
-                done();
-            });
-
-            it('fails on invalid WWW-Authenticate header format', function (done) {
-
-                var credentials = {
-                    id: '123456',
-                    key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
-                    algorithm: 'sha256',
-                    user: 'steve'
-                };
-
-                var header = 'Hawk ts="1362346425875", tsm="hwayS28vtnn3qbv0mqRBYSXebN/zggEtucfeZ620Zo=", error="Stale timestamp"';
-                expect(Hawk.client.authenticate({ headers: { 'www-authenticate': header } }, credentials)).to.equal(false);
-                done();
-            });
-
-            it('skips tsm validation when missing ts', function (done) {
-
-                var header = 'Hawk error="Stale timestamp"';
-                expect(Hawk.client.authenticate({ headers: { 'www-authenticate': header } }, {})).to.equal(true);
-                done();
-            });
+        it('errors on invalid host', function (done) {
+
+            var credentials = {
+                id: '123456',
+                key: '2983d45yun89q',
+                algorithm: 'sha1'
+            };
+
+            var auth = Hawk.client.message(5, 80, 'I am the boodyman', { credentials: credentials, timestamp: 1353809207, nonce: 'abc123' });
+            expect(auth).to.not.exist();
+            done();
+        });
+
+        it('errors on invalid port', function (done) {
+
+            var credentials = {
+                id: '123456',
+                key: '2983d45yun89q',
+                algorithm: 'sha1'
+            };
+
+            var auth = Hawk.client.message('example.com', '80', 'I am the boodyman', { credentials: credentials, timestamp: 1353809207, nonce: 'abc123' });
+            expect(auth).to.not.exist();
+            done();
         });
 
-        describe('#message', function () {
-
-            it('generates authorization', function (done) {
-
-                var credentials = {
-                    id: '123456',
-                    key: '2983d45yun89q',
-                    algorithm: 'sha1'
-                };
+        it('errors on missing host', function (done) {
+
+            var credentials = {
+                id: '123456',
+                key: '2983d45yun89q',
+                algorithm: 'sha1'
+            };
+
+            var auth = Hawk.client.message('example.com', 0, 'I am the boodyman', { credentials: credentials, timestamp: 1353809207, nonce: 'abc123' });
+            expect(auth).to.not.exist();
+            done();
+        });
+
+        it('errors on null message', function (done) {
+
+            var credentials = {
+                id: '123456',
+                key: '2983d45yun89q',
+                algorithm: 'sha1'
+            };
+
+            var auth = Hawk.client.message('example.com', 80, null, { credentials: credentials, timestamp: 1353809207, nonce: 'abc123' });
+            expect(auth).to.not.exist();
+            done();
+        });
+
+        it('errors on missing message', function (done) {
+
+            var credentials = {
+                id: '123456',
+                key: '2983d45yun89q',
+                algorithm: 'sha1'
+            };
+
+            var auth = Hawk.client.message('example.com', 80, undefined, { credentials: credentials, timestamp: 1353809207, nonce: 'abc123' });
+            expect(auth).to.not.exist();
+            done();
+        });
+
+        it('errors on invalid message', function (done) {
+
+            var credentials = {
+                id: '123456',
+                key: '2983d45yun89q',
+                algorithm: 'sha1'
+            };
+
+            var auth = Hawk.client.message('example.com', 80, 5, { credentials: credentials, timestamp: 1353809207, nonce: 'abc123' });
+            expect(auth).to.not.exist();
+            done();
+        });
+
+        it('errors on missing options', function (done) {
+
+            var credentials = {
+                id: '123456',
+                key: '2983d45yun89q',
+                algorithm: 'sha1'
+            };
+
+            var auth = Hawk.client.message('example.com', 80, 'I am the boodyman');
+            expect(auth).to.not.exist();
+            done();
+        });
+
+        it('errors on invalid credentials (id)', function (done) {
+
+            var credentials = {
+                key: '2983d45yun89q',
+                algorithm: 'sha1'
+            };
+
+            var auth = Hawk.client.message('example.com', 80, 'I am the boodyman', { credentials: credentials, timestamp: 1353809207, nonce: 'abc123' });
+            expect(auth).to.not.exist();
+            done();
+        });
+
+        it('errors on invalid credentials (key)', function (done) {
+
+            var credentials = {
+                id: '123456',
+                algorithm: 'sha1'
+            };
 
-                var auth = Hawk.client.message('example.com', 80, 'I am the boodyman', { credentials: credentials, timestamp: 1353809207, nonce: 'abc123' });
-                expect(auth).to.exist();
-                expect(auth.ts).to.equal(1353809207);
-                expect(auth.nonce).to.equal('abc123');
-                done();
-            });
-
-            it('errors on invalid host', function (done) {
-
-                var credentials = {
-                    id: '123456',
-                    key: '2983d45yun89q',
-                    algorithm: 'sha1'
-                };
-
-                var auth = Hawk.client.message(5, 80, 'I am the boodyman', { credentials: credentials, timestamp: 1353809207, nonce: 'abc123' });
-                expect(auth).to.not.exist();
-                done();
-            });
-
-            it('errors on invalid port', function (done) {
-
-                var credentials = {
-                    id: '123456',
-                    key: '2983d45yun89q',
-                    algorithm: 'sha1'
-                };
-
-                var auth = Hawk.client.message('example.com', '80', 'I am the boodyman', { credentials: credentials, timestamp: 1353809207, nonce: 'abc123' });
-                expect(auth).to.not.exist();
-                done();
-            });
-
-            it('errors on missing host', function (done) {
-
-                var credentials = {
-                    id: '123456',
-                    key: '2983d45yun89q',
-                    algorithm: 'sha1'
-                };
-
-                var auth = Hawk.client.message('example.com', 0, 'I am the boodyman', { credentials: credentials, timestamp: 1353809207, nonce: 'abc123' });
-                expect(auth).to.not.exist();
-                done();
-            });
-
-            it('errors on null message', function (done) {
-
-                var credentials = {
-                    id: '123456',
-                    key: '2983d45yun89q',
-                    algorithm: 'sha1'
-                };
-
-                var auth = Hawk.client.message('example.com', 80, null, { credentials: credentials, timestamp: 1353809207, nonce: 'abc123' });
-                expect(auth).to.not.exist();
-                done();
-            });
-
-            it('errors on missing message', function (done) {
-
-                var credentials = {
-                    id: '123456',
-                    key: '2983d45yun89q',
-                    algorithm: 'sha1'
-                };
-
-                var auth = Hawk.client.message('example.com', 80, undefined, { credentials: credentials, timestamp: 1353809207, nonce: 'abc123' });
-                expect(auth).to.not.exist();
-                done();
-            });
-
-            it('errors on invalid message', function (done) {
-
-                var credentials = {
-                    id: '123456',
-                    key: '2983d45yun89q',
-                    algorithm: 'sha1'
-                };
-
-                var auth = Hawk.client.message('example.com', 80, 5, { credentials: credentials, timestamp: 1353809207, nonce: 'abc123' });
-                expect(auth).to.not.exist();
-                done();
-            });
-
-            it('errors on missing options', function (done) {
-
-                var credentials = {
-                    id: '123456',
-                    key: '2983d45yun89q',
-                    algorithm: 'sha1'
-                };
-
-                var auth = Hawk.client.message('example.com', 80, 'I am the boodyman');
-                expect(auth).to.not.exist();
-                done();
-            });
-
-            it('errors on invalid credentials (id)', function (done) {
-
-                var credentials = {
-                    key: '2983d45yun89q',
-                    algorithm: 'sha1'
-                };
-
-                var auth = Hawk.client.message('example.com', 80, 'I am the boodyman', { credentials: credentials, timestamp: 1353809207, nonce: 'abc123' });
-                expect(auth).to.not.exist();
-                done();
-            });
-
-            it('errors on invalid credentials (key)', function (done) {
-
-                var credentials = {
-                    id: '123456',
-                    algorithm: 'sha1'
-                };
-
-                var auth = Hawk.client.message('example.com', 80, 'I am the boodyman', { credentials: credentials, timestamp: 1353809207, nonce: 'abc123' });
-                expect(auth).to.not.exist();
-                done();
-            });
+            var auth = Hawk.client.message('example.com', 80, 'I am the boodyman', { credentials: credentials, timestamp: 1353809207, nonce: 'abc123' });
+            expect(auth).to.not.exist();
+            done();
         });
     });
 });
index f2d3d45..1131628 100755 (executable)
@@ -18,69 +18,53 @@ var it = lab.test;
 var expect = Code.expect;
 
 
-describe('Hawk', function () {
-
-    describe('Crypto', function () {
-
-        describe('#generateNormalizedString', function () {
-
-            it('should return a valid normalized string', function (done) {
-
-                expect(Hawk.crypto.generateNormalizedString('header', {
-                    credentials: {
-                        key: 'dasdfasdf',
-                        algorithm: 'sha256'
-                    },
-                    ts: 1357747017,
-                    nonce: 'k3k4j5',
-                    method: 'GET',
-                    resource: '/resource/something',
-                    host: 'example.com',
-                    port: 8080
-                })).to.equal('hawk.1.header\n1357747017\nk3k4j5\nGET\n/resource/something\nexample.com\n8080\n\n\n');
-
-                done();
-            });
-
-            it('should return a valid normalized string (ext)', function (done) {
-
-                expect(Hawk.crypto.generateNormalizedString('header', {
-                    credentials: {
-                        key: 'dasdfasdf',
-                        algorithm: 'sha256'
-                    },
-                    ts: 1357747017,
-                    nonce: 'k3k4j5',
-                    method: 'GET',
-                    resource: '/resource/something',
-                    host: 'example.com',
-                    port: 8080,
-                    ext: 'this is some app data'
-                })).to.equal('hawk.1.header\n1357747017\nk3k4j5\nGET\n/resource/something\nexample.com\n8080\n\nthis is some app data\n');
-
-                done();
-            });
-
-            it('should return a valid normalized string (payload + ext)', function (done) {
-
-                expect(Hawk.crypto.generateNormalizedString('header', {
-                    credentials: {
-                        key: 'dasdfasdf',
-                        algorithm: 'sha256'
-                    },
-                    ts: 1357747017,
-                    nonce: 'k3k4j5',
-                    method: 'GET',
-                    resource: '/resource/something',
-                    host: 'example.com',
-                    port: 8080,
-                    hash: 'U4MKKSmiVxk37JCCrAVIjV/OhB3y+NdwoCr6RShbVkE=',
-                    ext: 'this is some app data'
-                })).to.equal('hawk.1.header\n1357747017\nk3k4j5\nGET\n/resource/something\nexample.com\n8080\nU4MKKSmiVxk37JCCrAVIjV/OhB3y+NdwoCr6RShbVkE=\nthis is some app data\n');
-
-                done();
-            });
+describe('Crypto', function () {
+
+    describe('generateNormalizedString()', function () {
+
+        it('should return a valid normalized string', function (done) {
+
+            expect(Hawk.crypto.generateNormalizedString('header', {
+                ts: 1357747017,
+                nonce: 'k3k4j5',
+                method: 'GET',
+                resource: '/resource/something',
+                host: 'example.com',
+                port: 8080
+            })).to.equal('hawk.1.header\n1357747017\nk3k4j5\nGET\n/resource/something\nexample.com\n8080\n\n\n');
+
+            done();
+        });
+
+        it('should return a valid normalized string (ext)', function (done) {
+
+            expect(Hawk.crypto.generateNormalizedString('header', {
+                ts: 1357747017,
+                nonce: 'k3k4j5',
+                method: 'GET',
+                resource: '/resource/something',
+                host: 'example.com',
+                port: 8080,
+                ext: 'this is some app data'
+            })).to.equal('hawk.1.header\n1357747017\nk3k4j5\nGET\n/resource/something\nexample.com\n8080\n\nthis is some app data\n');
+
+            done();
+        });
+
+        it('should return a valid normalized string (payload + ext)', function (done) {
+
+            expect(Hawk.crypto.generateNormalizedString('header', {
+                ts: 1357747017,
+                nonce: 'k3k4j5',
+                method: 'GET',
+                resource: '/resource/something',
+                host: 'example.com',
+                port: 8080,
+                hash: 'U4MKKSmiVxk37JCCrAVIjV/OhB3y+NdwoCr6RShbVkE=',
+                ext: 'this is some app data'
+            })).to.equal('hawk.1.header\n1357747017\nk3k4j5\nGET\n/resource/something\nexample.com\n8080\nU4MKKSmiVxk37JCCrAVIjV/OhB3y+NdwoCr6RShbVkE=\nthis is some app data\n');
+
+            done();
         });
     });
 });
-
diff --git a/deps/npm/node_modules/request/node_modules/hawk/test/message.js b/deps/npm/node_modules/request/node_modules/hawk/test/message.js
deleted file mode 100755 (executable)
index b0494cc..0000000
+++ /dev/null
@@ -1,261 +0,0 @@
-// Load modules
-
-var Url = require('url');
-var Code = require('code');
-var Hawk = require('../lib');
-var Hoek = require('hoek');
-var Lab = require('lab');
-
-
-// Declare internals
-
-var internals = {};
-
-
-// Test shortcuts
-
-var lab = exports.lab = Lab.script();
-var describe = lab.experiment;
-var it = lab.test;
-var expect = Code.expect;
-
-
-describe('Hawk', function () {
-
-    var credentialsFunc = function (id, callback) {
-
-        var credentials = {
-            id: id,
-            key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
-            algorithm: (id === '1' ? 'sha1' : 'sha256'),
-            user: 'steve'
-        };
-
-        return callback(null, credentials);
-    };
-
-    it('should generate an authorization then successfully parse it', function (done) {
-
-        credentialsFunc('123456', function (err, credentials) {
-
-            var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
-            expect(auth).to.exist();
-
-            Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, credentialsFunc, {}, function (err, credentials) {
-
-                expect(err).to.not.exist();
-                expect(credentials.user).to.equal('steve');
-                done();
-            });
-        });
-    });
-
-    it('should fail authorization on mismatching host', function (done) {
-
-        credentialsFunc('123456', function (err, credentials) {
-
-            var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
-            expect(auth).to.exist();
-
-            Hawk.server.authenticateMessage('example1.com', 8080, 'some message', auth, credentialsFunc, {}, function (err, credentials) {
-
-                expect(err).to.exist();
-                expect(err.message).to.equal('Bad mac');
-                done();
-            });
-        });
-    });
-
-    it('should fail authorization on stale timestamp', function (done) {
-
-        credentialsFunc('123456', function (err, credentials) {
-
-            var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
-            expect(auth).to.exist();
-
-            Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, credentialsFunc, { localtimeOffsetMsec: 100000 }, function (err, credentials) {
-
-                expect(err).to.exist();
-                expect(err.message).to.equal('Stale timestamp');
-                done();
-            });
-        });
-    });
-
-    it('overrides timestampSkewSec', function (done) {
-
-        credentialsFunc('123456', function (err, credentials) {
-
-            var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials, localtimeOffsetMsec: 100000 });
-            expect(auth).to.exist();
-
-            Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, credentialsFunc, { timestampSkewSec: 500 }, function (err, credentials) {
-
-                expect(err).to.not.exist();
-                done();
-            });
-        });
-    });
-
-    it('should fail authorization on invalid authorization', function (done) {
-
-        credentialsFunc('123456', function (err, credentials) {
-
-            var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
-            expect(auth).to.exist();
-            delete auth.id;
-
-            Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, credentialsFunc, {}, function (err, credentials) {
-
-                expect(err).to.exist();
-                expect(err.message).to.equal('Invalid authorization');
-                done();
-            });
-        });
-    });
-
-    it('should fail authorization on bad hash', function (done) {
-
-        credentialsFunc('123456', function (err, credentials) {
-
-            var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
-            expect(auth).to.exist();
-
-            Hawk.server.authenticateMessage('example.com', 8080, 'some message1', auth, credentialsFunc, {}, function (err, credentials) {
-
-                expect(err).to.exist();
-                expect(err.message).to.equal('Bad message hash');
-                done();
-            });
-        });
-    });
-
-    it('should fail authorization on nonce error', function (done) {
-
-        credentialsFunc('123456', function (err, credentials) {
-
-            var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
-            expect(auth).to.exist();
-
-            Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, credentialsFunc, { nonceFunc: function (nonce, ts, callback) { callback (new Error('kaboom')); } }, function (err, credentials) {
-
-                expect(err).to.exist();
-                expect(err.message).to.equal('Invalid nonce');
-                done();
-            });
-        });
-    });
-
-    it('should fail authorization on credentials error', function (done) {
-
-        credentialsFunc('123456', function (err, credentials) {
-
-            var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
-            expect(auth).to.exist();
-
-            var errFunc = function (id, callback) {
-
-                callback(new Error('kablooey'));
-            };
-
-            Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, errFunc, {}, function (err, credentials) {
-
-                expect(err).to.exist();
-                expect(err.message).to.equal('kablooey');
-                done();
-            });
-        });
-    });
-
-    it('should fail authorization on missing credentials', function (done) {
-
-        credentialsFunc('123456', function (err, credentials) {
-
-            var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
-            expect(auth).to.exist();
-
-            var errFunc = function (id, callback) {
-
-                callback();
-            };
-
-            Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, errFunc, {}, function (err, credentials) {
-
-                expect(err).to.exist();
-                expect(err.message).to.equal('Unknown credentials');
-                done();
-            });
-        });
-    });
-
-    it('should fail authorization on invalid credentials', function (done) {
-
-        credentialsFunc('123456', function (err, credentials) {
-
-            var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
-            expect(auth).to.exist();
-
-            var errFunc = function (id, callback) {
-
-                callback(null, {});
-            };
-
-            Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, errFunc, {}, function (err, credentials) {
-
-                expect(err).to.exist();
-                expect(err.message).to.equal('Invalid credentials');
-                done();
-            });
-        });
-    });
-
-    it('should fail authorization on invalid credentials algorithm', function (done) {
-
-        credentialsFunc('123456', function (err, credentials) {
-
-            var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
-            expect(auth).to.exist();
-
-            var errFunc = function (id, callback) {
-
-                callback(null, { key: '123', algorithm: '456' });
-            };
-
-            Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, errFunc, {}, function (err, credentials) {
-
-                expect(err).to.exist();
-                expect(err.message).to.equal('Unknown algorithm');
-                done();
-            });
-        });
-    });
-
-    it('should fail on missing host', function (done) {
-
-        credentialsFunc('123456', function (err, credentials) {
-
-            var auth = Hawk.client.message(null, 8080, 'some message', { credentials: credentials });
-            expect(auth).to.not.exist();
-            done();
-        });
-    });
-
-    it('should fail on missing credentials', function (done) {
-
-        var auth = Hawk.client.message('example.com', 8080, 'some message', {});
-        expect(auth).to.not.exist();
-        done();
-    });
-
-    it('should fail on invalid algorithm', function (done) {
-
-        credentialsFunc('123456', function (err, credentials) {
-
-            var creds = Hoek.clone(credentials);
-            creds.algorithm = 'blah';
-            var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: creds });
-            expect(auth).to.not.exist();
-            done();
-        });
-    });
-});
index 60af199..a466264 100755 (executable)
@@ -19,79 +19,76 @@ var it = lab.test;
 var expect = Code.expect;
 
 
-describe('Hawk', function () {
+describe('README', function () {
 
-    describe('README', function () {
+    describe('core', function () {
 
-        describe('core', function () {
+        var credentials = {
+            id: 'dh37fgj492je',
+            key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
+            algorithm: 'sha256'
+        };
 
-            var credentials = {
-                id: 'dh37fgj492je',
-                key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
-                algorithm: 'sha256'
-            };
+        var options = {
+            credentials: credentials,
+            timestamp: 1353832234,
+            nonce: 'j4h3g2',
+            ext: 'some-app-ext-data'
+        };
 
-            var options = {
-                credentials: credentials,
-                timestamp: 1353832234,
-                nonce: 'j4h3g2',
-                ext: 'some-app-ext-data'
-            };
+        it('should generate a header protocol example', function (done) {
 
-            it('should generate a header protocol example', function (done) {
+            var header = Hawk.client.header('http://example.com:8000/resource/1?b=1&a=2', 'GET', options).field;
 
-                var header = Hawk.client.header('http://example.com:8000/resource/1?b=1&a=2', 'GET', options).field;
+            expect(header).to.equal('Hawk id="dh37fgj492je", ts="1353832234", nonce="j4h3g2", ext="some-app-ext-data", mac="6R4rV5iE+NPoym+WwjeHzjAGXUtLNIxmo1vpMofpLAE="');
+            done();
+        });
 
-                expect(header).to.equal('Hawk id="dh37fgj492je", ts="1353832234", nonce="j4h3g2", ext="some-app-ext-data", mac="6R4rV5iE+NPoym+WwjeHzjAGXUtLNIxmo1vpMofpLAE="');
-                done();
-            });
+        it('should generate a normalized string protocol example', function (done) {
 
-            it('should generate a normalized string protocol example', function (done) {
-
-                var normalized = Hawk.crypto.generateNormalizedString('header', {
-                    credentials: credentials,
-                    ts: options.timestamp,
-                    nonce: options.nonce,
-                    method: 'GET',
-                    resource: '/resource?a=1&b=2',
-                    host: 'example.com',
-                    port: 8000,
-                    ext: options.ext
-                });
-
-                expect(normalized).to.equal('hawk.1.header\n1353832234\nj4h3g2\nGET\n/resource?a=1&b=2\nexample.com\n8000\n\nsome-app-ext-data\n');
-                done();
+            var normalized = Hawk.crypto.generateNormalizedString('header', {
+                credentials: credentials,
+                ts: options.timestamp,
+                nonce: options.nonce,
+                method: 'GET',
+                resource: '/resource?a=1&b=2',
+                host: 'example.com',
+                port: 8000,
+                ext: options.ext
             });
 
-            var payloadOptions = Hoek.clone(options);
-            payloadOptions.payload = 'Thank you for flying Hawk';
-            payloadOptions.contentType = 'text/plain';
+            expect(normalized).to.equal('hawk.1.header\n1353832234\nj4h3g2\nGET\n/resource?a=1&b=2\nexample.com\n8000\n\nsome-app-ext-data\n');
+            done();
+        });
 
-            it('should generate a header protocol example (with payload)', function (done) {
+        var payloadOptions = Hoek.clone(options);
+        payloadOptions.payload = 'Thank you for flying Hawk';
+        payloadOptions.contentType = 'text/plain';
 
-                var header = Hawk.client.header('http://example.com:8000/resource/1?b=1&a=2', 'POST', payloadOptions).field;
+        it('should generate a header protocol example (with payload)', function (done) {
 
-                expect(header).to.equal('Hawk id="dh37fgj492je", ts="1353832234", nonce="j4h3g2", hash="Yi9LfIIFRtBEPt74PVmbTF/xVAwPn7ub15ePICfgnuY=", ext="some-app-ext-data", mac="aSe1DERmZuRl3pI36/9BdZmnErTw3sNzOOAUlfeKjVw="');
-                done();
-            });
+            var header = Hawk.client.header('http://example.com:8000/resource/1?b=1&a=2', 'POST', payloadOptions).field;
 
-            it('should generate a normalized string protocol example (with payload)', function (done) {
-
-                var normalized = Hawk.crypto.generateNormalizedString('header', {
-                    credentials: credentials,
-                    ts: options.timestamp,
-                    nonce: options.nonce,
-                    method: 'POST',
-                    resource: '/resource?a=1&b=2',
-                    host: 'example.com',
-                    port: 8000,
-                    hash: Hawk.crypto.calculatePayloadHash(payloadOptions.payload, credentials.algorithm, payloadOptions.contentType),
-                    ext: options.ext
-                });
-
-                expect(normalized).to.equal('hawk.1.header\n1353832234\nj4h3g2\nPOST\n/resource?a=1&b=2\nexample.com\n8000\nYi9LfIIFRtBEPt74PVmbTF/xVAwPn7ub15ePICfgnuY=\nsome-app-ext-data\n');
-                done();
+            expect(header).to.equal('Hawk id="dh37fgj492je", ts="1353832234", nonce="j4h3g2", hash="Yi9LfIIFRtBEPt74PVmbTF/xVAwPn7ub15ePICfgnuY=", ext="some-app-ext-data", mac="aSe1DERmZuRl3pI36/9BdZmnErTw3sNzOOAUlfeKjVw="');
+            done();
+        });
+
+        it('should generate a normalized string protocol example (with payload)', function (done) {
+
+            var normalized = Hawk.crypto.generateNormalizedString('header', {
+                credentials: credentials,
+                ts: options.timestamp,
+                nonce: options.nonce,
+                method: 'POST',
+                resource: '/resource?a=1&b=2',
+                host: 'example.com',
+                port: 8000,
+                hash: Hawk.crypto.calculatePayloadHash(payloadOptions.payload, credentials.algorithm, payloadOptions.contentType),
+                ext: options.ext
             });
+
+            expect(normalized).to.equal('hawk.1.header\n1353832234\nj4h3g2\nPOST\n/resource?a=1&b=2\nexample.com\n8000\nYi9LfIIFRtBEPt74PVmbTF/xVAwPn7ub15ePICfgnuY=\nsome-app-ext-data\n');
+            done();
         });
     });
 });
index 00d7d08..c2899e4 100755 (executable)
@@ -3,6 +3,7 @@
 var Url = require('url');
 var Code = require('code');
 var Hawk = require('../lib');
+var Hoek = require('hoek');
 var Lab = require('lab');
 
 
@@ -19,967 +20,1294 @@ var it = lab.test;
 var expect = Code.expect;
 
 
-describe('Hawk', function () {
+describe('Server', function () {
 
-    describe('server', function () {
+    var credentialsFunc = function (id, callback) {
 
-        var credentialsFunc = function (id, callback) {
+        var credentials = {
+            id: id,
+            key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
+            algorithm: (id === '1' ? 'sha1' : 'sha256'),
+            user: 'steve'
+        };
 
-            var credentials = {
-                id: id,
-                key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
-                algorithm: (id === '1' ? 'sha1' : 'sha256'),
-                user: 'steve'
+        return callback(null, credentials);
+    };
+
+    describe('authenticate()', function () {
+
+        it('parses a valid authentication header (sha1)', function (done) {
+
+            var req = {
+                method: 'GET',
+                url: '/resource/4?filter=a',
+                host: 'example.com',
+                port: 8080,
+                authorization: 'Hawk id="1", ts="1353788437", nonce="k3j4h2", mac="zy79QQ5/EYFmQqutVnYb73gAc/U=", ext="hello"'
             };
 
-            return callback(null, credentials);
-        };
+            Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
 
-        describe('#authenticate', function () {
+                expect(err).to.not.exist();
+                expect(credentials.user).to.equal('steve');
+                done();
+            });
+        });
+
+        it('parses a valid authentication header (sha256)', function (done) {
+
+            var req = {
+                method: 'GET',
+                url: '/resource/1?b=1&a=2',
+                host: 'example.com',
+                port: 8000,
+                authorization: 'Hawk id="dh37fgj492je", ts="1353832234", nonce="j4h3g2", mac="m8r1rHbXN6NgO+KIIhjO7sFRyd78RNGVUwehe8Cp2dU=", ext="some-app-data"'
+            };
+
+            Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353832234000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+
+                expect(err).to.not.exist();
+                expect(credentials.user).to.equal('steve');
+                done();
+            });
+        });
 
-            it('parses a valid authentication header (sha1)', function (done) {
+        it('parses a valid authentication header (host override)', function (done) {
 
-                var req = {
-                    method: 'GET',
-                    url: '/resource/4?filter=a',
-                    host: 'example.com',
-                    port: 8080,
+            var req = {
+                method: 'GET',
+                url: '/resource/4?filter=a',
+                headers: {
+                    host: 'example1.com:8080',
                     authorization: 'Hawk id="1", ts="1353788437", nonce="k3j4h2", mac="zy79QQ5/EYFmQqutVnYb73gAc/U=", ext="hello"'
-                };
+                }
+            };
 
-                Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+            Hawk.server.authenticate(req, credentialsFunc, { host: 'example.com', localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
 
-                    expect(err).to.not.exist();
-                    expect(credentials.user).to.equal('steve');
-                    done();
-                });
+                expect(err).to.not.exist();
+                expect(credentials.user).to.equal('steve');
+                done();
             });
+        });
 
-            it('parses a valid authentication header (sha256)', function (done) {
+        it('parses a valid authentication header (host port override)', function (done) {
 
-                var req = {
-                    method: 'GET',
-                    url: '/resource/1?b=1&a=2',
-                    host: 'example.com',
-                    port: 8000,
-                    authorization: 'Hawk id="dh37fgj492je", ts="1353832234", nonce="j4h3g2", mac="m8r1rHbXN6NgO+KIIhjO7sFRyd78RNGVUwehe8Cp2dU=", ext="some-app-data"'
-                };
+            var req = {
+                method: 'GET',
+                url: '/resource/4?filter=a',
+                headers: {
+                    host: 'example1.com:80',
+                    authorization: 'Hawk id="1", ts="1353788437", nonce="k3j4h2", mac="zy79QQ5/EYFmQqutVnYb73gAc/U=", ext="hello"'
+                }
+            };
 
-                Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353832234000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+            Hawk.server.authenticate(req, credentialsFunc, { host: 'example.com', port: 8080, localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
 
-                    expect(err).to.not.exist();
-                    expect(credentials.user).to.equal('steve');
-                    done();
-                });
+                expect(err).to.not.exist();
+                expect(credentials.user).to.equal('steve');
+                done();
             });
+        });
 
-            it('parses a valid authentication header (host override)', function (done) {
+        it('parses a valid authentication header (POST with payload)', function (done) {
 
-                var req = {
-                    method: 'GET',
-                    url: '/resource/4?filter=a',
+            var req = {
+                method: 'POST',
+                url: '/resource/4?filter=a',
+                host: 'example.com',
+                port: 8080,
+                authorization: 'Hawk id="123456", ts="1357926341", nonce="1AwuJD", hash="qAiXIVv+yjDATneWxZP2YCTa9aHRgQdnH9b3Wc+o3dg=", ext="some-app-data", mac="UeYcj5UoTVaAWXNvJfLVia7kU3VabxCqrccXP8sUGC4="'
+            };
+
+            Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1357926341000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+
+                expect(err).to.not.exist();
+                expect(credentials.user).to.equal('steve');
+                done();
+            });
+        });
+
+        it('errors on missing hash', function (done) {
+
+            var req = {
+                method: 'GET',
+                url: '/resource/1?b=1&a=2',
+                host: 'example.com',
+                port: 8000,
+                authorization: 'Hawk id="dh37fgj492je", ts="1353832234", nonce="j4h3g2", mac="m8r1rHbXN6NgO+KIIhjO7sFRyd78RNGVUwehe8Cp2dU=", ext="some-app-data"'
+            };
+
+            Hawk.server.authenticate(req, credentialsFunc, { payload: 'body', localtimeOffsetMsec: 1353832234000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+
+                expect(err).to.exist();
+                expect(err.output.payload.message).to.equal('Missing required payload hash');
+                done();
+            });
+        });
+
+        it('errors on a stale timestamp', function (done) {
+
+            var req = {
+                method: 'GET',
+                url: '/resource/4?filter=a',
+                host: 'example.com',
+                port: 8080,
+                authorization: 'Hawk id="123456", ts="1362337299", nonce="UzmxSs", ext="some-app-data", mac="wnNUxchvvryMH2RxckTdZ/gY3ijzvccx4keVvELC61w="'
+            };
+
+            Hawk.server.authenticate(req, credentialsFunc, {}, function (err, credentials, artifacts) {
+
+                expect(err).to.exist();
+                expect(err.output.payload.message).to.equal('Stale timestamp');
+                var header = err.output.headers['WWW-Authenticate'];
+                var ts = header.match(/^Hawk ts\=\"(\d+)\"\, tsm\=\"([^\"]+)\"\, error=\"Stale timestamp\"$/);
+                var now = Hawk.utils.now();
+                expect(parseInt(ts[1], 10) * 1000).to.be.within(now - 1000, now + 1000);
+
+                var res = {
                     headers: {
-                        host: 'example1.com:8080',
-                        authorization: 'Hawk id="1", ts="1353788437", nonce="k3j4h2", mac="zy79QQ5/EYFmQqutVnYb73gAc/U=", ext="hello"'
+                        'www-authenticate': header
                     }
                 };
 
-                Hawk.server.authenticate(req, credentialsFunc, { host: 'example.com', localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+                expect(Hawk.client.authenticate(res, credentials, artifacts)).to.equal(true);
+                done();
+            });
+        });
 
-                    expect(err).to.not.exist();
-                    expect(credentials.user).to.equal('steve');
+        it('errors on a replay', function (done) {
+
+            var req = {
+                method: 'GET',
+                url: '/resource/4?filter=a',
+                host: 'example.com',
+                port: 8080,
+                authorization: 'Hawk id="123", ts="1353788437", nonce="k3j4h2", mac="bXx7a7p1h9QYQNZ8x7QhvDQym8ACgab4m3lVSFn4DBw=", ext="hello"'
+            };
+
+            var memoryCache = {};
+            var options = {
+                localtimeOffsetMsec: 1353788437000 - Hawk.utils.now(),
+                nonceFunc: function (key, nonce, ts, callback) {
+
+                    if (memoryCache[key + nonce]) {
+                        return callback(new Error());
+                    }
+
+                    memoryCache[key + nonce] = true;
+                    return callback();
+                }
+            };
+
+            Hawk.server.authenticate(req, credentialsFunc, options, function (err, credentials, artifacts) {
+
+                expect(err).to.not.exist();
+                expect(credentials.user).to.equal('steve');
+
+                Hawk.server.authenticate(req, credentialsFunc, options, function (err, credentials, artifacts) {
+
+                    expect(err).to.exist();
+                    expect(err.output.payload.message).to.equal('Invalid nonce');
                     done();
                 });
             });
+        });
 
-            it('parses a valid authentication header (host port override)', function (done) {
+        it('does not error on nonce collision if keys differ', function (done) {
 
-                var req = {
-                    method: 'GET',
-                    url: '/resource/4?filter=a',
-                    headers: {
-                        host: 'example1.com:80',
-                        authorization: 'Hawk id="1", ts="1353788437", nonce="k3j4h2", mac="zy79QQ5/EYFmQqutVnYb73gAc/U=", ext="hello"'
+            var reqSteve = {
+                method: 'GET',
+                url: '/resource/4?filter=a',
+                host: 'example.com',
+                port: 8080,
+                authorization: 'Hawk id="123", ts="1353788437", nonce="k3j4h2", mac="bXx7a7p1h9QYQNZ8x7QhvDQym8ACgab4m3lVSFn4DBw=", ext="hello"'
+            };
+
+            var reqBob = {
+                method: 'GET',
+                url: '/resource/4?filter=a',
+                host: 'example.com',
+                port: 8080,
+                authorization: 'Hawk id="456", ts="1353788437", nonce="k3j4h2", mac="LXfmTnRzrLd9TD7yfH+4se46Bx6AHyhpM94hLCiNia4=", ext="hello"'
+            };
+
+            var credentialsFunc = function (id, callback) {
+
+                var credentials = {
+                    '123': {
+                        id: id,
+                        key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
+                        algorithm: (id === '1' ? 'sha1' : 'sha256'),
+                        user: 'steve'
+                    },
+                    '456': {
+                        id: id,
+                        key: 'xrunpaw3489ruxnpa98w4rxnwerxhqb98rpaxn39848',
+                        algorithm: (id === '1' ? 'sha1' : 'sha256'),
+                        user: 'bob'
                     }
                 };
 
-                Hawk.server.authenticate(req, credentialsFunc, { host: 'example.com', port: 8080, localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+                return callback(null, credentials[id]);
+            };
+
+            var memoryCache = {};
+            var options = {
+                localtimeOffsetMsec: 1353788437000 - Hawk.utils.now(),
+                nonceFunc: function (key, nonce, ts, callback) {
+
+                    if (memoryCache[key + nonce]) {
+                        return callback(new Error());
+                    }
+
+                    memoryCache[key + nonce] = true;
+                    return callback();
+                }
+            };
+
+            Hawk.server.authenticate(reqSteve, credentialsFunc, options, function (err, credentials, artifacts) {
+
+                expect(err).to.not.exist();
+                expect(credentials.user).to.equal('steve');
+
+                Hawk.server.authenticate(reqBob, credentialsFunc, options, function (err, credentials, artifacts) {
 
                     expect(err).to.not.exist();
-                    expect(credentials.user).to.equal('steve');
+                    expect(credentials.user).to.equal('bob');
                     done();
                 });
             });
+        });
 
-            it('parses a valid authentication header (POST with payload)', function (done) {
+        it('errors on an invalid authentication header: wrong scheme', function (done) {
 
-                var req = {
-                    method: 'POST',
-                    url: '/resource/4?filter=a',
-                    host: 'example.com',
-                    port: 8080,
-                    authorization: 'Hawk id="123456", ts="1357926341", nonce="1AwuJD", hash="qAiXIVv+yjDATneWxZP2YCTa9aHRgQdnH9b3Wc+o3dg=", ext="some-app-data", mac="UeYcj5UoTVaAWXNvJfLVia7kU3VabxCqrccXP8sUGC4="'
-                };
+            var req = {
+                method: 'GET',
+                url: '/resource/4?filter=a',
+                host: 'example.com',
+                port: 8080,
+                authorization: 'Basic asdasdasdasd'
+            };
 
-                Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1357926341000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+            Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
 
-                    expect(err).to.not.exist();
-                    expect(credentials.user).to.equal('steve');
-                    done();
-                });
+                expect(err).to.exist();
+                expect(err.output.payload.message).to.not.exist();
+                done();
             });
+        });
 
-            it('errors on missing hash', function (done) {
+        it('errors on an invalid authentication header: no scheme', function (done) {
 
-                var req = {
-                    method: 'GET',
-                    url: '/resource/1?b=1&a=2',
-                    host: 'example.com',
-                    port: 8000,
-                    authorization: 'Hawk id="dh37fgj492je", ts="1353832234", nonce="j4h3g2", mac="m8r1rHbXN6NgO+KIIhjO7sFRyd78RNGVUwehe8Cp2dU=", ext="some-app-data"'
-                };
+            var req = {
+                method: 'GET',
+                url: '/resource/4?filter=a',
+                host: 'example.com',
+                port: 8080,
+                authorization: '!@#'
+            };
 
-                Hawk.server.authenticate(req, credentialsFunc, { payload: 'body', localtimeOffsetMsec: 1353832234000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+            Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
 
-                    expect(err).to.exist();
-                    expect(err.output.payload.message).to.equal('Missing required payload hash');
-                    done();
-                });
+                expect(err).to.exist();
+                expect(err.output.payload.message).to.equal('Invalid header syntax');
+                done();
+            });
+        });
+
+        it('errors on an missing authorization header', function (done) {
+
+            var req = {
+                method: 'GET',
+                url: '/resource/4?filter=a',
+                host: 'example.com',
+                port: 8080
+            };
+
+            Hawk.server.authenticate(req, credentialsFunc, {}, function (err, credentials, artifacts) {
+
+                expect(err).to.exist();
+                expect(err.isMissing).to.equal(true);
+                done();
             });
+        });
 
-            it('errors on a stale timestamp', function (done) {
+        it('errors on an missing host header', function (done) {
 
-                var req = {
-                    method: 'GET',
-                    url: '/resource/4?filter=a',
-                    host: 'example.com',
-                    port: 8080,
-                    authorization: 'Hawk id="123456", ts="1362337299", nonce="UzmxSs", ext="some-app-data", mac="wnNUxchvvryMH2RxckTdZ/gY3ijzvccx4keVvELC61w="'
-                };
+            var req = {
+                method: 'GET',
+                url: '/resource/4?filter=a',
+                headers: {
+                    authorization: 'Hawk id="123", ts="1353788437", nonce="k3j4h2", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
+                }
+            };
 
-                Hawk.server.authenticate(req, credentialsFunc, {}, function (err, credentials, artifacts) {
+            Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
 
-                    expect(err).to.exist();
-                    expect(err.output.payload.message).to.equal('Stale timestamp');
-                    var header = err.output.headers['WWW-Authenticate'];
-                    var ts = header.match(/^Hawk ts\=\"(\d+)\"\, tsm\=\"([^\"]+)\"\, error=\"Stale timestamp\"$/);
-                    var now = Hawk.utils.now();
-                    expect(parseInt(ts[1], 10) * 1000).to.be.within(now - 1000, now + 1000);
-
-                    var res = {
-                        headers: {
-                            'www-authenticate': header
-                        }
-                    };
-
-                    expect(Hawk.client.authenticate(res, credentials, artifacts)).to.equal(true);
-                    done();
-                });
+                expect(err).to.exist();
+                expect(err.output.payload.message).to.equal('Invalid Host header');
+                done();
             });
+        });
+
+        it('errors on an missing authorization attribute (id)', function (done) {
 
-            it('errors on a replay', function (done) {
+            var req = {
+                method: 'GET',
+                url: '/resource/4?filter=a',
+                host: 'example.com',
+                port: 8080,
+                authorization: 'Hawk ts="1353788437", nonce="k3j4h2", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
+            };
+
+            Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+
+                expect(err).to.exist();
+                expect(err.output.payload.message).to.equal('Missing attributes');
+                done();
+            });
+        });
 
-                var req = {
-                    method: 'GET',
-                    url: '/resource/4?filter=a',
-                    host: 'example.com',
-                    port: 8080,
-                    authorization: 'Hawk id="123", ts="1353788437", nonce="k3j4h2", mac="bXx7a7p1h9QYQNZ8x7QhvDQym8ACgab4m3lVSFn4DBw=", ext="hello"'
+        it('errors on an missing authorization attribute (ts)', function (done) {
+
+            var req = {
+                method: 'GET',
+                url: '/resource/4?filter=a',
+                host: 'example.com',
+                port: 8080,
+                authorization: 'Hawk id="123", nonce="k3j4h2", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
+            };
+
+            Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+
+                expect(err).to.exist();
+                expect(err.output.payload.message).to.equal('Missing attributes');
+                done();
+            });
+        });
+
+        it('errors on an missing authorization attribute (nonce)', function (done) {
+
+            var req = {
+                method: 'GET',
+                url: '/resource/4?filter=a',
+                host: 'example.com',
+                port: 8080,
+                authorization: 'Hawk id="123", ts="1353788437", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
+            };
+
+            Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+
+                expect(err).to.exist();
+                expect(err.output.payload.message).to.equal('Missing attributes');
+                done();
+            });
+        });
+
+        it('errors on an missing authorization attribute (mac)', function (done) {
+
+            var req = {
+                method: 'GET',
+                url: '/resource/4?filter=a',
+                host: 'example.com',
+                port: 8080,
+                authorization: 'Hawk id="123", ts="1353788437", nonce="k3j4h2", ext="hello"'
+            };
+
+            Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+
+                expect(err).to.exist();
+                expect(err.output.payload.message).to.equal('Missing attributes');
+                done();
+            });
+        });
+
+        it('errors on an unknown authorization attribute', function (done) {
+
+            var req = {
+                method: 'GET',
+                url: '/resource/4?filter=a',
+                host: 'example.com',
+                port: 8080,
+                authorization: 'Hawk id="123", ts="1353788437", nonce="k3j4h2", x="3", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
+            };
+
+            Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+
+                expect(err).to.exist();
+                expect(err.output.payload.message).to.equal('Unknown attribute: x');
+                done();
+            });
+        });
+
+        it('errors on an bad authorization header format', function (done) {
+
+            var req = {
+                method: 'GET',
+                url: '/resource/4?filter=a',
+                host: 'example.com',
+                port: 8080,
+                authorization: 'Hawk id="123\\", ts="1353788437", nonce="k3j4h2", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
+            };
+
+            Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+
+                expect(err).to.exist();
+                expect(err.output.payload.message).to.equal('Bad header format');
+                done();
+            });
+        });
+
+        it('errors on an bad authorization attribute value', function (done) {
+
+            var req = {
+                method: 'GET',
+                url: '/resource/4?filter=a',
+                host: 'example.com',
+                port: 8080,
+                authorization: 'Hawk id="\t", ts="1353788437", nonce="k3j4h2", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
+            };
+
+            Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+
+                expect(err).to.exist();
+                expect(err.output.payload.message).to.equal('Bad attribute value: id');
+                done();
+            });
+        });
+
+        it('errors on an empty authorization attribute value', function (done) {
+
+            var req = {
+                method: 'GET',
+                url: '/resource/4?filter=a',
+                host: 'example.com',
+                port: 8080,
+                authorization: 'Hawk id="", ts="1353788437", nonce="k3j4h2", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
+            };
+
+            Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+
+                expect(err).to.exist();
+                expect(err.output.payload.message).to.equal('Bad attribute value: id');
+                done();
+            });
+        });
+
+        it('errors on duplicated authorization attribute key', function (done) {
+
+            var req = {
+                method: 'GET',
+                url: '/resource/4?filter=a',
+                host: 'example.com',
+                port: 8080,
+                authorization: 'Hawk id="123", id="456", ts="1353788437", nonce="k3j4h2", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
+            };
+
+            Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+
+                expect(err).to.exist();
+                expect(err.output.payload.message).to.equal('Duplicate attribute: id');
+                done();
+            });
+        });
+
+        it('errors on an invalid authorization header format', function (done) {
+
+            var req = {
+                method: 'GET',
+                url: '/resource/4?filter=a',
+                host: 'example.com',
+                port: 8080,
+                authorization: 'Hawk'
+            };
+
+            Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+
+                expect(err).to.exist();
+                expect(err.output.payload.message).to.equal('Invalid header syntax');
+                done();
+            });
+        });
+
+        it('errors on an bad host header (missing host)', function (done) {
+
+            var req = {
+                method: 'GET',
+                url: '/resource/4?filter=a',
+                headers: {
+                    host: ':8080',
+                    authorization: 'Hawk id="123", ts="1353788437", nonce="k3j4h2", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
+                }
+            };
+
+            Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+
+                expect(err).to.exist();
+                expect(err.output.payload.message).to.equal('Invalid Host header');
+                done();
+            });
+        });
+
+        it('errors on an bad host header (pad port)', function (done) {
+
+            var req = {
+                method: 'GET',
+                url: '/resource/4?filter=a',
+                headers: {
+                    host: 'example.com:something',
+                    authorization: 'Hawk id="123", ts="1353788437", nonce="k3j4h2", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
+                }
+            };
+
+            Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+
+                expect(err).to.exist();
+                expect(err.output.payload.message).to.equal('Invalid Host header');
+                done();
+            });
+        });
+
+        it('errors on credentialsFunc error', function (done) {
+
+            var req = {
+                method: 'GET',
+                url: '/resource/4?filter=a',
+                host: 'example.com',
+                port: 8080,
+                authorization: 'Hawk id="123", ts="1353788437", nonce="k3j4h2", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
+            };
+
+            var credentialsFunc = function (id, callback) {
+
+                return callback(new Error('Unknown user'));
+            };
+
+            Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+
+                expect(err).to.exist();
+                expect(err.message).to.equal('Unknown user');
+                done();
+            });
+        });
+
+        it('errors on credentialsFunc error (with credentials)', function (done) {
+
+            var req = {
+                method: 'GET',
+                url: '/resource/4?filter=a',
+                host: 'example.com',
+                port: 8080,
+                authorization: 'Hawk id="123", ts="1353788437", nonce="k3j4h2", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
+            };
+
+            var credentialsFunc = function (id, callback) {
+
+                return callback(new Error('Unknown user'), { some: 'value' });
+            };
+
+            Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+
+                expect(err).to.exist();
+                expect(err.message).to.equal('Unknown user');
+                expect(credentials.some).to.equal('value');
+                done();
+            });
+        });
+
+        it('errors on missing credentials', function (done) {
+
+            var req = {
+                method: 'GET',
+                url: '/resource/4?filter=a',
+                host: 'example.com',
+                port: 8080,
+                authorization: 'Hawk id="123", ts="1353788437", nonce="k3j4h2", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
+            };
+
+            var credentialsFunc = function (id, callback) {
+
+                return callback(null, null);
+            };
+
+            Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+
+                expect(err).to.exist();
+                expect(err.output.payload.message).to.equal('Unknown credentials');
+                done();
+            });
+        });
+
+        it('errors on invalid credentials (id)', function (done) {
+
+            var req = {
+                method: 'GET',
+                url: '/resource/4?filter=a',
+                host: 'example.com',
+                port: 8080,
+                authorization: 'Hawk id="123", ts="1353788437", nonce="k3j4h2", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
+            };
+
+            var credentialsFunc = function (id, callback) {
+
+                var credentials = {
+                    key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
+                    user: 'steve'
                 };
 
-                var memoryCache = {};
-                var options = {
-                    localtimeOffsetMsec: 1353788437000 - Hawk.utils.now(),
-                    nonceFunc: function (nonce, ts, callback) {
+                return callback(null, credentials);
+            };
 
-                        if (memoryCache[nonce]) {
-                            return callback(new Error());
-                        }
+            Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
 
-                        memoryCache[nonce] = true;
-                        return callback();
-                    }
+                expect(err).to.exist();
+                expect(err.message).to.equal('Invalid credentials');
+                expect(err.output.payload.message).to.equal('An internal server error occurred');
+                done();
+            });
+        });
+
+        it('errors on invalid credentials (key)', function (done) {
+
+            var req = {
+                method: 'GET',
+                url: '/resource/4?filter=a',
+                host: 'example.com',
+                port: 8080,
+                authorization: 'Hawk id="123", ts="1353788437", nonce="k3j4h2", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
+            };
+
+            var credentialsFunc = function (id, callback) {
+
+                var credentials = {
+                    id: '23434d3q4d5345d',
+                    user: 'steve'
                 };
 
-                Hawk.server.authenticate(req, credentialsFunc, options, function (err, credentials, artifacts) {
+                return callback(null, credentials);
+            };
 
-                    expect(err).to.not.exist();
-                    expect(credentials.user).to.equal('steve');
+            Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
 
-                    Hawk.server.authenticate(req, credentialsFunc, options, function (err, credentials, artifacts) {
+                expect(err).to.exist();
+                expect(err.message).to.equal('Invalid credentials');
+                expect(err.output.payload.message).to.equal('An internal server error occurred');
+                done();
+            });
+        });
 
-                        expect(err).to.exist();
-                        expect(err.output.payload.message).to.equal('Invalid nonce');
-                        done();
-                    });
-                });
+        it('errors on unknown credentials algorithm', function (done) {
+
+            var req = {
+                method: 'GET',
+                url: '/resource/4?filter=a',
+                host: 'example.com',
+                port: 8080,
+                authorization: 'Hawk id="123", ts="1353788437", nonce="k3j4h2", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
+            };
+
+            var credentialsFunc = function (id, callback) {
+
+                var credentials = {
+                    key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
+                    algorithm: 'hmac-sha-0',
+                    user: 'steve'
+                };
+
+                return callback(null, credentials);
+            };
+
+            Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+
+                expect(err).to.exist();
+                expect(err.message).to.equal('Unknown algorithm');
+                expect(err.output.payload.message).to.equal('An internal server error occurred');
+                done();
             });
+        });
 
-            it('errors on an invalid authentication header: wrong scheme', function (done) {
+        it('errors on unknown bad mac', function (done) {
 
-                var req = {
-                    method: 'GET',
-                    url: '/resource/4?filter=a',
-                    host: 'example.com',
-                    port: 8080,
-                    authorization: 'Basic asdasdasdasd'
+            var req = {
+                method: 'GET',
+                url: '/resource/4?filter=a',
+                host: 'example.com',
+                port: 8080,
+                authorization: 'Hawk id="123", ts="1353788437", nonce="k3j4h2", mac="/qwS4UjfVWMcU4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
+            };
+
+            var credentialsFunc = function (id, callback) {
+
+                var credentials = {
+                    key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
+                    algorithm: 'sha256',
+                    user: 'steve'
                 };
 
-                Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+                return callback(null, credentials);
+            };
 
-                    expect(err).to.exist();
-                    expect(err.output.payload.message).to.not.exist();
-                    done();
-                });
+            Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+
+                expect(err).to.exist();
+                expect(err.output.payload.message).to.equal('Bad mac');
+                done();
             });
+        });
+    });
+
+    describe('header()', function () {
+
+        it('generates header', function (done) {
+
+            var credentials = {
+                id: '123456',
+                key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
+                algorithm: 'sha256',
+                user: 'steve'
+            };
+
+            var artifacts = {
+                method: 'POST',
+                host: 'example.com',
+                port: '8080',
+                resource: '/resource/4?filter=a',
+                ts: '1398546787',
+                nonce: 'xUwusx',
+                hash: 'nJjkVtBE5Y/Bk38Aiokwn0jiJxt/0S2WRSUwWLCf5xk=',
+                ext: 'some-app-data',
+                mac: 'dvIvMThwi28J61Jc3P0ryAhuKpanU63GXdx6hkmQkJA=',
+                id: '123456'
+            };
+
+            var header = Hawk.server.header(credentials, artifacts, { payload: 'some reply', contentType: 'text/plain', ext: 'response-specific' });
+            expect(header).to.equal('Hawk mac=\"n14wVJK4cOxAytPUMc5bPezQzuJGl5n7MYXhFQgEKsE=\", hash=\"f9cDF/TDm7TkYRLnGwRMfeDzT6LixQVLvrIKhh0vgmM=\", ext=\"response-specific\"');
+            done();
+        });
+
+        it('generates header (empty payload)', function (done) {
+
+            var credentials = {
+                id: '123456',
+                key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
+                algorithm: 'sha256',
+                user: 'steve'
+            };
+
+            var artifacts = {
+                method: 'POST',
+                host: 'example.com',
+                port: '8080',
+                resource: '/resource/4?filter=a',
+                ts: '1398546787',
+                nonce: 'xUwusx',
+                hash: 'nJjkVtBE5Y/Bk38Aiokwn0jiJxt/0S2WRSUwWLCf5xk=',
+                ext: 'some-app-data',
+                mac: 'dvIvMThwi28J61Jc3P0ryAhuKpanU63GXdx6hkmQkJA=',
+                id: '123456'
+            };
+
+            var header = Hawk.server.header(credentials, artifacts, { payload: '', contentType: 'text/plain', ext: 'response-specific' });
+            expect(header).to.equal('Hawk mac=\"i8/kUBDx0QF+PpCtW860kkV/fa9dbwEoe/FpGUXowf0=\", hash=\"q/t+NNAkQZNlq/aAD6PlexImwQTxwgT2MahfTa9XRLA=\", ext=\"response-specific\"');
+            done();
+        });
+
+        it('generates header (pre calculated hash)', function (done) {
+
+            var credentials = {
+                id: '123456',
+                key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
+                algorithm: 'sha256',
+                user: 'steve'
+            };
+
+            var artifacts = {
+                method: 'POST',
+                host: 'example.com',
+                port: '8080',
+                resource: '/resource/4?filter=a',
+                ts: '1398546787',
+                nonce: 'xUwusx',
+                hash: 'nJjkVtBE5Y/Bk38Aiokwn0jiJxt/0S2WRSUwWLCf5xk=',
+                ext: 'some-app-data',
+                mac: 'dvIvMThwi28J61Jc3P0ryAhuKpanU63GXdx6hkmQkJA=',
+                id: '123456'
+            };
+
+            var options = { payload: 'some reply', contentType: 'text/plain', ext: 'response-specific' };
+            options.hash = Hawk.crypto.calculatePayloadHash(options.payload, credentials.algorithm, options.contentType);
+            var header = Hawk.server.header(credentials, artifacts, options);
+            expect(header).to.equal('Hawk mac=\"n14wVJK4cOxAytPUMc5bPezQzuJGl5n7MYXhFQgEKsE=\", hash=\"f9cDF/TDm7TkYRLnGwRMfeDzT6LixQVLvrIKhh0vgmM=\", ext=\"response-specific\"');
+            done();
+        });
+
+        it('generates header (null ext)', function (done) {
+
+            var credentials = {
+                id: '123456',
+                key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
+                algorithm: 'sha256',
+                user: 'steve'
+            };
+
+            var artifacts = {
+                method: 'POST',
+                host: 'example.com',
+                port: '8080',
+                resource: '/resource/4?filter=a',
+                ts: '1398546787',
+                nonce: 'xUwusx',
+                hash: 'nJjkVtBE5Y/Bk38Aiokwn0jiJxt/0S2WRSUwWLCf5xk=',
+                mac: 'dvIvMThwi28J61Jc3P0ryAhuKpanU63GXdx6hkmQkJA=',
+                id: '123456'
+            };
+
+            var header = Hawk.server.header(credentials, artifacts, { payload: 'some reply', contentType: 'text/plain', ext: null });
+            expect(header).to.equal('Hawk mac=\"6PrybJTJs20jsgBw5eilXpcytD8kUbaIKNYXL+6g0ns=\", hash=\"f9cDF/TDm7TkYRLnGwRMfeDzT6LixQVLvrIKhh0vgmM=\"');
+            done();
+        });
+
+        it('errors on missing artifacts', function (done) {
+
+            var credentials = {
+                id: '123456',
+                key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
+                algorithm: 'sha256',
+                user: 'steve'
+            };
 
-            it('errors on an invalid authentication header: no scheme', function (done) {
+            var header = Hawk.server.header(credentials, null, { payload: 'some reply', contentType: 'text/plain', ext: 'response-specific' });
+            expect(header).to.equal('');
+            done();
+        });
 
-                var req = {
-                    method: 'GET',
-                    url: '/resource/4?filter=a',
-                    host: 'example.com',
-                    port: 8080,
-                    authorization: '!@#'
-                };
+        it('errors on invalid artifacts', function (done) {
 
-                Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+            var credentials = {
+                id: '123456',
+                key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
+                algorithm: 'sha256',
+                user: 'steve'
+            };
 
-                    expect(err).to.exist();
-                    expect(err.output.payload.message).to.equal('Invalid header syntax');
-                    done();
-                });
-            });
+            var header = Hawk.server.header(credentials, 5, { payload: 'some reply', contentType: 'text/plain', ext: 'response-specific' });
+            expect(header).to.equal('');
+            done();
+        });
 
-            it('errors on an missing authorization header', function (done) {
+        it('errors on missing credentials', function (done) {
+
+            var artifacts = {
+                method: 'POST',
+                host: 'example.com',
+                port: '8080',
+                resource: '/resource/4?filter=a',
+                ts: '1398546787',
+                nonce: 'xUwusx',
+                hash: 'nJjkVtBE5Y/Bk38Aiokwn0jiJxt/0S2WRSUwWLCf5xk=',
+                ext: 'some-app-data',
+                mac: 'dvIvMThwi28J61Jc3P0ryAhuKpanU63GXdx6hkmQkJA=',
+                id: '123456'
+            };
 
-                var req = {
-                    method: 'GET',
-                    url: '/resource/4?filter=a',
-                    host: 'example.com',
-                    port: 8080
-                };
+            var header = Hawk.server.header(null, artifacts, { payload: 'some reply', contentType: 'text/plain', ext: 'response-specific' });
+            expect(header).to.equal('');
+            done();
+        });
 
-                Hawk.server.authenticate(req, credentialsFunc, {}, function (err, credentials, artifacts) {
+        it('errors on invalid credentials (key)', function (done) {
 
-                    expect(err).to.exist();
-                    expect(err.isMissing).to.equal(true);
-                    done();
-                });
-            });
+            var credentials = {
+                id: '123456',
+                algorithm: 'sha256',
+                user: 'steve'
+            };
 
-            it('errors on an missing host header', function (done) {
+            var artifacts = {
+                method: 'POST',
+                host: 'example.com',
+                port: '8080',
+                resource: '/resource/4?filter=a',
+                ts: '1398546787',
+                nonce: 'xUwusx',
+                hash: 'nJjkVtBE5Y/Bk38Aiokwn0jiJxt/0S2WRSUwWLCf5xk=',
+                ext: 'some-app-data',
+                mac: 'dvIvMThwi28J61Jc3P0ryAhuKpanU63GXdx6hkmQkJA=',
+                id: '123456'
+            };
 
-                var req = {
-                    method: 'GET',
-                    url: '/resource/4?filter=a',
-                    headers: {
-                        authorization: 'Hawk id="123", ts="1353788437", nonce="k3j4h2", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
-                    }
-                };
+            var header = Hawk.server.header(credentials, artifacts, { payload: 'some reply', contentType: 'text/plain', ext: 'response-specific' });
+            expect(header).to.equal('');
+            done();
+        });
 
-                Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+        it('errors on invalid algorithm', function (done) {
 
-                    expect(err).to.exist();
-                    expect(err.output.payload.message).to.equal('Invalid Host header');
-                    done();
-                });
-            });
+            var credentials = {
+                id: '123456',
+                key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
+                algorithm: 'x',
+                user: 'steve'
+            };
 
-            it('errors on an missing authorization attribute (id)', function (done) {
+            var artifacts = {
+                method: 'POST',
+                host: 'example.com',
+                port: '8080',
+                resource: '/resource/4?filter=a',
+                ts: '1398546787',
+                nonce: 'xUwusx',
+                hash: 'nJjkVtBE5Y/Bk38Aiokwn0jiJxt/0S2WRSUwWLCf5xk=',
+                ext: 'some-app-data',
+                mac: 'dvIvMThwi28J61Jc3P0ryAhuKpanU63GXdx6hkmQkJA=',
+                id: '123456'
+            };
 
-                var req = {
-                    method: 'GET',
-                    url: '/resource/4?filter=a',
-                    host: 'example.com',
-                    port: 8080,
-                    authorization: 'Hawk ts="1353788437", nonce="k3j4h2", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
-                };
+            var header = Hawk.server.header(credentials, artifacts, { payload: 'some reply', contentType: 'text/plain', ext: 'response-specific' });
+            expect(header).to.equal('');
+            done();
+        });
+    });
 
-                Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+    describe('authenticateMessage()', function () {
 
-                    expect(err).to.exist();
-                    expect(err.output.payload.message).to.equal('Missing attributes');
-                    done();
-                });
-            });
+        it('errors on invalid authorization (ts)', function (done) {
 
-            it('errors on an missing authorization attribute (ts)', function (done) {
+            credentialsFunc('123456', function (err, credentials) {
 
-                var req = {
-                    method: 'GET',
-                    url: '/resource/4?filter=a',
-                    host: 'example.com',
-                    port: 8080,
-                    authorization: 'Hawk id="123", nonce="k3j4h2", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
-                };
+                var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
+                delete auth.ts;
 
-                Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+                Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, credentialsFunc, {}, function (err, credentials) {
 
                     expect(err).to.exist();
-                    expect(err.output.payload.message).to.equal('Missing attributes');
+                    expect(err.message).to.equal('Invalid authorization');
                     done();
                 });
             });
+        });
 
-            it('errors on an missing authorization attribute (nonce)', function (done) {
+        it('errors on invalid authorization (nonce)', function (done) {
 
-                var req = {
-                    method: 'GET',
-                    url: '/resource/4?filter=a',
-                    host: 'example.com',
-                    port: 8080,
-                    authorization: 'Hawk id="123", ts="1353788437", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
-                };
+            credentialsFunc('123456', function (err, credentials) {
+
+                var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
+                delete auth.nonce;
 
-                Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+                Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, credentialsFunc, {}, function (err, credentials) {
 
                     expect(err).to.exist();
-                    expect(err.output.payload.message).to.equal('Missing attributes');
+                    expect(err.message).to.equal('Invalid authorization');
                     done();
                 });
             });
+        });
 
-            it('errors on an missing authorization attribute (mac)', function (done) {
+        it('errors on invalid authorization (hash)', function (done) {
 
-                var req = {
-                    method: 'GET',
-                    url: '/resource/4?filter=a',
-                    host: 'example.com',
-                    port: 8080,
-                    authorization: 'Hawk id="123", ts="1353788437", nonce="k3j4h2", ext="hello"'
-                };
+            credentialsFunc('123456', function (err, credentials) {
 
-                Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+                var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
+                delete auth.hash;
+
+                Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, credentialsFunc, {}, function (err, credentials) {
 
                     expect(err).to.exist();
-                    expect(err.output.payload.message).to.equal('Missing attributes');
+                    expect(err.message).to.equal('Invalid authorization');
                     done();
                 });
             });
+        });
 
-            it('errors on an unknown authorization attribute', function (done) {
-
-                var req = {
-                    method: 'GET',
-                    url: '/resource/4?filter=a',
-                    host: 'example.com',
-                    port: 8080,
-                    authorization: 'Hawk id="123", ts="1353788437", nonce="k3j4h2", x="3", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
-                };
-
-                Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+        it('errors with credentials', function (done) {
 
-                    expect(err).to.exist();
-                    expect(err.output.payload.message).to.equal('Unknown attribute: x');
-                    done();
-                });
-            });
+            credentialsFunc('123456', function (err, credentials) {
 
-            it('errors on an bad authorization header format', function (done) {
+                var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
 
-                var req = {
-                    method: 'GET',
-                    url: '/resource/4?filter=a',
-                    host: 'example.com',
-                    port: 8080,
-                    authorization: 'Hawk id="123\\", ts="1353788437", nonce="k3j4h2", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
-                };
+                Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, function (id, callback) {
 
-                Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+                    callback(new Error('something'), { some: 'value' });
+                }, {}, function (err, credentials) {
 
                     expect(err).to.exist();
-                    expect(err.output.payload.message).to.equal('Bad header format');
+                    expect(err.message).to.equal('something');
+                    expect(credentials.some).to.equal('value');
                     done();
                 });
             });
+        });
 
-            it('errors on an bad authorization attribute value', function (done) {
+        it('errors on nonce collision', function (done) {
 
-                var req = {
-                    method: 'GET',
-                    url: '/resource/4?filter=a',
-                    host: 'example.com',
-                    port: 8080,
-                    authorization: 'Hawk id="\t", ts="1353788437", nonce="k3j4h2", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
-                };
+            credentialsFunc('123456', function (err, credentials) {
+
+                var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
+                Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, credentialsFunc, {
+                    nonceFunc: function (key, nonce, ts, nonceCallback) {
 
-                Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+                        nonceCallback(true);
+                    }
+                }, function (err, credentials) {
 
                     expect(err).to.exist();
-                    expect(err.output.payload.message).to.equal('Bad attribute value: id');
+                    expect(err.message).to.equal('Invalid nonce');
                     done();
                 });
             });
+        });
 
-            it('errors on an empty authorization attribute value', function (done) {
+        var credentialsFunc = function (id, callback) {
 
-                var req = {
-                    method: 'GET',
-                    url: '/resource/4?filter=a',
-                    host: 'example.com',
-                    port: 8080,
-                    authorization: 'Hawk id="", ts="1353788437", nonce="k3j4h2", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
-                };
+            var credentials = {
+                id: id,
+                key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
+                algorithm: (id === '1' ? 'sha1' : 'sha256'),
+                user: 'steve'
+            };
 
-                Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+            return callback(null, credentials);
+        };
 
-                    expect(err).to.exist();
-                    expect(err.output.payload.message).to.equal('Bad attribute value: id');
-                    done();
-                });
-            });
+        it('should generate an authorization then successfully parse it', function (done) {
 
-            it('errors on duplicated authorization attribute key', function (done) {
+            credentialsFunc('123456', function (err, credentials) {
 
-                var req = {
-                    method: 'GET',
-                    url: '/resource/4?filter=a',
-                    host: 'example.com',
-                    port: 8080,
-                    authorization: 'Hawk id="123", id="456", ts="1353788437", nonce="k3j4h2", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
-                };
+                var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
+                expect(auth).to.exist();
 
-                Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+                Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, credentialsFunc, {}, function (err, credentials) {
 
-                    expect(err).to.exist();
-                    expect(err.output.payload.message).to.equal('Duplicate attribute: id');
+                    expect(err).to.not.exist();
+                    expect(credentials.user).to.equal('steve');
                     done();
                 });
             });
+        });
 
-            it('errors on an invalid authorization header format', function (done) {
+        it('should fail authorization on mismatching host', function (done) {
 
-                var req = {
-                    method: 'GET',
-                    url: '/resource/4?filter=a',
-                    host: 'example.com',
-                    port: 8080,
-                    authorization: 'Hawk'
-                };
+            credentialsFunc('123456', function (err, credentials) {
 
-                Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+                var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
+                expect(auth).to.exist();
+
+                Hawk.server.authenticateMessage('example1.com', 8080, 'some message', auth, credentialsFunc, {}, function (err, credentials) {
 
                     expect(err).to.exist();
-                    expect(err.output.payload.message).to.equal('Invalid header syntax');
+                    expect(err.message).to.equal('Bad mac');
                     done();
                 });
             });
+        });
 
-            it('errors on an bad host header (missing host)', function (done) {
+        it('should fail authorization on stale timestamp', function (done) {
 
-                var req = {
-                    method: 'GET',
-                    url: '/resource/4?filter=a',
-                    headers: {
-                        host: ':8080',
-                        authorization: 'Hawk id="123", ts="1353788437", nonce="k3j4h2", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
-                    }
-                };
+            credentialsFunc('123456', function (err, credentials) {
+
+                var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
+                expect(auth).to.exist();
 
-                Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+                Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, credentialsFunc, { localtimeOffsetMsec: 100000 }, function (err, credentials) {
 
                     expect(err).to.exist();
-                    expect(err.output.payload.message).to.equal('Invalid Host header');
+                    expect(err.message).to.equal('Stale timestamp');
                     done();
                 });
             });
+        });
 
-            it('errors on an bad host header (pad port)', function (done) {
+        it('overrides timestampSkewSec', function (done) {
 
-                var req = {
-                    method: 'GET',
-                    url: '/resource/4?filter=a',
-                    headers: {
-                        host: 'example.com:something',
-                        authorization: 'Hawk id="123", ts="1353788437", nonce="k3j4h2", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
-                    }
-                };
+            credentialsFunc('123456', function (err, credentials) {
 
-                Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+                var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials, localtimeOffsetMsec: 100000 });
+                expect(auth).to.exist();
 
-                    expect(err).to.exist();
-                    expect(err.output.payload.message).to.equal('Invalid Host header');
+                Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, credentialsFunc, { timestampSkewSec: 500 }, function (err, credentials) {
+
+                    expect(err).to.not.exist();
                     done();
                 });
             });
+        });
 
-            it('errors on credentialsFunc error', function (done) {
-
-                var req = {
-                    method: 'GET',
-                    url: '/resource/4?filter=a',
-                    host: 'example.com',
-                    port: 8080,
-                    authorization: 'Hawk id="123", ts="1353788437", nonce="k3j4h2", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
-                };
+        it('should fail authorization on invalid authorization', function (done) {
 
-                var credentialsFunc = function (id, callback) {
+            credentialsFunc('123456', function (err, credentials) {
 
-                    return callback(new Error('Unknown user'));
-                };
+                var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
+                expect(auth).to.exist();
+                delete auth.id;
 
-                Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+                Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, credentialsFunc, {}, function (err, credentials) {
 
                     expect(err).to.exist();
-                    expect(err.message).to.equal('Unknown user');
+                    expect(err.message).to.equal('Invalid authorization');
                     done();
                 });
             });
+        });
 
-            it('errors on credentialsFunc error (with credentials)', function (done) {
-
-                var req = {
-                    method: 'GET',
-                    url: '/resource/4?filter=a',
-                    host: 'example.com',
-                    port: 8080,
-                    authorization: 'Hawk id="123", ts="1353788437", nonce="k3j4h2", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
-                };
+        it('should fail authorization on bad hash', function (done) {
 
-                var credentialsFunc = function (id, callback) {
+            credentialsFunc('123456', function (err, credentials) {
 
-                    return callback(new Error('Unknown user'), { some: 'value' });
-                };
+                var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
+                expect(auth).to.exist();
 
-                Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+                Hawk.server.authenticateMessage('example.com', 8080, 'some message1', auth, credentialsFunc, {}, function (err, credentials) {
 
                     expect(err).to.exist();
-                    expect(err.message).to.equal('Unknown user');
-                    expect(credentials.some).to.equal('value');
+                    expect(err.message).to.equal('Bad message hash');
                     done();
                 });
             });
+        });
 
-            it('errors on missing credentials', function (done) {
+        it('should fail authorization on nonce error', function (done) {
 
-                var req = {
-                    method: 'GET',
-                    url: '/resource/4?filter=a',
-                    host: 'example.com',
-                    port: 8080,
-                    authorization: 'Hawk id="123", ts="1353788437", nonce="k3j4h2", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
-                };
+            credentialsFunc('123456', function (err, credentials) {
 
-                var credentialsFunc = function (id, callback) {
+                var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
+                expect(auth).to.exist();
 
-                    return callback(null, null);
-                };
+                Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, credentialsFunc, {
+                    nonceFunc: function (key, nonce, ts, callback) {
 
-                Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+                        callback(new Error('kaboom'));
+                    }
+                }, function (err, credentials) {
 
                     expect(err).to.exist();
-                    expect(err.output.payload.message).to.equal('Unknown credentials');
+                    expect(err.message).to.equal('Invalid nonce');
                     done();
                 });
             });
+        });
 
-            it('errors on invalid credentials (id)', function (done) {
+        it('should fail authorization on credentials error', function (done) {
 
-                var req = {
-                    method: 'GET',
-                    url: '/resource/4?filter=a',
-                    host: 'example.com',
-                    port: 8080,
-                    authorization: 'Hawk id="123", ts="1353788437", nonce="k3j4h2", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
-                };
+            credentialsFunc('123456', function (err, credentials) {
 
-                var credentialsFunc = function (id, callback) {
+                var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
+                expect(auth).to.exist();
 
-                    var credentials = {
-                        key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
-                        user: 'steve'
-                    };
+                var errFunc = function (id, callback) {
 
-                    return callback(null, credentials);
+                    callback(new Error('kablooey'));
                 };
 
-                Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+                Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, errFunc, {}, function (err, credentials) {
 
                     expect(err).to.exist();
-                    expect(err.message).to.equal('Invalid credentials');
-                    expect(err.output.payload.message).to.equal('An internal server error occurred');
+                    expect(err.message).to.equal('kablooey');
                     done();
                 });
             });
+        });
 
-            it('errors on invalid credentials (key)', function (done) {
+        it('should fail authorization on missing credentials', function (done) {
 
-                var req = {
-                    method: 'GET',
-                    url: '/resource/4?filter=a',
-                    host: 'example.com',
-                    port: 8080,
-                    authorization: 'Hawk id="123", ts="1353788437", nonce="k3j4h2", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
-                };
+            credentialsFunc('123456', function (err, credentials) {
 
-                var credentialsFunc = function (id, callback) {
+                var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
+                expect(auth).to.exist();
 
-                    var credentials = {
-                        id: '23434d3q4d5345d',
-                        user: 'steve'
-                    };
+                var errFunc = function (id, callback) {
 
-                    return callback(null, credentials);
+                    callback();
                 };
 
-                Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+                Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, errFunc, {}, function (err, credentials) {
 
                     expect(err).to.exist();
-                    expect(err.message).to.equal('Invalid credentials');
-                    expect(err.output.payload.message).to.equal('An internal server error occurred');
+                    expect(err.message).to.equal('Unknown credentials');
                     done();
                 });
             });
+        });
 
-            it('errors on unknown credentials algorithm', function (done) {
+        it('should fail authorization on invalid credentials', function (done) {
 
-                var req = {
-                    method: 'GET',
-                    url: '/resource/4?filter=a',
-                    host: 'example.com',
-                    port: 8080,
-                    authorization: 'Hawk id="123", ts="1353788437", nonce="k3j4h2", mac="/qwS4UjfVWMcUyW6EEgUH4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
-                };
+            credentialsFunc('123456', function (err, credentials) {
 
-                var credentialsFunc = function (id, callback) {
+                var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
+                expect(auth).to.exist();
 
-                    var credentials = {
-                        key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
-                        algorithm: 'hmac-sha-0',
-                        user: 'steve'
-                    };
+                var errFunc = function (id, callback) {
 
-                    return callback(null, credentials);
+                    callback(null, {});
                 };
 
-                Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+                Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, errFunc, {}, function (err, credentials) {
 
                     expect(err).to.exist();
-                    expect(err.message).to.equal('Unknown algorithm');
-                    expect(err.output.payload.message).to.equal('An internal server error occurred');
+                    expect(err.message).to.equal('Invalid credentials');
                     done();
                 });
             });
+        });
 
-            it('errors on unknown bad mac', function (done) {
+        it('should fail authorization on invalid credentials algorithm', function (done) {
 
-                var req = {
-                    method: 'GET',
-                    url: '/resource/4?filter=a',
-                    host: 'example.com',
-                    port: 8080,
-                    authorization: 'Hawk id="123", ts="1353788437", nonce="k3j4h2", mac="/qwS4UjfVWMcU4jlr7T/wuKe3dKijvTvSos=", ext="hello"'
-                };
+            credentialsFunc('123456', function (err, credentials) {
 
-                var credentialsFunc = function (id, callback) {
+                var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
+                expect(auth).to.exist();
 
-                    var credentials = {
-                        key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
-                        algorithm: 'sha256',
-                        user: 'steve'
-                    };
+                var errFunc = function (id, callback) {
 
-                    return callback(null, credentials);
+                    callback(null, { key: '123', algorithm: '456' });
                 };
 
-                Hawk.server.authenticate(req, credentialsFunc, { localtimeOffsetMsec: 1353788437000 - Hawk.utils.now() }, function (err, credentials, artifacts) {
+                Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, errFunc, {}, function (err, credentials) {
 
                     expect(err).to.exist();
-                    expect(err.output.payload.message).to.equal('Bad mac');
+                    expect(err.message).to.equal('Unknown algorithm');
                     done();
                 });
             });
         });
 
-        describe('#header', function () {
-
-            it('generates header', function (done) {
-
-                var credentials = {
-                    id: '123456',
-                    key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
-                    algorithm: 'sha256',
-                    user: 'steve'
-                };
-
-                var artifacts = {
-                    method: 'POST',
-                    host: 'example.com',
-                    port: '8080',
-                    resource: '/resource/4?filter=a',
-                    ts: '1398546787',
-                    nonce: 'xUwusx',
-                    hash: 'nJjkVtBE5Y/Bk38Aiokwn0jiJxt/0S2WRSUwWLCf5xk=',
-                    ext: 'some-app-data',
-                    mac: 'dvIvMThwi28J61Jc3P0ryAhuKpanU63GXdx6hkmQkJA=',
-                    id: '123456'
-                };
-
-                var header = Hawk.server.header(credentials, artifacts, { payload: 'some reply', contentType: 'text/plain', ext: 'response-specific' });
-                expect(header).to.equal('Hawk mac=\"n14wVJK4cOxAytPUMc5bPezQzuJGl5n7MYXhFQgEKsE=\", hash=\"f9cDF/TDm7TkYRLnGwRMfeDzT6LixQVLvrIKhh0vgmM=\", ext=\"response-specific\"');
-                done();
-            });
-
-            it('generates header (empty payload)', function (done) {
-
-                var credentials = {
-                    id: '123456',
-                    key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
-                    algorithm: 'sha256',
-                    user: 'steve'
-                };
-
-                var artifacts = {
-                    method: 'POST',
-                    host: 'example.com',
-                    port: '8080',
-                    resource: '/resource/4?filter=a',
-                    ts: '1398546787',
-                    nonce: 'xUwusx',
-                    hash: 'nJjkVtBE5Y/Bk38Aiokwn0jiJxt/0S2WRSUwWLCf5xk=',
-                    ext: 'some-app-data',
-                    mac: 'dvIvMThwi28J61Jc3P0ryAhuKpanU63GXdx6hkmQkJA=',
-                    id: '123456'
-                };
-
-                var header = Hawk.server.header(credentials, artifacts, { payload: '', contentType: 'text/plain', ext: 'response-specific' });
-                expect(header).to.equal('Hawk mac=\"i8/kUBDx0QF+PpCtW860kkV/fa9dbwEoe/FpGUXowf0=\", hash=\"q/t+NNAkQZNlq/aAD6PlexImwQTxwgT2MahfTa9XRLA=\", ext=\"response-specific\"');
-                done();
-            });
-
-            it('generates header (pre calculated hash)', function (done) {
-
-                var credentials = {
-                    id: '123456',
-                    key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
-                    algorithm: 'sha256',
-                    user: 'steve'
-                };
-
-                var artifacts = {
-                    method: 'POST',
-                    host: 'example.com',
-                    port: '8080',
-                    resource: '/resource/4?filter=a',
-                    ts: '1398546787',
-                    nonce: 'xUwusx',
-                    hash: 'nJjkVtBE5Y/Bk38Aiokwn0jiJxt/0S2WRSUwWLCf5xk=',
-                    ext: 'some-app-data',
-                    mac: 'dvIvMThwi28J61Jc3P0ryAhuKpanU63GXdx6hkmQkJA=',
-                    id: '123456'
-                };
-
-                var options = { payload: 'some reply', contentType: 'text/plain', ext: 'response-specific' };
-                options.hash = Hawk.crypto.calculatePayloadHash(options.payload, credentials.algorithm, options.contentType);
-                var header = Hawk.server.header(credentials, artifacts, options);
-                expect(header).to.equal('Hawk mac=\"n14wVJK4cOxAytPUMc5bPezQzuJGl5n7MYXhFQgEKsE=\", hash=\"f9cDF/TDm7TkYRLnGwRMfeDzT6LixQVLvrIKhh0vgmM=\", ext=\"response-specific\"');
-                done();
-            });
-
-            it('generates header (null ext)', function (done) {
-
-                var credentials = {
-                    id: '123456',
-                    key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
-                    algorithm: 'sha256',
-                    user: 'steve'
-                };
-
-                var artifacts = {
-                    method: 'POST',
-                    host: 'example.com',
-                    port: '8080',
-                    resource: '/resource/4?filter=a',
-                    ts: '1398546787',
-                    nonce: 'xUwusx',
-                    hash: 'nJjkVtBE5Y/Bk38Aiokwn0jiJxt/0S2WRSUwWLCf5xk=',
-                    mac: 'dvIvMThwi28J61Jc3P0ryAhuKpanU63GXdx6hkmQkJA=',
-                    id: '123456'
-                };
-
-                var header = Hawk.server.header(credentials, artifacts, { payload: 'some reply', contentType: 'text/plain', ext: null });
-                expect(header).to.equal('Hawk mac=\"6PrybJTJs20jsgBw5eilXpcytD8kUbaIKNYXL+6g0ns=\", hash=\"f9cDF/TDm7TkYRLnGwRMfeDzT6LixQVLvrIKhh0vgmM=\"');
-                done();
-            });
-
-            it('errors on missing artifacts', function (done) {
-
-                var credentials = {
-                    id: '123456',
-                    key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
-                    algorithm: 'sha256',
-                    user: 'steve'
-                };
-
-                var header = Hawk.server.header(credentials, null, { payload: 'some reply', contentType: 'text/plain', ext: 'response-specific' });
-                expect(header).to.equal('');
-                done();
-            });
-
-            it('errors on invalid artifacts', function (done) {
-
-                var credentials = {
-                    id: '123456',
-                    key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
-                    algorithm: 'sha256',
-                    user: 'steve'
-                };
-
-                var header = Hawk.server.header(credentials, 5, { payload: 'some reply', contentType: 'text/plain', ext: 'response-specific' });
-                expect(header).to.equal('');
-                done();
-            });
-
-            it('errors on missing credentials', function (done) {
-
-                var artifacts = {
-                    method: 'POST',
-                    host: 'example.com',
-                    port: '8080',
-                    resource: '/resource/4?filter=a',
-                    ts: '1398546787',
-                    nonce: 'xUwusx',
-                    hash: 'nJjkVtBE5Y/Bk38Aiokwn0jiJxt/0S2WRSUwWLCf5xk=',
-                    ext: 'some-app-data',
-                    mac: 'dvIvMThwi28J61Jc3P0ryAhuKpanU63GXdx6hkmQkJA=',
-                    id: '123456'
-                };
-
-                var header = Hawk.server.header(null, artifacts, { payload: 'some reply', contentType: 'text/plain', ext: 'response-specific' });
-                expect(header).to.equal('');
-                done();
-            });
-
-            it('errors on invalid credentials (key)', function (done) {
-
-                var credentials = {
-                    id: '123456',
-                    algorithm: 'sha256',
-                    user: 'steve'
-                };
-
-                var artifacts = {
-                    method: 'POST',
-                    host: 'example.com',
-                    port: '8080',
-                    resource: '/resource/4?filter=a',
-                    ts: '1398546787',
-                    nonce: 'xUwusx',
-                    hash: 'nJjkVtBE5Y/Bk38Aiokwn0jiJxt/0S2WRSUwWLCf5xk=',
-                    ext: 'some-app-data',
-                    mac: 'dvIvMThwi28J61Jc3P0ryAhuKpanU63GXdx6hkmQkJA=',
-                    id: '123456'
-                };
-
-                var header = Hawk.server.header(credentials, artifacts, { payload: 'some reply', contentType: 'text/plain', ext: 'response-specific' });
-                expect(header).to.equal('');
-                done();
-            });
-
-            it('errors on invalid algorithm', function (done) {
-
-                var credentials = {
-                    id: '123456',
-                    key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
-                    algorithm: 'x',
-                    user: 'steve'
-                };
+        it('should fail on missing host', function (done) {
 
-                var artifacts = {
-                    method: 'POST',
-                    host: 'example.com',
-                    port: '8080',
-                    resource: '/resource/4?filter=a',
-                    ts: '1398546787',
-                    nonce: 'xUwusx',
-                    hash: 'nJjkVtBE5Y/Bk38Aiokwn0jiJxt/0S2WRSUwWLCf5xk=',
-                    ext: 'some-app-data',
-                    mac: 'dvIvMThwi28J61Jc3P0ryAhuKpanU63GXdx6hkmQkJA=',
-                    id: '123456'
-                };
+            credentialsFunc('123456', function (err, credentials) {
 
-                var header = Hawk.server.header(credentials, artifacts, { payload: 'some reply', contentType: 'text/plain', ext: 'response-specific' });
-                expect(header).to.equal('');
+                var auth = Hawk.client.message(null, 8080, 'some message', { credentials: credentials });
+                expect(auth).to.not.exist();
                 done();
             });
         });
 
-        describe('#authenticateMessage', function () {
-
-            it('errors on invalid authorization (ts)', function (done) {
-
-                credentialsFunc('123456', function (err, credentials) {
-
-                    var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
-                    delete auth.ts;
-
-                    Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, credentialsFunc, {}, function (err, credentials) {
-
-                        expect(err).to.exist();
-                        expect(err.message).to.equal('Invalid authorization');
-                        done();
-                    });
-                });
-            });
-
-            it('errors on invalid authorization (nonce)', function (done) {
-
-                credentialsFunc('123456', function (err, credentials) {
-
-                    var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
-                    delete auth.nonce;
-
-                    Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, credentialsFunc, {}, function (err, credentials) {
-
-                        expect(err).to.exist();
-                        expect(err.message).to.equal('Invalid authorization');
-                        done();
-                    });
-                });
-            });
-
-            it('errors on invalid authorization (hash)', function (done) {
-
-                credentialsFunc('123456', function (err, credentials) {
-
-                    var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
-                    delete auth.hash;
-
-                    Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, credentialsFunc, {}, function (err, credentials) {
-
-                        expect(err).to.exist();
-                        expect(err.message).to.equal('Invalid authorization');
-                        done();
-                    });
-                });
-            });
-
-            it('errors with credentials', function (done) {
+        it('should fail on missing credentials', function (done) {
 
-                credentialsFunc('123456', function (err, credentials) {
+            var auth = Hawk.client.message('example.com', 8080, 'some message', {});
+            expect(auth).to.not.exist();
+            done();
+        });
 
-                    var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
+        it('should fail on invalid algorithm', function (done) {
 
-                    Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, function (id, callback) { callback(new Error('something'), { some: 'value' }); }, {}, function (err, credentials) {
+            credentialsFunc('123456', function (err, credentials) {
 
-                        expect(err).to.exist();
-                        expect(err.message).to.equal('something');
-                        expect(credentials.some).to.equal('value');
-                        done();
-                    });
-                });
+                var creds = Hoek.clone(credentials);
+                creds.algorithm = 'blah';
+                var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: creds });
+                expect(auth).to.not.exist();
+                done();
             });
         });
+    });
 
-        describe('#authenticatePayloadHash', function () {
+    describe('authenticatePayloadHash()', function () {
 
-            it('checks payload hash', function (done) {
+        it('checks payload hash', function (done) {
 
-                expect(Hawk.server.authenticatePayloadHash('abcdefg', { hash: 'abcdefg' })).to.equal(true);
-                expect(Hawk.server.authenticatePayloadHash('1234567', { hash: 'abcdefg' })).to.equal(false);
-                done();
-            });
+            expect(Hawk.server.authenticatePayloadHash('abcdefg', { hash: 'abcdefg' })).to.equal(true);
+            expect(Hawk.server.authenticatePayloadHash('1234567', { hash: 'abcdefg' })).to.equal(false);
+            done();
         });
     });
 });
index e64b009..1b623c0 100755 (executable)
@@ -21,77 +21,33 @@ var it = lab.test;
 var expect = Code.expect;
 
 
-describe('Hawk', function () {
+describe('Uri', function () {
 
-    describe('Uri', function () {
+    var credentialsFunc = function (id, callback) {
 
-        var credentialsFunc = function (id, callback) {
-
-            var credentials = {
-                id: id,
-                key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
-                algorithm: 'sha256',
-                user: 'steve'
-            };
-
-            return callback(null, credentials);
+        var credentials = {
+            id: id,
+            key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
+            algorithm: 'sha256',
+            user: 'steve'
         };
 
-        it('should generate a bewit then successfully authenticate it', function (done) {
-
-            var req = {
-                method: 'GET',
-                url: '/resource/4?a=1&b=2',
-                host: 'example.com',
-                port: 80
-            };
-
-            credentialsFunc('123456', function (err, credentials) {
-
-                var bewit = Hawk.uri.getBewit('http://example.com/resource/4?a=1&b=2', { credentials: credentials, ttlSec: 60 * 60 * 24 * 365 * 100, ext: 'some-app-data' });
-                req.url += '&bewit=' + bewit;
-
-                Hawk.uri.authenticate(req, credentialsFunc, {}, function (err, credentials, attributes) {
-
-                    expect(err).to.not.exist();
-                    expect(credentials.user).to.equal('steve');
-                    expect(attributes.ext).to.equal('some-app-data');
-                    done();
-                });
-            });
-        });
-
-        it('should generate a bewit then successfully authenticate it (no ext)', function (done) {
-
-            var req = {
-                method: 'GET',
-                url: '/resource/4?a=1&b=2',
-                host: 'example.com',
-                port: 80
-            };
+        return callback(null, credentials);
+    };
 
-            credentialsFunc('123456', function (err, credentials) {
+    it('should generate a bewit then successfully authenticate it', function (done) {
 
-                var bewit = Hawk.uri.getBewit('http://example.com/resource/4?a=1&b=2', { credentials: credentials, ttlSec: 60 * 60 * 24 * 365 * 100 });
-                req.url += '&bewit=' + bewit;
-
-                Hawk.uri.authenticate(req, credentialsFunc, {}, function (err, credentials, attributes) {
-
-                    expect(err).to.not.exist();
-                    expect(credentials.user).to.equal('steve');
-                    done();
-                });
-            });
-        });
+        var req = {
+            method: 'GET',
+            url: '/resource/4?a=1&b=2',
+            host: 'example.com',
+            port: 80
+        };
 
-        it('should successfully authenticate a request (last param)', function (done) {
+        credentialsFunc('123456', function (err, credentials) {
 
-            var req = {
-                method: 'GET',
-                url: '/resource/4?a=1&b=2&bewit=MTIzNDU2XDQ1MTE0ODQ2MjFcMzFjMmNkbUJFd1NJRVZDOVkva1NFb2c3d3YrdEVNWjZ3RXNmOGNHU2FXQT1cc29tZS1hcHAtZGF0YQ',
-                host: 'example.com',
-                port: 8080
-            };
+            var bewit = Hawk.uri.getBewit('http://example.com/resource/4?a=1&b=2', { credentials: credentials, ttlSec: 60 * 60 * 24 * 365 * 100, ext: 'some-app-data' });
+            req.url += '&bewit=' + bewit;
 
             Hawk.uri.authenticate(req, credentialsFunc, {}, function (err, credentials, attributes) {
 
@@ -101,342 +57,401 @@ describe('Hawk', function () {
                 done();
             });
         });
+    });
 
-        it('should successfully authenticate a request (first param)', function (done) {
+    it('should generate a bewit then successfully authenticate it (no ext)', function (done) {
 
-            var req = {
-                method: 'GET',
-                url: '/resource/4?bewit=MTIzNDU2XDQ1MTE0ODQ2MjFcMzFjMmNkbUJFd1NJRVZDOVkva1NFb2c3d3YrdEVNWjZ3RXNmOGNHU2FXQT1cc29tZS1hcHAtZGF0YQ&a=1&b=2',
-                host: 'example.com',
-                port: 8080
-            };
+        var req = {
+            method: 'GET',
+            url: '/resource/4?a=1&b=2',
+            host: 'example.com',
+            port: 80
+        };
+
+        credentialsFunc('123456', function (err, credentials) {
+
+            var bewit = Hawk.uri.getBewit('http://example.com/resource/4?a=1&b=2', { credentials: credentials, ttlSec: 60 * 60 * 24 * 365 * 100 });
+            req.url += '&bewit=' + bewit;
 
             Hawk.uri.authenticate(req, credentialsFunc, {}, function (err, credentials, attributes) {
 
                 expect(err).to.not.exist();
                 expect(credentials.user).to.equal('steve');
-                expect(attributes.ext).to.equal('some-app-data');
                 done();
             });
         });
+    });
 
-        it('should successfully authenticate a request (only param)', function (done) {
+    it('should successfully authenticate a request (last param)', function (done) {
 
-            var req = {
-                method: 'GET',
-                url: '/resource/4?bewit=MTIzNDU2XDQ1MTE0ODQ2NDFcZm1CdkNWT3MvcElOTUUxSTIwbWhrejQ3UnBwTmo4Y1VrSHpQd3Q5OXJ1cz1cc29tZS1hcHAtZGF0YQ',
-                host: 'example.com',
-                port: 8080
-            };
+        var req = {
+            method: 'GET',
+            url: '/resource/4?a=1&b=2&bewit=MTIzNDU2XDQ1MTE0ODQ2MjFcMzFjMmNkbUJFd1NJRVZDOVkva1NFb2c3d3YrdEVNWjZ3RXNmOGNHU2FXQT1cc29tZS1hcHAtZGF0YQ',
+            host: 'example.com',
+            port: 8080
+        };
 
-            Hawk.uri.authenticate(req, credentialsFunc, {}, function (err, credentials, attributes) {
+        Hawk.uri.authenticate(req, credentialsFunc, {}, function (err, credentials, attributes) {
 
-                expect(err).to.not.exist();
-                expect(credentials.user).to.equal('steve');
-                expect(attributes.ext).to.equal('some-app-data');
-                done();
-            });
+            expect(err).to.not.exist();
+            expect(credentials.user).to.equal('steve');
+            expect(attributes.ext).to.equal('some-app-data');
+            done();
         });
+    });
 
-        it('should fail on multiple authentication', function (done) {
+    it('should successfully authenticate a request (first param)', function (done) {
 
-            var req = {
-                method: 'GET',
-                url: '/resource/4?bewit=MTIzNDU2XDQ1MTE0ODQ2NDFcZm1CdkNWT3MvcElOTUUxSTIwbWhrejQ3UnBwTmo4Y1VrSHpQd3Q5OXJ1cz1cc29tZS1hcHAtZGF0YQ',
-                host: 'example.com',
-                port: 8080,
-                authorization: 'Basic asdasdasdasd'
-            };
+        var req = {
+            method: 'GET',
+            url: '/resource/4?bewit=MTIzNDU2XDQ1MTE0ODQ2MjFcMzFjMmNkbUJFd1NJRVZDOVkva1NFb2c3d3YrdEVNWjZ3RXNmOGNHU2FXQT1cc29tZS1hcHAtZGF0YQ&a=1&b=2',
+            host: 'example.com',
+            port: 8080
+        };
 
-            Hawk.uri.authenticate(req, credentialsFunc, {}, function (err, credentials, attributes) {
+        Hawk.uri.authenticate(req, credentialsFunc, {}, function (err, credentials, attributes) {
 
-                expect(err).to.exist();
-                expect(err.output.payload.message).to.equal('Multiple authentications');
-                done();
-            });
+            expect(err).to.not.exist();
+            expect(credentials.user).to.equal('steve');
+            expect(attributes.ext).to.equal('some-app-data');
+            done();
         });
+    });
 
-        it('should fail on method other than GET', function (done) {
+    it('should successfully authenticate a request (only param)', function (done) {
 
-            credentialsFunc('123456', function (err, credentials) {
+        var req = {
+            method: 'GET',
+            url: '/resource/4?bewit=MTIzNDU2XDQ1MTE0ODQ2NDFcZm1CdkNWT3MvcElOTUUxSTIwbWhrejQ3UnBwTmo4Y1VrSHpQd3Q5OXJ1cz1cc29tZS1hcHAtZGF0YQ',
+            host: 'example.com',
+            port: 8080
+        };
 
-                var req = {
-                    method: 'POST',
-                    url: '/resource/4?filter=a',
-                    host: 'example.com',
-                    port: 8080
-                };
+        Hawk.uri.authenticate(req, credentialsFunc, {}, function (err, credentials, attributes) {
 
-                var exp = Math.floor(Hawk.utils.now() / 1000) + 60;
-                var ext = 'some-app-data';
-                var mac = Hawk.crypto.calculateMac('bewit', credentials, {
-                    timestamp: exp,
-                    nonce: '',
-                    method: req.method,
-                    resource: req.url,
-                    host: req.host,
-                    port: req.port,
-                    ext: ext
-                });
+            expect(err).to.not.exist();
+            expect(credentials.user).to.equal('steve');
+            expect(attributes.ext).to.equal('some-app-data');
+            done();
+        });
+    });
 
-                var bewit = credentials.id + '\\' + exp + '\\' + mac + '\\' + ext;
+    it('should fail on multiple authentication', function (done) {
 
-                req.url += '&bewit=' + Hoek.base64urlEncode(bewit);
+        var req = {
+            method: 'GET',
+            url: '/resource/4?bewit=MTIzNDU2XDQ1MTE0ODQ2NDFcZm1CdkNWT3MvcElOTUUxSTIwbWhrejQ3UnBwTmo4Y1VrSHpQd3Q5OXJ1cz1cc29tZS1hcHAtZGF0YQ',
+            host: 'example.com',
+            port: 8080,
+            authorization: 'Basic asdasdasdasd'
+        };
 
-                Hawk.uri.authenticate(req, credentialsFunc, {}, function (err, credentials, attributes) {
+        Hawk.uri.authenticate(req, credentialsFunc, {}, function (err, credentials, attributes) {
 
-                    expect(err).to.exist();
-                    expect(err.output.payload.message).to.equal('Invalid method');
-                    done();
-                });
-            });
+            expect(err).to.exist();
+            expect(err.output.payload.message).to.equal('Multiple authentications');
+            done();
         });
+    });
+
+    it('should fail on method other than GET', function (done) {
 
-        it('should fail on invalid host header', function (done) {
+        credentialsFunc('123456', function (err, credentials) {
 
             var req = {
-                method: 'GET',
-                url: '/resource/4?bewit=MTIzNDU2XDQ1MDk5OTE3MTlcTUE2eWkwRWRwR0pEcWRwb0JkYVdvVDJrL0hDSzA1T0Y3MkhuZlVmVy96Zz1cc29tZS1hcHAtZGF0YQ',
-                headers: {
-                    host: 'example.com:something'
-                }
+                method: 'POST',
+                url: '/resource/4?filter=a',
+                host: 'example.com',
+                port: 8080
             };
 
+            var exp = Math.floor(Hawk.utils.now() / 1000) + 60;
+            var ext = 'some-app-data';
+            var mac = Hawk.crypto.calculateMac('bewit', credentials, {
+                timestamp: exp,
+                nonce: '',
+                method: req.method,
+                resource: req.url,
+                host: req.host,
+                port: req.port,
+                ext: ext
+            });
+
+            var bewit = credentials.id + '\\' + exp + '\\' + mac + '\\' + ext;
+
+            req.url += '&bewit=' + Hoek.base64urlEncode(bewit);
+
             Hawk.uri.authenticate(req, credentialsFunc, {}, function (err, credentials, attributes) {
 
                 expect(err).to.exist();
-                expect(err.output.payload.message).to.equal('Invalid Host header');
+                expect(err.output.payload.message).to.equal('Invalid method');
                 done();
             });
         });
+    });
 
-        it('should fail on empty bewit', function (done) {
+    it('should fail on invalid host header', function (done) {
 
-            var req = {
-                method: 'GET',
-                url: '/resource/4?bewit=',
-                host: 'example.com',
-                port: 8080
-            };
+        var req = {
+            method: 'GET',
+            url: '/resource/4?bewit=MTIzNDU2XDQ1MDk5OTE3MTlcTUE2eWkwRWRwR0pEcWRwb0JkYVdvVDJrL0hDSzA1T0Y3MkhuZlVmVy96Zz1cc29tZS1hcHAtZGF0YQ',
+            headers: {
+                host: 'example.com:something'
+            }
+        };
 
-            Hawk.uri.authenticate(req, credentialsFunc, {}, function (err, credentials, attributes) {
+        Hawk.uri.authenticate(req, credentialsFunc, {}, function (err, credentials, attributes) {
 
-                expect(err).to.exist();
-                expect(err.output.payload.message).to.equal('Empty bewit');
-                expect(err.isMissing).to.not.exist();
-                done();
-            });
+            expect(err).to.exist();
+            expect(err.output.payload.message).to.equal('Invalid Host header');
+            done();
         });
+    });
 
-        it('should fail on invalid bewit', function (done) {
+    it('should fail on empty bewit', function (done) {
 
-            var req = {
-                method: 'GET',
-                url: '/resource/4?bewit=*',
-                host: 'example.com',
-                port: 8080
-            };
+        var req = {
+            method: 'GET',
+            url: '/resource/4?bewit=',
+            host: 'example.com',
+            port: 8080
+        };
 
-            Hawk.uri.authenticate(req, credentialsFunc, {}, function (err, credentials, attributes) {
+        Hawk.uri.authenticate(req, credentialsFunc, {}, function (err, credentials, attributes) {
 
-                expect(err).to.exist();
-                expect(err.output.payload.message).to.equal('Invalid bewit encoding');
-                expect(err.isMissing).to.not.exist();
-                done();
-            });
+            expect(err).to.exist();
+            expect(err.output.payload.message).to.equal('Empty bewit');
+            expect(err.isMissing).to.not.exist();
+            done();
         });
+    });
 
-        it('should fail on missing bewit', function (done) {
+    it('should fail on invalid bewit', function (done) {
 
-            var req = {
-                method: 'GET',
-                url: '/resource/4',
-                host: 'example.com',
-                port: 8080
-            };
+        var req = {
+            method: 'GET',
+            url: '/resource/4?bewit=*',
+            host: 'example.com',
+            port: 8080
+        };
 
-            Hawk.uri.authenticate(req, credentialsFunc, {}, function (err, credentials, attributes) {
+        Hawk.uri.authenticate(req, credentialsFunc, {}, function (err, credentials, attributes) {
 
-                expect(err).to.exist();
-                expect(err.output.payload.message).to.not.exist();
-                expect(err.isMissing).to.equal(true);
-                done();
-            });
+            expect(err).to.exist();
+            expect(err.output.payload.message).to.equal('Invalid bewit encoding');
+            expect(err.isMissing).to.not.exist();
+            done();
         });
+    });
 
-        it('should fail on invalid bewit structure', function (done) {
+    it('should fail on missing bewit', function (done) {
 
-            var req = {
-                method: 'GET',
-                url: '/resource/4?bewit=abc',
-                host: 'example.com',
-                port: 8080
-            };
+        var req = {
+            method: 'GET',
+            url: '/resource/4',
+            host: 'example.com',
+            port: 8080
+        };
 
-            Hawk.uri.authenticate(req, credentialsFunc, {}, function (err, credentials, attributes) {
+        Hawk.uri.authenticate(req, credentialsFunc, {}, function (err, credentials, attributes) {
 
-                expect(err).to.exist();
-                expect(err.output.payload.message).to.equal('Invalid bewit structure');
-                done();
-            });
+            expect(err).to.exist();
+            expect(err.output.payload.message).to.not.exist();
+            expect(err.isMissing).to.equal(true);
+            done();
         });
+    });
 
-        it('should fail on empty bewit attribute', function (done) {
+    it('should fail on invalid bewit structure', function (done) {
 
-            var req = {
-                method: 'GET',
-                url: '/resource/4?bewit=YVxcY1xk',
-                host: 'example.com',
-                port: 8080
-            };
+        var req = {
+            method: 'GET',
+            url: '/resource/4?bewit=abc',
+            host: 'example.com',
+            port: 8080
+        };
 
-            Hawk.uri.authenticate(req, credentialsFunc, {}, function (err, credentials, attributes) {
+        Hawk.uri.authenticate(req, credentialsFunc, {}, function (err, credentials, attributes) {
 
-                expect(err).to.exist();
-                expect(err.output.payload.message).to.equal('Missing bewit attributes');
-                done();
-            });
+            expect(err).to.exist();
+            expect(err.output.payload.message).to.equal('Invalid bewit structure');
+            done();
         });
+    });
 
-        it('should fail on missing bewit id attribute', function (done) {
+    it('should fail on empty bewit attribute', function (done) {
 
-            var req = {
-                method: 'GET',
-                url: '/resource/4?bewit=XDQ1NTIxNDc2MjJcK0JFbFhQMXhuWjcvd1Nrbm1ldGhlZm5vUTNHVjZNSlFVRHk4NWpTZVJ4VT1cc29tZS1hcHAtZGF0YQ',
-                host: 'example.com',
-                port: 8080
-            };
+        var req = {
+            method: 'GET',
+            url: '/resource/4?bewit=YVxcY1xk',
+            host: 'example.com',
+            port: 8080
+        };
 
-            Hawk.uri.authenticate(req, credentialsFunc, {}, function (err, credentials, attributes) {
+        Hawk.uri.authenticate(req, credentialsFunc, {}, function (err, credentials, attributes) {
 
-                expect(err).to.exist();
-                expect(err.output.payload.message).to.equal('Missing bewit attributes');
-                done();
-            });
+            expect(err).to.exist();
+            expect(err.output.payload.message).to.equal('Missing bewit attributes');
+            done();
         });
-        
-        it('should fail on expired access', function (done) {
+    });
 
-            var req = {
-                method: 'GET',
-                url: '/resource/4?a=1&b=2&bewit=MTIzNDU2XDEzNTY0MTg1ODNcWk1wZlMwWU5KNHV0WHpOMmRucTRydEk3NXNXTjFjeWVITTcrL0tNZFdVQT1cc29tZS1hcHAtZGF0YQ',
-                host: 'example.com',
-                port: 8080
-            };
+    it('should fail on missing bewit id attribute', function (done) {
 
-            Hawk.uri.authenticate(req, credentialsFunc, {}, function (err, credentials, attributes) {
+        var req = {
+            method: 'GET',
+            url: '/resource/4?bewit=XDQ1NTIxNDc2MjJcK0JFbFhQMXhuWjcvd1Nrbm1ldGhlZm5vUTNHVjZNSlFVRHk4NWpTZVJ4VT1cc29tZS1hcHAtZGF0YQ',
+            host: 'example.com',
+            port: 8080
+        };
 
-                expect(err).to.exist();
-                expect(err.output.payload.message).to.equal('Access expired');
-                done();
-            });
+        Hawk.uri.authenticate(req, credentialsFunc, {}, function (err, credentials, attributes) {
+
+            expect(err).to.exist();
+            expect(err.output.payload.message).to.equal('Missing bewit attributes');
+            done();
         });
+    });
 
-        it('should fail on credentials function error', function (done) {
+    it('should fail on expired access', function (done) {
 
-            var req = {
-                method: 'GET',
-                url: '/resource/4?bewit=MTIzNDU2XDQ1MDk5OTE3MTlcTUE2eWkwRWRwR0pEcWRwb0JkYVdvVDJrL0hDSzA1T0Y3MkhuZlVmVy96Zz1cc29tZS1hcHAtZGF0YQ',
-                host: 'example.com',
-                port: 8080
-            };
+        var req = {
+            method: 'GET',
+            url: '/resource/4?a=1&b=2&bewit=MTIzNDU2XDEzNTY0MTg1ODNcWk1wZlMwWU5KNHV0WHpOMmRucTRydEk3NXNXTjFjeWVITTcrL0tNZFdVQT1cc29tZS1hcHAtZGF0YQ',
+            host: 'example.com',
+            port: 8080
+        };
 
-            Hawk.uri.authenticate(req, function (id, callback) { callback(Hawk.error.badRequest('Boom')); }, {}, function (err, credentials, attributes) {
+        Hawk.uri.authenticate(req, credentialsFunc, {}, function (err, credentials, attributes) {
 
-                expect(err).to.exist();
-                expect(err.output.payload.message).to.equal('Boom');
-                done();
-            });
+            expect(err).to.exist();
+            expect(err.output.payload.message).to.equal('Access expired');
+            done();
         });
+    });
 
-        it('should fail on credentials function error with credentials', function (done) {
+    it('should fail on credentials function error', function (done) {
 
-            var req = {
-                method: 'GET',
-                url: '/resource/4?bewit=MTIzNDU2XDQ1MDk5OTE3MTlcTUE2eWkwRWRwR0pEcWRwb0JkYVdvVDJrL0hDSzA1T0Y3MkhuZlVmVy96Zz1cc29tZS1hcHAtZGF0YQ',
-                host: 'example.com',
-                port: 8080
-            };
+        var req = {
+            method: 'GET',
+            url: '/resource/4?bewit=MTIzNDU2XDQ1MDk5OTE3MTlcTUE2eWkwRWRwR0pEcWRwb0JkYVdvVDJrL0hDSzA1T0Y3MkhuZlVmVy96Zz1cc29tZS1hcHAtZGF0YQ',
+            host: 'example.com',
+            port: 8080
+        };
 
-            Hawk.uri.authenticate(req, function (id, callback) { callback(Hawk.error.badRequest('Boom'), { some: 'value' }); }, {}, function (err, credentials, attributes) {
+        Hawk.uri.authenticate(req, function (id, callback) {
 
-                expect(err).to.exist();
-                expect(err.output.payload.message).to.equal('Boom');
-                expect(credentials.some).to.equal('value');
-                done();
-            });
+            callback(Hawk.error.badRequest('Boom'));
+        }, {}, function (err, credentials, attributes) {
+
+            expect(err).to.exist();
+            expect(err.output.payload.message).to.equal('Boom');
+            done();
         });
+    });
 
-        it('should fail on null credentials function response', function (done) {
+    it('should fail on credentials function error with credentials', function (done) {
 
-            var req = {
-                method: 'GET',
-                url: '/resource/4?bewit=MTIzNDU2XDQ1MDk5OTE3MTlcTUE2eWkwRWRwR0pEcWRwb0JkYVdvVDJrL0hDSzA1T0Y3MkhuZlVmVy96Zz1cc29tZS1hcHAtZGF0YQ',
-                host: 'example.com',
-                port: 8080
-            };
+        var req = {
+            method: 'GET',
+            url: '/resource/4?bewit=MTIzNDU2XDQ1MDk5OTE3MTlcTUE2eWkwRWRwR0pEcWRwb0JkYVdvVDJrL0hDSzA1T0Y3MkhuZlVmVy96Zz1cc29tZS1hcHAtZGF0YQ',
+            host: 'example.com',
+            port: 8080
+        };
 
-            Hawk.uri.authenticate(req, function (id, callback) { callback(null, null); }, {}, function (err, credentials, attributes) {
+        Hawk.uri.authenticate(req, function (id, callback) {
 
-                expect(err).to.exist();
-                expect(err.output.payload.message).to.equal('Unknown credentials');
-                done();
-            });
+            callback(Hawk.error.badRequest('Boom'), { some: 'value' });
+        }, {}, function (err, credentials, attributes) {
+
+            expect(err).to.exist();
+            expect(err.output.payload.message).to.equal('Boom');
+            expect(credentials.some).to.equal('value');
+            done();
         });
+    });
 
-        it('should fail on invalid credentials function response', function (done) {
+    it('should fail on null credentials function response', function (done) {
 
-            var req = {
-                method: 'GET',
-                url: '/resource/4?bewit=MTIzNDU2XDQ1MDk5OTE3MTlcTUE2eWkwRWRwR0pEcWRwb0JkYVdvVDJrL0hDSzA1T0Y3MkhuZlVmVy96Zz1cc29tZS1hcHAtZGF0YQ',
-                host: 'example.com',
-                port: 8080
-            };
+        var req = {
+            method: 'GET',
+            url: '/resource/4?bewit=MTIzNDU2XDQ1MDk5OTE3MTlcTUE2eWkwRWRwR0pEcWRwb0JkYVdvVDJrL0hDSzA1T0Y3MkhuZlVmVy96Zz1cc29tZS1hcHAtZGF0YQ',
+            host: 'example.com',
+            port: 8080
+        };
 
-            Hawk.uri.authenticate(req, function (id, callback) { callback(null, {}); }, {}, function (err, credentials, attributes) {
+        Hawk.uri.authenticate(req, function (id, callback) {
 
-                expect(err).to.exist();
-                expect(err.message).to.equal('Invalid credentials');
-                done();
-            });
+            callback(null, null);
+        }, {}, function (err, credentials, attributes) {
+
+            expect(err).to.exist();
+            expect(err.output.payload.message).to.equal('Unknown credentials');
+            done();
         });
+    });
 
-        it('should fail on invalid credentials function response (unknown algorithm)', function (done) {
+    it('should fail on invalid credentials function response', function (done) {
 
-            var req = {
-                method: 'GET',
-                url: '/resource/4?bewit=MTIzNDU2XDQ1MDk5OTE3MTlcTUE2eWkwRWRwR0pEcWRwb0JkYVdvVDJrL0hDSzA1T0Y3MkhuZlVmVy96Zz1cc29tZS1hcHAtZGF0YQ',
-                host: 'example.com',
-                port: 8080
-            };
+        var req = {
+            method: 'GET',
+            url: '/resource/4?bewit=MTIzNDU2XDQ1MDk5OTE3MTlcTUE2eWkwRWRwR0pEcWRwb0JkYVdvVDJrL0hDSzA1T0Y3MkhuZlVmVy96Zz1cc29tZS1hcHAtZGF0YQ',
+            host: 'example.com',
+            port: 8080
+        };
 
-            Hawk.uri.authenticate(req, function (id, callback) { callback(null, { key: 'xxx', algorithm: 'xxx' }); }, {}, function (err, credentials, attributes) {
+        Hawk.uri.authenticate(req, function (id, callback) {
 
-                expect(err).to.exist();
-                expect(err.message).to.equal('Unknown algorithm');
-                done();
-            });
+            callback(null, {});
+        }, {}, function (err, credentials, attributes) {
+
+            expect(err).to.exist();
+            expect(err.message).to.equal('Invalid credentials');
+            done();
         });
+    });
 
-        it('should fail on expired access', function (done) {
+    it('should fail on invalid credentials function response (unknown algorithm)', function (done) {
 
-            var req = {
-                method: 'GET',
-                url: '/resource/4?bewit=MTIzNDU2XDQ1MDk5OTE3MTlcTUE2eWkwRWRwR0pEcWRwb0JkYVdvVDJrL0hDSzA1T0Y3MkhuZlVmVy96Zz1cc29tZS1hcHAtZGF0YQ',
-                host: 'example.com',
-                port: 8080
-            };
+        var req = {
+            method: 'GET',
+            url: '/resource/4?bewit=MTIzNDU2XDQ1MDk5OTE3MTlcTUE2eWkwRWRwR0pEcWRwb0JkYVdvVDJrL0hDSzA1T0Y3MkhuZlVmVy96Zz1cc29tZS1hcHAtZGF0YQ',
+            host: 'example.com',
+            port: 8080
+        };
 
-            Hawk.uri.authenticate(req, function (id, callback) { callback(null, { key: 'xxx', algorithm: 'sha256' }); }, {}, function (err, credentials, attributes) {
+        Hawk.uri.authenticate(req, function (id, callback) {
 
-                expect(err).to.exist();
-                expect(err.output.payload.message).to.equal('Bad mac');
-                done();
-            });
+            callback(null, { key: 'xxx', algorithm: 'xxx' });
+        }, {}, function (err, credentials, attributes) {
+
+            expect(err).to.exist();
+            expect(err.message).to.equal('Unknown algorithm');
+            done();
+        });
+    });
+
+    it('should fail on expired access', function (done) {
+
+        var req = {
+            method: 'GET',
+            url: '/resource/4?bewit=MTIzNDU2XDQ1MDk5OTE3MTlcTUE2eWkwRWRwR0pEcWRwb0JkYVdvVDJrL0hDSzA1T0Y3MkhuZlVmVy96Zz1cc29tZS1hcHAtZGF0YQ',
+            host: 'example.com',
+            port: 8080
+        };
+
+        Hawk.uri.authenticate(req, function (id, callback) {
+
+            callback(null, { key: 'xxx', algorithm: 'sha256' });
+        }, {}, function (err, credentials, attributes) {
+
+            expect(err).to.exist();
+            expect(err.output.payload.message).to.equal('Bad mac');
+            done();
         });
     });
 
-    describe('#getBewit', function () {
+    describe('getBewit()', function () {
 
         it('returns a valid bewit value', function (done) {
 
@@ -586,5 +601,249 @@ describe('Hawk', function () {
             done();
         });
     });
+    describe('authenticateMessage()', function () {
+
+        var credentialsFunc = function (id, callback) {
+
+            var credentials = {
+                id: id,
+                key: 'werxhqb98rpaxn39848xrunpaw3489ruxnpa98w4rxn',
+                algorithm: (id === '1' ? 'sha1' : 'sha256'),
+                user: 'steve'
+            };
+
+            return callback(null, credentials);
+        };
+
+        it('should generate an authorization then successfully parse it', function (done) {
+
+            credentialsFunc('123456', function (err, credentials) {
+
+                var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
+                expect(auth).to.exist();
+
+                Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, credentialsFunc, {}, function (err, credentials) {
+
+                    expect(err).to.not.exist();
+                    expect(credentials.user).to.equal('steve');
+                    done();
+                });
+            });
+        });
+
+        it('should fail authorization on mismatching host', function (done) {
+
+            credentialsFunc('123456', function (err, credentials) {
+
+                var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
+                expect(auth).to.exist();
+
+                Hawk.server.authenticateMessage('example1.com', 8080, 'some message', auth, credentialsFunc, {}, function (err, credentials) {
+
+                    expect(err).to.exist();
+                    expect(err.message).to.equal('Bad mac');
+                    done();
+                });
+            });
+        });
+
+        it('should fail authorization on stale timestamp', function (done) {
+
+            credentialsFunc('123456', function (err, credentials) {
+
+                var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
+                expect(auth).to.exist();
+
+                Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, credentialsFunc, { localtimeOffsetMsec: 100000 }, function (err, credentials) {
+
+                    expect(err).to.exist();
+                    expect(err.message).to.equal('Stale timestamp');
+                    done();
+                });
+            });
+        });
+
+        it('overrides timestampSkewSec', function (done) {
+
+            credentialsFunc('123456', function (err, credentials) {
+
+                var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials, localtimeOffsetMsec: 100000 });
+                expect(auth).to.exist();
+
+                Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, credentialsFunc, { timestampSkewSec: 500 }, function (err, credentials) {
+
+                    expect(err).to.not.exist();
+                    done();
+                });
+            });
+        });
+
+        it('should fail authorization on invalid authorization', function (done) {
+
+            credentialsFunc('123456', function (err, credentials) {
+
+                var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
+                expect(auth).to.exist();
+                delete auth.id;
+
+                Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, credentialsFunc, {}, function (err, credentials) {
+
+                    expect(err).to.exist();
+                    expect(err.message).to.equal('Invalid authorization');
+                    done();
+                });
+            });
+        });
+
+        it('should fail authorization on bad hash', function (done) {
+
+            credentialsFunc('123456', function (err, credentials) {
+
+                var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
+                expect(auth).to.exist();
+
+                Hawk.server.authenticateMessage('example.com', 8080, 'some message1', auth, credentialsFunc, {}, function (err, credentials) {
+
+                    expect(err).to.exist();
+                    expect(err.message).to.equal('Bad message hash');
+                    done();
+                });
+            });
+        });
+
+        it('should fail authorization on nonce error', function (done) {
+
+            credentialsFunc('123456', function (err, credentials) {
+
+                var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
+                expect(auth).to.exist();
+
+                Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, credentialsFunc, {
+                    nonceFunc: function (key, nonce, ts, callback) {
+
+                        callback(new Error('kaboom'));
+                    }
+                }, function (err, credentials) {
+
+                    expect(err).to.exist();
+                    expect(err.message).to.equal('Invalid nonce');
+                    done();
+                });
+            });
+        });
+
+        it('should fail authorization on credentials error', function (done) {
+
+            credentialsFunc('123456', function (err, credentials) {
+
+                var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
+                expect(auth).to.exist();
+
+                var errFunc = function (id, callback) {
+
+                    callback(new Error('kablooey'));
+                };
+
+                Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, errFunc, {}, function (err, credentials) {
+
+                    expect(err).to.exist();
+                    expect(err.message).to.equal('kablooey');
+                    done();
+                });
+            });
+        });
+
+        it('should fail authorization on missing credentials', function (done) {
+
+            credentialsFunc('123456', function (err, credentials) {
+
+                var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
+                expect(auth).to.exist();
+
+                var errFunc = function (id, callback) {
+
+                    callback();
+                };
+
+                Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, errFunc, {}, function (err, credentials) {
+
+                    expect(err).to.exist();
+                    expect(err.message).to.equal('Unknown credentials');
+                    done();
+                });
+            });
+        });
+
+        it('should fail authorization on invalid credentials', function (done) {
+
+            credentialsFunc('123456', function (err, credentials) {
+
+                var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
+                expect(auth).to.exist();
+
+                var errFunc = function (id, callback) {
+
+                    callback(null, {});
+                };
+
+                Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, errFunc, {}, function (err, credentials) {
+
+                    expect(err).to.exist();
+                    expect(err.message).to.equal('Invalid credentials');
+                    done();
+                });
+            });
+        });
+
+        it('should fail authorization on invalid credentials algorithm', function (done) {
+
+            credentialsFunc('123456', function (err, credentials) {
+
+                var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: credentials });
+                expect(auth).to.exist();
+
+                var errFunc = function (id, callback) {
+
+                    callback(null, { key: '123', algorithm: '456' });
+                };
+
+                Hawk.server.authenticateMessage('example.com', 8080, 'some message', auth, errFunc, {}, function (err, credentials) {
+
+                    expect(err).to.exist();
+                    expect(err.message).to.equal('Unknown algorithm');
+                    done();
+                });
+            });
+        });
+
+        it('should fail on missing host', function (done) {
+
+            credentialsFunc('123456', function (err, credentials) {
+
+                var auth = Hawk.client.message(null, 8080, 'some message', { credentials: credentials });
+                expect(auth).to.not.exist();
+                done();
+            });
+        });
+
+        it('should fail on missing credentials', function (done) {
+
+            var auth = Hawk.client.message('example.com', 8080, 'some message', {});
+            expect(auth).to.not.exist();
+            done();
+        });
+
+        it('should fail on invalid algorithm', function (done) {
+
+            credentialsFunc('123456', function (err, credentials) {
+
+                var creds = Hoek.clone(credentials);
+                creds.algorithm = 'blah';
+                var auth = Hawk.client.message('example.com', 8080, 'some message', { credentials: creds });
+                expect(auth).to.not.exist();
+                done();
+            });
+        });
+    });
 });
 
index 9ccda8b..1bfef65 100755 (executable)
@@ -19,102 +19,103 @@ var it = lab.test;
 var expect = Code.expect;
 
 
-describe('Hawk', function () {
-
-    describe('Utils', function () {
-
-        describe('#parseHost', function () {
-
-            it('returns port 80 for non tls node request', function (done) {
-
-                var req = {
-                    method: 'POST',
-                    url: '/resource/4?filter=a',
-                    headers: {
-                        host: 'example.com',
-                        'content-type': 'text/plain;x=y'
-                    }
-                };
-
-                expect(Hawk.utils.parseHost(req, 'Host').port).to.equal(80);
-                done();
-            });
-
-            it('returns port 443 for non tls node request', function (done) {
-
-                var req = {
-                    method: 'POST',
-                    url: '/resource/4?filter=a',
-                    headers: {
-                        host: 'example.com',
-                        'content-type': 'text/plain;x=y'
-                    },
-                    connection: {
-                        encrypted: true
-                    }
-                };
-
-                expect(Hawk.utils.parseHost(req, 'Host').port).to.equal(443);
-                done();
-            });
-
-            it('returns port 443 for non tls node request (IPv6)', function (done) {
-
-                var req = {
-                    method: 'POST',
-                    url: '/resource/4?filter=a',
-                    headers: {
-                        host: '[123:123:123]',
-                        'content-type': 'text/plain;x=y'
-                    },
-                    connection: {
-                        encrypted: true
-                    }
-                };
-
-                expect(Hawk.utils.parseHost(req, 'Host').port).to.equal(443);
-                done();
-            });
-
-            it('parses IPv6 headers', function (done) {
-
-                var req = {
-                    method: 'POST',
-                    url: '/resource/4?filter=a',
-                    headers: {
-                        host: '[123:123:123]:8000',
-                        'content-type': 'text/plain;x=y'
-                    },
-                    connection: {
-                        encrypted: true
-                    }
-                };
-
-                var host = Hawk.utils.parseHost(req, 'Host');
-                expect(host.port).to.equal('8000');
-                expect(host.name).to.equal('[123:123:123]');
-                done();
-            });
+describe('Utils', function () {
+
+    describe('parseHost()', function () {
+
+        it('returns port 80 for non tls node request', function (done) {
+
+            var req = {
+                method: 'POST',
+                url: '/resource/4?filter=a',
+                headers: {
+                    host: 'example.com',
+                    'content-type': 'text/plain;x=y'
+                }
+            };
+
+            expect(Hawk.utils.parseHost(req, 'Host').port).to.equal(80);
+            done();
         });
 
-        describe('#version', function () {
+        it('returns port 443 for non tls node request', function (done) {
+
+            var req = {
+                method: 'POST',
+                url: '/resource/4?filter=a',
+                headers: {
+                    host: 'example.com',
+                    'content-type': 'text/plain;x=y'
+                },
+                connection: {
+                    encrypted: true
+                }
+            };
+
+            expect(Hawk.utils.parseHost(req, 'Host').port).to.equal(443);
+            done();
+        });
 
-            it('returns the correct package version number', function (done) {
+        it('returns port 443 for non tls node request (IPv6)', function (done) {
+
+            var req = {
+                method: 'POST',
+                url: '/resource/4?filter=a',
+                headers: {
+                    host: '[123:123:123]',
+                    'content-type': 'text/plain;x=y'
+                },
+                connection: {
+                    encrypted: true
+                }
+            };
+
+            expect(Hawk.utils.parseHost(req, 'Host').port).to.equal(443);
+            done();
+        });
 
-                expect(Hawk.utils.version()).to.equal(Package.version);
-                done();
-            });
+        it('parses IPv6 headers', function (done) {
+
+            var req = {
+                method: 'POST',
+                url: '/resource/4?filter=a',
+                headers: {
+                    host: '[123:123:123]:8000',
+                    'content-type': 'text/plain;x=y'
+                },
+                connection: {
+                    encrypted: true
+                }
+            };
+
+            var host = Hawk.utils.parseHost(req, 'Host');
+            expect(host.port).to.equal('8000');
+            expect(host.name).to.equal('[123:123:123]');
+            done();
         });
+    });
 
-        describe('#unauthorized', function () {
+    describe('version()', function () {
 
-            it('returns a hawk 401', function (done) {
+        it('returns the correct package version number', function (done) {
 
-                expect(Hawk.utils.unauthorized('kaboom').output.headers['WWW-Authenticate']).to.equal('Hawk error="kaboom"');
-                done();
-            });
+            expect(Hawk.utils.version()).to.equal(Package.version);
+            done();
         });
     });
-});
 
+    describe('unauthorized()', function () {
 
+        it('returns a hawk 401', function (done) {
+
+            expect(Hawk.utils.unauthorized('kaboom').output.headers['WWW-Authenticate']).to.equal('Hawk error="kaboom"');
+            done();
+        });
+
+        it('supports attributes', function (done) {
+
+            expect(Hawk.utils.unauthorized('kaboom', { a: 'b' }).output.headers['WWW-Authenticate']).to.equal('Hawk a="b", error="kaboom"');
+            done();
+        });
+    });
+});
index 034c2b4..be2bc63 100644 (file)
     "pretest": "which gjslint; if [[ \"$?\" = 0 ]] ; then  gjslint --nojsdoc -r lib -r tst; else echo \"Missing gjslint. Skipping lint\"; fi",
     "test": "tap ./tst"
   },
-  "readme": "node-asn1 is a library for encoding and decoding ASN.1 datatypes in pure JS.\nCurrently BER encoding is supported; at some point I'll likely have to do DER.\n\n## Usage\n\nMostly, if you're *actually* needing to read and write ASN.1, you probably don't\nneed this readme to explain what and why.  If you have no idea what ASN.1 is,\nsee this: ftp://ftp.rsa.com/pub/pkcs/ascii/layman.asc\n\nThe source is pretty much self-explanatory, and has read/write methods for the\ncommon types out there.\n\n### Decoding\n\nThe following reads an ASN.1 sequence with a boolean.\n\n    var Ber = require('asn1').Ber;\n\n    var reader = new Ber.Reader(new Buffer([0x30, 0x03, 0x01, 0x01, 0xff]));\n\n    reader.readSequence();\n    console.log('Sequence len: ' + reader.length);\n    if (reader.peek() === Ber.Boolean)\n      console.log(reader.readBoolean());\n\n### Encoding\n\nThe following generates the same payload as above.\n\n    var Ber = require('asn1').Ber;\n\n    var writer = new Ber.Writer();\n\n    writer.startSequence();\n    writer.writeBoolean(true);\n    writer.endSequence();\n\n    console.log(writer.buffer);\n\n## Installation\n\n    npm install asn1\n\n## License\n\nMIT.\n\n## Bugs\n\nSee <https://github.com/mcavage/node-asn1/issues>.\n",
-  "readmeFilename": "README.md",
-  "bugs": {
-    "url": "https://github.com/mcavage/node-asn1/issues"
+  "_npmUser": {
+    "name": "mcavage",
+    "email": "mcavage@gmail.com"
   },
-  "homepage": "https://github.com/mcavage/node-asn1#readme",
   "_id": "asn1@0.1.11",
+  "_engineSupported": true,
+  "_npmVersion": "1.1.0-beta-4",
+  "_nodeVersion": "v0.6.6",
+  "_defaultsLoaded": true,
+  "dist": {
+    "shasum": "559be18376d08a4ec4dbe80877d27818639b2df7",
+    "tarball": "http://registry.npmjs.org/asn1/-/asn1-0.1.11.tgz"
+  },
+  "maintainers": [
+    {
+      "name": "mcavage",
+      "email": "mcavage@gmail.com"
+    }
+  ],
+  "directories": {},
   "_shasum": "559be18376d08a4ec4dbe80877d27818639b2df7",
   "_resolved": "https://registry.npmjs.org/asn1/-/asn1-0.1.11.tgz",
-  "_from": "asn1@0.1.11"
+  "_from": "asn1@0.1.11",
+  "bugs": {
+    "url": "https://github.com/mcavage/node-asn1/issues"
+  },
+  "readme": "ERROR: No README data found!",
+  "homepage": "https://github.com/mcavage/node-asn1#readme"
 }
index b331767..6fcca67 100644 (file)
   "engines": {
     "node": ">=0.8"
   },
-  "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.<anonymous> (/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 <https://github.com/mcavage/node-assert-plus/issues>.\n",
-  "readmeFilename": "README.md",
   "bugs": {
     "url": "https://github.com/mcavage/node-assert-plus/issues"
   },
-  "homepage": "https://github.com/mcavage/node-assert-plus#readme",
   "dependencies": {},
   "_id": "assert-plus@0.1.5",
+  "dist": {
+    "shasum": "ee74009413002d84cec7219c6ac811812e723160",
+    "tarball": "http://registry.npmjs.org/assert-plus/-/assert-plus-0.1.5.tgz"
+  },
+  "_from": "assert-plus@>=0.1.5 <0.2.0",
+  "_npmVersion": "1.3.11",
+  "_npmUser": {
+    "name": "mcavage",
+    "email": "mcavage@gmail.com"
+  },
+  "maintainers": [
+    {
+      "name": "mcavage",
+      "email": "mcavage@gmail.com"
+    }
+  ],
+  "directories": {},
   "_shasum": "ee74009413002d84cec7219c6ac811812e723160",
   "_resolved": "https://registry.npmjs.org/assert-plus/-/assert-plus-0.1.5.tgz",
-  "_from": "assert-plus@>=0.1.5 <0.2.0"
+  "readme": "ERROR: No README data found!",
+  "homepage": "https://github.com/mcavage/node-assert-plus#readme"
 }
index 2090a5e..c33f8a5 100644 (file)
     "type": "git",
     "url": "git+https://github.com/rmustacc/node-ctype.git"
   },
-  "readme": "Node-CType is a way to read and write binary data in structured and easy to use\nformat. Its name comes from the C header file.\n\nTo get started, simply clone the repository or use npm to install it. Once it is\nthere, simply require it.\n\ngit clone git://github.com/rmustacc/node-ctype\nnpm install ctype\nvar mod_ctype = require('ctype')\n\n\nThere are two APIs that you can use, depending on what abstraction you'd like.\nThe low level API let's you read and write individual integers and floats from\nbuffers. The higher level API let's you read and write structures of these. To\nillustrate this, let's looks look at how we would read and write a binary\nencoded x,y point.\n\nIn C we would define this structure as follows:\n\ntypedef struct point {\n\tuint16_t\tp_x;\n\tuint16_t\tp_y;\n} point_t;\n\nTo read a binary encoded point from a Buffer, we first need to create a CType\nparser (where we specify the endian and other options) and add the typedef.\n\nvar parser = new mod_ctype.Parser({ endian: 'big' });\nparser.typedef('point_t', [\n\t{ x: { type: 'uint16_t' } },\n\t{ y: { type: 'uint16_t' } }\n]);\n\nFrom here, given a buffer buf and an offset into it, we can read a point.\n\nvar out = parser.readData([ { point: { type: 'point_t' } } ], buffer, 0);\nconsole.log(out);\n{ point: { x: 23, y: 42 } }\n\nAnother way to get the same information would be to use the low level methods.\nNote that these require you to manually deal with the offset. Here's how we'd\nget the same values of x and y from the buffer.\n\nvar x = mod_ctype.ruint16(buf, 'big', 0);\nvar y = mod_ctype.ruint16(buf, 'big', 2);\nconsole.log(x + ', ' + y);\n23, 42\n\nThe true power of this API comes from the ability to define and nest typedefs,\njust as you would in C. By default, the following types are defined by default.\nNote that they return a Number, unless indicated otherwise.\n\n    * int8_t\n    * int16_t\n    * int32_t\n    * int64_t (returns an array where val[0] << 32 + val[1] would be the value)\n    * uint8_t\n    * uint16_t\n    * uint32_t\n    * uint64_t (returns an array where val[0] << 32 + val[1] would be the value)\n    * float\n    * double\n    * char (either returns a buffer with that character or a uint8_t)\n    * char[] (returns an object with the buffer and the number of characters read which is either the total amount requested or until the first 0)\n\n\nctf2json integration:\n\nNode-CType supports consuming the output of ctf2json. Once you read in a JSON file,\nall you have to do to add all the definitions it contains is:\n\nvar data, parser;\ndata = JSON.parse(parsedJSONData);\nparser = mod_ctype.parseCTF(data, { endian: 'big' });\n\nFor more documentation, see the file README.old. Full documentation is in the\nprocess of being rewritten as a series of manual pages which will be available\nin the repository and online for viewing.\n\nTo read the ctio manual page simple run, from the root of the workspace:\n\nman -Mman -s 3ctype ctio\n",
-  "readmeFilename": "README",
-  "bugs": {
-    "url": "https://github.com/rmustacc/node-ctype/issues"
-  },
   "_id": "ctype@0.5.3",
+  "dist": {
+    "shasum": "82c18c2461f74114ef16c135224ad0b9144ca12f",
+    "tarball": "http://registry.npmjs.org/ctype/-/ctype-0.5.3.tgz"
+  },
+  "_npmVersion": "1.1.59",
+  "_npmUser": {
+    "name": "rm",
+    "email": "rm@fingolfin.org"
+  },
+  "maintainers": [
+    {
+      "name": "rm",
+      "email": "rm@fingolfin.org"
+    }
+  ],
+  "directories": {},
   "_shasum": "82c18c2461f74114ef16c135224ad0b9144ca12f",
   "_resolved": "https://registry.npmjs.org/ctype/-/ctype-0.5.3.tgz",
-  "_from": "ctype@0.5.3"
+  "_from": "ctype@0.5.3",
+  "bugs": {
+    "url": "https://github.com/rmustacc/node-ctype/issues"
+  },
+  "readme": "ERROR: No README data found!"
 }
diff --git a/deps/npm/node_modules/request/node_modules/isstream/.jshintrc b/deps/npm/node_modules/request/node_modules/isstream/.jshintrc
deleted file mode 100644 (file)
index c8ef3ca..0000000
+++ /dev/null
@@ -1,59 +0,0 @@
-{
-    "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
index d0338b8..74e97e6 100644 (file)
     "url": "https://github.com/rvagg/isstream/issues"
   },
   "homepage": "https://github.com/rvagg/isstream",
-  "readme": "# isStream\n\n[![Build Status](https://secure.travis-ci.org/rvagg/isstream.png)](http://travis-ci.org/rvagg/isstream)\n\n**Test if an object is a `Stream`**\n\n[![NPM](https://nodei.co/npm/isstream.svg)](https://nodei.co/npm/isstream/)\n\nThe missing `Stream.isStream(obj)`: determine if an object is standard Node.js `Stream`. Works for Node-core `Stream` objects (for 0.8, 0.10, 0.11, and in theory, older and newer versions) and all versions of **[readable-stream](https://github.com/isaacs/readable-stream)**.\n\n## Usage:\n\n```js\nvar isStream = require('isstream')\nvar Stream = require('stream')\n\nisStream(new Stream()) // true\n\nisStream({}) // false\n\nisStream(new Stream.Readable())    // true\nisStream(new Stream.Writable())    // true\nisStream(new Stream.Duplex())      // true\nisStream(new Stream.Transform())   // true\nisStream(new Stream.PassThrough()) // true\n```\n\n## But wait! There's more!\n\nYou can also test for `isReadable(obj)`, `isWritable(obj)` and `isDuplex(obj)` to test for implementations of Streams2 (and Streams3) base classes.\n\n```js\nvar isReadable = require('isstream').isReadable\nvar isWritable = require('isstream').isWritable\nvar isDuplex = require('isstream').isDuplex\nvar Stream = require('stream')\n\nisReadable(new Stream()) // false\nisWritable(new Stream()) // false\nisDuplex(new Stream())   // false\n\nisReadable(new Stream.Readable())    // true\nisReadable(new Stream.Writable())    // false\nisReadable(new Stream.Duplex())      // true\nisReadable(new Stream.Transform())   // true\nisReadable(new Stream.PassThrough()) // true\n\nisWritable(new Stream.Readable())    // false\nisWritable(new Stream.Writable())    // true\nisWritable(new Stream.Duplex())      // true\nisWritable(new Stream.Transform())   // true\nisWritable(new Stream.PassThrough()) // true\n\nisDuplex(new Stream.Readable())    // false\nisDuplex(new Stream.Writable())    // false\nisDuplex(new Stream.Duplex())      // true\nisDuplex(new Stream.Transform())   // true\nisDuplex(new Stream.PassThrough()) // true\n```\n\n*Reminder: when implementing your own streams, please [use **readable-stream** rather than core streams](http://r.va.gg/2014/06/why-i-dont-use-nodes-core-stream-module.html).*\n\n\n## License\n\n**isStream** is Copyright (c) 2015 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.\n",
-  "readmeFilename": "README.md",
+  "gitHead": "cd39cba6da939b4fc9110825203adc506422c3dc",
   "_id": "isstream@0.1.2",
   "_shasum": "47e63f7af55afa6f92e1500e690eb8b8529c099a",
+  "_from": "isstream@>=0.1.1 <0.2.0",
+  "_npmVersion": "2.6.1",
+  "_nodeVersion": "1.4.3",
+  "_npmUser": {
+    "name": "rvagg",
+    "email": "rod@vagg.org"
+  },
+  "maintainers": [
+    {
+      "name": "rvagg",
+      "email": "rod@vagg.org"
+    }
+  ],
+  "dist": {
+    "shasum": "47e63f7af55afa6f92e1500e690eb8b8529c099a",
+    "tarball": "http://registry.npmjs.org/isstream/-/isstream-0.1.2.tgz"
+  },
+  "directories": {},
   "_resolved": "https://registry.npmjs.org/isstream/-/isstream-0.1.2.tgz",
-  "_from": "isstream@>=0.1.1 <0.2.0"
+  "readme": "ERROR: No README data found!"
 }
index fb90c27..c5b8f5f 100644 (file)
@@ -1,3 +1,35 @@
+2.1.3 / 2015-07-13
+==================
+
+  * deps: mime-db@~1.15.0
+    - Add new mime types
+
+2.1.2 / 2015-06-25
+==================
+
+  * deps: mime-db@~1.14.0
+    - Add new mime types
+
+2.1.1 / 2015-06-08
+==================
+
+  * perf: fix deopt during mapping
+
+2.1.0 / 2015-06-07
+==================
+
+  * Fix incorrectly treating extension-less file name as extension
+    - i.e. `'path/to/json'` will no longer return `application/json`
+  * Fix `.charset(type)` to accept parameters
+  * Fix `.charset(type)` to match case-insensitive
+  * Improve generation of extension to MIME mapping
+  * Refactor internals for readability and no argument reassignment
+  * Prefer `application/*` MIME types from the same source
+  * Prefer any type over `application/octet-stream`
+  * deps: mime-db@~1.13.0
+    - Add nginx as a source
+    - Add new mime types
+
 2.0.14 / 2015-06-06
 ===================
 
index a7ae8ee..0616607 100644 (file)
@@ -1,22 +1,23 @@
+(The MIT License)
 
-The MIT License (MIT)
+Copyright (c) 2014 Jonathan Ong <me@jongleberry.com>
+Copyright (c) 2015 Douglas Christopher Wilson <doug@somethingdoug.com>
 
-Copyright (c) 2014 Jonathan Ong me@jongleberry.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:
 
-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 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.
+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.
index 3727493..e26295d 100644 (file)
@@ -42,10 +42,11 @@ All functions return `false` if input is invalid or not found.
 Lookup the content-type associated with a file.
 
 ```js
-mime.lookup('json')           // 'application/json'
-mime.lookup('.md')            // 'text/x-markdown'
-mime.lookup('file.html')      // 'text/html'
-mime.lookup('folder/file.js') // 'application/javascript'
+mime.lookup('json')             // 'application/json'
+mime.lookup('.md')              // 'text/x-markdown'
+mime.lookup('file.html')        // 'text/html'
+mime.lookup('folder/file.js')   // 'application/javascript'
+mime.lookup('folder/.htaccess') // false
 
 mime.lookup('cats') // false
 ```
index b46a202..9edf72b 100644 (file)
+/*!
+ * mime-types
+ * Copyright(c) 2014 Jonathan Ong
+ * Copyright(c) 2015 Douglas Christopher Wilson
+ * MIT Licensed
+ */
+
+'use strict'
+
+/**
+ * Module dependencies.
+ * @private
+ */
 
 var db = require('mime-db')
+var extname = require('path').extname
 
-// types[extension] = type
-exports.types = Object.create(null)
-// extensions[type] = [extensions]
+/**
+ * Module variables.
+ * @private
+ */
+
+var extractTypeRegExp = /^\s*([^;\s]*)(?:;|\s|$)/
+var textTypeRegExp = /^text\//i
+
+/**
+ * Module exports.
+ * @public
+ */
+
+exports.charset = charset
+exports.charsets = { lookup: charset }
+exports.contentType = contentType
+exports.extension = extension
 exports.extensions = Object.create(null)
+exports.lookup = lookup
+exports.types = Object.create(null)
 
-Object.keys(db).forEach(function (name) {
-  var mime = db[name]
-  var exts = mime.extensions
-  if (!exts || !exts.length) return
-  exports.extensions[name] = exts
-  exts.forEach(function (ext) {
-    exports.types[ext] = name
-  })
-})
-
-exports.lookup = function (string) {
-  if (!string || typeof string !== "string") return false
-  // remove any leading paths, though we should just use path.basename
-  string = string.replace(/.*[\.\/\\]/, '').toLowerCase()
-  if (!string) return false
-  return exports.types[string] || false
-}
+// Populate the extensions/types maps
+populateMaps(exports.extensions, exports.types)
 
-exports.extension = function (type) {
-  if (!type || typeof type !== "string") return false
-  // to do: use media-typer
-  type = type.match(/^\s*([^;\s]*)(?:;|\s|$)/)
-  if (!type) return false
-  var exts = exports.extensions[type[1].toLowerCase()]
-  if (!exts || !exts.length) return false
-  return exts[0]
-}
+/**
+ * Get the default charset for a MIME type.
+ *
+ * @param {string} type
+ * @return {boolean|string}
+ */
+
+function charset(type) {
+  if (!type || typeof type !== 'string') {
+    return false
+  }
 
-// type has to be an exact mime type
-exports.charset = function (type) {
-  var mime = db[type]
-  if (mime && mime.charset) return mime.charset
+  // TODO: use media-typer
+  var match = extractTypeRegExp.exec(type)
+  var mime = match && db[match[1].toLowerCase()]
+
+  if (mime && mime.charset) {
+    return mime.charset
+  }
 
   // default text/* to utf-8
-  if (/^text\//.test(type)) return 'UTF-8'
+  if (match && textTypeRegExp.test(match[1])) {
+    return 'UTF-8'
+  }
 
   return false
 }
 
-// backwards compatibility
-exports.charsets = {
-  lookup: exports.charset
+/**
+ * Create a full Content-Type header given a MIME type or extension.
+ *
+ * @param {string} str
+ * @return {boolean|string}
+ */
+
+function contentType(str) {
+  // TODO: should this even be in this module?
+  if (!str || typeof str !== 'string') {
+    return false
+  }
+
+  var mime = str.indexOf('/') === -1
+    ? exports.lookup(str)
+    : str
+
+  if (!mime) {
+    return false
+  }
+
+  // TODO: use content-type or other module
+  if (mime.indexOf('charset') === -1) {
+    var charset = exports.charset(mime)
+    if (charset) mime += '; charset=' + charset.toLowerCase()
+  }
+
+  return mime
+}
+
+/**
+ * Get the default extension for a MIME type.
+ *
+ * @param {string} type
+ * @return {boolean|string}
+ */
+
+function extension(type) {
+  if (!type || typeof type !== 'string') {
+    return false
+  }
+
+  // TODO: use media-typer
+  var match = extractTypeRegExp.exec(type)
+
+  // get extensions
+  var exts = match && exports.extensions[match[1].toLowerCase()]
+
+  if (!exts || !exts.length) {
+    return false
+  }
+
+  return exts[0]
 }
 
-// to do: maybe use set-type module or something
-exports.contentType = function (type) {
-  if (!type || typeof type !== "string") return false
-  if (!~type.indexOf('/')) type = exports.lookup(type)
-  if (!type) return false
-  if (!~type.indexOf('charset')) {
-    var charset = exports.charset(type)
-    if (charset) type += '; charset=' + charset.toLowerCase()
+/**
+ * Lookup the MIME type for a file path/extension.
+ *
+ * @param {string} path
+ * @return {boolean|string}
+ */
+
+function lookup(path) {
+  if (!path || typeof path !== 'string') {
+    return false
+  }
+
+  // get the extension ("ext" or ".ext" or full path)
+  var extension = extname('x.' + path)
+    .toLowerCase()
+    .substr(1)
+
+  if (!extension) {
+    return false
   }
-  return type
+
+  return exports.types[extension] || false
+}
+
+/**
+ * Populate the extensions and types maps.
+ * @private
+ */
+
+function populateMaps(extensions, types) {
+  // source preference (least -> most)
+  var preference = ['nginx', 'apache', undefined, 'iana']
+
+  Object.keys(db).forEach(function forEachMimeType(type) {
+    var mime = db[type]
+    var exts = mime.extensions
+
+    if (!exts || !exts.length) {
+      return
+    }
+
+    // mime -> extensions
+    extensions[type] = exts
+
+    // extension -> mime
+    for (var i = 0; i < exts.length; i++) {
+      var extension = exts[i]
+
+      if (types[extension]) {
+        var from = preference.indexOf(db[types[extension]].source)
+        var to = preference.indexOf(mime.source)
+
+        if (types[extension] !== 'application/octet-stream'
+          && from > to || (from === to && types[extension].substr(0, 12) === 'application/')) {
+          // skip the remapping
+          return
+        }
+      }
+
+      // set the extension -> mime
+      types[extension] = type
+    }
+  })
 }
index d559c26..fa40614 100644 (file)
@@ -1,3 +1,32 @@
+1.15.0 / 2015-07-13
+===================
+
+  * Add `application/x-httpd-php`
+
+1.14.0 / 2015-06-25
+===================
+
+  * Add `application/scim+json`
+  * Add `application/vnd.3gpp.ussd+xml`
+  * Add `application/vnd.biopax.rdf+xml`
+  * Add `text/x-processing`
+
+1.13.0 / 2015-06-07
+===================
+
+  * Add nginx as a source
+  * Add `application/x-cocoa`
+  * Add `application/x-java-archive-diff`
+  * Add `application/x-makeself`
+  * Add `application/x-perl`
+  * Add `application/x-pilot`
+  * Add `application/x-redhat-package-manager`
+  * Add `application/x-sea`
+  * Add `audio/x-m4a`
+  * Add `audio/x-realaudio`
+  * Add `image/x-jng`
+  * Add `text/mathml`
+
 1.12.0 / 2015-06-05
 ===================
 
index 2c54bb4..164cca0 100644 (file)
@@ -13,6 +13,7 @@ It aggregates data from the following sources:
 
 - http://www.iana.org/assignments/media-types/media-types.xhtml
 - http://svn.apache.org/repos/asf/httpd/httpd/trunk/docs/conf/mime.types
+- http://hg.nginx.org/nginx/raw-file/default/conf/mime.types
 
 ## Installation
 
@@ -20,8 +21,12 @@ It aggregates data from the following sources:
 npm install mime-db
 ```
 
-If you're crazy enough to use this in the browser,
-you can just grab the JSON file:
+### Database Download
+
+If you're crazy enough to use this in the browser, you can just grab the
+JSON file using [RawGit](https://rawgit.com/). It is recommended to replace
+`master` with [a release tag](https://github.com/jshttp/mime-db/tags) as the
+JSON format may change in the future.
 
 ```
 https://cdn.rawgit.com/jshttp/mime-db/master/db.json
@@ -45,6 +50,7 @@ Each mime type has the following properties:
     If not set, it's probably a custom media type.
     - `apache` - [Apache common media types](http://svn.apache.org/repos/asf/httpd/httpd/trunk/docs/conf/mime.types)
     - `iana` - [IANA-defined media types](http://www.iana.org/assignments/media-types/media-types.xhtml)
+    - `nginx` - [nginx media types](http://hg.nginx.org/nginx/raw-file/default/conf/mime.types)
 - `.extensions[]` - known extensions associated with this mime type.
 - `.compressible` - whether a file of this type is can be gzipped.
 - `.charset` - the default charset associated with this type, if any.
@@ -56,7 +62,7 @@ If unknown, every property could be `undefined`.
 To edit the database, only make PRs against `src/custom.json` or
 `src/custom-suffix.json`.
 
-To update the build, run `npm run update`.
+To update the build, run `npm run build`.
 
 ## Adding Custom Media Types
 
index 5f111be..2f2dc44 100644 (file)
   "application/java-archive": {
     "source": "apache",
     "compressible": false,
-    "extensions": ["jar"]
+    "extensions": ["jar","war","ear"]
   },
   "application/java-serialized-object": {
     "source": "apache",
   "application/octet-stream": {
     "source": "iana",
     "compressible": false,
-    "extensions": ["bin","dms","lrf","mar","so","dist","distz","pkg","bpk","dump","elc","deploy","buffer"]
+    "extensions": ["bin","dms","lrf","mar","so","dist","distz","pkg","bpk","dump","elc","deploy","exe","dll","deb","dmg","iso","img","msi","msp","msm","buffer"]
   },
   "application/oda": {
     "source": "iana",
   "application/scaip+xml": {
     "source": "iana"
   },
+  "application/scim+json": {
+    "source": "iana",
+    "compressible": true
+  },
   "application/scvp-cv-request": {
     "source": "iana",
     "extensions": ["scq"]
   "application/vnd.3gpp.sms": {
     "source": "iana"
   },
+  "application/vnd.3gpp.ussd+xml": {
+    "source": "iana"
+  },
   "application/vnd.3gpp2.bcmcsinfo+xml": {
     "source": "iana"
   },
     "source": "iana",
     "compressible": true
   },
+  "application/vnd.biopax.rdf+xml": {
+    "source": "iana"
+  },
   "application/vnd.blueice.multipass": {
     "source": "iana",
     "extensions": ["mpm"]
   "application/x-chrome-extension": {
     "extensions": ["crx"]
   },
+  "application/x-cocoa": {
+    "source": "nginx",
+    "extensions": ["cco"]
+  },
   "application/x-compress": {
     "source": "apache"
   },
     "source": "apache",
     "extensions": ["hdf"]
   },
+  "application/x-httpd-php": {
+    "compressible": true,
+    "extensions": ["php"]
+  },
   "application/x-install-instructions": {
     "source": "apache",
     "extensions": ["install"]
     "source": "apache",
     "extensions": ["iso"]
   },
+  "application/x-java-archive-diff": {
+    "source": "nginx",
+    "extensions": ["jardiff"]
+  },
   "application/x-java-jnlp-file": {
     "source": "apache",
     "compressible": false,
     "source": "apache",
     "extensions": ["lzh","lha"]
   },
+  "application/x-makeself": {
+    "source": "nginx",
+    "extensions": ["run"]
+  },
   "application/x-mie": {
     "source": "apache",
     "extensions": ["mie"]
     "source": "apache",
     "extensions": ["nzb"]
   },
+  "application/x-perl": {
+    "source": "nginx",
+    "extensions": ["pl","pm"]
+  },
+  "application/x-pilot": {
+    "source": "nginx",
+    "extensions": ["prc","pdb"]
+  },
   "application/x-pkcs12": {
     "source": "apache",
     "compressible": false,
     "compressible": false,
     "extensions": ["rar"]
   },
+  "application/x-redhat-package-manager": {
+    "source": "nginx",
+    "extensions": ["rpm"]
+  },
   "application/x-research-info-systems": {
     "source": "apache",
     "extensions": ["ris"]
   },
+  "application/x-sea": {
+    "source": "nginx",
+    "extensions": ["sea"]
+  },
   "application/x-sh": {
     "source": "apache",
     "compressible": true,
   },
   "application/x-tcl": {
     "source": "apache",
-    "extensions": ["tcl"]
+    "extensions": ["tcl","tk"]
   },
   "application/x-tex": {
     "source": "apache",
   },
   "application/x-x509-ca-cert": {
     "source": "apache",
-    "extensions": ["der","crt"]
+    "extensions": ["der","crt","pem"]
   },
   "application/x-xfig": {
     "source": "apache",
     "source": "apache",
     "extensions": ["flac"]
   },
+  "audio/x-m4a": {
+    "source": "nginx",
+    "extensions": ["m4a"]
+  },
   "audio/x-matroska": {
     "source": "apache",
     "extensions": ["mka"]
     "source": "apache",
     "extensions": ["rmp"]
   },
+  "audio/x-realaudio": {
+    "source": "nginx",
+    "extensions": ["ra"]
+  },
   "audio/x-tta": {
     "source": "apache"
   },
     "compressible": true,
     "extensions": ["ico"]
   },
+  "image/x-jng": {
+    "source": "nginx",
+    "extensions": ["jng"]
+  },
   "image/x-mrsid-image": {
     "source": "apache",
     "extensions": ["sid"]
   },
   "image/x-ms-bmp": {
+    "source": "nginx",
     "compressible": true,
     "extensions": ["bmp"]
   },
   "text/html": {
     "source": "iana",
     "compressible": true,
-    "extensions": ["html","htm"]
+    "extensions": ["html","htm","shtml"]
   },
   "text/jade": {
     "extensions": ["jade"]
   "text/markdown": {
     "source": "iana"
   },
+  "text/mathml": {
+    "source": "nginx",
+    "extensions": ["mml"]
+  },
   "text/mizar": {
     "source": "iana"
   },
     "extensions": ["c","cc","cxx","cpp","h","hh","dic"]
   },
   "text/x-component": {
+    "source": "nginx",
     "extensions": ["htc"]
   },
   "text/x-fortran": {
     "source": "apache",
     "extensions": ["p","pas"]
   },
+  "text/x-processing": {
+    "compressible": true,
+    "extensions": ["pde"]
+  },
   "text/x-sass": {
     "extensions": ["sass"]
   },
   },
   "text/xml": {
     "source": "iana",
-    "compressible": true
+    "compressible": true,
+    "extensions": ["xml"]
   },
   "text/xml-external-parsed-entity": {
     "source": "iana"
   },
   "video/3gpp": {
     "source": "apache",
-    "extensions": ["3gp"]
+    "extensions": ["3gp","3gpp"]
   },
   "video/3gpp-tt": {
     "source": "apache"
index 6161722..a07ee86 100644 (file)
@@ -1,7 +1,7 @@
 {
   "name": "mime-db",
   "description": "Media Type Database",
-  "version": "1.12.0",
+  "version": "1.15.0",
   "contributors": [
     {
       "name": "Douglas Christopher Wilson",
     "url": "git+https://github.com/jshttp/mime-db.git"
   },
   "devDependencies": {
-    "bluebird": "2.9.27",
-    "co": "4.5.4",
+    "bluebird": "2.9.33",
+    "co": "4.6.0",
     "cogent": "1.0.1",
-    "csv-parse": "0.1.2",
+    "csv-parse": "0.1.3",
     "gnode": "0.1.1",
-    "istanbul": "0.3.9",
+    "istanbul": "0.3.17",
     "mocha": "1.21.5",
-    "raw-body": "2.1.0",
+    "raw-body": "2.1.2",
     "stream-to-array": "2"
   },
   "files": [
   },
   "scripts": {
     "build": "node scripts/build",
-    "fetch": "gnode scripts/extensions && gnode scripts/types",
+    "fetch": "gnode scripts/fetch-apache && gnode scripts/fetch-iana && gnode scripts/fetch-nginx",
     "test": "mocha --reporter spec --bail --check-leaks test/",
     "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks test/",
     "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks test/",
     "update": "npm run fetch && npm run build"
   },
-  "gitHead": "cf35cbba6b22f4a3b3eef9a32129ea5b7f0f91ee",
+  "gitHead": "96922b79fcaacf8c2a95ce3368739ec71c9471a2",
   "bugs": {
     "url": "https://github.com/jshttp/mime-db/issues"
   },
   "homepage": "https://github.com/jshttp/mime-db",
-  "_id": "mime-db@1.12.0",
-  "_shasum": "3d0c63180f458eb10d325aaa37d7c58ae312e9d7",
-  "_from": "mime-db@>=1.12.0 <1.13.0",
+  "_id": "mime-db@1.15.0",
+  "_shasum": "d219e6214bbcae23a6fa69c0868c4fadc1405e8a",
+  "_from": "mime-db@>=1.15.0 <1.16.0",
   "_npmVersion": "1.4.28",
   "_npmUser": {
     "name": "dougwilson",
     }
   ],
   "dist": {
-    "shasum": "3d0c63180f458eb10d325aaa37d7c58ae312e9d7",
-    "tarball": "http://registry.npmjs.org/mime-db/-/mime-db-1.12.0.tgz"
+    "shasum": "d219e6214bbcae23a6fa69c0868c4fadc1405e8a",
+    "tarball": "http://registry.npmjs.org/mime-db/-/mime-db-1.15.0.tgz"
   },
   "directories": {},
-  "_resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.12.0.tgz",
+  "_resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.15.0.tgz",
   "readme": "ERROR: No README data found!"
 }
index 23060b7..4fbb214 100644 (file)
@@ -1,7 +1,7 @@
 {
   "name": "mime-types",
   "description": "The ultimate javascript content-type utility.",
-  "version": "2.0.14",
+  "version": "2.1.3",
   "contributors": [
     {
       "name": "Douglas Christopher Wilson",
     "url": "git+https://github.com/jshttp/mime-types.git"
   },
   "dependencies": {
-    "mime-db": "~1.12.0"
+    "mime-db": "~1.15.0"
   },
   "devDependencies": {
-    "istanbul": "0.3.9",
+    "istanbul": "0.3.17",
     "mocha": "~1.21.5"
   },
   "files": [
     "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot test/test.js",
     "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter dot test/test.js"
   },
-  "gitHead": "7d53a3351581eb3d7ae1e846ea860037bce6fe3f",
+  "gitHead": "565c49ad5683d4a123a170da3444ed32ce426c3a",
   "bugs": {
     "url": "https://github.com/jshttp/mime-types/issues"
   },
   "homepage": "https://github.com/jshttp/mime-types",
-  "_id": "mime-types@2.0.14",
-  "_shasum": "310e159db23e077f8bb22b748dabfa4957140aa6",
-  "_from": "mime-types@>=2.0.1 <2.1.0",
+  "_id": "mime-types@2.1.3",
+  "_shasum": "f259849c7eb1f85b8f5f826187278a7f74f0c966",
+  "_from": "mime-types@>=2.1.2 <2.2.0",
   "_npmVersion": "1.4.28",
   "_npmUser": {
     "name": "dougwilson",
     }
   ],
   "dist": {
-    "shasum": "310e159db23e077f8bb22b748dabfa4957140aa6",
-    "tarball": "http://registry.npmjs.org/mime-types/-/mime-types-2.0.14.tgz"
+    "shasum": "f259849c7eb1f85b8f5f826187278a7f74f0c966",
+    "tarball": "http://registry.npmjs.org/mime-types/-/mime-types-2.1.3.tgz"
   },
   "directories": {},
-  "_resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.0.14.tgz",
+  "_resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.3.tgz",
   "readme": "ERROR: No README data found!"
 }
diff --git a/deps/npm/node_modules/request/node_modules/qs/.jshintignore b/deps/npm/node_modules/request/node_modules/qs/.jshintignore
deleted file mode 100644 (file)
index 3c3629e..0000000
+++ /dev/null
@@ -1 +0,0 @@
-node_modules
diff --git a/deps/npm/node_modules/request/node_modules/qs/Makefile b/deps/npm/node_modules/request/node_modules/qs/Makefile
deleted file mode 100644 (file)
index 31cc899..0000000
+++ /dev/null
@@ -1,8 +0,0 @@
-test:
-       @node node_modules/lab/bin/lab -a code -L
-test-cov:
-       @node node_modules/lab/bin/lab -a code -t 100 -L
-test-cov-html:
-       @node node_modules/lab/bin/lab -a code -L -r html -o coverage.html
-
-.PHONY: test test-cov test-cov-html
index 0c72aba..48a0de9 100644 (file)
@@ -34,10 +34,17 @@ For example, the string `'foo[bar]=baz'` converts to:
 }
 ```
 
-The parsed value is returned as a plain object, created via `Object.create(null)` and as such you should be aware that prototype methods do not exist on it and a user may set those names to whatever value they like:
+When using the `plainObjects` option the parsed value is returned as a plain object, created via `Object.create(null)` and as such you should be aware that prototype methods will not exist on it and a user may set those names to whatever value they like:
 
 ```javascript
-Qs.parse('a.hasOwnProperty=b');
+Qs.parse('a.hasOwnProperty=b', { plainObjects: true });
+// { a: { hasOwnProperty: 'b' } }
+```
+
+By default parameters that would overwrite properties on the object prototype are ignored, if you wish to keep the data from those fields either use `plainObjects` as mentioned above, or set `allowPrototypes` to `true` which will allow user input to overwrite those properties. *WARNING* It is generally a bad idea to enable this option as it can cause problems when attempting to use the properties that have been overwritten. Always be careful with this option.
+
+```javascript
+Qs.parse('a.hasOwnProperty=b', { allowPrototypes: true });
 // { a: { hasOwnProperty: 'b' } }
 ```
 
@@ -111,6 +118,13 @@ Qs.parse('a=b;c=d,e=f', { delimiter: /[;,]/ });
 // { a: 'b', c: 'd', e: 'f' }
 ```
 
+Option `allowDots` can be used to disable dot notation:
+
+```javascript
+Qs.parse('a.b=c', { allowDots: false });
+// { 'a.b': 'c' } }
+```
+
 ### Parsing Arrays
 
 **qs** can also parse arrays using a similar `[]` notation:
diff --git a/deps/npm/node_modules/request/node_modules/qs/index.js b/deps/npm/node_modules/request/node_modules/qs/index.js
deleted file mode 100644 (file)
index 2291cd8..0000000
+++ /dev/null
@@ -1 +0,0 @@
-module.exports = require('./lib/');
index 1a1e205..e7c56c5 100644 (file)
@@ -10,7 +10,9 @@ var internals = {
     depth: 5,
     arrayLimit: 20,
     parameterLimit: 1000,
-    strictNullHandling: false
+    strictNullHandling: false,
+    plainObjects: false,
+    allowPrototypes: false
 };
 
 
@@ -61,7 +63,7 @@ internals.parseObject = function (chain, val, options) {
         obj = obj.concat(internals.parseObject(chain, val, options));
     }
     else {
-        obj = Object.create(null);
+        obj = options.plainObjects ? Object.create(null) : {};
         var cleanRoot = root[0] === '[' && root[root.length - 1] === ']' ? root.slice(1, root.length - 1) : root;
         var index = parseInt(cleanRoot, 10);
         var indexString = '' + index;
@@ -109,6 +111,16 @@ internals.parseKeys = function (key, val, options) {
 
     var keys = [];
     if (segment[1]) {
+        // If we aren't using plain objects, optionally prefix keys
+        // that would overwrite object prototype properties
+        if (!options.plainObjects &&
+            Object.prototype.hasOwnProperty(segment[1])) {
+
+            if (!options.allowPrototypes) {
+                return;
+            }
+        }
+
         keys.push(segment[1]);
     }
 
@@ -118,6 +130,13 @@ internals.parseKeys = function (key, val, options) {
     while ((segment = child.exec(key)) !== null && i < options.depth) {
 
         ++i;
+        if (!options.plainObjects &&
+            Object.prototype.hasOwnProperty(segment[1].replace(/\[|\]/g, ''))) {
+
+            if (!options.allowPrototypes) {
+                continue;
+            }
+        }
         keys.push(segment[1]);
     }
 
@@ -133,25 +152,26 @@ internals.parseKeys = function (key, val, options) {
 
 module.exports = function (str, options) {
 
-    if (str === '' ||
-        str === null ||
-        typeof str === 'undefined') {
-
-        return Object.create(null);
-    }
-
     options = options || {};
     options.delimiter = typeof options.delimiter === 'string' || Utils.isRegExp(options.delimiter) ? options.delimiter : internals.delimiter;
     options.depth = typeof options.depth === 'number' ? options.depth : internals.depth;
     options.arrayLimit = typeof options.arrayLimit === 'number' ? options.arrayLimit : internals.arrayLimit;
     options.parseArrays = options.parseArrays !== false;
     options.allowDots = options.allowDots !== false;
+    options.plainObjects = typeof options.plainObjects === 'boolean' ? options.plainObjects : internals.plainObjects;
+    options.allowPrototypes = typeof options.allowPrototypes === 'boolean' ? options.allowPrototypes : internals.allowPrototypes;
     options.parameterLimit = typeof options.parameterLimit === 'number' ? options.parameterLimit : internals.parameterLimit;
     options.strictNullHandling = typeof options.strictNullHandling === 'boolean' ? options.strictNullHandling : internals.strictNullHandling;
 
+    if (str === '' ||
+        str === null ||
+        typeof str === 'undefined') {
+
+        return options.plainObjects ? Object.create(null) : {};
+    }
 
     var tempObj = typeof str === 'string' ? internals.parseValues(str, options) : str;
-    var obj = Object.create(null);
+    var obj = options.plainObjects ? Object.create(null) : {};
 
     // Iterate over the keys and setup the new object
 
@@ -159,7 +179,7 @@ module.exports = function (str, options) {
     for (var i = 0, il = keys.length; i < il; ++i) {
         var key = keys[i];
         var newObj = internals.parseKeys(key, tempObj[key], options);
-        obj = Utils.merge(obj, newObj);
+        obj = Utils.merge(obj, newObj, options);
     }
 
     return Utils.compact(obj);
index ec93afc..88f3147 100644 (file)
@@ -5,14 +5,14 @@
 
 var internals = {};
 internals.hexTable = new Array(256);
-for (var i = 0; i < 256; ++i) {
-    internals.hexTable[i] = '%' + ((i < 16 ? '0' : '') + i.toString(16)).toUpperCase();
+for (var h = 0; h < 256; ++h) {
+    internals.hexTable[h] = '%' + ((h < 16 ? '0' : '') + h.toString(16)).toUpperCase();
 }
 
 
-exports.arrayToObject = function (source) {
+exports.arrayToObject = function (source, options) {
 
-    var obj = Object.create(null);
+    var obj = options.plainObjects ? Object.create(null) : {};
     for (var i = 0, il = source.length; i < il; ++i) {
         if (typeof source[i] !== 'undefined') {
 
@@ -24,7 +24,7 @@ exports.arrayToObject = function (source) {
 };
 
 
-exports.merge = function (target, source) {
+exports.merge = function (target, source, options) {
 
     if (!source) {
         return target;
@@ -52,7 +52,7 @@ exports.merge = function (target, source) {
     if (Array.isArray(target) &&
         !Array.isArray(source)) {
 
-        target = exports.arrayToObject(target);
+        target = exports.arrayToObject(target, options);
     }
 
     var keys = Object.keys(source);
@@ -60,11 +60,11 @@ exports.merge = function (target, source) {
         var key = keys[k];
         var value = source[key];
 
-        if (!target[key]) {
+        if (!Object.prototype.hasOwnProperty.call(target, key)) {
             target[key] = value;
         }
         else {
-            target[key] = exports.merge(target[key], value);
+            target[key] = exports.merge(target[key], value, options);
         }
     }
 
index bd7c53c..4c45772 100644 (file)
@@ -1,9 +1,9 @@
 {
   "name": "qs",
-  "version": "3.1.0",
+  "version": "4.0.0",
   "description": "A querystring parser that supports nesting and arrays, with a depth limit",
   "homepage": "https://github.com/hapijs/qs",
-  "main": "index.js",
+  "main": "lib/index.js",
   "dependencies": {},
   "devDependencies": {
     "browserify": "^10.2.1",
@@ -11,8 +11,9 @@
     "lab": "5.x.x"
   },
   "scripts": {
-    "test": "make test-cov",
-    "dist": "browserify --standalone Qs index.js > dist/qs.js"
+    "test": "lab -a code -t 100 -L",
+    "test-cov-html": "lab -a code -r html -o coverage.html",
+    "dist": "browserify --standalone Qs lib/index.js > dist/qs.js"
   },
   "repository": {
     "type": "git",
     "qs"
   ],
   "license": "BSD-3-Clause",
-  "gitHead": "e53b1b242a55f886531954ebdd78b3b20efadaf0",
+  "gitHead": "e573dd08eae6cce30d2202704691a102dfa3782a",
   "bugs": {
     "url": "https://github.com/hapijs/qs/issues"
   },
-  "_id": "qs@3.1.0",
-  "_shasum": "d0e9ae745233a12dc43fb4f3055bba446261153c",
-  "_from": "qs@>=3.1.0 <3.2.0",
-  "_npmVersion": "2.9.0",
-  "_nodeVersion": "0.12.2",
+  "_id": "qs@4.0.0",
+  "_shasum": "c31d9b74ec27df75e543a86c78728ed8d4623607",
+  "_from": "qs@>=4.0.0 <4.1.0",
+  "_npmVersion": "2.12.0",
+  "_nodeVersion": "0.12.4",
   "_npmUser": {
     "name": "nlf",
     "email": "quitlahok@gmail.com"
   },
   "dist": {
-    "shasum": "d0e9ae745233a12dc43fb4f3055bba446261153c",
-    "tarball": "http://registry.npmjs.org/qs/-/qs-3.1.0.tgz"
+    "shasum": "c31d9b74ec27df75e543a86c78728ed8d4623607",
+    "tarball": "http://registry.npmjs.org/qs/-/qs-4.0.0.tgz"
   },
   "maintainers": [
     {
@@ -51,6 +52,6 @@
     }
   ],
   "directories": {},
-  "_resolved": "https://registry.npmjs.org/qs/-/qs-3.1.0.tgz",
+  "_resolved": "https://registry.npmjs.org/qs/-/qs-4.0.0.tgz",
   "readme": "ERROR: No README data found!"
 }
index 9afbf35..a19d764 100644 (file)
@@ -23,194 +23,194 @@ describe('parse()', function () {
 
     it('parses a simple string', function (done) {
 
-        expect(Qs.parse('0=foo')).to.deep.equal({ '0': 'foo' }, { prototype: false });
-        expect(Qs.parse('foo=c++')).to.deep.equal({ foo: 'c  ' }, { prototype: false });
-        expect(Qs.parse('a[>=]=23')).to.deep.equal({ a: { '>=': '23' } }, { prototype: false });
-        expect(Qs.parse('a[<=>]==23')).to.deep.equal({ a: { '<=>': '=23' } }, { prototype: false });
-        expect(Qs.parse('a[==]=23')).to.deep.equal({ a: { '==': '23' } }, { prototype: false });
-        expect(Qs.parse('foo', {strictNullHandling: true})).to.deep.equal({ foo: null }, { prototype: false });
-        expect(Qs.parse('foo' )).to.deep.equal({ foo: '' }, { prototype: false });
-        expect(Qs.parse('foo=')).to.deep.equal({ foo: '' }, { prototype: false });
-        expect(Qs.parse('foo=bar')).to.deep.equal({ foo: 'bar' }, { prototype: false });
-        expect(Qs.parse(' foo = bar = baz ')).to.deep.equal({ ' foo ': ' bar = baz ' }, { prototype: false });
-        expect(Qs.parse('foo=bar=baz')).to.deep.equal({ foo: 'bar=baz' }, { prototype: false });
-        expect(Qs.parse('foo=bar&bar=baz')).to.deep.equal({ foo: 'bar', bar: 'baz' }, { prototype: false });
-        expect(Qs.parse('foo2=bar2&baz2=')).to.deep.equal({ foo2: 'bar2', baz2: '' }, { prototype: false });
-        expect(Qs.parse('foo=bar&baz', {strictNullHandling: true})).to.deep.equal({ foo: 'bar', baz: null }, { prototype: false });
-        expect(Qs.parse('foo=bar&baz')).to.deep.equal({ foo: 'bar', baz: '' }, { prototype: false });
+        expect(Qs.parse('0=foo')).to.deep.equal({ '0': 'foo' });
+        expect(Qs.parse('foo=c++')).to.deep.equal({ foo: 'c  ' });
+        expect(Qs.parse('a[>=]=23')).to.deep.equal({ a: { '>=': '23' } });
+        expect(Qs.parse('a[<=>]==23')).to.deep.equal({ a: { '<=>': '=23' } });
+        expect(Qs.parse('a[==]=23')).to.deep.equal({ a: { '==': '23' } });
+        expect(Qs.parse('foo', { strictNullHandling: true })).to.deep.equal({ foo: null });
+        expect(Qs.parse('foo' )).to.deep.equal({ foo: '' });
+        expect(Qs.parse('foo=')).to.deep.equal({ foo: '' });
+        expect(Qs.parse('foo=bar')).to.deep.equal({ foo: 'bar' });
+        expect(Qs.parse(' foo = bar = baz ')).to.deep.equal({ ' foo ': ' bar = baz ' });
+        expect(Qs.parse('foo=bar=baz')).to.deep.equal({ foo: 'bar=baz' });
+        expect(Qs.parse('foo=bar&bar=baz')).to.deep.equal({ foo: 'bar', bar: 'baz' });
+        expect(Qs.parse('foo2=bar2&baz2=')).to.deep.equal({ foo2: 'bar2', baz2: '' });
+        expect(Qs.parse('foo=bar&baz', { strictNullHandling: true })).to.deep.equal({ foo: 'bar', baz: null });
+        expect(Qs.parse('foo=bar&baz')).to.deep.equal({ foo: 'bar', baz: '' });
         expect(Qs.parse('cht=p3&chd=t:60,40&chs=250x100&chl=Hello|World')).to.deep.equal({
             cht: 'p3',
             chd: 't:60,40',
             chs: '250x100',
             chl: 'Hello|World'
-        }, { prototype: false });
+        });
         done();
     });
 
     it('allows disabling dot notation', function (done) {
 
-        expect(Qs.parse('a.b=c')).to.deep.equal({ a: { b: 'c' } }, { prototype: false });
-        expect(Qs.parse('a.b=c', { allowDots: false })).to.deep.equal({ 'a.b': 'c' }, { prototype: false });
+        expect(Qs.parse('a.b=c')).to.deep.equal({ a: { b: 'c' } });
+        expect(Qs.parse('a.b=c', { allowDots: false })).to.deep.equal({ 'a.b': 'c' });
         done();
     });
 
     it('parses a single nested string', function (done) {
 
-        expect(Qs.parse('a[b]=c')).to.deep.equal({ a: { b: 'c' } }, { prototype: false });
+        expect(Qs.parse('a[b]=c')).to.deep.equal({ a: { b: 'c' } });
         done();
     });
 
     it('parses a double nested string', function (done) {
 
-        expect(Qs.parse('a[b][c]=d')).to.deep.equal({ a: { b: { c: 'd' } } }, { prototype: false });
+        expect(Qs.parse('a[b][c]=d')).to.deep.equal({ a: { b: { c: 'd' } } });
         done();
     });
 
     it('defaults to a depth of 5', function (done) {
 
-        expect(Qs.parse('a[b][c][d][e][f][g][h]=i')).to.deep.equal({ a: { b: { c: { d: { e: { f: { '[g][h]': 'i' } } } } } } }, { prototype: false });
+        expect(Qs.parse('a[b][c][d][e][f][g][h]=i')).to.deep.equal({ a: { b: { c: { d: { e: { f: { '[g][h]': 'i' } } } } } } });
         done();
     });
 
     it('only parses one level when depth = 1', function (done) {
 
-        expect(Qs.parse('a[b][c]=d', { depth: 1 })).to.deep.equal({ a: { b: { '[c]': 'd' } } }, { prototype: false });
-        expect(Qs.parse('a[b][c][d]=e', { depth: 1 })).to.deep.equal({ a: { b: { '[c][d]': 'e' } } }, { prototype: false });
+        expect(Qs.parse('a[b][c]=d', { depth: 1 })).to.deep.equal({ a: { b: { '[c]': 'd' } } });
+        expect(Qs.parse('a[b][c][d]=e', { depth: 1 })).to.deep.equal({ a: { b: { '[c][d]': 'e' } } });
         done();
     });
 
     it('parses a simple array', function (done) {
 
-        expect(Qs.parse('a=b&a=c')).to.deep.equal({ a: ['b', 'c'] }, { prototype: false });
+        expect(Qs.parse('a=b&a=c')).to.deep.equal({ a: ['b', 'c'] });
         done();
     });
 
     it('parses an explicit array', function (done) {
 
-        expect(Qs.parse('a[]=b')).to.deep.equal({ a: ['b'] }, { prototype: false });
-        expect(Qs.parse('a[]=b&a[]=c')).to.deep.equal({ a: ['b', 'c'] }, { prototype: false });
-        expect(Qs.parse('a[]=b&a[]=c&a[]=d')).to.deep.equal({ a: ['b', 'c', 'd'] }, { prototype: false });
+        expect(Qs.parse('a[]=b')).to.deep.equal({ a: ['b'] });
+        expect(Qs.parse('a[]=b&a[]=c')).to.deep.equal({ a: ['b', 'c'] });
+        expect(Qs.parse('a[]=b&a[]=c&a[]=d')).to.deep.equal({ a: ['b', 'c', 'd'] });
         done();
     });
 
     it('parses a mix of simple and explicit arrays', function (done) {
 
-        expect(Qs.parse('a=b&a[]=c')).to.deep.equal({ a: ['b', 'c'] }, { prototype: false });
-        expect(Qs.parse('a[]=b&a=c')).to.deep.equal({ a: ['b', 'c'] }, { prototype: false });
-        expect(Qs.parse('a[0]=b&a=c')).to.deep.equal({ a: ['b', 'c'] }, { prototype: false });
-        expect(Qs.parse('a=b&a[0]=c')).to.deep.equal({ a: ['b', 'c'] }, { prototype: false });
-        expect(Qs.parse('a[1]=b&a=c')).to.deep.equal({ a: ['b', 'c'] }, { prototype: false });
-        expect(Qs.parse('a=b&a[1]=c')).to.deep.equal({ a: ['b', 'c'] }, { prototype: false });
+        expect(Qs.parse('a=b&a[]=c')).to.deep.equal({ a: ['b', 'c'] });
+        expect(Qs.parse('a[]=b&a=c')).to.deep.equal({ a: ['b', 'c'] });
+        expect(Qs.parse('a[0]=b&a=c')).to.deep.equal({ a: ['b', 'c'] });
+        expect(Qs.parse('a=b&a[0]=c')).to.deep.equal({ a: ['b', 'c'] });
+        expect(Qs.parse('a[1]=b&a=c')).to.deep.equal({ a: ['b', 'c'] });
+        expect(Qs.parse('a=b&a[1]=c')).to.deep.equal({ a: ['b', 'c'] });
         done();
     });
 
     it('parses a nested array', function (done) {
 
-        expect(Qs.parse('a[b][]=c&a[b][]=d')).to.deep.equal({ a: { b: ['c', 'd'] } }, { prototype: false });
-        expect(Qs.parse('a[>=]=25')).to.deep.equal({ a: { '>=': '25' } }, { prototype: false });
+        expect(Qs.parse('a[b][]=c&a[b][]=d')).to.deep.equal({ a: { b: ['c', 'd'] } });
+        expect(Qs.parse('a[>=]=25')).to.deep.equal({ a: { '>=': '25' } });
         done();
     });
 
     it('allows to specify array indices', function (done) {
 
-        expect(Qs.parse('a[1]=c&a[0]=b&a[2]=d')).to.deep.equal({ a: ['b', 'c', 'd'] }, { prototype: false });
-        expect(Qs.parse('a[1]=c&a[0]=b')).to.deep.equal({ a: ['b', 'c'] }, { prototype: false });
-        expect(Qs.parse('a[1]=c')).to.deep.equal({ a: ['c'] }, { prototype: false });
+        expect(Qs.parse('a[1]=c&a[0]=b&a[2]=d')).to.deep.equal({ a: ['b', 'c', 'd'] });
+        expect(Qs.parse('a[1]=c&a[0]=b')).to.deep.equal({ a: ['b', 'c'] });
+        expect(Qs.parse('a[1]=c')).to.deep.equal({ a: ['c'] });
         done();
     });
 
     it('limits specific array indices to 20', function (done) {
 
-        expect(Qs.parse('a[20]=a')).to.deep.equal({ a: ['a'] }, { prototype: false });
-        expect(Qs.parse('a[21]=a')).to.deep.equal({ a: { '21': 'a' } }, { prototype: false });
+        expect(Qs.parse('a[20]=a')).to.deep.equal({ a: ['a'] });
+        expect(Qs.parse('a[21]=a')).to.deep.equal({ a: { '21': 'a' } });
         done();
     });
 
     it('supports keys that begin with a number', function (done) {
 
-        expect(Qs.parse('a[12b]=c')).to.deep.equal({ a: { '12b': 'c' } }, { prototype: false });
+        expect(Qs.parse('a[12b]=c')).to.deep.equal({ a: { '12b': 'c' } });
         done();
     });
 
     it('supports encoded = signs', function (done) {
 
-        expect(Qs.parse('he%3Dllo=th%3Dere')).to.deep.equal({ 'he=llo': 'th=ere' }, { prototype: false });
+        expect(Qs.parse('he%3Dllo=th%3Dere')).to.deep.equal({ 'he=llo': 'th=ere' });
         done();
     });
 
     it('is ok with url encoded strings', function (done) {
 
-        expect(Qs.parse('a[b%20c]=d')).to.deep.equal({ a: { 'b c': 'd' } }, { prototype: false });
-        expect(Qs.parse('a[b]=c%20d')).to.deep.equal({ a: { b: 'c d' } }, { prototype: false });
+        expect(Qs.parse('a[b%20c]=d')).to.deep.equal({ a: { 'b c': 'd' } });
+        expect(Qs.parse('a[b]=c%20d')).to.deep.equal({ a: { b: 'c d' } });
         done();
     });
 
     it('allows brackets in the value', function (done) {
 
-        expect(Qs.parse('pets=["tobi"]')).to.deep.equal({ pets: '["tobi"]' }, { prototype: false });
-        expect(Qs.parse('operators=[">=", "<="]')).to.deep.equal({ operators: '[">=", "<="]' }, { prototype: false });
+        expect(Qs.parse('pets=["tobi"]')).to.deep.equal({ pets: '["tobi"]' });
+        expect(Qs.parse('operators=[">=", "<="]')).to.deep.equal({ operators: '[">=", "<="]' });
         done();
     });
 
     it('allows empty values', function (done) {
 
-        expect(Qs.parse('')).to.deep.equal({}, { prototype: false });
-        expect(Qs.parse(null)).to.deep.equal({}, { prototype: false });
-        expect(Qs.parse(undefined)).to.deep.equal({}, { prototype: false });
+        expect(Qs.parse('')).to.deep.equal({});
+        expect(Qs.parse(null)).to.deep.equal({});
+        expect(Qs.parse(undefined)).to.deep.equal({});
         done();
     });
 
     it('transforms arrays to objects', function (done) {
 
-        expect(Qs.parse('foo[0]=bar&foo[bad]=baz')).to.deep.equal({ foo: { '0': 'bar', bad: 'baz' } }, { prototype: false });
-        expect(Qs.parse('foo[bad]=baz&foo[0]=bar')).to.deep.equal({ foo: { bad: 'baz', '0': 'bar' } }, { prototype: false });
-        expect(Qs.parse('foo[bad]=baz&foo[]=bar')).to.deep.equal({ foo: { bad: 'baz', '0': 'bar' } }, { prototype: false });
-        expect(Qs.parse('foo[]=bar&foo[bad]=baz')).to.deep.equal({ foo: { '0': 'bar', bad: 'baz' } }, { prototype: false });
-        expect(Qs.parse('foo[bad]=baz&foo[]=bar&foo[]=foo')).to.deep.equal({ foo: { bad: 'baz', '0': 'bar', '1': 'foo' } }, { prototype: false });
-        expect(Qs.parse('foo[0][a]=a&foo[0][b]=b&foo[1][a]=aa&foo[1][b]=bb')).to.deep.equal({foo: [ {a: 'a', b: 'b'}, {a: 'aa', b: 'bb'} ]}, { prototype: false });
-        expect(Qs.parse('a[]=b&a[t]=u&a[hasOwnProperty]=c')).to.deep.equal({ a: { '0': 'b', t: 'u', hasOwnProperty: 'c' } }, { prototype: false });
-        expect(Qs.parse('a[]=b&a[hasOwnProperty]=c&a[x]=y')).to.deep.equal({ a: { '0': 'b', hasOwnProperty: 'c', x: 'y' } }, { prototype: false });
+        expect(Qs.parse('foo[0]=bar&foo[bad]=baz')).to.deep.equal({ foo: { '0': 'bar', bad: 'baz' } });
+        expect(Qs.parse('foo[bad]=baz&foo[0]=bar')).to.deep.equal({ foo: { bad: 'baz', '0': 'bar' } });
+        expect(Qs.parse('foo[bad]=baz&foo[]=bar')).to.deep.equal({ foo: { bad: 'baz', '0': 'bar' } });
+        expect(Qs.parse('foo[]=bar&foo[bad]=baz')).to.deep.equal({ foo: { '0': 'bar', bad: 'baz' } });
+        expect(Qs.parse('foo[bad]=baz&foo[]=bar&foo[]=foo')).to.deep.equal({ foo: { bad: 'baz', '0': 'bar', '1': 'foo' } });
+        expect(Qs.parse('foo[0][a]=a&foo[0][b]=b&foo[1][a]=aa&foo[1][b]=bb')).to.deep.equal({ foo: [{ a: 'a', b: 'b' }, { a: 'aa', b: 'bb' }] });
+        expect(Qs.parse('a[]=b&a[t]=u&a[hasOwnProperty]=c')).to.deep.equal({ a: { '0': 'b', t: 'u', c: true } });
+        expect(Qs.parse('a[]=b&a[hasOwnProperty]=c&a[x]=y')).to.deep.equal({ a: { '0': 'b', '1': 'c', x: 'y' } });
         done();
     });
 
     it('transforms arrays to objects (dot notation)', function (done) {
 
-        expect(Qs.parse('foo[0].baz=bar&fool.bad=baz')).to.deep.equal({ foo: [ { baz: 'bar'} ], fool: { bad: 'baz' } }, { prototype: false });
-        expect(Qs.parse('foo[0].baz=bar&fool.bad.boo=baz')).to.deep.equal({ foo: [ { baz: 'bar'} ], fool: { bad: { boo: 'baz' } } }, { prototype: false });
-        expect(Qs.parse('foo[0][0].baz=bar&fool.bad=baz')).to.deep.equal({ foo: [[ { baz: 'bar'} ]], fool: { bad: 'baz' } }, { prototype: false });
-        expect(Qs.parse('foo[0].baz[0]=15&foo[0].bar=2')).to.deep.equal({ foo: [{ baz: ['15'], bar: '2' }] }, { prototype: false });
-        expect(Qs.parse('foo[0].baz[0]=15&foo[0].baz[1]=16&foo[0].bar=2')).to.deep.equal({ foo: [{ baz: ['15', '16'], bar: '2' }] }, { prototype: false });
-        expect(Qs.parse('foo.bad=baz&foo[0]=bar')).to.deep.equal({ foo: { bad: 'baz', '0': 'bar' } }, { prototype: false });
-        expect(Qs.parse('foo.bad=baz&foo[]=bar')).to.deep.equal({ foo: { bad: 'baz', '0': 'bar' } }, { prototype: false });
-        expect(Qs.parse('foo[]=bar&foo.bad=baz')).to.deep.equal({ foo: { '0': 'bar', bad: 'baz' } }, { prototype: false });
-        expect(Qs.parse('foo.bad=baz&foo[]=bar&foo[]=foo')).to.deep.equal({ foo: { bad: 'baz', '0': 'bar', '1': 'foo' } }, { prototype: false });
-        expect(Qs.parse('foo[0].a=a&foo[0].b=b&foo[1].a=aa&foo[1].b=bb')).to.deep.equal({foo: [ {a: 'a', b: 'b'}, {a: 'aa', b: 'bb'} ]}, { prototype: false });
+        expect(Qs.parse('foo[0].baz=bar&fool.bad=baz')).to.deep.equal({ foo: [{ baz: 'bar' }], fool: { bad: 'baz' } });
+        expect(Qs.parse('foo[0].baz=bar&fool.bad.boo=baz')).to.deep.equal({ foo: [{ baz: 'bar' }], fool: { bad: { boo: 'baz' } } });
+        expect(Qs.parse('foo[0][0].baz=bar&fool.bad=baz')).to.deep.equal({ foo: [[{ baz: 'bar' }]], fool: { bad: 'baz' } });
+        expect(Qs.parse('foo[0].baz[0]=15&foo[0].bar=2')).to.deep.equal({ foo: [{ baz: ['15'], bar: '2' }] });
+        expect(Qs.parse('foo[0].baz[0]=15&foo[0].baz[1]=16&foo[0].bar=2')).to.deep.equal({ foo: [{ baz: ['15', '16'], bar: '2' }] });
+        expect(Qs.parse('foo.bad=baz&foo[0]=bar')).to.deep.equal({ foo: { bad: 'baz', '0': 'bar' } });
+        expect(Qs.parse('foo.bad=baz&foo[]=bar')).to.deep.equal({ foo: { bad: 'baz', '0': 'bar' } });
+        expect(Qs.parse('foo[]=bar&foo.bad=baz')).to.deep.equal({ foo: { '0': 'bar', bad: 'baz' } });
+        expect(Qs.parse('foo.bad=baz&foo[]=bar&foo[]=foo')).to.deep.equal({ foo: { bad: 'baz', '0': 'bar', '1': 'foo' } });
+        expect(Qs.parse('foo[0].a=a&foo[0].b=b&foo[1].a=aa&foo[1].b=bb')).to.deep.equal({ foo: [{ a: 'a', b: 'b' }, { a: 'aa', b: 'bb' }] });
         done();
     });
 
     it('can add keys to objects', function (done) {
 
-        expect(Qs.parse('a[b]=c&a=d')).to.deep.equal({ a: { b: 'c', d: true } }, { prototype: false });
+        expect(Qs.parse('a[b]=c&a=d')).to.deep.equal({ a: { b: 'c', d: true } });
         done();
     });
 
     it('correctly prunes undefined values when converting an array to an object', function (done) {
 
-        expect(Qs.parse('a[2]=b&a[99999999]=c')).to.deep.equal({ a: { '2': 'b', '99999999': 'c' } }, { prototype: false });
+        expect(Qs.parse('a[2]=b&a[99999999]=c')).to.deep.equal({ a: { '2': 'b', '99999999': 'c' } });
         done();
     });
 
     it('supports malformed uri characters', function (done) {
 
-        expect(Qs.parse('{%:%}', {strictNullHandling: true})).to.deep.equal({ '{%:%}': null }, { prototype: false });
-        expect(Qs.parse('{%:%}=')).to.deep.equal({ '{%:%}': '' }, { prototype: false });
-        expect(Qs.parse('foo=%:%}')).to.deep.equal({ foo: '%:%}' }, { prototype: false });
+        expect(Qs.parse('{%:%}', { strictNullHandling: true })).to.deep.equal({ '{%:%}': null });
+        expect(Qs.parse('{%:%}=')).to.deep.equal({ '{%:%}': '' });
+        expect(Qs.parse('foo=%:%}')).to.deep.equal({ foo: '%:%}' });
         done();
     });
 
     it('doesn\'t produce empty keys', function (done) {
 
-        expect(Qs.parse('_r=1&')).to.deep.equal({ '_r': '1' }, { prototype: false });
+        expect(Qs.parse('_r=1&')).to.deep.equal({ '_r': '1' });
         done();
     });
 
@@ -224,45 +224,45 @@ describe('parse()', function () {
 
     it('parses arrays of objects', function (done) {
 
-        expect(Qs.parse('a[][b]=c')).to.deep.equal({ a: [{ b: 'c' }] }, { prototype: false });
-        expect(Qs.parse('a[0][b]=c')).to.deep.equal({ a: [{ b: 'c' }] }, { prototype: false });
+        expect(Qs.parse('a[][b]=c')).to.deep.equal({ a: [{ b: 'c' }] });
+        expect(Qs.parse('a[0][b]=c')).to.deep.equal({ a: [{ b: 'c' }] });
         done();
     });
 
     it('allows for empty strings in arrays', function (done) {
 
-        expect(Qs.parse('a[]=b&a[]=&a[]=c')).to.deep.equal({ a: ['b', '', 'c'] }, { prototype: false });
-        expect(Qs.parse('a[0]=b&a[1]&a[2]=c&a[19]=', {strictNullHandling: true})).to.deep.equal({ a: ['b', null, 'c', ''] }, { prototype: false });
-        expect(Qs.parse('a[0]=b&a[1]=&a[2]=c&a[19]', {strictNullHandling: true})).to.deep.equal({ a: ['b', '', 'c', null] }, { prototype: false });
-        expect(Qs.parse('a[]=&a[]=b&a[]=c')).to.deep.equal({ a: ['', 'b', 'c'] }, { prototype: false });
+        expect(Qs.parse('a[]=b&a[]=&a[]=c')).to.deep.equal({ a: ['b', '', 'c'] });
+        expect(Qs.parse('a[0]=b&a[1]&a[2]=c&a[19]=', { strictNullHandling: true })).to.deep.equal({ a: ['b', null, 'c', ''] });
+        expect(Qs.parse('a[0]=b&a[1]=&a[2]=c&a[19]', { strictNullHandling: true })).to.deep.equal({ a: ['b', '', 'c', null] });
+        expect(Qs.parse('a[]=&a[]=b&a[]=c')).to.deep.equal({ a: ['', 'b', 'c'] });
         done();
     });
 
     it('compacts sparse arrays', function (done) {
 
-        expect(Qs.parse('a[10]=1&a[2]=2')).to.deep.equal({ a: ['2', '1'] }, { prototype: false });
+        expect(Qs.parse('a[10]=1&a[2]=2')).to.deep.equal({ a: ['2', '1'] });
         done();
     });
 
     it('parses semi-parsed strings', function (done) {
 
-        expect(Qs.parse({ 'a[b]': 'c' })).to.deep.equal({ a: { b: 'c' } }, { prototype: false });
-        expect(Qs.parse({ 'a[b]': 'c', 'a[d]': 'e' })).to.deep.equal({ a: { b: 'c', d: 'e' } }, { prototype: false });
+        expect(Qs.parse({ 'a[b]': 'c' })).to.deep.equal({ a: { b: 'c' } });
+        expect(Qs.parse({ 'a[b]': 'c', 'a[d]': 'e' })).to.deep.equal({ a: { b: 'c', d: 'e' } });
         done();
     });
 
     it('parses buffers correctly', function (done) {
 
         var b = new Buffer('test');
-        expect(Qs.parse({ a: b })).to.deep.equal({ a: b }, { prototype: false });
+        expect(Qs.parse({ a: b })).to.deep.equal({ a: b });
         done();
     });
 
     it('continues parsing when no parent is found', function (done) {
 
-        expect(Qs.parse('[]=&a=b')).to.deep.equal({ '0': '', a: 'b' }, { prototype: false });
-        expect(Qs.parse('[]&a=b', {strictNullHandling: true})).to.deep.equal({ '0': null, a: 'b' }, { prototype: false });
-        expect(Qs.parse('[foo]=bar')).to.deep.equal({ foo: 'bar' }, { prototype: false });
+        expect(Qs.parse('[]=&a=b')).to.deep.equal({ '0': '', a: 'b' });
+        expect(Qs.parse('[]&a=b', { strictNullHandling: true })).to.deep.equal({ '0': null, a: 'b' });
+        expect(Qs.parse('[foo]=bar')).to.deep.equal({ foo: 'bar' });
         done();
     });
 
@@ -286,9 +286,9 @@ describe('parse()', function () {
         Object.prototype.crash = '';
         Array.prototype.crash = '';
         expect(Qs.parse.bind(null, 'a=b')).to.not.throw();
-        expect(Qs.parse('a=b')).to.deep.equal({ a: 'b' }, { prototype: false });
+        expect(Qs.parse('a=b')).to.deep.equal({ a: 'b' });
         expect(Qs.parse.bind(null, 'a[][b]=c')).to.not.throw();
-        expect(Qs.parse('a[][b]=c')).to.deep.equal({ a: [{ b: 'c' }] }, { prototype: false });
+        expect(Qs.parse('a[][b]=c')).to.deep.equal({ a: [{ b: 'c' }] });
         delete Object.prototype.crash;
         delete Array.prototype.crash;
         done();
@@ -296,105 +296,105 @@ describe('parse()', function () {
 
     it('parses a string with an alternative string delimiter', function (done) {
 
-        expect(Qs.parse('a=b;c=d', { delimiter: ';' })).to.deep.equal({ a: 'b', c: 'd' }, { prototype: false });
+        expect(Qs.parse('a=b;c=d', { delimiter: ';' })).to.deep.equal({ a: 'b', c: 'd' });
         done();
     });
 
     it('parses a string with an alternative RegExp delimiter', function (done) {
 
-        expect(Qs.parse('a=b; c=d', { delimiter: /[;,] */ })).to.deep.equal({ a: 'b', c: 'd' }, { prototype: false });
+        expect(Qs.parse('a=b; c=d', { delimiter: /[;,] */ })).to.deep.equal({ a: 'b', c: 'd' });
         done();
     });
 
     it('does not use non-splittable objects as delimiters', function (done) {
 
-        expect(Qs.parse('a=b&c=d', { delimiter: true })).to.deep.equal({ a: 'b', c: 'd' }, { prototype: false });
+        expect(Qs.parse('a=b&c=d', { delimiter: true })).to.deep.equal({ a: 'b', c: 'd' });
         done();
     });
 
     it('allows overriding parameter limit', function (done) {
 
-        expect(Qs.parse('a=b&c=d', { parameterLimit: 1 })).to.deep.equal({ a: 'b' }, { prototype: false });
+        expect(Qs.parse('a=b&c=d', { parameterLimit: 1 })).to.deep.equal({ a: 'b' });
         done();
     });
 
     it('allows setting the parameter limit to Infinity', function (done) {
 
-        expect(Qs.parse('a=b&c=d', { parameterLimit: Infinity })).to.deep.equal({ a: 'b', c: 'd' }, { prototype: false });
+        expect(Qs.parse('a=b&c=d', { parameterLimit: Infinity })).to.deep.equal({ a: 'b', c: 'd' });
         done();
     });
 
     it('allows overriding array limit', function (done) {
 
-        expect(Qs.parse('a[0]=b', { arrayLimit: -1 })).to.deep.equal({ a: { '0': 'b' } }, { prototype: false });
-        expect(Qs.parse('a[-1]=b', { arrayLimit: -1 })).to.deep.equal({ a: { '-1': 'b' } }, { prototype: false });
-        expect(Qs.parse('a[0]=b&a[1]=c', { arrayLimit: 0 })).to.deep.equal({ a: { '0': 'b', '1': 'c' } }, { prototype: false });
+        expect(Qs.parse('a[0]=b', { arrayLimit: -1 })).to.deep.equal({ a: { '0': 'b' } });
+        expect(Qs.parse('a[-1]=b', { arrayLimit: -1 })).to.deep.equal({ a: { '-1': 'b' } });
+        expect(Qs.parse('a[0]=b&a[1]=c', { arrayLimit: 0 })).to.deep.equal({ a: { '0': 'b', '1': 'c' } });
         done();
     });
 
     it('allows disabling array parsing', function (done) {
 
-        expect(Qs.parse('a[0]=b&a[1]=c', { parseArrays: false })).to.deep.equal({ a: { '0': 'b', '1': 'c' } }, { prototype: false });
+        expect(Qs.parse('a[0]=b&a[1]=c', { parseArrays: false })).to.deep.equal({ a: { '0': 'b', '1': 'c' } });
         done();
     });
 
     it('parses an object', function (done) {
 
         var input = {
-            'user[name]': {'pop[bob]': 3},
+            'user[name]': { 'pop[bob]': 3 },
             'user[email]': null
         };
 
         var expected = {
             'user': {
-                'name': {'pop[bob]': 3},
+                'name': { 'pop[bob]': 3 },
                 'email': null
             }
         };
 
         var result = Qs.parse(input);
 
-        expect(result).to.deep.equal(expected, { prototype: false });
+        expect(result).to.deep.equal(expected);
         done();
     });
 
     it('parses an object in dot notation', function (done) {
 
         var input = {
-            'user.name': {'pop[bob]': 3},
+            'user.name': { 'pop[bob]': 3 },
             'user.email.': null
         };
 
         var expected = {
             'user': {
-                'name': {'pop[bob]': 3},
+                'name': { 'pop[bob]': 3 },
                 'email': null
             }
         };
 
         var result = Qs.parse(input);
 
-        expect(result).to.deep.equal(expected, { prototype: false });
+        expect(result).to.deep.equal(expected);
         done();
     });
 
     it('parses an object and not child values', function (done) {
 
         var input = {
-            'user[name]': {'pop[bob]': { 'test': 3 }},
+            'user[name]': { 'pop[bob]': { 'test': 3 } },
             'user[email]': null
         };
 
         var expected = {
             'user': {
-                'name': {'pop[bob]': { 'test': 3 }},
+                'name': { 'pop[bob]': { 'test': 3 } },
                 'email': null
             }
         };
 
         var result = Qs.parse(input);
 
-        expect(result).to.deep.equal(expected, { prototype: false });
+        expect(result).to.deep.equal(expected);
         done();
     });
 
@@ -404,7 +404,7 @@ describe('parse()', function () {
         delete global.Buffer;
         var result = Qs.parse('a=b&c=d');
         global.Buffer = tempBuffer;
-        expect(result).to.deep.equal({ a: 'b', c: 'd' }, { prototype: false });
+        expect(result).to.deep.equal({ a: 'b', c: 'd' });
         done();
     });
 
@@ -423,7 +423,7 @@ describe('parse()', function () {
         expect(parsed).to.contain('foo');
         expect(parsed.foo).to.contain('bar', 'baz');
         expect(parsed.foo.bar).to.equal('baz');
-        expect(parsed.foo.baz).to.deep.equal(a, { prototype: false });
+        expect(parsed.foo.baz).to.deep.equal(a);
         done();
     });
 
@@ -432,24 +432,47 @@ describe('parse()', function () {
         var a = Object.create(null);
         a.b = 'c';
 
-        expect(Qs.parse(a)).to.deep.equal({ b: 'c' }, { prototype: false });
+        expect(Qs.parse(a)).to.deep.equal({ b: 'c' });
         var result = Qs.parse({ a: a });
         expect(result).to.contain('a');
-        expect(result.a).to.deep.equal(a, { prototype: false });
+        expect(result.a).to.deep.equal(a);
         done();
     });
 
     it('parses dates correctly', function (done) {
 
         var now = new Date();
-        expect(Qs.parse({ a: now })).to.deep.equal({ a: now }, { prototype: false });
+        expect(Qs.parse({ a: now })).to.deep.equal({ a: now });
         done();
     });
 
     it('parses regular expressions correctly', function (done) {
 
         var re = /^test$/;
-        expect(Qs.parse({ a: re })).to.deep.equal({ a: re }, { prototype: false });
+        expect(Qs.parse({ a: re })).to.deep.equal({ a: re });
+        done();
+    });
+
+    it('can allow overwriting prototype properties', function (done) {
+
+        expect(Qs.parse('a[hasOwnProperty]=b', { allowPrototypes: true })).to.deep.equal({ a: { hasOwnProperty: 'b' } }, { prototype: false });
+        expect(Qs.parse('hasOwnProperty=b', { allowPrototypes: true })).to.deep.equal({ hasOwnProperty: 'b' }, { prototype: false });
+        done();
+    });
+
+    it('can return plain objects', function (done) {
+
+        var expected = Object.create(null);
+        expected.a = Object.create(null);
+        expected.a.b = 'c';
+        expected.a.hasOwnProperty = 'd';
+        expect(Qs.parse('a[b]=c&a[hasOwnProperty]=d', { plainObjects: true })).to.deep.equal(expected);
+        expect(Qs.parse(null, { plainObjects: true })).to.deep.equal(Object.create(null));
+        var expectedArray = Object.create(null);
+        expectedArray.a = Object.create(null);
+        expectedArray.a['0'] = 'b';
+        expectedArray.a.c = 'd';
+        expect(Qs.parse('a[]=b&a[c]=d', { plainObjects: true })).to.deep.equal(expectedArray);
         done();
     });
 });
index 7a80c6c..48b7803 100644 (file)
@@ -111,14 +111,14 @@ describe('stringify()', function () {
     it('stringifies an empty value', function (done) {
 
         expect(Qs.stringify({ a: '' })).to.equal('a=');
-        expect(Qs.stringify({ a: null }, {strictNullHandling: true})).to.equal('a');
+        expect(Qs.stringify({ a: null }, { strictNullHandling: true })).to.equal('a');
 
         expect(Qs.stringify({ a: '', b: '' })).to.equal('a=&b=');
-        expect(Qs.stringify({ a: null, b: '' }, {strictNullHandling: true})).to.equal('a&b=');
+        expect(Qs.stringify({ a: null, b: '' }, { strictNullHandling: true })).to.equal('a&b=');
 
         expect(Qs.stringify({ a: { b: '' } })).to.equal('a%5Bb%5D=');
-        expect(Qs.stringify({ a: { b: null } }, {strictNullHandling: true})).to.equal('a%5Bb%5D');
-        expect(Qs.stringify({ a: { b: null } }, {strictNullHandling: false})).to.equal('a%5Bb%5D=');
+        expect(Qs.stringify({ a: { b: null } }, { strictNullHandling: true })).to.equal('a%5Bb%5D');
+        expect(Qs.stringify({ a: { b: null } }, { strictNullHandling: false })).to.equal('a%5Bb%5D=');
 
         done();
     });
@@ -155,8 +155,8 @@ describe('stringify()', function () {
 
         expect(Qs.stringify({ a: undefined })).to.equal('');
 
-        expect(Qs.stringify({ a: { b: undefined, c: null } }, {strictNullHandling: true})).to.equal('a%5Bc%5D');
-        expect(Qs.stringify({ a: { b: undefined, c: null } }, {strictNullHandling: false})).to.equal('a%5Bc%5D=');
+        expect(Qs.stringify({ a: { b: undefined, c: null } }, { strictNullHandling: true })).to.equal('a%5Bc%5D');
+        expect(Qs.stringify({ a: { b: undefined, c: null } }, { strictNullHandling: false })).to.equal('a%5Bc%5D=');
         expect(Qs.stringify({ a: { b: undefined, c: '' } })).to.equal('a%5Bc%5D=');
         done();
     });
@@ -184,7 +184,7 @@ describe('stringify()', function () {
     it('skips properties that are part of the object prototype', function (done) {
 
         Object.prototype.crash = 'test';
-        expect(Qs.stringify({ a: 'b'})).to.equal('a=b');
+        expect(Qs.stringify({ a: 'b' })).to.equal('a=b');
         expect(Qs.stringify({ a: { b: 'c' } })).to.equal('a%5Bb%5D=c');
         delete Object.prototype.crash;
         done();
@@ -224,8 +224,8 @@ describe('stringify()', function () {
     it('selects properties when filter=array', function (done) {
 
         expect(Qs.stringify({ a: 'b' }, { filter: ['a'] })).to.equal('a=b');
-        expect(Qs.stringify({ a: 1}, { filter: [] })).to.equal('');
-        expect(Qs.stringify({ a: { b: [1, 2, 3, 4], c: 'd' }, c: 'f' }, { filter: ['a', 'b', 0, 2]})).to.equal('a%5Bb%5D%5B0%5D=1&a%5Bb%5D%5B2%5D=3');
+        expect(Qs.stringify({ a: 1 }, { filter: [] })).to.equal('');
+        expect(Qs.stringify({ a: { b: [1, 2, 3, 4], c: 'd' }, c: 'f' }, { filter: ['a', 'b', 0, 2] })).to.equal('a%5Bb%5D%5B0%5D=1&a%5Bb%5D%5B2%5D=3');
         done();
 
     });
index 37b7bec..3b1373b 100644 (file)
   "license": "MIT",
   "readme": "# Decode streams into strings The Right Way(tm)\n\n```javascript\nvar fs   = require('fs')\nvar zlib = require('zlib')\nvar strs = require('stringstream')\n\nvar utf8Stream = fs.createReadStream('massiveLogFile.gz')\n  .pipe(zlib.createGunzip())\n  .pipe(strs('utf8'))\n```\n\nNo need to deal with `setEncoding()` weirdness, just compose streams\nlike they were supposed to be!\n\nHandles input and output encoding:\n\n```javascript\n// Stream from utf8 to hex to base64... Why not, ay.\nvar hex64Stream = fs.createReadStream('myFile')\n  .pipe(strs('utf8', 'hex'))\n  .pipe(strs('hex', 'base64'))\n```\n\nAlso deals with `base64` output correctly by aligning each emitted data\nchunk so that there are no dangling `=` characters:\n\n```javascript\nvar stream = fs.createReadStream('myFile').pipe(strs('base64'))\n\nvar base64Str = ''\n\nstream.on('data', function(data) { base64Str += data })\nstream.on('end', function() {\n  console.log('My base64 encoded file is: ' + base64Str) // Wouldn't work with setEncoding()\n  console.log('Original file is: ' + new Buffer(base64Str, 'base64'))\n})\n```\n",
   "readmeFilename": "README.md",
-  "bugs": {
-    "url": "https://github.com/mhart/StringStream/issues"
-  },
-  "homepage": "https://github.com/mhart/StringStream#readme",
   "_id": "stringstream@0.0.4",
+  "dist": {
+    "shasum": "0f0e3423f942960b5692ac324a57dd093bc41a92",
+    "tarball": "http://registry.npmjs.org/stringstream/-/stringstream-0.0.4.tgz"
+  },
+  "_npmVersion": "1.2.0",
+  "_npmUser": {
+    "name": "hichaelmart",
+    "email": "michael.hart.au@gmail.com"
+  },
+  "maintainers": [
+    {
+      "name": "hichaelmart",
+      "email": "michael.hart.au@gmail.com"
+    }
+  ],
+  "directories": {},
   "_shasum": "0f0e3423f942960b5692ac324a57dd093bc41a92",
   "_resolved": "https://registry.npmjs.org/stringstream/-/stringstream-0.0.4.tgz",
-  "_from": "stringstream@>=0.0.4 <0.1.0"
+  "_from": "stringstream@>=0.0.4 <0.1.0",
+  "bugs": {
+    "url": "https://github.com/mhart/StringStream/issues"
+  },
+  "homepage": "https://github.com/mhart/StringStream#readme"
 }
diff --git a/deps/npm/node_modules/request/node_modules/tunnel-agent/.jshintrc b/deps/npm/node_modules/request/node_modules/tunnel-agent/.jshintrc
deleted file mode 100644 (file)
index 4c1c8d4..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-{
-  "node": true,
-  "asi": true,
-  "laxcomma": true
-}
index c432d8d..0f3275a 100644 (file)
@@ -7,7 +7,7 @@
     "util",
     "utility"
   ],
-  "version": "2.58.0",
+  "version": "2.60.0",
   "author": {
     "name": "Mikeal Rogers",
     "email": "mikeal.rogers@gmail.com"
   },
   "main": "index.js",
   "dependencies": {
-    "bl": "~0.9.0",
-    "caseless": "~0.10.0",
-    "extend": "~2.0.1",
+    "bl": "~1.0.0",
+    "caseless": "~0.11.0",
+    "extend": "~3.0.0",
     "forever-agent": "~0.6.0",
     "form-data": "~1.0.0-rc1",
     "json-stringify-safe": "~5.0.0",
-    "mime-types": "~2.0.1",
+    "mime-types": "~2.1.2",
     "node-uuid": "~1.4.0",
-    "qs": "~3.1.0",
+    "qs": "~4.0.0",
     "tunnel-agent": "~0.4.0",
     "tough-cookie": ">=0.12.0",
     "http-signature": "~0.11.0",
     "oauth-sign": "~0.8.0",
-    "hawk": "~2.3.0",
+    "hawk": "~3.1.0",
     "aws-sign2": "~0.5.0",
     "stringstream": "~0.0.4",
     "combined-stream": "~1.0.1",
     "taper": "~0.4.0",
     "bluebird": "~2.9.21"
   },
-  "gitHead": "ab40f9e61f813f9cc68257c17621b7879561486c",
+  "gitHead": "af19cef3bc60e9151ffce5015d8ce3c0728d3aca",
   "homepage": "https://github.com/request/request#readme",
-  "_id": "request@2.58.0",
-  "_shasum": "b5f49c0b94aab7fad388612a1fb6ad03b6cc1580",
-  "_from": "request@>=2.58.0 <2.59.0",
-  "_npmVersion": "2.10.1",
-  "_nodeVersion": "0.12.4",
+  "_id": "request@2.60.0",
+  "_shasum": "498820957fcdded1d37749069610c85f61a29f2d",
+  "_from": "request@2.60.0",
+  "_npmVersion": "2.11.2",
+  "_nodeVersion": "0.12.6",
   "_npmUser": {
     "name": "simov",
     "email": "simeonvelichkov@gmail.com"
   },
+  "dist": {
+    "shasum": "498820957fcdded1d37749069610c85f61a29f2d",
+    "tarball": "http://registry.npmjs.org/request/-/request-2.60.0.tgz"
+  },
   "maintainers": [
     {
       "name": "mikeal",
       "email": "simeonvelichkov@gmail.com"
     }
   ],
-  "dist": {
-    "shasum": "b5f49c0b94aab7fad388612a1fb6ad03b6cc1580",
-    "tarball": "http://registry.npmjs.org/request/-/request-2.58.0.tgz"
-  },
   "directories": {},
-  "_resolved": "https://registry.npmjs.org/request/-/request-2.58.0.tgz",
-  "readme": "ERROR: No README data found!"
+  "_resolved": "https://registry.npmjs.org/request/-/request-2.60.0.tgz"
 }
index c032ea8..f3f5dd9 100644 (file)
@@ -31,6 +31,7 @@ var safeStringify = helpers.safeStringify
   , toBase64 = helpers.toBase64
   , defer = helpers.defer
   , copy = helpers.copy
+  , version = helpers.version
   , globalCookieJar = cookies.jar()
 
 
@@ -430,28 +431,24 @@ Request.prototype.init = function (options) {
     self.elapsedTime = self.elapsedTime || 0
   }
 
-  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
-      }
-    } else {
-      length = self.body.length
+  function setContentLength () {
+    if (!Buffer.isBuffer(self.body) && !Array.isArray(self.body)) {
+      self.body = new Buffer(self.body)
     }
-    if (length) {
-      if (!self.hasHeader('content-length')) {
+    if (!self.hasHeader('content-length')) {
+      var length = (Array.isArray(self.body))
+        ? self.body.reduce(function (a, b) {return a + b.length}, 0)
+        : self.body.length
+      if (length) {
         self.setHeader('content-length', length)
+      } else {
+        self.emit('error', new Error('Argument error, options.body.'))
       }
-    } else {
-      self.emit('error', new Error('Argument error, options.body.'))
     }
   }
+  if (self.body) {
+    setContentLength()
+  }
 
   if (options.oauth) {
     self.oauth(options.oauth)
@@ -481,7 +478,16 @@ Request.prototype.init = function (options) {
     if (options.agentClass) {
       self.agentClass = options.agentClass
     } else if (options.forever) {
-      self.agentClass = protocol === 'http:' ? ForeverAgent : ForeverAgent.SSL
+      var v = version()
+      // use ForeverAgent in node 0.10- only
+      if (v.major === 0 && v.minor <= 10) {
+        self.agentClass = protocol === 'http:' ? ForeverAgent : ForeverAgent.SSL
+      } else {
+        self.agent = new self.httpModule.Agent({
+          keepAlive: true,
+          maxSockets: (options.pool && options.pool.maxSockets) || Infinity
+        })
+      }
     } else {
       self.agentClass = self.httpModule.Agent
     }
@@ -541,6 +547,7 @@ Request.prototype.init = function (options) {
         self._multipart.body.pipe(self)
       }
       if (self.body) {
+        setContentLength()
         if (Array.isArray(self.body)) {
           self.body.forEach(function (part) {
             self.write(part)
@@ -566,7 +573,7 @@ Request.prototype.init = function (options) {
 
     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.setHeader(self._form.getHeaders(), true)
       self._form.getLength(function (err, length) {
         if (!err) {
           self.setHeader('content-length', length)
@@ -1145,7 +1152,9 @@ Request.prototype.qs = function (q, clobber) {
 Request.prototype.form = function (form) {
   var self = this
   if (form) {
-    self.setHeader('content-type', 'application/x-www-form-urlencoded')
+    if (!/^application\/x-www-form-urlencoded\b/.test(self.getHeader('content-type'))) {
+      self.setHeader('content-type', 'application/x-www-form-urlencoded')
+    }
     self.body = (typeof form === 'string')
       ? self._qs.rfc3986(form.toString('utf8'))
       : self._qs.stringify(form).toString('utf8')
index 58e7ac3..18659f6 100644 (file)
@@ -1,3 +1,5 @@
+[![Build Status](https://travis-ci.org/isaacs/rimraf.svg?branch=master)](https://travis-ci.org/isaacs/rimraf) [![Dependency Status](https://david-dm.org/isaacs/rimraf.svg)](https://david-dm.org/isaacs/rimraf) [![devDependency Status](https://david-dm.org/isaacs/rimraf/dev-status.svg)](https://david-dm.org/isaacs/rimraf#info=devDependencies)
+
 The [UNIX command](http://en.wikipedia.org/wiki/Rm_(Unix)) `rm -rf` for node.  
 
 Install with `npm install rimraf`, or just drop rimraf.js somewhere.
@@ -28,7 +30,7 @@ the async API.  It's better.
 ## CLI
 
 If installed with `npm install rimraf -g` it can be used as a global
-command `rimraf <path>` which is useful for cross platform support.
+command `rimraf <path> [<path> ...]` which is useful for cross platform support.
 
 ## mkdirp
 
diff --git a/deps/npm/node_modules/rimraf/node_modules/glob/README.md b/deps/npm/node_modules/rimraf/node_modules/glob/README.md
deleted file mode 100644 (file)
index 258257e..0000000
+++ /dev/null
@@ -1,369 +0,0 @@
-[![Build Status](https://travis-ci.org/isaacs/node-glob.svg?branch=master)](https://travis-ci.org/isaacs/node-glob/) [![Dependency Status](https://david-dm.org/isaacs/node-glob.svg)](https://david-dm.org/isaacs/node-glob) [![devDependency Status](https://david-dm.org/isaacs/node-glob/dev-status.svg)](https://david-dm.org/isaacs/node-glob#info=devDependencies) [![optionalDependency Status](https://david-dm.org/isaacs/node-glob/optional-status.svg)](https://david-dm.org/isaacs/node-glob#info=optionalDependencies)
-
-# Glob
-
-Match files using the patterns the shell uses, like stars and stuff.
-
-This is a glob implementation in JavaScript.  It uses the `minimatch`
-library to do its matching.
-
-![](oh-my-glob.gif)
-
-## Usage
-
-```javascript
-var glob = require("glob")
-
-// options is optional
-glob("**/*.js", options, function (er, files) {
-  // files is an array of filenames.
-  // If the `nonull` option is set, and nothing
-  // was found, then files is ["**/*.js"]
-  // er is an error object or null.
-})
-```
-
-## Glob Primer
-
-"Globs" are the patterns you type when you do stuff like `ls *.js` on
-the command line, or put `build/*` in a `.gitignore` file.
-
-Before parsing the path part patterns, braced sections are expanded
-into a set.  Braced sections start with `{` and end with `}`, with any
-number of comma-delimited sections within.  Braced sections may contain
-slash characters, so `a{/b/c,bcd}` would expand into `a/b/c` and `abcd`.
-
-The following characters have special magic meaning when used in a
-path portion:
-
-* `*` Matches 0 or more characters in a single path portion
-* `?` Matches 1 character
-* `[...]` Matches a range of characters, similar to a RegExp range.
-  If the first character of the range is `!` or `^` then it matches
-  any character not in the range.
-* `!(pattern|pattern|pattern)` Matches anything that does not match
-  any of the patterns provided.
-* `?(pattern|pattern|pattern)` Matches zero or one occurrence of the
-  patterns provided.
-* `+(pattern|pattern|pattern)` Matches one or more occurrences of the
-  patterns provided.
-* `*(a|b|c)` Matches zero or more occurrences of the patterns provided
-* `@(pattern|pat*|pat?erN)` Matches exactly one of the patterns
-  provided
-* `**` If a "globstar" is alone in a path portion, then it matches
-  zero or more directories and subdirectories searching for matches.
-  It does not crawl symlinked directories.
-
-### Dots
-
-If a file or directory path portion has a `.` as the first character,
-then it will not match any glob pattern unless that pattern's
-corresponding path part also has a `.` as its first character.
-
-For example, the pattern `a/.*/c` would match the file at `a/.b/c`.
-However the pattern `a/*/c` would not, because `*` does not start with
-a dot character.
-
-You can make glob treat dots as normal characters by setting
-`dot:true` in the options.
-
-### Basename Matching
-
-If you set `matchBase:true` in the options, and the pattern has no
-slashes in it, then it will seek for any file anywhere in the tree
-with a matching basename.  For example, `*.js` would match
-`test/simple/basic.js`.
-
-### Negation
-
-The intent for negation would be for a pattern starting with `!` to
-match everything that *doesn't* match the supplied pattern.  However,
-the implementation is weird, and for the time being, this should be
-avoided.  The behavior will change or be deprecated in version 5.
-
-### Empty Sets
-
-If no matching files are found, then an empty array is returned.  This
-differs from the shell, where the pattern itself is returned.  For
-example:
-
-    $ echo a*s*d*f
-    a*s*d*f
-
-To get the bash-style behavior, set the `nonull:true` in the options.
-
-### See Also:
-
-* `man sh`
-* `man bash` (Search for "Pattern Matching")
-* `man 3 fnmatch`
-* `man 5 gitignore`
-* [minimatch documentation](https://github.com/isaacs/minimatch)
-
-## glob.hasMagic(pattern, [options])
-
-Returns `true` if there are any special characters in the pattern, and
-`false` otherwise.
-
-Note that the options affect the results.  If `noext:true` is set in
-the options object, then `+(a|b)` will not be considered a magic
-pattern.  If the pattern has a brace expansion, like `a/{b/c,x/y}`
-then that is considered magical, unless `nobrace:true` is set in the
-options.
-
-## glob(pattern, [options], cb)
-
-* `pattern` {String} Pattern to be matched
-* `options` {Object}
-* `cb` {Function}
-  * `err` {Error | null}
-  * `matches` {Array<String>} filenames found matching the pattern
-
-Perform an asynchronous glob search.
-
-## glob.sync(pattern, [options])
-
-* `pattern` {String} Pattern to be matched
-* `options` {Object}
-* return: {Array<String>} filenames found matching the pattern
-
-Perform a synchronous glob search.
-
-## Class: glob.Glob
-
-Create a Glob object by instantiating the `glob.Glob` class.
-
-```javascript
-var Glob = require("glob").Glob
-var mg = new Glob(pattern, options, cb)
-```
-
-It's an EventEmitter, and starts walking the filesystem to find matches
-immediately.
-
-### new glob.Glob(pattern, [options], [cb])
-
-* `pattern` {String} pattern to search for
-* `options` {Object}
-* `cb` {Function} Called when an error occurs, or matches are found
-  * `err` {Error | null}
-  * `matches` {Array<String>} filenames found matching the pattern
-
-Note that if the `sync` flag is set in the options, then matches will
-be immediately available on the `g.found` member.
-
-### Properties
-
-* `minimatch` The minimatch object that the glob uses.
-* `options` The options object passed in.
-* `aborted` Boolean which is set to true when calling `abort()`.  There
-  is no way at this time to continue a glob search after aborting, but
-  you can re-use the statCache to avoid having to duplicate syscalls.
-* `statCache` Collection of all the stat results the glob search
-  performed.
-* `cache` Convenience object.  Each field has the following possible
-  values:
-  * `false` - Path does not exist
-  * `true` - Path exists
-  * `'DIR'` - Path exists, and is not a directory
-  * `'FILE'` - Path exists, and is a directory
-  * `[file, entries, ...]` - Path exists, is a directory, and the
-    array value is the results of `fs.readdir`
-* `statCache` Cache of `fs.stat` results, to prevent statting the same
-  path multiple times.
-* `symlinks` A record of which paths are symbolic links, which is
-  relevant in resolving `**` patterns.
-* `realpathCache` An optional object which is passed to `fs.realpath`
-  to minimize unnecessary syscalls.  It is stored on the instantiated
-  Glob object, and may be re-used.
-
-### Events
-
-* `end` When the matching is finished, this is emitted with all the
-  matches found.  If the `nonull` option is set, and no match was found,
-  then the `matches` list contains the original pattern.  The matches
-  are sorted, unless the `nosort` flag is set.
-* `match` Every time a match is found, this is emitted with the matched.
-* `error` Emitted when an unexpected error is encountered, or whenever
-  any fs error occurs if `options.strict` is set.
-* `abort` When `abort()` is called, this event is raised.
-
-### Methods
-
-* `pause` Temporarily stop the search
-* `resume` Resume the search
-* `abort` Stop the search forever
-
-### Options
-
-All the options that can be passed to Minimatch can also be passed to
-Glob to change pattern matching behavior.  Also, some have been added,
-or have glob-specific ramifications.
-
-All options are false by default, unless otherwise noted.
-
-All options are added to the Glob object, as well.
-
-If you are running many `glob` operations, you can pass a Glob object
-as the `options` argument to a subsequent operation to shortcut some
-`stat` and `readdir` calls.  At the very least, you may pass in shared
-`symlinks`, `statCache`, `realpathCache`, and `cache` options, so that
-parallel glob operations will be sped up by sharing information about
-the filesystem.
-
-* `cwd` The current working directory in which to search.  Defaults
-  to `process.cwd()`.
-* `root` The place where patterns starting with `/` will be mounted
-  onto.  Defaults to `path.resolve(options.cwd, "/")` (`/` on Unix
-  systems, and `C:\` or some such on Windows.)
-* `dot` Include `.dot` files in normal matches and `globstar` matches.
-  Note that an explicit dot in a portion of the pattern will always
-  match dot files.
-* `nomount` By default, a pattern starting with a forward-slash will be
-  "mounted" onto the root setting, so that a valid filesystem path is
-  returned.  Set this flag to disable that behavior.
-* `mark` Add a `/` character to directory matches.  Note that this
-  requires additional stat calls.
-* `nosort` Don't sort the results.
-* `stat` Set to true to stat *all* results.  This reduces performance
-  somewhat, and is completely unnecessary, unless `readdir` is presumed
-  to be an untrustworthy indicator of file existence.
-* `silent` When an unusual error is encountered when attempting to
-  read a directory, a warning will be printed to stderr.  Set the
-  `silent` option to true to suppress these warnings.
-* `strict` When an unusual error is encountered when attempting to
-  read a directory, the process will just continue on in search of
-  other matches.  Set the `strict` option to raise an error in these
-  cases.
-* `cache` See `cache` property above.  Pass in a previously generated
-  cache object to save some fs calls.
-* `statCache` A cache of results of filesystem information, to prevent
-  unnecessary stat calls.  While it should not normally be necessary
-  to set this, you may pass the statCache from one glob() call to the
-  options object of another, if you know that the filesystem will not
-  change between calls.  (See "Race Conditions" below.)
-* `symlinks` A cache of known symbolic links.  You may pass in a
-  previously generated `symlinks` object to save `lstat` calls when
-  resolving `**` matches.
-* `sync` DEPRECATED: use `glob.sync(pattern, opts)` instead.
-* `nounique` In some cases, brace-expanded patterns can result in the
-  same file showing up multiple times in the result set.  By default,
-  this implementation prevents duplicates in the result set.  Set this
-  flag to disable that behavior.
-* `nonull` Set to never return an empty set, instead returning a set
-  containing the pattern itself.  This is the default in glob(3).
-* `debug` Set to enable debug logging in minimatch and glob.
-* `nobrace` Do not expand `{a,b}` and `{1..3}` brace sets.
-* `noglobstar` Do not match `**` against multiple filenames.  (Ie,
-  treat it as a normal `*` instead.)
-* `noext` Do not match `+(a|b)` "extglob" patterns.
-* `nocase` Perform a case-insensitive match.  Note: on
-  case-insensitive filesystems, non-magic patterns will match by
-  default, since `stat` and `readdir` will not raise errors.
-* `matchBase` Perform a basename-only match if the pattern does not
-  contain any slash characters.  That is, `*.js` would be treated as
-  equivalent to `**/*.js`, matching all js files in all directories.
-* `nonegate` Suppress `negate` behavior.  (See below.)
-* `nocomment` Suppress `comment` behavior.  (See below.)
-* `nonull` Return the pattern when no matches are found.
-* `nodir` Do not match directories, only files.  (Note: to match
-  *only* directories, simply put a `/` at the end of the pattern.)
-* `ignore` Add a pattern or an array of patterns to exclude matches.
-* `follow` Follow symlinked directories when expanding `**` patterns.
-  Note that this can result in a lot of duplicate references in the
-  presence of cyclic links.
-* `realpath` Set to true to call `fs.realpath` on all of the results.
-  In the case of a symlink that cannot be resolved, the full absolute
-  path to the matched entry is returned (though it will usually be a
-  broken symlink)
-
-## Comparisons to other fnmatch/glob implementations
-
-While strict compliance with the existing standards is a worthwhile
-goal, some discrepancies exist between node-glob and other
-implementations, and are intentional.
-
-If the pattern starts with a `!` character, then it is negated.  Set the
-`nonegate` flag to suppress this behavior, and treat leading `!`
-characters normally.  This is perhaps relevant if you wish to start the
-pattern with a negative extglob pattern like `!(a|B)`.  Multiple `!`
-characters at the start of a pattern will negate the pattern multiple
-times.
-
-If a pattern starts with `#`, then it is treated as a comment, and
-will not match anything.  Use `\#` to match a literal `#` at the
-start of a line, or set the `nocomment` flag to suppress this behavior.
-
-The double-star character `**` is supported by default, unless the
-`noglobstar` flag is set.  This is supported in the manner of bsdglob
-and bash 4.3, where `**` only has special significance if it is the only
-thing in a path part.  That is, `a/**/b` will match `a/x/y/b`, but
-`a/**b` will not.
-
-Note that symlinked directories are not crawled as part of a `**`,
-though their contents may match against subsequent portions of the
-pattern.  This prevents infinite loops and duplicates and the like.
-
-If an escaped pattern has no matches, and the `nonull` flag is set,
-then glob returns the pattern as-provided, rather than
-interpreting the character escapes.  For example,
-`glob.match([], "\\*a\\?")` will return `"\\*a\\?"` rather than
-`"*a?"`.  This is akin to setting the `nullglob` option in bash, except
-that it does not resolve escaped pattern characters.
-
-If brace expansion is not disabled, then it is performed before any
-other interpretation of the glob pattern.  Thus, a pattern like
-`+(a|{b),c)}`, which would not be valid in bash or zsh, is expanded
-**first** into the set of `+(a|b)` and `+(a|c)`, and those patterns are
-checked for validity.  Since those two are valid, matching proceeds.
-
-## Windows
-
-**Please only use forward-slashes in glob expressions.**
-
-Though windows uses either `/` or `\` as its path separator, only `/`
-characters are used by this glob implementation.  You must use
-forward-slashes **only** in glob expressions.  Back-slashes will always
-be interpreted as escape characters, not path separators.
-
-Results from absolute patterns such as `/foo/*` are mounted onto the
-root setting using `path.join`.  On windows, this will by default result
-in `/foo/*` matching `C:\foo\bar.txt`.
-
-## Race Conditions
-
-Glob searching, by its very nature, is susceptible to race conditions,
-since it relies on directory walking and such.
-
-As a result, it is possible that a file that exists when glob looks for
-it may have been deleted or modified by the time it returns the result.
-
-As part of its internal implementation, this program caches all stat
-and readdir calls that it makes, in order to cut down on system
-overhead.  However, this also makes it even more susceptible to races,
-especially if the cache or statCache objects are reused between glob
-calls.
-
-Users are thus advised not to use a glob result as a guarantee of
-filesystem state in the face of rapid changes.  For the vast majority
-of operations, this is never a problem.
-
-## Contributing
-
-Any change to behavior (including bugfixes) must come with a test.
-
-Patches that fail tests or reduce performance will be rejected.
-
-```
-# to run tests
-npm test
-
-# to re-generate test fixtures
-npm run test-regen
-
-# to benchmark against bash/zsh
-npm run bench
-
-# to profile javascript
-npm run prof
-```
diff --git a/deps/npm/node_modules/rimraf/node_modules/glob/common.js b/deps/npm/node_modules/rimraf/node_modules/glob/common.js
deleted file mode 100644 (file)
index cd7c824..0000000
+++ /dev/null
@@ -1,237 +0,0 @@
-exports.alphasort = alphasort
-exports.alphasorti = alphasorti
-exports.isAbsolute = process.platform === "win32" ? absWin : absUnix
-exports.setopts = setopts
-exports.ownProp = ownProp
-exports.makeAbs = makeAbs
-exports.finish = finish
-exports.mark = mark
-exports.isIgnored = isIgnored
-exports.childrenIgnored = childrenIgnored
-
-function ownProp (obj, field) {
-  return Object.prototype.hasOwnProperty.call(obj, field)
-}
-
-var path = require("path")
-var minimatch = require("minimatch")
-var Minimatch = minimatch.Minimatch
-
-function absWin (p) {
-  if (absUnix(p)) return true
-  // pull off the device/UNC bit from a windows path.
-  // from node's lib/path.js
-  var splitDeviceRe =
-      /^([a-zA-Z]:|[\\\/]{2}[^\\\/]+[\\\/]+[^\\\/]+)?([\\\/])?([\s\S]*?)$/
-  var result = splitDeviceRe.exec(p)
-  var device = result[1] || ''
-  var isUnc = device && device.charAt(1) !== ':'
-  var isAbsolute = !!result[2] || isUnc // UNC paths are always absolute
-
-  return isAbsolute
-}
-
-function absUnix (p) {
-  return p.charAt(0) === "/" || p === ""
-}
-
-function alphasorti (a, b) {
-  return a.toLowerCase().localeCompare(b.toLowerCase())
-}
-
-function alphasort (a, b) {
-  return a.localeCompare(b)
-}
-
-function setupIgnores (self, options) {
-  self.ignore = options.ignore || []
-
-  if (!Array.isArray(self.ignore))
-    self.ignore = [self.ignore]
-
-  if (self.ignore.length) {
-    self.ignore = self.ignore.map(ignoreMap)
-  }
-}
-
-function ignoreMap (pattern) {
-  var gmatcher = null
-  if (pattern.slice(-3) === '/**') {
-    var gpattern = pattern.replace(/(\/\*\*)+$/, '')
-    gmatcher = new Minimatch(gpattern, { nonegate: true })
-  }
-
-  return {
-    matcher: new Minimatch(pattern, { nonegate: true }),
-    gmatcher: gmatcher
-  }
-}
-
-function setopts (self, pattern, options) {
-  if (!options)
-    options = {}
-
-  // base-matching: just use globstar for that.
-  if (options.matchBase && -1 === pattern.indexOf("/")) {
-    if (options.noglobstar) {
-      throw new Error("base matching requires globstar")
-    }
-    pattern = "**/" + pattern
-  }
-
-  self.pattern = pattern
-  self.strict = options.strict !== false
-  self.realpath = !!options.realpath
-  self.realpathCache = options.realpathCache || Object.create(null)
-  self.follow = !!options.follow
-  self.dot = !!options.dot
-  self.mark = !!options.mark
-  self.nodir = !!options.nodir
-  if (self.nodir)
-    self.mark = true
-  self.sync = !!options.sync
-  self.nounique = !!options.nounique
-  self.nonull = !!options.nonull
-  self.nosort = !!options.nosort
-  self.nocase = !!options.nocase
-  self.stat = !!options.stat
-  self.noprocess = !!options.noprocess
-
-  self.maxLength = options.maxLength || Infinity
-  self.cache = options.cache || Object.create(null)
-  self.statCache = options.statCache || Object.create(null)
-  self.symlinks = options.symlinks || Object.create(null)
-
-  setupIgnores(self, options)
-
-  self.changedCwd = false
-  var cwd = process.cwd()
-  if (!ownProp(options, "cwd"))
-    self.cwd = cwd
-  else {
-    self.cwd = options.cwd
-    self.changedCwd = path.resolve(options.cwd) !== cwd
-  }
-
-  self.root = options.root || path.resolve(self.cwd, "/")
-  self.root = path.resolve(self.root)
-  if (process.platform === "win32")
-    self.root = self.root.replace(/\\/g, "/")
-
-  self.nomount = !!options.nomount
-
-  self.minimatch = new Minimatch(pattern, options)
-  self.options = self.minimatch.options
-}
-
-function finish (self) {
-  var nou = self.nounique
-  var all = nou ? [] : Object.create(null)
-
-  for (var i = 0, l = self.matches.length; i < l; i ++) {
-    var matches = self.matches[i]
-    if (!matches || Object.keys(matches).length === 0) {
-      if (self.nonull) {
-        // do like the shell, and spit out the literal glob
-        var literal = self.minimatch.globSet[i]
-        if (nou)
-          all.push(literal)
-        else
-          all[literal] = true
-      }
-    } else {
-      // had matches
-      var m = Object.keys(matches)
-      if (nou)
-        all.push.apply(all, m)
-      else
-        m.forEach(function (m) {
-          all[m] = true
-        })
-    }
-  }
-
-  if (!nou)
-    all = Object.keys(all)
-
-  if (!self.nosort)
-    all = all.sort(self.nocase ? alphasorti : alphasort)
-
-  // at *some* point we statted all of these
-  if (self.mark) {
-    for (var i = 0; i < all.length; i++) {
-      all[i] = self._mark(all[i])
-    }
-    if (self.nodir) {
-      all = all.filter(function (e) {
-        return !(/\/$/.test(e))
-      })
-    }
-  }
-
-  if (self.ignore.length)
-    all = all.filter(function(m) {
-      return !isIgnored(self, m)
-    })
-
-  self.found = all
-}
-
-function mark (self, p) {
-  var abs = makeAbs(self, p)
-  var c = self.cache[abs]
-  var m = p
-  if (c) {
-    var isDir = c === 'DIR' || Array.isArray(c)
-    var slash = p.slice(-1) === '/'
-
-    if (isDir && !slash)
-      m += '/'
-    else if (!isDir && slash)
-      m = m.slice(0, -1)
-
-    if (m !== p) {
-      var mabs = makeAbs(self, m)
-      self.statCache[mabs] = self.statCache[abs]
-      self.cache[mabs] = self.cache[abs]
-    }
-  }
-
-  return m
-}
-
-// lotta situps...
-function makeAbs (self, f) {
-  var abs = f
-  if (f.charAt(0) === '/') {
-    abs = path.join(self.root, f)
-  } else if (exports.isAbsolute(f)) {
-    abs = f
-  } else if (self.changedCwd) {
-    abs = path.resolve(self.cwd, f)
-  } else if (self.realpath) {
-    abs = path.resolve(f)
-  }
-  return abs
-}
-
-
-// Return true, if pattern ends with globstar '**', for the accompanying parent directory.
-// Ex:- If node_modules/** is the pattern, add 'node_modules' to ignore list along with it's contents
-function isIgnored (self, path) {
-  if (!self.ignore.length)
-    return false
-
-  return self.ignore.some(function(item) {
-    return item.matcher.match(path) || !!(item.gmatcher && item.gmatcher.match(path))
-  })
-}
-
-function childrenIgnored (self, path) {
-  if (!self.ignore.length)
-    return false
-
-  return self.ignore.some(function(item) {
-    return !!(item.gmatcher && item.gmatcher.match(path))
-  })
-}
diff --git a/deps/npm/node_modules/rimraf/node_modules/glob/glob.js b/deps/npm/node_modules/rimraf/node_modules/glob/glob.js
deleted file mode 100644 (file)
index eac0693..0000000
+++ /dev/null
@@ -1,740 +0,0 @@
-// Approach:
-//
-// 1. Get the minimatch set
-// 2. For each pattern in the set, PROCESS(pattern, false)
-// 3. Store matches per-set, then uniq them
-//
-// PROCESS(pattern, inGlobStar)
-// Get the first [n] items from pattern that are all strings
-// Join these together.  This is PREFIX.
-//   If there is no more remaining, then stat(PREFIX) and
-//   add to matches if it succeeds.  END.
-//
-// If inGlobStar and PREFIX is symlink and points to dir
-//   set ENTRIES = []
-// else readdir(PREFIX) as ENTRIES
-//   If fail, END
-//
-// with ENTRIES
-//   If pattern[n] is GLOBSTAR
-//     // handle the case where the globstar match is empty
-//     // by pruning it out, and testing the resulting pattern
-//     PROCESS(pattern[0..n] + pattern[n+1 .. $], false)
-//     // handle other cases.
-//     for ENTRY in ENTRIES (not dotfiles)
-//       // attach globstar + tail onto the entry
-//       // Mark that this entry is a globstar match
-//       PROCESS(pattern[0..n] + ENTRY + pattern[n .. $], true)
-//
-//   else // not globstar
-//     for ENTRY in ENTRIES (not dotfiles, unless pattern[n] is dot)
-//       Test ENTRY against pattern[n]
-//       If fails, continue
-//       If passes, PROCESS(pattern[0..n] + item + pattern[n+1 .. $])
-//
-// Caveat:
-//   Cache all stats and readdirs results to minimize syscall.  Since all
-//   we ever care about is existence and directory-ness, we can just keep
-//   `true` for files, and [children,...] for directories, or `false` for
-//   things that don't exist.
-
-module.exports = glob
-
-var fs = require('fs')
-var minimatch = require('minimatch')
-var Minimatch = minimatch.Minimatch
-var inherits = require('inherits')
-var EE = require('events').EventEmitter
-var path = require('path')
-var assert = require('assert')
-var globSync = require('./sync.js')
-var common = require('./common.js')
-var alphasort = common.alphasort
-var alphasorti = common.alphasorti
-var isAbsolute = common.isAbsolute
-var setopts = common.setopts
-var ownProp = common.ownProp
-var inflight = require('inflight')
-var util = require('util')
-var childrenIgnored = common.childrenIgnored
-
-var once = require('once')
-
-function glob (pattern, options, cb) {
-  if (typeof options === 'function') cb = options, options = {}
-  if (!options) options = {}
-
-  if (options.sync) {
-    if (cb)
-      throw new TypeError('callback provided to sync glob')
-    return globSync(pattern, options)
-  }
-
-  return new Glob(pattern, options, cb)
-}
-
-glob.sync = globSync
-var GlobSync = glob.GlobSync = globSync.GlobSync
-
-// old api surface
-glob.glob = glob
-
-glob.hasMagic = function (pattern, options_) {
-  var options = util._extend({}, options_)
-  options.noprocess = true
-
-  var g = new Glob(pattern, options)
-  var set = g.minimatch.set
-  if (set.length > 1)
-    return true
-
-  for (var j = 0; j < set[0].length; j++) {
-    if (typeof set[0][j] !== 'string')
-      return true
-  }
-
-  return false
-}
-
-glob.Glob = Glob
-inherits(Glob, EE)
-function Glob (pattern, options, cb) {
-  if (typeof options === 'function') {
-    cb = options
-    options = null
-  }
-
-  if (options && options.sync) {
-    if (cb)
-      throw new TypeError('callback provided to sync glob')
-    return new GlobSync(pattern, options)
-  }
-
-  if (!(this instanceof Glob))
-    return new Glob(pattern, options, cb)
-
-  setopts(this, pattern, options)
-  this._didRealPath = false
-
-  // process each pattern in the minimatch set
-  var n = this.minimatch.set.length
-
-  // The matches are stored as {<filename>: true,...} so that
-  // duplicates are automagically pruned.
-  // Later, we do an Object.keys() on these.
-  // Keep them as a list so we can fill in when nonull is set.
-  this.matches = new Array(n)
-
-  if (typeof cb === 'function') {
-    cb = once(cb)
-    this.on('error', cb)
-    this.on('end', function (matches) {
-      cb(null, matches)
-    })
-  }
-
-  var self = this
-  var n = this.minimatch.set.length
-  this._processing = 0
-  this.matches = new Array(n)
-
-  this._emitQueue = []
-  this._processQueue = []
-  this.paused = false
-
-  if (this.noprocess)
-    return this
-
-  if (n === 0)
-    return done()
-
-  for (var i = 0; i < n; i ++) {
-    this._process(this.minimatch.set[i], i, false, done)
-  }
-
-  function done () {
-    --self._processing
-    if (self._processing <= 0)
-      self._finish()
-  }
-}
-
-Glob.prototype._finish = function () {
-  assert(this instanceof Glob)
-  if (this.aborted)
-    return
-
-  if (this.realpath && !this._didRealpath)
-    return this._realpath()
-
-  common.finish(this)
-  this.emit('end', this.found)
-}
-
-Glob.prototype._realpath = function () {
-  if (this._didRealpath)
-    return
-
-  this._didRealpath = true
-
-  var n = this.matches.length
-  if (n === 0)
-    return this._finish()
-
-  var self = this
-  for (var i = 0; i < this.matches.length; i++)
-    this._realpathSet(i, next)
-
-  function next () {
-    if (--n === 0)
-      self._finish()
-  }
-}
-
-Glob.prototype._realpathSet = function (index, cb) {
-  var matchset = this.matches[index]
-  if (!matchset)
-    return cb()
-
-  var found = Object.keys(matchset)
-  var self = this
-  var n = found.length
-
-  if (n === 0)
-    return cb()
-
-  var set = this.matches[index] = Object.create(null)
-  found.forEach(function (p, i) {
-    // If there's a problem with the stat, then it means that
-    // one or more of the links in the realpath couldn't be
-    // resolved.  just return the abs value in that case.
-    p = self._makeAbs(p)
-    fs.realpath(p, self.realpathCache, function (er, real) {
-      if (!er)
-        set[real] = true
-      else if (er.syscall === 'stat')
-        set[p] = true
-      else
-        self.emit('error', er) // srsly wtf right here
-
-      if (--n === 0) {
-        self.matches[index] = set
-        cb()
-      }
-    })
-  })
-}
-
-Glob.prototype._mark = function (p) {
-  return common.mark(this, p)
-}
-
-Glob.prototype._makeAbs = function (f) {
-  return common.makeAbs(this, f)
-}
-
-Glob.prototype.abort = function () {
-  this.aborted = true
-  this.emit('abort')
-}
-
-Glob.prototype.pause = function () {
-  if (!this.paused) {
-    this.paused = true
-    this.emit('pause')
-  }
-}
-
-Glob.prototype.resume = function () {
-  if (this.paused) {
-    this.emit('resume')
-    this.paused = false
-    if (this._emitQueue.length) {
-      var eq = this._emitQueue.slice(0)
-      this._emitQueue.length = 0
-      for (var i = 0; i < eq.length; i ++) {
-        var e = eq[i]
-        this._emitMatch(e[0], e[1])
-      }
-    }
-    if (this._processQueue.length) {
-      var pq = this._processQueue.slice(0)
-      this._processQueue.length = 0
-      for (var i = 0; i < pq.length; i ++) {
-        var p = pq[i]
-        this._processing--
-        this._process(p[0], p[1], p[2], p[3])
-      }
-    }
-  }
-}
-
-Glob.prototype._process = function (pattern, index, inGlobStar, cb) {
-  assert(this instanceof Glob)
-  assert(typeof cb === 'function')
-
-  if (this.aborted)
-    return
-
-  this._processing++
-  if (this.paused) {
-    this._processQueue.push([pattern, index, inGlobStar, cb])
-    return
-  }
-
-  //console.error('PROCESS %d', this._processing, pattern)
-
-  // Get the first [n] parts of pattern that are all strings.
-  var n = 0
-  while (typeof pattern[n] === 'string') {
-    n ++
-  }
-  // now n is the index of the first one that is *not* a string.
-
-  // see if there's anything else
-  var prefix
-  switch (n) {
-    // if not, then this is rather simple
-    case pattern.length:
-      this._processSimple(pattern.join('/'), index, cb)
-      return
-
-    case 0:
-      // pattern *starts* with some non-trivial item.
-      // going to readdir(cwd), but not include the prefix in matches.
-      prefix = null
-      break
-
-    default:
-      // pattern has some string bits in the front.
-      // whatever it starts with, whether that's 'absolute' like /foo/bar,
-      // or 'relative' like '../baz'
-      prefix = pattern.slice(0, n).join('/')
-      break
-  }
-
-  var remain = pattern.slice(n)
-
-  // get the list of entries.
-  var read
-  if (prefix === null)
-    read = '.'
-  else if (isAbsolute(prefix) || isAbsolute(pattern.join('/'))) {
-    if (!prefix || !isAbsolute(prefix))
-      prefix = '/' + prefix
-    read = prefix
-  } else
-    read = prefix
-
-  var abs = this._makeAbs(read)
-
-  //if ignored, skip _processing
-  if (childrenIgnored(this, read))
-    return cb()
-
-  var isGlobStar = remain[0] === minimatch.GLOBSTAR
-  if (isGlobStar)
-    this._processGlobStar(prefix, read, abs, remain, index, inGlobStar, cb)
-  else
-    this._processReaddir(prefix, read, abs, remain, index, inGlobStar, cb)
-}
-
-Glob.prototype._processReaddir = function (prefix, read, abs, remain, index, inGlobStar, cb) {
-  var self = this
-  this._readdir(abs, inGlobStar, function (er, entries) {
-    return self._processReaddir2(prefix, read, abs, remain, index, inGlobStar, entries, cb)
-  })
-}
-
-Glob.prototype._processReaddir2 = function (prefix, read, abs, remain, index, inGlobStar, entries, cb) {
-
-  // if the abs isn't a dir, then nothing can match!
-  if (!entries)
-    return cb()
-
-  // It will only match dot entries if it starts with a dot, or if
-  // dot is set.  Stuff like @(.foo|.bar) isn't allowed.
-  var pn = remain[0]
-  var negate = !!this.minimatch.negate
-  var rawGlob = pn._glob
-  var dotOk = this.dot || rawGlob.charAt(0) === '.'
-
-  var matchedEntries = []
-  for (var i = 0; i < entries.length; i++) {
-    var e = entries[i]
-    if (e.charAt(0) !== '.' || dotOk) {
-      var m
-      if (negate && !prefix) {
-        m = !e.match(pn)
-      } else {
-        m = e.match(pn)
-      }
-      if (m)
-        matchedEntries.push(e)
-    }
-  }
-
-  //console.error('prd2', prefix, entries, remain[0]._glob, matchedEntries)
-
-  var len = matchedEntries.length
-  // If there are no matched entries, then nothing matches.
-  if (len === 0)
-    return cb()
-
-  // if this is the last remaining pattern bit, then no need for
-  // an additional stat *unless* the user has specified mark or
-  // stat explicitly.  We know they exist, since readdir returned
-  // them.
-
-  if (remain.length === 1 && !this.mark && !this.stat) {
-    if (!this.matches[index])
-      this.matches[index] = Object.create(null)
-
-    for (var i = 0; i < len; i ++) {
-      var e = matchedEntries[i]
-      if (prefix) {
-        if (prefix !== '/')
-          e = prefix + '/' + e
-        else
-          e = prefix + e
-      }
-
-      if (e.charAt(0) === '/' && !this.nomount) {
-        e = path.join(this.root, e)
-      }
-      this._emitMatch(index, e)
-    }
-    // This was the last one, and no stats were needed
-    return cb()
-  }
-
-  // now test all matched entries as stand-ins for that part
-  // of the pattern.
-  remain.shift()
-  for (var i = 0; i < len; i ++) {
-    var e = matchedEntries[i]
-    var newPattern
-    if (prefix) {
-      if (prefix !== '/')
-        e = prefix + '/' + e
-      else
-        e = prefix + e
-    }
-    this._process([e].concat(remain), index, inGlobStar, cb)
-  }
-  cb()
-}
-
-Glob.prototype._emitMatch = function (index, e) {
-  if (this.aborted)
-    return
-
-  if (this.matches[index][e])
-    return
-
-  if (this.paused) {
-    this._emitQueue.push([index, e])
-    return
-  }
-
-  var abs = this._makeAbs(e)
-
-  if (this.nodir) {
-    var c = this.cache[abs]
-    if (c === 'DIR' || Array.isArray(c))
-      return
-  }
-
-  if (this.mark)
-    e = this._mark(e)
-
-  this.matches[index][e] = true
-
-  var st = this.statCache[abs]
-  if (st)
-    this.emit('stat', e, st)
-
-  this.emit('match', e)
-}
-
-Glob.prototype._readdirInGlobStar = function (abs, cb) {
-  if (this.aborted)
-    return
-
-  // follow all symlinked directories forever
-  // just proceed as if this is a non-globstar situation
-  if (this.follow)
-    return this._readdir(abs, false, cb)
-
-  var lstatkey = 'lstat\0' + abs
-  var self = this
-  var lstatcb = inflight(lstatkey, lstatcb_)
-
-  if (lstatcb)
-    fs.lstat(abs, lstatcb)
-
-  function lstatcb_ (er, lstat) {
-    if (er)
-      return cb()
-
-    var isSym = lstat.isSymbolicLink()
-    self.symlinks[abs] = isSym
-
-    // If it's not a symlink or a dir, then it's definitely a regular file.
-    // don't bother doing a readdir in that case.
-    if (!isSym && !lstat.isDirectory()) {
-      self.cache[abs] = 'FILE'
-      cb()
-    } else
-      self._readdir(abs, false, cb)
-  }
-}
-
-Glob.prototype._readdir = function (abs, inGlobStar, cb) {
-  if (this.aborted)
-    return
-
-  cb = inflight('readdir\0'+abs+'\0'+inGlobStar, cb)
-  if (!cb)
-    return
-
-  //console.error('RD %j %j', +inGlobStar, abs)
-  if (inGlobStar && !ownProp(this.symlinks, abs))
-    return this._readdirInGlobStar(abs, cb)
-
-  if (ownProp(this.cache, abs)) {
-    var c = this.cache[abs]
-    if (!c || c === 'FILE')
-      return cb()
-
-    if (Array.isArray(c))
-      return cb(null, c)
-  }
-
-  var self = this
-  fs.readdir(abs, readdirCb(this, abs, cb))
-}
-
-function readdirCb (self, abs, cb) {
-  return function (er, entries) {
-    if (er)
-      self._readdirError(abs, er, cb)
-    else
-      self._readdirEntries(abs, entries, cb)
-  }
-}
-
-Glob.prototype._readdirEntries = function (abs, entries, cb) {
-  if (this.aborted)
-    return
-
-  // if we haven't asked to stat everything, then just
-  // assume that everything in there exists, so we can avoid
-  // having to stat it a second time.
-  if (!this.mark && !this.stat) {
-    for (var i = 0; i < entries.length; i ++) {
-      var e = entries[i]
-      if (abs === '/')
-        e = abs + e
-      else
-        e = abs + '/' + e
-      this.cache[e] = true
-    }
-  }
-
-  this.cache[abs] = entries
-  return cb(null, entries)
-}
-
-Glob.prototype._readdirError = function (f, er, cb) {
-  if (this.aborted)
-    return
-
-  // handle errors, and cache the information
-  switch (er.code) {
-    case 'ENOTDIR': // totally normal. means it *does* exist.
-      this.cache[this._makeAbs(f)] = 'FILE'
-      break
-
-    case 'ENOENT': // not terribly unusual
-    case 'ELOOP':
-    case 'ENAMETOOLONG':
-    case 'UNKNOWN':
-      this.cache[this._makeAbs(f)] = false
-      break
-
-    default: // some unusual error.  Treat as failure.
-      this.cache[this._makeAbs(f)] = false
-      if (this.strict) return this.emit('error', er)
-      if (!this.silent) console.error('glob error', er)
-      break
-  }
-  return cb()
-}
-
-Glob.prototype._processGlobStar = function (prefix, read, abs, remain, index, inGlobStar, cb) {
-  var self = this
-  this._readdir(abs, inGlobStar, function (er, entries) {
-    self._processGlobStar2(prefix, read, abs, remain, index, inGlobStar, entries, cb)
-  })
-}
-
-
-Glob.prototype._processGlobStar2 = function (prefix, read, abs, remain, index, inGlobStar, entries, cb) {
-  //console.error('pgs2', prefix, remain[0], entries)
-
-  // no entries means not a dir, so it can never have matches
-  // foo.txt/** doesn't match foo.txt
-  if (!entries)
-    return cb()
-
-  // test without the globstar, and with every child both below
-  // and replacing the globstar.
-  var remainWithoutGlobStar = remain.slice(1)
-  var gspref = prefix ? [ prefix ] : []
-  var noGlobStar = gspref.concat(remainWithoutGlobStar)
-
-  // the noGlobStar pattern exits the inGlobStar state
-  this._process(noGlobStar, index, false, cb)
-
-  var isSym = this.symlinks[abs]
-  var len = entries.length
-
-  // If it's a symlink, and we're in a globstar, then stop
-  if (isSym && inGlobStar)
-    return cb()
-
-  for (var i = 0; i < len; i++) {
-    var e = entries[i]
-    if (e.charAt(0) === '.' && !this.dot)
-      continue
-
-    // these two cases enter the inGlobStar state
-    var instead = gspref.concat(entries[i], remainWithoutGlobStar)
-    this._process(instead, index, true, cb)
-
-    var below = gspref.concat(entries[i], remain)
-    this._process(below, index, true, cb)
-  }
-
-  cb()
-}
-
-Glob.prototype._processSimple = function (prefix, index, cb) {
-  // XXX review this.  Shouldn't it be doing the mounting etc
-  // before doing stat?  kinda weird?
-  var self = this
-  this._stat(prefix, function (er, exists) {
-    self._processSimple2(prefix, index, er, exists, cb)
-  })
-}
-Glob.prototype._processSimple2 = function (prefix, index, er, exists, cb) {
-
-  //console.error('ps2', prefix, exists)
-
-  if (!this.matches[index])
-    this.matches[index] = Object.create(null)
-
-  // If it doesn't exist, then just mark the lack of results
-  if (!exists)
-    return cb()
-
-  if (prefix && isAbsolute(prefix) && !this.nomount) {
-    var trail = /[\/\\]$/.test(prefix)
-    if (prefix.charAt(0) === '/') {
-      prefix = path.join(this.root, prefix)
-    } else {
-      prefix = path.resolve(this.root, prefix)
-      if (trail)
-        prefix += '/'
-    }
-  }
-
-  if (process.platform === 'win32')
-    prefix = prefix.replace(/\\/g, '/')
-
-  // Mark this as a match
-  this._emitMatch(index, prefix)
-  cb()
-}
-
-// Returns either 'DIR', 'FILE', or false
-Glob.prototype._stat = function (f, cb) {
-  var abs = this._makeAbs(f)
-  var needDir = f.slice(-1) === '/'
-
-  if (f.length > this.maxLength)
-    return cb()
-
-  if (!this.stat && ownProp(this.cache, abs)) {
-    var c = this.cache[abs]
-
-    if (Array.isArray(c))
-      c = 'DIR'
-
-    // It exists, but maybe not how we need it
-    if (!needDir || c === 'DIR')
-      return cb(null, c)
-
-    if (needDir && c === 'FILE')
-      return cb()
-
-    // otherwise we have to stat, because maybe c=true
-    // if we know it exists, but not what it is.
-  }
-
-  var exists
-  var stat = this.statCache[abs]
-  if (stat !== undefined) {
-    if (stat === false)
-      return cb(null, stat)
-    else {
-      var type = stat.isDirectory() ? 'DIR' : 'FILE'
-      if (needDir && type === 'FILE')
-        return cb()
-      else
-        return cb(null, type, stat)
-    }
-  }
-
-  var self = this
-  var statcb = inflight('stat\0' + abs, lstatcb_)
-  if (statcb)
-    fs.lstat(abs, statcb)
-
-  function lstatcb_ (er, lstat) {
-    if (lstat && lstat.isSymbolicLink()) {
-      // If it's a symlink, then treat it as the target, unless
-      // the target does not exist, then treat it as a file.
-      return fs.stat(abs, function (er, stat) {
-        if (er)
-          self._stat2(f, abs, null, lstat, cb)
-        else
-          self._stat2(f, abs, er, stat, cb)
-      })
-    } else {
-      self._stat2(f, abs, er, lstat, cb)
-    }
-  }
-}
-
-Glob.prototype._stat2 = function (f, abs, er, stat, cb) {
-  if (er) {
-    this.statCache[abs] = false
-    return cb()
-  }
-
-  var needDir = f.slice(-1) === '/'
-  this.statCache[abs] = stat
-
-  if (abs.slice(-1) === '/' && !stat.isDirectory())
-    return cb(null, false, stat)
-
-  var c = stat.isDirectory() ? 'DIR' : 'FILE'
-  this.cache[abs] = this.cache[abs] || c
-
-  if (needDir && c !== 'DIR')
-    return cb()
-
-  return cb(null, c, stat)
-}
diff --git a/deps/npm/node_modules/rimraf/node_modules/glob/package.json b/deps/npm/node_modules/rimraf/node_modules/glob/package.json
deleted file mode 100644 (file)
index 7a2cb4c..0000000
+++ /dev/null
@@ -1,72 +0,0 @@
-{
-  "author": {
-    "name": "Isaac Z. Schlueter",
-    "email": "i@izs.me",
-    "url": "http://blog.izs.me/"
-  },
-  "name": "glob",
-  "description": "a little globber",
-  "version": "4.5.3",
-  "repository": {
-    "type": "git",
-    "url": "git://github.com/isaacs/node-glob.git"
-  },
-  "main": "glob.js",
-  "files": [
-    "glob.js",
-    "sync.js",
-    "common.js"
-  ],
-  "engines": {
-    "node": "*"
-  },
-  "dependencies": {
-    "inflight": "^1.0.4",
-    "inherits": "2",
-    "minimatch": "^2.0.1",
-    "once": "^1.3.0"
-  },
-  "devDependencies": {
-    "mkdirp": "0",
-    "rimraf": "^2.2.8",
-    "tap": "^0.5.0",
-    "tick": "0.0.6"
-  },
-  "scripts": {
-    "prepublish": "npm run benchclean",
-    "profclean": "rm -f v8.log profile.txt",
-    "test": "npm run profclean && tap test/*.js",
-    "test-regen": "npm run profclean && TEST_REGEN=1 node test/00-setup.js",
-    "bench": "bash benchmark.sh",
-    "prof": "bash prof.sh && cat profile.txt",
-    "benchclean": "bash benchclean.sh"
-  },
-  "license": "ISC",
-  "gitHead": "a4e461ab59a837eee80a4d8dbdbf5ae1054a646f",
-  "bugs": {
-    "url": "https://github.com/isaacs/node-glob/issues"
-  },
-  "homepage": "https://github.com/isaacs/node-glob",
-  "_id": "glob@4.5.3",
-  "_shasum": "c6cb73d3226c1efef04de3c56d012f03377ee15f",
-  "_from": "glob@>=4.4.2 <5.0.0",
-  "_npmVersion": "2.7.1",
-  "_nodeVersion": "1.4.2",
-  "_npmUser": {
-    "name": "isaacs",
-    "email": "i@izs.me"
-  },
-  "maintainers": [
-    {
-      "name": "isaacs",
-      "email": "i@izs.me"
-    }
-  ],
-  "dist": {
-    "shasum": "c6cb73d3226c1efef04de3c56d012f03377ee15f",
-    "tarball": "http://registry.npmjs.org/glob/-/glob-4.5.3.tgz"
-  },
-  "directories": {},
-  "_resolved": "https://registry.npmjs.org/glob/-/glob-4.5.3.tgz",
-  "readme": "ERROR: No README data found!"
-}
diff --git a/deps/npm/node_modules/rimraf/node_modules/glob/sync.js b/deps/npm/node_modules/rimraf/node_modules/glob/sync.js
deleted file mode 100644 (file)
index f4f5e36..0000000
+++ /dev/null
@@ -1,457 +0,0 @@
-module.exports = globSync
-globSync.GlobSync = GlobSync
-
-var fs = require('fs')
-var minimatch = require('minimatch')
-var Minimatch = minimatch.Minimatch
-var Glob = require('./glob.js').Glob
-var util = require('util')
-var path = require('path')
-var assert = require('assert')
-var common = require('./common.js')
-var alphasort = common.alphasort
-var alphasorti = common.alphasorti
-var isAbsolute = common.isAbsolute
-var setopts = common.setopts
-var ownProp = common.ownProp
-var childrenIgnored = common.childrenIgnored
-
-function globSync (pattern, options) {
-  if (typeof options === 'function' || arguments.length === 3)
-    throw new TypeError('callback provided to sync glob\n'+
-                        'See: https://github.com/isaacs/node-glob/issues/167')
-
-  return new GlobSync(pattern, options).found
-}
-
-function GlobSync (pattern, options) {
-  if (!pattern)
-    throw new Error('must provide pattern')
-
-  if (typeof options === 'function' || arguments.length === 3)
-    throw new TypeError('callback provided to sync glob\n'+
-                        'See: https://github.com/isaacs/node-glob/issues/167')
-
-  if (!(this instanceof GlobSync))
-    return new GlobSync(pattern, options)
-
-  setopts(this, pattern, options)
-
-  if (this.noprocess)
-    return this
-
-  var n = this.minimatch.set.length
-  this.matches = new Array(n)
-  for (var i = 0; i < n; i ++) {
-    this._process(this.minimatch.set[i], i, false)
-  }
-  this._finish()
-}
-
-GlobSync.prototype._finish = function () {
-  assert(this instanceof GlobSync)
-  if (this.realpath) {
-    var self = this
-    this.matches.forEach(function (matchset, index) {
-      var set = self.matches[index] = Object.create(null)
-      for (var p in matchset) {
-        try {
-          p = self._makeAbs(p)
-          var real = fs.realpathSync(p, this.realpathCache)
-          set[real] = true
-        } catch (er) {
-          if (er.syscall === 'stat')
-            set[self._makeAbs(p)] = true
-          else
-            throw er
-        }
-      }
-    })
-  }
-  common.finish(this)
-}
-
-
-GlobSync.prototype._process = function (pattern, index, inGlobStar) {
-  assert(this instanceof GlobSync)
-
-  // Get the first [n] parts of pattern that are all strings.
-  var n = 0
-  while (typeof pattern[n] === 'string') {
-    n ++
-  }
-  // now n is the index of the first one that is *not* a string.
-
-  // See if there's anything else
-  var prefix
-  switch (n) {
-    // if not, then this is rather simple
-    case pattern.length:
-      this._processSimple(pattern.join('/'), index)
-      return
-
-    case 0:
-      // pattern *starts* with some non-trivial item.
-      // going to readdir(cwd), but not include the prefix in matches.
-      prefix = null
-      break
-
-    default:
-      // pattern has some string bits in the front.
-      // whatever it starts with, whether that's 'absolute' like /foo/bar,
-      // or 'relative' like '../baz'
-      prefix = pattern.slice(0, n).join('/')
-      break
-  }
-
-  var remain = pattern.slice(n)
-
-  // get the list of entries.
-  var read
-  if (prefix === null)
-    read = '.'
-  else if (isAbsolute(prefix) || isAbsolute(pattern.join('/'))) {
-    if (!prefix || !isAbsolute(prefix))
-      prefix = '/' + prefix
-    read = prefix
-  } else
-    read = prefix
-
-  var abs = this._makeAbs(read)
-
-  //if ignored, skip processing
-  if (childrenIgnored(this, read))
-    return
-
-  var isGlobStar = remain[0] === minimatch.GLOBSTAR
-  if (isGlobStar)
-    this._processGlobStar(prefix, read, abs, remain, index, inGlobStar)
-  else
-    this._processReaddir(prefix, read, abs, remain, index, inGlobStar)
-}
-
-
-GlobSync.prototype._processReaddir = function (prefix, read, abs, remain, index, inGlobStar) {
-  var entries = this._readdir(abs, inGlobStar)
-
-  // if the abs isn't a dir, then nothing can match!
-  if (!entries)
-    return
-
-  // It will only match dot entries if it starts with a dot, or if
-  // dot is set.  Stuff like @(.foo|.bar) isn't allowed.
-  var pn = remain[0]
-  var negate = !!this.minimatch.negate
-  var rawGlob = pn._glob
-  var dotOk = this.dot || rawGlob.charAt(0) === '.'
-
-  var matchedEntries = []
-  for (var i = 0; i < entries.length; i++) {
-    var e = entries[i]
-    if (e.charAt(0) !== '.' || dotOk) {
-      var m
-      if (negate && !prefix) {
-        m = !e.match(pn)
-      } else {
-        m = e.match(pn)
-      }
-      if (m)
-        matchedEntries.push(e)
-    }
-  }
-
-  var len = matchedEntries.length
-  // If there are no matched entries, then nothing matches.
-  if (len === 0)
-    return
-
-  // if this is the last remaining pattern bit, then no need for
-  // an additional stat *unless* the user has specified mark or
-  // stat explicitly.  We know they exist, since readdir returned
-  // them.
-
-  if (remain.length === 1 && !this.mark && !this.stat) {
-    if (!this.matches[index])
-      this.matches[index] = Object.create(null)
-
-    for (var i = 0; i < len; i ++) {
-      var e = matchedEntries[i]
-      if (prefix) {
-        if (prefix.slice(-1) !== '/')
-          e = prefix + '/' + e
-        else
-          e = prefix + e
-      }
-
-      if (e.charAt(0) === '/' && !this.nomount) {
-        e = path.join(this.root, e)
-      }
-      this.matches[index][e] = true
-    }
-    // This was the last one, and no stats were needed
-    return
-  }
-
-  // now test all matched entries as stand-ins for that part
-  // of the pattern.
-  remain.shift()
-  for (var i = 0; i < len; i ++) {
-    var e = matchedEntries[i]
-    var newPattern
-    if (prefix)
-      newPattern = [prefix, e]
-    else
-      newPattern = [e]
-    this._process(newPattern.concat(remain), index, inGlobStar)
-  }
-}
-
-
-GlobSync.prototype._emitMatch = function (index, e) {
-  var abs = this._makeAbs(e)
-  if (this.mark)
-    e = this._mark(e)
-
-  if (this.matches[index][e])
-    return
-
-  if (this.nodir) {
-    var c = this.cache[this._makeAbs(e)]
-    if (c === 'DIR' || Array.isArray(c))
-      return
-  }
-
-  this.matches[index][e] = true
-  if (this.stat)
-    this._stat(e)
-}
-
-
-GlobSync.prototype._readdirInGlobStar = function (abs) {
-  // follow all symlinked directories forever
-  // just proceed as if this is a non-globstar situation
-  if (this.follow)
-    return this._readdir(abs, false)
-
-  var entries
-  var lstat
-  var stat
-  try {
-    lstat = fs.lstatSync(abs)
-  } catch (er) {
-    // lstat failed, doesn't exist
-    return null
-  }
-
-  var isSym = lstat.isSymbolicLink()
-  this.symlinks[abs] = isSym
-
-  // If it's not a symlink or a dir, then it's definitely a regular file.
-  // don't bother doing a readdir in that case.
-  if (!isSym && !lstat.isDirectory())
-    this.cache[abs] = 'FILE'
-  else
-    entries = this._readdir(abs, false)
-
-  return entries
-}
-
-GlobSync.prototype._readdir = function (abs, inGlobStar) {
-  var entries
-
-  if (inGlobStar && !ownProp(this.symlinks, abs))
-    return this._readdirInGlobStar(abs)
-
-  if (ownProp(this.cache, abs)) {
-    var c = this.cache[abs]
-    if (!c || c === 'FILE')
-      return null
-
-    if (Array.isArray(c))
-      return c
-  }
-
-  try {
-    return this._readdirEntries(abs, fs.readdirSync(abs))
-  } catch (er) {
-    this._readdirError(abs, er)
-    return null
-  }
-}
-
-GlobSync.prototype._readdirEntries = function (abs, entries) {
-  // if we haven't asked to stat everything, then just
-  // assume that everything in there exists, so we can avoid
-  // having to stat it a second time.
-  if (!this.mark && !this.stat) {
-    for (var i = 0; i < entries.length; i ++) {
-      var e = entries[i]
-      if (abs === '/')
-        e = abs + e
-      else
-        e = abs + '/' + e
-      this.cache[e] = true
-    }
-  }
-
-  this.cache[abs] = entries
-
-  // mark and cache dir-ness
-  return entries
-}
-
-GlobSync.prototype._readdirError = function (f, er) {
-  // handle errors, and cache the information
-  switch (er.code) {
-    case 'ENOTDIR': // totally normal. means it *does* exist.
-      this.cache[this._makeAbs(f)] = 'FILE'
-      break
-
-    case 'ENOENT': // not terribly unusual
-    case 'ELOOP':
-    case 'ENAMETOOLONG':
-    case 'UNKNOWN':
-      this.cache[this._makeAbs(f)] = false
-      break
-
-    default: // some unusual error.  Treat as failure.
-      this.cache[this._makeAbs(f)] = false
-      if (this.strict) throw er
-      if (!this.silent) console.error('glob error', er)
-      break
-  }
-}
-
-GlobSync.prototype._processGlobStar = function (prefix, read, abs, remain, index, inGlobStar) {
-
-  var entries = this._readdir(abs, inGlobStar)
-
-  // no entries means not a dir, so it can never have matches
-  // foo.txt/** doesn't match foo.txt
-  if (!entries)
-    return
-
-  // test without the globstar, and with every child both below
-  // and replacing the globstar.
-  var remainWithoutGlobStar = remain.slice(1)
-  var gspref = prefix ? [ prefix ] : []
-  var noGlobStar = gspref.concat(remainWithoutGlobStar)
-
-  // the noGlobStar pattern exits the inGlobStar state
-  this._process(noGlobStar, index, false)
-
-  var len = entries.length
-  var isSym = this.symlinks[abs]
-
-  // If it's a symlink, and we're in a globstar, then stop
-  if (isSym && inGlobStar)
-    return
-
-  for (var i = 0; i < len; i++) {
-    var e = entries[i]
-    if (e.charAt(0) === '.' && !this.dot)
-      continue
-
-    // these two cases enter the inGlobStar state
-    var instead = gspref.concat(entries[i], remainWithoutGlobStar)
-    this._process(instead, index, true)
-
-    var below = gspref.concat(entries[i], remain)
-    this._process(below, index, true)
-  }
-}
-
-GlobSync.prototype._processSimple = function (prefix, index) {
-  // XXX review this.  Shouldn't it be doing the mounting etc
-  // before doing stat?  kinda weird?
-  var exists = this._stat(prefix)
-
-  if (!this.matches[index])
-    this.matches[index] = Object.create(null)
-
-  // If it doesn't exist, then just mark the lack of results
-  if (!exists)
-    return
-
-  if (prefix && isAbsolute(prefix) && !this.nomount) {
-    var trail = /[\/\\]$/.test(prefix)
-    if (prefix.charAt(0) === '/') {
-      prefix = path.join(this.root, prefix)
-    } else {
-      prefix = path.resolve(this.root, prefix)
-      if (trail)
-        prefix += '/'
-    }
-  }
-
-  if (process.platform === 'win32')
-    prefix = prefix.replace(/\\/g, '/')
-
-  // Mark this as a match
-  this.matches[index][prefix] = true
-}
-
-// Returns either 'DIR', 'FILE', or false
-GlobSync.prototype._stat = function (f) {
-  var abs = this._makeAbs(f)
-  var needDir = f.slice(-1) === '/'
-
-  if (f.length > this.maxLength)
-    return false
-
-  if (!this.stat && ownProp(this.cache, abs)) {
-    var c = this.cache[abs]
-
-    if (Array.isArray(c))
-      c = 'DIR'
-
-    // It exists, but maybe not how we need it
-    if (!needDir || c === 'DIR')
-      return c
-
-    if (needDir && c === 'FILE')
-      return false
-
-    // otherwise we have to stat, because maybe c=true
-    // if we know it exists, but not what it is.
-  }
-
-  var exists
-  var stat = this.statCache[abs]
-  if (!stat) {
-    var lstat
-    try {
-      lstat = fs.lstatSync(abs)
-    } catch (er) {
-      return false
-    }
-
-    if (lstat.isSymbolicLink()) {
-      try {
-        stat = fs.statSync(abs)
-      } catch (er) {
-        stat = lstat
-      }
-    } else {
-      stat = lstat
-    }
-  }
-
-  this.statCache[abs] = stat
-
-  var c = stat.isDirectory() ? 'DIR' : 'FILE'
-  this.cache[abs] = this.cache[abs] || c
-
-  if (needDir && c !== 'DIR')
-    return false
-
-  return c
-}
-
-GlobSync.prototype._mark = function (p) {
-  return common.mark(this, p)
-}
-
-GlobSync.prototype._makeAbs = function (f) {
-  return common.makeAbs(this, f)
-}
index dd45d79..449d380 100644 (file)
@@ -1,6 +1,6 @@
 {
   "name": "rimraf",
-  "version": "2.4.1",
+  "version": "2.4.2",
   "main": "rimraf.js",
   "description": "A deep deletion module for node (like `rm -rf`)",
   "author": {
     "rimraf": "./bin.js"
   },
   "dependencies": {
-    "glob": "^4.4.2"
+    "glob": "^5.0.14"
   },
   "files": [
-    "bin.js",
-    "rimraf.js",
     "LICENSE",
-    "README.md"
+    "README.md",
+    "bin.js",
+    "rimraf.js"
   ],
   "devDependencies": {
     "mkdirp": "^0.5.1",
-    "tap": "^1.2.0"
+    "tap": "^1.3.1"
   },
-  "gitHead": "9b97ac62e1b459d84dbe18f20757bfe4374e65ab",
+  "gitHead": "4359e9d3b3c0f26e6abe3139a00b93337f1689d7",
   "bugs": {
     "url": "https://github.com/isaacs/rimraf/issues"
   },
   "homepage": "https://github.com/isaacs/rimraf#readme",
-  "_id": "rimraf@2.4.1",
-  "_shasum": "99ff3cc1d61d687b67489b9f97cfa9d3db3b9e48",
-  "_from": "rimraf@2.4.1",
-  "_npmVersion": "3.0.0",
+  "_id": "rimraf@2.4.2",
+  "_shasum": "ab4f39b08b72eae07c3d9fe9f4831aebfc9f431d",
+  "_from": "rimraf@2.4.2",
+  "_npmVersion": "3.1.0",
   "_nodeVersion": "2.2.1",
   "_npmUser": {
     "name": "isaacs",
     "email": "isaacs@npmjs.com"
   },
   "dist": {
-    "shasum": "99ff3cc1d61d687b67489b9f97cfa9d3db3b9e48",
-    "tarball": "http://registry.npmjs.org/rimraf/-/rimraf-2.4.1.tgz"
+    "shasum": "ab4f39b08b72eae07c3d9fe9f4831aebfc9f431d",
+    "tarball": "http://registry.npmjs.org/rimraf/-/rimraf-2.4.2.tgz"
   },
   "maintainers": [
     {
@@ -57,5 +57,6 @@
     }
   ],
   "directories": {},
-  "_resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.4.1.tgz"
+  "_resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.4.2.tgz",
+  "readme": "ERROR: No README data found!"
 }
index 12eecdc..d650b89 100644 (file)
@@ -1,13 +1,10 @@
 {
   "name": "semver",
-  "version": "4.3.6",
+  "version": "5.0.1",
   "description": "The semantic version parser used by npm.",
   "main": "semver.js",
-  "browser": "semver.browser.js",
-  "min": "semver.min.js",
   "scripts": {
-    "test": "tap test/*.js",
-    "prepublish": "make"
+    "test": "tap test/*.js"
   },
   "devDependencies": {
     "tap": "^1.2.0",
   "license": "ISC",
   "repository": {
     "type": "git",
-    "url": "git://github.com/npm/node-semver.git"
+    "url": "git+https://github.com/npm/node-semver.git"
   },
   "bin": {
     "semver": "./bin/semver"
   },
-  "gitHead": "63c48296ca5da3ba6a88c743bb8c92effc789811",
+  "gitHead": "3408896f115cdb241684fb81f85abb0d2ecc27e9",
   "bugs": {
     "url": "https://github.com/npm/node-semver/issues"
   },
   "homepage": "https://github.com/npm/node-semver#readme",
-  "_id": "semver@4.3.6",
-  "_shasum": "300bc6e0e86374f7ba61068b5b1ecd57fc6532da",
-  "_from": "semver@>=4.3.6 <4.4.0",
-  "_npmVersion": "2.10.1",
-  "_nodeVersion": "2.0.1",
+  "_id": "semver@5.0.1",
+  "_shasum": "9fb3f4004f900d83c47968fe42f7583e05832cc9",
+  "_from": "semver@>=5.0.1 <5.1.0",
+  "_npmVersion": "3.1.0",
+  "_nodeVersion": "2.2.1",
   "_npmUser": {
     "name": "isaacs",
     "email": "isaacs@npmjs.com"
   },
   "dist": {
-    "shasum": "300bc6e0e86374f7ba61068b5b1ecd57fc6532da",
-    "tarball": "http://registry.npmjs.org/semver/-/semver-4.3.6.tgz"
+    "shasum": "9fb3f4004f900d83c47968fe42f7583e05832cc9",
+    "tarball": "http://registry.npmjs.org/semver/-/semver-5.0.1.tgz"
   },
   "maintainers": [
     {
@@ -50,5 +47,6 @@
     }
   ],
   "directories": {},
-  "_resolved": "https://registry.npmjs.org/semver/-/semver-4.3.6.tgz"
+  "_resolved": "https://registry.npmjs.org/semver/-/semver-5.0.1.tgz",
+  "readme": "ERROR: No README data found!"
 }
index cafcc00..d4a8dca 100644 (file)
@@ -1,6 +1,4 @@
-// export the class if we are in a Node-like system.
-if (typeof module === 'object' && module.exports === exports)
-  exports = module.exports = SemVer;
+exports = module.exports = SemVer;
 
 // The debug function is excluded entirely from the minified version.
 /* nomin */ var debug;
@@ -1199,7 +1197,3 @@ function outside(version, range, hilo, loose) {
   }
   return true;
 }
-
-// Use the define() function if we're in AMD land
-if (typeof define === 'function' && define.amd)
-  define(exports);
index aa5c582..4cee1cf 100644 (file)
@@ -1,5 +1,5 @@
 {
-  "version": "2.13.2",
+  "version": "2.13.3",
   "name": "npm",
   "description": "a package manager for JavaScript",
   "keywords": [
     "inflight": "~1.0.4",
     "inherits": "~2.0.1",
     "ini": "~1.3.4",
-    "init-package-json": "~1.7.0",
+    "init-package-json": "~1.7.1",
     "lockfile": "~1.0.1",
     "lru-cache": "~2.6.5",
-    "minimatch": "~2.0.8",
+    "minimatch": "~2.0.10",
     "mkdirp": "~0.5.1",
     "node-gyp": "~2.0.2",
     "nopt": "~3.0.3",
     "normalize-git-url": "~3.0.1",
-    "normalize-package-data": "~2.3.0",
+    "normalize-package-data": "~2.3.1",
     "npm-cache-filename": "~1.0.2",
-    "npm-install-checks": "~1.0.5",
-    "npm-package-arg": "~4.0.1",
-    "npm-registry-client": "~6.5.0",
+    "npm-install-checks": "~1.0.6",
+    "npm-package-arg": "~4.0.2",
+    "npm-registry-client": "~6.5.1",
     "npm-user-validate": "~0.1.2",
     "npmlog": "~1.2.1",
     "once": "~1.3.2",
     "osenv": "~0.1.3",
     "path-is-inside": "~1.0.0",
     "read": "~1.0.6",
-    "read-installed": "~4.0.1",
+    "read-installed": "~4.0.2",
     "read-package-json": "~2.0.0",
     "readable-stream": "~1.1.13",
     "realize-package-specifier": "~3.0.1",
-    "request": "~2.58.0",
+    "request": "~2.60.0",
     "retry": "~0.6.1",
-    "rimraf": "~2.4.1",
-    "semver": "~4.3.6",
+    "rimraf": "~2.4.2",
+    "semver": "~5.0.1",
     "sha": "~1.3.0",
     "slide": "~1.1.6",
     "sorted-object": "~1.0.0",
   "devDependencies": {
     "deep-equal": "~1.0.0",
     "marked": "~0.3.3",
-    "marked-man": "~0.1.4",
+    "marked-man": "~0.1.5",
     "nock": "~2.7.0",
     "npm-registry-couchapp": "~2.6.7",
     "npm-registry-mock": "~1.0.0",
index 85e871c..abe6c19 100644 (file)
@@ -8,7 +8,7 @@ set -e
 
 rm -rf release *.tgz || true
 mkdir release
-npm pack --loglevel error >/dev/null
+node ./cli.js pack --loglevel error >/dev/null
 mv *.tgz release
 cd release
 tar xzf *.tgz
@@ -18,12 +18,12 @@ mv package node_modules/npm
 
 # make the zip for windows users
 cp node_modules/npm/bin/*.cmd .
-zipname=npm-$(npm -v).zip
+zipname=npm-$(node ../cli.js -v).zip
 zip -q -9 -r -X "$zipname" *.cmd node_modules
 
 # make the tar for node's deps
 cd node_modules
-tarname=npm-$(npm -v).tgz
+tarname=npm-$(node ../../cli.js -v).tgz
 tar czf "$tarname" npm
 
 cd ..
diff --git a/deps/npm/test/npm_cache/npm-test-preferglobal-dep/0.0.0/package.tgz b/deps/npm/test/npm_cache/npm-test-preferglobal-dep/0.0.0/package.tgz
new file mode 100644 (file)
index 0000000..3d33fc8
Binary files /dev/null and b/deps/npm/test/npm_cache/npm-test-preferglobal-dep/0.0.0/package.tgz differ
diff --git a/deps/npm/test/npm_cache/npm-test-preferglobal-dep/0.0.0/package/package.json b/deps/npm/test/npm_cache/npm-test-preferglobal-dep/0.0.0/package/package.json
new file mode 100644 (file)
index 0000000..75614bd
--- /dev/null
@@ -0,0 +1 @@
+{"name":"npm-test-preferglobal-dep","version":"0.0.0","preferGlobal":true,"readme":"ERROR: No README data found!","_id":"npm-test-preferglobal-dep@0.0.0","scripts":{},"_shasum":"48c51014a917da64c1770f91dc4db16525c7c5e2","_from":"../npm-test-preferglobal-dep","_resolved":"file:../npm-test-preferglobal-dep"}
\ No newline at end of file
diff --git a/deps/npm/test/npm_cache/registry.npmjs.org/jshint/.cache.json b/deps/npm/test/npm_cache/registry.npmjs.org/jshint/.cache.json
new file mode 100644 (file)
index 0000000..eb40668
--- /dev/null
@@ -0,0 +1 @@
+{"_id":"jshint","_rev":"322-0929561aae4ba51e3c4396517b42d181","name":"jshint","description":"Static analysis tool for JavaScript","dist-tags":{"latest":"2.8.0"},"versions":{"0.1.8":{"name":"jshint","version":"0.1.8","description":"a cli for jshint","homepage":"http://github.com/jshint/node-jshint","author":{"name":"Brent Lintner","email":"brent.lintner@gmail.com","url":"http://github.com/brentlintner"},"licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"main":"./packages/jshint/jshint","files":["packages/jshint/README.markdown","packages/jshint/jshint.js","README.md","LICENSE","HELP","lib","bin","package.json"],"dependencies":{"argsparser":">=0.0.3"},"_id":"jshint@0.1.8","engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"0.3.17","_nodeVersion":"v0.4.2","directories":{"lib":"./lib","bin":"./bin"},"bin":{"jshint":"bin/jshint"},"_defaultsLoaded":true,"dist":{"shasum":"d90e12dccb1bc490409a079defa01e21ee16a6e8","tarball":"http://registry.npmjs.org/jshint/-/jshint-0.1.8.tgz"}},"0.1.9":{"name":"jshint","version":"0.1.9","description":"a cli for jshint","homepage":"http://github.com/jshint/node-jshint","author":{"name":"Brent Lintner","email":"brent.lintner@gmail.com","url":"http://github.com/brentlintner"},"licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"main":"./packages/jshint/jshint","files":["packages/jshint/README.markdown","packages/jshint/jshint.js","README.md","LICENSE","HELP","lib","bin","package.json"],"dependencies":{"argsparser":">=0.0.3"},"_id":"jshint@0.1.9","engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"0.3.17","_nodeVersion":"v0.4.2","directories":{"lib":"./lib","bin":"./bin"},"bin":{"jshint":"bin/jshint"},"_defaultsLoaded":true,"dist":{"shasum":"4ec9f0415c6746021de4b7eb5a3ca1a3ed7f33a7","tarball":"http://registry.npmjs.org/jshint/-/jshint-0.1.9.tgz"}},"0.2.0":{"name":"jshint","version":"0.2.0","description":"a cli for jshint","homepage":"http://github.com/jshint/node-jshint","author":{"name":"Brent Lintner","email":"brent.lintner@gmail.com","url":"http://github.com/brentlintner"},"licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"main":"./packages/jshint/jshint","files":["packages/jshint/README.markdown","packages/jshint/jshint.js","README.md","LICENSE","HELP","lib","bin","package.json"],"dependencies":{"argsparser":">=0.0.3"},"_id":"jshint@0.2.0","engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"0.3.17","_nodeVersion":"v0.4.2","directories":{"lib":"./lib","bin":"./bin"},"bin":{"jshint":"bin/jshint"},"_defaultsLoaded":true,"dist":{"shasum":"0c63f41429bb1a764ce5936f7aaaf806b771d947","tarball":"http://registry.npmjs.org/jshint/-/jshint-0.2.0.tgz"}},"0.2.1":{"name":"jshint","version":"0.2.1","description":"a cli for jshint","homepage":"http://github.com/jshint/node-jshint","author":{"name":"Brent Lintner","email":"brent.lintner@gmail.com","url":"http://github.com/brentlintner"},"licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"bin":{"jshint":"./bin/hint"},"main":"packages/jshint/jshint","files":["packages/jshint/README.markdown","packages/jshint/jshint.js","README.md","LICENSE","HELP"],"dependencies":{"argsparser":">=0.0.3"},"devDependencies":{},"_id":"jshint@0.2.1","engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.0.6","_nodeVersion":"v0.4.7","_defaultsLoaded":true,"dist":{"shasum":"c8589746ff9750d89c4b9e3a0996a9f81b6493bc","tarball":"http://registry.npmjs.org/jshint/-/jshint-0.2.1.tgz"},"scripts":{},"directories":{}},"0.2.2":{"name":"jshint","version":"0.2.2","description":"a cli for jshint","homepage":"http://github.com/jshint/node-jshint","author":{"name":"Brent Lintner","email":"brent.lintner@gmail.com","url":"http://github.com/brentlintner"},"licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"bin":{"jshint":"./bin/hint"},"main":"packages/jshint/jshint","files":["packages/jshint/README.markdown","packages/jshint/jshint.js","README.md","LICENSE","HELP","bin/hint"],"dependencies":{"argsparser":">=0.0.3"},"_npmJsonOpts":{"file":"/Users/isaacs/.npm/jshint/0.2.2/package/package.json","wscript":false,"contributors":false,"serverjs":false},"_id":"jshint@0.2.2","devDependencies":{},"engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.0.13","_nodeVersion":"v0.5.0-pre","_defaultsLoaded":true,"dist":{"shasum":"77091e70ea88bc28904d8e0e7ae2c45b638b477a","tarball":"http://registry.npmjs.org/jshint/-/jshint-0.2.2.tgz"},"scripts":{},"directories":{}},"0.2.3":{"name":"jshint","version":"0.2.3","description":"a cli for jshint","homepage":"http://github.com/jshint/node-jshint","author":{"name":"Brent Lintner","email":"brent.lintner@gmail.com","url":"http://github.com/brentlintner"},"licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"bin":{"jshint":"./bin/hint"},"main":"packages/jshint/jshint","files":["packages/jshint/README.markdown","packages/jshint/jshint.js","README.md","LICENSE","HELP","bin/hint","lib"],"dependencies":{"argsparser":">=0.0.3"},"preferGlobal":true,"_npmJsonOpts":{"file":"/home/brent/.npm/jshint/0.2.3/package/package.json","wscript":false,"contributors":false,"serverjs":false},"_id":"jshint@0.2.3","devDependencies":{},"engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.0.15","_nodeVersion":"v0.4.8","_defaultsLoaded":true,"dist":{"shasum":"d31480ae27228f1c4a7267d521b85fcb9662e53e","tarball":"http://registry.npmjs.org/jshint/-/jshint-0.2.3.tgz"},"scripts":{},"directories":{}},"0.3.0":{"name":"jshint","version":"0.3.0","description":"A CLI for JSHint","homepage":"http://github.com/jshint/node-jshint","author":{"name":"Brent Lintner","email":"brent.lintner@gmail.com","url":"http://github.com/brentlintner"},"licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"bin":{"jshint":"./bin/hint"},"main":"packages/jshint/jshint","files":["packages/jshint/README.markdown","packages/jshint/jshint.js","README.md","LICENSE","HELP","bin/hint","lib"],"dependencies":{"argsparser":">=0.0.3","glob":">=2.0.7"},"preferGlobal":true,"_npmJsonOpts":{"file":"/Users/brent/.npm/jshint/0.3.0/package/package.json","wscript":false,"contributors":false,"serverjs":false},"_id":"jshint@0.3.0","devDependencies":{},"engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.0.22","_nodeVersion":"v0.4.11","_defaultsLoaded":true,"dist":{"shasum":"b011c63b3a805e80e03453768f5a399e02fe5bc0","tarball":"http://registry.npmjs.org/jshint/-/jshint-0.3.0.tgz"},"scripts":{},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"}],"directories":{}},"0.3.1":{"name":"jshint","version":"0.3.1","description":"A CLI for JSHint","homepage":"http://github.com/jshint/node-jshint","author":{"name":"Brent Lintner","email":"brent.lintner@gmail.com","url":"http://github.com/brentlintner"},"licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"bin":{"jshint":"./bin/hint"},"main":"packages/jshint/jshint","files":["packages/jshint/README.markdown","packages/jshint/jshint.js","README.md","LICENSE","HELP","bin/hint","lib"],"dependencies":{"argsparser":">=0.0.3","glob":">=2.0.7"},"preferGlobal":true,"_npmJsonOpts":{"file":"/Users/brent/.npm/jshint/0.3.1/package/package.json","wscript":false,"contributors":false,"serverjs":false},"_id":"jshint@0.3.1","devDependencies":{},"engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.0.22","_nodeVersion":"v0.4.11","_defaultsLoaded":true,"dist":{"shasum":"260df1eaaa6462becf1693da55e831fa87abcb69","tarball":"http://registry.npmjs.org/jshint/-/jshint-0.3.1.tgz"},"scripts":{},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"}],"directories":{}},"0.4.0":{"name":"jshint","version":"0.4.0","description":"A CLI for JSHint","homepage":"http://github.com/jshint/node-jshint","author":{"name":"Brent Lintner","email":"brent.lintner@gmail.com","url":"http://github.com/brentlintner"},"licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"bin":{"jshint":"./bin/hint"},"main":"packages/jshint/jshint","files":["packages/jshint/README.markdown","packages/jshint/jshint.js","README.md","LICENSE","HELP","bin/hint","lib"],"dependencies":{"argsparser":">=0.0.3","glob":">=2.0.7","jasmine-node":"1.0.7"},"bundledDependencies":["argsparser","glob"],"preferGlobal":true,"_npmJsonOpts":{"file":"/Users/brent/.npm/jshint/0.4.0/package/package.json","wscript":false,"contributors":false,"serverjs":false},"_id":"jshint@0.4.0","devDependencies":{},"engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.0.27","_nodeVersion":"v0.4.11","_defaultsLoaded":true,"dist":{"shasum":"8349e2e7bb89147c8c8b47c8b1353d735af6dfeb","tarball":"http://registry.npmjs.org/jshint/-/jshint-0.4.0.tgz"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"}],"directories":{}},"0.5.0":{"name":"jshint","version":"0.5.0","description":"A CLI for JSHint","homepage":"http://github.com/jshint/node-jshint","author":{"name":"Brent Lintner","email":"brent.lintner@gmail.com","url":"http://github.com/brentlintner"},"licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"bin":{"jshint":"./bin/hint"},"main":"packages/jshint/jshint","files":["packages/jshint/README.markdown","packages/jshint/jshint.js","README.md","LICENSE","HELP","bin/hint","lib"],"dependencies":{"argsparser":">=0.0.3","jasmine-node":"1.0.7","minimatch":">=0.0.4"},"preferGlobal":true,"_npmUser":{"name":"brentlintner","email":"brent.lintner@gmail.com"},"_id":"jshint@0.5.0","bundleDependencies":["argsparser","minimatch"],"devDependencies":{},"engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.0.93","_nodeVersion":"v0.4.12","_defaultsLoaded":true,"dist":{"shasum":"a2351b0dbd7ba63f7b94da7d0769ac600e788fdd","tarball":"http://registry.npmjs.org/jshint/-/jshint-0.5.0.tgz"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"}],"directories":{}},"0.5.1":{"name":"jshint","version":"0.5.1","description":"A CLI for JSHint","homepage":"http://github.com/jshint/node-jshint","author":{"name":"Brent Lintner","email":"brent.lintner@gmail.com","url":"http://github.com/brentlintner"},"licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"bin":{"jshint":"./bin/hint"},"main":"packages/jshint/jshint","files":["packages/jshint/README.markdown","packages/jshint/jshint.js","README.md","LICENSE","HELP","bin/hint","lib"],"dependencies":{"argsparser":">=0.0.3","minimatch":">=0.0.4"},"devDependencies":{"jasmine-node":"1.0.7"},"preferGlobal":true,"_npmUser":{"name":"brentlintner","email":"brent.lintner@gmail.com"},"_id":"jshint@0.5.1","engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.0.99","_nodeVersion":"v0.4.12","_defaultsLoaded":true,"dist":{"shasum":"3bc469d32d67e818055799cc2f7212a6f9b8d25a","tarball":"http://registry.npmjs.org/jshint/-/jshint-0.5.1.tgz"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"}],"directories":{}},"0.5.2":{"name":"jshint","version":"0.5.2","description":"A CLI for JSHint","homepage":"http://github.com/jshint/node-jshint","author":{"name":"Brent Lintner","email":"brent.lintner@gmail.com","url":"http://github.com/brentlintner"},"licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"bin":{"jshint":"./bin/hint"},"main":"packages/jshint/jshint","files":["packages/jshint/README.markdown","packages/jshint/jshint.js","README.md","LICENSE","HELP","bin/hint","lib"],"dependencies":{"argsparser":">=0.0.3","minimatch":">=0.0.4"},"devDependencies":{"jasmine-node":"1.0.7"},"preferGlobal":true,"_npmUser":{"name":"brentlintner","email":"brent.lintner@gmail.com"},"_id":"jshint@0.5.2","engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.0.99","_nodeVersion":"v0.4.12","_defaultsLoaded":true,"dist":{"shasum":"2db6c1b8597fd820ae161f60d77c9db12efe40b9","tarball":"http://registry.npmjs.org/jshint/-/jshint-0.5.2.tgz"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"}],"directories":{}},"0.5.3":{"name":"jshint","version":"0.5.3","description":"A CLI for JSHint","homepage":"http://github.com/jshint/node-jshint","author":{"name":"Brent Lintner","email":"brent.lintner@gmail.com","url":"http://github.com/brentlintner"},"licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"bin":{"jshint":"./bin/hint"},"main":"packages/jshint/jshint","files":["packages/jshint/README.markdown","packages/jshint/jshint.js","README.md","LICENSE","HELP","bin/hint","lib"],"dependencies":{"argsparser":">=0.0.3","minimatch":">=0.0.4"},"devDependencies":{"jasmine-node":"1.0.7"},"preferGlobal":true,"_npmUser":{"name":"brentlintner","email":"brent.lintner@gmail.com"},"_id":"jshint@0.5.3","engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.1.0-alpha-2","_nodeVersion":"v0.6.3","_defaultsLoaded":true,"dist":{"shasum":"7519c1c8d42eca0799f4f30e58b172ff806f5e78","tarball":"http://registry.npmjs.org/jshint/-/jshint-0.5.3.tgz"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"}],"directories":{}},"0.5.4":{"name":"jshint","version":"0.5.4","description":"A CLI for JSHint","homepage":"http://github.com/jshint/node-jshint","author":{"name":"Brent Lintner","email":"brent.lintner@gmail.com","url":"http://github.com/brentlintner"},"licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"bin":{"jshint":"./bin/hint"},"main":"packages/jshint/jshint","files":["packages/jshint/README.markdown","packages/jshint/jshint.js","README.md","LICENSE","HELP","bin/hint","lib"],"dependencies":{"argsparser":">=0.0.3","minimatch":">=0.0.4"},"devDependencies":{"jasmine-node":"1.0.7"},"preferGlobal":true,"_npmUser":{"name":"brentlintner","email":"brent.lintner@gmail.com"},"_id":"jshint@0.5.4","engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.1.0-alpha-2","_nodeVersion":"v0.6.3","_defaultsLoaded":true,"dist":{"shasum":"7660480d2a99fd693addbaeecb56ac5d6ad4e1e2","tarball":"http://registry.npmjs.org/jshint/-/jshint-0.5.4.tgz"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"}],"directories":{}},"0.5.5":{"name":"jshint","version":"0.5.5","description":"A CLI for JSHint","homepage":"http://github.com/jshint/node-jshint","author":{"name":"Brent Lintner","email":"brent.lintner@gmail.com","url":"http://github.com/brentlintner"},"licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"bin":{"jshint":"./bin/hint"},"main":"packages/jshint/jshint","files":["packages/jshint/README.markdown","packages/jshint/jshint.js","README.md","LICENSE","HELP","bin/hint","lib"],"dependencies":{"argsparser":">=0.0.3","minimatch":">=0.0.4"},"devDependencies":{"jasmine-node":"1.0.7"},"preferGlobal":true,"_npmUser":{"name":"brentlintner","email":"brent.lintner@gmail.com"},"_id":"jshint@0.5.5","engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.1.0-alpha-2","_nodeVersion":"v0.6.3","_defaultsLoaded":true,"dist":{"shasum":"f2a2a69ea0d159058cfd56a6bd481866e6d82a82","tarball":"http://registry.npmjs.org/jshint/-/jshint-0.5.5.tgz"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"}],"directories":{}},"0.5.6":{"name":"jshint","version":"0.5.6","description":"A CLI for JSHint","homepage":"http://github.com/jshint/node-jshint","author":{"name":"Brent Lintner","email":"brent.lintner@gmail.com","url":"http://github.com/brentlintner"},"licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"bin":{"jshint":"./bin/hint"},"main":"packages/jshint/jshint","files":["packages/jshint/README.markdown","packages/jshint/jshint.js","README.md","LICENSE","HELP","bin/hint","lib"],"dependencies":{"argsparser":">=0.0.3","minimatch":">=0.0.4"},"devDependencies":{"jasmine-node":"1.0.7"},"preferGlobal":true,"_npmUser":{"name":"brentlintner","email":"brent.lintner@gmail.com"},"_id":"jshint@0.5.6","engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.1.0-beta-10","_nodeVersion":"v0.6.7","_defaultsLoaded":true,"dist":{"shasum":"64ed3d3701d2becbd3f838b4d4280aef72731b2c","tarball":"http://registry.npmjs.org/jshint/-/jshint-0.5.6.tgz"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"}],"directories":{}},"0.5.7":{"name":"jshint","version":"0.5.7","description":"A CLI for JSHint","homepage":"http://github.com/jshint/node-jshint","author":{"name":"Brent Lintner","email":"brent.lintner@gmail.com","url":"http://github.com/brentlintner"},"licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"bin":{"jshint":"./bin/hint"},"main":"packages/jshint/jshint","files":["packages/jshint/README.markdown","packages/jshint/jshint.js","README.md","LICENSE","HELP","bin/hint","lib"],"dependencies":{"argsparser":">=0.0.3","minimatch":">=0.0.4"},"devDependencies":{"jasmine-node":"1.0.7"},"preferGlobal":true,"_npmUser":{"name":"antonkovalyov","email":"anton@kovalyov.net"},"_id":"jshint@0.5.7","engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.0.106","_nodeVersion":"v0.6.5","_defaultsLoaded":true,"dist":{"shasum":"d7944db46f3bb7baefea3d13f23c99a8cd5b753b","tarball":"http://registry.npmjs.org/jshint/-/jshint-0.5.7.tgz"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"0.5.8":{"name":"jshint","version":"0.5.8","description":"A CLI for JSHint","homepage":"http://github.com/jshint/node-jshint","author":{"name":"Brent Lintner","email":"brent.lintner@gmail.com","url":"http://github.com/brentlintner"},"licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"bin":{"jshint":"./bin/hint"},"main":"packages/jshint/jshint","files":["packages/jshint/README.markdown","packages/jshint/jshint.js","README.md","LICENSE","HELP","bin/hint","lib"],"dependencies":{"argsparser":">=0.0.3","minimatch":">=0.0.4"},"devDependencies":{"jasmine-node":"1.0.7"},"preferGlobal":true,"_npmUser":{"name":"antonkovalyov","email":"anton@kovalyov.net"},"_id":"jshint@0.5.8","optionalDependencies":{},"engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.1.0-3","_nodeVersion":"v0.6.9","_defaultsLoaded":true,"dist":{"shasum":"8ce1e5a237aa1d1d8957e6b048028dc26a3e22a8","tarball":"http://registry.npmjs.org/jshint/-/jshint-0.5.8.tgz"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"0.5.9":{"name":"jshint","version":"0.5.9","description":"A CLI for JSHint","homepage":"http://github.com/jshint/node-jshint","author":{"name":"Brent Lintner","email":"brent.lintner@gmail.com","url":"http://github.com/brentlintner"},"licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"bin":{"jshint":"./bin/hint"},"main":"packages/jshint/jshint","files":["packages/jshint/README.markdown","packages/jshint/jshint.js","README.md","LICENSE","HELP","bin/hint","lib"],"dependencies":{"argsparser":">=0.0.3","minimatch":">=0.0.4"},"devDependencies":{"jasmine-node":"1.0.7"},"preferGlobal":true,"_npmUser":{"name":"brentlintner","email":"brent.lintner@gmail.com"},"_id":"jshint@0.5.9","optionalDependencies":{},"engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.1.1","_nodeVersion":"v0.6.11","_defaultsLoaded":true,"dist":{"shasum":"ccb5ba9d2818dfe78857feaa71ccba0cb10aebc9","tarball":"http://registry.npmjs.org/jshint/-/jshint-0.5.9.tgz"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"0.6.0":{"name":"jshint","version":"0.6.0","description":"A CLI for JSHint","homepage":"http://github.com/jshint/node-jshint","author":{"name":"Brent Lintner","email":"brent.lintner@gmail.com","url":"http://github.com/brentlintner"},"licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"bin":{"jshint":"./bin/hint"},"main":"packages/jshint/jshint","files":["packages/jshint/README.markdown","packages/jshint/jshint.js","README.md","LICENSE","HELP","bin/hint","lib"],"dependencies":{"argsparser":"0.0.x","minimatch":"0.0.x"},"devDependencies":{"jasmine-node":"1.0.x"},"preferGlobal":true,"_npmUser":{"name":"brentlintner","email":"brent.lintner@gmail.com"},"_id":"jshint@0.6.0","optionalDependencies":{},"engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.1.12","_nodeVersion":"v0.6.14","_defaultsLoaded":true,"dist":{"shasum":"38c95b34c825861cb7123f913cbcbe9091247d25","tarball":"http://registry.npmjs.org/jshint/-/jshint-0.6.0.tgz"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"0.6.1":{"name":"jshint","version":"0.6.1","description":"A CLI for JSHint","homepage":"http://github.com/jshint/node-jshint","author":{"name":"Brent Lintner","email":"brent.lintner@gmail.com","url":"http://github.com/brentlintner"},"licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"bin":{"jshint":"./bin/hint"},"main":"packages/jshint/jshint","files":["packages/jshint/README.markdown","packages/jshint/jshint.js","README.md","LICENSE","HELP","bin/hint","lib"],"dependencies":{"argsparser":"0.0.x","minimatch":"0.0.x"},"devDependencies":{"jasmine-node":"1.0.x"},"preferGlobal":true,"_npmUser":{"name":"brentlintner","email":"brent.lintner@gmail.com"},"_id":"jshint@0.6.1","optionalDependencies":{},"engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.1.12","_nodeVersion":"v0.6.14","_defaultsLoaded":true,"dist":{"shasum":"5b9e69b5867cb356e25d49d7a642a696207e46fa","tarball":"http://registry.npmjs.org/jshint/-/jshint-0.6.1.tgz"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"0.6.2":{"name":"jshint","version":"0.6.2","description":"A CLI for JSHint","homepage":"http://github.com/jshint/node-jshint","author":{"name":"Brent Lintner","email":"brent.lintner@gmail.com","url":"http://github.com/brentlintner"},"licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"bin":{"jshint":"./bin/hint"},"main":"packages/jshint/jshint","files":["packages/jshint/README.markdown","packages/jshint/jshint.js","README.md","LICENSE","HELP","bin/hint","lib"],"dependencies":{"argsparser":"0.0.x","minimatch":"0.0.x"},"devDependencies":{"jasmine-node":"1.0.x"},"preferGlobal":true,"_npmUser":{"name":"brentlintner","email":"brent.lintner@gmail.com"},"_id":"jshint@0.6.2","optionalDependencies":{},"engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.1.12","_nodeVersion":"v0.6.14","_defaultsLoaded":true,"dist":{"shasum":"b461612bf710df8d71d4274e04f5dcc7bee2a4d1","tarball":"http://registry.npmjs.org/jshint/-/jshint-0.6.2.tgz"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"0.6.3":{"name":"jshint","version":"0.6.3","description":"A CLI for JSHint","homepage":"http://github.com/jshint/node-jshint","author":{"name":"Brent Lintner","email":"brent.lintner@gmail.com","url":"http://github.com/brentlintner"},"licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"bin":{"jshint":"./bin/hint"},"main":"packages/jshint/jshint","files":["packages/jshint/README.markdown","packages/jshint/jshint.js","README.md","LICENSE","HELP","bin/hint","lib"],"dependencies":{"argsparser":"0.0.x","minimatch":"0.0.x"},"devDependencies":{"jasmine-node":"1.0.x"},"preferGlobal":true,"_npmUser":{"name":"antonkovalyov","email":"anton@kovalyov.net"},"_id":"jshint@0.6.3","optionalDependencies":{},"engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.1.0-3","_nodeVersion":"v0.6.9","_defaultsLoaded":true,"dist":{"shasum":"d07c254c928a842fbe92881ad3342c98bdd79530","tarball":"http://registry.npmjs.org/jshint/-/jshint-0.6.3.tgz"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"0.7.0":{"name":"jshint","version":"0.7.0","description":"A CLI for JSHint","homepage":"http://github.com/jshint/node-jshint","author":{"name":"Brent Lintner","email":"brent.lintner@gmail.com","url":"http://github.com/brentlintner"},"licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"bin":{"jshint":"./bin/hint"},"main":"packages/jshint/jshint","files":["packages/jshint/README.markdown","packages/jshint/jshint.js","README.md","LICENSE","HELP","bin/hint","lib"],"dependencies":{"cli":"0.4.3","minimatch":"0.0.x"},"devDependencies":{"jasmine-node":"1.0.x"},"preferGlobal":true,"_npmUser":{"name":"brentlintner","email":"brent.lintner@gmail.com"},"_id":"jshint@0.7.0","optionalDependencies":{},"engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.1.16","_nodeVersion":"v0.6.15","_defaultsLoaded":true,"dist":{"shasum":"4070f1ed3c13c154ce87eb4037593bbb5e4d9cd8","tarball":"http://registry.npmjs.org/jshint/-/jshint-0.7.0.tgz"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"0.7.1":{"name":"jshint","version":"0.7.1","description":"A CLI for JSHint","homepage":"http://github.com/jshint/node-jshint","author":{"name":"Brent Lintner","email":"brent.lintner@gmail.com","url":"http://github.com/brentlintner"},"licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"bin":{"jshint":"./bin/hint"},"main":"packages/jshint/jshint","files":["packages/jshint/README.markdown","packages/jshint/jshint.js","README.md","LICENSE","bin/hint","lib"],"dependencies":{"cli":"0.4.3","minimatch":"0.0.x"},"devDependencies":{"jasmine-node":"1.0.x"},"preferGlobal":true,"_npmUser":{"name":"brentlintner","email":"brent.lintner@gmail.com"},"_id":"jshint@0.7.1","optionalDependencies":{},"engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.1.16","_nodeVersion":"v0.6.15","_defaultsLoaded":true,"dist":{"shasum":"7c62cdd1b260ec71743a9851ce79a9fc9d22ff15","tarball":"http://registry.npmjs.org/jshint/-/jshint-0.7.1.tgz"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"0.7.2":{"name":"jshint","version":"0.7.2","description":"A CLI for JSHint","homepage":"http://github.com/jshint/node-jshint","author":{"name":"Brent Lintner","email":"brent.lintner@gmail.com","url":"http://github.com/brentlintner"},"licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"bin":{"jshint":"./bin/hint"},"main":"packages/jshint/jshint","files":["packages/jshint/README.markdown","packages/jshint/jshint.js","README.md","LICENSE","bin/hint","lib"],"dependencies":{"cli":"0.4.3","minimatch":"0.0.x"},"devDependencies":{"jasmine-node":"1.0.x"},"preferGlobal":true,"_npmUser":{"name":"antonkovalyov","email":"anton@kovalyov.net"},"_id":"jshint@0.7.2","optionalDependencies":{},"engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.1.0-3","_nodeVersion":"v0.6.9","_defaultsLoaded":true,"dist":{"shasum":"35064bd9aef2798e56ae9e81962bdd3435151510","tarball":"http://registry.npmjs.org/jshint/-/jshint-0.7.2.tgz"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"0.7.3":{"name":"jshint","version":"0.7.3","description":"A CLI for JSHint","homepage":"http://github.com/jshint/node-jshint","author":{"name":"Brent Lintner","email":"brent.lintner@gmail.com","url":"http://github.com/brentlintner"},"licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"bin":{"jshint":"./bin/hint"},"main":"packages/jshint/jshint","files":["packages/jshint/README.markdown","packages/jshint/jshint.js","README.md","LICENSE","bin/hint","lib"],"dependencies":{"cli":"0.4.3","minimatch":"0.0.x"},"devDependencies":{"jasmine-node":"1.0.x"},"preferGlobal":true,"_npmUser":{"name":"antonkovalyov","email":"anton@kovalyov.net"},"_id":"jshint@0.7.3","optionalDependencies":{},"engines":{"node":"*"},"_engineSupported":true,"_npmVersion":"1.1.0-3","_nodeVersion":"v0.6.9","_defaultsLoaded":true,"dist":{"shasum":"a1920fe3d12401d36333955691e14e888796e218","tarball":"http://registry.npmjs.org/jshint/-/jshint-0.7.3.tgz"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"0.8.0":{"name":"jshint","version":"0.8.0","description":"A CLI for JSHint","homepage":"http://github.com/jshint/node-jshint","author":{"name":"Brent Lintner","email":"brent.lintner@gmail.com","url":"http://github.com/brentlintner"},"licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"bin":{"jshint":"./bin/hint"},"main":"packages/jshint/jshint","files":["packages/jshint/README.markdown","packages/jshint/jshint.js","README.md","LICENSE","bin/hint","lib"],"dependencies":{"cli":"0.4.3","minimatch":"0.0.x"},"devDependencies":{"jasmine-node":"1.0.x"},"preferGlobal":true,"_id":"jshint@0.8.0","dist":{"shasum":"19393131b1bdff8fadb94c104be8425e65fdade4","tarball":"http://registry.npmjs.org/jshint/-/jshint-0.8.0.tgz"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"0.8.1":{"name":"jshint","version":"0.8.1","description":"A CLI for JSHint","homepage":"http://github.com/jshint/node-jshint","author":{"name":"Brent Lintner","email":"brent.lintner@gmail.com","url":"http://github.com/brentlintner"},"licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"bin":{"jshint":"./bin/hint"},"main":"packages/jshint/jshint","files":["packages/jshint/README.markdown","packages/jshint/jshint.js","README.md","LICENSE","bin/hint","lib"],"dependencies":{"cli":"0.4.3","minimatch":"0.0.x"},"devDependencies":{"jasmine-node":"1.0.x"},"preferGlobal":true,"_id":"jshint@0.8.1","dist":{"shasum":"9bcaeb31a7fd3e799d4bea20be784724feeabead","tarball":"http://registry.npmjs.org/jshint/-/jshint-0.8.1.tgz"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"0.8.2":{"name":"jshint","version":"0.8.2","description":"A CLI for JSHint","homepage":"http://github.com/jshint/node-jshint","author":{"name":"Brent Lintner","email":"brent.lintner@gmail.com","url":"http://github.com/brentlintner"},"licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"bin":{"jshint":"./bin/hint"},"main":"packages/jshint/jshint","files":["packages/jshint/README.markdown","packages/jshint/jshint.js","README.md","LICENSE","bin/hint","lib"],"dependencies":{"cli":"0.4.3","minimatch":"0.0.x"},"devDependencies":{"jasmine-node":"1.0.x"},"preferGlobal":true,"_id":"jshint@0.8.2","dist":{"shasum":"b49311dcbcf7c8cb8aa81319372959f201013191","tarball":"http://registry.npmjs.org/jshint/-/jshint-0.8.2.tgz"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"0.9.0":{"name":"jshint","version":"0.9.0","description":"A CLI for JSHint","homepage":"http://github.com/jshint/node-jshint","author":{"name":"Brent Lintner","email":"brent.lintner@gmail.com","url":"http://github.com/brentlintner"},"licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"bin":{"jshint":"./bin/hint"},"main":"packages/jshint/jshint","files":["packages/jshint/README.markdown","packages/jshint/jshint.js","README.md","LICENSE","bin/hint","lib"],"dependencies":{"cli":"0.4.3","minimatch":"0.0.x"},"devDependencies":{"jasmine-node":"1.0.x"},"preferGlobal":true,"_id":"jshint@0.9.0","dist":{"shasum":"225022bdeb44ac608ce5773ebe01e020eef413c3","tarball":"http://registry.npmjs.org/jshint/-/jshint-0.9.0.tgz"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"0.9.1":{"name":"jshint","version":"0.9.1","description":"A CLI for JSHint","homepage":"http://github.com/jshint/node-jshint","author":{"name":"Brent Lintner","email":"brent.lintner@gmail.com","url":"http://github.com/brentlintner"},"licenses":[{"type":"MIT","url":"http://www.opensource.org/licenses/mit-license.php"}],"bin":{"jshint":"./bin/hint"},"main":"packages/jshint/jshint","files":["packages/jshint/README.markdown","packages/jshint/jshint.js","README.md","LICENSE","bin/hint","lib"],"dependencies":{"cli":"0.4.3","minimatch":"0.0.x"},"devDependencies":{"jasmine-node":"1.0.x"},"preferGlobal":true,"_id":"jshint@0.9.1","dist":{"shasum":"ff32ec7f09f84001f7498eeafd63c9e4fbb2dc0e","tarball":"http://registry.npmjs.org/jshint/-/jshint-0.9.1.tgz"},"_npmVersion":"1.1.59","_npmUser":{"name":"antonkovalyov","email":"anton@kovalyov.net"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"1.0.0":{"name":"jshint","version":"1.0.0","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"bin":{"jshint":"./bin/jshint"},"scripts":{"test":"node ./make.js test","lint":"node ./make.js lint"},"main":"./src/stable/jshint.js","dependencies":{"esprima":"https://github.com/ariya/esprima/tarball/master","shelljs":"*","underscore":"*","peakle":"*","cli":"0.4.3","minimatch":"0.x.x"},"devDependencies":{"jshint":"*","shelljs":"*","browserify":"*","coveraje":"*","nodeunit":"*","sinon":"*"},"preferGlobal":true,"_id":"jshint@1.0.0","dist":{"shasum":"dcd5b7adf776a9f65197990b61fcfa71a3256f03","tarball":"http://registry.npmjs.org/jshint/-/jshint-1.0.0.tgz"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"1.1.0":{"name":"jshint","version":"1.1.0","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"bin":{"jshint":"./bin/jshint"},"scripts":{"test":"node ./make.js test","lint":"node ./make.js lint"},"main":"./src/stable/jshint.js","dependencies":{"esprima":"https://github.com/ariya/esprima/tarball/master","shelljs":"0.1.x","underscore":"1.4.x","peakle":"0.0.x","cli":"0.4.x","minimatch":"0.x.x"},"devDependencies":{"jshint":"1.1.0","shelljs":"0.1.x","browserify":"1.16.1","coveraje":"0.2.x","nodeunit":"0.7.x","sinon":"1.6.x"},"preferGlobal":true,"_id":"jshint@1.1.0","dist":{"shasum":"9987b90b860556cbc7f380d5755a23d504213513","tarball":"http://registry.npmjs.org/jshint/-/jshint-1.1.0.tgz"},"_npmVersion":"1.1.63","_npmUser":{"name":"antonkovalyov","email":"anton@kovalyov.net"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"2.0.0":{"name":"jshint","version":"2.0.0","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"bin":{"jshint":"./bin/jshint"},"scripts":{"build":"node ./make.js build","test":"node ./make.js test","lint":"node ./make.js lint"},"main":"./src/stable/jshint.js","dependencies":{"shelljs":"0.1.x","underscore":"1.4.x","cli":"0.4.x","minimatch":"0.x.x"},"devDependencies":{"jshint":"1.1.0","shelljs":"0.1.x","browserify":"2.12.x","coveraje":"0.2.x","nodeunit":"0.7.x","sinon":"1.6.x","console-browserify":"0.1.x"},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"_id":"jshint@2.0.0","dist":{"shasum":"4a5618819c4e7f63b00bf0ff387ee1360c924306","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.0.0.tgz"},"_npmVersion":"1.1.63","_npmUser":{"name":"antonkovalyov","email":"anton@kovalyov.net"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"2.0.1":{"name":"jshint","version":"2.0.1","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"bin":{"jshint":"./bin/jshint"},"scripts":{"build":"node ./make.js build","test":"node ./make.js test","lint":"node ./make.js lint"},"main":"./src/stable/jshint.js","dependencies":{"shelljs":"0.1.x","underscore":"1.4.x","cli":"0.4.x","minimatch":"0.x.x","console-browserify":"0.1.x"},"devDependencies":{"jshint":"1.1.0","shelljs":"0.1.x","browserify":"2.12.x","coveraje":"0.2.x","nodeunit":"0.7.x","sinon":"1.6.x"},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"_id":"jshint@2.0.1","dist":{"shasum":"b04cde939472afd7ba0ecf98cd0175ba9ed445a4","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.0.1.tgz"},"_npmVersion":"1.1.63","_npmUser":{"name":"antonkovalyov","email":"anton@kovalyov.net"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"2.1.0":{"name":"jshint","version":"2.1.0","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"bin":{"jshint":"./bin/jshint"},"scripts":{"build":"node ./make.js build","test":"node ./make.js test","lint":"node ./make.js lint"},"main":"./src/stable/jshint.js","dependencies":{"shelljs":"0.1.x","underscore":"1.4.x","cli":"0.4.x","minimatch":"0.x.x","console-browserify":"0.1.x"},"devDependencies":{"jshint":"1.1.0","shelljs":"0.1.x","browserify":"2.12.x","coveraje":"0.2.x","nodeunit":"0.7.x","sinon":"1.6.x"},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"_id":"jshint@2.1.0","dist":{"shasum":"a824d872d4a291c8bb0bda9a3aa4f7dfdf2959e1","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.1.0.tgz"},"_npmVersion":"1.1.63","_npmUser":{"name":"antonkovalyov","email":"anton@kovalyov.net"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"2.1.1":{"name":"jshint","version":"2.1.1","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"bin":{"jshint":"./bin/jshint"},"scripts":{"build":"node ./make.js build","test":"node ./make.js test","lint":"node ./make.js lint"},"main":"./src/stable/jshint.js","dependencies":{"shelljs":"0.1.x","underscore":"1.4.x","cli":"0.4.x","minimatch":"0.x.x","console-browserify":"0.1.x"},"devDependencies":{"jshint":"1.1.0","shelljs":"0.1.x","browserify":"2.12.x","coveraje":"0.2.x","nodeunit":"0.7.x","sinon":"1.6.x"},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"_id":"jshint@2.1.1","dist":{"shasum":"a5611a822407a3a6a51079318b8897d85abd2cb8","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.1.1.tgz"},"_npmVersion":"1.1.63","_npmUser":{"name":"antonkovalyov","email":"anton@kovalyov.net"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"2.1.2":{"name":"jshint","version":"2.1.2","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"bin":{"jshint":"./bin/jshint"},"scripts":{"build":"node ./make.js build","test":"node ./make.js test","lint":"node ./make.js lint"},"main":"./src/stable/jshint.js","dependencies":{"shelljs":"0.1.x","underscore":"1.4.x","cli":"0.4.x","minimatch":"0.x.x","console-browserify":"0.1.x"},"devDependencies":{"jshint":"1.1.0","shelljs":"0.1.x","browserify":"2.12.x","coveraje":"0.2.x","nodeunit":"0.7.x","sinon":"1.6.x"},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"_id":"jshint@2.1.2","dist":{"shasum":"1fb7b77df7b8620c17d4f807945bb2d24990969e","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.1.2.tgz"},"_npmVersion":"1.1.63","_npmUser":{"name":"antonkovalyov","email":"anton@kovalyov.net"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"2.1.3":{"name":"jshint","version":"2.1.3","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"build":"node ./make.js build","test":"node ./make.js test","lint":"node ./make.js lint"},"main":"./src/stable/jshint.js","dependencies":{"shelljs":"0.1.x","underscore":"1.4.x","cli":"0.4.x","minimatch":"0.x.x","console-browserify":"0.1.x"},"devDependencies":{"jshint":"2.1.x","shelljs":"0.1.x","browserify":"2.12.x","coveraje":"0.2.x","nodeunit":"0.8.x","sinon":"1.7.x"},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"_id":"jshint@2.1.3","dist":{"shasum":"2392e062f7f080fc5ee6d6db8164b6c81b1abaaf","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.1.3.tgz"},"_from":".","_npmVersion":"1.2.21","_npmUser":{"name":"antonkovalyov","email":"anton@kovalyov.net"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"2.1.4":{"name":"jshint","version":"2.1.4","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"build":"node ./make.js build","test":"node ./make.js test","lint":"node ./make.js lint"},"main":"./src/stable/jshint.js","dependencies":{"shelljs":"0.1.x","underscore":"1.4.x","cli":"0.4.x","minimatch":"0.x.x","console-browserify":"0.1.x"},"devDependencies":{"jshint":"2.1.x","shelljs":"0.1.x","browserify":"2.12.x","coveraje":"0.2.x","nodeunit":"0.8.x","sinon":"1.7.x"},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"_id":"jshint@2.1.4","dist":{"shasum":"8d5be86628eea91c073c8700dd6e4c90afd9ab38","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.1.4.tgz"},"_from":".","_npmVersion":"1.2.21","_npmUser":{"name":"antonkovalyov","email":"anton@kovalyov.net"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"2.1.5":{"name":"jshint","version":"2.1.5","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"build":"node ./make.js build","test":"node ./make.js test","lint":"node ./make.js lint"},"main":"./src/stable/jshint.js","dependencies":{"shelljs":"0.1.x","underscore":"1.4.x","cli":"0.4.x","minimatch":"0.x.x","console-browserify":"0.1.x"},"devDependencies":{"jshint":"2.1.x","shelljs":"0.1.x","browserify":"2.12.x","coveraje":"0.2.x","nodeunit":"0.8.x","sinon":"1.7.x"},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"files":["bin","src"],"_id":"jshint@2.1.5","dist":{"shasum":"fc95a40ea89a14522fec1d03950f6eaa0e363499","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.1.5.tgz"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"2.1.6":{"name":"jshint","version":"2.1.6","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"build":"node ./make.js build","test":"node ./make.js test","lint":"node ./make.js lint"},"main":"./src/stable/jshint.js","dependencies":{"shelljs":"0.1.x","underscore":"1.4.x","cli":"0.4.x","minimatch":"0.x.x","console-browserify":"0.1.x"},"devDependencies":{"jshint":"2.1.x","shelljs":"0.1.x","browserify":"2.12.x","coveraje":"0.2.x","nodeunit":"0.8.x","sinon":"1.7.x"},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"files":["bin","src"],"_id":"jshint@2.1.6","dist":{"shasum":"8e00e8893099128fc3d4478e3aedba8079ff3b02","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.1.6.tgz"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"2.1.7":{"name":"jshint","version":"2.1.7","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"build":"node ./make.js build","test":"node ./make.js test","lint":"node ./make.js lint"},"main":"./src/stable/jshint.js","dependencies":{"shelljs":"0.1.x","underscore":"1.4.x","cli":"0.4.x","minimatch":"0.x.x","console-browserify":"0.1.x"},"devDependencies":{"jshint":"2.1.x","shelljs":"0.1.x","browserify":"2.12.x","coveraje":"0.2.x","nodeunit":"0.8.x","sinon":"1.7.x"},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"files":["bin","src"],"_id":"jshint@2.1.7","dist":{"shasum":"11f4214333a0cd2df88057b88c4d751d0c0658a0","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.1.7.tgz"},"_from":".","_npmVersion":"1.2.21","_npmUser":{"name":"antonkovalyov","email":"anton@kovalyov.net"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"2.1.8":{"name":"jshint","version":"2.1.8","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"build":"node ./make.js build","test":"node ./make.js test","lint":"node ./make.js lint"},"main":"./src/stable/jshint.js","dependencies":{"shelljs":"0.1.x","underscore":"1.4.x","cli":"0.4.x","minimatch":"0.x.x","console-browserify":"0.1.x"},"devDependencies":{"jshint":"2.1.x","shelljs":"0.1.x","browserify":"2.12.x","coveraje":"0.2.x","nodeunit":"0.8.x","sinon":"1.7.x"},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"files":["bin","src"],"_id":"jshint@2.1.8","dist":{"shasum":"c4bfe5c28718d101148cfba9e285053a7671ccf2","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.1.8.tgz"},"_from":".","_npmVersion":"1.2.21","_npmUser":{"name":"antonkovalyov","email":"anton@kovalyov.net"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"2.1.9":{"name":"jshint","version":"2.1.9","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"build":"node make.js build","test":"nodeunit tests tests/stable/regression tests/stable/unit","pretest":"jshint --config=jshint.json src"},"main":"./src/stable/jshint.js","dependencies":{"shelljs":"0.1.x","underscore":"1.4.x","cli":"0.4.x","minimatch":"0.x.x","console-browserify":"0.1.x"},"devDependencies":{"jshint":"2.1.x","shelljs":"0.1.x","browserify":"2.12.x","coveraje":"0.2.x","nodeunit":"0.8.x","sinon":"1.7.x"},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"files":["bin","src"],"_id":"jshint@2.1.9","dist":{"shasum":"65cdbb2302cbf27e45db0066669b5d5e74f66465","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.1.9.tgz"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"2.1.10":{"name":"jshint","version":"2.1.10","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"build":"node make.js build","test":"nodeunit tests tests/regression tests/unit","pretest":"jshint src"},"main":"./src/jshint.js","dependencies":{"shelljs":"0.1.x","underscore":"1.4.x","cli":"0.4.x","minimatch":"0.x.x","console-browserify":"0.1.x"},"devDependencies":{"jshint":"2.1.x","shelljs":"0.1.x","browserify":"2.12.x","coveraje":"0.2.x","nodeunit":"0.8.x","sinon":"1.7.x"},"jshintConfig":{"boss":true,"node":true,"strict":true,"white":true,"smarttabs":true,"maxlen":100,"newcap":false,"undef":true,"unused":true,"onecase":true,"indent":2},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"files":["bin","src"],"_id":"jshint@2.1.10","dist":{"shasum":"0c015ec5bc5ad65c11c4b5152f221f24b7af5522","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.1.10.tgz"},"_from":".","_npmVersion":"1.2.21","_npmUser":{"name":"antonkovalyov","email":"anton@kovalyov.net"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"2.1.11":{"name":"jshint","version":"2.1.11","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"build":"node bin/build","test":"nodeunit tests tests/regression tests/unit","pretest":"jshint src"},"main":"./src/jshint.js","dependencies":{"shelljs":"0.1.x","underscore":"1.4.x","cli":"0.4.x","minimatch":"0.x.x","console-browserify":"0.1.x"},"devDependencies":{"jshint":"2.1.x","shelljs":"0.1.x","browserify":"2.12.x","coveraje":"0.2.x","nodeunit":"0.8.x","sinon":"1.7.x"},"jshintConfig":{"boss":true,"node":true,"strict":true,"white":true,"smarttabs":true,"maxlen":100,"newcap":false,"undef":true,"unused":true,"onecase":true,"indent":2},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"files":["bin","src"],"_id":"jshint@2.1.11","dist":{"shasum":"eb5108fef9ba5ddebb830983f572d242e49e3f96","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.1.11.tgz"},"_from":".","_npmVersion":"1.2.21","_npmUser":{"name":"antonkovalyov","email":"anton@kovalyov.net"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"2.2.0":{"name":"jshint","version":"2.2.0","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"data":"node scripts/generate-identifier-data","build":"node bin/build","test":"nodeunit tests tests/regression tests/unit","pretest":"jshint src"},"main":"./src/jshint.js","dependencies":{"shelljs":"0.1.x","underscore":"1.4.x","cli":"0.4.x","minimatch":"0.x.x","console-browserify":"0.1.x"},"devDependencies":{"jshint":"2.1.x","shelljs":"0.1.x","browserify":"2.12.x","coveraje":"0.2.x","nodeunit":"0.8.x","sinon":"1.7.x","unicode-6.3.0":"0.1.x","regenerate":"0.5.x"},"jshintConfig":{"boss":true,"node":true,"strict":true,"white":true,"smarttabs":true,"maxlen":100,"newcap":false,"undef":true,"unused":true,"onecase":true,"indent":2},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"files":["bin","src","data"],"_id":"jshint@2.2.0","dist":{"shasum":"9cd120e17c6635a5bfd6339531b088ed33eb5af2","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.2.0.tgz"},"_from":".","_npmVersion":"1.3.5","_npmUser":{"name":"antonkovalyov","email":"anton@kovalyov.net"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"2.3.0":{"name":"jshint","version":"2.3.0","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"data":"node scripts/generate-identifier-data","build":"node bin/build","test":"nodeunit tests tests/regression tests/unit","pretest":"jshint src"},"main":"./src/jshint.js","dependencies":{"shelljs":"0.1.x","underscore":"1.4.x","cli":"0.4.x","minimatch":"0.x.x","console-browserify":"0.1.x"},"devDependencies":{"jshint":"2.3.x","shelljs":"0.1.x","browserify":"2.12.x","coveraje":"0.2.x","nodeunit":"0.8.x","sinon":"1.7.x","unicode-6.3.0":"0.1.x","regenerate":"0.5.x"},"jshintConfig":{"boss":true,"node":true,"strict":true,"white":true,"smarttabs":true,"maxlen":100,"newcap":false,"undef":true,"unused":true,"onecase":true,"indent":2},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"files":["bin","src","data"],"_id":"jshint@2.3.0","dist":{"shasum":"19504455a2c20c46ee183361eb87f3a1c0b7dc47","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.3.0.tgz"},"_from":".","_npmVersion":"1.3.5","_npmUser":{"name":"antonkovalyov","email":"anton@kovalyov.net"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"2.4.0":{"name":"jshint","version":"2.4.0","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"data":"node scripts/generate-identifier-data","build":"node bin/build","test":"nodeunit tests tests/regression tests/unit","pretest":"jshint src"},"main":"./src/jshint.js","dependencies":{"shelljs":"0.1.x","underscore":"1.4.x","cli":"0.4.x","minimatch":"0.x.x","htmlparser2":"3.3.x","console-browserify":"0.1.x"},"devDependencies":{"jshint":"2.4.x","shelljs":"0.1.x","browserify":"3.x","coveraje":"0.2.x","nodeunit":"0.8.x","sinon":"1.7.x","unicode-6.3.0":"0.1.x","regenerate":"0.5.x"},"jshintConfig":{"boss":true,"node":true,"strict":true,"white":true,"smarttabs":true,"maxlen":100,"newcap":false,"undef":true,"unused":true,"onecase":true,"indent":2},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"files":["bin","src","data"],"_id":"jshint@2.4.0","dist":{"shasum":"31717646cee2137cdd7f1b773c3fce58f4d99fc5","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.4.0.tgz"},"_from":".","_npmVersion":"1.3.5","_npmUser":{"name":"antonkovalyov","email":"anton@kovalyov.net"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"2.4.1":{"name":"jshint","version":"2.4.1","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"data":"node scripts/generate-identifier-data","build":"node bin/build","test":"nodeunit tests tests/regression tests/unit","pretest":"jshint src"},"main":"./src/jshint.js","dependencies":{"shelljs":"0.1.x","underscore":"1.4.x","cli":"0.4.x","minimatch":"0.x.x","htmlparser2":"3.3.x","console-browserify":"0.1.x"},"devDependencies":{"jshint":"2.4.x","shelljs":"0.1.x","browserify":"3.x","coveraje":"0.2.x","nodeunit":"0.8.x","sinon":"1.7.x","unicode-6.3.0":"0.1.x","regenerate":"0.5.x"},"jshintConfig":{"boss":true,"node":true,"strict":true,"white":true,"smarttabs":true,"maxlen":100,"newcap":false,"undef":true,"unused":true,"onecase":true,"indent":2},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"files":["bin","src","data"],"_id":"jshint@2.4.1","dist":{"shasum":"833f361a56577b80816b64f18434cce3b3942591","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.4.1.tgz"},"_from":".","_npmVersion":"1.2.21","_npmUser":{"name":"antonkovalyov","email":"anton@kovalyov.net"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"2.4.2":{"name":"jshint","version":"2.4.2","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"data":"node scripts/generate-identifier-data","build":"node bin/build","test":"nodeunit tests tests/regression tests/unit","pretest":"jshint src"},"main":"./src/jshint.js","dependencies":{"shelljs":"0.1.x","underscore":"1.4.x","cli":"0.4.x","minimatch":"0.x.x","htmlparser2":"3.3.x","console-browserify":"0.1.x"},"devDependencies":{"jshint":"2.4.x","shelljs":"0.1.x","browserify":"3.x","coveraje":"0.2.x","nodeunit":"0.8.x","sinon":"1.7.x","unicode-6.3.0":"0.1.x","regenerate":"0.5.x"},"jshintConfig":{"boss":true,"node":true,"strict":true,"white":true,"smarttabs":true,"maxlen":100,"newcap":false,"undef":true,"unused":true,"onecase":true,"indent":2},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"files":["bin","src","data"],"_id":"jshint@2.4.2","dist":{"shasum":"4f85a8e3133e5bded5b84e06718889bcbb9fa4d0","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.4.2.tgz"},"_from":".","_npmVersion":"1.2.21","_npmUser":{"name":"antonkovalyov","email":"anton@kovalyov.net"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"2.4.3":{"name":"jshint","version":"2.4.3","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"data":"node scripts/generate-identifier-data","build":"node bin/build","test":"nodeunit tests tests/regression tests/unit","pretest":"jshint src"},"main":"./src/jshint.js","dependencies":{"shelljs":"0.1.x","underscore":"1.4.x","cli":"0.4.x","minimatch":"0.x.x","htmlparser2":"3.3.x","console-browserify":"0.1.x"},"devDependencies":{"jshint":"2.4.x","shelljs":"0.1.x","browserify":"3.x","coveraje":"0.2.x","nodeunit":"0.8.x","sinon":"1.7.x","unicode-6.3.0":"0.1.x","regenerate":"0.5.x"},"jshintConfig":{"boss":true,"node":true,"strict":true,"white":true,"smarttabs":true,"maxlen":100,"newcap":false,"undef":true,"unused":true,"onecase":true,"indent":2},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"files":["bin","src","data"],"_id":"jshint@2.4.3","dist":{"shasum":"1beb074b4d9f817773bb5aa16882fd67164c216a","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.4.3.tgz"},"_from":".","_npmVersion":"1.3.5","_npmUser":{"name":"antonkovalyov","email":"anton@kovalyov.net"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"2.4.4":{"name":"jshint","version":"2.4.4","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"data":"node scripts/generate-identifier-data","build":"node bin/build","test":"nodeunit tests tests/regression tests/unit","pretest":"jshint src"},"main":"./src/jshint.js","dependencies":{"shelljs":"0.1.x","underscore":"1.4.x","cli":"0.4.x","minimatch":"0.x.x","htmlparser2":"3.3.x","console-browserify":"0.1.x","exit":"0.1.x"},"devDependencies":{"jshint":"2.4.x","shelljs":"0.1.x","browserify":"3.x","coveraje":"0.2.x","nodeunit":"0.8.x","sinon":"1.7.x","unicode-6.3.0":"0.1.x","regenerate":"0.5.x"},"jshintConfig":{"boss":true,"node":true,"strict":true,"white":true,"smarttabs":true,"maxlen":100,"newcap":false,"undef":true,"unused":true,"onecase":true,"indent":2},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"files":["bin","src","data"],"_id":"jshint@2.4.4","dist":{"shasum":"4162238314c649f987752651e8e064e30a68706e","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.4.4.tgz"},"_from":".","_npmVersion":"1.2.21","_npmUser":{"name":"antonkovalyov","email":"anton@kovalyov.net"},"maintainers":[{"name":"brentlintner","email":"brent.lintner@gmail.com"},{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"2.5.0":{"name":"jshint","version":"2.5.0","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"data":"node scripts/generate-identifier-data","build":"node bin/build","test":"nodeunit tests tests/regression tests/unit","pretest":"jshint src"},"main":"./src/jshint.js","dependencies":{"shelljs":"0.1.x","underscore":"1.4.x","cli":"0.4.x","minimatch":"0.x.x","htmlparser2":"3.3.x","console-browserify":"0.1.x","exit":"0.1.x","strip-json-comments":"0.1.x"},"devDependencies":{"jshint":"2.4.x","shelljs":"0.1.x","browserify":"3.x","coveraje":"0.2.x","nodeunit":"0.8.x","sinon":"1.7.x","unicode-6.3.0":"0.1.x","regenerate":"0.5.x"},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"files":["bin","src","data"],"_id":"jshint@2.5.0","dist":{"shasum":"82fd1a235ffce75fad1b40b2a38bef47beac8c54","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.5.0.tgz"},"_from":".","_npmVersion":"1.4.6","_npmUser":{"name":"antonkovalyov","email":"anton@kovalyov.net"},"maintainers":[{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"2.5.1":{"name":"jshint","version":"2.5.1","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"data":"node scripts/generate-identifier-data","build":"node bin/build","test":"nodeunit tests tests/regression tests/unit","pretest":"jshint src"},"main":"./src/jshint.js","dependencies":{"shelljs":"0.3.x","underscore":"1.6.x","cli":"0.6.x","minimatch":"0.x.x","htmlparser2":"3.7.x","console-browserify":"1.1.x","exit":"0.1.x","strip-json-comments":"0.1.x"},"devDependencies":{"jshint":"2.5.x","browserify":"4.x","coveraje":"0.2.x","nodeunit":"0.9.x","sinon":"1.9.x","unicode-6.3.0":"0.1.x","regenerate":"0.6.x"},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"files":["bin","src","data","dist"],"_id":"jshint@2.5.1","dist":{"shasum":"8e96d27377806767d40f16676fbec113d33520ec","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.5.1.tgz"},"_from":".","_npmVersion":"1.4.6","_npmUser":{"name":"antonkovalyov","email":"anton@kovalyov.net"},"maintainers":[{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"2.5.2":{"name":"jshint","version":"2.5.2","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"data":"node scripts/generate-identifier-data","build":"node bin/build","test":"nodeunit tests tests/regression tests/unit","pretest":"jshint src"},"main":"./src/jshint.js","dependencies":{"shelljs":"0.3.x","underscore":"1.6.x","cli":"0.6.x","minimatch":"0.x.x","htmlparser2":"3.7.x","console-browserify":"1.1.x","exit":"0.1.x","strip-json-comments":"0.1.x"},"devDependencies":{"jshint":"2.5.x","browserify":"4.x","coveraje":"0.2.x","nodeunit":"0.9.x","sinon":"1.9.x","unicode-6.3.0":"0.1.x","regenerate":"0.6.x"},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"files":["bin","src","data","dist"],"_id":"jshint@2.5.2","dist":{"shasum":"bec223d5149e49ef6ea96dcf8b3504a27613e8be","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.5.2.tgz"},"_from":".","_npmVersion":"1.4.6","_npmUser":{"name":"antonkovalyov","email":"anton@kovalyov.net"},"maintainers":[{"name":"antonkovalyov","email":"anton@kovalyov.net"}],"directories":{}},"2.5.3":{"name":"jshint","version":"2.5.3","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"data":"node scripts/generate-identifier-data","build":"node bin/build","test":"nodeunit tests tests/regression tests/unit","pretest":"jshint src"},"main":"./src/jshint.js","dependencies":{"shelljs":"0.3.x","underscore":"1.6.x","cli":"0.6.x","minimatch":"0.x.x","htmlparser2":"3.7.x","console-browserify":"1.1.x","exit":"0.1.x","strip-json-comments":"0.1.x"},"devDependencies":{"jshint":"2.5.x","browserify":"4.x","coveraje":"0.2.x","nodeunit":"0.9.x","sinon":"1.9.x","unicode-6.3.0":"0.1.x","regenerate":"0.6.x"},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"files":["bin","src","data","dist"],"gitHead":"e3250b47e0c1fbb11a782864166900ba5b60cf41","_id":"jshint@2.5.3","_shasum":"821c14ff5ccaa458ae1b34a2caa70bf753f963ea","_from":".","_npmVersion":"1.5.0-alpha-1","_npmUser":{"name":"rwaldron","email":"waldron.rick@gmail.com"},"maintainers":[{"name":"antonkovalyov","email":"anton@kovalyov.net"},{"name":"rwaldron","email":"waldron.rick@gmail.com"}],"dist":{"shasum":"821c14ff5ccaa458ae1b34a2caa70bf753f963ea","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.5.3.tgz"},"directories":{}},"2.5.4":{"name":"jshint","version":"2.5.4","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"data":"node scripts/generate-identifier-data","build":"node bin/build","test":"nodeunit tests tests/regression tests/unit","pretest":"jshint src"},"main":"./src/jshint.js","dependencies":{"shelljs":"0.3.x","underscore":"1.6.x","cli":"0.6.x","minimatch":"0.x.x","htmlparser2":"3.7.x","console-browserify":"1.1.x","exit":"0.1.x","strip-json-comments":"0.1.x"},"devDependencies":{"jshint":"2.5.x","browserify":"4.x","coveraje":"0.2.x","nodeunit":"0.9.x","sinon":"1.9.x","unicode-6.3.0":"0.1.x","regenerate":"0.6.x"},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"files":["bin","src","data","dist"],"gitHead":"be724857242ecf6931387feed23d5cae285354d0","_id":"jshint@2.5.4","_shasum":"3dc82cb37b381b65f0e95ec7a616d39b4e95faef","_from":".","_npmVersion":"1.5.0-alpha-1","_npmUser":{"name":"rwaldron","email":"waldron.rick@gmail.com"},"maintainers":[{"name":"antonkovalyov","email":"anton@kovalyov.net"},{"name":"rwaldron","email":"waldron.rick@gmail.com"}],"dist":{"shasum":"3dc82cb37b381b65f0e95ec7a616d39b4e95faef","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.5.4.tgz"},"directories":{}},"2.5.5":{"name":"jshint","version":"2.5.5","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"data":"node scripts/generate-identifier-data","build":"node bin/build","test":"nodeunit tests tests/regression tests/unit","pretest":"jshint src"},"main":"./src/jshint.js","dependencies":{"shelljs":"0.3.x","underscore":"1.6.x","cli":"0.6.x","minimatch":"0.x.x","htmlparser2":"3.7.x","console-browserify":"1.1.x","exit":"0.1.x","strip-json-comments":"0.1.x"},"devDependencies":{"jshint":"2.5.x","browserify":"4.x","coveraje":"0.2.x","nodeunit":"0.9.x","sinon":"1.9.x","unicode-6.3.0":"0.1.x","regenerate":"0.6.x"},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"files":["bin","src","data","dist"],"gitHead":"94df11c872bccd979c8deffed612e4421abdf17d","_id":"jshint@2.5.5","_shasum":"9f24958dcd11c5e2ceba96ec92225873b02f4775","_from":".","_npmVersion":"1.5.0-alpha-1","_npmUser":{"name":"rwaldron","email":"waldron.rick@gmail.com"},"maintainers":[{"name":"antonkovalyov","email":"anton@kovalyov.net"},{"name":"rwaldron","email":"waldron.rick@gmail.com"}],"dist":{"shasum":"9f24958dcd11c5e2ceba96ec92225873b02f4775","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.5.5.tgz"},"directories":{}},"2.5.6":{"name":"jshint","version":"2.5.6","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"data":"node scripts/generate-identifier-data","build":"node bin/build","test":"nodeunit tests tests/regression tests/unit","pretest":"jshint src"},"main":"./src/jshint.js","dependencies":{"shelljs":"0.3.x","underscore":"1.6.x","cli":"0.6.x","minimatch":"1.0.x","htmlparser2":"3.7.x","console-browserify":"1.1.x","exit":"0.1.x","strip-json-comments":"1.0.x"},"devDependencies":{"jshint":"2.5.x","browserify":"5.x","coveraje":"0.2.x","nodeunit":"0.9.x","sinon":"1.10.x","unicode-6.3.0":"0.1.x","regenerate":"0.6.x"},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"files":["bin","src","data","dist"],"gitHead":"17e9355cd27ef53c76c82e9c8514118eabe25ffe","_id":"jshint@2.5.6","_shasum":"1685ce1f9e1c74832375d83fe89728589bd9d8c7","_from":".","_npmVersion":"1.5.0-alpha-1","_npmUser":{"name":"rwaldron","email":"waldron.rick@gmail.com"},"maintainers":[{"name":"antonkovalyov","email":"anton@kovalyov.net"},{"name":"rwaldron","email":"waldron.rick@gmail.com"}],"dist":{"shasum":"1685ce1f9e1c74832375d83fe89728589bd9d8c7","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.5.6.tgz"},"directories":{}},"2.5.7":{"name":"jshint","version":"2.5.7","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"data":"node scripts/generate-identifier-data","build":"node bin/build","test":"nodeunit tests tests/regression tests/unit","pretest":"jshint src"},"main":"./src/jshint.js","dependencies":{"shelljs":"0.3.x","underscore":"1.6.x","cli":"0.6.x","minimatch":"1.0.x","htmlparser2":"3.7.x","console-browserify":"1.1.x","exit":"0.1.x","strip-json-comments":"1.0.x"},"devDependencies":{"jshint":"2.5.x","browserify":"6.x","coveraje":"0.2.x","nodeunit":"0.9.x","sinon":"1.10.x","unicode-6.3.0":"0.1.x","regenerate":"0.6.x","mock-stdin":"^0.3.0"},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"files":["bin","src","data","dist"],"gitHead":"5b779e62d99c1182581167d07a870b34fc4579b0","_id":"jshint@2.5.7","_shasum":"69a6dfa046f3164f904a82f9b0ab57192fc13749","_from":".","_npmVersion":"1.5.0-alpha-1","_npmUser":{"name":"rwaldron","email":"waldron.rick@gmail.com"},"maintainers":[{"name":"antonkovalyov","email":"anton@kovalyov.net"},{"name":"rwaldron","email":"waldron.rick@gmail.com"}],"dist":{"shasum":"69a6dfa046f3164f904a82f9b0ab57192fc13749","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.5.7.tgz"},"directories":{}},"2.5.8":{"name":"jshint","version":"2.5.8","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"build":"node bin/build","data":"node scripts/generate-identifier-data","pretest":"jshint src","test":"nodeunit tests tests/regression tests/unit"},"main":"./src/jshint.js","dependencies":{"cli":"0.6.x","console-browserify":"1.1.x","exit":"0.1.x","htmlparser2":"3.8.x","minimatch":"1.0.x","shelljs":"0.3.x","strip-json-comments":"1.0.x","underscore":"1.6.x"},"devDependencies":{"browserify":"6.x","coveraje":"0.2.x","jshint":"2.5.x","mock-stdin":"0.3.x","nodeunit":"0.9.x","regenerate":"1.0.x","sinon":"1.11.x","unicode-6.3.0":"0.1.x"},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"files":["bin","data","dist","src"],"gitHead":"53556a7e6a4f6a7bb1bee6e83a229e0481b782b9","_id":"jshint@2.5.8","_shasum":"31ddb3c17df48fe04cff24abe0a1bb1c1bc529f5","_from":".","_npmVersion":"1.5.0-alpha-1","_npmUser":{"name":"rwaldron","email":"waldron.rick@gmail.com"},"maintainers":[{"name":"antonkovalyov","email":"anton@kovalyov.net"},{"name":"rwaldron","email":"waldron.rick@gmail.com"}],"dist":{"shasum":"31ddb3c17df48fe04cff24abe0a1bb1c1bc529f5","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.5.8.tgz"},"directories":{}},"2.5.9":{"name":"jshint","version":"2.5.9","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"build":"node bin/build","data":"node scripts/generate-identifier-data","pretest":"jshint src","test":"nodeunit tests tests/regression tests/unit"},"main":"./src/jshint.js","dependencies":{"cli":"0.6.x","console-browserify":"1.1.x","exit":"0.1.x","htmlparser2":"3.8.x","minimatch":"1.0.x","shelljs":"0.3.x","strip-json-comments":"1.0.x","underscore":"1.6.x"},"devDependencies":{"browserify":"6.x","coveraje":"0.2.x","jshint":"2.5.x","mock-stdin":"0.3.x","nodeunit":"0.9.x","regenerate":"1.0.x","sinon":"1.11.x","unicode-6.3.0":"0.1.x"},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"files":["bin","data","dist","src"],"gitHead":"1839f7a0b504890fec60d27e0d6945cb52a697fb","_id":"jshint@2.5.9","_shasum":"c2d514d6dcc03bfc4d0c5c1f5d1033a4cc1539d4","_from":".","_npmVersion":"1.5.0-alpha-1","_npmUser":{"name":"rwaldron","email":"waldron.rick@gmail.com"},"maintainers":[{"name":"antonkovalyov","email":"anton@kovalyov.net"},{"name":"rwaldron","email":"waldron.rick@gmail.com"}],"dist":{"shasum":"c2d514d6dcc03bfc4d0c5c1f5d1033a4cc1539d4","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.5.9.tgz"},"directories":{}},"2.5.10":{"name":"jshint","version":"2.5.10","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"build":"node bin/build","data":"node scripts/generate-identifier-data","pretest":"jshint src","test":"nodeunit tests tests/regression tests/unit"},"main":"./src/jshint.js","dependencies":{"cli":"0.6.x","console-browserify":"1.1.x","exit":"0.1.x","htmlparser2":"3.8.x","minimatch":"1.0.x","shelljs":"0.3.x","strip-json-comments":"1.0.x","underscore":"1.6.x"},"devDependencies":{"browserify":"6.x","coveraje":"0.2.x","jshint":"2.5.x","mock-stdin":"0.3.x","nodeunit":"0.9.x","regenerate":"1.0.x","sinon":"1.11.x","unicode-6.3.0":"0.1.x"},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"files":["bin","data","dist","src"],"gitHead":"3a71ce850c57be8c03599462f42245708387a5f6","_id":"jshint@2.5.10","_shasum":"2fef47ee0901914e31832123d5d3f434c28060ef","_from":".","_npmVersion":"1.5.0-alpha-1","_npmUser":{"name":"rwaldron","email":"waldron.rick@gmail.com"},"maintainers":[{"name":"antonkovalyov","email":"anton@kovalyov.net"},{"name":"rwaldron","email":"waldron.rick@gmail.com"}],"dist":{"shasum":"2fef47ee0901914e31832123d5d3f434c28060ef","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.5.10.tgz"},"directories":{}},"2.5.11":{"name":"jshint","version":"2.5.11","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"build":"node bin/build","coverage":"istanbul -- cover ./node_modules/.bin/nodeunit tests/unit","data":"node scripts/generate-identifier-data","pretest":"jshint src","test":"nodeunit tests tests/regression tests/unit"},"main":"./src/jshint.js","dependencies":{"cli":"0.6.x","console-browserify":"1.1.x","exit":"0.1.x","htmlparser2":"3.8.x","minimatch":"1.0.x","shelljs":"0.3.x","strip-json-comments":"1.0.x","underscore":"1.6.x"},"devDependencies":{"browserify":"6.x","coveralls":"2.11.x","istanbul":"0.3.x","jshint":"2.5.x","mock-stdin":"0.3.x","nodeunit":"0.9.x","regenerate":"1.0.x","sinon":"1.11.x","unicode-6.3.0":"0.1.x"},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"files":["bin","data","dist","src"],"gitHead":"29bda1104e117c34bdd7702854fbc40cd00e66ac","_id":"jshint@2.5.11","_shasum":"e2d95858bbb1aa78300108a2e81099fb095622e0","_from":".","_npmVersion":"1.5.0-alpha-1","_npmUser":{"name":"rwaldron","email":"waldron.rick@gmail.com"},"maintainers":[{"name":"antonkovalyov","email":"anton@kovalyov.net"},{"name":"rwaldron","email":"waldron.rick@gmail.com"}],"dist":{"shasum":"e2d95858bbb1aa78300108a2e81099fb095622e0","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.5.11.tgz"},"directories":{}},"2.6.0":{"name":"jshint","version":"2.6.0","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"build":"node bin/build","coverage":"istanbul -- cover ./node_modules/.bin/nodeunit tests/unit","data":"node scripts/generate-identifier-data","pretest":"jshint src && jscs src","test":"nodeunit tests tests/regression tests/unit"},"main":"./src/jshint.js","dependencies":{"cli":"0.6.x","console-browserify":"1.1.x","exit":"0.1.x","htmlparser2":"3.8.x","minimatch":"1.0.x","shelljs":"0.3.x","strip-json-comments":"1.0.x","underscore":"1.6.x"},"devDependencies":{"browserify":"6.x","coveralls":"2.11.x","istanbul":"0.3.x","jscs":"1.9.x","jshint":"2.5.x","mock-stdin":"0.3.x","nodeunit":"0.9.x","regenerate":"1.0.x","sinon":"1.11.x","unicode-6.3.0":"0.1.x"},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"files":["bin","data","dist","src"],"gitHead":"f1fabe31294552a05d41259e64bb83427bfb2f7f","_id":"jshint@2.6.0","_shasum":"04e59d04da83aa32301d89115628274871597f33","_from":".","_npmVersion":"2.1.18","_nodeVersion":"0.10.35","_npmUser":{"name":"rwaldron","email":"waldron.rick@gmail.com"},"maintainers":[{"name":"antonkovalyov","email":"anton@kovalyov.net"},{"name":"rwaldron","email":"waldron.rick@gmail.com"}],"dist":{"shasum":"04e59d04da83aa32301d89115628274871597f33","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.6.0.tgz"},"directories":{}},"2.6.1":{"name":"jshint","version":"2.6.1","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"build":"node bin/build","coverage":"istanbul -- cover ./node_modules/.bin/nodeunit tests/unit","data":"node scripts/generate-identifier-data","pretest":"jshint src && jscs src","test":"nodeunit tests tests/regression tests/unit"},"main":"./src/jshint.js","dependencies":{"cli":"0.6.x","console-browserify":"1.1.x","exit":"0.1.x","htmlparser2":"3.8.x","minimatch":"1.0.x","shelljs":"0.3.x","strip-json-comments":"1.0.x","underscore":"1.6.x"},"devDependencies":{"browserify":"6.x","coveralls":"2.11.x","istanbul":"0.3.x","jscs":"1.11.x","jshint":"2.5.x","mock-stdin":"0.3.x","nodeunit":"0.9.x","regenerate":"1.0.x","sinon":"1.11.x","unicode-6.3.0":"0.1.x"},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"files":["bin","data","dist","src"],"gitHead":"02c2628de6401363fad48b3cc7668eef2c2d7c1a","_id":"jshint@2.6.1","_shasum":"2a431526e20215043e56831d228c769f3a9f5bc9","_from":".","_npmVersion":"2.1.18","_nodeVersion":"0.10.35","_npmUser":{"name":"rwaldron","email":"waldron.rick@gmail.com"},"maintainers":[{"name":"antonkovalyov","email":"anton@kovalyov.net"},{"name":"rwaldron","email":"waldron.rick@gmail.com"}],"dist":{"shasum":"2a431526e20215043e56831d228c769f3a9f5bc9","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.6.1.tgz"},"directories":{}},"2.6.2":{"name":"jshint","version":"2.6.2","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"build":"node bin/build","coverage":"istanbul -- cover ./node_modules/.bin/nodeunit tests/unit","data":"node scripts/generate-identifier-data","pretest":"jshint src && jscs src","test":"nodeunit tests tests/regression tests/unit"},"main":"./src/jshint.js","dependencies":{"cli":"0.6.x","console-browserify":"1.1.x","exit":"0.1.x","htmlparser2":"3.8.x","minimatch":"1.0.x","shelljs":"0.3.x","strip-json-comments":"1.0.x","underscore":"1.6.x"},"devDependencies":{"browserify":"6.x","coveralls":"2.11.x","istanbul":"0.3.x","jscs":"1.11.x","jshint":"2.5.x","mock-stdin":"0.3.x","nodeunit":"0.9.x","regenerate":"1.0.x","sinon":"1.11.x","unicode-6.3.0":"0.1.x"},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"files":["bin","data","dist","src"],"gitHead":"d82cf19916ea35079dc239f32b950dfc0767b795","_id":"jshint@2.6.2","_shasum":"fce55812fc9374855238ab2b08c8b37fbd9b5bee","_from":".","_npmVersion":"2.1.18","_nodeVersion":"0.10.35","_npmUser":{"name":"rwaldron","email":"waldron.rick@gmail.com"},"maintainers":[{"name":"antonkovalyov","email":"anton@kovalyov.net"},{"name":"rwaldron","email":"waldron.rick@gmail.com"}],"dist":{"shasum":"fce55812fc9374855238ab2b08c8b37fbd9b5bee","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.6.2.tgz"},"directories":{}},"2.6.3":{"name":"jshint","version":"2.6.3","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"build":"node bin/build","coverage":"istanbul -- cover ./node_modules/.bin/nodeunit tests/unit","data":"node scripts/generate-identifier-data","pretest":"jshint src && jscs src","test":"nodeunit tests tests/regression tests/unit"},"main":"./src/jshint.js","dependencies":{"cli":"0.6.x","console-browserify":"1.1.x","exit":"0.1.x","htmlparser2":"3.8.x","minimatch":"1.0.x","shelljs":"0.3.x","strip-json-comments":"1.0.x","underscore":"1.6.x"},"devDependencies":{"browserify":"6.x","coveralls":"2.11.x","istanbul":"0.3.x","jscs":"1.11.x","jshint":"2.5.x","mock-stdin":"0.3.x","nodeunit":"0.9.x","regenerate":"1.0.x","sinon":"1.11.x","unicode-6.3.0":"0.1.x"},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"files":["bin","data","dist","src"],"gitHead":"983fc8de62dc826670b7af8e64fd67de0a4d1a27","_id":"jshint@2.6.3","_shasum":"84b470b8e5d5cd7adf0a3bd4975250443c9d311a","_from":".","_npmVersion":"2.1.18","_nodeVersion":"0.10.35","_npmUser":{"name":"rwaldron","email":"waldron.rick@gmail.com"},"maintainers":[{"name":"antonkovalyov","email":"anton@kovalyov.net"},{"name":"rwaldron","email":"waldron.rick@gmail.com"}],"dist":{"shasum":"84b470b8e5d5cd7adf0a3bd4975250443c9d311a","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.6.3.tgz"},"directories":{}},"2.7.0":{"name":"jshint","version":"2.7.0","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"build":"node bin/build","coverage":"istanbul -- cover ./node_modules/.bin/nodeunit tests/unit","data":"node scripts/generate-identifier-data","pretest":"jshint src && jscs src","test":"nodeunit tests tests/regression tests/unit"},"main":"./src/jshint.js","dependencies":{"cli":"0.6.x","console-browserify":"1.1.x","exit":"0.1.x","htmlparser2":"3.8.x","minimatch":"2.0.x","shelljs":"0.3.x","strip-json-comments":"1.0.x","lodash":"3.6.x"},"devDependencies":{"browserify":"9.x","coveralls":"2.11.x","istanbul":"0.3.x","jscs":"1.11.x","jshint":"2.6.x","mock-stdin":"0.3.x","nodeunit":"0.9.x","regenerate":"1.2.x","sinon":"1.12.x","unicode-6.3.0":"0.1.x"},"licenses":[{"type":"MIT","url":"https://github.com/jshint/jshint/blob/master/LICENSE"}],"preferGlobal":true,"files":["bin","data","dist","src"],"gitHead":"dd768c243af2bd3a8beb5e47768eef3ec7ab2e5e","_id":"jshint@2.7.0","_shasum":"d512bb14731dac09e49f212e6b2f1b0fdbabbc4f","_from":".","_npmVersion":"2.1.18","_nodeVersion":"0.10.35","_npmUser":{"name":"rwaldron","email":"waldron.rick@gmail.com"},"maintainers":[{"name":"antonkovalyov","email":"anton@kovalyov.net"},{"name":"rwaldron","email":"waldron.rick@gmail.com"}],"dist":{"shasum":"d512bb14731dac09e49f212e6b2f1b0fdbabbc4f","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.7.0.tgz"},"directories":{}},"2.8.0":{"name":"jshint","version":"2.8.0","homepage":"http://jshint.com/","description":"Static analysis tool for JavaScript","author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"bugs":{"url":"https://github.com/jshint/jshint/issues"},"bin":{"jshint":"./bin/jshint"},"scripts":{"build":"node bin/build","coverage":"istanbul -- cover ./node_modules/.bin/nodeunit tests/unit","data":"node scripts/generate-identifier-data","pretest":"jshint src && jscs src","test":"nodeunit tests tests/regression tests/unit"},"main":"./src/jshint.js","dependencies":{"cli":"0.6.x","console-browserify":"1.1.x","exit":"0.1.x","htmlparser2":"3.8.x","minimatch":"2.0.x","shelljs":"0.3.x","strip-json-comments":"1.0.x","lodash":"3.7.x"},"devDependencies":{"browserify":"9.x","coveralls":"2.11.x","istanbul":"0.3.x","jscs":"1.11.x","jshint":"2.6.x","mock-stdin":"0.3.x","nodeunit":"0.9.x","regenerate":"1.2.x","sinon":"1.12.x","unicode-6.3.0":"0.1.x"},"license":"(MIT AND JSON)","preferGlobal":true,"files":["bin","data","dist","src"],"gitHead":"e6611af2d180bd2317d5762e85807a481de99ccb","_id":"jshint@2.8.0","_shasum":"1d09a3bd913c4cadfa81bf18d582bd85bffe0d44","_from":".","_npmVersion":"2.6.0","_nodeVersion":"0.12.0","_npmUser":{"name":"jugglinmike","email":"mike@mikepennisi.com"},"maintainers":[{"name":"antonkovalyov","email":"anton@kovalyov.net"},{"name":"rwaldron","email":"waldron.rick@gmail.com"},{"name":"jugglinmike","email":"mike@mikepennisi.com"}],"dist":{"shasum":"1d09a3bd913c4cadfa81bf18d582bd85bffe0d44","tarball":"http://registry.npmjs.org/jshint/-/jshint-2.8.0.tgz"},"directories":{}}},"maintainers":[{"name":"antonkovalyov","email":"anton@kovalyov.net"},{"name":"rwaldron","email":"waldron.rick@gmail.com"},{"name":"jugglinmike","email":"mike@mikepennisi.com"}],"time":{"modified":"2015-05-31T17:47:28.288Z","created":"2011-03-27T18:32:36.942Z","0.1.8":"2011-03-27T18:32:37.263Z","0.1.9":"2011-03-30T01:23:22.132Z","0.2.0":"2011-04-07T01:29:17.412Z","0.2.1":"2011-05-06T15:19:59.724Z","0.2.2":"2011-05-26T02:28:56.346Z","0.2.3":"2011-06-22T00:20:15.092Z","0.3.0":"2011-08-20T23:55:34.317Z","0.3.1":"2011-09-05T17:43:21.706Z","0.4.0":"2011-10-11T01:30:17.763Z","0.5.0":"2011-10-13T02:31:28.177Z","0.5.1":"2011-10-15T20:27:49.794Z","0.5.2":"2011-10-27T23:47:13.813Z","0.5.3":"2011-12-06T17:04:23.138Z","0.5.4":"2011-12-09T16:22:22.276Z","0.5.5":"2011-12-12T23:04:51.885Z","0.5.6":"2012-01-10T19:47:14.374Z","0.5.7":"2012-01-20T17:56:31.354Z","0.5.8":"2012-02-14T03:54:59.373Z","0.5.9":"2012-02-28T19:37:50.194Z","0.6.0":"2012-04-04T20:08:42.115Z","0.6.1":"2012-04-11T18:54:41.288Z","0.6.2":"2012-04-30T15:42:49.409Z","0.6.3":"2012-05-02T05:57:50.465Z","0.7.0":"2012-05-08T17:08:21.221Z","0.7.1":"2012-05-17T21:06:25.975Z","0.7.2":"2012-07-26T23:52:25.934Z","0.7.3":"2012-08-06T04:29:47.399Z","0.8.0":"2012-08-20T18:38:37.399Z","0.8.1":"2012-08-27T16:42:17.856Z","0.8.2":"2012-08-30T16:06:24.563Z","0.9.0":"2012-09-03T22:09:34.078Z","0.9.1":"2012-09-25T19:05:55.651Z","1.0.0":"2013-02-21T20:56:02.439Z","1.1.0":"2013-03-06T01:06:48.338Z","2.0.0":"2013-05-08T20:38:37.226Z","2.0.1":"2013-05-08T21:01:32.782Z","2.1.0":"2013-05-21T04:36:39.121Z","2.1.1":"2013-05-21T19:13:39.939Z","2.1.2":"2013-05-22T02:23:18.655Z","2.1.3":"2013-06-03T02:19:30.866Z","2.1.4":"2013-06-24T18:45:59.139Z","2.1.5":"2013-07-27T22:58:03.807Z","2.1.6":"2013-07-29T05:07:25.272Z","2.1.7":"2013-07-29T18:11:57.558Z","2.1.8":"2013-08-01T03:14:32.906Z","2.1.9":"2013-08-02T20:38:14.506Z","2.1.10":"2013-08-15T22:44:38.250Z","2.1.11":"2013-09-20T22:42:42.815Z","2.2.0":"2013-10-18T17:31:51.676Z","2.3.0":"2013-10-21T01:32:59.427Z","2.4.0":"2013-12-25T01:57:21.185Z","2.4.1":"2014-01-03T21:06:46.027Z","2.4.2":"2014-01-21T19:28:04.110Z","2.4.3":"2014-01-26T03:31:02.974Z","2.4.4":"2014-02-21T02:20:54.850Z","2.5.0":"2014-04-02T05:16:29.038Z","2.5.1":"2014-05-16T04:23:38.796Z","2.5.2":"2014-07-05T16:46:57.881Z","2.5.3":"2014-08-08T19:00:00.438Z","2.5.4":"2014-08-18T16:11:02.461Z","2.5.5":"2014-08-24T04:20:32.497Z","2.5.6":"2014-09-21T17:21:30.478Z","2.5.7":"2014-10-28T16:51:38.395Z","2.5.8":"2014-10-29T21:48:42.556Z","2.5.9":"2014-11-06T13:43:15.032Z","2.5.10":"2014-11-06T18:55:24.861Z","2.5.11":"2014-12-18T19:22:58.738Z","2.6.0":"2015-01-21T22:25:46.173Z","2.6.1":"2015-02-27T17:25:52.054Z","2.6.2":"2015-02-28T00:22:54.946Z","2.6.3":"2015-02-28T17:18:08.698Z","2.7.0":"2015-04-11T20:42:55.596Z","2.8.0":"2015-05-31T17:47:28.288Z"},"author":{"name":"Anton Kovalyov","email":"anton@kovalyov.net","url":"http://anton.kovalyov.net/"},"users":{"mvolkmann":true,"soldair":true,"danielr":true,"fgribreau":true,"pid":true,"graemef":true,"gillesruppert":true,"jgoodall":true,"tokuhirom":true,"m42am":true,"af":true,"jamesallardice":true,"charmander":true,"sandeepmistry":true,"millermedeiros":true,"ianmcburnie":true,"cparker15":true,"antonnguyen":true,"niftymonkey":true,"blalor":true,"netroy":true,"joliva":true,"pragma-dudes":true,"fibo":true,"adamrenny":true,"codylindley":true,"victorquinn":true,"chrisoei":true,"shiin":true,"mhaidarh":true,"cedx":true,"pragmadash":true,"claveren":true,"chpopov":true,"xtopher":true,"csk83":true,"priyaranjan":true,"jorgemsrs":true,"cilindrox":true,"fmm":true,"darryl.west":true,"renatobalbino":true,"redbe4rd":true,"fei":true,"sionbird":true,"toogle":true,"qiuzuhui":true,"ezhi":true,"davidbaiguini":true,"owaz":true,"chaowi":true,"agent_9191":true,"ambdxtrch":true,"frk1705":true,"tunnckocore":true,"nlwillia":true,"gdibble":true,"goblindegook":true,"antonkovalyov":true,"thebearingedge":true,"jits":true,"qmmr":true,"louxiaojian":true,"markymark":true,"byossarian":true,"alaabadran":true,"piotr23":true,"buster":true,"dgarlitt":true,"waltgiroir":true,"bkimminich":true,"csbun":true,"leobalter":true,"ivangaravito":true,"mjurincic":true,"kws4679":true,"presence":true,"hoitmort":true,"azder":true,"alexandermac":true,"sirreal":true,"kh3phr3n":true,"nitayneeman":true,"nicolasmccurdy":true,"haeck":true,"pnevares":true,"gdbtek":true,"ksmithut":true,"kulakowka":true,"nadimix":true,"trigu":true,"vboctor":true,"shannonmoeller":true,"limit":true,"borjes":true,"yasinaydin":true,"josuehenry14":true,"ericwbailey":true,"kai_":true,"raiseandfall":true,"clux":true,"ugarz":true,"sasquatch":true,"tfentonz":true,"dac2205":true,"subchen":true,"marbio":true,"brandondoran":true,"jackpinto":true,"joris-van-der-wel":true,"rogier.spieker":true,"hassane":true,"sakthiinfotec":true,"season19840122":true,"fvcproductions":true,"felixjung":true,"jamesmgreene":true,"nice_body":true,"maskedcoder":true},"repository":{"type":"git","url":"https://github.com/jshint/jshint.git"},"readme":"# JSHint, A Static Code Analysis Tool for JavaScript\n\n\\[ [Use it online](http://jshint.com/) • [About](http://jshint.com/about/) •\n[Docs](http://jshint.com/docs/) • [FAQ](http://jshint.com/docs/faq) •\n[Install](http://jshint.com/install/) • [Hack](http://jshint.com/hack/) •\n[Blog](http://jshint.com/blog/) • [Twitter](https://twitter.com/jshint/) \\]\n\n[![NPM version](https://img.shields.io/npm/v/jshint.svg?style=flat)](https://www.npmjs.com/package/jshint)\n[![Linux Build Status](https://img.shields.io/travis/jshint/jshint/master.svg?style=flat&label=Linux%20build)](https://travis-ci.org/jshint/jshint)\n[![Windows Build status](https://img.shields.io/appveyor/ci/jshint/jshint/master.svg?style=flat&label=Windows%20build)](https://ci.appveyor.com/project/jshint/jshint/branch/master)\n[![Dependency Status](https://img.shields.io/david/jshint/jshint.svg?style=flat)](https://david-dm.org/jshint/jshint)\n[![devDependency Status](https://img.shields.io/david/dev/jshint/jshint.svg?style=flat)](https://david-dm.org/jshint/jshint#info=devDependencies)\n[![Coverage Status](https://img.shields.io/coveralls/jshint/jshint.svg?style=flat)](https://coveralls.io/r/jshint/jshint?branch=master)\n\nJSHint is a community-driven tool to detect errors and potential problems\nin JavaScript code. It is very flexible so you can easily adjust it to your\nparticular coding guidelines and the environment you expect your code to\nexecute in.\n\n## Reporting a bug\n\nTo report a bug simply create a\n[new GitHub Issue](https://github.com/jshint/jshint/issues/new) and describe\nyour problem or suggestion. We welcome all kinds of feedback regarding\nJSHint including but not limited to:\n\n * When JSHint doesn't work as expected\n * When JSHint complains about valid JavaScript code that works in all browsers\n * When you simply want a new option or feature\n\nBefore reporting a bug look around to see if there are any open or closed tickets\nthat cover your issue. And remember the wisdom: pull request > bug report > tweet.\n\n## Issue Priority\n\n- *P1:* Something is throwing exceptions; broken JSHint backward compatibility.\n- *P2:* Something is not being parsed correctly.\n- *P3:* Features that the core team will work on once P2s and P1s are done.\n- *P4:* Patches welcome; The request is good, but low priority.\n\n\n## License\n\nJSHint is distributed under the MIT License. One file and one file only\n(src/stable/jshint.js) is distributed under the slightly modified MIT License.\n\n## The JSHint Team\n\nJSHint is maintained by [Rick Waldron](https://github.com/rwaldron/), [Caitlin\nPotter](https://github.com/caitp/), [Mike\nSherov](https://github.com/mikesherov/), and [Mike\nPennisi](https://github.com/jugglinmike/).\n\n## Thank you!\n\nWe really appreciate all kinds of feedback and contributions. Thanks for using and supporting JSHint!\n","readmeFilename":"README.md","homepage":"http://jshint.com/","bugs":{"url":"https://github.com/jshint/jshint/issues"},"license":"(MIT AND JSON)","_attachments":{},"_etag":"\"G9561MH4XUZS8T2K8YB5INUN\""}
\ No newline at end of file