commit adfdc0c93856d70326def1d2c18cff6c19745ddf Author: Timothy J. Warren Date: Thu Sep 18 15:35:58 2014 -0400 First commit diff --git a/app.js b/app.js new file mode 100644 index 0000000..59e4ade --- /dev/null +++ b/app.js @@ -0,0 +1,60 @@ +var express = require('express'); +var path = require('path'); +var favicon = require('serve-favicon'); +var logger = require('morgan'); +var cookieParser = require('cookie-parser'); +var bodyParser = require('body-parser'); + +var routes = require('./routes/index'); +var users = require('./routes/users'); + +var app = express(); + +// view engine setup +app.set('views', path.join(__dirname, 'views')); +app.set('view engine', 'dust'); + +// uncomment after placing your favicon in /public +//app.use(favicon(__dirname + '/public/favicon.ico')); +app.use(logger('dev')); +app.use(bodyParser.json()); +app.use(bodyParser.urlencoded({ extended: false })); +app.use(cookieParser()); +app.use(express.static(path.join(__dirname, 'public'))); + +app.use('/', routes); +app.use('/users', users); + +// catch 404 and forward to error handler +app.use(function(req, res, next) { + var err = new Error('Not Found'); + err.status = 404; + next(err); +}); + +// error handlers + +// development error handler +// will print stacktrace +if (app.get('env') === 'development') { + app.use(function(err, req, res, next) { + res.status(err.status || 500); + res.render('error', { + message: err.message, + error: err + }); + }); +} + +// production error handler +// no stacktraces leaked to user +app.use(function(err, req, res, next) { + res.status(err.status || 500); + res.render('error', { + message: err.message, + error: {} + }); +}); + + +module.exports = app; diff --git a/bin/www b/bin/www new file mode 100755 index 0000000..9377435 --- /dev/null +++ b/bin/www @@ -0,0 +1,9 @@ +#!/usr/bin/env node +var debug = require('debug')('node-task'); +var app = require('../app'); + +app.set('port', process.env.PORT || 3000); + +var server = app.listen(app.get('port'), function() { + debug('Express server listening on port ' + server.address().port); +}); diff --git a/node_modules/.bin/nodeunit b/node_modules/.bin/nodeunit new file mode 120000 index 0000000..f31cdbe --- /dev/null +++ b/node_modules/.bin/nodeunit @@ -0,0 +1 @@ +../nodeunit/bin/nodeunit \ No newline at end of file diff --git a/node_modules/body-parser/HISTORY.md b/node_modules/body-parser/HISTORY.md new file mode 100644 index 0000000..e9ecf43 --- /dev/null +++ b/node_modules/body-parser/HISTORY.md @@ -0,0 +1,199 @@ +1.8.2 / 2014-09-15 +================== + + * deps: depd@0.4.5 + +1.8.1 / 2014-09-07 +================== + + * deps: media-typer@0.3.0 + * deps: type-is@~1.5.1 + +1.8.0 / 2014-09-05 +================== + + * make empty-body-handling consistent between chunked requests + - empty `json` produces `{}` + - empty `raw` produces `new Buffer(0)` + - empty `text` produces `''` + - empty `urlencoded` produces `{}` + * deps: qs@2.2.3 + - Fix issue where first empty value in array is discarded + * deps: type-is@~1.5.0 + - fix `hasbody` to be true for `content-length: 0` + +1.7.0 / 2014-09-01 +================== + + * add `parameterLimit` option to `urlencoded` parser + * change `urlencoded` extended array limit to 100 + * respond with 415 when over `parameterLimit` in `urlencoded` + +1.6.7 / 2014-08-29 +================== + + * deps: qs@2.2.2 + - Remove unnecessary cloning + +1.6.6 / 2014-08-27 +================== + + * deps: qs@2.2.0 + - Array parsing fix + - Performance improvements + +1.6.5 / 2014-08-16 +================== + + * deps: on-finished@2.1.0 + +1.6.4 / 2014-08-14 +================== + + * deps: qs@1.2.2 + +1.6.3 / 2014-08-10 +================== + + * deps: qs@1.2.1 + +1.6.2 / 2014-08-07 +================== + + * deps: qs@1.2.0 + - Fix parsing array of objects + +1.6.1 / 2014-08-06 +================== + + * deps: qs@1.1.0 + - Accept urlencoded square brackets + - Accept empty values in implicit array notation + +1.6.0 / 2014-08-05 +================== + + * deps: qs@1.0.2 + - Complete rewrite + - Limits array length to 20 + - Limits object depth to 5 + - Limits parameters to 1,000 + +1.5.2 / 2014-07-27 +================== + + * deps: depd@0.4.4 + - Work-around v8 generating empty stack traces + +1.5.1 / 2014-07-26 +================== + + * deps: depd@0.4.3 + - Fix exception when global `Error.stackTraceLimit` is too low + +1.5.0 / 2014-07-20 +================== + + * deps: depd@0.4.2 + - Add `TRACE_DEPRECATION` environment variable + - Remove non-standard grey color from color output + - Support `--no-deprecation` argument + - Support `--trace-deprecation` argument + * deps: iconv-lite@0.4.4 + - Added encoding UTF-7 + * deps: raw-body@1.3.0 + - deps: iconv-lite@0.4.4 + - Added encoding UTF-7 + - Fix `Cannot switch to old mode now` error on Node.js 0.10+ + * deps: type-is@~1.3.2 + +1.4.3 / 2014-06-19 +================== + + * deps: type-is@1.3.1 + - fix global variable leak + +1.4.2 / 2014-06-19 +================== + + * deps: type-is@1.3.0 + - improve type parsing + +1.4.1 / 2014-06-19 +================== + + * fix urlencoded extended deprecation message + +1.4.0 / 2014-06-19 +================== + + * add `text` parser + * add `raw` parser + * check accepted charset in content-type (accepts utf-8) + * check accepted encoding in content-encoding (accepts identity) + * deprecate `bodyParser()` middleware; use `.json()` and `.urlencoded()` as needed + * deprecate `urlencoded()` without provided `extended` option + * lazy-load urlencoded parsers + * parsers split into files for reduced mem usage + * support gzip and deflate bodies + - set `inflate: false` to turn off + * deps: raw-body@1.2.2 + - Support all encodings from `iconv-lite` + +1.3.1 / 2014-06-11 +================== + + * deps: type-is@1.2.1 + - Switch dependency from mime to mime-types@1.0.0 + +1.3.0 / 2014-05-31 +================== + + * add `extended` option to urlencoded parser + +1.2.2 / 2014-05-27 +================== + + * deps: raw-body@1.1.6 + - assert stream encoding on node.js 0.8 + - assert stream encoding on node.js < 0.10.6 + - deps: bytes@1 + +1.2.1 / 2014-05-26 +================== + + * invoke `next(err)` after request fully read + - prevents hung responses and socket hang ups + +1.2.0 / 2014-05-11 +================== + + * add `verify` option + * deps: type-is@1.2.0 + - support suffix matching + +1.1.2 / 2014-05-11 +================== + + * improve json parser speed + +1.1.1 / 2014-05-11 +================== + + * fix repeated limit parsing with every request + +1.1.0 / 2014-05-10 +================== + + * add `type` option + * deps: pin for safety and consistency + +1.0.2 / 2014-04-14 +================== + + * use `type-is` module + +1.0.1 / 2014-03-20 +================== + + * lower default limits to 100kb diff --git a/node_modules/body-parser/LICENSE b/node_modules/body-parser/LICENSE new file mode 100644 index 0000000..53e49a3 --- /dev/null +++ b/node_modules/body-parser/LICENSE @@ -0,0 +1,23 @@ +(The MIT License) + +Copyright (c) 2014 Jonathan Ong +Copyright (c) 2014 Douglas Christopher Wilson + +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/node_modules/body-parser/README.md b/node_modules/body-parser/README.md new file mode 100644 index 0000000..7b9b4ed --- /dev/null +++ b/node_modules/body-parser/README.md @@ -0,0 +1,140 @@ +# body-parser + +[![NPM Version][npm-image]][npm-url] +[![NPM Downloads][downloads-image]][downloads-url] +[![Build Status][travis-image]][travis-url] +[![Test Coverage][coveralls-image]][coveralls-url] +[![Gittip][gittip-image]][gittip-url] + +Node.js body parsing middleware. + +This does not handle multipart bodies, due to their complex and typically large nature. For multipart bodies, you may be interested in the following modules: + +- [busboy](https://www.npmjs.org/package/busboy#readme) and [connect-busboy](https://www.npmjs.org/package/connect-busboy#readme) +- [multiparty](https://www.npmjs.org/package/multiparty#readme) and [connect-multiparty](https://www.npmjs.org/package/connect-multiparty#readme) +- [formidable](https://www.npmjs.org/package/formidable#readme) +- [multer](https://www.npmjs.org/package/multer#readme) + +Other body parsers you might be interested in: + +- [body](https://www.npmjs.org/package/body#readme) +- [co-body](https://www.npmjs.org/package/co-body#readme) + +## Installation + +```sh +$ npm install body-parser +``` + +## API + +```js +var express = require('express') +var bodyParser = require('body-parser') + +var app = express() + +// parse application/x-www-form-urlencoded +app.use(bodyParser.urlencoded({ extended: false })) + +// parse application/json +app.use(bodyParser.json()) + +// parse application/vnd.api+json as json +app.use(bodyParser.json({ type: 'application/vnd.api+json' })) + +app.use(function (req, res, next) { + console.log(req.body) // populated! + next() +}) +``` + +### bodyParser.json(options) + +Returns middleware that only parses `json`. This parser accepts any Unicode encoding of the body and supports automatic inflation of `gzip` and `deflate` encodings. + +The options are: + +- `strict` - only parse objects and arrays. (default: `true`) +- `inflate` - if deflated bodies will be inflated. (default: `true`) +- `limit` - maximum request body size. (default: `<100kb>`) +- `reviver` - passed to `JSON.parse()` +- `type` - request content-type to parse (default: `json`) +- `verify` - function to verify body content + +The `type` argument is passed directly to the [type-is](https://www.npmjs.org/package/type-is#readme) library. This can be an extension name (like `json`), a mime type (like `application/json`), or a mime time with a wildcard (like `*/json`). + +The `verify` argument, if supplied, is called as `verify(req, res, buf, encoding)`, where `buf` is a `Buffer` of the raw request body and `encoding` is the encoding of the request. The parsing can be aborted by throwing an error. + +The `reviver` argument is passed directly to `JSON.parse` as the second argument. You can find more information on this argument [in the MDN documentation about JSON.parse](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/JSON/parse#Example.3A_Using_the_reviver_parameter). + +### bodyParser.raw(options) + +Returns middleware that parses all bodies as a `Buffer`. This parser supports automatic inflation of `gzip` and `deflate` encodings. + +The options are: + +- `inflate` - if deflated bodies will be inflated. (default: `true`) +- `limit` - maximum request body size. (default: `<100kb>`) +- `type` - request content-type to parse (default: `application/octet-stream`) +- `verify` - function to verify body content + +The `type` argument is passed directly to the [type-is](https://www.npmjs.org/package/type-is#readme) library. This can be an extension name (like `bin`), a mime type (like `application/octet-stream`), or a mime time with a wildcard (like `application/*`). + +The `verify` argument, if supplied, is called as `verify(req, res, buf, encoding)`, where `buf` is a `Buffer` of the raw request body and `encoding` is the encoding of the request. The parsing can be aborted by throwing an error. + +### bodyParser.text(options) + +Returns middleware that parses all bodies as a string. This parser supports automatic inflation of `gzip` and `deflate` encodings. + +The options are: + +- `defaultCharset` - the default charset to parse as, if not specified in content-type. (default: `utf-8`) +- `inflate` - if deflated bodies will be inflated. (default: `true`) +- `limit` - maximum request body size. (default: `<100kb>`) +- `type` - request content-type to parse (default: `text/plain`) +- `verify` - function to verify body content + +The `type` argument is passed directly to the [type-is](https://www.npmjs.org/package/type-is#readme) library. This can be an extension name (like `txt`), a mime type (like `text/plain`), or a mime time with a wildcard (like `text/*`). + +The `verify` argument, if supplied, is called as `verify(req, res, buf, encoding)`, where `buf` is a `Buffer` of the raw request body and `encoding` is the encoding of the request. The parsing can be aborted by throwing an error. + +### bodyParser.urlencoded(options) + +Returns middleware that only parses `urlencoded` bodies. This parser accepts only UTF-8 encoding of the body and supports automatic inflation of `gzip` and `deflate` encodings. + +The options are: + +- `extended` - parse extended syntax with the [qs](https://www.npmjs.org/package/qs#readme) module. (default: `true`) +- `inflate` - if deflated bodies will be inflated. (default: `true`) +- `limit` - maximum request body size. (default: `<100kb>`) +- `parameterLimit` - maximum number of parameters. (default: `1000`) +- `type` - request content-type to parse (default: `urlencoded`) +- `verify` - function to verify body content + +The `extended` argument allows to choose between parsing the urlencoded data with the `querystring` library (when `false`) or the `qs` library (when `true`). The "extended" syntax allows for rich objects and arrays to be encoded into the urlencoded format, allowing for a JSON-like experience with urlencoded. For more information, please [see the qs library](https://www.npmjs.org/package/qs#readme). + +The `parameterLimit` argument controls the maximum number of parameters that are allowed in the urlencoded data. If a request contains more parameters than this value, a 415 will be returned to the client. + +The `type` argument is passed directly to the [type-is](https://www.npmjs.org/package/type-is#readme) library. This can be an extension name (like `urlencoded`), a mime type (like `application/x-www-form-urlencoded`), or a mime time with a wildcard (like `*/x-www-form-urlencoded`). + +The `verify` argument, if supplied, is called as `verify(req, res, buf, encoding)`, where `buf` is a `Buffer` of the raw request body and `encoding` is the encoding of the request. The parsing can be aborted by throwing an error. + +### req.body + +A new `body` object containing the parsed data is populated on the `request` object after the middleware. + +## License + +[MIT](LICENSE) + +[npm-image]: https://img.shields.io/npm/v/body-parser.svg?style=flat +[npm-url]: https://npmjs.org/package/body-parser +[travis-image]: https://img.shields.io/travis/expressjs/body-parser.svg?style=flat +[travis-url]: https://travis-ci.org/expressjs/body-parser +[coveralls-image]: https://img.shields.io/coveralls/expressjs/body-parser.svg?style=flat +[coveralls-url]: https://coveralls.io/r/expressjs/body-parser?branch=master +[downloads-image]: https://img.shields.io/npm/dm/body-parser.svg?style=flat +[downloads-url]: https://npmjs.org/package/body-parser +[gittip-image]: https://img.shields.io/gittip/dougwilson.svg?style=flat +[gittip-url]: https://www.gittip.com/dougwilson/ diff --git a/node_modules/body-parser/index.js b/node_modules/body-parser/index.js new file mode 100644 index 0000000..7c87204 --- /dev/null +++ b/node_modules/body-parser/index.js @@ -0,0 +1,84 @@ +/*! + * body-parser + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module dependencies. + */ + +var deprecate = require('depd')('body-parser') +var fs = require('fs') +var path = require('path') + +/** + * Module exports. + */ + +exports = module.exports = deprecate.function(bodyParser, + 'bodyParser: use individual json/urlencoded middlewares') + +/** + * Path to the parser modules. + */ + +var parsersDir = path.join(__dirname, 'lib', 'types') + +/** + * Auto-load bundled parsers with getters. + */ + +fs.readdirSync(parsersDir).forEach(function onfilename(filename) { + if (!/\.js$/.test(filename)) return + + var loc = path.resolve(parsersDir, filename) + var mod + var name = path.basename(filename, '.js') + + function load() { + if (mod) { + return mod + } + + return mod = require(loc) + } + + Object.defineProperty(exports, name, { + configurable: true, + enumerable: true, + get: load + }) +}) + +/** + * Create a middleware to parse json and urlencoded bodies. + * + * @param {object} [options] + * @return {function} + * @deprecated + * @api public + */ + +function bodyParser(options){ + var opts = {} + + options = options || {} + + // exclude type option + for (var prop in options) { + if ('type' !== prop) { + opts[prop] = options[prop] + } + } + + var _urlencoded = exports.urlencoded(opts) + var _json = exports.json(opts) + + return function bodyParser(req, res, next) { + _json(req, res, function(err){ + if (err) return next(err); + _urlencoded(req, res, next); + }); + } +} diff --git a/node_modules/body-parser/lib/read.js b/node_modules/body-parser/lib/read.js new file mode 100644 index 0000000..1e66cbf --- /dev/null +++ b/node_modules/body-parser/lib/read.js @@ -0,0 +1,145 @@ +/*! + * body-parser + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module dependencies. + */ + +var getBody = require('raw-body') +var iconv = require('iconv-lite') +var onFinished = require('on-finished') +var typer = require('media-typer') +var zlib = require('zlib') + +/** + * Module exports. + */ + +module.exports = read + +/** + * Read a request into a buffer and parse. + * + * @param {object} req + * @param {object} res + * @param {function} next + * @param {function} parse + * @param {object} options + * @api private + */ + +function read(req, res, next, parse, options) { + var length + var stream + + // flag as parsed + req._body = true + + try { + stream = contentstream(req, options.inflate) + length = stream.length + delete stream.length + } catch (err) { + return next(err) + } + + options = options || {} + options.length = length + + var encoding = options.encoding !== null + ? options.encoding || 'utf-8' + : null + var verify = options.verify + + options.encoding = verify + ? null + : encoding + + // read body + getBody(stream, options, function (err, body) { + if (err) { + if (!err.status) { + err.status = 400 + } + + // read off entire request + stream.resume() + onFinished(req, function onfinished() { + next(err) + }) + return + } + + // verify + if (verify) { + try { + verify(req, res, body, encoding) + } catch (err) { + if (!err.status) err.status = 403 + return next(err) + } + } + + // parse + try { + body = typeof body !== 'string' && encoding !== null + ? iconv.decode(body, encoding) + : body + req.body = parse(body) + } catch (err) { + if (!err.status) { + err.body = body + err.status = 400 + } + return next(err) + } + + next() + }) +} + +/** + * Get the content stream of the request. + * + * @param {object} req + * @param {boolean} [inflate=true] + * @return {object} + * @api private + */ + +function contentstream(req, inflate) { + var encoding = req.headers['content-encoding'] || 'identity' + var err + var length = req.headers['content-length'] + var stream + + if (inflate === false && encoding !== 'identity') { + err = new Error('content encoding unsupported') + err.status = 415 + throw err + } + + switch (encoding) { + case 'deflate': + stream = zlib.createInflate() + req.pipe(stream) + break + case 'gzip': + stream = zlib.createGunzip() + req.pipe(stream) + break + case 'identity': + stream = req + stream.length = length + break + default: + err = new Error('unsupported content encoding') + err.status = 415 + throw err + } + + return stream +} diff --git a/node_modules/body-parser/lib/types/json.js b/node_modules/body-parser/lib/types/json.js new file mode 100644 index 0000000..4ba1a4b --- /dev/null +++ b/node_modules/body-parser/lib/types/json.js @@ -0,0 +1,108 @@ +/*! + * body-parser + * Copyright(c) 2014 Jonathan Ong + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module dependencies. + */ + +var bytes = require('bytes') +var read = require('../read') +var typer = require('media-typer') +var typeis = require('type-is') + +/** + * Module exports. + */ + +module.exports = json + +/** + * RegExp to match the first non-space in a string. + */ + +var firstcharRegExp = /^\s*(.)/ + +/** + * Create a middleware to parse JSON bodies. + * + * @param {object} [options] + * @return {function} + * @api public + */ + +function json(options) { + options = options || {} + + var limit = typeof options.limit !== 'number' + ? bytes(options.limit || '100kb') + : options.limit + var inflate = options.inflate !== false + var reviver = options.reviver + var strict = options.strict !== false + var type = options.type || 'json' + var verify = options.verify || false + + if (verify !== false && typeof verify !== 'function') { + throw new TypeError('option verify must be function') + } + + function parse(body) { + if (body.length === 0) { + // special-case empty json body, as it's a common client-side mistake + // TODO: maybe make this configurable or part of "strict" option + return {} + } + + if (strict) { + var first = firstchar(body) + + if (first !== '{' && first !== '[') { + throw new Error('invalid json') + } + } + + return JSON.parse(body, reviver) + } + + return function jsonParser(req, res, next) { + if (req._body) return next() + req.body = req.body || {} + + if (!typeis(req, type)) return next() + + // RFC 7159 sec 8.1 + var charset = typer.parse(req).parameters.charset || 'utf-8' + if (charset.substr(0, 4).toLowerCase() !== 'utf-') { + var err = new Error('unsupported charset') + err.status = 415 + next(err) + return + } + + // read + read(req, res, next, parse, { + encoding: charset, + inflate: inflate, + limit: limit, + verify: verify + }) + } +} + +/** + * Get the first non-whitespace character in a string. + * + * @param {string} str + * @return {function} + * @api public + */ + + +function firstchar(str) { + var match = firstcharRegExp.exec(str) + return match ? match[1] : '' +} diff --git a/node_modules/body-parser/lib/types/raw.js b/node_modules/body-parser/lib/types/raw.js new file mode 100644 index 0000000..9d7e49a --- /dev/null +++ b/node_modules/body-parser/lib/types/raw.js @@ -0,0 +1,61 @@ +/*! + * body-parser + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module dependencies. + */ + +var bytes = require('bytes') +var read = require('../read') +var typeis = require('type-is') + +/** + * Module exports. + */ + +module.exports = raw + +/** + * Create a middleware to parse raw bodies. + * + * @param {object} [options] + * @return {function} + * @api public + */ + +function raw(options) { + options = options || {}; + + var inflate = options.inflate !== false + var limit = typeof options.limit !== 'number' + ? bytes(options.limit || '100kb') + : options.limit + var type = options.type || 'application/octet-stream' + var verify = options.verify || false + + if (verify !== false && typeof verify !== 'function') { + throw new TypeError('option verify must be function') + } + + function parse(buf) { + return buf + } + + return function rawParser(req, res, next) { + if (req._body) return next() + req.body = req.body || {} + + if (!typeis(req, type)) return next() + + // read + read(req, res, next, parse, { + encoding: null, + inflate: inflate, + limit: limit, + verify: verify + }) + } +} diff --git a/node_modules/body-parser/lib/types/text.js b/node_modules/body-parser/lib/types/text.js new file mode 100644 index 0000000..2330b5b --- /dev/null +++ b/node_modules/body-parser/lib/types/text.js @@ -0,0 +1,66 @@ +/*! + * body-parser + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module dependencies. + */ + +var bytes = require('bytes') +var read = require('../read') +var typeis = require('type-is') +var typer = require('media-typer') + +/** + * Module exports. + */ + +module.exports = text + +/** + * Create a middleware to parse text bodies. + * + * @param {object} [options] + * @return {function} + * @api public + */ + +function text(options) { + options = options || {}; + + var defaultCharset = options.defaultCharset || 'utf-8' + var inflate = options.inflate !== false + var limit = typeof options.limit !== 'number' + ? bytes(options.limit || '100kb') + : options.limit + var type = options.type || 'text/plain' + var verify = options.verify || false + + if (verify !== false && typeof verify !== 'function') { + throw new TypeError('option verify must be function') + } + + function parse(buf) { + return buf + } + + return function textParser(req, res, next) { + if (req._body) return next() + req.body = req.body || {} + + if (!typeis(req, type)) return next() + + // get charset + var charset = typer.parse(req).parameters.charset || defaultCharset + + // read + read(req, res, next, parse, { + encoding: charset, + inflate: inflate, + limit: limit, + verify: verify + }) + } +} diff --git a/node_modules/body-parser/lib/types/urlencoded.js b/node_modules/body-parser/lib/types/urlencoded.js new file mode 100644 index 0000000..d846e65 --- /dev/null +++ b/node_modules/body-parser/lib/types/urlencoded.js @@ -0,0 +1,206 @@ +/*! + * body-parser + * Copyright(c) 2014 Jonathan Ong + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module dependencies. + */ + +var bytes = require('bytes') +var deprecate = require('depd')('body-parser') +var read = require('../read') +var typer = require('media-typer') +var typeis = require('type-is') + +/** + * Module exports. + */ + +module.exports = urlencoded + +/** + * Cache of parser modules. + */ + +var parsers = Object.create(null) + +/** + * Create a middleware to parse urlencoded bodies. + * + * @param {object} [options] + * @return {function} + * @api public + */ + +function urlencoded(options){ + options = options || {}; + + // notice because option default will flip in next major + if (options.extended === undefined) { + deprecate('undefined extended: provide extended option') + } + + var extended = options.extended !== false + var inflate = options.inflate !== false + var limit = typeof options.limit !== 'number' + ? bytes(options.limit || '100kb') + : options.limit + var type = options.type || 'urlencoded' + var verify = options.verify || false + + if (verify !== false && typeof verify !== 'function') { + throw new TypeError('option verify must be function') + } + + var queryparse = extended + ? extendedparser(options) + : simpleparser(options) + + function parse(body) { + return body.length + ? queryparse(body) + : {} + } + + return function urlencodedParser(req, res, next) { + if (req._body) return next(); + req.body = req.body || {} + + if (!typeis(req, type)) return next(); + + var charset = typer.parse(req).parameters.charset || 'utf-8' + if (charset.toLowerCase() !== 'utf-8') { + var err = new Error('unsupported charset') + err.status = 415 + next(err) + return + } + + // read + read(req, res, next, parse, { + encoding: charset, + inflate: inflate, + limit: limit, + verify: verify + }) + } +} + +/** + * Get the extended query parser. + * + * @param {object} options + */ + +function extendedparser(options) { + var parameterLimit = options.parameterLimit !== undefined + ? options.parameterLimit + : 1000 + var parse = parser('qs') + + if (isNaN(parameterLimit) || parameterLimit < 1) { + throw new TypeError('option parameterLimit must be a positive number') + } + + if (isFinite(parameterLimit)) { + parameterLimit = parameterLimit | 0 + } + + var opts = { + arrayLimit: 100, + parameterLimit: parameterLimit + } + + return function queryparse(body) { + if (overlimit(body, parameterLimit)) { + var err = new Error('too many parameters') + err.status = 413 + throw err + } + + return parse(body, opts) + } +} + +/** + * Determine if the parameter count is over the limit. + * + * @param {string} body + * @param {number} limit + * @api private + */ + +function overlimit(body, limit) { + if (limit === Infinity) { + return false + } + + var count = 0 + var index = 0 + + while ((index = body.indexOf('&', index)) !== -1) { + count++ + index++ + + if (count === limit) { + return true + } + } + + return false +} + +/** + * Get parser for module name dynamically. + * + * @param {string} name + * @return {function} + * @api private + */ + +function parser(name) { + var mod = parsers[name] + + if (mod) { + return mod.parse + } + + // load module + mod = parsers[name] = require(name) + + return mod.parse +} + +/** + * Get the simple query parser. + * + * @param {object} options + */ + +function simpleparser(options) { + var parameterLimit = options.parameterLimit !== undefined + ? options.parameterLimit + : 1000 + var parse = parser('querystring') + + if (isNaN(parameterLimit) || parameterLimit < 1) { + throw new TypeError('option parameterLimit must be a positive number') + } + + if (isFinite(parameterLimit)) { + parameterLimit = parameterLimit | 0 + } + + return function queryparse(body) { + if (overlimit(body, parameterLimit)) { + var err = new Error('too many parameters') + err.status = 413 + throw err + } + + return parse(body, undefined, undefined, {maxKeys: parameterLimit}) + } +} diff --git a/node_modules/body-parser/node_modules/bytes/.npmignore b/node_modules/body-parser/node_modules/bytes/.npmignore new file mode 100644 index 0000000..9daeafb --- /dev/null +++ b/node_modules/body-parser/node_modules/bytes/.npmignore @@ -0,0 +1 @@ +test diff --git a/node_modules/body-parser/node_modules/bytes/History.md b/node_modules/body-parser/node_modules/bytes/History.md new file mode 100644 index 0000000..5097352 --- /dev/null +++ b/node_modules/body-parser/node_modules/bytes/History.md @@ -0,0 +1,25 @@ + +1.0.0 / 2014-05-05 +================== + + * add negative support. fixes #6 + +0.3.0 / 2014-03-19 +================== + + * added terabyte support + +0.2.1 / 2013-04-01 +================== + + * add .component + +0.2.0 / 2012-10-28 +================== + + * bytes(200).should.eql('200b') + +0.1.0 / 2012-07-04 +================== + + * add bytes to string conversion [yields] diff --git a/node_modules/body-parser/node_modules/bytes/Makefile b/node_modules/body-parser/node_modules/bytes/Makefile new file mode 100644 index 0000000..8e8640f --- /dev/null +++ b/node_modules/body-parser/node_modules/bytes/Makefile @@ -0,0 +1,7 @@ + +test: + @./node_modules/.bin/mocha \ + --reporter spec \ + --require should + +.PHONY: test \ No newline at end of file diff --git a/node_modules/body-parser/node_modules/bytes/Readme.md b/node_modules/body-parser/node_modules/bytes/Readme.md new file mode 100644 index 0000000..5591b28 --- /dev/null +++ b/node_modules/body-parser/node_modules/bytes/Readme.md @@ -0,0 +1,54 @@ +# node-bytes + + Byte string parser / formatter. + +## Example: + +```js +bytes('1kb') +// => 1024 + +bytes('2mb') +// => 2097152 + +bytes('1gb') +// => 1073741824 + +bytes(1073741824) +// => 1gb + +bytes(1099511627776) +// => 1tb +``` + +## Installation + +``` +$ npm install bytes +$ component install visionmedia/bytes.js +``` + +## License + +(The MIT License) + +Copyright (c) 2012 TJ Holowaychuk <tj@vision-media.ca> + +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/node_modules/body-parser/node_modules/bytes/component.json b/node_modules/body-parser/node_modules/bytes/component.json new file mode 100644 index 0000000..2929c25 --- /dev/null +++ b/node_modules/body-parser/node_modules/bytes/component.json @@ -0,0 +1,7 @@ +{ + "name": "bytes", + "description": "byte size string parser / serializer", + "keywords": ["bytes", "utility"], + "version": "0.2.1", + "scripts": ["index.js"] +} diff --git a/node_modules/body-parser/node_modules/bytes/index.js b/node_modules/body-parser/node_modules/bytes/index.js new file mode 100644 index 0000000..c1da2fe --- /dev/null +++ b/node_modules/body-parser/node_modules/bytes/index.js @@ -0,0 +1,41 @@ + +/** + * Parse byte `size` string. + * + * @param {String} size + * @return {Number} + * @api public + */ + +module.exports = function(size) { + if ('number' == typeof size) return convert(size); + var parts = size.match(/^(\d+(?:\.\d+)?) *(kb|mb|gb|tb)$/) + , n = parseFloat(parts[1]) + , type = parts[2]; + + var map = { + kb: 1 << 10 + , mb: 1 << 20 + , gb: 1 << 30 + , tb: ((1 << 30) * 1024) + }; + + return map[type] * n; +}; + +/** + * convert bytes into string. + * + * @param {Number} b - bytes to convert + * @return {String} + * @api public + */ + +function convert (b) { + var tb = ((1 << 30) * 1024), gb = 1 << 30, mb = 1 << 20, kb = 1 << 10, abs = Math.abs(b); + if (abs >= tb) return (Math.round(b / tb * 100) / 100) + 'tb'; + if (abs >= gb) return (Math.round(b / gb * 100) / 100) + 'gb'; + if (abs >= mb) return (Math.round(b / mb * 100) / 100) + 'mb'; + if (abs >= kb) return (Math.round(b / kb * 100) / 100) + 'kb'; + return b + 'b'; +} diff --git a/node_modules/body-parser/node_modules/bytes/package.json b/node_modules/body-parser/node_modules/bytes/package.json new file mode 100644 index 0000000..dabaa22 --- /dev/null +++ b/node_modules/body-parser/node_modules/bytes/package.json @@ -0,0 +1,49 @@ +{ + "name": "bytes", + "author": { + "name": "TJ Holowaychuk", + "email": "tj@vision-media.ca", + "url": "http://tjholowaychuk.com" + }, + "description": "byte size string parser / serializer", + "repository": { + "type": "git", + "url": "https://github.com/visionmedia/bytes.js.git" + }, + "version": "1.0.0", + "main": "index.js", + "dependencies": {}, + "devDependencies": { + "mocha": "*", + "should": "*" + }, + "component": { + "scripts": { + "bytes/index.js": "index.js" + } + }, + "bugs": { + "url": "https://github.com/visionmedia/bytes.js/issues" + }, + "homepage": "https://github.com/visionmedia/bytes.js", + "_id": "bytes@1.0.0", + "dist": { + "shasum": "3569ede8ba34315fab99c3e92cb04c7220de1fa8", + "tarball": "http://registry.npmjs.org/bytes/-/bytes-1.0.0.tgz" + }, + "_from": "bytes@1.0.0", + "_npmVersion": "1.4.3", + "_npmUser": { + "name": "tjholowaychuk", + "email": "tj@vision-media.ca" + }, + "maintainers": [ + { + "name": "tjholowaychuk", + "email": "tj@vision-media.ca" + } + ], + "directories": {}, + "_shasum": "3569ede8ba34315fab99c3e92cb04c7220de1fa8", + "_resolved": "https://registry.npmjs.org/bytes/-/bytes-1.0.0.tgz" +} diff --git a/node_modules/body-parser/node_modules/depd/History.md b/node_modules/body-parser/node_modules/depd/History.md new file mode 100644 index 0000000..800eab1 --- /dev/null +++ b/node_modules/body-parser/node_modules/depd/History.md @@ -0,0 +1,62 @@ +0.4.5 / 2014-09-09 +================== + + * Improve call speed to functions using the function wrapper + * Support Node.js 0.6 + +0.4.4 / 2014-07-27 +================== + + * Work-around v8 generating empty stack traces + +0.4.3 / 2014-07-26 +================== + + * Fix exception when global `Error.stackTraceLimit` is too low + +0.4.2 / 2014-07-19 +================== + + * Correct call site for wrapped functions and properties + +0.4.1 / 2014-07-19 +================== + + * Improve automatic message generation for function properties + +0.4.0 / 2014-07-19 +================== + + * Add `TRACE_DEPRECATION` environment variable + * Remove non-standard grey color from color output + * Support `--no-deprecation` argument + * Support `--trace-deprecation` argument + * Support `deprecate.property(fn, prop, message)` + +0.3.0 / 2014-06-16 +================== + + * Add `NO_DEPRECATION` environment variable + +0.2.0 / 2014-06-15 +================== + + * Add `deprecate.property(obj, prop, message)` + * Remove `supports-color` dependency for node.js 0.8 + +0.1.0 / 2014-06-15 +================== + + * Add `deprecate.function(fn, message)` + * Add `process.on('deprecation', fn)` emitter + * Automatically generate message when omitted from `deprecate()` + +0.0.1 / 2014-06-15 +================== + + * Fix warning for dynamic calls at singe call site + +0.0.0 / 2014-06-15 +================== + + * Initial implementation diff --git a/node_modules/body-parser/node_modules/depd/LICENSE b/node_modules/body-parser/node_modules/depd/LICENSE new file mode 100644 index 0000000..b7dce6c --- /dev/null +++ b/node_modules/body-parser/node_modules/depd/LICENSE @@ -0,0 +1,22 @@ +(The MIT License) + +Copyright (c) 2014 Douglas Christopher Wilson + +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/node_modules/body-parser/node_modules/depd/Readme.md b/node_modules/body-parser/node_modules/depd/Readme.md new file mode 100644 index 0000000..098953e --- /dev/null +++ b/node_modules/body-parser/node_modules/depd/Readme.md @@ -0,0 +1,266 @@ +# depd + +[![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] +[![Gittip][gittip-image]][gittip-url] + +Deprecate all the things + +> With great modules comes great responsibility; mark things deprecated! + +## Install + +```sh +$ npm install depd +``` + +## API + +```js +var deprecate = require('depd')('my-module') +``` + +This library allows you to display deprecation messages to your users. +This library goes above and beyond with deprecation warnings by +introspecting the call stack (but only the bits that it is interested +in). + +Instead of just warning on the first invocation of a deprecated +function and never again, this module will warn on the first invocation +of a deprecated function per unique call site, making it ideal to alert +users of all deprecated uses across the code base, rather than just +whatever happens to execute first. + +The deprecation warnings from this module also include the file and line +information for the call into the module that the deprecated function was +in. + +### depd(namespace) + +Create a new deprecate function that uses the given namespace name in the +messages and will display the call site prior to the stack entering the +file this function was called from. It is highly suggested you use the +name of your module as the namespace. + +### deprecate(message) + +Call this function from deprecated code to display a deprecation message. +This message will appear once per unique caller site. Caller site is the +first call site in the stack in a different file from the caller of this +function. + +If the message is omitted, a message is generated for you based on the site +of the `deprecate()` call and will display the name of the function called, +similar to the name displayed in a stack trace. + +### deprecate.function(fn, message) + +Call this function to wrap a given function in a deprecation message on any +call to the function. An optional message can be supplied to provide a custom +message. + +### deprecate.property(obj, prop, message) + +Call this function to wrap a given property on object in a deprecation message +on any accessing or setting of the property. An optional message can be supplied +to provide a custom message. + +The method must be called on the object where the property belongs (not +inherited from the prototype). + +If the property is a data descriptor, it will be converted to an accessor +descriptor in order to display the deprecation message. + +### process.on('deprecation', fn) + +This module will allow easy capturing of deprecation errors by emitting the +errors as the type "deprecation" on the global `process`. If there are no +listeners for this type, the errors are written to STDERR as normal, but if +there are any listeners, nothing will be written to STDERR and instead only +emitted. From there, you can write the errors in a different format or to a +logging source. + +The error represents the deprecation and is emitted only once with the same +rules as writing to STDERR. The error has the following properties: + + - `message` - This is the message given by the library + - `name` - This is always `'DeprecationError'` + - `namespace` - This is the namespace the deprecation came from + - `stack` - This is the stack of the call to the deprecated thing + +Example `error.stack` output: + +``` +DeprecationError: my-cool-module deprecated oldfunction + at Object. ([eval]-wrapper:6:22) + at Module._compile (module.js:456:26) + at evalScript (node.js:532:25) + at startup (node.js:80:7) + at node.js:902:3 +``` + +### process.env.NO_DEPRECATION + +As a user of modules that are deprecated, the environment variable `NO_DEPRECATION` +is provided as a quick solution to silencing deprecation warnings from being +output. The format of this is similar to that of `DEBUG`: + +```sh +$ NO_DEPRECATION=my-module,othermod node app.js +``` + +This will suppress deprecations from being output for "my-module" and "othermod". +The value is a list of comma-separated namespaces. To suppress every warning +across all namespaces, use the value `*` for a namespace. + +Providing the argument `--no-deprecation` to the `node` executable will suppress +all deprecations (only available in Node.js 0.8 or higher). + +**NOTE** This will not suppress the deperecations given to any "deprecation" +event listeners, just the output to STDERR. + +### process.env.TRACE_DEPRECATION + +As a user of modules that are deprecated, the environment variable `TRACE_DEPRECATION` +is provided as a solution to getting more detailed location information in deprecation +warnings by including the entire stack trace. The format of this is the same as +`NO_DEPRECATION`: + +```sh +$ TRACE_DEPRECATION=my-module,othermod node app.js +``` + +This will include stack traces for deprecations being output for "my-module" and +"othermod". The value is a list of comma-separated namespaces. To trace every +warning across all namespaces, use the value `*` for a namespace. + +Providing the argument `--trace-deprecation` to the `node` executable will trace +all deprecations (only available in Node.js 0.8 or higher). + +**NOTE** This will not trace the deperecations silenced by `NO_DEPRECATION`. + +## Display + +![message](files/message.png) + +When a user calls a function in your library that you mark deprecated, they +will see the following written to STDERR (in the given colors, similar colors +and layout to the `debug` module): + +``` +bright cyan bright yellow +| | reset cyan +| | | | +▼ ▼ ▼ ▼ +my-cool-module deprecated oldfunction [eval]-wrapper:6:22 +▲ ▲ ▲ ▲ +| | | | +namespace | | location of mycoolmod.oldfunction() call + | deprecation message + the word "deprecated" +``` + +If the user redirects their STDERR to a file or somewhere that does not support +colors, they see (similar layout to the `debug` module): + +``` +Sun, 15 Jun 2014 05:21:37 GMT my-cool-module deprecated oldfunction at [eval]-wrapper:6:22 +▲ ▲ ▲ ▲ ▲ +| | | | | +timestamp of message namespace | | location of mycoolmod.oldfunction() call + | deprecation message + the word "deprecated" +``` + +## Examples + +### Deprecating all calls to a function + +This will display a deprecated message about "oldfunction" being deprecated +from "my-module" on STDERR. + +```js +var deprecate = require('depd')('my-cool-module') + +// message automatically derived from function name +// Object.oldfunction +exports.oldfunction = deprecate.function(function oldfunction() { + // all calls to function are deprecated +}) + +// specific message +exports.oldfunction = deprecate.function(function () { + // all calls to function are deprecated +}, 'oldfunction') +``` + +### Conditionally deprecating a function call + +This will display a deprecated message about "weirdfunction" being deprecated +from "my-module" on STDERR when called with less than 2 arguments. + +```js +var deprecate = require('depd')('my-cool-module') + +exports.weirdfunction = function () { + if (arguments.length < 2) { + // calls with 0 or 1 args are deprecated + deprecate('weirdfunction args < 2') + } +} +``` + +When calling `deprecate` as a function, the warning is counted per call site +within your own module, so you can display different deprecations depending +on different situations and the users will still get all the warnings: + +```js +var deprecate = require('depd')('my-cool-module') + +exports.weirdfunction = function () { + if (arguments.length < 2) { + // calls with 0 or 1 args are deprecated + deprecate('weirdfunction args < 2') + } else if (typeof arguments[0] !== 'string') { + // calls with non-string first argument are deprecated + deprecate('weirdfunction non-string first arg') + } +} +``` + +### Deprecating property access + +This will display a deprecated message about "oldprop" being deprecated +from "my-module" on STDERR when accessed. A deprecation will be displayed +when setting the value and when getting the value. + +```js +var deprecate = require('depd')('my-cool-module') + +exports.oldprop = 'something' + +// message automatically derives from property name +deprecate.property(exports, 'oldprop') + +// explicit message +deprecate.property(exports, 'oldprop', 'oldprop >= 0.10') +``` + +## License + +[MIT](LICENSE) + +[npm-version-image]: https://img.shields.io/npm/v/depd.svg?style=flat +[npm-downloads-image]: https://img.shields.io/npm/dm/depd.svg?style=flat +[npm-url]: https://npmjs.org/package/depd +[travis-image]: https://img.shields.io/travis/dougwilson/nodejs-depd.svg?style=flat +[travis-url]: https://travis-ci.org/dougwilson/nodejs-depd +[coveralls-image]: https://img.shields.io/coveralls/dougwilson/nodejs-depd.svg?style=flat +[coveralls-url]: https://coveralls.io/r/dougwilson/nodejs-depd?branch=master +[node-image]: https://img.shields.io/node/v/depd.svg?style=flat +[node-url]: http://nodejs.org/download/ +[gittip-image]: https://img.shields.io/gittip/dougwilson.svg?style=flat +[gittip-url]: https://www.gittip.com/dougwilson/ diff --git a/node_modules/body-parser/node_modules/depd/index.js b/node_modules/body-parser/node_modules/depd/index.js new file mode 100644 index 0000000..4fee4d9 --- /dev/null +++ b/node_modules/body-parser/node_modules/depd/index.js @@ -0,0 +1,522 @@ +/*! + * depd + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module dependencies. + */ + +var callSiteToString = require('./lib/compat').callSiteToString +var EventEmitter = require('events').EventEmitter +var relative = require('path').relative + +/** + * Module exports. + */ + +module.exports = depd + +/** + * Get the path to base files on. + */ + +var basePath = process.cwd() + +/** + * Get listener count on event emitter. + */ + +/*istanbul ignore next*/ +var eventListenerCount = EventEmitter.listenerCount + || function (emitter, type) { return emitter.listeners(type).length } + +/** + * Determine if namespace is contained in the string. + */ + +function containsNamespace(str, namespace) { + var val = str.split(/[ ,]+/) + + namespace = String(namespace).toLowerCase() + + for (var i = 0 ; i < val.length; i++) { + if (!(str = val[i])) continue; + + // namespace contained + if (str === '*' || str.toLowerCase() === namespace) { + return true + } + } + + return false +} + +/** + * Convert a data descriptor to accessor descriptor. + */ + +function convertDataDescriptorToAccessor(obj, prop, message) { + var descriptor = Object.getOwnPropertyDescriptor(obj, prop) + var value = descriptor.value + + descriptor.get = function getter() { return value } + + if (descriptor.writable) { + descriptor.set = function setter(val) { return value = val } + } + + delete descriptor.value + delete descriptor.writable + + Object.defineProperty(obj, prop, descriptor) + + return descriptor +} + +/** + * Create arguments string to keep arity. + */ + +function createArgumentsString(arity) { + var str = '' + + for (var i = 0; i < arity; i++) { + str += ', arg' + i + } + + return str.substr(2) +} + +/** + * Create stack string from stack. + */ + +function createStackString(stack) { + var str = this.name + ': ' + this.namespace + + if (this.message) { + str += ' deprecated ' + this.message + } + + for (var i = 0; i < stack.length; i++) { + str += '\n at ' + callSiteToString(stack[i]) + } + + return str +} + +/** + * Create deprecate for namespace in caller. + */ + +function depd(namespace) { + if (!namespace) { + throw new TypeError('argument namespace is required') + } + + var stack = getStack() + var site = callSiteLocation(stack[1]) + var file = site[0] + + function deprecate(message) { + // call to self as log + log.call(deprecate, message) + } + + deprecate._file = file + deprecate._ignored = isignored(namespace) + deprecate._namespace = namespace + deprecate._traced = istraced(namespace) + deprecate._warned = Object.create(null) + + deprecate.function = wrapfunction + deprecate.property = wrapproperty + + return deprecate +} + +/** + * Determine if namespace is ignored. + */ + +function isignored(namespace) { + /* istanbul ignore next: tested in a child processs */ + if (process.noDeprecation) { + // --no-deprecation support + return true + } + + var str = process.env.NO_DEPRECATION || '' + + // namespace ignored + return containsNamespace(str, namespace) +} + +/** + * Determine if namespace is traced. + */ + +function istraced(namespace) { + /* istanbul ignore next: tested in a child processs */ + if (process.traceDeprecation) { + // --trace-deprecation support + return true + } + + var str = process.env.TRACE_DEPRECATION || '' + + // namespace traced + return containsNamespace(str, namespace) +} + +/** + * Display deprecation message. + */ + +function log(message, site) { + var haslisteners = eventListenerCount(process, 'deprecation') !== 0 + + // abort early if no destination + if (!haslisteners && this._ignored) { + return + } + + var caller + var callFile + var callSite + var i = 0 + var seen = false + var stack = getStack() + var file = this._file + + if (site) { + // provided site + callSite = callSiteLocation(stack[1]) + callSite.name = site.name + file = callSite[0] + } else { + // get call site + i = 2 + site = callSiteLocation(stack[i]) + callSite = site + } + + // get caller of deprecated thing in relation to file + for (; i < stack.length; i++) { + caller = callSiteLocation(stack[i]) + callFile = caller[0] + + if (callFile === file) { + seen = true + } else if (callFile === this._file) { + file = this._file + } else if (seen) { + break + } + } + + var key = caller + ? site.join(':') + '__' + caller.join(':') + : undefined + + if (key !== undefined && key in this._warned) { + // already warned + return + } + + this._warned[key] = true + + // generate automatic message from call site + if (!message) { + message = callSite === site || !callSite.name + ? defaultMessage(site) + : defaultMessage(callSite) + } + + // emit deprecation if listeners exist + if (haslisteners) { + var err = DeprecationError(this._namespace, message, stack.slice(i)) + process.emit('deprecation', err) + return + } + + // format and write message + var format = process.stderr.isTTY + ? formatColor + : formatPlain + var msg = format.call(this, message, caller, stack.slice(i)) + process.stderr.write(msg + '\n', 'utf8') + + return +} + +/** + * Get call site location as array. + */ + +function callSiteLocation(callSite) { + var file = callSite.getFileName() || '' + var line = callSite.getLineNumber() + var colm = callSite.getColumnNumber() + + if (callSite.isEval()) { + file = callSite.getEvalOrigin() + ', ' + file + } + + var site = [file, line, colm] + + site.callSite = callSite + site.name = callSite.getFunctionName() + + return site +} + +/** + * Generate a default message from the site. + */ + +function defaultMessage(site) { + var callSite = site.callSite + var funcName = site.name + var typeName = callSite.getTypeName() + + // make useful anonymous name + if (!funcName) { + funcName = '' + } + + // make useful type name + if (typeName === 'Function') { + typeName = callSite.getThis().name || typeName + } + + return callSite.getMethodName() + ? typeName + '.' + funcName + : funcName +} + +/** + * Format deprecation message without color. + */ + +function formatPlain(msg, caller, stack) { + var timestamp = new Date().toUTCString() + + var formatted = timestamp + + ' ' + this._namespace + + ' deprecated ' + msg + + // add stack trace + if (this._traced) { + for (var i = 0; i < stack.length; i++) { + formatted += '\n at ' + callSiteToString(stack[i]) + } + + return formatted + } + + if (caller) { + formatted += ' at ' + formatLocation(caller) + } + + return formatted +} + +/** + * Format deprecation message with color. + */ + +function formatColor(msg, caller, stack) { + var formatted = '\x1b[36;1m' + this._namespace + '\x1b[22;39m' // bold cyan + + ' \x1b[33;1mdeprecated\x1b[22;39m' // bold yellow + + ' \x1b[0m' + msg + '\x1b[39m' // reset + + // add stack trace + if (this._traced) { + for (var i = 0; i < stack.length; i++) { + formatted += '\n \x1b[36mat ' + callSiteToString(stack[i]) + '\x1b[39m' // cyan + } + + return formatted + } + + if (caller) { + formatted += ' \x1b[36m' + formatLocation(caller) + '\x1b[39m' // cyan + } + + return formatted +} + +/** + * Format call site location. + */ + +function formatLocation(callSite) { + return relative(basePath, callSite[0]) + + ':' + callSite[1] + + ':' + callSite[2] +} + +/** + * Get the stack as array of call sites. + */ + +function getStack() { + var limit = Error.stackTraceLimit + var obj = {} + var prep = Error.prepareStackTrace + + Error.prepareStackTrace = prepareObjectStackTrace + Error.stackTraceLimit = Math.max(10, limit) + + // capture the stack + Error.captureStackTrace(obj) + + // slice this function off the top + var stack = obj.stack.slice(1) + + Error.prepareStackTrace = prep + Error.stackTraceLimit = limit + + return stack +} + +/** + * Capture call site stack from v8. + */ + +function prepareObjectStackTrace(obj, stack) { + return stack +} + +/** + * Return a wrapped function in a deprecation message. + */ + +function wrapfunction(fn, message) { + if (typeof fn !== 'function') { + throw new TypeError('argument fn must be a function') + } + + var args = createArgumentsString(fn.length) + var deprecate = this + var stack = getStack() + var site = callSiteLocation(stack[1]) + + site.name = fn.name + + var deprecatedfn = eval('(function (' + args + ') {\n' + + '"use strict"\n' + + 'log.call(deprecate, message, site)\n' + + 'return fn.apply(this, arguments)\n' + + '})') + + return deprecatedfn +} + +/** + * Wrap property in a deprecation message. + */ + +function wrapproperty(obj, prop, message) { + if (!obj || (typeof obj !== 'object' && typeof obj !== 'function')) { + throw new TypeError('argument obj must be object') + } + + var descriptor = Object.getOwnPropertyDescriptor(obj, prop) + + if (!descriptor) { + throw new TypeError('must call property on owner object') + } + + if (!descriptor.configurable) { + throw new TypeError('property must be configurable') + } + + var deprecate = this + var stack = getStack() + var site = callSiteLocation(stack[1]) + + // set site name + site.name = prop + + // convert data descriptor + if ('value' in descriptor) { + descriptor = convertDataDescriptorToAccessor(obj, prop, message) + } + + var get = descriptor.get + var set = descriptor.set + + // wrap getter + if (typeof get === 'function') { + descriptor.get = function getter() { + log.call(deprecate, message, site) + return get.apply(this, arguments) + } + } + + // wrap setter + if (typeof set === 'function') { + descriptor.set = function setter() { + log.call(deprecate, message, site) + return set.apply(this, arguments) + } + } + + Object.defineProperty(obj, prop, descriptor) +} + +/** + * Create DeprecationError for deprecation + */ + +function DeprecationError(namespace, message, stack) { + var error = new Error() + var stackString + + Object.defineProperty(error, 'constructor', { + value: DeprecationError + }) + + Object.defineProperty(error, 'message', { + configurable: true, + enumerable: false, + value: message, + writable: true + }) + + Object.defineProperty(error, 'name', { + enumerable: false, + configurable: true, + value: 'DeprecationError', + writable: true + }) + + Object.defineProperty(error, 'namespace', { + configurable: true, + enumerable: false, + value: namespace, + writable: true + }) + + Object.defineProperty(error, 'stack', { + configurable: true, + enumerable: false, + get: function () { + if (stackString !== undefined) { + return stackString + } + + // prepare stack trace + return stackString = createStackString.call(this, stack) + }, + set: function setter(val) { + stackString = val + } + }) + + return error +} diff --git a/node_modules/body-parser/node_modules/depd/lib/compat/buffer-concat.js b/node_modules/body-parser/node_modules/depd/lib/compat/buffer-concat.js new file mode 100644 index 0000000..09d9721 --- /dev/null +++ b/node_modules/body-parser/node_modules/depd/lib/compat/buffer-concat.js @@ -0,0 +1,33 @@ +/*! + * depd + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module exports. + */ + +module.exports = bufferConcat + +/** + * Concatenate an array of Buffers. + */ + +function bufferConcat(bufs) { + var length = 0 + + for (var i = 0, len = bufs.length; i < len; i++) { + length += bufs[i].length + } + + var buf = new Buffer(length) + var pos = 0 + + for (var i = 0, len = bufs.length; i < len; i++) { + bufs[i].copy(buf, pos) + pos += bufs[i].length + } + + return buf +} diff --git a/node_modules/body-parser/node_modules/depd/lib/compat/callsite-tostring.js b/node_modules/body-parser/node_modules/depd/lib/compat/callsite-tostring.js new file mode 100644 index 0000000..17cf7ed --- /dev/null +++ b/node_modules/body-parser/node_modules/depd/lib/compat/callsite-tostring.js @@ -0,0 +1,101 @@ +/*! + * depd + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module exports. + */ + +module.exports = callSiteToString + +/** + * Format a CallSite file location to a string. + */ + +function callSiteFileLocation(callSite) { + var fileName + var fileLocation = '' + + if (callSite.isNative()) { + fileLocation = 'native' + } else if (callSite.isEval()) { + fileName = callSite.getScriptNameOrSourceURL() + if (!fileName) { + fileLocation = callSite.getEvalOrigin() + } + } else { + fileName = callSite.getFileName() + } + + if (fileName) { + fileLocation += fileName + + var lineNumber = callSite.getLineNumber() + if (lineNumber != null) { + fileLocation += ':' + lineNumber + + var columnNumber = callSite.getColumnNumber() + if (columnNumber) { + fileLocation += ':' + columnNumber + } + } + } + + return fileLocation || 'unknown source' +} + +/** + * Format a CallSite to a string. + */ + +function callSiteToString(callSite) { + var addSuffix = true + var fileLocation = callSiteFileLocation(callSite) + var functionName = callSite.getFunctionName() + var isConstructor = callSite.isConstructor() + var isMethodCall = !(callSite.isToplevel() || isConstructor) + var line = '' + + if (isMethodCall) { + var methodName = callSite.getMethodName() + var typeName = getConstructorName(callSite) + + if (functionName) { + if (typeName && functionName.indexOf(typeName) !== 0) { + line += typeName + '.' + } + + line += functionName + + if (methodName && functionName.lastIndexOf('.' + methodName) !== functionName.length - methodName.length - 1) { + line += ' [as ' + methodName + ']' + } + } else { + line += typeName + '.' + (methodName || '') + } + } else if (isConstructor) { + line += 'new ' + (functionName || '') + } else if (functionName) { + line += functionName + } else { + addSuffix = false + line += fileLocation + } + + if (addSuffix) { + line += ' (' + fileLocation + ')' + } + + return line +} + +/** + * Get constructor name of reviver. + */ + +function getConstructorName(obj) { + var receiver = obj.receiver + return (receiver.constructor && receiver.constructor.name) || null +} diff --git a/node_modules/body-parser/node_modules/depd/lib/compat/index.js b/node_modules/body-parser/node_modules/depd/lib/compat/index.js new file mode 100644 index 0000000..7fee026 --- /dev/null +++ b/node_modules/body-parser/node_modules/depd/lib/compat/index.js @@ -0,0 +1,69 @@ +/*! + * depd + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module exports. + */ + +lazyProperty(module.exports, 'bufferConcat', function bufferConcat() { + return Buffer.concat || require('./buffer-concat') +}) + +lazyProperty(module.exports, 'callSiteToString', function callSiteToString() { + var limit = Error.stackTraceLimit + var obj = {} + var prep = Error.prepareStackTrace + + function prepareObjectStackTrace(obj, stack) { + return stack + } + + Error.prepareStackTrace = prepareObjectStackTrace + Error.stackTraceLimit = 2 + + // capture the stack + Error.captureStackTrace(obj) + + // slice the stack + var stack = obj.stack.slice() + + Error.prepareStackTrace = prep + Error.stackTraceLimit = limit + + return stack[0].toString ? toString : require('./callsite-tostring') +}) + +/** + * Define a lazy property. + */ + +function lazyProperty(obj, prop, getter) { + function get() { + var val = getter() + + Object.defineProperty(obj, prop, { + configurable: true, + enumerable: true, + value: val + }) + + return val + } + + Object.defineProperty(obj, prop, { + configurable: true, + enumerable: true, + get: get + }) +} + +/** + * Call toString() on the obj + */ + +function toString(obj) { + return obj.toString() +} diff --git a/node_modules/body-parser/node_modules/depd/package.json b/node_modules/body-parser/node_modules/depd/package.json new file mode 100644 index 0000000..55a9db0 --- /dev/null +++ b/node_modules/body-parser/node_modules/depd/package.json @@ -0,0 +1,67 @@ +{ + "name": "depd", + "description": "Deprecate all the things", + "version": "0.4.5", + "author": { + "name": "Douglas Christopher Wilson", + "email": "doug@somethingdoug.com" + }, + "license": "MIT", + "keywords": [ + "deprecate", + "deprecated" + ], + "repository": { + "type": "git", + "url": "https://github.com/dougwilson/nodejs-depd" + }, + "devDependencies": { + "benchmark": "1.0.0", + "beautify-benchmark": "0.2.4", + "istanbul": "0.3.2", + "mocha": "~1.21.4", + "should": "~4.0.4" + }, + "files": [ + "lib/", + "History.md", + "LICENSE", + "index.js", + "Readme.md" + ], + "engines": { + "node": ">= 0.6" + }, + "scripts": { + "bench": "node benchmark/index.js", + "test": "mocha --reporter spec --bail --require should test/", + "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --require should test/", + "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --require should test/" + }, + "gitHead": "e37a15044f7da76b94d8e0d46a6343feb168c82b", + "bugs": { + "url": "https://github.com/dougwilson/nodejs-depd/issues" + }, + "homepage": "https://github.com/dougwilson/nodejs-depd", + "_id": "depd@0.4.5", + "_shasum": "1a664b53388b4a6573e8ae67b5f767c693ca97f1", + "_from": "depd@0.4.5", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + "maintainers": [ + { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + } + ], + "dist": { + "shasum": "1a664b53388b4a6573e8ae67b5f767c693ca97f1", + "tarball": "http://registry.npmjs.org/depd/-/depd-0.4.5.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/depd/-/depd-0.4.5.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/body-parser/node_modules/iconv-lite/.npmignore b/node_modules/body-parser/node_modules/iconv-lite/.npmignore new file mode 100644 index 0000000..6c69ea0 --- /dev/null +++ b/node_modules/body-parser/node_modules/iconv-lite/.npmignore @@ -0,0 +1,5 @@ +*~ +*sublime-* +generation +test +wiki diff --git a/node_modules/body-parser/node_modules/iconv-lite/.travis.yml b/node_modules/body-parser/node_modules/iconv-lite/.travis.yml new file mode 100644 index 0000000..9169b9f --- /dev/null +++ b/node_modules/body-parser/node_modules/iconv-lite/.travis.yml @@ -0,0 +1,5 @@ + language: node_js + node_js: + - 0.8 + - 0.10 + - 0.11 diff --git a/node_modules/body-parser/node_modules/iconv-lite/Changelog.md b/node_modules/body-parser/node_modules/iconv-lite/Changelog.md new file mode 100644 index 0000000..75db5f9 --- /dev/null +++ b/node_modules/body-parser/node_modules/iconv-lite/Changelog.md @@ -0,0 +1,29 @@ + +# 0.4.4 / 2014-07-16 + + * added encodings UTF-7 (RFC2152) and UTF-7-IMAP (RFC3501 Section 5.1.3) + * fixed streaming base64 encoding + +# 0.4.3 / 2014-06-14 + + * added encodings UTF-16BE and UTF-16 with BOM + +# 0.4.2 / 2014-06-12 + + * don't throw exception if `extendNodeEncodings()` is called more than once + +# 0.4.1 / 2014-06-11 + + * codepage 808 added + + +# 0.4.0 / 2014-06-10 + + * code is rewritten from scratch + * all widespread encodings are supported + * streaming interface added + * browserify compatibility added + * (optional) extend core primitive encodings to make usage even simpler + * moved from vows to mocha as the testing framework + + diff --git a/node_modules/body-parser/node_modules/iconv-lite/LICENSE b/node_modules/body-parser/node_modules/iconv-lite/LICENSE new file mode 100644 index 0000000..d518d83 --- /dev/null +++ b/node_modules/body-parser/node_modules/iconv-lite/LICENSE @@ -0,0 +1,21 @@ +Copyright (c) 2011 Alexander Shtuchkin + +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/node_modules/body-parser/node_modules/iconv-lite/README.md b/node_modules/body-parser/node_modules/iconv-lite/README.md new file mode 100644 index 0000000..f8d0845 --- /dev/null +++ b/node_modules/body-parser/node_modules/iconv-lite/README.md @@ -0,0 +1,137 @@ +## Pure JS character encoding conversion + + + + * Doesn't need native code compilation. Works on Windows and in sandboxed environments like [Cloud9](http://c9.io). + * Used in popular projects like [Grunt](http://gruntjs.com/), [Nodemailer](http://www.nodemailer.com/), [Yeoman](http://yeoman.io/) and others. + * Faster than [node-iconv](https://github.com/bnoordhuis/node-iconv) (see below for performance comparison). + * Intuitive encode/decode API + * Streaming support for Node v0.10+ + * Can extend Node.js primitives (buffers, streams) to support all iconv-lite encodings. + * In-browser usage via [Browserify](https://github.com/substack/node-browserify) (~180k gzip compressed with Buffer shim included). + * License: MIT. + +[![NPM Stats](https://nodei.co/npm/iconv-lite.png?downloads=true)](https://npmjs.org/packages/iconv-lite/) + +## Usage +### Basic API +```javascript +var iconv = require('iconv-lite'); + +// Convert from an encoded buffer to js string. +str = iconv.decode(new Buffer([0x68, 0x65, 0x6c, 0x6c, 0x6f]), 'win1251'); + +// Convert from js string to an encoded buffer. +buf = iconv.encode("Sample input string", 'win1251'); + +// Check if encoding is supported +iconv.encodingExists("us-ascii") +``` + +### Streaming API (Node v0.10+) +```javascript + +// Decode stream (from binary stream to js strings) +http.createServer(function(req, res) { + var converterStream = iconv.decodeStream('win1251'); + req.pipe(converterStream); + + converterStream.on('data', function(str) { + console.log(str); // Do something with decoded strings, chunk-by-chunk. + }); +}); + +// Convert encoding streaming example +fs.createReadStream('file-in-win1251.txt') + .pipe(iconv.decodeStream('win1251')) + .pipe(iconv.encodeStream('ucs2')) + .pipe(fs.createWriteStream('file-in-ucs2.txt')); + +// Sugar: all encode/decode streams have .collect(cb) method to accumulate data. +http.createServer(function(req, res) { + req.pipe(iconv.decodeStream('win1251')).collect(function(err, body) { + assert(typeof body == 'string'); + console.log(body); // full request body string + }); +}); +``` + +### Extend Node.js own encodings +```javascript +// After this call all Node basic primitives will understand iconv-lite encodings. +iconv.extendNodeEncodings(); + +// Examples: +buf = new Buffer(str, 'win1251'); +buf.write(str, 'gbk'); +str = buf.toString('latin1'); +assert(Buffer.isEncoding('iso-8859-15')); +Buffer.byteLength(str, 'us-ascii'); + +http.createServer(function(req, res) { + req.setEncoding('big5'); + req.collect(function(err, body) { + console.log(body); + }); +}); + +fs.createReadStream("file.txt", "shift_jis"); + +// External modules are also supported (if they use Node primitives, which they probably do). +request = require('request'); +request({ + url: "http://github.com/", + encoding: "cp932" +}); + +// To remove extensions +iconv.undoExtendNodeEncodings(); +``` + +## Supported encodings + + * All node.js native encodings: utf8, ucs2 / utf16-le, ascii, binary, base64, hex. + * Additional unicode encodings: utf16, utf16-be, utf-7, utf-7-imap. + * All widespread singlebyte encodings: Windows 125x family, ISO-8859 family, + IBM/DOS codepages, Macintosh family, KOI8 family, all others supported by iconv library. + Aliases like 'latin1', 'us-ascii' also supported. + * All widespread multibyte encodings: CP932, CP936, CP949, CP950, GB2313, GBK, GB18030, Big5, Shift_JIS, EUC-JP. + +See [all supported encodings on wiki](https://github.com/ashtuchkin/iconv-lite/wiki/Supported-Encodings). + +Most singlebyte encodings are generated automatically from [node-iconv](https://github.com/bnoordhuis/node-iconv). Thank you Ben Noordhuis and libiconv authors! + +Multibyte encodings are generated from [Unicode.org mappings](http://www.unicode.org/Public/MAPPINGS/) and [WHATWG Encoding Standard mappings](http://encoding.spec.whatwg.org/). Thank you, respective authors! + + +## Encoding/decoding speed + +Comparison with node-iconv module (1000x256kb, on MacBook Pro, Core i5/2.6 GHz, Node v0.10.26). +Note: your results may vary, so please always check on your hardware. + + operation iconv@2.1.4 iconv-lite@0.4.0 + ---------------------------------------------------------- + encode('win1251') ~130 Mb/s ~380 Mb/s + decode('win1251') ~127 Mb/s ~210 Mb/s + + +## Notes + +When decoding, be sure to supply a Buffer to decode() method, otherwise [bad things usually happen](https://github.com/ashtuchkin/iconv-lite/wiki/Use-Buffers-when-decoding). +Untranslatable characters are set to � or ?. No transliteration is currently supported. + +## Testing + +```bash +$ git clone git@github.com:ashtuchkin/iconv-lite.git +$ cd iconv-lite +$ npm install +$ npm test + +$ # To view performance: +$ node test/performance.js +``` + +## Adoption +[![NPM](https://nodei.co/npm-dl/iconv-lite.png)](https://nodei.co/npm/iconv-lite/) + diff --git a/node_modules/body-parser/node_modules/iconv-lite/README.md~ b/node_modules/body-parser/node_modules/iconv-lite/README.md~ new file mode 100644 index 0000000..5f57561 --- /dev/null +++ b/node_modules/body-parser/node_modules/iconv-lite/README.md~ @@ -0,0 +1,54 @@ +iconv-lite - native javascript conversion between character encodings. +====================================================================== + +## Usage + + var iconv = require('iconv-lite'); + + // Convert from an encoded buffer to string. + str = iconv.fromEncoding(buf, 'win-1251'); + // Or + str = iconv.decode(buf, 'win-1251'); + + // Convert from string to an encoded buffer. + buf = iconv.toEncoding("Sample input string", 'win-1251'); + // Or + buf = iconv.encode("Sample input string", 'win-1251'); + +## Supported encodings + +Currently only a small part of encodings supported: + +* All node.js native encodings: 'utf8', 'ucs2', 'ascii', 'binary', 'base64'. +* 'latin1' +* Cyrillic encodings: 'windows-1251', 'koi8-r', 'iso 8859-5'. + +Other encodings are easy to add, see the source. Please, participate. + + +## Encoding/decoding speed + +Comparison with iconv module (1000 times 256kb, on Core i5/2.5 GHz). + + Operation\module iconv iconv-lite (this) + toEncoding('win1251') 19.57 mb/s 49.04 mb/s + fromEncoding('win1251') 16.39 mb/s 24.11 mb/s + + +## Notes + +This module is JavaScript-only, thus can be used in a sandboxed environment like [Cloud9](http://c9.io). + +Untranslatable characters are set to '?'. No transliteration is currently supported, pull requests are welcome. + +## Testing + + npm install --dev iconv-lite + vows + +## TODO + +* Support streaming character conversion, something like util.pipe(req, iconv.fromEncodingStream('latin1')). +* Add more encodings. +* Add transliteration (best fit char). +* Add tests and correct support of variable-byte encodings (currently work is delegated to node). diff --git a/node_modules/body-parser/node_modules/iconv-lite/encodings/dbcs-codec.js b/node_modules/body-parser/node_modules/iconv-lite/encodings/dbcs-codec.js new file mode 100644 index 0000000..fd3681c --- /dev/null +++ b/node_modules/body-parser/node_modules/iconv-lite/encodings/dbcs-codec.js @@ -0,0 +1,564 @@ + +// Multibyte codec. In this scheme, a character is represented by 1 or more bytes. +// Our codec supports UTF-16 surrogates, extensions for GB18030 and unicode sequences. +// To save memory and loading time, we read table files only when requested. + +exports._dbcs = function(options) { + return new DBCSCodec(options); +} + +var UNASSIGNED = -1, + GB18030_CODE = -2, + SEQ_START = -10, + NODE_START = -1000, + UNASSIGNED_NODE = new Array(0x100), + DEF_CHAR = -1; + +for (var i = 0; i < 0x100; i++) + UNASSIGNED_NODE[i] = UNASSIGNED; + + +// Class DBCSCodec reads and initializes mapping tables. +function DBCSCodec(options) { + this.options = options; + if (!options) + throw new Error("DBCS codec is called without the data.") + if (!options.table) + throw new Error("Encoding '" + options.encodingName + "' has no data."); + + // Load tables. + var mappingTable = options.table(); + + + // Decode tables: MBCS -> Unicode. + + // decodeTables is a trie, encoded as an array of arrays of integers. Internal arrays are trie nodes and all have len = 256. + // Trie root is decodeTables[0]. + // Values: >= 0 -> unicode character code. can be > 0xFFFF + // == UNASSIGNED -> unknown/unassigned sequence. + // == GB18030_CODE -> this is the end of a GB18030 4-byte sequence. + // <= NODE_START -> index of the next node in our trie to process next byte. + // <= SEQ_START -> index of the start of a character code sequence, in decodeTableSeq. + this.decodeTables = []; + this.decodeTables[0] = UNASSIGNED_NODE.slice(0); // Create root node. + + // Sometimes a MBCS char corresponds to a sequence of unicode chars. We store them as arrays of integers here. + this.decodeTableSeq = []; + + // Actual mapping tables consist of chunks. Use them to fill up decode tables. + for (var i = 0; i < mappingTable.length; i++) + this._addDecodeChunk(mappingTable[i]); + + this.defaultCharUnicode = options.iconv.defaultCharUnicode; + + + // Encode tables: Unicode -> DBCS. + + // `encodeTable` is array mapping from unicode char to encoded char. All its values are integers for performance. + // Because it can be sparse, it is represented as array of buckets by 256 chars each. Bucket can be null. + // Values: >= 0 -> it is a normal char. Write the value (if <=256 then 1 byte, if <=65536 then 2 bytes, etc.). + // == UNASSIGNED -> no conversion found. Output a default char. + // <= SEQ_START -> it's an index in encodeTableSeq, see below. The character starts a sequence. + this.encodeTable = []; + + // `encodeTableSeq` is used when a sequence of unicode characters is encoded as a single code. We use a tree of + // objects where keys correspond to characters in sequence and leafs are the encoded dbcs values. A special DEF_CHAR key + // means end of sequence (needed when one sequence is a strict subsequence of another). + // Objects are kept separately from encodeTable to increase performance. + this.encodeTableSeq = []; + + // Some chars can be decoded, but need not be encoded. + var skipEncodeChars = {}; + if (options.encodeSkipVals) + for (var i = 0; i < options.encodeSkipVals.length; i++) { + var range = options.encodeSkipVals[i]; + for (var j = range.from; j <= range.to; j++) + skipEncodeChars[j] = true; + } + + // Use decode trie to recursively fill out encode tables. + this._fillEncodeTable(0, 0, skipEncodeChars); + + // Add more encoding pairs when needed. + for (var uChar in options.encodeAdd || {}) + this._setEncodeChar(uChar.charCodeAt(0), options.encodeAdd[uChar]); + + this.defCharSB = this.encodeTable[0][options.iconv.defaultCharSingleByte.charCodeAt(0)]; + if (this.defCharSB === UNASSIGNED) this.defCharSB = this.encodeTable[0]['?']; + if (this.defCharSB === UNASSIGNED) this.defCharSB = "?".charCodeAt(0); + + + // Load & create GB18030 tables when needed. + if (typeof options.gb18030 === 'function') { + this.gb18030 = options.gb18030(); // Load GB18030 ranges. + + // Add GB18030 decode tables. + var thirdByteNodeIdx = this.decodeTables.length; + var thirdByteNode = this.decodeTables[thirdByteNodeIdx] = UNASSIGNED_NODE.slice(0); + + var fourthByteNodeIdx = this.decodeTables.length; + var fourthByteNode = this.decodeTables[fourthByteNodeIdx] = UNASSIGNED_NODE.slice(0); + + for (var i = 0x81; i <= 0xFE; i++) { + var secondByteNodeIdx = NODE_START - this.decodeTables[0][i]; + var secondByteNode = this.decodeTables[secondByteNodeIdx]; + for (var j = 0x30; j <= 0x39; j++) + secondByteNode[j] = NODE_START - thirdByteNodeIdx; + } + for (var i = 0x81; i <= 0xFE; i++) + thirdByteNode[i] = NODE_START - fourthByteNodeIdx; + for (var i = 0x30; i <= 0x39; i++) + fourthByteNode[i] = GB18030_CODE + } +} + +// Public interface: create encoder and decoder objects. +// The methods (write, end) are simple functions to not inhibit optimizations. +DBCSCodec.prototype.encoder = function encoderDBCS(options) { + return { + // Methods + write: encoderDBCSWrite, + end: encoderDBCSEnd, + + // Encoder state + leadSurrogate: -1, + seqObj: undefined, + + // Static data + encodeTable: this.encodeTable, + encodeTableSeq: this.encodeTableSeq, + defaultCharSingleByte: this.defCharSB, + gb18030: this.gb18030, + + // Export for testing + findIdx: findIdx, + } +} + +DBCSCodec.prototype.decoder = function decoderDBCS(options) { + return { + // Methods + write: decoderDBCSWrite, + end: decoderDBCSEnd, + + // Decoder state + nodeIdx: 0, + prevBuf: new Buffer(0), + + // Static data + decodeTables: this.decodeTables, + decodeTableSeq: this.decodeTableSeq, + defaultCharUnicode: this.defaultCharUnicode, + gb18030: this.gb18030, + } +} + + + +// Decoder helpers +DBCSCodec.prototype._getDecodeTrieNode = function(addr) { + var bytes = []; + for (; addr > 0; addr >>= 8) + bytes.push(addr & 0xFF); + if (bytes.length == 0) + bytes.push(0); + + var node = this.decodeTables[0]; + for (var i = bytes.length-1; i > 0; i--) { // Traverse nodes deeper into the trie. + var val = node[bytes[i]]; + + if (val == UNASSIGNED) { // Create new node. + node[bytes[i]] = NODE_START - this.decodeTables.length; + this.decodeTables.push(node = UNASSIGNED_NODE.slice(0)); + } + else if (val <= NODE_START) { // Existing node. + node = this.decodeTables[NODE_START - val]; + } + else + throw new Error("Overwrite byte in " + this.options.encodingName + ", addr: " + addr.toString(16)); + } + return node; +} + + +DBCSCodec.prototype._addDecodeChunk = function(chunk) { + // First element of chunk is the hex mbcs code where we start. + var curAddr = parseInt(chunk[0], 16); + + // Choose the decoding node where we'll write our chars. + var writeTable = this._getDecodeTrieNode(curAddr); + curAddr = curAddr & 0xFF; + + // Write all other elements of the chunk to the table. + for (var k = 1; k < chunk.length; k++) { + var part = chunk[k]; + if (typeof part === "string") { // String, write as-is. + for (var l = 0; l < part.length;) { + var code = part.charCodeAt(l++); + if (0xD800 <= code && code < 0xDC00) { // Decode surrogate + var codeTrail = part.charCodeAt(l++); + if (0xDC00 <= codeTrail && codeTrail < 0xE000) + writeTable[curAddr++] = 0x10000 + (code - 0xD800) * 0x400 + (codeTrail - 0xDC00); + else + throw new Error("Incorrect surrogate pair in " + this.options.encodingName + " at chunk " + chunk[0]); + } + else if (0x0FF0 < code && code <= 0x0FFF) { // Character sequence (our own encoding used) + var len = 0xFFF - code + 2; + var seq = []; + for (var m = 0; m < len; m++) + seq.push(part.charCodeAt(l++)); // Simple variation: don't support surrogates or subsequences in seq. + + writeTable[curAddr++] = SEQ_START - this.decodeTableSeq.length; + this.decodeTableSeq.push(seq); + } + else + writeTable[curAddr++] = code; // Basic char + } + } + else if (typeof part === "number") { // Integer, meaning increasing sequence starting with prev character. + var charCode = writeTable[curAddr - 1] + 1; + for (var l = 0; l < part; l++) + writeTable[curAddr++] = charCode++; + } + else + throw new Error("Incorrect type '" + typeof part + "' given in " + this.options.encodingName + " at chunk " + chunk[0]); + } + if (curAddr > 0xFF) + throw new Error("Incorrect chunk in " + this.options.encodingName + " at addr " + chunk[0] + ": too long" + curAddr); +} + +// Encoder helpers +DBCSCodec.prototype._getEncodeBucket = function(uCode) { + var high = uCode >> 8; // This could be > 0xFF because of astral characters. + if (this.encodeTable[high] === undefined) + this.encodeTable[high] = UNASSIGNED_NODE.slice(0); // Create bucket on demand. + return this.encodeTable[high]; +} + +DBCSCodec.prototype._setEncodeChar = function(uCode, dbcsCode) { + var bucket = this._getEncodeBucket(uCode); + var low = uCode & 0xFF; + if (bucket[low] <= SEQ_START) + this.encodeTableSeq[SEQ_START-bucket[low]][DEF_CHAR] = dbcsCode; // There's already a sequence, set a single-char subsequence of it. + else if (bucket[low] == UNASSIGNED) + bucket[low] = dbcsCode; +} + +DBCSCodec.prototype._setEncodeSequence = function(seq, dbcsCode) { + + // Get the root of character tree according to first character of the sequence. + var uCode = seq[0]; + var bucket = this._getEncodeBucket(uCode); + var low = uCode & 0xFF; + + var node; + if (bucket[low] <= SEQ_START) { + // There's already a sequence with - use it. + node = this.encodeTableSeq[SEQ_START-bucket[low]]; + } + else { + // There was no sequence object - allocate a new one. + node = {}; + if (bucket[low] !== UNASSIGNED) node[DEF_CHAR] = bucket[low]; // If a char was set before - make it a single-char subsequence. + bucket[low] = SEQ_START - this.encodeTableSeq.length; + this.encodeTableSeq.push(node); + } + + // Traverse the character tree, allocating new nodes as needed. + for (var j = 1; j < seq.length-1; j++) { + var oldVal = node[uCode]; + if (typeof oldVal === 'object') + node = oldVal; + else { + node = node[uCode] = {} + if (oldVal !== undefined) + node[DEF_CHAR] = oldVal + } + } + + // Set the leaf to given dbcsCode. + uCode = seq[seq.length-1]; + node[uCode] = dbcsCode; +} + +DBCSCodec.prototype._fillEncodeTable = function(nodeIdx, prefix, skipEncodeChars) { + var node = this.decodeTables[nodeIdx]; + for (var i = 0; i < 0x100; i++) { + var uCode = node[i]; + var mbCode = prefix + i; + if (skipEncodeChars[mbCode]) + continue; + + if (uCode >= 0) + this._setEncodeChar(uCode, mbCode); + else if (uCode <= NODE_START) + this._fillEncodeTable(NODE_START - uCode, mbCode << 8, skipEncodeChars); + else if (uCode <= SEQ_START) + this._setEncodeSequence(this.decodeTableSeq[SEQ_START - uCode], mbCode); + } +} + + + +// == Actual Encoding ========================================================== + + +function encoderDBCSWrite(str) { + var newBuf = new Buffer(str.length * (this.gb18030 ? 4 : 3)), + leadSurrogate = this.leadSurrogate, + seqObj = this.seqObj, nextChar = -1, + i = 0, j = 0; + + while (true) { + // 0. Get next character. + if (nextChar === -1) { + if (i == str.length) break; + var uCode = str.charCodeAt(i++); + } + else { + var uCode = nextChar; + nextChar = -1; + } + + // 1. Handle surrogates. + if (0xD800 <= uCode && uCode < 0xE000) { // Char is one of surrogates. + if (uCode < 0xDC00) { // We've got lead surrogate. + if (leadSurrogate === -1) { + leadSurrogate = uCode; + continue; + } else { + leadSurrogate = uCode; + // Double lead surrogate found. + uCode = UNASSIGNED; + } + } else { // We've got trail surrogate. + if (leadSurrogate !== -1) { + uCode = 0x10000 + (leadSurrogate - 0xD800) * 0x400 + (uCode - 0xDC00); + leadSurrogate = -1; + } else { + // Incomplete surrogate pair - only trail surrogate found. + uCode = UNASSIGNED; + } + + } + } + else if (leadSurrogate !== -1) { + // Incomplete surrogate pair - only lead surrogate found. + nextChar = uCode; uCode = UNASSIGNED; // Write an error, then current char. + leadSurrogate = -1; + } + + // 2. Convert uCode character. + var dbcsCode = UNASSIGNED; + if (seqObj !== undefined && uCode != UNASSIGNED) { // We are in the middle of the sequence + var resCode = seqObj[uCode]; + if (typeof resCode === 'object') { // Sequence continues. + seqObj = resCode; + continue; + + } else if (typeof resCode == 'number') { // Sequence finished. Write it. + dbcsCode = resCode; + + } else if (resCode == undefined) { // Current character is not part of the sequence. + + // Try default character for this sequence + resCode = seqObj[DEF_CHAR]; + if (resCode !== undefined) { + dbcsCode = resCode; // Found. Write it. + nextChar = uCode; // Current character will be written too in the next iteration. + + } else { + // TODO: What if we have no default? (resCode == undefined) + // Then, we should write first char of the sequence as-is and try the rest recursively. + // Didn't do it for now because no encoding has this situation yet. + // Currently, just skip the sequence and write current char. + } + } + seqObj = undefined; + } + else if (uCode >= 0) { // Regular character + var subtable = this.encodeTable[uCode >> 8]; + if (subtable !== undefined) + dbcsCode = subtable[uCode & 0xFF]; + + if (dbcsCode <= SEQ_START) { // Sequence start + seqObj = this.encodeTableSeq[SEQ_START-dbcsCode]; + continue; + } + + if (dbcsCode == UNASSIGNED && this.gb18030) { + // Use GB18030 algorithm to find character(s) to write. + var idx = findIdx(this.gb18030.uChars, uCode); + if (idx != -1) { + var dbcsCode = this.gb18030.gbChars[idx] + (uCode - this.gb18030.uChars[idx]); + newBuf[j++] = 0x81 + Math.floor(dbcsCode / 12600); dbcsCode = dbcsCode % 12600; + newBuf[j++] = 0x30 + Math.floor(dbcsCode / 1260); dbcsCode = dbcsCode % 1260; + newBuf[j++] = 0x81 + Math.floor(dbcsCode / 10); dbcsCode = dbcsCode % 10; + newBuf[j++] = 0x30 + dbcsCode; + continue; + } + } + } + + // 3. Write dbcsCode character. + if (dbcsCode === UNASSIGNED) + dbcsCode = this.defaultCharSingleByte; + + if (dbcsCode < 0x100) { + newBuf[j++] = dbcsCode; + } + else if (dbcsCode < 0x10000) { + newBuf[j++] = dbcsCode >> 8; // high byte + newBuf[j++] = dbcsCode & 0xFF; // low byte + } + else { + newBuf[j++] = dbcsCode >> 16; + newBuf[j++] = (dbcsCode >> 8) & 0xFF; + newBuf[j++] = dbcsCode & 0xFF; + } + } + + this.seqObj = seqObj; + this.leadSurrogate = leadSurrogate; + return newBuf.slice(0, j); +} + +function encoderDBCSEnd() { + if (this.leadSurrogate === -1 && this.seqObj === undefined) + return; // All clean. Most often case. + + var newBuf = new Buffer(10), j = 0; + + if (this.seqObj) { // We're in the sequence. + var dbcsCode = this.seqObj[DEF_CHAR]; + if (dbcsCode !== undefined) { // Write beginning of the sequence. + if (dbcsCode < 0x100) { + newBuf[j++] = dbcsCode; + } + else { + newBuf[j++] = dbcsCode >> 8; // high byte + newBuf[j++] = dbcsCode & 0xFF; // low byte + } + } else { + // See todo above. + } + this.seqObj = undefined; + } + + if (this.leadSurrogate !== -1) { + // Incomplete surrogate pair - only lead surrogate found. + newBuf[j++] = this.defaultCharSingleByte; + this.leadSurrogate = -1; + } + + return newBuf.slice(0, j); +} + + +// == Actual Decoding ========================================================== + + +function decoderDBCSWrite(buf) { + var newBuf = new Buffer(buf.length*2), + nodeIdx = this.nodeIdx, + prevBuf = this.prevBuf, prevBufOffset = this.prevBuf.length, + seqStart = -this.prevBuf.length, // idx of the start of current parsed sequence. + uCode; + + if (prevBufOffset > 0) // Make prev buf overlap a little to make it easier to slice later. + prevBuf = Buffer.concat([prevBuf, buf.slice(0, 10)]); + + for (var i = 0, j = 0; i < buf.length; i++) { + var curByte = (i >= 0) ? buf[i] : prevBuf[i + prevBufOffset]; + + // Lookup in current trie node. + var uCode = this.decodeTables[nodeIdx][curByte]; + + if (uCode >= 0) { + // Normal character, just use it. + } + else if (uCode === UNASSIGNED) { // Unknown char. + // TODO: Callback with seq. + //var curSeq = (seqStart >= 0) ? buf.slice(seqStart, i+1) : prevBuf.slice(seqStart + prevBufOffset, i+1 + prevBufOffset); + i = seqStart; // Try to parse again, after skipping first byte of the sequence ('i' will be incremented by 'for' cycle). + uCode = this.defaultCharUnicode.charCodeAt(0); + } + else if (uCode === GB18030_CODE) { + var curSeq = (seqStart >= 0) ? buf.slice(seqStart, i+1) : prevBuf.slice(seqStart + prevBufOffset, i+1 + prevBufOffset); + var ptr = (curSeq[0]-0x81)*12600 + (curSeq[1]-0x30)*1260 + (curSeq[2]-0x81)*10 + (curSeq[3]-0x30); + var idx = findIdx(this.gb18030.gbChars, ptr); + uCode = this.gb18030.uChars[idx] + ptr - this.gb18030.gbChars[idx]; + } + else if (uCode <= NODE_START) { // Go to next trie node. + nodeIdx = NODE_START - uCode; + continue; + } + else if (uCode <= SEQ_START) { // Output a sequence of chars. + var seq = this.decodeTableSeq[SEQ_START - uCode]; + for (var k = 0; k < seq.length - 1; k++) { + uCode = seq[k]; + newBuf[j++] = uCode & 0xFF; + newBuf[j++] = uCode >> 8; + } + uCode = seq[seq.length-1]; + } + else + throw new Error("Unknown table value when decoding: " + val); + + // Write the character to buffer, handling higher planes using surrogate pair. + if (uCode > 0xFFFF) { + uCode -= 0x10000; + var uCodeLead = 0xD800 + Math.floor(uCode / 0x400); + newBuf[j++] = uCodeLead & 0xFF; + newBuf[j++] = uCodeLead >> 8; + + uCode = 0xDC00 + uCode % 0x400; + } + newBuf[j++] = uCode & 0xFF; + newBuf[j++] = uCode >> 8; + + // Reset trie node. + nodeIdx = 0; seqStart = i+1; + } + + this.nodeIdx = nodeIdx; + this.prevBuf = (seqStart >= 0) ? buf.slice(seqStart) : prevBuf.slice(seqStart + prevBufOffset); + return newBuf.slice(0, j).toString('ucs2'); +} + +function decoderDBCSEnd() { + var ret = ''; + + // Try to parse all remaining chars. + while (this.prevBuf.length > 0) { + // Skip 1 character in the buffer. + ret += this.defaultCharUnicode; + var buf = this.prevBuf.slice(1); + + // Parse remaining as usual. + this.prevBuf = new Buffer(0); + this.nodeIdx = 0; + if (buf.length > 0) + ret += decoderDBCSWrite.call(this, buf); + } + + this.nodeIdx = 0; + return ret; +} + +// Binary search for GB18030. Returns largest i such that table[i] <= val. +function findIdx(table, val) { + if (table[0] > val) + return -1; + + var l = 0, r = table.length; + while (l < r-1) { // always table[l] <= val < table[r] + var mid = l + Math.floor((r-l+1)/2); + if (table[mid] <= val) + l = mid; + else + r = mid; + } + return l; +} + diff --git a/node_modules/body-parser/node_modules/iconv-lite/encodings/dbcs-data.js b/node_modules/body-parser/node_modules/iconv-lite/encodings/dbcs-data.js new file mode 100644 index 0000000..44be66c --- /dev/null +++ b/node_modules/body-parser/node_modules/iconv-lite/encodings/dbcs-data.js @@ -0,0 +1,168 @@ + +// Description of supported double byte encodings and aliases. +// Tables are not require()-d until they are needed to speed up library load. +// require()-s are direct to support Browserify. + +module.exports = { + + // == Japanese/ShiftJIS ==================================================== + // All japanese encodings are based on JIS X set of standards: + // JIS X 0201 - Single-byte encoding of ASCII + ¥ + Kana chars at 0xA1-0xDF. + // JIS X 0208 - Main set of 6879 characters, placed in 94x94 plane, to be encoded by 2 bytes. + // Has several variations in 1978, 1983, 1990 and 1997. + // JIS X 0212 - Supplementary plane of 6067 chars in 94x94 plane. 1990. Effectively dead. + // JIS X 0213 - Extension and modern replacement of 0208 and 0212. Total chars: 11233. + // 2 planes, first is superset of 0208, second - revised 0212. + // Introduced in 2000, revised 2004. Some characters are in Unicode Plane 2 (0x2xxxx) + + // Byte encodings are: + // * Shift_JIS: Compatible with 0201, uses not defined chars in top half as lead bytes for double-byte + // encoding of 0208. Lead byte ranges: 0x81-0x9F, 0xE0-0xEF; Trail byte ranges: 0x40-0x7E, 0x80-0x9E, 0x9F-0xFC. + // Windows CP932 is a superset of Shift_JIS. Some companies added more chars, notably KDDI. + // * EUC-JP: Up to 3 bytes per character. Used mostly on *nixes. + // 0x00-0x7F - lower part of 0201 + // 0x8E, 0xA1-0xDF - upper part of 0201 + // (0xA1-0xFE)x2 - 0208 plane (94x94). + // 0x8F, (0xA1-0xFE)x2 - 0212 plane (94x94). + // * JIS X 208: 7-bit, direct encoding of 0208. Byte ranges: 0x21-0x7E (94 values). Uncommon. + // Used as-is in ISO2022 family. + // * ISO2022-JP: Stateful encoding, with escape sequences to switch between ASCII, + // 0201-1976 Roman, 0208-1978, 0208-1983. + // * ISO2022-JP-1: Adds esc seq for 0212-1990. + // * ISO2022-JP-2: Adds esc seq for GB2313-1980, KSX1001-1992, ISO8859-1, ISO8859-7. + // * ISO2022-JP-3: Adds esc seq for 0201-1976 Kana set, 0213-2000 Planes 1, 2. + // * ISO2022-JP-2004: Adds 0213-2004 Plane 1. + // + // After JIS X 0213 appeared, Shift_JIS-2004, EUC-JISX0213 and ISO2022-JP-2004 followed, with just changing the planes. + // + // Overall, it seems that it's a mess :( http://www8.plala.or.jp/tkubota1/unicode-symbols-map2.html + + + 'shiftjis': { + type: '_dbcs', + table: function() { return require('./tables/shiftjis.json') }, + encodeAdd: {'\u00a5': 0x5C, '\u203E': 0x7E}, + encodeSkipVals: [{from: 0xED40, to: 0xF940}], + }, + 'csshiftjis': 'shiftjis', + 'mskanji': 'shiftjis', + 'sjis': 'shiftjis', + 'windows-31j': 'shiftjis', + 'x-sjis': 'shiftjis', + 'windows932': 'shiftjis', + '932': 'shiftjis', + 'cp932': 'shiftjis', + + 'eucjp': { + type: '_dbcs', + table: function() { return require('./tables/eucjp.json') }, + encodeAdd: {'\u00a5': 0x5C, '\u203E': 0x7E}, + }, + + // TODO: KDDI extension to Shift_JIS + // TODO: IBM CCSID 942 = CP932, but F0-F9 custom chars and other char changes. + // TODO: IBM CCSID 943 = Shift_JIS = CP932 with original Shift_JIS lower 128 chars. + + // == Chinese/GBK ========================================================== + // http://en.wikipedia.org/wiki/GBK + + // Oldest GB2312 (1981, ~7600 chars) is a subset of CP936 + 'gb2312': 'cp936', + 'gb231280': 'cp936', + 'gb23121980': 'cp936', + 'csgb2312': 'cp936', + 'csiso58gb231280': 'cp936', + 'euccn': 'cp936', + 'isoir58': 'gbk', + + // Microsoft's CP936 is a subset and approximation of GBK. + // TODO: Euro = 0x80 in cp936, but not in GBK (where it's valid but undefined) + 'windows936': 'cp936', + '936': 'cp936', + 'cp936': { + type: '_dbcs', + table: function() { return require('./tables/cp936.json') }, + }, + + // GBK (~22000 chars) is an extension of CP936 that added user-mapped chars and some other. + 'gbk': { + type: '_dbcs', + table: function() { return require('./tables/cp936.json').concat(require('./tables/gbk-added.json')) }, + }, + 'xgbk': 'gbk', + + // GB18030 is an algorithmic extension of GBK. + 'gb18030': { + type: '_dbcs', + table: function() { return require('./tables/cp936.json').concat(require('./tables/gbk-added.json')) }, + gb18030: function() { return require('./tables/gb18030-ranges.json') }, + }, + + 'chinese': 'gb18030', + + // TODO: Support GB18030 (~27000 chars + whole unicode mapping, cp54936) + // http://icu-project.org/docs/papers/gb18030.html + // http://source.icu-project.org/repos/icu/data/trunk/charset/data/xml/gb-18030-2000.xml + // http://www.khngai.com/chinese/charmap/tblgbk.php?page=0 + + // == Korean =============================================================== + // EUC-KR, KS_C_5601 and KS X 1001 are exactly the same. + 'windows949': 'cp949', + '949': 'cp949', + 'cp949': { + type: '_dbcs', + table: function() { return require('./tables/cp949.json') }, + }, + + 'cseuckr': 'cp949', + 'csksc56011987': 'cp949', + 'euckr': 'cp949', + 'isoir149': 'cp949', + 'korean': 'cp949', + 'ksc56011987': 'cp949', + 'ksc56011989': 'cp949', + 'ksc5601': 'cp949', + + + // == Big5/Taiwan/Hong Kong ================================================ + // There are lots of tables for Big5 and cp950. Please see the following links for history: + // http://moztw.org/docs/big5/ http://www.haible.de/bruno/charsets/conversion-tables/Big5.html + // Variations, in roughly number of defined chars: + // * Windows CP 950: Microsoft variant of Big5. Canonical: http://www.unicode.org/Public/MAPPINGS/VENDORS/MICSFT/WINDOWS/CP950.TXT + // * Windows CP 951: Microsoft variant of Big5-HKSCS-2001. Seems to be never public. http://me.abelcheung.org/articles/research/what-is-cp951/ + // * Big5-2003 (Taiwan standard) almost superset of cp950. + // * Unicode-at-on (UAO) / Mozilla 1.8. Falling out of use on the Web. Not supported by other browsers. + // * Big5-HKSCS (-2001, -2004, -2008). Hong Kong standard. + // many unicode code points moved from PUA to Supplementary plane (U+2XXXX) over the years. + // Plus, it has 4 combining sequences. + // Seems that Mozilla refused to support it for 10 yrs. https://bugzilla.mozilla.org/show_bug.cgi?id=162431 https://bugzilla.mozilla.org/show_bug.cgi?id=310299 + // because big5-hkscs is the only encoding to include astral characters in non-algorithmic way. + // Implementations are not consistent within browsers; sometimes labeled as just big5. + // MS Internet Explorer switches from big5 to big5-hkscs when a patch applied. + // Great discussion & recap of what's going on https://bugzilla.mozilla.org/show_bug.cgi?id=912470#c31 + // In the encoder, it might make sense to support encoding old PUA mappings to Big5 bytes seq-s. + // Official spec: http://www.ogcio.gov.hk/en/business/tech_promotion/ccli/terms/doc/2003cmp_2008.txt + // http://www.ogcio.gov.hk/tc/business/tech_promotion/ccli/terms/doc/hkscs-2008-big5-iso.txt + // + // Current understanding of how to deal with Big5(-HKSCS) is in the Encoding Standard, http://encoding.spec.whatwg.org/#big5-encoder + // Unicode mapping (http://www.unicode.org/Public/MAPPINGS/OBSOLETE/EASTASIA/OTHER/BIG5.TXT) is said to be wrong. + + 'windows950': 'cp950', + '950': 'cp950', + 'cp950': { + type: '_dbcs', + table: function() { return require('./tables/cp950.json') }, + }, + + // Big5 has many variations and is an extension of cp950. We use Encoding Standard's as a consensus. + 'big5': 'big5hkscs', + 'big5hkscs': { + type: '_dbcs', + table: function() { return require('./tables/cp950.json').concat(require('./tables/big5-added.json')) }, + }, + + 'cnbig5': 'big5hkscs', + 'csbig5': 'big5hkscs', + 'xxbig5': 'big5hkscs', + +}; \ No newline at end of file diff --git a/node_modules/body-parser/node_modules/iconv-lite/encodings/index.js b/node_modules/body-parser/node_modules/iconv-lite/encodings/index.js new file mode 100644 index 0000000..2cda918 --- /dev/null +++ b/node_modules/body-parser/node_modules/iconv-lite/encodings/index.js @@ -0,0 +1,20 @@ + +// Update this array if you add/rename/remove files in this directory. +// We support Browserify by skipping automatic module discovery and requiring modules directly. +var modules = [ + require("./internal"), + require("./utf16"), + require("./utf7"), + require("./sbcs-codec"), + require("./sbcs-data"), + require("./sbcs-data-generated"), + require("./dbcs-codec"), + require("./dbcs-data"), +]; + +// Put all encoding/alias/codec definitions to single object and export it. +for (var i = 0; i < modules.length; i++) { + var module = modules[i]; + for (var enc in module) + exports[enc] = module[enc]; +} diff --git a/node_modules/body-parser/node_modules/iconv-lite/encodings/internal.js b/node_modules/body-parser/node_modules/iconv-lite/encodings/internal.js new file mode 100644 index 0000000..396f580 --- /dev/null +++ b/node_modules/body-parser/node_modules/iconv-lite/encodings/internal.js @@ -0,0 +1,81 @@ + +// Export Node.js internal encodings. + +var utf16lebom = new Buffer([0xFF, 0xFE]); + +module.exports = { + // Encodings + utf8: { type: "_internal", enc: "utf8" }, + cesu8: { type: "_internal", enc: "utf8" }, + unicode11utf8: { type: "_internal", enc: "utf8" }, + ucs2: { type: "_internal", enc: "ucs2", bom: utf16lebom }, + utf16le:{ type: "_internal", enc: "ucs2", bom: utf16lebom }, + binary: { type: "_internal", enc: "binary" }, + base64: { type: "_internal", enc: "base64" }, + hex: { type: "_internal", enc: "hex" }, + + // Codec. + _internal: function(options) { + if (!options || !options.enc) + throw new Error("Internal codec is called without encoding type.") + + return { + encoder: options.enc == "base64" ? encoderBase64 : encoderInternal, + decoder: decoderInternal, + + enc: options.enc, + bom: options.bom, + }; + }, +}; + +// We use node.js internal decoder. It's signature is the same as ours. +var StringDecoder = require('string_decoder').StringDecoder; + +if (!StringDecoder.prototype.end) // Node v0.8 doesn't have this method. + StringDecoder.prototype.end = function() {}; + +function decoderInternal() { + return new StringDecoder(this.enc); +} + +// Encoder is mostly trivial + +function encoderInternal() { + return { + write: encodeInternal, + end: function() {}, + + enc: this.enc, + } +} + +function encodeInternal(str) { + return new Buffer(str, this.enc); +} + + +// Except base64 encoder, which must keep its state. + +function encoderBase64() { + return { + write: encodeBase64Write, + end: encodeBase64End, + + prevStr: '', + }; +} + +function encodeBase64Write(str) { + str = this.prevStr + str; + var completeQuads = str.length - (str.length % 4); + this.prevStr = str.slice(completeQuads); + str = str.slice(0, completeQuads); + + return new Buffer(str, "base64"); +} + +function encodeBase64End() { + return new Buffer(this.prevStr, "base64"); +} + diff --git a/node_modules/body-parser/node_modules/iconv-lite/encodings/sbcs-codec.js b/node_modules/body-parser/node_modules/iconv-lite/encodings/sbcs-codec.js new file mode 100644 index 0000000..c79defb --- /dev/null +++ b/node_modules/body-parser/node_modules/iconv-lite/encodings/sbcs-codec.js @@ -0,0 +1,76 @@ + +// Single-byte codec. Needs a 'chars' string parameter that contains 256 or 128 chars that +// correspond to encoded bytes (if 128 - then lower half is ASCII). + +exports._sbcs = function(options) { + if (!options) + throw new Error("SBCS codec is called without the data.") + + // Prepare char buffer for decoding. + if (!options.chars || (options.chars.length !== 128 && options.chars.length !== 256)) + throw new Error("Encoding '"+options.type+"' has incorrect 'chars' (must be of len 128 or 256)"); + + if (options.chars.length === 128) { + var asciiString = ""; + for (var i = 0; i < 128; i++) + asciiString += String.fromCharCode(i); + options.chars = asciiString + options.chars; + } + + var decodeBuf = new Buffer(options.chars, 'ucs2'); + + // Encoding buffer. + var encodeBuf = new Buffer(65536); + encodeBuf.fill(options.iconv.defaultCharSingleByte.charCodeAt(0)); + + for (var i = 0; i < options.chars.length; i++) + encodeBuf[options.chars.charCodeAt(i)] = i; + + return { + encoder: encoderSBCS, + decoder: decoderSBCS, + + encodeBuf: encodeBuf, + decodeBuf: decodeBuf, + }; +} + +function encoderSBCS(options) { + return { + write: encoderSBCSWrite, + end: function() {}, + + encodeBuf: this.encodeBuf, + }; +} + +function encoderSBCSWrite(str) { + var buf = new Buffer(str.length); + for (var i = 0; i < str.length; i++) + buf[i] = this.encodeBuf[str.charCodeAt(i)]; + + return buf; +} + + +function decoderSBCS(options) { + return { + write: decoderSBCSWrite, + end: function() {}, + + decodeBuf: this.decodeBuf, + }; +} + +function decoderSBCSWrite(buf) { + // Strings are immutable in JS -> we use ucs2 buffer to speed up computations. + var decodeBuf = this.decodeBuf; + var newBuf = new Buffer(buf.length*2); + var idx1 = 0, idx2 = 0; + for (var i = 0, _len = buf.length; i < _len; i++) { + idx1 = buf[i]*2; idx2 = i*2; + newBuf[idx2] = decodeBuf[idx1]; + newBuf[idx2+1] = decodeBuf[idx1+1]; + } + return newBuf.toString('ucs2'); +} diff --git a/node_modules/body-parser/node_modules/iconv-lite/encodings/sbcs-data-generated.js b/node_modules/body-parser/node_modules/iconv-lite/encodings/sbcs-data-generated.js new file mode 100644 index 0000000..3808260 --- /dev/null +++ b/node_modules/body-parser/node_modules/iconv-lite/encodings/sbcs-data-generated.js @@ -0,0 +1,450 @@ + +// Generated data for sbcs codec. Don't edit manually. Regenerate using generation/gen-sbcs.js script. +module.exports = { + "437": "cp437", + "737": "cp737", + "775": "cp775", + "850": "cp850", + "852": "cp852", + "855": "cp855", + "856": "cp856", + "857": "cp857", + "858": "cp858", + "860": "cp860", + "861": "cp861", + "862": "cp862", + "863": "cp863", + "864": "cp864", + "865": "cp865", + "866": "cp866", + "869": "cp869", + "874": "windows874", + "922": "cp922", + "1046": "cp1046", + "1124": "cp1124", + "1125": "cp1125", + "1129": "cp1129", + "1133": "cp1133", + "1161": "cp1161", + "1162": "cp1162", + "1163": "cp1163", + "1250": "windows1250", + "1251": "windows1251", + "1252": "windows1252", + "1253": "windows1253", + "1254": "windows1254", + "1255": "windows1255", + "1256": "windows1256", + "1257": "windows1257", + "1258": "windows1258", + "28591": "iso88591", + "28592": "iso88592", + "28593": "iso88593", + "28594": "iso88594", + "28595": "iso88595", + "28596": "iso88596", + "28597": "iso88597", + "28598": "iso88598", + "28599": "iso88599", + "28600": "iso885910", + "28601": "iso885911", + "28603": "iso885913", + "28604": "iso885914", + "28605": "iso885915", + "28606": "iso885916", + "windows874": { + "type": "_sbcs", + "chars": "€����…�����������‘’“”•–—�������� กขฃคฅฆงจฉชซฌญฎฏฐฑฒณดตถทธนบปผฝพฟภมยรฤลฦวศษสหฬอฮฯะัาำิีึืฺุู����฿เแโใไๅๆ็่้๊๋์ํ๎๏๐๑๒๓๔๕๖๗๘๙๚๛����" + }, + "win874": "windows874", + "cp874": "windows874", + "windows1250": { + "type": "_sbcs", + "chars": "€�‚�„…†‡�‰Š‹ŚŤŽŹ�‘’“”•–—�™š›śťžź ˇ˘Ł¤Ą¦§¨©Ş«¬­®Ż°±˛ł´µ¶·¸ąş»Ľ˝ľżŔÁÂĂÄĹĆÇČÉĘËĚÍÎĎĐŃŇÓÔŐÖ×ŘŮÚŰÜÝŢßŕáâăäĺćçčéęëěíîďđńňóôőö÷řůúűüýţ˙" + }, + "win1250": "windows1250", + "cp1250": "windows1250", + "windows1251": { + "type": "_sbcs", + "chars": "ЂЃ‚ѓ„…†‡€‰Љ‹ЊЌЋЏђ‘’“”•–—�™љ›њќћџ ЎўЈ¤Ґ¦§Ё©Є«¬­®Ї°±Ііґµ¶·ё№є»јЅѕїАБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмнопрстуфхцчшщъыьэюя" + }, + "win1251": "windows1251", + "cp1251": "windows1251", + "windows1252": { + "type": "_sbcs", + "chars": "€�‚ƒ„…†‡ˆ‰Š‹Œ�Ž��‘’“”•–—˜™š›œ�žŸ ¡¢£¤¥¦§¨©ª«¬­®¯°±²³´µ¶·¸¹º»¼½¾¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖ×ØÙÚÛÜÝÞßàáâãäåæçèéêëìíîïðñòóôõö÷øùúûüýþÿ" + }, + "win1252": "windows1252", + "cp1252": "windows1252", + "windows1253": { + "type": "_sbcs", + "chars": "€�‚ƒ„…†‡�‰�‹�����‘’“”•–—�™�›���� ΅Ά£¤¥¦§¨©�«¬­®―°±²³΄µ¶·ΈΉΊ»Ό½ΎΏΐΑΒΓΔΕΖΗΘΙΚΛΜΝΞΟΠΡ�ΣΤΥΦΧΨΩΪΫάέήίΰαβγδεζηθικλμνξοπρςστυφχψωϊϋόύώ�" + }, + "win1253": "windows1253", + "cp1253": "windows1253", + "windows1254": { + "type": "_sbcs", + "chars": "€�‚ƒ„…†‡ˆ‰Š‹Œ����‘’“”•–—˜™š›œ��Ÿ ¡¢£¤¥¦§¨©ª«¬­®¯°±²³´µ¶·¸¹º»¼½¾¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏĞÑÒÓÔÕÖ×ØÙÚÛÜİŞßàáâãäåæçèéêëìíîïğñòóôõö÷øùúûüışÿ" + }, + "win1254": "windows1254", + "cp1254": "windows1254", + "windows1255": { + "type": "_sbcs", + "chars": "€�‚ƒ„…†‡ˆ‰�‹�����‘’“”•–—˜™�›���� ¡¢£₪¥¦§¨©×«¬­®¯°±²³´µ¶·¸¹÷»¼½¾¿ְֱֲֳִֵֶַָֹ�ֻּֽ־ֿ׀ׁׂ׃װױײ׳״�������אבגדהוזחטיךכלםמןנסעףפץצקרשת��‎‏�" + }, + "win1255": "windows1255", + "cp1255": "windows1255", + "windows1256": { + "type": "_sbcs", + "chars": "€پ‚ƒ„…†‡ˆ‰ٹ‹Œچژڈگ‘’“”•–—ک™ڑ›œ‌‍ں ،¢£¤¥¦§¨©ھ«¬­®¯°±²³´µ¶·¸¹؛»¼½¾؟ہءآأؤإئابةتثجحخدذرزسشصض×طظعغـفقكàلâمنهوçèéêëىيîïًٌٍَôُِ÷ّùْûü‎‏ے" + }, + "win1256": "windows1256", + "cp1256": "windows1256", + "windows1257": { + "type": "_sbcs", + "chars": "€�‚�„…†‡�‰�‹�¨ˇ¸�‘’“”•–—�™�›�¯˛� �¢£¤�¦§Ø©Ŗ«¬­®Æ°±²³´µ¶·ø¹ŗ»¼½¾æĄĮĀĆÄÅĘĒČÉŹĖĢĶĪĻŠŃŅÓŌÕÖ×ŲŁŚŪÜŻŽßąįāćäåęēčéźėģķīļšńņóōõö÷ųłśūüżž˙" + }, + "win1257": "windows1257", + "cp1257": "windows1257", + "windows1258": { + "type": "_sbcs", + "chars": "€�‚ƒ„…†‡ˆ‰�‹Œ����‘’“”•–—˜™�›œ��Ÿ ¡¢£¤¥¦§¨©ª«¬­®¯°±²³´µ¶·¸¹º»¼½¾¿ÀÁÂĂÄÅÆÇÈÉÊË̀ÍÎÏĐÑ̉ÓÔƠÖ×ØÙÚÛÜỮßàáâăäåæçèéêë́íîïđṇ̃óôơö÷øùúûüư₫ÿ" + }, + "win1258": "windows1258", + "cp1258": "windows1258", + "iso88591": { + "type": "_sbcs", + "chars": "€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ ¡¢£¤¥¦§¨©ª«¬­®¯°±²³´µ¶·¸¹º»¼½¾¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖ×ØÙÚÛÜÝÞßàáâãäåæçèéêëìíîïðñòóôõö÷øùúûüýþÿ" + }, + "cp28591": "iso88591", + "iso88592": { + "type": "_sbcs", + "chars": "€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ Ą˘Ł¤ĽŚ§¨ŠŞŤŹ­ŽŻ°ą˛ł´ľśˇ¸šşťź˝žżŔÁÂĂÄĹĆÇČÉĘËĚÍÎĎĐŃŇÓÔŐÖ×ŘŮÚŰÜÝŢßŕáâăäĺćçčéęëěíîďđńňóôőö÷řůúűüýţ˙" + }, + "cp28592": "iso88592", + "iso88593": { + "type": "_sbcs", + "chars": "€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ Ħ˘£¤�Ĥ§¨İŞĞĴ­�Ż°ħ²³´µĥ·¸ışğĵ½�żÀÁÂ�ÄĊĈÇÈÉÊËÌÍÎÏ�ÑÒÓÔĠÖ×ĜÙÚÛÜŬŜßàáâ�äċĉçèéêëìíîï�ñòóôġö÷ĝùúûüŭŝ˙" + }, + "cp28593": "iso88593", + "iso88594": { + "type": "_sbcs", + "chars": "€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ ĄĸŖ¤ĨĻ§¨ŠĒĢŦ­Ž¯°ą˛ŗ´ĩļˇ¸šēģŧŊžŋĀÁÂÃÄÅÆĮČÉĘËĖÍÎĪĐŅŌĶÔÕÖ×ØŲÚÛÜŨŪßāáâãäåæįčéęëėíîīđņōķôõö÷øųúûüũū˙" + }, + "cp28594": "iso88594", + "iso88595": { + "type": "_sbcs", + "chars": "€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ ЁЂЃЄЅІЇЈЉЊЋЌ­ЎЏАБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмнопрстуфхцчшщъыьэюя№ёђѓєѕіїјљњћќ§ўџ" + }, + "cp28595": "iso88595", + "iso88596": { + "type": "_sbcs", + "chars": "€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ ���¤�������،­�������������؛���؟�ءآأؤإئابةتثجحخدذرزسشصضطظعغ�����ـفقكلمنهوىيًٌٍَُِّْ�������������" + }, + "cp28596": "iso88596", + "iso88597": { + "type": "_sbcs", + "chars": "€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ ‘’£€₯¦§¨©ͺ«¬­�―°±²³΄΅Ά·ΈΉΊ»Ό½ΎΏΐΑΒΓΔΕΖΗΘΙΚΛΜΝΞΟΠΡ�ΣΤΥΦΧΨΩΪΫάέήίΰαβγδεζηθικλμνξοπρςστυφχψωϊϋόύώ�" + }, + "cp28597": "iso88597", + "iso88598": { + "type": "_sbcs", + "chars": "€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ �¢£¤¥¦§¨©×«¬­®¯°±²³´µ¶·¸¹÷»¼½¾��������������������������������‗אבגדהוזחטיךכלםמןנסעףפץצקרשת��‎‏�" + }, + "cp28598": "iso88598", + "iso88599": { + "type": "_sbcs", + "chars": "€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ ¡¢£¤¥¦§¨©ª«¬­®¯°±²³´µ¶·¸¹º»¼½¾¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏĞÑÒÓÔÕÖ×ØÙÚÛÜİŞßàáâãäåæçèéêëìíîïğñòóôõö÷øùúûüışÿ" + }, + "cp28599": "iso88599", + "iso885910": { + "type": "_sbcs", + "chars": "€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ ĄĒĢĪĨĶ§ĻĐŠŦŽ­ŪŊ°ąēģīĩķ·ļđšŧž―ūŋĀÁÂÃÄÅÆĮČÉĘËĖÍÎÏÐŅŌÓÔÕÖŨØŲÚÛÜÝÞßāáâãäåæįčéęëėíîïðņōóôõöũøųúûüýþĸ" + }, + "cp28600": "iso885910", + "iso885911": { + "type": "_sbcs", + "chars": "€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ กขฃคฅฆงจฉชซฌญฎฏฐฑฒณดตถทธนบปผฝพฟภมยรฤลฦวศษสหฬอฮฯะัาำิีึืฺุู����฿เแโใไๅๆ็่้๊๋์ํ๎๏๐๑๒๓๔๕๖๗๘๙๚๛����" + }, + "cp28601": "iso885911", + "iso885913": { + "type": "_sbcs", + "chars": "€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ ”¢£¤„¦§Ø©Ŗ«¬­®Æ°±²³“µ¶·ø¹ŗ»¼½¾æĄĮĀĆÄÅĘĒČÉŹĖĢĶĪĻŠŃŅÓŌÕÖ×ŲŁŚŪÜŻŽßąįāćäåęēčéźėģķīļšńņóōõö÷ųłśūüżž’" + }, + "cp28603": "iso885913", + "iso885914": { + "type": "_sbcs", + "chars": "€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ Ḃḃ£ĊċḊ§Ẁ©ẂḋỲ­®ŸḞḟĠġṀṁ¶ṖẁṗẃṠỳẄẅṡÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏŴÑÒÓÔÕÖṪØÙÚÛÜÝŶßàáâãäåæçèéêëìíîïŵñòóôõöṫøùúûüýŷÿ" + }, + "cp28604": "iso885914", + "iso885915": { + "type": "_sbcs", + "chars": "€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ ¡¢£€¥Š§š©ª«¬­®¯°±²³Žµ¶·ž¹º»ŒœŸ¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖ×ØÙÚÛÜÝÞßàáâãäåæçèéêëìíîïðñòóôõö÷øùúûüýþÿ" + }, + "cp28605": "iso885915", + "iso885916": { + "type": "_sbcs", + "chars": "€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ ĄąŁ€„Š§š©Ș«Ź­źŻ°±ČłŽ”¶·žčș»ŒœŸżÀÁÂĂÄĆÆÇÈÉÊËÌÍÎÏĐŃÒÓÔŐÖŚŰÙÚÛÜĘȚßàáâăäćæçèéêëìíîïđńòóôőöśűùúûüęțÿ" + }, + "cp28606": "iso885916", + "cp437": { + "type": "_sbcs", + "chars": "ÇüéâäàåçêëèïîìÄÅÉæÆôöòûùÿÖÜ¢£¥₧ƒáíóúñѪº¿⌐¬½¼¡«»░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀αßΓπΣσµτΦΘΩδ∞φε∩≡±≥≤⌠⌡÷≈°∙·√ⁿ²■ " + }, + "ibm437": "cp437", + "csibm437": "cp437", + "cp737": { + "type": "_sbcs", + "chars": "ΑΒΓΔΕΖΗΘΙΚΛΜΝΞΟΠΡΣΤΥΦΧΨΩαβγδεζηθικλμνξοπρσςτυφχψ░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀ωάέήϊίόύϋώΆΈΉΊΌΎΏ±≥≤ΪΫ÷≈°∙·√ⁿ²■ " + }, + "ibm737": "cp737", + "csibm737": "cp737", + "cp775": { + "type": "_sbcs", + "chars": "ĆüéāäģåćłēŖŗīŹÄÅÉæÆōöĢ¢ŚśÖÜø£ØפĀĪóŻżź”¦©®¬½¼Ł«»░▒▓│┤ĄČĘĖ╣║╗╝ĮŠ┐└┴┬├─┼ŲŪ╚╔╩╦╠═╬Žąčęėįšųūž┘┌█▄▌▐▀ÓßŌŃõÕµńĶķĻļņĒŅ’­±“¾¶§÷„°∙·¹³²■ " + }, + "ibm775": "cp775", + "csibm775": "cp775", + "cp850": { + "type": "_sbcs", + "chars": "ÇüéâäàåçêëèïîìÄÅÉæÆôöòûùÿÖÜø£Ø׃áíóúñѪº¿®¬½¼¡«»░▒▓│┤ÁÂÀ©╣║╗╝¢¥┐└┴┬├─┼ãÃ╚╔╩╦╠═╬¤ðÐÊËÈıÍÎÏ┘┌█▄¦Ì▀ÓßÔÒõÕµþÞÚÛÙýݯ´­±‗¾¶§÷¸°¨·¹³²■ " + }, + "ibm850": "cp850", + "csibm850": "cp850", + "cp852": { + "type": "_sbcs", + "chars": "ÇüéâäůćçłëŐőîŹÄĆÉĹĺôöĽľŚśÖÜŤťŁ×čáíóúĄąŽžĘ꬟Ⱥ«»░▒▓│┤ÁÂĚŞ╣║╗╝Żż┐└┴┬├─┼Ăă╚╔╩╦╠═╬¤đĐĎËďŇÍÎě┘┌█▄ŢŮ▀ÓßÔŃńňŠšŔÚŕŰýÝţ´­˝˛ˇ˘§÷¸°¨˙űŘř■ " + }, + "ibm852": "cp852", + "csibm852": "cp852", + "cp855": { + "type": "_sbcs", + "chars": "ђЂѓЃёЁєЄѕЅіІїЇјЈљЉњЊћЋќЌўЎџЏюЮъЪаАбБцЦдДеЕфФгГ«»░▒▓│┤хХиИ╣║╗╝йЙ┐└┴┬├─┼кК╚╔╩╦╠═╬¤лЛмМнНоОп┘┌█▄Пя▀ЯрРсСтТуУжЖвВьЬ№­ыЫзЗшШэЭщЩчЧ§■ " + }, + "ibm855": "cp855", + "csibm855": "cp855", + "cp856": { + "type": "_sbcs", + "chars": "אבגדהוזחטיךכלםמןנסעףפץצקרשת�£�×����������®¬½¼�«»░▒▓│┤���©╣║╗╝¢¥┐└┴┬├─┼��╚╔╩╦╠═╬¤���������┘┌█▄¦�▀������µ�������¯´­±‗¾¶§÷¸°¨·¹³²■ " + }, + "ibm856": "cp856", + "csibm856": "cp856", + "cp857": { + "type": "_sbcs", + "chars": "ÇüéâäàåçêëèïîıÄÅÉæÆôöòûùİÖÜø£ØŞşáíóúñÑĞ𿮬½¼¡«»░▒▓│┤ÁÂÀ©╣║╗╝¢¥┐└┴┬├─┼ãÃ╚╔╩╦╠═╬¤ºªÊËÈ�ÍÎÏ┘┌█▄¦Ì▀ÓßÔÒõÕµ�×ÚÛÙìÿ¯´­±�¾¶§÷¸°¨·¹³²■ " + }, + "ibm857": "cp857", + "csibm857": "cp857", + "cp858": { + "type": "_sbcs", + "chars": "ÇüéâäàåçêëèïîìÄÅÉæÆôöòûùÿÖÜø£Ø׃áíóúñѪº¿®¬½¼¡«»░▒▓│┤ÁÂÀ©╣║╗╝¢¥┐└┴┬├─┼ãÃ╚╔╩╦╠═╬¤ðÐÊËÈ€ÍÎÏ┘┌█▄¦Ì▀ÓßÔÒõÕµþÞÚÛÙýݯ´­±‗¾¶§÷¸°¨·¹³²■ " + }, + "ibm858": "cp858", + "csibm858": "cp858", + "cp860": { + "type": "_sbcs", + "chars": "ÇüéâãàÁçêÊèÍÔìÃÂÉÀÈôõòÚùÌÕÜ¢£Ù₧ÓáíóúñѪº¿Ò¬½¼¡«»░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀αßΓπΣσµτΦΘΩδ∞φε∩≡±≥≤⌠⌡÷≈°∙·√ⁿ²■ " + }, + "ibm860": "cp860", + "csibm860": "cp860", + "cp861": { + "type": "_sbcs", + "chars": "ÇüéâäàåçêëèÐðÞÄÅÉæÆôöþûÝýÖÜø£Ø₧ƒáíóúÁÍÓÚ¿⌐¬½¼¡«»░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀αßΓπΣσµτΦΘΩδ∞φε∩≡±≥≤⌠⌡÷≈°∙·√ⁿ²■ " + }, + "ibm861": "cp861", + "csibm861": "cp861", + "cp862": { + "type": "_sbcs", + "chars": "אבגדהוזחטיךכלםמןנסעףפץצקרשת¢£¥₧ƒáíóúñѪº¿⌐¬½¼¡«»░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀αßΓπΣσµτΦΘΩδ∞φε∩≡±≥≤⌠⌡÷≈°∙·√ⁿ²■ " + }, + "ibm862": "cp862", + "csibm862": "cp862", + "cp863": { + "type": "_sbcs", + "chars": "ÇüéâÂà¶çêëèïî‗À§ÉÈÊôËÏûù¤ÔÜ¢£ÙÛƒ¦´óú¨¸³¯Î⌐¬½¼¾«»░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀αßΓπΣσµτΦΘΩδ∞φε∩≡±≥≤⌠⌡÷≈°∙·√ⁿ²■ " + }, + "ibm863": "cp863", + "csibm863": "cp863", + "cp864": { + "type": "_sbcs", + "chars": "\u0000\u0001\u0002\u0003\u0004\u0005\u0006\u0007\b\t\n\u000b\f\r\u000e\u000f\u0010\u0011\u0012\u0013\u0014\u0015\u0016\u0017\u0018\u0019\u001a\u001b\u001c\u001d\u001e\u001f !\"#$٪&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~°·∙√▒─│┼┤┬├┴┐┌└┘β∞φ±½¼≈«»ﻷﻸ��ﻻﻼ� ­ﺂ£¤ﺄ��ﺎﺏﺕﺙ،ﺝﺡﺥ٠١٢٣٤٥٦٧٨٩ﻑ؛ﺱﺵﺹ؟¢ﺀﺁﺃﺅﻊﺋﺍﺑﺓﺗﺛﺟﺣﺧﺩﺫﺭﺯﺳﺷﺻﺿﻁﻅﻋﻏ¦¬÷×ﻉـﻓﻗﻛﻟﻣﻧﻫﻭﻯﻳﺽﻌﻎﻍﻡﹽّﻥﻩﻬﻰﻲﻐﻕﻵﻶﻝﻙﻱ■�" + }, + "ibm864": "cp864", + "csibm864": "cp864", + "cp865": { + "type": "_sbcs", + "chars": "ÇüéâäàåçêëèïîìÄÅÉæÆôöòûùÿÖÜø£Ø₧ƒáíóúñѪº¿⌐¬½¼¡«¤░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀αßΓπΣσµτΦΘΩδ∞φε∩≡±≥≤⌠⌡÷≈°∙·√ⁿ²■ " + }, + "ibm865": "cp865", + "csibm865": "cp865", + "cp866": { + "type": "_sbcs", + "chars": "АБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмноп░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀рстуфхцчшщъыьэюяЁёЄєЇїЎў°∙·√№¤■ " + }, + "ibm866": "cp866", + "csibm866": "cp866", + "cp869": { + "type": "_sbcs", + "chars": "������Ά�·¬¦‘’Έ―ΉΊΪΌ��ΎΫ©Ώ²³ά£έήίϊΐόύΑΒΓΔΕΖΗ½ΘΙ«»░▒▓│┤ΚΛΜΝ╣║╗╝ΞΟ┐└┴┬├─┼ΠΡ╚╔╩╦╠═╬ΣΤΥΦΧΨΩαβγ┘┌█▄δε▀ζηθικλμνξοπρσςτ΄­±υφχ§ψ΅°¨ωϋΰώ■ " + }, + "ibm869": "cp869", + "csibm869": "cp869", + "cp922": { + "type": "_sbcs", + "chars": "€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ ¡¢£¤¥¦§¨©ª«¬­®‾°±²³´µ¶·¸¹º»¼½¾¿ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏŠÑÒÓÔÕÖ×ØÙÚÛÜÝŽßàáâãäåæçèéêëìíîïšñòóôõö÷øùúûüýžÿ" + }, + "ibm922": "cp922", + "csibm922": "cp922", + "cp1046": { + "type": "_sbcs", + "chars": "ﺈ×÷ﹱˆ■│─┐┌└┘ﹹﹻﹽﹿﹷﺊﻰﻳﻲﻎﻏﻐﻶﻸﻺﻼ ¤ﺋﺑﺗﺛﺟﺣ،­ﺧﺳ٠١٢٣٤٥٦٧٨٩ﺷ؛ﺻﺿﻊ؟ﻋءآأؤإئابةتثجحخدذرزسشصضطﻇعغﻌﺂﺄﺎﻓـفقكلمنهوىيًٌٍَُِّْﻗﻛﻟﻵﻷﻹﻻﻣﻧﻬﻩ�" + }, + "ibm1046": "cp1046", + "csibm1046": "cp1046", + "cp1124": { + "type": "_sbcs", + "chars": "€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ ЁЂҐЄЅІЇЈЉЊЋЌ­ЎЏАБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмнопрстуфхцчшщъыьэюя№ёђґєѕіїјљњћќ§ўџ" + }, + "ibm1124": "cp1124", + "csibm1124": "cp1124", + "cp1125": { + "type": "_sbcs", + "chars": "АБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмноп░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀рстуфхцчшщъыьэюяЁёҐґЄєІіЇї·√№¤■ " + }, + "ibm1125": "cp1125", + "csibm1125": "cp1125", + "cp1129": { + "type": "_sbcs", + "chars": "€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ ¡¢£¤¥¦§œ©ª«¬­®¯°±²³Ÿµ¶·Œ¹º»¼½¾¿ÀÁÂĂÄÅÆÇÈÉÊË̀ÍÎÏĐÑ̉ÓÔƠÖ×ØÙÚÛÜỮßàáâăäåæçèéêë́íîïđṇ̃óôơö÷øùúûüư₫ÿ" + }, + "ibm1129": "cp1129", + "csibm1129": "cp1129", + "cp1133": { + "type": "_sbcs", + "chars": "€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ ກຂຄງຈສຊຍດຕຖທນບປຜຝພຟມຢຣລວຫອຮ���ຯະາຳິີຶືຸູຼັົຽ���ເແໂໃໄ່້໊໋໌ໍໆ�ໜໝ₭����������������໐໑໒໓໔໕໖໗໘໙��¢¬¦�" + }, + "ibm1133": "cp1133", + "csibm1133": "cp1133", + "cp1161": { + "type": "_sbcs", + "chars": "��������������������������������่กขฃคฅฆงจฉชซฌญฎฏฐฑฒณดตถทธนบปผฝพฟภมยรฤลฦวศษสหฬอฮฯะัาำิีึืฺุู้๊๋€฿เแโใไๅๆ็่้๊๋์ํ๎๏๐๑๒๓๔๕๖๗๘๙๚๛¢¬¦ " + }, + "ibm1161": "cp1161", + "csibm1161": "cp1161", + "cp1162": { + "type": "_sbcs", + "chars": "€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ กขฃคฅฆงจฉชซฌญฎฏฐฑฒณดตถทธนบปผฝพฟภมยรฤลฦวศษสหฬอฮฯะัาำิีึืฺุู����฿เแโใไๅๆ็่้๊๋์ํ๎๏๐๑๒๓๔๕๖๗๘๙๚๛����" + }, + "ibm1162": "cp1162", + "csibm1162": "cp1162", + "cp1163": { + "type": "_sbcs", + "chars": "€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ ¡¢£€¥¦§œ©ª«¬­®¯°±²³Ÿµ¶·Œ¹º»¼½¾¿ÀÁÂĂÄÅÆÇÈÉÊË̀ÍÎÏĐÑ̉ÓÔƠÖ×ØÙÚÛÜỮßàáâăäåæçèéêë́íîïđṇ̃óôơö÷øùúûüư₫ÿ" + }, + "ibm1163": "cp1163", + "csibm1163": "cp1163", + "maccroatian": { + "type": "_sbcs", + "chars": "ÄÅÇÉÑÖÜáàâäãåçéèêëíìîïñóòôöõúùûü†°¢£§•¶ß®Š™´¨≠ŽØ∞±≤≥∆µ∂∑∏š∫ªºΩžø¿¡¬√ƒ≈Ć«Č… ÀÃÕŒœĐ—“”‘’÷◊�©⁄¤‹›Æ»–·‚„‰ÂćÁčÈÍÎÏÌÓÔđÒÚÛÙıˆ˜¯πË˚¸Êæˇ" + }, + "maccyrillic": { + "type": "_sbcs", + "chars": "АБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯ†°¢£§•¶І®©™Ђђ≠Ѓѓ∞±≤≥іµ∂ЈЄєЇїЉљЊњјЅ¬√ƒ≈∆«»… ЋћЌќѕ–—“”‘’÷„ЎўЏџ№Ёёяабвгдежзийклмнопрстуфхцчшщъыьэю¤" + }, + "macgreek": { + "type": "_sbcs", + "chars": "Ĺ²É³ÖÜ΅àâä΄¨çéèê룙î‰ôö¦­ùûü†ΓΔΘΛΞΠß®©ΣΪ§≠°·Α±≤≥¥ΒΕΖΗΙΚΜΦΫΨΩάΝ¬ΟΡ≈Τ«»… ΥΧΆΈœ–―“”‘’÷ΉΊΌΎέήίόΏύαβψδεφγηιξκλμνοπώρστθωςχυζϊϋΐΰ�" + }, + "maciceland": { + "type": "_sbcs", + "chars": "ÄÅÇÉÑÖÜáàâäãåçéèêëíìîïñóòôöõúùûüÝ°¢£§•¶ß®©™´¨≠ÆØ∞±≤≥¥µ∂∑∏π∫ªºΩæø¿¡¬√ƒ≈∆«»… ÀÃÕŒœ–—“”‘’÷◊ÿŸ⁄¤ÐðÞþý·‚„‰ÂÊÁËÈÍÎÏÌÓÔ�ÒÚÛÙıˆ˜¯˘˙˚¸˝˛ˇ" + }, + "macroman": { + "type": "_sbcs", + "chars": "ÄÅÇÉÑÖÜáàâäãåçéèêëíìîïñóòôöõúùûü†°¢£§•¶ß®©™´¨≠ÆØ∞±≤≥¥µ∂∑∏π∫ªºΩæø¿¡¬√ƒ≈∆«»… ÀÃÕŒœ–—“”‘’÷◊ÿŸ⁄¤‹›fifl‡·‚„‰ÂÊÁËÈÍÎÏÌÓÔ�ÒÚÛÙıˆ˜¯˘˙˚¸˝˛ˇ" + }, + "macromania": { + "type": "_sbcs", + "chars": "ÄÅÇÉÑÖÜáàâäãåçéèêëíìîïñóòôöõúùûü†°¢£§•¶ß®©™´¨≠ĂŞ∞±≤≥¥µ∂∑∏π∫ªºΩăş¿¡¬√ƒ≈∆«»… ÀÃÕŒœ–—“”‘’÷◊ÿŸ⁄¤‹›Ţţ‡·‚„‰ÂÊÁËÈÍÎÏÌÓÔ�ÒÚÛÙıˆ˜¯˘˙˚¸˝˛ˇ" + }, + "macthai": { + "type": "_sbcs", + "chars": "«»…“”�•‘’� กขฃคฅฆงจฉชซฌญฎฏฐฑฒณดตถทธนบปผฝพฟภมยรฤลฦวศษสหฬอฮฯะัาำิีึืฺุู​–—฿เแโใไๅๆ็่้๊๋์ํ™๏๐๑๒๓๔๕๖๗๘๙®©����" + }, + "macturkish": { + "type": "_sbcs", + "chars": "ÄÅÇÉÑÖÜáàâäãåçéèêëíìîïñóòôöõúùûü†°¢£§•¶ß®©™´¨≠ÆØ∞±≤≥¥µ∂∑∏π∫ªºΩæø¿¡¬√ƒ≈∆«»… ÀÃÕŒœ–—“”‘’÷◊ÿŸĞğİıŞş‡·‚„‰ÂÊÁËÈÍÎÏÌÓÔ�ÒÚÛÙ�ˆ˜¯˘˙˚¸˝˛ˇ" + }, + "macukraine": { + "type": "_sbcs", + "chars": "АБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯ†°Ґ£§•¶І®©™Ђђ≠Ѓѓ∞±≤≥іµґЈЄєЇїЉљЊњјЅ¬√ƒ≈∆«»… ЋћЌќѕ–—“”‘’÷„ЎўЏџ№Ёёяабвгдежзийклмнопрстуфхцчшщъыьэю¤" + }, + "koi8r": { + "type": "_sbcs", + "chars": "─│┌┐└┘├┤┬┴┼▀▄█▌▐░▒▓⌠■∙√≈≤≥ ⌡°²·÷═║╒ё╓╔╕╖╗╘╙╚╛╜╝╞╟╠╡Ё╢╣╤╥╦╧╨╩╪╫╬©юабцдефгхийклмнопярстужвьызшэщчъЮАБЦДЕФГХИЙКЛМНОПЯРСТУЖВЬЫЗШЭЩЧЪ" + }, + "koi8u": { + "type": "_sbcs", + "chars": "─│┌┐└┘├┤┬┴┼▀▄█▌▐░▒▓⌠■∙√≈≤≥ ⌡°²·÷═║╒ёє╔ії╗╘╙╚╛ґ╝╞╟╠╡ЁЄ╣ІЇ╦╧╨╩╪Ґ╬©юабцдефгхийклмнопярстужвьызшэщчъЮАБЦДЕФГХИЙКЛМНОПЯРСТУЖВЬЫЗШЭЩЧЪ" + }, + "koi8ru": { + "type": "_sbcs", + "chars": "─│┌┐└┘├┤┬┴┼▀▄█▌▐░▒▓⌠■∙√≈≤≥ ⌡°²·÷═║╒ёє╔ії╗╘╙╚╛ґў╞╟╠╡ЁЄ╣ІЇ╦╧╨╩╪ҐЎ©юабцдефгхийклмнопярстужвьызшэщчъЮАБЦДЕФГХИЙКЛМНОПЯРСТУЖВЬЫЗШЭЩЧЪ" + }, + "koi8t": { + "type": "_sbcs", + "chars": "қғ‚Ғ„…†‡�‰ҳ‹ҲҷҶ�Қ‘’“”•–—�™�›�����ӯӮё¤ӣ¦§���«¬­®�°±²Ё�Ӣ¶·�№�»���©юабцдефгхийклмнопярстужвьызшэщчъЮАБЦДЕФГХИЙКЛМНОПЯРСТУЖВЬЫЗШЭЩЧЪ" + }, + "armscii8": { + "type": "_sbcs", + "chars": "€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ �և։)(»«—.՝,-֊…՜՛՞ԱաԲբԳգԴդԵեԶզԷէԸըԹթԺժԻիԼլԽխԾծԿկՀհՁձՂղՃճՄմՅյՆնՇշՈոՉչՊպՋջՌռՍսՎվՏտՐրՑցՒւՓփՔքՕօՖֆ՚�" + }, + "rk1048": { + "type": "_sbcs", + "chars": "ЂЃ‚ѓ„…†‡€‰Љ‹ЊҚҺЏђ‘’“”•–—�™љ›њқһџ ҰұӘ¤Ө¦§Ё©Ғ«¬­®Ү°±Ііөµ¶·ё№ғ»әҢңүАБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмнопрстуфхцчшщъыьэюя" + }, + "tcvn": { + "type": "_sbcs", + "chars": "\u0000ÚỤ\u0003ỪỬỮ\u0007\b\t\n\u000b\f\r\u000e\u000f\u0010ỨỰỲỶỸÝỴ\u0018\u0019\u001a\u001b\u001c\u001d\u001e\u001f !\"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~ÀẢÃÁẠẶẬÈẺẼÉẸỆÌỈĨÍỊÒỎÕÓỌỘỜỞỠỚỢÙỦŨ ĂÂÊÔƠƯĐăâêôơưđẶ̀̀̉̃́àảãáạẲằẳẵắẴẮẦẨẪẤỀặầẩẫấậèỂẻẽéẹềểễếệìỉỄẾỒĩíịòỔỏõóọồổỗốộờởỡớợùỖủũúụừửữứựỳỷỹýỵỐ" + }, + "georgianacademy": { + "type": "_sbcs", + "chars": "€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ ¡¢£¤¥¦§¨©ª«¬­®¯°±²³´µ¶·¸¹º»¼½¾¿აბგდევზთიკლმნოპჟრსტუფქღყშჩცძწჭხჯჰჱჲჳჴჵჶçèéêëìíîïðñòóôõö÷øùúûüýþÿ" + }, + "georgianps": { + "type": "_sbcs", + "chars": "€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ ¡¢£¤¥¦§¨©ª«¬­®¯°±²³´µ¶·¸¹º»¼½¾¿აბგდევზჱთიკლმნჲოპჟრსტჳუფქღყშჩცძწჭხჴჯჰჵæçèéêëìíîïðñòóôõö÷øùúûüýþÿ" + }, + "pt154": { + "type": "_sbcs", + "chars": "ҖҒӮғ„…ҶҮҲүҠӢҢҚҺҸҗ‘’“”•–—ҳҷҡӣңқһҹ ЎўЈӨҘҰ§Ё©Ә«¬ӯ®Ҝ°ұІіҙө¶·ё№ә»јҪҫҝАБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмнопрстуфхцчшщъыьэюя" + }, + "viscii": { + "type": "_sbcs", + "chars": "\u0000\u0001Ẳ\u0003\u0004ẴẪ\u0007\b\t\n\u000b\f\r\u000e\u000f\u0010\u0011\u0012\u0013Ỷ\u0015\u0016\u0017\u0018Ỹ\u001a\u001b\u001c\u001dỴ\u001f !\"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~ẠẮẰẶẤẦẨẬẼẸẾỀỂỄỆỐỒỔỖỘỢỚỜỞỊỎỌỈỦŨỤỲÕắằặấầẩậẽẹếềểễệốồổỗỠƠộờởịỰỨỪỬơớƯÀÁÂÃẢĂẳẵÈÉÊẺÌÍĨỳĐứÒÓÔạỷừửÙÚỹỵÝỡưàáâãảăữẫèéêẻìíĩỉđựòóôõỏọụùúũủýợỮ" + }, + "iso646cn": { + "type": "_sbcs", + "chars": "\u0000\u0001\u0002\u0003\u0004\u0005\u0006\u0007\b\t\n\u000b\f\r\u000e\u000f\u0010\u0011\u0012\u0013\u0014\u0015\u0016\u0017\u0018\u0019\u001a\u001b\u001c\u001d\u001e\u001f !\"#¥%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}‾��������������������������������������������������������������������������������������������������������������������������������" + }, + "iso646jp": { + "type": "_sbcs", + "chars": "\u0000\u0001\u0002\u0003\u0004\u0005\u0006\u0007\b\t\n\u000b\f\r\u000e\u000f\u0010\u0011\u0012\u0013\u0014\u0015\u0016\u0017\u0018\u0019\u001a\u001b\u001c\u001d\u001e\u001f !\"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[¥]^_`abcdefghijklmnopqrstuvwxyz{|}‾��������������������������������������������������������������������������������������������������������������������������������" + }, + "hproman8": { + "type": "_sbcs", + "chars": "€‚ƒ„…†‡ˆ‰Š‹ŒŽ‘’“”•–—˜™š›œžŸ ÀÂÈÊËÎÏ´ˋˆ¨˜ÙÛ₤¯Ýý°ÇçÑñ¡¿¤£¥§ƒ¢âêôûáéóúàèòùäëöüÅîØÆåíøæÄìÖÜÉïßÔÁÃãÐðÍÌÓÒÕõŠšÚŸÿÞþ·µ¶¾—¼½ªº«■»±�" + }, + "macintosh": { + "type": "_sbcs", + "chars": "ÄÅÇÉÑÖÜáàâäãåçéèêëíìîïñóòôöõúùûü†°¢£§•¶ß®©™´¨≠ÆØ∞±≤≥¥µ∂∑∏π∫ªºΩæø¿¡¬√ƒ≈∆«»… ÀÃÕŒœ–—“”‘’÷◊ÿŸ⁄¤‹›fifl‡·‚„‰ÂÊÁËÈÍÎÏÌÓÔ�ÒÚÛÙıˆ˜¯˘˙˚¸˝˛ˇ" + }, + "ascii": { + "type": "_sbcs", + "chars": "��������������������������������������������������������������������������������������������������������������������������������" + }, + "tis620": { + "type": "_sbcs", + "chars": "���������������������������������กขฃคฅฆงจฉชซฌญฎฏฐฑฒณดตถทธนบปผฝพฟภมยรฤลฦวศษสหฬอฮฯะัาำิีึืฺุู����฿เแโใไๅๆ็่้๊๋์ํ๎๏๐๑๒๓๔๕๖๗๘๙๚๛����" + } +} \ No newline at end of file diff --git a/node_modules/body-parser/node_modules/iconv-lite/encodings/sbcs-data.js b/node_modules/body-parser/node_modules/iconv-lite/encodings/sbcs-data.js new file mode 100644 index 0000000..74fb34b --- /dev/null +++ b/node_modules/body-parser/node_modules/iconv-lite/encodings/sbcs-data.js @@ -0,0 +1,168 @@ + +// Manually added data to be used by sbcs codec in addition to generated one. + +module.exports = { + // Not supported by iconv, not sure why. + "10029": "maccenteuro", + "maccenteuro": { + "type": "_sbcs", + "chars": "ÄĀāÉĄÖÜáąČäčĆć鏟ĎíďĒēĖóėôöõúĚěü†°Ę£§•¶ß®©™ę¨≠ģĮįĪ≤≥īĶ∂∑łĻļĽľĹĺŅņѬ√ńŇ∆«»… ňŐÕőŌ–—“”‘’÷◊ōŔŕŘ‹›řŖŗŠ‚„šŚśÁŤťÍŽžŪÓÔūŮÚůŰűŲųÝýķŻŁżĢˇ" + }, + + "808": "cp808", + "ibm808": "cp808", + "cp808": { + "type": "_sbcs", + "chars": "АБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмноп░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀рстуфхцчшщъыьэюяЁёЄєЇїЎў°∙·√№€■ " + }, + + // Aliases of generated encodings. + "ascii8bit": "ascii", + "usascii": "ascii", + "ansix3.4": "ascii", + "ansix3.41968": "ascii", + "ansix3.41986": "ascii", + "csascii": "ascii", + "cp367": "ascii", + "ibm367": "ascii", + "isoir6": "ascii", + "iso646us": "ascii", + "iso646.irv": "ascii", + "us": "ascii", + + "latin1": "iso88591", + "latin2": "iso88592", + "latin3": "iso88593", + "latin4": "iso88594", + "latin5": "iso88599", + "latin6": "iso885910", + "latin7": "iso885913", + "latin8": "iso885914", + "latin9": "iso885915", + "latin10": "iso885916", + + "csisolatin1": "iso88591", + "csisolatin2": "iso88592", + "csisolatin3": "iso88593", + "csisolatin4": "iso88594", + "csisolatincyrillic": "iso88595", + "csisolatinarabic": "iso88596", + "csisolatingreek" : "iso88597", + "csisolatinhebrew": "iso88598", + "csisolatin5": "iso88599", + "csisolatin6": "iso885910", + + "l1": "iso88591", + "l2": "iso88592", + "l3": "iso88593", + "l4": "iso88594", + "l5": "iso88599", + "l6": "iso885910", + "l7": "iso885913", + "l8": "iso885914", + "l9": "iso885915", + "l10": "iso885916", + + "isoir14": "iso646jp", + "isoir57": "iso646cn", + "isoir100": "iso88591", + "isoir101": "iso88592", + "isoir109": "iso88593", + "isoir110": "iso88594", + "isoir144": "iso88595", + "isoir127": "iso88596", + "isoir126": "iso88597", + "isoir138": "iso88598", + "isoir148": "iso88599", + "isoir157": "iso885910", + "isoir166": "tis620", + "isoir179": "iso885913", + "isoir199": "iso885914", + "isoir203": "iso885915", + "isoir226": "iso885916", + + "cp819": "iso88591", + "ibm819": "iso88591", + + "cyrillic": "iso88595", + + "arabic": "iso88596", + "arabic8": "iso88596", + "ecma114": "iso88596", + "asmo708": "iso88596", + + "greek" : "iso88597", + "greek8" : "iso88597", + "ecma118" : "iso88597", + "elot928" : "iso88597", + + "hebrew": "iso88598", + "hebrew8": "iso88598", + + "turkish": "iso88599", + "turkish8": "iso88599", + + "thai": "iso885911", + "thai8": "iso885911", + + "celtic": "iso885914", + "celtic8": "iso885914", + "isoceltic": "iso885914", + + "tis6200": "tis620", + "tis620.25291": "tis620", + "tis620.25330": "tis620", + + "10000": "macroman", + "10006": "macgreek", + "10007": "maccyrillic", + "10079": "maciceland", + "10081": "macturkish", + + "cspc8codepage437": "cp437", + "cspc775baltic": "cp775", + "cspc850multilingual": "cp850", + "cspcp852": "cp852", + "cspc862latinhebrew": "cp862", + "cpgr": "cp869", + + "msee": "cp1250", + "mscyrl": "cp1251", + "msansi": "cp1252", + "msgreek": "cp1253", + "msturk": "cp1254", + "mshebr": "cp1255", + "msarab": "cp1256", + "winbaltrim": "cp1257", + + "cp20866": "koi8r", + "20866": "koi8r", + "ibm878": "koi8r", + "cskoi8r": "koi8r", + + "cp21866": "koi8u", + "21866": "koi8u", + "ibm1168": "koi8u", + + "strk10482002": "rk1048", + + "tcvn5712": "tcvn", + "tcvn57121": "tcvn", + + "gb198880": "iso646cn", + "cn": "iso646cn", + + "csiso14jisc6220ro": "iso646jp", + "jisc62201969ro": "iso646jp", + "jp": "iso646jp", + + "cshproman8": "hproman8", + "r8": "hproman8", + "roman8": "hproman8", + "xroman8": "hproman8", + "ibm1051": "hproman8", + + "mac": "macintosh", + "csmacintosh": "macintosh", +}; + diff --git a/node_modules/body-parser/node_modules/iconv-lite/encodings/tables/big5-added.json b/node_modules/body-parser/node_modules/iconv-lite/encodings/tables/big5-added.json new file mode 100644 index 0000000..3c3d3c2 --- /dev/null +++ b/node_modules/body-parser/node_modules/iconv-lite/encodings/tables/big5-added.json @@ -0,0 +1,122 @@ +[ +["8740","䏰䰲䘃䖦䕸𧉧䵷䖳𧲱䳢𧳅㮕䜶䝄䱇䱀𤊿𣘗𧍒𦺋𧃒䱗𪍑䝏䗚䲅𧱬䴇䪤䚡𦬣爥𥩔𡩣𣸆𣽡晍囻"], +["8767","綕夝𨮹㷴霴𧯯寛𡵞媤㘥𩺰嫑宷峼杮薓𩥅瑡璝㡵𡵓𣚞𦀡㻬"], +["87a1","𥣞㫵竼龗𤅡𨤍𣇪𠪊𣉞䌊蒄龖鐯䤰蘓墖靊鈘秐稲晠権袝瑌篅枂稬剏遆㓦珄𥶹瓆鿇垳䤯呌䄱𣚎堘穲𧭥讏䚮𦺈䆁𥶙箮𢒼鿈𢓁𢓉𢓌鿉蔄𣖻䂴鿊䓡𪷿拁灮鿋"], +["8840","㇀",4,"𠄌㇅𠃑𠃍㇆㇇𠃋𡿨㇈𠃊㇉㇊㇋㇌𠄎㇍㇎ĀÁǍÀĒÉĚÈŌÓǑÒ࿿Ê̄Ế࿿Ê̌ỀÊāáǎàɑēéěèīíǐìōóǒòūúǔùǖǘǚ"], +["88a1","ǜü࿿ê̄ế࿿ê̌ềêɡ⏚⏛"], +["8940","𪎩𡅅"], +["8943","攊"], +["8946","丽滝鵎釟"], +["894c","𧜵撑会伨侨兖兴农凤务动医华发变团声处备夲头学实実岚庆总斉柾栄桥济炼电纤纬纺织经统缆缷艺苏药视设询车轧轮"], +["89a1","琑糼緍楆竉刧"], +["89ab","醌碸酞肼"], +["89b0","贋胶𠧧"], +["89b5","肟黇䳍鷉鸌䰾𩷶𧀎鸊𪄳㗁"], +["89c1","溚舾甙"], +["89c5","䤑马骏龙禇𨑬𡷊𠗐𢫦两亁亀亇亿仫伷㑌侽㹈倃傈㑽㒓㒥円夅凛凼刅争剹劐匧㗇厩㕑厰㕓参吣㕭㕲㚁咓咣咴咹哐哯唘唣唨㖘唿㖥㖿嗗㗅"], +["8a40","𧶄唥"], +["8a43","𠱂𠴕𥄫喐𢳆㧬𠍁蹆𤶸𩓥䁓𨂾睺𢰸㨴䟕𨅝𦧲𤷪擝𠵼𠾴𠳕𡃴撍蹾𠺖𠰋𠽤𢲩𨉖𤓓"], +["8a64","𠵆𩩍𨃩䟴𤺧𢳂骲㩧𩗴㿭㔆𥋇𩟔𧣈𢵄鵮頕"], +["8a76","䏙𦂥撴哣𢵌𢯊𡁷㧻𡁯"], +["8aa1","𦛚𦜖𧦠擪𥁒𠱃蹨𢆡𨭌𠜱"], +["8aac","䠋𠆩㿺塳𢶍"], +["8ab2","𤗈𠓼𦂗𠽌𠶖啹䂻䎺"], +["8abb","䪴𢩦𡂝膪飵𠶜捹㧾𢝵跀嚡摼㹃"], +["8ac9","𪘁𠸉𢫏𢳉"], +["8ace","𡃈𣧂㦒㨆𨊛㕸𥹉𢃇噒𠼱𢲲𩜠㒼氽𤸻"], +["8adf","𧕴𢺋𢈈𪙛𨳍𠹺𠰴𦠜羓𡃏𢠃𢤹㗻𥇣𠺌𠾍𠺪㾓𠼰𠵇𡅏𠹌"], +["8af6","𠺫𠮩𠵈𡃀𡄽㿹𢚖搲𠾭"], +["8b40","𣏴𧘹𢯎𠵾𠵿𢱑𢱕㨘𠺘𡃇𠼮𪘲𦭐𨳒𨶙𨳊閪哌苄喹"], +["8b55","𩻃鰦骶𧝞𢷮煀腭胬尜𦕲脴㞗卟𨂽醶𠻺𠸏𠹷𠻻㗝𤷫㘉𠳖嚯𢞵𡃉𠸐𠹸𡁸𡅈𨈇𡑕𠹹𤹐𢶤婔𡀝𡀞𡃵𡃶垜𠸑"], +["8ba1","𧚔𨋍𠾵𠹻𥅾㜃𠾶𡆀𥋘𪊽𤧚𡠺𤅷𨉼墙剨㘚𥜽箲孨䠀䬬鼧䧧鰟鮍𥭴𣄽嗻㗲嚉丨夂𡯁屮靑𠂆乛亻㔾尣彑忄㣺扌攵歺氵氺灬爫丬犭𤣩罒礻糹罓𦉪㓁"], +["8bde","𦍋耂肀𦘒𦥑卝衤见𧢲讠贝钅镸长门𨸏韦页风飞饣𩠐鱼鸟黄歯龜丷𠂇阝户钢"], +["8c40","倻淾𩱳龦㷉袏𤅎灷峵䬠𥇍㕙𥴰愢𨨲辧釶熑朙玺𣊁𪄇㲋𡦀䬐磤琂冮𨜏䀉橣𪊺䈣蘏𠩯稪𩥇𨫪靕灍匤𢁾鏴盙𨧣龧矝亣俰傼丯众龨吴綋墒壐𡶶庒庙忂𢜒斋"], +["8ca1","𣏹椙橃𣱣泿"], +["8ca7","爀𤔅玌㻛𤨓嬕璹讃𥲤𥚕窓篬糃繬苸薗龩袐龪躹龫迏蕟駠鈡龬𨶹𡐿䁱䊢娚"], +["8cc9","顨杫䉶圽"], +["8cce","藖𤥻芿𧄍䲁𦵴嵻𦬕𦾾龭龮宖龯曧繛湗秊㶈䓃𣉖𢞖䎚䔶"], +["8ce6","峕𣬚諹屸㴒𣕑嵸龲煗䕘𤃬𡸣䱷㥸㑊𠆤𦱁諌侴𠈹妿腬顖𩣺弻"], +["8d40","𠮟"], +["8d42","𢇁𨥭䄂䚻𩁹㼇龳𪆵䃸㟖䛷𦱆䅼𨚲𧏿䕭㣔𥒚䕡䔛䶉䱻䵶䗪㿈𤬏㙡䓞䒽䇭崾嵈嵖㷼㠏嶤嶹㠠㠸幂庽弥徃㤈㤔㤿㥍惗愽峥㦉憷憹懏㦸戬抐拥挘㧸嚱"], +["8da1","㨃揢揻搇摚㩋擀崕嘡龟㪗斆㪽旿晓㫲暒㬢朖㭂枤栀㭘桊梄㭲㭱㭻椉楃牜楤榟榅㮼槖㯝橥橴橱檂㯬檙㯲檫檵櫔櫶殁毁毪汵沪㳋洂洆洦涁㳯涤涱渕渘温溆𨧀溻滢滚齿滨滩漤漴㵆𣽁澁澾㵪㵵熷岙㶊瀬㶑灐灔灯灿炉𠌥䏁㗱𠻘"], +["8e40","𣻗垾𦻓焾𥟠㙎榢𨯩孴穉𥣡𩓙穥穽𥦬窻窰竂竃燑𦒍䇊竚竝竪䇯咲𥰁笋筕笩𥌎𥳾箢筯莜𥮴𦱿篐萡箒箸𥴠㶭𥱥蒒篺簆簵𥳁籄粃𤢂粦晽𤕸糉糇糦籴糳糵糎"], +["8ea1","繧䔝𦹄絝𦻖璍綉綫焵綳緒𤁗𦀩緤㴓緵𡟹緥𨍭縝𦄡𦅚繮纒䌫鑬縧罀罁罇礶𦋐駡羗𦍑羣𡙡𠁨䕜𣝦䔃𨌺翺𦒉者耈耝耨耯𪂇𦳃耻耼聡𢜔䦉𦘦𣷣𦛨朥肧𨩈脇脚墰𢛶汿𦒘𤾸擧𡒊舘𡡞橓𤩥𤪕䑺舩𠬍𦩒𣵾俹𡓽蓢荢𦬊𤦧𣔰𡝳𣷸芪椛芳䇛"], +["8f40","蕋苐茚𠸖𡞴㛁𣅽𣕚艻苢茘𣺋𦶣𦬅𦮗𣗎㶿茝嗬莅䔋𦶥莬菁菓㑾𦻔橗蕚㒖𦹂𢻯葘𥯤葱㷓䓤檧葊𣲵祘蒨𦮖𦹷𦹃蓞萏莑䒠蒓蓤𥲑䉀𥳀䕃蔴嫲𦺙䔧蕳䔖枿蘖"], +["8fa1","𨘥𨘻藁𧂈蘂𡖂𧃍䕫䕪蘨㙈𡢢号𧎚虾蝱𪃸蟮𢰧螱蟚蠏噡虬桖䘏衅衆𧗠𣶹𧗤衞袜䙛袴袵揁装睷𧜏覇覊覦覩覧覼𨨥觧𧤤𧪽誜瞓釾誐𧩙竩𧬺𣾏䜓𧬸煼謌謟𥐰𥕥謿譌譍誩𤩺讐讛誯𡛟䘕衏貛𧵔𧶏貫㜥𧵓賖𧶘𧶽贒贃𡤐賛灜贑𤳉㻐起"], +["9040","趩𨀂𡀔𤦊㭼𨆼𧄌竧躭躶軃鋔輙輭𨍥𨐒辥錃𪊟𠩐辳䤪𨧞𨔽𣶻廸𣉢迹𪀔𨚼𨔁𢌥㦀𦻗逷𨔼𧪾遡𨕬𨘋邨𨜓郄𨛦邮都酧㫰醩釄粬𨤳𡺉鈎沟鉁鉢𥖹銹𨫆𣲛𨬌𥗛"], +["90a1","𠴱錬鍫𨫡𨯫炏嫃𨫢𨫥䥥鉄𨯬𨰹𨯿鍳鑛躼閅閦鐦閠濶䊹𢙺𨛘𡉼𣸮䧟氜陻隖䅬隣𦻕懚隶磵𨫠隽双䦡𦲸𠉴𦐐𩂯𩃥𤫑𡤕𣌊霱虂霶䨏䔽䖅𤫩灵孁霛靜𩇕靗孊𩇫靟鐥僐𣂷𣂼鞉鞟鞱鞾韀韒韠𥑬韮琜𩐳響韵𩐝𧥺䫑頴頳顋顦㬎𧅵㵑𠘰𤅜"], +["9140","𥜆飊颷飈飇䫿𦴧𡛓喰飡飦飬鍸餹𤨩䭲𩡗𩤅駵騌騻騐驘𥜥㛄𩂱𩯕髠髢𩬅髴䰎鬔鬭𨘀倴鬴𦦨㣃𣁽魐魀𩴾婅𡡣鮎𤉋鰂鯿鰌𩹨鷔𩾷𪆒𪆫𪃡𪄣𪇟鵾鶃𪄴鸎梈"], +["91a1","鷄𢅛𪆓𪈠𡤻𪈳鴹𪂹𪊴麐麕麞麢䴴麪麯𤍤黁㭠㧥㴝伲㞾𨰫鼂鼈䮖鐤𦶢鼗鼖鼹嚟嚊齅馸𩂋韲葿齢齩竜龎爖䮾𤥵𤦻煷𤧸𤍈𤩑玞𨯚𡣺禟𨥾𨸶鍩鏳𨩄鋬鎁鏋𨥬𤒹爗㻫睲穃烐𤑳𤏸煾𡟯炣𡢾𣖙㻇𡢅𥐯𡟸㜢𡛻𡠹㛡𡝴𡣑𥽋㜣𡛀坛𤨥𡏾𡊨"], +["9240","𡏆𡒶蔃𣚦蔃葕𤦔𧅥𣸱𥕜𣻻𧁒䓴𣛮𩦝𦼦柹㜳㰕㷧塬𡤢栐䁗𣜿𤃡𤂋𤄏𦰡哋嚞𦚱嚒𠿟𠮨𠸍鏆𨬓鎜仸儫㠙𤐶亼𠑥𠍿佋侊𥙑婨𠆫𠏋㦙𠌊𠐔㐵伩𠋀𨺳𠉵諚𠈌亘"], +["92a1","働儍侢伃𤨎𣺊佂倮偬傁俌俥偘僼兙兛兝兞湶𣖕𣸹𣺿浲𡢄𣺉冨凃𠗠䓝𠒣𠒒𠒑赺𨪜𠜎剙劤𠡳勡鍮䙺熌𤎌𠰠𤦬𡃤槑𠸝瑹㻞璙琔瑖玘䮎𤪼𤂍叐㖄爏𤃉喴𠍅响𠯆圝鉝雴鍦埝垍坿㘾壋媙𨩆𡛺𡝯𡜐娬妸銏婾嫏娒𥥆𡧳𡡡𤊕㛵洅瑃娡𥺃"], +["9340","媁𨯗𠐓鏠璌𡌃焅䥲鐈𨧻鎽㞠尞岞幞幈𡦖𡥼𣫮廍孏𡤃𡤄㜁𡢠㛝𡛾㛓脪𨩇𡶺𣑲𨦨弌弎𡤧𡞫婫𡜻孄蘔𧗽衠恾𢡠𢘫忛㺸𢖯𢖾𩂈𦽳懀𠀾𠁆𢘛憙憘恵𢲛𢴇𤛔𩅍"], +["93a1","摱𤙥𢭪㨩𢬢𣑐𩣪𢹸挷𪑛撶挱揑𤧣𢵧护𢲡搻敫楲㯴𣂎𣊭𤦉𣊫唍𣋠𡣙𩐿曎𣊉𣆳㫠䆐𥖄𨬢𥖏𡛼𥕛𥐥磮𣄃𡠪𣈴㑤𣈏𣆂𤋉暎𦴤晫䮓昰𧡰𡷫晣𣋒𣋡昞𥡲㣑𣠺𣞼㮙𣞢𣏾瓐㮖枏𤘪梶栞㯄檾㡣𣟕𤒇樳橒櫉欅𡤒攑梘橌㯗橺歗𣿀𣲚鎠鋲𨯪𨫋"], +["9440","銉𨀞𨧜鑧涥漋𤧬浧𣽿㶏渄𤀼娽渊塇洤硂焻𤌚𤉶烱牐犇犔𤞏𤜥兹𤪤𠗫瑺𣻸𣙟𤩊𤤗𥿡㼆㺱𤫟𨰣𣼵悧㻳瓌琼鎇琷䒟𦷪䕑疃㽣𤳙𤴆㽘畕癳𪗆㬙瑨𨫌𤦫𤦎㫻"], +["94a1","㷍𤩎㻿𤧅𤣳釺圲鍂𨫣𡡤僟𥈡𥇧睸𣈲眎眏睻𤚗𣞁㩞𤣰琸璛㺿𤪺𤫇䃈𤪖𦆮錇𥖁砞碍碈磒珐祙𧝁𥛣䄎禛蒖禥樭𣻺稺秴䅮𡛦䄲鈵秱𠵌𤦌𠊙𣶺𡝮㖗啫㕰㚪𠇔𠰍竢婙𢛵𥪯𥪜娍𠉛磰娪𥯆竾䇹籝籭䈑𥮳𥺼𥺦糍𤧹𡞰粎籼粮檲緜縇緓罎𦉡"], +["9540","𦅜𧭈綗𥺂䉪𦭵𠤖柖𠁎𣗏埄𦐒𦏸𤥢翝笧𠠬𥫩𥵃笌𥸎駦虅驣樜𣐿㧢𤧷𦖭騟𦖠蒀𧄧𦳑䓪脷䐂胆脉腂𦞴飃𦩂艢艥𦩑葓𦶧蘐𧈛媆䅿𡡀嬫𡢡嫤𡣘蚠蜨𣶏蠭𧐢娂"], +["95a1","衮佅袇袿裦襥襍𥚃襔𧞅𧞄𨯵𨯙𨮜𨧹㺭蒣䛵䛏㟲訽訜𩑈彍鈫𤊄旔焩烄𡡅鵭貟賩𧷜妚矃姰䍮㛔踪躧𤰉輰轊䋴汘澻𢌡䢛潹溋𡟚鯩㚵𤤯邻邗啱䤆醻鐄𨩋䁢𨫼鐧𨰝𨰻蓥訫閙閧閗閖𨴴瑅㻂𤣿𤩂𤏪㻧𣈥随𨻧𨹦𨹥㻌𤧭𤩸𣿮琒瑫㻼靁𩂰"], +["9640","桇䨝𩂓𥟟靝鍨𨦉𨰦𨬯𦎾銺嬑譩䤼珹𤈛鞛靱餸𠼦巁𨯅𤪲頟𩓚鋶𩗗釥䓀𨭐𤩧𨭤飜𨩅㼀鈪䤥萔餻饍𧬆㷽馛䭯馪驜𨭥𥣈檏騡嫾騯𩣱䮐𩥈馼䮽䮗鍽塲𡌂堢𤦸"], +["96a1","𡓨硄𢜟𣶸棅㵽鑘㤧慐𢞁𢥫愇鱏鱓鱻鰵鰐魿鯏𩸭鮟𪇵𪃾鴡䲮𤄄鸘䲰鴌𪆴𪃭𪃳𩤯鶥蒽𦸒𦿟𦮂藼䔳𦶤𦺄𦷰萠藮𦸀𣟗𦁤秢𣖜𣙀䤭𤧞㵢鏛銾鍈𠊿碹鉷鑍俤㑀遤𥕝砽硔碶硋𡝗𣇉𤥁㚚佲濚濙瀞瀞吔𤆵垻壳垊鴖埗焴㒯𤆬燫𦱀𤾗嬨𡞵𨩉"], +["9740","愌嫎娋䊼𤒈㜬䭻𨧼鎻鎸𡣖𠼝葲𦳀𡐓𤋺𢰦𤏁妔𣶷𦝁綨𦅛𦂤𤦹𤦋𨧺鋥珢㻩璴𨭣𡢟㻡𤪳櫘珳珻㻖𤨾𤪔𡟙𤩦𠎧𡐤𤧥瑈𤤖炥𤥶銄珦鍟𠓾錱𨫎𨨖鎆𨯧𥗕䤵𨪂煫"], +["97a1","𤥃𠳿嚤𠘚𠯫𠲸唂秄𡟺緾𡛂𤩐𡡒䔮鐁㜊𨫀𤦭妰𡢿𡢃𧒄媡㛢𣵛㚰鉟婹𨪁𡡢鍴㳍𠪴䪖㦊僴㵩㵌𡎜煵䋻𨈘渏𩃤䓫浗𧹏灧沯㳖𣿭𣸭渂漌㵯𠏵畑㚼㓈䚀㻚䡱姄鉮䤾轁𨰜𦯀堒埈㛖𡑒烾𤍢𤩱𢿣𡊰𢎽梹楧𡎘𣓥𧯴𣛟𨪃𣟖𣏺𤲟樚𣚭𦲷萾䓟䓎"], +["9840","𦴦𦵑𦲂𦿞漗𧄉茽𡜺菭𦲀𧁓𡟛妉媂𡞳婡婱𡤅𤇼㜭姯𡜼㛇熎鎐暚𤊥婮娫𤊓樫𣻹𧜶𤑛𤋊焝𤉙𨧡侰𦴨峂𤓎𧹍𤎽樌𤉖𡌄炦焳𤏩㶥泟勇𤩏繥姫崯㷳彜𤩝𡟟綤萦"], +["98a1","咅𣫺𣌀𠈔坾𠣕𠘙㿥𡾞𪊶瀃𩅛嵰玏糓𨩙𩐠俈翧狍猐𧫴猸猹𥛶獁獈㺩𧬘遬燵𤣲珡臶㻊県㻑沢国琙琞琟㻢㻰㻴㻺瓓㼎㽓畂畭畲疍㽼痈痜㿀癍㿗癴㿜発𤽜熈嘣覀塩䀝睃䀹条䁅㗛瞘䁪䁯属瞾矋売砘点砜䂨砹硇硑硦葈𥔵礳栃礲䄃"], +["9940","䄉禑禙辻稆込䅧窑䆲窼艹䇄竏竛䇏両筢筬筻簒簛䉠䉺类粜䊌粸䊔糭输烀𠳏総緔緐緽羮羴犟䎗耠耥笹耮耱联㷌垴炠肷胩䏭脌猪脎脒畠脔䐁㬹腖腙腚"], +["99a1","䐓堺腼膄䐥膓䐭膥埯臁臤艔䒏芦艶苊苘苿䒰荗险榊萅烵葤惣蒈䔄蒾蓡蓸蔐蔸蕒䔻蕯蕰藠䕷虲蚒蚲蛯际螋䘆䘗袮裿褤襇覑𧥧訩訸誔誴豑賔賲贜䞘塟跃䟭仮踺嗘坔蹱嗵躰䠷軎転軤軭軲辷迁迊迌逳駄䢭飠鈓䤞鈨鉘鉫銱銮銿"], +["9a40","鋣鋫鋳鋴鋽鍃鎄鎭䥅䥑麿鐗匁鐝鐭鐾䥪鑔鑹锭関䦧间阳䧥枠䨤靀䨵鞲韂噔䫤惨颹䬙飱塄餎餙冴餜餷饂饝饢䭰駅䮝騼鬏窃魩鮁鯝鯱鯴䱭鰠㝯𡯂鵉鰺"], +["9aa1","黾噐鶓鶽鷀鷼银辶鹻麬麱麽黆铜黢黱黸竈齄𠂔𠊷𠎠椚铃妬𠓗塀铁㞹𠗕𠘕𠙶𡚺块煳𠫂𠫍𠮿呪吆𠯋咞𠯻𠰻𠱓𠱥𠱼惧𠲍噺𠲵𠳝𠳭𠵯𠶲𠷈楕鰯螥𠸄𠸎𠻗𠾐𠼭𠹳尠𠾼帋𡁜𡁏𡁶朞𡁻𡂈𡂖㙇𡂿𡃓𡄯𡄻卤蒭𡋣𡍵𡌶讁𡕷𡘙𡟃𡟇乸炻𡠭𡥪"], +["9b40","𡨭𡩅𡰪𡱰𡲬𡻈拃𡻕𡼕熘桕𢁅槩㛈𢉼𢏗𢏺𢜪𢡱𢥏苽𢥧𢦓𢫕覥𢫨辠𢬎鞸𢬿顇骽𢱌"], +["9b62","𢲈𢲷𥯨𢴈𢴒𢶷𢶕𢹂𢽴𢿌𣀳𣁦𣌟𣏞徱晈暿𧩹𣕧𣗳爁𤦺矗𣘚𣜖纇𠍆墵朎"], +["9ba1","椘𣪧𧙗𥿢𣸑𣺹𧗾𢂚䣐䪸𤄙𨪚𤋮𤌍𤀻𤌴𤎖𤩅𠗊凒𠘑妟𡺨㮾𣳿𤐄𤓖垈𤙴㦛𤜯𨗨𩧉㝢𢇃譞𨭎駖𤠒𤣻𤨕爉𤫀𠱸奥𤺥𤾆𠝹軚𥀬劏圿煱𥊙𥐙𣽊𤪧喼𥑆𥑮𦭒釔㑳𥔿𧘲𥕞䜘𥕢𥕦𥟇𤤿𥡝偦㓻𣏌惞𥤃䝼𨥈𥪮𥮉𥰆𡶐垡煑澶𦄂𧰒遖𦆲𤾚譢𦐂𦑊"], +["9c40","嵛𦯷輶𦒄𡤜諪𤧶𦒈𣿯𦔒䯀𦖿𦚵𢜛鑥𥟡憕娧晉侻嚹𤔡𦛼乪𤤴陖涏𦲽㘘襷𦞙𦡮𦐑𦡞營𦣇筂𩃀𠨑𦤦鄄𦤹穅鷰𦧺騦𦨭㙟𦑩𠀡禃𦨴𦭛崬𣔙菏𦮝䛐𦲤画补𦶮墶"], +["9ca1","㜜𢖍𧁋𧇍㱔𧊀𧊅銁𢅺𧊋錰𧋦𤧐氹钟𧑐𠻸蠧裵𢤦𨑳𡞱溸𤨪𡠠㦤㚹尐秣䔿暶𩲭𩢤襃𧟌𧡘囖䃟𡘊㦡𣜯𨃨𡏅熭荦𧧝𩆨婧䲷𧂯𨦫𧧽𧨊𧬋𧵦𤅺筃祾𨀉澵𪋟樃𨌘厢𦸇鎿栶靝𨅯𨀣𦦵𡏭𣈯𨁈嶅𨰰𨂃圕頣𨥉嶫𤦈斾槕叒𤪥𣾁㰑朶𨂐𨃴𨄮𡾡𨅏"], +["9d40","𨆉𨆯𨈚𨌆𨌯𨎊㗊𨑨𨚪䣺揦𨥖砈鉕𨦸䏲𨧧䏟𨧨𨭆𨯔姸𨰉輋𨿅𩃬筑𩄐𩄼㷷𩅞𤫊运犏嚋𩓧𩗩𩖰𩖸𩜲𩣑𩥉𩥪𩧃𩨨𩬎𩵚𩶛纟𩻸𩼣䲤镇𪊓熢𪋿䶑递𪗋䶜𠲜达嗁"], +["9da1","辺𢒰边𤪓䔉繿潖檱仪㓤𨬬𧢝㜺躀𡟵𨀤𨭬𨮙𧨾𦚯㷫𧙕𣲷𥘵𥥖亚𥺁𦉘嚿𠹭踎孭𣺈𤲞揞拐𡟶𡡻攰嘭𥱊吚𥌑㷆𩶘䱽嘢嘞罉𥻘奵𣵀蝰东𠿪𠵉𣚺脗鵞贘瘻鱅癎瞹鍅吲腈苷嘥脲萘肽嗪祢噃吖𠺝㗎嘅嗱曱𨋢㘭甴嗰喺咗啲𠱁𠲖廐𥅈𠹶𢱢"], +["9e40","𠺢麫絚嗞𡁵抝靭咔賍燶酶揼掹揾啩𢭃鱲𢺳冚㓟𠶧冧呍唞唓癦踭𦢊疱肶蠄螆裇膶萜𡃁䓬猄𤜆宐茋𦢓噻𢛴𧴯𤆣𧵳𦻐𧊶酰𡇙鈈𣳼𪚩𠺬𠻹牦𡲢䝎𤿂𧿹𠿫䃺"], +["9ea1","鱝攟𢶠䣳𤟠𩵼𠿬𠸊恢𧖣𠿭"], +["9ead","𦁈𡆇熣纎鵐业丄㕷嬍沲卧㚬㧜卽㚥𤘘墚𤭮舭呋垪𥪕𠥹"], +["9ec5","㩒𢑥獴𩺬䴉鯭𣳾𩼰䱛𤾩𩖞𩿞葜𣶶𧊲𦞳𣜠挮紥𣻷𣸬㨪逈勌㹴㙺䗩𠒎癀嫰𠺶硺𧼮墧䂿噼鮋嵴癔𪐴麅䳡痹㟻愙𣃚𤏲"], +["9ef5","噝𡊩垧𤥣𩸆刴𧂮㖭汊鵼"], +["9f40","籖鬹埞𡝬屓擓𩓐𦌵𧅤蚭𠴨𦴢𤫢𠵱"], +["9f4f","凾𡼏嶎霃𡷑麁遌笟鬂峑箣扨挵髿篏鬪籾鬮籂粆鰕篼鬉鼗鰛𤤾齚啳寃俽麘俲剠㸆勑坧偖妷帒韈鶫轜呩鞴饀鞺匬愰"], +["9fa1","椬叚鰊鴂䰻陁榀傦畆𡝭駚剳"], +["9fae","酙隁酜"], +["9fb2","酑𨺗捿𦴣櫊嘑醎畺抅𠏼獏籰𥰡𣳽"], +["9fc1","𤤙盖鮝个𠳔莾衂"], +["9fc9","届槀僭坺刟巵从氱𠇲伹咜哚劚趂㗾弌㗳"], +["9fdb","歒酼龥鮗頮颴骺麨麄煺笔"], +["9fe7","毺蠘罸"], +["9feb","嘠𪙊蹷齓"], +["9ff0","跔蹏鸜踁抂𨍽踨蹵竓𤩷稾磘泪詧瘇"], +["a040","𨩚鼦泎蟖痃𪊲硓咢贌狢獱謭猂瓱賫𤪻蘯徺袠䒷"], +["a055","𡠻𦸅"], +["a058","詾𢔛"], +["a05b","惽癧髗鵄鍮鮏蟵"], +["a063","蠏賷猬霡鮰㗖犲䰇籑饊𦅙慙䰄麖慽"], +["a073","坟慯抦戹拎㩜懢厪𣏵捤栂㗒"], +["a0a1","嵗𨯂迚𨸹"], +["a0a6","僙𡵆礆匲阸𠼻䁥"], +["a0ae","矾"], +["a0b0","糂𥼚糚稭聦聣絍甅瓲覔舚朌聢𧒆聛瓰脃眤覉𦟌畓𦻑螩蟎臈螌詉貭譃眫瓸蓚㘵榲趦"], +["a0d4","覩瑨涹蟁𤀑瓧㷛煶悤憜㳑煢恷"], +["a0e2","罱𨬭牐惩䭾删㰘𣳇𥻗𧙖𥔱𡥄𡋾𩤃𦷜𧂭峁𦆭𨨏𣙷𠃮𦡆𤼎䕢嬟𦍌齐麦𦉫"], +["a3c0","␀",31,"␡"], +["c6a1","①",9,"⑴",9,"ⅰ",9,"丶丿亅亠冂冖冫勹匸卩厶夊宀巛⼳广廴彐彡攴无疒癶辵隶¨ˆヽヾゝゞ〃仝々〆〇ー[]✽ぁ",23], +["c740","す",58,"ァアィイ"], +["c7a1","ゥ",81,"А",5,"ЁЖ",4], +["c840","Л",26,"ёж",25,"⇧↸↹㇏𠃌乚𠂊刂䒑"], +["c8a1","龰冈龱𧘇"], +["c8cd","¬¦'"㈱№℡゛゜⺀⺄⺆⺇⺈⺊⺌⺍⺕⺜⺝⺥⺧⺪⺬⺮⺶⺼⺾⻆⻊⻌⻍⻏⻖⻗⻞⻣"], +["c8f5","ʃɐɛɔɵœøŋʊɪ"], +["f9fe","■"], +["fa40","𠕇鋛𠗟𣿅蕌䊵珯况㙉𤥂𨧤鍄𡧛苮𣳈砼杄拟𤤳𨦪𠊠𦮳𡌅侫𢓭倈𦴩𧪄𣘀𤪱𢔓倩𠍾徤𠎀𠍇滛𠐟偽儁㑺儎顬㝃萖𤦤𠒇兠𣎴兪𠯿𢃼𠋥𢔰𠖎𣈳𡦃宂蝽𠖳𣲙冲冸"], +["faa1","鴴凉减凑㳜凓𤪦决凢卂凭菍椾𣜭彻刋刦刼劵剗劔効勅簕蕂勠蘍𦬓包𨫞啉滙𣾀𠥔𣿬匳卄𠯢泋𡜦栛珕恊㺪㣌𡛨燝䒢卭却𨚫卾卿𡖖𡘓矦厓𨪛厠厫厮玧𥝲㽙玜叁叅汉义埾叙㪫𠮏叠𣿫𢶣叶𠱷吓灹唫晗浛呭𦭓𠵴啝咏咤䞦𡜍𠻝㶴𠵍"], +["fb40","𨦼𢚘啇䳭启琗喆喩嘅𡣗𤀺䕒𤐵暳𡂴嘷曍𣊊暤暭噍噏磱囱鞇叾圀囯园𨭦㘣𡉏坆𤆥汮炋坂㚱𦱾埦𡐖堃𡑔𤍣堦𤯵塜墪㕡壠壜𡈼壻寿坃𪅐𤉸鏓㖡够梦㛃湙"], +["fba1","𡘾娤啓𡚒蔅姉𠵎𦲁𦴪𡟜姙𡟻𡞲𦶦浱𡠨𡛕姹𦹅媫婣㛦𤦩婷㜈媖瑥嫓𦾡𢕔㶅𡤑㜲𡚸広勐孶斈孼𧨎䀄䡝𠈄寕慠𡨴𥧌𠖥寳宝䴐尅𡭄尓珎尔𡲥𦬨屉䣝岅峩峯嶋𡷹𡸷崐崘嵆𡺤岺巗苼㠭𤤁𢁉𢅳芇㠶㯂帮檊幵幺𤒼𠳓厦亷廐厨𡝱帉廴𨒂"], +["fc40","廹廻㢠廼栾鐛弍𠇁弢㫞䢮𡌺强𦢈𢏐彘𢑱彣鞽𦹮彲鍀𨨶徧嶶㵟𥉐𡽪𧃸𢙨釖𠊞𨨩怱暅𡡷㥣㷇㘹垐𢞴祱㹀悞悤悳𤦂𤦏𧩓璤僡媠慤萤慂慈𦻒憁凴𠙖憇宪𣾷"], +["fca1","𢡟懓𨮝𩥝懐㤲𢦀𢣁怣慜攞掋𠄘担𡝰拕𢸍捬𤧟㨗搸揸𡎎𡟼撐澊𢸶頔𤂌𥜝擡擥鑻㩦携㩗敍漖𤨨𤨣斅敭敟𣁾斵𤥀䬷旑䃘𡠩无旣忟𣐀昘𣇷𣇸晄𣆤𣆥晋𠹵晧𥇦晳晴𡸽𣈱𨗴𣇈𥌓矅𢣷馤朂𤎜𤨡㬫槺𣟂杞杧杢𤇍𩃭柗䓩栢湐鈼栁𣏦𦶠桝"], +["fd40","𣑯槡樋𨫟楳棃𣗍椁椀㴲㨁𣘼㮀枬楡𨩊䋼椶榘㮡𠏉荣傐槹𣙙𢄪橅𣜃檝㯳枱櫈𩆜㰍欝𠤣惞欵歴𢟍溵𣫛𠎵𡥘㝀吡𣭚毡𣻼毜氷𢒋𤣱𦭑汚舦汹𣶼䓅𣶽𤆤𤤌𤤀"], +["fda1","𣳉㛥㳫𠴲鮃𣇹𢒑羏样𦴥𦶡𦷫涖浜湼漄𤥿𤂅𦹲蔳𦽴凇沜渝萮𨬡港𣸯瑓𣾂秌湏媑𣁋濸㜍澝𣸰滺𡒗𤀽䕕鏰潄潜㵎潴𩅰㴻澟𤅄濓𤂑𤅕𤀹𣿰𣾴𤄿凟𤅖𤅗𤅀𦇝灋灾炧炁烌烕烖烟䄄㷨熴熖𤉷焫煅媈煊煮岜𤍥煏鍢𤋁焬𤑚𤨧𤨢熺𨯨炽爎"], +["fe40","鑂爕夑鑃爤鍁𥘅爮牀𤥴梽牕牗㹕𣁄栍漽犂猪猫𤠣𨠫䣭𨠄猨献珏玪𠰺𦨮珉瑉𤇢𡛧𤨤昣㛅𤦷𤦍𤧻珷琕椃𤨦琹𠗃㻗瑜𢢭瑠𨺲瑇珤瑶莹瑬㜰瑴鏱樬璂䥓𤪌"], +["fea1","𤅟𤩹𨮏孆𨰃𡢞瓈𡦈甎瓩甞𨻙𡩋寗𨺬鎅畍畊畧畮𤾂㼄𤴓疎瑝疞疴瘂瘬癑癏癯癶𦏵皐臯㟸𦤑𦤎皡皥皷盌𦾟葢𥂝𥅽𡸜眞眦着撯𥈠睘𣊬瞯𨥤𨥨𡛁矴砉𡍶𤨒棊碯磇磓隥礮𥗠磗礴碱𧘌辸袄𨬫𦂃𢘜禆褀椂禀𥡗禝𧬹礼禩渪𧄦㺨秆𩄍秔"] +] diff --git a/node_modules/body-parser/node_modules/iconv-lite/encodings/tables/cp936.json b/node_modules/body-parser/node_modules/iconv-lite/encodings/tables/cp936.json new file mode 100644 index 0000000..49ddb9a --- /dev/null +++ b/node_modules/body-parser/node_modules/iconv-lite/encodings/tables/cp936.json @@ -0,0 +1,264 @@ +[ +["0","\u0000",127,"€"], +["8140","丂丄丅丆丏丒丗丟丠両丣並丩丮丯丱丳丵丷丼乀乁乂乄乆乊乑乕乗乚乛乢乣乤乥乧乨乪",5,"乲乴",9,"乿",6,"亇亊"], +["8180","亐亖亗亙亜亝亞亣亪亯亰亱亴亶亷亸亹亼亽亾仈仌仏仐仒仚仛仜仠仢仦仧仩仭仮仯仱仴仸仹仺仼仾伀伂",6,"伋伌伒",4,"伜伝伡伣伨伩伬伭伮伱伳伵伷伹伻伾",4,"佄佅佇",5,"佒佔佖佡佢佦佨佪佫佭佮佱佲併佷佸佹佺佽侀侁侂侅來侇侊侌侎侐侒侓侕侖侘侙侚侜侞侟価侢"], +["8240","侤侫侭侰",4,"侶",8,"俀俁係俆俇俈俉俋俌俍俒",4,"俙俛俠俢俤俥俧俫俬俰俲俴俵俶俷俹俻俼俽俿",11], +["8280","個倎倐們倓倕倖倗倛倝倞倠倢倣値倧倫倯",10,"倻倽倿偀偁偂偄偅偆偉偊偋偍偐",4,"偖偗偘偙偛偝",7,"偦",5,"偭",8,"偸偹偺偼偽傁傂傃傄傆傇傉傊傋傌傎",20,"傤傦傪傫傭",4,"傳",6,"傼"], +["8340","傽",17,"僐",5,"僗僘僙僛",10,"僨僩僪僫僯僰僱僲僴僶",4,"僼",9,"儈"], +["8380","儉儊儌",5,"儓",13,"儢",28,"兂兇兊兌兎兏児兒兓兗兘兙兛兝",4,"兣兤兦內兩兪兯兲兺兾兿冃冄円冇冊冋冎冏冐冑冓冔冘冚冝冞冟冡冣冦",4,"冭冮冴冸冹冺冾冿凁凂凃凅凈凊凍凎凐凒",5], +["8440","凘凙凚凜凞凟凢凣凥",5,"凬凮凱凲凴凷凾刄刅刉刋刌刏刐刓刔刕刜刞刟刡刢刣別刦刧刪刬刯刱刲刴刵刼刾剄",5,"剋剎剏剒剓剕剗剘"], +["8480","剙剚剛剝剟剠剢剣剤剦剨剫剬剭剮剰剱剳",9,"剾劀劃",4,"劉",6,"劑劒劔",6,"劜劤劥劦劧劮劯劰労",9,"勀勁勂勄勅勆勈勊勌勍勎勏勑勓勔動勗務",5,"勠勡勢勣勥",10,"勱",7,"勻勼勽匁匂匃匄匇匉匊匋匌匎"], +["8540","匑匒匓匔匘匛匜匞匟匢匤匥匧匨匩匫匬匭匯",9,"匼匽區卂卄卆卋卌卍卐協単卙卛卝卥卨卪卬卭卲卶卹卻卼卽卾厀厁厃厇厈厊厎厏"], +["8580","厐",4,"厖厗厙厛厜厞厠厡厤厧厪厫厬厭厯",6,"厷厸厹厺厼厽厾叀參",4,"収叏叐叒叓叕叚叜叝叞叡叢叧叴叺叾叿吀吂吅吇吋吔吘吙吚吜吢吤吥吪吰吳吶吷吺吽吿呁呂呄呅呇呉呌呍呎呏呑呚呝",4,"呣呥呧呩",7,"呴呹呺呾呿咁咃咅咇咈咉咊咍咑咓咗咘咜咞咟咠咡"], +["8640","咢咥咮咰咲咵咶咷咹咺咼咾哃哅哊哋哖哘哛哠",4,"哫哬哯哰哱哴",5,"哻哾唀唂唃唄唅唈唊",4,"唒唓唕",5,"唜唝唞唟唡唥唦"], +["8680","唨唩唫唭唲唴唵唶唸唹唺唻唽啀啂啅啇啈啋",4,"啑啒啓啔啗",4,"啝啞啟啠啢啣啨啩啫啯",5,"啹啺啽啿喅喆喌喍喎喐喒喓喕喖喗喚喛喞喠",6,"喨",8,"喲喴営喸喺喼喿",4,"嗆嗇嗈嗊嗋嗎嗏嗐嗕嗗",4,"嗞嗠嗢嗧嗩嗭嗮嗰嗱嗴嗶嗸",4,"嗿嘂嘃嘄嘅"], +["8740","嘆嘇嘊嘋嘍嘐",7,"嘙嘚嘜嘝嘠嘡嘢嘥嘦嘨嘩嘪嘫嘮嘯嘰嘳嘵嘷嘸嘺嘼嘽嘾噀",11,"噏",4,"噕噖噚噛噝",4], +["8780","噣噥噦噧噭噮噯噰噲噳噴噵噷噸噹噺噽",7,"嚇",6,"嚐嚑嚒嚔",14,"嚤",10,"嚰",6,"嚸嚹嚺嚻嚽",12,"囋",8,"囕囖囘囙囜団囥",5,"囬囮囯囲図囶囷囸囻囼圀圁圂圅圇國",6], +["8840","園",9,"圝圞圠圡圢圤圥圦圧圫圱圲圴",4,"圼圽圿坁坃坄坅坆坈坉坋坒",4,"坘坙坢坣坥坧坬坮坰坱坲坴坵坸坹坺坽坾坿垀"], +["8880","垁垇垈垉垊垍",4,"垔",6,"垜垝垞垟垥垨垪垬垯垰垱垳垵垶垷垹",8,"埄",6,"埌埍埐埑埓埖埗埛埜埞埡埢埣埥",7,"埮埰埱埲埳埵埶執埻埼埾埿堁堃堄堅堈堉堊堌堎堏堐堒堓堔堖堗堘堚堛堜堝堟堢堣堥",4,"堫",4,"報堲堳場堶",7], +["8940","堾",5,"塅",6,"塎塏塐塒塓塕塖塗塙",4,"塟",5,"塦",4,"塭",16,"塿墂墄墆墇墈墊墋墌"], +["8980","墍",4,"墔",4,"墛墜墝墠",7,"墪",17,"墽墾墿壀壂壃壄壆",10,"壒壓壔壖",13,"壥",5,"壭壯壱売壴壵壷壸壺",7,"夃夅夆夈",4,"夎夐夑夒夓夗夘夛夝夞夠夡夢夣夦夨夬夰夲夳夵夶夻"], +["8a40","夽夾夿奀奃奅奆奊奌奍奐奒奓奙奛",4,"奡奣奤奦",12,"奵奷奺奻奼奾奿妀妅妉妋妌妎妏妐妑妔妕妘妚妛妜妝妟妠妡妢妦"], +["8a80","妧妬妭妰妱妳",5,"妺妼妽妿",6,"姇姈姉姌姍姎姏姕姖姙姛姞",4,"姤姦姧姩姪姫姭",11,"姺姼姽姾娀娂娊娋娍娎娏娐娒娔娕娖娗娙娚娛娝娞娡娢娤娦娧娨娪",6,"娳娵娷",4,"娽娾娿婁",4,"婇婈婋",9,"婖婗婘婙婛",5], +["8b40","婡婣婤婥婦婨婩婫",8,"婸婹婻婼婽婾媀",17,"媓",6,"媜",13,"媫媬"], +["8b80","媭",4,"媴媶媷媹",4,"媿嫀嫃",5,"嫊嫋嫍",4,"嫓嫕嫗嫙嫚嫛嫝嫞嫟嫢嫤嫥嫧嫨嫪嫬",4,"嫲",22,"嬊",11,"嬘",25,"嬳嬵嬶嬸",7,"孁",6], +["8c40","孈",7,"孒孖孞孠孡孧孨孫孭孮孯孲孴孶孷學孹孻孼孾孿宂宆宊宍宎宐宑宒宔宖実宧宨宩宬宭宮宯宱宲宷宺宻宼寀寁寃寈寉寊寋寍寎寏"], +["8c80","寑寔",8,"寠寢寣實寧審",4,"寯寱",6,"寽対尀専尃尅將專尋尌對導尐尒尓尗尙尛尞尟尠尡尣尦尨尩尪尫尭尮尯尰尲尳尵尶尷屃屄屆屇屌屍屒屓屔屖屗屘屚屛屜屝屟屢層屧",6,"屰屲",6,"屻屼屽屾岀岃",4,"岉岊岋岎岏岒岓岕岝",4,"岤",4], +["8d40","岪岮岯岰岲岴岶岹岺岻岼岾峀峂峃峅",5,"峌",5,"峓",5,"峚",6,"峢峣峧峩峫峬峮峯峱",9,"峼",4], +["8d80","崁崄崅崈",5,"崏",4,"崕崗崘崙崚崜崝崟",4,"崥崨崪崫崬崯",4,"崵",7,"崿",7,"嵈嵉嵍",10,"嵙嵚嵜嵞",10,"嵪嵭嵮嵰嵱嵲嵳嵵",12,"嶃",21,"嶚嶛嶜嶞嶟嶠"], +["8e40","嶡",21,"嶸",12,"巆",6,"巎",12,"巜巟巠巣巤巪巬巭"], +["8e80","巰巵巶巸",4,"巿帀帄帇帉帊帋帍帎帒帓帗帞",7,"帨",4,"帯帰帲",4,"帹帺帾帿幀幁幃幆",5,"幍",6,"幖",4,"幜幝幟幠幣",14,"幵幷幹幾庁庂広庅庈庉庌庍庎庒庘庛庝庡庢庣庤庨",4,"庮",4,"庴庺庻庼庽庿",6], +["8f40","廆廇廈廋",5,"廔廕廗廘廙廚廜",11,"廩廫",8,"廵廸廹廻廼廽弅弆弇弉弌弍弎弐弒弔弖弙弚弜弝弞弡弢弣弤"], +["8f80","弨弫弬弮弰弲",6,"弻弽弾弿彁",14,"彑彔彙彚彛彜彞彟彠彣彥彧彨彫彮彯彲彴彵彶彸彺彽彾彿徃徆徍徎徏徑従徔徖徚徛徝從徟徠徢",5,"復徫徬徯",5,"徶徸徹徺徻徾",4,"忇忈忊忋忎忓忔忕忚忛応忞忟忢忣忥忦忨忩忬忯忰忲忳忴忶忷忹忺忼怇"], +["9040","怈怉怋怌怐怑怓怗怘怚怞怟怢怣怤怬怭怮怰",4,"怶",4,"怽怾恀恄",6,"恌恎恏恑恓恔恖恗恘恛恜恞恟恠恡恥恦恮恱恲恴恵恷恾悀"], +["9080","悁悂悅悆悇悈悊悋悎悏悐悑悓悕悗悘悙悜悞悡悢悤悥悧悩悪悮悰悳悵悶悷悹悺悽",7,"惇惈惉惌",4,"惒惓惔惖惗惙惛惞惡",4,"惪惱惲惵惷惸惻",4,"愂愃愄愅愇愊愋愌愐",4,"愖愗愘愙愛愜愝愞愡愢愥愨愩愪愬",18,"慀",6], +["9140","慇慉態慍慏慐慒慓慔慖",6,"慞慟慠慡慣慤慥慦慩",6,"慱慲慳慴慶慸",18,"憌憍憏",4,"憕"], +["9180","憖",6,"憞",8,"憪憫憭",9,"憸",5,"憿懀懁懃",4,"應懌",4,"懓懕",16,"懧",13,"懶",8,"戀",5,"戇戉戓戔戙戜戝戞戠戣戦戧戨戩戫戭戯戰戱戲戵戶戸",4,"扂扄扅扆扊"], +["9240","扏扐払扖扗扙扚扜",6,"扤扥扨扱扲扴扵扷扸扺扻扽抁抂抃抅抆抇抈抋",5,"抔抙抜抝択抣抦抧抩抪抭抮抯抰抲抳抴抶抷抸抺抾拀拁"], +["9280","拃拋拏拑拕拝拞拠拡拤拪拫拰拲拵拸拹拺拻挀挃挄挅挆挊挋挌挍挏挐挒挓挔挕挗挘挙挜挦挧挩挬挭挮挰挱挳",5,"挻挼挾挿捀捁捄捇捈捊捑捒捓捔捖",7,"捠捤捥捦捨捪捫捬捯捰捲捳捴捵捸捹捼捽捾捿掁掃掄掅掆掋掍掑掓掔掕掗掙",6,"採掤掦掫掯掱掲掵掶掹掻掽掿揀"], +["9340","揁揂揃揅揇揈揊揋揌揑揓揔揕揗",6,"揟揢揤",4,"揫揬揮揯揰揱揳揵揷揹揺揻揼揾搃搄搆",4,"損搎搑搒搕",5,"搝搟搢搣搤"], +["9380","搥搧搨搩搫搮",5,"搵",4,"搻搼搾摀摂摃摉摋",6,"摓摕摖摗摙",4,"摟",7,"摨摪摫摬摮",9,"摻",6,"撃撆撈",8,"撓撔撗撘撚撛撜撝撟",4,"撥撦撧撨撪撫撯撱撲撳撴撶撹撻撽撾撿擁擃擄擆",6,"擏擑擓擔擕擖擙據"], +["9440","擛擜擝擟擠擡擣擥擧",24,"攁",7,"攊",7,"攓",4,"攙",8], +["9480","攢攣攤攦",4,"攬攭攰攱攲攳攷攺攼攽敀",4,"敆敇敊敋敍敎敐敒敓敔敗敘敚敜敟敠敡敤敥敧敨敩敪敭敮敯敱敳敵敶數",14,"斈斉斊斍斎斏斒斔斕斖斘斚斝斞斠斢斣斦斨斪斬斮斱",7,"斺斻斾斿旀旂旇旈旉旊旍旐旑旓旔旕旘",7,"旡旣旤旪旫"], +["9540","旲旳旴旵旸旹旻",4,"昁昄昅昇昈昉昋昍昐昑昒昖昗昘昚昛昜昞昡昢昣昤昦昩昪昫昬昮昰昲昳昷",4,"昽昿晀時晄",6,"晍晎晐晑晘"], +["9580","晙晛晜晝晞晠晢晣晥晧晩",4,"晱晲晳晵晸晹晻晼晽晿暀暁暃暅暆暈暉暊暋暍暎暏暐暒暓暔暕暘",4,"暞",8,"暩",4,"暯",4,"暵暶暷暸暺暻暼暽暿",25,"曚曞",7,"曧曨曪",5,"曱曵曶書曺曻曽朁朂會"], +["9640","朄朅朆朇朌朎朏朑朒朓朖朘朙朚朜朞朠",5,"朧朩朮朰朲朳朶朷朸朹朻朼朾朿杁杄杅杇杊杋杍杒杔杕杗",4,"杝杢杣杤杦杧杫杬杮東杴杶"], +["9680","杸杹杺杻杽枀枂枃枅枆枈枊枌枍枎枏枑枒枓枔枖枙枛枟枠枡枤枦枩枬枮枱枲枴枹",7,"柂柅",9,"柕柖柗柛柟柡柣柤柦柧柨柪柫柭柮柲柵",7,"柾栁栂栃栄栆栍栐栒栔栕栘",4,"栞栟栠栢",6,"栫",6,"栴栵栶栺栻栿桇桋桍桏桒桖",5], +["9740","桜桝桞桟桪桬",7,"桵桸",8,"梂梄梇",7,"梐梑梒梔梕梖梘",9,"梣梤梥梩梪梫梬梮梱梲梴梶梷梸"], +["9780","梹",6,"棁棃",5,"棊棌棎棏棐棑棓棔棖棗棙棛",4,"棡棢棤",9,"棯棲棳棴棶棷棸棻棽棾棿椀椂椃椄椆",4,"椌椏椑椓",11,"椡椢椣椥",7,"椮椯椱椲椳椵椶椷椸椺椻椼椾楀楁楃",16,"楕楖楘楙楛楜楟"], +["9840","楡楢楤楥楧楨楩楪楬業楯楰楲",4,"楺楻楽楾楿榁榃榅榊榋榌榎",5,"榖榗榙榚榝",9,"榩榪榬榮榯榰榲榳榵榶榸榹榺榼榽"], +["9880","榾榿槀槂",7,"構槍槏槑槒槓槕",5,"槜槝槞槡",11,"槮槯槰槱槳",9,"槾樀",9,"樋",11,"標",5,"樠樢",5,"権樫樬樭樮樰樲樳樴樶",6,"樿",4,"橅橆橈",7,"橑",6,"橚"], +["9940","橜",4,"橢橣橤橦",10,"橲",6,"橺橻橽橾橿檁檂檃檅",8,"檏檒",4,"檘",7,"檡",5], +["9980","檧檨檪檭",114,"欥欦欨",6], +["9a40","欯欰欱欳欴欵欶欸欻欼欽欿歀歁歂歄歅歈歊歋歍",11,"歚",7,"歨歩歫",13,"歺歽歾歿殀殅殈"], +["9a80","殌殎殏殐殑殔殕殗殘殙殜",4,"殢",7,"殫",7,"殶殸",6,"毀毃毄毆",4,"毌毎毐毑毘毚毜",4,"毢",7,"毬毭毮毰毱毲毴毶毷毸毺毻毼毾",6,"氈",4,"氎氒気氜氝氞氠氣氥氫氬氭氱氳氶氷氹氺氻氼氾氿汃汄汅汈汋",4,"汑汒汓汖汘"], +["9b40","汙汚汢汣汥汦汧汫",4,"汱汳汵汷汸決汻汼汿沀沄沇沊沋沍沎沑沒沕沖沗沘沚沜沝沞沠沢沨沬沯沰沴沵沶沷沺泀況泂泃泆泇泈泋泍泎泏泑泒泘"], +["9b80","泙泚泜泝泟泤泦泧泩泬泭泲泴泹泿洀洂洃洅洆洈洉洊洍洏洐洑洓洔洕洖洘洜洝洟",5,"洦洨洩洬洭洯洰洴洶洷洸洺洿浀浂浄浉浌浐浕浖浗浘浛浝浟浡浢浤浥浧浨浫浬浭浰浱浲浳浵浶浹浺浻浽",4,"涃涄涆涇涊涋涍涏涐涒涖",4,"涜涢涥涬涭涰涱涳涴涶涷涹",5,"淁淂淃淈淉淊"], +["9c40","淍淎淏淐淒淓淔淕淗淚淛淜淟淢淣淥淧淨淩淪淭淯淰淲淴淵淶淸淺淽",7,"渆渇済渉渋渏渒渓渕渘渙減渜渞渟渢渦渧渨渪測渮渰渱渳渵"], +["9c80","渶渷渹渻",7,"湅",7,"湏湐湑湒湕湗湙湚湜湝湞湠",10,"湬湭湯",14,"満溁溂溄溇溈溊",4,"溑",6,"溙溚溛溝溞溠溡溣溤溦溨溩溫溬溭溮溰溳溵溸溹溼溾溿滀滃滄滅滆滈滉滊滌滍滎滐滒滖滘滙滛滜滝滣滧滪",5], +["9d40","滰滱滲滳滵滶滷滸滺",7,"漃漄漅漇漈漊",4,"漐漑漒漖",9,"漡漢漣漥漦漧漨漬漮漰漲漴漵漷",6,"漿潀潁潂"], +["9d80","潃潄潅潈潉潊潌潎",9,"潙潚潛潝潟潠潡潣潤潥潧",5,"潯潰潱潳潵潶潷潹潻潽",6,"澅澆澇澊澋澏",12,"澝澞澟澠澢",4,"澨",10,"澴澵澷澸澺",5,"濁濃",5,"濊",6,"濓",10,"濟濢濣濤濥"], +["9e40","濦",7,"濰",32,"瀒",7,"瀜",6,"瀤",6], +["9e80","瀫",9,"瀶瀷瀸瀺",17,"灍灎灐",13,"灟",11,"灮灱灲灳灴灷灹灺灻災炁炂炃炄炆炇炈炋炌炍炏炐炑炓炗炘炚炛炞",12,"炰炲炴炵炶為炾炿烄烅烆烇烉烋",12,"烚"], +["9f40","烜烝烞烠烡烢烣烥烪烮烰",6,"烸烺烻烼烾",10,"焋",4,"焑焒焔焗焛",10,"焧",7,"焲焳焴"], +["9f80","焵焷",13,"煆煇煈煉煋煍煏",12,"煝煟",4,"煥煩",4,"煯煰煱煴煵煶煷煹煻煼煾",5,"熅",4,"熋熌熍熎熐熑熒熓熕熖熗熚",4,"熡",6,"熩熪熫熭",5,"熴熶熷熸熺",8,"燄",9,"燏",4], +["a040","燖",9,"燡燢燣燤燦燨",5,"燯",9,"燺",11,"爇",19], +["a080","爛爜爞",9,"爩爫爭爮爯爲爳爴爺爼爾牀",6,"牉牊牋牎牏牐牑牓牔牕牗牘牚牜牞牠牣牤牥牨牪牫牬牭牰牱牳牴牶牷牸牻牼牽犂犃犅",4,"犌犎犐犑犓",11,"犠",11,"犮犱犲犳犵犺",6,"狅狆狇狉狊狋狌狏狑狓狔狕狖狘狚狛"], +["a1a1"," 、。·ˉˇ¨〃々—~‖…‘’“”〔〕〈",7,"〖〗【】±×÷∶∧∨∑∏∪∩∈∷√⊥∥∠⌒⊙∫∮≡≌≈∽∝≠≮≯≤≥∞∵∴♂♀°′″℃$¤¢£‰§№☆★○●◎◇◆□■△▲※→←↑↓〓"], +["a2a1","ⅰ",9], +["a2b1","⒈",19,"⑴",19,"①",9], +["a2e5","㈠",9], +["a2f1","Ⅰ",11], +["a3a1","!"#¥%",88," ̄"], +["a4a1","ぁ",82], +["a5a1","ァ",85], +["a6a1","Α",16,"Σ",6], +["a6c1","α",16,"σ",6], +["a6e0","︵︶︹︺︿﹀︽︾﹁﹂﹃﹄"], +["a6ee","︻︼︷︸︱"], +["a6f4","︳︴"], +["a7a1","А",5,"ЁЖ",25], +["a7d1","а",5,"ёж",25], +["a840","ˊˋ˙–―‥‵℅℉↖↗↘↙∕∟∣≒≦≧⊿═",35,"▁",6], +["a880","█",7,"▓▔▕▼▽◢◣◤◥☉⊕〒〝〞"], +["a8a1","āáǎàēéěèīíǐìōóǒòūúǔùǖǘǚǜüêɑ"], +["a8bd","ńň"], +["a8c0","ɡ"], +["a8c5","ㄅ",36], +["a940","〡",8,"㊣㎎㎏㎜㎝㎞㎡㏄㏎㏑㏒㏕︰¬¦"], +["a959","℡㈱"], +["a95c","‐"], +["a960","ー゛゜ヽヾ〆ゝゞ﹉",9,"﹔﹕﹖﹗﹙",8], +["a980","﹢",4,"﹨﹩﹪﹫"], +["a996","〇"], +["a9a4","─",75], +["aa40","狜狝狟狢",5,"狪狫狵狶狹狽狾狿猀猂猄",5,"猋猌猍猏猐猑猒猔猘猙猚猟猠猣猤猦猧猨猭猯猰猲猳猵猶猺猻猼猽獀",8], +["aa80","獉獊獋獌獎獏獑獓獔獕獖獘",7,"獡",10,"獮獰獱"], +["ab40","獲",11,"獿",4,"玅玆玈玊玌玍玏玐玒玓玔玕玗玘玙玚玜玝玞玠玡玣",5,"玪玬玭玱玴玵玶玸玹玼玽玾玿珁珃",4], +["ab80","珋珌珎珒",6,"珚珛珜珝珟珡珢珣珤珦珨珪珫珬珮珯珰珱珳",4], +["ac40","珸",10,"琄琇琈琋琌琍琎琑",8,"琜",5,"琣琤琧琩琫琭琯琱琲琷",4,"琽琾琿瑀瑂",11], +["ac80","瑎",6,"瑖瑘瑝瑠",12,"瑮瑯瑱",4,"瑸瑹瑺"], +["ad40","瑻瑼瑽瑿璂璄璅璆璈璉璊璌璍璏璑",10,"璝璟",7,"璪",15,"璻",12], +["ad80","瓈",9,"瓓",8,"瓝瓟瓡瓥瓧",6,"瓰瓱瓲"], +["ae40","瓳瓵瓸",6,"甀甁甂甃甅",7,"甎甐甒甔甕甖甗甛甝甞甠",4,"甦甧甪甮甴甶甹甼甽甿畁畂畃畄畆畇畉畊畍畐畑畒畓畕畖畗畘"], +["ae80","畝",7,"畧畨畩畫",6,"畳畵當畷畺",4,"疀疁疂疄疅疇"], +["af40","疈疉疊疌疍疎疐疓疕疘疛疜疞疢疦",4,"疭疶疷疺疻疿痀痁痆痋痌痎痏痐痑痓痗痙痚痜痝痟痠痡痥痩痬痭痮痯痲痳痵痶痷痸痺痻痽痾瘂瘄瘆瘇"], +["af80","瘈瘉瘋瘍瘎瘏瘑瘒瘓瘔瘖瘚瘜瘝瘞瘡瘣瘧瘨瘬瘮瘯瘱瘲瘶瘷瘹瘺瘻瘽癁療癄"], +["b040","癅",6,"癎",5,"癕癗",4,"癝癟癠癡癢癤",6,"癬癭癮癰",7,"癹発發癿皀皁皃皅皉皊皌皍皏皐皒皔皕皗皘皚皛"], +["b080","皜",7,"皥",8,"皯皰皳皵",9,"盀盁盃啊阿埃挨哎唉哀皑癌蔼矮艾碍爱隘鞍氨安俺按暗岸胺案肮昂盎凹敖熬翱袄傲奥懊澳芭捌扒叭吧笆八疤巴拔跋靶把耙坝霸罢爸白柏百摆佰败拜稗斑班搬扳般颁板版扮拌伴瓣半办绊邦帮梆榜膀绑棒磅蚌镑傍谤苞胞包褒剥"], +["b140","盄盇盉盋盌盓盕盙盚盜盝盞盠",4,"盦",7,"盰盳盵盶盷盺盻盽盿眀眂眃眅眆眊県眎",10,"眛眜眝眞眡眣眤眥眧眪眫"], +["b180","眬眮眰",4,"眹眻眽眾眿睂睄睅睆睈",7,"睒",7,"睜薄雹保堡饱宝抱报暴豹鲍爆杯碑悲卑北辈背贝钡倍狈备惫焙被奔苯本笨崩绷甭泵蹦迸逼鼻比鄙笔彼碧蓖蔽毕毙毖币庇痹闭敝弊必辟壁臂避陛鞭边编贬扁便变卞辨辩辫遍标彪膘表鳖憋别瘪彬斌濒滨宾摈兵冰柄丙秉饼炳"], +["b240","睝睞睟睠睤睧睩睪睭",11,"睺睻睼瞁瞂瞃瞆",5,"瞏瞐瞓",11,"瞡瞣瞤瞦瞨瞫瞭瞮瞯瞱瞲瞴瞶",4], +["b280","瞼瞾矀",12,"矎",8,"矘矙矚矝",4,"矤病并玻菠播拨钵波博勃搏铂箔伯帛舶脖膊渤泊驳捕卜哺补埠不布步簿部怖擦猜裁材才财睬踩采彩菜蔡餐参蚕残惭惨灿苍舱仓沧藏操糙槽曹草厕策侧册测层蹭插叉茬茶查碴搽察岔差诧拆柴豺搀掺蝉馋谗缠铲产阐颤昌猖"], +["b340","矦矨矪矯矰矱矲矴矵矷矹矺矻矼砃",5,"砊砋砎砏砐砓砕砙砛砞砠砡砢砤砨砪砫砮砯砱砲砳砵砶砽砿硁硂硃硄硆硈硉硊硋硍硏硑硓硔硘硙硚"], +["b380","硛硜硞",11,"硯",7,"硸硹硺硻硽",6,"场尝常长偿肠厂敞畅唱倡超抄钞朝嘲潮巢吵炒车扯撤掣彻澈郴臣辰尘晨忱沉陈趁衬撑称城橙成呈乘程惩澄诚承逞骋秤吃痴持匙池迟弛驰耻齿侈尺赤翅斥炽充冲虫崇宠抽酬畴踌稠愁筹仇绸瞅丑臭初出橱厨躇锄雏滁除楚"], +["b440","碄碅碆碈碊碋碏碐碒碔碕碖碙碝碞碠碢碤碦碨",7,"碵碶碷碸確碻碼碽碿磀磂磃磄磆磇磈磌磍磎磏磑磒磓磖磗磘磚",9], +["b480","磤磥磦磧磩磪磫磭",4,"磳磵磶磸磹磻",5,"礂礃礄礆",6,"础储矗搐触处揣川穿椽传船喘串疮窗幢床闯创吹炊捶锤垂春椿醇唇淳纯蠢戳绰疵茨磁雌辞慈瓷词此刺赐次聪葱囱匆从丛凑粗醋簇促蹿篡窜摧崔催脆瘁粹淬翠村存寸磋撮搓措挫错搭达答瘩打大呆歹傣戴带殆代贷袋待逮"], +["b540","礍",5,"礔",9,"礟",4,"礥",14,"礵",4,"礽礿祂祃祄祅祇祊",8,"祔祕祘祙祡祣"], +["b580","祤祦祩祪祫祬祮祰",6,"祹祻",4,"禂禃禆禇禈禉禋禌禍禎禐禑禒怠耽担丹单郸掸胆旦氮但惮淡诞弹蛋当挡党荡档刀捣蹈倒岛祷导到稻悼道盗德得的蹬灯登等瞪凳邓堤低滴迪敌笛狄涤翟嫡抵底地蒂第帝弟递缔颠掂滇碘点典靛垫电佃甸店惦奠淀殿碉叼雕凋刁掉吊钓调跌爹碟蝶迭谍叠"], +["b640","禓",6,"禛",11,"禨",10,"禴",4,"禼禿秂秄秅秇秈秊秌秎秏秐秓秔秖秗秙",5,"秠秡秢秥秨秪"], +["b680","秬秮秱",6,"秹秺秼秾秿稁稄稅稇稈稉稊稌稏",4,"稕稖稘稙稛稜丁盯叮钉顶鼎锭定订丢东冬董懂动栋侗恫冻洞兜抖斗陡豆逗痘都督毒犊独读堵睹赌杜镀肚度渡妒端短锻段断缎堆兑队对墩吨蹲敦顿囤钝盾遁掇哆多夺垛躲朵跺舵剁惰堕蛾峨鹅俄额讹娥恶厄扼遏鄂饿恩而儿耳尔饵洱二"], +["b740","稝稟稡稢稤",14,"稴稵稶稸稺稾穀",5,"穇",9,"穒",4,"穘",16], +["b780","穩",6,"穱穲穳穵穻穼穽穾窂窅窇窉窊窋窌窎窏窐窓窔窙窚窛窞窡窢贰发罚筏伐乏阀法珐藩帆番翻樊矾钒繁凡烦反返范贩犯饭泛坊芳方肪房防妨仿访纺放菲非啡飞肥匪诽吠肺废沸费芬酚吩氛分纷坟焚汾粉奋份忿愤粪丰封枫蜂峰锋风疯烽逢冯缝讽奉凤佛否夫敷肤孵扶拂辐幅氟符伏俘服"], +["b840","窣窤窧窩窪窫窮",4,"窴",10,"竀",10,"竌",9,"竗竘竚竛竜竝竡竢竤竧",5,"竮竰竱竲竳"], +["b880","竴",4,"竻竼竾笀笁笂笅笇笉笌笍笎笐笒笓笖笗笘笚笜笝笟笡笢笣笧笩笭浮涪福袱弗甫抚辅俯釜斧脯腑府腐赴副覆赋复傅付阜父腹负富讣附妇缚咐噶嘎该改概钙盖溉干甘杆柑竿肝赶感秆敢赣冈刚钢缸肛纲岗港杠篙皋高膏羔糕搞镐稿告哥歌搁戈鸽胳疙割革葛格蛤阁隔铬个各给根跟耕更庚羹"], +["b940","笯笰笲笴笵笶笷笹笻笽笿",5,"筆筈筊筍筎筓筕筗筙筜筞筟筡筣",10,"筯筰筳筴筶筸筺筼筽筿箁箂箃箄箆",6,"箎箏"], +["b980","箑箒箓箖箘箙箚箛箞箟箠箣箤箥箮箯箰箲箳箵箶箷箹",7,"篂篃範埂耿梗工攻功恭龚供躬公宫弓巩汞拱贡共钩勾沟苟狗垢构购够辜菇咕箍估沽孤姑鼓古蛊骨谷股故顾固雇刮瓜剐寡挂褂乖拐怪棺关官冠观管馆罐惯灌贯光广逛瑰规圭硅归龟闺轨鬼诡癸桂柜跪贵刽辊滚棍锅郭国果裹过哈"], +["ba40","篅篈築篊篋篍篎篏篐篒篔",4,"篛篜篞篟篠篢篣篤篧篨篩篫篬篭篯篰篲",4,"篸篹篺篻篽篿",7,"簈簉簊簍簎簐",5,"簗簘簙"], +["ba80","簚",4,"簠",5,"簨簩簫",12,"簹",5,"籂骸孩海氦亥害骇酣憨邯韩含涵寒函喊罕翰撼捍旱憾悍焊汗汉夯杭航壕嚎豪毫郝好耗号浩呵喝荷菏核禾和何合盒貉阂河涸赫褐鹤贺嘿黑痕很狠恨哼亨横衡恒轰哄烘虹鸿洪宏弘红喉侯猴吼厚候后呼乎忽瑚壶葫胡蝴狐糊湖"], +["bb40","籃",9,"籎",36,"籵",5,"籾",9], +["bb80","粈粊",6,"粓粔粖粙粚粛粠粡粣粦粧粨粩粫粬粭粯粰粴",4,"粺粻弧虎唬护互沪户花哗华猾滑画划化话槐徊怀淮坏欢环桓还缓换患唤痪豢焕涣宦幻荒慌黄磺蝗簧皇凰惶煌晃幌恍谎灰挥辉徽恢蛔回毁悔慧卉惠晦贿秽会烩汇讳诲绘荤昏婚魂浑混豁活伙火获或惑霍货祸击圾基机畸稽积箕"], +["bc40","粿糀糂糃糄糆糉糋糎",6,"糘糚糛糝糞糡",6,"糩",5,"糰",7,"糹糺糼",13,"紋",5], +["bc80","紑",14,"紡紣紤紥紦紨紩紪紬紭紮細",6,"肌饥迹激讥鸡姬绩缉吉极棘辑籍集及急疾汲即嫉级挤几脊己蓟技冀季伎祭剂悸济寄寂计记既忌际妓继纪嘉枷夹佳家加荚颊贾甲钾假稼价架驾嫁歼监坚尖笺间煎兼肩艰奸缄茧检柬碱硷拣捡简俭剪减荐槛鉴践贱见键箭件"], +["bd40","紷",54,"絯",7], +["bd80","絸",32,"健舰剑饯渐溅涧建僵姜将浆江疆蒋桨奖讲匠酱降蕉椒礁焦胶交郊浇骄娇嚼搅铰矫侥脚狡角饺缴绞剿教酵轿较叫窖揭接皆秸街阶截劫节桔杰捷睫竭洁结解姐戒藉芥界借介疥诫届巾筋斤金今津襟紧锦仅谨进靳晋禁近烬浸"], +["be40","継",12,"綧",6,"綯",42], +["be80","線",32,"尽劲荆兢茎睛晶鲸京惊精粳经井警景颈静境敬镜径痉靖竟竞净炯窘揪究纠玖韭久灸九酒厩救旧臼舅咎就疚鞠拘狙疽居驹菊局咀矩举沮聚拒据巨具距踞锯俱句惧炬剧捐鹃娟倦眷卷绢撅攫抉掘倔爵觉决诀绝均菌钧军君峻"], +["bf40","緻",62], +["bf80","縺縼",4,"繂",4,"繈",21,"俊竣浚郡骏喀咖卡咯开揩楷凯慨刊堪勘坎砍看康慷糠扛抗亢炕考拷烤靠坷苛柯棵磕颗科壳咳可渴克刻客课肯啃垦恳坑吭空恐孔控抠口扣寇枯哭窟苦酷库裤夸垮挎跨胯块筷侩快宽款匡筐狂框矿眶旷况亏盔岿窥葵奎魁傀"], +["c040","繞",35,"纃",23,"纜纝纞"], +["c080","纮纴纻纼绖绤绬绹缊缐缞缷缹缻",6,"罃罆",9,"罒罓馈愧溃坤昆捆困括扩廓阔垃拉喇蜡腊辣啦莱来赖蓝婪栏拦篮阑兰澜谰揽览懒缆烂滥琅榔狼廊郎朗浪捞劳牢老佬姥酪烙涝勒乐雷镭蕾磊累儡垒擂肋类泪棱楞冷厘梨犁黎篱狸离漓理李里鲤礼莉荔吏栗丽厉励砾历利傈例俐"], +["c140","罖罙罛罜罝罞罠罣",4,"罫罬罭罯罰罳罵罶罷罸罺罻罼罽罿羀羂",7,"羋羍羏",4,"羕",4,"羛羜羠羢羣羥羦羨",6,"羱"], +["c180","羳",4,"羺羻羾翀翂翃翄翆翇翈翉翋翍翏",4,"翖翗翙",5,"翢翣痢立粒沥隶力璃哩俩联莲连镰廉怜涟帘敛脸链恋炼练粮凉梁粱良两辆量晾亮谅撩聊僚疗燎寥辽潦了撂镣廖料列裂烈劣猎琳林磷霖临邻鳞淋凛赁吝拎玲菱零龄铃伶羚凌灵陵岭领另令溜琉榴硫馏留刘瘤流柳六龙聋咙笼窿"], +["c240","翤翧翨翪翫翬翭翯翲翴",6,"翽翾翿耂耇耈耉耊耎耏耑耓耚耛耝耞耟耡耣耤耫",5,"耲耴耹耺耼耾聀聁聄聅聇聈聉聎聏聐聑聓聕聖聗"], +["c280","聙聛",13,"聫",5,"聲",11,"隆垄拢陇楼娄搂篓漏陋芦卢颅庐炉掳卤虏鲁麓碌露路赂鹿潞禄录陆戮驴吕铝侣旅履屡缕虑氯律率滤绿峦挛孪滦卵乱掠略抡轮伦仑沦纶论萝螺罗逻锣箩骡裸落洛骆络妈麻玛码蚂马骂嘛吗埋买麦卖迈脉瞒馒蛮满蔓曼慢漫"], +["c340","聾肁肂肅肈肊肍",5,"肔肕肗肙肞肣肦肧肨肬肰肳肵肶肸肹肻胅胇",4,"胏",6,"胘胟胠胢胣胦胮胵胷胹胻胾胿脀脁脃脄脅脇脈脋"], +["c380","脌脕脗脙脛脜脝脟",12,"脭脮脰脳脴脵脷脹",4,"脿谩芒茫盲氓忙莽猫茅锚毛矛铆卯茂冒帽貌贸么玫枚梅酶霉煤没眉媒镁每美昧寐妹媚门闷们萌蒙檬盟锰猛梦孟眯醚靡糜迷谜弥米秘觅泌蜜密幂棉眠绵冕免勉娩缅面苗描瞄藐秒渺庙妙蔑灭民抿皿敏悯闽明螟鸣铭名命谬摸"], +["c440","腀",5,"腇腉腍腎腏腒腖腗腘腛",4,"腡腢腣腤腦腨腪腫腬腯腲腳腵腶腷腸膁膃",4,"膉膋膌膍膎膐膒",5,"膙膚膞",4,"膤膥"], +["c480","膧膩膫",7,"膴",5,"膼膽膾膿臄臅臇臈臉臋臍",6,"摹蘑模膜磨摩魔抹末莫墨默沫漠寞陌谋牟某拇牡亩姆母墓暮幕募慕木目睦牧穆拿哪呐钠那娜纳氖乃奶耐奈南男难囊挠脑恼闹淖呢馁内嫩能妮霓倪泥尼拟你匿腻逆溺蔫拈年碾撵捻念娘酿鸟尿捏聂孽啮镊镍涅您柠狞凝宁"], +["c540","臔",14,"臤臥臦臨臩臫臮",4,"臵",5,"臽臿舃與",4,"舎舏舑舓舕",5,"舝舠舤舥舦舧舩舮舲舺舼舽舿"], +["c580","艀艁艂艃艅艆艈艊艌艍艎艐",7,"艙艛艜艝艞艠",7,"艩拧泞牛扭钮纽脓浓农弄奴努怒女暖虐疟挪懦糯诺哦欧鸥殴藕呕偶沤啪趴爬帕怕琶拍排牌徘湃派攀潘盘磐盼畔判叛乓庞旁耪胖抛咆刨炮袍跑泡呸胚培裴赔陪配佩沛喷盆砰抨烹澎彭蓬棚硼篷膨朋鹏捧碰坯砒霹批披劈琵毗"], +["c640","艪艫艬艭艱艵艶艷艸艻艼芀芁芃芅芆芇芉芌芐芓芔芕芖芚芛芞芠芢芣芧芲芵芶芺芻芼芿苀苂苃苅苆苉苐苖苙苚苝苢苧苨苩苪苬苭苮苰苲苳苵苶苸"], +["c680","苺苼",4,"茊茋茍茐茒茓茖茘茙茝",9,"茩茪茮茰茲茷茻茽啤脾疲皮匹痞僻屁譬篇偏片骗飘漂瓢票撇瞥拼频贫品聘乒坪苹萍平凭瓶评屏坡泼颇婆破魄迫粕剖扑铺仆莆葡菩蒲埔朴圃普浦谱曝瀑期欺栖戚妻七凄漆柒沏其棋奇歧畦崎脐齐旗祈祁骑起岂乞企启契砌器气迄弃汽泣讫掐"], +["c740","茾茿荁荂荄荅荈荊",4,"荓荕",4,"荝荢荰",6,"荹荺荾",6,"莇莈莊莋莌莍莏莐莑莔莕莖莗莙莚莝莟莡",6,"莬莭莮"], +["c780","莯莵莻莾莿菂菃菄菆菈菉菋菍菎菐菑菒菓菕菗菙菚菛菞菢菣菤菦菧菨菫菬菭恰洽牵扦钎铅千迁签仟谦乾黔钱钳前潜遣浅谴堑嵌欠歉枪呛腔羌墙蔷强抢橇锹敲悄桥瞧乔侨巧鞘撬翘峭俏窍切茄且怯窃钦侵亲秦琴勤芹擒禽寝沁青轻氢倾卿清擎晴氰情顷请庆琼穷秋丘邱球求囚酋泅趋区蛆曲躯屈驱渠"], +["c840","菮華菳",4,"菺菻菼菾菿萀萂萅萇萈萉萊萐萒",5,"萙萚萛萞",5,"萩",7,"萲",5,"萹萺萻萾",7,"葇葈葉"], +["c880","葊",6,"葒",4,"葘葝葞葟葠葢葤",4,"葪葮葯葰葲葴葷葹葻葼取娶龋趣去圈颧权醛泉全痊拳犬券劝缺炔瘸却鹊榷确雀裙群然燃冉染瓤壤攘嚷让饶扰绕惹热壬仁人忍韧任认刃妊纫扔仍日戎茸蓉荣融熔溶容绒冗揉柔肉茹蠕儒孺如辱乳汝入褥软阮蕊瑞锐闰润若弱撒洒萨腮鳃塞赛三叁"], +["c940","葽",4,"蒃蒄蒅蒆蒊蒍蒏",7,"蒘蒚蒛蒝蒞蒟蒠蒢",12,"蒰蒱蒳蒵蒶蒷蒻蒼蒾蓀蓂蓃蓅蓆蓇蓈蓋蓌蓎蓏蓒蓔蓕蓗"], +["c980","蓘",4,"蓞蓡蓢蓤蓧",4,"蓭蓮蓯蓱",10,"蓽蓾蔀蔁蔂伞散桑嗓丧搔骚扫嫂瑟色涩森僧莎砂杀刹沙纱傻啥煞筛晒珊苫杉山删煽衫闪陕擅赡膳善汕扇缮墒伤商赏晌上尚裳梢捎稍烧芍勺韶少哨邵绍奢赊蛇舌舍赦摄射慑涉社设砷申呻伸身深娠绅神沈审婶甚肾慎渗声生甥牲升绳"], +["ca40","蔃",8,"蔍蔎蔏蔐蔒蔔蔕蔖蔘蔙蔛蔜蔝蔞蔠蔢",8,"蔭",9,"蔾",4,"蕄蕅蕆蕇蕋",10], +["ca80","蕗蕘蕚蕛蕜蕝蕟",4,"蕥蕦蕧蕩",8,"蕳蕵蕶蕷蕸蕼蕽蕿薀薁省盛剩胜圣师失狮施湿诗尸虱十石拾时什食蚀实识史矢使屎驶始式示士世柿事拭誓逝势是嗜噬适仕侍释饰氏市恃室视试收手首守寿授售受瘦兽蔬枢梳殊抒输叔舒淑疏书赎孰熟薯暑曙署蜀黍鼠属术述树束戍竖墅庶数漱"], +["cb40","薂薃薆薈",6,"薐",10,"薝",6,"薥薦薧薩薫薬薭薱",5,"薸薺",6,"藂",6,"藊",4,"藑藒"], +["cb80","藔藖",5,"藝",6,"藥藦藧藨藪",14,"恕刷耍摔衰甩帅栓拴霜双爽谁水睡税吮瞬顺舜说硕朔烁斯撕嘶思私司丝死肆寺嗣四伺似饲巳松耸怂颂送宋讼诵搜艘擞嗽苏酥俗素速粟僳塑溯宿诉肃酸蒜算虽隋随绥髓碎岁穗遂隧祟孙损笋蓑梭唆缩琐索锁所塌他它她塔"], +["cc40","藹藺藼藽藾蘀",4,"蘆",10,"蘒蘓蘔蘕蘗",15,"蘨蘪",13,"蘹蘺蘻蘽蘾蘿虀"], +["cc80","虁",11,"虒虓處",4,"虛虜虝號虠虡虣",7,"獭挞蹋踏胎苔抬台泰酞太态汰坍摊贪瘫滩坛檀痰潭谭谈坦毯袒碳探叹炭汤塘搪堂棠膛唐糖倘躺淌趟烫掏涛滔绦萄桃逃淘陶讨套特藤腾疼誊梯剔踢锑提题蹄啼体替嚏惕涕剃屉天添填田甜恬舔腆挑条迢眺跳贴铁帖厅听烃"], +["cd40","虭虯虰虲",6,"蚃",6,"蚎",4,"蚔蚖",5,"蚞",4,"蚥蚦蚫蚭蚮蚲蚳蚷蚸蚹蚻",4,"蛁蛂蛃蛅蛈蛌蛍蛒蛓蛕蛖蛗蛚蛜"], +["cd80","蛝蛠蛡蛢蛣蛥蛦蛧蛨蛪蛫蛬蛯蛵蛶蛷蛺蛻蛼蛽蛿蜁蜄蜅蜆蜋蜌蜎蜏蜐蜑蜔蜖汀廷停亭庭挺艇通桐酮瞳同铜彤童桶捅筒统痛偷投头透凸秃突图徒途涂屠土吐兔湍团推颓腿蜕褪退吞屯臀拖托脱鸵陀驮驼椭妥拓唾挖哇蛙洼娃瓦袜歪外豌弯湾玩顽丸烷完碗挽晚皖惋宛婉万腕汪王亡枉网往旺望忘妄威"], +["ce40","蜙蜛蜝蜟蜠蜤蜦蜧蜨蜪蜫蜬蜭蜯蜰蜲蜳蜵蜶蜸蜹蜺蜼蜽蝀",6,"蝊蝋蝍蝏蝐蝑蝒蝔蝕蝖蝘蝚",5,"蝡蝢蝦",7,"蝯蝱蝲蝳蝵"], +["ce80","蝷蝸蝹蝺蝿螀螁螄螆螇螉螊螌螎",4,"螔螕螖螘",6,"螠",4,"巍微危韦违桅围唯惟为潍维苇萎委伟伪尾纬未蔚味畏胃喂魏位渭谓尉慰卫瘟温蚊文闻纹吻稳紊问嗡翁瓮挝蜗涡窝我斡卧握沃巫呜钨乌污诬屋无芜梧吾吴毋武五捂午舞伍侮坞戊雾晤物勿务悟误昔熙析西硒矽晰嘻吸锡牺"], +["cf40","螥螦螧螩螪螮螰螱螲螴螶螷螸螹螻螼螾螿蟁",4,"蟇蟈蟉蟌",4,"蟔",6,"蟜蟝蟞蟟蟡蟢蟣蟤蟦蟧蟨蟩蟫蟬蟭蟯",9], +["cf80","蟺蟻蟼蟽蟿蠀蠁蠂蠄",5,"蠋",7,"蠔蠗蠘蠙蠚蠜",4,"蠣稀息希悉膝夕惜熄烯溪汐犀檄袭席习媳喜铣洗系隙戏细瞎虾匣霞辖暇峡侠狭下厦夏吓掀锨先仙鲜纤咸贤衔舷闲涎弦嫌显险现献县腺馅羡宪陷限线相厢镶香箱襄湘乡翔祥详想响享项巷橡像向象萧硝霄削哮嚣销消宵淆晓"], +["d040","蠤",13,"蠳",5,"蠺蠻蠽蠾蠿衁衂衃衆",5,"衎",5,"衕衖衘衚",6,"衦衧衪衭衯衱衳衴衵衶衸衹衺"], +["d080","衻衼袀袃袆袇袉袊袌袎袏袐袑袓袔袕袗",4,"袝",4,"袣袥",5,"小孝校肖啸笑效楔些歇蝎鞋协挟携邪斜胁谐写械卸蟹懈泄泻谢屑薪芯锌欣辛新忻心信衅星腥猩惺兴刑型形邢行醒幸杏性姓兄凶胸匈汹雄熊休修羞朽嗅锈秀袖绣墟戌需虚嘘须徐许蓄酗叙旭序畜恤絮婿绪续轩喧宣悬旋玄"], +["d140","袬袮袯袰袲",4,"袸袹袺袻袽袾袿裀裃裄裇裈裊裋裌裍裏裐裑裓裖裗裚",4,"裠裡裦裧裩",6,"裲裵裶裷裺裻製裿褀褁褃",5], +["d180","褉褋",4,"褑褔",4,"褜",4,"褢褣褤褦褧褨褩褬褭褮褯褱褲褳褵褷选癣眩绚靴薛学穴雪血勋熏循旬询寻驯巡殉汛训讯逊迅压押鸦鸭呀丫芽牙蚜崖衙涯雅哑亚讶焉咽阉烟淹盐严研蜒岩延言颜阎炎沿奄掩眼衍演艳堰燕厌砚雁唁彦焰宴谚验殃央鸯秧杨扬佯疡羊洋阳氧仰痒养样漾邀腰妖瑶"], +["d240","褸",8,"襂襃襅",24,"襠",5,"襧",19,"襼"], +["d280","襽襾覀覂覄覅覇",26,"摇尧遥窑谣姚咬舀药要耀椰噎耶爷野冶也页掖业叶曳腋夜液一壹医揖铱依伊衣颐夷遗移仪胰疑沂宜姨彝椅蚁倚已乙矣以艺抑易邑屹亿役臆逸肄疫亦裔意毅忆义益溢诣议谊译异翼翌绎茵荫因殷音阴姻吟银淫寅饮尹引隐"], +["d340","覢",30,"觃觍觓觔觕觗觘觙觛觝觟觠觡觢觤觧觨觩觪觬觭觮觰觱觲觴",6], +["d380","觻",4,"訁",5,"計",21,"印英樱婴鹰应缨莹萤营荧蝇迎赢盈影颖硬映哟拥佣臃痈庸雍踊蛹咏泳涌永恿勇用幽优悠忧尤由邮铀犹油游酉有友右佑釉诱又幼迂淤于盂榆虞愚舆余俞逾鱼愉渝渔隅予娱雨与屿禹宇语羽玉域芋郁吁遇喻峪御愈欲狱育誉"], +["d440","訞",31,"訿",8,"詉",21], +["d480","詟",25,"詺",6,"浴寓裕预豫驭鸳渊冤元垣袁原援辕园员圆猿源缘远苑愿怨院曰约越跃钥岳粤月悦阅耘云郧匀陨允运蕴酝晕韵孕匝砸杂栽哉灾宰载再在咱攒暂赞赃脏葬遭糟凿藻枣早澡蚤躁噪造皂灶燥责择则泽贼怎增憎曾赠扎喳渣札轧"], +["d540","誁",7,"誋",7,"誔",46], +["d580","諃",32,"铡闸眨栅榨咋乍炸诈摘斋宅窄债寨瞻毡詹粘沾盏斩辗崭展蘸栈占战站湛绽樟章彰漳张掌涨杖丈帐账仗胀瘴障招昭找沼赵照罩兆肇召遮折哲蛰辙者锗蔗这浙珍斟真甄砧臻贞针侦枕疹诊震振镇阵蒸挣睁征狰争怔整拯正政"], +["d640","諤",34,"謈",27], +["d680","謤謥謧",30,"帧症郑证芝枝支吱蜘知肢脂汁之织职直植殖执值侄址指止趾只旨纸志挚掷至致置帜峙制智秩稚质炙痔滞治窒中盅忠钟衷终种肿重仲众舟周州洲诌粥轴肘帚咒皱宙昼骤珠株蛛朱猪诸诛逐竹烛煮拄瞩嘱主著柱助蛀贮铸筑"], +["d740","譆",31,"譧",4,"譭",25], +["d780","讇",24,"讬讱讻诇诐诪谉谞住注祝驻抓爪拽专砖转撰赚篆桩庄装妆撞壮状椎锥追赘坠缀谆准捉拙卓桌琢茁酌啄着灼浊兹咨资姿滋淄孜紫仔籽滓子自渍字鬃棕踪宗综总纵邹走奏揍租足卒族祖诅阻组钻纂嘴醉最罪尊遵昨左佐柞做作坐座"], +["d840","谸",8,"豂豃豄豅豈豊豋豍",7,"豖豗豘豙豛",5,"豣",6,"豬",6,"豴豵豶豷豻",6,"貃貄貆貇"], +["d880","貈貋貍",6,"貕貖貗貙",20,"亍丌兀丐廿卅丕亘丞鬲孬噩丨禺丿匕乇夭爻卮氐囟胤馗毓睾鼗丶亟鼐乜乩亓芈孛啬嘏仄厍厝厣厥厮靥赝匚叵匦匮匾赜卦卣刂刈刎刭刳刿剀剌剞剡剜蒯剽劂劁劐劓冂罔亻仃仉仂仨仡仫仞伛仳伢佤仵伥伧伉伫佞佧攸佚佝"], +["d940","貮",62], +["d980","賭",32,"佟佗伲伽佶佴侑侉侃侏佾佻侪佼侬侔俦俨俪俅俚俣俜俑俟俸倩偌俳倬倏倮倭俾倜倌倥倨偾偃偕偈偎偬偻傥傧傩傺僖儆僭僬僦僮儇儋仝氽佘佥俎龠汆籴兮巽黉馘冁夔勹匍訇匐凫夙兕亠兖亳衮袤亵脔裒禀嬴蠃羸冫冱冽冼"], +["da40","贎",14,"贠赑赒赗赟赥赨赩赪赬赮赯赱赲赸",8,"趂趃趆趇趈趉趌",4,"趒趓趕",9,"趠趡"], +["da80","趢趤",12,"趲趶趷趹趻趽跀跁跂跅跇跈跉跊跍跐跒跓跔凇冖冢冥讠讦讧讪讴讵讷诂诃诋诏诎诒诓诔诖诘诙诜诟诠诤诨诩诮诰诳诶诹诼诿谀谂谄谇谌谏谑谒谔谕谖谙谛谘谝谟谠谡谥谧谪谫谮谯谲谳谵谶卩卺阝阢阡阱阪阽阼陂陉陔陟陧陬陲陴隈隍隗隰邗邛邝邙邬邡邴邳邶邺"], +["db40","跕跘跙跜跠跡跢跥跦跧跩跭跮跰跱跲跴跶跼跾",6,"踆踇踈踋踍踎踐踑踒踓踕",7,"踠踡踤",4,"踫踭踰踲踳踴踶踷踸踻踼踾"], +["db80","踿蹃蹅蹆蹌",4,"蹓",5,"蹚",11,"蹧蹨蹪蹫蹮蹱邸邰郏郅邾郐郄郇郓郦郢郜郗郛郫郯郾鄄鄢鄞鄣鄱鄯鄹酃酆刍奂劢劬劭劾哿勐勖勰叟燮矍廴凵凼鬯厶弁畚巯坌垩垡塾墼壅壑圩圬圪圳圹圮圯坜圻坂坩垅坫垆坼坻坨坭坶坳垭垤垌垲埏垧垴垓垠埕埘埚埙埒垸埴埯埸埤埝"], +["dc40","蹳蹵蹷",4,"蹽蹾躀躂躃躄躆躈",6,"躑躒躓躕",6,"躝躟",11,"躭躮躰躱躳",6,"躻",7], +["dc80","軃",10,"軏",21,"堋堍埽埭堀堞堙塄堠塥塬墁墉墚墀馨鼙懿艹艽艿芏芊芨芄芎芑芗芙芫芸芾芰苈苊苣芘芷芮苋苌苁芩芴芡芪芟苄苎芤苡茉苷苤茏茇苜苴苒苘茌苻苓茑茚茆茔茕苠苕茜荑荛荜茈莒茼茴茱莛荞茯荏荇荃荟荀茗荠茭茺茳荦荥"], +["dd40","軥",62], +["dd80","輤",32,"荨茛荩荬荪荭荮莰荸莳莴莠莪莓莜莅荼莶莩荽莸荻莘莞莨莺莼菁萁菥菘堇萘萋菝菽菖萜萸萑萆菔菟萏萃菸菹菪菅菀萦菰菡葜葑葚葙葳蒇蒈葺蒉葸萼葆葩葶蒌蒎萱葭蓁蓍蓐蓦蒽蓓蓊蒿蒺蓠蒡蒹蒴蒗蓥蓣蔌甍蔸蓰蔹蔟蔺"], +["de40","轅",32,"轪辀辌辒辝辠辡辢辤辥辦辧辪辬辭辮辯農辳辴辵辷辸辺辻込辿迀迃迆"], +["de80","迉",4,"迏迒迖迗迚迠迡迣迧迬迯迱迲迴迵迶迺迻迼迾迿逇逈逌逎逓逕逘蕖蔻蓿蓼蕙蕈蕨蕤蕞蕺瞢蕃蕲蕻薤薨薇薏蕹薮薜薅薹薷薰藓藁藜藿蘧蘅蘩蘖蘼廾弈夼奁耷奕奚奘匏尢尥尬尴扌扪抟抻拊拚拗拮挢拶挹捋捃掭揶捱捺掎掴捭掬掊捩掮掼揲揸揠揿揄揞揎摒揆掾摅摁搋搛搠搌搦搡摞撄摭撖"], +["df40","這逜連逤逥逧",5,"逰",4,"逷逹逺逽逿遀遃遅遆遈",4,"過達違遖遙遚遜",5,"遤遦遧適遪遫遬遯",4,"遶",6,"遾邁"], +["df80","還邅邆邇邉邊邌",4,"邒邔邖邘邚邜邞邟邠邤邥邧邨邩邫邭邲邷邼邽邿郀摺撷撸撙撺擀擐擗擤擢攉攥攮弋忒甙弑卟叱叽叩叨叻吒吖吆呋呒呓呔呖呃吡呗呙吣吲咂咔呷呱呤咚咛咄呶呦咝哐咭哂咴哒咧咦哓哔呲咣哕咻咿哌哙哚哜咩咪咤哝哏哞唛哧唠哽唔哳唢唣唏唑唧唪啧喏喵啉啭啁啕唿啐唼"], +["e040","郂郃郆郈郉郋郌郍郒郔郕郖郘郙郚郞郟郠郣郤郥郩郪郬郮郰郱郲郳郵郶郷郹郺郻郼郿鄀鄁鄃鄅",19,"鄚鄛鄜"], +["e080","鄝鄟鄠鄡鄤",10,"鄰鄲",6,"鄺",8,"酄唷啖啵啶啷唳唰啜喋嗒喃喱喹喈喁喟啾嗖喑啻嗟喽喾喔喙嗪嗷嗉嘟嗑嗫嗬嗔嗦嗝嗄嗯嗥嗲嗳嗌嗍嗨嗵嗤辔嘞嘈嘌嘁嘤嘣嗾嘀嘧嘭噘嘹噗嘬噍噢噙噜噌噔嚆噤噱噫噻噼嚅嚓嚯囔囗囝囡囵囫囹囿圄圊圉圜帏帙帔帑帱帻帼"], +["e140","酅酇酈酑酓酔酕酖酘酙酛酜酟酠酦酧酨酫酭酳酺酻酼醀",4,"醆醈醊醎醏醓",6,"醜",5,"醤",5,"醫醬醰醱醲醳醶醷醸醹醻"], +["e180","醼",10,"釈釋釐釒",9,"針",8,"帷幄幔幛幞幡岌屺岍岐岖岈岘岙岑岚岜岵岢岽岬岫岱岣峁岷峄峒峤峋峥崂崃崧崦崮崤崞崆崛嵘崾崴崽嵬嵛嵯嵝嵫嵋嵊嵩嵴嶂嶙嶝豳嶷巅彳彷徂徇徉後徕徙徜徨徭徵徼衢彡犭犰犴犷犸狃狁狎狍狒狨狯狩狲狴狷猁狳猃狺"], +["e240","釦",62], +["e280","鈥",32,"狻猗猓猡猊猞猝猕猢猹猥猬猸猱獐獍獗獠獬獯獾舛夥飧夤夂饣饧",5,"饴饷饽馀馄馇馊馍馐馑馓馔馕庀庑庋庖庥庠庹庵庾庳赓廒廑廛廨廪膺忄忉忖忏怃忮怄忡忤忾怅怆忪忭忸怙怵怦怛怏怍怩怫怊怿怡恸恹恻恺恂"], +["e340","鉆",45,"鉵",16], +["e380","銆",7,"銏",24,"恪恽悖悚悭悝悃悒悌悛惬悻悱惝惘惆惚悴愠愦愕愣惴愀愎愫慊慵憬憔憧憷懔懵忝隳闩闫闱闳闵闶闼闾阃阄阆阈阊阋阌阍阏阒阕阖阗阙阚丬爿戕氵汔汜汊沣沅沐沔沌汨汩汴汶沆沩泐泔沭泷泸泱泗沲泠泖泺泫泮沱泓泯泾"], +["e440","銨",5,"銯",24,"鋉",31], +["e480","鋩",32,"洹洧洌浃浈洇洄洙洎洫浍洮洵洚浏浒浔洳涑浯涞涠浞涓涔浜浠浼浣渚淇淅淞渎涿淠渑淦淝淙渖涫渌涮渫湮湎湫溲湟溆湓湔渲渥湄滟溱溘滠漭滢溥溧溽溻溷滗溴滏溏滂溟潢潆潇漤漕滹漯漶潋潴漪漉漩澉澍澌潸潲潼潺濑"], +["e540","錊",51,"錿",10], +["e580","鍊",31,"鍫濉澧澹澶濂濡濮濞濠濯瀚瀣瀛瀹瀵灏灞宀宄宕宓宥宸甯骞搴寤寮褰寰蹇謇辶迓迕迥迮迤迩迦迳迨逅逄逋逦逑逍逖逡逵逶逭逯遄遑遒遐遨遘遢遛暹遴遽邂邈邃邋彐彗彖彘尻咫屐屙孱屣屦羼弪弩弭艴弼鬻屮妁妃妍妩妪妣"], +["e640","鍬",34,"鎐",27], +["e680","鎬",29,"鏋鏌鏍妗姊妫妞妤姒妲妯姗妾娅娆姝娈姣姘姹娌娉娲娴娑娣娓婀婧婊婕娼婢婵胬媪媛婷婺媾嫫媲嫒嫔媸嫠嫣嫱嫖嫦嫘嫜嬉嬗嬖嬲嬷孀尕尜孚孥孳孑孓孢驵驷驸驺驿驽骀骁骅骈骊骐骒骓骖骘骛骜骝骟骠骢骣骥骧纟纡纣纥纨纩"], +["e740","鏎",7,"鏗",54], +["e780","鐎",32,"纭纰纾绀绁绂绉绋绌绐绔绗绛绠绡绨绫绮绯绱绲缍绶绺绻绾缁缂缃缇缈缋缌缏缑缒缗缙缜缛缟缡",6,"缪缫缬缭缯",4,"缵幺畿巛甾邕玎玑玮玢玟珏珂珑玷玳珀珉珈珥珙顼琊珩珧珞玺珲琏琪瑛琦琥琨琰琮琬"], +["e840","鐯",14,"鐿",43,"鑬鑭鑮鑯"], +["e880","鑰",20,"钑钖钘铇铏铓铔铚铦铻锜锠琛琚瑁瑜瑗瑕瑙瑷瑭瑾璜璎璀璁璇璋璞璨璩璐璧瓒璺韪韫韬杌杓杞杈杩枥枇杪杳枘枧杵枨枞枭枋杷杼柰栉柘栊柩枰栌柙枵柚枳柝栀柃枸柢栎柁柽栲栳桠桡桎桢桄桤梃栝桕桦桁桧桀栾桊桉栩梵梏桴桷梓桫棂楮棼椟椠棹"], +["e940","锧锳锽镃镈镋镕镚镠镮镴镵長",7,"門",42], +["e980","閫",32,"椤棰椋椁楗棣椐楱椹楠楂楝榄楫榀榘楸椴槌榇榈槎榉楦楣楹榛榧榻榫榭槔榱槁槊槟榕槠榍槿樯槭樗樘橥槲橄樾檠橐橛樵檎橹樽樨橘橼檑檐檩檗檫猷獒殁殂殇殄殒殓殍殚殛殡殪轫轭轱轲轳轵轶轸轷轹轺轼轾辁辂辄辇辋"], +["ea40","闌",27,"闬闿阇阓阘阛阞阠阣",6,"阫阬阭阯阰阷阸阹阺阾陁陃陊陎陏陑陒陓陖陗"], +["ea80","陘陙陚陜陝陞陠陣陥陦陫陭",4,"陳陸",12,"隇隉隊辍辎辏辘辚軎戋戗戛戟戢戡戥戤戬臧瓯瓴瓿甏甑甓攴旮旯旰昊昙杲昃昕昀炅曷昝昴昱昶昵耆晟晔晁晏晖晡晗晷暄暌暧暝暾曛曜曦曩贲贳贶贻贽赀赅赆赈赉赇赍赕赙觇觊觋觌觎觏觐觑牮犟牝牦牯牾牿犄犋犍犏犒挈挲掰"], +["eb40","隌階隑隒隓隕隖隚際隝",9,"隨",7,"隱隲隴隵隷隸隺隻隿雂雃雈雊雋雐雑雓雔雖",9,"雡",6,"雫"], +["eb80","雬雭雮雰雱雲雴雵雸雺電雼雽雿霂霃霅霊霋霌霐霑霒霔霕霗",4,"霝霟霠搿擘耄毪毳毽毵毹氅氇氆氍氕氘氙氚氡氩氤氪氲攵敕敫牍牒牖爰虢刖肟肜肓肼朊肽肱肫肭肴肷胧胨胩胪胛胂胄胙胍胗朐胝胫胱胴胭脍脎胲胼朕脒豚脶脞脬脘脲腈腌腓腴腙腚腱腠腩腼腽腭腧塍媵膈膂膑滕膣膪臌朦臊膻"], +["ec40","霡",8,"霫霬霮霯霱霳",4,"霺霻霼霽霿",18,"靔靕靗靘靚靜靝靟靣靤靦靧靨靪",7], +["ec80","靲靵靷",4,"靽",7,"鞆",4,"鞌鞎鞏鞐鞓鞕鞖鞗鞙",4,"臁膦欤欷欹歃歆歙飑飒飓飕飙飚殳彀毂觳斐齑斓於旆旄旃旌旎旒旖炀炜炖炝炻烀炷炫炱烨烊焐焓焖焯焱煳煜煨煅煲煊煸煺熘熳熵熨熠燠燔燧燹爝爨灬焘煦熹戾戽扃扈扉礻祀祆祉祛祜祓祚祢祗祠祯祧祺禅禊禚禧禳忑忐"], +["ed40","鞞鞟鞡鞢鞤",6,"鞬鞮鞰鞱鞳鞵",46], +["ed80","韤韥韨韮",4,"韴韷",23,"怼恝恚恧恁恙恣悫愆愍慝憩憝懋懑戆肀聿沓泶淼矶矸砀砉砗砘砑斫砭砜砝砹砺砻砟砼砥砬砣砩硎硭硖硗砦硐硇硌硪碛碓碚碇碜碡碣碲碹碥磔磙磉磬磲礅磴礓礤礞礴龛黹黻黼盱眄眍盹眇眈眚眢眙眭眦眵眸睐睑睇睃睚睨"], +["ee40","頏",62], +["ee80","顎",32,"睢睥睿瞍睽瞀瞌瞑瞟瞠瞰瞵瞽町畀畎畋畈畛畲畹疃罘罡罟詈罨罴罱罹羁罾盍盥蠲钅钆钇钋钊钌钍钏钐钔钗钕钚钛钜钣钤钫钪钭钬钯钰钲钴钶",4,"钼钽钿铄铈",6,"铐铑铒铕铖铗铙铘铛铞铟铠铢铤铥铧铨铪"], +["ef40","顯",5,"颋颎颒颕颙颣風",37,"飏飐飔飖飗飛飜飝飠",4], +["ef80","飥飦飩",30,"铩铫铮铯铳铴铵铷铹铼铽铿锃锂锆锇锉锊锍锎锏锒",4,"锘锛锝锞锟锢锪锫锩锬锱锲锴锶锷锸锼锾锿镂锵镄镅镆镉镌镎镏镒镓镔镖镗镘镙镛镞镟镝镡镢镤",8,"镯镱镲镳锺矧矬雉秕秭秣秫稆嵇稃稂稞稔"], +["f040","餈",4,"餎餏餑",28,"餯",26], +["f080","饊",9,"饖",12,"饤饦饳饸饹饻饾馂馃馉稹稷穑黏馥穰皈皎皓皙皤瓞瓠甬鸠鸢鸨",4,"鸲鸱鸶鸸鸷鸹鸺鸾鹁鹂鹄鹆鹇鹈鹉鹋鹌鹎鹑鹕鹗鹚鹛鹜鹞鹣鹦",6,"鹱鹭鹳疒疔疖疠疝疬疣疳疴疸痄疱疰痃痂痖痍痣痨痦痤痫痧瘃痱痼痿瘐瘀瘅瘌瘗瘊瘥瘘瘕瘙"], +["f140","馌馎馚",10,"馦馧馩",47], +["f180","駙",32,"瘛瘼瘢瘠癀瘭瘰瘿瘵癃瘾瘳癍癞癔癜癖癫癯翊竦穸穹窀窆窈窕窦窠窬窨窭窳衤衩衲衽衿袂袢裆袷袼裉裢裎裣裥裱褚裼裨裾裰褡褙褓褛褊褴褫褶襁襦襻疋胥皲皴矜耒耔耖耜耠耢耥耦耧耩耨耱耋耵聃聆聍聒聩聱覃顸颀颃"], +["f240","駺",62], +["f280","騹",32,"颉颌颍颏颔颚颛颞颟颡颢颥颦虍虔虬虮虿虺虼虻蚨蚍蚋蚬蚝蚧蚣蚪蚓蚩蚶蛄蚵蛎蚰蚺蚱蚯蛉蛏蚴蛩蛱蛲蛭蛳蛐蜓蛞蛴蛟蛘蛑蜃蜇蛸蜈蜊蜍蜉蜣蜻蜞蜥蜮蜚蜾蝈蜴蜱蜩蜷蜿螂蜢蝽蝾蝻蝠蝰蝌蝮螋蝓蝣蝼蝤蝙蝥螓螯螨蟒"], +["f340","驚",17,"驲骃骉骍骎骔骕骙骦骩",6,"骲骳骴骵骹骻骽骾骿髃髄髆",4,"髍髎髏髐髒體髕髖髗髙髚髛髜"], +["f380","髝髞髠髢髣髤髥髧髨髩髪髬髮髰",8,"髺髼",6,"鬄鬅鬆蟆螈螅螭螗螃螫蟥螬螵螳蟋蟓螽蟑蟀蟊蟛蟪蟠蟮蠖蠓蟾蠊蠛蠡蠹蠼缶罂罄罅舐竺竽笈笃笄笕笊笫笏筇笸笪笙笮笱笠笥笤笳笾笞筘筚筅筵筌筝筠筮筻筢筲筱箐箦箧箸箬箝箨箅箪箜箢箫箴篑篁篌篝篚篥篦篪簌篾篼簏簖簋"], +["f440","鬇鬉",5,"鬐鬑鬒鬔",10,"鬠鬡鬢鬤",10,"鬰鬱鬳",7,"鬽鬾鬿魀魆魊魋魌魎魐魒魓魕",5], +["f480","魛",32,"簟簪簦簸籁籀臾舁舂舄臬衄舡舢舣舭舯舨舫舸舻舳舴舾艄艉艋艏艚艟艨衾袅袈裘裟襞羝羟羧羯羰羲籼敉粑粝粜粞粢粲粼粽糁糇糌糍糈糅糗糨艮暨羿翎翕翥翡翦翩翮翳糸絷綦綮繇纛麸麴赳趄趔趑趱赧赭豇豉酊酐酎酏酤"], +["f540","魼",62], +["f580","鮻",32,"酢酡酰酩酯酽酾酲酴酹醌醅醐醍醑醢醣醪醭醮醯醵醴醺豕鹾趸跫踅蹙蹩趵趿趼趺跄跖跗跚跞跎跏跛跆跬跷跸跣跹跻跤踉跽踔踝踟踬踮踣踯踺蹀踹踵踽踱蹉蹁蹂蹑蹒蹊蹰蹶蹼蹯蹴躅躏躔躐躜躞豸貂貊貅貘貔斛觖觞觚觜"], +["f640","鯜",62], +["f680","鰛",32,"觥觫觯訾謦靓雩雳雯霆霁霈霏霎霪霭霰霾龀龃龅",5,"龌黾鼋鼍隹隼隽雎雒瞿雠銎銮鋈錾鍪鏊鎏鐾鑫鱿鲂鲅鲆鲇鲈稣鲋鲎鲐鲑鲒鲔鲕鲚鲛鲞",5,"鲥",4,"鲫鲭鲮鲰",7,"鲺鲻鲼鲽鳄鳅鳆鳇鳊鳋"], +["f740","鰼",62], +["f780","鱻鱽鱾鲀鲃鲄鲉鲊鲌鲏鲓鲖鲗鲘鲙鲝鲪鲬鲯鲹鲾",4,"鳈鳉鳑鳒鳚鳛鳠鳡鳌",4,"鳓鳔鳕鳗鳘鳙鳜鳝鳟鳢靼鞅鞑鞒鞔鞯鞫鞣鞲鞴骱骰骷鹘骶骺骼髁髀髅髂髋髌髑魅魃魇魉魈魍魑飨餍餮饕饔髟髡髦髯髫髻髭髹鬈鬏鬓鬟鬣麽麾縻麂麇麈麋麒鏖麝麟黛黜黝黠黟黢黩黧黥黪黯鼢鼬鼯鼹鼷鼽鼾齄"], +["f840","鳣",62], +["f880","鴢",32], +["f940","鵃",62], +["f980","鶂",32], +["fa40","鶣",62], +["fa80","鷢",32], +["fb40","鸃",27,"鸤鸧鸮鸰鸴鸻鸼鹀鹍鹐鹒鹓鹔鹖鹙鹝鹟鹠鹡鹢鹥鹮鹯鹲鹴",9,"麀"], +["fb80","麁麃麄麅麆麉麊麌",5,"麔",8,"麞麠",5,"麧麨麩麪"], +["fc40","麫",8,"麵麶麷麹麺麼麿",4,"黅黆黇黈黊黋黌黐黒黓黕黖黗黙黚點黡黣黤黦黨黫黬黭黮黰",8,"黺黽黿",6], +["fc80","鼆",4,"鼌鼏鼑鼒鼔鼕鼖鼘鼚",5,"鼡鼣",8,"鼭鼮鼰鼱"], +["fd40","鼲",4,"鼸鼺鼼鼿",4,"齅",10,"齒",38], +["fd80","齹",5,"龁龂龍",11,"龜龝龞龡",4,"郎凉秊裏隣"], +["fe40","兀嗀﨎﨏﨑﨓﨔礼﨟蘒﨡﨣﨤﨧﨨﨩"] +] diff --git a/node_modules/body-parser/node_modules/iconv-lite/encodings/tables/cp949.json b/node_modules/body-parser/node_modules/iconv-lite/encodings/tables/cp949.json new file mode 100644 index 0000000..2022a00 --- /dev/null +++ b/node_modules/body-parser/node_modules/iconv-lite/encodings/tables/cp949.json @@ -0,0 +1,273 @@ +[ +["0","\u0000",127], +["8141","갂갃갅갆갋",4,"갘갞갟갡갢갣갥",6,"갮갲갳갴"], +["8161","갵갶갷갺갻갽갾갿걁",9,"걌걎",5,"걕"], +["8181","걖걗걙걚걛걝",18,"걲걳걵걶걹걻",4,"겂겇겈겍겎겏겑겒겓겕",6,"겞겢",5,"겫겭겮겱",6,"겺겾겿곀곂곃곅곆곇곉곊곋곍",7,"곖곘",7,"곢곣곥곦곩곫곭곮곲곴곷",4,"곾곿괁괂괃괅괇",4,"괎괐괒괓"], +["8241","괔괕괖괗괙괚괛괝괞괟괡",7,"괪괫괮",5], +["8261","괶괷괹괺괻괽",6,"굆굈굊",5,"굑굒굓굕굖굗"], +["8281","굙",7,"굢굤",7,"굮굯굱굲굷굸굹굺굾궀궃",4,"궊궋궍궎궏궑",10,"궞",5,"궥",17,"궸",7,"귂귃귅귆귇귉",6,"귒귔",7,"귝귞귟귡귢귣귥",18], +["8341","귺귻귽귾긂",5,"긊긌긎",5,"긕",7], +["8361","긝",18,"긲긳긵긶긹긻긼"], +["8381","긽긾긿깂깄깇깈깉깋깏깑깒깓깕깗",4,"깞깢깣깤깦깧깪깫깭깮깯깱",6,"깺깾",5,"꺆",5,"꺍",46,"꺿껁껂껃껅",6,"껎껒",5,"껚껛껝",8], +["8441","껦껧껩껪껬껮",5,"껵껶껷껹껺껻껽",8], +["8461","꼆꼉꼊꼋꼌꼎꼏꼑",18], +["8481","꼤",7,"꼮꼯꼱꼳꼵",6,"꼾꽀꽄꽅꽆꽇꽊",5,"꽑",10,"꽞",5,"꽦",18,"꽺",5,"꾁꾂꾃꾅꾆꾇꾉",6,"꾒꾓꾔꾖",5,"꾝",26,"꾺꾻꾽꾾"], +["8541","꾿꿁",5,"꿊꿌꿏",4,"꿕",6,"꿝",4], +["8561","꿢",5,"꿪",5,"꿲꿳꿵꿶꿷꿹",6,"뀂뀃"], +["8581","뀅",6,"뀍뀎뀏뀑뀒뀓뀕",6,"뀞",9,"뀩",26,"끆끇끉끋끍끏끐끑끒끖끘끚끛끜끞",29,"끾끿낁낂낃낅",6,"낎낐낒",5,"낛낝낞낣낤"], +["8641","낥낦낧낪낰낲낶낷낹낺낻낽",6,"냆냊",5,"냒"], +["8661","냓냕냖냗냙",6,"냡냢냣냤냦",10], +["8681","냱",22,"넊넍넎넏넑넔넕넖넗넚넞",4,"넦넧넩넪넫넭",6,"넶넺",5,"녂녃녅녆녇녉",6,"녒녓녖녗녙녚녛녝녞녟녡",22,"녺녻녽녾녿놁놃",4,"놊놌놎놏놐놑놕놖놗놙놚놛놝"], +["8741","놞",9,"놩",15], +["8761","놹",18,"뇍뇎뇏뇑뇒뇓뇕"], +["8781","뇖",5,"뇞뇠",7,"뇪뇫뇭뇮뇯뇱",7,"뇺뇼뇾",5,"눆눇눉눊눍",6,"눖눘눚",5,"눡",18,"눵",6,"눽",26,"뉙뉚뉛뉝뉞뉟뉡",6,"뉪",4], +["8841","뉯",4,"뉶",5,"뉽",6,"늆늇늈늊",4], +["8861","늏늒늓늕늖늗늛",4,"늢늤늧늨늩늫늭늮늯늱늲늳늵늶늷"], +["8881","늸",15,"닊닋닍닎닏닑닓",4,"닚닜닞닟닠닡닣닧닩닪닰닱닲닶닼닽닾댂댃댅댆댇댉",6,"댒댖",5,"댝",54,"덗덙덚덝덠덡덢덣"], +["8941","덦덨덪덬덭덯덲덳덵덶덷덹",6,"뎂뎆",5,"뎍"], +["8961","뎎뎏뎑뎒뎓뎕",10,"뎢",5,"뎩뎪뎫뎭"], +["8981","뎮",21,"돆돇돉돊돍돏돑돒돓돖돘돚돜돞돟돡돢돣돥돦돧돩",18,"돽",18,"됑",6,"됙됚됛됝됞됟됡",6,"됪됬",7,"됵",15], +["8a41","둅",10,"둒둓둕둖둗둙",6,"둢둤둦"], +["8a61","둧",4,"둭",18,"뒁뒂"], +["8a81","뒃",4,"뒉",19,"뒞",5,"뒥뒦뒧뒩뒪뒫뒭",7,"뒶뒸뒺",5,"듁듂듃듅듆듇듉",6,"듑듒듓듔듖",5,"듞듟듡듢듥듧",4,"듮듰듲",5,"듹",26,"딖딗딙딚딝"], +["8b41","딞",5,"딦딫",4,"딲딳딵딶딷딹",6,"땂땆"], +["8b61","땇땈땉땊땎땏땑땒땓땕",6,"땞땢",8], +["8b81","땫",52,"떢떣떥떦떧떩떬떭떮떯떲떶",4,"떾떿뗁뗂뗃뗅",6,"뗎뗒",5,"뗙",18,"뗭",18], +["8c41","똀",15,"똒똓똕똖똗똙",4], +["8c61","똞",6,"똦",5,"똭",6,"똵",5], +["8c81","똻",12,"뙉",26,"뙥뙦뙧뙩",50,"뚞뚟뚡뚢뚣뚥",5,"뚭뚮뚯뚰뚲",16], +["8d41","뛃",16,"뛕",8], +["8d61","뛞",17,"뛱뛲뛳뛵뛶뛷뛹뛺"], +["8d81","뛻",4,"뜂뜃뜄뜆",33,"뜪뜫뜭뜮뜱",6,"뜺뜼",7,"띅띆띇띉띊띋띍",6,"띖",9,"띡띢띣띥띦띧띩",6,"띲띴띶",5,"띾띿랁랂랃랅",6,"랎랓랔랕랚랛랝랞"], +["8e41","랟랡",6,"랪랮",5,"랶랷랹",8], +["8e61","럂",4,"럈럊",19], +["8e81","럞",13,"럮럯럱럲럳럵",6,"럾렂",4,"렊렋렍렎렏렑",6,"렚렜렞",5,"렦렧렩렪렫렭",6,"렶렺",5,"롁롂롃롅",11,"롒롔",7,"롞롟롡롢롣롥",6,"롮롰롲",5,"롹롺롻롽",7], +["8f41","뢅",7,"뢎",17], +["8f61","뢠",7,"뢩",6,"뢱뢲뢳뢵뢶뢷뢹",4], +["8f81","뢾뢿룂룄룆",5,"룍룎룏룑룒룓룕",7,"룞룠룢",5,"룪룫룭룮룯룱",6,"룺룼룾",5,"뤅",18,"뤙",6,"뤡",26,"뤾뤿륁륂륃륅",6,"륍륎륐륒",5], +["9041","륚륛륝륞륟륡",6,"륪륬륮",5,"륶륷륹륺륻륽"], +["9061","륾",5,"릆릈릋릌릏",15], +["9081","릟",12,"릮릯릱릲릳릵",6,"릾맀맂",5,"맊맋맍맓",4,"맚맜맟맠맢맦맧맩맪맫맭",6,"맶맻",4,"먂",5,"먉",11,"먖",33,"먺먻먽먾먿멁멃멄멅멆"], +["9141","멇멊멌멏멐멑멒멖멗멙멚멛멝",6,"멦멪",5], +["9161","멲멳멵멶멷멹",9,"몆몈몉몊몋몍",5], +["9181","몓",20,"몪몭몮몯몱몳",4,"몺몼몾",5,"뫅뫆뫇뫉",14,"뫚",33,"뫽뫾뫿묁묂묃묅",7,"묎묐묒",5,"묙묚묛묝묞묟묡",6], +["9241","묨묪묬",7,"묷묹묺묿",4,"뭆뭈뭊뭋뭌뭎뭑뭒"], +["9261","뭓뭕뭖뭗뭙",7,"뭢뭤",7,"뭭",4], +["9281","뭲",21,"뮉뮊뮋뮍뮎뮏뮑",18,"뮥뮦뮧뮩뮪뮫뮭",6,"뮵뮶뮸",7,"믁믂믃믅믆믇믉",6,"믑믒믔",35,"믺믻믽믾밁"], +["9341","밃",4,"밊밎밐밒밓밙밚밠밡밢밣밦밨밪밫밬밮밯밲밳밵"], +["9361","밶밷밹",6,"뱂뱆뱇뱈뱊뱋뱎뱏뱑",8], +["9381","뱚뱛뱜뱞",37,"벆벇벉벊벍벏",4,"벖벘벛",4,"벢벣벥벦벩",6,"벲벶",5,"벾벿볁볂볃볅",7,"볎볒볓볔볖볗볙볚볛볝",22,"볷볹볺볻볽"], +["9441","볾",5,"봆봈봊",5,"봑봒봓봕",8], +["9461","봞",5,"봥",6,"봭",12], +["9481","봺",5,"뵁",6,"뵊뵋뵍뵎뵏뵑",6,"뵚",9,"뵥뵦뵧뵩",22,"붂붃붅붆붋",4,"붒붔붖붗붘붛붝",6,"붥",10,"붱",6,"붹",24], +["9541","뷒뷓뷖뷗뷙뷚뷛뷝",11,"뷪",5,"뷱"], +["9561","뷲뷳뷵뷶뷷뷹",6,"븁븂븄븆",5,"븎븏븑븒븓"], +["9581","븕",6,"븞븠",35,"빆빇빉빊빋빍빏",4,"빖빘빜빝빞빟빢빣빥빦빧빩빫",4,"빲빶",4,"빾빿뺁뺂뺃뺅",6,"뺎뺒",5,"뺚",13,"뺩",14], +["9641","뺸",23,"뻒뻓"], +["9661","뻕뻖뻙",6,"뻡뻢뻦",5,"뻭",8], +["9681","뻶",10,"뼂",5,"뼊",13,"뼚뼞",33,"뽂뽃뽅뽆뽇뽉",6,"뽒뽓뽔뽖",44], +["9741","뾃",16,"뾕",8], +["9761","뾞",17,"뾱",7], +["9781","뾹",11,"뿆",5,"뿎뿏뿑뿒뿓뿕",6,"뿝뿞뿠뿢",89,"쀽쀾쀿"], +["9841","쁀",16,"쁒",5,"쁙쁚쁛"], +["9861","쁝쁞쁟쁡",6,"쁪",15], +["9881","쁺",21,"삒삓삕삖삗삙",6,"삢삤삦",5,"삮삱삲삷",4,"삾샂샃샄샆샇샊샋샍샎샏샑",6,"샚샞",5,"샦샧샩샪샫샭",6,"샶샸샺",5,"섁섂섃섅섆섇섉",6,"섑섒섓섔섖",5,"섡섢섥섨섩섪섫섮"], +["9941","섲섳섴섵섷섺섻섽섾섿셁",6,"셊셎",5,"셖셗"], +["9961","셙셚셛셝",6,"셦셪",5,"셱셲셳셵셶셷셹셺셻"], +["9981","셼",8,"솆",5,"솏솑솒솓솕솗",4,"솞솠솢솣솤솦솧솪솫솭솮솯솱",11,"솾",5,"쇅쇆쇇쇉쇊쇋쇍",6,"쇕쇖쇙",6,"쇡쇢쇣쇥쇦쇧쇩",6,"쇲쇴",7,"쇾쇿숁숂숃숅",6,"숎숐숒",5,"숚숛숝숞숡숢숣"], +["9a41","숤숥숦숧숪숬숮숰숳숵",16], +["9a61","쉆쉇쉉",6,"쉒쉓쉕쉖쉗쉙",6,"쉡쉢쉣쉤쉦"], +["9a81","쉧",4,"쉮쉯쉱쉲쉳쉵",6,"쉾슀슂",5,"슊",5,"슑",6,"슙슚슜슞",5,"슦슧슩슪슫슮",5,"슶슸슺",33,"싞싟싡싢싥",5,"싮싰싲싳싴싵싷싺싽싾싿쌁",6,"쌊쌋쌎쌏"], +["9b41","쌐쌑쌒쌖쌗쌙쌚쌛쌝",6,"쌦쌧쌪",8], +["9b61","쌳",17,"썆",7], +["9b81","썎",25,"썪썫썭썮썯썱썳",4,"썺썻썾",5,"쎅쎆쎇쎉쎊쎋쎍",50,"쏁",22,"쏚"], +["9c41","쏛쏝쏞쏡쏣",4,"쏪쏫쏬쏮",5,"쏶쏷쏹",5], +["9c61","쏿",8,"쐉",6,"쐑",9], +["9c81","쐛",8,"쐥",6,"쐭쐮쐯쐱쐲쐳쐵",6,"쐾",9,"쑉",26,"쑦쑧쑩쑪쑫쑭",6,"쑶쑷쑸쑺",5,"쒁",18,"쒕",6,"쒝",12], +["9d41","쒪",13,"쒹쒺쒻쒽",8], +["9d61","쓆",25], +["9d81","쓠",8,"쓪",5,"쓲쓳쓵쓶쓷쓹쓻쓼쓽쓾씂",9,"씍씎씏씑씒씓씕",6,"씝",10,"씪씫씭씮씯씱",6,"씺씼씾",5,"앆앇앋앏앐앑앒앖앚앛앜앟앢앣앥앦앧앩",6,"앲앶",5,"앾앿얁얂얃얅얆얈얉얊얋얎얐얒얓얔"], +["9e41","얖얙얚얛얝얞얟얡",7,"얪",9,"얶"], +["9e61","얷얺얿",4,"엋엍엏엒엓엕엖엗엙",6,"엢엤엦엧"], +["9e81","엨엩엪엫엯엱엲엳엵엸엹엺엻옂옃옄옉옊옋옍옎옏옑",6,"옚옝",6,"옦옧옩옪옫옯옱옲옶옸옺옼옽옾옿왂왃왅왆왇왉",6,"왒왖",5,"왞왟왡",10,"왭왮왰왲",5,"왺왻왽왾왿욁",6,"욊욌욎",5,"욖욗욙욚욛욝",6,"욦"], +["9f41","욨욪",5,"욲욳욵욶욷욻",4,"웂웄웆",5,"웎"], +["9f61","웏웑웒웓웕",6,"웞웟웢",5,"웪웫웭웮웯웱웲"], +["9f81","웳",4,"웺웻웼웾",5,"윆윇윉윊윋윍",6,"윖윘윚",5,"윢윣윥윦윧윩",6,"윲윴윶윸윹윺윻윾윿읁읂읃읅",4,"읋읎읐읙읚읛읝읞읟읡",6,"읩읪읬",7,"읶읷읹읺읻읿잀잁잂잆잋잌잍잏잒잓잕잙잛",4,"잢잧",4,"잮잯잱잲잳잵잶잷"], +["a041","잸잹잺잻잾쟂",5,"쟊쟋쟍쟏쟑",6,"쟙쟚쟛쟜"], +["a061","쟞",5,"쟥쟦쟧쟩쟪쟫쟭",13], +["a081","쟻",4,"젂젃젅젆젇젉젋",4,"젒젔젗",4,"젞젟젡젢젣젥",6,"젮젰젲",5,"젹젺젻젽젾젿졁",6,"졊졋졎",5,"졕",26,"졲졳졵졶졷졹졻",4,"좂좄좈좉좊좎",5,"좕",7,"좞좠좢좣좤"], +["a141","좥좦좧좩",18,"좾좿죀죁"], +["a161","죂죃죅죆죇죉죊죋죍",6,"죖죘죚",5,"죢죣죥"], +["a181","죦",14,"죶",5,"죾죿줁줂줃줇",4,"줎 、。·‥…¨〃­―∥\∼‘’“”〔〕〈",9,"±×÷≠≤≥∞∴°′″℃Å¢£¥♂♀∠⊥⌒∂∇≡≒§※☆★○●◎◇◆□■△▲▽▼→←↑↓↔〓≪≫√∽∝∵∫∬∈∋⊆⊇⊂⊃∪∩∧∨¬"], +["a241","줐줒",5,"줙",18], +["a261","줭",6,"줵",18], +["a281","쥈",7,"쥒쥓쥕쥖쥗쥙",6,"쥢쥤",7,"쥭쥮쥯⇒⇔∀∃´~ˇ˘˝˚˙¸˛¡¿ː∮∑∏¤℉‰◁◀▷▶♤♠♡♥♧♣⊙◈▣◐◑▒▤▥▨▧▦▩♨☏☎☜☞¶†‡↕↗↙↖↘♭♩♪♬㉿㈜№㏇™㏂㏘℡€®"], +["a341","쥱쥲쥳쥵",6,"쥽",10,"즊즋즍즎즏"], +["a361","즑",6,"즚즜즞",16], +["a381","즯",16,"짂짃짅짆짉짋",4,"짒짔짗짘짛!",58,"₩]",32," ̄"], +["a441","짞짟짡짣짥짦짨짩짪짫짮짲",5,"짺짻짽짾짿쨁쨂쨃쨄"], +["a461","쨅쨆쨇쨊쨎",5,"쨕쨖쨗쨙",12], +["a481","쨦쨧쨨쨪",28,"ㄱ",93], +["a541","쩇",4,"쩎쩏쩑쩒쩓쩕",6,"쩞쩢",5,"쩩쩪"], +["a561","쩫",17,"쩾",5,"쪅쪆"], +["a581","쪇",16,"쪙",14,"ⅰ",9], +["a5b0","Ⅰ",9], +["a5c1","Α",16,"Σ",6], +["a5e1","α",16,"σ",6], +["a641","쪨",19,"쪾쪿쫁쫂쫃쫅"], +["a661","쫆",5,"쫎쫐쫒쫔쫕쫖쫗쫚",5,"쫡",6], +["a681","쫨쫩쫪쫫쫭",6,"쫵",18,"쬉쬊─│┌┐┘└├┬┤┴┼━┃┏┓┛┗┣┳┫┻╋┠┯┨┷┿┝┰┥┸╂┒┑┚┙┖┕┎┍┞┟┡┢┦┧┩┪┭┮┱┲┵┶┹┺┽┾╀╁╃",7], +["a741","쬋",4,"쬑쬒쬓쬕쬖쬗쬙",6,"쬢",7], +["a761","쬪",22,"쭂쭃쭄"], +["a781","쭅쭆쭇쭊쭋쭍쭎쭏쭑",6,"쭚쭛쭜쭞",5,"쭥",7,"㎕㎖㎗ℓ㎘㏄㎣㎤㎥㎦㎙",9,"㏊㎍㎎㎏㏏㎈㎉㏈㎧㎨㎰",9,"㎀",4,"㎺",5,"㎐",4,"Ω㏀㏁㎊㎋㎌㏖㏅㎭㎮㎯㏛㎩㎪㎫㎬㏝㏐㏓㏃㏉㏜㏆"], +["a841","쭭",10,"쭺",14], +["a861","쮉",18,"쮝",6], +["a881","쮤",19,"쮹",11,"ÆЪĦ"], +["a8a6","IJ"], +["a8a8","ĿŁØŒºÞŦŊ"], +["a8b1","㉠",27,"ⓐ",25,"①",14,"½⅓⅔¼¾⅛⅜⅝⅞"], +["a941","쯅",14,"쯕",10], +["a961","쯠쯡쯢쯣쯥쯦쯨쯪",18], +["a981","쯽",14,"찎찏찑찒찓찕",6,"찞찟찠찣찤æđðħıijĸŀłøœßþŧŋʼn㈀",27,"⒜",25,"⑴",14,"¹²³⁴ⁿ₁₂₃₄"], +["aa41","찥찦찪찫찭찯찱",6,"찺찿",4,"챆챇챉챊챋챍챎"], +["aa61","챏",4,"챖챚",5,"챡챢챣챥챧챩",6,"챱챲"], +["aa81","챳챴챶",29,"ぁ",82], +["ab41","첔첕첖첗첚첛첝첞첟첡",6,"첪첮",5,"첶첷첹"], +["ab61","첺첻첽",6,"쳆쳈쳊",5,"쳑쳒쳓쳕",5], +["ab81","쳛",8,"쳥",6,"쳭쳮쳯쳱",12,"ァ",85], +["ac41","쳾쳿촀촂",5,"촊촋촍촎촏촑",6,"촚촜촞촟촠"], +["ac61","촡촢촣촥촦촧촩촪촫촭",11,"촺",4], +["ac81","촿",28,"쵝쵞쵟А",5,"ЁЖ",25], +["acd1","а",5,"ёж",25], +["ad41","쵡쵢쵣쵥",6,"쵮쵰쵲",5,"쵹",7], +["ad61","춁",6,"춉",10,"춖춗춙춚춛춝춞춟"], +["ad81","춠춡춢춣춦춨춪",5,"춱",18,"췅"], +["ae41","췆",5,"췍췎췏췑",16], +["ae61","췢",5,"췩췪췫췭췮췯췱",6,"췺췼췾",4], +["ae81","츃츅츆츇츉츊츋츍",6,"츕츖츗츘츚",5,"츢츣츥츦츧츩츪츫"], +["af41","츬츭츮츯츲츴츶",19], +["af61","칊",13,"칚칛칝칞칢",5,"칪칬"], +["af81","칮",5,"칶칷칹칺칻칽",6,"캆캈캊",5,"캒캓캕캖캗캙"], +["b041","캚",5,"캢캦",5,"캮",12], +["b061","캻",5,"컂",19], +["b081","컖",13,"컦컧컩컪컭",6,"컶컺",5,"가각간갇갈갉갊감",7,"같",4,"갠갤갬갭갯갰갱갸갹갼걀걋걍걔걘걜거걱건걷걸걺검겁것겄겅겆겉겊겋게겐겔겜겝겟겠겡겨격겪견겯결겸겹겻겼경곁계곈곌곕곗고곡곤곧골곪곬곯곰곱곳공곶과곽관괄괆"], +["b141","켂켃켅켆켇켉",6,"켒켔켖",5,"켝켞켟켡켢켣"], +["b161","켥",6,"켮켲",5,"켹",11], +["b181","콅",14,"콖콗콙콚콛콝",6,"콦콨콪콫콬괌괍괏광괘괜괠괩괬괭괴괵괸괼굄굅굇굉교굔굘굡굣구국군굳굴굵굶굻굼굽굿궁궂궈궉권궐궜궝궤궷귀귁귄귈귐귑귓규균귤그극근귿글긁금급긋긍긔기긱긴긷길긺김깁깃깅깆깊까깍깎깐깔깖깜깝깟깠깡깥깨깩깬깰깸"], +["b241","콭콮콯콲콳콵콶콷콹",6,"쾁쾂쾃쾄쾆",5,"쾍"], +["b261","쾎",18,"쾢",5,"쾩"], +["b281","쾪",5,"쾱",18,"쿅",6,"깹깻깼깽꺄꺅꺌꺼꺽꺾껀껄껌껍껏껐껑께껙껜껨껫껭껴껸껼꼇꼈꼍꼐꼬꼭꼰꼲꼴꼼꼽꼿꽁꽂꽃꽈꽉꽐꽜꽝꽤꽥꽹꾀꾄꾈꾐꾑꾕꾜꾸꾹꾼꿀꿇꿈꿉꿋꿍꿎꿔꿜꿨꿩꿰꿱꿴꿸뀀뀁뀄뀌뀐뀔뀜뀝뀨끄끅끈끊끌끎끓끔끕끗끙"], +["b341","쿌",19,"쿢쿣쿥쿦쿧쿩"], +["b361","쿪",5,"쿲쿴쿶",5,"쿽쿾쿿퀁퀂퀃퀅",5], +["b381","퀋",5,"퀒",5,"퀙",19,"끝끼끽낀낄낌낍낏낑나낙낚난낟날낡낢남납낫",4,"낱낳내낵낸낼냄냅냇냈냉냐냑냔냘냠냥너넉넋넌널넒넓넘넙넛넜넝넣네넥넨넬넴넵넷넸넹녀녁년녈념녑녔녕녘녜녠노녹논놀놂놈놉놋농높놓놔놘놜놨뇌뇐뇔뇜뇝"], +["b441","퀮",5,"퀶퀷퀹퀺퀻퀽",6,"큆큈큊",5], +["b461","큑큒큓큕큖큗큙",6,"큡",10,"큮큯"], +["b481","큱큲큳큵",6,"큾큿킀킂",18,"뇟뇨뇩뇬뇰뇹뇻뇽누눅눈눋눌눔눕눗눙눠눴눼뉘뉜뉠뉨뉩뉴뉵뉼늄늅늉느늑는늘늙늚늠늡늣능늦늪늬늰늴니닉닌닐닒님닙닛닝닢다닥닦단닫",4,"닳담답닷",4,"닿대댁댄댈댐댑댓댔댕댜더덕덖던덛덜덞덟덤덥"], +["b541","킕",14,"킦킧킩킪킫킭",5], +["b561","킳킶킸킺",5,"탂탃탅탆탇탊",5,"탒탖",4], +["b581","탛탞탟탡탢탣탥",6,"탮탲",5,"탹",11,"덧덩덫덮데덱덴델뎀뎁뎃뎄뎅뎌뎐뎔뎠뎡뎨뎬도독돈돋돌돎돐돔돕돗동돛돝돠돤돨돼됐되된될됨됩됫됴두둑둔둘둠둡둣둥둬뒀뒈뒝뒤뒨뒬뒵뒷뒹듀듄듈듐듕드득든듣들듦듬듭듯등듸디딕딘딛딜딤딥딧딨딩딪따딱딴딸"], +["b641","턅",7,"턎",17], +["b661","턠",15,"턲턳턵턶턷턹턻턼턽턾"], +["b681","턿텂텆",5,"텎텏텑텒텓텕",6,"텞텠텢",5,"텩텪텫텭땀땁땃땄땅땋때땍땐땔땜땝땟땠땡떠떡떤떨떪떫떰떱떳떴떵떻떼떽뗀뗄뗌뗍뗏뗐뗑뗘뗬또똑똔똘똥똬똴뙈뙤뙨뚜뚝뚠뚤뚫뚬뚱뛔뛰뛴뛸뜀뜁뜅뜨뜩뜬뜯뜰뜸뜹뜻띄띈띌띔띕띠띤띨띰띱띳띵라락란랄람랍랏랐랑랒랖랗"], +["b741","텮",13,"텽",6,"톅톆톇톉톊"], +["b761","톋",20,"톢톣톥톦톧"], +["b781","톩",6,"톲톴톶톷톸톹톻톽톾톿퇁",14,"래랙랜랠램랩랫랬랭랴략랸럇량러럭런럴럼럽럿렀렁렇레렉렌렐렘렙렛렝려력련렬렴렵렷렸령례롄롑롓로록론롤롬롭롯롱롸롼뢍뢨뢰뢴뢸룀룁룃룅료룐룔룝룟룡루룩룬룰룸룹룻룽뤄뤘뤠뤼뤽륀륄륌륏륑류륙륜률륨륩"], +["b841","퇐",7,"퇙",17], +["b861","퇫",8,"퇵퇶퇷퇹",13], +["b881","툈툊",5,"툑",24,"륫륭르륵른를름릅릇릉릊릍릎리릭린릴림립릿링마막만많",4,"맘맙맛망맞맡맣매맥맨맬맴맵맷맸맹맺먀먁먈먕머먹먼멀멂멈멉멋멍멎멓메멕멘멜멤멥멧멨멩며멱면멸몃몄명몇몌모목몫몬몰몲몸몹못몽뫄뫈뫘뫙뫼"], +["b941","툪툫툮툯툱툲툳툵",6,"툾퉀퉂",5,"퉉퉊퉋퉌"], +["b961","퉍",14,"퉝",6,"퉥퉦퉧퉨"], +["b981","퉩",22,"튂튃튅튆튇튉튊튋튌묀묄묍묏묑묘묜묠묩묫무묵묶문묻물묽묾뭄뭅뭇뭉뭍뭏뭐뭔뭘뭡뭣뭬뮈뮌뮐뮤뮨뮬뮴뮷므믄믈믐믓미믹민믿밀밂밈밉밋밌밍및밑바",4,"받",4,"밤밥밧방밭배백밴밸뱀뱁뱃뱄뱅뱉뱌뱍뱐뱝버벅번벋벌벎범법벗"], +["ba41","튍튎튏튒튓튔튖",5,"튝튞튟튡튢튣튥",6,"튭"], +["ba61","튮튯튰튲",5,"튺튻튽튾틁틃",4,"틊틌",5], +["ba81","틒틓틕틖틗틙틚틛틝",6,"틦",9,"틲틳틵틶틷틹틺벙벚베벡벤벧벨벰벱벳벴벵벼벽변별볍볏볐병볕볘볜보복볶본볼봄봅봇봉봐봔봤봬뵀뵈뵉뵌뵐뵘뵙뵤뵨부북분붇불붉붊붐붑붓붕붙붚붜붤붰붸뷔뷕뷘뷜뷩뷰뷴뷸븀븃븅브븍븐블븜븝븟비빅빈빌빎빔빕빗빙빚빛빠빡빤"], +["bb41","틻",4,"팂팄팆",5,"팏팑팒팓팕팗",4,"팞팢팣"], +["bb61","팤팦팧팪팫팭팮팯팱",6,"팺팾",5,"퍆퍇퍈퍉"], +["bb81","퍊",31,"빨빪빰빱빳빴빵빻빼빽뺀뺄뺌뺍뺏뺐뺑뺘뺙뺨뻐뻑뻔뻗뻘뻠뻣뻤뻥뻬뼁뼈뼉뼘뼙뼛뼜뼝뽀뽁뽄뽈뽐뽑뽕뾔뾰뿅뿌뿍뿐뿔뿜뿟뿡쀼쁑쁘쁜쁠쁨쁩삐삑삔삘삠삡삣삥사삭삯산삳살삵삶삼삽삿샀상샅새색샌샐샘샙샛샜생샤"], +["bc41","퍪",17,"퍾퍿펁펂펃펅펆펇"], +["bc61","펈펉펊펋펎펒",5,"펚펛펝펞펟펡",6,"펪펬펮"], +["bc81","펯",4,"펵펶펷펹펺펻펽",6,"폆폇폊",5,"폑",5,"샥샨샬샴샵샷샹섀섄섈섐섕서",4,"섣설섦섧섬섭섯섰성섶세섹센셀셈셉셋셌셍셔셕션셜셤셥셧셨셩셰셴셸솅소속솎손솔솖솜솝솟송솥솨솩솬솰솽쇄쇈쇌쇔쇗쇘쇠쇤쇨쇰쇱쇳쇼쇽숀숄숌숍숏숑수숙순숟술숨숩숫숭"], +["bd41","폗폙",7,"폢폤",7,"폮폯폱폲폳폵폶폷"], +["bd61","폸폹폺폻폾퐀퐂",5,"퐉",13], +["bd81","퐗",5,"퐞",25,"숯숱숲숴쉈쉐쉑쉔쉘쉠쉥쉬쉭쉰쉴쉼쉽쉿슁슈슉슐슘슛슝스슥슨슬슭슴습슷승시식신싣실싫심십싯싱싶싸싹싻싼쌀쌈쌉쌌쌍쌓쌔쌕쌘쌜쌤쌥쌨쌩썅써썩썬썰썲썸썹썼썽쎄쎈쎌쏀쏘쏙쏜쏟쏠쏢쏨쏩쏭쏴쏵쏸쐈쐐쐤쐬쐰"], +["be41","퐸",7,"푁푂푃푅",14], +["be61","푔",7,"푝푞푟푡푢푣푥",7,"푮푰푱푲"], +["be81","푳",4,"푺푻푽푾풁풃",4,"풊풌풎",5,"풕",8,"쐴쐼쐽쑈쑤쑥쑨쑬쑴쑵쑹쒀쒔쒜쒸쒼쓩쓰쓱쓴쓸쓺쓿씀씁씌씐씔씜씨씩씬씰씸씹씻씽아악안앉않알앍앎앓암압앗았앙앝앞애액앤앨앰앱앳앴앵야약얀얄얇얌얍얏양얕얗얘얜얠얩어억언얹얻얼얽얾엄",6,"엌엎"], +["bf41","풞",10,"풪",14], +["bf61","풹",18,"퓍퓎퓏퓑퓒퓓퓕"], +["bf81","퓖",5,"퓝퓞퓠",7,"퓩퓪퓫퓭퓮퓯퓱",6,"퓹퓺퓼에엑엔엘엠엡엣엥여역엮연열엶엷염",5,"옅옆옇예옌옐옘옙옛옜오옥온올옭옮옰옳옴옵옷옹옻와왁완왈왐왑왓왔왕왜왝왠왬왯왱외왹왼욀욈욉욋욍요욕욘욜욤욥욧용우욱운울욹욺움웁웃웅워웍원월웜웝웠웡웨"], +["c041","퓾",5,"픅픆픇픉픊픋픍",6,"픖픘",5], +["c061","픞",25], +["c081","픸픹픺픻픾픿핁핂핃핅",6,"핎핐핒",5,"핚핛핝핞핟핡핢핣웩웬웰웸웹웽위윅윈윌윔윕윗윙유육윤율윰윱윳융윷으윽은을읊음읍읏응",7,"읜읠읨읫이익인일읽읾잃임입잇있잉잊잎자작잔잖잗잘잚잠잡잣잤장잦재잭잰잴잼잽잿쟀쟁쟈쟉쟌쟎쟐쟘쟝쟤쟨쟬저적전절젊"], +["c141","핤핦핧핪핬핮",5,"핶핷핹핺핻핽",6,"햆햊햋"], +["c161","햌햍햎햏햑",19,"햦햧"], +["c181","햨",31,"점접젓정젖제젝젠젤젬젭젯젱져젼졀졈졉졌졍졔조족존졸졺좀좁좃종좆좇좋좌좍좔좝좟좡좨좼좽죄죈죌죔죕죗죙죠죡죤죵주죽준줄줅줆줌줍줏중줘줬줴쥐쥑쥔쥘쥠쥡쥣쥬쥰쥴쥼즈즉즌즐즘즙즛증지직진짇질짊짐집짓"], +["c241","헊헋헍헎헏헑헓",4,"헚헜헞",5,"헦헧헩헪헫헭헮"], +["c261","헯",4,"헶헸헺",5,"혂혃혅혆혇혉",6,"혒"], +["c281","혖",5,"혝혞혟혡혢혣혥",7,"혮",9,"혺혻징짖짙짚짜짝짠짢짤짧짬짭짯짰짱째짹짼쨀쨈쨉쨋쨌쨍쨔쨘쨩쩌쩍쩐쩔쩜쩝쩟쩠쩡쩨쩽쪄쪘쪼쪽쫀쫄쫌쫍쫏쫑쫓쫘쫙쫠쫬쫴쬈쬐쬔쬘쬠쬡쭁쭈쭉쭌쭐쭘쭙쭝쭤쭸쭹쮜쮸쯔쯤쯧쯩찌찍찐찔찜찝찡찢찧차착찬찮찰참찹찻"], +["c341","혽혾혿홁홂홃홄홆홇홊홌홎홏홐홒홓홖홗홙홚홛홝",4], +["c361","홢",4,"홨홪",5,"홲홳홵",11], +["c381","횁횂횄횆",5,"횎횏횑횒횓횕",7,"횞횠횢",5,"횩횪찼창찾채책챈챌챔챕챗챘챙챠챤챦챨챰챵처척천철첨첩첫첬청체첵첸첼쳄쳅쳇쳉쳐쳔쳤쳬쳰촁초촉촌촐촘촙촛총촤촨촬촹최쵠쵤쵬쵭쵯쵱쵸춈추축춘출춤춥춧충춰췄췌췐취췬췰췸췹췻췽츄츈츌츔츙츠측츤츨츰츱츳층"], +["c441","횫횭횮횯횱",7,"횺횼",7,"훆훇훉훊훋"], +["c461","훍훎훏훐훒훓훕훖훘훚",5,"훡훢훣훥훦훧훩",4], +["c481","훮훯훱훲훳훴훶",5,"훾훿휁휂휃휅",11,"휒휓휔치칙친칟칠칡침칩칫칭카칵칸칼캄캅캇캉캐캑캔캘캠캡캣캤캥캬캭컁커컥컨컫컬컴컵컷컸컹케켁켄켈켐켑켓켕켜켠켤켬켭켯켰켱켸코콕콘콜콤콥콧콩콰콱콴콸쾀쾅쾌쾡쾨쾰쿄쿠쿡쿤쿨쿰쿱쿳쿵쿼퀀퀄퀑퀘퀭퀴퀵퀸퀼"], +["c541","휕휖휗휚휛휝휞휟휡",6,"휪휬휮",5,"휶휷휹"], +["c561","휺휻휽",6,"흅흆흈흊",5,"흒흓흕흚",4], +["c581","흟흢흤흦흧흨흪흫흭흮흯흱흲흳흵",6,"흾흿힀힂",5,"힊힋큄큅큇큉큐큔큘큠크큭큰클큼큽킁키킥킨킬킴킵킷킹타탁탄탈탉탐탑탓탔탕태택탠탤탬탭탯탰탱탸턍터턱턴털턺텀텁텃텄텅테텍텐텔템텝텟텡텨텬텼톄톈토톡톤톨톰톱톳통톺톼퇀퇘퇴퇸툇툉툐투툭툰툴툼툽툿퉁퉈퉜"], +["c641","힍힎힏힑",6,"힚힜힞",5], +["c6a1","퉤튀튁튄튈튐튑튕튜튠튤튬튱트특튼튿틀틂틈틉틋틔틘틜틤틥티틱틴틸팀팁팃팅파팍팎판팔팖팜팝팟팠팡팥패팩팬팰팸팹팻팼팽퍄퍅퍼퍽펀펄펌펍펏펐펑페펙펜펠펨펩펫펭펴편펼폄폅폈평폐폘폡폣포폭폰폴폼폽폿퐁"], +["c7a1","퐈퐝푀푄표푠푤푭푯푸푹푼푿풀풂품풉풋풍풔풩퓌퓐퓔퓜퓟퓨퓬퓰퓸퓻퓽프픈플픔픕픗피픽핀필핌핍핏핑하학한할핥함합핫항해핵핸핼햄햅햇했행햐향허헉헌헐헒험헙헛헝헤헥헨헬헴헵헷헹혀혁현혈혐협혓혔형혜혠"], +["c8a1","혤혭호혹혼홀홅홈홉홋홍홑화확환활홧황홰홱홴횃횅회획횐횔횝횟횡효횬횰횹횻후훅훈훌훑훔훗훙훠훤훨훰훵훼훽휀휄휑휘휙휜휠휨휩휫휭휴휵휸휼흄흇흉흐흑흔흖흗흘흙흠흡흣흥흩희흰흴흼흽힁히힉힌힐힘힙힛힝"], +["caa1","伽佳假價加可呵哥嘉嫁家暇架枷柯歌珂痂稼苛茄街袈訶賈跏軻迦駕刻却各恪慤殼珏脚覺角閣侃刊墾奸姦干幹懇揀杆柬桿澗癎看磵稈竿簡肝艮艱諫間乫喝曷渴碣竭葛褐蝎鞨勘坎堪嵌感憾戡敢柑橄減甘疳監瞰紺邯鑑鑒龕"], +["cba1","匣岬甲胛鉀閘剛堈姜岡崗康强彊慷江畺疆糠絳綱羌腔舡薑襁講鋼降鱇介价個凱塏愷愾慨改槪漑疥皆盖箇芥蓋豈鎧開喀客坑更粳羹醵倨去居巨拒据據擧渠炬祛距踞車遽鉅鋸乾件健巾建愆楗腱虔蹇鍵騫乞傑杰桀儉劍劒檢"], +["cca1","瞼鈐黔劫怯迲偈憩揭擊格檄激膈覡隔堅牽犬甄絹繭肩見譴遣鵑抉決潔結缺訣兼慊箝謙鉗鎌京俓倞傾儆勁勍卿坰境庚徑慶憬擎敬景暻更梗涇炅烱璟璥瓊痙硬磬竟競絅經耕耿脛莖警輕逕鏡頃頸驚鯨係啓堺契季屆悸戒桂械"], +["cda1","棨溪界癸磎稽系繫繼計誡谿階鷄古叩告呱固姑孤尻庫拷攷故敲暠枯槁沽痼皐睾稿羔考股膏苦苽菰藁蠱袴誥賈辜錮雇顧高鼓哭斛曲梏穀谷鵠困坤崑昆梱棍滾琨袞鯤汨滑骨供公共功孔工恐恭拱控攻珙空蚣貢鞏串寡戈果瓜"], +["cea1","科菓誇課跨過鍋顆廓槨藿郭串冠官寬慣棺款灌琯瓘管罐菅觀貫關館刮恝括适侊光匡壙廣曠洸炚狂珖筐胱鑛卦掛罫乖傀塊壞怪愧拐槐魁宏紘肱轟交僑咬喬嬌嶠巧攪敎校橋狡皎矯絞翹膠蕎蛟較轎郊餃驕鮫丘久九仇俱具勾"], +["cfa1","區口句咎嘔坵垢寇嶇廐懼拘救枸柩構歐毆毬求溝灸狗玖球瞿矩究絿耉臼舅舊苟衢謳購軀逑邱鉤銶駒驅鳩鷗龜國局菊鞠鞫麴君窘群裙軍郡堀屈掘窟宮弓穹窮芎躬倦券勸卷圈拳捲權淃眷厥獗蕨蹶闕机櫃潰詭軌饋句晷歸貴"], +["d0a1","鬼龜叫圭奎揆槻珪硅窺竅糾葵規赳逵閨勻均畇筠菌鈞龜橘克剋劇戟棘極隙僅劤勤懃斤根槿瑾筋芹菫覲謹近饉契今妗擒昑檎琴禁禽芩衾衿襟金錦伋及急扱汲級給亘兢矜肯企伎其冀嗜器圻基埼夔奇妓寄岐崎己幾忌技旗旣"], +["d1a1","朞期杞棋棄機欺氣汽沂淇玘琦琪璂璣畸畿碁磯祁祇祈祺箕紀綺羈耆耭肌記譏豈起錡錤飢饑騎騏驥麒緊佶吉拮桔金喫儺喇奈娜懦懶拏拿癩",5,"那樂",4,"諾酪駱亂卵暖欄煖爛蘭難鸞捏捺南嵐枏楠湳濫男藍襤拉"], +["d2a1","納臘蠟衲囊娘廊",4,"乃來內奈柰耐冷女年撚秊念恬拈捻寧寗努勞奴弩怒擄櫓爐瑙盧",5,"駑魯",10,"濃籠聾膿農惱牢磊腦賂雷尿壘",7,"嫩訥杻紐勒",5,"能菱陵尼泥匿溺多茶"], +["d3a1","丹亶但單團壇彖斷旦檀段湍短端簞緞蛋袒鄲鍛撻澾獺疸達啖坍憺擔曇淡湛潭澹痰聃膽蕁覃談譚錟沓畓答踏遝唐堂塘幢戇撞棠當糖螳黨代垈坮大對岱帶待戴擡玳臺袋貸隊黛宅德悳倒刀到圖堵塗導屠島嶋度徒悼挑掉搗桃"], +["d4a1","棹櫂淘渡滔濤燾盜睹禱稻萄覩賭跳蹈逃途道都鍍陶韜毒瀆牘犢獨督禿篤纛讀墩惇敦旽暾沌焞燉豚頓乭突仝冬凍動同憧東桐棟洞潼疼瞳童胴董銅兜斗杜枓痘竇荳讀豆逗頭屯臀芚遁遯鈍得嶝橙燈登等藤謄鄧騰喇懶拏癩羅"], +["d5a1","蘿螺裸邏樂洛烙珞絡落諾酪駱丹亂卵欄欒瀾爛蘭鸞剌辣嵐擥攬欖濫籃纜藍襤覽拉臘蠟廊朗浪狼琅瑯螂郞來崍徠萊冷掠略亮倆兩凉梁樑粮粱糧良諒輛量侶儷勵呂廬慮戾旅櫚濾礪藜蠣閭驢驪麗黎力曆歷瀝礫轢靂憐戀攣漣"], +["d6a1","煉璉練聯蓮輦連鍊冽列劣洌烈裂廉斂殮濂簾獵令伶囹寧岺嶺怜玲笭羚翎聆逞鈴零靈領齡例澧禮醴隷勞怒撈擄櫓潞瀘爐盧老蘆虜路輅露魯鷺鹵碌祿綠菉錄鹿麓論壟弄朧瀧瓏籠聾儡瀨牢磊賂賚賴雷了僚寮廖料燎療瞭聊蓼"], +["d7a1","遼鬧龍壘婁屢樓淚漏瘻累縷蔞褸鏤陋劉旒柳榴流溜瀏琉瑠留瘤硫謬類六戮陸侖倫崙淪綸輪律慄栗率隆勒肋凜凌楞稜綾菱陵俚利厘吏唎履悧李梨浬犁狸理璃異痢籬罹羸莉裏裡里釐離鯉吝潾燐璘藺躪隣鱗麟林淋琳臨霖砬"], +["d8a1","立笠粒摩瑪痲碼磨馬魔麻寞幕漠膜莫邈万卍娩巒彎慢挽晩曼滿漫灣瞞萬蔓蠻輓饅鰻唜抹末沫茉襪靺亡妄忘忙望網罔芒茫莽輞邙埋妹媒寐昧枚梅每煤罵買賣邁魅脈貊陌驀麥孟氓猛盲盟萌冪覓免冕勉棉沔眄眠綿緬面麵滅"], +["d9a1","蔑冥名命明暝椧溟皿瞑茗蓂螟酩銘鳴袂侮冒募姆帽慕摸摹暮某模母毛牟牡瑁眸矛耗芼茅謀謨貌木沐牧目睦穆鶩歿沒夢朦蒙卯墓妙廟描昴杳渺猫竗苗錨務巫憮懋戊拇撫无楙武毋無珷畝繆舞茂蕪誣貿霧鵡墨默們刎吻問文"], +["daa1","汶紊紋聞蚊門雯勿沕物味媚尾嵋彌微未梶楣渼湄眉米美薇謎迷靡黴岷悶愍憫敏旻旼民泯玟珉緡閔密蜜謐剝博拍搏撲朴樸泊珀璞箔粕縛膊舶薄迫雹駁伴半反叛拌搬攀斑槃泮潘班畔瘢盤盼磐磻礬絆般蟠返頒飯勃拔撥渤潑"], +["dba1","發跋醱鉢髮魃倣傍坊妨尨幇彷房放方旁昉枋榜滂磅紡肪膀舫芳蒡蚌訪謗邦防龐倍俳北培徘拜排杯湃焙盃背胚裴裵褙賠輩配陪伯佰帛柏栢白百魄幡樊煩燔番磻繁蕃藩飜伐筏罰閥凡帆梵氾汎泛犯範范法琺僻劈壁擘檗璧癖"], +["dca1","碧蘗闢霹便卞弁變辨辯邊別瞥鱉鼈丙倂兵屛幷昞昺柄棅炳甁病秉竝輧餠騈保堡報寶普步洑湺潽珤甫菩補褓譜輔伏僕匐卜宓復服福腹茯蔔複覆輹輻馥鰒本乶俸奉封峯峰捧棒烽熢琫縫蓬蜂逢鋒鳳不付俯傅剖副否咐埠夫婦"], +["dda1","孚孵富府復扶敷斧浮溥父符簿缶腐腑膚艀芙莩訃負賦賻赴趺部釜阜附駙鳧北分吩噴墳奔奮忿憤扮昐汾焚盆粉糞紛芬賁雰不佛弗彿拂崩朋棚硼繃鵬丕備匕匪卑妃婢庇悲憊扉批斐枇榧比毖毗毘沸泌琵痺砒碑秕秘粃緋翡肥"], +["dea1","脾臂菲蜚裨誹譬費鄙非飛鼻嚬嬪彬斌檳殯浜濱瀕牝玭貧賓頻憑氷聘騁乍事些仕伺似使俟僿史司唆嗣四士奢娑寫寺射巳師徙思捨斜斯柶査梭死沙泗渣瀉獅砂社祀祠私篩紗絲肆舍莎蓑蛇裟詐詞謝賜赦辭邪飼駟麝削數朔索"], +["dfa1","傘刪山散汕珊産疝算蒜酸霰乷撒殺煞薩三參杉森渗芟蔘衫揷澁鈒颯上傷像償商喪嘗孀尙峠常床庠廂想桑橡湘爽牀狀相祥箱翔裳觴詳象賞霜塞璽賽嗇塞穡索色牲生甥省笙墅壻嶼序庶徐恕抒捿敍暑曙書栖棲犀瑞筮絮緖署"], +["e0a1","胥舒薯西誓逝鋤黍鼠夕奭席惜昔晳析汐淅潟石碩蓆釋錫仙僊先善嬋宣扇敾旋渲煽琁瑄璇璿癬禪線繕羨腺膳船蘚蟬詵跣選銑鐥饍鮮卨屑楔泄洩渫舌薛褻設說雪齧剡暹殲纖蟾贍閃陝攝涉燮葉城姓宬性惺成星晟猩珹盛省筬"], +["e1a1","聖聲腥誠醒世勢歲洗稅笹細說貰召嘯塑宵小少巢所掃搔昭梳沼消溯瀟炤燒甦疏疎瘙笑篠簫素紹蔬蕭蘇訴逍遡邵銷韶騷俗屬束涑粟續謖贖速孫巽損蓀遜飡率宋悚松淞訟誦送頌刷殺灑碎鎖衰釗修受嗽囚垂壽嫂守岫峀帥愁"], +["e2a1","戍手授搜收數樹殊水洙漱燧狩獸琇璲瘦睡秀穗竪粹綏綬繡羞脩茱蒐蓚藪袖誰讐輸遂邃酬銖銹隋隧隨雖需須首髓鬚叔塾夙孰宿淑潚熟琡璹肅菽巡徇循恂旬栒楯橓殉洵淳珣盾瞬筍純脣舜荀蓴蕣詢諄醇錞順馴戌術述鉥崇崧"], +["e3a1","嵩瑟膝蝨濕拾習褶襲丞乘僧勝升承昇繩蠅陞侍匙嘶始媤尸屎屍市弑恃施是時枾柴猜矢示翅蒔蓍視試詩諡豕豺埴寔式息拭植殖湜熄篒蝕識軾食飾伸侁信呻娠宸愼新晨燼申神紳腎臣莘薪藎蜃訊身辛辰迅失室實悉審尋心沁"], +["e4a1","沈深瀋甚芯諶什十拾雙氏亞俄兒啞娥峨我牙芽莪蛾衙訝阿雅餓鴉鵝堊岳嶽幄惡愕握樂渥鄂鍔顎鰐齷安岸按晏案眼雁鞍顔鮟斡謁軋閼唵岩巖庵暗癌菴闇壓押狎鴨仰央怏昻殃秧鴦厓哀埃崖愛曖涯碍艾隘靄厄扼掖液縊腋額"], +["e5a1","櫻罌鶯鸚也倻冶夜惹揶椰爺耶若野弱掠略約若葯蒻藥躍亮佯兩凉壤孃恙揚攘敭暘梁楊樣洋瀁煬痒瘍禳穰糧羊良襄諒讓釀陽量養圄御於漁瘀禦語馭魚齬億憶抑檍臆偃堰彦焉言諺孼蘖俺儼嚴奄掩淹嶪業円予余勵呂女如廬"], +["e6a1","旅歟汝濾璵礖礪與艅茹輿轝閭餘驪麗黎亦力域役易曆歷疫繹譯轢逆驛嚥堧姸娟宴年延憐戀捐挻撚椽沇沿涎涓淵演漣烟然煙煉燃燕璉硏硯秊筵緣練縯聯衍軟輦蓮連鉛鍊鳶列劣咽悅涅烈熱裂說閱厭廉念捻染殮炎焰琰艶苒"], +["e7a1","簾閻髥鹽曄獵燁葉令囹塋寧嶺嶸影怜映暎楹榮永泳渶潁濚瀛瀯煐營獰玲瑛瑩瓔盈穎纓羚聆英詠迎鈴鍈零霙靈領乂倪例刈叡曳汭濊猊睿穢芮藝蘂禮裔詣譽豫醴銳隸霓預五伍俉傲午吾吳嗚塢墺奧娛寤悟惡懊敖旿晤梧汚澳"], +["e8a1","烏熬獒筽蜈誤鰲鼇屋沃獄玉鈺溫瑥瘟穩縕蘊兀壅擁瓮甕癰翁邕雍饔渦瓦窩窪臥蛙蝸訛婉完宛梡椀浣玩琓琬碗緩翫脘腕莞豌阮頑曰往旺枉汪王倭娃歪矮外嵬巍猥畏了僚僥凹堯夭妖姚寥寮尿嶢拗搖撓擾料曜樂橈燎燿瑤療"], +["e9a1","窈窯繇繞耀腰蓼蟯要謠遙遼邀饒慾欲浴縟褥辱俑傭冗勇埇墉容庸慂榕涌湧溶熔瑢用甬聳茸蓉踊鎔鏞龍于佑偶優又友右宇寓尤愚憂旴牛玗瑀盂祐禑禹紆羽芋藕虞迂遇郵釪隅雨雩勖彧旭昱栯煜稶郁頊云暈橒殞澐熉耘芸蕓"], +["eaa1","運隕雲韻蔚鬱亐熊雄元原員圓園垣媛嫄寃怨愿援沅洹湲源爰猿瑗苑袁轅遠阮院願鴛月越鉞位偉僞危圍委威尉慰暐渭爲瑋緯胃萎葦蔿蝟衛褘謂違韋魏乳侑儒兪劉唯喩孺宥幼幽庾悠惟愈愉揄攸有杻柔柚柳楡楢油洧流游溜"], +["eba1","濡猶猷琉瑜由留癒硫紐維臾萸裕誘諛諭踰蹂遊逾遺酉釉鍮類六堉戮毓肉育陸倫允奫尹崙淪潤玧胤贇輪鈗閏律慄栗率聿戎瀜絨融隆垠恩慇殷誾銀隱乙吟淫蔭陰音飮揖泣邑凝應膺鷹依倚儀宜意懿擬椅毅疑矣義艤薏蟻衣誼"], +["eca1","議醫二以伊利吏夷姨履已弛彛怡易李梨泥爾珥理異痍痢移罹而耳肄苡荑裏裡貽貳邇里離飴餌匿溺瀷益翊翌翼謚人仁刃印吝咽因姻寅引忍湮燐璘絪茵藺蚓認隣靭靷鱗麟一佚佾壹日溢逸鎰馹任壬妊姙恁林淋稔臨荏賃入卄"], +["eda1","立笠粒仍剩孕芿仔刺咨姉姿子字孜恣慈滋炙煮玆瓷疵磁紫者自茨蔗藉諮資雌作勺嚼斫昨灼炸爵綽芍酌雀鵲孱棧殘潺盞岑暫潛箴簪蠶雜丈仗匠場墻壯奬將帳庄張掌暲杖樟檣欌漿牆狀獐璋章粧腸臟臧莊葬蔣薔藏裝贓醬長"], +["eea1","障再哉在宰才材栽梓渽滓災縡裁財載齋齎爭箏諍錚佇低儲咀姐底抵杵楮樗沮渚狙猪疽箸紵苧菹著藷詛貯躇這邸雎齟勣吊嫡寂摘敵滴狄炙的積笛籍績翟荻謫賊赤跡蹟迪迹適鏑佃佺傳全典前剪塡塼奠專展廛悛戰栓殿氈澱"], +["efa1","煎琠田甸畑癲筌箋箭篆纏詮輾轉鈿銓錢鐫電顚顫餞切截折浙癤竊節絶占岾店漸点粘霑鮎點接摺蝶丁井亭停偵呈姃定幀庭廷征情挺政整旌晶晸柾楨檉正汀淀淨渟湞瀞炡玎珽町睛碇禎程穽精綎艇訂諪貞鄭酊釘鉦鋌錠霆靖"], +["f0a1","靜頂鼎制劑啼堤帝弟悌提梯濟祭第臍薺製諸蹄醍除際霽題齊俎兆凋助嘲弔彫措操早晁曺曹朝條棗槽漕潮照燥爪璪眺祖祚租稠窕粗糟組繰肇藻蚤詔調趙躁造遭釣阻雕鳥族簇足鏃存尊卒拙猝倧宗從悰慫棕淙琮種終綜縱腫"], +["f1a1","踪踵鍾鐘佐坐左座挫罪主住侏做姝胄呪周嗾奏宙州廚晝朱柱株注洲湊澍炷珠疇籌紂紬綢舟蛛註誅走躊輳週酎酒鑄駐竹粥俊儁准埈寯峻晙樽浚準濬焌畯竣蠢逡遵雋駿茁中仲衆重卽櫛楫汁葺增憎曾拯烝甑症繒蒸證贈之只"], +["f2a1","咫地址志持指摯支旨智枝枳止池沚漬知砥祉祗紙肢脂至芝芷蜘誌識贄趾遲直稙稷織職唇嗔塵振搢晉晋桭榛殄津溱珍瑨璡畛疹盡眞瞋秦縉縝臻蔯袗診賑軫辰進鎭陣陳震侄叱姪嫉帙桎瓆疾秩窒膣蛭質跌迭斟朕什執潗緝輯"], +["f3a1","鏶集徵懲澄且侘借叉嗟嵯差次此磋箚茶蹉車遮捉搾着窄錯鑿齪撰澯燦璨瓚竄簒纂粲纘讚贊鑽餐饌刹察擦札紮僭參塹慘慙懺斬站讒讖倉倡創唱娼廠彰愴敞昌昶暢槍滄漲猖瘡窓脹艙菖蒼債埰寀寨彩採砦綵菜蔡采釵冊柵策"], +["f4a1","責凄妻悽處倜刺剔尺慽戚拓擲斥滌瘠脊蹠陟隻仟千喘天川擅泉淺玔穿舛薦賤踐遷釧闡阡韆凸哲喆徹撤澈綴輟轍鐵僉尖沾添甛瞻簽籤詹諂堞妾帖捷牒疊睫諜貼輒廳晴淸聽菁請靑鯖切剃替涕滯締諦逮遞體初剿哨憔抄招梢"], +["f5a1","椒楚樵炒焦硝礁礎秒稍肖艸苕草蕉貂超酢醋醮促囑燭矗蜀觸寸忖村邨叢塚寵悤憁摠總聰蔥銃撮催崔最墜抽推椎楸樞湫皺秋芻萩諏趨追鄒酋醜錐錘鎚雛騶鰍丑畜祝竺筑築縮蓄蹙蹴軸逐春椿瑃出朮黜充忠沖蟲衝衷悴膵萃"], +["f6a1","贅取吹嘴娶就炊翠聚脆臭趣醉驟鷲側仄厠惻測層侈値嗤峙幟恥梔治淄熾痔痴癡稚穉緇緻置致蚩輜雉馳齒則勅飭親七柒漆侵寢枕沈浸琛砧針鍼蟄秤稱快他咤唾墮妥惰打拖朶楕舵陀馱駝倬卓啄坼度托拓擢晫柝濁濯琢琸託"], +["f7a1","鐸呑嘆坦彈憚歎灘炭綻誕奪脫探眈耽貪塔搭榻宕帑湯糖蕩兌台太怠態殆汰泰笞胎苔跆邰颱宅擇澤撑攄兎吐土討慟桶洞痛筒統通堆槌腿褪退頹偸套妬投透鬪慝特闖坡婆巴把播擺杷波派爬琶破罷芭跛頗判坂板版瓣販辦鈑"], +["f8a1","阪八叭捌佩唄悖敗沛浿牌狽稗覇貝彭澎烹膨愎便偏扁片篇編翩遍鞭騙貶坪平枰萍評吠嬖幣廢弊斃肺蔽閉陛佈包匍匏咆哺圃布怖抛抱捕暴泡浦疱砲胞脯苞葡蒲袍褒逋鋪飽鮑幅暴曝瀑爆輻俵剽彪慓杓標漂瓢票表豹飇飄驃"], +["f9a1","品稟楓諷豊風馮彼披疲皮被避陂匹弼必泌珌畢疋筆苾馝乏逼下何厦夏廈昰河瑕荷蝦賀遐霞鰕壑學虐謔鶴寒恨悍旱汗漢澣瀚罕翰閑閒限韓割轄函含咸啣喊檻涵緘艦銜陷鹹合哈盒蛤閤闔陜亢伉姮嫦巷恒抗杭桁沆港缸肛航"], +["faa1","行降項亥偕咳垓奚孩害懈楷海瀣蟹解該諧邂駭骸劾核倖幸杏荇行享向嚮珦鄕響餉饗香噓墟虛許憲櫶獻軒歇險驗奕爀赫革俔峴弦懸晛泫炫玄玹現眩睍絃絢縣舷衒見賢鉉顯孑穴血頁嫌俠協夾峽挾浹狹脅脇莢鋏頰亨兄刑型"], +["fba1","形泂滎瀅灐炯熒珩瑩荊螢衡逈邢鎣馨兮彗惠慧暳蕙蹊醯鞋乎互呼壕壺好岵弧戶扈昊晧毫浩淏湖滸澔濠濩灝狐琥瑚瓠皓祜糊縞胡芦葫蒿虎號蝴護豪鎬頀顥惑或酷婚昏混渾琿魂忽惚笏哄弘汞泓洪烘紅虹訌鴻化和嬅樺火畵"], +["fca1","禍禾花華話譁貨靴廓擴攫確碻穫丸喚奐宦幻患換歡晥桓渙煥環紈還驩鰥活滑猾豁闊凰幌徨恍惶愰慌晃晄榥況湟滉潢煌璜皇篁簧荒蝗遑隍黃匯回廻徊恢悔懷晦會檜淮澮灰獪繪膾茴蛔誨賄劃獲宖橫鐄哮嚆孝效斅曉梟涍淆"], +["fda1","爻肴酵驍侯候厚后吼喉嗅帿後朽煦珝逅勛勳塤壎焄熏燻薰訓暈薨喧暄煊萱卉喙毁彙徽揮暉煇諱輝麾休携烋畦虧恤譎鷸兇凶匈洶胸黑昕欣炘痕吃屹紇訖欠欽歆吸恰洽翕興僖凞喜噫囍姬嬉希憙憘戱晞曦熙熹熺犧禧稀羲詰"] +] diff --git a/node_modules/body-parser/node_modules/iconv-lite/encodings/tables/cp950.json b/node_modules/body-parser/node_modules/iconv-lite/encodings/tables/cp950.json new file mode 100644 index 0000000..d8bc871 --- /dev/null +++ b/node_modules/body-parser/node_modules/iconv-lite/encodings/tables/cp950.json @@ -0,0 +1,177 @@ +[ +["0","\u0000",127], +["a140"," ,、。.‧;:?!︰…‥﹐﹑﹒·﹔﹕﹖﹗|–︱—︳╴︴﹏()︵︶{}︷︸〔〕︹︺【】︻︼《》︽︾〈〉︿﹀「」﹁﹂『』﹃﹄﹙﹚"], +["a1a1","﹛﹜﹝﹞‘’“”〝〞‵′#&*※§〃○●△▲◎☆★◇◆□■▽▼㊣℅¯ ̄_ˍ﹉﹊﹍﹎﹋﹌﹟﹠﹡+-×÷±√<>=≦≧≠∞≒≡﹢",4,"~∩∪⊥∠∟⊿㏒㏑∫∮∵∴♀♂⊕⊙↑↓←→↖↗↙↘∥∣/"], +["a240","\∕﹨$¥〒¢£%@℃℉﹩﹪﹫㏕㎜㎝㎞㏎㎡㎎㎏㏄°兙兛兞兝兡兣嗧瓩糎▁",7,"▏▎▍▌▋▊▉┼┴┬┤├▔─│▕┌┐└┘╭"], +["a2a1","╮╰╯═╞╪╡◢◣◥◤╱╲╳0",9,"Ⅰ",9,"〡",8,"十卄卅A",25,"a",21], +["a340","wxyzΑ",16,"Σ",6,"α",16,"σ",6,"ㄅ",10], +["a3a1","ㄐ",25,"˙ˉˊˇˋ"], +["a3e1","€"], +["a440","一乙丁七乃九了二人儿入八几刀刁力匕十卜又三下丈上丫丸凡久么也乞于亡兀刃勺千叉口土士夕大女子孑孓寸小尢尸山川工己已巳巾干廾弋弓才"], +["a4a1","丑丐不中丰丹之尹予云井互五亢仁什仃仆仇仍今介仄元允內六兮公冗凶分切刈勻勾勿化匹午升卅卞厄友及反壬天夫太夭孔少尤尺屯巴幻廿弔引心戈戶手扎支文斗斤方日曰月木欠止歹毋比毛氏水火爪父爻片牙牛犬王丙"], +["a540","世丕且丘主乍乏乎以付仔仕他仗代令仙仞充兄冉冊冬凹出凸刊加功包匆北匝仟半卉卡占卯卮去可古右召叮叩叨叼司叵叫另只史叱台句叭叻四囚外"], +["a5a1","央失奴奶孕它尼巨巧左市布平幼弁弘弗必戊打扔扒扑斥旦朮本未末札正母民氐永汁汀氾犯玄玉瓜瓦甘生用甩田由甲申疋白皮皿目矛矢石示禾穴立丞丟乒乓乩亙交亦亥仿伉伙伊伕伍伐休伏仲件任仰仳份企伋光兇兆先全"], +["a640","共再冰列刑划刎刖劣匈匡匠印危吉吏同吊吐吁吋各向名合吃后吆吒因回囝圳地在圭圬圯圩夙多夷夸妄奸妃好她如妁字存宇守宅安寺尖屹州帆并年"], +["a6a1","式弛忙忖戎戌戍成扣扛托收早旨旬旭曲曳有朽朴朱朵次此死氖汝汗汙江池汐汕污汛汍汎灰牟牝百竹米糸缶羊羽老考而耒耳聿肉肋肌臣自至臼舌舛舟艮色艾虫血行衣西阡串亨位住佇佗佞伴佛何估佐佑伽伺伸佃佔似但佣"], +["a740","作你伯低伶余佝佈佚兌克免兵冶冷別判利刪刨劫助努劬匣即卵吝吭吞吾否呎吧呆呃吳呈呂君吩告吹吻吸吮吵吶吠吼呀吱含吟听囪困囤囫坊坑址坍"], +["a7a1","均坎圾坐坏圻壯夾妝妒妨妞妣妙妖妍妤妓妊妥孝孜孚孛完宋宏尬局屁尿尾岐岑岔岌巫希序庇床廷弄弟彤形彷役忘忌志忍忱快忸忪戒我抄抗抖技扶抉扭把扼找批扳抒扯折扮投抓抑抆改攻攸旱更束李杏材村杜杖杞杉杆杠"], +["a840","杓杗步每求汞沙沁沈沉沅沛汪決沐汰沌汨沖沒汽沃汲汾汴沆汶沍沔沘沂灶灼災灸牢牡牠狄狂玖甬甫男甸皂盯矣私秀禿究系罕肖肓肝肘肛肚育良芒"], +["a8a1","芋芍見角言谷豆豕貝赤走足身車辛辰迂迆迅迄巡邑邢邪邦那酉釆里防阮阱阪阬並乖乳事些亞享京佯依侍佳使佬供例來侃佰併侈佩佻侖佾侏侑佺兔兒兕兩具其典冽函刻券刷刺到刮制剁劾劻卒協卓卑卦卷卸卹取叔受味呵"], +["a940","咖呸咕咀呻呷咄咒咆呼咐呱呶和咚呢周咋命咎固垃坷坪坩坡坦坤坼夜奉奇奈奄奔妾妻委妹妮姑姆姐姍始姓姊妯妳姒姅孟孤季宗定官宜宙宛尚屈居"], +["a9a1","屆岷岡岸岩岫岱岳帘帚帖帕帛帑幸庚店府底庖延弦弧弩往征彿彼忝忠忽念忿怏怔怯怵怖怪怕怡性怩怫怛或戕房戾所承拉拌拄抿拂抹拒招披拓拔拋拈抨抽押拐拙拇拍抵拚抱拘拖拗拆抬拎放斧於旺昔易昌昆昂明昀昏昕昊"], +["aa40","昇服朋杭枋枕東果杳杷枇枝林杯杰板枉松析杵枚枓杼杪杲欣武歧歿氓氛泣注泳沱泌泥河沽沾沼波沫法泓沸泄油況沮泗泅泱沿治泡泛泊沬泯泜泖泠"], +["aaa1","炕炎炒炊炙爬爭爸版牧物狀狎狙狗狐玩玨玟玫玥甽疝疙疚的盂盲直知矽社祀祁秉秈空穹竺糾罔羌羋者肺肥肢肱股肫肩肴肪肯臥臾舍芳芝芙芭芽芟芹花芬芥芯芸芣芰芾芷虎虱初表軋迎返近邵邸邱邶采金長門阜陀阿阻附"], +["ab40","陂隹雨青非亟亭亮信侵侯便俠俑俏保促侶俘俟俊俗侮俐俄係俚俎俞侷兗冒冑冠剎剃削前剌剋則勇勉勃勁匍南卻厚叛咬哀咨哎哉咸咦咳哇哂咽咪品"], +["aba1","哄哈咯咫咱咻咩咧咿囿垂型垠垣垢城垮垓奕契奏奎奐姜姘姿姣姨娃姥姪姚姦威姻孩宣宦室客宥封屎屏屍屋峙峒巷帝帥帟幽庠度建弈弭彥很待徊律徇後徉怒思怠急怎怨恍恰恨恢恆恃恬恫恪恤扁拜挖按拼拭持拮拽指拱拷"], +["ac40","拯括拾拴挑挂政故斫施既春昭映昧是星昨昱昤曷柿染柱柔某柬架枯柵柩柯柄柑枴柚查枸柏柞柳枰柙柢柝柒歪殃殆段毒毗氟泉洋洲洪流津洌洱洞洗"], +["aca1","活洽派洶洛泵洹洧洸洩洮洵洎洫炫為炳炬炯炭炸炮炤爰牲牯牴狩狠狡玷珊玻玲珍珀玳甚甭畏界畎畋疫疤疥疢疣癸皆皇皈盈盆盃盅省盹相眉看盾盼眇矜砂研砌砍祆祉祈祇禹禺科秒秋穿突竿竽籽紂紅紀紉紇約紆缸美羿耄"], +["ad40","耐耍耑耶胖胥胚胃胄背胡胛胎胞胤胝致舢苧范茅苣苛苦茄若茂茉苒苗英茁苜苔苑苞苓苟苯茆虐虹虻虺衍衫要觔計訂訃貞負赴赳趴軍軌述迦迢迪迥"], +["ada1","迭迫迤迨郊郎郁郃酋酊重閂限陋陌降面革韋韭音頁風飛食首香乘亳倌倍倣俯倦倥俸倩倖倆值借倚倒們俺倀倔倨俱倡個候倘俳修倭倪俾倫倉兼冤冥冢凍凌准凋剖剜剔剛剝匪卿原厝叟哨唐唁唷哼哥哲唆哺唔哩哭員唉哮哪"], +["ae40","哦唧唇哽唏圃圄埂埔埋埃堉夏套奘奚娑娘娜娟娛娓姬娠娣娩娥娌娉孫屘宰害家宴宮宵容宸射屑展屐峭峽峻峪峨峰島崁峴差席師庫庭座弱徒徑徐恙"], +["aea1","恣恥恐恕恭恩息悄悟悚悍悔悌悅悖扇拳挈拿捎挾振捕捂捆捏捉挺捐挽挪挫挨捍捌效敉料旁旅時晉晏晃晒晌晅晁書朔朕朗校核案框桓根桂桔栩梳栗桌桑栽柴桐桀格桃株桅栓栘桁殊殉殷氣氧氨氦氤泰浪涕消涇浦浸海浙涓"], +["af40","浬涉浮浚浴浩涌涊浹涅浥涔烊烘烤烙烈烏爹特狼狹狽狸狷玆班琉珮珠珪珞畔畝畜畚留疾病症疲疳疽疼疹痂疸皋皰益盍盎眩真眠眨矩砰砧砸砝破砷"], +["afa1","砥砭砠砟砲祕祐祠祟祖神祝祗祚秤秣秧租秦秩秘窄窈站笆笑粉紡紗紋紊素索純紐紕級紜納紙紛缺罟羔翅翁耆耘耕耙耗耽耿胱脂胰脅胭胴脆胸胳脈能脊胼胯臭臬舀舐航舫舨般芻茫荒荔荊茸荐草茵茴荏茲茹茶茗荀茱茨荃"], +["b040","虔蚊蚪蚓蚤蚩蚌蚣蚜衰衷袁袂衽衹記訐討訌訕訊託訓訖訏訑豈豺豹財貢起躬軒軔軏辱送逆迷退迺迴逃追逅迸邕郡郝郢酒配酌釘針釗釜釙閃院陣陡"], +["b0a1","陛陝除陘陞隻飢馬骨高鬥鬲鬼乾偺偽停假偃偌做偉健偶偎偕偵側偷偏倏偯偭兜冕凰剪副勒務勘動匐匏匙匿區匾參曼商啪啦啄啞啡啃啊唱啖問啕唯啤唸售啜唬啣唳啁啗圈國圉域堅堊堆埠埤基堂堵執培夠奢娶婁婉婦婪婀"], +["b140","娼婢婚婆婊孰寇寅寄寂宿密尉專將屠屜屝崇崆崎崛崖崢崑崩崔崙崤崧崗巢常帶帳帷康庸庶庵庾張強彗彬彩彫得徙從徘御徠徜恿患悉悠您惋悴惦悽"], +["b1a1","情悻悵惜悼惘惕惆惟悸惚惇戚戛扈掠控捲掖探接捷捧掘措捱掩掉掃掛捫推掄授掙採掬排掏掀捻捩捨捺敝敖救教敗啟敏敘敕敔斜斛斬族旋旌旎晝晚晤晨晦晞曹勗望梁梯梢梓梵桿桶梱梧梗械梃棄梭梆梅梔條梨梟梡梂欲殺"], +["b240","毫毬氫涎涼淳淙液淡淌淤添淺清淇淋涯淑涮淞淹涸混淵淅淒渚涵淚淫淘淪深淮淨淆淄涪淬涿淦烹焉焊烽烯爽牽犁猜猛猖猓猙率琅琊球理現琍瓠瓶"], +["b2a1","瓷甜產略畦畢異疏痔痕疵痊痍皎盔盒盛眷眾眼眶眸眺硫硃硎祥票祭移窒窕笠笨笛第符笙笞笮粒粗粕絆絃統紮紹紼絀細紳組累終紲紱缽羞羚翌翎習耜聊聆脯脖脣脫脩脰脤舂舵舷舶船莎莞莘荸莢莖莽莫莒莊莓莉莠荷荻荼"], +["b340","莆莧處彪蛇蛀蚶蛄蚵蛆蛋蚱蚯蛉術袞袈被袒袖袍袋覓規訪訝訣訥許設訟訛訢豉豚販責貫貨貪貧赧赦趾趺軛軟這逍通逗連速逝逐逕逞造透逢逖逛途"], +["b3a1","部郭都酗野釵釦釣釧釭釩閉陪陵陳陸陰陴陶陷陬雀雪雩章竟頂頃魚鳥鹵鹿麥麻傢傍傅備傑傀傖傘傚最凱割剴創剩勞勝勛博厥啻喀喧啼喊喝喘喂喜喪喔喇喋喃喳單喟唾喲喚喻喬喱啾喉喫喙圍堯堪場堤堰報堡堝堠壹壺奠"], +["b440","婷媚婿媒媛媧孳孱寒富寓寐尊尋就嵌嵐崴嵇巽幅帽幀幃幾廊廁廂廄弼彭復循徨惑惡悲悶惠愜愣惺愕惰惻惴慨惱愎惶愉愀愒戟扉掣掌描揀揩揉揆揍"], +["b4a1","插揣提握揖揭揮捶援揪換摒揚揹敞敦敢散斑斐斯普晰晴晶景暑智晾晷曾替期朝棺棕棠棘棗椅棟棵森棧棹棒棲棣棋棍植椒椎棉棚楮棻款欺欽殘殖殼毯氮氯氬港游湔渡渲湧湊渠渥渣減湛湘渤湖湮渭渦湯渴湍渺測湃渝渾滋"], +["b540","溉渙湎湣湄湲湩湟焙焚焦焰無然煮焜牌犄犀猶猥猴猩琺琪琳琢琥琵琶琴琯琛琦琨甥甦畫番痢痛痣痙痘痞痠登發皖皓皴盜睏短硝硬硯稍稈程稅稀窘"], +["b5a1","窗窖童竣等策筆筐筒答筍筋筏筑粟粥絞結絨絕紫絮絲絡給絢絰絳善翔翕耋聒肅腕腔腋腑腎脹腆脾腌腓腴舒舜菩萃菸萍菠菅萋菁華菱菴著萊菰萌菌菽菲菊萸萎萄菜萇菔菟虛蛟蛙蛭蛔蛛蛤蛐蛞街裁裂袱覃視註詠評詞証詁"], +["b640","詔詛詐詆訴診訶詖象貂貯貼貳貽賁費賀貴買貶貿貸越超趁跎距跋跚跑跌跛跆軻軸軼辜逮逵週逸進逶鄂郵鄉郾酣酥量鈔鈕鈣鈉鈞鈍鈐鈇鈑閔閏開閑"], +["b6a1","間閒閎隊階隋陽隅隆隍陲隄雁雅雄集雇雯雲韌項順須飧飪飯飩飲飭馮馭黃黍黑亂傭債傲傳僅傾催傷傻傯僇剿剷剽募勦勤勢勣匯嗟嗨嗓嗦嗎嗜嗇嗑嗣嗤嗯嗚嗡嗅嗆嗥嗉園圓塞塑塘塗塚塔填塌塭塊塢塒塋奧嫁嫉嫌媾媽媼"], +["b740","媳嫂媲嵩嵯幌幹廉廈弒彙徬微愚意慈感想愛惹愁愈慎慌慄慍愾愴愧愍愆愷戡戢搓搾搞搪搭搽搬搏搜搔損搶搖搗搆敬斟新暗暉暇暈暖暄暘暍會榔業"], +["b7a1","楚楷楠楔極椰概楊楨楫楞楓楹榆楝楣楛歇歲毀殿毓毽溢溯滓溶滂源溝滇滅溥溘溼溺溫滑準溜滄滔溪溧溴煎煙煩煤煉照煜煬煦煌煥煞煆煨煖爺牒猷獅猿猾瑯瑚瑕瑟瑞瑁琿瑙瑛瑜當畸瘀痰瘁痲痱痺痿痴痳盞盟睛睫睦睞督"], +["b840","睹睪睬睜睥睨睢矮碎碰碗碘碌碉硼碑碓硿祺祿禁萬禽稜稚稠稔稟稞窟窠筷節筠筮筧粱粳粵經絹綑綁綏絛置罩罪署義羨群聖聘肆肄腱腰腸腥腮腳腫"], +["b8a1","腹腺腦舅艇蒂葷落萱葵葦葫葉葬葛萼萵葡董葩葭葆虞虜號蛹蜓蜈蜇蜀蛾蛻蜂蜃蜆蜊衙裟裔裙補裘裝裡裊裕裒覜解詫該詳試詩詰誇詼詣誠話誅詭詢詮詬詹詻訾詨豢貊貉賊資賈賄貲賃賂賅跡跟跨路跳跺跪跤跦躲較載軾輊"], +["b940","辟農運遊道遂達逼違遐遇遏過遍遑逾遁鄒鄗酬酪酩釉鈷鉗鈸鈽鉀鈾鉛鉋鉤鉑鈴鉉鉍鉅鈹鈿鉚閘隘隔隕雍雋雉雊雷電雹零靖靴靶預頑頓頊頒頌飼飴"], +["b9a1","飽飾馳馱馴髡鳩麂鼎鼓鼠僧僮僥僖僭僚僕像僑僱僎僩兢凳劃劂匱厭嗾嘀嘛嘗嗽嘔嘆嘉嘍嘎嗷嘖嘟嘈嘐嗶團圖塵塾境墓墊塹墅塽壽夥夢夤奪奩嫡嫦嫩嫗嫖嫘嫣孵寞寧寡寥實寨寢寤察對屢嶄嶇幛幣幕幗幔廓廖弊彆彰徹慇"], +["ba40","愿態慷慢慣慟慚慘慵截撇摘摔撤摸摟摺摑摧搴摭摻敲斡旗旖暢暨暝榜榨榕槁榮槓構榛榷榻榫榴槐槍榭槌榦槃榣歉歌氳漳演滾漓滴漩漾漠漬漏漂漢"], +["baa1","滿滯漆漱漸漲漣漕漫漯澈漪滬漁滲滌滷熔熙煽熊熄熒爾犒犖獄獐瑤瑣瑪瑰瑭甄疑瘧瘍瘋瘉瘓盡監瞄睽睿睡磁碟碧碳碩碣禎福禍種稱窪窩竭端管箕箋筵算箝箔箏箸箇箄粹粽精綻綰綜綽綾綠緊綴網綱綺綢綿綵綸維緒緇綬"], +["bb40","罰翠翡翟聞聚肇腐膀膏膈膊腿膂臧臺與舔舞艋蓉蒿蓆蓄蒙蒞蒲蒜蓋蒸蓀蓓蒐蒼蓑蓊蜿蜜蜻蜢蜥蜴蜘蝕蜷蜩裳褂裴裹裸製裨褚裯誦誌語誣認誡誓誤"], +["bba1","說誥誨誘誑誚誧豪貍貌賓賑賒赫趙趕跼輔輒輕輓辣遠遘遜遣遙遞遢遝遛鄙鄘鄞酵酸酷酴鉸銀銅銘銖鉻銓銜銨鉼銑閡閨閩閣閥閤隙障際雌雒需靼鞅韶頗領颯颱餃餅餌餉駁骯骰髦魁魂鳴鳶鳳麼鼻齊億儀僻僵價儂儈儉儅凜"], +["bc40","劇劈劉劍劊勰厲嘮嘻嘹嘲嘿嘴嘩噓噎噗噴嘶嘯嘰墀墟增墳墜墮墩墦奭嬉嫻嬋嫵嬌嬈寮寬審寫層履嶝嶔幢幟幡廢廚廟廝廣廠彈影德徵慶慧慮慝慕憂"], +["bca1","慼慰慫慾憧憐憫憎憬憚憤憔憮戮摩摯摹撞撲撈撐撰撥撓撕撩撒撮播撫撚撬撙撢撳敵敷數暮暫暴暱樣樟槨樁樞標槽模樓樊槳樂樅槭樑歐歎殤毅毆漿潼澄潑潦潔澆潭潛潸潮澎潺潰潤澗潘滕潯潠潟熟熬熱熨牖犛獎獗瑩璋璃"], +["bd40","瑾璀畿瘠瘩瘟瘤瘦瘡瘢皚皺盤瞎瞇瞌瞑瞋磋磅確磊碾磕碼磐稿稼穀稽稷稻窯窮箭箱範箴篆篇篁箠篌糊締練緯緻緘緬緝編緣線緞緩綞緙緲緹罵罷羯"], +["bda1","翩耦膛膜膝膠膚膘蔗蔽蔚蓮蔬蔭蔓蔑蔣蔡蔔蓬蔥蓿蔆螂蝴蝶蝠蝦蝸蝨蝙蝗蝌蝓衛衝褐複褒褓褕褊誼諒談諄誕請諸課諉諂調誰論諍誶誹諛豌豎豬賠賞賦賤賬賭賢賣賜質賡赭趟趣踫踐踝踢踏踩踟踡踞躺輝輛輟輩輦輪輜輞"], +["be40","輥適遮遨遭遷鄰鄭鄧鄱醇醉醋醃鋅銻銷鋪銬鋤鋁銳銼鋒鋇鋰銲閭閱霄霆震霉靠鞍鞋鞏頡頫頜颳養餓餒餘駝駐駟駛駑駕駒駙骷髮髯鬧魅魄魷魯鴆鴉"], +["bea1","鴃麩麾黎墨齒儒儘儔儐儕冀冪凝劑劓勳噙噫噹噩噤噸噪器噥噱噯噬噢噶壁墾壇壅奮嬝嬴學寰導彊憲憑憩憊懍憶憾懊懈戰擅擁擋撻撼據擄擇擂操撿擒擔撾整曆曉暹曄曇暸樽樸樺橙橫橘樹橄橢橡橋橇樵機橈歙歷氅濂澱澡"], +["bf40","濃澤濁澧澳激澹澶澦澠澴熾燉燐燒燈燕熹燎燙燜燃燄獨璜璣璘璟璞瓢甌甍瘴瘸瘺盧盥瞠瞞瞟瞥磨磚磬磧禦積穎穆穌穋窺篙簑築篤篛篡篩篦糕糖縊"], +["bfa1","縑縈縛縣縞縝縉縐罹羲翰翱翮耨膳膩膨臻興艘艙蕊蕙蕈蕨蕩蕃蕉蕭蕪蕞螃螟螞螢融衡褪褲褥褫褡親覦諦諺諫諱謀諜諧諮諾謁謂諷諭諳諶諼豫豭貓賴蹄踱踴蹂踹踵輻輯輸輳辨辦遵遴選遲遼遺鄴醒錠錶鋸錳錯錢鋼錫錄錚"], +["c040","錐錦錡錕錮錙閻隧隨險雕霎霑霖霍霓霏靛靜靦鞘頰頸頻頷頭頹頤餐館餞餛餡餚駭駢駱骸骼髻髭鬨鮑鴕鴣鴦鴨鴒鴛默黔龍龜優償儡儲勵嚎嚀嚐嚅嚇"], +["c0a1","嚏壕壓壑壎嬰嬪嬤孺尷屨嶼嶺嶽嶸幫彌徽應懂懇懦懋戲戴擎擊擘擠擰擦擬擱擢擭斂斃曙曖檀檔檄檢檜櫛檣橾檗檐檠歜殮毚氈濘濱濟濠濛濤濫濯澀濬濡濩濕濮濰燧營燮燦燥燭燬燴燠爵牆獰獲璩環璦璨癆療癌盪瞳瞪瞰瞬"], +["c140","瞧瞭矯磷磺磴磯礁禧禪穗窿簇簍篾篷簌篠糠糜糞糢糟糙糝縮績繆縷縲繃縫總縱繅繁縴縹繈縵縿縯罄翳翼聱聲聰聯聳臆臃膺臂臀膿膽臉膾臨舉艱薪"], +["c1a1","薄蕾薜薑薔薯薛薇薨薊虧蟀蟑螳蟒蟆螫螻螺蟈蟋褻褶襄褸褽覬謎謗謙講謊謠謝謄謐豁谿豳賺賽購賸賻趨蹉蹋蹈蹊轄輾轂轅輿避遽還邁邂邀鄹醣醞醜鍍鎂錨鍵鍊鍥鍋錘鍾鍬鍛鍰鍚鍔闊闋闌闈闆隱隸雖霜霞鞠韓顆颶餵騁"], +["c240","駿鮮鮫鮪鮭鴻鴿麋黏點黜黝黛鼾齋叢嚕嚮壙壘嬸彝懣戳擴擲擾攆擺擻擷斷曜朦檳檬櫃檻檸櫂檮檯歟歸殯瀉瀋濾瀆濺瀑瀏燻燼燾燸獷獵璧璿甕癖癘"], +["c2a1","癒瞽瞿瞻瞼礎禮穡穢穠竄竅簫簧簪簞簣簡糧織繕繞繚繡繒繙罈翹翻職聶臍臏舊藏薩藍藐藉薰薺薹薦蟯蟬蟲蟠覆覲觴謨謹謬謫豐贅蹙蹣蹦蹤蹟蹕軀轉轍邇邃邈醫醬釐鎔鎊鎖鎢鎳鎮鎬鎰鎘鎚鎗闔闖闐闕離雜雙雛雞霤鞣鞦"], +["c340","鞭韹額顏題顎顓颺餾餿餽餮馥騎髁鬃鬆魏魎魍鯊鯉鯽鯈鯀鵑鵝鵠黠鼕鼬儳嚥壞壟壢寵龐廬懲懷懶懵攀攏曠曝櫥櫝櫚櫓瀛瀟瀨瀚瀝瀕瀘爆爍牘犢獸"], +["c3a1","獺璽瓊瓣疇疆癟癡矇礙禱穫穩簾簿簸簽簷籀繫繭繹繩繪羅繳羶羹羸臘藩藝藪藕藤藥藷蟻蠅蠍蟹蟾襠襟襖襞譁譜識證譚譎譏譆譙贈贊蹼蹲躇蹶蹬蹺蹴轔轎辭邊邋醱醮鏡鏑鏟鏃鏈鏜鏝鏖鏢鏍鏘鏤鏗鏨關隴難霪霧靡韜韻類"], +["c440","願顛颼饅饉騖騙鬍鯨鯧鯖鯛鶉鵡鵲鵪鵬麒麗麓麴勸嚨嚷嚶嚴嚼壤孀孃孽寶巉懸懺攘攔攙曦朧櫬瀾瀰瀲爐獻瓏癢癥礦礪礬礫竇競籌籃籍糯糰辮繽繼"], +["c4a1","纂罌耀臚艦藻藹蘑藺蘆蘋蘇蘊蠔蠕襤覺觸議譬警譯譟譫贏贍躉躁躅躂醴釋鐘鐃鏽闡霰飄饒饑馨騫騰騷騵鰓鰍鹹麵黨鼯齟齣齡儷儸囁囀囂夔屬巍懼懾攝攜斕曩櫻欄櫺殲灌爛犧瓖瓔癩矓籐纏續羼蘗蘭蘚蠣蠢蠡蠟襪襬覽譴"], +["c540","護譽贓躊躍躋轟辯醺鐮鐳鐵鐺鐸鐲鐫闢霸霹露響顧顥饗驅驃驀騾髏魔魑鰭鰥鶯鶴鷂鶸麝黯鼙齜齦齧儼儻囈囊囉孿巔巒彎懿攤權歡灑灘玀瓤疊癮癬"], +["c5a1","禳籠籟聾聽臟襲襯觼讀贖贗躑躓轡酈鑄鑑鑒霽霾韃韁顫饕驕驍髒鬚鱉鰱鰾鰻鷓鷗鼴齬齪龔囌巖戀攣攫攪曬欐瓚竊籤籣籥纓纖纔臢蘸蘿蠱變邐邏鑣鑠鑤靨顯饜驚驛驗髓體髑鱔鱗鱖鷥麟黴囑壩攬灞癱癲矗罐羈蠶蠹衢讓讒"], +["c640","讖艷贛釀鑪靂靈靄韆顰驟鬢魘鱟鷹鷺鹼鹽鼇齷齲廳欖灣籬籮蠻觀躡釁鑲鑰顱饞髖鬣黌灤矚讚鑷韉驢驥纜讜躪釅鑽鑾鑼鱷鱸黷豔鑿鸚爨驪鬱鸛鸞籲"], +["c940","乂乜凵匚厂万丌乇亍囗兀屮彳丏冇与丮亓仂仉仈冘勼卬厹圠夃夬尐巿旡殳毌气爿丱丼仨仜仩仡仝仚刌匜卌圢圣夗夯宁宄尒尻屴屳帄庀庂忉戉扐氕"], +["c9a1","氶汃氿氻犮犰玊禸肊阞伎优伬仵伔仱伀价伈伝伂伅伢伓伄仴伒冱刓刉刐劦匢匟卍厊吇囡囟圮圪圴夼妀奼妅奻奾奷奿孖尕尥屼屺屻屾巟幵庄异弚彴忕忔忏扜扞扤扡扦扢扙扠扚扥旯旮朾朹朸朻机朿朼朳氘汆汒汜汏汊汔汋"], +["ca40","汌灱牞犴犵玎甪癿穵网艸艼芀艽艿虍襾邙邗邘邛邔阢阤阠阣佖伻佢佉体佤伾佧佒佟佁佘伭伳伿佡冏冹刜刞刡劭劮匉卣卲厎厏吰吷吪呔呅吙吜吥吘"], +["caa1","吽呏呁吨吤呇囮囧囥坁坅坌坉坋坒夆奀妦妘妠妗妎妢妐妏妧妡宎宒尨尪岍岏岈岋岉岒岊岆岓岕巠帊帎庋庉庌庈庍弅弝彸彶忒忑忐忭忨忮忳忡忤忣忺忯忷忻怀忴戺抃抌抎抏抔抇扱扻扺扰抁抈扷扽扲扴攷旰旴旳旲旵杅杇"], +["cb40","杙杕杌杈杝杍杚杋毐氙氚汸汧汫沄沋沏汱汯汩沚汭沇沕沜汦汳汥汻沎灴灺牣犿犽狃狆狁犺狅玕玗玓玔玒町甹疔疕皁礽耴肕肙肐肒肜芐芏芅芎芑芓"], +["cba1","芊芃芄豸迉辿邟邡邥邞邧邠阰阨阯阭丳侘佼侅佽侀侇佶佴侉侄佷佌侗佪侚佹侁佸侐侜侔侞侒侂侕佫佮冞冼冾刵刲刳剆刱劼匊匋匼厒厔咇呿咁咑咂咈呫呺呾呥呬呴呦咍呯呡呠咘呣呧呤囷囹坯坲坭坫坱坰坶垀坵坻坳坴坢"], +["cc40","坨坽夌奅妵妺姏姎妲姌姁妶妼姃姖妱妽姀姈妴姇孢孥宓宕屄屇岮岤岠岵岯岨岬岟岣岭岢岪岧岝岥岶岰岦帗帔帙弨弢弣弤彔徂彾彽忞忥怭怦怙怲怋"], +["cca1","怴怊怗怳怚怞怬怢怍怐怮怓怑怌怉怜戔戽抭抴拑抾抪抶拊抮抳抯抻抩抰抸攽斨斻昉旼昄昒昈旻昃昋昍昅旽昑昐曶朊枅杬枎枒杶杻枘枆构杴枍枌杺枟枑枙枃杽极杸杹枔欥殀歾毞氝沓泬泫泮泙沶泔沭泧沷泐泂沺泃泆泭泲"], +["cd40","泒泝沴沊沝沀泞泀洰泍泇沰泹泏泩泑炔炘炅炓炆炄炑炖炂炚炃牪狖狋狘狉狜狒狔狚狌狑玤玡玭玦玢玠玬玝瓝瓨甿畀甾疌疘皯盳盱盰盵矸矼矹矻矺"], +["cda1","矷祂礿秅穸穻竻籵糽耵肏肮肣肸肵肭舠芠苀芫芚芘芛芵芧芮芼芞芺芴芨芡芩苂芤苃芶芢虰虯虭虮豖迒迋迓迍迖迕迗邲邴邯邳邰阹阽阼阺陃俍俅俓侲俉俋俁俔俜俙侻侳俛俇俖侺俀侹俬剄剉勀勂匽卼厗厖厙厘咺咡咭咥哏"], +["ce40","哃茍咷咮哖咶哅哆咠呰咼咢咾呲哞咰垵垞垟垤垌垗垝垛垔垘垏垙垥垚垕壴复奓姡姞姮娀姱姝姺姽姼姶姤姲姷姛姩姳姵姠姾姴姭宨屌峐峘峌峗峋峛"], +["cea1","峞峚峉峇峊峖峓峔峏峈峆峎峟峸巹帡帢帣帠帤庰庤庢庛庣庥弇弮彖徆怷怹恔恲恞恅恓恇恉恛恌恀恂恟怤恄恘恦恮扂扃拏挍挋拵挎挃拫拹挏挌拸拶挀挓挔拺挕拻拰敁敃斪斿昶昡昲昵昜昦昢昳昫昺昝昴昹昮朏朐柁柲柈枺"], +["cf40","柜枻柸柘柀枷柅柫柤柟枵柍枳柷柶柮柣柂枹柎柧柰枲柼柆柭柌枮柦柛柺柉柊柃柪柋欨殂殄殶毖毘毠氠氡洨洴洭洟洼洿洒洊泚洳洄洙洺洚洑洀洝浂"], +["cfa1","洁洘洷洃洏浀洇洠洬洈洢洉洐炷炟炾炱炰炡炴炵炩牁牉牊牬牰牳牮狊狤狨狫狟狪狦狣玅珌珂珈珅玹玶玵玴珫玿珇玾珃珆玸珋瓬瓮甮畇畈疧疪癹盄眈眃眄眅眊盷盻盺矧矨砆砑砒砅砐砏砎砉砃砓祊祌祋祅祄秕种秏秖秎窀"], +["d040","穾竑笀笁籺籸籹籿粀粁紃紈紁罘羑羍羾耇耎耏耔耷胘胇胠胑胈胂胐胅胣胙胜胊胕胉胏胗胦胍臿舡芔苙苾苹茇苨茀苕茺苫苖苴苬苡苲苵茌苻苶苰苪"], +["d0a1","苤苠苺苳苭虷虴虼虳衁衎衧衪衩觓訄訇赲迣迡迮迠郱邽邿郕郅邾郇郋郈釔釓陔陏陑陓陊陎倞倅倇倓倢倰倛俵俴倳倷倬俶俷倗倜倠倧倵倯倱倎党冔冓凊凄凅凈凎剡剚剒剞剟剕剢勍匎厞唦哢唗唒哧哳哤唚哿唄唈哫唑唅哱"], +["d140","唊哻哷哸哠唎唃唋圁圂埌堲埕埒垺埆垽垼垸垶垿埇埐垹埁夎奊娙娖娭娮娕娏娗娊娞娳孬宧宭宬尃屖屔峬峿峮峱峷崀峹帩帨庨庮庪庬弳弰彧恝恚恧"], +["d1a1","恁悢悈悀悒悁悝悃悕悛悗悇悜悎戙扆拲挐捖挬捄捅挶捃揤挹捋捊挼挩捁挴捘捔捙挭捇挳捚捑挸捗捀捈敊敆旆旃旄旂晊晟晇晑朒朓栟栚桉栲栳栻桋桏栖栱栜栵栫栭栯桎桄栴栝栒栔栦栨栮桍栺栥栠欬欯欭欱欴歭肂殈毦毤"], +["d240","毨毣毢毧氥浺浣浤浶洍浡涒浘浢浭浯涑涍淯浿涆浞浧浠涗浰浼浟涂涘洯浨涋浾涀涄洖涃浻浽浵涐烜烓烑烝烋缹烢烗烒烞烠烔烍烅烆烇烚烎烡牂牸"], +["d2a1","牷牶猀狺狴狾狶狳狻猁珓珙珥珖玼珧珣珩珜珒珛珔珝珚珗珘珨瓞瓟瓴瓵甡畛畟疰痁疻痄痀疿疶疺皊盉眝眛眐眓眒眣眑眕眙眚眢眧砣砬砢砵砯砨砮砫砡砩砳砪砱祔祛祏祜祓祒祑秫秬秠秮秭秪秜秞秝窆窉窅窋窌窊窇竘笐"], +["d340","笄笓笅笏笈笊笎笉笒粄粑粊粌粈粍粅紞紝紑紎紘紖紓紟紒紏紌罜罡罞罠罝罛羖羒翃翂翀耖耾耹胺胲胹胵脁胻脀舁舯舥茳茭荄茙荑茥荖茿荁茦茜茢"], +["d3a1","荂荎茛茪茈茼荍茖茤茠茷茯茩荇荅荌荓茞茬荋茧荈虓虒蚢蚨蚖蚍蚑蚞蚇蚗蚆蚋蚚蚅蚥蚙蚡蚧蚕蚘蚎蚝蚐蚔衃衄衭衵衶衲袀衱衿衯袃衾衴衼訒豇豗豻貤貣赶赸趵趷趶軑軓迾迵适迿迻逄迼迶郖郠郙郚郣郟郥郘郛郗郜郤酐"], +["d440","酎酏釕釢釚陜陟隼飣髟鬯乿偰偪偡偞偠偓偋偝偲偈偍偁偛偊偢倕偅偟偩偫偣偤偆偀偮偳偗偑凐剫剭剬剮勖勓匭厜啵啶唼啍啐唴唪啑啢唶唵唰啒啅"], +["d4a1","唌唲啥啎唹啈唭唻啀啋圊圇埻堔埢埶埜埴堀埭埽堈埸堋埳埏堇埮埣埲埥埬埡堎埼堐埧堁堌埱埩埰堍堄奜婠婘婕婧婞娸娵婭婐婟婥婬婓婤婗婃婝婒婄婛婈媎娾婍娹婌婰婩婇婑婖婂婜孲孮寁寀屙崞崋崝崚崠崌崨崍崦崥崏"], +["d540","崰崒崣崟崮帾帴庱庴庹庲庳弶弸徛徖徟悊悐悆悾悰悺惓惔惏惤惙惝惈悱惛悷惊悿惃惍惀挲捥掊掂捽掽掞掭掝掗掫掎捯掇掐据掯捵掜捭掮捼掤挻掟"], +["d5a1","捸掅掁掑掍捰敓旍晥晡晛晙晜晢朘桹梇梐梜桭桮梮梫楖桯梣梬梩桵桴梲梏桷梒桼桫桲梪梀桱桾梛梖梋梠梉梤桸桻梑梌梊桽欶欳欷欸殑殏殍殎殌氪淀涫涴涳湴涬淩淢涷淶淔渀淈淠淟淖涾淥淜淝淛淴淊涽淭淰涺淕淂淏淉"], +["d640","淐淲淓淽淗淍淣涻烺焍烷焗烴焌烰焄烳焐烼烿焆焓焀烸烶焋焂焎牾牻牼牿猝猗猇猑猘猊猈狿猏猞玈珶珸珵琄琁珽琇琀珺珼珿琌琋珴琈畤畣痎痒痏"], +["d6a1","痋痌痑痐皏皉盓眹眯眭眱眲眴眳眽眥眻眵硈硒硉硍硊硌砦硅硐祤祧祩祪祣祫祡离秺秸秶秷窏窔窐笵筇笴笥笰笢笤笳笘笪笝笱笫笭笯笲笸笚笣粔粘粖粣紵紽紸紶紺絅紬紩絁絇紾紿絊紻紨罣羕羜羝羛翊翋翍翐翑翇翏翉耟"], +["d740","耞耛聇聃聈脘脥脙脛脭脟脬脞脡脕脧脝脢舑舸舳舺舴舲艴莐莣莨莍荺荳莤荴莏莁莕莙荵莔莩荽莃莌莝莛莪莋荾莥莯莈莗莰荿莦莇莮荶莚虙虖蚿蚷"], +["d7a1","蛂蛁蛅蚺蚰蛈蚹蚳蚸蛌蚴蚻蚼蛃蚽蚾衒袉袕袨袢袪袚袑袡袟袘袧袙袛袗袤袬袌袓袎覂觖觙觕訰訧訬訞谹谻豜豝豽貥赽赻赹趼跂趹趿跁軘軞軝軜軗軠軡逤逋逑逜逌逡郯郪郰郴郲郳郔郫郬郩酖酘酚酓酕釬釴釱釳釸釤釹釪"], +["d840","釫釷釨釮镺閆閈陼陭陫陱陯隿靪頄飥馗傛傕傔傞傋傣傃傌傎傝偨傜傒傂傇兟凔匒匑厤厧喑喨喥喭啷噅喢喓喈喏喵喁喣喒喤啽喌喦啿喕喡喎圌堩堷"], +["d8a1","堙堞堧堣堨埵塈堥堜堛堳堿堶堮堹堸堭堬堻奡媯媔媟婺媢媞婸媦婼媥媬媕媮娷媄媊媗媃媋媩婻婽媌媜媏媓媝寪寍寋寔寑寊寎尌尰崷嵃嵫嵁嵋崿崵嵑嵎嵕崳崺嵒崽崱嵙嵂崹嵉崸崼崲崶嵀嵅幄幁彘徦徥徫惉悹惌惢惎惄愔"], +["d940","惲愊愖愅惵愓惸惼惾惁愃愘愝愐惿愄愋扊掔掱掰揎揥揨揯揃撝揳揊揠揶揕揲揵摡揟掾揝揜揄揘揓揂揇揌揋揈揰揗揙攲敧敪敤敜敨敥斌斝斞斮旐旒"], +["d9a1","晼晬晻暀晱晹晪晲朁椌棓椄棜椪棬棪棱椏棖棷棫棤棶椓椐棳棡椇棌椈楰梴椑棯棆椔棸棐棽棼棨椋椊椗棎棈棝棞棦棴棑椆棔棩椕椥棇欹欻欿欼殔殗殙殕殽毰毲毳氰淼湆湇渟湉溈渼渽湅湢渫渿湁湝湳渜渳湋湀湑渻渃渮湞"], +["da40","湨湜湡渱渨湠湱湫渹渢渰湓湥渧湸湤湷湕湹湒湦渵渶湚焠焞焯烻焮焱焣焥焢焲焟焨焺焛牋牚犈犉犆犅犋猒猋猰猢猱猳猧猲猭猦猣猵猌琮琬琰琫琖"], +["daa1","琚琡琭琱琤琣琝琩琠琲瓻甯畯畬痧痚痡痦痝痟痤痗皕皒盚睆睇睄睍睅睊睎睋睌矞矬硠硤硥硜硭硱硪确硰硩硨硞硢祴祳祲祰稂稊稃稌稄窙竦竤筊笻筄筈筌筎筀筘筅粢粞粨粡絘絯絣絓絖絧絪絏絭絜絫絒絔絩絑絟絎缾缿罥"], +["db40","罦羢羠羡翗聑聏聐胾胔腃腊腒腏腇脽腍脺臦臮臷臸臹舄舼舽舿艵茻菏菹萣菀菨萒菧菤菼菶萐菆菈菫菣莿萁菝菥菘菿菡菋菎菖菵菉萉萏菞萑萆菂菳"], +["dba1","菕菺菇菑菪萓菃菬菮菄菻菗菢萛菛菾蛘蛢蛦蛓蛣蛚蛪蛝蛫蛜蛬蛩蛗蛨蛑衈衖衕袺裗袹袸裀袾袶袼袷袽袲褁裉覕覘覗觝觚觛詎詍訹詙詀詗詘詄詅詒詈詑詊詌詏豟貁貀貺貾貰貹貵趄趀趉跘跓跍跇跖跜跏跕跙跈跗跅軯軷軺"], +["dc40","軹軦軮軥軵軧軨軶軫軱軬軴軩逭逴逯鄆鄬鄄郿郼鄈郹郻鄁鄀鄇鄅鄃酡酤酟酢酠鈁鈊鈥鈃鈚鈦鈏鈌鈀鈒釿釽鈆鈄鈧鈂鈜鈤鈙鈗鈅鈖镻閍閌閐隇陾隈"], +["dca1","隉隃隀雂雈雃雱雰靬靰靮頇颩飫鳦黹亃亄亶傽傿僆傮僄僊傴僈僂傰僁傺傱僋僉傶傸凗剺剸剻剼嗃嗛嗌嗐嗋嗊嗝嗀嗔嗄嗩喿嗒喍嗏嗕嗢嗖嗈嗲嗍嗙嗂圔塓塨塤塏塍塉塯塕塎塝塙塥塛堽塣塱壼嫇嫄嫋媺媸媱媵媰媿嫈媻嫆"], +["dd40","媷嫀嫊媴媶嫍媹媐寖寘寙尟尳嵱嵣嵊嵥嵲嵬嵞嵨嵧嵢巰幏幎幊幍幋廅廌廆廋廇彀徯徭惷慉慊愫慅愶愲愮慆愯慏愩慀戠酨戣戥戤揅揱揫搐搒搉搠搤"], +["dda1","搳摃搟搕搘搹搷搢搣搌搦搰搨摁搵搯搊搚摀搥搧搋揧搛搮搡搎敯斒旓暆暌暕暐暋暊暙暔晸朠楦楟椸楎楢楱椿楅楪椹楂楗楙楺楈楉椵楬椳椽楥棰楸椴楩楀楯楄楶楘楁楴楌椻楋椷楜楏楑椲楒椯楻椼歆歅歃歂歈歁殛嗀毻毼"], +["de40","毹毷毸溛滖滈溏滀溟溓溔溠溱溹滆滒溽滁溞滉溷溰滍溦滏溲溾滃滜滘溙溒溎溍溤溡溿溳滐滊溗溮溣煇煔煒煣煠煁煝煢煲煸煪煡煂煘煃煋煰煟煐煓"], +["dea1","煄煍煚牏犍犌犑犐犎猼獂猻猺獀獊獉瑄瑊瑋瑒瑑瑗瑀瑏瑐瑎瑂瑆瑍瑔瓡瓿瓾瓽甝畹畷榃痯瘏瘃痷痾痼痹痸瘐痻痶痭痵痽皙皵盝睕睟睠睒睖睚睩睧睔睙睭矠碇碚碔碏碄碕碅碆碡碃硹碙碀碖硻祼禂祽祹稑稘稙稒稗稕稢稓"], +["df40","稛稐窣窢窞竫筦筤筭筴筩筲筥筳筱筰筡筸筶筣粲粴粯綈綆綀綍絿綅絺綎絻綃絼綌綔綄絽綒罭罫罧罨罬羦羥羧翛翜耡腤腠腷腜腩腛腢腲朡腞腶腧腯"], +["dfa1","腄腡舝艉艄艀艂艅蓱萿葖葶葹蒏蒍葥葑葀蒆葧萰葍葽葚葙葴葳葝蔇葞萷萺萴葺葃葸萲葅萩菙葋萯葂萭葟葰萹葎葌葒葯蓅蒎萻葇萶萳葨葾葄萫葠葔葮葐蜋蜄蛷蜌蛺蛖蛵蝍蛸蜎蜉蜁蛶蜍蜅裖裋裍裎裞裛裚裌裐覅覛觟觥觤"], +["e040","觡觠觢觜触詶誆詿詡訿詷誂誄詵誃誁詴詺谼豋豊豥豤豦貆貄貅賌赨赩趑趌趎趏趍趓趔趐趒跰跠跬跱跮跐跩跣跢跧跲跫跴輆軿輁輀輅輇輈輂輋遒逿"], +["e0a1","遄遉逽鄐鄍鄏鄑鄖鄔鄋鄎酮酯鉈鉒鈰鈺鉦鈳鉥鉞銃鈮鉊鉆鉭鉬鉏鉠鉧鉯鈶鉡鉰鈱鉔鉣鉐鉲鉎鉓鉌鉖鈲閟閜閞閛隒隓隑隗雎雺雽雸雵靳靷靸靲頏頍頎颬飶飹馯馲馰馵骭骫魛鳪鳭鳧麀黽僦僔僗僨僳僛僪僝僤僓僬僰僯僣僠"], +["e140","凘劀劁勩勫匰厬嘧嘕嘌嘒嗼嘏嘜嘁嘓嘂嗺嘝嘄嗿嗹墉塼墐墘墆墁塿塴墋塺墇墑墎塶墂墈塻墔墏壾奫嫜嫮嫥嫕嫪嫚嫭嫫嫳嫢嫠嫛嫬嫞嫝嫙嫨嫟孷寠"], +["e1a1","寣屣嶂嶀嵽嶆嵺嶁嵷嶊嶉嶈嵾嵼嶍嵹嵿幘幙幓廘廑廗廎廜廕廙廒廔彄彃彯徶愬愨慁慞慱慳慒慓慲慬憀慴慔慺慛慥愻慪慡慖戩戧戫搫摍摛摝摴摶摲摳摽摵摦撦摎撂摞摜摋摓摠摐摿搿摬摫摙摥摷敳斠暡暠暟朅朄朢榱榶槉"], +["e240","榠槎榖榰榬榼榑榙榎榧榍榩榾榯榿槄榽榤槔榹槊榚槏榳榓榪榡榞槙榗榐槂榵榥槆歊歍歋殞殟殠毃毄毾滎滵滱漃漥滸漷滻漮漉潎漙漚漧漘漻漒滭漊"], +["e2a1","漶潳滹滮漭潀漰漼漵滫漇漎潃漅滽滶漹漜滼漺漟漍漞漈漡熇熐熉熀熅熂熏煻熆熁熗牄牓犗犕犓獃獍獑獌瑢瑳瑱瑵瑲瑧瑮甀甂甃畽疐瘖瘈瘌瘕瘑瘊瘔皸瞁睼瞅瞂睮瞀睯睾瞃碲碪碴碭碨硾碫碞碥碠碬碢碤禘禊禋禖禕禔禓"], +["e340","禗禈禒禐稫穊稰稯稨稦窨窫窬竮箈箜箊箑箐箖箍箌箛箎箅箘劄箙箤箂粻粿粼粺綧綷緂綣綪緁緀緅綝緎緄緆緋緌綯綹綖綼綟綦綮綩綡緉罳翢翣翥翞"], +["e3a1","耤聝聜膉膆膃膇膍膌膋舕蒗蒤蒡蒟蒺蓎蓂蒬蒮蒫蒹蒴蓁蓍蒪蒚蒱蓐蒝蒧蒻蒢蒔蓇蓌蒛蒩蒯蒨蓖蒘蒶蓏蒠蓗蓔蓒蓛蒰蒑虡蜳蜣蜨蝫蝀蜮蜞蜡蜙蜛蝃蜬蝁蜾蝆蜠蜲蜪蜭蜼蜒蜺蜱蜵蝂蜦蜧蜸蜤蜚蜰蜑裷裧裱裲裺裾裮裼裶裻"], +["e440","裰裬裫覝覡覟覞觩觫觨誫誙誋誒誏誖谽豨豩賕賏賗趖踉踂跿踍跽踊踃踇踆踅跾踀踄輐輑輎輍鄣鄜鄠鄢鄟鄝鄚鄤鄡鄛酺酲酹酳銥銤鉶銛鉺銠銔銪銍"], +["e4a1","銦銚銫鉹銗鉿銣鋮銎銂銕銢鉽銈銡銊銆銌銙銧鉾銇銩銝銋鈭隞隡雿靘靽靺靾鞃鞀鞂靻鞄鞁靿韎韍頖颭颮餂餀餇馝馜駃馹馻馺駂馽駇骱髣髧鬾鬿魠魡魟鳱鳲鳵麧僿儃儰僸儆儇僶僾儋儌僽儊劋劌勱勯噈噂噌嘵噁噊噉噆噘"], +["e540","噚噀嘳嘽嘬嘾嘸嘪嘺圚墫墝墱墠墣墯墬墥墡壿嫿嫴嫽嫷嫶嬃嫸嬂嫹嬁嬇嬅嬏屧嶙嶗嶟嶒嶢嶓嶕嶠嶜嶡嶚嶞幩幝幠幜緳廛廞廡彉徲憋憃慹憱憰憢憉"], +["e5a1","憛憓憯憭憟憒憪憡憍慦憳戭摮摰撖撠撅撗撜撏撋撊撌撣撟摨撱撘敶敺敹敻斲斳暵暰暩暲暷暪暯樀樆樗槥槸樕槱槤樠槿槬槢樛樝槾樧槲槮樔槷槧橀樈槦槻樍槼槫樉樄樘樥樏槶樦樇槴樖歑殥殣殢殦氁氀毿氂潁漦潾澇濆澒"], +["e640","澍澉澌潢潏澅潚澖潶潬澂潕潲潒潐潗澔澓潝漀潡潫潽潧澐潓澋潩潿澕潣潷潪潻熲熯熛熰熠熚熩熵熝熥熞熤熡熪熜熧熳犘犚獘獒獞獟獠獝獛獡獚獙"], +["e6a1","獢璇璉璊璆璁瑽璅璈瑼瑹甈甇畾瘥瘞瘙瘝瘜瘣瘚瘨瘛皜皝皞皛瞍瞏瞉瞈磍碻磏磌磑磎磔磈磃磄磉禚禡禠禜禢禛歶稹窲窴窳箷篋箾箬篎箯箹篊箵糅糈糌糋緷緛緪緧緗緡縃緺緦緶緱緰緮緟罶羬羰羭翭翫翪翬翦翨聤聧膣膟"], +["e740","膞膕膢膙膗舖艏艓艒艐艎艑蔤蔻蔏蔀蔩蔎蔉蔍蔟蔊蔧蔜蓻蔫蓺蔈蔌蓴蔪蓲蔕蓷蓫蓳蓼蔒蓪蓩蔖蓾蔨蔝蔮蔂蓽蔞蓶蔱蔦蓧蓨蓰蓯蓹蔘蔠蔰蔋蔙蔯虢"], +["e7a1","蝖蝣蝤蝷蟡蝳蝘蝔蝛蝒蝡蝚蝑蝞蝭蝪蝐蝎蝟蝝蝯蝬蝺蝮蝜蝥蝏蝻蝵蝢蝧蝩衚褅褌褔褋褗褘褙褆褖褑褎褉覢覤覣觭觰觬諏諆誸諓諑諔諕誻諗誾諀諅諘諃誺誽諙谾豍貏賥賟賙賨賚賝賧趠趜趡趛踠踣踥踤踮踕踛踖踑踙踦踧"], +["e840","踔踒踘踓踜踗踚輬輤輘輚輠輣輖輗遳遰遯遧遫鄯鄫鄩鄪鄲鄦鄮醅醆醊醁醂醄醀鋐鋃鋄鋀鋙銶鋏鋱鋟鋘鋩鋗鋝鋌鋯鋂鋨鋊鋈鋎鋦鋍鋕鋉鋠鋞鋧鋑鋓"], +["e8a1","銵鋡鋆銴镼閬閫閮閰隤隢雓霅霈霂靚鞊鞎鞈韐韏頞頝頦頩頨頠頛頧颲餈飺餑餔餖餗餕駜駍駏駓駔駎駉駖駘駋駗駌骳髬髫髳髲髱魆魃魧魴魱魦魶魵魰魨魤魬鳼鳺鳽鳿鳷鴇鴀鳹鳻鴈鴅鴄麃黓鼏鼐儜儓儗儚儑凞匴叡噰噠噮"], +["e940","噳噦噣噭噲噞噷圜圛壈墽壉墿墺壂墼壆嬗嬙嬛嬡嬔嬓嬐嬖嬨嬚嬠嬞寯嶬嶱嶩嶧嶵嶰嶮嶪嶨嶲嶭嶯嶴幧幨幦幯廩廧廦廨廥彋徼憝憨憖懅憴懆懁懌憺"], +["e9a1","憿憸憌擗擖擐擏擉撽撉擃擛擳擙攳敿敼斢曈暾曀曊曋曏暽暻暺曌朣樴橦橉橧樲橨樾橝橭橶橛橑樨橚樻樿橁橪橤橐橏橔橯橩橠樼橞橖橕橍橎橆歕歔歖殧殪殫毈毇氄氃氆澭濋澣濇澼濎濈潞濄澽澞濊澨瀄澥澮澺澬澪濏澿澸"], +["ea40","澢濉澫濍澯澲澰燅燂熿熸燖燀燁燋燔燊燇燏熽燘熼燆燚燛犝犞獩獦獧獬獥獫獪瑿璚璠璔璒璕璡甋疀瘯瘭瘱瘽瘳瘼瘵瘲瘰皻盦瞚瞝瞡瞜瞛瞢瞣瞕瞙"], +["eaa1","瞗磝磩磥磪磞磣磛磡磢磭磟磠禤穄穈穇窶窸窵窱窷篞篣篧篝篕篥篚篨篹篔篪篢篜篫篘篟糒糔糗糐糑縒縡縗縌縟縠縓縎縜縕縚縢縋縏縖縍縔縥縤罃罻罼罺羱翯耪耩聬膱膦膮膹膵膫膰膬膴膲膷膧臲艕艖艗蕖蕅蕫蕍蕓蕡蕘"], +["eb40","蕀蕆蕤蕁蕢蕄蕑蕇蕣蔾蕛蕱蕎蕮蕵蕕蕧蕠薌蕦蕝蕔蕥蕬虣虥虤螛螏螗螓螒螈螁螖螘蝹螇螣螅螐螑螝螄螔螜螚螉褞褦褰褭褮褧褱褢褩褣褯褬褟觱諠"], +["eba1","諢諲諴諵諝謔諤諟諰諈諞諡諨諿諯諻貑貒貐賵賮賱賰賳赬赮趥趧踳踾踸蹀蹅踶踼踽蹁踰踿躽輶輮輵輲輹輷輴遶遹遻邆郺鄳鄵鄶醓醐醑醍醏錧錞錈錟錆錏鍺錸錼錛錣錒錁鍆錭錎錍鋋錝鋺錥錓鋹鋷錴錂錤鋿錩錹錵錪錔錌"], +["ec40","錋鋾錉錀鋻錖閼闍閾閹閺閶閿閵閽隩雔霋霒霐鞙鞗鞔韰韸頵頯頲餤餟餧餩馞駮駬駥駤駰駣駪駩駧骹骿骴骻髶髺髹髷鬳鮀鮅鮇魼魾魻鮂鮓鮒鮐魺鮕"], +["eca1","魽鮈鴥鴗鴠鴞鴔鴩鴝鴘鴢鴐鴙鴟麈麆麇麮麭黕黖黺鼒鼽儦儥儢儤儠儩勴嚓嚌嚍嚆嚄嚃噾嚂噿嚁壖壔壏壒嬭嬥嬲嬣嬬嬧嬦嬯嬮孻寱寲嶷幬幪徾徻懃憵憼懧懠懥懤懨懞擯擩擣擫擤擨斁斀斶旚曒檍檖檁檥檉檟檛檡檞檇檓檎"], +["ed40","檕檃檨檤檑橿檦檚檅檌檒歛殭氉濌澩濴濔濣濜濭濧濦濞濲濝濢濨燡燱燨燲燤燰燢獳獮獯璗璲璫璐璪璭璱璥璯甐甑甒甏疄癃癈癉癇皤盩瞵瞫瞲瞷瞶"], +["eda1","瞴瞱瞨矰磳磽礂磻磼磲礅磹磾礄禫禨穜穛穖穘穔穚窾竀竁簅簏篲簀篿篻簎篴簋篳簂簉簃簁篸篽簆篰篱簐簊糨縭縼繂縳顈縸縪繉繀繇縩繌縰縻縶繄縺罅罿罾罽翴翲耬膻臄臌臊臅臇膼臩艛艚艜薃薀薏薧薕薠薋薣蕻薤薚薞"], +["ee40","蕷蕼薉薡蕺蕸蕗薎薖薆薍薙薝薁薢薂薈薅蕹蕶薘薐薟虨螾螪螭蟅螰螬螹螵螼螮蟉蟃蟂蟌螷螯蟄蟊螴螶螿螸螽蟞螲褵褳褼褾襁襒褷襂覭覯覮觲觳謞"], +["eea1","謘謖謑謅謋謢謏謒謕謇謍謈謆謜謓謚豏豰豲豱豯貕貔賹赯蹎蹍蹓蹐蹌蹇轃轀邅遾鄸醚醢醛醙醟醡醝醠鎡鎃鎯鍤鍖鍇鍼鍘鍜鍶鍉鍐鍑鍠鍭鎏鍌鍪鍹鍗鍕鍒鍏鍱鍷鍻鍡鍞鍣鍧鎀鍎鍙闇闀闉闃闅閷隮隰隬霠霟霘霝霙鞚鞡鞜"], +["ef40","鞞鞝韕韔韱顁顄顊顉顅顃餥餫餬餪餳餲餯餭餱餰馘馣馡騂駺駴駷駹駸駶駻駽駾駼騃骾髾髽鬁髼魈鮚鮨鮞鮛鮦鮡鮥鮤鮆鮢鮠鮯鴳鵁鵧鴶鴮鴯鴱鴸鴰"], +["efa1","鵅鵂鵃鴾鴷鵀鴽翵鴭麊麉麍麰黈黚黻黿鼤鼣鼢齔龠儱儭儮嚘嚜嚗嚚嚝嚙奰嬼屩屪巀幭幮懘懟懭懮懱懪懰懫懖懩擿攄擽擸攁攃擼斔旛曚曛曘櫅檹檽櫡櫆檺檶檷櫇檴檭歞毉氋瀇瀌瀍瀁瀅瀔瀎濿瀀濻瀦濼濷瀊爁燿燹爃燽獶"], +["f040","璸瓀璵瓁璾璶璻瓂甔甓癜癤癙癐癓癗癚皦皽盬矂瞺磿礌礓礔礉礐礒礑禭禬穟簜簩簙簠簟簭簝簦簨簢簥簰繜繐繖繣繘繢繟繑繠繗繓羵羳翷翸聵臑臒"], +["f0a1","臐艟艞薴藆藀藃藂薳薵薽藇藄薿藋藎藈藅薱薶藒蘤薸薷薾虩蟧蟦蟢蟛蟫蟪蟥蟟蟳蟤蟔蟜蟓蟭蟘蟣螤蟗蟙蠁蟴蟨蟝襓襋襏襌襆襐襑襉謪謧謣謳謰謵譇謯謼謾謱謥謷謦謶謮謤謻謽謺豂豵貙貘貗賾贄贂贀蹜蹢蹠蹗蹖蹞蹥蹧"], +["f140","蹛蹚蹡蹝蹩蹔轆轇轈轋鄨鄺鄻鄾醨醥醧醯醪鎵鎌鎒鎷鎛鎝鎉鎧鎎鎪鎞鎦鎕鎈鎙鎟鎍鎱鎑鎲鎤鎨鎴鎣鎥闒闓闑隳雗雚巂雟雘雝霣霢霥鞬鞮鞨鞫鞤鞪"], +["f1a1","鞢鞥韗韙韖韘韺顐顑顒颸饁餼餺騏騋騉騍騄騑騊騅騇騆髀髜鬈鬄鬅鬩鬵魊魌魋鯇鯆鯃鮿鯁鮵鮸鯓鮶鯄鮹鮽鵜鵓鵏鵊鵛鵋鵙鵖鵌鵗鵒鵔鵟鵘鵚麎麌黟鼁鼀鼖鼥鼫鼪鼩鼨齌齕儴儵劖勷厴嚫嚭嚦嚧嚪嚬壚壝壛夒嬽嬾嬿巃幰"], +["f240","徿懻攇攐攍攉攌攎斄旞旝曞櫧櫠櫌櫑櫙櫋櫟櫜櫐櫫櫏櫍櫞歠殰氌瀙瀧瀠瀖瀫瀡瀢瀣瀩瀗瀤瀜瀪爌爊爇爂爅犥犦犤犣犡瓋瓅璷瓃甖癠矉矊矄矱礝礛"], +["f2a1","礡礜礗礞禰穧穨簳簼簹簬簻糬糪繶繵繸繰繷繯繺繲繴繨罋罊羃羆羷翽翾聸臗臕艤艡艣藫藱藭藙藡藨藚藗藬藲藸藘藟藣藜藑藰藦藯藞藢蠀蟺蠃蟶蟷蠉蠌蠋蠆蟼蠈蟿蠊蠂襢襚襛襗襡襜襘襝襙覈覷覶觶譐譈譊譀譓譖譔譋譕"], +["f340","譑譂譒譗豃豷豶貚贆贇贉趬趪趭趫蹭蹸蹳蹪蹯蹻軂轒轑轏轐轓辴酀鄿醰醭鏞鏇鏏鏂鏚鏐鏹鏬鏌鏙鎩鏦鏊鏔鏮鏣鏕鏄鏎鏀鏒鏧镽闚闛雡霩霫霬霨霦"], +["f3a1","鞳鞷鞶韝韞韟顜顙顝顗颿颽颻颾饈饇饃馦馧騚騕騥騝騤騛騢騠騧騣騞騜騔髂鬋鬊鬎鬌鬷鯪鯫鯠鯞鯤鯦鯢鯰鯔鯗鯬鯜鯙鯥鯕鯡鯚鵷鶁鶊鶄鶈鵱鶀鵸鶆鶋鶌鵽鵫鵴鵵鵰鵩鶅鵳鵻鶂鵯鵹鵿鶇鵨麔麑黀黼鼭齀齁齍齖齗齘匷嚲"], +["f440","嚵嚳壣孅巆巇廮廯忀忁懹攗攖攕攓旟曨曣曤櫳櫰櫪櫨櫹櫱櫮櫯瀼瀵瀯瀷瀴瀱灂瀸瀿瀺瀹灀瀻瀳灁爓爔犨獽獼璺皫皪皾盭矌矎矏矍矲礥礣礧礨礤礩"], +["f4a1","禲穮穬穭竷籉籈籊籇籅糮繻繾纁纀羺翿聹臛臙舋艨艩蘢藿蘁藾蘛蘀藶蘄蘉蘅蘌藽蠙蠐蠑蠗蠓蠖襣襦覹觷譠譪譝譨譣譥譧譭趮躆躈躄轙轖轗轕轘轚邍酃酁醷醵醲醳鐋鐓鏻鐠鐏鐔鏾鐕鐐鐨鐙鐍鏵鐀鏷鐇鐎鐖鐒鏺鐉鏸鐊鏿"], +["f540","鏼鐌鏶鐑鐆闞闠闟霮霯鞹鞻韽韾顠顢顣顟飁飂饐饎饙饌饋饓騲騴騱騬騪騶騩騮騸騭髇髊髆鬐鬒鬑鰋鰈鯷鰅鰒鯸鱀鰇鰎鰆鰗鰔鰉鶟鶙鶤鶝鶒鶘鶐鶛"], +["f5a1","鶠鶔鶜鶪鶗鶡鶚鶢鶨鶞鶣鶿鶩鶖鶦鶧麙麛麚黥黤黧黦鼰鼮齛齠齞齝齙龑儺儹劘劗囃嚽嚾孈孇巋巏廱懽攛欂櫼欃櫸欀灃灄灊灈灉灅灆爝爚爙獾甗癪矐礭礱礯籔籓糲纊纇纈纋纆纍罍羻耰臝蘘蘪蘦蘟蘣蘜蘙蘧蘮蘡蘠蘩蘞蘥"], +["f640","蠩蠝蠛蠠蠤蠜蠫衊襭襩襮襫觺譹譸譅譺譻贐贔趯躎躌轞轛轝酆酄酅醹鐿鐻鐶鐩鐽鐼鐰鐹鐪鐷鐬鑀鐱闥闤闣霵霺鞿韡顤飉飆飀饘饖騹騽驆驄驂驁騺"], +["f6a1","騿髍鬕鬗鬘鬖鬺魒鰫鰝鰜鰬鰣鰨鰩鰤鰡鶷鶶鶼鷁鷇鷊鷏鶾鷅鷃鶻鶵鷎鶹鶺鶬鷈鶱鶭鷌鶳鷍鶲鹺麜黫黮黭鼛鼘鼚鼱齎齥齤龒亹囆囅囋奱孋孌巕巑廲攡攠攦攢欋欈欉氍灕灖灗灒爞爟犩獿瓘瓕瓙瓗癭皭礵禴穰穱籗籜籙籛籚"], +["f740","糴糱纑罏羇臞艫蘴蘵蘳蘬蘲蘶蠬蠨蠦蠪蠥襱覿覾觻譾讄讂讆讅譿贕躕躔躚躒躐躖躗轠轢酇鑌鑐鑊鑋鑏鑇鑅鑈鑉鑆霿韣顪顩飋饔饛驎驓驔驌驏驈驊"], +["f7a1","驉驒驐髐鬙鬫鬻魖魕鱆鱈鰿鱄鰹鰳鱁鰼鰷鰴鰲鰽鰶鷛鷒鷞鷚鷋鷐鷜鷑鷟鷩鷙鷘鷖鷵鷕鷝麶黰鼵鼳鼲齂齫龕龢儽劙壨壧奲孍巘蠯彏戁戃戄攩攥斖曫欑欒欏毊灛灚爢玂玁玃癰矔籧籦纕艬蘺虀蘹蘼蘱蘻蘾蠰蠲蠮蠳襶襴襳觾"], +["f840","讌讎讋讈豅贙躘轤轣醼鑢鑕鑝鑗鑞韄韅頀驖驙鬞鬟鬠鱒鱘鱐鱊鱍鱋鱕鱙鱌鱎鷻鷷鷯鷣鷫鷸鷤鷶鷡鷮鷦鷲鷰鷢鷬鷴鷳鷨鷭黂黐黲黳鼆鼜鼸鼷鼶齃齏"], +["f8a1","齱齰齮齯囓囍孎屭攭曭曮欓灟灡灝灠爣瓛瓥矕礸禷禶籪纗羉艭虃蠸蠷蠵衋讔讕躞躟躠躝醾醽釂鑫鑨鑩雥靆靃靇韇韥驞髕魙鱣鱧鱦鱢鱞鱠鸂鷾鸇鸃鸆鸅鸀鸁鸉鷿鷽鸄麠鼞齆齴齵齶囔攮斸欘欙欗欚灢爦犪矘矙礹籩籫糶纚"], +["f940","纘纛纙臠臡虆虇虈襹襺襼襻觿讘讙躥躤躣鑮鑭鑯鑱鑳靉顲饟鱨鱮鱭鸋鸍鸐鸏鸒鸑麡黵鼉齇齸齻齺齹圞灦籯蠼趲躦釃鑴鑸鑶鑵驠鱴鱳鱱鱵鸔鸓黶鼊"], +["f9a1","龤灨灥糷虪蠾蠽蠿讞貜躩軉靋顳顴飌饡馫驤驦驧鬤鸕鸗齈戇欞爧虌躨钂钀钁驩驨鬮鸙爩虋讟钃鱹麷癵驫鱺鸝灩灪麤齾齉龘碁銹裏墻恒粧嫺╔╦╗╠╬╣╚╩╝╒╤╕╞╪╡╘╧╛╓╥╖╟╫╢╙╨╜║═╭╮╰╯▓"] +] diff --git a/node_modules/body-parser/node_modules/iconv-lite/encodings/tables/eucjp.json b/node_modules/body-parser/node_modules/iconv-lite/encodings/tables/eucjp.json new file mode 100644 index 0000000..4fa61ca --- /dev/null +++ b/node_modules/body-parser/node_modules/iconv-lite/encodings/tables/eucjp.json @@ -0,0 +1,182 @@ +[ +["0","\u0000",127], +["8ea1","。",62], +["a1a1"," 、。,.・:;?!゛゜´`¨^ ̄_ヽヾゝゞ〃仝々〆〇ー―‐/\~∥|…‥‘’“”()〔〕[]{}〈",9,"+-±×÷=≠<>≦≧∞∴♂♀°′″℃¥$¢£%#&*@§☆★○●◎◇"], +["a2a1","◆□■△▲▽▼※〒→←↑↓〓"], +["a2ba","∈∋⊆⊇⊂⊃∪∩"], +["a2ca","∧∨¬⇒⇔∀∃"], +["a2dc","∠⊥⌒∂∇≡≒≪≫√∽∝∵∫∬"], +["a2f2","ʼn♯♭♪†‡¶"], +["a2fe","◯"], +["a3b0","0",9], +["a3c1","A",25], +["a3e1","a",25], +["a4a1","ぁ",82], +["a5a1","ァ",85], +["a6a1","Α",16,"Σ",6], +["a6c1","α",16,"σ",6], +["a7a1","А",5,"ЁЖ",25], +["a7d1","а",5,"ёж",25], +["a8a1","─│┌┐┘└├┬┤┴┼━┃┏┓┛┗┣┳┫┻╋┠┯┨┷┿┝┰┥┸╂"], +["ada1","①",19,"Ⅰ",9], +["adc0","㍉㌔㌢㍍㌘㌧㌃㌶㍑㍗㌍㌦㌣㌫㍊㌻㎜㎝㎞㎎㎏㏄㎡"], +["addf","㍻〝〟№㏍℡㊤",4,"㈱㈲㈹㍾㍽㍼≒≡∫∮∑√⊥∠∟⊿∵∩∪"], +["b0a1","亜唖娃阿哀愛挨姶逢葵茜穐悪握渥旭葦芦鯵梓圧斡扱宛姐虻飴絢綾鮎或粟袷安庵按暗案闇鞍杏以伊位依偉囲夷委威尉惟意慰易椅為畏異移維緯胃萎衣謂違遺医井亥域育郁磯一壱溢逸稲茨芋鰯允印咽員因姻引飲淫胤蔭"], +["b1a1","院陰隠韻吋右宇烏羽迂雨卯鵜窺丑碓臼渦嘘唄欝蔚鰻姥厩浦瓜閏噂云運雲荏餌叡営嬰影映曳栄永泳洩瑛盈穎頴英衛詠鋭液疫益駅悦謁越閲榎厭円園堰奄宴延怨掩援沿演炎焔煙燕猿縁艶苑薗遠鉛鴛塩於汚甥凹央奥往応"], +["b2a1","押旺横欧殴王翁襖鴬鴎黄岡沖荻億屋憶臆桶牡乙俺卸恩温穏音下化仮何伽価佳加可嘉夏嫁家寡科暇果架歌河火珂禍禾稼箇花苛茄荷華菓蝦課嘩貨迦過霞蚊俄峨我牙画臥芽蛾賀雅餓駕介会解回塊壊廻快怪悔恢懐戒拐改"], +["b3a1","魁晦械海灰界皆絵芥蟹開階貝凱劾外咳害崖慨概涯碍蓋街該鎧骸浬馨蛙垣柿蛎鈎劃嚇各廓拡撹格核殻獲確穫覚角赫較郭閣隔革学岳楽額顎掛笠樫橿梶鰍潟割喝恰括活渇滑葛褐轄且鰹叶椛樺鞄株兜竃蒲釜鎌噛鴨栢茅萱"], +["b4a1","粥刈苅瓦乾侃冠寒刊勘勧巻喚堪姦完官寛干幹患感慣憾換敢柑桓棺款歓汗漢澗潅環甘監看竿管簡緩缶翰肝艦莞観諌貫還鑑間閑関陥韓館舘丸含岸巌玩癌眼岩翫贋雁頑顔願企伎危喜器基奇嬉寄岐希幾忌揮机旗既期棋棄"], +["b5a1","機帰毅気汽畿祈季稀紀徽規記貴起軌輝飢騎鬼亀偽儀妓宜戯技擬欺犠疑祇義蟻誼議掬菊鞠吉吃喫桔橘詰砧杵黍却客脚虐逆丘久仇休及吸宮弓急救朽求汲泣灸球究窮笈級糾給旧牛去居巨拒拠挙渠虚許距鋸漁禦魚亨享京"], +["b6a1","供侠僑兇競共凶協匡卿叫喬境峡強彊怯恐恭挟教橋況狂狭矯胸脅興蕎郷鏡響饗驚仰凝尭暁業局曲極玉桐粁僅勤均巾錦斤欣欽琴禁禽筋緊芹菌衿襟謹近金吟銀九倶句区狗玖矩苦躯駆駈駒具愚虞喰空偶寓遇隅串櫛釧屑屈"], +["b7a1","掘窟沓靴轡窪熊隈粂栗繰桑鍬勲君薫訓群軍郡卦袈祁係傾刑兄啓圭珪型契形径恵慶慧憩掲携敬景桂渓畦稽系経継繋罫茎荊蛍計詣警軽頚鶏芸迎鯨劇戟撃激隙桁傑欠決潔穴結血訣月件倹倦健兼券剣喧圏堅嫌建憲懸拳捲"], +["b8a1","検権牽犬献研硯絹県肩見謙賢軒遣鍵険顕験鹸元原厳幻弦減源玄現絃舷言諺限乎個古呼固姑孤己庫弧戸故枯湖狐糊袴股胡菰虎誇跨鈷雇顧鼓五互伍午呉吾娯後御悟梧檎瑚碁語誤護醐乞鯉交佼侯候倖光公功効勾厚口向"], +["b9a1","后喉坑垢好孔孝宏工巧巷幸広庚康弘恒慌抗拘控攻昂晃更杭校梗構江洪浩港溝甲皇硬稿糠紅紘絞綱耕考肯肱腔膏航荒行衡講貢購郊酵鉱砿鋼閤降項香高鴻剛劫号合壕拷濠豪轟麹克刻告国穀酷鵠黒獄漉腰甑忽惚骨狛込"], +["baa1","此頃今困坤墾婚恨懇昏昆根梱混痕紺艮魂些佐叉唆嵯左差査沙瑳砂詐鎖裟坐座挫債催再最哉塞妻宰彩才採栽歳済災采犀砕砦祭斎細菜裁載際剤在材罪財冴坂阪堺榊肴咲崎埼碕鷺作削咋搾昨朔柵窄策索錯桜鮭笹匙冊刷"], +["bba1","察拶撮擦札殺薩雑皐鯖捌錆鮫皿晒三傘参山惨撒散桟燦珊産算纂蚕讃賛酸餐斬暫残仕仔伺使刺司史嗣四士始姉姿子屍市師志思指支孜斯施旨枝止死氏獅祉私糸紙紫肢脂至視詞詩試誌諮資賜雌飼歯事似侍児字寺慈持時"], +["bca1","次滋治爾璽痔磁示而耳自蒔辞汐鹿式識鴫竺軸宍雫七叱執失嫉室悉湿漆疾質実蔀篠偲柴芝屡蕊縞舎写射捨赦斜煮社紗者謝車遮蛇邪借勺尺杓灼爵酌釈錫若寂弱惹主取守手朱殊狩珠種腫趣酒首儒受呪寿授樹綬需囚収周"], +["bda1","宗就州修愁拾洲秀秋終繍習臭舟蒐衆襲讐蹴輯週酋酬集醜什住充十従戎柔汁渋獣縦重銃叔夙宿淑祝縮粛塾熟出術述俊峻春瞬竣舜駿准循旬楯殉淳準潤盾純巡遵醇順処初所暑曙渚庶緒署書薯藷諸助叙女序徐恕鋤除傷償"], +["bea1","勝匠升召哨商唱嘗奨妾娼宵将小少尚庄床廠彰承抄招掌捷昇昌昭晶松梢樟樵沼消渉湘焼焦照症省硝礁祥称章笑粧紹肖菖蒋蕉衝裳訟証詔詳象賞醤鉦鍾鐘障鞘上丈丞乗冗剰城場壌嬢常情擾条杖浄状畳穣蒸譲醸錠嘱埴飾"], +["bfa1","拭植殖燭織職色触食蝕辱尻伸信侵唇娠寝審心慎振新晋森榛浸深申疹真神秦紳臣芯薪親診身辛進針震人仁刃塵壬尋甚尽腎訊迅陣靭笥諏須酢図厨逗吹垂帥推水炊睡粋翠衰遂酔錐錘随瑞髄崇嵩数枢趨雛据杉椙菅頗雀裾"], +["c0a1","澄摺寸世瀬畝是凄制勢姓征性成政整星晴棲栖正清牲生盛精聖声製西誠誓請逝醒青静斉税脆隻席惜戚斥昔析石積籍績脊責赤跡蹟碩切拙接摂折設窃節説雪絶舌蝉仙先千占宣専尖川戦扇撰栓栴泉浅洗染潜煎煽旋穿箭線"], +["c1a1","繊羨腺舛船薦詮賎践選遷銭銑閃鮮前善漸然全禅繕膳糎噌塑岨措曾曽楚狙疏疎礎祖租粗素組蘇訴阻遡鼠僧創双叢倉喪壮奏爽宋層匝惣想捜掃挿掻操早曹巣槍槽漕燥争痩相窓糟総綜聡草荘葬蒼藻装走送遭鎗霜騒像増憎"], +["c2a1","臓蔵贈造促側則即息捉束測足速俗属賊族続卒袖其揃存孫尊損村遜他多太汰詑唾堕妥惰打柁舵楕陀駄騨体堆対耐岱帯待怠態戴替泰滞胎腿苔袋貸退逮隊黛鯛代台大第醍題鷹滝瀧卓啄宅托択拓沢濯琢託鐸濁諾茸凧蛸只"], +["c3a1","叩但達辰奪脱巽竪辿棚谷狸鱈樽誰丹単嘆坦担探旦歎淡湛炭短端箪綻耽胆蛋誕鍛団壇弾断暖檀段男談値知地弛恥智池痴稚置致蜘遅馳築畜竹筑蓄逐秩窒茶嫡着中仲宙忠抽昼柱注虫衷註酎鋳駐樗瀦猪苧著貯丁兆凋喋寵"], +["c4a1","帖帳庁弔張彫徴懲挑暢朝潮牒町眺聴脹腸蝶調諜超跳銚長頂鳥勅捗直朕沈珍賃鎮陳津墜椎槌追鎚痛通塚栂掴槻佃漬柘辻蔦綴鍔椿潰坪壷嬬紬爪吊釣鶴亭低停偵剃貞呈堤定帝底庭廷弟悌抵挺提梯汀碇禎程締艇訂諦蹄逓"], +["c5a1","邸鄭釘鼎泥摘擢敵滴的笛適鏑溺哲徹撤轍迭鉄典填天展店添纏甜貼転顛点伝殿澱田電兎吐堵塗妬屠徒斗杜渡登菟賭途都鍍砥砺努度土奴怒倒党冬凍刀唐塔塘套宕島嶋悼投搭東桃梼棟盗淘湯涛灯燈当痘祷等答筒糖統到"], +["c6a1","董蕩藤討謄豆踏逃透鐙陶頭騰闘働動同堂導憧撞洞瞳童胴萄道銅峠鴇匿得徳涜特督禿篤毒独読栃橡凸突椴届鳶苫寅酉瀞噸屯惇敦沌豚遁頓呑曇鈍奈那内乍凪薙謎灘捺鍋楢馴縄畷南楠軟難汝二尼弐迩匂賑肉虹廿日乳入"], +["c7a1","如尿韮任妊忍認濡禰祢寧葱猫熱年念捻撚燃粘乃廼之埜嚢悩濃納能脳膿農覗蚤巴把播覇杷波派琶破婆罵芭馬俳廃拝排敗杯盃牌背肺輩配倍培媒梅楳煤狽買売賠陪這蝿秤矧萩伯剥博拍柏泊白箔粕舶薄迫曝漠爆縛莫駁麦"], +["c8a1","函箱硲箸肇筈櫨幡肌畑畠八鉢溌発醗髪伐罰抜筏閥鳩噺塙蛤隼伴判半反叛帆搬斑板氾汎版犯班畔繁般藩販範釆煩頒飯挽晩番盤磐蕃蛮匪卑否妃庇彼悲扉批披斐比泌疲皮碑秘緋罷肥被誹費避非飛樋簸備尾微枇毘琵眉美"], +["c9a1","鼻柊稗匹疋髭彦膝菱肘弼必畢筆逼桧姫媛紐百謬俵彪標氷漂瓢票表評豹廟描病秒苗錨鋲蒜蛭鰭品彬斌浜瀕貧賓頻敏瓶不付埠夫婦富冨布府怖扶敷斧普浮父符腐膚芙譜負賦赴阜附侮撫武舞葡蕪部封楓風葺蕗伏副復幅服"], +["caa1","福腹複覆淵弗払沸仏物鮒分吻噴墳憤扮焚奮粉糞紛雰文聞丙併兵塀幣平弊柄並蔽閉陛米頁僻壁癖碧別瞥蔑箆偏変片篇編辺返遍便勉娩弁鞭保舗鋪圃捕歩甫補輔穂募墓慕戊暮母簿菩倣俸包呆報奉宝峰峯崩庖抱捧放方朋"], +["cba1","法泡烹砲縫胞芳萌蓬蜂褒訪豊邦鋒飽鳳鵬乏亡傍剖坊妨帽忘忙房暴望某棒冒紡肪膨謀貌貿鉾防吠頬北僕卜墨撲朴牧睦穆釦勃没殆堀幌奔本翻凡盆摩磨魔麻埋妹昧枚毎哩槙幕膜枕鮪柾鱒桝亦俣又抹末沫迄侭繭麿万慢満"], +["cca1","漫蔓味未魅巳箕岬密蜜湊蓑稔脈妙粍民眠務夢無牟矛霧鵡椋婿娘冥名命明盟迷銘鳴姪牝滅免棉綿緬面麺摸模茂妄孟毛猛盲網耗蒙儲木黙目杢勿餅尤戻籾貰問悶紋門匁也冶夜爺耶野弥矢厄役約薬訳躍靖柳薮鑓愉愈油癒"], +["cda1","諭輸唯佑優勇友宥幽悠憂揖有柚湧涌猶猷由祐裕誘遊邑郵雄融夕予余与誉輿預傭幼妖容庸揚揺擁曜楊様洋溶熔用窯羊耀葉蓉要謡踊遥陽養慾抑欲沃浴翌翼淀羅螺裸来莱頼雷洛絡落酪乱卵嵐欄濫藍蘭覧利吏履李梨理璃"], +["cea1","痢裏裡里離陸律率立葎掠略劉流溜琉留硫粒隆竜龍侶慮旅虜了亮僚両凌寮料梁涼猟療瞭稜糧良諒遼量陵領力緑倫厘林淋燐琳臨輪隣鱗麟瑠塁涙累類令伶例冷励嶺怜玲礼苓鈴隷零霊麗齢暦歴列劣烈裂廉恋憐漣煉簾練聯"], +["cfa1","蓮連錬呂魯櫓炉賂路露労婁廊弄朗楼榔浪漏牢狼篭老聾蝋郎六麓禄肋録論倭和話歪賄脇惑枠鷲亙亘鰐詫藁蕨椀湾碗腕"], +["d0a1","弌丐丕个丱丶丼丿乂乖乘亂亅豫亊舒弍于亞亟亠亢亰亳亶从仍仄仆仂仗仞仭仟价伉佚估佛佝佗佇佶侈侏侘佻佩佰侑佯來侖儘俔俟俎俘俛俑俚俐俤俥倚倨倔倪倥倅伜俶倡倩倬俾俯們倆偃假會偕偐偈做偖偬偸傀傚傅傴傲"], +["d1a1","僉僊傳僂僖僞僥僭僣僮價僵儉儁儂儖儕儔儚儡儺儷儼儻儿兀兒兌兔兢竸兩兪兮冀冂囘册冉冏冑冓冕冖冤冦冢冩冪冫决冱冲冰况冽凅凉凛几處凩凭凰凵凾刄刋刔刎刧刪刮刳刹剏剄剋剌剞剔剪剴剩剳剿剽劍劔劒剱劈劑辨"], +["d2a1","辧劬劭劼劵勁勍勗勞勣勦飭勠勳勵勸勹匆匈甸匍匐匏匕匚匣匯匱匳匸區卆卅丗卉卍凖卞卩卮夘卻卷厂厖厠厦厥厮厰厶參簒雙叟曼燮叮叨叭叺吁吽呀听吭吼吮吶吩吝呎咏呵咎呟呱呷呰咒呻咀呶咄咐咆哇咢咸咥咬哄哈咨"], +["d3a1","咫哂咤咾咼哘哥哦唏唔哽哮哭哺哢唹啀啣啌售啜啅啖啗唸唳啝喙喀咯喊喟啻啾喘喞單啼喃喩喇喨嗚嗅嗟嗄嗜嗤嗔嘔嗷嘖嗾嗽嘛嗹噎噐營嘴嘶嘲嘸噫噤嘯噬噪嚆嚀嚊嚠嚔嚏嚥嚮嚶嚴囂嚼囁囃囀囈囎囑囓囗囮囹圀囿圄圉"], +["d4a1","圈國圍圓團圖嗇圜圦圷圸坎圻址坏坩埀垈坡坿垉垓垠垳垤垪垰埃埆埔埒埓堊埖埣堋堙堝塲堡塢塋塰毀塒堽塹墅墹墟墫墺壞墻墸墮壅壓壑壗壙壘壥壜壤壟壯壺壹壻壼壽夂夊夐夛梦夥夬夭夲夸夾竒奕奐奎奚奘奢奠奧奬奩"], +["d5a1","奸妁妝佞侫妣妲姆姨姜妍姙姚娥娟娑娜娉娚婀婬婉娵娶婢婪媚媼媾嫋嫂媽嫣嫗嫦嫩嫖嫺嫻嬌嬋嬖嬲嫐嬪嬶嬾孃孅孀孑孕孚孛孥孩孰孳孵學斈孺宀它宦宸寃寇寉寔寐寤實寢寞寥寫寰寶寳尅將專對尓尠尢尨尸尹屁屆屎屓"], +["d6a1","屐屏孱屬屮乢屶屹岌岑岔妛岫岻岶岼岷峅岾峇峙峩峽峺峭嶌峪崋崕崗嵜崟崛崑崔崢崚崙崘嵌嵒嵎嵋嵬嵳嵶嶇嶄嶂嶢嶝嶬嶮嶽嶐嶷嶼巉巍巓巒巖巛巫已巵帋帚帙帑帛帶帷幄幃幀幎幗幔幟幢幤幇幵并幺麼广庠廁廂廈廐廏"], +["d7a1","廖廣廝廚廛廢廡廨廩廬廱廳廰廴廸廾弃弉彝彜弋弑弖弩弭弸彁彈彌彎弯彑彖彗彙彡彭彳彷徃徂彿徊很徑徇從徙徘徠徨徭徼忖忻忤忸忱忝悳忿怡恠怙怐怩怎怱怛怕怫怦怏怺恚恁恪恷恟恊恆恍恣恃恤恂恬恫恙悁悍惧悃悚"], +["d8a1","悄悛悖悗悒悧悋惡悸惠惓悴忰悽惆悵惘慍愕愆惶惷愀惴惺愃愡惻惱愍愎慇愾愨愧慊愿愼愬愴愽慂慄慳慷慘慙慚慫慴慯慥慱慟慝慓慵憙憖憇憬憔憚憊憑憫憮懌懊應懷懈懃懆憺懋罹懍懦懣懶懺懴懿懽懼懾戀戈戉戍戌戔戛"], +["d9a1","戞戡截戮戰戲戳扁扎扞扣扛扠扨扼抂抉找抒抓抖拔抃抔拗拑抻拏拿拆擔拈拜拌拊拂拇抛拉挌拮拱挧挂挈拯拵捐挾捍搜捏掖掎掀掫捶掣掏掉掟掵捫捩掾揩揀揆揣揉插揶揄搖搴搆搓搦搶攝搗搨搏摧摯摶摎攪撕撓撥撩撈撼"], +["daa1","據擒擅擇撻擘擂擱擧舉擠擡抬擣擯攬擶擴擲擺攀擽攘攜攅攤攣攫攴攵攷收攸畋效敖敕敍敘敞敝敲數斂斃變斛斟斫斷旃旆旁旄旌旒旛旙无旡旱杲昊昃旻杳昵昶昴昜晏晄晉晁晞晝晤晧晨晟晢晰暃暈暎暉暄暘暝曁暹曉暾暼"], +["dba1","曄暸曖曚曠昿曦曩曰曵曷朏朖朞朦朧霸朮朿朶杁朸朷杆杞杠杙杣杤枉杰枩杼杪枌枋枦枡枅枷柯枴柬枳柩枸柤柞柝柢柮枹柎柆柧檜栞框栩桀桍栲桎梳栫桙档桷桿梟梏梭梔條梛梃檮梹桴梵梠梺椏梍桾椁棊椈棘椢椦棡椌棍"], +["dca1","棔棧棕椶椒椄棗棣椥棹棠棯椨椪椚椣椡棆楹楷楜楸楫楔楾楮椹楴椽楙椰楡楞楝榁楪榲榮槐榿槁槓榾槎寨槊槝榻槃榧樮榑榠榜榕榴槞槨樂樛槿權槹槲槧樅榱樞槭樔槫樊樒櫁樣樓橄樌橲樶橸橇橢橙橦橈樸樢檐檍檠檄檢檣"], +["dda1","檗蘗檻櫃櫂檸檳檬櫞櫑櫟檪櫚櫪櫻欅蘖櫺欒欖鬱欟欸欷盜欹飮歇歃歉歐歙歔歛歟歡歸歹歿殀殄殃殍殘殕殞殤殪殫殯殲殱殳殷殼毆毋毓毟毬毫毳毯麾氈氓气氛氤氣汞汕汢汪沂沍沚沁沛汾汨汳沒沐泄泱泓沽泗泅泝沮沱沾"], +["dea1","沺泛泯泙泪洟衍洶洫洽洸洙洵洳洒洌浣涓浤浚浹浙涎涕濤涅淹渕渊涵淇淦涸淆淬淞淌淨淒淅淺淙淤淕淪淮渭湮渮渙湲湟渾渣湫渫湶湍渟湃渺湎渤滿渝游溂溪溘滉溷滓溽溯滄溲滔滕溏溥滂溟潁漑灌滬滸滾漿滲漱滯漲滌"], +["dfa1","漾漓滷澆潺潸澁澀潯潛濳潭澂潼潘澎澑濂潦澳澣澡澤澹濆澪濟濕濬濔濘濱濮濛瀉瀋濺瀑瀁瀏濾瀛瀚潴瀝瀘瀟瀰瀾瀲灑灣炙炒炯烱炬炸炳炮烟烋烝烙焉烽焜焙煥煕熈煦煢煌煖煬熏燻熄熕熨熬燗熹熾燒燉燔燎燠燬燧燵燼"], +["e0a1","燹燿爍爐爛爨爭爬爰爲爻爼爿牀牆牋牘牴牾犂犁犇犒犖犢犧犹犲狃狆狄狎狒狢狠狡狹狷倏猗猊猜猖猝猴猯猩猥猾獎獏默獗獪獨獰獸獵獻獺珈玳珎玻珀珥珮珞璢琅瑯琥珸琲琺瑕琿瑟瑙瑁瑜瑩瑰瑣瑪瑶瑾璋璞璧瓊瓏瓔珱"], +["e1a1","瓠瓣瓧瓩瓮瓲瓰瓱瓸瓷甄甃甅甌甎甍甕甓甞甦甬甼畄畍畊畉畛畆畚畩畤畧畫畭畸當疆疇畴疊疉疂疔疚疝疥疣痂疳痃疵疽疸疼疱痍痊痒痙痣痞痾痿痼瘁痰痺痲痳瘋瘍瘉瘟瘧瘠瘡瘢瘤瘴瘰瘻癇癈癆癜癘癡癢癨癩癪癧癬癰"], +["e2a1","癲癶癸發皀皃皈皋皎皖皓皙皚皰皴皸皹皺盂盍盖盒盞盡盥盧盪蘯盻眈眇眄眩眤眞眥眦眛眷眸睇睚睨睫睛睥睿睾睹瞎瞋瞑瞠瞞瞰瞶瞹瞿瞼瞽瞻矇矍矗矚矜矣矮矼砌砒礦砠礪硅碎硴碆硼碚碌碣碵碪碯磑磆磋磔碾碼磅磊磬"], +["e3a1","磧磚磽磴礇礒礑礙礬礫祀祠祗祟祚祕祓祺祿禊禝禧齋禪禮禳禹禺秉秕秧秬秡秣稈稍稘稙稠稟禀稱稻稾稷穃穗穉穡穢穩龝穰穹穽窈窗窕窘窖窩竈窰窶竅竄窿邃竇竊竍竏竕竓站竚竝竡竢竦竭竰笂笏笊笆笳笘笙笞笵笨笶筐"], +["e4a1","筺笄筍笋筌筅筵筥筴筧筰筱筬筮箝箘箟箍箜箚箋箒箏筝箙篋篁篌篏箴篆篝篩簑簔篦篥籠簀簇簓篳篷簗簍篶簣簧簪簟簷簫簽籌籃籔籏籀籐籘籟籤籖籥籬籵粃粐粤粭粢粫粡粨粳粲粱粮粹粽糀糅糂糘糒糜糢鬻糯糲糴糶糺紆"], +["e5a1","紂紜紕紊絅絋紮紲紿紵絆絳絖絎絲絨絮絏絣經綉絛綏絽綛綺綮綣綵緇綽綫總綢綯緜綸綟綰緘緝緤緞緻緲緡縅縊縣縡縒縱縟縉縋縢繆繦縻縵縹繃縷縲縺繧繝繖繞繙繚繹繪繩繼繻纃緕繽辮繿纈纉續纒纐纓纔纖纎纛纜缸缺"], +["e6a1","罅罌罍罎罐网罕罔罘罟罠罨罩罧罸羂羆羃羈羇羌羔羞羝羚羣羯羲羹羮羶羸譱翅翆翊翕翔翡翦翩翳翹飜耆耄耋耒耘耙耜耡耨耿耻聊聆聒聘聚聟聢聨聳聲聰聶聹聽聿肄肆肅肛肓肚肭冐肬胛胥胙胝胄胚胖脉胯胱脛脩脣脯腋"], +["e7a1","隋腆脾腓腑胼腱腮腥腦腴膃膈膊膀膂膠膕膤膣腟膓膩膰膵膾膸膽臀臂膺臉臍臑臙臘臈臚臟臠臧臺臻臾舁舂舅與舊舍舐舖舩舫舸舳艀艙艘艝艚艟艤艢艨艪艫舮艱艷艸艾芍芒芫芟芻芬苡苣苟苒苴苳苺莓范苻苹苞茆苜茉苙"], +["e8a1","茵茴茖茲茱荀茹荐荅茯茫茗茘莅莚莪莟莢莖茣莎莇莊荼莵荳荵莠莉莨菴萓菫菎菽萃菘萋菁菷萇菠菲萍萢萠莽萸蔆菻葭萪萼蕚蒄葷葫蒭葮蒂葩葆萬葯葹萵蓊葢蒹蒿蒟蓙蓍蒻蓚蓐蓁蓆蓖蒡蔡蓿蓴蔗蔘蔬蔟蔕蔔蓼蕀蕣蕘蕈"], +["e9a1","蕁蘂蕋蕕薀薤薈薑薊薨蕭薔薛藪薇薜蕷蕾薐藉薺藏薹藐藕藝藥藜藹蘊蘓蘋藾藺蘆蘢蘚蘰蘿虍乕虔號虧虱蚓蚣蚩蚪蚋蚌蚶蚯蛄蛆蚰蛉蠣蚫蛔蛞蛩蛬蛟蛛蛯蜒蜆蜈蜀蜃蛻蜑蜉蜍蛹蜊蜴蜿蜷蜻蜥蜩蜚蝠蝟蝸蝌蝎蝴蝗蝨蝮蝙"], +["eaa1","蝓蝣蝪蠅螢螟螂螯蟋螽蟀蟐雖螫蟄螳蟇蟆螻蟯蟲蟠蠏蠍蟾蟶蟷蠎蟒蠑蠖蠕蠢蠡蠱蠶蠹蠧蠻衄衂衒衙衞衢衫袁衾袞衵衽袵衲袂袗袒袮袙袢袍袤袰袿袱裃裄裔裘裙裝裹褂裼裴裨裲褄褌褊褓襃褞褥褪褫襁襄褻褶褸襌褝襠襞"], +["eba1","襦襤襭襪襯襴襷襾覃覈覊覓覘覡覩覦覬覯覲覺覽覿觀觚觜觝觧觴觸訃訖訐訌訛訝訥訶詁詛詒詆詈詼詭詬詢誅誂誄誨誡誑誥誦誚誣諄諍諂諚諫諳諧諤諱謔諠諢諷諞諛謌謇謚諡謖謐謗謠謳鞫謦謫謾謨譁譌譏譎證譖譛譚譫"], +["eca1","譟譬譯譴譽讀讌讎讒讓讖讙讚谺豁谿豈豌豎豐豕豢豬豸豺貂貉貅貊貍貎貔豼貘戝貭貪貽貲貳貮貶賈賁賤賣賚賽賺賻贄贅贊贇贏贍贐齎贓賍贔贖赧赭赱赳趁趙跂趾趺跏跚跖跌跛跋跪跫跟跣跼踈踉跿踝踞踐踟蹂踵踰踴蹊"], +["eda1","蹇蹉蹌蹐蹈蹙蹤蹠踪蹣蹕蹶蹲蹼躁躇躅躄躋躊躓躑躔躙躪躡躬躰軆躱躾軅軈軋軛軣軼軻軫軾輊輅輕輒輙輓輜輟輛輌輦輳輻輹轅轂輾轌轉轆轎轗轜轢轣轤辜辟辣辭辯辷迚迥迢迪迯邇迴逅迹迺逑逕逡逍逞逖逋逧逶逵逹迸"], +["eea1","遏遐遑遒逎遉逾遖遘遞遨遯遶隨遲邂遽邁邀邊邉邏邨邯邱邵郢郤扈郛鄂鄒鄙鄲鄰酊酖酘酣酥酩酳酲醋醉醂醢醫醯醪醵醴醺釀釁釉釋釐釖釟釡釛釼釵釶鈞釿鈔鈬鈕鈑鉞鉗鉅鉉鉤鉈銕鈿鉋鉐銜銖銓銛鉚鋏銹銷鋩錏鋺鍄錮"], +["efa1","錙錢錚錣錺錵錻鍜鍠鍼鍮鍖鎰鎬鎭鎔鎹鏖鏗鏨鏥鏘鏃鏝鏐鏈鏤鐚鐔鐓鐃鐇鐐鐶鐫鐵鐡鐺鑁鑒鑄鑛鑠鑢鑞鑪鈩鑰鑵鑷鑽鑚鑼鑾钁鑿閂閇閊閔閖閘閙閠閨閧閭閼閻閹閾闊濶闃闍闌闕闔闖關闡闥闢阡阨阮阯陂陌陏陋陷陜陞"], +["f0a1","陝陟陦陲陬隍隘隕隗險隧隱隲隰隴隶隸隹雎雋雉雍襍雜霍雕雹霄霆霈霓霎霑霏霖霙霤霪霰霹霽霾靄靆靈靂靉靜靠靤靦靨勒靫靱靹鞅靼鞁靺鞆鞋鞏鞐鞜鞨鞦鞣鞳鞴韃韆韈韋韜韭齏韲竟韶韵頏頌頸頤頡頷頽顆顏顋顫顯顰"], +["f1a1","顱顴顳颪颯颱颶飄飃飆飩飫餃餉餒餔餘餡餝餞餤餠餬餮餽餾饂饉饅饐饋饑饒饌饕馗馘馥馭馮馼駟駛駝駘駑駭駮駱駲駻駸騁騏騅駢騙騫騷驅驂驀驃騾驕驍驛驗驟驢驥驤驩驫驪骭骰骼髀髏髑髓體髞髟髢髣髦髯髫髮髴髱髷"], +["f2a1","髻鬆鬘鬚鬟鬢鬣鬥鬧鬨鬩鬪鬮鬯鬲魄魃魏魍魎魑魘魴鮓鮃鮑鮖鮗鮟鮠鮨鮴鯀鯊鮹鯆鯏鯑鯒鯣鯢鯤鯔鯡鰺鯲鯱鯰鰕鰔鰉鰓鰌鰆鰈鰒鰊鰄鰮鰛鰥鰤鰡鰰鱇鰲鱆鰾鱚鱠鱧鱶鱸鳧鳬鳰鴉鴈鳫鴃鴆鴪鴦鶯鴣鴟鵄鴕鴒鵁鴿鴾鵆鵈"], +["f3a1","鵝鵞鵤鵑鵐鵙鵲鶉鶇鶫鵯鵺鶚鶤鶩鶲鷄鷁鶻鶸鶺鷆鷏鷂鷙鷓鷸鷦鷭鷯鷽鸚鸛鸞鹵鹹鹽麁麈麋麌麒麕麑麝麥麩麸麪麭靡黌黎黏黐黔黜點黝黠黥黨黯黴黶黷黹黻黼黽鼇鼈皷鼕鼡鼬鼾齊齒齔齣齟齠齡齦齧齬齪齷齲齶龕龜龠"], +["f4a1","堯槇遙瑤凜熙"], +["f9a1","纊褜鍈銈蓜俉炻昱棈鋹曻彅丨仡仼伀伃伹佖侒侊侚侔俍偀倢俿倞偆偰偂傔僴僘兊兤冝冾凬刕劜劦勀勛匀匇匤卲厓厲叝﨎咜咊咩哿喆坙坥垬埈埇﨏塚增墲夋奓奛奝奣妤妺孖寀甯寘寬尞岦岺峵崧嵓﨑嵂嵭嶸嶹巐弡弴彧德"], +["faa1","忞恝悅悊惞惕愠惲愑愷愰憘戓抦揵摠撝擎敎昀昕昻昉昮昞昤晥晗晙晴晳暙暠暲暿曺朎朗杦枻桒柀栁桄棏﨓楨﨔榘槢樰橫橆橳橾櫢櫤毖氿汜沆汯泚洄涇浯涖涬淏淸淲淼渹湜渧渼溿澈澵濵瀅瀇瀨炅炫焏焄煜煆煇凞燁燾犱"], +["fba1","犾猤猪獷玽珉珖珣珒琇珵琦琪琩琮瑢璉璟甁畯皂皜皞皛皦益睆劯砡硎硤硺礰礼神祥禔福禛竑竧靖竫箞精絈絜綷綠緖繒罇羡羽茁荢荿菇菶葈蒴蕓蕙蕫﨟薰蘒﨡蠇裵訒訷詹誧誾諟諸諶譓譿賰賴贒赶﨣軏﨤逸遧郞都鄕鄧釚"], +["fca1","釗釞釭釮釤釥鈆鈐鈊鈺鉀鈼鉎鉙鉑鈹鉧銧鉷鉸鋧鋗鋙鋐﨧鋕鋠鋓錥錡鋻﨨錞鋿錝錂鍰鍗鎤鏆鏞鏸鐱鑅鑈閒隆﨩隝隯霳霻靃靍靏靑靕顗顥飯飼餧館馞驎髙髜魵魲鮏鮱鮻鰀鵰鵫鶴鸙黑"], +["fcf1","ⅰ",9,"¬¦'""], +["8fa2af","˘ˇ¸˙˝¯˛˚~΄΅"], +["8fa2c2","¡¦¿"], +["8fa2eb","ºª©®™¤№"], +["8fa6e1","ΆΈΉΊΪ"], +["8fa6e7","Ό"], +["8fa6e9","ΎΫ"], +["8fa6ec","Ώ"], +["8fa6f1","άέήίϊΐόςύϋΰώ"], +["8fa7c2","Ђ",10,"ЎЏ"], +["8fa7f2","ђ",10,"ўџ"], +["8fa9a1","ÆĐ"], +["8fa9a4","Ħ"], +["8fa9a6","IJ"], +["8fa9a8","ŁĿ"], +["8fa9ab","ŊØŒ"], +["8fa9af","ŦÞ"], +["8fa9c1","æđðħıijĸłŀʼnŋøœßŧþ"], +["8faaa1","ÁÀÄÂĂǍĀĄÅÃĆĈČÇĊĎÉÈËÊĚĖĒĘ"], +["8faaba","ĜĞĢĠĤÍÌÏÎǏİĪĮĨĴĶĹĽĻŃŇŅÑÓÒÖÔǑŐŌÕŔŘŖŚŜŠŞŤŢÚÙÜÛŬǓŰŪŲŮŨǗǛǙǕŴÝŸŶŹŽŻ"], +["8faba1","áàäâăǎāąåãćĉčçċďéèëêěėēęǵĝğ"], +["8fabbd","ġĥíìïîǐ"], +["8fabc5","īįĩĵķĺľļńňņñóòöôǒőōõŕřŗśŝšşťţúùüûŭǔűūųůũǘǜǚǖŵýÿŷźžż"], +["8fb0a1","丂丄丅丌丒丟丣两丨丫丮丯丰丵乀乁乄乇乑乚乜乣乨乩乴乵乹乿亍亖亗亝亯亹仃仐仚仛仠仡仢仨仯仱仳仵份仾仿伀伂伃伈伋伌伒伕伖众伙伮伱你伳伵伷伹伻伾佀佂佈佉佋佌佒佔佖佘佟佣佪佬佮佱佷佸佹佺佽佾侁侂侄"], +["8fb1a1","侅侉侊侌侎侐侒侓侔侗侙侚侞侟侲侷侹侻侼侽侾俀俁俅俆俈俉俋俌俍俏俒俜俠俢俰俲俼俽俿倀倁倄倇倊倌倎倐倓倗倘倛倜倝倞倢倧倮倰倲倳倵偀偁偂偅偆偊偌偎偑偒偓偗偙偟偠偢偣偦偧偪偭偰偱倻傁傃傄傆傊傎傏傐"], +["8fb2a1","傒傓傔傖傛傜傞",4,"傪傯傰傹傺傽僀僃僄僇僌僎僐僓僔僘僜僝僟僢僤僦僨僩僯僱僶僺僾儃儆儇儈儋儌儍儎僲儐儗儙儛儜儝儞儣儧儨儬儭儯儱儳儴儵儸儹兂兊兏兓兕兗兘兟兤兦兾冃冄冋冎冘冝冡冣冭冸冺冼冾冿凂"], +["8fb3a1","凈减凑凒凓凕凘凞凢凥凮凲凳凴凷刁刂刅划刓刕刖刘刢刨刱刲刵刼剅剉剕剗剘剚剜剟剠剡剦剮剷剸剹劀劂劅劊劌劓劕劖劗劘劚劜劤劥劦劧劯劰劶劷劸劺劻劽勀勄勆勈勌勏勑勔勖勛勜勡勥勨勩勪勬勰勱勴勶勷匀匃匊匋"], +["8fb4a1","匌匑匓匘匛匜匞匟匥匧匨匩匫匬匭匰匲匵匼匽匾卂卌卋卙卛卡卣卥卬卭卲卹卾厃厇厈厎厓厔厙厝厡厤厪厫厯厲厴厵厷厸厺厽叀叅叏叒叓叕叚叝叞叠另叧叵吂吓吚吡吧吨吪启吱吴吵呃呄呇呍呏呞呢呤呦呧呩呫呭呮呴呿"], +["8fb5a1","咁咃咅咈咉咍咑咕咖咜咟咡咦咧咩咪咭咮咱咷咹咺咻咿哆哊响哎哠哪哬哯哶哼哾哿唀唁唅唈唉唌唍唎唕唪唫唲唵唶唻唼唽啁啇啉啊啍啐啑啘啚啛啞啠啡啤啦啿喁喂喆喈喎喏喑喒喓喔喗喣喤喭喲喿嗁嗃嗆嗉嗋嗌嗎嗑嗒"], +["8fb6a1","嗓嗗嗘嗛嗞嗢嗩嗶嗿嘅嘈嘊嘍",5,"嘙嘬嘰嘳嘵嘷嘹嘻嘼嘽嘿噀噁噃噄噆噉噋噍噏噔噞噠噡噢噣噦噩噭噯噱噲噵嚄嚅嚈嚋嚌嚕嚙嚚嚝嚞嚟嚦嚧嚨嚩嚫嚬嚭嚱嚳嚷嚾囅囉囊囋囏囐囌囍囙囜囝囟囡囤",4,"囱囫园"], +["8fb7a1","囶囷圁圂圇圊圌圑圕圚圛圝圠圢圣圤圥圩圪圬圮圯圳圴圽圾圿坅坆坌坍坒坢坥坧坨坫坭",4,"坳坴坵坷坹坺坻坼坾垁垃垌垔垗垙垚垜垝垞垟垡垕垧垨垩垬垸垽埇埈埌埏埕埝埞埤埦埧埩埭埰埵埶埸埽埾埿堃堄堈堉埡"], +["8fb8a1","堌堍堛堞堟堠堦堧堭堲堹堿塉塌塍塏塐塕塟塡塤塧塨塸塼塿墀墁墇墈墉墊墌墍墏墐墔墖墝墠墡墢墦墩墱墲壄墼壂壈壍壎壐壒壔壖壚壝壡壢壩壳夅夆夋夌夒夓夔虁夝夡夣夤夨夯夰夳夵夶夿奃奆奒奓奙奛奝奞奟奡奣奫奭"], +["8fb9a1","奯奲奵奶她奻奼妋妌妎妒妕妗妟妤妧妭妮妯妰妳妷妺妼姁姃姄姈姊姍姒姝姞姟姣姤姧姮姯姱姲姴姷娀娄娌娍娎娒娓娞娣娤娧娨娪娭娰婄婅婇婈婌婐婕婞婣婥婧婭婷婺婻婾媋媐媓媖媙媜媞媟媠媢媧媬媱媲媳媵媸媺媻媿"], +["8fbaa1","嫄嫆嫈嫏嫚嫜嫠嫥嫪嫮嫵嫶嫽嬀嬁嬈嬗嬴嬙嬛嬝嬡嬥嬭嬸孁孋孌孒孖孞孨孮孯孼孽孾孿宁宄宆宊宎宐宑宓宔宖宨宩宬宭宯宱宲宷宺宼寀寁寍寏寖",4,"寠寯寱寴寽尌尗尞尟尣尦尩尫尬尮尰尲尵尶屙屚屜屢屣屧屨屩"], +["8fbba1","屭屰屴屵屺屻屼屽岇岈岊岏岒岝岟岠岢岣岦岪岲岴岵岺峉峋峒峝峗峮峱峲峴崁崆崍崒崫崣崤崦崧崱崴崹崽崿嵂嵃嵆嵈嵕嵑嵙嵊嵟嵠嵡嵢嵤嵪嵭嵰嵹嵺嵾嵿嶁嶃嶈嶊嶒嶓嶔嶕嶙嶛嶟嶠嶧嶫嶰嶴嶸嶹巃巇巋巐巎巘巙巠巤"], +["8fbca1","巩巸巹帀帇帍帒帔帕帘帟帠帮帨帲帵帾幋幐幉幑幖幘幛幜幞幨幪",4,"幰庀庋庎庢庤庥庨庪庬庱庳庽庾庿廆廌廋廎廑廒廔廕廜廞廥廫异弆弇弈弎弙弜弝弡弢弣弤弨弫弬弮弰弴弶弻弽弿彀彄彅彇彍彐彔彘彛彠彣彤彧"], +["8fbda1","彯彲彴彵彸彺彽彾徉徍徏徖徜徝徢徧徫徤徬徯徰徱徸忄忇忈忉忋忐",4,"忞忡忢忨忩忪忬忭忮忯忲忳忶忺忼怇怊怍怓怔怗怘怚怟怤怭怳怵恀恇恈恉恌恑恔恖恗恝恡恧恱恾恿悂悆悈悊悎悑悓悕悘悝悞悢悤悥您悰悱悷"], +["8fbea1","悻悾惂惄惈惉惊惋惎惏惔惕惙惛惝惞惢惥惲惵惸惼惽愂愇愊愌愐",4,"愖愗愙愜愞愢愪愫愰愱愵愶愷愹慁慅慆慉慞慠慬慲慸慻慼慿憀憁憃憄憋憍憒憓憗憘憜憝憟憠憥憨憪憭憸憹憼懀懁懂懎懏懕懜懝懞懟懡懢懧懩懥"], +["8fbfa1","懬懭懯戁戃戄戇戓戕戜戠戢戣戧戩戫戹戽扂扃扄扆扌扐扑扒扔扖扚扜扤扭扯扳扺扽抍抎抏抐抦抨抳抶抷抺抾抿拄拎拕拖拚拪拲拴拼拽挃挄挊挋挍挐挓挖挘挩挪挭挵挶挹挼捁捂捃捄捆捊捋捎捒捓捔捘捛捥捦捬捭捱捴捵"], +["8fc0a1","捸捼捽捿掂掄掇掊掐掔掕掙掚掞掤掦掭掮掯掽揁揅揈揎揑揓揔揕揜揠揥揪揬揲揳揵揸揹搉搊搐搒搔搘搞搠搢搤搥搩搪搯搰搵搽搿摋摏摑摒摓摔摚摛摜摝摟摠摡摣摭摳摴摻摽撅撇撏撐撑撘撙撛撝撟撡撣撦撨撬撳撽撾撿"], +["8fc1a1","擄擉擊擋擌擎擐擑擕擗擤擥擩擪擭擰擵擷擻擿攁攄攈攉攊攏攓攔攖攙攛攞攟攢攦攩攮攱攺攼攽敃敇敉敐敒敔敟敠敧敫敺敽斁斅斊斒斕斘斝斠斣斦斮斲斳斴斿旂旈旉旎旐旔旖旘旟旰旲旴旵旹旾旿昀昄昈昉昍昑昒昕昖昝"], +["8fc2a1","昞昡昢昣昤昦昩昪昫昬昮昰昱昳昹昷晀晅晆晊晌晑晎晗晘晙晛晜晠晡曻晪晫晬晾晳晵晿晷晸晹晻暀晼暋暌暍暐暒暙暚暛暜暟暠暤暭暱暲暵暻暿曀曂曃曈曌曎曏曔曛曟曨曫曬曮曺朅朇朎朓朙朜朠朢朳朾杅杇杈杌杔杕杝"], +["8fc3a1","杦杬杮杴杶杻极构枎枏枑枓枖枘枙枛枰枱枲枵枻枼枽柹柀柂柃柅柈柉柒柗柙柜柡柦柰柲柶柷桒栔栙栝栟栨栧栬栭栯栰栱栳栻栿桄桅桊桌桕桗桘桛桫桮",4,"桵桹桺桻桼梂梄梆梈梖梘梚梜梡梣梥梩梪梮梲梻棅棈棌棏"], +["8fc4a1","棐棑棓棖棙棜棝棥棨棪棫棬棭棰棱棵棶棻棼棽椆椉椊椐椑椓椖椗椱椳椵椸椻楂楅楉楎楗楛楣楤楥楦楨楩楬楰楱楲楺楻楿榀榍榒榖榘榡榥榦榨榫榭榯榷榸榺榼槅槈槑槖槗槢槥槮槯槱槳槵槾樀樁樃樏樑樕樚樝樠樤樨樰樲"], +["8fc5a1","樴樷樻樾樿橅橆橉橊橎橐橑橒橕橖橛橤橧橪橱橳橾檁檃檆檇檉檋檑檛檝檞檟檥檫檯檰檱檴檽檾檿櫆櫉櫈櫌櫐櫔櫕櫖櫜櫝櫤櫧櫬櫰櫱櫲櫼櫽欂欃欆欇欉欏欐欑欗欛欞欤欨欫欬欯欵欶欻欿歆歊歍歒歖歘歝歠歧歫歮歰歵歽"], +["8fc6a1","歾殂殅殗殛殟殠殢殣殨殩殬殭殮殰殸殹殽殾毃毄毉毌毖毚毡毣毦毧毮毱毷毹毿氂氄氅氉氍氎氐氒氙氟氦氧氨氬氮氳氵氶氺氻氿汊汋汍汏汒汔汙汛汜汫汭汯汴汶汸汹汻沅沆沇沉沔沕沗沘沜沟沰沲沴泂泆泍泏泐泑泒泔泖"], +["8fc7a1","泚泜泠泧泩泫泬泮泲泴洄洇洊洎洏洑洓洚洦洧洨汧洮洯洱洹洼洿浗浞浟浡浥浧浯浰浼涂涇涑涒涔涖涗涘涪涬涴涷涹涽涿淄淈淊淎淏淖淛淝淟淠淢淥淩淯淰淴淶淼渀渄渞渢渧渲渶渹渻渼湄湅湈湉湋湏湑湒湓湔湗湜湝湞"], +["8fc8a1","湢湣湨湳湻湽溍溓溙溠溧溭溮溱溳溻溿滀滁滃滇滈滊滍滎滏滫滭滮滹滻滽漄漈漊漌漍漖漘漚漛漦漩漪漯漰漳漶漻漼漭潏潑潒潓潗潙潚潝潞潡潢潨潬潽潾澃澇澈澋澌澍澐澒澓澔澖澚澟澠澥澦澧澨澮澯澰澵澶澼濅濇濈濊"], +["8fc9a1","濚濞濨濩濰濵濹濼濽瀀瀅瀆瀇瀍瀗瀠瀣瀯瀴瀷瀹瀼灃灄灈灉灊灋灔灕灝灞灎灤灥灬灮灵灶灾炁炅炆炔",4,"炛炤炫炰炱炴炷烊烑烓烔烕烖烘烜烤烺焃",4,"焋焌焏焞焠焫焭焯焰焱焸煁煅煆煇煊煋煐煒煗煚煜煞煠"], +["8fcaa1","煨煹熀熅熇熌熒熚熛熠熢熯熰熲熳熺熿燀燁燄燋燌燓燖燙燚燜燸燾爀爇爈爉爓爗爚爝爟爤爫爯爴爸爹牁牂牃牅牎牏牐牓牕牖牚牜牞牠牣牨牫牮牯牱牷牸牻牼牿犄犉犍犎犓犛犨犭犮犱犴犾狁狇狉狌狕狖狘狟狥狳狴狺狻"], +["8fcba1","狾猂猄猅猇猋猍猒猓猘猙猞猢猤猧猨猬猱猲猵猺猻猽獃獍獐獒獖獘獝獞獟獠獦獧獩獫獬獮獯獱獷獹獼玀玁玃玅玆玎玐玓玕玗玘玜玞玟玠玢玥玦玪玫玭玵玷玹玼玽玿珅珆珉珋珌珏珒珓珖珙珝珡珣珦珧珩珴珵珷珹珺珻珽"], +["8fcca1","珿琀琁琄琇琊琑琚琛琤琦琨",9,"琹瑀瑃瑄瑆瑇瑋瑍瑑瑒瑗瑝瑢瑦瑧瑨瑫瑭瑮瑱瑲璀璁璅璆璇璉璏璐璑璒璘璙璚璜璟璠璡璣璦璨璩璪璫璮璯璱璲璵璹璻璿瓈瓉瓌瓐瓓瓘瓚瓛瓞瓟瓤瓨瓪瓫瓯瓴瓺瓻瓼瓿甆"], +["8fcda1","甒甖甗甠甡甤甧甩甪甯甶甹甽甾甿畀畃畇畈畎畐畒畗畞畟畡畯畱畹",5,"疁疅疐疒疓疕疙疜疢疤疴疺疿痀痁痄痆痌痎痏痗痜痟痠痡痤痧痬痮痯痱痹瘀瘂瘃瘄瘇瘈瘊瘌瘏瘒瘓瘕瘖瘙瘛瘜瘝瘞瘣瘥瘦瘩瘭瘲瘳瘵瘸瘹"], +["8fcea1","瘺瘼癊癀癁癃癄癅癉癋癕癙癟癤癥癭癮癯癱癴皁皅皌皍皕皛皜皝皟皠皢",6,"皪皭皽盁盅盉盋盌盎盔盙盠盦盨盬盰盱盶盹盼眀眆眊眎眒眔眕眗眙眚眜眢眨眭眮眯眴眵眶眹眽眾睂睅睆睊睍睎睏睒睖睗睜睞睟睠睢"], +["8fcfa1","睤睧睪睬睰睲睳睴睺睽瞀瞄瞌瞍瞔瞕瞖瞚瞟瞢瞧瞪瞮瞯瞱瞵瞾矃矉矑矒矕矙矞矟矠矤矦矪矬矰矱矴矸矻砅砆砉砍砎砑砝砡砢砣砭砮砰砵砷硃硄硇硈硌硎硒硜硞硠硡硣硤硨硪确硺硾碊碏碔碘碡碝碞碟碤碨碬碭碰碱碲碳"], +["8fd0a1","碻碽碿磇磈磉磌磎磒磓磕磖磤磛磟磠磡磦磪磲磳礀磶磷磺磻磿礆礌礐礚礜礞礟礠礥礧礩礭礱礴礵礻礽礿祄祅祆祊祋祏祑祔祘祛祜祧祩祫祲祹祻祼祾禋禌禑禓禔禕禖禘禛禜禡禨禩禫禯禱禴禸离秂秄秇秈秊秏秔秖秚秝秞"], +["8fd1a1","秠秢秥秪秫秭秱秸秼稂稃稇稉稊稌稑稕稛稞稡稧稫稭稯稰稴稵稸稹稺穄穅穇穈穌穕穖穙穜穝穟穠穥穧穪穭穵穸穾窀窂窅窆窊窋窐窑窔窞窠窣窬窳窵窹窻窼竆竉竌竎竑竛竨竩竫竬竱竴竻竽竾笇笔笟笣笧笩笪笫笭笮笯笰"], +["8fd2a1","笱笴笽笿筀筁筇筎筕筠筤筦筩筪筭筯筲筳筷箄箉箎箐箑箖箛箞箠箥箬箯箰箲箵箶箺箻箼箽篂篅篈篊篔篖篗篙篚篛篨篪篲篴篵篸篹篺篼篾簁簂簃簄簆簉簋簌簎簏簙簛簠簥簦簨簬簱簳簴簶簹簺籆籊籕籑籒籓籙",5], +["8fd3a1","籡籣籧籩籭籮籰籲籹籼籽粆粇粏粔粞粠粦粰粶粷粺粻粼粿糄糇糈糉糍糏糓糔糕糗糙糚糝糦糩糫糵紃紇紈紉紏紑紒紓紖紝紞紣紦紪紭紱紼紽紾絀絁絇絈絍絑絓絗絙絚絜絝絥絧絪絰絸絺絻絿綁綂綃綅綆綈綋綌綍綑綖綗綝"], +["8fd4a1","綞綦綧綪綳綶綷綹緂",4,"緌緍緎緗緙縀緢緥緦緪緫緭緱緵緶緹緺縈縐縑縕縗縜縝縠縧縨縬縭縯縳縶縿繄繅繇繎繐繒繘繟繡繢繥繫繮繯繳繸繾纁纆纇纊纍纑纕纘纚纝纞缼缻缽缾缿罃罄罇罏罒罓罛罜罝罡罣罤罥罦罭"], +["8fd5a1","罱罽罾罿羀羋羍羏羐羑羖羗羜羡羢羦羪羭羴羼羿翀翃翈翎翏翛翟翣翥翨翬翮翯翲翺翽翾翿耇耈耊耍耎耏耑耓耔耖耝耞耟耠耤耦耬耮耰耴耵耷耹耺耼耾聀聄聠聤聦聭聱聵肁肈肎肜肞肦肧肫肸肹胈胍胏胒胔胕胗胘胠胭胮"], +["8fd6a1","胰胲胳胶胹胺胾脃脋脖脗脘脜脞脠脤脧脬脰脵脺脼腅腇腊腌腒腗腠腡腧腨腩腭腯腷膁膐膄膅膆膋膎膖膘膛膞膢膮膲膴膻臋臃臅臊臎臏臕臗臛臝臞臡臤臫臬臰臱臲臵臶臸臹臽臿舀舃舏舓舔舙舚舝舡舢舨舲舴舺艃艄艅艆"], +["8fd7a1","艋艎艏艑艖艜艠艣艧艭艴艻艽艿芀芁芃芄芇芉芊芎芑芔芖芘芚芛芠芡芣芤芧芨芩芪芮芰芲芴芷芺芼芾芿苆苐苕苚苠苢苤苨苪苭苯苶苷苽苾茀茁茇茈茊茋荔茛茝茞茟茡茢茬茭茮茰茳茷茺茼茽荂荃荄荇荍荎荑荕荖荗荰荸"], +["8fd8a1","荽荿莀莂莄莆莍莒莔莕莘莙莛莜莝莦莧莩莬莾莿菀菇菉菏菐菑菔菝荓菨菪菶菸菹菼萁萆萊萏萑萕萙莭萯萹葅葇葈葊葍葏葑葒葖葘葙葚葜葠葤葥葧葪葰葳葴葶葸葼葽蒁蒅蒒蒓蒕蒞蒦蒨蒩蒪蒯蒱蒴蒺蒽蒾蓀蓂蓇蓈蓌蓏蓓"], +["8fd9a1","蓜蓧蓪蓯蓰蓱蓲蓷蔲蓺蓻蓽蔂蔃蔇蔌蔎蔐蔜蔞蔢蔣蔤蔥蔧蔪蔫蔯蔳蔴蔶蔿蕆蕏",4,"蕖蕙蕜",6,"蕤蕫蕯蕹蕺蕻蕽蕿薁薅薆薉薋薌薏薓薘薝薟薠薢薥薧薴薶薷薸薼薽薾薿藂藇藊藋藎薭藘藚藟藠藦藨藭藳藶藼"], +["8fdaa1","藿蘀蘄蘅蘍蘎蘐蘑蘒蘘蘙蘛蘞蘡蘧蘩蘶蘸蘺蘼蘽虀虂虆虒虓虖虗虘虙虝虠",4,"虩虬虯虵虶虷虺蚍蚑蚖蚘蚚蚜蚡蚦蚧蚨蚭蚱蚳蚴蚵蚷蚸蚹蚿蛀蛁蛃蛅蛑蛒蛕蛗蛚蛜蛠蛣蛥蛧蚈蛺蛼蛽蜄蜅蜇蜋蜎蜏蜐蜓蜔蜙蜞蜟蜡蜣"], +["8fdba1","蜨蜮蜯蜱蜲蜹蜺蜼蜽蜾蝀蝃蝅蝍蝘蝝蝡蝤蝥蝯蝱蝲蝻螃",6,"螋螌螐螓螕螗螘螙螞螠螣螧螬螭螮螱螵螾螿蟁蟈蟉蟊蟎蟕蟖蟙蟚蟜蟟蟢蟣蟤蟪蟫蟭蟱蟳蟸蟺蟿蠁蠃蠆蠉蠊蠋蠐蠙蠒蠓蠔蠘蠚蠛蠜蠞蠟蠨蠭蠮蠰蠲蠵"], +["8fdca1","蠺蠼衁衃衅衈衉衊衋衎衑衕衖衘衚衜衟衠衤衩衱衹衻袀袘袚袛袜袟袠袨袪袺袽袾裀裊",4,"裑裒裓裛裞裧裯裰裱裵裷褁褆褍褎褏褕褖褘褙褚褜褠褦褧褨褰褱褲褵褹褺褾襀襂襅襆襉襏襒襗襚襛襜襡襢襣襫襮襰襳襵襺"], +["8fdda1","襻襼襽覉覍覐覔覕覛覜覟覠覥覰覴覵覶覷覼觔",4,"觥觩觫觭觱觳觶觹觽觿訄訅訇訏訑訒訔訕訞訠訢訤訦訫訬訯訵訷訽訾詀詃詅詇詉詍詎詓詖詗詘詜詝詡詥詧詵詶詷詹詺詻詾詿誀誃誆誋誏誐誒誖誗誙誟誧誩誮誯誳"], +["8fdea1","誶誷誻誾諃諆諈諉諊諑諓諔諕諗諝諟諬諰諴諵諶諼諿謅謆謋謑謜謞謟謊謭謰謷謼譂",4,"譈譒譓譔譙譍譞譣譭譶譸譹譼譾讁讄讅讋讍讏讔讕讜讞讟谸谹谽谾豅豇豉豋豏豑豓豔豗豘豛豝豙豣豤豦豨豩豭豳豵豶豻豾貆"], +["8fdfa1","貇貋貐貒貓貙貛貜貤貹貺賅賆賉賋賏賖賕賙賝賡賨賬賯賰賲賵賷賸賾賿贁贃贉贒贗贛赥赩赬赮赿趂趄趈趍趐趑趕趞趟趠趦趫趬趯趲趵趷趹趻跀跅跆跇跈跊跎跑跔跕跗跙跤跥跧跬跰趼跱跲跴跽踁踄踅踆踋踑踔踖踠踡踢"], +["8fe0a1","踣踦踧踱踳踶踷踸踹踽蹀蹁蹋蹍蹎蹏蹔蹛蹜蹝蹞蹡蹢蹩蹬蹭蹯蹰蹱蹹蹺蹻躂躃躉躐躒躕躚躛躝躞躢躧躩躭躮躳躵躺躻軀軁軃軄軇軏軑軔軜軨軮軰軱軷軹軺軭輀輂輇輈輏輐輖輗輘輞輠輡輣輥輧輨輬輭輮輴輵輶輷輺轀轁"], +["8fe1a1","轃轇轏轑",4,"轘轝轞轥辝辠辡辤辥辦辵辶辸达迀迁迆迊迋迍运迒迓迕迠迣迤迨迮迱迵迶迻迾适逄逈逌逘逛逨逩逯逪逬逭逳逴逷逿遃遄遌遛遝遢遦遧遬遰遴遹邅邈邋邌邎邐邕邗邘邙邛邠邡邢邥邰邲邳邴邶邽郌邾郃"], +["8fe2a1","郄郅郇郈郕郗郘郙郜郝郟郥郒郶郫郯郰郴郾郿鄀鄄鄅鄆鄈鄍鄐鄔鄖鄗鄘鄚鄜鄞鄠鄥鄢鄣鄧鄩鄮鄯鄱鄴鄶鄷鄹鄺鄼鄽酃酇酈酏酓酗酙酚酛酡酤酧酭酴酹酺酻醁醃醅醆醊醎醑醓醔醕醘醞醡醦醨醬醭醮醰醱醲醳醶醻醼醽醿"], +["8fe3a1","釂釃釅釓釔釗釙釚釞釤釥釩釪釬",5,"釷釹釻釽鈀鈁鈄鈅鈆鈇鈉鈊鈌鈐鈒鈓鈖鈘鈜鈝鈣鈤鈥鈦鈨鈮鈯鈰鈳鈵鈶鈸鈹鈺鈼鈾鉀鉂鉃鉆鉇鉊鉍鉎鉏鉑鉘鉙鉜鉝鉠鉡鉥鉧鉨鉩鉮鉯鉰鉵",4,"鉻鉼鉽鉿銈銉銊銍銎銒銗"], +["8fe4a1","銙銟銠銤銥銧銨銫銯銲銶銸銺銻銼銽銿",4,"鋅鋆鋇鋈鋋鋌鋍鋎鋐鋓鋕鋗鋘鋙鋜鋝鋟鋠鋡鋣鋥鋧鋨鋬鋮鋰鋹鋻鋿錀錂錈錍錑錔錕錜錝錞錟錡錤錥錧錩錪錳錴錶錷鍇鍈鍉鍐鍑鍒鍕鍗鍘鍚鍞鍤鍥鍧鍩鍪鍭鍯鍰鍱鍳鍴鍶"], +["8fe5a1","鍺鍽鍿鎀鎁鎂鎈鎊鎋鎍鎏鎒鎕鎘鎛鎞鎡鎣鎤鎦鎨鎫鎴鎵鎶鎺鎩鏁鏄鏅鏆鏇鏉",4,"鏓鏙鏜鏞鏟鏢鏦鏧鏹鏷鏸鏺鏻鏽鐁鐂鐄鐈鐉鐍鐎鐏鐕鐖鐗鐟鐮鐯鐱鐲鐳鐴鐻鐿鐽鑃鑅鑈鑊鑌鑕鑙鑜鑟鑡鑣鑨鑫鑭鑮鑯鑱鑲钄钃镸镹"], +["8fe6a1","镾閄閈閌閍閎閝閞閟閡閦閩閫閬閴閶閺閽閿闆闈闉闋闐闑闒闓闙闚闝闞闟闠闤闦阝阞阢阤阥阦阬阱阳阷阸阹阺阼阽陁陒陔陖陗陘陡陮陴陻陼陾陿隁隂隃隄隉隑隖隚隝隟隤隥隦隩隮隯隳隺雊雒嶲雘雚雝雞雟雩雯雱雺霂"], +["8fe7a1","霃霅霉霚霛霝霡霢霣霨霱霳靁靃靊靎靏靕靗靘靚靛靣靧靪靮靳靶靷靸靻靽靿鞀鞉鞕鞖鞗鞙鞚鞞鞟鞢鞬鞮鞱鞲鞵鞶鞸鞹鞺鞼鞾鞿韁韄韅韇韉韊韌韍韎韐韑韔韗韘韙韝韞韠韛韡韤韯韱韴韷韸韺頇頊頙頍頎頔頖頜頞頠頣頦"], +["8fe8a1","頫頮頯頰頲頳頵頥頾顄顇顊顑顒顓顖顗顙顚顢顣顥顦顪顬颫颭颮颰颴颷颸颺颻颿飂飅飈飌飡飣飥飦飧飪飳飶餂餇餈餑餕餖餗餚餛餜餟餢餦餧餫餱",4,"餹餺餻餼饀饁饆饇饈饍饎饔饘饙饛饜饞饟饠馛馝馟馦馰馱馲馵"], +["8fe9a1","馹馺馽馿駃駉駓駔駙駚駜駞駧駪駫駬駰駴駵駹駽駾騂騃騄騋騌騐騑騖騞騠騢騣騤騧騭騮騳騵騶騸驇驁驄驊驋驌驎驑驔驖驝骪骬骮骯骲骴骵骶骹骻骾骿髁髃髆髈髎髐髒髕髖髗髛髜髠髤髥髧髩髬髲髳髵髹髺髽髿",4], +["8feaa1","鬄鬅鬈鬉鬋鬌鬍鬎鬐鬒鬖鬙鬛鬜鬠鬦鬫鬭鬳鬴鬵鬷鬹鬺鬽魈魋魌魕魖魗魛魞魡魣魥魦魨魪",4,"魳魵魷魸魹魿鮀鮄鮅鮆鮇鮉鮊鮋鮍鮏鮐鮔鮚鮝鮞鮦鮧鮩鮬鮰鮱鮲鮷鮸鮻鮼鮾鮿鯁鯇鯈鯎鯐鯗鯘鯝鯟鯥鯧鯪鯫鯯鯳鯷鯸"], +["8feba1","鯹鯺鯽鯿鰀鰂鰋鰏鰑鰖鰘鰙鰚鰜鰞鰢鰣鰦",4,"鰱鰵鰶鰷鰽鱁鱃鱄鱅鱉鱊鱎鱏鱐鱓鱔鱖鱘鱛鱝鱞鱟鱣鱩鱪鱜鱫鱨鱮鱰鱲鱵鱷鱻鳦鳲鳷鳹鴋鴂鴑鴗鴘鴜鴝鴞鴯鴰鴲鴳鴴鴺鴼鵅鴽鵂鵃鵇鵊鵓鵔鵟鵣鵢鵥鵩鵪鵫鵰鵶鵷鵻"], +["8feca1","鵼鵾鶃鶄鶆鶊鶍鶎鶒鶓鶕鶖鶗鶘鶡鶪鶬鶮鶱鶵鶹鶼鶿鷃鷇鷉鷊鷔鷕鷖鷗鷚鷞鷟鷠鷥鷧鷩鷫鷮鷰鷳鷴鷾鸊鸂鸇鸎鸐鸑鸒鸕鸖鸙鸜鸝鹺鹻鹼麀麂麃麄麅麇麎麏麖麘麛麞麤麨麬麮麯麰麳麴麵黆黈黋黕黟黤黧黬黭黮黰黱黲黵"], +["8feda1","黸黿鼂鼃鼉鼏鼐鼑鼒鼔鼖鼗鼙鼚鼛鼟鼢鼦鼪鼫鼯鼱鼲鼴鼷鼹鼺鼼鼽鼿齁齃",4,"齓齕齖齗齘齚齝齞齨齩齭",4,"齳齵齺齽龏龐龑龒龔龖龗龞龡龢龣龥"] +] diff --git a/node_modules/body-parser/node_modules/iconv-lite/encodings/tables/gb18030-ranges.json b/node_modules/body-parser/node_modules/iconv-lite/encodings/tables/gb18030-ranges.json new file mode 100644 index 0000000..85c6934 --- /dev/null +++ b/node_modules/body-parser/node_modules/iconv-lite/encodings/tables/gb18030-ranges.json @@ -0,0 +1 @@ +{"uChars":[128,165,169,178,184,216,226,235,238,244,248,251,253,258,276,284,300,325,329,334,364,463,465,467,469,471,473,475,477,506,594,610,712,716,730,930,938,962,970,1026,1104,1106,8209,8215,8218,8222,8231,8241,8244,8246,8252,8365,8452,8454,8458,8471,8482,8556,8570,8596,8602,8713,8720,8722,8726,8731,8737,8740,8742,8748,8751,8760,8766,8777,8781,8787,8802,8808,8816,8854,8858,8870,8896,8979,9322,9372,9548,9588,9616,9622,9634,9652,9662,9672,9676,9680,9702,9735,9738,9793,9795,11906,11909,11913,11917,11928,11944,11947,11951,11956,11960,11964,11979,12284,12292,12312,12319,12330,12351,12436,12447,12535,12543,12586,12842,12850,12964,13200,13215,13218,13253,13263,13267,13270,13384,13428,13727,13839,13851,14617,14703,14801,14816,14964,15183,15471,15585,16471,16736,17208,17325,17330,17374,17623,17997,18018,18212,18218,18301,18318,18760,18811,18814,18820,18823,18844,18848,18872,19576,19620,19738,19887,40870,59244,59336,59367,59413,59417,59423,59431,59437,59443,59452,59460,59478,59493,63789,63866,63894,63976,63986,64016,64018,64021,64025,64034,64037,64042,65074,65093,65107,65112,65127,65132,65375,65510,65536],"gbChars":[0,36,38,45,50,81,89,95,96,100,103,104,105,109,126,133,148,172,175,179,208,306,307,308,309,310,311,312,313,341,428,443,544,545,558,741,742,749,750,805,819,820,7922,7924,7925,7927,7934,7943,7944,7945,7950,8062,8148,8149,8152,8164,8174,8236,8240,8262,8264,8374,8380,8381,8384,8388,8390,8392,8393,8394,8396,8401,8406,8416,8419,8424,8437,8439,8445,8482,8485,8496,8521,8603,8936,8946,9046,9050,9063,9066,9076,9092,9100,9108,9111,9113,9131,9162,9164,9218,9219,11329,11331,11334,11336,11346,11361,11363,11366,11370,11372,11375,11389,11682,11686,11687,11692,11694,11714,11716,11723,11725,11730,11736,11982,11989,12102,12336,12348,12350,12384,12393,12395,12397,12510,12553,12851,12962,12973,13738,13823,13919,13933,14080,14298,14585,14698,15583,15847,16318,16434,16438,16481,16729,17102,17122,17315,17320,17402,17418,17859,17909,17911,17915,17916,17936,17939,17961,18664,18703,18814,18962,19043,33469,33470,33471,33484,33485,33490,33497,33501,33505,33513,33520,33536,33550,37845,37921,37948,38029,38038,38064,38065,38066,38069,38075,38076,38078,39108,39109,39113,39114,39115,39116,39265,39394,189000]} \ No newline at end of file diff --git a/node_modules/body-parser/node_modules/iconv-lite/encodings/tables/gbk-added.json b/node_modules/body-parser/node_modules/iconv-lite/encodings/tables/gbk-added.json new file mode 100644 index 0000000..8abfa9f --- /dev/null +++ b/node_modules/body-parser/node_modules/iconv-lite/encodings/tables/gbk-added.json @@ -0,0 +1,55 @@ +[ +["a140","",62], +["a180","",32], +["a240","",62], +["a280","",32], +["a2ab","",5], +["a2e3","€"], +["a2ef",""], +["a2fd",""], +["a340","",62], +["a380","",31," "], +["a440","",62], +["a480","",32], +["a4f4","",10], +["a540","",62], +["a580","",32], +["a5f7","",7], +["a640","",62], +["a680","",32], +["a6b9","",7], +["a6d9","",6], +["a6ec",""], +["a6f3",""], +["a6f6","",8], +["a740","",62], +["a780","",32], +["a7c2","",14], +["a7f2","",12], +["a896","",10], +["a8bc",""], +["a8bf","ǹ"], +["a8c1",""], +["a8ea","",20], +["a958",""], +["a95b",""], +["a95d",""], +["a989","〾⿰",11], +["a997","",12], +["a9f0","",14], +["aaa1","",93], +["aba1","",93], +["aca1","",93], +["ada1","",93], +["aea1","",93], +["afa1","",93], +["d7fa","",4], +["f8a1","",93], +["f9a1","",93], +["faa1","",93], +["fba1","",93], +["fca1","",93], +["fda1","",93], +["fe50","⺁⺄㑳㑇⺈⺋㖞㘚㘎⺌⺗㥮㤘㧏㧟㩳㧐㭎㱮㳠⺧⺪䁖䅟⺮䌷⺳⺶⺷䎱䎬⺻䏝䓖䙡䙌"], +["fe80","䜣䜩䝼䞍⻊䥇䥺䥽䦂䦃䦅䦆䦟䦛䦷䦶䲣䲟䲠䲡䱷䲢䴓",6,"䶮",93] +] diff --git a/node_modules/body-parser/node_modules/iconv-lite/encodings/tables/shiftjis.json b/node_modules/body-parser/node_modules/iconv-lite/encodings/tables/shiftjis.json new file mode 100644 index 0000000..5a3a43c --- /dev/null +++ b/node_modules/body-parser/node_modules/iconv-lite/encodings/tables/shiftjis.json @@ -0,0 +1,125 @@ +[ +["0","\u0000",128], +["a1","。",62], +["8140"," 、。,.・:;?!゛゜´`¨^ ̄_ヽヾゝゞ〃仝々〆〇ー―‐/\~∥|…‥‘’“”()〔〕[]{}〈",9,"+-±×"], +["8180","÷=≠<>≦≧∞∴♂♀°′″℃¥$¢£%#&*@§☆★○●◎◇◆□■△▲▽▼※〒→←↑↓〓"], +["81b8","∈∋⊆⊇⊂⊃∪∩"], +["81c8","∧∨¬⇒⇔∀∃"], +["81da","∠⊥⌒∂∇≡≒≪≫√∽∝∵∫∬"], +["81f0","ʼn♯♭♪†‡¶"], +["81fc","◯"], +["824f","0",9], +["8260","A",25], +["8281","a",25], +["829f","ぁ",82], +["8340","ァ",62], +["8380","ム",22], +["839f","Α",16,"Σ",6], +["83bf","α",16,"σ",6], +["8440","А",5,"ЁЖ",25], +["8470","а",5,"ёж",7], +["8480","о",17], +["849f","─│┌┐┘└├┬┤┴┼━┃┏┓┛┗┣┳┫┻╋┠┯┨┷┿┝┰┥┸╂"], +["8740","①",19,"Ⅰ",9], +["875f","㍉㌔㌢㍍㌘㌧㌃㌶㍑㍗㌍㌦㌣㌫㍊㌻㎜㎝㎞㎎㎏㏄㎡"], +["877e","㍻"], +["8780","〝〟№㏍℡㊤",4,"㈱㈲㈹㍾㍽㍼≒≡∫∮∑√⊥∠∟⊿∵∩∪"], +["889f","亜唖娃阿哀愛挨姶逢葵茜穐悪握渥旭葦芦鯵梓圧斡扱宛姐虻飴絢綾鮎或粟袷安庵按暗案闇鞍杏以伊位依偉囲夷委威尉惟意慰易椅為畏異移維緯胃萎衣謂違遺医井亥域育郁磯一壱溢逸稲茨芋鰯允印咽員因姻引飲淫胤蔭"], +["8940","院陰隠韻吋右宇烏羽迂雨卯鵜窺丑碓臼渦嘘唄欝蔚鰻姥厩浦瓜閏噂云運雲荏餌叡営嬰影映曳栄永泳洩瑛盈穎頴英衛詠鋭液疫益駅悦謁越閲榎厭円"], +["8980","園堰奄宴延怨掩援沿演炎焔煙燕猿縁艶苑薗遠鉛鴛塩於汚甥凹央奥往応押旺横欧殴王翁襖鴬鴎黄岡沖荻億屋憶臆桶牡乙俺卸恩温穏音下化仮何伽価佳加可嘉夏嫁家寡科暇果架歌河火珂禍禾稼箇花苛茄荷華菓蝦課嘩貨迦過霞蚊俄峨我牙画臥芽蛾賀雅餓駕介会解回塊壊廻快怪悔恢懐戒拐改"], +["8a40","魁晦械海灰界皆絵芥蟹開階貝凱劾外咳害崖慨概涯碍蓋街該鎧骸浬馨蛙垣柿蛎鈎劃嚇各廓拡撹格核殻獲確穫覚角赫較郭閣隔革学岳楽額顎掛笠樫"], +["8a80","橿梶鰍潟割喝恰括活渇滑葛褐轄且鰹叶椛樺鞄株兜竃蒲釜鎌噛鴨栢茅萱粥刈苅瓦乾侃冠寒刊勘勧巻喚堪姦完官寛干幹患感慣憾換敢柑桓棺款歓汗漢澗潅環甘監看竿管簡緩缶翰肝艦莞観諌貫還鑑間閑関陥韓館舘丸含岸巌玩癌眼岩翫贋雁頑顔願企伎危喜器基奇嬉寄岐希幾忌揮机旗既期棋棄"], +["8b40","機帰毅気汽畿祈季稀紀徽規記貴起軌輝飢騎鬼亀偽儀妓宜戯技擬欺犠疑祇義蟻誼議掬菊鞠吉吃喫桔橘詰砧杵黍却客脚虐逆丘久仇休及吸宮弓急救"], +["8b80","朽求汲泣灸球究窮笈級糾給旧牛去居巨拒拠挙渠虚許距鋸漁禦魚亨享京供侠僑兇競共凶協匡卿叫喬境峡強彊怯恐恭挟教橋況狂狭矯胸脅興蕎郷鏡響饗驚仰凝尭暁業局曲極玉桐粁僅勤均巾錦斤欣欽琴禁禽筋緊芹菌衿襟謹近金吟銀九倶句区狗玖矩苦躯駆駈駒具愚虞喰空偶寓遇隅串櫛釧屑屈"], +["8c40","掘窟沓靴轡窪熊隈粂栗繰桑鍬勲君薫訓群軍郡卦袈祁係傾刑兄啓圭珪型契形径恵慶慧憩掲携敬景桂渓畦稽系経継繋罫茎荊蛍計詣警軽頚鶏芸迎鯨"], +["8c80","劇戟撃激隙桁傑欠決潔穴結血訣月件倹倦健兼券剣喧圏堅嫌建憲懸拳捲検権牽犬献研硯絹県肩見謙賢軒遣鍵険顕験鹸元原厳幻弦減源玄現絃舷言諺限乎個古呼固姑孤己庫弧戸故枯湖狐糊袴股胡菰虎誇跨鈷雇顧鼓五互伍午呉吾娯後御悟梧檎瑚碁語誤護醐乞鯉交佼侯候倖光公功効勾厚口向"], +["8d40","后喉坑垢好孔孝宏工巧巷幸広庚康弘恒慌抗拘控攻昂晃更杭校梗構江洪浩港溝甲皇硬稿糠紅紘絞綱耕考肯肱腔膏航荒行衡講貢購郊酵鉱砿鋼閤降"], +["8d80","項香高鴻剛劫号合壕拷濠豪轟麹克刻告国穀酷鵠黒獄漉腰甑忽惚骨狛込此頃今困坤墾婚恨懇昏昆根梱混痕紺艮魂些佐叉唆嵯左差査沙瑳砂詐鎖裟坐座挫債催再最哉塞妻宰彩才採栽歳済災采犀砕砦祭斎細菜裁載際剤在材罪財冴坂阪堺榊肴咲崎埼碕鷺作削咋搾昨朔柵窄策索錯桜鮭笹匙冊刷"], +["8e40","察拶撮擦札殺薩雑皐鯖捌錆鮫皿晒三傘参山惨撒散桟燦珊産算纂蚕讃賛酸餐斬暫残仕仔伺使刺司史嗣四士始姉姿子屍市師志思指支孜斯施旨枝止"], +["8e80","死氏獅祉私糸紙紫肢脂至視詞詩試誌諮資賜雌飼歯事似侍児字寺慈持時次滋治爾璽痔磁示而耳自蒔辞汐鹿式識鴫竺軸宍雫七叱執失嫉室悉湿漆疾質実蔀篠偲柴芝屡蕊縞舎写射捨赦斜煮社紗者謝車遮蛇邪借勺尺杓灼爵酌釈錫若寂弱惹主取守手朱殊狩珠種腫趣酒首儒受呪寿授樹綬需囚収周"], +["8f40","宗就州修愁拾洲秀秋終繍習臭舟蒐衆襲讐蹴輯週酋酬集醜什住充十従戎柔汁渋獣縦重銃叔夙宿淑祝縮粛塾熟出術述俊峻春瞬竣舜駿准循旬楯殉淳"], +["8f80","準潤盾純巡遵醇順処初所暑曙渚庶緒署書薯藷諸助叙女序徐恕鋤除傷償勝匠升召哨商唱嘗奨妾娼宵将小少尚庄床廠彰承抄招掌捷昇昌昭晶松梢樟樵沼消渉湘焼焦照症省硝礁祥称章笑粧紹肖菖蒋蕉衝裳訟証詔詳象賞醤鉦鍾鐘障鞘上丈丞乗冗剰城場壌嬢常情擾条杖浄状畳穣蒸譲醸錠嘱埴飾"], +["9040","拭植殖燭織職色触食蝕辱尻伸信侵唇娠寝審心慎振新晋森榛浸深申疹真神秦紳臣芯薪親診身辛進針震人仁刃塵壬尋甚尽腎訊迅陣靭笥諏須酢図厨"], +["9080","逗吹垂帥推水炊睡粋翠衰遂酔錐錘随瑞髄崇嵩数枢趨雛据杉椙菅頗雀裾澄摺寸世瀬畝是凄制勢姓征性成政整星晴棲栖正清牲生盛精聖声製西誠誓請逝醒青静斉税脆隻席惜戚斥昔析石積籍績脊責赤跡蹟碩切拙接摂折設窃節説雪絶舌蝉仙先千占宣専尖川戦扇撰栓栴泉浅洗染潜煎煽旋穿箭線"], +["9140","繊羨腺舛船薦詮賎践選遷銭銑閃鮮前善漸然全禅繕膳糎噌塑岨措曾曽楚狙疏疎礎祖租粗素組蘇訴阻遡鼠僧創双叢倉喪壮奏爽宋層匝惣想捜掃挿掻"], +["9180","操早曹巣槍槽漕燥争痩相窓糟総綜聡草荘葬蒼藻装走送遭鎗霜騒像増憎臓蔵贈造促側則即息捉束測足速俗属賊族続卒袖其揃存孫尊損村遜他多太汰詑唾堕妥惰打柁舵楕陀駄騨体堆対耐岱帯待怠態戴替泰滞胎腿苔袋貸退逮隊黛鯛代台大第醍題鷹滝瀧卓啄宅托択拓沢濯琢託鐸濁諾茸凧蛸只"], +["9240","叩但達辰奪脱巽竪辿棚谷狸鱈樽誰丹単嘆坦担探旦歎淡湛炭短端箪綻耽胆蛋誕鍛団壇弾断暖檀段男談値知地弛恥智池痴稚置致蜘遅馳築畜竹筑蓄"], +["9280","逐秩窒茶嫡着中仲宙忠抽昼柱注虫衷註酎鋳駐樗瀦猪苧著貯丁兆凋喋寵帖帳庁弔張彫徴懲挑暢朝潮牒町眺聴脹腸蝶調諜超跳銚長頂鳥勅捗直朕沈珍賃鎮陳津墜椎槌追鎚痛通塚栂掴槻佃漬柘辻蔦綴鍔椿潰坪壷嬬紬爪吊釣鶴亭低停偵剃貞呈堤定帝底庭廷弟悌抵挺提梯汀碇禎程締艇訂諦蹄逓"], +["9340","邸鄭釘鼎泥摘擢敵滴的笛適鏑溺哲徹撤轍迭鉄典填天展店添纏甜貼転顛点伝殿澱田電兎吐堵塗妬屠徒斗杜渡登菟賭途都鍍砥砺努度土奴怒倒党冬"], +["9380","凍刀唐塔塘套宕島嶋悼投搭東桃梼棟盗淘湯涛灯燈当痘祷等答筒糖統到董蕩藤討謄豆踏逃透鐙陶頭騰闘働動同堂導憧撞洞瞳童胴萄道銅峠鴇匿得徳涜特督禿篤毒独読栃橡凸突椴届鳶苫寅酉瀞噸屯惇敦沌豚遁頓呑曇鈍奈那内乍凪薙謎灘捺鍋楢馴縄畷南楠軟難汝二尼弐迩匂賑肉虹廿日乳入"], +["9440","如尿韮任妊忍認濡禰祢寧葱猫熱年念捻撚燃粘乃廼之埜嚢悩濃納能脳膿農覗蚤巴把播覇杷波派琶破婆罵芭馬俳廃拝排敗杯盃牌背肺輩配倍培媒梅"], +["9480","楳煤狽買売賠陪這蝿秤矧萩伯剥博拍柏泊白箔粕舶薄迫曝漠爆縛莫駁麦函箱硲箸肇筈櫨幡肌畑畠八鉢溌発醗髪伐罰抜筏閥鳩噺塙蛤隼伴判半反叛帆搬斑板氾汎版犯班畔繁般藩販範釆煩頒飯挽晩番盤磐蕃蛮匪卑否妃庇彼悲扉批披斐比泌疲皮碑秘緋罷肥被誹費避非飛樋簸備尾微枇毘琵眉美"], +["9540","鼻柊稗匹疋髭彦膝菱肘弼必畢筆逼桧姫媛紐百謬俵彪標氷漂瓢票表評豹廟描病秒苗錨鋲蒜蛭鰭品彬斌浜瀕貧賓頻敏瓶不付埠夫婦富冨布府怖扶敷"], +["9580","斧普浮父符腐膚芙譜負賦赴阜附侮撫武舞葡蕪部封楓風葺蕗伏副復幅服福腹複覆淵弗払沸仏物鮒分吻噴墳憤扮焚奮粉糞紛雰文聞丙併兵塀幣平弊柄並蔽閉陛米頁僻壁癖碧別瞥蔑箆偏変片篇編辺返遍便勉娩弁鞭保舗鋪圃捕歩甫補輔穂募墓慕戊暮母簿菩倣俸包呆報奉宝峰峯崩庖抱捧放方朋"], +["9640","法泡烹砲縫胞芳萌蓬蜂褒訪豊邦鋒飽鳳鵬乏亡傍剖坊妨帽忘忙房暴望某棒冒紡肪膨謀貌貿鉾防吠頬北僕卜墨撲朴牧睦穆釦勃没殆堀幌奔本翻凡盆"], +["9680","摩磨魔麻埋妹昧枚毎哩槙幕膜枕鮪柾鱒桝亦俣又抹末沫迄侭繭麿万慢満漫蔓味未魅巳箕岬密蜜湊蓑稔脈妙粍民眠務夢無牟矛霧鵡椋婿娘冥名命明盟迷銘鳴姪牝滅免棉綿緬面麺摸模茂妄孟毛猛盲網耗蒙儲木黙目杢勿餅尤戻籾貰問悶紋門匁也冶夜爺耶野弥矢厄役約薬訳躍靖柳薮鑓愉愈油癒"], +["9740","諭輸唯佑優勇友宥幽悠憂揖有柚湧涌猶猷由祐裕誘遊邑郵雄融夕予余与誉輿預傭幼妖容庸揚揺擁曜楊様洋溶熔用窯羊耀葉蓉要謡踊遥陽養慾抑欲"], +["9780","沃浴翌翼淀羅螺裸来莱頼雷洛絡落酪乱卵嵐欄濫藍蘭覧利吏履李梨理璃痢裏裡里離陸律率立葎掠略劉流溜琉留硫粒隆竜龍侶慮旅虜了亮僚両凌寮料梁涼猟療瞭稜糧良諒遼量陵領力緑倫厘林淋燐琳臨輪隣鱗麟瑠塁涙累類令伶例冷励嶺怜玲礼苓鈴隷零霊麗齢暦歴列劣烈裂廉恋憐漣煉簾練聯"], +["9840","蓮連錬呂魯櫓炉賂路露労婁廊弄朗楼榔浪漏牢狼篭老聾蝋郎六麓禄肋録論倭和話歪賄脇惑枠鷲亙亘鰐詫藁蕨椀湾碗腕"], +["989f","弌丐丕个丱丶丼丿乂乖乘亂亅豫亊舒弍于亞亟亠亢亰亳亶从仍仄仆仂仗仞仭仟价伉佚估佛佝佗佇佶侈侏侘佻佩佰侑佯來侖儘俔俟俎俘俛俑俚俐俤俥倚倨倔倪倥倅伜俶倡倩倬俾俯們倆偃假會偕偐偈做偖偬偸傀傚傅傴傲"], +["9940","僉僊傳僂僖僞僥僭僣僮價僵儉儁儂儖儕儔儚儡儺儷儼儻儿兀兒兌兔兢竸兩兪兮冀冂囘册冉冏冑冓冕冖冤冦冢冩冪冫决冱冲冰况冽凅凉凛几處凩凭"], +["9980","凰凵凾刄刋刔刎刧刪刮刳刹剏剄剋剌剞剔剪剴剩剳剿剽劍劔劒剱劈劑辨辧劬劭劼劵勁勍勗勞勣勦飭勠勳勵勸勹匆匈甸匍匐匏匕匚匣匯匱匳匸區卆卅丗卉卍凖卞卩卮夘卻卷厂厖厠厦厥厮厰厶參簒雙叟曼燮叮叨叭叺吁吽呀听吭吼吮吶吩吝呎咏呵咎呟呱呷呰咒呻咀呶咄咐咆哇咢咸咥咬哄哈咨"], +["9a40","咫哂咤咾咼哘哥哦唏唔哽哮哭哺哢唹啀啣啌售啜啅啖啗唸唳啝喙喀咯喊喟啻啾喘喞單啼喃喩喇喨嗚嗅嗟嗄嗜嗤嗔嘔嗷嘖嗾嗽嘛嗹噎噐營嘴嘶嘲嘸"], +["9a80","噫噤嘯噬噪嚆嚀嚊嚠嚔嚏嚥嚮嚶嚴囂嚼囁囃囀囈囎囑囓囗囮囹圀囿圄圉圈國圍圓團圖嗇圜圦圷圸坎圻址坏坩埀垈坡坿垉垓垠垳垤垪垰埃埆埔埒埓堊埖埣堋堙堝塲堡塢塋塰毀塒堽塹墅墹墟墫墺壞墻墸墮壅壓壑壗壙壘壥壜壤壟壯壺壹壻壼壽夂夊夐夛梦夥夬夭夲夸夾竒奕奐奎奚奘奢奠奧奬奩"], +["9b40","奸妁妝佞侫妣妲姆姨姜妍姙姚娥娟娑娜娉娚婀婬婉娵娶婢婪媚媼媾嫋嫂媽嫣嫗嫦嫩嫖嫺嫻嬌嬋嬖嬲嫐嬪嬶嬾孃孅孀孑孕孚孛孥孩孰孳孵學斈孺宀"], +["9b80","它宦宸寃寇寉寔寐寤實寢寞寥寫寰寶寳尅將專對尓尠尢尨尸尹屁屆屎屓屐屏孱屬屮乢屶屹岌岑岔妛岫岻岶岼岷峅岾峇峙峩峽峺峭嶌峪崋崕崗嵜崟崛崑崔崢崚崙崘嵌嵒嵎嵋嵬嵳嵶嶇嶄嶂嶢嶝嶬嶮嶽嶐嶷嶼巉巍巓巒巖巛巫已巵帋帚帙帑帛帶帷幄幃幀幎幗幔幟幢幤幇幵并幺麼广庠廁廂廈廐廏"], +["9c40","廖廣廝廚廛廢廡廨廩廬廱廳廰廴廸廾弃弉彝彜弋弑弖弩弭弸彁彈彌彎弯彑彖彗彙彡彭彳彷徃徂彿徊很徑徇從徙徘徠徨徭徼忖忻忤忸忱忝悳忿怡恠"], +["9c80","怙怐怩怎怱怛怕怫怦怏怺恚恁恪恷恟恊恆恍恣恃恤恂恬恫恙悁悍惧悃悚悄悛悖悗悒悧悋惡悸惠惓悴忰悽惆悵惘慍愕愆惶惷愀惴惺愃愡惻惱愍愎慇愾愨愧慊愿愼愬愴愽慂慄慳慷慘慙慚慫慴慯慥慱慟慝慓慵憙憖憇憬憔憚憊憑憫憮懌懊應懷懈懃懆憺懋罹懍懦懣懶懺懴懿懽懼懾戀戈戉戍戌戔戛"], +["9d40","戞戡截戮戰戲戳扁扎扞扣扛扠扨扼抂抉找抒抓抖拔抃抔拗拑抻拏拿拆擔拈拜拌拊拂拇抛拉挌拮拱挧挂挈拯拵捐挾捍搜捏掖掎掀掫捶掣掏掉掟掵捫"], +["9d80","捩掾揩揀揆揣揉插揶揄搖搴搆搓搦搶攝搗搨搏摧摯摶摎攪撕撓撥撩撈撼據擒擅擇撻擘擂擱擧舉擠擡抬擣擯攬擶擴擲擺攀擽攘攜攅攤攣攫攴攵攷收攸畋效敖敕敍敘敞敝敲數斂斃變斛斟斫斷旃旆旁旄旌旒旛旙无旡旱杲昊昃旻杳昵昶昴昜晏晄晉晁晞晝晤晧晨晟晢晰暃暈暎暉暄暘暝曁暹曉暾暼"], +["9e40","曄暸曖曚曠昿曦曩曰曵曷朏朖朞朦朧霸朮朿朶杁朸朷杆杞杠杙杣杤枉杰枩杼杪枌枋枦枡枅枷柯枴柬枳柩枸柤柞柝柢柮枹柎柆柧檜栞框栩桀桍栲桎"], +["9e80","梳栫桙档桷桿梟梏梭梔條梛梃檮梹桴梵梠梺椏梍桾椁棊椈棘椢椦棡椌棍棔棧棕椶椒椄棗棣椥棹棠棯椨椪椚椣椡棆楹楷楜楸楫楔楾楮椹楴椽楙椰楡楞楝榁楪榲榮槐榿槁槓榾槎寨槊槝榻槃榧樮榑榠榜榕榴槞槨樂樛槿權槹槲槧樅榱樞槭樔槫樊樒櫁樣樓橄樌橲樶橸橇橢橙橦橈樸樢檐檍檠檄檢檣"], +["9f40","檗蘗檻櫃櫂檸檳檬櫞櫑櫟檪櫚櫪櫻欅蘖櫺欒欖鬱欟欸欷盜欹飮歇歃歉歐歙歔歛歟歡歸歹歿殀殄殃殍殘殕殞殤殪殫殯殲殱殳殷殼毆毋毓毟毬毫毳毯"], +["9f80","麾氈氓气氛氤氣汞汕汢汪沂沍沚沁沛汾汨汳沒沐泄泱泓沽泗泅泝沮沱沾沺泛泯泙泪洟衍洶洫洽洸洙洵洳洒洌浣涓浤浚浹浙涎涕濤涅淹渕渊涵淇淦涸淆淬淞淌淨淒淅淺淙淤淕淪淮渭湮渮渙湲湟渾渣湫渫湶湍渟湃渺湎渤滿渝游溂溪溘滉溷滓溽溯滄溲滔滕溏溥滂溟潁漑灌滬滸滾漿滲漱滯漲滌"], +["e040","漾漓滷澆潺潸澁澀潯潛濳潭澂潼潘澎澑濂潦澳澣澡澤澹濆澪濟濕濬濔濘濱濮濛瀉瀋濺瀑瀁瀏濾瀛瀚潴瀝瀘瀟瀰瀾瀲灑灣炙炒炯烱炬炸炳炮烟烋烝"], +["e080","烙焉烽焜焙煥煕熈煦煢煌煖煬熏燻熄熕熨熬燗熹熾燒燉燔燎燠燬燧燵燼燹燿爍爐爛爨爭爬爰爲爻爼爿牀牆牋牘牴牾犂犁犇犒犖犢犧犹犲狃狆狄狎狒狢狠狡狹狷倏猗猊猜猖猝猴猯猩猥猾獎獏默獗獪獨獰獸獵獻獺珈玳珎玻珀珥珮珞璢琅瑯琥珸琲琺瑕琿瑟瑙瑁瑜瑩瑰瑣瑪瑶瑾璋璞璧瓊瓏瓔珱"], +["e140","瓠瓣瓧瓩瓮瓲瓰瓱瓸瓷甄甃甅甌甎甍甕甓甞甦甬甼畄畍畊畉畛畆畚畩畤畧畫畭畸當疆疇畴疊疉疂疔疚疝疥疣痂疳痃疵疽疸疼疱痍痊痒痙痣痞痾痿"], +["e180","痼瘁痰痺痲痳瘋瘍瘉瘟瘧瘠瘡瘢瘤瘴瘰瘻癇癈癆癜癘癡癢癨癩癪癧癬癰癲癶癸發皀皃皈皋皎皖皓皙皚皰皴皸皹皺盂盍盖盒盞盡盥盧盪蘯盻眈眇眄眩眤眞眥眦眛眷眸睇睚睨睫睛睥睿睾睹瞎瞋瞑瞠瞞瞰瞶瞹瞿瞼瞽瞻矇矍矗矚矜矣矮矼砌砒礦砠礪硅碎硴碆硼碚碌碣碵碪碯磑磆磋磔碾碼磅磊磬"], +["e240","磧磚磽磴礇礒礑礙礬礫祀祠祗祟祚祕祓祺祿禊禝禧齋禪禮禳禹禺秉秕秧秬秡秣稈稍稘稙稠稟禀稱稻稾稷穃穗穉穡穢穩龝穰穹穽窈窗窕窘窖窩竈窰"], +["e280","窶竅竄窿邃竇竊竍竏竕竓站竚竝竡竢竦竭竰笂笏笊笆笳笘笙笞笵笨笶筐筺笄筍笋筌筅筵筥筴筧筰筱筬筮箝箘箟箍箜箚箋箒箏筝箙篋篁篌篏箴篆篝篩簑簔篦篥籠簀簇簓篳篷簗簍篶簣簧簪簟簷簫簽籌籃籔籏籀籐籘籟籤籖籥籬籵粃粐粤粭粢粫粡粨粳粲粱粮粹粽糀糅糂糘糒糜糢鬻糯糲糴糶糺紆"], +["e340","紂紜紕紊絅絋紮紲紿紵絆絳絖絎絲絨絮絏絣經綉絛綏絽綛綺綮綣綵緇綽綫總綢綯緜綸綟綰緘緝緤緞緻緲緡縅縊縣縡縒縱縟縉縋縢繆繦縻縵縹繃縷"], +["e380","縲縺繧繝繖繞繙繚繹繪繩繼繻纃緕繽辮繿纈纉續纒纐纓纔纖纎纛纜缸缺罅罌罍罎罐网罕罔罘罟罠罨罩罧罸羂羆羃羈羇羌羔羞羝羚羣羯羲羹羮羶羸譱翅翆翊翕翔翡翦翩翳翹飜耆耄耋耒耘耙耜耡耨耿耻聊聆聒聘聚聟聢聨聳聲聰聶聹聽聿肄肆肅肛肓肚肭冐肬胛胥胙胝胄胚胖脉胯胱脛脩脣脯腋"], +["e440","隋腆脾腓腑胼腱腮腥腦腴膃膈膊膀膂膠膕膤膣腟膓膩膰膵膾膸膽臀臂膺臉臍臑臙臘臈臚臟臠臧臺臻臾舁舂舅與舊舍舐舖舩舫舸舳艀艙艘艝艚艟艤"], +["e480","艢艨艪艫舮艱艷艸艾芍芒芫芟芻芬苡苣苟苒苴苳苺莓范苻苹苞茆苜茉苙茵茴茖茲茱荀茹荐荅茯茫茗茘莅莚莪莟莢莖茣莎莇莊荼莵荳荵莠莉莨菴萓菫菎菽萃菘萋菁菷萇菠菲萍萢萠莽萸蔆菻葭萪萼蕚蒄葷葫蒭葮蒂葩葆萬葯葹萵蓊葢蒹蒿蒟蓙蓍蒻蓚蓐蓁蓆蓖蒡蔡蓿蓴蔗蔘蔬蔟蔕蔔蓼蕀蕣蕘蕈"], +["e540","蕁蘂蕋蕕薀薤薈薑薊薨蕭薔薛藪薇薜蕷蕾薐藉薺藏薹藐藕藝藥藜藹蘊蘓蘋藾藺蘆蘢蘚蘰蘿虍乕虔號虧虱蚓蚣蚩蚪蚋蚌蚶蚯蛄蛆蚰蛉蠣蚫蛔蛞蛩蛬"], +["e580","蛟蛛蛯蜒蜆蜈蜀蜃蛻蜑蜉蜍蛹蜊蜴蜿蜷蜻蜥蜩蜚蝠蝟蝸蝌蝎蝴蝗蝨蝮蝙蝓蝣蝪蠅螢螟螂螯蟋螽蟀蟐雖螫蟄螳蟇蟆螻蟯蟲蟠蠏蠍蟾蟶蟷蠎蟒蠑蠖蠕蠢蠡蠱蠶蠹蠧蠻衄衂衒衙衞衢衫袁衾袞衵衽袵衲袂袗袒袮袙袢袍袤袰袿袱裃裄裔裘裙裝裹褂裼裴裨裲褄褌褊褓襃褞褥褪褫襁襄褻褶褸襌褝襠襞"], +["e640","襦襤襭襪襯襴襷襾覃覈覊覓覘覡覩覦覬覯覲覺覽覿觀觚觜觝觧觴觸訃訖訐訌訛訝訥訶詁詛詒詆詈詼詭詬詢誅誂誄誨誡誑誥誦誚誣諄諍諂諚諫諳諧"], +["e680","諤諱謔諠諢諷諞諛謌謇謚諡謖謐謗謠謳鞫謦謫謾謨譁譌譏譎證譖譛譚譫譟譬譯譴譽讀讌讎讒讓讖讙讚谺豁谿豈豌豎豐豕豢豬豸豺貂貉貅貊貍貎貔豼貘戝貭貪貽貲貳貮貶賈賁賤賣賚賽賺賻贄贅贊贇贏贍贐齎贓賍贔贖赧赭赱赳趁趙跂趾趺跏跚跖跌跛跋跪跫跟跣跼踈踉跿踝踞踐踟蹂踵踰踴蹊"], +["e740","蹇蹉蹌蹐蹈蹙蹤蹠踪蹣蹕蹶蹲蹼躁躇躅躄躋躊躓躑躔躙躪躡躬躰軆躱躾軅軈軋軛軣軼軻軫軾輊輅輕輒輙輓輜輟輛輌輦輳輻輹轅轂輾轌轉轆轎轗轜"], +["e780","轢轣轤辜辟辣辭辯辷迚迥迢迪迯邇迴逅迹迺逑逕逡逍逞逖逋逧逶逵逹迸遏遐遑遒逎遉逾遖遘遞遨遯遶隨遲邂遽邁邀邊邉邏邨邯邱邵郢郤扈郛鄂鄒鄙鄲鄰酊酖酘酣酥酩酳酲醋醉醂醢醫醯醪醵醴醺釀釁釉釋釐釖釟釡釛釼釵釶鈞釿鈔鈬鈕鈑鉞鉗鉅鉉鉤鉈銕鈿鉋鉐銜銖銓銛鉚鋏銹銷鋩錏鋺鍄錮"], +["e840","錙錢錚錣錺錵錻鍜鍠鍼鍮鍖鎰鎬鎭鎔鎹鏖鏗鏨鏥鏘鏃鏝鏐鏈鏤鐚鐔鐓鐃鐇鐐鐶鐫鐵鐡鐺鑁鑒鑄鑛鑠鑢鑞鑪鈩鑰鑵鑷鑽鑚鑼鑾钁鑿閂閇閊閔閖閘閙"], +["e880","閠閨閧閭閼閻閹閾闊濶闃闍闌闕闔闖關闡闥闢阡阨阮阯陂陌陏陋陷陜陞陝陟陦陲陬隍隘隕隗險隧隱隲隰隴隶隸隹雎雋雉雍襍雜霍雕雹霄霆霈霓霎霑霏霖霙霤霪霰霹霽霾靄靆靈靂靉靜靠靤靦靨勒靫靱靹鞅靼鞁靺鞆鞋鞏鞐鞜鞨鞦鞣鞳鞴韃韆韈韋韜韭齏韲竟韶韵頏頌頸頤頡頷頽顆顏顋顫顯顰"], +["e940","顱顴顳颪颯颱颶飄飃飆飩飫餃餉餒餔餘餡餝餞餤餠餬餮餽餾饂饉饅饐饋饑饒饌饕馗馘馥馭馮馼駟駛駝駘駑駭駮駱駲駻駸騁騏騅駢騙騫騷驅驂驀驃"], +["e980","騾驕驍驛驗驟驢驥驤驩驫驪骭骰骼髀髏髑髓體髞髟髢髣髦髯髫髮髴髱髷髻鬆鬘鬚鬟鬢鬣鬥鬧鬨鬩鬪鬮鬯鬲魄魃魏魍魎魑魘魴鮓鮃鮑鮖鮗鮟鮠鮨鮴鯀鯊鮹鯆鯏鯑鯒鯣鯢鯤鯔鯡鰺鯲鯱鯰鰕鰔鰉鰓鰌鰆鰈鰒鰊鰄鰮鰛鰥鰤鰡鰰鱇鰲鱆鰾鱚鱠鱧鱶鱸鳧鳬鳰鴉鴈鳫鴃鴆鴪鴦鶯鴣鴟鵄鴕鴒鵁鴿鴾鵆鵈"], +["ea40","鵝鵞鵤鵑鵐鵙鵲鶉鶇鶫鵯鵺鶚鶤鶩鶲鷄鷁鶻鶸鶺鷆鷏鷂鷙鷓鷸鷦鷭鷯鷽鸚鸛鸞鹵鹹鹽麁麈麋麌麒麕麑麝麥麩麸麪麭靡黌黎黏黐黔黜點黝黠黥黨黯"], +["ea80","黴黶黷黹黻黼黽鼇鼈皷鼕鼡鼬鼾齊齒齔齣齟齠齡齦齧齬齪齷齲齶龕龜龠堯槇遙瑤凜熙"], +["ed40","纊褜鍈銈蓜俉炻昱棈鋹曻彅丨仡仼伀伃伹佖侒侊侚侔俍偀倢俿倞偆偰偂傔僴僘兊兤冝冾凬刕劜劦勀勛匀匇匤卲厓厲叝﨎咜咊咩哿喆坙坥垬埈埇﨏"], +["ed80","塚增墲夋奓奛奝奣妤妺孖寀甯寘寬尞岦岺峵崧嵓﨑嵂嵭嶸嶹巐弡弴彧德忞恝悅悊惞惕愠惲愑愷愰憘戓抦揵摠撝擎敎昀昕昻昉昮昞昤晥晗晙晴晳暙暠暲暿曺朎朗杦枻桒柀栁桄棏﨓楨﨔榘槢樰橫橆橳橾櫢櫤毖氿汜沆汯泚洄涇浯涖涬淏淸淲淼渹湜渧渼溿澈澵濵瀅瀇瀨炅炫焏焄煜煆煇凞燁燾犱"], +["ee40","犾猤猪獷玽珉珖珣珒琇珵琦琪琩琮瑢璉璟甁畯皂皜皞皛皦益睆劯砡硎硤硺礰礼神祥禔福禛竑竧靖竫箞精絈絜綷綠緖繒罇羡羽茁荢荿菇菶葈蒴蕓蕙"], +["ee80","蕫﨟薰蘒﨡蠇裵訒訷詹誧誾諟諸諶譓譿賰賴贒赶﨣軏﨤逸遧郞都鄕鄧釚釗釞釭釮釤釥鈆鈐鈊鈺鉀鈼鉎鉙鉑鈹鉧銧鉷鉸鋧鋗鋙鋐﨧鋕鋠鋓錥錡鋻﨨錞鋿錝錂鍰鍗鎤鏆鏞鏸鐱鑅鑈閒隆﨩隝隯霳霻靃靍靏靑靕顗顥飯飼餧館馞驎髙髜魵魲鮏鮱鮻鰀鵰鵫鶴鸙黑"], +["eeef","ⅰ",9,"¬¦'""], +["f040","",62], +["f080","",124], +["f140","",62], +["f180","",124], +["f240","",62], +["f280","",124], +["f340","",62], +["f380","",124], +["f440","",62], +["f480","",124], +["f540","",62], +["f580","",124], +["f640","",62], +["f680","",124], +["f740","",62], +["f780","",124], +["f840","",62], +["f880","",124], +["f940",""], +["fa40","ⅰ",9,"Ⅰ",9,"¬¦'"㈱№℡∵纊褜鍈銈蓜俉炻昱棈鋹曻彅丨仡仼伀伃伹佖侒侊侚侔俍偀倢俿倞偆偰偂傔僴僘兊"], +["fa80","兤冝冾凬刕劜劦勀勛匀匇匤卲厓厲叝﨎咜咊咩哿喆坙坥垬埈埇﨏塚增墲夋奓奛奝奣妤妺孖寀甯寘寬尞岦岺峵崧嵓﨑嵂嵭嶸嶹巐弡弴彧德忞恝悅悊惞惕愠惲愑愷愰憘戓抦揵摠撝擎敎昀昕昻昉昮昞昤晥晗晙晴晳暙暠暲暿曺朎朗杦枻桒柀栁桄棏﨓楨﨔榘槢樰橫橆橳橾櫢櫤毖氿汜沆汯泚洄涇浯"], +["fb40","涖涬淏淸淲淼渹湜渧渼溿澈澵濵瀅瀇瀨炅炫焏焄煜煆煇凞燁燾犱犾猤猪獷玽珉珖珣珒琇珵琦琪琩琮瑢璉璟甁畯皂皜皞皛皦益睆劯砡硎硤硺礰礼神"], +["fb80","祥禔福禛竑竧靖竫箞精絈絜綷綠緖繒罇羡羽茁荢荿菇菶葈蒴蕓蕙蕫﨟薰蘒﨡蠇裵訒訷詹誧誾諟諸諶譓譿賰賴贒赶﨣軏﨤逸遧郞都鄕鄧釚釗釞釭釮釤釥鈆鈐鈊鈺鉀鈼鉎鉙鉑鈹鉧銧鉷鉸鋧鋗鋙鋐﨧鋕鋠鋓錥錡鋻﨨錞鋿錝錂鍰鍗鎤鏆鏞鏸鐱鑅鑈閒隆﨩隝隯霳霻靃靍靏靑靕顗顥飯飼餧館馞驎髙"], +["fc40","髜魵魲鮏鮱鮻鰀鵰鵫鶴鸙黑"] +] diff --git a/node_modules/body-parser/node_modules/iconv-lite/encodings/utf16.js b/node_modules/body-parser/node_modules/iconv-lite/encodings/utf16.js new file mode 100644 index 0000000..4cd425d --- /dev/null +++ b/node_modules/body-parser/node_modules/iconv-lite/encodings/utf16.js @@ -0,0 +1,202 @@ + + +// == UTF16-BE codec. ========================================================== + +exports.utf16be = function(options) { + return { + encoder: utf16beEncoder, + decoder: utf16beDecoder, + + bom: new Buffer([0xFE, 0xFF]), + }; +}; + + +// -- Encoding + +function utf16beEncoder(options) { + return { + write: utf16beEncoderWrite, + end: function() {}, + } +} + +function utf16beEncoderWrite(str) { + var buf = new Buffer(str, 'ucs2'); + for (var i = 0; i < buf.length; i += 2) { + var tmp = buf[i]; buf[i] = buf[i+1]; buf[i+1] = tmp; + } + return buf; +} + + +// -- Decoding + +function utf16beDecoder(options) { + return { + write: utf16beDecoderWrite, + end: function() {}, + + overflowByte: -1, + }; +} + +function utf16beDecoderWrite(buf) { + if (buf.length == 0) + return ''; + + var buf2 = new Buffer(buf.length + 1), + i = 0, j = 0; + + if (this.overflowByte !== -1) { + buf2[0] = buf[0]; + buf2[1] = this.overflowByte; + i = 1; j = 2; + } + + for (; i < buf.length-1; i += 2, j+= 2) { + buf2[j] = buf[i+1]; + buf2[j+1] = buf[i]; + } + + this.overflowByte = (i == buf.length-1) ? buf[buf.length-1] : -1; + + return buf2.slice(0, j).toString('ucs2'); +} + + +// == UTF-16 codec ============================================================= +// Decoder chooses automatically from UTF-16LE and UTF-16BE using BOM and space-based heuristic. +// Defaults to UTF-16BE, according to RFC 2781, although it is against some industry practices, see +// http://en.wikipedia.org/wiki/UTF-16 and http://encoding.spec.whatwg.org/#utf-16le +// Decoder default can be changed: iconv.decode(buf, 'utf16', {default: 'utf-16le'}); + +// Encoder prepends BOM and uses UTF-16BE. +// Endianness can also be changed: iconv.encode(str, 'utf16', {use: 'utf-16le'}); + +exports.utf16 = function(options) { + return { + encoder: utf16Encoder, + decoder: utf16Decoder, + + getCodec: options.iconv.getCodec, + }; +}; + +// -- Encoding + +function utf16Encoder(options) { + options = options || {}; + var codec = this.getCodec(options.use || 'utf-16be'); + if (!codec.bom) + throw new Error("iconv-lite: in UTF-16 encoder, 'use' parameter should be either UTF-16BE or UTF16-LE."); + + return { + write: utf16EncoderWrite, + end: utf16EncoderEnd, + + bom: codec.bom, + internalEncoder: codec.encoder(options), + }; +} + +function utf16EncoderWrite(str) { + var buf = this.internalEncoder.write(str); + + if (this.bom) { + buf = Buffer.concat([this.bom, buf]); + this.bom = null; + } + + return buf; +} + +function utf16EncoderEnd() { + return this.internalEncoder.end(); +} + + +// -- Decoding + +function utf16Decoder(options) { + return { + write: utf16DecoderWrite, + end: utf16DecoderEnd, + + internalDecoder: null, + initialBytes: [], + initialBytesLen: 0, + + options: options || {}, + getCodec: this.getCodec, + }; +} + +function utf16DecoderWrite(buf) { + if (this.internalDecoder) + return this.internalDecoder.write(buf); + + // Codec is not chosen yet. Accumulate initial bytes. + this.initialBytes.push(buf); + this.initialBytesLen += buf.length; + + if (this.initialBytesLen < 16) // We need > 2 bytes to use space heuristic (see below) + return ''; + + // We have enough bytes -> decide endianness. + return utf16DecoderDecideEndianness.call(this); +} + +function utf16DecoderEnd() { + if (this.internalDecoder) + return this.internalDecoder.end(); + + var res = utf16DecoderDecideEndianness.call(this); + var trail; + + if (this.internalDecoder) + trail = this.internalDecoder.end(); + + return (trail && trail.length > 0) ? (res + trail) : res; +} + +function utf16DecoderDecideEndianness() { + var buf = Buffer.concat(this.initialBytes); + this.initialBytes.length = this.initialBytesLen = 0; + + if (buf.length < 2) + return ''; // Not a valid UTF-16 sequence anyway. + + // Default encoding. + var enc = this.options.default || 'utf-16be'; + + // Check BOM. + if (buf[0] == 0xFE && buf[1] == 0xFF) { // UTF-16BE BOM + enc = 'utf-16be'; buf = buf.slice(2); + } + else if (buf[0] == 0xFF && buf[1] == 0xFE) { // UTF-16LE BOM + enc = 'utf-16le'; buf = buf.slice(2); + } + else { + // No BOM found. Try to deduce encoding from initial content. + // Most of the time, the content has spaces (U+0020), but the opposite (U+2000) is very uncommon. + // So, we count spaces as if it was LE or BE, and decide from that. + var spaces = [0, 0], // Counts of space chars in both positions + _len = Math.min(buf.length - (buf.length % 2), 64); // Len is always even. + + for (var i = 0; i < _len; i += 2) { + if (buf[i] == 0x00 && buf[i+1] == 0x20) spaces[0]++; + if (buf[i] == 0x20 && buf[i+1] == 0x00) spaces[1]++; + } + + if (spaces[0] > 0 && spaces[1] == 0) + enc = 'utf-16be'; + else if (spaces[0] == 0 && spaces[1] > 0) + enc = 'utf-16le'; + } + + this.internalDecoder = this.getCodec(enc).decoder(this.options); + return this.internalDecoder.write(buf); +} + + diff --git a/node_modules/body-parser/node_modules/iconv-lite/encodings/utf7.js b/node_modules/body-parser/node_modules/iconv-lite/encodings/utf7.js new file mode 100644 index 0000000..740f766 --- /dev/null +++ b/node_modules/body-parser/node_modules/iconv-lite/encodings/utf7.js @@ -0,0 +1,284 @@ + +// UTF-7 codec, according to https://tools.ietf.org/html/rfc2152 +// Below is UTF-7-IMAP codec, according to http://tools.ietf.org/html/rfc3501#section-5.1.3 + +exports.utf7 = function(options) { + return { + encoder: function utf7Encoder() { + return { + write: utf7EncoderWrite, + end: function() {}, + + iconv: options.iconv, + }; + }, + decoder: function utf7Decoder() { + return { + write: utf7DecoderWrite, + end: utf7DecoderEnd, + + iconv: options.iconv, + inBase64: false, + base64Accum: '', + }; + }, + }; +}; + + +var nonDirectChars = /[^A-Za-z0-9'\(\),-\.\/:\? \n\r\t]+/g; + +function utf7EncoderWrite(str) { + // Naive implementation. + // Non-direct chars are encoded as "+-"; single "+" char is encoded as "+-". + return new Buffer(str.replace(nonDirectChars, function(chunk) { + return "+" + (chunk === '+' ? '' : + this.iconv.encode(chunk, 'utf16-be').toString('base64').replace(/=+$/, '')) + + "-"; + }.bind(this))); +} + + +var base64Regex = /[A-Za-z0-9\/+]/; +var base64Chars = []; +for (var i = 0; i < 256; i++) + base64Chars[i] = base64Regex.test(String.fromCharCode(i)); + +var plusChar = '+'.charCodeAt(0), + minusChar = '-'.charCodeAt(0), + andChar = '&'.charCodeAt(0); + +function utf7DecoderWrite(buf) { + var res = "", lastI = 0, + inBase64 = this.inBase64, + base64Accum = this.base64Accum; + + // The decoder is more involved as we must handle chunks in stream. + + for (var i = 0; i < buf.length; i++) { + if (!inBase64) { // We're in direct mode. + // Write direct chars until '+' + if (buf[i] == plusChar) { + res += this.iconv.decode(buf.slice(lastI, i), "ascii"); // Write direct chars. + lastI = i+1; + inBase64 = true; + } + } else { // We decode base64. + if (!base64Chars[buf[i]]) { // Base64 ended. + if (i == lastI && buf[i] == minusChar) {// "+-" -> "+" + res += "+"; + } else { + var b64str = base64Accum + buf.slice(lastI, i).toString(); + res += this.iconv.decode(new Buffer(b64str, 'base64'), "utf16-be"); + } + + if (buf[i] != minusChar) // Minus is absorbed after base64. + i--; + + lastI = i+1; + inBase64 = false; + base64Accum = ''; + } + } + } + + if (!inBase64) { + res += this.iconv.decode(buf.slice(lastI), "ascii"); // Write direct chars. + } else { + var b64str = base64Accum + buf.slice(lastI).toString(); + + var canBeDecoded = b64str.length - (b64str.length % 8); // Minimal chunk: 2 quads -> 2x3 bytes -> 3 chars. + base64Accum = b64str.slice(canBeDecoded); // The rest will be decoded in future. + b64str = b64str.slice(0, canBeDecoded); + + res += this.iconv.decode(new Buffer(b64str, 'base64'), "utf16-be"); + } + + this.inBase64 = inBase64; + this.base64Accum = base64Accum; + + return res; +} + +function utf7DecoderEnd() { + var res = ""; + if (this.inBase64 && this.base64Accum.length > 0) + res = this.iconv.decode(new Buffer(this.base64Accum, 'base64'), "utf16-be"); + + this.inBase64 = false; + this.base64Accum = ''; + return res; +} + + +// UTF-7-IMAP codec. +// RFC3501 Sec. 5.1.3 Modified UTF-7 (http://tools.ietf.org/html/rfc3501#section-5.1.3) +// Differences: +// * Base64 part is started by "&" instead of "+" +// * Direct characters are 0x20-0x7E, except "&" (0x26) +// * In Base64, "," is used instead of "/" +// * Base64 must not be used to represent direct characters. +// * No implicit shift back from Base64 (should always end with '-') +// * String must end in non-shifted position. +// * "-&" while in base64 is not allowed. + + +exports.utf7imap = function(options) { + return { + encoder: function utf7ImapEncoder() { + return { + write: utf7ImapEncoderWrite, + end: utf7ImapEncoderEnd, + + iconv: options.iconv, + inBase64: false, + base64Accum: new Buffer(6), + base64AccumIdx: 0, + }; + }, + decoder: function utf7ImapDecoder() { + return { + write: utf7ImapDecoderWrite, + end: utf7ImapDecoderEnd, + + iconv: options.iconv, + inBase64: false, + base64Accum: '', + }; + }, + }; +}; + + +function utf7ImapEncoderWrite(str) { + var inBase64 = this.inBase64, + base64Accum = this.base64Accum, + base64AccumIdx = this.base64AccumIdx, + buf = new Buffer(str.length*5 + 10), bufIdx = 0; + + for (var i = 0; i < str.length; i++) { + var uChar = str.charCodeAt(i); + if (0x20 <= uChar && uChar <= 0x7E) { // Direct character or '&'. + if (inBase64) { + if (base64AccumIdx > 0) { + bufIdx += buf.write(base64Accum.slice(0, base64AccumIdx).toString('base64').replace(/\//g, ',').replace(/=+$/, ''), bufIdx); + base64AccumIdx = 0; + } + + buf[bufIdx++] = minusChar; // Write '-', then go to direct mode. + inBase64 = false; + } + + if (!inBase64) { + buf[bufIdx++] = uChar; // Write direct character + + if (uChar === andChar) // Ampersand -> '&-' + buf[bufIdx++] = minusChar; + } + + } else { // Non-direct character + if (!inBase64) { + buf[bufIdx++] = andChar; // Write '&', then go to base64 mode. + inBase64 = true; + } + if (inBase64) { + base64Accum[base64AccumIdx++] = uChar >> 8; + base64Accum[base64AccumIdx++] = uChar & 0xFF; + + if (base64AccumIdx == base64Accum.length) { + bufIdx += buf.write(base64Accum.toString('base64').replace(/\//g, ','), bufIdx); + base64AccumIdx = 0; + } + } + } + } + + this.inBase64 = inBase64; + this.base64AccumIdx = base64AccumIdx; + + return buf.slice(0, bufIdx); +} + +function utf7ImapEncoderEnd() { + var buf = new Buffer(10), bufIdx = 0; + if (this.inBase64) { + if (this.base64AccumIdx > 0) { + bufIdx += buf.write(this.base64Accum.slice(0, this.base64AccumIdx).toString('base64').replace(/\//g, ',').replace(/=+$/, ''), bufIdx); + this.base64AccumIdx = 0; + } + + buf[bufIdx++] = minusChar; // Write '-', then go to direct mode. + this.inBase64 = false; + } + + return buf.slice(0, bufIdx); +} + + +var base64IMAPChars = base64Chars.slice(); +base64IMAPChars[','.charCodeAt(0)] = true; + +function utf7ImapDecoderWrite(buf) { + var res = "", lastI = 0, + inBase64 = this.inBase64, + base64Accum = this.base64Accum; + + // The decoder is more involved as we must handle chunks in stream. + // It is forgiving, closer to standard UTF-7 (for example, '-' is optional at the end). + + for (var i = 0; i < buf.length; i++) { + if (!inBase64) { // We're in direct mode. + // Write direct chars until '&' + if (buf[i] == andChar) { + res += this.iconv.decode(buf.slice(lastI, i), "ascii"); // Write direct chars. + lastI = i+1; + inBase64 = true; + } + } else { // We decode base64. + if (!base64IMAPChars[buf[i]]) { // Base64 ended. + if (i == lastI && buf[i] == minusChar) { // "&-" -> "&" + res += "&"; + } else { + var b64str = base64Accum + buf.slice(lastI, i).toString().replace(/,/g, '/'); + res += this.iconv.decode(new Buffer(b64str, 'base64'), "utf16-be"); + } + + if (buf[i] != minusChar) // Minus may be absorbed after base64. + i--; + + lastI = i+1; + inBase64 = false; + base64Accum = ''; + } + } + } + + if (!inBase64) { + res += this.iconv.decode(buf.slice(lastI), "ascii"); // Write direct chars. + } else { + var b64str = base64Accum + buf.slice(lastI).toString().replace(/,/g, '/'); + + var canBeDecoded = b64str.length - (b64str.length % 8); // Minimal chunk: 2 quads -> 2x3 bytes -> 3 chars. + base64Accum = b64str.slice(canBeDecoded); // The rest will be decoded in future. + b64str = b64str.slice(0, canBeDecoded); + + res += this.iconv.decode(new Buffer(b64str, 'base64'), "utf16-be"); + } + + this.inBase64 = inBase64; + this.base64Accum = base64Accum; + + return res; +} + +function utf7ImapDecoderEnd() { + var res = ""; + if (this.inBase64 && this.base64Accum.length > 0) + res = this.iconv.decode(new Buffer(this.base64Accum, 'base64'), "utf16-be"); + + this.inBase64 = false; + this.base64Accum = ''; + return res; +} + + diff --git a/node_modules/body-parser/node_modules/iconv-lite/lib/extend-node.js b/node_modules/body-parser/node_modules/iconv-lite/lib/extend-node.js new file mode 100644 index 0000000..000cee2 --- /dev/null +++ b/node_modules/body-parser/node_modules/iconv-lite/lib/extend-node.js @@ -0,0 +1,210 @@ + +// == Extend Node primitives to use iconv-lite ================================= + +module.exports = function (iconv) { + var original = undefined; // Place to keep original methods. + + iconv.extendNodeEncodings = function extendNodeEncodings() { + if (original) return; + original = {}; + + var nodeNativeEncodings = { + 'hex': true, 'utf8': true, 'utf-8': true, 'ascii': true, 'binary': true, + 'base64': true, 'ucs2': true, 'ucs-2': true, 'utf16le': true, 'utf-16le': true, + }; + + Buffer.isNativeEncoding = function(enc) { + return nodeNativeEncodings[enc && enc.toLowerCase()]; + } + + // -- SlowBuffer ----------------------------------------------------------- + var SlowBuffer = require('buffer').SlowBuffer; + + original.SlowBufferToString = SlowBuffer.prototype.toString; + SlowBuffer.prototype.toString = function(encoding, start, end) { + encoding = String(encoding || 'utf8').toLowerCase(); + start = +start || 0; + if (typeof end !== 'number') end = this.length; + + // Fastpath empty strings + if (+end == start) + return ''; + + // Use native conversion when possible + if (Buffer.isNativeEncoding(encoding)) + return original.SlowBufferToString.call(this, encoding, start, end); + + // Otherwise, use our decoding method. + if (typeof start == 'undefined') start = 0; + if (typeof end == 'undefined') end = this.length; + return iconv.decode(this.slice(start, end), encoding); + } + + original.SlowBufferWrite = SlowBuffer.prototype.write; + SlowBuffer.prototype.write = function(string, offset, length, encoding) { + // Support both (string, offset, length, encoding) + // and the legacy (string, encoding, offset, length) + if (isFinite(offset)) { + if (!isFinite(length)) { + encoding = length; + length = undefined; + } + } else { // legacy + var swap = encoding; + encoding = offset; + offset = length; + length = swap; + } + + offset = +offset || 0; + var remaining = this.length - offset; + if (!length) { + length = remaining; + } else { + length = +length; + if (length > remaining) { + length = remaining; + } + } + encoding = String(encoding || 'utf8').toLowerCase(); + + // Use native conversion when possible + if (Buffer.isNativeEncoding(encoding)) + return original.SlowBufferWrite.call(this, string, offset, length, encoding); + + if (string.length > 0 && (length < 0 || offset < 0)) + throw new RangeError('attempt to write beyond buffer bounds'); + + // Otherwise, use our encoding method. + var buf = iconv.encode(string, encoding); + if (buf.length < length) length = buf.length; + buf.copy(this, offset, 0, length); + return length; + } + + // -- Buffer --------------------------------------------------------------- + + original.BufferIsEncoding = Buffer.isEncoding; + Buffer.isEncoding = function(encoding) { + return Buffer.isNativeEncoding(encoding) || iconv.encodingExists(encoding); + } + + original.BufferByteLength = Buffer.byteLength; + Buffer.byteLength = SlowBuffer.byteLength = function(str, encoding) { + encoding = String(encoding || 'utf8').toLowerCase(); + + // Use native conversion when possible + if (Buffer.isNativeEncoding(encoding)) + return original.BufferByteLength.call(this, str, encoding); + + // Slow, I know, but we don't have a better way yet. + return iconv.encode(str, encoding).length; + } + + original.BufferToString = Buffer.prototype.toString; + Buffer.prototype.toString = function(encoding, start, end) { + encoding = String(encoding || 'utf8').toLowerCase(); + + // Use native conversion when possible + if (Buffer.isNativeEncoding(encoding)) + return original.BufferToString.call(this, encoding, start, end); + + // Otherwise, use our decoding method. + if (typeof start == 'undefined') start = 0; + if (typeof end == 'undefined') end = this.length; + return iconv.decode(this.slice(start, end), encoding); + } + + original.BufferWrite = Buffer.prototype.write; + Buffer.prototype.write = function(string, offset, length, encoding) { + var _offset = offset, _length = length, _encoding = encoding; + // Support both (string, offset, length, encoding) + // and the legacy (string, encoding, offset, length) + if (isFinite(offset)) { + if (!isFinite(length)) { + encoding = length; + length = undefined; + } + } else { // legacy + var swap = encoding; + encoding = offset; + offset = length; + length = swap; + } + + encoding = String(encoding || 'utf8').toLowerCase(); + + // Use native conversion when possible + if (Buffer.isNativeEncoding(encoding)) + return original.BufferWrite.call(this, string, _offset, _length, _encoding); + + offset = +offset || 0; + var remaining = this.length - offset; + if (!length) { + length = remaining; + } else { + length = +length; + if (length > remaining) { + length = remaining; + } + } + + if (string.length > 0 && (length < 0 || offset < 0)) + throw new RangeError('attempt to write beyond buffer bounds'); + + // Otherwise, use our encoding method. + var buf = iconv.encode(string, encoding); + if (buf.length < length) length = buf.length; + buf.copy(this, offset, 0, length); + return length; + + // TODO: Set _charsWritten. + } + + + // -- Readable ------------------------------------------------------------- + if (iconv.supportsStreams) { + var Readable = require('stream').Readable; + + original.ReadableSetEncoding = Readable.prototype.setEncoding; + Readable.prototype.setEncoding = function setEncoding(enc, options) { + // Try to use original function when possible. + if (Buffer.isNativeEncoding(enc)) + return original.ReadableSetEncoding.call(this, enc); + + // Try to use our own decoder, it has the same interface. + this._readableState.decoder = iconv.getCodec(enc).decoder(options); + this._readableState.encoding = enc; + } + + Readable.prototype.collect = iconv._collect; + } + } + + // Remove iconv-lite Node primitive extensions. + iconv.undoExtendNodeEncodings = function undoExtendNodeEncodings() { + if (!original) + throw new Error("require('iconv-lite').undoExtendNodeEncodings(): Nothing to undo; extendNodeEncodings() is not called.") + + delete Buffer.isNativeEncoding; + + var SlowBuffer = require('buffer').SlowBuffer; + + SlowBuffer.prototype.toString = original.SlowBufferToString; + SlowBuffer.prototype.write = original.SlowBufferWrite; + + Buffer.isEncoding = original.BufferIsEncoding; + Buffer.byteLength = original.BufferByteLength; + Buffer.prototype.toString = original.BufferToString; + Buffer.prototype.write = original.BufferWrite; + + if (iconv.supportsStreams) { + var Readable = require('stream').Readable; + + Readable.prototype.setEncoding = original.ReadableSetEncoding; + delete Readable.prototype.collect; + } + + original = undefined; + } +} diff --git a/node_modules/body-parser/node_modules/iconv-lite/lib/index.js b/node_modules/body-parser/node_modules/iconv-lite/lib/index.js new file mode 100644 index 0000000..0775589 --- /dev/null +++ b/node_modules/body-parser/node_modules/iconv-lite/lib/index.js @@ -0,0 +1,122 @@ + +var iconv = module.exports; + +// All codecs and aliases are kept here, keyed by encoding name/alias. +// They are lazy loaded in `iconv.getCodec` from `encodings/index.js`. +iconv.encodings = null; + +// Characters emitted in case of error. +iconv.defaultCharUnicode = '�'; +iconv.defaultCharSingleByte = '?'; + +// Public API. +iconv.encode = function encode(str, encoding, options) { + str = "" + (str || ""); // Ensure string. + + var encoder = iconv.getCodec(encoding).encoder(options); + + var res = encoder.write(str); + var trail = encoder.end(); + + return (trail && trail.length > 0) ? Buffer.concat([res, trail]) : res; +} + +iconv.decode = function decode(buf, encoding, options) { + if (typeof buf === 'string') { + if (!iconv.skipDecodeWarning) { + console.error('Iconv-lite warning: decode()-ing strings is deprecated. Refer to https://github.com/ashtuchkin/iconv-lite/wiki/Use-Buffers-when-decoding'); + iconv.skipDecodeWarning = true; + } + + buf = new Buffer("" + (buf || ""), "binary"); // Ensure buffer. + } + + var decoder = iconv.getCodec(encoding).decoder(options); + + var res = decoder.write(buf); + var trail = decoder.end(); + + return (trail && trail.length > 0) ? (res + trail) : res; +} + +iconv.encodingExists = function encodingExists(enc) { + try { + iconv.getCodec(enc); + return true; + } catch (e) { + return false; + } +} + +// Legacy aliases to convert functions +iconv.toEncoding = iconv.encode; +iconv.fromEncoding = iconv.decode; + +// Search for a codec in iconv.encodings. Cache codec data in iconv._codecDataCache. +iconv._codecDataCache = {}; +iconv.getCodec = function getCodec(encoding) { + if (!iconv.encodings) + iconv.encodings = require("../encodings"); // Lazy load all encoding definitions. + + // Canonicalize encoding name: strip all non-alphanumeric chars and appended year. + var enc = (''+encoding).toLowerCase().replace(/[^0-9a-z]|:\d{4}$/g, ""); + + // Traverse iconv.encodings to find actual codec. + var codecData, codecOptions; + while (true) { + codecData = iconv._codecDataCache[enc]; + if (codecData) + return codecData; + + var codec = iconv.encodings[enc]; + + switch (typeof codec) { + case "string": // Direct alias to other encoding. + enc = codec; + break; + + case "object": // Alias with options. Can be layered. + if (!codecOptions) { + codecOptions = codec; + codecOptions.encodingName = enc; + } + else { + for (var key in codec) + codecOptions[key] = codec[key]; + } + + enc = codec.type; + break; + + case "function": // Codec itself. + if (!codecOptions) + codecOptions = { encodingName: enc }; + codecOptions.iconv = iconv; + + // The codec function must load all tables and return object with .encoder and .decoder methods. + // It'll be called only once (for each different options object). + codecData = codec.call(iconv.encodings, codecOptions); + + iconv._codecDataCache[codecOptions.encodingName] = codecData; // Save it to be reused later. + return codecData; + + default: + throw new Error("Encoding not recognized: '" + encoding + "' (searched as: '"+enc+"')"); + } + } +} + +// Load extensions in Node. All of them are omitted in Browserify build via 'browser' field in package.json. +var nodeVer = typeof process !== 'undefined' && process.versions && process.versions.node; +if (nodeVer) { + + // Load streaming support in Node v0.10+ + var nodeVerArr = nodeVer.split(".").map(Number); + if (nodeVerArr[0] > 0 || nodeVerArr[1] >= 10) { + require("./streams")(iconv); + } + + // Load Node primitive extensions. + require("./extend-node")(iconv); +} + diff --git a/node_modules/body-parser/node_modules/iconv-lite/lib/streams.js b/node_modules/body-parser/node_modules/iconv-lite/lib/streams.js new file mode 100644 index 0000000..0563731 --- /dev/null +++ b/node_modules/body-parser/node_modules/iconv-lite/lib/streams.js @@ -0,0 +1,118 @@ +var Transform = require("stream").Transform; + + +// == Exports ================================================================== +module.exports = function(iconv) { + + // Additional Public API. + iconv.encodeStream = function encodeStream(encoding, options) { + return new IconvLiteEncoderStream(iconv.getCodec(encoding).encoder(options), options); + } + + iconv.decodeStream = function decodeStream(encoding, options) { + return new IconvLiteDecoderStream(iconv.getCodec(encoding).decoder(options), options); + } + + iconv.supportsStreams = true; + + + // Not published yet. + iconv.IconvLiteEncoderStream = IconvLiteEncoderStream; + iconv.IconvLiteDecoderStream = IconvLiteDecoderStream; + iconv._collect = IconvLiteDecoderStream.prototype.collect; +}; + + +// == Encoder stream ======================================================= +function IconvLiteEncoderStream(conv, options) { + this.conv = conv; + options = options || {}; + options.decodeStrings = false; // We accept only strings, so we don't need to decode them. + Transform.call(this, options); +} + +IconvLiteEncoderStream.prototype = Object.create(Transform.prototype, { + constructor: { value: IconvLiteEncoderStream } +}); + +IconvLiteEncoderStream.prototype._transform = function(chunk, encoding, done) { + if (typeof chunk != 'string') + return done(new Error("Iconv encoding stream needs strings as its input.")); + try { + var res = this.conv.write(chunk); + if (res && res.length) this.push(res); + done(); + } + catch (e) { + done(e); + } +} + +IconvLiteEncoderStream.prototype._flush = function(done) { + try { + var res = this.conv.end(); + if (res && res.length) this.push(res); + done(); + } + catch (e) { + done(e); + } +} + +IconvLiteEncoderStream.prototype.collect = function(cb) { + var chunks = []; + this.on('error', cb); + this.on('data', function(chunk) { chunks.push(chunk); }); + this.on('end', function() { + cb(null, Buffer.concat(chunks)); + }); + return this; +} + + +// == Decoder stream ======================================================= +function IconvLiteDecoderStream(conv, options) { + this.conv = conv; + options = options || {}; + options.encoding = this.encoding = 'utf8'; // We output strings. + Transform.call(this, options); +} + +IconvLiteDecoderStream.prototype = Object.create(Transform.prototype, { + constructor: { value: IconvLiteDecoderStream } +}); + +IconvLiteDecoderStream.prototype._transform = function(chunk, encoding, done) { + if (!Buffer.isBuffer(chunk)) + return done(new Error("Iconv decoding stream needs buffers as its input.")); + try { + var res = this.conv.write(chunk); + if (res && res.length) this.push(res, this.encoding); + done(); + } + catch (e) { + done(e); + } +} + +IconvLiteDecoderStream.prototype._flush = function(done) { + try { + var res = this.conv.end(); + if (res && res.length) this.push(res, this.encoding); + done(); + } + catch (e) { + done(e); + } +} + +IconvLiteDecoderStream.prototype.collect = function(cb) { + var res = ''; + this.on('error', cb); + this.on('data', function(chunk) { res += chunk; }); + this.on('end', function() { + cb(null, res); + }); + return this; +} + diff --git a/node_modules/body-parser/node_modules/iconv-lite/package.json b/node_modules/body-parser/node_modules/iconv-lite/package.json new file mode 100644 index 0000000..ee348fa --- /dev/null +++ b/node_modules/body-parser/node_modules/iconv-lite/package.json @@ -0,0 +1,110 @@ +{ + "name": "iconv-lite", + "description": "Convert character encodings in pure javascript.", + "version": "0.4.4", + "license": "MIT", + "keywords": [ + "iconv", + "convert", + "charset", + "icu" + ], + "author": { + "name": "Alexander Shtuchkin", + "email": "ashtuchkin@gmail.com" + }, + "contributors": [ + { + "name": "Jinwu Zhan", + "url": "https://github.com/jenkinv" + }, + { + "name": "Adamansky Anton", + "url": "https://github.com/adamansky" + }, + { + "name": "George Stagas", + "url": "https://github.com/stagas" + }, + { + "name": "Mike D Pilsbury", + "url": "https://github.com/pekim" + }, + { + "name": "Niggler", + "url": "https://github.com/Niggler" + }, + { + "name": "wychi", + "url": "https://github.com/wychi" + }, + { + "name": "David Kuo", + "url": "https://github.com/david50407" + }, + { + "name": "ChangZhuo Chen", + "url": "https://github.com/czchen" + }, + { + "name": "Lee Treveil", + "url": "https://github.com/leetreveil" + }, + { + "name": "Brian White", + "url": "https://github.com/mscdex" + }, + { + "name": "Mithgol", + "url": "https://github.com/Mithgol" + } + ], + "main": "./lib/index.js", + "homepage": "https://github.com/ashtuchkin/iconv-lite", + "bugs": { + "url": "https://github.com/ashtuchkin/iconv-lite/issues" + }, + "repository": { + "type": "git", + "url": "git://github.com/ashtuchkin/iconv-lite.git" + }, + "engines": { + "node": ">=0.8.0" + }, + "scripts": { + "test": "mocha --reporter spec --grep ." + }, + "browser": { + "./extend-node": false, + "./streams": false + }, + "devDependencies": { + "mocha": "*", + "request": "*", + "unorm": "*", + "errto": "*", + "async": "*", + "iconv": "~2.1.4" + }, + "gitHead": "9f0b0a7631d167322f47c2202aa3e5b090945131", + "_id": "iconv-lite@0.4.4", + "_shasum": "e95f2e41db0735fc21652f7827a5ee32e63c83a8", + "_from": "iconv-lite@0.4.4", + "_npmVersion": "1.4.14", + "_npmUser": { + "name": "ashtuchkin", + "email": "ashtuchkin@gmail.com" + }, + "maintainers": [ + { + "name": "ashtuchkin", + "email": "ashtuchkin@gmail.com" + } + ], + "dist": { + "shasum": "e95f2e41db0735fc21652f7827a5ee32e63c83a8", + "tarball": "http://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.4.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.4.tgz" +} diff --git a/node_modules/body-parser/node_modules/media-typer/HISTORY.md b/node_modules/body-parser/node_modules/media-typer/HISTORY.md new file mode 100644 index 0000000..62c2003 --- /dev/null +++ b/node_modules/body-parser/node_modules/media-typer/HISTORY.md @@ -0,0 +1,22 @@ +0.3.0 / 2014-09-07 +================== + + * Support Node.js 0.6 + * Throw error when parameter format invalid on parse + +0.2.0 / 2014-06-18 +================== + + * Add `typer.format()` to format media types + +0.1.0 / 2014-06-17 +================== + + * Accept `req` as argument to `parse` + * Accept `res` as argument to `parse` + * Parse media type with extra LWS between type and first parameter + +0.0.0 / 2014-06-13 +================== + + * Initial implementation diff --git a/node_modules/body-parser/node_modules/media-typer/LICENSE b/node_modules/body-parser/node_modules/media-typer/LICENSE new file mode 100644 index 0000000..b7dce6c --- /dev/null +++ b/node_modules/body-parser/node_modules/media-typer/LICENSE @@ -0,0 +1,22 @@ +(The MIT License) + +Copyright (c) 2014 Douglas Christopher Wilson + +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/node_modules/body-parser/node_modules/media-typer/README.md b/node_modules/body-parser/node_modules/media-typer/README.md new file mode 100644 index 0000000..d8df623 --- /dev/null +++ b/node_modules/body-parser/node_modules/media-typer/README.md @@ -0,0 +1,81 @@ +# media-typer + +[![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] + +Simple RFC 6838 media type parser + +## Installation + +```sh +$ npm install media-typer +``` + +## API + +```js +var typer = require('media-typer') +``` + +### typer.parse(string) + +```js +var obj = typer.parse('image/svg+xml; charset=utf-8') +``` + +Parse a media type string. This will return an object with the following +properties (examples are shown for the string `'image/svg+xml; charset=utf-8'`): + + - `type`: The type of the media type (always lower case). Example: `'image'` + + - `subtype`: The subtype of the media type (always lower case). Example: `'svg'` + + - `suffix`: The suffix of the media type (always lower case). Example: `'xml'` + + - `parameters`: An object of the parameters in the media type (name of parameter always lower case). Example: `{charset: 'utf-8'}` + +### typer.parse(req) + +```js +var obj = typer.parse(req) +``` + +Parse the `content-type` header from the given `req`. Short-cut for +`typer.parse(req.headers['content-type'])`. + +### typer.parse(res) + +```js +var obj = typer.parse(res) +``` + +Parse the `content-type` header set on the given `res`. Short-cut for +`typer.parse(res.getHeader('content-type'))`. + +### typer.format(obj) + +```js +var obj = typer.format({type: 'image', subtype: 'svg', suffix: 'xml'}) +``` + +Format an object into a media type string. This will return a string of the +mime type for the given object. For the properties of the object, see the +documentation for `typer.parse(string)`. + +## License + +[MIT](LICENSE) + +[npm-image]: https://img.shields.io/npm/v/media-typer.svg?style=flat +[npm-url]: https://npmjs.org/package/media-typer +[node-version-image]: https://img.shields.io/badge/node.js-%3E%3D_0.6-brightgreen.svg?style=flat +[node-version-url]: http://nodejs.org/download/ +[travis-image]: https://img.shields.io/travis/jshttp/media-typer.svg?style=flat +[travis-url]: https://travis-ci.org/jshttp/media-typer +[coveralls-image]: https://img.shields.io/coveralls/jshttp/media-typer.svg?style=flat +[coveralls-url]: https://coveralls.io/r/jshttp/media-typer +[downloads-image]: https://img.shields.io/npm/dm/media-typer.svg?style=flat +[downloads-url]: https://npmjs.org/package/media-typer diff --git a/node_modules/body-parser/node_modules/media-typer/index.js b/node_modules/body-parser/node_modules/media-typer/index.js new file mode 100644 index 0000000..07f7295 --- /dev/null +++ b/node_modules/body-parser/node_modules/media-typer/index.js @@ -0,0 +1,270 @@ +/*! + * media-typer + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * RegExp to match *( ";" parameter ) in RFC 2616 sec 3.7 + * + * parameter = token "=" ( token | quoted-string ) + * token = 1* + * separators = "(" | ")" | "<" | ">" | "@" + * | "," | ";" | ":" | "\" | <"> + * | "/" | "[" | "]" | "?" | "=" + * | "{" | "}" | SP | HT + * quoted-string = ( <"> *(qdtext | quoted-pair ) <"> ) + * qdtext = > + * quoted-pair = "\" CHAR + * CHAR = + * TEXT = + * LWS = [CRLF] 1*( SP | HT ) + * CRLF = CR LF + * CR = + * LF = + * SP = + * SHT = + * CTL = + * OCTET = + */ +var paramRegExp = /; *([!#$%&'\*\+\-\.0-9A-Z\^_`a-z\|~]+) *= *("(?:[ !\u0023-\u005b\u005d-\u007e\u0080-\u00ff]|\\[\u0020-\u007e])*"|[!#$%&'\*\+\-\.0-9A-Z\^_`a-z\|~]+) */g; +var textRegExp = /^[\u0020-\u007e\u0080-\u00ff]+$/ +var tokenRegExp = /^[!#$%&'\*\+\-\.0-9A-Z\^_`a-z\|~]+$/ + +/** + * RegExp to match quoted-pair in RFC 2616 + * + * quoted-pair = "\" CHAR + * CHAR = + */ +var qescRegExp = /\\([\u0000-\u007f])/g; + +/** + * RegExp to match chars that must be quoted-pair in RFC 2616 + */ +var quoteRegExp = /([\\"])/g; + +/** + * RegExp to match type in RFC 6838 + * + * type-name = restricted-name + * subtype-name = restricted-name + * restricted-name = restricted-name-first *126restricted-name-chars + * restricted-name-first = ALPHA / DIGIT + * restricted-name-chars = ALPHA / DIGIT / "!" / "#" / + * "$" / "&" / "-" / "^" / "_" + * restricted-name-chars =/ "." ; Characters before first dot always + * ; specify a facet name + * restricted-name-chars =/ "+" ; Characters after last plus always + * ; specify a structured syntax suffix + * ALPHA = %x41-5A / %x61-7A ; A-Z / a-z + * DIGIT = %x30-39 ; 0-9 + */ +var subtypeNameRegExp = /^[A-Za-z0-9][A-Za-z0-9!#$&^_.-]{0,126}$/ +var typeNameRegExp = /^[A-Za-z0-9][A-Za-z0-9!#$&^_-]{0,126}$/ +var typeRegExp = /^ *([A-Za-z0-9][A-Za-z0-9!#$&^_-]{0,126})\/([A-Za-z0-9][A-Za-z0-9!#$&^_.+-]{0,126}) *$/; + +/** + * Module exports. + */ + +exports.format = format +exports.parse = parse + +/** + * Format object to media type. + * + * @param {object} obj + * @return {string} + * @api public + */ + +function format(obj) { + if (!obj || typeof obj !== 'object') { + throw new TypeError('argument obj is required') + } + + var parameters = obj.parameters + var subtype = obj.subtype + var suffix = obj.suffix + var type = obj.type + + if (!type || !typeNameRegExp.test(type)) { + throw new TypeError('invalid type') + } + + if (!subtype || !subtypeNameRegExp.test(subtype)) { + throw new TypeError('invalid subtype') + } + + // format as type/subtype + var string = type + '/' + subtype + + // append +suffix + if (suffix) { + if (!typeNameRegExp.test(suffix)) { + throw new TypeError('invalid suffix') + } + + string += '+' + suffix + } + + // append parameters + if (parameters && typeof parameters === 'object') { + var param + var params = Object.keys(parameters).sort() + + for (var i = 0; i < params.length; i++) { + param = params[i] + + if (!tokenRegExp.test(param)) { + throw new TypeError('invalid parameter name') + } + + string += '; ' + param + '=' + qstring(parameters[param]) + } + } + + return string +} + +/** + * Parse media type to object. + * + * @param {string|object} string + * @return {Object} + * @api public + */ + +function parse(string) { + if (!string) { + throw new TypeError('argument string is required') + } + + // support req/res-like objects as argument + if (typeof string === 'object') { + string = getcontenttype(string) + } + + if (typeof string !== 'string') { + throw new TypeError('argument string is required to be a string') + } + + var index = string.indexOf(';') + var type = index !== -1 + ? string.substr(0, index) + : string + + var key + var match + var obj = splitType(type) + var params = {} + var value + + paramRegExp.lastIndex = index + + while (match = paramRegExp.exec(string)) { + if (match.index !== index) { + throw new TypeError('invalid parameter format') + } + + index += match[0].length + key = match[1].toLowerCase() + value = match[2] + + if (value[0] === '"') { + // remove quotes and escapes + value = value + .substr(1, value.length - 2) + .replace(qescRegExp, '$1') + } + + params[key] = value + } + + if (index !== -1 && index !== string.length) { + throw new TypeError('invalid parameter format') + } + + obj.parameters = params + + return obj +} + +/** + * Get content-type from req/res objects. + * + * @param {object} + * @return {Object} + * @api private + */ + +function getcontenttype(obj) { + if (typeof obj.getHeader === 'function') { + // res-like + return obj.getHeader('content-type') + } + + if (typeof obj.headers === 'object') { + // req-like + return obj.headers && obj.headers['content-type'] + } +} + +/** + * Quote a string if necessary. + * + * @param {string} val + * @return {string} + * @api private + */ + +function qstring(val) { + var str = String(val) + + // no need to quote tokens + if (tokenRegExp.test(str)) { + return str + } + + if (str.length > 0 && !textRegExp.test(str)) { + throw new TypeError('invalid parameter value') + } + + return '"' + str.replace(quoteRegExp, '\\$1') + '"' +} + +/** + * Simply "type/subtype+siffx" into parts. + * + * @param {string} string + * @return {Object} + * @api private + */ + +function splitType(string) { + var match = typeRegExp.exec(string.toLowerCase()) + + if (!match) { + throw new TypeError('invalid media type') + } + + var type = match[1] + var subtype = match[2] + var suffix + + // suffix after last + + var index = subtype.lastIndexOf('+') + if (index !== -1) { + suffix = subtype.substr(index + 1) + subtype = subtype.substr(0, index) + } + + var obj = { + type: type, + subtype: subtype, + suffix: suffix + } + + return obj +} diff --git a/node_modules/body-parser/node_modules/media-typer/package.json b/node_modules/body-parser/node_modules/media-typer/package.json new file mode 100644 index 0000000..88bb0a8 --- /dev/null +++ b/node_modules/body-parser/node_modules/media-typer/package.json @@ -0,0 +1,57 @@ +{ + "name": "media-typer", + "description": "Simple RFC 6838 media type parser and formatter", + "version": "0.3.0", + "author": { + "name": "Douglas Christopher Wilson", + "email": "doug@somethingdoug.com" + }, + "license": "MIT", + "repository": { + "type": "git", + "url": "https://github.com/jshttp/media-typer" + }, + "devDependencies": { + "istanbul": "0.3.2", + "mocha": "~1.21.4", + "should": "~4.0.4" + }, + "files": [ + "LICENSE", + "HISTORY.md", + "index.js" + ], + "engines": { + "node": ">= 0.6" + }, + "scripts": { + "test": "mocha --reporter spec --check-leaks --bail 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/" + }, + "gitHead": "d49d41ffd0bb5a0655fa44a59df2ec0bfc835b16", + "bugs": { + "url": "https://github.com/jshttp/media-typer/issues" + }, + "homepage": "https://github.com/jshttp/media-typer", + "_id": "media-typer@0.3.0", + "_shasum": "8710d7af0aa626f8fffa1ce00168545263255748", + "_from": "media-typer@0.3.0", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + "maintainers": [ + { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + } + ], + "dist": { + "shasum": "8710d7af0aa626f8fffa1ce00168545263255748", + "tarball": "http://registry.npmjs.org/media-typer/-/media-typer-0.3.0.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/media-typer/-/media-typer-0.3.0.tgz" +} diff --git a/node_modules/body-parser/node_modules/on-finished/HISTORY.md b/node_modules/body-parser/node_modules/on-finished/HISTORY.md new file mode 100644 index 0000000..0aa241b --- /dev/null +++ b/node_modules/body-parser/node_modules/on-finished/HISTORY.md @@ -0,0 +1,66 @@ +2.1.0 / 2014-08-16 +================== + + * Check if `socket` is detached + * Return `undefined` for `isFinished` if state unknown + +2.0.0 / 2014-08-16 +================== + + * Add `isFinished` function + * Move to `jshttp` organization + * Remove support for plain socket argument + * Rename to `on-finished` + * Support both `req` and `res` as arguments + * deps: ee-first@1.0.5 + +1.2.2 / 2014-06-10 +================== + + * Reduce listeners added to emitters + - avoids "event emitter leak" warnings when used multiple times on same request + +1.2.1 / 2014-06-08 +================== + + * Fix returned value when already finished + +1.2.0 / 2014-06-05 +================== + + * Call callback when called on already-finished socket + +1.1.4 / 2014-05-27 +================== + + * Support node.js 0.8 + +1.1.3 / 2014-04-30 +================== + + * Make sure errors passed as instanceof `Error` + +1.1.2 / 2014-04-18 +================== + + * Default the `socket` to passed-in object + +1.1.1 / 2014-01-16 +================== + + * Rename module to `finished` + +1.1.0 / 2013-12-25 +================== + + * Call callback when called on already-errored socket + +1.0.1 / 2013-12-20 +================== + + * Actually pass the error to the callback + +1.0.0 / 2013-12-20 +================== + + * Initial release diff --git a/node_modules/body-parser/node_modules/on-finished/LICENSE b/node_modules/body-parser/node_modules/on-finished/LICENSE new file mode 100644 index 0000000..5931fd2 --- /dev/null +++ b/node_modules/body-parser/node_modules/on-finished/LICENSE @@ -0,0 +1,23 @@ +(The MIT License) + +Copyright (c) 2013 Jonathan Ong +Copyright (c) 2014 Douglas Christopher Wilson + +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/node_modules/body-parser/node_modules/on-finished/README.md b/node_modules/body-parser/node_modules/on-finished/README.md new file mode 100644 index 0000000..887b5c3 --- /dev/null +++ b/node_modules/body-parser/node_modules/on-finished/README.md @@ -0,0 +1,90 @@ +# on-finished + +[![NPM Version](http://img.shields.io/npm/v/on-finished.svg?style=flat)](https://www.npmjs.org/package/on-finished) +[![Node.js Version](http://img.shields.io/badge/node.js->=_0.8-brightgreen.svg?style=flat)](http://nodejs.org/download/) +[![Build Status](http://img.shields.io/travis/jshttp/on-finished.svg?style=flat)](https://travis-ci.org/jshttp/on-finished) +[![Coverage Status](https://img.shields.io/coveralls/jshttp/on-finished.svg?style=flat)](https://coveralls.io/r/jshttp/on-finished) + +Execute a callback when a request closes, finishes, or errors. + +## Install + +```sh +$ npm install on-finished +``` + +## API + +```js +var onFinished = require('on-finished') +``` + +### onFinished(res, listener) + +Attach a listener to listen for the response to finish. The listener will +be invoked only once when the response finished. If the response finished +to to an error, the first argument will contain the error. + +Listening to the end of a response would be used to close things associated +with the response, like open files. + +```js +onFinished(res, function (err) { + // clean up open fds, etc. +}) +``` + +### onFinished(req, listener) + +Attach a listener to listen for the request to finish. The listener will +be invoked only once when the request finished. If the request finished +to to an error, the first argument will contain the error. + +Listening to the end of a request would be used to know when to continue +after reading the data. + +```js +var data = '' + +req.setEncoding('utf8') +res.on('data', function (str) { + data += str +}) + +onFinished(req, function (err) { + // data is read unless there is err +}) +``` + +### onFinished.isFinished(res) + +Determine if `res` is already finished. This would be useful to check and +not even start certain operations if the response has already finished. + +### onFinished.isFinished(req) + +Determine if `req` is already finished. This would be useful to check and +not even start certain operations if the request has already finished. + +### Example + +The following code ensures that file descriptors are always closed +once the response finishes. + +```js +var destroy = require('destroy') +var http = require('http') +var onFinished = require('finished') + +http.createServer(function onRequest(req, res) { + var stream = fs.createReadStream('package.json') + stream.pipe(res) + onFinished(res, function (err) { + destroy(stream) + }) +}) +``` + +## License + +[MIT](LICENSE) diff --git a/node_modules/body-parser/node_modules/on-finished/index.js b/node_modules/body-parser/node_modules/on-finished/index.js new file mode 100644 index 0000000..a505561 --- /dev/null +++ b/node_modules/body-parser/node_modules/on-finished/index.js @@ -0,0 +1,127 @@ +/*! + * on-finished + * Copyright(c) 2013 Jonathan Ong + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module exports. + */ + +module.exports = onFinished; +module.exports.isFinished = isFinished; + +/** +* Module dependencies. +*/ + +var first = require('ee-first') + +/** +* Variables. +*/ + +/* istanbul ignore next */ +var defer = typeof setImmediate === 'function' + ? setImmediate + : function(fn){ process.nextTick(fn.bind.apply(fn, arguments)) } + +/** + * Invoke callback when the response has finished, useful for + * cleaning up resources afterwards. + * + * @param {object} msg + * @param {function} listener + * @return {object} + * @api public + */ + +function onFinished(msg, listener) { + if (isFinished(msg) !== false) { + defer(listener) + return msg + } + + // attach the listener to the message + attachListener(msg, listener) + + return msg +} + +/** + * Determine is message is already finished. + * + * @param {object} msg + * @return {boolean} + * @api public + */ + +function isFinished(msg) { + var socket = msg.socket + + if (typeof msg.finished === 'boolean') { + // OutgoingMessage + return Boolean(!socket || msg.finished || !socket.writable) + } + + if (typeof msg.complete === 'boolean') { + // IncomingMessage + return Boolean(!socket || msg.complete || !socket.readable) + } + + // don't know + return undefined +} + +/** + * Attach the listener to the message. + * + * @param {object} msg + * @return {function} + * @api private + */ + +function attachListener(msg, listener) { + var attached = msg.__onFinished + var socket = msg.socket + + // create a private single listener with queue + if (!attached || !attached.queue) { + attached = msg.__onFinished = createListener(msg) + + // finished on first event + first([ + [socket, 'error', 'close'], + [msg, 'end', 'finish'], + ], attached) + } + + attached.queue.push(listener) +} + +/** + * Create listener on message. + * + * @param {object} msg + * @return {function} + * @api private + */ + +function createListener(msg) { + function listener(err) { + if (msg.__onFinished === listener) msg.__onFinished = null + if (!listener.queue) return + + var queue = listener.queue + listener.queue = null + + for (var i = 0; i < queue.length; i++) { + queue[i](err) + } + } + + listener.queue = [] + + return listener +} diff --git a/node_modules/body-parser/node_modules/on-finished/node_modules/ee-first/LICENSE b/node_modules/body-parser/node_modules/on-finished/node_modules/ee-first/LICENSE new file mode 100644 index 0000000..a7ae8ee --- /dev/null +++ b/node_modules/body-parser/node_modules/on-finished/node_modules/ee-first/LICENSE @@ -0,0 +1,22 @@ + +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/node_modules/body-parser/node_modules/on-finished/node_modules/ee-first/README.md b/node_modules/body-parser/node_modules/on-finished/node_modules/ee-first/README.md new file mode 100644 index 0000000..0ebc0aa --- /dev/null +++ b/node_modules/body-parser/node_modules/on-finished/node_modules/ee-first/README.md @@ -0,0 +1,63 @@ +# EE First + +[![NPM version][npm-image]][npm-url] +[![Build status][travis-image]][travis-url] +[![Test coverage][coveralls-image]][coveralls-url] +[![License][license-image]][license-url] +[![Downloads][downloads-image]][downloads-url] +[![Gittip][gittip-image]][gittip-url] + +Get the first event in a set of event emitters and event pairs, +then clean up after itself. + +## Install + +```sh +$ npm install ee-first +``` + +## API + +```js +var first = require('ee-first') +``` + +### first(arr, listener) + +Invoke `listener` on the first event from the list specified in `arr`. `arr` is +an array of arrays, with each array in the format `[ee, ...event]`. `listener` +will be called only once, the first time any of the given events are emitted. If +`error` is one of the listened events, then if that fires first, the `listener` +will be given the `err` argument. + +The `listener` is invoked as `listener(err, ee, event, args)`, where `err` is the +first argument emitted from an `error` event, if applicable; `ee` is the event +emitter that fired; `event` is the string event name that fired; and `args` is an +array of the arguments that were emitted on the event. + +```js +var ee1 = new EventEmitter() +var ee2 = new EventEmitter() + +first([ + [ee1, 'close', 'end', 'error'], + [ee2, 'error'] +], function (err, ee, event, args) { + // listener invoked +}) +``` + +[npm-image]: https://img.shields.io/npm/v/ee-first.svg?style=flat-square +[npm-url]: https://npmjs.org/package/ee-first +[github-tag]: http://img.shields.io/github/tag/jonathanong/ee-first.svg?style=flat-square +[github-url]: https://github.com/jonathanong/ee-first/tags +[travis-image]: https://img.shields.io/travis/jonathanong/ee-first.svg?style=flat-square +[travis-url]: https://travis-ci.org/jonathanong/ee-first +[coveralls-image]: https://img.shields.io/coveralls/jonathanong/ee-first.svg?style=flat-square +[coveralls-url]: https://coveralls.io/r/jonathanong/ee-first?branch=master +[license-image]: http://img.shields.io/npm/l/ee-first.svg?style=flat-square +[license-url]: LICENSE.md +[downloads-image]: http://img.shields.io/npm/dm/ee-first.svg?style=flat-square +[downloads-url]: https://npmjs.org/package/ee-first +[gittip-image]: https://img.shields.io/gittip/jonathanong.svg?style=flat-square +[gittip-url]: https://www.gittip.com/jonathanong/ diff --git a/node_modules/body-parser/node_modules/on-finished/node_modules/ee-first/index.js b/node_modules/body-parser/node_modules/on-finished/node_modules/ee-first/index.js new file mode 100644 index 0000000..d0c48c9 --- /dev/null +++ b/node_modules/body-parser/node_modules/on-finished/node_modules/ee-first/index.js @@ -0,0 +1,60 @@ + +module.exports = function first(stuff, done) { + if (!Array.isArray(stuff)) + throw new TypeError('arg must be an array of [ee, events...] arrays') + + var cleanups = [] + + for (var i = 0; i < stuff.length; i++) { + var arr = stuff[i] + + if (!Array.isArray(arr) || arr.length < 2) + throw new TypeError('each array member must be [ee, events...]') + + var ee = arr[0] + + for (var j = 1; j < arr.length; j++) { + var event = arr[j] + var fn = listener(event, cleanup) + + // listen to the event + ee.on(event, fn) + // push this listener to the list of cleanups + cleanups.push({ + ee: ee, + event: event, + fn: fn, + }) + } + } + + return function (fn) { + done = fn + } + + function cleanup() { + var x + for (var i = 0; i < cleanups.length; i++) { + x = cleanups[i] + x.ee.removeListener(x.event, x.fn) + } + done.apply(null, arguments) + } +} + +function listener(event, done) { + return function onevent(arg1) { + var args = new Array(arguments.length) + var ee = this + var err = event === 'error' + ? arg1 + : null + + // copy args to prevent arguments escaping scope + for (var i = 0; i < args.length; i++) { + args[i] = arguments[i] + } + + done(err, ee, event, args) + } +} diff --git a/node_modules/body-parser/node_modules/on-finished/node_modules/ee-first/package.json b/node_modules/body-parser/node_modules/on-finished/node_modules/ee-first/package.json new file mode 100644 index 0000000..f19f55e --- /dev/null +++ b/node_modules/body-parser/node_modules/on-finished/node_modules/ee-first/package.json @@ -0,0 +1,63 @@ +{ + "name": "ee-first", + "description": "return the first event in a set of ee/event pairs", + "version": "1.0.5", + "author": { + "name": "Jonathan Ong", + "email": "me@jongleberry.com", + "url": "http://jongleberry.com" + }, + "contributors": [ + { + "name": "Douglas Christopher Wilson", + "email": "doug@somethingdoug.com" + } + ], + "license": "MIT", + "repository": { + "type": "git", + "url": "https://github.com/jonathanong/ee-first" + }, + "devDependencies": { + "istanbul": "0.3.0", + "mocha": "1" + }, + "files": [ + "index.js", + "LICENSE" + ], + "scripts": { + "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/" + }, + "gitHead": "c9d9a6881863c0d2fcc2e4ac99a170088c205304", + "bugs": { + "url": "https://github.com/jonathanong/ee-first/issues" + }, + "homepage": "https://github.com/jonathanong/ee-first", + "_id": "ee-first@1.0.5", + "_shasum": "8c9b212898d8cd9f1a9436650ce7be202c9e9ff0", + "_from": "ee-first@1.0.5", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + "maintainers": [ + { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + }, + { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + } + ], + "dist": { + "shasum": "8c9b212898d8cd9f1a9436650ce7be202c9e9ff0", + "tarball": "http://registry.npmjs.org/ee-first/-/ee-first-1.0.5.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/ee-first/-/ee-first-1.0.5.tgz" +} diff --git a/node_modules/body-parser/node_modules/on-finished/package.json b/node_modules/body-parser/node_modules/on-finished/package.json new file mode 100644 index 0000000..bf7dcd6 --- /dev/null +++ b/node_modules/body-parser/node_modules/on-finished/package.json @@ -0,0 +1,70 @@ +{ + "name": "on-finished", + "description": "Execute a callback when a request closes, finishes, or errors", + "version": "2.1.0", + "contributors": [ + { + "name": "Douglas Christopher Wilson", + "email": "doug@somethingdoug.com" + }, + { + "name": "Jonathan Ong", + "email": "me@jongleberry.com", + "url": "http://jongleberry.com" + } + ], + "license": "MIT", + "repository": { + "type": "git", + "url": "https://github.com/jshttp/on-finished" + }, + "dependencies": { + "ee-first": "1.0.5" + }, + "devDependencies": { + "istanbul": "0.3.0", + "mocha": "~1.21.4" + }, + "engine": { + "node": ">= 0.8.0" + }, + "files": [ + "HISTORY.md", + "LICENSE", + "index.js" + ], + "scripts": { + "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/" + }, + "gitHead": "1ad808e704e2aeda3a7464b78cacead2fb453727", + "bugs": { + "url": "https://github.com/jshttp/on-finished/issues" + }, + "homepage": "https://github.com/jshttp/on-finished", + "_id": "on-finished@2.1.0", + "_shasum": "0c539f09291e8ffadde0c8a25850fb2cedc7022d", + "_from": "on-finished@~2.1.0", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + "maintainers": [ + { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + } + ], + "dist": { + "shasum": "0c539f09291e8ffadde0c8a25850fb2cedc7022d", + "tarball": "http://registry.npmjs.org/on-finished/-/on-finished-2.1.0.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/on-finished/-/on-finished-2.1.0.tgz" +} diff --git a/node_modules/body-parser/node_modules/qs/.jshintignore b/node_modules/body-parser/node_modules/qs/.jshintignore new file mode 100644 index 0000000..3c3629e --- /dev/null +++ b/node_modules/body-parser/node_modules/qs/.jshintignore @@ -0,0 +1 @@ +node_modules diff --git a/node_modules/body-parser/node_modules/qs/.jshintrc b/node_modules/body-parser/node_modules/qs/.jshintrc new file mode 100644 index 0000000..997b3f7 --- /dev/null +++ b/node_modules/body-parser/node_modules/qs/.jshintrc @@ -0,0 +1,10 @@ +{ + "node": true, + + "curly": true, + "latedef": true, + "quotmark": true, + "undef": true, + "unused": true, + "trailing": true +} diff --git a/node_modules/body-parser/node_modules/qs/.npmignore b/node_modules/body-parser/node_modules/qs/.npmignore new file mode 100644 index 0000000..7e1574d --- /dev/null +++ b/node_modules/body-parser/node_modules/qs/.npmignore @@ -0,0 +1,18 @@ +.idea +*.iml +npm-debug.log +dump.rdb +node_modules +results.tap +results.xml +npm-shrinkwrap.json +config.json +.DS_Store +*/.DS_Store +*/*/.DS_Store +._* +*/._* +*/*/._* +coverage.* +lib-cov +complexity.md diff --git a/node_modules/body-parser/node_modules/qs/.travis.yml b/node_modules/body-parser/node_modules/qs/.travis.yml new file mode 100644 index 0000000..c891dd0 --- /dev/null +++ b/node_modules/body-parser/node_modules/qs/.travis.yml @@ -0,0 +1,4 @@ +language: node_js + +node_js: + - 0.10 \ No newline at end of file diff --git a/node_modules/body-parser/node_modules/qs/CHANGELOG.md b/node_modules/body-parser/node_modules/qs/CHANGELOG.md new file mode 100644 index 0000000..2f20704 --- /dev/null +++ b/node_modules/body-parser/node_modules/qs/CHANGELOG.md @@ -0,0 +1,78 @@ + +## [**2.2.3**](https://github.com/hapijs/qs/issues?milestone=12&state=open) +- [**#37**](https://github.com/hapijs/qs/issues/37) parser discards first empty value in array +- [**#36**](https://github.com/hapijs/qs/issues/36) Update to lab 4.x + +## [**2.2.2**](https://github.com/hapijs/qs/issues?milestone=11&state=closed) +- [**#33**](https://github.com/hapijs/qs/issues/33) Error when plain object in a value +- [**#34**](https://github.com/hapijs/qs/issues/34) use Object.prototype.hasOwnProperty.call instead of obj.hasOwnProperty +- [**#24**](https://github.com/hapijs/qs/issues/24) Changelog? Semver? + +--- + + + +## [**2.2.2**](https://github.com/hapijs/qs/issues?milestone=11&state=closed) +- [**#33**](https://github.com/hapijs/qs/issues/33) Error when plain object in a value +- [**#34**](https://github.com/hapijs/qs/issues/34) use Object.prototype.hasOwnProperty.call instead of obj.hasOwnProperty +- [**#24**](https://github.com/hapijs/qs/issues/24) Changelog? Semver? + +--- + + + +## [**2.2.2**](https://github.com/hapijs/qs/issues?milestone=11&state=open) +- [**#34**](https://github.com/hapijs/qs/issues/34) use Object.prototype.hasOwnProperty.call instead of obj.hasOwnProperty +- [**#24**](https://github.com/hapijs/qs/issues/24) Changelog? Semver? + +--- + + +# 2014-08-28 +95 commits against 24 issues, over a month [`32edf33`](https://github.com/hapijs/qs/commit/32edf33)⎆[`b1e7b53`](https://github.com/hapijs/qs/commit/b1e7b53) + +## [**2.2.1**](https://github.com/hapijs/qs/issues?milestone=10&state=closed) +- [**#32**](https://github.com/hapijs/qs/issues/32) account for circular references properly, closes #31 +- [**#31**](https://github.com/hapijs/qs/issues/31) qs.parse stackoverflow on circular objects + +## [**2.2.0**](https://github.com/hapijs/qs/issues?milestone=9&state=closed) +- [**#30**](https://github.com/hapijs/qs/issues/30) Bug when merging non-object values into arrays +- [**#29**](https://github.com/hapijs/qs/issues/29) Don't call Utils.clone at the top of Utils.merge +- [**#26**](https://github.com/hapijs/qs/issues/26) Don't use Buffer global if it's not present +- [**#23**](https://github.com/hapijs/qs/issues/23) Ability to not limit parameters? + +## [**2.1.0**](https://github.com/hapijs/qs/issues?milestone=8&state=closed) +- [**#22**](https://github.com/hapijs/qs/issues/22) Enable using a RegExp as delimiter + +## [**2.0.0**](https://github.com/hapijs/qs/issues?milestone=7&state=closed) +- [**#20**](https://github.com/hapijs/qs/issues/20) Configurable parametersLimit +- [**#18**](https://github.com/hapijs/qs/issues/18) Why is there arrayLimit? +- [**#21**](https://github.com/hapijs/qs/issues/21) make all limits optional, for #18, for #20 + +## [**1.2.2**](https://github.com/hapijs/qs/issues?milestone=6&state=closed) +- [**#19**](https://github.com/hapijs/qs/issues/19) Don't overwrite null values + +## [**1.2.1**](https://github.com/hapijs/qs/issues?milestone=5&state=closed) +- [**#16**](https://github.com/hapijs/qs/issues/16) ignore non-string delimiters +- [**#15**](https://github.com/hapijs/qs/issues/15) Close code block + +## [**1.2.0**](https://github.com/hapijs/qs/issues?milestone=4&state=closed) +- [**#12**](https://github.com/hapijs/qs/issues/12) Add optional delim argument +- [**#13**](https://github.com/hapijs/qs/issues/13) fix #11: flattened keys in array are now correctly parsed + +## [**1.1.0**](https://github.com/hapijs/qs/issues?milestone=3&state=closed) +- [**#7**](https://github.com/hapijs/qs/issues/7) Empty values of a POST array disappear after being submitted +- [**#9**](https://github.com/hapijs/qs/issues/9) Should not omit equals signs (=) when value is null +- [**#6**](https://github.com/hapijs/qs/issues/6) Minor grammar fix in README + +## [**1.0.2**](https://github.com/hapijs/qs/issues?milestone=2&state=closed) +- [**#5**](https://github.com/hapijs/qs/issues/5) array holes incorrectly copied into object on large index + + +## Issues +- [**#25**](https://github.com/hapijs/qs/issues/25) Remove references to Buffer +- [**#11**](https://github.com/hapijs/qs/issues/11) Flattened keys in array does not parse correctly +- [**#8**](https://github.com/hapijs/qs/issues/8) Square brackets should be URI encoded +- [**#3**](https://github.com/hapijs/qs/issues/3) Update README.md +- [**#2**](https://github.com/hapijs/qs/issues/2) Add travis and rework package + diff --git a/node_modules/body-parser/node_modules/qs/CONTRIBUTING.md b/node_modules/body-parser/node_modules/qs/CONTRIBUTING.md new file mode 100644 index 0000000..8928361 --- /dev/null +++ b/node_modules/body-parser/node_modules/qs/CONTRIBUTING.md @@ -0,0 +1 @@ +Please view our [hapijs contributing guide](https://github.com/hapijs/hapi/blob/master/CONTRIBUTING.md). diff --git a/node_modules/body-parser/node_modules/qs/LICENSE b/node_modules/body-parser/node_modules/qs/LICENSE new file mode 100755 index 0000000..d456948 --- /dev/null +++ b/node_modules/body-parser/node_modules/qs/LICENSE @@ -0,0 +1,28 @@ +Copyright (c) 2014 Nathan LaFreniere and other contributors. +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + * Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + * The names of any contributors may not be used to endorse or promote + products derived from this software without specific prior written + permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND +ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS AND CONTRIBUTORS BE LIABLE FOR ANY +DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + + * * * + +The complete list of contributors can be found at: https://github.com/hapijs/qs/graphs/contributors diff --git a/node_modules/body-parser/node_modules/qs/Makefile b/node_modules/body-parser/node_modules/qs/Makefile new file mode 100644 index 0000000..600a700 --- /dev/null +++ b/node_modules/body-parser/node_modules/qs/Makefile @@ -0,0 +1,8 @@ +test: + @node node_modules/lab/bin/lab +test-cov: + @node node_modules/lab/bin/lab -t 100 +test-cov-html: + @node node_modules/lab/bin/lab -r html -o coverage.html + +.PHONY: test test-cov test-cov-html \ No newline at end of file diff --git a/node_modules/body-parser/node_modules/qs/README.md b/node_modules/body-parser/node_modules/qs/README.md new file mode 100755 index 0000000..a6f99ab --- /dev/null +++ b/node_modules/body-parser/node_modules/qs/README.md @@ -0,0 +1,213 @@ +# qs + +A querystring parsing and stringifying library with some added security. + +[![Build Status](https://secure.travis-ci.org/hapijs/qs.svg)](http://travis-ci.org/hapijs/qs) + +Lead Maintainer: [Nathan LaFreniere](https://github.com/nlf) + +The **qs** module was originally created and maintained by [TJ Holowaychuk](https://github.com/visionmedia/node-querystring). + +## Usage + +```javascript +var Qs = require('qs'); + +var obj = Qs.parse('a=c'); // { a: 'c' } +var str = Qs.stringify(obj); // 'a=c' +``` + +### Parsing Objects + +```javascript +Qs.parse(string, [options]); +``` + +**qs** allows you to create nested objects within your query strings, by surrounding the name of sub-keys with square brackets `[]`. +For example, the string `'foo[bar]=baz'` converts to: + +```javascript +{ + foo: { + bar: 'baz' + } +} +``` + +URI encoded strings work too: + +```javascript +Qs.parse('a%5Bb%5D=c'); +// { a: { b: 'c' } } +``` + +You can also nest your objects, like `'foo[bar][baz]=foobarbaz'`: + +```javascript +{ + foo: { + bar: { + baz: 'foobarbaz' + } + } +} +``` + +By default, when nesting objects **qs** will only parse up to 5 children deep. This means if you attempt to parse a string like +`'a[b][c][d][e][f][g][h][i]=j'` your resulting object will be: + +```javascript +{ + a: { + b: { + c: { + d: { + e: { + f: { + '[g][h][i]': 'j' + } + } + } + } + } + } +} +``` + +This depth can be overridden by passing a `depth` option to `Qs.parse(string, [options])`: + +```javascript +Qs.parse('a[b][c][d][e][f][g][h][i]=j', { depth: 1 }); +// { a: { b: { '[c][d][e][f][g][h][i]': 'j' } } } +``` + +The depth limit helps mitigate abuse when **qs** is used to parse user input, and it is recommended to keep it a reasonably small number. + +For similar reasons, by default **qs** will only parse up to 1000 parameters. This can be overridden by passing a `parameterLimit` option: + +```javascript +Qs.parse('a=b&c=d', { parameterLimit: 1 }); +// { a: 'b' } +``` + +An optional delimiter can also be passed: + +```javascript +Qs.parse('a=b;c=d', { delimiter: ';' }); +// { a: 'b', c: 'd' } +``` + +Delimiters can be a regular expression too: + +```javascript +Qs.parse('a=b;c=d,e=f', { delimiter: /[;,]/ }); +// { a: 'b', c: 'd', e: 'f' } +``` + +### Parsing Arrays + +**qs** can also parse arrays using a similar `[]` notation: + +```javascript +Qs.parse('a[]=b&a[]=c'); +// { a: ['b', 'c'] } +``` + +You may specify an index as well: + +```javascript +Qs.parse('a[1]=c&a[0]=b'); +// { a: ['b', 'c'] } +``` + +Note that the only difference between an index in an array and a key in an object is that the value between the brackets must be a number +to create an array. When creating arrays with specific indices, **qs** will compact a sparse array to only the existing values preserving +their order: + +```javascript +Qs.parse('a[1]=b&a[15]=c'); +// { a: ['b', 'c'] } +``` + +Note that an empty string is also a value, and will be preserved: + +```javascript +Qs.parse('a[]=&a[]=b'); +// { a: ['', 'b'] } +Qs.parse('a[0]=b&a[1]=&a[2]=c'); +// { a: ['b', '', 'c'] } +``` + +**qs** will also limit specifying indices in an array to a maximum index of `20`. Any array members with an index of greater than `20` will +instead be converted to an object with the index as the key: + +```javascript +Qs.parse('a[100]=b'); +// { a: { '100': 'b' } } +``` + +This limit can be overridden by passing an `arrayLimit` option: + +```javascript +Qs.parse('a[1]=b', { arrayLimit: 0 }); +// { a: { '1': 'b' } } +``` + +If you mix notations, **qs** will merge the two items into an object: + +```javascript +Qs.parse('a[0]=b&a[b]=c'); +// { a: { '0': 'b', b: 'c' } } +``` + +You can also create arrays of objects: + +```javascript +Qs.parse('a[][b]=c'); +// { a: [{ b: 'c' }] } +``` + +### Stringifying + +```javascript +Qs.stringify(object, [options]); +``` + +When stringifying, **qs** always URI encodes output. Objects are stringified as you would expect: + +```javascript +Qs.stringify({ a: 'b' }); +// 'a=b' +Qs.stringify({ a: { b: 'c' } }); +// 'a%5Bb%5D=c' +``` + +Examples beyond this point will be shown as though the output is not URI encoded for clarity. Please note that the return values in these cases *will* be URI encoded during real usage. + +When arrays are stringified, they are always given explicit indices: + +```javascript +Qs.stringify({ a: ['b', 'c', 'd'] }); +// 'a[0]=b&a[1]=c&a[2]=d' +``` + +Empty strings and null values will omit the value, but the equals sign (=) remains in place: + +```javascript +Qs.stringify({ a: '' }); +// 'a=' +``` + +Properties that are set to `undefined` will be omitted entirely: + +```javascript +Qs.stringify({ a: null, b: undefined }); +// 'a=' +``` + +The delimiter may be overridden with stringify as well: + +```javascript +Qs.stringify({ a: 'b', c: 'd' }, { delimiter: ';' }); +// 'a=b;c=d' +``` diff --git a/node_modules/body-parser/node_modules/qs/index.js b/node_modules/body-parser/node_modules/qs/index.js new file mode 100644 index 0000000..bb0a047 --- /dev/null +++ b/node_modules/body-parser/node_modules/qs/index.js @@ -0,0 +1 @@ +module.exports = require('./lib'); diff --git a/node_modules/body-parser/node_modules/qs/lib/index.js b/node_modules/body-parser/node_modules/qs/lib/index.js new file mode 100755 index 0000000..0e09493 --- /dev/null +++ b/node_modules/body-parser/node_modules/qs/lib/index.js @@ -0,0 +1,15 @@ +// Load modules + +var Stringify = require('./stringify'); +var Parse = require('./parse'); + + +// Declare internals + +var internals = {}; + + +module.exports = { + stringify: Stringify, + parse: Parse +}; diff --git a/node_modules/body-parser/node_modules/qs/lib/parse.js b/node_modules/body-parser/node_modules/qs/lib/parse.js new file mode 100755 index 0000000..f2e0a0d --- /dev/null +++ b/node_modules/body-parser/node_modules/qs/lib/parse.js @@ -0,0 +1,154 @@ +// Load modules + +var Utils = require('./utils'); + + +// Declare internals + +var internals = { + delimiter: '&', + depth: 5, + arrayLimit: 20, + parameterLimit: 1000 +}; + + +internals.parseValues = function (str, options) { + + var obj = {}; + var parts = str.split(options.delimiter, options.parameterLimit === Infinity ? undefined : options.parameterLimit); + + for (var i = 0, il = parts.length; i < il; ++i) { + var part = parts[i]; + var pos = part.indexOf(']=') === -1 ? part.indexOf('=') : part.indexOf(']=') + 1; + + if (pos === -1) { + obj[Utils.decode(part)] = ''; + } + else { + var key = Utils.decode(part.slice(0, pos)); + var val = Utils.decode(part.slice(pos + 1)); + + if (!obj.hasOwnProperty(key)) { + obj[key] = val; + } + else { + obj[key] = [].concat(obj[key]).concat(val); + } + } + } + + return obj; +}; + + +internals.parseObject = function (chain, val, options) { + + if (!chain.length) { + return val; + } + + var root = chain.shift(); + + var obj = {}; + if (root === '[]') { + obj = []; + obj = obj.concat(internals.parseObject(chain, val, options)); + } + else { + var cleanRoot = root[0] === '[' && root[root.length - 1] === ']' ? root.slice(1, root.length - 1) : root; + var index = parseInt(cleanRoot, 10); + if (!isNaN(index) && + root !== cleanRoot && + index <= options.arrayLimit) { + + obj = []; + obj[index] = internals.parseObject(chain, val, options); + } + else { + obj[cleanRoot] = internals.parseObject(chain, val, options); + } + } + + return obj; +}; + + +internals.parseKeys = function (key, val, options) { + + if (!key) { + return; + } + + // The regex chunks + + var parent = /^([^\[\]]*)/; + var child = /(\[[^\[\]]*\])/g; + + // Get the parent + + var segment = parent.exec(key); + + // Don't allow them to overwrite object prototype properties + + if (Object.prototype.hasOwnProperty(segment[1])) { + return; + } + + // Stash the parent if it exists + + var keys = []; + if (segment[1]) { + keys.push(segment[1]); + } + + // Loop through children appending to the array until we hit depth + + var i = 0; + while ((segment = child.exec(key)) !== null && i < options.depth) { + + ++i; + if (!Object.prototype.hasOwnProperty(segment[1].replace(/\[|\]/g, ''))) { + keys.push(segment[1]); + } + } + + // If there's a remainder, just add whatever is left + + if (segment) { + keys.push('[' + key.slice(segment.index) + ']'); + } + + return internals.parseObject(keys, val, options); +}; + + +module.exports = function (str, options) { + + if (str === '' || + str === null || + typeof str === 'undefined') { + + return {}; + } + + 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.parameterLimit = typeof options.parameterLimit === 'number' ? options.parameterLimit : internals.parameterLimit; + + var tempObj = typeof str === 'string' ? internals.parseValues(str, options) : str; + var obj = {}; + + // Iterate over the keys and setup the new object + + var keys = Object.keys(tempObj); + 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); + } + + return Utils.compact(obj); +}; diff --git a/node_modules/body-parser/node_modules/qs/lib/stringify.js b/node_modules/body-parser/node_modules/qs/lib/stringify.js new file mode 100755 index 0000000..582577a --- /dev/null +++ b/node_modules/body-parser/node_modules/qs/lib/stringify.js @@ -0,0 +1,58 @@ +// Load modules + +var Utils = require('./utils'); + + +// Declare internals + +var internals = { + delimiter: '&' +}; + + +internals.stringify = function (obj, prefix) { + + if (Utils.isBuffer(obj)) { + obj = obj.toString(); + } + else if (obj instanceof Date) { + obj = obj.toISOString(); + } + else if (obj === null) { + obj = ''; + } + + if (typeof obj === 'string' || + typeof obj === 'number' || + typeof obj === 'boolean') { + + return [encodeURIComponent(prefix) + '=' + encodeURIComponent(obj)]; + } + + var values = []; + + for (var key in obj) { + if (obj.hasOwnProperty(key)) { + values = values.concat(internals.stringify(obj[key], prefix + '[' + key + ']')); + } + } + + return values; +}; + + +module.exports = function (obj, options) { + + options = options || {}; + var delimiter = typeof options.delimiter === 'undefined' ? internals.delimiter : options.delimiter; + + var keys = []; + + for (var key in obj) { + if (obj.hasOwnProperty(key)) { + keys = keys.concat(internals.stringify(obj[key], key)); + } + } + + return keys.join(delimiter); +}; diff --git a/node_modules/body-parser/node_modules/qs/lib/utils.js b/node_modules/body-parser/node_modules/qs/lib/utils.js new file mode 100755 index 0000000..c0b915d --- /dev/null +++ b/node_modules/body-parser/node_modules/qs/lib/utils.js @@ -0,0 +1,139 @@ +// Load modules + + +// Declare internals + +var internals = {}; + + +exports.arrayToObject = function (source) { + + var obj = {}; + for (var i = 0, il = source.length; i < il; ++i) { + if (typeof source[i] !== 'undefined') { + + obj[i] = source[i]; + } + } + + return obj; +}; + + +exports.merge = function (target, source) { + + if (!source) { + return target; + } + + if (Array.isArray(source)) { + for (var i = 0, il = source.length; i < il; ++i) { + if (typeof source[i] !== 'undefined') { + if (typeof target[i] === 'object') { + target[i] = exports.merge(target[i], source[i]); + } + else { + target[i] = source[i]; + } + } + } + + return target; + } + + if (Array.isArray(target)) { + if (typeof source !== 'object') { + target.push(source); + return target; + } + else { + target = exports.arrayToObject(target); + } + } + + var keys = Object.keys(source); + for (var k = 0, kl = keys.length; k < kl; ++k) { + var key = keys[k]; + var value = source[key]; + + if (value && + typeof value === 'object') { + + if (!target[key]) { + target[key] = value; + } + else { + target[key] = exports.merge(target[key], value); + } + } + else { + target[key] = value; + } + } + + return target; +}; + + +exports.decode = function (str) { + + try { + return decodeURIComponent(str.replace(/\+/g, ' ')); + } catch (e) { + return str; + } +}; + + +exports.compact = function (obj, refs) { + + if (typeof obj !== 'object' || + obj === null) { + + return obj; + } + + refs = refs || []; + var lookup = refs.indexOf(obj); + if (lookup !== -1) { + return refs[lookup]; + } + + refs.push(obj); + + if (Array.isArray(obj)) { + var compacted = []; + + for (var i = 0, l = obj.length; i < l; ++i) { + if (typeof obj[i] !== 'undefined') { + compacted.push(obj[i]); + } + } + + return compacted; + } + + var keys = Object.keys(obj); + for (var i = 0, il = keys.length; i < il; ++i) { + var key = keys[i]; + obj[key] = exports.compact(obj[key], refs); + } + + return obj; +}; + + +exports.isRegExp = function (obj) { + return Object.prototype.toString.call(obj) === '[object RegExp]'; +}; + + +exports.isBuffer = function (obj) { + + if (typeof Buffer !== 'undefined') { + return Buffer.isBuffer(obj); + } + else { + return false; + } +}; diff --git a/node_modules/body-parser/node_modules/qs/package.json b/node_modules/body-parser/node_modules/qs/package.json new file mode 100755 index 0000000..488cb37 --- /dev/null +++ b/node_modules/body-parser/node_modules/qs/package.json @@ -0,0 +1,60 @@ +{ + "name": "qs", + "version": "2.2.3", + "description": "A querystring parser that supports nesting and arrays, with a depth limit", + "homepage": "https://github.com/hapijs/qs", + "main": "index.js", + "dependencies": {}, + "devDependencies": { + "lab": "4.x.x" + }, + "scripts": { + "test": "make test-cov" + }, + "repository": { + "type": "git", + "url": "https://github.com/hapijs/qs.git" + }, + "keywords": [ + "querystring", + "qs" + ], + "author": { + "name": "Nathan LaFreniere", + "email": "quitlahok@gmail.com" + }, + "licenses": [ + { + "type": "BSD", + "url": "http://github.com/hapijs/qs/raw/master/LICENSE" + } + ], + "gitHead": "904528124a6eb879ebc5197376e9613069414f67", + "bugs": { + "url": "https://github.com/hapijs/qs/issues" + }, + "_id": "qs@2.2.3", + "_shasum": "6139c1f47960eff5655e56aab0ef9f6dd16d4eeb", + "_from": "qs@2.2.3", + "_npmVersion": "1.4.23", + "_npmUser": { + "name": "nlf", + "email": "quitlahok@gmail.com" + }, + "maintainers": [ + { + "name": "nlf", + "email": "quitlahok@gmail.com" + }, + { + "name": "hueniverse", + "email": "eran@hueniverse.com" + } + ], + "dist": { + "shasum": "6139c1f47960eff5655e56aab0ef9f6dd16d4eeb", + "tarball": "http://registry.npmjs.org/qs/-/qs-2.2.3.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/qs/-/qs-2.2.3.tgz" +} diff --git a/node_modules/body-parser/node_modules/qs/test/parse.js b/node_modules/body-parser/node_modules/qs/test/parse.js new file mode 100755 index 0000000..15a4888 --- /dev/null +++ b/node_modules/body-parser/node_modules/qs/test/parse.js @@ -0,0 +1,385 @@ +// Load modules + +var Lab = require('lab'); +var Qs = require('../'); + + +// Declare internals + +var internals = {}; + + +// Test shortcuts + +var lab = exports.lab = Lab.script(); +var expect = Lab.expect; +var before = lab.before; +var after = lab.after; +var describe = lab.experiment; +var it = lab.test; + + +describe('#parse', function () { + + it('parses a simple string', function (done) { + + 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')).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('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' + }); + done(); + }); + + it('parses a single nested string', function (done) { + + 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' } } }); + 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' } } } } } } }); + 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' } } }); + 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'] }); + done(); + }); + + it('parses an explicit array', function (done) { + + 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 nested array', function (done) { + + 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'] }); + 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'] }); + expect(Qs.parse('a[21]=a')).to.deep.equal({ a: { '21': 'a' } }); + done(); + }); + + it('supports encoded = signs', function (done) { + + 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' } }); + 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"]' }); + expect(Qs.parse('operators=[">=", "<="]')).to.deep.equal({ operators: '[">=", "<="]' }); + done(); + }); + + it('allows empty values', function (done) { + + 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' } }); + 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('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' } }); + done(); + }); + + it('supports malformed uri characters', function (done) { + + 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' }); + done(); + }); + + it('cannot override prototypes', function (done) { + + var obj = Qs.parse('toString=bad&bad[toString]=bad&constructor=bad'); + expect(typeof obj.toString).to.equal('function'); + expect(typeof obj.bad.toString).to.equal('function'); + expect(typeof obj.constructor).to.equal('function'); + done(); + }); + + it('cannot access Object prototype', function (done) { + + Qs.parse('constructor[prototype][bad]=bad'); + Qs.parse('bad[constructor][prototype][bad]=bad'); + expect(typeof Object.prototype.bad).to.equal('undefined'); + done(); + }); + + it('parses arrays of objects', function (done) { + + 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'] }); + expect(Qs.parse('a[0]=b&a[1]=&a[2]=c&a[19]=')).to.deep.equal({ a: ['b', '', 'c', ''] }); + 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'] }); + done(); + }); + + it('parses semi-parsed strings', function (done) { + + 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 }); + done(); + }); + + it('continues parsing when no parent is found', function (done) { + + expect(Qs.parse('[]&a=b')).to.deep.equal({ '0': '', a: 'b' }); + expect(Qs.parse('[foo]=bar')).to.deep.equal({ foo: 'bar' }); + done(); + }); + + it('does not error when parsing a very long array', function (done) { + + var str = 'a[]=a'; + while (Buffer.byteLength(str) < 128 * 1024) { + str += '&' + str; + } + + expect(function () { + + Qs.parse(str); + }).to.not.throw(); + + done(); + }); + + it('should not throw when a native prototype has an enumerable property', { parallel: false }, function (done) { + + 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' }); + expect(Qs.parse.bind(null, 'a[][b]=c')).to.not.throw(); + expect(Qs.parse('a[][b]=c')).to.deep.equal({ a: [{ b: 'c' }] }); + delete Object.prototype.crash; + delete Array.prototype.crash; + done(); + }); + + 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' }); + 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' }); + 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' }); + done(); + }); + + it('allows overriding parameter limit', function (done) { + + 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' }); + done(); + }); + + it('allows overriding array limit', function (done) { + + expect(Qs.parse('a[0]=b&a[1]=c', { arrayLimit: 0 })).to.deep.equal({ a: { '0': 'b', '1': 'c' } }); + done(); + }); + + it('parses an object', function (done) { + + var input = { + "user[name]": {"pop[bob]": 3}, + "user[email]": null + }; + + var expected = { + "user": { + "name": {"pop[bob]": 3}, + "email": null + } + }; + + var result = Qs.parse(input); + + 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[email]": null + }; + + var expected = { + "user": { + "name": {"pop[bob]": { "test": 3 }}, + "email": null + } + }; + + var result = Qs.parse(input); + + expect(result).to.deep.equal(expected); + done(); + }); + + it('does not blow up when Buffer global is missing', function (done) { + + var tempBuffer = global.Buffer; + delete global.Buffer; + expect(Qs.parse('a=b&c=d')).to.deep.equal({ a: 'b', c: 'd' }); + global.Buffer = tempBuffer; + done(); + }); + + it('does not crash when using invalid dot notation', function (done) { + + expect(Qs.parse('roomInfoList[0].childrenAges[0]=15&roomInfoList[0].numberOfAdults=2')).to.deep.equal({ roomInfoList: [['15', '2']] }); + done(); + }); + + it('does not crash when parsing circular references', function (done) { + + var a = {}; + a.b = a; + + var parsed; + + expect(function () { + + parsed = Qs.parse({ 'foo[bar]': 'baz', 'foo[baz]': a }); + }).to.not.throw(Error); + + expect(parsed).to.have.key('foo'); + expect(parsed.foo).to.have.keys('bar', 'baz'); + expect(parsed.foo.bar).to.equal('baz'); + expect(parsed.foo.baz).to.deep.equal(a); + done(); + }); + + it('parses plain objects correctly', function (done) { + + var a = Object.create(null); + a.b = 'c'; + + expect(Qs.parse(a)).to.deep.equal({ b: 'c' }); + expect(Qs.parse({ a: a })).to.deep.equal({ a: { b: 'c' } }); + done(); + }); + + it('parses dates correctly', function (done) { + + var now = new Date(); + 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 }); + done(); + }); +}); diff --git a/node_modules/body-parser/node_modules/qs/test/stringify.js b/node_modules/body-parser/node_modules/qs/test/stringify.js new file mode 100755 index 0000000..b96b52b --- /dev/null +++ b/node_modules/body-parser/node_modules/qs/test/stringify.js @@ -0,0 +1,139 @@ +// Load modules + +var Lab = require('lab'); +var Qs = require('../'); + + +// Declare internals + +var internals = {}; + + +// Test shortcuts + +var lab = exports.lab = Lab.script(); +var expect = Lab.expect; +var before = lab.before; +var after = lab.after; +var describe = lab.experiment; +var it = lab.test; + + +describe('#stringify', function () { + + it('stringifies a querystring object', function (done) { + + expect(Qs.stringify({ a: 'b' })).to.equal('a=b'); + expect(Qs.stringify({ a: 1 })).to.equal('a=1'); + expect(Qs.stringify({ a: 1, b: 2 })).to.equal('a=1&b=2'); + done(); + }); + + it('stringifies a nested object', function (done) { + + expect(Qs.stringify({ a: { b: 'c' } })).to.equal('a%5Bb%5D=c'); + expect(Qs.stringify({ a: { b: { c: { d: 'e' } } } })).to.equal('a%5Bb%5D%5Bc%5D%5Bd%5D=e'); + done(); + }); + + it('stringifies an array value', function (done) { + + expect(Qs.stringify({ a: ['b', 'c', 'd'] })).to.equal('a%5B0%5D=b&a%5B1%5D=c&a%5B2%5D=d'); + done(); + }); + + it('stringifies a nested array value', function (done) { + + expect(Qs.stringify({ a: { b: ['c', 'd'] } })).to.equal('a%5Bb%5D%5B0%5D=c&a%5Bb%5D%5B1%5D=d'); + done(); + }); + + it('stringifies an object inside an array', function (done) { + + expect(Qs.stringify({ a: [{ b: 'c' }] })).to.equal('a%5B0%5D%5Bb%5D=c'); + expect(Qs.stringify({ a: [{ b: { c: [1] } }] })).to.equal('a%5B0%5D%5Bb%5D%5Bc%5D%5B0%5D=1'); + done(); + }); + + it('stringifies a complicated object', function (done) { + + expect(Qs.stringify({ a: { b: 'c', d: 'e' } })).to.equal('a%5Bb%5D=c&a%5Bd%5D=e'); + done(); + }); + + it('stringifies an empty value', function (done) { + + expect(Qs.stringify({ a: '' })).to.equal('a='); + expect(Qs.stringify({ a: '', b: '' })).to.equal('a=&b='); + expect(Qs.stringify({ a: null })).to.equal('a='); + expect(Qs.stringify({ a: { b: null } })).to.equal('a%5Bb%5D='); + done(); + }); + + it('drops keys with a value of undefined', function (done) { + + expect(Qs.stringify({ a: undefined })).to.equal(''); + expect(Qs.stringify({ a: { b: undefined, c: null } })).to.equal('a%5Bc%5D='); + done(); + }); + + it('url encodes values', function (done) { + + expect(Qs.stringify({ a: 'b c' })).to.equal('a=b%20c'); + done(); + }); + + it('stringifies a date', function (done) { + + var now = new Date(); + var str = 'a=' + encodeURIComponent(now.toISOString()); + expect(Qs.stringify({ a: now })).to.equal(str); + done(); + }); + + it('stringifies the weird object from qs', function (done) { + + expect(Qs.stringify({ 'my weird field': 'q1!2"\'w$5&7/z8)?' })).to.equal('my%20weird%20field=q1!2%22\'w%245%267%2Fz8)%3F'); + done(); + }); + + 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: 'c' } })).to.equal('a%5Bb%5D=c'); + delete Object.prototype.crash; + done(); + }); + + it('stringifies boolean values', function (done) { + + expect(Qs.stringify({ a: true })).to.equal('a=true'); + expect(Qs.stringify({ a: { b: true } })).to.equal('a%5Bb%5D=true'); + expect(Qs.stringify({ b: false })).to.equal('b=false'); + expect(Qs.stringify({ b: { c: false } })).to.equal('b%5Bc%5D=false'); + done(); + }); + + it('stringifies buffer values', function (done) { + + expect(Qs.stringify({ a: new Buffer('test') })).to.equal('a=test'); + expect(Qs.stringify({ a: { b: new Buffer('test') } })).to.equal('a%5Bb%5D=test'); + done(); + }); + + it('stringifies an object using an alternative delimiter', function (done) { + + expect(Qs.stringify({ a: 'b', c: 'd' }, { delimiter: ';' })).to.equal('a=b;c=d'); + done(); + }); + + it('doesn\'t blow up when Buffer global is missing', function (done) { + + var tempBuffer = global.Buffer; + delete global.Buffer; + expect(Qs.stringify({ a: 'b', c: 'd' })).to.equal('a=b&c=d'); + global.Buffer = tempBuffer; + done(); + }); +}); diff --git a/node_modules/body-parser/node_modules/raw-body/.npmignore b/node_modules/body-parser/node_modules/raw-body/.npmignore new file mode 100644 index 0000000..cd39b77 --- /dev/null +++ b/node_modules/body-parser/node_modules/raw-body/.npmignore @@ -0,0 +1,3 @@ +coverage/ +test/ +.travis.yml diff --git a/node_modules/body-parser/node_modules/raw-body/HISTORY.md b/node_modules/body-parser/node_modules/raw-body/HISTORY.md new file mode 100644 index 0000000..7772dcc --- /dev/null +++ b/node_modules/body-parser/node_modules/raw-body/HISTORY.md @@ -0,0 +1,114 @@ +1.3.0 / 2014-07-20 +================== + + * Fully unpipe the stream on error + - Fixes `Cannot switch to old mode now` error on Node.js 0.10+ + +1.2.3 / 2014-07-20 +================== + + * deps: iconv-lite@0.4.4 + - Added encoding UTF-7 + +1.2.2 / 2014-06-19 +================== + + * Send invalid encoding error to callback + +1.2.1 / 2014-06-15 +================== + + * deps: iconv-lite@0.4.3 + - Added encodings UTF-16BE and UTF-16 with BOM + +1.2.0 / 2014-06-13 +================== + + * Passing string as `options` interpreted as encoding + * Support all encodings from `iconv-lite` + +1.1.7 / 2014-06-12 +================== + + * use `string_decoder` module from npm + +1.1.6 / 2014-05-27 +================== + + * check encoding for old streams1 + * support node.js < 0.10.6 + +1.1.5 / 2014-05-14 +================== + + * bump bytes + +1.1.4 / 2014-04-19 +================== + + * allow true as an option + * bump bytes + +1.1.3 / 2014-03-02 +================== + + * fix case when length=null + +1.1.2 / 2013-12-01 +================== + + * be less strict on state.encoding check + +1.1.1 / 2013-11-27 +================== + + * add engines + +1.1.0 / 2013-11-27 +================== + + * add err.statusCode and err.type + * allow for encoding option to be true + * pause the stream instead of dumping on error + * throw if the stream's encoding is set + +1.0.1 / 2013-11-19 +================== + + * dont support streams1, throw if dev set encoding + +1.0.0 / 2013-11-17 +================== + + * rename `expected` option to `length` + +0.2.0 / 2013-11-15 +================== + + * republish + +0.1.1 / 2013-11-15 +================== + + * use bytes + +0.1.0 / 2013-11-11 +================== + + * generator support + +0.0.3 / 2013-10-10 +================== + + * update repo + +0.0.2 / 2013-09-14 +================== + + * dump stream on bad headers + * listen to events after defining received and buffers + +0.0.1 / 2013-09-14 +================== + + * Initial release diff --git a/node_modules/body-parser/node_modules/raw-body/README.md b/node_modules/body-parser/node_modules/raw-body/README.md new file mode 100644 index 0000000..e95d000 --- /dev/null +++ b/node_modules/body-parser/node_modules/raw-body/README.md @@ -0,0 +1,103 @@ +# raw-body + +[![NPM version](https://badge.fury.io/js/raw-body.svg)](http://badge.fury.io/js/raw-body) +[![Build Status](https://travis-ci.org/stream-utils/raw-body.svg?branch=master)](https://travis-ci.org/stream-utils/raw-body) +[![Coverage Status](https://img.shields.io/coveralls/stream-utils/raw-body.svg?branch=master)](https://coveralls.io/r/stream-utils/raw-body) + +Gets the entire buffer of a stream either as a `Buffer` or a string. +Validates the stream's length against an expected length and maximum limit. +Ideal for parsing request bodies. + +## API + +```js +var getRawBody = require('raw-body') +var typer = require('media-typer') + +app.use(function (req, res, next) { + getRawBody(req, { + length: req.headers['content-length'], + limit: '1mb', + encoding: typer.parse(req.headers['content-type']).parameters.charset + }, function (err, string) { + if (err) + return next(err) + + req.text = string + next() + }) +}) +``` + +or in a Koa generator: + +```js +app.use(function* (next) { + var string = yield getRawBody(this.req, { + length: this.length, + limit: '1mb', + encoding: this.charset + }) +}) +``` + +### getRawBody(stream, [options], [callback]) + +Returns a thunk for yielding with generators. + +Options: + +- `length` - The length length of the stream. + If the contents of the stream do not add up to this length, + an `400` error code is returned. +- `limit` - The byte limit of the body. + If the body ends up being larger than this limit, + a `413` error code is returned. +- `encoding` - The requested encoding. + By default, a `Buffer` instance will be returned. + Most likely, you want `utf8`. + You can use any type of encoding supported by [iconv-lite](https://www.npmjs.org/package/iconv-lite#readme). + +You can also pass a string in place of options to just specify the encoding. + +`callback(err, res)`: + +- `err` - the following attributes will be defined if applicable: + + - `limit` - the limit in bytes + - `length` and `expected` - the expected length of the stream + - `received` - the received bytes + - `encoding` - the invalid encoding + - `status` and `statusCode` - the corresponding status code for the error + - `type` - either `entity.too.large`, `request.size.invalid`, `stream.encoding.set`, or `encoding.unsupported` + +- `res` - the result, either as a `String` if an encoding was set or a `Buffer` otherwise. + +If an error occurs, the stream will be paused, everything unpiped, +and you are responsible for correctly disposing the stream. +For HTTP requests, no handling is required if you send a response. +For streams that use file descriptors, you should `stream.destroy()` or `stream.close()` to prevent leaks. + +## License + +The MIT License (MIT) + +Copyright (c) 2013 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/node_modules/body-parser/node_modules/raw-body/index.js b/node_modules/body-parser/node_modules/raw-body/index.js new file mode 100644 index 0000000..c430d23 --- /dev/null +++ b/node_modules/body-parser/node_modules/raw-body/index.js @@ -0,0 +1,224 @@ +var bytes = require('bytes') +var iconv = require('iconv-lite') + +module.exports = function (stream, options, done) { + if (options === true || typeof options === 'string') { + // short cut for encoding + options = { + encoding: options + } + } + + options = options || {} + + if (typeof options === 'function') { + done = options + options = {} + } + + // get encoding + var encoding = options.encoding !== true + ? options.encoding + : 'utf-8' + + // convert the limit to an integer + var limit = null + if (typeof options.limit === 'number') + limit = options.limit + if (typeof options.limit === 'string') + limit = bytes(options.limit) + + // convert the expected length to an integer + var length = null + if (options.length != null && !isNaN(options.length)) + length = parseInt(options.length, 10) + + // check the length and limit options. + // note: we intentionally leave the stream paused, + // so users should handle the stream themselves. + if (limit !== null && length !== null && length > limit) { + var err = makeError('request entity too large', 'entity.too.large') + err.status = err.statusCode = 413 + err.length = err.expected = length + err.limit = limit + cleanup() + halt(stream) + process.nextTick(function () { + done(err) + }) + return defer + } + + // streams1: assert request encoding is buffer. + // streams2+: assert the stream encoding is buffer. + // stream._decoder: streams1 + // state.encoding: streams2 + // state.decoder: streams2, specifically < 0.10.6 + var state = stream._readableState + if (stream._decoder || (state && (state.encoding || state.decoder))) { + // developer error + var err = makeError('stream encoding should not be set', + 'stream.encoding.set') + err.status = err.statusCode = 500 + cleanup() + halt(stream) + process.nextTick(function () { + done(err) + }) + return defer + } + + var received = 0 + var decoder + + try { + decoder = getDecoder(encoding) + } catch (err) { + cleanup() + halt(stream) + process.nextTick(function () { + done(err) + }) + return defer + } + + var buffer = decoder + ? '' + : [] + + stream.on('data', onData) + stream.once('end', onEnd) + stream.once('error', onEnd) + stream.once('close', cleanup) + + return defer + + // yieldable support + function defer(fn) { + done = fn + } + + function onData(chunk) { + received += chunk.length + decoder + ? buffer += decoder.write(chunk) + : buffer.push(chunk) + + if (limit !== null && received > limit) { + var err = makeError('request entity too large', 'entity.too.large') + err.status = err.statusCode = 413 + err.received = received + err.limit = limit + cleanup() + halt(stream) + done(err) + } + } + + function onEnd(err) { + if (err) { + cleanup() + halt(stream) + done(err) + } else if (length !== null && received !== length) { + err = makeError('request size did not match content length', + 'request.size.invalid') + err.status = err.statusCode = 400 + err.received = received + err.length = err.expected = length + cleanup() + done(err) + } else { + var string = decoder + ? buffer + (decoder.end() || '') + : Buffer.concat(buffer) + cleanup() + done(null, string) + } + } + + function cleanup() { + received = buffer = null + + stream.removeListener('data', onData) + stream.removeListener('end', onEnd) + stream.removeListener('error', onEnd) + stream.removeListener('close', cleanup) + } +} + +function getDecoder(encoding) { + if (!encoding) return null + + try { + return iconv.getCodec(encoding).decoder() + } catch (e) { + var err = makeError('specified encoding unsupported', 'encoding.unsupported') + err.status = err.statusCode = 415 + err.encoding = encoding + throw err + } +} + +/** + * Halt a stream. + * + * @param {Object} stream + * @api private + */ + +function halt(stream) { + // unpipe everything from the stream + unpipe(stream) + + // pause stream + if (typeof stream.pause === 'function') { + stream.pause() + } +} + +// to create serializable errors you must re-set message so +// that it is enumerable and you must re configure the type +// property so that is writable and enumerable +function makeError(message, type) { + var error = new Error() + error.message = message + Object.defineProperty(error, 'type', { + value: type, + enumerable: true, + writable: true, + configurable: true + }) + return error +} + +/** + * Unpipe everything from a stream. + * + * @param {Object} stream + * @api private + */ + +/* istanbul ignore next: implementation differs between versions */ +function unpipe(stream) { + if (typeof stream.unpipe === 'function') { + // new-style + stream.unpipe() + return + } + + // Node.js 0.8 hack + var listener + var listeners = stream.listeners('close') + + for (var i = 0; i < listeners.length; i++) { + listener = listeners[i] + + if (listener.name !== 'cleanup' && listener.name !== 'onclose') { + continue + } + + // invoke the listener + listener.call(stream) + } +} diff --git a/node_modules/body-parser/node_modules/raw-body/package.json b/node_modules/body-parser/node_modules/raw-body/package.json new file mode 100644 index 0000000..51c1eb8 --- /dev/null +++ b/node_modules/body-parser/node_modules/raw-body/package.json @@ -0,0 +1,71 @@ +{ + "name": "raw-body", + "description": "Get and validate the raw body of a readable stream.", + "version": "1.3.0", + "author": { + "name": "Jonathan Ong", + "email": "me@jongleberry.com", + "url": "http://jongleberry.com" + }, + "contributors": [ + { + "name": "Douglas Christopher Wilson", + "email": "doug@somethingdoug.com" + }, + { + "name": "Raynos", + "email": "raynos2@gmail.com" + } + ], + "license": "MIT", + "repository": { + "type": "git", + "url": "git://github.com/stream-utils/raw-body" + }, + "dependencies": { + "bytes": "1", + "iconv-lite": "0.4.4" + }, + "devDependencies": { + "istanbul": "0.3.0", + "mocha": "~1.20.1", + "readable-stream": "~1.0.17", + "through2": "~0.5.1" + }, + "engines": { + "node": ">= 0.8.0" + }, + "scripts": { + "test": "mocha --reporter spec --bail test/", + "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot test/", + "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec test/" + }, + "bugs": { + "url": "https://github.com/stream-utils/raw-body/issues" + }, + "homepage": "https://github.com/stream-utils/raw-body", + "_id": "raw-body@1.3.0", + "dist": { + "shasum": "978230a156a5548f42eef14de22d0f4f610083d1", + "tarball": "http://registry.npmjs.org/raw-body/-/raw-body-1.3.0.tgz" + }, + "_from": "raw-body@1.3.0", + "_npmVersion": "1.4.3", + "_npmUser": { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + "maintainers": [ + { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + }, + { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + } + ], + "directories": {}, + "_shasum": "978230a156a5548f42eef14de22d0f4f610083d1", + "_resolved": "https://registry.npmjs.org/raw-body/-/raw-body-1.3.0.tgz" +} diff --git a/node_modules/body-parser/node_modules/type-is/HISTORY.md b/node_modules/body-parser/node_modules/type-is/HISTORY.md new file mode 100644 index 0000000..c828c45 --- /dev/null +++ b/node_modules/body-parser/node_modules/type-is/HISTORY.md @@ -0,0 +1,71 @@ +1.5.1 / 2014-09-07 +================== + + * Support Node.js 0.6 + * deps: media-typer@0.3.0 + * deps: mime-types@~2.0.1 + - Support Node.js 0.6 + +1.5.0 / 2014-09-05 +================== + + * fix `hasbody` to be true for `content-length: 0` + +1.4.0 / 2014-09-02 +================== + + * update mime-types + +1.3.2 / 2014-06-24 +================== + + * use `~` range on mime-types + +1.3.1 / 2014-06-19 +================== + + * fix global variable leak + +1.3.0 / 2014-06-19 +================== + + * improve type parsing + + - invalid media type never matches + - media type not case-sensitive + - extra LWS does not affect results + +1.2.2 / 2014-06-19 +================== + + * fix behavior on unknown type argument + +1.2.1 / 2014-06-03 +================== + + * switch dependency from `mime` to `mime-types@1.0.0` + +1.2.0 / 2014-05-11 +================== + + * support suffix matching: + + - `+json` matches `application/vnd+json` + - `*/vnd+json` matches `application/vnd+json` + - `application/*+json` matches `application/vnd+json` + +1.1.0 / 2014-04-12 +================== + + * add non-array values support + * expose internal utilities: + + - `.is()` + - `.hasBody()` + - `.normalize()` + - `.match()` + +1.0.1 / 2014-03-30 +================== + + * add `multipart` as a shorthand diff --git a/node_modules/body-parser/node_modules/type-is/LICENSE b/node_modules/body-parser/node_modules/type-is/LICENSE new file mode 100644 index 0000000..4164d08 --- /dev/null +++ b/node_modules/body-parser/node_modules/type-is/LICENSE @@ -0,0 +1,21 @@ +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/node_modules/body-parser/node_modules/type-is/README.md b/node_modules/body-parser/node_modules/type-is/README.md new file mode 100644 index 0000000..a3ec5a5 --- /dev/null +++ b/node_modules/body-parser/node_modules/type-is/README.md @@ -0,0 +1,100 @@ +# type-is + +[![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] + +Infer the content-type of a request. + +### Install + +```sh +$ npm install type-is +``` + +## API + +```js +var http = require('http') +var is = require('type-is') + +http.createServer(function (req, res) { + var istext = is(req, ['text/*']) + res.end('you ' + (istext ? 'sent' : 'did not send') + ' me text') +}) +``` + +### type = is(request, types) + +`request` is the node HTTP request. `types` is an array of types. + +```js +// req.headers.content-type = 'application/json' + +is(req, ['json']) // 'json' +is(req, ['html', 'json']) // 'json' +is(req, ['application/*']) // 'application/json' +is(req, ['application/json']) // 'application/json' + +is(req, ['html']) // false +``` + +#### Each type can be: + +- An extension name such as `json`. This name will be returned if matched. +- A mime type such as `application/json`. +- A mime type with a wildcard such as `*/json` or `application/*`. The full mime type will be returned if matched +- A suffix such as `+json`. This can be combined with a wildcard such as `*/vnd+json` or `application/*+json`. The full mime type will be returned if matched. + +`false` will be returned if no type matches. + +## Examples + +#### Example body parser + +```js +var is = require('type-is'); + +function bodyParser(req, res, next) { + if (!is.hasBody(req)) { + return next() + } + + switch (is(req, ['urlencoded', 'json', 'multipart'])) { + case 'urlencoded': + // parse urlencoded body + throw new Error('implement urlencoded body parsing') + break + case 'json': + // parse json body + throw new Error('implement json body parsing') + break + case 'multipart': + // parse multipart body + throw new Error('implement multipart body parsing') + break + default: + // 415 error code + res.statusCode = 415 + res.end() + return + } +} +``` + +## License + +[MIT](LICENSE) + +[npm-image]: https://img.shields.io/npm/v/type-is.svg?style=flat +[npm-url]: https://npmjs.org/package/type-is +[node-version-image]: https://img.shields.io/badge/node.js-%3E%3D_0.6-brightgreen.svg?style=flat +[node-version-url]: http://nodejs.org/download/ +[travis-image]: https://img.shields.io/travis/jshttp/type-is.svg?style=flat +[travis-url]: https://travis-ci.org/jshttp/type-is +[coveralls-image]: https://img.shields.io/coveralls/jshttp/type-is.svg?style=flat +[coveralls-url]: https://coveralls.io/r/jshttp/type-is?branch=master +[downloads-image]: https://img.shields.io/npm/dm/type-is.svg?style=flat +[downloads-url]: https://npmjs.org/package/type-is diff --git a/node_modules/body-parser/node_modules/type-is/index.js b/node_modules/body-parser/node_modules/type-is/index.js new file mode 100644 index 0000000..8d220d1 --- /dev/null +++ b/node_modules/body-parser/node_modules/type-is/index.js @@ -0,0 +1,226 @@ + +var typer = require('media-typer') +var mime = require('mime-types') + +module.exports = typeofrequest; +typeofrequest.is = typeis; +typeofrequest.hasBody = hasbody; +typeofrequest.normalize = normalize; +typeofrequest.match = mimeMatch; + +/** + * Compare a `value` content-type with `types`. + * Each `type` can be an extension like `html`, + * a special shortcut like `multipart` or `urlencoded`, + * or a mime type. + * + * If no types match, `false` is returned. + * Otherwise, the first `type` that matches is returned. + * + * @param {String} value + * @param {Array} types + * @return String + */ + +function typeis(value, types_) { + var i + var types = types_ + + // remove parameters and normalize + value = typenormalize(value) + + // no type or invalid + if (!value) { + return false + } + + // support flattened arguments + if (types && !Array.isArray(types)) { + types = new Array(arguments.length - 1) + for (i = 0; i < types.length; i++) { + types[i] = arguments[i + 1] + } + } + + // no types, return the content type + if (!types || !types.length) return value; + + var type + for (i = 0; i < types.length; i++) { + if (mimeMatch(normalize(type = types[i]), value)) { + return type[0] === '+' || ~type.indexOf('*') + ? value + : type + } + } + + // no matches + return false; +} + +/** + * Check if a request has a request body. + * A request with a body __must__ either have `transfer-encoding` + * or `content-length` headers set. + * http://www.w3.org/Protocols/rfc2616/rfc2616-sec4.html#sec4.3 + * + * @param {Object} request + * @return {Boolean} + * @api public + */ + +function hasbody(req) { + var headers = req.headers; + if ('transfer-encoding' in headers) return true; + return !isNaN(headers['content-length']); +} + +/** + * Check if the incoming request contains the "Content-Type" + * header field, and it contains any of the give mime `type`s. + * If there is no request body, `null` is returned. + * If there is no content type, `false` is returned. + * Otherwise, it returns the first `type` that matches. + * + * Examples: + * + * // With Content-Type: text/html; charset=utf-8 + * this.is('html'); // => 'html' + * this.is('text/html'); // => 'text/html' + * this.is('text/*', 'application/json'); // => 'text/html' + * + * // When Content-Type is application/json + * this.is('json', 'urlencoded'); // => 'json' + * this.is('application/json'); // => 'application/json' + * this.is('html', 'application/*'); // => 'application/json' + * + * this.is('html'); // => false + * + * @param {String|Array} types... + * @return {String|false|null} + * @api public + */ + +function typeofrequest(req, types_) { + var types = types_ + + // no body + if (!hasbody(req)) { + return null + } + + // support flattened arguments + if (arguments.length > 2) { + types = new Array(arguments.length - 1) + for (var i = 0; i < types.length; i++) { + types[i] = arguments[i + 1] + } + } + + // request content type + var value = req.headers['content-type'] + + return typeis(value, types); +} + +/** + * Normalize a mime type. + * If it's a shorthand, expand it to a valid mime type. + * + * In general, you probably want: + * + * var type = is(req, ['urlencoded', 'json', 'multipart']); + * + * Then use the appropriate body parsers. + * These three are the most common request body types + * and are thus ensured to work. + * + * @param {String} type + * @api private + */ + +function normalize(type) { + switch (type) { + case 'urlencoded': return 'application/x-www-form-urlencoded'; + case 'multipart': + type = 'multipart/*'; + break; + } + + return type[0] === '+' || ~type.indexOf('/') + ? type + : mime.lookup(type) +} + +/** + * Check if `exected` mime type + * matches `actual` mime type with + * wildcard and +suffix support. + * + * @param {String} expected + * @param {String} actual + * @return {Boolean} + * @api private + */ + +function mimeMatch(expected, actual) { + // invalid type + if (expected === false) { + return false + } + + // exact match + if (expected === actual) { + return true + } + + actual = actual.split('/'); + + if (expected[0] === '+') { + // support +suffix + return Boolean(actual[1]) + && expected.length <= actual[1].length + && expected === actual[1].substr(0 - expected.length) + } + + if (!~expected.indexOf('*')) return false; + + expected = expected.split('/'); + + if (expected[0] === '*') { + // support */yyy + return expected[1] === actual[1] + } + + if (expected[1] === '*') { + // support xxx/* + return expected[0] === actual[0] + } + + if (expected[1][0] === '*' && expected[1][1] === '+') { + // support xxx/*+zzz + return expected[0] === actual[0] + && expected[1].length <= actual[1].length + 1 + && expected[1].substr(1) === actual[1].substr(1 - expected[1].length) + } + + return false +} + +/** + * Normalize a type and remove parameters. + * + * @param {string} value + * @return {string} + * @api private + */ + +function typenormalize(value) { + try { + var type = typer.parse(value) + delete type.parameters + return typer.format(type) + } catch (err) { + return null + } +} diff --git a/node_modules/body-parser/node_modules/type-is/node_modules/mime-types/HISTORY.md b/node_modules/body-parser/node_modules/type-is/node_modules/mime-types/HISTORY.md new file mode 100644 index 0000000..510ea56 --- /dev/null +++ b/node_modules/body-parser/node_modules/type-is/node_modules/mime-types/HISTORY.md @@ -0,0 +1,31 @@ +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/node_modules/body-parser/node_modules/type-is/node_modules/mime-types/LICENSE b/node_modules/body-parser/node_modules/type-is/node_modules/mime-types/LICENSE new file mode 100644 index 0000000..a7ae8ee --- /dev/null +++ b/node_modules/body-parser/node_modules/type-is/node_modules/mime-types/LICENSE @@ -0,0 +1,22 @@ + +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/node_modules/body-parser/node_modules/type-is/node_modules/mime-types/README.md b/node_modules/body-parser/node_modules/type-is/node_modules/mime-types/README.md new file mode 100644 index 0000000..99d658b --- /dev/null +++ b/node_modules/body-parser/node_modules/type-is/node_modules/mime-types/README.md @@ -0,0 +1,99 @@ +# 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('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' +``` + +### 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?style=flat +[npm-url]: https://npmjs.org/package/mime-types +[node-version-image]: https://img.shields.io/badge/node.js-%3E%3D_0.6-brightgreen.svg?style=flat +[node-version-url]: http://nodejs.org/download/ +[travis-image]: https://img.shields.io/travis/jshttp/mime-types.svg?style=flat +[travis-url]: https://travis-ci.org/jshttp/mime-types +[coveralls-image]: https://img.shields.io/coveralls/jshttp/mime-types.svg?style=flat +[coveralls-url]: https://coveralls.io/r/jshttp/mime-types +[downloads-image]: https://img.shields.io/npm/dm/mime-types.svg?style=flat +[downloads-url]: https://npmjs.org/package/mime-types diff --git a/node_modules/body-parser/node_modules/type-is/node_modules/mime-types/index.js b/node_modules/body-parser/node_modules/type-is/node_modules/mime-types/index.js new file mode 100644 index 0000000..b46a202 --- /dev/null +++ b/node_modules/body-parser/node_modules/type-is/node_modules/mime-types/index.js @@ -0,0 +1,63 @@ + +var db = require('mime-db') + +// types[extension] = type +exports.types = Object.create(null) +// extensions[type] = [extensions] +exports.extensions = 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 +} + +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] +} + +// type has to be an exact mime type +exports.charset = function (type) { + var mime = db[type] + if (mime && mime.charset) return mime.charset + + // default text/* to utf-8 + if (/^text\//.test(type)) return 'UTF-8' + + return false +} + +// backwards compatibility +exports.charsets = { + lookup: exports.charset +} + +// 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() + } + return type +} diff --git a/node_modules/body-parser/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/LICENSE b/node_modules/body-parser/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/LICENSE new file mode 100644 index 0000000..a7ae8ee --- /dev/null +++ b/node_modules/body-parser/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/LICENSE @@ -0,0 +1,22 @@ + +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/node_modules/body-parser/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/README.md b/node_modules/body-parser/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/README.md new file mode 100644 index 0000000..7909379 --- /dev/null +++ b/node_modules/body-parser/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/README.md @@ -0,0 +1,72 @@ +# 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 consistents of a single, public JSON file and does not include any logic, +allowing it to remain as unopinionated 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 + +## Usage + +```bash +npm i mime-db +``` + +```js +var db = require('mime-db'); + +// grab data on .js files +var data = db['application/javascript']; +``` + +If you're crazy enough to use this in the browser, +you can just grab the JSON file: + +``` +https://cdn.rawgit.com/jshttp/mime-db/master/db.json +``` + +## 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) +- `.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`. + +## Repository Structure + +- `scripts` - these are scripts to run to build the database +- `src/` - this is a folder of files created from remote sources like Apache and IANA +- `lib/` - this is a folder of our own custom sources and db, which will be merged into `db.json` +- `db.json` - the final built JSON file for end-user usage + +## Contributing + +To edit the database, only make PRs against files in the `lib/` folder. +To update the build, run `npm run update`. + +[npm-version-image]: https://img.shields.io/npm/v/mime-db.svg?style=flat +[npm-downloads-image]: https://img.shields.io/npm/dm/mime-db.svg?style=flat +[npm-url]: https://npmjs.org/package/mime-db +[travis-image]: https://img.shields.io/travis/jshttp/mime-db.svg?style=flat +[travis-url]: https://travis-ci.org/jshttp/mime-db +[coveralls-image]: https://img.shields.io/coveralls/jshttp/mime-db.svg?style=flat +[coveralls-url]: https://coveralls.io/r/jshttp/mime-db?branch=master +[node-image]: http://img.shields.io/badge/node.js->=_0.6-brightgreen.svg?style=flat +[node-url]: http://nodejs.org/download/ diff --git a/node_modules/body-parser/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/db.json b/node_modules/body-parser/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/db.json new file mode 100644 index 0000000..f89fc14 --- /dev/null +++ b/node_modules/body-parser/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/db.json @@ -0,0 +1,6269 @@ +{ + "application/1d-interleaved-parityfec": { + "source": "iana" + }, + "application/3gpdash-qoe-report+xml": { + "source": "iana" + }, + "application/3gpp-ims+xml": { + "source": "iana" + }, + "application/activemessage": { + "source": "iana" + }, + "application/alto-costmap+json": { + "source": "iana" + }, + "application/alto-costmapfilter+json": { + "source": "iana" + }, + "application/alto-directory+json": { + "source": "iana" + }, + "application/alto-endpointcost+json": { + "source": "iana" + }, + "application/alto-endpointcostparams+json": { + "source": "iana" + }, + "application/alto-endpointprop+json": { + "source": "iana" + }, + "application/alto-endpointpropparams+json": { + "source": "iana" + }, + "application/alto-error+json": { + "source": "iana" + }, + "application/alto-networkmap+json": { + "source": "iana" + }, + "application/alto-networkmapfilter+json": { + "source": "iana" + }, + "application/andrew-inset": { + "source": "iana", + "extensions": ["ez"] + }, + "application/applefile": { + "source": "iana" + }, + "application/applixware": { + "source": "apache", + "extensions": ["aw"] + }, + "application/atf": { + "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/auth-policy+xml": { + "source": "iana" + }, + "application/bacnet-xdd+zip": { + "source": "iana" + }, + "application/batch-smtp": { + "source": "iana" + }, + "application/beep+xml": { + "source": "iana" + }, + "application/calendar+json": { + "source": "iana" + }, + "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/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-2018+xml": { + "source": "iana" + }, + "application/cellml+xml": { + "source": "iana" + }, + "application/cfw": { + "source": "iana" + }, + "application/cms": { + "source": "iana" + }, + "application/cnrp+xml": { + "source": "iana" + }, + "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/dec-dx": { + "source": "iana" + }, + "application/dialog-info+xml": { + "source": "iana" + }, + "application/dicom": { + "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": "apache", + "extensions": ["epub"] + }, + "application/eshop": { + "source": "iana" + }, + "application/example": { + "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/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"] + }, + "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/jrd+json": { + "source": "iana" + }, + "application/json": { + "source": "iana", + "charset": "UTF-8", + "compressible": true, + "extensions": ["json","map"] + }, + "application/json-patch+json": { + "source": "iana" + }, + "application/jsonml+json": { + "source": "apache", + "extensions": ["jsonml"] + }, + "application/kpml-request+xml": { + "source": "iana" + }, + "application/kpml-response+xml": { + "source": "iana" + }, + "application/ld+json": { + "source": "iana" + }, + "application/link-format": { + "source": "iana" + }, + "application/load-control+xml": { + "source": "iana" + }, + "application/lost+xml": { + "source": "iana", + "extensions": ["lostxml"] + }, + "application/lostsync+xml": { + "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/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": "apache", + "extensions": ["mbox"] + }, + "application/mbox+xml": { + "source": "iana" + }, + "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" + }, + "application/metalink+xml": { + "source": "apache", + "extensions": ["metalink"] + }, + "application/metalink4+xml": { + "source": "iana", + "extensions": ["meta4"] + }, + "application/mets+xml": { + "source": "iana", + "extensions": ["mets"] + }, + "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": "apache" + }, + "application/octet-stream": { + "source": "iana", + "compressible": false, + "extensions": ["bin","dms","lrf","mar","so","dist","distz","pkg","bpk","dump","elc","deploy","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/oscp-response": { + "source": "iana" + }, + "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/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" + }, + "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/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" + }, + "application/vcard+xml": { + "source": "iana" + }, + "application/vemmi": { + "source": "iana" + }, + "application/vividence.scriptfile": { + "source": "apache" + }, + "application/vnd-acucobol": { + "source": "iana" + }, + "application/vnd-curl": { + "source": "iana" + }, + "application/vnd-dart": { + "source": "iana" + }, + "application/vnd-dxr": { + "source": "iana" + }, + "application/vnd-fdf": { + "source": "iana" + }, + "application/vnd-mif": { + "source": "iana" + }, + "application/vnd-sema": { + "source": "iana" + }, + "application/vnd-wap-wmlc": { + "source": "iana" + }, + "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.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": "apache", + "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.api+json": { + "source": "iana" + }, + "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.bekitzur-stech+json": { + "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.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.collection+json": { + "source": "iana" + }, + "application/vnd.collection.doc+json": { + "source": "iana" + }, + "application/vnd.collection.next+json": { + "source": "iana" + }, + "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": "apache" + }, + "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": "apache", + "compressible": true, + "extensions": ["dart"] + }, + "application/vnd.data-vision.rdz": { + "source": "iana", + "extensions": ["rdz"] + }, + "application/vnd.debian.binary-package": { + "source": "iana" + }, + "application/vnd.dece-zip": { + "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": "apache", + "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" + }, + "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": "apache", + "extensions": ["svc"] + }, + "application/vnd.dvb_service": { + "source": "iana" + }, + "application/vnd.dxr": { + "source": "apache" + }, + "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.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.fdf": { + "source": "apache", + "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" + }, + "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.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.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" + }, + "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" + }, + "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" + }, + "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.lis.v2.result+json": { + "source": "iana" + }, + "application/vnd.ims.lti.v2.toolconsumerprofile+json": { + "source": "iana" + }, + "application/vnd.ims.lti.v2.toolproxy+json": { + "source": "iana" + }, + "application/vnd.ims.lti.v2.toolproxy.id+json": { + "source": "iana" + }, + "application/vnd.ims.lti.v2.toolsettings+json": { + "source": "iana" + }, + "application/vnd.ims.lti.v2.toolsettings.simple+json": { + "source": "iana" + }, + "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" + }, + "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.micrografx-igx": { + "source": "iana" + }, + "application/vnd.micrografx.flo": { + "source": "iana", + "extensions": ["flo"] + }, + "application/vnd.micrografx.igx": { + "source": "apache", + "extensions": ["igx"] + }, + "application/vnd.miele+json": { + "source": "iana" + }, + "application/vnd.mif": { + "source": "apache", + "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.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" + }, + "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" + }, + "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.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": "apache" + }, + "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-doc": { + "source": "iana" + }, + "application/vnd.sealed-eml": { + "source": "iana" + }, + "application/vnd.sealed-mht": { + "source": "iana" + }, + "application/vnd.sealed-ppt": { + "source": "iana" + }, + "application/vnd.sealed-tiff": { + "source": "iana" + }, + "application/vnd.sealed-xls": { + "source": "iana" + }, + "application/vnd.sealed.3df": { + "source": "iana" + }, + "application/vnd.sealed.csf": { + "source": "iana" + }, + "application/vnd.sealed.doc": { + "source": "apache" + }, + "application/vnd.sealed.eml": { + "source": "apache" + }, + "application/vnd.sealed.mht": { + "source": "apache" + }, + "application/vnd.sealed.net": { + "source": "iana" + }, + "application/vnd.sealed.ppt": { + "source": "apache" + }, + "application/vnd.sealed.tiff": { + "source": "apache" + }, + "application/vnd.sealed.xls": { + "source": "apache" + }, + "application/vnd.sealedmedia.softseal-html": { + "source": "iana" + }, + "application/vnd.sealedmedia.softseal-pdf": { + "source": "iana" + }, + "application/vnd.sealedmedia.softseal.html": { + "source": "apache" + }, + "application/vnd.sealedmedia.softseal.pdf": { + "source": "apache" + }, + "application/vnd.seemail": { + "source": "iana", + "extensions": ["see"] + }, + "application/vnd.sema": { + "source": "apache", + "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" + }, + "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.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-slc": { + "source": "iana" + }, + "application/vnd.wap-wbxml": { + "source": "iana" + }, + "application/vnd.wap.sic": { + "source": "iana" + }, + "application/vnd.wap.slc": { + "source": "apache" + }, + "application/vnd.wap.wbxml": { + "source": "apache", + "extensions": ["wbxml"] + }, + "application/vnd.wap.wmlc": { + "source": "apache", + "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" + }, + "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/vwg-multiplexed": { + "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-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-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-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-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-nzb": { + "source": "apache", + "extensions": ["nzb"] + }, + "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-research-info-systems": { + "source": "apache", + "extensions": ["ris"] + }, + "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"] + }, + "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": { + "extensions": ["webapp"] + }, + "application/x-www-form-urlencode": { + "compressible": false + }, + "application/x-www-form-urlencoded": { + "source": "iana" + }, + "application/x-x509-ca-cert": { + "source": "apache", + "extensions": ["der","crt"] + }, + "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": "iana" + }, + "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/example": { + "source": "iana" + }, + "audio/fwdred": { + "source": "iana" + }, + "audio/g719": { + "source": "iana" + }, + "audio/g721": { + "source": "iana" + }, + "audio/g722": { + "source": "iana" + }, + "audio/g7221": { + "source": "apache" + }, + "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": "apache" + }, + "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.sealedmedia.softseal.mpeg": { + "source": "apache" + }, + "audio/vnd.vmx.cvsd": { + "source": "iana" + }, + "audio/vnd.wave": { + "compressible": false + }, + "audio/vorbis": { + "source": "iana", + "compressible": false + }, + "audio/vorbis-config": { + "source": "iana" + }, + "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-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-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/example": { + "source": "iana" + }, + "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-djvu": { + "source": "iana" + }, + "image/vnd-svf": { + "source": "iana" + }, + "image/vnd-wap-wbmp": { + "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": "apache", + "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.sealed.png": { + "source": "apache" + }, + "image/vnd.sealedmedia.softseal-gif": { + "source": "iana" + }, + "image/vnd.sealedmedia.softseal-jpg": { + "source": "iana" + }, + "image/vnd.sealedmedia.softseal.gif": { + "source": "apache" + }, + "image/vnd.sealedmedia.softseal.jpg": { + "source": "apache" + }, + "image/vnd.svf": { + "source": "apache" + }, + "image/vnd.valve.source.texture": { + "source": "iana" + }, + "image/vnd.wap.wbmp": { + "source": "apache", + "extensions": ["wbmp"] + }, + "image/vnd.xiff": { + "source": "iana", + "extensions": ["xif"] + }, + "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-mrsid-image": { + "source": "apache", + "extensions": ["sid"] + }, + "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/example": { + "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/example": { + "source": "iana", + "compressible": false + }, + "model/iges": { + "source": "iana", + "compressible": false, + "extensions": ["igs","iges"] + }, + "model/mesh": { + "source": "iana", + "compressible": false, + "extensions": ["msh","mesh","silo"] + }, + "model/vnd-dwf": { + "source": "iana" + }, + "model/vnd.collada+xml": { + "source": "iana", + "extensions": ["dae"] + }, + "model/vnd.dwf": { + "source": "apache", + "extensions": ["dwf"] + }, + "model/vnd.flatland.3dml": { + "source": "iana" + }, + "model/vnd.gdl": { + "source": "iana", + "extensions": ["gdl"] + }, + "model/vnd.gs-gdl": { + "source": "iana" + }, + "model/vnd.gs.gdl": { + "source": "apache" + }, + "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.parasolid.transmit.binary": { + "source": "apache" + }, + "model/vnd.parasolid.transmit.text": { + "source": "apache" + }, + "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/example": { + "source": "iana" + }, + "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"] + }, + "text/css": { + "source": "iana", + "compressible": true, + "extensions": ["css"] + }, + "text/csv": { + "source": "iana", + "compressible": true, + "extensions": ["csv"] + }, + "text/directory": { + "source": "iana" + }, + "text/dns": { + "source": "iana" + }, + "text/ecmascript": { + "source": "iana" + }, + "text/encaprtp": { + "source": "iana" + }, + "text/enriched": { + "source": "iana" + }, + "text/example": { + "source": "iana" + }, + "text/fwdred": { + "source": "iana" + }, + "text/grammar-ref-list": { + "source": "iana" + }, + "text/html": { + "source": "iana", + "compressible": true, + "extensions": ["html","htm"] + }, + "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/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" + }, + "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-curl": { + "source": "iana" + }, + "text/vnd.abc": { + "source": "iana" + }, + "text/vnd.curl": { + "source": "apache", + "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-wml": { + "source": "iana" + }, + "text/vnd.wap.si": { + "source": "iana" + }, + "text/vnd.wap.sl": { + "source": "iana" + }, + "text/vnd.wap.wml": { + "source": "apache", + "extensions": ["wml"] + }, + "text/vnd.wap.wmlscript": { + "source": "iana", + "extensions": ["wmls"] + }, + "text/vtt": { + "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": { + "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-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 + }, + "text/xml-external-parsed-entity": { + "source": "iana" + }, + "video/1d-interleaved-parityfec": { + "source": "apache" + }, + "video/3gpp": { + "source": "apache", + "extensions": ["3gp"] + }, + "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/example": { + "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/node_modules/body-parser/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/index.js b/node_modules/body-parser/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/index.js new file mode 100644 index 0000000..551031f --- /dev/null +++ b/node_modules/body-parser/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/index.js @@ -0,0 +1,11 @@ +/*! + * mime-db + * Copyright(c) 2014 Jonathan Ong + * MIT Licensed + */ + +/** + * Module exports. + */ + +module.exports = require('./db.json') diff --git a/node_modules/body-parser/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/package.json b/node_modules/body-parser/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/package.json new file mode 100644 index 0000000..f067351 --- /dev/null +++ b/node_modules/body-parser/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/package.json @@ -0,0 +1,74 @@ +{ + "name": "mime-db", + "description": "Media Type Database", + "version": "1.0.1", + "author": { + "name": "Jonathan Ong", + "email": "me@jongleberry.com", + "url": "http://jongleberry.com" + }, + "license": "MIT", + "repository": { + "type": "git", + "url": "https://github.com/jshttp/mime-db" + }, + "devDependencies": { + "co": "3", + "cogent": "1", + "csv-parse": "0", + "gnode": "0.0.8", + "istanbul": "0.3.0", + "mocha": "1", + "stream-to-array": "2" + }, + "engine": { + "node": ">= 0.6.0" + }, + "files": [ + "LICENSE", + "db.json", + "index.js" + ], + "scripts": { + "update": "gnode scripts/extensions && gnode scripts/types && node scripts/build", + "clean": "rm src/*", + "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/" + }, + "keywords": [ + "mime", + "db", + "type", + "types", + "database", + "charset", + "charsets" + ], + "gitHead": "6c9ee137430015b52887901377ac2f33e21f4078", + "bugs": { + "url": "https://github.com/jshttp/mime-db/issues" + }, + "homepage": "https://github.com/jshttp/mime-db", + "_id": "mime-db@1.0.1", + "_shasum": "35d99b0965967253bb30633a7d07a8de9975a952", + "_from": "mime-db@~1.0.1", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + }, + "maintainers": [ + { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + } + ], + "dist": { + "shasum": "35d99b0965967253bb30633a7d07a8de9975a952", + "tarball": "http://registry.npmjs.org/mime-db/-/mime-db-1.0.1.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.0.1.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/body-parser/node_modules/type-is/node_modules/mime-types/package.json b/node_modules/body-parser/node_modules/type-is/node_modules/mime-types/package.json new file mode 100644 index 0000000..494c346 --- /dev/null +++ b/node_modules/body-parser/node_modules/type-is/node_modules/mime-types/package.json @@ -0,0 +1,80 @@ +{ + "name": "mime-types", + "description": "The ultimate javascript content-type utility.", + "version": "2.0.1", + "contributors": [ + { + "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": "https://github.com/jshttp/mime-types" + }, + "dependencies": { + "mime-db": "~1.0.1" + }, + "devDependencies": { + "istanbul": "0", + "mocha": "1" + }, + "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": "c6e40fb033331aa87d9d4a5f1e5c0245e9edb2f6", + "bugs": { + "url": "https://github.com/jshttp/mime-types/issues" + }, + "homepage": "https://github.com/jshttp/mime-types", + "_id": "mime-types@2.0.1", + "_shasum": "7f5b4712592e7dd46ca733fd1c5f5d71356de615", + "_from": "mime-types@~2.0.1", + "_npmVersion": "1.4.21", + "_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": "7f5b4712592e7dd46ca733fd1c5f5d71356de615", + "tarball": "http://registry.npmjs.org/mime-types/-/mime-types-2.0.1.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.0.1.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/body-parser/node_modules/type-is/package.json b/node_modules/body-parser/node_modules/type-is/package.json new file mode 100644 index 0000000..0518a9b --- /dev/null +++ b/node_modules/body-parser/node_modules/type-is/package.json @@ -0,0 +1,93 @@ +{ + "name": "type-is", + "description": "Infer the content-type of a request.", + "version": "1.5.1", + "author": { + "name": "Jonathan Ong", + "email": "me@jongleberry.com", + "url": "http://jongleberry.com" + }, + "contributors": [ + { + "name": "Douglas Christopher Wilson", + "email": "doug@somethingdoug.com" + } + ], + "license": "MIT", + "repository": { + "type": "git", + "url": "https://github.com/jshttp/type-is" + }, + "dependencies": { + "media-typer": "0.3.0", + "mime-types": "~2.0.1" + }, + "devDependencies": { + "istanbul": "~0.3.0", + "mocha": "1" + }, + "engines": { + "node": ">= 0.6" + }, + "files": [ + "LICENSE", + "HISTORY.md", + "index.js" + ], + "scripts": { + "test": "mocha --reporter spec --check-leaks --bail 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/" + }, + "keywords": [ + "content", + "type", + "checking" + ], + "gitHead": "74d33287453bf7c166f6410fc608c1c7588070ae", + "bugs": { + "url": "https://github.com/jshttp/type-is/issues" + }, + "homepage": "https://github.com/jshttp/type-is", + "_id": "type-is@1.5.1", + "_shasum": "5c1e62d874f79199fb16b34d16972dba376ccbed", + "_from": "type-is@~1.5.1", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + "maintainers": [ + { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + }, + { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + { + "name": "tjholowaychuk", + "email": "tj@vision-media.ca" + }, + { + "name": "shtylman", + "email": "shtylman@gmail.com" + }, + { + "name": "mscdex", + "email": "mscdex@mscdex.net" + }, + { + "name": "fishrock123", + "email": "fishrock123@rocketmail.com" + } + ], + "dist": { + "shasum": "5c1e62d874f79199fb16b34d16972dba376ccbed", + "tarball": "http://registry.npmjs.org/type-is/-/type-is-1.5.1.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/type-is/-/type-is-1.5.1.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/body-parser/package.json b/node_modules/body-parser/package.json new file mode 100644 index 0000000..b74c7e9 --- /dev/null +++ b/node_modules/body-parser/package.json @@ -0,0 +1,96 @@ +{ + "name": "body-parser", + "description": "Node.js body parsing middleware", + "version": "1.8.2", + "contributors": [ + { + "name": "Douglas Christopher Wilson", + "email": "doug@somethingdoug.com" + }, + { + "name": "Jonathan Ong", + "email": "me@jongleberry.com", + "url": "http://jongleberry.com" + } + ], + "license": "MIT", + "repository": { + "type": "git", + "url": "https://github.com/expressjs/body-parser" + }, + "dependencies": { + "bytes": "1.0.0", + "depd": "0.4.5", + "iconv-lite": "0.4.4", + "media-typer": "0.3.0", + "on-finished": "2.1.0", + "qs": "2.2.3", + "raw-body": "1.3.0", + "type-is": "~1.5.1" + }, + "devDependencies": { + "istanbul": "0.3.2", + "mocha": "~1.21.4", + "should": "~4.0.4", + "supertest": "~0.13.0" + }, + "files": [ + "lib/", + "LICENSE", + "HISTORY.md", + "index.js" + ], + "engines": { + "node": ">= 0.8" + }, + "scripts": { + "test": "mocha --require should --require test/support/env --reporter spec --check-leaks --bail test/", + "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --require test/support/env --reporter dot --check-leaks test/", + "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --require test/support/env --reporter spec --check-leaks test/" + }, + "gitHead": "caf6e06cf7b4e3d31717e75e31dc2efc873a1047", + "bugs": { + "url": "https://github.com/expressjs/body-parser/issues" + }, + "homepage": "https://github.com/expressjs/body-parser", + "_id": "body-parser@1.8.2", + "_shasum": "cb55519e748f2ac89bd3c8e34cb759d391c4d67d", + "_from": "body-parser@1.8.2", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + "maintainers": [ + { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + }, + { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + { + "name": "tjholowaychuk", + "email": "tj@vision-media.ca" + }, + { + "name": "shtylman", + "email": "shtylman@gmail.com" + }, + { + "name": "mscdex", + "email": "mscdex@mscdex.net" + }, + { + "name": "fishrock123", + "email": "fishrock123@rocketmail.com" + } + ], + "dist": { + "shasum": "cb55519e748f2ac89bd3c8e34cb759d391c4d67d", + "tarball": "http://registry.npmjs.org/body-parser/-/body-parser-1.8.2.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.8.2.tgz" +} diff --git a/node_modules/cookie-parser/HISTORY.md b/node_modules/cookie-parser/HISTORY.md new file mode 100644 index 0000000..9b42e8d --- /dev/null +++ b/node_modules/cookie-parser/HISTORY.md @@ -0,0 +1,46 @@ +1.3.3 / 2014-09-05 +================== + + * deps: cookie-signature@1.0.5 + +1.3.2 / 2014-06-26 +================== + + * deps: cookie-signature@1.0.4 + - fix for timing attacks + +1.3.1 / 2014-06-17 +================== + + * actually export `signedCookie` + +1.3.0 / 2014-06-17 +================== + + * add `signedCookie` export for single cookie unsigning + +1.2.0 / 2014-06-17 +================== + + * export parsing functions + * `req.cookies` and `req.signedCookies` are now plain objects + * slightly faster parsing of many cookies + +1.1.0 / 2014-05-12 +================== + + * Support for NodeJS version 0.8 + * deps: cookie@0.1.2 + - Fix for maxAge == 0 + - made compat with expires field + - tweak maxAge NaN error message + +1.0.1 / 2014-02-20 +================== + + * add missing dependencies + +1.0.0 / 2014-02-15 +================== + + * Genesis from `connect` diff --git a/node_modules/cookie-parser/LICENSE b/node_modules/cookie-parser/LICENSE new file mode 100644 index 0000000..a7693b0 --- /dev/null +++ b/node_modules/cookie-parser/LICENSE @@ -0,0 +1,22 @@ +(The MIT License) + +Copyright (c) 2014 TJ Holowaychuk + +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/node_modules/cookie-parser/README.md b/node_modules/cookie-parser/README.md new file mode 100644 index 0000000..53c483f --- /dev/null +++ b/node_modules/cookie-parser/README.md @@ -0,0 +1,78 @@ +# cookie-parser + +[![NPM Version][npm-image]][npm-url] +[![NPM Downloads][downloads-image]][downloads-url] +[![Build Status][travis-image]][travis-url] +[![Test Coverage][coveralls-image]][coveralls-url] + +Parse `Cookie` header and populate `req.cookies` with an object keyed by the cookie +names. Optionally you may enable signed cookie support by passing a `secret` string, +which assigns `req.secret` so it may be used by other middleware. + +## Installation + +```sh +$ npm install cookie-parser +``` + +## API + +```js +var express = require('express') +var cookieParser = require('cookie-parser') + +var app = express() +app.use(cookieParser()) +``` + +### cookieParser(secret, options) + +- `secret` a string used for signing cookies. This is optional and if not specified, will not parse signed cookies. +- `options` an object that is passed to `cookie.parse` as the second option. See [cookie](https://www.npmjs.org/package/cookie) for more information. + - `decode` a function to decode the value of the cookie + +### cookieParser.JSONCookie(str) + +Parse a cookie value as a JSON cookie. This will return the parsed JSON value if it was a JSON cookie, otherwise it will return the passed value. + +### cookieParser.JSONCookies(cookies) + +Given an object, this will iterate over the keys and call `JSONCookie` on each value. This will return the same object passed in. + +### cookieParser.signedCookie(str, secret) + +Parse a cookie value as a signed cookie. This will return the parsed unsigned value if it was a signed cookie and the signature was valid, otherwise it will return the passed value. + +### cookieParser.signedCookies(cookies, secret) + +Given an object, this will iterate over the keys and check if any value is a signed cookie. If it is a signed cookie and the signature is valid, the key will be deleted from the object and added to the new object that is returned. + +## Example + +```js +var express = require('express') +var cookieParser = require('cookie-parser') + +var app = express() +app.use(cookieParser()) + +app.get('/', function(req, res) { + console.log("Cookies: ", req.cookies) +}) + +app.listen(8080) + +// curl command that sends an HTTP request with two cookies +// curl http://127.0.0.1:8080 --cookie "Cho=Kim;Greet=Hello" +``` + +### [MIT Licensed](LICENSE) + +[npm-image]: https://img.shields.io/npm/v/cookie-parser.svg?style=flat +[npm-url]: https://npmjs.org/package/cookie-parser +[travis-image]: https://img.shields.io/travis/expressjs/cookie-parser.svg?style=flat +[travis-url]: https://travis-ci.org/expressjs/cookie-parser +[coveralls-image]: https://img.shields.io/coveralls/expressjs/cookie-parser.svg?style=flat +[coveralls-url]: https://coveralls.io/r/expressjs/cookie-parser?branch=master +[downloads-image]: https://img.shields.io/npm/dm/cookie-parser.svg?style=flat +[downloads-url]: https://npmjs.org/package/cookie-parser diff --git a/node_modules/cookie-parser/index.js b/node_modules/cookie-parser/index.js new file mode 100644 index 0000000..cecb840 --- /dev/null +++ b/node_modules/cookie-parser/index.js @@ -0,0 +1,59 @@ +/*! + * cookie-parser + * MIT Licensed + */ + +/** + * Module dependencies. + */ + +var cookie = require('cookie'); +var parse = require('./lib/parse'); + +/** + * Parse Cookie header and populate `req.cookies` + * with an object keyed by the cookie names. + * + * @param {String} [secret] + * @param {Object} [options] + * @return {Function} + * @api public + */ + +exports = module.exports = function cookieParser(secret, options){ + return function cookieParser(req, res, next) { + if (req.cookies) return next(); + var cookies = req.headers.cookie; + + req.secret = secret; + req.cookies = Object.create(null); + req.signedCookies = Object.create(null); + + // no cookies + if (!cookies) { + return next(); + } + + req.cookies = cookie.parse(cookies, options); + + // parse signed cookies + if (secret) { + req.signedCookies = parse.signedCookies(req.cookies, secret); + req.signedCookies = parse.JSONCookies(req.signedCookies); + } + + // parse JSON cookies + req.cookies = parse.JSONCookies(req.cookies); + + next(); + }; +}; + +/** + * Export parsing functions. + */ + +exports.JSONCookie = parse.JSONCookie; +exports.JSONCookies = parse.JSONCookies; +exports.signedCookie = parse.signedCookie; +exports.signedCookies = parse.signedCookies; diff --git a/node_modules/cookie-parser/lib/parse.js b/node_modules/cookie-parser/lib/parse.js new file mode 100644 index 0000000..db1e619 --- /dev/null +++ b/node_modules/cookie-parser/lib/parse.js @@ -0,0 +1,90 @@ +var signature = require('cookie-signature'); + +/** + * Parse signed cookies, returning an object + * containing the decoded key/value pairs, + * while removing the signed key from `obj`. + * + * @param {Object} obj + * @return {Object} + * @api private + */ + +exports.signedCookies = function(obj, secret){ + var cookies = Object.keys(obj); + var dec; + var key; + var ret = Object.create(null); + var val; + + for (var i = 0; i < cookies.length; i++) { + key = cookies[i]; + val = obj[key]; + dec = exports.signedCookie(val, secret); + + if (val !== dec) { + ret[key] = dec; + delete obj[key]; + } + } + + return ret; +}; + +/** + * Parse a signed cookie string, return the decoded value + * + * @param {String} str signed cookie string + * @param {String} secret + * @return {String} decoded value + * @api private + */ + +exports.signedCookie = function(str, secret){ + return str.substr(0, 2) === 's:' + ? signature.unsign(str.slice(2), secret) + : str; +}; + +/** + * Parse JSON cookies. + * + * @param {Object} obj + * @return {Object} + * @api private + */ + +exports.JSONCookies = function(obj){ + var cookies = Object.keys(obj); + var key; + var val; + + for (var i = 0; i < cookies.length; i++) { + key = cookies[i]; + val = exports.JSONCookie(obj[key]); + + if (val) { + obj[key] = val; + } + } + + return obj; +}; + +/** + * Parse JSON cookie string + * + * @param {String} str + * @return {Object} Parsed object or null if not json cookie + * @api private + */ + +exports.JSONCookie = function(str) { + if (!str || str.substr(0, 2) !== 'j:') return; + + try { + return JSON.parse(str.slice(2)); + } catch (err) { + // no op + } +}; diff --git a/node_modules/cookie-parser/node_modules/cookie-signature/.npmignore b/node_modules/cookie-parser/node_modules/cookie-signature/.npmignore new file mode 100644 index 0000000..f1250e5 --- /dev/null +++ b/node_modules/cookie-parser/node_modules/cookie-signature/.npmignore @@ -0,0 +1,4 @@ +support +test +examples +*.sock diff --git a/node_modules/cookie-parser/node_modules/cookie-signature/History.md b/node_modules/cookie-parser/node_modules/cookie-signature/History.md new file mode 100644 index 0000000..2bbc4b3 --- /dev/null +++ b/node_modules/cookie-parser/node_modules/cookie-signature/History.md @@ -0,0 +1,27 @@ +1.0.4 / 2014-06-25 +================== + + * corrected avoidance of timing attacks (thanks @tenbits!) + + +1.0.3 / 2014-01-28 +================== + + * [incorrect] fix for timing attacks + +1.0.2 / 2014-01-28 +================== + + * fix missing repository warning + * fix typo in test + +1.0.1 / 2013-04-15 +================== + + * Revert "Changed underlying HMAC algo. to sha512." + * Revert "Fix for timing attacks on MAC verification." + +0.0.1 / 2010-01-03 +================== + + * Initial release diff --git a/node_modules/cookie-parser/node_modules/cookie-signature/Makefile b/node_modules/cookie-parser/node_modules/cookie-signature/Makefile new file mode 100644 index 0000000..4e9c8d3 --- /dev/null +++ b/node_modules/cookie-parser/node_modules/cookie-signature/Makefile @@ -0,0 +1,7 @@ + +test: + @./node_modules/.bin/mocha \ + --require should \ + --reporter spec + +.PHONY: test \ No newline at end of file diff --git a/node_modules/cookie-parser/node_modules/cookie-signature/Readme.md b/node_modules/cookie-parser/node_modules/cookie-signature/Readme.md new file mode 100644 index 0000000..2559e84 --- /dev/null +++ b/node_modules/cookie-parser/node_modules/cookie-signature/Readme.md @@ -0,0 +1,42 @@ + +# cookie-signature + + Sign and unsign cookies. + +## Example + +```js +var cookie = require('cookie-signature'); + +var val = cookie.sign('hello', 'tobiiscool'); +val.should.equal('hello.DGDUkGlIkCzPz+C0B064FNgHdEjox7ch8tOBGslZ5QI'); + +var val = cookie.sign('hello', 'tobiiscool'); +cookie.unsign(val, 'tobiiscool').should.equal('hello'); +cookie.unsign(val, 'luna').should.be.false; +``` + +## License + +(The MIT License) + +Copyright (c) 2012 LearnBoost <tj@learnboost.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. \ No newline at end of file diff --git a/node_modules/cookie-parser/node_modules/cookie-signature/index.js b/node_modules/cookie-parser/node_modules/cookie-signature/index.js new file mode 100644 index 0000000..b63bf84 --- /dev/null +++ b/node_modules/cookie-parser/node_modules/cookie-signature/index.js @@ -0,0 +1,51 @@ +/** + * Module dependencies. + */ + +var crypto = require('crypto'); + +/** + * Sign the given `val` with `secret`. + * + * @param {String} val + * @param {String} secret + * @return {String} + * @api private + */ + +exports.sign = function(val, secret){ + if ('string' != typeof val) throw new TypeError('cookie required'); + if ('string' != typeof secret) throw new TypeError('secret required'); + return val + '.' + crypto + .createHmac('sha256', secret) + .update(val) + .digest('base64') + .replace(/\=+$/, ''); +}; + +/** + * Unsign and decode the given `val` with `secret`, + * returning `false` if the signature is invalid. + * + * @param {String} val + * @param {String} secret + * @return {String|Boolean} + * @api private + */ + +exports.unsign = function(val, secret){ + if ('string' != typeof val) throw new TypeError('cookie required'); + if ('string' != typeof secret) throw new TypeError('secret required'); + var str = val.slice(0, val.lastIndexOf('.')) + , mac = exports.sign(str, secret); + + return sha1(mac) == sha1(val) ? str : false; +}; + +/** + * Private + */ + +function sha1(str){ + return crypto.createHash('sha1').update(str).digest('hex'); +} diff --git a/node_modules/cookie-parser/node_modules/cookie-signature/package.json b/node_modules/cookie-parser/node_modules/cookie-signature/package.json new file mode 100644 index 0000000..ac74d61 --- /dev/null +++ b/node_modules/cookie-parser/node_modules/cookie-signature/package.json @@ -0,0 +1,55 @@ +{ + "name": "cookie-signature", + "version": "1.0.5", + "description": "Sign and unsign cookies", + "keywords": [ + "cookie", + "sign", + "unsign" + ], + "author": { + "name": "TJ Holowaychuk", + "email": "tj@learnboost.com" + }, + "license": "MIT", + "repository": { + "type": "git", + "url": "https://github.com/visionmedia/node-cookie-signature.git" + }, + "dependencies": {}, + "devDependencies": { + "mocha": "*", + "should": "*" + }, + "main": "index", + "gitHead": "73ed69b511b3ef47555d71b4ed1deea9e5ed6e1f", + "bugs": { + "url": "https://github.com/visionmedia/node-cookie-signature/issues" + }, + "homepage": "https://github.com/visionmedia/node-cookie-signature", + "_id": "cookie-signature@1.0.5", + "scripts": {}, + "_shasum": "a122e3f1503eca0f5355795b0711bb2368d450f9", + "_from": "cookie-signature@1.0.5", + "_npmVersion": "1.4.20", + "_npmUser": { + "name": "natevw", + "email": "natevw@yahoo.com" + }, + "maintainers": [ + { + "name": "tjholowaychuk", + "email": "tj@vision-media.ca" + }, + { + "name": "natevw", + "email": "natevw@yahoo.com" + } + ], + "dist": { + "shasum": "a122e3f1503eca0f5355795b0711bb2368d450f9", + "tarball": "http://registry.npmjs.org/cookie-signature/-/cookie-signature-1.0.5.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/cookie-signature/-/cookie-signature-1.0.5.tgz" +} diff --git a/node_modules/cookie-parser/node_modules/cookie/.npmignore b/node_modules/cookie-parser/node_modules/cookie/.npmignore new file mode 100644 index 0000000..efab07f --- /dev/null +++ b/node_modules/cookie-parser/node_modules/cookie/.npmignore @@ -0,0 +1,2 @@ +test +.travis.yml diff --git a/node_modules/cookie-parser/node_modules/cookie/LICENSE b/node_modules/cookie-parser/node_modules/cookie/LICENSE new file mode 100644 index 0000000..249d9de --- /dev/null +++ b/node_modules/cookie-parser/node_modules/cookie/LICENSE @@ -0,0 +1,9 @@ +// MIT License + +Copyright (C) Roman Shtylman + +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/node_modules/cookie-parser/node_modules/cookie/README.md b/node_modules/cookie-parser/node_modules/cookie/README.md new file mode 100644 index 0000000..3170b4b --- /dev/null +++ b/node_modules/cookie-parser/node_modules/cookie/README.md @@ -0,0 +1,44 @@ +# cookie [![Build Status](https://secure.travis-ci.org/defunctzombie/node-cookie.png?branch=master)](http://travis-ci.org/defunctzombie/node-cookie) # + +cookie is a basic cookie parser and serializer. It doesn't make assumptions about how you are going to deal with your cookies. It basically just provides a way to read and write the HTTP cookie headers. + +See [RFC6265](http://tools.ietf.org/html/rfc6265) for details about the http header for cookies. + +## how? + +``` +npm install cookie +``` + +```javascript +var cookie = require('cookie'); + +var hdr = cookie.serialize('foo', 'bar'); +// hdr = 'foo=bar'; + +var cookies = cookie.parse('foo=bar; cat=meow; dog=ruff'); +// cookies = { foo: 'bar', cat: 'meow', dog: 'ruff' }; +``` + +## more + +The serialize function takes a third parameter, an object, to set cookie options. See the RFC for valid values. + +### path +> cookie path + +### expires +> absolute expiration date for the cookie (Date object) + +### maxAge +> relative max age of the cookie from when the client receives it (seconds) + +### domain +> domain for the cookie + +### secure +> true or false + +### httpOnly +> true or false + diff --git a/node_modules/cookie-parser/node_modules/cookie/index.js b/node_modules/cookie-parser/node_modules/cookie/index.js new file mode 100644 index 0000000..00d54a7 --- /dev/null +++ b/node_modules/cookie-parser/node_modules/cookie/index.js @@ -0,0 +1,75 @@ + +/// Serialize the a name value pair into a cookie string suitable for +/// http headers. An optional options object specified cookie parameters +/// +/// serialize('foo', 'bar', { httpOnly: true }) +/// => "foo=bar; httpOnly" +/// +/// @param {String} name +/// @param {String} val +/// @param {Object} options +/// @return {String} +var serialize = function(name, val, opt){ + opt = opt || {}; + var enc = opt.encode || encode; + var pairs = [name + '=' + enc(val)]; + + if (null != opt.maxAge) { + var maxAge = opt.maxAge - 0; + if (isNaN(maxAge)) throw new Error('maxAge should be a Number'); + pairs.push('Max-Age=' + maxAge); + } + + if (opt.domain) pairs.push('Domain=' + opt.domain); + if (opt.path) pairs.push('Path=' + opt.path); + if (opt.expires) pairs.push('Expires=' + opt.expires.toUTCString()); + if (opt.httpOnly) pairs.push('HttpOnly'); + if (opt.secure) pairs.push('Secure'); + + return pairs.join('; '); +}; + +/// Parse the given cookie header string into an object +/// The object has the various cookies as keys(names) => values +/// @param {String} str +/// @return {Object} +var parse = function(str, opt) { + opt = opt || {}; + var obj = {} + var pairs = str.split(/; */); + var dec = opt.decode || decode; + + pairs.forEach(function(pair) { + var eq_idx = pair.indexOf('=') + + // skip things that don't look like key=value + if (eq_idx < 0) { + return; + } + + var key = pair.substr(0, eq_idx).trim() + var val = pair.substr(++eq_idx, pair.length).trim(); + + // quoted values + if ('"' == val[0]) { + val = val.slice(1, -1); + } + + // only assign once + if (undefined == obj[key]) { + try { + obj[key] = dec(val); + } catch (e) { + obj[key] = val; + } + } + }); + + return obj; +}; + +var encode = encodeURIComponent; +var decode = decodeURIComponent; + +module.exports.serialize = serialize; +module.exports.parse = parse; diff --git a/node_modules/cookie-parser/node_modules/cookie/package.json b/node_modules/cookie-parser/node_modules/cookie/package.json new file mode 100644 index 0000000..80aecf4 --- /dev/null +++ b/node_modules/cookie-parser/node_modules/cookie/package.json @@ -0,0 +1,53 @@ +{ + "author": { + "name": "Roman Shtylman", + "email": "shtylman@gmail.com" + }, + "name": "cookie", + "description": "cookie parsing and serialization", + "version": "0.1.2", + "repository": { + "type": "git", + "url": "git://github.com/shtylman/node-cookie.git" + }, + "keywords": [ + "cookie", + "cookies" + ], + "main": "index.js", + "scripts": { + "test": "mocha" + }, + "dependencies": {}, + "devDependencies": { + "mocha": "1.x.x" + }, + "optionalDependencies": {}, + "engines": { + "node": "*" + }, + "bugs": { + "url": "https://github.com/shtylman/node-cookie/issues" + }, + "homepage": "https://github.com/shtylman/node-cookie", + "_id": "cookie@0.1.2", + "dist": { + "shasum": "72fec3d24e48a3432073d90c12642005061004b1", + "tarball": "http://registry.npmjs.org/cookie/-/cookie-0.1.2.tgz" + }, + "_from": "cookie@0.1.2", + "_npmVersion": "1.4.6", + "_npmUser": { + "name": "shtylman", + "email": "shtylman@gmail.com" + }, + "maintainers": [ + { + "name": "shtylman", + "email": "shtylman@gmail.com" + } + ], + "directories": {}, + "_shasum": "72fec3d24e48a3432073d90c12642005061004b1", + "_resolved": "https://registry.npmjs.org/cookie/-/cookie-0.1.2.tgz" +} diff --git a/node_modules/cookie-parser/package.json b/node_modules/cookie-parser/package.json new file mode 100644 index 0000000..1f4207e --- /dev/null +++ b/node_modules/cookie-parser/package.json @@ -0,0 +1,71 @@ +{ + "name": "cookie-parser", + "description": "cookie parsing with signatures", + "version": "1.3.3", + "author": { + "name": "TJ Holowaychuk", + "email": "tj@vision-media.ca", + "url": "http://tjholowaychuk.com" + }, + "licenses": "MIT", + "repository": { + "type": "git", + "url": "https://github.com/expressjs/cookie-parser" + }, + "keywords": [ + "cookie", + "middleware" + ], + "dependencies": { + "cookie": "0.1.2", + "cookie-signature": "1.0.5" + }, + "devDependencies": { + "istanbul": "0.3.2", + "mocha": "~1.21.4", + "supertest": "~0.13.0" + }, + "files": [ + "lib/", + "LICENSE", + "HISTORY.md", + "index.js" + ], + "engines": { + "node": ">= 0.8.0" + }, + "scripts": { + "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/" + }, + "gitHead": "893bf91a8a4e49c63b6e32065991b13a7d27ed4c", + "bugs": { + "url": "https://github.com/expressjs/cookie-parser/issues" + }, + "homepage": "https://github.com/expressjs/cookie-parser", + "_id": "cookie-parser@1.3.3", + "_shasum": "7e3a2c745f4b460d5a340e578a0baa5d7725fe37", + "_from": "cookie-parser@1.3.3", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + "maintainers": [ + { + "name": "shtylman", + "email": "shtylman@gmail.com" + }, + { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + } + ], + "dist": { + "shasum": "7e3a2c745f4b460d5a340e578a0baa5d7725fe37", + "tarball": "http://registry.npmjs.org/cookie-parser/-/cookie-parser-1.3.3.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/cookie-parser/-/cookie-parser-1.3.3.tgz" +} diff --git a/node_modules/debug/.jshintrc b/node_modules/debug/.jshintrc new file mode 100644 index 0000000..299877f --- /dev/null +++ b/node_modules/debug/.jshintrc @@ -0,0 +1,3 @@ +{ + "laxbreak": true +} diff --git a/node_modules/debug/.npmignore b/node_modules/debug/.npmignore new file mode 100644 index 0000000..7e6163d --- /dev/null +++ b/node_modules/debug/.npmignore @@ -0,0 +1,6 @@ +support +test +examples +example +*.sock +dist diff --git a/node_modules/debug/History.md b/node_modules/debug/History.md new file mode 100644 index 0000000..79429ff --- /dev/null +++ b/node_modules/debug/History.md @@ -0,0 +1,150 @@ + +2.0.0 / 2014-09-01 +================== + + * package: update "browserify" to v5.11.0 + * node: use stderr rather than stdout for logging (#29, @stephenmathieson) + +1.0.4 / 2014-07-15 +================== + + * dist: recompile + * example: remove `console.info()` log usage + * example: add "Content-Type" UTF-8 header to browser example + * browser: place %c marker after the space character + * browser: reset the "content" color via `color: inherit` + * browser: add colors support for Firefox >= v31 + * debug: prefer an instance `log()` function over the global one (#119) + * Readme: update documentation about styled console logs for FF v31 (#116, @wryk) + +1.0.3 / 2014-07-09 +================== + + * Add support for multiple wildcards in namespaces (#122, @seegno) + * browser: fix lint + +1.0.2 / 2014-06-10 +================== + + * browser: update color palette (#113, @gscottolson) + * common: make console logging function configurable (#108, @timoxley) + * node: fix %o colors on old node <= 0.8.x + * Makefile: find node path using shell/which (#109, @timoxley) + +1.0.1 / 2014-06-06 +================== + + * browser: use `removeItem()` to clear localStorage + * browser, node: don't set DEBUG if namespaces is undefined (#107, @leedm777) + * package: add "contributors" section + * node: fix comment typo + * README: list authors + +1.0.0 / 2014-06-04 +================== + + * make ms diff be global, not be scope + * debug: ignore empty strings in enable() + * node: make DEBUG_COLORS able to disable coloring + * *: export the `colors` array + * npmignore: don't publish the `dist` dir + * Makefile: refactor to use browserify + * package: add "browserify" as a dev dependency + * Readme: add Web Inspector Colors section + * node: reset terminal color for the debug content + * node: map "%o" to `util.inspect()` + * browser: map "%j" to `JSON.stringify()` + * debug: add custom "formatters" + * debug: use "ms" module for humanizing the diff + * Readme: add "bash" syntax highlighting + * browser: add Firebug color support + * browser: add colors for WebKit browsers + * node: apply log to `console` + * rewrite: abstract common logic for Node & browsers + * add .jshintrc file + +0.8.1 / 2014-04-14 +================== + + * package: re-add the "component" section + +0.8.0 / 2014-03-30 +================== + + * add `enable()` method for nodejs. Closes #27 + * change from stderr to stdout + * remove unnecessary index.js file + +0.7.4 / 2013-11-13 +================== + + * remove "browserify" key from package.json (fixes something in browserify) + +0.7.3 / 2013-10-30 +================== + + * fix: catch localStorage security error when cookies are blocked (Chrome) + * add debug(err) support. Closes #46 + * add .browser prop to package.json. Closes #42 + +0.7.2 / 2013-02-06 +================== + + * fix package.json + * fix: Mobile Safari (private mode) is broken with debug + * fix: Use unicode to send escape character to shell instead of octal to work with strict mode javascript + +0.7.1 / 2013-02-05 +================== + + * add repository URL to package.json + * add DEBUG_COLORED to force colored output + * add browserify support + * fix component. Closes #24 + +0.7.0 / 2012-05-04 +================== + + * Added .component to package.json + * Added debug.component.js build + +0.6.0 / 2012-03-16 +================== + + * Added support for "-" prefix in DEBUG [Vinay Pulim] + * Added `.enabled` flag to the node version [TooTallNate] + +0.5.0 / 2012-02-02 +================== + + * Added: humanize diffs. Closes #8 + * Added `debug.disable()` to the CS variant + * Removed padding. Closes #10 + * Fixed: persist client-side variant again. Closes #9 + +0.4.0 / 2012-02-01 +================== + + * Added browser variant support for older browsers [TooTallNate] + * Added `debug.enable('project:*')` to browser variant [TooTallNate] + * Added padding to diff (moved it to the right) + +0.3.0 / 2012-01-26 +================== + + * Added millisecond diff when isatty, otherwise UTC string + +0.2.0 / 2012-01-22 +================== + + * Added wildcard support + +0.1.0 / 2011-12-02 +================== + + * Added: remove colors unless stderr isatty [TooTallNate] + +0.0.1 / 2010-01-03 +================== + + * Initial release diff --git a/node_modules/debug/Makefile b/node_modules/debug/Makefile new file mode 100644 index 0000000..b0bde6e --- /dev/null +++ b/node_modules/debug/Makefile @@ -0,0 +1,33 @@ + +# get Makefile directory name: http://stackoverflow.com/a/5982798/376773 +THIS_MAKEFILE_PATH:=$(word $(words $(MAKEFILE_LIST)),$(MAKEFILE_LIST)) +THIS_DIR:=$(shell cd $(dir $(THIS_MAKEFILE_PATH));pwd) + +# BIN directory +BIN := $(THIS_DIR)/node_modules/.bin + +# applications +NODE ?= $(shell which node) +NPM ?= $(NODE) $(shell which npm) +BROWSERIFY ?= $(NODE) $(BIN)/browserify + +all: dist/debug.js + +install: node_modules + +clean: + @rm -rf node_modules dist + +dist: + @mkdir -p $@ + +dist/debug.js: node_modules browser.js debug.js dist + @$(BROWSERIFY) \ + --standalone debug \ + . > $@ + +node_modules: package.json + @NODE_ENV= $(NPM) install + @touch node_modules + +.PHONY: all install clean diff --git a/node_modules/debug/Readme.md b/node_modules/debug/Readme.md new file mode 100644 index 0000000..e59b9ad --- /dev/null +++ b/node_modules/debug/Readme.md @@ -0,0 +1,156 @@ +# debug + + tiny node.js debugging utility modelled after node core's debugging technique. + +## Installation + +```bash +$ npm install debug +``` + +## Usage + + With `debug` you simply invoke the exported function to generate your debug function, passing it a name which will determine if a noop function is returned, or a decorated `console.error`, so all of the `console` format string goodies you're used to work fine. A unique color is selected per-function for visibility. + +Example _app.js_: + +```js +var debug = require('debug')('http') + , http = require('http') + , name = 'My App'; + +// fake app + +debug('booting %s', name); + +http.createServer(function(req, res){ + debug(req.method + ' ' + req.url); + res.end('hello\n'); +}).listen(3000, function(){ + debug('listening'); +}); + +// fake worker of some kind + +require('./worker'); +``` + +Example _worker.js_: + +```js +var debug = require('debug')('worker'); + +setInterval(function(){ + debug('doing some work'); +}, 1000); +``` + + The __DEBUG__ environment variable is then used to enable these based on space or comma-delimited names. Here are some examples: + + ![debug http and worker](http://f.cl.ly/items/18471z1H402O24072r1J/Screenshot.png) + + ![debug worker](http://f.cl.ly/items/1X413v1a3M0d3C2c1E0i/Screenshot.png) + +## Millisecond diff + + When actively developing an application it can be useful to see when the time spent between one `debug()` call and the next. Suppose for example you invoke `debug()` before requesting a resource, and after as well, the "+NNNms" will show you how much time was spent between calls. + + ![](http://f.cl.ly/items/2i3h1d3t121M2Z1A3Q0N/Screenshot.png) + + When stdout is not a TTY, `Date#toUTCString()` is used, making it more useful for logging the debug information as shown below: + + ![](http://f.cl.ly/items/112H3i0e0o0P0a2Q2r11/Screenshot.png) + +## Conventions + + If you're using this in one or more of your libraries, you _should_ use the name of your library so that developers may toggle debugging as desired without guessing names. If you have more than one debuggers you _should_ prefix them with your library name and use ":" to separate features. For example "bodyParser" from Connect would then be "connect:bodyParser". + +## Wildcards + + The `*` character may be used as a wildcard. Suppose for example your library has debuggers named "connect:bodyParser", "connect:compress", "connect:session", instead of listing all three with `DEBUG=connect:bodyParser,connect.compress,connect:session`, you may simply do `DEBUG=connect:*`, or to run everything using this module simply use `DEBUG=*`. + + You can also exclude specific debuggers by prefixing them with a "-" character. For example, `DEBUG=*,-connect:*` would include all debuggers except those starting with "connect:". + +## Browser support + + Debug works in the browser as well, currently persisted by `localStorage`. For example if you have `worker:a` and `worker:b` as shown below, and wish to debug both type `debug.enable('worker:*')` in the console and refresh the page, this will remain until you disable with `debug.disable()`. + +```js +a = debug('worker:a'); +b = debug('worker:b'); + +setInterval(function(){ + a('doing some work'); +}, 1000); + +setInterval(function(){ + b('doing some work'); +}, 1200); +``` + +#### Web Inspector Colors + + Colors are also enabled on "Web Inspectors" that understand the `%c` formatting + option. These are WebKit web inspectors, Firefox ([since version + 31](https://hacks.mozilla.org/2014/05/editable-box-model-multiple-selection-sublime-text-keys-much-more-firefox-developer-tools-episode-31/)) + and the Firebug plugin for Firefox (any version). + + Colored output looks something like: + + ![](https://cloud.githubusercontent.com/assets/71256/3139768/b98c5fd8-e8ef-11e3-862a-f7253b6f47c6.png) + +### stderr vs stdout + +You can set an alternative logging method per-namespace by overriding the `log` method on a per-namespace or globally: + +Example _stderr.js_: + +```js +var debug = require('../'); +var log = debug('app:log'); + +// by default console.log is used +log('goes to stdout!'); + +var error = debug('app:error'); +// set this namespace to log via console.error +error.log = console.error.bind(console); // don't forget to bind to console! +error('goes to stderr'); +log('still goes to stdout!'); + +// set all output to go via console.warn +// overrides all per-namespace log settings +debug.log = console.warn.bind(console); +log('now goes to stderr via console.warn'); +error('still goes to stderr, but via console.warn now'); +``` + +## Authors + + - TJ Holowaychuk + - Nathan Rajlich + +## License + +(The MIT License) + +Copyright (c) 2014 TJ Holowaychuk <tj@vision-media.ca> + +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/node_modules/debug/browser.js b/node_modules/debug/browser.js new file mode 100644 index 0000000..ce6369f --- /dev/null +++ b/node_modules/debug/browser.js @@ -0,0 +1,147 @@ + +/** + * This is the web browser implementation of `debug()`. + * + * Expose `debug()` as the module. + */ + +exports = module.exports = require('./debug'); +exports.log = log; +exports.formatArgs = formatArgs; +exports.save = save; +exports.load = load; +exports.useColors = useColors; + +/** + * Colors. + */ + +exports.colors = [ + 'lightseagreen', + 'forestgreen', + 'goldenrod', + 'dodgerblue', + 'darkorchid', + 'crimson' +]; + +/** + * Currently only WebKit-based Web Inspectors, Firefox >= v31, + * and the Firebug extension (any Firefox version) are known + * to support "%c" CSS customizations. + * + * TODO: add a `localStorage` variable to explicitly enable/disable colors + */ + +function useColors() { + // is webkit? http://stackoverflow.com/a/16459606/376773 + return ('WebkitAppearance' in document.documentElement.style) || + // is firebug? http://stackoverflow.com/a/398120/376773 + (window.console && (console.firebug || (console.exception && console.table))) || + // is firefox >= v31? + // https://developer.mozilla.org/en-US/docs/Tools/Web_Console#Styling_messages + (navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/) && parseInt(RegExp.$1, 10) >= 31); +} + +/** + * Map %j to `JSON.stringify()`, since no Web Inspectors do that by default. + */ + +exports.formatters.j = function(v) { + return JSON.stringify(v); +}; + + +/** + * Colorize log arguments if enabled. + * + * @api public + */ + +function formatArgs() { + var args = arguments; + var useColors = this.useColors; + + args[0] = (useColors ? '%c' : '') + + this.namespace + + (useColors ? ' %c' : ' ') + + args[0] + + (useColors ? '%c ' : ' ') + + '+' + exports.humanize(this.diff); + + if (!useColors) return args; + + var c = 'color: ' + this.color; + args = [args[0], c, 'color: inherit'].concat(Array.prototype.slice.call(args, 1)); + + // the final "%c" is somewhat tricky, because there could be other + // arguments passed either before or after the %c, so we need to + // figure out the correct index to insert the CSS into + var index = 0; + var lastC = 0; + args[0].replace(/%[a-z%]/g, function(match) { + if ('%%' === match) return; + index++; + if ('%c' === match) { + // we only are interested in the *last* %c + // (the user may have provided their own) + lastC = index; + } + }); + + args.splice(lastC, 0, c); + return args; +} + +/** + * Invokes `console.log()` when available. + * No-op when `console.log` is not a "function". + * + * @api public + */ + +function log() { + // This hackery is required for IE8, + // where the `console.log` function doesn't have 'apply' + return 'object' == typeof console + && 'function' == typeof console.log + && Function.prototype.apply.call(console.log, console, arguments); +} + +/** + * Save `namespaces`. + * + * @param {String} namespaces + * @api private + */ + +function save(namespaces) { + try { + if (null == namespaces) { + localStorage.removeItem('debug'); + } else { + localStorage.debug = namespaces; + } + } catch(e) {} +} + +/** + * Load `namespaces`. + * + * @return {String} returns the previously persisted debug modes + * @api private + */ + +function load() { + var r; + try { + r = localStorage.debug; + } catch(e) {} + return r; +} + +/** + * Enable namespaces listed in `localStorage.debug` initially. + */ + +exports.enable(load()); diff --git a/node_modules/debug/component.json b/node_modules/debug/component.json new file mode 100644 index 0000000..db1ceed --- /dev/null +++ b/node_modules/debug/component.json @@ -0,0 +1,19 @@ +{ + "name": "debug", + "repo": "visionmedia/debug", + "description": "small debugging utility", + "version": "2.0.0", + "keywords": [ + "debug", + "log", + "debugger" + ], + "main": "browser.js", + "scripts": [ + "browser.js", + "debug.js" + ], + "dependencies": { + "guille/ms.js": "0.6.1" + } +} diff --git a/node_modules/debug/debug.js b/node_modules/debug/debug.js new file mode 100644 index 0000000..7571a86 --- /dev/null +++ b/node_modules/debug/debug.js @@ -0,0 +1,197 @@ + +/** + * This is the common logic for both the Node.js and web browser + * implementations of `debug()`. + * + * Expose `debug()` as the module. + */ + +exports = module.exports = debug; +exports.coerce = coerce; +exports.disable = disable; +exports.enable = enable; +exports.enabled = enabled; +exports.humanize = require('ms'); + +/** + * The currently active debug mode names, and names to skip. + */ + +exports.names = []; +exports.skips = []; + +/** + * Map of special "%n" handling functions, for the debug "format" argument. + * + * Valid key names are a single, lowercased letter, i.e. "n". + */ + +exports.formatters = {}; + +/** + * Previously assigned color. + */ + +var prevColor = 0; + +/** + * Previous log timestamp. + */ + +var prevTime; + +/** + * Select a color. + * + * @return {Number} + * @api private + */ + +function selectColor() { + return exports.colors[prevColor++ % exports.colors.length]; +} + +/** + * Create a debugger with the given `namespace`. + * + * @param {String} namespace + * @return {Function} + * @api public + */ + +function debug(namespace) { + + // define the `disabled` version + function disabled() { + } + disabled.enabled = false; + + // define the `enabled` version + function enabled() { + + var self = enabled; + + // set `diff` timestamp + var curr = +new Date(); + var ms = curr - (prevTime || curr); + self.diff = ms; + self.prev = prevTime; + self.curr = curr; + prevTime = curr; + + // add the `color` if not set + if (null == self.useColors) self.useColors = exports.useColors(); + if (null == self.color && self.useColors) self.color = selectColor(); + + var args = Array.prototype.slice.call(arguments); + + args[0] = exports.coerce(args[0]); + + if ('string' !== typeof args[0]) { + // anything else let's inspect with %o + args = ['%o'].concat(args); + } + + // apply any `formatters` transformations + var index = 0; + args[0] = args[0].replace(/%([a-z%])/g, function(match, format) { + // if we encounter an escaped % then don't increase the array index + if (match === '%%') return match; + index++; + var formatter = exports.formatters[format]; + if ('function' === typeof formatter) { + var val = args[index]; + match = formatter.call(self, val); + + // now we need to remove `args[index]` since it's inlined in the `format` + args.splice(index, 1); + index--; + } + return match; + }); + + if ('function' === typeof exports.formatArgs) { + args = exports.formatArgs.apply(self, args); + } + var logFn = enabled.log || exports.log || console.log.bind(console); + logFn.apply(self, args); + } + enabled.enabled = true; + + var fn = exports.enabled(namespace) ? enabled : disabled; + + fn.namespace = namespace; + + return fn; +} + +/** + * Enables a debug mode by namespaces. This can include modes + * separated by a colon and wildcards. + * + * @param {String} namespaces + * @api public + */ + +function enable(namespaces) { + exports.save(namespaces); + + var split = (namespaces || '').split(/[\s,]+/); + var len = split.length; + + for (var i = 0; i < len; i++) { + if (!split[i]) continue; // ignore empty strings + namespaces = split[i].replace(/\*/g, '.*?'); + if (namespaces[0] === '-') { + exports.skips.push(new RegExp('^' + namespaces.substr(1) + '$')); + } else { + exports.names.push(new RegExp('^' + namespaces + '$')); + } + } +} + +/** + * Disable debug output. + * + * @api public + */ + +function disable() { + exports.enable(''); +} + +/** + * Returns true if the given mode name is enabled, false otherwise. + * + * @param {String} name + * @return {Boolean} + * @api public + */ + +function enabled(name) { + var i, len; + for (i = 0, len = exports.skips.length; i < len; i++) { + if (exports.skips[i].test(name)) { + return false; + } + } + for (i = 0, len = exports.names.length; i < len; i++) { + if (exports.names[i].test(name)) { + return true; + } + } + return false; +} + +/** + * Coerce `val`. + * + * @param {Mixed} val + * @return {Mixed} + * @api private + */ + +function coerce(val) { + if (val instanceof Error) return val.stack || val.message; + return val; +} diff --git a/node_modules/debug/node.js b/node_modules/debug/node.js new file mode 100644 index 0000000..db86f64 --- /dev/null +++ b/node_modules/debug/node.js @@ -0,0 +1,129 @@ + +/** + * Module dependencies. + */ + +var tty = require('tty'); +var util = require('util'); + +/** + * This is the Node.js implementation of `debug()`. + * + * Expose `debug()` as the module. + */ + +exports = module.exports = require('./debug'); +exports.log = log; +exports.formatArgs = formatArgs; +exports.save = save; +exports.load = load; +exports.useColors = useColors; + +/** + * Colors. + */ + +exports.colors = [6, 2, 3, 4, 5, 1]; + +/** + * Is stdout a TTY? Colored output is enabled when `true`. + */ + +function useColors() { + var debugColors = (process.env.DEBUG_COLORS || '').trim().toLowerCase(); + if (0 === debugColors.length) { + return tty.isatty(1); + } else { + return '0' !== debugColors + && 'no' !== debugColors + && 'false' !== debugColors + && 'disabled' !== debugColors; + } +} + +/** + * Map %o to `util.inspect()`, since Node doesn't do that out of the box. + */ + +var inspect = (4 === util.inspect.length ? + // node <= 0.8.x + function (v, colors) { + return util.inspect(v, void 0, void 0, colors); + } : + // node > 0.8.x + function (v, colors) { + return util.inspect(v, { colors: colors }); + } +); + +exports.formatters.o = function(v) { + return inspect(v, this.useColors) + .replace(/\s*\n\s*/g, ' '); +}; + +/** + * Adds ANSI color escape codes if enabled. + * + * @api public + */ + +function formatArgs() { + var args = arguments; + var useColors = this.useColors; + var name = this.namespace; + + if (useColors) { + var c = this.color; + + args[0] = ' \u001b[9' + c + 'm' + name + ' ' + + '\u001b[0m' + + args[0] + '\u001b[3' + c + 'm' + + ' +' + exports.humanize(this.diff) + '\u001b[0m'; + } else { + args[0] = new Date().toUTCString() + + ' ' + name + ' ' + args[0]; + } + return args; +} + +/** + * Invokes `console.error()` with the specified arguments. + */ + +function log() { + return console.error.apply(console, arguments); +} + +/** + * Save `namespaces`. + * + * @param {String} namespaces + * @api private + */ + +function save(namespaces) { + if (null == namespaces) { + // If you set a process.env field to null or undefined, it gets cast to the + // string 'null' or 'undefined'. Just delete instead. + delete process.env.DEBUG; + } else { + process.env.DEBUG = namespaces; + } +} + +/** + * Load `namespaces`. + * + * @return {String} returns the previously persisted debug modes + * @api private + */ + +function load() { + return process.env.DEBUG; +} + +/** + * Enable namespaces listed in `process.env.DEBUG` initially. + */ + +exports.enable(load()); diff --git a/node_modules/debug/node_modules/ms/.npmignore b/node_modules/debug/node_modules/ms/.npmignore new file mode 100644 index 0000000..d1aa0ce --- /dev/null +++ b/node_modules/debug/node_modules/ms/.npmignore @@ -0,0 +1,5 @@ +node_modules +test +History.md +Makefile +component.json diff --git a/node_modules/debug/node_modules/ms/README.md b/node_modules/debug/node_modules/ms/README.md new file mode 100644 index 0000000..d4ab12a --- /dev/null +++ b/node_modules/debug/node_modules/ms/README.md @@ -0,0 +1,33 @@ +# ms.js: miliseconds conversion utility + +```js +ms('1d') // 86400000 +ms('10h') // 36000000 +ms('2h') // 7200000 +ms('1m') // 60000 +ms('5s') // 5000 +ms('100') // 100 +``` + +```js +ms(60000) // "1m" +ms(2 * 60000) // "2m" +ms(ms('10 hours')) // "10h" +``` + +```js +ms(60000, { long: true }) // "1 minute" +ms(2 * 60000, { long: true }) // "2 minutes" +ms(ms('10 hours', { long: true })) // "10 hours" +``` + +- Node/Browser compatible. Published as `ms` in NPM. +- If a number is supplied to `ms`, a string with a unit is returned. +- If a string that contains the number is supplied, it returns it as +a number (e.g: it returns `100` for `'100'`). +- If you pass a string with a number and a valid unit, the number of +equivalent ms is returned. + +## License + +MIT \ No newline at end of file diff --git a/node_modules/debug/node_modules/ms/index.js b/node_modules/debug/node_modules/ms/index.js new file mode 100644 index 0000000..c5847f8 --- /dev/null +++ b/node_modules/debug/node_modules/ms/index.js @@ -0,0 +1,111 @@ +/** + * Helpers. + */ + +var s = 1000; +var m = s * 60; +var h = m * 60; +var d = h * 24; +var y = d * 365.25; + +/** + * Parse or format the given `val`. + * + * Options: + * + * - `long` verbose formatting [false] + * + * @param {String|Number} val + * @param {Object} options + * @return {String|Number} + * @api public + */ + +module.exports = function(val, options){ + options = options || {}; + if ('string' == typeof val) return parse(val); + return options.long + ? long(val) + : short(val); +}; + +/** + * Parse the given `str` and return milliseconds. + * + * @param {String} str + * @return {Number} + * @api private + */ + +function parse(str) { + var match = /^((?:\d+)?\.?\d+) *(ms|seconds?|s|minutes?|m|hours?|h|days?|d|years?|y)?$/i.exec(str); + if (!match) return; + var n = parseFloat(match[1]); + var type = (match[2] || 'ms').toLowerCase(); + switch (type) { + case 'years': + case 'year': + case 'y': + return n * y; + case 'days': + case 'day': + case 'd': + return n * d; + case 'hours': + case 'hour': + case 'h': + return n * h; + case 'minutes': + case 'minute': + case 'm': + return n * m; + case 'seconds': + case 'second': + case 's': + return n * s; + case 'ms': + return n; + } +} + +/** + * Short format for `ms`. + * + * @param {Number} ms + * @return {String} + * @api private + */ + +function short(ms) { + if (ms >= d) return Math.round(ms / d) + 'd'; + if (ms >= h) return Math.round(ms / h) + 'h'; + if (ms >= m) return Math.round(ms / m) + 'm'; + if (ms >= s) return Math.round(ms / s) + 's'; + return ms + 'ms'; +} + +/** + * Long format for `ms`. + * + * @param {Number} ms + * @return {String} + * @api private + */ + +function long(ms) { + return plural(ms, d, 'day') + || plural(ms, h, 'hour') + || plural(ms, m, 'minute') + || plural(ms, s, 'second') + || ms + ' ms'; +} + +/** + * Pluralization helper. + */ + +function plural(ms, n, name) { + if (ms < n) return; + if (ms < n * 1.5) return Math.floor(ms / n) + ' ' + name; + return Math.ceil(ms / n) + ' ' + name + 's'; +} diff --git a/node_modules/debug/node_modules/ms/package.json b/node_modules/debug/node_modules/ms/package.json new file mode 100644 index 0000000..96d29fd --- /dev/null +++ b/node_modules/debug/node_modules/ms/package.json @@ -0,0 +1,45 @@ +{ + "name": "ms", + "version": "0.6.2", + "description": "Tiny ms conversion utility", + "repository": { + "type": "git", + "url": "git://github.com/guille/ms.js.git" + }, + "main": "./index", + "devDependencies": { + "mocha": "*", + "expect.js": "*", + "serve": "*" + }, + "component": { + "scripts": { + "ms/index.js": "index.js" + } + }, + "readme": "# ms.js: miliseconds conversion utility\n\n```js\nms('1d') // 86400000\nms('10h') // 36000000\nms('2h') // 7200000\nms('1m') // 60000\nms('5s') // 5000\nms('100') // 100\n```\n\n```js\nms(60000) // \"1m\"\nms(2 * 60000) // \"2m\"\nms(ms('10 hours')) // \"10h\"\n```\n\n```js\nms(60000, { long: true }) // \"1 minute\"\nms(2 * 60000, { long: true }) // \"2 minutes\"\nms(ms('10 hours', { long: true })) // \"10 hours\"\n```\n\n- Node/Browser compatible. Published as `ms` in NPM.\n- If a number is supplied to `ms`, a string with a unit is returned.\n- If a string that contains the number is supplied, it returns it as\na number (e.g: it returns `100` for `'100'`).\n- If you pass a string with a number and a valid unit, the number of\nequivalent ms is returned.\n\n## License\n\nMIT", + "readmeFilename": "README.md", + "bugs": { + "url": "https://github.com/guille/ms.js/issues" + }, + "_id": "ms@0.6.2", + "dist": { + "shasum": "d89c2124c6fdc1353d65a8b77bf1aac4b193708c", + "tarball": "http://registry.npmjs.org/ms/-/ms-0.6.2.tgz" + }, + "_from": "ms@0.6.2", + "_npmVersion": "1.2.30", + "_npmUser": { + "name": "rauchg", + "email": "rauchg@gmail.com" + }, + "maintainers": [ + { + "name": "rauchg", + "email": "rauchg@gmail.com" + } + ], + "directories": {}, + "_shasum": "d89c2124c6fdc1353d65a8b77bf1aac4b193708c", + "_resolved": "https://registry.npmjs.org/ms/-/ms-0.6.2.tgz" +} diff --git a/node_modules/debug/package.json b/node_modules/debug/package.json new file mode 100644 index 0000000..f516035 --- /dev/null +++ b/node_modules/debug/package.json @@ -0,0 +1,71 @@ +{ + "name": "debug", + "version": "2.0.0", + "repository": { + "type": "git", + "url": "git://github.com/visionmedia/debug.git" + }, + "description": "small debugging utility", + "keywords": [ + "debug", + "log", + "debugger" + ], + "author": { + "name": "TJ Holowaychuk", + "email": "tj@vision-media.ca" + }, + "contributors": [ + { + "name": "Nathan Rajlich", + "email": "nathan@tootallnate.net", + "url": "http://n8.io" + } + ], + "dependencies": { + "ms": "0.6.2" + }, + "devDependencies": { + "browserify": "5.11.0", + "mocha": "*" + }, + "main": "./node.js", + "browser": "./browser.js", + "component": { + "scripts": { + "debug/index.js": "browser.js", + "debug/debug.js": "debug.js" + } + }, + "gitHead": "c61ae82bde19c6fdedfc6684817ff7eb541ff029", + "bugs": { + "url": "https://github.com/visionmedia/debug/issues" + }, + "homepage": "https://github.com/visionmedia/debug", + "_id": "debug@2.0.0", + "scripts": {}, + "_shasum": "89bd9df6732b51256bc6705342bba02ed12131ef", + "_from": "debug@2.0.0", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "tootallnate", + "email": "nathan@tootallnate.net" + }, + "maintainers": [ + { + "name": "tjholowaychuk", + "email": "tj@vision-media.ca" + }, + { + "name": "tootallnate", + "email": "nathan@tootallnate.net" + } + ], + "dist": { + "shasum": "89bd9df6732b51256bc6705342bba02ed12131ef", + "tarball": "http://registry.npmjs.org/debug/-/debug-2.0.0.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/debug/-/debug-2.0.0.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/dust/.npmignore b/node_modules/dust/.npmignore new file mode 100644 index 0000000..00495dc --- /dev/null +++ b/node_modules/dust/.npmignore @@ -0,0 +1 @@ +/nbproject \ No newline at end of file diff --git a/node_modules/dust/LICENSE b/node_modules/dust/LICENSE new file mode 100644 index 0000000..1c59043 --- /dev/null +++ b/node_modules/dust/LICENSE @@ -0,0 +1,19 @@ +Copyright (c) 2010 Aleksander Williams + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. \ No newline at end of file diff --git a/node_modules/dust/Makefile b/node_modules/dust/Makefile new file mode 100644 index 0000000..46cd327 --- /dev/null +++ b/node_modules/dust/Makefile @@ -0,0 +1,78 @@ +# +# Run all tests +# +test: + node test/server.js + +# +# Run the benchmarks +# +bench: + node benchmark/server.js + +# +# Build the docs +# +docs: + node docs/build.js + +# +# Build the parser +# +parser: + node src/build.js + +# +# Build dust.js +# + +SRC = lib +VERSION = ${shell cat package.json | grep version | grep -o '[0-9]\.[0-9]\.[0-9]\+'} +CORE = dist/dust-core-${VERSION}.js +CORE_MIN = dist/dust-core-${VERSION}.min.js +FULL = dist/dust-full-${VERSION}.js +FULL_MIN = dist/dust-full-${VERSION}.min.js + +define HEADER +// +// Dust - Asynchronous Templating v${VERSION} +// http://akdubya.github.com/dustjs +// +// Copyright (c) 2010, Aleksander Williams +// Released under the MIT License. +// + +endef + +export HEADER + +dust: + @@mkdir -p dist + @@touch ${CORE} + @@echo "$$HEADER" > ${CORE} + @@cat ${SRC}/dust.js >> ${CORE} + @@echo ${CORE} built + @@touch ${FULL} + @@echo "$$HEADER" > ${FULL} + @@cat ${SRC}/dust.js\ + ${SRC}/compiler.js\ + ${SRC}/parser.js >> ${FULL} + @@echo ${FULL} built + +min: dust + @@echo minifying... + @@echo "$$HEADER" > ${CORE_MIN} + @@echo "$$HEADER" > ${FULL_MIN} + @@minmin ${CORE} >> ${CORE_MIN} + @@minmin ${FULL} >> ${FULL_MIN} + +clean: + git rm dist/* + +release: clean docs min + git add dist/* + git commit -a -m "release v${VERSION}" + git tag -a -m "version v${VERSION}" v${VERSION} + npm publish + +.PHONY: test docs bench parser \ No newline at end of file diff --git a/node_modules/dust/README.md b/node_modules/dust/README.md new file mode 100644 index 0000000..e18180b --- /dev/null +++ b/node_modules/dust/README.md @@ -0,0 +1,51 @@ +Dust +==== + +> Asynchronous templates for the browser and node.js + +#### # + +Why? +---- + +I like [Mustache](http://mustache.github.com) and variants but none of them offers quite what I need. + +Use Dust if you want these things: + +* async/streaming operation +* browser/node compatibility +* extended Mustache/ctemplate syntax +* clean, low-level API +* [high performance](http://akdubya.github.com/dustjs/benchmark/index.html) +* composable templates + +Composable templates? +--------------------- + + {^xhr} + {>base_template/} + {:else} + {+main/} + {/xhr} + { + +Demo & Guide +------------ + +Extensive docs and a full demo are available at \ No newline at end of file diff --git a/node_modules/dust/TODO b/node_modules/dust/TODO new file mode 100644 index 0000000..f9a3f86 --- /dev/null +++ b/node_modules/dust/TODO @@ -0,0 +1,3 @@ +- Optimize static strings +- Improve interface to compile options (formatting, etc.) +- Refactor compiler \ No newline at end of file diff --git a/node_modules/dust/benchmark/index.html b/node_modules/dust/benchmark/index.html new file mode 100644 index 0000000..529cd90 --- /dev/null +++ b/node_modules/dust/benchmark/index.html @@ -0,0 +1,161 @@ + + + + shootout + + + + + + +
+
+ +
+ +
+
+

Targets: Dust, Handlebars, Mustache, jquery-tmpl. Each benchmark runs once using an adaptive test cycles algorithm similar to the one found in jslitmus.

+
+ + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/node_modules/dust/benchmark/server.js b/node_modules/dust/benchmark/server.js new file mode 100644 index 0000000..72ec2d4 --- /dev/null +++ b/node_modules/dust/benchmark/server.js @@ -0,0 +1,33 @@ +var uubench = require('./uubench'), + dust = require('../lib/dust'), + dustBench = require('./suites/dust_suite').dustBench; + +uubench.nextTick = process.nextTick; + +var suite = new uubench.Suite({ + iterations: 10000, + result: function(name, stats) { + var opms = stats.iterations/stats.elapsed; + console.log(pad(12, name + ": "), pad(5, Math.round(opms), true)); + } +}); + +function pad(amt, val, pre) { + val = String(val); + var len = amt - val.length, out = ''; + for (var i=0; ireplace/}{/peeps}", + context: { peeps: [ + { name: "Moe", count: 15 }, + { name: "Larry", count: 5 }, + { name: "Curly", count: 0 } + ] + } + }, + + recursion: { + source: "{name}{#kids}{>recursion:./}{/kids}", + context: { + name: '1', + kids: [ + { + name: '1.1', + kids: [ + {name: '1.1.1'} + ] + } + ] + } + }, + + filter: { + source: "{#filter}foo {bar}{/filter}", + context: { + filter: function(chunk, context, bodies) { + return chunk.tap(function(data) { + return data.toUpperCase(); + }).render(bodies.block, context).untap(); + }, + bar: "bar" + } + }, + + complex: { + source: "

{header}

\n" + + "{?items}\n" + + "
    \n" + + " {#items}\n" + + " {#current}\n" + + "
  • {name}
  • \n" + + " {:else}\n" + + "
  • {name}
  • \n" + + " {/current}\n" + + " {/items}\n" + + "
\n" + + "{:else}\n" + + "

The list is empty.

\n" + + "{/items}", + context: { + header: function() { + return "Colors"; + }, + items: [ + {name: "red", current: true, url: "#Red"}, + {name: "green", current: false, url: "#Green"}, + {name: "blue", current: false, url: "#Blue"} + ] + } + } + +} + +exports.dustBench = function(suite, name, id) { + var bench = benches[name], + ctx = bench.context; + + dust.loadSource(dust.compile(bench.source, name)); + suite.bench(id || name, function(next) { + dust.render(name, ctx, function() { + next(); + }); + }); +}; + +exports.dustBench.benches = benches; + +})(typeof exports !== "undefined" ? exports : window); \ No newline at end of file diff --git a/node_modules/dust/benchmark/suites/handlebars_suite.js b/node_modules/dust/benchmark/suites/handlebars_suite.js new file mode 100644 index 0000000..ae0c88d --- /dev/null +++ b/node_modules/dust/benchmark/suites/handlebars_suite.js @@ -0,0 +1,101 @@ +(function(exports){ + +var benches = { + + string: { + source: "Hello World!", + context: {} + }, + + replace: { + source: "Hello {{name}}! You have {{count}} new messages.", + context: { name: "Mick", count: 30 } + }, + + array: { + source: "{{#names}}{{name}}{{/names}}", + context: { names: [{name: "Moe"}, {name: "Larry"}, {name: "Curly"}, {name: "Shemp"}] } + }, + + object: { + source: "{{#person}}{{name}}{{age}}{{/person}}", + context: { person: { name: "Larry", age: 45 } } + }, + + partial: { + source: "{{#peeps}}{{>replace}}{{/peeps}}", + context: { peeps: [{name: "Moe", count: 15}, {name: "Larry", count: 5}, {name: "Curly", count: 1}] }, + partials: { replace: "Hello {{name}}! You have {{count}} new messages." } + }, + + recursion: { + source: "{{name}}{{#kids}}{{>recursion}}{{/kids}}", + context: { + name: '1', + kids: [ + { + name: '1.1', + kids: [ + {name: '1.1.1'} + ] + } + ] + }, + partials: { recursion: "{{name}}{{#kids}}{{>recursion}}{{/kids}}" } + }, + + filter: { + source: "{{#filter}}foo {{bar}}{{/filter}}", + context: { + filter: function(ctx, fn) { + return fn(ctx).toUpperCase(); + }, + bar: "bar" + } + }, + + complex: { + source: "

{{header}}

{{#hasItems}}
    {{#items}}{{#current}}" + + "
  • {{name}}
  • {{/current}}{{^current}}" + + "
  • {{name}}
  • {{/current}}" + + "{{/items}}
{{^}}

The list is empty.

{{/hasItems}}", + context: { + header: function() { + return "Colors"; + }, + items: [ + {name: "red", current: true, url: "#Red"}, + {name: "green", current: false, url: "#Green"}, + {name: "blue", current: false, url: "#Blue"} + ], + hasItems: function(ctx, fn) { + if (ctx.items.length) { + return fn(ctx); + } + } + } + } + +} + +exports.handlebarsBench = function(suite, name, id) { + var bench = benches[name], + fn = Handlebars.compile(bench.source), + ctx = bench.context, + partials = {}; + + if (bench.partials) { + for (var key in bench.partials) { + partials[key] = Handlebars.compile(bench.partials[key]); + } + } + + suite.bench(id || name, function(next) { + fn(ctx, {partials: partials}); + next(); + }); +} + +exports.handlebarsBench.benches = benches; + +})(typeof exports !== "undefined" ? exports : window); \ No newline at end of file diff --git a/node_modules/dust/benchmark/suites/jquery_suite.js b/node_modules/dust/benchmark/suites/jquery_suite.js new file mode 100644 index 0000000..ee426b7 --- /dev/null +++ b/node_modules/dust/benchmark/suites/jquery_suite.js @@ -0,0 +1,84 @@ +(function(exports){ + +var benches = { + + string: { + source: "Hello World!", + context: {} + }, + + replace: { + source: "Hello ${name}! You have ${count} new messages.", + context: { name: "Mick", count: 30 } + }, + + array: { + source: "{{each names}}${name}{{/each}}", + context: { names: [{name: "Moe"}, {name: "Larry"}, {name: "Curly"}, {name: "Shemp"}] } + }, + + object: { + source: "${person.name}${person.age}", + context: { person: { name: "Larry", age: 45 } } + }, + + partial: { + source: "{{tmpl(peeps) \"replace\"}}", + context: { peeps: [{name: "Moe", count: 15}, {name: "Larry", count: 5}, {name: "Curly", count: 1}] } + }, + + recursion: { + source: "${name}{{tmpl(kids) \"recursion\"}}", + context: { + name: '1', + kids: [ + { + name: '1.1', + kids: [ + {name: '1.1.1', kids: []} + ] + } + ] + } + }, + + filter: { + source: "FOO ${bar.toUpperCase()}", + context: { + bar: "bar" + } + }, + + complex: { + source: "

${header}

{{if items.length}}
    {{each items}}{{if current}}" + + "
  • ${name}
  • {{else}}" + + "
  • ${name}
  • {{/if}}" + + "{{/each}}
{{else}}

The list is empty.

{{/if}}", + context: { + header: function() { + return "Colors"; + }, + items: [ + {name: "red", current: true, url: "#Red"}, + {name: "green", current: false, url: "#Green"}, + {name: "blue", current: false, url: "#Blue"} + ] + } + } + +} + +exports.jqueryBench = function(suite, name, id) { + var bench = benches[name], + fn = $.template(name, bench.source), + ctx = bench.context; + + suite.bench(id || name, function(next) { + $.tmpl(fn, ctx); + next(); + }); +} + +exports.jqueryBench.benches = benches; + +})(typeof exports !== "undefined" ? exports : window); \ No newline at end of file diff --git a/node_modules/dust/benchmark/suites/mustache_suite.js b/node_modules/dust/benchmark/suites/mustache_suite.js new file mode 100644 index 0000000..b2aa9c9 --- /dev/null +++ b/node_modules/dust/benchmark/suites/mustache_suite.js @@ -0,0 +1,97 @@ +(function(exports){ + +var benches = { + + string: { + source: "Hello World!", + context: {} + }, + + replace: { + source: "Hello {{name}}! You have {{count}} new messages.", + context: { name: "Mick", count: 30 } + }, + + array: { + source: "{{#names}}{{name}}{{/names}}", + context: { names: [{name: "Moe"}, {name: "Larry"}, {name: "Curly"}, {name: "Shemp"}] } + }, + + object: { + source: "{{#person}}{{name}}{{age}}{{/person}}", + context: { person: { name: "Larry", age: 45 } } + }, + + partial: { + source: "{{#peeps}}{{>replace}}{{/peeps}}", + context: { peeps: [{name: "Moe", count: 15}, {name: "Larry", count: 5}, {name: "Curly", count: 1}] }, + partials: { replace: "Hello {{name}}! You have {{count}} new messages." } + }, + + recursion: { + source: "{{name}}{{#kids}}{{>recursion}}{{/kids}}", + context: { + name: '1', + kids: [ + { + name: '1.1', + kids: [ + {name: '1.1.1', kids: []} + ] + } + ] + }, + partials: { recursion: "{{name}}{{#kids}}{{>recursion}}{{/kids}}" } + }, + + filter: { + source: "{{#filter}}foo {{bar}}{{/filter}}", + context: { + filter: function() { + return function(text, render) { + return render(text).toUpperCase(); + } + }, + bar: "bar" + } + }, + + complex: { + source: "

{{header}}

{{#hasItems}}
    {{#items}}{{#current}}" + + "
  • {{name}}
  • {{/current}}{{^current}}" + + "
  • {{name}}
  • {{/current}}" + + "{{/items}}
{{/hasItems}}{{^hasItems}}

The list is empty.

{{/hasItems}}", + context: { + header: function() { + return "Colors"; + }, + items: [ + {name: "red", current: true, url: "#Red"}, + {name: "green", current: false, url: "#Green"}, + {name: "blue", current: false, url: "#Blue"} + ], + hasItems: function() { + return this.items.length !== 0; + }, + empty: function() { + return this.items.length === 0; + } + } + } +} + +exports.mustacheBench = function(suite, name, id) { + var bench = benches[name], + src = bench.source, + ctx = bench.context, + partials = bench.partials; + + suite.bench(id || name, function(next) { + Mustache.to_html(src, ctx, partials); + next(); + }); +} + +exports.mustacheBench.benches = benches; + +})(typeof exports !== "undefined" ? exports : window); \ No newline at end of file diff --git a/node_modules/dust/benchmark/uubench.js b/node_modules/dust/benchmark/uubench.js new file mode 100644 index 0000000..b4004a3 --- /dev/null +++ b/node_modules/dust/benchmark/uubench.js @@ -0,0 +1,107 @@ +(function(uubench){ + +function Bench(id, test, options, callback) { + this.id = id; + this.options = options; + this.test = test; + this.loop = test.length > 1; + this.callback = callback; +} + +Bench.prototype.run = function(iter) { + var self = this, fn = self.test, + checkfn = self.options.type === "adaptive" ? adaptive : fixed, + i = iter, pend = i, + min = self.options.min, start; + + if (self.loop) { + pend = 1; + start = new Date(); + fn(checkfn, i); + } else { + start = new Date(); + while (i--) { + fn(checkfn); + } + } + + function fixed() { + if (--pend === 0) { + var elapsed = new Date() - start; + self.callback({iterations: iter, elapsed: elapsed}); + } + } + + function adaptive() { + if (--pend === 0) { + var elapsed = new Date() - start; + if (elapsed < min) { + self.run(iter*2); + } else { + self.callback({iterations: iter, elapsed: elapsed}); + } + } + } +} + +uubench.Bench = Bench; + +uubench.defaults = { + type: "adaptive", // adaptive or fixed + iterations: 10, // starting iterations + min: 100, // minimum run time (ms) - adaptive only + delay: 100 // delay between tests (ms) +} + +function Suite(opts) { + for (var key in uubench.defaults) { + if (opts[key] === undefined) { + opts[key] = uubench.defaults[key]; + } + } + this.options = opts; + this.tests = []; +} + +Suite.prototype.bench = function(name, fn) { + var self = this; + self.tests.push(new Bench(name, fn, this.options, function(stats) { + self.emit("result", name, stats); + self.pending--; + self.check(); + })); +} + +Suite.prototype.run = function() { + if (this.pending) return; + var self = this, len = self.tests.length; + self.emit("start", self.tests); + self.start = new Date().getTime(); + self.pending = len; + for (var i=0; i\"]/), + AMP = /&/g, + LT = //g, + QUOT = /\"/g; + +dust.escapeHtml = function(s) { + if (typeof s === "string") { + if (!HCHARS.test(s)) { + return s; + } + return s.replace(AMP,'&').replace(LT,'<').replace(GT,'>').replace(QUOT,'"'); + } + return s; +}; + +var BS = /\\/g, + CR = /\r/g, + LS = /\u2028/g, + PS = /\u2029/g, + NL = /\n/g, + LF = /\f/g, + SQ = /'/g, + DQ = /"/g, + TB = /\t/g; + +dust.escapeJs = function(s) { + if (typeof s === "string") { + return s + .replace(BS, '\\\\') + .replace(DQ, '\\"') + .replace(SQ, "\\'") + .replace(CR, '\\r') + .replace(LS, '\\u2028') + .replace(PS, '\\u2029') + .replace(NL, '\\n') + .replace(LF, '\\f') + .replace(TB, "\\t"); + } + return s; +}; + +})(dust); + +if (typeof exports !== "undefined") { + if (typeof process !== "undefined") { + require('./server')(dust); + } + module.exports = dust; +} diff --git a/node_modules/dust/dist/dust-core-0.3.0.min.js b/node_modules/dust/dist/dust-core-0.3.0.min.js new file mode 100644 index 0000000..cab380b --- /dev/null +++ b/node_modules/dust/dist/dust-core-0.3.0.min.js @@ -0,0 +1,21 @@ +// +// Dust - Asynchronous Templating v0.3.0 +// http://akdubya.github.com/dustjs +// +// Copyright (c) 2010, Aleksander Williams +// Released under the MIT License. +// + +var dust={}; +(function(d){function h(a,b,c){this.stack=a;this.global=b;this.blocks=c}function k(a,b,c,e){this.tail=b;this.isObject=!d.isArray(a)&&a&&typeof a==="object";this.head=a;this.index=c;this.of=e}function l(a){this.head=new f(this);this.callback=a;this.out=""}function j(){this.head=new f(this)}function f(a,b,c){this.root=a;this.next=b;this.data="";this.flushable=false;this.taps=c}function m(a,b){this.head=a;this.tail=b}d.cache={};d.register=function(a,b){if(a)d.cache[a]=b};d.render=function(a,b,c){c=(new l(c)).head; +d.load(a,c,h.wrap(b)).end()};d.stream=function(a,b){var c=new j;d.nextTick(function(){d.load(a,c.head,h.wrap(b)).end()});return c};d.renderSource=function(a,b,c){return d.compileFn(a)(b,c)};d.compileFn=function(a,b){var c=d.loadSource(d.compile(a,b));return function(e,g){var i=g?new l(g):new j;d.nextTick(function(){c(i.head,h.wrap(e)).end()});return i}};d.load=function(a,b,c){var e=d.cache[a];if(e)return e(b,c);else{if(d.onLoad)return b.map(function(g){d.onLoad(a,function(i,n){if(i)return g.setError(i); +d.cache[a]||d.loadSource(d.compile(n,a));d.cache[a](g,c).end()})});return b.setError(Error("Template Not Found: "+a))}};d.loadSource=function(a){return eval(a)};d.isArray=Array.isArray?Array.isArray:function(a){return Object.prototype.toString.call(a)=="[object Array]"};d.nextTick=function(a){setTimeout(a,0)};d.isEmpty=function(a){if(d.isArray(a)&&!a.length)return true;if(a===0)return false;return!a};d.filter=function(a,b,c){if(c)for(var e=0,g=c.length;e\"]/),p=/&/g,q=//g,s=/\"/g;d.escapeHtml=function(a){if(typeof a==="string"){if(!o.test(a))return a;return a.replace(p,"&").replace(q,"<").replace(r,">").replace(s,""")}return a}; +var t=/\\/g,u=/\r/g,v=/\u2028/g,w=/\u2029/g,x=/\n/g,y=/\f/g,z=/'/g,A=/"/g,B=/\t/g;d.escapeJs=function(a){if(typeof a==="string")return a.replace(t,"\\\\").replace(A,'\\"').replace(z,"\\'").replace(u,"\\r").replace(v,"\\u2028").replace(w,"\\u2029").replace(x,"\\n").replace(y,"\\f").replace(B,"\\t");return a}})(dust);if(typeof exports!=="undefined"){typeof process!=="undefined"&&require("./server")(dust);module.exports=dust}; diff --git a/node_modules/dust/dist/dust-full-0.3.0.js b/node_modules/dust/dist/dust-full-0.3.0.js new file mode 100644 index 0000000..6d7bdae --- /dev/null +++ b/node_modules/dust/dist/dust-full-0.3.0.js @@ -0,0 +1,3209 @@ +// +// Dust - Asynchronous Templating v0.3.0 +// http://akdubya.github.com/dustjs +// +// Copyright (c) 2010, Aleksander Williams +// Released under the MIT License. +// + +var dust = {}; + +(function(dust) { + +dust.cache = {}; + +dust.register = function(name, tmpl) { + if (!name) return; + dust.cache[name] = tmpl; +}; + +dust.render = function(name, context, callback) { + var chunk = new Stub(callback).head; + dust.load(name, chunk, Context.wrap(context)).end(); +}; + +dust.stream = function(name, context) { + var stream = new Stream(); + dust.nextTick(function() { + dust.load(name, stream.head, Context.wrap(context)).end(); + }); + return stream; +}; + +dust.renderSource = function(source, context, callback) { + return dust.compileFn(source)(context, callback); +}; + +dust.compileFn = function(source, name) { + var tmpl = dust.loadSource(dust.compile(source, name)); + return function(context, callback) { + var master = callback ? new Stub(callback) : new Stream(); + dust.nextTick(function() { + tmpl(master.head, Context.wrap(context)).end(); + }); + return master; + } +}; + +dust.load = function(name, chunk, context) { + var tmpl = dust.cache[name]; + if (tmpl) { + return tmpl(chunk, context); + } else { + if (dust.onLoad) { + return chunk.map(function(chunk) { + dust.onLoad(name, function(err, src) { + if (err) return chunk.setError(err); + if (!dust.cache[name]) dust.loadSource(dust.compile(src, name)); + dust.cache[name](chunk, context).end(); + }); + }); + } + return chunk.setError(new Error("Template Not Found: " + name)); + } +}; + +dust.loadSource = function(source, path) { + return eval(source); +}; + +if (Array.isArray) { + dust.isArray = Array.isArray; +} else { + dust.isArray = function(arr) { + return Object.prototype.toString.call(arr) == "[object Array]"; + }; +} + +dust.nextTick = function(callback) { + setTimeout(callback, 0); +} + +dust.isEmpty = function(value) { + if (dust.isArray(value) && !value.length) return true; + if (value === 0) return false; + return (!value); +}; + +dust.filter = function(string, auto, filters) { + if (filters) { + for (var i=0, len=filters.length; i\"]/), + AMP = /&/g, + LT = //g, + QUOT = /\"/g; + +dust.escapeHtml = function(s) { + if (typeof s === "string") { + if (!HCHARS.test(s)) { + return s; + } + return s.replace(AMP,'&').replace(LT,'<').replace(GT,'>').replace(QUOT,'"'); + } + return s; +}; + +var BS = /\\/g, + CR = /\r/g, + LS = /\u2028/g, + PS = /\u2029/g, + NL = /\n/g, + LF = /\f/g, + SQ = /'/g, + DQ = /"/g, + TB = /\t/g; + +dust.escapeJs = function(s) { + if (typeof s === "string") { + return s + .replace(BS, '\\\\') + .replace(DQ, '\\"') + .replace(SQ, "\\'") + .replace(CR, '\\r') + .replace(LS, '\\u2028') + .replace(PS, '\\u2029') + .replace(NL, '\\n') + .replace(LF, '\\f') + .replace(TB, "\\t"); + } + return s; +}; + +})(dust); + +if (typeof exports !== "undefined") { + if (typeof process !== "undefined") { + require('./server')(dust); + } + module.exports = dust; +} +(function(dust) { + +dust.compile = function(source, name) { + var ast = filterAST(dust.parse(source)); + return compile(ast, name); +}; + +function filterAST(ast) { + var context = {}; + return dust.filterNode(context, ast); +} + +dust.filterNode = function(context, node) { + return dust.optimizers[node[0]](context, node); +} + +dust.optimizers = { + body: compactBuffers, + buffer: noop, + special: convertSpecial, + format: nullify, // TODO: convert format + reference: visit, + "#": visit, + "?": visit, + "^": visit, + "<": visit, + "+": visit, + "@": visit, + "%": visit, + partial: visit, + context: visit, + params: visit, + bodies: visit, + param: visit, + filters: noop, + key: noop, + path: noop, + literal: noop, + comment: nullify +} + +dust.pragmas = { + esc: function(compiler, context, bodies, params) { + var old = compiler.auto; + if (!context) context = 'h'; + compiler.auto = (context === 's') ? '' : context; + var out = compileParts(compiler, bodies.block); + compiler.auto = old; + return out; + } +} + +function visit(context, node) { + var out = [node[0]]; + for (var i=1, len=node.length; i rightmostMatchFailuresPos) { + rightmostMatchFailuresPos = pos; + rightmostMatchFailuresExpected = []; + } + + rightmostMatchFailuresExpected.push(failure); + } + + function parse_body() { + var cacheKey = "body" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + + var result1 = []; + var result2 = parse_part(); + while (result2 !== null) { + result1.push(result2); + var result2 = parse_part(); + } + var result0 = result1 !== null + ? (function(p) { return ["body"].concat(p) })(result1) + : null; + + + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_part() { + var cacheKey = "part" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + + var result6 = parse_comment(); + if (result6 !== null) { + var result0 = result6; + } else { + var result5 = parse_section(); + if (result5 !== null) { + var result0 = result5; + } else { + var result4 = parse_partial(); + if (result4 !== null) { + var result0 = result4; + } else { + var result3 = parse_special(); + if (result3 !== null) { + var result0 = result3; + } else { + var result2 = parse_reference(); + if (result2 !== null) { + var result0 = result2; + } else { + var result1 = parse_buffer(); + if (result1 !== null) { + var result0 = result1; + } else { + var result0 = null;; + }; + }; + }; + }; + }; + } + + + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_section() { + var cacheKey = "section" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + var savedReportMatchFailures = reportMatchFailures; + reportMatchFailures = false; + var savedPos1 = pos; + var result8 = parse_sec_tag_start(); + if (result8 !== null) { + var result9 = parse_rd(); + if (result9 !== null) { + var result10 = parse_body(); + if (result10 !== null) { + var result11 = parse_bodies(); + if (result11 !== null) { + var result12 = parse_end_tag(); + if (result12 !== null) { + var result13 = (function() {return result8[1].text === result12.text})() ? '' : null; + if (result13 !== null) { + var result7 = [result8, result9, result10, result11, result12, result13]; + } else { + var result7 = null; + pos = savedPos1; + } + } else { + var result7 = null; + pos = savedPos1; + } + } else { + var result7 = null; + pos = savedPos1; + } + } else { + var result7 = null; + pos = savedPos1; + } + } else { + var result7 = null; + pos = savedPos1; + } + } else { + var result7 = null; + pos = savedPos1; + } + var result6 = result7 !== null + ? (function(t, b, e, n) { e.push(["param", ["literal", "block"], b]); t.push(e); return t })(result7[0], result7[2], result7[3], result7[4]) + : null; + if (result6 !== null) { + var result0 = result6; + } else { + var savedPos0 = pos; + var result3 = parse_sec_tag_start(); + if (result3 !== null) { + if (input.substr(pos, 1) === "/") { + var result4 = "/"; + pos += 1; + } else { + var result4 = null; + if (reportMatchFailures) { + matchFailed("\"/\""); + } + } + if (result4 !== null) { + var result5 = parse_rd(); + if (result5 !== null) { + var result2 = [result3, result4, result5]; + } else { + var result2 = null; + pos = savedPos0; + } + } else { + var result2 = null; + pos = savedPos0; + } + } else { + var result2 = null; + pos = savedPos0; + } + var result1 = result2 !== null + ? (function(t) { t.push(["bodies"]); return t })(result2[0]) + : null; + if (result1 !== null) { + var result0 = result1; + } else { + var result0 = null;; + }; + } + reportMatchFailures = savedReportMatchFailures; + if (reportMatchFailures && result0 === null) { + matchFailed("section"); + } + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_sec_tag_start() { + var cacheKey = "sec_tag_start" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + + var savedPos0 = pos; + var result2 = parse_ld(); + if (result2 !== null) { + if (input.substr(pos).match(/^[#?^<+@%]/) !== null) { + var result3 = input.charAt(pos); + pos++; + } else { + var result3 = null; + if (reportMatchFailures) { + matchFailed("[#?^<+@%]"); + } + } + if (result3 !== null) { + var result4 = parse_identifier(); + if (result4 !== null) { + var result5 = parse_context(); + if (result5 !== null) { + var result6 = parse_params(); + if (result6 !== null) { + var result1 = [result2, result3, result4, result5, result6]; + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + var result0 = result1 !== null + ? (function(t, n, c, p) { return [t, n, c, p] })(result1[1], result1[2], result1[3], result1[4]) + : null; + + + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_end_tag() { + var cacheKey = "end_tag" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + var savedReportMatchFailures = reportMatchFailures; + reportMatchFailures = false; + var savedPos0 = pos; + var result2 = parse_ld(); + if (result2 !== null) { + if (input.substr(pos, 1) === "/") { + var result3 = "/"; + pos += 1; + } else { + var result3 = null; + if (reportMatchFailures) { + matchFailed("\"/\""); + } + } + if (result3 !== null) { + var result4 = parse_identifier(); + if (result4 !== null) { + var result5 = parse_rd(); + if (result5 !== null) { + var result1 = [result2, result3, result4, result5]; + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + var result0 = result1 !== null + ? (function(n) { return n })(result1[2]) + : null; + reportMatchFailures = savedReportMatchFailures; + if (reportMatchFailures && result0 === null) { + matchFailed("end tag"); + } + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_context() { + var cacheKey = "context" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + + var savedPos0 = pos; + if (input.substr(pos, 1) === ":") { + var result4 = ":"; + pos += 1; + } else { + var result4 = null; + if (reportMatchFailures) { + matchFailed("\":\""); + } + } + if (result4 !== null) { + var result5 = parse_identifier(); + if (result5 !== null) { + var result3 = [result4, result5]; + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + var result2 = result3 !== null + ? (function(n) {return n})(result3[1]) + : null; + var result1 = result2 !== null ? result2 : ''; + var result0 = result1 !== null + ? (function(n) { return n ? ["context", n] : ["context"] })(result1) + : null; + + + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_params() { + var cacheKey = "params" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + var savedReportMatchFailures = reportMatchFailures; + reportMatchFailures = false; + var result1 = []; + var savedPos0 = pos; + var result4 = parse_ws(); + if (result4 !== null) { + var result5 = parse_key(); + if (result5 !== null) { + if (input.substr(pos, 1) === "=") { + var result6 = "="; + pos += 1; + } else { + var result6 = null; + if (reportMatchFailures) { + matchFailed("\"=\""); + } + } + if (result6 !== null) { + var result9 = parse_identifier(); + if (result9 !== null) { + var result7 = result9; + } else { + var result8 = parse_inline(); + if (result8 !== null) { + var result7 = result8; + } else { + var result7 = null;; + }; + } + if (result7 !== null) { + var result3 = [result4, result5, result6, result7]; + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + var result2 = result3 !== null + ? (function(k, v) {return ["param", ["literal", k], v]})(result3[1], result3[3]) + : null; + while (result2 !== null) { + result1.push(result2); + var savedPos0 = pos; + var result4 = parse_ws(); + if (result4 !== null) { + var result5 = parse_key(); + if (result5 !== null) { + if (input.substr(pos, 1) === "=") { + var result6 = "="; + pos += 1; + } else { + var result6 = null; + if (reportMatchFailures) { + matchFailed("\"=\""); + } + } + if (result6 !== null) { + var result9 = parse_identifier(); + if (result9 !== null) { + var result7 = result9; + } else { + var result8 = parse_inline(); + if (result8 !== null) { + var result7 = result8; + } else { + var result7 = null;; + }; + } + if (result7 !== null) { + var result3 = [result4, result5, result6, result7]; + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + var result2 = result3 !== null + ? (function(k, v) {return ["param", ["literal", k], v]})(result3[1], result3[3]) + : null; + } + var result0 = result1 !== null + ? (function(p) { return ["params"].concat(p) })(result1) + : null; + reportMatchFailures = savedReportMatchFailures; + if (reportMatchFailures && result0 === null) { + matchFailed("params"); + } + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_bodies() { + var cacheKey = "bodies" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + var savedReportMatchFailures = reportMatchFailures; + reportMatchFailures = false; + var result1 = []; + var savedPos0 = pos; + var result4 = parse_ld(); + if (result4 !== null) { + if (input.substr(pos, 1) === ":") { + var result5 = ":"; + pos += 1; + } else { + var result5 = null; + if (reportMatchFailures) { + matchFailed("\":\""); + } + } + if (result5 !== null) { + var result6 = parse_key(); + if (result6 !== null) { + var result7 = parse_rd(); + if (result7 !== null) { + var result8 = parse_body(); + if (result8 !== null) { + var result3 = [result4, result5, result6, result7, result8]; + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + var result2 = result3 !== null + ? (function(k, v) {return ["param", ["literal", k], v]})(result3[2], result3[4]) + : null; + while (result2 !== null) { + result1.push(result2); + var savedPos0 = pos; + var result4 = parse_ld(); + if (result4 !== null) { + if (input.substr(pos, 1) === ":") { + var result5 = ":"; + pos += 1; + } else { + var result5 = null; + if (reportMatchFailures) { + matchFailed("\":\""); + } + } + if (result5 !== null) { + var result6 = parse_key(); + if (result6 !== null) { + var result7 = parse_rd(); + if (result7 !== null) { + var result8 = parse_body(); + if (result8 !== null) { + var result3 = [result4, result5, result6, result7, result8]; + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + var result2 = result3 !== null + ? (function(k, v) {return ["param", ["literal", k], v]})(result3[2], result3[4]) + : null; + } + var result0 = result1 !== null + ? (function(p) { return ["bodies"].concat(p) })(result1) + : null; + reportMatchFailures = savedReportMatchFailures; + if (reportMatchFailures && result0 === null) { + matchFailed("bodies"); + } + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_reference() { + var cacheKey = "reference" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + var savedReportMatchFailures = reportMatchFailures; + reportMatchFailures = false; + var savedPos0 = pos; + var result2 = parse_ld(); + if (result2 !== null) { + var result3 = parse_identifier(); + if (result3 !== null) { + var result4 = parse_filters(); + if (result4 !== null) { + var result5 = parse_rd(); + if (result5 !== null) { + var result1 = [result2, result3, result4, result5]; + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + var result0 = result1 !== null + ? (function(n, f) { return ["reference", n, f] })(result1[1], result1[2]) + : null; + reportMatchFailures = savedReportMatchFailures; + if (reportMatchFailures && result0 === null) { + matchFailed("reference"); + } + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_partial() { + var cacheKey = "partial" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + var savedReportMatchFailures = reportMatchFailures; + reportMatchFailures = false; + var savedPos0 = pos; + var result2 = parse_ld(); + if (result2 !== null) { + if (input.substr(pos, 1) === ">") { + var result3 = ">"; + pos += 1; + } else { + var result3 = null; + if (reportMatchFailures) { + matchFailed("\">\""); + } + } + if (result3 !== null) { + var result10 = parse_key(); + var result9 = result10 !== null + ? (function(k) {return ["literal", k]})(result10) + : null; + if (result9 !== null) { + var result4 = result9; + } else { + var result8 = parse_inline(); + if (result8 !== null) { + var result4 = result8; + } else { + var result4 = null;; + }; + } + if (result4 !== null) { + var result5 = parse_context(); + if (result5 !== null) { + if (input.substr(pos, 1) === "/") { + var result6 = "/"; + pos += 1; + } else { + var result6 = null; + if (reportMatchFailures) { + matchFailed("\"/\""); + } + } + if (result6 !== null) { + var result7 = parse_rd(); + if (result7 !== null) { + var result1 = [result2, result3, result4, result5, result6, result7]; + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + var result0 = result1 !== null + ? (function(n, c) { return ["partial", n, c] })(result1[2], result1[3]) + : null; + reportMatchFailures = savedReportMatchFailures; + if (reportMatchFailures && result0 === null) { + matchFailed("partial"); + } + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_filters() { + var cacheKey = "filters" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + var savedReportMatchFailures = reportMatchFailures; + reportMatchFailures = false; + var result1 = []; + var savedPos0 = pos; + if (input.substr(pos, 1) === "|") { + var result4 = "|"; + pos += 1; + } else { + var result4 = null; + if (reportMatchFailures) { + matchFailed("\"|\""); + } + } + if (result4 !== null) { + var result5 = parse_key(); + if (result5 !== null) { + var result3 = [result4, result5]; + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + var result2 = result3 !== null + ? (function(n) {return n})(result3[1]) + : null; + while (result2 !== null) { + result1.push(result2); + var savedPos0 = pos; + if (input.substr(pos, 1) === "|") { + var result4 = "|"; + pos += 1; + } else { + var result4 = null; + if (reportMatchFailures) { + matchFailed("\"|\""); + } + } + if (result4 !== null) { + var result5 = parse_key(); + if (result5 !== null) { + var result3 = [result4, result5]; + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + var result2 = result3 !== null + ? (function(n) {return n})(result3[1]) + : null; + } + var result0 = result1 !== null + ? (function(f) { return ["filters"].concat(f) })(result1) + : null; + reportMatchFailures = savedReportMatchFailures; + if (reportMatchFailures && result0 === null) { + matchFailed("filters"); + } + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_special() { + var cacheKey = "special" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + var savedReportMatchFailures = reportMatchFailures; + reportMatchFailures = false; + var savedPos0 = pos; + var result2 = parse_ld(); + if (result2 !== null) { + if (input.substr(pos, 1) === "~") { + var result3 = "~"; + pos += 1; + } else { + var result3 = null; + if (reportMatchFailures) { + matchFailed("\"~\""); + } + } + if (result3 !== null) { + var result4 = parse_key(); + if (result4 !== null) { + var result5 = parse_rd(); + if (result5 !== null) { + var result1 = [result2, result3, result4, result5]; + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + var result0 = result1 !== null + ? (function(k) { return ["special", k] })(result1[2]) + : null; + reportMatchFailures = savedReportMatchFailures; + if (reportMatchFailures && result0 === null) { + matchFailed("special"); + } + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_identifier() { + var cacheKey = "identifier" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + var savedReportMatchFailures = reportMatchFailures; + reportMatchFailures = false; + var result4 = parse_path(); + var result3 = result4 !== null + ? (function(p) { return wrap(["path"].concat(p), cacheKey) })(result4) + : null; + if (result3 !== null) { + var result0 = result3; + } else { + var result2 = parse_key(); + var result1 = result2 !== null + ? (function(k) { return wrap(["key", k], cacheKey) })(result2) + : null; + if (result1 !== null) { + var result0 = result1; + } else { + var result0 = null;; + }; + } + reportMatchFailures = savedReportMatchFailures; + if (reportMatchFailures && result0 === null) { + matchFailed("identifier"); + } + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_path() { + var cacheKey = "path" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + var savedReportMatchFailures = reportMatchFailures; + reportMatchFailures = false; + var savedPos0 = pos; + var result11 = parse_key(); + var result5 = result11 !== null ? result11 : ''; + if (result5 !== null) { + var savedPos1 = pos; + if (input.substr(pos, 1) === ".") { + var result9 = "."; + pos += 1; + } else { + var result9 = null; + if (reportMatchFailures) { + matchFailed("\".\""); + } + } + if (result9 !== null) { + var result10 = parse_key(); + if (result10 !== null) { + var result8 = [result9, result10]; + } else { + var result8 = null; + pos = savedPos1; + } + } else { + var result8 = null; + pos = savedPos1; + } + var result7 = result8 !== null + ? (function(k) {return k})(result8[1]) + : null; + if (result7 !== null) { + var result6 = []; + while (result7 !== null) { + result6.push(result7); + var savedPos1 = pos; + if (input.substr(pos, 1) === ".") { + var result9 = "."; + pos += 1; + } else { + var result9 = null; + if (reportMatchFailures) { + matchFailed("\".\""); + } + } + if (result9 !== null) { + var result10 = parse_key(); + if (result10 !== null) { + var result8 = [result9, result10]; + } else { + var result8 = null; + pos = savedPos1; + } + } else { + var result8 = null; + pos = savedPos1; + } + var result7 = result8 !== null + ? (function(k) {return k})(result8[1]) + : null; + } + } else { + var result6 = null; + } + if (result6 !== null) { + var result4 = [result5, result6]; + } else { + var result4 = null; + pos = savedPos0; + } + } else { + var result4 = null; + pos = savedPos0; + } + var result3 = result4 !== null + ? (function(k, d) { + if (k) { d.unshift(k); return [false, d]; } + return [true, d]; + })(result4[0], result4[1]) + : null; + if (result3 !== null) { + var result0 = result3; + } else { + if (input.substr(pos, 1) === ".") { + var result2 = "."; + pos += 1; + } else { + var result2 = null; + if (reportMatchFailures) { + matchFailed("\".\""); + } + } + var result1 = result2 !== null + ? (function() { return [true, []] })() + : null; + if (result1 !== null) { + var result0 = result1; + } else { + var result0 = null;; + }; + } + reportMatchFailures = savedReportMatchFailures; + if (reportMatchFailures && result0 === null) { + matchFailed("path"); + } + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_key() { + var cacheKey = "key" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + var savedReportMatchFailures = reportMatchFailures; + reportMatchFailures = false; + var savedPos0 = pos; + if (input.substr(pos).match(/^[a-zA-Z_$]/) !== null) { + var result2 = input.charAt(pos); + pos++; + } else { + var result2 = null; + if (reportMatchFailures) { + matchFailed("[a-zA-Z_$]"); + } + } + if (result2 !== null) { + var result3 = []; + if (input.substr(pos).match(/^[0-9a-zA-Z_$]/) !== null) { + var result4 = input.charAt(pos); + pos++; + } else { + var result4 = null; + if (reportMatchFailures) { + matchFailed("[0-9a-zA-Z_$]"); + } + } + while (result4 !== null) { + result3.push(result4); + if (input.substr(pos).match(/^[0-9a-zA-Z_$]/) !== null) { + var result4 = input.charAt(pos); + pos++; + } else { + var result4 = null; + if (reportMatchFailures) { + matchFailed("[0-9a-zA-Z_$]"); + } + } + } + if (result3 !== null) { + var result1 = [result2, result3]; + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + var result0 = result1 !== null + ? (function(h, t) { return h + t.join('') })(result1[0], result1[1]) + : null; + reportMatchFailures = savedReportMatchFailures; + if (reportMatchFailures && result0 === null) { + matchFailed("key"); + } + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_inline() { + var cacheKey = "inline" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + var savedReportMatchFailures = reportMatchFailures; + reportMatchFailures = false; + var savedPos2 = pos; + if (input.substr(pos, 1) === "\"") { + var result14 = "\""; + pos += 1; + } else { + var result14 = null; + if (reportMatchFailures) { + matchFailed("\"\\\"\""); + } + } + if (result14 !== null) { + if (input.substr(pos, 1) === "\"") { + var result15 = "\""; + pos += 1; + } else { + var result15 = null; + if (reportMatchFailures) { + matchFailed("\"\\\"\""); + } + } + if (result15 !== null) { + var result13 = [result14, result15]; + } else { + var result13 = null; + pos = savedPos2; + } + } else { + var result13 = null; + pos = savedPos2; + } + var result12 = result13 !== null + ? (function() { return ["literal", ""] })() + : null; + if (result12 !== null) { + var result0 = result12; + } else { + var savedPos1 = pos; + if (input.substr(pos, 1) === "\"") { + var result9 = "\""; + pos += 1; + } else { + var result9 = null; + if (reportMatchFailures) { + matchFailed("\"\\\"\""); + } + } + if (result9 !== null) { + var result10 = parse_literal(); + if (result10 !== null) { + if (input.substr(pos, 1) === "\"") { + var result11 = "\""; + pos += 1; + } else { + var result11 = null; + if (reportMatchFailures) { + matchFailed("\"\\\"\""); + } + } + if (result11 !== null) { + var result8 = [result9, result10, result11]; + } else { + var result8 = null; + pos = savedPos1; + } + } else { + var result8 = null; + pos = savedPos1; + } + } else { + var result8 = null; + pos = savedPos1; + } + var result7 = result8 !== null + ? (function(l) { return ["literal", l] })(result8[1]) + : null; + if (result7 !== null) { + var result0 = result7; + } else { + var savedPos0 = pos; + if (input.substr(pos, 1) === "\"") { + var result3 = "\""; + pos += 1; + } else { + var result3 = null; + if (reportMatchFailures) { + matchFailed("\"\\\"\""); + } + } + if (result3 !== null) { + var result6 = parse_inline_part(); + if (result6 !== null) { + var result4 = []; + while (result6 !== null) { + result4.push(result6); + var result6 = parse_inline_part(); + } + } else { + var result4 = null; + } + if (result4 !== null) { + if (input.substr(pos, 1) === "\"") { + var result5 = "\""; + pos += 1; + } else { + var result5 = null; + if (reportMatchFailures) { + matchFailed("\"\\\"\""); + } + } + if (result5 !== null) { + var result2 = [result3, result4, result5]; + } else { + var result2 = null; + pos = savedPos0; + } + } else { + var result2 = null; + pos = savedPos0; + } + } else { + var result2 = null; + pos = savedPos0; + } + var result1 = result2 !== null + ? (function(p) { return ["body"].concat(p) })(result2[1]) + : null; + if (result1 !== null) { + var result0 = result1; + } else { + var result0 = null;; + }; + }; + } + reportMatchFailures = savedReportMatchFailures; + if (reportMatchFailures && result0 === null) { + matchFailed("inline"); + } + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_inline_part() { + var cacheKey = "inline_part" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + + var result4 = parse_special(); + if (result4 !== null) { + var result0 = result4; + } else { + var result3 = parse_reference(); + if (result3 !== null) { + var result0 = result3; + } else { + var result2 = parse_literal(); + var result1 = result2 !== null + ? (function(l) { return ["buffer", l] })(result2) + : null; + if (result1 !== null) { + var result0 = result1; + } else { + var result0 = null;; + }; + }; + } + + + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_buffer() { + var cacheKey = "buffer" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + var savedReportMatchFailures = reportMatchFailures; + reportMatchFailures = false; + var savedPos4 = pos; + var result14 = parse_eol(); + if (result14 !== null) { + var result15 = []; + var result16 = parse_ws(); + while (result16 !== null) { + result15.push(result16); + var result16 = parse_ws(); + } + if (result15 !== null) { + var result13 = [result14, result15]; + } else { + var result13 = null; + pos = savedPos4; + } + } else { + var result13 = null; + pos = savedPos4; + } + var result12 = result13 !== null + ? (function(e, w) { return ["format", e, w.join('')] })(result13[0], result13[1]) + : null; + if (result12 !== null) { + var result0 = result12; + } else { + var savedPos0 = pos; + var savedPos3 = pos; + var savedReportMatchFailuresVar2 = reportMatchFailures; + reportMatchFailures = false; + var result11 = parse_tag(); + reportMatchFailures = savedReportMatchFailuresVar2; + if (result11 === null) { + var result5 = ''; + } else { + var result5 = null; + pos = savedPos3; + } + if (result5 !== null) { + var savedPos2 = pos; + var savedReportMatchFailuresVar1 = reportMatchFailures; + reportMatchFailures = false; + var result10 = parse_eol(); + reportMatchFailures = savedReportMatchFailuresVar1; + if (result10 === null) { + var result6 = ''; + } else { + var result6 = null; + pos = savedPos2; + } + if (result6 !== null) { + var savedPos1 = pos; + var savedReportMatchFailuresVar0 = reportMatchFailures; + reportMatchFailures = false; + var result9 = parse_comment(); + reportMatchFailures = savedReportMatchFailuresVar0; + if (result9 === null) { + var result7 = ''; + } else { + var result7 = null; + pos = savedPos1; + } + if (result7 !== null) { + if (input.length > pos) { + var result8 = input.charAt(pos); + pos++; + } else { + var result8 = null; + if (reportMatchFailures) { + matchFailed('any character'); + } + } + if (result8 !== null) { + var result4 = [result5, result6, result7, result8]; + } else { + var result4 = null; + pos = savedPos0; + } + } else { + var result4 = null; + pos = savedPos0; + } + } else { + var result4 = null; + pos = savedPos0; + } + } else { + var result4 = null; + pos = savedPos0; + } + var result3 = result4 !== null + ? (function(c) {return c})(result4[3]) + : null; + if (result3 !== null) { + var result2 = []; + while (result3 !== null) { + result2.push(result3); + var savedPos0 = pos; + var savedPos3 = pos; + var savedReportMatchFailuresVar2 = reportMatchFailures; + reportMatchFailures = false; + var result11 = parse_tag(); + reportMatchFailures = savedReportMatchFailuresVar2; + if (result11 === null) { + var result5 = ''; + } else { + var result5 = null; + pos = savedPos3; + } + if (result5 !== null) { + var savedPos2 = pos; + var savedReportMatchFailuresVar1 = reportMatchFailures; + reportMatchFailures = false; + var result10 = parse_eol(); + reportMatchFailures = savedReportMatchFailuresVar1; + if (result10 === null) { + var result6 = ''; + } else { + var result6 = null; + pos = savedPos2; + } + if (result6 !== null) { + var savedPos1 = pos; + var savedReportMatchFailuresVar0 = reportMatchFailures; + reportMatchFailures = false; + var result9 = parse_comment(); + reportMatchFailures = savedReportMatchFailuresVar0; + if (result9 === null) { + var result7 = ''; + } else { + var result7 = null; + pos = savedPos1; + } + if (result7 !== null) { + if (input.length > pos) { + var result8 = input.charAt(pos); + pos++; + } else { + var result8 = null; + if (reportMatchFailures) { + matchFailed('any character'); + } + } + if (result8 !== null) { + var result4 = [result5, result6, result7, result8]; + } else { + var result4 = null; + pos = savedPos0; + } + } else { + var result4 = null; + pos = savedPos0; + } + } else { + var result4 = null; + pos = savedPos0; + } + } else { + var result4 = null; + pos = savedPos0; + } + var result3 = result4 !== null + ? (function(c) {return c})(result4[3]) + : null; + } + } else { + var result2 = null; + } + var result1 = result2 !== null + ? (function(b) { return ["buffer", b.join('')] })(result2) + : null; + if (result1 !== null) { + var result0 = result1; + } else { + var result0 = null;; + }; + } + reportMatchFailures = savedReportMatchFailures; + if (reportMatchFailures && result0 === null) { + matchFailed("buffer"); + } + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_literal() { + var cacheKey = "literal" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + var savedReportMatchFailures = reportMatchFailures; + reportMatchFailures = false; + var savedPos0 = pos; + var savedPos2 = pos; + var savedReportMatchFailuresVar1 = reportMatchFailures; + reportMatchFailures = false; + var result10 = parse_tag(); + reportMatchFailures = savedReportMatchFailuresVar1; + if (result10 === null) { + var result4 = ''; + } else { + var result4 = null; + pos = savedPos2; + } + if (result4 !== null) { + var savedPos1 = pos; + var savedReportMatchFailuresVar0 = reportMatchFailures; + reportMatchFailures = false; + var result9 = parse_eol(); + reportMatchFailures = savedReportMatchFailuresVar0; + if (result9 === null) { + var result5 = ''; + } else { + var result5 = null; + pos = savedPos1; + } + if (result5 !== null) { + var result8 = parse_esc(); + if (result8 !== null) { + var result6 = result8; + } else { + if (input.substr(pos).match(/^[^"]/) !== null) { + var result7 = input.charAt(pos); + pos++; + } else { + var result7 = null; + if (reportMatchFailures) { + matchFailed("[^\"]"); + } + } + if (result7 !== null) { + var result6 = result7; + } else { + var result6 = null;; + }; + } + if (result6 !== null) { + var result3 = [result4, result5, result6]; + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + var result2 = result3 !== null + ? (function(c) {return c})(result3[2]) + : null; + if (result2 !== null) { + var result1 = []; + while (result2 !== null) { + result1.push(result2); + var savedPos0 = pos; + var savedPos2 = pos; + var savedReportMatchFailuresVar1 = reportMatchFailures; + reportMatchFailures = false; + var result10 = parse_tag(); + reportMatchFailures = savedReportMatchFailuresVar1; + if (result10 === null) { + var result4 = ''; + } else { + var result4 = null; + pos = savedPos2; + } + if (result4 !== null) { + var savedPos1 = pos; + var savedReportMatchFailuresVar0 = reportMatchFailures; + reportMatchFailures = false; + var result9 = parse_eol(); + reportMatchFailures = savedReportMatchFailuresVar0; + if (result9 === null) { + var result5 = ''; + } else { + var result5 = null; + pos = savedPos1; + } + if (result5 !== null) { + var result8 = parse_esc(); + if (result8 !== null) { + var result6 = result8; + } else { + if (input.substr(pos).match(/^[^"]/) !== null) { + var result7 = input.charAt(pos); + pos++; + } else { + var result7 = null; + if (reportMatchFailures) { + matchFailed("[^\"]"); + } + } + if (result7 !== null) { + var result6 = result7; + } else { + var result6 = null;; + }; + } + if (result6 !== null) { + var result3 = [result4, result5, result6]; + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + var result2 = result3 !== null + ? (function(c) {return c})(result3[2]) + : null; + } + } else { + var result1 = null; + } + var result0 = result1 !== null + ? (function(b) { return b.join('') })(result1) + : null; + reportMatchFailures = savedReportMatchFailures; + if (reportMatchFailures && result0 === null) { + matchFailed("literal"); + } + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_esc() { + var cacheKey = "esc" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + + if (input.substr(pos, 2) === "\\\"") { + var result1 = "\\\""; + pos += 2; + } else { + var result1 = null; + if (reportMatchFailures) { + matchFailed("\"\\\\\\\"\""); + } + } + var result0 = result1 !== null + ? (function() { return '"' })() + : null; + + + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_comment() { + var cacheKey = "comment" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + var savedReportMatchFailures = reportMatchFailures; + reportMatchFailures = false; + var savedPos0 = pos; + if (input.substr(pos, 2) === "{!") { + var result2 = "{!"; + pos += 2; + } else { + var result2 = null; + if (reportMatchFailures) { + matchFailed("\"{!\""); + } + } + if (result2 !== null) { + var result3 = []; + var savedPos1 = pos; + var savedPos2 = pos; + var savedReportMatchFailuresVar0 = reportMatchFailures; + reportMatchFailures = false; + if (input.substr(pos, 2) === "!}") { + var result9 = "!}"; + pos += 2; + } else { + var result9 = null; + if (reportMatchFailures) { + matchFailed("\"!}\""); + } + } + reportMatchFailures = savedReportMatchFailuresVar0; + if (result9 === null) { + var result7 = ''; + } else { + var result7 = null; + pos = savedPos2; + } + if (result7 !== null) { + if (input.length > pos) { + var result8 = input.charAt(pos); + pos++; + } else { + var result8 = null; + if (reportMatchFailures) { + matchFailed('any character'); + } + } + if (result8 !== null) { + var result6 = [result7, result8]; + } else { + var result6 = null; + pos = savedPos1; + } + } else { + var result6 = null; + pos = savedPos1; + } + var result5 = result6 !== null + ? (function(c) {return c})(result6[1]) + : null; + while (result5 !== null) { + result3.push(result5); + var savedPos1 = pos; + var savedPos2 = pos; + var savedReportMatchFailuresVar0 = reportMatchFailures; + reportMatchFailures = false; + if (input.substr(pos, 2) === "!}") { + var result9 = "!}"; + pos += 2; + } else { + var result9 = null; + if (reportMatchFailures) { + matchFailed("\"!}\""); + } + } + reportMatchFailures = savedReportMatchFailuresVar0; + if (result9 === null) { + var result7 = ''; + } else { + var result7 = null; + pos = savedPos2; + } + if (result7 !== null) { + if (input.length > pos) { + var result8 = input.charAt(pos); + pos++; + } else { + var result8 = null; + if (reportMatchFailures) { + matchFailed('any character'); + } + } + if (result8 !== null) { + var result6 = [result7, result8]; + } else { + var result6 = null; + pos = savedPos1; + } + } else { + var result6 = null; + pos = savedPos1; + } + var result5 = result6 !== null + ? (function(c) {return c})(result6[1]) + : null; + } + if (result3 !== null) { + if (input.substr(pos, 2) === "!}") { + var result4 = "!}"; + pos += 2; + } else { + var result4 = null; + if (reportMatchFailures) { + matchFailed("\"!}\""); + } + } + if (result4 !== null) { + var result1 = [result2, result3, result4]; + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + var result0 = result1 !== null + ? (function(c) { return ["comment", c.join('')] })(result1[1]) + : null; + reportMatchFailures = savedReportMatchFailures; + if (reportMatchFailures && result0 === null) { + matchFailed("comment"); + } + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_tag() { + var cacheKey = "tag" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + + var savedPos0 = pos; + var result3 = parse_ld(); + if (result3 !== null) { + if (input.substr(pos).match(/^[#?^><+%:@\/~%]/) !== null) { + var result4 = input.charAt(pos); + pos++; + } else { + var result4 = null; + if (reportMatchFailures) { + matchFailed("[#?^><+%:@\\/~%]"); + } + } + if (result4 !== null) { + var savedPos1 = pos; + var savedPos3 = pos; + var savedReportMatchFailuresVar1 = reportMatchFailures; + reportMatchFailures = false; + var result12 = parse_rd(); + reportMatchFailures = savedReportMatchFailuresVar1; + if (result12 === null) { + var result8 = ''; + } else { + var result8 = null; + pos = savedPos3; + } + if (result8 !== null) { + var savedPos2 = pos; + var savedReportMatchFailuresVar0 = reportMatchFailures; + reportMatchFailures = false; + var result11 = parse_eol(); + reportMatchFailures = savedReportMatchFailuresVar0; + if (result11 === null) { + var result9 = ''; + } else { + var result9 = null; + pos = savedPos2; + } + if (result9 !== null) { + if (input.length > pos) { + var result10 = input.charAt(pos); + pos++; + } else { + var result10 = null; + if (reportMatchFailures) { + matchFailed('any character'); + } + } + if (result10 !== null) { + var result7 = [result8, result9, result10]; + } else { + var result7 = null; + pos = savedPos1; + } + } else { + var result7 = null; + pos = savedPos1; + } + } else { + var result7 = null; + pos = savedPos1; + } + if (result7 !== null) { + var result5 = []; + while (result7 !== null) { + result5.push(result7); + var savedPos1 = pos; + var savedPos3 = pos; + var savedReportMatchFailuresVar1 = reportMatchFailures; + reportMatchFailures = false; + var result12 = parse_rd(); + reportMatchFailures = savedReportMatchFailuresVar1; + if (result12 === null) { + var result8 = ''; + } else { + var result8 = null; + pos = savedPos3; + } + if (result8 !== null) { + var savedPos2 = pos; + var savedReportMatchFailuresVar0 = reportMatchFailures; + reportMatchFailures = false; + var result11 = parse_eol(); + reportMatchFailures = savedReportMatchFailuresVar0; + if (result11 === null) { + var result9 = ''; + } else { + var result9 = null; + pos = savedPos2; + } + if (result9 !== null) { + if (input.length > pos) { + var result10 = input.charAt(pos); + pos++; + } else { + var result10 = null; + if (reportMatchFailures) { + matchFailed('any character'); + } + } + if (result10 !== null) { + var result7 = [result8, result9, result10]; + } else { + var result7 = null; + pos = savedPos1; + } + } else { + var result7 = null; + pos = savedPos1; + } + } else { + var result7 = null; + pos = savedPos1; + } + } + } else { + var result5 = null; + } + if (result5 !== null) { + var result6 = parse_rd(); + if (result6 !== null) { + var result2 = [result3, result4, result5, result6]; + } else { + var result2 = null; + pos = savedPos0; + } + } else { + var result2 = null; + pos = savedPos0; + } + } else { + var result2 = null; + pos = savedPos0; + } + } else { + var result2 = null; + pos = savedPos0; + } + if (result2 !== null) { + var result0 = result2; + } else { + var result1 = parse_reference(); + if (result1 !== null) { + var result0 = result1; + } else { + var result0 = null;; + }; + } + + + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_ld() { + var cacheKey = "ld" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + + if (input.substr(pos, 1) === "{") { + var result0 = "{"; + pos += 1; + } else { + var result0 = null; + if (reportMatchFailures) { + matchFailed("\"{\""); + } + } + + + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_rd() { + var cacheKey = "rd" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + + if (input.substr(pos, 1) === "}") { + var result0 = "}"; + pos += 1; + } else { + var result0 = null; + if (reportMatchFailures) { + matchFailed("\"}\""); + } + } + + + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_eol() { + var cacheKey = "eol" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + + if (input.substr(pos, 1) === "\n") { + var result5 = "\n"; + pos += 1; + } else { + var result5 = null; + if (reportMatchFailures) { + matchFailed("\"\\n\""); + } + } + if (result5 !== null) { + var result0 = result5; + } else { + if (input.substr(pos, 2) === "\r\n") { + var result4 = "\r\n"; + pos += 2; + } else { + var result4 = null; + if (reportMatchFailures) { + matchFailed("\"\\r\\n\""); + } + } + if (result4 !== null) { + var result0 = result4; + } else { + if (input.substr(pos, 1) === "\r") { + var result3 = "\r"; + pos += 1; + } else { + var result3 = null; + if (reportMatchFailures) { + matchFailed("\"\\r\""); + } + } + if (result3 !== null) { + var result0 = result3; + } else { + if (input.substr(pos, 1) === "\u2028") { + var result2 = "\u2028"; + pos += 1; + } else { + var result2 = null; + if (reportMatchFailures) { + matchFailed("\"\\u2028\""); + } + } + if (result2 !== null) { + var result0 = result2; + } else { + if (input.substr(pos, 1) === "\u2029") { + var result1 = "\u2029"; + pos += 1; + } else { + var result1 = null; + if (reportMatchFailures) { + matchFailed("\"\\u2029\""); + } + } + if (result1 !== null) { + var result0 = result1; + } else { + var result0 = null;; + }; + }; + }; + }; + } + + + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_ws() { + var cacheKey = "ws" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + + if (input.substr(pos).match(/^[ \xA0\uFEFF]/) !== null) { + var result0 = input.charAt(pos); + pos++; + } else { + var result0 = null; + if (reportMatchFailures) { + matchFailed("[ \\xA0\\uFEFF]"); + } + } + + + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function buildErrorMessage() { + function buildExpected(failuresExpected) { + failuresExpected.sort(); + + var lastFailure = null; + var failuresExpectedUnique = []; + for (var i = 0; i < failuresExpected.length; i++) { + if (failuresExpected[i] !== lastFailure) { + failuresExpectedUnique.push(failuresExpected[i]); + lastFailure = failuresExpected[i]; + } + } + + switch (failuresExpectedUnique.length) { + case 0: + return 'end of input'; + case 1: + return failuresExpectedUnique[0]; + default: + return failuresExpectedUnique.slice(0, failuresExpectedUnique.length - 1).join(', ') + + ' or ' + + failuresExpectedUnique[failuresExpectedUnique.length - 1]; + } + } + + var expected = buildExpected(rightmostMatchFailuresExpected); + var actualPos = Math.max(pos, rightmostMatchFailuresPos); + var actual = actualPos < input.length + ? quote(input.charAt(actualPos)) + : 'end of input'; + + return 'Expected ' + expected + ' but ' + actual + ' found.'; + } + + function computeErrorPosition() { + /* + * The first idea was to use |String.split| to break the input up to the + * error position along newlines and derive the line and column from + * there. However IE's |split| implementation is so broken that it was + * enough to prevent it. + */ + + var line = 1; + var column = 1; + var seenCR = false; + + for (var i = 0; i < rightmostMatchFailuresPos; i++) { + var ch = input.charAt(i); + if (ch === '\n') { + if (!seenCR) { line++; } + column = 1; + seenCR = false; + } else if (ch === '\r' | ch === '\u2028' || ch === '\u2029') { + line++; + column = 1; + seenCR = true; + } else { + column++; + seenCR = false; + } + } + + return { line: line, column: column }; + } + + + + function wrap(node, ck) { + + node['text'] = input.substring(ck.split('@')[1], pos); + + return node; + + } + + + + var result = parse_body(); + + /* + * The parser is now in one of the following three states: + * + * 1. The parser successfully parsed the whole input. + * + * - |result !== null| + * - |pos === input.length| + * - |rightmostMatchFailuresExpected| may or may not contain something + * + * 2. The parser successfully parsed only a part of the input. + * + * - |result !== null| + * - |pos < input.length| + * - |rightmostMatchFailuresExpected| may or may not contain something + * + * 3. The parser did not successfully parse any part of the input. + * + * - |result === null| + * - |pos === 0| + * - |rightmostMatchFailuresExpected| contains at least one failure + * + * All code following this comment (including called functions) must + * handle these states. + */ + if (result === null || pos !== input.length) { + var errorPosition = computeErrorPosition(); + throw new SyntaxError( + buildErrorMessage(), + errorPosition.line, + errorPosition.column + ); + } + + return result; + }, + + /* Returns the parser source code. */ + toSource: function() { return this._source; } + }; + + /* Thrown when a parser encounters a syntax error. */ + + result.SyntaxError = function(message, line, column) { + this.name = 'SyntaxError'; + this.message = message; + this.line = line; + this.column = column; + }; + + result.SyntaxError.prototype = Error.prototype; + + return result; +})(); + +dust.parse = parser.parse; + +})(typeof exports !== 'undefined' ? exports : window.dust); \ No newline at end of file diff --git a/node_modules/dust/dist/dust-full-0.3.0.min.js b/node_modules/dust/dist/dust-full-0.3.0.min.js new file mode 100644 index 0000000..ba21d94 --- /dev/null +++ b/node_modules/dust/dist/dust-full-0.3.0.min.js @@ -0,0 +1,61 @@ +// +// Dust - Asynchronous Templating v0.3.0 +// http://akdubya.github.com/dustjs +// +// Copyright (c) 2010, Aleksander Williams +// Released under the MIT License. +// + +var dust={}; +(function(o){function z(e,k,l){this.stack=e;this.global=k;this.blocks=l}function H(e,k,l,x){this.tail=k;this.isObject=!o.isArray(e)&&e&&typeof e==="object";this.head=e;this.index=l;this.of=x}function p(e){this.head=new B(this);this.callback=e;this.out=""}function J(){this.head=new B(this)}function B(e,k,l){this.root=e;this.next=k;this.data="";this.flushable=false;this.taps=l}function r(e,k){this.head=e;this.tail=k}o.cache={};o.register=function(e,k){if(e)o.cache[e]=k};o.render=function(e,k,l){l=(new p(l)).head; +o.load(e,l,z.wrap(k)).end()};o.stream=function(e,k){var l=new J;o.nextTick(function(){o.load(e,l.head,z.wrap(k)).end()});return l};o.renderSource=function(e,k,l){return o.compileFn(e)(k,l)};o.compileFn=function(e,k){var l=o.loadSource(o.compile(e,k));return function(x,C){var E=C?new p(C):new J;o.nextTick(function(){l(E.head,z.wrap(x)).end()});return E}};o.load=function(e,k,l){var x=o.cache[e];if(x)return x(k,l);else{if(o.onLoad)return k.map(function(C){o.onLoad(e,function(E,M){if(E)return C.setError(E); +o.cache[e]||o.loadSource(o.compile(M,e));o.cache[e](C,l).end()})});return k.setError(Error("Template Not Found: "+e))}};o.loadSource=function(e){return eval(e)};o.isArray=Array.isArray?Array.isArray:function(e){return Object.prototype.toString.call(e)=="[object Array]"};o.nextTick=function(e){setTimeout(e,0)};o.isEmpty=function(e){if(o.isArray(e)&&!e.length)return true;if(e===0)return false;return!e};o.filter=function(e,k,l){if(l)for(var x=0,C=l.length;x\"]/),q=/&/g,j=//g,t=/\"/g;o.escapeHtml=function(e){if(typeof e==="string"){if(!K.test(e))return e;return e.replace(q,"&").replace(j,"<").replace(w,">").replace(t,""")}return e}; +var y=/\\/g,A=/\r/g,F=/\u2028/g,L=/\u2029/g,N=/\n/g,V=/\f/g,I=/'/g,Q=/"/g,T=/\t/g;o.escapeJs=function(e){if(typeof e==="string")return e.replace(y,"\\\\").replace(Q,'\\"').replace(I,"\\'").replace(A,"\\r").replace(F,"\\u2028").replace(L,"\\u2029").replace(N,"\\n").replace(V,"\\f").replace(T,"\\t");return e}})(dust);if(typeof exports!=="undefined"){typeof process!=="undefined"&&require("./server")(dust);module.exports=dust} +(function(o){function z(q,j){for(var w=[j[0]],t=1,y=j.length;tR){R=a;W=[]}W.push(n)}}function K(){var n="body@"+a,b=v[n];if(b){a=b.nextPos;return b.result}b=[];for(var c= +q();c!==null;){b.push(c);c=q()}b=b!==null?["body"].concat(b):null;v[n]={nextPos:a,result:b};return b}function q(){var n="part@"+a,b=v[n];if(b){a=b.nextPos;return b.result}b=l();if(b!==null)b=b;else{b=j();if(b!==null)b=b;else{b="partial@"+a;var c=v[b];if(c){a=c.nextPos;b=c.result}else{c=h;h=false;var d=a,g=C();if(g!==null){if(p.substr(a,1)===">"){var f=">";a+=1}else{f=null;h&&r('">"')}if(f!==null){var i=I();i=i!==null?["literal",i]:null;if(i!==null)i=i;else{i=Q();i=i!==null?i:null}if(i!==null){var m= +y();if(m!==null){if(p.substr(a,1)==="/"){var s="/";a+=1}else{s=null;h&&r('"/"')}if(s!==null){var u=E();if(u!==null)g=[g,f,i,m,s,u];else{g=null;a=d}}else{g=null;a=d}}else{g=null;a=d}}else{g=null;a=d}}else{g=null;a=d}}else{g=null;a=d}d=g!==null?["partial",g[2],g[3]]:null;(h=c)&&d===null&&r("partial");v[b]={nextPos:a,result:d};b=d}if(b!==null)b=b;else{b=L();if(b!==null)b=b;else{b=F();if(b!==null)b=b;else{b="buffer@"+a;if(c=v[b]){a=c.nextPos;b=c.result}else{c=h;h=false;d=a;g=M();if(g!==null){f=[];for(i= +U();i!==null;){f.push(i);i=U()}if(f!==null)g=[g,f];else{g=null;a=d}}else{g=null;a=d}d=g!==null?["format",g[0],g[1].join("")]:null;if(d!==null)d=d;else{i=g=a;f=h;h=false;m=x();h=f;if(m===null)f="";else{f=null;a=i}if(f!==null){m=a;i=h;h=false;s=M();h=i;if(s===null)i="";else{i=null;a=m}if(i!==null){m=a;s=h;h=false;u=l();h=s;if(u===null)s="";else{s=null;a=m}if(s!==null){if(p.length>a){m=p.charAt(a);a++}else{m=null;h&&r("any character")}if(m!==null)f=[f,i,s,m];else{f=null;a=g}}else{f=null;a=g}}else{f= +null;a=g}}else{f=null;a=g}g=f!==null?f[3]:null;if(g!==null)for(d=[];g!==null;){d.push(g);i=g=a;f=h;h=false;m=x();h=f;if(m===null)f="";else{f=null;a=i}if(f!==null){m=a;i=h;h=false;s=M();h=i;if(s===null)i="";else{i=null;a=m}if(i!==null){m=a;s=h;h=false;u=l();h=s;if(u===null)s="";else{s=null;a=m}if(s!==null){if(p.length>a){m=p.charAt(a);a++}else{m=null;h&&r("any character")}if(m!==null)f=[f,i,s,m];else{f=null;a=g}}else{f=null;a=g}}else{f=null;a=g}}else{f=null;a=g}g=f!==null?f[3]:null}else d=null;d=d!== +null?["buffer",d.join("")]:null;d=d!==null?d:null}(h=c)&&d===null&&r("buffer");v[b]={nextPos:a,result:d};b=d}b=b!==null?b:null}}}}}v[n]={nextPos:a,result:b};return b}function j(){var n="section@"+a,b=v[n];if(b){a=b.nextPos;return b.result}b=h;h=false;var c=a,d=w();if(d!==null){var g=E();if(g!==null){var f=K();if(f!==null){var i=A();if(i!==null){var m=t();if(m!==null){var s=d[1].text===m.text?"":null;if(s!==null)d=[d,g,f,i,m,s];else{d=null;a=c}}else{d=null;a=c}}else{d=null;a=c}}else{d=null;a=c}}else{d= +null;a=c}}else{d=null;a=c}c=d!==null?function(u,D,O){O.push(["param",["literal","block"],D]);u.push(O);return u}(d[0],d[2],d[3],d[4]):null;if(c!==null)c=c;else{c=a;d=w();if(d!==null){if(p.substr(a,1)==="/"){g="/";a+=1}else{g=null;h&&r('"/"')}if(g!==null){f=E();if(f!==null)d=[d,g,f];else{d=null;a=c}}else{d=null;a=c}}else{d=null;a=c}c=d!==null?function(u){u.push(["bodies"]);return u}(d[0]):null;c=c!==null?c:null}(h=b)&&c===null&&r("section");v[n]={nextPos:a,result:c};return c}function w(){var n="sec_tag_start@"+ +a,b=v[n];if(b){a=b.nextPos;return b.result}b=a;var c=C();if(c!==null){if(p.substr(a).match(/^[#?^<+@%]/)!==null){var d=p.charAt(a);a++}else{d=null;h&&r("[#?^<+@%]")}if(d!==null){var g=N();if(g!==null){var f=y();if(f!==null){var i;i="params@"+a;var m=v[i];if(m){a=m.nextPos;i=m.result}else{m=h;h=false;var s=[],u=a,D=U();if(D!==null){var O=I();if(O!==null){if(p.substr(a,1)==="="){var P="=";a+=1}else{P=null;h&&r('"="')}if(P!==null){var G=N();if(G!==null)G=G;else{G=Q();G=G!==null?G:null}if(G!==null)D= +[D,O,P,G];else{D=null;a=u}}else{D=null;a=u}}else{D=null;a=u}}else{D=null;a=u}for(u=D!==null?["param",["literal",D[1]],D[3]]:null;u!==null;){s.push(u);u=a;D=U();if(D!==null){O=I();if(O!==null){if(p.substr(a,1)==="="){P="=";a+=1}else{P=null;h&&r('"="')}if(P!==null){G=N();if(G!==null)G=G;else{G=Q();G=G!==null?G:null}if(G!==null)D=[D,O,P,G];else{D=null;a=u}}else{D=null;a=u}}else{D=null;a=u}}else{D=null;a=u}u=D!==null?["param",["literal",D[1]],D[3]]:null}s=s!==null?["params"].concat(s):null;(h=m)&&s=== +null&&r("params");v[i]={nextPos:a,result:s};i=s}if(i!==null)c=[c,d,g,f,i];else{c=null;a=b}}else{c=null;a=b}}else{c=null;a=b}}else{c=null;a=b}}else{c=null;a=b}b=c!==null?[c[1],c[2],c[3],c[4]]:null;v[n]={nextPos:a,result:b};return b}function t(){var n="end_tag@"+a,b=v[n];if(b){a=b.nextPos;return b.result}b=h;h=false;var c=a,d=C();if(d!==null){if(p.substr(a,1)==="/"){var g="/";a+=1}else{g=null;h&&r('"/"')}if(g!==null){var f=N();if(f!==null){var i=E();if(i!==null)d=[d,g,f,i];else{d=null;a=c}}else{d=null; +a=c}}else{d=null;a=c}}else{d=null;a=c}c=d!==null?d[2]:null;(h=b)&&c===null&&r("end tag");v[n]={nextPos:a,result:c};return c}function y(){var n="context@"+a,b=v[n];if(b){a=b.nextPos;return b.result}b=a;if(p.substr(a,1)===":"){var c=":";a+=1}else{c=null;h&&r('":"')}if(c!==null){var d=N();if(d!==null)c=[c,d];else{c=null;a=b}}else{c=null;a=b}b=c!==null?c[1]:null;b=b!==null?b:"";b=b!==null?b?["context",b]:["context"]:null;v[n]={nextPos:a,result:b};return b}function A(){var n="bodies@"+a,b=v[n];if(b){a= +b.nextPos;return b.result}b=h;h=false;var c=[],d=a,g=C();if(g!==null){if(p.substr(a,1)===":"){var f=":";a+=1}else{f=null;h&&r('":"')}if(f!==null){var i=I();if(i!==null){var m=E();if(m!==null){var s=K();if(s!==null)g=[g,f,i,m,s];else{g=null;a=d}}else{g=null;a=d}}else{g=null;a=d}}else{g=null;a=d}}else{g=null;a=d}for(d=g!==null?["param",["literal",g[2]],g[4]]:null;d!==null;){c.push(d);d=a;g=C();if(g!==null){if(p.substr(a,1)===":"){f=":";a+=1}else{f=null;h&&r('":"')}if(f!==null){i=I();if(i!==null){m= +E();if(m!==null){s=K();if(s!==null)g=[g,f,i,m,s];else{g=null;a=d}}else{g=null;a=d}}else{g=null;a=d}}else{g=null;a=d}}else{g=null;a=d}d=g!==null?["param",["literal",g[2]],g[4]]:null}c=c!==null?["bodies"].concat(c):null;(h=b)&&c===null&&r("bodies");v[n]={nextPos:a,result:c};return c}function F(){var n="reference@"+a,b=v[n];if(b){a=b.nextPos;return b.result}b=h;h=false;var c=a,d=C();if(d!==null){var g=N();if(g!==null){var f;f="filters@"+a;var i=v[f];if(i){a=i.nextPos;f=i.result}else{i=h;h=false;var m= +[],s=a;if(p.substr(a,1)==="|"){var u="|";a+=1}else{u=null;h&&r('"|"')}if(u!==null){var D=I();if(D!==null)u=[u,D];else{u=null;a=s}}else{u=null;a=s}for(s=u!==null?u[1]:null;s!==null;){m.push(s);s=a;if(p.substr(a,1)==="|"){u="|";a+=1}else{u=null;h&&r('"|"')}if(u!==null){D=I();if(D!==null)u=[u,D];else{u=null;a=s}}else{u=null;a=s}s=u!==null?u[1]:null}m=m!==null?["filters"].concat(m):null;(h=i)&&m===null&&r("filters");v[f]={nextPos:a,result:m};f=m}if(f!==null){i=E();if(i!==null)d=[d,g,f,i];else{d=null; +a=c}}else{d=null;a=c}}else{d=null;a=c}}else{d=null;a=c}c=d!==null?["reference",d[1],d[2]]:null;(h=b)&&c===null&&r("reference");v[n]={nextPos:a,result:c};return c}function L(){var n="special@"+a,b=v[n];if(b){a=b.nextPos;return b.result}b=h;h=false;var c=a,d=C();if(d!==null){if(p.substr(a,1)==="~"){var g="~";a+=1}else{g=null;h&&r('"~"')}if(g!==null){var f=I();if(f!==null){var i=E();if(i!==null)d=[d,g,f,i];else{d=null;a=c}}else{d=null;a=c}}else{d=null;a=c}}else{d=null;a=c}c=d!==null?["special",d[2]]: +null;(h=b)&&c===null&&r("special");v[n]={nextPos:a,result:c};return c}function N(){var n="identifier@"+a,b=v[n];if(b){a=b.nextPos;return b.result}b=h;h=false;var c=V();c=c!==null?X(["path"].concat(c),n):null;if(c!==null)c=c;else{c=I();c=c!==null?X(["key",c],n):null;c=c!==null?c:null}(h=b)&&c===null&&r("identifier");v[n]={nextPos:a,result:c};return c}function V(){var n="path@"+a,b=v[n];if(b){a=b.nextPos;return b.result}b=h;h=false;var c=a,d=I();d=d!==null?d:"";if(d!==null){var g=a;if(p.substr(a,1)=== +"."){var f=".";a+=1}else{f=null;h&&r('"."')}if(f!==null){var i=I();if(i!==null)f=[f,i];else{f=null;a=g}}else{f=null;a=g}g=f!==null?f[1]:null;if(g!==null)for(var m=[];g!==null;){m.push(g);g=a;if(p.substr(a,1)==="."){f=".";a+=1}else{f=null;h&&r('"."')}if(f!==null){i=I();if(i!==null)f=[f,i];else{f=null;a=g}}else{f=null;a=g}g=f!==null?f[1]:null}else m=null;if(m!==null)d=[d,m];else{d=null;a=c}}else{d=null;a=c}c=d!==null?function(s,u){if(s){u.unshift(s);return[false,u]}return[true,u]}(d[0],d[1]):null;if(c!== +null)c=c;else{if(p.substr(a,1)==="."){c=".";a+=1}else{c=null;h&&r('"."')}c=c!==null?[true,[]]:null;c=c!==null?c:null}(h=b)&&c===null&&r("path");v[n]={nextPos:a,result:c};return c}function I(){var n="key@"+a,b=v[n];if(b){a=b.nextPos;return b.result}b=h;h=false;var c=a;if(p.substr(a).match(/^[a-zA-Z_$]/)!==null){var d=p.charAt(a);a++}else{d=null;h&&r("[a-zA-Z_$]")}if(d!==null){var g=[];if(p.substr(a).match(/^[0-9a-zA-Z_$]/)!==null){var f=p.charAt(a);a++}else{f=null;h&&r("[0-9a-zA-Z_$]")}for(;f!==null;){g.push(f); +if(p.substr(a).match(/^[0-9a-zA-Z_$]/)!==null){f=p.charAt(a);a++}else{f=null;h&&r("[0-9a-zA-Z_$]")}}if(g!==null)d=[d,g];else{d=null;a=c}}else{d=null;a=c}c=d!==null?d[0]+d[1].join(""):null;(h=b)&&c===null&&r("key");v[n]={nextPos:a,result:c};return c}function Q(){var n="inline@"+a,b=v[n];if(b){a=b.nextPos;return b.result}b=h;h=false;var c=a;if(p.substr(a,1)==='"'){var d='"';a+=1}else{d=null;h&&r('"\\""')}if(d!==null){if(p.substr(a,1)==='"'){var g='"';a+=1}else{g=null;h&&r('"\\""')}if(g!==null)d=[d, +g];else{d=null;a=c}}else{d=null;a=c}c=d!==null?["literal",""]:null;if(c!==null)c=c;else{c=a;if(p.substr(a,1)==='"'){d='"';a+=1}else{d=null;h&&r('"\\""')}if(d!==null){g=e();if(g!==null){if(p.substr(a,1)==='"'){var f='"';a+=1}else{f=null;h&&r('"\\""')}if(f!==null)d=[d,g,f];else{d=null;a=c}}else{d=null;a=c}}else{d=null;a=c}c=d!==null?["literal",d[1]]:null;if(c!==null)c=c;else{c=a;if(p.substr(a,1)==='"'){d='"';a+=1}else{d=null;h&&r('"\\""')}if(d!==null){f=T();if(f!==null)for(g=[];f!==null;){g.push(f); +f=T()}else g=null;if(g!==null){if(p.substr(a,1)==='"'){f='"';a+=1}else{f=null;h&&r('"\\""')}if(f!==null)d=[d,g,f];else{d=null;a=c}}else{d=null;a=c}}else{d=null;a=c}c=d!==null?["body"].concat(d[1]):null;c=c!==null?c:null}}(h=b)&&c===null&&r("inline");v[n]={nextPos:a,result:c};return c}function T(){var n="inline_part@"+a,b=v[n];if(b){a=b.nextPos;return b.result}b=L();if(b!==null)b=b;else{b=F();if(b!==null)b=b;else{b=e();b=b!==null?["buffer",b]:null;b=b!==null?b:null}}v[n]={nextPos:a,result:b};return b} +function e(){var n="literal@"+a,b=v[n];if(b){a=b.nextPos;return b.result}b=h;h=false;var c=a,d=a,g=h;h=false;var f=x();h=g;if(f===null)g="";else{g=null;a=d}if(g!==null){f=a;d=h;h=false;var i=M();h=d;if(i===null)d="";else{d=null;a=f}if(d!==null){f=k();if(f!==null)f=f;else{if(p.substr(a).match(/^[^"]/)!==null){f=p.charAt(a);a++}else{f=null;h&&r('[^"]')}f=f!==null?f:null}if(f!==null)g=[g,d,f];else{g=null;a=c}}else{g=null;a=c}}else{g=null;a=c}c=g!==null?g[2]:null;if(c!==null)for(var m=[];c!==null;){m.push(c); +d=c=a;g=h;h=false;f=x();h=g;if(f===null)g="";else{g=null;a=d}if(g!==null){f=a;d=h;h=false;i=M();h=d;if(i===null)d="";else{d=null;a=f}if(d!==null){f=k();if(f!==null)f=f;else{if(p.substr(a).match(/^[^"]/)!==null){f=p.charAt(a);a++}else{f=null;h&&r('[^"]')}f=f!==null?f:null}if(f!==null)g=[g,d,f];else{g=null;a=c}}else{g=null;a=c}}else{g=null;a=c}c=g!==null?g[2]:null}else m=null;m=m!==null?m.join(""):null;(h=b)&&m===null&&r("literal");v[n]={nextPos:a,result:m};return m}function k(){var n="esc@"+a,b=v[n]; +if(b){a=b.nextPos;return b.result}if(p.substr(a,2)==='\\"'){b='\\"';a+=2}else{b=null;h&&r('"\\\\\\""')}b=b!==null?'"':null;v[n]={nextPos:a,result:b};return b}function l(){var n="comment@"+a,b=v[n];if(b){a=b.nextPos;return b.result}b=h;h=false;var c=a;if(p.substr(a,2)==="{!"){var d="{!";a+=2}else{d=null;h&&r('"{!"')}if(d!==null){var g=[],f=a,i=a,m=h;h=false;if(p.substr(a,2)==="!}"){var s="!}";a+=2}else{s=null;h&&r('"!}"')}h=m;if(s===null)m="";else{m=null;a=i}if(m!==null){if(p.length>a){i=p.charAt(a); +a++}else{i=null;h&&r("any character")}if(i!==null)i=[m,i];else{i=null;a=f}}else{i=null;a=f}for(f=i!==null?i[1]:null;f!==null;){g.push(f);i=f=a;m=h;h=false;if(p.substr(a,2)==="!}"){s="!}";a+=2}else{s=null;h&&r('"!}"')}h=m;if(s===null)m="";else{m=null;a=i}if(m!==null){if(p.length>a){i=p.charAt(a);a++}else{i=null;h&&r("any character")}if(i!==null)i=[m,i];else{i=null;a=f}}else{i=null;a=f}f=i!==null?i[1]:null}if(g!==null){if(p.substr(a,2)==="!}"){f="!}";a+=2}else{f=null;h&&r('"!}"')}if(f!==null)d=[d,g, +f];else{d=null;a=c}}else{d=null;a=c}}else{d=null;a=c}c=d!==null?["comment",d[1].join("")]:null;(h=b)&&c===null&&r("comment");v[n]={nextPos:a,result:c};return c}function x(){var n="tag@"+a,b=v[n];if(b){a=b.nextPos;return b.result}b=a;var c=C();if(c!==null){if(p.substr(a).match(/^[#?^><+%:@\/~%]/)!==null){var d=p.charAt(a);a++}else{d=null;h&&r("[#?^><+%:@\\/~%]")}if(d!==null){var g=a,f=a,i=h;h=false;var m=E();h=i;if(m===null)i="";else{i=null;a=f}if(i!==null){f=a;m=h;h=false;var s=M();h=m;if(s===null)m= +"";else{m=null;a=f}if(m!==null){if(p.length>a){f=p.charAt(a);a++}else{f=null;h&&r("any character")}if(f!==null)i=[i,m,f];else{i=null;a=g}}else{i=null;a=g}}else{i=null;a=g}if(i!==null)for(var u=[];i!==null;){u.push(i);f=g=a;i=h;h=false;m=E();h=i;if(m===null)i="";else{i=null;a=f}if(i!==null){f=a;m=h;h=false;s=M();h=m;if(s===null)m="";else{m=null;a=f}if(m!==null){if(p.length>a){f=p.charAt(a);a++}else{f=null;h&&r("any character")}if(f!==null)i=[i,m,f];else{i=null;a=g}}else{i=null;a=g}}else{i=null;a=g}}else u= +null;if(u!==null){g=E();if(g!==null)c=[c,d,u,g];else{c=null;a=b}}else{c=null;a=b}}else{c=null;a=b}}else{c=null;a=b}if(c!==null)b=c;else{b=F();b=b!==null?b:null}v[n]={nextPos:a,result:b};return b}function C(){var n="ld@"+a,b=v[n];if(b){a=b.nextPos;return b.result}if(p.substr(a,1)==="{"){b="{";a+=1}else{b=null;h&&r('"{"')}v[n]={nextPos:a,result:b};return b}function E(){var n="rd@"+a,b=v[n];if(b){a=b.nextPos;return b.result}if(p.substr(a,1)==="}"){b="}";a+=1}else{b=null;h&&r('"}"')}v[n]={nextPos:a,result:b}; +return b}function M(){var n="eol@"+a,b=v[n];if(b){a=b.nextPos;return b.result}if(p.substr(a,1)==="\n"){b="\n";a+=1}else{b=null;h&&r('"\\n"')}if(b!==null)b=b;else{if(p.substr(a,2)==="\r\n"){b="\r\n";a+=2}else{b=null;h&&r('"\\r\\n"')}if(b!==null)b=b;else{if(p.substr(a,1)==="\r"){b="\r";a+=1}else{b=null;h&&r('"\\r"')}if(b!==null)b=b;else{if(p.substr(a,1)==="\u2028"){b="\u2028";a+=1}else{b=null;h&&r('"\\u2028"')}if(b!==null)b=b;else{if(p.substr(a,1)==="\u2029"){b="\u2029";a+=1}else{b=null;h&&r('"\\u2029"')}b= +b!==null?b:null}}}}v[n]={nextPos:a,result:b};return b}function U(){var n="ws@"+a,b=v[n];if(b){a=b.nextPos;return b.result}if(p.substr(a).match(/^[\t\u000b\u000c \xA0\uFEFF]/)!==null){b=p.charAt(a);a++}else{b=null;h&&r("[\t\u000b\u000c \\xA0\\uFEFF]")}v[n]={nextPos:a,result:b};return b}function Y(){var n=function(c){c.sort();for(var d=null,g=[],f=0;f + + +Include the full distribution if you want to compile templates within the browser (as in the online demo): + + + +Precompilation is the recommended approach for general use. + +### Compiling Templates + +Use `dust.compile` to compile a template body into a string of JavaScript source code: + + var compiled = dust.compile("Hello {name}!", "intro"); + +The variable `compiled` now contains the following string: + + '(function(){dust.register("intro",body_0) ...' + +If you save this source to a file and include the file in your HTML script tags, the compiled template will automatically register itself with the local runtime, under the name "intro". To evaluate a compiled template string manually, use `dust.loadSource`: + + dust.loadSource(compiled); + +The template is now available within the `dust.cache` object. + +### Rendering Templates + +The rendering engine provides both callback and streaming interfaces. + +#### The Callback Interface + +To render a template, call `dust.render` with the template name, a context object and a callback function: + + dust.render("intro", {name: "Fred"}, function(err, out) { + console.log(out); + }); + +The code above will write the following to the console: + + Hello Fred! + +#### The Streaming Interface + +Templates may also be streamed. `dust.stream` returns a handler very similar to a Node `EventEmitter`: + + dust.stream("index", context) + .on("data", function(data) { + console.log(data); + }) + .on("end", function() { + console.log("I'm finished!"); + }) + .on("error", function(err) { + console.log("Something terrible happened!"); + }); + +When used with specially crafted context handlers, the streaming interface provides chunked template rendering. + +### Contexts + +The context is a special object that handles variable lookups and controls template behavior. It is the interface between your application logic and your templates. The context can be visualized as a stack of objects that grows as we descend into nested sections: + + global --> { helper: function() { ... }, ... } + root --> { profile: { ... }, ... } + profile --> { friends: [ ... ], ... } + friends[0] --> { name: "Jorge", ... } + +When looking up a key, Dust searches the context stack from the bottom up. There is no need to merge helper functions into the template data; instead, create a base context onto which you can push your local template data: + + // Set up a base context with global helpers + var base = dust.makeBase({ + sayHello: function() { return "Hello!" } + }); + + // Push to the base context at render time + dust.render("index", base.push({foo: "bar"}), function(err, out) { + console.log(out); + }); + +Dust does not care how your reference objects are built. You may, for example, push prototyped objects onto the stack. The system leaves the `this` keyword intact when calling handler functions on your objects. + +### Handlers + +When Dust encounters a function in the context, it calls the function, passing in arguments that reflect the current state of the template. In the simplest case, a handler can pass a value back to the template engine: + + { + name: function() { + return "Bob"; + } + } + +#### Chunks + +But handlers can do much more than return values: they have complete control over the flow of the template, using the same API Dust uses internally. For example, the handler below writes a string directly to the current template chunk: + + { + name: function(chunk) { + return chunk.write("Bob"); + } + } + +A `Chunk` is a Dust primitive for controlling the flow of the template. Depending upon the behaviors defined in the context, templates may output one or more chunks during rendering. A handler that writes to a chunk directly must return the modified chunk. + +#### Accessing the Context + +Handlers have access to the context object: + + { + wrap: function(chunk, context) { + return chunk.write(context.get("foo")); + } + } + +`context.get("foo")` searches for _foo_ within the context stack. `context.current()` retrieves the value most recently pushed onto the context stack. + +#### Accessing Body Parameters + +The `bodies` object provides access to any bodies defined within the calling block. + + {#guide}foo{:else}bar{/guide} + +The template above will either render "foo" or "bar" depending on the behavior of the handler below: + + { + guide: function(chunk, context, bodies) { + if (secret === 42) { + return chunk.render(bodies.block, context); + } else { + return chunk.render(bodies['else'], context); + } + } + } + +`bodies.block` is a special parameter that returns the default (unnamed) block. `chunk.render` renders the chosen block. + +#### Accessing Inline Parameters + +The `params` object contains any inline parameters passed to a section tag: + + { + hello: function(chunk, context, bodies, params) { + if (params.greet === "true") { + return chunk.write("Hello!"); + } + return chunk; + } + } + +#### Asynchronous Handlers + +You may define handlers that execute asynchronously and in parallel: + + { + type: function(chunk) { + return chunk.map(function(chunk) { + setTimeout(function() { + chunk.end("Async"); + }); + }); + } + } + +`chunk.map` tells Dust to manufacture a new chunk, reserving a slot in the output stream before continuing on to render the rest of the template. You must (eventually) call `chunk.end()` on a mapped chunk to weave its content back into the stream. + +`chunk.map` provides a convenient way to split up templates rendered via `dust.stream`. For example, you might wrap the head of an HTML document in a special `{#head} ... {/head}` tag that is flushed to the browser before the rest of the body has finished rendering. + +### Reference + +#### Compiling + + dust.compile(source, name) + +Compiles `source` into a JavaScript template string. Registers itself under `name` when evaluated. + + dust.compileFn(source, [name]) + +Compiles `source` directly into a JavaScript function that takes a context and an optional callback (see `dust.renderSource`). Registers the template under `name` if this argument is supplied. + + dust.optimizers + +Object containing functions that transform the parse-tree before the template is compiled. To disable whitespace compression: + + dust.optimizers.format = function(ctx, node) { return node }; + +#### Loading + + dust.register(name, fn) + +Used internally to register template function `fn` with the runtime environment. Override to customize the way Dust caches templates. + + dust.onLoad(name, callback(err, out)) + +By default Dust returns a "template not found" error when a named template cannot be located in the cache. Override `onLoad` to specify a fallback loading mechanism (e.g., to load templates from the filesystem or a database). + + dust.loadSource(source, [filename]) + +Evaluates compiled `source` string. In Node.js, evaluates `source` as if it were loaded from `filename`. `filename` is optional. + +#### Rendering + + dust.render(name, context, callback(error, output)) + +Renders the named template and calls `callback` on completion. `context` may be a plain object or an instance of `dust.Context`. + + dust.stream(name, context) + +Streams the named template. `context` may be a plain object or an instance of `dust.Context`. Returns an instance of `dust.Stream`. + + stream.on("data", listener(data)) + stream.on("end", listener) + stream.on("error", listener(error)) + +Registers an event listener. Streams accept a single listener for a given event. + + dust.renderSource(source, context, [callback(error, output)]) + +Compiles and renders `source`, invoking `callback` on completion. If no callback is supplied this function returns a Stream object. Use this function when precompilation is not required. + +#### Contexts + + dust.makeBase(object) + +Manufactures a `dust.Context` instance with its global object set to `object`. + + context.get(key) + +Retrieves the value at `key` from the context stack. + + context.push(head, [index], [length]) + +Pushes an arbitrary value onto the context stack and returns a new context instance. Specify `index` and/or `length` to enable enumeration helpers. + + context.rebase(head) + +Returns a new context instance consisting only of the value at `head`, plus any previously defined global object. + + context.current() + +Returns the `head` of the context stack. + +#### Chunks + +The operations below always return a chunk object. + + chunk.write(data) + +Writes `data` to this chunk's buffer. + + chunk.map(callback(chunk)) + +Creates a new chunk and passes it to `callback`. Use `map` to wrap asynchronous functions and to partition the template for streaming. + + chunk.end(data) + +Writes `data` to this chunk's buffer and marks it as flushable. This method _must_ be called on any chunks created via `chunk.map`. Do _not_ call this method on a handler's main chunk -- `dust.render` and `dust.stream` take care of this for you. + + chunk.tap(callback) + chunk.untap() + +Convenience methods for applying filters to a stream. See the _filter_ demo for an example. + + chunk.render(body, context) + +Renders a template block, such as a default block or an `else` block. Basically equivalent to `body(chunk, context)`. + + chunk.setError(error) + +Sets an error on this chunk and immediately flushes the output. + + chunk.reference(elem, context, auto, filters) + chunk.section(elem, context, bodies, params) + chunk.exists(elem, context, bodies) + chunk.notexists(elem, context, bodies) + chunk.block(elem, context, bodies) + chunk.partial(elem, context) + chunk.helper(name, context, bodies, params) + +These methods implement Dust's default behavior for keys, sections, blocks, partials and context helpers. While it is unlikely you'll need to modify these methods or invoke them from within handlers, the source code may be a useful point of reference for developers. + +#### Utilities + + dust.filters + +Object containing built-in key filters. Can be customized with additional filters. + + dust.helpers + +Object containing the built-in context helpers. These may also be customized. + + dust.escapeHtml + +HTML escape function used by `dust.filters.h`. + + dust.escapeJs + +JavaScript string escape function used by `dust.filters.j`. \ No newline at end of file diff --git a/node_modules/dust/docs/build.js b/node_modules/dust/docs/build.js new file mode 100644 index 0000000..2ea53a2 --- /dev/null +++ b/node_modules/dust/docs/build.js @@ -0,0 +1,68 @@ +var path = require('path'), + fs = require('fs'), + Script = process.binding('evals').Script, + dust = require('../lib/dust'), + root = path.join(path.dirname(__filename), ".."); + +var src = fs.readFileSync(path.join(root, 'docs/index.dust.html'), 'utf8'); +dust.loadSource(dust.compile(src, "index")); + +var sd = process.compile(fs.readFileSync(path.join(root, 'vendor/showdown.js'), 'utf8'), 'showdown.js'); + +var inliners = { + css: function(names) { + var out = ""; + return out; + }, + + js: function(names) { + var out = ""; + return out; + } +} + +var context = { + inline: function(chk, ctx, bod, prm) { + var names = prm.names.split(' '); + return chk.write(inliners[prm.ext](names)); + }, + + tmpl: function(chk, ctx, bod, prm) { + var names = prm.names.split(' '); + var out = ""; + return chk.write(out); + }, + + md: function(chk, ctx, bod, prm) { + var converter = new sd(); + return chk.tap(function(data) { + return converter.makeHtml(data); + }).render(bod.block, ctx).untap(); + }, + + file: function(chk, ctx, bod, prm) { + var name = prm.name; + return chk.write(fs.readFileSync(path.join(root, 'docs', name), 'utf8')); + } +} + +function render() { + dust.render("index", context, function(err, output) { + if (err) throw err; + fs.writeFileSync(path.join(root, 'index.html'), output); + }); +} + +render(); \ No newline at end of file diff --git a/node_modules/dust/docs/index.css b/node_modules/dust/docs/index.css new file mode 100644 index 0000000..81ca035 --- /dev/null +++ b/node_modules/dust/docs/index.css @@ -0,0 +1,203 @@ +body { + font-family: 'Georgia', serif; + font-size: 18px; + margin: 0; + padding: 0; +} + +p, h4, h3, .content ul { + line-height: 26px; + margin-top: 26px; + margin-bottom: 26px; +} + +.content ul li { + margin-top: 13px; + margin-bottom: 13px; +} + +h1, h2 { + line-height: 48px; + font-size: 32px; + font-weight: normal; + margin: 8px 0 8px 2%; +} + +h3 { + font-size: 24px; +} + +h4 { + font-size: 1em; +} + +h1, h2, pre, code, .console, .status, #nav, #tagline { + font-family: 'Droid Sans Mono', 'Bitstream Vera Sans Mono', 'DejaVu Sans Mono', Monaco, Courier, monospace; +} + +a:link, a:visited { + color: #ef674a; +} + +p code { + font-size: 16px; + line-height: 16px; +} + +pre, .console { + background-color: #191919; + white-space: pre-wrap; + word-wrap: break-word; +} + +.console { + font-size: 16px; + height: 270px; + color: #dddddd; + margin-top: 26px; + margin-bottom: 26px; + border: 1px solid #888; + resize: auto; + overflow: auto; + padding: 2px; +} + +textarea { + width: 100%; + display: block; + -moz-box-sizing: border-box; + -webkit-box-sizing: border-box; +} + +#nav { + position: fixed; + top: 18px; + right: 2%; + font-size: 22px; + z-index: 99; +} + +#nav a:link, #nav a:visited { + color: #eaf2d9; +} + +#nav a { + text-decoration: none; + margin-left: 17px; +} + +#nav a:last { + margin: 0; +} + +#tagline { + position: absolute; + display: none; + top: 24px; + font-size: 14px; +} + +#guide pre { + font-size: 16px; + line-height: 26px; + color: #dddddd; + padding: 26px; + margin: 26px 0; +} + +#header, #demo { + clear: both; +} + +.ok { + background-color: green; +} + +.error { + background-color: red; +} + +.pending { + background-color: yellow; +} + +.status { + font-size: 14px; + padding: 2px; + margin-top: -24px; +} + +.header, .content { + clear: both; + width: 100%; + overflow: hidden; + color: #ede6da; +} + +.header { + clear: both; + width: 100%; + -webkit-box-shadow: 0px 4px 6px hsla(0, 0%, 0%, 0.4); + -moz-box-shadow: 0px 4px 6px hsla(0, 0%, 0%, 0.4); + background-color: #581406; +} + +.content { + background-color: #2d2929; +} + +.left { + float: left; + width: 100%; + position: relative; + -webkit-box-shadow: 2px 0px 6px hsla(0, 0%, 0%, 0.4); + -moz-box-shadow: 2px 0px 6px hsla(0, 0%, 0%, 0.4); +} + +.content .left, .header .left { + right: 50%; +} + +.content .left { + background-color: #272121; +} + +.header, .col1, .col2 { + float: left; + position: relative; + overflow: hidden; +} + +.col1 { + width: 96%; + left: 2%; +} + +.left .header { + width: 100%; + left: 50%; +} + +.left .col1 { + width: 46%; + left: 52%; +} + +.left .col2 { + width: 46%; + left: 56%; +} + +.docked { + position: fixed; + width: 100%; + top: 0; + background-color: hsla(10, 87%, 18%, 0.80); + z-index: 5; +} + +code .keyword { font-weight: bold; color: #dd7522 } +code .string, code .regexp { color: #669933 } +code .class, code .special { } +code .number { color: #eddd3d } +code .comment { color: grey } \ No newline at end of file diff --git a/node_modules/dust/docs/index.dust.html b/node_modules/dust/docs/index.dust.html new file mode 100644 index 0000000..0107408 --- /dev/null +++ b/node_modules/dust/docs/index.dust.html @@ -0,0 +1,95 @@ + + + + dust + + + {#inline names="index" ext="css"/} + + + + + + + + + + + {#tmpl names="select"/} + {#inline names="index" ext="js"/} + + +
+
+
+

{~lb}dust{~rb}

+ asynchronous streaming templates for the browser and node.js +
+ +
+

1. Select a template or write your own:

+ +
Ready
+

2. The compiled template registers itself by name:

+
+

When you're done messing around have a look at the guide.

+
+
+

3. Control template behavior with contexts and helpers:

+ +
Ready
+

4. Render or stream the result:

+

+        
+
+
+
+
+
+

{~lb}guide{~rb}

+
+
+ {#md}{#file name="syntax.md"/}{/md} +
+
+ {#md}{#file name="api.md"/}{/md} +
+
+
+
+
+
+

{~lb}tests{~rb}

+
+
+

If the console below indicates an error then we have a problem.

+

+        
+
+

Interested in seeing how Dust stacks up against similar templating engines? Have a look at the live benchmarks.

+
+
+
+
+
+
+

{~lb}about{~rb}

+
+
+ {#md}{#file name="about.md"/}{/md} +
+
+

Dust was created by akdubya.

+

This page is powered by Dust, jQuery, showdown, beautify.js, jsDump and hijs. +

+
+
+ + + \ No newline at end of file diff --git a/node_modules/dust/docs/index.js b/node_modules/dust/docs/index.js new file mode 100644 index 0000000..d1baaef --- /dev/null +++ b/node_modules/dust/docs/index.js @@ -0,0 +1,181 @@ +jsDump.parsers['function'] = function(fn) { + return fn.toString(); +} + +function renderDemo() { + var tmpl = dust.cache["demo"], + source = $('#input-context').val(); + + $('#output-text').empty(); + + if (tmpl && source) { + setPending('#input-context'); + setPending('#output-text'); + try { + eval("var context = " + source + ";"); + if (typeof context === 'function') { + context = context(); + } + dust.stream("demo", context) + .on('data', function(data) { + $('#output-text').append(dust.escapeHtml(data)); + }) + .on('end', function() { + setOkay('#input-context'); + setOkay('#output-text'); + }) + .on('error', function(err) { + setError('#input-context', err); + }); + } catch(err) { + setError('#input-context', err); + } + } +} + +function setOkay(sel) { + $(sel).next() + .removeClass('pending') + .addClass('ok') + .html('Ready'); +} + +function setPending(sel) { + $(sel).next() + .removeClass('ok') + .removeClass('error') + .addClass('pending') + .html('Pending'); +} + +function setError(sel, err) { + $(sel).next() + .removeClass('pending') + .addClass('error') + .html(err.toString()); +} + +function dump(obj) { + return js_beautify(jsDump.parse(obj), { + indent_size: 2 + }); +} + +function runSuite() { + var suite = new uutest.Suite({ + start: function() { + $('#test-console').empty(); + }, + pass: function() { + $('#test-console').append("."); + }, + fail: function() { + $('#test-console').append("F"); + }, + done: function(passed, failed, elapsed) { + $('#test-console').append("\n"); + $('#test-console').append(passed + " passed " + failed + " failed " + "(" + elapsed + "ms)"); + this.errors.forEach(function(err) { + $('#test-console').append("\n"); + $('#test-console').append(dust.escapeHtml(dumpError(err))); + }); + } + }); + coreSetup(suite, dustExamples.slice(1), dust); + suite.run(); +} + +function dumpError(err) { + var out = err.testName + " -> "; + if (!err.message) { + err.message = jsDump.parse(err.expected) + + " " + err.operator + " " + jsDump.parse(err.actual); + } + return out + err.stack; +} + +$(document).ready(function() { + + dustExamples.forEach(function(ex) { + dust.loadSource(dust.compile(ex.source, ex.name)); + }); + + runSuite(); + + $('#tagline').empty().show().css({left: ($(window).width() * .02) + 125}); + dust.loadSource(dust.compile(dustExamples[0].source, "intro")); + dust.stream("intro", dustExamples[0].context()) + .on('data', function(data) { + $('#tagline').append(data); + }) + .on('end', function() { + $('#tagline').delay(500).fadeOut('slow'); + }); + + dust.render("select", { + examples: dustExamples, + selected: function(chk, ctx) { + if (ctx.current().name === "replace") return "selected"; + } + }, function(err, output) { + $('#select').html(output); + }); + + $('#select > select').change(function() { + var idx = $(this).val(); + $('#input-source').val(dustExamples[idx].source); + $('#input-context').val(dump(dustExamples[idx].context)); + $('#input-source').change(); + }); + + $('#input-source').change(function() { + setPending('#input-source'); + try { + var compiled = dust.compile($(this).val(), "demo"); + dust.loadSource(compiled); + $('#output-js').text(js_beautify(compiled, { + indent_size: 2 + })); + setOkay('#input-source'); + } catch(err) { + setError('#input-source', err); + return; + } + renderDemo(); + }); + + $('#input-context').change(renderDemo); + + var sections = $("body > div"); + var cur_id; + + $(window).scroll(function() { + var scrollTop = $(window).scrollTop(); + + if (scrollTop === 0) { + cur_id = undefined; + $('.docked').remove(); + return; + } + + sections.each(function(idx, section) { + var sectionTop = section.offsetTop, + sectionBottom = sectionTop + section.offsetHeight; + + if (scrollTop >= sectionTop && scrollTop < sectionBottom) { + var $hdr = $(section).find('.header').clone(); + if (section.id !== cur_id) { + cur_id = section.id; + $('.docked').remove(); + $hdr.appendTo('body'); + $hdr.addClass('docked'); + } + return false; + } + }); + }); + + $('#select > select').change(); + $(window).scroll(); + +}); \ No newline at end of file diff --git a/node_modules/dust/docs/select.dust.html b/node_modules/dust/docs/select.dust.html new file mode 100644 index 0000000..130f384 --- /dev/null +++ b/node_modules/dust/docs/select.dust.html @@ -0,0 +1,5 @@ + \ No newline at end of file diff --git a/node_modules/dust/docs/syntax.md b/node_modules/dust/docs/syntax.md new file mode 100644 index 0000000..cef4423 --- /dev/null +++ b/node_modules/dust/docs/syntax.md @@ -0,0 +1,286 @@ +Dust is a JavaScript templating engine designed to provide a clean separation between presentation and logic without sacrificing ease of use. It is particularly well-suited for asynchronous and streaming applications. + +### Syntax + +Dust templates use two types of tags: _keys_ and _sections_. Keys reference fields within the current view context. You can think of them as placeholders that allow the context to insert data into the template. Sections accept template blocks that may be enumerated, filtered or transformed in various ways. + +### Keys + +To reference a key from the view context within the template, enclose the key in curly braces. For example, given the template below: + + Hello {name}! + +And the following view context: + + { name: "Fred" } + +The resulting output would be: + + Hello Fred! + +If the _name_ key cannot be found in the view, Dust outputs an empty string: + + Hello ! + +Generally, Dust casts whatever values it finds to strings. If Dust encounters a handler function it calls the function, passing in the current state of the template. + +#### Filters + +By default, the content of all key tags is HTML escaped, so assuming the _name_ key above resolves to a dangerous script tag: + + + +This would be rendered as: + + <script>alert('I am evil!')</script> + +To disable auto-escaping, append a pipe character '|' and an 's' to the end of the tag identifier, like so: + + Hello {name|s} + +There are several other built-in filters: `h` forces HTML escaping, `j` escapes JavaScript strings, `u` proxies to JavaScript's built-in `encodeURI`, and `uc` proxies to JavaScript's `encodeURIComponent`. Filters can also be chained together like so: + + Hello {name|s|h|u} + +When chained in this manner, filters are applied from left to right. Filters do not accept arguments; if you need more sophisticated behavior use a section tag instead. + +### Sections + +Keys are fine for simple lookups, but suppose the view context contains a _friends_ field which resolves to an array of objects containing _name_ and _age_ fields. This is where section tags are useful. + + {#friends} + {name}, {age}{~n} + {/friends} + +Here, the section begins with `{#friends}` and ends with `{/friends}`. Dust's default behavior is to enumerate over the array, passing each object in the array to the block. With a the following view context: + + { + friends: [ + { name: "Moe", age: 37 }, + { name: "Larry", age: 39 }, + { name: "Curly", age: 35 } + ] + } + +The output is as one might expect: + + Moe, 37 + Larry, 39 + Curly, 35 + +When _friends_ resolves to a value or object instead of an array, Dust sets the current context to the value and renders the block one time. If _friends_ resolves to a custom handler function, the function is given control over the section's behavior. + +Dust outputs nothing if the friends key is empty or nonexistent. Let's change that by inserting an `{:else}` tag, which tells Dust to render an alternate template block when a section key resolves to a falsy value: + + {#friends} + {name}, {age}{~n} + {:else} + You have no friends! + {/friends} + +Now when the friends key is empty or nonexistent we get the following: + + You have no friends! + +Internally, Dust builds a stack of contexts as templates delve deeper into nested sections. If a key is not found within the current context, Dust looks for the key within the parent context, and its parent, and so on. + +Self-closing section tags are allowed, so the template code below is permissible (although in this case it won't render anything): + + {#friends/} + +#### Paths + +Paths allow you to reference keys relative to the current context. + + {#names}{.} {/names} + +The dot notation above lets the template reference the current context implicitly, so given an array of strings: + + { names: ["Moe", "Larry", "Curly"] } + +The template block outputs each string in the array. + + Moe Larry Curly + +Paths can also be used to reach into nested contexts: + + {foo.bar} + +Or to constrain lookups to the current section scope: + + {.foo} + +To avoid brittle and confusing references, paths never backtrack up the context stack. If you need to drill into a key available within the parent context, pass the key as a parameter. + +#### Inline Parameters + +Inline parameters appear within the section's opening tag. Parameters are separated by a single space. By default, inline parameters merge values into the section's view context: + + {#profile bar="baz" bing="bong"} + {name}, {bar}, {bing} + {/profile} + +Assuming _name_ within the profile section resolves to "Fred", the output would be: + + Fred, baz, bong + +Inline parameters may be used to alias keys that conflict between parent and child contexts: + + {name}{~n} + {#profile root_name=name} + {name}, {root_name} + {/profile} + +Note here that we're passing in a key rather than a string literal. If the context is as follows: + + { + name: "Foo", + profile: { + name: "Bar" + } + } + +The output will be: + + Foo + Bar, Foo + +Parameters accept interpolated string literals as values: + + {#snippet id="{name}_id"/} + +#### Body Parameters + +Unlike inline parameters, which modify the context, body parameters pass named template blocks to handler functions. Body parameters are useful for implementing striping or other complex behaviors that might otherwise involve manually assembling strings within your view functions. The only body parameter with default behavior is the `{:else}` tag as seen above. + +#### Contexts + +Normally, upon encountering a section tag Dust merges the section's context with the parent context. Sometimes it can be useful to manually set the context provided to a section. Sections accept a context argument for this purpose: + + {#list:projects}{name}{/list} + +Here, we're providing an array of _projects_ to the _list_ section, which might be a special helper defined on the view. If _list_ is not a function but some other value instead, its parent context is simply set to _projects_. + +#### Special Sections + +In addition to the standard hashed (`#`) section tag, Dust provides a few section tags with special semantics, namely the _exists_ tag (`?`), the _notexists_ tag (`^`), and the context helpers tag (`@`). These tags make it easier to work with plain JSON data without additional helpers. + +The exists and notexists sections check for the existence (in the falsy sense) of a key within the current context. They do not alter the current context, making it possible to, for instance, check that an array is non-empty before wrapping it in HTML list tags: + + {?tags} +
    + {#tags} +
  • {.}
  • + {/tags} +
+ {:else} + No Tags! + {/tags} + +Unlike regular sections, conditional sections do not evaluate functions defined on the view. In those cases you'll still have to write your own handlers. + +The context helpers tag provides a couple of convenience functions to support iteration. The `sep` tag prints the enclosed block for every value except for the last. The `idx` tag passes the numerical index of the current element to the enclosed block. + + {#names}{.}{@idx}{.}{/idx}{@sep}, {/sep}{/names} + +The template above might output something like: + + Moe0, Larry1, Curly2 + +### Partials + +Partials, also known as template includes, allow you to compose templates at runtime. + + {>profile/} + +The block above looks for a template named "profile" and inserts its output into the parent template. Like sections, partials inherit the current context. And like sections, partials accept a context argument: + + {>profile:user/} + +Partial tags also accept string literals and interpolated string literals as keys: + + {>"path/to/comments.dust.html"/} + {>"posts/{type}.dust.html"/} + + This is useful when you're retrieving templates from the filesystem and the template names wouldn't otherwise be valid identifiers, or when selecting templates dynamically based on information from the view context. + +### Blocks and Inline Partials + +Often you'll want to have a template inherit the bulk of its content from a common base template. Dust solves this problem via blocks and inline partials. When placed within a template, blocks allow you to define snippets of template code that may be overriden by any templates that reference this template: + + Start{~n} + {+title} + Base Title + {/title} + {~n} + {+main} + Base Content + {/main} + {~n} + End + +Notice the special syntax for blocks: `{+block} ... {/block}`. When this template is rendered standalone, Dust simply renders the content within the blocks: + + Start + Base Title + Base Content + End + +But when the template is invoked from another template that contains inline partial tags (`{base_template/} + {base_template/} + {:else} + {+main/} + {/xhr} + {dust

{dust}

asynchronous streaming templates for the browser and node.js

1. Select a template or write your own:

Ready

2. The compiled template registers itself by name:

When you're done messing around have a look at the guide.

3. Control template behavior with contexts and helpers:

Ready

4. Render or stream the result:

{guide}

Dust is a JavaScript templating engine designed to provide a clean separation between presentation and logic without sacrificing ease of use. It is particularly well-suited for asynchronous and streaming applications.

+ +

Syntax

+ +

Dust templates use two types of tags: keys and sections. Keys reference fields within the current view context. You can think of them as placeholders that allow the context to insert data into the template. Sections accept template blocks that may be enumerated, filtered or transformed in various ways.

+ +

Keys

+ +

To reference a key from the view context within the template, enclose the key in curly braces. For example, given the template below:

+ +
Hello {name}!
+
+ +

And the following view context:

+ +
{ name: "Fred" }
+
+ +

The resulting output would be:

+ +
Hello Fred!
+
+ +

If the name key cannot be found in the view, Dust outputs an empty string:

+ +
Hello !
+
+ +

Generally, Dust casts whatever values it finds to strings. If Dust encounters a handler function it calls the function, passing in the current state of the template.

+ +

Filters

+ +

By default, the content of all key tags is HTML escaped, so assuming the name key above resolves to a dangerous script tag:

+ +
<script>alert('I am evil!')</script>
+
+ +

This would be rendered as:

+ +
&lt;script&gt;alert('I am evil!')&lt;/script&gt;
+
+ +

To disable auto-escaping, append a pipe character '|' and an 's' to the end of the tag identifier, like so:

+ +
Hello {name|s}
+
+ +

There are several other built-in filters: h forces HTML escaping, j escapes JavaScript strings, u proxies to JavaScript's built-in encodeURI, and uc proxies to JavaScript's encodeURIComponent. Filters can also be chained together like so:

+ +
Hello {name|s|h|u}
+
+ +

When chained in this manner, filters are applied from left to right. Filters do not accept arguments; if you need more sophisticated behavior use a section tag instead.

+ +

Sections

+ +

Keys are fine for simple lookups, but suppose the view context contains a friends field which resolves to an array of objects containing name and age fields. This is where section tags are useful.

+ +
{#friends}
+  {name}, {age}{~n}
+{/friends}
+
+ +

Here, the section begins with {#friends} and ends with {/friends}. Dust's default behavior is to enumerate over the array, passing each object in the array to the block. With a the following view context:

+ +
{
+  friends: [
+    { name: "Moe", age: 37 },
+    { name: "Larry", age: 39 },
+    { name: "Curly", age: 35 }
+  ]
+}
+
+ +

The output is as one might expect:

+ +
Moe, 37
+Larry, 39
+Curly, 35
+
+ +

When friends resolves to a value or object instead of an array, Dust sets the current context to the value and renders the block one time. If friends resolves to a custom handler function, the function is given control over the section's behavior.

+ +

Dust outputs nothing if the friends key is empty or nonexistent. Let's change that by inserting an {:else} tag, which tells Dust to render an alternate template block when a section key resolves to a falsy value:

+ +
{#friends}
+  {name}, {age}{~n}
+{:else}
+  You have no friends!
+{/friends}
+
+ +

Now when the friends key is empty or nonexistent we get the following:

+ +
You have no friends!
+
+ +

Internally, Dust builds a stack of contexts as templates delve deeper into nested sections. If a key is not found within the current context, Dust looks for the key within the parent context, and its parent, and so on.

+ +

Self-closing section tags are allowed, so the template code below is permissible (although in this case it won't render anything):

+ +
{#friends/}
+
+ +

Paths

+ +

Paths allow you to reference keys relative to the current context.

+ +
{#names}{.} {/names}
+
+ +

The dot notation above lets the template reference the current context implicitly, so given an array of strings:

+ +
{ names: ["Moe", "Larry", "Curly"] }
+
+ +

The template block outputs each string in the array.

+ +
Moe Larry Curly 
+
+ +

Paths can also be used to reach into nested contexts:

+ +
{foo.bar}
+
+ +

Or to constrain lookups to the current section scope:

+ +
{.foo}
+
+ +

To avoid brittle and confusing references, paths never backtrack up the context stack. If you need to drill into a key available within the parent context, pass the key as a parameter.

+ +

Inline Parameters

+ +

Inline parameters appear within the section's opening tag. Parameters are separated by a single space. By default, inline parameters merge values into the section's view context:

+ +
{#profile bar="baz" bing="bong"}
+  {name}, {bar}, {bing}
+{/profile}
+
+ +

Assuming name within the profile section resolves to "Fred", the output would be:

+ +
Fred, baz, bong
+
+ +

Inline parameters may be used to alias keys that conflict between parent and child contexts:

+ +
{name}{~n}
+{#profile root_name=name}
+  {name}, {root_name}
+{/profile}
+
+ +

Note here that we're passing in a key rather than a string literal. If the context is as follows:

+ +
{
+  name: "Foo",
+  profile: {
+    name: "Bar"
+  }
+}
+
+ +

The output will be:

+ +
Foo
+Bar, Foo
+
+ +

Parameters accept interpolated string literals as values:

+ +
{#snippet id="{name}_id"/}
+
+ +

Body Parameters

+ +

Unlike inline parameters, which modify the context, body parameters pass named template blocks to handler functions. Body parameters are useful for implementing striping or other complex behaviors that might otherwise involve manually assembling strings within your view functions. The only body parameter with default behavior is the {:else} tag as seen above.

+ +

Contexts

+ +

Normally, upon encountering a section tag Dust merges the section's context with the parent context. Sometimes it can be useful to manually set the context provided to a section. Sections accept a context argument for this purpose:

+ +
{#list:projects}{name}{/list}
+
+ +

Here, we're providing an array of projects to the list section, which might be a special helper defined on the view. If list is not a function but some other value instead, its parent context is simply set to projects.

+ +

Special Sections

+ +

In addition to the standard hashed (#) section tag, Dust provides a few section tags with special semantics, namely the exists tag (?), the notexists tag (^), and the context helpers tag (@). These tags make it easier to work with plain JSON data without additional helpers.

+ +

The exists and notexists sections check for the existence (in the falsy sense) of a key within the current context. They do not alter the current context, making it possible to, for instance, check that an array is non-empty before wrapping it in HTML list tags:

+ +
{?tags}
+  <ul>
+    {#tags}
+      <li>{.}</li>
+    {/tags}
+  </ul>
+{:else}
+  No Tags!
+{/tags}
+
+ +

Unlike regular sections, conditional sections do not evaluate functions defined on the view. In those cases you'll still have to write your own handlers.

+ +

The context helpers tag provides a couple of convenience functions to support iteration. The sep tag prints the enclosed block for every value except for the last. The idx tag passes the numerical index of the current element to the enclosed block.

+ +
{#names}{.}{@idx}{.}{/idx}{@sep}, {/sep}{/names}
+
+ +

The template above might output something like:

+ +
Moe0, Larry1, Curly2
+
+ +

Partials

+ +

Partials, also known as template includes, allow you to compose templates at runtime.

+ +
{>profile/}
+
+ +

The block above looks for a template named "profile" and inserts its output into the parent template. Like sections, partials inherit the current context. And like sections, partials accept a context argument:

+ +
{>profile:user/}
+
+ +

Partial tags also accept string literals and interpolated string literals as keys:

+ +
{>"path/to/comments.dust.html"/}
+{>"posts/{type}.dust.html"/}
+
+ +

This is useful when you're retrieving templates from the filesystem and the template names wouldn't otherwise be valid identifiers, or when selecting templates dynamically based on information from the view context.

+ +

Blocks and Inline Partials

+ +

Often you'll want to have a template inherit the bulk of its content from a common base template. Dust solves this problem via blocks and inline partials. When placed within a template, blocks allow you to define snippets of template code that may be overriden by any templates that reference this template:

+ +
Start{~n}
+{+title}
+  Base Title
+{/title}
+{~n}
+{+main}
+  Base Content
+{/main}
+{~n}
+End
+
+ +

Notice the special syntax for blocks: {+block} ... {/block}. When this template is rendered standalone, Dust simply renders the content within the blocks:

+ +
Start
+Base Title
+Base Content
+End
+
+ +

But when the template is invoked from another template that contains inline partial tags ({<snippet} ... {/snippet}):

+ +
{>base_template/}
+{<title}
+  Child Title
+{/title}
+{<main}
+  Child Content
+{/main}
+
+ +

Dust overrides the block contents of the base template:

+ +
Start
+Child Title
+Child Content
+End
+
+ +

A block may be self-closing ({+block/}), in which case it is not displayed unless a calling template overrides the content of the block. Inline partials never output content themselves, and are always global to the template in which they are defined, so the order of their definition has no significance. They are passed to all templates invoked by the template in which they are defined.

+ +

Note that blocks can be used to render inline partials that are defined within the same template. This is useful when you want to use the same template to serve AJAX requests and regular requests:

+ +
{^xhr}
+  {>base_template/}
+{:else}
+  {+main/}
+{/xhr}
+{<title}
+  Child Title
+{/title}
+{<main}
+  Child Content
+{/main}
+
+ +

Static Text

+ +

The Dust parser is finely tuned to minimize the amount of escaping that needs to be done within static text. Any text that does not closely resemble a Dust tag is considered static and will be passed through untouched to the template's output. This makes Dust suitable for use in templating many different formats. In order to be recognized as such, Dust tags should not contain extraneous whitespace and newlines.

+ +

Special Characters

+ +

Depending on whitespace and delimeter settings, it is sometimes necessary to include escape tags within static text. Escape tags begin with a tilde (~), followed by a key identifying the desired escape sequence. Currently newline (n), carriage return (r), space (s), left brace (lb) and right brace (rb) are supported. For example:

+ +
Hello World!{~n}
+
+ +

Inserts a newline after the text. By default, Dust compresses whitespace by eliminating newlines and indentation. This behavior can be toggled at compile time.

+ +

Comments

+ +

Comments, which do not appear in template output, begin and end with a bang (!):

+ +
{!
+  Multiline
+  {#foo}{bar}{/foo}
+!}
+{!before!}Hello{!after!}
+
+ +

The template above would render as follows:

+ +
Hello
+

A pure JavaScript library, Dust is runs in both browser-side and server-side environments. Dust templates are compiled and then loaded where they are needed along with the runtime library. The library doesn't make any assumptions about how templates are loaded; you are free to integrate templating into your environment as you see fit.

+ +

Installation

+ +

To run Dust within Node.js, first install via npm:

+ +
npm install dust
+
+ +

Then, within your Node script or the REPL:

+ +
var dust = require('dust');
+
+ +

This will import everything needed to parse, compile and render templates. To render Dust templates in the browser, grab the runtime distribution and include it in your script tags along with your compiled templates:

+ +
<script src="dust-core-0.3.0.min.js"></script>
+<script src="compiled_templates.js"></script>
+
+ +

Include the full distribution if you want to compile templates within the browser (as in the online demo):

+ +
<script src="dust-full-0.3.0.min.js"></script>
+
+ +

Precompilation is the recommended approach for general use.

+ +

Compiling Templates

+ +

Use dust.compile to compile a template body into a string of JavaScript source code:

+ +
var compiled = dust.compile("Hello {name}!", "intro");
+
+ +

The variable compiled now contains the following string:

+ +
'(function(){dust.register("intro",body_0) ...'
+
+ +

If you save this source to a file and include the file in your HTML script tags, the compiled template will automatically register itself with the local runtime, under the name "intro". To evaluate a compiled template string manually, use dust.loadSource:

+ +
dust.loadSource(compiled);
+
+ +

The template is now available within the dust.cache object.

+ +

Rendering Templates

+ +

The rendering engine provides both callback and streaming interfaces.

+ +

The Callback Interface

+ +

To render a template, call dust.render with the template name, a context object and a callback function:

+ +
dust.render("intro", {name: "Fred"}, function(err, out) {
+  console.log(out);
+});
+
+ +

The code above will write the following to the console:

+ +
Hello Fred!
+
+ +

The Streaming Interface

+ +

Templates may also be streamed. dust.stream returns a handler very similar to a Node EventEmitter:

+ +
dust.stream("index", context)
+    .on("data", function(data) {
+      console.log(data);
+    })
+    .on("end", function() {
+      console.log("I'm finished!");
+    })
+    .on("error", function(err) {
+      console.log("Something terrible happened!");
+    });
+
+ +

When used with specially crafted context handlers, the streaming interface provides chunked template rendering.

+ +

Contexts

+ +

The context is a special object that handles variable lookups and controls template behavior. It is the interface between your application logic and your templates. The context can be visualized as a stack of objects that grows as we descend into nested sections:

+ +
global     --> { helper: function() { ... }, ... }
+root       --> { profile: { ... }, ... }
+profile    --> { friends: [ ... ], ... }
+friends[0] --> { name: "Jorge", ... }
+
+ +

When looking up a key, Dust searches the context stack from the bottom up. There is no need to merge helper functions into the template data; instead, create a base context onto which you can push your local template data:

+ +
// Set up a base context with global helpers
+var base = dust.makeBase({
+  sayHello: function() { return "Hello!" }
+});
+
+// Push to the base context at render time
+dust.render("index", base.push({foo: "bar"}), function(err, out) {
+  console.log(out);
+});
+
+ +

Dust does not care how your reference objects are built. You may, for example, push prototyped objects onto the stack. The system leaves the this keyword intact when calling handler functions on your objects.

+ +

Handlers

+ +

When Dust encounters a function in the context, it calls the function, passing in arguments that reflect the current state of the template. In the simplest case, a handler can pass a value back to the template engine:

+ +
{
+  name: function() {
+    return "Bob";
+  }
+}
+
+ +

Chunks

+ +

But handlers can do much more than return values: they have complete control over the flow of the template, using the same API Dust uses internally. For example, the handler below writes a string directly to the current template chunk:

+ +
{
+  name: function(chunk) {
+    return chunk.write("Bob");
+  }
+}
+
+ +

A Chunk is a Dust primitive for controlling the flow of the template. Depending upon the behaviors defined in the context, templates may output one or more chunks during rendering. A handler that writes to a chunk directly must return the modified chunk.

+ +

Accessing the Context

+ +

Handlers have access to the context object:

+ +
{
+  wrap: function(chunk, context) {
+    return chunk.write(context.get("foo"));
+  }
+}
+
+ +

context.get("foo") searches for foo within the context stack. context.current() retrieves the value most recently pushed onto the context stack.

+ +

Accessing Body Parameters

+ +

The bodies object provides access to any bodies defined within the calling block.

+ +
{#guide}foo{:else}bar{/guide}
+
+ +

The template above will either render "foo" or "bar" depending on the behavior of the handler below:

+ +
{
+  guide: function(chunk, context, bodies) {
+    if (secret === 42) {
+      return chunk.render(bodies.block, context);
+    } else {
+      return chunk.render(bodies['else'], context);
+    }
+  }
+}
+
+ +

bodies.block is a special parameter that returns the default (unnamed) block. chunk.render renders the chosen block.

+ +

Accessing Inline Parameters

+ +

The params object contains any inline parameters passed to a section tag:

+ +
{
+  hello: function(chunk, context, bodies, params) {
+    if (params.greet === "true") {
+      return chunk.write("Hello!");
+    }
+    return chunk;
+  }
+}
+
+ +

Asynchronous Handlers

+ +

You may define handlers that execute asynchronously and in parallel:

+ +
{
+  type: function(chunk) {
+    return chunk.map(function(chunk) {
+      setTimeout(function() {
+        chunk.end("Async");
+      });
+    });
+  }
+}
+
+ +

chunk.map tells Dust to manufacture a new chunk, reserving a slot in the output stream before continuing on to render the rest of the template. You must (eventually) call chunk.end() on a mapped chunk to weave its content back into the stream.

+ +

chunk.map provides a convenient way to split up templates rendered via dust.stream. For example, you might wrap the head of an HTML document in a special {#head} ... {/head} tag that is flushed to the browser before the rest of the body has finished rendering.

+ +

Reference

+ +

Compiling

+ +
dust.compile(source, name)
+
+ +

Compiles source into a JavaScript template string. Registers itself under name when evaluated.

+ +
dust.compileFn(source, [name])
+
+ +

Compiles source directly into a JavaScript function that takes a context and an optional callback (see dust.renderSource). Registers the template under name if this argument is supplied.

+ +
dust.optimizers
+
+ +

Object containing functions that transform the parse-tree before the template is compiled. To disable whitespace compression:

+ +
dust.optimizers.format = function(ctx, node) { return node };
+
+ +

Loading

+ +
dust.register(name, fn)
+
+ +

Used internally to register template function fn with the runtime environment. Override to customize the way Dust caches templates.

+ +
dust.onLoad(name, callback(err, out))
+
+ +

By default Dust returns a "template not found" error when a named template cannot be located in the cache. Override onLoad to specify a fallback loading mechanism (e.g., to load templates from the filesystem or a database).

+ +
dust.loadSource(source, [filename])
+
+ +

Evaluates compiled source string. In Node.js, evaluates source as if it were loaded from filename. filename is optional.

+ +

Rendering

+ +
dust.render(name, context, callback(error, output))
+
+ +

Renders the named template and calls callback on completion. context may be a plain object or an instance of dust.Context.

+ +
dust.stream(name, context)
+
+ +

Streams the named template. context may be a plain object or an instance of dust.Context. Returns an instance of dust.Stream.

+ +
stream.on("data", listener(data))
+stream.on("end", listener)
+stream.on("error", listener(error))
+
+ +

Registers an event listener. Streams accept a single listener for a given event.

+ +
dust.renderSource(source, context, [callback(error, output)])
+
+ +

Compiles and renders source, invoking callback on completion. If no callback is supplied this function returns a Stream object. Use this function when precompilation is not required.

+ +

Contexts

+ +
dust.makeBase(object)
+
+ +

Manufactures a dust.Context instance with its global object set to object.

+ +
context.get(key)
+
+ +

Retrieves the value at key from the context stack.

+ +
context.push(head, [index], [length])
+
+ +

Pushes an arbitrary value onto the context stack and returns a new context instance. Specify index and/or length to enable enumeration helpers.

+ +
context.rebase(head)
+
+ +

Returns a new context instance consisting only of the value at head, plus any previously defined global object.

+ +
context.current()
+
+ +

Returns the head of the context stack.

+ +

Chunks

+ +

The operations below always return a chunk object.

+ +
chunk.write(data)
+
+ +

Writes data to this chunk's buffer.

+ +
chunk.map(callback(chunk))
+
+ +

Creates a new chunk and passes it to callback. Use map to wrap asynchronous functions and to partition the template for streaming.

+ +
chunk.end(data)
+
+ +

Writes data to this chunk's buffer and marks it as flushable. This method must be called on any chunks created via chunk.map. Do not call this method on a handler's main chunk -- dust.render and dust.stream take care of this for you.

+ +
chunk.tap(callback)
+chunk.untap()
+
+ +

Convenience methods for applying filters to a stream. See the filter demo for an example.

+ +
chunk.render(body, context)
+
+ +

Renders a template block, such as a default block or an else block. Basically equivalent to body(chunk, context).

+ +
chunk.setError(error)
+
+ +

Sets an error on this chunk and immediately flushes the output.

+ +
chunk.reference(elem, context, auto, filters)
+chunk.section(elem, context, bodies, params)
+chunk.exists(elem, context, bodies)
+chunk.notexists(elem, context, bodies)
+chunk.block(elem, context, bodies)
+chunk.partial(elem, context)
+chunk.helper(name, context, bodies, params)
+
+ +

These methods implement Dust's default behavior for keys, sections, blocks, partials and context helpers. While it is unlikely you'll need to modify these methods or invoke them from within handlers, the source code may be a useful point of reference for developers.

+ +

Utilities

+ +
dust.filters
+
+ +

Object containing built-in key filters. Can be customized with additional filters.

+ +
dust.helpers
+
+ +

Object containing the built-in context helpers. These may also be customized.

+ +
dust.escapeHtml
+
+ +

HTML escape function used by dust.filters.h.

+ +
dust.escapeJs
+
+ +

JavaScript string escape function used by dust.filters.j.

{tests}

If the console below indicates an error then we have a problem.

Interested in seeing how Dust stacks up against similar templating engines? Have a look at the live benchmarks.

{about}

Why Dust? Why another templating engine when there are so many alternatives? Dust is based on the philosophy that an ideal templating environment should be:

+ +
    +
  • Markup-like: A templating syntax should not encompass operations that are better left to a programming language. Templates should make it easy to format content for presentation while keeping application logic where it belongs: in the application.
  • +
  • Asynchronous: Template helpers should be callable asynchronously and in parallel so that expensive operations (caching, deferred loading, filtering) can run as the template is being rendered.
  • +
  • Streaming: Templates should allow (but not require) data to be flushed to the output in user-defined chunks.
  • +
  • Browser and server compatible: Templates should render in both server and browser environments without hacks or extensive configuration.
  • +
  • Storage agnostic: The templating engine should not impose a particular loading scheme. Developers should be free to load templates via the filesystem, a database or an army of carrier pigeons.
  • +
  • Composable: Designers should be able to break presentation markup into manageable components and combine these components at runtime. It should not be necessary to statically link templates or manually assemble 'layouts' inside application code.
  • +
  • Format agnostic: While HTML generation and DOM manipulation are useful in specific instances, a general-purpose template system should not be tied to a particular output format.
  • +
  • Precise: The parser should be accurate enough that designers rarely have to use escape sequences to achieve the desired result. Similarly, templates shouldn't mysteriously generate or eliminate whitespace.
  • +
  • Safe(r): At the very least, the engine should be configurable such that it is reasonably safe to render untrusted templates in a server environment.
  • +
  • Fast: Server-side templates cannot always be cached. Browser-side templates may be rendered on devices with limited system resources. A template engine should be fast enough to render in real time without bottlenecking its environment.
  • +
+ +

If this list leaves you nodding your head in agreement you should give Dust a try.

Dust was created by akdubya.

This page is powered by Dust, jQuery, showdown, beautify.js, jsDump and hijs.

\ No newline at end of file diff --git a/node_modules/dust/lib/compiler.js b/node_modules/dust/lib/compiler.js new file mode 100644 index 0000000..9eaef40 --- /dev/null +++ b/node_modules/dust/lib/compiler.js @@ -0,0 +1,319 @@ +(function(dust) { + +dust.compile = function(source, name) { + var ast = filterAST(dust.parse(source)); + return compile(ast, name); +}; + +function filterAST(ast) { + var context = {}; + return dust.filterNode(context, ast); +} + +dust.filterNode = function(context, node) { + return dust.optimizers[node[0]](context, node); +} + +dust.optimizers = { + body: compactBuffers, + buffer: noop, + special: convertSpecial, + format: nullify, // TODO: convert format + reference: visit, + "#": visit, + "?": visit, + "^": visit, + "<": visit, + "+": visit, + "@": visit, + "%": visit, + partial: visit, + context: visit, + params: visit, + bodies: visit, + param: visit, + filters: noop, + key: noop, + path: noop, + literal: noop, + comment: nullify +} + +dust.pragmas = { + esc: function(compiler, context, bodies, params) { + var old = compiler.auto; + if (!context) context = 'h'; + compiler.auto = (context === 's') ? '' : context; + var out = compileParts(compiler, bodies.block); + compiler.auto = old; + return out; + } +} + +function visit(context, node) { + var out = [node[0]]; + for (var i=1, len=node.length; i\"]/), + AMP = /&/g, + LT = //g, + QUOT = /\"/g; + +dust.escapeHtml = function(s) { + if (typeof s === "string") { + if (!HCHARS.test(s)) { + return s; + } + return s.replace(AMP,'&').replace(LT,'<').replace(GT,'>').replace(QUOT,'"'); + } + return s; +}; + +var BS = /\\/g, + CR = /\r/g, + LS = /\u2028/g, + PS = /\u2029/g, + NL = /\n/g, + LF = /\f/g, + SQ = /'/g, + DQ = /"/g, + TB = /\t/g; + +dust.escapeJs = function(s) { + if (typeof s === "string") { + return s + .replace(BS, '\\\\') + .replace(DQ, '\\"') + .replace(SQ, "\\'") + .replace(CR, '\\r') + .replace(LS, '\\u2028') + .replace(PS, '\\u2029') + .replace(NL, '\\n') + .replace(LF, '\\f') + .replace(TB, "\\t"); + } + return s; +}; + +})(dust); + +if (typeof exports !== "undefined") { + if (typeof process !== "undefined") { + require('./server')(dust); + } + module.exports = dust; +} diff --git a/node_modules/dust/lib/parser.js b/node_modules/dust/lib/parser.js new file mode 100644 index 0000000..313781d --- /dev/null +++ b/node_modules/dust/lib/parser.js @@ -0,0 +1,2368 @@ +(function(dust){ + +var parser = (function(){ + /* Generated by PEG.js (http://pegjs.majda.cz/). */ + + var result = { + /* + * Parses the input with a generated parser. If the parsing is successfull, + * returns a value explicitly or implicitly specified by the grammar from + * which the parser was generated (see |PEG.buildParser|). If the parsing is + * unsuccessful, throws |PEG.parser.SyntaxError| describing the error. + */ + parse: function(input) { + var pos = 0; + var reportMatchFailures = true; + var rightmostMatchFailuresPos = 0; + var rightmostMatchFailuresExpected = []; + var cache = {}; + + function padLeft(input, padding, length) { + var result = input; + + var padLength = length - input.length; + for (var i = 0; i < padLength; i++) { + result = padding + result; + } + + return result; + } + + function escape(ch) { + var charCode = ch.charCodeAt(0); + + if (charCode < 0xFF) { + var escapeChar = 'x'; + var length = 2; + } else { + var escapeChar = 'u'; + var length = 4; + } + + return '\\' + escapeChar + padLeft(charCode.toString(16).toUpperCase(), '0', length); + } + + function quote(s) { + /* + * ECMA-262, 5th ed., 7.8.4: All characters may appear literally in a + * string literal except for the closing quote character, backslash, + * carriage return, line separator, paragraph separator, and line feed. + * Any character may appear in the form of an escape sequence. + */ + return '"' + s + .replace(/\\/g, '\\\\') // backslash + .replace(/"/g, '\\"') // closing quote character + .replace(/\r/g, '\\r') // carriage return + .replace(/\n/g, '\\n') // line feed + .replace(/[\x80-\uFFFF]/g, escape) // non-ASCII characters + + '"'; + } + + function matchFailed(failure) { + if (pos < rightmostMatchFailuresPos) { + return; + } + + if (pos > rightmostMatchFailuresPos) { + rightmostMatchFailuresPos = pos; + rightmostMatchFailuresExpected = []; + } + + rightmostMatchFailuresExpected.push(failure); + } + + function parse_body() { + var cacheKey = "body" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + + var result1 = []; + var result2 = parse_part(); + while (result2 !== null) { + result1.push(result2); + var result2 = parse_part(); + } + var result0 = result1 !== null + ? (function(p) { return ["body"].concat(p) })(result1) + : null; + + + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_part() { + var cacheKey = "part" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + + var result6 = parse_comment(); + if (result6 !== null) { + var result0 = result6; + } else { + var result5 = parse_section(); + if (result5 !== null) { + var result0 = result5; + } else { + var result4 = parse_partial(); + if (result4 !== null) { + var result0 = result4; + } else { + var result3 = parse_special(); + if (result3 !== null) { + var result0 = result3; + } else { + var result2 = parse_reference(); + if (result2 !== null) { + var result0 = result2; + } else { + var result1 = parse_buffer(); + if (result1 !== null) { + var result0 = result1; + } else { + var result0 = null;; + }; + }; + }; + }; + }; + } + + + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_section() { + var cacheKey = "section" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + var savedReportMatchFailures = reportMatchFailures; + reportMatchFailures = false; + var savedPos1 = pos; + var result8 = parse_sec_tag_start(); + if (result8 !== null) { + var result9 = parse_rd(); + if (result9 !== null) { + var result10 = parse_body(); + if (result10 !== null) { + var result11 = parse_bodies(); + if (result11 !== null) { + var result12 = parse_end_tag(); + if (result12 !== null) { + var result13 = (function() {return result8[1].text === result12.text})() ? '' : null; + if (result13 !== null) { + var result7 = [result8, result9, result10, result11, result12, result13]; + } else { + var result7 = null; + pos = savedPos1; + } + } else { + var result7 = null; + pos = savedPos1; + } + } else { + var result7 = null; + pos = savedPos1; + } + } else { + var result7 = null; + pos = savedPos1; + } + } else { + var result7 = null; + pos = savedPos1; + } + } else { + var result7 = null; + pos = savedPos1; + } + var result6 = result7 !== null + ? (function(t, b, e, n) { e.push(["param", ["literal", "block"], b]); t.push(e); return t })(result7[0], result7[2], result7[3], result7[4]) + : null; + if (result6 !== null) { + var result0 = result6; + } else { + var savedPos0 = pos; + var result3 = parse_sec_tag_start(); + if (result3 !== null) { + if (input.substr(pos, 1) === "/") { + var result4 = "/"; + pos += 1; + } else { + var result4 = null; + if (reportMatchFailures) { + matchFailed("\"/\""); + } + } + if (result4 !== null) { + var result5 = parse_rd(); + if (result5 !== null) { + var result2 = [result3, result4, result5]; + } else { + var result2 = null; + pos = savedPos0; + } + } else { + var result2 = null; + pos = savedPos0; + } + } else { + var result2 = null; + pos = savedPos0; + } + var result1 = result2 !== null + ? (function(t) { t.push(["bodies"]); return t })(result2[0]) + : null; + if (result1 !== null) { + var result0 = result1; + } else { + var result0 = null;; + }; + } + reportMatchFailures = savedReportMatchFailures; + if (reportMatchFailures && result0 === null) { + matchFailed("section"); + } + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_sec_tag_start() { + var cacheKey = "sec_tag_start" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + + var savedPos0 = pos; + var result2 = parse_ld(); + if (result2 !== null) { + if (input.substr(pos).match(/^[#?^<+@%]/) !== null) { + var result3 = input.charAt(pos); + pos++; + } else { + var result3 = null; + if (reportMatchFailures) { + matchFailed("[#?^<+@%]"); + } + } + if (result3 !== null) { + var result4 = parse_identifier(); + if (result4 !== null) { + var result5 = parse_context(); + if (result5 !== null) { + var result6 = parse_params(); + if (result6 !== null) { + var result1 = [result2, result3, result4, result5, result6]; + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + var result0 = result1 !== null + ? (function(t, n, c, p) { return [t, n, c, p] })(result1[1], result1[2], result1[3], result1[4]) + : null; + + + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_end_tag() { + var cacheKey = "end_tag" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + var savedReportMatchFailures = reportMatchFailures; + reportMatchFailures = false; + var savedPos0 = pos; + var result2 = parse_ld(); + if (result2 !== null) { + if (input.substr(pos, 1) === "/") { + var result3 = "/"; + pos += 1; + } else { + var result3 = null; + if (reportMatchFailures) { + matchFailed("\"/\""); + } + } + if (result3 !== null) { + var result4 = parse_identifier(); + if (result4 !== null) { + var result5 = parse_rd(); + if (result5 !== null) { + var result1 = [result2, result3, result4, result5]; + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + var result0 = result1 !== null + ? (function(n) { return n })(result1[2]) + : null; + reportMatchFailures = savedReportMatchFailures; + if (reportMatchFailures && result0 === null) { + matchFailed("end tag"); + } + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_context() { + var cacheKey = "context" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + + var savedPos0 = pos; + if (input.substr(pos, 1) === ":") { + var result4 = ":"; + pos += 1; + } else { + var result4 = null; + if (reportMatchFailures) { + matchFailed("\":\""); + } + } + if (result4 !== null) { + var result5 = parse_identifier(); + if (result5 !== null) { + var result3 = [result4, result5]; + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + var result2 = result3 !== null + ? (function(n) {return n})(result3[1]) + : null; + var result1 = result2 !== null ? result2 : ''; + var result0 = result1 !== null + ? (function(n) { return n ? ["context", n] : ["context"] })(result1) + : null; + + + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_params() { + var cacheKey = "params" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + var savedReportMatchFailures = reportMatchFailures; + reportMatchFailures = false; + var result1 = []; + var savedPos0 = pos; + var result4 = parse_ws(); + if (result4 !== null) { + var result5 = parse_key(); + if (result5 !== null) { + if (input.substr(pos, 1) === "=") { + var result6 = "="; + pos += 1; + } else { + var result6 = null; + if (reportMatchFailures) { + matchFailed("\"=\""); + } + } + if (result6 !== null) { + var result9 = parse_identifier(); + if (result9 !== null) { + var result7 = result9; + } else { + var result8 = parse_inline(); + if (result8 !== null) { + var result7 = result8; + } else { + var result7 = null;; + }; + } + if (result7 !== null) { + var result3 = [result4, result5, result6, result7]; + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + var result2 = result3 !== null + ? (function(k, v) {return ["param", ["literal", k], v]})(result3[1], result3[3]) + : null; + while (result2 !== null) { + result1.push(result2); + var savedPos0 = pos; + var result4 = parse_ws(); + if (result4 !== null) { + var result5 = parse_key(); + if (result5 !== null) { + if (input.substr(pos, 1) === "=") { + var result6 = "="; + pos += 1; + } else { + var result6 = null; + if (reportMatchFailures) { + matchFailed("\"=\""); + } + } + if (result6 !== null) { + var result9 = parse_identifier(); + if (result9 !== null) { + var result7 = result9; + } else { + var result8 = parse_inline(); + if (result8 !== null) { + var result7 = result8; + } else { + var result7 = null;; + }; + } + if (result7 !== null) { + var result3 = [result4, result5, result6, result7]; + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + var result2 = result3 !== null + ? (function(k, v) {return ["param", ["literal", k], v]})(result3[1], result3[3]) + : null; + } + var result0 = result1 !== null + ? (function(p) { return ["params"].concat(p) })(result1) + : null; + reportMatchFailures = savedReportMatchFailures; + if (reportMatchFailures && result0 === null) { + matchFailed("params"); + } + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_bodies() { + var cacheKey = "bodies" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + var savedReportMatchFailures = reportMatchFailures; + reportMatchFailures = false; + var result1 = []; + var savedPos0 = pos; + var result4 = parse_ld(); + if (result4 !== null) { + if (input.substr(pos, 1) === ":") { + var result5 = ":"; + pos += 1; + } else { + var result5 = null; + if (reportMatchFailures) { + matchFailed("\":\""); + } + } + if (result5 !== null) { + var result6 = parse_key(); + if (result6 !== null) { + var result7 = parse_rd(); + if (result7 !== null) { + var result8 = parse_body(); + if (result8 !== null) { + var result3 = [result4, result5, result6, result7, result8]; + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + var result2 = result3 !== null + ? (function(k, v) {return ["param", ["literal", k], v]})(result3[2], result3[4]) + : null; + while (result2 !== null) { + result1.push(result2); + var savedPos0 = pos; + var result4 = parse_ld(); + if (result4 !== null) { + if (input.substr(pos, 1) === ":") { + var result5 = ":"; + pos += 1; + } else { + var result5 = null; + if (reportMatchFailures) { + matchFailed("\":\""); + } + } + if (result5 !== null) { + var result6 = parse_key(); + if (result6 !== null) { + var result7 = parse_rd(); + if (result7 !== null) { + var result8 = parse_body(); + if (result8 !== null) { + var result3 = [result4, result5, result6, result7, result8]; + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + var result2 = result3 !== null + ? (function(k, v) {return ["param", ["literal", k], v]})(result3[2], result3[4]) + : null; + } + var result0 = result1 !== null + ? (function(p) { return ["bodies"].concat(p) })(result1) + : null; + reportMatchFailures = savedReportMatchFailures; + if (reportMatchFailures && result0 === null) { + matchFailed("bodies"); + } + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_reference() { + var cacheKey = "reference" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + var savedReportMatchFailures = reportMatchFailures; + reportMatchFailures = false; + var savedPos0 = pos; + var result2 = parse_ld(); + if (result2 !== null) { + var result3 = parse_identifier(); + if (result3 !== null) { + var result4 = parse_filters(); + if (result4 !== null) { + var result5 = parse_rd(); + if (result5 !== null) { + var result1 = [result2, result3, result4, result5]; + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + var result0 = result1 !== null + ? (function(n, f) { return ["reference", n, f] })(result1[1], result1[2]) + : null; + reportMatchFailures = savedReportMatchFailures; + if (reportMatchFailures && result0 === null) { + matchFailed("reference"); + } + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_partial() { + var cacheKey = "partial" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + var savedReportMatchFailures = reportMatchFailures; + reportMatchFailures = false; + var savedPos0 = pos; + var result2 = parse_ld(); + if (result2 !== null) { + if (input.substr(pos, 1) === ">") { + var result3 = ">"; + pos += 1; + } else { + var result3 = null; + if (reportMatchFailures) { + matchFailed("\">\""); + } + } + if (result3 !== null) { + var result10 = parse_key(); + var result9 = result10 !== null + ? (function(k) {return ["literal", k]})(result10) + : null; + if (result9 !== null) { + var result4 = result9; + } else { + var result8 = parse_inline(); + if (result8 !== null) { + var result4 = result8; + } else { + var result4 = null;; + }; + } + if (result4 !== null) { + var result5 = parse_context(); + if (result5 !== null) { + if (input.substr(pos, 1) === "/") { + var result6 = "/"; + pos += 1; + } else { + var result6 = null; + if (reportMatchFailures) { + matchFailed("\"/\""); + } + } + if (result6 !== null) { + var result7 = parse_rd(); + if (result7 !== null) { + var result1 = [result2, result3, result4, result5, result6, result7]; + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + var result0 = result1 !== null + ? (function(n, c) { return ["partial", n, c] })(result1[2], result1[3]) + : null; + reportMatchFailures = savedReportMatchFailures; + if (reportMatchFailures && result0 === null) { + matchFailed("partial"); + } + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_filters() { + var cacheKey = "filters" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + var savedReportMatchFailures = reportMatchFailures; + reportMatchFailures = false; + var result1 = []; + var savedPos0 = pos; + if (input.substr(pos, 1) === "|") { + var result4 = "|"; + pos += 1; + } else { + var result4 = null; + if (reportMatchFailures) { + matchFailed("\"|\""); + } + } + if (result4 !== null) { + var result5 = parse_key(); + if (result5 !== null) { + var result3 = [result4, result5]; + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + var result2 = result3 !== null + ? (function(n) {return n})(result3[1]) + : null; + while (result2 !== null) { + result1.push(result2); + var savedPos0 = pos; + if (input.substr(pos, 1) === "|") { + var result4 = "|"; + pos += 1; + } else { + var result4 = null; + if (reportMatchFailures) { + matchFailed("\"|\""); + } + } + if (result4 !== null) { + var result5 = parse_key(); + if (result5 !== null) { + var result3 = [result4, result5]; + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + var result2 = result3 !== null + ? (function(n) {return n})(result3[1]) + : null; + } + var result0 = result1 !== null + ? (function(f) { return ["filters"].concat(f) })(result1) + : null; + reportMatchFailures = savedReportMatchFailures; + if (reportMatchFailures && result0 === null) { + matchFailed("filters"); + } + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_special() { + var cacheKey = "special" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + var savedReportMatchFailures = reportMatchFailures; + reportMatchFailures = false; + var savedPos0 = pos; + var result2 = parse_ld(); + if (result2 !== null) { + if (input.substr(pos, 1) === "~") { + var result3 = "~"; + pos += 1; + } else { + var result3 = null; + if (reportMatchFailures) { + matchFailed("\"~\""); + } + } + if (result3 !== null) { + var result4 = parse_key(); + if (result4 !== null) { + var result5 = parse_rd(); + if (result5 !== null) { + var result1 = [result2, result3, result4, result5]; + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + var result0 = result1 !== null + ? (function(k) { return ["special", k] })(result1[2]) + : null; + reportMatchFailures = savedReportMatchFailures; + if (reportMatchFailures && result0 === null) { + matchFailed("special"); + } + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_identifier() { + var cacheKey = "identifier" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + var savedReportMatchFailures = reportMatchFailures; + reportMatchFailures = false; + var result4 = parse_path(); + var result3 = result4 !== null + ? (function(p) { return wrap(["path"].concat(p), cacheKey) })(result4) + : null; + if (result3 !== null) { + var result0 = result3; + } else { + var result2 = parse_key(); + var result1 = result2 !== null + ? (function(k) { return wrap(["key", k], cacheKey) })(result2) + : null; + if (result1 !== null) { + var result0 = result1; + } else { + var result0 = null;; + }; + } + reportMatchFailures = savedReportMatchFailures; + if (reportMatchFailures && result0 === null) { + matchFailed("identifier"); + } + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_path() { + var cacheKey = "path" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + var savedReportMatchFailures = reportMatchFailures; + reportMatchFailures = false; + var savedPos0 = pos; + var result11 = parse_key(); + var result5 = result11 !== null ? result11 : ''; + if (result5 !== null) { + var savedPos1 = pos; + if (input.substr(pos, 1) === ".") { + var result9 = "."; + pos += 1; + } else { + var result9 = null; + if (reportMatchFailures) { + matchFailed("\".\""); + } + } + if (result9 !== null) { + var result10 = parse_key(); + if (result10 !== null) { + var result8 = [result9, result10]; + } else { + var result8 = null; + pos = savedPos1; + } + } else { + var result8 = null; + pos = savedPos1; + } + var result7 = result8 !== null + ? (function(k) {return k})(result8[1]) + : null; + if (result7 !== null) { + var result6 = []; + while (result7 !== null) { + result6.push(result7); + var savedPos1 = pos; + if (input.substr(pos, 1) === ".") { + var result9 = "."; + pos += 1; + } else { + var result9 = null; + if (reportMatchFailures) { + matchFailed("\".\""); + } + } + if (result9 !== null) { + var result10 = parse_key(); + if (result10 !== null) { + var result8 = [result9, result10]; + } else { + var result8 = null; + pos = savedPos1; + } + } else { + var result8 = null; + pos = savedPos1; + } + var result7 = result8 !== null + ? (function(k) {return k})(result8[1]) + : null; + } + } else { + var result6 = null; + } + if (result6 !== null) { + var result4 = [result5, result6]; + } else { + var result4 = null; + pos = savedPos0; + } + } else { + var result4 = null; + pos = savedPos0; + } + var result3 = result4 !== null + ? (function(k, d) { + if (k) { d.unshift(k); return [false, d]; } + return [true, d]; + })(result4[0], result4[1]) + : null; + if (result3 !== null) { + var result0 = result3; + } else { + if (input.substr(pos, 1) === ".") { + var result2 = "."; + pos += 1; + } else { + var result2 = null; + if (reportMatchFailures) { + matchFailed("\".\""); + } + } + var result1 = result2 !== null + ? (function() { return [true, []] })() + : null; + if (result1 !== null) { + var result0 = result1; + } else { + var result0 = null;; + }; + } + reportMatchFailures = savedReportMatchFailures; + if (reportMatchFailures && result0 === null) { + matchFailed("path"); + } + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_key() { + var cacheKey = "key" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + var savedReportMatchFailures = reportMatchFailures; + reportMatchFailures = false; + var savedPos0 = pos; + if (input.substr(pos).match(/^[a-zA-Z_$]/) !== null) { + var result2 = input.charAt(pos); + pos++; + } else { + var result2 = null; + if (reportMatchFailures) { + matchFailed("[a-zA-Z_$]"); + } + } + if (result2 !== null) { + var result3 = []; + if (input.substr(pos).match(/^[0-9a-zA-Z_$]/) !== null) { + var result4 = input.charAt(pos); + pos++; + } else { + var result4 = null; + if (reportMatchFailures) { + matchFailed("[0-9a-zA-Z_$]"); + } + } + while (result4 !== null) { + result3.push(result4); + if (input.substr(pos).match(/^[0-9a-zA-Z_$]/) !== null) { + var result4 = input.charAt(pos); + pos++; + } else { + var result4 = null; + if (reportMatchFailures) { + matchFailed("[0-9a-zA-Z_$]"); + } + } + } + if (result3 !== null) { + var result1 = [result2, result3]; + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + var result0 = result1 !== null + ? (function(h, t) { return h + t.join('') })(result1[0], result1[1]) + : null; + reportMatchFailures = savedReportMatchFailures; + if (reportMatchFailures && result0 === null) { + matchFailed("key"); + } + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_inline() { + var cacheKey = "inline" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + var savedReportMatchFailures = reportMatchFailures; + reportMatchFailures = false; + var savedPos2 = pos; + if (input.substr(pos, 1) === "\"") { + var result14 = "\""; + pos += 1; + } else { + var result14 = null; + if (reportMatchFailures) { + matchFailed("\"\\\"\""); + } + } + if (result14 !== null) { + if (input.substr(pos, 1) === "\"") { + var result15 = "\""; + pos += 1; + } else { + var result15 = null; + if (reportMatchFailures) { + matchFailed("\"\\\"\""); + } + } + if (result15 !== null) { + var result13 = [result14, result15]; + } else { + var result13 = null; + pos = savedPos2; + } + } else { + var result13 = null; + pos = savedPos2; + } + var result12 = result13 !== null + ? (function() { return ["literal", ""] })() + : null; + if (result12 !== null) { + var result0 = result12; + } else { + var savedPos1 = pos; + if (input.substr(pos, 1) === "\"") { + var result9 = "\""; + pos += 1; + } else { + var result9 = null; + if (reportMatchFailures) { + matchFailed("\"\\\"\""); + } + } + if (result9 !== null) { + var result10 = parse_literal(); + if (result10 !== null) { + if (input.substr(pos, 1) === "\"") { + var result11 = "\""; + pos += 1; + } else { + var result11 = null; + if (reportMatchFailures) { + matchFailed("\"\\\"\""); + } + } + if (result11 !== null) { + var result8 = [result9, result10, result11]; + } else { + var result8 = null; + pos = savedPos1; + } + } else { + var result8 = null; + pos = savedPos1; + } + } else { + var result8 = null; + pos = savedPos1; + } + var result7 = result8 !== null + ? (function(l) { return ["literal", l] })(result8[1]) + : null; + if (result7 !== null) { + var result0 = result7; + } else { + var savedPos0 = pos; + if (input.substr(pos, 1) === "\"") { + var result3 = "\""; + pos += 1; + } else { + var result3 = null; + if (reportMatchFailures) { + matchFailed("\"\\\"\""); + } + } + if (result3 !== null) { + var result6 = parse_inline_part(); + if (result6 !== null) { + var result4 = []; + while (result6 !== null) { + result4.push(result6); + var result6 = parse_inline_part(); + } + } else { + var result4 = null; + } + if (result4 !== null) { + if (input.substr(pos, 1) === "\"") { + var result5 = "\""; + pos += 1; + } else { + var result5 = null; + if (reportMatchFailures) { + matchFailed("\"\\\"\""); + } + } + if (result5 !== null) { + var result2 = [result3, result4, result5]; + } else { + var result2 = null; + pos = savedPos0; + } + } else { + var result2 = null; + pos = savedPos0; + } + } else { + var result2 = null; + pos = savedPos0; + } + var result1 = result2 !== null + ? (function(p) { return ["body"].concat(p) })(result2[1]) + : null; + if (result1 !== null) { + var result0 = result1; + } else { + var result0 = null;; + }; + }; + } + reportMatchFailures = savedReportMatchFailures; + if (reportMatchFailures && result0 === null) { + matchFailed("inline"); + } + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_inline_part() { + var cacheKey = "inline_part" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + + var result4 = parse_special(); + if (result4 !== null) { + var result0 = result4; + } else { + var result3 = parse_reference(); + if (result3 !== null) { + var result0 = result3; + } else { + var result2 = parse_literal(); + var result1 = result2 !== null + ? (function(l) { return ["buffer", l] })(result2) + : null; + if (result1 !== null) { + var result0 = result1; + } else { + var result0 = null;; + }; + }; + } + + + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_buffer() { + var cacheKey = "buffer" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + var savedReportMatchFailures = reportMatchFailures; + reportMatchFailures = false; + var savedPos4 = pos; + var result14 = parse_eol(); + if (result14 !== null) { + var result15 = []; + var result16 = parse_ws(); + while (result16 !== null) { + result15.push(result16); + var result16 = parse_ws(); + } + if (result15 !== null) { + var result13 = [result14, result15]; + } else { + var result13 = null; + pos = savedPos4; + } + } else { + var result13 = null; + pos = savedPos4; + } + var result12 = result13 !== null + ? (function(e, w) { return ["format", e, w.join('')] })(result13[0], result13[1]) + : null; + if (result12 !== null) { + var result0 = result12; + } else { + var savedPos0 = pos; + var savedPos3 = pos; + var savedReportMatchFailuresVar2 = reportMatchFailures; + reportMatchFailures = false; + var result11 = parse_tag(); + reportMatchFailures = savedReportMatchFailuresVar2; + if (result11 === null) { + var result5 = ''; + } else { + var result5 = null; + pos = savedPos3; + } + if (result5 !== null) { + var savedPos2 = pos; + var savedReportMatchFailuresVar1 = reportMatchFailures; + reportMatchFailures = false; + var result10 = parse_eol(); + reportMatchFailures = savedReportMatchFailuresVar1; + if (result10 === null) { + var result6 = ''; + } else { + var result6 = null; + pos = savedPos2; + } + if (result6 !== null) { + var savedPos1 = pos; + var savedReportMatchFailuresVar0 = reportMatchFailures; + reportMatchFailures = false; + var result9 = parse_comment(); + reportMatchFailures = savedReportMatchFailuresVar0; + if (result9 === null) { + var result7 = ''; + } else { + var result7 = null; + pos = savedPos1; + } + if (result7 !== null) { + if (input.length > pos) { + var result8 = input.charAt(pos); + pos++; + } else { + var result8 = null; + if (reportMatchFailures) { + matchFailed('any character'); + } + } + if (result8 !== null) { + var result4 = [result5, result6, result7, result8]; + } else { + var result4 = null; + pos = savedPos0; + } + } else { + var result4 = null; + pos = savedPos0; + } + } else { + var result4 = null; + pos = savedPos0; + } + } else { + var result4 = null; + pos = savedPos0; + } + var result3 = result4 !== null + ? (function(c) {return c})(result4[3]) + : null; + if (result3 !== null) { + var result2 = []; + while (result3 !== null) { + result2.push(result3); + var savedPos0 = pos; + var savedPos3 = pos; + var savedReportMatchFailuresVar2 = reportMatchFailures; + reportMatchFailures = false; + var result11 = parse_tag(); + reportMatchFailures = savedReportMatchFailuresVar2; + if (result11 === null) { + var result5 = ''; + } else { + var result5 = null; + pos = savedPos3; + } + if (result5 !== null) { + var savedPos2 = pos; + var savedReportMatchFailuresVar1 = reportMatchFailures; + reportMatchFailures = false; + var result10 = parse_eol(); + reportMatchFailures = savedReportMatchFailuresVar1; + if (result10 === null) { + var result6 = ''; + } else { + var result6 = null; + pos = savedPos2; + } + if (result6 !== null) { + var savedPos1 = pos; + var savedReportMatchFailuresVar0 = reportMatchFailures; + reportMatchFailures = false; + var result9 = parse_comment(); + reportMatchFailures = savedReportMatchFailuresVar0; + if (result9 === null) { + var result7 = ''; + } else { + var result7 = null; + pos = savedPos1; + } + if (result7 !== null) { + if (input.length > pos) { + var result8 = input.charAt(pos); + pos++; + } else { + var result8 = null; + if (reportMatchFailures) { + matchFailed('any character'); + } + } + if (result8 !== null) { + var result4 = [result5, result6, result7, result8]; + } else { + var result4 = null; + pos = savedPos0; + } + } else { + var result4 = null; + pos = savedPos0; + } + } else { + var result4 = null; + pos = savedPos0; + } + } else { + var result4 = null; + pos = savedPos0; + } + var result3 = result4 !== null + ? (function(c) {return c})(result4[3]) + : null; + } + } else { + var result2 = null; + } + var result1 = result2 !== null + ? (function(b) { return ["buffer", b.join('')] })(result2) + : null; + if (result1 !== null) { + var result0 = result1; + } else { + var result0 = null;; + }; + } + reportMatchFailures = savedReportMatchFailures; + if (reportMatchFailures && result0 === null) { + matchFailed("buffer"); + } + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_literal() { + var cacheKey = "literal" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + var savedReportMatchFailures = reportMatchFailures; + reportMatchFailures = false; + var savedPos0 = pos; + var savedPos2 = pos; + var savedReportMatchFailuresVar1 = reportMatchFailures; + reportMatchFailures = false; + var result10 = parse_tag(); + reportMatchFailures = savedReportMatchFailuresVar1; + if (result10 === null) { + var result4 = ''; + } else { + var result4 = null; + pos = savedPos2; + } + if (result4 !== null) { + var savedPos1 = pos; + var savedReportMatchFailuresVar0 = reportMatchFailures; + reportMatchFailures = false; + var result9 = parse_eol(); + reportMatchFailures = savedReportMatchFailuresVar0; + if (result9 === null) { + var result5 = ''; + } else { + var result5 = null; + pos = savedPos1; + } + if (result5 !== null) { + var result8 = parse_esc(); + if (result8 !== null) { + var result6 = result8; + } else { + if (input.substr(pos).match(/^[^"]/) !== null) { + var result7 = input.charAt(pos); + pos++; + } else { + var result7 = null; + if (reportMatchFailures) { + matchFailed("[^\"]"); + } + } + if (result7 !== null) { + var result6 = result7; + } else { + var result6 = null;; + }; + } + if (result6 !== null) { + var result3 = [result4, result5, result6]; + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + var result2 = result3 !== null + ? (function(c) {return c})(result3[2]) + : null; + if (result2 !== null) { + var result1 = []; + while (result2 !== null) { + result1.push(result2); + var savedPos0 = pos; + var savedPos2 = pos; + var savedReportMatchFailuresVar1 = reportMatchFailures; + reportMatchFailures = false; + var result10 = parse_tag(); + reportMatchFailures = savedReportMatchFailuresVar1; + if (result10 === null) { + var result4 = ''; + } else { + var result4 = null; + pos = savedPos2; + } + if (result4 !== null) { + var savedPos1 = pos; + var savedReportMatchFailuresVar0 = reportMatchFailures; + reportMatchFailures = false; + var result9 = parse_eol(); + reportMatchFailures = savedReportMatchFailuresVar0; + if (result9 === null) { + var result5 = ''; + } else { + var result5 = null; + pos = savedPos1; + } + if (result5 !== null) { + var result8 = parse_esc(); + if (result8 !== null) { + var result6 = result8; + } else { + if (input.substr(pos).match(/^[^"]/) !== null) { + var result7 = input.charAt(pos); + pos++; + } else { + var result7 = null; + if (reportMatchFailures) { + matchFailed("[^\"]"); + } + } + if (result7 !== null) { + var result6 = result7; + } else { + var result6 = null;; + }; + } + if (result6 !== null) { + var result3 = [result4, result5, result6]; + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + } else { + var result3 = null; + pos = savedPos0; + } + var result2 = result3 !== null + ? (function(c) {return c})(result3[2]) + : null; + } + } else { + var result1 = null; + } + var result0 = result1 !== null + ? (function(b) { return b.join('') })(result1) + : null; + reportMatchFailures = savedReportMatchFailures; + if (reportMatchFailures && result0 === null) { + matchFailed("literal"); + } + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_esc() { + var cacheKey = "esc" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + + if (input.substr(pos, 2) === "\\\"") { + var result1 = "\\\""; + pos += 2; + } else { + var result1 = null; + if (reportMatchFailures) { + matchFailed("\"\\\\\\\"\""); + } + } + var result0 = result1 !== null + ? (function() { return '"' })() + : null; + + + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_comment() { + var cacheKey = "comment" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + var savedReportMatchFailures = reportMatchFailures; + reportMatchFailures = false; + var savedPos0 = pos; + if (input.substr(pos, 2) === "{!") { + var result2 = "{!"; + pos += 2; + } else { + var result2 = null; + if (reportMatchFailures) { + matchFailed("\"{!\""); + } + } + if (result2 !== null) { + var result3 = []; + var savedPos1 = pos; + var savedPos2 = pos; + var savedReportMatchFailuresVar0 = reportMatchFailures; + reportMatchFailures = false; + if (input.substr(pos, 2) === "!}") { + var result9 = "!}"; + pos += 2; + } else { + var result9 = null; + if (reportMatchFailures) { + matchFailed("\"!}\""); + } + } + reportMatchFailures = savedReportMatchFailuresVar0; + if (result9 === null) { + var result7 = ''; + } else { + var result7 = null; + pos = savedPos2; + } + if (result7 !== null) { + if (input.length > pos) { + var result8 = input.charAt(pos); + pos++; + } else { + var result8 = null; + if (reportMatchFailures) { + matchFailed('any character'); + } + } + if (result8 !== null) { + var result6 = [result7, result8]; + } else { + var result6 = null; + pos = savedPos1; + } + } else { + var result6 = null; + pos = savedPos1; + } + var result5 = result6 !== null + ? (function(c) {return c})(result6[1]) + : null; + while (result5 !== null) { + result3.push(result5); + var savedPos1 = pos; + var savedPos2 = pos; + var savedReportMatchFailuresVar0 = reportMatchFailures; + reportMatchFailures = false; + if (input.substr(pos, 2) === "!}") { + var result9 = "!}"; + pos += 2; + } else { + var result9 = null; + if (reportMatchFailures) { + matchFailed("\"!}\""); + } + } + reportMatchFailures = savedReportMatchFailuresVar0; + if (result9 === null) { + var result7 = ''; + } else { + var result7 = null; + pos = savedPos2; + } + if (result7 !== null) { + if (input.length > pos) { + var result8 = input.charAt(pos); + pos++; + } else { + var result8 = null; + if (reportMatchFailures) { + matchFailed('any character'); + } + } + if (result8 !== null) { + var result6 = [result7, result8]; + } else { + var result6 = null; + pos = savedPos1; + } + } else { + var result6 = null; + pos = savedPos1; + } + var result5 = result6 !== null + ? (function(c) {return c})(result6[1]) + : null; + } + if (result3 !== null) { + if (input.substr(pos, 2) === "!}") { + var result4 = "!}"; + pos += 2; + } else { + var result4 = null; + if (reportMatchFailures) { + matchFailed("\"!}\""); + } + } + if (result4 !== null) { + var result1 = [result2, result3, result4]; + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + } else { + var result1 = null; + pos = savedPos0; + } + var result0 = result1 !== null + ? (function(c) { return ["comment", c.join('')] })(result1[1]) + : null; + reportMatchFailures = savedReportMatchFailures; + if (reportMatchFailures && result0 === null) { + matchFailed("comment"); + } + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_tag() { + var cacheKey = "tag" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + + var savedPos0 = pos; + var result3 = parse_ld(); + if (result3 !== null) { + if (input.substr(pos).match(/^[#?^><+%:@\/~%]/) !== null) { + var result4 = input.charAt(pos); + pos++; + } else { + var result4 = null; + if (reportMatchFailures) { + matchFailed("[#?^><+%:@\\/~%]"); + } + } + if (result4 !== null) { + var savedPos1 = pos; + var savedPos3 = pos; + var savedReportMatchFailuresVar1 = reportMatchFailures; + reportMatchFailures = false; + var result12 = parse_rd(); + reportMatchFailures = savedReportMatchFailuresVar1; + if (result12 === null) { + var result8 = ''; + } else { + var result8 = null; + pos = savedPos3; + } + if (result8 !== null) { + var savedPos2 = pos; + var savedReportMatchFailuresVar0 = reportMatchFailures; + reportMatchFailures = false; + var result11 = parse_eol(); + reportMatchFailures = savedReportMatchFailuresVar0; + if (result11 === null) { + var result9 = ''; + } else { + var result9 = null; + pos = savedPos2; + } + if (result9 !== null) { + if (input.length > pos) { + var result10 = input.charAt(pos); + pos++; + } else { + var result10 = null; + if (reportMatchFailures) { + matchFailed('any character'); + } + } + if (result10 !== null) { + var result7 = [result8, result9, result10]; + } else { + var result7 = null; + pos = savedPos1; + } + } else { + var result7 = null; + pos = savedPos1; + } + } else { + var result7 = null; + pos = savedPos1; + } + if (result7 !== null) { + var result5 = []; + while (result7 !== null) { + result5.push(result7); + var savedPos1 = pos; + var savedPos3 = pos; + var savedReportMatchFailuresVar1 = reportMatchFailures; + reportMatchFailures = false; + var result12 = parse_rd(); + reportMatchFailures = savedReportMatchFailuresVar1; + if (result12 === null) { + var result8 = ''; + } else { + var result8 = null; + pos = savedPos3; + } + if (result8 !== null) { + var savedPos2 = pos; + var savedReportMatchFailuresVar0 = reportMatchFailures; + reportMatchFailures = false; + var result11 = parse_eol(); + reportMatchFailures = savedReportMatchFailuresVar0; + if (result11 === null) { + var result9 = ''; + } else { + var result9 = null; + pos = savedPos2; + } + if (result9 !== null) { + if (input.length > pos) { + var result10 = input.charAt(pos); + pos++; + } else { + var result10 = null; + if (reportMatchFailures) { + matchFailed('any character'); + } + } + if (result10 !== null) { + var result7 = [result8, result9, result10]; + } else { + var result7 = null; + pos = savedPos1; + } + } else { + var result7 = null; + pos = savedPos1; + } + } else { + var result7 = null; + pos = savedPos1; + } + } + } else { + var result5 = null; + } + if (result5 !== null) { + var result6 = parse_rd(); + if (result6 !== null) { + var result2 = [result3, result4, result5, result6]; + } else { + var result2 = null; + pos = savedPos0; + } + } else { + var result2 = null; + pos = savedPos0; + } + } else { + var result2 = null; + pos = savedPos0; + } + } else { + var result2 = null; + pos = savedPos0; + } + if (result2 !== null) { + var result0 = result2; + } else { + var result1 = parse_reference(); + if (result1 !== null) { + var result0 = result1; + } else { + var result0 = null;; + }; + } + + + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_ld() { + var cacheKey = "ld" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + + if (input.substr(pos, 1) === "{") { + var result0 = "{"; + pos += 1; + } else { + var result0 = null; + if (reportMatchFailures) { + matchFailed("\"{\""); + } + } + + + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_rd() { + var cacheKey = "rd" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + + if (input.substr(pos, 1) === "}") { + var result0 = "}"; + pos += 1; + } else { + var result0 = null; + if (reportMatchFailures) { + matchFailed("\"}\""); + } + } + + + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_eol() { + var cacheKey = "eol" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + + if (input.substr(pos, 1) === "\n") { + var result5 = "\n"; + pos += 1; + } else { + var result5 = null; + if (reportMatchFailures) { + matchFailed("\"\\n\""); + } + } + if (result5 !== null) { + var result0 = result5; + } else { + if (input.substr(pos, 2) === "\r\n") { + var result4 = "\r\n"; + pos += 2; + } else { + var result4 = null; + if (reportMatchFailures) { + matchFailed("\"\\r\\n\""); + } + } + if (result4 !== null) { + var result0 = result4; + } else { + if (input.substr(pos, 1) === "\r") { + var result3 = "\r"; + pos += 1; + } else { + var result3 = null; + if (reportMatchFailures) { + matchFailed("\"\\r\""); + } + } + if (result3 !== null) { + var result0 = result3; + } else { + if (input.substr(pos, 1) === "\u2028") { + var result2 = "\u2028"; + pos += 1; + } else { + var result2 = null; + if (reportMatchFailures) { + matchFailed("\"\\u2028\""); + } + } + if (result2 !== null) { + var result0 = result2; + } else { + if (input.substr(pos, 1) === "\u2029") { + var result1 = "\u2029"; + pos += 1; + } else { + var result1 = null; + if (reportMatchFailures) { + matchFailed("\"\\u2029\""); + } + } + if (result1 !== null) { + var result0 = result1; + } else { + var result0 = null;; + }; + }; + }; + }; + } + + + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function parse_ws() { + var cacheKey = "ws" + '@' + pos; + var cachedResult = cache[cacheKey]; + if (cachedResult) { + pos = cachedResult.nextPos; + return cachedResult.result; + } + + + if (input.substr(pos).match(/^[ \xA0\uFEFF]/) !== null) { + var result0 = input.charAt(pos); + pos++; + } else { + var result0 = null; + if (reportMatchFailures) { + matchFailed("[ \\xA0\\uFEFF]"); + } + } + + + + cache[cacheKey] = { + nextPos: pos, + result: result0 + }; + return result0; + } + + function buildErrorMessage() { + function buildExpected(failuresExpected) { + failuresExpected.sort(); + + var lastFailure = null; + var failuresExpectedUnique = []; + for (var i = 0; i < failuresExpected.length; i++) { + if (failuresExpected[i] !== lastFailure) { + failuresExpectedUnique.push(failuresExpected[i]); + lastFailure = failuresExpected[i]; + } + } + + switch (failuresExpectedUnique.length) { + case 0: + return 'end of input'; + case 1: + return failuresExpectedUnique[0]; + default: + return failuresExpectedUnique.slice(0, failuresExpectedUnique.length - 1).join(', ') + + ' or ' + + failuresExpectedUnique[failuresExpectedUnique.length - 1]; + } + } + + var expected = buildExpected(rightmostMatchFailuresExpected); + var actualPos = Math.max(pos, rightmostMatchFailuresPos); + var actual = actualPos < input.length + ? quote(input.charAt(actualPos)) + : 'end of input'; + + return 'Expected ' + expected + ' but ' + actual + ' found.'; + } + + function computeErrorPosition() { + /* + * The first idea was to use |String.split| to break the input up to the + * error position along newlines and derive the line and column from + * there. However IE's |split| implementation is so broken that it was + * enough to prevent it. + */ + + var line = 1; + var column = 1; + var seenCR = false; + + for (var i = 0; i < rightmostMatchFailuresPos; i++) { + var ch = input.charAt(i); + if (ch === '\n') { + if (!seenCR) { line++; } + column = 1; + seenCR = false; + } else if (ch === '\r' | ch === '\u2028' || ch === '\u2029') { + line++; + column = 1; + seenCR = true; + } else { + column++; + seenCR = false; + } + } + + return { line: line, column: column }; + } + + + + function wrap(node, ck) { + + node['text'] = input.substring(ck.split('@')[1], pos); + + return node; + + } + + + + var result = parse_body(); + + /* + * The parser is now in one of the following three states: + * + * 1. The parser successfully parsed the whole input. + * + * - |result !== null| + * - |pos === input.length| + * - |rightmostMatchFailuresExpected| may or may not contain something + * + * 2. The parser successfully parsed only a part of the input. + * + * - |result !== null| + * - |pos < input.length| + * - |rightmostMatchFailuresExpected| may or may not contain something + * + * 3. The parser did not successfully parse any part of the input. + * + * - |result === null| + * - |pos === 0| + * - |rightmostMatchFailuresExpected| contains at least one failure + * + * All code following this comment (including called functions) must + * handle these states. + */ + if (result === null || pos !== input.length) { + var errorPosition = computeErrorPosition(); + throw new SyntaxError( + buildErrorMessage(), + errorPosition.line, + errorPosition.column + ); + } + + return result; + }, + + /* Returns the parser source code. */ + toSource: function() { return this._source; } + }; + + /* Thrown when a parser encounters a syntax error. */ + + result.SyntaxError = function(message, line, column) { + this.name = 'SyntaxError'; + this.message = message; + this.line = line; + this.column = column; + }; + + result.SyntaxError.prototype = Error.prototype; + + return result; +})(); + +dust.parse = parser.parse; + +})(typeof exports !== 'undefined' ? exports : window.dust); \ No newline at end of file diff --git a/node_modules/dust/lib/server.js b/node_modules/dust/lib/server.js new file mode 100644 index 0000000..122bba2 --- /dev/null +++ b/node_modules/dust/lib/server.js @@ -0,0 +1,20 @@ +var path = require('path'), + parser = require('./parser'), + compiler = require('./compiler'), + Script = process.binding('evals').Script; + +require.paths.unshift(path.join(__dirname, '..')); + +module.exports = function(dust) { + compiler.parse = parser.parse; + dust.compile = compiler.compile; + + dust.loadSource = function(source, path) { + return Script.runInNewContext(source, {dust: dust}, path); + }; + + dust.nextTick = process.nextTick; + + // expose optimizers in commonjs env too + dust.optimizers = compiler.optimizers; +} diff --git a/node_modules/dust/nbproject/private/config.properties b/node_modules/dust/nbproject/private/config.properties new file mode 100644 index 0000000..e69de29 diff --git a/node_modules/dust/nbproject/private/private.properties b/node_modules/dust/nbproject/private/private.properties new file mode 100644 index 0000000..34b8c3d --- /dev/null +++ b/node_modules/dust/nbproject/private/private.properties @@ -0,0 +1 @@ +platform.active=Ruby diff --git a/node_modules/dust/nbproject/private/private.xml b/node_modules/dust/nbproject/private/private.xml new file mode 100644 index 0000000..c1f155a --- /dev/null +++ b/node_modules/dust/nbproject/private/private.xml @@ -0,0 +1,4 @@ + + + + diff --git a/node_modules/dust/nbproject/private/rake-d.txt b/node_modules/dust/nbproject/private/rake-d.txt new file mode 100644 index 0000000..57417cb --- /dev/null +++ b/node_modules/dust/nbproject/private/rake-d.txt @@ -0,0 +1,19 @@ +clean=Remove any temporary products. +clobber=Remove any generated file. +clobber_package=Remove package products +clobber_rdoc=Remove rdoc products +doc= +doc/rdoc= +doc/rdoc/index.html= +gem=Build the gem file dust-0.0.1.gem +package=Build all the packages +pkg= +pkg/dust-0.0.1= +pkg/dust-0.0.1.gem= +pkg/dust-0.0.1.tgz= +pkg/dust-0.0.1.zip= +rdoc=Build the rdoc HTML Files +repackage=Force a rebuild of the package files +rerdoc=Force a rebuild of the RDOC files +spec=Run specs +test=Run tests diff --git a/node_modules/dust/nbproject/project.properties b/node_modules/dust/nbproject/project.properties new file mode 100644 index 0000000..09c4186 --- /dev/null +++ b/node_modules/dust/nbproject/project.properties @@ -0,0 +1,6 @@ +javac.classpath= +main.file= +platform.active=Ruby +source.encoding=UTF-8 +src.lib.dir=lib +src.src.dir=src diff --git a/node_modules/dust/nbproject/project.xml b/node_modules/dust/nbproject/project.xml new file mode 100644 index 0000000..02c683b --- /dev/null +++ b/node_modules/dust/nbproject/project.xml @@ -0,0 +1,14 @@ + + + org.netbeans.modules.ruby.rubyproject + + + dust + + + + + + + + diff --git a/node_modules/dust/package.json b/node_modules/dust/package.json new file mode 100644 index 0000000..896ef26 --- /dev/null +++ b/node_modules/dust/package.json @@ -0,0 +1,45 @@ +{ + "name": "dust", + "version": "0.3.0", + "description": "Asynchronous templates for the browser and node.js", + "author": { + "name": "Aleksander Williams" + }, + "contributors": [], + "url": "http://akdubya.github.com/dustjs/", + "keywords": [ + "templates", + "views" + ], + "main": "./lib/dust", + "scripts": { + "test": "make test" + }, + "_id": "dust@0.3.0", + "engines": { + "node": "*" + }, + "_engineSupported": true, + "_npmVersion": "0.2.14", + "_nodeVersion": "v0.3.2-pre", + "directories": { + "lib": "./lib" + }, + "modules": { + "compiler.js": "lib/compiler.js", + "dust.js": "lib/dust.js", + "parser.js": "lib/parser.js", + "server.js": "lib/server.js" + }, + "files": [ + "" + ], + "_defaultsLoaded": true, + "dist": { + "shasum": "86b65a9a9769a50de9f2c7ad998503019a1564a5", + "tarball": "http://registry.npmjs.org/dust/-/dust-0.3.0.tgz" + }, + "_shasum": "86b65a9a9769a50de9f2c7ad998503019a1564a5", + "_from": "dust@0.3.0", + "_resolved": "https://registry.npmjs.org/dust/-/dust-0.3.0.tgz" +} diff --git a/node_modules/dust/src/build.js b/node_modules/dust/src/build.js new file mode 100644 index 0000000..1ff1b7e --- /dev/null +++ b/node_modules/dust/src/build.js @@ -0,0 +1,12 @@ +var peg = require('peg'), + fs = require('fs'), + path = require('path'), + root = path.join(path.dirname(__filename), ".."); + +var parser = peg.buildParser(fs.readFileSync(path.join(root, 'src', 'dust.pegjs'), 'utf8')); + +fs.writeFileSync(path.join(root, 'lib', 'parser.js'), "(function(dust){\n\nvar parser = " + + parser.toSource().replace('this.SyntaxError', 'SyntaxError') + ";\n\n" + + "dust.parse = parser.parse;\n\n" + + "})(typeof exports !== 'undefined' ? exports : window.dust);" +); \ No newline at end of file diff --git a/node_modules/dust/src/dust.pegjs b/node_modules/dust/src/dust.pegjs new file mode 100644 index 0000000..6334b62 --- /dev/null +++ b/node_modules/dust/src/dust.pegjs @@ -0,0 +1,118 @@ +{ + function wrap(node, ck) { + node['text'] = input.substring(ck.split('@')[1], pos); + return node; + } +} + +start + = body + +body + = p:part* { return ["body"].concat(p) } + +part + = comment / section / partial / special / reference / buffer + +section "section" + = t:sec_tag_start rd b:body e:bodies n:end_tag + &{return result8[1].text === result12.text} + { e.push(["param", ["literal", "block"], b]); t.push(e); return t } + / t:sec_tag_start "/" rd + { t.push(["bodies"]); return t } + +sec_tag_start + = ld t:[#?^<+@%] n:identifier c:context p:params + { return [t, n, c, p] } + +end_tag "end tag" + = ld "/" n:identifier rd + { return n } + +context + = n:(":" n:identifier {return n})? + { return n ? ["context", n] : ["context"] } + +params "params" + = p:(ws k:key "=" v:(identifier / inline) {return ["param", ["literal", k], v]})* + { return ["params"].concat(p) } + +bodies "bodies" + = p:(ld ":" k:key rd v:body {return ["param", ["literal", k], v]})* + { return ["bodies"].concat(p) } + +reference "reference" + = ld n:identifier f:filters rd + { return ["reference", n, f] } + +partial "partial" + = ld ">" n:(k:key {return ["literal", k]} / inline) c:context "/" rd + { return ["partial", n, c] } + +filters "filters" + = f:("|" n:key {return n})* + { return ["filters"].concat(f) } + +special "special" + = ld "~" k:key rd + { return ["special", k] } + +identifier "identifier" + = p:path { return wrap(["path"].concat(p), cacheKey) } + / k:key { return wrap(["key", k], cacheKey) } + +path "path" + = k:key? d:("." k:key {return k})+ { + if (k) { d.unshift(k); return [false, d]; } + return [true, d]; + } + / "." { return [true, []] } + +key "key" + = h:[a-zA-Z_$] t:[0-9a-zA-Z_$]* + { return h + t.join('') } + +inline "inline" + = '"' '"' { return ["literal", ""] } + / '"' l:literal '"' { return ["literal", l] } + / '"' p:inline_part+ '"' { return ["body"].concat(p) } + +inline_part + = special / reference / l:literal { return ["buffer", l] } + +buffer "buffer" + = e:eol w:ws* + { return ["format", e, w.join('')] } + / b:(!tag !eol !comment c:. {return c})+ + { return ["buffer", b.join('')] } + +literal "literal" + = b:(!tag !eol c:(esc / [^"]) {return c})+ + { return b.join('') } + +esc + = '\\"' { return '"' } + +comment "comment" + = "{!" c:(!"!}" c:. {return c})* "!}" + { return ["comment", c.join('')] } + +tag + = ld [#?^><+%:@/~%] (!rd !eol .)+ rd + / reference + +ld + = "{" + +rd + = "}" + +eol + = "\n" + / "\r\n" + / "\r" + / "\u2028" + / "\u2029" + +ws + = [\t\v\f \u00A0\uFEFF] \ No newline at end of file diff --git a/node_modules/dust/test/core.js b/node_modules/dust/test/core.js new file mode 100644 index 0000000..c5335d8 --- /dev/null +++ b/node_modules/dust/test/core.js @@ -0,0 +1,83 @@ +(function(exports){ + +exports.coreSetup = function(suite, auto) { + auto.forEach(function(test) { + suite.test(test.name, function(){ + testRender(this, test.source, test.context, test.expected); + }); + }); + + suite.test("base context", function() { + var base = dust.makeBase({ + sayHello: function() { return "Hello!" } + }); + testRender(this, "{sayHello} {foo}", base.push({foo: "bar"}), "Hello! bar"); + }); + + suite.test("valid keys", function() { + testRender(this, "{_foo}{$bar}{baz1}", {_foo: 1, $bar: 2, baz1: 3}, "123"); + }); + + suite.test("onLoad callback", function() { + var unit = this; + dust.onLoad = function(name, cb) { + cb(null, "Loaded: " + name); + }; + dust.render("onLoad", {}, function(err, out) { + try { + unit.ifError(err); + unit.equals(out, "Loaded: onLoad"); + } catch(err) { + unit.fail(err); + return; + } + unit.pass(); + }); + }); + + suite.test("renderSource (callback)", function() { + var unit = this; + dust.renderSource('Hello World', {}, function(err, out) { + try { + unit.ifError(err); + unit.equals(out, "Hello World"); + } catch(err) { + unit.fail(err); + return; + } + unit.pass(); + }); + }); + + suite.test("renderSource (stream)", function() { + var unit = this; + dust.renderSource('Hello World', {}).on('data', function(data) { + try { + unit.equals('Hello World', data); + } catch(err) { + unit.fail(err); + return; + } + unit.pass(); + }).on('error', function(err) { + unit.fail(err); + }); + }); +} + +function testRender(unit, source, context, expected) { + var name = unit.id; + dust.loadSource(dust.compile(source, name)); + dust.render(name, context, function(err, output) { + try { + unit.ifError(err); + unit.equals(output, expected); + } catch(err) { + unit.fail(err); + return; + } + unit.pass(); + }); +} + +})(typeof exports !== "undefined" ? exports : window); \ No newline at end of file diff --git a/node_modules/dust/test/examples.js b/node_modules/dust/test/examples.js new file mode 100644 index 0000000..c3e76da --- /dev/null +++ b/node_modules/dust/test/examples.js @@ -0,0 +1,318 @@ +(function(exports){ + +exports.dustExamples = [ + { + name: "intro", + source: "{#stream}{#delay}{.}{/delay}{/stream}", + context: (function(){ + var d = 1; + return { + stream: function() { + return "asynchronous templates for the browser and node.js".split(''); + }, + delay: function(chunk, context, bodies) { + return chunk.map(function(chunk) { + setTimeout(function() { + chunk.render(bodies.block, context).end(); + }, d++ * 15); + }); + } + } + }) + }, + { + name: "plain", + source: "Hello World!", + context: {}, + expected: "Hello World!" + }, + { + name: "replace", + source: "Hello {name}! You have {count} new messages.", + context: { name: "Mick", count: 30 }, + expected: "Hello Mick! You have 30 new messages." + }, + { + name: "zero", + source: "{#zero}{.}{/zero}", + context: { zero: 0 }, + expected: "0" + }, + { + name: "array", + source: "{#names}{title} {name}{~n}{/names}", + context: { title: "Sir", names: [ { name: "Moe" }, { name: "Larry" }, { name: "Curly" } ] }, + expected: "Sir Moe\nSir Larry\nSir Curly\n" + }, + { + name: "empty_array", + source: "{#names}{title} {name}{~n}{/names}", + context: { title: "Sir", names: [] }, + expected: "" + }, + { + name: "implicit", + source: "{#names}{.}{~n}{/names}", + context: { names: ["Moe", "Larry", "Curly"] }, + expected: "Moe\nLarry\nCurly\n" + }, + { + name: "object", + source: "{#person}{root}: {name}, {age}{/person}", + context: { root: "Subject", person: { name: "Larry", age: 45 } }, + expected: "Subject: Larry, 45" + }, + { + name: "rename_key", + source: "{#person foo=root}{foo}: {name}, {age}{/person}", + context: { root: "Subject", person: { name: "Larry", age: 45 } }, + expected: "Subject: Larry, 45" + }, + { + name: "force_current", + source: "{#person}{.root}: {name}, {age}{/person}", + context: { root: "Subject", person: { name: "Larry", age: 45 } }, + expected: ": Larry, 45" + }, + { + name: "path", + source: "{foo.bar}", + context: { foo: {bar: "Hello!"} }, + expected: "Hello!" + }, + { + name: "escaped", + source: "{safe|s}{~n}{unsafe}", + context: { safe: "", unsafe: "" }, + expected: "\n<script>alert('Goodbye!')</script>" + }, + { + name: "escape_pragma", + source: "{%esc:s}\n {unsafe}{~n}\n {%esc:h}\n {unsafe}\n {/esc}\n{/esc}", + context: { unsafe: "" }, + expected: "\n<script>alert('Goodbye!')</script>" + }, + { + name: "else_block", + source: "{#foo}\n" + + " foo,{~s}\n" + + "{:else}\n" + + " not foo,{~s}\n" + + "{/foo}\n" + + "{#bar}\n" + + " bar!\n" + + "{:else}\n" + + " not bar!\n" + + "{/bar}", + context: { foo: true, bar: false }, + expected: "foo, not bar!" + }, + { + name: "conditional", + source: "{?tags}\n" + + "
    {~n}\n" + + " {#tags}\n" + + " {~s}
  • {.}
  • {~n}\n" + + " {/tags}\n" + + "
\n" + + "{:else}\n" + + " No Tags!\n" + + "{/tags}\n" + + "{~n}\n" + + "{^likes}\n" + + " No Likes!\n" + + "{:else}\n" + + "
    {~n}\n" + + " {#likes}\n" + + " {~s}
  • {.}
  • {~n}\n" + + " {/likes}\n" + + "
\n" + + "{/likes}", + context: { tags: [], likes: ["moe", "larry", "curly", "shemp"] }, + expected: "No Tags!\n" + + "
    \n" + + "
  • moe
  • \n" + + "
  • larry
  • \n" + + "
  • curly
  • \n" + + "
  • shemp
  • \n" + + "
" + }, + { + name: "sync_key", + source: "Hello {type} World!", + context: { + type: function(chunk) { + return "Sync"; + } + }, + expected: "Hello Sync World!" + }, + { + name: "async_key", + source: "Hello {type} World!", + context: { + type: function(chunk) { + return chunk.map(function(chunk) { + dust.nextTick(function() { + chunk.end("Async"); + }); + }); + } + }, + expected: "Hello Async World!" + }, + { + name: "sync_chunk", + source: "Hello {type} World!", + context: { + type: function(chunk) { + return chunk.write("Chunky"); + } + }, + expected: "Hello Chunky World!" + }, + { + name: "async_iterator", + source: "{#numbers}{#delay}{.}{/delay}{@sep}, {/sep}{/numbers}", + context: { + numbers: [3, 2, 1], + delay: function(chunk, context, bodies) { + return chunk.map(function(chunk) { + setTimeout(function() { + chunk.render(bodies.block, context).end(); + }, Math.ceil(Math.random()*10)); + }); + } + }, + expected: "3, 2, 1" + }, + { + name: "filter", + source: "{#filter}foo {bar}{/filter}", + context: { + filter: function(chunk, context, bodies) { + return chunk.tap(function(data) { + return data.toUpperCase(); + }).render(bodies.block, context).untap(); + }, + + bar: "bar" + }, + expected: "FOO BAR" + }, + { + name: "context", + source: "{#list:projects}{name}{:else}No Projects!{/list}", + context: { + list: function(chunk, context, bodies) { + var items = context.current(), + len = items.length; + + if (len) { + chunk.write("
    \n"); + for (var i=0; i") + .render(bodies.block, context.push(items[i])) + .write("\n"); + } + return chunk.write("
"); + } else if (bodies['else']) { + return chunk.render(bodies['else'], context); + } + return chunk; + }, + + projects: [ + {name: "Mayhem"}, + {name: "Flash"}, + {name: "Thunder"} + ] + }, + expected: "
    \n" + + "
  • Mayhem
  • \n" + + "
  • Flash
  • \n" + + "
  • Thunder
  • \n" + + "
" + }, + { + name: "params", + source: "{#helper foo=\"bar\"/}", + context: { + helper: function(chunk, context, bodies, params) { + return chunk.write(params.foo); + } + }, + expected: "bar" + }, + { + name: "partials", + source: '{>replace/} {>"plain"/} {>"{ref}"/}', + context: { name: "Jim", count: 42, ref: "plain" }, + expected: "Hello Jim! You have 42 new messages. Hello World! Hello World!" + }, + { + name: "partial_context", + source: "{>replace:.profile/}", + context: { profile: { name: "Mick", count: 30 } }, + expected: "Hello Mick! You have 30 new messages." + }, + { + name: "base_template", + source: "Start{~n}\n" + + "{+title}\n" + + " Base Title\n" + + "{/title}\n" + + "{~n}\n" + + "{+main}\n" + + " Base Content\n" + + "{/main}\n" + + "{~n}\n" + + "End", + context: {}, + expected: "Start\nBase Title\nBase Content\nEnd" + }, + { + name: "child_template", + source: "{^xhr}\n" + + " {>base_template/}\n" + + "{:else}\n" + + " {+main/}\n" + + "{/xhr}\n" + + "{recursion:./}{/kids}", + context: { + name: '1', + kids: [ + { + name: '1.1', + kids: [ + {name: '1.1.1'} + ] + } + ] + }, + expected: "1\n1.1\n1.1.1\n" + }, + { + name: "comments", + source: "{!\n" + + " Multiline\n" + + " {#foo}{bar}{/foo}\n" + + "!}\n" + + "{!before!}Hello{!after!}", + context: {}, + expected: "Hello" + } +]; + +})(typeof exports !== "undefined" ? exports : window); \ No newline at end of file diff --git a/node_modules/dust/test/server.js b/node_modules/dust/test/server.js new file mode 100644 index 0000000..66b03ca --- /dev/null +++ b/node_modules/dust/test/server.js @@ -0,0 +1,35 @@ +var uutest = require('./uutest'), + dust = require('../lib/dust'), + tests = require('./examples').dustExamples, + coreSetup = require('./core').coreSetup; + +function dumpError(err) { + var out = err.testName + " -> "; + if (!err.message) { + err.message = JSON.stringify(err.expected) + + " " + err.operator + " " + JSON.stringify(err.actual); + } + return out + err.stack; +} + +var suite = new uutest.Suite({ + pass: function() { + process.stdout.write("."); + }, + fail: function(err) { + process.stdout.write("F"); + }, + done: function(passed, failed, elapsed) { + process.stdout.write("\n"); + console.log(passed + " passed " + failed + " failed " + "(" + elapsed + "ms)"); + this.errors.forEach(function(err) { + console.log(dumpError(err)); + }); + } +}); + +global.dust = dust; + +coreSetup(suite, tests.slice(1)); + +suite.run(); \ No newline at end of file diff --git a/node_modules/dust/test/uutest.js b/node_modules/dust/test/uutest.js new file mode 100644 index 0000000..79aa7a8 --- /dev/null +++ b/node_modules/dust/test/uutest.js @@ -0,0 +1,104 @@ +(function(uutest){ + +function Test(id, test, timeout, callback) { + this.id = id; + this.test = test; + this.callback = callback; + this.timeout = timeout; +} + +Test.prototype.run = function() { + var self = this; + self.timer = setTimeout(function() { + self.fail(new Error("TimeoutError")); + }, self.timeout); + try { + self.test.call(self); + } catch(err) { + self.fail(err); + } +} + +Test.prototype.equals = function(actual, expected, message) { + if (actual !== expected) { + var err = new Error(); + if (message) err.message = message; + throw wrapAssertionError(err, actual, expected, "==="); + } +} + +Test.prototype.ifError = function(err) { + if (err) throw err; +} + +Test.prototype.pass = function() { + clearTimeout(this.timer); + this.callback(); +} + +Test.prototype.fail = function(err) { + clearTimeout(this.timer); + this.callback(err); +} + +uutest.Test = Test; + +function Suite(options) { + this.options = options || {}; + this.timeout = options.timeout || 1000; + this.tests = []; +} + +Suite.prototype.test = function(name, fn) { + var self = this; + self.tests.push(new Test(name, fn, self.timeout, function(err) { + if (err) { + err.testName = name; + self.errors.push(err); + self.emit("fail", err); + } else { + self.emit("pass", name); + } + self.pending--; + self.check(); + })); +} + +Suite.prototype.run = function() { + if (this.pending) return; + var self = this, len = self.tests.length; + self.errors = []; + self.emit("start", self.tests); + self.start = new Date().getTime(); + self.pending = len; + for (var i=0; i + http://jsbeautifier.org/ + + Originally converted to javascript by Vital, + + You are free to use this in any way you want, in case you find this useful or working for you. + + Usage: + js_beautify(js_source_text); + js_beautify(js_source_text, options); + + The options are: + indent_size (default 4) — indentation size, + indent_char (default space) — character to indent with, + preserve_newlines (default true) — whether existing line breaks should be preserved, + indent_level (default 0) — initial indentation level, you probably won't need this ever, + + space_after_anon_function (default false) — if true, then space is added between "function ()" + (jslint is happy about this); if false, then the common "function()" output is used. + braces_on_own_line (default false) - ANSI / Allman brace style, each opening/closing brace gets its own line. + + e.g + + js_beautify(js_source_text, {indent_size: 1, indent_char: '\t'}); + + +*/ + + + +function js_beautify(js_source_text, options) { + + var input, output, token_text, last_type, last_text, last_last_text, last_word, flags, flag_store, indent_string; + var whitespace, wordchar, punct, parser_pos, line_starters, digits; + var prefix, token_type, do_block_just_closed; + var wanted_newline, just_added_newline, n_newlines; + + + // Some interpreters have unexpected results with foo = baz || bar; + options = options ? options : {}; + var opt_braces_on_own_line = options.braces_on_own_line ? options.braces_on_own_line : false; + var opt_indent_size = options.indent_size ? options.indent_size : 4; + var opt_indent_char = options.indent_char ? options.indent_char : ' '; + var opt_preserve_newlines = typeof options.preserve_newlines === 'undefined' ? true : options.preserve_newlines; + var opt_indent_level = options.indent_level ? options.indent_level : 0; // starting indentation + var opt_space_after_anon_function = options.space_after_anon_function === 'undefined' ? false : options.space_after_anon_function; + var opt_keep_array_indentation = typeof options.keep_array_indentation === 'undefined' ? false : options.keep_array_indentation; + + just_added_newline = false; + + // cache the source's length. + var input_length = js_source_text.length; + + function trim_output() { + while (output.length && (output[output.length - 1] === ' ' || output[output.length - 1] === indent_string)) { + output.pop(); + } + } + + function is_array(mode) { + return mode === '[EXPRESSION]' || mode === '[INDENTED-EXPRESSION]'; + } + + + function print_newline(ignore_repeated) { + + flags.eat_next_space = false; + if (opt_keep_array_indentation && is_array(flags.mode)) { + return; + } + + ignore_repeated = typeof ignore_repeated === 'undefined' ? true : ignore_repeated; + + flags.if_line = false; + trim_output(); + + if (!output.length) { + return; // no newline on start of file + } + + if (output[output.length - 1] !== "\n" || !ignore_repeated) { + just_added_newline = true; + output.push("\n"); + } + for (var i = 0; i < flags.indentation_level; i += 1) { + output.push(indent_string); + } + if (flags.var_line && flags.var_line_reindented) { + if (opt_indent_char === ' ') { + output.push(' '); // var_line always pushes 4 spaces, so that the variables would be one under another + } else { + output.push(indent_string); // skip space-stuffing, if indenting with a tab + } + } + } + + + + function print_single_space() { + if (flags.eat_next_space) { + flags.eat_next_space = false; + return; + } + var last_output = ' '; + if (output.length) { + last_output = output[output.length - 1]; + } + if (last_output !== ' ' && last_output !== '\n' && last_output !== indent_string) { // prevent occassional duplicate space + output.push(' '); + } + } + + + function print_token() { + just_added_newline = false; + flags.eat_next_space = false; + output.push(token_text); + } + + function indent() { + flags.indentation_level += 1; + } + + + function remove_indent() { + if (output.length && output[output.length - 1] === indent_string) { + output.pop(); + } + } + + function set_mode(mode) { + if (flags) { + flag_store.push(flags); + } + flags = { + previous_mode: flags ? flags.mode : 'BLOCK', + mode: mode, + var_line: false, + var_line_tainted: false, + var_line_reindented: false, + in_html_comment: false, + if_line: false, + in_case: false, + eat_next_space: false, + indentation_baseline: -1, + indentation_level: (flags ? flags.indentation_level + ((flags.var_line && flags.var_line_reindented) ? 1 : 0) : opt_indent_level) + }; + } + + function is_array(mode) { + return mode === '[EXPRESSION]' || mode === '[INDENTED-EXPRESSION]'; + } + + function is_expression(mode) { + return mode === '[EXPRESSION]' || mode === '[INDENTED-EXPRESSION]' || mode === '(EXPRESSION)'; + } + + function restore_mode() { + do_block_just_closed = flags.mode === 'DO_BLOCK'; + if (flag_store.length > 0) { + flags = flag_store.pop(); + } + } + + + function in_array(what, arr) { + for (var i = 0; i < arr.length; i += 1) { + if (arr[i] === what) { + return true; + } + } + return false; + } + + // Walk backwards from the colon to find a '?' (colon is part of a ternary op) + // or a '{' (colon is part of a class literal). Along the way, keep track of + // the blocks and expressions we pass so we only trigger on those chars in our + // own level, and keep track of the colons so we only trigger on the matching '?'. + + + function is_ternary_op() { + var level = 0, + colon_count = 0; + for (var i = output.length - 1; i >= 0; i--) { + switch (output[i]) { + case ':': + if (level === 0) { + colon_count++; + } + break; + case '?': + if (level === 0) { + if (colon_count === 0) { + return true; + } else { + colon_count--; + } + } + break; + case '{': + if (level === 0) { + return false; + } + level--; + break; + case '(': + case '[': + level--; + break; + case ')': + case ']': + case '}': + level++; + break; + } + } + } + + function get_next_token() { + n_newlines = 0; + + if (parser_pos >= input_length) { + return ['', 'TK_EOF']; + } + + wanted_newline = false; + + var c = input.charAt(parser_pos); + parser_pos += 1; + + + var keep_whitespace = opt_keep_array_indentation && is_array(flags.mode); + + if (keep_whitespace) { + + // + // slight mess to allow nice preservation of array indentation and reindent that correctly + // first time when we get to the arrays: + // var a = [ + // ....'something' + // we make note of whitespace_count = 4 into flags.indentation_baseline + // so we know that 4 whitespaces in original source match indent_level of reindented source + // + // and afterwards, when we get to + // 'something, + // .......'something else' + // we know that this should be indented to indent_level + (7 - indentation_baseline) spaces + // + var whitespace_count = 0; + + while (in_array(c, whitespace)) { + + if (c === "\n") { + trim_output(); + output.push("\n"); + just_added_newline = true; + whitespace_count = 0; + } else { + if (c === '\t') { + whitespace_count += 4; + } else { + whitespace_count += 1; + } + } + + if (parser_pos >= input_length) { + return ['', 'TK_EOF']; + } + + c = input.charAt(parser_pos); + parser_pos += 1; + + } + if (flags.indentation_baseline === -1) { + flags.indentation_baseline = whitespace_count; + } + + if (just_added_newline) { + var i; + for (i = 0; i < flags.indentation_level + 1; i += 1) { + output.push(indent_string); + } + if (flags.indentation_baseline !== -1) { + for (i = 0; i < whitespace_count - flags.indentation_baseline; i++) { + output.push(' '); + } + } + } + + } else { + while (in_array(c, whitespace)) { + + if (c === "\n") { + n_newlines += 1; + } + + + if (parser_pos >= input_length) { + return ['', 'TK_EOF']; + } + + c = input.charAt(parser_pos); + parser_pos += 1; + + } + + if (opt_preserve_newlines) { + if (n_newlines > 1) { + for (i = 0; i < n_newlines; i += 1) { + print_newline(i === 0); + just_added_newline = true; + } + } + } + wanted_newline = n_newlines > 0; + } + + + if (in_array(c, wordchar)) { + if (parser_pos < input_length) { + while (in_array(input.charAt(parser_pos), wordchar)) { + c += input.charAt(parser_pos); + parser_pos += 1; + if (parser_pos === input_length) { + break; + } + } + } + + // small and surprisingly unugly hack for 1E-10 representation + if (parser_pos !== input_length && c.match(/^[0-9]+[Ee]$/) && (input.charAt(parser_pos) === '-' || input.charAt(parser_pos) === '+')) { + + var sign = input.charAt(parser_pos); + parser_pos += 1; + + var t = get_next_token(parser_pos); + c += sign + t[0]; + return [c, 'TK_WORD']; + } + + if (c === 'in') { // hack for 'in' operator + return [c, 'TK_OPERATOR']; + } + if (wanted_newline && last_type !== 'TK_OPERATOR' && !flags.if_line && (opt_preserve_newlines || last_text !== 'var')) { + print_newline(); + } + return [c, 'TK_WORD']; + } + + if (c === '(' || c === '[') { + return [c, 'TK_START_EXPR']; + } + + if (c === ')' || c === ']') { + return [c, 'TK_END_EXPR']; + } + + if (c === '{') { + return [c, 'TK_START_BLOCK']; + } + + if (c === '}') { + return [c, 'TK_END_BLOCK']; + } + + if (c === ';') { + return [c, 'TK_SEMICOLON']; + } + + if (c === '/') { + var comment = ''; + // peek for comment /* ... */ + var inline_comment = true; + if (input.charAt(parser_pos) === '*') { + parser_pos += 1; + if (parser_pos < input_length) { + while (! (input.charAt(parser_pos) === '*' && input.charAt(parser_pos + 1) && input.charAt(parser_pos + 1) === '/') && parser_pos < input_length) { + c = input.charAt(parser_pos); + comment += c; + if (c === '\x0d' || c === '\x0a') { + inline_comment = false; + } + parser_pos += 1; + if (parser_pos >= input_length) { + break; + } + } + } + parser_pos += 2; + if (inline_comment) { + return ['/*' + comment + '*/', 'TK_INLINE_COMMENT']; + } else { + return ['/*' + comment + '*/', 'TK_BLOCK_COMMENT']; + } + } + // peek for comment // ... + if (input.charAt(parser_pos) === '/') { + comment = c; + while (input.charAt(parser_pos) !== "\x0d" && input.charAt(parser_pos) !== "\x0a") { + comment += input.charAt(parser_pos); + parser_pos += 1; + if (parser_pos >= input_length) { + break; + } + } + parser_pos += 1; + if (wanted_newline) { + print_newline(); + } + return [comment, 'TK_COMMENT']; + } + + } + + if (c === "'" || // string + c === '"' || // string + (c === '/' && ((last_type === 'TK_WORD' && in_array(last_text, ['return', 'do'])) || (last_type === 'TK_START_EXPR' || last_type === 'TK_START_BLOCK' || last_type === 'TK_END_BLOCK' || last_type === 'TK_OPERATOR' || last_type === 'TK_EQUALS' || last_type === 'TK_EOF' || last_type === 'TK_SEMICOLON')))) { // regexp + var sep = c; + var esc = false; + var resulting_string = c; + + if (parser_pos < input_length) { + if (sep === '/') { + // + // handle regexp separately... + // + var in_char_class = false; + while (esc || in_char_class || input.charAt(parser_pos) !== sep) { + resulting_string += input.charAt(parser_pos); + if (!esc) { + esc = input.charAt(parser_pos) === '\\'; + if (input.charAt(parser_pos) === '[') { + in_char_class = true; + } else if (input.charAt(parser_pos) === ']') { + in_char_class = false; + } + } else { + esc = false; + } + parser_pos += 1; + if (parser_pos >= input_length) { + // incomplete string/rexp when end-of-file reached. + // bail out with what had been received so far. + return [resulting_string, 'TK_STRING']; + } + } + + } else { + // + // and handle string also separately + // + while (esc || input.charAt(parser_pos) !== sep) { + resulting_string += input.charAt(parser_pos); + if (!esc) { + esc = input.charAt(parser_pos) === '\\'; + } else { + esc = false; + } + parser_pos += 1; + if (parser_pos >= input_length) { + // incomplete string/rexp when end-of-file reached. + // bail out with what had been received so far. + return [resulting_string, 'TK_STRING']; + } + } + } + + + + } + + parser_pos += 1; + + resulting_string += sep; + + if (sep === '/') { + // regexps may have modifiers /regexp/MOD , so fetch those, too + while (parser_pos < input_length && in_array(input.charAt(parser_pos), wordchar)) { + resulting_string += input.charAt(parser_pos); + parser_pos += 1; + } + } + return [resulting_string, 'TK_STRING']; + } + + if (c === '#') { + // Spidermonkey-specific sharp variables for circular references + // https://developer.mozilla.org/En/Sharp_variables_in_JavaScript + // http://mxr.mozilla.org/mozilla-central/source/js/src/jsscan.cpp around line 1935 + var sharp = '#'; + if (parser_pos < input_length && in_array(input.charAt(parser_pos), digits)) { + do { + c = input.charAt(parser_pos); + sharp += c; + parser_pos += 1; + } while (parser_pos < input_length && c !== '#' && c !== '='); + if (c === '#') { + // + } else if (input.charAt(parser_pos) === '[' && input.charAt(parser_pos + 1) === ']') { + sharp += '[]'; + parser_pos += 2; + } else if (input.charAt(parser_pos) === '{' && input.charAt(parser_pos + 1) === '}') { + sharp += '{}'; + parser_pos += 2; + } + return [sharp, 'TK_WORD']; + } + } + + if (c === '<' && input.substring(parser_pos - 1, parser_pos + 3) === '') { + flags.in_html_comment = false; + parser_pos += 2; + if (wanted_newline) { + print_newline(); + } + return ['-->', 'TK_COMMENT']; + } + + if (in_array(c, punct)) { + while (parser_pos < input_length && in_array(c + input.charAt(parser_pos), punct)) { + c += input.charAt(parser_pos); + parser_pos += 1; + if (parser_pos >= input_length) { + break; + } + } + + if (c === '=') { + return [c, 'TK_EQUALS']; + } else { + return [c, 'TK_OPERATOR']; + } + } + + return [c, 'TK_UNKNOWN']; + } + + //---------------------------------- + indent_string = ''; + while (opt_indent_size > 0) { + indent_string += opt_indent_char; + opt_indent_size -= 1; + } + + input = js_source_text; + + last_word = ''; // last 'TK_WORD' passed + last_type = 'TK_START_EXPR'; // last token type + last_text = ''; // last token text + last_last_text = ''; // pre-last token text + output = []; + + do_block_just_closed = false; + + whitespace = "\n\r\t ".split(''); + wordchar = 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789_$'.split(''); + digits = '0123456789'.split(''); + + punct = '+ - * / % & ++ -- = += -= *= /= %= == === != !== > < >= <= >> << >>> >>>= >>= <<= && &= | || ! !! , : ? ^ ^= |= ::'.split(' '); + + // words which should always start on new line. + line_starters = 'continue,try,throw,return,var,if,switch,case,default,for,while,break,function'.split(','); + + // states showing if we are currently in expression (i.e. "if" case) - 'EXPRESSION', or in usual block (like, procedure), 'BLOCK'. + // some formatting depends on that. + flag_store = []; + set_mode('BLOCK'); + + parser_pos = 0; + while (true) { + var t = get_next_token(parser_pos); + token_text = t[0]; + token_type = t[1]; + if (token_type === 'TK_EOF') { + break; + } + + switch (token_type) { + + case 'TK_START_EXPR': + + if (token_text === '[') { + + if (last_type === 'TK_WORD' || last_text === ')') { + // this is array index specifier, break immediately + // a[x], fn()[x] + if (in_array(last_text, line_starters)) { + print_single_space(); + } + set_mode('(EXPRESSION)'); + print_token(); + break; + } + + if (flags.mode === '[EXPRESSION]' || flags.mode === '[INDENTED-EXPRESSION]') { + if (last_last_text === ']' && last_text === ',') { + // ], [ goes to new line + if (flags.mode === '[EXPRESSION]') { + flags.mode = '[INDENTED-EXPRESSION]'; + if (!opt_keep_array_indentation) { + indent(); + } + } + set_mode('[EXPRESSION]'); + if (!opt_keep_array_indentation) { + print_newline(); + } + } else if (last_text === '[') { + if (flags.mode === '[EXPRESSION]') { + flags.mode = '[INDENTED-EXPRESSION]'; + if (!opt_keep_array_indentation) { + indent(); + } + } + set_mode('[EXPRESSION]'); + + if (!opt_keep_array_indentation) { + print_newline(); + } + } else { + set_mode('[EXPRESSION]'); + } + } else { + set_mode('[EXPRESSION]'); + } + + + + } else { + set_mode('(EXPRESSION)'); + } + + if (last_text === ';' || last_type === 'TK_START_BLOCK') { + print_newline(); + } else if (last_type === 'TK_END_EXPR' || last_type === 'TK_START_EXPR' || last_type === 'TK_END_BLOCK' || last_text === '.') { + // do nothing on (( and )( and ][ and ]( and .( + } else if (last_type !== 'TK_WORD' && last_type !== 'TK_OPERATOR') { + print_single_space(); + } else if (last_word === 'function') { + // function() vs function () + if (opt_space_after_anon_function) { + print_single_space(); + } + } else if (in_array(last_text, line_starters) || last_text === 'catch') { + print_single_space(); + } + print_token(); + + break; + + case 'TK_END_EXPR': + if (token_text === ']') { + if (opt_keep_array_indentation) { + if (last_text === '}') { + // trim_output(); + // print_newline(true); + remove_indent(); + print_token(); + restore_mode(); + break; + } + } else { + if (flags.mode === '[INDENTED-EXPRESSION]') { + if (last_text === ']') { + restore_mode(); + print_newline(); + print_token(); + break; + } + } + } + } + restore_mode(); + print_token(); + break; + + case 'TK_START_BLOCK': + + if (last_word === 'do') { + set_mode('DO_BLOCK'); + } else { + set_mode('BLOCK'); + } + if (opt_braces_on_own_line) { + if (last_type !== 'TK_OPERATOR') { + if (last_text == 'return') { + print_single_space(); + } else { + print_newline(true); + } + } + print_token(); + indent(); + } else { + if (last_type !== 'TK_OPERATOR' && last_type !== 'TK_START_EXPR') { + if (last_type === 'TK_START_BLOCK') { + print_newline(); + } else { + print_single_space(); + } + } else { + // if TK_OPERATOR or TK_START_EXPR + if (is_array(flags.previous_mode) && last_text === ',') { + print_newline(); // [a, b, c, { + } + } + indent(); + print_token(); + } + + break; + + case 'TK_END_BLOCK': + restore_mode(); + if (opt_braces_on_own_line) { + print_newline(); + print_token(); + } else { + if (last_type === 'TK_START_BLOCK') { + // nothing + if (just_added_newline) { + remove_indent(); + } else { + // {} + trim_output(); + } + } else { + print_newline(); + } + print_token(); + } + break; + + case 'TK_WORD': + + // no, it's not you. even I have problems understanding how this works + // and what does what. + if (do_block_just_closed) { + // do {} ## while () + print_single_space(); + print_token(); + print_single_space(); + do_block_just_closed = false; + break; + } + + if (token_text === 'function') { + if ((just_added_newline || last_text === ';') && last_text !== '{') { + // make sure there is a nice clean space of at least one blank line + // before a new function definition + n_newlines = just_added_newline ? n_newlines : 0; + + for (var i = 0; i < 2 - n_newlines; i++) { + print_newline(false); + } + + } + } + + if (token_text === 'case' || token_text === 'default') { + if (last_text === ':') { + // switch cases following one another + remove_indent(); + } else { + // case statement starts in the same line where switch + flags.indentation_level--; + print_newline(); + flags.indentation_level++; + } + print_token(); + flags.in_case = true; + break; + } + + prefix = 'NONE'; + + if (last_type === 'TK_END_BLOCK') { + if (!in_array(token_text.toLowerCase(), ['else', 'catch', 'finally'])) { + prefix = 'NEWLINE'; + } else { + if (opt_braces_on_own_line) { + prefix = 'NEWLINE'; + } else { + prefix = 'SPACE'; + print_single_space(); + } + } + } else if (last_type === 'TK_SEMICOLON' && (flags.mode === 'BLOCK' || flags.mode === 'DO_BLOCK')) { + prefix = 'NEWLINE'; + } else if (last_type === 'TK_SEMICOLON' && is_expression(flags.mode)) { + prefix = 'SPACE'; + } else if (last_type === 'TK_STRING') { + prefix = 'NEWLINE'; + } else if (last_type === 'TK_WORD') { + prefix = 'SPACE'; + } else if (last_type === 'TK_START_BLOCK') { + prefix = 'NEWLINE'; + } else if (last_type === 'TK_END_EXPR') { + print_single_space(); + prefix = 'NEWLINE'; + } + + if (last_type !== 'TK_END_BLOCK' && in_array(token_text.toLowerCase(), ['else', 'catch', 'finally'])) { + print_newline(); + } else if (in_array(token_text, line_starters) || prefix === 'NEWLINE') { + if (last_text === 'else') { + // no need to force newline on else break + print_single_space(); + } else if ((last_type === 'TK_START_EXPR' || last_text === '=' || last_text === ',') && token_text === 'function') { + // no need to force newline on 'function': (function + // DONOTHING + } else if (last_text === 'return' || last_text === 'throw') { + // no newline between 'return nnn' + print_single_space(); + } else if (last_type !== 'TK_END_EXPR') { + if ((last_type !== 'TK_START_EXPR' || token_text !== 'var') && last_text !== ':') { + // no need to force newline on 'var': for (var x = 0...) + if (token_text === 'if' && last_word === 'else' && last_text !== '{') { + // no newline for } else if { + print_single_space(); + } else { + print_newline(); + } + } + } else { + if (in_array(token_text, line_starters) && last_text !== ')') { + print_newline(); + } + } + } else if (is_array(flags.mode) && last_text === ',' && last_last_text === '}') { + print_newline(); // }, in lists get a newline treatment + } else if (prefix === 'SPACE') { + print_single_space(); + } + print_token(); + last_word = token_text; + + if (token_text === 'var') { + flags.var_line = true; + flags.var_line_reindented = false; + flags.var_line_tainted = false; + } + + if (token_text === 'if' || token_text === 'else') { + flags.if_line = true; + } + + break; + + case 'TK_SEMICOLON': + + print_token(); + flags.var_line = false; + flags.var_line_reindented = false; + break; + + case 'TK_STRING': + + if (last_type === 'TK_START_BLOCK' || last_type === 'TK_END_BLOCK' || last_type === 'TK_SEMICOLON') { + print_newline(); + } else if (last_type === 'TK_WORD') { + print_single_space(); + } + print_token(); + break; + + case 'TK_EQUALS': + if (flags.var_line) { + // just got an '=' in a var-line, different formatting/line-breaking, etc will now be done + flags.var_line_tainted = true; + } + print_single_space(); + print_token(); + print_single_space(); + break; + + case 'TK_OPERATOR': + + var space_before = true; + var space_after = true; + + if (flags.var_line && token_text === ',' && (is_expression(flags.mode))) { + // do not break on comma, for(var a = 1, b = 2) + flags.var_line_tainted = false; + } + + if (flags.var_line) { + if (token_text === ',') { + if (flags.var_line_tainted) { + print_token(); + flags.var_line_reindented = true; + flags.var_line_tainted = false; + print_newline(); + break; + } else { + flags.var_line_tainted = false; + } + // } else if (token_text === ':') { + // hmm, when does this happen? tests don't catch this + // flags.var_line = false; + } + } + + if (last_text === 'return' || last_text === 'throw') { + // "return" had a special handling in TK_WORD. Now we need to return the favor + print_single_space(); + print_token(); + break; + } + + if (token_text === ':' && flags.in_case) { + print_token(); // colon really asks for separate treatment + print_newline(); + flags.in_case = false; + break; + } + + if (token_text === '::') { + // no spaces around exotic namespacing syntax operator + print_token(); + break; + } + + if (token_text === ',') { + if (flags.var_line) { + if (flags.var_line_tainted) { + print_token(); + print_newline(); + flags.var_line_tainted = false; + } else { + print_token(); + print_single_space(); + } + } else if (last_type === 'TK_END_BLOCK' && flags.mode !== "(EXPRESSION)") { + print_token(); + if (flags.mode === 'OBJECT' && last_text === '}') { + print_newline(); + } else { + print_single_space(); + } + } else { + if (flags.mode === 'OBJECT') { + print_token(); + print_newline(); + } else { + // EXPR or DO_BLOCK + print_token(); + print_single_space(); + } + } + break; + // } else if (in_array(token_text, ['--', '++', '!']) || (in_array(token_text, ['-', '+']) && (in_array(last_type, ['TK_START_BLOCK', 'TK_START_EXPR', 'TK_EQUALS']) || in_array(last_text, line_starters) || in_array(last_text, ['==', '!=', '+=', '-=', '*=', '/=', '+', '-'])))) { + } else if (in_array(token_text, ['--', '++', '!']) || (in_array(token_text, ['-', '+']) && (in_array(last_type, ['TK_START_BLOCK', 'TK_START_EXPR', 'TK_EQUALS', 'TK_OPERATOR']) || in_array(last_text, line_starters)))) { + // unary operators (and binary +/- pretending to be unary) special cases + + space_before = false; + space_after = false; + + if (last_text === ';' && is_expression(flags.mode)) { + // for (;; ++i) + // ^^^ + space_before = true; + } + if (last_type === 'TK_WORD' && in_array(last_text, line_starters)) { + space_before = true; + } + + if (flags.mode === 'BLOCK' && (last_text === '{' || last_text === ';')) { + // { foo; --i } + // foo(); --bar; + print_newline(); + } + } else if (token_text === '.') { + // decimal digits or object.property + space_before = false; + + } else if (token_text === ':') { + if (!is_ternary_op()) { + flags.mode = 'OBJECT'; + space_before = false; + } + } + if (space_before) { + print_single_space(); + } + + print_token(); + + if (space_after) { + print_single_space(); + } + + if (token_text === '!') { + // flags.eat_next_space = true; + } + + break; + + case 'TK_BLOCK_COMMENT': + + var lines = token_text.split(/\x0a|\x0d\x0a/); + + if (/^\/\*\*/.test(token_text)) { + // javadoc: reformat and reindent + print_newline(); + output.push(lines[0]); + for (i = 1; i < lines.length; i++) { + print_newline(); + output.push(' '); + output.push(lines[i].replace(/^\s\s*|\s\s*$/, '')); + } + + } else { + // simple block comment: leave intact + if (lines.length > 1) { + // multiline comment block starts with a new line + print_newline(); + trim_output(); + } else { + // single-line /* comment */ stays where it is + print_single_space(); + } + for (i = 0; i < lines.length; i++) { + output.push(lines[i]); + output.push('\n'); + } + + } + print_newline(); + break; + + case 'TK_INLINE_COMMENT': + + print_single_space(); + print_token(); + if (is_expression(flags.mode)) { + print_single_space(); + } else { + print_newline(); + } + break; + + case 'TK_COMMENT': + + // print_newline(); + if (wanted_newline) { + print_newline(); + } else { + print_single_space(); + } + print_token(); + print_newline(); + break; + + case 'TK_UNKNOWN': + print_token(); + break; + } + + last_last_text = last_text; + last_type = token_type; + last_text = token_text; + } + + return output.join('').replace(/[\n ]+$/, ''); + +} + +// Add support for CommonJS. Just put this file somewhere on your require.paths +// and you will be able to `var js_beautify = require("beautify").js_beautify`. +if (typeof exports !== "undefined") + exports.js_beautify = js_beautify; \ No newline at end of file diff --git a/node_modules/dust/vendor/ecma.js b/node_modules/dust/vendor/ecma.js new file mode 100644 index 0000000..2b25803 --- /dev/null +++ b/node_modules/dust/vendor/ecma.js @@ -0,0 +1,60 @@ +if (!Array.prototype.forEach) { + Array.prototype.forEach = function(fun /*, thisp */) { + "use strict"; + + if (this === void 0 || this === null) + throw new TypeError(); + + var t = Object(this); + var len = t.length >>> 0; + if (typeof fun !== "function") + throw new TypeError(); + + var thisp = arguments[1]; + for (var i = 0; i < len; i++) { + if (i in t) + fun.call(thisp, t[i], i, t); + } + }; +} + +if (!Array.prototype.map) { + Array.prototype.map = function(fun /*, thisp */) { + "use strict"; + + if (this === void 0 || this === null) + throw new TypeError(); + + var t = Object(this); + var len = t.length >>> 0; + if (typeof fun !== "function") + throw new TypeError(); + + var res = new Array(len); + var thisp = arguments[1]; + for (var i = 0; i < len; i++) { + if (i in t) + res[i] = fun.call(thisp, t[i], i, t); + } + + return res; + }; +} + +if (!String.prototype.trim) { + String.prototype.trim = function() { + return this.replace(/^\s+|\s+$/g,""); + } +} + +if (!String.prototype.trimLeft) { + String.prototype.trimLeft = function() { + return this.replace(/^\s+/,""); + } +} + +if (!String.prototype.trimRight) { + String.prototype.trimRight = function() { + return this.replace(/\s+$/,""); + } +} \ No newline at end of file diff --git a/node_modules/dust/vendor/hijs.js b/node_modules/dust/vendor/hijs.js new file mode 100644 index 0000000..300ad9b --- /dev/null +++ b/node_modules/dust/vendor/hijs.js @@ -0,0 +1,93 @@ +(function (hijs) { +// +// hijs - JavaScript Syntax Highlighter +// +// Copyright (c) 2010 Alexis Sellier +// + +// All elements which match this will be syntax highlighted. +var selector = hijs || 'code'; + +var keywords = ('var function if else for while break switch case do new null in with void ' + +'continue delete return this true false throw catch typeof with instanceof').split(' '), + special = ('eval window document undefined NaN Infinity parseInt parseFloat ' + +'encodeURI decodeURI encodeURIComponent decodeURIComponent').split(' '); + +// Syntax definition +// The key becomes the class name of the +// around the matched block of code. +var syntax = [ + ['comment', /(\/\*(?:[^*\n]|\*+[^\/*])*\*+\/)/g], + ['comment', /(\/\/[^\n]*)/g], + ['string' , /("(?:(?!")[^\\\n]|\\.)*"|'(?:(?!')[^\\\n]|\\.)*')/g], + ['regexp' , /(\/.+\/[mgi]*)(?!\s*\w)/g], + ['class' , /\b([A-Z][a-zA-Z]+)\b/g], + ['number' , /\b([0-9]+(?:\.[0-9]+)?)\b/g], + ['keyword', new(RegExp)('\\b(' + keywords.join('|') + ')\\b', 'g')], + ['special', new(RegExp)('\\b(' + special.join('|') + ')\\b', 'g')] +]; +var nodes, table = {}; + +if (/^[a-z]+$/.test(selector)) { + nodes = document.getElementsByTagName(selector); +} else if (/^\.[\w-]+$/.test(selector)) { + nodes = document.getElementsByClassName(selector.slice(1)); +} else if (document.querySelectorAll) { + nodes = document.querySelectorAll(selector); +} else { + nodes = []; +} + +for (var i = 0, children; i < nodes.length; i++) { + children = nodes[i].childNodes; + + for (var j = 0, str; j < children.length; j++) { + code = children[j]; + + if (code.length >= 0) { // It's a text node + // Don't highlight command-line snippets + if (! /^\$/.test(code.nodeValue.trim())) { + syntax.forEach(function (s) { + var k = s[0], v = s[1]; + code.nodeValue = code.nodeValue.replace(v, function (_, m) { + return '\u00ab' + encode(k) + '\u00b7' + + encode(m) + + '\u00b7' + encode(k) + '\u00bb'; + }); + }); + } + } + } +} +for (var i = 0; i < nodes.length; i++) { + nodes[i].innerHTML = + nodes[i].innerHTML.replace(/\u00ab(.+?)\u00b7(.+?)\u00b7\1\u00bb/g, function (_, name, value) { + value = value.replace(/\u00ab[^\u00b7]+\u00b7/g, '').replace(/\u00b7[^\u00bb]+\u00bb/g, ''); + return '' + escape(decode(value)) + ''; + }); +} + +function escape(str) { + return str.replace(//g, '>'); +} + +// Encode ASCII characters to, and from Braille +function encode (str, encoded) { + table[encoded = str.split('').map(function (s) { + if (s.charCodeAt(0) > 127) { return s } + return String.fromCharCode(s.charCodeAt(0) + 0x2800); + }).join('')] = str; + return encoded; +} +function decode (str) { + if (str in table) { + return table[str]; + } else { + return str.trim().split('').map(function (s) { + if (s.charCodeAt(0) - 0x2800 > 127) { return s } + return String.fromCharCode(s.charCodeAt(0) - 0x2800); + }).join(''); + } +} + +})(window.hijs); \ No newline at end of file diff --git a/node_modules/dust/vendor/jquery.min.js b/node_modules/dust/vendor/jquery.min.js new file mode 100644 index 0000000..7c24308 --- /dev/null +++ b/node_modules/dust/vendor/jquery.min.js @@ -0,0 +1,154 @@ +/*! + * jQuery JavaScript Library v1.4.2 + * http://jquery.com/ + * + * Copyright 2010, John Resig + * Dual licensed under the MIT or GPL Version 2 licenses. + * http://jquery.org/license + * + * Includes Sizzle.js + * http://sizzlejs.com/ + * Copyright 2010, The Dojo Foundation + * Released under the MIT, BSD, and GPL Licenses. + * + * Date: Sat Feb 13 22:33:48 2010 -0500 + */ +(function(A,w){function ma(){if(!c.isReady){try{s.documentElement.doScroll("left")}catch(a){setTimeout(ma,1);return}c.ready()}}function Qa(a,b){b.src?c.ajax({url:b.src,async:false,dataType:"script"}):c.globalEval(b.text||b.textContent||b.innerHTML||"");b.parentNode&&b.parentNode.removeChild(b)}function X(a,b,d,f,e,j){var i=a.length;if(typeof b==="object"){for(var o in b)X(a,o,b[o],f,e,d);return a}if(d!==w){f=!j&&f&&c.isFunction(d);for(o=0;o)[^>]*$|^#([\w-]+)$/,Ua=/^.[^:#\[\.,]*$/,Va=/\S/, +Wa=/^(\s|\u00A0)+|(\s|\u00A0)+$/g,Xa=/^<(\w+)\s*\/?>(?:<\/\1>)?$/,P=navigator.userAgent,xa=false,Q=[],L,$=Object.prototype.toString,aa=Object.prototype.hasOwnProperty,ba=Array.prototype.push,R=Array.prototype.slice,ya=Array.prototype.indexOf;c.fn=c.prototype={init:function(a,b){var d,f;if(!a)return this;if(a.nodeType){this.context=this[0]=a;this.length=1;return this}if(a==="body"&&!b){this.context=s;this[0]=s.body;this.selector="body";this.length=1;return this}if(typeof a==="string")if((d=Ta.exec(a))&& +(d[1]||!b))if(d[1]){f=b?b.ownerDocument||b:s;if(a=Xa.exec(a))if(c.isPlainObject(b)){a=[s.createElement(a[1])];c.fn.attr.call(a,b,true)}else a=[f.createElement(a[1])];else{a=sa([d[1]],[f]);a=(a.cacheable?a.fragment.cloneNode(true):a.fragment).childNodes}return c.merge(this,a)}else{if(b=s.getElementById(d[2])){if(b.id!==d[2])return T.find(a);this.length=1;this[0]=b}this.context=s;this.selector=a;return this}else if(!b&&/^\w+$/.test(a)){this.selector=a;this.context=s;a=s.getElementsByTagName(a);return c.merge(this, +a)}else return!b||b.jquery?(b||T).find(a):c(b).find(a);else if(c.isFunction(a))return T.ready(a);if(a.selector!==w){this.selector=a.selector;this.context=a.context}return c.makeArray(a,this)},selector:"",jquery:"1.4.2",length:0,size:function(){return this.length},toArray:function(){return R.call(this,0)},get:function(a){return a==null?this.toArray():a<0?this.slice(a)[0]:this[a]},pushStack:function(a,b,d){var f=c();c.isArray(a)?ba.apply(f,a):c.merge(f,a);f.prevObject=this;f.context=this.context;if(b=== +"find")f.selector=this.selector+(this.selector?" ":"")+d;else if(b)f.selector=this.selector+"."+b+"("+d+")";return f},each:function(a,b){return c.each(this,a,b)},ready:function(a){c.bindReady();if(c.isReady)a.call(s,c);else Q&&Q.push(a);return this},eq:function(a){return a===-1?this.slice(a):this.slice(a,+a+1)},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},slice:function(){return this.pushStack(R.apply(this,arguments),"slice",R.call(arguments).join(","))},map:function(a){return this.pushStack(c.map(this, +function(b,d){return a.call(b,d,b)}))},end:function(){return this.prevObject||c(null)},push:ba,sort:[].sort,splice:[].splice};c.fn.init.prototype=c.fn;c.extend=c.fn.extend=function(){var a=arguments[0]||{},b=1,d=arguments.length,f=false,e,j,i,o;if(typeof a==="boolean"){f=a;a=arguments[1]||{};b=2}if(typeof a!=="object"&&!c.isFunction(a))a={};if(d===b){a=this;--b}for(;b
a"; +var e=d.getElementsByTagName("*"),j=d.getElementsByTagName("a")[0];if(!(!e||!e.length||!j)){c.support={leadingWhitespace:d.firstChild.nodeType===3,tbody:!d.getElementsByTagName("tbody").length,htmlSerialize:!!d.getElementsByTagName("link").length,style:/red/.test(j.getAttribute("style")),hrefNormalized:j.getAttribute("href")==="/a",opacity:/^0.55$/.test(j.style.opacity),cssFloat:!!j.style.cssFloat,checkOn:d.getElementsByTagName("input")[0].value==="on",optSelected:s.createElement("select").appendChild(s.createElement("option")).selected, +parentNode:d.removeChild(d.appendChild(s.createElement("div"))).parentNode===null,deleteExpando:true,checkClone:false,scriptEval:false,noCloneEvent:true,boxModel:null};b.type="text/javascript";try{b.appendChild(s.createTextNode("window."+f+"=1;"))}catch(i){}a.insertBefore(b,a.firstChild);if(A[f]){c.support.scriptEval=true;delete A[f]}try{delete b.test}catch(o){c.support.deleteExpando=false}a.removeChild(b);if(d.attachEvent&&d.fireEvent){d.attachEvent("onclick",function k(){c.support.noCloneEvent= +false;d.detachEvent("onclick",k)});d.cloneNode(true).fireEvent("onclick")}d=s.createElement("div");d.innerHTML="";a=s.createDocumentFragment();a.appendChild(d.firstChild);c.support.checkClone=a.cloneNode(true).cloneNode(true).lastChild.checked;c(function(){var k=s.createElement("div");k.style.width=k.style.paddingLeft="1px";s.body.appendChild(k);c.boxModel=c.support.boxModel=k.offsetWidth===2;s.body.removeChild(k).style.display="none"});a=function(k){var n= +s.createElement("div");k="on"+k;var r=k in n;if(!r){n.setAttribute(k,"return;");r=typeof n[k]==="function"}return r};c.support.submitBubbles=a("submit");c.support.changeBubbles=a("change");a=b=d=e=j=null}})();c.props={"for":"htmlFor","class":"className",readonly:"readOnly",maxlength:"maxLength",cellspacing:"cellSpacing",rowspan:"rowSpan",colspan:"colSpan",tabindex:"tabIndex",usemap:"useMap",frameborder:"frameBorder"};var G="jQuery"+J(),Ya=0,za={};c.extend({cache:{},expando:G,noData:{embed:true,object:true, +applet:true},data:function(a,b,d){if(!(a.nodeName&&c.noData[a.nodeName.toLowerCase()])){a=a==A?za:a;var f=a[G],e=c.cache;if(!f&&typeof b==="string"&&d===w)return null;f||(f=++Ya);if(typeof b==="object"){a[G]=f;e[f]=c.extend(true,{},b)}else if(!e[f]){a[G]=f;e[f]={}}a=e[f];if(d!==w)a[b]=d;return typeof b==="string"?a[b]:a}},removeData:function(a,b){if(!(a.nodeName&&c.noData[a.nodeName.toLowerCase()])){a=a==A?za:a;var d=a[G],f=c.cache,e=f[d];if(b){if(e){delete e[b];c.isEmptyObject(e)&&c.removeData(a)}}else{if(c.support.deleteExpando)delete a[c.expando]; +else a.removeAttribute&&a.removeAttribute(c.expando);delete f[d]}}}});c.fn.extend({data:function(a,b){if(typeof a==="undefined"&&this.length)return c.data(this[0]);else if(typeof a==="object")return this.each(function(){c.data(this,a)});var d=a.split(".");d[1]=d[1]?"."+d[1]:"";if(b===w){var f=this.triggerHandler("getData"+d[1]+"!",[d[0]]);if(f===w&&this.length)f=c.data(this[0],a);return f===w&&d[1]?this.data(d[0]):f}else return this.trigger("setData"+d[1]+"!",[d[0],b]).each(function(){c.data(this, +a,b)})},removeData:function(a){return this.each(function(){c.removeData(this,a)})}});c.extend({queue:function(a,b,d){if(a){b=(b||"fx")+"queue";var f=c.data(a,b);if(!d)return f||[];if(!f||c.isArray(d))f=c.data(a,b,c.makeArray(d));else f.push(d);return f}},dequeue:function(a,b){b=b||"fx";var d=c.queue(a,b),f=d.shift();if(f==="inprogress")f=d.shift();if(f){b==="fx"&&d.unshift("inprogress");f.call(a,function(){c.dequeue(a,b)})}}});c.fn.extend({queue:function(a,b){if(typeof a!=="string"){b=a;a="fx"}if(b=== +w)return c.queue(this[0],a);return this.each(function(){var d=c.queue(this,a,b);a==="fx"&&d[0]!=="inprogress"&&c.dequeue(this,a)})},dequeue:function(a){return this.each(function(){c.dequeue(this,a)})},delay:function(a,b){a=c.fx?c.fx.speeds[a]||a:a;b=b||"fx";return this.queue(b,function(){var d=this;setTimeout(function(){c.dequeue(d,b)},a)})},clearQueue:function(a){return this.queue(a||"fx",[])}});var Aa=/[\n\t]/g,ca=/\s+/,Za=/\r/g,$a=/href|src|style/,ab=/(button|input)/i,bb=/(button|input|object|select|textarea)/i, +cb=/^(a|area)$/i,Ba=/radio|checkbox/;c.fn.extend({attr:function(a,b){return X(this,a,b,true,c.attr)},removeAttr:function(a){return this.each(function(){c.attr(this,a,"");this.nodeType===1&&this.removeAttribute(a)})},addClass:function(a){if(c.isFunction(a))return this.each(function(n){var r=c(this);r.addClass(a.call(this,n,r.attr("class")))});if(a&&typeof a==="string")for(var b=(a||"").split(ca),d=0,f=this.length;d-1)return true;return false},val:function(a){if(a===w){var b=this[0];if(b){if(c.nodeName(b,"option"))return(b.attributes.value||{}).specified?b.value:b.text;if(c.nodeName(b,"select")){var d=b.selectedIndex,f=[],e=b.options;b=b.type==="select-one";if(d<0)return null;var j=b?d:0;for(d=b?d+1:e.length;j=0;else if(c.nodeName(this,"select")){var u=c.makeArray(r);c("option",this).each(function(){this.selected= +c.inArray(c(this).val(),u)>=0});if(!u.length)this.selectedIndex=-1}else this.value=r}})}});c.extend({attrFn:{val:true,css:true,html:true,text:true,data:true,width:true,height:true,offset:true},attr:function(a,b,d,f){if(!a||a.nodeType===3||a.nodeType===8)return w;if(f&&b in c.attrFn)return c(a)[b](d);f=a.nodeType!==1||!c.isXMLDoc(a);var e=d!==w;b=f&&c.props[b]||b;if(a.nodeType===1){var j=$a.test(b);if(b in a&&f&&!j){if(e){b==="type"&&ab.test(a.nodeName)&&a.parentNode&&c.error("type property can't be changed"); +a[b]=d}if(c.nodeName(a,"form")&&a.getAttributeNode(b))return a.getAttributeNode(b).nodeValue;if(b==="tabIndex")return(b=a.getAttributeNode("tabIndex"))&&b.specified?b.value:bb.test(a.nodeName)||cb.test(a.nodeName)&&a.href?0:w;return a[b]}if(!c.support.style&&f&&b==="style"){if(e)a.style.cssText=""+d;return a.style.cssText}e&&a.setAttribute(b,""+d);a=!c.support.hrefNormalized&&f&&j?a.getAttribute(b,2):a.getAttribute(b);return a===null?w:a}return c.style(a,b,d)}});var O=/\.(.*)$/,db=function(a){return a.replace(/[^\w\s\.\|`]/g, +function(b){return"\\"+b})};c.event={add:function(a,b,d,f){if(!(a.nodeType===3||a.nodeType===8)){if(a.setInterval&&a!==A&&!a.frameElement)a=A;var e,j;if(d.handler){e=d;d=e.handler}if(!d.guid)d.guid=c.guid++;if(j=c.data(a)){var i=j.events=j.events||{},o=j.handle;if(!o)j.handle=o=function(){return typeof c!=="undefined"&&!c.event.triggered?c.event.handle.apply(o.elem,arguments):w};o.elem=a;b=b.split(" ");for(var k,n=0,r;k=b[n++];){j=e?c.extend({},e):{handler:d,data:f};if(k.indexOf(".")>-1){r=k.split("."); +k=r.shift();j.namespace=r.slice(0).sort().join(".")}else{r=[];j.namespace=""}j.type=k;j.guid=d.guid;var u=i[k],z=c.event.special[k]||{};if(!u){u=i[k]=[];if(!z.setup||z.setup.call(a,f,r,o)===false)if(a.addEventListener)a.addEventListener(k,o,false);else a.attachEvent&&a.attachEvent("on"+k,o)}if(z.add){z.add.call(a,j);if(!j.handler.guid)j.handler.guid=d.guid}u.push(j);c.event.global[k]=true}a=null}}},global:{},remove:function(a,b,d,f){if(!(a.nodeType===3||a.nodeType===8)){var e,j=0,i,o,k,n,r,u,z=c.data(a), +C=z&&z.events;if(z&&C){if(b&&b.type){d=b.handler;b=b.type}if(!b||typeof b==="string"&&b.charAt(0)==="."){b=b||"";for(e in C)c.event.remove(a,e+b)}else{for(b=b.split(" ");e=b[j++];){n=e;i=e.indexOf(".")<0;o=[];if(!i){o=e.split(".");e=o.shift();k=new RegExp("(^|\\.)"+c.map(o.slice(0).sort(),db).join("\\.(?:.*\\.)?")+"(\\.|$)")}if(r=C[e])if(d){n=c.event.special[e]||{};for(B=f||0;B=0){a.type= +e=e.slice(0,-1);a.exclusive=true}if(!d){a.stopPropagation();c.event.global[e]&&c.each(c.cache,function(){this.events&&this.events[e]&&c.event.trigger(a,b,this.handle.elem)})}if(!d||d.nodeType===3||d.nodeType===8)return w;a.result=w;a.target=d;b=c.makeArray(b);b.unshift(a)}a.currentTarget=d;(f=c.data(d,"handle"))&&f.apply(d,b);f=d.parentNode||d.ownerDocument;try{if(!(d&&d.nodeName&&c.noData[d.nodeName.toLowerCase()]))if(d["on"+e]&&d["on"+e].apply(d,b)===false)a.result=false}catch(j){}if(!a.isPropagationStopped()&& +f)c.event.trigger(a,b,f,true);else if(!a.isDefaultPrevented()){f=a.target;var i,o=c.nodeName(f,"a")&&e==="click",k=c.event.special[e]||{};if((!k._default||k._default.call(d,a)===false)&&!o&&!(f&&f.nodeName&&c.noData[f.nodeName.toLowerCase()])){try{if(f[e]){if(i=f["on"+e])f["on"+e]=null;c.event.triggered=true;f[e]()}}catch(n){}if(i)f["on"+e]=i;c.event.triggered=false}}},handle:function(a){var b,d,f,e;a=arguments[0]=c.event.fix(a||A.event);a.currentTarget=this;b=a.type.indexOf(".")<0&&!a.exclusive; +if(!b){d=a.type.split(".");a.type=d.shift();f=new RegExp("(^|\\.)"+d.slice(0).sort().join("\\.(?:.*\\.)?")+"(\\.|$)")}e=c.data(this,"events");d=e[a.type];if(e&&d){d=d.slice(0);e=0;for(var j=d.length;e-1?c.map(a.options,function(f){return f.selected}).join("-"):"";else if(a.nodeName.toLowerCase()==="select")d=a.selectedIndex;return d},fa=function(a,b){var d=a.target,f,e;if(!(!da.test(d.nodeName)||d.readOnly)){f=c.data(d,"_change_data");e=Fa(d);if(a.type!=="focusout"||d.type!=="radio")c.data(d,"_change_data", +e);if(!(f===w||e===f))if(f!=null||e){a.type="change";return c.event.trigger(a,b,d)}}};c.event.special.change={filters:{focusout:fa,click:function(a){var b=a.target,d=b.type;if(d==="radio"||d==="checkbox"||b.nodeName.toLowerCase()==="select")return fa.call(this,a)},keydown:function(a){var b=a.target,d=b.type;if(a.keyCode===13&&b.nodeName.toLowerCase()!=="textarea"||a.keyCode===32&&(d==="checkbox"||d==="radio")||d==="select-multiple")return fa.call(this,a)},beforeactivate:function(a){a=a.target;c.data(a, +"_change_data",Fa(a))}},setup:function(){if(this.type==="file")return false;for(var a in ea)c.event.add(this,a+".specialChange",ea[a]);return da.test(this.nodeName)},teardown:function(){c.event.remove(this,".specialChange");return da.test(this.nodeName)}};ea=c.event.special.change.filters}s.addEventListener&&c.each({focus:"focusin",blur:"focusout"},function(a,b){function d(f){f=c.event.fix(f);f.type=b;return c.event.handle.call(this,f)}c.event.special[b]={setup:function(){this.addEventListener(a, +d,true)},teardown:function(){this.removeEventListener(a,d,true)}}});c.each(["bind","one"],function(a,b){c.fn[b]=function(d,f,e){if(typeof d==="object"){for(var j in d)this[b](j,f,d[j],e);return this}if(c.isFunction(f)){e=f;f=w}var i=b==="one"?c.proxy(e,function(k){c(this).unbind(k,i);return e.apply(this,arguments)}):e;if(d==="unload"&&b!=="one")this.one(d,f,e);else{j=0;for(var o=this.length;j0){y=t;break}}t=t[g]}m[q]=y}}}var f=/((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^[\]]*\]|['"][^'"]*['"]|[^[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?((?:.|\r|\n)*)/g, +e=0,j=Object.prototype.toString,i=false,o=true;[0,0].sort(function(){o=false;return 0});var k=function(g,h,l,m){l=l||[];var q=h=h||s;if(h.nodeType!==1&&h.nodeType!==9)return[];if(!g||typeof g!=="string")return l;for(var p=[],v,t,y,S,H=true,M=x(h),I=g;(f.exec(""),v=f.exec(I))!==null;){I=v[3];p.push(v[1]);if(v[2]){S=v[3];break}}if(p.length>1&&r.exec(g))if(p.length===2&&n.relative[p[0]])t=ga(p[0]+p[1],h);else for(t=n.relative[p[0]]?[h]:k(p.shift(),h);p.length;){g=p.shift();if(n.relative[g])g+=p.shift(); +t=ga(g,t)}else{if(!m&&p.length>1&&h.nodeType===9&&!M&&n.match.ID.test(p[0])&&!n.match.ID.test(p[p.length-1])){v=k.find(p.shift(),h,M);h=v.expr?k.filter(v.expr,v.set)[0]:v.set[0]}if(h){v=m?{expr:p.pop(),set:z(m)}:k.find(p.pop(),p.length===1&&(p[0]==="~"||p[0]==="+")&&h.parentNode?h.parentNode:h,M);t=v.expr?k.filter(v.expr,v.set):v.set;if(p.length>0)y=z(t);else H=false;for(;p.length;){var D=p.pop();v=D;if(n.relative[D])v=p.pop();else D="";if(v==null)v=h;n.relative[D](y,v,M)}}else y=[]}y||(y=t);y||k.error(D|| +g);if(j.call(y)==="[object Array]")if(H)if(h&&h.nodeType===1)for(g=0;y[g]!=null;g++){if(y[g]&&(y[g]===true||y[g].nodeType===1&&E(h,y[g])))l.push(t[g])}else for(g=0;y[g]!=null;g++)y[g]&&y[g].nodeType===1&&l.push(t[g]);else l.push.apply(l,y);else z(y,l);if(S){k(S,q,l,m);k.uniqueSort(l)}return l};k.uniqueSort=function(g){if(B){i=o;g.sort(B);if(i)for(var h=1;h":function(g,h){var l=typeof h==="string";if(l&&!/\W/.test(h)){h=h.toLowerCase();for(var m=0,q=g.length;m=0))l||m.push(v);else if(l)h[p]=false;return false},ID:function(g){return g[1].replace(/\\/g,"")},TAG:function(g){return g[1].toLowerCase()}, +CHILD:function(g){if(g[1]==="nth"){var h=/(-?)(\d*)n((?:\+|-)?\d*)/.exec(g[2]==="even"&&"2n"||g[2]==="odd"&&"2n+1"||!/\D/.test(g[2])&&"0n+"+g[2]||g[2]);g[2]=h[1]+(h[2]||1)-0;g[3]=h[3]-0}g[0]=e++;return g},ATTR:function(g,h,l,m,q,p){h=g[1].replace(/\\/g,"");if(!p&&n.attrMap[h])g[1]=n.attrMap[h];if(g[2]==="~=")g[4]=" "+g[4]+" ";return g},PSEUDO:function(g,h,l,m,q){if(g[1]==="not")if((f.exec(g[3])||"").length>1||/^\w/.test(g[3]))g[3]=k(g[3],null,null,h);else{g=k.filter(g[3],h,l,true^q);l||m.push.apply(m, +g);return false}else if(n.match.POS.test(g[0])||n.match.CHILD.test(g[0]))return true;return g},POS:function(g){g.unshift(true);return g}},filters:{enabled:function(g){return g.disabled===false&&g.type!=="hidden"},disabled:function(g){return g.disabled===true},checked:function(g){return g.checked===true},selected:function(g){return g.selected===true},parent:function(g){return!!g.firstChild},empty:function(g){return!g.firstChild},has:function(g,h,l){return!!k(l[3],g).length},header:function(g){return/h\d/i.test(g.nodeName)}, +text:function(g){return"text"===g.type},radio:function(g){return"radio"===g.type},checkbox:function(g){return"checkbox"===g.type},file:function(g){return"file"===g.type},password:function(g){return"password"===g.type},submit:function(g){return"submit"===g.type},image:function(g){return"image"===g.type},reset:function(g){return"reset"===g.type},button:function(g){return"button"===g.type||g.nodeName.toLowerCase()==="button"},input:function(g){return/input|select|textarea|button/i.test(g.nodeName)}}, +setFilters:{first:function(g,h){return h===0},last:function(g,h,l,m){return h===m.length-1},even:function(g,h){return h%2===0},odd:function(g,h){return h%2===1},lt:function(g,h,l){return hl[3]-0},nth:function(g,h,l){return l[3]-0===h},eq:function(g,h,l){return l[3]-0===h}},filter:{PSEUDO:function(g,h,l,m){var q=h[1],p=n.filters[q];if(p)return p(g,l,h,m);else if(q==="contains")return(g.textContent||g.innerText||a([g])||"").indexOf(h[3])>=0;else if(q==="not"){h= +h[3];l=0;for(m=h.length;l=0}},ID:function(g,h){return g.nodeType===1&&g.getAttribute("id")===h},TAG:function(g,h){return h==="*"&&g.nodeType===1||g.nodeName.toLowerCase()===h},CLASS:function(g,h){return(" "+(g.className||g.getAttribute("class"))+" ").indexOf(h)>-1},ATTR:function(g,h){var l=h[1];g=n.attrHandle[l]?n.attrHandle[l](g):g[l]!=null?g[l]:g.getAttribute(l);l=g+"";var m=h[2];h=h[4];return g==null?m==="!=":m=== +"="?l===h:m==="*="?l.indexOf(h)>=0:m==="~="?(" "+l+" ").indexOf(h)>=0:!h?l&&g!==false:m==="!="?l!==h:m==="^="?l.indexOf(h)===0:m==="$="?l.substr(l.length-h.length)===h:m==="|="?l===h||l.substr(0,h.length+1)===h+"-":false},POS:function(g,h,l,m){var q=n.setFilters[h[2]];if(q)return q(g,l,h,m)}}},r=n.match.POS;for(var u in n.match){n.match[u]=new RegExp(n.match[u].source+/(?![^\[]*\])(?![^\(]*\))/.source);n.leftMatch[u]=new RegExp(/(^(?:.|\r|\n)*?)/.source+n.match[u].source.replace(/\\(\d+)/g,function(g, +h){return"\\"+(h-0+1)}))}var z=function(g,h){g=Array.prototype.slice.call(g,0);if(h){h.push.apply(h,g);return h}return g};try{Array.prototype.slice.call(s.documentElement.childNodes,0)}catch(C){z=function(g,h){h=h||[];if(j.call(g)==="[object Array]")Array.prototype.push.apply(h,g);else if(typeof g.length==="number")for(var l=0,m=g.length;l";var l=s.documentElement;l.insertBefore(g,l.firstChild);if(s.getElementById(h)){n.find.ID=function(m,q,p){if(typeof q.getElementById!=="undefined"&&!p)return(q=q.getElementById(m[1]))?q.id===m[1]||typeof q.getAttributeNode!=="undefined"&& +q.getAttributeNode("id").nodeValue===m[1]?[q]:w:[]};n.filter.ID=function(m,q){var p=typeof m.getAttributeNode!=="undefined"&&m.getAttributeNode("id");return m.nodeType===1&&p&&p.nodeValue===q}}l.removeChild(g);l=g=null})();(function(){var g=s.createElement("div");g.appendChild(s.createComment(""));if(g.getElementsByTagName("*").length>0)n.find.TAG=function(h,l){l=l.getElementsByTagName(h[1]);if(h[1]==="*"){h=[];for(var m=0;l[m];m++)l[m].nodeType===1&&h.push(l[m]);l=h}return l};g.innerHTML=""; +if(g.firstChild&&typeof g.firstChild.getAttribute!=="undefined"&&g.firstChild.getAttribute("href")!=="#")n.attrHandle.href=function(h){return h.getAttribute("href",2)};g=null})();s.querySelectorAll&&function(){var g=k,h=s.createElement("div");h.innerHTML="

";if(!(h.querySelectorAll&&h.querySelectorAll(".TEST").length===0)){k=function(m,q,p,v){q=q||s;if(!v&&q.nodeType===9&&!x(q))try{return z(q.querySelectorAll(m),p)}catch(t){}return g(m,q,p,v)};for(var l in g)k[l]=g[l];h=null}}(); +(function(){var g=s.createElement("div");g.innerHTML="
";if(!(!g.getElementsByClassName||g.getElementsByClassName("e").length===0)){g.lastChild.className="e";if(g.getElementsByClassName("e").length!==1){n.order.splice(1,0,"CLASS");n.find.CLASS=function(h,l,m){if(typeof l.getElementsByClassName!=="undefined"&&!m)return l.getElementsByClassName(h[1])};g=null}}})();var E=s.compareDocumentPosition?function(g,h){return!!(g.compareDocumentPosition(h)&16)}: +function(g,h){return g!==h&&(g.contains?g.contains(h):true)},x=function(g){return(g=(g?g.ownerDocument||g:0).documentElement)?g.nodeName!=="HTML":false},ga=function(g,h){var l=[],m="",q;for(h=h.nodeType?[h]:h;q=n.match.PSEUDO.exec(g);){m+=q[0];g=g.replace(n.match.PSEUDO,"")}g=n.relative[g]?g+"*":g;q=0;for(var p=h.length;q=0===d})};c.fn.extend({find:function(a){for(var b=this.pushStack("","find",a),d=0,f=0,e=this.length;f0)for(var j=d;j0},closest:function(a,b){if(c.isArray(a)){var d=[],f=this[0],e,j= +{},i;if(f&&a.length){e=0;for(var o=a.length;e-1:c(f).is(e)){d.push({selector:i,elem:f});delete j[i]}}f=f.parentNode}}return d}var k=c.expr.match.POS.test(a)?c(a,b||this.context):null;return this.map(function(n,r){for(;r&&r.ownerDocument&&r!==b;){if(k?k.index(r)>-1:c(r).is(a))return r;r=r.parentNode}return null})},index:function(a){if(!a||typeof a=== +"string")return c.inArray(this[0],a?c(a):this.parent().children());return c.inArray(a.jquery?a[0]:a,this)},add:function(a,b){a=typeof a==="string"?c(a,b||this.context):c.makeArray(a);b=c.merge(this.get(),a);return this.pushStack(qa(a[0])||qa(b[0])?b:c.unique(b))},andSelf:function(){return this.add(this.prevObject)}});c.each({parent:function(a){return(a=a.parentNode)&&a.nodeType!==11?a:null},parents:function(a){return c.dir(a,"parentNode")},parentsUntil:function(a,b,d){return c.dir(a,"parentNode", +d)},next:function(a){return c.nth(a,2,"nextSibling")},prev:function(a){return c.nth(a,2,"previousSibling")},nextAll:function(a){return c.dir(a,"nextSibling")},prevAll:function(a){return c.dir(a,"previousSibling")},nextUntil:function(a,b,d){return c.dir(a,"nextSibling",d)},prevUntil:function(a,b,d){return c.dir(a,"previousSibling",d)},siblings:function(a){return c.sibling(a.parentNode.firstChild,a)},children:function(a){return c.sibling(a.firstChild)},contents:function(a){return c.nodeName(a,"iframe")? +a.contentDocument||a.contentWindow.document:c.makeArray(a.childNodes)}},function(a,b){c.fn[a]=function(d,f){var e=c.map(this,b,d);eb.test(a)||(f=d);if(f&&typeof f==="string")e=c.filter(f,e);e=this.length>1?c.unique(e):e;if((this.length>1||gb.test(f))&&fb.test(a))e=e.reverse();return this.pushStack(e,a,R.call(arguments).join(","))}});c.extend({filter:function(a,b,d){if(d)a=":not("+a+")";return c.find.matches(a,b)},dir:function(a,b,d){var f=[];for(a=a[b];a&&a.nodeType!==9&&(d===w||a.nodeType!==1||!c(a).is(d));){a.nodeType=== +1&&f.push(a);a=a[b]}return f},nth:function(a,b,d){b=b||1;for(var f=0;a;a=a[d])if(a.nodeType===1&&++f===b)break;return a},sibling:function(a,b){for(var d=[];a;a=a.nextSibling)a.nodeType===1&&a!==b&&d.push(a);return d}});var Ja=/ jQuery\d+="(?:\d+|null)"/g,V=/^\s+/,Ka=/(<([\w:]+)[^>]*?)\/>/g,hb=/^(?:area|br|col|embed|hr|img|input|link|meta|param)$/i,La=/<([\w:]+)/,ib=/"},F={option:[1,""],legend:[1,"
","
"],thead:[1,"","
"],tr:[2,"","
"],td:[3,"","
"],col:[2,"","
"],area:[1,"",""],_default:[0,"",""]};F.optgroup=F.option;F.tbody=F.tfoot=F.colgroup=F.caption=F.thead;F.th=F.td;if(!c.support.htmlSerialize)F._default=[1,"div
","
"];c.fn.extend({text:function(a){if(c.isFunction(a))return this.each(function(b){var d= +c(this);d.text(a.call(this,b,d.text()))});if(typeof a!=="object"&&a!==w)return this.empty().append((this[0]&&this[0].ownerDocument||s).createTextNode(a));return c.text(this)},wrapAll:function(a){if(c.isFunction(a))return this.each(function(d){c(this).wrapAll(a.call(this,d))});if(this[0]){var b=c(a,this[0].ownerDocument).eq(0).clone(true);this[0].parentNode&&b.insertBefore(this[0]);b.map(function(){for(var d=this;d.firstChild&&d.firstChild.nodeType===1;)d=d.firstChild;return d}).append(this)}return this}, +wrapInner:function(a){if(c.isFunction(a))return this.each(function(b){c(this).wrapInner(a.call(this,b))});return this.each(function(){var b=c(this),d=b.contents();d.length?d.wrapAll(a):b.append(a)})},wrap:function(a){return this.each(function(){c(this).wrapAll(a)})},unwrap:function(){return this.parent().each(function(){c.nodeName(this,"body")||c(this).replaceWith(this.childNodes)}).end()},append:function(){return this.domManip(arguments,true,function(a){this.nodeType===1&&this.appendChild(a)})}, +prepend:function(){return this.domManip(arguments,true,function(a){this.nodeType===1&&this.insertBefore(a,this.firstChild)})},before:function(){if(this[0]&&this[0].parentNode)return this.domManip(arguments,false,function(b){this.parentNode.insertBefore(b,this)});else if(arguments.length){var a=c(arguments[0]);a.push.apply(a,this.toArray());return this.pushStack(a,"before",arguments)}},after:function(){if(this[0]&&this[0].parentNode)return this.domManip(arguments,false,function(b){this.parentNode.insertBefore(b, +this.nextSibling)});else if(arguments.length){var a=this.pushStack(this,"after",arguments);a.push.apply(a,c(arguments[0]).toArray());return a}},remove:function(a,b){for(var d=0,f;(f=this[d])!=null;d++)if(!a||c.filter(a,[f]).length){if(!b&&f.nodeType===1){c.cleanData(f.getElementsByTagName("*"));c.cleanData([f])}f.parentNode&&f.parentNode.removeChild(f)}return this},empty:function(){for(var a=0,b;(b=this[a])!=null;a++)for(b.nodeType===1&&c.cleanData(b.getElementsByTagName("*"));b.firstChild;)b.removeChild(b.firstChild); +return this},clone:function(a){var b=this.map(function(){if(!c.support.noCloneEvent&&!c.isXMLDoc(this)){var d=this.outerHTML,f=this.ownerDocument;if(!d){d=f.createElement("div");d.appendChild(this.cloneNode(true));d=d.innerHTML}return c.clean([d.replace(Ja,"").replace(/=([^="'>\s]+\/)>/g,'="$1">').replace(V,"")],f)[0]}else return this.cloneNode(true)});if(a===true){ra(this,b);ra(this.find("*"),b.find("*"))}return b},html:function(a){if(a===w)return this[0]&&this[0].nodeType===1?this[0].innerHTML.replace(Ja, +""):null;else if(typeof a==="string"&&!ta.test(a)&&(c.support.leadingWhitespace||!V.test(a))&&!F[(La.exec(a)||["",""])[1].toLowerCase()]){a=a.replace(Ka,Ma);try{for(var b=0,d=this.length;b0||e.cacheable||this.length>1?k.cloneNode(true):k)}o.length&&c.each(o,Qa)}return this}});c.fragments={};c.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(a,b){c.fn[a]=function(d){var f=[];d=c(d);var e=this.length===1&&this[0].parentNode;if(e&&e.nodeType===11&&e.childNodes.length===1&&d.length===1){d[b](this[0]); +return this}else{e=0;for(var j=d.length;e0?this.clone(true):this).get();c.fn[b].apply(c(d[e]),i);f=f.concat(i)}return this.pushStack(f,a,d.selector)}}});c.extend({clean:function(a,b,d,f){b=b||s;if(typeof b.createElement==="undefined")b=b.ownerDocument||b[0]&&b[0].ownerDocument||s;for(var e=[],j=0,i;(i=a[j])!=null;j++){if(typeof i==="number")i+="";if(i){if(typeof i==="string"&&!jb.test(i))i=b.createTextNode(i);else if(typeof i==="string"){i=i.replace(Ka,Ma);var o=(La.exec(i)||["", +""])[1].toLowerCase(),k=F[o]||F._default,n=k[0],r=b.createElement("div");for(r.innerHTML=k[1]+i+k[2];n--;)r=r.lastChild;if(!c.support.tbody){n=ib.test(i);o=o==="table"&&!n?r.firstChild&&r.firstChild.childNodes:k[1]===""&&!n?r.childNodes:[];for(k=o.length-1;k>=0;--k)c.nodeName(o[k],"tbody")&&!o[k].childNodes.length&&o[k].parentNode.removeChild(o[k])}!c.support.leadingWhitespace&&V.test(i)&&r.insertBefore(b.createTextNode(V.exec(i)[0]),r.firstChild);i=r.childNodes}if(i.nodeType)e.push(i);else e= +c.merge(e,i)}}if(d)for(j=0;e[j];j++)if(f&&c.nodeName(e[j],"script")&&(!e[j].type||e[j].type.toLowerCase()==="text/javascript"))f.push(e[j].parentNode?e[j].parentNode.removeChild(e[j]):e[j]);else{e[j].nodeType===1&&e.splice.apply(e,[j+1,0].concat(c.makeArray(e[j].getElementsByTagName("script"))));d.appendChild(e[j])}return e},cleanData:function(a){for(var b,d,f=c.cache,e=c.event.special,j=c.support.deleteExpando,i=0,o;(o=a[i])!=null;i++)if(d=o[c.expando]){b=f[d];if(b.events)for(var k in b.events)e[k]? +c.event.remove(o,k):Ca(o,k,b.handle);if(j)delete o[c.expando];else o.removeAttribute&&o.removeAttribute(c.expando);delete f[d]}}});var kb=/z-?index|font-?weight|opacity|zoom|line-?height/i,Na=/alpha\([^)]*\)/,Oa=/opacity=([^)]*)/,ha=/float/i,ia=/-([a-z])/ig,lb=/([A-Z])/g,mb=/^-?\d+(?:px)?$/i,nb=/^-?\d/,ob={position:"absolute",visibility:"hidden",display:"block"},pb=["Left","Right"],qb=["Top","Bottom"],rb=s.defaultView&&s.defaultView.getComputedStyle,Pa=c.support.cssFloat?"cssFloat":"styleFloat",ja= +function(a,b){return b.toUpperCase()};c.fn.css=function(a,b){return X(this,a,b,true,function(d,f,e){if(e===w)return c.curCSS(d,f);if(typeof e==="number"&&!kb.test(f))e+="px";c.style(d,f,e)})};c.extend({style:function(a,b,d){if(!a||a.nodeType===3||a.nodeType===8)return w;if((b==="width"||b==="height")&&parseFloat(d)<0)d=w;var f=a.style||a,e=d!==w;if(!c.support.opacity&&b==="opacity"){if(e){f.zoom=1;b=parseInt(d,10)+""==="NaN"?"":"alpha(opacity="+d*100+")";a=f.filter||c.curCSS(a,"filter")||"";f.filter= +Na.test(a)?a.replace(Na,b):b}return f.filter&&f.filter.indexOf("opacity=")>=0?parseFloat(Oa.exec(f.filter)[1])/100+"":""}if(ha.test(b))b=Pa;b=b.replace(ia,ja);if(e)f[b]=d;return f[b]},css:function(a,b,d,f){if(b==="width"||b==="height"){var e,j=b==="width"?pb:qb;function i(){e=b==="width"?a.offsetWidth:a.offsetHeight;f!=="border"&&c.each(j,function(){f||(e-=parseFloat(c.curCSS(a,"padding"+this,true))||0);if(f==="margin")e+=parseFloat(c.curCSS(a,"margin"+this,true))||0;else e-=parseFloat(c.curCSS(a, +"border"+this+"Width",true))||0})}a.offsetWidth!==0?i():c.swap(a,ob,i);return Math.max(0,Math.round(e))}return c.curCSS(a,b,d)},curCSS:function(a,b,d){var f,e=a.style;if(!c.support.opacity&&b==="opacity"&&a.currentStyle){f=Oa.test(a.currentStyle.filter||"")?parseFloat(RegExp.$1)/100+"":"";return f===""?"1":f}if(ha.test(b))b=Pa;if(!d&&e&&e[b])f=e[b];else if(rb){if(ha.test(b))b="float";b=b.replace(lb,"-$1").toLowerCase();e=a.ownerDocument.defaultView;if(!e)return null;if(a=e.getComputedStyle(a,null))f= +a.getPropertyValue(b);if(b==="opacity"&&f==="")f="1"}else if(a.currentStyle){d=b.replace(ia,ja);f=a.currentStyle[b]||a.currentStyle[d];if(!mb.test(f)&&nb.test(f)){b=e.left;var j=a.runtimeStyle.left;a.runtimeStyle.left=a.currentStyle.left;e.left=d==="fontSize"?"1em":f||0;f=e.pixelLeft+"px";e.left=b;a.runtimeStyle.left=j}}return f},swap:function(a,b,d){var f={};for(var e in b){f[e]=a.style[e];a.style[e]=b[e]}d.call(a);for(e in b)a.style[e]=f[e]}});if(c.expr&&c.expr.filters){c.expr.filters.hidden=function(a){var b= +a.offsetWidth,d=a.offsetHeight,f=a.nodeName.toLowerCase()==="tr";return b===0&&d===0&&!f?true:b>0&&d>0&&!f?false:c.curCSS(a,"display")==="none"};c.expr.filters.visible=function(a){return!c.expr.filters.hidden(a)}}var sb=J(),tb=//gi,ub=/select|textarea/i,vb=/color|date|datetime|email|hidden|month|number|password|range|search|tel|text|time|url|week/i,N=/=\?(&|$)/,ka=/\?/,wb=/(\?|&)_=.*?(&|$)/,xb=/^(\w+:)?\/\/([^\/?#]+)/,yb=/%20/g,zb=c.fn.load;c.fn.extend({load:function(a,b,d){if(typeof a!== +"string")return zb.call(this,a);else if(!this.length)return this;var f=a.indexOf(" ");if(f>=0){var e=a.slice(f,a.length);a=a.slice(0,f)}f="GET";if(b)if(c.isFunction(b)){d=b;b=null}else if(typeof b==="object"){b=c.param(b,c.ajaxSettings.traditional);f="POST"}var j=this;c.ajax({url:a,type:f,dataType:"html",data:b,complete:function(i,o){if(o==="success"||o==="notmodified")j.html(e?c("
").append(i.responseText.replace(tb,"")).find(e):i.responseText);d&&j.each(d,[i.responseText,o,i])}});return this}, +serialize:function(){return c.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return this.elements?c.makeArray(this.elements):this}).filter(function(){return this.name&&!this.disabled&&(this.checked||ub.test(this.nodeName)||vb.test(this.type))}).map(function(a,b){a=c(this).val();return a==null?null:c.isArray(a)?c.map(a,function(d){return{name:b.name,value:d}}):{name:b.name,value:a}}).get()}});c.each("ajaxStart ajaxStop ajaxComplete ajaxError ajaxSuccess ajaxSend".split(" "), +function(a,b){c.fn[b]=function(d){return this.bind(b,d)}});c.extend({get:function(a,b,d,f){if(c.isFunction(b)){f=f||d;d=b;b=null}return c.ajax({type:"GET",url:a,data:b,success:d,dataType:f})},getScript:function(a,b){return c.get(a,null,b,"script")},getJSON:function(a,b,d){return c.get(a,b,d,"json")},post:function(a,b,d,f){if(c.isFunction(b)){f=f||d;d=b;b={}}return c.ajax({type:"POST",url:a,data:b,success:d,dataType:f})},ajaxSetup:function(a){c.extend(c.ajaxSettings,a)},ajaxSettings:{url:location.href, +global:true,type:"GET",contentType:"application/x-www-form-urlencoded",processData:true,async:true,xhr:A.XMLHttpRequest&&(A.location.protocol!=="file:"||!A.ActiveXObject)?function(){return new A.XMLHttpRequest}:function(){try{return new A.ActiveXObject("Microsoft.XMLHTTP")}catch(a){}},accepts:{xml:"application/xml, text/xml",html:"text/html",script:"text/javascript, application/javascript",json:"application/json, text/javascript",text:"text/plain",_default:"*/*"}},lastModified:{},etag:{},ajax:function(a){function b(){e.success&& +e.success.call(k,o,i,x);e.global&&f("ajaxSuccess",[x,e])}function d(){e.complete&&e.complete.call(k,x,i);e.global&&f("ajaxComplete",[x,e]);e.global&&!--c.active&&c.event.trigger("ajaxStop")}function f(q,p){(e.context?c(e.context):c.event).trigger(q,p)}var e=c.extend(true,{},c.ajaxSettings,a),j,i,o,k=a&&a.context||e,n=e.type.toUpperCase();if(e.data&&e.processData&&typeof e.data!=="string")e.data=c.param(e.data,e.traditional);if(e.dataType==="jsonp"){if(n==="GET")N.test(e.url)||(e.url+=(ka.test(e.url)? +"&":"?")+(e.jsonp||"callback")+"=?");else if(!e.data||!N.test(e.data))e.data=(e.data?e.data+"&":"")+(e.jsonp||"callback")+"=?";e.dataType="json"}if(e.dataType==="json"&&(e.data&&N.test(e.data)||N.test(e.url))){j=e.jsonpCallback||"jsonp"+sb++;if(e.data)e.data=(e.data+"").replace(N,"="+j+"$1");e.url=e.url.replace(N,"="+j+"$1");e.dataType="script";A[j]=A[j]||function(q){o=q;b();d();A[j]=w;try{delete A[j]}catch(p){}z&&z.removeChild(C)}}if(e.dataType==="script"&&e.cache===null)e.cache=false;if(e.cache=== +false&&n==="GET"){var r=J(),u=e.url.replace(wb,"$1_="+r+"$2");e.url=u+(u===e.url?(ka.test(e.url)?"&":"?")+"_="+r:"")}if(e.data&&n==="GET")e.url+=(ka.test(e.url)?"&":"?")+e.data;e.global&&!c.active++&&c.event.trigger("ajaxStart");r=(r=xb.exec(e.url))&&(r[1]&&r[1]!==location.protocol||r[2]!==location.host);if(e.dataType==="script"&&n==="GET"&&r){var z=s.getElementsByTagName("head")[0]||s.documentElement,C=s.createElement("script");C.src=e.url;if(e.scriptCharset)C.charset=e.scriptCharset;if(!j){var B= +false;C.onload=C.onreadystatechange=function(){if(!B&&(!this.readyState||this.readyState==="loaded"||this.readyState==="complete")){B=true;b();d();C.onload=C.onreadystatechange=null;z&&C.parentNode&&z.removeChild(C)}}}z.insertBefore(C,z.firstChild);return w}var E=false,x=e.xhr();if(x){e.username?x.open(n,e.url,e.async,e.username,e.password):x.open(n,e.url,e.async);try{if(e.data||a&&a.contentType)x.setRequestHeader("Content-Type",e.contentType);if(e.ifModified){c.lastModified[e.url]&&x.setRequestHeader("If-Modified-Since", +c.lastModified[e.url]);c.etag[e.url]&&x.setRequestHeader("If-None-Match",c.etag[e.url])}r||x.setRequestHeader("X-Requested-With","XMLHttpRequest");x.setRequestHeader("Accept",e.dataType&&e.accepts[e.dataType]?e.accepts[e.dataType]+", */*":e.accepts._default)}catch(ga){}if(e.beforeSend&&e.beforeSend.call(k,x,e)===false){e.global&&!--c.active&&c.event.trigger("ajaxStop");x.abort();return false}e.global&&f("ajaxSend",[x,e]);var g=x.onreadystatechange=function(q){if(!x||x.readyState===0||q==="abort"){E|| +d();E=true;if(x)x.onreadystatechange=c.noop}else if(!E&&x&&(x.readyState===4||q==="timeout")){E=true;x.onreadystatechange=c.noop;i=q==="timeout"?"timeout":!c.httpSuccess(x)?"error":e.ifModified&&c.httpNotModified(x,e.url)?"notmodified":"success";var p;if(i==="success")try{o=c.httpData(x,e.dataType,e)}catch(v){i="parsererror";p=v}if(i==="success"||i==="notmodified")j||b();else c.handleError(e,x,i,p);d();q==="timeout"&&x.abort();if(e.async)x=null}};try{var h=x.abort;x.abort=function(){x&&h.call(x); +g("abort")}}catch(l){}e.async&&e.timeout>0&&setTimeout(function(){x&&!E&&g("timeout")},e.timeout);try{x.send(n==="POST"||n==="PUT"||n==="DELETE"?e.data:null)}catch(m){c.handleError(e,x,null,m);d()}e.async||g();return x}},handleError:function(a,b,d,f){if(a.error)a.error.call(a.context||a,b,d,f);if(a.global)(a.context?c(a.context):c.event).trigger("ajaxError",[b,a,f])},active:0,httpSuccess:function(a){try{return!a.status&&location.protocol==="file:"||a.status>=200&&a.status<300||a.status===304||a.status=== +1223||a.status===0}catch(b){}return false},httpNotModified:function(a,b){var d=a.getResponseHeader("Last-Modified"),f=a.getResponseHeader("Etag");if(d)c.lastModified[b]=d;if(f)c.etag[b]=f;return a.status===304||a.status===0},httpData:function(a,b,d){var f=a.getResponseHeader("content-type")||"",e=b==="xml"||!b&&f.indexOf("xml")>=0;a=e?a.responseXML:a.responseText;e&&a.documentElement.nodeName==="parsererror"&&c.error("parsererror");if(d&&d.dataFilter)a=d.dataFilter(a,b);if(typeof a==="string")if(b=== +"json"||!b&&f.indexOf("json")>=0)a=c.parseJSON(a);else if(b==="script"||!b&&f.indexOf("javascript")>=0)c.globalEval(a);return a},param:function(a,b){function d(i,o){if(c.isArray(o))c.each(o,function(k,n){b||/\[\]$/.test(i)?f(i,n):d(i+"["+(typeof n==="object"||c.isArray(n)?k:"")+"]",n)});else!b&&o!=null&&typeof o==="object"?c.each(o,function(k,n){d(i+"["+k+"]",n)}):f(i,o)}function f(i,o){o=c.isFunction(o)?o():o;e[e.length]=encodeURIComponent(i)+"="+encodeURIComponent(o)}var e=[];if(b===w)b=c.ajaxSettings.traditional; +if(c.isArray(a)||a.jquery)c.each(a,function(){f(this.name,this.value)});else for(var j in a)d(j,a[j]);return e.join("&").replace(yb,"+")}});var la={},Ab=/toggle|show|hide/,Bb=/^([+-]=)?([\d+-.]+)(.*)$/,W,va=[["height","marginTop","marginBottom","paddingTop","paddingBottom"],["width","marginLeft","marginRight","paddingLeft","paddingRight"],["opacity"]];c.fn.extend({show:function(a,b){if(a||a===0)return this.animate(K("show",3),a,b);else{a=0;for(b=this.length;a").appendTo("body");f=e.css("display");if(f==="none")f="block";e.remove();la[d]=f}c.data(this[a],"olddisplay",f)}}a=0;for(b=this.length;a=0;f--)if(d[f].elem===this){b&&d[f](true);d.splice(f,1)}});b||this.dequeue();return this}});c.each({slideDown:K("show",1),slideUp:K("hide",1),slideToggle:K("toggle",1),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"}},function(a,b){c.fn[a]=function(d,f){return this.animate(b,d,f)}});c.extend({speed:function(a,b,d){var f=a&&typeof a==="object"?a:{complete:d||!d&&b||c.isFunction(a)&&a,duration:a,easing:d&&b||b&&!c.isFunction(b)&&b};f.duration=c.fx.off?0:typeof f.duration=== +"number"?f.duration:c.fx.speeds[f.duration]||c.fx.speeds._default;f.old=f.complete;f.complete=function(){f.queue!==false&&c(this).dequeue();c.isFunction(f.old)&&f.old.call(this)};return f},easing:{linear:function(a,b,d,f){return d+f*a},swing:function(a,b,d,f){return(-Math.cos(a*Math.PI)/2+0.5)*f+d}},timers:[],fx:function(a,b,d){this.options=b;this.elem=a;this.prop=d;if(!b.orig)b.orig={}}});c.fx.prototype={update:function(){this.options.step&&this.options.step.call(this.elem,this.now,this);(c.fx.step[this.prop]|| +c.fx.step._default)(this);if((this.prop==="height"||this.prop==="width")&&this.elem.style)this.elem.style.display="block"},cur:function(a){if(this.elem[this.prop]!=null&&(!this.elem.style||this.elem.style[this.prop]==null))return this.elem[this.prop];return(a=parseFloat(c.css(this.elem,this.prop,a)))&&a>-10000?a:parseFloat(c.curCSS(this.elem,this.prop))||0},custom:function(a,b,d){function f(j){return e.step(j)}this.startTime=J();this.start=a;this.end=b;this.unit=d||this.unit||"px";this.now=this.start; +this.pos=this.state=0;var e=this;f.elem=this.elem;if(f()&&c.timers.push(f)&&!W)W=setInterval(c.fx.tick,13)},show:function(){this.options.orig[this.prop]=c.style(this.elem,this.prop);this.options.show=true;this.custom(this.prop==="width"||this.prop==="height"?1:0,this.cur());c(this.elem).show()},hide:function(){this.options.orig[this.prop]=c.style(this.elem,this.prop);this.options.hide=true;this.custom(this.cur(),0)},step:function(a){var b=J(),d=true;if(a||b>=this.options.duration+this.startTime){this.now= +this.end;this.pos=this.state=1;this.update();this.options.curAnim[this.prop]=true;for(var f in this.options.curAnim)if(this.options.curAnim[f]!==true)d=false;if(d){if(this.options.display!=null){this.elem.style.overflow=this.options.overflow;a=c.data(this.elem,"olddisplay");this.elem.style.display=a?a:this.options.display;if(c.css(this.elem,"display")==="none")this.elem.style.display="block"}this.options.hide&&c(this.elem).hide();if(this.options.hide||this.options.show)for(var e in this.options.curAnim)c.style(this.elem, +e,this.options.orig[e]);this.options.complete.call(this.elem)}return false}else{e=b-this.startTime;this.state=e/this.options.duration;a=this.options.easing||(c.easing.swing?"swing":"linear");this.pos=c.easing[this.options.specialEasing&&this.options.specialEasing[this.prop]||a](this.state,e,0,1,this.options.duration);this.now=this.start+(this.end-this.start)*this.pos;this.update()}return true}};c.extend(c.fx,{tick:function(){for(var a=c.timers,b=0;b
"; +a.insertBefore(b,a.firstChild);d=b.firstChild;f=d.firstChild;e=d.nextSibling.firstChild.firstChild;this.doesNotAddBorder=f.offsetTop!==5;this.doesAddBorderForTableAndCells=e.offsetTop===5;f.style.position="fixed";f.style.top="20px";this.supportsFixedPosition=f.offsetTop===20||f.offsetTop===15;f.style.position=f.style.top="";d.style.overflow="hidden";d.style.position="relative";this.subtractsBorderForOverflowNotVisible=f.offsetTop===-5;this.doesNotIncludeMarginInBodyOffset=a.offsetTop!==j;a.removeChild(b); +c.offset.initialize=c.noop},bodyOffset:function(a){var b=a.offsetTop,d=a.offsetLeft;c.offset.initialize();if(c.offset.doesNotIncludeMarginInBodyOffset){b+=parseFloat(c.curCSS(a,"marginTop",true))||0;d+=parseFloat(c.curCSS(a,"marginLeft",true))||0}return{top:b,left:d}},setOffset:function(a,b,d){if(/static/.test(c.curCSS(a,"position")))a.style.position="relative";var f=c(a),e=f.offset(),j=parseInt(c.curCSS(a,"top",true),10)||0,i=parseInt(c.curCSS(a,"left",true),10)||0;if(c.isFunction(b))b=b.call(a, +d,e);d={top:b.top-e.top+j,left:b.left-e.left+i};"using"in b?b.using.call(a,d):f.css(d)}};c.fn.extend({position:function(){if(!this[0])return null;var a=this[0],b=this.offsetParent(),d=this.offset(),f=/^body|html$/i.test(b[0].nodeName)?{top:0,left:0}:b.offset();d.top-=parseFloat(c.curCSS(a,"marginTop",true))||0;d.left-=parseFloat(c.curCSS(a,"marginLeft",true))||0;f.top+=parseFloat(c.curCSS(b[0],"borderTopWidth",true))||0;f.left+=parseFloat(c.curCSS(b[0],"borderLeftWidth",true))||0;return{top:d.top- +f.top,left:d.left-f.left}},offsetParent:function(){return this.map(function(){for(var a=this.offsetParent||s.body;a&&!/^body|html$/i.test(a.nodeName)&&c.css(a,"position")==="static";)a=a.offsetParent;return a})}});c.each(["Left","Top"],function(a,b){var d="scroll"+b;c.fn[d]=function(f){var e=this[0],j;if(!e)return null;if(f!==w)return this.each(function(){if(j=wa(this))j.scrollTo(!a?f:c(j).scrollLeft(),a?f:c(j).scrollTop());else this[d]=f});else return(j=wa(e))?"pageXOffset"in j?j[a?"pageYOffset": +"pageXOffset"]:c.support.boxModel&&j.document.documentElement[d]||j.document.body[d]:e[d]}});c.each(["Height","Width"],function(a,b){var d=b.toLowerCase();c.fn["inner"+b]=function(){return this[0]?c.css(this[0],d,false,"padding"):null};c.fn["outer"+b]=function(f){return this[0]?c.css(this[0],d,false,f?"margin":"border"):null};c.fn[d]=function(f){var e=this[0];if(!e)return f==null?null:this;if(c.isFunction(f))return this.each(function(j){var i=c(this);i[d](f.call(this,j,i[d]()))});return"scrollTo"in +e&&e.document?e.document.compatMode==="CSS1Compat"&&e.document.documentElement["client"+b]||e.document.body["client"+b]:e.nodeType===9?Math.max(e.documentElement["client"+b],e.body["scroll"+b],e.documentElement["scroll"+b],e.body["offset"+b],e.documentElement["offset"+b]):f===w?c.css(e,d):this.css(d,typeof f==="string"?f:f+"px")}});A.jQuery=A.$=c})(window); diff --git a/node_modules/dust/vendor/jsdump.js b/node_modules/dust/vendor/jsdump.js new file mode 100644 index 0000000..d7e67fa --- /dev/null +++ b/node_modules/dust/vendor/jsdump.js @@ -0,0 +1,163 @@ +/** + * jsDump + * Copyright (c) 2008 Ariel Flesler - aflesler(at)gmail(dot)com | http://flesler.blogspot.com + * Licensed under BSD (http://www.opensource.org/licenses/bsd-license.php) + * Date: 5/15/2008 + * @projectDescription Advanced and extensible data dumping for Javascript. + * @version 1.0.0 + * @author Ariel Flesler + * @link {http://flesler.blogspot.com/2008/05/jsdump-pretty-dump-of-any-javascript.html} + */ +var jsDump; + +(function(){ + function quote( str ){ + return '"' + str.toString().replace(/"/g, '\\"') + '"'; + } + function literal( o ){ + return o + ''; + } + function join( pre, arr, post ){ + var s = jsDump.separator(), + base = jsDump.indent(), + inner = jsDump.indent(1); + if( arr.join ) + arr = arr.join( ',' + s + inner ); + if( !arr ) + return pre + post; + return [ pre, inner + arr, base + post ].join(s); + } + function array( arr ){ + var i = arr.length, ret = Array(i); + this.up(); + while( i-- ) + ret[i] = this.parse( arr[i] ); + this.down(); + return join( '[', ret, ']' ); + } + + var reName = /^function (\w+)/; + + jsDump = { + parse:function( obj, type ){//type is used mostly internally, you can fix a (custom)type in advance + var parser = this.parsers[ type || this.typeOf(obj) ]; + type = typeof parser; + + return type == 'function' ? parser.call( this, obj ) : + type == 'string' ? parser : + this.parsers.error; + }, + typeOf:function( obj ){ + var type = typeof obj, + f = 'function';//we'll use it 3 times, save it + return type != 'object' && type != f ? type : + !obj ? 'null' : + obj.exec ? 'regexp' :// some browsers (FF) consider regexps functions + obj.getHours ? 'date' : + obj.scrollBy ? 'window' : + obj.nodeName == '#document' ? 'document' : + obj.nodeName ? 'node' : + obj.item ? 'nodelist' : // Safari reports nodelists as functions + obj.callee ? 'arguments' : + obj.call || obj.constructor != Array && //an array would also fall on this hack + (obj+'').indexOf(f) != -1 ? f : //IE reports functions like alert, as objects + 'length' in obj ? 'array' : + type; + }, + separator:function(){ + return this.multiline ? this.HTML ? '
' : '\n' : this.HTML ? ' ' : ' '; + }, + indent:function( extra ){// extra can be a number, shortcut for increasing-calling-decreasing + if( !this.multiline ) + return ''; + var chr = this.indentChar; + if( this.HTML ) + chr = chr.replace(/\t/g,' ').replace(/ /g,' '); + return Array( this._depth_ + (extra||0) ).join(chr); + }, + up:function( a ){ + this._depth_ += a || 1; + }, + down:function( a ){ + this._depth_ -= a || 1; + }, + setParser:function( name, parser ){ + this.parsers[name] = parser; + }, + // The next 3 are exposed so you can use them + quote:quote, + literal:literal, + join:join, + _depth_: 1, + // This is the list of parsers, to modify them, use jsDump.setParser + parsers:{ + window: '[Window]', + document: '[Document]', + error:'[ERROR]', //when no parser is found, shouldn't happen + unknown: '[Unknown]', + 'null':'null', + undefined:'undefined', + 'function':function( fn ){ + var ret = 'function', + name = 'name' in fn ? fn.name : (reName.exec(fn)||[])[1];//functions never have name in IE + if( name ) + ret += ' ' + name; + ret += '('; + ret = [ ret, this.parse( fn, 'functionArgs' ), '){'].join(''); + return join( ret, this.parse(fn,'functionCode'), '}' ); + }, + array: array, + nodelist: array, + arguments: array, + object:function( map ){ + var ret = [ ]; + this.up(); + for( var key in map ) + ret.push( this.parse(key,'key') + ': ' + this.parse(map[key]) ); + this.down(); + return join( '{', ret, '}' ); + }, + node:function( node ){ + var open = this.HTML ? '<' : '<', + close = this.HTML ? '>' : '>'; + var tag = node.nodeName.toLowerCase(), + ret = open + tag; + for( var a in this.DOMAttrs ){ + var val = node[this.DOMAttrs[a]]; + if( val ) + ret += ' ' + a + '=' + this.parse( val, 'attribute' ); + } + return ret + close + open + '/' + tag + close; + }, + functionArgs:function( fn ){//function calls it internally, it's the arguments part of the function + var l = fn.length; + if( !l ) return ''; + var args = Array(l); + while( l-- ) + args[l] = String.fromCharCode(97+l);//97 is 'a' + return ' ' + args.join(', ') + ' '; + }, + key:quote, //object calls it internally, the key part of an item in a map + functionCode:'[code]', //function calls it internally, it's the content of the function + attribute:quote, //node calls it internally, it's an html attribute value + string:quote, + date:quote, + regexp:literal, //regex + number:literal, + 'boolean':literal + }, + DOMAttrs:{//attributes to dump from nodes, name=>realName + id:'id', + name:'name', + 'class':'className' + }, + HTML:false,//if true, entities are escaped ( <, >, \t, space and \n ) + indentChar:' ',//indentation unit + multiline:true //if true, items in a collection, are separated by a \n, else just a space. + }; + +})(); + +if (typeof exports !== 'undefined') { + exports.jsDump = jsDump; +} \ No newline at end of file diff --git a/node_modules/dust/vendor/showdown.js b/node_modules/dust/vendor/showdown.js new file mode 100644 index 0000000..306dcb1 --- /dev/null +++ b/node_modules/dust/vendor/showdown.js @@ -0,0 +1,1296 @@ +// +// showdown.js -- A javascript port of Markdown. +// +// Copyright (c) 2007 John Fraser. +// +// Original Markdown Copyright (c) 2004-2005 John Gruber +// +// +// Redistributable under a BSD-style open source license. +// See license.txt for more information. +// +// The full source distribution is at: +// +// A A L +// T C A +// T K B +// +// +// + +// +// Wherever possible, Showdown is a straight, line-by-line port +// of the Perl version of Markdown. +// +// This is not a normal parser design; it's basically just a +// series of string substitutions. It's hard to read and +// maintain this way, but keeping Showdown close to the original +// design makes it easier to port new features. +// +// More importantly, Showdown behaves like markdown.pl in most +// edge cases. So web applications can do client-side preview +// in Javascript, and then build identical HTML on the server. +// +// This port needs the new RegExp functionality of ECMA 262, +// 3rd Edition (i.e. Javascript 1.5). Most modern web browsers +// should do fine. Even with the new regular expression features, +// We do a lot of work to emulate Perl's regex functionality. +// The tricky changes in this file mostly have the "attacklab:" +// label. Major or self-explanatory changes don't. +// +// Smart diff tools like Araxis Merge will be able to match up +// this file with markdown.pl in a useful way. A little tweaking +// helps: in a copy of markdown.pl, replace "#" with "//" and +// replace "$text" with "text". Be sure to ignore whitespace +// and line endings. +// + + +// +// Showdown usage: +// +// var text = "Markdown *rocks*."; +// +// var converter = new Showdown.converter(); +// var html = converter.makeHtml(text); +// +// alert(html); +// +// Note: move the sample code to the bottom of this +// file before uncommenting it. +// + + +// +// Showdown namespace +// +var Showdown = {}; + +// +// converter +// +// Wraps all "globals" so that the only thing +// exposed is makeHtml(). +// +Showdown.converter = function() { + +// +// Globals: +// + +// Global hashes, used by various utility routines +var g_urls; +var g_titles; +var g_html_blocks; + +// Used to track when we're inside an ordered or unordered list +// (see _ProcessListItems() for details): +var g_list_level = 0; + + +this.makeHtml = function(text) { +// +// Main function. The order in which other subs are called here is +// essential. Link and image substitutions need to happen before +// _EscapeSpecialCharsWithinTagAttributes(), so that any *'s or _'s in the +// and tags get encoded. +// + + // Clear the global hashes. If we don't clear these, you get conflicts + // from other articles when generating a page which contains more than + // one article (e.g. an index page that shows the N most recent + // articles): + g_urls = new Array(); + g_titles = new Array(); + g_html_blocks = new Array(); + + // attacklab: Replace ~ with ~T + // This lets us use tilde as an escape char to avoid md5 hashes + // The choice of character is arbitray; anything that isn't + // magic in Markdown will work. + text = text.replace(/~/g,"~T"); + + // attacklab: Replace $ with ~D + // RegExp interprets $ as a special character + // when it's in a replacement string + text = text.replace(/\$/g,"~D"); + + // Standardize line endings + text = text.replace(/\r\n/g,"\n"); // DOS to Unix + text = text.replace(/\r/g,"\n"); // Mac to Unix + + // Make sure text begins and ends with a couple of newlines: + text = "\n\n" + text + "\n\n"; + + // Convert all tabs to spaces. + text = _Detab(text); + + // Strip any lines consisting only of spaces and tabs. + // This makes subsequent regexen easier to write, because we can + // match consecutive blank lines with /\n+/ instead of something + // contorted like /[ \t]*\n+/ . + text = text.replace(/^[ \t]+$/mg,""); + + // Turn block-level HTML blocks into hash entries + text = _HashHTMLBlocks(text); + + // Strip link definitions, store in hashes. + text = _StripLinkDefinitions(text); + + text = _RunBlockGamut(text); + + text = _UnescapeSpecialChars(text); + + // attacklab: Restore dollar signs + text = text.replace(/~D/g,"$$"); + + // attacklab: Restore tildes + text = text.replace(/~T/g,"~"); + + return text; +} + + +var _StripLinkDefinitions = function(text) { +// +// Strips link definitions from text, stores the URLs and titles in +// hash references. +// + + // Link defs are in the form: ^[id]: url "optional title" + + /* + var text = text.replace(/ + ^[ ]{0,3}\[(.+)\]: // id = $1 attacklab: g_tab_width - 1 + [ \t]* + \n? // maybe *one* newline + [ \t]* + ? // url = $2 + [ \t]* + \n? // maybe one newline + [ \t]* + (?: + (\n*) // any lines skipped = $3 attacklab: lookbehind removed + ["(] + (.+?) // title = $4 + [")] + [ \t]* + )? // title is optional + (?:\n+|$) + /gm, + function(){...}); + */ + var text = text.replace(/^[ ]{0,3}\[(.+)\]:[ \t]*\n?[ \t]*?[ \t]*\n?[ \t]*(?:(\n*)["(](.+?)[")][ \t]*)?(?:\n+|\Z)/gm, + function (wholeMatch,m1,m2,m3,m4) { + m1 = m1.toLowerCase(); + g_urls[m1] = _EncodeAmpsAndAngles(m2); // Link IDs are case-insensitive + if (m3) { + // Oops, found blank lines, so it's not a title. + // Put back the parenthetical statement we stole. + return m3+m4; + } else if (m4) { + g_titles[m1] = m4.replace(/"/g,"""); + } + + // Completely remove the definition from the text + return ""; + } + ); + + return text; +} + + +var _HashHTMLBlocks = function(text) { + // attacklab: Double up blank lines to reduce lookaround + text = text.replace(/\n/g,"\n\n"); + + // Hashify HTML blocks: + // We only want to do this for block-level HTML tags, such as headers, + // lists, and tables. That's because we still want to wrap

s around + // "paragraphs" that are wrapped in non-block-level tags, such as anchors, + // phrase emphasis, and spans. The list of tags we're looking for is + // hard-coded: + var block_tags_a = "p|div|h[1-6]|blockquote|pre|table|dl|ol|ul|script|noscript|form|fieldset|iframe|math|ins|del" + var block_tags_b = "p|div|h[1-6]|blockquote|pre|table|dl|ol|ul|script|noscript|form|fieldset|iframe|math" + + // First, look for nested blocks, e.g.: + //

+ //
+ // tags for inner block must be indented. + //
+ //
+ // + // The outermost tags must start at the left margin for this to match, and + // the inner nested divs must be indented. + // We need to do this before the next, more liberal match, because the next + // match will start at the first `
` and stop at the first `
`. + + // attacklab: This regex can be expensive when it fails. + /* + var text = text.replace(/ + ( // save in $1 + ^ // start of line (with /m) + <($block_tags_a) // start tag = $2 + \b // word break + // attacklab: hack around khtml/pcre bug... + [^\r]*?\n // any number of lines, minimally matching + // the matching end tag + [ \t]* // trailing spaces/tabs + (?=\n+) // followed by a newline + ) // attacklab: there are sentinel newlines at end of document + /gm,function(){...}}; + */ + text = text.replace(/^(<(p|div|h[1-6]|blockquote|pre|table|dl|ol|ul|script|noscript|form|fieldset|iframe|math|ins|del)\b[^\r]*?\n<\/\2>[ \t]*(?=\n+))/gm,hashElement); + + // + // Now match more liberally, simply from `\n` to `\n` + // + + /* + var text = text.replace(/ + ( // save in $1 + ^ // start of line (with /m) + <($block_tags_b) // start tag = $2 + \b // word break + // attacklab: hack around khtml/pcre bug... + [^\r]*? // any number of lines, minimally matching + .* // the matching end tag + [ \t]* // trailing spaces/tabs + (?=\n+) // followed by a newline + ) // attacklab: there are sentinel newlines at end of document + /gm,function(){...}}; + */ + text = text.replace(/^(<(p|div|h[1-6]|blockquote|pre|table|dl|ol|ul|script|noscript|form|fieldset|iframe|math)\b[^\r]*?.*<\/\2>[ \t]*(?=\n+)\n)/gm,hashElement); + + // Special case just for
. It was easier to make a special case than + // to make the other regex more complicated. + + /* + text = text.replace(/ + ( // save in $1 + \n\n // Starting after a blank line + [ ]{0,3} + (<(hr) // start tag = $2 + \b // word break + ([^<>])*? // + \/?>) // the matching end tag + [ \t]* + (?=\n{2,}) // followed by a blank line + ) + /g,hashElement); + */ + text = text.replace(/(\n[ ]{0,3}(<(hr)\b([^<>])*?\/?>)[ \t]*(?=\n{2,}))/g,hashElement); + + // Special case for standalone HTML comments: + + /* + text = text.replace(/ + ( // save in $1 + \n\n // Starting after a blank line + [ ]{0,3} // attacklab: g_tab_width - 1 + + [ \t]* + (?=\n{2,}) // followed by a blank line + ) + /g,hashElement); + */ + text = text.replace(/(\n\n[ ]{0,3}[ \t]*(?=\n{2,}))/g,hashElement); + + // PHP and ASP-style processor instructions ( and <%...%>) + + /* + text = text.replace(/ + (?: + \n\n // Starting after a blank line + ) + ( // save in $1 + [ ]{0,3} // attacklab: g_tab_width - 1 + (?: + <([?%]) // $2 + [^\r]*? + \2> + ) + [ \t]* + (?=\n{2,}) // followed by a blank line + ) + /g,hashElement); + */ + text = text.replace(/(?:\n\n)([ ]{0,3}(?:<([?%])[^\r]*?\2>)[ \t]*(?=\n{2,}))/g,hashElement); + + // attacklab: Undo double lines (see comment at top of this function) + text = text.replace(/\n\n/g,"\n"); + return text; +} + +var hashElement = function(wholeMatch,m1) { + var blockText = m1; + + // Undo double lines + blockText = blockText.replace(/\n\n/g,"\n"); + blockText = blockText.replace(/^\n/,""); + + // strip trailing blank lines + blockText = blockText.replace(/\n+$/g,""); + + // Replace the element text with a marker ("~KxK" where x is its key) + blockText = "\n\n~K" + (g_html_blocks.push(blockText)-1) + "K\n\n"; + + return blockText; +}; + +var _RunBlockGamut = function(text) { +// +// These are all the transformations that form block-level +// tags like paragraphs, headers, and list items. +// + text = _DoHeaders(text); + + // Do Horizontal Rules: + var key = hashBlock("
"); + text = text.replace(/^[ ]{0,2}([ ]?\*[ ]?){3,}[ \t]*$/gm,key); + text = text.replace(/^[ ]{0,2}([ ]?\-[ ]?){3,}[ \t]*$/gm,key); + text = text.replace(/^[ ]{0,2}([ ]?\_[ ]?){3,}[ \t]*$/gm,key); + + text = _DoLists(text); + text = _DoCodeBlocks(text); + text = _DoBlockQuotes(text); + + // We already ran _HashHTMLBlocks() before, in Markdown(), but that + // was to escape raw HTML in the original Markdown source. This time, + // we're escaping the markup we've just created, so that we don't wrap + //

tags around block-level tags. + text = _HashHTMLBlocks(text); + text = _FormParagraphs(text); + + return text; +} + + +var _RunSpanGamut = function(text) { +// +// These are all the transformations that occur *within* block-level +// tags like paragraphs, headers, and list items. +// + + text = _DoCodeSpans(text); + text = _EscapeSpecialCharsWithinTagAttributes(text); + text = _EncodeBackslashEscapes(text); + + // Process anchor and image tags. Images must come first, + // because ![foo][f] looks like an anchor. + text = _DoImages(text); + text = _DoAnchors(text); + + // Make links out of things like `` + // Must come after _DoAnchors(), because you can use < and > + // delimiters in inline links like [this](). + text = _DoAutoLinks(text); + text = _EncodeAmpsAndAngles(text); + text = _DoItalicsAndBold(text); + + // Do hard breaks: + text = text.replace(/ +\n/g,"
\n"); + + return text; +} + +var _EscapeSpecialCharsWithinTagAttributes = function(text) { +// +// Within tags -- meaning between < and > -- encode [\ ` * _] so they +// don't conflict with their use in Markdown for code, italics and strong. +// + + // Build a regex to find HTML tags and comments. See Friedl's + // "Mastering Regular Expressions", 2nd Ed., pp. 200-201. + var regex = /(<[a-z\/!$]("[^"]*"|'[^']*'|[^'">])*>|)/gi; + + text = text.replace(regex, function(wholeMatch) { + var tag = wholeMatch.replace(/(.)<\/?code>(?=.)/g,"$1`"); + tag = escapeCharacters(tag,"\\`*_"); + return tag; + }); + + return text; +} + +var _DoAnchors = function(text) { +// +// Turn Markdown link shortcuts into XHTML
tags. +// + // + // First, handle reference-style links: [link text] [id] + // + + /* + text = text.replace(/ + ( // wrap whole match in $1 + \[ + ( + (?: + \[[^\]]*\] // allow brackets nested one level + | + [^\[] // or anything else + )* + ) + \] + + [ ]? // one optional space + (?:\n[ ]*)? // one optional newline followed by spaces + + \[ + (.*?) // id = $3 + \] + )()()()() // pad remaining backreferences + /g,_DoAnchors_callback); + */ + text = text.replace(/(\[((?:\[[^\]]*\]|[^\[\]])*)\][ ]?(?:\n[ ]*)?\[(.*?)\])()()()()/g,writeAnchorTag); + + // + // Next, inline-style links: [link text](url "optional title") + // + + /* + text = text.replace(/ + ( // wrap whole match in $1 + \[ + ( + (?: + \[[^\]]*\] // allow brackets nested one level + | + [^\[\]] // or anything else + ) + ) + \] + \( // literal paren + [ \t]* + () // no id, so leave $3 empty + ? // href = $4 + [ \t]* + ( // $5 + (['"]) // quote char = $6 + (.*?) // Title = $7 + \6 // matching quote + [ \t]* // ignore any spaces/tabs between closing quote and ) + )? // title is optional + \) + ) + /g,writeAnchorTag); + */ + text = text.replace(/(\[((?:\[[^\]]*\]|[^\[\]])*)\]\([ \t]*()?[ \t]*((['"])(.*?)\6[ \t]*)?\))/g,writeAnchorTag); + + // + // Last, handle reference-style shortcuts: [link text] + // These must come last in case you've also got [link test][1] + // or [link test](/foo) + // + + /* + text = text.replace(/ + ( // wrap whole match in $1 + \[ + ([^\[\]]+) // link text = $2; can't contain '[' or ']' + \] + )()()()()() // pad rest of backreferences + /g, writeAnchorTag); + */ + text = text.replace(/(\[([^\[\]]+)\])()()()()()/g, writeAnchorTag); + + return text; +} + +var writeAnchorTag = function(wholeMatch,m1,m2,m3,m4,m5,m6,m7) { + if (m7 == undefined) m7 = ""; + var whole_match = m1; + var link_text = m2; + var link_id = m3.toLowerCase(); + var url = m4; + var title = m7; + + if (url == "") { + if (link_id == "") { + // lower-case and turn embedded newlines into spaces + link_id = link_text.toLowerCase().replace(/ ?\n/g," "); + } + url = "#"+link_id; + + if (g_urls[link_id] != undefined) { + url = g_urls[link_id]; + if (g_titles[link_id] != undefined) { + title = g_titles[link_id]; + } + } + else { + if (whole_match.search(/\(\s*\)$/m)>-1) { + // Special case for explicit empty url + url = ""; + } else { + return whole_match; + } + } + } + + url = escapeCharacters(url,"*_"); + var result = ""; + + return result; +} + + +var _DoImages = function(text) { +// +// Turn Markdown image shortcuts into tags. +// + + // + // First, handle reference-style labeled images: ![alt text][id] + // + + /* + text = text.replace(/ + ( // wrap whole match in $1 + !\[ + (.*?) // alt text = $2 + \] + + [ ]? // one optional space + (?:\n[ ]*)? // one optional newline followed by spaces + + \[ + (.*?) // id = $3 + \] + )()()()() // pad rest of backreferences + /g,writeImageTag); + */ + text = text.replace(/(!\[(.*?)\][ ]?(?:\n[ ]*)?\[(.*?)\])()()()()/g,writeImageTag); + + // + // Next, handle inline images: ![alt text](url "optional title") + // Don't forget: encode * and _ + + /* + text = text.replace(/ + ( // wrap whole match in $1 + !\[ + (.*?) // alt text = $2 + \] + \s? // One optional whitespace character + \( // literal paren + [ \t]* + () // no id, so leave $3 empty + ? // src url = $4 + [ \t]* + ( // $5 + (['"]) // quote char = $6 + (.*?) // title = $7 + \6 // matching quote + [ \t]* + )? // title is optional + \) + ) + /g,writeImageTag); + */ + text = text.replace(/(!\[(.*?)\]\s?\([ \t]*()?[ \t]*((['"])(.*?)\6[ \t]*)?\))/g,writeImageTag); + + return text; +} + +var writeImageTag = function(wholeMatch,m1,m2,m3,m4,m5,m6,m7) { + var whole_match = m1; + var alt_text = m2; + var link_id = m3.toLowerCase(); + var url = m4; + var title = m7; + + if (!title) title = ""; + + if (url == "") { + if (link_id == "") { + // lower-case and turn embedded newlines into spaces + link_id = alt_text.toLowerCase().replace(/ ?\n/g," "); + } + url = "#"+link_id; + + if (g_urls[link_id] != undefined) { + url = g_urls[link_id]; + if (g_titles[link_id] != undefined) { + title = g_titles[link_id]; + } + } + else { + return whole_match; + } + } + + alt_text = alt_text.replace(/"/g,"""); + url = escapeCharacters(url,"*_"); + var result = "\""" + _RunSpanGamut(m1) + "");}); + + text = text.replace(/^(.+)[ \t]*\n-+[ \t]*\n+/gm, + function(matchFound,m1){return hashBlock("

" + _RunSpanGamut(m1) + "

");}); + + // atx-style headers: + // # Header 1 + // ## Header 2 + // ## Header 2 with closing hashes ## + // ... + // ###### Header 6 + // + + /* + text = text.replace(/ + ^(\#{1,6}) // $1 = string of #'s + [ \t]* + (.+?) // $2 = Header text + [ \t]* + \#* // optional closing #'s (not counted) + \n+ + /gm, function() {...}); + */ + + text = text.replace(/^(\#{1,6})[ \t]*(.+?)[ \t]*\#*\n+/gm, + function(wholeMatch,m1,m2) { + var h_level = m1.length; + return hashBlock("" + _RunSpanGamut(m2) + ""); + }); + + return text; +} + +// This declaration keeps Dojo compressor from outputting garbage: +var _ProcessListItems; + +var _DoLists = function(text) { +// +// Form HTML ordered (numbered) and unordered (bulleted) lists. +// + + // attacklab: add sentinel to hack around khtml/safari bug: + // http://bugs.webkit.org/show_bug.cgi?id=11231 + text += "~0"; + + // Re-usable pattern to match any entirel ul or ol list: + + /* + var whole_list = / + ( // $1 = whole list + ( // $2 + [ ]{0,3} // attacklab: g_tab_width - 1 + ([*+-]|\d+[.]) // $3 = first list item marker + [ \t]+ + ) + [^\r]+? + ( // $4 + ~0 // sentinel for workaround; should be $ + | + \n{2,} + (?=\S) + (?! // Negative lookahead for another list item marker + [ \t]* + (?:[*+-]|\d+[.])[ \t]+ + ) + ) + )/g + */ + var whole_list = /^(([ ]{0,3}([*+-]|\d+[.])[ \t]+)[^\r]+?(~0|\n{2,}(?=\S)(?![ \t]*(?:[*+-]|\d+[.])[ \t]+)))/gm; + + if (g_list_level) { + text = text.replace(whole_list,function(wholeMatch,m1,m2) { + var list = m1; + var list_type = (m2.search(/[*+-]/g)>-1) ? "ul" : "ol"; + + // Turn double returns into triple returns, so that we can make a + // paragraph for the last item in a list, if necessary: + list = list.replace(/\n{2,}/g,"\n\n\n");; + var result = _ProcessListItems(list); + + // Trim any trailing whitespace, to put the closing `` + // up on the preceding line, to get it past the current stupid + // HTML block parser. This is a hack to work around the terrible + // hack that is the HTML block parser. + result = result.replace(/\s+$/,""); + result = "<"+list_type+">" + result + "\n"; + return result; + }); + } else { + whole_list = /(\n\n|^\n?)(([ ]{0,3}([*+-]|\d+[.])[ \t]+)[^\r]+?(~0|\n{2,}(?=\S)(?![ \t]*(?:[*+-]|\d+[.])[ \t]+)))/g; + text = text.replace(whole_list,function(wholeMatch,m1,m2,m3) { + var runup = m1; + var list = m2; + + var list_type = (m3.search(/[*+-]/g)>-1) ? "ul" : "ol"; + // Turn double returns into triple returns, so that we can make a + // paragraph for the last item in a list, if necessary: + var list = list.replace(/\n{2,}/g,"\n\n\n");; + var result = _ProcessListItems(list); + result = runup + "<"+list_type+">\n" + result + "\n"; + return result; + }); + } + + // attacklab: strip sentinel + text = text.replace(/~0/,""); + + return text; +} + +_ProcessListItems = function(list_str) { +// +// Process the contents of a single ordered or unordered list, splitting it +// into individual list items. +// + // The $g_list_level global keeps track of when we're inside a list. + // Each time we enter a list, we increment it; when we leave a list, + // we decrement. If it's zero, we're not in a list anymore. + // + // We do this because when we're not inside a list, we want to treat + // something like this: + // + // I recommend upgrading to version + // 8. Oops, now this line is treated + // as a sub-list. + // + // As a single paragraph, despite the fact that the second line starts + // with a digit-period-space sequence. + // + // Whereas when we're inside a list (or sub-list), that line will be + // treated as the start of a sub-list. What a kludge, huh? This is + // an aspect of Markdown's syntax that's hard to parse perfectly + // without resorting to mind-reading. Perhaps the solution is to + // change the syntax rules such that sub-lists must start with a + // starting cardinal number; e.g. "1." or "a.". + + g_list_level++; + + // trim trailing blank lines: + list_str = list_str.replace(/\n{2,}$/,"\n"); + + // attacklab: add sentinel to emulate \z + list_str += "~0"; + + /* + list_str = list_str.replace(/ + (\n)? // leading line = $1 + (^[ \t]*) // leading whitespace = $2 + ([*+-]|\d+[.]) [ \t]+ // list marker = $3 + ([^\r]+? // list item text = $4 + (\n{1,2})) + (?= \n* (~0 | \2 ([*+-]|\d+[.]) [ \t]+)) + /gm, function(){...}); + */ + list_str = list_str.replace(/(\n)?(^[ \t]*)([*+-]|\d+[.])[ \t]+([^\r]+?(\n{1,2}))(?=\n*(~0|\2([*+-]|\d+[.])[ \t]+))/gm, + function(wholeMatch,m1,m2,m3,m4){ + var item = m4; + var leading_line = m1; + var leading_space = m2; + + if (leading_line || (item.search(/\n{2,}/)>-1)) { + item = _RunBlockGamut(_Outdent(item)); + } + else { + // Recursion for sub-lists: + item = _DoLists(_Outdent(item)); + item = item.replace(/\n$/,""); // chomp(item) + item = _RunSpanGamut(item); + } + + return "
  • " + item + "
  • \n"; + } + ); + + // attacklab: strip sentinel + list_str = list_str.replace(/~0/g,""); + + g_list_level--; + return list_str; +} + + +var _DoCodeBlocks = function(text) { +// +// Process Markdown `
    ` blocks.
    +//
    +
    +	/*
    +		text = text.replace(text,
    +			/(?:\n\n|^)
    +			(								// $1 = the code block -- one or more lines, starting with a space/tab
    +				(?:
    +					(?:[ ]{4}|\t)			// Lines must start with a tab or a tab-width of spaces - attacklab: g_tab_width
    +					.*\n+
    +				)+
    +			)
    +			(\n*[ ]{0,3}[^ \t\n]|(?=~0))	// attacklab: g_tab_width
    +		/g,function(){...});
    +	*/
    +
    +	// attacklab: sentinel workarounds for lack of \A and \Z, safari\khtml bug
    +	text += "~0";
    +
    +	text = text.replace(/(?:\n\n|^)((?:(?:[ ]{4}|\t).*\n+)+)(\n*[ ]{0,3}[^ \t\n]|(?=~0))/g,
    +		function(wholeMatch,m1,m2) {
    +			var codeblock = m1;
    +			var nextChar = m2;
    +
    +			codeblock = _EncodeCode( _Outdent(codeblock));
    +			codeblock = _Detab(codeblock);
    +			codeblock = codeblock.replace(/^\n+/g,""); // trim leading newlines
    +			codeblock = codeblock.replace(/\n+$/g,""); // trim trailing whitespace
    +
    +			codeblock = "
    " + codeblock + "\n
    "; + + return hashBlock(codeblock) + nextChar; + } + ); + + // attacklab: strip sentinel + text = text.replace(/~0/,""); + + return text; +} + +var hashBlock = function(text) { + text = text.replace(/(^\n+|\n+$)/g,""); + return "\n\n~K" + (g_html_blocks.push(text)-1) + "K\n\n"; +} + + +var _DoCodeSpans = function(text) { +// +// * Backtick quotes are used for spans. +// +// * You can use multiple backticks as the delimiters if you want to +// include literal backticks in the code span. So, this input: +// +// Just type ``foo `bar` baz`` at the prompt. +// +// Will translate to: +// +//

    Just type foo `bar` baz at the prompt.

    +// +// There's no arbitrary limit to the number of backticks you +// can use as delimters. If you need three consecutive backticks +// in your code, use four for delimiters, etc. +// +// * You can use spaces to get literal backticks at the edges: +// +// ... type `` `bar` `` ... +// +// Turns to: +// +// ... type `bar` ... +// + + /* + text = text.replace(/ + (^|[^\\]) // Character before opening ` can't be a backslash + (`+) // $2 = Opening run of ` + ( // $3 = The code block + [^\r]*? + [^`] // attacklab: work around lack of lookbehind + ) + \2 // Matching closer + (?!`) + /gm, function(){...}); + */ + + text = text.replace(/(^|[^\\])(`+)([^\r]*?[^`])\2(?!`)/gm, + function(wholeMatch,m1,m2,m3,m4) { + var c = m3; + c = c.replace(/^([ \t]*)/g,""); // leading whitespace + c = c.replace(/[ \t]*$/g,""); // trailing whitespace + c = _EncodeCode(c); + return m1+""+c+""; + }); + + return text; +} + + +var _EncodeCode = function(text) { +// +// Encode/escape certain characters inside Markdown code runs. +// The point is that in code, these characters are literals, +// and lose their special Markdown meanings. +// + // Encode all ampersands; HTML entities are not + // entities within a Markdown code span. + text = text.replace(/&/g,"&"); + + // Do the angle bracket song and dance: + text = text.replace(//g,">"); + + // Now, escape characters that are magic in Markdown: + text = escapeCharacters(text,"\*_{}[]\\",false); + +// jj the line above breaks this: +//--- + +//* Item + +// 1. Subitem + +// special char: * +//--- + + return text; +} + + +var _DoItalicsAndBold = function(text) { + + // must go first: + text = text.replace(/(\*\*|__)(?=\S)([^\r]*?\S[*_]*)\1/g, + "$2"); + + text = text.replace(/(\*|_)(?=\S)([^\r]*?\S)\1/g, + "$2"); + + return text; +} + + +var _DoBlockQuotes = function(text) { + + /* + text = text.replace(/ + ( // Wrap whole match in $1 + ( + ^[ \t]*>[ \t]? // '>' at the start of a line + .+\n // rest of the first line + (.+\n)* // subsequent consecutive lines + \n* // blanks + )+ + ) + /gm, function(){...}); + */ + + text = text.replace(/((^[ \t]*>[ \t]?.+\n(.+\n)*\n*)+)/gm, + function(wholeMatch,m1) { + var bq = m1; + + // attacklab: hack around Konqueror 3.5.4 bug: + // "----------bug".replace(/^-/g,"") == "bug" + + bq = bq.replace(/^[ \t]*>[ \t]?/gm,"~0"); // trim one level of quoting + + // attacklab: clean up hack + bq = bq.replace(/~0/g,""); + + bq = bq.replace(/^[ \t]+$/gm,""); // trim whitespace-only lines + bq = _RunBlockGamut(bq); // recurse + + bq = bq.replace(/(^|\n)/g,"$1 "); + // These leading spaces screw with
     content, so we need to fix that:
    +			bq = bq.replace(
    +					/(\s*
    [^\r]+?<\/pre>)/gm,
    +				function(wholeMatch,m1) {
    +					var pre = m1;
    +					// attacklab: hack around Konqueror 3.5.4 bug:
    +					pre = pre.replace(/^  /mg,"~0");
    +					pre = pre.replace(/~0/g,"");
    +					return pre;
    +				});
    +
    +			return hashBlock("
    \n" + bq + "\n
    "); + }); + return text; +} + + +var _FormParagraphs = function(text) { +// +// Params: +// $text - string to process with html

    tags +// + + // Strip leading and trailing lines: + text = text.replace(/^\n+/g,""); + text = text.replace(/\n+$/g,""); + + var grafs = text.split(/\n{2,}/g); + var grafsOut = new Array(); + + // + // Wrap

    tags. + // + var end = grafs.length; + for (var i=0; i= 0) { + grafsOut.push(str); + } + else if (str.search(/\S/) >= 0) { + str = _RunSpanGamut(str); + str = str.replace(/^([ \t]*)/g,"

    "); + str += "

    " + grafsOut.push(str); + } + + } + + // + // Unhashify HTML blocks + // + end = grafsOut.length; + for (var i=0; i= 0) { + var blockText = g_html_blocks[RegExp.$1]; + blockText = blockText.replace(/\$/g,"$$$$"); // Escape any dollar signs + grafsOut[i] = grafsOut[i].replace(/~K\d+K/,blockText); + } + } + + return grafsOut.join("\n\n"); +} + + +var _EncodeAmpsAndAngles = function(text) { +// Smart processing for ampersands and angle brackets that need to be encoded. + + // Ampersand-encoding based entirely on Nat Irons's Amputator MT plugin: + // http://bumppo.net/projects/amputator/ + text = text.replace(/&(?!#?[xX]?(?:[0-9a-fA-F]+|\w+);)/g,"&"); + + // Encode naked <'s + text = text.replace(/<(?![a-z\/?\$!])/gi,"<"); + + return text; +} + + +var _EncodeBackslashEscapes = function(text) { +// +// Parameter: String. +// Returns: The string, with after processing the following backslash +// escape sequences. +// + + // attacklab: The polite way to do this is with the new + // escapeCharacters() function: + // + // text = escapeCharacters(text,"\\",true); + // text = escapeCharacters(text,"`*_{}[]()>#+-.!",true); + // + // ...but we're sidestepping its use of the (slow) RegExp constructor + // as an optimization for Firefox. This function gets called a LOT. + + text = text.replace(/\\(\\)/g,escapeCharacters_callback); + text = text.replace(/\\([`*_{}\[\]()>#+-.!])/g,escapeCharacters_callback); + return text; +} + + +var _DoAutoLinks = function(text) { + + text = text.replace(/<((https?|ftp|dict):[^'">\s]+)>/gi,"
    $1"); + + // Email addresses: + + /* + text = text.replace(/ + < + (?:mailto:)? + ( + [-.\w]+ + \@ + [-a-z0-9]+(\.[-a-z0-9]+)*\.[a-z]+ + ) + > + /gi, _DoAutoLinks_callback()); + */ + text = text.replace(/<(?:mailto:)?([-.\w]+\@[-a-z0-9]+(\.[-a-z0-9]+)*\.[a-z]+)>/gi, + function(wholeMatch,m1) { + return _EncodeEmailAddress( _UnescapeSpecialChars(m1) ); + } + ); + + return text; +} + + +var _EncodeEmailAddress = function(addr) { +// +// Input: an email address, e.g. "foo@example.com" +// +// Output: the email address as a mailto link, with each character +// of the address encoded as either a decimal or hex entity, in +// the hopes of foiling most address harvesting spam bots. E.g.: +// +// foo +// @example.com +// +// Based on a filter by Matthew Wickline, posted to the BBEdit-Talk +// mailing list: +// + + // attacklab: why can't javascript speak hex? + function char2hex(ch) { + var hexDigits = '0123456789ABCDEF'; + var dec = ch.charCodeAt(0); + return(hexDigits.charAt(dec>>4) + hexDigits.charAt(dec&15)); + } + + var encode = [ + function(ch){return "&#"+ch.charCodeAt(0)+";";}, + function(ch){return "&#x"+char2hex(ch)+";";}, + function(ch){return ch;} + ]; + + addr = "mailto:" + addr; + + addr = addr.replace(/./g, function(ch) { + if (ch == "@") { + // this *must* be encoded. I insist. + ch = encode[Math.floor(Math.random()*2)](ch); + } else if (ch !=":") { + // leave ':' alone (to spot mailto: later) + var r = Math.random(); + // roughly 10% raw, 45% hex, 45% dec + ch = ( + r > .9 ? encode[2](ch) : + r > .45 ? encode[1](ch) : + encode[0](ch) + ); + } + return ch; + }); + + addr = "" + addr + ""; + addr = addr.replace(/">.+:/g,"\">"); // strip the mailto: from the visible part + + return addr; +} + + +var _UnescapeSpecialChars = function(text) { +// +// Swap back in all the special characters we've hidden. +// + text = text.replace(/~E(\d+)E/g, + function(wholeMatch,m1) { + var charCodeToReplace = parseInt(m1); + return String.fromCharCode(charCodeToReplace); + } + ); + return text; +} + + +var _Outdent = function(text) { +// +// Remove one level of line-leading tabs or spaces +// + + // attacklab: hack around Konqueror 3.5.4 bug: + // "----------bug".replace(/^-/g,"") == "bug" + + text = text.replace(/^(\t|[ ]{1,4})/gm,"~0"); // attacklab: g_tab_width + + // attacklab: clean up hack + text = text.replace(/~0/g,"") + + return text; +} + +var _Detab = function(text) { +// attacklab: Detab's completely rewritten for speed. +// In perl we could fix it by anchoring the regexp with \G. +// In javascript we're less fortunate. + + // expand first n-1 tabs + text = text.replace(/\t(?=\t)/g," "); // attacklab: g_tab_width + + // replace the nth with two sentinels + text = text.replace(/\t/g,"~A~B"); + + // use the sentinel to anchor our regex so it doesn't explode + text = text.replace(/~B(.+?)~A/g, + function(wholeMatch,m1,m2) { + var leadingText = m1; + var numSpaces = 4 - leadingText.length % 4; // attacklab: g_tab_width + + // there *must* be a better way to do this: + for (var i=0; i `app.mountpath` when mounting an express app in another express app + - `json spaces` no longer enabled by default in development + - `req.accepts*` -> `req.accepts*s` - i.e. `req.acceptsEncoding` -> `req.acceptsEncodings` + - `req.params` is now an object instead of an array + - `res.locals` is no longer a function. It is a plain js object. Treat it as such. + - `res.headerSent` -> `res.headersSent` to match node.js ServerResponse object + * refactor: + - `req.accepts*` with [accepts](https://github.com/expressjs/accepts) + - `req.is` with [type-is](https://github.com/expressjs/type-is) + - [path-to-regexp](https://github.com/component/path-to-regexp) + * add: + - `app.router()` - returns the app Router instance + - `app.route()` - Proxy to the app's `Router#route()` method to create a new route + - Router & Route - public API + +3.17.3 / 2014-09-18 +=================== + + * deps: proxy-addr@~1.0.2 + - Fix a global leak when multiple subnets are trusted + - deps: ipaddr.js@0.1.3 + +3.17.2 / 2014-09-15 +=================== + + * Use `crc` instead of `buffer-crc32` for speed + * deps: connect@2.26.1 + - deps: body-parser@~1.8.2 + - deps: depd@0.4.5 + - deps: express-session@~1.8.2 + - deps: morgan@~1.3.1 + - deps: serve-favicon@~2.1.3 + - deps: serve-static@~1.6.2 + * deps: depd@0.4.5 + * deps: send@0.9.2 + - deps: depd@0.4.5 + - deps: etag@~1.3.1 + - deps: range-parser@~1.0.2 + +3.17.1 / 2014-09-08 +=================== + + * Fix error in `req.subdomains` on empty host + +3.17.0 / 2014-09-08 +=================== + + * Support `X-Forwarded-Host` in `req.subdomains` + * Support IP address host in `req.subdomains` + * deps: connect@2.26.0 + - deps: body-parser@~1.8.1 + - deps: compression@~1.1.0 + - deps: connect-timeout@~1.3.0 + - deps: cookie-parser@~1.3.3 + - deps: cookie-signature@1.0.5 + - deps: csurf@~1.6.1 + - deps: debug@~2.0.0 + - deps: errorhandler@~1.2.0 + - deps: express-session@~1.8.1 + - deps: finalhandler@0.2.0 + - deps: fresh@0.2.4 + - deps: media-typer@0.3.0 + - deps: method-override@~2.2.0 + - deps: morgan@~1.3.0 + - deps: qs@2.2.3 + - deps: serve-favicon@~2.1.3 + - deps: serve-index@~1.2.1 + - deps: serve-static@~1.6.1 + - deps: type-is@~1.5.1 + - deps: vhost@~3.0.0 + * deps: cookie-signature@1.0.5 + * deps: debug@~2.0.0 + * deps: fresh@0.2.4 + * deps: media-typer@0.3.0 + - Throw error when parameter format invalid on parse + * deps: range-parser@~1.0.2 + * deps: send@0.9.1 + - Add `lastModified` option + - Use `etag` to generate `ETag` header + - deps: debug@~2.0.0 + - deps: fresh@0.2.4 + * deps: vary@~1.0.0 + - Accept valid `Vary` header string as `field` + +3.16.10 / 2014-09-04 +==================== + + * deps: connect@2.25.10 + - deps: serve-static@~1.5.4 + * deps: send@0.8.5 + - Fix a path traversal issue when using `root` + - Fix malicious path detection for empty string path + +3.16.9 / 2014-08-29 +=================== + + * deps: connect@2.25.9 + - deps: body-parser@~1.6.7 + - deps: qs@2.2.2 + +3.16.8 / 2014-08-27 +=================== + + * deps: connect@2.25.8 + - deps: body-parser@~1.6.6 + - deps: csurf@~1.4.1 + - deps: qs@2.2.0 + +3.16.7 / 2014-08-18 +=================== + + * deps: connect@2.25.7 + - deps: body-parser@~1.6.5 + - deps: express-session@~1.7.6 + - deps: morgan@~1.2.3 + - deps: serve-static@~1.5.3 + * deps: send@0.8.3 + - deps: destroy@1.0.3 + - deps: on-finished@2.1.0 + +3.16.6 / 2014-08-14 +=================== + + * deps: connect@2.25.6 + - deps: body-parser@~1.6.4 + - deps: qs@1.2.2 + - deps: serve-static@~1.5.2 + * deps: send@0.8.2 + - Work around `fd` leak in Node.js 0.10 for `fs.ReadStream` + +3.16.5 / 2014-08-11 +=================== + + * deps: connect@2.25.5 + - Fix backwards compatibility in `logger` + +3.16.4 / 2014-08-10 +=================== + + * Fix original URL parsing in `res.location` + * deps: connect@2.25.4 + - Fix `query` middleware breaking with argument + - deps: body-parser@~1.6.3 + - deps: compression@~1.0.11 + - deps: connect-timeout@~1.2.2 + - deps: express-session@~1.7.5 + - deps: method-override@~2.1.3 + - deps: on-headers@~1.0.0 + - deps: parseurl@~1.3.0 + - deps: qs@1.2.1 + - deps: response-time@~2.0.1 + - deps: serve-index@~1.1.6 + - deps: serve-static@~1.5.1 + * deps: parseurl@~1.3.0 + +3.16.3 / 2014-08-07 +=================== + + * deps: connect@2.25.3 + - deps: multiparty@3.3.2 + +3.16.2 / 2014-08-07 +=================== + + * deps: connect@2.25.2 + - deps: body-parser@~1.6.2 + - deps: qs@1.2.0 + +3.16.1 / 2014-08-06 +=================== + + * deps: connect@2.25.1 + - deps: body-parser@~1.6.1 + - deps: qs@1.1.0 + +3.16.0 / 2014-08-05 +=================== + + * deps: connect@2.25.0 + - deps: body-parser@~1.6.0 + - deps: compression@~1.0.10 + - deps: csurf@~1.4.0 + - deps: express-session@~1.7.4 + - deps: qs@1.0.2 + - deps: serve-static@~1.5.0 + * deps: send@0.8.1 + - Add `extensions` option + +3.15.3 / 2014-08-04 +=================== + + * fix `res.sendfile` regression for serving directory index files + * deps: connect@2.24.3 + - deps: serve-index@~1.1.5 + - deps: serve-static@~1.4.4 + * deps: send@0.7.4 + - Fix incorrect 403 on Windows and Node.js 0.11 + - Fix serving index files without root dir + +3.15.2 / 2014-07-27 +=================== + + * deps: connect@2.24.2 + - deps: body-parser@~1.5.2 + - deps: depd@0.4.4 + - deps: express-session@~1.7.2 + - deps: morgan@~1.2.2 + - deps: serve-static@~1.4.2 + * deps: depd@0.4.4 + - Work-around v8 generating empty stack traces + * deps: send@0.7.2 + - deps: depd@0.4.4 + +3.15.1 / 2014-07-26 +=================== + + * deps: connect@2.24.1 + - deps: body-parser@~1.5.1 + - deps: depd@0.4.3 + - deps: express-session@~1.7.1 + - deps: morgan@~1.2.1 + - deps: serve-index@~1.1.4 + - deps: serve-static@~1.4.1 + * deps: depd@0.4.3 + - Fix exception when global `Error.stackTraceLimit` is too low + * deps: send@0.7.1 + - deps: depd@0.4.3 + +3.15.0 / 2014-07-22 +=================== + + * Fix `req.protocol` for proxy-direct connections + * Pass options from `res.sendfile` to `send` + * deps: connect@2.24.0 + - deps: body-parser@~1.5.0 + - deps: compression@~1.0.9 + - deps: connect-timeout@~1.2.1 + - deps: debug@1.0.4 + - deps: depd@0.4.2 + - deps: express-session@~1.7.0 + - deps: finalhandler@0.1.0 + - deps: method-override@~2.1.2 + - deps: morgan@~1.2.0 + - deps: multiparty@3.3.1 + - deps: parseurl@~1.2.0 + - deps: serve-static@~1.4.0 + * deps: debug@1.0.4 + * deps: depd@0.4.2 + - Add `TRACE_DEPRECATION` environment variable + - Remove non-standard grey color from color output + - Support `--no-deprecation` argument + - Support `--trace-deprecation` argument + * deps: parseurl@~1.2.0 + - Cache URLs based on original value + - Remove no-longer-needed URL mis-parse work-around + - Simplify the "fast-path" `RegExp` + * deps: send@0.7.0 + - Add `dotfiles` option + - Cap `maxAge` value to 1 year + - deps: debug@1.0.4 + - deps: depd@0.4.2 + +3.14.0 / 2014-07-11 +=================== + + * add explicit "Rosetta Flash JSONP abuse" protection + - previous versions are not vulnerable; this is just explicit protection + * deprecate `res.redirect(url, status)` -- use `res.redirect(status, url)` instead + * fix `res.send(status, num)` to send `num` as json (not error) + * remove unnecessary escaping when `res.jsonp` returns JSON response + * deps: basic-auth@1.0.0 + - support empty password + - support empty username + * deps: connect@2.23.0 + - deps: debug@1.0.3 + - deps: express-session@~1.6.4 + - deps: method-override@~2.1.0 + - deps: parseurl@~1.1.3 + - deps: serve-static@~1.3.1 + * deps: debug@1.0.3 + - Add support for multiple wildcards in namespaces + * deps: methods@1.1.0 + - add `CONNECT` + * deps: parseurl@~1.1.3 + - faster parsing of href-only URLs + +3.13.0 / 2014-07-03 +=================== + + * add deprecation message to `app.configure` + * add deprecation message to `req.auth` + * use `basic-auth` to parse `Authorization` header + * deps: connect@2.22.0 + - deps: csurf@~1.3.0 + - deps: express-session@~1.6.1 + - deps: multiparty@3.3.0 + - deps: serve-static@~1.3.0 + * deps: send@0.5.0 + - Accept string for `maxage` (converted by `ms`) + - Include link in default redirect response + +3.12.1 / 2014-06-26 +=================== + + * deps: connect@2.21.1 + - deps: cookie-parser@1.3.2 + - deps: cookie-signature@1.0.4 + - deps: express-session@~1.5.2 + - deps: type-is@~1.3.2 + * deps: cookie-signature@1.0.4 + - fix for timing attacks + +3.12.0 / 2014-06-21 +=================== + + * use `media-typer` to alter content-type charset + * deps: connect@2.21.0 + - deprecate `connect(middleware)` -- use `app.use(middleware)` instead + - deprecate `connect.createServer()` -- use `connect()` instead + - fix `res.setHeader()` patch to work with with get -> append -> set pattern + - deps: compression@~1.0.8 + - deps: errorhandler@~1.1.1 + - deps: express-session@~1.5.0 + - deps: serve-index@~1.1.3 + +3.11.0 / 2014-06-19 +=================== + + * deprecate things with `depd` module + * deps: buffer-crc32@0.2.3 + * deps: connect@2.20.2 + - deprecate `verify` option to `json` -- use `body-parser` npm module instead + - deprecate `verify` option to `urlencoded` -- use `body-parser` npm module instead + - deprecate things with `depd` module + - use `finalhandler` for final response handling + - use `media-typer` to parse `content-type` for charset + - deps: body-parser@1.4.3 + - deps: connect-timeout@1.1.1 + - deps: cookie-parser@1.3.1 + - deps: csurf@1.2.2 + - deps: errorhandler@1.1.0 + - deps: express-session@1.4.0 + - deps: multiparty@3.2.9 + - deps: serve-index@1.1.2 + - deps: type-is@1.3.1 + - deps: vhost@2.0.0 + +3.10.5 / 2014-06-11 +=================== + + * deps: connect@2.19.6 + - deps: body-parser@1.3.1 + - deps: compression@1.0.7 + - deps: debug@1.0.2 + - deps: serve-index@1.1.1 + - deps: serve-static@1.2.3 + * deps: debug@1.0.2 + * deps: send@0.4.3 + - Do not throw un-catchable error on file open race condition + - Use `escape-html` for HTML escaping + - deps: debug@1.0.2 + - deps: finished@1.2.2 + - deps: fresh@0.2.2 + +3.10.4 / 2014-06-09 +=================== + + * deps: connect@2.19.5 + - fix "event emitter leak" warnings + - deps: csurf@1.2.1 + - deps: debug@1.0.1 + - deps: serve-static@1.2.2 + - deps: type-is@1.2.1 + * deps: debug@1.0.1 + * deps: send@0.4.2 + - fix "event emitter leak" warnings + - deps: finished@1.2.1 + - deps: debug@1.0.1 + +3.10.3 / 2014-06-05 +=================== + + * use `vary` module for `res.vary` + * deps: connect@2.19.4 + - deps: errorhandler@1.0.2 + - deps: method-override@2.0.2 + - deps: serve-favicon@2.0.1 + * deps: debug@1.0.0 + +3.10.2 / 2014-06-03 +=================== + + * deps: connect@2.19.3 + - deps: compression@1.0.6 + +3.10.1 / 2014-06-03 +=================== + + * deps: connect@2.19.2 + - deps: compression@1.0.4 + * deps: proxy-addr@1.0.1 + +3.10.0 / 2014-06-02 +=================== + + * deps: connect@2.19.1 + - deprecate `methodOverride()` -- use `method-override` npm module instead + - deps: body-parser@1.3.0 + - deps: method-override@2.0.1 + - deps: multiparty@3.2.8 + - deps: response-time@2.0.0 + - deps: serve-static@1.2.1 + * deps: methods@1.0.1 + * deps: send@0.4.1 + - Send `max-age` in `Cache-Control` in correct format + +3.9.0 / 2014-05-30 +================== + + * custom etag control with `app.set('etag', val)` + - `app.set('etag', function(body, encoding){ return '"etag"' })` custom etag generation + - `app.set('etag', 'weak')` weak tag + - `app.set('etag', 'strong')` strong etag + - `app.set('etag', false)` turn off + - `app.set('etag', true)` standard etag + * Include ETag in HEAD requests + * mark `res.send` ETag as weak and reduce collisions + * update connect to 2.18.0 + - deps: compression@1.0.3 + - deps: serve-index@1.1.0 + - deps: serve-static@1.2.0 + * update send to 0.4.0 + - Calculate ETag with md5 for reduced collisions + - Ignore stream errors after request ends + - deps: debug@0.8.1 + +3.8.1 / 2014-05-27 +================== + + * update connect to 2.17.3 + - deps: body-parser@1.2.2 + - deps: express-session@1.2.1 + - deps: method-override@1.0.2 + +3.8.0 / 2014-05-21 +================== + + * keep previous `Content-Type` for `res.jsonp` + * set proper `charset` in `Content-Type` for `res.send` + * update connect to 2.17.1 + - fix `res.charset` appending charset when `content-type` has one + - deps: express-session@1.2.0 + - deps: morgan@1.1.1 + - deps: serve-index@1.0.3 + +3.7.0 / 2014-05-18 +================== + + * proper proxy trust with `app.set('trust proxy', trust)` + - `app.set('trust proxy', 1)` trust first hop + - `app.set('trust proxy', 'loopback')` trust loopback addresses + - `app.set('trust proxy', '10.0.0.1')` trust single IP + - `app.set('trust proxy', '10.0.0.1/16')` trust subnet + - `app.set('trust proxy', '10.0.0.1, 10.0.0.2')` trust list + - `app.set('trust proxy', false)` turn off + - `app.set('trust proxy', true)` trust everything + * update connect to 2.16.2 + - deprecate `res.headerSent` -- use `res.headersSent` + - deprecate `res.on("header")` -- use on-headers module instead + - fix edge-case in `res.appendHeader` that would append in wrong order + - json: use body-parser + - urlencoded: use body-parser + - dep: bytes@1.0.0 + - dep: cookie-parser@1.1.0 + - dep: csurf@1.2.0 + - dep: express-session@1.1.0 + - dep: method-override@1.0.1 + +3.6.0 / 2014-05-09 +================== + + * deprecate `app.del()` -- use `app.delete()` instead + * deprecate `res.json(obj, status)` -- use `res.json(status, obj)` instead + - the edge-case `res.json(status, num)` requires `res.status(status).json(num)` + * deprecate `res.jsonp(obj, status)` -- use `res.jsonp(status, obj)` instead + - the edge-case `res.jsonp(status, num)` requires `res.status(status).jsonp(num)` + * support PURGE method + - add `app.purge` + - add `router.purge` + - include PURGE in `app.all` + * update connect to 2.15.0 + * Add `res.appendHeader` + * Call error stack even when response has been sent + * Patch `res.headerSent` to return Boolean + * Patch `res.headersSent` for node.js 0.8 + * Prevent default 404 handler after response sent + * dep: compression@1.0.2 + * dep: connect-timeout@1.1.0 + * dep: debug@^0.8.0 + * dep: errorhandler@1.0.1 + * dep: express-session@1.0.4 + * dep: morgan@1.0.1 + * dep: serve-favicon@2.0.0 + * dep: serve-index@1.0.2 + * update debug to 0.8.0 + * add `enable()` method + * change from stderr to stdout + * update methods to 1.0.0 + - add PURGE + * update mkdirp to 0.5.0 + +3.5.3 / 2014-05-08 +================== + + * fix `req.host` for IPv6 literals + * fix `res.jsonp` error if callback param is object + +3.5.2 / 2014-04-24 +================== + + * update connect to 2.14.5 + * update cookie to 0.1.2 + * update mkdirp to 0.4.0 + * update send to 0.3.0 + +3.5.1 / 2014-03-25 +================== + + * pin less-middleware in generated app + +3.5.0 / 2014-03-06 +================== + + * bump deps + +3.4.8 / 2014-01-13 +================== + + * prevent incorrect automatic OPTIONS responses #1868 @dpatti + * update binary and examples for jade 1.0 #1876 @yossi, #1877 @reqshark, #1892 @matheusazzi + * throw 400 in case of malformed paths @rlidwka + +3.4.7 / 2013-12-10 +================== + + * update connect + +3.4.6 / 2013-12-01 +================== + + * update connect (raw-body) + +3.4.5 / 2013-11-27 +================== + + * update connect + * res.location: remove leading ./ #1802 @kapouer + * res.redirect: fix `res.redirect('toString') #1829 @michaelficarra + * res.send: always send ETag when content-length > 0 + * router: add Router.all() method + +3.4.4 / 2013-10-29 +================== + + * update connect + * update supertest + * update methods + * express(1): replace bodyParser() with urlencoded() and json() #1795 @chirag04 + +3.4.3 / 2013-10-23 +================== + + * update connect + +3.4.2 / 2013-10-18 +================== + + * update connect + * downgrade commander + +3.4.1 / 2013-10-15 +================== + + * update connect + * update commander + * jsonp: check if callback is a function + * router: wrap encodeURIComponent in a try/catch #1735 (@lxe) + * res.format: now includes chraset @1747 (@sorribas) + * res.links: allow multiple calls @1746 (@sorribas) + +3.4.0 / 2013-09-07 +================== + + * add res.vary(). Closes #1682 + * update connect + +3.3.8 / 2013-09-02 +================== + + * update connect + +3.3.7 / 2013-08-28 +================== + + * update connect + +3.3.6 / 2013-08-27 +================== + + * Revert "remove charset from json responses. Closes #1631" (causes issues in some clients) + * add: req.accepts take an argument list + +3.3.4 / 2013-07-08 +================== + + * update send and connect + +3.3.3 / 2013-07-04 +================== + + * update connect + +3.3.2 / 2013-07-03 +================== + + * update connect + * update send + * remove .version export + +3.3.1 / 2013-06-27 +================== + + * update connect + +3.3.0 / 2013-06-26 +================== + + * update connect + * add support for multiple X-Forwarded-Proto values. Closes #1646 + * change: remove charset from json responses. Closes #1631 + * change: return actual booleans from req.accept* functions + * fix jsonp callback array throw + +3.2.6 / 2013-06-02 +================== + + * update connect + +3.2.5 / 2013-05-21 +================== + + * update connect + * update node-cookie + * add: throw a meaningful error when there is no default engine + * change generation of ETags with res.send() to GET requests only. Closes #1619 + +3.2.4 / 2013-05-09 +================== + + * fix `req.subdomains` when no Host is present + * fix `req.host` when no Host is present, return undefined + +3.2.3 / 2013-05-07 +================== + + * update connect / qs + +3.2.2 / 2013-05-03 +================== + + * update qs + +3.2.1 / 2013-04-29 +================== + + * add app.VERB() paths array deprecation warning + * update connect + * update qs and remove all ~ semver crap + * fix: accept number as value of Signed Cookie + +3.2.0 / 2013-04-15 +================== + + * add "view" constructor setting to override view behaviour + * add req.acceptsEncoding(name) + * add req.acceptedEncodings + * revert cookie signature change causing session race conditions + * fix sorting of Accept values of the same quality + +3.1.2 / 2013-04-12 +================== + + * add support for custom Accept parameters + * update cookie-signature + +3.1.1 / 2013-04-01 +================== + + * add X-Forwarded-Host support to `req.host` + * fix relative redirects + * update mkdirp + * update buffer-crc32 + * remove legacy app.configure() method from app template. + +3.1.0 / 2013-01-25 +================== + + * add support for leading "." in "view engine" setting + * add array support to `res.set()` + * add node 0.8.x to travis.yml + * add "subdomain offset" setting for tweaking `req.subdomains` + * add `res.location(url)` implementing `res.redirect()`-like setting of Location + * use app.get() for x-powered-by setting for inheritance + * fix colons in passwords for `req.auth` + +3.0.6 / 2013-01-04 +================== + + * add http verb methods to Router + * update connect + * fix mangling of the `res.cookie()` options object + * fix jsonp whitespace escape. Closes #1132 + +3.0.5 / 2012-12-19 +================== + + * add throwing when a non-function is passed to a route + * fix: explicitly remove Transfer-Encoding header from 204 and 304 responses + * revert "add 'etag' option" + +3.0.4 / 2012-12-05 +================== + + * add 'etag' option to disable `res.send()` Etags + * add escaping of urls in text/plain in `res.redirect()` + for old browsers interpreting as html + * change crc32 module for a more liberal license + * update connect + +3.0.3 / 2012-11-13 +================== + + * update connect + * update cookie module + * fix cookie max-age + +3.0.2 / 2012-11-08 +================== + + * add OPTIONS to cors example. Closes #1398 + * fix route chaining regression. Closes #1397 + +3.0.1 / 2012-11-01 +================== + + * update connect + +3.0.0 / 2012-10-23 +================== + + * add `make clean` + * add "Basic" check to req.auth + * add `req.auth` test coverage + * add cb && cb(payload) to `res.jsonp()`. Closes #1374 + * add backwards compat for `res.redirect()` status. Closes #1336 + * add support for `res.json()` to retain previously defined Content-Types. Closes #1349 + * update connect + * change `res.redirect()` to utilize a pathname-relative Location again. Closes #1382 + * remove non-primitive string support for `res.send()` + * fix view-locals example. Closes #1370 + * fix route-separation example + +3.0.0rc5 / 2012-09-18 +================== + + * update connect + * add redis search example + * add static-files example + * add "x-powered-by" setting (`app.disable('x-powered-by')`) + * add "application/octet-stream" redirect Accept test case. Closes #1317 + +3.0.0rc4 / 2012-08-30 +================== + + * add `res.jsonp()`. Closes #1307 + * add "verbose errors" option to error-pages example + * add another route example to express(1) so people are not so confused + * add redis online user activity tracking example + * update connect dep + * fix etag quoting. Closes #1310 + * fix error-pages 404 status + * fix jsonp callback char restrictions + * remove old OPTIONS default response + +3.0.0rc3 / 2012-08-13 +================== + + * update connect dep + * fix signed cookies to work with `connect.cookieParser()` ("s:" prefix was missing) [tnydwrds] + * fix `res.render()` clobbering of "locals" + +3.0.0rc2 / 2012-08-03 +================== + + * add CORS example + * update connect dep + * deprecate `.createServer()` & remove old stale examples + * fix: escape `res.redirect()` link + * fix vhost example + +3.0.0rc1 / 2012-07-24 +================== + + * add more examples to view-locals + * add scheme-relative redirects (`res.redirect("//foo.com")`) support + * update cookie dep + * update connect dep + * update send dep + * fix `express(1)` -h flag, use -H for hogan. Closes #1245 + * fix `res.sendfile()` socket error handling regression + +3.0.0beta7 / 2012-07-16 +================== + + * update connect dep for `send()` root normalization regression + +3.0.0beta6 / 2012-07-13 +================== + + * add `err.view` property for view errors. Closes #1226 + * add "jsonp callback name" setting + * add support for "/foo/:bar*" non-greedy matches + * change `res.sendfile()` to use `send()` module + * change `res.send` to use "response-send" module + * remove `app.locals.use` and `res.locals.use`, use regular middleware + +3.0.0beta5 / 2012-07-03 +================== + + * add "make check" support + * add route-map example + * add `res.json(obj, status)` support back for BC + * add "methods" dep, remove internal methods module + * update connect dep + * update auth example to utilize cores pbkdf2 + * updated tests to use "supertest" + +3.0.0beta4 / 2012-06-25 +================== + + * Added `req.auth` + * Added `req.range(size)` + * Added `res.links(obj)` + * Added `res.send(body, status)` support back for backwards compat + * Added `.default()` support to `res.format()` + * Added 2xx / 304 check to `req.fresh` + * Revert "Added + support to the router" + * Fixed `res.send()` freshness check, respect res.statusCode + +3.0.0beta3 / 2012-06-15 +================== + + * Added hogan `--hjs` to express(1) [nullfirm] + * Added another example to content-negotiation + * Added `fresh` dep + * Changed: `res.send()` always checks freshness + * Fixed: expose connects mime module. Cloases #1165 + +3.0.0beta2 / 2012-06-06 +================== + + * Added `+` support to the router + * Added `req.host` + * Changed `req.param()` to check route first + * Update connect dep + +3.0.0beta1 / 2012-06-01 +================== + + * Added `res.format()` callback to override default 406 behaviour + * Fixed `res.redirect()` 406. Closes #1154 + +3.0.0alpha5 / 2012-05-30 +================== + + * Added `req.ip` + * Added `{ signed: true }` option to `res.cookie()` + * Removed `res.signedCookie()` + * Changed: dont reverse `req.ips` + * Fixed "trust proxy" setting check for `req.ips` + +3.0.0alpha4 / 2012-05-09 +================== + + * Added: allow `[]` in jsonp callback. Closes #1128 + * Added `PORT` env var support in generated template. Closes #1118 [benatkin] + * Updated: connect 2.2.2 + +3.0.0alpha3 / 2012-05-04 +================== + + * Added public `app.routes`. Closes #887 + * Added _view-locals_ example + * Added _mvc_ example + * Added `res.locals.use()`. Closes #1120 + * Added conditional-GET support to `res.send()` + * Added: coerce `res.set()` values to strings + * Changed: moved `static()` in generated apps below router + * Changed: `res.send()` only set ETag when not previously set + * Changed connect 2.2.1 dep + * Changed: `make test` now runs unit / acceptance tests + * Fixed req/res proto inheritance + +3.0.0alpha2 / 2012-04-26 +================== + + * Added `make benchmark` back + * Added `res.send()` support for `String` objects + * Added client-side data exposing example + * Added `res.header()` and `req.header()` aliases for BC + * Added `express.createServer()` for BC + * Perf: memoize parsed urls + * Perf: connect 2.2.0 dep + * Changed: make `expressInit()` middleware self-aware + * Fixed: use app.get() for all core settings + * Fixed redis session example + * Fixed session example. Closes #1105 + * Fixed generated express dep. Closes #1078 + +3.0.0alpha1 / 2012-04-15 +================== + + * Added `app.locals.use(callback)` + * Added `app.locals` object + * Added `app.locals(obj)` + * Added `res.locals` object + * Added `res.locals(obj)` + * Added `res.format()` for content-negotiation + * Added `app.engine()` + * Added `res.cookie()` JSON cookie support + * Added "trust proxy" setting + * Added `req.subdomains` + * Added `req.protocol` + * Added `req.secure` + * Added `req.path` + * Added `req.ips` + * Added `req.fresh` + * Added `req.stale` + * Added comma-delmited / array support for `req.accepts()` + * Added debug instrumentation + * Added `res.set(obj)` + * Added `res.set(field, value)` + * Added `res.get(field)` + * Added `app.get(setting)`. Closes #842 + * Added `req.acceptsLanguage()` + * Added `req.acceptsCharset()` + * Added `req.accepted` + * Added `req.acceptedLanguages` + * Added `req.acceptedCharsets` + * Added "json replacer" setting + * Added "json spaces" setting + * Added X-Forwarded-Proto support to `res.redirect()`. Closes #92 + * Added `--less` support to express(1) + * Added `express.response` prototype + * Added `express.request` prototype + * Added `express.application` prototype + * Added `app.path()` + * Added `app.render()` + * Added `res.type()` to replace `res.contentType()` + * Changed: `res.redirect()` to add relative support + * Changed: enable "jsonp callback" by default + * Changed: renamed "case sensitive routes" to "case sensitive routing" + * Rewrite of all tests with mocha + * Removed "root" setting + * Removed `res.redirect('home')` support + * Removed `req.notify()` + * Removed `app.register()` + * Removed `app.redirect()` + * Removed `app.is()` + * Removed `app.helpers()` + * Removed `app.dynamicHelpers()` + * Fixed `res.sendfile()` with non-GET. Closes #723 + * Fixed express(1) public dir for windows. Closes #866 + +2.5.9/ 2012-04-02 +================== + + * Added support for PURGE request method [pbuyle] + * Fixed `express(1)` generated app `app.address()` before `listening` [mmalecki] + +2.5.8 / 2012-02-08 +================== + + * Update mkdirp dep. Closes #991 + +2.5.7 / 2012-02-06 +================== + + * Fixed `app.all` duplicate DELETE requests [mscdex] + +2.5.6 / 2012-01-13 +================== + + * Updated hamljs dev dep. Closes #953 + +2.5.5 / 2012-01-08 +================== + + * Fixed: set `filename` on cached templates [matthewleon] + +2.5.4 / 2012-01-02 +================== + + * Fixed `express(1)` eol on 0.4.x. Closes #947 + +2.5.3 / 2011-12-30 +================== + + * Fixed `req.is()` when a charset is present + +2.5.2 / 2011-12-10 +================== + + * Fixed: express(1) LF -> CRLF for windows + +2.5.1 / 2011-11-17 +================== + + * Changed: updated connect to 1.8.x + * Removed sass.js support from express(1) + +2.5.0 / 2011-10-24 +================== + + * Added ./routes dir for generated app by default + * Added npm install reminder to express(1) app gen + * Added 0.5.x support + * Removed `make test-cov` since it wont work with node 0.5.x + * Fixed express(1) public dir for windows. Closes #866 + +2.4.7 / 2011-10-05 +================== + + * Added mkdirp to express(1). Closes #795 + * Added simple _json-config_ example + * Added shorthand for the parsed request's pathname via `req.path` + * Changed connect dep to 1.7.x to fix npm issue... + * Fixed `res.redirect()` __HEAD__ support. [reported by xerox] + * Fixed `req.flash()`, only escape args + * Fixed absolute path checking on windows. Closes #829 [reported by andrewpmckenzie] + +2.4.6 / 2011-08-22 +================== + + * Fixed multiple param callback regression. Closes #824 [reported by TroyGoode] + +2.4.5 / 2011-08-19 +================== + + * Added support for routes to handle errors. Closes #809 + * Added `app.routes.all()`. Closes #803 + * Added "basepath" setting to work in conjunction with reverse proxies etc. + * Refactored `Route` to use a single array of callbacks + * Added support for multiple callbacks for `app.param()`. Closes #801 +Closes #805 + * Changed: removed .call(self) for route callbacks + * Dependency: `qs >= 0.3.1` + * Fixed `res.redirect()` on windows due to `join()` usage. Closes #808 + +2.4.4 / 2011-08-05 +================== + + * Fixed `res.header()` intention of a set, even when `undefined` + * Fixed `*`, value no longer required + * Fixed `res.send(204)` support. Closes #771 + +2.4.3 / 2011-07-14 +================== + + * Added docs for `status` option special-case. Closes #739 + * Fixed `options.filename`, exposing the view path to template engines + +2.4.2. / 2011-07-06 +================== + + * Revert "removed jsonp stripping" for XSS + +2.4.1 / 2011-07-06 +================== + + * Added `res.json()` JSONP support. Closes #737 + * Added _extending-templates_ example. Closes #730 + * Added "strict routing" setting for trailing slashes + * Added support for multiple envs in `app.configure()` calls. Closes #735 + * Changed: `res.send()` using `res.json()` + * Changed: when cookie `path === null` don't default it + * Changed; default cookie path to "home" setting. Closes #731 + * Removed _pids/logs_ creation from express(1) + +2.4.0 / 2011-06-28 +================== + + * Added chainable `res.status(code)` + * Added `res.json()`, an explicit version of `res.send(obj)` + * Added simple web-service example + +2.3.12 / 2011-06-22 +================== + + * \#express is now on freenode! come join! + * Added `req.get(field, param)` + * Added links to Japanese documentation, thanks @hideyukisaito! + * Added; the `express(1)` generated app outputs the env + * Added `content-negotiation` example + * Dependency: connect >= 1.5.1 < 2.0.0 + * Fixed view layout bug. Closes #720 + * Fixed; ignore body on 304. Closes #701 + +2.3.11 / 2011-06-04 +================== + + * Added `npm test` + * Removed generation of dummy test file from `express(1)` + * Fixed; `express(1)` adds express as a dep + * Fixed; prune on `prepublish` + +2.3.10 / 2011-05-27 +================== + + * Added `req.route`, exposing the current route + * Added _package.json_ generation support to `express(1)` + * Fixed call to `app.param()` function for optional params. Closes #682 + +2.3.9 / 2011-05-25 +================== + + * Fixed bug-ish with `../' in `res.partial()` calls + +2.3.8 / 2011-05-24 +================== + + * Fixed `app.options()` + +2.3.7 / 2011-05-23 +================== + + * Added route `Collection`, ex: `app.get('/user/:id').remove();` + * Added support for `app.param(fn)` to define param logic + * Removed `app.param()` support for callback with return value + * Removed module.parent check from express(1) generated app. Closes #670 + * Refactored router. Closes #639 + +2.3.6 / 2011-05-20 +================== + + * Changed; using devDependencies instead of git submodules + * Fixed redis session example + * Fixed markdown example + * Fixed view caching, should not be enabled in development + +2.3.5 / 2011-05-20 +================== + + * Added export `.view` as alias for `.View` + +2.3.4 / 2011-05-08 +================== + + * Added `./examples/say` + * Fixed `res.sendfile()` bug preventing the transfer of files with spaces + +2.3.3 / 2011-05-03 +================== + + * Added "case sensitive routes" option. + * Changed; split methods supported per rfc [slaskis] + * Fixed route-specific middleware when using the same callback function several times + +2.3.2 / 2011-04-27 +================== + + * Fixed view hints + +2.3.1 / 2011-04-26 +================== + + * Added `app.match()` as `app.match.all()` + * Added `app.lookup()` as `app.lookup.all()` + * Added `app.remove()` for `app.remove.all()` + * Added `app.remove.VERB()` + * Fixed template caching collision issue. Closes #644 + * Moved router over from connect and started refactor + +2.3.0 / 2011-04-25 +================== + + * Added options support to `res.clearCookie()` + * Added `res.helpers()` as alias of `res.locals()` + * Added; json defaults to UTF-8 with `res.send()`. Closes #632. [Daniel * Dependency `connect >= 1.4.0` + * Changed; auto set Content-Type in res.attachement [Aaron Heckmann] + * Renamed "cache views" to "view cache". Closes #628 + * Fixed caching of views when using several apps. Closes #637 + * Fixed gotcha invoking `app.param()` callbacks once per route middleware. +Closes #638 + * Fixed partial lookup precedence. Closes #631 +Shaw] + +2.2.2 / 2011-04-12 +================== + + * Added second callback support for `res.download()` connection errors + * Fixed `filename` option passing to template engine + +2.2.1 / 2011-04-04 +================== + + * Added `layout(path)` helper to change the layout within a view. Closes #610 + * Fixed `partial()` collection object support. + Previously only anything with `.length` would work. + When `.length` is present one must still be aware of holes, + however now `{ collection: {foo: 'bar'}}` is valid, exposes + `keyInCollection` and `keysInCollection`. + + * Performance improved with better view caching + * Removed `request` and `response` locals + * Changed; errorHandler page title is now `Express` instead of `Connect` + +2.2.0 / 2011-03-30 +================== + + * Added `app.lookup.VERB()`, ex `app.lookup.put('/user/:id')`. Closes #606 + * Added `app.match.VERB()`, ex `app.match.put('/user/12')`. Closes #606 + * Added `app.VERB(path)` as alias of `app.lookup.VERB()`. + * Dependency `connect >= 1.2.0` + +2.1.1 / 2011-03-29 +================== + + * Added; expose `err.view` object when failing to locate a view + * Fixed `res.partial()` call `next(err)` when no callback is given [reported by aheckmann] + * Fixed; `res.send(undefined)` responds with 204 [aheckmann] + +2.1.0 / 2011-03-24 +================== + + * Added `/_?` partial lookup support. Closes #447 + * Added `request`, `response`, and `app` local variables + * Added `settings` local variable, containing the app's settings + * Added `req.flash()` exception if `req.session` is not available + * Added `res.send(bool)` support (json response) + * Fixed stylus example for latest version + * Fixed; wrap try/catch around `res.render()` + +2.0.0 / 2011-03-17 +================== + + * Fixed up index view path alternative. + * Changed; `res.locals()` without object returns the locals + +2.0.0rc3 / 2011-03-17 +================== + + * Added `res.locals(obj)` to compliment `res.local(key, val)` + * Added `res.partial()` callback support + * Fixed recursive error reporting issue in `res.render()` + +2.0.0rc2 / 2011-03-17 +================== + + * Changed; `partial()` "locals" are now optional + * Fixed `SlowBuffer` support. Closes #584 [reported by tyrda01] + * Fixed .filename view engine option [reported by drudge] + * Fixed blog example + * Fixed `{req,res}.app` reference when mounting [Ben Weaver] + +2.0.0rc / 2011-03-14 +================== + + * Fixed; expose `HTTPSServer` constructor + * Fixed express(1) default test charset. Closes #579 [reported by secoif] + * Fixed; default charset to utf-8 instead of utf8 for lame IE [reported by NickP] + +2.0.0beta3 / 2011-03-09 +================== + + * Added support for `res.contentType()` literal + The original `res.contentType('.json')`, + `res.contentType('application/json')`, and `res.contentType('json')` + will work now. + * Added `res.render()` status option support back + * Added charset option for `res.render()` + * Added `.charset` support (via connect 1.0.4) + * Added view resolution hints when in development and a lookup fails + * Added layout lookup support relative to the page view. + For example while rendering `./views/user/index.jade` if you create + `./views/user/layout.jade` it will be used in favour of the root layout. + * Fixed `res.redirect()`. RFC states absolute url [reported by unlink] + * Fixed; default `res.send()` string charset to utf8 + * Removed `Partial` constructor (not currently used) + +2.0.0beta2 / 2011-03-07 +================== + + * Added res.render() `.locals` support back to aid in migration process + * Fixed flash example + +2.0.0beta / 2011-03-03 +================== + + * Added HTTPS support + * Added `res.cookie()` maxAge support + * Added `req.header()` _Referrer_ / _Referer_ special-case, either works + * Added mount support for `res.redirect()`, now respects the mount-point + * Added `union()` util, taking place of `merge(clone())` combo + * Added stylus support to express(1) generated app + * Added secret to session middleware used in examples and generated app + * Added `res.local(name, val)` for progressive view locals + * Added default param support to `req.param(name, default)` + * Added `app.disabled()` and `app.enabled()` + * Added `app.register()` support for omitting leading ".", either works + * Added `res.partial()`, using the same interface as `partial()` within a view. Closes #539 + * Added `app.param()` to map route params to async/sync logic + * Added; aliased `app.helpers()` as `app.locals()`. Closes #481 + * Added extname with no leading "." support to `res.contentType()` + * Added `cache views` setting, defaulting to enabled in "production" env + * Added index file partial resolution, eg: partial('user') may try _views/user/index.jade_. + * Added `req.accepts()` support for extensions + * Changed; `res.download()` and `res.sendfile()` now utilize Connect's + static file server `connect.static.send()`. + * Changed; replaced `connect.utils.mime()` with npm _mime_ module + * Changed; allow `req.query` to be pre-defined (via middleware or other parent + * Changed view partial resolution, now relative to parent view + * Changed view engine signature. no longer `engine.render(str, options, callback)`, now `engine.compile(str, options) -> Function`, the returned function accepts `fn(locals)`. + * Fixed `req.param()` bug returning Array.prototype methods. Closes #552 + * Fixed; using `Stream#pipe()` instead of `sys.pump()` in `res.sendfile()` + * Fixed; using _qs_ module instead of _querystring_ + * Fixed; strip unsafe chars from jsonp callbacks + * Removed "stream threshold" setting + +1.0.8 / 2011-03-01 +================== + + * Allow `req.query` to be pre-defined (via middleware or other parent app) + * "connect": ">= 0.5.0 < 1.0.0". Closes #547 + * Removed the long deprecated __EXPRESS_ENV__ support + +1.0.7 / 2011-02-07 +================== + + * Fixed `render()` setting inheritance. + Mounted apps would not inherit "view engine" + +1.0.6 / 2011-02-07 +================== + + * Fixed `view engine` setting bug when period is in dirname + +1.0.5 / 2011-02-05 +================== + + * Added secret to generated app `session()` call + +1.0.4 / 2011-02-05 +================== + + * Added `qs` dependency to _package.json_ + * Fixed namespaced `require()`s for latest connect support + +1.0.3 / 2011-01-13 +================== + + * Remove unsafe characters from JSONP callback names [Ryan Grove] + +1.0.2 / 2011-01-10 +================== + + * Removed nested require, using `connect.router` + +1.0.1 / 2010-12-29 +================== + + * Fixed for middleware stacked via `createServer()` + previously the `foo` middleware passed to `createServer(foo)` + would not have access to Express methods such as `res.send()` + or props like `req.query` etc. + +1.0.0 / 2010-11-16 +================== + + * Added; deduce partial object names from the last segment. + For example by default `partial('forum/post', postObject)` will + give you the _post_ object, providing a meaningful default. + * Added http status code string representation to `res.redirect()` body + * Added; `res.redirect()` supporting _text/plain_ and _text/html_ via __Accept__. + * Added `req.is()` to aid in content negotiation + * Added partial local inheritance [suggested by masylum]. Closes #102 + providing access to parent template locals. + * Added _-s, --session[s]_ flag to express(1) to add session related middleware + * Added _--template_ flag to express(1) to specify the + template engine to use. + * Added _--css_ flag to express(1) to specify the + stylesheet engine to use (or just plain css by default). + * Added `app.all()` support [thanks aheckmann] + * Added partial direct object support. + You may now `partial('user', user)` providing the "user" local, + vs previously `partial('user', { object: user })`. + * Added _route-separation_ example since many people question ways + to do this with CommonJS modules. Also view the _blog_ example for + an alternative. + * Performance; caching view path derived partial object names + * Fixed partial local inheritance precedence. [reported by Nick Poulden] Closes #454 + * Fixed jsonp support; _text/javascript_ as per mailinglist discussion + +1.0.0rc4 / 2010-10-14 +================== + + * Added _NODE_ENV_ support, _EXPRESS_ENV_ is deprecated and will be removed in 1.0.0 + * Added route-middleware support (very helpful, see the [docs](http://expressjs.com/guide.html#Route-Middleware)) + * Added _jsonp callback_ setting to enable/disable jsonp autowrapping [Dav Glass] + * Added callback query check on response.send to autowrap JSON objects for simple webservice implementations [Dav Glass] + * Added `partial()` support for array-like collections. Closes #434 + * Added support for swappable querystring parsers + * Added session usage docs. Closes #443 + * Added dynamic helper caching. Closes #439 [suggested by maritz] + * Added authentication example + * Added basic Range support to `res.sendfile()` (and `res.download()` etc) + * Changed; `express(1)` generated app using 2 spaces instead of 4 + * Default env to "development" again [aheckmann] + * Removed _context_ option is no more, use "scope" + * Fixed; exposing _./support_ libs to examples so they can run without installs + * Fixed mvc example + +1.0.0rc3 / 2010-09-20 +================== + + * Added confirmation for `express(1)` app generation. Closes #391 + * Added extending of flash formatters via `app.flashFormatters` + * Added flash formatter support. Closes #411 + * Added streaming support to `res.sendfile()` using `sys.pump()` when >= "stream threshold" + * Added _stream threshold_ setting for `res.sendfile()` + * Added `res.send()` __HEAD__ support + * Added `res.clearCookie()` + * Added `res.cookie()` + * Added `res.render()` headers option + * Added `res.redirect()` response bodies + * Added `res.render()` status option support. Closes #425 [thanks aheckmann] + * Fixed `res.sendfile()` responding with 403 on malicious path + * Fixed `res.download()` bug; when an error occurs remove _Content-Disposition_ + * Fixed; mounted apps settings now inherit from parent app [aheckmann] + * Fixed; stripping Content-Length / Content-Type when 204 + * Fixed `res.send()` 204. Closes #419 + * Fixed multiple _Set-Cookie_ headers via `res.header()`. Closes #402 + * Fixed bug messing with error handlers when `listenFD()` is called instead of `listen()`. [thanks guillermo] + + +1.0.0rc2 / 2010-08-17 +================== + + * Added `app.register()` for template engine mapping. Closes #390 + * Added `res.render()` callback support as second argument (no options) + * Added callback support to `res.download()` + * Added callback support for `res.sendfile()` + * Added support for middleware access via `express.middlewareName()` vs `connect.middlewareName()` + * Added "partials" setting to docs + * Added default expresso tests to `express(1)` generated app. Closes #384 + * Fixed `res.sendfile()` error handling, defer via `next()` + * Fixed `res.render()` callback when a layout is used [thanks guillermo] + * Fixed; `make install` creating ~/.node_libraries when not present + * Fixed issue preventing error handlers from being defined anywhere. Closes #387 + +1.0.0rc / 2010-07-28 +================== + + * Added mounted hook. Closes #369 + * Added connect dependency to _package.json_ + + * Removed "reload views" setting and support code + development env never caches, production always caches. + + * Removed _param_ in route callbacks, signature is now + simply (req, res, next), previously (req, res, params, next). + Use _req.params_ for path captures, _req.query_ for GET params. + + * Fixed "home" setting + * Fixed middleware/router precedence issue. Closes #366 + * Fixed; _configure()_ callbacks called immediately. Closes #368 + +1.0.0beta2 / 2010-07-23 +================== + + * Added more examples + * Added; exporting `Server` constructor + * Added `Server#helpers()` for view locals + * Added `Server#dynamicHelpers()` for dynamic view locals. Closes #349 + * Added support for absolute view paths + * Added; _home_ setting defaults to `Server#route` for mounted apps. Closes #363 + * Added Guillermo Rauch to the contributor list + * Added support for "as" for non-collection partials. Closes #341 + * Fixed _install.sh_, ensuring _~/.node_libraries_ exists. Closes #362 [thanks jf] + * Fixed `res.render()` exceptions, now passed to `next()` when no callback is given [thanks guillermo] + * Fixed instanceof `Array` checks, now `Array.isArray()` + * Fixed express(1) expansion of public dirs. Closes #348 + * Fixed middleware precedence. Closes #345 + * Fixed view watcher, now async [thanks aheckmann] + +1.0.0beta / 2010-07-15 +================== + + * Re-write + - much faster + - much lighter + - Check [ExpressJS.com](http://expressjs.com) for migration guide and updated docs + +0.14.0 / 2010-06-15 +================== + + * Utilize relative requires + * Added Static bufferSize option [aheckmann] + * Fixed caching of view and partial subdirectories [aheckmann] + * Fixed mime.type() comments now that ".ext" is not supported + * Updated haml submodule + * Updated class submodule + * Removed bin/express + +0.13.0 / 2010-06-01 +================== + + * Added node v0.1.97 compatibility + * Added support for deleting cookies via Request#cookie('key', null) + * Updated haml submodule + * Fixed not-found page, now using using charset utf-8 + * Fixed show-exceptions page, now using using charset utf-8 + * Fixed view support due to fs.readFile Buffers + * Changed; mime.type() no longer accepts ".type" due to node extname() changes + +0.12.0 / 2010-05-22 +================== + + * Added node v0.1.96 compatibility + * Added view `helpers` export which act as additional local variables + * Updated haml submodule + * Changed ETag; removed inode, modified time only + * Fixed LF to CRLF for setting multiple cookies + * Fixed cookie complation; values are now urlencoded + * Fixed cookies parsing; accepts quoted values and url escaped cookies + +0.11.0 / 2010-05-06 +================== + + * Added support for layouts using different engines + - this.render('page.html.haml', { layout: 'super-cool-layout.html.ejs' }) + - this.render('page.html.haml', { layout: 'foo' }) // assumes 'foo.html.haml' + - this.render('page.html.haml', { layout: false }) // no layout + * Updated ext submodule + * Updated haml submodule + * Fixed EJS partial support by passing along the context. Issue #307 + +0.10.1 / 2010-05-03 +================== + + * Fixed binary uploads. + +0.10.0 / 2010-04-30 +================== + + * Added charset support via Request#charset (automatically assigned to 'UTF-8' when respond()'s + encoding is set to 'utf8' or 'utf-8'. + * Added "encoding" option to Request#render(). Closes #299 + * Added "dump exceptions" setting, which is enabled by default. + * Added simple ejs template engine support + * Added error response support for text/plain, application/json. Closes #297 + * Added callback function param to Request#error() + * Added Request#sendHead() + * Added Request#stream() + * Added support for Request#respond(304, null) for empty response bodies + * Added ETag support to Request#sendfile() + * Added options to Request#sendfile(), passed to fs.createReadStream() + * Added filename arg to Request#download() + * Performance enhanced due to pre-reversing plugins so that plugins.reverse() is not called on each request + * Performance enhanced by preventing several calls to toLowerCase() in Router#match() + * Changed; Request#sendfile() now streams + * Changed; Renamed Request#halt() to Request#respond(). Closes #289 + * Changed; Using sys.inspect() instead of JSON.encode() for error output + * Changed; run() returns the http.Server instance. Closes #298 + * Changed; Defaulting Server#host to null (INADDR_ANY) + * Changed; Logger "common" format scale of 0.4f + * Removed Logger "request" format + * Fixed; Catching ENOENT in view caching, preventing error when "views/partials" is not found + * Fixed several issues with http client + * Fixed Logger Content-Length output + * Fixed bug preventing Opera from retaining the generated session id. Closes #292 + +0.9.0 / 2010-04-14 +================== + + * Added DSL level error() route support + * Added DSL level notFound() route support + * Added Request#error() + * Added Request#notFound() + * Added Request#render() callback function. Closes #258 + * Added "max upload size" setting + * Added "magic" variables to collection partials (\_\_index\_\_, \_\_length\_\_, \_\_isFirst\_\_, \_\_isLast\_\_). Closes #254 + * Added [haml.js](http://github.com/visionmedia/haml.js) submodule; removed haml-js + * Added callback function support to Request#halt() as 3rd/4th arg + * Added preprocessing of route param wildcards using param(). Closes #251 + * Added view partial support (with collections etc) + * Fixed bug preventing falsey params (such as ?page=0). Closes #286 + * Fixed setting of multiple cookies. Closes #199 + * Changed; view naming convention is now NAME.TYPE.ENGINE (for example page.html.haml) + * Changed; session cookie is now httpOnly + * Changed; Request is no longer global + * Changed; Event is no longer global + * Changed; "sys" module is no longer global + * Changed; moved Request#download to Static plugin where it belongs + * Changed; Request instance created before body parsing. Closes #262 + * Changed; Pre-caching views in memory when "cache view contents" is enabled. Closes #253 + * Changed; Pre-caching view partials in memory when "cache view partials" is enabled + * Updated support to node --version 0.1.90 + * Updated dependencies + * Removed set("session cookie") in favour of use(Session, { cookie: { ... }}) + * Removed utils.mixin(); use Object#mergeDeep() + +0.8.0 / 2010-03-19 +================== + + * Added coffeescript example app. Closes #242 + * Changed; cache api now async friendly. Closes #240 + * Removed deprecated 'express/static' support. Use 'express/plugins/static' + +0.7.6 / 2010-03-19 +================== + + * Added Request#isXHR. Closes #229 + * Added `make install` (for the executable) + * Added `express` executable for setting up simple app templates + * Added "GET /public/*" to Static plugin, defaulting to /public + * Added Static plugin + * Fixed; Request#render() only calls cache.get() once + * Fixed; Namespacing View caches with "view:" + * Fixed; Namespacing Static caches with "static:" + * Fixed; Both example apps now use the Static plugin + * Fixed set("views"). Closes #239 + * Fixed missing space for combined log format + * Deprecated Request#sendfile() and 'express/static' + * Removed Server#running + +0.7.5 / 2010-03-16 +================== + + * Added Request#flash() support without args, now returns all flashes + * Updated ext submodule + +0.7.4 / 2010-03-16 +================== + + * Fixed session reaper + * Changed; class.js replacing js-oo Class implementation (quite a bit faster, no browser cruft) + +0.7.3 / 2010-03-16 +================== + + * Added package.json + * Fixed requiring of haml / sass due to kiwi removal + +0.7.2 / 2010-03-16 +================== + + * Fixed GIT submodules (HAH!) + +0.7.1 / 2010-03-16 +================== + + * Changed; Express now using submodules again until a PM is adopted + * Changed; chat example using millisecond conversions from ext + +0.7.0 / 2010-03-15 +================== + + * Added Request#pass() support (finds the next matching route, or the given path) + * Added Logger plugin (default "common" format replaces CommonLogger) + * Removed Profiler plugin + * Removed CommonLogger plugin + +0.6.0 / 2010-03-11 +================== + + * Added seed.yml for kiwi package management support + * Added HTTP client query string support when method is GET. Closes #205 + + * Added support for arbitrary view engines. + For example "foo.engine.html" will now require('engine'), + the exports from this module are cached after the first require(). + + * Added async plugin support + + * Removed usage of RESTful route funcs as http client + get() etc, use http.get() and friends + + * Removed custom exceptions + +0.5.0 / 2010-03-10 +================== + + * Added ext dependency (library of js extensions) + * Removed extname() / basename() utils. Use path module + * Removed toArray() util. Use arguments.values + * Removed escapeRegexp() util. Use RegExp.escape() + * Removed process.mixin() dependency. Use utils.mixin() + * Removed Collection + * Removed ElementCollection + * Shameless self promotion of ebook "Advanced JavaScript" (http://dev-mag.com) ;) + +0.4.0 / 2010-02-11 +================== + + * Added flash() example to sample upload app + * Added high level restful http client module (express/http) + * Changed; RESTful route functions double as HTTP clients. Closes #69 + * Changed; throwing error when routes are added at runtime + * Changed; defaulting render() context to the current Request. Closes #197 + * Updated haml submodule + +0.3.0 / 2010-02-11 +================== + + * Updated haml / sass submodules. Closes #200 + * Added flash message support. Closes #64 + * Added accepts() now allows multiple args. fixes #117 + * Added support for plugins to halt. Closes #189 + * Added alternate layout support. Closes #119 + * Removed Route#run(). Closes #188 + * Fixed broken specs due to use(Cookie) missing + +0.2.1 / 2010-02-05 +================== + + * Added "plot" format option for Profiler (for gnuplot processing) + * Added request number to Profiler plugin + * Fixed binary encoding for multi-part file uploads, was previously defaulting to UTF8 + * Fixed issue with routes not firing when not files are present. Closes #184 + * Fixed process.Promise -> events.Promise + +0.2.0 / 2010-02-03 +================== + + * Added parseParam() support for name[] etc. (allows for file inputs with "multiple" attr) Closes #180 + * Added Both Cache and Session option "reapInterval" may be "reapEvery". Closes #174 + * Added expiration support to cache api with reaper. Closes #133 + * Added cache Store.Memory#reap() + * Added Cache; cache api now uses first class Cache instances + * Added abstract session Store. Closes #172 + * Changed; cache Memory.Store#get() utilizing Collection + * Renamed MemoryStore -> Store.Memory + * Fixed use() of the same plugin several time will always use latest options. Closes #176 + +0.1.0 / 2010-02-03 +================== + + * Changed; Hooks (before / after) pass request as arg as well as evaluated in their context + * Updated node support to 0.1.27 Closes #169 + * Updated dirname(__filename) -> __dirname + * Updated libxmljs support to v0.2.0 + * Added session support with memory store / reaping + * Added quick uid() helper + * Added multi-part upload support + * Added Sass.js support / submodule + * Added production env caching view contents and static files + * Added static file caching. Closes #136 + * Added cache plugin with memory stores + * Added support to StaticFile so that it works with non-textual files. + * Removed dirname() helper + * Removed several globals (now their modules must be required) + +0.0.2 / 2010-01-10 +================== + + * Added view benchmarks; currently haml vs ejs + * Added Request#attachment() specs. Closes #116 + * Added use of node's parseQuery() util. Closes #123 + * Added `make init` for submodules + * Updated Haml + * Updated sample chat app to show messages on load + * Updated libxmljs parseString -> parseHtmlString + * Fixed `make init` to work with older versions of git + * Fixed specs can now run independent specs for those who cant build deps. Closes #127 + * Fixed issues introduced by the node url module changes. Closes 126. + * Fixed two assertions failing due to Collection#keys() returning strings + * Fixed faulty Collection#toArray() spec due to keys() returning strings + * Fixed `make test` now builds libxmljs.node before testing + +0.0.1 / 2010-01-03 +================== + + * Initial release diff --git a/node_modules/express/LICENSE b/node_modules/express/LICENSE new file mode 100644 index 0000000..0f3c767 --- /dev/null +++ b/node_modules/express/LICENSE @@ -0,0 +1,22 @@ +(The MIT License) + +Copyright (c) 2009-2014 TJ Holowaychuk + +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/node_modules/express/Readme.md b/node_modules/express/Readme.md new file mode 100644 index 0000000..426bb72 --- /dev/null +++ b/node_modules/express/Readme.md @@ -0,0 +1,128 @@ +[![Express Logo](https://i.cloudup.com/zfY6lL7eFa-3000x3000.png)](http://expressjs.com/) + + Fast, unopinionated, minimalist web framework for [node](http://nodejs.org). + + [![NPM Version](https://img.shields.io/npm/v/express.svg?style=flat)](https://www.npmjs.org/package/express) + [![Build Status](https://img.shields.io/travis/strongloop/express.svg?style=flat)](https://travis-ci.org/strongloop/express) + [![Coverage Status](https://img.shields.io/coveralls/strongloop/express.svg?style=flat)](https://coveralls.io/r/strongloop/express) + [![Gittip](https://img.shields.io/gittip/dougwilson.svg?style=flat)](https://www.gittip.com/dougwilson/) + +```js +var express = require('express') +var app = express() + +app.get('/', function (req, res) { + res.send('Hello World') +}) + +app.listen(3000) +``` + + **PROTIP** Be sure to read [Migrating from 3.x to 4.x](https://github.com/strongloop/express/wiki/Migrating-from-3.x-to-4.x) as well as [New features in 4.x](https://github.com/strongloop/express/wiki/New-features-in-4.x). + +### Installation + +```bash +$ npm install express +``` + +## Quick Start + + The quickest way to get started with express is to utilize the executable [`express(1)`](https://github.com/expressjs/generator) to generate an application as shown below: + + Install the executable. The executable's major version will match Express's: + +```bash +$ npm install -g express-generator@4 +``` + + Create the app: + +```bash +$ express /tmp/foo && cd /tmp/foo +``` + + Install dependencies: + +```bash +$ npm install +``` + + Start the server: + +```bash +$ npm start +``` + +## Features + + * Robust routing + * HTTP helpers (redirection, caching, etc) + * View system supporting 14+ template engines + * Content negotiation + * Focus on high performance + * Executable for generating applications quickly + * High test coverage + +## Philosophy + + The Express philosophy is to provide small, robust tooling for HTTP servers, making + it a great solution for single page applications, web sites, hybrids, or public + HTTP APIs. + + Express does not force you to use any specific ORM or template engine. With support for over + 14 template engines via [Consolidate.js](https://github.com/visionmedia/consolidate.js), + you can quickly craft your perfect framework. + +## More Information + + * [Website and Documentation](http://expressjs.com/) - [[website repo](https://github.com/strongloop/expressjs.com)] + * [Github Organization](https://github.com/expressjs) for Official Middleware & Modules + * [#express](https://webchat.freenode.net/?channels=express) on freenode IRC + * Visit the [Wiki](https://github.com/strongloop/express/wiki) + * [Google Group](https://groups.google.com/group/express-js) for discussion + * [Русскоязычная документация](http://jsman.ru/express/) + * [한국어 문서](http://expressjs.kr) - [[website repo](https://github.com/Hanul/expressjs.kr)] + * Run express examples [online](https://runnable.com/express) + +## Viewing Examples + + Clone the Express repo, then install the dev dependencies to install all the example / test suite dependencies: + +```bash +$ git clone git://github.com/strongloop/express.git --depth 1 +$ cd express +$ npm install +``` + + Then run whichever example you want: + + $ node examples/content-negotiation + + You can also view live examples here: + + + +## Running Tests + + To run the test suite, first invoke the following command within the repo, installing the development dependencies: + +```bash +$ npm install +``` + + Then run the tests: + +```bash +$ npm test +``` + +### Contributors + + * Author: [TJ Holowaychuk](https://github.com/visionmedia) + * Lead Maintainer: [Douglas Christopher Wilson](https://github.com/dougwilson) + * [All Contributors](https://github.com/strongloop/express/graphs/contributors) + +### License + + [MIT](LICENSE) diff --git a/node_modules/express/index.js b/node_modules/express/index.js new file mode 100644 index 0000000..3da3378 --- /dev/null +++ b/node_modules/express/index.js @@ -0,0 +1,2 @@ + +module.exports = require('./lib/express'); diff --git a/node_modules/express/lib/application.js b/node_modules/express/lib/application.js new file mode 100644 index 0000000..2c7cc2d --- /dev/null +++ b/node_modules/express/lib/application.js @@ -0,0 +1,568 @@ +/** + * Module dependencies. + */ + +var finalhandler = require('finalhandler'); +var flatten = require('./utils').flatten; +var mixin = require('utils-merge'); +var Router = require('./router'); +var methods = require('methods'); +var middleware = require('./middleware/init'); +var query = require('./middleware/query'); +var debug = require('debug')('express:application'); +var View = require('./view'); +var http = require('http'); +var compileETag = require('./utils').compileETag; +var compileQueryParser = require('./utils').compileQueryParser; +var compileTrust = require('./utils').compileTrust; +var deprecate = require('depd')('express'); +var resolve = require('path').resolve; +var slice = Array.prototype.slice; + +/** + * Application prototype. + */ + +var app = exports = module.exports = {}; + +/** + * Initialize the server. + * + * - setup default configuration + * - setup default middleware + * - setup route reflection methods + * + * @api private + */ + +app.init = function(){ + this.cache = {}; + this.settings = {}; + this.engines = {}; + this.defaultConfiguration(); +}; + +/** + * Initialize application configuration. + * + * @api private + */ + +app.defaultConfiguration = function(){ + // default settings + this.enable('x-powered-by'); + this.set('etag', 'weak'); + var env = process.env.NODE_ENV || 'development'; + this.set('env', env); + this.set('query parser', 'extended'); + this.set('subdomain offset', 2); + this.set('trust proxy', false); + + debug('booting in %s mode', env); + + // inherit protos + this.on('mount', function(parent){ + this.request.__proto__ = parent.request; + this.response.__proto__ = parent.response; + this.engines.__proto__ = parent.engines; + this.settings.__proto__ = parent.settings; + }); + + // setup locals + this.locals = Object.create(null); + + // top-most app is mounted at / + this.mountpath = '/'; + + // default locals + this.locals.settings = this.settings; + + // default configuration + this.set('view', View); + this.set('views', resolve('views')); + this.set('jsonp callback name', 'callback'); + + if (env === 'production') { + this.enable('view cache'); + } + + Object.defineProperty(this, 'router', { + get: function() { + throw new Error('\'app.router\' is deprecated!\nPlease see the 3.x to 4.x migration guide for details on how to update your app.'); + } + }); +}; + +/** + * lazily adds the base router if it has not yet been added. + * + * We cannot add the base router in the defaultConfiguration because + * it reads app settings which might be set after that has run. + * + * @api private + */ +app.lazyrouter = function() { + if (!this._router) { + this._router = new Router({ + caseSensitive: this.enabled('case sensitive routing'), + strict: this.enabled('strict routing') + }); + + this._router.use(query(this.get('query parser fn'))); + this._router.use(middleware.init(this)); + } +}; + +/** + * Dispatch a req, res pair into the application. Starts pipeline processing. + * + * If no _done_ callback is provided, then default error handlers will respond + * in the event of an error bubbling through the stack. + * + * @api private + */ + +app.handle = function(req, res, done) { + var router = this._router; + + // final handler + done = done || finalhandler(req, res, { + env: this.get('env'), + onerror: logerror.bind(this) + }); + + // no routes + if (!router) { + debug('no routes defined on app'); + done(); + return; + } + + router.handle(req, res, done); +}; + +/** + * Proxy `Router#use()` to add middleware to the app router. + * See Router#use() documentation for details. + * + * If the _fn_ parameter is an express app, then it will be + * mounted at the _route_ specified. + * + * @api public + */ + +app.use = function use(fn) { + var offset = 0; + var path = '/'; + var self = this; + + // default path to '/' + // disambiguate app.use([fn]) + if (typeof fn !== 'function') { + var arg = fn; + + while (Array.isArray(arg) && arg.length !== 0) { + arg = arg[0]; + } + + // first arg is the path + if (typeof arg !== 'function') { + offset = 1; + path = fn; + } + } + + var fns = flatten(slice.call(arguments, offset)); + + if (fns.length === 0) { + throw new TypeError('app.use() requires middleware functions'); + } + + // setup router + this.lazyrouter(); + var router = this._router; + + fns.forEach(function (fn) { + // non-express app + if (!fn || !fn.handle || !fn.set) { + return router.use(path, fn); + } + + debug('.use app under %s', path); + fn.mountpath = path; + fn.parent = self; + + // restore .app property on req and res + router.use(path, function mounted_app(req, res, next) { + var orig = req.app; + fn.handle(req, res, function (err) { + req.__proto__ = orig.request; + res.__proto__ = orig.response; + next(err); + }); + }); + + // mounted an app + fn.emit('mount', self); + }); + + return this; +}; + +/** + * Proxy to the app `Router#route()` + * Returns a new `Route` instance for the _path_. + * + * Routes are isolated middleware stacks for specific paths. + * See the Route api docs for details. + * + * @api public + */ + +app.route = function(path){ + this.lazyrouter(); + return this._router.route(path); +}; + +/** + * Register the given template engine callback `fn` + * as `ext`. + * + * By default will `require()` the engine based on the + * file extension. For example if you try to render + * a "foo.jade" file Express will invoke the following internally: + * + * app.engine('jade', require('jade').__express); + * + * For engines that do not provide `.__express` out of the box, + * or if you wish to "map" a different extension to the template engine + * you may use this method. For example mapping the EJS template engine to + * ".html" files: + * + * app.engine('html', require('ejs').renderFile); + * + * In this case EJS provides a `.renderFile()` method with + * the same signature that Express expects: `(path, options, callback)`, + * though note that it aliases this method as `ejs.__express` internally + * so if you're using ".ejs" extensions you dont need to do anything. + * + * Some template engines do not follow this convention, the + * [Consolidate.js](https://github.com/visionmedia/consolidate.js) + * library was created to map all of node's popular template + * engines to follow this convention, thus allowing them to + * work seamlessly within Express. + * + * @param {String} ext + * @param {Function} fn + * @return {app} for chaining + * @api public + */ + +app.engine = function(ext, fn){ + if ('function' != typeof fn) throw new Error('callback function required'); + if ('.' != ext[0]) ext = '.' + ext; + this.engines[ext] = fn; + return this; +}; + +/** + * Proxy to `Router#param()` with one added api feature. The _name_ parameter + * can be an array of names. + * + * See the Router#param() docs for more details. + * + * @param {String|Array} name + * @param {Function} fn + * @return {app} for chaining + * @api public + */ + +app.param = function(name, fn){ + var self = this; + self.lazyrouter(); + + if (Array.isArray(name)) { + name.forEach(function(key) { + self.param(key, fn); + }); + return this; + } + + self._router.param(name, fn); + return this; +}; + +/** + * Assign `setting` to `val`, or return `setting`'s value. + * + * app.set('foo', 'bar'); + * app.get('foo'); + * // => "bar" + * + * Mounted servers inherit their parent server's settings. + * + * @param {String} setting + * @param {*} [val] + * @return {Server} for chaining + * @api public + */ + +app.set = function(setting, val){ + if (arguments.length === 1) { + // app.get(setting) + return this.settings[setting]; + } + + // set value + this.settings[setting] = val; + + // trigger matched settings + switch (setting) { + case 'etag': + debug('compile etag %s', val); + this.set('etag fn', compileETag(val)); + break; + case 'query parser': + debug('compile query parser %s', val); + this.set('query parser fn', compileQueryParser(val)); + break; + case 'trust proxy': + debug('compile trust proxy %s', val); + this.set('trust proxy fn', compileTrust(val)); + break; + } + + return this; +}; + +/** + * Return the app's absolute pathname + * based on the parent(s) that have + * mounted it. + * + * For example if the application was + * mounted as "/admin", which itself + * was mounted as "/blog" then the + * return value would be "/blog/admin". + * + * @return {String} + * @api private + */ + +app.path = function(){ + return this.parent + ? this.parent.path() + this.mountpath + : ''; +}; + +/** + * Check if `setting` is enabled (truthy). + * + * app.enabled('foo') + * // => false + * + * app.enable('foo') + * app.enabled('foo') + * // => true + * + * @param {String} setting + * @return {Boolean} + * @api public + */ + +app.enabled = function(setting){ + return !!this.set(setting); +}; + +/** + * Check if `setting` is disabled. + * + * app.disabled('foo') + * // => true + * + * app.enable('foo') + * app.disabled('foo') + * // => false + * + * @param {String} setting + * @return {Boolean} + * @api public + */ + +app.disabled = function(setting){ + return !this.set(setting); +}; + +/** + * Enable `setting`. + * + * @param {String} setting + * @return {app} for chaining + * @api public + */ + +app.enable = function(setting){ + return this.set(setting, true); +}; + +/** + * Disable `setting`. + * + * @param {String} setting + * @return {app} for chaining + * @api public + */ + +app.disable = function(setting){ + return this.set(setting, false); +}; + +/** + * Delegate `.VERB(...)` calls to `router.VERB(...)`. + */ + +methods.forEach(function(method){ + app[method] = function(path){ + if ('get' == method && 1 == arguments.length) return this.set(path); + + this.lazyrouter(); + + var route = this._router.route(path); + route[method].apply(route, slice.call(arguments, 1)); + return this; + }; +}); + +/** + * Special-cased "all" method, applying the given route `path`, + * middleware, and callback to _every_ HTTP method. + * + * @param {String} path + * @param {Function} ... + * @return {app} for chaining + * @api public + */ + +app.all = function(path){ + this.lazyrouter(); + + var route = this._router.route(path); + var args = slice.call(arguments, 1); + methods.forEach(function(method){ + route[method].apply(route, args); + }); + + return this; +}; + +// del -> delete alias + +app.del = deprecate.function(app.delete, 'app.del: Use app.delete instead'); + +/** + * Render the given view `name` name with `options` + * and a callback accepting an error and the + * rendered template string. + * + * Example: + * + * app.render('email', { name: 'Tobi' }, function(err, html){ + * // ... + * }) + * + * @param {String} name + * @param {String|Function} options or fn + * @param {Function} fn + * @api public + */ + +app.render = function(name, options, fn){ + var opts = {}; + var cache = this.cache; + var engines = this.engines; + var view; + + // support callback function as second arg + if ('function' == typeof options) { + fn = options, options = {}; + } + + // merge app.locals + mixin(opts, this.locals); + + // merge options._locals + if (options._locals) mixin(opts, options._locals); + + // merge options + mixin(opts, options); + + // set .cache unless explicitly provided + opts.cache = null == opts.cache + ? this.enabled('view cache') + : opts.cache; + + // primed cache + if (opts.cache) view = cache[name]; + + // view + if (!view) { + view = new (this.get('view'))(name, { + defaultEngine: this.get('view engine'), + root: this.get('views'), + engines: engines + }); + + if (!view.path) { + var err = new Error('Failed to lookup view "' + name + '" in views directory "' + view.root + '"'); + err.view = view; + return fn(err); + } + + // prime the cache + if (opts.cache) cache[name] = view; + } + + // render + try { + view.render(opts, fn); + } catch (err) { + fn(err); + } +}; + +/** + * Listen for connections. + * + * A node `http.Server` is returned, with this + * application (which is a `Function`) as its + * callback. If you wish to create both an HTTP + * and HTTPS server you may do so with the "http" + * and "https" modules as shown here: + * + * var http = require('http') + * , https = require('https') + * , express = require('express') + * , app = express(); + * + * http.createServer(app).listen(80); + * https.createServer({ ... }, app).listen(443); + * + * @return {http.Server} + * @api public + */ + +app.listen = function(){ + var server = http.createServer(this); + return server.listen.apply(server, arguments); +}; + +/** +* Log error using console.error. +* +* @param {Error} err +* @api public +*/ + +function logerror(err){ + if (this.get('env') !== 'test') console.error(err.stack || err.toString()); +} diff --git a/node_modules/express/lib/express.js b/node_modules/express/lib/express.js new file mode 100644 index 0000000..7be6832 --- /dev/null +++ b/node_modules/express/lib/express.js @@ -0,0 +1,93 @@ +/** + * Module dependencies. + */ + +var EventEmitter = require('events').EventEmitter; +var mixin = require('utils-merge'); +var proto = require('./application'); +var Route = require('./router/route'); +var Router = require('./router'); +var req = require('./request'); +var res = require('./response'); + +/** + * Expose `createApplication()`. + */ + +exports = module.exports = createApplication; + +/** + * Create an express application. + * + * @return {Function} + * @api public + */ + +function createApplication() { + var app = function(req, res, next) { + app.handle(req, res, next); + }; + + mixin(app, proto); + mixin(app, EventEmitter.prototype); + + app.request = { __proto__: req, app: app }; + app.response = { __proto__: res, app: app }; + app.init(); + return app; +} + +/** + * Expose the prototypes. + */ + +exports.application = proto; +exports.request = req; +exports.response = res; + +/** + * Expose constructors. + */ + +exports.Route = Route; +exports.Router = Router; + +/** + * Expose middleware + */ + +exports.query = require('./middleware/query'); +exports.static = require('serve-static'); + +/** + * Replace removed middleware with an appropriate error message. + */ + +[ + 'json', + 'urlencoded', + 'bodyParser', + 'compress', + 'cookieSession', + 'session', + 'logger', + 'cookieParser', + 'favicon', + 'responseTime', + 'errorHandler', + 'timeout', + 'methodOverride', + 'vhost', + 'csrf', + 'directory', + 'limit', + 'multipart', + 'staticCache', +].forEach(function (name) { + Object.defineProperty(exports, name, { + get: function () { + throw new Error('Most middleware (like ' + name + ') is no longer bundled with Express and must be installed separately. Please see https://github.com/senchalabs/connect#middleware.'); + }, + configurable: true + }); +}); diff --git a/node_modules/express/lib/middleware/init.js b/node_modules/express/lib/middleware/init.js new file mode 100644 index 0000000..c09cf0c --- /dev/null +++ b/node_modules/express/lib/middleware/init.js @@ -0,0 +1,26 @@ +/** + * Initialization middleware, exposing the + * request and response to eachother, as well + * as defaulting the X-Powered-By header field. + * + * @param {Function} app + * @return {Function} + * @api private + */ + +exports.init = function(app){ + return function expressInit(req, res, next){ + if (app.enabled('x-powered-by')) res.setHeader('X-Powered-By', 'Express'); + req.res = res; + res.req = req; + req.next = next; + + req.__proto__ = app.request; + res.__proto__ = app.response; + + res.locals = res.locals || Object.create(null); + + next(); + }; +}; + diff --git a/node_modules/express/lib/middleware/query.js b/node_modules/express/lib/middleware/query.js new file mode 100644 index 0000000..092bbd9 --- /dev/null +++ b/node_modules/express/lib/middleware/query.js @@ -0,0 +1,30 @@ +/** + * Module dependencies. + */ + +var parseUrl = require('parseurl'); +var qs = require('qs'); + +/** + * @param {Object} options + * @return {Function} + * @api public + */ + +module.exports = function query(options) { + var queryparse = qs.parse; + + if (typeof options === 'function') { + queryparse = options; + options = undefined; + } + + return function query(req, res, next){ + if (!req.query) { + var val = parseUrl(req).query; + req.query = queryparse(val, options); + } + + next(); + }; +}; diff --git a/node_modules/express/lib/request.js b/node_modules/express/lib/request.js new file mode 100644 index 0000000..483ee1c --- /dev/null +++ b/node_modules/express/lib/request.js @@ -0,0 +1,460 @@ +/** + * Module dependencies. + */ + +var accepts = require('accepts'); +var deprecate = require('depd')('express'); +var isIP = require('net').isIP; +var typeis = require('type-is'); +var http = require('http'); +var fresh = require('fresh'); +var parseRange = require('range-parser'); +var parse = require('parseurl'); +var proxyaddr = require('proxy-addr'); + +/** + * Request prototype. + */ + +var req = exports = module.exports = { + __proto__: http.IncomingMessage.prototype +}; + +/** + * Return request header. + * + * The `Referrer` header field is special-cased, + * both `Referrer` and `Referer` are interchangeable. + * + * Examples: + * + * req.get('Content-Type'); + * // => "text/plain" + * + * req.get('content-type'); + * // => "text/plain" + * + * req.get('Something'); + * // => undefined + * + * Aliased as `req.header()`. + * + * @param {String} name + * @return {String} + * @api public + */ + +req.get = +req.header = function(name){ + switch (name = name.toLowerCase()) { + case 'referer': + case 'referrer': + return this.headers.referrer + || this.headers.referer; + default: + return this.headers[name]; + } +}; + +/** + * To do: update docs. + * + * Check if the given `type(s)` is acceptable, returning + * the best match when true, otherwise `undefined`, in which + * case you should respond with 406 "Not Acceptable". + * + * The `type` value may be a single mime type string + * such as "application/json", the extension name + * such as "json", a comma-delimted list such as "json, html, text/plain", + * an argument list such as `"json", "html", "text/plain"`, + * or an array `["json", "html", "text/plain"]`. When a list + * or array is given the _best_ match, if any is returned. + * + * Examples: + * + * // Accept: text/html + * req.accepts('html'); + * // => "html" + * + * // Accept: text/*, application/json + * req.accepts('html'); + * // => "html" + * req.accepts('text/html'); + * // => "text/html" + * req.accepts('json, text'); + * // => "json" + * req.accepts('application/json'); + * // => "application/json" + * + * // Accept: text/*, application/json + * req.accepts('image/png'); + * req.accepts('png'); + * // => undefined + * + * // Accept: text/*;q=.5, application/json + * req.accepts(['html', 'json']); + * req.accepts('html', 'json'); + * req.accepts('html, json'); + * // => "json" + * + * @param {String|Array} type(s) + * @return {String} + * @api public + */ + +req.accepts = function(){ + var accept = accepts(this); + return accept.types.apply(accept, arguments); +}; + +/** + * Check if the given `encoding`s are accepted. + * + * @param {String} ...encoding + * @return {Boolean} + * @api public + */ + +req.acceptsEncodings = function(){ + var accept = accepts(this); + return accept.encodings.apply(accept, arguments); +}; + +req.acceptsEncoding = deprecate.function(req.acceptsEncodings, + 'req.acceptsEncoding: Use acceptsEncodings instead'); + +/** + * Check if the given `charset`s are acceptable, + * otherwise you should respond with 406 "Not Acceptable". + * + * @param {String} ...charset + * @return {Boolean} + * @api public + */ + +req.acceptsCharsets = function(){ + var accept = accepts(this); + return accept.charsets.apply(accept, arguments); +}; + +req.acceptsCharset = deprecate.function(req.acceptsCharsets, + 'req.acceptsCharset: Use acceptsCharsets instead'); + +/** + * Check if the given `lang`s are acceptable, + * otherwise you should respond with 406 "Not Acceptable". + * + * @param {String} ...lang + * @return {Boolean} + * @api public + */ + +req.acceptsLanguages = function(){ + var accept = accepts(this); + return accept.languages.apply(accept, arguments); +}; + +req.acceptsLanguage = deprecate.function(req.acceptsLanguages, + 'req.acceptsLanguage: Use acceptsLanguages instead'); + +/** + * Parse Range header field, + * capping to the given `size`. + * + * Unspecified ranges such as "0-" require + * knowledge of your resource length. In + * the case of a byte range this is of course + * the total number of bytes. If the Range + * header field is not given `null` is returned, + * `-1` when unsatisfiable, `-2` when syntactically invalid. + * + * NOTE: remember that ranges are inclusive, so + * for example "Range: users=0-3" should respond + * with 4 users when available, not 3. + * + * @param {Number} size + * @return {Array} + * @api public + */ + +req.range = function(size){ + var range = this.get('Range'); + if (!range) return; + return parseRange(size, range); +}; + +/** + * Return the value of param `name` when present or `defaultValue`. + * + * - Checks route placeholders, ex: _/user/:id_ + * - Checks body params, ex: id=12, {"id":12} + * - Checks query string params, ex: ?id=12 + * + * To utilize request bodies, `req.body` + * should be an object. This can be done by using + * the `bodyParser()` middleware. + * + * @param {String} name + * @param {Mixed} [defaultValue] + * @return {String} + * @api public + */ + +req.param = function(name, defaultValue){ + var params = this.params || {}; + var body = this.body || {}; + var query = this.query || {}; + if (null != params[name] && params.hasOwnProperty(name)) return params[name]; + if (null != body[name]) return body[name]; + if (null != query[name]) return query[name]; + return defaultValue; +}; + +/** + * Check if the incoming request contains the "Content-Type" + * header field, and it contains the give mime `type`. + * + * Examples: + * + * // With Content-Type: text/html; charset=utf-8 + * req.is('html'); + * req.is('text/html'); + * req.is('text/*'); + * // => true + * + * // When Content-Type is application/json + * req.is('json'); + * req.is('application/json'); + * req.is('application/*'); + * // => true + * + * req.is('html'); + * // => false + * + * @param {String} type + * @return {Boolean} + * @api public + */ + +req.is = function(types){ + if (!Array.isArray(types)) types = [].slice.call(arguments); + return typeis(this, types); +}; + +/** + * Return the protocol string "http" or "https" + * when requested with TLS. When the "trust proxy" + * setting trusts the socket address, the + * "X-Forwarded-Proto" header field will be trusted + * and used if present. + * + * If you're running behind a reverse proxy that + * supplies https for you this may be enabled. + * + * @return {String} + * @api public + */ + +defineGetter(req, 'protocol', function protocol(){ + var proto = this.connection.encrypted + ? 'https' + : 'http'; + var trust = this.app.get('trust proxy fn'); + + if (!trust(this.connection.remoteAddress)) { + return proto; + } + + // Note: X-Forwarded-Proto is normally only ever a + // single value, but this is to be safe. + proto = this.get('X-Forwarded-Proto') || proto; + return proto.split(/\s*,\s*/)[0]; +}); + +/** + * Short-hand for: + * + * req.protocol == 'https' + * + * @return {Boolean} + * @api public + */ + +defineGetter(req, 'secure', function secure(){ + return 'https' == this.protocol; +}); + +/** + * Return the remote address from the trusted proxy. + * + * The is the remote address on the socket unless + * "trust proxy" is set. + * + * @return {String} + * @api public + */ + +defineGetter(req, 'ip', function ip(){ + var trust = this.app.get('trust proxy fn'); + return proxyaddr(this, trust); +}); + +/** + * When "trust proxy" is set, trusted proxy addresses + client. + * + * For example if the value were "client, proxy1, proxy2" + * you would receive the array `["client", "proxy1", "proxy2"]` + * where "proxy2" is the furthest down-stream and "proxy1" and + * "proxy2" were trusted. + * + * @return {Array} + * @api public + */ + +defineGetter(req, 'ips', function ips() { + var trust = this.app.get('trust proxy fn'); + var addrs = proxyaddr.all(this, trust); + return addrs.slice(1).reverse(); +}); + +/** + * Return subdomains as an array. + * + * Subdomains are the dot-separated parts of the host before the main domain of + * the app. By default, the domain of the app is assumed to be the last two + * parts of the host. This can be changed by setting "subdomain offset". + * + * For example, if the domain is "tobi.ferrets.example.com": + * If "subdomain offset" is not set, req.subdomains is `["ferrets", "tobi"]`. + * If "subdomain offset" is 3, req.subdomains is `["tobi"]`. + * + * @return {Array} + * @api public + */ + +defineGetter(req, 'subdomains', function subdomains() { + var hostname = this.hostname; + + if (!hostname) return []; + + var offset = this.app.get('subdomain offset'); + var subdomains = !isIP(hostname) + ? hostname.split('.').reverse() + : [hostname]; + + return subdomains.slice(offset); +}); + +/** + * Short-hand for `url.parse(req.url).pathname`. + * + * @return {String} + * @api public + */ + +defineGetter(req, 'path', function path() { + return parse(this).pathname; +}); + +/** + * Parse the "Host" header field to a hostname. + * + * When the "trust proxy" setting trusts the socket + * address, the "X-Forwarded-Host" header field will + * be trusted. + * + * @return {String} + * @api public + */ + +defineGetter(req, 'hostname', function hostname(){ + var trust = this.app.get('trust proxy fn'); + var host = this.get('X-Forwarded-Host'); + + if (!host || !trust(this.connection.remoteAddress)) { + host = this.get('Host'); + } + + if (!host) return; + + // IPv6 literal support + var offset = host[0] === '[' + ? host.indexOf(']') + 1 + : 0; + var index = host.indexOf(':', offset); + + return ~index + ? host.substring(0, index) + : host; +}); + +// TODO: change req.host to return host in next major + +defineGetter(req, 'host', deprecate.function(function host(){ + return this.hostname; +}, 'req.host: Use req.hostname instead')); + +/** + * Check if the request is fresh, aka + * Last-Modified and/or the ETag + * still match. + * + * @return {Boolean} + * @api public + */ + +defineGetter(req, 'fresh', function(){ + var method = this.method; + var s = this.res.statusCode; + + // GET or HEAD for weak freshness validation only + if ('GET' != method && 'HEAD' != method) return false; + + // 2xx or 304 as per rfc2616 14.26 + if ((s >= 200 && s < 300) || 304 == s) { + return fresh(this.headers, this.res._headers); + } + + return false; +}); + +/** + * Check if the request is stale, aka + * "Last-Modified" and / or the "ETag" for the + * resource has changed. + * + * @return {Boolean} + * @api public + */ + +defineGetter(req, 'stale', function stale(){ + return !this.fresh; +}); + +/** + * Check if the request was an _XMLHttpRequest_. + * + * @return {Boolean} + * @api public + */ + +defineGetter(req, 'xhr', function xhr(){ + var val = this.get('X-Requested-With') || ''; + return 'xmlhttprequest' == val.toLowerCase(); +}); + +/** + * Helper function for creating a getter on an object. + * + * @param {Object} obj + * @param {String} name + * @param {Function} getter + * @api private + */ +function defineGetter(obj, name, getter) { + Object.defineProperty(obj, name, { + configurable: true, + enumerable: true, + get: getter + }); +}; diff --git a/node_modules/express/lib/response.js b/node_modules/express/lib/response.js new file mode 100644 index 0000000..879dd98 --- /dev/null +++ b/node_modules/express/lib/response.js @@ -0,0 +1,967 @@ +/** + * Module dependencies. + */ + +var deprecate = require('depd')('express'); +var escapeHtml = require('escape-html'); +var http = require('http'); +var isAbsolute = require('./utils').isAbsolute; +var onFinished = require('on-finished'); +var path = require('path'); +var mixin = require('utils-merge'); +var sign = require('cookie-signature').sign; +var normalizeType = require('./utils').normalizeType; +var normalizeTypes = require('./utils').normalizeTypes; +var setCharset = require('./utils').setCharset; +var contentDisposition = require('./utils').contentDisposition; +var statusCodes = http.STATUS_CODES; +var cookie = require('cookie'); +var send = require('send'); +var extname = path.extname; +var mime = send.mime; +var resolve = path.resolve; +var vary = require('vary'); + +/** + * Response prototype. + */ + +var res = module.exports = { + __proto__: http.ServerResponse.prototype +}; + +/** + * Set status `code`. + * + * @param {Number} code + * @return {ServerResponse} + * @api public + */ + +res.status = function(code){ + this.statusCode = code; + return this; +}; + +/** + * Set Link header field with the given `links`. + * + * Examples: + * + * res.links({ + * next: 'http://api.example.com/users?page=2', + * last: 'http://api.example.com/users?page=5' + * }); + * + * @param {Object} links + * @return {ServerResponse} + * @api public + */ + +res.links = function(links){ + var link = this.get('Link') || ''; + if (link) link += ', '; + return this.set('Link', link + Object.keys(links).map(function(rel){ + return '<' + links[rel] + '>; rel="' + rel + '"'; + }).join(', ')); +}; + +/** + * Send a response. + * + * Examples: + * + * res.send(new Buffer('wahoo')); + * res.send({ some: 'json' }); + * res.send('

    some html

    '); + * + * @param {string|number|boolean|object|Buffer} body + * @api public + */ + +res.send = function send(body) { + var chunk = body; + var encoding; + var len; + var req = this.req; + var type; + + // settings + var app = this.app; + + // allow status / body + if (arguments.length === 2) { + // res.send(body, status) backwards compat + if (typeof arguments[0] !== 'number' && typeof arguments[1] === 'number') { + deprecate('res.send(body, status): Use res.status(status).send(body) instead'); + this.statusCode = arguments[1]; + } else { + deprecate('res.send(status, body): Use res.status(status).send(body) instead'); + this.statusCode = arguments[0]; + chunk = arguments[1]; + } + } + + // disambiguate res.send(status) and res.send(status, num) + if (typeof chunk === 'number' && arguments.length === 1) { + // res.send(status) will set status message as text string + if (!this.get('Content-Type')) { + this.type('txt'); + } + + deprecate('res.send(status): Use res.status(status).end() instead'); + this.statusCode = chunk; + chunk = http.STATUS_CODES[chunk]; + } + + switch (typeof chunk) { + // string defaulting to html + case 'string': + if (!this.get('Content-Type')) { + this.type('html'); + } + break; + case 'boolean': + case 'number': + case 'object': + if (chunk === null) { + chunk = ''; + } else if (Buffer.isBuffer(chunk)) { + if (!this.get('Content-Type')) { + this.type('bin'); + } + } else { + return this.json(chunk); + } + break; + } + + // write strings in utf-8 + if (typeof chunk === 'string') { + encoding = 'utf8'; + type = this.get('Content-Type'); + + // reflect this in content-type + if (typeof type === 'string') { + this.set('Content-Type', setCharset(type, 'utf-8')); + } + } + + // populate Content-Length + if (chunk !== undefined) { + if (!Buffer.isBuffer(chunk)) { + // convert chunk to Buffer; saves later double conversions + chunk = new Buffer(chunk, encoding); + encoding = undefined; + } + + len = chunk.length; + this.set('Content-Length', len); + } + + // method check + var isHead = req.method === 'HEAD'; + + // ETag support + if (len !== undefined && (isHead || req.method === 'GET')) { + var etag = app.get('etag fn'); + if (etag && !this.get('ETag')) { + etag = etag(chunk, encoding); + etag && this.set('ETag', etag); + } + } + + // freshness + if (req.fresh) this.statusCode = 304; + + // strip irrelevant headers + if (204 == this.statusCode || 304 == this.statusCode) { + this.removeHeader('Content-Type'); + this.removeHeader('Content-Length'); + this.removeHeader('Transfer-Encoding'); + chunk = ''; + } + + // skip body for HEAD + if (isHead) { + this.end(); + } + + // respond + this.end(chunk, encoding); + + return this; +}; + +/** + * Send JSON response. + * + * Examples: + * + * res.json(null); + * res.json({ user: 'tj' }); + * + * @param {string|number|boolean|object} obj + * @api public + */ + +res.json = function json(obj) { + var val = obj; + + // allow status / body + if (arguments.length === 2) { + // res.json(body, status) backwards compat + if (typeof arguments[1] === 'number') { + deprecate('res.json(obj, status): Use res.status(status).json(obj) instead'); + this.statusCode = arguments[1]; + } else { + deprecate('res.json(status, obj): Use res.status(status).json(obj) instead'); + this.statusCode = arguments[0]; + val = arguments[1]; + } + } + + // settings + var app = this.app; + var replacer = app.get('json replacer'); + var spaces = app.get('json spaces'); + var body = JSON.stringify(val, replacer, spaces); + + // content-type + if (!this.get('Content-Type')) { + this.set('Content-Type', 'application/json'); + } + + return this.send(body); +}; + +/** + * Send JSON response with JSONP callback support. + * + * Examples: + * + * res.jsonp(null); + * res.jsonp({ user: 'tj' }); + * + * @param {string|number|boolean|object} obj + * @api public + */ + +res.jsonp = function jsonp(obj) { + var val = obj; + + // allow status / body + if (arguments.length === 2) { + // res.json(body, status) backwards compat + if (typeof arguments[1] === 'number') { + deprecate('res.jsonp(obj, status): Use res.status(status).json(obj) instead'); + this.statusCode = arguments[1]; + } else { + deprecate('res.jsonp(status, obj): Use res.status(status).jsonp(obj) instead'); + this.statusCode = arguments[0]; + val = arguments[1]; + } + } + + // settings + var app = this.app; + var replacer = app.get('json replacer'); + var spaces = app.get('json spaces'); + var body = JSON.stringify(val, replacer, spaces); + var callback = this.req.query[app.get('jsonp callback name')]; + + // content-type + if (!this.get('Content-Type')) { + this.set('X-Content-Type-Options', 'nosniff'); + this.set('Content-Type', 'application/json'); + } + + // fixup callback + if (Array.isArray(callback)) { + callback = callback[0]; + } + + // jsonp + if (typeof callback === 'string' && callback.length !== 0) { + this.charset = 'utf-8'; + this.set('X-Content-Type-Options', 'nosniff'); + this.set('Content-Type', 'text/javascript'); + + // restrict callback charset + callback = callback.replace(/[^\[\]\w$.]/g, ''); + + // replace chars not allowed in JavaScript that are in JSON + body = body + .replace(/\u2028/g, '\\u2028') + .replace(/\u2029/g, '\\u2029'); + + // the /**/ is a specific security mitigation for "Rosetta Flash JSONP abuse" + // the typeof check is just to reduce client error noise + body = '/**/ typeof ' + callback + ' === \'function\' && ' + callback + '(' + body + ');'; + } + + return this.send(body); +}; + +/** + * Send given HTTP status code. + * + * Sets the response status to `statusCode` and the body of the + * response to the standard description from node's http.STATUS_CODES + * or the statusCode number if no description. + * + * Examples: + * + * res.sendStatus(200); + * + * @param {number} statusCode + * @api public + */ + +res.sendStatus = function sendStatus(statusCode) { + var body = http.STATUS_CODES[statusCode] || String(statusCode); + + this.statusCode = statusCode; + this.type('txt'); + + return this.send(body); +}; + +/** + * Transfer the file at the given `path`. + * + * Automatically sets the _Content-Type_ response header field. + * The callback `fn(err)` is invoked when the transfer is complete + * or when an error occurs. Be sure to check `res.sentHeader` + * if you wish to attempt responding, as the header and some data + * may have already been transferred. + * + * Options: + * + * - `maxAge` defaulting to 0 (can be string converted by `ms`) + * - `root` root directory for relative filenames + * - `headers` object of headers to serve with file + * - `dotfiles` serve dotfiles, defaulting to false; can be `"allow"` to send them + * + * Other options are passed along to `send`. + * + * Examples: + * + * The following example illustrates how `res.sendFile()` may + * be used as an alternative for the `static()` middleware for + * dynamic situations. The code backing `res.sendFile()` is actually + * the same code, so HTTP cache support etc is identical. + * + * app.get('/user/:uid/photos/:file', function(req, res){ + * var uid = req.params.uid + * , file = req.params.file; + * + * req.user.mayViewFilesFrom(uid, function(yes){ + * if (yes) { + * res.sendFile('/uploads/' + uid + '/' + file); + * } else { + * res.send(403, 'Sorry! you cant see that.'); + * } + * }); + * }); + * + * @api public + */ + +res.sendFile = function sendFile(path, options, fn) { + var req = this.req; + var res = this; + var next = req.next; + + if (!path) { + throw new TypeError('path argument is required to res.sendFile'); + } + + // support function as second arg + if (typeof options === 'function') { + fn = options; + options = {}; + } + + options = options || {}; + + if (!options.root && !isAbsolute(path)) { + throw new TypeError('path must be absolute or specify root to res.sendFile'); + } + + // create file stream + var pathname = encodeURI(path); + var file = send(req, pathname, options); + + // transfer + sendfile(res, file, options, function (err) { + if (fn) return fn(err); + if (err && err.code === 'EISDIR') return next(); + + // next() all but aborted errors + if (err && err.code !== 'ECONNABORT') { + next(err); + } + }); +}; + +/** + * Transfer the file at the given `path`. + * + * Automatically sets the _Content-Type_ response header field. + * The callback `fn(err)` is invoked when the transfer is complete + * or when an error occurs. Be sure to check `res.sentHeader` + * if you wish to attempt responding, as the header and some data + * may have already been transferred. + * + * Options: + * + * - `maxAge` defaulting to 0 (can be string converted by `ms`) + * - `root` root directory for relative filenames + * - `headers` object of headers to serve with file + * - `dotfiles` serve dotfiles, defaulting to false; can be `"allow"` to send them + * + * Other options are passed along to `send`. + * + * Examples: + * + * The following example illustrates how `res.sendfile()` may + * be used as an alternative for the `static()` middleware for + * dynamic situations. The code backing `res.sendfile()` is actually + * the same code, so HTTP cache support etc is identical. + * + * app.get('/user/:uid/photos/:file', function(req, res){ + * var uid = req.params.uid + * , file = req.params.file; + * + * req.user.mayViewFilesFrom(uid, function(yes){ + * if (yes) { + * res.sendfile('/uploads/' + uid + '/' + file); + * } else { + * res.send(403, 'Sorry! you cant see that.'); + * } + * }); + * }); + * + * @api public + */ + +res.sendfile = function(path, options, fn){ + var req = this.req; + var res = this; + var next = req.next; + + // support function as second arg + if (typeof options === 'function') { + fn = options; + options = {}; + } + + options = options || {}; + + // create file stream + var file = send(req, path, options); + + // transfer + sendfile(res, file, options, function (err) { + if (fn) return fn(err); + if (err && err.code === 'EISDIR') return next(); + + // next() all but aborted errors + if (err && err.code !== 'ECONNABORT') { + next(err); + } + }); +}; + +res.sendfile = deprecate.function(res.sendfile, + 'res.sendfile: Use res.sendFile instead'); + +/** + * Transfer the file at the given `path` as an attachment. + * + * Optionally providing an alternate attachment `filename`, + * and optional callback `fn(err)`. The callback is invoked + * when the data transfer is complete, or when an error has + * ocurred. Be sure to check `res.headersSent` if you plan to respond. + * + * This method uses `res.sendfile()`. + * + * @api public + */ + +res.download = function download(path, filename, fn) { + // support function as second arg + if (typeof filename === 'function') { + fn = filename; + filename = null; + } + + filename = filename || path; + + // set Content-Disposition when file is sent + var headers = { + 'Content-Disposition': contentDisposition(filename) + }; + + // Resolve the full path for sendFile + var fullPath = resolve(path); + + return this.sendFile(fullPath, { headers: headers }, fn); +}; + +/** + * Set _Content-Type_ response header with `type` through `mime.lookup()` + * when it does not contain "/", or set the Content-Type to `type` otherwise. + * + * Examples: + * + * res.type('.html'); + * res.type('html'); + * res.type('json'); + * res.type('application/json'); + * res.type('png'); + * + * @param {String} type + * @return {ServerResponse} for chaining + * @api public + */ + +res.contentType = +res.type = function(type){ + return this.set('Content-Type', ~type.indexOf('/') + ? type + : mime.lookup(type)); +}; + +/** + * Respond to the Acceptable formats using an `obj` + * of mime-type callbacks. + * + * This method uses `req.accepted`, an array of + * acceptable types ordered by their quality values. + * When "Accept" is not present the _first_ callback + * is invoked, otherwise the first match is used. When + * no match is performed the server responds with + * 406 "Not Acceptable". + * + * Content-Type is set for you, however if you choose + * you may alter this within the callback using `res.type()` + * or `res.set('Content-Type', ...)`. + * + * res.format({ + * 'text/plain': function(){ + * res.send('hey'); + * }, + * + * 'text/html': function(){ + * res.send('

    hey

    '); + * }, + * + * 'appliation/json': function(){ + * res.send({ message: 'hey' }); + * } + * }); + * + * In addition to canonicalized MIME types you may + * also use extnames mapped to these types: + * + * res.format({ + * text: function(){ + * res.send('hey'); + * }, + * + * html: function(){ + * res.send('

    hey

    '); + * }, + * + * json: function(){ + * res.send({ message: 'hey' }); + * } + * }); + * + * By default Express passes an `Error` + * with a `.status` of 406 to `next(err)` + * if a match is not made. If you provide + * a `.default` callback it will be invoked + * instead. + * + * @param {Object} obj + * @return {ServerResponse} for chaining + * @api public + */ + +res.format = function(obj){ + var req = this.req; + var next = req.next; + + var fn = obj.default; + if (fn) delete obj.default; + var keys = Object.keys(obj); + + var key = req.accepts(keys); + + this.vary("Accept"); + + if (key) { + this.set('Content-Type', normalizeType(key).value); + obj[key](req, this, next); + } else if (fn) { + fn(); + } else { + var err = new Error('Not Acceptable'); + err.status = 406; + err.types = normalizeTypes(keys).map(function(o){ return o.value }); + next(err); + } + + return this; +}; + +/** + * Set _Content-Disposition_ header to _attachment_ with optional `filename`. + * + * @param {String} filename + * @return {ServerResponse} + * @api public + */ + +res.attachment = function(filename){ + if (filename) this.type(extname(filename)); + this.set('Content-Disposition', contentDisposition(filename)); + return this; +}; + +/** + * Set header `field` to `val`, or pass + * an object of header fields. + * + * Examples: + * + * res.set('Foo', ['bar', 'baz']); + * res.set('Accept', 'application/json'); + * res.set({ Accept: 'text/plain', 'X-API-Key': 'tobi' }); + * + * Aliased as `res.header()`. + * + * @param {String|Object|Array} field + * @param {String} val + * @return {ServerResponse} for chaining + * @api public + */ + +res.set = +res.header = function header(field, val) { + if (arguments.length === 2) { + if (Array.isArray(val)) val = val.map(String); + else val = String(val); + if ('content-type' == field.toLowerCase() && !/;\s*charset\s*=/.test(val)) { + var charset = mime.charsets.lookup(val.split(';')[0]); + if (charset) val += '; charset=' + charset.toLowerCase(); + } + this.setHeader(field, val); + } else { + for (var key in field) { + this.set(key, field[key]); + } + } + return this; +}; + +/** + * Get value for header `field`. + * + * @param {String} field + * @return {String} + * @api public + */ + +res.get = function(field){ + return this.getHeader(field); +}; + +/** + * Clear cookie `name`. + * + * @param {String} name + * @param {Object} options + * @return {ServerResponse} for chaining + * @api public + */ + +res.clearCookie = function(name, options){ + var opts = { expires: new Date(1), path: '/' }; + return this.cookie(name, '', options + ? mixin(opts, options) + : opts); +}; + +/** + * Set cookie `name` to `val`, with the given `options`. + * + * Options: + * + * - `maxAge` max-age in milliseconds, converted to `expires` + * - `signed` sign the cookie + * - `path` defaults to "/" + * + * Examples: + * + * // "Remember Me" for 15 minutes + * res.cookie('rememberme', '1', { expires: new Date(Date.now() + 900000), httpOnly: true }); + * + * // save as above + * res.cookie('rememberme', '1', { maxAge: 900000, httpOnly: true }) + * + * @param {String} name + * @param {String|Object} val + * @param {Options} options + * @return {ServerResponse} for chaining + * @api public + */ + +res.cookie = function(name, val, options){ + options = mixin({}, options); + var secret = this.req.secret; + var signed = options.signed; + if (signed && !secret) throw new Error('cookieParser("secret") required for signed cookies'); + if ('number' == typeof val) val = val.toString(); + if ('object' == typeof val) val = 'j:' + JSON.stringify(val); + if (signed) val = 's:' + sign(val, secret); + if ('maxAge' in options) { + options.expires = new Date(Date.now() + options.maxAge); + options.maxAge /= 1000; + } + if (null == options.path) options.path = '/'; + var headerVal = cookie.serialize(name, String(val), options); + + // supports multiple 'res.cookie' calls by getting previous value + var prev = this.get('Set-Cookie'); + if (prev) { + if (Array.isArray(prev)) { + headerVal = prev.concat(headerVal); + } else { + headerVal = [prev, headerVal]; + } + } + this.set('Set-Cookie', headerVal); + return this; +}; + + +/** + * Set the location header to `url`. + * + * The given `url` can also be "back", which redirects + * to the _Referrer_ or _Referer_ headers or "/". + * + * Examples: + * + * res.location('/foo/bar').; + * res.location('http://example.com'); + * res.location('../login'); + * + * @param {String} url + * @return {ServerResponse} for chaining + * @api public + */ + +res.location = function(url){ + var req = this.req; + + // "back" is an alias for the referrer + if ('back' == url) url = req.get('Referrer') || '/'; + + // Respond + this.set('Location', url); + return this; +}; + +/** + * Redirect to the given `url` with optional response `status` + * defaulting to 302. + * + * The resulting `url` is determined by `res.location()`, so + * it will play nicely with mounted apps, relative paths, + * `"back"` etc. + * + * Examples: + * + * res.redirect('/foo/bar'); + * res.redirect('http://example.com'); + * res.redirect(301, 'http://example.com'); + * res.redirect('../login'); // /blog/post/1 -> /blog/login + * + * @api public + */ + +res.redirect = function redirect(url) { + var address = url; + var body; + var status = 302; + + // allow status / url + if (arguments.length === 2) { + if (typeof arguments[0] === 'number') { + status = arguments[0]; + address = arguments[1]; + } else { + deprecate('res.redirect(ur, status): Use res.redirect(status, url) instead'); + status = arguments[1]; + } + } + + // Set location header + this.location(address); + address = this.get('Location'); + + // Support text/{plain,html} by default + this.format({ + text: function(){ + body = statusCodes[status] + '. Redirecting to ' + encodeURI(url); + }, + + html: function(){ + var u = escapeHtml(url); + body = '

    ' + statusCodes[status] + '. Redirecting to ' + u + '

    '; + }, + + default: function(){ + body = ''; + } + }); + + // Respond + this.statusCode = status; + this.set('Content-Length', Buffer.byteLength(body)); + + if (this.req.method === 'HEAD') { + this.end(); + } + + this.end(body); +}; + +/** + * Add `field` to Vary. If already present in the Vary set, then + * this call is simply ignored. + * + * @param {Array|String} field + * @return {ServerResponse} for chaining + * @api public + */ + +res.vary = function(field){ + // checks for back-compat + if (!field || (Array.isArray(field) && !field.length)) { + deprecate('res.vary(): Provide a field name'); + return this; + } + + vary(this, field); + + return this; +}; + +/** + * Render `view` with the given `options` and optional callback `fn`. + * When a callback function is given a response will _not_ be made + * automatically, otherwise a response of _200_ and _text/html_ is given. + * + * Options: + * + * - `cache` boolean hinting to the engine it should cache + * - `filename` filename of the view being rendered + * + * @api public + */ + +res.render = function(view, options, fn){ + options = options || {}; + var self = this; + var req = this.req; + var app = req.app; + + // support callback function as second arg + if ('function' == typeof options) { + fn = options, options = {}; + } + + // merge res.locals + options._locals = self.locals; + + // default callback to respond + fn = fn || function(err, str){ + if (err) return req.next(err); + self.send(str); + }; + + // render + app.render(view, options, fn); +}; + +// pipe the send file stream +function sendfile(res, file, options, callback) { + var done = false; + + // directory + function ondirectory() { + if (done) return; + done = true; + + var err = new Error('EISDIR, read'); + err.code = 'EISDIR'; + callback(err); + } + + // errors + function onerror(err) { + if (done) return; + done = true; + callback(err); + } + + // ended + function onend() { + if (done) return; + done = true; + callback(); + } + + // finished + function onfinish(err) { + if (err) return onerror(err); + if (done) return; + + setImmediate(function () { + if (done) return; + done = true; + + // response finished before end of file + var err = new Error('Request aborted'); + err.code = 'ECONNABORT'; + callback(err); + }); + } + + file.on('end', onend); + file.on('error', onerror); + file.on('directory', ondirectory); + onFinished(res, onfinish); + + if (options.headers) { + // set headers on successful transfer + file.on('headers', function headers(res) { + var obj = options.headers; + var keys = Object.keys(obj); + + for (var i = 0; i < keys.length; i++) { + var k = keys[i]; + res.setHeader(k, obj[k]); + } + }); + } + + // pipe + file.pipe(res); +} diff --git a/node_modules/express/lib/router/index.js b/node_modules/express/lib/router/index.js new file mode 100644 index 0000000..64fcd1e --- /dev/null +++ b/node_modules/express/lib/router/index.js @@ -0,0 +1,576 @@ + +/** + * Module dependencies. + */ + +var Route = require('./route'); +var Layer = require('./layer'); +var methods = require('methods'); +var mixin = require('utils-merge'); +var debug = require('debug')('express:router'); +var parseUrl = require('parseurl'); +var utils = require('../utils'); + +/** + * Module variables. + */ + +var objectRegExp = /^\[object (\S+)\]$/; +var slice = Array.prototype.slice; +var toString = Object.prototype.toString; + +/** + * Initialize a new `Router` with the given `options`. + * + * @param {Object} options + * @return {Router} which is an callable function + * @api public + */ + +var proto = module.exports = function(options) { + options = options || {}; + + function router(req, res, next) { + router.handle(req, res, next); + } + + // mixin Router class functions + router.__proto__ = proto; + + router.params = {}; + router._params = []; + router.caseSensitive = options.caseSensitive; + router.mergeParams = options.mergeParams; + router.strict = options.strict; + router.stack = []; + + return router; +}; + +/** + * Map the given param placeholder `name`(s) to the given callback. + * + * Parameter mapping is used to provide pre-conditions to routes + * which use normalized placeholders. For example a _:user_id_ parameter + * could automatically load a user's information from the database without + * any additional code, + * + * The callback uses the same signature as middleware, the only difference + * being that the value of the placeholder is passed, in this case the _id_ + * of the user. Once the `next()` function is invoked, just like middleware + * it will continue on to execute the route, or subsequent parameter functions. + * + * Just like in middleware, you must either respond to the request or call next + * to avoid stalling the request. + * + * app.param('user_id', function(req, res, next, id){ + * User.find(id, function(err, user){ + * if (err) { + * return next(err); + * } else if (!user) { + * return next(new Error('failed to load user')); + * } + * req.user = user; + * next(); + * }); + * }); + * + * @param {String} name + * @param {Function} fn + * @return {app} for chaining + * @api public + */ + +proto.param = function(name, fn){ + // param logic + if ('function' == typeof name) { + this._params.push(name); + return; + } + + // apply param functions + var params = this._params; + var len = params.length; + var ret; + + if (name[0] === ':') { + name = name.substr(1); + } + + for (var i = 0; i < len; ++i) { + if (ret = params[i](name, fn)) { + fn = ret; + } + } + + // ensure we end up with a + // middleware function + if ('function' != typeof fn) { + throw new Error('invalid param() call for ' + name + ', got ' + fn); + } + + (this.params[name] = this.params[name] || []).push(fn); + return this; +}; + +/** + * Dispatch a req, res into the router. + * + * @api private + */ + +proto.handle = function(req, res, done) { + var self = this; + + debug('dispatching %s %s', req.method, req.url); + + var search = 1 + req.url.indexOf('?'); + var pathlength = search ? search - 1 : req.url.length; + var fqdn = 1 + req.url.substr(0, pathlength).indexOf('://'); + var protohost = fqdn ? req.url.substr(0, req.url.indexOf('/', 2 + fqdn)) : ''; + var idx = 0; + var removed = ''; + var slashAdded = false; + var paramcalled = {}; + + // store options for OPTIONS request + // only used if OPTIONS request + var options = []; + + // middleware and routes + var stack = self.stack; + + // manage inter-router variables + var parentParams = req.params; + var parentUrl = req.baseUrl || ''; + done = restore(done, req, 'baseUrl', 'next', 'params'); + + // setup next layer + req.next = next; + + // for options requests, respond with a default if nothing else responds + if (req.method === 'OPTIONS') { + done = wrap(done, function(old, err) { + if (err || options.length === 0) return old(err); + + var body = options.join(','); + return res.set('Allow', body).send(body); + }); + } + + // setup basic req values + req.baseUrl = parentUrl; + req.originalUrl = req.originalUrl || req.url; + + next(); + + function next(err) { + var layerError = err === 'route' + ? null + : err; + + var layer = stack[idx++]; + + if (slashAdded) { + req.url = req.url.substr(1); + slashAdded = false; + } + + if (removed.length !== 0) { + req.baseUrl = parentUrl; + req.url = protohost + removed + req.url.substr(protohost.length); + removed = ''; + } + + if (!layer) { + return done(layerError); + } + + self.match_layer(layer, req, res, function (err, path) { + if (err || path === undefined) { + return next(layerError || err); + } + + // route object and not middleware + var route = layer.route; + + // if final route, then we support options + if (route) { + // we don't run any routes with error first + if (layerError) { + return next(layerError); + } + + var method = req.method; + var has_method = route._handles_method(method); + + // build up automatic options response + if (!has_method && method === 'OPTIONS') { + options.push.apply(options, route._options()); + } + + // don't even bother + if (!has_method && method !== 'HEAD') { + return next(); + } + + // we can now dispatch to the route + req.route = route; + } + + // Capture one-time layer values + req.params = self.mergeParams + ? mergeParams(layer.params, parentParams) + : layer.params; + var layerPath = layer.path; + + // this should be done for the layer + self.process_params(layer, paramcalled, req, res, function (err) { + if (err) { + return next(layerError || err); + } + + if (route) { + return layer.handle_request(req, res, next); + } + + trim_prefix(layer, layerError, layerPath, path); + }); + }); + } + + function trim_prefix(layer, layerError, layerPath, path) { + var c = path[layerPath.length]; + if (c && '/' !== c && '.' !== c) return next(layerError); + + // Trim off the part of the url that matches the route + // middleware (.use stuff) needs to have the path stripped + if (layerPath.length !== 0) { + debug('trim prefix (%s) from url %s', layerPath, req.url); + removed = layerPath; + req.url = protohost + req.url.substr(protohost.length + removed.length); + + // Ensure leading slash + if (!fqdn && req.url[0] !== '/') { + req.url = '/' + req.url; + slashAdded = true; + } + + // Setup base URL (no trailing slash) + req.baseUrl = parentUrl + (removed[removed.length - 1] === '/' + ? removed.substring(0, removed.length - 1) + : removed); + } + + debug('%s %s : %s', layer.name, layerPath, req.originalUrl); + + if (layerError) { + layer.handle_error(layerError, req, res, next); + } else { + layer.handle_request(req, res, next); + } + } +}; + +/** + * Match request to a layer. + * + * @api private + */ + +proto.match_layer = function match_layer(layer, req, res, done) { + var error = null; + var path; + + try { + path = parseUrl(req).pathname; + + if (!layer.match(path)) { + path = undefined; + } + } catch (err) { + error = err; + } + + done(error, path); +}; + +/** + * Process any parameters for the layer. + * + * @api private + */ + +proto.process_params = function(layer, called, req, res, done) { + var params = this.params; + + // captured parameters from the layer, keys and values + var keys = layer.keys; + + // fast track + if (!keys || keys.length === 0) { + return done(); + } + + var i = 0; + var name; + var paramIndex = 0; + var key; + var paramVal; + var paramCallbacks; + var paramCalled; + + // process params in order + // param callbacks can be async + function param(err) { + if (err) { + return done(err); + } + + if (i >= keys.length ) { + return done(); + } + + paramIndex = 0; + key = keys[i++]; + + if (!key) { + return done(); + } + + name = key.name; + paramVal = req.params[name]; + paramCallbacks = params[name]; + paramCalled = called[name]; + + if (paramVal === undefined || !paramCallbacks) { + return param(); + } + + // param previously called with same value or error occurred + if (paramCalled && (paramCalled.error || paramCalled.match === paramVal)) { + // restore value + req.params[name] = paramCalled.value; + + // next param + return param(paramCalled.error); + } + + called[name] = paramCalled = { + error: null, + match: paramVal, + value: paramVal + }; + + paramCallback(); + } + + // single param callbacks + function paramCallback(err) { + var fn = paramCallbacks[paramIndex++]; + + // store updated value + paramCalled.value = req.params[key.name]; + + if (err) { + // store error + paramCalled.error = err; + param(err); + return; + } + + if (!fn) return param(); + + try { + fn(req, res, paramCallback, paramVal, key.name); + } catch (e) { + paramCallback(e); + } + } + + param(); +}; + +/** + * Use the given middleware function, with optional path, defaulting to "/". + * + * Use (like `.all`) will run for any http METHOD, but it will not add + * handlers for those methods so OPTIONS requests will not consider `.use` + * functions even if they could respond. + * + * The other difference is that _route_ path is stripped and not visible + * to the handler function. The main effect of this feature is that mounted + * handlers can operate without any code changes regardless of the "prefix" + * pathname. + * + * @api public + */ + +proto.use = function use(fn) { + var offset = 0; + var path = '/'; + var self = this; + + // default path to '/' + // disambiguate router.use([fn]) + if (typeof fn !== 'function') { + var arg = fn; + + while (Array.isArray(arg) && arg.length !== 0) { + arg = arg[0]; + } + + // first arg is the path + if (typeof arg !== 'function') { + offset = 1; + path = fn; + } + } + + var callbacks = utils.flatten(slice.call(arguments, offset)); + + if (callbacks.length === 0) { + throw new TypeError('Router.use() requires middleware functions'); + } + + callbacks.forEach(function (fn) { + if (typeof fn !== 'function') { + throw new TypeError('Router.use() requires middleware function but got a ' + gettype(fn)); + } + + // add the middleware + debug('use %s %s', path, fn.name || ''); + + var layer = new Layer(path, { + sensitive: self.caseSensitive, + strict: false, + end: false + }, fn); + + layer.route = undefined; + + self.stack.push(layer); + }); + + return this; +}; + +/** + * Create a new Route for the given path. + * + * Each route contains a separate middleware stack and VERB handlers. + * + * See the Route api documentation for details on adding handlers + * and middleware to routes. + * + * @param {String} path + * @return {Route} + * @api public + */ + +proto.route = function(path){ + var route = new Route(path); + + var layer = new Layer(path, { + sensitive: this.caseSensitive, + strict: this.strict, + end: true + }, route.dispatch.bind(route)); + + layer.route = route; + + this.stack.push(layer); + return route; +}; + +// create Router#VERB functions +methods.concat('all').forEach(function(method){ + proto[method] = function(path){ + var route = this.route(path) + route[method].apply(route, slice.call(arguments, 1)); + return this; + }; +}); + +// get type for error message +function gettype(obj) { + var type = typeof obj; + + if (type !== 'object') { + return type; + } + + // inspect [[Class]] for objects + return toString.call(obj) + .replace(objectRegExp, '$1'); +} + +// merge params with parent params +function mergeParams(params, parent) { + if (typeof parent !== 'object' || !parent) { + return params; + } + + // make copy of parent for base + var obj = mixin({}, parent); + + // simple non-numeric merging + if (!(0 in params) || !(0 in parent)) { + return mixin(obj, params); + } + + var i = 0; + var o = 0; + + // determine numeric gaps + while (i === o || o in parent) { + if (i in params) i++; + if (o in parent) o++; + } + + // offset numeric indices in params before merge + for (i--; i >= 0; i--) { + params[i + o] = params[i]; + + // create holes for the merge when necessary + if (i < o) { + delete params[i]; + } + } + + return mixin(parent, params); +} + +// restore obj props after function +function restore(fn, obj) { + var props = new Array(arguments.length - 2); + var vals = new Array(arguments.length - 2); + + for (var i = 0; i < props.length; i++) { + props[i] = arguments[i + 2]; + vals[i] = obj[props[i]]; + } + + return function(err){ + // restore vals + for (var i = 0; i < props.length; i++) { + obj[props[i]] = vals[i]; + } + + return fn.apply(this, arguments); + }; +} + +// wrap a function +function wrap(old, fn) { + return function proxy() { + var args = new Array(arguments.length + 1); + + args[0] = old; + for (var i = 0, len = arguments.length; i < len; i++) { + args[i + 1] = arguments[i]; + } + + fn.apply(this, args); + }; +} diff --git a/node_modules/express/lib/router/layer.js b/node_modules/express/lib/router/layer.js new file mode 100644 index 0000000..e292a13 --- /dev/null +++ b/node_modules/express/lib/router/layer.js @@ -0,0 +1,151 @@ +/** + * Module dependencies. + */ + +var pathRegexp = require('path-to-regexp'); +var debug = require('debug')('express:router:layer'); + +/** + * Expose `Layer`. + */ + +module.exports = Layer; + +function Layer(path, options, fn) { + if (!(this instanceof Layer)) { + return new Layer(path, options, fn); + } + + debug('new %s', path); + options = options || {}; + + this.handle = fn; + this.name = fn.name || ''; + this.params = undefined; + this.path = undefined; + this.regexp = pathRegexp(path, this.keys = [], options); + + if (path === '/' && options.end === false) { + this.regexp.fast_slash = true; + } +} + +/** + * Handle the error for the layer. + * + * @param {Error} error + * @param {Request} req + * @param {Response} res + * @param {function} next + * @api private + */ + +Layer.prototype.handle_error = function handle_error(error, req, res, next) { + var fn = this.handle; + + if (fn.length !== 4) { + // not a standard error handler + return next(error); + } + + try { + fn(error, req, res, next); + } catch (err) { + next(err); + } +}; + +/** + * Handle the request for the layer. + * + * @param {Request} req + * @param {Response} res + * @param {function} next + * @api private + */ + +Layer.prototype.handle_request = function handle(req, res, next) { + var fn = this.handle; + + if (fn.length > 3) { + // not a standard request handler + return next(); + } + + try { + fn(req, res, next); + } catch (err) { + next(err); + } +}; + +/** + * Check if this route matches `path`, if so + * populate `.params`. + * + * @param {String} path + * @return {Boolean} + * @api private + */ + +Layer.prototype.match = function match(path) { + if (this.regexp.fast_slash) { + // fast path non-ending match for / (everything matches) + this.params = {}; + this.path = ''; + return true; + } + + var m = this.regexp.exec(path); + + if (!m) { + this.params = undefined; + this.path = undefined; + return false; + } + + // store values + this.params = {}; + this.path = m[0]; + + var keys = this.keys; + var params = this.params; + var n = 0; + var key; + var val; + + for (var i = 1, len = m.length; i < len; ++i) { + key = keys[i - 1]; + val = decode_param(m[i]); + + if (key) { + params[key.name] = val; + } else { + params[n++] = val; + } + } + + return true; +}; + +/** + * Decode param value. + * + * @param {string} val + * @return {string} + * @api private + */ + +function decode_param(val){ + if (typeof val !== 'string') { + return val; + } + + try { + return decodeURIComponent(val); + } catch (e) { + var err = new TypeError("Failed to decode param '" + val + "'"); + err.status = 400; + throw err; + } +} diff --git a/node_modules/express/lib/router/match.js b/node_modules/express/lib/router/match.js new file mode 100644 index 0000000..9afebfc --- /dev/null +++ b/node_modules/express/lib/router/match.js @@ -0,0 +1,56 @@ + +/** + * Expose `Layer`. + */ + +module.exports = Match; + +function Match(layer, path, params) { + this.layer = layer; + this.params = {}; + this.path = path || ''; + + if (!params) { + return this; + } + + var keys = layer.keys; + var n = 0; + var prop; + var key; + var val; + + for (var i = 0; i < params.length; i++) { + key = keys[i]; + val = decode_param(params[i]); + prop = key + ? key.name + : n++; + + this.params[prop] = val; + } + + return this; +}; + +/** + * Decode param value. + * + * @param {string} val + * @return {string} + * @api private + */ + +function decode_param(val){ + if (typeof val !== 'string') { + return val; + } + + try { + return decodeURIComponent(val); + } catch (e) { + var err = new TypeError("Failed to decode param '" + val + "'"); + err.status = 400; + throw err; + } +} diff --git a/node_modules/express/lib/router/route.js b/node_modules/express/lib/router/route.js new file mode 100644 index 0000000..6b39211 --- /dev/null +++ b/node_modules/express/lib/router/route.js @@ -0,0 +1,175 @@ +/** + * Module dependencies. + */ + +var debug = require('debug')('express:router:route'); +var Layer = require('./layer'); +var methods = require('methods'); +var utils = require('../utils'); + +/** + * Expose `Route`. + */ + +module.exports = Route; + +/** + * Initialize `Route` with the given `path`, + * + * @param {String} path + * @api private + */ + +function Route(path) { + debug('new %s', path); + this.path = path; + this.stack = []; + + // route handlers for various http methods + this.methods = {}; +} + +/** + * @api private + */ + +Route.prototype._handles_method = function _handles_method(method) { + if (this.methods._all) { + return true; + } + + method = method.toLowerCase(); + + if (method === 'head' && !this.methods['head']) { + method = 'get'; + } + + return Boolean(this.methods[method]); +}; + +/** + * @return {Array} supported HTTP methods + * @api private + */ + +Route.prototype._options = function(){ + return Object.keys(this.methods).map(function(method) { + return method.toUpperCase(); + }); +}; + +/** + * dispatch req, res into this route + * + * @api private + */ + +Route.prototype.dispatch = function(req, res, done){ + var idx = 0; + var stack = this.stack; + if (stack.length === 0) { + return done(); + } + + var method = req.method.toLowerCase(); + if (method === 'head' && !this.methods['head']) { + method = 'get'; + } + + req.route = this; + + next(); + + function next(err) { + if (err && err === 'route') { + return done(); + } + + var layer = stack[idx++]; + if (!layer) { + return done(err); + } + + if (layer.method && layer.method !== method) { + return next(err); + } + + if (err) { + layer.handle_error(err, req, res, next); + } else { + layer.handle_request(req, res, next); + } + } +}; + +/** + * Add a handler for all HTTP verbs to this route. + * + * Behaves just like middleware and can respond or call `next` + * to continue processing. + * + * You can use multiple `.all` call to add multiple handlers. + * + * function check_something(req, res, next){ + * next(); + * }; + * + * function validate_user(req, res, next){ + * next(); + * }; + * + * route + * .all(validate_user) + * .all(check_something) + * .get(function(req, res, next){ + * res.send('hello world'); + * }); + * + * @param {function} handler + * @return {Route} for chaining + * @api public + */ + +Route.prototype.all = function(){ + var self = this; + var callbacks = utils.flatten([].slice.call(arguments)); + callbacks.forEach(function(fn) { + if (typeof fn !== 'function') { + var type = {}.toString.call(fn); + var msg = 'Route.all() requires callback functions but got a ' + type; + throw new Error(msg); + } + + var layer = Layer('/', {}, fn); + layer.method = undefined; + + self.methods._all = true; + self.stack.push(layer); + }); + + return self; +}; + +methods.forEach(function(method){ + Route.prototype[method] = function(){ + var self = this; + var callbacks = utils.flatten([].slice.call(arguments)); + + callbacks.forEach(function(fn) { + if (typeof fn !== 'function') { + var type = {}.toString.call(fn); + var msg = 'Route.' + method + '() requires callback functions but got a ' + type; + throw new Error(msg); + } + + debug('%s %s', method, self.path); + + var layer = Layer('/', {}, fn); + layer.method = method; + + self.methods[method] = true; + self.stack.push(layer); + }); + return self; + }; +}); diff --git a/node_modules/express/lib/utils.js b/node_modules/express/lib/utils.js new file mode 100644 index 0000000..8dd2966 --- /dev/null +++ b/node_modules/express/lib/utils.js @@ -0,0 +1,291 @@ +/** + * Module dependencies. + */ + +var mime = require('send').mime; +var basename = require('path').basename; +var etag = require('etag'); +var proxyaddr = require('proxy-addr'); +var qs = require('qs'); +var querystring = require('querystring'); +var typer = require('media-typer'); + +/** + * Return strong ETag for `body`. + * + * @param {String|Buffer} body + * @param {String} [encoding] + * @return {String} + * @api private + */ + +exports.etag = function (body, encoding) { + var buf = !Buffer.isBuffer(body) + ? new Buffer(body, encoding) + : body + + return etag(buf, {weak: false}) +}; + +/** + * Return weak ETag for `body`. + * + * @param {String|Buffer} body + * @param {String} [encoding] + * @return {String} + * @api private + */ + +exports.wetag = function wetag(body, encoding){ + var buf = !Buffer.isBuffer(body) + ? new Buffer(body, encoding) + : body + + return etag(buf, {weak: true}) +}; + +/** + * Check if `path` looks absolute. + * + * @param {String} path + * @return {Boolean} + * @api private + */ + +exports.isAbsolute = function(path){ + if ('/' == path[0]) return true; + if (':' == path[1] && '\\' == path[2]) return true; + if ('\\\\' == path.substring(0, 2)) return true; // Microsoft Azure absolute path +}; + +/** + * Flatten the given `arr`. + * + * @param {Array} arr + * @return {Array} + * @api private + */ + +exports.flatten = function(arr, ret){ + ret = ret || []; + var len = arr.length; + for (var i = 0; i < len; ++i) { + if (Array.isArray(arr[i])) { + exports.flatten(arr[i], ret); + } else { + ret.push(arr[i]); + } + } + return ret; +}; + +/** + * Normalize the given `type`, for example "html" becomes "text/html". + * + * @param {String} type + * @return {Object} + * @api private + */ + +exports.normalizeType = function(type){ + return ~type.indexOf('/') + ? acceptParams(type) + : { value: mime.lookup(type), params: {} }; +}; + +/** + * Normalize `types`, for example "html" becomes "text/html". + * + * @param {Array} types + * @return {Array} + * @api private + */ + +exports.normalizeTypes = function(types){ + var ret = []; + + for (var i = 0; i < types.length; ++i) { + ret.push(exports.normalizeType(types[i])); + } + + return ret; +}; + +/** + * Generate Content-Disposition header appropriate for the filename. + * non-ascii filenames are urlencoded and a filename* parameter is added + * + * @param {String} filename + * @return {String} + * @api private + */ + +exports.contentDisposition = function(filename){ + var ret = 'attachment'; + if (filename) { + filename = basename(filename); + // if filename contains non-ascii characters, add a utf-8 version ala RFC 5987 + ret = /[^\040-\176]/.test(filename) + ? 'attachment; filename="' + encodeURI(filename) + '"; filename*=UTF-8\'\'' + encodeURI(filename) + : 'attachment; filename="' + filename + '"'; + } + + return ret; +}; + +/** + * Parse accept params `str` returning an + * object with `.value`, `.quality` and `.params`. + * also includes `.originalIndex` for stable sorting + * + * @param {String} str + * @return {Object} + * @api private + */ + +function acceptParams(str, index) { + var parts = str.split(/ *; */); + var ret = { value: parts[0], quality: 1, params: {}, originalIndex: index }; + + for (var i = 1; i < parts.length; ++i) { + var pms = parts[i].split(/ *= */); + if ('q' == pms[0]) { + ret.quality = parseFloat(pms[1]); + } else { + ret.params[pms[0]] = pms[1]; + } + } + + return ret; +} + +/** + * Compile "etag" value to function. + * + * @param {Boolean|String|Function} val + * @return {Function} + * @api private + */ + +exports.compileETag = function(val) { + var fn; + + if (typeof val === 'function') { + return val; + } + + switch (val) { + case true: + fn = exports.wetag; + break; + case false: + break; + case 'strong': + fn = exports.etag; + break; + case 'weak': + fn = exports.wetag; + break; + default: + throw new TypeError('unknown value for etag function: ' + val); + } + + return fn; +} + +/** + * Compile "query parser" value to function. + * + * @param {String|Function} val + * @return {Function} + * @api private + */ + +exports.compileQueryParser = function compileQueryParser(val) { + var fn; + + if (typeof val === 'function') { + return val; + } + + switch (val) { + case true: + fn = querystring.parse; + break; + case false: + fn = newObject; + break; + case 'extended': + fn = qs.parse; + break; + case 'simple': + fn = querystring.parse; + break; + default: + throw new TypeError('unknown value for query parser function: ' + val); + } + + return fn; +} + +/** + * Compile "proxy trust" value to function. + * + * @param {Boolean|String|Number|Array|Function} val + * @return {Function} + * @api private + */ + +exports.compileTrust = function(val) { + if (typeof val === 'function') return val; + + if (val === true) { + // Support plain true/false + return function(){ return true }; + } + + if (typeof val === 'number') { + // Support trusting hop count + return function(a, i){ return i < val }; + } + + if (typeof val === 'string') { + // Support comma-separated values + val = val.split(/ *, */); + } + + return proxyaddr.compile(val || []); +} + +/** + * Set the charset in a given Content-Type string. + * + * @param {String} type + * @param {String} charset + * @return {String} + * @api private + */ + +exports.setCharset = function(type, charset){ + if (!type || !charset) return type; + + // parse type + var parsed = typer.parse(type); + + // set charset + parsed.parameters.charset = charset; + + // format type + return typer.format(parsed); +}; + +/** + * Return new empty objet. + * + * @return {Object} + * @api private + */ + +function newObject() { + return {}; +} diff --git a/node_modules/express/lib/view.js b/node_modules/express/lib/view.js new file mode 100644 index 0000000..989e8bb --- /dev/null +++ b/node_modules/express/lib/view.js @@ -0,0 +1,77 @@ +/** + * Module dependencies. + */ + +var path = require('path'); +var fs = require('fs'); +var utils = require('./utils'); +var dirname = path.dirname; +var basename = path.basename; +var extname = path.extname; +var exists = fs.existsSync || path.existsSync; +var join = path.join; + +/** + * Expose `View`. + */ + +module.exports = View; + +/** + * Initialize a new `View` with the given `name`. + * + * Options: + * + * - `defaultEngine` the default template engine name + * - `engines` template engine require() cache + * - `root` root path for view lookup + * + * @param {String} name + * @param {Object} options + * @api private + */ + +function View(name, options) { + options = options || {}; + this.name = name; + this.root = options.root; + var engines = options.engines; + this.defaultEngine = options.defaultEngine; + var ext = this.ext = extname(name); + if (!ext && !this.defaultEngine) throw new Error('No default engine was specified and no extension was provided.'); + if (!ext) name += (ext = this.ext = ('.' != this.defaultEngine[0] ? '.' : '') + this.defaultEngine); + this.engine = engines[ext] || (engines[ext] = require(ext.slice(1)).__express); + this.path = this.lookup(name); +} + +/** + * Lookup view by the given `path` + * + * @param {String} path + * @return {String} + * @api private + */ + +View.prototype.lookup = function(path){ + var ext = this.ext; + + // . + if (!utils.isAbsolute(path)) path = join(this.root, path); + if (exists(path)) return path; + + // /index. + path = join(dirname(path), basename(path, ext), 'index' + ext); + if (exists(path)) return path; +}; + +/** + * Render with the given `options` and callback `fn(err, str)`. + * + * @param {Object} options + * @param {Function} fn + * @api private + */ + +View.prototype.render = function(options, fn){ + this.engine(this.path, options, fn); +}; diff --git a/node_modules/express/node_modules/accepts/README.md b/node_modules/express/node_modules/accepts/README.md new file mode 100644 index 0000000..eaec5e9 --- /dev/null +++ b/node_modules/express/node_modules/accepts/README.md @@ -0,0 +1,95 @@ +# Accepts + +[![NPM version][npm-image]][npm-url] +[![Build status][travis-image]][travis-url] +[![Test coverage][coveralls-image]][coveralls-url] +[![Dependency Status][david-image]][david-url] +[![License][license-image]][license-url] +[![Downloads][downloads-image]][downloads-url] + +Higher level content negotation based on [negotiator](https://github.com/federomero/negotiator). Extracted from [koa](https://github.com/koajs/koa) for general use. + +In addition to negotatior, it allows: + +- Allows types as an array or arguments list, ie `(['text/html', 'application/json'])` as well as `('text/html', 'application/json')`. +- Allows type shorthands such as `json`. +- Returns `false` when no types match +- Treats non-existent headers as `*` + +## API + +### var accept = new Accepts(req) + +```js +var accepts = require('accepts') + +http.createServer(function (req, res) { + var accept = accepts(req) +}) +``` + +### accept\[property\]\(\) + +Returns all the explicitly accepted content property as an array in descending priority. + +- `accept.types()` +- `accept.encodings()` +- `accept.charsets()` +- `accept.languages()` + +They are also aliased in singular form such as `accept.type()`. `accept.languages()` is also aliased as `accept.langs()`, etc. + +Note: you should almost never do this in a real app as it defeats the purpose of content negotiation. + +Example: + +```js +// in Google Chrome +var encodings = accept.encodings() // -> ['sdch', 'gzip', 'deflate'] +``` + +Since you probably don't support `sdch`, you should just supply the encodings you support: + +```js +var encoding = accept.encodings('gzip', 'deflate') // -> 'gzip', probably +``` + +### accept\[property\]\(values, ...\) + +You can either have `values` be an array or have an argument list of values. + +If the client does not accept any `values`, `false` will be returned. +If the client accepts any `values`, the preferred `value` will be return. + +For `accept.types()`, shorthand mime types are allowed. + +Example: + +```js +// req.headers.accept = 'application/json' + +accept.types('json') // -> 'json' +accept.types('html', 'json') // -> 'json' +accept.types('html') // -> false + +// req.headers.accept = '' +// which is equivalent to `*` + +accept.types() // -> [], no explicit types +accept.types('text/html', 'text/json') // -> 'text/html', since it was first +``` + +[npm-image]: https://img.shields.io/npm/v/accepts.svg?style=flat-square +[npm-url]: https://npmjs.org/package/accepts +[github-tag]: http://img.shields.io/github/tag/jshttp/accepts.svg?style=flat-square +[github-url]: https://github.com/jshttp/accepts/tags +[travis-image]: https://img.shields.io/travis/jshttp/accepts.svg?style=flat-square +[travis-url]: https://travis-ci.org/jshttp/accepts +[coveralls-image]: https://img.shields.io/coveralls/jshttp/accepts.svg?style=flat-square +[coveralls-url]: https://coveralls.io/r/jshttp/accepts?branch=master +[david-image]: http://img.shields.io/david/jshttp/accepts.svg?style=flat-square +[david-url]: https://david-dm.org/jshttp/accepts +[license-image]: http://img.shields.io/npm/l/accepts.svg?style=flat-square +[license-url]: LICENSE +[downloads-image]: http://img.shields.io/npm/dm/accepts.svg?style=flat-square +[downloads-url]: https://npmjs.org/package/accepts diff --git a/node_modules/express/node_modules/accepts/index.js b/node_modules/express/node_modules/accepts/index.js new file mode 100644 index 0000000..805e33a --- /dev/null +++ b/node_modules/express/node_modules/accepts/index.js @@ -0,0 +1,160 @@ +var Negotiator = require('negotiator') +var mime = require('mime-types') + +var slice = [].slice + +module.exports = Accepts + +function Accepts(req) { + if (!(this instanceof Accepts)) + return new Accepts(req) + + this.headers = req.headers + this.negotiator = Negotiator(req) +} + +/** + * Check if the given `type(s)` is acceptable, returning + * the best match when true, otherwise `undefined`, in which + * case you should respond with 406 "Not Acceptable". + * + * The `type` value may be a single mime type string + * such as "application/json", the extension name + * such as "json" or an array `["json", "html", "text/plain"]`. When a list + * or array is given the _best_ match, if any is returned. + * + * Examples: + * + * // Accept: text/html + * this.types('html'); + * // => "html" + * + * // Accept: text/*, application/json + * this.types('html'); + * // => "html" + * this.types('text/html'); + * // => "text/html" + * this.types('json', 'text'); + * // => "json" + * this.types('application/json'); + * // => "application/json" + * + * // Accept: text/*, application/json + * this.types('image/png'); + * this.types('png'); + * // => undefined + * + * // Accept: text/*;q=.5, application/json + * this.types(['html', 'json']); + * this.types('html', 'json'); + * // => "json" + * + * @param {String|Array} type(s)... + * @return {String|Array|Boolean} + * @api public + */ + +Accepts.prototype.type = +Accepts.prototype.types = function (types) { + if (!Array.isArray(types)) types = slice.call(arguments); + var n = this.negotiator; + if (!types.length) return n.mediaTypes(); + if (!this.headers.accept) return types[0]; + var mimes = types.map(extToMime); + var accepts = n.mediaTypes(mimes.filter(validMime)); + var first = accepts[0]; + if (!first) return false; + return types[mimes.indexOf(first)]; +} + +/** + * Return accepted encodings or best fit based on `encodings`. + * + * Given `Accept-Encoding: gzip, deflate` + * an array sorted by quality is returned: + * + * ['gzip', 'deflate'] + * + * @param {String|Array} encoding(s)... + * @return {String|Array} + * @api public + */ + +Accepts.prototype.encoding = +Accepts.prototype.encodings = function (encodings) { + if (!Array.isArray(encodings)) encodings = slice.call(arguments); + var n = this.negotiator; + if (!encodings.length) return n.encodings(); + return n.encodings(encodings)[0] || false; +} + +/** + * Return accepted charsets or best fit based on `charsets`. + * + * Given `Accept-Charset: utf-8, iso-8859-1;q=0.2, utf-7;q=0.5` + * an array sorted by quality is returned: + * + * ['utf-8', 'utf-7', 'iso-8859-1'] + * + * @param {String|Array} charset(s)... + * @return {String|Array} + * @api public + */ + +Accepts.prototype.charset = +Accepts.prototype.charsets = function (charsets) { + if (!Array.isArray(charsets)) charsets = [].slice.call(arguments); + var n = this.negotiator; + if (!charsets.length) return n.charsets(); + if (!this.headers['accept-charset']) return charsets[0]; + return n.charsets(charsets)[0] || false; +} + +/** + * Return accepted languages or best fit based on `langs`. + * + * Given `Accept-Language: en;q=0.8, es, pt` + * an array sorted by quality is returned: + * + * ['es', 'pt', 'en'] + * + * @param {String|Array} lang(s)... + * @return {Array|String} + * @api public + */ + +Accepts.prototype.lang = +Accepts.prototype.langs = +Accepts.prototype.language = +Accepts.prototype.languages = function (langs) { + if (!Array.isArray(langs)) langs = slice.call(arguments); + var n = this.negotiator; + if (!langs.length) return n.languages(); + if (!this.headers['accept-language']) return langs[0]; + return n.languages(langs)[0] || false; +} + +/** + * Convert extnames to mime. + * + * @param {String} type + * @return {String} + * @api private + */ + +function extToMime(type) { + if (~type.indexOf('/')) return type; + return mime.lookup(type); +} + +/** + * Check if mime is valid. + * + * @param {String} type + * @return {String} + * @api private + */ + +function validMime(type) { + return typeof type === 'string'; +} diff --git a/node_modules/express/node_modules/accepts/node_modules/mime-types/HISTORY.md b/node_modules/express/node_modules/accepts/node_modules/mime-types/HISTORY.md new file mode 100644 index 0000000..510ea56 --- /dev/null +++ b/node_modules/express/node_modules/accepts/node_modules/mime-types/HISTORY.md @@ -0,0 +1,31 @@ +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/node_modules/express/node_modules/accepts/node_modules/mime-types/LICENSE b/node_modules/express/node_modules/accepts/node_modules/mime-types/LICENSE new file mode 100644 index 0000000..a7ae8ee --- /dev/null +++ b/node_modules/express/node_modules/accepts/node_modules/mime-types/LICENSE @@ -0,0 +1,22 @@ + +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/node_modules/express/node_modules/accepts/node_modules/mime-types/README.md b/node_modules/express/node_modules/accepts/node_modules/mime-types/README.md new file mode 100644 index 0000000..99d658b --- /dev/null +++ b/node_modules/express/node_modules/accepts/node_modules/mime-types/README.md @@ -0,0 +1,99 @@ +# 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('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' +``` + +### 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?style=flat +[npm-url]: https://npmjs.org/package/mime-types +[node-version-image]: https://img.shields.io/badge/node.js-%3E%3D_0.6-brightgreen.svg?style=flat +[node-version-url]: http://nodejs.org/download/ +[travis-image]: https://img.shields.io/travis/jshttp/mime-types.svg?style=flat +[travis-url]: https://travis-ci.org/jshttp/mime-types +[coveralls-image]: https://img.shields.io/coveralls/jshttp/mime-types.svg?style=flat +[coveralls-url]: https://coveralls.io/r/jshttp/mime-types +[downloads-image]: https://img.shields.io/npm/dm/mime-types.svg?style=flat +[downloads-url]: https://npmjs.org/package/mime-types diff --git a/node_modules/express/node_modules/accepts/node_modules/mime-types/index.js b/node_modules/express/node_modules/accepts/node_modules/mime-types/index.js new file mode 100644 index 0000000..b46a202 --- /dev/null +++ b/node_modules/express/node_modules/accepts/node_modules/mime-types/index.js @@ -0,0 +1,63 @@ + +var db = require('mime-db') + +// types[extension] = type +exports.types = Object.create(null) +// extensions[type] = [extensions] +exports.extensions = 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 +} + +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] +} + +// type has to be an exact mime type +exports.charset = function (type) { + var mime = db[type] + if (mime && mime.charset) return mime.charset + + // default text/* to utf-8 + if (/^text\//.test(type)) return 'UTF-8' + + return false +} + +// backwards compatibility +exports.charsets = { + lookup: exports.charset +} + +// 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() + } + return type +} diff --git a/node_modules/express/node_modules/accepts/node_modules/mime-types/node_modules/mime-db/LICENSE b/node_modules/express/node_modules/accepts/node_modules/mime-types/node_modules/mime-db/LICENSE new file mode 100644 index 0000000..a7ae8ee --- /dev/null +++ b/node_modules/express/node_modules/accepts/node_modules/mime-types/node_modules/mime-db/LICENSE @@ -0,0 +1,22 @@ + +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/node_modules/express/node_modules/accepts/node_modules/mime-types/node_modules/mime-db/README.md b/node_modules/express/node_modules/accepts/node_modules/mime-types/node_modules/mime-db/README.md new file mode 100644 index 0000000..7909379 --- /dev/null +++ b/node_modules/express/node_modules/accepts/node_modules/mime-types/node_modules/mime-db/README.md @@ -0,0 +1,72 @@ +# 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 consistents of a single, public JSON file and does not include any logic, +allowing it to remain as unopinionated 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 + +## Usage + +```bash +npm i mime-db +``` + +```js +var db = require('mime-db'); + +// grab data on .js files +var data = db['application/javascript']; +``` + +If you're crazy enough to use this in the browser, +you can just grab the JSON file: + +``` +https://cdn.rawgit.com/jshttp/mime-db/master/db.json +``` + +## 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) +- `.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`. + +## Repository Structure + +- `scripts` - these are scripts to run to build the database +- `src/` - this is a folder of files created from remote sources like Apache and IANA +- `lib/` - this is a folder of our own custom sources and db, which will be merged into `db.json` +- `db.json` - the final built JSON file for end-user usage + +## Contributing + +To edit the database, only make PRs against files in the `lib/` folder. +To update the build, run `npm run update`. + +[npm-version-image]: https://img.shields.io/npm/v/mime-db.svg?style=flat +[npm-downloads-image]: https://img.shields.io/npm/dm/mime-db.svg?style=flat +[npm-url]: https://npmjs.org/package/mime-db +[travis-image]: https://img.shields.io/travis/jshttp/mime-db.svg?style=flat +[travis-url]: https://travis-ci.org/jshttp/mime-db +[coveralls-image]: https://img.shields.io/coveralls/jshttp/mime-db.svg?style=flat +[coveralls-url]: https://coveralls.io/r/jshttp/mime-db?branch=master +[node-image]: http://img.shields.io/badge/node.js->=_0.6-brightgreen.svg?style=flat +[node-url]: http://nodejs.org/download/ diff --git a/node_modules/express/node_modules/accepts/node_modules/mime-types/node_modules/mime-db/db.json b/node_modules/express/node_modules/accepts/node_modules/mime-types/node_modules/mime-db/db.json new file mode 100644 index 0000000..f89fc14 --- /dev/null +++ b/node_modules/express/node_modules/accepts/node_modules/mime-types/node_modules/mime-db/db.json @@ -0,0 +1,6269 @@ +{ + "application/1d-interleaved-parityfec": { + "source": "iana" + }, + "application/3gpdash-qoe-report+xml": { + "source": "iana" + }, + "application/3gpp-ims+xml": { + "source": "iana" + }, + "application/activemessage": { + "source": "iana" + }, + "application/alto-costmap+json": { + "source": "iana" + }, + "application/alto-costmapfilter+json": { + "source": "iana" + }, + "application/alto-directory+json": { + "source": "iana" + }, + "application/alto-endpointcost+json": { + "source": "iana" + }, + "application/alto-endpointcostparams+json": { + "source": "iana" + }, + "application/alto-endpointprop+json": { + "source": "iana" + }, + "application/alto-endpointpropparams+json": { + "source": "iana" + }, + "application/alto-error+json": { + "source": "iana" + }, + "application/alto-networkmap+json": { + "source": "iana" + }, + "application/alto-networkmapfilter+json": { + "source": "iana" + }, + "application/andrew-inset": { + "source": "iana", + "extensions": ["ez"] + }, + "application/applefile": { + "source": "iana" + }, + "application/applixware": { + "source": "apache", + "extensions": ["aw"] + }, + "application/atf": { + "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/auth-policy+xml": { + "source": "iana" + }, + "application/bacnet-xdd+zip": { + "source": "iana" + }, + "application/batch-smtp": { + "source": "iana" + }, + "application/beep+xml": { + "source": "iana" + }, + "application/calendar+json": { + "source": "iana" + }, + "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/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-2018+xml": { + "source": "iana" + }, + "application/cellml+xml": { + "source": "iana" + }, + "application/cfw": { + "source": "iana" + }, + "application/cms": { + "source": "iana" + }, + "application/cnrp+xml": { + "source": "iana" + }, + "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/dec-dx": { + "source": "iana" + }, + "application/dialog-info+xml": { + "source": "iana" + }, + "application/dicom": { + "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": "apache", + "extensions": ["epub"] + }, + "application/eshop": { + "source": "iana" + }, + "application/example": { + "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/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"] + }, + "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/jrd+json": { + "source": "iana" + }, + "application/json": { + "source": "iana", + "charset": "UTF-8", + "compressible": true, + "extensions": ["json","map"] + }, + "application/json-patch+json": { + "source": "iana" + }, + "application/jsonml+json": { + "source": "apache", + "extensions": ["jsonml"] + }, + "application/kpml-request+xml": { + "source": "iana" + }, + "application/kpml-response+xml": { + "source": "iana" + }, + "application/ld+json": { + "source": "iana" + }, + "application/link-format": { + "source": "iana" + }, + "application/load-control+xml": { + "source": "iana" + }, + "application/lost+xml": { + "source": "iana", + "extensions": ["lostxml"] + }, + "application/lostsync+xml": { + "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/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": "apache", + "extensions": ["mbox"] + }, + "application/mbox+xml": { + "source": "iana" + }, + "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" + }, + "application/metalink+xml": { + "source": "apache", + "extensions": ["metalink"] + }, + "application/metalink4+xml": { + "source": "iana", + "extensions": ["meta4"] + }, + "application/mets+xml": { + "source": "iana", + "extensions": ["mets"] + }, + "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": "apache" + }, + "application/octet-stream": { + "source": "iana", + "compressible": false, + "extensions": ["bin","dms","lrf","mar","so","dist","distz","pkg","bpk","dump","elc","deploy","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/oscp-response": { + "source": "iana" + }, + "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/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" + }, + "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/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" + }, + "application/vcard+xml": { + "source": "iana" + }, + "application/vemmi": { + "source": "iana" + }, + "application/vividence.scriptfile": { + "source": "apache" + }, + "application/vnd-acucobol": { + "source": "iana" + }, + "application/vnd-curl": { + "source": "iana" + }, + "application/vnd-dart": { + "source": "iana" + }, + "application/vnd-dxr": { + "source": "iana" + }, + "application/vnd-fdf": { + "source": "iana" + }, + "application/vnd-mif": { + "source": "iana" + }, + "application/vnd-sema": { + "source": "iana" + }, + "application/vnd-wap-wmlc": { + "source": "iana" + }, + "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.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": "apache", + "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.api+json": { + "source": "iana" + }, + "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.bekitzur-stech+json": { + "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.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.collection+json": { + "source": "iana" + }, + "application/vnd.collection.doc+json": { + "source": "iana" + }, + "application/vnd.collection.next+json": { + "source": "iana" + }, + "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": "apache" + }, + "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": "apache", + "compressible": true, + "extensions": ["dart"] + }, + "application/vnd.data-vision.rdz": { + "source": "iana", + "extensions": ["rdz"] + }, + "application/vnd.debian.binary-package": { + "source": "iana" + }, + "application/vnd.dece-zip": { + "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": "apache", + "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" + }, + "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": "apache", + "extensions": ["svc"] + }, + "application/vnd.dvb_service": { + "source": "iana" + }, + "application/vnd.dxr": { + "source": "apache" + }, + "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.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.fdf": { + "source": "apache", + "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" + }, + "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.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.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" + }, + "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" + }, + "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" + }, + "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.lis.v2.result+json": { + "source": "iana" + }, + "application/vnd.ims.lti.v2.toolconsumerprofile+json": { + "source": "iana" + }, + "application/vnd.ims.lti.v2.toolproxy+json": { + "source": "iana" + }, + "application/vnd.ims.lti.v2.toolproxy.id+json": { + "source": "iana" + }, + "application/vnd.ims.lti.v2.toolsettings+json": { + "source": "iana" + }, + "application/vnd.ims.lti.v2.toolsettings.simple+json": { + "source": "iana" + }, + "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" + }, + "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.micrografx-igx": { + "source": "iana" + }, + "application/vnd.micrografx.flo": { + "source": "iana", + "extensions": ["flo"] + }, + "application/vnd.micrografx.igx": { + "source": "apache", + "extensions": ["igx"] + }, + "application/vnd.miele+json": { + "source": "iana" + }, + "application/vnd.mif": { + "source": "apache", + "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.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" + }, + "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" + }, + "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.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": "apache" + }, + "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-doc": { + "source": "iana" + }, + "application/vnd.sealed-eml": { + "source": "iana" + }, + "application/vnd.sealed-mht": { + "source": "iana" + }, + "application/vnd.sealed-ppt": { + "source": "iana" + }, + "application/vnd.sealed-tiff": { + "source": "iana" + }, + "application/vnd.sealed-xls": { + "source": "iana" + }, + "application/vnd.sealed.3df": { + "source": "iana" + }, + "application/vnd.sealed.csf": { + "source": "iana" + }, + "application/vnd.sealed.doc": { + "source": "apache" + }, + "application/vnd.sealed.eml": { + "source": "apache" + }, + "application/vnd.sealed.mht": { + "source": "apache" + }, + "application/vnd.sealed.net": { + "source": "iana" + }, + "application/vnd.sealed.ppt": { + "source": "apache" + }, + "application/vnd.sealed.tiff": { + "source": "apache" + }, + "application/vnd.sealed.xls": { + "source": "apache" + }, + "application/vnd.sealedmedia.softseal-html": { + "source": "iana" + }, + "application/vnd.sealedmedia.softseal-pdf": { + "source": "iana" + }, + "application/vnd.sealedmedia.softseal.html": { + "source": "apache" + }, + "application/vnd.sealedmedia.softseal.pdf": { + "source": "apache" + }, + "application/vnd.seemail": { + "source": "iana", + "extensions": ["see"] + }, + "application/vnd.sema": { + "source": "apache", + "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" + }, + "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.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-slc": { + "source": "iana" + }, + "application/vnd.wap-wbxml": { + "source": "iana" + }, + "application/vnd.wap.sic": { + "source": "iana" + }, + "application/vnd.wap.slc": { + "source": "apache" + }, + "application/vnd.wap.wbxml": { + "source": "apache", + "extensions": ["wbxml"] + }, + "application/vnd.wap.wmlc": { + "source": "apache", + "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" + }, + "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/vwg-multiplexed": { + "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-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-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-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-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-nzb": { + "source": "apache", + "extensions": ["nzb"] + }, + "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-research-info-systems": { + "source": "apache", + "extensions": ["ris"] + }, + "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"] + }, + "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": { + "extensions": ["webapp"] + }, + "application/x-www-form-urlencode": { + "compressible": false + }, + "application/x-www-form-urlencoded": { + "source": "iana" + }, + "application/x-x509-ca-cert": { + "source": "apache", + "extensions": ["der","crt"] + }, + "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": "iana" + }, + "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/example": { + "source": "iana" + }, + "audio/fwdred": { + "source": "iana" + }, + "audio/g719": { + "source": "iana" + }, + "audio/g721": { + "source": "iana" + }, + "audio/g722": { + "source": "iana" + }, + "audio/g7221": { + "source": "apache" + }, + "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": "apache" + }, + "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.sealedmedia.softseal.mpeg": { + "source": "apache" + }, + "audio/vnd.vmx.cvsd": { + "source": "iana" + }, + "audio/vnd.wave": { + "compressible": false + }, + "audio/vorbis": { + "source": "iana", + "compressible": false + }, + "audio/vorbis-config": { + "source": "iana" + }, + "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-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-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/example": { + "source": "iana" + }, + "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-djvu": { + "source": "iana" + }, + "image/vnd-svf": { + "source": "iana" + }, + "image/vnd-wap-wbmp": { + "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": "apache", + "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.sealed.png": { + "source": "apache" + }, + "image/vnd.sealedmedia.softseal-gif": { + "source": "iana" + }, + "image/vnd.sealedmedia.softseal-jpg": { + "source": "iana" + }, + "image/vnd.sealedmedia.softseal.gif": { + "source": "apache" + }, + "image/vnd.sealedmedia.softseal.jpg": { + "source": "apache" + }, + "image/vnd.svf": { + "source": "apache" + }, + "image/vnd.valve.source.texture": { + "source": "iana" + }, + "image/vnd.wap.wbmp": { + "source": "apache", + "extensions": ["wbmp"] + }, + "image/vnd.xiff": { + "source": "iana", + "extensions": ["xif"] + }, + "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-mrsid-image": { + "source": "apache", + "extensions": ["sid"] + }, + "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/example": { + "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/example": { + "source": "iana", + "compressible": false + }, + "model/iges": { + "source": "iana", + "compressible": false, + "extensions": ["igs","iges"] + }, + "model/mesh": { + "source": "iana", + "compressible": false, + "extensions": ["msh","mesh","silo"] + }, + "model/vnd-dwf": { + "source": "iana" + }, + "model/vnd.collada+xml": { + "source": "iana", + "extensions": ["dae"] + }, + "model/vnd.dwf": { + "source": "apache", + "extensions": ["dwf"] + }, + "model/vnd.flatland.3dml": { + "source": "iana" + }, + "model/vnd.gdl": { + "source": "iana", + "extensions": ["gdl"] + }, + "model/vnd.gs-gdl": { + "source": "iana" + }, + "model/vnd.gs.gdl": { + "source": "apache" + }, + "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.parasolid.transmit.binary": { + "source": "apache" + }, + "model/vnd.parasolid.transmit.text": { + "source": "apache" + }, + "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/example": { + "source": "iana" + }, + "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"] + }, + "text/css": { + "source": "iana", + "compressible": true, + "extensions": ["css"] + }, + "text/csv": { + "source": "iana", + "compressible": true, + "extensions": ["csv"] + }, + "text/directory": { + "source": "iana" + }, + "text/dns": { + "source": "iana" + }, + "text/ecmascript": { + "source": "iana" + }, + "text/encaprtp": { + "source": "iana" + }, + "text/enriched": { + "source": "iana" + }, + "text/example": { + "source": "iana" + }, + "text/fwdred": { + "source": "iana" + }, + "text/grammar-ref-list": { + "source": "iana" + }, + "text/html": { + "source": "iana", + "compressible": true, + "extensions": ["html","htm"] + }, + "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/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" + }, + "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-curl": { + "source": "iana" + }, + "text/vnd.abc": { + "source": "iana" + }, + "text/vnd.curl": { + "source": "apache", + "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-wml": { + "source": "iana" + }, + "text/vnd.wap.si": { + "source": "iana" + }, + "text/vnd.wap.sl": { + "source": "iana" + }, + "text/vnd.wap.wml": { + "source": "apache", + "extensions": ["wml"] + }, + "text/vnd.wap.wmlscript": { + "source": "iana", + "extensions": ["wmls"] + }, + "text/vtt": { + "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": { + "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-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 + }, + "text/xml-external-parsed-entity": { + "source": "iana" + }, + "video/1d-interleaved-parityfec": { + "source": "apache" + }, + "video/3gpp": { + "source": "apache", + "extensions": ["3gp"] + }, + "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/example": { + "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/node_modules/express/node_modules/accepts/node_modules/mime-types/node_modules/mime-db/index.js b/node_modules/express/node_modules/accepts/node_modules/mime-types/node_modules/mime-db/index.js new file mode 100644 index 0000000..551031f --- /dev/null +++ b/node_modules/express/node_modules/accepts/node_modules/mime-types/node_modules/mime-db/index.js @@ -0,0 +1,11 @@ +/*! + * mime-db + * Copyright(c) 2014 Jonathan Ong + * MIT Licensed + */ + +/** + * Module exports. + */ + +module.exports = require('./db.json') diff --git a/node_modules/express/node_modules/accepts/node_modules/mime-types/node_modules/mime-db/package.json b/node_modules/express/node_modules/accepts/node_modules/mime-types/node_modules/mime-db/package.json new file mode 100644 index 0000000..f067351 --- /dev/null +++ b/node_modules/express/node_modules/accepts/node_modules/mime-types/node_modules/mime-db/package.json @@ -0,0 +1,74 @@ +{ + "name": "mime-db", + "description": "Media Type Database", + "version": "1.0.1", + "author": { + "name": "Jonathan Ong", + "email": "me@jongleberry.com", + "url": "http://jongleberry.com" + }, + "license": "MIT", + "repository": { + "type": "git", + "url": "https://github.com/jshttp/mime-db" + }, + "devDependencies": { + "co": "3", + "cogent": "1", + "csv-parse": "0", + "gnode": "0.0.8", + "istanbul": "0.3.0", + "mocha": "1", + "stream-to-array": "2" + }, + "engine": { + "node": ">= 0.6.0" + }, + "files": [ + "LICENSE", + "db.json", + "index.js" + ], + "scripts": { + "update": "gnode scripts/extensions && gnode scripts/types && node scripts/build", + "clean": "rm src/*", + "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/" + }, + "keywords": [ + "mime", + "db", + "type", + "types", + "database", + "charset", + "charsets" + ], + "gitHead": "6c9ee137430015b52887901377ac2f33e21f4078", + "bugs": { + "url": "https://github.com/jshttp/mime-db/issues" + }, + "homepage": "https://github.com/jshttp/mime-db", + "_id": "mime-db@1.0.1", + "_shasum": "35d99b0965967253bb30633a7d07a8de9975a952", + "_from": "mime-db@~1.0.1", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + }, + "maintainers": [ + { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + } + ], + "dist": { + "shasum": "35d99b0965967253bb30633a7d07a8de9975a952", + "tarball": "http://registry.npmjs.org/mime-db/-/mime-db-1.0.1.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.0.1.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/express/node_modules/accepts/node_modules/mime-types/package.json b/node_modules/express/node_modules/accepts/node_modules/mime-types/package.json new file mode 100644 index 0000000..494c346 --- /dev/null +++ b/node_modules/express/node_modules/accepts/node_modules/mime-types/package.json @@ -0,0 +1,80 @@ +{ + "name": "mime-types", + "description": "The ultimate javascript content-type utility.", + "version": "2.0.1", + "contributors": [ + { + "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": "https://github.com/jshttp/mime-types" + }, + "dependencies": { + "mime-db": "~1.0.1" + }, + "devDependencies": { + "istanbul": "0", + "mocha": "1" + }, + "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": "c6e40fb033331aa87d9d4a5f1e5c0245e9edb2f6", + "bugs": { + "url": "https://github.com/jshttp/mime-types/issues" + }, + "homepage": "https://github.com/jshttp/mime-types", + "_id": "mime-types@2.0.1", + "_shasum": "7f5b4712592e7dd46ca733fd1c5f5d71356de615", + "_from": "mime-types@~2.0.1", + "_npmVersion": "1.4.21", + "_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": "7f5b4712592e7dd46ca733fd1c5f5d71356de615", + "tarball": "http://registry.npmjs.org/mime-types/-/mime-types-2.0.1.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.0.1.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/express/node_modules/accepts/node_modules/negotiator/.npmignore b/node_modules/express/node_modules/accepts/node_modules/negotiator/.npmignore new file mode 100644 index 0000000..a6a8d17 --- /dev/null +++ b/node_modules/express/node_modules/accepts/node_modules/negotiator/.npmignore @@ -0,0 +1,3 @@ +examples +test +.travis.yml diff --git a/node_modules/express/node_modules/accepts/node_modules/negotiator/LICENSE b/node_modules/express/node_modules/accepts/node_modules/negotiator/LICENSE new file mode 100644 index 0000000..42ca2e7 --- /dev/null +++ b/node_modules/express/node_modules/accepts/node_modules/negotiator/LICENSE @@ -0,0 +1,27 @@ +Original "Negotiator" program Copyright Federico Romero +Port to JavaScript Copyright Isaac Z. Schlueter + +All rights reserved. + +MIT License + +Permission is hereby granted, free of charge, to any person +obtaining a copy of this software and associated documentation +files (the "Software"), to deal in the Software without +restriction, including without limitation the rights to use, +copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the +Software is furnished to do so, subject to the following +conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES +OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT +HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR +OTHER DEALINGS IN THE SOFTWARE. diff --git a/node_modules/express/node_modules/accepts/node_modules/negotiator/lib/charset.js b/node_modules/express/node_modules/accepts/node_modules/negotiator/lib/charset.js new file mode 100644 index 0000000..d231291 --- /dev/null +++ b/node_modules/express/node_modules/accepts/node_modules/negotiator/lib/charset.js @@ -0,0 +1,90 @@ +module.exports = preferredCharsets; +preferredCharsets.preferredCharsets = preferredCharsets; + +function parseAcceptCharset(accept) { + return accept.split(',').map(function(e) { + return parseCharset(e.trim()); + }).filter(function(e) { + return e; + }); +} + +function parseCharset(s) { + var match = s.match(/^\s*(\S+?)\s*(?:;(.*))?$/); + if (!match) return null; + + var charset = match[1]; + var q = 1; + if (match[2]) { + var params = match[2].split(';') + for (var i = 0; i < params.length; i ++) { + var p = params[i].trim().split('='); + if (p[0] === 'q') { + q = parseFloat(p[1]); + break; + } + } + } + + return { + charset: charset, + q: q + }; +} + +function getCharsetPriority(charset, accepted) { + return (accepted.map(function(a) { + return specify(charset, a); + }).filter(Boolean).sort(function (a, b) { + if(a.s == b.s) { + return a.q > b.q ? -1 : 1; + } else { + return a.s > b.s ? -1 : 1; + } + })[0] || {s: 0, q:0}); +} + +function specify(charset, spec) { + var s = 0; + if(spec.charset === charset){ + s |= 1; + } else if (spec.charset !== '*' ) { + return null + } + + return { + s: s, + q: spec.q, + } +} + +function preferredCharsets(accept, provided) { + // RFC 2616 sec 14.2: no header = * + accept = parseAcceptCharset(accept === undefined ? '*' : accept || ''); + if (provided) { + return provided.map(function(type) { + return [type, getCharsetPriority(type, accept)]; + }).filter(function(pair) { + return pair[1].q > 0; + }).sort(function(a, b) { + var pa = a[1]; + var pb = b[1]; + if(pa.q == pb.q) { + return pa.s < pb.s ? 1 : -1; + } else { + return pa.q < pb.q ? 1 : -1; + } + }).map(function(pair) { + return pair[0]; + }); + } else { + return accept.sort(function (a, b) { + // revsort + return a.q < b.q ? 1 : -1; + }).filter(function(type) { + return type.q > 0; + }).map(function(type) { + return type.charset; + }); + } +} diff --git a/node_modules/express/node_modules/accepts/node_modules/negotiator/lib/encoding.js b/node_modules/express/node_modules/accepts/node_modules/negotiator/lib/encoding.js new file mode 100644 index 0000000..207291d --- /dev/null +++ b/node_modules/express/node_modules/accepts/node_modules/negotiator/lib/encoding.js @@ -0,0 +1,120 @@ +module.exports = preferredEncodings; +preferredEncodings.preferredEncodings = preferredEncodings; + +function parseAcceptEncoding(accept) { + var acceptableEncodings; + + if (accept) { + acceptableEncodings = accept.split(',').map(function(e) { + return parseEncoding(e.trim()); + }); + } else { + acceptableEncodings = []; + } + + if (!acceptableEncodings.some(function(e) { + return e && specify('identity', e); + })) { + /* + * If identity doesn't explicitly appear in the accept-encoding header, + * it's added to the list of acceptable encoding with the lowest q + * + */ + var lowestQ = 1; + + for(var i = 0; i < acceptableEncodings.length; i++){ + var e = acceptableEncodings[i]; + if(e && e.q < lowestQ){ + lowestQ = e.q; + } + } + acceptableEncodings.push({ + encoding: 'identity', + q: lowestQ / 2, + }); + } + + return acceptableEncodings.filter(function(e) { + return e; + }); +} + +function parseEncoding(s) { + var match = s.match(/^\s*(\S+?)\s*(?:;(.*))?$/); + + if (!match) return null; + + var encoding = match[1]; + var q = 1; + if (match[2]) { + var params = match[2].split(';'); + for (var i = 0; i < params.length; i ++) { + var p = params[i].trim().split('='); + if (p[0] === 'q') { + q = parseFloat(p[1]); + break; + } + } + } + + return { + encoding: encoding, + q: q + }; +} + +function getEncodingPriority(encoding, accepted) { + return (accepted.map(function(a) { + return specify(encoding, a); + }).filter(Boolean).sort(function (a, b) { + if(a.s == b.s) { + return a.q > b.q ? -1 : 1; + } else { + return a.s > b.s ? -1 : 1; + } + })[0] || {s: 0, q: 0}); +} + +function specify(encoding, spec) { + var s = 0; + if(spec.encoding === encoding){ + s |= 1; + } else if (spec.encoding !== '*' ) { + return null + } + + return { + s: s, + q: spec.q, + } +}; + +function preferredEncodings(accept, provided) { + accept = parseAcceptEncoding(accept || ''); + if (provided) { + return provided.map(function(type) { + return [type, getEncodingPriority(type, accept)]; + }).filter(function(pair) { + return pair[1].q > 0; + }).sort(function(a, b) { + var pa = a[1]; + var pb = b[1]; + if(pa.q == pb.q) { + return pa.s < pb.s ? 1 : -1; + } else { + return pa.q < pb.q ? 1 : -1; + } + }).map(function(pair) { + return pair[0]; + }); + } else { + return accept.sort(function (a, b) { + // revsort + return a.q < b.q ? 1 : -1; + }).filter(function(type){ + return type.q > 0; + }).map(function(type) { + return type.encoding; + }); + } +} diff --git a/node_modules/express/node_modules/accepts/node_modules/negotiator/lib/language.js b/node_modules/express/node_modules/accepts/node_modules/negotiator/lib/language.js new file mode 100644 index 0000000..63036c7 --- /dev/null +++ b/node_modules/express/node_modules/accepts/node_modules/negotiator/lib/language.js @@ -0,0 +1,103 @@ +module.exports = preferredLanguages; +preferredLanguages.preferredLanguages = preferredLanguages; + +function parseAcceptLanguage(accept) { + return accept.split(',').map(function(e) { + return parseLanguage(e.trim()); + }).filter(function(e) { + return e; + }); +} + +function parseLanguage(s) { + var match = s.match(/^\s*(\S+?)(?:-(\S+?))?\s*(?:;(.*))?$/); + if (!match) return null; + + var prefix = match[1], + suffix = match[2], + full = prefix; + + if (suffix) full += "-" + suffix; + + var q = 1; + if (match[3]) { + var params = match[3].split(';') + for (var i = 0; i < params.length; i ++) { + var p = params[i].split('='); + if (p[0] === 'q') q = parseFloat(p[1]); + } + } + + return { + prefix: prefix, + suffix: suffix, + q: q, + full: full + }; +} + +function getLanguagePriority(language, accepted) { + return (accepted.map(function(a){ + return specify(language, a); + }).filter(Boolean).sort(function (a, b) { + if(a.s == b.s) { + return a.q > b.q ? -1 : 1; + } else { + return a.s > b.s ? -1 : 1; + } + })[0] || {s: 0, q: 0}); +} + +function specify(language, spec) { + var p = parseLanguage(language) + if (!p) return null; + var s = 0; + if(spec.full === p.full){ + s |= 4; + } else if (spec.prefix === p.full) { + s |= 2; + } else if (spec.full === p.prefix) { + s |= 1; + } else if (spec.full !== '*' ) { + return null + } + + return { + s: s, + q: spec.q, + } +}; + +function preferredLanguages(accept, provided) { + // RFC 2616 sec 14.4: no header = * + accept = parseAcceptLanguage(accept === undefined ? '*' : accept || ''); + if (provided) { + + var ret = provided.map(function(type) { + return [type, getLanguagePriority(type, accept)]; + }).filter(function(pair) { + return pair[1].q > 0; + }).sort(function(a, b) { + var pa = a[1]; + var pb = b[1]; + if(pa.q == pb.q) { + return pa.s < pb.s ? 1 : -1; + } else { + return pa.q < pb.q ? 1 : -1; + } + }).map(function(pair) { + return pair[0]; + }); + return ret; + + } else { + return accept.sort(function (a, b) { + // revsort + return a.q < b.q ? 1 : -1; + }).filter(function(type) { + return type.q > 0; + }).map(function(type) { + return type.full; + }); + } +} diff --git a/node_modules/express/node_modules/accepts/node_modules/negotiator/lib/mediaType.js b/node_modules/express/node_modules/accepts/node_modules/negotiator/lib/mediaType.js new file mode 100644 index 0000000..f4dc1ca --- /dev/null +++ b/node_modules/express/node_modules/accepts/node_modules/negotiator/lib/mediaType.js @@ -0,0 +1,125 @@ +module.exports = preferredMediaTypes; +preferredMediaTypes.preferredMediaTypes = preferredMediaTypes; + +function parseAccept(accept) { + return accept.split(',').map(function(e) { + return parseMediaType(e.trim()); + }).filter(function(e) { + return e; + }); +}; + +function parseMediaType(s) { + var match = s.match(/\s*(\S+?)\/([^;\s]+)\s*(?:;(.*))?/); + if (!match) return null; + + var type = match[1], + subtype = match[2], + full = "" + type + "/" + subtype, + params = {}, + q = 1; + + if (match[3]) { + params = match[3].split(';').map(function(s) { + return s.trim().split('='); + }).reduce(function (set, p) { + set[p[0]] = p[1]; + return set + }, params); + + if (params.q != null) { + q = parseFloat(params.q); + delete params.q; + } + } + + return { + type: type, + subtype: subtype, + params: params, + q: q, + full: full + }; +} + +function getMediaTypePriority(type, accepted) { + return (accepted.map(function(a) { + return specify(type, a); + }).filter(Boolean).sort(function (a, b) { + if(a.s == b.s) { + return a.q > b.q ? -1 : 1; + } else { + return a.s > b.s ? -1 : 1; + } + })[0] || {s: 0, q: 0}); +} + +function specify(type, spec) { + var p = parseMediaType(type); + var s = 0; + + if (!p) { + return null; + } + + if(spec.type == p.type) { + s |= 4 + } else if(spec.type != '*') { + return null; + } + + if(spec.subtype == p.subtype) { + s |= 2 + } else if(spec.subtype != '*') { + return null; + } + + var keys = Object.keys(spec.params); + if (keys.length > 0) { + if (keys.every(function (k) { + return spec.params[k] == '*' || spec.params[k] == p.params[k]; + })) { + s |= 1 + } else { + return null + } + } + + return { + q: spec.q, + s: s, + } + +} + +function preferredMediaTypes(accept, provided) { + // RFC 2616 sec 14.2: no header = */* + accept = parseAccept(accept === undefined ? '*/*' : accept || ''); + if (provided) { + return provided.map(function(type) { + return [type, getMediaTypePriority(type, accept)]; + }).filter(function(pair) { + return pair[1].q > 0; + }).sort(function(a, b) { + var pa = a[1]; + var pb = b[1]; + if(pa.q == pb.q) { + return pa.s < pb.s ? 1 : -1; + } else { + return pa.q < pb.q ? 1 : -1; + } + }).map(function(pair) { + return pair[0]; + }); + + } else { + return accept.sort(function (a, b) { + // revsort + return a.q < b.q ? 1 : -1; + }).filter(function(type) { + return type.q > 0; + }).map(function(type) { + return type.full; + }); + } +} diff --git a/node_modules/express/node_modules/accepts/node_modules/negotiator/lib/negotiator.js b/node_modules/express/node_modules/accepts/node_modules/negotiator/lib/negotiator.js new file mode 100644 index 0000000..ba0c48b --- /dev/null +++ b/node_modules/express/node_modules/accepts/node_modules/negotiator/lib/negotiator.js @@ -0,0 +1,37 @@ +module.exports = Negotiator; +Negotiator.Negotiator = Negotiator; + +function Negotiator(request) { + if (!(this instanceof Negotiator)) return new Negotiator(request); + this.request = request; +} + +var set = { charset: 'accept-charset', + encoding: 'accept-encoding', + language: 'accept-language', + mediaType: 'accept' }; + + +function capitalize(string){ + return string.charAt(0).toUpperCase() + string.slice(1); +} + +Object.keys(set).forEach(function (k) { + var header = set[k], + method = require('./'+k+'.js'), + singular = k, + plural = k + 's'; + + Negotiator.prototype[plural] = function (available) { + return method(this.request.headers[header], available); + }; + + Negotiator.prototype[singular] = function(available) { + var set = this[plural](available); + if (set) return set[0]; + }; + + // Keep preferred* methods for legacy compatibility + Negotiator.prototype['preferred'+capitalize(plural)] = Negotiator.prototype[plural]; + Negotiator.prototype['preferred'+capitalize(singular)] = Negotiator.prototype[singular]; +}) diff --git a/node_modules/express/node_modules/accepts/node_modules/negotiator/package.json b/node_modules/express/node_modules/accepts/node_modules/negotiator/package.json new file mode 100644 index 0000000..73193ba --- /dev/null +++ b/node_modules/express/node_modules/accepts/node_modules/negotiator/package.json @@ -0,0 +1,66 @@ +{ + "name": "negotiator", + "description": "HTTP content negotiation", + "version": "0.4.7", + "author": { + "name": "Federico Romero", + "email": "federico.romero@outboxlabs.com" + }, + "contributors": [ + { + "name": "Isaac Z. Schlueter", + "email": "i@izs.me", + "url": "http://blog.izs.me/" + } + ], + "repository": { + "type": "git", + "url": "git://github.com/federomero/negotiator.git" + }, + "keywords": [ + "http", + "content negotiation", + "accept", + "accept-language", + "accept-encoding", + "accept-charset" + ], + "engine": "node >= 0.6", + "license": "MIT", + "devDependencies": { + "nodeunit": "0.8.x" + }, + "scripts": { + "test": "nodeunit test" + }, + "optionalDependencies": {}, + "engines": { + "node": "*" + }, + "main": "lib/negotiator.js", + "bugs": { + "url": "https://github.com/federomero/negotiator/issues" + }, + "homepage": "https://github.com/federomero/negotiator", + "dependencies": {}, + "_id": "negotiator@0.4.7", + "dist": { + "shasum": "a4160f7177ec806738631d0d3052325da42abdc8", + "tarball": "http://registry.npmjs.org/negotiator/-/negotiator-0.4.7.tgz" + }, + "_from": "negotiator@0.4.7", + "_npmVersion": "1.4.3", + "_npmUser": { + "name": "federomero", + "email": "federomero@gmail.com" + }, + "maintainers": [ + { + "name": "federomero", + "email": "federomero@gmail.com" + } + ], + "directories": {}, + "_shasum": "a4160f7177ec806738631d0d3052325da42abdc8", + "_resolved": "https://registry.npmjs.org/negotiator/-/negotiator-0.4.7.tgz" +} diff --git a/node_modules/express/node_modules/accepts/node_modules/negotiator/readme.md b/node_modules/express/node_modules/accepts/node_modules/negotiator/readme.md new file mode 100644 index 0000000..d982a9c --- /dev/null +++ b/node_modules/express/node_modules/accepts/node_modules/negotiator/readme.md @@ -0,0 +1,132 @@ +# Negotiator [![Build Status](https://travis-ci.org/federomero/negotiator.png)](https://travis-ci.org/federomero/negotiator) + +An HTTP content negotiator for node.js written in javascript. + +# Accept Negotiation + + Negotiator = require('negotiator') + + availableMediaTypes = ['text/html', 'text/plain', 'application/json'] + + // The negotiator constructor receives a request object + negotiator = new Negotiator(request) + + // Let's say Accept header is 'text/html, application/*;q=0.2, image/jpeg;q=0.8' + + negotiator.mediaTypes() + // -> ['text/html', 'image/jpeg', 'application/*'] + + negotiator.mediaTypes(availableMediaTypes) + // -> ['text/html', 'application/json'] + + negotiator.mediaType(availableMediaTypes) + // -> 'text/html' + +You can check a working example at `examples/accept.js`. + +## Methods + +`mediaTypes(availableMediaTypes)`: + +Returns an array of preferred media types ordered by priority from a list of available media types. + +`mediaType(availableMediaType)`: + +Returns the top preferred media type from a list of available media types. + +# Accept-Language Negotiation + + Negotiator = require('negotiator') + + negotiator = new Negotiator(request) + + availableLanguages = 'en', 'es', 'fr' + + // Let's say Accept-Language header is 'en;q=0.8, es, pt' + + negotiator.languages() + // -> ['es', 'pt', 'en'] + + negotiator.languages(availableLanguages) + // -> ['es', 'en'] + + language = negotiator.language(availableLanguages) + // -> 'es' + +You can check a working example at `examples/language.js`. + +## Methods + +`languages(availableLanguages)`: + +Returns an array of preferred languages ordered by priority from a list of available languages. + +`language(availableLanguages)`: + +Returns the top preferred language from a list of available languages. + +# Accept-Charset Negotiation + + Negotiator = require('negotiator') + + availableCharsets = ['utf-8', 'iso-8859-1', 'iso-8859-5'] + + negotiator = new Negotiator(request) + + // Let's say Accept-Charset header is 'utf-8, iso-8859-1;q=0.8, utf-7;q=0.2' + + negotiator.charsets() + // -> ['utf-8', 'iso-8859-1', 'utf-7'] + + negotiator.charsets(availableCharsets) + // -> ['utf-8', 'iso-8859-1'] + + negotiator.charset(availableCharsets) + // -> 'utf-8' + +You can check a working example at `examples/charset.js`. + +## Methods + +`charsets(availableCharsets)`: + +Returns an array of preferred charsets ordered by priority from a list of available charsets. + +`charset(availableCharsets)`: + +Returns the top preferred charset from a list of available charsets. + +# Accept-Encoding Negotiation + + Negotiator = require('negotiator').Negotiator + + availableEncodings = ['identity', 'gzip'] + + negotiator = new Negotiator(request) + + // Let's say Accept-Encoding header is 'gzip, compress;q=0.2, identity;q=0.5' + + negotiator.encodings() + // -> ['gzip', 'identity', 'compress'] + + negotiator.encodings(availableEncodings) + // -> ['gzip', 'identity'] + + negotiator.encoding(availableEncodings) + // -> 'gzip' + +You can check a working example at `examples/encoding.js`. + +## Methods + +`encodings(availableEncodings)`: + +Returns an array of preferred encodings ordered by priority from a list of available encodings. + +`encoding(availableEncodings)`: + +Returns the top preferred encoding from a list of available encodings. + +# License + +MIT diff --git a/node_modules/express/node_modules/accepts/package.json b/node_modules/express/node_modules/accepts/package.json new file mode 100644 index 0000000..441d8dc --- /dev/null +++ b/node_modules/express/node_modules/accepts/package.json @@ -0,0 +1,91 @@ +{ + "name": "accepts", + "description": "Higher-level content negotiation", + "version": "1.1.0", + "author": { + "name": "Jonathan Ong", + "email": "me@jongleberry.com", + "url": "http://jongleberry.com" + }, + "license": "MIT", + "repository": { + "type": "git", + "url": "https://github.com/jshttp/accepts" + }, + "dependencies": { + "mime-types": "~2.0.0", + "negotiator": "0.4.7" + }, + "devDependencies": { + "istanbul": "~0.3.0", + "mocha": "1", + "should": "4" + }, + "engines": { + "node": ">= 0.8.0" + }, + "scripts": { + "test": "mocha --require should --reporter dot test/", + "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --require should --reporter dot test/", + "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --require should --reporter spec test/" + }, + "keywords": [ + "content", + "negotiation", + "accept", + "accepts" + ], + "files": [ + "index.js" + ], + "gitHead": "564a01f1d1b4864365029a55773b765fb9e7756a", + "bugs": { + "url": "https://github.com/jshttp/accepts/issues" + }, + "homepage": "https://github.com/jshttp/accepts", + "_id": "accepts@1.1.0", + "_shasum": "43ba6d946374c80f91823eaec6bb43dc4955500b", + "_from": "accepts@~1.1.0", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + }, + "maintainers": [ + { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + }, + { + "name": "federomero", + "email": "federomero@gmail.com" + }, + { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + { + "name": "tjholowaychuk", + "email": "tj@vision-media.ca" + }, + { + "name": "shtylman", + "email": "shtylman@gmail.com" + }, + { + "name": "mscdex", + "email": "mscdex@mscdex.net" + }, + { + "name": "fishrock123", + "email": "fishrock123@rocketmail.com" + } + ], + "dist": { + "shasum": "43ba6d946374c80f91823eaec6bb43dc4955500b", + "tarball": "http://registry.npmjs.org/accepts/-/accepts-1.1.0.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/accepts/-/accepts-1.1.0.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/express/node_modules/cookie-signature/.npmignore b/node_modules/express/node_modules/cookie-signature/.npmignore new file mode 100644 index 0000000..f1250e5 --- /dev/null +++ b/node_modules/express/node_modules/cookie-signature/.npmignore @@ -0,0 +1,4 @@ +support +test +examples +*.sock diff --git a/node_modules/express/node_modules/cookie-signature/History.md b/node_modules/express/node_modules/cookie-signature/History.md new file mode 100644 index 0000000..2bbc4b3 --- /dev/null +++ b/node_modules/express/node_modules/cookie-signature/History.md @@ -0,0 +1,27 @@ +1.0.4 / 2014-06-25 +================== + + * corrected avoidance of timing attacks (thanks @tenbits!) + + +1.0.3 / 2014-01-28 +================== + + * [incorrect] fix for timing attacks + +1.0.2 / 2014-01-28 +================== + + * fix missing repository warning + * fix typo in test + +1.0.1 / 2013-04-15 +================== + + * Revert "Changed underlying HMAC algo. to sha512." + * Revert "Fix for timing attacks on MAC verification." + +0.0.1 / 2010-01-03 +================== + + * Initial release diff --git a/node_modules/express/node_modules/cookie-signature/Makefile b/node_modules/express/node_modules/cookie-signature/Makefile new file mode 100644 index 0000000..4e9c8d3 --- /dev/null +++ b/node_modules/express/node_modules/cookie-signature/Makefile @@ -0,0 +1,7 @@ + +test: + @./node_modules/.bin/mocha \ + --require should \ + --reporter spec + +.PHONY: test \ No newline at end of file diff --git a/node_modules/express/node_modules/cookie-signature/Readme.md b/node_modules/express/node_modules/cookie-signature/Readme.md new file mode 100644 index 0000000..2559e84 --- /dev/null +++ b/node_modules/express/node_modules/cookie-signature/Readme.md @@ -0,0 +1,42 @@ + +# cookie-signature + + Sign and unsign cookies. + +## Example + +```js +var cookie = require('cookie-signature'); + +var val = cookie.sign('hello', 'tobiiscool'); +val.should.equal('hello.DGDUkGlIkCzPz+C0B064FNgHdEjox7ch8tOBGslZ5QI'); + +var val = cookie.sign('hello', 'tobiiscool'); +cookie.unsign(val, 'tobiiscool').should.equal('hello'); +cookie.unsign(val, 'luna').should.be.false; +``` + +## License + +(The MIT License) + +Copyright (c) 2012 LearnBoost <tj@learnboost.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. \ No newline at end of file diff --git a/node_modules/express/node_modules/cookie-signature/index.js b/node_modules/express/node_modules/cookie-signature/index.js new file mode 100644 index 0000000..b63bf84 --- /dev/null +++ b/node_modules/express/node_modules/cookie-signature/index.js @@ -0,0 +1,51 @@ +/** + * Module dependencies. + */ + +var crypto = require('crypto'); + +/** + * Sign the given `val` with `secret`. + * + * @param {String} val + * @param {String} secret + * @return {String} + * @api private + */ + +exports.sign = function(val, secret){ + if ('string' != typeof val) throw new TypeError('cookie required'); + if ('string' != typeof secret) throw new TypeError('secret required'); + return val + '.' + crypto + .createHmac('sha256', secret) + .update(val) + .digest('base64') + .replace(/\=+$/, ''); +}; + +/** + * Unsign and decode the given `val` with `secret`, + * returning `false` if the signature is invalid. + * + * @param {String} val + * @param {String} secret + * @return {String|Boolean} + * @api private + */ + +exports.unsign = function(val, secret){ + if ('string' != typeof val) throw new TypeError('cookie required'); + if ('string' != typeof secret) throw new TypeError('secret required'); + var str = val.slice(0, val.lastIndexOf('.')) + , mac = exports.sign(str, secret); + + return sha1(mac) == sha1(val) ? str : false; +}; + +/** + * Private + */ + +function sha1(str){ + return crypto.createHash('sha1').update(str).digest('hex'); +} diff --git a/node_modules/express/node_modules/cookie-signature/package.json b/node_modules/express/node_modules/cookie-signature/package.json new file mode 100644 index 0000000..741961f --- /dev/null +++ b/node_modules/express/node_modules/cookie-signature/package.json @@ -0,0 +1,56 @@ +{ + "name": "cookie-signature", + "version": "1.0.5", + "description": "Sign and unsign cookies", + "keywords": [ + "cookie", + "sign", + "unsign" + ], + "author": { + "name": "TJ Holowaychuk", + "email": "tj@learnboost.com" + }, + "license": "MIT", + "repository": { + "type": "git", + "url": "https://github.com/visionmedia/node-cookie-signature.git" + }, + "dependencies": {}, + "devDependencies": { + "mocha": "*", + "should": "*" + }, + "main": "index", + "gitHead": "73ed69b511b3ef47555d71b4ed1deea9e5ed6e1f", + "bugs": { + "url": "https://github.com/visionmedia/node-cookie-signature/issues" + }, + "homepage": "https://github.com/visionmedia/node-cookie-signature", + "_id": "cookie-signature@1.0.5", + "scripts": {}, + "_shasum": "a122e3f1503eca0f5355795b0711bb2368d450f9", + "_from": "cookie-signature@1.0.5", + "_npmVersion": "1.4.20", + "_npmUser": { + "name": "natevw", + "email": "natevw@yahoo.com" + }, + "maintainers": [ + { + "name": "tjholowaychuk", + "email": "tj@vision-media.ca" + }, + { + "name": "natevw", + "email": "natevw@yahoo.com" + } + ], + "dist": { + "shasum": "a122e3f1503eca0f5355795b0711bb2368d450f9", + "tarball": "http://registry.npmjs.org/cookie-signature/-/cookie-signature-1.0.5.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/cookie-signature/-/cookie-signature-1.0.5.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/express/node_modules/cookie/.npmignore b/node_modules/express/node_modules/cookie/.npmignore new file mode 100644 index 0000000..efab07f --- /dev/null +++ b/node_modules/express/node_modules/cookie/.npmignore @@ -0,0 +1,2 @@ +test +.travis.yml diff --git a/node_modules/express/node_modules/cookie/LICENSE b/node_modules/express/node_modules/cookie/LICENSE new file mode 100644 index 0000000..249d9de --- /dev/null +++ b/node_modules/express/node_modules/cookie/LICENSE @@ -0,0 +1,9 @@ +// MIT License + +Copyright (C) Roman Shtylman + +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/node_modules/express/node_modules/cookie/README.md b/node_modules/express/node_modules/cookie/README.md new file mode 100644 index 0000000..3170b4b --- /dev/null +++ b/node_modules/express/node_modules/cookie/README.md @@ -0,0 +1,44 @@ +# cookie [![Build Status](https://secure.travis-ci.org/defunctzombie/node-cookie.png?branch=master)](http://travis-ci.org/defunctzombie/node-cookie) # + +cookie is a basic cookie parser and serializer. It doesn't make assumptions about how you are going to deal with your cookies. It basically just provides a way to read and write the HTTP cookie headers. + +See [RFC6265](http://tools.ietf.org/html/rfc6265) for details about the http header for cookies. + +## how? + +``` +npm install cookie +``` + +```javascript +var cookie = require('cookie'); + +var hdr = cookie.serialize('foo', 'bar'); +// hdr = 'foo=bar'; + +var cookies = cookie.parse('foo=bar; cat=meow; dog=ruff'); +// cookies = { foo: 'bar', cat: 'meow', dog: 'ruff' }; +``` + +## more + +The serialize function takes a third parameter, an object, to set cookie options. See the RFC for valid values. + +### path +> cookie path + +### expires +> absolute expiration date for the cookie (Date object) + +### maxAge +> relative max age of the cookie from when the client receives it (seconds) + +### domain +> domain for the cookie + +### secure +> true or false + +### httpOnly +> true or false + diff --git a/node_modules/express/node_modules/cookie/index.js b/node_modules/express/node_modules/cookie/index.js new file mode 100644 index 0000000..00d54a7 --- /dev/null +++ b/node_modules/express/node_modules/cookie/index.js @@ -0,0 +1,75 @@ + +/// Serialize the a name value pair into a cookie string suitable for +/// http headers. An optional options object specified cookie parameters +/// +/// serialize('foo', 'bar', { httpOnly: true }) +/// => "foo=bar; httpOnly" +/// +/// @param {String} name +/// @param {String} val +/// @param {Object} options +/// @return {String} +var serialize = function(name, val, opt){ + opt = opt || {}; + var enc = opt.encode || encode; + var pairs = [name + '=' + enc(val)]; + + if (null != opt.maxAge) { + var maxAge = opt.maxAge - 0; + if (isNaN(maxAge)) throw new Error('maxAge should be a Number'); + pairs.push('Max-Age=' + maxAge); + } + + if (opt.domain) pairs.push('Domain=' + opt.domain); + if (opt.path) pairs.push('Path=' + opt.path); + if (opt.expires) pairs.push('Expires=' + opt.expires.toUTCString()); + if (opt.httpOnly) pairs.push('HttpOnly'); + if (opt.secure) pairs.push('Secure'); + + return pairs.join('; '); +}; + +/// Parse the given cookie header string into an object +/// The object has the various cookies as keys(names) => values +/// @param {String} str +/// @return {Object} +var parse = function(str, opt) { + opt = opt || {}; + var obj = {} + var pairs = str.split(/; */); + var dec = opt.decode || decode; + + pairs.forEach(function(pair) { + var eq_idx = pair.indexOf('=') + + // skip things that don't look like key=value + if (eq_idx < 0) { + return; + } + + var key = pair.substr(0, eq_idx).trim() + var val = pair.substr(++eq_idx, pair.length).trim(); + + // quoted values + if ('"' == val[0]) { + val = val.slice(1, -1); + } + + // only assign once + if (undefined == obj[key]) { + try { + obj[key] = dec(val); + } catch (e) { + obj[key] = val; + } + } + }); + + return obj; +}; + +var encode = encodeURIComponent; +var decode = decodeURIComponent; + +module.exports.serialize = serialize; +module.exports.parse = parse; diff --git a/node_modules/express/node_modules/cookie/package.json b/node_modules/express/node_modules/cookie/package.json new file mode 100644 index 0000000..7dbb395 --- /dev/null +++ b/node_modules/express/node_modules/cookie/package.json @@ -0,0 +1,54 @@ +{ + "author": { + "name": "Roman Shtylman", + "email": "shtylman@gmail.com" + }, + "name": "cookie", + "description": "cookie parsing and serialization", + "version": "0.1.2", + "repository": { + "type": "git", + "url": "git://github.com/shtylman/node-cookie.git" + }, + "keywords": [ + "cookie", + "cookies" + ], + "main": "index.js", + "scripts": { + "test": "mocha" + }, + "dependencies": {}, + "devDependencies": { + "mocha": "1.x.x" + }, + "optionalDependencies": {}, + "engines": { + "node": "*" + }, + "bugs": { + "url": "https://github.com/shtylman/node-cookie/issues" + }, + "homepage": "https://github.com/shtylman/node-cookie", + "_id": "cookie@0.1.2", + "dist": { + "shasum": "72fec3d24e48a3432073d90c12642005061004b1", + "tarball": "http://registry.npmjs.org/cookie/-/cookie-0.1.2.tgz" + }, + "_from": "cookie@0.1.2", + "_npmVersion": "1.4.6", + "_npmUser": { + "name": "shtylman", + "email": "shtylman@gmail.com" + }, + "maintainers": [ + { + "name": "shtylman", + "email": "shtylman@gmail.com" + } + ], + "directories": {}, + "_shasum": "72fec3d24e48a3432073d90c12642005061004b1", + "_resolved": "https://registry.npmjs.org/cookie/-/cookie-0.1.2.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/express/node_modules/depd/History.md b/node_modules/express/node_modules/depd/History.md new file mode 100644 index 0000000..800eab1 --- /dev/null +++ b/node_modules/express/node_modules/depd/History.md @@ -0,0 +1,62 @@ +0.4.5 / 2014-09-09 +================== + + * Improve call speed to functions using the function wrapper + * Support Node.js 0.6 + +0.4.4 / 2014-07-27 +================== + + * Work-around v8 generating empty stack traces + +0.4.3 / 2014-07-26 +================== + + * Fix exception when global `Error.stackTraceLimit` is too low + +0.4.2 / 2014-07-19 +================== + + * Correct call site for wrapped functions and properties + +0.4.1 / 2014-07-19 +================== + + * Improve automatic message generation for function properties + +0.4.0 / 2014-07-19 +================== + + * Add `TRACE_DEPRECATION` environment variable + * Remove non-standard grey color from color output + * Support `--no-deprecation` argument + * Support `--trace-deprecation` argument + * Support `deprecate.property(fn, prop, message)` + +0.3.0 / 2014-06-16 +================== + + * Add `NO_DEPRECATION` environment variable + +0.2.0 / 2014-06-15 +================== + + * Add `deprecate.property(obj, prop, message)` + * Remove `supports-color` dependency for node.js 0.8 + +0.1.0 / 2014-06-15 +================== + + * Add `deprecate.function(fn, message)` + * Add `process.on('deprecation', fn)` emitter + * Automatically generate message when omitted from `deprecate()` + +0.0.1 / 2014-06-15 +================== + + * Fix warning for dynamic calls at singe call site + +0.0.0 / 2014-06-15 +================== + + * Initial implementation diff --git a/node_modules/express/node_modules/depd/LICENSE b/node_modules/express/node_modules/depd/LICENSE new file mode 100644 index 0000000..b7dce6c --- /dev/null +++ b/node_modules/express/node_modules/depd/LICENSE @@ -0,0 +1,22 @@ +(The MIT License) + +Copyright (c) 2014 Douglas Christopher Wilson + +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/node_modules/express/node_modules/depd/Readme.md b/node_modules/express/node_modules/depd/Readme.md new file mode 100644 index 0000000..098953e --- /dev/null +++ b/node_modules/express/node_modules/depd/Readme.md @@ -0,0 +1,266 @@ +# depd + +[![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] +[![Gittip][gittip-image]][gittip-url] + +Deprecate all the things + +> With great modules comes great responsibility; mark things deprecated! + +## Install + +```sh +$ npm install depd +``` + +## API + +```js +var deprecate = require('depd')('my-module') +``` + +This library allows you to display deprecation messages to your users. +This library goes above and beyond with deprecation warnings by +introspecting the call stack (but only the bits that it is interested +in). + +Instead of just warning on the first invocation of a deprecated +function and never again, this module will warn on the first invocation +of a deprecated function per unique call site, making it ideal to alert +users of all deprecated uses across the code base, rather than just +whatever happens to execute first. + +The deprecation warnings from this module also include the file and line +information for the call into the module that the deprecated function was +in. + +### depd(namespace) + +Create a new deprecate function that uses the given namespace name in the +messages and will display the call site prior to the stack entering the +file this function was called from. It is highly suggested you use the +name of your module as the namespace. + +### deprecate(message) + +Call this function from deprecated code to display a deprecation message. +This message will appear once per unique caller site. Caller site is the +first call site in the stack in a different file from the caller of this +function. + +If the message is omitted, a message is generated for you based on the site +of the `deprecate()` call and will display the name of the function called, +similar to the name displayed in a stack trace. + +### deprecate.function(fn, message) + +Call this function to wrap a given function in a deprecation message on any +call to the function. An optional message can be supplied to provide a custom +message. + +### deprecate.property(obj, prop, message) + +Call this function to wrap a given property on object in a deprecation message +on any accessing or setting of the property. An optional message can be supplied +to provide a custom message. + +The method must be called on the object where the property belongs (not +inherited from the prototype). + +If the property is a data descriptor, it will be converted to an accessor +descriptor in order to display the deprecation message. + +### process.on('deprecation', fn) + +This module will allow easy capturing of deprecation errors by emitting the +errors as the type "deprecation" on the global `process`. If there are no +listeners for this type, the errors are written to STDERR as normal, but if +there are any listeners, nothing will be written to STDERR and instead only +emitted. From there, you can write the errors in a different format or to a +logging source. + +The error represents the deprecation and is emitted only once with the same +rules as writing to STDERR. The error has the following properties: + + - `message` - This is the message given by the library + - `name` - This is always `'DeprecationError'` + - `namespace` - This is the namespace the deprecation came from + - `stack` - This is the stack of the call to the deprecated thing + +Example `error.stack` output: + +``` +DeprecationError: my-cool-module deprecated oldfunction + at Object. ([eval]-wrapper:6:22) + at Module._compile (module.js:456:26) + at evalScript (node.js:532:25) + at startup (node.js:80:7) + at node.js:902:3 +``` + +### process.env.NO_DEPRECATION + +As a user of modules that are deprecated, the environment variable `NO_DEPRECATION` +is provided as a quick solution to silencing deprecation warnings from being +output. The format of this is similar to that of `DEBUG`: + +```sh +$ NO_DEPRECATION=my-module,othermod node app.js +``` + +This will suppress deprecations from being output for "my-module" and "othermod". +The value is a list of comma-separated namespaces. To suppress every warning +across all namespaces, use the value `*` for a namespace. + +Providing the argument `--no-deprecation` to the `node` executable will suppress +all deprecations (only available in Node.js 0.8 or higher). + +**NOTE** This will not suppress the deperecations given to any "deprecation" +event listeners, just the output to STDERR. + +### process.env.TRACE_DEPRECATION + +As a user of modules that are deprecated, the environment variable `TRACE_DEPRECATION` +is provided as a solution to getting more detailed location information in deprecation +warnings by including the entire stack trace. The format of this is the same as +`NO_DEPRECATION`: + +```sh +$ TRACE_DEPRECATION=my-module,othermod node app.js +``` + +This will include stack traces for deprecations being output for "my-module" and +"othermod". The value is a list of comma-separated namespaces. To trace every +warning across all namespaces, use the value `*` for a namespace. + +Providing the argument `--trace-deprecation` to the `node` executable will trace +all deprecations (only available in Node.js 0.8 or higher). + +**NOTE** This will not trace the deperecations silenced by `NO_DEPRECATION`. + +## Display + +![message](files/message.png) + +When a user calls a function in your library that you mark deprecated, they +will see the following written to STDERR (in the given colors, similar colors +and layout to the `debug` module): + +``` +bright cyan bright yellow +| | reset cyan +| | | | +▼ ▼ ▼ ▼ +my-cool-module deprecated oldfunction [eval]-wrapper:6:22 +▲ ▲ ▲ ▲ +| | | | +namespace | | location of mycoolmod.oldfunction() call + | deprecation message + the word "deprecated" +``` + +If the user redirects their STDERR to a file or somewhere that does not support +colors, they see (similar layout to the `debug` module): + +``` +Sun, 15 Jun 2014 05:21:37 GMT my-cool-module deprecated oldfunction at [eval]-wrapper:6:22 +▲ ▲ ▲ ▲ ▲ +| | | | | +timestamp of message namespace | | location of mycoolmod.oldfunction() call + | deprecation message + the word "deprecated" +``` + +## Examples + +### Deprecating all calls to a function + +This will display a deprecated message about "oldfunction" being deprecated +from "my-module" on STDERR. + +```js +var deprecate = require('depd')('my-cool-module') + +// message automatically derived from function name +// Object.oldfunction +exports.oldfunction = deprecate.function(function oldfunction() { + // all calls to function are deprecated +}) + +// specific message +exports.oldfunction = deprecate.function(function () { + // all calls to function are deprecated +}, 'oldfunction') +``` + +### Conditionally deprecating a function call + +This will display a deprecated message about "weirdfunction" being deprecated +from "my-module" on STDERR when called with less than 2 arguments. + +```js +var deprecate = require('depd')('my-cool-module') + +exports.weirdfunction = function () { + if (arguments.length < 2) { + // calls with 0 or 1 args are deprecated + deprecate('weirdfunction args < 2') + } +} +``` + +When calling `deprecate` as a function, the warning is counted per call site +within your own module, so you can display different deprecations depending +on different situations and the users will still get all the warnings: + +```js +var deprecate = require('depd')('my-cool-module') + +exports.weirdfunction = function () { + if (arguments.length < 2) { + // calls with 0 or 1 args are deprecated + deprecate('weirdfunction args < 2') + } else if (typeof arguments[0] !== 'string') { + // calls with non-string first argument are deprecated + deprecate('weirdfunction non-string first arg') + } +} +``` + +### Deprecating property access + +This will display a deprecated message about "oldprop" being deprecated +from "my-module" on STDERR when accessed. A deprecation will be displayed +when setting the value and when getting the value. + +```js +var deprecate = require('depd')('my-cool-module') + +exports.oldprop = 'something' + +// message automatically derives from property name +deprecate.property(exports, 'oldprop') + +// explicit message +deprecate.property(exports, 'oldprop', 'oldprop >= 0.10') +``` + +## License + +[MIT](LICENSE) + +[npm-version-image]: https://img.shields.io/npm/v/depd.svg?style=flat +[npm-downloads-image]: https://img.shields.io/npm/dm/depd.svg?style=flat +[npm-url]: https://npmjs.org/package/depd +[travis-image]: https://img.shields.io/travis/dougwilson/nodejs-depd.svg?style=flat +[travis-url]: https://travis-ci.org/dougwilson/nodejs-depd +[coveralls-image]: https://img.shields.io/coveralls/dougwilson/nodejs-depd.svg?style=flat +[coveralls-url]: https://coveralls.io/r/dougwilson/nodejs-depd?branch=master +[node-image]: https://img.shields.io/node/v/depd.svg?style=flat +[node-url]: http://nodejs.org/download/ +[gittip-image]: https://img.shields.io/gittip/dougwilson.svg?style=flat +[gittip-url]: https://www.gittip.com/dougwilson/ diff --git a/node_modules/express/node_modules/depd/index.js b/node_modules/express/node_modules/depd/index.js new file mode 100644 index 0000000..4fee4d9 --- /dev/null +++ b/node_modules/express/node_modules/depd/index.js @@ -0,0 +1,522 @@ +/*! + * depd + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module dependencies. + */ + +var callSiteToString = require('./lib/compat').callSiteToString +var EventEmitter = require('events').EventEmitter +var relative = require('path').relative + +/** + * Module exports. + */ + +module.exports = depd + +/** + * Get the path to base files on. + */ + +var basePath = process.cwd() + +/** + * Get listener count on event emitter. + */ + +/*istanbul ignore next*/ +var eventListenerCount = EventEmitter.listenerCount + || function (emitter, type) { return emitter.listeners(type).length } + +/** + * Determine if namespace is contained in the string. + */ + +function containsNamespace(str, namespace) { + var val = str.split(/[ ,]+/) + + namespace = String(namespace).toLowerCase() + + for (var i = 0 ; i < val.length; i++) { + if (!(str = val[i])) continue; + + // namespace contained + if (str === '*' || str.toLowerCase() === namespace) { + return true + } + } + + return false +} + +/** + * Convert a data descriptor to accessor descriptor. + */ + +function convertDataDescriptorToAccessor(obj, prop, message) { + var descriptor = Object.getOwnPropertyDescriptor(obj, prop) + var value = descriptor.value + + descriptor.get = function getter() { return value } + + if (descriptor.writable) { + descriptor.set = function setter(val) { return value = val } + } + + delete descriptor.value + delete descriptor.writable + + Object.defineProperty(obj, prop, descriptor) + + return descriptor +} + +/** + * Create arguments string to keep arity. + */ + +function createArgumentsString(arity) { + var str = '' + + for (var i = 0; i < arity; i++) { + str += ', arg' + i + } + + return str.substr(2) +} + +/** + * Create stack string from stack. + */ + +function createStackString(stack) { + var str = this.name + ': ' + this.namespace + + if (this.message) { + str += ' deprecated ' + this.message + } + + for (var i = 0; i < stack.length; i++) { + str += '\n at ' + callSiteToString(stack[i]) + } + + return str +} + +/** + * Create deprecate for namespace in caller. + */ + +function depd(namespace) { + if (!namespace) { + throw new TypeError('argument namespace is required') + } + + var stack = getStack() + var site = callSiteLocation(stack[1]) + var file = site[0] + + function deprecate(message) { + // call to self as log + log.call(deprecate, message) + } + + deprecate._file = file + deprecate._ignored = isignored(namespace) + deprecate._namespace = namespace + deprecate._traced = istraced(namespace) + deprecate._warned = Object.create(null) + + deprecate.function = wrapfunction + deprecate.property = wrapproperty + + return deprecate +} + +/** + * Determine if namespace is ignored. + */ + +function isignored(namespace) { + /* istanbul ignore next: tested in a child processs */ + if (process.noDeprecation) { + // --no-deprecation support + return true + } + + var str = process.env.NO_DEPRECATION || '' + + // namespace ignored + return containsNamespace(str, namespace) +} + +/** + * Determine if namespace is traced. + */ + +function istraced(namespace) { + /* istanbul ignore next: tested in a child processs */ + if (process.traceDeprecation) { + // --trace-deprecation support + return true + } + + var str = process.env.TRACE_DEPRECATION || '' + + // namespace traced + return containsNamespace(str, namespace) +} + +/** + * Display deprecation message. + */ + +function log(message, site) { + var haslisteners = eventListenerCount(process, 'deprecation') !== 0 + + // abort early if no destination + if (!haslisteners && this._ignored) { + return + } + + var caller + var callFile + var callSite + var i = 0 + var seen = false + var stack = getStack() + var file = this._file + + if (site) { + // provided site + callSite = callSiteLocation(stack[1]) + callSite.name = site.name + file = callSite[0] + } else { + // get call site + i = 2 + site = callSiteLocation(stack[i]) + callSite = site + } + + // get caller of deprecated thing in relation to file + for (; i < stack.length; i++) { + caller = callSiteLocation(stack[i]) + callFile = caller[0] + + if (callFile === file) { + seen = true + } else if (callFile === this._file) { + file = this._file + } else if (seen) { + break + } + } + + var key = caller + ? site.join(':') + '__' + caller.join(':') + : undefined + + if (key !== undefined && key in this._warned) { + // already warned + return + } + + this._warned[key] = true + + // generate automatic message from call site + if (!message) { + message = callSite === site || !callSite.name + ? defaultMessage(site) + : defaultMessage(callSite) + } + + // emit deprecation if listeners exist + if (haslisteners) { + var err = DeprecationError(this._namespace, message, stack.slice(i)) + process.emit('deprecation', err) + return + } + + // format and write message + var format = process.stderr.isTTY + ? formatColor + : formatPlain + var msg = format.call(this, message, caller, stack.slice(i)) + process.stderr.write(msg + '\n', 'utf8') + + return +} + +/** + * Get call site location as array. + */ + +function callSiteLocation(callSite) { + var file = callSite.getFileName() || '' + var line = callSite.getLineNumber() + var colm = callSite.getColumnNumber() + + if (callSite.isEval()) { + file = callSite.getEvalOrigin() + ', ' + file + } + + var site = [file, line, colm] + + site.callSite = callSite + site.name = callSite.getFunctionName() + + return site +} + +/** + * Generate a default message from the site. + */ + +function defaultMessage(site) { + var callSite = site.callSite + var funcName = site.name + var typeName = callSite.getTypeName() + + // make useful anonymous name + if (!funcName) { + funcName = '' + } + + // make useful type name + if (typeName === 'Function') { + typeName = callSite.getThis().name || typeName + } + + return callSite.getMethodName() + ? typeName + '.' + funcName + : funcName +} + +/** + * Format deprecation message without color. + */ + +function formatPlain(msg, caller, stack) { + var timestamp = new Date().toUTCString() + + var formatted = timestamp + + ' ' + this._namespace + + ' deprecated ' + msg + + // add stack trace + if (this._traced) { + for (var i = 0; i < stack.length; i++) { + formatted += '\n at ' + callSiteToString(stack[i]) + } + + return formatted + } + + if (caller) { + formatted += ' at ' + formatLocation(caller) + } + + return formatted +} + +/** + * Format deprecation message with color. + */ + +function formatColor(msg, caller, stack) { + var formatted = '\x1b[36;1m' + this._namespace + '\x1b[22;39m' // bold cyan + + ' \x1b[33;1mdeprecated\x1b[22;39m' // bold yellow + + ' \x1b[0m' + msg + '\x1b[39m' // reset + + // add stack trace + if (this._traced) { + for (var i = 0; i < stack.length; i++) { + formatted += '\n \x1b[36mat ' + callSiteToString(stack[i]) + '\x1b[39m' // cyan + } + + return formatted + } + + if (caller) { + formatted += ' \x1b[36m' + formatLocation(caller) + '\x1b[39m' // cyan + } + + return formatted +} + +/** + * Format call site location. + */ + +function formatLocation(callSite) { + return relative(basePath, callSite[0]) + + ':' + callSite[1] + + ':' + callSite[2] +} + +/** + * Get the stack as array of call sites. + */ + +function getStack() { + var limit = Error.stackTraceLimit + var obj = {} + var prep = Error.prepareStackTrace + + Error.prepareStackTrace = prepareObjectStackTrace + Error.stackTraceLimit = Math.max(10, limit) + + // capture the stack + Error.captureStackTrace(obj) + + // slice this function off the top + var stack = obj.stack.slice(1) + + Error.prepareStackTrace = prep + Error.stackTraceLimit = limit + + return stack +} + +/** + * Capture call site stack from v8. + */ + +function prepareObjectStackTrace(obj, stack) { + return stack +} + +/** + * Return a wrapped function in a deprecation message. + */ + +function wrapfunction(fn, message) { + if (typeof fn !== 'function') { + throw new TypeError('argument fn must be a function') + } + + var args = createArgumentsString(fn.length) + var deprecate = this + var stack = getStack() + var site = callSiteLocation(stack[1]) + + site.name = fn.name + + var deprecatedfn = eval('(function (' + args + ') {\n' + + '"use strict"\n' + + 'log.call(deprecate, message, site)\n' + + 'return fn.apply(this, arguments)\n' + + '})') + + return deprecatedfn +} + +/** + * Wrap property in a deprecation message. + */ + +function wrapproperty(obj, prop, message) { + if (!obj || (typeof obj !== 'object' && typeof obj !== 'function')) { + throw new TypeError('argument obj must be object') + } + + var descriptor = Object.getOwnPropertyDescriptor(obj, prop) + + if (!descriptor) { + throw new TypeError('must call property on owner object') + } + + if (!descriptor.configurable) { + throw new TypeError('property must be configurable') + } + + var deprecate = this + var stack = getStack() + var site = callSiteLocation(stack[1]) + + // set site name + site.name = prop + + // convert data descriptor + if ('value' in descriptor) { + descriptor = convertDataDescriptorToAccessor(obj, prop, message) + } + + var get = descriptor.get + var set = descriptor.set + + // wrap getter + if (typeof get === 'function') { + descriptor.get = function getter() { + log.call(deprecate, message, site) + return get.apply(this, arguments) + } + } + + // wrap setter + if (typeof set === 'function') { + descriptor.set = function setter() { + log.call(deprecate, message, site) + return set.apply(this, arguments) + } + } + + Object.defineProperty(obj, prop, descriptor) +} + +/** + * Create DeprecationError for deprecation + */ + +function DeprecationError(namespace, message, stack) { + var error = new Error() + var stackString + + Object.defineProperty(error, 'constructor', { + value: DeprecationError + }) + + Object.defineProperty(error, 'message', { + configurable: true, + enumerable: false, + value: message, + writable: true + }) + + Object.defineProperty(error, 'name', { + enumerable: false, + configurable: true, + value: 'DeprecationError', + writable: true + }) + + Object.defineProperty(error, 'namespace', { + configurable: true, + enumerable: false, + value: namespace, + writable: true + }) + + Object.defineProperty(error, 'stack', { + configurable: true, + enumerable: false, + get: function () { + if (stackString !== undefined) { + return stackString + } + + // prepare stack trace + return stackString = createStackString.call(this, stack) + }, + set: function setter(val) { + stackString = val + } + }) + + return error +} diff --git a/node_modules/express/node_modules/depd/lib/compat/buffer-concat.js b/node_modules/express/node_modules/depd/lib/compat/buffer-concat.js new file mode 100644 index 0000000..09d9721 --- /dev/null +++ b/node_modules/express/node_modules/depd/lib/compat/buffer-concat.js @@ -0,0 +1,33 @@ +/*! + * depd + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module exports. + */ + +module.exports = bufferConcat + +/** + * Concatenate an array of Buffers. + */ + +function bufferConcat(bufs) { + var length = 0 + + for (var i = 0, len = bufs.length; i < len; i++) { + length += bufs[i].length + } + + var buf = new Buffer(length) + var pos = 0 + + for (var i = 0, len = bufs.length; i < len; i++) { + bufs[i].copy(buf, pos) + pos += bufs[i].length + } + + return buf +} diff --git a/node_modules/express/node_modules/depd/lib/compat/callsite-tostring.js b/node_modules/express/node_modules/depd/lib/compat/callsite-tostring.js new file mode 100644 index 0000000..17cf7ed --- /dev/null +++ b/node_modules/express/node_modules/depd/lib/compat/callsite-tostring.js @@ -0,0 +1,101 @@ +/*! + * depd + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module exports. + */ + +module.exports = callSiteToString + +/** + * Format a CallSite file location to a string. + */ + +function callSiteFileLocation(callSite) { + var fileName + var fileLocation = '' + + if (callSite.isNative()) { + fileLocation = 'native' + } else if (callSite.isEval()) { + fileName = callSite.getScriptNameOrSourceURL() + if (!fileName) { + fileLocation = callSite.getEvalOrigin() + } + } else { + fileName = callSite.getFileName() + } + + if (fileName) { + fileLocation += fileName + + var lineNumber = callSite.getLineNumber() + if (lineNumber != null) { + fileLocation += ':' + lineNumber + + var columnNumber = callSite.getColumnNumber() + if (columnNumber) { + fileLocation += ':' + columnNumber + } + } + } + + return fileLocation || 'unknown source' +} + +/** + * Format a CallSite to a string. + */ + +function callSiteToString(callSite) { + var addSuffix = true + var fileLocation = callSiteFileLocation(callSite) + var functionName = callSite.getFunctionName() + var isConstructor = callSite.isConstructor() + var isMethodCall = !(callSite.isToplevel() || isConstructor) + var line = '' + + if (isMethodCall) { + var methodName = callSite.getMethodName() + var typeName = getConstructorName(callSite) + + if (functionName) { + if (typeName && functionName.indexOf(typeName) !== 0) { + line += typeName + '.' + } + + line += functionName + + if (methodName && functionName.lastIndexOf('.' + methodName) !== functionName.length - methodName.length - 1) { + line += ' [as ' + methodName + ']' + } + } else { + line += typeName + '.' + (methodName || '') + } + } else if (isConstructor) { + line += 'new ' + (functionName || '') + } else if (functionName) { + line += functionName + } else { + addSuffix = false + line += fileLocation + } + + if (addSuffix) { + line += ' (' + fileLocation + ')' + } + + return line +} + +/** + * Get constructor name of reviver. + */ + +function getConstructorName(obj) { + var receiver = obj.receiver + return (receiver.constructor && receiver.constructor.name) || null +} diff --git a/node_modules/express/node_modules/depd/lib/compat/index.js b/node_modules/express/node_modules/depd/lib/compat/index.js new file mode 100644 index 0000000..7fee026 --- /dev/null +++ b/node_modules/express/node_modules/depd/lib/compat/index.js @@ -0,0 +1,69 @@ +/*! + * depd + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module exports. + */ + +lazyProperty(module.exports, 'bufferConcat', function bufferConcat() { + return Buffer.concat || require('./buffer-concat') +}) + +lazyProperty(module.exports, 'callSiteToString', function callSiteToString() { + var limit = Error.stackTraceLimit + var obj = {} + var prep = Error.prepareStackTrace + + function prepareObjectStackTrace(obj, stack) { + return stack + } + + Error.prepareStackTrace = prepareObjectStackTrace + Error.stackTraceLimit = 2 + + // capture the stack + Error.captureStackTrace(obj) + + // slice the stack + var stack = obj.stack.slice() + + Error.prepareStackTrace = prep + Error.stackTraceLimit = limit + + return stack[0].toString ? toString : require('./callsite-tostring') +}) + +/** + * Define a lazy property. + */ + +function lazyProperty(obj, prop, getter) { + function get() { + var val = getter() + + Object.defineProperty(obj, prop, { + configurable: true, + enumerable: true, + value: val + }) + + return val + } + + Object.defineProperty(obj, prop, { + configurable: true, + enumerable: true, + get: get + }) +} + +/** + * Call toString() on the obj + */ + +function toString(obj) { + return obj.toString() +} diff --git a/node_modules/express/node_modules/depd/package.json b/node_modules/express/node_modules/depd/package.json new file mode 100644 index 0000000..55a9db0 --- /dev/null +++ b/node_modules/express/node_modules/depd/package.json @@ -0,0 +1,67 @@ +{ + "name": "depd", + "description": "Deprecate all the things", + "version": "0.4.5", + "author": { + "name": "Douglas Christopher Wilson", + "email": "doug@somethingdoug.com" + }, + "license": "MIT", + "keywords": [ + "deprecate", + "deprecated" + ], + "repository": { + "type": "git", + "url": "https://github.com/dougwilson/nodejs-depd" + }, + "devDependencies": { + "benchmark": "1.0.0", + "beautify-benchmark": "0.2.4", + "istanbul": "0.3.2", + "mocha": "~1.21.4", + "should": "~4.0.4" + }, + "files": [ + "lib/", + "History.md", + "LICENSE", + "index.js", + "Readme.md" + ], + "engines": { + "node": ">= 0.6" + }, + "scripts": { + "bench": "node benchmark/index.js", + "test": "mocha --reporter spec --bail --require should test/", + "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --require should test/", + "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --require should test/" + }, + "gitHead": "e37a15044f7da76b94d8e0d46a6343feb168c82b", + "bugs": { + "url": "https://github.com/dougwilson/nodejs-depd/issues" + }, + "homepage": "https://github.com/dougwilson/nodejs-depd", + "_id": "depd@0.4.5", + "_shasum": "1a664b53388b4a6573e8ae67b5f767c693ca97f1", + "_from": "depd@0.4.5", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + "maintainers": [ + { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + } + ], + "dist": { + "shasum": "1a664b53388b4a6573e8ae67b5f767c693ca97f1", + "tarball": "http://registry.npmjs.org/depd/-/depd-0.4.5.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/depd/-/depd-0.4.5.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/express/node_modules/escape-html/.npmignore b/node_modules/express/node_modules/escape-html/.npmignore new file mode 100644 index 0000000..48a2e24 --- /dev/null +++ b/node_modules/express/node_modules/escape-html/.npmignore @@ -0,0 +1,2 @@ +components +build diff --git a/node_modules/express/node_modules/escape-html/Makefile b/node_modules/express/node_modules/escape-html/Makefile new file mode 100644 index 0000000..3f6119d --- /dev/null +++ b/node_modules/express/node_modules/escape-html/Makefile @@ -0,0 +1,11 @@ + +build: components index.js + @component build + +components: + @Component install + +clean: + rm -fr build components template.js + +.PHONY: clean diff --git a/node_modules/express/node_modules/escape-html/Readme.md b/node_modules/express/node_modules/escape-html/Readme.md new file mode 100644 index 0000000..2cfcc99 --- /dev/null +++ b/node_modules/express/node_modules/escape-html/Readme.md @@ -0,0 +1,15 @@ + +# escape-html + + Escape HTML entities + +## Example + +```js +var escape = require('escape-html'); +escape(str); +``` + +## License + + MIT \ No newline at end of file diff --git a/node_modules/express/node_modules/escape-html/component.json b/node_modules/express/node_modules/escape-html/component.json new file mode 100644 index 0000000..cb9740f --- /dev/null +++ b/node_modules/express/node_modules/escape-html/component.json @@ -0,0 +1,10 @@ +{ + "name": "escape-html", + "description": "Escape HTML entities", + "version": "1.0.1", + "keywords": ["escape", "html", "utility"], + "dependencies": {}, + "scripts": [ + "index.js" + ] +} diff --git a/node_modules/express/node_modules/escape-html/index.js b/node_modules/express/node_modules/escape-html/index.js new file mode 100644 index 0000000..2765211 --- /dev/null +++ b/node_modules/express/node_modules/escape-html/index.js @@ -0,0 +1,16 @@ +/** + * Escape special characters in the given string of html. + * + * @param {String} html + * @return {String} + * @api private + */ + +module.exports = function(html) { + return String(html) + .replace(/&/g, '&') + .replace(/"/g, '"') + .replace(/'/g, ''') + .replace(//g, '>'); +} diff --git a/node_modules/express/node_modules/escape-html/package.json b/node_modules/express/node_modules/escape-html/package.json new file mode 100644 index 0000000..ee240f0 --- /dev/null +++ b/node_modules/express/node_modules/escape-html/package.json @@ -0,0 +1,47 @@ +{ + "name": "escape-html", + "description": "Escape HTML entities", + "version": "1.0.1", + "keywords": [ + "escape", + "html", + "utility" + ], + "dependencies": {}, + "main": "index.js", + "component": { + "scripts": { + "escape-html/index.js": "index.js" + } + }, + "repository": { + "type": "git", + "url": "https://github.com/component/escape-html.git" + }, + "readme": "\n# escape-html\n\n Escape HTML entities\n\n## Example\n\n```js\nvar escape = require('escape-html');\nescape(str);\n```\n\n## License\n\n MIT", + "readmeFilename": "Readme.md", + "bugs": { + "url": "https://github.com/component/escape-html/issues" + }, + "homepage": "https://github.com/component/escape-html", + "_id": "escape-html@1.0.1", + "dist": { + "shasum": "181a286ead397a39a92857cfb1d43052e356bff0", + "tarball": "http://registry.npmjs.org/escape-html/-/escape-html-1.0.1.tgz" + }, + "_from": "escape-html@1.0.1", + "_npmVersion": "1.3.15", + "_npmUser": { + "name": "tjholowaychuk", + "email": "tj@vision-media.ca" + }, + "maintainers": [ + { + "name": "tjholowaychuk", + "email": "tj@vision-media.ca" + } + ], + "directories": {}, + "_shasum": "181a286ead397a39a92857cfb1d43052e356bff0", + "_resolved": "https://registry.npmjs.org/escape-html/-/escape-html-1.0.1.tgz" +} diff --git a/node_modules/express/node_modules/etag/HISTORY.md b/node_modules/express/node_modules/etag/HISTORY.md new file mode 100644 index 0000000..c13d034 --- /dev/null +++ b/node_modules/express/node_modules/etag/HISTORY.md @@ -0,0 +1,37 @@ +1.3.1 / 2014-09-14 +================== + + * Use the (new and improved) `crc` for crc32 + +1.3.0 / 2014-08-29 +================== + + * Default strings to strong ETags + * Improve speed for weak ETags over 1KB + +1.2.1 / 2014-08-29 +================== + + * Use the (much faster) `buffer-crc32` for crc32 + +1.2.0 / 2014-08-24 +================== + + * Add support for file stat objects + +1.1.0 / 2014-08-24 +================== + + * Add fast-path for empty entity + * Add weak ETag generation + * Shrink size of generated ETags + +1.0.1 / 2014-08-24 +================== + + * Fix behavior of string containing Unicode + +1.0.0 / 2014-05-18 +================== + + * Initial release diff --git a/node_modules/express/node_modules/etag/LICENSE b/node_modules/express/node_modules/etag/LICENSE new file mode 100644 index 0000000..b7dce6c --- /dev/null +++ b/node_modules/express/node_modules/etag/LICENSE @@ -0,0 +1,22 @@ +(The MIT License) + +Copyright (c) 2014 Douglas Christopher Wilson + +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/node_modules/express/node_modules/etag/README.md b/node_modules/express/node_modules/etag/README.md new file mode 100644 index 0000000..d770f49 --- /dev/null +++ b/node_modules/express/node_modules/etag/README.md @@ -0,0 +1,141 @@ +# etag + +[![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] + +Create simple ETags + +## Installation + +```sh +$ npm install etag +``` + +## API + +```js +var etag = require('etag') +``` + +### etag(entity, [options]) + +Generate a strong ETag for the given entity. This should be the complete +body of the entity. Strings, `Buffer`s, and `fs.Stats` are accepted. By +default, a strong ETag is generated except for `fs.Stats`, which will +generate a weak ETag (this can be overwritten by `options.weak`). + +```js +res.setHeader('ETag', etag(body)) +``` + +#### Options + +`etag` accepts these properties in the options object. + +##### weak + +Specifies if a "strong" or a "weak" ETag will be generated. The ETag can only +really be a strong as the given input. + +## Testing + +```sh +$ npm test +``` + +## Benchmark + +```bash +$ npm run-script bench + +> etag@1.2.0 bench nodejs-etag +> node benchmark/index.js + +> node benchmark/body0-100b.js + + 100B body + + 1 test completed. + 2 tests completed. + 3 tests completed. + 4 tests completed. + + buffer - strong x 518,895 ops/sec ±1.71% (185 runs sampled) +* buffer - weak x 1,917,975 ops/sec ±0.34% (195 runs sampled) + string - strong x 245,251 ops/sec ±0.90% (190 runs sampled) + string - weak x 442,232 ops/sec ±0.21% (196 runs sampled) + +> node benchmark/body1-1kb.js + + 1KB body + + 1 test completed. + 2 tests completed. + 3 tests completed. + 4 tests completed. + + buffer - strong x 309,748 ops/sec ±0.99% (191 runs sampled) +* buffer - weak x 352,402 ops/sec ±0.20% (198 runs sampled) + string - strong x 159,058 ops/sec ±1.83% (191 runs sampled) + string - weak x 184,052 ops/sec ±1.30% (189 runs sampled) + +> node benchmark/body2-5kb.js + + 5KB body + + 1 test completed. + 2 tests completed. + 3 tests completed. + 4 tests completed. + +* buffer - strong x 110,157 ops/sec ±0.60% (194 runs sampled) +* buffer - weak x 111,333 ops/sec ±0.67% (194 runs sampled) + string - strong x 62,091 ops/sec ±3.92% (186 runs sampled) + string - weak x 60,681 ops/sec ±3.98% (186 runs sampled) + +> node benchmark/body3-10kb.js + + 10KB body + + 1 test completed. + 2 tests completed. + 3 tests completed. + 4 tests completed. + +* buffer - strong x 61,843 ops/sec ±0.44% (197 runs sampled) +* buffer - weak x 61,687 ops/sec ±0.52% (197 runs sampled) + string - strong x 41,377 ops/sec ±3.33% (189 runs sampled) + string - weak x 41,368 ops/sec ±3.29% (190 runs sampled) + +> node benchmark/body4-100kb.js + + 100KB body + + 1 test completed. + 2 tests completed. + 3 tests completed. + 4 tests completed. + +* buffer - strong x 6,874 ops/sec ±0.17% (198 runs sampled) +* buffer - weak x 6,880 ops/sec ±0.15% (198 runs sampled) + string - strong x 5,382 ops/sec ±2.17% (192 runs sampled) + string - weak x 5,361 ops/sec ±2.23% (192 runs sampled) +``` + +## License + +[MIT](LICENSE) + +[npm-image]: https://img.shields.io/npm/v/etag.svg?style=flat +[npm-url]: https://npmjs.org/package/etag +[node-version-image]: https://img.shields.io/node/v/etag.svg?style=flat +[node-version-url]: http://nodejs.org/download/ +[travis-image]: https://img.shields.io/travis/jshttp/etag.svg?style=flat +[travis-url]: https://travis-ci.org/jshttp/etag +[coveralls-image]: https://img.shields.io/coveralls/jshttp/etag.svg?style=flat +[coveralls-url]: https://coveralls.io/r/jshttp/etag?branch=master +[downloads-image]: https://img.shields.io/npm/dm/etag.svg?style=flat +[downloads-url]: https://npmjs.org/package/etag diff --git a/node_modules/express/node_modules/etag/index.js b/node_modules/express/node_modules/etag/index.js new file mode 100644 index 0000000..3ddf18f --- /dev/null +++ b/node_modules/express/node_modules/etag/index.js @@ -0,0 +1,133 @@ +/*! + * etag + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module exports. + */ + +module.exports = etag + +/** + * Module dependencies. + */ + +var crc = require('crc').crc32 +var crypto = require('crypto') +var Stats = require('fs').Stats + +/** + * Module variables. + */ + +var crc32threshold = 1000 // 1KB +var NULL = new Buffer([0]) + +/** + * Create a simple ETag. + * + * @param {string|Buffer|Stats} entity + * @param {object} [options] + * @param {boolean} [options.weak] + * @return {String} + * @api public + */ + +function etag(entity, options) { + if (entity == null) { + throw new TypeError('argument entity is required') + } + + var isBuffer = Buffer.isBuffer(entity) + var isStats = entity instanceof Stats + var weak = options && typeof options.weak === 'boolean' + ? options.weak + : isStats + + // support fs.Stats object + if (isStats) { + return stattag(entity, weak) + } + + if (!isBuffer && typeof entity !== 'string') { + throw new TypeError('argument entity must be string, Buffer, or fs.Stats') + } + + var buf = !isBuffer + ? new Buffer(entity, 'utf8') + : entity + var hash = weak && buf.length <= crc32threshold + ? weakhash(buf) + : stronghash(buf) + + return weak + ? 'W/"' + hash + '"' + : '"' + hash + '"' +} + +/** + * Generate a tag for a stat. + * + * @param {Buffer} entity + * @return {String} + * @api private + */ + +function stattag(stat, weak) { + var mtime = stat.mtime.toISOString() + var size = stat.size.toString(16) + + if (weak) { + return 'W/"' + size + '-' + crc(mtime) + '"' + } + + var hash = crypto + .createHash('md5') + .update('file', 'utf8') + .update(NULL) + .update(size, 'utf8') + .update(NULL) + .update(mtime, 'utf8') + .digest('base64') + + return '"' + hash + '"' +} + +/** + * Generate a strong hash. + * + * @param {Buffer} entity + * @return {String} + * @api private + */ + +function stronghash(buf) { + if (buf.length === 0) { + // fast-path empty + return '1B2M2Y8AsgTpgAmY7PhCfg==' + } + + return crypto + .createHash('md5') + .update(buf) + .digest('base64') +} + +/** + * Generate a weak hash. + * + * @param {Buffer} entity + * @return {String} + * @api private + */ + +function weakhash(buf) { + if (buf.length === 0) { + // fast-path empty + return '0-0' + } + + return buf.length.toString(16) + '-' + crc(buf).toString(16) +} diff --git a/node_modules/express/node_modules/etag/node_modules/crc/.npmignore b/node_modules/express/node_modules/etag/node_modules/crc/.npmignore new file mode 100644 index 0000000..b84a005 --- /dev/null +++ b/node_modules/express/node_modules/etag/node_modules/crc/.npmignore @@ -0,0 +1,4 @@ +benchmark +src +test +.travis.yml diff --git a/node_modules/express/node_modules/etag/node_modules/crc/LICENSE b/node_modules/express/node_modules/etag/node_modules/crc/LICENSE new file mode 100644 index 0000000..c49097c --- /dev/null +++ b/node_modules/express/node_modules/etag/node_modules/crc/LICENSE @@ -0,0 +1,22 @@ +The MIT License (MIT) + +Copyright 2014 Alex Gorbatchev + +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/node_modules/express/node_modules/etag/node_modules/crc/README.md b/node_modules/express/node_modules/etag/node_modules/crc/README.md new file mode 100644 index 0000000..3fdef99 --- /dev/null +++ b/node_modules/express/node_modules/etag/node_modules/crc/README.md @@ -0,0 +1,89 @@ +# crc + +[![GitTip](http://img.shields.io/gittip/alexgorbatchev.svg?style=flat)](https://www.gittip.com/alexgorbatchev/) +[![Dependency status](http://img.shields.io/david/alexgorbatchev/node-crc.svg?style=flat)](https://david-dm.org/alexgorbatchev/node-crc) +[![devDependency Status](http://img.shields.io/david/dev/alexgorbatchev/node-crc.svg?style=flat)](https://david-dm.org/alexgorbatchev/node-crc#info=devDependencies) +[![Build Status](http://img.shields.io/travis/alexgorbatchev/node-crc.svg?style=flat&branch=master)](https://travis-ci.org/alexgorbatchev/node-crc) + +[![NPM](https://nodei.co/npm/node-crc.svg?style=flat)](https://npmjs.org/package/node-crc) + +Module for calculating Cyclic Redundancy Check (CRC). + +## Features + +* Version 3 is 3-4 times faster than version 2. +* Pure JavaScript implementation, no dependencies. +* Provides CRC Tables for optimized calculations. +* Provides support for the following CRC algorithms: + * CRC1 `crc.crc1(…)` + * CRC8 `crc.crc8(…)` + * CRC8 1-Wire `crc.crc81wire(…)` + * CRC16 `crc.crc16(…)` + * CRC16 CCITT `crc.crc16ccitt(…)` + * CRC16 Modbus `crc.crc16modbus(…)` + * CRC24 `crc.crc24(…)` + * CRC32 `crc.crc32(…)` + +## Installation + + npm install crc + +## Running tests + + $ npm install + $ npm test + +## Usage Example + +Calculate a CRC32: + + var crc = require('crc'); + + crc.crc32('hello').toString(16); + # => "3610a686" + +Calculate a CRC32 of a file: + + crc.crc32(fs.readFileSync('README.md', 'utf8')).toString(16); + # => "127ad531" + +Or using a `Buffer`: + + crc.crc32(fs.readFileSync('README.md')).toString(16); + # => "127ad531" + +Incrementally calculate a CRC32: + + value = crc32('one'); + value = crc32('two', value); + value = crc32('three', value); + value.toString(16); + # => "09e1c092" + +## Thanks! + +[pycrc](http://www.tty1.net/pycrc/) library is which the source of all of the CRC tables. + +# License + +The MIT License (MIT) + +Copyright (c) 2014 Alex Gorbatchev + +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/node_modules/express/node_modules/etag/node_modules/crc/lib/crc.js b/node_modules/express/node_modules/etag/node_modules/crc/lib/crc.js new file mode 100644 index 0000000..1c342b7 --- /dev/null +++ b/node_modules/express/node_modules/etag/node_modules/crc/lib/crc.js @@ -0,0 +1,71 @@ +// Generated by CoffeeScript 1.7.1 +var CRC, hex; + +hex = require('./hex'); + +module.exports = CRC = (function() { + CRC.prototype.INIT_CRC = 0x00; + + CRC.prototype.XOR_MASK = 0x00; + + CRC.prototype.WIDTH = 0; + + CRC.prototype.pack = function(crc) { + return ''; + }; + + CRC.prototype.each_byte = function(buf, cb) { + var i, _i, _ref, _results; + if (!Buffer.isBuffer(buf)) { + buf = Buffer(buf); + } + _results = []; + for (i = _i = 0, _ref = buf.length - 1; 0 <= _ref ? _i <= _ref : _i >= _ref; i = 0 <= _ref ? ++_i : --_i) { + _results.push(cb(buf[i])); + } + return _results; + }; + + function CRC() { + this.crc = this.INIT_CRC; + } + + CRC.prototype.digest_length = function() { + return Math.ceil(this.WIDTH / 8.0); + }; + + CRC.prototype.update = function(data) {}; + + CRC.prototype.reset = function() { + return this.crc = this.INIT_CRC; + }; + + CRC.prototype.checksum = function(signed) { + var sum; + if (signed == null) { + signed = true; + } + sum = this.crc ^ this.XOR_MASK; + if (signed) { + sum = sum >>> 0; + } + return sum; + }; + + CRC.prototype.finish = function() { + return this.pack(this.checksum()); + }; + + CRC.prototype.hexdigest = function(value) { + var result; + if (value != null) { + this.update(value); + } + result = this.finish(); + this.reset(); + return result; + }; + + return CRC; + +})(); diff --git a/node_modules/express/node_modules/etag/node_modules/crc/lib/crc1.js b/node_modules/express/node_modules/etag/node_modules/crc/lib/crc1.js new file mode 100644 index 0000000..3cb4fa9 --- /dev/null +++ b/node_modules/express/node_modules/etag/node_modules/crc/lib/crc1.js @@ -0,0 +1,21 @@ +// Generated by CoffeeScript 1.7.1 +var Buffer, create; + +Buffer = require('buffer').Buffer; + +create = require('./create'); + +module.exports = create(function(buf, previous) { + var accum, byte, crc, _i, _len; + if (!Buffer.isBuffer(buf)) { + buf = Buffer(buf); + } + crc = ~~previous; + accum = 0; + for (_i = 0, _len = buf.length; _i < _len; _i++) { + byte = buf[_i]; + accum += byte; + } + crc += accum % 256; + return crc % 256; +}); diff --git a/node_modules/express/node_modules/etag/node_modules/crc/lib/crc16.js b/node_modules/express/node_modules/etag/node_modules/crc/lib/crc16.js new file mode 100644 index 0000000..f19faa8 --- /dev/null +++ b/node_modules/express/node_modules/etag/node_modules/crc/lib/crc16.js @@ -0,0 +1,25 @@ +// Generated by CoffeeScript 1.7.1 +var Buffer, TABLE, create; + +Buffer = require('buffer').Buffer; + +create = require('./create'); + +TABLE = [0x0000, 0xc0c1, 0xc181, 0x0140, 0xc301, 0x03c0, 0x0280, 0xc241, 0xc601, 0x06c0, 0x0780, 0xc741, 0x0500, 0xc5c1, 0xc481, 0x0440, 0xcc01, 0x0cc0, 0x0d80, 0xcd41, 0x0f00, 0xcfc1, 0xce81, 0x0e40, 0x0a00, 0xcac1, 0xcb81, 0x0b40, 0xc901, 0x09c0, 0x0880, 0xc841, 0xd801, 0x18c0, 0x1980, 0xd941, 0x1b00, 0xdbc1, 0xda81, 0x1a40, 0x1e00, 0xdec1, 0xdf81, 0x1f40, 0xdd01, 0x1dc0, 0x1c80, 0xdc41, 0x1400, 0xd4c1, 0xd581, 0x1540, 0xd701, 0x17c0, 0x1680, 0xd641, 0xd201, 0x12c0, 0x1380, 0xd341, 0x1100, 0xd1c1, 0xd081, 0x1040, 0xf001, 0x30c0, 0x3180, 0xf141, 0x3300, 0xf3c1, 0xf281, 0x3240, 0x3600, 0xf6c1, 0xf781, 0x3740, 0xf501, 0x35c0, 0x3480, 0xf441, 0x3c00, 0xfcc1, 0xfd81, 0x3d40, 0xff01, 0x3fc0, 0x3e80, 0xfe41, 0xfa01, 0x3ac0, 0x3b80, 0xfb41, 0x3900, 0xf9c1, 0xf881, 0x3840, 0x2800, 0xe8c1, 0xe981, 0x2940, 0xeb01, 0x2bc0, 0x2a80, 0xea41, 0xee01, 0x2ec0, 0x2f80, 0xef41, 0x2d00, 0xedc1, 0xec81, 0x2c40, 0xe401, 0x24c0, 0x2580, 0xe541, 0x2700, 0xe7c1, 0xe681, 0x2640, 0x2200, 0xe2c1, 0xe381, 0x2340, 0xe101, 0x21c0, 0x2080, 0xe041, 0xa001, 0x60c0, 0x6180, 0xa141, 0x6300, 0xa3c1, 0xa281, 0x6240, 0x6600, 0xa6c1, 0xa781, 0x6740, 0xa501, 0x65c0, 0x6480, 0xa441, 0x6c00, 0xacc1, 0xad81, 0x6d40, 0xaf01, 0x6fc0, 0x6e80, 0xae41, 0xaa01, 0x6ac0, 0x6b80, 0xab41, 0x6900, 0xa9c1, 0xa881, 0x6840, 0x7800, 0xb8c1, 0xb981, 0x7940, 0xbb01, 0x7bc0, 0x7a80, 0xba41, 0xbe01, 0x7ec0, 0x7f80, 0xbf41, 0x7d00, 0xbdc1, 0xbc81, 0x7c40, 0xb401, 0x74c0, 0x7580, 0xb541, 0x7700, 0xb7c1, 0xb681, 0x7640, 0x7200, 0xb2c1, 0xb381, 0x7340, 0xb101, 0x71c0, 0x7080, 0xb041, 0x5000, 0x90c1, 0x9181, 0x5140, 0x9301, 0x53c0, 0x5280, 0x9241, 0x9601, 0x56c0, 0x5780, 0x9741, 0x5500, 0x95c1, 0x9481, 0x5440, 0x9c01, 0x5cc0, 0x5d80, 0x9d41, 0x5f00, 0x9fc1, 0x9e81, 0x5e40, 0x5a00, 0x9ac1, 0x9b81, 0x5b40, 0x9901, 0x59c0, 0x5880, 0x9841, 0x8801, 0x48c0, 0x4980, 0x8941, 0x4b00, 0x8bc1, 0x8a81, 0x4a40, 0x4e00, 0x8ec1, 0x8f81, 0x4f40, 0x8d01, 0x4dc0, 0x4c80, 0x8c41, 0x4400, 0x84c1, 0x8581, 0x4540, 0x8701, 0x47c0, 0x4680, 0x8641, 0x8201, 0x42c0, 0x4380, 0x8341, 0x4100, 0x81c1, 0x8081, 0x4040]; + +if (typeof Int32Array !== 'undefined') { + TABLE = new Int32Array(TABLE); +} + +module.exports = create(function(buf, previous) { + var byte, crc, _i, _len; + if (!Buffer.isBuffer(buf)) { + buf = Buffer(buf); + } + crc = ~~previous; + for (_i = 0, _len = buf.length; _i < _len; _i++) { + byte = buf[_i]; + crc = (TABLE[(crc ^ byte) & 0xff] ^ (crc >> 8)) & 0xffff; + } + return crc; +}); diff --git a/node_modules/express/node_modules/etag/node_modules/crc/lib/crc16_ccitt.js b/node_modules/express/node_modules/etag/node_modules/crc/lib/crc16_ccitt.js new file mode 100644 index 0000000..5331638 --- /dev/null +++ b/node_modules/express/node_modules/etag/node_modules/crc/lib/crc16_ccitt.js @@ -0,0 +1,25 @@ +// Generated by CoffeeScript 1.7.1 +var Buffer, TABLE, create; + +Buffer = require('buffer').Buffer; + +create = require('./create'); + +TABLE = [0x0000, 0x1021, 0x2042, 0x3063, 0x4084, 0x50a5, 0x60c6, 0x70e7, 0x8108, 0x9129, 0xa14a, 0xb16b, 0xc18c, 0xd1ad, 0xe1ce, 0xf1ef, 0x1231, 0x0210, 0x3273, 0x2252, 0x52b5, 0x4294, 0x72f7, 0x62d6, 0x9339, 0x8318, 0xb37b, 0xa35a, 0xd3bd, 0xc39c, 0xf3ff, 0xe3de, 0x2462, 0x3443, 0x0420, 0x1401, 0x64e6, 0x74c7, 0x44a4, 0x5485, 0xa56a, 0xb54b, 0x8528, 0x9509, 0xe5ee, 0xf5cf, 0xc5ac, 0xd58d, 0x3653, 0x2672, 0x1611, 0x0630, 0x76d7, 0x66f6, 0x5695, 0x46b4, 0xb75b, 0xa77a, 0x9719, 0x8738, 0xf7df, 0xe7fe, 0xd79d, 0xc7bc, 0x48c4, 0x58e5, 0x6886, 0x78a7, 0x0840, 0x1861, 0x2802, 0x3823, 0xc9cc, 0xd9ed, 0xe98e, 0xf9af, 0x8948, 0x9969, 0xa90a, 0xb92b, 0x5af5, 0x4ad4, 0x7ab7, 0x6a96, 0x1a71, 0x0a50, 0x3a33, 0x2a12, 0xdbfd, 0xcbdc, 0xfbbf, 0xeb9e, 0x9b79, 0x8b58, 0xbb3b, 0xab1a, 0x6ca6, 0x7c87, 0x4ce4, 0x5cc5, 0x2c22, 0x3c03, 0x0c60, 0x1c41, 0xedae, 0xfd8f, 0xcdec, 0xddcd, 0xad2a, 0xbd0b, 0x8d68, 0x9d49, 0x7e97, 0x6eb6, 0x5ed5, 0x4ef4, 0x3e13, 0x2e32, 0x1e51, 0x0e70, 0xff9f, 0xefbe, 0xdfdd, 0xcffc, 0xbf1b, 0xaf3a, 0x9f59, 0x8f78, 0x9188, 0x81a9, 0xb1ca, 0xa1eb, 0xd10c, 0xc12d, 0xf14e, 0xe16f, 0x1080, 0x00a1, 0x30c2, 0x20e3, 0x5004, 0x4025, 0x7046, 0x6067, 0x83b9, 0x9398, 0xa3fb, 0xb3da, 0xc33d, 0xd31c, 0xe37f, 0xf35e, 0x02b1, 0x1290, 0x22f3, 0x32d2, 0x4235, 0x5214, 0x6277, 0x7256, 0xb5ea, 0xa5cb, 0x95a8, 0x8589, 0xf56e, 0xe54f, 0xd52c, 0xc50d, 0x34e2, 0x24c3, 0x14a0, 0x0481, 0x7466, 0x6447, 0x5424, 0x4405, 0xa7db, 0xb7fa, 0x8799, 0x97b8, 0xe75f, 0xf77e, 0xc71d, 0xd73c, 0x26d3, 0x36f2, 0x0691, 0x16b0, 0x6657, 0x7676, 0x4615, 0x5634, 0xd94c, 0xc96d, 0xf90e, 0xe92f, 0x99c8, 0x89e9, 0xb98a, 0xa9ab, 0x5844, 0x4865, 0x7806, 0x6827, 0x18c0, 0x08e1, 0x3882, 0x28a3, 0xcb7d, 0xdb5c, 0xeb3f, 0xfb1e, 0x8bf9, 0x9bd8, 0xabbb, 0xbb9a, 0x4a75, 0x5a54, 0x6a37, 0x7a16, 0x0af1, 0x1ad0, 0x2ab3, 0x3a92, 0xfd2e, 0xed0f, 0xdd6c, 0xcd4d, 0xbdaa, 0xad8b, 0x9de8, 0x8dc9, 0x7c26, 0x6c07, 0x5c64, 0x4c45, 0x3ca2, 0x2c83, 0x1ce0, 0x0cc1, 0xef1f, 0xff3e, 0xcf5d, 0xdf7c, 0xaf9b, 0xbfba, 0x8fd9, 0x9ff8, 0x6e17, 0x7e36, 0x4e55, 0x5e74, 0x2e93, 0x3eb2, 0x0ed1, 0x1ef0]; + +if (typeof Int32Array !== 'undefined') { + TABLE = new Int32Array(TABLE); +} + +module.exports = create(function(buf, previous) { + var byte, crc, _i, _len; + if (!Buffer.isBuffer(buf)) { + buf = Buffer(buf); + } + crc = ~~previous || 0xffff; + for (_i = 0, _len = buf.length; _i < _len; _i++) { + byte = buf[_i]; + crc = (TABLE[((crc >> 8) ^ byte) & 0xff] ^ (crc << 8)) & 0xffff; + } + return crc; +}); diff --git a/node_modules/express/node_modules/etag/node_modules/crc/lib/crc16_modbus.js b/node_modules/express/node_modules/etag/node_modules/crc/lib/crc16_modbus.js new file mode 100644 index 0000000..dcbd41b --- /dev/null +++ b/node_modules/express/node_modules/etag/node_modules/crc/lib/crc16_modbus.js @@ -0,0 +1,25 @@ +// Generated by CoffeeScript 1.7.1 +var Buffer, TABLE, create; + +Buffer = require('buffer').Buffer; + +create = require('./create'); + +TABLE = [0x0000, 0xc0c1, 0xc181, 0x0140, 0xc301, 0x03c0, 0x0280, 0xc241, 0xc601, 0x06c0, 0x0780, 0xc741, 0x0500, 0xc5c1, 0xc481, 0x0440, 0xcc01, 0x0cc0, 0x0d80, 0xcd41, 0x0f00, 0xcfc1, 0xce81, 0x0e40, 0x0a00, 0xcac1, 0xcb81, 0x0b40, 0xc901, 0x09c0, 0x0880, 0xc841, 0xd801, 0x18c0, 0x1980, 0xd941, 0x1b00, 0xdbc1, 0xda81, 0x1a40, 0x1e00, 0xdec1, 0xdf81, 0x1f40, 0xdd01, 0x1dc0, 0x1c80, 0xdc41, 0x1400, 0xd4c1, 0xd581, 0x1540, 0xd701, 0x17c0, 0x1680, 0xd641, 0xd201, 0x12c0, 0x1380, 0xd341, 0x1100, 0xd1c1, 0xd081, 0x1040, 0xf001, 0x30c0, 0x3180, 0xf141, 0x3300, 0xf3c1, 0xf281, 0x3240, 0x3600, 0xf6c1, 0xf781, 0x3740, 0xf501, 0x35c0, 0x3480, 0xf441, 0x3c00, 0xfcc1, 0xfd81, 0x3d40, 0xff01, 0x3fc0, 0x3e80, 0xfe41, 0xfa01, 0x3ac0, 0x3b80, 0xfb41, 0x3900, 0xf9c1, 0xf881, 0x3840, 0x2800, 0xe8c1, 0xe981, 0x2940, 0xeb01, 0x2bc0, 0x2a80, 0xea41, 0xee01, 0x2ec0, 0x2f80, 0xef41, 0x2d00, 0xedc1, 0xec81, 0x2c40, 0xe401, 0x24c0, 0x2580, 0xe541, 0x2700, 0xe7c1, 0xe681, 0x2640, 0x2200, 0xe2c1, 0xe381, 0x2340, 0xe101, 0x21c0, 0x2080, 0xe041, 0xa001, 0x60c0, 0x6180, 0xa141, 0x6300, 0xa3c1, 0xa281, 0x6240, 0x6600, 0xa6c1, 0xa781, 0x6740, 0xa501, 0x65c0, 0x6480, 0xa441, 0x6c00, 0xacc1, 0xad81, 0x6d40, 0xaf01, 0x6fc0, 0x6e80, 0xae41, 0xaa01, 0x6ac0, 0x6b80, 0xab41, 0x6900, 0xa9c1, 0xa881, 0x6840, 0x7800, 0xb8c1, 0xb981, 0x7940, 0xbb01, 0x7bc0, 0x7a80, 0xba41, 0xbe01, 0x7ec0, 0x7f80, 0xbf41, 0x7d00, 0xbdc1, 0xbc81, 0x7c40, 0xb401, 0x74c0, 0x7580, 0xb541, 0x7700, 0xb7c1, 0xb681, 0x7640, 0x7200, 0xb2c1, 0xb381, 0x7340, 0xb101, 0x71c0, 0x7080, 0xb041, 0x5000, 0x90c1, 0x9181, 0x5140, 0x9301, 0x53c0, 0x5280, 0x9241, 0x9601, 0x56c0, 0x5780, 0x9741, 0x5500, 0x95c1, 0x9481, 0x5440, 0x9c01, 0x5cc0, 0x5d80, 0x9d41, 0x5f00, 0x9fc1, 0x9e81, 0x5e40, 0x5a00, 0x9ac1, 0x9b81, 0x5b40, 0x9901, 0x59c0, 0x5880, 0x9841, 0x8801, 0x48c0, 0x4980, 0x8941, 0x4b00, 0x8bc1, 0x8a81, 0x4a40, 0x4e00, 0x8ec1, 0x8f81, 0x4f40, 0x8d01, 0x4dc0, 0x4c80, 0x8c41, 0x4400, 0x84c1, 0x8581, 0x4540, 0x8701, 0x47c0, 0x4680, 0x8641, 0x8201, 0x42c0, 0x4380, 0x8341, 0x4100, 0x81c1, 0x8081, 0x4040]; + +if (typeof Int32Array !== 'undefined') { + TABLE = new Int32Array(TABLE); +} + +module.exports = create(function(buf, previous) { + var byte, crc, _i, _len; + if (!Buffer.isBuffer(buf)) { + buf = Buffer(buf); + } + crc = ~~previous || 0xffff; + for (_i = 0, _len = buf.length; _i < _len; _i++) { + byte = buf[_i]; + crc = (TABLE[(crc ^ byte) & 0xff] ^ (crc >> 8)) & 0xffff; + } + return crc; +}); diff --git a/node_modules/express/node_modules/etag/node_modules/crc/lib/crc24.js b/node_modules/express/node_modules/etag/node_modules/crc/lib/crc24.js new file mode 100644 index 0000000..413d159 --- /dev/null +++ b/node_modules/express/node_modules/etag/node_modules/crc/lib/crc24.js @@ -0,0 +1,25 @@ +// Generated by CoffeeScript 1.7.1 +var Buffer, TABLE, create; + +Buffer = require('buffer').Buffer; + +create = require('./create'); + +TABLE = [0x000000, 0x864cfb, 0x8ad50d, 0x0c99f6, 0x93e6e1, 0x15aa1a, 0x1933ec, 0x9f7f17, 0xa18139, 0x27cdc2, 0x2b5434, 0xad18cf, 0x3267d8, 0xb42b23, 0xb8b2d5, 0x3efe2e, 0xc54e89, 0x430272, 0x4f9b84, 0xc9d77f, 0x56a868, 0xd0e493, 0xdc7d65, 0x5a319e, 0x64cfb0, 0xe2834b, 0xee1abd, 0x685646, 0xf72951, 0x7165aa, 0x7dfc5c, 0xfbb0a7, 0x0cd1e9, 0x8a9d12, 0x8604e4, 0x00481f, 0x9f3708, 0x197bf3, 0x15e205, 0x93aefe, 0xad50d0, 0x2b1c2b, 0x2785dd, 0xa1c926, 0x3eb631, 0xb8faca, 0xb4633c, 0x322fc7, 0xc99f60, 0x4fd39b, 0x434a6d, 0xc50696, 0x5a7981, 0xdc357a, 0xd0ac8c, 0x56e077, 0x681e59, 0xee52a2, 0xe2cb54, 0x6487af, 0xfbf8b8, 0x7db443, 0x712db5, 0xf7614e, 0x19a3d2, 0x9fef29, 0x9376df, 0x153a24, 0x8a4533, 0x0c09c8, 0x00903e, 0x86dcc5, 0xb822eb, 0x3e6e10, 0x32f7e6, 0xb4bb1d, 0x2bc40a, 0xad88f1, 0xa11107, 0x275dfc, 0xdced5b, 0x5aa1a0, 0x563856, 0xd074ad, 0x4f0bba, 0xc94741, 0xc5deb7, 0x43924c, 0x7d6c62, 0xfb2099, 0xf7b96f, 0x71f594, 0xee8a83, 0x68c678, 0x645f8e, 0xe21375, 0x15723b, 0x933ec0, 0x9fa736, 0x19ebcd, 0x8694da, 0x00d821, 0x0c41d7, 0x8a0d2c, 0xb4f302, 0x32bff9, 0x3e260f, 0xb86af4, 0x2715e3, 0xa15918, 0xadc0ee, 0x2b8c15, 0xd03cb2, 0x567049, 0x5ae9bf, 0xdca544, 0x43da53, 0xc596a8, 0xc90f5e, 0x4f43a5, 0x71bd8b, 0xf7f170, 0xfb6886, 0x7d247d, 0xe25b6a, 0x641791, 0x688e67, 0xeec29c, 0x3347a4, 0xb50b5f, 0xb992a9, 0x3fde52, 0xa0a145, 0x26edbe, 0x2a7448, 0xac38b3, 0x92c69d, 0x148a66, 0x181390, 0x9e5f6b, 0x01207c, 0x876c87, 0x8bf571, 0x0db98a, 0xf6092d, 0x7045d6, 0x7cdc20, 0xfa90db, 0x65efcc, 0xe3a337, 0xef3ac1, 0x69763a, 0x578814, 0xd1c4ef, 0xdd5d19, 0x5b11e2, 0xc46ef5, 0x42220e, 0x4ebbf8, 0xc8f703, 0x3f964d, 0xb9dab6, 0xb54340, 0x330fbb, 0xac70ac, 0x2a3c57, 0x26a5a1, 0xa0e95a, 0x9e1774, 0x185b8f, 0x14c279, 0x928e82, 0x0df195, 0x8bbd6e, 0x872498, 0x016863, 0xfad8c4, 0x7c943f, 0x700dc9, 0xf64132, 0x693e25, 0xef72de, 0xe3eb28, 0x65a7d3, 0x5b59fd, 0xdd1506, 0xd18cf0, 0x57c00b, 0xc8bf1c, 0x4ef3e7, 0x426a11, 0xc426ea, 0x2ae476, 0xaca88d, 0xa0317b, 0x267d80, 0xb90297, 0x3f4e6c, 0x33d79a, 0xb59b61, 0x8b654f, 0x0d29b4, 0x01b042, 0x87fcb9, 0x1883ae, 0x9ecf55, 0x9256a3, 0x141a58, 0xefaaff, 0x69e604, 0x657ff2, 0xe33309, 0x7c4c1e, 0xfa00e5, 0xf69913, 0x70d5e8, 0x4e2bc6, 0xc8673d, 0xc4fecb, 0x42b230, 0xddcd27, 0x5b81dc, 0x57182a, 0xd154d1, 0x26359f, 0xa07964, 0xace092, 0x2aac69, 0xb5d37e, 0x339f85, 0x3f0673, 0xb94a88, 0x87b4a6, 0x01f85d, 0x0d61ab, 0x8b2d50, 0x145247, 0x921ebc, 0x9e874a, 0x18cbb1, 0xe37b16, 0x6537ed, 0x69ae1b, 0xefe2e0, 0x709df7, 0xf6d10c, 0xfa48fa, 0x7c0401, 0x42fa2f, 0xc4b6d4, 0xc82f22, 0x4e63d9, 0xd11cce, 0x575035, 0x5bc9c3, 0xdd8538]; + +if (typeof Int32Array !== 'undefined') { + TABLE = new Int32Array(TABLE); +} + +module.exports = create(function(buf, previous) { + var byte, crc, _i, _len; + if (!Buffer.isBuffer(buf)) { + buf = Buffer(buf); + } + crc = ~~previous || 0xb704ce; + for (_i = 0, _len = buf.length; _i < _len; _i++) { + byte = buf[_i]; + crc = (TABLE[((crc >> 16) ^ byte) & 0xff] ^ (crc << 8)) & 0xffffff; + } + return crc; +}); diff --git a/node_modules/express/node_modules/etag/node_modules/crc/lib/crc32.js b/node_modules/express/node_modules/etag/node_modules/crc/lib/crc32.js new file mode 100644 index 0000000..eb2c85e --- /dev/null +++ b/node_modules/express/node_modules/etag/node_modules/crc/lib/crc32.js @@ -0,0 +1,25 @@ +// Generated by CoffeeScript 1.7.1 +var Buffer, TABLE, create; + +Buffer = require('buffer').Buffer; + +create = require('./create'); + +TABLE = [0x00000000, 0x77073096, 0xee0e612c, 0x990951ba, 0x076dc419, 0x706af48f, 0xe963a535, 0x9e6495a3, 0x0edb8832, 0x79dcb8a4, 0xe0d5e91e, 0x97d2d988, 0x09b64c2b, 0x7eb17cbd, 0xe7b82d07, 0x90bf1d91, 0x1db71064, 0x6ab020f2, 0xf3b97148, 0x84be41de, 0x1adad47d, 0x6ddde4eb, 0xf4d4b551, 0x83d385c7, 0x136c9856, 0x646ba8c0, 0xfd62f97a, 0x8a65c9ec, 0x14015c4f, 0x63066cd9, 0xfa0f3d63, 0x8d080df5, 0x3b6e20c8, 0x4c69105e, 0xd56041e4, 0xa2677172, 0x3c03e4d1, 0x4b04d447, 0xd20d85fd, 0xa50ab56b, 0x35b5a8fa, 0x42b2986c, 0xdbbbc9d6, 0xacbcf940, 0x32d86ce3, 0x45df5c75, 0xdcd60dcf, 0xabd13d59, 0x26d930ac, 0x51de003a, 0xc8d75180, 0xbfd06116, 0x21b4f4b5, 0x56b3c423, 0xcfba9599, 0xb8bda50f, 0x2802b89e, 0x5f058808, 0xc60cd9b2, 0xb10be924, 0x2f6f7c87, 0x58684c11, 0xc1611dab, 0xb6662d3d, 0x76dc4190, 0x01db7106, 0x98d220bc, 0xefd5102a, 0x71b18589, 0x06b6b51f, 0x9fbfe4a5, 0xe8b8d433, 0x7807c9a2, 0x0f00f934, 0x9609a88e, 0xe10e9818, 0x7f6a0dbb, 0x086d3d2d, 0x91646c97, 0xe6635c01, 0x6b6b51f4, 0x1c6c6162, 0x856530d8, 0xf262004e, 0x6c0695ed, 0x1b01a57b, 0x8208f4c1, 0xf50fc457, 0x65b0d9c6, 0x12b7e950, 0x8bbeb8ea, 0xfcb9887c, 0x62dd1ddf, 0x15da2d49, 0x8cd37cf3, 0xfbd44c65, 0x4db26158, 0x3ab551ce, 0xa3bc0074, 0xd4bb30e2, 0x4adfa541, 0x3dd895d7, 0xa4d1c46d, 0xd3d6f4fb, 0x4369e96a, 0x346ed9fc, 0xad678846, 0xda60b8d0, 0x44042d73, 0x33031de5, 0xaa0a4c5f, 0xdd0d7cc9, 0x5005713c, 0x270241aa, 0xbe0b1010, 0xc90c2086, 0x5768b525, 0x206f85b3, 0xb966d409, 0xce61e49f, 0x5edef90e, 0x29d9c998, 0xb0d09822, 0xc7d7a8b4, 0x59b33d17, 0x2eb40d81, 0xb7bd5c3b, 0xc0ba6cad, 0xedb88320, 0x9abfb3b6, 0x03b6e20c, 0x74b1d29a, 0xead54739, 0x9dd277af, 0x04db2615, 0x73dc1683, 0xe3630b12, 0x94643b84, 0x0d6d6a3e, 0x7a6a5aa8, 0xe40ecf0b, 0x9309ff9d, 0x0a00ae27, 0x7d079eb1, 0xf00f9344, 0x8708a3d2, 0x1e01f268, 0x6906c2fe, 0xf762575d, 0x806567cb, 0x196c3671, 0x6e6b06e7, 0xfed41b76, 0x89d32be0, 0x10da7a5a, 0x67dd4acc, 0xf9b9df6f, 0x8ebeeff9, 0x17b7be43, 0x60b08ed5, 0xd6d6a3e8, 0xa1d1937e, 0x38d8c2c4, 0x4fdff252, 0xd1bb67f1, 0xa6bc5767, 0x3fb506dd, 0x48b2364b, 0xd80d2bda, 0xaf0a1b4c, 0x36034af6, 0x41047a60, 0xdf60efc3, 0xa867df55, 0x316e8eef, 0x4669be79, 0xcb61b38c, 0xbc66831a, 0x256fd2a0, 0x5268e236, 0xcc0c7795, 0xbb0b4703, 0x220216b9, 0x5505262f, 0xc5ba3bbe, 0xb2bd0b28, 0x2bb45a92, 0x5cb36a04, 0xc2d7ffa7, 0xb5d0cf31, 0x2cd99e8b, 0x5bdeae1d, 0x9b64c2b0, 0xec63f226, 0x756aa39c, 0x026d930a, 0x9c0906a9, 0xeb0e363f, 0x72076785, 0x05005713, 0x95bf4a82, 0xe2b87a14, 0x7bb12bae, 0x0cb61b38, 0x92d28e9b, 0xe5d5be0d, 0x7cdcefb7, 0x0bdbdf21, 0x86d3d2d4, 0xf1d4e242, 0x68ddb3f8, 0x1fda836e, 0x81be16cd, 0xf6b9265b, 0x6fb077e1, 0x18b74777, 0x88085ae6, 0xff0f6a70, 0x66063bca, 0x11010b5c, 0x8f659eff, 0xf862ae69, 0x616bffd3, 0x166ccf45, 0xa00ae278, 0xd70dd2ee, 0x4e048354, 0x3903b3c2, 0xa7672661, 0xd06016f7, 0x4969474d, 0x3e6e77db, 0xaed16a4a, 0xd9d65adc, 0x40df0b66, 0x37d83bf0, 0xa9bcae53, 0xdebb9ec5, 0x47b2cf7f, 0x30b5ffe9, 0xbdbdf21c, 0xcabac28a, 0x53b39330, 0x24b4a3a6, 0xbad03605, 0xcdd70693, 0x54de5729, 0x23d967bf, 0xb3667a2e, 0xc4614ab8, 0x5d681b02, 0x2a6f2b94, 0xb40bbe37, 0xc30c8ea1, 0x5a05df1b, 0x2d02ef8d]; + +if (typeof Int32Array !== 'undefined') { + TABLE = new Int32Array(TABLE); +} + +module.exports = create(function(buf, previous) { + var byte, crc, _i, _len; + if (!Buffer.isBuffer(buf)) { + buf = Buffer(buf); + } + crc = ~~previous ^ -1; + for (_i = 0, _len = buf.length; _i < _len; _i++) { + byte = buf[_i]; + crc = TABLE[(crc ^ byte) & 0xff] ^ (crc >>> 8); + } + return crc ^ -1; +}); diff --git a/node_modules/express/node_modules/etag/node_modules/crc/lib/crc8.js b/node_modules/express/node_modules/etag/node_modules/crc/lib/crc8.js new file mode 100644 index 0000000..d6518c1 --- /dev/null +++ b/node_modules/express/node_modules/etag/node_modules/crc/lib/crc8.js @@ -0,0 +1,25 @@ +// Generated by CoffeeScript 1.7.1 +var Buffer, TABLE, create; + +Buffer = require('buffer').Buffer; + +create = require('./create'); + +TABLE = [0x00, 0x07, 0x0e, 0x09, 0x1c, 0x1b, 0x12, 0x15, 0x38, 0x3f, 0x36, 0x31, 0x24, 0x23, 0x2a, 0x2d, 0x70, 0x77, 0x7e, 0x79, 0x6c, 0x6b, 0x62, 0x65, 0x48, 0x4f, 0x46, 0x41, 0x54, 0x53, 0x5a, 0x5d, 0xe0, 0xe7, 0xee, 0xe9, 0xfc, 0xfb, 0xf2, 0xf5, 0xd8, 0xdf, 0xd6, 0xd1, 0xc4, 0xc3, 0xca, 0xcd, 0x90, 0x97, 0x9e, 0x99, 0x8c, 0x8b, 0x82, 0x85, 0xa8, 0xaf, 0xa6, 0xa1, 0xb4, 0xb3, 0xba, 0xbd, 0xc7, 0xc0, 0xc9, 0xce, 0xdb, 0xdc, 0xd5, 0xd2, 0xff, 0xf8, 0xf1, 0xf6, 0xe3, 0xe4, 0xed, 0xea, 0xb7, 0xb0, 0xb9, 0xbe, 0xab, 0xac, 0xa5, 0xa2, 0x8f, 0x88, 0x81, 0x86, 0x93, 0x94, 0x9d, 0x9a, 0x27, 0x20, 0x29, 0x2e, 0x3b, 0x3c, 0x35, 0x32, 0x1f, 0x18, 0x11, 0x16, 0x03, 0x04, 0x0d, 0x0a, 0x57, 0x50, 0x59, 0x5e, 0x4b, 0x4c, 0x45, 0x42, 0x6f, 0x68, 0x61, 0x66, 0x73, 0x74, 0x7d, 0x7a, 0x89, 0x8e, 0x87, 0x80, 0x95, 0x92, 0x9b, 0x9c, 0xb1, 0xb6, 0xbf, 0xb8, 0xad, 0xaa, 0xa3, 0xa4, 0xf9, 0xfe, 0xf7, 0xf0, 0xe5, 0xe2, 0xeb, 0xec, 0xc1, 0xc6, 0xcf, 0xc8, 0xdd, 0xda, 0xd3, 0xd4, 0x69, 0x6e, 0x67, 0x60, 0x75, 0x72, 0x7b, 0x7c, 0x51, 0x56, 0x5f, 0x58, 0x4d, 0x4a, 0x43, 0x44, 0x19, 0x1e, 0x17, 0x10, 0x05, 0x02, 0x0b, 0x0c, 0x21, 0x26, 0x2f, 0x28, 0x3d, 0x3a, 0x33, 0x34, 0x4e, 0x49, 0x40, 0x47, 0x52, 0x55, 0x5c, 0x5b, 0x76, 0x71, 0x78, 0x7f, 0x6a, 0x6d, 0x64, 0x63, 0x3e, 0x39, 0x30, 0x37, 0x22, 0x25, 0x2c, 0x2b, 0x06, 0x01, 0x08, 0x0f, 0x1a, 0x1d, 0x14, 0x13, 0xae, 0xa9, 0xa0, 0xa7, 0xb2, 0xb5, 0xbc, 0xbb, 0x96, 0x91, 0x98, 0x9f, 0x8a, 0x8d, 0x84, 0x83, 0xde, 0xd9, 0xd0, 0xd7, 0xc2, 0xc5, 0xcc, 0xcb, 0xe6, 0xe1, 0xe8, 0xef, 0xfa, 0xfd, 0xf4, 0xf3]; + +if (typeof Int32Array !== 'undefined') { + TABLE = new Int32Array(TABLE); +} + +module.exports = create(function(buf, previous) { + var byte, crc, _i, _len; + if (!Buffer.isBuffer(buf)) { + buf = Buffer(buf); + } + crc = ~~previous; + for (_i = 0, _len = buf.length; _i < _len; _i++) { + byte = buf[_i]; + crc = (TABLE[(crc ^ byte) & 0xff] ^ (crc << 8)) & 0xff; + } + return crc; +}); diff --git a/node_modules/express/node_modules/etag/node_modules/crc/lib/crc8_1wire.js b/node_modules/express/node_modules/etag/node_modules/crc/lib/crc8_1wire.js new file mode 100644 index 0000000..c63a422 --- /dev/null +++ b/node_modules/express/node_modules/etag/node_modules/crc/lib/crc8_1wire.js @@ -0,0 +1,25 @@ +// Generated by CoffeeScript 1.7.1 +var Buffer, TABLE, create; + +Buffer = require('buffer').Buffer; + +create = require('./create'); + +TABLE = [0x00, 0x5e, 0xbc, 0xe2, 0x61, 0x3f, 0xdd, 0x83, 0xc2, 0x9c, 0x7e, 0x20, 0xa3, 0xfd, 0x1f, 0x41, 0x9d, 0xc3, 0x21, 0x7f, 0xfc, 0xa2, 0x40, 0x1e, 0x5f, 0x01, 0xe3, 0xbd, 0x3e, 0x60, 0x82, 0xdc, 0x23, 0x7d, 0x9f, 0xc1, 0x42, 0x1c, 0xfe, 0xa0, 0xe1, 0xbf, 0x5d, 0x03, 0x80, 0xde, 0x3c, 0x62, 0xbe, 0xe0, 0x02, 0x5c, 0xdf, 0x81, 0x63, 0x3d, 0x7c, 0x22, 0xc0, 0x9e, 0x1d, 0x43, 0xa1, 0xff, 0x46, 0x18, 0xfa, 0xa4, 0x27, 0x79, 0x9b, 0xc5, 0x84, 0xda, 0x38, 0x66, 0xe5, 0xbb, 0x59, 0x07, 0xdb, 0x85, 0x67, 0x39, 0xba, 0xe4, 0x06, 0x58, 0x19, 0x47, 0xa5, 0xfb, 0x78, 0x26, 0xc4, 0x9a, 0x65, 0x3b, 0xd9, 0x87, 0x04, 0x5a, 0xb8, 0xe6, 0xa7, 0xf9, 0x1b, 0x45, 0xc6, 0x98, 0x7a, 0x24, 0xf8, 0xa6, 0x44, 0x1a, 0x99, 0xc7, 0x25, 0x7b, 0x3a, 0x64, 0x86, 0xd8, 0x5b, 0x05, 0xe7, 0xb9, 0x8c, 0xd2, 0x30, 0x6e, 0xed, 0xb3, 0x51, 0x0f, 0x4e, 0x10, 0xf2, 0xac, 0x2f, 0x71, 0x93, 0xcd, 0x11, 0x4f, 0xad, 0xf3, 0x70, 0x2e, 0xcc, 0x92, 0xd3, 0x8d, 0x6f, 0x31, 0xb2, 0xec, 0x0e, 0x50, 0xaf, 0xf1, 0x13, 0x4d, 0xce, 0x90, 0x72, 0x2c, 0x6d, 0x33, 0xd1, 0x8f, 0x0c, 0x52, 0xb0, 0xee, 0x32, 0x6c, 0x8e, 0xd0, 0x53, 0x0d, 0xef, 0xb1, 0xf0, 0xae, 0x4c, 0x12, 0x91, 0xcf, 0x2d, 0x73, 0xca, 0x94, 0x76, 0x28, 0xab, 0xf5, 0x17, 0x49, 0x08, 0x56, 0xb4, 0xea, 0x69, 0x37, 0xd5, 0x8b, 0x57, 0x09, 0xeb, 0xb5, 0x36, 0x68, 0x8a, 0xd4, 0x95, 0xcb, 0x29, 0x77, 0xf4, 0xaa, 0x48, 0x16, 0xe9, 0xb7, 0x55, 0x0b, 0x88, 0xd6, 0x34, 0x6a, 0x2b, 0x75, 0x97, 0xc9, 0x4a, 0x14, 0xf6, 0xa8, 0x74, 0x2a, 0xc8, 0x96, 0x15, 0x4b, 0xa9, 0xf7, 0xb6, 0xe8, 0x0a, 0x54, 0xd7, 0x89, 0x6b, 0x35]; + +if (typeof Int32Array !== 'undefined') { + TABLE = new Int32Array(TABLE); +} + +module.exports = create(function(buf, previous) { + var byte, crc, _i, _len; + if (!Buffer.isBuffer(buf)) { + buf = Buffer(buf); + } + crc = ~~previous; + for (_i = 0, _len = buf.length; _i < _len; _i++) { + byte = buf[_i]; + crc = (TABLE[(crc ^ byte) & 0xff] ^ (crc << 8)) & 0xff; + } + return crc; +}); diff --git a/node_modules/express/node_modules/etag/node_modules/crc/lib/create.js b/node_modules/express/node_modules/etag/node_modules/crc/lib/create.js new file mode 100644 index 0000000..df4d991 --- /dev/null +++ b/node_modules/express/node_modules/etag/node_modules/crc/lib/create.js @@ -0,0 +1,10 @@ +// Generated by CoffeeScript 1.7.1 +module.exports = function(calc) { + var fn; + fn = function(buf, previous) { + return calc(buf, previous) >>> 0; + }; + fn.signed = calc; + fn.unsigned = fn; + return fn; +}; diff --git a/node_modules/express/node_modules/etag/node_modules/crc/lib/hex.js b/node_modules/express/node_modules/etag/node_modules/crc/lib/hex.js new file mode 100644 index 0000000..0a6aa4c --- /dev/null +++ b/node_modules/express/node_modules/etag/node_modules/crc/lib/hex.js @@ -0,0 +1,9 @@ +// Generated by CoffeeScript 1.7.1 +module.exports = function(number) { + var result; + result = number.toString(16); + while (result.length % 2) { + result = "0" + result; + } + return result; +}; diff --git a/node_modules/express/node_modules/etag/node_modules/crc/lib/index.js b/node_modules/express/node_modules/etag/node_modules/crc/lib/index.js new file mode 100644 index 0000000..15ac34c --- /dev/null +++ b/node_modules/express/node_modules/etag/node_modules/crc/lib/index.js @@ -0,0 +1,11 @@ +// Generated by CoffeeScript 1.7.1 +module.exports = { + crc1: require('./crc1'), + crc8: require('./crc8'), + crc81wire: require('./crc8_1wire'), + crc16: require('./crc16'), + crc16ccitt: require('./crc16_ccitt'), + crc16modbus: require('./crc16_modbus'), + crc24: require('./crc24'), + crc32: require('./crc32') +}; diff --git a/node_modules/express/node_modules/etag/node_modules/crc/package.json b/node_modules/express/node_modules/etag/node_modules/crc/package.json new file mode 100644 index 0000000..5d8586f --- /dev/null +++ b/node_modules/express/node_modules/etag/node_modules/crc/package.json @@ -0,0 +1,57 @@ +{ + "name": "crc", + "version": "3.0.0", + "description": "Various CRC JavaScript implementations", + "keywords": [ + "crc" + ], + "main": "./lib/index.js", + "scripts": { + "test": "mocha test/*.spec.coffee", + "pretest": "coffee --bare --output ./lib --compile ./src/*.coffee" + }, + "author": { + "name": "Alex Gorbatchev", + "url": "https://github.com/alexgorbatchev" + }, + "devDependencies": { + "beautify-benchmark": "^0.2.4", + "benchmark": "^1.0.0", + "buffer-crc32": "^0.2.3", + "chai": "~1.9.1", + "coffee-errors": "~0.8.6", + "coffee-script": "~1.7.1", + "mocha": "*", + "seedrandom": "^2.3.6" + }, + "homepage": "https://github.com/alexgorbatchev/node-crc", + "bugs": { + "url": "https://github.com/alexgorbatchev/node-crc/issues" + }, + "repository": { + "type": "git", + "url": "git://github.com/alexgorbatchev/node-crc.git" + }, + "license": "MIT", + "gitHead": "16dbe7ca019d73be10e99c2f5fa690dcbfc0dd40", + "_id": "crc@3.0.0", + "_shasum": "d11e97ec44a844e5eb15a74fa2c7875d0aac4b22", + "_from": "crc@3.0.0", + "_npmVersion": "2.0.0-beta.0", + "_npmUser": { + "name": "alexgorbatchev", + "email": "alex.gorbatchev@gmail.com" + }, + "maintainers": [ + { + "name": "alexgorbatchev", + "email": "alex.gorbatchev@gmail.com" + } + ], + "dist": { + "shasum": "d11e97ec44a844e5eb15a74fa2c7875d0aac4b22", + "tarball": "http://registry.npmjs.org/crc/-/crc-3.0.0.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/crc/-/crc-3.0.0.tgz" +} diff --git a/node_modules/express/node_modules/etag/package.json b/node_modules/express/node_modules/etag/package.json new file mode 100644 index 0000000..c33c203 --- /dev/null +++ b/node_modules/express/node_modules/etag/package.json @@ -0,0 +1,74 @@ +{ + "name": "etag", + "description": "Create simple ETags", + "version": "1.3.1", + "contributors": [ + { + "name": "Douglas Christopher Wilson", + "email": "doug@somethingdoug.com" + }, + { + "name": "David Björklund", + "email": "david.bjorklund@gmail.com" + } + ], + "license": "MIT", + "keywords": [ + "etag", + "http", + "res" + ], + "repository": { + "type": "git", + "url": "https://github.com/jshttp/etag" + }, + "dependencies": { + "crc": "3.0.0" + }, + "devDependencies": { + "benchmark": "1.0.0", + "beautify-benchmark": "0.2.4", + "istanbul": "0.3.2", + "mocha": "~1.21.4", + "seedrandom": "~2.3.6" + }, + "files": [ + "LICENSE", + "HISTORY.md", + "index.js" + ], + "engines": { + "node": ">= 0.8" + }, + "scripts": { + "bench": "node benchmark/index.js", + "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/" + }, + "gitHead": "88a83fdccc15065893cfad6e2c7af8a379941f16", + "bugs": { + "url": "https://github.com/jshttp/etag/issues" + }, + "homepage": "https://github.com/jshttp/etag", + "_id": "etag@1.3.1", + "_shasum": "e51925728688a32dc4eea1cfa9ab4f734d055567", + "_from": "etag@~1.3.1", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + "maintainers": [ + { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + } + ], + "dist": { + "shasum": "e51925728688a32dc4eea1cfa9ab4f734d055567", + "tarball": "http://registry.npmjs.org/etag/-/etag-1.3.1.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/etag/-/etag-1.3.1.tgz" +} diff --git a/node_modules/express/node_modules/finalhandler/HISTORY.md b/node_modules/express/node_modules/finalhandler/HISTORY.md new file mode 100644 index 0000000..655d866 --- /dev/null +++ b/node_modules/express/node_modules/finalhandler/HISTORY.md @@ -0,0 +1,33 @@ +0.2.0 / 2014-09-03 +================== + + * Set `X-Content-Type-Options: nosniff` header + * deps: debug@~2.0.0 + +0.1.0 / 2014-07-16 +================== + + * Respond after request fully read + - prevents hung responses and socket hang ups + * deps: debug@1.0.4 + +0.0.3 / 2014-07-11 +================== + + * deps: debug@1.0.3 + - Add support for multiple wildcards in namespaces + +0.0.2 / 2014-06-19 +================== + + * Handle invalid status codes + +0.0.1 / 2014-06-05 +================== + + * deps: debug@1.0.2 + +0.0.0 / 2014-06-05 +================== + + * Extracted from connect/express diff --git a/node_modules/express/node_modules/finalhandler/LICENSE b/node_modules/express/node_modules/finalhandler/LICENSE new file mode 100644 index 0000000..eda2305 --- /dev/null +++ b/node_modules/express/node_modules/finalhandler/LICENSE @@ -0,0 +1,22 @@ +(The MIT License) + +Copyright (c) 2014 Douglas Christopher Wilson + +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/node_modules/express/node_modules/finalhandler/README.md b/node_modules/express/node_modules/finalhandler/README.md new file mode 100644 index 0000000..fd7eb58 --- /dev/null +++ b/node_modules/express/node_modules/finalhandler/README.md @@ -0,0 +1,133 @@ +# finalhandler + +[![NPM Version][npm-image]][npm-url] +[![NPM Downloads][downloads-image]][downloads-url] +[![Node.js Version][node-image]][node-url] +[![Build Status][travis-image]][travis-url] +[![Test Coverage][coveralls-image]][coveralls-url] + +Node.js function to invoke as the final step to respond to HTTP request. + +## Installation + +```sh +$ npm install finalhandler +``` + +## API + +```js +var finalhandler = require('finalhandler') +``` + +### finalhandler(req, res, [options]) + +Returns function to be invoked as the final step for the given `req` and `res`. +This function is to be invoked as `fn(err)`. If `err` is falsy, the handler will +write out a 404 response to the `res`. If it is truthy, an error response will +be written out to the `res`, and `res.statusCode` is set from `err.status`. + +The final handler will also unpipe anything from `req` when it is invoked. + +#### options.env + +By default, the environment is determined by `NODE_ENV` variable, but it can be +overridden by this option. + +#### options.onerror + +Provide a function to be called with the `err` when it exists. Can be used for +writing errors to a central location without excessive function generation. Called +as `onerror(err, req, res)`. + +## Examples + +### always 404 + +```js +var finalhandler = require('finalhandler') +var http = require('http') + +var server = http.createServer(function (req, res) { + var done = finalhandler(req, res) + done() +}) + +server.listen(3000) +``` + +### perform simple action + +```js +var finalhandler = require('finalhandler') +var fs = require('fs') +var http = require('http') + +var server = http.createServer(function (req, res) { + var done = finalhandler(req, res) + + fs.readFile('index.html', function (err, buf) { + if (err) return done(err) + res.setHeader('Content-Type', 'text/html') + res.end(buf) + }) +}) + +server.listen(3000) +``` + +### use with middleware-style functions + +```js +var finalhandler = require('finalhandler') +var http = require('http') +var serveStatic = require('serve-static') + +var serve = serveStatic('public') + +var server = http.createServer(function (req, res) { + var done = finalhandler(req, res) + serve(req, res, done) +}) + +server.listen(3000) +``` + +### keep log of all errors + +```js +var finalhandler = require('finalhandler') +var fs = require('fs') +var http = require('http') + +var server = http.createServer(function (req, res) { + var done = finalhandler(req, res, {onerror: logerror}) + + fs.readFile('index.html', function (err, buf) { + if (err) return done(err) + res.setHeader('Content-Type', 'text/html') + res.end(buf) + }) +}) + +server.listen(3000) + +function logerror(err) { + console.error(err.stack || err.toString()) +} +``` + +## License + +[MIT](LICENSE) + +[npm-image]: https://img.shields.io/npm/v/finalhandler.svg?style=flat +[npm-url]: https://npmjs.org/package/finalhandler +[node-image]: http://img.shields.io/badge/node.js-%3E%3D_0.8-brightgreen.svg?style=flat +[node-url]: http://nodejs.org/download/ +[travis-image]: https://img.shields.io/travis/pillarjs/finalhandler.svg?style=flat +[travis-url]: https://travis-ci.org/pillarjs/finalhandler +[coveralls-image]: https://img.shields.io/coveralls/pillarjs/finalhandler.svg?style=flat +[coveralls-url]: https://coveralls.io/r/pillarjs/finalhandler?branch=master +[downloads-image]: http://img.shields.io/npm/dm/finalhandler.svg?style=flat +[downloads-url]: https://npmjs.org/package/finalhandler diff --git a/node_modules/express/node_modules/finalhandler/index.js b/node_modules/express/node_modules/finalhandler/index.js new file mode 100644 index 0000000..d1a9b2f --- /dev/null +++ b/node_modules/express/node_modules/finalhandler/index.js @@ -0,0 +1,163 @@ +/*! + * finalhandler + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module dependencies. + */ + +var debug = require('debug')('finalhandler') +var escapeHtml = require('escape-html') +var http = require('http') + +/** + * Variables. + */ + +/* istanbul ignore next */ +var defer = typeof setImmediate === 'function' + ? setImmediate + : function(fn){ process.nextTick(fn.bind.apply(fn, arguments)) } + +/** + * Module exports. + */ + +module.exports = finalhandler + +/** + * Final handler: + * + * @param {Request} req + * @param {Response} res + * @param {Object} [options] + * @return {Function} + * @api public + */ + +function finalhandler(req, res, options) { + options = options || {} + + // get environment + var env = options.env || process.env.NODE_ENV || 'development' + + // get error callback + var onerror = options.onerror + + return function (err) { + var msg + + // unhandled error + if (err) { + // default status code to 500 + if (!res.statusCode || res.statusCode < 400) { + res.statusCode = 500 + } + + // respect err.status + if (err.status) { + res.statusCode = err.status + } + + // production gets a basic error message + var msg = env === 'production' + ? http.STATUS_CODES[res.statusCode] + : err.stack || err.toString() + msg = escapeHtml(msg) + .replace(/\n/g, '
    ') + .replace(/ /g, '  ') + '\n' + } else { + res.statusCode = 404 + msg = 'Cannot ' + escapeHtml(req.method) + ' ' + escapeHtml(req.originalUrl || req.url) + '\n' + } + + debug('default %s', res.statusCode) + + // schedule onerror callback + if (err && onerror) { + defer(onerror, err, req, res) + } + + // cannot actually respond + if (res._header) { + return req.socket.destroy() + } + + send(req, res, res.statusCode, msg) + } +} + +/** + * Send response. + * + * @param {IncomingMessage} req + * @param {OutgoingMessage} res + * @param {number} status + * @param {string} body + * @api private + */ + +function send(req, res, status, body) { + function write() { + res.statusCode = status + + // security header for content sniffing + res.setHeader('X-Content-Type-Options', 'nosniff') + + // standard headers + res.setHeader('Content-Type', 'text/html; charset=utf-8') + res.setHeader('Content-Length', Buffer.byteLength(body, 'utf8')) + + if (req.method === 'HEAD') { + res.end() + return + } + + res.end(body, 'utf8') + } + + if (!req.readable) { + write() + return + } + + // unpipe everything from the request + unpipe(req) + + // flush the request + req.once('end', write) + req.resume() +} + +/** + * Unpipe everything from a stream. + * + * @param {Object} stream + * @api private + */ + +/* istanbul ignore next: implementation differs between versions */ +function unpipe(stream) { + if (typeof stream.unpipe === 'function') { + // new-style + stream.unpipe() + return + } + + // Node.js 0.8 hack + var listener + var listeners = stream.listeners('close') + + for (var i = 0; i < listeners.length; i++) { + listener = listeners[i] + + if (listener.name !== 'cleanup' && listener.name !== 'onclose') { + continue + } + + // invoke the listener + listener.call(stream) + } +} diff --git a/node_modules/express/node_modules/finalhandler/node_modules/debug/.jshintrc b/node_modules/express/node_modules/finalhandler/node_modules/debug/.jshintrc new file mode 100644 index 0000000..299877f --- /dev/null +++ b/node_modules/express/node_modules/finalhandler/node_modules/debug/.jshintrc @@ -0,0 +1,3 @@ +{ + "laxbreak": true +} diff --git a/node_modules/express/node_modules/finalhandler/node_modules/debug/.npmignore b/node_modules/express/node_modules/finalhandler/node_modules/debug/.npmignore new file mode 100644 index 0000000..7e6163d --- /dev/null +++ b/node_modules/express/node_modules/finalhandler/node_modules/debug/.npmignore @@ -0,0 +1,6 @@ +support +test +examples +example +*.sock +dist diff --git a/node_modules/express/node_modules/finalhandler/node_modules/debug/History.md b/node_modules/express/node_modules/finalhandler/node_modules/debug/History.md new file mode 100644 index 0000000..79429ff --- /dev/null +++ b/node_modules/express/node_modules/finalhandler/node_modules/debug/History.md @@ -0,0 +1,150 @@ + +2.0.0 / 2014-09-01 +================== + + * package: update "browserify" to v5.11.0 + * node: use stderr rather than stdout for logging (#29, @stephenmathieson) + +1.0.4 / 2014-07-15 +================== + + * dist: recompile + * example: remove `console.info()` log usage + * example: add "Content-Type" UTF-8 header to browser example + * browser: place %c marker after the space character + * browser: reset the "content" color via `color: inherit` + * browser: add colors support for Firefox >= v31 + * debug: prefer an instance `log()` function over the global one (#119) + * Readme: update documentation about styled console logs for FF v31 (#116, @wryk) + +1.0.3 / 2014-07-09 +================== + + * Add support for multiple wildcards in namespaces (#122, @seegno) + * browser: fix lint + +1.0.2 / 2014-06-10 +================== + + * browser: update color palette (#113, @gscottolson) + * common: make console logging function configurable (#108, @timoxley) + * node: fix %o colors on old node <= 0.8.x + * Makefile: find node path using shell/which (#109, @timoxley) + +1.0.1 / 2014-06-06 +================== + + * browser: use `removeItem()` to clear localStorage + * browser, node: don't set DEBUG if namespaces is undefined (#107, @leedm777) + * package: add "contributors" section + * node: fix comment typo + * README: list authors + +1.0.0 / 2014-06-04 +================== + + * make ms diff be global, not be scope + * debug: ignore empty strings in enable() + * node: make DEBUG_COLORS able to disable coloring + * *: export the `colors` array + * npmignore: don't publish the `dist` dir + * Makefile: refactor to use browserify + * package: add "browserify" as a dev dependency + * Readme: add Web Inspector Colors section + * node: reset terminal color for the debug content + * node: map "%o" to `util.inspect()` + * browser: map "%j" to `JSON.stringify()` + * debug: add custom "formatters" + * debug: use "ms" module for humanizing the diff + * Readme: add "bash" syntax highlighting + * browser: add Firebug color support + * browser: add colors for WebKit browsers + * node: apply log to `console` + * rewrite: abstract common logic for Node & browsers + * add .jshintrc file + +0.8.1 / 2014-04-14 +================== + + * package: re-add the "component" section + +0.8.0 / 2014-03-30 +================== + + * add `enable()` method for nodejs. Closes #27 + * change from stderr to stdout + * remove unnecessary index.js file + +0.7.4 / 2013-11-13 +================== + + * remove "browserify" key from package.json (fixes something in browserify) + +0.7.3 / 2013-10-30 +================== + + * fix: catch localStorage security error when cookies are blocked (Chrome) + * add debug(err) support. Closes #46 + * add .browser prop to package.json. Closes #42 + +0.7.2 / 2013-02-06 +================== + + * fix package.json + * fix: Mobile Safari (private mode) is broken with debug + * fix: Use unicode to send escape character to shell instead of octal to work with strict mode javascript + +0.7.1 / 2013-02-05 +================== + + * add repository URL to package.json + * add DEBUG_COLORED to force colored output + * add browserify support + * fix component. Closes #24 + +0.7.0 / 2012-05-04 +================== + + * Added .component to package.json + * Added debug.component.js build + +0.6.0 / 2012-03-16 +================== + + * Added support for "-" prefix in DEBUG [Vinay Pulim] + * Added `.enabled` flag to the node version [TooTallNate] + +0.5.0 / 2012-02-02 +================== + + * Added: humanize diffs. Closes #8 + * Added `debug.disable()` to the CS variant + * Removed padding. Closes #10 + * Fixed: persist client-side variant again. Closes #9 + +0.4.0 / 2012-02-01 +================== + + * Added browser variant support for older browsers [TooTallNate] + * Added `debug.enable('project:*')` to browser variant [TooTallNate] + * Added padding to diff (moved it to the right) + +0.3.0 / 2012-01-26 +================== + + * Added millisecond diff when isatty, otherwise UTC string + +0.2.0 / 2012-01-22 +================== + + * Added wildcard support + +0.1.0 / 2011-12-02 +================== + + * Added: remove colors unless stderr isatty [TooTallNate] + +0.0.1 / 2010-01-03 +================== + + * Initial release diff --git a/node_modules/express/node_modules/finalhandler/node_modules/debug/Makefile b/node_modules/express/node_modules/finalhandler/node_modules/debug/Makefile new file mode 100644 index 0000000..b0bde6e --- /dev/null +++ b/node_modules/express/node_modules/finalhandler/node_modules/debug/Makefile @@ -0,0 +1,33 @@ + +# get Makefile directory name: http://stackoverflow.com/a/5982798/376773 +THIS_MAKEFILE_PATH:=$(word $(words $(MAKEFILE_LIST)),$(MAKEFILE_LIST)) +THIS_DIR:=$(shell cd $(dir $(THIS_MAKEFILE_PATH));pwd) + +# BIN directory +BIN := $(THIS_DIR)/node_modules/.bin + +# applications +NODE ?= $(shell which node) +NPM ?= $(NODE) $(shell which npm) +BROWSERIFY ?= $(NODE) $(BIN)/browserify + +all: dist/debug.js + +install: node_modules + +clean: + @rm -rf node_modules dist + +dist: + @mkdir -p $@ + +dist/debug.js: node_modules browser.js debug.js dist + @$(BROWSERIFY) \ + --standalone debug \ + . > $@ + +node_modules: package.json + @NODE_ENV= $(NPM) install + @touch node_modules + +.PHONY: all install clean diff --git a/node_modules/express/node_modules/finalhandler/node_modules/debug/Readme.md b/node_modules/express/node_modules/finalhandler/node_modules/debug/Readme.md new file mode 100644 index 0000000..e59b9ad --- /dev/null +++ b/node_modules/express/node_modules/finalhandler/node_modules/debug/Readme.md @@ -0,0 +1,156 @@ +# debug + + tiny node.js debugging utility modelled after node core's debugging technique. + +## Installation + +```bash +$ npm install debug +``` + +## Usage + + With `debug` you simply invoke the exported function to generate your debug function, passing it a name which will determine if a noop function is returned, or a decorated `console.error`, so all of the `console` format string goodies you're used to work fine. A unique color is selected per-function for visibility. + +Example _app.js_: + +```js +var debug = require('debug')('http') + , http = require('http') + , name = 'My App'; + +// fake app + +debug('booting %s', name); + +http.createServer(function(req, res){ + debug(req.method + ' ' + req.url); + res.end('hello\n'); +}).listen(3000, function(){ + debug('listening'); +}); + +// fake worker of some kind + +require('./worker'); +``` + +Example _worker.js_: + +```js +var debug = require('debug')('worker'); + +setInterval(function(){ + debug('doing some work'); +}, 1000); +``` + + The __DEBUG__ environment variable is then used to enable these based on space or comma-delimited names. Here are some examples: + + ![debug http and worker](http://f.cl.ly/items/18471z1H402O24072r1J/Screenshot.png) + + ![debug worker](http://f.cl.ly/items/1X413v1a3M0d3C2c1E0i/Screenshot.png) + +## Millisecond diff + + When actively developing an application it can be useful to see when the time spent between one `debug()` call and the next. Suppose for example you invoke `debug()` before requesting a resource, and after as well, the "+NNNms" will show you how much time was spent between calls. + + ![](http://f.cl.ly/items/2i3h1d3t121M2Z1A3Q0N/Screenshot.png) + + When stdout is not a TTY, `Date#toUTCString()` is used, making it more useful for logging the debug information as shown below: + + ![](http://f.cl.ly/items/112H3i0e0o0P0a2Q2r11/Screenshot.png) + +## Conventions + + If you're using this in one or more of your libraries, you _should_ use the name of your library so that developers may toggle debugging as desired without guessing names. If you have more than one debuggers you _should_ prefix them with your library name and use ":" to separate features. For example "bodyParser" from Connect would then be "connect:bodyParser". + +## Wildcards + + The `*` character may be used as a wildcard. Suppose for example your library has debuggers named "connect:bodyParser", "connect:compress", "connect:session", instead of listing all three with `DEBUG=connect:bodyParser,connect.compress,connect:session`, you may simply do `DEBUG=connect:*`, or to run everything using this module simply use `DEBUG=*`. + + You can also exclude specific debuggers by prefixing them with a "-" character. For example, `DEBUG=*,-connect:*` would include all debuggers except those starting with "connect:". + +## Browser support + + Debug works in the browser as well, currently persisted by `localStorage`. For example if you have `worker:a` and `worker:b` as shown below, and wish to debug both type `debug.enable('worker:*')` in the console and refresh the page, this will remain until you disable with `debug.disable()`. + +```js +a = debug('worker:a'); +b = debug('worker:b'); + +setInterval(function(){ + a('doing some work'); +}, 1000); + +setInterval(function(){ + b('doing some work'); +}, 1200); +``` + +#### Web Inspector Colors + + Colors are also enabled on "Web Inspectors" that understand the `%c` formatting + option. These are WebKit web inspectors, Firefox ([since version + 31](https://hacks.mozilla.org/2014/05/editable-box-model-multiple-selection-sublime-text-keys-much-more-firefox-developer-tools-episode-31/)) + and the Firebug plugin for Firefox (any version). + + Colored output looks something like: + + ![](https://cloud.githubusercontent.com/assets/71256/3139768/b98c5fd8-e8ef-11e3-862a-f7253b6f47c6.png) + +### stderr vs stdout + +You can set an alternative logging method per-namespace by overriding the `log` method on a per-namespace or globally: + +Example _stderr.js_: + +```js +var debug = require('../'); +var log = debug('app:log'); + +// by default console.log is used +log('goes to stdout!'); + +var error = debug('app:error'); +// set this namespace to log via console.error +error.log = console.error.bind(console); // don't forget to bind to console! +error('goes to stderr'); +log('still goes to stdout!'); + +// set all output to go via console.warn +// overrides all per-namespace log settings +debug.log = console.warn.bind(console); +log('now goes to stderr via console.warn'); +error('still goes to stderr, but via console.warn now'); +``` + +## Authors + + - TJ Holowaychuk + - Nathan Rajlich + +## License + +(The MIT License) + +Copyright (c) 2014 TJ Holowaychuk <tj@vision-media.ca> + +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/node_modules/express/node_modules/finalhandler/node_modules/debug/browser.js b/node_modules/express/node_modules/finalhandler/node_modules/debug/browser.js new file mode 100644 index 0000000..ce6369f --- /dev/null +++ b/node_modules/express/node_modules/finalhandler/node_modules/debug/browser.js @@ -0,0 +1,147 @@ + +/** + * This is the web browser implementation of `debug()`. + * + * Expose `debug()` as the module. + */ + +exports = module.exports = require('./debug'); +exports.log = log; +exports.formatArgs = formatArgs; +exports.save = save; +exports.load = load; +exports.useColors = useColors; + +/** + * Colors. + */ + +exports.colors = [ + 'lightseagreen', + 'forestgreen', + 'goldenrod', + 'dodgerblue', + 'darkorchid', + 'crimson' +]; + +/** + * Currently only WebKit-based Web Inspectors, Firefox >= v31, + * and the Firebug extension (any Firefox version) are known + * to support "%c" CSS customizations. + * + * TODO: add a `localStorage` variable to explicitly enable/disable colors + */ + +function useColors() { + // is webkit? http://stackoverflow.com/a/16459606/376773 + return ('WebkitAppearance' in document.documentElement.style) || + // is firebug? http://stackoverflow.com/a/398120/376773 + (window.console && (console.firebug || (console.exception && console.table))) || + // is firefox >= v31? + // https://developer.mozilla.org/en-US/docs/Tools/Web_Console#Styling_messages + (navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/) && parseInt(RegExp.$1, 10) >= 31); +} + +/** + * Map %j to `JSON.stringify()`, since no Web Inspectors do that by default. + */ + +exports.formatters.j = function(v) { + return JSON.stringify(v); +}; + + +/** + * Colorize log arguments if enabled. + * + * @api public + */ + +function formatArgs() { + var args = arguments; + var useColors = this.useColors; + + args[0] = (useColors ? '%c' : '') + + this.namespace + + (useColors ? ' %c' : ' ') + + args[0] + + (useColors ? '%c ' : ' ') + + '+' + exports.humanize(this.diff); + + if (!useColors) return args; + + var c = 'color: ' + this.color; + args = [args[0], c, 'color: inherit'].concat(Array.prototype.slice.call(args, 1)); + + // the final "%c" is somewhat tricky, because there could be other + // arguments passed either before or after the %c, so we need to + // figure out the correct index to insert the CSS into + var index = 0; + var lastC = 0; + args[0].replace(/%[a-z%]/g, function(match) { + if ('%%' === match) return; + index++; + if ('%c' === match) { + // we only are interested in the *last* %c + // (the user may have provided their own) + lastC = index; + } + }); + + args.splice(lastC, 0, c); + return args; +} + +/** + * Invokes `console.log()` when available. + * No-op when `console.log` is not a "function". + * + * @api public + */ + +function log() { + // This hackery is required for IE8, + // where the `console.log` function doesn't have 'apply' + return 'object' == typeof console + && 'function' == typeof console.log + && Function.prototype.apply.call(console.log, console, arguments); +} + +/** + * Save `namespaces`. + * + * @param {String} namespaces + * @api private + */ + +function save(namespaces) { + try { + if (null == namespaces) { + localStorage.removeItem('debug'); + } else { + localStorage.debug = namespaces; + } + } catch(e) {} +} + +/** + * Load `namespaces`. + * + * @return {String} returns the previously persisted debug modes + * @api private + */ + +function load() { + var r; + try { + r = localStorage.debug; + } catch(e) {} + return r; +} + +/** + * Enable namespaces listed in `localStorage.debug` initially. + */ + +exports.enable(load()); diff --git a/node_modules/express/node_modules/finalhandler/node_modules/debug/component.json b/node_modules/express/node_modules/finalhandler/node_modules/debug/component.json new file mode 100644 index 0000000..db1ceed --- /dev/null +++ b/node_modules/express/node_modules/finalhandler/node_modules/debug/component.json @@ -0,0 +1,19 @@ +{ + "name": "debug", + "repo": "visionmedia/debug", + "description": "small debugging utility", + "version": "2.0.0", + "keywords": [ + "debug", + "log", + "debugger" + ], + "main": "browser.js", + "scripts": [ + "browser.js", + "debug.js" + ], + "dependencies": { + "guille/ms.js": "0.6.1" + } +} diff --git a/node_modules/express/node_modules/finalhandler/node_modules/debug/debug.js b/node_modules/express/node_modules/finalhandler/node_modules/debug/debug.js new file mode 100644 index 0000000..7571a86 --- /dev/null +++ b/node_modules/express/node_modules/finalhandler/node_modules/debug/debug.js @@ -0,0 +1,197 @@ + +/** + * This is the common logic for both the Node.js and web browser + * implementations of `debug()`. + * + * Expose `debug()` as the module. + */ + +exports = module.exports = debug; +exports.coerce = coerce; +exports.disable = disable; +exports.enable = enable; +exports.enabled = enabled; +exports.humanize = require('ms'); + +/** + * The currently active debug mode names, and names to skip. + */ + +exports.names = []; +exports.skips = []; + +/** + * Map of special "%n" handling functions, for the debug "format" argument. + * + * Valid key names are a single, lowercased letter, i.e. "n". + */ + +exports.formatters = {}; + +/** + * Previously assigned color. + */ + +var prevColor = 0; + +/** + * Previous log timestamp. + */ + +var prevTime; + +/** + * Select a color. + * + * @return {Number} + * @api private + */ + +function selectColor() { + return exports.colors[prevColor++ % exports.colors.length]; +} + +/** + * Create a debugger with the given `namespace`. + * + * @param {String} namespace + * @return {Function} + * @api public + */ + +function debug(namespace) { + + // define the `disabled` version + function disabled() { + } + disabled.enabled = false; + + // define the `enabled` version + function enabled() { + + var self = enabled; + + // set `diff` timestamp + var curr = +new Date(); + var ms = curr - (prevTime || curr); + self.diff = ms; + self.prev = prevTime; + self.curr = curr; + prevTime = curr; + + // add the `color` if not set + if (null == self.useColors) self.useColors = exports.useColors(); + if (null == self.color && self.useColors) self.color = selectColor(); + + var args = Array.prototype.slice.call(arguments); + + args[0] = exports.coerce(args[0]); + + if ('string' !== typeof args[0]) { + // anything else let's inspect with %o + args = ['%o'].concat(args); + } + + // apply any `formatters` transformations + var index = 0; + args[0] = args[0].replace(/%([a-z%])/g, function(match, format) { + // if we encounter an escaped % then don't increase the array index + if (match === '%%') return match; + index++; + var formatter = exports.formatters[format]; + if ('function' === typeof formatter) { + var val = args[index]; + match = formatter.call(self, val); + + // now we need to remove `args[index]` since it's inlined in the `format` + args.splice(index, 1); + index--; + } + return match; + }); + + if ('function' === typeof exports.formatArgs) { + args = exports.formatArgs.apply(self, args); + } + var logFn = enabled.log || exports.log || console.log.bind(console); + logFn.apply(self, args); + } + enabled.enabled = true; + + var fn = exports.enabled(namespace) ? enabled : disabled; + + fn.namespace = namespace; + + return fn; +} + +/** + * Enables a debug mode by namespaces. This can include modes + * separated by a colon and wildcards. + * + * @param {String} namespaces + * @api public + */ + +function enable(namespaces) { + exports.save(namespaces); + + var split = (namespaces || '').split(/[\s,]+/); + var len = split.length; + + for (var i = 0; i < len; i++) { + if (!split[i]) continue; // ignore empty strings + namespaces = split[i].replace(/\*/g, '.*?'); + if (namespaces[0] === '-') { + exports.skips.push(new RegExp('^' + namespaces.substr(1) + '$')); + } else { + exports.names.push(new RegExp('^' + namespaces + '$')); + } + } +} + +/** + * Disable debug output. + * + * @api public + */ + +function disable() { + exports.enable(''); +} + +/** + * Returns true if the given mode name is enabled, false otherwise. + * + * @param {String} name + * @return {Boolean} + * @api public + */ + +function enabled(name) { + var i, len; + for (i = 0, len = exports.skips.length; i < len; i++) { + if (exports.skips[i].test(name)) { + return false; + } + } + for (i = 0, len = exports.names.length; i < len; i++) { + if (exports.names[i].test(name)) { + return true; + } + } + return false; +} + +/** + * Coerce `val`. + * + * @param {Mixed} val + * @return {Mixed} + * @api private + */ + +function coerce(val) { + if (val instanceof Error) return val.stack || val.message; + return val; +} diff --git a/node_modules/express/node_modules/finalhandler/node_modules/debug/node.js b/node_modules/express/node_modules/finalhandler/node_modules/debug/node.js new file mode 100644 index 0000000..db86f64 --- /dev/null +++ b/node_modules/express/node_modules/finalhandler/node_modules/debug/node.js @@ -0,0 +1,129 @@ + +/** + * Module dependencies. + */ + +var tty = require('tty'); +var util = require('util'); + +/** + * This is the Node.js implementation of `debug()`. + * + * Expose `debug()` as the module. + */ + +exports = module.exports = require('./debug'); +exports.log = log; +exports.formatArgs = formatArgs; +exports.save = save; +exports.load = load; +exports.useColors = useColors; + +/** + * Colors. + */ + +exports.colors = [6, 2, 3, 4, 5, 1]; + +/** + * Is stdout a TTY? Colored output is enabled when `true`. + */ + +function useColors() { + var debugColors = (process.env.DEBUG_COLORS || '').trim().toLowerCase(); + if (0 === debugColors.length) { + return tty.isatty(1); + } else { + return '0' !== debugColors + && 'no' !== debugColors + && 'false' !== debugColors + && 'disabled' !== debugColors; + } +} + +/** + * Map %o to `util.inspect()`, since Node doesn't do that out of the box. + */ + +var inspect = (4 === util.inspect.length ? + // node <= 0.8.x + function (v, colors) { + return util.inspect(v, void 0, void 0, colors); + } : + // node > 0.8.x + function (v, colors) { + return util.inspect(v, { colors: colors }); + } +); + +exports.formatters.o = function(v) { + return inspect(v, this.useColors) + .replace(/\s*\n\s*/g, ' '); +}; + +/** + * Adds ANSI color escape codes if enabled. + * + * @api public + */ + +function formatArgs() { + var args = arguments; + var useColors = this.useColors; + var name = this.namespace; + + if (useColors) { + var c = this.color; + + args[0] = ' \u001b[9' + c + 'm' + name + ' ' + + '\u001b[0m' + + args[0] + '\u001b[3' + c + 'm' + + ' +' + exports.humanize(this.diff) + '\u001b[0m'; + } else { + args[0] = new Date().toUTCString() + + ' ' + name + ' ' + args[0]; + } + return args; +} + +/** + * Invokes `console.error()` with the specified arguments. + */ + +function log() { + return console.error.apply(console, arguments); +} + +/** + * Save `namespaces`. + * + * @param {String} namespaces + * @api private + */ + +function save(namespaces) { + if (null == namespaces) { + // If you set a process.env field to null or undefined, it gets cast to the + // string 'null' or 'undefined'. Just delete instead. + delete process.env.DEBUG; + } else { + process.env.DEBUG = namespaces; + } +} + +/** + * Load `namespaces`. + * + * @return {String} returns the previously persisted debug modes + * @api private + */ + +function load() { + return process.env.DEBUG; +} + +/** + * Enable namespaces listed in `process.env.DEBUG` initially. + */ + +exports.enable(load()); diff --git a/node_modules/express/node_modules/finalhandler/node_modules/debug/node_modules/ms/.npmignore b/node_modules/express/node_modules/finalhandler/node_modules/debug/node_modules/ms/.npmignore new file mode 100644 index 0000000..d1aa0ce --- /dev/null +++ b/node_modules/express/node_modules/finalhandler/node_modules/debug/node_modules/ms/.npmignore @@ -0,0 +1,5 @@ +node_modules +test +History.md +Makefile +component.json diff --git a/node_modules/express/node_modules/finalhandler/node_modules/debug/node_modules/ms/README.md b/node_modules/express/node_modules/finalhandler/node_modules/debug/node_modules/ms/README.md new file mode 100644 index 0000000..d4ab12a --- /dev/null +++ b/node_modules/express/node_modules/finalhandler/node_modules/debug/node_modules/ms/README.md @@ -0,0 +1,33 @@ +# ms.js: miliseconds conversion utility + +```js +ms('1d') // 86400000 +ms('10h') // 36000000 +ms('2h') // 7200000 +ms('1m') // 60000 +ms('5s') // 5000 +ms('100') // 100 +``` + +```js +ms(60000) // "1m" +ms(2 * 60000) // "2m" +ms(ms('10 hours')) // "10h" +``` + +```js +ms(60000, { long: true }) // "1 minute" +ms(2 * 60000, { long: true }) // "2 minutes" +ms(ms('10 hours', { long: true })) // "10 hours" +``` + +- Node/Browser compatible. Published as `ms` in NPM. +- If a number is supplied to `ms`, a string with a unit is returned. +- If a string that contains the number is supplied, it returns it as +a number (e.g: it returns `100` for `'100'`). +- If you pass a string with a number and a valid unit, the number of +equivalent ms is returned. + +## License + +MIT \ No newline at end of file diff --git a/node_modules/express/node_modules/finalhandler/node_modules/debug/node_modules/ms/index.js b/node_modules/express/node_modules/finalhandler/node_modules/debug/node_modules/ms/index.js new file mode 100644 index 0000000..c5847f8 --- /dev/null +++ b/node_modules/express/node_modules/finalhandler/node_modules/debug/node_modules/ms/index.js @@ -0,0 +1,111 @@ +/** + * Helpers. + */ + +var s = 1000; +var m = s * 60; +var h = m * 60; +var d = h * 24; +var y = d * 365.25; + +/** + * Parse or format the given `val`. + * + * Options: + * + * - `long` verbose formatting [false] + * + * @param {String|Number} val + * @param {Object} options + * @return {String|Number} + * @api public + */ + +module.exports = function(val, options){ + options = options || {}; + if ('string' == typeof val) return parse(val); + return options.long + ? long(val) + : short(val); +}; + +/** + * Parse the given `str` and return milliseconds. + * + * @param {String} str + * @return {Number} + * @api private + */ + +function parse(str) { + var match = /^((?:\d+)?\.?\d+) *(ms|seconds?|s|minutes?|m|hours?|h|days?|d|years?|y)?$/i.exec(str); + if (!match) return; + var n = parseFloat(match[1]); + var type = (match[2] || 'ms').toLowerCase(); + switch (type) { + case 'years': + case 'year': + case 'y': + return n * y; + case 'days': + case 'day': + case 'd': + return n * d; + case 'hours': + case 'hour': + case 'h': + return n * h; + case 'minutes': + case 'minute': + case 'm': + return n * m; + case 'seconds': + case 'second': + case 's': + return n * s; + case 'ms': + return n; + } +} + +/** + * Short format for `ms`. + * + * @param {Number} ms + * @return {String} + * @api private + */ + +function short(ms) { + if (ms >= d) return Math.round(ms / d) + 'd'; + if (ms >= h) return Math.round(ms / h) + 'h'; + if (ms >= m) return Math.round(ms / m) + 'm'; + if (ms >= s) return Math.round(ms / s) + 's'; + return ms + 'ms'; +} + +/** + * Long format for `ms`. + * + * @param {Number} ms + * @return {String} + * @api private + */ + +function long(ms) { + return plural(ms, d, 'day') + || plural(ms, h, 'hour') + || plural(ms, m, 'minute') + || plural(ms, s, 'second') + || ms + ' ms'; +} + +/** + * Pluralization helper. + */ + +function plural(ms, n, name) { + if (ms < n) return; + if (ms < n * 1.5) return Math.floor(ms / n) + ' ' + name; + return Math.ceil(ms / n) + ' ' + name + 's'; +} diff --git a/node_modules/express/node_modules/finalhandler/node_modules/debug/node_modules/ms/package.json b/node_modules/express/node_modules/finalhandler/node_modules/debug/node_modules/ms/package.json new file mode 100644 index 0000000..654cde8 --- /dev/null +++ b/node_modules/express/node_modules/finalhandler/node_modules/debug/node_modules/ms/package.json @@ -0,0 +1,47 @@ +{ + "name": "ms", + "version": "0.6.2", + "description": "Tiny ms conversion utility", + "repository": { + "type": "git", + "url": "git://github.com/guille/ms.js.git" + }, + "main": "./index", + "devDependencies": { + "mocha": "*", + "expect.js": "*", + "serve": "*" + }, + "component": { + "scripts": { + "ms/index.js": "index.js" + } + }, + "readme": "# ms.js: miliseconds conversion utility\n\n```js\nms('1d') // 86400000\nms('10h') // 36000000\nms('2h') // 7200000\nms('1m') // 60000\nms('5s') // 5000\nms('100') // 100\n```\n\n```js\nms(60000) // \"1m\"\nms(2 * 60000) // \"2m\"\nms(ms('10 hours')) // \"10h\"\n```\n\n```js\nms(60000, { long: true }) // \"1 minute\"\nms(2 * 60000, { long: true }) // \"2 minutes\"\nms(ms('10 hours', { long: true })) // \"10 hours\"\n```\n\n- Node/Browser compatible. Published as `ms` in NPM.\n- If a number is supplied to `ms`, a string with a unit is returned.\n- If a string that contains the number is supplied, it returns it as\na number (e.g: it returns `100` for `'100'`).\n- If you pass a string with a number and a valid unit, the number of\nequivalent ms is returned.\n\n## License\n\nMIT", + "readmeFilename": "README.md", + "bugs": { + "url": "https://github.com/guille/ms.js/issues" + }, + "_id": "ms@0.6.2", + "dist": { + "shasum": "d89c2124c6fdc1353d65a8b77bf1aac4b193708c", + "tarball": "http://registry.npmjs.org/ms/-/ms-0.6.2.tgz" + }, + "_from": "ms@0.6.2", + "_npmVersion": "1.2.30", + "_npmUser": { + "name": "rauchg", + "email": "rauchg@gmail.com" + }, + "maintainers": [ + { + "name": "rauchg", + "email": "rauchg@gmail.com" + } + ], + "directories": {}, + "_shasum": "d89c2124c6fdc1353d65a8b77bf1aac4b193708c", + "_resolved": "https://registry.npmjs.org/ms/-/ms-0.6.2.tgz", + "homepage": "https://github.com/guille/ms.js", + "scripts": {} +} diff --git a/node_modules/express/node_modules/finalhandler/node_modules/debug/package.json b/node_modules/express/node_modules/finalhandler/node_modules/debug/package.json new file mode 100644 index 0000000..551da3b --- /dev/null +++ b/node_modules/express/node_modules/finalhandler/node_modules/debug/package.json @@ -0,0 +1,71 @@ +{ + "name": "debug", + "version": "2.0.0", + "repository": { + "type": "git", + "url": "git://github.com/visionmedia/debug.git" + }, + "description": "small debugging utility", + "keywords": [ + "debug", + "log", + "debugger" + ], + "author": { + "name": "TJ Holowaychuk", + "email": "tj@vision-media.ca" + }, + "contributors": [ + { + "name": "Nathan Rajlich", + "email": "nathan@tootallnate.net", + "url": "http://n8.io" + } + ], + "dependencies": { + "ms": "0.6.2" + }, + "devDependencies": { + "browserify": "5.11.0", + "mocha": "*" + }, + "main": "./node.js", + "browser": "./browser.js", + "component": { + "scripts": { + "debug/index.js": "browser.js", + "debug/debug.js": "debug.js" + } + }, + "gitHead": "c61ae82bde19c6fdedfc6684817ff7eb541ff029", + "bugs": { + "url": "https://github.com/visionmedia/debug/issues" + }, + "homepage": "https://github.com/visionmedia/debug", + "_id": "debug@2.0.0", + "scripts": {}, + "_shasum": "89bd9df6732b51256bc6705342bba02ed12131ef", + "_from": "debug@~2.0.0", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "tootallnate", + "email": "nathan@tootallnate.net" + }, + "maintainers": [ + { + "name": "tjholowaychuk", + "email": "tj@vision-media.ca" + }, + { + "name": "tootallnate", + "email": "nathan@tootallnate.net" + } + ], + "dist": { + "shasum": "89bd9df6732b51256bc6705342bba02ed12131ef", + "tarball": "http://registry.npmjs.org/debug/-/debug-2.0.0.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/debug/-/debug-2.0.0.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/express/node_modules/finalhandler/package.json b/node_modules/express/node_modules/finalhandler/package.json new file mode 100644 index 0000000..cef5a71 --- /dev/null +++ b/node_modules/express/node_modules/finalhandler/package.json @@ -0,0 +1,80 @@ +{ + "name": "finalhandler", + "description": "Node.js final http responder", + "version": "0.2.0", + "author": { + "name": "Douglas Christopher Wilson", + "email": "doug@somethingdoug.com" + }, + "license": "MIT", + "repository": { + "type": "git", + "url": "https://github.com/pillarjs/finalhandler" + }, + "dependencies": { + "debug": "~2.0.0", + "escape-html": "1.0.1" + }, + "devDependencies": { + "istanbul": "0.3.0", + "mocha": "~1.21.4", + "readable-stream": "~1.0.27", + "should": "~4.0.1", + "supertest": "~0.13.0" + }, + "files": [ + "LICENSE", + "HISTORY.md", + "index.js" + ], + "engines": { + "node": ">= 0.8.0" + }, + "scripts": { + "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/" + }, + "gitHead": "0e5d26695b1ab248823366018f09c058a4eaf59b", + "bugs": { + "url": "https://github.com/pillarjs/finalhandler/issues" + }, + "homepage": "https://github.com/pillarjs/finalhandler", + "_id": "finalhandler@0.2.0", + "_shasum": "794082424b17f6a4b2a0eda39f9db6948ee4be8d", + "_from": "finalhandler@0.2.0", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + "maintainers": [ + { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + }, + { + "name": "shtylman", + "email": "shtylman@gmail.com" + }, + { + "name": "tjholowaychuk", + "email": "tj@vision-media.ca" + }, + { + "name": "fishrock123", + "email": "fishrock123@rocketmail.com" + } + ], + "dist": { + "shasum": "794082424b17f6a4b2a0eda39f9db6948ee4be8d", + "tarball": "http://registry.npmjs.org/finalhandler/-/finalhandler-0.2.0.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-0.2.0.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/express/node_modules/fresh/HISTORY.md b/node_modules/express/node_modules/fresh/HISTORY.md new file mode 100644 index 0000000..56361df --- /dev/null +++ b/node_modules/express/node_modules/fresh/HISTORY.md @@ -0,0 +1,24 @@ +0.2.4 / 2014-09-07 +================== + + * Support Node.js 0.6 + +0.2.3 / 2014-09-07 +================== + + * Move repository to jshttp + +0.2.2 / 2014-02-19 +================== + + * Revert "Fix for blank page on Safari reload" + +0.2.1 / 2014-01-29 +================== + + * fix: support max-age=0 for end-to-end revalidation + +0.2.0 / 2013-08-11 +================== + + * fix: return false for no-cache diff --git a/node_modules/express/node_modules/fresh/LICENSE b/node_modules/express/node_modules/fresh/LICENSE new file mode 100644 index 0000000..f527394 --- /dev/null +++ b/node_modules/express/node_modules/fresh/LICENSE @@ -0,0 +1,22 @@ +(The MIT License) + +Copyright (c) 2012 TJ Holowaychuk + +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/node_modules/express/node_modules/fresh/README.md b/node_modules/express/node_modules/fresh/README.md new file mode 100644 index 0000000..54a885f --- /dev/null +++ b/node_modules/express/node_modules/fresh/README.md @@ -0,0 +1,58 @@ +# fresh + +[![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] + +HTTP response freshness testing + +## Installation + +``` +$ npm install fresh +``` + +## API + +```js +var fresh = require('fresh') +``` + +### fresh(req, res) + + Check freshness of `req` and `res` headers. + + When the cache is "fresh" __true__ is returned, + otherwise __false__ is returned to indicate that + the cache is now stale. + +## Example + +```js +var req = { 'if-none-match': 'tobi' }; +var res = { 'etag': 'luna' }; +fresh(req, res); +// => false + +var req = { 'if-none-match': 'tobi' }; +var res = { 'etag': 'tobi' }; +fresh(req, res); +// => true +``` + +## License + +[MIT](LICENSE) + +[npm-image]: https://img.shields.io/npm/v/fresh.svg?style=flat +[npm-url]: https://npmjs.org/package/fresh +[node-version-image]: https://img.shields.io/badge/node.js-%3E%3D_0.6-brightgreen.svg?style=flat +[node-version-url]: http://nodejs.org/download/ +[travis-image]: https://img.shields.io/travis/jshttp/fresh.svg?style=flat +[travis-url]: https://travis-ci.org/jshttp/fresh +[coveralls-image]: https://img.shields.io/coveralls/jshttp/fresh.svg?style=flat +[coveralls-url]: https://coveralls.io/r/jshttp/fresh?branch=master +[downloads-image]: https://img.shields.io/npm/dm/fresh.svg?style=flat +[downloads-url]: https://npmjs.org/package/fresh diff --git a/node_modules/express/node_modules/fresh/index.js b/node_modules/express/node_modules/fresh/index.js new file mode 100644 index 0000000..9c3f47d --- /dev/null +++ b/node_modules/express/node_modules/fresh/index.js @@ -0,0 +1,53 @@ + +/** + * Expose `fresh()`. + */ + +module.exports = fresh; + +/** + * Check freshness of `req` and `res` headers. + * + * When the cache is "fresh" __true__ is returned, + * otherwise __false__ is returned to indicate that + * the cache is now stale. + * + * @param {Object} req + * @param {Object} res + * @return {Boolean} + * @api public + */ + +function fresh(req, res) { + // defaults + var etagMatches = true; + var notModified = true; + + // fields + var modifiedSince = req['if-modified-since']; + var noneMatch = req['if-none-match']; + var lastModified = res['last-modified']; + var etag = res['etag']; + var cc = req['cache-control']; + + // unconditional request + if (!modifiedSince && !noneMatch) return false; + + // check for no-cache cache request directive + if (cc && cc.indexOf('no-cache') !== -1) return false; + + // parse if-none-match + if (noneMatch) noneMatch = noneMatch.split(/ *, */); + + // if-none-match + if (noneMatch) etagMatches = ~noneMatch.indexOf(etag) || '*' == noneMatch[0]; + + // if-modified-since + if (modifiedSince) { + modifiedSince = new Date(modifiedSince); + lastModified = new Date(lastModified); + notModified = lastModified <= modifiedSince; + } + + return !! (etagMatches && notModified); +} \ No newline at end of file diff --git a/node_modules/express/node_modules/fresh/package.json b/node_modules/express/node_modules/fresh/package.json new file mode 100644 index 0000000..a153522 --- /dev/null +++ b/node_modules/express/node_modules/fresh/package.json @@ -0,0 +1,77 @@ +{ + "name": "fresh", + "description": "HTTP response freshness testing", + "version": "0.2.4", + "author": { + "name": "TJ Holowaychuk", + "email": "tj@vision-media.ca", + "url": "http://tjholowaychuk.com" + }, + "license": "MIT", + "keywords": [ + "fresh", + "http", + "conditional", + "cache" + ], + "repository": { + "type": "git", + "url": "https://github.com/jshttp/fresh" + }, + "devDependencies": { + "istanbul": "0", + "mocha": "1", + "should": "3" + }, + "files": [ + "HISTORY.md", + "LICENSE", + "index.js" + ], + "engines": { + "node": ">= 0.6" + }, + "scripts": { + "test": "mocha --reporter spec --require should", + "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --require should", + "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter dot --require should" + }, + "gitHead": "8440a4ca75fb091dec06e88654b3b1c31d7e7164", + "bugs": { + "url": "https://github.com/jshttp/fresh/issues" + }, + "homepage": "https://github.com/jshttp/fresh", + "_id": "fresh@0.2.4", + "_shasum": "3582499206c9723714190edd74b4604feb4a614c", + "_from": "fresh@0.2.4", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + "maintainers": [ + { + "name": "tjholowaychuk", + "email": "tj@vision-media.ca" + }, + { + "name": "jonathanong", + "email": "jonathanrichardong@gmail.com" + }, + { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + } + ], + "dist": { + "shasum": "3582499206c9723714190edd74b4604feb4a614c", + "tarball": "http://registry.npmjs.org/fresh/-/fresh-0.2.4.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/fresh/-/fresh-0.2.4.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/express/node_modules/media-typer/HISTORY.md b/node_modules/express/node_modules/media-typer/HISTORY.md new file mode 100644 index 0000000..62c2003 --- /dev/null +++ b/node_modules/express/node_modules/media-typer/HISTORY.md @@ -0,0 +1,22 @@ +0.3.0 / 2014-09-07 +================== + + * Support Node.js 0.6 + * Throw error when parameter format invalid on parse + +0.2.0 / 2014-06-18 +================== + + * Add `typer.format()` to format media types + +0.1.0 / 2014-06-17 +================== + + * Accept `req` as argument to `parse` + * Accept `res` as argument to `parse` + * Parse media type with extra LWS between type and first parameter + +0.0.0 / 2014-06-13 +================== + + * Initial implementation diff --git a/node_modules/express/node_modules/media-typer/LICENSE b/node_modules/express/node_modules/media-typer/LICENSE new file mode 100644 index 0000000..b7dce6c --- /dev/null +++ b/node_modules/express/node_modules/media-typer/LICENSE @@ -0,0 +1,22 @@ +(The MIT License) + +Copyright (c) 2014 Douglas Christopher Wilson + +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/node_modules/express/node_modules/media-typer/README.md b/node_modules/express/node_modules/media-typer/README.md new file mode 100644 index 0000000..d8df623 --- /dev/null +++ b/node_modules/express/node_modules/media-typer/README.md @@ -0,0 +1,81 @@ +# media-typer + +[![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] + +Simple RFC 6838 media type parser + +## Installation + +```sh +$ npm install media-typer +``` + +## API + +```js +var typer = require('media-typer') +``` + +### typer.parse(string) + +```js +var obj = typer.parse('image/svg+xml; charset=utf-8') +``` + +Parse a media type string. This will return an object with the following +properties (examples are shown for the string `'image/svg+xml; charset=utf-8'`): + + - `type`: The type of the media type (always lower case). Example: `'image'` + + - `subtype`: The subtype of the media type (always lower case). Example: `'svg'` + + - `suffix`: The suffix of the media type (always lower case). Example: `'xml'` + + - `parameters`: An object of the parameters in the media type (name of parameter always lower case). Example: `{charset: 'utf-8'}` + +### typer.parse(req) + +```js +var obj = typer.parse(req) +``` + +Parse the `content-type` header from the given `req`. Short-cut for +`typer.parse(req.headers['content-type'])`. + +### typer.parse(res) + +```js +var obj = typer.parse(res) +``` + +Parse the `content-type` header set on the given `res`. Short-cut for +`typer.parse(res.getHeader('content-type'))`. + +### typer.format(obj) + +```js +var obj = typer.format({type: 'image', subtype: 'svg', suffix: 'xml'}) +``` + +Format an object into a media type string. This will return a string of the +mime type for the given object. For the properties of the object, see the +documentation for `typer.parse(string)`. + +## License + +[MIT](LICENSE) + +[npm-image]: https://img.shields.io/npm/v/media-typer.svg?style=flat +[npm-url]: https://npmjs.org/package/media-typer +[node-version-image]: https://img.shields.io/badge/node.js-%3E%3D_0.6-brightgreen.svg?style=flat +[node-version-url]: http://nodejs.org/download/ +[travis-image]: https://img.shields.io/travis/jshttp/media-typer.svg?style=flat +[travis-url]: https://travis-ci.org/jshttp/media-typer +[coveralls-image]: https://img.shields.io/coveralls/jshttp/media-typer.svg?style=flat +[coveralls-url]: https://coveralls.io/r/jshttp/media-typer +[downloads-image]: https://img.shields.io/npm/dm/media-typer.svg?style=flat +[downloads-url]: https://npmjs.org/package/media-typer diff --git a/node_modules/express/node_modules/media-typer/index.js b/node_modules/express/node_modules/media-typer/index.js new file mode 100644 index 0000000..07f7295 --- /dev/null +++ b/node_modules/express/node_modules/media-typer/index.js @@ -0,0 +1,270 @@ +/*! + * media-typer + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * RegExp to match *( ";" parameter ) in RFC 2616 sec 3.7 + * + * parameter = token "=" ( token | quoted-string ) + * token = 1* + * separators = "(" | ")" | "<" | ">" | "@" + * | "," | ";" | ":" | "\" | <"> + * | "/" | "[" | "]" | "?" | "=" + * | "{" | "}" | SP | HT + * quoted-string = ( <"> *(qdtext | quoted-pair ) <"> ) + * qdtext = > + * quoted-pair = "\" CHAR + * CHAR = + * TEXT = + * LWS = [CRLF] 1*( SP | HT ) + * CRLF = CR LF + * CR = + * LF = + * SP = + * SHT = + * CTL = + * OCTET = + */ +var paramRegExp = /; *([!#$%&'\*\+\-\.0-9A-Z\^_`a-z\|~]+) *= *("(?:[ !\u0023-\u005b\u005d-\u007e\u0080-\u00ff]|\\[\u0020-\u007e])*"|[!#$%&'\*\+\-\.0-9A-Z\^_`a-z\|~]+) */g; +var textRegExp = /^[\u0020-\u007e\u0080-\u00ff]+$/ +var tokenRegExp = /^[!#$%&'\*\+\-\.0-9A-Z\^_`a-z\|~]+$/ + +/** + * RegExp to match quoted-pair in RFC 2616 + * + * quoted-pair = "\" CHAR + * CHAR = + */ +var qescRegExp = /\\([\u0000-\u007f])/g; + +/** + * RegExp to match chars that must be quoted-pair in RFC 2616 + */ +var quoteRegExp = /([\\"])/g; + +/** + * RegExp to match type in RFC 6838 + * + * type-name = restricted-name + * subtype-name = restricted-name + * restricted-name = restricted-name-first *126restricted-name-chars + * restricted-name-first = ALPHA / DIGIT + * restricted-name-chars = ALPHA / DIGIT / "!" / "#" / + * "$" / "&" / "-" / "^" / "_" + * restricted-name-chars =/ "." ; Characters before first dot always + * ; specify a facet name + * restricted-name-chars =/ "+" ; Characters after last plus always + * ; specify a structured syntax suffix + * ALPHA = %x41-5A / %x61-7A ; A-Z / a-z + * DIGIT = %x30-39 ; 0-9 + */ +var subtypeNameRegExp = /^[A-Za-z0-9][A-Za-z0-9!#$&^_.-]{0,126}$/ +var typeNameRegExp = /^[A-Za-z0-9][A-Za-z0-9!#$&^_-]{0,126}$/ +var typeRegExp = /^ *([A-Za-z0-9][A-Za-z0-9!#$&^_-]{0,126})\/([A-Za-z0-9][A-Za-z0-9!#$&^_.+-]{0,126}) *$/; + +/** + * Module exports. + */ + +exports.format = format +exports.parse = parse + +/** + * Format object to media type. + * + * @param {object} obj + * @return {string} + * @api public + */ + +function format(obj) { + if (!obj || typeof obj !== 'object') { + throw new TypeError('argument obj is required') + } + + var parameters = obj.parameters + var subtype = obj.subtype + var suffix = obj.suffix + var type = obj.type + + if (!type || !typeNameRegExp.test(type)) { + throw new TypeError('invalid type') + } + + if (!subtype || !subtypeNameRegExp.test(subtype)) { + throw new TypeError('invalid subtype') + } + + // format as type/subtype + var string = type + '/' + subtype + + // append +suffix + if (suffix) { + if (!typeNameRegExp.test(suffix)) { + throw new TypeError('invalid suffix') + } + + string += '+' + suffix + } + + // append parameters + if (parameters && typeof parameters === 'object') { + var param + var params = Object.keys(parameters).sort() + + for (var i = 0; i < params.length; i++) { + param = params[i] + + if (!tokenRegExp.test(param)) { + throw new TypeError('invalid parameter name') + } + + string += '; ' + param + '=' + qstring(parameters[param]) + } + } + + return string +} + +/** + * Parse media type to object. + * + * @param {string|object} string + * @return {Object} + * @api public + */ + +function parse(string) { + if (!string) { + throw new TypeError('argument string is required') + } + + // support req/res-like objects as argument + if (typeof string === 'object') { + string = getcontenttype(string) + } + + if (typeof string !== 'string') { + throw new TypeError('argument string is required to be a string') + } + + var index = string.indexOf(';') + var type = index !== -1 + ? string.substr(0, index) + : string + + var key + var match + var obj = splitType(type) + var params = {} + var value + + paramRegExp.lastIndex = index + + while (match = paramRegExp.exec(string)) { + if (match.index !== index) { + throw new TypeError('invalid parameter format') + } + + index += match[0].length + key = match[1].toLowerCase() + value = match[2] + + if (value[0] === '"') { + // remove quotes and escapes + value = value + .substr(1, value.length - 2) + .replace(qescRegExp, '$1') + } + + params[key] = value + } + + if (index !== -1 && index !== string.length) { + throw new TypeError('invalid parameter format') + } + + obj.parameters = params + + return obj +} + +/** + * Get content-type from req/res objects. + * + * @param {object} + * @return {Object} + * @api private + */ + +function getcontenttype(obj) { + if (typeof obj.getHeader === 'function') { + // res-like + return obj.getHeader('content-type') + } + + if (typeof obj.headers === 'object') { + // req-like + return obj.headers && obj.headers['content-type'] + } +} + +/** + * Quote a string if necessary. + * + * @param {string} val + * @return {string} + * @api private + */ + +function qstring(val) { + var str = String(val) + + // no need to quote tokens + if (tokenRegExp.test(str)) { + return str + } + + if (str.length > 0 && !textRegExp.test(str)) { + throw new TypeError('invalid parameter value') + } + + return '"' + str.replace(quoteRegExp, '\\$1') + '"' +} + +/** + * Simply "type/subtype+siffx" into parts. + * + * @param {string} string + * @return {Object} + * @api private + */ + +function splitType(string) { + var match = typeRegExp.exec(string.toLowerCase()) + + if (!match) { + throw new TypeError('invalid media type') + } + + var type = match[1] + var subtype = match[2] + var suffix + + // suffix after last + + var index = subtype.lastIndexOf('+') + if (index !== -1) { + suffix = subtype.substr(index + 1) + subtype = subtype.substr(0, index) + } + + var obj = { + type: type, + subtype: subtype, + suffix: suffix + } + + return obj +} diff --git a/node_modules/express/node_modules/media-typer/package.json b/node_modules/express/node_modules/media-typer/package.json new file mode 100644 index 0000000..4bd1a51 --- /dev/null +++ b/node_modules/express/node_modules/media-typer/package.json @@ -0,0 +1,58 @@ +{ + "name": "media-typer", + "description": "Simple RFC 6838 media type parser and formatter", + "version": "0.3.0", + "author": { + "name": "Douglas Christopher Wilson", + "email": "doug@somethingdoug.com" + }, + "license": "MIT", + "repository": { + "type": "git", + "url": "https://github.com/jshttp/media-typer" + }, + "devDependencies": { + "istanbul": "0.3.2", + "mocha": "~1.21.4", + "should": "~4.0.4" + }, + "files": [ + "LICENSE", + "HISTORY.md", + "index.js" + ], + "engines": { + "node": ">= 0.6" + }, + "scripts": { + "test": "mocha --reporter spec --check-leaks --bail 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/" + }, + "gitHead": "d49d41ffd0bb5a0655fa44a59df2ec0bfc835b16", + "bugs": { + "url": "https://github.com/jshttp/media-typer/issues" + }, + "homepage": "https://github.com/jshttp/media-typer", + "_id": "media-typer@0.3.0", + "_shasum": "8710d7af0aa626f8fffa1ce00168545263255748", + "_from": "media-typer@0.3.0", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + "maintainers": [ + { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + } + ], + "dist": { + "shasum": "8710d7af0aa626f8fffa1ce00168545263255748", + "tarball": "http://registry.npmjs.org/media-typer/-/media-typer-0.3.0.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/media-typer/-/media-typer-0.3.0.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/express/node_modules/merge-descriptors/.npmignore b/node_modules/express/node_modules/merge-descriptors/.npmignore new file mode 100644 index 0000000..f62e605 --- /dev/null +++ b/node_modules/express/node_modules/merge-descriptors/.npmignore @@ -0,0 +1,59 @@ +# Compiled source # +################### +*.com +*.class +*.dll +*.exe +*.o +*.so + +# Packages # +############ +# it's better to unpack these files and commit the raw source +# git has its own built in compression methods +*.7z +*.dmg +*.gz +*.iso +*.jar +*.rar +*.tar +*.zip + +# Logs and databases # +###################### +*.log +*.sql +*.sqlite + +# OS generated files # +###################### +.DS_Store* +ehthumbs.db +Icon? +Thumbs.db + +# Node.js # +########### +lib-cov +*.seed +*.log +*.csv +*.dat +*.out +*.pid +*.gz + +pids +logs +results + +node_modules +npm-debug.log + +# Components # +############## + +/build +/components +/vendors \ No newline at end of file diff --git a/node_modules/express/node_modules/merge-descriptors/README.md b/node_modules/express/node_modules/merge-descriptors/README.md new file mode 100644 index 0000000..50cf50c --- /dev/null +++ b/node_modules/express/node_modules/merge-descriptors/README.md @@ -0,0 +1,49 @@ +# Merge Descriptors [![Build Status](https://travis-ci.org/component/merge-descriptors.png)](https://travis-ci.org/component/merge-descriptors) + +Merge objects using descriptors. + +```js +var thing = { + get name() { + return 'jon' + } +} + +var animal = { + +} + +merge(animal, thing) + +animal.name === 'jon' +``` + +## API + +### merge(destination, source) + +Overwrites `destination`'s descriptors with `source`'s. + +## License + +The MIT License (MIT) + +Copyright (c) 2013 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. \ No newline at end of file diff --git a/node_modules/express/node_modules/merge-descriptors/component.json b/node_modules/express/node_modules/merge-descriptors/component.json new file mode 100644 index 0000000..7653906 --- /dev/null +++ b/node_modules/express/node_modules/merge-descriptors/component.json @@ -0,0 +1,10 @@ +{ + "name": "merge-descriptors", + "description": "Merge objects using descriptors", + "version": "0.0.2", + "scripts": [ + "index.js" + ], + "repo": "component/merge-descriptors", + "license": "MIT" +} \ No newline at end of file diff --git a/node_modules/express/node_modules/merge-descriptors/index.js b/node_modules/express/node_modules/merge-descriptors/index.js new file mode 100644 index 0000000..e4e2379 --- /dev/null +++ b/node_modules/express/node_modules/merge-descriptors/index.js @@ -0,0 +1,8 @@ +module.exports = function (dest, src) { + Object.getOwnPropertyNames(src).forEach(function (name) { + var descriptor = Object.getOwnPropertyDescriptor(src, name) + Object.defineProperty(dest, name, descriptor) + }) + + return dest +} \ No newline at end of file diff --git a/node_modules/express/node_modules/merge-descriptors/package.json b/node_modules/express/node_modules/merge-descriptors/package.json new file mode 100644 index 0000000..76673a2 --- /dev/null +++ b/node_modules/express/node_modules/merge-descriptors/package.json @@ -0,0 +1,42 @@ +{ + "name": "merge-descriptors", + "description": "Merge objects using descriptors", + "version": "0.0.2", + "author": { + "name": "Jonathan Ong", + "email": "me@jongleberry.com", + "url": "http://jongleberry.com" + }, + "license": "MIT", + "repository": { + "type": "git", + "url": "https://github.com/component/merge-descriptors.git" + }, + "bugs": { + "url": "https://github.com/component/merge-descriptors/issues" + }, + "scripts": { + "test": "make test;" + }, + "homepage": "https://github.com/component/merge-descriptors", + "_id": "merge-descriptors@0.0.2", + "dist": { + "shasum": "c36a52a781437513c57275f39dd9d317514ac8c7", + "tarball": "http://registry.npmjs.org/merge-descriptors/-/merge-descriptors-0.0.2.tgz" + }, + "_from": "merge-descriptors@0.0.2", + "_npmVersion": "1.3.17", + "_npmUser": { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + }, + "maintainers": [ + { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + } + ], + "directories": {}, + "_shasum": "c36a52a781437513c57275f39dd9d317514ac8c7", + "_resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-0.0.2.tgz" +} diff --git a/node_modules/express/node_modules/methods/.npmignore b/node_modules/express/node_modules/methods/.npmignore new file mode 100644 index 0000000..c2658d7 --- /dev/null +++ b/node_modules/express/node_modules/methods/.npmignore @@ -0,0 +1 @@ +node_modules/ diff --git a/node_modules/express/node_modules/methods/History.md b/node_modules/express/node_modules/methods/History.md new file mode 100644 index 0000000..d3996c2 --- /dev/null +++ b/node_modules/express/node_modules/methods/History.md @@ -0,0 +1,20 @@ + +1.1.0 / 2014-07-05 +================== + + * add CONNECT + +1.0.1 / 2014-06-02 +================== + + * fix index.js to work with harmony transform + +1.0.0 / 2014-05-08 +================== + + * add PURGE. Closes #9 + +0.1.0 / 2013-10-28 +================== + + * add http.METHODS support diff --git a/node_modules/express/node_modules/methods/LICENSE b/node_modules/express/node_modules/methods/LICENSE new file mode 100644 index 0000000..8bce401 --- /dev/null +++ b/node_modules/express/node_modules/methods/LICENSE @@ -0,0 +1,23 @@ +(The MIT License) + +Copyright (c) 2013-2014 TJ Holowaychuk + +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/node_modules/express/node_modules/methods/Readme.md b/node_modules/express/node_modules/methods/Readme.md new file mode 100644 index 0000000..ac0658e --- /dev/null +++ b/node_modules/express/node_modules/methods/Readme.md @@ -0,0 +1,4 @@ + +# Methods + + HTTP verbs that node core's parser supports. diff --git a/node_modules/express/node_modules/methods/index.js b/node_modules/express/node_modules/methods/index.js new file mode 100644 index 0000000..f7e3c48 --- /dev/null +++ b/node_modules/express/node_modules/methods/index.js @@ -0,0 +1,41 @@ + +var http = require('http'); + +if (http.METHODS) { + + module.exports = http.METHODS.map(function(method){ + return method.toLowerCase(); + }); + +} else { + + module.exports = [ + 'get', + 'post', + 'put', + 'head', + 'delete', + 'options', + 'trace', + 'copy', + 'lock', + 'mkcol', + 'move', + 'purge', + 'propfind', + 'proppatch', + 'unlock', + 'report', + 'mkactivity', + 'checkout', + 'merge', + 'm-search', + 'notify', + 'subscribe', + 'unsubscribe', + 'patch', + 'search', + 'connect' + ]; + +} diff --git a/node_modules/express/node_modules/methods/package.json b/node_modules/express/node_modules/methods/package.json new file mode 100644 index 0000000..7d57f1a --- /dev/null +++ b/node_modules/express/node_modules/methods/package.json @@ -0,0 +1,57 @@ +{ + "name": "methods", + "version": "1.1.0", + "description": "HTTP methods that node supports", + "main": "index.js", + "scripts": { + "test": "./node_modules/mocha/bin/mocha" + }, + "keywords": [ + "http", + "methods" + ], + "author": { + "name": "TJ Holowaychuk" + }, + "license": "MIT", + "repository": { + "type": "git", + "url": "git://github.com/visionmedia/node-methods.git" + }, + "devDependencies": { + "mocha": "1.17.x" + }, + "gitHead": "2a4dd325d18436c33356e6be19e32e08a7c877ab", + "bugs": { + "url": "https://github.com/visionmedia/node-methods/issues" + }, + "homepage": "https://github.com/visionmedia/node-methods", + "_id": "methods@1.1.0", + "_shasum": "5dca4ee12df52ff3b056145986a8f01cbc86436f", + "_from": "methods@1.1.0", + "_npmVersion": "1.4.16", + "_npmUser": { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + }, + "maintainers": [ + { + "name": "tjholowaychuk", + "email": "tj@vision-media.ca" + }, + { + "name": "jonathanong", + "email": "jonathanrichardong@gmail.com" + }, + { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + } + ], + "dist": { + "shasum": "5dca4ee12df52ff3b056145986a8f01cbc86436f", + "tarball": "http://registry.npmjs.org/methods/-/methods-1.1.0.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/methods/-/methods-1.1.0.tgz" +} diff --git a/node_modules/express/node_modules/methods/test/methods.js b/node_modules/express/node_modules/methods/test/methods.js new file mode 100644 index 0000000..527beab --- /dev/null +++ b/node_modules/express/node_modules/methods/test/methods.js @@ -0,0 +1,33 @@ +var http = require('http'); +var assert = require('assert'); +var methods = require('..'); + +describe('methods', function() { + + if (http.METHODS) { + + it('is a lowercased http.METHODS', function() { + var lowercased = http.METHODS.map(function(method) { + return method.toLowerCase(); + }); + assert.deepEqual(lowercased, methods); + }); + + } else { + + it('contains GET, POST, PUT, and DELETE', function() { + assert.notEqual(methods.indexOf('get'), -1); + assert.notEqual(methods.indexOf('post'), -1); + assert.notEqual(methods.indexOf('put'), -1); + assert.notEqual(methods.indexOf('delete'), -1); + }); + + it('is all lowercase', function() { + for (var i = 0; i < methods.length; i ++) { + assert(methods[i], methods[i].toLowerCase(), methods[i] + " isn't all lowercase"); + } + }); + + } + +}); diff --git a/node_modules/express/node_modules/on-finished/HISTORY.md b/node_modules/express/node_modules/on-finished/HISTORY.md new file mode 100644 index 0000000..0aa241b --- /dev/null +++ b/node_modules/express/node_modules/on-finished/HISTORY.md @@ -0,0 +1,66 @@ +2.1.0 / 2014-08-16 +================== + + * Check if `socket` is detached + * Return `undefined` for `isFinished` if state unknown + +2.0.0 / 2014-08-16 +================== + + * Add `isFinished` function + * Move to `jshttp` organization + * Remove support for plain socket argument + * Rename to `on-finished` + * Support both `req` and `res` as arguments + * deps: ee-first@1.0.5 + +1.2.2 / 2014-06-10 +================== + + * Reduce listeners added to emitters + - avoids "event emitter leak" warnings when used multiple times on same request + +1.2.1 / 2014-06-08 +================== + + * Fix returned value when already finished + +1.2.0 / 2014-06-05 +================== + + * Call callback when called on already-finished socket + +1.1.4 / 2014-05-27 +================== + + * Support node.js 0.8 + +1.1.3 / 2014-04-30 +================== + + * Make sure errors passed as instanceof `Error` + +1.1.2 / 2014-04-18 +================== + + * Default the `socket` to passed-in object + +1.1.1 / 2014-01-16 +================== + + * Rename module to `finished` + +1.1.0 / 2013-12-25 +================== + + * Call callback when called on already-errored socket + +1.0.1 / 2013-12-20 +================== + + * Actually pass the error to the callback + +1.0.0 / 2013-12-20 +================== + + * Initial release diff --git a/node_modules/express/node_modules/on-finished/LICENSE b/node_modules/express/node_modules/on-finished/LICENSE new file mode 100644 index 0000000..5931fd2 --- /dev/null +++ b/node_modules/express/node_modules/on-finished/LICENSE @@ -0,0 +1,23 @@ +(The MIT License) + +Copyright (c) 2013 Jonathan Ong +Copyright (c) 2014 Douglas Christopher Wilson + +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/node_modules/express/node_modules/on-finished/README.md b/node_modules/express/node_modules/on-finished/README.md new file mode 100644 index 0000000..887b5c3 --- /dev/null +++ b/node_modules/express/node_modules/on-finished/README.md @@ -0,0 +1,90 @@ +# on-finished + +[![NPM Version](http://img.shields.io/npm/v/on-finished.svg?style=flat)](https://www.npmjs.org/package/on-finished) +[![Node.js Version](http://img.shields.io/badge/node.js->=_0.8-brightgreen.svg?style=flat)](http://nodejs.org/download/) +[![Build Status](http://img.shields.io/travis/jshttp/on-finished.svg?style=flat)](https://travis-ci.org/jshttp/on-finished) +[![Coverage Status](https://img.shields.io/coveralls/jshttp/on-finished.svg?style=flat)](https://coveralls.io/r/jshttp/on-finished) + +Execute a callback when a request closes, finishes, or errors. + +## Install + +```sh +$ npm install on-finished +``` + +## API + +```js +var onFinished = require('on-finished') +``` + +### onFinished(res, listener) + +Attach a listener to listen for the response to finish. The listener will +be invoked only once when the response finished. If the response finished +to to an error, the first argument will contain the error. + +Listening to the end of a response would be used to close things associated +with the response, like open files. + +```js +onFinished(res, function (err) { + // clean up open fds, etc. +}) +``` + +### onFinished(req, listener) + +Attach a listener to listen for the request to finish. The listener will +be invoked only once when the request finished. If the request finished +to to an error, the first argument will contain the error. + +Listening to the end of a request would be used to know when to continue +after reading the data. + +```js +var data = '' + +req.setEncoding('utf8') +res.on('data', function (str) { + data += str +}) + +onFinished(req, function (err) { + // data is read unless there is err +}) +``` + +### onFinished.isFinished(res) + +Determine if `res` is already finished. This would be useful to check and +not even start certain operations if the response has already finished. + +### onFinished.isFinished(req) + +Determine if `req` is already finished. This would be useful to check and +not even start certain operations if the request has already finished. + +### Example + +The following code ensures that file descriptors are always closed +once the response finishes. + +```js +var destroy = require('destroy') +var http = require('http') +var onFinished = require('finished') + +http.createServer(function onRequest(req, res) { + var stream = fs.createReadStream('package.json') + stream.pipe(res) + onFinished(res, function (err) { + destroy(stream) + }) +}) +``` + +## License + +[MIT](LICENSE) diff --git a/node_modules/express/node_modules/on-finished/index.js b/node_modules/express/node_modules/on-finished/index.js new file mode 100644 index 0000000..a505561 --- /dev/null +++ b/node_modules/express/node_modules/on-finished/index.js @@ -0,0 +1,127 @@ +/*! + * on-finished + * Copyright(c) 2013 Jonathan Ong + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module exports. + */ + +module.exports = onFinished; +module.exports.isFinished = isFinished; + +/** +* Module dependencies. +*/ + +var first = require('ee-first') + +/** +* Variables. +*/ + +/* istanbul ignore next */ +var defer = typeof setImmediate === 'function' + ? setImmediate + : function(fn){ process.nextTick(fn.bind.apply(fn, arguments)) } + +/** + * Invoke callback when the response has finished, useful for + * cleaning up resources afterwards. + * + * @param {object} msg + * @param {function} listener + * @return {object} + * @api public + */ + +function onFinished(msg, listener) { + if (isFinished(msg) !== false) { + defer(listener) + return msg + } + + // attach the listener to the message + attachListener(msg, listener) + + return msg +} + +/** + * Determine is message is already finished. + * + * @param {object} msg + * @return {boolean} + * @api public + */ + +function isFinished(msg) { + var socket = msg.socket + + if (typeof msg.finished === 'boolean') { + // OutgoingMessage + return Boolean(!socket || msg.finished || !socket.writable) + } + + if (typeof msg.complete === 'boolean') { + // IncomingMessage + return Boolean(!socket || msg.complete || !socket.readable) + } + + // don't know + return undefined +} + +/** + * Attach the listener to the message. + * + * @param {object} msg + * @return {function} + * @api private + */ + +function attachListener(msg, listener) { + var attached = msg.__onFinished + var socket = msg.socket + + // create a private single listener with queue + if (!attached || !attached.queue) { + attached = msg.__onFinished = createListener(msg) + + // finished on first event + first([ + [socket, 'error', 'close'], + [msg, 'end', 'finish'], + ], attached) + } + + attached.queue.push(listener) +} + +/** + * Create listener on message. + * + * @param {object} msg + * @return {function} + * @api private + */ + +function createListener(msg) { + function listener(err) { + if (msg.__onFinished === listener) msg.__onFinished = null + if (!listener.queue) return + + var queue = listener.queue + listener.queue = null + + for (var i = 0; i < queue.length; i++) { + queue[i](err) + } + } + + listener.queue = [] + + return listener +} diff --git a/node_modules/express/node_modules/on-finished/node_modules/ee-first/LICENSE b/node_modules/express/node_modules/on-finished/node_modules/ee-first/LICENSE new file mode 100644 index 0000000..a7ae8ee --- /dev/null +++ b/node_modules/express/node_modules/on-finished/node_modules/ee-first/LICENSE @@ -0,0 +1,22 @@ + +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/node_modules/express/node_modules/on-finished/node_modules/ee-first/README.md b/node_modules/express/node_modules/on-finished/node_modules/ee-first/README.md new file mode 100644 index 0000000..0ebc0aa --- /dev/null +++ b/node_modules/express/node_modules/on-finished/node_modules/ee-first/README.md @@ -0,0 +1,63 @@ +# EE First + +[![NPM version][npm-image]][npm-url] +[![Build status][travis-image]][travis-url] +[![Test coverage][coveralls-image]][coveralls-url] +[![License][license-image]][license-url] +[![Downloads][downloads-image]][downloads-url] +[![Gittip][gittip-image]][gittip-url] + +Get the first event in a set of event emitters and event pairs, +then clean up after itself. + +## Install + +```sh +$ npm install ee-first +``` + +## API + +```js +var first = require('ee-first') +``` + +### first(arr, listener) + +Invoke `listener` on the first event from the list specified in `arr`. `arr` is +an array of arrays, with each array in the format `[ee, ...event]`. `listener` +will be called only once, the first time any of the given events are emitted. If +`error` is one of the listened events, then if that fires first, the `listener` +will be given the `err` argument. + +The `listener` is invoked as `listener(err, ee, event, args)`, where `err` is the +first argument emitted from an `error` event, if applicable; `ee` is the event +emitter that fired; `event` is the string event name that fired; and `args` is an +array of the arguments that were emitted on the event. + +```js +var ee1 = new EventEmitter() +var ee2 = new EventEmitter() + +first([ + [ee1, 'close', 'end', 'error'], + [ee2, 'error'] +], function (err, ee, event, args) { + // listener invoked +}) +``` + +[npm-image]: https://img.shields.io/npm/v/ee-first.svg?style=flat-square +[npm-url]: https://npmjs.org/package/ee-first +[github-tag]: http://img.shields.io/github/tag/jonathanong/ee-first.svg?style=flat-square +[github-url]: https://github.com/jonathanong/ee-first/tags +[travis-image]: https://img.shields.io/travis/jonathanong/ee-first.svg?style=flat-square +[travis-url]: https://travis-ci.org/jonathanong/ee-first +[coveralls-image]: https://img.shields.io/coveralls/jonathanong/ee-first.svg?style=flat-square +[coveralls-url]: https://coveralls.io/r/jonathanong/ee-first?branch=master +[license-image]: http://img.shields.io/npm/l/ee-first.svg?style=flat-square +[license-url]: LICENSE.md +[downloads-image]: http://img.shields.io/npm/dm/ee-first.svg?style=flat-square +[downloads-url]: https://npmjs.org/package/ee-first +[gittip-image]: https://img.shields.io/gittip/jonathanong.svg?style=flat-square +[gittip-url]: https://www.gittip.com/jonathanong/ diff --git a/node_modules/express/node_modules/on-finished/node_modules/ee-first/index.js b/node_modules/express/node_modules/on-finished/node_modules/ee-first/index.js new file mode 100644 index 0000000..d0c48c9 --- /dev/null +++ b/node_modules/express/node_modules/on-finished/node_modules/ee-first/index.js @@ -0,0 +1,60 @@ + +module.exports = function first(stuff, done) { + if (!Array.isArray(stuff)) + throw new TypeError('arg must be an array of [ee, events...] arrays') + + var cleanups = [] + + for (var i = 0; i < stuff.length; i++) { + var arr = stuff[i] + + if (!Array.isArray(arr) || arr.length < 2) + throw new TypeError('each array member must be [ee, events...]') + + var ee = arr[0] + + for (var j = 1; j < arr.length; j++) { + var event = arr[j] + var fn = listener(event, cleanup) + + // listen to the event + ee.on(event, fn) + // push this listener to the list of cleanups + cleanups.push({ + ee: ee, + event: event, + fn: fn, + }) + } + } + + return function (fn) { + done = fn + } + + function cleanup() { + var x + for (var i = 0; i < cleanups.length; i++) { + x = cleanups[i] + x.ee.removeListener(x.event, x.fn) + } + done.apply(null, arguments) + } +} + +function listener(event, done) { + return function onevent(arg1) { + var args = new Array(arguments.length) + var ee = this + var err = event === 'error' + ? arg1 + : null + + // copy args to prevent arguments escaping scope + for (var i = 0; i < args.length; i++) { + args[i] = arguments[i] + } + + done(err, ee, event, args) + } +} diff --git a/node_modules/express/node_modules/on-finished/node_modules/ee-first/package.json b/node_modules/express/node_modules/on-finished/node_modules/ee-first/package.json new file mode 100644 index 0000000..54d04e1 --- /dev/null +++ b/node_modules/express/node_modules/on-finished/node_modules/ee-first/package.json @@ -0,0 +1,64 @@ +{ + "name": "ee-first", + "description": "return the first event in a set of ee/event pairs", + "version": "1.0.5", + "author": { + "name": "Jonathan Ong", + "email": "me@jongleberry.com", + "url": "http://jongleberry.com" + }, + "contributors": [ + { + "name": "Douglas Christopher Wilson", + "email": "doug@somethingdoug.com" + } + ], + "license": "MIT", + "repository": { + "type": "git", + "url": "https://github.com/jonathanong/ee-first" + }, + "devDependencies": { + "istanbul": "0.3.0", + "mocha": "1" + }, + "files": [ + "index.js", + "LICENSE" + ], + "scripts": { + "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/" + }, + "gitHead": "c9d9a6881863c0d2fcc2e4ac99a170088c205304", + "bugs": { + "url": "https://github.com/jonathanong/ee-first/issues" + }, + "homepage": "https://github.com/jonathanong/ee-first", + "_id": "ee-first@1.0.5", + "_shasum": "8c9b212898d8cd9f1a9436650ce7be202c9e9ff0", + "_from": "ee-first@1.0.5", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + "maintainers": [ + { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + }, + { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + } + ], + "dist": { + "shasum": "8c9b212898d8cd9f1a9436650ce7be202c9e9ff0", + "tarball": "http://registry.npmjs.org/ee-first/-/ee-first-1.0.5.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/ee-first/-/ee-first-1.0.5.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/express/node_modules/on-finished/package.json b/node_modules/express/node_modules/on-finished/package.json new file mode 100644 index 0000000..374a921 --- /dev/null +++ b/node_modules/express/node_modules/on-finished/package.json @@ -0,0 +1,71 @@ +{ + "name": "on-finished", + "description": "Execute a callback when a request closes, finishes, or errors", + "version": "2.1.0", + "contributors": [ + { + "name": "Douglas Christopher Wilson", + "email": "doug@somethingdoug.com" + }, + { + "name": "Jonathan Ong", + "email": "me@jongleberry.com", + "url": "http://jongleberry.com" + } + ], + "license": "MIT", + "repository": { + "type": "git", + "url": "https://github.com/jshttp/on-finished" + }, + "dependencies": { + "ee-first": "1.0.5" + }, + "devDependencies": { + "istanbul": "0.3.0", + "mocha": "~1.21.4" + }, + "engine": { + "node": ">= 0.8.0" + }, + "files": [ + "HISTORY.md", + "LICENSE", + "index.js" + ], + "scripts": { + "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/" + }, + "gitHead": "1ad808e704e2aeda3a7464b78cacead2fb453727", + "bugs": { + "url": "https://github.com/jshttp/on-finished/issues" + }, + "homepage": "https://github.com/jshttp/on-finished", + "_id": "on-finished@2.1.0", + "_shasum": "0c539f09291e8ffadde0c8a25850fb2cedc7022d", + "_from": "on-finished@~2.1.0", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + "maintainers": [ + { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + } + ], + "dist": { + "shasum": "0c539f09291e8ffadde0c8a25850fb2cedc7022d", + "tarball": "http://registry.npmjs.org/on-finished/-/on-finished-2.1.0.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/on-finished/-/on-finished-2.1.0.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/express/node_modules/parseurl/.npmignore b/node_modules/express/node_modules/parseurl/.npmignore new file mode 100644 index 0000000..85c82a5 --- /dev/null +++ b/node_modules/express/node_modules/parseurl/.npmignore @@ -0,0 +1,4 @@ +benchmark/ +coverage/ +test/ +.travis.yml diff --git a/node_modules/express/node_modules/parseurl/HISTORY.md b/node_modules/express/node_modules/parseurl/HISTORY.md new file mode 100644 index 0000000..65a0860 --- /dev/null +++ b/node_modules/express/node_modules/parseurl/HISTORY.md @@ -0,0 +1,42 @@ +1.3.0 / 2014-08-09 +================== + + * Add `parseurl.original` for parsing `req.originalUrl` with fallback + * Return `undefined` if `req.url` is `undefined` + +1.2.0 / 2014-07-21 +================== + + * Cache URLs based on original value + * Remove no-longer-needed URL mis-parse work-around + * Simplify the "fast-path" `RegExp` + +1.1.3 / 2014-07-08 +================== + + * Fix typo + +1.1.2 / 2014-07-08 +================== + + * Seriously fix Node.js 0.8 compatibility + +1.1.1 / 2014-07-08 +================== + + * Fix Node.js 0.8 compatibility + +1.1.0 / 2014-07-08 +================== + + * Incorporate URL href-only parse fast-path + +1.0.1 / 2014-03-08 +================== + + * Add missing `require` + +1.0.0 / 2014-03-08 +================== + + * Genesis from `connect` diff --git a/node_modules/express/node_modules/parseurl/LICENSE b/node_modules/express/node_modules/parseurl/LICENSE new file mode 100644 index 0000000..ec7dfe7 --- /dev/null +++ b/node_modules/express/node_modules/parseurl/LICENSE @@ -0,0 +1,24 @@ + +(The MIT License) + +Copyright (c) 2014 Jonathan Ong +Copyright (c) 2014 Douglas Christopher Wilson + +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/node_modules/express/node_modules/parseurl/README.md b/node_modules/express/node_modules/parseurl/README.md new file mode 100644 index 0000000..0db1d02 --- /dev/null +++ b/node_modules/express/node_modules/parseurl/README.md @@ -0,0 +1,107 @@ +# parseurl + +[![NPM version](https://badge.fury.io/js/parseurl.svg)](http://badge.fury.io/js/parseurl) +[![Build Status](https://travis-ci.org/expressjs/parseurl.svg?branch=master)](https://travis-ci.org/expressjs/parseurl) +[![Coverage Status](https://img.shields.io/coveralls/expressjs/parseurl.svg?branch=master)](https://coveralls.io/r/expressjs/parseurl) + +Parse a URL with memoization. + +## Install + +```bash +$ npm install parseurl +``` + +## API + +```js +var parseurl = require('parseurl') +``` + +### parseurl(req) + +Parse the URL of the given request object (looks at the `req.url` property) +and return the result. The result is the same as `url.parse` in Node.js core. +Calling this function multiple times on the same `req` where `req.url` does +not change will return a cached parsed object, rather than parsing again. + +### parseurl.original(req) + +Parse the original URL of the given request object and return the result. +This works by trying to parse `req.originalUrl` if it is a string, otherwise +parses `req.url`. The result is the same as `url.parse` in Node.js core. +Calling this function multiple times on the same `req` where `req.originalUrl` +does not change will return a cached parsed object, rather than parsing again. + +## Benchmark + +```bash +$ npm run-script bench + +> parseurl@1.3.0 bench nodejs-parseurl +> node benchmark/index.js + +> node benchmark/fullurl.js + + Parsing URL "http://localhost:8888/foo/bar?user=tj&pet=fluffy" + + 1 test completed. + 2 tests completed. + 3 tests completed. + + fasturl x 1,290,780 ops/sec ±0.46% (195 runs sampled) + nativeurl x 56,401 ops/sec ±0.22% (196 runs sampled) + parseurl x 55,231 ops/sec ±0.22% (194 runs sampled) + +> node benchmark/pathquery.js + + Parsing URL "/foo/bar?user=tj&pet=fluffy" + + 1 test completed. + 2 tests completed. + 3 tests completed. + + fasturl x 1,986,668 ops/sec ±0.27% (190 runs sampled) + nativeurl x 98,740 ops/sec ±0.21% (195 runs sampled) + parseurl x 2,628,171 ops/sec ±0.36% (195 runs sampled) + +> node benchmark/samerequest.js + + Parsing URL "/foo/bar?user=tj&pet=fluffy" on same request object + + 1 test completed. + 2 tests completed. + 3 tests completed. + + fasturl x 2,184,468 ops/sec ±0.40% (194 runs sampled) + nativeurl x 99,437 ops/sec ±0.71% (194 runs sampled) + parseurl x 10,498,005 ops/sec ±0.61% (186 runs sampled) + +> node benchmark/simplepath.js + + Parsing URL "/foo/bar" + + 1 test completed. + 2 tests completed. + 3 tests completed. + + fasturl x 4,535,825 ops/sec ±0.27% (191 runs sampled) + nativeurl x 98,769 ops/sec ±0.54% (191 runs sampled) + parseurl x 4,164,865 ops/sec ±0.34% (192 runs sampled) + +> node benchmark/slash.js + + Parsing URL "/" + + 1 test completed. + 2 tests completed. + 3 tests completed. + + fasturl x 4,908,405 ops/sec ±0.42% (191 runs sampled) + nativeurl x 100,945 ops/sec ±0.59% (188 runs sampled) + parseurl x 4,333,208 ops/sec ±0.27% (194 runs sampled) +``` + +## License + + [MIT](LICENSE) diff --git a/node_modules/express/node_modules/parseurl/index.js b/node_modules/express/node_modules/parseurl/index.js new file mode 100644 index 0000000..8632347 --- /dev/null +++ b/node_modules/express/node_modules/parseurl/index.js @@ -0,0 +1,136 @@ +/*! + * parseurl + * Copyright(c) 2014 Jonathan Ong + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module dependencies. + */ + +var url = require('url') +var parse = url.parse +var Url = url.Url + +/** + * Pattern for a simple path case. + * See: https://github.com/joyent/node/pull/7878 + */ + +var simplePathRegExp = /^(\/\/?(?!\/)[^\?#\s]*)(\?[^#\s]*)?$/ + +/** + * Exports. + */ + +module.exports = parseurl +module.exports.original = originalurl + +/** + * Parse the `req` url with memoization. + * + * @param {ServerRequest} req + * @return {Object} + * @api public + */ + +function parseurl(req) { + var url = req.url + + if (url === undefined) { + // URL is undefined + return undefined + } + + var parsed = req._parsedUrl + + if (fresh(url, parsed)) { + // Return cached URL parse + return parsed + } + + // Parse the URL + parsed = fastparse(url) + parsed._raw = url + + return req._parsedUrl = parsed +}; + +/** + * Parse the `req` original url with fallback and memoization. + * + * @param {ServerRequest} req + * @return {Object} + * @api public + */ + +function originalurl(req) { + var url = req.originalUrl + + if (typeof url !== 'string') { + // Fallback + return parseurl(req) + } + + var parsed = req._parsedOriginalUrl + + if (fresh(url, parsed)) { + // Return cached URL parse + return parsed + } + + // Parse the URL + parsed = fastparse(url) + parsed._raw = url + + return req._parsedOriginalUrl = parsed +}; + +/** + * Parse the `str` url with fast-path short-cut. + * + * @param {string} str + * @return {Object} + * @api private + */ + +function fastparse(str) { + // Try fast path regexp + // See: https://github.com/joyent/node/pull/7878 + var simplePath = typeof str === 'string' && simplePathRegExp.exec(str) + + // Construct simple URL + if (simplePath) { + var pathname = simplePath[1] + var search = simplePath[2] || null + var url = Url !== undefined + ? new Url() + : {} + url.path = str + url.href = str + url.pathname = pathname + url.search = search + url.query = search && search.substr(1) + + return url + } + + return parse(str) +} + +/** + * Determine if parsed is still fresh for url. + * + * @param {string} url + * @param {object} parsedUrl + * @return {boolean} + * @api private + */ + +function fresh(url, parsedUrl) { + return typeof parsedUrl === 'object' + && parsedUrl !== null + && (Url === undefined || parsedUrl instanceof Url) + && parsedUrl._raw === url +} diff --git a/node_modules/express/node_modules/parseurl/package.json b/node_modules/express/node_modules/parseurl/package.json new file mode 100644 index 0000000..6fbd23e --- /dev/null +++ b/node_modules/express/node_modules/parseurl/package.json @@ -0,0 +1,80 @@ +{ + "name": "parseurl", + "description": "parse a url with memoization", + "version": "1.3.0", + "author": { + "name": "Jonathan Ong", + "email": "me@jongleberry.com", + "url": "http://jongleberry.com" + }, + "contributors": [ + { + "name": "Douglas Christopher Wilson", + "email": "doug@somethingdoug.com" + } + ], + "repository": { + "type": "git", + "url": "https://github.com/expressjs/parseurl" + }, + "license": "MIT", + "devDependencies": { + "benchmark": "1.0.0", + "beautify-benchmark": "0.2.4", + "fast-url-parser": "~1.0.0", + "istanbul": "0.3.0", + "mocha": "~1.21.4" + }, + "scripts": { + "bench": "node benchmark/index.js", + "test": "mocha --check-leaks --bail --reporter spec test/", + "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --check-leaks --reporter dot test/", + "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --check-leaks --reporter spec test/" + }, + "gitHead": "03b7ccca240e2bef5df6c25797e99175d28fb2cb", + "bugs": { + "url": "https://github.com/expressjs/parseurl/issues" + }, + "homepage": "https://github.com/expressjs/parseurl", + "_id": "parseurl@1.3.0", + "_shasum": "b58046db4223e145afa76009e61bac87cc2281b3", + "_from": "parseurl@~1.3.0", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + "maintainers": [ + { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + }, + { + "name": "shtylman", + "email": "shtylman@gmail.com" + }, + { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + { + "name": "tjholowaychuk", + "email": "tj@vision-media.ca" + }, + { + "name": "mscdex", + "email": "mscdex@mscdex.net" + }, + { + "name": "fishrock123", + "email": "fishrock123@rocketmail.com" + } + ], + "dist": { + "shasum": "b58046db4223e145afa76009e61bac87cc2281b3", + "tarball": "http://registry.npmjs.org/parseurl/-/parseurl-1.3.0.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/parseurl/-/parseurl-1.3.0.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/express/node_modules/path-to-regexp/.npmignore b/node_modules/express/node_modules/path-to-regexp/.npmignore new file mode 100644 index 0000000..ba2a97b --- /dev/null +++ b/node_modules/express/node_modules/path-to-regexp/.npmignore @@ -0,0 +1,2 @@ +node_modules +coverage diff --git a/node_modules/express/node_modules/path-to-regexp/History.md b/node_modules/express/node_modules/path-to-regexp/History.md new file mode 100644 index 0000000..f962cfa --- /dev/null +++ b/node_modules/express/node_modules/path-to-regexp/History.md @@ -0,0 +1,16 @@ +0.1.3 / 2014-07-06 +================== + + * Better array support + * Improved support for trailing slash in non-ending mode + +0.1.0 / 2014-03-06 +================== + + * add options.end + +0.0.2 / 2013-02-10 +================== + + * Update to match current express + * add .license property to component.json diff --git a/node_modules/express/node_modules/path-to-regexp/Readme.md b/node_modules/express/node_modules/path-to-regexp/Readme.md new file mode 100644 index 0000000..9199e38 --- /dev/null +++ b/node_modules/express/node_modules/path-to-regexp/Readme.md @@ -0,0 +1,33 @@ + +# Path-to-RegExp + + Turn an Express-style path string such as `/user/:name` into a regular expression. + +## Usage + +```javascript +var pathToRegexp = require('path-to-regexp'); +``` +### pathToRegexp(path, keys, options) + + - **path** A string in the express format, an array of such strings, or a regular expression + - **keys** An array to be populated with the keys present in the url. Once the function completes, this will be an array of strings. + - **options** + - **options.sensitive** Defaults to false, set this to true to make routes case sensitive + - **options.strict** Defaults to false, set this to true to make the trailing slash matter. + - **options.end** Defaults to true, set this to false to only match the prefix of the URL. + +```javascript +var keys = []; +var exp = pathToRegexp('/foo/:bar', keys); +//keys = ['bar'] +//exp = /^\/foo\/(?:([^\/]+?))\/?$/i +``` + +## Live Demo + +You can see a live demo of this library in use at [express-route-tester](http://forbeslindesay.github.com/express-route-tester/). + +## License + + MIT \ No newline at end of file diff --git a/node_modules/express/node_modules/path-to-regexp/component.json b/node_modules/express/node_modules/path-to-regexp/component.json new file mode 100644 index 0000000..6ab37d3 --- /dev/null +++ b/node_modules/express/node_modules/path-to-regexp/component.json @@ -0,0 +1,15 @@ +{ + "name": "path-to-regexp", + "description": "Express style path to RegExp utility", + "version": "0.1.3", + "keywords": [ + "express", + "regexp", + "route", + "routing" + ], + "scripts": [ + "index.js" + ], + "license": "MIT" +} diff --git a/node_modules/express/node_modules/path-to-regexp/index.js b/node_modules/express/node_modules/path-to-regexp/index.js new file mode 100644 index 0000000..2801f91 --- /dev/null +++ b/node_modules/express/node_modules/path-to-regexp/index.js @@ -0,0 +1,70 @@ +/** + * Expose `pathtoRegexp`. + */ + +module.exports = pathtoRegexp; + +/** + * Normalize the given path string, + * returning a regular expression. + * + * An empty array should be passed, + * which will contain the placeholder + * key names. For example "/user/:id" will + * then contain ["id"]. + * + * @param {String|RegExp|Array} path + * @param {Array} keys + * @param {Object} options + * @return {RegExp} + * @api private + */ + +function pathtoRegexp(path, keys, options) { + options = options || {}; + var strict = options.strict; + var end = options.end !== false; + var flags = options.sensitive ? '' : 'i'; + keys = keys || []; + + if (path instanceof RegExp) { + return path; + } + + if (Array.isArray(path)) { + // Map array parts into regexps and return their source. We also pass + // the same keys and options instance into every generation to get + // consistent matching groups before we join the sources together. + path = path.map(function (value) { + return pathtoRegexp(value, keys, options).source; + }); + + return new RegExp('(?:' + path.join('|') + ')', flags); + } + + path = ('^' + path + (strict ? '' : path[path.length - 1] === '/' ? '?' : '/?')) + .replace(/\/\(/g, '/(?:') + .replace(/([\/\.])/g, '\\$1') + .replace(/(\\\/)?(\\\.)?:(\w+)(\(.*?\))?(\*)?(\?)?/g, function (match, slash, format, key, capture, star, optional) { + slash = slash || ''; + format = format || ''; + capture = capture || '([^\\/' + format + ']+?)'; + optional = optional || ''; + + keys.push({ name: key, optional: !!optional }); + + return '' + + (optional ? '' : slash) + + '(?:' + + format + (optional ? slash : '') + capture + + (star ? '((?:[\\/' + format + '].+?)?)' : '') + + ')' + + optional; + }) + .replace(/\*/g, '(.*)'); + + // If the path is non-ending, match until the end or a slash. + path += (end ? '$' : (path[path.length - 1] === '/' ? '' : '(?=\\/|$)')); + + return new RegExp(path, flags); +}; diff --git a/node_modules/express/node_modules/path-to-regexp/package.json b/node_modules/express/node_modules/path-to-regexp/package.json new file mode 100644 index 0000000..bccfe25 --- /dev/null +++ b/node_modules/express/node_modules/path-to-regexp/package.json @@ -0,0 +1,162 @@ +{ + "name": "path-to-regexp", + "description": "Express style path to RegExp utility", + "version": "0.1.3", + "scripts": { + "test": "istanbul cover _mocha -- -R spec" + }, + "keywords": [ + "express", + "regexp" + ], + "component": { + "scripts": { + "path-to-regexp": "index.js" + } + }, + "repository": { + "type": "git", + "url": "https://github.com/component/path-to-regexp.git" + }, + "devDependencies": { + "mocha": "^1.17.1", + "istanbul": "^0.2.6" + }, + "bugs": { + "url": "https://github.com/component/path-to-regexp/issues" + }, + "homepage": "https://github.com/component/path-to-regexp", + "_id": "path-to-regexp@0.1.3", + "_shasum": "21b9ab82274279de25b156ea08fd12ca51b8aecb", + "_from": "path-to-regexp@0.1.3", + "_npmVersion": "1.4.9", + "_npmUser": { + "name": "blakeembrey", + "email": "hello@blakeembrey.com" + }, + "maintainers": [ + { + "name": "tjholowaychuk", + "email": "tj@vision-media.ca" + }, + { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + }, + { + "name": "dominicbarnes", + "email": "dominic@dbarnes.info" + }, + { + "name": "tootallnate", + "email": "nathan@tootallnate.net" + }, + { + "name": "rauchg", + "email": "rauchg@gmail.com" + }, + { + "name": "retrofox", + "email": "rdsuarez@gmail.com" + }, + { + "name": "coreh", + "email": "thecoreh@gmail.com" + }, + { + "name": "forbeslindesay", + "email": "forbes@lindesay.co.uk" + }, + { + "name": "kelonye", + "email": "kelonyemitchel@gmail.com" + }, + { + "name": "mattmueller", + "email": "mattmuelle@gmail.com" + }, + { + "name": "yields", + "email": "yields@icloud.com" + }, + { + "name": "anthonyshort", + "email": "antshort@gmail.com" + }, + { + "name": "ianstormtaylor", + "email": "ian@ianstormtaylor.com" + }, + { + "name": "cristiandouce", + "email": "cristian@gravityonmars.com" + }, + { + "name": "swatinem", + "email": "arpad.borsos@googlemail.com" + }, + { + "name": "stagas", + "email": "gstagas@gmail.com" + }, + { + "name": "amasad", + "email": "amjad.masad@gmail.com" + }, + { + "name": "juliangruber", + "email": "julian@juliangruber.com" + }, + { + "name": "shtylman", + "email": "shtylman@gmail.com" + }, + { + "name": "calvinfo", + "email": "calvin@calv.info" + }, + { + "name": "blakeembrey", + "email": "hello@blakeembrey.com" + }, + { + "name": "timoxley", + "email": "secoif@gmail.com" + }, + { + "name": "jonathanong", + "email": "jonathanrichardong@gmail.com" + }, + { + "name": "queckezz", + "email": "fabian.eichenberger@gmail.com" + }, + { + "name": "nami-doc", + "email": "vendethiel@hotmail.fr" + }, + { + "name": "clintwood", + "email": "clint@anotherway.co.za" + }, + { + "name": "thehydroimpulse", + "email": "dnfagnan@gmail.com" + }, + { + "name": "stephenmathieson", + "email": "me@stephenmathieson.com" + }, + { + "name": "trevorgerhardt", + "email": "trevorgerhardt@gmail.com" + } + ], + "dist": { + "shasum": "21b9ab82274279de25b156ea08fd12ca51b8aecb", + "tarball": "http://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.3.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.3.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/express/node_modules/path-to-regexp/test.js b/node_modules/express/node_modules/path-to-regexp/test.js new file mode 100644 index 0000000..4a0c270 --- /dev/null +++ b/node_modules/express/node_modules/path-to-regexp/test.js @@ -0,0 +1,616 @@ +var pathToRegExp = require('./'); +var assert = require('assert'); + +describe('path-to-regexp', function () { + describe('strings', function () { + it('should match simple paths', function () { + var params = []; + var m = pathToRegExp('/test', params).exec('/test'); + + assert.equal(params.length, 0); + + assert.equal(m.length, 1); + assert.equal(m[0], '/test'); + }); + + it('should match express format params', function () { + var params = []; + var m = pathToRegExp('/:test', params).exec('/pathname'); + + assert.equal(params.length, 1); + assert.equal(params[0].name, 'test'); + assert.equal(params[0].optional, false); + + assert.equal(m.length, 2); + assert.equal(m[0], '/pathname'); + assert.equal(m[1], 'pathname'); + }); + + it('should do strict matches', function () { + var params = []; + var re = pathToRegExp('/:test', params, { strict: true }); + var m; + + assert.equal(params.length, 1); + assert.equal(params[0].name, 'test'); + assert.equal(params[0].optional, false); + + m = re.exec('/route'); + + assert.equal(m.length, 2); + assert.equal(m[0], '/route'); + assert.equal(m[1], 'route'); + + m = re.exec('/route/'); + + assert.ok(!m); + }); + + it('should do strict matches with trailing slashes', function () { + var params = []; + var re = pathToRegExp('/:test/', params, { strict: true }); + var m; + + assert.equal(params.length, 1); + assert.equal(params[0].name, 'test'); + assert.equal(params[0].optional, false); + + m = re.exec('/route'); + + assert.ok(!m); + + m = re.exec('/route/'); + + assert.equal(m.length, 2); + assert.equal(m[0], '/route/'); + assert.equal(m[1], 'route'); + + m = re.exec('/route//'); + + assert.ok(!m); + }); + + it('should allow optional express format params', function () { + var params = []; + var re = pathToRegExp('/:test?', params); + var m; + + assert.equal(params.length, 1); + assert.equal(params[0].name, 'test'); + assert.equal(params[0].optional, true); + + m = re.exec('/route'); + + assert.equal(m.length, 2); + assert.equal(m[0], '/route'); + assert.equal(m[1], 'route'); + + m = re.exec('/'); + + assert.equal(m.length, 2); + assert.equal(m[0], '/'); + assert.equal(m[1], undefined); + }); + + it('should allow express format param regexps', function () { + var params = []; + var m = pathToRegExp('/:page(\\d+)', params).exec('/56'); + + assert.equal(params.length, 1); + assert.equal(params[0].name, 'page'); + assert.equal(params[0].optional, false); + + assert.equal(m.length, 2); + assert.equal(m[0], '/56'); + assert.equal(m[1], '56'); + }); + + it('should match without a prefixed slash', function () { + var params = []; + var m = pathToRegExp(':test', params).exec('string'); + + assert.equal(params.length, 1); + assert.equal(params[0].name, 'test'); + assert.equal(params[0].optional, false); + + assert.equal(m.length, 2); + assert.equal(m[0], 'string'); + assert.equal(m[1], 'string'); + }); + + it('should not match format parts', function () { + var params = []; + var m = pathToRegExp('/:test.json', params).exec('/route.json'); + + assert.equal(params.length, 1); + assert.equal(params[0].name, 'test'); + assert.equal(params[0].optional, false); + + assert.equal(m.length, 2); + assert.equal(m[0], '/route.json'); + assert.equal(m[1], 'route'); + }); + + it('should match format parts', function () { + var params = []; + var re = pathToRegExp('/:test.:format', params); + var m; + + assert.equal(params.length, 2); + assert.equal(params[0].name, 'test'); + assert.equal(params[0].optional, false); + assert.equal(params[1].name, 'format'); + assert.equal(params[1].optional, false); + + m = re.exec('/route.json'); + + assert.equal(m.length, 3); + assert.equal(m[0], '/route.json'); + assert.equal(m[1], 'route'); + assert.equal(m[2], 'json'); + + m = re.exec('/route'); + + assert.ok(!m); + }); + + it('should match route parts with a trailing format', function () { + var params = []; + var m = pathToRegExp('/:test.json', params).exec('/route.json'); + + assert.equal(params.length, 1); + assert.equal(params[0].name, 'test'); + assert.equal(params[0].optional, false); + + assert.equal(m.length, 2); + assert.equal(m[0], '/route.json'); + assert.equal(m[1], 'route'); + }); + + it('should match optional trailing routes', function () { + var params = []; + var m = pathToRegExp('/test*', params).exec('/test/route'); + + assert.equal(params.length, 0); + + assert.equal(m.length, 2); + assert.equal(m[0], '/test/route'); + assert.equal(m[1], '/route'); + }); + + it('should match optional trailing routes after a param', function () { + var params = []; + var re = pathToRegExp('/:test*', params); + var m; + + assert.equal(params.length, 1); + assert.equal(params[0].name, 'test'); + assert.equal(params[0].optional, false); + + m = re.exec('/test/route'); + + assert.equal(m.length, 3); + assert.equal(m[0], '/test/route'); + assert.equal(m[1], 'test'); + assert.equal(m[2], '/route'); + + m = re.exec('/testing'); + + assert.equal(m.length, 3); + assert.equal(m[0], '/testing'); + assert.equal(m[1], 'testing'); + assert.equal(m[2], ''); + }); + + it('should match optional trailing routes before a format', function () { + var params = []; + var re = pathToRegExp('/test*.json', params); + var m; + + assert.equal(params.length, 0); + + m = re.exec('/test.json'); + + assert.equal(m.length, 2); + assert.equal(m[0], '/test.json'); + assert.equal(m[1], ''); + + m = re.exec('/testing.json'); + + assert.equal(m.length, 2); + assert.equal(m[0], '/testing.json'); + assert.equal(m[1], 'ing'); + + m = re.exec('/test/route.json'); + + assert.equal(m.length, 2); + assert.equal(m[0], '/test/route.json'); + assert.equal(m[1], '/route'); + }); + + it('should match optional trailing routes after a param and before a format', function () { + var params = []; + var re = pathToRegExp('/:test*.json', params); + var m; + + assert.equal(params.length, 1); + assert.equal(params[0].name, 'test'); + assert.equal(params[0].optional, false); + + m = re.exec('/testing.json'); + + assert.equal(m.length, 3); + assert.equal(m[0], '/testing.json'); + assert.equal(m[1], 'testing'); + assert.equal(m[2], ''); + + m = re.exec('/test/route.json'); + + assert.equal(m.length, 3); + assert.equal(m[0], '/test/route.json'); + assert.equal(m[1], 'test'); + assert.equal(m[2], '/route'); + + m = re.exec('.json'); + + assert.ok(!m); + }); + + it('should match optional trailing routes between a normal param and a format param', function () { + var params = []; + var re = pathToRegExp('/:test*.:format', params); + var m; + + assert.equal(params.length, 2); + assert.equal(params[0].name, 'test'); + assert.equal(params[0].optional, false); + assert.equal(params[1].name, 'format'); + assert.equal(params[1].optional, false); + + m = re.exec('/testing.json'); + + assert.equal(m.length, 4); + assert.equal(m[0], '/testing.json'); + assert.equal(m[1], 'testing'); + assert.equal(m[2], ''); + assert.equal(m[3], 'json'); + + m = re.exec('/test/route.json'); + + assert.equal(m.length, 4); + assert.equal(m[0], '/test/route.json'); + assert.equal(m[1], 'test'); + assert.equal(m[2], '/route'); + assert.equal(m[3], 'json'); + + m = re.exec('/test'); + + assert.ok(!m); + + m = re.exec('.json'); + + assert.ok(!m); + }); + + it('should match optional trailing routes after a param and before an optional format param', function () { + var params = []; + var re = pathToRegExp('/:test*.:format?', params); + var m; + + assert.equal(params.length, 2); + assert.equal(params[0].name, 'test'); + assert.equal(params[0].optional, false); + assert.equal(params[1].name, 'format'); + assert.equal(params[1].optional, true); + + m = re.exec('/testing.json'); + + assert.equal(m.length, 4); + assert.equal(m[0], '/testing.json'); + assert.equal(m[1], 'testing'); + assert.equal(m[2], ''); + assert.equal(m[3], 'json'); + + m = re.exec('/test/route.json'); + + assert.equal(m.length, 4); + assert.equal(m[0], '/test/route.json'); + assert.equal(m[1], 'test'); + assert.equal(m[2], '/route'); + assert.equal(m[3], 'json'); + + m = re.exec('/test'); + + assert.equal(m.length, 4); + assert.equal(m[0], '/test'); + assert.equal(m[1], 'test'); + assert.equal(m[2], ''); + assert.equal(m[3], undefined); + + m = re.exec('.json'); + + assert.ok(!m); + }); + + it('should match optional trailing routes inside optional express param', function () { + var params = []; + var re = pathToRegExp('/:test*?', params); + var m; + + assert.equal(params.length, 1); + assert.equal(params[0].name, 'test'); + assert.equal(params[0].optional, true); + + m = re.exec('/test/route'); + + assert.equal(m.length, 3); + assert.equal(m[0], '/test/route'); + assert.equal(m[1], 'test'); + assert.equal(m[2], '/route'); + + m = re.exec('/test'); + + assert.equal(m.length, 3); + assert.equal(m[0], '/test'); + assert.equal(m[1], 'test'); + assert.equal(m[2], ''); + + m = re.exec('/'); + + assert.equal(m.length, 3); + assert.equal(m[0], '/'); + assert.equal(m[1], undefined); + assert.equal(m[2], undefined); + }); + + it('should do case insensitive matches', function () { + var m = pathToRegExp('/test').exec('/TEST'); + + assert.equal(m[0], '/TEST'); + }); + + it('should do case sensitive matches', function () { + var re = pathToRegExp('/test', null, { sensitive: true }); + var m; + + m = re.exec('/test'); + + assert.equal(m.length, 1); + assert.equal(m[0], '/test'); + + m = re.exec('/TEST'); + + assert.ok(!m); + }); + + it('should do non-ending matches', function () { + var params = []; + var m = pathToRegExp('/:test', params, { end: false }).exec('/test/route'); + + assert.equal(params.length, 1); + assert.equal(params[0].name, 'test'); + assert.equal(params[0].optional, false); + + assert.equal(m.length, 2); + assert.equal(m[0], '/test'); + assert.equal(m[1], 'test'); + }); + + it('should match trailing slashes in non-ending non-strict mode', function () { + var params = []; + var re = pathToRegExp('/:test', params, { end: false }); + var m; + + assert.equal(params.length, 1); + assert.equal(params[0].name, 'test'); + assert.equal(params[0].optional, false); + + m = re.exec('/test/'); + + assert.equal(m.length, 2); + assert.equal(m[0], '/test/'); + assert.equal(m[1], 'test'); + }); + + it('should match trailing slashes in non-ending non-strict mode', function () { + var params = []; + var re = pathToRegExp('/route/', params, { end: false }); + var m; + + assert.equal(params.length, 0); + + m = re.exec('/route/'); + + assert.equal(m.length, 1); + assert.equal(m[0], '/route/'); + + m = re.exec('/route/test'); + + assert.equal(m.length, 1); + assert.equal(m[0], '/route'); + + m = re.exec('/route'); + + assert.equal(m.length, 1); + assert.equal(m[0], '/route'); + + m = re.exec('/route//'); + + assert.equal(m.length, 1); + assert.equal(m[0], '/route/'); + }); + + it('should match trailing slashing in non-ending strict mode', function () { + var params = []; + var re = pathToRegExp('/route/', params, { end: false, strict: true }); + + assert.equal(params.length, 0); + + m = re.exec('/route/'); + + assert.equal(m.length, 1); + assert.equal(m[0], '/route/'); + + m = re.exec('/route/test'); + + assert.equal(m.length, 1); + assert.equal(m[0], '/route/'); + + m = re.exec('/route'); + + assert.ok(!m); + + m = re.exec('/route//'); + + assert.equal(m.length, 1); + assert.equal(m[0], '/route/'); + }); + + it('should not match trailing slashes in non-ending strict mode', function () { + var params = []; + var re = pathToRegExp('/route', params, { end: false, strict: true }); + + assert.equal(params.length, 0); + + m = re.exec('/route'); + + assert.equal(m.length, 1); + assert.equal(m[0], '/route'); + + m = re.exec('/route/'); + + assert.ok(m.length, 1); + assert.equal(m[0], '/route'); + }); + + it('should match text after an express param', function () { + var params = []; + var re = pathToRegExp('/(:test)route', params); + + assert.equal(params.length, 1); + assert.equal(params[0].name, 'test'); + assert.equal(params[0].optional, false); + + m = re.exec('/route'); + + assert.ok(!m); + + m = re.exec('/testroute'); + + assert.equal(m.length, 2); + assert.equal(m[0], '/testroute'); + assert.equal(m[1], 'test'); + + m = re.exec('testroute'); + + assert.ok(!m); + }); + + it('should match text after an optional express param', function () { + var params = []; + var re = pathToRegExp('/(:test?)route', params); + var m; + + assert.equal(params.length, 1); + assert.equal(params[0].name, 'test'); + assert.equal(params[0].optional, true); + + m = re.exec('/route'); + + assert.equal(m.length, 2); + assert.equal(m[0], '/route'); + assert.equal(m[1], undefined); + + m = re.exec('/testroute'); + + assert.equal(m.length, 2); + assert.equal(m[0], '/testroute'); + assert.equal(m[1], 'test'); + + m = re.exec('route'); + + assert.ok(!m); + }); + + it('should match optional formats', function () { + var params = []; + var re = pathToRegExp('/:test.:format?', params); + var m; + + assert.equal(params.length, 2); + assert.equal(params[0].name, 'test'); + assert.equal(params[0].optional, false); + assert.equal(params[1].name, 'format'); + assert.equal(params[1].optional, true); + + m = re.exec('/route'); + + assert.equal(m.length, 3); + assert.equal(m[0], '/route'); + assert.equal(m[1], 'route'); + assert.equal(m[2], undefined); + + m = re.exec('/route.json'); + + assert.equal(m.length, 3); + assert.equal(m[0], '/route.json'); + assert.equal(m[1], 'route'); + assert.equal(m[2], 'json'); + }); + + it('should match full paths with format by default', function () { + var params = []; + var m = pathToRegExp('/:test', params).exec('/test.json'); + + assert.equal(params.length, 1); + assert.equal(params[0].name, 'test'); + assert.equal(params[0].optional, false); + + assert.equal(m.length, 2); + assert.equal(m[0], '/test.json'); + assert.equal(m[1], 'test.json'); + }); + }); + + describe('regexps', function () { + it('should return the regexp', function () { + assert.deepEqual(pathToRegExp(/.*/), /.*/); + }); + }); + + describe('arrays', function () { + it('should join arrays parts', function () { + var re = pathToRegExp(['/test', '/route']); + + assert.ok(re.test('/test')); + assert.ok(re.test('/route')); + assert.ok(!re.test('/else')); + }); + + it('should match parts properly', function () { + var params = []; + var re = pathToRegExp(['/:test', '/test/:route'], params); + var m; + + assert.equal(params.length, 2); + assert.equal(params[0].name, 'test'); + assert.equal(params[0].optional, false); + assert.equal(params[1].name, 'route'); + assert.equal(params[1].optional, false); + + m = re.exec('/route'); + + assert.equal(m.length, 3); + assert.equal(m[0], '/route'); + assert.equal(m[1], 'route'); + assert.equal(m[2], undefined); + + m = re.exec('/test/path'); + + assert.equal(m.length, 3); + assert.equal(m[0], '/test/path'); + assert.equal(m[1], undefined); + assert.equal(m[2], 'path'); + }); + }); +}); diff --git a/node_modules/express/node_modules/proxy-addr/HISTORY.md b/node_modules/express/node_modules/proxy-addr/HISTORY.md new file mode 100644 index 0000000..be5a4ff --- /dev/null +++ b/node_modules/express/node_modules/proxy-addr/HISTORY.md @@ -0,0 +1,34 @@ +1.0.2 / 2014-09-18 +================== + + * Fix a global leak when multiple subnets are trusted + * Support Node.js 0.6 + * deps: ipaddr.js@0.1.3 + +1.0.1 / 2014-06-03 +================== + + * Fix links in npm package + +1.0.0 / 2014-05-08 +================== + + * Add `trust` argument to determine proxy trust on + * Accepts custom function + * Accepts IPv4/IPv6 address(es) + * Accepts subnets + * Accepts pre-defined names + * Add optional `trust` argument to `proxyaddr.all` to + stop at first untrusted + * Add `proxyaddr.compile` to pre-compile `trust` function + to make subsequent calls faster + +0.0.1 / 2014-05-04 +================== + + * Fix bad npm publish + +0.0.0 / 2014-05-04 +================== + + * Initial release diff --git a/node_modules/express/node_modules/proxy-addr/LICENSE b/node_modules/express/node_modules/proxy-addr/LICENSE new file mode 100644 index 0000000..b7dce6c --- /dev/null +++ b/node_modules/express/node_modules/proxy-addr/LICENSE @@ -0,0 +1,22 @@ +(The MIT License) + +Copyright (c) 2014 Douglas Christopher Wilson + +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/node_modules/express/node_modules/proxy-addr/README.md b/node_modules/express/node_modules/proxy-addr/README.md new file mode 100644 index 0000000..57ec4cd --- /dev/null +++ b/node_modules/express/node_modules/proxy-addr/README.md @@ -0,0 +1,137 @@ +# proxy-addr + +[![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] + +Determine address of proxied request + +## Install + +```sh +$ npm install proxy-addr +``` + +## API + +```js +var proxyaddr = require('proxy-addr') +``` + +### proxyaddr(req, trust) + +Return the address of the request, using the given `trust` parameter. + +The `trust` argument is a function that returns `true` if you trust +the address, `false` if you don't. The closest untrusted address is +returned. + +```js +proxyaddr(req, function(addr){ return addr === '127.0.0.1' }) +proxyaddr(req, function(addr, i){ return i < 1 }) +``` + +The `trust` arugment may also be a single IP address string or an +array of trusted addresses, as plain IP addresses, CIDR-formatted +strings, or IP/netmask strings. + +```js +proxyaddr(req, '127.0.0.1') +proxyaddr(req, ['127.0.0.0/8', '10.0.0.0/8']) +proxyaddr(req, ['127.0.0.0/255.0.0.0', '192.168.0.0/255.255.0.0']) +``` + +This module also supports IPv6. Your IPv6 addresses will be normalized +automatically (i.e. `fe80::00ed:1` equals `fe80:0:0:0:0:0:ed:1`). + +```js +proxyaddr(req, '::1') +proxyaddr(req, ['::1/128', 'fe80::/10']) +proxyaddr(req, ['fe80::/ffc0::']) +``` + +This module will automatically work with IPv4-mapped IPv6 addresses +as well to support node.js in IPv6-only mode. This means that you do +not have to specify both `::ffff:a00:1` and `10.0.0.1`. + +As a convenience, this module also takes certain pre-defined names +in addition to IP addresses, which expand into IP addresses: + +```js +proxyaddr(req, 'loopback') +proxyaddr(req, ['loopback', 'fc00:ac:1ab5:fff::1/64']) +``` + + * `loopback`: IPv4 and IPv6 loopback addresses (like `::1` and + `127.0.0.1`). + * `linklocal`: IPv4 and IPv6 link-local addresses (like + `fe80::1:1:1:1` and `169.254.0.1`). + * `uniquelocal`: IPv4 private addresses and IPv6 unique-local + addresses (like `fc00:ac:1ab5:fff::1` and `192.168.0.1`). + +When `trust` is specified as a function, it will be called for each +address to determine if it is a trusted address. The function is +given two arguments: `addr` and `i`, where `addr` is a string of +the address to check and `i` is a number that represents the distance +from the socket address. + +### proxyaddr.all(req, [trust]) + +Return all the addresses of the request, optionally stopping at the +first untrusted. This array is ordered from closest to furthest +(i.e. `arr[0] === req.connection.remoteAddress`). + +```js +proxyaddr.all(req) +``` + +The optional `trust` argument takes the same arguments as `trust` +does in `proxyaddr(req, trust)`. + +```js +proxyaddr.all(req, 'loopback') +``` + +### proxyaddr.compile(val) + +Compiles argument `val` into a `trust` function. This function takes +the same arguments as `trust` does in `proxyaddr(req, trust)` and +returns a function suitable for `proxyaddr(req, trust)`. + +```js +var trust = proxyaddr.compile('localhost') +var addr = proxyaddr(req, trust) +``` + +This function is meant to be optimized for use against every request. +It is recommend to compile a trust function up-front for the trusted +configuration and pass that to `proxyaddr(req, trust)` for each request. + +## Testing + +```sh +$ npm test +``` + +## Benchmarks + +```sh +$ npm run-script bench +``` + +## License + +[MIT](LICENSE) + +[npm-image]: https://img.shields.io/npm/v/proxy-addr.svg?style=flat +[npm-url]: https://npmjs.org/package/proxy-addr +[node-version-image]: https://img.shields.io/node/v/proxy-addr.svg?style=flat +[node-version-url]: http://nodejs.org/download/ +[travis-image]: https://img.shields.io/travis/jshttp/proxy-addr.svg?style=flat +[travis-url]: https://travis-ci.org/jshttp/proxy-addr +[coveralls-image]: https://img.shields.io/coveralls/jshttp/proxy-addr.svg?style=flat +[coveralls-url]: https://coveralls.io/r/jshttp/proxy-addr?branch=master +[downloads-image]: https://img.shields.io/npm/dm/proxy-addr.svg?style=flat +[downloads-url]: https://npmjs.org/package/proxy-addr diff --git a/node_modules/express/node_modules/proxy-addr/index.js b/node_modules/express/node_modules/proxy-addr/index.js new file mode 100644 index 0000000..f10b2d5 --- /dev/null +++ b/node_modules/express/node_modules/proxy-addr/index.js @@ -0,0 +1,352 @@ +/*! + * proxy-addr + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module exports. + */ + +module.exports = proxyaddr; +module.exports.all = alladdrs; +module.exports.compile = compile; + +/** + * Module dependencies. + */ + +var ipaddr = require('ipaddr.js'); + +/** + * Variables. + */ + +var digitre = /^[0-9]+$/; +var isip = ipaddr.isValid; +var parseip = ipaddr.parse; + +/** + * Pre-defined IP ranges. + */ + +var ipranges = { + linklocal: ['169.254.0.0/16', 'fe80::/10'], + loopback: ['127.0.0.1/8', '::1/128'], + uniquelocal: ['10.0.0.0/8', '172.16.0.0/12', '192.168.0.0/16', 'fc00::/7'] +}; + +/** + * Get all addresses in the request, optionally stopping + * at the first untrusted. + * + * @param {Object} request + * @param {Function|Array|String} [trust] + * @api public + */ + +function alladdrs(req, trust) { + if (!req) { + throw new TypeError('req argument is required'); + } + + var proxyAddrs = (req.headers['x-forwarded-for'] || '') + .split(/ *, */) + .filter(Boolean) + .reverse(); + var socketAddr = req.connection.remoteAddress; + var addrs = [socketAddr].concat(proxyAddrs); + + if (!trust) { + // Return all addresses + return addrs; + } + + if (typeof trust !== 'function') { + trust = compile(trust); + } + + for (var i = 0; i < addrs.length - 1; i++) { + if (trust(addrs[i], i)) continue; + + addrs.length = i + 1; + } + + return addrs; +} + +/** + * Compile argument into trust function. + * + * @param {Array|String} val + * @api private + */ + +function compile(val) { + if (!val) { + throw new TypeError('argument is required'); + } + + var trust = typeof val === 'string' + ? [val] + : val; + + if (!Array.isArray(trust)) { + throw new TypeError('unsupported trust argument'); + } + + for (var i = 0; i < trust.length; i++) { + val = trust[i]; + + if (!ipranges.hasOwnProperty(val)) { + continue; + } + + // Splice in pre-defined range + val = ipranges[val]; + trust.splice.apply(trust, [i, 1].concat(val)); + i += val.length - 1; + } + + return compileTrust(compileRangeSubnets(trust)); +} + +/** + * Compile `arr` elements into range subnets. + * + * @param {Array} arr + * @api private + */ + +function compileRangeSubnets(arr) { + var rangeSubnets = new Array(arr.length); + + for (var i = 0; i < arr.length; i++) { + rangeSubnets[i] = parseipNotation(arr[i]); + } + + return rangeSubnets; +} + +/** + * Compile range subnet array into trust function. + * + * @param {Array} rangeSubnets + * @api private + */ + +function compileTrust(rangeSubnets) { + // Return optimized function based on length + var len = rangeSubnets.length; + return len === 0 + ? trustNone + : len === 1 + ? trustSingle(rangeSubnets[0]) + : trustMulti(rangeSubnets); +} + +/** + * Parse IP notation string into range subnet. + * + * @param {String} note + * @api private + */ + +function parseipNotation(note) { + var ip; + var kind; + var max; + var pos = note.lastIndexOf('/'); + var range; + + ip = pos !== -1 + ? note.substring(0, pos) + : note; + + if (!isip(ip)) { + throw new TypeError('invalid IP address: ' + ip); + } + + ip = parseip(ip); + + kind = ip.kind(); + max = kind === 'ipv6' + ? 128 + : 32; + + range = pos !== -1 + ? note.substring(pos + 1, note.length) + : max; + + if (typeof range !== 'number') { + range = digitre.test(range) + ? parseInt(range, 10) + : isip(range) + ? parseNetmask(range) + : 0; + } + + if (ip.kind() === 'ipv6' && ip.isIPv4MappedAddress()) { + // Store as IPv4 + ip = ip.toIPv4Address(); + range = range <= max + ? range - 96 + : range; + } + + if (range <= 0 || range > max) { + throw new TypeError('invalid range on address: ' + note); + } + + return [ip, range]; +} + +/** + * Parse netmask string into CIDR range. + * + * @param {String} note + * @api private + */ + +function parseNetmask(netmask) { + var ip = parseip(netmask); + var parts; + var size; + + switch (ip.kind()) { + case 'ipv4': + parts = ip.octets; + size = 8; + break; + case 'ipv6': + parts = ip.parts; + size = 16; + break; + } + + var max = Math.pow(2, size) - 1; + var part; + var range = 0; + + for (var i = 0; i < parts.length; i++) { + part = parts[i] & max; + + if (part === max) { + range += size; + continue; + } + + while (part) { + part = (part << 1) & max; + range += 1; + } + + break; + } + + return range; +} + +/** + * Determine address of proxied request. + * + * @param {Object} request + * @param {Function|Array|String} trust + * @api public + */ + +function proxyaddr(req, trust) { + if (!req) { + throw new TypeError('req argument is required'); + } + + if (!trust) { + throw new TypeError('trust argument is required'); + } + + var addrs = alladdrs(req, trust); + var addr = addrs[addrs.length - 1]; + + return addr; +} + +/** + * Static trust function to trust nothing. + * + * @api private + */ + +function trustNone() { + return false; +} + +/** + * Compile trust function for multiple subnets. + * + * @param {Array} subnets + * @api private + */ + +function trustMulti(subnets) { + return function trust(addr) { + if (!isip(addr)) return false; + + var ip = parseip(addr); + var ipv4; + var kind = ip.kind(); + var subnet; + var subnetip; + var subnetkind; + var subnetrange; + var trusted; + + for (var i = 0; i < subnets.length; i++) { + subnet = subnets[i]; + subnetip = subnet[0]; + subnetkind = subnetip.kind(); + subnetrange = subnet[1]; + trusted = ip; + + if (kind !== subnetkind) { + if (kind !== 'ipv6' || subnetkind !== 'ipv4' || !ip.isIPv4MappedAddress()) { + continue; + } + + // Store addr as IPv4 + ipv4 = ipv4 || ip.toIPv4Address(); + trusted = ipv4; + } + + if (trusted.match(subnetip, subnetrange)) return true; + } + + return false; + }; +} + +/** + * Compile trust function for single subnet. + * + * @param {Object} subnet + * @api private + */ + +function trustSingle(subnet) { + var subnetip = subnet[0]; + var subnetkind = subnetip.kind(); + var subnetisipv4 = subnetkind === 'ipv4'; + var subnetrange = subnet[1]; + + return function trust(addr) { + if (!isip(addr)) return false; + + var ip = parseip(addr); + var kind = ip.kind(); + + return kind === subnetkind + ? ip.match(subnetip, subnetrange) + : subnetisipv4 && kind === 'ipv6' && ip.isIPv4MappedAddress() + ? ip.toIPv4Address().match(subnetip, subnetrange) + : false; + }; +} diff --git a/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/.npmignore b/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/.npmignore new file mode 100644 index 0000000..7a1537b --- /dev/null +++ b/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/.npmignore @@ -0,0 +1,2 @@ +.idea +node_modules diff --git a/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/Cakefile b/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/Cakefile new file mode 100644 index 0000000..7fd355a --- /dev/null +++ b/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/Cakefile @@ -0,0 +1,18 @@ +fs = require 'fs' +CoffeeScript = require 'coffee-script' +nodeunit = require 'nodeunit' +UglifyJS = require 'uglify-js' + +task 'build', 'build the JavaScript files from CoffeeScript source', build = (cb) -> + source = fs.readFileSync 'src/ipaddr.coffee' + fs.writeFileSync 'lib/ipaddr.js', CoffeeScript.compile source.toString() + + invoke 'test' + invoke 'compress' + +task 'test', 'run the bundled tests', (cb) -> + nodeunit.reporters.default.run ['test'] + +task 'compress', 'uglify the resulting javascript', (cb) -> + result = UglifyJS.minify('lib/ipaddr.js') + fs.writeFileSync('ipaddr.min.js', result.code) diff --git a/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/LICENSE b/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/LICENSE new file mode 100644 index 0000000..3493f0d --- /dev/null +++ b/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/LICENSE @@ -0,0 +1,19 @@ +Copyright (C) 2011 Peter Zotov + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. \ No newline at end of file diff --git a/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/README.md b/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/README.md new file mode 100644 index 0000000..a816672 --- /dev/null +++ b/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/README.md @@ -0,0 +1,149 @@ +# ipaddr.js — an IPv6 and IPv4 address manipulation library + +ipaddr.js is a small (1.9K minified and gzipped) library for manipulating +IP addresses in JavaScript environments. It runs on both CommonJS runtimes +(e.g. [nodejs]) and in a web browser. + +ipaddr.js allows you to verify and parse string representation of an IP +address, match it against a CIDR range or range list, determine if it falls +into some reserved ranges (examples include loopback and private ranges), +and convert between IPv4 and IPv4-mapped IPv6 addresses. + +[nodejs]: http://nodejs.org + +## Installation + +`npm install ipaddr.js` + +## API + +ipaddr.js defines one object in the global scope: `ipaddr`. In CommonJS, +it is exported from the module: + +```js +var ipaddr = require('ipaddr.js'); +``` + +The API consists of several global methods and two classes: ipaddr.IPv6 and ipaddr.IPv4. + +### Global methods + +There are three global methods defined: `ipaddr.isValid`, `ipaddr.parse` and +`ipaddr.process`. All of them receive a string as a single parameter. + +The `ipaddr.isValid` method returns `true` if the address is a valid IPv4 or +IPv6 address, and `false` otherwise. It does not throw any exceptions. + +The `ipaddr.parse` method returns an object representing the IP address, +or throws an `Error` if the passed string is not a valid representation of an +IP address. + +The `ipaddr.process` method works just like the `ipaddr.parse` one, but it +automatically converts IPv4-mapped IPv6 addresses to their IPv4 couterparts +before returning. It is useful when you have a Node.js instance listening +on an IPv6 socket, and the `net.ivp6.bindv6only` sysctl parameter (or its +equivalent on non-Linux OS) is set to 0. In this case, you can accept IPv4 +connections on your IPv6-only socket, but the remote address will be mangled. +Use `ipaddr.process` method to automatically demangle it. + +### Object representation + +Parsing methods return an object which descends from `ipaddr.IPv6` or +`ipaddr.IPv4`. These objects share some properties, but most of them differ. + +#### Shared properties + +One can determine the type of address by calling `addr.kind()`. It will return +either `"ipv6"` or `"ipv4"`. + +An address can be converted back to its string representation with `addr.toString()`. +Note that this method: + * does not return the original string used to create the object (in fact, there is + no way of getting that string) + * returns a compact representation (when it is applicable) + +A `match(range, bits)` method can be used to check if the address falls into a +certain CIDR range. +Note that an address can be (obviously) matched only against an address of the same type. + +For example: + +```js +var addr = ipaddr.parse("2001:db8:1234::1"); +var range = ipaddr.parse("2001:db8::"); + +addr.match(range, 32); // => true +``` + +A `range()` method returns one of predefined names for several special ranges defined +by IP protocols. The exact names (and their respective CIDR ranges) can be looked up +in the source: [IPv6 ranges] and [IPv4 ranges]. Some common ones include `"unicast"` +(the default one) and `"reserved"`. + +You can match against your own range list by using +`ipaddr.subnetMatch(address, rangeList, defaultName)` method. It can work with both +IPv6 and IPv4 addresses, and accepts a name-to-subnet map as the range list. For example: + +```js +var rangeList = { + documentationOnly: [ ipaddr.parse('2001:db8::'), 32 ], + tunnelProviders: [ + [ ipaddr.parse('2001:470::'), 32 ], // he.net + [ ipaddr.parse('2001:5c0::'), 32 ] // freenet6 + ] +}; +ipaddr.subnetMatch(ipaddr.parse('2001:470:8:66::1'), rangeList, 'unknown'); // => "he.net" +``` + +The addresses can be converted to their byte representation with `toByteArray()`. +(Actually, JavaScript mostly does not know about byte buffers. They are emulated with +arrays of numbers, each in range of 0..255.) + +```js +var bytes = ipaddr.parse('2a00:1450:8007::68').toByteArray(); // ipv6.google.com +bytes // => [42, 0x00, 0x14, 0x50, 0x80, 0x07, 0x00, , 0x00, 0x68 ] +``` + +The `ipaddr.IPv4` and `ipaddr.IPv6` objects have some methods defined, too. All of them +have the same interface for both protocols, and are similar to global methods. + +`ipaddr.IPvX.isValid(string)` can be used to check if the string is a valid address +for particular protocol, and `ipaddr.IPvX.parse(string)` is the error-throwing parser. + +[IPv6 ranges]: https://github.com/whitequark/ipaddr.js/blob/master/src/ipaddr.coffee#L186 +[IPv4 ranges]: https://github.com/whitequark/ipaddr.js/blob/master/src/ipaddr.coffee#L71 + +#### IPv6 properties + +Sometimes you will want to convert IPv6 not to a compact string representation (with +the `::` substitution); the `toNormalizedString()` method will return an address where +all zeroes are explicit. + +For example: + +```js +var addr = ipaddr.parse("2001:0db8::0001"); +addr.toString(); // => "2001:db8::1" +addr.toNormalizedString(); // => "2001:db8:0:0:0:0:0:1" +``` + +The `isIPv4MappedAddress()` method will return `true` if this address is an IPv4-mapped +one, and `toIPv4Address()` will return an IPv4 object address. + +To access the underlying binary representation of the address, use `addr.parts`. + +```js +var addr = ipaddr.parse("2001:db8:10::1234:DEAD"); +addr.parts // => [0x2001, 0xdb8, 0x10, 0, 0, 0, 0x1234, 0xdead] +``` + +#### IPv4 properties + +`toIPv4MappedAddress()` will return a corresponding IPv4-mapped IPv6 address. + +To access the underlying representation of the address, use `addr.octets`. + +```js +var addr = ipaddr.parse("192.168.1.1"); +addr.octets // => [192, 168, 1, 1] +``` diff --git a/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/ipaddr.min.js b/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/ipaddr.min.js new file mode 100644 index 0000000..528d48b --- /dev/null +++ b/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/ipaddr.min.js @@ -0,0 +1 @@ +(function(){var t,r,n,e,i,o,a,s;r={},s=this,"undefined"!=typeof module&&null!==module&&module.exports?module.exports=r:s.ipaddr=r,a=function(t,r,n,e){var i,o;if(t.length!==r.length)throw new Error("ipaddr: cannot match CIDR for objects with different lengths");for(i=0;e>0;){if(o=n-e,0>o&&(o=0),t[i]>>o!==r[i]>>o)return!1;e-=n,i+=1}return!0},r.subnetMatch=function(t,r,n){var e,i,o,a,s;null==n&&(n="unicast");for(e in r)for(i=r[e],"[object Array]"!==toString.call(i[0])&&(i=[i]),a=0,s=i.length;s>a;a++)if(o=i[a],t.match.apply(t,o))return e;return n},r.IPv4=function(){function t(t){var r,n,e;if(4!==t.length)throw new Error("ipaddr: ipv4 octet count should be 4");for(n=0,e=t.length;e>n;n++)if(r=t[n],!(r>=0&&255>=r))throw new Error("ipaddr: ipv4 octet is a byte");this.octets=t}return t.prototype.kind=function(){return"ipv4"},t.prototype.toString=function(){return this.octets.join(".")},t.prototype.toByteArray=function(){return this.octets.slice(0)},t.prototype.match=function(t,r){if("ipv4"!==t.kind())throw new Error("ipaddr: cannot match ipv4 address with non-ipv4 one");return a(this.octets,t.octets,8,r)},t.prototype.SpecialRanges={broadcast:[[new t([255,255,255,255]),32]],multicast:[[new t([224,0,0,0]),4]],linkLocal:[[new t([169,254,0,0]),16]],loopback:[[new t([127,0,0,0]),8]],"private":[[new t([10,0,0,0]),8],[new t([172,16,0,0]),12],[new t([192,168,0,0]),16]],reserved:[[new t([192,0,0,0]),24],[new t([192,0,2,0]),24],[new t([192,88,99,0]),24],[new t([198,51,100,0]),24],[new t([203,0,113,0]),24],[new t([240,0,0,0]),4]]},t.prototype.range=function(){return r.subnetMatch(this,this.SpecialRanges)},t.prototype.toIPv4MappedAddress=function(){return r.IPv6.parse("::ffff:"+this.toString())},t}(),n="(0?\\d+|0x[a-f0-9]+)",e={fourOctet:new RegExp("^"+n+"\\."+n+"\\."+n+"\\."+n+"$","i"),longValue:new RegExp("^"+n+"$","i")},r.IPv4.parser=function(t){var r,n,i,o,a;return n=function(t){return"0"===t[0]&&"x"!==t[1]?parseInt(t,8):parseInt(t)},(r=t.match(e.fourOctet))?function(){var t,e,o,a;for(o=r.slice(1,6),a=[],t=0,e=o.length;e>t;t++)i=o[t],a.push(n(i));return a}():(r=t.match(e.longValue))?(a=n(r[1]),function(){var t,r;for(r=[],o=t=0;24>=t;o=t+=8)r.push(a>>o&255);return r}().reverse()):null},r.IPv6=function(){function t(t){var r,n,e;if(8!==t.length)throw new Error("ipaddr: ipv6 part count should be 8");for(n=0,e=t.length;e>n;n++)if(r=t[n],!(r>=0&&65535>=r))throw new Error("ipaddr: ipv6 part should fit to two octets");this.parts=t}return t.prototype.kind=function(){return"ipv6"},t.prototype.toString=function(){var t,r,n,e,i,o,a;for(i=function(){var t,n,e,i;for(e=this.parts,i=[],t=0,n=e.length;n>t;t++)r=e[t],i.push(r.toString(16));return i}.call(this),t=[],n=function(r){return t.push(r)},e=0,o=0,a=i.length;a>o;o++)switch(r=i[o],e){case 0:"0"===r?n(""):n(r),e=1;break;case 1:"0"===r?e=2:n(r);break;case 2:"0"!==r&&(n(""),n(r),e=3);break;case 3:n(r)}return 2===e&&(n(""),n("")),t.join(":")},t.prototype.toByteArray=function(){var t,r,n,e,i;for(t=[],i=this.parts,n=0,e=i.length;e>n;n++)r=i[n],t.push(r>>8),t.push(255&r);return t},t.prototype.toNormalizedString=function(){var t;return function(){var r,n,e,i;for(e=this.parts,i=[],r=0,n=e.length;n>r;r++)t=e[r],i.push(t.toString(16));return i}.call(this).join(":")},t.prototype.match=function(t,r){if("ipv6"!==t.kind())throw new Error("ipaddr: cannot match ipv6 address with non-ipv6 one");return a(this.parts,t.parts,16,r)},t.prototype.SpecialRanges={unspecified:[new t([0,0,0,0,0,0,0,0]),128],linkLocal:[new t([65152,0,0,0,0,0,0,0]),10],multicast:[new t([65280,0,0,0,0,0,0,0]),8],loopback:[new t([0,0,0,0,0,0,0,1]),128],uniqueLocal:[new t([64512,0,0,0,0,0,0,0]),7],ipv4Mapped:[new t([0,0,0,0,0,65535,0,0]),96],rfc6145:[new t([0,0,0,0,65535,0,0,0]),96],rfc6052:[new t([100,65435,0,0,0,0,0,0]),96],"6to4":[new t([8194,0,0,0,0,0,0,0]),16],teredo:[new t([8193,0,0,0,0,0,0,0]),32],reserved:[[new t([8193,3512,0,0,0,0,0,0]),32]]},t.prototype.range=function(){return r.subnetMatch(this,this.SpecialRanges)},t.prototype.isIPv4MappedAddress=function(){return"ipv4Mapped"===this.range()},t.prototype.toIPv4Address=function(){var t,n,e;if(!this.isIPv4MappedAddress())throw new Error("ipaddr: trying to convert a generic ipv6 address to ipv4");return e=this.parts.slice(-2),t=e[0],n=e[1],new r.IPv4([t>>8,255&t,n>>8,255&n])},t}(),i="(?:[0-9a-f]+::?)+",o={"native":new RegExp("^(::)?("+i+")?([0-9a-f]+)?(::)?$","i"),transitional:new RegExp("^((?:"+i+")|(?:::)(?:"+i+")?)"+(""+n+"\\."+n+"\\."+n+"\\."+n+"$"),"i")},t=function(t,r){var n,e,i,o,a;if(t.indexOf("::")!==t.lastIndexOf("::"))return null;for(n=0,e=-1;(e=t.indexOf(":",e+1))>=0;)n++;for(":"===t[0]&&n--,":"===t[t.length-1]&&n--,a=r-n,o=":";a--;)o+="0:";return t=t.replace("::",o),":"===t[0]&&(t=t.slice(1)),":"===t[t.length-1]&&(t=t.slice(0,-1)),function(){var r,n,e,o;for(e=t.split(":"),o=[],r=0,n=e.length;n>r;r++)i=e[r],o.push(parseInt(i,16));return o}()},r.IPv6.parser=function(r){var n,e;return r.match(o["native"])?t(r,8):(n=r.match(o.transitional))&&(e=t(n[1].slice(0,-1),6))?(e.push(parseInt(n[2])<<8|parseInt(n[3])),e.push(parseInt(n[4])<<8|parseInt(n[5])),e):null},r.IPv4.isIPv4=r.IPv6.isIPv6=function(t){return null!==this.parser(t)},r.IPv4.isValid=r.IPv6.isValid=function(t){var r;try{return new this(this.parser(t)),!0}catch(n){return r=n,!1}},r.IPv4.parse=r.IPv6.parse=function(t){var r;if(r=this.parser(t),null===r)throw new Error("ipaddr: string is not formatted like ip address");return new this(r)},r.isValid=function(t){return r.IPv6.isValid(t)||r.IPv4.isValid(t)},r.parse=function(t){if(r.IPv6.isIPv6(t))return r.IPv6.parse(t);if(r.IPv4.isIPv4(t))return r.IPv4.parse(t);throw new Error("ipaddr: the address has neither IPv6 nor IPv4 format")},r.process=function(t){var r;return r=this.parse(t),"ipv6"===r.kind()&&r.isIPv4MappedAddress()?r.toIPv4Address():r}}).call(this); \ No newline at end of file diff --git a/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/lib/ipaddr.js b/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/lib/ipaddr.js new file mode 100644 index 0000000..2319737 --- /dev/null +++ b/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/lib/ipaddr.js @@ -0,0 +1,401 @@ +(function() { + var expandIPv6, ipaddr, ipv4Part, ipv4Regexes, ipv6Part, ipv6Regexes, matchCIDR, root; + + ipaddr = {}; + + root = this; + + if ((typeof module !== "undefined" && module !== null) && module.exports) { + module.exports = ipaddr; + } else { + root['ipaddr'] = ipaddr; + } + + matchCIDR = function(first, second, partSize, cidrBits) { + var part, shift; + if (first.length !== second.length) { + throw new Error("ipaddr: cannot match CIDR for objects with different lengths"); + } + part = 0; + while (cidrBits > 0) { + shift = partSize - cidrBits; + if (shift < 0) { + shift = 0; + } + if (first[part] >> shift !== second[part] >> shift) { + return false; + } + cidrBits -= partSize; + part += 1; + } + return true; + }; + + ipaddr.subnetMatch = function(address, rangeList, defaultName) { + var rangeName, rangeSubnets, subnet, _i, _len; + if (defaultName == null) { + defaultName = 'unicast'; + } + for (rangeName in rangeList) { + rangeSubnets = rangeList[rangeName]; + if (toString.call(rangeSubnets[0]) !== '[object Array]') { + rangeSubnets = [rangeSubnets]; + } + for (_i = 0, _len = rangeSubnets.length; _i < _len; _i++) { + subnet = rangeSubnets[_i]; + if (address.match.apply(address, subnet)) { + return rangeName; + } + } + } + return defaultName; + }; + + ipaddr.IPv4 = (function() { + function IPv4(octets) { + var octet, _i, _len; + if (octets.length !== 4) { + throw new Error("ipaddr: ipv4 octet count should be 4"); + } + for (_i = 0, _len = octets.length; _i < _len; _i++) { + octet = octets[_i]; + if (!((0 <= octet && octet <= 255))) { + throw new Error("ipaddr: ipv4 octet is a byte"); + } + } + this.octets = octets; + } + + IPv4.prototype.kind = function() { + return 'ipv4'; + }; + + IPv4.prototype.toString = function() { + return this.octets.join("."); + }; + + IPv4.prototype.toByteArray = function() { + return this.octets.slice(0); + }; + + IPv4.prototype.match = function(other, cidrRange) { + if (other.kind() !== 'ipv4') { + throw new Error("ipaddr: cannot match ipv4 address with non-ipv4 one"); + } + return matchCIDR(this.octets, other.octets, 8, cidrRange); + }; + + IPv4.prototype.SpecialRanges = { + broadcast: [[new IPv4([255, 255, 255, 255]), 32]], + multicast: [[new IPv4([224, 0, 0, 0]), 4]], + linkLocal: [[new IPv4([169, 254, 0, 0]), 16]], + loopback: [[new IPv4([127, 0, 0, 0]), 8]], + "private": [[new IPv4([10, 0, 0, 0]), 8], [new IPv4([172, 16, 0, 0]), 12], [new IPv4([192, 168, 0, 0]), 16]], + reserved: [[new IPv4([192, 0, 0, 0]), 24], [new IPv4([192, 0, 2, 0]), 24], [new IPv4([192, 88, 99, 0]), 24], [new IPv4([198, 51, 100, 0]), 24], [new IPv4([203, 0, 113, 0]), 24], [new IPv4([240, 0, 0, 0]), 4]] + }; + + IPv4.prototype.range = function() { + return ipaddr.subnetMatch(this, this.SpecialRanges); + }; + + IPv4.prototype.toIPv4MappedAddress = function() { + return ipaddr.IPv6.parse("::ffff:" + (this.toString())); + }; + + return IPv4; + + })(); + + ipv4Part = "(0?\\d+|0x[a-f0-9]+)"; + + ipv4Regexes = { + fourOctet: new RegExp("^" + ipv4Part + "\\." + ipv4Part + "\\." + ipv4Part + "\\." + ipv4Part + "$", 'i'), + longValue: new RegExp("^" + ipv4Part + "$", 'i') + }; + + ipaddr.IPv4.parser = function(string) { + var match, parseIntAuto, part, shift, value; + parseIntAuto = function(string) { + if (string[0] === "0" && string[1] !== "x") { + return parseInt(string, 8); + } else { + return parseInt(string); + } + }; + if (match = string.match(ipv4Regexes.fourOctet)) { + return (function() { + var _i, _len, _ref, _results; + _ref = match.slice(1, 6); + _results = []; + for (_i = 0, _len = _ref.length; _i < _len; _i++) { + part = _ref[_i]; + _results.push(parseIntAuto(part)); + } + return _results; + })(); + } else if (match = string.match(ipv4Regexes.longValue)) { + value = parseIntAuto(match[1]); + return ((function() { + var _i, _results; + _results = []; + for (shift = _i = 0; _i <= 24; shift = _i += 8) { + _results.push((value >> shift) & 0xff); + } + return _results; + })()).reverse(); + } else { + return null; + } + }; + + ipaddr.IPv6 = (function() { + function IPv6(parts) { + var part, _i, _len; + if (parts.length !== 8) { + throw new Error("ipaddr: ipv6 part count should be 8"); + } + for (_i = 0, _len = parts.length; _i < _len; _i++) { + part = parts[_i]; + if (!((0 <= part && part <= 0xffff))) { + throw new Error("ipaddr: ipv6 part should fit to two octets"); + } + } + this.parts = parts; + } + + IPv6.prototype.kind = function() { + return 'ipv6'; + }; + + IPv6.prototype.toString = function() { + var compactStringParts, part, pushPart, state, stringParts, _i, _len; + stringParts = (function() { + var _i, _len, _ref, _results; + _ref = this.parts; + _results = []; + for (_i = 0, _len = _ref.length; _i < _len; _i++) { + part = _ref[_i]; + _results.push(part.toString(16)); + } + return _results; + }).call(this); + compactStringParts = []; + pushPart = function(part) { + return compactStringParts.push(part); + }; + state = 0; + for (_i = 0, _len = stringParts.length; _i < _len; _i++) { + part = stringParts[_i]; + switch (state) { + case 0: + if (part === '0') { + pushPart(''); + } else { + pushPart(part); + } + state = 1; + break; + case 1: + if (part === '0') { + state = 2; + } else { + pushPart(part); + } + break; + case 2: + if (part !== '0') { + pushPart(''); + pushPart(part); + state = 3; + } + break; + case 3: + pushPart(part); + } + } + if (state === 2) { + pushPart(''); + pushPart(''); + } + return compactStringParts.join(":"); + }; + + IPv6.prototype.toByteArray = function() { + var bytes, part, _i, _len, _ref; + bytes = []; + _ref = this.parts; + for (_i = 0, _len = _ref.length; _i < _len; _i++) { + part = _ref[_i]; + bytes.push(part >> 8); + bytes.push(part & 0xff); + } + return bytes; + }; + + IPv6.prototype.toNormalizedString = function() { + var part; + return ((function() { + var _i, _len, _ref, _results; + _ref = this.parts; + _results = []; + for (_i = 0, _len = _ref.length; _i < _len; _i++) { + part = _ref[_i]; + _results.push(part.toString(16)); + } + return _results; + }).call(this)).join(":"); + }; + + IPv6.prototype.match = function(other, cidrRange) { + if (other.kind() !== 'ipv6') { + throw new Error("ipaddr: cannot match ipv6 address with non-ipv6 one"); + } + return matchCIDR(this.parts, other.parts, 16, cidrRange); + }; + + IPv6.prototype.SpecialRanges = { + unspecified: [new IPv6([0, 0, 0, 0, 0, 0, 0, 0]), 128], + linkLocal: [new IPv6([0xfe80, 0, 0, 0, 0, 0, 0, 0]), 10], + multicast: [new IPv6([0xff00, 0, 0, 0, 0, 0, 0, 0]), 8], + loopback: [new IPv6([0, 0, 0, 0, 0, 0, 0, 1]), 128], + uniqueLocal: [new IPv6([0xfc00, 0, 0, 0, 0, 0, 0, 0]), 7], + ipv4Mapped: [new IPv6([0, 0, 0, 0, 0, 0xffff, 0, 0]), 96], + rfc6145: [new IPv6([0, 0, 0, 0, 0xffff, 0, 0, 0]), 96], + rfc6052: [new IPv6([0x64, 0xff9b, 0, 0, 0, 0, 0, 0]), 96], + '6to4': [new IPv6([0x2002, 0, 0, 0, 0, 0, 0, 0]), 16], + teredo: [new IPv6([0x2001, 0, 0, 0, 0, 0, 0, 0]), 32], + reserved: [[new IPv6([0x2001, 0xdb8, 0, 0, 0, 0, 0, 0]), 32]] + }; + + IPv6.prototype.range = function() { + return ipaddr.subnetMatch(this, this.SpecialRanges); + }; + + IPv6.prototype.isIPv4MappedAddress = function() { + return this.range() === 'ipv4Mapped'; + }; + + IPv6.prototype.toIPv4Address = function() { + var high, low, _ref; + if (!this.isIPv4MappedAddress()) { + throw new Error("ipaddr: trying to convert a generic ipv6 address to ipv4"); + } + _ref = this.parts.slice(-2), high = _ref[0], low = _ref[1]; + return new ipaddr.IPv4([high >> 8, high & 0xff, low >> 8, low & 0xff]); + }; + + return IPv6; + + })(); + + ipv6Part = "(?:[0-9a-f]+::?)+"; + + ipv6Regexes = { + "native": new RegExp("^(::)?(" + ipv6Part + ")?([0-9a-f]+)?(::)?$", 'i'), + transitional: new RegExp(("^((?:" + ipv6Part + ")|(?:::)(?:" + ipv6Part + ")?)") + ("" + ipv4Part + "\\." + ipv4Part + "\\." + ipv4Part + "\\." + ipv4Part + "$"), 'i') + }; + + expandIPv6 = function(string, parts) { + var colonCount, lastColon, part, replacement, replacementCount; + if (string.indexOf('::') !== string.lastIndexOf('::')) { + return null; + } + colonCount = 0; + lastColon = -1; + while ((lastColon = string.indexOf(':', lastColon + 1)) >= 0) { + colonCount++; + } + if (string[0] === ':') { + colonCount--; + } + if (string[string.length - 1] === ':') { + colonCount--; + } + replacementCount = parts - colonCount; + replacement = ':'; + while (replacementCount--) { + replacement += '0:'; + } + string = string.replace('::', replacement); + if (string[0] === ':') { + string = string.slice(1); + } + if (string[string.length - 1] === ':') { + string = string.slice(0, -1); + } + return (function() { + var _i, _len, _ref, _results; + _ref = string.split(":"); + _results = []; + for (_i = 0, _len = _ref.length; _i < _len; _i++) { + part = _ref[_i]; + _results.push(parseInt(part, 16)); + } + return _results; + })(); + }; + + ipaddr.IPv6.parser = function(string) { + var match, parts; + if (string.match(ipv6Regexes['native'])) { + return expandIPv6(string, 8); + } else if (match = string.match(ipv6Regexes['transitional'])) { + parts = expandIPv6(match[1].slice(0, -1), 6); + if (parts) { + parts.push(parseInt(match[2]) << 8 | parseInt(match[3])); + parts.push(parseInt(match[4]) << 8 | parseInt(match[5])); + return parts; + } + } + return null; + }; + + ipaddr.IPv4.isIPv4 = ipaddr.IPv6.isIPv6 = function(string) { + return this.parser(string) !== null; + }; + + ipaddr.IPv4.isValid = ipaddr.IPv6.isValid = function(string) { + var e; + try { + new this(this.parser(string)); + return true; + } catch (_error) { + e = _error; + return false; + } + }; + + ipaddr.IPv4.parse = ipaddr.IPv6.parse = function(string) { + var parts; + parts = this.parser(string); + if (parts === null) { + throw new Error("ipaddr: string is not formatted like ip address"); + } + return new this(parts); + }; + + ipaddr.isValid = function(string) { + return ipaddr.IPv6.isValid(string) || ipaddr.IPv4.isValid(string); + }; + + ipaddr.parse = function(string) { + if (ipaddr.IPv6.isIPv6(string)) { + return ipaddr.IPv6.parse(string); + } else if (ipaddr.IPv4.isIPv4(string)) { + return ipaddr.IPv4.parse(string); + } else { + throw new Error("ipaddr: the address has neither IPv6 nor IPv4 format"); + } + }; + + ipaddr.process = function(string) { + var addr; + addr = this.parse(string); + if (addr.kind() === 'ipv6' && addr.isIPv4MappedAddress()) { + return addr.toIPv4Address(); + } else { + return addr; + } + }; + +}).call(this); diff --git a/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/package.json b/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/package.json new file mode 100644 index 0000000..a174603 --- /dev/null +++ b/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/package.json @@ -0,0 +1,56 @@ +{ + "name": "ipaddr.js", + "description": "A library for manipulating IPv4 and IPv6 addresses in JavaScript.", + "version": "0.1.3", + "author": { + "name": "Peter Zotov", + "email": "whitequark@whitequark.org" + }, + "directories": { + "lib": "./lib" + }, + "dependencies": {}, + "devDependencies": { + "coffee-script": "~1.6", + "nodeunit": "~0.5.3", + "uglify-js": "latest" + }, + "scripts": { + "test": "cake build test" + }, + "keywords": [ + "ip", + "ipv4", + "ipv6" + ], + "repository": { + "type": "git", + "url": "git://github.com/whitequark/ipaddr.js" + }, + "main": "./lib/ipaddr", + "engines": { + "node": ">= 0.2.5" + }, + "bugs": { + "url": "https://github.com/whitequark/ipaddr.js/issues" + }, + "_id": "ipaddr.js@0.1.3", + "dist": { + "shasum": "27a9ca37f148d2102b0ef191ccbf2c51a8f025c6", + "tarball": "http://registry.npmjs.org/ipaddr.js/-/ipaddr.js-0.1.3.tgz" + }, + "_from": "ipaddr.js@0.1.3", + "_npmVersion": "1.4.4", + "_npmUser": { + "name": "whitequark", + "email": "whitequark@whitequark.org" + }, + "maintainers": [ + { + "name": "whitequark", + "email": "whitequark@whitequark.org" + } + ], + "_shasum": "27a9ca37f148d2102b0ef191ccbf2c51a8f025c6", + "_resolved": "https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-0.1.3.tgz" +} diff --git a/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/src/ipaddr.coffee b/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/src/ipaddr.coffee new file mode 100644 index 0000000..4c89ded --- /dev/null +++ b/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/src/ipaddr.coffee @@ -0,0 +1,344 @@ +# Define the main object +ipaddr = {} + +root = this + +# Export for both the CommonJS and browser-like environment +if module? && module.exports + module.exports = ipaddr +else + root['ipaddr'] = ipaddr + +# A generic CIDR (Classless Inter-Domain Routing) RFC1518 range matcher. +matchCIDR = (first, second, partSize, cidrBits) -> + if first.length != second.length + throw new Error "ipaddr: cannot match CIDR for objects with different lengths" + + part = 0 + while cidrBits > 0 + shift = partSize - cidrBits + shift = 0 if shift < 0 + + if first[part] >> shift != second[part] >> shift + return false + + cidrBits -= partSize + part += 1 + + return true + +# An utility function to ease named range matching. See examples below. +ipaddr.subnetMatch = (address, rangeList, defaultName='unicast') -> + for rangeName, rangeSubnets of rangeList + # ECMA5 Array.isArray isn't available everywhere + if toString.call(rangeSubnets[0]) != '[object Array]' + rangeSubnets = [ rangeSubnets ] + + for subnet in rangeSubnets + return rangeName if address.match.apply(address, subnet) + + return defaultName + +# An IPv4 address (RFC791). +class ipaddr.IPv4 + # Constructs a new IPv4 address from an array of four octets. + # Verifies the input. + constructor: (octets) -> + if octets.length != 4 + throw new Error "ipaddr: ipv4 octet count should be 4" + + for octet in octets + if !(0 <= octet <= 255) + throw new Error "ipaddr: ipv4 octet is a byte" + + @octets = octets + + # The 'kind' method exists on both IPv4 and IPv6 classes. + kind: -> + return 'ipv4' + + # Returns the address in convenient, decimal-dotted format. + toString: -> + return @octets.join "." + + # Returns an array of byte-sized values in network order + toByteArray: -> + return @octets.slice(0) # octets.clone + + # Checks if this address matches other one within given CIDR range. + match: (other, cidrRange) -> + if other.kind() != 'ipv4' + throw new Error "ipaddr: cannot match ipv4 address with non-ipv4 one" + + return matchCIDR(this.octets, other.octets, 8, cidrRange) + + # Special IPv4 address ranges. + SpecialRanges: + broadcast: [ + [ new IPv4([255, 255, 255, 255]), 32 ] + ] + multicast: [ # RFC3171 + [ new IPv4([224, 0, 0, 0]), 4 ] + ] + linkLocal: [ # RFC3927 + [ new IPv4([169, 254, 0, 0]), 16 ] + ] + loopback: [ # RFC5735 + [ new IPv4([127, 0, 0, 0]), 8 ] + ] + private: [ # RFC1918 + [ new IPv4([10, 0, 0, 0]), 8 ] + [ new IPv4([172, 16, 0, 0]), 12 ] + [ new IPv4([192, 168, 0, 0]), 16 ] + ] + reserved: [ # Reserved and testing-only ranges; RFCs 5735, 5737, 2544, 1700 + [ new IPv4([192, 0, 0, 0]), 24 ] + [ new IPv4([192, 0, 2, 0]), 24 ] + [ new IPv4([192, 88, 99, 0]), 24 ] + [ new IPv4([198, 51, 100, 0]), 24 ] + [ new IPv4([203, 0, 113, 0]), 24 ] + [ new IPv4([240, 0, 0, 0]), 4 ] + ] + + # Checks if the address corresponds to one of the special ranges. + range: -> + return ipaddr.subnetMatch(this, @SpecialRanges) + + # Convrets this IPv4 address to an IPv4-mapped IPv6 address. + toIPv4MappedAddress: -> + return ipaddr.IPv6.parse "::ffff:#{@toString()}" + +# A list of regular expressions that match arbitrary IPv4 addresses, +# for which a number of weird notations exist. +# Note that an address like 0010.0xa5.1.1 is considered legal. +ipv4Part = "(0?\\d+|0x[a-f0-9]+)" +ipv4Regexes = + fourOctet: new RegExp "^#{ipv4Part}\\.#{ipv4Part}\\.#{ipv4Part}\\.#{ipv4Part}$", 'i' + longValue: new RegExp "^#{ipv4Part}$", 'i' + +# Classful variants (like a.b, where a is an octet, and b is a 24-bit +# value representing last three octets; this corresponds to a class C +# address) are omitted due to classless nature of modern Internet. +ipaddr.IPv4.parser = (string) -> + parseIntAuto = (string) -> + if string[0] == "0" && string[1] != "x" + parseInt(string, 8) + else + parseInt(string) + + # parseInt recognizes all that octal & hexadecimal weirdness for us + if match = string.match(ipv4Regexes.fourOctet) + return (parseIntAuto(part) for part in match[1..5]) + else if match = string.match(ipv4Regexes.longValue) + value = parseIntAuto(match[1]) + return ((value >> shift) & 0xff for shift in [0..24] by 8).reverse() + else + return null + +# An IPv6 address (RFC2460) +class ipaddr.IPv6 + # Constructs an IPv6 address from an array of eight 16-bit parts. + # Throws an error if the input is invalid. + constructor: (parts) -> + if parts.length != 8 + throw new Error "ipaddr: ipv6 part count should be 8" + + for part in parts + if !(0 <= part <= 0xffff) + throw new Error "ipaddr: ipv6 part should fit to two octets" + + @parts = parts + + # The 'kind' method exists on both IPv4 and IPv6 classes. + kind: -> + return 'ipv6' + + # Returns the address in compact, human-readable format like + # 2001:db8:8:66::1 + toString: -> + stringParts = (part.toString(16) for part in @parts) + + compactStringParts = [] + pushPart = (part) -> compactStringParts.push part + + state = 0 + for part in stringParts + switch state + when 0 + if part == '0' + pushPart('') + else + pushPart(part) + + state = 1 + when 1 + if part == '0' + state = 2 + else + pushPart(part) + when 2 + unless part == '0' + pushPart('') + pushPart(part) + state = 3 + when 3 + pushPart(part) + + if state == 2 + pushPart('') + pushPart('') + + return compactStringParts.join ":" + + # Returns an array of byte-sized values in network order + toByteArray: -> + bytes = [] + for part in @parts + bytes.push(part >> 8) + bytes.push(part & 0xff) + + return bytes + + # Returns the address in expanded format with all zeroes included, like + # 2001:db8:8:66:0:0:0:1 + toNormalizedString: -> + return (part.toString(16) for part in @parts).join ":" + + # Checks if this address matches other one within given CIDR range. + match: (other, cidrRange) -> + if other.kind() != 'ipv6' + throw new Error "ipaddr: cannot match ipv6 address with non-ipv6 one" + + return matchCIDR(this.parts, other.parts, 16, cidrRange) + + # Special IPv6 ranges + SpecialRanges: + unspecified: [ new IPv6([0, 0, 0, 0, 0, 0, 0, 0]), 128 ] # RFC4291, here and after + linkLocal: [ new IPv6([0xfe80, 0, 0, 0, 0, 0, 0, 0]), 10 ] + multicast: [ new IPv6([0xff00, 0, 0, 0, 0, 0, 0, 0]), 8 ] + loopback: [ new IPv6([0, 0, 0, 0, 0, 0, 0, 1]), 128 ] + uniqueLocal: [ new IPv6([0xfc00, 0, 0, 0, 0, 0, 0, 0]), 7 ] + ipv4Mapped: [ new IPv6([0, 0, 0, 0, 0, 0xffff, 0, 0]), 96 ] + rfc6145: [ new IPv6([0, 0, 0, 0, 0xffff, 0, 0, 0]), 96 ] # RFC6145 + rfc6052: [ new IPv6([0x64, 0xff9b, 0, 0, 0, 0, 0, 0]), 96 ] # RFC6052 + '6to4': [ new IPv6([0x2002, 0, 0, 0, 0, 0, 0, 0]), 16 ] # RFC3056 + teredo: [ new IPv6([0x2001, 0, 0, 0, 0, 0, 0, 0]), 32 ] # RFC6052, RFC6146 + reserved: [ + [ new IPv6([ 0x2001, 0xdb8, 0, 0, 0, 0, 0, 0]), 32 ] # RFC4291 + ] + + # Checks if the address corresponds to one of the special ranges. + range: -> + return ipaddr.subnetMatch(this, @SpecialRanges) + + # Checks if this address is an IPv4-mapped IPv6 address. + isIPv4MappedAddress: -> + return @range() == 'ipv4Mapped' + + # Converts this address to IPv4 address if it is an IPv4-mapped IPv6 address. + # Throws an error otherwise. + toIPv4Address: -> + unless @isIPv4MappedAddress() + throw new Error "ipaddr: trying to convert a generic ipv6 address to ipv4" + + [high, low] = @parts[-2..-1] + + return new ipaddr.IPv4([high >> 8, high & 0xff, low >> 8, low & 0xff]) + +# IPv6-matching regular expressions. +# For IPv6, the task is simpler: it is enough to match the colon-delimited +# hexadecimal IPv6 and a transitional variant with dotted-decimal IPv4 at +# the end. +ipv6Part = "(?:[0-9a-f]+::?)+" +ipv6Regexes = + native: new RegExp "^(::)?(#{ipv6Part})?([0-9a-f]+)?(::)?$", 'i' + transitional: new RegExp "^((?:#{ipv6Part})|(?:::)(?:#{ipv6Part})?)" + + "#{ipv4Part}\\.#{ipv4Part}\\.#{ipv4Part}\\.#{ipv4Part}$", 'i' + +# Expand :: in an IPv6 address or address part consisting of `parts` groups. +expandIPv6 = (string, parts) -> + # More than one '::' means invalid adddress + if string.indexOf('::') != string.lastIndexOf('::') + return null + + # How many parts do we already have? + colonCount = 0 + lastColon = -1 + while (lastColon = string.indexOf(':', lastColon + 1)) >= 0 + colonCount++ + + # 0::0 is two parts more than :: + colonCount-- if string[0] == ':' + colonCount-- if string[string.length-1] == ':' + + # replacement = ':' + '0:' * (parts - colonCount) + replacementCount = parts - colonCount + replacement = ':' + while replacementCount-- + replacement += '0:' + + # Insert the missing zeroes + string = string.replace('::', replacement) + + # Trim any garbage which may be hanging around if :: was at the edge in + # the source string + string = string[1..-1] if string[0] == ':' + string = string[0..-2] if string[string.length-1] == ':' + + return (parseInt(part, 16) for part in string.split(":")) + +# Parse an IPv6 address. +ipaddr.IPv6.parser = (string) -> + if string.match(ipv6Regexes['native']) + return expandIPv6(string, 8) + + else if match = string.match(ipv6Regexes['transitional']) + parts = expandIPv6(match[1][0..-2], 6) + if parts + parts.push(parseInt(match[2]) << 8 | parseInt(match[3])) + parts.push(parseInt(match[4]) << 8 | parseInt(match[5])) + return parts + + return null + +# Checks if a given string is formatted like IPv4/IPv6 address. +ipaddr.IPv4.isIPv4 = ipaddr.IPv6.isIPv6 = (string) -> + return @parser(string) != null + +# Checks if a given string is a valid IPv4/IPv6 address. +ipaddr.IPv4.isValid = ipaddr.IPv6.isValid = (string) -> + try + new this(@parser(string)) + return true + catch e + return false + +# Tries to parse and validate a string with IPv4/IPv6 address. +# Throws an error if it fails. +ipaddr.IPv4.parse = ipaddr.IPv6.parse = (string) -> + parts = @parser(string) + if parts == null + throw new Error "ipaddr: string is not formatted like ip address" + + return new this(parts) + +# Checks if the address is valid IP address +ipaddr.isValid = (string) -> + return ipaddr.IPv6.isValid(string) || ipaddr.IPv4.isValid(string) + +# Try to parse an address and throw an error if it is impossible +ipaddr.parse = (string) -> + if ipaddr.IPv6.isIPv6(string) + return ipaddr.IPv6.parse(string) + else if ipaddr.IPv4.isIPv4(string) + return ipaddr.IPv4.parse(string) + else + throw new Error "ipaddr: the address has neither IPv6 nor IPv4 format" + +# Parse an address and return plain IPv4 address if it is an IPv4-mapped address +ipaddr.process = (string) -> + addr = @parse(string) + if addr.kind() == 'ipv6' && addr.isIPv4MappedAddress() + return addr.toIPv4Address() + else + return addr diff --git a/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/test/ipaddr.test.coffee b/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/test/ipaddr.test.coffee new file mode 100644 index 0000000..56751da --- /dev/null +++ b/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/test/ipaddr.test.coffee @@ -0,0 +1,209 @@ +ipaddr = require '../lib/ipaddr' + +module.exports = + 'should define main classes': (test) -> + test.ok(ipaddr.IPv4?, 'defines IPv4 class') + test.ok(ipaddr.IPv6?, 'defines IPv6 class') + test.done() + + 'can construct IPv4 from octets': (test) -> + test.doesNotThrow -> + new ipaddr.IPv4([192, 168, 1, 2]) + test.done() + + 'refuses to construct invalid IPv4': (test) -> + test.throws -> + new ipaddr.IPv4([300, 1, 2, 3]) + test.throws -> + new ipaddr.IPv4([8, 8, 8]) + test.done() + + 'converts IPv4 to string correctly': (test) -> + addr = new ipaddr.IPv4([192, 168, 1, 1]) + test.equal(addr.toString(), '192.168.1.1') + test.done() + + 'returns correct kind for IPv4': (test) -> + addr = new ipaddr.IPv4([1, 2, 3, 4]) + test.equal(addr.kind(), 'ipv4') + test.done() + + 'allows to access IPv4 octets': (test) -> + addr = new ipaddr.IPv4([42, 0, 0, 0]) + test.equal(addr.octets[0], 42) + test.done() + + 'checks IPv4 address format': (test) -> + test.equal(ipaddr.IPv4.isIPv4('192.168.007.0xa'), true) + test.equal(ipaddr.IPv4.isIPv4('1024.0.0.1'), true) + test.equal(ipaddr.IPv4.isIPv4('8.0xa.wtf.6'), false) + test.done() + + 'validates IPv4 addresses': (test) -> + test.equal(ipaddr.IPv4.isValid('192.168.007.0xa'), true) + test.equal(ipaddr.IPv4.isValid('1024.0.0.1'), false) + test.equal(ipaddr.IPv4.isValid('8.0xa.wtf.6'), false) + test.done() + + 'parses IPv4 in several weird formats': (test) -> + test.deepEqual(ipaddr.IPv4.parse('192.168.1.1').octets, [192, 168, 1, 1]) + test.deepEqual(ipaddr.IPv4.parse('0xc0.168.1.1').octets, [192, 168, 1, 1]) + test.deepEqual(ipaddr.IPv4.parse('192.0250.1.1').octets, [192, 168, 1, 1]) + test.deepEqual(ipaddr.IPv4.parse('0xc0a80101').octets, [192, 168, 1, 1]) + test.deepEqual(ipaddr.IPv4.parse('030052000401').octets, [192, 168, 1, 1]) + test.deepEqual(ipaddr.IPv4.parse('3232235777').octets, [192, 168, 1, 1]) + test.done() + + 'barfs at invalid IPv4': (test) -> + test.throws -> + ipaddr.IPv4.parse('10.0.0.wtf') + test.done() + + 'matches IPv4 CIDR correctly': (test) -> + addr = new ipaddr.IPv4([10, 5, 0, 1]) + test.equal(addr.match(ipaddr.IPv4.parse('0.0.0.0'), 0), true) + test.equal(addr.match(ipaddr.IPv4.parse('11.0.0.0'), 8), false) + test.equal(addr.match(ipaddr.IPv4.parse('10.0.0.0'), 8), true) + test.equal(addr.match(ipaddr.IPv4.parse('10.0.0.1'), 8), true) + test.equal(addr.match(ipaddr.IPv4.parse('10.0.0.10'), 8), true) + test.equal(addr.match(ipaddr.IPv4.parse('10.5.5.0'), 16), true) + test.equal(addr.match(ipaddr.IPv4.parse('10.4.5.0'), 16), false) + test.equal(addr.match(ipaddr.IPv4.parse('10.4.5.0'), 15), true) + test.equal(addr.match(ipaddr.IPv4.parse('10.5.0.2'), 32), false) + test.equal(addr.match(addr, 32), true) + test.done() + + 'detects reserved IPv4 networks': (test) -> + test.equal(ipaddr.IPv4.parse('10.1.0.1').range(), 'private') + test.equal(ipaddr.IPv4.parse('192.168.2.1').range(), 'private') + test.equal(ipaddr.IPv4.parse('224.100.0.1').range(), 'multicast') + test.equal(ipaddr.IPv4.parse('169.254.15.0').range(), 'linkLocal') + test.equal(ipaddr.IPv4.parse('127.1.1.1').range(), 'loopback') + test.equal(ipaddr.IPv4.parse('255.255.255.255').range(), 'broadcast') + test.equal(ipaddr.IPv4.parse('240.1.2.3').range(), 'reserved') + test.equal(ipaddr.IPv4.parse('8.8.8.8').range(), 'unicast') + test.done() + + 'can construct IPv6 from parts': (test) -> + test.doesNotThrow -> + new ipaddr.IPv6([0x2001, 0xdb8, 0xf53a, 0, 0, 0, 0, 1]) + test.done() + + 'refuses to construct invalid IPv6': (test) -> + test.throws -> + new ipaddr.IPv6([0xfffff, 0, 0, 0, 0, 0, 0, 1]) + test.throws -> + new ipaddr.IPv6([0xfffff, 0, 0, 0, 0, 0, 1]) + test.done() + + 'converts IPv6 to string correctly': (test) -> + addr = new ipaddr.IPv6([0x2001, 0xdb8, 0xf53a, 0, 0, 0, 0, 1]) + test.equal(addr.toNormalizedString(), '2001:db8:f53a:0:0:0:0:1') + test.equal(addr.toString(), '2001:db8:f53a::1') + test.equal(new ipaddr.IPv6([0, 0, 0, 0, 0, 0, 0, 1]).toString(), '::1') + test.equal(new ipaddr.IPv6([0x2001, 0xdb8, 0, 0, 0, 0, 0, 0]).toString(), '2001:db8::') + test.done() + + 'returns correct kind for IPv6': (test) -> + addr = new ipaddr.IPv6([0x2001, 0xdb8, 0xf53a, 0, 0, 0, 0, 1]) + test.equal(addr.kind(), 'ipv6') + test.done() + + 'allows to access IPv6 address parts': (test) -> + addr = new ipaddr.IPv6([0x2001, 0xdb8, 0xf53a, 0, 0, 42, 0, 1]) + test.equal(addr.parts[5], 42) + test.done() + + 'checks IPv6 address format': (test) -> + test.equal(ipaddr.IPv6.isIPv6('2001:db8:F53A::1'), true) + test.equal(ipaddr.IPv6.isIPv6('200001::1'), true) + test.equal(ipaddr.IPv6.isIPv6('::ffff:192.168.1.1'), true) + test.equal(ipaddr.IPv6.isIPv6('::ffff:300.168.1.1'), true) + test.equal(ipaddr.IPv6.isIPv6('::ffff:300.168.1.1:0'), false) + test.equal(ipaddr.IPv6.isIPv6('fe80::wtf'), false) + test.done() + + 'validates IPv6 addresses': (test) -> + test.equal(ipaddr.IPv6.isValid('2001:db8:F53A::1'), true) + test.equal(ipaddr.IPv6.isValid('200001::1'), false) + test.equal(ipaddr.IPv6.isValid('::ffff:192.168.1.1'), true) + test.equal(ipaddr.IPv6.isValid('::ffff:300.168.1.1'), false) + test.equal(ipaddr.IPv6.isValid('::ffff:300.168.1.1:0'), false) + test.equal(ipaddr.IPv6.isValid('2001:db8::F53A::1'), false) + test.equal(ipaddr.IPv6.isValid('fe80::wtf'), false) + test.done() + + 'parses IPv6 in different formats': (test) -> + test.deepEqual(ipaddr.IPv6.parse('2001:db8:F53A:0:0:0:0:1').parts, [0x2001, 0xdb8, 0xf53a, 0, 0, 0, 0, 1]) + test.deepEqual(ipaddr.IPv6.parse('fe80::10').parts, [0xfe80, 0, 0, 0, 0, 0, 0, 0x10]) + test.deepEqual(ipaddr.IPv6.parse('2001:db8:F53A::').parts, [0x2001, 0xdb8, 0xf53a, 0, 0, 0, 0, 0]) + test.deepEqual(ipaddr.IPv6.parse('::1').parts, [0, 0, 0, 0, 0, 0, 0, 1]) + test.deepEqual(ipaddr.IPv6.parse('::').parts, [0, 0, 0, 0, 0, 0, 0, 0]) + test.done() + + 'barfs at invalid IPv6': (test) -> + test.throws -> + ipaddr.IPv6.parse('fe80::0::1') + test.done() + + 'matches IPv6 CIDR correctly': (test) -> + addr = ipaddr.IPv6.parse('2001:db8:f53a::1') + test.equal(addr.match(ipaddr.IPv6.parse('::'), 0), true) + test.equal(addr.match(ipaddr.IPv6.parse('2001:db8:f53a::1:1'), 64), true) + test.equal(addr.match(ipaddr.IPv6.parse('2001:db8:f53b::1:1'), 48), false) + test.equal(addr.match(ipaddr.IPv6.parse('2001:db8:f531::1:1'), 44), true) + test.equal(addr.match(ipaddr.IPv6.parse('2001:db8:f500::1'), 40), true) + test.equal(addr.match(ipaddr.IPv6.parse('2001:db9:f500::1'), 40), false) + test.equal(addr.match(addr, 128), true) + test.done() + + 'converts between IPv4-mapped IPv6 addresses and IPv4 addresses': (test) -> + addr = ipaddr.IPv4.parse('77.88.21.11') + mapped = addr.toIPv4MappedAddress() + test.deepEqual(mapped.parts, [0, 0, 0, 0, 0, 0xffff, 0x4d58, 0x150b]) + test.deepEqual(mapped.toIPv4Address().octets, addr.octets) + test.done() + + 'refuses to convert non-IPv4-mapped IPv6 address to IPv4 address': (test) -> + test.throws -> + ipaddr.IPv6.parse('2001:db8::1').toIPv4Address() + test.done() + + 'detects reserved IPv6 networks': (test) -> + test.equal(ipaddr.IPv6.parse('::').range(), 'unspecified') + test.equal(ipaddr.IPv6.parse('fe80::1234:5678:abcd:0123').range(), 'linkLocal') + test.equal(ipaddr.IPv6.parse('ff00::1234').range(), 'multicast') + test.equal(ipaddr.IPv6.parse('::1').range(), 'loopback') + test.equal(ipaddr.IPv6.parse('fc00::').range(), 'uniqueLocal') + test.equal(ipaddr.IPv6.parse('::ffff:192.168.1.10').range(), 'ipv4Mapped') + test.equal(ipaddr.IPv6.parse('::ffff:0:192.168.1.10').range(), 'rfc6145') + test.equal(ipaddr.IPv6.parse('64:ff9b::1234').range(), 'rfc6052') + test.equal(ipaddr.IPv6.parse('2002:1f63:45e8::1').range(), '6to4') + test.equal(ipaddr.IPv6.parse('2001::4242').range(), 'teredo') + test.equal(ipaddr.IPv6.parse('2001:db8::3210').range(), 'reserved') + test.equal(ipaddr.IPv6.parse('2001:470:8:66::1').range(), 'unicast') + test.done() + + 'is able to determine IP address type': (test) -> + test.equal(ipaddr.parse('8.8.8.8').kind(), 'ipv4') + test.equal(ipaddr.parse('2001:db8:3312::1').kind(), 'ipv6') + test.done() + + 'throws an error if tried to parse an invalid address': (test) -> + test.throws -> + ipaddr.parse('::some.nonsense') + test.done() + + 'correctly processes IPv4-mapped addresses': (test) -> + test.equal(ipaddr.process('8.8.8.8').kind(), 'ipv4') + test.equal(ipaddr.process('2001:db8:3312::1').kind(), 'ipv6') + test.equal(ipaddr.process('::ffff:192.168.1.1').kind(), 'ipv4') + test.done() + + 'correctly converts IPv6 and IPv4 addresses to byte arrays': (test) -> + test.deepEqual(ipaddr.parse('1.2.3.4').toByteArray(), + [0x1, 0x2, 0x3, 0x4]); + # Fuck yeah. The first byte of Google's IPv6 address is 42. 42! + test.deepEqual(ipaddr.parse('2a00:1450:8007::68').toByteArray(), + [42, 0x00, 0x14, 0x50, 0x80, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x68 ]) + test.done() diff --git a/node_modules/express/node_modules/proxy-addr/package.json b/node_modules/express/node_modules/proxy-addr/package.json new file mode 100644 index 0000000..8c63b83 --- /dev/null +++ b/node_modules/express/node_modules/proxy-addr/package.json @@ -0,0 +1,89 @@ +{ + "name": "proxy-addr", + "description": "Determine address of proxied request", + "version": "1.0.2", + "author": { + "name": "Douglas Christopher Wilson", + "email": "doug@somethingdoug.com" + }, + "license": "MIT", + "keywords": [ + "ip", + "proxy", + "x-forwarded-for" + ], + "repository": { + "type": "git", + "url": "https://github.com/jshttp/proxy-addr" + }, + "dependencies": { + "ipaddr.js": "0.1.3" + }, + "devDependencies": { + "benchmark": "1.0.0", + "beautify-benchmark": "0.2.4", + "istanbul": "0.3.2", + "mocha": "~1.21.4", + "should": "~4.0.0" + }, + "files": [ + "LICENSE", + "HISTORY.md", + "README.md", + "index.js" + ], + "engines": { + "node": ">= 0.6" + }, + "scripts": { + "bench": "node benchmark/index.js", + "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/" + }, + "gitHead": "63a0f679bd4b074b7391fa464cb779275f24b1da", + "bugs": { + "url": "https://github.com/jshttp/proxy-addr/issues" + }, + "homepage": "https://github.com/jshttp/proxy-addr", + "_id": "proxy-addr@1.0.2", + "_shasum": "b322f905aa4f4bd3ce60550295eabbbb07c92143", + "_from": "proxy-addr@~1.0.2", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + "maintainers": [ + { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + }, + { + "name": "shtylman", + "email": "shtylman@gmail.com" + }, + { + "name": "tjholowaychuk", + "email": "tj@vision-media.ca" + }, + { + "name": "mscdex", + "email": "mscdex@mscdex.net" + }, + { + "name": "fishrock123", + "email": "fishrock123@rocketmail.com" + } + ], + "dist": { + "shasum": "b322f905aa4f4bd3ce60550295eabbbb07c92143", + "tarball": "http://registry.npmjs.org/proxy-addr/-/proxy-addr-1.0.2.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/proxy-addr/-/proxy-addr-1.0.2.tgz" +} diff --git a/node_modules/express/node_modules/qs/.jshintignore b/node_modules/express/node_modules/qs/.jshintignore new file mode 100644 index 0000000..3c3629e --- /dev/null +++ b/node_modules/express/node_modules/qs/.jshintignore @@ -0,0 +1 @@ +node_modules diff --git a/node_modules/express/node_modules/qs/.jshintrc b/node_modules/express/node_modules/qs/.jshintrc new file mode 100644 index 0000000..997b3f7 --- /dev/null +++ b/node_modules/express/node_modules/qs/.jshintrc @@ -0,0 +1,10 @@ +{ + "node": true, + + "curly": true, + "latedef": true, + "quotmark": true, + "undef": true, + "unused": true, + "trailing": true +} diff --git a/node_modules/express/node_modules/qs/.npmignore b/node_modules/express/node_modules/qs/.npmignore new file mode 100644 index 0000000..7e1574d --- /dev/null +++ b/node_modules/express/node_modules/qs/.npmignore @@ -0,0 +1,18 @@ +.idea +*.iml +npm-debug.log +dump.rdb +node_modules +results.tap +results.xml +npm-shrinkwrap.json +config.json +.DS_Store +*/.DS_Store +*/*/.DS_Store +._* +*/._* +*/*/._* +coverage.* +lib-cov +complexity.md diff --git a/node_modules/express/node_modules/qs/.travis.yml b/node_modules/express/node_modules/qs/.travis.yml new file mode 100644 index 0000000..c891dd0 --- /dev/null +++ b/node_modules/express/node_modules/qs/.travis.yml @@ -0,0 +1,4 @@ +language: node_js + +node_js: + - 0.10 \ No newline at end of file diff --git a/node_modules/express/node_modules/qs/CHANGELOG.md b/node_modules/express/node_modules/qs/CHANGELOG.md new file mode 100644 index 0000000..2f20704 --- /dev/null +++ b/node_modules/express/node_modules/qs/CHANGELOG.md @@ -0,0 +1,78 @@ + +## [**2.2.3**](https://github.com/hapijs/qs/issues?milestone=12&state=open) +- [**#37**](https://github.com/hapijs/qs/issues/37) parser discards first empty value in array +- [**#36**](https://github.com/hapijs/qs/issues/36) Update to lab 4.x + +## [**2.2.2**](https://github.com/hapijs/qs/issues?milestone=11&state=closed) +- [**#33**](https://github.com/hapijs/qs/issues/33) Error when plain object in a value +- [**#34**](https://github.com/hapijs/qs/issues/34) use Object.prototype.hasOwnProperty.call instead of obj.hasOwnProperty +- [**#24**](https://github.com/hapijs/qs/issues/24) Changelog? Semver? + +--- + + + +## [**2.2.2**](https://github.com/hapijs/qs/issues?milestone=11&state=closed) +- [**#33**](https://github.com/hapijs/qs/issues/33) Error when plain object in a value +- [**#34**](https://github.com/hapijs/qs/issues/34) use Object.prototype.hasOwnProperty.call instead of obj.hasOwnProperty +- [**#24**](https://github.com/hapijs/qs/issues/24) Changelog? Semver? + +--- + + + +## [**2.2.2**](https://github.com/hapijs/qs/issues?milestone=11&state=open) +- [**#34**](https://github.com/hapijs/qs/issues/34) use Object.prototype.hasOwnProperty.call instead of obj.hasOwnProperty +- [**#24**](https://github.com/hapijs/qs/issues/24) Changelog? Semver? + +--- + + +# 2014-08-28 +95 commits against 24 issues, over a month [`32edf33`](https://github.com/hapijs/qs/commit/32edf33)⎆[`b1e7b53`](https://github.com/hapijs/qs/commit/b1e7b53) + +## [**2.2.1**](https://github.com/hapijs/qs/issues?milestone=10&state=closed) +- [**#32**](https://github.com/hapijs/qs/issues/32) account for circular references properly, closes #31 +- [**#31**](https://github.com/hapijs/qs/issues/31) qs.parse stackoverflow on circular objects + +## [**2.2.0**](https://github.com/hapijs/qs/issues?milestone=9&state=closed) +- [**#30**](https://github.com/hapijs/qs/issues/30) Bug when merging non-object values into arrays +- [**#29**](https://github.com/hapijs/qs/issues/29) Don't call Utils.clone at the top of Utils.merge +- [**#26**](https://github.com/hapijs/qs/issues/26) Don't use Buffer global if it's not present +- [**#23**](https://github.com/hapijs/qs/issues/23) Ability to not limit parameters? + +## [**2.1.0**](https://github.com/hapijs/qs/issues?milestone=8&state=closed) +- [**#22**](https://github.com/hapijs/qs/issues/22) Enable using a RegExp as delimiter + +## [**2.0.0**](https://github.com/hapijs/qs/issues?milestone=7&state=closed) +- [**#20**](https://github.com/hapijs/qs/issues/20) Configurable parametersLimit +- [**#18**](https://github.com/hapijs/qs/issues/18) Why is there arrayLimit? +- [**#21**](https://github.com/hapijs/qs/issues/21) make all limits optional, for #18, for #20 + +## [**1.2.2**](https://github.com/hapijs/qs/issues?milestone=6&state=closed) +- [**#19**](https://github.com/hapijs/qs/issues/19) Don't overwrite null values + +## [**1.2.1**](https://github.com/hapijs/qs/issues?milestone=5&state=closed) +- [**#16**](https://github.com/hapijs/qs/issues/16) ignore non-string delimiters +- [**#15**](https://github.com/hapijs/qs/issues/15) Close code block + +## [**1.2.0**](https://github.com/hapijs/qs/issues?milestone=4&state=closed) +- [**#12**](https://github.com/hapijs/qs/issues/12) Add optional delim argument +- [**#13**](https://github.com/hapijs/qs/issues/13) fix #11: flattened keys in array are now correctly parsed + +## [**1.1.0**](https://github.com/hapijs/qs/issues?milestone=3&state=closed) +- [**#7**](https://github.com/hapijs/qs/issues/7) Empty values of a POST array disappear after being submitted +- [**#9**](https://github.com/hapijs/qs/issues/9) Should not omit equals signs (=) when value is null +- [**#6**](https://github.com/hapijs/qs/issues/6) Minor grammar fix in README + +## [**1.0.2**](https://github.com/hapijs/qs/issues?milestone=2&state=closed) +- [**#5**](https://github.com/hapijs/qs/issues/5) array holes incorrectly copied into object on large index + + +## Issues +- [**#25**](https://github.com/hapijs/qs/issues/25) Remove references to Buffer +- [**#11**](https://github.com/hapijs/qs/issues/11) Flattened keys in array does not parse correctly +- [**#8**](https://github.com/hapijs/qs/issues/8) Square brackets should be URI encoded +- [**#3**](https://github.com/hapijs/qs/issues/3) Update README.md +- [**#2**](https://github.com/hapijs/qs/issues/2) Add travis and rework package + diff --git a/node_modules/express/node_modules/qs/CONTRIBUTING.md b/node_modules/express/node_modules/qs/CONTRIBUTING.md new file mode 100644 index 0000000..8928361 --- /dev/null +++ b/node_modules/express/node_modules/qs/CONTRIBUTING.md @@ -0,0 +1 @@ +Please view our [hapijs contributing guide](https://github.com/hapijs/hapi/blob/master/CONTRIBUTING.md). diff --git a/node_modules/express/node_modules/qs/LICENSE b/node_modules/express/node_modules/qs/LICENSE new file mode 100755 index 0000000..d456948 --- /dev/null +++ b/node_modules/express/node_modules/qs/LICENSE @@ -0,0 +1,28 @@ +Copyright (c) 2014 Nathan LaFreniere and other contributors. +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + * Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + * The names of any contributors may not be used to endorse or promote + products derived from this software without specific prior written + permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND +ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS AND CONTRIBUTORS BE LIABLE FOR ANY +DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND +ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + + * * * + +The complete list of contributors can be found at: https://github.com/hapijs/qs/graphs/contributors diff --git a/node_modules/express/node_modules/qs/Makefile b/node_modules/express/node_modules/qs/Makefile new file mode 100644 index 0000000..600a700 --- /dev/null +++ b/node_modules/express/node_modules/qs/Makefile @@ -0,0 +1,8 @@ +test: + @node node_modules/lab/bin/lab +test-cov: + @node node_modules/lab/bin/lab -t 100 +test-cov-html: + @node node_modules/lab/bin/lab -r html -o coverage.html + +.PHONY: test test-cov test-cov-html \ No newline at end of file diff --git a/node_modules/express/node_modules/qs/README.md b/node_modules/express/node_modules/qs/README.md new file mode 100755 index 0000000..a6f99ab --- /dev/null +++ b/node_modules/express/node_modules/qs/README.md @@ -0,0 +1,213 @@ +# qs + +A querystring parsing and stringifying library with some added security. + +[![Build Status](https://secure.travis-ci.org/hapijs/qs.svg)](http://travis-ci.org/hapijs/qs) + +Lead Maintainer: [Nathan LaFreniere](https://github.com/nlf) + +The **qs** module was originally created and maintained by [TJ Holowaychuk](https://github.com/visionmedia/node-querystring). + +## Usage + +```javascript +var Qs = require('qs'); + +var obj = Qs.parse('a=c'); // { a: 'c' } +var str = Qs.stringify(obj); // 'a=c' +``` + +### Parsing Objects + +```javascript +Qs.parse(string, [options]); +``` + +**qs** allows you to create nested objects within your query strings, by surrounding the name of sub-keys with square brackets `[]`. +For example, the string `'foo[bar]=baz'` converts to: + +```javascript +{ + foo: { + bar: 'baz' + } +} +``` + +URI encoded strings work too: + +```javascript +Qs.parse('a%5Bb%5D=c'); +// { a: { b: 'c' } } +``` + +You can also nest your objects, like `'foo[bar][baz]=foobarbaz'`: + +```javascript +{ + foo: { + bar: { + baz: 'foobarbaz' + } + } +} +``` + +By default, when nesting objects **qs** will only parse up to 5 children deep. This means if you attempt to parse a string like +`'a[b][c][d][e][f][g][h][i]=j'` your resulting object will be: + +```javascript +{ + a: { + b: { + c: { + d: { + e: { + f: { + '[g][h][i]': 'j' + } + } + } + } + } + } +} +``` + +This depth can be overridden by passing a `depth` option to `Qs.parse(string, [options])`: + +```javascript +Qs.parse('a[b][c][d][e][f][g][h][i]=j', { depth: 1 }); +// { a: { b: { '[c][d][e][f][g][h][i]': 'j' } } } +``` + +The depth limit helps mitigate abuse when **qs** is used to parse user input, and it is recommended to keep it a reasonably small number. + +For similar reasons, by default **qs** will only parse up to 1000 parameters. This can be overridden by passing a `parameterLimit` option: + +```javascript +Qs.parse('a=b&c=d', { parameterLimit: 1 }); +// { a: 'b' } +``` + +An optional delimiter can also be passed: + +```javascript +Qs.parse('a=b;c=d', { delimiter: ';' }); +// { a: 'b', c: 'd' } +``` + +Delimiters can be a regular expression too: + +```javascript +Qs.parse('a=b;c=d,e=f', { delimiter: /[;,]/ }); +// { a: 'b', c: 'd', e: 'f' } +``` + +### Parsing Arrays + +**qs** can also parse arrays using a similar `[]` notation: + +```javascript +Qs.parse('a[]=b&a[]=c'); +// { a: ['b', 'c'] } +``` + +You may specify an index as well: + +```javascript +Qs.parse('a[1]=c&a[0]=b'); +// { a: ['b', 'c'] } +``` + +Note that the only difference between an index in an array and a key in an object is that the value between the brackets must be a number +to create an array. When creating arrays with specific indices, **qs** will compact a sparse array to only the existing values preserving +their order: + +```javascript +Qs.parse('a[1]=b&a[15]=c'); +// { a: ['b', 'c'] } +``` + +Note that an empty string is also a value, and will be preserved: + +```javascript +Qs.parse('a[]=&a[]=b'); +// { a: ['', 'b'] } +Qs.parse('a[0]=b&a[1]=&a[2]=c'); +// { a: ['b', '', 'c'] } +``` + +**qs** will also limit specifying indices in an array to a maximum index of `20`. Any array members with an index of greater than `20` will +instead be converted to an object with the index as the key: + +```javascript +Qs.parse('a[100]=b'); +// { a: { '100': 'b' } } +``` + +This limit can be overridden by passing an `arrayLimit` option: + +```javascript +Qs.parse('a[1]=b', { arrayLimit: 0 }); +// { a: { '1': 'b' } } +``` + +If you mix notations, **qs** will merge the two items into an object: + +```javascript +Qs.parse('a[0]=b&a[b]=c'); +// { a: { '0': 'b', b: 'c' } } +``` + +You can also create arrays of objects: + +```javascript +Qs.parse('a[][b]=c'); +// { a: [{ b: 'c' }] } +``` + +### Stringifying + +```javascript +Qs.stringify(object, [options]); +``` + +When stringifying, **qs** always URI encodes output. Objects are stringified as you would expect: + +```javascript +Qs.stringify({ a: 'b' }); +// 'a=b' +Qs.stringify({ a: { b: 'c' } }); +// 'a%5Bb%5D=c' +``` + +Examples beyond this point will be shown as though the output is not URI encoded for clarity. Please note that the return values in these cases *will* be URI encoded during real usage. + +When arrays are stringified, they are always given explicit indices: + +```javascript +Qs.stringify({ a: ['b', 'c', 'd'] }); +// 'a[0]=b&a[1]=c&a[2]=d' +``` + +Empty strings and null values will omit the value, but the equals sign (=) remains in place: + +```javascript +Qs.stringify({ a: '' }); +// 'a=' +``` + +Properties that are set to `undefined` will be omitted entirely: + +```javascript +Qs.stringify({ a: null, b: undefined }); +// 'a=' +``` + +The delimiter may be overridden with stringify as well: + +```javascript +Qs.stringify({ a: 'b', c: 'd' }, { delimiter: ';' }); +// 'a=b;c=d' +``` diff --git a/node_modules/express/node_modules/qs/index.js b/node_modules/express/node_modules/qs/index.js new file mode 100644 index 0000000..bb0a047 --- /dev/null +++ b/node_modules/express/node_modules/qs/index.js @@ -0,0 +1 @@ +module.exports = require('./lib'); diff --git a/node_modules/express/node_modules/qs/lib/index.js b/node_modules/express/node_modules/qs/lib/index.js new file mode 100755 index 0000000..0e09493 --- /dev/null +++ b/node_modules/express/node_modules/qs/lib/index.js @@ -0,0 +1,15 @@ +// Load modules + +var Stringify = require('./stringify'); +var Parse = require('./parse'); + + +// Declare internals + +var internals = {}; + + +module.exports = { + stringify: Stringify, + parse: Parse +}; diff --git a/node_modules/express/node_modules/qs/lib/parse.js b/node_modules/express/node_modules/qs/lib/parse.js new file mode 100755 index 0000000..f2e0a0d --- /dev/null +++ b/node_modules/express/node_modules/qs/lib/parse.js @@ -0,0 +1,154 @@ +// Load modules + +var Utils = require('./utils'); + + +// Declare internals + +var internals = { + delimiter: '&', + depth: 5, + arrayLimit: 20, + parameterLimit: 1000 +}; + + +internals.parseValues = function (str, options) { + + var obj = {}; + var parts = str.split(options.delimiter, options.parameterLimit === Infinity ? undefined : options.parameterLimit); + + for (var i = 0, il = parts.length; i < il; ++i) { + var part = parts[i]; + var pos = part.indexOf(']=') === -1 ? part.indexOf('=') : part.indexOf(']=') + 1; + + if (pos === -1) { + obj[Utils.decode(part)] = ''; + } + else { + var key = Utils.decode(part.slice(0, pos)); + var val = Utils.decode(part.slice(pos + 1)); + + if (!obj.hasOwnProperty(key)) { + obj[key] = val; + } + else { + obj[key] = [].concat(obj[key]).concat(val); + } + } + } + + return obj; +}; + + +internals.parseObject = function (chain, val, options) { + + if (!chain.length) { + return val; + } + + var root = chain.shift(); + + var obj = {}; + if (root === '[]') { + obj = []; + obj = obj.concat(internals.parseObject(chain, val, options)); + } + else { + var cleanRoot = root[0] === '[' && root[root.length - 1] === ']' ? root.slice(1, root.length - 1) : root; + var index = parseInt(cleanRoot, 10); + if (!isNaN(index) && + root !== cleanRoot && + index <= options.arrayLimit) { + + obj = []; + obj[index] = internals.parseObject(chain, val, options); + } + else { + obj[cleanRoot] = internals.parseObject(chain, val, options); + } + } + + return obj; +}; + + +internals.parseKeys = function (key, val, options) { + + if (!key) { + return; + } + + // The regex chunks + + var parent = /^([^\[\]]*)/; + var child = /(\[[^\[\]]*\])/g; + + // Get the parent + + var segment = parent.exec(key); + + // Don't allow them to overwrite object prototype properties + + if (Object.prototype.hasOwnProperty(segment[1])) { + return; + } + + // Stash the parent if it exists + + var keys = []; + if (segment[1]) { + keys.push(segment[1]); + } + + // Loop through children appending to the array until we hit depth + + var i = 0; + while ((segment = child.exec(key)) !== null && i < options.depth) { + + ++i; + if (!Object.prototype.hasOwnProperty(segment[1].replace(/\[|\]/g, ''))) { + keys.push(segment[1]); + } + } + + // If there's a remainder, just add whatever is left + + if (segment) { + keys.push('[' + key.slice(segment.index) + ']'); + } + + return internals.parseObject(keys, val, options); +}; + + +module.exports = function (str, options) { + + if (str === '' || + str === null || + typeof str === 'undefined') { + + return {}; + } + + 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.parameterLimit = typeof options.parameterLimit === 'number' ? options.parameterLimit : internals.parameterLimit; + + var tempObj = typeof str === 'string' ? internals.parseValues(str, options) : str; + var obj = {}; + + // Iterate over the keys and setup the new object + + var keys = Object.keys(tempObj); + 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); + } + + return Utils.compact(obj); +}; diff --git a/node_modules/express/node_modules/qs/lib/stringify.js b/node_modules/express/node_modules/qs/lib/stringify.js new file mode 100755 index 0000000..582577a --- /dev/null +++ b/node_modules/express/node_modules/qs/lib/stringify.js @@ -0,0 +1,58 @@ +// Load modules + +var Utils = require('./utils'); + + +// Declare internals + +var internals = { + delimiter: '&' +}; + + +internals.stringify = function (obj, prefix) { + + if (Utils.isBuffer(obj)) { + obj = obj.toString(); + } + else if (obj instanceof Date) { + obj = obj.toISOString(); + } + else if (obj === null) { + obj = ''; + } + + if (typeof obj === 'string' || + typeof obj === 'number' || + typeof obj === 'boolean') { + + return [encodeURIComponent(prefix) + '=' + encodeURIComponent(obj)]; + } + + var values = []; + + for (var key in obj) { + if (obj.hasOwnProperty(key)) { + values = values.concat(internals.stringify(obj[key], prefix + '[' + key + ']')); + } + } + + return values; +}; + + +module.exports = function (obj, options) { + + options = options || {}; + var delimiter = typeof options.delimiter === 'undefined' ? internals.delimiter : options.delimiter; + + var keys = []; + + for (var key in obj) { + if (obj.hasOwnProperty(key)) { + keys = keys.concat(internals.stringify(obj[key], key)); + } + } + + return keys.join(delimiter); +}; diff --git a/node_modules/express/node_modules/qs/lib/utils.js b/node_modules/express/node_modules/qs/lib/utils.js new file mode 100755 index 0000000..c0b915d --- /dev/null +++ b/node_modules/express/node_modules/qs/lib/utils.js @@ -0,0 +1,139 @@ +// Load modules + + +// Declare internals + +var internals = {}; + + +exports.arrayToObject = function (source) { + + var obj = {}; + for (var i = 0, il = source.length; i < il; ++i) { + if (typeof source[i] !== 'undefined') { + + obj[i] = source[i]; + } + } + + return obj; +}; + + +exports.merge = function (target, source) { + + if (!source) { + return target; + } + + if (Array.isArray(source)) { + for (var i = 0, il = source.length; i < il; ++i) { + if (typeof source[i] !== 'undefined') { + if (typeof target[i] === 'object') { + target[i] = exports.merge(target[i], source[i]); + } + else { + target[i] = source[i]; + } + } + } + + return target; + } + + if (Array.isArray(target)) { + if (typeof source !== 'object') { + target.push(source); + return target; + } + else { + target = exports.arrayToObject(target); + } + } + + var keys = Object.keys(source); + for (var k = 0, kl = keys.length; k < kl; ++k) { + var key = keys[k]; + var value = source[key]; + + if (value && + typeof value === 'object') { + + if (!target[key]) { + target[key] = value; + } + else { + target[key] = exports.merge(target[key], value); + } + } + else { + target[key] = value; + } + } + + return target; +}; + + +exports.decode = function (str) { + + try { + return decodeURIComponent(str.replace(/\+/g, ' ')); + } catch (e) { + return str; + } +}; + + +exports.compact = function (obj, refs) { + + if (typeof obj !== 'object' || + obj === null) { + + return obj; + } + + refs = refs || []; + var lookup = refs.indexOf(obj); + if (lookup !== -1) { + return refs[lookup]; + } + + refs.push(obj); + + if (Array.isArray(obj)) { + var compacted = []; + + for (var i = 0, l = obj.length; i < l; ++i) { + if (typeof obj[i] !== 'undefined') { + compacted.push(obj[i]); + } + } + + return compacted; + } + + var keys = Object.keys(obj); + for (var i = 0, il = keys.length; i < il; ++i) { + var key = keys[i]; + obj[key] = exports.compact(obj[key], refs); + } + + return obj; +}; + + +exports.isRegExp = function (obj) { + return Object.prototype.toString.call(obj) === '[object RegExp]'; +}; + + +exports.isBuffer = function (obj) { + + if (typeof Buffer !== 'undefined') { + return Buffer.isBuffer(obj); + } + else { + return false; + } +}; diff --git a/node_modules/express/node_modules/qs/package.json b/node_modules/express/node_modules/qs/package.json new file mode 100755 index 0000000..01b285a --- /dev/null +++ b/node_modules/express/node_modules/qs/package.json @@ -0,0 +1,61 @@ +{ + "name": "qs", + "version": "2.2.3", + "description": "A querystring parser that supports nesting and arrays, with a depth limit", + "homepage": "https://github.com/hapijs/qs", + "main": "index.js", + "dependencies": {}, + "devDependencies": { + "lab": "4.x.x" + }, + "scripts": { + "test": "make test-cov" + }, + "repository": { + "type": "git", + "url": "https://github.com/hapijs/qs.git" + }, + "keywords": [ + "querystring", + "qs" + ], + "author": { + "name": "Nathan LaFreniere", + "email": "quitlahok@gmail.com" + }, + "licenses": [ + { + "type": "BSD", + "url": "http://github.com/hapijs/qs/raw/master/LICENSE" + } + ], + "gitHead": "904528124a6eb879ebc5197376e9613069414f67", + "bugs": { + "url": "https://github.com/hapijs/qs/issues" + }, + "_id": "qs@2.2.3", + "_shasum": "6139c1f47960eff5655e56aab0ef9f6dd16d4eeb", + "_from": "qs@2.2.3", + "_npmVersion": "1.4.23", + "_npmUser": { + "name": "nlf", + "email": "quitlahok@gmail.com" + }, + "maintainers": [ + { + "name": "nlf", + "email": "quitlahok@gmail.com" + }, + { + "name": "hueniverse", + "email": "eran@hueniverse.com" + } + ], + "dist": { + "shasum": "6139c1f47960eff5655e56aab0ef9f6dd16d4eeb", + "tarball": "http://registry.npmjs.org/qs/-/qs-2.2.3.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/qs/-/qs-2.2.3.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/express/node_modules/qs/test/parse.js b/node_modules/express/node_modules/qs/test/parse.js new file mode 100755 index 0000000..15a4888 --- /dev/null +++ b/node_modules/express/node_modules/qs/test/parse.js @@ -0,0 +1,385 @@ +// Load modules + +var Lab = require('lab'); +var Qs = require('../'); + + +// Declare internals + +var internals = {}; + + +// Test shortcuts + +var lab = exports.lab = Lab.script(); +var expect = Lab.expect; +var before = lab.before; +var after = lab.after; +var describe = lab.experiment; +var it = lab.test; + + +describe('#parse', function () { + + it('parses a simple string', function (done) { + + 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')).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('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' + }); + done(); + }); + + it('parses a single nested string', function (done) { + + 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' } } }); + 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' } } } } } } }); + 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' } } }); + 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'] }); + done(); + }); + + it('parses an explicit array', function (done) { + + 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 nested array', function (done) { + + 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'] }); + 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'] }); + expect(Qs.parse('a[21]=a')).to.deep.equal({ a: { '21': 'a' } }); + done(); + }); + + it('supports encoded = signs', function (done) { + + 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' } }); + 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"]' }); + expect(Qs.parse('operators=[">=", "<="]')).to.deep.equal({ operators: '[">=", "<="]' }); + done(); + }); + + it('allows empty values', function (done) { + + 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' } }); + 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('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' } }); + done(); + }); + + it('supports malformed uri characters', function (done) { + + 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' }); + done(); + }); + + it('cannot override prototypes', function (done) { + + var obj = Qs.parse('toString=bad&bad[toString]=bad&constructor=bad'); + expect(typeof obj.toString).to.equal('function'); + expect(typeof obj.bad.toString).to.equal('function'); + expect(typeof obj.constructor).to.equal('function'); + done(); + }); + + it('cannot access Object prototype', function (done) { + + Qs.parse('constructor[prototype][bad]=bad'); + Qs.parse('bad[constructor][prototype][bad]=bad'); + expect(typeof Object.prototype.bad).to.equal('undefined'); + done(); + }); + + it('parses arrays of objects', function (done) { + + 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'] }); + expect(Qs.parse('a[0]=b&a[1]=&a[2]=c&a[19]=')).to.deep.equal({ a: ['b', '', 'c', ''] }); + 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'] }); + done(); + }); + + it('parses semi-parsed strings', function (done) { + + 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 }); + done(); + }); + + it('continues parsing when no parent is found', function (done) { + + expect(Qs.parse('[]&a=b')).to.deep.equal({ '0': '', a: 'b' }); + expect(Qs.parse('[foo]=bar')).to.deep.equal({ foo: 'bar' }); + done(); + }); + + it('does not error when parsing a very long array', function (done) { + + var str = 'a[]=a'; + while (Buffer.byteLength(str) < 128 * 1024) { + str += '&' + str; + } + + expect(function () { + + Qs.parse(str); + }).to.not.throw(); + + done(); + }); + + it('should not throw when a native prototype has an enumerable property', { parallel: false }, function (done) { + + 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' }); + expect(Qs.parse.bind(null, 'a[][b]=c')).to.not.throw(); + expect(Qs.parse('a[][b]=c')).to.deep.equal({ a: [{ b: 'c' }] }); + delete Object.prototype.crash; + delete Array.prototype.crash; + done(); + }); + + 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' }); + 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' }); + 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' }); + done(); + }); + + it('allows overriding parameter limit', function (done) { + + 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' }); + done(); + }); + + it('allows overriding array limit', function (done) { + + expect(Qs.parse('a[0]=b&a[1]=c', { arrayLimit: 0 })).to.deep.equal({ a: { '0': 'b', '1': 'c' } }); + done(); + }); + + it('parses an object', function (done) { + + var input = { + "user[name]": {"pop[bob]": 3}, + "user[email]": null + }; + + var expected = { + "user": { + "name": {"pop[bob]": 3}, + "email": null + } + }; + + var result = Qs.parse(input); + + 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[email]": null + }; + + var expected = { + "user": { + "name": {"pop[bob]": { "test": 3 }}, + "email": null + } + }; + + var result = Qs.parse(input); + + expect(result).to.deep.equal(expected); + done(); + }); + + it('does not blow up when Buffer global is missing', function (done) { + + var tempBuffer = global.Buffer; + delete global.Buffer; + expect(Qs.parse('a=b&c=d')).to.deep.equal({ a: 'b', c: 'd' }); + global.Buffer = tempBuffer; + done(); + }); + + it('does not crash when using invalid dot notation', function (done) { + + expect(Qs.parse('roomInfoList[0].childrenAges[0]=15&roomInfoList[0].numberOfAdults=2')).to.deep.equal({ roomInfoList: [['15', '2']] }); + done(); + }); + + it('does not crash when parsing circular references', function (done) { + + var a = {}; + a.b = a; + + var parsed; + + expect(function () { + + parsed = Qs.parse({ 'foo[bar]': 'baz', 'foo[baz]': a }); + }).to.not.throw(Error); + + expect(parsed).to.have.key('foo'); + expect(parsed.foo).to.have.keys('bar', 'baz'); + expect(parsed.foo.bar).to.equal('baz'); + expect(parsed.foo.baz).to.deep.equal(a); + done(); + }); + + it('parses plain objects correctly', function (done) { + + var a = Object.create(null); + a.b = 'c'; + + expect(Qs.parse(a)).to.deep.equal({ b: 'c' }); + expect(Qs.parse({ a: a })).to.deep.equal({ a: { b: 'c' } }); + done(); + }); + + it('parses dates correctly', function (done) { + + var now = new Date(); + 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 }); + done(); + }); +}); diff --git a/node_modules/express/node_modules/qs/test/stringify.js b/node_modules/express/node_modules/qs/test/stringify.js new file mode 100755 index 0000000..b96b52b --- /dev/null +++ b/node_modules/express/node_modules/qs/test/stringify.js @@ -0,0 +1,139 @@ +// Load modules + +var Lab = require('lab'); +var Qs = require('../'); + + +// Declare internals + +var internals = {}; + + +// Test shortcuts + +var lab = exports.lab = Lab.script(); +var expect = Lab.expect; +var before = lab.before; +var after = lab.after; +var describe = lab.experiment; +var it = lab.test; + + +describe('#stringify', function () { + + it('stringifies a querystring object', function (done) { + + expect(Qs.stringify({ a: 'b' })).to.equal('a=b'); + expect(Qs.stringify({ a: 1 })).to.equal('a=1'); + expect(Qs.stringify({ a: 1, b: 2 })).to.equal('a=1&b=2'); + done(); + }); + + it('stringifies a nested object', function (done) { + + expect(Qs.stringify({ a: { b: 'c' } })).to.equal('a%5Bb%5D=c'); + expect(Qs.stringify({ a: { b: { c: { d: 'e' } } } })).to.equal('a%5Bb%5D%5Bc%5D%5Bd%5D=e'); + done(); + }); + + it('stringifies an array value', function (done) { + + expect(Qs.stringify({ a: ['b', 'c', 'd'] })).to.equal('a%5B0%5D=b&a%5B1%5D=c&a%5B2%5D=d'); + done(); + }); + + it('stringifies a nested array value', function (done) { + + expect(Qs.stringify({ a: { b: ['c', 'd'] } })).to.equal('a%5Bb%5D%5B0%5D=c&a%5Bb%5D%5B1%5D=d'); + done(); + }); + + it('stringifies an object inside an array', function (done) { + + expect(Qs.stringify({ a: [{ b: 'c' }] })).to.equal('a%5B0%5D%5Bb%5D=c'); + expect(Qs.stringify({ a: [{ b: { c: [1] } }] })).to.equal('a%5B0%5D%5Bb%5D%5Bc%5D%5B0%5D=1'); + done(); + }); + + it('stringifies a complicated object', function (done) { + + expect(Qs.stringify({ a: { b: 'c', d: 'e' } })).to.equal('a%5Bb%5D=c&a%5Bd%5D=e'); + done(); + }); + + it('stringifies an empty value', function (done) { + + expect(Qs.stringify({ a: '' })).to.equal('a='); + expect(Qs.stringify({ a: '', b: '' })).to.equal('a=&b='); + expect(Qs.stringify({ a: null })).to.equal('a='); + expect(Qs.stringify({ a: { b: null } })).to.equal('a%5Bb%5D='); + done(); + }); + + it('drops keys with a value of undefined', function (done) { + + expect(Qs.stringify({ a: undefined })).to.equal(''); + expect(Qs.stringify({ a: { b: undefined, c: null } })).to.equal('a%5Bc%5D='); + done(); + }); + + it('url encodes values', function (done) { + + expect(Qs.stringify({ a: 'b c' })).to.equal('a=b%20c'); + done(); + }); + + it('stringifies a date', function (done) { + + var now = new Date(); + var str = 'a=' + encodeURIComponent(now.toISOString()); + expect(Qs.stringify({ a: now })).to.equal(str); + done(); + }); + + it('stringifies the weird object from qs', function (done) { + + expect(Qs.stringify({ 'my weird field': 'q1!2"\'w$5&7/z8)?' })).to.equal('my%20weird%20field=q1!2%22\'w%245%267%2Fz8)%3F'); + done(); + }); + + 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: 'c' } })).to.equal('a%5Bb%5D=c'); + delete Object.prototype.crash; + done(); + }); + + it('stringifies boolean values', function (done) { + + expect(Qs.stringify({ a: true })).to.equal('a=true'); + expect(Qs.stringify({ a: { b: true } })).to.equal('a%5Bb%5D=true'); + expect(Qs.stringify({ b: false })).to.equal('b=false'); + expect(Qs.stringify({ b: { c: false } })).to.equal('b%5Bc%5D=false'); + done(); + }); + + it('stringifies buffer values', function (done) { + + expect(Qs.stringify({ a: new Buffer('test') })).to.equal('a=test'); + expect(Qs.stringify({ a: { b: new Buffer('test') } })).to.equal('a%5Bb%5D=test'); + done(); + }); + + it('stringifies an object using an alternative delimiter', function (done) { + + expect(Qs.stringify({ a: 'b', c: 'd' }, { delimiter: ';' })).to.equal('a=b;c=d'); + done(); + }); + + it('doesn\'t blow up when Buffer global is missing', function (done) { + + var tempBuffer = global.Buffer; + delete global.Buffer; + expect(Qs.stringify({ a: 'b', c: 'd' })).to.equal('a=b&c=d'); + global.Buffer = tempBuffer; + done(); + }); +}); diff --git a/node_modules/express/node_modules/range-parser/HISTORY.md b/node_modules/express/node_modules/range-parser/HISTORY.md new file mode 100644 index 0000000..1bb53bd --- /dev/null +++ b/node_modules/express/node_modules/range-parser/HISTORY.md @@ -0,0 +1,35 @@ +1.0.2 / 2014-09-08 +================== + + * Support Node.js 0.6 + +1.0.1 / 2014-09-07 +================== + + * Move repository to jshttp + +1.0.0 / 2013-12-11 +================== + + * Add repository to package.json + * Add MIT license + +0.0.4 / 2012-06-17 +================== + + * Change ret -1 for unsatisfiable and -2 when invalid + +0.0.3 / 2012-06-17 +================== + + * Fix last-byte-pos default to len - 1 + +0.0.2 / 2012-06-14 +================== + + * Add `.type` + +0.0.1 / 2012-06-11 +================== + + * Initial release diff --git a/node_modules/express/node_modules/range-parser/LICENSE b/node_modules/express/node_modules/range-parser/LICENSE new file mode 100644 index 0000000..a491841 --- /dev/null +++ b/node_modules/express/node_modules/range-parser/LICENSE @@ -0,0 +1,22 @@ +(The MIT License) + +Copyright (c) 2012-2014 TJ Holowaychuk + +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/node_modules/express/node_modules/range-parser/README.md b/node_modules/express/node_modules/range-parser/README.md new file mode 100644 index 0000000..6a2682f --- /dev/null +++ b/node_modules/express/node_modules/range-parser/README.md @@ -0,0 +1,48 @@ +# range-parser + +[![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] + +Range header field parser. + +## Installation + +``` +$ npm install range-parser +``` + +## Examples + +```js +assert(-1 == parse(200, 'bytes=500-20')); +assert(-2 == parse(200, 'bytes=malformed')); +parse(200, 'bytes=0-499').should.eql(arr('bytes', [{ start: 0, end: 199 }])); +parse(1000, 'bytes=0-499').should.eql(arr('bytes', [{ start: 0, end: 499 }])); +parse(1000, 'bytes=40-80').should.eql(arr('bytes', [{ start: 40, end: 80 }])); +parse(1000, 'bytes=-500').should.eql(arr('bytes', [{ start: 500, end: 999 }])); +parse(1000, 'bytes=-400').should.eql(arr('bytes', [{ start: 600, end: 999 }])); +parse(1000, 'bytes=500-').should.eql(arr('bytes', [{ start: 500, end: 999 }])); +parse(1000, 'bytes=400-').should.eql(arr('bytes', [{ start: 400, end: 999 }])); +parse(1000, 'bytes=0-0').should.eql(arr('bytes', [{ start: 0, end: 0 }])); +parse(1000, 'bytes=-1').should.eql(arr('bytes', [{ start: 999, end: 999 }])); +parse(1000, 'items=0-5').should.eql(arr('items', [{ start: 0, end: 5 }])); +parse(1000, 'bytes=40-80,-1').should.eql(arr('bytes', [{ start: 40, end: 80 }, { start: 999, end: 999 }])); +``` + +## License + +[MIT](LICENSE) + +[npm-image]: https://img.shields.io/npm/v/range-parser.svg?style=flat +[npm-url]: https://npmjs.org/package/range-parser +[node-version-image]: https://img.shields.io/badge/node.js-%3E%3D_0.6-brightgreen.svg?style=flat +[node-version-url]: http://nodejs.org/download/ +[travis-image]: https://img.shields.io/travis/jshttp/range-parser.svg?style=flat +[travis-url]: https://travis-ci.org/jshttp/range-parser +[coveralls-image]: https://img.shields.io/coveralls/jshttp/range-parser.svg?style=flat +[coveralls-url]: https://coveralls.io/r/jshttp/range-parser +[downloads-image]: https://img.shields.io/npm/dm/range-parser.svg?style=flat +[downloads-url]: https://npmjs.org/package/range-parser diff --git a/node_modules/express/node_modules/range-parser/index.js b/node_modules/express/node_modules/range-parser/index.js new file mode 100644 index 0000000..09a6c40 --- /dev/null +++ b/node_modules/express/node_modules/range-parser/index.js @@ -0,0 +1,49 @@ + +/** + * Parse "Range" header `str` relative to the given file `size`. + * + * @param {Number} size + * @param {String} str + * @return {Array} + * @api public + */ + +module.exports = function(size, str){ + var valid = true; + var i = str.indexOf('='); + + if (-1 == i) return -2; + + var arr = str.slice(i + 1).split(',').map(function(range){ + var range = range.split('-') + , start = parseInt(range[0], 10) + , end = parseInt(range[1], 10); + + // -nnn + if (isNaN(start)) { + start = size - end; + end = size - 1; + // nnn- + } else if (isNaN(end)) { + end = size - 1; + } + + // limit last-byte-pos to current length + if (end > size - 1) end = size - 1; + + // invalid + if (isNaN(start) + || isNaN(end) + || start > end + || start < 0) valid = false; + + return { + start: start, + end: end + }; + }); + + arr.type = str.slice(0, i); + + return valid ? arr : -1; +}; diff --git a/node_modules/express/node_modules/range-parser/package.json b/node_modules/express/node_modules/range-parser/package.json new file mode 100644 index 0000000..9fc243b --- /dev/null +++ b/node_modules/express/node_modules/range-parser/package.json @@ -0,0 +1,76 @@ +{ + "name": "range-parser", + "author": { + "name": "TJ Holowaychuk", + "email": "tj@vision-media.ca", + "url": "http://tjholowaychuk.com" + }, + "description": "Range header field string parser", + "version": "1.0.2", + "license": "MIT", + "keywords": [ + "range", + "parser", + "http" + ], + "repository": { + "type": "git", + "url": "https://github.com/jshttp/range-parser" + }, + "devDependencies": { + "istanbul": "0", + "mocha": "1", + "should": "2" + }, + "files": [ + "HISTORY.md", + "LICENSE", + "index.js" + ], + "engines": { + "node": ">= 0.6" + }, + "scripts": { + "test": "mocha --reporter spec --require should", + "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --require should", + "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter dot --require should" + }, + "gitHead": "ae23b02ce705b56e7f7c48e832d41fa710227ecc", + "bugs": { + "url": "https://github.com/jshttp/range-parser/issues" + }, + "homepage": "https://github.com/jshttp/range-parser", + "_id": "range-parser@1.0.2", + "_shasum": "06a12a42e5131ba8e457cd892044867f2344e549", + "_from": "range-parser@~1.0.2", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + "maintainers": [ + { + "name": "tjholowaychuk", + "email": "tj@vision-media.ca" + }, + { + "name": "jonathanong", + "email": "jonathanrichardong@gmail.com" + }, + { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + } + ], + "dist": { + "shasum": "06a12a42e5131ba8e457cd892044867f2344e549", + "tarball": "http://registry.npmjs.org/range-parser/-/range-parser-1.0.2.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/range-parser/-/range-parser-1.0.2.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/express/node_modules/send/History.md b/node_modules/express/node_modules/send/History.md new file mode 100644 index 0000000..02d912e --- /dev/null +++ b/node_modules/express/node_modules/send/History.md @@ -0,0 +1,199 @@ +0.9.2 / 2014-09-15 +================== + + * deps: depd@0.4.5 + * deps: etag@~1.3.1 + * deps: range-parser@~1.0.2 + +0.9.1 / 2014-09-07 +================== + + * deps: fresh@0.2.4 + +0.9.0 / 2014-09-07 +================== + + * Add `lastModified` option + * Use `etag` to generate `ETag` header + * deps: debug@~2.0.0 + +0.8.5 / 2014-09-04 +================== + + * Fix malicious path detection for empty string path + +0.8.4 / 2014-09-04 +================== + + * Fix a path traversal issue when using `root` + +0.8.3 / 2014-08-16 +================== + + * deps: destroy@1.0.3 + - renamed from dethroy + * deps: on-finished@2.1.0 + +0.8.2 / 2014-08-14 +================== + + * Work around `fd` leak in Node.js 0.10 for `fs.ReadStream` + * deps: dethroy@1.0.2 + +0.8.1 / 2014-08-05 +================== + + * Fix `extensions` behavior when file already has extension + +0.8.0 / 2014-08-05 +================== + + * Add `extensions` option + +0.7.4 / 2014-08-04 +================== + + * Fix serving index files without root dir + +0.7.3 / 2014-07-29 +================== + + * Fix incorrect 403 on Windows and Node.js 0.11 + +0.7.2 / 2014-07-27 +================== + + * deps: depd@0.4.4 + - Work-around v8 generating empty stack traces + +0.7.1 / 2014-07-26 +================== + + * deps: depd@0.4.3 + - Fix exception when global `Error.stackTraceLimit` is too low + +0.7.0 / 2014-07-20 +================== + + * Deprecate `hidden` option; use `dotfiles` option + * Add `dotfiles` option + * deps: debug@1.0.4 + * deps: depd@0.4.2 + - Add `TRACE_DEPRECATION` environment variable + - Remove non-standard grey color from color output + - Support `--no-deprecation` argument + - Support `--trace-deprecation` argument + +0.6.0 / 2014-07-11 +================== + + * Deprecate `from` option; use `root` option + * Deprecate `send.etag()` -- use `etag` in `options` + * Deprecate `send.hidden()` -- use `hidden` in `options` + * Deprecate `send.index()` -- use `index` in `options` + * Deprecate `send.maxage()` -- use `maxAge` in `options` + * Deprecate `send.root()` -- use `root` in `options` + * Cap `maxAge` value to 1 year + * deps: debug@1.0.3 + - Add support for multiple wildcards in namespaces + +0.5.0 / 2014-06-28 +================== + + * Accept string for `maxAge` (converted by `ms`) + * Add `headers` event + * Include link in default redirect response + * Use `EventEmitter.listenerCount` to count listeners + +0.4.3 / 2014-06-11 +================== + + * Do not throw un-catchable error on file open race condition + * Use `escape-html` for HTML escaping + * deps: debug@1.0.2 + - fix some debugging output colors on node.js 0.8 + * deps: finished@1.2.2 + * deps: fresh@0.2.2 + +0.4.2 / 2014-06-09 +================== + + * fix "event emitter leak" warnings + * deps: debug@1.0.1 + * deps: finished@1.2.1 + +0.4.1 / 2014-06-02 +================== + + * Send `max-age` in `Cache-Control` in correct format + +0.4.0 / 2014-05-27 +================== + + * Calculate ETag with md5 for reduced collisions + * Fix wrong behavior when index file matches directory + * Ignore stream errors after request ends + - Goodbye `EBADF, read` + * Skip directories in index file search + * deps: debug@0.8.1 + +0.3.0 / 2014-04-24 +================== + + * Fix sending files with dots without root set + * Coerce option types + * Accept API options in options object + * Set etags to "weak" + * Include file path in etag + * Make "Can't set headers after they are sent." catchable + * Send full entity-body for multi range requests + * Default directory access to 403 when index disabled + * Support multiple index paths + * Support "If-Range" header + * Control whether to generate etags + * deps: mime@1.2.11 + +0.2.0 / 2014-01-29 +================== + + * update range-parser and fresh + +0.1.4 / 2013-08-11 +================== + + * update fresh + +0.1.3 / 2013-07-08 +================== + + * Revert "Fix fd leak" + +0.1.2 / 2013-07-03 +================== + + * Fix fd leak + +0.1.0 / 2012-08-25 +================== + + * add options parameter to send() that is passed to fs.createReadStream() [kanongil] + +0.0.4 / 2012-08-16 +================== + + * allow custom "Accept-Ranges" definition + +0.0.3 / 2012-07-16 +================== + + * fix normalization of the root directory. Closes #3 + +0.0.2 / 2012-07-09 +================== + + * add passing of req explicitly for now (YUCK) + +0.0.1 / 2010-01-03 +================== + + * Initial release diff --git a/node_modules/express/node_modules/send/LICENSE b/node_modules/express/node_modules/send/LICENSE new file mode 100644 index 0000000..3b87e2d --- /dev/null +++ b/node_modules/express/node_modules/send/LICENSE @@ -0,0 +1,23 @@ +(The MIT License) + +Copyright (c) 2012 TJ Holowaychuk +Copyright (c) 2014 Douglas Christopher Wilson + +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/node_modules/express/node_modules/send/Readme.md b/node_modules/express/node_modules/send/Readme.md new file mode 100644 index 0000000..aa83608 --- /dev/null +++ b/node_modules/express/node_modules/send/Readme.md @@ -0,0 +1,182 @@ +# send + +[![NPM Version][npm-image]][npm-url] +[![NPM Downloads][downloads-image]][downloads-url] +[![Build Status][travis-image]][travis-url] +[![Test Coverage][coveralls-image]][coveralls-url] +[![Gittip][gittip-image]][gittip-url] + + Send is Connect's `static()` extracted for generalized use, a streaming static file + server supporting partial responses (Ranges), conditional-GET negotiation, high test coverage, and granular events which may be leveraged to take appropriate actions in your application or framework. + +## Installation + +```bash +$ npm install send +``` + +## API + +```js +var send = require('send') +``` + +### send(req, path, [options]) + +Create a new `SendStream` for the given path to send to a `res`. The `req` is +the Node.js HTTP request and the `path` is a urlencoded path to send (urlencoded, +not the actual file-system path). + +#### Options + +##### dotfiles + + Set how "dotfiles" are treated when encountered. A dotfile is a file + or directory that begins with a dot ("."). Note this check is done on + the path itself without checking if the path actually exists on the + disk. If `root` is specified, only the dotfiles above the root are + checked (i.e. the root itself can be within a dotfile when when set + to "deny"). + + The default value is `'ignore'`. + + - `'allow'` No special treatment for dotfiles. + - `'deny'` Send a 403 for any request for a dotfile. + - `'ignore'` Pretend like the dotfile does not exist and 404. + +##### etag + + Enable or disable etag generation, defaults to true. + +##### extensions + + If a given file doesn't exist, try appending one of the given extensions, + in the given order. By default, this is disabled (set to `false`). An + example value that will serve extension-less HTML files: `['html', 'htm']`. + This is skipped if the requested file already has an extension. + +##### index + + By default send supports "index.html" files, to disable this + set `false` or to supply a new index pass a string or an array + in preferred order. + +##### lastModified + + Enable or disable `Last-Modified` header, defaults to true. Uses the file + system's last modified value. + +##### maxAge + + Provide a max-age in milliseconds for http caching, defaults to 0. + This can also be a string accepted by the + [ms](https://www.npmjs.org/package/ms#readme) module. + +##### root + + Serve files relative to `path`. + +### Events + +The `SendStream` is an event emitter and will emit the following events: + + - `error` an error occurred `(err)` + - `directory` a directory was requested + - `file` a file was requested `(path, stat)` + - `headers` the headers are about to be set on a file `(res, path, stat)` + - `stream` file streaming has started `(stream)` + - `end` streaming has completed + +### .pipe + +The `pipe` method is used to pipe the response into the Node.js HTTP response +object, typically `send(req, path, options).pipe(res)`. + +## Error-handling + + By default when no `error` listeners are present an automatic response will be made, otherwise you have full control over the response, aka you may show a 5xx page etc. + +## Caching + + It does _not_ perform internal caching, you should use a reverse proxy cache such + as Varnish for this, or those fancy things called CDNs. If your application is small enough that it would benefit from single-node memory caching, it's small enough that it does not need caching at all ;). + +## Debugging + + To enable `debug()` instrumentation output export __DEBUG__: + +``` +$ DEBUG=send node app +``` + +## Running tests + +``` +$ npm install +$ npm test +``` + +## Examples + + Small: + +```js +var http = require('http'); +var send = require('send'); + +var app = http.createServer(function(req, res){ + send(req, req.url).pipe(res); +}).listen(3000); +``` + + Serving from a root directory with custom error-handling: + +```js +var http = require('http'); +var send = require('send'); +var url = require('url'); + +var app = http.createServer(function(req, res){ + // your custom error-handling logic: + function error(err) { + res.statusCode = err.status || 500; + res.end(err.message); + } + + // your custom headers + function headers(res, path, stat) { + // serve all files for download + res.setHeader('Content-Disposition', 'attachment'); + } + + // your custom directory handling logic: + function redirect() { + res.statusCode = 301; + res.setHeader('Location', req.url + '/'); + res.end('Redirecting to ' + req.url + '/'); + } + + // transfer arbitrary files from within + // /www/example.com/public/* + send(req, url.parse(req.url).pathname, {root: '/www/example.com/public'}) + .on('error', error) + .on('directory', redirect) + .on('headers', headers) + .pipe(res); +}).listen(3000); +``` + +## License + +[MIT](LICENSE) + +[npm-image]: https://img.shields.io/npm/v/send.svg?style=flat +[npm-url]: https://npmjs.org/package/send +[travis-image]: https://img.shields.io/travis/visionmedia/send.svg?style=flat +[travis-url]: https://travis-ci.org/visionmedia/send +[coveralls-image]: https://img.shields.io/coveralls/visionmedia/send.svg?style=flat +[coveralls-url]: https://coveralls.io/r/visionmedia/send?branch=master +[downloads-image]: https://img.shields.io/npm/dm/send.svg?style=flat +[downloads-url]: https://npmjs.org/package/send +[gittip-image]: https://img.shields.io/gittip/dougwilson.svg?style=flat +[gittip-url]: https://www.gittip.com/dougwilson/ diff --git a/node_modules/express/node_modules/send/index.js b/node_modules/express/node_modules/send/index.js new file mode 100644 index 0000000..64b6d64 --- /dev/null +++ b/node_modules/express/node_modules/send/index.js @@ -0,0 +1,773 @@ + +/** + * Module dependencies. + */ + +var debug = require('debug')('send') +var deprecate = require('depd')('send') +var destroy = require('destroy') +var escapeHtml = require('escape-html') + , parseRange = require('range-parser') + , Stream = require('stream') + , mime = require('mime') + , fresh = require('fresh') + , path = require('path') + , http = require('http') + , fs = require('fs') + , normalize = path.normalize + , join = path.join +var etag = require('etag') +var EventEmitter = require('events').EventEmitter; +var ms = require('ms'); +var onFinished = require('on-finished') + +/** + * Variables. + */ +var extname = path.extname +var maxMaxAge = 60 * 60 * 24 * 365 * 1000; // 1 year +var resolve = path.resolve +var sep = path.sep +var toString = Object.prototype.toString +var upPathRegexp = /(?:^|[\\\/])\.\.(?:[\\\/]|$)/ + +/** + * Expose `send`. + */ + +exports = module.exports = send; + +/** + * Expose mime module. + */ + +exports.mime = mime; + +/** + * Shim EventEmitter.listenerCount for node.js < 0.10 + */ + +/* istanbul ignore next */ +var listenerCount = EventEmitter.listenerCount + || function(emitter, type){ return emitter.listeners(type).length; }; + +/** + * Return a `SendStream` for `req` and `path`. + * + * @param {Request} req + * @param {String} path + * @param {Object} options + * @return {SendStream} + * @api public + */ + +function send(req, path, options) { + return new SendStream(req, path, options); +} + +/** + * Initialize a `SendStream` with the given `path`. + * + * @param {Request} req + * @param {String} path + * @param {Object} options + * @api private + */ + +function SendStream(req, path, options) { + var self = this; + options = options || {}; + this.req = req; + this.path = path; + this.options = options; + + this._etag = options.etag !== undefined + ? Boolean(options.etag) + : true + + this._dotfiles = options.dotfiles !== undefined + ? options.dotfiles + : 'ignore' + + if (['allow', 'deny', 'ignore'].indexOf(this._dotfiles) === -1) { + throw new TypeError('dotfiles option must be "allow", "deny", or "ignore"') + } + + this._hidden = Boolean(options.hidden) + + if ('hidden' in options) { + deprecate('hidden: use dotfiles: \'' + (this._hidden ? 'allow' : 'ignore') + '\' instead') + } + + // legacy support + if (!('dotfiles' in options)) { + this._dotfiles = undefined + } + + this._extensions = options.extensions !== undefined + ? normalizeList(options.extensions) + : [] + + this._index = options.index !== undefined + ? normalizeList(options.index) + : ['index.html'] + + this._lastModified = options.lastModified !== undefined + ? Boolean(options.lastModified) + : true + + this._maxage = options.maxAge || options.maxage + this._maxage = typeof this._maxage === 'string' + ? ms(this._maxage) + : Number(this._maxage) + this._maxage = !isNaN(this._maxage) + ? Math.min(Math.max(0, this._maxage), maxMaxAge) + : 0 + + this._root = options.root + ? resolve(options.root) + : null + + if (!this._root && options.from) { + this.from(options.from); + } +} + +/** + * Inherits from `Stream.prototype`. + */ + +SendStream.prototype.__proto__ = Stream.prototype; + +/** + * Enable or disable etag generation. + * + * @param {Boolean} val + * @return {SendStream} + * @api public + */ + +SendStream.prototype.etag = deprecate.function(function etag(val) { + val = Boolean(val); + debug('etag %s', val); + this._etag = val; + return this; +}, 'send.etag: pass etag as option'); + +/** + * Enable or disable "hidden" (dot) files. + * + * @param {Boolean} path + * @return {SendStream} + * @api public + */ + +SendStream.prototype.hidden = deprecate.function(function hidden(val) { + val = Boolean(val); + debug('hidden %s', val); + this._hidden = val; + this._dotfiles = undefined + return this; +}, 'send.hidden: use dotfiles option'); + +/** + * Set index `paths`, set to a falsy + * value to disable index support. + * + * @param {String|Boolean|Array} paths + * @return {SendStream} + * @api public + */ + +SendStream.prototype.index = deprecate.function(function index(paths) { + var index = !paths ? [] : normalizeList(paths); + debug('index %o', paths); + this._index = index; + return this; +}, 'send.index: pass index as option'); + +/** + * Set root `path`. + * + * @param {String} path + * @return {SendStream} + * @api public + */ + +SendStream.prototype.root = function(path){ + path = String(path); + this._root = resolve(path) + return this; +}; + +SendStream.prototype.from = deprecate.function(SendStream.prototype.root, + 'send.from: pass root as option'); + +SendStream.prototype.root = deprecate.function(SendStream.prototype.root, + 'send.root: pass root as option'); + +/** + * Set max-age to `maxAge`. + * + * @param {Number} maxAge + * @return {SendStream} + * @api public + */ + +SendStream.prototype.maxage = deprecate.function(function maxage(maxAge) { + maxAge = typeof maxAge === 'string' + ? ms(maxAge) + : Number(maxAge); + if (isNaN(maxAge)) maxAge = 0; + if (Infinity == maxAge) maxAge = 60 * 60 * 24 * 365 * 1000; + debug('max-age %d', maxAge); + this._maxage = maxAge; + return this; +}, 'send.maxage: pass maxAge as option'); + +/** + * Emit error with `status`. + * + * @param {Number} status + * @api private + */ + +SendStream.prototype.error = function(status, err){ + var res = this.res; + var msg = http.STATUS_CODES[status]; + + err = err || new Error(msg); + err.status = status; + + // emit if listeners instead of responding + if (listenerCount(this, 'error') !== 0) { + return this.emit('error', err); + } + + // wipe all existing headers + res._headers = undefined; + + res.statusCode = err.status; + res.end(msg); +}; + +/** + * Check if the pathname ends with "/". + * + * @return {Boolean} + * @api private + */ + +SendStream.prototype.hasTrailingSlash = function(){ + return '/' == this.path[this.path.length - 1]; +}; + +/** + * Check if this is a conditional GET request. + * + * @return {Boolean} + * @api private + */ + +SendStream.prototype.isConditionalGET = function(){ + return this.req.headers['if-none-match'] + || this.req.headers['if-modified-since']; +}; + +/** + * Strip content-* header fields. + * + * @api private + */ + +SendStream.prototype.removeContentHeaderFields = function(){ + var res = this.res; + Object.keys(res._headers).forEach(function(field){ + if (0 == field.indexOf('content')) { + res.removeHeader(field); + } + }); +}; + +/** + * Respond with 304 not modified. + * + * @api private + */ + +SendStream.prototype.notModified = function(){ + var res = this.res; + debug('not modified'); + this.removeContentHeaderFields(); + res.statusCode = 304; + res.end(); +}; + +/** + * Raise error that headers already sent. + * + * @api private + */ + +SendStream.prototype.headersAlreadySent = function headersAlreadySent(){ + var err = new Error('Can\'t set headers after they are sent.'); + debug('headers already sent'); + this.error(500, err); +}; + +/** + * Check if the request is cacheable, aka + * responded with 2xx or 304 (see RFC 2616 section 14.2{5,6}). + * + * @return {Boolean} + * @api private + */ + +SendStream.prototype.isCachable = function(){ + var res = this.res; + return (res.statusCode >= 200 && res.statusCode < 300) || 304 == res.statusCode; +}; + +/** + * Handle stat() error. + * + * @param {Error} err + * @api private + */ + +SendStream.prototype.onStatError = function(err){ + var notfound = ['ENOENT', 'ENAMETOOLONG', 'ENOTDIR']; + if (~notfound.indexOf(err.code)) return this.error(404, err); + this.error(500, err); +}; + +/** + * Check if the cache is fresh. + * + * @return {Boolean} + * @api private + */ + +SendStream.prototype.isFresh = function(){ + return fresh(this.req.headers, this.res._headers); +}; + +/** + * Check if the range is fresh. + * + * @return {Boolean} + * @api private + */ + +SendStream.prototype.isRangeFresh = function isRangeFresh(){ + var ifRange = this.req.headers['if-range']; + + if (!ifRange) return true; + + return ~ifRange.indexOf('"') + ? ~ifRange.indexOf(this.res._headers['etag']) + : Date.parse(this.res._headers['last-modified']) <= Date.parse(ifRange); +}; + +/** + * Redirect to `path`. + * + * @param {String} path + * @api private + */ + +SendStream.prototype.redirect = function(path){ + if (listenerCount(this, 'directory') !== 0) { + return this.emit('directory'); + } + + if (this.hasTrailingSlash()) return this.error(403); + var res = this.res; + path += '/'; + res.statusCode = 301; + res.setHeader('Content-Type', 'text/html; charset=utf-8'); + res.setHeader('Location', path); + res.end('Redirecting to ' + escapeHtml(path) + '\n'); +}; + +/** + * Pipe to `res. + * + * @param {Stream} res + * @return {Stream} res + * @api public + */ + +SendStream.prototype.pipe = function(res){ + var self = this + , args = arguments + , root = this._root; + + // references + this.res = res; + + // decode the path + var path = decode(this.path) + if (path === -1) return this.error(400) + + // null byte(s) + if (~path.indexOf('\0')) return this.error(400); + + var parts + if (root !== null) { + // join / normalize from optional root dir + path = normalize(join(root, path)) + root = normalize(root + sep) + + // malicious path + if ((path + sep).substr(0, root.length) !== root) { + debug('malicious path "%s"', path) + return this.error(403) + } + + // explode path parts + parts = path.substr(root.length).split(sep) + } else { + // ".." is malicious without "root" + if (upPathRegexp.test(path)) { + debug('malicious path "%s"', path) + return this.error(403) + } + + // explode path parts + parts = normalize(path).split(sep) + + // resolve the path + path = resolve(path) + } + + // dotfile handling + if (containsDotFile(parts)) { + var access = this._dotfiles + + // legacy support + if (access === undefined) { + access = parts[parts.length - 1][0] === '.' + ? (this._hidden ? 'allow' : 'ignore') + : 'allow' + } + + debug('%s dotfile "%s"', access, path) + switch (access) { + case 'allow': + break + case 'deny': + return this.error(403) + case 'ignore': + default: + return this.error(404) + } + } + + // index file support + if (this._index.length && this.path[this.path.length - 1] === '/') { + this.sendIndex(path); + return res; + } + + this.sendFile(path); + return res; +}; + +/** + * Transfer `path`. + * + * @param {String} path + * @api public + */ + +SendStream.prototype.send = function(path, stat){ + var options = this.options; + var len = stat.size; + var res = this.res; + var req = this.req; + var ranges = req.headers.range; + var offset = options.start || 0; + + if (res._header) { + // impossible to send now + return this.headersAlreadySent(); + } + + debug('pipe "%s"', path) + + // set header fields + this.setHeader(path, stat); + + // set content-type + this.type(path); + + // conditional GET support + if (this.isConditionalGET() + && this.isCachable() + && this.isFresh()) { + return this.notModified(); + } + + // adjust len to start/end options + len = Math.max(0, len - offset); + if (options.end !== undefined) { + var bytes = options.end - offset + 1; + if (len > bytes) len = bytes; + } + + // Range support + if (ranges) { + ranges = parseRange(len, ranges); + + // If-Range support + if (!this.isRangeFresh()) { + debug('range stale'); + ranges = -2; + } + + // unsatisfiable + if (-1 == ranges) { + debug('range unsatisfiable'); + res.setHeader('Content-Range', 'bytes */' + stat.size); + return this.error(416); + } + + // valid (syntactically invalid/multiple ranges are treated as a regular response) + if (-2 != ranges && ranges.length === 1) { + debug('range %j', ranges); + + options.start = offset + ranges[0].start; + options.end = offset + ranges[0].end; + + // Content-Range + res.statusCode = 206; + res.setHeader('Content-Range', 'bytes ' + + ranges[0].start + + '-' + + ranges[0].end + + '/' + + len); + len = options.end - options.start + 1; + } + } + + // content-length + res.setHeader('Content-Length', len); + + // HEAD support + if ('HEAD' == req.method) return res.end(); + + this.stream(path, options); +}; + +/** + * Transfer file for `path`. + * + * @param {String} path + * @api private + */ +SendStream.prototype.sendFile = function sendFile(path) { + var i = 0 + var self = this + + debug('stat "%s"', path); + fs.stat(path, function onstat(err, stat) { + if (err && err.code === 'ENOENT' + && !extname(path) + && path[path.length - 1] !== sep) { + // not found, check extensions + return next(err) + } + if (err) return self.onStatError(err) + if (stat.isDirectory()) return self.redirect(self.path) + self.emit('file', path, stat) + self.send(path, stat) + }) + + function next(err) { + if (self._extensions.length <= i) { + return err + ? self.onStatError(err) + : self.error(404) + } + + var p = path + '.' + self._extensions[i++] + + debug('stat "%s"', p) + fs.stat(p, function (err, stat) { + if (err) return next(err) + if (stat.isDirectory()) return next() + self.emit('file', p, stat) + self.send(p, stat) + }) + } +} + +/** + * Transfer index for `path`. + * + * @param {String} path + * @api private + */ +SendStream.prototype.sendIndex = function sendIndex(path){ + var i = -1; + var self = this; + + function next(err){ + if (++i >= self._index.length) { + if (err) return self.onStatError(err); + return self.error(404); + } + + var p = join(path, self._index[i]); + + debug('stat "%s"', p); + fs.stat(p, function(err, stat){ + if (err) return next(err); + if (stat.isDirectory()) return next(); + self.emit('file', p, stat); + self.send(p, stat); + }); + } + + next(); +}; + +/** + * Stream `path` to the response. + * + * @param {String} path + * @param {Object} options + * @api private + */ + +SendStream.prototype.stream = function(path, options){ + // TODO: this is all lame, refactor meeee + var finished = false; + var self = this; + var res = this.res; + var req = this.req; + + // pipe + var stream = fs.createReadStream(path, options); + this.emit('stream', stream); + stream.pipe(res); + + // response finished, done with the fd + onFinished(res, function onfinished(){ + finished = true; + destroy(stream); + }); + + // error handling code-smell + stream.on('error', function onerror(err){ + // request already finished + if (finished) return; + + // clean up stream + finished = true; + destroy(stream); + + // error + self.onStatError(err); + }); + + // end + stream.on('end', function onend(){ + self.emit('end'); + }); +}; + +/** + * Set content-type based on `path` + * if it hasn't been explicitly set. + * + * @param {String} path + * @api private + */ + +SendStream.prototype.type = function(path){ + var res = this.res; + if (res.getHeader('Content-Type')) return; + var type = mime.lookup(path); + var charset = mime.charsets.lookup(type); + debug('content-type %s', type); + res.setHeader('Content-Type', type + (charset ? '; charset=' + charset : '')); +}; + +/** + * Set response header fields, most + * fields may be pre-defined. + * + * @param {String} path + * @param {Object} stat + * @api private + */ + +SendStream.prototype.setHeader = function setHeader(path, stat){ + var res = this.res; + + this.emit('headers', res, path, stat); + + if (!res.getHeader('Accept-Ranges')) res.setHeader('Accept-Ranges', 'bytes'); + if (!res.getHeader('Date')) res.setHeader('Date', new Date().toUTCString()); + if (!res.getHeader('Cache-Control')) res.setHeader('Cache-Control', 'public, max-age=' + Math.floor(this._maxage / 1000)); + + if (this._lastModified && !res.getHeader('Last-Modified')) { + var modified = stat.mtime.toUTCString() + debug('modified %s', modified) + res.setHeader('Last-Modified', modified) + } + + if (this._etag && !res.getHeader('ETag')) { + var val = etag(stat) + debug('etag %s', val) + res.setHeader('ETag', val) + } +}; + +/** + * Determine if path parts contain a dotfile. + * + * @api private + */ + +function containsDotFile(parts) { + for (var i = 0; i < parts.length; i++) { + if (parts[i][0] === '.') { + return true + } + } + + return false +} + +/** + * decodeURIComponent. + * + * Allows V8 to only deoptimize this fn instead of all + * of send(). + * + * @param {String} path + * @api private + */ + +function decode(path) { + try { + return decodeURIComponent(path) + } catch (err) { + return -1 + } +} + +/** + * Normalize the index option into an array. + * + * @param {boolean|string|array} val + * @api private + */ + +function normalizeList(val){ + return [].concat(val || []) +} diff --git a/node_modules/express/node_modules/send/node_modules/depd/History.md b/node_modules/express/node_modules/send/node_modules/depd/History.md new file mode 100644 index 0000000..800eab1 --- /dev/null +++ b/node_modules/express/node_modules/send/node_modules/depd/History.md @@ -0,0 +1,62 @@ +0.4.5 / 2014-09-09 +================== + + * Improve call speed to functions using the function wrapper + * Support Node.js 0.6 + +0.4.4 / 2014-07-27 +================== + + * Work-around v8 generating empty stack traces + +0.4.3 / 2014-07-26 +================== + + * Fix exception when global `Error.stackTraceLimit` is too low + +0.4.2 / 2014-07-19 +================== + + * Correct call site for wrapped functions and properties + +0.4.1 / 2014-07-19 +================== + + * Improve automatic message generation for function properties + +0.4.0 / 2014-07-19 +================== + + * Add `TRACE_DEPRECATION` environment variable + * Remove non-standard grey color from color output + * Support `--no-deprecation` argument + * Support `--trace-deprecation` argument + * Support `deprecate.property(fn, prop, message)` + +0.3.0 / 2014-06-16 +================== + + * Add `NO_DEPRECATION` environment variable + +0.2.0 / 2014-06-15 +================== + + * Add `deprecate.property(obj, prop, message)` + * Remove `supports-color` dependency for node.js 0.8 + +0.1.0 / 2014-06-15 +================== + + * Add `deprecate.function(fn, message)` + * Add `process.on('deprecation', fn)` emitter + * Automatically generate message when omitted from `deprecate()` + +0.0.1 / 2014-06-15 +================== + + * Fix warning for dynamic calls at singe call site + +0.0.0 / 2014-06-15 +================== + + * Initial implementation diff --git a/node_modules/express/node_modules/send/node_modules/depd/LICENSE b/node_modules/express/node_modules/send/node_modules/depd/LICENSE new file mode 100644 index 0000000..b7dce6c --- /dev/null +++ b/node_modules/express/node_modules/send/node_modules/depd/LICENSE @@ -0,0 +1,22 @@ +(The MIT License) + +Copyright (c) 2014 Douglas Christopher Wilson + +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/node_modules/express/node_modules/send/node_modules/depd/Readme.md b/node_modules/express/node_modules/send/node_modules/depd/Readme.md new file mode 100644 index 0000000..098953e --- /dev/null +++ b/node_modules/express/node_modules/send/node_modules/depd/Readme.md @@ -0,0 +1,266 @@ +# depd + +[![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] +[![Gittip][gittip-image]][gittip-url] + +Deprecate all the things + +> With great modules comes great responsibility; mark things deprecated! + +## Install + +```sh +$ npm install depd +``` + +## API + +```js +var deprecate = require('depd')('my-module') +``` + +This library allows you to display deprecation messages to your users. +This library goes above and beyond with deprecation warnings by +introspecting the call stack (but only the bits that it is interested +in). + +Instead of just warning on the first invocation of a deprecated +function and never again, this module will warn on the first invocation +of a deprecated function per unique call site, making it ideal to alert +users of all deprecated uses across the code base, rather than just +whatever happens to execute first. + +The deprecation warnings from this module also include the file and line +information for the call into the module that the deprecated function was +in. + +### depd(namespace) + +Create a new deprecate function that uses the given namespace name in the +messages and will display the call site prior to the stack entering the +file this function was called from. It is highly suggested you use the +name of your module as the namespace. + +### deprecate(message) + +Call this function from deprecated code to display a deprecation message. +This message will appear once per unique caller site. Caller site is the +first call site in the stack in a different file from the caller of this +function. + +If the message is omitted, a message is generated for you based on the site +of the `deprecate()` call and will display the name of the function called, +similar to the name displayed in a stack trace. + +### deprecate.function(fn, message) + +Call this function to wrap a given function in a deprecation message on any +call to the function. An optional message can be supplied to provide a custom +message. + +### deprecate.property(obj, prop, message) + +Call this function to wrap a given property on object in a deprecation message +on any accessing or setting of the property. An optional message can be supplied +to provide a custom message. + +The method must be called on the object where the property belongs (not +inherited from the prototype). + +If the property is a data descriptor, it will be converted to an accessor +descriptor in order to display the deprecation message. + +### process.on('deprecation', fn) + +This module will allow easy capturing of deprecation errors by emitting the +errors as the type "deprecation" on the global `process`. If there are no +listeners for this type, the errors are written to STDERR as normal, but if +there are any listeners, nothing will be written to STDERR and instead only +emitted. From there, you can write the errors in a different format or to a +logging source. + +The error represents the deprecation and is emitted only once with the same +rules as writing to STDERR. The error has the following properties: + + - `message` - This is the message given by the library + - `name` - This is always `'DeprecationError'` + - `namespace` - This is the namespace the deprecation came from + - `stack` - This is the stack of the call to the deprecated thing + +Example `error.stack` output: + +``` +DeprecationError: my-cool-module deprecated oldfunction + at Object. ([eval]-wrapper:6:22) + at Module._compile (module.js:456:26) + at evalScript (node.js:532:25) + at startup (node.js:80:7) + at node.js:902:3 +``` + +### process.env.NO_DEPRECATION + +As a user of modules that are deprecated, the environment variable `NO_DEPRECATION` +is provided as a quick solution to silencing deprecation warnings from being +output. The format of this is similar to that of `DEBUG`: + +```sh +$ NO_DEPRECATION=my-module,othermod node app.js +``` + +This will suppress deprecations from being output for "my-module" and "othermod". +The value is a list of comma-separated namespaces. To suppress every warning +across all namespaces, use the value `*` for a namespace. + +Providing the argument `--no-deprecation` to the `node` executable will suppress +all deprecations (only available in Node.js 0.8 or higher). + +**NOTE** This will not suppress the deperecations given to any "deprecation" +event listeners, just the output to STDERR. + +### process.env.TRACE_DEPRECATION + +As a user of modules that are deprecated, the environment variable `TRACE_DEPRECATION` +is provided as a solution to getting more detailed location information in deprecation +warnings by including the entire stack trace. The format of this is the same as +`NO_DEPRECATION`: + +```sh +$ TRACE_DEPRECATION=my-module,othermod node app.js +``` + +This will include stack traces for deprecations being output for "my-module" and +"othermod". The value is a list of comma-separated namespaces. To trace every +warning across all namespaces, use the value `*` for a namespace. + +Providing the argument `--trace-deprecation` to the `node` executable will trace +all deprecations (only available in Node.js 0.8 or higher). + +**NOTE** This will not trace the deperecations silenced by `NO_DEPRECATION`. + +## Display + +![message](files/message.png) + +When a user calls a function in your library that you mark deprecated, they +will see the following written to STDERR (in the given colors, similar colors +and layout to the `debug` module): + +``` +bright cyan bright yellow +| | reset cyan +| | | | +▼ ▼ ▼ ▼ +my-cool-module deprecated oldfunction [eval]-wrapper:6:22 +▲ ▲ ▲ ▲ +| | | | +namespace | | location of mycoolmod.oldfunction() call + | deprecation message + the word "deprecated" +``` + +If the user redirects their STDERR to a file or somewhere that does not support +colors, they see (similar layout to the `debug` module): + +``` +Sun, 15 Jun 2014 05:21:37 GMT my-cool-module deprecated oldfunction at [eval]-wrapper:6:22 +▲ ▲ ▲ ▲ ▲ +| | | | | +timestamp of message namespace | | location of mycoolmod.oldfunction() call + | deprecation message + the word "deprecated" +``` + +## Examples + +### Deprecating all calls to a function + +This will display a deprecated message about "oldfunction" being deprecated +from "my-module" on STDERR. + +```js +var deprecate = require('depd')('my-cool-module') + +// message automatically derived from function name +// Object.oldfunction +exports.oldfunction = deprecate.function(function oldfunction() { + // all calls to function are deprecated +}) + +// specific message +exports.oldfunction = deprecate.function(function () { + // all calls to function are deprecated +}, 'oldfunction') +``` + +### Conditionally deprecating a function call + +This will display a deprecated message about "weirdfunction" being deprecated +from "my-module" on STDERR when called with less than 2 arguments. + +```js +var deprecate = require('depd')('my-cool-module') + +exports.weirdfunction = function () { + if (arguments.length < 2) { + // calls with 0 or 1 args are deprecated + deprecate('weirdfunction args < 2') + } +} +``` + +When calling `deprecate` as a function, the warning is counted per call site +within your own module, so you can display different deprecations depending +on different situations and the users will still get all the warnings: + +```js +var deprecate = require('depd')('my-cool-module') + +exports.weirdfunction = function () { + if (arguments.length < 2) { + // calls with 0 or 1 args are deprecated + deprecate('weirdfunction args < 2') + } else if (typeof arguments[0] !== 'string') { + // calls with non-string first argument are deprecated + deprecate('weirdfunction non-string first arg') + } +} +``` + +### Deprecating property access + +This will display a deprecated message about "oldprop" being deprecated +from "my-module" on STDERR when accessed. A deprecation will be displayed +when setting the value and when getting the value. + +```js +var deprecate = require('depd')('my-cool-module') + +exports.oldprop = 'something' + +// message automatically derives from property name +deprecate.property(exports, 'oldprop') + +// explicit message +deprecate.property(exports, 'oldprop', 'oldprop >= 0.10') +``` + +## License + +[MIT](LICENSE) + +[npm-version-image]: https://img.shields.io/npm/v/depd.svg?style=flat +[npm-downloads-image]: https://img.shields.io/npm/dm/depd.svg?style=flat +[npm-url]: https://npmjs.org/package/depd +[travis-image]: https://img.shields.io/travis/dougwilson/nodejs-depd.svg?style=flat +[travis-url]: https://travis-ci.org/dougwilson/nodejs-depd +[coveralls-image]: https://img.shields.io/coveralls/dougwilson/nodejs-depd.svg?style=flat +[coveralls-url]: https://coveralls.io/r/dougwilson/nodejs-depd?branch=master +[node-image]: https://img.shields.io/node/v/depd.svg?style=flat +[node-url]: http://nodejs.org/download/ +[gittip-image]: https://img.shields.io/gittip/dougwilson.svg?style=flat +[gittip-url]: https://www.gittip.com/dougwilson/ diff --git a/node_modules/express/node_modules/send/node_modules/depd/index.js b/node_modules/express/node_modules/send/node_modules/depd/index.js new file mode 100644 index 0000000..4fee4d9 --- /dev/null +++ b/node_modules/express/node_modules/send/node_modules/depd/index.js @@ -0,0 +1,522 @@ +/*! + * depd + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module dependencies. + */ + +var callSiteToString = require('./lib/compat').callSiteToString +var EventEmitter = require('events').EventEmitter +var relative = require('path').relative + +/** + * Module exports. + */ + +module.exports = depd + +/** + * Get the path to base files on. + */ + +var basePath = process.cwd() + +/** + * Get listener count on event emitter. + */ + +/*istanbul ignore next*/ +var eventListenerCount = EventEmitter.listenerCount + || function (emitter, type) { return emitter.listeners(type).length } + +/** + * Determine if namespace is contained in the string. + */ + +function containsNamespace(str, namespace) { + var val = str.split(/[ ,]+/) + + namespace = String(namespace).toLowerCase() + + for (var i = 0 ; i < val.length; i++) { + if (!(str = val[i])) continue; + + // namespace contained + if (str === '*' || str.toLowerCase() === namespace) { + return true + } + } + + return false +} + +/** + * Convert a data descriptor to accessor descriptor. + */ + +function convertDataDescriptorToAccessor(obj, prop, message) { + var descriptor = Object.getOwnPropertyDescriptor(obj, prop) + var value = descriptor.value + + descriptor.get = function getter() { return value } + + if (descriptor.writable) { + descriptor.set = function setter(val) { return value = val } + } + + delete descriptor.value + delete descriptor.writable + + Object.defineProperty(obj, prop, descriptor) + + return descriptor +} + +/** + * Create arguments string to keep arity. + */ + +function createArgumentsString(arity) { + var str = '' + + for (var i = 0; i < arity; i++) { + str += ', arg' + i + } + + return str.substr(2) +} + +/** + * Create stack string from stack. + */ + +function createStackString(stack) { + var str = this.name + ': ' + this.namespace + + if (this.message) { + str += ' deprecated ' + this.message + } + + for (var i = 0; i < stack.length; i++) { + str += '\n at ' + callSiteToString(stack[i]) + } + + return str +} + +/** + * Create deprecate for namespace in caller. + */ + +function depd(namespace) { + if (!namespace) { + throw new TypeError('argument namespace is required') + } + + var stack = getStack() + var site = callSiteLocation(stack[1]) + var file = site[0] + + function deprecate(message) { + // call to self as log + log.call(deprecate, message) + } + + deprecate._file = file + deprecate._ignored = isignored(namespace) + deprecate._namespace = namespace + deprecate._traced = istraced(namespace) + deprecate._warned = Object.create(null) + + deprecate.function = wrapfunction + deprecate.property = wrapproperty + + return deprecate +} + +/** + * Determine if namespace is ignored. + */ + +function isignored(namespace) { + /* istanbul ignore next: tested in a child processs */ + if (process.noDeprecation) { + // --no-deprecation support + return true + } + + var str = process.env.NO_DEPRECATION || '' + + // namespace ignored + return containsNamespace(str, namespace) +} + +/** + * Determine if namespace is traced. + */ + +function istraced(namespace) { + /* istanbul ignore next: tested in a child processs */ + if (process.traceDeprecation) { + // --trace-deprecation support + return true + } + + var str = process.env.TRACE_DEPRECATION || '' + + // namespace traced + return containsNamespace(str, namespace) +} + +/** + * Display deprecation message. + */ + +function log(message, site) { + var haslisteners = eventListenerCount(process, 'deprecation') !== 0 + + // abort early if no destination + if (!haslisteners && this._ignored) { + return + } + + var caller + var callFile + var callSite + var i = 0 + var seen = false + var stack = getStack() + var file = this._file + + if (site) { + // provided site + callSite = callSiteLocation(stack[1]) + callSite.name = site.name + file = callSite[0] + } else { + // get call site + i = 2 + site = callSiteLocation(stack[i]) + callSite = site + } + + // get caller of deprecated thing in relation to file + for (; i < stack.length; i++) { + caller = callSiteLocation(stack[i]) + callFile = caller[0] + + if (callFile === file) { + seen = true + } else if (callFile === this._file) { + file = this._file + } else if (seen) { + break + } + } + + var key = caller + ? site.join(':') + '__' + caller.join(':') + : undefined + + if (key !== undefined && key in this._warned) { + // already warned + return + } + + this._warned[key] = true + + // generate automatic message from call site + if (!message) { + message = callSite === site || !callSite.name + ? defaultMessage(site) + : defaultMessage(callSite) + } + + // emit deprecation if listeners exist + if (haslisteners) { + var err = DeprecationError(this._namespace, message, stack.slice(i)) + process.emit('deprecation', err) + return + } + + // format and write message + var format = process.stderr.isTTY + ? formatColor + : formatPlain + var msg = format.call(this, message, caller, stack.slice(i)) + process.stderr.write(msg + '\n', 'utf8') + + return +} + +/** + * Get call site location as array. + */ + +function callSiteLocation(callSite) { + var file = callSite.getFileName() || '' + var line = callSite.getLineNumber() + var colm = callSite.getColumnNumber() + + if (callSite.isEval()) { + file = callSite.getEvalOrigin() + ', ' + file + } + + var site = [file, line, colm] + + site.callSite = callSite + site.name = callSite.getFunctionName() + + return site +} + +/** + * Generate a default message from the site. + */ + +function defaultMessage(site) { + var callSite = site.callSite + var funcName = site.name + var typeName = callSite.getTypeName() + + // make useful anonymous name + if (!funcName) { + funcName = '' + } + + // make useful type name + if (typeName === 'Function') { + typeName = callSite.getThis().name || typeName + } + + return callSite.getMethodName() + ? typeName + '.' + funcName + : funcName +} + +/** + * Format deprecation message without color. + */ + +function formatPlain(msg, caller, stack) { + var timestamp = new Date().toUTCString() + + var formatted = timestamp + + ' ' + this._namespace + + ' deprecated ' + msg + + // add stack trace + if (this._traced) { + for (var i = 0; i < stack.length; i++) { + formatted += '\n at ' + callSiteToString(stack[i]) + } + + return formatted + } + + if (caller) { + formatted += ' at ' + formatLocation(caller) + } + + return formatted +} + +/** + * Format deprecation message with color. + */ + +function formatColor(msg, caller, stack) { + var formatted = '\x1b[36;1m' + this._namespace + '\x1b[22;39m' // bold cyan + + ' \x1b[33;1mdeprecated\x1b[22;39m' // bold yellow + + ' \x1b[0m' + msg + '\x1b[39m' // reset + + // add stack trace + if (this._traced) { + for (var i = 0; i < stack.length; i++) { + formatted += '\n \x1b[36mat ' + callSiteToString(stack[i]) + '\x1b[39m' // cyan + } + + return formatted + } + + if (caller) { + formatted += ' \x1b[36m' + formatLocation(caller) + '\x1b[39m' // cyan + } + + return formatted +} + +/** + * Format call site location. + */ + +function formatLocation(callSite) { + return relative(basePath, callSite[0]) + + ':' + callSite[1] + + ':' + callSite[2] +} + +/** + * Get the stack as array of call sites. + */ + +function getStack() { + var limit = Error.stackTraceLimit + var obj = {} + var prep = Error.prepareStackTrace + + Error.prepareStackTrace = prepareObjectStackTrace + Error.stackTraceLimit = Math.max(10, limit) + + // capture the stack + Error.captureStackTrace(obj) + + // slice this function off the top + var stack = obj.stack.slice(1) + + Error.prepareStackTrace = prep + Error.stackTraceLimit = limit + + return stack +} + +/** + * Capture call site stack from v8. + */ + +function prepareObjectStackTrace(obj, stack) { + return stack +} + +/** + * Return a wrapped function in a deprecation message. + */ + +function wrapfunction(fn, message) { + if (typeof fn !== 'function') { + throw new TypeError('argument fn must be a function') + } + + var args = createArgumentsString(fn.length) + var deprecate = this + var stack = getStack() + var site = callSiteLocation(stack[1]) + + site.name = fn.name + + var deprecatedfn = eval('(function (' + args + ') {\n' + + '"use strict"\n' + + 'log.call(deprecate, message, site)\n' + + 'return fn.apply(this, arguments)\n' + + '})') + + return deprecatedfn +} + +/** + * Wrap property in a deprecation message. + */ + +function wrapproperty(obj, prop, message) { + if (!obj || (typeof obj !== 'object' && typeof obj !== 'function')) { + throw new TypeError('argument obj must be object') + } + + var descriptor = Object.getOwnPropertyDescriptor(obj, prop) + + if (!descriptor) { + throw new TypeError('must call property on owner object') + } + + if (!descriptor.configurable) { + throw new TypeError('property must be configurable') + } + + var deprecate = this + var stack = getStack() + var site = callSiteLocation(stack[1]) + + // set site name + site.name = prop + + // convert data descriptor + if ('value' in descriptor) { + descriptor = convertDataDescriptorToAccessor(obj, prop, message) + } + + var get = descriptor.get + var set = descriptor.set + + // wrap getter + if (typeof get === 'function') { + descriptor.get = function getter() { + log.call(deprecate, message, site) + return get.apply(this, arguments) + } + } + + // wrap setter + if (typeof set === 'function') { + descriptor.set = function setter() { + log.call(deprecate, message, site) + return set.apply(this, arguments) + } + } + + Object.defineProperty(obj, prop, descriptor) +} + +/** + * Create DeprecationError for deprecation + */ + +function DeprecationError(namespace, message, stack) { + var error = new Error() + var stackString + + Object.defineProperty(error, 'constructor', { + value: DeprecationError + }) + + Object.defineProperty(error, 'message', { + configurable: true, + enumerable: false, + value: message, + writable: true + }) + + Object.defineProperty(error, 'name', { + enumerable: false, + configurable: true, + value: 'DeprecationError', + writable: true + }) + + Object.defineProperty(error, 'namespace', { + configurable: true, + enumerable: false, + value: namespace, + writable: true + }) + + Object.defineProperty(error, 'stack', { + configurable: true, + enumerable: false, + get: function () { + if (stackString !== undefined) { + return stackString + } + + // prepare stack trace + return stackString = createStackString.call(this, stack) + }, + set: function setter(val) { + stackString = val + } + }) + + return error +} diff --git a/node_modules/express/node_modules/send/node_modules/depd/lib/compat/buffer-concat.js b/node_modules/express/node_modules/send/node_modules/depd/lib/compat/buffer-concat.js new file mode 100644 index 0000000..09d9721 --- /dev/null +++ b/node_modules/express/node_modules/send/node_modules/depd/lib/compat/buffer-concat.js @@ -0,0 +1,33 @@ +/*! + * depd + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module exports. + */ + +module.exports = bufferConcat + +/** + * Concatenate an array of Buffers. + */ + +function bufferConcat(bufs) { + var length = 0 + + for (var i = 0, len = bufs.length; i < len; i++) { + length += bufs[i].length + } + + var buf = new Buffer(length) + var pos = 0 + + for (var i = 0, len = bufs.length; i < len; i++) { + bufs[i].copy(buf, pos) + pos += bufs[i].length + } + + return buf +} diff --git a/node_modules/express/node_modules/send/node_modules/depd/lib/compat/callsite-tostring.js b/node_modules/express/node_modules/send/node_modules/depd/lib/compat/callsite-tostring.js new file mode 100644 index 0000000..17cf7ed --- /dev/null +++ b/node_modules/express/node_modules/send/node_modules/depd/lib/compat/callsite-tostring.js @@ -0,0 +1,101 @@ +/*! + * depd + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module exports. + */ + +module.exports = callSiteToString + +/** + * Format a CallSite file location to a string. + */ + +function callSiteFileLocation(callSite) { + var fileName + var fileLocation = '' + + if (callSite.isNative()) { + fileLocation = 'native' + } else if (callSite.isEval()) { + fileName = callSite.getScriptNameOrSourceURL() + if (!fileName) { + fileLocation = callSite.getEvalOrigin() + } + } else { + fileName = callSite.getFileName() + } + + if (fileName) { + fileLocation += fileName + + var lineNumber = callSite.getLineNumber() + if (lineNumber != null) { + fileLocation += ':' + lineNumber + + var columnNumber = callSite.getColumnNumber() + if (columnNumber) { + fileLocation += ':' + columnNumber + } + } + } + + return fileLocation || 'unknown source' +} + +/** + * Format a CallSite to a string. + */ + +function callSiteToString(callSite) { + var addSuffix = true + var fileLocation = callSiteFileLocation(callSite) + var functionName = callSite.getFunctionName() + var isConstructor = callSite.isConstructor() + var isMethodCall = !(callSite.isToplevel() || isConstructor) + var line = '' + + if (isMethodCall) { + var methodName = callSite.getMethodName() + var typeName = getConstructorName(callSite) + + if (functionName) { + if (typeName && functionName.indexOf(typeName) !== 0) { + line += typeName + '.' + } + + line += functionName + + if (methodName && functionName.lastIndexOf('.' + methodName) !== functionName.length - methodName.length - 1) { + line += ' [as ' + methodName + ']' + } + } else { + line += typeName + '.' + (methodName || '') + } + } else if (isConstructor) { + line += 'new ' + (functionName || '') + } else if (functionName) { + line += functionName + } else { + addSuffix = false + line += fileLocation + } + + if (addSuffix) { + line += ' (' + fileLocation + ')' + } + + return line +} + +/** + * Get constructor name of reviver. + */ + +function getConstructorName(obj) { + var receiver = obj.receiver + return (receiver.constructor && receiver.constructor.name) || null +} diff --git a/node_modules/express/node_modules/send/node_modules/depd/lib/compat/index.js b/node_modules/express/node_modules/send/node_modules/depd/lib/compat/index.js new file mode 100644 index 0000000..7fee026 --- /dev/null +++ b/node_modules/express/node_modules/send/node_modules/depd/lib/compat/index.js @@ -0,0 +1,69 @@ +/*! + * depd + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module exports. + */ + +lazyProperty(module.exports, 'bufferConcat', function bufferConcat() { + return Buffer.concat || require('./buffer-concat') +}) + +lazyProperty(module.exports, 'callSiteToString', function callSiteToString() { + var limit = Error.stackTraceLimit + var obj = {} + var prep = Error.prepareStackTrace + + function prepareObjectStackTrace(obj, stack) { + return stack + } + + Error.prepareStackTrace = prepareObjectStackTrace + Error.stackTraceLimit = 2 + + // capture the stack + Error.captureStackTrace(obj) + + // slice the stack + var stack = obj.stack.slice() + + Error.prepareStackTrace = prep + Error.stackTraceLimit = limit + + return stack[0].toString ? toString : require('./callsite-tostring') +}) + +/** + * Define a lazy property. + */ + +function lazyProperty(obj, prop, getter) { + function get() { + var val = getter() + + Object.defineProperty(obj, prop, { + configurable: true, + enumerable: true, + value: val + }) + + return val + } + + Object.defineProperty(obj, prop, { + configurable: true, + enumerable: true, + get: get + }) +} + +/** + * Call toString() on the obj + */ + +function toString(obj) { + return obj.toString() +} diff --git a/node_modules/express/node_modules/send/node_modules/depd/package.json b/node_modules/express/node_modules/send/node_modules/depd/package.json new file mode 100644 index 0000000..55a9db0 --- /dev/null +++ b/node_modules/express/node_modules/send/node_modules/depd/package.json @@ -0,0 +1,67 @@ +{ + "name": "depd", + "description": "Deprecate all the things", + "version": "0.4.5", + "author": { + "name": "Douglas Christopher Wilson", + "email": "doug@somethingdoug.com" + }, + "license": "MIT", + "keywords": [ + "deprecate", + "deprecated" + ], + "repository": { + "type": "git", + "url": "https://github.com/dougwilson/nodejs-depd" + }, + "devDependencies": { + "benchmark": "1.0.0", + "beautify-benchmark": "0.2.4", + "istanbul": "0.3.2", + "mocha": "~1.21.4", + "should": "~4.0.4" + }, + "files": [ + "lib/", + "History.md", + "LICENSE", + "index.js", + "Readme.md" + ], + "engines": { + "node": ">= 0.6" + }, + "scripts": { + "bench": "node benchmark/index.js", + "test": "mocha --reporter spec --bail --require should test/", + "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --require should test/", + "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --require should test/" + }, + "gitHead": "e37a15044f7da76b94d8e0d46a6343feb168c82b", + "bugs": { + "url": "https://github.com/dougwilson/nodejs-depd/issues" + }, + "homepage": "https://github.com/dougwilson/nodejs-depd", + "_id": "depd@0.4.5", + "_shasum": "1a664b53388b4a6573e8ae67b5f767c693ca97f1", + "_from": "depd@0.4.5", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + "maintainers": [ + { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + } + ], + "dist": { + "shasum": "1a664b53388b4a6573e8ae67b5f767c693ca97f1", + "tarball": "http://registry.npmjs.org/depd/-/depd-0.4.5.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/depd/-/depd-0.4.5.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/express/node_modules/send/node_modules/destroy/README.md b/node_modules/express/node_modules/send/node_modules/destroy/README.md new file mode 100644 index 0000000..665acb7 --- /dev/null +++ b/node_modules/express/node_modules/send/node_modules/destroy/README.md @@ -0,0 +1,38 @@ +# Destroy + +[![NPM version][npm-image]][npm-url] +[![Build status][travis-image]][travis-url] +[![Test coverage][coveralls-image]][coveralls-url] +[![Dependency Status][david-image]][david-url] +[![License][license-image]][license-url] +[![Downloads][downloads-image]][downloads-url] +[![Gittip][gittip-image]][gittip-url] + +Destroy a stream. + +## API + +```js +var destroy = require('destroy') + +var fs = require('fs') +var stream = fs.createReadStream('package.json') +destroy(stream) +``` + +[npm-image]: https://img.shields.io/npm/v/destroy.svg?style=flat-square +[npm-url]: https://npmjs.org/package/destroy +[github-tag]: http://img.shields.io/github/tag/stream-utils/destroy.svg?style=flat-square +[github-url]: https://github.com/stream-utils/destroy/tags +[travis-image]: https://img.shields.io/travis/stream-utils/destroy.svg?style=flat-square +[travis-url]: https://travis-ci.org/stream-utils/destroy +[coveralls-image]: https://img.shields.io/coveralls/stream-utils/destroy.svg?style=flat-square +[coveralls-url]: https://coveralls.io/r/stream-utils/destroy?branch=master +[david-image]: http://img.shields.io/david/stream-utils/destroy.svg?style=flat-square +[david-url]: https://david-dm.org/stream-utils/destroy +[license-image]: http://img.shields.io/npm/l/destroy.svg?style=flat-square +[license-url]: LICENSE.md +[downloads-image]: http://img.shields.io/npm/dm/destroy.svg?style=flat-square +[downloads-url]: https://npmjs.org/package/destroy +[gittip-image]: https://img.shields.io/gittip/jonathanong.svg?style=flat-square +[gittip-url]: https://www.gittip.com/jonathanong/ diff --git a/node_modules/express/node_modules/send/node_modules/destroy/index.js b/node_modules/express/node_modules/send/node_modules/destroy/index.js new file mode 100644 index 0000000..b455217 --- /dev/null +++ b/node_modules/express/node_modules/send/node_modules/destroy/index.js @@ -0,0 +1,36 @@ +var ReadStream = require('fs').ReadStream +var Stream = require('stream') + +module.exports = function destroy(stream) { + if (stream instanceof ReadStream) { + return destroyReadStream(stream) + } + + if (!(stream instanceof Stream)) { + return stream + } + + if (typeof stream.destroy === 'function') { + stream.destroy() + } + + return stream +} + +function destroyReadStream(stream) { + stream.destroy() + + if (typeof stream.close === 'function') { + // node.js core bug work-around + stream.on('open', onopenClose) + } + + return stream +} + +function onopenClose() { + if (typeof this.fd === 'number') { + // actually close down the fd + this.close() + } +} diff --git a/node_modules/express/node_modules/send/node_modules/destroy/package.json b/node_modules/express/node_modules/send/node_modules/destroy/package.json new file mode 100644 index 0000000..8a58cad --- /dev/null +++ b/node_modules/express/node_modules/send/node_modules/destroy/package.json @@ -0,0 +1,66 @@ +{ + "name": "destroy", + "description": "destroy a stream if possible", + "version": "1.0.3", + "author": { + "name": "Jonathan Ong", + "email": "me@jongleberry.com", + "url": "http://jongleberry.com" + }, + "contributors": [ + { + "name": "Douglas Christopher Wilson", + "email": "doug@somethingdoug.com" + } + ], + "license": "MIT", + "repository": { + "type": "git", + "url": "https://github.com/stream-utils/destroy" + }, + "devDependencies": { + "istanbul": "0", + "mocha": "1" + }, + "scripts": { + "test": "mocha --reporter spec", + "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot", + "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter dot" + }, + "files": [ + "index.js" + ], + "keywords": [ + "stream", + "streams", + "destroy", + "cleanup", + "leak", + "fd" + ], + "gitHead": "50af95ece4a70202f9301bc3edc8f9fdbbad0f26", + "bugs": { + "url": "https://github.com/stream-utils/destroy/issues" + }, + "homepage": "https://github.com/stream-utils/destroy", + "_id": "destroy@1.0.3", + "_shasum": "b433b4724e71fd8551d9885174851c5fc377e2c9", + "_from": "destroy@1.0.3", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + }, + "maintainers": [ + { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + } + ], + "dist": { + "shasum": "b433b4724e71fd8551d9885174851c5fc377e2c9", + "tarball": "http://registry.npmjs.org/destroy/-/destroy-1.0.3.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/destroy/-/destroy-1.0.3.tgz" +} diff --git a/node_modules/express/node_modules/send/node_modules/mime/LICENSE b/node_modules/express/node_modules/send/node_modules/mime/LICENSE new file mode 100644 index 0000000..451fc45 --- /dev/null +++ b/node_modules/express/node_modules/send/node_modules/mime/LICENSE @@ -0,0 +1,19 @@ +Copyright (c) 2010 Benjamin Thomas, Robert Kieffer + +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/node_modules/express/node_modules/send/node_modules/mime/README.md b/node_modules/express/node_modules/send/node_modules/mime/README.md new file mode 100644 index 0000000..6ca19bd --- /dev/null +++ b/node_modules/express/node_modules/send/node_modules/mime/README.md @@ -0,0 +1,66 @@ +# mime + +Comprehensive MIME type mapping API. Includes all 600+ types and 800+ extensions defined by the Apache project, plus additional types submitted by the node.js community. + +## Install + +Install with [npm](http://github.com/isaacs/npm): + + npm install mime + +## API - Queries + +### mime.lookup(path) +Get the mime type associated with a file, if no mime type is found `application/octet-stream` is returned. Performs a case-insensitive lookup using the extension in `path` (the substring after the last '/' or '.'). E.g. + + var mime = require('mime'); + + mime.lookup('/path/to/file.txt'); // => 'text/plain' + mime.lookup('file.txt'); // => 'text/plain' + mime.lookup('.TXT'); // => 'text/plain' + mime.lookup('htm'); // => 'text/html' + +### mime.default_type +Sets the mime type returned when `mime.lookup` fails to find the extension searched for. (Default is `application/octet-stream`.) + +### mime.extension(type) +Get the default extension for `type` + + mime.extension('text/html'); // => 'html' + mime.extension('application/octet-stream'); // => 'bin' + +### mime.charsets.lookup() + +Map mime-type to charset + + mime.charsets.lookup('text/plain'); // => 'UTF-8' + +(The logic for charset lookups is pretty rudimentary. Feel free to suggest improvements.) + +## API - Defining Custom Types + +The following APIs allow you to add your own type mappings within your project. If you feel a type should be included as part of node-mime, see [requesting new types](https://github.com/broofa/node-mime/wiki/Requesting-New-Types). + +### mime.define() + +Add custom mime/extension mappings + + mime.define({ + 'text/x-some-format': ['x-sf', 'x-sft', 'x-sfml'], + 'application/x-my-type': ['x-mt', 'x-mtt'], + // etc ... + }); + + mime.lookup('x-sft'); // => 'text/x-some-format' + +The first entry in the extensions array is returned by `mime.extension()`. E.g. + + mime.extension('text/x-some-format'); // => 'x-sf' + +### mime.load(filepath) + +Load mappings from an Apache ".types" format file + + mime.load('./my_project.types'); + +The .types file format is simple - See the `types` dir for examples. diff --git a/node_modules/express/node_modules/send/node_modules/mime/mime.js b/node_modules/express/node_modules/send/node_modules/mime/mime.js new file mode 100644 index 0000000..48be0c5 --- /dev/null +++ b/node_modules/express/node_modules/send/node_modules/mime/mime.js @@ -0,0 +1,114 @@ +var path = require('path'); +var fs = require('fs'); + +function Mime() { + // Map of extension -> mime type + this.types = Object.create(null); + + // Map of mime type -> extension + this.extensions = Object.create(null); +} + +/** + * Define mimetype -> extension mappings. Each key is a mime-type that maps + * to an array of extensions associated with the type. The first extension is + * used as the default extension for the type. + * + * e.g. mime.define({'audio/ogg', ['oga', 'ogg', 'spx']}); + * + * @param map (Object) type definitions + */ +Mime.prototype.define = function (map) { + for (var type in map) { + var exts = map[type]; + + for (var i = 0; i < exts.length; i++) { + if (process.env.DEBUG_MIME && this.types[exts]) { + console.warn(this._loading.replace(/.*\//, ''), 'changes "' + exts[i] + '" extension type from ' + + this.types[exts] + ' to ' + type); + } + + this.types[exts[i]] = type; + } + + // Default extension is the first one we encounter + if (!this.extensions[type]) { + this.extensions[type] = exts[0]; + } + } +}; + +/** + * Load an Apache2-style ".types" file + * + * This may be called multiple times (it's expected). Where files declare + * overlapping types/extensions, the last file wins. + * + * @param file (String) path of file to load. + */ +Mime.prototype.load = function(file) { + + this._loading = file; + // Read file and split into lines + var map = {}, + content = fs.readFileSync(file, 'ascii'), + lines = content.split(/[\r\n]+/); + + lines.forEach(function(line) { + // Clean up whitespace/comments, and split into fields + var fields = line.replace(/\s*#.*|^\s*|\s*$/g, '').split(/\s+/); + map[fields.shift()] = fields; + }); + + this.define(map); + + this._loading = null; +}; + +/** + * Lookup a mime type based on extension + */ +Mime.prototype.lookup = function(path, fallback) { + var ext = path.replace(/.*[\.\/\\]/, '').toLowerCase(); + + return this.types[ext] || fallback || this.default_type; +}; + +/** + * Return file extension associated with a mime type + */ +Mime.prototype.extension = function(mimeType) { + var type = mimeType.match(/^\s*([^;\s]*)(?:;|\s|$)/)[1].toLowerCase(); + return this.extensions[type]; +}; + +// Default instance +var mime = new Mime(); + +// Load local copy of +// http://svn.apache.org/repos/asf/httpd/httpd/trunk/docs/conf/mime.types +mime.load(path.join(__dirname, 'types/mime.types')); + +// Load additional types from node.js community +mime.load(path.join(__dirname, 'types/node.types')); + +// Default type +mime.default_type = mime.lookup('bin'); + +// +// Additional API specific to the default instance +// + +mime.Mime = Mime; + +/** + * Lookup a charset based on mime type. + */ +mime.charsets = { + lookup: function(mimeType, fallback) { + // Assume text types are utf8 + return (/^text\//).test(mimeType) ? 'UTF-8' : fallback; + } +}; + +module.exports = mime; diff --git a/node_modules/express/node_modules/send/node_modules/mime/package.json b/node_modules/express/node_modules/send/node_modules/mime/package.json new file mode 100644 index 0000000..9782ade --- /dev/null +++ b/node_modules/express/node_modules/send/node_modules/mime/package.json @@ -0,0 +1,57 @@ +{ + "author": { + "name": "Robert Kieffer", + "email": "robert@broofa.com", + "url": "http://github.com/broofa" + }, + "contributors": [ + { + "name": "Benjamin Thomas", + "email": "benjamin@benjaminthomas.org", + "url": "http://github.com/bentomas" + } + ], + "dependencies": {}, + "description": "A comprehensive library for mime-type mapping", + "devDependencies": {}, + "keywords": [ + "util", + "mime" + ], + "main": "mime.js", + "name": "mime", + "repository": { + "url": "https://github.com/broofa/node-mime", + "type": "git" + }, + "version": "1.2.11", + "readme": "# mime\n\nComprehensive MIME type mapping API. Includes all 600+ types and 800+ extensions defined by the Apache project, plus additional types submitted by the node.js community.\n\n## Install\n\nInstall with [npm](http://github.com/isaacs/npm):\n\n npm install mime\n\n## API - Queries\n\n### mime.lookup(path)\nGet the mime type associated with a file, if no mime type is found `application/octet-stream` is returned. Performs a case-insensitive lookup using the extension in `path` (the substring after the last '/' or '.'). E.g.\n\n var mime = require('mime');\n\n mime.lookup('/path/to/file.txt'); // => 'text/plain'\n mime.lookup('file.txt'); // => 'text/plain'\n mime.lookup('.TXT'); // => 'text/plain'\n mime.lookup('htm'); // => 'text/html'\n\n### mime.default_type\nSets the mime type returned when `mime.lookup` fails to find the extension searched for. (Default is `application/octet-stream`.)\n\n### mime.extension(type)\nGet the default extension for `type`\n\n mime.extension('text/html'); // => 'html'\n mime.extension('application/octet-stream'); // => 'bin'\n\n### mime.charsets.lookup()\n\nMap mime-type to charset\n\n mime.charsets.lookup('text/plain'); // => 'UTF-8'\n\n(The logic for charset lookups is pretty rudimentary. Feel free to suggest improvements.)\n\n## API - Defining Custom Types\n\nThe following APIs allow you to add your own type mappings within your project. If you feel a type should be included as part of node-mime, see [requesting new types](https://github.com/broofa/node-mime/wiki/Requesting-New-Types).\n\n### mime.define()\n\nAdd custom mime/extension mappings\n\n mime.define({\n 'text/x-some-format': ['x-sf', 'x-sft', 'x-sfml'],\n 'application/x-my-type': ['x-mt', 'x-mtt'],\n // etc ...\n });\n\n mime.lookup('x-sft'); // => 'text/x-some-format'\n\nThe first entry in the extensions array is returned by `mime.extension()`. E.g.\n\n mime.extension('text/x-some-format'); // => 'x-sf'\n\n### mime.load(filepath)\n\nLoad mappings from an Apache \".types\" format file\n\n mime.load('./my_project.types');\n\nThe .types file format is simple - See the `types` dir for examples.\n", + "readmeFilename": "README.md", + "bugs": { + "url": "https://github.com/broofa/node-mime/issues" + }, + "_id": "mime@1.2.11", + "dist": { + "shasum": "58203eed86e3a5ef17aed2b7d9ebd47f0a60dd10", + "tarball": "http://registry.npmjs.org/mime/-/mime-1.2.11.tgz" + }, + "_from": "mime@1.2.11", + "_npmVersion": "1.3.6", + "_npmUser": { + "name": "broofa", + "email": "robert@broofa.com" + }, + "maintainers": [ + { + "name": "broofa", + "email": "robert@broofa.com" + }, + { + "name": "bentomas", + "email": "benjamin@benjaminthomas.org" + } + ], + "directories": {}, + "_shasum": "58203eed86e3a5ef17aed2b7d9ebd47f0a60dd10", + "_resolved": "https://registry.npmjs.org/mime/-/mime-1.2.11.tgz" +} diff --git a/node_modules/express/node_modules/send/node_modules/mime/test.js b/node_modules/express/node_modules/send/node_modules/mime/test.js new file mode 100644 index 0000000..2cda1c7 --- /dev/null +++ b/node_modules/express/node_modules/send/node_modules/mime/test.js @@ -0,0 +1,84 @@ +/** + * Usage: node test.js + */ + +var mime = require('./mime'); +var assert = require('assert'); +var path = require('path'); + +function eq(a, b) { + console.log('Test: ' + a + ' === ' + b); + assert.strictEqual.apply(null, arguments); +} + +console.log(Object.keys(mime.extensions).length + ' types'); +console.log(Object.keys(mime.types).length + ' extensions\n'); + +// +// Test mime lookups +// + +eq('text/plain', mime.lookup('text.txt')); // normal file +eq('text/plain', mime.lookup('TEXT.TXT')); // uppercase +eq('text/plain', mime.lookup('dir/text.txt')); // dir + file +eq('text/plain', mime.lookup('.text.txt')); // hidden file +eq('text/plain', mime.lookup('.txt')); // nameless +eq('text/plain', mime.lookup('txt')); // extension-only +eq('text/plain', mime.lookup('/txt')); // extension-less () +eq('text/plain', mime.lookup('\\txt')); // Windows, extension-less +eq('application/octet-stream', mime.lookup('text.nope')); // unrecognized +eq('fallback', mime.lookup('text.fallback', 'fallback')); // alternate default + +// +// Test extensions +// + +eq('txt', mime.extension(mime.types.text)); +eq('html', mime.extension(mime.types.htm)); +eq('bin', mime.extension('application/octet-stream')); +eq('bin', mime.extension('application/octet-stream ')); +eq('html', mime.extension(' text/html; charset=UTF-8')); +eq('html', mime.extension('text/html; charset=UTF-8 ')); +eq('html', mime.extension('text/html; charset=UTF-8')); +eq('html', mime.extension('text/html ; charset=UTF-8')); +eq('html', mime.extension('text/html;charset=UTF-8')); +eq('html', mime.extension('text/Html;charset=UTF-8')); +eq(undefined, mime.extension('unrecognized')); + +// +// Test node.types lookups +// + +eq('application/font-woff', mime.lookup('file.woff')); +eq('application/octet-stream', mime.lookup('file.buffer')); +eq('audio/mp4', mime.lookup('file.m4a')); +eq('font/opentype', mime.lookup('file.otf')); + +// +// Test charsets +// + +eq('UTF-8', mime.charsets.lookup('text/plain')); +eq(undefined, mime.charsets.lookup(mime.types.js)); +eq('fallback', mime.charsets.lookup('application/octet-stream', 'fallback')); + +// +// Test for overlaps between mime.types and node.types +// + +var apacheTypes = new mime.Mime(), nodeTypes = new mime.Mime(); +apacheTypes.load(path.join(__dirname, 'types/mime.types')); +nodeTypes.load(path.join(__dirname, 'types/node.types')); + +var keys = [].concat(Object.keys(apacheTypes.types)) + .concat(Object.keys(nodeTypes.types)); +keys.sort(); +for (var i = 1; i < keys.length; i++) { + if (keys[i] == keys[i-1]) { + console.warn('Warning: ' + + 'node.types defines ' + keys[i] + '->' + nodeTypes.types[keys[i]] + + ', mime.types defines ' + keys[i] + '->' + apacheTypes.types[keys[i]]); + } +} + +console.log('\nOK'); diff --git a/node_modules/express/node_modules/send/node_modules/mime/types/mime.types b/node_modules/express/node_modules/send/node_modules/mime/types/mime.types new file mode 100644 index 0000000..da8cd69 --- /dev/null +++ b/node_modules/express/node_modules/send/node_modules/mime/types/mime.types @@ -0,0 +1,1588 @@ +# This file maps Internet media types to unique file extension(s). +# Although created for httpd, this file is used by many software systems +# and has been placed in the public domain for unlimited redisribution. +# +# The table below contains both registered and (common) unregistered types. +# A type that has no unique extension can be ignored -- they are listed +# here to guide configurations toward known types and to make it easier to +# identify "new" types. File extensions are also commonly used to indicate +# content languages and encodings, so choose them carefully. +# +# Internet media types should be registered as described in RFC 4288. +# The registry is at . +# +# MIME type (lowercased) Extensions +# ============================================ ========== +# application/1d-interleaved-parityfec +# application/3gpp-ims+xml +# application/activemessage +application/andrew-inset ez +# application/applefile +application/applixware aw +application/atom+xml atom +application/atomcat+xml atomcat +# application/atomicmail +application/atomsvc+xml atomsvc +# application/auth-policy+xml +# application/batch-smtp +# application/beep+xml +# application/calendar+xml +# application/cals-1840 +# application/ccmp+xml +application/ccxml+xml ccxml +application/cdmi-capability cdmia +application/cdmi-container cdmic +application/cdmi-domain cdmid +application/cdmi-object cdmio +application/cdmi-queue cdmiq +# application/cea-2018+xml +# application/cellml+xml +# application/cfw +# application/cnrp+xml +# application/commonground +# application/conference-info+xml +# application/cpl+xml +# application/csta+xml +# application/cstadata+xml +application/cu-seeme cu +# application/cybercash +application/davmount+xml davmount +# application/dca-rft +# application/dec-dx +# application/dialog-info+xml +# application/dicom +# application/dns +application/docbook+xml dbk +# application/dskpp+xml +application/dssc+der dssc +application/dssc+xml xdssc +# application/dvcs +application/ecmascript ecma +# application/edi-consent +# application/edi-x12 +# application/edifact +application/emma+xml emma +# application/epp+xml +application/epub+zip epub +# application/eshop +# application/example +application/exi exi +# application/fastinfoset +# application/fastsoap +# application/fits +application/font-tdpfr pfr +# application/framework-attributes+xml +application/gml+xml gml +application/gpx+xml gpx +application/gxf gxf +# application/h224 +# application/held+xml +# application/http +application/hyperstudio stk +# application/ibe-key-request+xml +# application/ibe-pkg-reply+xml +# application/ibe-pp-data +# application/iges +# application/im-iscomposing+xml +# application/index +# application/index.cmd +# application/index.obj +# application/index.response +# application/index.vnd +application/inkml+xml ink inkml +# application/iotp +application/ipfix ipfix +# application/ipp +# application/isup +application/java-archive jar +application/java-serialized-object ser +application/java-vm class +application/javascript js +application/json json +application/jsonml+json jsonml +# application/kpml-request+xml +# application/kpml-response+xml +application/lost+xml lostxml +application/mac-binhex40 hqx +application/mac-compactpro cpt +# application/macwriteii +application/mads+xml mads +application/marc mrc +application/marcxml+xml mrcx +application/mathematica ma nb mb +# application/mathml-content+xml +# application/mathml-presentation+xml +application/mathml+xml mathml +# application/mbms-associated-procedure-description+xml +# application/mbms-deregister+xml +# application/mbms-envelope+xml +# application/mbms-msk+xml +# application/mbms-msk-response+xml +# application/mbms-protection-description+xml +# application/mbms-reception-report+xml +# application/mbms-register+xml +# application/mbms-register-response+xml +# application/mbms-user-service-description+xml +application/mbox mbox +# application/media_control+xml +application/mediaservercontrol+xml mscml +application/metalink+xml metalink +application/metalink4+xml meta4 +application/mets+xml mets +# application/mikey +application/mods+xml mods +# application/moss-keys +# application/moss-signature +# application/mosskey-data +# application/mosskey-request +application/mp21 m21 mp21 +application/mp4 mp4s +# application/mpeg4-generic +# application/mpeg4-iod +# application/mpeg4-iod-xmt +# application/msc-ivr+xml +# application/msc-mixer+xml +application/msword doc dot +application/mxf mxf +# application/nasdata +# application/news-checkgroups +# application/news-groupinfo +# application/news-transmission +# application/nss +# application/ocsp-request +# application/ocsp-response +application/octet-stream bin dms lrf mar so dist distz pkg bpk dump elc deploy +application/oda oda +application/oebps-package+xml opf +application/ogg ogx +application/omdoc+xml omdoc +application/onenote onetoc onetoc2 onetmp onepkg +application/oxps oxps +# application/parityfec +application/patch-ops-error+xml xer +application/pdf pdf +application/pgp-encrypted pgp +# application/pgp-keys +application/pgp-signature asc sig +application/pics-rules prf +# application/pidf+xml +# application/pidf-diff+xml +application/pkcs10 p10 +application/pkcs7-mime p7m p7c +application/pkcs7-signature p7s +application/pkcs8 p8 +application/pkix-attr-cert ac +application/pkix-cert cer +application/pkix-crl crl +application/pkix-pkipath pkipath +application/pkixcmp pki +application/pls+xml pls +# application/poc-settings+xml +application/postscript ai eps ps +# application/prs.alvestrand.titrax-sheet +application/prs.cww cww +# application/prs.nprend +# application/prs.plucker +# application/prs.rdf-xml-crypt +# application/prs.xsf+xml +application/pskc+xml pskcxml +# application/qsig +application/rdf+xml rdf +application/reginfo+xml rif +application/relax-ng-compact-syntax rnc +# application/remote-printing +application/resource-lists+xml rl +application/resource-lists-diff+xml rld +# application/riscos +# application/rlmi+xml +application/rls-services+xml rs +application/rpki-ghostbusters gbr +application/rpki-manifest mft +application/rpki-roa roa +# application/rpki-updown +application/rsd+xml rsd +application/rss+xml rss +application/rtf rtf +# application/rtx +# application/samlassertion+xml +# application/samlmetadata+xml +application/sbml+xml sbml +application/scvp-cv-request scq +application/scvp-cv-response scs +application/scvp-vp-request spq +application/scvp-vp-response spp +application/sdp sdp +# application/set-payment +application/set-payment-initiation setpay +# application/set-registration +application/set-registration-initiation setreg +# application/sgml +# application/sgml-open-catalog +application/shf+xml shf +# application/sieve +# application/simple-filter+xml +# application/simple-message-summary +# application/simplesymbolcontainer +# application/slate +# application/smil +application/smil+xml smi smil +# application/soap+fastinfoset +# application/soap+xml +application/sparql-query rq +application/sparql-results+xml srx +# application/spirits-event+xml +application/srgs gram +application/srgs+xml grxml +application/sru+xml sru +application/ssdl+xml ssdl +application/ssml+xml ssml +# application/tamp-apex-update +# application/tamp-apex-update-confirm +# application/tamp-community-update +# application/tamp-community-update-confirm +# application/tamp-error +# application/tamp-sequence-adjust +# application/tamp-sequence-adjust-confirm +# application/tamp-status-query +# application/tamp-status-response +# application/tamp-update +# application/tamp-update-confirm +application/tei+xml tei teicorpus +application/thraud+xml tfi +# application/timestamp-query +# application/timestamp-reply +application/timestamped-data tsd +# application/tve-trigger +# application/ulpfec +# application/vcard+xml +# application/vemmi +# application/vividence.scriptfile +# application/vnd.3gpp.bsf+xml +application/vnd.3gpp.pic-bw-large plb +application/vnd.3gpp.pic-bw-small psb +application/vnd.3gpp.pic-bw-var pvb +# application/vnd.3gpp.sms +# application/vnd.3gpp2.bcmcsinfo+xml +# application/vnd.3gpp2.sms +application/vnd.3gpp2.tcap tcap +application/vnd.3m.post-it-notes pwn +application/vnd.accpac.simply.aso aso +application/vnd.accpac.simply.imp imp +application/vnd.acucobol acu +application/vnd.acucorp atc acutc +application/vnd.adobe.air-application-installer-package+zip air +application/vnd.adobe.formscentral.fcdt fcdt +application/vnd.adobe.fxp fxp fxpl +# application/vnd.adobe.partial-upload +application/vnd.adobe.xdp+xml xdp +application/vnd.adobe.xfdf xfdf +# application/vnd.aether.imp +# application/vnd.ah-barcode +application/vnd.ahead.space ahead +application/vnd.airzip.filesecure.azf azf +application/vnd.airzip.filesecure.azs azs +application/vnd.amazon.ebook azw +application/vnd.americandynamics.acc acc +application/vnd.amiga.ami ami +# application/vnd.amundsen.maze+xml +application/vnd.android.package-archive apk +application/vnd.anser-web-certificate-issue-initiation cii +application/vnd.anser-web-funds-transfer-initiation fti +application/vnd.antix.game-component atx +application/vnd.apple.installer+xml mpkg +application/vnd.apple.mpegurl m3u8 +# application/vnd.arastra.swi +application/vnd.aristanetworks.swi swi +application/vnd.astraea-software.iota iota +application/vnd.audiograph aep +# application/vnd.autopackage +# application/vnd.avistar+xml +application/vnd.blueice.multipass mpm +# application/vnd.bluetooth.ep.oob +application/vnd.bmi bmi +application/vnd.businessobjects rep +# application/vnd.cab-jscript +# application/vnd.canon-cpdl +# application/vnd.canon-lips +# application/vnd.cendio.thinlinc.clientconf +application/vnd.chemdraw+xml cdxml +application/vnd.chipnuts.karaoke-mmd mmd +application/vnd.cinderella cdy +# application/vnd.cirpack.isdn-ext +application/vnd.claymore cla +application/vnd.cloanto.rp9 rp9 +application/vnd.clonk.c4group c4g c4d c4f c4p c4u +application/vnd.cluetrust.cartomobile-config c11amc +application/vnd.cluetrust.cartomobile-config-pkg c11amz +# application/vnd.collection+json +# application/vnd.commerce-battelle +application/vnd.commonspace csp +application/vnd.contact.cmsg cdbcmsg +application/vnd.cosmocaller cmc +application/vnd.crick.clicker clkx +application/vnd.crick.clicker.keyboard clkk +application/vnd.crick.clicker.palette clkp +application/vnd.crick.clicker.template clkt +application/vnd.crick.clicker.wordbank clkw +application/vnd.criticaltools.wbs+xml wbs +application/vnd.ctc-posml pml +# application/vnd.ctct.ws+xml +# application/vnd.cups-pdf +# application/vnd.cups-postscript +application/vnd.cups-ppd ppd +# application/vnd.cups-raster +# application/vnd.cups-raw +# application/vnd.curl +application/vnd.curl.car car +application/vnd.curl.pcurl pcurl +# application/vnd.cybank +application/vnd.dart dart +application/vnd.data-vision.rdz rdz +application/vnd.dece.data uvf uvvf uvd uvvd +application/vnd.dece.ttml+xml uvt uvvt +application/vnd.dece.unspecified uvx uvvx +application/vnd.dece.zip uvz uvvz +application/vnd.denovo.fcselayout-link fe_launch +# application/vnd.dir-bi.plate-dl-nosuffix +application/vnd.dna dna +application/vnd.dolby.mlp mlp +# application/vnd.dolby.mobile.1 +# application/vnd.dolby.mobile.2 +application/vnd.dpgraph dpg +application/vnd.dreamfactory dfac +application/vnd.ds-keypoint kpxx +application/vnd.dvb.ait ait +# application/vnd.dvb.dvbj +# application/vnd.dvb.esgcontainer +# application/vnd.dvb.ipdcdftnotifaccess +# application/vnd.dvb.ipdcesgaccess +# application/vnd.dvb.ipdcesgaccess2 +# application/vnd.dvb.ipdcesgpdd +# application/vnd.dvb.ipdcroaming +# application/vnd.dvb.iptv.alfec-base +# application/vnd.dvb.iptv.alfec-enhancement +# application/vnd.dvb.notif-aggregate-root+xml +# application/vnd.dvb.notif-container+xml +# application/vnd.dvb.notif-generic+xml +# application/vnd.dvb.notif-ia-msglist+xml +# application/vnd.dvb.notif-ia-registration-request+xml +# application/vnd.dvb.notif-ia-registration-response+xml +# application/vnd.dvb.notif-init+xml +# application/vnd.dvb.pfr +application/vnd.dvb.service svc +# application/vnd.dxr +application/vnd.dynageo geo +# application/vnd.easykaraoke.cdgdownload +# application/vnd.ecdis-update +application/vnd.ecowin.chart mag +# application/vnd.ecowin.filerequest +# application/vnd.ecowin.fileupdate +# application/vnd.ecowin.series +# application/vnd.ecowin.seriesrequest +# application/vnd.ecowin.seriesupdate +# application/vnd.emclient.accessrequest+xml +application/vnd.enliven nml +# application/vnd.eprints.data+xml +application/vnd.epson.esf esf +application/vnd.epson.msf msf +application/vnd.epson.quickanime qam +application/vnd.epson.salt slt +application/vnd.epson.ssf ssf +# application/vnd.ericsson.quickcall +application/vnd.eszigno3+xml es3 et3 +# application/vnd.etsi.aoc+xml +# application/vnd.etsi.cug+xml +# application/vnd.etsi.iptvcommand+xml +# application/vnd.etsi.iptvdiscovery+xml +# application/vnd.etsi.iptvprofile+xml +# application/vnd.etsi.iptvsad-bc+xml +# application/vnd.etsi.iptvsad-cod+xml +# application/vnd.etsi.iptvsad-npvr+xml +# application/vnd.etsi.iptvservice+xml +# application/vnd.etsi.iptvsync+xml +# application/vnd.etsi.iptvueprofile+xml +# application/vnd.etsi.mcid+xml +# application/vnd.etsi.overload-control-policy-dataset+xml +# application/vnd.etsi.sci+xml +# application/vnd.etsi.simservs+xml +# application/vnd.etsi.tsl+xml +# application/vnd.etsi.tsl.der +# application/vnd.eudora.data +application/vnd.ezpix-album ez2 +application/vnd.ezpix-package ez3 +# application/vnd.f-secure.mobile +application/vnd.fdf fdf +application/vnd.fdsn.mseed mseed +application/vnd.fdsn.seed seed dataless +# application/vnd.ffsns +# application/vnd.fints +application/vnd.flographit gph +application/vnd.fluxtime.clip ftc +# application/vnd.font-fontforge-sfd +application/vnd.framemaker fm frame maker book +application/vnd.frogans.fnc fnc +application/vnd.frogans.ltf ltf +application/vnd.fsc.weblaunch fsc +application/vnd.fujitsu.oasys oas +application/vnd.fujitsu.oasys2 oa2 +application/vnd.fujitsu.oasys3 oa3 +application/vnd.fujitsu.oasysgp fg5 +application/vnd.fujitsu.oasysprs bh2 +# application/vnd.fujixerox.art-ex +# application/vnd.fujixerox.art4 +# application/vnd.fujixerox.hbpl +application/vnd.fujixerox.ddd ddd +application/vnd.fujixerox.docuworks xdw +application/vnd.fujixerox.docuworks.binder xbd +# application/vnd.fut-misnet +application/vnd.fuzzysheet fzs +application/vnd.genomatix.tuxedo txd +# application/vnd.geocube+xml +application/vnd.geogebra.file ggb +application/vnd.geogebra.tool ggt +application/vnd.geometry-explorer gex gre +application/vnd.geonext gxt +application/vnd.geoplan g2w +application/vnd.geospace g3w +# application/vnd.globalplatform.card-content-mgt +# application/vnd.globalplatform.card-content-mgt-response +application/vnd.gmx gmx +application/vnd.google-earth.kml+xml kml +application/vnd.google-earth.kmz kmz +application/vnd.grafeq gqf gqs +# application/vnd.gridmp +application/vnd.groove-account gac +application/vnd.groove-help ghf +application/vnd.groove-identity-message gim +application/vnd.groove-injector grv +application/vnd.groove-tool-message gtm +application/vnd.groove-tool-template tpl +application/vnd.groove-vcard vcg +# application/vnd.hal+json +application/vnd.hal+xml hal +application/vnd.handheld-entertainment+xml zmm +application/vnd.hbci hbci +# application/vnd.hcl-bireports +application/vnd.hhe.lesson-player les +application/vnd.hp-hpgl hpgl +application/vnd.hp-hpid hpid +application/vnd.hp-hps hps +application/vnd.hp-jlyt jlt +application/vnd.hp-pcl pcl +application/vnd.hp-pclxl pclxl +# application/vnd.httphone +application/vnd.hydrostatix.sof-data sfd-hdstx +# application/vnd.hzn-3d-crossword +# application/vnd.ibm.afplinedata +# application/vnd.ibm.electronic-media +application/vnd.ibm.minipay mpy +application/vnd.ibm.modcap afp listafp list3820 +application/vnd.ibm.rights-management irm +application/vnd.ibm.secure-container sc +application/vnd.iccprofile icc icm +application/vnd.igloader igl +application/vnd.immervision-ivp ivp +application/vnd.immervision-ivu ivu +# application/vnd.informedcontrol.rms+xml +# application/vnd.informix-visionary +# application/vnd.infotech.project +# application/vnd.infotech.project+xml +# application/vnd.innopath.wamp.notification +application/vnd.insors.igm igm +application/vnd.intercon.formnet xpw xpx +application/vnd.intergeo i2g +# application/vnd.intertrust.digibox +# application/vnd.intertrust.nncp +application/vnd.intu.qbo qbo +application/vnd.intu.qfx qfx +# application/vnd.iptc.g2.conceptitem+xml +# application/vnd.iptc.g2.knowledgeitem+xml +# application/vnd.iptc.g2.newsitem+xml +# application/vnd.iptc.g2.newsmessage+xml +# application/vnd.iptc.g2.packageitem+xml +# application/vnd.iptc.g2.planningitem+xml +application/vnd.ipunplugged.rcprofile rcprofile +application/vnd.irepository.package+xml irp +application/vnd.is-xpr xpr +application/vnd.isac.fcs fcs +application/vnd.jam jam +# application/vnd.japannet-directory-service +# application/vnd.japannet-jpnstore-wakeup +# application/vnd.japannet-payment-wakeup +# application/vnd.japannet-registration +# application/vnd.japannet-registration-wakeup +# application/vnd.japannet-setstore-wakeup +# application/vnd.japannet-verification +# application/vnd.japannet-verification-wakeup +application/vnd.jcp.javame.midlet-rms rms +application/vnd.jisp jisp +application/vnd.joost.joda-archive joda +application/vnd.kahootz ktz ktr +application/vnd.kde.karbon karbon +application/vnd.kde.kchart chrt +application/vnd.kde.kformula kfo +application/vnd.kde.kivio flw +application/vnd.kde.kontour kon +application/vnd.kde.kpresenter kpr kpt +application/vnd.kde.kspread ksp +application/vnd.kde.kword kwd kwt +application/vnd.kenameaapp htke +application/vnd.kidspiration kia +application/vnd.kinar kne knp +application/vnd.koan skp skd skt skm +application/vnd.kodak-descriptor sse +application/vnd.las.las+xml lasxml +# application/vnd.liberty-request+xml +application/vnd.llamagraphics.life-balance.desktop lbd +application/vnd.llamagraphics.life-balance.exchange+xml lbe +application/vnd.lotus-1-2-3 123 +application/vnd.lotus-approach apr +application/vnd.lotus-freelance pre +application/vnd.lotus-notes nsf +application/vnd.lotus-organizer org +application/vnd.lotus-screencam scm +application/vnd.lotus-wordpro lwp +application/vnd.macports.portpkg portpkg +# application/vnd.marlin.drm.actiontoken+xml +# application/vnd.marlin.drm.conftoken+xml +# application/vnd.marlin.drm.license+xml +# application/vnd.marlin.drm.mdcf +application/vnd.mcd mcd +application/vnd.medcalcdata mc1 +application/vnd.mediastation.cdkey cdkey +# application/vnd.meridian-slingshot +application/vnd.mfer mwf +application/vnd.mfmp mfm +application/vnd.micrografx.flo flo +application/vnd.micrografx.igx igx +application/vnd.mif mif +# application/vnd.minisoft-hp3000-save +# application/vnd.mitsubishi.misty-guard.trustweb +application/vnd.mobius.daf daf +application/vnd.mobius.dis dis +application/vnd.mobius.mbk mbk +application/vnd.mobius.mqy mqy +application/vnd.mobius.msl msl +application/vnd.mobius.plc plc +application/vnd.mobius.txf txf +application/vnd.mophun.application mpn +application/vnd.mophun.certificate mpc +# application/vnd.motorola.flexsuite +# application/vnd.motorola.flexsuite.adsi +# application/vnd.motorola.flexsuite.fis +# application/vnd.motorola.flexsuite.gotap +# application/vnd.motorola.flexsuite.kmr +# application/vnd.motorola.flexsuite.ttc +# application/vnd.motorola.flexsuite.wem +# application/vnd.motorola.iprm +application/vnd.mozilla.xul+xml xul +application/vnd.ms-artgalry cil +# application/vnd.ms-asf +application/vnd.ms-cab-compressed cab +# application/vnd.ms-color.iccprofile +application/vnd.ms-excel xls xlm xla xlc xlt xlw +application/vnd.ms-excel.addin.macroenabled.12 xlam +application/vnd.ms-excel.sheet.binary.macroenabled.12 xlsb +application/vnd.ms-excel.sheet.macroenabled.12 xlsm +application/vnd.ms-excel.template.macroenabled.12 xltm +application/vnd.ms-fontobject eot +application/vnd.ms-htmlhelp chm +application/vnd.ms-ims ims +application/vnd.ms-lrm lrm +# application/vnd.ms-office.activex+xml +application/vnd.ms-officetheme thmx +# application/vnd.ms-opentype +# application/vnd.ms-package.obfuscated-opentype +application/vnd.ms-pki.seccat cat +application/vnd.ms-pki.stl stl +# application/vnd.ms-playready.initiator+xml +application/vnd.ms-powerpoint ppt pps pot +application/vnd.ms-powerpoint.addin.macroenabled.12 ppam +application/vnd.ms-powerpoint.presentation.macroenabled.12 pptm +application/vnd.ms-powerpoint.slide.macroenabled.12 sldm +application/vnd.ms-powerpoint.slideshow.macroenabled.12 ppsm +application/vnd.ms-powerpoint.template.macroenabled.12 potm +# application/vnd.ms-printing.printticket+xml +application/vnd.ms-project mpp mpt +# application/vnd.ms-tnef +# application/vnd.ms-wmdrm.lic-chlg-req +# application/vnd.ms-wmdrm.lic-resp +# application/vnd.ms-wmdrm.meter-chlg-req +# application/vnd.ms-wmdrm.meter-resp +application/vnd.ms-word.document.macroenabled.12 docm +application/vnd.ms-word.template.macroenabled.12 dotm +application/vnd.ms-works wps wks wcm wdb +application/vnd.ms-wpl wpl +application/vnd.ms-xpsdocument xps +application/vnd.mseq mseq +# application/vnd.msign +# application/vnd.multiad.creator +# application/vnd.multiad.creator.cif +# application/vnd.music-niff +application/vnd.musician mus +application/vnd.muvee.style msty +application/vnd.mynfc taglet +# application/vnd.ncd.control +# application/vnd.ncd.reference +# application/vnd.nervana +# application/vnd.netfpx +application/vnd.neurolanguage.nlu nlu +application/vnd.nitf ntf nitf +application/vnd.noblenet-directory nnd +application/vnd.noblenet-sealer nns +application/vnd.noblenet-web nnw +# application/vnd.nokia.catalogs +# application/vnd.nokia.conml+wbxml +# application/vnd.nokia.conml+xml +# application/vnd.nokia.isds-radio-presets +# application/vnd.nokia.iptv.config+xml +# application/vnd.nokia.landmark+wbxml +# application/vnd.nokia.landmark+xml +# application/vnd.nokia.landmarkcollection+xml +# application/vnd.nokia.n-gage.ac+xml +application/vnd.nokia.n-gage.data ngdat +application/vnd.nokia.n-gage.symbian.install n-gage +# application/vnd.nokia.ncd +# application/vnd.nokia.pcd+wbxml +# application/vnd.nokia.pcd+xml +application/vnd.nokia.radio-preset rpst +application/vnd.nokia.radio-presets rpss +application/vnd.novadigm.edm edm +application/vnd.novadigm.edx edx +application/vnd.novadigm.ext ext +# application/vnd.ntt-local.file-transfer +# application/vnd.ntt-local.sip-ta_remote +# application/vnd.ntt-local.sip-ta_tcp_stream +application/vnd.oasis.opendocument.chart odc +application/vnd.oasis.opendocument.chart-template otc +application/vnd.oasis.opendocument.database odb +application/vnd.oasis.opendocument.formula odf +application/vnd.oasis.opendocument.formula-template odft +application/vnd.oasis.opendocument.graphics odg +application/vnd.oasis.opendocument.graphics-template otg +application/vnd.oasis.opendocument.image odi +application/vnd.oasis.opendocument.image-template oti +application/vnd.oasis.opendocument.presentation odp +application/vnd.oasis.opendocument.presentation-template otp +application/vnd.oasis.opendocument.spreadsheet ods +application/vnd.oasis.opendocument.spreadsheet-template ots +application/vnd.oasis.opendocument.text odt +application/vnd.oasis.opendocument.text-master odm +application/vnd.oasis.opendocument.text-template ott +application/vnd.oasis.opendocument.text-web oth +# application/vnd.obn +# application/vnd.oftn.l10n+json +# application/vnd.oipf.contentaccessdownload+xml +# application/vnd.oipf.contentaccessstreaming+xml +# application/vnd.oipf.cspg-hexbinary +# application/vnd.oipf.dae.svg+xml +# application/vnd.oipf.dae.xhtml+xml +# application/vnd.oipf.mippvcontrolmessage+xml +# application/vnd.oipf.pae.gem +# application/vnd.oipf.spdiscovery+xml +# application/vnd.oipf.spdlist+xml +# application/vnd.oipf.ueprofile+xml +# application/vnd.oipf.userprofile+xml +application/vnd.olpc-sugar xo +# application/vnd.oma-scws-config +# application/vnd.oma-scws-http-request +# application/vnd.oma-scws-http-response +# application/vnd.oma.bcast.associated-procedure-parameter+xml +# application/vnd.oma.bcast.drm-trigger+xml +# application/vnd.oma.bcast.imd+xml +# application/vnd.oma.bcast.ltkm +# application/vnd.oma.bcast.notification+xml +# application/vnd.oma.bcast.provisioningtrigger +# application/vnd.oma.bcast.sgboot +# application/vnd.oma.bcast.sgdd+xml +# application/vnd.oma.bcast.sgdu +# application/vnd.oma.bcast.simple-symbol-container +# application/vnd.oma.bcast.smartcard-trigger+xml +# application/vnd.oma.bcast.sprov+xml +# application/vnd.oma.bcast.stkm +# application/vnd.oma.cab-address-book+xml +# application/vnd.oma.cab-feature-handler+xml +# application/vnd.oma.cab-pcc+xml +# application/vnd.oma.cab-user-prefs+xml +# application/vnd.oma.dcd +# application/vnd.oma.dcdc +application/vnd.oma.dd2+xml dd2 +# application/vnd.oma.drm.risd+xml +# application/vnd.oma.group-usage-list+xml +# application/vnd.oma.pal+xml +# application/vnd.oma.poc.detailed-progress-report+xml +# application/vnd.oma.poc.final-report+xml +# application/vnd.oma.poc.groups+xml +# application/vnd.oma.poc.invocation-descriptor+xml +# application/vnd.oma.poc.optimized-progress-report+xml +# application/vnd.oma.push +# application/vnd.oma.scidm.messages+xml +# application/vnd.oma.xcap-directory+xml +# application/vnd.omads-email+xml +# application/vnd.omads-file+xml +# application/vnd.omads-folder+xml +# application/vnd.omaloc-supl-init +application/vnd.openofficeorg.extension oxt +# application/vnd.openxmlformats-officedocument.custom-properties+xml +# application/vnd.openxmlformats-officedocument.customxmlproperties+xml +# application/vnd.openxmlformats-officedocument.drawing+xml +# application/vnd.openxmlformats-officedocument.drawingml.chart+xml +# application/vnd.openxmlformats-officedocument.drawingml.chartshapes+xml +# application/vnd.openxmlformats-officedocument.drawingml.diagramcolors+xml +# application/vnd.openxmlformats-officedocument.drawingml.diagramdata+xml +# application/vnd.openxmlformats-officedocument.drawingml.diagramlayout+xml +# application/vnd.openxmlformats-officedocument.drawingml.diagramstyle+xml +# application/vnd.openxmlformats-officedocument.extended-properties+xml +# application/vnd.openxmlformats-officedocument.presentationml.commentauthors+xml +# application/vnd.openxmlformats-officedocument.presentationml.comments+xml +# application/vnd.openxmlformats-officedocument.presentationml.handoutmaster+xml +# application/vnd.openxmlformats-officedocument.presentationml.notesmaster+xml +# application/vnd.openxmlformats-officedocument.presentationml.notesslide+xml +application/vnd.openxmlformats-officedocument.presentationml.presentation pptx +# application/vnd.openxmlformats-officedocument.presentationml.presentation.main+xml +# application/vnd.openxmlformats-officedocument.presentationml.presprops+xml +application/vnd.openxmlformats-officedocument.presentationml.slide sldx +# application/vnd.openxmlformats-officedocument.presentationml.slide+xml +# application/vnd.openxmlformats-officedocument.presentationml.slidelayout+xml +# application/vnd.openxmlformats-officedocument.presentationml.slidemaster+xml +application/vnd.openxmlformats-officedocument.presentationml.slideshow ppsx +# application/vnd.openxmlformats-officedocument.presentationml.slideshow.main+xml +# application/vnd.openxmlformats-officedocument.presentationml.slideupdateinfo+xml +# application/vnd.openxmlformats-officedocument.presentationml.tablestyles+xml +# application/vnd.openxmlformats-officedocument.presentationml.tags+xml +application/vnd.openxmlformats-officedocument.presentationml.template potx +# application/vnd.openxmlformats-officedocument.presentationml.template.main+xml +# application/vnd.openxmlformats-officedocument.presentationml.viewprops+xml +# application/vnd.openxmlformats-officedocument.spreadsheetml.calcchain+xml +# application/vnd.openxmlformats-officedocument.spreadsheetml.chartsheet+xml +# application/vnd.openxmlformats-officedocument.spreadsheetml.comments+xml +# application/vnd.openxmlformats-officedocument.spreadsheetml.connections+xml +# application/vnd.openxmlformats-officedocument.spreadsheetml.dialogsheet+xml +# application/vnd.openxmlformats-officedocument.spreadsheetml.externallink+xml +# application/vnd.openxmlformats-officedocument.spreadsheetml.pivotcachedefinition+xml +# application/vnd.openxmlformats-officedocument.spreadsheetml.pivotcacherecords+xml +# application/vnd.openxmlformats-officedocument.spreadsheetml.pivottable+xml +# application/vnd.openxmlformats-officedocument.spreadsheetml.querytable+xml +# application/vnd.openxmlformats-officedocument.spreadsheetml.revisionheaders+xml +# application/vnd.openxmlformats-officedocument.spreadsheetml.revisionlog+xml +# application/vnd.openxmlformats-officedocument.spreadsheetml.sharedstrings+xml +application/vnd.openxmlformats-officedocument.spreadsheetml.sheet xlsx +# application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml +# application/vnd.openxmlformats-officedocument.spreadsheetml.sheetmetadata+xml +# application/vnd.openxmlformats-officedocument.spreadsheetml.styles+xml +# application/vnd.openxmlformats-officedocument.spreadsheetml.table+xml +# application/vnd.openxmlformats-officedocument.spreadsheetml.tablesinglecells+xml +application/vnd.openxmlformats-officedocument.spreadsheetml.template xltx +# application/vnd.openxmlformats-officedocument.spreadsheetml.template.main+xml +# application/vnd.openxmlformats-officedocument.spreadsheetml.usernames+xml +# application/vnd.openxmlformats-officedocument.spreadsheetml.volatiledependencies+xml +# application/vnd.openxmlformats-officedocument.spreadsheetml.worksheet+xml +# application/vnd.openxmlformats-officedocument.theme+xml +# application/vnd.openxmlformats-officedocument.themeoverride+xml +# application/vnd.openxmlformats-officedocument.vmldrawing +# application/vnd.openxmlformats-officedocument.wordprocessingml.comments+xml +application/vnd.openxmlformats-officedocument.wordprocessingml.document docx +# application/vnd.openxmlformats-officedocument.wordprocessingml.document.glossary+xml +# application/vnd.openxmlformats-officedocument.wordprocessingml.document.main+xml +# application/vnd.openxmlformats-officedocument.wordprocessingml.endnotes+xml +# application/vnd.openxmlformats-officedocument.wordprocessingml.fonttable+xml +# application/vnd.openxmlformats-officedocument.wordprocessingml.footer+xml +# application/vnd.openxmlformats-officedocument.wordprocessingml.footnotes+xml +# application/vnd.openxmlformats-officedocument.wordprocessingml.numbering+xml +# application/vnd.openxmlformats-officedocument.wordprocessingml.settings+xml +# application/vnd.openxmlformats-officedocument.wordprocessingml.styles+xml +application/vnd.openxmlformats-officedocument.wordprocessingml.template dotx +# application/vnd.openxmlformats-officedocument.wordprocessingml.template.main+xml +# application/vnd.openxmlformats-officedocument.wordprocessingml.websettings+xml +# application/vnd.openxmlformats-package.core-properties+xml +# application/vnd.openxmlformats-package.digital-signature-xmlsignature+xml +# application/vnd.openxmlformats-package.relationships+xml +# application/vnd.quobject-quoxdocument +# application/vnd.osa.netdeploy +application/vnd.osgeo.mapguide.package mgp +# application/vnd.osgi.bundle +application/vnd.osgi.dp dp +application/vnd.osgi.subsystem esa +# application/vnd.otps.ct-kip+xml +application/vnd.palm pdb pqa oprc +# application/vnd.paos.xml +application/vnd.pawaafile paw +application/vnd.pg.format str +application/vnd.pg.osasli ei6 +# application/vnd.piaccess.application-licence +application/vnd.picsel efif +application/vnd.pmi.widget wg +# application/vnd.poc.group-advertisement+xml +application/vnd.pocketlearn plf +application/vnd.powerbuilder6 pbd +# application/vnd.powerbuilder6-s +# application/vnd.powerbuilder7 +# application/vnd.powerbuilder7-s +# application/vnd.powerbuilder75 +# application/vnd.powerbuilder75-s +# application/vnd.preminet +application/vnd.previewsystems.box box +application/vnd.proteus.magazine mgz +application/vnd.publishare-delta-tree qps +application/vnd.pvi.ptid1 ptid +# application/vnd.pwg-multiplexed +# application/vnd.pwg-xhtml-print+xml +# application/vnd.qualcomm.brew-app-res +application/vnd.quark.quarkxpress qxd qxt qwd qwt qxl qxb +# application/vnd.radisys.moml+xml +# application/vnd.radisys.msml+xml +# application/vnd.radisys.msml-audit+xml +# application/vnd.radisys.msml-audit-conf+xml +# application/vnd.radisys.msml-audit-conn+xml +# application/vnd.radisys.msml-audit-dialog+xml +# application/vnd.radisys.msml-audit-stream+xml +# application/vnd.radisys.msml-conf+xml +# application/vnd.radisys.msml-dialog+xml +# application/vnd.radisys.msml-dialog-base+xml +# application/vnd.radisys.msml-dialog-fax-detect+xml +# application/vnd.radisys.msml-dialog-fax-sendrecv+xml +# application/vnd.radisys.msml-dialog-group+xml +# application/vnd.radisys.msml-dialog-speech+xml +# application/vnd.radisys.msml-dialog-transform+xml +# application/vnd.rainstor.data +# application/vnd.rapid +application/vnd.realvnc.bed bed +application/vnd.recordare.musicxml mxl +application/vnd.recordare.musicxml+xml musicxml +# application/vnd.renlearn.rlprint +application/vnd.rig.cryptonote cryptonote +application/vnd.rim.cod cod +application/vnd.rn-realmedia rm +application/vnd.rn-realmedia-vbr rmvb +application/vnd.route66.link66+xml link66 +# application/vnd.rs-274x +# application/vnd.ruckus.download +# application/vnd.s3sms +application/vnd.sailingtracker.track st +# application/vnd.sbm.cid +# application/vnd.sbm.mid2 +# application/vnd.scribus +# application/vnd.sealed.3df +# application/vnd.sealed.csf +# application/vnd.sealed.doc +# application/vnd.sealed.eml +# application/vnd.sealed.mht +# application/vnd.sealed.net +# application/vnd.sealed.ppt +# application/vnd.sealed.tiff +# application/vnd.sealed.xls +# application/vnd.sealedmedia.softseal.html +# application/vnd.sealedmedia.softseal.pdf +application/vnd.seemail see +application/vnd.sema sema +application/vnd.semd semd +application/vnd.semf semf +application/vnd.shana.informed.formdata ifm +application/vnd.shana.informed.formtemplate itp +application/vnd.shana.informed.interchange iif +application/vnd.shana.informed.package ipk +application/vnd.simtech-mindmapper twd twds +application/vnd.smaf mmf +# application/vnd.smart.notebook +application/vnd.smart.teacher teacher +# application/vnd.software602.filler.form+xml +# application/vnd.software602.filler.form-xml-zip +application/vnd.solent.sdkm+xml sdkm sdkd +application/vnd.spotfire.dxp dxp +application/vnd.spotfire.sfs sfs +# application/vnd.sss-cod +# application/vnd.sss-dtf +# application/vnd.sss-ntf +application/vnd.stardivision.calc sdc +application/vnd.stardivision.draw sda +application/vnd.stardivision.impress sdd +application/vnd.stardivision.math smf +application/vnd.stardivision.writer sdw vor +application/vnd.stardivision.writer-global sgl +application/vnd.stepmania.package smzip +application/vnd.stepmania.stepchart sm +# application/vnd.street-stream +application/vnd.sun.xml.calc sxc +application/vnd.sun.xml.calc.template stc +application/vnd.sun.xml.draw sxd +application/vnd.sun.xml.draw.template std +application/vnd.sun.xml.impress sxi +application/vnd.sun.xml.impress.template sti +application/vnd.sun.xml.math sxm +application/vnd.sun.xml.writer sxw +application/vnd.sun.xml.writer.global sxg +application/vnd.sun.xml.writer.template stw +# application/vnd.sun.wadl+xml +application/vnd.sus-calendar sus susp +application/vnd.svd svd +# application/vnd.swiftview-ics +application/vnd.symbian.install sis sisx +application/vnd.syncml+xml xsm +application/vnd.syncml.dm+wbxml bdm +application/vnd.syncml.dm+xml xdm +# application/vnd.syncml.dm.notification +# application/vnd.syncml.ds.notification +application/vnd.tao.intent-module-archive tao +application/vnd.tcpdump.pcap pcap cap dmp +application/vnd.tmobile-livetv tmo +application/vnd.trid.tpt tpt +application/vnd.triscape.mxs mxs +application/vnd.trueapp tra +# application/vnd.truedoc +# application/vnd.ubisoft.webplayer +application/vnd.ufdl ufd ufdl +application/vnd.uiq.theme utz +application/vnd.umajin umj +application/vnd.unity unityweb +application/vnd.uoml+xml uoml +# application/vnd.uplanet.alert +# application/vnd.uplanet.alert-wbxml +# application/vnd.uplanet.bearer-choice +# application/vnd.uplanet.bearer-choice-wbxml +# application/vnd.uplanet.cacheop +# application/vnd.uplanet.cacheop-wbxml +# application/vnd.uplanet.channel +# application/vnd.uplanet.channel-wbxml +# application/vnd.uplanet.list +# application/vnd.uplanet.list-wbxml +# application/vnd.uplanet.listcmd +# application/vnd.uplanet.listcmd-wbxml +# application/vnd.uplanet.signal +application/vnd.vcx vcx +# application/vnd.vd-study +# application/vnd.vectorworks +# application/vnd.verimatrix.vcas +# application/vnd.vidsoft.vidconference +application/vnd.visio vsd vst vss vsw +application/vnd.visionary vis +# application/vnd.vividence.scriptfile +application/vnd.vsf vsf +# application/vnd.wap.sic +# application/vnd.wap.slc +application/vnd.wap.wbxml wbxml +application/vnd.wap.wmlc wmlc +application/vnd.wap.wmlscriptc wmlsc +application/vnd.webturbo wtb +# application/vnd.wfa.wsc +# application/vnd.wmc +# application/vnd.wmf.bootstrap +# application/vnd.wolfram.mathematica +# application/vnd.wolfram.mathematica.package +application/vnd.wolfram.player nbp +application/vnd.wordperfect wpd +application/vnd.wqd wqd +# application/vnd.wrq-hp3000-labelled +application/vnd.wt.stf stf +# application/vnd.wv.csp+wbxml +# application/vnd.wv.csp+xml +# application/vnd.wv.ssp+xml +application/vnd.xara xar +application/vnd.xfdl xfdl +# application/vnd.xfdl.webform +# application/vnd.xmi+xml +# application/vnd.xmpie.cpkg +# application/vnd.xmpie.dpkg +# application/vnd.xmpie.plan +# application/vnd.xmpie.ppkg +# application/vnd.xmpie.xlim +application/vnd.yamaha.hv-dic hvd +application/vnd.yamaha.hv-script hvs +application/vnd.yamaha.hv-voice hvp +application/vnd.yamaha.openscoreformat osf +application/vnd.yamaha.openscoreformat.osfpvg+xml osfpvg +# application/vnd.yamaha.remote-setup +application/vnd.yamaha.smaf-audio saf +application/vnd.yamaha.smaf-phrase spf +# application/vnd.yamaha.through-ngn +# application/vnd.yamaha.tunnel-udpencap +application/vnd.yellowriver-custom-menu cmp +application/vnd.zul zir zirz +application/vnd.zzazz.deck+xml zaz +application/voicexml+xml vxml +# application/vq-rtcpxr +# application/watcherinfo+xml +# application/whoispp-query +# application/whoispp-response +application/widget wgt +application/winhlp hlp +# application/wita +# application/wordperfect5.1 +application/wsdl+xml wsdl +application/wspolicy+xml wspolicy +application/x-7z-compressed 7z +application/x-abiword abw +application/x-ace-compressed ace +# application/x-amf +application/x-apple-diskimage dmg +application/x-authorware-bin aab x32 u32 vox +application/x-authorware-map aam +application/x-authorware-seg aas +application/x-bcpio bcpio +application/x-bittorrent torrent +application/x-blorb blb blorb +application/x-bzip bz +application/x-bzip2 bz2 boz +application/x-cbr cbr cba cbt cbz cb7 +application/x-cdlink vcd +application/x-cfs-compressed cfs +application/x-chat chat +application/x-chess-pgn pgn +application/x-conference nsc +# application/x-compress +application/x-cpio cpio +application/x-csh csh +application/x-debian-package deb udeb +application/x-dgc-compressed dgc +application/x-director dir dcr dxr cst cct cxt w3d fgd swa +application/x-doom wad +application/x-dtbncx+xml ncx +application/x-dtbook+xml dtb +application/x-dtbresource+xml res +application/x-dvi dvi +application/x-envoy evy +application/x-eva eva +application/x-font-bdf bdf +# application/x-font-dos +# application/x-font-framemaker +application/x-font-ghostscript gsf +# application/x-font-libgrx +application/x-font-linux-psf psf +application/x-font-otf otf +application/x-font-pcf pcf +application/x-font-snf snf +# application/x-font-speedo +# application/x-font-sunos-news +application/x-font-ttf ttf ttc +application/x-font-type1 pfa pfb pfm afm +application/font-woff woff +# application/x-font-vfont +application/x-freearc arc +application/x-futuresplash spl +application/x-gca-compressed gca +application/x-glulx ulx +application/x-gnumeric gnumeric +application/x-gramps-xml gramps +application/x-gtar gtar +# application/x-gzip +application/x-hdf hdf +application/x-install-instructions install +application/x-iso9660-image iso +application/x-java-jnlp-file jnlp +application/x-latex latex +application/x-lzh-compressed lzh lha +application/x-mie mie +application/x-mobipocket-ebook prc mobi +application/x-ms-application application +application/x-ms-shortcut lnk +application/x-ms-wmd wmd +application/x-ms-wmz wmz +application/x-ms-xbap xbap +application/x-msaccess mdb +application/x-msbinder obd +application/x-mscardfile crd +application/x-msclip clp +application/x-msdownload exe dll com bat msi +application/x-msmediaview mvb m13 m14 +application/x-msmetafile wmf wmz emf emz +application/x-msmoney mny +application/x-mspublisher pub +application/x-msschedule scd +application/x-msterminal trm +application/x-mswrite wri +application/x-netcdf nc cdf +application/x-nzb nzb +application/x-pkcs12 p12 pfx +application/x-pkcs7-certificates p7b spc +application/x-pkcs7-certreqresp p7r +application/x-rar-compressed rar +application/x-research-info-systems ris +application/x-sh sh +application/x-shar shar +application/x-shockwave-flash swf +application/x-silverlight-app xap +application/x-sql sql +application/x-stuffit sit +application/x-stuffitx sitx +application/x-subrip srt +application/x-sv4cpio sv4cpio +application/x-sv4crc sv4crc +application/x-t3vm-image t3 +application/x-tads gam +application/x-tar tar +application/x-tcl tcl +application/x-tex tex +application/x-tex-tfm tfm +application/x-texinfo texinfo texi +application/x-tgif obj +application/x-ustar ustar +application/x-wais-source src +application/x-x509-ca-cert der crt +application/x-xfig fig +application/x-xliff+xml xlf +application/x-xpinstall xpi +application/x-xz xz +application/x-zmachine z1 z2 z3 z4 z5 z6 z7 z8 +# application/x400-bp +application/xaml+xml xaml +# application/xcap-att+xml +# application/xcap-caps+xml +application/xcap-diff+xml xdf +# application/xcap-el+xml +# application/xcap-error+xml +# application/xcap-ns+xml +# application/xcon-conference-info-diff+xml +# application/xcon-conference-info+xml +application/xenc+xml xenc +application/xhtml+xml xhtml xht +# application/xhtml-voice+xml +application/xml xml xsl +application/xml-dtd dtd +# application/xml-external-parsed-entity +# application/xmpp+xml +application/xop+xml xop +application/xproc+xml xpl +application/xslt+xml xslt +application/xspf+xml xspf +application/xv+xml mxml xhvml xvml xvm +application/yang yang +application/yin+xml yin +application/zip zip +# audio/1d-interleaved-parityfec +# audio/32kadpcm +# audio/3gpp +# audio/3gpp2 +# audio/ac3 +audio/adpcm adp +# audio/amr +# audio/amr-wb +# audio/amr-wb+ +# audio/asc +# audio/atrac-advanced-lossless +# audio/atrac-x +# audio/atrac3 +audio/basic au snd +# audio/bv16 +# audio/bv32 +# audio/clearmode +# audio/cn +# audio/dat12 +# audio/dls +# audio/dsr-es201108 +# audio/dsr-es202050 +# audio/dsr-es202211 +# audio/dsr-es202212 +# audio/dv +# audio/dvi4 +# audio/eac3 +# audio/evrc +# audio/evrc-qcp +# audio/evrc0 +# audio/evrc1 +# audio/evrcb +# audio/evrcb0 +# audio/evrcb1 +# audio/evrcwb +# audio/evrcwb0 +# audio/evrcwb1 +# audio/example +# audio/fwdred +# audio/g719 +# audio/g722 +# audio/g7221 +# audio/g723 +# audio/g726-16 +# audio/g726-24 +# audio/g726-32 +# audio/g726-40 +# audio/g728 +# audio/g729 +# audio/g7291 +# audio/g729d +# audio/g729e +# audio/gsm +# audio/gsm-efr +# audio/gsm-hr-08 +# audio/ilbc +# audio/ip-mr_v2.5 +# audio/isac +# audio/l16 +# audio/l20 +# audio/l24 +# audio/l8 +# audio/lpc +audio/midi mid midi kar rmi +# audio/mobile-xmf +audio/mp4 mp4a +# audio/mp4a-latm +# audio/mpa +# audio/mpa-robust +audio/mpeg mpga mp2 mp2a mp3 m2a m3a +# audio/mpeg4-generic +# audio/musepack +audio/ogg oga ogg spx +# audio/opus +# audio/parityfec +# audio/pcma +# audio/pcma-wb +# audio/pcmu-wb +# audio/pcmu +# audio/prs.sid +# audio/qcelp +# audio/red +# audio/rtp-enc-aescm128 +# audio/rtp-midi +# audio/rtx +audio/s3m s3m +audio/silk sil +# audio/smv +# audio/smv0 +# audio/smv-qcp +# audio/sp-midi +# audio/speex +# audio/t140c +# audio/t38 +# audio/telephone-event +# audio/tone +# audio/uemclip +# audio/ulpfec +# audio/vdvi +# audio/vmr-wb +# audio/vnd.3gpp.iufp +# audio/vnd.4sb +# audio/vnd.audiokoz +# audio/vnd.celp +# audio/vnd.cisco.nse +# audio/vnd.cmles.radio-events +# audio/vnd.cns.anp1 +# audio/vnd.cns.inf1 +audio/vnd.dece.audio uva uvva +audio/vnd.digital-winds eol +# audio/vnd.dlna.adts +# audio/vnd.dolby.heaac.1 +# audio/vnd.dolby.heaac.2 +# audio/vnd.dolby.mlp +# audio/vnd.dolby.mps +# audio/vnd.dolby.pl2 +# audio/vnd.dolby.pl2x +# audio/vnd.dolby.pl2z +# audio/vnd.dolby.pulse.1 +audio/vnd.dra dra +audio/vnd.dts dts +audio/vnd.dts.hd dtshd +# audio/vnd.dvb.file +# audio/vnd.everad.plj +# audio/vnd.hns.audio +audio/vnd.lucent.voice lvp +audio/vnd.ms-playready.media.pya pya +# audio/vnd.nokia.mobile-xmf +# audio/vnd.nortel.vbk +audio/vnd.nuera.ecelp4800 ecelp4800 +audio/vnd.nuera.ecelp7470 ecelp7470 +audio/vnd.nuera.ecelp9600 ecelp9600 +# audio/vnd.octel.sbc +# audio/vnd.qcelp +# audio/vnd.rhetorex.32kadpcm +audio/vnd.rip rip +# audio/vnd.sealedmedia.softseal.mpeg +# audio/vnd.vmx.cvsd +# audio/vorbis +# audio/vorbis-config +audio/webm weba +audio/x-aac aac +audio/x-aiff aif aiff aifc +audio/x-caf caf +audio/x-flac flac +audio/x-matroska mka +audio/x-mpegurl m3u +audio/x-ms-wax wax +audio/x-ms-wma wma +audio/x-pn-realaudio ram ra +audio/x-pn-realaudio-plugin rmp +# audio/x-tta +audio/x-wav wav +audio/xm xm +chemical/x-cdx cdx +chemical/x-cif cif +chemical/x-cmdf cmdf +chemical/x-cml cml +chemical/x-csml csml +# chemical/x-pdb +chemical/x-xyz xyz +image/bmp bmp +image/cgm cgm +# image/example +# image/fits +image/g3fax g3 +image/gif gif +image/ief ief +# image/jp2 +image/jpeg jpeg jpg jpe +# image/jpm +# image/jpx +image/ktx ktx +# image/naplps +image/png png +image/prs.btif btif +# image/prs.pti +image/sgi sgi +image/svg+xml svg svgz +# image/t38 +image/tiff tiff tif +# image/tiff-fx +image/vnd.adobe.photoshop psd +# image/vnd.cns.inf2 +image/vnd.dece.graphic uvi uvvi uvg uvvg +image/vnd.dvb.subtitle sub +image/vnd.djvu djvu djv +image/vnd.dwg dwg +image/vnd.dxf dxf +image/vnd.fastbidsheet fbs +image/vnd.fpx fpx +image/vnd.fst fst +image/vnd.fujixerox.edmics-mmr mmr +image/vnd.fujixerox.edmics-rlc rlc +# image/vnd.globalgraphics.pgb +# image/vnd.microsoft.icon +# image/vnd.mix +image/vnd.ms-modi mdi +image/vnd.ms-photo wdp +image/vnd.net-fpx npx +# image/vnd.radiance +# image/vnd.sealed.png +# image/vnd.sealedmedia.softseal.gif +# image/vnd.sealedmedia.softseal.jpg +# image/vnd.svf +image/vnd.wap.wbmp wbmp +image/vnd.xiff xif +image/webp webp +image/x-3ds 3ds +image/x-cmu-raster ras +image/x-cmx cmx +image/x-freehand fh fhc fh4 fh5 fh7 +image/x-icon ico +image/x-mrsid-image sid +image/x-pcx pcx +image/x-pict pic pct +image/x-portable-anymap pnm +image/x-portable-bitmap pbm +image/x-portable-graymap pgm +image/x-portable-pixmap ppm +image/x-rgb rgb +image/x-tga tga +image/x-xbitmap xbm +image/x-xpixmap xpm +image/x-xwindowdump xwd +# message/cpim +# message/delivery-status +# message/disposition-notification +# message/example +# message/external-body +# message/feedback-report +# message/global +# message/global-delivery-status +# message/global-disposition-notification +# message/global-headers +# message/http +# message/imdn+xml +# message/news +# message/partial +message/rfc822 eml mime +# message/s-http +# message/sip +# message/sipfrag +# message/tracking-status +# message/vnd.si.simp +# model/example +model/iges igs iges +model/mesh msh mesh silo +model/vnd.collada+xml dae +model/vnd.dwf dwf +# model/vnd.flatland.3dml +model/vnd.gdl gdl +# model/vnd.gs-gdl +# model/vnd.gs.gdl +model/vnd.gtw gtw +# model/vnd.moml+xml +model/vnd.mts mts +# model/vnd.parasolid.transmit.binary +# model/vnd.parasolid.transmit.text +model/vnd.vtu vtu +model/vrml wrl vrml +model/x3d+binary x3db x3dbz +model/x3d+vrml x3dv x3dvz +model/x3d+xml x3d x3dz +# multipart/alternative +# multipart/appledouble +# multipart/byteranges +# multipart/digest +# multipart/encrypted +# multipart/example +# multipart/form-data +# multipart/header-set +# multipart/mixed +# multipart/parallel +# multipart/related +# multipart/report +# multipart/signed +# multipart/voice-message +# text/1d-interleaved-parityfec +text/cache-manifest appcache +text/calendar ics ifb +text/css css +text/csv csv +# text/directory +# text/dns +# text/ecmascript +# text/enriched +# text/example +# text/fwdred +text/html html htm +# text/javascript +text/n3 n3 +# text/parityfec +text/plain txt text conf def list log in +# text/prs.fallenstein.rst +text/prs.lines.tag dsc +# text/vnd.radisys.msml-basic-layout +# text/red +# text/rfc822-headers +text/richtext rtx +# text/rtf +# text/rtp-enc-aescm128 +# text/rtx +text/sgml sgml sgm +# text/t140 +text/tab-separated-values tsv +text/troff t tr roff man me ms +text/turtle ttl +# text/ulpfec +text/uri-list uri uris urls +text/vcard vcard +# text/vnd.abc +text/vnd.curl curl +text/vnd.curl.dcurl dcurl +text/vnd.curl.scurl scurl +text/vnd.curl.mcurl mcurl +# text/vnd.dmclientscript +text/vnd.dvb.subtitle sub +# text/vnd.esmertec.theme-descriptor +text/vnd.fly fly +text/vnd.fmi.flexstor flx +text/vnd.graphviz gv +text/vnd.in3d.3dml 3dml +text/vnd.in3d.spot spot +# text/vnd.iptc.newsml +# text/vnd.iptc.nitf +# text/vnd.latex-z +# text/vnd.motorola.reflex +# text/vnd.ms-mediapackage +# text/vnd.net2phone.commcenter.command +# text/vnd.si.uricatalogue +text/vnd.sun.j2me.app-descriptor jad +# text/vnd.trolltech.linguist +# text/vnd.wap.si +# text/vnd.wap.sl +text/vnd.wap.wml wml +text/vnd.wap.wmlscript wmls +text/x-asm s asm +text/x-c c cc cxx cpp h hh dic +text/x-fortran f for f77 f90 +text/x-java-source java +text/x-opml opml +text/x-pascal p pas +text/x-nfo nfo +text/x-setext etx +text/x-sfv sfv +text/x-uuencode uu +text/x-vcalendar vcs +text/x-vcard vcf +# text/xml +# text/xml-external-parsed-entity +# video/1d-interleaved-parityfec +video/3gpp 3gp +# video/3gpp-tt +video/3gpp2 3g2 +# video/bmpeg +# video/bt656 +# video/celb +# video/dv +# video/example +video/h261 h261 +video/h263 h263 +# video/h263-1998 +# video/h263-2000 +video/h264 h264 +# video/h264-rcdo +# video/h264-svc +video/jpeg jpgv +# video/jpeg2000 +video/jpm jpm jpgm +video/mj2 mj2 mjp2 +# video/mp1s +# video/mp2p +# video/mp2t +video/mp4 mp4 mp4v mpg4 +# video/mp4v-es +video/mpeg mpeg mpg mpe m1v m2v +# video/mpeg4-generic +# video/mpv +# video/nv +video/ogg ogv +# video/parityfec +# video/pointer +video/quicktime qt mov +# video/raw +# video/rtp-enc-aescm128 +# video/rtx +# video/smpte292m +# video/ulpfec +# video/vc1 +# video/vnd.cctv +video/vnd.dece.hd uvh uvvh +video/vnd.dece.mobile uvm uvvm +# video/vnd.dece.mp4 +video/vnd.dece.pd uvp uvvp +video/vnd.dece.sd uvs uvvs +video/vnd.dece.video uvv uvvv +# video/vnd.directv.mpeg +# video/vnd.directv.mpeg-tts +# video/vnd.dlna.mpeg-tts +video/vnd.dvb.file dvb +video/vnd.fvt fvt +# video/vnd.hns.video +# video/vnd.iptvforum.1dparityfec-1010 +# video/vnd.iptvforum.1dparityfec-2005 +# video/vnd.iptvforum.2dparityfec-1010 +# video/vnd.iptvforum.2dparityfec-2005 +# video/vnd.iptvforum.ttsavc +# video/vnd.iptvforum.ttsmpeg2 +# video/vnd.motorola.video +# video/vnd.motorola.videop +video/vnd.mpegurl mxu m4u +video/vnd.ms-playready.media.pyv pyv +# video/vnd.nokia.interleaved-multimedia +# video/vnd.nokia.videovoip +# video/vnd.objectvideo +# video/vnd.sealed.mpeg1 +# video/vnd.sealed.mpeg4 +# video/vnd.sealed.swf +# video/vnd.sealedmedia.softseal.mov +video/vnd.uvvu.mp4 uvu uvvu +video/vnd.vivo viv +video/webm webm +video/x-f4v f4v +video/x-fli fli +video/x-flv flv +video/x-m4v m4v +video/x-matroska mkv mk3d mks +video/x-mng mng +video/x-ms-asf asf asx +video/x-ms-vob vob +video/x-ms-wm wm +video/x-ms-wmv wmv +video/x-ms-wmx wmx +video/x-ms-wvx wvx +video/x-msvideo avi +video/x-sgi-movie movie +video/x-smv smv +x-conference/x-cooltalk ice diff --git a/node_modules/express/node_modules/send/node_modules/mime/types/node.types b/node_modules/express/node_modules/send/node_modules/mime/types/node.types new file mode 100644 index 0000000..55b2cf7 --- /dev/null +++ b/node_modules/express/node_modules/send/node_modules/mime/types/node.types @@ -0,0 +1,77 @@ +# What: WebVTT +# Why: To allow formats intended for marking up external text track resources. +# http://dev.w3.org/html5/webvtt/ +# Added by: niftylettuce +text/vtt vtt + +# What: Google Chrome Extension +# Why: To allow apps to (work) be served with the right content type header. +# http://codereview.chromium.org/2830017 +# Added by: niftylettuce +application/x-chrome-extension crx + +# What: HTC support +# Why: To properly render .htc files such as CSS3PIE +# Added by: niftylettuce +text/x-component htc + +# What: HTML5 application cache manifes ('.manifest' extension) +# Why: De-facto standard. Required by Mozilla browser when serving HTML5 apps +# per https://developer.mozilla.org/en/offline_resources_in_firefox +# Added by: louisremi +text/cache-manifest manifest + +# What: node binary buffer format +# Why: semi-standard extension w/in the node community +# Added by: tootallnate +application/octet-stream buffer + +# What: The "protected" MP-4 formats used by iTunes. +# Why: Required for streaming music to browsers (?) +# Added by: broofa +application/mp4 m4p +audio/mp4 m4a + +# What: Video format, Part of RFC1890 +# Why: See https://github.com/bentomas/node-mime/pull/6 +# Added by: mjrusso +video/MP2T ts + +# What: EventSource mime type +# Why: mime type of Server-Sent Events stream +# http://www.w3.org/TR/eventsource/#text-event-stream +# Added by: francois2metz +text/event-stream event-stream + +# What: Mozilla App manifest mime type +# Why: https://developer.mozilla.org/en/Apps/Manifest#Serving_manifests +# Added by: ednapiranha +application/x-web-app-manifest+json webapp + +# What: Lua file types +# Why: Googling around shows de-facto consensus on these +# Added by: creationix (Issue #45) +text/x-lua lua +application/x-lua-bytecode luac + +# What: Markdown files, as per http://daringfireball.net/projects/markdown/syntax +# Why: http://stackoverflow.com/questions/10701983/what-is-the-mime-type-for-markdown +# Added by: avoidwork +text/x-markdown markdown md mkd + +# What: ini files +# Why: because they're just text files +# Added by: Matthew Kastor +text/plain ini + +# What: DASH Adaptive Streaming manifest +# Why: https://developer.mozilla.org/en-US/docs/DASH_Adaptive_Streaming_for_HTML_5_Video +# Added by: eelcocramer +application/dash+xml mdp + +# What: OpenType font files - http://www.microsoft.com/typography/otspec/ +# Why: Browsers usually ignore the font MIME types and sniff the content, +# but Chrome, shows a warning if OpenType fonts aren't served with +# the `font/opentype` MIME type: http://i.imgur.com/8c5RN8M.png. +# Added by: alrra +font/opentype otf diff --git a/node_modules/express/node_modules/send/node_modules/ms/.npmignore b/node_modules/express/node_modules/send/node_modules/ms/.npmignore new file mode 100644 index 0000000..d1aa0ce --- /dev/null +++ b/node_modules/express/node_modules/send/node_modules/ms/.npmignore @@ -0,0 +1,5 @@ +node_modules +test +History.md +Makefile +component.json diff --git a/node_modules/express/node_modules/send/node_modules/ms/README.md b/node_modules/express/node_modules/send/node_modules/ms/README.md new file mode 100644 index 0000000..d4ab12a --- /dev/null +++ b/node_modules/express/node_modules/send/node_modules/ms/README.md @@ -0,0 +1,33 @@ +# ms.js: miliseconds conversion utility + +```js +ms('1d') // 86400000 +ms('10h') // 36000000 +ms('2h') // 7200000 +ms('1m') // 60000 +ms('5s') // 5000 +ms('100') // 100 +``` + +```js +ms(60000) // "1m" +ms(2 * 60000) // "2m" +ms(ms('10 hours')) // "10h" +``` + +```js +ms(60000, { long: true }) // "1 minute" +ms(2 * 60000, { long: true }) // "2 minutes" +ms(ms('10 hours', { long: true })) // "10 hours" +``` + +- Node/Browser compatible. Published as `ms` in NPM. +- If a number is supplied to `ms`, a string with a unit is returned. +- If a string that contains the number is supplied, it returns it as +a number (e.g: it returns `100` for `'100'`). +- If you pass a string with a number and a valid unit, the number of +equivalent ms is returned. + +## License + +MIT \ No newline at end of file diff --git a/node_modules/express/node_modules/send/node_modules/ms/index.js b/node_modules/express/node_modules/send/node_modules/ms/index.js new file mode 100644 index 0000000..c5847f8 --- /dev/null +++ b/node_modules/express/node_modules/send/node_modules/ms/index.js @@ -0,0 +1,111 @@ +/** + * Helpers. + */ + +var s = 1000; +var m = s * 60; +var h = m * 60; +var d = h * 24; +var y = d * 365.25; + +/** + * Parse or format the given `val`. + * + * Options: + * + * - `long` verbose formatting [false] + * + * @param {String|Number} val + * @param {Object} options + * @return {String|Number} + * @api public + */ + +module.exports = function(val, options){ + options = options || {}; + if ('string' == typeof val) return parse(val); + return options.long + ? long(val) + : short(val); +}; + +/** + * Parse the given `str` and return milliseconds. + * + * @param {String} str + * @return {Number} + * @api private + */ + +function parse(str) { + var match = /^((?:\d+)?\.?\d+) *(ms|seconds?|s|minutes?|m|hours?|h|days?|d|years?|y)?$/i.exec(str); + if (!match) return; + var n = parseFloat(match[1]); + var type = (match[2] || 'ms').toLowerCase(); + switch (type) { + case 'years': + case 'year': + case 'y': + return n * y; + case 'days': + case 'day': + case 'd': + return n * d; + case 'hours': + case 'hour': + case 'h': + return n * h; + case 'minutes': + case 'minute': + case 'm': + return n * m; + case 'seconds': + case 'second': + case 's': + return n * s; + case 'ms': + return n; + } +} + +/** + * Short format for `ms`. + * + * @param {Number} ms + * @return {String} + * @api private + */ + +function short(ms) { + if (ms >= d) return Math.round(ms / d) + 'd'; + if (ms >= h) return Math.round(ms / h) + 'h'; + if (ms >= m) return Math.round(ms / m) + 'm'; + if (ms >= s) return Math.round(ms / s) + 's'; + return ms + 'ms'; +} + +/** + * Long format for `ms`. + * + * @param {Number} ms + * @return {String} + * @api private + */ + +function long(ms) { + return plural(ms, d, 'day') + || plural(ms, h, 'hour') + || plural(ms, m, 'minute') + || plural(ms, s, 'second') + || ms + ' ms'; +} + +/** + * Pluralization helper. + */ + +function plural(ms, n, name) { + if (ms < n) return; + if (ms < n * 1.5) return Math.floor(ms / n) + ' ' + name; + return Math.ceil(ms / n) + ' ' + name + 's'; +} diff --git a/node_modules/express/node_modules/send/node_modules/ms/package.json b/node_modules/express/node_modules/send/node_modules/ms/package.json new file mode 100644 index 0000000..654cde8 --- /dev/null +++ b/node_modules/express/node_modules/send/node_modules/ms/package.json @@ -0,0 +1,47 @@ +{ + "name": "ms", + "version": "0.6.2", + "description": "Tiny ms conversion utility", + "repository": { + "type": "git", + "url": "git://github.com/guille/ms.js.git" + }, + "main": "./index", + "devDependencies": { + "mocha": "*", + "expect.js": "*", + "serve": "*" + }, + "component": { + "scripts": { + "ms/index.js": "index.js" + } + }, + "readme": "# ms.js: miliseconds conversion utility\n\n```js\nms('1d') // 86400000\nms('10h') // 36000000\nms('2h') // 7200000\nms('1m') // 60000\nms('5s') // 5000\nms('100') // 100\n```\n\n```js\nms(60000) // \"1m\"\nms(2 * 60000) // \"2m\"\nms(ms('10 hours')) // \"10h\"\n```\n\n```js\nms(60000, { long: true }) // \"1 minute\"\nms(2 * 60000, { long: true }) // \"2 minutes\"\nms(ms('10 hours', { long: true })) // \"10 hours\"\n```\n\n- Node/Browser compatible. Published as `ms` in NPM.\n- If a number is supplied to `ms`, a string with a unit is returned.\n- If a string that contains the number is supplied, it returns it as\na number (e.g: it returns `100` for `'100'`).\n- If you pass a string with a number and a valid unit, the number of\nequivalent ms is returned.\n\n## License\n\nMIT", + "readmeFilename": "README.md", + "bugs": { + "url": "https://github.com/guille/ms.js/issues" + }, + "_id": "ms@0.6.2", + "dist": { + "shasum": "d89c2124c6fdc1353d65a8b77bf1aac4b193708c", + "tarball": "http://registry.npmjs.org/ms/-/ms-0.6.2.tgz" + }, + "_from": "ms@0.6.2", + "_npmVersion": "1.2.30", + "_npmUser": { + "name": "rauchg", + "email": "rauchg@gmail.com" + }, + "maintainers": [ + { + "name": "rauchg", + "email": "rauchg@gmail.com" + } + ], + "directories": {}, + "_shasum": "d89c2124c6fdc1353d65a8b77bf1aac4b193708c", + "_resolved": "https://registry.npmjs.org/ms/-/ms-0.6.2.tgz", + "homepage": "https://github.com/guille/ms.js", + "scripts": {} +} diff --git a/node_modules/express/node_modules/send/package.json b/node_modules/express/node_modules/send/package.json new file mode 100644 index 0000000..74d6f9c --- /dev/null +++ b/node_modules/express/node_modules/send/package.json @@ -0,0 +1,85 @@ +{ + "name": "send", + "description": "Better streaming static file server with Range and conditional-GET support", + "version": "0.9.2", + "author": { + "name": "TJ Holowaychuk", + "email": "tj@vision-media.ca" + }, + "contributors": [ + { + "name": "Douglas Christopher Wilson", + "email": "doug@somethingdoug.com" + } + ], + "license": "MIT", + "repository": { + "type": "git", + "url": "https://github.com/visionmedia/send" + }, + "keywords": [ + "static", + "file", + "server" + ], + "dependencies": { + "debug": "~2.0.0", + "depd": "0.4.5", + "destroy": "1.0.3", + "escape-html": "1.0.1", + "etag": "~1.3.1", + "fresh": "0.2.4", + "mime": "1.2.11", + "ms": "0.6.2", + "on-finished": "2.1.0", + "range-parser": "~1.0.2" + }, + "devDependencies": { + "istanbul": "0.3.2", + "mocha": "~1.21.0", + "should": "~4.0.0", + "supertest": "~0.13.0" + }, + "files": [ + "History.md", + "LICENSE", + "index.js" + ], + "engines": { + "node": ">= 0.8.0" + }, + "scripts": { + "test": "mocha --check-leaks --reporter spec --bail", + "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --check-leaks --reporter dot", + "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --check-leaks --reporter spec" + }, + "gitHead": "c2b125b19c1f0f1f3c9bcd72be32d1ea54f2f620", + "bugs": { + "url": "https://github.com/visionmedia/send/issues" + }, + "homepage": "https://github.com/visionmedia/send", + "_id": "send@0.9.2", + "_shasum": "77d22a0f462604451917075c6f52e69c2b3b6e25", + "_from": "send@0.9.2", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + "maintainers": [ + { + "name": "tjholowaychuk", + "email": "tj@vision-media.ca" + }, + { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + } + ], + "dist": { + "shasum": "77d22a0f462604451917075c6f52e69c2b3b6e25", + "tarball": "http://registry.npmjs.org/send/-/send-0.9.2.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/send/-/send-0.9.2.tgz" +} diff --git a/node_modules/express/node_modules/serve-static/HISTORY.md b/node_modules/express/node_modules/serve-static/HISTORY.md new file mode 100644 index 0000000..bce3ac3 --- /dev/null +++ b/node_modules/express/node_modules/serve-static/HISTORY.md @@ -0,0 +1,176 @@ +1.6.2 / 2014-09-15 +================== + + * deps: send@0.9.2 + - deps: depd@0.4.5 + - deps: etag@~1.3.1 + - deps: range-parser@~1.0.2 + +1.6.1 / 2014-09-07 +================== + + * deps: send@0.9.1 + - deps: fresh@0.2.4 + +1.6.0 / 2014-09-07 +================== + + * deps: send@0.9.0 + - Add `lastModified` option + - Use `etag` to generate `ETag` header + - deps: debug@~2.0.0 + +1.5.4 / 2014-09-04 +================== + + * deps: send@0.8.5 + - Fix a path traversal issue when using `root` + - Fix malicious path detection for empty string path + +1.5.3 / 2014-08-17 +================== + + * deps: send@0.8.3 + +1.5.2 / 2014-08-14 +================== + + * deps: send@0.8.2 + - Work around `fd` leak in Node.js 0.10 for `fs.ReadStream` + +1.5.1 / 2014-08-09 +================== + + * Fix parsing of weird `req.originalUrl` values + * deps: parseurl@~1.3.0 + * deps: utils-merge@1.0.0 + +1.5.0 / 2014-08-05 +================== + + * deps: send@0.8.1 + - Add `extensions` option + +1.4.4 / 2014-08-04 +================== + + * deps: send@0.7.4 + - Fix serving index files without root dir + +1.4.3 / 2014-07-29 +================== + + * deps: send@0.7.3 + - Fix incorrect 403 on Windows and Node.js 0.11 + +1.4.2 / 2014-07-27 +================== + + * deps: send@0.7.2 + - deps: depd@0.4.4 + +1.4.1 / 2014-07-26 +================== + + * deps: send@0.7.1 + - deps: depd@0.4.3 + +1.4.0 / 2014-07-21 +================== + + * deps: parseurl@~1.2.0 + - Cache URLs based on original value + - Remove no-longer-needed URL mis-parse work-around + - Simplify the "fast-path" `RegExp` + * deps: send@0.7.0 + - Add `dotfiles` option + - deps: debug@1.0.4 + - deps: depd@0.4.2 + +1.3.2 / 2014-07-11 +================== + + * deps: send@0.6.0 + - Cap `maxAge` value to 1 year + - deps: debug@1.0.3 + +1.3.1 / 2014-07-09 +================== + + * deps: parseurl@~1.1.3 + - faster parsing of href-only URLs + +1.3.0 / 2014-06-28 +================== + + * Add `setHeaders` option + * Include HTML link in redirect response + * deps: send@0.5.0 + - Accept string for `maxAge` (converted by `ms`) + +1.2.3 / 2014-06-11 +================== + + * deps: send@0.4.3 + - Do not throw un-catchable error on file open race condition + - Use `escape-html` for HTML escaping + - deps: debug@1.0.2 + - deps: finished@1.2.2 + - deps: fresh@0.2.2 + +1.2.2 / 2014-06-09 +================== + + * deps: send@0.4.2 + - fix "event emitter leak" warnings + - deps: debug@1.0.1 + - deps: finished@1.2.1 + +1.2.1 / 2014-06-02 +================== + + * use `escape-html` for escaping + * deps: send@0.4.1 + - Send `max-age` in `Cache-Control` in correct format + +1.2.0 / 2014-05-29 +================== + + * deps: send@0.4.0 + - Calculate ETag with md5 for reduced collisions + - Fix wrong behavior when index file matches directory + - Ignore stream errors after request ends + - Skip directories in index file search + - deps: debug@0.8.1 + +1.1.0 / 2014-04-24 +================== + + * Accept options directly to `send` module + * deps: send@0.3.0 + +1.0.4 / 2014-04-07 +================== + + * Resolve relative paths at middleware setup + * Use parseurl to parse the URL from request + +1.0.3 / 2014-03-20 +================== + + * Do not rely on connect-like environments + +1.0.2 / 2014-03-06 +================== + + * deps: send@0.2.0 + +1.0.1 / 2014-03-05 +================== + + * Add mime export for back-compat + +1.0.0 / 2014-03-05 +================== + + * Genesis from `connect` diff --git a/node_modules/express/node_modules/serve-static/LICENSE b/node_modules/express/node_modules/serve-static/LICENSE new file mode 100644 index 0000000..b7bc085 --- /dev/null +++ b/node_modules/express/node_modules/serve-static/LICENSE @@ -0,0 +1,25 @@ +(The MIT License) + +Copyright (c) 2010 Sencha Inc. +Copyright (c) 2011 LearnBoost +Copyright (c) 2011 TJ Holowaychuk +Copyright (c) 2014 Douglas Christopher Wilson + +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/node_modules/express/node_modules/serve-static/README.md b/node_modules/express/node_modules/serve-static/README.md new file mode 100644 index 0000000..ae03fa5 --- /dev/null +++ b/node_modules/express/node_modules/serve-static/README.md @@ -0,0 +1,149 @@ +# serve-static + +[![NPM Version][npm-image]][npm-url] +[![NPM Downloads][downloads-image]][downloads-url] +[![Build Status][travis-image]][travis-url] +[![Test Coverage][coveralls-image]][coveralls-url] +[![Gratipay][gratipay-image]][gratipay-url] + +## Install + +```sh +$ npm install serve-static +``` + +## API + +```js +var serveStatic = require('serve-static') +``` + +### serveStatic(root, options) + +Create a new middleware function to serve files from within a given root +directory. The file to serve will be determined by combining `req.url` +with the provided root directory. When a file is not found, instead of +sending a 404 response, this module will instead call `next()` to move on +to the next middleware, allowing for stacking and fall-backs. + +#### Options + +##### dotfiles + + Set how "dotfiles" are treated when encountered. A dotfile is a file +or directory that begins with a dot ("."). Note this check is done on +the path itself without checking if the path actually exists on the +disk. If `root` is specified, only the dotfiles above the root are +checked (i.e. the root itself can be within a dotfile when when set +to "deny"). + +The default value is `'ignore'`. + + - `'allow'` No special treatment for dotfiles. + - `'deny'` Send a 403 for any request for a dotfile. + - `'ignore'` Pretend like the dotfile does not exist and call `next()`. + +##### etag + +Enable or disable etag generation, defaults to true. + +##### extensions + +Set file extension fallbacks. When set, if a file is not found, the given +extensions will be added to the file name and search for. The first that +exists will be served. Example: `['html', 'htm']`. + +The default value is `false`. + +##### index + +By default this module will send "index.html" files in response to a request +on a directory. To disable this set `false` or to supply a new index pass a +string or an array in preferred order. + +##### lastModified + +Enable or disable `Last-Modified` header, defaults to true. Uses the file +system's last modified value. + +##### maxAge + +Provide a max-age in milliseconds for http caching, defaults to 0. This +can also be a string accepted by the [ms](https://www.npmjs.org/package/ms#readme) +module. + +##### redirect + +Redirect to trailing "/" when the pathname is a dir. Defaults to `true`. + +##### setHeaders + +Function to set custom headers on response. + +## Examples + +### Serve files with vanilla node.js http server + +```js +var finalhandler = require('finalhandler') +var http = require('http') +var serveStatic = require('serve-static') + +// Serve up public/ftp folder +var serve = serveStatic('public/ftp', {'index': ['index.html', 'index.htm']}) + +// Create server +var server = http.createServer(function(req, res){ + var done = finalhandler(req, res) + serve(req, res, done) +}) + +// Listen +server.listen(3000) +``` + +### Serve all files from ftp folder + +```js +var connect = require('connect') +var serveStatic = require('serve-static') + +var app = connect() + +app.use(serveStatic('public/ftp', {'index': ['default.html', 'default.htm']})) +app.listen(3000) +``` + +### Serve all files as downloads + +```js +var express = require('express') +var serveStatic = require('serve-static') + +var app = express() + +app.use(serveStatic('public/ftp', { + 'index': false, + 'setHeaders': setHeaders +})) +app.listen(3000) + +function setHeaders(res, path) { + res.attachment(path) +} +``` + +## License + +[MIT](LICENSE) + +[npm-image]: https://img.shields.io/npm/v/serve-static.svg?style=flat +[npm-url]: https://npmjs.org/package/serve-static +[travis-image]: https://img.shields.io/travis/expressjs/serve-static.svg?style=flat +[travis-url]: https://travis-ci.org/expressjs/serve-static +[coveralls-image]: https://img.shields.io/coveralls/expressjs/serve-static.svg?style=flat +[coveralls-url]: https://coveralls.io/r/expressjs/serve-static +[downloads-image]: https://img.shields.io/npm/dm/serve-static.svg?style=flat +[downloads-url]: https://npmjs.org/package/serve-static +[gratipay-image]: https://img.shields.io/gratipay/dougwilson.svg?style=flat +[gratipay-url]: https://gratipay.com/dougwilson/ diff --git a/node_modules/express/node_modules/serve-static/index.js b/node_modules/express/node_modules/serve-static/index.js new file mode 100644 index 0000000..e9c0153 --- /dev/null +++ b/node_modules/express/node_modules/serve-static/index.js @@ -0,0 +1,113 @@ +/*! + * serve-static + * Copyright(c) 2010 Sencha Inc. + * Copyright(c) 2011 TJ Holowaychuk + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module dependencies. + */ + +var escapeHtml = require('escape-html'); +var merge = require('utils-merge'); +var parseurl = require('parseurl'); +var resolve = require('path').resolve; +var send = require('send'); +var url = require('url'); + +/** + * @param {String} root + * @param {Object} options + * @return {Function} + * @api public + */ + +exports = module.exports = function serveStatic(root, options) { + if (!root) { + throw new TypeError('root path required') + } + + if (typeof root !== 'string') { + throw new TypeError('root path must be a string') + } + + // copy options object + options = merge({}, options) + + // resolve root to absolute + root = resolve(root) + + // default redirect + var redirect = options.redirect !== false + + // headers listener + var setHeaders = options.setHeaders + delete options.setHeaders + + if (setHeaders && typeof setHeaders !== 'function') { + throw new TypeError('option setHeaders must be function') + } + + // setup options for send + options.maxage = options.maxage || options.maxAge || 0 + options.root = root + + return function serveStatic(req, res, next) { + if (req.method !== 'GET' && req.method !== 'HEAD') { + return next() + } + + var opts = merge({}, options) + var originalUrl = parseurl.original(req) + var path = parseurl(req).pathname + + if (path === '/' && originalUrl.pathname[originalUrl.pathname.length - 1] !== '/') { + // make sure redirect occurs at mount + path = '' + } + + // create send stream + var stream = send(req, path, opts) + + if (redirect) { + // redirect relative to originalUrl + stream.on('directory', function redirect() { + originalUrl.pathname += '/' + + var target = url.format(originalUrl) + + res.statusCode = 303 + res.setHeader('Content-Type', 'text/html; charset=utf-8') + res.setHeader('Location', target) + res.end('Redirecting to ' + escapeHtml(target) + '\n') + }) + } else { + // forward to next middleware on directory + stream.on('directory', next) + } + + // add headers listener + if (setHeaders) { + stream.on('headers', setHeaders) + } + + // forward non-404 errors + stream.on('error', function error(err) { + next(err.status === 404 ? null : err) + }) + + // pipe + stream.pipe(res) + } +} + +/** + * Expose mime module. + * + * If you wish to extend the mime table use this + * reference to the "mime" module in the npm registry. + */ + +exports.mime = send.mime diff --git a/node_modules/express/node_modules/serve-static/package.json b/node_modules/express/node_modules/serve-static/package.json new file mode 100644 index 0000000..ddcbf74 --- /dev/null +++ b/node_modules/express/node_modules/serve-static/package.json @@ -0,0 +1,84 @@ +{ + "name": "serve-static", + "description": "Serve static files", + "version": "1.6.2", + "author": { + "name": "Douglas Christopher Wilson", + "email": "doug@somethingdoug.com" + }, + "license": "MIT", + "repository": { + "type": "git", + "url": "https://github.com/expressjs/serve-static" + }, + "dependencies": { + "escape-html": "1.0.1", + "parseurl": "~1.3.0", + "send": "0.9.2", + "utils-merge": "1.0.0" + }, + "devDependencies": { + "istanbul": "0.3.2", + "mocha": "~1.21.0", + "should": "~4.0.0", + "supertest": "~0.13.0" + }, + "files": [ + "LICENSE", + "HISTORY.md", + "index.js" + ], + "engines": { + "node": ">= 0.8.0" + }, + "scripts": { + "test": "mocha --reporter spec --bail --check-leaks --require should test/", + "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks --require should test/", + "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks --require should test/" + }, + "gitHead": "7053ce75b7091a891d3bcb88a2b19b1b0692396c", + "bugs": { + "url": "https://github.com/expressjs/serve-static/issues" + }, + "homepage": "https://github.com/expressjs/serve-static", + "_id": "serve-static@1.6.2", + "_shasum": "c1390ff43941867250296b091391d25be7c87571", + "_from": "serve-static@~1.6.2", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + "maintainers": [ + { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + }, + { + "name": "shtylman", + "email": "shtylman@gmail.com" + }, + { + "name": "tjholowaychuk", + "email": "tj@vision-media.ca" + }, + { + "name": "mscdex", + "email": "mscdex@mscdex.net" + }, + { + "name": "fishrock123", + "email": "fishrock123@rocketmail.com" + } + ], + "dist": { + "shasum": "c1390ff43941867250296b091391d25be7c87571", + "tarball": "http://registry.npmjs.org/serve-static/-/serve-static-1.6.2.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/serve-static/-/serve-static-1.6.2.tgz" +} diff --git a/node_modules/express/node_modules/type-is/HISTORY.md b/node_modules/express/node_modules/type-is/HISTORY.md new file mode 100644 index 0000000..c828c45 --- /dev/null +++ b/node_modules/express/node_modules/type-is/HISTORY.md @@ -0,0 +1,71 @@ +1.5.1 / 2014-09-07 +================== + + * Support Node.js 0.6 + * deps: media-typer@0.3.0 + * deps: mime-types@~2.0.1 + - Support Node.js 0.6 + +1.5.0 / 2014-09-05 +================== + + * fix `hasbody` to be true for `content-length: 0` + +1.4.0 / 2014-09-02 +================== + + * update mime-types + +1.3.2 / 2014-06-24 +================== + + * use `~` range on mime-types + +1.3.1 / 2014-06-19 +================== + + * fix global variable leak + +1.3.0 / 2014-06-19 +================== + + * improve type parsing + + - invalid media type never matches + - media type not case-sensitive + - extra LWS does not affect results + +1.2.2 / 2014-06-19 +================== + + * fix behavior on unknown type argument + +1.2.1 / 2014-06-03 +================== + + * switch dependency from `mime` to `mime-types@1.0.0` + +1.2.0 / 2014-05-11 +================== + + * support suffix matching: + + - `+json` matches `application/vnd+json` + - `*/vnd+json` matches `application/vnd+json` + - `application/*+json` matches `application/vnd+json` + +1.1.0 / 2014-04-12 +================== + + * add non-array values support + * expose internal utilities: + + - `.is()` + - `.hasBody()` + - `.normalize()` + - `.match()` + +1.0.1 / 2014-03-30 +================== + + * add `multipart` as a shorthand diff --git a/node_modules/express/node_modules/type-is/LICENSE b/node_modules/express/node_modules/type-is/LICENSE new file mode 100644 index 0000000..4164d08 --- /dev/null +++ b/node_modules/express/node_modules/type-is/LICENSE @@ -0,0 +1,21 @@ +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/node_modules/express/node_modules/type-is/README.md b/node_modules/express/node_modules/type-is/README.md new file mode 100644 index 0000000..a3ec5a5 --- /dev/null +++ b/node_modules/express/node_modules/type-is/README.md @@ -0,0 +1,100 @@ +# type-is + +[![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] + +Infer the content-type of a request. + +### Install + +```sh +$ npm install type-is +``` + +## API + +```js +var http = require('http') +var is = require('type-is') + +http.createServer(function (req, res) { + var istext = is(req, ['text/*']) + res.end('you ' + (istext ? 'sent' : 'did not send') + ' me text') +}) +``` + +### type = is(request, types) + +`request` is the node HTTP request. `types` is an array of types. + +```js +// req.headers.content-type = 'application/json' + +is(req, ['json']) // 'json' +is(req, ['html', 'json']) // 'json' +is(req, ['application/*']) // 'application/json' +is(req, ['application/json']) // 'application/json' + +is(req, ['html']) // false +``` + +#### Each type can be: + +- An extension name such as `json`. This name will be returned if matched. +- A mime type such as `application/json`. +- A mime type with a wildcard such as `*/json` or `application/*`. The full mime type will be returned if matched +- A suffix such as `+json`. This can be combined with a wildcard such as `*/vnd+json` or `application/*+json`. The full mime type will be returned if matched. + +`false` will be returned if no type matches. + +## Examples + +#### Example body parser + +```js +var is = require('type-is'); + +function bodyParser(req, res, next) { + if (!is.hasBody(req)) { + return next() + } + + switch (is(req, ['urlencoded', 'json', 'multipart'])) { + case 'urlencoded': + // parse urlencoded body + throw new Error('implement urlencoded body parsing') + break + case 'json': + // parse json body + throw new Error('implement json body parsing') + break + case 'multipart': + // parse multipart body + throw new Error('implement multipart body parsing') + break + default: + // 415 error code + res.statusCode = 415 + res.end() + return + } +} +``` + +## License + +[MIT](LICENSE) + +[npm-image]: https://img.shields.io/npm/v/type-is.svg?style=flat +[npm-url]: https://npmjs.org/package/type-is +[node-version-image]: https://img.shields.io/badge/node.js-%3E%3D_0.6-brightgreen.svg?style=flat +[node-version-url]: http://nodejs.org/download/ +[travis-image]: https://img.shields.io/travis/jshttp/type-is.svg?style=flat +[travis-url]: https://travis-ci.org/jshttp/type-is +[coveralls-image]: https://img.shields.io/coveralls/jshttp/type-is.svg?style=flat +[coveralls-url]: https://coveralls.io/r/jshttp/type-is?branch=master +[downloads-image]: https://img.shields.io/npm/dm/type-is.svg?style=flat +[downloads-url]: https://npmjs.org/package/type-is diff --git a/node_modules/express/node_modules/type-is/index.js b/node_modules/express/node_modules/type-is/index.js new file mode 100644 index 0000000..8d220d1 --- /dev/null +++ b/node_modules/express/node_modules/type-is/index.js @@ -0,0 +1,226 @@ + +var typer = require('media-typer') +var mime = require('mime-types') + +module.exports = typeofrequest; +typeofrequest.is = typeis; +typeofrequest.hasBody = hasbody; +typeofrequest.normalize = normalize; +typeofrequest.match = mimeMatch; + +/** + * Compare a `value` content-type with `types`. + * Each `type` can be an extension like `html`, + * a special shortcut like `multipart` or `urlencoded`, + * or a mime type. + * + * If no types match, `false` is returned. + * Otherwise, the first `type` that matches is returned. + * + * @param {String} value + * @param {Array} types + * @return String + */ + +function typeis(value, types_) { + var i + var types = types_ + + // remove parameters and normalize + value = typenormalize(value) + + // no type or invalid + if (!value) { + return false + } + + // support flattened arguments + if (types && !Array.isArray(types)) { + types = new Array(arguments.length - 1) + for (i = 0; i < types.length; i++) { + types[i] = arguments[i + 1] + } + } + + // no types, return the content type + if (!types || !types.length) return value; + + var type + for (i = 0; i < types.length; i++) { + if (mimeMatch(normalize(type = types[i]), value)) { + return type[0] === '+' || ~type.indexOf('*') + ? value + : type + } + } + + // no matches + return false; +} + +/** + * Check if a request has a request body. + * A request with a body __must__ either have `transfer-encoding` + * or `content-length` headers set. + * http://www.w3.org/Protocols/rfc2616/rfc2616-sec4.html#sec4.3 + * + * @param {Object} request + * @return {Boolean} + * @api public + */ + +function hasbody(req) { + var headers = req.headers; + if ('transfer-encoding' in headers) return true; + return !isNaN(headers['content-length']); +} + +/** + * Check if the incoming request contains the "Content-Type" + * header field, and it contains any of the give mime `type`s. + * If there is no request body, `null` is returned. + * If there is no content type, `false` is returned. + * Otherwise, it returns the first `type` that matches. + * + * Examples: + * + * // With Content-Type: text/html; charset=utf-8 + * this.is('html'); // => 'html' + * this.is('text/html'); // => 'text/html' + * this.is('text/*', 'application/json'); // => 'text/html' + * + * // When Content-Type is application/json + * this.is('json', 'urlencoded'); // => 'json' + * this.is('application/json'); // => 'application/json' + * this.is('html', 'application/*'); // => 'application/json' + * + * this.is('html'); // => false + * + * @param {String|Array} types... + * @return {String|false|null} + * @api public + */ + +function typeofrequest(req, types_) { + var types = types_ + + // no body + if (!hasbody(req)) { + return null + } + + // support flattened arguments + if (arguments.length > 2) { + types = new Array(arguments.length - 1) + for (var i = 0; i < types.length; i++) { + types[i] = arguments[i + 1] + } + } + + // request content type + var value = req.headers['content-type'] + + return typeis(value, types); +} + +/** + * Normalize a mime type. + * If it's a shorthand, expand it to a valid mime type. + * + * In general, you probably want: + * + * var type = is(req, ['urlencoded', 'json', 'multipart']); + * + * Then use the appropriate body parsers. + * These three are the most common request body types + * and are thus ensured to work. + * + * @param {String} type + * @api private + */ + +function normalize(type) { + switch (type) { + case 'urlencoded': return 'application/x-www-form-urlencoded'; + case 'multipart': + type = 'multipart/*'; + break; + } + + return type[0] === '+' || ~type.indexOf('/') + ? type + : mime.lookup(type) +} + +/** + * Check if `exected` mime type + * matches `actual` mime type with + * wildcard and +suffix support. + * + * @param {String} expected + * @param {String} actual + * @return {Boolean} + * @api private + */ + +function mimeMatch(expected, actual) { + // invalid type + if (expected === false) { + return false + } + + // exact match + if (expected === actual) { + return true + } + + actual = actual.split('/'); + + if (expected[0] === '+') { + // support +suffix + return Boolean(actual[1]) + && expected.length <= actual[1].length + && expected === actual[1].substr(0 - expected.length) + } + + if (!~expected.indexOf('*')) return false; + + expected = expected.split('/'); + + if (expected[0] === '*') { + // support */yyy + return expected[1] === actual[1] + } + + if (expected[1] === '*') { + // support xxx/* + return expected[0] === actual[0] + } + + if (expected[1][0] === '*' && expected[1][1] === '+') { + // support xxx/*+zzz + return expected[0] === actual[0] + && expected[1].length <= actual[1].length + 1 + && expected[1].substr(1) === actual[1].substr(1 - expected[1].length) + } + + return false +} + +/** + * Normalize a type and remove parameters. + * + * @param {string} value + * @return {string} + * @api private + */ + +function typenormalize(value) { + try { + var type = typer.parse(value) + delete type.parameters + return typer.format(type) + } catch (err) { + return null + } +} diff --git a/node_modules/express/node_modules/type-is/node_modules/mime-types/HISTORY.md b/node_modules/express/node_modules/type-is/node_modules/mime-types/HISTORY.md new file mode 100644 index 0000000..510ea56 --- /dev/null +++ b/node_modules/express/node_modules/type-is/node_modules/mime-types/HISTORY.md @@ -0,0 +1,31 @@ +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/node_modules/express/node_modules/type-is/node_modules/mime-types/LICENSE b/node_modules/express/node_modules/type-is/node_modules/mime-types/LICENSE new file mode 100644 index 0000000..a7ae8ee --- /dev/null +++ b/node_modules/express/node_modules/type-is/node_modules/mime-types/LICENSE @@ -0,0 +1,22 @@ + +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/node_modules/express/node_modules/type-is/node_modules/mime-types/README.md b/node_modules/express/node_modules/type-is/node_modules/mime-types/README.md new file mode 100644 index 0000000..99d658b --- /dev/null +++ b/node_modules/express/node_modules/type-is/node_modules/mime-types/README.md @@ -0,0 +1,99 @@ +# 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('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' +``` + +### 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?style=flat +[npm-url]: https://npmjs.org/package/mime-types +[node-version-image]: https://img.shields.io/badge/node.js-%3E%3D_0.6-brightgreen.svg?style=flat +[node-version-url]: http://nodejs.org/download/ +[travis-image]: https://img.shields.io/travis/jshttp/mime-types.svg?style=flat +[travis-url]: https://travis-ci.org/jshttp/mime-types +[coveralls-image]: https://img.shields.io/coveralls/jshttp/mime-types.svg?style=flat +[coveralls-url]: https://coveralls.io/r/jshttp/mime-types +[downloads-image]: https://img.shields.io/npm/dm/mime-types.svg?style=flat +[downloads-url]: https://npmjs.org/package/mime-types diff --git a/node_modules/express/node_modules/type-is/node_modules/mime-types/index.js b/node_modules/express/node_modules/type-is/node_modules/mime-types/index.js new file mode 100644 index 0000000..b46a202 --- /dev/null +++ b/node_modules/express/node_modules/type-is/node_modules/mime-types/index.js @@ -0,0 +1,63 @@ + +var db = require('mime-db') + +// types[extension] = type +exports.types = Object.create(null) +// extensions[type] = [extensions] +exports.extensions = 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 +} + +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] +} + +// type has to be an exact mime type +exports.charset = function (type) { + var mime = db[type] + if (mime && mime.charset) return mime.charset + + // default text/* to utf-8 + if (/^text\//.test(type)) return 'UTF-8' + + return false +} + +// backwards compatibility +exports.charsets = { + lookup: exports.charset +} + +// 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() + } + return type +} diff --git a/node_modules/express/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/LICENSE b/node_modules/express/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/LICENSE new file mode 100644 index 0000000..a7ae8ee --- /dev/null +++ b/node_modules/express/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/LICENSE @@ -0,0 +1,22 @@ + +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/node_modules/express/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/README.md b/node_modules/express/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/README.md new file mode 100644 index 0000000..7909379 --- /dev/null +++ b/node_modules/express/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/README.md @@ -0,0 +1,72 @@ +# 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 consistents of a single, public JSON file and does not include any logic, +allowing it to remain as unopinionated 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 + +## Usage + +```bash +npm i mime-db +``` + +```js +var db = require('mime-db'); + +// grab data on .js files +var data = db['application/javascript']; +``` + +If you're crazy enough to use this in the browser, +you can just grab the JSON file: + +``` +https://cdn.rawgit.com/jshttp/mime-db/master/db.json +``` + +## 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) +- `.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`. + +## Repository Structure + +- `scripts` - these are scripts to run to build the database +- `src/` - this is a folder of files created from remote sources like Apache and IANA +- `lib/` - this is a folder of our own custom sources and db, which will be merged into `db.json` +- `db.json` - the final built JSON file for end-user usage + +## Contributing + +To edit the database, only make PRs against files in the `lib/` folder. +To update the build, run `npm run update`. + +[npm-version-image]: https://img.shields.io/npm/v/mime-db.svg?style=flat +[npm-downloads-image]: https://img.shields.io/npm/dm/mime-db.svg?style=flat +[npm-url]: https://npmjs.org/package/mime-db +[travis-image]: https://img.shields.io/travis/jshttp/mime-db.svg?style=flat +[travis-url]: https://travis-ci.org/jshttp/mime-db +[coveralls-image]: https://img.shields.io/coveralls/jshttp/mime-db.svg?style=flat +[coveralls-url]: https://coveralls.io/r/jshttp/mime-db?branch=master +[node-image]: http://img.shields.io/badge/node.js->=_0.6-brightgreen.svg?style=flat +[node-url]: http://nodejs.org/download/ diff --git a/node_modules/express/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/db.json b/node_modules/express/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/db.json new file mode 100644 index 0000000..f89fc14 --- /dev/null +++ b/node_modules/express/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/db.json @@ -0,0 +1,6269 @@ +{ + "application/1d-interleaved-parityfec": { + "source": "iana" + }, + "application/3gpdash-qoe-report+xml": { + "source": "iana" + }, + "application/3gpp-ims+xml": { + "source": "iana" + }, + "application/activemessage": { + "source": "iana" + }, + "application/alto-costmap+json": { + "source": "iana" + }, + "application/alto-costmapfilter+json": { + "source": "iana" + }, + "application/alto-directory+json": { + "source": "iana" + }, + "application/alto-endpointcost+json": { + "source": "iana" + }, + "application/alto-endpointcostparams+json": { + "source": "iana" + }, + "application/alto-endpointprop+json": { + "source": "iana" + }, + "application/alto-endpointpropparams+json": { + "source": "iana" + }, + "application/alto-error+json": { + "source": "iana" + }, + "application/alto-networkmap+json": { + "source": "iana" + }, + "application/alto-networkmapfilter+json": { + "source": "iana" + }, + "application/andrew-inset": { + "source": "iana", + "extensions": ["ez"] + }, + "application/applefile": { + "source": "iana" + }, + "application/applixware": { + "source": "apache", + "extensions": ["aw"] + }, + "application/atf": { + "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/auth-policy+xml": { + "source": "iana" + }, + "application/bacnet-xdd+zip": { + "source": "iana" + }, + "application/batch-smtp": { + "source": "iana" + }, + "application/beep+xml": { + "source": "iana" + }, + "application/calendar+json": { + "source": "iana" + }, + "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/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-2018+xml": { + "source": "iana" + }, + "application/cellml+xml": { + "source": "iana" + }, + "application/cfw": { + "source": "iana" + }, + "application/cms": { + "source": "iana" + }, + "application/cnrp+xml": { + "source": "iana" + }, + "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/dec-dx": { + "source": "iana" + }, + "application/dialog-info+xml": { + "source": "iana" + }, + "application/dicom": { + "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": "apache", + "extensions": ["epub"] + }, + "application/eshop": { + "source": "iana" + }, + "application/example": { + "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/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"] + }, + "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/jrd+json": { + "source": "iana" + }, + "application/json": { + "source": "iana", + "charset": "UTF-8", + "compressible": true, + "extensions": ["json","map"] + }, + "application/json-patch+json": { + "source": "iana" + }, + "application/jsonml+json": { + "source": "apache", + "extensions": ["jsonml"] + }, + "application/kpml-request+xml": { + "source": "iana" + }, + "application/kpml-response+xml": { + "source": "iana" + }, + "application/ld+json": { + "source": "iana" + }, + "application/link-format": { + "source": "iana" + }, + "application/load-control+xml": { + "source": "iana" + }, + "application/lost+xml": { + "source": "iana", + "extensions": ["lostxml"] + }, + "application/lostsync+xml": { + "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/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": "apache", + "extensions": ["mbox"] + }, + "application/mbox+xml": { + "source": "iana" + }, + "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" + }, + "application/metalink+xml": { + "source": "apache", + "extensions": ["metalink"] + }, + "application/metalink4+xml": { + "source": "iana", + "extensions": ["meta4"] + }, + "application/mets+xml": { + "source": "iana", + "extensions": ["mets"] + }, + "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": "apache" + }, + "application/octet-stream": { + "source": "iana", + "compressible": false, + "extensions": ["bin","dms","lrf","mar","so","dist","distz","pkg","bpk","dump","elc","deploy","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/oscp-response": { + "source": "iana" + }, + "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/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" + }, + "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/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" + }, + "application/vcard+xml": { + "source": "iana" + }, + "application/vemmi": { + "source": "iana" + }, + "application/vividence.scriptfile": { + "source": "apache" + }, + "application/vnd-acucobol": { + "source": "iana" + }, + "application/vnd-curl": { + "source": "iana" + }, + "application/vnd-dart": { + "source": "iana" + }, + "application/vnd-dxr": { + "source": "iana" + }, + "application/vnd-fdf": { + "source": "iana" + }, + "application/vnd-mif": { + "source": "iana" + }, + "application/vnd-sema": { + "source": "iana" + }, + "application/vnd-wap-wmlc": { + "source": "iana" + }, + "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.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": "apache", + "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.api+json": { + "source": "iana" + }, + "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.bekitzur-stech+json": { + "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.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.collection+json": { + "source": "iana" + }, + "application/vnd.collection.doc+json": { + "source": "iana" + }, + "application/vnd.collection.next+json": { + "source": "iana" + }, + "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": "apache" + }, + "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": "apache", + "compressible": true, + "extensions": ["dart"] + }, + "application/vnd.data-vision.rdz": { + "source": "iana", + "extensions": ["rdz"] + }, + "application/vnd.debian.binary-package": { + "source": "iana" + }, + "application/vnd.dece-zip": { + "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": "apache", + "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" + }, + "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": "apache", + "extensions": ["svc"] + }, + "application/vnd.dvb_service": { + "source": "iana" + }, + "application/vnd.dxr": { + "source": "apache" + }, + "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.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.fdf": { + "source": "apache", + "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" + }, + "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.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.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" + }, + "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" + }, + "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" + }, + "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.lis.v2.result+json": { + "source": "iana" + }, + "application/vnd.ims.lti.v2.toolconsumerprofile+json": { + "source": "iana" + }, + "application/vnd.ims.lti.v2.toolproxy+json": { + "source": "iana" + }, + "application/vnd.ims.lti.v2.toolproxy.id+json": { + "source": "iana" + }, + "application/vnd.ims.lti.v2.toolsettings+json": { + "source": "iana" + }, + "application/vnd.ims.lti.v2.toolsettings.simple+json": { + "source": "iana" + }, + "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" + }, + "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.micrografx-igx": { + "source": "iana" + }, + "application/vnd.micrografx.flo": { + "source": "iana", + "extensions": ["flo"] + }, + "application/vnd.micrografx.igx": { + "source": "apache", + "extensions": ["igx"] + }, + "application/vnd.miele+json": { + "source": "iana" + }, + "application/vnd.mif": { + "source": "apache", + "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.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" + }, + "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" + }, + "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.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": "apache" + }, + "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-doc": { + "source": "iana" + }, + "application/vnd.sealed-eml": { + "source": "iana" + }, + "application/vnd.sealed-mht": { + "source": "iana" + }, + "application/vnd.sealed-ppt": { + "source": "iana" + }, + "application/vnd.sealed-tiff": { + "source": "iana" + }, + "application/vnd.sealed-xls": { + "source": "iana" + }, + "application/vnd.sealed.3df": { + "source": "iana" + }, + "application/vnd.sealed.csf": { + "source": "iana" + }, + "application/vnd.sealed.doc": { + "source": "apache" + }, + "application/vnd.sealed.eml": { + "source": "apache" + }, + "application/vnd.sealed.mht": { + "source": "apache" + }, + "application/vnd.sealed.net": { + "source": "iana" + }, + "application/vnd.sealed.ppt": { + "source": "apache" + }, + "application/vnd.sealed.tiff": { + "source": "apache" + }, + "application/vnd.sealed.xls": { + "source": "apache" + }, + "application/vnd.sealedmedia.softseal-html": { + "source": "iana" + }, + "application/vnd.sealedmedia.softseal-pdf": { + "source": "iana" + }, + "application/vnd.sealedmedia.softseal.html": { + "source": "apache" + }, + "application/vnd.sealedmedia.softseal.pdf": { + "source": "apache" + }, + "application/vnd.seemail": { + "source": "iana", + "extensions": ["see"] + }, + "application/vnd.sema": { + "source": "apache", + "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" + }, + "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.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-slc": { + "source": "iana" + }, + "application/vnd.wap-wbxml": { + "source": "iana" + }, + "application/vnd.wap.sic": { + "source": "iana" + }, + "application/vnd.wap.slc": { + "source": "apache" + }, + "application/vnd.wap.wbxml": { + "source": "apache", + "extensions": ["wbxml"] + }, + "application/vnd.wap.wmlc": { + "source": "apache", + "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" + }, + "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/vwg-multiplexed": { + "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-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-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-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-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-nzb": { + "source": "apache", + "extensions": ["nzb"] + }, + "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-research-info-systems": { + "source": "apache", + "extensions": ["ris"] + }, + "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"] + }, + "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": { + "extensions": ["webapp"] + }, + "application/x-www-form-urlencode": { + "compressible": false + }, + "application/x-www-form-urlencoded": { + "source": "iana" + }, + "application/x-x509-ca-cert": { + "source": "apache", + "extensions": ["der","crt"] + }, + "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": "iana" + }, + "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/example": { + "source": "iana" + }, + "audio/fwdred": { + "source": "iana" + }, + "audio/g719": { + "source": "iana" + }, + "audio/g721": { + "source": "iana" + }, + "audio/g722": { + "source": "iana" + }, + "audio/g7221": { + "source": "apache" + }, + "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": "apache" + }, + "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.sealedmedia.softseal.mpeg": { + "source": "apache" + }, + "audio/vnd.vmx.cvsd": { + "source": "iana" + }, + "audio/vnd.wave": { + "compressible": false + }, + "audio/vorbis": { + "source": "iana", + "compressible": false + }, + "audio/vorbis-config": { + "source": "iana" + }, + "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-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-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/example": { + "source": "iana" + }, + "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-djvu": { + "source": "iana" + }, + "image/vnd-svf": { + "source": "iana" + }, + "image/vnd-wap-wbmp": { + "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": "apache", + "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.sealed.png": { + "source": "apache" + }, + "image/vnd.sealedmedia.softseal-gif": { + "source": "iana" + }, + "image/vnd.sealedmedia.softseal-jpg": { + "source": "iana" + }, + "image/vnd.sealedmedia.softseal.gif": { + "source": "apache" + }, + "image/vnd.sealedmedia.softseal.jpg": { + "source": "apache" + }, + "image/vnd.svf": { + "source": "apache" + }, + "image/vnd.valve.source.texture": { + "source": "iana" + }, + "image/vnd.wap.wbmp": { + "source": "apache", + "extensions": ["wbmp"] + }, + "image/vnd.xiff": { + "source": "iana", + "extensions": ["xif"] + }, + "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-mrsid-image": { + "source": "apache", + "extensions": ["sid"] + }, + "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/example": { + "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/example": { + "source": "iana", + "compressible": false + }, + "model/iges": { + "source": "iana", + "compressible": false, + "extensions": ["igs","iges"] + }, + "model/mesh": { + "source": "iana", + "compressible": false, + "extensions": ["msh","mesh","silo"] + }, + "model/vnd-dwf": { + "source": "iana" + }, + "model/vnd.collada+xml": { + "source": "iana", + "extensions": ["dae"] + }, + "model/vnd.dwf": { + "source": "apache", + "extensions": ["dwf"] + }, + "model/vnd.flatland.3dml": { + "source": "iana" + }, + "model/vnd.gdl": { + "source": "iana", + "extensions": ["gdl"] + }, + "model/vnd.gs-gdl": { + "source": "iana" + }, + "model/vnd.gs.gdl": { + "source": "apache" + }, + "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.parasolid.transmit.binary": { + "source": "apache" + }, + "model/vnd.parasolid.transmit.text": { + "source": "apache" + }, + "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/example": { + "source": "iana" + }, + "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"] + }, + "text/css": { + "source": "iana", + "compressible": true, + "extensions": ["css"] + }, + "text/csv": { + "source": "iana", + "compressible": true, + "extensions": ["csv"] + }, + "text/directory": { + "source": "iana" + }, + "text/dns": { + "source": "iana" + }, + "text/ecmascript": { + "source": "iana" + }, + "text/encaprtp": { + "source": "iana" + }, + "text/enriched": { + "source": "iana" + }, + "text/example": { + "source": "iana" + }, + "text/fwdred": { + "source": "iana" + }, + "text/grammar-ref-list": { + "source": "iana" + }, + "text/html": { + "source": "iana", + "compressible": true, + "extensions": ["html","htm"] + }, + "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/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" + }, + "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-curl": { + "source": "iana" + }, + "text/vnd.abc": { + "source": "iana" + }, + "text/vnd.curl": { + "source": "apache", + "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-wml": { + "source": "iana" + }, + "text/vnd.wap.si": { + "source": "iana" + }, + "text/vnd.wap.sl": { + "source": "iana" + }, + "text/vnd.wap.wml": { + "source": "apache", + "extensions": ["wml"] + }, + "text/vnd.wap.wmlscript": { + "source": "iana", + "extensions": ["wmls"] + }, + "text/vtt": { + "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": { + "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-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 + }, + "text/xml-external-parsed-entity": { + "source": "iana" + }, + "video/1d-interleaved-parityfec": { + "source": "apache" + }, + "video/3gpp": { + "source": "apache", + "extensions": ["3gp"] + }, + "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/example": { + "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/node_modules/express/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/index.js b/node_modules/express/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/index.js new file mode 100644 index 0000000..551031f --- /dev/null +++ b/node_modules/express/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/index.js @@ -0,0 +1,11 @@ +/*! + * mime-db + * Copyright(c) 2014 Jonathan Ong + * MIT Licensed + */ + +/** + * Module exports. + */ + +module.exports = require('./db.json') diff --git a/node_modules/express/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/package.json b/node_modules/express/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/package.json new file mode 100644 index 0000000..f067351 --- /dev/null +++ b/node_modules/express/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/package.json @@ -0,0 +1,74 @@ +{ + "name": "mime-db", + "description": "Media Type Database", + "version": "1.0.1", + "author": { + "name": "Jonathan Ong", + "email": "me@jongleberry.com", + "url": "http://jongleberry.com" + }, + "license": "MIT", + "repository": { + "type": "git", + "url": "https://github.com/jshttp/mime-db" + }, + "devDependencies": { + "co": "3", + "cogent": "1", + "csv-parse": "0", + "gnode": "0.0.8", + "istanbul": "0.3.0", + "mocha": "1", + "stream-to-array": "2" + }, + "engine": { + "node": ">= 0.6.0" + }, + "files": [ + "LICENSE", + "db.json", + "index.js" + ], + "scripts": { + "update": "gnode scripts/extensions && gnode scripts/types && node scripts/build", + "clean": "rm src/*", + "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/" + }, + "keywords": [ + "mime", + "db", + "type", + "types", + "database", + "charset", + "charsets" + ], + "gitHead": "6c9ee137430015b52887901377ac2f33e21f4078", + "bugs": { + "url": "https://github.com/jshttp/mime-db/issues" + }, + "homepage": "https://github.com/jshttp/mime-db", + "_id": "mime-db@1.0.1", + "_shasum": "35d99b0965967253bb30633a7d07a8de9975a952", + "_from": "mime-db@~1.0.1", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + }, + "maintainers": [ + { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + } + ], + "dist": { + "shasum": "35d99b0965967253bb30633a7d07a8de9975a952", + "tarball": "http://registry.npmjs.org/mime-db/-/mime-db-1.0.1.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.0.1.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/express/node_modules/type-is/node_modules/mime-types/package.json b/node_modules/express/node_modules/type-is/node_modules/mime-types/package.json new file mode 100644 index 0000000..494c346 --- /dev/null +++ b/node_modules/express/node_modules/type-is/node_modules/mime-types/package.json @@ -0,0 +1,80 @@ +{ + "name": "mime-types", + "description": "The ultimate javascript content-type utility.", + "version": "2.0.1", + "contributors": [ + { + "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": "https://github.com/jshttp/mime-types" + }, + "dependencies": { + "mime-db": "~1.0.1" + }, + "devDependencies": { + "istanbul": "0", + "mocha": "1" + }, + "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": "c6e40fb033331aa87d9d4a5f1e5c0245e9edb2f6", + "bugs": { + "url": "https://github.com/jshttp/mime-types/issues" + }, + "homepage": "https://github.com/jshttp/mime-types", + "_id": "mime-types@2.0.1", + "_shasum": "7f5b4712592e7dd46ca733fd1c5f5d71356de615", + "_from": "mime-types@~2.0.1", + "_npmVersion": "1.4.21", + "_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": "7f5b4712592e7dd46ca733fd1c5f5d71356de615", + "tarball": "http://registry.npmjs.org/mime-types/-/mime-types-2.0.1.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.0.1.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/express/node_modules/type-is/package.json b/node_modules/express/node_modules/type-is/package.json new file mode 100644 index 0000000..0518a9b --- /dev/null +++ b/node_modules/express/node_modules/type-is/package.json @@ -0,0 +1,93 @@ +{ + "name": "type-is", + "description": "Infer the content-type of a request.", + "version": "1.5.1", + "author": { + "name": "Jonathan Ong", + "email": "me@jongleberry.com", + "url": "http://jongleberry.com" + }, + "contributors": [ + { + "name": "Douglas Christopher Wilson", + "email": "doug@somethingdoug.com" + } + ], + "license": "MIT", + "repository": { + "type": "git", + "url": "https://github.com/jshttp/type-is" + }, + "dependencies": { + "media-typer": "0.3.0", + "mime-types": "~2.0.1" + }, + "devDependencies": { + "istanbul": "~0.3.0", + "mocha": "1" + }, + "engines": { + "node": ">= 0.6" + }, + "files": [ + "LICENSE", + "HISTORY.md", + "index.js" + ], + "scripts": { + "test": "mocha --reporter spec --check-leaks --bail 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/" + }, + "keywords": [ + "content", + "type", + "checking" + ], + "gitHead": "74d33287453bf7c166f6410fc608c1c7588070ae", + "bugs": { + "url": "https://github.com/jshttp/type-is/issues" + }, + "homepage": "https://github.com/jshttp/type-is", + "_id": "type-is@1.5.1", + "_shasum": "5c1e62d874f79199fb16b34d16972dba376ccbed", + "_from": "type-is@~1.5.1", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + "maintainers": [ + { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + }, + { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + { + "name": "tjholowaychuk", + "email": "tj@vision-media.ca" + }, + { + "name": "shtylman", + "email": "shtylman@gmail.com" + }, + { + "name": "mscdex", + "email": "mscdex@mscdex.net" + }, + { + "name": "fishrock123", + "email": "fishrock123@rocketmail.com" + } + ], + "dist": { + "shasum": "5c1e62d874f79199fb16b34d16972dba376ccbed", + "tarball": "http://registry.npmjs.org/type-is/-/type-is-1.5.1.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/type-is/-/type-is-1.5.1.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/express/node_modules/utils-merge/.travis.yml b/node_modules/express/node_modules/utils-merge/.travis.yml new file mode 100644 index 0000000..af92b02 --- /dev/null +++ b/node_modules/express/node_modules/utils-merge/.travis.yml @@ -0,0 +1,6 @@ +language: "node_js" +node_js: + - "0.4" + - "0.6" + - "0.8" + - "0.10" diff --git a/node_modules/express/node_modules/utils-merge/LICENSE b/node_modules/express/node_modules/utils-merge/LICENSE new file mode 100644 index 0000000..e33bd10 --- /dev/null +++ b/node_modules/express/node_modules/utils-merge/LICENSE @@ -0,0 +1,20 @@ +(The MIT License) + +Copyright (c) 2013 Jared Hanson + +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/node_modules/express/node_modules/utils-merge/README.md b/node_modules/express/node_modules/utils-merge/README.md new file mode 100644 index 0000000..2f94e9b --- /dev/null +++ b/node_modules/express/node_modules/utils-merge/README.md @@ -0,0 +1,34 @@ +# utils-merge + +Merges the properties from a source object into a destination object. + +## Install + + $ npm install utils-merge + +## Usage + +```javascript +var a = { foo: 'bar' } + , b = { bar: 'baz' }; + +merge(a, b); +// => { foo: 'bar', bar: 'baz' } +``` + +## Tests + + $ npm install + $ npm test + +[![Build Status](https://secure.travis-ci.org/jaredhanson/utils-merge.png)](http://travis-ci.org/jaredhanson/utils-merge) + +## Credits + + - [Jared Hanson](http://github.com/jaredhanson) + +## License + +[The MIT License](http://opensource.org/licenses/MIT) + +Copyright (c) 2013 Jared Hanson <[http://jaredhanson.net/](http://jaredhanson.net/)> diff --git a/node_modules/express/node_modules/utils-merge/index.js b/node_modules/express/node_modules/utils-merge/index.js new file mode 100644 index 0000000..4265c69 --- /dev/null +++ b/node_modules/express/node_modules/utils-merge/index.js @@ -0,0 +1,23 @@ +/** + * Merge object b with object a. + * + * var a = { foo: 'bar' } + * , b = { bar: 'baz' }; + * + * merge(a, b); + * // => { foo: 'bar', bar: 'baz' } + * + * @param {Object} a + * @param {Object} b + * @return {Object} + * @api public + */ + +exports = module.exports = function(a, b){ + if (a && b) { + for (var key in b) { + a[key] = b[key]; + } + } + return a; +}; diff --git a/node_modules/express/node_modules/utils-merge/package.json b/node_modules/express/node_modules/utils-merge/package.json new file mode 100644 index 0000000..c168717 --- /dev/null +++ b/node_modules/express/node_modules/utils-merge/package.json @@ -0,0 +1,60 @@ +{ + "name": "utils-merge", + "version": "1.0.0", + "description": "merge() utility function", + "keywords": [ + "util" + ], + "repository": { + "type": "git", + "url": "git://github.com/jaredhanson/utils-merge.git" + }, + "bugs": { + "url": "http://github.com/jaredhanson/utils-merge/issues" + }, + "author": { + "name": "Jared Hanson", + "email": "jaredhanson@gmail.com", + "url": "http://www.jaredhanson.net/" + }, + "licenses": [ + { + "type": "MIT", + "url": "http://www.opensource.org/licenses/MIT" + } + ], + "main": "./index", + "dependencies": {}, + "devDependencies": { + "mocha": "1.x.x", + "chai": "1.x.x" + }, + "scripts": { + "test": "node_modules/.bin/mocha --reporter spec --require test/bootstrap/node test/*.test.js" + }, + "engines": { + "node": ">= 0.4.0" + }, + "readme": "# utils-merge\n\nMerges the properties from a source object into a destination object.\n\n## Install\n\n $ npm install utils-merge\n\n## Usage\n\n```javascript\nvar a = { foo: 'bar' }\n , b = { bar: 'baz' };\n\nmerge(a, b);\n// => { foo: 'bar', bar: 'baz' }\n```\n\n## Tests\n\n $ npm install\n $ npm test\n\n[![Build Status](https://secure.travis-ci.org/jaredhanson/utils-merge.png)](http://travis-ci.org/jaredhanson/utils-merge)\n\n## Credits\n\n - [Jared Hanson](http://github.com/jaredhanson)\n\n## License\n\n[The MIT License](http://opensource.org/licenses/MIT)\n\nCopyright (c) 2013 Jared Hanson <[http://jaredhanson.net/](http://jaredhanson.net/)>\n", + "readmeFilename": "README.md", + "_id": "utils-merge@1.0.0", + "dist": { + "shasum": "0294fb922bb9375153541c4f7096231f287c8af8", + "tarball": "http://registry.npmjs.org/utils-merge/-/utils-merge-1.0.0.tgz" + }, + "_from": "utils-merge@1.0.0", + "_npmVersion": "1.2.25", + "_npmUser": { + "name": "jaredhanson", + "email": "jaredhanson@gmail.com" + }, + "maintainers": [ + { + "name": "jaredhanson", + "email": "jaredhanson@gmail.com" + } + ], + "directories": {}, + "_shasum": "0294fb922bb9375153541c4f7096231f287c8af8", + "_resolved": "https://registry.npmjs.org/utils-merge/-/utils-merge-1.0.0.tgz" +} diff --git a/node_modules/express/node_modules/vary/.npmignore b/node_modules/express/node_modules/vary/.npmignore new file mode 100644 index 0000000..cd39b77 --- /dev/null +++ b/node_modules/express/node_modules/vary/.npmignore @@ -0,0 +1,3 @@ +coverage/ +test/ +.travis.yml diff --git a/node_modules/express/node_modules/vary/History.md b/node_modules/express/node_modules/vary/History.md new file mode 100644 index 0000000..e5d8e69 --- /dev/null +++ b/node_modules/express/node_modules/vary/History.md @@ -0,0 +1,16 @@ +1.0.0 / 2014-08-10 +================== + + * Accept valid `Vary` header string as `field` + * Add `vary.append` for low-level string manipulation + * Move to `jshttp` orgainzation + +0.1.0 / 2014-06-05 +================== + + * Support array of fields to set + +0.0.0 / 2014-06-04 +================== + + * Initial release diff --git a/node_modules/express/node_modules/vary/LICENSE b/node_modules/express/node_modules/vary/LICENSE new file mode 100644 index 0000000..b7dce6c --- /dev/null +++ b/node_modules/express/node_modules/vary/LICENSE @@ -0,0 +1,22 @@ +(The MIT License) + +Copyright (c) 2014 Douglas Christopher Wilson + +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/node_modules/express/node_modules/vary/README.md b/node_modules/express/node_modules/vary/README.md new file mode 100644 index 0000000..82392d0 --- /dev/null +++ b/node_modules/express/node_modules/vary/README.md @@ -0,0 +1,59 @@ +# vary + +[![NPM Version](http://img.shields.io/npm/v/vary.svg?style=flat)](https://www.npmjs.org/package/vary) +[![Node.js Version](http://img.shields.io/badge/node.js->=_0.8-blue.svg?style=flat)](http://nodejs.org/download/) +[![Build Status](http://img.shields.io/travis/jshttp/vary.svg?style=flat)](https://travis-ci.org/jshttp/vary) +[![Coverage Status](https://img.shields.io/coveralls/jshttp/vary.svg?style=flat)](https://coveralls.io/r/jshttp/vary) +[![Gittip](http://img.shields.io/gittip/dougwilson.svg?style=flat)](https://www.gittip.com/dougwilson/) + +Manipulate the HTTP Vary header + +## Install + +```sh +$ npm install vary +``` + +## API + +```js +var vary = require('vary') +``` + +### vary(res, field) + +Adds the given header `field` to the `Vary` response header of `res`. +This can be a string of a single field, a string of a valid `Vary` +header, or an array of multiple fields. + +This will append the header if not already listed, otherwise leaves +it listed in the current location. + +```js +// Append "Origin" to the Vary header of the response +vary(res, 'Origin') +``` + +### vary.append(header, field) + +Adds the given header `field` to the `Vary` response header string `header`. +This can be a string of a single field, a string of a valid `Vary` header, +or an array of multiple fields. + +This will append the header if not already listed, otherwise leaves +it listed in the current location. The new header string is returned. + +```js +// Get header string appending "Origin" to "Accept, User-Agent" +vary.append('Accept, User-Agent', 'Origin') +``` + +## Testing + +```sh +$ npm test +``` + +## License + +[MIT](LICENSE) diff --git a/node_modules/express/node_modules/vary/index.js b/node_modules/express/node_modules/vary/index.js new file mode 100644 index 0000000..1e544e8 --- /dev/null +++ b/node_modules/express/node_modules/vary/index.js @@ -0,0 +1,112 @@ +/*! + * vary + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module exports. + */ + +module.exports = vary; +module.exports.append = append; + +/** + * Variables. + */ + +var separators = /[\(\)<>@,;:\\"\/\[\]\?=\{\}\u0020\u0009]/; + +/** + * Append a field to a vary header. + * + * @param {String} header + * @param {String|Array} field + * @return {String} + * @api public + */ + +function append(header, field) { + if (typeof header !== 'string') { + throw new TypeError('header argument is required'); + } + + if (!field) { + throw new TypeError('field argument is required'); + } + + // get fields array + var fields = !Array.isArray(field) + ? parse(String(field)) + : field; + + // assert on invalid fields + for (var i = 0; i < fields.length; i++) { + if (separators.test(fields[i])) { + throw new TypeError('field argument contains an invalid header'); + } + } + + // existing, unspecified vary + if (header === '*') { + return header; + } + + // enumerate current values + var vals = parse(header.toLowerCase()); + + // unspecified vary + if (fields.indexOf('*') !== -1 || vals.indexOf('*') !== -1) { + return '*'; + } + + for (var i = 0; i < fields.length; i++) { + field = fields[i].toLowerCase(); + + // append value (case-preserving) + if (vals.indexOf(field) === -1) { + vals.push(field); + header = header + ? header + ', ' + fields[i] + : fields[i]; + } + } + + return header; +} + +/** + * Parse a vary header into an array. + * + * @param {String} header + * @return {Array} + * @api private + */ + +function parse(header) { + return header.trim().split(/ *, */); +} + +/** + * Mark that a request is varied on a header field. + * + * @param {Object} res + * @param {String|Array} field + * @api public + */ + +function vary(res, field) { + if (!res || !res.getHeader || !res.setHeader) { + // quack quack + throw new TypeError('res argument is required'); + } + + // get existing header + var val = res.getHeader('Vary') || '' + var header = Array.isArray(val) + ? val.join(', ') + : String(val); + + // set new header + res.setHeader('Vary', append(header, field)); +} diff --git a/node_modules/express/node_modules/vary/package.json b/node_modules/express/node_modules/vary/package.json new file mode 100644 index 0000000..4c4bd62 --- /dev/null +++ b/node_modules/express/node_modules/vary/package.json @@ -0,0 +1,71 @@ +{ + "name": "vary", + "description": "Manipulate the HTTP Vary header", + "version": "1.0.0", + "author": { + "name": "Douglas Christopher Wilson", + "email": "doug@somethingdoug.com" + }, + "license": "MIT", + "keywords": [ + "http", + "res", + "vary" + ], + "repository": { + "type": "git", + "url": "https://github.com/jshttp/vary" + }, + "devDependencies": { + "istanbul": "0.3.0", + "mocha": "~1.21.4", + "should": "~4.0.4", + "supertest": "~0.13.0" + }, + "engines": { + "node": ">= 0.8.0" + }, + "scripts": { + "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/" + }, + "gitHead": "56acecd9fa20888132563b00576625ea02a69a35", + "bugs": { + "url": "https://github.com/jshttp/vary/issues" + }, + "homepage": "https://github.com/jshttp/vary", + "_id": "vary@1.0.0", + "_shasum": "c5e76cec20d3820d8f2a96e7bee38731c34da1e7", + "_from": "vary@~1.0.0", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + "maintainers": [ + { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + }, + { + "name": "fishrock123", + "email": "fishrock123@rocketmail.com" + }, + { + "name": "shtylman", + "email": "shtylman@gmail.com" + } + ], + "dist": { + "shasum": "c5e76cec20d3820d8f2a96e7bee38731c34da1e7", + "tarball": "http://registry.npmjs.org/vary/-/vary-1.0.0.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/vary/-/vary-1.0.0.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/express/package.json b/node_modules/express/package.json new file mode 100644 index 0000000..653a847 --- /dev/null +++ b/node_modules/express/package.json @@ -0,0 +1,159 @@ +{ + "name": "express", + "description": "Fast, unopinionated, minimalist web framework", + "version": "4.9.3", + "author": { + "name": "TJ Holowaychuk", + "email": "tj@vision-media.ca" + }, + "contributors": [ + { + "name": "Aaron Heckmann", + "email": "aaron.heckmann+github@gmail.com" + }, + { + "name": "Ciaran Jessup", + "email": "ciaranj@gmail.com" + }, + { + "name": "Douglas Christopher Wilson", + "email": "doug@somethingdoug.com" + }, + { + "name": "Guillermo Rauch", + "email": "rauchg@gmail.com" + }, + { + "name": "Jonathan Ong", + "email": "me@jongleberry.com" + }, + { + "name": "Roman Shtylman", + "email": "shtylman+expressjs@gmail.com" + }, + { + "name": "Young Jae Sim", + "email": "hanul@hanul.me" + } + ], + "keywords": [ + "express", + "framework", + "sinatra", + "web", + "rest", + "restful", + "router", + "app", + "api" + ], + "repository": { + "type": "git", + "url": "https://github.com/strongloop/express" + }, + "license": "MIT", + "homepage": "http://expressjs.com/", + "dependencies": { + "accepts": "~1.1.0", + "cookie-signature": "1.0.5", + "debug": "~2.0.0", + "depd": "0.4.5", + "escape-html": "1.0.1", + "etag": "~1.3.1", + "finalhandler": "0.2.0", + "fresh": "0.2.4", + "media-typer": "0.3.0", + "methods": "1.1.0", + "on-finished": "~2.1.0", + "parseurl": "~1.3.0", + "path-to-regexp": "0.1.3", + "proxy-addr": "~1.0.2", + "qs": "2.2.3", + "range-parser": "~1.0.2", + "send": "0.9.2", + "serve-static": "~1.6.2", + "type-is": "~1.5.1", + "vary": "~1.0.0", + "cookie": "0.1.2", + "merge-descriptors": "0.0.2", + "utils-merge": "1.0.0" + }, + "devDependencies": { + "after": "0.8.1", + "istanbul": "0.3.2", + "mocha": "~1.21.4", + "should": "~4.0.4", + "supertest": "~0.13.0", + "ejs": "~1.0.0", + "marked": "0.3.2", + "hjs": "~0.0.6", + "body-parser": "~1.8.2", + "connect-redis": "~2.1.0", + "cookie-parser": "~1.3.3", + "express-session": "~1.8.2", + "jade": "~1.6.0", + "method-override": "~2.2.0", + "morgan": "~1.3.1", + "multiparty": "~3.3.2", + "vhost": "~3.0.0" + }, + "engines": { + "node": ">= 0.10.0" + }, + "scripts": { + "prepublish": "npm prune", + "test": "mocha --require test/support/env --reporter spec --bail --check-leaks test/ test/acceptance/", + "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --require test/support/env --reporter dot --check-leaks test/ test/acceptance/", + "test-tap": "mocha --require test/support/env --reporter tap --check-leaks test/ test/acceptance/", + "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --require test/support/env --reporter spec --check-leaks test/ test/acceptance/" + }, + "gitHead": "bc38d896ea6bb8049e08467c0ff7fcf40956e744", + "bugs": { + "url": "https://github.com/strongloop/express/issues" + }, + "_id": "express@4.9.3", + "_shasum": "6aadd470fbb0fdd2550536ab33b63c3fcb7f1028", + "_from": "express@4.9.3", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + "maintainers": [ + { + "name": "tjholowaychuk", + "email": "tj@vision-media.ca" + }, + { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + }, + { + "name": "shtylman", + "email": "shtylman@gmail.com" + }, + { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + { + "name": "aredridel", + "email": "aredridel@nbtsc.org" + }, + { + "name": "strongloop", + "email": "callback@strongloop.com" + }, + { + "name": "rfeng", + "email": "enjoyjava@gmail.com" + } + ], + "dist": { + "shasum": "6aadd470fbb0fdd2550536ab33b63c3fcb7f1028", + "tarball": "http://registry.npmjs.org/express/-/express-4.9.3.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/express/-/express-4.9.3.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/morgan/HISTORY.md b/node_modules/morgan/HISTORY.md new file mode 100644 index 0000000..4d002d5 --- /dev/null +++ b/node_modules/morgan/HISTORY.md @@ -0,0 +1,67 @@ +1.3.1 / 2014-09-14 +================== + + * Remove us-used `bytes` dependency + * deps: depd@0.4.5 + +1.3.0 / 2014-09-01 +================== + + * Assert if `format` is not a function or string + +1.2.3 / 2014-08-16 +================== + + * deps: on-finished@2.1.0 + +1.2.2 / 2014-07-27 +================== + + * deps: depd@0.4.4 + - Work-around v8 generating empty stack traces + +1.2.1 / 2014-07-26 +================== + + * deps: depd@0.4.3 + - Fix exception when global `Error.stackTraceLimit` is too low + +1.2.0 / 2014-07-19 +================== + + * Add `:remote-user` token + * Add `combined` log format + * Add `common` log format + * Add `morgan(format, options)` function signature + * Deprecate `default` format -- use `combined` format instead + * Deprecate not providing a format + * Remove non-standard grey color from `dev` format + +1.1.1 / 2014-05-20 +================== + + * simplify method to get remote address + +1.1.0 / 2014-05-18 +================== + + * "dev" format will use same tokens as other formats + * `:response-time` token is now empty when immediate used + * `:response-time` token is now monotonic + * `:response-time` token has precision to 1 μs + * fix `:status` + immediate output in node.js 0.8 + * improve `buffer` option to prevent indefinite event loop holding + * deps: bytes@1.0.0 + - add negative support + +1.0.1 / 2014-05-04 +================== + + * Make buffer unique per morgan instance + * deps: bytes@0.3.0 + * added terabyte support + +1.0.0 / 2014-02-08 +================== + + * Initial release diff --git a/node_modules/morgan/LICENSE b/node_modules/morgan/LICENSE new file mode 100644 index 0000000..53e49a3 --- /dev/null +++ b/node_modules/morgan/LICENSE @@ -0,0 +1,23 @@ +(The MIT License) + +Copyright (c) 2014 Jonathan Ong +Copyright (c) 2014 Douglas Christopher Wilson + +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/node_modules/morgan/README.md b/node_modules/morgan/README.md new file mode 100644 index 0000000..9bf8aed --- /dev/null +++ b/node_modules/morgan/README.md @@ -0,0 +1,200 @@ +# morgan + +[![NPM Version][npm-image]][npm-url] +[![NPM Downloads][downloads-image]][downloads-url] +[![Build Status][travis-image]][travis-url] +[![Test Coverage][coveralls-image]][coveralls-url] +[![Gratipay][gratipay-image]][gratipay-url] + +HTTP request logger middleware for node.js + +> Named after [Dexter](http://en.wikipedia.org/wiki/Dexter_Morgan), a show you should not watch until completion. + +## API + +```js +var morgan = require('morgan') +``` + +### morgan(format, options) + +Create a new morgan logger middleware function using the given `format` and `options`. +The `format` argument may be a string of a predefined name (see below for the names), +a string of a format string, or a function that will produce a log entry. + +#### Options + +Morgan accepts these properties in the options object. + +#### buffer + +Buffer duration before writing logs to the `stream`, defaults to `false`. When +set to `true`, defaults to `1000 ms`. + +#### immediate + +Write log line on request instead of response. This means that a requests will +be logged even if the server crashes, _but data from the response (like the +response code, content length, etc.) cannot be logged_. + +##### skip + +Function to determine if logging is skipped, defaults to `false`. This function +will be called as `skip(req, res)`. + +```js +// EXAMPLE: only log error responses +morgan('combined', { + skip: function (req, res) { return res.statusCode < 400 } +}) +``` + +##### stream + +Output stream for writing log lines, defaults to `process.stdout`. + +#### Predefined Formats + +There are various pre-defined formats provided: + +##### combined + +Standard Apache combined log output. + +``` +:remote-addr - :remote-user [:date] ":method :url HTTP/:http-version" :status :res[content-length] ":referrer" ":user-agent" +``` + +##### common + +Standard Apache common log output. + +``` +:remote-addr - :remote-user [:date] ":method :url HTTP/:http-version" :status :res[content-length] +``` + +##### dev + +Concise output colored by response status for development use. The `:status` +token will be colored red for server error codes, yellow for client error +codes, cyan for redirection codes, and uncolored for all other codes. + +``` +:method :url :status :response-time ms - :res[content-length] +``` + +##### short + +Shorter than default, also including response time. + +``` +:remote-addr :remote-user :method :url HTTP/:http-version :status :res[content-length] - :response-time ms +``` + +##### tiny + +The minimal output. + +``` +:method :url :status :res[content-length] - :response-time ms +``` + +#### Tokens + +- `:req[header]` ex: `:req[Accept]` +- `:res[header]` ex: `:res[Content-Length]` +- `:http-version` +- `:response-time` +- `:remote-addr` +- `:remote-user` +- `:date` +- `:method` +- `:url` +- `:referrer` +- `:user-agent` +- `:status` + +To define a token, simply invoke `morgan.token()` with the name and a callback function. The value returned is then available as ":type" in this case: +```js +morgan.token('type', function(req, res){ return req.headers['content-type']; }) +``` + +## Examples + +### express/connect + +Simple app that will log all request in the Apache combined format to STDOUT + +```js +var express = require('express') +var morgan = require('morgan') + +var app = express() + +app.use(morgan('combined')) + +app.get('/', function (req, res) { + res.send('hello, world!') +}) +``` + +### vanilla http server + +Simple app that will log all request in the Apache combined format to STDOUT + +```js +var finalhandler = require('finalhandler') +var http = require('http') +var morgan = require('morgan') + +// create "middleware" +var logger = morgan('combined') + +http.createServer(function (req, res) { + var done = finalhandler(req, res) + logger(req, res, function (err) { + if (err) return done(err) + + // respond to request + res.setHeader('content-type', 'text/plain') + res.end('hello, world!') + }) +}) +``` + +### write logs to a file + +Simple app that will log all request in the Apache combined format to the file "access.log" + +```js +var express = require('express') +var fs = require('fs') +var morgan = require('morgan') + +var app = express() + +// create a write stream (in append mode) +var accessLogStream = fs.createWriteStream(__dirname + '/access.log', {flags: 'a'}) + +// setup the logger +app.use(morgan('combined', {stream: accessLogStream})) + +app.get('/', function (req, res) { + res.send('hello, world!') +}) +``` + +## License + +[MIT](LICENSE) + +[npm-image]: https://img.shields.io/npm/v/morgan.svg?style=flat +[npm-url]: https://npmjs.org/package/morgan +[travis-image]: https://img.shields.io/travis/expressjs/morgan.svg?style=flat +[travis-url]: https://travis-ci.org/expressjs/morgan +[coveralls-image]: https://img.shields.io/coveralls/expressjs/morgan.svg?style=flat +[coveralls-url]: https://coveralls.io/r/expressjs/morgan?branch=master +[downloads-image]: http://img.shields.io/npm/dm/morgan.svg?style=flat +[downloads-url]: https://npmjs.org/package/morgan +[gratipay-image]: https://img.shields.io/gratipay/dougwilson.svg?style=flat +[gratipay-url]: https://www.gratipay.com/dougwilson/ diff --git a/node_modules/morgan/index.js b/node_modules/morgan/index.js new file mode 100644 index 0000000..9726ea5 --- /dev/null +++ b/node_modules/morgan/index.js @@ -0,0 +1,321 @@ +/*! + * morgan + * Copyright(c) 2010 Sencha Inc. + * Copyright(c) 2011 TJ Holowaychuk + * Copyright(c) 2014 Jonathan Ong + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module dependencies. + */ + +var auth = require('basic-auth') +var deprecate = require('depd')('morgan') +var onFinished = require('on-finished') + +/** + * Default log buffer duration. + */ + +var defaultBufferDuration = 1000; + +/** + * Create a logger middleware. + * + * @param {String|Function} format + * @param {Object} [options] + * @return {Function} middleware + * @api public + */ + +exports = module.exports = function morgan(format, options) { + if (typeof format === 'object') { + options = format + format = options.format || 'default' + + // smart deprecation message + deprecate('morgan(options): use morgan(' + (typeof format === 'string' ? JSON.stringify(format) : 'format') + ', options) instead') + } + + if (format === undefined) { + deprecate('undefined format: specify a format') + } + + options = options || {} + + // output on request instead of response + var immediate = options.immediate; + + // check if log entry should be skipped + var skip = options.skip || function () { return false; }; + + // format function + var fmt = compile(exports[format] || format || exports.default) + + // options + var stream = options.stream || process.stdout + , buffer = options.buffer; + + // buffering support + if (buffer) { + var realStream = stream + var buf = [] + var timer = null + var interval = 'number' == typeof buffer + ? buffer + : defaultBufferDuration + + // flush function + var flush = function(){ + timer = null + + if (buf.length) { + realStream.write(buf.join('')); + buf.length = 0; + } + } + + // swap the stream + stream = { + write: function(str){ + if (timer === null) { + timer = setTimeout(flush, interval) + } + + buf.push(str); + } + }; + } + + return function logger(req, res, next) { + req._startAt = process.hrtime(); + req._startTime = new Date; + req._remoteAddress = req.connection && req.connection.remoteAddress; + + function logRequest(){ + if (skip(req, res)) return; + var line = fmt(exports, req, res); + if (null == line) return; + stream.write(line + '\n'); + }; + + // immediate + if (immediate) { + logRequest(); + } else { + onFinished(res, logRequest) + } + + next(); + }; +}; + +/** + * Compile `format` into a function. + * + * @param {Function|String} format + * @return {Function} + * @api private + */ + +function compile(format) { + if (typeof format === 'function') { + // already compiled + return format + } + + if (typeof format !== 'string') { + throw new TypeError('argument format must be a function or string') + } + + var fmt = format.replace(/"/g, '\\"') + var js = ' return "' + fmt.replace(/:([-\w]{2,})(?:\[([^\]]+)\])?/g, function(_, name, arg){ + return '"\n + (tokens["' + name + '"](req, res, "' + arg + '") || "-") + "'; + }) + '";' + + return new Function('tokens, req, res', js); +}; + +/** + * Define a token function with the given `name`, + * and callback `fn(req, res)`. + * + * @param {String} name + * @param {Function} fn + * @return {Object} exports for chaining + * @api public + */ + +exports.token = function(name, fn) { + exports[name] = fn; + return this; +}; + +/** + * Define a `fmt` with the given `name`. + * + * @param {String} name + * @param {String|Function} fmt + * @return {Object} exports for chaining + * @api public + */ + +exports.format = function(name, fmt){ + exports[name] = fmt; + return this; +}; + +/** + * Apache combined log format. + */ + +exports.format('combined', ':remote-addr - :remote-user [:date] ":method :url HTTP/:http-version" :status :res[content-length] ":referrer" ":user-agent"') + +/** + * Apache common log format. + */ + +exports.format('common', ':remote-addr - :remote-user [:date] ":method :url HTTP/:http-version" :status :res[content-length]') + +/** + * Default format. + */ + +exports.format('default', ':remote-addr - :remote-user [:date] ":method :url HTTP/:http-version" :status :res[content-length] ":referrer" ":user-agent"'); +deprecate.property(exports, 'default', 'default format: use combined format') + +/** + * Short format. + */ + +exports.format('short', ':remote-addr :remote-user :method :url HTTP/:http-version :status :res[content-length] - :response-time ms'); + +/** + * Tiny format. + */ + +exports.format('tiny', ':method :url :status :res[content-length] - :response-time ms'); + +/** + * dev (colored) + */ + +exports.format('dev', function(tokens, req, res){ + var color = 32; // green + var status = res.statusCode; + + if (status >= 500) color = 31; // red + else if (status >= 400) color = 33; // yellow + else if (status >= 300) color = 36; // cyan + + var fn = compile('\x1b[0m:method :url \x1b[' + color + 'm:status \x1b[0m:response-time ms - :res[content-length]\x1b[0m'); + + return fn(tokens, req, res); +}); + +/** + * request url + */ + +exports.token('url', function(req){ + return req.originalUrl || req.url; +}); + +/** + * request method + */ + +exports.token('method', function(req){ + return req.method; +}); + +/** + * response time in milliseconds + */ + +exports.token('response-time', function(req, res){ + if (!res._header || !req._startAt) return ''; + var diff = process.hrtime(req._startAt); + var ms = diff[0] * 1e3 + diff[1] * 1e-6; + return ms.toFixed(3); +}); + +/** + * UTC date + */ + +exports.token('date', function(){ + return new Date().toUTCString(); +}); + +/** + * response status code + */ + +exports.token('status', function(req, res){ + return res._header ? res.statusCode : null; +}); + +/** + * normalized referrer + */ + +exports.token('referrer', function(req){ + return req.headers['referer'] || req.headers['referrer']; +}); + +/** + * remote address + */ + +exports.token('remote-addr', function(req){ + if (req.ip) return req.ip; + if (req._remoteAddress) return req._remoteAddress; + if (req.connection) return req.connection.remoteAddress; + return undefined; +}); + +/** + * remote user + */ + +exports.token('remote-user', function (req) { + var creds = auth(req) + var user = (creds && creds.name) || '-' + return user; +}) + +/** + * HTTP version + */ + +exports.token('http-version', function(req){ + return req.httpVersionMajor + '.' + req.httpVersionMinor; +}); + +/** + * UA string + */ + +exports.token('user-agent', function(req){ + return req.headers['user-agent']; +}); + +/** + * request header + */ + +exports.token('req', function(req, res, field){ + return req.headers[field.toLowerCase()]; +}); + +/** + * response header + */ + +exports.token('res', function(req, res, field){ + return (res._headers || {})[field.toLowerCase()]; +}); + diff --git a/node_modules/morgan/node_modules/basic-auth/Readme.md b/node_modules/morgan/node_modules/basic-auth/Readme.md new file mode 100644 index 0000000..5859757 --- /dev/null +++ b/node_modules/morgan/node_modules/basic-auth/Readme.md @@ -0,0 +1,26 @@ +# basic-auth + + Generic basic auth Authorization header field parser for whatever. + +## Installation + +``` +$ npm install basic-auth +``` + +## Example + + Pass a node request or koa Context object to the module exported. If + parsing fails `undefined` is returned, otherwise an object with + `.name` and `.pass`. + +```js +var auth = require('basic-auth'); +var user = auth(req); +// => { name: 'something', pass: 'whatever' } + +``` + +# License + + MIT diff --git a/node_modules/morgan/node_modules/basic-auth/index.js b/node_modules/morgan/node_modules/basic-auth/index.js new file mode 100644 index 0000000..3ef1ff1 --- /dev/null +++ b/node_modules/morgan/node_modules/basic-auth/index.js @@ -0,0 +1,28 @@ + +/** + * Parse the Authorization header field of `req`. + * + * @param {Request} req + * @return {Object} with .name and .pass + * @api public + */ + +module.exports = function(req){ + req = req.req || req; + + var auth = req.headers.authorization; + if (!auth) return; + + // malformed + var parts = auth.split(' '); + if ('basic' != parts[0].toLowerCase()) return; + if (!parts[1]) return; + auth = parts[1]; + + // credentials + auth = new Buffer(auth, 'base64').toString(); + auth = auth.match(/^([^:]*):(.*)$/); + if (!auth) return; + + return { name: auth[1], pass: auth[2] }; +}; diff --git a/node_modules/morgan/node_modules/basic-auth/package.json b/node_modules/morgan/node_modules/basic-auth/package.json new file mode 100644 index 0000000..30bd7cb --- /dev/null +++ b/node_modules/morgan/node_modules/basic-auth/package.json @@ -0,0 +1,55 @@ +{ + "name": "basic-auth", + "version": "1.0.0", + "repository": { + "type": "git", + "url": "https://github.com/visionmedia/node-basic-auth" + }, + "description": "generic basic auth parser", + "keywords": [ + "basic", + "auth", + "authorization", + "basicauth" + ], + "devDependencies": { + "mocha": "*", + "should": "*" + }, + "scripts": { + "test": "make test" + }, + "files": [ + "index.js" + ], + "license": "MIT", + "gitHead": "099e8c703ea3994d72240492aba9b115517cf45e", + "bugs": { + "url": "https://github.com/visionmedia/node-basic-auth/issues" + }, + "homepage": "https://github.com/visionmedia/node-basic-auth", + "_id": "basic-auth@1.0.0", + "_shasum": "111b2d9ff8e4e6d136b8c84ea5e096cb87351637", + "_from": "basic-auth@1.0.0", + "_npmVersion": "1.4.16", + "_npmUser": { + "name": "jonathanong", + "email": "jonathanrichardong@gmail.com" + }, + "maintainers": [ + { + "name": "tjholowaychuk", + "email": "tj@vision-media.ca" + }, + { + "name": "jonathanong", + "email": "jonathanrichardong@gmail.com" + } + ], + "dist": { + "shasum": "111b2d9ff8e4e6d136b8c84ea5e096cb87351637", + "tarball": "http://registry.npmjs.org/basic-auth/-/basic-auth-1.0.0.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/basic-auth/-/basic-auth-1.0.0.tgz" +} diff --git a/node_modules/morgan/node_modules/depd/History.md b/node_modules/morgan/node_modules/depd/History.md new file mode 100644 index 0000000..800eab1 --- /dev/null +++ b/node_modules/morgan/node_modules/depd/History.md @@ -0,0 +1,62 @@ +0.4.5 / 2014-09-09 +================== + + * Improve call speed to functions using the function wrapper + * Support Node.js 0.6 + +0.4.4 / 2014-07-27 +================== + + * Work-around v8 generating empty stack traces + +0.4.3 / 2014-07-26 +================== + + * Fix exception when global `Error.stackTraceLimit` is too low + +0.4.2 / 2014-07-19 +================== + + * Correct call site for wrapped functions and properties + +0.4.1 / 2014-07-19 +================== + + * Improve automatic message generation for function properties + +0.4.0 / 2014-07-19 +================== + + * Add `TRACE_DEPRECATION` environment variable + * Remove non-standard grey color from color output + * Support `--no-deprecation` argument + * Support `--trace-deprecation` argument + * Support `deprecate.property(fn, prop, message)` + +0.3.0 / 2014-06-16 +================== + + * Add `NO_DEPRECATION` environment variable + +0.2.0 / 2014-06-15 +================== + + * Add `deprecate.property(obj, prop, message)` + * Remove `supports-color` dependency for node.js 0.8 + +0.1.0 / 2014-06-15 +================== + + * Add `deprecate.function(fn, message)` + * Add `process.on('deprecation', fn)` emitter + * Automatically generate message when omitted from `deprecate()` + +0.0.1 / 2014-06-15 +================== + + * Fix warning for dynamic calls at singe call site + +0.0.0 / 2014-06-15 +================== + + * Initial implementation diff --git a/node_modules/morgan/node_modules/depd/LICENSE b/node_modules/morgan/node_modules/depd/LICENSE new file mode 100644 index 0000000..b7dce6c --- /dev/null +++ b/node_modules/morgan/node_modules/depd/LICENSE @@ -0,0 +1,22 @@ +(The MIT License) + +Copyright (c) 2014 Douglas Christopher Wilson + +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/node_modules/morgan/node_modules/depd/Readme.md b/node_modules/morgan/node_modules/depd/Readme.md new file mode 100644 index 0000000..098953e --- /dev/null +++ b/node_modules/morgan/node_modules/depd/Readme.md @@ -0,0 +1,266 @@ +# depd + +[![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] +[![Gittip][gittip-image]][gittip-url] + +Deprecate all the things + +> With great modules comes great responsibility; mark things deprecated! + +## Install + +```sh +$ npm install depd +``` + +## API + +```js +var deprecate = require('depd')('my-module') +``` + +This library allows you to display deprecation messages to your users. +This library goes above and beyond with deprecation warnings by +introspecting the call stack (but only the bits that it is interested +in). + +Instead of just warning on the first invocation of a deprecated +function and never again, this module will warn on the first invocation +of a deprecated function per unique call site, making it ideal to alert +users of all deprecated uses across the code base, rather than just +whatever happens to execute first. + +The deprecation warnings from this module also include the file and line +information for the call into the module that the deprecated function was +in. + +### depd(namespace) + +Create a new deprecate function that uses the given namespace name in the +messages and will display the call site prior to the stack entering the +file this function was called from. It is highly suggested you use the +name of your module as the namespace. + +### deprecate(message) + +Call this function from deprecated code to display a deprecation message. +This message will appear once per unique caller site. Caller site is the +first call site in the stack in a different file from the caller of this +function. + +If the message is omitted, a message is generated for you based on the site +of the `deprecate()` call and will display the name of the function called, +similar to the name displayed in a stack trace. + +### deprecate.function(fn, message) + +Call this function to wrap a given function in a deprecation message on any +call to the function. An optional message can be supplied to provide a custom +message. + +### deprecate.property(obj, prop, message) + +Call this function to wrap a given property on object in a deprecation message +on any accessing or setting of the property. An optional message can be supplied +to provide a custom message. + +The method must be called on the object where the property belongs (not +inherited from the prototype). + +If the property is a data descriptor, it will be converted to an accessor +descriptor in order to display the deprecation message. + +### process.on('deprecation', fn) + +This module will allow easy capturing of deprecation errors by emitting the +errors as the type "deprecation" on the global `process`. If there are no +listeners for this type, the errors are written to STDERR as normal, but if +there are any listeners, nothing will be written to STDERR and instead only +emitted. From there, you can write the errors in a different format or to a +logging source. + +The error represents the deprecation and is emitted only once with the same +rules as writing to STDERR. The error has the following properties: + + - `message` - This is the message given by the library + - `name` - This is always `'DeprecationError'` + - `namespace` - This is the namespace the deprecation came from + - `stack` - This is the stack of the call to the deprecated thing + +Example `error.stack` output: + +``` +DeprecationError: my-cool-module deprecated oldfunction + at Object. ([eval]-wrapper:6:22) + at Module._compile (module.js:456:26) + at evalScript (node.js:532:25) + at startup (node.js:80:7) + at node.js:902:3 +``` + +### process.env.NO_DEPRECATION + +As a user of modules that are deprecated, the environment variable `NO_DEPRECATION` +is provided as a quick solution to silencing deprecation warnings from being +output. The format of this is similar to that of `DEBUG`: + +```sh +$ NO_DEPRECATION=my-module,othermod node app.js +``` + +This will suppress deprecations from being output for "my-module" and "othermod". +The value is a list of comma-separated namespaces. To suppress every warning +across all namespaces, use the value `*` for a namespace. + +Providing the argument `--no-deprecation` to the `node` executable will suppress +all deprecations (only available in Node.js 0.8 or higher). + +**NOTE** This will not suppress the deperecations given to any "deprecation" +event listeners, just the output to STDERR. + +### process.env.TRACE_DEPRECATION + +As a user of modules that are deprecated, the environment variable `TRACE_DEPRECATION` +is provided as a solution to getting more detailed location information in deprecation +warnings by including the entire stack trace. The format of this is the same as +`NO_DEPRECATION`: + +```sh +$ TRACE_DEPRECATION=my-module,othermod node app.js +``` + +This will include stack traces for deprecations being output for "my-module" and +"othermod". The value is a list of comma-separated namespaces. To trace every +warning across all namespaces, use the value `*` for a namespace. + +Providing the argument `--trace-deprecation` to the `node` executable will trace +all deprecations (only available in Node.js 0.8 or higher). + +**NOTE** This will not trace the deperecations silenced by `NO_DEPRECATION`. + +## Display + +![message](files/message.png) + +When a user calls a function in your library that you mark deprecated, they +will see the following written to STDERR (in the given colors, similar colors +and layout to the `debug` module): + +``` +bright cyan bright yellow +| | reset cyan +| | | | +▼ ▼ ▼ ▼ +my-cool-module deprecated oldfunction [eval]-wrapper:6:22 +▲ ▲ ▲ ▲ +| | | | +namespace | | location of mycoolmod.oldfunction() call + | deprecation message + the word "deprecated" +``` + +If the user redirects their STDERR to a file or somewhere that does not support +colors, they see (similar layout to the `debug` module): + +``` +Sun, 15 Jun 2014 05:21:37 GMT my-cool-module deprecated oldfunction at [eval]-wrapper:6:22 +▲ ▲ ▲ ▲ ▲ +| | | | | +timestamp of message namespace | | location of mycoolmod.oldfunction() call + | deprecation message + the word "deprecated" +``` + +## Examples + +### Deprecating all calls to a function + +This will display a deprecated message about "oldfunction" being deprecated +from "my-module" on STDERR. + +```js +var deprecate = require('depd')('my-cool-module') + +// message automatically derived from function name +// Object.oldfunction +exports.oldfunction = deprecate.function(function oldfunction() { + // all calls to function are deprecated +}) + +// specific message +exports.oldfunction = deprecate.function(function () { + // all calls to function are deprecated +}, 'oldfunction') +``` + +### Conditionally deprecating a function call + +This will display a deprecated message about "weirdfunction" being deprecated +from "my-module" on STDERR when called with less than 2 arguments. + +```js +var deprecate = require('depd')('my-cool-module') + +exports.weirdfunction = function () { + if (arguments.length < 2) { + // calls with 0 or 1 args are deprecated + deprecate('weirdfunction args < 2') + } +} +``` + +When calling `deprecate` as a function, the warning is counted per call site +within your own module, so you can display different deprecations depending +on different situations and the users will still get all the warnings: + +```js +var deprecate = require('depd')('my-cool-module') + +exports.weirdfunction = function () { + if (arguments.length < 2) { + // calls with 0 or 1 args are deprecated + deprecate('weirdfunction args < 2') + } else if (typeof arguments[0] !== 'string') { + // calls with non-string first argument are deprecated + deprecate('weirdfunction non-string first arg') + } +} +``` + +### Deprecating property access + +This will display a deprecated message about "oldprop" being deprecated +from "my-module" on STDERR when accessed. A deprecation will be displayed +when setting the value and when getting the value. + +```js +var deprecate = require('depd')('my-cool-module') + +exports.oldprop = 'something' + +// message automatically derives from property name +deprecate.property(exports, 'oldprop') + +// explicit message +deprecate.property(exports, 'oldprop', 'oldprop >= 0.10') +``` + +## License + +[MIT](LICENSE) + +[npm-version-image]: https://img.shields.io/npm/v/depd.svg?style=flat +[npm-downloads-image]: https://img.shields.io/npm/dm/depd.svg?style=flat +[npm-url]: https://npmjs.org/package/depd +[travis-image]: https://img.shields.io/travis/dougwilson/nodejs-depd.svg?style=flat +[travis-url]: https://travis-ci.org/dougwilson/nodejs-depd +[coveralls-image]: https://img.shields.io/coveralls/dougwilson/nodejs-depd.svg?style=flat +[coveralls-url]: https://coveralls.io/r/dougwilson/nodejs-depd?branch=master +[node-image]: https://img.shields.io/node/v/depd.svg?style=flat +[node-url]: http://nodejs.org/download/ +[gittip-image]: https://img.shields.io/gittip/dougwilson.svg?style=flat +[gittip-url]: https://www.gittip.com/dougwilson/ diff --git a/node_modules/morgan/node_modules/depd/index.js b/node_modules/morgan/node_modules/depd/index.js new file mode 100644 index 0000000..4fee4d9 --- /dev/null +++ b/node_modules/morgan/node_modules/depd/index.js @@ -0,0 +1,522 @@ +/*! + * depd + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module dependencies. + */ + +var callSiteToString = require('./lib/compat').callSiteToString +var EventEmitter = require('events').EventEmitter +var relative = require('path').relative + +/** + * Module exports. + */ + +module.exports = depd + +/** + * Get the path to base files on. + */ + +var basePath = process.cwd() + +/** + * Get listener count on event emitter. + */ + +/*istanbul ignore next*/ +var eventListenerCount = EventEmitter.listenerCount + || function (emitter, type) { return emitter.listeners(type).length } + +/** + * Determine if namespace is contained in the string. + */ + +function containsNamespace(str, namespace) { + var val = str.split(/[ ,]+/) + + namespace = String(namespace).toLowerCase() + + for (var i = 0 ; i < val.length; i++) { + if (!(str = val[i])) continue; + + // namespace contained + if (str === '*' || str.toLowerCase() === namespace) { + return true + } + } + + return false +} + +/** + * Convert a data descriptor to accessor descriptor. + */ + +function convertDataDescriptorToAccessor(obj, prop, message) { + var descriptor = Object.getOwnPropertyDescriptor(obj, prop) + var value = descriptor.value + + descriptor.get = function getter() { return value } + + if (descriptor.writable) { + descriptor.set = function setter(val) { return value = val } + } + + delete descriptor.value + delete descriptor.writable + + Object.defineProperty(obj, prop, descriptor) + + return descriptor +} + +/** + * Create arguments string to keep arity. + */ + +function createArgumentsString(arity) { + var str = '' + + for (var i = 0; i < arity; i++) { + str += ', arg' + i + } + + return str.substr(2) +} + +/** + * Create stack string from stack. + */ + +function createStackString(stack) { + var str = this.name + ': ' + this.namespace + + if (this.message) { + str += ' deprecated ' + this.message + } + + for (var i = 0; i < stack.length; i++) { + str += '\n at ' + callSiteToString(stack[i]) + } + + return str +} + +/** + * Create deprecate for namespace in caller. + */ + +function depd(namespace) { + if (!namespace) { + throw new TypeError('argument namespace is required') + } + + var stack = getStack() + var site = callSiteLocation(stack[1]) + var file = site[0] + + function deprecate(message) { + // call to self as log + log.call(deprecate, message) + } + + deprecate._file = file + deprecate._ignored = isignored(namespace) + deprecate._namespace = namespace + deprecate._traced = istraced(namespace) + deprecate._warned = Object.create(null) + + deprecate.function = wrapfunction + deprecate.property = wrapproperty + + return deprecate +} + +/** + * Determine if namespace is ignored. + */ + +function isignored(namespace) { + /* istanbul ignore next: tested in a child processs */ + if (process.noDeprecation) { + // --no-deprecation support + return true + } + + var str = process.env.NO_DEPRECATION || '' + + // namespace ignored + return containsNamespace(str, namespace) +} + +/** + * Determine if namespace is traced. + */ + +function istraced(namespace) { + /* istanbul ignore next: tested in a child processs */ + if (process.traceDeprecation) { + // --trace-deprecation support + return true + } + + var str = process.env.TRACE_DEPRECATION || '' + + // namespace traced + return containsNamespace(str, namespace) +} + +/** + * Display deprecation message. + */ + +function log(message, site) { + var haslisteners = eventListenerCount(process, 'deprecation') !== 0 + + // abort early if no destination + if (!haslisteners && this._ignored) { + return + } + + var caller + var callFile + var callSite + var i = 0 + var seen = false + var stack = getStack() + var file = this._file + + if (site) { + // provided site + callSite = callSiteLocation(stack[1]) + callSite.name = site.name + file = callSite[0] + } else { + // get call site + i = 2 + site = callSiteLocation(stack[i]) + callSite = site + } + + // get caller of deprecated thing in relation to file + for (; i < stack.length; i++) { + caller = callSiteLocation(stack[i]) + callFile = caller[0] + + if (callFile === file) { + seen = true + } else if (callFile === this._file) { + file = this._file + } else if (seen) { + break + } + } + + var key = caller + ? site.join(':') + '__' + caller.join(':') + : undefined + + if (key !== undefined && key in this._warned) { + // already warned + return + } + + this._warned[key] = true + + // generate automatic message from call site + if (!message) { + message = callSite === site || !callSite.name + ? defaultMessage(site) + : defaultMessage(callSite) + } + + // emit deprecation if listeners exist + if (haslisteners) { + var err = DeprecationError(this._namespace, message, stack.slice(i)) + process.emit('deprecation', err) + return + } + + // format and write message + var format = process.stderr.isTTY + ? formatColor + : formatPlain + var msg = format.call(this, message, caller, stack.slice(i)) + process.stderr.write(msg + '\n', 'utf8') + + return +} + +/** + * Get call site location as array. + */ + +function callSiteLocation(callSite) { + var file = callSite.getFileName() || '' + var line = callSite.getLineNumber() + var colm = callSite.getColumnNumber() + + if (callSite.isEval()) { + file = callSite.getEvalOrigin() + ', ' + file + } + + var site = [file, line, colm] + + site.callSite = callSite + site.name = callSite.getFunctionName() + + return site +} + +/** + * Generate a default message from the site. + */ + +function defaultMessage(site) { + var callSite = site.callSite + var funcName = site.name + var typeName = callSite.getTypeName() + + // make useful anonymous name + if (!funcName) { + funcName = '' + } + + // make useful type name + if (typeName === 'Function') { + typeName = callSite.getThis().name || typeName + } + + return callSite.getMethodName() + ? typeName + '.' + funcName + : funcName +} + +/** + * Format deprecation message without color. + */ + +function formatPlain(msg, caller, stack) { + var timestamp = new Date().toUTCString() + + var formatted = timestamp + + ' ' + this._namespace + + ' deprecated ' + msg + + // add stack trace + if (this._traced) { + for (var i = 0; i < stack.length; i++) { + formatted += '\n at ' + callSiteToString(stack[i]) + } + + return formatted + } + + if (caller) { + formatted += ' at ' + formatLocation(caller) + } + + return formatted +} + +/** + * Format deprecation message with color. + */ + +function formatColor(msg, caller, stack) { + var formatted = '\x1b[36;1m' + this._namespace + '\x1b[22;39m' // bold cyan + + ' \x1b[33;1mdeprecated\x1b[22;39m' // bold yellow + + ' \x1b[0m' + msg + '\x1b[39m' // reset + + // add stack trace + if (this._traced) { + for (var i = 0; i < stack.length; i++) { + formatted += '\n \x1b[36mat ' + callSiteToString(stack[i]) + '\x1b[39m' // cyan + } + + return formatted + } + + if (caller) { + formatted += ' \x1b[36m' + formatLocation(caller) + '\x1b[39m' // cyan + } + + return formatted +} + +/** + * Format call site location. + */ + +function formatLocation(callSite) { + return relative(basePath, callSite[0]) + + ':' + callSite[1] + + ':' + callSite[2] +} + +/** + * Get the stack as array of call sites. + */ + +function getStack() { + var limit = Error.stackTraceLimit + var obj = {} + var prep = Error.prepareStackTrace + + Error.prepareStackTrace = prepareObjectStackTrace + Error.stackTraceLimit = Math.max(10, limit) + + // capture the stack + Error.captureStackTrace(obj) + + // slice this function off the top + var stack = obj.stack.slice(1) + + Error.prepareStackTrace = prep + Error.stackTraceLimit = limit + + return stack +} + +/** + * Capture call site stack from v8. + */ + +function prepareObjectStackTrace(obj, stack) { + return stack +} + +/** + * Return a wrapped function in a deprecation message. + */ + +function wrapfunction(fn, message) { + if (typeof fn !== 'function') { + throw new TypeError('argument fn must be a function') + } + + var args = createArgumentsString(fn.length) + var deprecate = this + var stack = getStack() + var site = callSiteLocation(stack[1]) + + site.name = fn.name + + var deprecatedfn = eval('(function (' + args + ') {\n' + + '"use strict"\n' + + 'log.call(deprecate, message, site)\n' + + 'return fn.apply(this, arguments)\n' + + '})') + + return deprecatedfn +} + +/** + * Wrap property in a deprecation message. + */ + +function wrapproperty(obj, prop, message) { + if (!obj || (typeof obj !== 'object' && typeof obj !== 'function')) { + throw new TypeError('argument obj must be object') + } + + var descriptor = Object.getOwnPropertyDescriptor(obj, prop) + + if (!descriptor) { + throw new TypeError('must call property on owner object') + } + + if (!descriptor.configurable) { + throw new TypeError('property must be configurable') + } + + var deprecate = this + var stack = getStack() + var site = callSiteLocation(stack[1]) + + // set site name + site.name = prop + + // convert data descriptor + if ('value' in descriptor) { + descriptor = convertDataDescriptorToAccessor(obj, prop, message) + } + + var get = descriptor.get + var set = descriptor.set + + // wrap getter + if (typeof get === 'function') { + descriptor.get = function getter() { + log.call(deprecate, message, site) + return get.apply(this, arguments) + } + } + + // wrap setter + if (typeof set === 'function') { + descriptor.set = function setter() { + log.call(deprecate, message, site) + return set.apply(this, arguments) + } + } + + Object.defineProperty(obj, prop, descriptor) +} + +/** + * Create DeprecationError for deprecation + */ + +function DeprecationError(namespace, message, stack) { + var error = new Error() + var stackString + + Object.defineProperty(error, 'constructor', { + value: DeprecationError + }) + + Object.defineProperty(error, 'message', { + configurable: true, + enumerable: false, + value: message, + writable: true + }) + + Object.defineProperty(error, 'name', { + enumerable: false, + configurable: true, + value: 'DeprecationError', + writable: true + }) + + Object.defineProperty(error, 'namespace', { + configurable: true, + enumerable: false, + value: namespace, + writable: true + }) + + Object.defineProperty(error, 'stack', { + configurable: true, + enumerable: false, + get: function () { + if (stackString !== undefined) { + return stackString + } + + // prepare stack trace + return stackString = createStackString.call(this, stack) + }, + set: function setter(val) { + stackString = val + } + }) + + return error +} diff --git a/node_modules/morgan/node_modules/depd/lib/compat/buffer-concat.js b/node_modules/morgan/node_modules/depd/lib/compat/buffer-concat.js new file mode 100644 index 0000000..09d9721 --- /dev/null +++ b/node_modules/morgan/node_modules/depd/lib/compat/buffer-concat.js @@ -0,0 +1,33 @@ +/*! + * depd + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module exports. + */ + +module.exports = bufferConcat + +/** + * Concatenate an array of Buffers. + */ + +function bufferConcat(bufs) { + var length = 0 + + for (var i = 0, len = bufs.length; i < len; i++) { + length += bufs[i].length + } + + var buf = new Buffer(length) + var pos = 0 + + for (var i = 0, len = bufs.length; i < len; i++) { + bufs[i].copy(buf, pos) + pos += bufs[i].length + } + + return buf +} diff --git a/node_modules/morgan/node_modules/depd/lib/compat/callsite-tostring.js b/node_modules/morgan/node_modules/depd/lib/compat/callsite-tostring.js new file mode 100644 index 0000000..17cf7ed --- /dev/null +++ b/node_modules/morgan/node_modules/depd/lib/compat/callsite-tostring.js @@ -0,0 +1,101 @@ +/*! + * depd + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module exports. + */ + +module.exports = callSiteToString + +/** + * Format a CallSite file location to a string. + */ + +function callSiteFileLocation(callSite) { + var fileName + var fileLocation = '' + + if (callSite.isNative()) { + fileLocation = 'native' + } else if (callSite.isEval()) { + fileName = callSite.getScriptNameOrSourceURL() + if (!fileName) { + fileLocation = callSite.getEvalOrigin() + } + } else { + fileName = callSite.getFileName() + } + + if (fileName) { + fileLocation += fileName + + var lineNumber = callSite.getLineNumber() + if (lineNumber != null) { + fileLocation += ':' + lineNumber + + var columnNumber = callSite.getColumnNumber() + if (columnNumber) { + fileLocation += ':' + columnNumber + } + } + } + + return fileLocation || 'unknown source' +} + +/** + * Format a CallSite to a string. + */ + +function callSiteToString(callSite) { + var addSuffix = true + var fileLocation = callSiteFileLocation(callSite) + var functionName = callSite.getFunctionName() + var isConstructor = callSite.isConstructor() + var isMethodCall = !(callSite.isToplevel() || isConstructor) + var line = '' + + if (isMethodCall) { + var methodName = callSite.getMethodName() + var typeName = getConstructorName(callSite) + + if (functionName) { + if (typeName && functionName.indexOf(typeName) !== 0) { + line += typeName + '.' + } + + line += functionName + + if (methodName && functionName.lastIndexOf('.' + methodName) !== functionName.length - methodName.length - 1) { + line += ' [as ' + methodName + ']' + } + } else { + line += typeName + '.' + (methodName || '') + } + } else if (isConstructor) { + line += 'new ' + (functionName || '') + } else if (functionName) { + line += functionName + } else { + addSuffix = false + line += fileLocation + } + + if (addSuffix) { + line += ' (' + fileLocation + ')' + } + + return line +} + +/** + * Get constructor name of reviver. + */ + +function getConstructorName(obj) { + var receiver = obj.receiver + return (receiver.constructor && receiver.constructor.name) || null +} diff --git a/node_modules/morgan/node_modules/depd/lib/compat/index.js b/node_modules/morgan/node_modules/depd/lib/compat/index.js new file mode 100644 index 0000000..7fee026 --- /dev/null +++ b/node_modules/morgan/node_modules/depd/lib/compat/index.js @@ -0,0 +1,69 @@ +/*! + * depd + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module exports. + */ + +lazyProperty(module.exports, 'bufferConcat', function bufferConcat() { + return Buffer.concat || require('./buffer-concat') +}) + +lazyProperty(module.exports, 'callSiteToString', function callSiteToString() { + var limit = Error.stackTraceLimit + var obj = {} + var prep = Error.prepareStackTrace + + function prepareObjectStackTrace(obj, stack) { + return stack + } + + Error.prepareStackTrace = prepareObjectStackTrace + Error.stackTraceLimit = 2 + + // capture the stack + Error.captureStackTrace(obj) + + // slice the stack + var stack = obj.stack.slice() + + Error.prepareStackTrace = prep + Error.stackTraceLimit = limit + + return stack[0].toString ? toString : require('./callsite-tostring') +}) + +/** + * Define a lazy property. + */ + +function lazyProperty(obj, prop, getter) { + function get() { + var val = getter() + + Object.defineProperty(obj, prop, { + configurable: true, + enumerable: true, + value: val + }) + + return val + } + + Object.defineProperty(obj, prop, { + configurable: true, + enumerable: true, + get: get + }) +} + +/** + * Call toString() on the obj + */ + +function toString(obj) { + return obj.toString() +} diff --git a/node_modules/morgan/node_modules/depd/package.json b/node_modules/morgan/node_modules/depd/package.json new file mode 100644 index 0000000..55a9db0 --- /dev/null +++ b/node_modules/morgan/node_modules/depd/package.json @@ -0,0 +1,67 @@ +{ + "name": "depd", + "description": "Deprecate all the things", + "version": "0.4.5", + "author": { + "name": "Douglas Christopher Wilson", + "email": "doug@somethingdoug.com" + }, + "license": "MIT", + "keywords": [ + "deprecate", + "deprecated" + ], + "repository": { + "type": "git", + "url": "https://github.com/dougwilson/nodejs-depd" + }, + "devDependencies": { + "benchmark": "1.0.0", + "beautify-benchmark": "0.2.4", + "istanbul": "0.3.2", + "mocha": "~1.21.4", + "should": "~4.0.4" + }, + "files": [ + "lib/", + "History.md", + "LICENSE", + "index.js", + "Readme.md" + ], + "engines": { + "node": ">= 0.6" + }, + "scripts": { + "bench": "node benchmark/index.js", + "test": "mocha --reporter spec --bail --require should test/", + "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --require should test/", + "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --require should test/" + }, + "gitHead": "e37a15044f7da76b94d8e0d46a6343feb168c82b", + "bugs": { + "url": "https://github.com/dougwilson/nodejs-depd/issues" + }, + "homepage": "https://github.com/dougwilson/nodejs-depd", + "_id": "depd@0.4.5", + "_shasum": "1a664b53388b4a6573e8ae67b5f767c693ca97f1", + "_from": "depd@0.4.5", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + "maintainers": [ + { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + } + ], + "dist": { + "shasum": "1a664b53388b4a6573e8ae67b5f767c693ca97f1", + "tarball": "http://registry.npmjs.org/depd/-/depd-0.4.5.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/depd/-/depd-0.4.5.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/morgan/node_modules/on-finished/HISTORY.md b/node_modules/morgan/node_modules/on-finished/HISTORY.md new file mode 100644 index 0000000..0aa241b --- /dev/null +++ b/node_modules/morgan/node_modules/on-finished/HISTORY.md @@ -0,0 +1,66 @@ +2.1.0 / 2014-08-16 +================== + + * Check if `socket` is detached + * Return `undefined` for `isFinished` if state unknown + +2.0.0 / 2014-08-16 +================== + + * Add `isFinished` function + * Move to `jshttp` organization + * Remove support for plain socket argument + * Rename to `on-finished` + * Support both `req` and `res` as arguments + * deps: ee-first@1.0.5 + +1.2.2 / 2014-06-10 +================== + + * Reduce listeners added to emitters + - avoids "event emitter leak" warnings when used multiple times on same request + +1.2.1 / 2014-06-08 +================== + + * Fix returned value when already finished + +1.2.0 / 2014-06-05 +================== + + * Call callback when called on already-finished socket + +1.1.4 / 2014-05-27 +================== + + * Support node.js 0.8 + +1.1.3 / 2014-04-30 +================== + + * Make sure errors passed as instanceof `Error` + +1.1.2 / 2014-04-18 +================== + + * Default the `socket` to passed-in object + +1.1.1 / 2014-01-16 +================== + + * Rename module to `finished` + +1.1.0 / 2013-12-25 +================== + + * Call callback when called on already-errored socket + +1.0.1 / 2013-12-20 +================== + + * Actually pass the error to the callback + +1.0.0 / 2013-12-20 +================== + + * Initial release diff --git a/node_modules/morgan/node_modules/on-finished/LICENSE b/node_modules/morgan/node_modules/on-finished/LICENSE new file mode 100644 index 0000000..5931fd2 --- /dev/null +++ b/node_modules/morgan/node_modules/on-finished/LICENSE @@ -0,0 +1,23 @@ +(The MIT License) + +Copyright (c) 2013 Jonathan Ong +Copyright (c) 2014 Douglas Christopher Wilson + +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/node_modules/morgan/node_modules/on-finished/README.md b/node_modules/morgan/node_modules/on-finished/README.md new file mode 100644 index 0000000..887b5c3 --- /dev/null +++ b/node_modules/morgan/node_modules/on-finished/README.md @@ -0,0 +1,90 @@ +# on-finished + +[![NPM Version](http://img.shields.io/npm/v/on-finished.svg?style=flat)](https://www.npmjs.org/package/on-finished) +[![Node.js Version](http://img.shields.io/badge/node.js->=_0.8-brightgreen.svg?style=flat)](http://nodejs.org/download/) +[![Build Status](http://img.shields.io/travis/jshttp/on-finished.svg?style=flat)](https://travis-ci.org/jshttp/on-finished) +[![Coverage Status](https://img.shields.io/coveralls/jshttp/on-finished.svg?style=flat)](https://coveralls.io/r/jshttp/on-finished) + +Execute a callback when a request closes, finishes, or errors. + +## Install + +```sh +$ npm install on-finished +``` + +## API + +```js +var onFinished = require('on-finished') +``` + +### onFinished(res, listener) + +Attach a listener to listen for the response to finish. The listener will +be invoked only once when the response finished. If the response finished +to to an error, the first argument will contain the error. + +Listening to the end of a response would be used to close things associated +with the response, like open files. + +```js +onFinished(res, function (err) { + // clean up open fds, etc. +}) +``` + +### onFinished(req, listener) + +Attach a listener to listen for the request to finish. The listener will +be invoked only once when the request finished. If the request finished +to to an error, the first argument will contain the error. + +Listening to the end of a request would be used to know when to continue +after reading the data. + +```js +var data = '' + +req.setEncoding('utf8') +res.on('data', function (str) { + data += str +}) + +onFinished(req, function (err) { + // data is read unless there is err +}) +``` + +### onFinished.isFinished(res) + +Determine if `res` is already finished. This would be useful to check and +not even start certain operations if the response has already finished. + +### onFinished.isFinished(req) + +Determine if `req` is already finished. This would be useful to check and +not even start certain operations if the request has already finished. + +### Example + +The following code ensures that file descriptors are always closed +once the response finishes. + +```js +var destroy = require('destroy') +var http = require('http') +var onFinished = require('finished') + +http.createServer(function onRequest(req, res) { + var stream = fs.createReadStream('package.json') + stream.pipe(res) + onFinished(res, function (err) { + destroy(stream) + }) +}) +``` + +## License + +[MIT](LICENSE) diff --git a/node_modules/morgan/node_modules/on-finished/index.js b/node_modules/morgan/node_modules/on-finished/index.js new file mode 100644 index 0000000..a505561 --- /dev/null +++ b/node_modules/morgan/node_modules/on-finished/index.js @@ -0,0 +1,127 @@ +/*! + * on-finished + * Copyright(c) 2013 Jonathan Ong + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module exports. + */ + +module.exports = onFinished; +module.exports.isFinished = isFinished; + +/** +* Module dependencies. +*/ + +var first = require('ee-first') + +/** +* Variables. +*/ + +/* istanbul ignore next */ +var defer = typeof setImmediate === 'function' + ? setImmediate + : function(fn){ process.nextTick(fn.bind.apply(fn, arguments)) } + +/** + * Invoke callback when the response has finished, useful for + * cleaning up resources afterwards. + * + * @param {object} msg + * @param {function} listener + * @return {object} + * @api public + */ + +function onFinished(msg, listener) { + if (isFinished(msg) !== false) { + defer(listener) + return msg + } + + // attach the listener to the message + attachListener(msg, listener) + + return msg +} + +/** + * Determine is message is already finished. + * + * @param {object} msg + * @return {boolean} + * @api public + */ + +function isFinished(msg) { + var socket = msg.socket + + if (typeof msg.finished === 'boolean') { + // OutgoingMessage + return Boolean(!socket || msg.finished || !socket.writable) + } + + if (typeof msg.complete === 'boolean') { + // IncomingMessage + return Boolean(!socket || msg.complete || !socket.readable) + } + + // don't know + return undefined +} + +/** + * Attach the listener to the message. + * + * @param {object} msg + * @return {function} + * @api private + */ + +function attachListener(msg, listener) { + var attached = msg.__onFinished + var socket = msg.socket + + // create a private single listener with queue + if (!attached || !attached.queue) { + attached = msg.__onFinished = createListener(msg) + + // finished on first event + first([ + [socket, 'error', 'close'], + [msg, 'end', 'finish'], + ], attached) + } + + attached.queue.push(listener) +} + +/** + * Create listener on message. + * + * @param {object} msg + * @return {function} + * @api private + */ + +function createListener(msg) { + function listener(err) { + if (msg.__onFinished === listener) msg.__onFinished = null + if (!listener.queue) return + + var queue = listener.queue + listener.queue = null + + for (var i = 0; i < queue.length; i++) { + queue[i](err) + } + } + + listener.queue = [] + + return listener +} diff --git a/node_modules/morgan/node_modules/on-finished/node_modules/ee-first/LICENSE b/node_modules/morgan/node_modules/on-finished/node_modules/ee-first/LICENSE new file mode 100644 index 0000000..a7ae8ee --- /dev/null +++ b/node_modules/morgan/node_modules/on-finished/node_modules/ee-first/LICENSE @@ -0,0 +1,22 @@ + +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/node_modules/morgan/node_modules/on-finished/node_modules/ee-first/README.md b/node_modules/morgan/node_modules/on-finished/node_modules/ee-first/README.md new file mode 100644 index 0000000..0ebc0aa --- /dev/null +++ b/node_modules/morgan/node_modules/on-finished/node_modules/ee-first/README.md @@ -0,0 +1,63 @@ +# EE First + +[![NPM version][npm-image]][npm-url] +[![Build status][travis-image]][travis-url] +[![Test coverage][coveralls-image]][coveralls-url] +[![License][license-image]][license-url] +[![Downloads][downloads-image]][downloads-url] +[![Gittip][gittip-image]][gittip-url] + +Get the first event in a set of event emitters and event pairs, +then clean up after itself. + +## Install + +```sh +$ npm install ee-first +``` + +## API + +```js +var first = require('ee-first') +``` + +### first(arr, listener) + +Invoke `listener` on the first event from the list specified in `arr`. `arr` is +an array of arrays, with each array in the format `[ee, ...event]`. `listener` +will be called only once, the first time any of the given events are emitted. If +`error` is one of the listened events, then if that fires first, the `listener` +will be given the `err` argument. + +The `listener` is invoked as `listener(err, ee, event, args)`, where `err` is the +first argument emitted from an `error` event, if applicable; `ee` is the event +emitter that fired; `event` is the string event name that fired; and `args` is an +array of the arguments that were emitted on the event. + +```js +var ee1 = new EventEmitter() +var ee2 = new EventEmitter() + +first([ + [ee1, 'close', 'end', 'error'], + [ee2, 'error'] +], function (err, ee, event, args) { + // listener invoked +}) +``` + +[npm-image]: https://img.shields.io/npm/v/ee-first.svg?style=flat-square +[npm-url]: https://npmjs.org/package/ee-first +[github-tag]: http://img.shields.io/github/tag/jonathanong/ee-first.svg?style=flat-square +[github-url]: https://github.com/jonathanong/ee-first/tags +[travis-image]: https://img.shields.io/travis/jonathanong/ee-first.svg?style=flat-square +[travis-url]: https://travis-ci.org/jonathanong/ee-first +[coveralls-image]: https://img.shields.io/coveralls/jonathanong/ee-first.svg?style=flat-square +[coveralls-url]: https://coveralls.io/r/jonathanong/ee-first?branch=master +[license-image]: http://img.shields.io/npm/l/ee-first.svg?style=flat-square +[license-url]: LICENSE.md +[downloads-image]: http://img.shields.io/npm/dm/ee-first.svg?style=flat-square +[downloads-url]: https://npmjs.org/package/ee-first +[gittip-image]: https://img.shields.io/gittip/jonathanong.svg?style=flat-square +[gittip-url]: https://www.gittip.com/jonathanong/ diff --git a/node_modules/morgan/node_modules/on-finished/node_modules/ee-first/index.js b/node_modules/morgan/node_modules/on-finished/node_modules/ee-first/index.js new file mode 100644 index 0000000..d0c48c9 --- /dev/null +++ b/node_modules/morgan/node_modules/on-finished/node_modules/ee-first/index.js @@ -0,0 +1,60 @@ + +module.exports = function first(stuff, done) { + if (!Array.isArray(stuff)) + throw new TypeError('arg must be an array of [ee, events...] arrays') + + var cleanups = [] + + for (var i = 0; i < stuff.length; i++) { + var arr = stuff[i] + + if (!Array.isArray(arr) || arr.length < 2) + throw new TypeError('each array member must be [ee, events...]') + + var ee = arr[0] + + for (var j = 1; j < arr.length; j++) { + var event = arr[j] + var fn = listener(event, cleanup) + + // listen to the event + ee.on(event, fn) + // push this listener to the list of cleanups + cleanups.push({ + ee: ee, + event: event, + fn: fn, + }) + } + } + + return function (fn) { + done = fn + } + + function cleanup() { + var x + for (var i = 0; i < cleanups.length; i++) { + x = cleanups[i] + x.ee.removeListener(x.event, x.fn) + } + done.apply(null, arguments) + } +} + +function listener(event, done) { + return function onevent(arg1) { + var args = new Array(arguments.length) + var ee = this + var err = event === 'error' + ? arg1 + : null + + // copy args to prevent arguments escaping scope + for (var i = 0; i < args.length; i++) { + args[i] = arguments[i] + } + + done(err, ee, event, args) + } +} diff --git a/node_modules/morgan/node_modules/on-finished/node_modules/ee-first/package.json b/node_modules/morgan/node_modules/on-finished/node_modules/ee-first/package.json new file mode 100644 index 0000000..f19f55e --- /dev/null +++ b/node_modules/morgan/node_modules/on-finished/node_modules/ee-first/package.json @@ -0,0 +1,63 @@ +{ + "name": "ee-first", + "description": "return the first event in a set of ee/event pairs", + "version": "1.0.5", + "author": { + "name": "Jonathan Ong", + "email": "me@jongleberry.com", + "url": "http://jongleberry.com" + }, + "contributors": [ + { + "name": "Douglas Christopher Wilson", + "email": "doug@somethingdoug.com" + } + ], + "license": "MIT", + "repository": { + "type": "git", + "url": "https://github.com/jonathanong/ee-first" + }, + "devDependencies": { + "istanbul": "0.3.0", + "mocha": "1" + }, + "files": [ + "index.js", + "LICENSE" + ], + "scripts": { + "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/" + }, + "gitHead": "c9d9a6881863c0d2fcc2e4ac99a170088c205304", + "bugs": { + "url": "https://github.com/jonathanong/ee-first/issues" + }, + "homepage": "https://github.com/jonathanong/ee-first", + "_id": "ee-first@1.0.5", + "_shasum": "8c9b212898d8cd9f1a9436650ce7be202c9e9ff0", + "_from": "ee-first@1.0.5", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + "maintainers": [ + { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + }, + { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + } + ], + "dist": { + "shasum": "8c9b212898d8cd9f1a9436650ce7be202c9e9ff0", + "tarball": "http://registry.npmjs.org/ee-first/-/ee-first-1.0.5.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/ee-first/-/ee-first-1.0.5.tgz" +} diff --git a/node_modules/morgan/node_modules/on-finished/package.json b/node_modules/morgan/node_modules/on-finished/package.json new file mode 100644 index 0000000..bf7dcd6 --- /dev/null +++ b/node_modules/morgan/node_modules/on-finished/package.json @@ -0,0 +1,70 @@ +{ + "name": "on-finished", + "description": "Execute a callback when a request closes, finishes, or errors", + "version": "2.1.0", + "contributors": [ + { + "name": "Douglas Christopher Wilson", + "email": "doug@somethingdoug.com" + }, + { + "name": "Jonathan Ong", + "email": "me@jongleberry.com", + "url": "http://jongleberry.com" + } + ], + "license": "MIT", + "repository": { + "type": "git", + "url": "https://github.com/jshttp/on-finished" + }, + "dependencies": { + "ee-first": "1.0.5" + }, + "devDependencies": { + "istanbul": "0.3.0", + "mocha": "~1.21.4" + }, + "engine": { + "node": ">= 0.8.0" + }, + "files": [ + "HISTORY.md", + "LICENSE", + "index.js" + ], + "scripts": { + "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/" + }, + "gitHead": "1ad808e704e2aeda3a7464b78cacead2fb453727", + "bugs": { + "url": "https://github.com/jshttp/on-finished/issues" + }, + "homepage": "https://github.com/jshttp/on-finished", + "_id": "on-finished@2.1.0", + "_shasum": "0c539f09291e8ffadde0c8a25850fb2cedc7022d", + "_from": "on-finished@~2.1.0", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + "maintainers": [ + { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + } + ], + "dist": { + "shasum": "0c539f09291e8ffadde0c8a25850fb2cedc7022d", + "tarball": "http://registry.npmjs.org/on-finished/-/on-finished-2.1.0.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/on-finished/-/on-finished-2.1.0.tgz" +} diff --git a/node_modules/morgan/package.json b/node_modules/morgan/package.json new file mode 100644 index 0000000..a960efa --- /dev/null +++ b/node_modules/morgan/package.json @@ -0,0 +1,90 @@ +{ + "name": "morgan", + "description": "http request logger middleware for node.js", + "version": "1.3.1", + "author": { + "name": "Jonathan Ong", + "email": "me@jongleberry.com", + "url": "http://jongleberry.com" + }, + "contributors": [ + { + "name": "Douglas Christopher Wilson", + "email": "doug@somethingdoug.com" + } + ], + "license": "MIT", + "repository": { + "type": "git", + "url": "https://github.com/expressjs/morgan" + }, + "dependencies": { + "basic-auth": "1.0.0", + "depd": "0.4.5", + "on-finished": "2.1.0" + }, + "devDependencies": { + "istanbul": "0.3.2", + "mocha": "~1.21.0", + "should": "~4.0.4", + "supertest": "~0.13.0" + }, + "files": [ + "LICENSE", + "HISTORY.md", + "index.js" + ], + "engines": { + "node": ">= 0.8.0" + }, + "scripts": { + "test": "mocha --check-leaks --reporter spec --bail", + "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --check-leaks --reporter dot", + "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --check-leaks --reporter spec" + }, + "gitHead": "a7192887a0f388d6f397bd70c836a63d6b8afc76", + "bugs": { + "url": "https://github.com/expressjs/morgan/issues" + }, + "homepage": "https://github.com/expressjs/morgan", + "_id": "morgan@1.3.1", + "_shasum": "5c2ae66ef1da03f0ac9f0f42840cca5d8bfec23f", + "_from": "morgan@1.3.1", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + "maintainers": [ + { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + }, + { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + { + "name": "tjholowaychuk", + "email": "tj@vision-media.ca" + }, + { + "name": "shtylman", + "email": "shtylman@gmail.com" + }, + { + "name": "mscdex", + "email": "mscdex@mscdex.net" + }, + { + "name": "fishrock123", + "email": "fishrock123@rocketmail.com" + } + ], + "dist": { + "shasum": "5c2ae66ef1da03f0ac9f0f42840cca5d8bfec23f", + "tarball": "http://registry.npmjs.org/morgan/-/morgan-1.3.1.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/morgan/-/morgan-1.3.1.tgz" +} diff --git a/node_modules/mysql/.npmignore b/node_modules/mysql/.npmignore new file mode 100644 index 0000000..14aea2a --- /dev/null +++ b/node_modules/mysql/.npmignore @@ -0,0 +1,6 @@ +benchmark/ +coverage/ +lib-cov/ +test/ +tool/ +.travis.yml diff --git a/node_modules/mysql/Changes.md b/node_modules/mysql/Changes.md new file mode 100644 index 0000000..00d3b30 --- /dev/null +++ b/node_modules/mysql/Changes.md @@ -0,0 +1,351 @@ +# Changes + +This file is a manually maintained list of changes for each release. Feel free +to add your changes here when sending pull requests. Also send corrections if +you spot any mistakes. + +## v2.5.0 (2014-09-07) + +* Add code `POOL_ENQUEUELIMIT` to error reaching `queueLimit` +* Add `enqueue` event to pool #716 +* Add `enqueue` event to protocol and connection #381 +* Blacklist unsupported connection flags #881 +* Make only column names enumerable in `RowDataPacket` #549 #895 +* Support Node.js 0.6 #718 + +## v2.4.3 (2014-08-25) + +* Fix `pool.query` to use `typeCast` configuration + +## v2.4.2 (2014-08-03) + +* Fix incorrect sequence packet errors to be catchable #867 +* Fix stray protocol packet errors to be catchable #867 +* Fix timing of fatal protocol errors bubbling to user #879 + +## v2.4.1 (2014-07-17) + +* Fix `pool.query` not invoking callback on connection error #872 + +## v2.4.0 (2014-07-13) + +* Add code `POOL_NOEXIST` in PoolCluster error #846 +* Add `acquireTimeout` pool option to specify a timeout for acquiring a connection #821 #854 +* Add `connection.escapeId` +* Add `pool.escapeId` +* Add `timeout` option to all sequences #855 #863 +* Default `connectTimeout` to 10 seconds +* Fix domain binding with `conn.connect` +* Fix `packet.default` to actually be a string +* Fix `PARSER_*` errors to be catchable +* Fix `PROTOCOL_PACKETS_OUT_OF_ORDER` error to be catchable #844 +* Include packets that failed parsing under `debug` +* Return `Query` object from `pool.query` like `conn.query` #830 +* Use `EventEmitter.listenerCount` when possible for faster counting + +## v2.3.2 (2014-05-29) + +* Fix pool leaking connections after `conn.changeUser` #833 + +## v2.3.1 (2014-05-26) + +* Add database errors to error constants +* Add global errors to error constants +* Throw when calling `conn.release` multiple times #824 #827 +* Update known error codes + +## v2.3.0 (2014-05-16) + +* Accept MySQL charset (like `UTF8` or `UTF8MB4`) in `charset` option #808 +* Accept pool options in connection string to `mysql.createPool` #811 +* Clone connection config for new pool connections +* Default `connectTimeout` to 2 minutes +* Reject unauthorized SSL connections (use `ssl.rejectUnauthorized` to override) #816 +* Return last error when PoolCluster exhausts connection retries #818 +* Remove connection from pool after `conn.changeUser` is released #806 +* Throw on unknown SSL profile name #817 +* User newer TLS functions when available #809 + +## v2.2.0 (2014-04-27) + +* Use indexOf instead of for loops removing conn from pool #611 +* Make callback to `pool.query` optional like `conn.query` #585 +* Prevent enqueuing sequences after fatal error #400 +* Fix geometry parser for empty fields #742 +* Accept lower-case charset option +* Throw on unknown charset option #789 +* Update known charsets +* Remove console.warn from PoolCluster #744 +* Fix `pool.end` to handle queued connections #797 +* Fix `pool.releaseConnection` to keep connection queue flowing #797 +* Fix SSL handshake error to be catchable #800 +* Add `connection.threadId` to get MySQL connection ID #602 +* Ensure `pool.getConnection` retrieves good connections #434 #557 #778 +* Fix pool cluster wildcard matching #627 +* Pass query values through to `SqlString.format` #590 + +## v2.1.1 (2014-03-13) + +* fix authentication w/password failure for node.js 0.10.5 #746 #752 +* fix authentication w/password TypeError exception for node.js 0.10.0-0.10.4 #747 +* fix specifying `values` in `conn.query({...}).on(...)` pattern #755 +* fix long stack trace to include the `pool.query(...)` call #715 + +## v2.1.0 (2014-02-20) + +* crypto.createHash fix for node.js < 11 #735 +* Add `connectTimeout` option to specify a timeout for establishing a connection #726 +* SSL support #481 + +## v2.0.1 + +* internal parser speed improvement #702 +* domains support +* 'trace' connection option to control if long stack traces are generated #713 #710 #439 + +## v2.0.0 (2014-01-09) + +* stream improvements: + - node 0.8 support #692 + - Emit 'close' events from query streams #688 +* encoding fix in streaming LOAD DATA LOCAL INFILE #670 +* Doc improvements + +## v2.0.0-rc2 (2013-12-07) + +* Streaming LOAD DATA LOCAL INFILE #668 +* Doc improvements + +## v2.0.0-rc1 (2013-11-30) + +* Transaction support +* Expose SqlString.format as mysql.format() +* Many bug fixes +* Better support for dates in local time zone +* Doc improvements + +## v2.0.0-alpha9 (2013-08-27) + +* Add query to pool to execute queries directly using the pool +* Pool option to set queue limit +* Pool sends 'connection' event when it opens a new connection +* Added stringifyObjects option to treat input as strings rather than objects (#501) +* Support for poolClusters +* Datetime improvements +* Bug fixes + +## v2.0.0-alpha8 (2013-04-30) + +* Switch to old mode for Streams 2 (Node.js v 0.10.x) +* Add stream method to Query Wraps events from the query object into a node v0.10.x Readable stream +* DECIMAL should also be treated as big number +* Removed slow unnecessary stack access +* Added charsets +* Added bigNumberStrings option for forcing BIGINT columns as strings +* Changes date parsing to return String if not a valid JS Date +* Adds support for ?? escape sequence to escape identifiers +* Changes Auth.token() to force password to be in binary, not utf8 (#378) +* Restrict debugging by packet types +* Add 'multipleStatements' option tracking to ConnectionConfig. Fixes GH-408 +* Changes Pool to handle 'error' events and dispose connection +* Allows db.query({ sql: "..." }, [ val1, ... ], cb); (#390) +* Improved documentation +* Bug fixes + +## v2.0.0-alpha7 (2013-02-03) + +* Add connection pooling (#351) + +## v2.0.0-alpha6 (2013-01-31) + +* Add supportBigNumbers option (#381, #382) +* Accept prebuilt Query object in connection.query +* Bug fixes + +## v2.0.0-alpha5 (2012-12-03) + +* Add mysql.escapeId to escape identifiers (closes #342) +* Allow custom escaping mode (config.queryFormat) +* Convert DATE columns to configured timezone instead of UTC (#332) +* Convert LONGLONG and NEWDECIMAL to numbers (#333) +* Fix Connection.escape() (fixes #330) +* Changed Readme ambiguity about custom type cast fallback +* Change typeCast to receive Connection instead of Connection.config.timezone +* Fix drain event having useless err parameter +* Add Connection.statistics() back from v0.9 +* Add Connection.ping() back from v0.9 + +## v2.0.0-alpha4 (2012-10-03) + +* Fix some OOB errors on resume() +* Fix quick pause() / resume() usage +* Properly parse host denied / similar errors +* Add Connection.ChangeUser functionality +* Make sure changeUser errors are fatal +* Enable formatting nested arrays for bulk inserts +* Add Connection.escape functionality +* Renamed 'close' to 'end' event +* Return parsed object instead of Buffer for GEOMETRY types +* Allow nestTables inline (using a string instead of a boolean) +* Check for ZEROFILL_FLAG and format number accordingly +* Add timezone support (default: local) +* Add custom typeCast functionality +* Export mysql column types +* Add connection flags functionality (#237) +* Exports drain event when queue finishes processing (#272, #271, #306) + +## v2.0.0-alpha3 (2012-06-12) + +* Implement support for `LOAD DATA LOCAL INFILE` queries (#182). +* Support OLD\_PASSWORD() accounts like 0.9.x did. You should still upgrade any + user accounts in your your MySQL user table that has short (16 byte) Password + values. Connecting to those accounts is not secure. (#204) +* Ignore function values when escaping objects, allows to use RowDataPacket + objects as query arguments. (Alex Gorbatchev, #213) +* Handle initial error packets from server such as `ER_HOST_NOT_PRIVILEGED`. +* Treat `utf8\_bin` as a String, not Buffer. (#214) +* Handle empty strings in first row column value. (#222) +* Honor Connection#nestTables setting for queries. (#221) +* Remove `CLIENT_INTERACTIVE` flag from config. Improves #225. +* Improve docs for connections settings. +* Implement url string support for Connection configs. + +## v2.0.0-alpha2 (2012-05-31) + +* Specify escaping before for NaN / Infinity (they are as unquoted constants). +* Support for unix domain socket connections (use: {socketPath: '...'}). +* Fix type casting for NULL values for Date/Number fields +* Add `fields` argument to `query()` as well as `'fields'` event. This is + similar to what was available in 0.9.x. +* Support connecting to the sphinx searchd daemon as well as MariaDB (#199). +* Implement long stack trace support, will be removed / disabled if the node + core ever supports it natively. +* Implement `nestTables` option for queries, allows fetching JOIN result sets + with overlapping column names. +* Fix ? placeholder mechanism for values containing '?' characters (#205). +* Detect when `connect()` is called more than once on a connection and provide + the user with a good error message for it (#204). +* Switch to `UTF8_GENERAL_CI` (previously `UTF8_UNICODE_CI`) as the default + charset for all connections to avoid strange MySQL performance issues (#200), + and also make the charset user configurable. +* Fix BLOB type casting for `TINY_BLOB`, `MEDIUM_BLOB` and `LONG_BLOB`. +* Add support for sending and receiving large (> 16 MB) packets. + +## v2.0.0-alpha (2012-05-15) + +This release is a rewrite. You should carefully test your application after +upgrading to avoid problems. This release features many improvements, most +importantly: + +* ~5x faster than v0.9.x for parsing query results +* Support for pause() / resume() (for streaming rows) +* Support for multiple statement queries +* Support for stored procedures +* Support for transactions +* Support for binary columns (as blobs) +* Consistent & well documented error handling +* A new Connection class that has well defined semantics (unlike the old Client class). +* Convenient escaping of objects / arrays that allows for simpler query construction +* A significantly simpler code base +* Many bug fixes & other small improvements (Closed 62 out of 66 GitHub issues) + +Below are a few notes on the upgrade process itself: + +The first thing you will run into is that the old `Client` class is gone and +has been replaced with a less ambitious `Connection` class. So instead of +`mysql.createClient()`, you now have to: + +```js +var mysql = require('mysql'); +var connection = mysql.createConnection({ + host : 'localhost', + user : 'me', + password : 'secret', +}); + +connection.query('SELECT 1', function(err, rows) { + if (err) throw err; + + console.log('Query result: ', rows); +}); + +connection.end(); +``` + +The new `Connection` class does not try to handle re-connects, please study the +`Server disconnects` section in the new Readme. + +Other than that, the interface has stayed very similar. Here are a few things +to check out so: + +* BIGINT's are now cast into strings +* Binary data is now cast to buffers +* The `'row'` event on the `Query` object is now called `'result'` and will + also be emitted for queries that produce an OK/Error response. +* Error handling is consistently defined now, check the Readme +* Escaping has become more powerful which may break your code if you are + currently using objects to fill query placeholders. +* Connections can now be established explicitly again, so you may wish to do so + if you want to handle connection errors specifically. + +That should be most of it, if you run into anything else, please send a patch +or open an issue to improve this document. + +## v0.9.6 (2012-03-12) + +* Escape array values so they produce sql arrays (Roger Castells, Colin Smith) +* docs: mention mysql transaction stop gap solution (Blake Miner) +* docs: Mention affectedRows in FAQ (Michael Baldwin) + +## v0.9.5 (2011-11-26) + +* Fix #142 Driver stalls upon reconnect attempt that's immediately closed +* Add travis build +* Switch to urun as a test runner +* Switch to utest for unit tests +* Remove fast-or-slow dependency for tests +* Split integration tests into individual files again + +## v0.9.4 (2011-08-31) + +* Expose package.json as `mysql.PACKAGE` (#104) + +## v0.9.3 (2011-08-22) + +* Set default `client.user` to root +* Fix #91: Client#format should not mutate params array +* Fix #94: TypeError in client.js +* Parse decimals as string (vadimg) + +## v0.9.2 (2011-08-07) + +* The underlaying socket connection is now managed implicitly rather than explicitly. +* Check the [upgrading guide][] for a full list of changes. + +## v0.9.1 (2011-02-20) + +* Fix issue #49 / `client.escape()` throwing exceptions on objects. (Nick Payne) +* Drop < v0.4.x compatibility. From now on you need node v0.4.x to use this module. + +## Older releases + +These releases were done before maintaining this file: + +* [v0.9.0](https://github.com/felixge/node-mysql/compare/v0.8.0...v0.9.0) + (2011-01-04) +* [v0.8.0](https://github.com/felixge/node-mysql/compare/v0.7.0...v0.8.0) + (2010-10-30) +* [v0.7.0](https://github.com/felixge/node-mysql/compare/v0.6.0...v0.7.0) + (2010-10-14) +* [v0.6.0](https://github.com/felixge/node-mysql/compare/v0.5.0...v0.6.0) + (2010-09-28) +* [v0.5.0](https://github.com/felixge/node-mysql/compare/v0.4.0...v0.5.0) + (2010-09-17) +* [v0.4.0](https://github.com/felixge/node-mysql/compare/v0.3.0...v0.4.0) + (2010-09-02) +* [v0.3.0](https://github.com/felixge/node-mysql/compare/v0.2.0...v0.3.0) + (2010-08-25) +* [v0.2.0](https://github.com/felixge/node-mysql/compare/v0.1.0...v0.2.0) + (2010-08-22) +* [v0.1.0](https://github.com/felixge/node-mysql/commits/v0.1.0) + (2010-08-22) diff --git a/node_modules/mysql/License b/node_modules/mysql/License new file mode 100644 index 0000000..c7ff12a --- /dev/null +++ b/node_modules/mysql/License @@ -0,0 +1,19 @@ +Copyright (c) 2012 Felix Geisendörfer (felix@debuggable.com) and contributors + + Permission is hereby granted, free of charge, to any person obtaining a copy + of this software and associated documentation files (the "Software"), to deal + in the Software without restriction, including without limitation the rights + to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + copies of the Software, and to permit persons to whom the Software is + furnished to do so, subject to the following conditions: + + The above copyright notice and this permission notice shall be included in + all copies or substantial portions of the Software. + + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + THE SOFTWARE. diff --git a/node_modules/mysql/Readme.md b/node_modules/mysql/Readme.md new file mode 100644 index 0000000..51b9d14 --- /dev/null +++ b/node_modules/mysql/Readme.md @@ -0,0 +1,1182 @@ +# mysql + +[![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] + +## Install + +```sh +$ npm install mysql +``` + +For information about the previous 0.9.x releases, visit the [v0.9 branch][]. + +Sometimes I may also ask you to install the latest version from Github to check +if a bugfix is working. In this case, please do: + +```sh +$ npm install felixge/node-mysql +``` + +[v0.9 branch]: https://github.com/felixge/node-mysql/tree/v0.9 + +## Introduction + +This is a node.js driver for mysql. It is written in JavaScript, does not +require compiling, and is 100% MIT licensed. + +Here is an example on how to use it: + +```js +var mysql = require('mysql'); +var connection = mysql.createConnection({ + host : 'localhost', + user : 'me', + password : 'secret' +}); + +connection.connect(); + +connection.query('SELECT 1 + 1 AS solution', function(err, rows, fields) { + if (err) throw err; + + console.log('The solution is: ', rows[0].solution); +}); + +connection.end(); +``` + +From this example, you can learn the following: + +* Every method you invoke on a connection is queued and executed in sequence. +* Closing the connection is done using `end()` which makes sure all remaining + queries are executed before sending a quit packet to the mysql server. + +## Contributors + +Thanks goes to the people who have contributed code to this module, see the +[GitHub Contributors page][]. + +[GitHub Contributors page]: https://github.com/felixge/node-mysql/graphs/contributors + +Additionally I'd like to thank the following people: + +* [Andrey Hristov][] (Oracle) - for helping me with protocol questions. +* [Ulf Wendel][] (Oracle) - for helping me with protocol questions. + +[Ulf Wendel]: http://blog.ulf-wendel.de/ +[Andrey Hristov]: http://andrey.hristov.com/ + +## Sponsors + +The following companies have supported this project financially, allowing me to +spend more time on it (ordered by time of contribution): + +* [Transloadit](http://transloadit.com) (my startup, we do file uploading & + video encoding as a service, check it out) +* [Joyent](http://www.joyent.com/) +* [pinkbike.com](http://pinkbike.com/) +* [Holiday Extras](http://www.holidayextras.co.uk/) (they are [hiring](http://join.holidayextras.co.uk/vacancy/software-engineer/)) +* [Newscope](http://newscope.com/) (they are [hiring](http://www.newscope.com/stellenangebote)) + +If you are interested in sponsoring a day or more of my time, please +[get in touch][]. + +[get in touch]: http://felixge.de/#consulting + +## Community + +If you'd like to discuss this module, or ask questions about it, please use one +of the following: + +* **Mailing list**: https://groups.google.com/forum/#!forum/node-mysql +* **IRC Channel**: #node.js (on freenode.net, I pay attention to any message + including the term `mysql`) + +## Establishing connections + +The recommended way to establish a connection is this: + +```js +var mysql = require('mysql'); +var connection = mysql.createConnection({ + host : 'example.org', + user : 'bob', + password : 'secret' +}); + +connection.connect(function(err) { + if (err) { + console.error('error connecting: ' + err.stack); + return; + } + + console.log('connected as id ' + connection.threadId); +}); +``` + +However, a connection can also be implicitly established by invoking a query: + +```js +var mysql = require('mysql'); +var connection = mysql.createConnection(...); + +connection.query('SELECT 1', function(err, rows) { + // connected! (unless `err` is set) +}); +``` + +Depending on how you like to handle your errors, either method may be +appropriate. Any type of connection error (handshake or network) is considered +a fatal error, see the [Error Handling](#error-handling) section for more +information. + +## Connection options + +When establishing a connection, you can set the following options: + +* `host`: The hostname of the database you are connecting to. (Default: + `localhost`) +* `port`: The port number to connect to. (Default: `3306`) +* `localAddress`: The source IP address to use for TCP connection. (Optional) +* `socketPath`: The path to a unix domain socket to connect to. When used `host` + and `port` are ignored. +* `user`: The MySQL user to authenticate as. +* `password`: The password of that MySQL user. +* `database`: Name of the database to use for this connection (Optional). +* `charset`: The charset for the connection. This is called "collation" in the SQL-level + of MySQL (like `utf8_general_ci`). If a SQL-level charset is specified (like `utf8mb4`) + then the default collation for that charset is used. (Default: `'UTF8_GENERAL_CI'`) +* `timezone`: The timezone used to store local dates. (Default: `'local'`) +* `connectTimeout`: The milliseconds before a timeout occurs during the initial connection + to the MySQL server. (Default: 10 seconds) +* `stringifyObjects`: Stringify objects instead of converting to values. See +issue [#501](https://github.com/felixge/node-mysql/issues/501). (Default: `'false'`) +* `insecureAuth`: Allow connecting to MySQL instances that ask for the old + (insecure) authentication method. (Default: `false`) +* `typeCast`: Determines if column values should be converted to native + JavaScript types. (Default: `true`) +* `queryFormat`: A custom query format function. See [Custom format](#custom-format). +* `supportBigNumbers`: When dealing with big numbers (BIGINT and DECIMAL columns) in the database, + you should enable this option (Default: `false`). +* `bigNumberStrings`: Enabling both `supportBigNumbers` and `bigNumberStrings` forces big numbers + (BIGINT and DECIMAL columns) to be always returned as JavaScript String objects (Default: `false`). + Enabling `supportBigNumbers` but leaving `bigNumberStrings` disabled will return big numbers as String + objects only when they cannot be accurately represented with [JavaScript Number objects] (http://ecma262-5.com/ELS5_HTML.htm#Section_8.5) + (which happens when they exceed the [-2^53, +2^53] range), otherwise they will be returned as + Number objects. This option is ignored if `supportBigNumbers` is disabled. +* `dateStrings`: Force date types (TIMESTAMP, DATETIME, DATE) to be returned as strings rather then + inflated into JavaScript Date objects. (Default: `false`) +* `debug`: Prints protocol details to stdout. (Default: `false`) +* `trace`: Generates stack traces on `Error` to include call site of library + entrance ("long stack traces"). Slight performance penalty for most calls. + (Default: `true`) +* `multipleStatements`: Allow multiple mysql statements per query. Be careful + with this, it exposes you to SQL injection attacks. (Default: `false`) +* `flags`: List of connection flags to use other than the default ones. It is + also possible to blacklist default ones. For more information, check + [Connection Flags](#connection-flags). +* `ssl`: object with ssl parameters or a string containing name of ssl profile. See [SSL options](#ssl-options). + + +In addition to passing these options as an object, you can also use a url +string. For example: + +```js +var connection = mysql.createConnection('mysql://user:pass@host/db?debug=true&charset=BIG5_CHINESE_CI&timezone=-0700'); +``` + +Note: The query values are first attempted to be parsed as JSON, and if that +fails assumed to be plaintext strings. + +### SSL options + +The `ssl` option in the connection options takes a string or an object. When given a string, +it uses one of the predefined SSL profiles included. The following profiles are included: + +* `"Amazon RDS"`: this profile is for connecting to an Amazon RDS server and contains the + ca from https://rds.amazonaws.com/doc/rds-ssl-ca-cert.pem + +When connecting to other servers, you will need to provide an object of options, in the +same format as [crypto.createCredentials](http://nodejs.org/api/crypto.html#crypto_crypto_createcredentials_details). +Please note the arguments expect a string of the certificate, not a file name to the +certificate. Here is a simple example: + +```js +var connection = mysql.createConnection({ + host : 'localhost', + ssl : { + ca : fs.readFileSync(__dirname + '/mysql-ca.crt') + } +}); +``` + +You can also connect to a MySQL server without properly providing the appropriate +CA to trust. _You should not do this_. + +```js +var connection = mysql.createConnection({ + host : 'localhost', + ssl : { + // DO NOT DO THIS + // set up your ca correctly to trust the connection + rejectUnauthorized: false + } +}); +``` + +## Terminating connections + +There are two ways to end a connection. Terminating a connection gracefully is +done by calling the `end()` method: + +```js +connection.end(function(err) { + // The connection is terminated now +}); +``` + +This will make sure all previously enqueued queries are still before sending a +`COM_QUIT` packet to the MySQL server. If a fatal error occurs before the +`COM_QUIT` packet can be sent, an `err` argument will be provided to the +callback, but the connection will be terminated regardless of that. + +An alternative way to end the connection is to call the `destroy()` method. +This will cause an immediate termination of the underlying socket. +Additionally `destroy()` guarantees that no more events or callbacks will be +triggered for the connection. + +```js +connection.destroy(); +``` + +Unlike `end()` the `destroy()` method does not take a callback argument. + +## Pooling connections + +Use pool directly. +```js +var mysql = require('mysql'); +var pool = mysql.createPool({ + connectionLimit : 10, + host : 'example.org', + user : 'bob', + password : 'secret' +}); + +pool.query('SELECT 1 + 1 AS solution', function(err, rows, fields) { + if (err) throw err; + + console.log('The solution is: ', rows[0].solution); +}); +``` + +Connections can be pooled to ease sharing a single connection, or managing +multiple connections. + +```js +var mysql = require('mysql'); +var pool = mysql.createPool({ + host : 'example.org', + user : 'bob', + password : 'secret' +}); + +pool.getConnection(function(err, connection) { + // connected! (unless `err` is set) +}); +``` + +When you are done with a connection, just call `connection.release()` and the +connection will return to the pool, ready to be used again by someone else. + +```js +var mysql = require('mysql'); +var pool = mysql.createPool(...); + +pool.getConnection(function(err, connection) { + // Use the connection + connection.query( 'SELECT something FROM sometable', function(err, rows) { + // And done with the connection. + connection.release(); + + // Don't use the connection here, it has been returned to the pool. + }); +}); +``` + +If you would like to close the connection and remove it from the pool, use +`connection.destroy()` instead. The pool will create a new connection the next +time one is needed. + +Connections are lazily created by the pool. If you configure the pool to allow +up to 100 connections, but only ever use 5 simultaneously, only 5 connections +will be made. Connections are also cycled round-robin style, with connections +being taken from the top of the pool and returning to the bottom. + +When a previous connection is retrieved from the pool, a ping packet is sent +to the server to check if the connection is still good. + +## Pool options + +Pools accept all the same options as a connection. When creating a new +connection, the options are simply passed to the connection constructor. In +addition to those options pools accept a few extras: + +* `acquireTimeout`: The milliseconds before a timeout occurs during the connection + acquisition. This is slightly different from `connectTimeout`, because acquiring + a pool connection does not always involve making a connection. (Default: 10 seconds) +* `waitForConnections`: Determines the pool's action when no connections are + available and the limit has been reached. If `true`, the pool will queue the + connection request and call it when one becomes available. If `false`, the + pool will immediately call back with an error. (Default: `true`) +* `connectionLimit`: The maximum number of connections to create at once. + (Default: `10`) +* `queueLimit`: The maximum number of connection requests the pool will queue + before returning an error from `getConnection`. If set to `0`, there is no + limit to the number of queued connection requests. (Default: `0`) + +## Pool events + +### connection + +The pool will emit a `connection` event when a new connection is made within the pool. +If you need to set session variables on the connection before it gets used, you can +listen to the `connection` event. + +```js +pool.on('connection', function (connection) { + connection.query('SET SESSION auto_increment_increment=1') +}); +``` + +### enqueue + +The pool will emit an `enqueue` event when a callback has been queued to wait for +an available connection. + +```js +pool.on('enqueue', function () { + console.log('Waiting for available connection slot'); +}); +``` + +## PoolCluster + +PoolCluster provides multiple hosts connection. (group & retry & selector) + +```js +// create +var poolCluster = mysql.createPoolCluster(); + +poolCluster.add(config); // anonymous group +poolCluster.add('MASTER', masterConfig); +poolCluster.add('SLAVE1', slave1Config); +poolCluster.add('SLAVE2', slave2Config); + +// Target Group : ALL(anonymous, MASTER, SLAVE1-2), Selector : round-robin(default) +poolCluster.getConnection(function (err, connection) {}); + +// Target Group : MASTER, Selector : round-robin +poolCluster.getConnection('MASTER', function (err, connection) {}); + +// Target Group : SLAVE1-2, Selector : order +// If can't connect to SLAVE1, return SLAVE2. (remove SLAVE1 in the cluster) +poolCluster.on('remove', function (nodeId) { + console.log('REMOVED NODE : ' + nodeId); // nodeId = SLAVE1 +}); + +poolCluster.getConnection('SLAVE*', 'ORDER', function (err, connection) {}); + +// of namespace : of(pattern, selector) +poolCluster.of('*').getConnection(function (err, connection) {}); + +var pool = poolCluster.of('SLAVE*', 'RANDOM'); +pool.getConnection(function (err, connection) {}); +pool.getConnection(function (err, connection) {}); + +// destroy +poolCluster.end(); +``` + +## PoolCluster Option +* `canRetry`: If `true`, `PoolCluster` will attempt to reconnect when connection fails. (Default: `true`) +* `removeNodeErrorCount`: If connection fails, node's `errorCount` increases. + When `errorCount` is greater than `removeNodeErrorCount`, remove a node in the `PoolCluster`. (Default: `5`) +* `defaultSelector`: The default selector. (Default: `RR`) + * `RR`: Select one alternately. (Round-Robin) + * `RANDOM`: Select the node by random function. + * `ORDER`: Select the first node available unconditionally. + +```js +var clusterConfig = { + removeNodeErrorCount: 1, // Remove the node immediately when connection fails. + defaultSelector: 'ORDER' +}; + +var poolCluster = mysql.createPoolCluster(clusterConfig); +``` + +## Switching users / altering connection state + +MySQL offers a changeUser command that allows you to alter the current user and +other aspects of the connection without shutting down the underlying socket: + +```js +connection.changeUser({user : 'john'}, function(err) { + if (err) throw err; +}); +``` + +The available options for this feature are: + +* `user`: The name of the new user (defaults to the previous one). +* `password`: The password of the new user (defaults to the previous one). +* `charset`: The new charset (defaults to the previous one). +* `database`: The new database (defaults to the previous one). + +A sometimes useful side effect of this functionality is that this function also +resets any connection state (variables, transactions, etc.). + +Errors encountered during this operation are treated as fatal connection errors +by this module. + +## Server disconnects + +You may lose the connection to a MySQL server due to network problems, the +server timing you out, the server being restarted, or crashing. All of these +events are considered fatal errors, and will have the `err.code = +'PROTOCOL_CONNECTION_LOST'`. See the [Error Handling](#error-handling) section +for more information. + +Re-connecting a connection is done by establishing a new connection. Once +terminated, an existing connection object cannot be re-connected by design. + +With Pool, disconnected connections will be removed from the pool freeing up +space for a new connection to be created on the next getConnection call. + +## Escaping query values + +In order to avoid SQL Injection attacks, you should always escape any user +provided data before using it inside a SQL query. You can do so using the +`connection.escape()` or `pool.escape()` methods: + +```js +var userId = 'some user provided value'; +var sql = 'SELECT * FROM users WHERE id = ' + connection.escape(userId); +connection.query(sql, function(err, results) { + // ... +}); +``` + +Alternatively, you can use `?` characters as placeholders for values you would +like to have escaped like this: + +```js +connection.query('SELECT * FROM users WHERE id = ?', [userId], function(err, results) { + // ... +}); +``` + +This looks similar to prepared statements in MySQL, however it really just uses +the same `connection.escape()` method internally. + +**Caution** This also differs from prepared statements in that all `?` are +replaced, even those contained in comments and strings. + +Different value types are escaped differently, here is how: + +* Numbers are left untouched +* Booleans are converted to `true` / `false` strings +* Date objects are converted to `'YYYY-mm-dd HH:ii:ss'` strings +* Buffers are converted to hex strings, e.g. `X'0fa5'` +* Strings are safely escaped +* Arrays are turned into list, e.g. `['a', 'b']` turns into `'a', 'b'` +* Nested arrays are turned into grouped lists (for bulk inserts), e.g. `[['a', + 'b'], ['c', 'd']]` turns into `('a', 'b'), ('c', 'd')` +* Objects are turned into `key = 'val'` pairs. Nested objects are cast to + strings. +* `undefined` / `null` are converted to `NULL` +* `NaN` / `Infinity` are left as-is. MySQL does not support these, and trying + to insert them as values will trigger MySQL errors until they implement + support. + +If you paid attention, you may have noticed that this escaping allows you +to do neat things like this: + +```js +var post = {id: 1, title: 'Hello MySQL'}; +var query = connection.query('INSERT INTO posts SET ?', post, function(err, result) { + // Neat! +}); +console.log(query.sql); // INSERT INTO posts SET `id` = 1, `title` = 'Hello MySQL' + +``` + +If you feel the need to escape queries by yourself, you can also use the escaping +function directly: + +```js +var query = "SELECT * FROM posts WHERE title=" + mysql.escape("Hello MySQL"); + +console.log(query); // SELECT * FROM posts WHERE title='Hello MySQL' +``` + +## Escaping query identifiers + +If you can't trust an SQL identifier (database / table / column name) because it is +provided by a user, you should escape it with `mysql.escapeId(identifier)`, +`connection.escapeId(identifier)` or `pool.escapeId(identifier)` like this: + +```js +var sorter = 'date'; +var sql = 'SELECT * FROM posts ORDER BY ' + connection.escapeId(sorter); +connection.query(sql, function(err, results) { + // ... +}); +``` + +It also supports adding qualified identifiers. It will escape both parts. + +```js +var sorter = 'date'; +var sql = 'SELECT * FROM posts ORDER BY ' + connection.escapeId('posts.' + sorter); +connection.query(sql, function(err, results) { + // ... +}); +``` + +Alternatively, you can use `??` characters as placeholders for identifiers you would +like to have escaped like this: + +```js +var userId = 1; +var columns = ['username', 'email']; +var query = connection.query('SELECT ?? FROM ?? WHERE id = ?', [columns, 'users', userId], function(err, results) { + // ... +}); + +console.log(query.sql); // SELECT `username`, `email` FROM `users` WHERE id = 1 +``` +**Please note that this last character sequence is experimental and syntax might change** + +When you pass an Object to `.escape()` or `.query()`, `.escapeId()` is used to avoid SQL injection in object keys. + +### Preparing Queries + +You can use mysql.format to prepare a query with multiple insertion points, utilizing the proper escaping for ids and values. A simple example of this follows: + +```js +var sql = "SELECT * FROM ?? WHERE ?? = ?"; +var inserts = ['users', 'id', userId]; +sql = mysql.format(sql, inserts); +``` + +Following this you then have a valid, escaped query that you can then send to the database safely. This is useful if you are looking to prepare the query before actually sending it to the database. As mysql.format is exposed from SqlString.format you also have the option (but are not required) to pass in stringifyObject and timezone, allowing you provide a custom means of turning objects into strings, as well as a location-specific/timezone-aware Date. + +### Custom format + +If you prefer to have another type of query escape format, there's a connection configuration option you can use to define a custom format function. You can access the connection object if you want to use the built-in `.escape()` or any other connection function. + +Here's an example of how to implement another format: + +```js +connection.config.queryFormat = function (query, values) { + if (!values) return query; + return query.replace(/\:(\w+)/g, function (txt, key) { + if (values.hasOwnProperty(key)) { + return this.escape(values[key]); + } + return txt; + }.bind(this)); +}; + +connection.query("UPDATE posts SET title = :title", { title: "Hello MySQL" }); +``` + +## Getting the id of an inserted row + +If you are inserting a row into a table with an auto increment primary key, you +can retrieve the insert id like this: + +```js +connection.query('INSERT INTO posts SET ?', {title: 'test'}, function(err, result) { + if (err) throw err; + + console.log(result.insertId); +}); +``` + +When dealing with big numbers (above JavaScript Number precision limit), you should +consider enabling `supportBigNumbers` option to be able to read the insert id as a +string, otherwise it will throw. + +This option is also required when fetching big numbers from the database, otherwise +you will get values rounded to hundreds or thousands due to the precision limit. + +## Getting the number of affected rows. + +You can get the number of affected rows from an insert, update or delete statement. + +```js +connection.query('DELETE FROM posts WHERE title = "wrong"', function (err, result) { + if (err) throw err; + + console.log('deleted ' + result.affectedRows + ' rows'); +}) +``` + +## Getting the number of changed rows. + +You can get the number of changed rows from an update statement. + +"changedRows" differs from "affectedRows" in that it does not count updated rows +whose values were not changed. + +```js +connection.query('UPDATE posts SET ...', function (err, result) { + if (err) throw err; + + console.log('changed ' + result.changedRows + ' rows'); +}) +``` + +## Getting the connection ID + +You can get the MySQL connection ID ("thread ID") of a given connection using the `threadId` +property. + +```js +connection.connect(function(err) { + if (err) throw err; + console.log('connected as id ' + connection.threadId); +}); +``` + +## Executing queries in parallel + +The MySQL protocol is sequential, this means that you need multiple connections +to execute queries in parallel. You can use a Pool to manage connections, one +simple approach is to create one connection per incoming http request. + +## Streaming query rows + +Sometimes you may want to select large quantities of rows and process each of +them as they are received. This can be done like this: + +```js +var query = connection.query('SELECT * FROM posts'); +query + .on('error', function(err) { + // Handle error, an 'end' event will be emitted after this as well + }) + .on('fields', function(fields) { + // the field packets for the rows to follow + }) + .on('result', function(row) { + // Pausing the connnection is useful if your processing involves I/O + connection.pause(); + + processRow(row, function() { + connection.resume(); + }); + }) + .on('end', function() { + // all rows have been received + }); +``` + +Please note a few things about the example above: + +* Usually you will want to receive a certain amount of rows before starting to + throttle the connection using `pause()`. This number will depend on the + amount and size of your rows. +* `pause()` / `resume()` operate on the underlying socket and parser. You are + guaranteed that no more `'result'` events will fire after calling `pause()`. +* You MUST NOT provide a callback to the `query()` method when streaming rows. +* The `'result'` event will fire for both rows as well as OK packets + confirming the success of a INSERT/UPDATE query. + +Additionally you may be interested to know that it is currently not possible to +stream individual row columns, they will always be buffered up entirely. If you +have a good use case for streaming large fields to and from MySQL, I'd love to +get your thoughts and contributions on this. + +### Piping results with [Streams2](http://blog.nodejs.org/2012/12/20/streams2/) + +The query object provides a convenience method `.stream([options])` that wraps +query events into a [Readable](http://nodejs.org/api/stream.html#stream_class_stream_readable) +Streams2 object. This stream can easily be piped downstream and provides +automatic pause/resume, based on downstream congestion and the optional +`highWaterMark`. The `objectMode` parameter of the stream is set to `true` by +default. + +For example, piping query results into another stream (with a max buffer of 5 +objects) is simply: + +```js +connection.query('SELECT * FROM posts') + .stream({highWaterMark: 5}) + .pipe(...); +``` + +## Multiple statement queries + +Support for multiple statements is disabled for security reasons (it allows for +SQL injection attacks if values are not properly escaped). To use this feature +you have to enable it for your connection: + +```js +var connection = mysql.createConnection({multipleStatements: true}); +``` + +Once enabled, you can execute multiple statement queries like any other query: + +```js +connection.query('SELECT 1; SELECT 2', function(err, results) { + if (err) throw err; + + // `results` is an array with one element for every statement in the query: + console.log(results[0]); // [{1: 1}] + console.log(results[1]); // [{2: 2}] +}); +``` + +Additionally you can also stream the results of multiple statement queries: + +```js +var query = connection.query('SELECT 1; SELECT 2'); + +query + .on('fields', function(fields, index) { + // the fields for the result rows that follow + }) + .on('result', function(row, index) { + // index refers to the statement this result belongs to (starts at 0) + }); +``` + +If one of the statements in your query causes an error, the resulting Error +object contains a `err.index` property which tells you which statement caused +it. MySQL will also stop executing any remaining statements when an error +occurs. + +Please note that the interface for streaming multiple statement queries is +experimental and I am looking forward to feedback on it. + +## Stored procedures + +You can call stored procedures from your queries as with any other mysql driver. +If the stored procedure produces several result sets, they are exposed to you +the same way as the results for multiple statement queries. + +## Joins with overlapping column names + +When executing joins, you are likely to get result sets with overlapping column +names. + +By default, node-mysql will overwrite colliding column names in the +order the columns are received from MySQL, causing some of the received values +to be unavailable. + +However, you can also specify that you want your columns to be nested below +the table name like this: + +```js +var options = {sql: '...', nestTables: true}; +connection.query(options, function(err, results) { + /* results will be an array like this now: + [{ + table1: { + fieldA: '...', + fieldB: '...', + }, + table2: { + fieldA: '...', + fieldB: '...', + }, + }, ...] + */ +}); +``` + +Or use a string separator to have your results merged. + +```js +var options = {sql: '...', nestTables: '_'}; +connection.query(options, function(err, results) { + /* results will be an array like this now: + [{ + table1_fieldA: '...', + table1_fieldB: '...', + table2_fieldA: '...', + table2_fieldB: '...', + }, ...] + */ +}); +``` + +## Transactions + +Simple transaction support is available at the connection level: + +```js +connection.beginTransaction(function(err) { + if (err) { throw err; } + connection.query('INSERT INTO posts SET title=?', title, function(err, result) { + if (err) { + connection.rollback(function() { + throw err; + }); + } + + var log = 'Post ' + result.insertId + ' added'; + + connection.query('INSERT INTO log SET data=?', log, function(err, result) { + if (err) { + connection.rollback(function() { + throw err; + }); + } + connection.commit(function(err) { + if (err) { + connection.rollback(function() { + throw err; + }); + } + console.log('success!'); + }); + }); + }); +}); +``` +Please note that beginTransaction(), commit() and rollback() are simply convenience +functions that execute the START TRANSACTION, COMMIT, and ROLLBACK commands respectively. +It is important to understand that many commands in MySQL can cause an implicit commit, +as described [in the MySQL documentation](http://dev.mysql.com/doc/refman/5.5/en/implicit-commit.html) + +## Timeouts + +Every operation takes an optional inactivity timeout option. This allows you to +specify appropriate timeouts for operations. It is important to note that these +timeouts are not part of the MySQL protocol, and rather timeout operations through +the client. This means that when a timeout is reached, the connection it occurred +on will be destroyed and no further operations can be performed. + +```js +// Kill query after 60s +connection.query({sql: 'SELECT COUNT(*) AS count FROM big_table', timeout: 60000}, function (err, rows) { + if (err && err.code === 'PROTOCOL_SEQUENCE_TIMEOUT') { + throw new Error('too long to count table rows!'); + } + + if (err) { + throw err; + } + + console.log(rows[0].count + ' rows'); +}); +``` + +## Error handling + +This module comes with a consistent approach to error handling that you should +review carefully in order to write solid applications. + +All errors created by this module are instances of the JavaScript [Error][] +object. Additionally they come with two properties: + +* `err.code`: Either a [MySQL server error][] (e.g. + `'ER_ACCESS_DENIED_ERROR'`), a node.js error (e.g. `'ECONNREFUSED'`) or an + internal error (e.g. `'PROTOCOL_CONNECTION_LOST'`). +* `err.fatal`: Boolean, indicating if this error is terminal to the connection + object. + +[Error]: https://developer.mozilla.org/en/JavaScript/Reference/Global_Objects/Error +[MySQL server error]: http://dev.mysql.com/doc/refman/5.5/en/error-messages-server.html + +Fatal errors are propagated to *all* pending callbacks. In the example below, a +fatal error is triggered by trying to connect to an invalid port. Therefore the +error object is propagated to both pending callbacks: + +```js +var connection = require('mysql').createConnection({ + port: 84943, // WRONG PORT +}); + +connection.connect(function(err) { + console.log(err.code); // 'ECONNREFUSED' + console.log(err.fatal); // true +}); + +connection.query('SELECT 1', function(err) { + console.log(err.code); // 'ECONNREFUSED' + console.log(err.fatal); // true +}); +``` + +Normal errors however are only delegated to the callback they belong to. So in +the example below, only the first callback receives an error, the second query +works as expected: + +```js +connection.query('USE name_of_db_that_does_not_exist', function(err, rows) { + console.log(err.code); // 'ER_BAD_DB_ERROR' +}); + +connection.query('SELECT 1', function(err, rows) { + console.log(err); // null + console.log(rows.length); // 1 +}); +``` + +Last but not least: If a fatal errors occurs and there are no pending +callbacks, or a normal error occurs which has no callback belonging to it, the +error is emitted as an `'error'` event on the connection object. This is +demonstrated in the example below: + +```js +connection.on('error', function(err) { + console.log(err.code); // 'ER_BAD_DB_ERROR' +}); + +connection.query('USE name_of_db_that_does_not_exist'); +``` + +Note: `'error'` are special in node. If they occur without an attached +listener, a stack trace is printed and your process is killed. + +**tl;dr:** This module does not want you to deal with silent failures. You +should always provide callbacks to your method calls. If you want to ignore +this advice and suppress unhandled errors, you can do this: + +```js +// I am Chuck Norris: +connection.on('error', function() {}); +``` + +## Exception Safety + +This module is exception safe. That means you can continue to use it, even if +one of your callback functions throws an error which you're catching using +'uncaughtException' or a domain. + +## Type casting + +For your convenience, this driver will cast mysql types into native JavaScript +types by default. The following mappings exist: + +### Number + +* TINYINT +* SMALLINT +* INT +* MEDIUMINT +* YEAR +* FLOAT +* DOUBLE + +### Date + +* TIMESTAMP +* DATE +* DATETIME + +### Buffer + +* TINYBLOB +* MEDIUMBLOB +* LONGBLOB +* BLOB +* BINARY +* VARBINARY +* BIT (last byte will be filled with 0 bits as necessary) + +### String + +* CHAR +* VARCHAR +* TINYTEXT +* MEDIUMTEXT +* LONGTEXT +* TEXT +* ENUM +* SET +* DECIMAL (may exceed float precision) +* BIGINT (may exceed float precision) +* TIME (could be mapped to Date, but what date would be set?) +* GEOMETRY (never used those, get in touch if you do) + +It is not recommended (and may go away / change in the future) to disable type +casting, but you can currently do so on either the connection: + +```js +var connection = require('mysql').createConnection({typeCast: false}); +``` + +Or on the query level: + +```js +var options = {sql: '...', typeCast: false}; +var query = connection.query(options, function(err, results) { + +}); +``` + +You can also pass a function and handle type casting yourself. You're given some +column information like database, table and name and also type and length. If you +just want to apply a custom type casting to a specific type you can do it and then +fallback to the default. Here's an example of converting `TINYINT(1)` to boolean: + +```js +connection.query({ + sql: '...', + typeCast: function (field, next) { + if (field.type == 'TINY' && field.length == 1) { + return (field.string() == '1'); // 1 = true, 0 = false + } + return next(); + } +}); +``` +__WARNING: YOU MUST INVOKE the parser using one of these three field functions in your custom typeCast callback. They can only be called once.( see #539 for discussion)__ + +``` +field.string() +field.buffer() +field.geometry() +``` +are aliases for +``` +parser.parseLengthCodedString() +parser.parseLengthCodedBuffer() +parser.parseGeometryValue() +``` +__You can find which field function you need to use by looking at: [RowDataPacket.prototype._typeCast](https://github.com/felixge/node-mysql/blob/master/lib/protocol/packets/RowDataPacket.js#L41)__ + + +## Connection Flags + +If, for any reason, you would like to change the default connection flags, you +can use the connection option `flags`. Pass a string with a comma separated list +of items to add to the default flags. If you don't want a default flag to be used +prepend the flag with a minus sign. To add a flag that is not in the default list, +just write the flag name, or prefix it with a plus (case insensitive). + +**Please note that some available flags that are not not supported (e.g.: Compression), +are still not allowed to be specified.** + +### Example + +The next example blacklists FOUND_ROWS flag from default connection flags. + +```js +var connection = mysql.createConnection("mysql://localhost/test?flags=-FOUND_ROWS"); +``` + +### Default Flags + +The following flags are sent by default on a new connection: + +- `CONNECT_WITH_DB` - Ability to specify the database on connection. +- `FOUND_ROWS` - Send the found rows instead of the affected rows as `affectedRows`. +- `IGNORE_SIGPIPE` - Old; no effect. +- `IGNORE_SPACE` - Let the parser ignore spaces before the `(` in queries. +- `LOCAL_FILES` - Can use `LOAD DATA LOCAL`. +- `LONG_FLAG` +- `LONG_PASSWORD` - Use the improved version of Old Password Authentication. +- `MULTI_RESULTS` - Can handle multiple resultsets for COM_QUERY. +- `ODBC` Old; no effect. +- `PROTOCOL_41` - Uses the 4.1 protocol. +- `PS_MULTI_RESULTS` - Can handle multiple resultsets for COM_STMT_EXECUTE. +- `RESERVED` - Old flag for the 4.1 protocol. +- `SECURE_CONNECTION` - Support native 4.1 authentication. +- `TRANSACTIONS` - Asks for the transaction status flags. + +In addition, the following flag will be sent if the option `multipleStatements` +is set to `true`: + +- `MULTI_STATEMENTS` - The client may send multiple statement per query or + statement prepare. + +### Other Available Flags + +There are other flags available. They may or may not function, but are still +available to specify. + +- COMPRESS +- INTERACTIVE +- NO_SCHEMA +- PLUGIN_AUTH +- REMEMBER_OPTIONS +- SSL +- SSL_VERIFY_SERVER_CERT + +## Debugging and reporting problems + +If you are running into problems, one thing that may help is enabling the +`debug` mode for the connection: + +```js +var connection = mysql.createConnection({debug: true}); +``` + +This will print all incoming and outgoing packets on stdout. You can also restrict debugging to +packet types by passing an array of types to debug: + +```js +var connection = mysql.createConnection({debug: ['ComQueryPacket', 'RowDataPacket']}); +``` + +to restrict debugging to the query and data packets. + +If that does not help, feel free to open a GitHub issue. A good GitHub issue +will have: + +* The minimal amount of code required to reproduce the problem (if possible) +* As much debugging output and information about your environment (mysql + version, node version, os, etc.) as you can gather. + +## Running tests + +The test suite is split into two parts: unit tests and integration tests. +The unit tests run on any machine while the integration tests require a +MySQL server instance to be setup. + +### Running unit tests + +```sh +$ FILTER=unit npm test +``` + +### Running integration tests + +Set the environment variables `MYSQL_DATABASE`, `MYSQL_HOST`, `MYSQL_PORT`, +`MYSQL_USER` and `MYSQL_PASSWORD`. Then run `npm test`. + +For example, if you have an installation of mysql running on localhost:3306 +and no password set for the `root` user, run: + +```sh +$ mysql -u root -e "CREATE DATABASE IF NOT EXISTS node_mysql_test" +$ MYSQL_HOST=localhost MYSQL_PORT=3306 MYSQL_DATABASE=node_mysql_test MYSQL_USER=root MYSQL_PASSWORD= FILTER=integration npm test +``` + +## Todo + +* Prepared statements +* Support for encodings other than UTF-8 / ASCII + +[npm-image]: https://img.shields.io/npm/v/mysql.svg?style=flat +[npm-url]: https://npmjs.org/package/mysql +[node-version-image]: https://img.shields.io/badge/node.js-%3E%3D_0.6-brightgreen.svg?style=flat +[node-version-url]: http://nodejs.org/download/ +[travis-image]: https://img.shields.io/travis/felixge/node-mysql.svg?style=flat +[travis-url]: https://travis-ci.org/felixge/node-mysql +[coveralls-image]: https://img.shields.io/coveralls/felixge/node-mysql.svg?style=flat +[coveralls-url]: https://coveralls.io/r/felixge/node-mysql?branch=master +[downloads-image]: https://img.shields.io/npm/dm/mysql.svg?style=flat +[downloads-url]: https://npmjs.org/package/mysql diff --git a/node_modules/mysql/fixtures/ssl-profiles.json b/node_modules/mysql/fixtures/ssl-profiles.json new file mode 100644 index 0000000..0629d5e --- /dev/null +++ b/node_modules/mysql/fixtures/ssl-profiles.json @@ -0,0 +1,5 @@ +{ + "Amazon RDS": { + "ca": "-----BEGIN CERTIFICATE-----\nMIIDQzCCAqygAwIBAgIJAOd1tlfiGoEoMA0GCSqGSIb3DQEBBQUAMHUxCzAJBgNV\nBAYTAlVTMRMwEQYDVQQIEwpXYXNoaW5ndG9uMRAwDgYDVQQHEwdTZWF0dGxlMRMw\nEQYDVQQKEwpBbWF6b24uY29tMQwwCgYDVQQLEwNSRFMxHDAaBgNVBAMTE2F3cy5h\nbWF6b24uY29tL3Jkcy8wHhcNMTAwNDA1MjI0NDMxWhcNMTUwNDA0MjI0NDMxWjB1\nMQswCQYDVQQGEwJVUzETMBEGA1UECBMKV2FzaGluZ3RvbjEQMA4GA1UEBxMHU2Vh\ndHRsZTETMBEGA1UEChMKQW1hem9uLmNvbTEMMAoGA1UECxMDUkRTMRwwGgYDVQQD\nExNhd3MuYW1hem9uLmNvbS9yZHMvMIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKB\ngQDKhXGU7tizxUR5WaFoMTFcxNxa05PEjZaIOEN5ctkWrqYSRov0/nOMoZjqk8bC\nmed9vPFoQGD0OTakPs0jVe3wwmR735hyVwmKIPPsGlaBYj1O6llIpZeQVyupNx56\nUzqtiLaDzh1KcmfqP3qP2dInzBfJQKjiRudo1FWnpPt33QIDAQABo4HaMIHXMB0G\nA1UdDgQWBBT/H3x+cqSkR/ePSIinPtc4yWKe3DCBpwYDVR0jBIGfMIGcgBT/H3x+\ncqSkR/ePSIinPtc4yWKe3KF5pHcwdTELMAkGA1UEBhMCVVMxEzARBgNVBAgTCldh\nc2hpbmd0b24xEDAOBgNVBAcTB1NlYXR0bGUxEzARBgNVBAoTCkFtYXpvbi5jb20x\nDDAKBgNVBAsTA1JEUzEcMBoGA1UEAxMTYXdzLmFtYXpvbi5jb20vcmRzL4IJAOd1\ntlfiGoEoMAwGA1UdEwQFMAMBAf8wDQYJKoZIhvcNAQEFBQADgYEAvguZy/BDT66x\nGfgnJlyQwnFSeVLQm9u/FIvz4huGjbq9dqnD6h/Gm56QPFdyMEyDiZWaqY6V08lY\nLTBNb4kcIc9/6pc0/ojKciP5QJRm6OiZ4vgG05nF4fYjhU7WClUx7cxq1fKjNc2J\nUCmmYqgiVkAGWRETVo+byOSDZ4swb10=\n-----END CERTIFICATE-----\n" + } +} diff --git a/node_modules/mysql/index.js b/node_modules/mysql/index.js new file mode 100644 index 0000000..523eb53 --- /dev/null +++ b/node_modules/mysql/index.js @@ -0,0 +1,26 @@ +var Connection = require('./lib/Connection'); +var ConnectionConfig = require('./lib/ConnectionConfig'); +var Types = require('./lib/protocol/constants/types'); +var SqlString = require('./lib/protocol/SqlString'); +var Pool = require('./lib/Pool'); +var PoolConfig = require('./lib/PoolConfig'); +var PoolCluster = require('./lib/PoolCluster'); + +exports.createConnection = function(config) { + return new Connection({config: new ConnectionConfig(config)}); +}; + +exports.createPool = function(config) { + return new Pool({config: new PoolConfig(config)}); +}; + +exports.createPoolCluster = function(config) { + return new PoolCluster(config); +}; + +exports.createQuery = Connection.createQuery; + +exports.Types = Types; +exports.escape = SqlString.escape; +exports.escapeId = SqlString.escapeId; +exports.format = SqlString.format; diff --git a/node_modules/mysql/lib/Connection.js b/node_modules/mysql/lib/Connection.js new file mode 100644 index 0000000..600cbdd --- /dev/null +++ b/node_modules/mysql/lib/Connection.js @@ -0,0 +1,389 @@ +var Crypto = require('crypto'); +var Net = require('net'); +var tls = require('tls'); +var ConnectionConfig = require('./ConnectionConfig'); +var Protocol = require('./protocol/Protocol'); +var SqlString = require('./protocol/SqlString'); +var Query = require('./protocol/sequences/Query'); +var EventEmitter = require('events').EventEmitter; +var Util = require('util'); + +module.exports = Connection; +Util.inherits(Connection, EventEmitter); +function Connection(options) { + EventEmitter.call(this); + + this.config = options.config; + + this._socket = options.socket; + this._protocol = new Protocol({config: this.config, connection: this}); + this._connectCalled = false; + this.state = "disconnected"; + this.threadId = null; +} + +function bindToCurrentDomain(callback) { + if (!callback) return; + + var domain = process.domain; + + return domain + ? domain.bind(callback) + : callback; +} + +Connection.createQuery = function(sql, values, cb) { + if (sql instanceof Query) { + return sql; + } + + var options = {}; + + if (typeof sql === 'object') { + // query(options, cb) + options = sql; + if (typeof values === 'function') { + cb = values; + } else if (typeof values !== 'undefined') { + options.values = values; + } + } else if (typeof values === 'function') { + // query(sql, cb) + cb = values; + options.sql = sql; + options.values = undefined; + } else { + // query(sql, values, cb) + options.sql = sql; + options.values = values; + } + return new Query(options, bindToCurrentDomain(cb)); +}; + +Connection.prototype.connect = function connect(options, callback) { + if (!callback && typeof options === 'function') { + callback = options; + options = {}; + } + + if (!this._connectCalled) { + this._connectCalled = true; + + // Connect either via a UNIX domain socket or a TCP socket. + this._socket = (this.config.socketPath) + ? Net.createConnection(this.config.socketPath) + : Net.createConnection(this.config.port, this.config.host); + + var connection = this; + this._protocol.on('data', function(data) { + connection._socket.write(data); + }); + this._socket.on('data', function(data) { + connection._protocol.write(data); + }); + this._protocol.on('end', function() { + connection._socket.end() + }); + this._socket.on('end', function(err) { + connection._protocol.end(); + }); + + this._socket.on('error', this._handleNetworkError.bind(this)); + this._socket.on('connect', this._handleProtocolConnect.bind(this)); + this._protocol.on('handshake', this._handleProtocolHandshake.bind(this)); + this._protocol.on('unhandledError', this._handleProtocolError.bind(this)); + this._protocol.on('drain', this._handleProtocolDrain.bind(this)); + this._protocol.on('end', this._handleProtocolEnd.bind(this)); + this._protocol.on('enqueue', this._handleProtocolEnqueue.bind(this)); + + if (this.config.connectTimeout) { + var handleConnectTimeout = this._handleConnectTimeout.bind(this); + + this._socket.setTimeout(this.config.connectTimeout, handleConnectTimeout); + this._socket.once('connect', function() { + this.setTimeout(0, handleConnectTimeout); + }); + } + } + + this._protocol.handshake(options, bindToCurrentDomain(callback)); +}; + +Connection.prototype.changeUser = function changeUser(options, callback) { + if (!callback && typeof options === 'function') { + callback = options; + options = {}; + } + + this._implyConnect(); + + var charsetNumber = (options.charset) + ? ConnectionConfig.getCharsetNumber(options.charset) + : this.config.charsetNumber; + + return this._protocol.changeUser({ + user : options.user || this.config.user, + password : options.password || this.config.password, + database : options.database || this.config.database, + timeout : options.timeout, + charsetNumber : charsetNumber, + currentConfig : this.config + }, bindToCurrentDomain(callback)); +}; + +Connection.prototype.beginTransaction = function beginTransaction(options, callback) { + if (!callback && typeof options === 'function') { + callback = options; + options = {}; + } + + options = options || {}; + options.sql = 'START TRANSACTION'; + options.values = null; + + return this.query(options, callback); +}; + +Connection.prototype.commit = function commit(options, callback) { + if (!callback && typeof options === 'function') { + callback = options; + options = {}; + } + + options = options || {}; + options.sql = 'COMMIT'; + options.values = null; + + return this.query(options, callback); +}; + +Connection.prototype.rollback = function rollback(options, callback) { + if (!callback && typeof options === 'function') { + callback = options; + options = {}; + } + + options = options || {}; + options.sql = 'ROLLBACK'; + options.values = null; + + return this.query(options, callback); +}; + +Connection.prototype.query = function(sql, values, cb) { + this._implyConnect(); + + var query = Connection.createQuery(sql, values, cb); + query._connection = this; + + if (!(typeof sql == 'object' && 'typeCast' in sql)) { + query.typeCast = this.config.typeCast; + } + + query.sql = this.format(query.sql, query.values); + + return this._protocol._enqueue(query); +}; + +Connection.prototype.ping = function ping(options, callback) { + if (!callback && typeof options === 'function') { + callback = options; + options = {}; + } + + this._implyConnect(); + this._protocol.ping(options, bindToCurrentDomain(callback)); +}; + +Connection.prototype.statistics = function statistics(options, callback) { + if (!callback && typeof options === 'function') { + callback = options; + options = {}; + } + + this._implyConnect(); + this._protocol.stats(options, bindToCurrentDomain(callback)); +}; + +Connection.prototype.end = function end(options, callback) { + if (!callback && typeof options === 'function') { + callback = options; + options = {}; + } + + this._implyConnect(); + this._protocol.quit(options, bindToCurrentDomain(callback)); +}; + +Connection.prototype.destroy = function() { + this.state = "disconnected"; + this._implyConnect(); + this._socket.destroy(); + this._protocol.destroy(); +}; + +Connection.prototype.pause = function() { + this._socket.pause(); + this._protocol.pause(); +}; + +Connection.prototype.resume = function() { + this._socket.resume(); + this._protocol.resume(); +}; + +Connection.prototype.escape = function(value) { + return SqlString.escape(value, false, this.config.timezone); +}; + +Connection.prototype.escapeId = function escapeId(value) { + return SqlString.escapeId(value, false); +}; + +Connection.prototype.format = function(sql, values) { + if (typeof this.config.queryFormat == "function") { + return this.config.queryFormat.call(this, sql, values, this.config.timezone); + } + return SqlString.format(sql, values, this.config.stringifyObjects, this.config.timezone); +}; + +if (tls.TLSSocket) { + // 0.11+ environment + Connection.prototype._startTLS = function _startTLS(onSecure) { + var secureContext = tls.createSecureContext({ + key : this.config.ssl.key, + cert : this.config.ssl.cert, + passphrase : this.config.ssl.passphrase, + ca : this.config.ssl.ca + }); + + // "unpipe" + this._socket.removeAllListeners('data'); + this._protocol.removeAllListeners('data'); + + // socket <-> encrypted + var rejectUnauthorized = this.config.ssl.rejectUnauthorized; + var secureSocket = new tls.TLSSocket(this._socket, { + rejectUnauthorized : rejectUnauthorized, + requestCert : true, + secureContext : secureContext, + isServer : false + }); + + // cleartext <-> protocol + secureSocket.pipe(this._protocol); + this._protocol.on('data', function(data) { + secureSocket.write(data); + }); + + secureSocket.on('secure', function() { + onSecure(rejectUnauthorized ? this.ssl.verifyError() : null); + }); + + // start TLS communications + secureSocket._start(); + }; +} else { + // pre-0.11 environment + Connection.prototype._startTLS = function _startTLS(onSecure) { + // before TLS: + // _socket <-> _protocol + // after: + // _socket <-> securePair.encrypted <-> securePair.cleartext <-> _protocol + + var credentials = Crypto.createCredentials({ + key : this.config.ssl.key, + cert : this.config.ssl.cert, + passphrase : this.config.ssl.passphrase, + ca : this.config.ssl.ca + }); + + var rejectUnauthorized = this.config.ssl.rejectUnauthorized; + var securePair = tls.createSecurePair(credentials, false, true, rejectUnauthorized); + + // "unpipe" + this._socket.removeAllListeners('data'); + this._protocol.removeAllListeners('data'); + + // socket <-> encrypted + securePair.encrypted.pipe(this._socket); + this._socket.on('data', function(data) { + securePair.encrypted.write(data); + }); + + // cleartext <-> protocol + securePair.cleartext.pipe(this._protocol); + this._protocol.on('data', function(data) { + securePair.cleartext.write(data); + }); + + securePair.on('secure', function() { + if (!rejectUnauthorized) { + onSecure(); + return; + } + + var verifyError = this.ssl.verifyError(); + var err = verifyError; + + // node.js 0.6 support + if (typeof err === 'string') { + err = new Error(verifyError); + err.code = verifyError; + } + + onSecure(err); + }); + }; +} + +Connection.prototype._handleConnectTimeout = function() { + if (this._socket) { + this._socket.setTimeout(0); + this._socket.destroy(); + } + + var err = new Error('connect ETIMEDOUT'); + err.errorno = 'ETIMEDOUT'; + err.code = 'ETIMEDOUT'; + err.syscall = 'connect'; + + this._handleNetworkError(err); +}; + +Connection.prototype._handleNetworkError = function(err) { + this._protocol.handleNetworkError(err); +}; + +Connection.prototype._handleProtocolError = function(err) { + this.state = "protocol_error"; + this.emit('error', err); +}; + +Connection.prototype._handleProtocolDrain = function() { + this.emit('drain'); +}; + +Connection.prototype._handleProtocolConnect = function() { + this.state = "connected"; +}; + +Connection.prototype._handleProtocolHandshake = function _handleProtocolHandshake(packet) { + this.state = "authenticated"; + this.threadId = packet.threadId; +}; + +Connection.prototype._handleProtocolEnd = function(err) { + this.state = "disconnected"; + this.emit('end', err); +}; + +Connection.prototype._handleProtocolEnqueue = function _handleProtocolEnqueue(sequence) { + this.emit('enqueue', sequence); +}; + +Connection.prototype._implyConnect = function() { + if (!this._connectCalled) { + this.connect(); + } +}; diff --git a/node_modules/mysql/lib/ConnectionConfig.js b/node_modules/mysql/lib/ConnectionConfig.js new file mode 100644 index 0000000..294a538 --- /dev/null +++ b/node_modules/mysql/lib/ConnectionConfig.js @@ -0,0 +1,201 @@ +var urlParse = require('url').parse; +var ClientConstants = require('./protocol/constants/client'); +var Charsets = require('./protocol/constants/charsets'); +var SSLProfiles = null; + +module.exports = ConnectionConfig; +function ConnectionConfig(options) { + if (typeof options === 'string') { + options = ConnectionConfig.parseUrl(options); + } + + this.host = options.host || 'localhost'; + this.port = options.port || 3306; + this.localAddress = options.localAddress; + this.socketPath = options.socketPath; + this.user = options.user || undefined; + this.password = options.password || undefined; + this.database = options.database; + this.connectTimeout = (options.connectTimeout === undefined) + ? (10 * 1000) + : options.connectTimeout; + this.insecureAuth = options.insecureAuth || false; + this.supportBigNumbers = options.supportBigNumbers || false; + this.bigNumberStrings = options.bigNumberStrings || false; + this.dateStrings = options.dateStrings || false; + this.debug = options.debug; + this.trace = options.trace !== false; + this.stringifyObjects = options.stringifyObjects || false; + this.timezone = options.timezone || 'local'; + this.flags = options.flags || ''; + this.queryFormat = options.queryFormat; + this.pool = options.pool || undefined; + this.ssl = (typeof options.ssl === 'string') + ? ConnectionConfig.getSSLProfile(options.ssl) + : (options.ssl || false); + this.multipleStatements = options.multipleStatements || false; + this.typeCast = (options.typeCast === undefined) + ? true + : options.typeCast; + + if (this.timezone[0] == " ") { + // "+" is a url encoded char for space so it + // gets translated to space when giving a + // connection string.. + this.timezone = "+" + this.timezone.substr(1); + } + + if (this.ssl) { + // Default rejectUnauthorized to true + this.ssl.rejectUnauthorized = this.ssl.rejectUnauthorized !== false; + } + + this.maxPacketSize = 0; + this.charsetNumber = (options.charset) + ? ConnectionConfig.getCharsetNumber(options.charset) + : options.charsetNumber||Charsets.UTF8_GENERAL_CI; + + // Set the client flags + var defaultFlags = ConnectionConfig.getDefaultFlags(options); + this.clientFlags = ConnectionConfig.mergeFlags(defaultFlags, options.flags) +} + +ConnectionConfig.mergeFlags = function mergeFlags(defaultFlags, userFlags) { + var allFlags = ConnectionConfig.parseFlagList(defaultFlags); + var newFlags = ConnectionConfig.parseFlagList(userFlags); + + // Merge the new flags + for (var flag in newFlags) { + if (allFlags[flag] !== false) { + allFlags[flag] = newFlags[flag]; + } + } + + // Build flags + var flags = 0x0; + for (var flag in allFlags) { + if (allFlags[flag]) { + // TODO: Throw here on some future release + flags |= ClientConstants['CLIENT_' + flag] || 0x0; + } + } + + return flags; +}; + +ConnectionConfig.getCharsetNumber = function getCharsetNumber(charset) { + var num = Charsets[charset.toUpperCase()]; + + if (num === undefined) { + throw new TypeError('Unknown charset \'' + charset + '\''); + } + + return num; +}; + +ConnectionConfig.getDefaultFlags = function getDefaultFlags(options) { + var defaultFlags = [ + '-COMPRESS', // Compression protocol *NOT* supported + '-CONNECT_ATTRS', // Does *NOT* send connection attributes in Protocol::HandshakeResponse41 + '+CONNECT_WITH_DB', // One can specify db on connect in Handshake Response Packet + '+FOUND_ROWS', // Send found rows instead of affected rows + '+IGNORE_SIGPIPE', // Don't issue SIGPIPE if network failures + '+IGNORE_SPACE', // Let the parser ignore spaces before '(' + '+LOCAL_FILES', // Can use LOAD DATA LOCAL + '+LONG_FLAG', // Longer flags in Protocol::ColumnDefinition320 + '+LONG_PASSWORD', // Use the improved version of Old Password Authentication + '+MULTI_RESULTS', // Can handle multiple resultsets for COM_QUERY + '+ODBC', // Special handling of ODBC behaviour + '-PLUGIN_AUTH', // Does *NOT* support auth plugins + '+PROTOCOL_41', // Uses the 4.1 protocol + '+PS_MULTI_RESULTS', // Can handle multiple resultsets for COM_STMT_EXECUTE + '+RESERVED', // Unused + '+SECURE_CONNECTION', // Supports Authentication::Native41 + '+TRANSACTIONS' // Expects status flags + ]; + + if (options && options.multipleStatements) { + // May send multiple statements per COM_QUERY and COM_STMT_PREPARE + defaultFlags.push('+MULTI_STATEMENTS'); + } + + return defaultFlags; +}; + +ConnectionConfig.getSSLProfile = function getSSLProfile(name) { + if (!SSLProfiles) { + SSLProfiles = require('./../fixtures/ssl-profiles.json'); + } + + var ssl = SSLProfiles[name]; + + if (ssl === undefined) { + throw new TypeError('Unknown SSL profile \'' + name + '\''); + } + + return ssl; +}; + +ConnectionConfig.parseFlagList = function parseFlagList(flagList) { + var allFlags = Object.create(null); + + if (!flagList) { + return allFlags; + } + + var flags = !Array.isArray(flagList) + ? String(flagList || '').toUpperCase().split(/\s*,+\s*/) + : flagList; + + for (var i = 0; i < flags.length; i++) { + var flag = flags[i]; + var offset = 1; + var state = flag[0]; + + if (state === undefined) { + // TODO: throw here on some future release + continue; + } + + if (state !== '-' && state !== '+') { + offset = 0; + state = '+'; + } + + allFlags[flag.substr(offset)] = state === '+'; + } + + return allFlags; +}; + +ConnectionConfig.parseUrl = function(url) { + url = urlParse(url, true); + + var options = { + host : url.hostname, + port : url.port, + database : url.pathname.substr(1), + }; + + if (url.auth) { + var auth = url.auth.split(':'); + options.user = auth[0]; + options.password = auth[1]; + } + + if (url.query) { + for (var key in url.query) { + var value = url.query[key]; + + try { + // Try to parse this as a JSON expression first + options[key] = JSON.parse(value); + } catch (err) { + // Otherwise assume it is a plain string + options[key] = value; + } + } + } + + return options; +}; diff --git a/node_modules/mysql/lib/Pool.js b/node_modules/mysql/lib/Pool.js new file mode 100644 index 0000000..57c4b3d --- /dev/null +++ b/node_modules/mysql/lib/Pool.js @@ -0,0 +1,243 @@ +var mysql = require('../'); +var Connection = require('./Connection'); +var EventEmitter = require('events').EventEmitter; +var Util = require('util'); +var PoolConnection = require('./PoolConnection'); + +module.exports = Pool; + +Util.inherits(Pool, EventEmitter); +function Pool(options) { + EventEmitter.call(this); + this.config = options.config; + this.config.connectionConfig.pool = this; + + this._allConnections = []; + this._freeConnections = []; + this._connectionQueue = []; + this._closed = false; +} + +Pool.prototype.getConnection = function (cb) { + + if (this._closed) { + return process.nextTick(function(){ + return cb(new Error('Pool is closed.')); + }); + } + + var connection; + + if (this._freeConnections.length > 0) { + connection = this._freeConnections.shift(); + + return this.acquireConnection(connection, cb); + } + + if (this.config.connectionLimit === 0 || this._allConnections.length < this.config.connectionLimit) { + connection = new PoolConnection(this, { config: this.config.newConnectionConfig() }); + + this._allConnections.push(connection); + + return connection.connect({timeout: this.config.acquireTimeout}, function (err) { + if (this._closed) { + return cb(new Error('Pool is closed.')); + } + if (err) { + return cb(err); + } + + this.emit('connection', connection); + return cb(null, connection); + }.bind(this)); + } + + if (!this.config.waitForConnections) { + return process.nextTick(function(){ + return cb(new Error('No connections available.')); + }); + } + + this._enqueueCallback(cb); +}; + +Pool.prototype.acquireConnection = function acquireConnection(connection, cb) { + if (connection._pool !== this) { + throw new Error('Connection acquired from wrong pool.'); + } + + var pool = this; + + connection._pool = null; + connection.ping({timeout: this.config.acquireTimeout}, function(err) { + if (!err) { + connection._pool = pool; + cb(null, connection); + return; + } + + connection.destroy(); + pool._connectionQueue.unshift(cb); + pool._removeConnection(connection); + }); +}; + +Pool.prototype.releaseConnection = function releaseConnection(connection) { + var cb; + + if (connection._pool) { + if (connection._pool !== this) { + throw new Error('Connection released to wrong pool'); + } + + if (connection._purge) { + // purge connection from pool + this._purgeConnection(connection); + return; + } else if (this._freeConnections.indexOf(connection) !== -1) { + // connection already in free connection pool + // this won't catch all double-release cases + throw new Error('Connection already released'); + } else { + // add connection to end of free queue + this._freeConnections.push(connection); + } + } + + while (this._closed && this._connectionQueue.length) { + // empty the connection queue + cb = this._connectionQueue.shift(); + + process.nextTick(cb.bind(null, new Error('Pool is closed.'))); + } + + if (this._connectionQueue.length) { + cb = this._connectionQueue.shift(); + + this.getConnection(cb); + } +}; + +Pool.prototype.end = function (cb) { + this._closed = true; + + if (typeof cb != "function") { + cb = function (err) { + if (err) throw err; + }; + } + + var calledBack = false; + var closedConnections = 0; + var connection; + + var endCB = function(err) { + if (calledBack) { + return; + } + + if (err || ++closedConnections >= this._allConnections.length) { + calledBack = true; + return cb(err); + } + }.bind(this); + + if (this._allConnections.length === 0) { + return process.nextTick(endCB); + } + + while (this._allConnections.length) { + connection = this._allConnections[0]; + connection._pool = null; + connection._realEnd(endCB); + this._removeConnection(connection); + } +}; + +Pool.prototype.query = function (sql, values, cb) { + var query = Connection.createQuery(sql, values, cb); + + if (!(typeof sql === 'object' && 'typeCast' in sql)) { + query.typeCast = this.config.connectionConfig.typeCast; + } + + if (this.config.connectionConfig.trace) { + // Long stack trace support + query._callSite = new Error; + } + + this.getConnection(function (err, conn) { + if (err) { + var cb = query._callback; + cb && cb(err); + return; + } + + // Release connection based off event + query.once('end', function() { + conn.release(); + }); + + conn.query(query); + }); + + return query; +}; + +Pool.prototype._enqueueCallback = function _enqueueCallback(callback) { + + if (this.config.queueLimit && this._connectionQueue.length >= this.config.queueLimit) { + process.nextTick(function () { + var err = new Error('Queue limit reached.'); + err.code = 'POOL_ENQUEUELIMIT'; + callback(err); + }); + return; + } + + // Bind to domain, as dequeue will likely occur in a different domain + var cb = process.domain + ? process.domain.bind(callback) + : callback; + + this._connectionQueue.push(cb); + this.emit('enqueue'); +}; + +Pool.prototype._purgeConnection = function _purgeConnection(connection) { + var pool = this; + + connection._realEnd(function(err) { + if (err) { + connection.destroy(); + } + + pool._removeConnection(connection); + }); +}; + +Pool.prototype._removeConnection = function(connection) { + var index; + + connection._pool = null; + + if ((index = this._allConnections.indexOf(connection)) !== -1) { + // Remove connection from all connections + this._allConnections.splice(index, 1); + } + + if ((index = this._freeConnections.indexOf(connection)) !== -1) { + // Remove connection from free connections + this._freeConnections.splice(index, 1); + } + + this.releaseConnection(connection); +}; + +Pool.prototype.escape = function(value) { + return mysql.escape(value, this.config.connectionConfig.stringifyObjects, this.config.connectionConfig.timezone); +}; + +Pool.prototype.escapeId = function escapeId(value) { + return mysql.escapeId(value, false); +}; diff --git a/node_modules/mysql/lib/PoolCluster.js b/node_modules/mysql/lib/PoolCluster.js new file mode 100644 index 0000000..e2af239 --- /dev/null +++ b/node_modules/mysql/lib/PoolCluster.js @@ -0,0 +1,256 @@ +var Pool = require('./Pool'); +var PoolConfig = require('./PoolConfig'); +var Util = require('util'); +var EventEmitter = require('events').EventEmitter; + +module.exports = PoolCluster; + +/** + * PoolCluster + */ +function PoolCluster(config) { + EventEmitter.call(this); + + config = config || {}; + this._canRetry = typeof config.canRetry === 'undefined' ? true : config.canRetry; + this._removeNodeErrorCount = config.removeNodeErrorCount || 5; + this._defaultSelector = config.defaultSelector || 'RR'; + + this._closed = false; + this._lastId = 0; + this._nodes = {}; + this._serviceableNodeIds = []; + this._namespaces = {}; + this._findCaches = {}; +} + +Util.inherits(PoolCluster, EventEmitter); + +PoolCluster.prototype.of = function(pattern, selector) { + pattern = pattern || '*'; + + selector = selector || this._defaultSelector; + selector = selector.toUpperCase(); + if (typeof Selector[selector] === 'undefined') { + selector = this._defaultSelector; + } + + var key = pattern + selector; + + if (typeof this._namespaces[key] === 'undefined') { + this._namespaces[key] = new PoolNamespace(this, pattern, selector); + } + + return this._namespaces[key]; +}; + +PoolCluster.prototype.add = function(id, config) { + if (typeof id === 'object') { + config = id; + id = 'CLUSTER::' + (++this._lastId); + } + + if (typeof this._nodes[id] === 'undefined') { + this._nodes[id] = { + id: id, + errorCount: 0, + pool: new Pool({config: new PoolConfig(config)}) + }; + + this._serviceableNodeIds.push(id); + + this._clearFindCaches(); + } +}; + +PoolCluster.prototype.getConnection = function(pattern, selector, cb) { + var namespace; + if (typeof pattern === 'function') { + cb = pattern; + namespace = this.of(); + } else { + if (typeof selector === 'function') { + cb = selector; + selector = this._defaultSelector; + } + + namespace = this.of(pattern, selector); + } + + namespace.getConnection(cb); +}; + +PoolCluster.prototype.end = function() { + if (this._closed) { + return; + } + + this._closed = true; + + for (var id in this._nodes) { + this._nodes[id].pool.end(); + } +}; + +PoolCluster.prototype._findNodeIds = function(pattern) { + if (typeof this._findCaches[pattern] !== 'undefined') { + return this._findCaches[pattern]; + } + + var foundNodeIds; + + if (pattern === '*') { // all + foundNodeIds = this._serviceableNodeIds; + } else if (this._serviceableNodeIds.indexOf(pattern) != -1) { // one + foundNodeIds = [pattern]; + } else if (pattern[pattern.length - 1] === '*') { + // wild matching + var keyword = pattern.substring(pattern.length - 1, 0); + + foundNodeIds = this._serviceableNodeIds.filter(function (id) { + return id.indexOf(keyword) === 0; + }); + } else { + foundNodeIds = []; + } + + this._findCaches[pattern] = foundNodeIds; + + return foundNodeIds; +}; + +PoolCluster.prototype._getNode = function(id) { + return this._nodes[id] || null; +}; + +PoolCluster.prototype._increaseErrorCount = function(node) { + if (++node.errorCount >= this._removeNodeErrorCount) { + var index = this._serviceableNodeIds.indexOf(node.id); + if (index !== -1) { + this._serviceableNodeIds.splice(index, 1); + delete this._nodes[node.id]; + + this._clearFindCaches(); + + node.pool.end(); + + this.emit('remove', node.id); + } + } +}; + +PoolCluster.prototype._decreaseErrorCount = function(node) { + if (node.errorCount > 0) { + --node.errorCount; + } +}; + +PoolCluster.prototype._getConnection = function(node, cb) { + var self = this; + + node.pool.getConnection(function (err, connection) { + if (err) { + self._increaseErrorCount(node); + cb(err); + return; + } else { + self._decreaseErrorCount(node); + } + + connection._clusterId = node.id; + + cb(null, connection); + }); +}; + +PoolCluster.prototype._clearFindCaches = function() { + this._findCaches = {}; +}; + +/** + * PoolNamespace + */ +function PoolNamespace(cluster, pattern, selector) { + this._cluster = cluster; + this._pattern = pattern; + this._selector = new Selector[selector](); +} + +PoolNamespace.prototype.getConnection = function(cb) { + var clusterNode = this._getClusterNode(); + var cluster = this._cluster; + var namespace = this; + + if (clusterNode === null) { + var err = new Error('Pool does not exist.') + err.code = 'POOL_NOEXIST'; + return cb(err); + } + + cluster._getConnection(clusterNode, function(err, connection) { + var retry = err && cluster._canRetry + && cluster._findNodeIds(namespace._pattern).length !== 0; + + if (retry) { + return namespace.getConnection(cb); + } + + if (err) { + return cb(err); + } + + cb(null, connection); + }); +}; + +PoolNamespace.prototype._getClusterNode = function _getClusterNode() { + var foundNodeIds = this._cluster._findNodeIds(this._pattern); + var nodeId; + + switch (foundNodeIds.length) { + case 0: + nodeId = null; + break; + case 1: + nodeId = foundNodeIds[0]; + break; + default: + nodeId = this._selector(foundNodeIds); + break; + } + + return nodeId !== null + ? this._cluster._getNode(nodeId) + : null; +}; + +/** + * Selector + */ +var Selector = {}; + +Selector.RR = function () { + var index = 0; + + return function(clusterIds) { + if (index >= clusterIds.length) { + index = 0; + } + + var clusterId = clusterIds[index++]; + + return clusterId; + }; +}; + +Selector.RANDOM = function () { + return function(clusterIds) { + return clusterIds[Math.floor(Math.random() * clusterIds.length)]; + }; +}; + +Selector.ORDER = function () { + return function(clusterIds) { + return clusterIds[0]; + }; +}; diff --git a/node_modules/mysql/lib/PoolConfig.js b/node_modules/mysql/lib/PoolConfig.js new file mode 100644 index 0000000..8c5017a --- /dev/null +++ b/node_modules/mysql/lib/PoolConfig.js @@ -0,0 +1,32 @@ + +var ConnectionConfig = require('./ConnectionConfig'); + +module.exports = PoolConfig; +function PoolConfig(options) { + if (typeof options === 'string') { + options = ConnectionConfig.parseUrl(options); + } + + this.acquireTimeout = (options.acquireTimeout === undefined) + ? 10 * 1000 + : Number(options.acquireTimeout); + this.connectionConfig = new ConnectionConfig(options); + this.waitForConnections = (options.waitForConnections === undefined) + ? true + : Boolean(options.waitForConnections); + this.connectionLimit = (options.connectionLimit === undefined) + ? 10 + : Number(options.connectionLimit); + this.queueLimit = (options.queueLimit === undefined) + ? 0 + : Number(options.queueLimit); +} + +PoolConfig.prototype.newConnectionConfig = function newConnectionConfig() { + var connectionConfig = new ConnectionConfig(this.connectionConfig); + + connectionConfig.clientFlags = this.connectionConfig.clientFlags; + connectionConfig.maxPacketSize = this.connectionConfig.maxPacketSize; + + return connectionConfig; +}; diff --git a/node_modules/mysql/lib/PoolConnection.js b/node_modules/mysql/lib/PoolConnection.js new file mode 100644 index 0000000..a99fdb0 --- /dev/null +++ b/node_modules/mysql/lib/PoolConnection.js @@ -0,0 +1,62 @@ +var inherits = require('util').inherits; +var Connection = require('./Connection') +var __changeUser = Connection.prototype.changeUser; + +module.exports = PoolConnection; +inherits(PoolConnection, Connection); + +function PoolConnection(pool, options) { + Connection.call(this, options); + this._pool = pool; + this._purge = false + + // When a fatal error occurs the connection's protocol ends, which will cause + // the connection to end as well, thus we only need to watch for the end event + // and we will be notified of disconnects. + this.on('end', this._removeFromPool); + this.on('error', this._removeFromPool); +} + +PoolConnection.prototype.changeUser = function changeUser(options, callback) { + this._purge = true; + + return __changeUser.apply(this, arguments); +}; + +PoolConnection.prototype.release = function release() { + var pool = this._pool; + + if (!pool || pool._closed) { + return; + } + + return pool.releaseConnection(this); +}; + +// TODO: Remove this when we are removing PoolConnection#end +PoolConnection.prototype._realEnd = Connection.prototype.end; + +PoolConnection.prototype.end = function () { + console.warn( 'Calling conn.end() to release a pooled connection is ' + + 'deprecated. In next version calling conn.end() will be ' + + 'restored to default conn.end() behavior. Use ' + + 'conn.release() instead.' + ); + this.release(); +}; + +PoolConnection.prototype.destroy = function () { + this._removeFromPool(this); + return Connection.prototype.destroy.apply(this, arguments); +}; + +PoolConnection.prototype._removeFromPool = function(connection) { + if (!this._pool || this._pool._closed) { + return; + } + + var pool = this._pool; + this._pool = null; + + pool._removeConnection(this); +}; diff --git a/node_modules/mysql/lib/protocol/Auth.js b/node_modules/mysql/lib/protocol/Auth.js new file mode 100644 index 0000000..edf2f25 --- /dev/null +++ b/node_modules/mysql/lib/protocol/Auth.js @@ -0,0 +1,165 @@ +var Buffer = require('buffer').Buffer; +var Crypto = require('crypto'); +var Auth = exports; + +function sha1(msg) { + var hash = Crypto.createHash('sha1'); + hash.update(msg, 'binary'); + return hash.digest('binary'); +} +Auth.sha1 = sha1; + +function xor(a, b) { + a = new Buffer(a, 'binary'); + b = new Buffer(b, 'binary'); + var result = new Buffer(a.length); + for (var i = 0; i < a.length; i++) { + result[i] = (a[i] ^ b[i]); + } + return result; +}; +Auth.xor = xor; + +Auth.token = function(password, scramble) { + if (!password) { + return new Buffer(0); + } + + // password must be in binary format, not utf8 + var stage1 = sha1((new Buffer(password, "utf8")).toString("binary")); + var stage2 = sha1(stage1); + var stage3 = sha1(scramble.toString('binary') + stage2); + return xor(stage3, stage1); +}; + +// This is a port of sql/password.c:hash_password which needs to be used for +// pre-4.1 passwords. +Auth.hashPassword = function(password) { + var nr = [0x5030, 0x5735], + add = 7, + nr2 = [0x1234, 0x5671], + result = new Buffer(8); + + if (typeof password == 'string'){ + password = new Buffer(password); + } + + for (var i = 0; i < password.length; i++) { + var c = password[i]; + if (c == 32 || c == 9) { + // skip space in password + continue; + } + + // nr^= (((nr & 63)+add)*c)+ (nr << 8); + // nr = xor(nr, add(mul(add(and(nr, 63), add), c), shl(nr, 8))) + nr = this.xor32(nr, this.add32(this.mul32(this.add32(this.and32(nr, [0,63]), [0,add]), [0,c]), this.shl32(nr, 8))); + + // nr2+=(nr2 << 8) ^ nr; + // nr2 = add(nr2, xor(shl(nr2, 8), nr)) + nr2 = this.add32(nr2, this.xor32(this.shl32(nr2, 8), nr)); + + // add+=tmp; + add += c; + } + + this.int31Write(result, nr, 0); + this.int31Write(result, nr2, 4); + + return result; +}; + +Auth.randomInit = function(seed1, seed2) { + return { + max_value: 0x3FFFFFFF, + max_value_dbl: 0x3FFFFFFF, + seed1: seed1 % 0x3FFFFFFF, + seed2: seed2 % 0x3FFFFFFF + }; +}; + +Auth.myRnd = function(r){ + r.seed1 = (r.seed1 * 3 + r.seed2) % r.max_value; + r.seed2 = (r.seed1 + r.seed2 + 33) % r.max_value; + + return r.seed1 / r.max_value_dbl; +}; + +Auth.scramble323 = function(message, password) { + var to = new Buffer(8), + hashPass = this.hashPassword(password), + hashMessage = this.hashPassword(message.slice(0, 8)), + seed1 = this.int32Read(hashPass, 0) ^ this.int32Read(hashMessage, 0), + seed2 = this.int32Read(hashPass, 4) ^ this.int32Read(hashMessage, 4), + r = this.randomInit(seed1, seed2); + + for (var i = 0; i < 8; i++){ + to[i] = Math.floor(this.myRnd(r) * 31) + 64; + } + var extra = (Math.floor(this.myRnd(r) * 31)); + + for (var i = 0; i < 8; i++){ + to[i] ^= extra; + } + + return to; +}; + +Auth.fmt32 = function(x){ + var a = x[0].toString(16), + b = x[1].toString(16); + + if (a.length == 1) a = '000'+a; + if (a.length == 2) a = '00'+a; + if (a.length == 3) a = '0'+a; + if (b.length == 1) b = '000'+b; + if (b.length == 2) b = '00'+b; + if (b.length == 3) b = '0'+b; + return '' + a + '/' + b; +}; + +Auth.xor32 = function(a,b){ + return [a[0] ^ b[0], a[1] ^ b[1]]; +}; + +Auth.add32 = function(a,b){ + var w1 = a[1] + b[1], + w2 = a[0] + b[0] + ((w1 & 0xFFFF0000) >> 16); + + return [w2 & 0xFFFF, w1 & 0xFFFF]; +}; + +Auth.mul32 = function(a,b){ + // based on this example of multiplying 32b ints using 16b + // http://www.dsprelated.com/showmessage/89790/1.php + var w1 = a[1] * b[1], + w2 = (((a[1] * b[1]) >> 16) & 0xFFFF) + ((a[0] * b[1]) & 0xFFFF) + (a[1] * b[0] & 0xFFFF); + + return [w2 & 0xFFFF, w1 & 0xFFFF]; +}; + +Auth.and32 = function(a,b){ + return [a[0] & b[0], a[1] & b[1]]; +}; + +Auth.shl32 = function(a,b){ + // assume b is 16 or less + var w1 = a[1] << b, + w2 = (a[0] << b) | ((w1 & 0xFFFF0000) >> 16); + + return [w2 & 0xFFFF, w1 & 0xFFFF]; +}; + +Auth.int31Write = function(buffer, number, offset) { + buffer[offset] = (number[0] >> 8) & 0x7F; + buffer[offset + 1] = (number[0]) & 0xFF; + buffer[offset + 2] = (number[1] >> 8) & 0xFF; + buffer[offset + 3] = (number[1]) & 0xFF; +}; + +Auth.int32Read = function(buffer, offset){ + return (buffer[offset] << 24) + + (buffer[offset+1] << 16) + + (buffer[offset+2] << 8) + + (buffer[offset+3]); +}; diff --git a/node_modules/mysql/lib/protocol/PacketHeader.js b/node_modules/mysql/lib/protocol/PacketHeader.js new file mode 100644 index 0000000..1bb282e --- /dev/null +++ b/node_modules/mysql/lib/protocol/PacketHeader.js @@ -0,0 +1,5 @@ +module.exports = PacketHeader; +function PacketHeader(length, number) { + this.length = length; + this.number = number; +} diff --git a/node_modules/mysql/lib/protocol/PacketWriter.js b/node_modules/mysql/lib/protocol/PacketWriter.js new file mode 100644 index 0000000..7de4e5a --- /dev/null +++ b/node_modules/mysql/lib/protocol/PacketWriter.js @@ -0,0 +1,197 @@ +var BIT_16 = Math.pow(2, 16); +var BIT_24 = Math.pow(2, 24); +// The maximum precision JS Numbers can hold precisely +// Don't panic: Good enough to represent byte values up to 8192 TB +var IEEE_754_BINARY_64_PRECISION = Math.pow(2, 53); +var MAX_PACKET_LENGTH = Math.pow(2, 24) - 1; + +module.exports = PacketWriter; +function PacketWriter() { + this._buffer = new Buffer(0); + this._offset = 0; +} + +PacketWriter.prototype.toBuffer = function(parser) { + var packets = Math.floor(this._buffer.length / MAX_PACKET_LENGTH) + 1; + var buffer = this._buffer; + this._buffer = new Buffer(this._buffer.length + packets * 4); + + for (var packet = 0; packet < packets; packet++) { + this._offset = packet * (MAX_PACKET_LENGTH + 4); + + var isLast = (packet + 1 === packets); + var packetLength = (isLast) + ? buffer.length % MAX_PACKET_LENGTH + : MAX_PACKET_LENGTH; + + var packetNumber = parser.incrementPacketNumber(); + + this.writeUnsignedNumber(3, packetLength); + this.writeUnsignedNumber(1, packetNumber); + + var start = packet * MAX_PACKET_LENGTH; + var end = start + packetLength; + + this.writeBuffer(buffer.slice(start, end)); + } + + return this._buffer; +}; + +PacketWriter.prototype.writeUnsignedNumber = function(bytes, value) { + this._allocate(bytes); + + for (var i = 0; i < bytes; i++) { + this._buffer[this._offset++] = (value >> (i * 8)) & 0xff; + } +}; + +PacketWriter.prototype.writeFiller = function(bytes) { + this._allocate(bytes); + + for (var i = 0; i < bytes; i++) { + this._buffer[this._offset++] = 0x00; + } +}; + +PacketWriter.prototype.writeNullTerminatedString = function(value, encoding) { + // Typecast undefined into '' and numbers into strings + value = value || ''; + value = value + ''; + + var bytes = Buffer.byteLength(value, encoding || 'utf-8') + 1; + this._allocate(bytes); + + this._buffer.write(value, this._offset, encoding); + this._buffer[this._offset + bytes - 1] = 0x00; + + this._offset += bytes; +}; + +PacketWriter.prototype.writeString = function(value) { + // Typecast undefined into '' and numbers into strings + value = value || ''; + value = value + ''; + + var bytes = Buffer.byteLength(value, 'utf-8'); + this._allocate(bytes); + + this._buffer.write(value, this._offset, 'utf-8'); + + this._offset += bytes; +}; + +PacketWriter.prototype.writeBuffer = function(value) { + var bytes = value.length; + + this._allocate(bytes); + value.copy(this._buffer, this._offset); + this._offset += bytes; +}; + +PacketWriter.prototype.writeLengthCodedNumber = function(value) { + if (value === null) { + this._allocate(1); + this._buffer[this._offset++] = 251; + return; + } + + if (value <= 250) { + this._allocate(1); + this._buffer[this._offset++] = value; + return; + } + + if (value > IEEE_754_BINARY_64_PRECISION) { + throw new Error( + 'writeLengthCodedNumber: JS precision range exceeded, your ' + + 'number is > 53 bit: "' + value + '"' + ); + } + + if (value <= BIT_16) { + this._allocate(3) + this._buffer[this._offset++] = 252; + } else if (value <= BIT_24) { + this._allocate(4) + this._buffer[this._offset++] = 253; + } else { + this._allocate(9); + this._buffer[this._offset++] = 254; + } + + // 16 Bit + this._buffer[this._offset++] = value & 0xff; + this._buffer[this._offset++] = (value >> 8) & 0xff; + + if (value <= BIT_16) return; + + // 24 Bit + this._buffer[this._offset++] = (value >> 16) & 0xff; + + if (value <= BIT_24) return; + + this._buffer[this._offset++] = (value >> 24) & 0xff; + + // Hack: Get the most significant 32 bit (JS bitwise operators are 32 bit) + value = value.toString(2); + value = value.substr(0, value.length - 32); + value = parseInt(value, 2); + + this._buffer[this._offset++] = value & 0xff; + this._buffer[this._offset++] = (value >> 8) & 0xff; + this._buffer[this._offset++] = (value >> 16) & 0xff; + + // Set last byte to 0, as we can only support 53 bits in JS (see above) + this._buffer[this._offset++] = 0; +}; + +PacketWriter.prototype.writeLengthCodedBuffer = function(value) { + var bytes = value.length; + this.writeLengthCodedNumber(bytes); + this.writeBuffer(value); +}; + +PacketWriter.prototype.writeNullTerminatedBuffer = function(value) { + this.writeBuffer(value); + this.writeFiller(1); // 0x00 terminator +}; + +PacketWriter.prototype.writeLengthCodedString = function(value) { + if (value === null) { + this.writeLengthCodedNumber(null); + return; + } + + value = (value === undefined) + ? '' + : String(value); + + var bytes = Buffer.byteLength(value, 'utf-8'); + this.writeLengthCodedNumber(bytes); + + if (!bytes) { + return; + } + + this._allocate(bytes); + this._buffer.write(value, this._offset, 'utf-8'); + this._offset += bytes; +}; + +PacketWriter.prototype._allocate = function(bytes) { + if (!this._buffer) { + this._buffer = new Buffer(bytes); + return; + } + + var bytesRemaining = this._buffer.length - this._offset; + if (bytesRemaining >= bytes) { + return; + } + + var oldBuffer = this._buffer; + + this._buffer = new Buffer(oldBuffer.length + bytes); + oldBuffer.copy(this._buffer); +}; diff --git a/node_modules/mysql/lib/protocol/Parser.js b/node_modules/mysql/lib/protocol/Parser.js new file mode 100644 index 0000000..a00ccd0 --- /dev/null +++ b/node_modules/mysql/lib/protocol/Parser.js @@ -0,0 +1,412 @@ +var MAX_PACKET_LENGTH = Math.pow(2, 24) - 1; +var MUL_32BIT = Math.pow(2, 32); +var PacketHeader = require('./PacketHeader'); +var BigNumber = require('bignumber.js'); + +module.exports = Parser; +function Parser(options) { + options = options || {}; + + this._supportBigNumbers = options.config && options.config.supportBigNumbers; + this._buffer = new Buffer(0); + this._longPacketBuffers = []; + this._offset = 0; + this._packetEnd = null; + this._packetHeader = null; + this._packetOffset = null; + this._onError = options.onError || function(err) { throw err; }; + this._onPacket = options.onPacket || function() {}; + this._nextPacketNumber = 0; + this._encoding = 'utf-8'; + this._paused = false; +} + +Parser.prototype.write = function(buffer) { + this.append(buffer); + + while (true) { + if (this._paused) { + return; + } + + if (!this._packetHeader) { + if (this._bytesRemaining() < 4) { + break; + } + + this._packetHeader = new PacketHeader( + this.parseUnsignedNumber(3), + this.parseUnsignedNumber(1) + ); + + if (this._packetHeader.number !== this._nextPacketNumber) { + var err = new Error( + 'Packets out of order. Got: ' + this._packetHeader.number + ' ' + + 'Expected: ' + this._nextPacketNumber + ); + + err.code = 'PROTOCOL_PACKETS_OUT_OF_ORDER'; + err.fatal = true; + + this._onError(err); + } + + this.incrementPacketNumber(); + } + + if (this._bytesRemaining() < this._packetHeader.length) { + break; + } + + this._packetEnd = this._offset + this._packetHeader.length; + this._packetOffset = this._offset; + + if (this._packetHeader.length === MAX_PACKET_LENGTH) { + this._longPacketBuffers.push(this._buffer.slice(this._packetOffset, this._packetEnd)); + + this._advanceToNextPacket(); + continue; + } + + this._combineLongPacketBuffers(); + + // Try...finally to ensure exception safety. Unfortunately this is costing + // us up to ~10% performance in some benchmarks. + var hadException = true; + try { + this._onPacket(this._packetHeader); + hadException = false; + } catch (err) { + if (typeof err.code !== 'string' || err.code.substr(0, 7) !== 'PARSER_') { + // Rethrow unknown errors + throw err; + } + + // Pass down parser errors + this._onError(err); + hadException = false; + } finally { + this._advanceToNextPacket(); + + // If we had an exception, the parser while loop will be broken out + // of after the finally block. So we need to make sure to re-enter it + // to continue parsing any bytes that may already have been received. + if (hadException) { + process.nextTick(this.write.bind(this)); + } + } + } +}; + +Parser.prototype.append = function(newBuffer) { + // If resume() is called, we don't pass a buffer to write() + if (!newBuffer) { + return; + } + + var oldBuffer = this._buffer; + var bytesRemaining = this._bytesRemaining(); + var newLength = bytesRemaining + newBuffer.length; + + var combinedBuffer = (this._offset > newLength) + ? oldBuffer.slice(0, newLength) + : new Buffer(newLength); + + oldBuffer.copy(combinedBuffer, 0, this._offset); + newBuffer.copy(combinedBuffer, bytesRemaining); + + this._buffer = combinedBuffer; + this._offset = 0; +}; + +Parser.prototype.pause = function() { + this._paused = true; +}; + +Parser.prototype.resume = function() { + this._paused = false; + + // nextTick() to avoid entering write() multiple times within the same stack + // which would cause problems as write manipulates the state of the object. + process.nextTick(this.write.bind(this)); +}; + +Parser.prototype.peak = function() { + return this._buffer[this._offset]; +}; + +Parser.prototype.parseUnsignedNumber = function(bytes) { + if (bytes === 1) { + return this._buffer[this._offset++]; + } + + var buffer = this._buffer; + var offset = this._offset + bytes - 1; + var value = 0; + + if (bytes > 4) { + var err = new Error('parseUnsignedNumber: Supports only up to 4 bytes'); + err.offset = (this._offset - this._packetOffset - 1); + err.code = 'PARSER_UNSIGNED_TOO_LONG'; + throw err; + } + + while (offset >= this._offset) { + value = ((value << 8) | buffer[offset]) >>> 0; + offset--; + } + + this._offset += bytes; + + return value; +}; + +Parser.prototype.parseLengthCodedString = function() { + var length = this.parseLengthCodedNumber(); + + if (length === null) { + return null; + } + + return this.parseString(length); +}; + +Parser.prototype.parseLengthCodedBuffer = function() { + var length = this.parseLengthCodedNumber(); + + if (length === null) { + return null; + } + + return this.parseBuffer(length); +}; + +Parser.prototype.parseLengthCodedNumber = function parseLengthCodedNumber() { + if (this._offset >= this._buffer.length) { + var err = new Error('Parser: read past end'); + err.offset = (this._offset - this._packetOffset); + err.code = 'PARSER_READ_PAST_END'; + throw err; + } + + var bits = this._buffer[this._offset++]; + + if (bits <= 250) { + return bits; + } + + switch (bits) { + case 251: + return null; + case 252: + return this.parseUnsignedNumber(2); + case 253: + return this.parseUnsignedNumber(3); + case 254: + break; + default: + var err = new Error('Unexpected first byte' + (bits ? ': 0x' + bits.toString(16) : '')); + err.offset = (this._offset - this._packetOffset - 1); + err.code = 'PARSER_BAD_LENGTH_BYTE'; + throw err; + } + + var low = this.parseUnsignedNumber(4); + var high = this.parseUnsignedNumber(4); + var value; + + if (high >>> 21) { + value = (new BigNumber(low)).plus((new BigNumber(MUL_32BIT)).times(high)).toString(); + + if (this._supportBigNumbers) { + return value; + } + + var err = new Error( + 'parseLengthCodedNumber: JS precision range exceeded, ' + + 'number is >= 53 bit: "' + value + '"' + ); + err.offset = (this._offset - this._packetOffset - 8); + err.code = 'PARSER_JS_PRECISION_RANGE_EXCEEDED'; + throw err; + } + + value = low + (MUL_32BIT * high); + + return value; +}; + +Parser.prototype.parseFiller = function(length) { + return this.parseBuffer(length); +}; + +Parser.prototype.parseNullTerminatedBuffer = function() { + var end = this._nullByteOffset(); + var value = this._buffer.slice(this._offset, end); + this._offset = end + 1; + + return value; +}; + +Parser.prototype.parseNullTerminatedString = function() { + var end = this._nullByteOffset(); + var value = this._buffer.toString(this._encoding, this._offset, end); + this._offset = end + 1; + + return value; +}; + +Parser.prototype._nullByteOffset = function() { + var offset = this._offset; + + while (this._buffer[offset] !== 0x00) { + offset++; + + if (offset >= this._buffer.length) { + var err = new Error('Offset of null terminated string not found.'); + err.offset = (this._offset - this._packetOffset); + err.code = 'PARSER_MISSING_NULL_BYTE'; + throw err; + } + } + + return offset; +}; + +Parser.prototype.parsePacketTerminatedString = function() { + var length = this._packetEnd - this._offset; + return this.parseString(length); +}; + +Parser.prototype.parseBuffer = function(length) { + var response = new Buffer(length); + this._buffer.copy(response, 0, this._offset, this._offset + length); + + this._offset += length; + return response; +}; + +Parser.prototype.parseString = function(length) { + var offset = this._offset; + var end = offset + length; + var value = this._buffer.toString(this._encoding, offset, end); + + this._offset = end; + return value; +}; + +Parser.prototype.parseGeometryValue = function() { + var buffer = this.parseLengthCodedBuffer(); + var offset = 4; + + if (buffer === null || !buffer.length) { + return null; + } + + function parseGeometry() { + var result = null; + var byteOrder = buffer.readUInt8(offset); offset += 1; + var wkbType = byteOrder? buffer.readUInt32LE(offset) : buffer.readUInt32BE(offset); offset += 4; + switch(wkbType) { + case 1: // WKBPoint + var x = byteOrder? buffer.readDoubleLE(offset) : buffer.readDoubleBE(offset); offset += 8; + var y = byteOrder? buffer.readDoubleLE(offset) : buffer.readDoubleBE(offset); offset += 8; + result = {x: x, y: y}; + break; + case 2: // WKBLineString + var numPoints = byteOrder? buffer.readUInt32LE(offset) : buffer.readUInt32BE(offset); offset += 4; + result = []; + for(var i=numPoints;i>0;i--) { + var x = byteOrder? buffer.readDoubleLE(offset) : buffer.readDoubleBE(offset); offset += 8; + var y = byteOrder? buffer.readDoubleLE(offset) : buffer.readDoubleBE(offset); offset += 8; + result.push({x: x, y: y}); + } + break; + case 3: // WKBPolygon + var numRings = byteOrder? buffer.readUInt32LE(offset) : buffer.readUInt32BE(offset); offset += 4; + result = []; + for(var i=numRings;i>0;i--) { + var numPoints = byteOrder? buffer.readUInt32LE(offset) : buffer.readUInt32BE(offset); offset += 4; + var line = []; + for(var j=numPoints;j>0;j--) { + var x = byteOrder? buffer.readDoubleLE(offset) : buffer.readDoubleBE(offset); offset += 8; + var y = byteOrder? buffer.readDoubleLE(offset) : buffer.readDoubleBE(offset); offset += 8; + line.push({x: x, y: y}); + } + result.push(line); + } + break; + case 4: // WKBMultiPoint + case 5: // WKBMultiLineString + case 6: // WKBMultiPolygon + case 7: // WKBGeometryCollection + var num = byteOrder? buffer.readUInt32LE(offset) : buffer.readUInt32BE(offset); offset += 4; + var result = []; + for(var i=num;i>0;i--) { + result.push(parseGeometry()); + } + break; + } + return result; + } + return parseGeometry(); +}; + +Parser.prototype.reachedPacketEnd = function() { + return this._offset === this._packetEnd; +}; + +Parser.prototype._bytesRemaining = function() { + return this._buffer.length - this._offset; +}; + +Parser.prototype.incrementPacketNumber = function() { + var currentPacketNumber = this._nextPacketNumber; + this._nextPacketNumber = (this._nextPacketNumber + 1) % 256; + + return currentPacketNumber; +}; + +Parser.prototype.resetPacketNumber = function() { + this._nextPacketNumber = 0; +}; + +Parser.prototype.packetLength = function() { + return this._longPacketBuffers.reduce(function(length, buffer) { + return length + buffer.length; + }, this._packetHeader.length); +}; + +Parser.prototype._combineLongPacketBuffers = function() { + if (!this._longPacketBuffers.length) { + return; + } + + var trailingPacketBytes = this._buffer.length - this._packetEnd; + + var length = this._longPacketBuffers.reduce(function(length, buffer) { + return length + buffer.length; + }, this._bytesRemaining()); + + var combinedBuffer = new Buffer(length); + + var offset = this._longPacketBuffers.reduce(function(offset, buffer) { + buffer.copy(combinedBuffer, offset); + return offset + buffer.length; + }, 0); + + this._buffer.copy(combinedBuffer, offset, this._offset); + + this._buffer = combinedBuffer; + this._longPacketBuffers = []; + this._offset = 0; + this._packetEnd = this._buffer.length - trailingPacketBytes; + this._packetOffset = 0; +}; + +Parser.prototype._advanceToNextPacket = function() { + this._offset = this._packetEnd; + this._packetHeader = null; + this._packetEnd = null; + this._packetOffset = null; +}; diff --git a/node_modules/mysql/lib/protocol/Protocol.js b/node_modules/mysql/lib/protocol/Protocol.js new file mode 100644 index 0000000..35bf0ef --- /dev/null +++ b/node_modules/mysql/lib/protocol/Protocol.js @@ -0,0 +1,446 @@ +var Parser = require('./Parser'); +var Sequences = require('./sequences'); +var Packets = require('./packets'); +var Timers = require('timers'); +var Stream = require('stream').Stream; +var Util = require('util'); +var PacketWriter = require('./PacketWriter'); + +module.exports = Protocol; +Util.inherits(Protocol, Stream); +function Protocol(options) { + Stream.call(this); + + options = options || {}; + + this.readable = true; + this.writable = true; + + this._config = options.config || {}; + this._connection = options.connection; + this._callback = null; + this._fatalError = null; + this._quitSequence = null; + this._handshakeSequence = null; + this._handshaked = false; + this._ended = false; + this._destroyed = false; + this._queue = []; + this._handshakeInitializationPacket = null; + + this._parser = new Parser({ + onError : this.handleParserError.bind(this), + onPacket : this._parsePacket.bind(this), + config : this._config + }); +} + +Protocol.prototype.write = function(buffer) { + this._parser.write(buffer); + return true; +}; + +Protocol.prototype.handshake = function handshake(options, callback) { + if (typeof options === 'function') { + callback = options; + options = {}; + } + + options = options || {}; + options.config = this._config; + + return this._handshakeSequence = this._enqueue(new Sequences.Handshake(options, callback)); +}; + +Protocol.prototype.query = function query(options, callback) { + return this._enqueue(new Sequences.Query(options, callback)); +}; + +Protocol.prototype.changeUser = function changeUser(options, callback) { + return this._enqueue(new Sequences.ChangeUser(options, callback)); +}; + +Protocol.prototype.ping = function ping(options, callback) { + if (typeof options === 'function') { + callback = options; + options = {}; + } + + return this._enqueue(new Sequences.Ping(options, callback)); +}; + +Protocol.prototype.stats = function stats(options, callback) { + if (typeof options === 'function') { + callback = options; + options = {}; + } + + return this._enqueue(new Sequences.Statistics(options, callback)); +}; + +Protocol.prototype.quit = function quit(options, callback) { + if (typeof options === 'function') { + callback = options; + options = {}; + } + + return this._quitSequence = this._enqueue(new Sequences.Quit(options, callback)); +}; + +Protocol.prototype.end = function() { + if(this._ended) { + return; + } + this._ended = true; + + var expected = (this._quitSequence && this._queue[0] === this._quitSequence); + if (expected) { + this._quitSequence.end(); + this.emit('end'); + return; + } + + var err = new Error('Connection lost: The server closed the connection.'); + err.fatal = true; + err.code = 'PROTOCOL_CONNECTION_LOST'; + + this._delegateError(err); +}; + +Protocol.prototype.pause = function() { + this._parser.pause(); + // Since there is a file stream in query, we must transmit pause/resume event to current sequence. + var seq = this._queue[0]; + if (seq && seq.emit) { + seq.emit('pause'); + } +}; + +Protocol.prototype.resume = function() { + this._parser.resume(); + // Since there is a file stream in query, we must transmit pause/resume event to current sequence. + var seq = this._queue[0]; + if (seq && seq.emit) { + seq.emit('resume'); + } +}; + +Protocol.prototype._enqueue = function(sequence) { + if (!this._validateEnqueue(sequence)) { + return sequence; + } + + if (this._config.trace) { + // Long stack trace support + sequence._callSite = sequence._callSite || new Error; + } + + this._queue.push(sequence); + this.emit('enqueue', sequence); + + var self = this; + sequence + .on('error', function(err) { + self._delegateError(err, sequence); + }) + .on('packet', function(packet) { + Timers.active(sequence); + self._emitPacket(packet); + }) + .on('end', function() { + self._dequeue(sequence); + }) + .on('timeout', function() { + var err = new Error(sequence.constructor.name + ' inactivity timeout'); + + err.code = 'PROTOCOL_SEQUENCE_TIMEOUT'; + err.fatal = true; + err.timeout = sequence._timeout; + + self._delegateError(err, sequence); + }) + .on('start-tls', function() { + Timers.active(sequence); + self._connection._startTLS(function(err) { + if (err) { + // SSL negotiation error are fatal + err.code = 'HANDSHAKE_SSL_ERROR'; + err.fatal = true; + sequence.end(err); + return + } + + Timers.active(sequence); + sequence._tlsUpgradeCompleteHandler(); + }) + }); + + if (this._queue.length === 1) { + this._parser.resetPacketNumber(); + this._startSequence(sequence); + } + + return sequence; +}; + +Protocol.prototype._validateEnqueue = function(sequence) { + var err; + var prefix = 'Cannot enqueue ' + sequence.constructor.name; + var prefixBefore = prefix + ' before '; + var prefixAfter = prefix + ' after '; + + if (this._fatalError) { + err = new Error(prefixAfter + 'fatal error.'); + err.code = 'PROTOCOL_ENQUEUE_AFTER_FATAL_ERROR'; + } else if (this._quitSequence) { + err = new Error(prefixAfter + 'invoking quit.'); + err.code = 'PROTOCOL_ENQUEUE_AFTER_QUIT'; + } else if (this._destroyed) { + err = new Error(prefixAfter + 'being destroyed.'); + err.code = 'PROTOCOL_ENQUEUE_AFTER_DESTROY'; + } else if (this._handshakeSequence && sequence.constructor === Sequences.Handshake) { + err = new Error(prefixAfter + 'already enqueuing a Handshake.'); + err.code = 'PROTOCOL_ENQUEUE_HANDSHAKE_TWICE'; + } else if (!this._handshakeSequence && sequence.constructor === Sequences.ChangeUser) { + err = new Error(prefixBefore + 'a Handshake.'); + err.code = 'PROTOCOL_ENQUEUE_BEFORE_HANDSHAKE'; + } else { + return true; + } + + var self = this; + err.fatal = false; + + sequence + .on('error', function(err) { + self._delegateError(err, sequence); + }) + .end(err); + + return false; +}; + +Protocol.prototype._parsePacket = function() { + var sequence = this._queue[0]; + + if (!sequence) { + var err = new Error('Received packet with no active sequence.'); + err.code = 'PROTOCOL_STRAY_PACKET'; + err.fatal = true; + + this._delegateError(err); + return; + } + + var Packet = this._determinePacket(sequence); + var packet = new Packet({protocol41: this._config.protocol41}); + var packetName = Packet.name; + + // Special case: Faster dispatch, and parsing done inside sequence + if (Packet === Packets.RowDataPacket) { + sequence.RowDataPacket(packet, this._parser, this._connection); + + if (this._config.debug) { + this._debugPacket(true, packet); + } + + return; + } + + if (this._config.debug) { + this._parsePacketDebug(packet); + } else { + packet.parse(this._parser); + } + + if (Packet === Packets.HandshakeInitializationPacket) { + this._handshakeInitializationPacket = packet; + } + + Timers.active(sequence); + + if (!sequence[packetName]) { + var err = new Error('Received packet in the wrong sequence.'); + err.code = 'PROTOCOL_INCORRECT_PACKET_SEQUENCE'; + err.fatal = true; + + this._delegateError(err); + return; + } + + sequence[packetName](packet); +}; + +Protocol.prototype._parsePacketDebug = function _parsePacketDebug(packet) { + try { + packet.parse(this._parser); + } finally { + this._debugPacket(true, packet); + } +}; + +Protocol.prototype._emitPacket = function(packet) { + var packetWriter = new PacketWriter(); + packet.write(packetWriter); + this.emit('data', packetWriter.toBuffer(this._parser)); + + if (this._config.debug) { + this._debugPacket(false, packet); + } +}; + +Protocol.prototype._determinePacket = function(sequence) { + var firstByte = this._parser.peak(); + + if (sequence.determinePacket) { + var Packet = sequence.determinePacket(firstByte, this._parser); + if (Packet) { + return Packet; + } + } + + switch (firstByte) { + case 0x00: + if (!this._handshaked) { + this._handshaked = true; + this.emit('handshake', this._handshakeInitializationPacket); + } + return Packets.OkPacket; + case 0xfe: return Packets.EofPacket; + case 0xff: return Packets.ErrorPacket; + } + + throw new Error('Could not determine packet, firstByte = ' + firstByte); +}; + +Protocol.prototype._dequeue = function(sequence) { + Timers.unenroll(sequence); + + // No point in advancing the queue, we are dead + if (this._fatalError) { + return; + } + + this._queue.shift(); + + var sequence = this._queue[0]; + if (!sequence) { + this.emit('drain'); + return; + } + + this._parser.resetPacketNumber(); + + this._startSequence(sequence); +}; + +Protocol.prototype._startSequence = function(sequence) { + if (sequence._timeout > 0 && isFinite(sequence._timeout)) { + Timers.enroll(sequence, sequence._timeout); + Timers.active(sequence); + } + + if (sequence.constructor === Sequences.ChangeUser) { + sequence.start(this._handshakeInitializationPacket); + } else { + sequence.start(); + } +}; + +Protocol.prototype.handleNetworkError = function(err) { + err.fatal = true; + + var sequence = this._queue[0]; + if (sequence) { + sequence.end(err); + } else { + this._delegateError(err); + } +}; + +Protocol.prototype.handleParserError = function handleParserError(err) { + var sequence = this._queue[0]; + if (sequence) { + sequence.end(err); + } else { + this._delegateError(err); + } +}; + +Protocol.prototype._delegateError = function(err, sequence) { + // Stop delegating errors after the first fatal error + if (this._fatalError) { + return; + } + + if (err.fatal) { + this._fatalError = err; + } + + if (this._shouldErrorBubbleUp(err, sequence)) { + // Can't use regular 'error' event here as that always destroys the pipe + // between socket and protocol which is not what we want (unless the + // exception was fatal). + this.emit('unhandledError', err); + } else if (err.fatal) { + // Send fatal error to all sequences in the queue + var queue = this._queue; + process.nextTick(function () { + queue.forEach(function (sequence) { + sequence.end(err); + }); + queue.length = 0; + }); + } + + // Make sure the stream we are piping to is getting closed + if (err.fatal) { + this.emit('end', err); + } +}; + +Protocol.prototype._shouldErrorBubbleUp = function(err, sequence) { + if (sequence) { + if (sequence.hasErrorHandler()) { + return false; + } else if (!err.fatal) { + return true; + } + } + + return (err.fatal && !this._hasPendingErrorHandlers()); +}; + +Protocol.prototype._hasPendingErrorHandlers = function() { + return this._queue.some(function(sequence) { + return sequence.hasErrorHandler(); + }); +}; + +Protocol.prototype.destroy = function() { + this._destroyed = true; + this._parser.pause(); + + if (this._connection.state !== "disconnected") { + if(!this._ended) { + this.end(); + } + } +}; + +Protocol.prototype._debugPacket = function(incoming, packet) { + var headline = (incoming) + ? '<-- ' + : '--> '; + + headline = headline + packet.constructor.name; + + // check for debug packet restriction + if (Array.isArray(this._config.debug) && this._config.debug.indexOf(packet.constructor.name) === -1) { + return; + } + + console.log(headline); + console.log(packet); + console.log(''); +}; diff --git a/node_modules/mysql/lib/protocol/ResultSet.js b/node_modules/mysql/lib/protocol/ResultSet.js new file mode 100644 index 0000000..f58d74f --- /dev/null +++ b/node_modules/mysql/lib/protocol/ResultSet.js @@ -0,0 +1,7 @@ +module.exports = ResultSet; +function ResultSet(resultSetHeaderPacket) { + this.resultSetHeaderPacket = resultSetHeaderPacket; + this.fieldPackets = []; + this.eofPackets = []; + this.rows = []; +} diff --git a/node_modules/mysql/lib/protocol/SqlString.js b/node_modules/mysql/lib/protocol/SqlString.js new file mode 100644 index 0000000..c9883da --- /dev/null +++ b/node_modules/mysql/lib/protocol/SqlString.js @@ -0,0 +1,140 @@ +var SqlString = exports; + +SqlString.escapeId = function (val, forbidQualified) { + if (Array.isArray(val)) { + return val.map(function(v) { + return SqlString.escapeId(v, forbidQualified); + }).join(', '); + } + + if (forbidQualified) { + return '`' + val.replace(/`/g, '``') + '`'; + } + return '`' + val.replace(/`/g, '``').replace(/\./g, '`.`') + '`'; +}; + +SqlString.escape = function(val, stringifyObjects, timeZone) { + if (val === undefined || val === null) { + return 'NULL'; + } + + switch (typeof val) { + case 'boolean': return (val) ? 'true' : 'false'; + case 'number': return val+''; + } + + if (val instanceof Date) { + val = SqlString.dateToString(val, timeZone || 'local'); + } + + if (Buffer.isBuffer(val)) { + return SqlString.bufferToString(val); + } + + if (Array.isArray(val)) { + return SqlString.arrayToList(val, timeZone); + } + + if (typeof val === 'object') { + if (stringifyObjects) { + val = val.toString(); + } else { + return SqlString.objectToValues(val, timeZone); + } + } + + val = val.replace(/[\0\n\r\b\t\\\'\"\x1a]/g, function(s) { + switch(s) { + case "\0": return "\\0"; + case "\n": return "\\n"; + case "\r": return "\\r"; + case "\b": return "\\b"; + case "\t": return "\\t"; + case "\x1a": return "\\Z"; + default: return "\\"+s; + } + }); + return "'"+val+"'"; +}; + +SqlString.arrayToList = function(array, timeZone) { + return array.map(function(v) { + if (Array.isArray(v)) return '(' + SqlString.arrayToList(v, timeZone) + ')'; + return SqlString.escape(v, true, timeZone); + }).join(', '); +}; + +SqlString.format = function(sql, values, stringifyObjects, timeZone) { + values = values == null ? [] : [].concat(values); + + return sql.replace(/\?\??/g, function(match) { + if (!values.length) { + return match; + } + + if (match == "??") { + return SqlString.escapeId(values.shift()); + } + return SqlString.escape(values.shift(), stringifyObjects, timeZone); + }); +}; + +SqlString.dateToString = function(date, timeZone) { + var dt = new Date(date); + + if (timeZone != 'local') { + var tz = convertTimezone(timeZone); + + dt.setTime(dt.getTime() + (dt.getTimezoneOffset() * 60000)); + if (tz !== false) { + dt.setTime(dt.getTime() + (tz * 60000)); + } + } + + var year = dt.getFullYear(); + var month = zeroPad(dt.getMonth() + 1, 2); + var day = zeroPad(dt.getDate(), 2); + var hour = zeroPad(dt.getHours(), 2); + var minute = zeroPad(dt.getMinutes(), 2); + var second = zeroPad(dt.getSeconds(), 2); + var millisecond = zeroPad(dt.getMilliseconds(), 3); + + return year + '-' + month + '-' + day + ' ' + hour + ':' + minute + ':' + second + '.' + millisecond; +}; + +SqlString.bufferToString = function bufferToString(buffer) { + return "X'" + buffer.toString('hex') + "'"; +}; + +SqlString.objectToValues = function(object, timeZone) { + var values = []; + for (var key in object) { + var value = object[key]; + if(typeof value === 'function') { + continue; + } + + values.push(this.escapeId(key) + ' = ' + SqlString.escape(value, true, timeZone)); + } + + return values.join(', '); +}; + +function zeroPad(number, length) { + number = number.toString(); + while (number.length < length) { + number = '0' + number; + } + + return number; +} + +function convertTimezone(tz) { + if (tz == "Z") return 0; + + var m = tz.match(/([\+\-\s])(\d\d):?(\d\d)?/); + if (m) { + return (m[1] == '-' ? -1 : 1) * (parseInt(m[2], 10) + ((m[3] ? parseInt(m[3], 10) : 0) / 60)) * 60; + } + return false; +} diff --git a/node_modules/mysql/lib/protocol/constants/charsets.js b/node_modules/mysql/lib/protocol/constants/charsets.js new file mode 100644 index 0000000..98b88ea --- /dev/null +++ b/node_modules/mysql/lib/protocol/constants/charsets.js @@ -0,0 +1,262 @@ +exports.BIG5_CHINESE_CI = 1; +exports.LATIN2_CZECH_CS = 2; +exports.DEC8_SWEDISH_CI = 3; +exports.CP850_GENERAL_CI = 4; +exports.LATIN1_GERMAN1_CI = 5; +exports.HP8_ENGLISH_CI = 6; +exports.KOI8R_GENERAL_CI = 7; +exports.LATIN1_SWEDISH_CI = 8; +exports.LATIN2_GENERAL_CI = 9; +exports.SWE7_SWEDISH_CI = 10; +exports.ASCII_GENERAL_CI = 11; +exports.UJIS_JAPANESE_CI = 12; +exports.SJIS_JAPANESE_CI = 13; +exports.CP1251_BULGARIAN_CI = 14; +exports.LATIN1_DANISH_CI = 15; +exports.HEBREW_GENERAL_CI = 16; +exports.TIS620_THAI_CI = 18; +exports.EUCKR_KOREAN_CI = 19; +exports.LATIN7_ESTONIAN_CS = 20; +exports.LATIN2_HUNGARIAN_CI = 21; +exports.KOI8U_GENERAL_CI = 22; +exports.CP1251_UKRAINIAN_CI = 23; +exports.GB2312_CHINESE_CI = 24; +exports.GREEK_GENERAL_CI = 25; +exports.CP1250_GENERAL_CI = 26; +exports.LATIN2_CROATIAN_CI = 27; +exports.GBK_CHINESE_CI = 28; +exports.CP1257_LITHUANIAN_CI = 29; +exports.LATIN5_TURKISH_CI = 30; +exports.LATIN1_GERMAN2_CI = 31; +exports.ARMSCII8_GENERAL_CI = 32; +exports.UTF8_GENERAL_CI = 33; +exports.CP1250_CZECH_CS = 34; +exports.UCS2_GENERAL_CI = 35; +exports.CP866_GENERAL_CI = 36; +exports.KEYBCS2_GENERAL_CI = 37; +exports.MACCE_GENERAL_CI = 38; +exports.MACROMAN_GENERAL_CI = 39; +exports.CP852_GENERAL_CI = 40; +exports.LATIN7_GENERAL_CI = 41; +exports.LATIN7_GENERAL_CS = 42; +exports.MACCE_BIN = 43; +exports.CP1250_CROATIAN_CI = 44; +exports.UTF8MB4_GENERAL_CI = 45; +exports.UTF8MB4_BIN = 46; +exports.LATIN1_BIN = 47; +exports.LATIN1_GENERAL_CI = 48; +exports.LATIN1_GENERAL_CS = 49; +exports.CP1251_BIN = 50; +exports.CP1251_GENERAL_CI = 51; +exports.CP1251_GENERAL_CS = 52; +exports.MACROMAN_BIN = 53; +exports.UTF16_GENERAL_CI = 54; +exports.UTF16_BIN = 55; +exports.UTF16LE_GENERAL_CI = 56; +exports.CP1256_GENERAL_CI = 57; +exports.CP1257_BIN = 58; +exports.CP1257_GENERAL_CI = 59; +exports.UTF32_GENERAL_CI = 60; +exports.UTF32_BIN = 61; +exports.UTF16LE_BIN = 62; +exports.BINARY = 63; +exports.ARMSCII8_BIN = 64; +exports.ASCII_BIN = 65; +exports.CP1250_BIN = 66; +exports.CP1256_BIN = 67; +exports.CP866_BIN = 68; +exports.DEC8_BIN = 69; +exports.GREEK_BIN = 70; +exports.HEBREW_BIN = 71; +exports.HP8_BIN = 72; +exports.KEYBCS2_BIN = 73; +exports.KOI8R_BIN = 74; +exports.KOI8U_BIN = 75; +exports.LATIN2_BIN = 77; +exports.LATIN5_BIN = 78; +exports.LATIN7_BIN = 79; +exports.CP850_BIN = 80; +exports.CP852_BIN = 81; +exports.SWE7_BIN = 82; +exports.UTF8_BIN = 83; +exports.BIG5_BIN = 84; +exports.EUCKR_BIN = 85; +exports.GB2312_BIN = 86; +exports.GBK_BIN = 87; +exports.SJIS_BIN = 88; +exports.TIS620_BIN = 89; +exports.UCS2_BIN = 90; +exports.UJIS_BIN = 91; +exports.GEOSTD8_GENERAL_CI = 92; +exports.GEOSTD8_BIN = 93; +exports.LATIN1_SPANISH_CI = 94; +exports.CP932_JAPANESE_CI = 95; +exports.CP932_BIN = 96; +exports.EUCJPMS_JAPANESE_CI = 97; +exports.EUCJPMS_BIN = 98; +exports.CP1250_POLISH_CI = 99; +exports.UTF16_UNICODE_CI = 101; +exports.UTF16_ICELANDIC_CI = 102; +exports.UTF16_LATVIAN_CI = 103; +exports.UTF16_ROMANIAN_CI = 104; +exports.UTF16_SLOVENIAN_CI = 105; +exports.UTF16_POLISH_CI = 106; +exports.UTF16_ESTONIAN_CI = 107; +exports.UTF16_SPANISH_CI = 108; +exports.UTF16_SWEDISH_CI = 109; +exports.UTF16_TURKISH_CI = 110; +exports.UTF16_CZECH_CI = 111; +exports.UTF16_DANISH_CI = 112; +exports.UTF16_LITHUANIAN_CI = 113; +exports.UTF16_SLOVAK_CI = 114; +exports.UTF16_SPANISH2_CI = 115; +exports.UTF16_ROMAN_CI = 116; +exports.UTF16_PERSIAN_CI = 117; +exports.UTF16_ESPERANTO_CI = 118; +exports.UTF16_HUNGARIAN_CI = 119; +exports.UTF16_SINHALA_CI = 120; +exports.UTF16_GERMAN2_CI = 121; +exports.UTF16_CROATIAN_MYSQL561_CI = 122; +exports.UTF16_UNICODE_520_CI = 123; +exports.UTF16_VIETNAMESE_CI = 124; +exports.UCS2_UNICODE_CI = 128; +exports.UCS2_ICELANDIC_CI = 129; +exports.UCS2_LATVIAN_CI = 130; +exports.UCS2_ROMANIAN_CI = 131; +exports.UCS2_SLOVENIAN_CI = 132; +exports.UCS2_POLISH_CI = 133; +exports.UCS2_ESTONIAN_CI = 134; +exports.UCS2_SPANISH_CI = 135; +exports.UCS2_SWEDISH_CI = 136; +exports.UCS2_TURKISH_CI = 137; +exports.UCS2_CZECH_CI = 138; +exports.UCS2_DANISH_CI = 139; +exports.UCS2_LITHUANIAN_CI = 140; +exports.UCS2_SLOVAK_CI = 141; +exports.UCS2_SPANISH2_CI = 142; +exports.UCS2_ROMAN_CI = 143; +exports.UCS2_PERSIAN_CI = 144; +exports.UCS2_ESPERANTO_CI = 145; +exports.UCS2_HUNGARIAN_CI = 146; +exports.UCS2_SINHALA_CI = 147; +exports.UCS2_GERMAN2_CI = 148; +exports.UCS2_CROATIAN_MYSQL561_CI = 149; +exports.UCS2_UNICODE_520_CI = 150; +exports.UCS2_VIETNAMESE_CI = 151; +exports.UCS2_GENERAL_MYSQL500_CI = 159; +exports.UTF32_UNICODE_CI = 160; +exports.UTF32_ICELANDIC_CI = 161; +exports.UTF32_LATVIAN_CI = 162; +exports.UTF32_ROMANIAN_CI = 163; +exports.UTF32_SLOVENIAN_CI = 164; +exports.UTF32_POLISH_CI = 165; +exports.UTF32_ESTONIAN_CI = 166; +exports.UTF32_SPANISH_CI = 167; +exports.UTF32_SWEDISH_CI = 168; +exports.UTF32_TURKISH_CI = 169; +exports.UTF32_CZECH_CI = 170; +exports.UTF32_DANISH_CI = 171; +exports.UTF32_LITHUANIAN_CI = 172; +exports.UTF32_SLOVAK_CI = 173; +exports.UTF32_SPANISH2_CI = 174; +exports.UTF32_ROMAN_CI = 175; +exports.UTF32_PERSIAN_CI = 176; +exports.UTF32_ESPERANTO_CI = 177; +exports.UTF32_HUNGARIAN_CI = 178; +exports.UTF32_SINHALA_CI = 179; +exports.UTF32_GERMAN2_CI = 180; +exports.UTF32_CROATIAN_MYSQL561_CI = 181; +exports.UTF32_UNICODE_520_CI = 182; +exports.UTF32_VIETNAMESE_CI = 183; +exports.UTF8_UNICODE_CI = 192; +exports.UTF8_ICELANDIC_CI = 193; +exports.UTF8_LATVIAN_CI = 194; +exports.UTF8_ROMANIAN_CI = 195; +exports.UTF8_SLOVENIAN_CI = 196; +exports.UTF8_POLISH_CI = 197; +exports.UTF8_ESTONIAN_CI = 198; +exports.UTF8_SPANISH_CI = 199; +exports.UTF8_SWEDISH_CI = 200; +exports.UTF8_TURKISH_CI = 201; +exports.UTF8_CZECH_CI = 202; +exports.UTF8_DANISH_CI = 203; +exports.UTF8_LITHUANIAN_CI = 204; +exports.UTF8_SLOVAK_CI = 205; +exports.UTF8_SPANISH2_CI = 206; +exports.UTF8_ROMAN_CI = 207; +exports.UTF8_PERSIAN_CI = 208; +exports.UTF8_ESPERANTO_CI = 209; +exports.UTF8_HUNGARIAN_CI = 210; +exports.UTF8_SINHALA_CI = 211; +exports.UTF8_GERMAN2_CI = 212; +exports.UTF8_CROATIAN_MYSQL561_CI = 213; +exports.UTF8_UNICODE_520_CI = 214; +exports.UTF8_VIETNAMESE_CI = 215; +exports.UTF8_GENERAL_MYSQL500_CI = 223; +exports.UTF8MB4_UNICODE_CI = 224; +exports.UTF8MB4_ICELANDIC_CI = 225; +exports.UTF8MB4_LATVIAN_CI = 226; +exports.UTF8MB4_ROMANIAN_CI = 227; +exports.UTF8MB4_SLOVENIAN_CI = 228; +exports.UTF8MB4_POLISH_CI = 229; +exports.UTF8MB4_ESTONIAN_CI = 230; +exports.UTF8MB4_SPANISH_CI = 231; +exports.UTF8MB4_SWEDISH_CI = 232; +exports.UTF8MB4_TURKISH_CI = 233; +exports.UTF8MB4_CZECH_CI = 234; +exports.UTF8MB4_DANISH_CI = 235; +exports.UTF8MB4_LITHUANIAN_CI = 236; +exports.UTF8MB4_SLOVAK_CI = 237; +exports.UTF8MB4_SPANISH2_CI = 238; +exports.UTF8MB4_ROMAN_CI = 239; +exports.UTF8MB4_PERSIAN_CI = 240; +exports.UTF8MB4_ESPERANTO_CI = 241; +exports.UTF8MB4_HUNGARIAN_CI = 242; +exports.UTF8MB4_SINHALA_CI = 243; +exports.UTF8MB4_GERMAN2_CI = 244; +exports.UTF8MB4_CROATIAN_MYSQL561_CI = 245; +exports.UTF8MB4_UNICODE_520_CI = 246; +exports.UTF8MB4_VIETNAMESE_CI = 247; +exports.UTF8_GENERAL50_CI = 253; + +// short aliases +exports.ARMSCII8 = exports.ARMSCII8_GENERAL_CI; +exports.ASCII = exports.ASCII_GENERAL_CI; +exports.BIG5 = exports.BIG5_CHINESE_CI; +exports.BINARY = exports.BINARY; +exports.CP1250 = exports.CP1250_GENERAL_CI; +exports.CP1251 = exports.CP1251_GENERAL_CI; +exports.CP1256 = exports.CP1256_GENERAL_CI; +exports.CP1257 = exports.CP1257_GENERAL_CI; +exports.CP866 = exports.CP866_GENERAL_CI; +exports.CP850 = exports.CP850_GENERAL_CI; +exports.CP852 = exports.CP852_GENERAL_CI; +exports.CP932 = exports.CP932_JAPANESE_CI; +exports.DEC8 = exports.DEC8_SWEDISH_CI; +exports.EUCJPMS = exports.EUCJPMS_JAPANESE_CI; +exports.EUCKR = exports.EUCKR_KOREAN_CI; +exports.GB2312 = exports.GB2312_CHINESE_CI; +exports.GBK = exports.GBK_CHINESE_CI; +exports.GEOSTD8 = exports.GEOSTD8_GENERAL_CI; +exports.GREEK = exports.GREEK_GENERAL_CI; +exports.HEBREW = exports.HEBREW_GENERAL_CI; +exports.HP8 = exports.HP8_ENGLISH_CI; +exports.KEYBCS2 = exports.KEYBCS2_GENERAL_CI; +exports.KOI8R = exports.KOI8R_GENERAL_CI; +exports.KOI8U = exports.KOI8U_GENERAL_CI; +exports.LATIN1 = exports.LATIN1_SWEDISH_CI; +exports.LATIN2 = exports.LATIN2_GENERAL_CI; +exports.LATIN5 = exports.LATIN5_TURKISH_CI; +exports.LATIN7 = exports.LATIN7_GENERAL_CI; +exports.MACCE = exports.MACCE_GENERAL_CI; +exports.MACROMAN = exports.MACROMAN_GENERAL_CI; +exports.SJIS = exports.SJIS_JAPANESE_CI; +exports.SWE7 = exports.SWE7_SWEDISH_CI; +exports.TIS620 = exports.TIS620_THAI_CI; +exports.UCS2 = exports.UCS2_GENERAL_CI; +exports.UJIS = exports.UJIS_JAPANESE_CI; +exports.UTF16 = exports.UTF16_GENERAL_CI; +exports.UTF16LE = exports.UTF16LE_GENERAL_CI; +exports.UTF8 = exports.UTF8_GENERAL_CI; +exports.UTF8MB4 = exports.UTF8MB4_GENERAL_CI; +exports.UTF32 = exports.UTF32_GENERAL_CI; diff --git a/node_modules/mysql/lib/protocol/constants/client.js b/node_modules/mysql/lib/protocol/constants/client.js new file mode 100644 index 0000000..59aadc6 --- /dev/null +++ b/node_modules/mysql/lib/protocol/constants/client.js @@ -0,0 +1,26 @@ +// Manually extracted from mysql-5.5.23/include/mysql_com.h +exports.CLIENT_LONG_PASSWORD = 1; /* new more secure passwords */ +exports.CLIENT_FOUND_ROWS = 2; /* Found instead of affected rows */ +exports.CLIENT_LONG_FLAG = 4; /* Get all column flags */ +exports.CLIENT_CONNECT_WITH_DB = 8; /* One can specify db on connect */ +exports.CLIENT_NO_SCHEMA = 16; /* Don't allow database.table.column */ +exports.CLIENT_COMPRESS = 32; /* Can use compression protocol */ +exports.CLIENT_ODBC = 64; /* Odbc client */ +exports.CLIENT_LOCAL_FILES = 128; /* Can use LOAD DATA LOCAL */ +exports.CLIENT_IGNORE_SPACE = 256; /* Ignore spaces before '(' */ +exports.CLIENT_PROTOCOL_41 = 512; /* New 4.1 protocol */ +exports.CLIENT_INTERACTIVE = 1024; /* This is an interactive client */ +exports.CLIENT_SSL = 2048; /* Switch to SSL after handshake */ +exports.CLIENT_IGNORE_SIGPIPE = 4096; /* IGNORE sigpipes */ +exports.CLIENT_TRANSACTIONS = 8192; /* Client knows about transactions */ +exports.CLIENT_RESERVED = 16384; /* Old flag for 4.1 protocol */ +exports.CLIENT_SECURE_CONNECTION = 32768; /* New 4.1 authentication */ + +exports.CLIENT_MULTI_STATEMENTS = 65536; /* Enable/disable multi-stmt support */ +exports.CLIENT_MULTI_RESULTS = 131072; /* Enable/disable multi-results */ +exports.CLIENT_PS_MULTI_RESULTS = 262144; /* Multi-results in PS-protocol */ + +exports.CLIENT_PLUGIN_AUTH = 524288; /* Client supports plugin authentication */ + +exports.CLIENT_SSL_VERIFY_SERVER_CERT = 1073741824; +exports.CLIENT_REMEMBER_OPTIONS = 2147483648; diff --git a/node_modules/mysql/lib/protocol/constants/errors.js b/node_modules/mysql/lib/protocol/constants/errors.js new file mode 100644 index 0000000..8856456 --- /dev/null +++ b/node_modules/mysql/lib/protocol/constants/errors.js @@ -0,0 +1,1978 @@ +/** + * MySQL error constants + * + * !! Generated by generate-error-constants.js, do not modify by hand !! + */ + +exports.EE_CANTCREATEFILE = 1; +exports.EE_READ = 2; +exports.EE_WRITE = 3; +exports.EE_BADCLOSE = 4; +exports.EE_OUTOFMEMORY = 5; +exports.EE_DELETE = 6; +exports.EE_LINK = 7; +exports.EE_EOFERR = 9; +exports.EE_CANTLOCK = 10; +exports.EE_CANTUNLOCK = 11; +exports.EE_DIR = 12; +exports.EE_STAT = 13; +exports.EE_CANT_CHSIZE = 14; +exports.EE_CANT_OPEN_STREAM = 15; +exports.EE_GETWD = 16; +exports.EE_SETWD = 17; +exports.EE_LINK_WARNING = 18; +exports.EE_OPEN_WARNING = 19; +exports.EE_DISK_FULL = 20; +exports.EE_CANT_MKDIR = 21; +exports.EE_UNKNOWN_CHARSET = 22; +exports.EE_OUT_OF_FILERESOURCES = 23; +exports.EE_CANT_READLINK = 24; +exports.EE_CANT_SYMLINK = 25; +exports.EE_REALPATH = 26; +exports.EE_SYNC = 27; +exports.EE_UNKNOWN_COLLATION = 28; +exports.EE_FILENOTFOUND = 29; +exports.EE_FILE_NOT_CLOSED = 30; +exports.EE_CHANGE_OWNERSHIP = 31; +exports.EE_CHANGE_PERMISSIONS = 32; +exports.EE_CANT_SEEK = 33; +exports.HA_ERR_KEY_NOT_FOUND = 120; +exports.HA_ERR_FOUND_DUPP_KEY = 121; +exports.HA_ERR_INTERNAL_ERROR = 122; +exports.HA_ERR_RECORD_CHANGED = 123; +exports.HA_ERR_WRONG_INDEX = 124; +exports.HA_ERR_CRASHED = 126; +exports.HA_ERR_WRONG_IN_RECORD = 127; +exports.HA_ERR_OUT_OF_MEM = 128; +exports.HA_ERR_NOT_A_TABLE = 130; +exports.HA_ERR_WRONG_COMMAND = 131; +exports.HA_ERR_OLD_FILE = 132; +exports.HA_ERR_NO_ACTIVE_RECORD = 133; +exports.HA_ERR_RECORD_DELETED = 134; +exports.HA_ERR_RECORD_FILE_FULL = 135; +exports.HA_ERR_INDEX_FILE_FULL = 136; +exports.HA_ERR_END_OF_FILE = 137; +exports.HA_ERR_UNSUPPORTED = 138; +exports.HA_ERR_TO_BIG_ROW = 139; +exports.HA_WRONG_CREATE_OPTION = 140; +exports.HA_ERR_FOUND_DUPP_UNIQUE = 141; +exports.HA_ERR_UNKNOWN_CHARSET = 142; +exports.HA_ERR_WRONG_MRG_TABLE_DEF = 143; +exports.HA_ERR_CRASHED_ON_REPAIR = 144; +exports.HA_ERR_CRASHED_ON_USAGE = 145; +exports.HA_ERR_LOCK_WAIT_TIMEOUT = 146; +exports.HA_ERR_LOCK_TABLE_FULL = 147; +exports.HA_ERR_READ_ONLY_TRANSACTION = 148; +exports.HA_ERR_LOCK_DEADLOCK = 149; +exports.HA_ERR_CANNOT_ADD_FOREIGN = 150; +exports.HA_ERR_NO_REFERENCED_ROW = 151; +exports.HA_ERR_ROW_IS_REFERENCED = 152; +exports.HA_ERR_NO_SAVEPOINT = 153; +exports.HA_ERR_NON_UNIQUE_BLOCK_SIZE = 154; +exports.HA_ERR_NO_SUCH_TABLE = 155; +exports.HA_ERR_TABLE_EXIST = 156; +exports.HA_ERR_NO_CONNECTION = 157; +exports.HA_ERR_NULL_IN_SPATIAL = 158; +exports.HA_ERR_TABLE_DEF_CHANGED = 159; +exports.HA_ERR_NO_PARTITION_FOUND = 160; +exports.HA_ERR_RBR_LOGGING_FAILED = 161; +exports.HA_ERR_DROP_INDEX_FK = 162; +exports.HA_ERR_FOREIGN_DUPLICATE_KEY = 163; +exports.HA_ERR_TABLE_NEEDS_UPGRADE = 164; +exports.HA_ERR_TABLE_READONLY = 165; +exports.HA_ERR_AUTOINC_READ_FAILED = 166; +exports.HA_ERR_AUTOINC_ERANGE = 167; +exports.HA_ERR_GENERIC = 168; +exports.HA_ERR_RECORD_IS_THE_SAME = 169; +exports.HA_ERR_LOGGING_IMPOSSIBLE = 170; +exports.HA_ERR_CORRUPT_EVENT = 171; +exports.HA_ERR_NEW_FILE = 172; +exports.HA_ERR_ROWS_EVENT_APPLY = 173; +exports.HA_ERR_INITIALIZATION = 174; +exports.HA_ERR_FILE_TOO_SHORT = 175; +exports.HA_ERR_WRONG_CRC = 176; +exports.HA_ERR_TOO_MANY_CONCURRENT_TRXS = 177; +exports.HA_ERR_NOT_IN_LOCK_PARTITIONS = 178; +exports.HA_ERR_INDEX_COL_TOO_LONG = 179; +exports.HA_ERR_INDEX_CORRUPT = 180; +exports.HA_ERR_UNDO_REC_TOO_BIG = 181; +exports.HA_FTS_INVALID_DOCID = 182; +exports.HA_ERR_TABLE_IN_FK_CHECK = 183; +exports.HA_ERR_TABLESPACE_EXISTS = 184; +exports.HA_ERR_TOO_MANY_FIELDS = 185; +exports.HA_ERR_ROW_IN_WRONG_PARTITION = 186; +exports.HA_ERR_INNODB_READ_ONLY = 187; +exports.HA_ERR_FTS_EXCEED_RESULT_CACHE_LIMIT = 188; +exports.HA_ERR_TEMP_FILE_WRITE_FAILURE = 189; +exports.HA_ERR_INNODB_FORCED_RECOVERY = 190; +exports.HA_ERR_FTS_TOO_MANY_WORDS_IN_PHRASE = 191; +exports.ER_HASHCHK = 1000; +exports.ER_NISAMCHK = 1001; +exports.ER_NO = 1002; +exports.ER_YES = 1003; +exports.ER_CANT_CREATE_FILE = 1004; +exports.ER_CANT_CREATE_TABLE = 1005; +exports.ER_CANT_CREATE_DB = 1006; +exports.ER_DB_CREATE_EXISTS = 1007; +exports.ER_DB_DROP_EXISTS = 1008; +exports.ER_DB_DROP_DELETE = 1009; +exports.ER_DB_DROP_RMDIR = 1010; +exports.ER_CANT_DELETE_FILE = 1011; +exports.ER_CANT_FIND_SYSTEM_REC = 1012; +exports.ER_CANT_GET_STAT = 1013; +exports.ER_CANT_GET_WD = 1014; +exports.ER_CANT_LOCK = 1015; +exports.ER_CANT_OPEN_FILE = 1016; +exports.ER_FILE_NOT_FOUND = 1017; +exports.ER_CANT_READ_DIR = 1018; +exports.ER_CANT_SET_WD = 1019; +exports.ER_CHECKREAD = 1020; +exports.ER_DISK_FULL = 1021; +exports.ER_DUP_KEY = 1022; +exports.ER_ERROR_ON_CLOSE = 1023; +exports.ER_ERROR_ON_READ = 1024; +exports.ER_ERROR_ON_RENAME = 1025; +exports.ER_ERROR_ON_WRITE = 1026; +exports.ER_FILE_USED = 1027; +exports.ER_FILSORT_ABORT = 1028; +exports.ER_FORM_NOT_FOUND = 1029; +exports.ER_GET_ERRNO = 1030; +exports.ER_ILLEGAL_HA = 1031; +exports.ER_KEY_NOT_FOUND = 1032; +exports.ER_NOT_FORM_FILE = 1033; +exports.ER_NOT_KEYFILE = 1034; +exports.ER_OLD_KEYFILE = 1035; +exports.ER_OPEN_AS_READONLY = 1036; +exports.ER_OUTOFMEMORY = 1037; +exports.ER_OUT_OF_SORTMEMORY = 1038; +exports.ER_UNEXPECTED_EOF = 1039; +exports.ER_CON_COUNT_ERROR = 1040; +exports.ER_OUT_OF_RESOURCES = 1041; +exports.ER_BAD_HOST_ERROR = 1042; +exports.ER_HANDSHAKE_ERROR = 1043; +exports.ER_DBACCESS_DENIED_ERROR = 1044; +exports.ER_ACCESS_DENIED_ERROR = 1045; +exports.ER_NO_DB_ERROR = 1046; +exports.ER_UNKNOWN_COM_ERROR = 1047; +exports.ER_BAD_NULL_ERROR = 1048; +exports.ER_BAD_DB_ERROR = 1049; +exports.ER_TABLE_EXISTS_ERROR = 1050; +exports.ER_BAD_TABLE_ERROR = 1051; +exports.ER_NON_UNIQ_ERROR = 1052; +exports.ER_SERVER_SHUTDOWN = 1053; +exports.ER_BAD_FIELD_ERROR = 1054; +exports.ER_WRONG_FIELD_WITH_GROUP = 1055; +exports.ER_WRONG_GROUP_FIELD = 1056; +exports.ER_WRONG_SUM_SELECT = 1057; +exports.ER_WRONG_VALUE_COUNT = 1058; +exports.ER_TOO_LONG_IDENT = 1059; +exports.ER_DUP_FIELDNAME = 1060; +exports.ER_DUP_KEYNAME = 1061; +exports.ER_DUP_ENTRY = 1062; +exports.ER_WRONG_FIELD_SPEC = 1063; +exports.ER_PARSE_ERROR = 1064; +exports.ER_EMPTY_QUERY = 1065; +exports.ER_NONUNIQ_TABLE = 1066; +exports.ER_INVALID_DEFAULT = 1067; +exports.ER_MULTIPLE_PRI_KEY = 1068; +exports.ER_TOO_MANY_KEYS = 1069; +exports.ER_TOO_MANY_KEY_PARTS = 1070; +exports.ER_TOO_LONG_KEY = 1071; +exports.ER_KEY_COLUMN_DOES_NOT_EXITS = 1072; +exports.ER_BLOB_USED_AS_KEY = 1073; +exports.ER_TOO_BIG_FIELDLENGTH = 1074; +exports.ER_WRONG_AUTO_KEY = 1075; +exports.ER_READY = 1076; +exports.ER_NORMAL_SHUTDOWN = 1077; +exports.ER_GOT_SIGNAL = 1078; +exports.ER_SHUTDOWN_COMPLETE = 1079; +exports.ER_FORCING_CLOSE = 1080; +exports.ER_IPSOCK_ERROR = 1081; +exports.ER_NO_SUCH_INDEX = 1082; +exports.ER_WRONG_FIELD_TERMINATORS = 1083; +exports.ER_BLOBS_AND_NO_TERMINATED = 1084; +exports.ER_TEXTFILE_NOT_READABLE = 1085; +exports.ER_FILE_EXISTS_ERROR = 1086; +exports.ER_LOAD_INFO = 1087; +exports.ER_ALTER_INFO = 1088; +exports.ER_WRONG_SUB_KEY = 1089; +exports.ER_CANT_REMOVE_ALL_FIELDS = 1090; +exports.ER_CANT_DROP_FIELD_OR_KEY = 1091; +exports.ER_INSERT_INFO = 1092; +exports.ER_UPDATE_TABLE_USED = 1093; +exports.ER_NO_SUCH_THREAD = 1094; +exports.ER_KILL_DENIED_ERROR = 1095; +exports.ER_NO_TABLES_USED = 1096; +exports.ER_TOO_BIG_SET = 1097; +exports.ER_NO_UNIQUE_LOGFILE = 1098; +exports.ER_TABLE_NOT_LOCKED_FOR_WRITE = 1099; +exports.ER_TABLE_NOT_LOCKED = 1100; +exports.ER_BLOB_CANT_HAVE_DEFAULT = 1101; +exports.ER_WRONG_DB_NAME = 1102; +exports.ER_WRONG_TABLE_NAME = 1103; +exports.ER_TOO_BIG_SELECT = 1104; +exports.ER_UNKNOWN_ERROR = 1105; +exports.ER_UNKNOWN_PROCEDURE = 1106; +exports.ER_WRONG_PARAMCOUNT_TO_PROCEDURE = 1107; +exports.ER_WRONG_PARAMETERS_TO_PROCEDURE = 1108; +exports.ER_UNKNOWN_TABLE = 1109; +exports.ER_FIELD_SPECIFIED_TWICE = 1110; +exports.ER_INVALID_GROUP_FUNC_USE = 1111; +exports.ER_UNSUPPORTED_EXTENSION = 1112; +exports.ER_TABLE_MUST_HAVE_COLUMNS = 1113; +exports.ER_RECORD_FILE_FULL = 1114; +exports.ER_UNKNOWN_CHARACTER_SET = 1115; +exports.ER_TOO_MANY_TABLES = 1116; +exports.ER_TOO_MANY_FIELDS = 1117; +exports.ER_TOO_BIG_ROWSIZE = 1118; +exports.ER_STACK_OVERRUN = 1119; +exports.ER_WRONG_OUTER_JOIN = 1120; +exports.ER_NULL_COLUMN_IN_INDEX = 1121; +exports.ER_CANT_FIND_UDF = 1122; +exports.ER_CANT_INITIALIZE_UDF = 1123; +exports.ER_UDF_NO_PATHS = 1124; +exports.ER_UDF_EXISTS = 1125; +exports.ER_CANT_OPEN_LIBRARY = 1126; +exports.ER_CANT_FIND_DL_ENTRY = 1127; +exports.ER_FUNCTION_NOT_DEFINED = 1128; +exports.ER_HOST_IS_BLOCKED = 1129; +exports.ER_HOST_NOT_PRIVILEGED = 1130; +exports.ER_PASSWORD_ANONYMOUS_USER = 1131; +exports.ER_PASSWORD_NOT_ALLOWED = 1132; +exports.ER_PASSWORD_NO_MATCH = 1133; +exports.ER_UPDATE_INFO = 1134; +exports.ER_CANT_CREATE_THREAD = 1135; +exports.ER_WRONG_VALUE_COUNT_ON_ROW = 1136; +exports.ER_CANT_REOPEN_TABLE = 1137; +exports.ER_INVALID_USE_OF_NULL = 1138; +exports.ER_REGEXP_ERROR = 1139; +exports.ER_MIX_OF_GROUP_FUNC_AND_FIELDS = 1140; +exports.ER_NONEXISTING_GRANT = 1141; +exports.ER_TABLEACCESS_DENIED_ERROR = 1142; +exports.ER_COLUMNACCESS_DENIED_ERROR = 1143; +exports.ER_ILLEGAL_GRANT_FOR_TABLE = 1144; +exports.ER_GRANT_WRONG_HOST_OR_USER = 1145; +exports.ER_NO_SUCH_TABLE = 1146; +exports.ER_NONEXISTING_TABLE_GRANT = 1147; +exports.ER_NOT_ALLOWED_COMMAND = 1148; +exports.ER_SYNTAX_ERROR = 1149; +exports.ER_DELAYED_CANT_CHANGE_LOCK = 1150; +exports.ER_TOO_MANY_DELAYED_THREADS = 1151; +exports.ER_ABORTING_CONNECTION = 1152; +exports.ER_NET_PACKET_TOO_LARGE = 1153; +exports.ER_NET_READ_ERROR_FROM_PIPE = 1154; +exports.ER_NET_FCNTL_ERROR = 1155; +exports.ER_NET_PACKETS_OUT_OF_ORDER = 1156; +exports.ER_NET_UNCOMPRESS_ERROR = 1157; +exports.ER_NET_READ_ERROR = 1158; +exports.ER_NET_READ_INTERRUPTED = 1159; +exports.ER_NET_ERROR_ON_WRITE = 1160; +exports.ER_NET_WRITE_INTERRUPTED = 1161; +exports.ER_TOO_LONG_STRING = 1162; +exports.ER_TABLE_CANT_HANDLE_BLOB = 1163; +exports.ER_TABLE_CANT_HANDLE_AUTO_INCREMENT = 1164; +exports.ER_DELAYED_INSERT_TABLE_LOCKED = 1165; +exports.ER_WRONG_COLUMN_NAME = 1166; +exports.ER_WRONG_KEY_COLUMN = 1167; +exports.ER_WRONG_MRG_TABLE = 1168; +exports.ER_DUP_UNIQUE = 1169; +exports.ER_BLOB_KEY_WITHOUT_LENGTH = 1170; +exports.ER_PRIMARY_CANT_HAVE_NULL = 1171; +exports.ER_TOO_MANY_ROWS = 1172; +exports.ER_REQUIRES_PRIMARY_KEY = 1173; +exports.ER_NO_RAID_COMPILED = 1174; +exports.ER_UPDATE_WITHOUT_KEY_IN_SAFE_MODE = 1175; +exports.ER_KEY_DOES_NOT_EXITS = 1176; +exports.ER_CHECK_NO_SUCH_TABLE = 1177; +exports.ER_CHECK_NOT_IMPLEMENTED = 1178; +exports.ER_CANT_DO_THIS_DURING_AN_TRANSACTION = 1179; +exports.ER_ERROR_DURING_COMMIT = 1180; +exports.ER_ERROR_DURING_ROLLBACK = 1181; +exports.ER_ERROR_DURING_FLUSH_LOGS = 1182; +exports.ER_ERROR_DURING_CHECKPOINT = 1183; +exports.ER_NEW_ABORTING_CONNECTION = 1184; +exports.ER_DUMP_NOT_IMPLEMENTED = 1185; +exports.ER_FLUSH_MASTER_BINLOG_CLOSED = 1186; +exports.ER_INDEX_REBUILD = 1187; +exports.ER_MASTER = 1188; +exports.ER_MASTER_NET_READ = 1189; +exports.ER_MASTER_NET_WRITE = 1190; +exports.ER_FT_MATCHING_KEY_NOT_FOUND = 1191; +exports.ER_LOCK_OR_ACTIVE_TRANSACTION = 1192; +exports.ER_UNKNOWN_SYSTEM_VARIABLE = 1193; +exports.ER_CRASHED_ON_USAGE = 1194; +exports.ER_CRASHED_ON_REPAIR = 1195; +exports.ER_WARNING_NOT_COMPLETE_ROLLBACK = 1196; +exports.ER_TRANS_CACHE_FULL = 1197; +exports.ER_SLAVE_MUST_STOP = 1198; +exports.ER_SLAVE_NOT_RUNNING = 1199; +exports.ER_BAD_SLAVE = 1200; +exports.ER_MASTER_INFO = 1201; +exports.ER_SLAVE_THREAD = 1202; +exports.ER_TOO_MANY_USER_CONNECTIONS = 1203; +exports.ER_SET_CONSTANTS_ONLY = 1204; +exports.ER_LOCK_WAIT_TIMEOUT = 1205; +exports.ER_LOCK_TABLE_FULL = 1206; +exports.ER_READ_ONLY_TRANSACTION = 1207; +exports.ER_DROP_DB_WITH_READ_LOCK = 1208; +exports.ER_CREATE_DB_WITH_READ_LOCK = 1209; +exports.ER_WRONG_ARGUMENTS = 1210; +exports.ER_NO_PERMISSION_TO_CREATE_USER = 1211; +exports.ER_UNION_TABLES_IN_DIFFERENT_DIR = 1212; +exports.ER_LOCK_DEADLOCK = 1213; +exports.ER_TABLE_CANT_HANDLE_FT = 1214; +exports.ER_CANNOT_ADD_FOREIGN = 1215; +exports.ER_NO_REFERENCED_ROW = 1216; +exports.ER_ROW_IS_REFERENCED = 1217; +exports.ER_CONNECT_TO_MASTER = 1218; +exports.ER_QUERY_ON_MASTER = 1219; +exports.ER_ERROR_WHEN_EXECUTING_COMMAND = 1220; +exports.ER_WRONG_USAGE = 1221; +exports.ER_WRONG_NUMBER_OF_COLUMNS_IN_SELECT = 1222; +exports.ER_CANT_UPDATE_WITH_READLOCK = 1223; +exports.ER_MIXING_NOT_ALLOWED = 1224; +exports.ER_DUP_ARGUMENT = 1225; +exports.ER_USER_LIMIT_REACHED = 1226; +exports.ER_SPECIFIC_ACCESS_DENIED_ERROR = 1227; +exports.ER_LOCAL_VARIABLE = 1228; +exports.ER_GLOBAL_VARIABLE = 1229; +exports.ER_NO_DEFAULT = 1230; +exports.ER_WRONG_VALUE_FOR_VAR = 1231; +exports.ER_WRONG_TYPE_FOR_VAR = 1232; +exports.ER_VAR_CANT_BE_READ = 1233; +exports.ER_CANT_USE_OPTION_HERE = 1234; +exports.ER_NOT_SUPPORTED_YET = 1235; +exports.ER_MASTER_FATAL_ERROR_READING_BINLOG = 1236; +exports.ER_SLAVE_IGNORED_TABLE = 1237; +exports.ER_INCORRECT_GLOBAL_LOCAL_VAR = 1238; +exports.ER_WRONG_FK_DEF = 1239; +exports.ER_KEY_REF_DO_NOT_MATCH_TABLE_REF = 1240; +exports.ER_OPERAND_COLUMNS = 1241; +exports.ER_SUBQUERY_NO_ = 1242; +exports.ER_UNKNOWN_STMT_HANDLER = 1243; +exports.ER_CORRUPT_HELP_DB = 1244; +exports.ER_CYCLIC_REFERENCE = 1245; +exports.ER_AUTO_CONVERT = 1246; +exports.ER_ILLEGAL_REFERENCE = 1247; +exports.ER_DERIVED_MUST_HAVE_ALIAS = 1248; +exports.ER_SELECT_REDUCED = 1249; +exports.ER_TABLENAME_NOT_ALLOWED_HERE = 1250; +exports.ER_NOT_SUPPORTED_AUTH_MODE = 1251; +exports.ER_SPATIAL_CANT_HAVE_NULL = 1252; +exports.ER_COLLATION_CHARSET_MISMATCH = 1253; +exports.ER_SLAVE_WAS_RUNNING = 1254; +exports.ER_SLAVE_WAS_NOT_RUNNING = 1255; +exports.ER_TOO_BIG_FOR_UNCOMPRESS = 1256; +exports.ER_ZLIB_Z_MEM_ERROR = 1257; +exports.ER_ZLIB_Z_BUF_ERROR = 1258; +exports.ER_ZLIB_Z_DATA_ERROR = 1259; +exports.ER_CUT_VALUE_GROUP_CONCAT = 1260; +exports.ER_WARN_TOO_FEW_RECORDS = 1261; +exports.ER_WARN_TOO_MANY_RECORDS = 1262; +exports.ER_WARN_NULL_TO_NOTNULL = 1263; +exports.ER_WARN_DATA_OUT_OF_RANGE = 1264; +exports.WARN_DATA_TRUNCATED = 1265; +exports.ER_WARN_USING_OTHER_HANDLER = 1266; +exports.ER_CANT_AGGREGATE_ = 1267; +exports.ER_DROP_USER = 1268; +exports.ER_REVOKE_GRANTS = 1269; +exports.ER_CANT_AGGREGATE_ = 1270; +exports.ER_CANT_AGGREGATE_NCOLLATIONS = 1271; +exports.ER_VARIABLE_IS_NOT_STRUCT = 1272; +exports.ER_UNKNOWN_COLLATION = 1273; +exports.ER_SLAVE_IGNORED_SSL_PARAMS = 1274; +exports.ER_SERVER_IS_IN_SECURE_AUTH_MODE = 1275; +exports.ER_WARN_FIELD_RESOLVED = 1276; +exports.ER_BAD_SLAVE_UNTIL_COND = 1277; +exports.ER_MISSING_SKIP_SLAVE = 1278; +exports.ER_UNTIL_COND_IGNORED = 1279; +exports.ER_WRONG_NAME_FOR_INDEX = 1280; +exports.ER_WRONG_NAME_FOR_CATALOG = 1281; +exports.ER_WARN_QC_RESIZE = 1282; +exports.ER_BAD_FT_COLUMN = 1283; +exports.ER_UNKNOWN_KEY_CACHE = 1284; +exports.ER_WARN_HOSTNAME_WONT_WORK = 1285; +exports.ER_UNKNOWN_STORAGE_ENGINE = 1286; +exports.ER_WARN_DEPRECATED_SYNTAX = 1287; +exports.ER_NON_UPDATABLE_TABLE = 1288; +exports.ER_FEATURE_DISABLED = 1289; +exports.ER_OPTION_PREVENTS_STATEMENT = 1290; +exports.ER_DUPLICATED_VALUE_IN_TYPE = 1291; +exports.ER_TRUNCATED_WRONG_VALUE = 1292; +exports.ER_TOO_MUCH_AUTO_TIMESTAMP_COLS = 1293; +exports.ER_INVALID_ON_UPDATE = 1294; +exports.ER_UNSUPPORTED_PS = 1295; +exports.ER_GET_ERRMSG = 1296; +exports.ER_GET_TEMPORARY_ERRMSG = 1297; +exports.ER_UNKNOWN_TIME_ZONE = 1298; +exports.ER_WARN_INVALID_TIMESTAMP = 1299; +exports.ER_INVALID_CHARACTER_STRING = 1300; +exports.ER_WARN_ALLOWED_PACKET_OVERFLOWED = 1301; +exports.ER_CONFLICTING_DECLARATIONS = 1302; +exports.ER_SP_NO_RECURSIVE_CREATE = 1303; +exports.ER_SP_ALREADY_EXISTS = 1304; +exports.ER_SP_DOES_NOT_EXIST = 1305; +exports.ER_SP_DROP_FAILED = 1306; +exports.ER_SP_STORE_FAILED = 1307; +exports.ER_SP_LILABEL_MISMATCH = 1308; +exports.ER_SP_LABEL_REDEFINE = 1309; +exports.ER_SP_LABEL_MISMATCH = 1310; +exports.ER_SP_UNINIT_VAR = 1311; +exports.ER_SP_BADSELECT = 1312; +exports.ER_SP_BADRETURN = 1313; +exports.ER_SP_BADSTATEMENT = 1314; +exports.ER_UPDATE_LOG_DEPRECATED_IGNORED = 1315; +exports.ER_UPDATE_LOG_DEPRECATED_TRANSLATED = 1316; +exports.ER_QUERY_INTERRUPTED = 1317; +exports.ER_SP_WRONG_NO_OF_ARGS = 1318; +exports.ER_SP_COND_MISMATCH = 1319; +exports.ER_SP_NORETURN = 1320; +exports.ER_SP_NORETURNEND = 1321; +exports.ER_SP_BAD_CURSOR_QUERY = 1322; +exports.ER_SP_BAD_CURSOR_SELECT = 1323; +exports.ER_SP_CURSOR_MISMATCH = 1324; +exports.ER_SP_CURSOR_ALREADY_OPEN = 1325; +exports.ER_SP_CURSOR_NOT_OPEN = 1326; +exports.ER_SP_UNDECLARED_VAR = 1327; +exports.ER_SP_WRONG_NO_OF_FETCH_ARGS = 1328; +exports.ER_SP_FETCH_NO_DATA = 1329; +exports.ER_SP_DUP_PARAM = 1330; +exports.ER_SP_DUP_VAR = 1331; +exports.ER_SP_DUP_COND = 1332; +exports.ER_SP_DUP_CURS = 1333; +exports.ER_SP_CANT_ALTER = 1334; +exports.ER_SP_SUBSELECT_NYI = 1335; +exports.ER_STMT_NOT_ALLOWED_IN_SF_OR_TRG = 1336; +exports.ER_SP_VARCOND_AFTER_CURSHNDLR = 1337; +exports.ER_SP_CURSOR_AFTER_HANDLER = 1338; +exports.ER_SP_CASE_NOT_FOUND = 1339; +exports.ER_FPARSER_TOO_BIG_FILE = 1340; +exports.ER_FPARSER_BAD_HEADER = 1341; +exports.ER_FPARSER_EOF_IN_COMMENT = 1342; +exports.ER_FPARSER_ERROR_IN_PARAMETER = 1343; +exports.ER_FPARSER_EOF_IN_UNKNOWN_PARAMETER = 1344; +exports.ER_VIEW_NO_EXPLAIN = 1345; +exports.ER_FRM_UNKNOWN_TYPE = 1346; +exports.ER_WRONG_OBJECT = 1347; +exports.ER_NONUPDATEABLE_COLUMN = 1348; +exports.ER_VIEW_SELECT_DERIVED = 1349; +exports.ER_VIEW_SELECT_CLAUSE = 1350; +exports.ER_VIEW_SELECT_VARIABLE = 1351; +exports.ER_VIEW_SELECT_TMPTABLE = 1352; +exports.ER_VIEW_WRONG_LIST = 1353; +exports.ER_WARN_VIEW_MERGE = 1354; +exports.ER_WARN_VIEW_WITHOUT_KEY = 1355; +exports.ER_VIEW_INVALID = 1356; +exports.ER_SP_NO_DROP_SP = 1357; +exports.ER_SP_GOTO_IN_HNDLR = 1358; +exports.ER_TRG_ALREADY_EXISTS = 1359; +exports.ER_TRG_DOES_NOT_EXIST = 1360; +exports.ER_TRG_ON_VIEW_OR_TEMP_TABLE = 1361; +exports.ER_TRG_CANT_CHANGE_ROW = 1362; +exports.ER_TRG_NO_SUCH_ROW_IN_TRG = 1363; +exports.ER_NO_DEFAULT_FOR_FIELD = 1364; +exports.ER_DIVISION_BY_ZERO = 1365; +exports.ER_TRUNCATED_WRONG_VALUE_FOR_FIELD = 1366; +exports.ER_ILLEGAL_VALUE_FOR_TYPE = 1367; +exports.ER_VIEW_NONUPD_CHECK = 1368; +exports.ER_VIEW_CHECK_FAILED = 1369; +exports.ER_PROCACCESS_DENIED_ERROR = 1370; +exports.ER_RELAY_LOG_FAIL = 1371; +exports.ER_PASSWD_LENGTH = 1372; +exports.ER_UNKNOWN_TARGET_BINLOG = 1373; +exports.ER_IO_ERR_LOG_INDEX_READ = 1374; +exports.ER_BINLOG_PURGE_PROHIBITED = 1375; +exports.ER_FSEEK_FAIL = 1376; +exports.ER_BINLOG_PURGE_FATAL_ERR = 1377; +exports.ER_LOG_IN_USE = 1378; +exports.ER_LOG_PURGE_UNKNOWN_ERR = 1379; +exports.ER_RELAY_LOG_INIT = 1380; +exports.ER_NO_BINARY_LOGGING = 1381; +exports.ER_RESERVED_SYNTAX = 1382; +exports.ER_WSAS_FAILED = 1383; +exports.ER_DIFF_GROUPS_PROC = 1384; +exports.ER_NO_GROUP_FOR_PROC = 1385; +exports.ER_ORDER_WITH_PROC = 1386; +exports.ER_LOGGING_PROHIBIT_CHANGING_OF = 1387; +exports.ER_NO_FILE_MAPPING = 1388; +exports.ER_WRONG_MAGIC = 1389; +exports.ER_PS_MANY_PARAM = 1390; +exports.ER_KEY_PART_ = 1391; +exports.ER_VIEW_CHECKSUM = 1392; +exports.ER_VIEW_MULTIUPDATE = 1393; +exports.ER_VIEW_NO_INSERT_FIELD_LIST = 1394; +exports.ER_VIEW_DELETE_MERGE_VIEW = 1395; +exports.ER_CANNOT_USER = 1396; +exports.ER_XAER_NOTA = 1397; +exports.ER_XAER_INVAL = 1398; +exports.ER_XAER_RMFAIL = 1399; +exports.ER_XAER_OUTSIDE = 1400; +exports.ER_XAER_RMERR = 1401; +exports.ER_XA_RBROLLBACK = 1402; +exports.ER_NONEXISTING_PROC_GRANT = 1403; +exports.ER_PROC_AUTO_GRANT_FAIL = 1404; +exports.ER_PROC_AUTO_REVOKE_FAIL = 1405; +exports.ER_DATA_TOO_LONG = 1406; +exports.ER_SP_BAD_SQLSTATE = 1407; +exports.ER_STARTUP = 1408; +exports.ER_LOAD_FROM_FIXED_SIZE_ROWS_TO_VAR = 1409; +exports.ER_CANT_CREATE_USER_WITH_GRANT = 1410; +exports.ER_WRONG_VALUE_FOR_TYPE = 1411; +exports.ER_TABLE_DEF_CHANGED = 1412; +exports.ER_SP_DUP_HANDLER = 1413; +exports.ER_SP_NOT_VAR_ARG = 1414; +exports.ER_SP_NO_RETSET = 1415; +exports.ER_CANT_CREATE_GEOMETRY_OBJECT = 1416; +exports.ER_FAILED_ROUTINE_BREAK_BINLOG = 1417; +exports.ER_BINLOG_UNSAFE_ROUTINE = 1418; +exports.ER_BINLOG_CREATE_ROUTINE_NEED_SUPER = 1419; +exports.ER_EXEC_STMT_WITH_OPEN_CURSOR = 1420; +exports.ER_STMT_HAS_NO_OPEN_CURSOR = 1421; +exports.ER_COMMIT_NOT_ALLOWED_IN_SF_OR_TRG = 1422; +exports.ER_NO_DEFAULT_FOR_VIEW_FIELD = 1423; +exports.ER_SP_NO_RECURSION = 1424; +exports.ER_TOO_BIG_SCALE = 1425; +exports.ER_TOO_BIG_PRECISION = 1426; +exports.ER_M_BIGGER_THAN_D = 1427; +exports.ER_WRONG_LOCK_OF_SYSTEM_TABLE = 1428; +exports.ER_CONNECT_TO_FOREIGN_DATA_SOURCE = 1429; +exports.ER_QUERY_ON_FOREIGN_DATA_SOURCE = 1430; +exports.ER_FOREIGN_DATA_SOURCE_DOESNT_EXIST = 1431; +exports.ER_FOREIGN_DATA_STRING_INVALID_CANT_CREATE = 1432; +exports.ER_FOREIGN_DATA_STRING_INVALID = 1433; +exports.ER_CANT_CREATE_FEDERATED_TABLE = 1434; +exports.ER_TRG_IN_WRONG_SCHEMA = 1435; +exports.ER_STACK_OVERRUN_NEED_MORE = 1436; +exports.ER_TOO_LONG_BODY = 1437; +exports.ER_WARN_CANT_DROP_DEFAULT_KEYCACHE = 1438; +exports.ER_TOO_BIG_DISPLAYWIDTH = 1439; +exports.ER_XAER_DUPID = 1440; +exports.ER_DATETIME_FUNCTION_OVERFLOW = 1441; +exports.ER_CANT_UPDATE_USED_TABLE_IN_SF_OR_TRG = 1442; +exports.ER_VIEW_PREVENT_UPDATE = 1443; +exports.ER_PS_NO_RECURSION = 1444; +exports.ER_SP_CANT_SET_AUTOCOMMIT = 1445; +exports.ER_MALFORMED_DEFINER = 1446; +exports.ER_VIEW_FRM_NO_USER = 1447; +exports.ER_VIEW_OTHER_USER = 1448; +exports.ER_NO_SUCH_USER = 1449; +exports.ER_FORBID_SCHEMA_CHANGE = 1450; +exports.ER_ROW_IS_REFERENCED_ = 1451; +exports.ER_NO_REFERENCED_ROW_ = 1452; +exports.ER_SP_BAD_VAR_SHADOW = 1453; +exports.ER_TRG_NO_DEFINER = 1454; +exports.ER_OLD_FILE_FORMAT = 1455; +exports.ER_SP_RECURSION_LIMIT = 1456; +exports.ER_SP_PROC_TABLE_CORRUPT = 1457; +exports.ER_SP_WRONG_NAME = 1458; +exports.ER_TABLE_NEEDS_UPGRADE = 1459; +exports.ER_SP_NO_AGGREGATE = 1460; +exports.ER_MAX_PREPARED_STMT_COUNT_REACHED = 1461; +exports.ER_VIEW_RECURSIVE = 1462; +exports.ER_NON_GROUPING_FIELD_USED = 1463; +exports.ER_TABLE_CANT_HANDLE_SPKEYS = 1464; +exports.ER_NO_TRIGGERS_ON_SYSTEM_SCHEMA = 1465; +exports.ER_REMOVED_SPACES = 1466; +exports.ER_AUTOINC_READ_FAILED = 1467; +exports.ER_USERNAME = 1468; +exports.ER_HOSTNAME = 1469; +exports.ER_WRONG_STRING_LENGTH = 1470; +exports.ER_NON_INSERTABLE_TABLE = 1471; +exports.ER_ADMIN_WRONG_MRG_TABLE = 1472; +exports.ER_TOO_HIGH_LEVEL_OF_NESTING_FOR_SELECT = 1473; +exports.ER_NAME_BECOMES_EMPTY = 1474; +exports.ER_AMBIGUOUS_FIELD_TERM = 1475; +exports.ER_FOREIGN_SERVER_EXISTS = 1476; +exports.ER_FOREIGN_SERVER_DOESNT_EXIST = 1477; +exports.ER_ILLEGAL_HA_CREATE_OPTION = 1478; +exports.ER_PARTITION_REQUIRES_VALUES_ERROR = 1479; +exports.ER_PARTITION_WRONG_VALUES_ERROR = 1480; +exports.ER_PARTITION_MAXVALUE_ERROR = 1481; +exports.ER_PARTITION_SUBPARTITION_ERROR = 1482; +exports.ER_PARTITION_SUBPART_MIX_ERROR = 1483; +exports.ER_PARTITION_WRONG_NO_PART_ERROR = 1484; +exports.ER_PARTITION_WRONG_NO_SUBPART_ERROR = 1485; +exports.ER_WRONG_EXPR_IN_PARTITION_FUNC_ERROR = 1486; +exports.ER_NO_CONST_EXPR_IN_RANGE_OR_LIST_ERROR = 1487; +exports.ER_FIELD_NOT_FOUND_PART_ERROR = 1488; +exports.ER_LIST_OF_FIELDS_ONLY_IN_HASH_ERROR = 1489; +exports.ER_INCONSISTENT_PARTITION_INFO_ERROR = 1490; +exports.ER_PARTITION_FUNC_NOT_ALLOWED_ERROR = 1491; +exports.ER_PARTITIONS_MUST_BE_DEFINED_ERROR = 1492; +exports.ER_RANGE_NOT_INCREASING_ERROR = 1493; +exports.ER_INCONSISTENT_TYPE_OF_FUNCTIONS_ERROR = 1494; +exports.ER_MULTIPLE_DEF_CONST_IN_LIST_PART_ERROR = 1495; +exports.ER_PARTITION_ENTRY_ERROR = 1496; +exports.ER_MIX_HANDLER_ERROR = 1497; +exports.ER_PARTITION_NOT_DEFINED_ERROR = 1498; +exports.ER_TOO_MANY_PARTITIONS_ERROR = 1499; +exports.ER_SUBPARTITION_ERROR = 1500; +exports.ER_CANT_CREATE_HANDLER_FILE = 1501; +exports.ER_BLOB_FIELD_IN_PART_FUNC_ERROR = 1502; +exports.ER_UNIQUE_KEY_NEED_ALL_FIELDS_IN_PF = 1503; +exports.ER_NO_PARTS_ERROR = 1504; +exports.ER_PARTITION_MGMT_ON_NONPARTITIONED = 1505; +exports.ER_FOREIGN_KEY_ON_PARTITIONED = 1506; +exports.ER_DROP_PARTITION_NON_EXISTENT = 1507; +exports.ER_DROP_LAST_PARTITION = 1508; +exports.ER_COALESCE_ONLY_ON_HASH_PARTITION = 1509; +exports.ER_REORG_HASH_ONLY_ON_SAME_NO = 1510; +exports.ER_REORG_NO_PARAM_ERROR = 1511; +exports.ER_ONLY_ON_RANGE_LIST_PARTITION = 1512; +exports.ER_ADD_PARTITION_SUBPART_ERROR = 1513; +exports.ER_ADD_PARTITION_NO_NEW_PARTITION = 1514; +exports.ER_COALESCE_PARTITION_NO_PARTITION = 1515; +exports.ER_REORG_PARTITION_NOT_EXIST = 1516; +exports.ER_SAME_NAME_PARTITION = 1517; +exports.ER_NO_BINLOG_ERROR = 1518; +exports.ER_CONSECUTIVE_REORG_PARTITIONS = 1519; +exports.ER_REORG_OUTSIDE_RANGE = 1520; +exports.ER_PARTITION_FUNCTION_FAILURE = 1521; +exports.ER_PART_STATE_ERROR = 1522; +exports.ER_LIMITED_PART_RANGE = 1523; +exports.ER_PLUGIN_IS_NOT_LOADED = 1524; +exports.ER_WRONG_VALUE = 1525; +exports.ER_NO_PARTITION_FOR_GIVEN_VALUE = 1526; +exports.ER_FILEGROUP_OPTION_ONLY_ONCE = 1527; +exports.ER_CREATE_FILEGROUP_FAILED = 1528; +exports.ER_DROP_FILEGROUP_FAILED = 1529; +exports.ER_TABLESPACE_AUTO_EXTEND_ERROR = 1530; +exports.ER_WRONG_SIZE_NUMBER = 1531; +exports.ER_SIZE_OVERFLOW_ERROR = 1532; +exports.ER_ALTER_FILEGROUP_FAILED = 1533; +exports.ER_BINLOG_ROW_LOGGING_FAILED = 1534; +exports.ER_BINLOG_ROW_WRONG_TABLE_DEF = 1535; +exports.ER_BINLOG_ROW_RBR_TO_SBR = 1536; +exports.ER_EVENT_ALREADY_EXISTS = 1537; +exports.ER_EVENT_STORE_FAILED = 1538; +exports.ER_EVENT_DOES_NOT_EXIST = 1539; +exports.ER_EVENT_CANT_ALTER = 1540; +exports.ER_EVENT_DROP_FAILED = 1541; +exports.ER_EVENT_INTERVAL_NOT_POSITIVE_OR_TOO_BIG = 1542; +exports.ER_EVENT_ENDS_BEFORE_STARTS = 1543; +exports.ER_EVENT_EXEC_TIME_IN_THE_PAST = 1544; +exports.ER_EVENT_OPEN_TABLE_FAILED = 1545; +exports.ER_EVENT_NEITHER_M_EXPR_NOR_M_AT = 1546; +exports.ER_COL_COUNT_DOESNT_MATCH_CORRUPTED = 1547; +exports.ER_CANNOT_LOAD_FROM_TABLE = 1548; +exports.ER_EVENT_CANNOT_DELETE = 1549; +exports.ER_EVENT_COMPILE_ERROR = 1550; +exports.ER_EVENT_SAME_NAME = 1551; +exports.ER_EVENT_DATA_TOO_LONG = 1552; +exports.ER_DROP_INDEX_FK = 1553; +exports.ER_WARN_DEPRECATED_SYNTAX_WITH_VER = 1554; +exports.ER_CANT_WRITE_LOCK_LOG_TABLE = 1555; +exports.ER_CANT_LOCK_LOG_TABLE = 1556; +exports.ER_FOREIGN_DUPLICATE_KEY = 1557; +exports.ER_COL_COUNT_DOESNT_MATCH_PLEASE_UPDATE = 1558; +exports.ER_TEMP_TABLE_PREVENTS_SWITCH_OUT_OF_RBR = 1559; +exports.ER_STORED_FUNCTION_PREVENTS_SWITCH_BINLOG_FORMAT = 1560; +exports.ER_NDB_CANT_SWITCH_BINLOG_FORMAT = 1561; +exports.ER_PARTITION_NO_TEMPORARY = 1562; +exports.ER_PARTITION_CONST_DOMAIN_ERROR = 1563; +exports.ER_PARTITION_FUNCTION_IS_NOT_ALLOWED = 1564; +exports.ER_DDL_LOG_ERROR = 1565; +exports.ER_NULL_IN_VALUES_LESS_THAN = 1566; +exports.ER_WRONG_PARTITION_NAME = 1567; +exports.ER_CANT_CHANGE_TX_CHARACTERISTICS = 1568; +exports.ER_DUP_ENTRY_AUTOINCREMENT_CASE = 1569; +exports.ER_EVENT_MODIFY_QUEUE_ERROR = 1570; +exports.ER_EVENT_SET_VAR_ERROR = 1571; +exports.ER_PARTITION_MERGE_ERROR = 1572; +exports.ER_CANT_ACTIVATE_LOG = 1573; +exports.ER_RBR_NOT_AVAILABLE = 1574; +exports.ER_BASE = 1575; +exports.ER_EVENT_RECURSION_FORBIDDEN = 1576; +exports.ER_EVENTS_DB_ERROR = 1577; +exports.ER_ONLY_INTEGERS_ALLOWED = 1578; +exports.ER_UNSUPORTED_LOG_ENGINE = 1579; +exports.ER_BAD_LOG_STATEMENT = 1580; +exports.ER_CANT_RENAME_LOG_TABLE = 1581; +exports.ER_WRONG_PARAMCOUNT_TO_NATIVE_FCT = 1582; +exports.ER_WRONG_PARAMETERS_TO_NATIVE_FCT = 1583; +exports.ER_WRONG_PARAMETERS_TO_STORED_FCT = 1584; +exports.ER_NATIVE_FCT_NAME_COLLISION = 1585; +exports.ER_DUP_ENTRY_WITH_KEY_NAME = 1586; +exports.ER_BINLOG_PURGE_EMFILE = 1587; +exports.ER_EVENT_CANNOT_CREATE_IN_THE_PAST = 1588; +exports.ER_EVENT_CANNOT_ALTER_IN_THE_PAST = 1589; +exports.ER_SLAVE_INCIDENT = 1590; +exports.ER_NO_PARTITION_FOR_GIVEN_VALUE_SILENT = 1591; +exports.ER_BINLOG_UNSAFE_STATEMENT = 1592; +exports.ER_SLAVE_FATAL_ERROR = 1593; +exports.ER_SLAVE_RELAY_LOG_READ_FAILURE = 1594; +exports.ER_SLAVE_RELAY_LOG_WRITE_FAILURE = 1595; +exports.ER_SLAVE_CREATE_EVENT_FAILURE = 1596; +exports.ER_SLAVE_MASTER_COM_FAILURE = 1597; +exports.ER_BINLOG_LOGGING_IMPOSSIBLE = 1598; +exports.ER_VIEW_NO_CREATION_CTX = 1599; +exports.ER_VIEW_INVALID_CREATION_CTX = 1600; +exports.ER_SR_INVALID_CREATION_CTX = 1601; +exports.ER_TRG_CORRUPTED_FILE = 1602; +exports.ER_TRG_NO_CREATION_CTX = 1603; +exports.ER_TRG_INVALID_CREATION_CTX = 1604; +exports.ER_EVENT_INVALID_CREATION_CTX = 1605; +exports.ER_TRG_CANT_OPEN_TABLE = 1606; +exports.ER_CANT_CREATE_SROUTINE = 1607; +exports.ER_NEVER_USED = 1608; +exports.ER_NO_FORMAT_DESCRIPTION_EVENT_BEFORE_BINLOG_STATEMENT = 1609; +exports.ER_SLAVE_CORRUPT_EVENT = 1610; +exports.ER_LOAD_DATA_INVALID_COLUMN = 1611; +exports.ER_LOG_PURGE_NO_FILE = 1612; +exports.ER_XA_RBTIMEOUT = 1613; +exports.ER_XA_RBDEADLOCK = 1614; +exports.ER_NEED_REPREPARE = 1615; +exports.ER_DELAYED_NOT_SUPPORTED = 1616; +exports.WARN_NO_MASTER_INFO = 1617; +exports.WARN_OPTION_IGNORED = 1618; +exports.WARN_PLUGIN_DELETE_BUILTIN = 1619; +exports.WARN_PLUGIN_BUSY = 1620; +exports.ER_VARIABLE_IS_READONLY = 1621; +exports.ER_WARN_ENGINE_TRANSACTION_ROLLBACK = 1622; +exports.ER_SLAVE_HEARTBEAT_FAILURE = 1623; +exports.ER_SLAVE_HEARTBEAT_VALUE_OUT_OF_RANGE = 1624; +exports.ER_NDB_REPLICATION_SCHEMA_ERROR = 1625; +exports.ER_CONFLICT_FN_PARSE_ERROR = 1626; +exports.ER_EXCEPTIONS_WRITE_ERROR = 1627; +exports.ER_TOO_LONG_TABLE_COMMENT = 1628; +exports.ER_TOO_LONG_FIELD_COMMENT = 1629; +exports.ER_FUNC_INEXISTENT_NAME_COLLISION = 1630; +exports.ER_DATABASE_NAME = 1631; +exports.ER_TABLE_NAME = 1632; +exports.ER_PARTITION_NAME = 1633; +exports.ER_SUBPARTITION_NAME = 1634; +exports.ER_TEMPORARY_NAME = 1635; +exports.ER_RENAMED_NAME = 1636; +exports.ER_TOO_MANY_CONCURRENT_TRXS = 1637; +exports.WARN_NON_ASCII_SEPARATOR_NOT_IMPLEMENTED = 1638; +exports.ER_DEBUG_SYNC_TIMEOUT = 1639; +exports.ER_DEBUG_SYNC_HIT_LIMIT = 1640; +exports.ER_DUP_SIGNAL_SET = 1641; +exports.ER_SIGNAL_WARN = 1642; +exports.ER_SIGNAL_NOT_FOUND = 1643; +exports.ER_SIGNAL_EXCEPTION = 1644; +exports.ER_RESIGNAL_WITHOUT_ACTIVE_HANDLER = 1645; +exports.ER_SIGNAL_BAD_CONDITION_TYPE = 1646; +exports.WARN_COND_ITEM_TRUNCATED = 1647; +exports.ER_COND_ITEM_TOO_LONG = 1648; +exports.ER_UNKNOWN_LOCALE = 1649; +exports.ER_SLAVE_IGNORE_SERVER_IDS = 1650; +exports.ER_QUERY_CACHE_DISABLED = 1651; +exports.ER_SAME_NAME_PARTITION_FIELD = 1652; +exports.ER_PARTITION_COLUMN_LIST_ERROR = 1653; +exports.ER_WRONG_TYPE_COLUMN_VALUE_ERROR = 1654; +exports.ER_TOO_MANY_PARTITION_FUNC_FIELDS_ERROR = 1655; +exports.ER_MAXVALUE_IN_VALUES_IN = 1656; +exports.ER_TOO_MANY_VALUES_ERROR = 1657; +exports.ER_ROW_SINGLE_PARTITION_FIELD_ERROR = 1658; +exports.ER_FIELD_TYPE_NOT_ALLOWED_AS_PARTITION_FIELD = 1659; +exports.ER_PARTITION_FIELDS_TOO_LONG = 1660; +exports.ER_BINLOG_ROW_ENGINE_AND_STMT_ENGINE = 1661; +exports.ER_BINLOG_ROW_MODE_AND_STMT_ENGINE = 1662; +exports.ER_BINLOG_UNSAFE_AND_STMT_ENGINE = 1663; +exports.ER_BINLOG_ROW_INJECTION_AND_STMT_ENGINE = 1664; +exports.ER_BINLOG_STMT_MODE_AND_ROW_ENGINE = 1665; +exports.ER_BINLOG_ROW_INJECTION_AND_STMT_MODE = 1666; +exports.ER_BINLOG_MULTIPLE_ENGINES_AND_SELF_LOGGING_ENGINE = 1667; +exports.ER_BINLOG_UNSAFE_LIMIT = 1668; +exports.ER_BINLOG_UNSAFE_INSERT_DELAYED = 1669; +exports.ER_BINLOG_UNSAFE_SYSTEM_TABLE = 1670; +exports.ER_BINLOG_UNSAFE_AUTOINC_COLUMNS = 1671; +exports.ER_BINLOG_UNSAFE_UDF = 1672; +exports.ER_BINLOG_UNSAFE_SYSTEM_VARIABLE = 1673; +exports.ER_BINLOG_UNSAFE_SYSTEM_FUNCTION = 1674; +exports.ER_BINLOG_UNSAFE_NONTRANS_AFTER_TRANS = 1675; +exports.ER_MESSAGE_AND_STATEMENT = 1676; +exports.ER_SLAVE_CONVERSION_FAILED = 1677; +exports.ER_SLAVE_CANT_CREATE_CONVERSION = 1678; +exports.ER_INSIDE_TRANSACTION_PREVENTS_SWITCH_BINLOG_FORMAT = 1679; +exports.ER_PATH_LENGTH = 1680; +exports.ER_WARN_DEPRECATED_SYNTAX_NO_REPLACEMENT = 1681; +exports.ER_WRONG_NATIVE_TABLE_STRUCTURE = 1682; +exports.ER_WRONG_PERFSCHEMA_USAGE = 1683; +exports.ER_WARN_I_S_SKIPPED_TABLE = 1684; +exports.ER_INSIDE_TRANSACTION_PREVENTS_SWITCH_BINLOG_DIRECT = 1685; +exports.ER_STORED_FUNCTION_PREVENTS_SWITCH_BINLOG_DIRECT = 1686; +exports.ER_SPATIAL_MUST_HAVE_GEOM_COL = 1687; +exports.ER_TOO_LONG_INDEX_COMMENT = 1688; +exports.ER_LOCK_ABORTED = 1689; +exports.ER_DATA_OUT_OF_RANGE = 1690; +exports.ER_WRONG_SPVAR_TYPE_IN_LIMIT = 1691; +exports.ER_BINLOG_UNSAFE_MULTIPLE_ENGINES_AND_SELF_LOGGING_ENGINE = 1692; +exports.ER_BINLOG_UNSAFE_MIXED_STATEMENT = 1693; +exports.ER_INSIDE_TRANSACTION_PREVENTS_SWITCH_SQL_LOG_BIN = 1694; +exports.ER_STORED_FUNCTION_PREVENTS_SWITCH_SQL_LOG_BIN = 1695; +exports.ER_FAILED_READ_FROM_PAR_FILE = 1696; +exports.ER_VALUES_IS_NOT_INT_TYPE_ERROR = 1697; +exports.ER_ACCESS_DENIED_NO_PASSWORD_ERROR = 1698; +exports.ER_SET_PASSWORD_AUTH_PLUGIN = 1699; +exports.ER_GRANT_PLUGIN_USER_EXISTS = 1700; +exports.ER_TRUNCATE_ILLEGAL_FK = 1701; +exports.ER_PLUGIN_IS_PERMANENT = 1702; +exports.ER_SLAVE_HEARTBEAT_VALUE_OUT_OF_RANGE_MIN = 1703; +exports.ER_SLAVE_HEARTBEAT_VALUE_OUT_OF_RANGE_MAX = 1704; +exports.ER_STMT_CACHE_FULL = 1705; +exports.ER_MULTI_UPDATE_KEY_CONFLICT = 1706; +exports.ER_TABLE_NEEDS_REBUILD = 1707; +exports.WARN_OPTION_BELOW_LIMIT = 1708; +exports.ER_INDEX_COLUMN_TOO_LONG = 1709; +exports.ER_ERROR_IN_TRIGGER_BODY = 1710; +exports.ER_ERROR_IN_UNKNOWN_TRIGGER_BODY = 1711; +exports.ER_INDEX_CORRUPT = 1712; +exports.ER_UNDO_RECORD_TOO_BIG = 1713; +exports.ER_BINLOG_UNSAFE_INSERT_IGNORE_SELECT = 1714; +exports.ER_BINLOG_UNSAFE_INSERT_SELECT_UPDATE = 1715; +exports.ER_BINLOG_UNSAFE_REPLACE_SELECT = 1716; +exports.ER_BINLOG_UNSAFE_CREATE_IGNORE_SELECT = 1717; +exports.ER_BINLOG_UNSAFE_CREATE_REPLACE_SELECT = 1718; +exports.ER_BINLOG_UNSAFE_UPDATE_IGNORE = 1719; +exports.ER_PLUGIN_NO_UNINSTALL = 1720; +exports.ER_PLUGIN_NO_INSTALL = 1721; +exports.ER_BINLOG_UNSAFE_WRITE_AUTOINC_SELECT = 1722; +exports.ER_BINLOG_UNSAFE_CREATE_SELECT_AUTOINC = 1723; +exports.ER_BINLOG_UNSAFE_INSERT_TWO_KEYS = 1724; +exports.ER_TABLE_IN_FK_CHECK = 1725; +exports.ER_UNSUPPORTED_ENGINE = 1726; +exports.ER_BINLOG_UNSAFE_AUTOINC_NOT_FIRST = 1727; +exports.ER_CANNOT_LOAD_FROM_TABLE_V = 1728; +exports.ER_MASTER_DELAY_VALUE_OUT_OF_RANGE = 1729; +exports.ER_ONLY_FD_AND_RBR_EVENTS_ALLOWED_IN_BINLOG_STATEMENT = 1730; +exports.ER_PARTITION_EXCHANGE_DIFFERENT_OPTION = 1731; +exports.ER_PARTITION_EXCHANGE_PART_TABLE = 1732; +exports.ER_PARTITION_EXCHANGE_TEMP_TABLE = 1733; +exports.ER_PARTITION_INSTEAD_OF_SUBPARTITION = 1734; +exports.ER_UNKNOWN_PARTITION = 1735; +exports.ER_TABLES_DIFFERENT_METADATA = 1736; +exports.ER_ROW_DOES_NOT_MATCH_PARTITION = 1737; +exports.ER_BINLOG_CACHE_SIZE_GREATER_THAN_MAX = 1738; +exports.ER_WARN_INDEX_NOT_APPLICABLE = 1739; +exports.ER_PARTITION_EXCHANGE_FOREIGN_KEY = 1740; +exports.ER_NO_SUCH_KEY_VALUE = 1741; +exports.ER_RPL_INFO_DATA_TOO_LONG = 1742; +exports.ER_NETWORK_READ_EVENT_CHECKSUM_FAILURE = 1743; +exports.ER_BINLOG_READ_EVENT_CHECKSUM_FAILURE = 1744; +exports.ER_BINLOG_STMT_CACHE_SIZE_GREATER_THAN_MAX = 1745; +exports.ER_CANT_UPDATE_TABLE_IN_CREATE_TABLE_SELECT = 1746; +exports.ER_PARTITION_CLAUSE_ON_NONPARTITIONED = 1747; +exports.ER_ROW_DOES_NOT_MATCH_GIVEN_PARTITION_SET = 1748; +exports.ER_NO_SUCH_PARTITION = 1749; +exports.ER_CHANGE_RPL_INFO_REPOSITORY_FAILURE = 1750; +exports.ER_WARNING_NOT_COMPLETE_ROLLBACK_WITH_CREATED_TEMP_TABLE = 1751; +exports.ER_WARNING_NOT_COMPLETE_ROLLBACK_WITH_DROPPED_TEMP_TABLE = 1752; +exports.ER_MTS_FEATURE_IS_NOT_SUPPORTED = 1753; +exports.ER_MTS_UPDATED_DBS_GREATER_MAX = 1754; +exports.ER_MTS_CANT_PARALLEL = 1755; +exports.ER_MTS_INCONSISTENT_DATA = 1756; +exports.ER_FULLTEXT_NOT_SUPPORTED_WITH_PARTITIONING = 1757; +exports.ER_DA_INVALID_CONDITION_NUMBER = 1758; +exports.ER_INSECURE_PLAIN_TEXT = 1759; +exports.ER_INSECURE_CHANGE_MASTER = 1760; +exports.ER_FOREIGN_DUPLICATE_KEY_WITH_CHILD_INFO = 1761; +exports.ER_FOREIGN_DUPLICATE_KEY_WITHOUT_CHILD_INFO = 1762; +exports.ER_SQLTHREAD_WITH_SECURE_SLAVE = 1763; +exports.ER_TABLE_HAS_NO_FT = 1764; +exports.ER_VARIABLE_NOT_SETTABLE_IN_SF_OR_TRIGGER = 1765; +exports.ER_VARIABLE_NOT_SETTABLE_IN_TRANSACTION = 1766; +exports.ER_GTID_NEXT_IS_NOT_IN_GTID_NEXT_LIST = 1767; +exports.ER_CANT_CHANGE_GTID_NEXT_IN_TRANSACTION_WHEN_GTID_NEXT_LIST_IS_NULL = 1768; +exports.ER_SET_STATEMENT_CANNOT_INVOKE_FUNCTION = 1769; +exports.ER_GTID_NEXT_CANT_BE_AUTOMATIC_IF_GTID_NEXT_LIST_IS_NON_NULL = 1770; +exports.ER_SKIPPING_LOGGED_TRANSACTION = 1771; +exports.ER_MALFORMED_GTID_SET_SPECIFICATION = 1772; +exports.ER_MALFORMED_GTID_SET_ENCODING = 1773; +exports.ER_MALFORMED_GTID_SPECIFICATION = 1774; +exports.ER_GNO_EXHAUSTED = 1775; +exports.ER_BAD_SLAVE_AUTO_POSITION = 1776; +exports.ER_AUTO_POSITION_REQUIRES_GTID_MODE_ON = 1777; +exports.ER_CANT_DO_IMPLICIT_COMMIT_IN_TRX_WHEN_GTID_NEXT_IS_SET = 1778; +exports.ER_GTID_MODE_ = 1779; +exports.ER_GTID_MODE_REQUIRES_BINLOG = 1780; +exports.ER_CANT_SET_GTID_NEXT_TO_GTID_WHEN_GTID_MODE_IS_OFF = 1781; +exports.ER_CANT_SET_GTID_NEXT_TO_ANONYMOUS_WHEN_GTID_MODE_IS_ON = 1782; +exports.ER_CANT_SET_GTID_NEXT_LIST_TO_NON_NULL_WHEN_GTID_MODE_IS_OFF = 1783; +exports.ER_FOUND_GTID_EVENT_WHEN_GTID_MODE_IS_OFF = 1784; +exports.ER_GTID_UNSAFE_NON_TRANSACTIONAL_TABLE = 1785; +exports.ER_GTID_UNSAFE_CREATE_SELECT = 1786; +exports.ER_GTID_UNSAFE_CREATE_DROP_TEMPORARY_TABLE_IN_TRANSACTION = 1787; +exports.ER_GTID_MODE_CAN_ONLY_CHANGE_ONE_STEP_AT_A_TIME = 1788; +exports.ER_MASTER_HAS_PURGED_REQUIRED_GTIDS = 1789; +exports.ER_CANT_SET_GTID_NEXT_WHEN_OWNING_GTID = 1790; +exports.ER_UNKNOWN_EXPLAIN_FORMAT = 1791; +exports.ER_CANT_EXECUTE_IN_READ_ONLY_TRANSACTION = 1792; +exports.ER_TOO_LONG_TABLE_PARTITION_COMMENT = 1793; +exports.ER_SLAVE_CONFIGURATION = 1794; +exports.ER_INNODB_FT_LIMIT = 1795; +exports.ER_INNODB_NO_FT_TEMP_TABLE = 1796; +exports.ER_INNODB_FT_WRONG_DOCID_COLUMN = 1797; +exports.ER_INNODB_FT_WRONG_DOCID_INDEX = 1798; +exports.ER_INNODB_ONLINE_LOG_TOO_BIG = 1799; +exports.ER_UNKNOWN_ALTER_ALGORITHM = 1800; +exports.ER_UNKNOWN_ALTER_LOCK = 1801; +exports.ER_MTS_CHANGE_MASTER_CANT_RUN_WITH_GAPS = 1802; +exports.ER_MTS_RECOVERY_FAILURE = 1803; +exports.ER_MTS_RESET_WORKERS = 1804; +exports.ER_COL_COUNT_DOESNT_MATCH_CORRUPTED_V = 1805; +exports.ER_SLAVE_SILENT_RETRY_TRANSACTION = 1806; +exports.ER_DISCARD_FK_CHECKS_RUNNING = 1807; +exports.ER_TABLE_SCHEMA_MISMATCH = 1808; +exports.ER_TABLE_IN_SYSTEM_TABLESPACE = 1809; +exports.ER_IO_READ_ERROR = 1810; +exports.ER_IO_WRITE_ERROR = 1811; +exports.ER_TABLESPACE_MISSING = 1812; +exports.ER_TABLESPACE_EXISTS = 1813; +exports.ER_TABLESPACE_DISCARDED = 1814; +exports.ER_INTERNAL_ERROR = 1815; +exports.ER_INNODB_IMPORT_ERROR = 1816; +exports.ER_INNODB_INDEX_CORRUPT = 1817; +exports.ER_INVALID_YEAR_COLUMN_LENGTH = 1818; +exports.ER_NOT_VALID_PASSWORD = 1819; +exports.ER_MUST_CHANGE_PASSWORD = 1820; +exports.ER_FK_NO_INDEX_CHILD = 1821; +exports.ER_FK_NO_INDEX_PARENT = 1822; +exports.ER_FK_FAIL_ADD_SYSTEM = 1823; +exports.ER_FK_CANNOT_OPEN_PARENT = 1824; +exports.ER_FK_INCORRECT_OPTION = 1825; +exports.ER_FK_DUP_NAME = 1826; +exports.ER_PASSWORD_FORMAT = 1827; +exports.ER_FK_COLUMN_CANNOT_DROP = 1828; +exports.ER_FK_COLUMN_CANNOT_DROP_CHILD = 1829; +exports.ER_FK_COLUMN_NOT_NULL = 1830; +exports.ER_DUP_INDEX = 1831; +exports.ER_FK_COLUMN_CANNOT_CHANGE = 1832; +exports.ER_FK_COLUMN_CANNOT_CHANGE_CHILD = 1833; +exports.ER_FK_CANNOT_DELETE_PARENT = 1834; +exports.ER_MALFORMED_PACKET = 1835; +exports.ER_READ_ONLY_MODE = 1836; +exports.ER_GTID_NEXT_TYPE_UNDEFINED_GROUP = 1837; +exports.ER_VARIABLE_NOT_SETTABLE_IN_SP = 1838; +exports.ER_CANT_SET_GTID_PURGED_WHEN_GTID_MODE_IS_OFF = 1839; +exports.ER_CANT_SET_GTID_PURGED_WHEN_GTID_EXECUTED_IS_NOT_EMPTY = 1840; +exports.ER_CANT_SET_GTID_PURGED_WHEN_OWNED_GTIDS_IS_NOT_EMPTY = 1841; +exports.ER_GTID_PURGED_WAS_CHANGED = 1842; +exports.ER_GTID_EXECUTED_WAS_CHANGED = 1843; +exports.ER_BINLOG_STMT_MODE_AND_NO_REPL_TABLES = 1844; +exports.ER_ALTER_OPERATION_NOT_SUPPORTED = 1845; +exports.ER_ALTER_OPERATION_NOT_SUPPORTED_REASON = 1846; +exports.ER_ALTER_OPERATION_NOT_SUPPORTED_REASON_COPY = 1847; +exports.ER_ALTER_OPERATION_NOT_SUPPORTED_REASON_PARTITION = 1848; +exports.ER_ALTER_OPERATION_NOT_SUPPORTED_REASON_FK_RENAME = 1849; +exports.ER_ALTER_OPERATION_NOT_SUPPORTED_REASON_COLUMN_TYPE = 1850; +exports.ER_ALTER_OPERATION_NOT_SUPPORTED_REASON_FK_CHECK = 1851; +exports.ER_ALTER_OPERATION_NOT_SUPPORTED_REASON_IGNORE = 1852; +exports.ER_ALTER_OPERATION_NOT_SUPPORTED_REASON_NOPK = 1853; +exports.ER_ALTER_OPERATION_NOT_SUPPORTED_REASON_AUTOINC = 1854; +exports.ER_ALTER_OPERATION_NOT_SUPPORTED_REASON_HIDDEN_FTS = 1855; +exports.ER_ALTER_OPERATION_NOT_SUPPORTED_REASON_CHANGE_FTS = 1856; +exports.ER_ALTER_OPERATION_NOT_SUPPORTED_REASON_FTS = 1857; +exports.ER_SQL_SLAVE_SKIP_COUNTER_NOT_SETTABLE_IN_GTID_MODE = 1858; +exports.ER_DUP_UNKNOWN_IN_INDEX = 1859; +exports.ER_IDENT_CAUSES_TOO_LONG_PATH = 1860; +exports.ER_ALTER_OPERATION_NOT_SUPPORTED_REASON_NOT_NULL = 1861; +exports.ER_MUST_CHANGE_PASSWORD_LOGIN = 1862; +exports.ER_ROW_IN_WRONG_PARTITION = 1863; +exports.ER_MTS_EVENT_BIGGER_PENDING_JOBS_SIZE_MAX = 1864; +exports.ER_INNODB_NO_FT_USES_PARSER = 1865; +exports.ER_BINLOG_LOGICAL_CORRUPTION = 1866; +exports.ER_WARN_PURGE_LOG_IN_USE = 1867; +exports.ER_WARN_PURGE_LOG_IS_ACTIVE = 1868; +exports.ER_AUTO_INCREMENT_CONFLICT = 1869; +exports.WARN_ON_BLOCKHOLE_IN_RBR = 1870; +exports.ER_SLAVE_MI_INIT_REPOSITORY = 1871; +exports.ER_SLAVE_RLI_INIT_REPOSITORY = 1872; +exports.ER_ACCESS_DENIED_CHANGE_USER_ERROR = 1873; +exports.ER_INNODB_READ_ONLY = 1874; +exports.ER_STOP_SLAVE_SQL_THREAD_TIMEOUT = 1875; +exports.ER_STOP_SLAVE_IO_THREAD_TIMEOUT = 1876; +exports.ER_TABLE_CORRUPT = 1877; +exports.ER_TEMP_FILE_WRITE_FAILURE = 1878; +exports.ER_INNODB_FT_AUX_NOT_HEX_ID = 1879; +exports.ER_OLD_TEMPORALS_UPGRADED = 1880; +exports.ER_INNODB_FORCED_RECOVERY = 1881; +exports.ER_AES_INVALID_IV = 1882; + +// Lookup-by-number table +exports[1] = 'EE_CANTCREATEFILE'; +exports[2] = 'EE_READ'; +exports[3] = 'EE_WRITE'; +exports[4] = 'EE_BADCLOSE'; +exports[5] = 'EE_OUTOFMEMORY'; +exports[6] = 'EE_DELETE'; +exports[7] = 'EE_LINK'; +exports[9] = 'EE_EOFERR'; +exports[10] = 'EE_CANTLOCK'; +exports[11] = 'EE_CANTUNLOCK'; +exports[12] = 'EE_DIR'; +exports[13] = 'EE_STAT'; +exports[14] = 'EE_CANT_CHSIZE'; +exports[15] = 'EE_CANT_OPEN_STREAM'; +exports[16] = 'EE_GETWD'; +exports[17] = 'EE_SETWD'; +exports[18] = 'EE_LINK_WARNING'; +exports[19] = 'EE_OPEN_WARNING'; +exports[20] = 'EE_DISK_FULL'; +exports[21] = 'EE_CANT_MKDIR'; +exports[22] = 'EE_UNKNOWN_CHARSET'; +exports[23] = 'EE_OUT_OF_FILERESOURCES'; +exports[24] = 'EE_CANT_READLINK'; +exports[25] = 'EE_CANT_SYMLINK'; +exports[26] = 'EE_REALPATH'; +exports[27] = 'EE_SYNC'; +exports[28] = 'EE_UNKNOWN_COLLATION'; +exports[29] = 'EE_FILENOTFOUND'; +exports[30] = 'EE_FILE_NOT_CLOSED'; +exports[31] = 'EE_CHANGE_OWNERSHIP'; +exports[32] = 'EE_CHANGE_PERMISSIONS'; +exports[33] = 'EE_CANT_SEEK'; +exports[120] = 'HA_ERR_KEY_NOT_FOUND'; +exports[121] = 'HA_ERR_FOUND_DUPP_KEY'; +exports[122] = 'HA_ERR_INTERNAL_ERROR'; +exports[123] = 'HA_ERR_RECORD_CHANGED'; +exports[124] = 'HA_ERR_WRONG_INDEX'; +exports[126] = 'HA_ERR_CRASHED'; +exports[127] = 'HA_ERR_WRONG_IN_RECORD'; +exports[128] = 'HA_ERR_OUT_OF_MEM'; +exports[130] = 'HA_ERR_NOT_A_TABLE'; +exports[131] = 'HA_ERR_WRONG_COMMAND'; +exports[132] = 'HA_ERR_OLD_FILE'; +exports[133] = 'HA_ERR_NO_ACTIVE_RECORD'; +exports[134] = 'HA_ERR_RECORD_DELETED'; +exports[135] = 'HA_ERR_RECORD_FILE_FULL'; +exports[136] = 'HA_ERR_INDEX_FILE_FULL'; +exports[137] = 'HA_ERR_END_OF_FILE'; +exports[138] = 'HA_ERR_UNSUPPORTED'; +exports[139] = 'HA_ERR_TO_BIG_ROW'; +exports[140] = 'HA_WRONG_CREATE_OPTION'; +exports[141] = 'HA_ERR_FOUND_DUPP_UNIQUE'; +exports[142] = 'HA_ERR_UNKNOWN_CHARSET'; +exports[143] = 'HA_ERR_WRONG_MRG_TABLE_DEF'; +exports[144] = 'HA_ERR_CRASHED_ON_REPAIR'; +exports[145] = 'HA_ERR_CRASHED_ON_USAGE'; +exports[146] = 'HA_ERR_LOCK_WAIT_TIMEOUT'; +exports[147] = 'HA_ERR_LOCK_TABLE_FULL'; +exports[148] = 'HA_ERR_READ_ONLY_TRANSACTION'; +exports[149] = 'HA_ERR_LOCK_DEADLOCK'; +exports[150] = 'HA_ERR_CANNOT_ADD_FOREIGN'; +exports[151] = 'HA_ERR_NO_REFERENCED_ROW'; +exports[152] = 'HA_ERR_ROW_IS_REFERENCED'; +exports[153] = 'HA_ERR_NO_SAVEPOINT'; +exports[154] = 'HA_ERR_NON_UNIQUE_BLOCK_SIZE'; +exports[155] = 'HA_ERR_NO_SUCH_TABLE'; +exports[156] = 'HA_ERR_TABLE_EXIST'; +exports[157] = 'HA_ERR_NO_CONNECTION'; +exports[158] = 'HA_ERR_NULL_IN_SPATIAL'; +exports[159] = 'HA_ERR_TABLE_DEF_CHANGED'; +exports[160] = 'HA_ERR_NO_PARTITION_FOUND'; +exports[161] = 'HA_ERR_RBR_LOGGING_FAILED'; +exports[162] = 'HA_ERR_DROP_INDEX_FK'; +exports[163] = 'HA_ERR_FOREIGN_DUPLICATE_KEY'; +exports[164] = 'HA_ERR_TABLE_NEEDS_UPGRADE'; +exports[165] = 'HA_ERR_TABLE_READONLY'; +exports[166] = 'HA_ERR_AUTOINC_READ_FAILED'; +exports[167] = 'HA_ERR_AUTOINC_ERANGE'; +exports[168] = 'HA_ERR_GENERIC'; +exports[169] = 'HA_ERR_RECORD_IS_THE_SAME'; +exports[170] = 'HA_ERR_LOGGING_IMPOSSIBLE'; +exports[171] = 'HA_ERR_CORRUPT_EVENT'; +exports[172] = 'HA_ERR_NEW_FILE'; +exports[173] = 'HA_ERR_ROWS_EVENT_APPLY'; +exports[174] = 'HA_ERR_INITIALIZATION'; +exports[175] = 'HA_ERR_FILE_TOO_SHORT'; +exports[176] = 'HA_ERR_WRONG_CRC'; +exports[177] = 'HA_ERR_TOO_MANY_CONCURRENT_TRXS'; +exports[178] = 'HA_ERR_NOT_IN_LOCK_PARTITIONS'; +exports[179] = 'HA_ERR_INDEX_COL_TOO_LONG'; +exports[180] = 'HA_ERR_INDEX_CORRUPT'; +exports[181] = 'HA_ERR_UNDO_REC_TOO_BIG'; +exports[182] = 'HA_FTS_INVALID_DOCID'; +exports[183] = 'HA_ERR_TABLE_IN_FK_CHECK'; +exports[184] = 'HA_ERR_TABLESPACE_EXISTS'; +exports[185] = 'HA_ERR_TOO_MANY_FIELDS'; +exports[186] = 'HA_ERR_ROW_IN_WRONG_PARTITION'; +exports[187] = 'HA_ERR_INNODB_READ_ONLY'; +exports[188] = 'HA_ERR_FTS_EXCEED_RESULT_CACHE_LIMIT'; +exports[189] = 'HA_ERR_TEMP_FILE_WRITE_FAILURE'; +exports[190] = 'HA_ERR_INNODB_FORCED_RECOVERY'; +exports[191] = 'HA_ERR_FTS_TOO_MANY_WORDS_IN_PHRASE'; +exports[1000] = 'ER_HASHCHK'; +exports[1001] = 'ER_NISAMCHK'; +exports[1002] = 'ER_NO'; +exports[1003] = 'ER_YES'; +exports[1004] = 'ER_CANT_CREATE_FILE'; +exports[1005] = 'ER_CANT_CREATE_TABLE'; +exports[1006] = 'ER_CANT_CREATE_DB'; +exports[1007] = 'ER_DB_CREATE_EXISTS'; +exports[1008] = 'ER_DB_DROP_EXISTS'; +exports[1009] = 'ER_DB_DROP_DELETE'; +exports[1010] = 'ER_DB_DROP_RMDIR'; +exports[1011] = 'ER_CANT_DELETE_FILE'; +exports[1012] = 'ER_CANT_FIND_SYSTEM_REC'; +exports[1013] = 'ER_CANT_GET_STAT'; +exports[1014] = 'ER_CANT_GET_WD'; +exports[1015] = 'ER_CANT_LOCK'; +exports[1016] = 'ER_CANT_OPEN_FILE'; +exports[1017] = 'ER_FILE_NOT_FOUND'; +exports[1018] = 'ER_CANT_READ_DIR'; +exports[1019] = 'ER_CANT_SET_WD'; +exports[1020] = 'ER_CHECKREAD'; +exports[1021] = 'ER_DISK_FULL'; +exports[1022] = 'ER_DUP_KEY'; +exports[1023] = 'ER_ERROR_ON_CLOSE'; +exports[1024] = 'ER_ERROR_ON_READ'; +exports[1025] = 'ER_ERROR_ON_RENAME'; +exports[1026] = 'ER_ERROR_ON_WRITE'; +exports[1027] = 'ER_FILE_USED'; +exports[1028] = 'ER_FILSORT_ABORT'; +exports[1029] = 'ER_FORM_NOT_FOUND'; +exports[1030] = 'ER_GET_ERRNO'; +exports[1031] = 'ER_ILLEGAL_HA'; +exports[1032] = 'ER_KEY_NOT_FOUND'; +exports[1033] = 'ER_NOT_FORM_FILE'; +exports[1034] = 'ER_NOT_KEYFILE'; +exports[1035] = 'ER_OLD_KEYFILE'; +exports[1036] = 'ER_OPEN_AS_READONLY'; +exports[1037] = 'ER_OUTOFMEMORY'; +exports[1038] = 'ER_OUT_OF_SORTMEMORY'; +exports[1039] = 'ER_UNEXPECTED_EOF'; +exports[1040] = 'ER_CON_COUNT_ERROR'; +exports[1041] = 'ER_OUT_OF_RESOURCES'; +exports[1042] = 'ER_BAD_HOST_ERROR'; +exports[1043] = 'ER_HANDSHAKE_ERROR'; +exports[1044] = 'ER_DBACCESS_DENIED_ERROR'; +exports[1045] = 'ER_ACCESS_DENIED_ERROR'; +exports[1046] = 'ER_NO_DB_ERROR'; +exports[1047] = 'ER_UNKNOWN_COM_ERROR'; +exports[1048] = 'ER_BAD_NULL_ERROR'; +exports[1049] = 'ER_BAD_DB_ERROR'; +exports[1050] = 'ER_TABLE_EXISTS_ERROR'; +exports[1051] = 'ER_BAD_TABLE_ERROR'; +exports[1052] = 'ER_NON_UNIQ_ERROR'; +exports[1053] = 'ER_SERVER_SHUTDOWN'; +exports[1054] = 'ER_BAD_FIELD_ERROR'; +exports[1055] = 'ER_WRONG_FIELD_WITH_GROUP'; +exports[1056] = 'ER_WRONG_GROUP_FIELD'; +exports[1057] = 'ER_WRONG_SUM_SELECT'; +exports[1058] = 'ER_WRONG_VALUE_COUNT'; +exports[1059] = 'ER_TOO_LONG_IDENT'; +exports[1060] = 'ER_DUP_FIELDNAME'; +exports[1061] = 'ER_DUP_KEYNAME'; +exports[1062] = 'ER_DUP_ENTRY'; +exports[1063] = 'ER_WRONG_FIELD_SPEC'; +exports[1064] = 'ER_PARSE_ERROR'; +exports[1065] = 'ER_EMPTY_QUERY'; +exports[1066] = 'ER_NONUNIQ_TABLE'; +exports[1067] = 'ER_INVALID_DEFAULT'; +exports[1068] = 'ER_MULTIPLE_PRI_KEY'; +exports[1069] = 'ER_TOO_MANY_KEYS'; +exports[1070] = 'ER_TOO_MANY_KEY_PARTS'; +exports[1071] = 'ER_TOO_LONG_KEY'; +exports[1072] = 'ER_KEY_COLUMN_DOES_NOT_EXITS'; +exports[1073] = 'ER_BLOB_USED_AS_KEY'; +exports[1074] = 'ER_TOO_BIG_FIELDLENGTH'; +exports[1075] = 'ER_WRONG_AUTO_KEY'; +exports[1076] = 'ER_READY'; +exports[1077] = 'ER_NORMAL_SHUTDOWN'; +exports[1078] = 'ER_GOT_SIGNAL'; +exports[1079] = 'ER_SHUTDOWN_COMPLETE'; +exports[1080] = 'ER_FORCING_CLOSE'; +exports[1081] = 'ER_IPSOCK_ERROR'; +exports[1082] = 'ER_NO_SUCH_INDEX'; +exports[1083] = 'ER_WRONG_FIELD_TERMINATORS'; +exports[1084] = 'ER_BLOBS_AND_NO_TERMINATED'; +exports[1085] = 'ER_TEXTFILE_NOT_READABLE'; +exports[1086] = 'ER_FILE_EXISTS_ERROR'; +exports[1087] = 'ER_LOAD_INFO'; +exports[1088] = 'ER_ALTER_INFO'; +exports[1089] = 'ER_WRONG_SUB_KEY'; +exports[1090] = 'ER_CANT_REMOVE_ALL_FIELDS'; +exports[1091] = 'ER_CANT_DROP_FIELD_OR_KEY'; +exports[1092] = 'ER_INSERT_INFO'; +exports[1093] = 'ER_UPDATE_TABLE_USED'; +exports[1094] = 'ER_NO_SUCH_THREAD'; +exports[1095] = 'ER_KILL_DENIED_ERROR'; +exports[1096] = 'ER_NO_TABLES_USED'; +exports[1097] = 'ER_TOO_BIG_SET'; +exports[1098] = 'ER_NO_UNIQUE_LOGFILE'; +exports[1099] = 'ER_TABLE_NOT_LOCKED_FOR_WRITE'; +exports[1100] = 'ER_TABLE_NOT_LOCKED'; +exports[1101] = 'ER_BLOB_CANT_HAVE_DEFAULT'; +exports[1102] = 'ER_WRONG_DB_NAME'; +exports[1103] = 'ER_WRONG_TABLE_NAME'; +exports[1104] = 'ER_TOO_BIG_SELECT'; +exports[1105] = 'ER_UNKNOWN_ERROR'; +exports[1106] = 'ER_UNKNOWN_PROCEDURE'; +exports[1107] = 'ER_WRONG_PARAMCOUNT_TO_PROCEDURE'; +exports[1108] = 'ER_WRONG_PARAMETERS_TO_PROCEDURE'; +exports[1109] = 'ER_UNKNOWN_TABLE'; +exports[1110] = 'ER_FIELD_SPECIFIED_TWICE'; +exports[1111] = 'ER_INVALID_GROUP_FUNC_USE'; +exports[1112] = 'ER_UNSUPPORTED_EXTENSION'; +exports[1113] = 'ER_TABLE_MUST_HAVE_COLUMNS'; +exports[1114] = 'ER_RECORD_FILE_FULL'; +exports[1115] = 'ER_UNKNOWN_CHARACTER_SET'; +exports[1116] = 'ER_TOO_MANY_TABLES'; +exports[1117] = 'ER_TOO_MANY_FIELDS'; +exports[1118] = 'ER_TOO_BIG_ROWSIZE'; +exports[1119] = 'ER_STACK_OVERRUN'; +exports[1120] = 'ER_WRONG_OUTER_JOIN'; +exports[1121] = 'ER_NULL_COLUMN_IN_INDEX'; +exports[1122] = 'ER_CANT_FIND_UDF'; +exports[1123] = 'ER_CANT_INITIALIZE_UDF'; +exports[1124] = 'ER_UDF_NO_PATHS'; +exports[1125] = 'ER_UDF_EXISTS'; +exports[1126] = 'ER_CANT_OPEN_LIBRARY'; +exports[1127] = 'ER_CANT_FIND_DL_ENTRY'; +exports[1128] = 'ER_FUNCTION_NOT_DEFINED'; +exports[1129] = 'ER_HOST_IS_BLOCKED'; +exports[1130] = 'ER_HOST_NOT_PRIVILEGED'; +exports[1131] = 'ER_PASSWORD_ANONYMOUS_USER'; +exports[1132] = 'ER_PASSWORD_NOT_ALLOWED'; +exports[1133] = 'ER_PASSWORD_NO_MATCH'; +exports[1134] = 'ER_UPDATE_INFO'; +exports[1135] = 'ER_CANT_CREATE_THREAD'; +exports[1136] = 'ER_WRONG_VALUE_COUNT_ON_ROW'; +exports[1137] = 'ER_CANT_REOPEN_TABLE'; +exports[1138] = 'ER_INVALID_USE_OF_NULL'; +exports[1139] = 'ER_REGEXP_ERROR'; +exports[1140] = 'ER_MIX_OF_GROUP_FUNC_AND_FIELDS'; +exports[1141] = 'ER_NONEXISTING_GRANT'; +exports[1142] = 'ER_TABLEACCESS_DENIED_ERROR'; +exports[1143] = 'ER_COLUMNACCESS_DENIED_ERROR'; +exports[1144] = 'ER_ILLEGAL_GRANT_FOR_TABLE'; +exports[1145] = 'ER_GRANT_WRONG_HOST_OR_USER'; +exports[1146] = 'ER_NO_SUCH_TABLE'; +exports[1147] = 'ER_NONEXISTING_TABLE_GRANT'; +exports[1148] = 'ER_NOT_ALLOWED_COMMAND'; +exports[1149] = 'ER_SYNTAX_ERROR'; +exports[1150] = 'ER_DELAYED_CANT_CHANGE_LOCK'; +exports[1151] = 'ER_TOO_MANY_DELAYED_THREADS'; +exports[1152] = 'ER_ABORTING_CONNECTION'; +exports[1153] = 'ER_NET_PACKET_TOO_LARGE'; +exports[1154] = 'ER_NET_READ_ERROR_FROM_PIPE'; +exports[1155] = 'ER_NET_FCNTL_ERROR'; +exports[1156] = 'ER_NET_PACKETS_OUT_OF_ORDER'; +exports[1157] = 'ER_NET_UNCOMPRESS_ERROR'; +exports[1158] = 'ER_NET_READ_ERROR'; +exports[1159] = 'ER_NET_READ_INTERRUPTED'; +exports[1160] = 'ER_NET_ERROR_ON_WRITE'; +exports[1161] = 'ER_NET_WRITE_INTERRUPTED'; +exports[1162] = 'ER_TOO_LONG_STRING'; +exports[1163] = 'ER_TABLE_CANT_HANDLE_BLOB'; +exports[1164] = 'ER_TABLE_CANT_HANDLE_AUTO_INCREMENT'; +exports[1165] = 'ER_DELAYED_INSERT_TABLE_LOCKED'; +exports[1166] = 'ER_WRONG_COLUMN_NAME'; +exports[1167] = 'ER_WRONG_KEY_COLUMN'; +exports[1168] = 'ER_WRONG_MRG_TABLE'; +exports[1169] = 'ER_DUP_UNIQUE'; +exports[1170] = 'ER_BLOB_KEY_WITHOUT_LENGTH'; +exports[1171] = 'ER_PRIMARY_CANT_HAVE_NULL'; +exports[1172] = 'ER_TOO_MANY_ROWS'; +exports[1173] = 'ER_REQUIRES_PRIMARY_KEY'; +exports[1174] = 'ER_NO_RAID_COMPILED'; +exports[1175] = 'ER_UPDATE_WITHOUT_KEY_IN_SAFE_MODE'; +exports[1176] = 'ER_KEY_DOES_NOT_EXITS'; +exports[1177] = 'ER_CHECK_NO_SUCH_TABLE'; +exports[1178] = 'ER_CHECK_NOT_IMPLEMENTED'; +exports[1179] = 'ER_CANT_DO_THIS_DURING_AN_TRANSACTION'; +exports[1180] = 'ER_ERROR_DURING_COMMIT'; +exports[1181] = 'ER_ERROR_DURING_ROLLBACK'; +exports[1182] = 'ER_ERROR_DURING_FLUSH_LOGS'; +exports[1183] = 'ER_ERROR_DURING_CHECKPOINT'; +exports[1184] = 'ER_NEW_ABORTING_CONNECTION'; +exports[1185] = 'ER_DUMP_NOT_IMPLEMENTED'; +exports[1186] = 'ER_FLUSH_MASTER_BINLOG_CLOSED'; +exports[1187] = 'ER_INDEX_REBUILD'; +exports[1188] = 'ER_MASTER'; +exports[1189] = 'ER_MASTER_NET_READ'; +exports[1190] = 'ER_MASTER_NET_WRITE'; +exports[1191] = 'ER_FT_MATCHING_KEY_NOT_FOUND'; +exports[1192] = 'ER_LOCK_OR_ACTIVE_TRANSACTION'; +exports[1193] = 'ER_UNKNOWN_SYSTEM_VARIABLE'; +exports[1194] = 'ER_CRASHED_ON_USAGE'; +exports[1195] = 'ER_CRASHED_ON_REPAIR'; +exports[1196] = 'ER_WARNING_NOT_COMPLETE_ROLLBACK'; +exports[1197] = 'ER_TRANS_CACHE_FULL'; +exports[1198] = 'ER_SLAVE_MUST_STOP'; +exports[1199] = 'ER_SLAVE_NOT_RUNNING'; +exports[1200] = 'ER_BAD_SLAVE'; +exports[1201] = 'ER_MASTER_INFO'; +exports[1202] = 'ER_SLAVE_THREAD'; +exports[1203] = 'ER_TOO_MANY_USER_CONNECTIONS'; +exports[1204] = 'ER_SET_CONSTANTS_ONLY'; +exports[1205] = 'ER_LOCK_WAIT_TIMEOUT'; +exports[1206] = 'ER_LOCK_TABLE_FULL'; +exports[1207] = 'ER_READ_ONLY_TRANSACTION'; +exports[1208] = 'ER_DROP_DB_WITH_READ_LOCK'; +exports[1209] = 'ER_CREATE_DB_WITH_READ_LOCK'; +exports[1210] = 'ER_WRONG_ARGUMENTS'; +exports[1211] = 'ER_NO_PERMISSION_TO_CREATE_USER'; +exports[1212] = 'ER_UNION_TABLES_IN_DIFFERENT_DIR'; +exports[1213] = 'ER_LOCK_DEADLOCK'; +exports[1214] = 'ER_TABLE_CANT_HANDLE_FT'; +exports[1215] = 'ER_CANNOT_ADD_FOREIGN'; +exports[1216] = 'ER_NO_REFERENCED_ROW'; +exports[1217] = 'ER_ROW_IS_REFERENCED'; +exports[1218] = 'ER_CONNECT_TO_MASTER'; +exports[1219] = 'ER_QUERY_ON_MASTER'; +exports[1220] = 'ER_ERROR_WHEN_EXECUTING_COMMAND'; +exports[1221] = 'ER_WRONG_USAGE'; +exports[1222] = 'ER_WRONG_NUMBER_OF_COLUMNS_IN_SELECT'; +exports[1223] = 'ER_CANT_UPDATE_WITH_READLOCK'; +exports[1224] = 'ER_MIXING_NOT_ALLOWED'; +exports[1225] = 'ER_DUP_ARGUMENT'; +exports[1226] = 'ER_USER_LIMIT_REACHED'; +exports[1227] = 'ER_SPECIFIC_ACCESS_DENIED_ERROR'; +exports[1228] = 'ER_LOCAL_VARIABLE'; +exports[1229] = 'ER_GLOBAL_VARIABLE'; +exports[1230] = 'ER_NO_DEFAULT'; +exports[1231] = 'ER_WRONG_VALUE_FOR_VAR'; +exports[1232] = 'ER_WRONG_TYPE_FOR_VAR'; +exports[1233] = 'ER_VAR_CANT_BE_READ'; +exports[1234] = 'ER_CANT_USE_OPTION_HERE'; +exports[1235] = 'ER_NOT_SUPPORTED_YET'; +exports[1236] = 'ER_MASTER_FATAL_ERROR_READING_BINLOG'; +exports[1237] = 'ER_SLAVE_IGNORED_TABLE'; +exports[1238] = 'ER_INCORRECT_GLOBAL_LOCAL_VAR'; +exports[1239] = 'ER_WRONG_FK_DEF'; +exports[1240] = 'ER_KEY_REF_DO_NOT_MATCH_TABLE_REF'; +exports[1241] = 'ER_OPERAND_COLUMNS'; +exports[1242] = 'ER_SUBQUERY_NO_'; +exports[1243] = 'ER_UNKNOWN_STMT_HANDLER'; +exports[1244] = 'ER_CORRUPT_HELP_DB'; +exports[1245] = 'ER_CYCLIC_REFERENCE'; +exports[1246] = 'ER_AUTO_CONVERT'; +exports[1247] = 'ER_ILLEGAL_REFERENCE'; +exports[1248] = 'ER_DERIVED_MUST_HAVE_ALIAS'; +exports[1249] = 'ER_SELECT_REDUCED'; +exports[1250] = 'ER_TABLENAME_NOT_ALLOWED_HERE'; +exports[1251] = 'ER_NOT_SUPPORTED_AUTH_MODE'; +exports[1252] = 'ER_SPATIAL_CANT_HAVE_NULL'; +exports[1253] = 'ER_COLLATION_CHARSET_MISMATCH'; +exports[1254] = 'ER_SLAVE_WAS_RUNNING'; +exports[1255] = 'ER_SLAVE_WAS_NOT_RUNNING'; +exports[1256] = 'ER_TOO_BIG_FOR_UNCOMPRESS'; +exports[1257] = 'ER_ZLIB_Z_MEM_ERROR'; +exports[1258] = 'ER_ZLIB_Z_BUF_ERROR'; +exports[1259] = 'ER_ZLIB_Z_DATA_ERROR'; +exports[1260] = 'ER_CUT_VALUE_GROUP_CONCAT'; +exports[1261] = 'ER_WARN_TOO_FEW_RECORDS'; +exports[1262] = 'ER_WARN_TOO_MANY_RECORDS'; +exports[1263] = 'ER_WARN_NULL_TO_NOTNULL'; +exports[1264] = 'ER_WARN_DATA_OUT_OF_RANGE'; +exports[1265] = 'WARN_DATA_TRUNCATED'; +exports[1266] = 'ER_WARN_USING_OTHER_HANDLER'; +exports[1267] = 'ER_CANT_AGGREGATE_'; +exports[1268] = 'ER_DROP_USER'; +exports[1269] = 'ER_REVOKE_GRANTS'; +exports[1270] = 'ER_CANT_AGGREGATE_'; +exports[1271] = 'ER_CANT_AGGREGATE_NCOLLATIONS'; +exports[1272] = 'ER_VARIABLE_IS_NOT_STRUCT'; +exports[1273] = 'ER_UNKNOWN_COLLATION'; +exports[1274] = 'ER_SLAVE_IGNORED_SSL_PARAMS'; +exports[1275] = 'ER_SERVER_IS_IN_SECURE_AUTH_MODE'; +exports[1276] = 'ER_WARN_FIELD_RESOLVED'; +exports[1277] = 'ER_BAD_SLAVE_UNTIL_COND'; +exports[1278] = 'ER_MISSING_SKIP_SLAVE'; +exports[1279] = 'ER_UNTIL_COND_IGNORED'; +exports[1280] = 'ER_WRONG_NAME_FOR_INDEX'; +exports[1281] = 'ER_WRONG_NAME_FOR_CATALOG'; +exports[1282] = 'ER_WARN_QC_RESIZE'; +exports[1283] = 'ER_BAD_FT_COLUMN'; +exports[1284] = 'ER_UNKNOWN_KEY_CACHE'; +exports[1285] = 'ER_WARN_HOSTNAME_WONT_WORK'; +exports[1286] = 'ER_UNKNOWN_STORAGE_ENGINE'; +exports[1287] = 'ER_WARN_DEPRECATED_SYNTAX'; +exports[1288] = 'ER_NON_UPDATABLE_TABLE'; +exports[1289] = 'ER_FEATURE_DISABLED'; +exports[1290] = 'ER_OPTION_PREVENTS_STATEMENT'; +exports[1291] = 'ER_DUPLICATED_VALUE_IN_TYPE'; +exports[1292] = 'ER_TRUNCATED_WRONG_VALUE'; +exports[1293] = 'ER_TOO_MUCH_AUTO_TIMESTAMP_COLS'; +exports[1294] = 'ER_INVALID_ON_UPDATE'; +exports[1295] = 'ER_UNSUPPORTED_PS'; +exports[1296] = 'ER_GET_ERRMSG'; +exports[1297] = 'ER_GET_TEMPORARY_ERRMSG'; +exports[1298] = 'ER_UNKNOWN_TIME_ZONE'; +exports[1299] = 'ER_WARN_INVALID_TIMESTAMP'; +exports[1300] = 'ER_INVALID_CHARACTER_STRING'; +exports[1301] = 'ER_WARN_ALLOWED_PACKET_OVERFLOWED'; +exports[1302] = 'ER_CONFLICTING_DECLARATIONS'; +exports[1303] = 'ER_SP_NO_RECURSIVE_CREATE'; +exports[1304] = 'ER_SP_ALREADY_EXISTS'; +exports[1305] = 'ER_SP_DOES_NOT_EXIST'; +exports[1306] = 'ER_SP_DROP_FAILED'; +exports[1307] = 'ER_SP_STORE_FAILED'; +exports[1308] = 'ER_SP_LILABEL_MISMATCH'; +exports[1309] = 'ER_SP_LABEL_REDEFINE'; +exports[1310] = 'ER_SP_LABEL_MISMATCH'; +exports[1311] = 'ER_SP_UNINIT_VAR'; +exports[1312] = 'ER_SP_BADSELECT'; +exports[1313] = 'ER_SP_BADRETURN'; +exports[1314] = 'ER_SP_BADSTATEMENT'; +exports[1315] = 'ER_UPDATE_LOG_DEPRECATED_IGNORED'; +exports[1316] = 'ER_UPDATE_LOG_DEPRECATED_TRANSLATED'; +exports[1317] = 'ER_QUERY_INTERRUPTED'; +exports[1318] = 'ER_SP_WRONG_NO_OF_ARGS'; +exports[1319] = 'ER_SP_COND_MISMATCH'; +exports[1320] = 'ER_SP_NORETURN'; +exports[1321] = 'ER_SP_NORETURNEND'; +exports[1322] = 'ER_SP_BAD_CURSOR_QUERY'; +exports[1323] = 'ER_SP_BAD_CURSOR_SELECT'; +exports[1324] = 'ER_SP_CURSOR_MISMATCH'; +exports[1325] = 'ER_SP_CURSOR_ALREADY_OPEN'; +exports[1326] = 'ER_SP_CURSOR_NOT_OPEN'; +exports[1327] = 'ER_SP_UNDECLARED_VAR'; +exports[1328] = 'ER_SP_WRONG_NO_OF_FETCH_ARGS'; +exports[1329] = 'ER_SP_FETCH_NO_DATA'; +exports[1330] = 'ER_SP_DUP_PARAM'; +exports[1331] = 'ER_SP_DUP_VAR'; +exports[1332] = 'ER_SP_DUP_COND'; +exports[1333] = 'ER_SP_DUP_CURS'; +exports[1334] = 'ER_SP_CANT_ALTER'; +exports[1335] = 'ER_SP_SUBSELECT_NYI'; +exports[1336] = 'ER_STMT_NOT_ALLOWED_IN_SF_OR_TRG'; +exports[1337] = 'ER_SP_VARCOND_AFTER_CURSHNDLR'; +exports[1338] = 'ER_SP_CURSOR_AFTER_HANDLER'; +exports[1339] = 'ER_SP_CASE_NOT_FOUND'; +exports[1340] = 'ER_FPARSER_TOO_BIG_FILE'; +exports[1341] = 'ER_FPARSER_BAD_HEADER'; +exports[1342] = 'ER_FPARSER_EOF_IN_COMMENT'; +exports[1343] = 'ER_FPARSER_ERROR_IN_PARAMETER'; +exports[1344] = 'ER_FPARSER_EOF_IN_UNKNOWN_PARAMETER'; +exports[1345] = 'ER_VIEW_NO_EXPLAIN'; +exports[1346] = 'ER_FRM_UNKNOWN_TYPE'; +exports[1347] = 'ER_WRONG_OBJECT'; +exports[1348] = 'ER_NONUPDATEABLE_COLUMN'; +exports[1349] = 'ER_VIEW_SELECT_DERIVED'; +exports[1350] = 'ER_VIEW_SELECT_CLAUSE'; +exports[1351] = 'ER_VIEW_SELECT_VARIABLE'; +exports[1352] = 'ER_VIEW_SELECT_TMPTABLE'; +exports[1353] = 'ER_VIEW_WRONG_LIST'; +exports[1354] = 'ER_WARN_VIEW_MERGE'; +exports[1355] = 'ER_WARN_VIEW_WITHOUT_KEY'; +exports[1356] = 'ER_VIEW_INVALID'; +exports[1357] = 'ER_SP_NO_DROP_SP'; +exports[1358] = 'ER_SP_GOTO_IN_HNDLR'; +exports[1359] = 'ER_TRG_ALREADY_EXISTS'; +exports[1360] = 'ER_TRG_DOES_NOT_EXIST'; +exports[1361] = 'ER_TRG_ON_VIEW_OR_TEMP_TABLE'; +exports[1362] = 'ER_TRG_CANT_CHANGE_ROW'; +exports[1363] = 'ER_TRG_NO_SUCH_ROW_IN_TRG'; +exports[1364] = 'ER_NO_DEFAULT_FOR_FIELD'; +exports[1365] = 'ER_DIVISION_BY_ZERO'; +exports[1366] = 'ER_TRUNCATED_WRONG_VALUE_FOR_FIELD'; +exports[1367] = 'ER_ILLEGAL_VALUE_FOR_TYPE'; +exports[1368] = 'ER_VIEW_NONUPD_CHECK'; +exports[1369] = 'ER_VIEW_CHECK_FAILED'; +exports[1370] = 'ER_PROCACCESS_DENIED_ERROR'; +exports[1371] = 'ER_RELAY_LOG_FAIL'; +exports[1372] = 'ER_PASSWD_LENGTH'; +exports[1373] = 'ER_UNKNOWN_TARGET_BINLOG'; +exports[1374] = 'ER_IO_ERR_LOG_INDEX_READ'; +exports[1375] = 'ER_BINLOG_PURGE_PROHIBITED'; +exports[1376] = 'ER_FSEEK_FAIL'; +exports[1377] = 'ER_BINLOG_PURGE_FATAL_ERR'; +exports[1378] = 'ER_LOG_IN_USE'; +exports[1379] = 'ER_LOG_PURGE_UNKNOWN_ERR'; +exports[1380] = 'ER_RELAY_LOG_INIT'; +exports[1381] = 'ER_NO_BINARY_LOGGING'; +exports[1382] = 'ER_RESERVED_SYNTAX'; +exports[1383] = 'ER_WSAS_FAILED'; +exports[1384] = 'ER_DIFF_GROUPS_PROC'; +exports[1385] = 'ER_NO_GROUP_FOR_PROC'; +exports[1386] = 'ER_ORDER_WITH_PROC'; +exports[1387] = 'ER_LOGGING_PROHIBIT_CHANGING_OF'; +exports[1388] = 'ER_NO_FILE_MAPPING'; +exports[1389] = 'ER_WRONG_MAGIC'; +exports[1390] = 'ER_PS_MANY_PARAM'; +exports[1391] = 'ER_KEY_PART_'; +exports[1392] = 'ER_VIEW_CHECKSUM'; +exports[1393] = 'ER_VIEW_MULTIUPDATE'; +exports[1394] = 'ER_VIEW_NO_INSERT_FIELD_LIST'; +exports[1395] = 'ER_VIEW_DELETE_MERGE_VIEW'; +exports[1396] = 'ER_CANNOT_USER'; +exports[1397] = 'ER_XAER_NOTA'; +exports[1398] = 'ER_XAER_INVAL'; +exports[1399] = 'ER_XAER_RMFAIL'; +exports[1400] = 'ER_XAER_OUTSIDE'; +exports[1401] = 'ER_XAER_RMERR'; +exports[1402] = 'ER_XA_RBROLLBACK'; +exports[1403] = 'ER_NONEXISTING_PROC_GRANT'; +exports[1404] = 'ER_PROC_AUTO_GRANT_FAIL'; +exports[1405] = 'ER_PROC_AUTO_REVOKE_FAIL'; +exports[1406] = 'ER_DATA_TOO_LONG'; +exports[1407] = 'ER_SP_BAD_SQLSTATE'; +exports[1408] = 'ER_STARTUP'; +exports[1409] = 'ER_LOAD_FROM_FIXED_SIZE_ROWS_TO_VAR'; +exports[1410] = 'ER_CANT_CREATE_USER_WITH_GRANT'; +exports[1411] = 'ER_WRONG_VALUE_FOR_TYPE'; +exports[1412] = 'ER_TABLE_DEF_CHANGED'; +exports[1413] = 'ER_SP_DUP_HANDLER'; +exports[1414] = 'ER_SP_NOT_VAR_ARG'; +exports[1415] = 'ER_SP_NO_RETSET'; +exports[1416] = 'ER_CANT_CREATE_GEOMETRY_OBJECT'; +exports[1417] = 'ER_FAILED_ROUTINE_BREAK_BINLOG'; +exports[1418] = 'ER_BINLOG_UNSAFE_ROUTINE'; +exports[1419] = 'ER_BINLOG_CREATE_ROUTINE_NEED_SUPER'; +exports[1420] = 'ER_EXEC_STMT_WITH_OPEN_CURSOR'; +exports[1421] = 'ER_STMT_HAS_NO_OPEN_CURSOR'; +exports[1422] = 'ER_COMMIT_NOT_ALLOWED_IN_SF_OR_TRG'; +exports[1423] = 'ER_NO_DEFAULT_FOR_VIEW_FIELD'; +exports[1424] = 'ER_SP_NO_RECURSION'; +exports[1425] = 'ER_TOO_BIG_SCALE'; +exports[1426] = 'ER_TOO_BIG_PRECISION'; +exports[1427] = 'ER_M_BIGGER_THAN_D'; +exports[1428] = 'ER_WRONG_LOCK_OF_SYSTEM_TABLE'; +exports[1429] = 'ER_CONNECT_TO_FOREIGN_DATA_SOURCE'; +exports[1430] = 'ER_QUERY_ON_FOREIGN_DATA_SOURCE'; +exports[1431] = 'ER_FOREIGN_DATA_SOURCE_DOESNT_EXIST'; +exports[1432] = 'ER_FOREIGN_DATA_STRING_INVALID_CANT_CREATE'; +exports[1433] = 'ER_FOREIGN_DATA_STRING_INVALID'; +exports[1434] = 'ER_CANT_CREATE_FEDERATED_TABLE'; +exports[1435] = 'ER_TRG_IN_WRONG_SCHEMA'; +exports[1436] = 'ER_STACK_OVERRUN_NEED_MORE'; +exports[1437] = 'ER_TOO_LONG_BODY'; +exports[1438] = 'ER_WARN_CANT_DROP_DEFAULT_KEYCACHE'; +exports[1439] = 'ER_TOO_BIG_DISPLAYWIDTH'; +exports[1440] = 'ER_XAER_DUPID'; +exports[1441] = 'ER_DATETIME_FUNCTION_OVERFLOW'; +exports[1442] = 'ER_CANT_UPDATE_USED_TABLE_IN_SF_OR_TRG'; +exports[1443] = 'ER_VIEW_PREVENT_UPDATE'; +exports[1444] = 'ER_PS_NO_RECURSION'; +exports[1445] = 'ER_SP_CANT_SET_AUTOCOMMIT'; +exports[1446] = 'ER_MALFORMED_DEFINER'; +exports[1447] = 'ER_VIEW_FRM_NO_USER'; +exports[1448] = 'ER_VIEW_OTHER_USER'; +exports[1449] = 'ER_NO_SUCH_USER'; +exports[1450] = 'ER_FORBID_SCHEMA_CHANGE'; +exports[1451] = 'ER_ROW_IS_REFERENCED_'; +exports[1452] = 'ER_NO_REFERENCED_ROW_'; +exports[1453] = 'ER_SP_BAD_VAR_SHADOW'; +exports[1454] = 'ER_TRG_NO_DEFINER'; +exports[1455] = 'ER_OLD_FILE_FORMAT'; +exports[1456] = 'ER_SP_RECURSION_LIMIT'; +exports[1457] = 'ER_SP_PROC_TABLE_CORRUPT'; +exports[1458] = 'ER_SP_WRONG_NAME'; +exports[1459] = 'ER_TABLE_NEEDS_UPGRADE'; +exports[1460] = 'ER_SP_NO_AGGREGATE'; +exports[1461] = 'ER_MAX_PREPARED_STMT_COUNT_REACHED'; +exports[1462] = 'ER_VIEW_RECURSIVE'; +exports[1463] = 'ER_NON_GROUPING_FIELD_USED'; +exports[1464] = 'ER_TABLE_CANT_HANDLE_SPKEYS'; +exports[1465] = 'ER_NO_TRIGGERS_ON_SYSTEM_SCHEMA'; +exports[1466] = 'ER_REMOVED_SPACES'; +exports[1467] = 'ER_AUTOINC_READ_FAILED'; +exports[1468] = 'ER_USERNAME'; +exports[1469] = 'ER_HOSTNAME'; +exports[1470] = 'ER_WRONG_STRING_LENGTH'; +exports[1471] = 'ER_NON_INSERTABLE_TABLE'; +exports[1472] = 'ER_ADMIN_WRONG_MRG_TABLE'; +exports[1473] = 'ER_TOO_HIGH_LEVEL_OF_NESTING_FOR_SELECT'; +exports[1474] = 'ER_NAME_BECOMES_EMPTY'; +exports[1475] = 'ER_AMBIGUOUS_FIELD_TERM'; +exports[1476] = 'ER_FOREIGN_SERVER_EXISTS'; +exports[1477] = 'ER_FOREIGN_SERVER_DOESNT_EXIST'; +exports[1478] = 'ER_ILLEGAL_HA_CREATE_OPTION'; +exports[1479] = 'ER_PARTITION_REQUIRES_VALUES_ERROR'; +exports[1480] = 'ER_PARTITION_WRONG_VALUES_ERROR'; +exports[1481] = 'ER_PARTITION_MAXVALUE_ERROR'; +exports[1482] = 'ER_PARTITION_SUBPARTITION_ERROR'; +exports[1483] = 'ER_PARTITION_SUBPART_MIX_ERROR'; +exports[1484] = 'ER_PARTITION_WRONG_NO_PART_ERROR'; +exports[1485] = 'ER_PARTITION_WRONG_NO_SUBPART_ERROR'; +exports[1486] = 'ER_WRONG_EXPR_IN_PARTITION_FUNC_ERROR'; +exports[1487] = 'ER_NO_CONST_EXPR_IN_RANGE_OR_LIST_ERROR'; +exports[1488] = 'ER_FIELD_NOT_FOUND_PART_ERROR'; +exports[1489] = 'ER_LIST_OF_FIELDS_ONLY_IN_HASH_ERROR'; +exports[1490] = 'ER_INCONSISTENT_PARTITION_INFO_ERROR'; +exports[1491] = 'ER_PARTITION_FUNC_NOT_ALLOWED_ERROR'; +exports[1492] = 'ER_PARTITIONS_MUST_BE_DEFINED_ERROR'; +exports[1493] = 'ER_RANGE_NOT_INCREASING_ERROR'; +exports[1494] = 'ER_INCONSISTENT_TYPE_OF_FUNCTIONS_ERROR'; +exports[1495] = 'ER_MULTIPLE_DEF_CONST_IN_LIST_PART_ERROR'; +exports[1496] = 'ER_PARTITION_ENTRY_ERROR'; +exports[1497] = 'ER_MIX_HANDLER_ERROR'; +exports[1498] = 'ER_PARTITION_NOT_DEFINED_ERROR'; +exports[1499] = 'ER_TOO_MANY_PARTITIONS_ERROR'; +exports[1500] = 'ER_SUBPARTITION_ERROR'; +exports[1501] = 'ER_CANT_CREATE_HANDLER_FILE'; +exports[1502] = 'ER_BLOB_FIELD_IN_PART_FUNC_ERROR'; +exports[1503] = 'ER_UNIQUE_KEY_NEED_ALL_FIELDS_IN_PF'; +exports[1504] = 'ER_NO_PARTS_ERROR'; +exports[1505] = 'ER_PARTITION_MGMT_ON_NONPARTITIONED'; +exports[1506] = 'ER_FOREIGN_KEY_ON_PARTITIONED'; +exports[1507] = 'ER_DROP_PARTITION_NON_EXISTENT'; +exports[1508] = 'ER_DROP_LAST_PARTITION'; +exports[1509] = 'ER_COALESCE_ONLY_ON_HASH_PARTITION'; +exports[1510] = 'ER_REORG_HASH_ONLY_ON_SAME_NO'; +exports[1511] = 'ER_REORG_NO_PARAM_ERROR'; +exports[1512] = 'ER_ONLY_ON_RANGE_LIST_PARTITION'; +exports[1513] = 'ER_ADD_PARTITION_SUBPART_ERROR'; +exports[1514] = 'ER_ADD_PARTITION_NO_NEW_PARTITION'; +exports[1515] = 'ER_COALESCE_PARTITION_NO_PARTITION'; +exports[1516] = 'ER_REORG_PARTITION_NOT_EXIST'; +exports[1517] = 'ER_SAME_NAME_PARTITION'; +exports[1518] = 'ER_NO_BINLOG_ERROR'; +exports[1519] = 'ER_CONSECUTIVE_REORG_PARTITIONS'; +exports[1520] = 'ER_REORG_OUTSIDE_RANGE'; +exports[1521] = 'ER_PARTITION_FUNCTION_FAILURE'; +exports[1522] = 'ER_PART_STATE_ERROR'; +exports[1523] = 'ER_LIMITED_PART_RANGE'; +exports[1524] = 'ER_PLUGIN_IS_NOT_LOADED'; +exports[1525] = 'ER_WRONG_VALUE'; +exports[1526] = 'ER_NO_PARTITION_FOR_GIVEN_VALUE'; +exports[1527] = 'ER_FILEGROUP_OPTION_ONLY_ONCE'; +exports[1528] = 'ER_CREATE_FILEGROUP_FAILED'; +exports[1529] = 'ER_DROP_FILEGROUP_FAILED'; +exports[1530] = 'ER_TABLESPACE_AUTO_EXTEND_ERROR'; +exports[1531] = 'ER_WRONG_SIZE_NUMBER'; +exports[1532] = 'ER_SIZE_OVERFLOW_ERROR'; +exports[1533] = 'ER_ALTER_FILEGROUP_FAILED'; +exports[1534] = 'ER_BINLOG_ROW_LOGGING_FAILED'; +exports[1535] = 'ER_BINLOG_ROW_WRONG_TABLE_DEF'; +exports[1536] = 'ER_BINLOG_ROW_RBR_TO_SBR'; +exports[1537] = 'ER_EVENT_ALREADY_EXISTS'; +exports[1538] = 'ER_EVENT_STORE_FAILED'; +exports[1539] = 'ER_EVENT_DOES_NOT_EXIST'; +exports[1540] = 'ER_EVENT_CANT_ALTER'; +exports[1541] = 'ER_EVENT_DROP_FAILED'; +exports[1542] = 'ER_EVENT_INTERVAL_NOT_POSITIVE_OR_TOO_BIG'; +exports[1543] = 'ER_EVENT_ENDS_BEFORE_STARTS'; +exports[1544] = 'ER_EVENT_EXEC_TIME_IN_THE_PAST'; +exports[1545] = 'ER_EVENT_OPEN_TABLE_FAILED'; +exports[1546] = 'ER_EVENT_NEITHER_M_EXPR_NOR_M_AT'; +exports[1547] = 'ER_COL_COUNT_DOESNT_MATCH_CORRUPTED'; +exports[1548] = 'ER_CANNOT_LOAD_FROM_TABLE'; +exports[1549] = 'ER_EVENT_CANNOT_DELETE'; +exports[1550] = 'ER_EVENT_COMPILE_ERROR'; +exports[1551] = 'ER_EVENT_SAME_NAME'; +exports[1552] = 'ER_EVENT_DATA_TOO_LONG'; +exports[1553] = 'ER_DROP_INDEX_FK'; +exports[1554] = 'ER_WARN_DEPRECATED_SYNTAX_WITH_VER'; +exports[1555] = 'ER_CANT_WRITE_LOCK_LOG_TABLE'; +exports[1556] = 'ER_CANT_LOCK_LOG_TABLE'; +exports[1557] = 'ER_FOREIGN_DUPLICATE_KEY'; +exports[1558] = 'ER_COL_COUNT_DOESNT_MATCH_PLEASE_UPDATE'; +exports[1559] = 'ER_TEMP_TABLE_PREVENTS_SWITCH_OUT_OF_RBR'; +exports[1560] = 'ER_STORED_FUNCTION_PREVENTS_SWITCH_BINLOG_FORMAT'; +exports[1561] = 'ER_NDB_CANT_SWITCH_BINLOG_FORMAT'; +exports[1562] = 'ER_PARTITION_NO_TEMPORARY'; +exports[1563] = 'ER_PARTITION_CONST_DOMAIN_ERROR'; +exports[1564] = 'ER_PARTITION_FUNCTION_IS_NOT_ALLOWED'; +exports[1565] = 'ER_DDL_LOG_ERROR'; +exports[1566] = 'ER_NULL_IN_VALUES_LESS_THAN'; +exports[1567] = 'ER_WRONG_PARTITION_NAME'; +exports[1568] = 'ER_CANT_CHANGE_TX_CHARACTERISTICS'; +exports[1569] = 'ER_DUP_ENTRY_AUTOINCREMENT_CASE'; +exports[1570] = 'ER_EVENT_MODIFY_QUEUE_ERROR'; +exports[1571] = 'ER_EVENT_SET_VAR_ERROR'; +exports[1572] = 'ER_PARTITION_MERGE_ERROR'; +exports[1573] = 'ER_CANT_ACTIVATE_LOG'; +exports[1574] = 'ER_RBR_NOT_AVAILABLE'; +exports[1575] = 'ER_BASE'; +exports[1576] = 'ER_EVENT_RECURSION_FORBIDDEN'; +exports[1577] = 'ER_EVENTS_DB_ERROR'; +exports[1578] = 'ER_ONLY_INTEGERS_ALLOWED'; +exports[1579] = 'ER_UNSUPORTED_LOG_ENGINE'; +exports[1580] = 'ER_BAD_LOG_STATEMENT'; +exports[1581] = 'ER_CANT_RENAME_LOG_TABLE'; +exports[1582] = 'ER_WRONG_PARAMCOUNT_TO_NATIVE_FCT'; +exports[1583] = 'ER_WRONG_PARAMETERS_TO_NATIVE_FCT'; +exports[1584] = 'ER_WRONG_PARAMETERS_TO_STORED_FCT'; +exports[1585] = 'ER_NATIVE_FCT_NAME_COLLISION'; +exports[1586] = 'ER_DUP_ENTRY_WITH_KEY_NAME'; +exports[1587] = 'ER_BINLOG_PURGE_EMFILE'; +exports[1588] = 'ER_EVENT_CANNOT_CREATE_IN_THE_PAST'; +exports[1589] = 'ER_EVENT_CANNOT_ALTER_IN_THE_PAST'; +exports[1590] = 'ER_SLAVE_INCIDENT'; +exports[1591] = 'ER_NO_PARTITION_FOR_GIVEN_VALUE_SILENT'; +exports[1592] = 'ER_BINLOG_UNSAFE_STATEMENT'; +exports[1593] = 'ER_SLAVE_FATAL_ERROR'; +exports[1594] = 'ER_SLAVE_RELAY_LOG_READ_FAILURE'; +exports[1595] = 'ER_SLAVE_RELAY_LOG_WRITE_FAILURE'; +exports[1596] = 'ER_SLAVE_CREATE_EVENT_FAILURE'; +exports[1597] = 'ER_SLAVE_MASTER_COM_FAILURE'; +exports[1598] = 'ER_BINLOG_LOGGING_IMPOSSIBLE'; +exports[1599] = 'ER_VIEW_NO_CREATION_CTX'; +exports[1600] = 'ER_VIEW_INVALID_CREATION_CTX'; +exports[1601] = 'ER_SR_INVALID_CREATION_CTX'; +exports[1602] = 'ER_TRG_CORRUPTED_FILE'; +exports[1603] = 'ER_TRG_NO_CREATION_CTX'; +exports[1604] = 'ER_TRG_INVALID_CREATION_CTX'; +exports[1605] = 'ER_EVENT_INVALID_CREATION_CTX'; +exports[1606] = 'ER_TRG_CANT_OPEN_TABLE'; +exports[1607] = 'ER_CANT_CREATE_SROUTINE'; +exports[1608] = 'ER_NEVER_USED'; +exports[1609] = 'ER_NO_FORMAT_DESCRIPTION_EVENT_BEFORE_BINLOG_STATEMENT'; +exports[1610] = 'ER_SLAVE_CORRUPT_EVENT'; +exports[1611] = 'ER_LOAD_DATA_INVALID_COLUMN'; +exports[1612] = 'ER_LOG_PURGE_NO_FILE'; +exports[1613] = 'ER_XA_RBTIMEOUT'; +exports[1614] = 'ER_XA_RBDEADLOCK'; +exports[1615] = 'ER_NEED_REPREPARE'; +exports[1616] = 'ER_DELAYED_NOT_SUPPORTED'; +exports[1617] = 'WARN_NO_MASTER_INFO'; +exports[1618] = 'WARN_OPTION_IGNORED'; +exports[1619] = 'WARN_PLUGIN_DELETE_BUILTIN'; +exports[1620] = 'WARN_PLUGIN_BUSY'; +exports[1621] = 'ER_VARIABLE_IS_READONLY'; +exports[1622] = 'ER_WARN_ENGINE_TRANSACTION_ROLLBACK'; +exports[1623] = 'ER_SLAVE_HEARTBEAT_FAILURE'; +exports[1624] = 'ER_SLAVE_HEARTBEAT_VALUE_OUT_OF_RANGE'; +exports[1625] = 'ER_NDB_REPLICATION_SCHEMA_ERROR'; +exports[1626] = 'ER_CONFLICT_FN_PARSE_ERROR'; +exports[1627] = 'ER_EXCEPTIONS_WRITE_ERROR'; +exports[1628] = 'ER_TOO_LONG_TABLE_COMMENT'; +exports[1629] = 'ER_TOO_LONG_FIELD_COMMENT'; +exports[1630] = 'ER_FUNC_INEXISTENT_NAME_COLLISION'; +exports[1631] = 'ER_DATABASE_NAME'; +exports[1632] = 'ER_TABLE_NAME'; +exports[1633] = 'ER_PARTITION_NAME'; +exports[1634] = 'ER_SUBPARTITION_NAME'; +exports[1635] = 'ER_TEMPORARY_NAME'; +exports[1636] = 'ER_RENAMED_NAME'; +exports[1637] = 'ER_TOO_MANY_CONCURRENT_TRXS'; +exports[1638] = 'WARN_NON_ASCII_SEPARATOR_NOT_IMPLEMENTED'; +exports[1639] = 'ER_DEBUG_SYNC_TIMEOUT'; +exports[1640] = 'ER_DEBUG_SYNC_HIT_LIMIT'; +exports[1641] = 'ER_DUP_SIGNAL_SET'; +exports[1642] = 'ER_SIGNAL_WARN'; +exports[1643] = 'ER_SIGNAL_NOT_FOUND'; +exports[1644] = 'ER_SIGNAL_EXCEPTION'; +exports[1645] = 'ER_RESIGNAL_WITHOUT_ACTIVE_HANDLER'; +exports[1646] = 'ER_SIGNAL_BAD_CONDITION_TYPE'; +exports[1647] = 'WARN_COND_ITEM_TRUNCATED'; +exports[1648] = 'ER_COND_ITEM_TOO_LONG'; +exports[1649] = 'ER_UNKNOWN_LOCALE'; +exports[1650] = 'ER_SLAVE_IGNORE_SERVER_IDS'; +exports[1651] = 'ER_QUERY_CACHE_DISABLED'; +exports[1652] = 'ER_SAME_NAME_PARTITION_FIELD'; +exports[1653] = 'ER_PARTITION_COLUMN_LIST_ERROR'; +exports[1654] = 'ER_WRONG_TYPE_COLUMN_VALUE_ERROR'; +exports[1655] = 'ER_TOO_MANY_PARTITION_FUNC_FIELDS_ERROR'; +exports[1656] = 'ER_MAXVALUE_IN_VALUES_IN'; +exports[1657] = 'ER_TOO_MANY_VALUES_ERROR'; +exports[1658] = 'ER_ROW_SINGLE_PARTITION_FIELD_ERROR'; +exports[1659] = 'ER_FIELD_TYPE_NOT_ALLOWED_AS_PARTITION_FIELD'; +exports[1660] = 'ER_PARTITION_FIELDS_TOO_LONG'; +exports[1661] = 'ER_BINLOG_ROW_ENGINE_AND_STMT_ENGINE'; +exports[1662] = 'ER_BINLOG_ROW_MODE_AND_STMT_ENGINE'; +exports[1663] = 'ER_BINLOG_UNSAFE_AND_STMT_ENGINE'; +exports[1664] = 'ER_BINLOG_ROW_INJECTION_AND_STMT_ENGINE'; +exports[1665] = 'ER_BINLOG_STMT_MODE_AND_ROW_ENGINE'; +exports[1666] = 'ER_BINLOG_ROW_INJECTION_AND_STMT_MODE'; +exports[1667] = 'ER_BINLOG_MULTIPLE_ENGINES_AND_SELF_LOGGING_ENGINE'; +exports[1668] = 'ER_BINLOG_UNSAFE_LIMIT'; +exports[1669] = 'ER_BINLOG_UNSAFE_INSERT_DELAYED'; +exports[1670] = 'ER_BINLOG_UNSAFE_SYSTEM_TABLE'; +exports[1671] = 'ER_BINLOG_UNSAFE_AUTOINC_COLUMNS'; +exports[1672] = 'ER_BINLOG_UNSAFE_UDF'; +exports[1673] = 'ER_BINLOG_UNSAFE_SYSTEM_VARIABLE'; +exports[1674] = 'ER_BINLOG_UNSAFE_SYSTEM_FUNCTION'; +exports[1675] = 'ER_BINLOG_UNSAFE_NONTRANS_AFTER_TRANS'; +exports[1676] = 'ER_MESSAGE_AND_STATEMENT'; +exports[1677] = 'ER_SLAVE_CONVERSION_FAILED'; +exports[1678] = 'ER_SLAVE_CANT_CREATE_CONVERSION'; +exports[1679] = 'ER_INSIDE_TRANSACTION_PREVENTS_SWITCH_BINLOG_FORMAT'; +exports[1680] = 'ER_PATH_LENGTH'; +exports[1681] = 'ER_WARN_DEPRECATED_SYNTAX_NO_REPLACEMENT'; +exports[1682] = 'ER_WRONG_NATIVE_TABLE_STRUCTURE'; +exports[1683] = 'ER_WRONG_PERFSCHEMA_USAGE'; +exports[1684] = 'ER_WARN_I_S_SKIPPED_TABLE'; +exports[1685] = 'ER_INSIDE_TRANSACTION_PREVENTS_SWITCH_BINLOG_DIRECT'; +exports[1686] = 'ER_STORED_FUNCTION_PREVENTS_SWITCH_BINLOG_DIRECT'; +exports[1687] = 'ER_SPATIAL_MUST_HAVE_GEOM_COL'; +exports[1688] = 'ER_TOO_LONG_INDEX_COMMENT'; +exports[1689] = 'ER_LOCK_ABORTED'; +exports[1690] = 'ER_DATA_OUT_OF_RANGE'; +exports[1691] = 'ER_WRONG_SPVAR_TYPE_IN_LIMIT'; +exports[1692] = 'ER_BINLOG_UNSAFE_MULTIPLE_ENGINES_AND_SELF_LOGGING_ENGINE'; +exports[1693] = 'ER_BINLOG_UNSAFE_MIXED_STATEMENT'; +exports[1694] = 'ER_INSIDE_TRANSACTION_PREVENTS_SWITCH_SQL_LOG_BIN'; +exports[1695] = 'ER_STORED_FUNCTION_PREVENTS_SWITCH_SQL_LOG_BIN'; +exports[1696] = 'ER_FAILED_READ_FROM_PAR_FILE'; +exports[1697] = 'ER_VALUES_IS_NOT_INT_TYPE_ERROR'; +exports[1698] = 'ER_ACCESS_DENIED_NO_PASSWORD_ERROR'; +exports[1699] = 'ER_SET_PASSWORD_AUTH_PLUGIN'; +exports[1700] = 'ER_GRANT_PLUGIN_USER_EXISTS'; +exports[1701] = 'ER_TRUNCATE_ILLEGAL_FK'; +exports[1702] = 'ER_PLUGIN_IS_PERMANENT'; +exports[1703] = 'ER_SLAVE_HEARTBEAT_VALUE_OUT_OF_RANGE_MIN'; +exports[1704] = 'ER_SLAVE_HEARTBEAT_VALUE_OUT_OF_RANGE_MAX'; +exports[1705] = 'ER_STMT_CACHE_FULL'; +exports[1706] = 'ER_MULTI_UPDATE_KEY_CONFLICT'; +exports[1707] = 'ER_TABLE_NEEDS_REBUILD'; +exports[1708] = 'WARN_OPTION_BELOW_LIMIT'; +exports[1709] = 'ER_INDEX_COLUMN_TOO_LONG'; +exports[1710] = 'ER_ERROR_IN_TRIGGER_BODY'; +exports[1711] = 'ER_ERROR_IN_UNKNOWN_TRIGGER_BODY'; +exports[1712] = 'ER_INDEX_CORRUPT'; +exports[1713] = 'ER_UNDO_RECORD_TOO_BIG'; +exports[1714] = 'ER_BINLOG_UNSAFE_INSERT_IGNORE_SELECT'; +exports[1715] = 'ER_BINLOG_UNSAFE_INSERT_SELECT_UPDATE'; +exports[1716] = 'ER_BINLOG_UNSAFE_REPLACE_SELECT'; +exports[1717] = 'ER_BINLOG_UNSAFE_CREATE_IGNORE_SELECT'; +exports[1718] = 'ER_BINLOG_UNSAFE_CREATE_REPLACE_SELECT'; +exports[1719] = 'ER_BINLOG_UNSAFE_UPDATE_IGNORE'; +exports[1720] = 'ER_PLUGIN_NO_UNINSTALL'; +exports[1721] = 'ER_PLUGIN_NO_INSTALL'; +exports[1722] = 'ER_BINLOG_UNSAFE_WRITE_AUTOINC_SELECT'; +exports[1723] = 'ER_BINLOG_UNSAFE_CREATE_SELECT_AUTOINC'; +exports[1724] = 'ER_BINLOG_UNSAFE_INSERT_TWO_KEYS'; +exports[1725] = 'ER_TABLE_IN_FK_CHECK'; +exports[1726] = 'ER_UNSUPPORTED_ENGINE'; +exports[1727] = 'ER_BINLOG_UNSAFE_AUTOINC_NOT_FIRST'; +exports[1728] = 'ER_CANNOT_LOAD_FROM_TABLE_V'; +exports[1729] = 'ER_MASTER_DELAY_VALUE_OUT_OF_RANGE'; +exports[1730] = 'ER_ONLY_FD_AND_RBR_EVENTS_ALLOWED_IN_BINLOG_STATEMENT'; +exports[1731] = 'ER_PARTITION_EXCHANGE_DIFFERENT_OPTION'; +exports[1732] = 'ER_PARTITION_EXCHANGE_PART_TABLE'; +exports[1733] = 'ER_PARTITION_EXCHANGE_TEMP_TABLE'; +exports[1734] = 'ER_PARTITION_INSTEAD_OF_SUBPARTITION'; +exports[1735] = 'ER_UNKNOWN_PARTITION'; +exports[1736] = 'ER_TABLES_DIFFERENT_METADATA'; +exports[1737] = 'ER_ROW_DOES_NOT_MATCH_PARTITION'; +exports[1738] = 'ER_BINLOG_CACHE_SIZE_GREATER_THAN_MAX'; +exports[1739] = 'ER_WARN_INDEX_NOT_APPLICABLE'; +exports[1740] = 'ER_PARTITION_EXCHANGE_FOREIGN_KEY'; +exports[1741] = 'ER_NO_SUCH_KEY_VALUE'; +exports[1742] = 'ER_RPL_INFO_DATA_TOO_LONG'; +exports[1743] = 'ER_NETWORK_READ_EVENT_CHECKSUM_FAILURE'; +exports[1744] = 'ER_BINLOG_READ_EVENT_CHECKSUM_FAILURE'; +exports[1745] = 'ER_BINLOG_STMT_CACHE_SIZE_GREATER_THAN_MAX'; +exports[1746] = 'ER_CANT_UPDATE_TABLE_IN_CREATE_TABLE_SELECT'; +exports[1747] = 'ER_PARTITION_CLAUSE_ON_NONPARTITIONED'; +exports[1748] = 'ER_ROW_DOES_NOT_MATCH_GIVEN_PARTITION_SET'; +exports[1749] = 'ER_NO_SUCH_PARTITION'; +exports[1750] = 'ER_CHANGE_RPL_INFO_REPOSITORY_FAILURE'; +exports[1751] = 'ER_WARNING_NOT_COMPLETE_ROLLBACK_WITH_CREATED_TEMP_TABLE'; +exports[1752] = 'ER_WARNING_NOT_COMPLETE_ROLLBACK_WITH_DROPPED_TEMP_TABLE'; +exports[1753] = 'ER_MTS_FEATURE_IS_NOT_SUPPORTED'; +exports[1754] = 'ER_MTS_UPDATED_DBS_GREATER_MAX'; +exports[1755] = 'ER_MTS_CANT_PARALLEL'; +exports[1756] = 'ER_MTS_INCONSISTENT_DATA'; +exports[1757] = 'ER_FULLTEXT_NOT_SUPPORTED_WITH_PARTITIONING'; +exports[1758] = 'ER_DA_INVALID_CONDITION_NUMBER'; +exports[1759] = 'ER_INSECURE_PLAIN_TEXT'; +exports[1760] = 'ER_INSECURE_CHANGE_MASTER'; +exports[1761] = 'ER_FOREIGN_DUPLICATE_KEY_WITH_CHILD_INFO'; +exports[1762] = 'ER_FOREIGN_DUPLICATE_KEY_WITHOUT_CHILD_INFO'; +exports[1763] = 'ER_SQLTHREAD_WITH_SECURE_SLAVE'; +exports[1764] = 'ER_TABLE_HAS_NO_FT'; +exports[1765] = 'ER_VARIABLE_NOT_SETTABLE_IN_SF_OR_TRIGGER'; +exports[1766] = 'ER_VARIABLE_NOT_SETTABLE_IN_TRANSACTION'; +exports[1767] = 'ER_GTID_NEXT_IS_NOT_IN_GTID_NEXT_LIST'; +exports[1768] = 'ER_CANT_CHANGE_GTID_NEXT_IN_TRANSACTION_WHEN_GTID_NEXT_LIST_IS_NULL'; +exports[1769] = 'ER_SET_STATEMENT_CANNOT_INVOKE_FUNCTION'; +exports[1770] = 'ER_GTID_NEXT_CANT_BE_AUTOMATIC_IF_GTID_NEXT_LIST_IS_NON_NULL'; +exports[1771] = 'ER_SKIPPING_LOGGED_TRANSACTION'; +exports[1772] = 'ER_MALFORMED_GTID_SET_SPECIFICATION'; +exports[1773] = 'ER_MALFORMED_GTID_SET_ENCODING'; +exports[1774] = 'ER_MALFORMED_GTID_SPECIFICATION'; +exports[1775] = 'ER_GNO_EXHAUSTED'; +exports[1776] = 'ER_BAD_SLAVE_AUTO_POSITION'; +exports[1777] = 'ER_AUTO_POSITION_REQUIRES_GTID_MODE_ON'; +exports[1778] = 'ER_CANT_DO_IMPLICIT_COMMIT_IN_TRX_WHEN_GTID_NEXT_IS_SET'; +exports[1779] = 'ER_GTID_MODE_'; +exports[1780] = 'ER_GTID_MODE_REQUIRES_BINLOG'; +exports[1781] = 'ER_CANT_SET_GTID_NEXT_TO_GTID_WHEN_GTID_MODE_IS_OFF'; +exports[1782] = 'ER_CANT_SET_GTID_NEXT_TO_ANONYMOUS_WHEN_GTID_MODE_IS_ON'; +exports[1783] = 'ER_CANT_SET_GTID_NEXT_LIST_TO_NON_NULL_WHEN_GTID_MODE_IS_OFF'; +exports[1784] = 'ER_FOUND_GTID_EVENT_WHEN_GTID_MODE_IS_OFF'; +exports[1785] = 'ER_GTID_UNSAFE_NON_TRANSACTIONAL_TABLE'; +exports[1786] = 'ER_GTID_UNSAFE_CREATE_SELECT'; +exports[1787] = 'ER_GTID_UNSAFE_CREATE_DROP_TEMPORARY_TABLE_IN_TRANSACTION'; +exports[1788] = 'ER_GTID_MODE_CAN_ONLY_CHANGE_ONE_STEP_AT_A_TIME'; +exports[1789] = 'ER_MASTER_HAS_PURGED_REQUIRED_GTIDS'; +exports[1790] = 'ER_CANT_SET_GTID_NEXT_WHEN_OWNING_GTID'; +exports[1791] = 'ER_UNKNOWN_EXPLAIN_FORMAT'; +exports[1792] = 'ER_CANT_EXECUTE_IN_READ_ONLY_TRANSACTION'; +exports[1793] = 'ER_TOO_LONG_TABLE_PARTITION_COMMENT'; +exports[1794] = 'ER_SLAVE_CONFIGURATION'; +exports[1795] = 'ER_INNODB_FT_LIMIT'; +exports[1796] = 'ER_INNODB_NO_FT_TEMP_TABLE'; +exports[1797] = 'ER_INNODB_FT_WRONG_DOCID_COLUMN'; +exports[1798] = 'ER_INNODB_FT_WRONG_DOCID_INDEX'; +exports[1799] = 'ER_INNODB_ONLINE_LOG_TOO_BIG'; +exports[1800] = 'ER_UNKNOWN_ALTER_ALGORITHM'; +exports[1801] = 'ER_UNKNOWN_ALTER_LOCK'; +exports[1802] = 'ER_MTS_CHANGE_MASTER_CANT_RUN_WITH_GAPS'; +exports[1803] = 'ER_MTS_RECOVERY_FAILURE'; +exports[1804] = 'ER_MTS_RESET_WORKERS'; +exports[1805] = 'ER_COL_COUNT_DOESNT_MATCH_CORRUPTED_V'; +exports[1806] = 'ER_SLAVE_SILENT_RETRY_TRANSACTION'; +exports[1807] = 'ER_DISCARD_FK_CHECKS_RUNNING'; +exports[1808] = 'ER_TABLE_SCHEMA_MISMATCH'; +exports[1809] = 'ER_TABLE_IN_SYSTEM_TABLESPACE'; +exports[1810] = 'ER_IO_READ_ERROR'; +exports[1811] = 'ER_IO_WRITE_ERROR'; +exports[1812] = 'ER_TABLESPACE_MISSING'; +exports[1813] = 'ER_TABLESPACE_EXISTS'; +exports[1814] = 'ER_TABLESPACE_DISCARDED'; +exports[1815] = 'ER_INTERNAL_ERROR'; +exports[1816] = 'ER_INNODB_IMPORT_ERROR'; +exports[1817] = 'ER_INNODB_INDEX_CORRUPT'; +exports[1818] = 'ER_INVALID_YEAR_COLUMN_LENGTH'; +exports[1819] = 'ER_NOT_VALID_PASSWORD'; +exports[1820] = 'ER_MUST_CHANGE_PASSWORD'; +exports[1821] = 'ER_FK_NO_INDEX_CHILD'; +exports[1822] = 'ER_FK_NO_INDEX_PARENT'; +exports[1823] = 'ER_FK_FAIL_ADD_SYSTEM'; +exports[1824] = 'ER_FK_CANNOT_OPEN_PARENT'; +exports[1825] = 'ER_FK_INCORRECT_OPTION'; +exports[1826] = 'ER_FK_DUP_NAME'; +exports[1827] = 'ER_PASSWORD_FORMAT'; +exports[1828] = 'ER_FK_COLUMN_CANNOT_DROP'; +exports[1829] = 'ER_FK_COLUMN_CANNOT_DROP_CHILD'; +exports[1830] = 'ER_FK_COLUMN_NOT_NULL'; +exports[1831] = 'ER_DUP_INDEX'; +exports[1832] = 'ER_FK_COLUMN_CANNOT_CHANGE'; +exports[1833] = 'ER_FK_COLUMN_CANNOT_CHANGE_CHILD'; +exports[1834] = 'ER_FK_CANNOT_DELETE_PARENT'; +exports[1835] = 'ER_MALFORMED_PACKET'; +exports[1836] = 'ER_READ_ONLY_MODE'; +exports[1837] = 'ER_GTID_NEXT_TYPE_UNDEFINED_GROUP'; +exports[1838] = 'ER_VARIABLE_NOT_SETTABLE_IN_SP'; +exports[1839] = 'ER_CANT_SET_GTID_PURGED_WHEN_GTID_MODE_IS_OFF'; +exports[1840] = 'ER_CANT_SET_GTID_PURGED_WHEN_GTID_EXECUTED_IS_NOT_EMPTY'; +exports[1841] = 'ER_CANT_SET_GTID_PURGED_WHEN_OWNED_GTIDS_IS_NOT_EMPTY'; +exports[1842] = 'ER_GTID_PURGED_WAS_CHANGED'; +exports[1843] = 'ER_GTID_EXECUTED_WAS_CHANGED'; +exports[1844] = 'ER_BINLOG_STMT_MODE_AND_NO_REPL_TABLES'; +exports[1845] = 'ER_ALTER_OPERATION_NOT_SUPPORTED'; +exports[1846] = 'ER_ALTER_OPERATION_NOT_SUPPORTED_REASON'; +exports[1847] = 'ER_ALTER_OPERATION_NOT_SUPPORTED_REASON_COPY'; +exports[1848] = 'ER_ALTER_OPERATION_NOT_SUPPORTED_REASON_PARTITION'; +exports[1849] = 'ER_ALTER_OPERATION_NOT_SUPPORTED_REASON_FK_RENAME'; +exports[1850] = 'ER_ALTER_OPERATION_NOT_SUPPORTED_REASON_COLUMN_TYPE'; +exports[1851] = 'ER_ALTER_OPERATION_NOT_SUPPORTED_REASON_FK_CHECK'; +exports[1852] = 'ER_ALTER_OPERATION_NOT_SUPPORTED_REASON_IGNORE'; +exports[1853] = 'ER_ALTER_OPERATION_NOT_SUPPORTED_REASON_NOPK'; +exports[1854] = 'ER_ALTER_OPERATION_NOT_SUPPORTED_REASON_AUTOINC'; +exports[1855] = 'ER_ALTER_OPERATION_NOT_SUPPORTED_REASON_HIDDEN_FTS'; +exports[1856] = 'ER_ALTER_OPERATION_NOT_SUPPORTED_REASON_CHANGE_FTS'; +exports[1857] = 'ER_ALTER_OPERATION_NOT_SUPPORTED_REASON_FTS'; +exports[1858] = 'ER_SQL_SLAVE_SKIP_COUNTER_NOT_SETTABLE_IN_GTID_MODE'; +exports[1859] = 'ER_DUP_UNKNOWN_IN_INDEX'; +exports[1860] = 'ER_IDENT_CAUSES_TOO_LONG_PATH'; +exports[1861] = 'ER_ALTER_OPERATION_NOT_SUPPORTED_REASON_NOT_NULL'; +exports[1862] = 'ER_MUST_CHANGE_PASSWORD_LOGIN'; +exports[1863] = 'ER_ROW_IN_WRONG_PARTITION'; +exports[1864] = 'ER_MTS_EVENT_BIGGER_PENDING_JOBS_SIZE_MAX'; +exports[1865] = 'ER_INNODB_NO_FT_USES_PARSER'; +exports[1866] = 'ER_BINLOG_LOGICAL_CORRUPTION'; +exports[1867] = 'ER_WARN_PURGE_LOG_IN_USE'; +exports[1868] = 'ER_WARN_PURGE_LOG_IS_ACTIVE'; +exports[1869] = 'ER_AUTO_INCREMENT_CONFLICT'; +exports[1870] = 'WARN_ON_BLOCKHOLE_IN_RBR'; +exports[1871] = 'ER_SLAVE_MI_INIT_REPOSITORY'; +exports[1872] = 'ER_SLAVE_RLI_INIT_REPOSITORY'; +exports[1873] = 'ER_ACCESS_DENIED_CHANGE_USER_ERROR'; +exports[1874] = 'ER_INNODB_READ_ONLY'; +exports[1875] = 'ER_STOP_SLAVE_SQL_THREAD_TIMEOUT'; +exports[1876] = 'ER_STOP_SLAVE_IO_THREAD_TIMEOUT'; +exports[1877] = 'ER_TABLE_CORRUPT'; +exports[1878] = 'ER_TEMP_FILE_WRITE_FAILURE'; +exports[1879] = 'ER_INNODB_FT_AUX_NOT_HEX_ID'; +exports[1880] = 'ER_OLD_TEMPORALS_UPGRADED'; +exports[1881] = 'ER_INNODB_FORCED_RECOVERY'; +exports[1882] = 'ER_AES_INVALID_IV'; diff --git a/node_modules/mysql/lib/protocol/constants/field_flags.js b/node_modules/mysql/lib/protocol/constants/field_flags.js new file mode 100644 index 0000000..c698da5 --- /dev/null +++ b/node_modules/mysql/lib/protocol/constants/field_flags.js @@ -0,0 +1,18 @@ +// Manually extracted from mysql-5.5.23/include/mysql_com.h +exports.NOT_NULL_FLAG = 1; /* Field can't be NULL */ +exports.PRI_KEY_FLAG = 2; /* Field is part of a primary key */ +exports.UNIQUE_KEY_FLAG = 4; /* Field is part of a unique key */ +exports.MULTIPLE_KEY_FLAG = 8; /* Field is part of a key */ +exports.BLOB_FLAG = 16; /* Field is a blob */ +exports.UNSIGNED_FLAG = 32; /* Field is unsigned */ +exports.ZEROFILL_FLAG = 64; /* Field is zerofill */ +exports.BINARY_FLAG = 128; /* Field is binary */ + +/* The following are only sent to new clients */ +exports.ENUM_FLAG = 256; /* field is an enum */ +exports.AUTO_INCREMENT_FLAG = 512; /* field is a autoincrement field */ +exports.TIMESTAMP_FLAG = 1024; /* Field is a timestamp */ +exports.SET_FLAG = 2048; /* field is a set */ +exports.NO_DEFAULT_VALUE_FLAG = 4096; /* Field doesn't have default value */ +exports.ON_UPDATE_NOW_FLAG = 8192; /* Field is set to NOW on UPDATE */ +exports.NUM_FLAG = 32768; /* Field is num (for clients) */ diff --git a/node_modules/mysql/lib/protocol/constants/server_status.js b/node_modules/mysql/lib/protocol/constants/server_status.js new file mode 100644 index 0000000..5537ee5 --- /dev/null +++ b/node_modules/mysql/lib/protocol/constants/server_status.js @@ -0,0 +1,39 @@ +// Manually extracted from mysql-5.5.23/include/mysql_com.h + +/** + Is raised when a multi-statement transaction + has been started, either explicitly, by means + of BEGIN or COMMIT AND CHAIN, or + implicitly, by the first transactional + statement, when autocommit=off. +*/ +exports.SERVER_STATUS_IN_TRANS = 1; +exports.SERVER_STATUS_AUTOCOMMIT = 2; /* Server in auto_commit mode */ +exports.SERVER_MORE_RESULTS_EXISTS = 8; /* Multi query - next query exists */ +exports.SERVER_QUERY_NO_GOOD_INDEX_USED = 16; +exports.SERVER_QUERY_NO_INDEX_USED = 32; +/** + The server was able to fulfill the clients request and opened a + read-only non-scrollable cursor for a query. This flag comes + in reply to COM_STMT_EXECUTE and COM_STMT_FETCH commands. +*/ +exports.SERVER_STATUS_CURSOR_EXISTS = 64; +/** + This flag is sent when a read-only cursor is exhausted, in reply to + COM_STMT_FETCH command. +*/ +exports.SERVER_STATUS_LAST_ROW_SENT = 128; +exports.SERVER_STATUS_DB_DROPPED = 256; /* A database was dropped */ +exports.SERVER_STATUS_NO_BACKSLASH_ESCAPES = 512; +/** + Sent to the client if after a prepared statement reprepare + we discovered that the new statement returns a different + number of result set columns. +*/ +exports.SERVER_STATUS_METADATA_CHANGED = 1024; +exports.SERVER_QUERY_WAS_SLOW = 2048; + +/** + To mark ResultSet containing output parameter values. +*/ +exports.SERVER_PS_OUT_PARAMS = 4096; diff --git a/node_modules/mysql/lib/protocol/constants/types.js b/node_modules/mysql/lib/protocol/constants/types.js new file mode 100644 index 0000000..21c4000 --- /dev/null +++ b/node_modules/mysql/lib/protocol/constants/types.js @@ -0,0 +1,29 @@ +// Manually extracted from mysql-5.5.23/include/mysql_com.h +// some more info here: http://dev.mysql.com/doc/refman/5.5/en/c-api-prepared-statement-type-codes.html +exports.DECIMAL = 0x00; // aka DECIMAL (http://dev.mysql.com/doc/refman/5.0/en/precision-math-decimal-changes.html) +exports.TINY = 0x01; // aka TINYINT, 1 byte +exports.SHORT = 0x02; // aka SMALLINT, 2 bytes +exports.LONG = 0x03; // aka INT, 4 bytes +exports.FLOAT = 0x04; // aka FLOAT, 4-8 bytes +exports.DOUBLE = 0x05; // aka DOUBLE, 8 bytes +exports.NULL = 0x06; // NULL (used for prepared statements, I think) +exports.TIMESTAMP = 0x07; // aka TIMESTAMP +exports.LONGLONG = 0x08; // aka BIGINT, 8 bytes +exports.INT24 = 0x09; // aka MEDIUMINT, 3 bytes +exports.DATE = 0x0a; // aka DATE +exports.TIME = 0x0b; // aka TIME +exports.DATETIME = 0x0c; // aka DATETIME +exports.YEAR = 0x0d; // aka YEAR, 1 byte (don't ask) +exports.NEWDATE = 0x0e; // aka ? +exports.VARCHAR = 0x0f; // aka VARCHAR (?) +exports.BIT = 0x10; // aka BIT, 1-8 byte +exports.NEWDECIMAL = 0xf6; // aka DECIMAL +exports.ENUM = 0xf7; // aka ENUM +exports.SET = 0xf8; // aka SET +exports.TINY_BLOB = 0xf9; // aka TINYBLOB, TINYTEXT +exports.MEDIUM_BLOB = 0xfa; // aka MEDIUMBLOB, MEDIUMTEXT +exports.LONG_BLOB = 0xfb; // aka LONGBLOG, LONGTEXT +exports.BLOB = 0xfc; // aka BLOB, TEXT +exports.VAR_STRING = 0xfd; // aka VARCHAR, VARBINARY +exports.STRING = 0xfe; // aka CHAR, BINARY +exports.GEOMETRY = 0xff; // aka GEOMETRY diff --git a/node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js b/node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js new file mode 100644 index 0000000..a66d28b --- /dev/null +++ b/node_modules/mysql/lib/protocol/packets/ClientAuthenticationPacket.js @@ -0,0 +1,52 @@ +module.exports = ClientAuthenticationPacket; +function ClientAuthenticationPacket(options) { + options = options || {}; + + this.clientFlags = options.clientFlags; + this.maxPacketSize = options.maxPacketSize; + this.charsetNumber = options.charsetNumber; + this.filler = undefined; + this.user = options.user; + this.scrambleBuff = options.scrambleBuff; + this.database = options.database; + this.protocol41 = options.protocol41; +} + +ClientAuthenticationPacket.prototype.parse = function(parser) { + if (this.protocol41) { + this.clientFlags = parser.parseUnsignedNumber(4); + this.maxPacketSize = parser.parseUnsignedNumber(4); + this.charsetNumber = parser.parseUnsignedNumber(1); + this.filler = parser.parseFiller(23); + this.user = parser.parseNullTerminatedString(); + this.scrambleBuff = parser.parseLengthCodedBuffer(); + this.database = parser.parseNullTerminatedString(); + } else { + this.clientFlags = parser.parseUnsignedNumber(2); + this.maxPacketSize = parser.parseUnsignedNumber(3); + this.user = parser.parseNullTerminatedString(); + this.scrambleBuff = parser.parseBuffer(8); + this.database = parser.parseLengthCodedBuffer(); + } +}; + +ClientAuthenticationPacket.prototype.write = function(writer) { + if (this.protocol41) { + writer.writeUnsignedNumber(4, this.clientFlags); + writer.writeUnsignedNumber(4, this.maxPacketSize); + writer.writeUnsignedNumber(1, this.charsetNumber); + writer.writeFiller(23); + writer.writeNullTerminatedString(this.user); + writer.writeLengthCodedBuffer(this.scrambleBuff); + writer.writeNullTerminatedString(this.database); + } else { + writer.writeUnsignedNumber(2, this.clientFlags); + writer.writeUnsignedNumber(3, this.maxPacketSize); + writer.writeNullTerminatedString(this.user); + writer.writeBuffer(this.scrambleBuff); + if (this.database && this.database.length) { + writer.writeFiller(1); + writer.writeBuffer(new Buffer(this.database)); + } + } +}; diff --git a/node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js b/node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js new file mode 100644 index 0000000..3278842 --- /dev/null +++ b/node_modules/mysql/lib/protocol/packets/ComChangeUserPacket.js @@ -0,0 +1,26 @@ +module.exports = ComChangeUserPacket; +function ComChangeUserPacket(options) { + options = options || {}; + + this.command = 0x11; + this.user = options.user; + this.scrambleBuff = options.scrambleBuff; + this.database = options.database; + this.charsetNumber = options.charsetNumber; +} + +ComChangeUserPacket.prototype.parse = function(parser) { + this.command = parser.parseUnsignedNumber(1); + this.user = parser.parseNullTerminatedString(); + this.scrambleBuff = parser.parseLengthCodedBuffer(); + this.database = parser.parseNullTerminatedString(); + this.charsetNumber = parser.parseUnsignedNumber(1); +}; + +ComChangeUserPacket.prototype.write = function(writer) { + writer.writeUnsignedNumber(1, this.command); + writer.writeNullTerminatedString(this.user); + writer.writeLengthCodedBuffer(this.scrambleBuff); + writer.writeNullTerminatedString(this.database); + writer.writeUnsignedNumber(2, this.charsetNumber); +}; diff --git a/node_modules/mysql/lib/protocol/packets/ComPingPacket.js b/node_modules/mysql/lib/protocol/packets/ComPingPacket.js new file mode 100644 index 0000000..359eef5 --- /dev/null +++ b/node_modules/mysql/lib/protocol/packets/ComPingPacket.js @@ -0,0 +1,12 @@ +module.exports = ComPingPacket; +function ComPingPacket(sql) { + this.command = 0x0e; +} + +ComPingPacket.prototype.write = function(writer) { + writer.writeUnsignedNumber(1, this.command); +}; + +ComPingPacket.prototype.parse = function(parser) { + this.command = parser.parseUnsignedNumber(1); +}; diff --git a/node_modules/mysql/lib/protocol/packets/ComQueryPacket.js b/node_modules/mysql/lib/protocol/packets/ComQueryPacket.js new file mode 100644 index 0000000..7ac191f --- /dev/null +++ b/node_modules/mysql/lib/protocol/packets/ComQueryPacket.js @@ -0,0 +1,15 @@ +module.exports = ComQueryPacket; +function ComQueryPacket(sql) { + this.command = 0x03; + this.sql = sql; +} + +ComQueryPacket.prototype.write = function(writer) { + writer.writeUnsignedNumber(1, this.command); + writer.writeString(this.sql); +}; + +ComQueryPacket.prototype.parse = function(parser) { + this.command = parser.parseUnsignedNumber(1); + this.sql = parser.parsePacketTerminatedString(); +}; diff --git a/node_modules/mysql/lib/protocol/packets/ComQuitPacket.js b/node_modules/mysql/lib/protocol/packets/ComQuitPacket.js new file mode 100644 index 0000000..26a08f8 --- /dev/null +++ b/node_modules/mysql/lib/protocol/packets/ComQuitPacket.js @@ -0,0 +1,12 @@ +module.exports = ComQuitPacket; +function ComQuitPacket(sql) { + this.command = 0x01; +} + +ComQuitPacket.prototype.parse = function parse(parser) { + this.command = parser.parseUnsignedNumber(1); +}; + +ComQuitPacket.prototype.write = function write(writer) { + writer.writeUnsignedNumber(1, this.command); +}; diff --git a/node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js b/node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js new file mode 100644 index 0000000..fe11d18 --- /dev/null +++ b/node_modules/mysql/lib/protocol/packets/ComStatisticsPacket.js @@ -0,0 +1,12 @@ +module.exports = ComStatisticsPacket; +function ComStatisticsPacket(sql) { + this.command = 0x09; +} + +ComStatisticsPacket.prototype.write = function(writer) { + writer.writeUnsignedNumber(1, this.command); +}; + +ComStatisticsPacket.prototype.parse = function(parser) { + this.command = parser.parseUnsignedNumber(1); +}; diff --git a/node_modules/mysql/lib/protocol/packets/EmptyPacket.js b/node_modules/mysql/lib/protocol/packets/EmptyPacket.js new file mode 100644 index 0000000..f02189c --- /dev/null +++ b/node_modules/mysql/lib/protocol/packets/EmptyPacket.js @@ -0,0 +1,6 @@ +module.exports = EmptyPacket; +function EmptyPacket() { +} + +EmptyPacket.prototype.write = function(writer) { +}; diff --git a/node_modules/mysql/lib/protocol/packets/EofPacket.js b/node_modules/mysql/lib/protocol/packets/EofPacket.js new file mode 100644 index 0000000..b80ca5e --- /dev/null +++ b/node_modules/mysql/lib/protocol/packets/EofPacket.js @@ -0,0 +1,25 @@ +module.exports = EofPacket; +function EofPacket(options) { + options = options || {}; + + this.fieldCount = undefined; + this.warningCount = options.warningCount; + this.serverStatus = options.serverStatus; + this.protocol41 = options.protocol41; +} + +EofPacket.prototype.parse = function(parser) { + this.fieldCount = parser.parseUnsignedNumber(1); + if (this.protocol41) { + this.warningCount = parser.parseUnsignedNumber(2); + this.serverStatus = parser.parseUnsignedNumber(2); + } +}; + +EofPacket.prototype.write = function(writer) { + writer.writeUnsignedNumber(1, 0xfe); + if (this.protocol41) { + writer.writeUnsignedNumber(2, this.warningCount); + writer.writeUnsignedNumber(2, this.serverStatus); + } +}; diff --git a/node_modules/mysql/lib/protocol/packets/ErrorPacket.js b/node_modules/mysql/lib/protocol/packets/ErrorPacket.js new file mode 100644 index 0000000..e03de00 --- /dev/null +++ b/node_modules/mysql/lib/protocol/packets/ErrorPacket.js @@ -0,0 +1,35 @@ +module.exports = ErrorPacket; +function ErrorPacket(options) { + options = options || {}; + + this.fieldCount = options.fieldCount; + this.errno = options.errno; + this.sqlStateMarker = options.sqlStateMarker; + this.sqlState = options.sqlState; + this.message = options.message; +} + +ErrorPacket.prototype.parse = function(parser) { + this.fieldCount = parser.parseUnsignedNumber(1); + this.errno = parser.parseUnsignedNumber(2); + + // sqlStateMarker ('#' = 0x23) indicates error packet format + if (parser.peak() === 0x23) { + this.sqlStateMarker = parser.parseString(1); + this.sqlState = parser.parseString(5); + } + + this.message = parser.parsePacketTerminatedString(); +}; + +ErrorPacket.prototype.write = function(writer) { + writer.writeUnsignedNumber(1, 0xff); + writer.writeUnsignedNumber(2, this.errno); + + if (this.sqlStateMarker) { + writer.writeString(this.sqlStateMarker); + writer.writeString(this.sqlState); + } + + writer.writeString(this.message); +}; diff --git a/node_modules/mysql/lib/protocol/packets/Field.js b/node_modules/mysql/lib/protocol/packets/Field.js new file mode 100644 index 0000000..b686a88 --- /dev/null +++ b/node_modules/mysql/lib/protocol/packets/Field.js @@ -0,0 +1,32 @@ +var Types = require('../constants/types'); + +module.exports = Field; +function Field(options) { + options = options || {}; + + this.parser = options.parser; + this.packet = options.packet; + this.db = options.packet.db; + this.table = options.packet.table; + this.name = options.packet.name; + this.type = typeToString(options.packet.type); + this.length = options.packet.length; +} + +Field.prototype.string = function () { + return this.parser.parseLengthCodedString(); +}; + +Field.prototype.buffer = function () { + return this.parser.parseLengthCodedBuffer(); +}; + +Field.prototype.geometry = function () { + return this.parser.parseGeometryValue(); +}; + +function typeToString(t) { + for (var k in Types) { + if (Types[k] == t) return k; + } +} diff --git a/node_modules/mysql/lib/protocol/packets/FieldPacket.js b/node_modules/mysql/lib/protocol/packets/FieldPacket.js new file mode 100644 index 0000000..d8fd68f --- /dev/null +++ b/node_modules/mysql/lib/protocol/packets/FieldPacket.js @@ -0,0 +1,93 @@ +module.exports = FieldPacket; +function FieldPacket(options) { + options = options || {}; + + this.catalog = options.catalog; + this.db = options.db; + this.table = options.table; + this.orgTable = options.orgTable; + this.name = options.name; + this.orgName = options.orgName; + this.charsetNr = options.charsetNr; + this.length = options.length; + this.type = options.type; + this.flags = options.flags; + this.decimals = options.decimals; + this.default = options.default; + this.zeroFill = options.zeroFill; + this.protocol41 = options.protocol41 +} + +FieldPacket.prototype.parse = function(parser) { + if (this.protocol41) { + this.catalog = parser.parseLengthCodedString(); + this.db = parser.parseLengthCodedString(); + this.table = parser.parseLengthCodedString(); + this.orgTable = parser.parseLengthCodedString(); + this.name = parser.parseLengthCodedString(); + this.orgName = parser.parseLengthCodedString(); + + if (parser.parseLengthCodedNumber() !== 0x0c) { + var err = new TypeError('Received invalid field length'); + err.code = 'PARSER_INVALID_FIELD_LENGTH'; + throw err; + } + + this.charsetNr = parser.parseUnsignedNumber(2); + this.length = parser.parseUnsignedNumber(4); + this.type = parser.parseUnsignedNumber(1); + this.flags = parser.parseUnsignedNumber(2); + this.decimals = parser.parseUnsignedNumber(1); + + var filler = parser.parseBuffer(2); + if (filler[0] !== 0x0 || filler[1] !== 0x0) { + var err = new TypeError('Received invalid filler'); + err.code = 'PARSER_INVALID_FILLER'; + throw err; + } + + // parsed flags + this.zeroFill = (this.flags & 0x0040 ? true : false); + + if (parser.reachedPacketEnd()) { + return; + } + + this.default = parser.parseLengthCodedString(); + } else { + this.table = parser.parseLengthCodedString(); + this.name = parser.parseLengthCodedString(); + this.length = parser.parseUnsignedNumber(parser.parseUnsignedNumber(1)); + this.type = parser.parseUnsignedNumber(parser.parseUnsignedNumber(1)); + } +}; + +FieldPacket.prototype.write = function(writer) { + if (this.protocol41) { + writer.writeLengthCodedString(this.catalog); + writer.writeLengthCodedString(this.db); + writer.writeLengthCodedString(this.table); + writer.writeLengthCodedString(this.orgTable); + writer.writeLengthCodedString(this.name); + writer.writeLengthCodedString(this.orgName); + + writer.writeLengthCodedNumber(0x0c); + writer.writeUnsignedNumber(2, this.charsetNr || 0); + writer.writeUnsignedNumber(4, this.length || 0); + writer.writeUnsignedNumber(1, this.type || 0); + writer.writeUnsignedNumber(2, this.flags || 0); + writer.writeUnsignedNumber(1, this.decimals || 0); + writer.writeFiller(2); + + if (this.default !== undefined) { + writer.writeLengthCodedString(this.default); + } + } else { + writer.writeLengthCodedString(this.table); + writer.writeLengthCodedString(this.name); + writer.writeUnsignedNumber(1, 0x01); + writer.writeUnsignedNumber(1, this.length); + writer.writeUnsignedNumber(1, 0x01); + writer.writeUnsignedNumber(1, this.type); + } +}; diff --git a/node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js b/node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js new file mode 100644 index 0000000..a55372a --- /dev/null +++ b/node_modules/mysql/lib/protocol/packets/HandshakeInitializationPacket.js @@ -0,0 +1,100 @@ +var Client = require('../constants/client'); + +module.exports = HandshakeInitializationPacket; +function HandshakeInitializationPacket(options) { + options = options || {}; + + this.protocolVersion = options.protocolVersion; + this.serverVersion = options.serverVersion; + this.threadId = options.threadId; + this.scrambleBuff1 = options.scrambleBuff1; + this.filler1 = options.filler1; + this.serverCapabilities1 = options.serverCapabilities1; + this.serverLanguage = options.serverLanguage; + this.serverStatus = options.serverStatus; + this.serverCapabilities2 = options.serverCapabilities2; + this.scrambleLength = options.scrambleLength; + this.filler2 = options.filler2; + this.scrambleBuff2 = options.scrambleBuff2; + this.filler3 = options.filler3; + this.pluginData = options.pluginData; + this.protocol41 = options.protocol41; + + if (this.protocol41) { + // force set the bit in serverCapabilities1 + this.serverCapabilities1 |= Client.CLIENT_PROTOCOL_41; + } +} + +HandshakeInitializationPacket.prototype.parse = function(parser) { + this.protocolVersion = parser.parseUnsignedNumber(1); + this.serverVersion = parser.parseNullTerminatedString(); + this.threadId = parser.parseUnsignedNumber(4); + this.scrambleBuff1 = parser.parseBuffer(8); + this.filler1 = parser.parseFiller(1); + this.serverCapabilities1 = parser.parseUnsignedNumber(2); + this.serverLanguage = parser.parseUnsignedNumber(1); + this.serverStatus = parser.parseUnsignedNumber(2); + + this.protocol41 = (this.serverCapabilities1 & (1 << 9)) > 0; + + if (this.protocol41) { + this.serverCapabilities2 = parser.parseUnsignedNumber(2); + this.scrambleLength = parser.parseUnsignedNumber(1); + this.filler2 = parser.parseFiller(10); + // scrambleBuff2 should be 0x00 terminated, but sphinx does not do this + // so we assume scrambleBuff2 to be 12 byte and treat the next byte as a + // filler byte. + this.scrambleBuff2 = parser.parseBuffer(12); + this.filler3 = parser.parseFiller(1); + } else { + this.filler2 = parser.parseFiller(13); + } + + if (parser.reachedPacketEnd()) { + return; + } + + // According to the docs this should be 0x00 terminated, but MariaDB does + // not do this, so we assume this string to be packet terminated. + this.pluginData = parser.parsePacketTerminatedString(); + + // However, if there is a trailing '\0', strip it + var lastChar = this.pluginData.length - 1; + if (this.pluginData[lastChar] === '\0') { + this.pluginData = this.pluginData.substr(0, lastChar); + } +}; + +HandshakeInitializationPacket.prototype.write = function(writer) { + writer.writeUnsignedNumber(1, this.protocolVersion); + writer.writeNullTerminatedString(this.serverVersion); + writer.writeUnsignedNumber(4, this.threadId); + writer.writeBuffer(this.scrambleBuff1); + writer.writeFiller(1); + writer.writeUnsignedNumber(2, this.serverCapabilities1); + writer.writeUnsignedNumber(1, this.serverLanguage); + writer.writeUnsignedNumber(2, this.serverStatus); + if (this.protocol41) { + writer.writeUnsignedNumber(2, this.serverCapabilities2); + writer.writeUnsignedNumber(1, this.scrambleLength); + writer.writeFiller(10); + } + writer.writeNullTerminatedBuffer(this.scrambleBuff2); + + if (this.pluginData !== undefined) { + writer.writeNullTerminatedString(this.pluginData); + } +}; + +HandshakeInitializationPacket.prototype.scrambleBuff = function() { + var buffer = new Buffer(this.scrambleBuff1.length + + (typeof this.scrambleBuff2 != "undefined" ? this.scrambleBuff2.length : 0)); + + this.scrambleBuff1.copy(buffer); + if (typeof this.scrambleBuff2 != "undefined") { + this.scrambleBuff2.copy(buffer, this.scrambleBuff1.length); + } + + return buffer; +}; diff --git a/node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js b/node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js new file mode 100644 index 0000000..8a79a08 --- /dev/null +++ b/node_modules/mysql/lib/protocol/packets/LocalDataFilePacket.js @@ -0,0 +1,11 @@ +module.exports = LocalDataFilePacket; +/** + * @param {Buffer} data + */ +function LocalDataFilePacket(data) { + this.data = data; +} + +LocalDataFilePacket.prototype.write = function(writer) { + writer.writeBuffer(this.data); +}; diff --git a/node_modules/mysql/lib/protocol/packets/OkPacket.js b/node_modules/mysql/lib/protocol/packets/OkPacket.js new file mode 100644 index 0000000..0d9a096 --- /dev/null +++ b/node_modules/mysql/lib/protocol/packets/OkPacket.js @@ -0,0 +1,41 @@ +module.exports = OkPacket; +function OkPacket(options) { + options = options || {}; + + this.fieldCount = undefined; + this.affectedRows = undefined; + this.insertId = undefined; + this.serverStatus = undefined; + this.warningCount = undefined; + this.message = undefined; + this.protocol41 = options.protocol41; +} + +OkPacket.prototype.parse = function(parser) { + this.fieldCount = parser.parseUnsignedNumber(1); + this.affectedRows = parser.parseLengthCodedNumber(); + this.insertId = parser.parseLengthCodedNumber(); + if (this.protocol41) { + this.serverStatus = parser.parseUnsignedNumber(2); + this.warningCount = parser.parseUnsignedNumber(2); + } + this.message = parser.parsePacketTerminatedString(); + this.changedRows = 0; + + var m = this.message.match(/\schanged:\s*(\d+)/i); + + if (m !== null) { + this.changedRows = parseInt(m[1], 10); + } +}; + +OkPacket.prototype.write = function(writer) { + writer.writeUnsignedNumber(1, 0x00); + writer.writeLengthCodedNumber(this.affectedRows || 0); + writer.writeLengthCodedNumber(this.insertId || 0); + if (this.protocol41) { + writer.writeUnsignedNumber(2, this.serverStatus || 0); + writer.writeUnsignedNumber(2, this.warningCount || 0); + } + writer.writeString(this.message); +}; diff --git a/node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js b/node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js new file mode 100644 index 0000000..1ff78ec --- /dev/null +++ b/node_modules/mysql/lib/protocol/packets/OldPasswordPacket.js @@ -0,0 +1,15 @@ +module.exports = OldPasswordPacket; +function OldPasswordPacket(options) { + options = options || {}; + + this.scrambleBuff = options.scrambleBuff; +} + +OldPasswordPacket.prototype.parse = function(parser) { + this.scrambleBuff = parser.parseNullTerminatedBuffer(); +}; + +OldPasswordPacket.prototype.write = function(writer) { + writer.writeBuffer(this.scrambleBuff); + writer.writeFiller(1); +}; diff --git a/node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js b/node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js new file mode 100644 index 0000000..25b8002 --- /dev/null +++ b/node_modules/mysql/lib/protocol/packets/ResultSetHeaderPacket.js @@ -0,0 +1,25 @@ +module.exports = ResultSetHeaderPacket; +function ResultSetHeaderPacket(options) { + options = options || {}; + + this.fieldCount = options.fieldCount; + this.extra = options.extra; +} + +ResultSetHeaderPacket.prototype.parse = function(parser) { + this.fieldCount = parser.parseLengthCodedNumber(); + + if (parser.reachedPacketEnd()) return; + + this.extra = (this.fieldCount === null) + ? parser.parsePacketTerminatedString() + : parser.parseLengthCodedNumber(); +}; + +ResultSetHeaderPacket.prototype.write = function(writer) { + writer.writeLengthCodedNumber(this.fieldCount); + + if (this.extra !== undefined) { + writer.writeLengthCodedNumber(this.extra); + } +}; diff --git a/node_modules/mysql/lib/protocol/packets/RowDataPacket.js b/node_modules/mysql/lib/protocol/packets/RowDataPacket.js new file mode 100644 index 0000000..82fa134 --- /dev/null +++ b/node_modules/mysql/lib/protocol/packets/RowDataPacket.js @@ -0,0 +1,120 @@ +var Types = require('../constants/types'); +var Charsets = require('../constants/charsets'); +var Field = require('./Field'); +var IEEE_754_BINARY_64_PRECISION = Math.pow(2, 53); + +module.exports = RowDataPacket; +function RowDataPacket() { +} + +Object.defineProperty(RowDataPacket.prototype, 'parse', { + configurable: true, + enumerable: false, + value: parse +}); + +Object.defineProperty(RowDataPacket.prototype, '_typeCast', { + configurable: true, + enumerable: false, + value: typeCast +}); + +function parse(parser, fieldPackets, typeCast, nestTables, connection) { + var self = this; + var next = function () { + return self._typeCast(fieldPacket, parser, connection.config.timezone, connection.config.supportBigNumbers, connection.config.bigNumberStrings, connection.config.dateStrings); + }; + + for (var i = 0; i < fieldPackets.length; i++) { + var fieldPacket = fieldPackets[i]; + var value; + + if (typeof typeCast == "function") { + value = typeCast.apply(connection, [ new Field({ packet: fieldPacket, parser: parser }), next ]); + } else { + value = (typeCast) + ? this._typeCast(fieldPacket, parser, connection.config.timezone, connection.config.supportBigNumbers, connection.config.bigNumberStrings, connection.config.dateStrings) + : ( (fieldPacket.charsetNr === Charsets.BINARY) + ? parser.parseLengthCodedBuffer() + : parser.parseLengthCodedString() ); + } + + if (typeof nestTables == "string" && nestTables.length) { + this[fieldPacket.table + nestTables + fieldPacket.name] = value; + } else if (nestTables) { + this[fieldPacket.table] = this[fieldPacket.table] || {}; + this[fieldPacket.table][fieldPacket.name] = value; + } else { + this[fieldPacket.name] = value; + } + } +} + +function typeCast(field, parser, timeZone, supportBigNumbers, bigNumberStrings, dateStrings) { + var numberString; + + switch (field.type) { + case Types.TIMESTAMP: + case Types.DATE: + case Types.DATETIME: + case Types.NEWDATE: + var dateString = parser.parseLengthCodedString(); + if (dateStrings) { + return dateString; + } + var dt; + + if (dateString === null) { + return null; + } + + var originalString = dateString; + if (field.type === Types.DATE) { + dateString += ' 00:00:00'; + } + + if (timeZone !== 'local') { + dateString += ' ' + timeZone; + } + + dt = new Date(dateString); + if (isNaN(dt.getTime())) { + return originalString; + } + + return dt; + case Types.TINY: + case Types.SHORT: + case Types.LONG: + case Types.INT24: + case Types.YEAR: + case Types.FLOAT: + case Types.DOUBLE: + numberString = parser.parseLengthCodedString(); + return (numberString === null || (field.zeroFill && numberString[0] == "0")) + ? numberString : Number(numberString); + case Types.NEWDECIMAL: + case Types.LONGLONG: + numberString = parser.parseLengthCodedString(); + return (numberString === null || (field.zeroFill && numberString[0] == "0")) + ? numberString + : ((supportBigNumbers && (bigNumberStrings || (Number(numberString) > IEEE_754_BINARY_64_PRECISION))) + ? numberString + : Number(numberString)); + case Types.BIT: + return parser.parseLengthCodedBuffer(); + case Types.STRING: + case Types.VAR_STRING: + case Types.TINY_BLOB: + case Types.MEDIUM_BLOB: + case Types.LONG_BLOB: + case Types.BLOB: + return (field.charsetNr === Charsets.BINARY) + ? parser.parseLengthCodedBuffer() + : parser.parseLengthCodedString(); + case Types.GEOMETRY: + return parser.parseGeometryValue(); + default: + return parser.parseLengthCodedString(); + } +} diff --git a/node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js b/node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js new file mode 100644 index 0000000..a57cfc1 --- /dev/null +++ b/node_modules/mysql/lib/protocol/packets/SSLRequestPacket.js @@ -0,0 +1,27 @@ +// http://dev.mysql.com/doc/internals/en/ssl.html +// http://dev.mysql.com/doc/internals/en/connection-phase-packets.html#packet-Protocol::SSLRequest + +var ClientConstants = require('../constants/client'); + +module.exports = SSLRequestPacket; + +function SSLRequestPacket(options) { + options = options || {}; + this.clientFlags = options.clientFlags | ClientConstants.CLIENT_SSL; + this.maxPacketSize = options.maxPacketSize; + this.charsetNumber = options.charsetNumber; +} + +SSLRequestPacket.prototype.parse = function(parser) { + // TODO: check SSLRequest packet v41 vs pre v41 + this.clientFlags = parser.parseUnsignedNumber(4); + this.maxPacketSize = parser.parseUnsignedNumber(4); + this.charsetNumber = parser.parseUnsignedNumber(1); +}; + +SSLRequestPacket.prototype.write = function(writer) { + writer.writeUnsignedNumber(4, this.clientFlags); + writer.writeUnsignedNumber(4, this.maxPacketSize); + writer.writeUnsignedNumber(1, this.charsetNumber); + writer.writeFiller(23); +}; diff --git a/node_modules/mysql/lib/protocol/packets/StatisticsPacket.js b/node_modules/mysql/lib/protocol/packets/StatisticsPacket.js new file mode 100644 index 0000000..5f70b3b --- /dev/null +++ b/node_modules/mysql/lib/protocol/packets/StatisticsPacket.js @@ -0,0 +1,20 @@ +module.exports = StatisticsPacket; +function StatisticsPacket() { + this.message = undefined; +} + +StatisticsPacket.prototype.parse = function(parser) { + this.message = parser.parsePacketTerminatedString(); + + var items = this.message.split(/\s\s/); + for (var i = 0; i < items.length; i++) { + var m = items[i].match(/^(.+)\:\s+(.+)$/); + if (m !== null) { + this[m[1].toLowerCase().replace(/\s/g, '_')] = Number(m[2]); + } + } +}; + +StatisticsPacket.prototype.write = function(writer) { + writer.writeString(this.message); +}; diff --git a/node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js b/node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js new file mode 100644 index 0000000..d73bf44 --- /dev/null +++ b/node_modules/mysql/lib/protocol/packets/UseOldPasswordPacket.js @@ -0,0 +1,14 @@ +module.exports = UseOldPasswordPacket; +function UseOldPasswordPacket(options) { + options = options || {}; + + this.firstByte = options.firstByte || 0xfe; +} + +UseOldPasswordPacket.prototype.parse = function(parser) { + this.firstByte = parser.parseUnsignedNumber(1); +}; + +UseOldPasswordPacket.prototype.write = function(writer) { + writer.writeUnsignedNumber(1, this.firstByte); +}; diff --git a/node_modules/mysql/lib/protocol/packets/index.js b/node_modules/mysql/lib/protocol/packets/index.js new file mode 100644 index 0000000..a13d469 --- /dev/null +++ b/node_modules/mysql/lib/protocol/packets/index.js @@ -0,0 +1,4 @@ +var Elements = module.exports = require('require-all')({ + dirname : __dirname, + filter : /([A-Z].+)\.js$/, +}); diff --git a/node_modules/mysql/lib/protocol/sequences/ChangeUser.js b/node_modules/mysql/lib/protocol/sequences/ChangeUser.js new file mode 100644 index 0000000..e3f0640 --- /dev/null +++ b/node_modules/mysql/lib/protocol/sequences/ChangeUser.js @@ -0,0 +1,41 @@ +var Sequence = require('./Sequence'); +var Util = require('util'); +var Packets = require('../packets'); +var Auth = require('../Auth'); + +module.exports = ChangeUser; +Util.inherits(ChangeUser, Sequence); +function ChangeUser(options, callback) { + Sequence.call(this, options, callback); + + this._user = options.user; + this._password = options.password; + this._database = options.database; + this._charsetNumber = options.charsetNumber; + this._currentConfig = options.currentConfig; +} + +ChangeUser.prototype.start = function(handshakeInitializationPacket) { + var scrambleBuff = handshakeInitializationPacket.scrambleBuff(); + scrambleBuff = Auth.token(this._password, scrambleBuff); + + var packet = new Packets.ComChangeUserPacket({ + user : this._user, + scrambleBuff : scrambleBuff, + database : this._database, + charsetNumber : this._charsetNumber, + }); + + this._currentConfig.user = this._user; + this._currentConfig.password = this._password; + this._currentConfig.database = this._database; + this._currentConfig.charsetNumber = this._charsetNumber; + + this.emit('packet', packet); +}; + +ChangeUser.prototype['ErrorPacket'] = function(packet) { + var err = this._packetToError(packet); + err.fatal = true; + this.end(err); +}; diff --git a/node_modules/mysql/lib/protocol/sequences/Handshake.js b/node_modules/mysql/lib/protocol/sequences/Handshake.js new file mode 100644 index 0000000..b26988c --- /dev/null +++ b/node_modules/mysql/lib/protocol/sequences/Handshake.js @@ -0,0 +1,104 @@ +var Sequence = require('./Sequence'); +var Util = require('util'); +var Packets = require('../packets'); +var Auth = require('../Auth'); +var ClientConstants = require('../constants/client'); + +module.exports = Handshake; +Util.inherits(Handshake, Sequence); +function Handshake(options, callback) { + Sequence.call(this, options, callback); + + options = options || {}; + + this._config = options.config; + this._handshakeInitializationPacket = null; +} + +Handshake.prototype.determinePacket = function(firstByte) { + if (firstByte === 0xff) { + return Packets.ErrorPacket; + } + + if (!this._handshakeInitializationPacket) { + return Packets.HandshakeInitializationPacket; + } + + if (firstByte === 0xfe) { + return Packets.UseOldPasswordPacket; + } +}; + +Handshake.prototype['HandshakeInitializationPacket'] = function(packet) { + this._handshakeInitializationPacket = packet; + + this._config.protocol41 = packet.protocol41; + + var serverSSLSupport = packet.serverCapabilities1 & ClientConstants.CLIENT_SSL; + + if (this._config.ssl) { + if (!serverSSLSupport) { + var err = new Error('Server does not support secure connnection'); + + err.code = 'HANDSHAKE_NO_SSL_SUPPORT'; + err.fatal = true; + + this.end(err); + return; + } + + this._config.clientFlags |= ClientConstants.CLIENT_SSL; + this.emit('packet', new Packets.SSLRequestPacket({ + clientFlags : this._config.clientFlags, + maxPacketSize : this._config.maxPacketSize, + charsetNumber : this._config.charsetNumber + })); + this.emit('start-tls'); + } else { + this._sendCredentials(); + } +}; + +Handshake.prototype._tlsUpgradeCompleteHandler = function() { + this._sendCredentials(); +}; + +Handshake.prototype._sendCredentials = function(serverHello) { + var packet = this._handshakeInitializationPacket; + this.emit('packet', new Packets.ClientAuthenticationPacket({ + clientFlags : this._config.clientFlags, + maxPacketSize : this._config.maxPacketSize, + charsetNumber : this._config.charsetNumber, + user : this._config.user, + scrambleBuff : (packet.protocol41) + ? Auth.token(this._config.password, packet.scrambleBuff()) + : Auth.scramble323(packet.scrambleBuff(), this._config.password), + database : this._config.database, + protocol41 : packet.protocol41 + })); +}; + +Handshake.prototype['UseOldPasswordPacket'] = function(packet) { + if (!this._config.insecureAuth) { + var err = new Error( + 'MySQL server is requesting the old and insecure pre-4.1 auth mechanism.' + + 'Upgrade the user password or use the {insecureAuth: true} option.' + ); + + err.code = 'HANDSHAKE_INSECURE_AUTH'; + err.fatal = true; + + this.end(err); + return; + } + + this.emit('packet', new Packets.OldPasswordPacket({ + scrambleBuff : Auth.scramble323(this._handshakeInitializationPacket.scrambleBuff(), this._config.password), + })); +}; + +Handshake.prototype['ErrorPacket'] = function(packet) { + var err = this._packetToError(packet, true); + err.fatal = true; + this.end(err); +}; diff --git a/node_modules/mysql/lib/protocol/sequences/Ping.js b/node_modules/mysql/lib/protocol/sequences/Ping.js new file mode 100644 index 0000000..b298c92 --- /dev/null +++ b/node_modules/mysql/lib/protocol/sequences/Ping.js @@ -0,0 +1,19 @@ +var Sequence = require('./Sequence'); +var Util = require('util'); +var Packets = require('../packets'); + +module.exports = Ping; +Util.inherits(Ping, Sequence); + +function Ping(options, callback) { + if (!callback && typeof options === 'function') { + callback = options; + options = {}; + } + + Sequence.call(this, options, callback); +} + +Ping.prototype.start = function() { + this.emit('packet', new Packets.ComPingPacket); +}; diff --git a/node_modules/mysql/lib/protocol/sequences/Query.js b/node_modules/mysql/lib/protocol/sequences/Query.js new file mode 100644 index 0000000..0be2914 --- /dev/null +++ b/node_modules/mysql/lib/protocol/sequences/Query.js @@ -0,0 +1,218 @@ +var Sequence = require('./Sequence'); +var Util = require('util'); +var Packets = require('../packets'); +var ResultSet = require('../ResultSet'); +var ServerStatus = require('../constants/server_status'); +var fs = require('fs'); +var Readable = require('readable-stream'); + +module.exports = Query; +Util.inherits(Query, Sequence); +function Query(options, callback) { + Sequence.call(this, options, callback); + + this.sql = options.sql; + this.values = options.values; + this.typeCast = (options.typeCast === undefined) + ? true + : options.typeCast; + this.nestTables = options.nestTables || false; + + this._resultSet = null; + this._results = []; + this._fields = []; + this._index = 0; + this._loadError = null; +} + +Query.prototype.start = function() { + this.emit('packet', new Packets.ComQueryPacket(this.sql)); +}; + +Query.prototype.determinePacket = function(firstByte, parser) { + if (firstByte === 0) { + // If we have a resultSet and got one eofPacket + if (this._resultSet && this._resultSet.eofPackets.length === 1) { + // Then this is a RowDataPacket with an empty string in the first column. + // See: https://github.com/felixge/node-mysql/issues/222 + } else if (this._resultSet && this._resultSet.resultSetHeaderPacket + && this._resultSet.resultSetHeaderPacket.fieldCount !== null) { + return Packets.FieldPacket; + } else { + return; + } + } + + if (firstByte === 255) { + return; + } + + // EofPacket's are 5 bytes in mysql >= 4.1 + // This is the only / best way to differentiate their firstByte from a 9 + // byte length coded binary. + if (firstByte === 0xfe && parser.packetLength() < 9) { + return Packets.EofPacket; + } + + if (!this._resultSet) { + return Packets.ResultSetHeaderPacket; + } + + return (this._resultSet.eofPackets.length === 0) + ? Packets.FieldPacket + : Packets.RowDataPacket; +}; + +Query.prototype['OkPacket'] = function(packet) { + // try...finally for exception safety + try { + if (!this._callback) { + this.emit('result', packet, this._index); + } else { + this._results.push(packet); + this._fields.push(undefined); + } + } finally { + this._index++; + this._handleFinalResultPacket(packet); + } +}; + +Query.prototype['ErrorPacket'] = function(packet) { + var err = this._packetToError(packet); + + var results = (this._results.length > 0) + ? this._results + : undefined; + + var fields = (this._fields.length > 0) + ? this._fields + : undefined; + + err.index = this._index; + this.end(err, results, fields); +}; + +Query.prototype['ResultSetHeaderPacket'] = function(packet) { + this._resultSet = new ResultSet(packet); + + // used by LOAD DATA LOCAL INFILE queries + if (packet.fieldCount === null) { + this._sendLocalDataFile(packet.extra); + } +}; + +Query.prototype['FieldPacket'] = function(packet) { + this._resultSet.fieldPackets.push(packet); +}; + +Query.prototype['EofPacket'] = function(packet) { + this._resultSet.eofPackets.push(packet); + + if (this._resultSet.eofPackets.length === 1 && !this._callback) { + this.emit('fields', this._resultSet.fieldPackets, this._index); + } + + if (this._resultSet.eofPackets.length !== 2) { + return; + } + + if (this._callback) { + this._results.push(this._resultSet.rows); + this._fields.push(this._resultSet.fieldPackets); + } + + this._index++; + this._resultSet = null; + this._handleFinalResultPacket(packet); +}; + +Query.prototype._handleFinalResultPacket = function(packet) { + if (packet.serverStatus & ServerStatus.SERVER_MORE_RESULTS_EXISTS) { + return; + } + + var results = (this._results.length > 1) + ? this._results + : this._results[0]; + + var fields = (this._fields.length > 1) + ? this._fields + : this._fields[0]; + + this.end(this._loadError, results, fields); +}; + +Query.prototype['RowDataPacket'] = function(packet, parser, connection) { + packet.parse(parser, this._resultSet.fieldPackets, this.typeCast, this.nestTables, connection); + + if (this._callback) { + this._resultSet.rows.push(packet); + } else { + this.emit('result', packet, this._index); + } +}; + +Query.prototype._sendLocalDataFile = function(path) { + var self = this; + var localStream = fs.createReadStream(path, { + 'flag': 'r', + 'encoding': null, + 'autoClose': true + }); + + + this.on('pause', function () { + localStream.pause(); + }); + + this.on('resume', function () { + localStream.resume(); + }); + + localStream.on('data', function (data) { + self.emit('packet', new Packets.LocalDataFilePacket(data)); + }); + + localStream.on('error', function (err) { + self._loadError = err; + localStream.emit('end'); + }); + + localStream.on('end', function () { + self.emit('packet', new Packets.EmptyPacket()); + }); +}; + +Query.prototype.stream = function(options) { + var self = this, + stream; + + options = options || {}; + options.objectMode = true; + stream = new Readable(options); + + stream._read = function() { + self._connection && self._connection.resume(); + }; + + this.on('result',function(row,i) { + if (!stream.push(row)) self._connection.pause(); + stream.emit('result',row,i); // replicate old emitter + }); + + this.on('error',function(err) { + stream.emit('error',err); // Pass on any errors + }); + + this.on('end', function() { + stream.emit('close'); // notify readers that query has completed + stream.push(null); // pushing null, indicating EOF + }); + + this.on('fields',function(fields,i) { + stream.emit('fields',fields,i); // replicate old emitter + }); + + return stream; +}; diff --git a/node_modules/mysql/lib/protocol/sequences/Quit.js b/node_modules/mysql/lib/protocol/sequences/Quit.js new file mode 100644 index 0000000..68ed876 --- /dev/null +++ b/node_modules/mysql/lib/protocol/sequences/Quit.js @@ -0,0 +1,18 @@ +var Sequence = require('./Sequence'); +var Util = require('util'); +var Packets = require('../packets'); + +module.exports = Quit; +Util.inherits(Quit, Sequence); +function Quit(options, callback) { + if (!callback && typeof options === 'function') { + callback = options; + options = {}; + } + + Sequence.call(this, options, callback); +} + +Quit.prototype.start = function() { + this.emit('packet', new Packets.ComQuitPacket); +}; diff --git a/node_modules/mysql/lib/protocol/sequences/Sequence.js b/node_modules/mysql/lib/protocol/sequences/Sequence.js new file mode 100644 index 0000000..9c2f6bf --- /dev/null +++ b/node_modules/mysql/lib/protocol/sequences/Sequence.js @@ -0,0 +1,117 @@ +var Util = require('util'); +var EventEmitter = require('events').EventEmitter; +var Packets = require('../packets'); +var ErrorConstants = require('../constants/errors'); + +var listenerCount = EventEmitter.listenerCount + || function(emitter, type){ return emitter.listeners(type).length; }; + +module.exports = Sequence; +Util.inherits(Sequence, EventEmitter); +function Sequence(options, callback) { + if (typeof options === 'function') { + callback = options; + options = {}; + } + + EventEmitter.call(this); + + options = options || {}; + + this._callback = callback; + this._callSite = null; + this._ended = false; + this._timeout = options.timeout; + + // For Timers + this._idleNext = null; + this._idlePrev = null; + this._idleStart = null; + this._idleTimeout = undefined; + this._repeat = null; +} + +Sequence.determinePacket = function(byte) { + switch (byte) { + case 0x00: return Packets.OkPacket; + case 0xfe: return Packets.EofPacket; + case 0xff: return Packets.ErrorPacket; + } +}; + +Sequence.prototype.hasErrorHandler = function() { + return Boolean(this._callback) || listenerCount(this, 'error') > 1; +}; + +Sequence.prototype._packetToError = function(packet) { + var code = ErrorConstants[packet.errno] || 'UNKNOWN_CODE_PLEASE_REPORT'; + var err = new Error(code + ': ' + packet.message); + err.code = code; + err.errno = packet.errno; + err.sqlState = packet.sqlState; + + return err; +}; + +Sequence.prototype._addLongStackTrace = function(err) { + if (!this._callSite) { + return; + } + + var delimiter = '\n --------------------\n' ; + + if (err.stack.indexOf(delimiter) > -1) { + return; + } + + err.stack += delimiter + this._callSite.stack.replace(/.+\n/, ''); +}; + +Sequence.prototype.end = function(err) { + if (this._ended) { + return; + } + + this._ended = true; + + if (err) { + this._addLongStackTrace(err); + } + + // Without this we are leaking memory. This problem was introduced in + // 8189925374e7ce3819bbe88b64c7b15abac96b16. I suspect that the error object + // causes a cyclic reference that the GC does not detect properly, but I was + // unable to produce a standalone version of this leak. This would be a great + // challenge for somebody interested in difficult problems : )! + this._callSite = null; + + // try...finally for exception safety + try { + if (err) { + this.emit('error', err); + } + } finally { + try { + if (this._callback) { + this._callback.apply(this, arguments); + } + } finally { + this.emit('end'); + } + } +}; + +Sequence.prototype['OkPacket'] = function(packet) { + this.end(null, packet); +}; + +Sequence.prototype['ErrorPacket'] = function(packet) { + this.end(this._packetToError(packet)); +}; + +// Implemented by child classes +Sequence.prototype.start = function() {}; + +Sequence.prototype._onTimeout = function _onTimeout() { + this.emit('timeout'); +}; diff --git a/node_modules/mysql/lib/protocol/sequences/Statistics.js b/node_modules/mysql/lib/protocol/sequences/Statistics.js new file mode 100644 index 0000000..50157ce --- /dev/null +++ b/node_modules/mysql/lib/protocol/sequences/Statistics.js @@ -0,0 +1,28 @@ +var Sequence = require('./Sequence'); +var Util = require('util'); +var Packets = require('../packets'); + +module.exports = Statistics; +Util.inherits(Statistics, Sequence); +function Statistics(options, callback) { + if (!callback && typeof options === 'function') { + callback = options; + options = {}; + } + + Sequence.call(this, options, callback); +} + +Statistics.prototype.start = function() { + this.emit('packet', new Packets.ComStatisticsPacket); +}; + +Statistics.prototype['StatisticsPacket'] = function (packet) { + this.end(null, packet); +}; + +Statistics.prototype.determinePacket = function(firstByte, parser) { + if (firstByte === 0x55) { + return Packets.StatisticsPacket; + } +}; diff --git a/node_modules/mysql/lib/protocol/sequences/index.js b/node_modules/mysql/lib/protocol/sequences/index.js new file mode 100644 index 0000000..a13d469 --- /dev/null +++ b/node_modules/mysql/lib/protocol/sequences/index.js @@ -0,0 +1,4 @@ +var Elements = module.exports = require('require-all')({ + dirname : __dirname, + filter : /([A-Z].+)\.js$/, +}); diff --git a/node_modules/mysql/node_modules/bignumber.js/.npmignore b/node_modules/mysql/node_modules/bignumber.js/.npmignore new file mode 100644 index 0000000..2a7fbd1 --- /dev/null +++ b/node_modules/mysql/node_modules/bignumber.js/.npmignore @@ -0,0 +1,2 @@ +test +perf diff --git a/node_modules/mysql/node_modules/bignumber.js/.travis.yml b/node_modules/mysql/node_modules/bignumber.js/.travis.yml new file mode 100644 index 0000000..c696551 --- /dev/null +++ b/node_modules/mysql/node_modules/bignumber.js/.travis.yml @@ -0,0 +1,6 @@ +language: node_js +node_js: + - "0.11" + - "0.10" + - "0.8" + - "0.6" \ No newline at end of file diff --git a/node_modules/mysql/node_modules/bignumber.js/LICENCE b/node_modules/mysql/node_modules/bignumber.js/LICENCE new file mode 100644 index 0000000..c045569 --- /dev/null +++ b/node_modules/mysql/node_modules/bignumber.js/LICENCE @@ -0,0 +1,23 @@ +The MIT Expat Licence. + +Copyright (c) 2012 Michael Mclaughlin + +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/node_modules/mysql/node_modules/bignumber.js/README.md b/node_modules/mysql/node_modules/bignumber.js/README.md new file mode 100644 index 0000000..3b72ea4 --- /dev/null +++ b/node_modules/mysql/node_modules/bignumber.js/README.md @@ -0,0 +1,242 @@ +[![Build Status](https://travis-ci.org/MikeMcl/bignumber.js.png)](https://travis-ci.org/MikeMcl/bignumber.js) + +# bignumber.js # + +A JavaScript library for arbitrary-precision decimal and non-decimal arithmetic. + +## Features + + - Faster, smaller, and perhaps easier to use than JavaScript versions of Java's BigDecimal + - 5 KB minified and gzipped + - Simple API but full-featured + - Works with numbers with or without fraction digits in bases from 2 to 64 inclusive + - Replicates the `toExponential`, `toFixed`, `toPrecision` and `toString` methods of JavaScript's Number type + - Includes a `toFraction` and a correctly-rounded `squareRoot` method + - Stores values in an accessible decimal floating point format + - No dependencies + - Comprehensive [documentation](http://mikemcl.github.io/bignumber.js/) and test set + +If an even smaller and simpler library is required see [big.js](https://github.com/MikeMcl/big.js/). +It's half the size but only works with decimal numbers and only has half the methods. +It also does not allow `NaN` or `Infinity`, or have the configuration options of this library. +See also [decimal.js](https://github.com/MikeMcl/decimal.js/). + +## Load + +The library is the single JavaScript file *bignumber.js* (or minified, *bignumber.min.js*). + +It can be loaded via a script tag in an HTML document for the browser + + + +or as a CommonJS, [Node.js](http://nodejs.org) or AMD module using `require`. + +For Node, put the *bignumber.js* file into the same directory as the file that is requiring it and use + + var BigNumber = require('./bignumber.js'); + +or put it in a *node_modules* directory within the directory and use `require('bignumber.js')`. + +The library is also available from the [npm](https://npmjs.org/) registry, so + + $ npm install bignumber.js + +will install this directory in a *node_modules* directory within the current directory. + +To load with AMD loader libraries such as [requireJS](http://requirejs.org/): + + require(['path/to/bignumber'], function(BigNumber) { + // Use BigNumber here in local scope. No global BigNumber. + }); + +## Use + +*In all examples below, `var`, semicolons and `toString` calls are not shown. +If a commented-out value is in quotes it means `toString` has been called on the preceding expression.* + +The library exports a single function: BigNumber, the constructor of BigNumber instances. +It accepts a value of type Number *(up to 15 significant digits only)*, String or BigNumber Object, + + x = new BigNumber(123.4567) + y = BigNumber('123456.7e-3') // 'new' is optional + z = new BigNumber(x) + x.equals(y) && y.equals(z) && x.equals(z) // true + +and a base from 2 to 64 inclusive can be specified. + + x = new BigNumber(1011, 2) // "11" + y = new BigNumber('zz.9', 36) // "1295.25" + z = x.plus(y) // "1306.25" + +A BigNumber is immutable in the sense that it is not changed by its methods. + + 0.3 - 0.1 // 0.19999999999999998 + x = new BigNumber(0.3) + x.minus(0.1) // "0.2" + x // "0.3" + +The methods that return a BigNumber can be chained. + + x.dividedBy(y).plus(z).times(9).floor() + x.times('1.23456780123456789e+9').plus(9876.5432321).dividedBy('4444562598.111772').ceil() + +Method names over 5 letters in length have a shorter alias. + + x.squareRoot().dividedBy(y).toPower(3).equals(x.sqrt().div(y).pow(3)) // true + x.cmp(y.mod(z).neg()) == 1 && x.comparedTo(y.modulo(z).negated()) == 1 // true + +Like JavaScript's Number type, there are `toExponential`, `toFixed` and `toPrecision` methods + + x = new BigNumber(255.5) + x.toExponential(5) // "2.55500e+2" + x.toFixed(5) // "255.50000" + x.toPrecision(5) // "255.50" + x.toNumber() // 255.5 + + and a base can be specified for `toString`. + + x.toString(16) // "ff.8" + +The maximum number of decimal places of, and the rounding mode applied to, the results of operations involving division (i.e. division, square root, base conversion, and negative power operations) is set by a configuration object passed to the `config` method of the `BigNumber` constructor. +The other arithmetic operations always give the exact result. + + BigNumber.config({ DECIMAL_PLACES: 10, ROUNDING_MODE: 4 }) + // Alternatively, BigNumber.config( 10, 4 ); + + x = new BigNumber(2); + y = new BigNumber(3); + z = x.div(y) // "0.6666666667" + z.sqrt() // "0.8164965809" + z.pow(-3) // "3.3749999995" + z.toString(2) // "0.1010101011" + z.times(z) // "0.44444444448888888889" + z.times(z).round(10) // "0.4444444445" + +There is a `toFraction` method with an optional *maximum denominator* argument + + y = new BigNumber(355) + pi = y.dividedBy(113) // "3.1415929204" + pi.toFraction() // [ "7853982301", "2500000000" ] + pi.toFraction(1000) // [ "355", "113" ] + +and `isNaN` and `isFinite` methods, as `NaN` and `Infinity` are valid `BigNumber` values. + + x = new BigNumber(NaN) // "NaN" + y = new BigNumber(Infinity) // "Infinity" + x.isNaN() && !y.isNaN() && !x.isFinite() && !y.isFinite() // true + +The value of a BigNumber is stored in a decimal floating point format in terms of a coefficient, exponent and sign. + + x = new BigNumber(-123.456); + x.c // "1,2,3,4,5,6" coefficient (i.e. significand) + x.e // 2 exponent + x.s // -1 sign + +For futher information see the [API](http://mikemcl.github.io/bignumber.js/) reference from the *doc* folder. + +## Test + +The *test* directory contains the test scripts for each method. + +The tests can be run with Node or a browser. + +For a quick test of all the methods, from a command-line shell at the *test/* directory + + $ node quick-test + +To test a single method in more depth, e.g. + + $ node toFraction + +To test all the methods in more depth + + $ node every-test + +For the browser, see *quick-test.html*, *single-test.html* and *every-test.html* in the *test/browser* directory. + +*bignumber-vs-number.html* enables some of the methods of bignumber.js to be compared with those of JavaScript's Number type. + +## Performance + +The *perf* directory contains two applications and a *lib* directory containing the BigDecimal libraries used by both. + +*bignumber-vs-bigdecimal.html* tests the performance of bignumber.js against the JavaScript translations of two versions of BigDecimal, its use should be more or less self-explanatory. +(The GWT version doesn't work in IE 6.) + +* GWT: java.math.BigDecimal + +* ICU4J: com.ibm.icu.math.BigDecimal + + +The BigDecimal in Node's npm registry is the GWT version. Despite its seeming popularity I have found it to have some serious bugs, see the Node script *perf/lib/bigdecimal_GWT/bugs.js* for examples of flaws in its *remainder*, *divide* and *compareTo* methods. + +*bigtime.js* is a Node command-line application which tests the performance of bignumber.js against the GWT version of BigDecimal from the npm registry. + +For example, to compare the time taken by the bignumber.js `plus` method and the BigDecimal `add` method: + + $ node bigtime plus 10000 40 + +This will time 10000 calls to each, using operands of up to 40 random digits and will check that the results match. + +For help: + + $ node bigtime -h + +See the README in the directory for more information. + +## Build + +I.e. minify. + +For Node, if uglify-js is installed globally ( `npm install uglify-js -g` ) then + + npm run build + +will create *bignumber.min.js*. + +## Feedback + +Open an issue, or email + +Michael +M8ch88l@gmail.com + +Bitcoin donation to: +**1CauoGYrEoJFhcyxGVaiLTE6f3WCaSUjnm** +Thank you + +## Licence + +MIT. + +See LICENCE. + +## Change Log + +####1.4.1 +* 08/06/2014 Amend README. + +####1.4.0 +* 08/05/2014 Added `toNumber`. + +####1.3.0 +* 08/11/2013 Ensure correct rounding of `sqrt` in all, rather than almost all, cases. +* Maximum radix to 64. + +####1.2.1 +* 17/10/2013 Sign of zero when x < 0 and x + (-x) = 0. + +####1.2.0 +* 19/9/2013 Throw Error objects for stack. + +####1.1.1 +* 22/8/2013 Show original value in constructor error message. + +####1.1.0 +* 1/8/2013 Allow numbers with trailing radix point. + +####1.0.1 +* Bugfix: error messages with incorrect method name + +####1.0.0 +* 8/11/2012 Initial release diff --git a/node_modules/mysql/node_modules/bignumber.js/bignumber.js b/node_modules/mysql/node_modules/bignumber.js/bignumber.js new file mode 100644 index 0000000..9bddb38 --- /dev/null +++ b/node_modules/mysql/node_modules/bignumber.js/bignumber.js @@ -0,0 +1,2017 @@ +/*! bignumber.js v1.4.1 https://github.com/MikeMcl/bignumber.js/LICENCE */ + +;(function ( global ) { + 'use strict'; + + /* + bignumber.js v1.4.1 + A JavaScript library for arbitrary-precision arithmetic. + https://github.com/MikeMcl/bignumber.js + Copyright (c) 2012 Michael Mclaughlin + MIT Expat Licence + */ + + /*********************************** DEFAULTS ************************************/ + + /* + * The default values below must be integers within the stated ranges (inclusive). + * Most of these values can be changed during run-time using BigNumber.config(). + */ + + /* + * The limit on the value of DECIMAL_PLACES, TO_EXP_NEG, TO_EXP_POS, MIN_EXP, + * MAX_EXP, and the argument to toFixed, toPrecision and toExponential, beyond + * which an exception is thrown (if ERRORS is true). + */ + var MAX = 1E9, // 0 to 1e+9 + + // Limit of magnitude of exponent argument to toPower. + MAX_POWER = 1E6, // 1 to 1e+6 + + // The maximum number of decimal places for operations involving division. + DECIMAL_PLACES = 20, // 0 to MAX + + /* + * The rounding mode used when rounding to the above decimal places, and when + * using toFixed, toPrecision and toExponential, and round (default value). + * UP 0 Away from zero. + * DOWN 1 Towards zero. + * CEIL 2 Towards +Infinity. + * FLOOR 3 Towards -Infinity. + * HALF_UP 4 Towards nearest neighbour. If equidistant, up. + * HALF_DOWN 5 Towards nearest neighbour. If equidistant, down. + * HALF_EVEN 6 Towards nearest neighbour. If equidistant, towards even neighbour. + * HALF_CEIL 7 Towards nearest neighbour. If equidistant, towards +Infinity. + * HALF_FLOOR 8 Towards nearest neighbour. If equidistant, towards -Infinity. + */ + ROUNDING_MODE = 4, // 0 to 8 + + // EXPONENTIAL_AT : [TO_EXP_NEG , TO_EXP_POS] + + // The exponent value at and beneath which toString returns exponential notation. + // Number type: -7 + TO_EXP_NEG = -7, // 0 to -MAX + + // The exponent value at and above which toString returns exponential notation. + // Number type: 21 + TO_EXP_POS = 21, // 0 to MAX + + // RANGE : [MIN_EXP, MAX_EXP] + + // The minimum exponent value, beneath which underflow to zero occurs. + // Number type: -324 (5e-324) + MIN_EXP = -MAX, // -1 to -MAX + + // The maximum exponent value, above which overflow to Infinity occurs. + // Number type: 308 (1.7976931348623157e+308) + MAX_EXP = MAX, // 1 to MAX + + // Whether BigNumber Errors are ever thrown. + // CHANGE parseInt to parseFloat if changing ERRORS to false. + ERRORS = true, // true or false + parse = parseInt, // parseInt or parseFloat + + /***********************************************************************************/ + + P = BigNumber.prototype, + DIGITS = '0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ$_', + outOfRange, + id = 0, + isValid = /^-?(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i, + trim = String.prototype.trim || function () {return this.replace(/^\s+|\s+$/g, '')}, + ONE = BigNumber(1); + + + // CONSTRUCTOR + + + /* + * The exported function. + * Create and return a new instance of a BigNumber object. + * + * n {number|string|BigNumber} A numeric value. + * [b] {number} The base of n. Integer, 2 to 64 inclusive. + */ + function BigNumber( n, b ) { + var e, i, isNum, digits, valid, orig, + x = this; + + // Enable constructor usage without new. + if ( !(x instanceof BigNumber) ) { + return new BigNumber( n, b ) + } + + // Duplicate. + if ( n instanceof BigNumber ) { + id = 0; + + // e is undefined. + if ( b !== e ) { + n += '' + } else { + x['s'] = n['s']; + x['e'] = n['e']; + x['c'] = ( n = n['c'] ) ? n.slice() : n; + return; + } + } + + // If number, check if minus zero. + if ( typeof n != 'string' ) { + n = ( isNum = typeof n == 'number' || + Object.prototype.toString.call(n) == '[object Number]' ) && + n === 0 && 1 / n < 0 ? '-0' : n + ''; + } + + orig = n; + + if ( b === e && isValid.test(n) ) { + + // Determine sign. + x['s'] = n.charAt(0) == '-' ? ( n = n.slice(1), -1 ) : 1; + + // Either n is not a valid BigNumber or a base has been specified. + } else { + + // Enable exponential notation to be used with base 10 argument. + // Ensure return value is rounded to DECIMAL_PLACES as with other bases. + if ( b == 10 ) { + + return setMode( n, DECIMAL_PLACES, ROUNDING_MODE ); + } + + n = trim.call(n).replace( /^\+(?!-)/, '' ); + + x['s'] = n.charAt(0) == '-' ? ( n = n.replace( /^-(?!-)/, '' ), -1 ) : 1; + + if ( b != null ) { + + if ( ( b == (b | 0) || !ERRORS ) && + !( outOfRange = !( b >= 2 && b < 65 ) ) ) { + + digits = '[' + DIGITS.slice( 0, b = b | 0 ) + ']+'; + + // Before non-decimal number validity test and base conversion + // remove the `.` from e.g. '1.', and replace e.g. '.1' with '0.1'. + n = n.replace( /\.$/, '' ).replace( /^\./, '0.' ); + + // Any number in exponential form will fail due to the e+/-. + if ( valid = new RegExp( + '^' + digits + '(?:\\.' + digits + ')?$', b < 37 ? 'i' : '' ).test(n) ) { + + if ( isNum ) { + + if ( n.replace( /^0\.0*|\./, '' ).length > 15 ) { + + // 'new BigNumber() number type has more than 15 significant digits: {n}' + ifExceptionsThrow( orig, 0 ); + } + + // Prevent later check for length on converted number. + isNum = !isNum; + } + n = convert( n, 10, b, x['s'] ); + + } else if ( n != 'Infinity' && n != 'NaN' ) { + + // 'new BigNumber() not a base {b} number: {n}' + ifExceptionsThrow( orig, 1, b ); + n = 'NaN'; + } + } else { + + // 'new BigNumber() base not an integer: {b}' + // 'new BigNumber() base out of range: {b}' + ifExceptionsThrow( b, 2 ); + + // Ignore base. + valid = isValid.test(n); + } + } else { + valid = isValid.test(n); + } + + if ( !valid ) { + + // Infinity/NaN + x['c'] = x['e'] = null; + + // NaN + if ( n != 'Infinity' ) { + + // No exception on NaN. + if ( n != 'NaN' ) { + + // 'new BigNumber() not a number: {n}' + ifExceptionsThrow( orig, 3 ); + } + x['s'] = null; + } + id = 0; + + return; + } + } + + // Decimal point? + if ( ( e = n.indexOf('.') ) > -1 ) { + n = n.replace( '.', '' ); + } + + // Exponential form? + if ( ( i = n.search( /e/i ) ) > 0 ) { + + // Determine exponent. + if ( e < 0 ) { + e = i; + } + e += +n.slice( i + 1 ); + n = n.substring( 0, i ); + + } else if ( e < 0 ) { + + // Integer. + e = n.length; + } + + // Determine leading zeros. + for ( i = 0; n.charAt(i) == '0'; i++ ) { + } + + b = n.length; + + // Disallow numbers with over 15 significant digits if number type. + if ( isNum && b > 15 && n.slice(i).length > 15 ) { + + // 'new BigNumber() number type has more than 15 significant digits: {n}' + ifExceptionsThrow( orig, 0 ); + } + id = 0; + + // Overflow? + if ( ( e -= i + 1 ) > MAX_EXP ) { + + // Infinity. + x['c'] = x['e'] = null; + + // Zero or underflow? + } else if ( i == b || e < MIN_EXP ) { + + // Zero. + x['c'] = [ x['e'] = 0 ]; + } else { + + // Determine trailing zeros. + for ( ; n.charAt(--b) == '0'; ) { + } + + x['e'] = e; + x['c'] = []; + + // Convert string to array of digits (without leading and trailing zeros). + for ( e = 0; i <= b; x['c'][e++] = +n.charAt(i++) ) { + } + } + } + + + // CONSTRUCTOR PROPERTIES/METHODS + + + BigNumber['ROUND_UP'] = 0; + BigNumber['ROUND_DOWN'] = 1; + BigNumber['ROUND_CEIL'] = 2; + BigNumber['ROUND_FLOOR'] = 3; + BigNumber['ROUND_HALF_UP'] = 4; + BigNumber['ROUND_HALF_DOWN'] = 5; + BigNumber['ROUND_HALF_EVEN'] = 6; + BigNumber['ROUND_HALF_CEIL'] = 7; + BigNumber['ROUND_HALF_FLOOR'] = 8; + + + /* + * Configure infrequently-changing library-wide settings. + * + * Accept an object or an argument list, with one or many of the following + * properties or parameters respectively: + * [ DECIMAL_PLACES [, ROUNDING_MODE [, EXPONENTIAL_AT [, RANGE [, ERRORS ]]]]] + * + * E.g. + * BigNumber.config(20, 4) is equivalent to + * BigNumber.config({ DECIMAL_PLACES : 20, ROUNDING_MODE : 4 }) + * Ignore properties/parameters set to null or undefined. + * + * Return an object with the properties current values. + */ + BigNumber['config'] = function () { + var v, p, + i = 0, + r = {}, + a = arguments, + o = a[0], + c = 'config', + inRange = function ( n, lo, hi ) { + return !( ( outOfRange = n < lo || n > hi ) || + parse(n) != n && n !== 0 ); + }, + has = o && typeof o == 'object' + ? function () {if ( o.hasOwnProperty(p) ) return ( v = o[p] ) != null} + : function () {if ( a.length > i ) return ( v = a[i++] ) != null}; + + // [DECIMAL_PLACES] {number} Integer, 0 to MAX inclusive. + if ( has( p = 'DECIMAL_PLACES' ) ) { + + if ( inRange( v, 0, MAX ) ) { + DECIMAL_PLACES = v | 0; + } else { + + // 'config() DECIMAL_PLACES not an integer: {v}' + // 'config() DECIMAL_PLACES out of range: {v}' + ifExceptionsThrow( v, p, c ); + } + } + r[p] = DECIMAL_PLACES; + + // [ROUNDING_MODE] {number} Integer, 0 to 8 inclusive. + if ( has( p = 'ROUNDING_MODE' ) ) { + + if ( inRange( v, 0, 8 ) ) { + ROUNDING_MODE = v | 0; + } else { + + // 'config() ROUNDING_MODE not an integer: {v}' + // 'config() ROUNDING_MODE out of range: {v}' + ifExceptionsThrow( v, p, c ); + } + } + r[p] = ROUNDING_MODE; + + /* + * [EXPONENTIAL_AT] {number|number[]} Integer, -MAX to MAX inclusive or + * [ integer -MAX to 0 inclusive, 0 to MAX inclusive ]. + */ + if ( has( p = 'EXPONENTIAL_AT' ) ) { + + if ( inRange( v, -MAX, MAX ) ) { + TO_EXP_NEG = -( TO_EXP_POS = ~~( v < 0 ? -v : +v ) ); + } else if ( !outOfRange && v && inRange( v[0], -MAX, 0 ) && + inRange( v[1], 0, MAX ) ) { + TO_EXP_NEG = ~~v[0]; + TO_EXP_POS = ~~v[1]; + } else { + + // 'config() EXPONENTIAL_AT not an integer or not [integer, integer]: {v}' + // 'config() EXPONENTIAL_AT out of range or not [negative, positive: {v}' + ifExceptionsThrow( v, p, c, 1 ); + } + } + r[p] = [ TO_EXP_NEG, TO_EXP_POS ]; + + /* + * [RANGE][ {number|number[]} Non-zero integer, -MAX to MAX inclusive or + * [ integer -MAX to -1 inclusive, integer 1 to MAX inclusive ]. + */ + if ( has( p = 'RANGE' ) ) { + + if ( inRange( v, -MAX, MAX ) && ~~v ) { + MIN_EXP = -( MAX_EXP = ~~( v < 0 ? -v : +v ) ); + } else if ( !outOfRange && v && inRange( v[0], -MAX, -1 ) && + inRange( v[1], 1, MAX ) ) { + MIN_EXP = ~~v[0], MAX_EXP = ~~v[1]; + } else { + + // 'config() RANGE not a non-zero integer or not [integer, integer]: {v}' + // 'config() RANGE out of range or not [negative, positive: {v}' + ifExceptionsThrow( v, p, c, 1, 1 ); + } + } + r[p] = [ MIN_EXP, MAX_EXP ]; + + // [ERRORS] {boolean|number} true, false, 1 or 0. + if ( has( p = 'ERRORS' ) ) { + + if ( v === !!v || v === 1 || v === 0 ) { + parse = ( outOfRange = id = 0, ERRORS = !!v ) + ? parseInt + : parseFloat; + } else { + + // 'config() ERRORS not a boolean or binary digit: {v}' + ifExceptionsThrow( v, p, c, 0, 0, 1 ); + } + } + r[p] = ERRORS; + + return r; + }; + + + // PRIVATE FUNCTIONS + + + // Assemble error messages. Throw BigNumber Errors. + function ifExceptionsThrow( arg, i, j, isArray, isRange, isErrors) { + + if ( ERRORS ) { + var error, + method = ['new BigNumber', 'cmp', 'div', 'eq', 'gt', 'gte', 'lt', + 'lte', 'minus', 'mod', 'plus', 'times', 'toFr' + ][ id ? id < 0 ? -id : id : 1 / id < 0 ? 1 : 0 ] + '()', + message = outOfRange ? ' out of range' : ' not a' + + ( isRange ? ' non-zero' : 'n' ) + ' integer'; + + message = ( [ + method + ' number type has more than 15 significant digits', + method + ' not a base ' + j + ' number', + method + ' base' + message, + method + ' not a number' ][i] || + j + '() ' + i + ( isErrors + ? ' not a boolean or binary digit' + : message + ( isArray + ? ' or not [' + ( outOfRange + ? ' negative, positive' + : ' integer, integer' ) + ' ]' + : '' ) ) ) + ': ' + arg; + + outOfRange = id = 0; + error = new Error(message); + error['name'] = 'BigNumber Error'; + + throw error; + } + } + + + /* + * Convert a numeric string of baseIn to a numeric string of baseOut. + */ + function convert( nStr, baseOut, baseIn, sign ) { + var e, dvs, dvd, nArr, fracArr, fracBN; + + // Convert string of base bIn to an array of numbers of baseOut. + // Eg. strToArr('255', 10) where baseOut is 16, returns [15, 15]. + // Eg. strToArr('ff', 16) where baseOut is 10, returns [2, 5, 5]. + function strToArr( str, bIn ) { + var j, + i = 0, + strL = str.length, + arrL, + arr = [0]; + + for ( bIn = bIn || baseIn; i < strL; i++ ) { + + for ( arrL = arr.length, j = 0; j < arrL; arr[j] *= bIn, j++ ) { + } + + for ( arr[0] += DIGITS.indexOf( str.charAt(i) ), j = 0; + j < arr.length; + j++ ) { + + if ( arr[j] > baseOut - 1 ) { + + if ( arr[j + 1] == null ) { + arr[j + 1] = 0; + } + arr[j + 1] += arr[j] / baseOut ^ 0; + arr[j] %= baseOut; + } + } + } + + return arr.reverse(); + } + + // Convert array to string. + // E.g. arrToStr( [9, 10, 11] ) becomes '9ab' (in bases above 11). + function arrToStr( arr ) { + var i = 0, + arrL = arr.length, + str = ''; + + for ( ; i < arrL; str += DIGITS.charAt( arr[i++] ) ) { + } + + return str; + } + + if ( baseIn < 37 ) { + nStr = nStr.toLowerCase(); + } + + /* + * If non-integer convert integer part and fraction part separately. + * Convert the fraction part as if it is an integer than use division to + * reduce it down again to a value less than one. + */ + if ( ( e = nStr.indexOf( '.' ) ) > -1 ) { + + /* + * Calculate the power to which to raise the base to get the number + * to divide the fraction part by after it has been converted as an + * integer to the required base. + */ + e = nStr.length - e - 1; + + // Use toFixed to avoid possible exponential notation. + dvs = strToArr( new BigNumber(baseIn)['pow'](e)['toF'](), 10 ); + + nArr = nStr.split('.'); + + // Convert the base of the fraction part (as integer). + dvd = strToArr( nArr[1] ); + + // Convert the base of the integer part. + nArr = strToArr( nArr[0] ); + + // Result will be a BigNumber with a value less than 1. + fracBN = divide( dvd, dvs, dvd.length - dvs.length, sign, baseOut, + // Is least significant digit of integer part an odd number? + nArr[nArr.length - 1] & 1 ); + + fracArr = fracBN['c']; + + // e can be <= 0 ( if e == 0, fracArr is [0] or [1] ). + if ( e = fracBN['e'] ) { + + // Append zeros according to the exponent of the result. + for ( ; ++e; fracArr.unshift(0) ) { + } + + // Append the fraction part to the converted integer part. + nStr = arrToStr(nArr) + '.' + arrToStr(fracArr); + + // fracArr is [1]. + // Fraction digits rounded up, so increment last digit of integer part. + } else if ( fracArr[0] ) { + + if ( nArr[ e = nArr.length - 1 ] < baseOut - 1 ) { + ++nArr[e]; + nStr = arrToStr(nArr); + } else { + nStr = new BigNumber( arrToStr(nArr), + baseOut )['plus'](ONE)['toS'](baseOut); + } + + // fracArr is [0]. No fraction digits. + } else { + nStr = arrToStr(nArr); + } + } else { + + // Simple integer. Convert base. + nStr = arrToStr( strToArr(nStr) ); + } + + return nStr; + } + + + // Perform division in the specified base. Called by div and convert. + function divide( dvd, dvs, exp, s, base, isOdd ) { + var dvsL, dvsT, next, cmp, remI, + dvsZ = dvs.slice(), + dvdI = dvsL = dvs.length, + dvdL = dvd.length, + rem = dvd.slice( 0, dvsL ), + remL = rem.length, + quo = new BigNumber(ONE), + qc = quo['c'] = [], + qi = 0, + dig = DECIMAL_PLACES + ( quo['e'] = exp ) + 1; + + quo['s'] = s; + s = dig < 0 ? 0 : dig; + + // Add zeros to make remainder as long as divisor. + for ( ; remL++ < dvsL; rem.push(0) ) { + } + + // Create version of divisor with leading zero. + dvsZ.unshift(0); + + do { + + // 'next' is how many times the divisor goes into the current remainder. + for ( next = 0; next < base; next++ ) { + + // Compare divisor and remainder. + if ( dvsL != ( remL = rem.length ) ) { + cmp = dvsL > remL ? 1 : -1; + } else { + for ( remI = -1, cmp = 0; ++remI < dvsL; ) { + + if ( dvs[remI] != rem[remI] ) { + cmp = dvs[remI] > rem[remI] ? 1 : -1; + break; + } + } + } + + // Subtract divisor from remainder (if divisor < remainder). + if ( cmp < 0 ) { + + // Remainder cannot be more than one digit longer than divisor. + // Equalise lengths using divisor with extra leading zero? + for ( dvsT = remL == dvsL ? dvs : dvsZ; remL; ) { + + if ( rem[--remL] < dvsT[remL] ) { + + for ( remI = remL; + remI && !rem[--remI]; + rem[remI] = base - 1 ) { + } + --rem[remI]; + rem[remL] += base; + } + rem[remL] -= dvsT[remL]; + } + for ( ; !rem[0]; rem.shift() ) { + } + } else { + break; + } + } + + // Add the 'next' digit to the result array. + qc[qi++] = cmp ? next : ++next; + + // Update the remainder. + rem[0] && cmp + ? ( rem[remL] = dvd[dvdI] || 0 ) + : ( rem = [ dvd[dvdI] ] ); + + } while ( ( dvdI++ < dvdL || rem[0] != null ) && s-- ); + + // Leading zero? Do not remove if result is simply zero (qi == 1). + if ( !qc[0] && qi != 1 ) { + + // There can't be more than one zero. + --quo['e']; + qc.shift(); + } + + // Round? + if ( qi > dig ) { + rnd( quo, DECIMAL_PLACES, base, isOdd, rem[0] != null ); + } + + // Overflow? + if ( quo['e'] > MAX_EXP ) { + + // Infinity. + quo['c'] = quo['e'] = null; + + // Underflow? + } else if ( quo['e'] < MIN_EXP ) { + + // Zero. + quo['c'] = [quo['e'] = 0]; + } + + return quo; + } + + + /* + * Return a string representing the value of BigNumber n in normal or + * exponential notation rounded to the specified decimal places or + * significant digits. + * Called by toString, toExponential (exp 1), toFixed, and toPrecision (exp 2). + * d is the index (with the value in normal notation) of the digit that may be + * rounded up. + */ + function format( n, d, exp ) { + + // Initially, i is the number of decimal places required. + var i = d - (n = new BigNumber(n))['e'], + c = n['c']; + + // +-Infinity or NaN? + if ( !c ) { + return n['toS'](); + } + + // Round? + if ( c.length > ++d ) { + rnd( n, i, 10 ); + } + + // Recalculate d if toFixed as n['e'] may have changed if value rounded up. + i = c[0] == 0 ? i + 1 : exp ? d : n['e'] + i + 1; + + // Append zeros? + for ( ; c.length < i; c.push(0) ) { + } + i = n['e']; + + /* + * toPrecision returns exponential notation if the number of significant + * digits specified is less than the number of digits necessary to + * represent the integer part of the value in normal notation. + */ + return exp == 1 || exp == 2 && ( --d < i || i <= TO_EXP_NEG ) + + // Exponential notation. + ? ( n['s'] < 0 && c[0] ? '-' : '' ) + ( c.length > 1 + ? ( c.splice( 1, 0, '.' ), c.join('') ) + : c[0] ) + ( i < 0 ? 'e' : 'e+' ) + i + + // Normal notation. + : n['toS'](); + } + + + // Round if necessary. + // Called by divide, format, setMode and sqrt. + function rnd( x, dp, base, isOdd, r ) { + var xc = x['c'], + isNeg = x['s'] < 0, + half = base / 2, + i = x['e'] + dp + 1, + + // 'next' is the digit after the digit that may be rounded up. + next = xc[i], + + /* + * 'more' is whether there are digits after 'next'. + * E.g. + * 0.005 (e = -3) to be rounded to 0 decimal places (dp = 0) gives i = -2 + * The 'next' digit is zero, and there ARE 'more' digits after it. + * 0.5 (e = -1) dp = 0 gives i = 0 + * The 'next' digit is 5 and there are no 'more' digits after it. + */ + more = r || i < 0 || xc[i + 1] != null; + + r = ROUNDING_MODE < 4 + ? ( next != null || more ) && + ( ROUNDING_MODE == 0 || + ROUNDING_MODE == 2 && !isNeg || + ROUNDING_MODE == 3 && isNeg ) + : next > half || next == half && + ( ROUNDING_MODE == 4 || more || + + /* + * isOdd is used in base conversion and refers to the least significant + * digit of the integer part of the value to be converted. The fraction + * part is rounded by this method separately from the integer part. + */ + ROUNDING_MODE == 6 && ( xc[i - 1] & 1 || !dp && isOdd ) || + ROUNDING_MODE == 7 && !isNeg || + ROUNDING_MODE == 8 && isNeg ); + + if ( i < 1 || !xc[0] ) { + xc.length = 0; + xc.push(0); + + if ( r ) { + + // 1, 0.1, 0.01, 0.001, 0.0001 etc. + xc[0] = 1; + x['e'] = -dp; + } else { + + // Zero. + x['e'] = 0; + } + + return x; + } + + // Remove any digits after the required decimal places. + xc.length = i--; + + // Round up? + if ( r ) { + + // Rounding up may mean the previous digit has to be rounded up and so on. + for ( --base; ++xc[i] > base; ) { + xc[i] = 0; + + if ( !i-- ) { + ++x['e']; + xc.unshift(1); + } + } + } + + // Remove trailing zeros. + for ( i = xc.length; !xc[--i]; xc.pop() ) { + } + + return x; + } + + + // Round after setting the appropriate rounding mode. + // Handles ceil, floor and round. + function setMode( x, dp, rm ) { + var r = ROUNDING_MODE; + + ROUNDING_MODE = rm; + x = new BigNumber(x); + x['c'] && rnd( x, dp, 10 ); + ROUNDING_MODE = r; + + return x; + } + + + // PROTOTYPE/INSTANCE METHODS + + + /* + * Return a new BigNumber whose value is the absolute value of this BigNumber. + */ + P['abs'] = P['absoluteValue'] = function () { + var x = new BigNumber(this); + + if ( x['s'] < 0 ) { + x['s'] = 1; + } + + return x; + }; + + + /* + * Return a new BigNumber whose value is the value of this BigNumber + * rounded to a whole number in the direction of Infinity. + */ + P['ceil'] = function () { + return setMode( this, 0, 2 ); + }; + + + /* + * Return + * 1 if the value of this BigNumber is greater than the value of BigNumber(y, b), + * -1 if the value of this BigNumber is less than the value of BigNumber(y, b), + * 0 if they have the same value, + * or null if the value of either is NaN. + */ + P['comparedTo'] = P['cmp'] = function ( y, b ) { + var a, + x = this, + xc = x['c'], + yc = ( id = -id, y = new BigNumber( y, b ) )['c'], + i = x['s'], + j = y['s'], + k = x['e'], + l = y['e']; + + // Either NaN? + if ( !i || !j ) { + return null; + } + + a = xc && !xc[0], b = yc && !yc[0]; + + // Either zero? + if ( a || b ) { + return a ? b ? 0 : -j : i; + } + + // Signs differ? + if ( i != j ) { + return i; + } + + // Either Infinity? + if ( a = i < 0, b = k == l, !xc || !yc ) { + return b ? 0 : !xc ^ a ? 1 : -1; + } + + // Compare exponents. + if ( !b ) { + return k > l ^ a ? 1 : -1; + } + + // Compare digit by digit. + for ( i = -1, + j = ( k = xc.length ) < ( l = yc.length ) ? k : l; + ++i < j; ) { + + if ( xc[i] != yc[i] ) { + return xc[i] > yc[i] ^ a ? 1 : -1; + } + } + // Compare lengths. + return k == l ? 0 : k > l ^ a ? 1 : -1; + }; + + + /* + * n / 0 = I + * n / N = N + * n / I = 0 + * 0 / n = 0 + * 0 / 0 = N + * 0 / N = N + * 0 / I = 0 + * N / n = N + * N / 0 = N + * N / N = N + * N / I = N + * I / n = I + * I / 0 = I + * I / N = N + * I / I = N + * + * Return a new BigNumber whose value is the value of this BigNumber + * divided by the value of BigNumber(y, b), rounded according to + * DECIMAL_PLACES and ROUNDING_MODE. + */ + P['dividedBy'] = P['div'] = function ( y, b ) { + var xc = this['c'], + xe = this['e'], + xs = this['s'], + yc = ( id = 2, y = new BigNumber( y, b ) )['c'], + ye = y['e'], + ys = y['s'], + s = xs == ys ? 1 : -1; + + // Either NaN/Infinity/0? + return !xe && ( !xc || !xc[0] ) || !ye && ( !yc || !yc[0] ) + + // Either NaN? + ? new BigNumber( !xs || !ys || + + // Both 0 or both Infinity? + ( xc ? yc && xc[0] == yc[0] : !yc ) + + // Return NaN. + ? NaN + + // x is 0 or y is Infinity? + : xc && xc[0] == 0 || !yc + + // Return +-0. + ? s * 0 + + // y is 0. Return +-Infinity. + : s / 0 ) + + : divide( xc, yc, xe - ye, s, 10 ); + }; + + + /* + * Return true if the value of this BigNumber is equal to the value of + * BigNumber(n, b), otherwise returns false. + */ + P['equals'] = P['eq'] = function ( n, b ) { + id = 3; + return this['cmp']( n, b ) === 0; + }; + + + /* + * Return a new BigNumber whose value is the value of this BigNumber + * rounded to a whole number in the direction of -Infinity. + */ + P['floor'] = function () { + return setMode( this, 0, 3 ); + }; + + + /* + * Return true if the value of this BigNumber is greater than the value of + * BigNumber(n, b), otherwise returns false. + */ + P['greaterThan'] = P['gt'] = function ( n, b ) { + id = 4; + return this['cmp']( n, b ) > 0; + }; + + + /* + * Return true if the value of this BigNumber is greater than or equal to + * the value of BigNumber(n, b), otherwise returns false. + */ + P['greaterThanOrEqualTo'] = P['gte'] = function ( n, b ) { + id = 5; + return ( b = this['cmp']( n, b ) ) == 1 || b === 0; + }; + + + /* + * Return true if the value of this BigNumber is a finite number, otherwise + * returns false. + */ + P['isFinite'] = P['isF'] = function () { + return !!this['c']; + }; + + + /* + * Return true if the value of this BigNumber is NaN, otherwise returns + * false. + */ + P['isNaN'] = function () { + return !this['s']; + }; + + + /* + * Return true if the value of this BigNumber is negative, otherwise + * returns false. + */ + P['isNegative'] = P['isNeg'] = function () { + return this['s'] < 0; + }; + + + /* + * Return true if the value of this BigNumber is 0 or -0, otherwise returns + * false. + */ + P['isZero'] = P['isZ'] = function () { + return !!this['c'] && this['c'][0] == 0; + }; + + + /* + * Return true if the value of this BigNumber is less than the value of + * BigNumber(n, b), otherwise returns false. + */ + P['lessThan'] = P['lt'] = function ( n, b ) { + id = 6; + return this['cmp']( n, b ) < 0; + }; + + + /* + * Return true if the value of this BigNumber is less than or equal to the + * value of BigNumber(n, b), otherwise returns false. + */ + P['lessThanOrEqualTo'] = P['lte'] = function ( n, b ) { + id = 7; + return ( b = this['cmp']( n, b ) ) == -1 || b === 0; + }; + + + /* + * n - 0 = n + * n - N = N + * n - I = -I + * 0 - n = -n + * 0 - 0 = 0 + * 0 - N = N + * 0 - I = -I + * N - n = N + * N - 0 = N + * N - N = N + * N - I = N + * I - n = I + * I - 0 = I + * I - N = N + * I - I = N + * + * Return a new BigNumber whose value is the value of this BigNumber minus + * the value of BigNumber(y, b). + */ + P['minus'] = function ( y, b ) { + var d, i, j, xLTy, + x = this, + a = x['s']; + + b = ( id = 8, y = new BigNumber( y, b ) )['s']; + + // Either NaN? + if ( !a || !b ) { + return new BigNumber(NaN); + } + + // Signs differ? + if ( a != b ) { + return y['s'] = -b, x['plus'](y); + } + + var xc = x['c'], + xe = x['e'], + yc = y['c'], + ye = y['e']; + + if ( !xe || !ye ) { + + // Either Infinity? + if ( !xc || !yc ) { + return xc ? ( y['s'] = -b, y ) : new BigNumber( yc ? x : NaN ); + } + + // Either zero? + if ( !xc[0] || !yc[0] ) { + + // y is non-zero? + return yc[0] + ? ( y['s'] = -b, y ) + + // x is non-zero? + : new BigNumber( xc[0] + ? x + + // Both are zero. + // IEEE 754 (2008) 6.3: n - n = -0 when rounding to -Infinity + : ROUNDING_MODE == 3 ? -0 : 0 ); + } + } + + // Determine which is the bigger number. + // Prepend zeros to equalise exponents. + if ( xc = xc.slice(), a = xe - ye ) { + d = ( xLTy = a < 0 ) ? ( a = -a, xc ) : ( ye = xe, yc ); + + for ( d.reverse(), b = a; b--; d.push(0) ) { + } + d.reverse(); + } else { + + // Exponents equal. Check digit by digit. + j = ( ( xLTy = xc.length < yc.length ) ? xc : yc ).length; + + for ( a = b = 0; b < j; b++ ) { + + if ( xc[b] != yc[b] ) { + xLTy = xc[b] < yc[b]; + break; + } + } + } + + // x < y? Point xc to the array of the bigger number. + if ( xLTy ) { + d = xc, xc = yc, yc = d; + y['s'] = -y['s']; + } + + /* + * Append zeros to xc if shorter. No need to add zeros to yc if shorter + * as subtraction only needs to start at yc.length. + */ + if ( ( b = -( ( j = xc.length ) - yc.length ) ) > 0 ) { + + for ( ; b--; xc[j++] = 0 ) { + } + } + + // Subtract yc from xc. + for ( b = yc.length; b > a; ){ + + if ( xc[--b] < yc[b] ) { + + for ( i = b; i && !xc[--i]; xc[i] = 9 ) { + } + --xc[i]; + xc[b] += 10; + } + xc[b] -= yc[b]; + } + + // Remove trailing zeros. + for ( ; xc[--j] == 0; xc.pop() ) { + } + + // Remove leading zeros and adjust exponent accordingly. + for ( ; xc[0] == 0; xc.shift(), --ye ) { + } + + /* + * No need to check for Infinity as +x - +y != Infinity && -x - -y != Infinity + * when neither x or y are Infinity. + */ + + // Underflow? + if ( ye < MIN_EXP || !xc[0] ) { + + /* + * Following IEEE 754 (2008) 6.3, + * n - n = +0 but n - n = -0 when rounding towards -Infinity. + */ + if ( !xc[0] ) { + y['s'] = ROUNDING_MODE == 3 ? -1 : 1; + } + + // Result is zero. + xc = [ye = 0]; + } + + return y['c'] = xc, y['e'] = ye, y; + }; + + + /* + * n % 0 = N + * n % N = N + * 0 % n = 0 + * -0 % n = -0 + * 0 % 0 = N + * 0 % N = N + * N % n = N + * N % 0 = N + * N % N = N + * + * Return a new BigNumber whose value is the value of this BigNumber modulo + * the value of BigNumber(y, b). + */ + P['modulo'] = P['mod'] = function ( y, b ) { + var x = this, + xc = x['c'], + yc = ( id = 9, y = new BigNumber( y, b ) )['c'], + i = x['s'], + j = y['s']; + + // Is x or y NaN, or y zero? + b = !i || !j || yc && !yc[0]; + + if ( b || xc && !xc[0] ) { + return new BigNumber( b ? NaN : x ); + } + + x['s'] = y['s'] = 1; + b = y['cmp'](x) == 1; + x['s'] = i, y['s'] = j; + + return b + ? new BigNumber(x) + : ( i = DECIMAL_PLACES, j = ROUNDING_MODE, + DECIMAL_PLACES = 0, ROUNDING_MODE = 1, + x = x['div'](y), + DECIMAL_PLACES = i, ROUNDING_MODE = j, + this['minus']( x['times'](y) ) ); + }; + + + /* + * Return a new BigNumber whose value is the value of this BigNumber + * negated, i.e. multiplied by -1. + */ + P['negated'] = P['neg'] = function () { + var x = new BigNumber(this); + + return x['s'] = -x['s'] || null, x; + }; + + + /* + * n + 0 = n + * n + N = N + * n + I = I + * 0 + n = n + * 0 + 0 = 0 + * 0 + N = N + * 0 + I = I + * N + n = N + * N + 0 = N + * N + N = N + * N + I = N + * I + n = I + * I + 0 = I + * I + N = N + * I + I = I + * + * Return a new BigNumber whose value is the value of this BigNumber plus + * the value of BigNumber(y, b). + */ + P['plus'] = function ( y, b ) { + var d, + x = this, + a = x['s']; + + b = ( id = 10, y = new BigNumber( y, b ) )['s']; + + // Either NaN? + if ( !a || !b ) { + return new BigNumber(NaN); + } + + // Signs differ? + if ( a != b ) { + return y['s'] = -b, x['minus'](y); + } + + var xe = x['e'], + xc = x['c'], + ye = y['e'], + yc = y['c']; + + if ( !xe || !ye ) { + + // Either Infinity? + if ( !xc || !yc ) { + + // Return +-Infinity. + return new BigNumber( a / 0 ); + } + + // Either zero? + if ( !xc[0] || !yc[0] ) { + + // y is non-zero? + return yc[0] + ? y + + // x is non-zero? + : new BigNumber( xc[0] + ? x + + // Both are zero. Return zero. + : a * 0 ); + } + } + + // Prepend zeros to equalise exponents. + // Note: Faster to use reverse then do unshifts. + if ( xc = xc.slice(), a = xe - ye ) { + d = a > 0 ? ( ye = xe, yc ) : ( a = -a, xc ); + + for ( d.reverse(); a--; d.push(0) ) { + } + d.reverse(); + } + + // Point xc to the longer array. + if ( xc.length - yc.length < 0 ) { + d = yc, yc = xc, xc = d; + } + + /* + * Only start adding at yc.length - 1 as the + * further digits of xc can be left as they are. + */ + for ( a = yc.length, b = 0; a; + b = ( xc[--a] = xc[a] + yc[a] + b ) / 10 ^ 0, xc[a] %= 10 ) { + } + + // No need to check for zero, as +x + +y != 0 && -x + -y != 0 + + if ( b ) { + xc.unshift(b); + + // Overflow? (MAX_EXP + 1 possible) + if ( ++ye > MAX_EXP ) { + + // Infinity. + xc = ye = null; + } + } + + // Remove trailing zeros. + for ( a = xc.length; xc[--a] == 0; xc.pop() ) { + } + + return y['c'] = xc, y['e'] = ye, y; + }; + + + /* + * Return a BigNumber whose value is the value of this BigNumber raised to + * the power e. If e is negative round according to DECIMAL_PLACES and + * ROUNDING_MODE. + * + * e {number} Integer, -MAX_POWER to MAX_POWER inclusive. + */ + P['toPower'] = P['pow'] = function ( e ) { + + // e to integer, avoiding NaN or Infinity becoming 0. + var i = e * 0 == 0 ? e | 0 : e, + x = new BigNumber(this), + y = new BigNumber(ONE); + + // Use Math.pow? + // Pass +-Infinity for out of range exponents. + if ( ( ( ( outOfRange = e < -MAX_POWER || e > MAX_POWER ) && + (i = e * 1 / 0) ) || + + /* + * Any exponent that fails the parse becomes NaN. + * + * Include 'e !== 0' because on Opera -0 == parseFloat(-0) is false, + * despite -0 === parseFloat(-0) && -0 == parseFloat('-0') is true. + */ + parse(e) != e && e !== 0 && !(i = NaN) ) && + + // 'pow() exponent not an integer: {e}' + // 'pow() exponent out of range: {e}' + !ifExceptionsThrow( e, 'exponent', 'pow' ) || + + // Pass zero to Math.pow, as any value to the power zero is 1. + !i ) { + + // i is +-Infinity, NaN or 0. + return new BigNumber( Math.pow( x['toS'](), i ) ); + } + + for ( i = i < 0 ? -i : i; ; ) { + + if ( i & 1 ) { + y = y['times'](x); + } + i >>= 1; + + if ( !i ) { + break; + } + x = x['times'](x); + } + + return e < 0 ? ONE['div'](y) : y; + }; + + + /* + * Return a new BigNumber whose value is the value of this BigNumber + * rounded to a maximum of dp decimal places using rounding mode rm, or to + * 0 and ROUNDING_MODE respectively if omitted. + * + * [dp] {number} Integer, 0 to MAX inclusive. + * [rm] {number} Integer, 0 to 8 inclusive. + */ + P['round'] = function ( dp, rm ) { + + dp = dp == null || ( ( ( outOfRange = dp < 0 || dp > MAX ) || + parse(dp) != dp ) && + + // 'round() decimal places out of range: {dp}' + // 'round() decimal places not an integer: {dp}' + !ifExceptionsThrow( dp, 'decimal places', 'round' ) ) + ? 0 + : dp | 0; + + rm = rm == null || ( ( ( outOfRange = rm < 0 || rm > 8 ) || + + // Include '&& rm !== 0' because with Opera -0 == parseFloat(-0) is false. + parse(rm) != rm && rm !== 0 ) && + + // 'round() mode not an integer: {rm}' + // 'round() mode out of range: {rm}' + !ifExceptionsThrow( rm, 'mode', 'round' ) ) + ? ROUNDING_MODE + : rm | 0; + + return setMode( this, dp, rm ); + }; + + + /* + * sqrt(-n) = N + * sqrt( N) = N + * sqrt(-I) = N + * sqrt( I) = I + * sqrt( 0) = 0 + * sqrt(-0) = -0 + * + * Return a new BigNumber whose value is the square root of the value of + * this BigNumber, rounded according to DECIMAL_PLACES and ROUNDING_MODE. + */ + P['squareRoot'] = P['sqrt'] = function () { + var n, r, re, t, + x = this, + c = x['c'], + s = x['s'], + e = x['e'], + dp = DECIMAL_PLACES, + rm = ROUNDING_MODE, + half = new BigNumber('0.5'); + + // Negative/NaN/Infinity/zero? + if ( s !== 1 || !c || !c[0] ) { + + return new BigNumber( !s || s < 0 && ( !c || c[0] ) + ? NaN + : c ? x : 1 / 0 ); + } + + // Initial estimate. + s = Math.sqrt( x['toS']() ); + ROUNDING_MODE = 1; + + /* + Math.sqrt underflow/overflow? + Pass x to Math.sqrt as integer, then adjust the exponent of the result. + */ + if ( s == 0 || s == 1 / 0 ) { + n = c.join(''); + + if ( !( n.length + e & 1 ) ) { + n += '0'; + } + r = new BigNumber( Math.sqrt(n) + '' ); + + // r may still not be finite. + if ( !r['c'] ) { + r['c'] = [1]; + } + r['e'] = ( ( ( e + 1 ) / 2 ) | 0 ) - ( e < 0 || e & 1 ); + } else { + r = new BigNumber( n = s.toString() ); + } + re = r['e']; + s = re + ( DECIMAL_PLACES += 4 ); + + if ( s < 3 ) { + s = 0; + } + e = s; + + // Newton-Raphson iteration. + for ( ; ; ) { + t = r; + r = half['times']( t['plus']( x['div'](t) ) ); + + if ( t['c'].slice( 0, s ).join('') === r['c'].slice( 0, s ).join('') ) { + c = r['c']; + + /* + The exponent of r may here be one less than the final result + exponent (re), e.g 0.0009999 (e-4) --> 0.001 (e-3), so adjust + s so the rounding digits are indexed correctly. + */ + s = s - ( n && r['e'] < re ); + + /* + The 4th rounding digit may be in error by -1 so if the 4 rounding + digits are 9999 or 4999 (i.e. approaching a rounding boundary) + continue the iteration. + */ + if ( c[s] == 9 && c[s - 1] == 9 && c[s - 2] == 9 && + ( c[s - 3] == 9 || n && c[s - 3] == 4 ) ) { + + /* + If 9999 on first run through, check to see if rounding up + gives the exact result as the nines may infinitely repeat. + */ + if ( n && c[s - 3] == 9 ) { + t = r['round']( dp, 0 ); + + if ( t['times'](t)['eq'](x) ) { + ROUNDING_MODE = rm; + DECIMAL_PLACES = dp; + + return t; + } + } + DECIMAL_PLACES += 4; + s += 4; + n = ''; + } else { + + /* + If the rounding digits are null, 0000 or 5000, check for an + exact result. If not, then there are further digits so + increment the 1st rounding digit to ensure correct rounding. + */ + if ( !c[e] && !c[e - 1] && !c[e - 2] && + ( !c[e - 3] || c[e - 3] == 5 ) ) { + + // Truncate to the first rounding digit. + if ( c.length > e - 2 ) { + c.length = e - 2; + } + + if ( !r['times'](r)['eq'](x) ) { + + while ( c.length < e - 3 ) { + c.push(0); + } + c[e - 3]++; + } + } + ROUNDING_MODE = rm; + rnd( r, DECIMAL_PLACES = dp, 10 ); + + return r; + } + } + } + }; + + + /* + * n * 0 = 0 + * n * N = N + * n * I = I + * 0 * n = 0 + * 0 * 0 = 0 + * 0 * N = N + * 0 * I = N + * N * n = N + * N * 0 = N + * N * N = N + * N * I = N + * I * n = I + * I * 0 = N + * I * N = N + * I * I = I + * + * Return a new BigNumber whose value is the value of this BigNumber times + * the value of BigNumber(y, b). + */ + P['times'] = function ( y, b ) { + var c, + x = this, + xc = x['c'], + yc = ( id = 11, y = new BigNumber( y, b ) )['c'], + i = x['e'], + j = y['e'], + a = x['s']; + + y['s'] = a == ( b = y['s'] ) ? 1 : -1; + + // Either NaN/Infinity/0? + if ( !i && ( !xc || !xc[0] ) || !j && ( !yc || !yc[0] ) ) { + + // Either NaN? + return new BigNumber( !a || !b || + + // x is 0 and y is Infinity or y is 0 and x is Infinity? + xc && !xc[0] && !yc || yc && !yc[0] && !xc + + // Return NaN. + ? NaN + + // Either Infinity? + : !xc || !yc + + // Return +-Infinity. + ? y['s'] / 0 + + // x or y is 0. Return +-0. + : y['s'] * 0 ); + } + y['e'] = i + j; + + if ( ( a = xc.length ) < ( b = yc.length ) ) { + c = xc, xc = yc, yc = c, j = a, a = b, b = j; + } + + for ( j = a + b, c = []; j--; c.push(0) ) { + } + + // Multiply! + for ( i = b - 1; i > -1; i-- ) { + + for ( b = 0, j = a + i; + j > i; + b = c[j] + yc[i] * xc[j - i - 1] + b, + c[j--] = b % 10 | 0, + b = b / 10 | 0 ) { + } + + if ( b ) { + c[j] = ( c[j] + b ) % 10; + } + } + + b && ++y['e']; + + // Remove any leading zero. + !c[0] && c.shift(); + + // Remove trailing zeros. + for ( j = c.length; !c[--j]; c.pop() ) { + } + + // No zero check needed as only x * 0 == 0 etc. + + // Overflow? + y['c'] = y['e'] > MAX_EXP + + // Infinity. + ? ( y['e'] = null ) + + // Underflow? + : y['e'] < MIN_EXP + + // Zero. + ? [ y['e'] = 0 ] + + // Neither. + : c; + + return y; + }; + + + /* + * Return a string representing the value of this BigNumber in exponential + * notation to dp fixed decimal places and rounded using ROUNDING_MODE if + * necessary. + * + * [dp] {number} Integer, 0 to MAX inclusive. + */ + P['toExponential'] = P['toE'] = function ( dp ) { + + return format( this, + ( dp == null || ( ( outOfRange = dp < 0 || dp > MAX ) || + + /* + * Include '&& dp !== 0' because with Opera -0 == parseFloat(-0) is + * false, despite -0 == parseFloat('-0') && 0 == -0 being true. + */ + parse(dp) != dp && dp !== 0 ) && + + // 'toE() decimal places not an integer: {dp}' + // 'toE() decimal places out of range: {dp}' + !ifExceptionsThrow( dp, 'decimal places', 'toE' ) ) && this['c'] + ? this['c'].length - 1 + : dp | 0, 1 ); + }; + + + /* + * Return a string representing the value of this BigNumber in normal + * notation to dp fixed decimal places and rounded using ROUNDING_MODE if + * necessary. + * + * Note: as with JavaScript's number type, (-0).toFixed(0) is '0', + * but e.g. (-0.00001).toFixed(0) is '-0'. + * + * [dp] {number} Integer, 0 to MAX inclusive. + */ + P['toFixed'] = P['toF'] = function ( dp ) { + var n, str, d, + x = this; + + if ( !( dp == null || ( ( outOfRange = dp < 0 || dp > MAX ) || + parse(dp) != dp && dp !== 0 ) && + + // 'toF() decimal places not an integer: {dp}' + // 'toF() decimal places out of range: {dp}' + !ifExceptionsThrow( dp, 'decimal places', 'toF' ) ) ) { + d = x['e'] + ( dp | 0 ); + } + + n = TO_EXP_NEG, dp = TO_EXP_POS; + TO_EXP_NEG = -( TO_EXP_POS = 1 / 0 ); + + // Note: str is initially undefined. + if ( d == str ) { + str = x['toS'](); + } else { + str = format( x, d ); + + // (-0).toFixed() is '0', but (-0.1).toFixed() is '-0'. + // (-0).toFixed(1) is '0.0', but (-0.01).toFixed(1) is '-0.0'. + if ( x['s'] < 0 && x['c'] ) { + + // As e.g. -0 toFixed(3), will wrongly be returned as -0.000 from toString. + if ( !x['c'][0] ) { + str = str.replace(/^-/, ''); + + // As e.g. -0.5 if rounded to -0 will cause toString to omit the minus sign. + } else if ( str.indexOf('-') < 0 ) { + str = '-' + str; + } + } + } + TO_EXP_NEG = n, TO_EXP_POS = dp; + + return str; + }; + + + /* + * Return a string array representing the value of this BigNumber as a + * simple fraction with an integer numerator and an integer denominator. + * The denominator will be a positive non-zero value less than or equal to + * the specified maximum denominator. If a maximum denominator is not + * specified, the denominator will be the lowest value necessary to + * represent the number exactly. + * + * [maxD] {number|string|BigNumber} Integer >= 1 and < Infinity. + */ + P['toFraction'] = P['toFr'] = function ( maxD ) { + var q, frac, n0, d0, d2, n, e, + n1 = d0 = new BigNumber(ONE), + d1 = n0 = new BigNumber('0'), + x = this, + xc = x['c'], + exp = MAX_EXP, + dp = DECIMAL_PLACES, + rm = ROUNDING_MODE, + d = new BigNumber(ONE); + + // NaN, Infinity. + if ( !xc ) { + return x['toS'](); + } + + e = d['e'] = xc.length - x['e'] - 1; + + // If max denominator is undefined or null... + if ( maxD == null || + + // or NaN... + ( !( id = 12, n = new BigNumber(maxD) )['s'] || + + // or less than 1, or Infinity... + ( outOfRange = n['cmp'](n1) < 0 || !n['c'] ) || + + // or not an integer... + ( ERRORS && n['e'] < n['c'].length - 1 ) ) && + + // 'toFr() max denominator not an integer: {maxD}' + // 'toFr() max denominator out of range: {maxD}' + !ifExceptionsThrow( maxD, 'max denominator', 'toFr' ) || + + // or greater than the maxD needed to specify the value exactly... + ( maxD = n )['cmp'](d) > 0 ) { + + // d is e.g. 10, 100, 1000, 10000... , n1 is 1. + maxD = e > 0 ? d : n1; + } + + MAX_EXP = 1 / 0; + n = new BigNumber( xc.join('') ); + + for ( DECIMAL_PLACES = 0, ROUNDING_MODE = 1; ; ) { + q = n['div'](d); + d2 = d0['plus']( q['times'](d1) ); + + if ( d2['cmp'](maxD) == 1 ) { + break; + } + + d0 = d1, d1 = d2; + + n1 = n0['plus']( q['times']( d2 = n1 ) ); + n0 = d2; + + d = n['minus']( q['times']( d2 = d ) ); + n = d2; + } + + d2 = maxD['minus'](d0)['div'](d1); + n0 = n0['plus']( d2['times'](n1) ); + d0 = d0['plus']( d2['times'](d1) ); + + n0['s'] = n1['s'] = x['s']; + + DECIMAL_PLACES = e * 2; + ROUNDING_MODE = rm; + + // Determine which fraction is closer to x, n0 / d0 or n1 / d1? + frac = n1['div'](d1)['minus'](x)['abs']()['cmp']( + n0['div'](d0)['minus'](x)['abs']() ) < 1 + ? [ n1['toS'](), d1['toS']() ] + : [ n0['toS'](), d0['toS']() ]; + + return MAX_EXP = exp, DECIMAL_PLACES = dp, frac; + }; + + + /* + * Return a string representing the value of this BigNumber to sd significant + * digits and rounded using ROUNDING_MODE if necessary. + * If sd is less than the number of digits necessary to represent the integer + * part of the value in normal notation, then use exponential notation. + * + * sd {number} Integer, 1 to MAX inclusive. + */ + P['toPrecision'] = P['toP'] = function ( sd ) { + + /* + * ERRORS true: Throw if sd not undefined, null or an integer in range. + * ERRORS false: Ignore sd if not a number or not in range. + * Truncate non-integers. + */ + return sd == null || ( ( ( outOfRange = sd < 1 || sd > MAX ) || + parse(sd) != sd ) && + + // 'toP() precision not an integer: {sd}' + // 'toP() precision out of range: {sd}' + !ifExceptionsThrow( sd, 'precision', 'toP' ) ) + ? this['toS']() + : format( this, --sd | 0, 2 ); + }; + + + /* + * Return a string representing the value of this BigNumber in base b, or + * base 10 if b is omitted. If a base is specified, including base 10, + * round according to DECIMAL_PLACES and ROUNDING_MODE. + * If a base is not specified, and this BigNumber has a positive exponent + * that is equal to or greater than TO_EXP_POS, or a negative exponent equal + * to or less than TO_EXP_NEG, return exponential notation. + * + * [b] {number} Integer, 2 to 64 inclusive. + */ + P['toString'] = P['toS'] = function ( b ) { + var u, str, strL, + x = this, + xe = x['e']; + + // Infinity or NaN? + if ( xe === null ) { + str = x['s'] ? 'Infinity' : 'NaN'; + + // Exponential format? + } else if ( b === u && ( xe <= TO_EXP_NEG || xe >= TO_EXP_POS ) ) { + return format( x, x['c'].length - 1, 1 ); + } else { + str = x['c'].join(''); + + // Negative exponent? + if ( xe < 0 ) { + + // Prepend zeros. + for ( ; ++xe; str = '0' + str ) { + } + str = '0.' + str; + + // Positive exponent? + } else if ( strL = str.length, xe > 0 ) { + + if ( ++xe > strL ) { + + // Append zeros. + for ( xe -= strL; xe-- ; str += '0' ) { + } + } else if ( xe < strL ) { + str = str.slice( 0, xe ) + '.' + str.slice(xe); + } + + // Exponent zero. + } else { + if ( u = str.charAt(0), strL > 1 ) { + str = u + '.' + str.slice(1); + + // Avoid '-0' + } else if ( u == '0' ) { + return u; + } + } + + if ( b != null ) { + + if ( !( outOfRange = !( b >= 2 && b < 65 ) ) && + ( b == (b | 0) || !ERRORS ) ) { + str = convert( str, b | 0, 10, x['s'] ); + + // Avoid '-0' + if ( str == '0' ) { + return str; + } + } else { + + // 'toS() base not an integer: {b}' + // 'toS() base out of range: {b}' + ifExceptionsThrow( b, 'base', 'toS' ); + } + } + + } + + return x['s'] < 0 ? '-' + str : str; + }; + + + /* + * Return the value of this BigNumber converted to a number primitive. + * + */ + P['toNumber'] = P['toN'] = function () { + var x = this; + + // Ensure zero has correct sign. + return +x || ( x['s'] ? 0 * x['s'] : NaN ); + }; + + + /* + * Return as toString, but do not accept a base argument. + */ + P['valueOf'] = function () { + return this['toS'](); + }; + + + // Add aliases for BigDecimal methods. + //P['add'] = P['plus']; + //P['subtract'] = P['minus']; + //P['multiply'] = P['times']; + //P['divide'] = P['div']; + //P['remainder'] = P['mod']; + //P['compareTo'] = P['cmp']; + //P['negate'] = P['neg']; + + + // EXPORT + + + // Node and other CommonJS-like environments that support module.exports. + if ( typeof module !== 'undefined' && module.exports ) { + module.exports = BigNumber; + + //AMD. + } else if ( typeof define == 'function' && define.amd ) { + define( function () { + return BigNumber; + }); + + //Browser. + } else { + global['BigNumber'] = BigNumber; + } + +})( this ); diff --git a/node_modules/mysql/node_modules/bignumber.js/bignumber.min.js b/node_modules/mysql/node_modules/bignumber.js/bignumber.min.js new file mode 100644 index 0000000..c6e985f --- /dev/null +++ b/node_modules/mysql/node_modules/bignumber.js/bignumber.min.js @@ -0,0 +1,2 @@ +/*! bignumber.js v1.4.1 https://github.com/MikeMcl/bignumber.js/LICENCE */ +(function(n){"use strict";function t(n,i){var c,l,a,b,w,p,s=this;if(!(s instanceof t))return new t(n,i);if(n instanceof t)if(u=0,i!==c)n+="";else{s.s=n.s;s.e=n.e;s.c=(n=n.c)?n.slice():n;return}if(typeof n!="string"&&(n=(a=typeof n=="number"||Object.prototype.toString.call(n)=="[object Number]")&&n===0&&1/n<0?"-0":n+""),p=n,i===c&&g.test(n))s.s=n.charAt(0)=="-"?(n=n.slice(1),-1):1;else{if(i==10)return k(n,e,r);if(n=rt.call(n).replace(/^\+(?!-)/,""),s.s=n.charAt(0)=="-"?(n=n.replace(/^-(?!-)/,""),-1):1,i!=null?i!=(i|0)&&y||(o=!(i>=2&&i<65))?(f(i,2),w=g.test(n)):(b="["+d.slice(0,i=i|0)+"]+",n=n.replace(/\.$/,"").replace(/^\./,"0."),(w=new RegExp("^"+b+"(?:\\."+b+")?$",i<37?"i":"").test(n))?(a&&(n.replace(/^0\.0*|\./,"").length>15&&f(p,0),a=!a),n=tt(n,10,i,s.s)):n!="Infinity"&&n!="NaN"&&(f(p,1,i),n="NaN")):w=g.test(n),!w){s.c=s.e=null;n!="Infinity"&&(n!="NaN"&&f(p,3),s.s=null);u=0;return}}for((c=n.indexOf("."))>-1&&(n=n.replace(".","")),(l=n.search(/e/i))>0?(c<0&&(c=l),c+=+n.slice(l+1),n=n.substring(0,l)):c<0&&(c=n.length),l=0;n.charAt(l)=="0";l++);if(i=n.length,a&&i>15&&n.slice(l).length>15&&f(p,0),u=0,(c-=l+1)>h)s.c=s.e=null;else if(l==i||ci-1&&(f[u+1]==null&&(f[u+1]=0),f[u+1]+=f[u]/i^0,f[u]%=i)}return f.reverse()}function o(n){for(var t=0,r=n.length,i="";t-1)if(e=n.length-e-1,c=h(new t(r).pow(e).toF(),10),f=n.split("."),l=h(f[1]),f=h(f[0]),a=it(l,c,l.length-c.length,u,i,f[f.length-1]&1),s=a.c,e=a.e){for(;++e;s.unshift(0));n=o(f)+"."+o(s)}else s[0]?f[e=f.length-1]c?1:-1;else for(a=-1,w=0;++as[a]?1:-1;break}if(w<0){for(d=c==y?i:rt;c;){if(s[--c]it&&b(l,e,f,o,s[0]!=null),l.e>h?l.c=l.e=null:l.e++i&&b(n,u,10),u=f[0]==0?u+1:r?i:n.e+u+1;f.length1?(f.splice(1,0,"."),f.join("")):f[0])+(u<0?"e":"e+")+u:n.toS()}function b(n,t,i,u,f){var e=n.c,s=n.s<0,c=i/2,o=n.e+t+1,h=e[o],l=f||o<0||e[o+1]!=null;if(f=r<4?(h!=null||l)&&(r==0||r==2&&!s||r==3&&s):h>c||h==c&&(r==4||l||r==6&&(e[o-1]&1||!t&&u)||r==7&&!s||r==8&&s),o<1||!e[0])return e.length=0,e.push(0),f?(e[0]=1,n.e=-t):n.e=0,n;if(e.length=o--,f)for(--i;++e[o]>i;)e[o]=0,o--||(++n.e,e.unshift(1));for(o=e.length;!e[--o];e.pop());return n}function k(n,i,u){var f=r;return r=u,n=new t(n),n.c&&b(n,i,10),r=f,n}var s=1e9,nt=1e6,e=20,r=4,c=-7,a=21,v=-s,h=s,y=!0,l=parseInt,i=t.prototype,d="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ$_",o,u=0,g=/^-?(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,rt=String.prototype.trim||function(){return this.replace(/^\s+|\s+$/g,"")},p=t(1);t.ROUND_UP=0;t.ROUND_DOWN=1;t.ROUND_CEIL=2;t.ROUND_FLOOR=3;t.ROUND_HALF_UP=4;t.ROUND_HALF_DOWN=5;t.ROUND_HALF_EVEN=6;t.ROUND_HALF_CEIL=7;t.ROUND_HALF_FLOOR=8;t.config=function(){var n,t,g=0,p={},d=arguments,k=d[0],w="config",i=function(n,t,i){return!((o=ni)||l(n)!=n&&n!==0)},b=k&&typeof k=="object"?function(){if(k.hasOwnProperty(t))return(n=k[t])!=null}:function(){if(d.length>g)return(n=d[g++])!=null};return b(t="DECIMAL_PLACES")&&(i(n,0,s)?e=n|0:f(n,t,w)),p[t]=e,b(t="ROUNDING_MODE")&&(i(n,0,8)?r=n|0:f(n,t,w)),p[t]=r,b(t="EXPONENTIAL_AT")&&(i(n,-s,s)?c=-(a=~~(n<0?-n:+n)):!o&&n&&i(n[0],-s,0)&&i(n[1],0,s)?(c=~~n[0],a=~~n[1]):f(n,t,w,1)),p[t]=[c,a],b(t="RANGE")&&(i(n,-s,s)&&~~n?v=-(h=~~(n<0?-n:+n)):!o&&n&&i(n[0],-s,-1)&&i(n[1],1,s)?(v=~~n[0],h=~~n[1]):f(n,t,w,1,1)),p[t]=[v,h],b(t="ERRORS")&&(n===!!n||n===1||n===0?l=(o=u=0,y=!!n)?parseInt:parseFloat:f(n,t,w,0,0,1)),p[t]=y,p};i.abs=i.absoluteValue=function(){var n=new t(this);return n.s<0&&(n.s=1),n};i.ceil=function(){return k(this,0,2)};i.comparedTo=i.cmp=function(n,i){var f,l=this,e=l.c,o=(u=-u,n=new t(n,i)).c,r=l.s,c=n.s,s=l.e,h=n.e;if(!r||!c)return null;if(f=e&&!e[0],i=o&&!o[0],f||i)return f?i?0:-c:r;if(r!=c)return r;if(f=r<0,i=s==h,!e||!o)return i?0:!e^f?1:-1;if(!i)return s>h^f?1:-1;for(r=-1,c=(s=e.length)<(h=o.length)?s:h;++ro[r]^f?1:-1;return s==h?0:s>h^f?1:-1};i.dividedBy=i.div=function(n,i){var r=this.c,o=this.e,s=this.s,f=(u=2,n=new t(n,i)).c,h=n.e,c=n.s,e=s==c?1:-1;return!o&&(!r||!r[0])||!h&&(!f||!f[0])?new t(!s||!c||(r?f&&r[0]==f[0]:!f)?NaN:r&&r[0]==0||!f?e*0:e/0):it(r,f,o-h,e,10)};i.equals=i.eq=function(n,t){return u=3,this.cmp(n,t)===0};i.floor=function(){return k(this,0,3)};i.greaterThan=i.gt=function(n,t){return u=4,this.cmp(n,t)>0};i.greaterThanOrEqualTo=i.gte=function(n,t){return u=5,(t=this.cmp(n,t))==1||t===0};i.isFinite=i.isF=function(){return!!this.c};i.isNaN=function(){return!this.s};i.isNegative=i.isNeg=function(){return this.s<0};i.isZero=i.isZ=function(){return!!this.c&&this.c[0]==0};i.lessThan=i.lt=function(n,t){return u=6,this.cmp(n,t)<0};i.lessThanOrEqualTo=i.lte=function(n,t){return u=7,(t=this.cmp(n,t))==-1||t===0};i.minus=function(n,i){var h,l,a,y,c=this,o=c.s;if(i=(u=8,n=new t(n,i)).s,!o||!i)return new t(NaN);if(o!=i)return n.s=-i,c.plus(n);var f=c.c,p=c.e,e=n.c,s=n.e;if(!p||!s){if(!f||!e)return f?(n.s=-i,n):new t(e?c:NaN);if(!f[0]||!e[0])return e[0]?(n.s=-i,n):new t(f[0]?c:r==3?-0:0)}if(f=f.slice(),o=p-s){for(h=(y=o<0)?(o=-o,f):(s=p,e),h.reverse(),i=o;i--;h.push(0));h.reverse()}else for(a=((y=f.length0)for(;i--;f[a++]=0);for(i=e.length;i>o;){if(f[--i]0?(s=l,e):(f=-f,r),o.reverse();f--;o.push(0));o.reverse()}for(r.length-e.length<0&&(o=e,e=r,r=o),f=e.length,i=0;f;i=(r[--f]=r[f]+e[f]+i)/10^0,r[f]%=10);for(i&&(r.unshift(i),++s>h&&(r=s=null)),f=r.length;r[--f]==0;r.pop());return n.c=r,n.e=s,n};i.toPower=i.pow=function(n){var i=n*0==0?n|0:n,r=new t(this),u=new t(p);if(((o=n<-nt||n>nt)&&(i=n/0)||l(n)!=n&&n!==0&&!(i=NaN))&&!f(n,"exponent","pow")||!i)return new t(Math.pow(r.toS(),i));for(i=i<0?-i:i;;){if(i&1&&(u=u.times(r)),i>>=1,!i)break;r=r.times(r)}return n<0?p.div(u):u};i.round=function(n,t){return n=n==null||((o=n<0||n>s)||l(n)!=n)&&!f(n,"decimal places","round")?0:n|0,t=t==null||((o=t<0||t>8)||l(t)!=t&&t!==0)&&!f(t,"mode","round")?r:t|0,k(this,n,t)};i.squareRoot=i.sqrt=function(){var o,u,c,s,h=this,n=h.c,i=h.s,f=h.e,l=e,a=r,v=new t("0.5");if(i!==1||!n||!n[0])return new t(!i||i<0&&(!n||n[0])?NaN:n?h:1/0);for(i=Math.sqrt(h.toS()),r=1,i==0||i==1/0?(o=n.join(""),o.length+f&1||(o+="0"),u=new t(Math.sqrt(o)+""),u.c||(u.c=[1]),u.e=((f+1)/2|0)-(f<0||f&1)):u=new t(o=i.toString()),c=u.e,i=c+(e+=4),i<3&&(i=0),f=i;;)if(s=u,u=v.times(s.plus(h.div(s))),s.c.slice(0,i).join("")===u.c.slice(0,i).join(""))if(n=u.c,i=i-(o&&u.ef-2&&(n.length=f-2),!u.times(u).eq(h))){while(n.length-1;s--){for(i=0,r=c+s;r>s;i=f[r]+o[s]*e[r-s-1]+i,f[r--]=i%10|0,i=i/10|0);i&&(f[r]=(f[r]+i)%10)}for(i&&++n.e,f[0]||f.shift(),r=f.length;!f[--r];f.pop());return n.c=n.e>h?n.e=null:n.es)||l(n)!=n&&n!==0)&&!f(n,"decimal places","toE"))&&this.c?this.c.length-1:n|0,1)};i.toFixed=i.toF=function(n){var u,t,r,i=this;return n==null||((o=n<0||n>s)||l(n)!=n&&n!==0)&&!f(n,"decimal places","toF")||(r=i.e+(n|0)),u=c,n=a,c=-(a=1/0),r==t?t=i.toS():(t=w(i,r),i.s<0&&i.c&&(i.c[0]?t.indexOf("-")<0&&(t="-"+t):t=t.replace(/^-/,""))),c=u,a=n,t};i.toFraction=i.toFr=function(n){var k,nt,c,l,i,s,d,a=l=new t(p),v=c=new t("0"),w=this,g=w.c,tt=h,it=e,rt=r,b=new t(p);if(!g)return w.toS();for(d=b.e=g.length-w.e-1,(n==null||(!(u=12,s=new t(n)).s||(o=s.cmp(a)<0||!s.c)||y&&s.e0)&&(n=d>0?b:a),h=1/0,s=new t(g.join("")),e=0,r=1;;){if(k=s.div(b),i=l.plus(k.times(v)),i.cmp(n)==1)break;l=v;v=i;a=c.plus(k.times(i=a));c=i;b=s.minus(k.times(i=b));s=i}return i=n.minus(l).div(v),c=c.plus(i.times(a)),l=l.plus(i.times(v)),c.s=a.s=w.s,e=d*2,r=rt,nt=a.div(v).minus(w).abs().cmp(c.div(l).minus(w).abs())<1?[a.toS(),v.toS()]:[c.toS(),l.toS()],h=tt,e=it,nt};i.toPrecision=i.toP=function(n){return n==null||((o=n<1||n>s)||l(n)!=n)&&!f(n,"precision","toP")?this.toS():w(this,--n|0,2)};i.toString=i.toS=function(n){var u,t,e,r=this,i=r.e;if(i===null)t=r.s?"Infinity":"NaN";else{if(n===u&&(i<=c||i>=a))return w(r,r.c.length-1,1);if(t=r.c.join(""),i<0){for(;++i;t="0"+t);t="0."+t}else if(e=t.length,i>0)if(++i>e)for(i-=e;i--;t+="0");else i1)t=u+"."+t.slice(1);else if(u=="0")return u;if(n!=null)if((o=!(n>=2&&n<65))||n!=(n|0)&&y)f(n,"base","toS");else if(t=tt(t,n|0,10,r.s),t=="0")return t}return r.s<0?"-"+t:t};i.toNumber=i.toN=function(){var n=this;return+n||(n.s?0*n.s:NaN)};i.valueOf=function(){return this.toS()};typeof module!="undefined"&&module.exports?module.exports=t:typeof define=="function"&&define.amd?define(function(){return t}):n.BigNumber=t})(this) \ No newline at end of file diff --git a/node_modules/mysql/node_modules/bignumber.js/doc/API.html b/node_modules/mysql/node_modules/bignumber.js/doc/API.html new file mode 100644 index 0000000..da221ac --- /dev/null +++ b/node_modules/mysql/node_modules/bignumber.js/doc/API.html @@ -0,0 +1,1731 @@ + + + + + + + bignumber.js API + + + + + + +
    + +

    bignumber.js

    + +

    A JavaScript library for arbitrary-precision arithmetic.

    + +

    + Hosted on GitHub. +

    + + +

    API

    + +

    + In all examples below, var and semicolons are not shown, and + if a commented-out value is in quotes it means toString has + been called on the preceding expression. +

    + + + +

    CONSTRUCTOR

    + +
    + BigNumberBigNumber(value [, base]) ⇒ + BigNumber + +
    +
    +
    value
    +
    + number|string|BigNumber : See RANGE for + range. +
    +
    + A numeric value. +
    +
    + Legitimate values include ±0, + ±Infinity and NaN. +
    +
    + Values of type number with more than 15 significant digits are + considered invalid as calling toString or + valueOf on such numbers may not result in the intended + value. +
    +
    + There is no limit to the number of digits of a value of type + string (other than that of JavaScript's maximum array size). +
    +
    + Decimal string values may be in exponential, as well as normal + (non-exponential) notation. Non-decimal values must be in normal + notation. +
    +
    + String values in hexadecimal literal form, e.g. '0xff', are + invalid, and string values in octal literal form will be interpreted as + decimals, e.g. '011' is interpreted as 11, not 9. +
    +
    Values in any base may have fraction digits.
    +
    + For bases from 10 to 36, lower and/or upper case letters can be used to + represent values from 10 to 35. For bases above 36, a-z + represents values from 10 to 35, A-Z from 36 to 61, and + $ and _ represent 62 and 63 respectively + (this can be changed by ediiting the DIGITS variable near the top of the + source file). +
    +
    +
    +
    base
    +
    + number : integer, 2 to 64 inclusive +
    +
    The base of value.
    +
    If base is omitted, or is null or undefined, + base 10 is assumed.
    +
    +

    Returns a new instance of a BigNumber object.

    +

    + If a base is specified, the value is rounded according to + the current DECIMAL_PLACES and + ROUNDING_MODE settings. + Usefully, this means the decimal places of a decimal value + passed to the constructor can be limited by explicitly specifying base 10. +

    +

    + See Errors for the treatment of an invalid + value or base. +

    +
    +x = new BigNumber(9)                       // '9'
    +y = new BigNumber(x)                       // '9'
    +BigNumber(435.345)                         // 'new' is optional
    +new BigNumber('5032485723458348569331745.33434346346912144534543')
    +new BigNumber('4.321e+4')                  // '43210'
    +new BigNumber('-735.0918e-430')            // '-7.350918e-428'
    +new BigNumber(Infinity)                    // 'Infinity'
    +new BigNumber(NaN)                         // 'NaN'
    +new BigNumber('.5')                        // '0.5'
    +new BigNumber('+2')                        // '2'
    +new BigNumber(-10110100.1, 2)              // '-180.5'
    +new BigNumber('123412421.234324', 5)       // '607236.557696'
    +new BigNumber('ff.8', 16)                  // '255.5'
    +
    +new BigNumber(9, 2)
    +// Throws 'not a base 2 number' if ERRORS is true, otherwise 'NaN'
    +
    +new BigNumber(96517860459076817.4395)
    +// Throws 'number type has more than 15 significant digits'
    +// if ERRORS is true, otherwise '96517860459076820'
    +
    +new BigNumber('blurgh')
    +// Throws 'not a number' if ERRORS is true, otherwise 'NaN'
    +
    +BigNumber.config({DECIMAL_PLACES : 5})
    +new BigNumber(1.23456789)                  // '1.23456789'
    +new BigNumber(1.23456789, 10)              // '1.23457'
    + + +

    Methods

    +

    + The BigNumber constructor has one added method, + config, which configures the library-wide settings for + arithmetic, formatting and errors. +

    + +
    + configconfig([settings]) ⇒ object +
    + + Note: the settings can also be supplied as an argument list, + see below. + +
    +
    settings
    +
    object
    + +
    + An object that contains some or all of the following properties: +
    + + + +
    DECIMAL_PLACES
    +
    + number : integer, 0 to 1e+9 + inclusive
    + Default value: 20 +
    +
    + The maximum number of decimal places of the results of + division, square root and base conversion operations, and power + operations with negative exponents.
    + I.e. aside from the base conversion which may be involved with any + method that accepts a base argument, the value is only relevant to + the dividedBy, squareRoot and + toPower methods. +
    +
    +
    BigNumber.config({ DECIMAL_PLACES : 5 })
    +BigNumber.config(5)    // equivalent
    +
    + + + +
    ROUNDING_MODE
    +
    + number : integer, 0 to 8 + inclusive
    + Default value: 4 + (ROUND_HALF_UP) +
    +
    + The rounding mode used in the above operations and by + round, + toExponential, + toFixed and + toPrecision. +
    +
    + The modes are available as enumerated properties of the BigNumber + constructor. +
    +
    +
    BigNumber.config({ ROUNDING_MODE : 0 })
    +BigNumber.config(null, BigNumber.ROUND_UP)    // equivalent
    +
    + + + +
    EXPONENTIAL_AT
    +
    + number : integer, magnitude 0 to + 1e+9 inclusive, or
    + number[] : [ integer -1e+9 to 0 inclusive, integer 0 to 1e+9 + inclusive ]
    + Default value: [-7, 20] +
    +
    + The exponent value(s) at which toString returns + exponential notation. +
    +
    + If a single number is assigned, the value is the exponent magnitude. +
    + If an array of two numbers is assigned then the first number is the + negative exponent value at and beneath which exponential notation is + used, and the second number is the positive exponent value at and + above which the same. +
    +
    + For example, to emulate JavaScript numbers in terms of the exponent + values at which they begin to use exponential notation, use + [-7, 20]. +
    +
    +
    BigNumber.config({ EXPONENTIAL_AT : 2 })
    +new BigNumber(12.3)         // '12.3'        e is only 1
    +new BigNumber(123)          // '1.23e+2'
    +new BigNumber(0.123)        // '0.123'       e is only -1
    +new BigNumber(0.0123)       // '1.23e-2'
    +
    +BigNumber.config({ EXPONENTIAL_AT : [-7, 20] })
    +new BigNumber(123456789)    // '123456789'   e is only 8
    +new BigNumber(0.000000123)  // '1.23e-7'
    +
    +// Almost never return exponential notation:
    +BigNumber.config({ EXPONENTIAL_AT : 1e+9 })
    +
    +// Always return exponential notation:
    +BigNumber.config({ EXPONENTIAL_AT : 0 })
    +
    +
    + Regardless of the value of EXPONENTIAL_AT, the + toFixed method will always return a value in + normal notation and the toExponential method will + always return a value in exponential form. +
    +
    + Calling toString with a base argument, e.g. + toString(10), will also always return normal notation. +
    + + + +
    RANGE
    +
    + number : integer, magnitude 1 to + 1e+9 inclusive, or
    + number[] : [ integer -1e+9 to -1 inclusive, integer 1 to 1e+9 + inclusive ]
    + Default value: [-1e+9, 1e+9] +
    +
    + The exponent value(s) beyond which overflow to Infinity and + underflow to zero occurs. +
    +
    + If a single number is assigned, it is the maximum exponent + magnitude: values wth a positive exponent of greater magnitude + become Infinity and those with a negative exponent of + greater magnitude become zero. +
    + If an array of two numbers is assigned then the first number is the + negative exponent limit and the second number is the positive + exponent limit. +
    +
    + For example, to emulate JavaScript numbers in terms of the exponent + values at which they become zero and Infinity, use + [-324, 308]. +
    +
    +
    BigNumber.config({ RANGE : 500 })
    +BigNumber.config().RANGE     // [ -500, 500 ]
    +new BigNumber('9.999e499')   // '9.999e+499'
    +new BigNumber('1e500')       // 'Infinity'
    +new BigNumber('1e-499')      // '1e-499'
    +new BigNumber('1e-500')      // '0'
    +
    +BigNumber.config({ RANGE : [-3, 4] })
    +new BigNumber(99999)         // '99999'      e is only 4
    +new BigNumber(100000)        // 'Infinity'   e is 5
    +new BigNumber(0.001)         // '0.01'       e is only -3
    +new BigNumber(0.0001)        // '0'          e is -4
    +
    +
    + The largest possible magnitude of a finite BigNumber is
    + 9.999...e+1000000000
    + The smallest possible magnitude of a non-zero BigNumber is
    + 1e-1000000000 +
    + + + +
    ERRORS
    +
    + boolean/number : true, false, 1 or 0
    + Default value: true +
    +
    + The value that determines whether BigNumber Errors are thrown.
    + If ERRORS is false, this library will not throw errors. +
    +
    + See Errors. +
    +
    +
    BigNumber.config({ ERRORS : false })
    +
    +
    +
    +
    +

    +
    Returns an object with the above properties and their current + values. +

    +

    + If the value to be assigned to any of the above properties is + null or undefined it is ignored. See + Errors for the treatment of invalid values. +

    +
    +BigNumber.config({
    +    DECIMAL_PLACES : 40,
    +    ROUNDING_MODE : BigNumber.ROUND_HALF_CEIL,
    +    EXPONENTIAL_AT : [-10, 20],
    +    RANGE : [-500, 500],
    +    ERRORS : true
    +});
    +
    +// Alternatively but equivalently:
    +BigNumber.config( 40, 7, [-10, 20], 500, 1 )
    +
    +obj = BigNumber.config();
    +obj.ERRORS       // true
    +obj.RANGE        // [-500, 500]
    + + + +

    Properties

    +

    + The library's enumerated rounding modes are stored as properties of the + constructor.
    + They are not referenced internally by the library itself. +

    +

    + Rounding modes 0 to 6 (inclusive) are the same as those of Java's + BigDecimal class. +

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    PropertyValueDescription
    ROUND_UP0Rounds away from zero
    ROUND_DOWN1Rounds towards zero
    ROUND_CEIL2Rounds towards Infinity
    ROUND_FLOOR3Rounds towards -Infinity
    ROUND_HALF_UP4 + Rounds towards nearest neighbour.
    + If equidistant, rounds away from zero +
    ROUND_HALF_DOWN5 + Rounds towards nearest neighbour.
    + If equidistant, rounds towards zero +
    ROUND_HALF_EVEN6 + Rounds towards nearest neighbour.
    + If equidistant, rounds towards even neighbour +
    ROUND_HALF_CEIL7 + Rounds towards nearest neighbour.
    + If equidistant, rounds towards Infinity +
    ROUND_HALF_FLOOR8 + Rounds towards nearest neighbour.
    + If equidistant, rounds towards -Infinity +
    +
    +BigNumber.config({ ROUNDING_MODE : BigNumber.ROUND_CEIL })
    +BigNumber.config({ ROUNDING_MODE : 2 })     // equivalent
    + + +

    INSTANCE

    + +

    Methods

    +

    + The methods inherited by a BigNumber instance from its constructor's + prototype object. +

    +

    + A BigNumber is immutable in the sense that it is not changed by its + methods. +

    +

    + The treatment of ±0, ±Infinity and + NaN is consistent with how JavaScript treats these values. +

    +

    + Method names over 5 letters in length have a shorter alias (except + valueOf).
    + Internally, the library always uses the shorter method names. +

    + + + +
    + absoluteValue.abs() ⇒ BigNumber +
    +

    + Returns a BigNumber whose value is the absolute value, i.e. the magnitude, + of this BigNumber. +

    +
    +x = new BigNumber(-0.8)
    +y = x.absoluteValue()         // '0.8'
    +z = y.abs()                   // '0.8'
    + + + +
    + ceil.ceil() ⇒ BigNumber +
    +

    + Returns a BigNumber whose value is the value of this BigNumber rounded to + a whole number in the direction of Infinity. +

    +
    +x = new BigNumber(1.3)
    +x.ceil()                      // '2'
    +y = new BigNumber(-1.8)
    +y.ceil()                      // '-1'
    + + + +
    + floor.floor() ⇒ + BigNumber +
    +

    + Returns a BigNumber whose value is the value of this BigNumber rounded to + a whole number in the direction of -Infinity. +

    +
    +x = new BigNumber(1.8)
    +x.floor()                     // '1'
    +y = new BigNumber(-1.3)
    +y.floor()                     // '-2'
    + + + +
    + negated.neg() ⇒ BigNumber +
    +

    + Returns a BigNumber whose value is the value of this BigNumber negated, + i.e. multiplied by -1. +

    +
    +x = new BigNumber(1.8)
    +x.negated()                   // '-1.8'
    +y = new BigNumber(-1.3)
    +y.neg()                       // '1.3'
    + + + +
    + squareRoot.sqrt() ⇒ BigNumber +
    +

    + Returns a BigNumber whose value is the square root of this BigNumber, + correctly rounded according to the current + DECIMAL_PLACES and + ROUNDING_MODE settings. +

    +
    +x = new BigNumber(16)
    +x.squareRoot()                // '4'
    +y = new BigNumber(3)
    +y.sqrt()                      // '1.73205080756887729353'
    + + + +
    + isFinite.isF() ⇒ boolean +
    +

    + Returns true if the value of this BigNumber is a finite + number, otherwise returns false.
    + The only possible non-finite values of a BigNumber are NaN, Infinity and + -Infinity. +

    +
    +x = new BigNumber(1)
    +x.isFinite()                  // true
    +y = new BigNumber(Infinity)
    +y.isF()                       // false
    +

    + Note: The native method isFinite() can be used if + n <= Number.MAX_VALUE. +

    + + + +
    + isNaN.isNaN() ⇒ boolean +
    +

    + Returns true if the value of this BigNumber is NaN, otherwise + returns false.
    +

    +
    +x = new BigNumber(NaN)
    +x.isNaN()                     // true
    +y = new BigNumber('Infinity')
    +y.isNaN()                     // false
    +

    + Note: The native method isNaN() can also be used. +

    + + + +
    + isNegative.isNeg() ⇒ boolean +
    +

    + Returns true if the value of this BigNumber is negative, + otherwise returns false.
    +

    +
    +x = new BigNumber(-0)
    +x.isNegative()                // true
    +y = new BigNumber(2)
    +y.isNeg                       // false
    +

    + Note: n < 0 can be used if + n <= -Number.MIN_VALUE. +

    + + + +
    + isZero.isZ() ⇒ boolean +
    +

    + Returns true if the value of this BigNumber is zero or minus + zero, otherwise returns false.
    +

    +
    +x = new BigNumber(-0)
    +x.isZero() && x.isNeg()        // true
    +y = new BigNumber(Infinity)
    +y.isZ()                        // false
    +

    + Note: n == 0 can be used if + n >= Number.MIN_VALUE. +

    + + + +
    + comparedTo.cmp(n [, base]) ⇒ number +
    +

    + n : number|string|BigNumber
    + base : number
    + + See constructor for further parameter details. + +

    + + + + + + + + + + + + + + + + + + + + + +
    Returns 
    1 + If the value of this BigNumber is greater than the value of n +
    -1 + If the value of this BigNumber is less than the value of n +
    0If this BigNumber and n have the same value
    null + if the value of either this BigNumber or n is + NaN +
    +
    +x = new BigNumber(Infinity)
    +y = new BigNumber(5)
    +x.comparedTo(y)                // 1
    +x.comparedTo(x.minus(1))       // 0
    +y.cmp(NaN)                     // null
    +y.cmp('110', 2)                // -1
    + + + +
    + dividedBy.div(n [, base]) ⇒ + BigNumber +
    +

    + n : number|string|BigNumber
    + base : number
    + See constructor for further parameter details. + +

    +

    + Returns a BigNumber whose value is the value of this BigNumber divided by + n, rounded according to the current + DECIMAL_PLACES and + ROUNDING_MODE settings. +

    +
    +x = new BigNumber(355)
    +y = new BigNumber(113)
    +x.dividedBy(y)             // '3.14159292035398230088'
    +x.div(5)                   // '71'
    +x.div(47, 16)              // '5'
    + + + +
    + minus.minus(n [, base]) ⇒ BigNumber +
    +

    + n : number|string|BigNumber
    + base : number
    + See constructor for further parameter details. + +

    +

    + Returns a BigNumber whose value is the value of this BigNumber minus + n. +

    +
    +0.3 - 0.1                  // 0.19999999999999998
    +x = new BigNumber(0.3)
    +x.minus(0.1)               // '0.2'
    +x.minus(0.6, 20)           // '0'
    + + + +
    + modulo.mod(n [, base]) ⇒ BigNumber +
    +

    + n : number|string|BigNumber
    + base : number
    + See constructor for further parameter details. + +

    +

    + Returns a BigNumber whose value is the value of this BigNumber modulo + n, i.e. the integer remainder of dividing this BigNumber by + n. +

    +

    + The result will have the same sign as this BigNumber, and it will match + that of JavaScript's % operator (within the limits of its precision) and + BigDecimal's remainder method. +

    +
    +1 % 0.9                    // 0.09999999999999998
    +x = new BigNumber(1)
    +x.modulo(0.9)              // '0.1'
    +y = new BigNumber(33)
    +y.mod('a', 33)             // '3'
    + + + +
    + plus.plus(n [, base]) ⇒ BigNumber +
    +

    + n : number|string|BigNumber
    + base : number
    + See constructor for further parameter details. + +

    +

    + Returns a BigNumber whose value is the value of this BigNumber plus + n. +

    +
    +0.1 + 0.2                       // 0.30000000000000004
    +x = new BigNumber(0.1)
    +y = x.plus(0.2)                 // '0.3'
    +BigNumber(0.7).plus(x).plus(y)  // '1'
    +x.plus('0.1', 8)                // '0.225'
    + + + +
    + times.times(n [, base]) ⇒ BigNumber +
    +

    + n : number|string|BigNumber
    + base : number
    + See constructor for further parameter details. + +

    +

    + Returns a BigNumber whose value is the value of this BigNumber times + n. +

    +
    +0.6 * 3                         // 1.7999999999999998
    +x = new BigNumber(0.6)
    +y = x.times(3)                  // '1.8'
    +BigNumber('7e+500').times(y)    // '1.26e+501'
    +x.times('-a', 16)               // '-6'
    + + + +
    + toPower.pow(exp) ⇒ BigNumber +
    +

    + exp : number : integer, -1e+6 to 1e+6 inclusive +

    +

    + Returns a BigNumber whose value is the value of this BigNumber raised to + the power exp. +

    +

    + If exp is negative the result is rounded according to the + current DECIMAL_PLACES and + ROUNDING_MODE settings. +

    +

    + If exp is not an integer or is out of range: +

    +

    + If ERRORS is true a BigNumber + Error is thrown,
    + else if exp is greater than 1e+6, it is interpreted as + Infinity;
    + else if exp is less than -1e+6, it is interpreted as + -Infinity;
    + else if exp is otherwise a number, it is truncated to an + integer;
    + else it is interpreted as NaN. +

    +

    + Note: High value exponents may cause this method to be slow to return. +

    +
    +Math.pow(0.7, 2)             // 0.48999999999999994
    +x = new BigNumber(0.7)
    +x.toPower(2)                 // '0.49'
    +BigNumber(3).pow(-2)         // '0.11111111111111111111'
    +
    +new BigNumber(123.456).toPower(1000).toString().length     // 5099
    +new BigNumber(2).pow(1e+6)   // Time taken (Node.js): 9 minutes 34 secs.
    + + + +
    + equals.eq(n [, base]) ⇒ boolean +
    +

    + n : number|string|BigNumber
    + base : number
    + See constructor for further parameter details. + +

    +

    + Returns true if the value of this BigNumber equals the value + of n, otherwise returns false.
    + As with JavaScript, NaN does not equal NaN. +
    Note : This method uses the comparedTo method + internally. +

    +
    +0 === 1e-324                    // true
    +x = new BigNumber(0)
    +x.equals('1e-324')              // false
    +BigNumber(-0).eq(x)             // true  ( -0 === 0 )
    +BigNumber(255).eq('ff', 16)     // true
    +
    +y = new BigNumber(NaN)
    +y.equals(NaN)                   // false
    + + + +
    + greaterThan.gt(n [, base]) ⇒ + boolean +
    +

    + n : number|string|BigNumber
    + base : number
    + See constructor for further parameter details. + +

    +

    + Returns true if the value of this BigNumber is greater than + the value of n, otherwise returns false.
    + Note : This method uses the comparedTo method internally. +

    +
    +0.1 > (0.3 - 0.2)                           // true
    +x = new BigNumber(0.1)
    +x.greaterThan(BigNumber(0.3).minus(0.2))    // false
    +BigNumber(0).gt(x)                          // false
    +BigNumber(11, 3).gt(11.1, 2)                // true
    + + + +
    + greaterThanOrEqualTo.gte(n [, base]) ⇒ + boolean +
    +

    + n : number|string|BigNumber
    + base : number
    + See constructor for further parameter details. + +

    +

    + Returns true if the value of this BigNumber is greater than + or equal to the value of n, otherwise returns + false.
    + Note : This method uses the comparedTo method internally. +

    +
    +(0.3 - 0.2) >= 0.1                   // false
    +x = new BigNumber(0.3).minus(0.2)
    +x.greaterThanOrEqualTo(0.1)          // true
    +BigNumber(1).gte(x)                  // true
    +BigNumber(10, 18).gte('i', 36)       // true
    + + + +
    + lessThan.lt(n [, base]) ⇒ boolean +
    +

    + n : number|string|BigNumber
    + base : number
    + See constructor for further parameter details. + +

    +

    + Returns true if the value of this BigNumber is less than the + value of n, otherwise returns false.
    + Note : This method uses the comparedTo method internally. +

    +
    +(0.3 - 0.2) < 0.1                    // true
    +x = new BigNumber(0.3).minus(0.2)
    +x.lessThan(0.1)                      // false
    +BigNumber(0).lt(x)                   // true
    +BigNumber(11.1, 2).lt(11, 3)         // true
    + + + +
    + lessThanOrEqualTo.lte(n [, base]) ⇒ + boolean +
    +

    + n : number|string|BigNumber
    + base : number
    + See constructor for further parameter details. + +

    +

    + Returns true if the value of this BigNumber is less than or + equal to the value of n, otherwise returns + false.
    + Note : This method uses the comparedTo method internally. +

    +
    +0.1 <= (0.3 - 0.2)                                // false
    +x = new BigNumber(0.1)
    +x.lessThanOrEqualTo(BigNumber(0.3).minus(0.2))    // true
    +BigNumber(-1).lte(x)                              // true
    +BigNumber(10, 18).lte('i', 36)                    // true
    + + + +
    + toExponential.toE([decimal_places]) ⇒ + string +
    +

    + decimal_places : number : integer, 0 to 1e+9 inclusive +

    +

    + Returns a string representing the value of this BigNumber in exponential + notation to the specified decimal places, i.e with one digit before the + decimal point and decimal_places digits after it. If rounding + is necessary, the current + ROUNDING_MODE is used. +

    +

    + If the value of this BigNumber in exponential notation has fewer fraction + digits then is specified by decimal_places, the return value + will be appended with zeros accordingly. +

    +

    + If decimal_places is omitted, or is null or + undefined, the number of digits after the decimal point defaults to the + minimum number of digits necessary to represent the value exactly. +

    +

    + See Errors for the treatment of other + non-integer or out of range decimal_places values. +

    +
    +x = 45.6
    +y = new BigNumber(x)
    +x.toExponential()         // '4.56e+1'
    +y.toExponential()         // '4.56e+1'
    +x.toExponential(0)        // '5e+1'
    +y.toE(0)                  // '5e+1'
    +x.toExponential(1)        // '4.6e+1'
    +y.toE(1)                  // '4.6e+1'
    +x.toExponential(3)        // '4.560e+1'
    +y.toE(3)                  // '4.560e+1'
    + + + +
    + toFixed.toF([decimal_places]) ⇒ + string +
    +

    + decimal_places : number : integer, 0 to 1e+9 inclusive +

    +

    + Returns a string representing the value of this BigNumber in normal + notation to the specified fixed number of decimal places, i.e. with + decimal_places digits after the decimal point. If rounding is + necessary, the current + ROUNDING_MODE setting is used. +

    +

    + If the value of this BigNumber in normal notation has fewer fraction + digits then is specified by decimal_places, the return value + will be appended with zeros accordingly. +

    +

    + Unlike Number.prototype.toFixed, which returns + exponential notation if a number is greater or equal to 1021, + this method will always return normal notation. +

    +

    + If decimal_places is omitted, or is null or + undefined, then the return value is the same as n.toString(). + This is also unlike Number.prototype.toFixed, which returns + the value to zero decimal places. +

    +

    + See Errors for the treatment of other + non-integer or out of range decimal_places values. +

    +
    +x = 45.6
    +y = new BigNumber(x)
    +x.toFixed()              // '46'
    +y.toFixed()              // '45.6'
    +y.toF(0)                 // '46'
    +x.toFixed(3)             // '45.600'
    +y.toF(3)                 // '45.600'
    + + + +
    toNumber.toN() ⇒ number
    +

    Returns the value of this BigNumber as a number primitive.

    +

    + Type coercion with, for example, JavaScript's unary plus operator can alternatively be used, + but then a BigNumber with the value minus zero will convert to positive zero. +

    +
    +x = new BigNumber(456.789)
    +x.toNumber()                   // 456.789
    ++x                             // 456.789
    +
    +y = new BigNumber('45987349857634085409857349856430985')
    +y.toNumber()                   // 4.598734985763409e+34
    +
    +z = new BigNumber(-0)
    +1 / +z                         // Infinity
    +1 / z.toNumber()               // -Infinity
    + + + +
    + toPrecision.toP([significant_figures]) ⇒ + string +
    +

    + significant_figures : number : integer, 1 to 1e+9 + inclusive +

    +

    + Returns a string representing the value of this BigNumber to the + specified number of significant digits. If rounding is necessary, the + current ROUNDING_MODE setting is + used. +

    +

    + If significant_figures is less than the number of digits + necessary to represent the integer part of the value in normal notation, + then exponential notation is used. +

    +

    + If significant_figures is omitted, or is null or + undefined, then the return value is the same as n.toString(). +

    +

    + See Errors for the treatment of other + non-integer or out of range significant_figures values. +

    +
    +x = 45.6
    +y = new BigNumber(x)
    +x.toPrecision()           // '45.6'
    +y.toPrecision()           // '45.6'
    +x.toPrecision(1)          // '5e+1'
    +y.toP(1)                  // '5e+1'
    +x.toPrecision(5)          // '45.600'
    +y.toP(5)                  // '45.600'
    + + + +
    + toString.toS([base]) ⇒ string +
    +

    + base : number : integer, 2 to 64 inclusive +

    +

    + Returns a string representing the value of this BigNumber in the specified + base, or base 10 if base is omitted. For bases above 10, + values from 10 to 35 are represented by a-z (as with + Number.toString), 36 to 61 by A-Z, and 62 and 63 + by $ and _ respectively. +

    +

    + If a base is specified the value is rounded according to the current + DECIMAL_PLACES + and ROUNDING_MODE settings. +

    +

    + If a base is not specified, and this BigNumber has a positive + exponent that is equal to or greater than the positive component of the + current EXPONENTIAL_AT setting, + or a negative exponent equal to or less than the negative component of the + setting, then exponential notation is returned. +

    +

    + If base is null or undefined it is ignored. +
    + See Errors for the treatment of other non-integer or + out of range base values. +

    +
    +x = new BigNumber(750000)
    +x.toString()                    // '750000'
    +BigNumber.config({ EXPONENTIAL_AT : 5 })
    +x.toString()                    // '7.5e+5'
    +
    +y = new BigNumber(362.875)
    +y.toString(2)                   // '101101010.111'
    +y.toString(9)                   // '442.77777777777777777778'
    +y.toString(32)                  // 'ba.s'
    +
    +BigNumber.config({ DECIMAL_PLACES : 4 });
    +z = new BigNumber('1.23456789')
    +z.toString()                    // '1.23456789'
    +z.toString(10)                  // '1.2346'
    + + + +
    + valueOf.valueOf() ⇒ string +
    +

    + As toString, but does not accept a base argument. +

    +
    +x = new BigNumber('1.777e+457')
    +x.valueOf()                      // '1.777e+457'
    + + + +
    + toFraction.toFr([max_denominator]) ⇒ + [string, string] +
    +

    + max_denominator : number|string|BigNumber : + integer >= 1 and < Infinity +

    +

    + Returns a string array representing the value of this BigNumber as a + simple fraction with an integer numerator and an integer denominator. The + denominator will be a positive non-zero value less than or equal to + max_denominator. +

    +

    + If a maximum denominator is not specified, or is null or + undefined, the denominator will be the lowest value necessary to represent + the number exactly. +

    +

    + See Errors for the treatment of other non-integer or + out of range max_denominator values. +

    +
    +x = new BigNumber(1.75)
    +x.toFraction()            // '7, 4'
    +
    +pi = new BigNumber('3.14159265358')
    +pi.toFr()                 // '157079632679,50000000000'
    +pi.toFr(100000)           // '312689, 99532'
    +pi.toFr(10000)            // '355, 113'
    +pi.toFr(100)              // '311, 99'
    +pi.toFr(10)               // '22, 7'
    +pi.toFr(1)                // '3, 1'
    + + + +
    + round.round([decimal_places [, rounding_mode]]) + ⇒ BigNumber +
    +

    + decimal_places : number : integer, 0 to 1e+9 inclusive +
    + rounding_mode : number : integer, 0 to 8 inclusive +

    +

    + Returns a BigNumber whose value is the value of this BigNumber rounded by + the specified rounding_mode to a maximum of + decimal_places digits after the decimal point. +

    +

    + if decimal_places is omitted, or is null or + undefined, the return value is n rounded to a whole number. +

    +

    + if rounding_mode is omitted, or is null or + undefined, the current + ROUNDING_MODE setting is used. +

    +

    + See Errors for the treatment of other + non-integer or out of range decimal_places or + rounding_mode values. +

    +
    +x = 1234.56
    +Math.round(x)                             // 1235
    +
    +y = new BigNumber(x)
    +y.round()                                 // '1235'
    +y.round(1)                                // '1234.6'
    +y.round(2)                                // '1234.56'
    +y.round(10)                               // '1234.56'
    +y.round(0, 1)                             // '1234'
    +y.round(0, 6)                             // '1235'
    +y.round(1, 1)                             // '1234.5'
    +y.round(1, BigNumber.ROUND_HALF_EVEN)     // '1234.6'
    +y                                         // '1234.56'
    + + + +

    Properties

    +

    + A BigNumber is an object with three properties: +

    + + + + + + + + + + + + + + + + + + + + + + + + + +
    PropertyDescriptionTypeValue
    ccoefficient*number[] Array of single digits
    eexponentnumberInteger, -1e+9 to 1e+9 inclusive
    ssignnumber-1 or 1
    +

    *significand

    +

    + The value of any of the three properties may also be null. +

    +

    + The value of a BigNumber is stored in a normalised decimal floating point + format which corresponds to the value's toExponential form, + with the decimal point to be positioned after the most significant + (left-most) digit of the coefficient. +

    +

    + Note that, as with JavaScript numbers, the original exponent and + fractional trailing zeros are not preserved. +

    +
    x = new BigNumber(0.123)              // '0.123'
    +x.toExponential()                     // '1.23e-1'
    +x.c                                   // '1,2,3'
    +x.e                                   // -1
    +x.s                                   // 1
    +
    +y = new Number(-123.4567000e+2)       // '-12345.67'
    +y.toExponential()                     // '-1.234567e+4'
    +z = new BigNumber('-123.4567000e+2')  // '-12345.67'
    +z.toExponential()                     // '-1.234567e+4'
    +z.c                                   // '1,2,3,4,5,6,7'
    +z.e                                   // 4
    +z.s                                   // -1
    + + +

    + A BigNumber is mutable in the sense that the value of its properties can + be changed.
    + For example, to rapidly shift a value by a power of 10: +

    +
    +x = new BigNumber('1234.000')      // '1234'
    +x.toExponential()                  // '1.234e+3'
    +x.c                                // '1,2,3,4'
    +x.e                                // 3
    +
    +x.e = -5
    +x                                  // '0.00001234'
    +

    + If changing the coefficient array directly, which is not recommended, be + careful to avoid leading or trailing zeros (unless zero itself is being + represented). +

    + + + +

    Zero, NaN and Infinity

    +

    + The table below shows how ±0, NaN and ±Infinity are stored. +

    + + + + + + + + + + + + + + + + + + + + + + + + + +
    ces
    ±0[0]0±1
    NaNnullnullnull
    ±Infinitynullnull±1
    +
    +x = new Number(-0)      // 0
    +1 / x == -Infinity     // true
    +
    +y = new BigNumber(-0)   // '0'
    +y.c                     // '0' ( [0].toString() )
    +y.e                     // 0
    +y.s                     // -1
    + + + +

    Errors

    +

    + The errors that are thrown are generic Error objects with + name BigNumber Error. The table below shows the errors + that may be thrown if ERRORS is true, and the + action taken if ERRORS is false. +

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    Method(s)ERRORS : true
    Throw BigNumber Error
    ERRORS : false
    Action on invalid argument
    + BigNumber
    + comparedTo
    + dividedBy
    + equals
    + greaterThan
    + greaterThanOrEqualTo
    + lessThan
    + lessThanOrEqualTo
    + minus
    + mod
    + plus
    + times
    number type has more than
    15 significant digits
    Accept.
    not a base... numberSubstitute NaN.
    base not an integerTruncate to integer.
    Ignore if not a number.
    base out of rangeIgnore.
    not a number*Substitute NaN.
    configDECIMAL_PLACES not an integerTruncate to integer.
    Ignore if not a number.
    DECIMAL_PLACES out of rangeIgnore.
    ROUNDING_MODE not an integerTruncate to integer.
    Ignore if not a number.
    ROUNDING_MODE out of rangeIgnore.
    + EXPONENTIAL_AT not an integer
    + or not [integer, integer] +
    Truncate to integer(s).
    Ignore if not number(s).
    + EXPONENTIAL_AT out of range
    + or not [negative, positive] +
    Ignore.
    + RANGE not a non-zero integer
    + or not [integer, integer] +
    Truncate to integer(s).
    Ignore if zero or not number(s).
    + RANGE out of range
    + or not [negative, positive] +
    Ignore.
    + ERRORS not a boolean
    + or binary digit +
    Ignore.
    toPowerexponent not an integerTruncate to integer.
    Substitute NaN if not a number.
    exponent out of rangeSubstitute ±Infinity. +
    rounddecimal places not an integerTruncate to integer.
    Ignore if not a number.
    decimal places out of rangeIgnore.
    mode not an integerTruncate to integer.
    Ignore if not a number.
    mode out of rangeIgnore.
    toExponentialdecimal places not an integerTruncate to integer.
    Ignore if not a number.
    decimal places out of rangeIgnore.
    toFixeddecimal places not an integerTruncate to integer.
    Ignore if not a number.
    decimal places out of rangeIgnore.
    toFractionmax denominator not an integerTruncate to integer.
    Ignore if not a number.
    max denominator out of rangeIgnore.
    toPrecisionprecision not an integerTruncate to integer.
    Ignore if not a number.
    precision out of rangeIgnore.
    toStringbase not an integerTruncate to integer.
    Ignore if not a number.
    base out of rangeIgnore.
    +

    + *No error is thrown if the value is NaN or 'NaN' +

    +

    + The message of a BigNumber Error will also contain the name of the + method from which the error originated. +

    +

    + To determine if an exception is a BigNumber Error: +

    +
    +try {
    +    // ...
    +} catch (e) {
    +    if ( e instanceof Error && e.name == 'BigNumber Error' ) {
    +        // ...
    +    }
    +}
    + +

    FAQ

    +
    Why are trailing fractional zeros removed from BigNumbers?
    +

    + Many arbitrary-precision libraries retain trailing fractional zeros as + they can indicate the precision of a value. This can be useful but the + results of arithmetic operations can be misleading. +

    +
    +x = new BigDecimal("1.0")
    +y = new BigDecimal("1.1000")
    +z = x.add(y)                      // 2.1000
    +
    +x = new BigDecimal("1.20")
    +y = new BigDecimal("3.45000")
    +z = x.multiply(y)                 // 4.1400000
    +

    + To specify the precision of a value is to specify that the value lies + within a certain range. +

    +

    + In the first example, x has a value of 1.0. The trailing zero + shows the precision of the value, implying that it is in the range 0.95 to + 1.05. Similarly, the precision indicated by the trailing zeros of + y indicates that the value is in the range 1.09995 to + 1.10005. If we add the two lowest values in the ranges we get 0.95 + + 1.09995 = 2.04995 and if we add the two highest values we get 1.05 + + 1.10005 = 2.15005, so the range of the result of the addition implied by + the precision of its operands is 2.04995 to 2.15005. The result given by + BigDecimal of 2.1000 however, indicates that the value is in the range + 2.09995 to 2.10005 and therefore the precision implied by its trailing + zeros is misleading. +

    +

    + In the second example, the true range is 4.122744 to 4.157256 yet the + BigDecimal answer of 4.1400000 indicates a range of 4.13999995 to + 4.14000005. Again, the precision implied by the trailing zeros is + misleading. +

    +

    + This library, like binary floating point and most calculators, does not + retain trailing fractional zeros. Instead, the toExponential, + toFixed and toPrecision methods enable trailing + zeros to be added if and when required. +

    +
    + +
    + + + diff --git a/node_modules/mysql/node_modules/bignumber.js/package.json b/node_modules/mysql/node_modules/bignumber.js/package.json new file mode 100644 index 0000000..228299c --- /dev/null +++ b/node_modules/mysql/node_modules/bignumber.js/package.json @@ -0,0 +1,60 @@ +{ + "name": "bignumber.js", + "description": "A library for arbitrary-precision decimal and non-decimal arithmetic", + "version": "1.4.1", + "keywords": [ + "arbitrary", + "precision", + "arithmetic", + "big", + "number", + "decimal", + "float", + "biginteger", + "bigdecimal", + "bignumber", + "bigint", + "bignum" + ], + "repository": { + "type": "git", + "url": "https://github.com/MikeMcl/bignumber.js.git" + }, + "main": "bignumber", + "author": { + "name": "Michael Mclaughlin", + "email": "M8ch88l@gmail.com" + }, + "engines": { + "node": "*" + }, + "license": "MIT", + "scripts": { + "test": "node ./test/every-test.js", + "build": "uglifyjs bignumber.js -c -m -o bignumber.min.js --preamble '/* bignumber.js v1.4.1 https://github.com/MikeMcl/bignumber.js/LICENCE */'" + }, + "bugs": { + "url": "https://github.com/MikeMcl/bignumber.js/issues" + }, + "homepage": "https://github.com/MikeMcl/bignumber.js", + "_id": "bignumber.js@1.4.1", + "dist": { + "shasum": "3d19ac321f8db4ba07aace23ebd4ac976fae6bfa", + "tarball": "http://registry.npmjs.org/bignumber.js/-/bignumber.js-1.4.1.tgz" + }, + "_from": "bignumber.js@1.4.1", + "_npmVersion": "1.4.6", + "_npmUser": { + "name": "mikemcl", + "email": "M8ch88l@gmail.com" + }, + "maintainers": [ + { + "name": "mikemcl", + "email": "M8ch88l@gmail.com" + } + ], + "directories": {}, + "_shasum": "3d19ac321f8db4ba07aace23ebd4ac976fae6bfa", + "_resolved": "https://registry.npmjs.org/bignumber.js/-/bignumber.js-1.4.1.tgz" +} diff --git a/node_modules/mysql/node_modules/readable-stream/.npmignore b/node_modules/mysql/node_modules/readable-stream/.npmignore new file mode 100644 index 0000000..38344f8 --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/.npmignore @@ -0,0 +1,5 @@ +build/ +test/ +examples/ +fs.js +zlib.js \ No newline at end of file diff --git a/node_modules/mysql/node_modules/readable-stream/LICENSE b/node_modules/mysql/node_modules/readable-stream/LICENSE new file mode 100644 index 0000000..e3d4e69 --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/LICENSE @@ -0,0 +1,18 @@ +Copyright Joyent, Inc. and other Node contributors. All rights reserved. +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to +deal in the Software without restriction, including without limitation the +rights to use, copy, modify, merge, publish, distribute, sublicense, and/or +sell copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The 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/node_modules/mysql/node_modules/readable-stream/README.md b/node_modules/mysql/node_modules/readable-stream/README.md new file mode 100644 index 0000000..e46b823 --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/README.md @@ -0,0 +1,15 @@ +# readable-stream + +***Node-core streams for userland*** + +[![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. + +**readable-stream** comes in two major versions, v1.0.x and v1.1.x. The former tracks the Streams2 implementation in Node 0.10, including bug-fixes and minor improvements as they are added. The latter tracks Streams3 as it develops in Node 0.11; we will likely see a v1.2.x branch for Node 0.12. + +**readable-stream** uses proper patch-level versioning so if you pin to `"~1.0.0"` you’ll get the latest Node 0.10 Streams2 implementation, including any fixes and minor non-breaking improvements. The patch-level versions of 1.0.x and 1.1.x should mirror the patch-level versions of Node-core releases. You should prefer the **1.0.x** releases for now and when you’re ready to start using Streams3, pin to `"~1.1.0"` + diff --git a/node_modules/mysql/node_modules/readable-stream/duplex.js b/node_modules/mysql/node_modules/readable-stream/duplex.js new file mode 100644 index 0000000..ca807af --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/duplex.js @@ -0,0 +1 @@ +module.exports = require("./lib/_stream_duplex.js") diff --git a/node_modules/mysql/node_modules/readable-stream/float.patch b/node_modules/mysql/node_modules/readable-stream/float.patch new file mode 100644 index 0000000..b984607 --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/float.patch @@ -0,0 +1,923 @@ +diff --git a/lib/_stream_duplex.js b/lib/_stream_duplex.js +index c5a741c..a2e0d8e 100644 +--- a/lib/_stream_duplex.js ++++ b/lib/_stream_duplex.js +@@ -26,8 +26,8 @@ + + module.exports = Duplex; + var util = require('util'); +-var Readable = require('_stream_readable'); +-var Writable = require('_stream_writable'); ++var Readable = require('./_stream_readable'); ++var Writable = require('./_stream_writable'); + + util.inherits(Duplex, Readable); + +diff --git a/lib/_stream_passthrough.js b/lib/_stream_passthrough.js +index a5e9864..330c247 100644 +--- a/lib/_stream_passthrough.js ++++ b/lib/_stream_passthrough.js +@@ -25,7 +25,7 @@ + + module.exports = PassThrough; + +-var Transform = require('_stream_transform'); ++var Transform = require('./_stream_transform'); + var util = require('util'); + util.inherits(PassThrough, Transform); + +diff --git a/lib/_stream_readable.js b/lib/_stream_readable.js +index 0c3fe3e..90a8298 100644 +--- a/lib/_stream_readable.js ++++ b/lib/_stream_readable.js +@@ -23,10 +23,34 @@ module.exports = Readable; + Readable.ReadableState = ReadableState; + + var EE = require('events').EventEmitter; ++if (!EE.listenerCount) EE.listenerCount = function(emitter, type) { ++ return emitter.listeners(type).length; ++}; ++ ++if (!global.setImmediate) global.setImmediate = function setImmediate(fn) { ++ return setTimeout(fn, 0); ++}; ++if (!global.clearImmediate) global.clearImmediate = function clearImmediate(i) { ++ return clearTimeout(i); ++}; ++ + var Stream = require('stream'); + var util = require('util'); ++if (!util.isUndefined) { ++ var utilIs = require('core-util-is'); ++ for (var f in utilIs) { ++ util[f] = utilIs[f]; ++ } ++} + var StringDecoder; +-var debug = util.debuglog('stream'); ++var debug; ++if (util.debuglog) ++ debug = util.debuglog('stream'); ++else try { ++ debug = require('debuglog')('stream'); ++} catch (er) { ++ debug = function() {}; ++} + + util.inherits(Readable, Stream); + +@@ -380,7 +404,7 @@ function chunkInvalid(state, chunk) { + + + function onEofChunk(stream, state) { +- if (state.decoder && !state.ended) { ++ if (state.decoder && !state.ended && state.decoder.end) { + var chunk = state.decoder.end(); + if (chunk && chunk.length) { + state.buffer.push(chunk); +diff --git a/lib/_stream_transform.js b/lib/_stream_transform.js +index b1f9fcc..b0caf57 100644 +--- a/lib/_stream_transform.js ++++ b/lib/_stream_transform.js +@@ -64,8 +64,14 @@ + + module.exports = Transform; + +-var Duplex = require('_stream_duplex'); ++var Duplex = require('./_stream_duplex'); + var util = require('util'); ++if (!util.isUndefined) { ++ var utilIs = require('core-util-is'); ++ for (var f in utilIs) { ++ util[f] = utilIs[f]; ++ } ++} + util.inherits(Transform, Duplex); + + +diff --git a/lib/_stream_writable.js b/lib/_stream_writable.js +index ba2e920..f49288b 100644 +--- a/lib/_stream_writable.js ++++ b/lib/_stream_writable.js +@@ -27,6 +27,12 @@ module.exports = Writable; + Writable.WritableState = WritableState; + + var util = require('util'); ++if (!util.isUndefined) { ++ var utilIs = require('core-util-is'); ++ for (var f in utilIs) { ++ util[f] = utilIs[f]; ++ } ++} + var Stream = require('stream'); + + util.inherits(Writable, Stream); +@@ -119,7 +125,7 @@ function WritableState(options, stream) { + function Writable(options) { + // Writable ctor is applied to Duplexes, though they're not + // instanceof Writable, they're instanceof Readable. +- if (!(this instanceof Writable) && !(this instanceof Stream.Duplex)) ++ if (!(this instanceof Writable) && !(this instanceof require('./_stream_duplex'))) + return new Writable(options); + + this._writableState = new WritableState(options, this); +diff --git a/test/simple/test-stream-big-push.js b/test/simple/test-stream-big-push.js +index e3787e4..8cd2127 100644 +--- a/test/simple/test-stream-big-push.js ++++ b/test/simple/test-stream-big-push.js +@@ -21,7 +21,7 @@ + + var common = require('../common'); + var assert = require('assert'); +-var stream = require('stream'); ++var stream = require('../../'); + var str = 'asdfasdfasdfasdfasdf'; + + var r = new stream.Readable({ +diff --git a/test/simple/test-stream-end-paused.js b/test/simple/test-stream-end-paused.js +index bb73777..d40efc7 100644 +--- a/test/simple/test-stream-end-paused.js ++++ b/test/simple/test-stream-end-paused.js +@@ -25,7 +25,7 @@ var gotEnd = false; + + // Make sure we don't miss the end event for paused 0-length streams + +-var Readable = require('stream').Readable; ++var Readable = require('../../').Readable; + var stream = new Readable(); + var calledRead = false; + stream._read = function() { +diff --git a/test/simple/test-stream-pipe-after-end.js b/test/simple/test-stream-pipe-after-end.js +index b46ee90..0be8366 100644 +--- a/test/simple/test-stream-pipe-after-end.js ++++ b/test/simple/test-stream-pipe-after-end.js +@@ -22,8 +22,8 @@ + var common = require('../common'); + var assert = require('assert'); + +-var Readable = require('_stream_readable'); +-var Writable = require('_stream_writable'); ++var Readable = require('../../lib/_stream_readable'); ++var Writable = require('../../lib/_stream_writable'); + var util = require('util'); + + util.inherits(TestReadable, Readable); +diff --git a/test/simple/test-stream-pipe-cleanup.js b/test/simple/test-stream-pipe-cleanup.js +deleted file mode 100644 +index f689358..0000000 +--- a/test/simple/test-stream-pipe-cleanup.js ++++ /dev/null +@@ -1,122 +0,0 @@ +-// Copyright Joyent, Inc. and other Node contributors. +-// +-// Permission is hereby granted, free of charge, to any person obtaining a +-// copy of this software and associated documentation files (the +-// "Software"), to deal in the Software without restriction, including +-// without limitation the rights to use, copy, modify, merge, publish, +-// distribute, sublicense, and/or sell copies of the Software, and to permit +-// persons to whom the Software is furnished to do so, subject to the +-// following conditions: +-// +-// The above copyright notice and this permission notice shall be included +-// in all copies or substantial portions of the Software. +-// +-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +-// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +-// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +-// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +-// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +-// USE OR OTHER DEALINGS IN THE SOFTWARE. +- +-// This test asserts that Stream.prototype.pipe does not leave listeners +-// hanging on the source or dest. +- +-var common = require('../common'); +-var stream = require('stream'); +-var assert = require('assert'); +-var util = require('util'); +- +-function Writable() { +- this.writable = true; +- this.endCalls = 0; +- stream.Stream.call(this); +-} +-util.inherits(Writable, stream.Stream); +-Writable.prototype.end = function() { +- this.endCalls++; +-}; +- +-Writable.prototype.destroy = function() { +- this.endCalls++; +-}; +- +-function Readable() { +- this.readable = true; +- stream.Stream.call(this); +-} +-util.inherits(Readable, stream.Stream); +- +-function Duplex() { +- this.readable = true; +- Writable.call(this); +-} +-util.inherits(Duplex, Writable); +- +-var i = 0; +-var limit = 100; +- +-var w = new Writable(); +- +-var r; +- +-for (i = 0; i < limit; i++) { +- r = new Readable(); +- r.pipe(w); +- r.emit('end'); +-} +-assert.equal(0, r.listeners('end').length); +-assert.equal(limit, w.endCalls); +- +-w.endCalls = 0; +- +-for (i = 0; i < limit; i++) { +- r = new Readable(); +- r.pipe(w); +- r.emit('close'); +-} +-assert.equal(0, r.listeners('close').length); +-assert.equal(limit, w.endCalls); +- +-w.endCalls = 0; +- +-r = new Readable(); +- +-for (i = 0; i < limit; i++) { +- w = new Writable(); +- r.pipe(w); +- w.emit('close'); +-} +-assert.equal(0, w.listeners('close').length); +- +-r = new Readable(); +-w = new Writable(); +-var d = new Duplex(); +-r.pipe(d); // pipeline A +-d.pipe(w); // pipeline B +-assert.equal(r.listeners('end').length, 2); // A.onend, A.cleanup +-assert.equal(r.listeners('close').length, 2); // A.onclose, A.cleanup +-assert.equal(d.listeners('end').length, 2); // B.onend, B.cleanup +-assert.equal(d.listeners('close').length, 3); // A.cleanup, B.onclose, B.cleanup +-assert.equal(w.listeners('end').length, 0); +-assert.equal(w.listeners('close').length, 1); // B.cleanup +- +-r.emit('end'); +-assert.equal(d.endCalls, 1); +-assert.equal(w.endCalls, 0); +-assert.equal(r.listeners('end').length, 0); +-assert.equal(r.listeners('close').length, 0); +-assert.equal(d.listeners('end').length, 2); // B.onend, B.cleanup +-assert.equal(d.listeners('close').length, 2); // B.onclose, B.cleanup +-assert.equal(w.listeners('end').length, 0); +-assert.equal(w.listeners('close').length, 1); // B.cleanup +- +-d.emit('end'); +-assert.equal(d.endCalls, 1); +-assert.equal(w.endCalls, 1); +-assert.equal(r.listeners('end').length, 0); +-assert.equal(r.listeners('close').length, 0); +-assert.equal(d.listeners('end').length, 0); +-assert.equal(d.listeners('close').length, 0); +-assert.equal(w.listeners('end').length, 0); +-assert.equal(w.listeners('close').length, 0); +diff --git a/test/simple/test-stream-pipe-error-handling.js b/test/simple/test-stream-pipe-error-handling.js +index c5d724b..c7d6b7d 100644 +--- a/test/simple/test-stream-pipe-error-handling.js ++++ b/test/simple/test-stream-pipe-error-handling.js +@@ -21,7 +21,7 @@ + + var common = require('../common'); + var assert = require('assert'); +-var Stream = require('stream').Stream; ++var Stream = require('../../').Stream; + + (function testErrorListenerCatches() { + var source = new Stream(); +diff --git a/test/simple/test-stream-pipe-event.js b/test/simple/test-stream-pipe-event.js +index cb9d5fe..56f8d61 100644 +--- a/test/simple/test-stream-pipe-event.js ++++ b/test/simple/test-stream-pipe-event.js +@@ -20,7 +20,7 @@ + // USE OR OTHER DEALINGS IN THE SOFTWARE. + + var common = require('../common'); +-var stream = require('stream'); ++var stream = require('../../'); + var assert = require('assert'); + var util = require('util'); + +diff --git a/test/simple/test-stream-push-order.js b/test/simple/test-stream-push-order.js +index f2e6ec2..a5c9bf9 100644 +--- a/test/simple/test-stream-push-order.js ++++ b/test/simple/test-stream-push-order.js +@@ -20,7 +20,7 @@ + // USE OR OTHER DEALINGS IN THE SOFTWARE. + + var common = require('../common.js'); +-var Readable = require('stream').Readable; ++var Readable = require('../../').Readable; + var assert = require('assert'); + + var s = new Readable({ +diff --git a/test/simple/test-stream-push-strings.js b/test/simple/test-stream-push-strings.js +index 06f43dc..1701a9a 100644 +--- a/test/simple/test-stream-push-strings.js ++++ b/test/simple/test-stream-push-strings.js +@@ -22,7 +22,7 @@ + var common = require('../common'); + var assert = require('assert'); + +-var Readable = require('stream').Readable; ++var Readable = require('../../').Readable; + var util = require('util'); + + util.inherits(MyStream, Readable); +diff --git a/test/simple/test-stream-readable-event.js b/test/simple/test-stream-readable-event.js +index ba6a577..a8e6f7b 100644 +--- a/test/simple/test-stream-readable-event.js ++++ b/test/simple/test-stream-readable-event.js +@@ -22,7 +22,7 @@ + var common = require('../common'); + var assert = require('assert'); + +-var Readable = require('stream').Readable; ++var Readable = require('../../').Readable; + + (function first() { + // First test, not reading when the readable is added. +diff --git a/test/simple/test-stream-readable-flow-recursion.js b/test/simple/test-stream-readable-flow-recursion.js +index 2891ad6..11689ba 100644 +--- a/test/simple/test-stream-readable-flow-recursion.js ++++ b/test/simple/test-stream-readable-flow-recursion.js +@@ -27,7 +27,7 @@ var assert = require('assert'); + // more data continuously, but without triggering a nextTick + // warning or RangeError. + +-var Readable = require('stream').Readable; ++var Readable = require('../../').Readable; + + // throw an error if we trigger a nextTick warning. + process.throwDeprecation = true; +diff --git a/test/simple/test-stream-unshift-empty-chunk.js b/test/simple/test-stream-unshift-empty-chunk.js +index 0c96476..7827538 100644 +--- a/test/simple/test-stream-unshift-empty-chunk.js ++++ b/test/simple/test-stream-unshift-empty-chunk.js +@@ -24,7 +24,7 @@ var assert = require('assert'); + + // This test verifies that stream.unshift(Buffer(0)) or + // stream.unshift('') does not set state.reading=false. +-var Readable = require('stream').Readable; ++var Readable = require('../../').Readable; + + var r = new Readable(); + var nChunks = 10; +diff --git a/test/simple/test-stream-unshift-read-race.js b/test/simple/test-stream-unshift-read-race.js +index 83fd9fa..17c18aa 100644 +--- a/test/simple/test-stream-unshift-read-race.js ++++ b/test/simple/test-stream-unshift-read-race.js +@@ -29,7 +29,7 @@ var assert = require('assert'); + // 3. push() after the EOF signaling null is an error. + // 4. _read() is not called after pushing the EOF null chunk. + +-var stream = require('stream'); ++var stream = require('../../'); + var hwm = 10; + var r = stream.Readable({ highWaterMark: hwm }); + var chunks = 10; +@@ -51,7 +51,14 @@ r._read = function(n) { + + function push(fast) { + assert(!pushedNull, 'push() after null push'); +- var c = pos >= data.length ? null : data.slice(pos, pos + n); ++ var c; ++ if (pos >= data.length) ++ c = null; ++ else { ++ if (n + pos > data.length) ++ n = data.length - pos; ++ c = data.slice(pos, pos + n); ++ } + pushedNull = c === null; + if (fast) { + pos += n; +diff --git a/test/simple/test-stream-writev.js b/test/simple/test-stream-writev.js +index 5b49e6e..b5321f3 100644 +--- a/test/simple/test-stream-writev.js ++++ b/test/simple/test-stream-writev.js +@@ -22,7 +22,7 @@ + var common = require('../common'); + var assert = require('assert'); + +-var stream = require('stream'); ++var stream = require('../../'); + + var queue = []; + for (var decode = 0; decode < 2; decode++) { +diff --git a/test/simple/test-stream2-basic.js b/test/simple/test-stream2-basic.js +index 3814bf0..248c1be 100644 +--- a/test/simple/test-stream2-basic.js ++++ b/test/simple/test-stream2-basic.js +@@ -21,7 +21,7 @@ + + + var common = require('../common.js'); +-var R = require('_stream_readable'); ++var R = require('../../lib/_stream_readable'); + var assert = require('assert'); + + var util = require('util'); +diff --git a/test/simple/test-stream2-compatibility.js b/test/simple/test-stream2-compatibility.js +index 6cdd4e9..f0fa84b 100644 +--- a/test/simple/test-stream2-compatibility.js ++++ b/test/simple/test-stream2-compatibility.js +@@ -21,7 +21,7 @@ + + + var common = require('../common.js'); +-var R = require('_stream_readable'); ++var R = require('../../lib/_stream_readable'); + var assert = require('assert'); + + var util = require('util'); +diff --git a/test/simple/test-stream2-finish-pipe.js b/test/simple/test-stream2-finish-pipe.js +index 39b274f..006a19b 100644 +--- a/test/simple/test-stream2-finish-pipe.js ++++ b/test/simple/test-stream2-finish-pipe.js +@@ -20,7 +20,7 @@ + // USE OR OTHER DEALINGS IN THE SOFTWARE. + + var common = require('../common.js'); +-var stream = require('stream'); ++var stream = require('../../'); + var Buffer = require('buffer').Buffer; + + var r = new stream.Readable(); +diff --git a/test/simple/test-stream2-fs.js b/test/simple/test-stream2-fs.js +deleted file mode 100644 +index e162406..0000000 +--- a/test/simple/test-stream2-fs.js ++++ /dev/null +@@ -1,72 +0,0 @@ +-// Copyright Joyent, Inc. and other Node contributors. +-// +-// Permission is hereby granted, free of charge, to any person obtaining a +-// copy of this software and associated documentation files (the +-// "Software"), to deal in the Software without restriction, including +-// without limitation the rights to use, copy, modify, merge, publish, +-// distribute, sublicense, and/or sell copies of the Software, and to permit +-// persons to whom the Software is furnished to do so, subject to the +-// following conditions: +-// +-// The above copyright notice and this permission notice shall be included +-// in all copies or substantial portions of the Software. +-// +-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +-// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +-// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +-// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +-// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +-// USE OR OTHER DEALINGS IN THE SOFTWARE. +- +- +-var common = require('../common.js'); +-var R = require('_stream_readable'); +-var assert = require('assert'); +- +-var fs = require('fs'); +-var FSReadable = fs.ReadStream; +- +-var path = require('path'); +-var file = path.resolve(common.fixturesDir, 'x1024.txt'); +- +-var size = fs.statSync(file).size; +- +-var expectLengths = [1024]; +- +-var util = require('util'); +-var Stream = require('stream'); +- +-util.inherits(TestWriter, Stream); +- +-function TestWriter() { +- Stream.apply(this); +- this.buffer = []; +- this.length = 0; +-} +- +-TestWriter.prototype.write = function(c) { +- this.buffer.push(c.toString()); +- this.length += c.length; +- return true; +-}; +- +-TestWriter.prototype.end = function(c) { +- if (c) this.buffer.push(c.toString()); +- this.emit('results', this.buffer); +-} +- +-var r = new FSReadable(file); +-var w = new TestWriter(); +- +-w.on('results', function(res) { +- console.error(res, w.length); +- assert.equal(w.length, size); +- var l = 0; +- assert.deepEqual(res.map(function (c) { +- return c.length; +- }), expectLengths); +- console.log('ok'); +-}); +- +-r.pipe(w); +diff --git a/test/simple/test-stream2-httpclient-response-end.js b/test/simple/test-stream2-httpclient-response-end.js +deleted file mode 100644 +index 15cffc2..0000000 +--- a/test/simple/test-stream2-httpclient-response-end.js ++++ /dev/null +@@ -1,52 +0,0 @@ +-// Copyright Joyent, Inc. and other Node contributors. +-// +-// Permission is hereby granted, free of charge, to any person obtaining a +-// copy of this software and associated documentation files (the +-// "Software"), to deal in the Software without restriction, including +-// without limitation the rights to use, copy, modify, merge, publish, +-// distribute, sublicense, and/or sell copies of the Software, and to permit +-// persons to whom the Software is furnished to do so, subject to the +-// following conditions: +-// +-// The above copyright notice and this permission notice shall be included +-// in all copies or substantial portions of the Software. +-// +-// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +-// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +-// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +-// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +-// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +-// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +-// USE OR OTHER DEALINGS IN THE SOFTWARE. +- +-var common = require('../common.js'); +-var assert = require('assert'); +-var http = require('http'); +-var msg = 'Hello'; +-var readable_event = false; +-var end_event = false; +-var server = http.createServer(function(req, res) { +- res.writeHead(200, {'Content-Type': 'text/plain'}); +- res.end(msg); +-}).listen(common.PORT, function() { +- http.get({port: common.PORT}, function(res) { +- var data = ''; +- res.on('readable', function() { +- console.log('readable event'); +- readable_event = true; +- data += res.read(); +- }); +- res.on('end', function() { +- console.log('end event'); +- end_event = true; +- assert.strictEqual(msg, data); +- server.close(); +- }); +- }); +-}); +- +-process.on('exit', function() { +- assert(readable_event); +- assert(end_event); +-}); +- +diff --git a/test/simple/test-stream2-large-read-stall.js b/test/simple/test-stream2-large-read-stall.js +index 2fbfbca..667985b 100644 +--- a/test/simple/test-stream2-large-read-stall.js ++++ b/test/simple/test-stream2-large-read-stall.js +@@ -30,7 +30,7 @@ var PUSHSIZE = 20; + var PUSHCOUNT = 1000; + var HWM = 50; + +-var Readable = require('stream').Readable; ++var Readable = require('../../').Readable; + var r = new Readable({ + highWaterMark: HWM + }); +@@ -39,23 +39,23 @@ var rs = r._readableState; + r._read = push; + + r.on('readable', function() { +- console.error('>> readable'); ++ //console.error('>> readable'); + do { +- console.error(' > read(%d)', READSIZE); ++ //console.error(' > read(%d)', READSIZE); + var ret = r.read(READSIZE); +- console.error(' < %j (%d remain)', ret && ret.length, rs.length); ++ //console.error(' < %j (%d remain)', ret && ret.length, rs.length); + } while (ret && ret.length === READSIZE); + +- console.error('<< after read()', +- ret && ret.length, +- rs.needReadable, +- rs.length); ++ //console.error('<< after read()', ++ // ret && ret.length, ++ // rs.needReadable, ++ // rs.length); + }); + + var endEmitted = false; + r.on('end', function() { + endEmitted = true; +- console.error('end'); ++ //console.error('end'); + }); + + var pushes = 0; +@@ -64,11 +64,11 @@ function push() { + return; + + if (pushes++ === PUSHCOUNT) { +- console.error(' push(EOF)'); ++ //console.error(' push(EOF)'); + return r.push(null); + } + +- console.error(' push #%d', pushes); ++ //console.error(' push #%d', pushes); + if (r.push(new Buffer(PUSHSIZE))) + setTimeout(push); + } +diff --git a/test/simple/test-stream2-objects.js b/test/simple/test-stream2-objects.js +index 3e6931d..ff47d89 100644 +--- a/test/simple/test-stream2-objects.js ++++ b/test/simple/test-stream2-objects.js +@@ -21,8 +21,8 @@ + + + var common = require('../common.js'); +-var Readable = require('_stream_readable'); +-var Writable = require('_stream_writable'); ++var Readable = require('../../lib/_stream_readable'); ++var Writable = require('../../lib/_stream_writable'); + var assert = require('assert'); + + // tiny node-tap lookalike. +diff --git a/test/simple/test-stream2-pipe-error-handling.js b/test/simple/test-stream2-pipe-error-handling.js +index cf7531c..e3f3e4e 100644 +--- a/test/simple/test-stream2-pipe-error-handling.js ++++ b/test/simple/test-stream2-pipe-error-handling.js +@@ -21,7 +21,7 @@ + + var common = require('../common'); + var assert = require('assert'); +-var stream = require('stream'); ++var stream = require('../../'); + + (function testErrorListenerCatches() { + var count = 1000; +diff --git a/test/simple/test-stream2-pipe-error-once-listener.js b/test/simple/test-stream2-pipe-error-once-listener.js +index 5e8e3cb..53b2616 100755 +--- a/test/simple/test-stream2-pipe-error-once-listener.js ++++ b/test/simple/test-stream2-pipe-error-once-listener.js +@@ -24,7 +24,7 @@ var common = require('../common.js'); + var assert = require('assert'); + + var util = require('util'); +-var stream = require('stream'); ++var stream = require('../../'); + + + var Read = function() { +diff --git a/test/simple/test-stream2-push.js b/test/simple/test-stream2-push.js +index b63edc3..eb2b0e9 100644 +--- a/test/simple/test-stream2-push.js ++++ b/test/simple/test-stream2-push.js +@@ -20,7 +20,7 @@ + // USE OR OTHER DEALINGS IN THE SOFTWARE. + + var common = require('../common.js'); +-var stream = require('stream'); ++var stream = require('../../'); + var Readable = stream.Readable; + var Writable = stream.Writable; + var assert = require('assert'); +diff --git a/test/simple/test-stream2-read-sync-stack.js b/test/simple/test-stream2-read-sync-stack.js +index e8a7305..9740a47 100644 +--- a/test/simple/test-stream2-read-sync-stack.js ++++ b/test/simple/test-stream2-read-sync-stack.js +@@ -21,7 +21,7 @@ + + var common = require('../common'); + var assert = require('assert'); +-var Readable = require('stream').Readable; ++var Readable = require('../../').Readable; + var r = new Readable(); + var N = 256 * 1024; + +diff --git a/test/simple/test-stream2-readable-empty-buffer-no-eof.js b/test/simple/test-stream2-readable-empty-buffer-no-eof.js +index cd30178..4b1659d 100644 +--- a/test/simple/test-stream2-readable-empty-buffer-no-eof.js ++++ b/test/simple/test-stream2-readable-empty-buffer-no-eof.js +@@ -22,10 +22,9 @@ + var common = require('../common'); + var assert = require('assert'); + +-var Readable = require('stream').Readable; ++var Readable = require('../../').Readable; + + test1(); +-test2(); + + function test1() { + var r = new Readable(); +@@ -88,31 +87,3 @@ function test1() { + console.log('ok'); + }); + } +- +-function test2() { +- var r = new Readable({ encoding: 'base64' }); +- var reads = 5; +- r._read = function(n) { +- if (!reads--) +- return r.push(null); // EOF +- else +- return r.push(new Buffer('x')); +- }; +- +- var results = []; +- function flow() { +- var chunk; +- while (null !== (chunk = r.read())) +- results.push(chunk + ''); +- } +- r.on('readable', flow); +- r.on('end', function() { +- results.push('EOF'); +- }); +- flow(); +- +- process.on('exit', function() { +- assert.deepEqual(results, [ 'eHh4', 'eHg=', 'EOF' ]); +- console.log('ok'); +- }); +-} +diff --git a/test/simple/test-stream2-readable-from-list.js b/test/simple/test-stream2-readable-from-list.js +index 7c96ffe..04a96f5 100644 +--- a/test/simple/test-stream2-readable-from-list.js ++++ b/test/simple/test-stream2-readable-from-list.js +@@ -21,7 +21,7 @@ + + var assert = require('assert'); + var common = require('../common.js'); +-var fromList = require('_stream_readable')._fromList; ++var fromList = require('../../lib/_stream_readable')._fromList; + + // tiny node-tap lookalike. + var tests = []; +diff --git a/test/simple/test-stream2-readable-legacy-drain.js b/test/simple/test-stream2-readable-legacy-drain.js +index 675da8e..51fd3d5 100644 +--- a/test/simple/test-stream2-readable-legacy-drain.js ++++ b/test/simple/test-stream2-readable-legacy-drain.js +@@ -22,7 +22,7 @@ + var common = require('../common'); + var assert = require('assert'); + +-var Stream = require('stream'); ++var Stream = require('../../'); + var Readable = Stream.Readable; + + var r = new Readable(); +diff --git a/test/simple/test-stream2-readable-non-empty-end.js b/test/simple/test-stream2-readable-non-empty-end.js +index 7314ae7..c971898 100644 +--- a/test/simple/test-stream2-readable-non-empty-end.js ++++ b/test/simple/test-stream2-readable-non-empty-end.js +@@ -21,7 +21,7 @@ + + var assert = require('assert'); + var common = require('../common.js'); +-var Readable = require('_stream_readable'); ++var Readable = require('../../lib/_stream_readable'); + + var len = 0; + var chunks = new Array(10); +diff --git a/test/simple/test-stream2-readable-wrap-empty.js b/test/simple/test-stream2-readable-wrap-empty.js +index 2e5cf25..fd8a3dc 100644 +--- a/test/simple/test-stream2-readable-wrap-empty.js ++++ b/test/simple/test-stream2-readable-wrap-empty.js +@@ -22,7 +22,7 @@ + var common = require('../common'); + var assert = require('assert'); + +-var Readable = require('_stream_readable'); ++var Readable = require('../../lib/_stream_readable'); + var EE = require('events').EventEmitter; + + var oldStream = new EE(); +diff --git a/test/simple/test-stream2-readable-wrap.js b/test/simple/test-stream2-readable-wrap.js +index 90eea01..6b177f7 100644 +--- a/test/simple/test-stream2-readable-wrap.js ++++ b/test/simple/test-stream2-readable-wrap.js +@@ -22,8 +22,8 @@ + var common = require('../common'); + var assert = require('assert'); + +-var Readable = require('_stream_readable'); +-var Writable = require('_stream_writable'); ++var Readable = require('../../lib/_stream_readable'); ++var Writable = require('../../lib/_stream_writable'); + var EE = require('events').EventEmitter; + + var testRuns = 0, completedRuns = 0; +diff --git a/test/simple/test-stream2-set-encoding.js b/test/simple/test-stream2-set-encoding.js +index 5d2c32a..685531b 100644 +--- a/test/simple/test-stream2-set-encoding.js ++++ b/test/simple/test-stream2-set-encoding.js +@@ -22,7 +22,7 @@ + + var common = require('../common.js'); + var assert = require('assert'); +-var R = require('_stream_readable'); ++var R = require('../../lib/_stream_readable'); + var util = require('util'); + + // tiny node-tap lookalike. +diff --git a/test/simple/test-stream2-transform.js b/test/simple/test-stream2-transform.js +index 9c9ddd8..a0cacc6 100644 +--- a/test/simple/test-stream2-transform.js ++++ b/test/simple/test-stream2-transform.js +@@ -21,8 +21,8 @@ + + var assert = require('assert'); + var common = require('../common.js'); +-var PassThrough = require('_stream_passthrough'); +-var Transform = require('_stream_transform'); ++var PassThrough = require('../../').PassThrough; ++var Transform = require('../../').Transform; + + // tiny node-tap lookalike. + var tests = []; +diff --git a/test/simple/test-stream2-unpipe-drain.js b/test/simple/test-stream2-unpipe-drain.js +index d66dc3c..365b327 100644 +--- a/test/simple/test-stream2-unpipe-drain.js ++++ b/test/simple/test-stream2-unpipe-drain.js +@@ -22,7 +22,7 @@ + + var common = require('../common.js'); + var assert = require('assert'); +-var stream = require('stream'); ++var stream = require('../../'); + var crypto = require('crypto'); + + var util = require('util'); +diff --git a/test/simple/test-stream2-unpipe-leak.js b/test/simple/test-stream2-unpipe-leak.js +index 99f8746..17c92ae 100644 +--- a/test/simple/test-stream2-unpipe-leak.js ++++ b/test/simple/test-stream2-unpipe-leak.js +@@ -22,7 +22,7 @@ + + var common = require('../common.js'); + var assert = require('assert'); +-var stream = require('stream'); ++var stream = require('../../'); + + var chunk = new Buffer('hallo'); + +diff --git a/test/simple/test-stream2-writable.js b/test/simple/test-stream2-writable.js +index 704100c..209c3a6 100644 +--- a/test/simple/test-stream2-writable.js ++++ b/test/simple/test-stream2-writable.js +@@ -20,8 +20,8 @@ + // USE OR OTHER DEALINGS IN THE SOFTWARE. + + var common = require('../common.js'); +-var W = require('_stream_writable'); +-var D = require('_stream_duplex'); ++var W = require('../../').Writable; ++var D = require('../../').Duplex; + var assert = require('assert'); + + var util = require('util'); +diff --git a/test/simple/test-stream3-pause-then-read.js b/test/simple/test-stream3-pause-then-read.js +index b91bde3..2f72c15 100644 +--- a/test/simple/test-stream3-pause-then-read.js ++++ b/test/simple/test-stream3-pause-then-read.js +@@ -22,7 +22,7 @@ + var common = require('../common'); + var assert = require('assert'); + +-var stream = require('stream'); ++var stream = require('../../'); + var Readable = stream.Readable; + var Writable = stream.Writable; + diff --git a/node_modules/mysql/node_modules/readable-stream/lib/_stream_duplex.js b/node_modules/mysql/node_modules/readable-stream/lib/_stream_duplex.js new file mode 100644 index 0000000..b513d61 --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/lib/_stream_duplex.js @@ -0,0 +1,89 @@ +// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. + +// a duplex stream is just a stream that is both readable and writable. +// Since JS doesn't have multiple prototypal inheritance, this class +// prototypally inherits from Readable, and then parasitically from +// Writable. + +module.exports = Duplex; + +/**/ +var objectKeys = Object.keys || function (obj) { + var keys = []; + for (var key in obj) keys.push(key); + return keys; +} +/**/ + + +/**/ +var util = require('core-util-is'); +util.inherits = require('inherits'); +/**/ + +var Readable = require('./_stream_readable'); +var Writable = require('./_stream_writable'); + +util.inherits(Duplex, Readable); + +forEach(objectKeys(Writable.prototype), function(method) { + if (!Duplex.prototype[method]) + Duplex.prototype[method] = Writable.prototype[method]; +}); + +function Duplex(options) { + if (!(this instanceof Duplex)) + return new Duplex(options); + + Readable.call(this, options); + Writable.call(this, options); + + if (options && options.readable === false) + this.readable = false; + + if (options && options.writable === false) + this.writable = false; + + this.allowHalfOpen = true; + if (options && options.allowHalfOpen === false) + this.allowHalfOpen = false; + + this.once('end', onend); +} + +// the no-half-open enforcer +function onend() { + // if we allow half-open state, or if the writable side ended, + // then we're ok. + if (this.allowHalfOpen || this._writableState.ended) + return; + + // no more data can be written. + // But allow more writes to happen in this tick. + process.nextTick(this.end.bind(this)); +} + +function forEach (xs, f) { + for (var i = 0, l = xs.length; i < l; i++) { + f(xs[i], i); + } +} diff --git a/node_modules/mysql/node_modules/readable-stream/lib/_stream_passthrough.js b/node_modules/mysql/node_modules/readable-stream/lib/_stream_passthrough.js new file mode 100644 index 0000000..895ca50 --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/lib/_stream_passthrough.js @@ -0,0 +1,46 @@ +// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. + +// a passthrough stream. +// basically just the most minimal sort of Transform stream. +// Every written chunk gets output as-is. + +module.exports = PassThrough; + +var Transform = require('./_stream_transform'); + +/**/ +var util = require('core-util-is'); +util.inherits = require('inherits'); +/**/ + +util.inherits(PassThrough, Transform); + +function PassThrough(options) { + if (!(this instanceof PassThrough)) + return new PassThrough(options); + + Transform.call(this, options); +} + +PassThrough.prototype._transform = function(chunk, encoding, cb) { + cb(null, chunk); +}; diff --git a/node_modules/mysql/node_modules/readable-stream/lib/_stream_readable.js b/node_modules/mysql/node_modules/readable-stream/lib/_stream_readable.js new file mode 100644 index 0000000..19ab358 --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/lib/_stream_readable.js @@ -0,0 +1,951 @@ +// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. + +module.exports = Readable; + +/**/ +var isArray = require('isarray'); +/**/ + + +/**/ +var Buffer = require('buffer').Buffer; +/**/ + +Readable.ReadableState = ReadableState; + +var EE = require('events').EventEmitter; + +/**/ +if (!EE.listenerCount) EE.listenerCount = function(emitter, type) { + return emitter.listeners(type).length; +}; +/**/ + +var Stream = require('stream'); + +/**/ +var util = require('core-util-is'); +util.inherits = require('inherits'); +/**/ + +var StringDecoder; + + +/**/ +var debug = require('util'); +if (debug && debug.debuglog) { + debug = debug.debuglog('stream'); +} else { + debug = function () {}; +} +/**/ + + +util.inherits(Readable, Stream); + +function ReadableState(options, stream) { + var Duplex = require('./_stream_duplex'); + + options = options || {}; + + // the point at which it stops calling _read() to fill the buffer + // Note: 0 is a valid value, means "don't call _read preemptively ever" + var hwm = options.highWaterMark; + var defaultHwm = options.objectMode ? 16 : 16 * 1024; + this.highWaterMark = (hwm || hwm === 0) ? hwm : defaultHwm; + + // cast to ints. + this.highWaterMark = ~~this.highWaterMark; + + this.buffer = []; + this.length = 0; + this.pipes = null; + this.pipesCount = 0; + this.flowing = null; + this.ended = false; + this.endEmitted = false; + this.reading = 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, because any + // actions that shouldn't happen until "later" should generally also + // not happen before the first write call. + this.sync = true; + + // whenever we return null, then we set a flag to say + // that we're awaiting a 'readable' event emission. + this.needReadable = false; + this.emittedReadable = false; + this.readableListening = false; + + + // object stream flag. Used to make read(n) ignore n and to + // make all the buffer merging and length checks go away + this.objectMode = !!options.objectMode; + + if (stream instanceof Duplex) + this.objectMode = this.objectMode || !!options.readableObjectMode; + + // Crypto is kind of old and crusty. Historically, its default string + // encoding is 'binary' so we have to make this configurable. + // Everything else in the universe uses 'utf8', though. + this.defaultEncoding = options.defaultEncoding || 'utf8'; + + // when piping, we only care about 'readable' events that happen + // after read()ing all the bytes and not getting any pushback. + this.ranOut = false; + + // the number of writers that are awaiting a drain event in .pipe()s + this.awaitDrain = 0; + + // if true, a maybeReadMore has been scheduled + this.readingMore = false; + + this.decoder = null; + this.encoding = null; + if (options.encoding) { + if (!StringDecoder) + StringDecoder = require('string_decoder/').StringDecoder; + this.decoder = new StringDecoder(options.encoding); + this.encoding = options.encoding; + } +} + +function Readable(options) { + var Duplex = require('./_stream_duplex'); + + if (!(this instanceof Readable)) + return new Readable(options); + + this._readableState = new ReadableState(options, this); + + // legacy + this.readable = true; + + Stream.call(this); +} + +// Manually shove something into the read() buffer. +// This returns true if the highWaterMark has not been hit yet, +// similar to how Writable.write() returns true if you should +// write() some more. +Readable.prototype.push = function(chunk, encoding) { + var state = this._readableState; + + if (util.isString(chunk) && !state.objectMode) { + encoding = encoding || state.defaultEncoding; + if (encoding !== state.encoding) { + chunk = new Buffer(chunk, encoding); + encoding = ''; + } + } + + return readableAddChunk(this, state, chunk, encoding, false); +}; + +// Unshift should *always* be something directly out of read() +Readable.prototype.unshift = function(chunk) { + var state = this._readableState; + return readableAddChunk(this, state, chunk, '', true); +}; + +function readableAddChunk(stream, state, chunk, encoding, addToFront) { + var er = chunkInvalid(state, chunk); + if (er) { + stream.emit('error', er); + } else if (util.isNullOrUndefined(chunk)) { + state.reading = false; + if (!state.ended) + onEofChunk(stream, state); + } else if (state.objectMode || chunk && chunk.length > 0) { + if (state.ended && !addToFront) { + var e = new Error('stream.push() after EOF'); + stream.emit('error', e); + } else if (state.endEmitted && addToFront) { + var e = new Error('stream.unshift() after end event'); + stream.emit('error', e); + } else { + if (state.decoder && !addToFront && !encoding) + chunk = state.decoder.write(chunk); + + if (!addToFront) + state.reading = false; + + // 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); + } + } else if (!addToFront) { + state.reading = false; + } + + return needMoreData(state); +} + + + +// if it's past the high water mark, we can push in some more. +// Also, if we have no data yet, we can stand some +// more bytes. This is to work around cases where hwm=0, +// such as the repl. Also, if the push() triggered a +// readable event, and the user called read(largeNumber) such that +// needReadable was set, then we ought to push more, so that another +// 'readable' event will be triggered. +function needMoreData(state) { + return !state.ended && + (state.needReadable || + state.length < state.highWaterMark || + state.length === 0); +} + +// backwards compatibility. +Readable.prototype.setEncoding = function(enc) { + if (!StringDecoder) + StringDecoder = require('string_decoder/').StringDecoder; + this._readableState.decoder = new StringDecoder(enc); + this._readableState.encoding = enc; + return this; +}; + +// Don't raise the hwm > 128MB +var MAX_HWM = 0x800000; +function roundUpToNextPowerOf2(n) { + if (n >= MAX_HWM) { + n = MAX_HWM; + } else { + // Get the next highest power of 2 + n--; + for (var p = 1; p < 32; p <<= 1) n |= n >> p; + n++; + } + return n; +} + +function howMuchToRead(n, state) { + if (state.length === 0 && state.ended) + return 0; + + if (state.objectMode) + return n === 0 ? 0 : 1; + + if (isNaN(n) || util.isNull(n)) { + // only flow one buffer at a time + if (state.flowing && state.buffer.length) + return state.buffer[0].length; + else + return state.length; + } + + if (n <= 0) + return 0; + + // If we're asking for more than the target buffer level, + // then raise the water mark. Bump up to the next highest + // power of 2, to prevent increasing it excessively in tiny + // amounts. + if (n > state.highWaterMark) + state.highWaterMark = roundUpToNextPowerOf2(n); + + // don't have that much. return null, unless we've ended. + if (n > state.length) { + if (!state.ended) { + state.needReadable = true; + return 0; + } else + return state.length; + } + + return n; +} + +// you can override either this method, or the async _read(n) below. +Readable.prototype.read = function(n) { + debug('read', n); + var state = this._readableState; + var nOrig = n; + + if (!util.isNumber(n) || n > 0) + state.emittedReadable = false; + + // if we're doing read(0) to trigger a readable event, but we + // already have a bunch of data in the buffer, then just trigger + // the 'readable' event and move on. + if (n === 0 && + state.needReadable && + (state.length >= state.highWaterMark || state.ended)) { + debug('read: emitReadable', state.length, state.ended); + if (state.length === 0 && state.ended) + endReadable(this); + else + emitReadable(this); + return null; + } + + n = howMuchToRead(n, state); + + // if we've ended, and we're now clear, then finish it up. + if (n === 0 && state.ended) { + if (state.length === 0) + endReadable(this); + return null; + } + + // All the actual chunk generation logic needs to be + // *below* the call to _read. The reason is that in certain + // synthetic stream cases, such as passthrough streams, _read + // may be a completely synchronous operation which may change + // the state of the read buffer, providing enough data when + // before there was *not* enough. + // + // So, the steps are: + // 1. Figure out what the state of things will be after we do + // a read from the buffer. + // + // 2. If that resulting state will trigger a _read, then call _read. + // Note that this may be asynchronous, or synchronous. Yes, it is + // deeply ugly to write APIs this way, but that still doesn't mean + // that the Readable class should behave improperly, as streams are + // designed to be sync/async agnostic. + // Take note if the _read call is sync or async (ie, if the read call + // has returned yet), so that we know whether or not it's safe to emit + // 'readable' etc. + // + // 3. Actually pull the requested chunks out of the buffer and return. + + // if we need a readable event, then we need to do some reading. + var doRead = state.needReadable; + debug('need readable', doRead); + + // if we currently have less than the highWaterMark, then also read some + 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) { + 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. + if (state.length === 0) + state.needReadable = true; + // call internal read method + this._read(state.highWaterMark); + state.sync = false; + } + + // If _read pushed data synchronously, then `reading` will be false, + // and we need to re-evaluate how much data we can return to the user. + if (doRead && !state.reading) + n = howMuchToRead(nOrig, state); + + var ret; + if (n > 0) + ret = fromList(n, state); + else + ret = null; + + if (util.isNull(ret)) { + state.needReadable = true; + n = 0; + } + + state.length -= n; + + // If we have nothing in the buffer, then we want to know + // as soon as we *do* get something into the buffer. + if (state.length === 0 && !state.ended) + state.needReadable = true; + + // If we tried to read() past the EOF, then emit end on the next tick. + if (nOrig !== n && state.ended && state.length === 0) + endReadable(this); + + if (!util.isNull(ret)) + this.emit('data', ret); + + return ret; +}; + +function chunkInvalid(state, chunk) { + var er = null; + if (!util.isBuffer(chunk) && + !util.isString(chunk) && + !util.isNullOrUndefined(chunk) && + !state.objectMode) { + er = new TypeError('Invalid non-string/buffer chunk'); + } + return er; +} + + +function onEofChunk(stream, state) { + if (state.decoder && !state.ended) { + var chunk = state.decoder.end(); + if (chunk && chunk.length) { + state.buffer.push(chunk); + state.length += state.objectMode ? 1 : chunk.length; + } + } + state.ended = true; + + // 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 +// another read() call => stack overflow. This way, it might trigger +// a nextTick recursion warning, but that's not so bad. +function emitReadable(stream) { + var state = stream._readableState; + state.needReadable = false; + if (!state.emittedReadable) { + debug('emitReadable', state.flowing); + state.emittedReadable = true; + if (state.sync) + process.nextTick(function() { + emitReadable_(stream); + }); + else + emitReadable_(stream); + } +} + +function emitReadable_(stream) { + debug('emit readable'); + stream.emit('readable'); + flow(stream); +} + + +// at this point, the user has presumably seen the 'readable' event, +// and called read() to consume some data. that may have triggered +// in turn another _read(n) call, in which case reading = true if +// it's in progress. +// However, if we're not ended, or reading, and the length < hwm, +// then go ahead and try to read some more preemptively. +function maybeReadMore(stream, state) { + if (!state.readingMore) { + state.readingMore = true; + process.nextTick(function() { + maybeReadMore_(stream, state); + }); + } +} + +function maybeReadMore_(stream, state) { + var len = state.length; + while (!state.reading && !state.flowing && !state.ended && + state.length < state.highWaterMark) { + debug('maybeReadMore read 0'); + stream.read(0); + if (len === state.length) + // didn't get any data, stop spinning. + break; + else + len = state.length; + } + state.readingMore = false; +} + +// abstract method. to be overridden in specific implementation classes. +// call cb(er, data) where data is <= n in length. +// for virtual (non-string, non-buffer) streams, "length" is somewhat +// arbitrary, and perhaps not very meaningful. +Readable.prototype._read = function(n) { + this.emit('error', new Error('not implemented')); +}; + +Readable.prototype.pipe = function(dest, pipeOpts) { + var src = this; + var state = this._readableState; + + switch (state.pipesCount) { + case 0: + state.pipes = dest; + break; + case 1: + state.pipes = [state.pipes, dest]; + break; + default: + state.pipes.push(dest); + break; + } + state.pipesCount += 1; + debug('pipe count=%d opts=%j', state.pipesCount, pipeOpts); + + var doEnd = (!pipeOpts || pipeOpts.end !== false) && + dest !== process.stdout && + dest !== process.stderr; + + var endFn = doEnd ? onend : cleanup; + if (state.endEmitted) + process.nextTick(endFn); + else + src.once('end', endFn); + + dest.on('unpipe', onunpipe); + function onunpipe(readable) { + debug('onunpipe'); + if (readable === src) { + cleanup(); + } + } + + function onend() { + debug('onend'); + dest.end(); + } + + // when the dest drains, it reduces the awaitDrain counter + // on the source. This would be more elegant with a .once() + // handler in flow(), but adding and removing repeatedly is + // too slow. + var ondrain = pipeOnDrain(src); + dest.on('drain', ondrain); + + function cleanup() { + debug('cleanup'); + // cleanup event handlers once the pipe is broken + dest.removeListener('close', onclose); + dest.removeListener('finish', onfinish); + dest.removeListener('drain', ondrain); + dest.removeListener('error', onerror); + dest.removeListener('unpipe', onunpipe); + src.removeListener('end', onend); + src.removeListener('end', cleanup); + 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 (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) + dest.emit('error', er); + } + // This is a brutally ugly hack to make sure that our error handler + // is attached before any userland ones. NEVER DO THIS. + if (!dest._events || !dest._events.error) + dest.on('error', onerror); + else if (isArray(dest._events.error)) + dest._events.error.unshift(onerror); + else + dest._events.error = [onerror, dest._events.error]; + + + + // Both close and finish should trigger unpipe, but only once. + function onclose() { + dest.removeListener('finish', onfinish); + unpipe(); + } + dest.once('close', onclose); + function onfinish() { + debug('onfinish'); + dest.removeListener('close', onclose); + unpipe(); + } + dest.once('finish', onfinish); + + function unpipe() { + debug('unpipe'); + src.unpipe(dest); + } + + // tell the dest that it's being piped to + dest.emit('pipe', src); + + // start the flow if it hasn't been started already. + if (!state.flowing) { + debug('pipe resume'); + src.resume(); + } + + return dest; +}; + +function pipeOnDrain(src) { + return function() { + var state = src._readableState; + debug('pipeOnDrain', state.awaitDrain); + if (state.awaitDrain) + state.awaitDrain--; + if (state.awaitDrain === 0 && EE.listenerCount(src, 'data')) { + state.flowing = true; + flow(src); + } + }; +} + + +Readable.prototype.unpipe = function(dest) { + var state = this._readableState; + + // if we're not piping anywhere, then do nothing. + if (state.pipesCount === 0) + return this; + + // just one destination. most common case. + if (state.pipesCount === 1) { + // passed in one, but it's not the right one. + if (dest && dest !== state.pipes) + return this; + + if (!dest) + dest = state.pipes; + + // got a match. + state.pipes = null; + state.pipesCount = 0; + state.flowing = false; + if (dest) + dest.emit('unpipe', this); + return this; + } + + // slow case. multiple pipe destinations. + + if (!dest) { + // remove all. + var dests = state.pipes; + var len = state.pipesCount; + state.pipes = null; + state.pipesCount = 0; + state.flowing = false; + + for (var i = 0; i < len; i++) + dests[i].emit('unpipe', this); + return this; + } + + // try to find the right one. + var i = indexOf(state.pipes, dest); + if (i === -1) + return this; + + state.pipes.splice(i, 1); + state.pipesCount -= 1; + if (state.pipesCount === 1) + state.pipes = state.pipes[0]; + + dest.emit('unpipe', this); + + return this; +}; + +// set up data events if they are asked for +// Ensure readable listeners eventually get something +Readable.prototype.on = function(ev, fn) { + var res = Stream.prototype.on.call(this, ev, fn); + + // If 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; + if (!state.readableListening) { + state.readableListening = true; + state.emittedReadable = false; + state.needReadable = true; + if (!state.reading) { + var self = this; + process.nextTick(function() { + debug('readable nexttick read 0'); + self.read(0); + }); + } else if (state.length) { + emitReadable(this, state); + } + } + } + + return res; +}; +Readable.prototype.addListener = Readable.prototype.on; + +// pause() and resume() are remnants of the legacy readable stream API +// If the user uses them, then switch into old mode. +Readable.prototype.resume = function() { + var state = this._readableState; + if (!state.flowing) { + debug('resume'); + state.flowing = true; + if (!state.reading) { + debug('resume read 0'); + this.read(0); + } + resume(this, state); + } + return this; +}; + +function resume(stream, state) { + if (!state.resumeScheduled) { + state.resumeScheduled = true; + process.nextTick(function() { + resume_(stream, state); + }); + } +} + +function resume_(stream, state) { + state.resumeScheduled = false; + stream.emit('resume'); + flow(stream); + if (state.flowing && !state.reading) + stream.read(0); +} + +Readable.prototype.pause = function() { + debug('call pause flowing=%j', this._readableState.flowing); + if (false !== this._readableState.flowing) { + debug('pause'); + this._readableState.flowing = false; + this.emit('pause'); + } + return this; +}; + +function 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. +// This is *not* part of the readable stream interface. +// It is an ugly unfortunate mess of history. +Readable.prototype.wrap = function(stream) { + var state = this._readableState; + var paused = false; + + var self = this; + stream.on('end', function() { + debug('wrapped end'); + if (state.decoder && !state.ended) { + var chunk = state.decoder.end(); + if (chunk && chunk.length) + self.push(chunk); + } + + self.push(null); + }); + + stream.on('data', function(chunk) { + debug('wrapped data'); + if (state.decoder) + chunk = state.decoder.write(chunk); + if (!chunk || !state.objectMode && !chunk.length) + return; + + var ret = self.push(chunk); + if (!ret) { + paused = true; + stream.pause(); + } + }); + + // proxy all the other methods. + // important when wrapping filters and duplexes. + for (var i in stream) { + if (util.isFunction(stream[i]) && util.isUndefined(this[i])) { + this[i] = function(method) { return function() { + return stream[method].apply(stream, arguments); + }}(i); + } + } + + // proxy certain important events. + var events = ['error', 'close', 'destroy', 'pause', 'resume']; + forEach(events, function(ev) { + stream.on(ev, self.emit.bind(self, ev)); + }); + + // when we try to consume some more bytes, simply unpause the + // underlying stream. + self._read = function(n) { + debug('wrapped _read', n); + if (paused) { + paused = false; + stream.resume(); + } + }; + + return self; +}; + + + +// exposed for testing purposes only. +Readable._fromList = fromList; + +// Pluck off n bytes from an array of buffers. +// Length is the combined lengths of all the buffers in the list. +function fromList(n, state) { + var list = state.buffer; + var length = state.length; + var stringMode = !!state.decoder; + var objectMode = !!state.objectMode; + var ret; + + // nothing in the list, definitely empty. + if (list.length === 0) + return null; + + if (length === 0) + ret = null; + else if (objectMode) + ret = list.shift(); + else if (!n || n >= length) { + // read it all, truncate the array. + if (stringMode) + ret = list.join(''); + else + ret = Buffer.concat(list, length); + list.length = 0; + } else { + // read just some of it. + if (n < list[0].length) { + // just take a part of the first list item. + // slice is the same for buffers and strings. + var buf = list[0]; + ret = buf.slice(0, n); + list[0] = buf.slice(n); + } else if (n === list[0].length) { + // first list is a perfect match + ret = list.shift(); + } else { + // complex case. + // we have enough to cover it, but it spans past the first buffer. + if (stringMode) + ret = ''; + else + ret = new Buffer(n); + + var c = 0; + for (var i = 0, l = list.length; i < l && c < n; i++) { + var buf = list[0]; + var cpy = Math.min(n - c, buf.length); + + if (stringMode) + ret += buf.slice(0, cpy); + else + buf.copy(ret, c, 0, cpy); + + if (cpy < buf.length) + list[0] = buf.slice(cpy); + else + list.shift(); + + c += cpy; + } + } + } + + return ret; +} + +function endReadable(stream) { + var state = stream._readableState; + + // If we get here before consuming all the bytes, then that is a + // bug in node. Should never happen. + if (state.length > 0) + throw new Error('endReadable called on non-empty stream'); + + if (!state.endEmitted) { + state.ended = true; + process.nextTick(function() { + // Check that we didn't get one last unshift. + if (!state.endEmitted && state.length === 0) { + state.endEmitted = true; + stream.readable = false; + stream.emit('end'); + } + }); + } +} + +function forEach (xs, f) { + for (var i = 0, l = xs.length; i < l; i++) { + f(xs[i], i); + } +} + +function indexOf (xs, x) { + for (var i = 0, l = xs.length; i < l; i++) { + if (xs[i] === x) return i; + } + return -1; +} diff --git a/node_modules/mysql/node_modules/readable-stream/lib/_stream_transform.js b/node_modules/mysql/node_modules/readable-stream/lib/_stream_transform.js new file mode 100644 index 0000000..905c5e4 --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/lib/_stream_transform.js @@ -0,0 +1,209 @@ +// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. + + +// a transform stream is a readable/writable stream where you do +// something with the data. Sometimes it's called a "filter", +// but that's not a great name for it, since that implies a thing where +// some bits pass through, and others are simply ignored. (That would +// be a valid example of a transform, of course.) +// +// While the output is causally related to the input, it's not a +// necessarily symmetric or synchronous transformation. For example, +// a zlib stream might take multiple plain-text writes(), and then +// emit a single compressed chunk some time in the future. +// +// Here's how this works: +// +// The Transform stream has all the aspects of the readable and writable +// stream classes. When you write(chunk), that calls _write(chunk,cb) +// internally, and returns false if there's a lot of pending writes +// buffered up. When you call read(), that calls _read(n) until +// there's enough pending readable data buffered up. +// +// In a transform stream, the written data is placed in a buffer. When +// _read(n) is called, it transforms the queued up data, calling the +// buffered _write cb's as it consumes chunks. If consuming a single +// written chunk would result in multiple output chunks, then the first +// outputted bit calls the readcb, and subsequent chunks just go into +// the read buffer, and will cause it to emit 'readable' if necessary. +// +// This way, back-pressure is actually determined by the reading side, +// since _read has to be called to start processing a new chunk. However, +// a pathological inflate type of transform can cause excessive buffering +// here. For example, imagine a stream where every byte of input is +// interpreted as an integer from 0-255, and then results in that many +// bytes of output. Writing the 4 bytes {ff,ff,ff,ff} would result in +// 1kb of data being output. In this case, you could write a very small +// amount of input, and end up with a very large amount of output. In +// such a pathological inflating mechanism, there'd be no way to tell +// the system to stop doing the transform. A single 4MB write could +// cause the system to run out of memory. +// +// However, even in such a pathological case, only a single written chunk +// would be consumed, and then the rest would wait (un-transformed) until +// the results of the previous transformed chunk were consumed. + +module.exports = Transform; + +var Duplex = require('./_stream_duplex'); + +/**/ +var util = require('core-util-is'); +util.inherits = require('inherits'); +/**/ + +util.inherits(Transform, Duplex); + + +function TransformState(options, stream) { + this.afterTransform = function(er, data) { + return afterTransform(stream, er, data); + }; + + this.needTransform = false; + this.transforming = false; + this.writecb = null; + this.writechunk = null; +} + +function afterTransform(stream, er, data) { + var ts = stream._transformState; + ts.transforming = false; + + var cb = ts.writecb; + + if (!cb) + return stream.emit('error', new Error('no writecb in Transform class')); + + ts.writechunk = null; + ts.writecb = null; + + if (!util.isNullOrUndefined(data)) + stream.push(data); + + if (cb) + cb(er); + + var rs = stream._readableState; + rs.reading = false; + if (rs.needReadable || rs.length < rs.highWaterMark) { + stream._read(rs.highWaterMark); + } +} + + +function Transform(options) { + if (!(this instanceof Transform)) + return new Transform(options); + + Duplex.call(this, options); + + this._transformState = new TransformState(options, this); + + // when the writable side finishes, then flush out anything remaining. + var stream = this; + + // start out asking for a readable event once data is transformed. + this._readableState.needReadable = true; + + // we have implemented the _read method, and done the other things + // that Readable wants before the first _read call, so unset the + // sync guard flag. + this._readableState.sync = false; + + this.once('prefinish', function() { + if (util.isFunction(this._flush)) + this._flush(function(er) { + done(stream, er); + }); + else + done(stream); + }); +} + +Transform.prototype.push = function(chunk, encoding) { + this._transformState.needTransform = false; + return Duplex.prototype.push.call(this, chunk, encoding); +}; + +// This is the part where you do stuff! +// override this function in implementation classes. +// 'chunk' is an input chunk. +// +// Call `push(newChunk)` to pass along transformed output +// to the readable side. You may call 'push' zero or more times. +// +// Call `cb(err)` when you are done with this chunk. If you pass +// an error, then that'll put the hurt on the whole operation. If you +// never call cb(), then you'll never get another chunk. +Transform.prototype._transform = function(chunk, encoding, cb) { + throw new Error('not implemented'); +}; + +Transform.prototype._write = function(chunk, encoding, cb) { + var ts = this._transformState; + ts.writecb = cb; + ts.writechunk = chunk; + ts.writeencoding = encoding; + if (!ts.transforming) { + var rs = this._readableState; + if (ts.needTransform || + rs.needReadable || + rs.length < rs.highWaterMark) + this._read(rs.highWaterMark); + } +}; + +// Doesn't matter what the args are here. +// _transform does all the work. +// That we got here means that the readable side wants more data. +Transform.prototype._read = function(n) { + var ts = this._transformState; + + if (!util.isNull(ts.writechunk) && ts.writecb && !ts.transforming) { + ts.transforming = true; + this._transform(ts.writechunk, ts.writeencoding, ts.afterTransform); + } else { + // mark that we need a transform, so that any data that comes in + // will get processed, now that we've asked for it. + ts.needTransform = true; + } +}; + + +function done(stream, er) { + if (er) + return stream.emit('error', er); + + // if there's nothing in the write buffer, then that means + // that nothing more will ever be provided + var ws = stream._writableState; + var ts = stream._transformState; + + if (ws.length) + throw new Error('calling transform done when ws.length != 0'); + + if (ts.transforming) + throw new Error('calling transform done when still transforming'); + + return stream.push(null); +} diff --git a/node_modules/mysql/node_modules/readable-stream/lib/_stream_writable.js b/node_modules/mysql/node_modules/readable-stream/lib/_stream_writable.js new file mode 100644 index 0000000..db8539c --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/lib/_stream_writable.js @@ -0,0 +1,477 @@ +// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. + +// A bit simpler than readable streams. +// Implement an async ._write(chunk, cb), and it'll handle all +// the drain event emission and buffering. + +module.exports = Writable; + +/**/ +var Buffer = require('buffer').Buffer; +/**/ + +Writable.WritableState = WritableState; + + +/**/ +var util = require('core-util-is'); +util.inherits = require('inherits'); +/**/ + +var Stream = require('stream'); + +util.inherits(Writable, Stream); + +function WriteReq(chunk, encoding, cb) { + this.chunk = chunk; + this.encoding = encoding; + this.callback = cb; +} + +function WritableState(options, stream) { + var Duplex = require('./_stream_duplex'); + + options = options || {}; + + // the point at which write() starts returning false + // Note: 0 is a valid value, means that we always return false if + // the entire buffer is not flushed immediately on write() + var hwm = options.highWaterMark; + var defaultHwm = options.objectMode ? 16 : 16 * 1024; + this.highWaterMark = (hwm || hwm === 0) ? hwm : defaultHwm; + + // object stream flag to indicate whether or not this stream + // contains buffers or objects. + this.objectMode = !!options.objectMode; + + if (stream instanceof Duplex) + this.objectMode = this.objectMode || !!options.writableObjectMode; + + // cast to ints. + this.highWaterMark = ~~this.highWaterMark; + + this.needDrain = false; + // at the start of calling end() + this.ending = false; + // when end() has been called, and returned + this.ended = false; + // when 'finish' is emitted + this.finished = false; + + // should we decode strings into buffers before passing to _write? + // this is here so that some node-core streams can optimize string + // handling at a lower level. + var noDecode = options.decodeStrings === false; + this.decodeStrings = !noDecode; + + // Crypto is kind of old and crusty. Historically, its default string + // encoding is 'binary' so we have to make this configurable. + // Everything else in the universe uses 'utf8', though. + this.defaultEncoding = options.defaultEncoding || 'utf8'; + + // not an actual buffer we keep track of, but a measurement + // of how much we're waiting to get pushed to some underlying + // socket or file. + this.length = 0; + + // a flag to see when we're in the middle of a write. + this.writing = false; + + // 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, because any + // actions that shouldn't happen until "later" should generally also + // not happen before the first write call. + this.sync = true; + + // a flag to know if we're processing previously buffered items, which + // may call the _write() callback in the same tick, so that we don't + // end up in an overlapped onwrite situation. + this.bufferProcessing = false; + + // the callback that's passed to _write(chunk,cb) + this.onwrite = function(er) { + onwrite(stream, er); + }; + + // the callback that the user supplies to write(chunk,encoding,cb) + this.writecb = null; + + // the amount that is being written when _write is called. + this.writelen = 0; + + this.buffer = []; + + // 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; +} + +function Writable(options) { + var Duplex = require('./_stream_duplex'); + + // Writable ctor is applied to Duplexes, though they're not + // instanceof Writable, they're instanceof Readable. + if (!(this instanceof Writable) && !(this instanceof Duplex)) + return new Writable(options); + + this._writableState = new WritableState(options, this); + + // legacy. + this.writable = true; + + Stream.call(this); +} + +// Otherwise people can pipe Writable streams, which is just wrong. +Writable.prototype.pipe = function() { + this.emit('error', new Error('Cannot pipe. Not readable.')); +}; + + +function writeAfterEnd(stream, state, cb) { + var er = new Error('write after end'); + // TODO: defer error events consistently everywhere, not just the cb + stream.emit('error', er); + process.nextTick(function() { + cb(er); + }); +} + +// If we get something that is not a buffer, string, null, or undefined, +// and we're not in objectMode, then that's an error. +// Otherwise stream chunks are all considered to be of length=1, and the +// watermarks determine how many objects to keep in the buffer, rather than +// how many bytes or characters. +function validChunk(stream, state, chunk, cb) { + var valid = true; + if (!util.isBuffer(chunk) && + !util.isString(chunk) && + !util.isNullOrUndefined(chunk) && + !state.objectMode) { + var er = new TypeError('Invalid non-string/buffer chunk'); + stream.emit('error', er); + process.nextTick(function() { + cb(er); + }); + valid = false; + } + return valid; +} + +Writable.prototype.write = function(chunk, encoding, cb) { + var state = this._writableState; + var ret = false; + + if (util.isFunction(encoding)) { + cb = encoding; + encoding = null; + } + + if (util.isBuffer(chunk)) + encoding = 'buffer'; + else if (!encoding) + encoding = state.defaultEncoding; + + if (!util.isFunction(cb)) + cb = function() {}; + + if (state.ended) + writeAfterEnd(this, state, cb); + else if (validChunk(this, state, chunk, cb)) { + state.pendingcb++; + ret = writeOrBuffer(this, state, chunk, encoding, cb); + } + + return ret; +}; + +Writable.prototype.cork = function() { + var state = this._writableState; + + state.corked++; +}; + +Writable.prototype.uncork = function() { + var state = this._writableState; + + if (state.corked) { + state.corked--; + + if (!state.writing && + !state.corked && + !state.finished && + !state.bufferProcessing && + state.buffer.length) + clearBuffer(this, state); + } +}; + +function decodeChunk(state, chunk, encoding) { + if (!state.objectMode && + state.decodeStrings !== false && + util.isString(chunk)) { + chunk = new Buffer(chunk, encoding); + } + return chunk; +} + +// if we're already writing something, then just put this +// in the queue, and wait our turn. Otherwise, call _write +// If we return false, then we need a drain event, so set that flag. +function writeOrBuffer(stream, state, chunk, encoding, cb) { + chunk = decodeChunk(state, chunk, encoding); + if (util.isBuffer(chunk)) + encoding = 'buffer'; + var len = state.objectMode ? 1 : chunk.length; + + state.length += len; + + var ret = state.length < state.highWaterMark; + // we must ensure that previous needDrain will not be reset to false. + if (!ret) + state.needDrain = true; + + if (state.writing || state.corked) + state.buffer.push(new WriteReq(chunk, encoding, cb)); + else + doWrite(stream, state, false, len, chunk, encoding, cb); + + return ret; +} + +function doWrite(stream, state, writev, len, chunk, encoding, cb) { + state.writelen = len; + state.writecb = cb; + state.writing = true; + state.sync = true; + if (writev) + stream._writev(chunk, state.onwrite); + else + stream._write(chunk, encoding, state.onwrite); + state.sync = false; +} + +function onwriteError(stream, state, sync, er, cb) { + if (sync) + process.nextTick(function() { + state.pendingcb--; + cb(er); + }); + else { + state.pendingcb--; + cb(er); + } + + stream._writableState.errorEmitted = true; + stream.emit('error', er); +} + +function onwriteStateUpdate(state) { + state.writing = false; + state.writecb = null; + state.length -= state.writelen; + state.writelen = 0; +} + +function onwrite(stream, er) { + var state = stream._writableState; + var sync = state.sync; + var cb = state.writecb; + + onwriteStateUpdate(state); + + if (er) + onwriteError(stream, state, sync, er, cb); + else { + // Check if we're actually ready to finish, but don't emit yet + var finished = needFinish(stream, state); + + if (!finished && + !state.corked && + !state.bufferProcessing && + state.buffer.length) { + clearBuffer(stream, state); + } + + if (sync) { + process.nextTick(function() { + afterWrite(stream, state, finished, cb); + }); + } else { + afterWrite(stream, state, finished, cb); + } + } +} + +function afterWrite(stream, state, finished, cb) { + if (!finished) + onwriteDrain(stream, state); + state.pendingcb--; + cb(); + finishMaybe(stream, state); +} + +// Must force callback to be called on nextTick, so that we don't +// emit 'drain' before the write() consumer gets the 'false' return +// value, and has a chance to attach a 'drain' listener. +function onwriteDrain(stream, state) { + if (state.length === 0 && state.needDrain) { + state.needDrain = false; + stream.emit('drain'); + } +} + + +// if there's something in the buffer waiting, then process it +function clearBuffer(stream, state) { + state.bufferProcessing = true; + + if (stream._writev && state.buffer.length > 1) { + // Fast case, write everything using _writev() + var cbs = []; + for (var c = 0; c < state.buffer.length; c++) + cbs.push(state.buffer[c].callback); + + // count the one we are adding, as well. + // TODO(isaacs) clean this up + state.pendingcb++; + doWrite(stream, state, true, state.length, state.buffer, '', function(err) { + for (var i = 0; i < cbs.length; i++) { + state.pendingcb--; + cbs[i](err); + } + }); + + // Clear buffer + state.buffer = []; + } else { + // Slow case, write chunks one-by-one + for (var c = 0; c < state.buffer.length; c++) { + var entry = state.buffer[c]; + var chunk = entry.chunk; + var encoding = entry.encoding; + var cb = entry.callback; + var len = state.objectMode ? 1 : chunk.length; + + doWrite(stream, state, false, len, chunk, encoding, cb); + + // if we didn't call the onwrite immediately, then + // it means that we need to wait until it does. + // also, that means that the chunk and cb are currently + // being processed, so move the buffer counter past them. + if (state.writing) { + c++; + break; + } + } + + if (c < state.buffer.length) + state.buffer = state.buffer.slice(c); + else + state.buffer.length = 0; + } + + state.bufferProcessing = false; +} + +Writable.prototype._write = function(chunk, encoding, cb) { + cb(new Error('not implemented')); + +}; + +Writable.prototype._writev = null; + +Writable.prototype.end = function(chunk, encoding, cb) { + var state = this._writableState; + + if (util.isFunction(chunk)) { + cb = chunk; + chunk = null; + encoding = null; + } else if (util.isFunction(encoding)) { + cb = encoding; + encoding = null; + } + + if (!util.isNullOrUndefined(chunk)) + this.write(chunk, encoding); + + // .end() fully uncorks + if (state.corked) { + state.corked = 1; + this.uncork(); + } + + // ignore unnecessary end() calls. + if (!state.ending && !state.finished) + endWritable(this, state, cb); +}; + + +function needFinish(stream, state) { + return (state.ending && + state.length === 0 && + !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); + if (need) { + if (state.pendingcb === 0) { + prefinish(stream, state); + state.finished = true; + stream.emit('finish'); + } else + prefinish(stream, state); + } + return need; +} + +function endWritable(stream, state, cb) { + state.ending = true; + finishMaybe(stream, state); + if (cb) { + if (state.finished) + process.nextTick(cb); + else + stream.once('finish', cb); + } + state.ended = true; +} diff --git a/node_modules/mysql/node_modules/readable-stream/node_modules/core-util-is/README.md b/node_modules/mysql/node_modules/readable-stream/node_modules/core-util-is/README.md new file mode 100644 index 0000000..5a76b41 --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/node_modules/core-util-is/README.md @@ -0,0 +1,3 @@ +# core-util-is + +The `util.is*` functions introduced in Node v0.12. diff --git a/node_modules/mysql/node_modules/readable-stream/node_modules/core-util-is/float.patch b/node_modules/mysql/node_modules/readable-stream/node_modules/core-util-is/float.patch new file mode 100644 index 0000000..a06d5c0 --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/node_modules/core-util-is/float.patch @@ -0,0 +1,604 @@ +diff --git a/lib/util.js b/lib/util.js +index a03e874..9074e8e 100644 +--- a/lib/util.js ++++ b/lib/util.js +@@ -19,430 +19,6 @@ + // OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE + // USE OR OTHER DEALINGS IN THE SOFTWARE. + +-var formatRegExp = /%[sdj%]/g; +-exports.format = function(f) { +- if (!isString(f)) { +- var objects = []; +- for (var i = 0; i < arguments.length; i++) { +- objects.push(inspect(arguments[i])); +- } +- return objects.join(' '); +- } +- +- var i = 1; +- var args = arguments; +- var len = args.length; +- var str = String(f).replace(formatRegExp, function(x) { +- if (x === '%%') return '%'; +- if (i >= len) return x; +- switch (x) { +- case '%s': return String(args[i++]); +- case '%d': return Number(args[i++]); +- case '%j': +- try { +- return JSON.stringify(args[i++]); +- } catch (_) { +- return '[Circular]'; +- } +- default: +- return x; +- } +- }); +- for (var x = args[i]; i < len; x = args[++i]) { +- if (isNull(x) || !isObject(x)) { +- str += ' ' + x; +- } else { +- str += ' ' + inspect(x); +- } +- } +- return str; +-}; +- +- +-// Mark that a method should not be used. +-// Returns a modified function which warns once by default. +-// If --no-deprecation is set, then it is a no-op. +-exports.deprecate = function(fn, msg) { +- // Allow for deprecating things in the process of starting up. +- if (isUndefined(global.process)) { +- return function() { +- return exports.deprecate(fn, msg).apply(this, arguments); +- }; +- } +- +- if (process.noDeprecation === true) { +- return fn; +- } +- +- var warned = false; +- function deprecated() { +- if (!warned) { +- if (process.throwDeprecation) { +- throw new Error(msg); +- } else if (process.traceDeprecation) { +- console.trace(msg); +- } else { +- console.error(msg); +- } +- warned = true; +- } +- return fn.apply(this, arguments); +- } +- +- return deprecated; +-}; +- +- +-var debugs = {}; +-var debugEnviron; +-exports.debuglog = function(set) { +- if (isUndefined(debugEnviron)) +- debugEnviron = process.env.NODE_DEBUG || ''; +- set = set.toUpperCase(); +- if (!debugs[set]) { +- if (new RegExp('\\b' + set + '\\b', 'i').test(debugEnviron)) { +- var pid = process.pid; +- debugs[set] = function() { +- var msg = exports.format.apply(exports, arguments); +- console.error('%s %d: %s', set, pid, msg); +- }; +- } else { +- debugs[set] = function() {}; +- } +- } +- return debugs[set]; +-}; +- +- +-/** +- * Echos the value of a value. Trys to print the value out +- * in the best way possible given the different types. +- * +- * @param {Object} obj The object to print out. +- * @param {Object} opts Optional options object that alters the output. +- */ +-/* legacy: obj, showHidden, depth, colors*/ +-function inspect(obj, opts) { +- // default options +- var ctx = { +- seen: [], +- stylize: stylizeNoColor +- }; +- // legacy... +- if (arguments.length >= 3) ctx.depth = arguments[2]; +- if (arguments.length >= 4) ctx.colors = arguments[3]; +- if (isBoolean(opts)) { +- // legacy... +- ctx.showHidden = opts; +- } else if (opts) { +- // got an "options" object +- exports._extend(ctx, opts); +- } +- // set default options +- if (isUndefined(ctx.showHidden)) ctx.showHidden = false; +- if (isUndefined(ctx.depth)) ctx.depth = 2; +- if (isUndefined(ctx.colors)) ctx.colors = false; +- if (isUndefined(ctx.customInspect)) ctx.customInspect = true; +- if (ctx.colors) ctx.stylize = stylizeWithColor; +- return formatValue(ctx, obj, ctx.depth); +-} +-exports.inspect = inspect; +- +- +-// http://en.wikipedia.org/wiki/ANSI_escape_code#graphics +-inspect.colors = { +- 'bold' : [1, 22], +- 'italic' : [3, 23], +- 'underline' : [4, 24], +- 'inverse' : [7, 27], +- 'white' : [37, 39], +- 'grey' : [90, 39], +- 'black' : [30, 39], +- 'blue' : [34, 39], +- 'cyan' : [36, 39], +- 'green' : [32, 39], +- 'magenta' : [35, 39], +- 'red' : [31, 39], +- 'yellow' : [33, 39] +-}; +- +-// Don't use 'blue' not visible on cmd.exe +-inspect.styles = { +- 'special': 'cyan', +- 'number': 'yellow', +- 'boolean': 'yellow', +- 'undefined': 'grey', +- 'null': 'bold', +- 'string': 'green', +- 'date': 'magenta', +- // "name": intentionally not styling +- 'regexp': 'red' +-}; +- +- +-function stylizeWithColor(str, styleType) { +- var style = inspect.styles[styleType]; +- +- if (style) { +- return '\u001b[' + inspect.colors[style][0] + 'm' + str + +- '\u001b[' + inspect.colors[style][1] + 'm'; +- } else { +- return str; +- } +-} +- +- +-function stylizeNoColor(str, styleType) { +- return str; +-} +- +- +-function arrayToHash(array) { +- var hash = {}; +- +- array.forEach(function(val, idx) { +- hash[val] = true; +- }); +- +- return hash; +-} +- +- +-function formatValue(ctx, value, recurseTimes) { +- // Provide a hook for user-specified inspect functions. +- // Check that value is an object with an inspect function on it +- if (ctx.customInspect && +- value && +- isFunction(value.inspect) && +- // Filter out the util module, it's inspect function is special +- value.inspect !== exports.inspect && +- // Also filter out any prototype objects using the circular check. +- !(value.constructor && value.constructor.prototype === value)) { +- var ret = value.inspect(recurseTimes, ctx); +- if (!isString(ret)) { +- ret = formatValue(ctx, ret, recurseTimes); +- } +- return ret; +- } +- +- // Primitive types cannot have properties +- var primitive = formatPrimitive(ctx, value); +- if (primitive) { +- return primitive; +- } +- +- // Look up the keys of the object. +- var keys = Object.keys(value); +- var visibleKeys = arrayToHash(keys); +- +- if (ctx.showHidden) { +- keys = Object.getOwnPropertyNames(value); +- } +- +- // Some type of object without properties can be shortcutted. +- if (keys.length === 0) { +- if (isFunction(value)) { +- var name = value.name ? ': ' + value.name : ''; +- return ctx.stylize('[Function' + name + ']', 'special'); +- } +- if (isRegExp(value)) { +- return ctx.stylize(RegExp.prototype.toString.call(value), 'regexp'); +- } +- if (isDate(value)) { +- return ctx.stylize(Date.prototype.toString.call(value), 'date'); +- } +- if (isError(value)) { +- return formatError(value); +- } +- } +- +- var base = '', array = false, braces = ['{', '}']; +- +- // Make Array say that they are Array +- if (isArray(value)) { +- array = true; +- braces = ['[', ']']; +- } +- +- // Make functions say that they are functions +- if (isFunction(value)) { +- var n = value.name ? ': ' + value.name : ''; +- base = ' [Function' + n + ']'; +- } +- +- // Make RegExps say that they are RegExps +- if (isRegExp(value)) { +- base = ' ' + RegExp.prototype.toString.call(value); +- } +- +- // Make dates with properties first say the date +- if (isDate(value)) { +- base = ' ' + Date.prototype.toUTCString.call(value); +- } +- +- // Make error with message first say the error +- if (isError(value)) { +- base = ' ' + formatError(value); +- } +- +- if (keys.length === 0 && (!array || value.length == 0)) { +- return braces[0] + base + braces[1]; +- } +- +- if (recurseTimes < 0) { +- if (isRegExp(value)) { +- return ctx.stylize(RegExp.prototype.toString.call(value), 'regexp'); +- } else { +- return ctx.stylize('[Object]', 'special'); +- } +- } +- +- ctx.seen.push(value); +- +- var output; +- if (array) { +- output = formatArray(ctx, value, recurseTimes, visibleKeys, keys); +- } else { +- output = keys.map(function(key) { +- return formatProperty(ctx, value, recurseTimes, visibleKeys, key, array); +- }); +- } +- +- ctx.seen.pop(); +- +- return reduceToSingleString(output, base, braces); +-} +- +- +-function formatPrimitive(ctx, value) { +- if (isUndefined(value)) +- return ctx.stylize('undefined', 'undefined'); +- if (isString(value)) { +- var simple = '\'' + JSON.stringify(value).replace(/^"|"$/g, '') +- .replace(/'/g, "\\'") +- .replace(/\\"/g, '"') + '\''; +- return ctx.stylize(simple, 'string'); +- } +- if (isNumber(value)) { +- // Format -0 as '-0'. Strict equality won't distinguish 0 from -0, +- // so instead we use the fact that 1 / -0 < 0 whereas 1 / 0 > 0 . +- if (value === 0 && 1 / value < 0) +- return ctx.stylize('-0', 'number'); +- return ctx.stylize('' + value, 'number'); +- } +- if (isBoolean(value)) +- return ctx.stylize('' + value, 'boolean'); +- // For some reason typeof null is "object", so special case here. +- if (isNull(value)) +- return ctx.stylize('null', 'null'); +-} +- +- +-function formatError(value) { +- return '[' + Error.prototype.toString.call(value) + ']'; +-} +- +- +-function formatArray(ctx, value, recurseTimes, visibleKeys, keys) { +- var output = []; +- for (var i = 0, l = value.length; i < l; ++i) { +- if (hasOwnProperty(value, String(i))) { +- output.push(formatProperty(ctx, value, recurseTimes, visibleKeys, +- String(i), true)); +- } else { +- output.push(''); +- } +- } +- keys.forEach(function(key) { +- if (!key.match(/^\d+$/)) { +- output.push(formatProperty(ctx, value, recurseTimes, visibleKeys, +- key, true)); +- } +- }); +- return output; +-} +- +- +-function formatProperty(ctx, value, recurseTimes, visibleKeys, key, array) { +- var name, str, desc; +- desc = Object.getOwnPropertyDescriptor(value, key) || { value: value[key] }; +- if (desc.get) { +- if (desc.set) { +- str = ctx.stylize('[Getter/Setter]', 'special'); +- } else { +- str = ctx.stylize('[Getter]', 'special'); +- } +- } else { +- if (desc.set) { +- str = ctx.stylize('[Setter]', 'special'); +- } +- } +- if (!hasOwnProperty(visibleKeys, key)) { +- name = '[' + key + ']'; +- } +- if (!str) { +- if (ctx.seen.indexOf(desc.value) < 0) { +- if (isNull(recurseTimes)) { +- str = formatValue(ctx, desc.value, null); +- } else { +- str = formatValue(ctx, desc.value, recurseTimes - 1); +- } +- if (str.indexOf('\n') > -1) { +- if (array) { +- str = str.split('\n').map(function(line) { +- return ' ' + line; +- }).join('\n').substr(2); +- } else { +- str = '\n' + str.split('\n').map(function(line) { +- return ' ' + line; +- }).join('\n'); +- } +- } +- } else { +- str = ctx.stylize('[Circular]', 'special'); +- } +- } +- if (isUndefined(name)) { +- if (array && key.match(/^\d+$/)) { +- return str; +- } +- name = JSON.stringify('' + key); +- if (name.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)) { +- name = name.substr(1, name.length - 2); +- name = ctx.stylize(name, 'name'); +- } else { +- name = name.replace(/'/g, "\\'") +- .replace(/\\"/g, '"') +- .replace(/(^"|"$)/g, "'"); +- name = ctx.stylize(name, 'string'); +- } +- } +- +- return name + ': ' + str; +-} +- +- +-function reduceToSingleString(output, base, braces) { +- var numLinesEst = 0; +- var length = output.reduce(function(prev, cur) { +- numLinesEst++; +- if (cur.indexOf('\n') >= 0) numLinesEst++; +- return prev + cur.replace(/\u001b\[\d\d?m/g, '').length + 1; +- }, 0); +- +- if (length > 60) { +- return braces[0] + +- (base === '' ? '' : base + '\n ') + +- ' ' + +- output.join(',\n ') + +- ' ' + +- braces[1]; +- } +- +- return braces[0] + base + ' ' + output.join(', ') + ' ' + braces[1]; +-} +- +- + // NOTE: These type checking functions intentionally don't use `instanceof` + // because it is fragile and can be easily faked with `Object.create()`. + function isArray(ar) { +@@ -522,166 +98,10 @@ function isPrimitive(arg) { + exports.isPrimitive = isPrimitive; + + function isBuffer(arg) { +- return arg instanceof Buffer; ++ return Buffer.isBuffer(arg); + } + exports.isBuffer = isBuffer; + + function objectToString(o) { + return Object.prototype.toString.call(o); +-} +- +- +-function pad(n) { +- return n < 10 ? '0' + n.toString(10) : n.toString(10); +-} +- +- +-var months = ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', +- 'Oct', 'Nov', 'Dec']; +- +-// 26 Feb 16:19:34 +-function timestamp() { +- var d = new Date(); +- var time = [pad(d.getHours()), +- pad(d.getMinutes()), +- pad(d.getSeconds())].join(':'); +- return [d.getDate(), months[d.getMonth()], time].join(' '); +-} +- +- +-// log is just a thin wrapper to console.log that prepends a timestamp +-exports.log = function() { +- console.log('%s - %s', timestamp(), exports.format.apply(exports, arguments)); +-}; +- +- +-/** +- * Inherit the prototype methods from one constructor into another. +- * +- * The Function.prototype.inherits from lang.js rewritten as a standalone +- * function (not on Function.prototype). NOTE: If this file is to be loaded +- * during bootstrapping this function needs to be rewritten using some native +- * functions as prototype setup using normal JavaScript does not work as +- * expected during bootstrapping (see mirror.js in r114903). +- * +- * @param {function} ctor Constructor function which needs to inherit the +- * prototype. +- * @param {function} superCtor Constructor function to inherit prototype from. +- */ +-exports.inherits = function(ctor, superCtor) { +- ctor.super_ = superCtor; +- ctor.prototype = Object.create(superCtor.prototype, { +- constructor: { +- value: ctor, +- enumerable: false, +- writable: true, +- configurable: true +- } +- }); +-}; +- +-exports._extend = function(origin, add) { +- // Don't do anything if add isn't an object +- if (!add || !isObject(add)) return origin; +- +- var keys = Object.keys(add); +- var i = keys.length; +- while (i--) { +- origin[keys[i]] = add[keys[i]]; +- } +- return origin; +-}; +- +-function hasOwnProperty(obj, prop) { +- return Object.prototype.hasOwnProperty.call(obj, prop); +-} +- +- +-// Deprecated old stuff. +- +-exports.p = exports.deprecate(function() { +- for (var i = 0, len = arguments.length; i < len; ++i) { +- console.error(exports.inspect(arguments[i])); +- } +-}, 'util.p: Use console.error() instead'); +- +- +-exports.exec = exports.deprecate(function() { +- return require('child_process').exec.apply(this, arguments); +-}, 'util.exec is now called `child_process.exec`.'); +- +- +-exports.print = exports.deprecate(function() { +- for (var i = 0, len = arguments.length; i < len; ++i) { +- process.stdout.write(String(arguments[i])); +- } +-}, 'util.print: Use console.log instead'); +- +- +-exports.puts = exports.deprecate(function() { +- for (var i = 0, len = arguments.length; i < len; ++i) { +- process.stdout.write(arguments[i] + '\n'); +- } +-}, 'util.puts: Use console.log instead'); +- +- +-exports.debug = exports.deprecate(function(x) { +- process.stderr.write('DEBUG: ' + x + '\n'); +-}, 'util.debug: Use console.error instead'); +- +- +-exports.error = exports.deprecate(function(x) { +- for (var i = 0, len = arguments.length; i < len; ++i) { +- process.stderr.write(arguments[i] + '\n'); +- } +-}, 'util.error: Use console.error instead'); +- +- +-exports.pump = exports.deprecate(function(readStream, writeStream, callback) { +- var callbackCalled = false; +- +- function call(a, b, c) { +- if (callback && !callbackCalled) { +- callback(a, b, c); +- callbackCalled = true; +- } +- } +- +- readStream.addListener('data', function(chunk) { +- if (writeStream.write(chunk) === false) readStream.pause(); +- }); +- +- writeStream.addListener('drain', function() { +- readStream.resume(); +- }); +- +- readStream.addListener('end', function() { +- writeStream.end(); +- }); +- +- readStream.addListener('close', function() { +- call(); +- }); +- +- readStream.addListener('error', function(err) { +- writeStream.end(); +- call(err); +- }); +- +- writeStream.addListener('error', function(err) { +- readStream.destroy(); +- call(err); +- }); +-}, 'util.pump(): Use readableStream.pipe() instead'); +- +- +-var uv; +-exports._errnoException = function(err, syscall) { +- if (isUndefined(uv)) uv = process.binding('uv'); +- var errname = uv.errname(err); +- var e = new Error(syscall + ' ' + errname); +- e.code = errname; +- e.errno = errname; +- e.syscall = syscall; +- return e; +-}; ++} \ No newline at end of file diff --git a/node_modules/mysql/node_modules/readable-stream/node_modules/core-util-is/lib/util.js b/node_modules/mysql/node_modules/readable-stream/node_modules/core-util-is/lib/util.js new file mode 100644 index 0000000..9074e8e --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/node_modules/core-util-is/lib/util.js @@ -0,0 +1,107 @@ +// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. + +// NOTE: These type checking functions intentionally don't use `instanceof` +// because it is fragile and can be easily faked with `Object.create()`. +function isArray(ar) { + return Array.isArray(ar); +} +exports.isArray = isArray; + +function isBoolean(arg) { + return typeof arg === 'boolean'; +} +exports.isBoolean = isBoolean; + +function isNull(arg) { + return arg === null; +} +exports.isNull = isNull; + +function isNullOrUndefined(arg) { + return arg == null; +} +exports.isNullOrUndefined = isNullOrUndefined; + +function isNumber(arg) { + return typeof arg === 'number'; +} +exports.isNumber = isNumber; + +function isString(arg) { + return typeof arg === 'string'; +} +exports.isString = isString; + +function isSymbol(arg) { + return typeof arg === 'symbol'; +} +exports.isSymbol = isSymbol; + +function isUndefined(arg) { + return arg === void 0; +} +exports.isUndefined = isUndefined; + +function isRegExp(re) { + return isObject(re) && objectToString(re) === '[object RegExp]'; +} +exports.isRegExp = isRegExp; + +function isObject(arg) { + return typeof arg === 'object' && arg !== null; +} +exports.isObject = isObject; + +function isDate(d) { + return isObject(d) && objectToString(d) === '[object Date]'; +} +exports.isDate = isDate; + +function isError(e) { + return isObject(e) && + (objectToString(e) === '[object Error]' || e instanceof Error); +} +exports.isError = isError; + +function isFunction(arg) { + return typeof arg === 'function'; +} +exports.isFunction = isFunction; + +function isPrimitive(arg) { + return arg === null || + typeof arg === 'boolean' || + typeof arg === 'number' || + typeof arg === 'string' || + typeof arg === 'symbol' || // ES6 symbol + typeof arg === 'undefined'; +} +exports.isPrimitive = isPrimitive; + +function isBuffer(arg) { + return Buffer.isBuffer(arg); +} +exports.isBuffer = isBuffer; + +function objectToString(o) { + return Object.prototype.toString.call(o); +} \ No newline at end of file diff --git a/node_modules/mysql/node_modules/readable-stream/node_modules/core-util-is/package.json b/node_modules/mysql/node_modules/readable-stream/node_modules/core-util-is/package.json new file mode 100644 index 0000000..390312c --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/node_modules/core-util-is/package.json @@ -0,0 +1,38 @@ +{ + "name": "core-util-is", + "version": "1.0.1", + "description": "The `util.is*` functions introduced in Node v0.12.", + "main": "lib/util.js", + "repository": { + "type": "git", + "url": "git://github.com/isaacs/core-util-is" + }, + "keywords": [ + "util", + "isBuffer", + "isArray", + "isNumber", + "isString", + "isRegExp", + "isThis", + "isThat", + "polyfill" + ], + "author": { + "name": "Isaac Z. Schlueter", + "email": "i@izs.me", + "url": "http://blog.izs.me/" + }, + "license": "MIT", + "bugs": { + "url": "https://github.com/isaacs/core-util-is/issues" + }, + "readme": "# core-util-is\n\nThe `util.is*` functions introduced in Node v0.12.\n", + "readmeFilename": "README.md", + "homepage": "https://github.com/isaacs/core-util-is", + "_id": "core-util-is@1.0.1", + "_shasum": "6b07085aef9a3ccac6ee53bf9d3df0c1521a5538", + "_from": "core-util-is@~1.0.0", + "_resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.1.tgz", + "scripts": {} +} diff --git a/node_modules/mysql/node_modules/readable-stream/node_modules/core-util-is/util.js b/node_modules/mysql/node_modules/readable-stream/node_modules/core-util-is/util.js new file mode 100644 index 0000000..007fa10 --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/node_modules/core-util-is/util.js @@ -0,0 +1,106 @@ +// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. + +// NOTE: These type checking functions intentionally don't use `instanceof` +// because it is fragile and can be easily faked with `Object.create()`. +function isArray(ar) { + return Array.isArray(ar); +} +exports.isArray = isArray; + +function isBoolean(arg) { + return typeof arg === 'boolean'; +} +exports.isBoolean = isBoolean; + +function isNull(arg) { + return arg === null; +} +exports.isNull = isNull; + +function isNullOrUndefined(arg) { + return arg == null; +} +exports.isNullOrUndefined = isNullOrUndefined; + +function isNumber(arg) { + return typeof arg === 'number'; +} +exports.isNumber = isNumber; + +function isString(arg) { + return typeof arg === 'string'; +} +exports.isString = isString; + +function isSymbol(arg) { + return typeof arg === 'symbol'; +} +exports.isSymbol = isSymbol; + +function isUndefined(arg) { + return arg === void 0; +} +exports.isUndefined = isUndefined; + +function isRegExp(re) { + return isObject(re) && objectToString(re) === '[object RegExp]'; +} +exports.isRegExp = isRegExp; + +function isObject(arg) { + return typeof arg === 'object' && arg !== null; +} +exports.isObject = isObject; + +function isDate(d) { + return isObject(d) && objectToString(d) === '[object Date]'; +} +exports.isDate = isDate; + +function isError(e) { + return isObject(e) && objectToString(e) === '[object Error]'; +} +exports.isError = isError; + +function isFunction(arg) { + return typeof arg === 'function'; +} +exports.isFunction = isFunction; + +function isPrimitive(arg) { + return arg === null || + typeof arg === 'boolean' || + typeof arg === 'number' || + typeof arg === 'string' || + typeof arg === 'symbol' || // ES6 symbol + typeof arg === 'undefined'; +} +exports.isPrimitive = isPrimitive; + +function isBuffer(arg) { + return arg instanceof Buffer; +} +exports.isBuffer = isBuffer; + +function objectToString(o) { + return Object.prototype.toString.call(o); +} diff --git a/node_modules/mysql/node_modules/readable-stream/node_modules/inherits/LICENSE b/node_modules/mysql/node_modules/readable-stream/node_modules/inherits/LICENSE new file mode 100644 index 0000000..dea3013 --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/node_modules/inherits/LICENSE @@ -0,0 +1,16 @@ +The ISC License + +Copyright (c) Isaac Z. Schlueter + +Permission to use, copy, modify, and/or distribute this software for any +purpose with or without fee is hereby granted, provided that the above +copyright notice and this permission notice appear in all copies. + +THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH +REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND +FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, +INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM +LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR +OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR +PERFORMANCE OF THIS SOFTWARE. + diff --git a/node_modules/mysql/node_modules/readable-stream/node_modules/inherits/README.md b/node_modules/mysql/node_modules/readable-stream/node_modules/inherits/README.md new file mode 100644 index 0000000..b1c5665 --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/node_modules/inherits/README.md @@ -0,0 +1,42 @@ +Browser-friendly inheritance fully compatible with standard node.js +[inherits](http://nodejs.org/api/util.html#util_util_inherits_constructor_superconstructor). + +This package exports standard `inherits` from node.js `util` module in +node environment, but also provides alternative browser-friendly +implementation through [browser +field](https://gist.github.com/shtylman/4339901). Alternative +implementation is a literal copy of standard one located in standalone +module to avoid requiring of `util`. It also has a shim for old +browsers with no `Object.create` support. + +While keeping you sure you are using standard `inherits` +implementation in node.js environment, it allows bundlers such as +[browserify](https://github.com/substack/node-browserify) to not +include full `util` package to your client code if all you need is +just `inherits` function. It worth, because browser shim for `util` +package is large and `inherits` is often the single function you need +from it. + +It's recommended to use this package instead of +`require('util').inherits` for any code that has chances to be used +not only in node.js but in browser too. + +## usage + +```js +var inherits = require('inherits'); +// then use exactly as the standard one +``` + +## note on version ~1.0 + +Version ~1.0 had completely different motivation and is not compatible +neither with 2.0 nor with standard node.js `inherits`. + +If you are using version ~1.0 and planning to switch to ~2.0, be +careful: + +* new version uses `super_` instead of `super` for referencing + superclass +* new version overwrites current prototype while old one preserves any + existing fields on it diff --git a/node_modules/mysql/node_modules/readable-stream/node_modules/inherits/inherits.js b/node_modules/mysql/node_modules/readable-stream/node_modules/inherits/inherits.js new file mode 100644 index 0000000..29f5e24 --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/node_modules/inherits/inherits.js @@ -0,0 +1 @@ +module.exports = require('util').inherits diff --git a/node_modules/mysql/node_modules/readable-stream/node_modules/inherits/inherits_browser.js b/node_modules/mysql/node_modules/readable-stream/node_modules/inherits/inherits_browser.js new file mode 100644 index 0000000..c1e78a7 --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/node_modules/inherits/inherits_browser.js @@ -0,0 +1,23 @@ +if (typeof Object.create === 'function') { + // implementation from standard node.js 'util' module + module.exports = function inherits(ctor, superCtor) { + ctor.super_ = superCtor + ctor.prototype = Object.create(superCtor.prototype, { + constructor: { + value: ctor, + enumerable: false, + writable: true, + configurable: true + } + }); + }; +} else { + // old school shim for old browsers + module.exports = function inherits(ctor, superCtor) { + ctor.super_ = superCtor + var TempCtor = function () {} + TempCtor.prototype = superCtor.prototype + ctor.prototype = new TempCtor() + ctor.prototype.constructor = ctor + } +} diff --git a/node_modules/mysql/node_modules/readable-stream/node_modules/inherits/package.json b/node_modules/mysql/node_modules/readable-stream/node_modules/inherits/package.json new file mode 100644 index 0000000..c532ca6 --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/node_modules/inherits/package.json @@ -0,0 +1,33 @@ +{ + "name": "inherits", + "description": "Browser-friendly inheritance fully compatible with standard node.js inherits()", + "version": "2.0.1", + "keywords": [ + "inheritance", + "class", + "klass", + "oop", + "object-oriented", + "inherits", + "browser", + "browserify" + ], + "main": "./inherits.js", + "browser": "./inherits_browser.js", + "repository": { + "type": "git", + "url": "git://github.com/isaacs/inherits" + }, + "license": "ISC", + "scripts": { + "test": "node test" + }, + "readme": "Browser-friendly inheritance fully compatible with standard node.js\n[inherits](http://nodejs.org/api/util.html#util_util_inherits_constructor_superconstructor).\n\nThis package exports standard `inherits` from node.js `util` module in\nnode environment, but also provides alternative browser-friendly\nimplementation through [browser\nfield](https://gist.github.com/shtylman/4339901). Alternative\nimplementation is a literal copy of standard one located in standalone\nmodule to avoid requiring of `util`. It also has a shim for old\nbrowsers with no `Object.create` support.\n\nWhile keeping you sure you are using standard `inherits`\nimplementation in node.js environment, it allows bundlers such as\n[browserify](https://github.com/substack/node-browserify) to not\ninclude full `util` package to your client code if all you need is\njust `inherits` function. It worth, because browser shim for `util`\npackage is large and `inherits` is often the single function you need\nfrom it.\n\nIt's recommended to use this package instead of\n`require('util').inherits` for any code that has chances to be used\nnot only in node.js but in browser too.\n\n## usage\n\n```js\nvar inherits = require('inherits');\n// then use exactly as the standard one\n```\n\n## note on version ~1.0\n\nVersion ~1.0 had completely different motivation and is not compatible\nneither with 2.0 nor with standard node.js `inherits`.\n\nIf you are using version ~1.0 and planning to switch to ~2.0, be\ncareful:\n\n* new version uses `super_` instead of `super` for referencing\n superclass\n* new version overwrites current prototype while old one preserves any\n existing fields on it\n", + "readmeFilename": "README.md", + "bugs": { + "url": "https://github.com/isaacs/inherits/issues" + }, + "homepage": "https://github.com/isaacs/inherits", + "_id": "inherits@2.0.1", + "_from": "inherits@~2.0.1" +} diff --git a/node_modules/mysql/node_modules/readable-stream/node_modules/inherits/test.js b/node_modules/mysql/node_modules/readable-stream/node_modules/inherits/test.js new file mode 100644 index 0000000..fc53012 --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/node_modules/inherits/test.js @@ -0,0 +1,25 @@ +var inherits = require('./inherits.js') +var assert = require('assert') + +function test(c) { + assert(c.constructor === Child) + assert(c.constructor.super_ === Parent) + assert(Object.getPrototypeOf(c) === Child.prototype) + assert(Object.getPrototypeOf(Object.getPrototypeOf(c)) === Parent.prototype) + assert(c instanceof Child) + assert(c instanceof Parent) +} + +function Child() { + Parent.call(this) + test(this) +} + +function Parent() {} + +inherits(Child, Parent) + +var c = new Child +test(c) + +console.log('ok') diff --git a/node_modules/mysql/node_modules/readable-stream/node_modules/isarray/README.md b/node_modules/mysql/node_modules/readable-stream/node_modules/isarray/README.md new file mode 100644 index 0000000..052a62b --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/node_modules/isarray/README.md @@ -0,0 +1,54 @@ + +# isarray + +`Array#isArray` for older browsers. + +## Usage + +```js +var isArray = require('isarray'); + +console.log(isArray([])); // => true +console.log(isArray({})); // => false +``` + +## Installation + +With [npm](http://npmjs.org) do + +```bash +$ npm install isarray +``` + +Then bundle for the browser with +[browserify](https://github.com/substack/browserify). + +With [component](http://component.io) do + +```bash +$ component install juliangruber/isarray +``` + +## License + +(MIT) + +Copyright (c) 2013 Julian Gruber <julian@juliangruber.com> + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/node_modules/mysql/node_modules/readable-stream/node_modules/isarray/build/build.js b/node_modules/mysql/node_modules/readable-stream/node_modules/isarray/build/build.js new file mode 100644 index 0000000..ec58596 --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/node_modules/isarray/build/build.js @@ -0,0 +1,209 @@ + +/** + * Require the given path. + * + * @param {String} path + * @return {Object} exports + * @api public + */ + +function require(path, parent, orig) { + var resolved = require.resolve(path); + + // lookup failed + if (null == resolved) { + orig = orig || path; + parent = parent || 'root'; + var err = new Error('Failed to require "' + orig + '" from "' + parent + '"'); + err.path = orig; + err.parent = parent; + err.require = true; + throw err; + } + + var module = require.modules[resolved]; + + // perform real require() + // by invoking the module's + // registered function + if (!module.exports) { + module.exports = {}; + module.client = module.component = true; + module.call(this, module.exports, require.relative(resolved), module); + } + + return module.exports; +} + +/** + * Registered modules. + */ + +require.modules = {}; + +/** + * Registered aliases. + */ + +require.aliases = {}; + +/** + * Resolve `path`. + * + * Lookup: + * + * - PATH/index.js + * - PATH.js + * - PATH + * + * @param {String} path + * @return {String} path or null + * @api private + */ + +require.resolve = function(path) { + if (path.charAt(0) === '/') path = path.slice(1); + var index = path + '/index.js'; + + var paths = [ + path, + path + '.js', + path + '.json', + path + '/index.js', + path + '/index.json' + ]; + + for (var i = 0; i < paths.length; i++) { + var path = paths[i]; + if (require.modules.hasOwnProperty(path)) return path; + } + + if (require.aliases.hasOwnProperty(index)) { + return require.aliases[index]; + } +}; + +/** + * Normalize `path` relative to the current path. + * + * @param {String} curr + * @param {String} path + * @return {String} + * @api private + */ + +require.normalize = function(curr, path) { + var segs = []; + + if ('.' != path.charAt(0)) return path; + + curr = curr.split('/'); + path = path.split('/'); + + for (var i = 0; i < path.length; ++i) { + if ('..' == path[i]) { + curr.pop(); + } else if ('.' != path[i] && '' != path[i]) { + segs.push(path[i]); + } + } + + return curr.concat(segs).join('/'); +}; + +/** + * Register module at `path` with callback `definition`. + * + * @param {String} path + * @param {Function} definition + * @api private + */ + +require.register = function(path, definition) { + require.modules[path] = definition; +}; + +/** + * Alias a module definition. + * + * @param {String} from + * @param {String} to + * @api private + */ + +require.alias = function(from, to) { + if (!require.modules.hasOwnProperty(from)) { + throw new Error('Failed to alias "' + from + '", it does not exist'); + } + require.aliases[to] = from; +}; + +/** + * Return a require function relative to the `parent` path. + * + * @param {String} parent + * @return {Function} + * @api private + */ + +require.relative = function(parent) { + var p = require.normalize(parent, '..'); + + /** + * lastIndexOf helper. + */ + + function lastIndexOf(arr, obj) { + var i = arr.length; + while (i--) { + if (arr[i] === obj) return i; + } + return -1; + } + + /** + * The relative require() itself. + */ + + function localRequire(path) { + var resolved = localRequire.resolve(path); + return require(resolved, parent, path); + } + + /** + * Resolve relative to the parent. + */ + + localRequire.resolve = function(path) { + var c = path.charAt(0); + if ('/' == c) return path.slice(1); + if ('.' == c) return require.normalize(p, path); + + // resolve deps by returning + // the dep in the nearest "deps" + // directory + var segs = parent.split('/'); + var i = lastIndexOf(segs, 'deps') + 1; + if (!i) i = 0; + path = segs.slice(0, i + 1).join('/') + '/deps/' + path; + return path; + }; + + /** + * Check if module is defined at `path`. + */ + + localRequire.exists = function(path) { + return require.modules.hasOwnProperty(localRequire.resolve(path)); + }; + + return localRequire; +}; +require.register("isarray/index.js", function(exports, require, module){ +module.exports = Array.isArray || function (arr) { + return Object.prototype.toString.call(arr) == '[object Array]'; +}; + +}); +require.alias("isarray/index.js", "isarray/index.js"); + diff --git a/node_modules/mysql/node_modules/readable-stream/node_modules/isarray/component.json b/node_modules/mysql/node_modules/readable-stream/node_modules/isarray/component.json new file mode 100644 index 0000000..9e31b68 --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/node_modules/isarray/component.json @@ -0,0 +1,19 @@ +{ + "name" : "isarray", + "description" : "Array#isArray for older browsers", + "version" : "0.0.1", + "repository" : "juliangruber/isarray", + "homepage": "https://github.com/juliangruber/isarray", + "main" : "index.js", + "scripts" : [ + "index.js" + ], + "dependencies" : {}, + "keywords": ["browser","isarray","array"], + "author": { + "name": "Julian Gruber", + "email": "mail@juliangruber.com", + "url": "http://juliangruber.com" + }, + "license": "MIT" +} diff --git a/node_modules/mysql/node_modules/readable-stream/node_modules/isarray/index.js b/node_modules/mysql/node_modules/readable-stream/node_modules/isarray/index.js new file mode 100644 index 0000000..5f5ad45 --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/node_modules/isarray/index.js @@ -0,0 +1,3 @@ +module.exports = Array.isArray || function (arr) { + return Object.prototype.toString.call(arr) == '[object Array]'; +}; diff --git a/node_modules/mysql/node_modules/readable-stream/node_modules/isarray/package.json b/node_modules/mysql/node_modules/readable-stream/node_modules/isarray/package.json new file mode 100644 index 0000000..fc7904b --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/node_modules/isarray/package.json @@ -0,0 +1,54 @@ +{ + "name": "isarray", + "description": "Array#isArray for older browsers", + "version": "0.0.1", + "repository": { + "type": "git", + "url": "git://github.com/juliangruber/isarray.git" + }, + "homepage": "https://github.com/juliangruber/isarray", + "main": "index.js", + "scripts": { + "test": "tap test/*.js" + }, + "dependencies": {}, + "devDependencies": { + "tap": "*" + }, + "keywords": [ + "browser", + "isarray", + "array" + ], + "author": { + "name": "Julian Gruber", + "email": "mail@juliangruber.com", + "url": "http://juliangruber.com" + }, + "license": "MIT", + "readme": "\n# isarray\n\n`Array#isArray` for older browsers.\n\n## Usage\n\n```js\nvar isArray = require('isarray');\n\nconsole.log(isArray([])); // => true\nconsole.log(isArray({})); // => false\n```\n\n## Installation\n\nWith [npm](http://npmjs.org) do\n\n```bash\n$ npm install isarray\n```\n\nThen bundle for the browser with\n[browserify](https://github.com/substack/browserify).\n\nWith [component](http://component.io) do\n\n```bash\n$ component install juliangruber/isarray\n```\n\n## License\n\n(MIT)\n\nCopyright (c) 2013 Julian Gruber <julian@juliangruber.com>\n\nPermission is hereby granted, free of charge, to any person obtaining a copy of\nthis software and associated documentation files (the \"Software\"), to deal in\nthe Software without restriction, including without limitation the rights to\nuse, copy, modify, merge, publish, distribute, sublicense, and/or sell copies\nof the Software, and to permit persons to whom the Software is furnished to do\nso, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.\n", + "readmeFilename": "README.md", + "_id": "isarray@0.0.1", + "dist": { + "shasum": "8a18acfca9a8f4177e09abfc6038939b05d1eedf", + "tarball": "http://registry.npmjs.org/isarray/-/isarray-0.0.1.tgz" + }, + "_from": "isarray@0.0.1", + "_npmVersion": "1.2.18", + "_npmUser": { + "name": "juliangruber", + "email": "julian@juliangruber.com" + }, + "maintainers": [ + { + "name": "juliangruber", + "email": "julian@juliangruber.com" + } + ], + "directories": {}, + "_shasum": "8a18acfca9a8f4177e09abfc6038939b05d1eedf", + "_resolved": "https://registry.npmjs.org/isarray/-/isarray-0.0.1.tgz", + "bugs": { + "url": "https://github.com/juliangruber/isarray/issues" + } +} diff --git a/node_modules/mysql/node_modules/readable-stream/node_modules/string_decoder/.npmignore b/node_modules/mysql/node_modules/readable-stream/node_modules/string_decoder/.npmignore new file mode 100644 index 0000000..206320c --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/node_modules/string_decoder/.npmignore @@ -0,0 +1,2 @@ +build +test diff --git a/node_modules/mysql/node_modules/readable-stream/node_modules/string_decoder/LICENSE b/node_modules/mysql/node_modules/readable-stream/node_modules/string_decoder/LICENSE new file mode 100644 index 0000000..6de584a --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/node_modules/string_decoder/LICENSE @@ -0,0 +1,20 @@ +Copyright Joyent, Inc. and other Node contributors. + +Permission is hereby granted, free of charge, to any person obtaining a +copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to permit +persons to whom the Software is furnished to do so, subject to the +following conditions: + +The above copyright notice and this permission notice shall be included +in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/node_modules/mysql/node_modules/readable-stream/node_modules/string_decoder/README.md b/node_modules/mysql/node_modules/readable-stream/node_modules/string_decoder/README.md new file mode 100644 index 0000000..4d2aa00 --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/node_modules/string_decoder/README.md @@ -0,0 +1,7 @@ +**string_decoder.js** (`require('string_decoder')`) from Node.js core + +Copyright Joyent, Inc. and other Node contributors. See LICENCE file for details. + +Version numbers match the versions found in Node core, e.g. 0.10.24 matches Node 0.10.24, likewise 0.11.10 matches Node 0.11.10. **Prefer the stable version over the unstable.** + +The *build/* directory contains a build script that will scrape the source from the [joyent/node](https://github.com/joyent/node) repo given a specific Node version. \ No newline at end of file diff --git a/node_modules/mysql/node_modules/readable-stream/node_modules/string_decoder/index.js b/node_modules/mysql/node_modules/readable-stream/node_modules/string_decoder/index.js new file mode 100644 index 0000000..b00e54f --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/node_modules/string_decoder/index.js @@ -0,0 +1,221 @@ +// Copyright Joyent, Inc. and other Node contributors. +// +// Permission is hereby granted, free of charge, to any person obtaining a +// copy of this software and associated documentation files (the +// "Software"), to deal in the Software without restriction, including +// without limitation the rights to use, copy, modify, merge, publish, +// distribute, sublicense, and/or sell copies of the Software, and to permit +// persons to whom the Software is furnished to do so, subject to the +// following conditions: +// +// The above copyright notice and this permission notice shall be included +// in all copies or substantial portions of the Software. +// +// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN +// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, +// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR +// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE +// USE OR OTHER DEALINGS IN THE SOFTWARE. + +var Buffer = require('buffer').Buffer; + +var isBufferEncoding = Buffer.isEncoding + || function(encoding) { + switch (encoding && encoding.toLowerCase()) { + case 'hex': case 'utf8': case 'utf-8': case 'ascii': case 'binary': case 'base64': case 'ucs2': case 'ucs-2': case 'utf16le': case 'utf-16le': case 'raw': return true; + default: return false; + } + } + + +function assertEncoding(encoding) { + if (encoding && !isBufferEncoding(encoding)) { + throw new Error('Unknown encoding: ' + encoding); + } +} + +// StringDecoder provides an interface for efficiently splitting a series of +// buffers into a series of JS strings without breaking apart multi-byte +// characters. CESU-8 is handled as part of the UTF-8 encoding. +// +// @TODO Handling all encodings inside a single object makes it very difficult +// to reason about this code, so it should be split up in the future. +// @TODO There should be a utf8-strict encoding that rejects invalid UTF-8 code +// points as used by CESU-8. +var StringDecoder = exports.StringDecoder = function(encoding) { + this.encoding = (encoding || 'utf8').toLowerCase().replace(/[-_]/, ''); + assertEncoding(encoding); + switch (this.encoding) { + case 'utf8': + // CESU-8 represents each of Surrogate Pair by 3-bytes + this.surrogateSize = 3; + break; + case 'ucs2': + case 'utf16le': + // UTF-16 represents each of Surrogate Pair by 2-bytes + this.surrogateSize = 2; + this.detectIncompleteChar = utf16DetectIncompleteChar; + break; + case 'base64': + // Base-64 stores 3 bytes in 4 chars, and pads the remainder. + this.surrogateSize = 3; + this.detectIncompleteChar = base64DetectIncompleteChar; + break; + default: + this.write = passThroughWrite; + return; + } + + // Enough space to store all bytes of a single character. UTF-8 needs 4 + // bytes, but CESU-8 may require up to 6 (3 bytes per surrogate). + this.charBuffer = new Buffer(6); + // Number of bytes received for the current incomplete multi-byte character. + this.charReceived = 0; + // Number of bytes expected for the current incomplete multi-byte character. + this.charLength = 0; +}; + + +// write decodes the given buffer and returns it as JS string that is +// guaranteed to not contain any partial multi-byte characters. Any partial +// character found at the end of the buffer is buffered up, and will be +// returned when calling write again with the remaining bytes. +// +// Note: Converting a Buffer containing an orphan surrogate to a String +// currently works, but converting a String to a Buffer (via `new Buffer`, or +// Buffer#write) will replace incomplete surrogates with the unicode +// replacement character. See https://codereview.chromium.org/121173009/ . +StringDecoder.prototype.write = function(buffer) { + var charStr = ''; + // if our last write ended with an incomplete multibyte character + while (this.charLength) { + // determine how many remaining bytes this buffer has to offer for this char + var available = (buffer.length >= this.charLength - this.charReceived) ? + this.charLength - this.charReceived : + buffer.length; + + // add the new bytes to the char buffer + buffer.copy(this.charBuffer, this.charReceived, 0, available); + this.charReceived += available; + + if (this.charReceived < this.charLength) { + // still not enough chars in this buffer? wait for more ... + return ''; + } + + // remove bytes belonging to the current character from the buffer + buffer = buffer.slice(available, buffer.length); + + // get the character that was split + charStr = this.charBuffer.slice(0, this.charLength).toString(this.encoding); + + // CESU-8: lead surrogate (D800-DBFF) is also the incomplete character + var charCode = charStr.charCodeAt(charStr.length - 1); + if (charCode >= 0xD800 && charCode <= 0xDBFF) { + this.charLength += this.surrogateSize; + charStr = ''; + continue; + } + this.charReceived = this.charLength = 0; + + // if there are no more bytes in this buffer, just emit our char + if (buffer.length === 0) { + return charStr; + } + break; + } + + // determine and set charLength / charReceived + this.detectIncompleteChar(buffer); + + var end = buffer.length; + if (this.charLength) { + // buffer the incomplete character bytes we got + buffer.copy(this.charBuffer, 0, buffer.length - this.charReceived, end); + end -= this.charReceived; + } + + charStr += buffer.toString(this.encoding, 0, end); + + var end = charStr.length - 1; + var charCode = charStr.charCodeAt(end); + // CESU-8: lead surrogate (D800-DBFF) is also the incomplete character + if (charCode >= 0xD800 && charCode <= 0xDBFF) { + var size = this.surrogateSize; + this.charLength += size; + this.charReceived += size; + this.charBuffer.copy(this.charBuffer, size, 0, size); + buffer.copy(this.charBuffer, 0, 0, size); + return charStr.substring(0, end); + } + + // or just emit the charStr + return charStr; +}; + +// detectIncompleteChar determines if there is an incomplete UTF-8 character at +// the end of the given buffer. If so, it sets this.charLength to the byte +// length that character, and sets this.charReceived to the number of bytes +// that are available for this character. +StringDecoder.prototype.detectIncompleteChar = function(buffer) { + // determine how many bytes we have to check at the end of this buffer + var i = (buffer.length >= 3) ? 3 : buffer.length; + + // Figure out if one of the last i bytes of our buffer announces an + // incomplete char. + for (; i > 0; i--) { + var c = buffer[buffer.length - i]; + + // See http://en.wikipedia.org/wiki/UTF-8#Description + + // 110XXXXX + if (i == 1 && c >> 5 == 0x06) { + this.charLength = 2; + break; + } + + // 1110XXXX + if (i <= 2 && c >> 4 == 0x0E) { + this.charLength = 3; + break; + } + + // 11110XXX + if (i <= 3 && c >> 3 == 0x1E) { + this.charLength = 4; + break; + } + } + this.charReceived = i; +}; + +StringDecoder.prototype.end = function(buffer) { + var res = ''; + if (buffer && buffer.length) + res = this.write(buffer); + + if (this.charReceived) { + var cr = this.charReceived; + var buf = this.charBuffer; + var enc = this.encoding; + res += buf.slice(0, cr).toString(enc); + } + + return res; +}; + +function passThroughWrite(buffer) { + return buffer.toString(this.encoding); +} + +function utf16DetectIncompleteChar(buffer) { + this.charReceived = buffer.length % 2; + this.charLength = this.charReceived ? 2 : 0; +} + +function base64DetectIncompleteChar(buffer) { + this.charReceived = buffer.length % 3; + this.charLength = this.charReceived ? 3 : 0; +} diff --git a/node_modules/mysql/node_modules/readable-stream/node_modules/string_decoder/package.json b/node_modules/mysql/node_modules/readable-stream/node_modules/string_decoder/package.json new file mode 100644 index 0000000..a8c586b --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/node_modules/string_decoder/package.json @@ -0,0 +1,54 @@ +{ + "name": "string_decoder", + "version": "0.10.31", + "description": "The string_decoder module from Node core", + "main": "index.js", + "dependencies": {}, + "devDependencies": { + "tap": "~0.4.8" + }, + "scripts": { + "test": "tap test/simple/*.js" + }, + "repository": { + "type": "git", + "url": "git://github.com/rvagg/string_decoder.git" + }, + "homepage": "https://github.com/rvagg/string_decoder", + "keywords": [ + "string", + "decoder", + "browser", + "browserify" + ], + "license": "MIT", + "gitHead": "d46d4fd87cf1d06e031c23f1ba170ca7d4ade9a0", + "bugs": { + "url": "https://github.com/rvagg/string_decoder/issues" + }, + "_id": "string_decoder@0.10.31", + "_shasum": "62e203bc41766c6c28c9fc84301dab1c5310fa94", + "_from": "string_decoder@~0.10.x", + "_npmVersion": "1.4.23", + "_npmUser": { + "name": "rvagg", + "email": "rod@vagg.org" + }, + "maintainers": [ + { + "name": "substack", + "email": "mail@substack.net" + }, + { + "name": "rvagg", + "email": "rod@vagg.org" + } + ], + "dist": { + "shasum": "62e203bc41766c6c28c9fc84301dab1c5310fa94", + "tarball": "http://registry.npmjs.org/string_decoder/-/string_decoder-0.10.31.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-0.10.31.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/mysql/node_modules/readable-stream/package.json b/node_modules/mysql/node_modules/readable-stream/package.json new file mode 100644 index 0000000..bd72748 --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/package.json @@ -0,0 +1,70 @@ +{ + "name": "readable-stream", + "version": "1.1.13", + "description": "Streams3, a user-land copy of the stream library from Node.js v0.11.x", + "main": "readable.js", + "dependencies": { + "core-util-is": "~1.0.0", + "isarray": "0.0.1", + "string_decoder": "~0.10.x", + "inherits": "~2.0.1" + }, + "devDependencies": { + "tap": "~0.2.6" + }, + "scripts": { + "test": "tap test/simple/*.js" + }, + "repository": { + "type": "git", + "url": "git://github.com/isaacs/readable-stream" + }, + "keywords": [ + "readable", + "stream", + "pipe" + ], + "browser": { + "util": false + }, + "author": { + "name": "Isaac Z. Schlueter", + "email": "i@izs.me", + "url": "http://blog.izs.me/" + }, + "license": "MIT", + "gitHead": "3b672fd7ae92acf5b4ffdbabf74b372a0a56b051", + "bugs": { + "url": "https://github.com/isaacs/readable-stream/issues" + }, + "homepage": "https://github.com/isaacs/readable-stream", + "_id": "readable-stream@1.1.13", + "_shasum": "f6eef764f514c89e2b9e23146a75ba106756d23e", + "_from": "readable-stream@1.1.13", + "_npmVersion": "1.4.23", + "_npmUser": { + "name": "rvagg", + "email": "rod@vagg.org" + }, + "maintainers": [ + { + "name": "isaacs", + "email": "i@izs.me" + }, + { + "name": "tootallnate", + "email": "nathan@tootallnate.net" + }, + { + "name": "rvagg", + "email": "rod@vagg.org" + } + ], + "dist": { + "shasum": "f6eef764f514c89e2b9e23146a75ba106756d23e", + "tarball": "http://registry.npmjs.org/readable-stream/-/readable-stream-1.1.13.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-1.1.13.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/mysql/node_modules/readable-stream/passthrough.js b/node_modules/mysql/node_modules/readable-stream/passthrough.js new file mode 100644 index 0000000..27e8d8a --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/passthrough.js @@ -0,0 +1 @@ +module.exports = require("./lib/_stream_passthrough.js") diff --git a/node_modules/mysql/node_modules/readable-stream/readable.js b/node_modules/mysql/node_modules/readable-stream/readable.js new file mode 100644 index 0000000..09b8bf5 --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/readable.js @@ -0,0 +1,7 @@ +exports = module.exports = require('./lib/_stream_readable.js'); +exports.Stream = require('stream'); +exports.Readable = exports; +exports.Writable = require('./lib/_stream_writable.js'); +exports.Duplex = require('./lib/_stream_duplex.js'); +exports.Transform = require('./lib/_stream_transform.js'); +exports.PassThrough = require('./lib/_stream_passthrough.js'); diff --git a/node_modules/mysql/node_modules/readable-stream/transform.js b/node_modules/mysql/node_modules/readable-stream/transform.js new file mode 100644 index 0000000..5d482f0 --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/transform.js @@ -0,0 +1 @@ +module.exports = require("./lib/_stream_transform.js") diff --git a/node_modules/mysql/node_modules/readable-stream/writable.js b/node_modules/mysql/node_modules/readable-stream/writable.js new file mode 100644 index 0000000..e1e9efd --- /dev/null +++ b/node_modules/mysql/node_modules/readable-stream/writable.js @@ -0,0 +1 @@ +module.exports = require("./lib/_stream_writable.js") diff --git a/node_modules/mysql/node_modules/require-all/.npmignore b/node_modules/mysql/node_modules/require-all/.npmignore new file mode 100644 index 0000000..b95d33c --- /dev/null +++ b/node_modules/mysql/node_modules/require-all/.npmignore @@ -0,0 +1,2 @@ +*.un~ +node_modules/ \ No newline at end of file diff --git a/node_modules/mysql/node_modules/require-all/License b/node_modules/mysql/node_modules/require-all/License new file mode 100644 index 0000000..143bad2 --- /dev/null +++ b/node_modules/mysql/node_modules/require-all/License @@ -0,0 +1,19 @@ +Copyright (c) 2012 Felix Geisendörfer (felix@debuggable.com) and 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. \ No newline at end of file diff --git a/node_modules/mysql/node_modules/require-all/Readme.md b/node_modules/mysql/node_modules/require-all/Readme.md new file mode 100644 index 0000000..fce0a7b --- /dev/null +++ b/node_modules/mysql/node_modules/require-all/Readme.md @@ -0,0 +1,25 @@ +# require-all + +An easy way to require all files within a directory. + +## Usage + +```js +var controllers = require('require-all')({ + dirname : __dirname + '/controllers', + filter : /(.+Controller)\.js$/, + excludeDirs : /^\.(git|svn)$/ +}); + +// controllers now is an object with references to all modules matching the filter +// for example: +// { HomeController: function HomeController() {...}, ...} +``` + +## Advanced usage + +If your objective is to simply require all .js and .json files in a directory you can just pass a string to require-all: + +``` js +var libs = require('require-all')(__dirname + '/lib'); +``` diff --git a/node_modules/mysql/node_modules/require-all/index.js b/node_modules/mysql/node_modules/require-all/index.js new file mode 100644 index 0000000..b7e1d04 --- /dev/null +++ b/node_modules/mysql/node_modules/require-all/index.js @@ -0,0 +1,40 @@ +var fs = require('fs'); + +module.exports = function requireAll(options) { + if (typeof options === 'string') { + options = { + dirname: options, + filter: /(.+)\.js(on)?$/, + excludeDirs: /^\.(git|svn)$/ + }; + } + + var files = fs.readdirSync(options.dirname); + var modules = {}; + + function excludeDirectory(dirname) { + return options.excludeDirs && dirname.match(options.excludeDirs); + } + + files.forEach(function (file) { + var filepath = options.dirname + '/' + file; + if (fs.statSync(filepath).isDirectory()) { + + if (excludeDirectory(file)) return; + + modules[file] = requireAll({ + dirname: filepath, + filter: options.filter, + excludeDirs: options.excludeDirs + }); + + } else { + var match = file.match(options.filter); + if (!match) return; + + modules[match[1]] = require(filepath); + } + }); + + return modules; +}; diff --git a/node_modules/mysql/node_modules/require-all/package.json b/node_modules/mysql/node_modules/require-all/package.json new file mode 100644 index 0000000..c7667e8 --- /dev/null +++ b/node_modules/mysql/node_modules/require-all/package.json @@ -0,0 +1,65 @@ +{ + "author": { + "name": "Felix Geisendörfer", + "email": "felix@debuggable.com", + "url": "http://debuggable.com/" + }, + "name": "require-all", + "description": "An easy way to require all files within a directory.", + "version": "0.0.8", + "scripts": { + "test": "node test/test.js" + }, + "repository": { + "type": "git", + "url": "git://github.com/felixge/node-require-all.git" + }, + "licenses": [ + { + "type": "MIT", + "url": "https://github.com/felixge/node-require-all/blob/master/License" + } + ], + "main": "./index", + "engines": { + "node": "*" + }, + "dependencies": {}, + "devDependencies": { + "semver": "~2.1.0" + }, + "optionalDependencies": {}, + "readme": "# require-all\n\nAn easy way to require all files within a directory.\n\n## Usage\n\n```js\nvar controllers = require('require-all')({\n dirname : __dirname + '/controllers',\n filter : /(.+Controller)\\.js$/,\n excludeDirs : /^\\.(git|svn)$/\n});\n\n// controllers now is an object with references to all modules matching the filter\n// for example:\n// { HomeController: function HomeController() {...}, ...}\n```\n\n## Advanced usage\n\nIf your objective is to simply require all .js and .json files in a directory you can just pass a string to require-all:\n\n``` js\nvar libs = require('require-all')(__dirname + '/lib');\n```\n", + "readmeFilename": "Readme.md", + "bugs": { + "url": "https://github.com/felixge/node-require-all/issues" + }, + "_id": "require-all@0.0.8", + "dist": { + "shasum": "a7d4307d90e422fcb9f04af018c149920074e4b3", + "tarball": "http://registry.npmjs.org/require-all/-/require-all-0.0.8.tgz" + }, + "_from": "require-all@0.0.8", + "_npmVersion": "1.2.32", + "_npmUser": { + "name": "dscape", + "email": "nunojobpinto@gmail.com" + }, + "maintainers": [ + { + "name": "felixge", + "email": "felix@debuggable.com" + }, + { + "name": "thlorenz", + "email": "thlorenz@gmx.de" + }, + { + "name": "dscape", + "email": "nunojobpinto@gmail.com" + } + ], + "directories": {}, + "_shasum": "a7d4307d90e422fcb9f04af018c149920074e4b3", + "_resolved": "https://registry.npmjs.org/require-all/-/require-all-0.0.8.tgz" +} diff --git a/node_modules/mysql/node_modules/require-all/test/controllers/main-Controller.js b/node_modules/mysql/node_modules/require-all/test/controllers/main-Controller.js new file mode 100644 index 0000000..355ce40 --- /dev/null +++ b/node_modules/mysql/node_modules/require-all/test/controllers/main-Controller.js @@ -0,0 +1,4 @@ +exports.index = 1; +exports.show = 2; +exports.add = 3; +exports.edit = 4; diff --git a/node_modules/mysql/node_modules/require-all/test/controllers/notthis.js b/node_modules/mysql/node_modules/require-all/test/controllers/notthis.js new file mode 100644 index 0000000..8ac88c5 --- /dev/null +++ b/node_modules/mysql/node_modules/require-all/test/controllers/notthis.js @@ -0,0 +1 @@ +exports.yes = 'no'; diff --git a/node_modules/mysql/node_modules/require-all/test/controllers/other-Controller.js b/node_modules/mysql/node_modules/require-all/test/controllers/other-Controller.js new file mode 100644 index 0000000..aec8f24 --- /dev/null +++ b/node_modules/mysql/node_modules/require-all/test/controllers/other-Controller.js @@ -0,0 +1,2 @@ +exports.index = 1; +exports.show = 'nothing' diff --git a/node_modules/mysql/node_modules/require-all/test/filterdir/root.js b/node_modules/mysql/node_modules/require-all/test/filterdir/root.js new file mode 100644 index 0000000..c9fd536 --- /dev/null +++ b/node_modules/mysql/node_modules/require-all/test/filterdir/root.js @@ -0,0 +1 @@ +module.exports = { guten: 'tag' }; diff --git a/node_modules/mysql/node_modules/require-all/test/filterdir/sub/hello.js b/node_modules/mysql/node_modules/require-all/test/filterdir/sub/hello.js new file mode 100644 index 0000000..0174eea --- /dev/null +++ b/node_modules/mysql/node_modules/require-all/test/filterdir/sub/hello.js @@ -0,0 +1 @@ +module.exports = { guten: 'abend' }; diff --git a/node_modules/mysql/node_modules/require-all/test/mydir/foo.js b/node_modules/mysql/node_modules/require-all/test/mydir/foo.js new file mode 100644 index 0000000..cb1c2c0 --- /dev/null +++ b/node_modules/mysql/node_modules/require-all/test/mydir/foo.js @@ -0,0 +1 @@ +module.exports = 'bar'; diff --git a/node_modules/mysql/node_modules/require-all/test/mydir/hello.js b/node_modules/mysql/node_modules/require-all/test/mydir/hello.js new file mode 100644 index 0000000..b1d17c1 --- /dev/null +++ b/node_modules/mysql/node_modules/require-all/test/mydir/hello.js @@ -0,0 +1,2 @@ +exports.world = true; +exports.universe = 42; diff --git a/node_modules/mysql/node_modules/require-all/test/mydir/sub/config.json b/node_modules/mysql/node_modules/require-all/test/mydir/sub/config.json new file mode 100644 index 0000000..d2b5939 --- /dev/null +++ b/node_modules/mysql/node_modules/require-all/test/mydir/sub/config.json @@ -0,0 +1,4 @@ +{ + "settingA": "A", + "settingB": "B" +} diff --git a/node_modules/mysql/node_modules/require-all/test/mydir/sub/no.2js b/node_modules/mysql/node_modules/require-all/test/mydir/sub/no.2js new file mode 100644 index 0000000..ec01c2c --- /dev/null +++ b/node_modules/mysql/node_modules/require-all/test/mydir/sub/no.2js @@ -0,0 +1 @@ +module.exports = true; diff --git a/node_modules/mysql/node_modules/require-all/test/mydir/sub/yes.js b/node_modules/mysql/node_modules/require-all/test/mydir/sub/yes.js new file mode 100644 index 0000000..ec01c2c --- /dev/null +++ b/node_modules/mysql/node_modules/require-all/test/mydir/sub/yes.js @@ -0,0 +1 @@ +module.exports = true; diff --git a/node_modules/mysql/node_modules/require-all/test/test.js b/node_modules/mysql/node_modules/require-all/test/test.js new file mode 100644 index 0000000..6c086c4 --- /dev/null +++ b/node_modules/mysql/node_modules/require-all/test/test.js @@ -0,0 +1,82 @@ +var assert = require('assert'); +var semver = require('semver'); +var requireAll = require('..'); + +var controllers = requireAll({ + dirname: __dirname + '/controllers', + filter: /(.+Controller)\.js$/ +}); + +assert.deepEqual(controllers, { + 'main-Controller': { + index: 1, + show: 2, + add: 3, + edit: 4 + }, + + 'other-Controller': { + index: 1, + show: 'nothing' + } +}); + +// +// requiring json only became an option in 0.6+ +// +if (semver.gt(process.version, 'v0.6.0')) { + var mydir = requireAll({ + dirname: __dirname + '/mydir', + filter: /(.+)\.(js|json)$/ + }); + + var mydir_contents = { + foo: 'bar', + hello: { + world: true, + universe: 42 + }, + sub: { + config: { + settingA: 'A', + settingB: 'B' + }, + yes: true + } + }; + + assert.deepEqual(mydir, mydir_contents); + + var defaults = requireAll(__dirname + '/mydir'); + + assert.deepEqual(defaults, mydir_contents); +} + +var unfiltered = requireAll({ + dirname: __dirname + '/filterdir', + filter: /(.+)\.js$/ +}); + +assert(unfiltered['.svn']); +assert(unfiltered.root); +assert(unfiltered.sub); + +var excludedSvn = requireAll({ + dirname: __dirname + '/filterdir', + filter: /(.+)\.js$/, + excludeDirs: /^\.svn$/ +}); + +assert.equal(excludedSvn['.svn'], undefined); +assert.ok(excludedSvn.root); +assert.ok(excludedSvn.sub); + +var excludedSvnAndSub = requireAll({ + dirname: __dirname + '/filterdir', + filter: /(.+)\.js$/, + excludeDirs: /^(\.svn|sub)$/ +}); + +assert.equal(excludedSvnAndSub['.svn'], undefined); +assert.ok(excludedSvnAndSub.root); +assert.equal(excludedSvnAndSub.sub, undefined); diff --git a/node_modules/mysql/package.json b/node_modules/mysql/package.json new file mode 100644 index 0000000..41f8f53 --- /dev/null +++ b/node_modules/mysql/package.json @@ -0,0 +1,106 @@ +{ + "name": "mysql", + "description": "A node.js driver for mysql. It is written in JavaScript, does not require compiling, and is 100% MIT licensed.", + "version": "2.5.0", + "license": "MIT", + "author": { + "name": "Felix Geisendörfer", + "email": "felix@debuggable.com", + "url": "http://debuggable.com/" + }, + "contributors": [ + { + "name": "Andrey Sidorov", + "email": "sidorares@yandex.ru" + }, + { + "name": "Douglas Christopher Wilson", + "email": "doug@somethingdoug.com" + }, + { + "name": "Diogo Resende", + "email": "dresende@thinkdigital.pt" + } + ], + "homepage": "https://github.com/felixge/node-mysql", + "repository": { + "type": "git", + "url": "https://github.com/felixge/node-mysql" + }, + "dependencies": { + "bignumber.js": "1.4.1", + "readable-stream": "~1.1.13", + "require-all": "0.0.8" + }, + "devDependencies": { + "istanbul": "0.3.2", + "rimraf": "2.2.8", + "mkdirp": "0.5.0", + "urun": "0.0.8", + "utest": "0.0.8" + }, + "engines": { + "node": ">= 0.6" + }, + "scripts": { + "test": "node test/run.js", + "test-cov": "node test/run-cov.js", + "test-travis": "node test/run-cov.js lcovonly" + }, + "gitHead": "a4dd3dc5df997093c574300f39a8a4b2a24b34a1", + "bugs": { + "url": "https://github.com/felixge/node-mysql/issues" + }, + "_id": "mysql@2.5.0", + "_shasum": "48557327576f2308729bb3d4a16dd1d3f76ee1d4", + "_from": "mysql@2.5.0", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + "maintainers": [ + { + "name": "felixge", + "email": "felix@debuggable.com" + }, + { + "name": "egorfine", + "email": "me@egorfine.com" + }, + { + "name": "dresende", + "email": "dresende@thinkdigital.pt" + }, + { + "name": "femto113", + "email": "ken.woodruff@gmail.com" + }, + { + "name": "nate.lillich", + "email": "nate@lifewanted.com" + }, + { + "name": "tolgaek", + "email": "tolga.ekmen@gmail.com" + }, + { + "name": "sidorares", + "email": "sidorares@yandex.com" + }, + { + "name": "seanmonstar", + "email": "sean.monstar@gmail.com" + }, + { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + } + ], + "dist": { + "shasum": "48557327576f2308729bb3d4a16dd1d3f76ee1d4", + "tarball": "http://registry.npmjs.org/mysql/-/mysql-2.5.0.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/mysql/-/mysql-2.5.0.tgz" +} diff --git a/node_modules/nodeunit/.npmignore b/node_modules/nodeunit/.npmignore new file mode 100644 index 0000000..1a82501 --- /dev/null +++ b/node_modules/nodeunit/.npmignore @@ -0,0 +1,3 @@ +dist +stamp-build +test/fixtures/dir2 diff --git a/node_modules/nodeunit/CONTRIBUTORS.md b/node_modules/nodeunit/CONTRIBUTORS.md new file mode 100644 index 0000000..fba3609 --- /dev/null +++ b/node_modules/nodeunit/CONTRIBUTORS.md @@ -0,0 +1,68 @@ +Nodeunit contributors (sorted alphabeticaly) +============================================ + +* **[Alex Gorbatchev](https://github.com/alexgorbatchev)** + + * Deeper default object inspection + * Timeout to ensure flushing of console output (default reporter) + +* **[Alex Wolfe](https://github.com/alexkwolfe)** + + * HTML test reporter + +* **[Caolan McMahon](https://github.com/caolan)** + + * Author and maintainer + * Most features develpopment + +* **[Carl Fürstenberg](https://github.com/azatoth)** + + * Debian-friendly Makefile, supports both 'node' and 'nodejs' executables + * Sandbox utility + * Minimal test reporter + +* **[Gerad Suyderhoud](https://github.com/gerad)** + + * First comand-line tool + +* **[Kadir Pekel](https://github.com/kadirpekel)** + + * Improvements to default test reporter + * HTTP test utility + +* **[Λlisue](https://github.com/lambdalisue)** + + * Add machineout reporter + +* **[Matthias Lübken](https://github.com/luebken)** + + * Utility functions for tracking incomplete tests on exit + +* **[Oleg Efimov](https://github.com/Sannis)** + + * Adding 'make lint' and fixing nodelint errors + * Option parsing, --help text and config file support + * Reporters option for command-line tool + +* **[Orlando Vazquez](https://github.com/orlandov)** + + * Added jUnit XML reporter + +* **[Ryan Dahl](https://github.com/ry)** + + * Add package.json + +* **[Sam Stephenson](https://github.com/sstephenson)** + + * Coffee-script support + +* **[Thomas Mayfield](https://github.com/thegreatape)** + + * Async setUp and tearDown support for testCase + +* **[Maciej Małecki](https://github.com/mmalecki)** + + * Removal of `testCase` + +**[Full contributors list](https://github.com/caolan/nodeunit/contributors).** + diff --git a/node_modules/nodeunit/LICENSE b/node_modules/nodeunit/LICENSE new file mode 100644 index 0000000..b7f9d50 --- /dev/null +++ b/node_modules/nodeunit/LICENSE @@ -0,0 +1,19 @@ +Copyright (c) 2010 Caolan McMahon + +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/node_modules/nodeunit/Makefile b/node_modules/nodeunit/Makefile new file mode 100644 index 0000000..8f8d8cb --- /dev/null +++ b/node_modules/nodeunit/Makefile @@ -0,0 +1,177 @@ +PACKAGE = nodeunit +NODEJS = $(if $(shell test -f /usr/bin/nodejs && echo "true"),nodejs,node) + +PREFIX ?= /usr/local +BINDIR ?= $(PREFIX)/bin +DATADIR ?= $(PREFIX)/share +MANDIR ?= $(PREFIX)/share/man +LIBDIR ?= $(PREFIX)/lib +NODEJSLIBDIR ?= $(LIBDIR)/$(NODEJS) + +BUILDDIR = dist + +DOCS = $(shell find doc -name '*.md' \ + |sed 's|.md|.1|g' \ + |sed 's|doc/|man1/|g' \ + ) + + +$(shell if [ ! -d $(BUILDDIR) ]; then mkdir $(BUILDDIR); fi) + +all: build doc + +browser: + # super hacky build script for browser version! + mkdir -p $(BUILDDIR)/browser + rm -rf $(BUILDDIR)/browser/* + # build browser version of nodeunit.js + cat share/license.js >> $(BUILDDIR)/browser/nodeunit.js + echo "nodeunit = (function(){" >> $(BUILDDIR)/browser/nodeunit.js + cat deps/json2.js >> $(BUILDDIR)/browser/nodeunit.js + # make assert global + echo "var assert = this.assert = {};" >> $(BUILDDIR)/browser/nodeunit.js + echo "var types = {};" >> $(BUILDDIR)/browser/nodeunit.js + echo "var core = {};" >> $(BUILDDIR)/browser/nodeunit.js + echo "var nodeunit = {};" >> $(BUILDDIR)/browser/nodeunit.js + echo "var reporter = {};" >> $(BUILDDIR)/browser/nodeunit.js + cat deps/async.js >> $(BUILDDIR)/browser/nodeunit.js + echo "(function(exports){" >> $(BUILDDIR)/browser/nodeunit.js + cat lib/assert.js >> $(BUILDDIR)/browser/nodeunit.js + echo "})(assert);" >> $(BUILDDIR)/browser/nodeunit.js + echo "(function(exports){" >> $(BUILDDIR)/browser/nodeunit.js + cat lib/types.js >> $(BUILDDIR)/browser/nodeunit.js + echo "})(types);" >> $(BUILDDIR)/browser/nodeunit.js + echo "(function(exports){" >> $(BUILDDIR)/browser/nodeunit.js + cat lib/core.js >> $(BUILDDIR)/browser/nodeunit.js + echo "})(core);" >> $(BUILDDIR)/browser/nodeunit.js + echo "(function(exports){" >> $(BUILDDIR)/browser/nodeunit.js + cat lib/reporters/browser.js >> $(BUILDDIR)/browser/nodeunit.js + echo "})(reporter);" >> $(BUILDDIR)/browser/nodeunit.js + echo "nodeunit = core;" >> $(BUILDDIR)/browser/nodeunit.js + echo "nodeunit.assert = assert;" >> $(BUILDDIR)/browser/nodeunit.js + echo "nodeunit.reporter = reporter;" >> $(BUILDDIR)/browser/nodeunit.js + echo "nodeunit.run = reporter.run;" >> $(BUILDDIR)/browser/nodeunit.js + echo "return nodeunit; })();" >> $(BUILDDIR)/browser/nodeunit.js + cp $(BUILDDIR)/browser/nodeunit.js $(BUILDDIR)/browser/.nodeunit.js + sed "/\@REMOVE_LINE_FOR_BROWSER/d" <$(BUILDDIR)/browser/.nodeunit.js > $(BUILDDIR)/browser/nodeunit.js + rm $(BUILDDIR)/browser/.nodeunit.js + # copy nodeunit.css + cp share/nodeunit.css $(BUILDDIR)/browser/nodeunit.css + # create nodeunit.min.js + node_modules/uglify-js/bin/uglifyjs $(BUILDDIR)/browser/nodeunit.js > $(BUILDDIR)/browser/nodeunit.min.js + # create test scripts + mkdir -p $(BUILDDIR)/browser/test + cp test/test.html $(BUILDDIR)/browser/test/test.html + # test-base.js + echo "(function (exports) {" > $(BUILDDIR)/browser/test/test-base.js + cat test/test-base.js >> $(BUILDDIR)/browser/test/test-base.js + echo "})(this.test_base = {});" >> $(BUILDDIR)/browser/test/test-base.js + cp $(BUILDDIR)/browser/test/test-base.js $(BUILDDIR)/browser/.test-base.js + sed "/\@REMOVE_LINE_FOR_BROWSER/d" <$(BUILDDIR)/browser/.test-base.js > $(BUILDDIR)/browser/test/test-base.js + rm $(BUILDDIR)/browser/.test-base.js + # test-runmodule.js + echo "(function (exports) {" > $(BUILDDIR)/browser/test/test-runmodule.js + cat test/test-runmodule.js >> $(BUILDDIR)/browser/test/test-runmodule.js + echo "})(this.test_runmodule = {});" >> $(BUILDDIR)/browser/test/test-runmodule.js + cp $(BUILDDIR)/browser/test/test-runmodule.js $(BUILDDIR)/browser/.test-runmodule.js + sed "/\@REMOVE_LINE_FOR_BROWSER/d" <$(BUILDDIR)/browser/.test-runmodule.js > $(BUILDDIR)/browser/test/test-runmodule.js + rm $(BUILDDIR)/browser/.test-runmodule.js + # test-runtest.js + echo "(function (exports) {" > $(BUILDDIR)/browser/test/test-runtest.js + cat test/test-runtest.js >> $(BUILDDIR)/browser/test/test-runtest.js + echo "})(this.test_runtest = {});" >> $(BUILDDIR)/browser/test/test-runtest.js + cp $(BUILDDIR)/browser/test/test-runtest.js $(BUILDDIR)/browser/.test-runtest.js + sed "/\@REMOVE_LINE_FOR_BROWSER/d" <$(BUILDDIR)/browser/.test-runtest.js > $(BUILDDIR)/browser/test/test-runtest.js + rm $(BUILDDIR)/browser/.test-runtest.js + # test-testcase.js + echo "(function (exports) {" > $(BUILDDIR)/browser/test/test-testcase.js + cat test/test-testcase.js >> $(BUILDDIR)/browser/test/test-testcase.js + echo "})(this.test_testcase = {});" >> $(BUILDDIR)/browser/test/test-testcase.js + cp $(BUILDDIR)/browser/test/test-testcase.js $(BUILDDIR)/browser/.test-testcase.js + sed "/\@REMOVE_LINE_FOR_BROWSER/d" <$(BUILDDIR)/browser/.test-testcase.js > $(BUILDDIR)/browser/test/test-testcase.js + rm $(BUILDDIR)/browser/.test-testcase.js + # test-testcase-legacy.js + echo "(function (exports) {" > $(BUILDDIR)/browser/test/test-testcase-legacy.js + cat test/test-testcase-legacy.js >> $(BUILDDIR)/browser/test/test-testcase-legacy.js + echo "})(this.test_testcase_legacy = {});" >> $(BUILDDIR)/browser/test/test-testcase-legacy.js + cp $(BUILDDIR)/browser/test/test-testcase-legacy.js $(BUILDDIR)/browser/.test-testcase-legacy.js + sed "/\@REMOVE_LINE_FOR_BROWSER/d" <$(BUILDDIR)/browser/.test-testcase-legacy.js > $(BUILDDIR)/browser/test/test-testcase-legacy.js + rm $(BUILDDIR)/browser/.test-testcase-legacy.js + # copy nodeunit.js to dist/browser/test to make it easier for me to host and + # run on windows VMs with IE + cp $(BUILDDIR)/browser/nodeunit.js $(BUILDDIR)/browser/test/nodeunit.js + cp $(BUILDDIR)/browser/nodeunit.css $(BUILDDIR)/browser/test/nodeunit.css + +commonjs: + # super hacky build script for browser commonjs version! + ##### make commonjs browser module ###### + mkdir -p $(BUILDDIR)/commonjs + rm -rf $(BUILDDIR)/commonjs/* + mkdir -p $(BUILDDIR)/commonjs/deps + cp deps/json2.js $(BUILDDIR)/commonjs/deps + cp deps/async.js $(BUILDDIR)/commonjs/deps + echo "var async = require('async');" >> $(BUILDDIR)/commonjs/nodeunit.js + echo "var assert = {};" >> $(BUILDDIR)/commonjs/nodeunit.js + echo "var types = {};" >> $(BUILDDIR)/commonjs/nodeunit.js + echo "var core = {};" >> $(BUILDDIR)/commonjs/nodeunit.js + echo "var nodeunit = {};" >> $(BUILDDIR)/commonjs/nodeunit.js + echo "var reporter = {};" >> $(BUILDDIR)/commonjs/nodeunit.js + echo "(function(exports){" >> $(BUILDDIR)/commonjs/nodeunit.js + cat lib/assert.js >> $(BUILDDIR)/commonjs/nodeunit.js + echo "})(assert);" >> $(BUILDDIR)/commonjs/nodeunit.js + echo "(function(exports){" >> $(BUILDDIR)/commonjs/nodeunit.js + cat lib/types.js >> $(BUILDDIR)/commonjs/nodeunit.js + echo "})(types);" >> $(BUILDDIR)/commonjs/nodeunit.js + echo "(function(exports){" >> $(BUILDDIR)/commonjs/nodeunit.js + cat lib/core.js >> $(BUILDDIR)/commonjs/nodeunit.js + echo "})(core);" >> $(BUILDDIR)/commonjs/nodeunit.js + echo "module.exports = core;" >> $(BUILDDIR)/commonjs/nodeunit.js + echo "(function(exports, nodeunit){" >> $(BUILDDIR)/commonjs/nodeunit.js + cat lib/reporters/browser.js >> $(BUILDDIR)/commonjs/nodeunit.js + echo "})(reporter, module.exports);" >> $(BUILDDIR)/commonjs/nodeunit.js + echo "module.exports.assert = assert;" >> $(BUILDDIR)/commonjs/nodeunit.js + echo "module.exports.reporter = reporter;" >> $(BUILDDIR)/commonjs/nodeunit.js + echo "module.exports.run = reporter.run;" >> $(BUILDDIR)/commonjs/nodeunit.js + sed -i "/\@REMOVE_LINE_FOR_BROWSER/d" $(BUILDDIR)/commonjs/nodeunit.js + sed -i "/\@REMOVE_LINE_FOR_COMMONJS/d" $(BUILDDIR)/commonjs/nodeunit.js + ##### end of commonjs browser module ##### + +build: stamp-build + +stamp-build: $(wildcard deps/* lib/*.js) + touch $@; + mkdir -p $(BUILDDIR)/nodeunit + cp -R bin node_modules deps index.js lib package.json share $(BUILDDIR)/nodeunit + printf '#!/bin/sh\n$(NODEJS) $(NODEJSLIBDIR)/$(PACKAGE)/bin/nodeunit $$@' > $(BUILDDIR)/nodeunit.sh + +test: + $(NODEJS) ./bin/nodeunit test + +install: build + install -d $(NODEJSLIBDIR) + cp -a $(BUILDDIR)/nodeunit $(NODEJSLIBDIR) + install -m 0755 $(BUILDDIR)/nodeunit.sh $(BINDIR)/nodeunit + install -d $(MANDIR)/man1/ + cp -a man1/nodeunit.1 $(MANDIR)/man1/ + +uninstall: + rm -rf $(NODEJSLIBDIR)/nodeunit $(NODEJSLIBDIR)/nodeunit.js $(BINDIR)/nodeunit + rm -rf $(MANDIR)/man1/nodeunit.1 + +clean: + rm -rf $(BUILDDIR) stamp-build + +lint: + nodelint --config nodelint.cfg ./index.js ./bin/nodeunit ./bin/nodeunit.json ./lib/*.js ./lib/reporters/*.js ./test/*.js + +doc: man1 $(DOCS) + @true + +man1: + @if ! test -d man1 ; then mkdir -p man1 ; fi + +# use `npm install ronn` for this to work. +man1/%.1: doc/%.md + ronn --roff $< > $@ + +.PHONY: browser test install uninstall build all diff --git a/node_modules/nodeunit/README.md b/node_modules/nodeunit/README.md new file mode 100644 index 0000000..43605b1 --- /dev/null +++ b/node_modules/nodeunit/README.md @@ -0,0 +1,468 @@ +Nodeunit +======== + +Simple syntax, powerful tools. Nodeunit provides easy async unit testing for +node.js and the browser. + +* Simple to use +* Just export the tests from a module +* Works with node.js and in the browser +* Helps you avoid common pitfalls when testing asynchronous code +* Easy to add test cases with setUp and tearDown functions if you wish +* Flexible reporters for custom output, built-in support for HTML and jUnit XML +* Allows the use of mocks and stubs + +__Contributors__ + +* [alexgorbatchev](https://github.com/alexgorbatchev) +* [alexkwolfe](https://github.com/alexkwolfe) +* [azatoth](https://github.com/azatoth) +* [kadirpekel](https://github.com/kadirpekel) +* [lambdalisue](https://github.com/lambdalisue) +* [luebken](https://github.com/luebken) +* [orlandov](https://github.com/orlandov) +* [Sannis](https://github.com/Sannis) +* [sstephenson](https://github.com/sstephenson) +* [thegreatape](https://github.com/thegreatape) +* [mmalecki](https://github.com/mmalecki) +* and thanks to [cjohansen](https://github.com/cjohansen) for input and advice + on implementing setUp and tearDown functions. See + [cjohansen's fork](https://github.com/cjohansen/nodeunit). + +Also, check out gerad's [nodeunit-dsl](https://github.com/gerad/nodeunit-dsl) +project, which implements a 'pretty dsl on top of nodeunit'. + +More contributor information can be found in the +[CONTRIBUTORS.md](https://github.com/caolan/nodeunit/blob/master/CONTRIBUTORS.md) +file. + +Usage +----- + +Here is an example unit test module: + + exports.testSomething = function(test){ + test.expect(1); + test.ok(true, "this assertion should pass"); + test.done(); + }; + + exports.testSomethingElse = function(test){ + test.ok(false, "this assertion should fail"); + test.done(); + }; + +When run using the included test runner, this will output the following: + + + +Installation +------------ + +There are two options for installing nodeunit: + +1. Clone / download nodeunit from [github](https://github.com/caolan/nodeunit), + then: + + make && sudo make install + +2. Install via npm: + + npm install nodeunit -g + +API Documentation +----------------- + +Nodeunit uses the functions available in the node.js +[assert module](http://nodejs.org/docs/v0.4.2/api/assert.html): + +* __ok(value, [message])__ - Tests if value is a true value. +* __equal(actual, expected, [message])__ - Tests shallow, coercive equality + with the equal comparison operator ( == ). +* __notEqual(actual, expected, [message])__ - Tests shallow, coercive + non-equality with the not equal comparison operator ( != ). +* __deepEqual(actual, expected, [message])__ - Tests for deep equality. +* __notDeepEqual(actual, expected, [message])__ - Tests for any deep + inequality. +* __strictEqual(actual, expected, [message])__ - Tests strict equality, as + determined by the strict equality operator ( === ) +* __notStrictEqual(actual, expected, [message])__ - Tests strict non-equality, + as determined by the strict not equal operator ( !== ) +* __throws(block, [error], [message])__ - Expects block to throw an error. +* __doesNotThrow(block, [error], [message])__ - Expects block not to throw an + error. +* __ifError(value)__ - Tests if value is not a false value, throws if it is a + true value. Useful when testing the first argument, error in callbacks. + +Nodeunit also provides the following functions within tests: + +* __expect(amount)__ - Specify how many assertions are expected to run within a + test. Very useful for ensuring that all your callbacks and assertions are + run. +* __done()__ - Finish the current test function, and move on to the next. ALL + tests should call this! + +Nodeunit aims to be simple and easy to learn. This is achieved through using +existing structures (such as node.js modules) to maximum effect, and reducing +the API where possible, to make it easier to digest. + +Tests are simply exported from a module, but they are still run in the order +they are defined. + +__Note:__ Users of old nodeunit versions may remember using `ok`, `equals` and +`same` in the style of qunit, instead of the assert functions above. These +functions still exist for backwards compatibility, and are simply aliases to +their assert module counterparts. + + +Asynchronous Testing +-------------------- + +When testing asynchronous code, there are a number of sharp edges to watch out +for. Thankfully, nodeunit is designed to help you avoid as many of these +pitfalls as possible. For the most part, testing asynchronous code in nodeunit +_just works_. + + +### Tests run in series + +While running tests in parallel seems like a good idea for speeding up your +test suite, in practice I've found it means writing much more complicated +tests. Because of node's module cache, running tests in parallel means mocking +and stubbing is pretty much impossible. One of the nicest things about testing +in javascript is the ease of doing stubs: + + var _readFile = fs.readFile; + fs.readFile = function(path, callback){ + // it's a stub! + }; + // test function that uses fs.readFile + + // we're done + fs.readFile = _readFile; + +You cannot do this when running tests in parallel. In order to keep testing as +simple as possible, nodeunit avoids it. Thankfully, most unit-test suites run +fast anyway. + + +### Explicit ending of tests + +When testing async code it's important that tests end at the correct point, not +just after a given number of assertions. Otherwise your tests can run short, +ending before all assertions have completed. It's important to detect too +many assertions as well as too few. Combining explicit ending of tests with +an expected number of assertions helps to avoid false test passes, so be sure +to use the `test.expect()` method at the start of your test functions, and +`test.done()` when finished. + + +Groups, setUp and tearDown +-------------------------- + +Nodeunit allows the nesting of test functions: + + exports.test1 = function (test) { + ... + } + + exports.group = { + test2: function (test) { + ... + }, + test3: function (test) { + ... + } + } + +This would be run as: + + test1 + group - test2 + group - test3 + +Using these groups, Nodeunit allows you to define a `setUp` function, which is +run before each test, and a `tearDown` function, which is run after each test +calls `test.done()`: + + module.exports = { + setUp: function (callback) { + this.foo = 'bar'; + callback(); + }, + tearDown: function (callback) { + // clean up + callback(); + }, + test1: function (test) { + test.equals(this.foo, 'bar'); + test.done(); + } + }; + +In this way, it's possible to have multiple groups of tests in a module, each +group with its own setUp and tearDown functions. + + +Running Tests +------------- + +Nodeunit comes with a basic command-line test runner, which can be installed +using `sudo make install`. Example usage: + + nodeunit testmodule1.js testfolder [...] + +If no entry file specified, `test` defaults. + +The default test reporter uses color output, because I think that's more fun :) I +intend to add a no-color option in future. To give you a feeling of the fun you'll +be having writing tests, lets fix the example at the start of the README: + + + +Ahhh, Doesn't that feel better? + +When using the included test runner, it will exit using the failed number of +assertions as the exit code. This means it exits with 0 when all tests pass. + + +### Command-line Options + +* __--reporter FILE__ - you can set the test reporter to a custom module or +on of the modules in nodeunit/lib/reporters, when omitted, the default test runner +is used. +* __--list-reporters__ - list available built-in reporters. +* __--config FILE__ - load config options from a JSON file, allows +the customisation of color schemes for the default test reporter etc. See +bin/nodeunit.json for current available options. +* __-t testName__ - run specifc test only. +* __-f fullTestName__ - run specific test only. fullTestName is built so: "outerGroup - .. - innerGroup - testName". +* __--version__ or __-v__ - report nodeunit version +* __--help__ - show nodeunit help + + +Running tests in the browser +---------------------------- + +Nodeunit tests can also be run inside the browser. For example usage, see +the examples/browser folder. The basic syntax is as follows: + +__test.html__ + + + + Example Test Suite + + + + + + +

    Example Test Suite

    + + + + +Here, `suite1` and `suite2` are just object literals containing test functions +or groups, as would be returned if you did `require('test-suite')` in node.js: + +__suite1.js__ + + this.suite1 = { + 'example test': function (test) { + test.ok(true, 'everything is ok'); + test.done(); + } + }; + +If you wish to use a commonjs format for your test suites (using exports), it is +up to you to define the commonjs tools for the browser. There are a number of +alternatives and it's important it fits with your existing code, which is +why nodeunit does not currently provide this out of the box. + +In the example above, the tests will run when the page is loaded. + +The browser-version of nodeunit.js is created in dist/browser when you do, `make +browser`. You'll need [UglifyJS](https://github.com/mishoo/UglifyJS) installed in +order for it to automatically create nodeunit.min.js. + + +Adding nodeunit to Your Projects +-------------------------------- + +If you don't want people to have to install the nodeunit command-line tool, +you'll want to create a script that runs the tests for your project with the +correct require paths set up. Here's an example test script, that assumes you +have nodeunit in a suitably located node_modules directory. + + #!/usr/bin/env node + var reporter = require('nodeunit').reporters.default; + reporter.run(['test']); + +If you're using git, you might find it useful to include nodeunit as a +submodule. Using submodules makes it easy for developers to download nodeunit +and run your test suite, without cluttering up your repository with +the source code. To add nodeunit as a git submodule do the following: + + git submodule add git://github.com/caolan/nodeunit.git node_modules/nodeunit + +This will add nodeunit to the node_modules folder of your project. Now, when +cloning the repository, nodeunit can be downloaded by doing the following: + + git submodule init + git submodule update + +Let's update the test script above with a helpful hint on how to get nodeunit, +if it's missing: + + #!/usr/bin/env node + try { + var reporter = require('nodeunit').reporters.default; + } + catch(e) { + console.log("Cannot find nodeunit module."); + console.log("You can download submodules for this project by doing:"); + console.log(""); + console.log(" git submodule init"); + console.log(" git submodule update"); + console.log(""); + process.exit(); + } + + process.chdir(__dirname); + reporter.run(['test']); + +Now if someone attempts to run your test suite without nodeunit installed they +will be prompted to download the submodules for your project. + + +Built-in Test Reporters +----------------------- + +* __default__ - The standard reporter seen in the nodeunit screenshots +* __minimal__ - Pretty, minimal output, shows errors and progress only +* __html__ - Outputs a HTML report to stdout +* __junit__ - Creates jUnit compatible XML reports, which can be used with + continuous integration tools such as [Hudson](http://hudson-ci.org/). +* __machineout__ - Simple reporter for machine analysis. There is + [nodeunit.vim](https://github.com/lambdalisue/nodeunit.vim) which is useful for TDD on VIM. + + +Writing a Test Reporter +--------------------- + +Nodeunit exports runTest(fn, options), runModule(mod, options) and +runFiles(paths, options). You'll most likely want to run test suites from +files, which can be done using the latter function. The _options_ argument can +contain callbacks which run during testing. Nodeunit provides the following +callbacks: + +* __moduleStart(name)__ - called before a module is tested +* __moduleDone(name, assertions)__ - called once all test functions within the + module have completed (see assertions object reference below) + ALL tests within the module +* __testStart(name)__ - called before a test function is run +* __testReady(test)__ - called before a test function is run with the test object that will be passed to the test function +* __testDone(name, assertions)__ - called once a test function has completed + (by calling test.done()) +* __log(assertion)__ - called whenever an assertion is made (see assertion + object reference below) +* __done(assertions)__ - called after all tests/modules are complete + +The __assertion__ object: + +* __passed()__ - did the assertion pass? +* __failed()__ - did the assertion fail? +* __error__ - the AssertionError if the assertion failed +* __method__ - the nodeunit assertion method used (ok, same, equals...) +* __message__ - the message the assertion method was called with (optional) + +The __assertionList__ object: + +* An array-like object with the following new attributes: + * __failures()__ - the number of assertions which failed + * __duration__ - the time taken for the test to complete in msecs + +For a reference implementation of a test reporter, see lib/reporters/default.js in +the nodeunit project directory. + + +Sandbox utility +--------------- + +This is a function which evaluates JavaScript files in a sandbox and returns the +context. The sandbox function can be used for testing client-side code or private +un-exported functions within a module. + + var sandbox = require('nodeunit').utils.sandbox; + var example = sandbox('example.js'); + +__sandbox(files, sandbox)__ - Evaluates JavaScript files in a sandbox, returning +the context. The first argument can either be a single filename or an array of +filenames. If multiple filenames are given their contents are concatenated before +evaluation. The second argument is an optional context to use for the sandbox. + +Note: When working with the sandbox if your script depends on outside sources +(i.e. using `require`) then you will want to pass that into the optional +context when setting up the sandbox. + + var sandbox = require('nodeunit').utils.sandbox; + // pass in some node globals + var box_globals = { + // Passing module.exports into the sandbox will give your code access to it. + module: {exports: exports}, + // Passing require into the sandbox will give your code access to use it AND + // will share the cache with modules already required from outside the sandbox. + require: require, + // Passing console into the sandbox will give your code access to it + console: console + }; + var example = sandbox('example.js', box_globals); + + +Running the nodeunit Tests +-------------------------- + +The tests for nodeunit are written using nodeunit itself as the test framework. +However, the module test-base.js first does some basic tests using the assert +module to ensure that test functions are actually run, and a basic level of +nodeunit functionality is available. + +To run the nodeunit tests do: + + make test + +__Note:__ There was a bug in node v0.2.0 causing the tests to hang, upgrading +to v0.2.1 fixes this. + + +__machineout__ reporter +---------------------------------------------- + +The default reporter is readable for human but not for machine analysis. +When you want to analyze the output of nodeunit, use __machineout__ reporter and you will get + + + + +nodeunit with vim +---------------------------------- +There is [nodeunit.vim](https://github.com/lambdalisue/nodeunit.vim) so you can use +nodeunit with VIM. + +That compiler uses __machineout__ reporter and it is useful to use +with [vim-makegreen](https://github.com/reinh/vim-makegreen). + + + +Contributing +------------ + +Contributions to the project are most welcome, so feel free to fork and improve. +When submitting a pull request, please run `make lint` first to ensure +we're following a consistent coding style. diff --git a/node_modules/nodeunit/bin/nodeunit b/node_modules/nodeunit/bin/nodeunit new file mode 100755 index 0000000..e3e15b5 --- /dev/null +++ b/node_modules/nodeunit/bin/nodeunit @@ -0,0 +1,132 @@ +#!/usr/bin/env node + +var + fs = require('fs'), + path = require('path'); + +// TODO: remove this when https://github.com/joyent/node/pull/1312 +// lands in core. +// +// Until then, use console.log from npm (https://gist.github.com/1077544) +require('../deps/console.log'); + +//require.paths.push(process.cwd()); +var args = (process.ARGV || process.argv).slice(2); + +var files = []; + +var testrunner, + config_file, + config_param_found = false, + output_param_found = false, + reporter_file = 'default', + reporter_param_found = false, + testspec_param_found = false; + testFullSpec_param_found = false; + +var usage = "Usage: nodeunit [options] testmodule1.js testfolder [...] \n" + + "Options:\n\n" + + " --config FILE the path to a JSON file with options\n" + + " --reporter FILE optional path to a reporter file to customize the output\n" + + " --list-reporters list available build-in reporters\n" + + " -t testName, specify a test to run\n" + + " -f fullTestName, specify a specific test to run. fullTestName is built so: \"outerGroup - .. - innerGroup - testName\"\n" + + " -h, --help display this help and exit\n" + + " -v, --version output version information and exit"; + + + +// load default options +var content = fs.readFileSync(__dirname + '/nodeunit.json', 'utf8'); +var options = JSON.parse(content); + +// a very basic pseudo --options parser +args.forEach(function (arg) { + if (arg.slice(0, 9) === "--config=") { + config_file = arg.slice(9); + } else if (arg === '--config') { + config_param_found = true; + } else if (config_param_found) { + config_file = arg; + config_param_found = false; + } else if (arg.slice(0, 9) === "--output=") { + options.output = arg.slice(9); + } else if (arg === '--output') { + output_param_found = true; + } else if (output_param_found) { + options.output = arg; + output_param_found = false; + } else if (arg.slice(0, 11) === "--reporter=") { + reporter_file = arg.slice(11); + } else if (arg === '--reporter') { + reporter_param_found = true; + } else if (reporter_param_found) { + reporter_file = arg; + reporter_param_found = false; + } else if (arg === '-t') { + testspec_param_found = true; + } else if (testspec_param_found) { + options.testspec = arg; + testspec_param_found = false; + } else if (arg === '-f') { + testFullSpec_param_found = true; + } else if (testFullSpec_param_found) { + options.testFullSpec= arg; + testFullSpec_param_found = false; + } else if (arg === '--list-reporters') { + var reporters = fs.readdirSync(__dirname + '/../lib/reporters'); + reporters = reporters.filter(function (reporter_file) { + return (/\.js$/).test(reporter_file); + }).map(function (reporter_file) { + return reporter_file.replace(/\.js$/, ''); + }).filter(function (reporter_file) { + return reporter_file !== 'index'; + }); + console.log('Build-in reporters: '); + reporters.forEach(function (reporter_file) { + var reporter = require('../lib/reporters/' + reporter_file); + console.log(' * ' + reporter_file + (reporter.info ? ': ' + reporter.info : '')); + }); + process.exit(0); + } else if ((arg === '-v') || (arg === '--version')) { + var content = fs.readFileSync(__dirname + '/../package.json', 'utf8'); + var pkg = JSON.parse(content); + console.log(pkg.version); + process.exit(0); + } else if ((arg === '-h') || (arg === '--help')) { + console.log(usage); + process.exit(0); + } else { + files.push(arg); + } +}); + +// defaults to `test` +if (files.length === 0) { + files = ['test']; +} + +if (config_file) { + content = fs.readFileSync(config_file, 'utf8'); + var custom_options = JSON.parse(content); + + for (var option in custom_options) { + if (typeof option === 'string') { + options[option] = custom_options[option]; + } + } +} + +var builtin_reporters = require(__dirname + '/../lib/reporters'); +if (reporter_file in builtin_reporters) { + testrunner = builtin_reporters[reporter_file]; +} +else { + testrunner = require(reporter_file); +} + +testrunner.run(files, options, function(err) { + if (err) { + process.exit(1); + } +}); diff --git a/node_modules/nodeunit/bin/nodeunit.json b/node_modules/nodeunit/bin/nodeunit.json new file mode 100644 index 0000000..5c7778f --- /dev/null +++ b/node_modules/nodeunit/bin/nodeunit.json @@ -0,0 +1,10 @@ +{ + "error_prefix": "\u001B[31m", + "error_suffix": "\u001B[39m", + "ok_prefix": "\u001B[32m", + "ok_suffix": "\u001B[39m", + "bold_prefix": "\u001B[1m", + "bold_suffix": "\u001B[22m", + "assertion_prefix": "\u001B[35m", + "assertion_suffix": "\u001B[39m" +} diff --git a/node_modules/nodeunit/deps/async.js b/node_modules/nodeunit/deps/async.js new file mode 100644 index 0000000..f65be61 --- /dev/null +++ b/node_modules/nodeunit/deps/async.js @@ -0,0 +1,628 @@ +/*global setTimeout: false, console: false */ +(function () { + + var async = {}; + + // global on the server, window in the browser + var root = this, + previous_async = root.async; + + if (typeof module !== 'undefined' && module.exports) { + module.exports = async; + } + else { + root.async = async; + } + + async.noConflict = function () { + root.async = previous_async; + return async; + }; + + //// cross-browser compatiblity functions //// + + var _forEach = function (arr, iterator) { + if (arr.forEach) { + return arr.forEach(iterator); + } + for (var i = 0; i < arr.length; i += 1) { + iterator(arr[i], i, arr); + } + }; + + var _map = function (arr, iterator) { + if (arr.map) { + return arr.map(iterator); + } + var results = []; + _forEach(arr, function (x, i, a) { + results.push(iterator(x, i, a)); + }); + return results; + }; + + var _reduce = function (arr, iterator, memo) { + if (arr.reduce) { + return arr.reduce(iterator, memo); + } + _forEach(arr, function (x, i, a) { + memo = iterator(memo, x, i, a); + }); + return memo; + }; + + var _keys = function (obj) { + if (Object.keys) { + return Object.keys(obj); + } + var keys = []; + for (var k in obj) { + if (obj.hasOwnProperty(k)) { + keys.push(k); + } + } + return keys; + }; + + var _indexOf = function (arr, item) { + if (arr.indexOf) { + return arr.indexOf(item); + } + for (var i = 0; i < arr.length; i += 1) { + if (arr[i] === item) { + return i; + } + } + return -1; + }; + + //// exported async module functions //// + + //// nextTick implementation with browser-compatible fallback //// + if (typeof setImmediate === 'function') { + async.nextTick = function (fn) { + setImmediate(fn); + }; + } + else if (typeof process !== 'undefined' && process.nextTick) { + async.nextTick = process.nextTick; + } + else { + async.nextTick = function (fn) { + setTimeout(fn, 0); + }; + } + + async.forEach = function (arr, iterator, callback) { + if (!arr.length) { + return callback(); + } + var completed = 0; + _forEach(arr, function (x) { + iterator(x, function (err) { + if (err) { + callback(err); + callback = function () {}; + } + else { + completed += 1; + if (completed === arr.length) { + callback(); + } + } + }); + }); + }; + + async.forEachSeries = function (arr, iterator, callback) { + if (!arr.length) { + return callback(); + } + var completed = 0; + var iterate = function () { + iterator(arr[completed], function (err) { + if (err) { + callback(err); + callback = function () {}; + } + else { + completed += 1; + if (completed === arr.length) { + callback(); + } + else { + iterate(); + } + } + }); + }; + iterate(); + }; + + + var doParallel = function (fn) { + return function () { + var args = Array.prototype.slice.call(arguments); + return fn.apply(null, [async.forEach].concat(args)); + }; + }; + var doSeries = function (fn) { + return function () { + var args = Array.prototype.slice.call(arguments); + return fn.apply(null, [async.forEachSeries].concat(args)); + }; + }; + + + var _asyncMap = function (eachfn, arr, iterator, callback) { + var results = []; + arr = _map(arr, function (x, i) { + return {index: i, value: x}; + }); + eachfn(arr, function (x, callback) { + iterator(x.value, function (err, v) { + results[x.index] = v; + callback(err); + }); + }, function (err) { + callback(err, results); + }); + }; + async.map = doParallel(_asyncMap); + async.mapSeries = doSeries(_asyncMap); + + + // reduce only has a series version, as doing reduce in parallel won't + // work in many situations. + async.reduce = function (arr, memo, iterator, callback) { + async.forEachSeries(arr, function (x, callback) { + iterator(memo, x, function (err, v) { + memo = v; + callback(err); + }); + }, function (err) { + callback(err, memo); + }); + }; + // inject alias + async.inject = async.reduce; + // foldl alias + async.foldl = async.reduce; + + async.reduceRight = function (arr, memo, iterator, callback) { + var reversed = _map(arr, function (x) { + return x; + }).reverse(); + async.reduce(reversed, memo, iterator, callback); + }; + // foldr alias + async.foldr = async.reduceRight; + + var _filter = function (eachfn, arr, iterator, callback) { + var results = []; + arr = _map(arr, function (x, i) { + return {index: i, value: x}; + }); + eachfn(arr, function (x, callback) { + iterator(x.value, function (v) { + if (v) { + results.push(x); + } + callback(); + }); + }, function (err) { + callback(_map(results.sort(function (a, b) { + return a.index - b.index; + }), function (x) { + return x.value; + })); + }); + }; + async.filter = doParallel(_filter); + async.filterSeries = doSeries(_filter); + // select alias + async.select = async.filter; + async.selectSeries = async.filterSeries; + + var _reject = function (eachfn, arr, iterator, callback) { + var results = []; + arr = _map(arr, function (x, i) { + return {index: i, value: x}; + }); + eachfn(arr, function (x, callback) { + iterator(x.value, function (v) { + if (!v) { + results.push(x); + } + callback(); + }); + }, function (err) { + callback(_map(results.sort(function (a, b) { + return a.index - b.index; + }), function (x) { + return x.value; + })); + }); + }; + async.reject = doParallel(_reject); + async.rejectSeries = doSeries(_reject); + + var _detect = function (eachfn, arr, iterator, main_callback) { + eachfn(arr, function (x, callback) { + iterator(x, function (result) { + if (result) { + main_callback(x); + } + else { + callback(); + } + }); + }, function (err) { + main_callback(); + }); + }; + async.detect = doParallel(_detect); + async.detectSeries = doSeries(_detect); + + async.some = function (arr, iterator, main_callback) { + async.forEach(arr, function (x, callback) { + iterator(x, function (v) { + if (v) { + main_callback(true); + main_callback = function () {}; + } + callback(); + }); + }, function (err) { + main_callback(false); + }); + }; + // any alias + async.any = async.some; + + async.every = function (arr, iterator, main_callback) { + async.forEach(arr, function (x, callback) { + iterator(x, function (v) { + if (!v) { + main_callback(false); + main_callback = function () {}; + } + callback(); + }); + }, function (err) { + main_callback(true); + }); + }; + // all alias + async.all = async.every; + + async.sortBy = function (arr, iterator, callback) { + async.map(arr, function (x, callback) { + iterator(x, function (err, criteria) { + if (err) { + callback(err); + } + else { + callback(null, {value: x, criteria: criteria}); + } + }); + }, function (err, results) { + if (err) { + return callback(err); + } + else { + var fn = function (left, right) { + var a = left.criteria, b = right.criteria; + return a < b ? -1 : a > b ? 1 : 0; + }; + callback(null, _map(results.sort(fn), function (x) { + return x.value; + })); + } + }); + }; + + async.auto = function (tasks, callback) { + callback = callback || function () {}; + var keys = _keys(tasks); + if (!keys.length) { + return callback(null); + } + + var completed = []; + + var listeners = []; + var addListener = function (fn) { + listeners.unshift(fn); + }; + var removeListener = function (fn) { + for (var i = 0; i < listeners.length; i += 1) { + if (listeners[i] === fn) { + listeners.splice(i, 1); + return; + } + } + }; + var taskComplete = function () { + _forEach(listeners, function (fn) { + fn(); + }); + }; + + addListener(function () { + if (completed.length === keys.length) { + callback(null); + } + }); + + _forEach(keys, function (k) { + var task = (tasks[k] instanceof Function) ? [tasks[k]]: tasks[k]; + var taskCallback = function (err) { + if (err) { + callback(err); + // stop subsequent errors hitting callback multiple times + callback = function () {}; + } + else { + completed.push(k); + taskComplete(); + } + }; + var requires = task.slice(0, Math.abs(task.length - 1)) || []; + var ready = function () { + return _reduce(requires, function (a, x) { + return (a && _indexOf(completed, x) !== -1); + }, true); + }; + if (ready()) { + task[task.length - 1](taskCallback); + } + else { + var listener = function () { + if (ready()) { + removeListener(listener); + task[task.length - 1](taskCallback); + } + }; + addListener(listener); + } + }); + }; + + async.waterfall = function (tasks, callback) { + if (!tasks.length) { + return callback(); + } + callback = callback || function () {}; + var wrapIterator = function (iterator) { + return function (err) { + if (err) { + callback(err); + callback = function () {}; + } + else { + var args = Array.prototype.slice.call(arguments, 1); + var next = iterator.next(); + if (next) { + args.push(wrapIterator(next)); + } + else { + args.push(callback); + } + async.nextTick(function () { + iterator.apply(null, args); + }); + } + }; + }; + wrapIterator(async.iterator(tasks))(); + }; + + async.parallel = function (tasks, callback) { + callback = callback || function () {}; + if (tasks.constructor === Array) { + async.map(tasks, function (fn, callback) { + if (fn) { + fn(function (err) { + var args = Array.prototype.slice.call(arguments, 1); + if (args.length <= 1) { + args = args[0]; + } + callback.call(null, err, args || null); + }); + } + }, callback); + } + else { + var results = {}; + async.forEach(_keys(tasks), function (k, callback) { + tasks[k](function (err) { + var args = Array.prototype.slice.call(arguments, 1); + if (args.length <= 1) { + args = args[0]; + } + results[k] = args; + callback(err); + }); + }, function (err) { + callback(err, results); + }); + } + }; + + async.series = function (tasks, callback) { + callback = callback || function () {}; + if (tasks.constructor === Array) { + async.mapSeries(tasks, function (fn, callback) { + if (fn) { + fn(function (err) { + var args = Array.prototype.slice.call(arguments, 1); + if (args.length <= 1) { + args = args[0]; + } + callback.call(null, err, args || null); + }); + } + }, callback); + } + else { + var results = {}; + async.forEachSeries(_keys(tasks), function (k, callback) { + tasks[k](function (err) { + var args = Array.prototype.slice.call(arguments, 1); + if (args.length <= 1) { + args = args[0]; + } + results[k] = args; + callback(err); + }); + }, function (err) { + callback(err, results); + }); + } + }; + + async.iterator = function (tasks) { + var makeCallback = function (index) { + var fn = function () { + if (tasks.length) { + tasks[index].apply(null, arguments); + } + return fn.next(); + }; + fn.next = function () { + return (index < tasks.length - 1) ? makeCallback(index + 1): null; + }; + return fn; + }; + return makeCallback(0); + }; + + async.apply = function (fn) { + var args = Array.prototype.slice.call(arguments, 1); + return function () { + return fn.apply( + null, args.concat(Array.prototype.slice.call(arguments)) + ); + }; + }; + + var _concat = function (eachfn, arr, fn, callback) { + var r = []; + eachfn(arr, function (x, cb) { + fn(x, function (err, y) { + r = r.concat(y || []); + cb(err); + }); + }, function (err) { + callback(err, r); + }); + }; + async.concat = doParallel(_concat); + async.concatSeries = doSeries(_concat); + + async.whilst = function (test, iterator, callback) { + if (test()) { + iterator(function (err) { + if (err) { + return callback(err); + } + async.whilst(test, iterator, callback); + }); + } + else { + callback(); + } + }; + + async.until = function (test, iterator, callback) { + if (!test()) { + iterator(function (err) { + if (err) { + return callback(err); + } + async.until(test, iterator, callback); + }); + } + else { + callback(); + } + }; + + async.queue = function (worker, concurrency) { + var workers = 0; + var tasks = []; + var q = { + concurrency: concurrency, + push: function (data, callback) { + tasks.push({data: data, callback: callback}); + async.nextTick(q.process); + }, + process: function () { + if (workers < q.concurrency && tasks.length) { + var task = tasks.splice(0, 1)[0]; + workers += 1; + worker(task.data, function () { + workers -= 1; + if (task.callback) { + task.callback.apply(task, arguments); + } + q.process(); + }); + } + }, + length: function () { + return tasks.length; + } + }; + return q; + }; + + var _console_fn = function (name) { + return function (fn) { + var args = Array.prototype.slice.call(arguments, 1); + fn.apply(null, args.concat([function (err) { + var args = Array.prototype.slice.call(arguments, 1); + if (typeof console !== 'undefined') { + if (err) { + if (console.error) { + console.error(err); + } + } + else if (console[name]) { + _forEach(args, function (x) { + console[name](x); + }); + } + } + }])); + }; + }; + async.log = _console_fn('log'); + async.dir = _console_fn('dir'); + /*async.info = _console_fn('info'); + async.warn = _console_fn('warn'); + async.error = _console_fn('error');*/ + + async.memoize = function (fn, hasher) { + var memo = {}; + hasher = hasher || function (x) { + return x; + }; + return function () { + var args = Array.prototype.slice.call(arguments); + var callback = args.pop(); + var key = hasher.apply(null, args); + if (key in memo) { + callback.apply(null, memo[key]); + } + else { + fn.apply(null, args.concat([function () { + memo[key] = arguments; + callback.apply(null, arguments); + }])); + } + }; + }; + +}()); diff --git a/node_modules/nodeunit/deps/console.log.js b/node_modules/nodeunit/deps/console.log.js new file mode 100644 index 0000000..fe146c1 --- /dev/null +++ b/node_modules/nodeunit/deps/console.log.js @@ -0,0 +1,55 @@ +/* + A console.log that won't leave you hanging when node exits + 90% of this file was ripped from node.js + + License: see: https://github.com/joyent/node/blob/master/lib/console.js + */ + + // console object +var formatRegExp = /%[sdj]/g; +function format(f) { + var util = require('util'); + + if (typeof f !== 'string') { + var objects = []; + for (var i = 0; i < arguments.length; i++) { + objects.push(util.inspect(arguments[i])); + } + return objects.join(' '); + } + + + var i = 1; + var args = arguments; + var str = String(f).replace(formatRegExp, function(x) { + switch (x) { + case '%s': return String(args[i++]); + case '%d': return Number(args[i++]); + case '%j': return JSON.stringify(args[i++]); + default: + return x; + } + }); + for (var len = args.length, x = args[i]; i < len; x = args[++i]) { + if (x === null || typeof x !== 'object') { + str += ' ' + x; + } else { + str += ' ' + util.inspect(x); + } + } + return str; +} + +console.log = function() { + var res = process.stdout.write(format.apply(this, arguments) + '\n'); + + // this is the first time stdout got backed up + if (!res && !process.stdout.pendingWrite) { + process.stdout.pendingWrite = true; + + // magic sauce: keep node alive until stdout has flushed + process.stdout.once('drain', function () { + process.stdout.draining = false; + }); + } +}; diff --git a/node_modules/nodeunit/deps/ejs/History.md b/node_modules/nodeunit/deps/ejs/History.md new file mode 100644 index 0000000..00d2b5b --- /dev/null +++ b/node_modules/nodeunit/deps/ejs/History.md @@ -0,0 +1,70 @@ + +0.4.3 / 2011-06-20 +================== + + * Fixed stacktraces line number when used multiline js expressions [Octave] + +0.4.2 / 2011-05-11 +================== + + * Added client side support + +0.4.1 / 2011-04-21 +================== + + * Fixed error context + +0.4.0 / 2011-04-21 +================== + + * Added; ported jade's error reporting to ejs. [slaskis] + +0.3.1 / 2011-02-23 +================== + + * Fixed optional `compile()` options + +0.3.0 / 2011-02-14 +================== + + * Added 'json' filter [Yuriy Bogdanov] + * Use exported version of parse function to allow monkey-patching [Anatoliy Chakkaev] + +0.2.1 / 2010-10-07 +================== + + * Added filter support + * Fixed _cache_ option. ~4x performance increase + +0.2.0 / 2010-08-05 +================== + + * Added support for global tag config + * Added custom tag support. Closes #5 + * Fixed whitespace bug. Closes #4 + +0.1.0 / 2010-08-04 +================== + + * Faster implementation [ashleydev] + +0.0.4 / 2010-08-02 +================== + + * Fixed single quotes for content outside of template tags. [aniero] + * Changed; `exports.compile()` now expects only "locals" + +0.0.3 / 2010-07-15 +================== + + * Fixed single quotes + +0.0.2 / 2010-07-09 +================== + + * Fixed newline preservation + +0.0.1 / 2010-07-09 +================== + + * Initial release diff --git a/node_modules/nodeunit/deps/ejs/Makefile b/node_modules/nodeunit/deps/ejs/Makefile new file mode 100644 index 0000000..a8b00d9 --- /dev/null +++ b/node_modules/nodeunit/deps/ejs/Makefile @@ -0,0 +1,20 @@ + +SRC = $(shell find lib -name "*.js" -type f) +UGLIFY_FLAGS = --no-mangle + +test: + @./node_modules/.bin/expresso test/*.test.js + +ejs.js: $(SRC) + @node support/compile.js $^ + +ejs.min.js: ejs.js + @uglifyjs $(UGLIFY_FLAGS) $< > $@ \ + && du ejs.min.js \ + && du ejs.js + +clean: + rm -f ejs.js + rm -f ejs.min.js + +.PHONY: test \ No newline at end of file diff --git a/node_modules/nodeunit/deps/ejs/Readme.md b/node_modules/nodeunit/deps/ejs/Readme.md new file mode 100644 index 0000000..58cb10a --- /dev/null +++ b/node_modules/nodeunit/deps/ejs/Readme.md @@ -0,0 +1,152 @@ + +# EJS + +Embedded JavaScript templates. + +## Installation + + $ npm install ejs + +## Features + + * Complies with the [Express](http://expressjs.com) view system + * Static caching of intermediate JavaScript + * Unbuffered code for conditionals etc `<% code %>` + * Escapes html by default with `<%= code %>` + * Unescaped buffering with `<%- code %>` + * Supports tag customization + * Filter support for designer-friendly templates + * Client-side support + +## Example + + <% if (user) { %> +

    <%= user.name %>

    + <% } %> + +## Usage + + ejs.compile(str, options); + // => Function + + ejs.render(str, options); + // => str + +## Options + + - `locals` Local variables object + - `cache` Compiled functions are cached, requires `filename` + - `filename` Used by `cache` to key caches + - `scope` Function execution context + - `debug` Output generated function body + - `open` Open tag, defaulting to "<%" + - `close` Closing tag, defaulting to "%>" + +## Custom tags + +Custom tags can also be applied globally: + + var ejs = require('ejs'); + ejs.open = '{{'; + ejs.close = '}}'; + +Which would make the following a valid template: + +

    {{= title }}

    + +## Filters + +EJS conditionally supports the concept of "filters". A "filter chain" +is a designer friendly api for manipulating data, without writing JavaScript. + +Filters can be applied by supplying the _:_ modifier, so for example if we wish to take the array `[{ name: 'tj' }, { name: 'mape' }, { name: 'guillermo' }]` and output a list of names we can do this simply with filters: + +Template: + +

    <%=: users | map:'name' | join %>

    + +Output: + +

    Tj, Mape, Guillermo

    + +Render call: + + ejs.render(str, { + locals: { + users: [ + { name: 'tj' }, + { name: 'mape' }, + { name: 'guillermo' } + ] + } + }); + +Or perhaps capitalize the first user's name for display: + +

    <%=: users | first | capitalize %>

    + +## Filter list + +Currently these filters are available: + + - first + - last + - capitalize + - downcase + - upcase + - sort + - sort_by:'prop' + - size + - length + - plus:n + - minus:n + - times:n + - divided_by:n + - join:'val' + - truncate:n + - truncate_words:n + - replace:pattern,substitution + - prepend:val + - append:val + - map:'prop' + - reverse + - get:'prop' + +## Adding filters + + To add a filter simply add a method to the `.filters` object: + +```js +ejs.filters.last = function(obj) { + return obj[obj.length - 1]; +}; +``` + +## client-side support + + include `./ejs.js` or `./ejs.min.js` and `require("ejs").compile(str)`. + +## License + +(The MIT License) + +Copyright (c) 2009-2010 TJ Holowaychuk <tj@vision-media.ca> + +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/node_modules/nodeunit/deps/ejs/benchmark.js b/node_modules/nodeunit/deps/ejs/benchmark.js new file mode 100644 index 0000000..7b267e1 --- /dev/null +++ b/node_modules/nodeunit/deps/ejs/benchmark.js @@ -0,0 +1,14 @@ + + +var ejs = require('./lib/ejs'), + str = '<% if (foo) { %>

    <%= foo %>

    <% } %>', + times = 50000; + +console.log('rendering ' + times + ' times'); + +var start = new Date; +while (times--) { + ejs.render(str, { cache: true, filename: 'test', locals: { foo: 'bar' }}); +} + +console.log('took ' + (new Date - start) + 'ms'); \ No newline at end of file diff --git a/node_modules/nodeunit/deps/ejs/ejs.js b/node_modules/nodeunit/deps/ejs/ejs.js new file mode 100644 index 0000000..b8c6aa1 --- /dev/null +++ b/node_modules/nodeunit/deps/ejs/ejs.js @@ -0,0 +1,531 @@ + +// CommonJS require() + +function require(p){ + var path = require.resolve(p) + , mod = require.modules[path]; + if (!mod) throw new Error('failed to require "' + p + '"'); + if (!mod.exports) { + mod.exports = {}; + mod.call(mod.exports, mod, mod.exports, require.relative(path)); + } + return mod.exports; + } + +require.modules = {}; + +require.resolve = function (path){ + var orig = path + , reg = path + '.js' + , index = path + '/index.js'; + return require.modules[reg] && reg + || require.modules[index] && index + || orig; + }; + +require.register = function (path, fn){ + require.modules[path] = fn; + }; + +require.relative = function (parent) { + return function(p){ + if ('.' != p[0]) return require(p); + + var path = parent.split('/') + , segs = p.split('/'); + path.pop(); + + for (var i = 0; i < segs.length; i++) { + var seg = segs[i]; + if ('..' == seg) path.pop(); + else if ('.' != seg) path.push(seg); + } + + return require(path.join('/')); + }; + }; + + +require.register("ejs.js", function(module, exports, require){ + +/*! + * EJS + * Copyright(c) 2010 TJ Holowaychuk + * MIT Licensed + */ + +/** + * Module dependencies. + */ + +var utils = require('./utils'); + +/** + * Library version. + */ + +exports.version = '0.4.2'; + +/** + * Filters. + * + * @type Object + */ + +var filters = exports.filters = require('./filters'); + +/** + * Intermediate js cache. + * + * @type Object + */ + +var cache = {}; + +/** + * Clear intermediate js cache. + * + * @api public + */ + +exports.clearCache = function(){ + cache = {}; +}; + +/** + * Translate filtered code into function calls. + * + * @param {String} js + * @return {String} + * @api private + */ + +function filtered(js) { + return js.substr(1).split('|').reduce(function(js, filter){ + var parts = filter.split(':') + , name = parts.shift() + , args = parts.shift() || ''; + if (args) args = ', ' + args; + return 'filters.' + name + '(' + js + args + ')'; + }); +}; + +/** + * Re-throw the given `err` in context to the + * `str` of ejs, `filename`, and `lineno`. + * + * @param {Error} err + * @param {String} str + * @param {String} filename + * @param {String} lineno + * @api private + */ + +function rethrow(err, str, filename, lineno){ + var lines = str.split('\n') + , start = Math.max(lineno - 3, 0) + , end = Math.min(lines.length, lineno + 3); + + // Error context + var context = lines.slice(start, end).map(function(line, i){ + var curr = i + start + 1; + return (curr == lineno ? ' >> ' : ' ') + + curr + + '| ' + + line; + }).join('\n'); + + // Alter exception message + err.path = filename; + err.message = (filename || 'ejs') + ':' + + lineno + '\n' + + context + '\n\n' + + err.message; + + throw err; +} + +/** + * Parse the given `str` of ejs, returning the function body. + * + * @param {String} str + * @return {String} + * @api public + */ + +var parse = exports.parse = function(str, options){ + var options = options || {} + , open = options.open || exports.open || '<%' + , close = options.close || exports.close || '%>'; + + var buf = [ + "var buf = [];" + , "\nwith (locals) {" + , "\n buf.push('" + ]; + + var lineno = 1; + + for (var i = 0, len = str.length; i < len; ++i) { + if (str.slice(i, open.length + i) == open) { + i += open.length + + var prefix, postfix, line = '__stack.lineno=' + lineno; + switch (str[i]) { + case '=': + prefix = "', escape((" + line + ', '; + postfix = ")), '"; + ++i; + break; + case '-': + prefix = "', (" + line + ', '; + postfix = "), '"; + ++i; + break; + default: + prefix = "');" + line + ';'; + postfix = "; buf.push('"; + } + + var start = i; + var end = str.indexOf(close, i); + var js = str.substring(i, end); + var n = 0; + while ((n = js.indexOf("\n", n)) > -1) { + n++; + lineno++; + } + if (js[0] == ':') js = filtered(js); + buf.push(prefix, js, postfix); + i += end - start + close.length - 1; + + } else if (str[i] == "\\") { + buf.push("\\\\"); + } else if (str[i] == "'") { + buf.push("\\'"); + } else if (str[i] == "\r") { + buf.push(" "); + } else if (str[i] == "\n") { + buf.push("\\n"); + lineno++; + } else { + buf.push(str[i]); + } + } + + buf.push("');\n}\nreturn buf.join('');"); + return buf.join(''); +}; + +/** + * Compile the given `str` of ejs into a `Function`. + * + * @param {String} str + * @param {Object} options + * @return {Function} + * @api public + */ + +var compile = exports.compile = function(str, options){ + options = options || {}; + + var input = JSON.stringify(str) + , filename = options.filename + ? JSON.stringify(options.filename) + : 'undefined'; + + // Adds the fancy stack trace meta info + str = [ + 'var __stack = { lineno: 1, input: ' + input + ', filename: ' + filename + ' };', + rethrow.toString(), + 'try {', + exports.parse(str, options), + '} catch (err) {', + ' rethrow(err, __stack.input, __stack.filename, __stack.lineno);', + '}' + ].join("\n"); + + if (options.debug) console.log(str); + var fn = new Function('locals, filters, escape', str); + return function(locals){ + return fn.call(this, locals, filters, utils.escape); + } +}; + +/** + * Render the given `str` of ejs. + * + * Options: + * + * - `locals` Local variables object + * - `cache` Compiled functions are cached, requires `filename` + * - `filename` Used by `cache` to key caches + * - `scope` Function execution context + * - `debug` Output generated function body + * - `open` Open tag, defaulting to "<%" + * - `close` Closing tag, defaulting to "%>" + * + * @param {String} str + * @param {Object} options + * @return {String} + * @api public + */ + +exports.render = function(str, options){ + var fn + , options = options || {}; + if (options.cache) { + if (options.filename) { + fn = cache[options.filename] || (cache[options.filename] = compile(str, options)); + } else { + throw new Error('"cache" option requires "filename".'); + } + } else { + fn = compile(str, options); + } + return fn.call(options.scope, options.locals || {}); +}; + +/** + * Expose to require(). + */ + +if (require.extensions) { + require.extensions['.ejs'] = function(module, filename) { + source = require('fs').readFileSync(filename, 'utf-8'); + module._compile(compile(source, {}), filename); + }; +} else if (require.registerExtension) { + require.registerExtension('.ejs', function(src) { + return compile(src, {}); + }); +} + +}); // module: ejs.js + +require.register("filters.js", function(module, exports, require){ + +/*! + * EJS - Filters + * Copyright(c) 2010 TJ Holowaychuk + * MIT Licensed + */ + +/** + * First element of the target `obj`. + */ + +exports.first = function(obj) { + return obj[0]; +}; + +/** + * Last element of the target `obj`. + */ + +exports.last = function(obj) { + return obj[obj.length - 1]; +}; + +/** + * Capitalize the first letter of the target `str`. + */ + +exports.capitalize = function(str){ + str = String(str); + return str[0].toUpperCase() + str.substr(1, str.length); +}; + +/** + * Downcase the target `str`. + */ + +exports.downcase = function(str){ + return String(str).toLowerCase(); +}; + +/** + * Uppercase the target `str`. + */ + +exports.upcase = function(str){ + return String(str).toUpperCase(); +}; + +/** + * Sort the target `obj`. + */ + +exports.sort = function(obj){ + return Object.create(obj).sort(); +}; + +/** + * Sort the target `obj` by the given `prop` ascending. + */ + +exports.sort_by = function(obj, prop){ + return Object.create(obj).sort(function(a, b){ + a = a[prop], b = b[prop]; + if (a > b) return 1; + if (a < b) return -1; + return 0; + }); +}; + +/** + * Size or length of the target `obj`. + */ + +exports.size = exports.length = function(obj) { + return obj.length; +}; + +/** + * Add `a` and `b`. + */ + +exports.plus = function(a, b){ + return Number(a) + Number(b); +}; + +/** + * Subtract `b` from `a`. + */ + +exports.minus = function(a, b){ + return Number(a) - Number(b); +}; + +/** + * Multiply `a` by `b`. + */ + +exports.times = function(a, b){ + return Number(a) * Number(b); +}; + +/** + * Divide `a` by `b`. + */ + +exports.divided_by = function(a, b){ + return Number(a) / Number(b); +}; + +/** + * Join `obj` with the given `str`. + */ + +exports.join = function(obj, str){ + return obj.join(str || ', '); +}; + +/** + * Truncate `str` to `len`. + */ + +exports.truncate = function(str, len){ + str = String(str); + return str.substr(0, len); +}; + +/** + * Truncate `str` to `n` words. + */ + +exports.truncate_words = function(str, n){ + var str = String(str) + , words = str.split(/ +/); + return words.slice(0, n).join(' '); +}; + +/** + * Replace `pattern` with `substitution` in `str`. + */ + +exports.replace = function(str, pattern, substitution){ + return String(str).replace(pattern, substitution || ''); +}; + +/** + * Prepend `val` to `obj`. + */ + +exports.prepend = function(obj, val){ + return Array.isArray(obj) + ? [val].concat(obj) + : val + obj; +}; + +/** + * Append `val` to `obj`. + */ + +exports.append = function(obj, val){ + return Array.isArray(obj) + ? obj.concat(val) + : obj + val; +}; + +/** + * Map the given `prop`. + */ + +exports.map = function(arr, prop){ + return arr.map(function(obj){ + return obj[prop]; + }); +}; + +/** + * Reverse the given `obj`. + */ + +exports.reverse = function(obj){ + return Array.isArray(obj) + ? obj.reverse() + : String(obj).split('').reverse().join(''); +}; + +/** + * Get `prop` of the given `obj`. + */ + +exports.get = function(obj, prop){ + return obj[prop]; +}; + +/** + * Packs the given `obj` into json string + */ +exports.json = function(obj){ + return JSON.stringify(obj); +}; +}); // module: filters.js + +require.register("utils.js", function(module, exports, require){ + +/*! + * EJS + * Copyright(c) 2010 TJ Holowaychuk + * MIT Licensed + */ + +/** + * Escape the given string of `html`. + * + * @param {String} html + * @return {String} + * @api private + */ + +exports.escape = function(html){ + return String(html) + .replace(/&(?!\w+;)/g, '&') + .replace(//g, '>') + .replace(/"/g, '"'); +}; + +}); // module: utils.js diff --git a/node_modules/nodeunit/deps/ejs/ejs.min.js b/node_modules/nodeunit/deps/ejs/ejs.min.js new file mode 100644 index 0000000..6b72d94 --- /dev/null +++ b/node_modules/nodeunit/deps/ejs/ejs.min.js @@ -0,0 +1,2 @@ +// CommonJS require() +function require(p){var path=require.resolve(p),mod=require.modules[path];if(!mod)throw new Error('failed to require "'+p+'"');mod.exports||(mod.exports={},mod.call(mod.exports,mod,mod.exports,require.relative(path)));return mod.exports}require.modules={},require.resolve=function(path){var orig=path,reg=path+".js",index=path+"/index.js";return require.modules[reg]&®||require.modules[index]&&index||orig},require.register=function(path,fn){require.modules[path]=fn},require.relative=function(parent){return function(p){if("."!=p[0])return require(p);var path=parent.split("/"),segs=p.split("/");path.pop();for(var i=0;i> ":" ")+curr+"| "+line}).join("\n");err.path=filename,err.message=(filename||"ejs")+":"+lineno+"\n"+context+"\n\n"+err.message;throw err}var parse=exports.parse=function(str,options){var options=options||{},open=options.open||exports.open||"<%",close=options.close||exports.close||"%>",buf=["var buf = [];","\nwith (locals) {","\n buf.push('"],lineno=1;for(var i=0,len=str.length;ib)return 1;if(a/g,">").replace(/"/g,""")}}) \ No newline at end of file diff --git a/node_modules/nodeunit/deps/ejs/examples/client.html b/node_modules/nodeunit/deps/ejs/examples/client.html new file mode 100644 index 0000000..7081a04 --- /dev/null +++ b/node_modules/nodeunit/deps/ejs/examples/client.html @@ -0,0 +1,5 @@ + + + + + \ No newline at end of file diff --git a/node_modules/nodeunit/deps/ejs/examples/list.ejs b/node_modules/nodeunit/deps/ejs/examples/list.ejs new file mode 100644 index 0000000..d571330 --- /dev/null +++ b/node_modules/nodeunit/deps/ejs/examples/list.ejs @@ -0,0 +1,7 @@ +<% if (names.length) { %> +
      + <% names.forEach(function(name){ %> +
    • <%= name %>
    • + <% }) %> +
    +<% } %> \ No newline at end of file diff --git a/node_modules/nodeunit/deps/ejs/examples/list.js b/node_modules/nodeunit/deps/ejs/examples/list.js new file mode 100644 index 0000000..9cd7168 --- /dev/null +++ b/node_modules/nodeunit/deps/ejs/examples/list.js @@ -0,0 +1,16 @@ + +/** + * Module dependencies. + */ + +var ejs = require('../') + , fs = require('fs') + , str = fs.readFileSync(__dirname + '/list.ejs', 'utf8'); + +var ret = ejs.render(str, { + locals: { + names: ['foo', 'bar', 'baz'] + } +}); + +console.log(ret); \ No newline at end of file diff --git a/node_modules/nodeunit/deps/ejs/index.js b/node_modules/nodeunit/deps/ejs/index.js new file mode 100644 index 0000000..20bf71a --- /dev/null +++ b/node_modules/nodeunit/deps/ejs/index.js @@ -0,0 +1,2 @@ + +module.exports = require('./lib/ejs'); \ No newline at end of file diff --git a/node_modules/nodeunit/deps/ejs/lib/ejs.js b/node_modules/nodeunit/deps/ejs/lib/ejs.js new file mode 100644 index 0000000..46afa74 --- /dev/null +++ b/node_modules/nodeunit/deps/ejs/lib/ejs.js @@ -0,0 +1,251 @@ + +/*! + * EJS + * Copyright(c) 2010 TJ Holowaychuk + * MIT Licensed + */ + +/** + * Module dependencies. + */ + +var utils = require('./utils'); + +/** + * Library version. + */ + +exports.version = '0.4.3'; + +/** + * Filters. + * + * @type Object + */ + +var filters = exports.filters = require('./filters'); + +/** + * Intermediate js cache. + * + * @type Object + */ + +var cache = {}; + +/** + * Clear intermediate js cache. + * + * @api public + */ + +exports.clearCache = function(){ + cache = {}; +}; + +/** + * Translate filtered code into function calls. + * + * @param {String} js + * @return {String} + * @api private + */ + +function filtered(js) { + return js.substr(1).split('|').reduce(function(js, filter){ + var parts = filter.split(':') + , name = parts.shift() + , args = parts.shift() || ''; + if (args) args = ', ' + args; + return 'filters.' + name + '(' + js + args + ')'; + }); +}; + +/** + * Re-throw the given `err` in context to the + * `str` of ejs, `filename`, and `lineno`. + * + * @param {Error} err + * @param {String} str + * @param {String} filename + * @param {String} lineno + * @api private + */ + +function rethrow(err, str, filename, lineno){ + var lines = str.split('\n') + , start = Math.max(lineno - 3, 0) + , end = Math.min(lines.length, lineno + 3); + + // Error context + var context = lines.slice(start, end).map(function(line, i){ + var curr = i + start + 1; + return (curr == lineno ? ' >> ' : ' ') + + curr + + '| ' + + line; + }).join('\n'); + + // Alter exception message + err.path = filename; + err.message = (filename || 'ejs') + ':' + + lineno + '\n' + + context + '\n\n' + + err.message; + + throw err; +} + +/** + * Parse the given `str` of ejs, returning the function body. + * + * @param {String} str + * @return {String} + * @api public + */ + +var parse = exports.parse = function(str, options){ + var options = options || {} + , open = options.open || exports.open || '<%' + , close = options.close || exports.close || '%>'; + + var buf = [ + "var buf = [];" + , "\nwith (locals) {" + , "\n buf.push('" + ]; + + var lineno = 1; + + for (var i = 0, len = str.length; i < len; ++i) { + if (str.slice(i, open.length + i) == open) { + i += open.length + + var prefix, postfix, line = '__stack.lineno=' + lineno; + switch (str.substr(i, 1)) { + case '=': + prefix = "', escape((" + line + ', '; + postfix = ")), '"; + ++i; + break; + case '-': + prefix = "', (" + line + ', '; + postfix = "), '"; + ++i; + break; + default: + prefix = "');" + line + ';'; + postfix = "; buf.push('"; + } + + var end = str.indexOf(close, i) + , js = str.substring(i, end) + , start = i + , n = 0; + + while (~(n = js.indexOf("\n", n))) n++, lineno++; + if (js.substr(0, 1) == ':') js = filtered(js); + buf.push(prefix, js, postfix); + i += end - start + close.length - 1; + + } else if (str.substr(i, 1) == "\\") { + buf.push("\\\\"); + } else if (str.substr(i, 1) == "'") { + buf.push("\\'"); + } else if (str.substr(i, 1) == "\r") { + buf.push(" "); + } else if (str.substr(i, 1) == "\n") { + buf.push("\\n"); + lineno++; + } else { + buf.push(str.substr(i, 1)); + } + } + + buf.push("');\n}\nreturn buf.join('');"); + return buf.join(''); +}; + +/** + * Compile the given `str` of ejs into a `Function`. + * + * @param {String} str + * @param {Object} options + * @return {Function} + * @api public + */ + +var compile = exports.compile = function(str, options){ + options = options || {}; + + var input = JSON.stringify(str) + , filename = options.filename + ? JSON.stringify(options.filename) + : 'undefined'; + + // Adds the fancy stack trace meta info + str = [ + 'var __stack = { lineno: 1, input: ' + input + ', filename: ' + filename + ' };', + rethrow.toString(), + 'try {', + exports.parse(str, options), + '} catch (err) {', + ' rethrow(err, __stack.input, __stack.filename, __stack.lineno);', + '}' + ].join("\n"); + + if (options.debug) console.log(str); + var fn = new Function('locals, filters, escape', str); + return function(locals){ + return fn.call(this, locals, filters, utils.escape); + } +}; + +/** + * Render the given `str` of ejs. + * + * Options: + * + * - `locals` Local variables object + * - `cache` Compiled functions are cached, requires `filename` + * - `filename` Used by `cache` to key caches + * - `scope` Function execution context + * - `debug` Output generated function body + * - `open` Open tag, defaulting to "<%" + * - `close` Closing tag, defaulting to "%>" + * + * @param {String} str + * @param {Object} options + * @return {String} + * @api public + */ + +exports.render = function(str, options){ + var fn + , options = options || {}; + if (options.cache) { + if (options.filename) { + fn = cache[options.filename] || (cache[options.filename] = compile(str, options)); + } else { + throw new Error('"cache" option requires "filename".'); + } + } else { + fn = compile(str, options); + } + return fn.call(options.scope, options.locals || {}); +}; + +/** + * Expose to require(). + */ + +if (require.extensions) { + require.extensions['.ejs'] = function(module, filename) { + source = require('fs').readFileSync(filename, 'utf-8'); + module._compile(compile(source, {}), filename); + }; +} else if (require.registerExtension) { + require.registerExtension('.ejs', function(src) { + return compile(src, {}); + }); +} diff --git a/node_modules/nodeunit/deps/ejs/lib/filters.js b/node_modules/nodeunit/deps/ejs/lib/filters.js new file mode 100644 index 0000000..d425c8d --- /dev/null +++ b/node_modules/nodeunit/deps/ejs/lib/filters.js @@ -0,0 +1,198 @@ + +/*! + * EJS - Filters + * Copyright(c) 2010 TJ Holowaychuk + * MIT Licensed + */ + +/** + * First element of the target `obj`. + */ + +exports.first = function(obj) { + return obj[0]; +}; + +/** + * Last element of the target `obj`. + */ + +exports.last = function(obj) { + return obj[obj.length - 1]; +}; + +/** + * Capitalize the first letter of the target `str`. + */ + +exports.capitalize = function(str){ + str = String(str); + return str[0].toUpperCase() + str.substr(1, str.length); +}; + +/** + * Downcase the target `str`. + */ + +exports.downcase = function(str){ + return String(str).toLowerCase(); +}; + +/** + * Uppercase the target `str`. + */ + +exports.upcase = function(str){ + return String(str).toUpperCase(); +}; + +/** + * Sort the target `obj`. + */ + +exports.sort = function(obj){ + return Object.create(obj).sort(); +}; + +/** + * Sort the target `obj` by the given `prop` ascending. + */ + +exports.sort_by = function(obj, prop){ + return Object.create(obj).sort(function(a, b){ + a = a[prop], b = b[prop]; + if (a > b) return 1; + if (a < b) return -1; + return 0; + }); +}; + +/** + * Size or length of the target `obj`. + */ + +exports.size = exports.length = function(obj) { + return obj.length; +}; + +/** + * Add `a` and `b`. + */ + +exports.plus = function(a, b){ + return Number(a) + Number(b); +}; + +/** + * Subtract `b` from `a`. + */ + +exports.minus = function(a, b){ + return Number(a) - Number(b); +}; + +/** + * Multiply `a` by `b`. + */ + +exports.times = function(a, b){ + return Number(a) * Number(b); +}; + +/** + * Divide `a` by `b`. + */ + +exports.divided_by = function(a, b){ + return Number(a) / Number(b); +}; + +/** + * Join `obj` with the given `str`. + */ + +exports.join = function(obj, str){ + return obj.join(str || ', '); +}; + +/** + * Truncate `str` to `len`. + */ + +exports.truncate = function(str, len){ + str = String(str); + return str.substr(0, len); +}; + +/** + * Truncate `str` to `n` words. + */ + +exports.truncate_words = function(str, n){ + var str = String(str) + , words = str.split(/ +/); + return words.slice(0, n).join(' '); +}; + +/** + * Replace `pattern` with `substitution` in `str`. + */ + +exports.replace = function(str, pattern, substitution){ + return String(str).replace(pattern, substitution || ''); +}; + +/** + * Prepend `val` to `obj`. + */ + +exports.prepend = function(obj, val){ + return Array.isArray(obj) + ? [val].concat(obj) + : val + obj; +}; + +/** + * Append `val` to `obj`. + */ + +exports.append = function(obj, val){ + return Array.isArray(obj) + ? obj.concat(val) + : obj + val; +}; + +/** + * Map the given `prop`. + */ + +exports.map = function(arr, prop){ + return arr.map(function(obj){ + return obj[prop]; + }); +}; + +/** + * Reverse the given `obj`. + */ + +exports.reverse = function(obj){ + return Array.isArray(obj) + ? obj.reverse() + : String(obj).split('').reverse().join(''); +}; + +/** + * Get `prop` of the given `obj`. + */ + +exports.get = function(obj, prop){ + return obj[prop]; +}; + +/** + * Packs the given `obj` into json string + */ +exports.json = function(obj){ + return JSON.stringify(obj); +}; \ No newline at end of file diff --git a/node_modules/nodeunit/deps/ejs/lib/utils.js b/node_modules/nodeunit/deps/ejs/lib/utils.js new file mode 100644 index 0000000..8d569d6 --- /dev/null +++ b/node_modules/nodeunit/deps/ejs/lib/utils.js @@ -0,0 +1,23 @@ + +/*! + * EJS + * Copyright(c) 2010 TJ Holowaychuk + * MIT Licensed + */ + +/** + * Escape the given string of `html`. + * + * @param {String} html + * @return {String} + * @api private + */ + +exports.escape = function(html){ + return String(html) + .replace(/&(?!\w+;)/g, '&') + .replace(//g, '>') + .replace(/"/g, '"'); +}; + \ No newline at end of file diff --git a/node_modules/nodeunit/deps/ejs/package.json b/node_modules/nodeunit/deps/ejs/package.json new file mode 100644 index 0000000..224b4ff --- /dev/null +++ b/node_modules/nodeunit/deps/ejs/package.json @@ -0,0 +1,11 @@ +{ + "name": "ejs", + "description": "Embedded JavaScript templates", + "version": "0.4.3", + "author": "TJ Holowaychuk ", + "keywords": ["template", "engine", "ejs"], + "devDependencies": { + "expresso": "0.9.2" + }, + "main": "./lib/ejs.js" +} \ No newline at end of file diff --git a/node_modules/nodeunit/deps/ejs/support/compile.js b/node_modules/nodeunit/deps/ejs/support/compile.js new file mode 100644 index 0000000..edd3815 --- /dev/null +++ b/node_modules/nodeunit/deps/ejs/support/compile.js @@ -0,0 +1,173 @@ + +/** + * Module dependencies. + */ + +var fs = require('fs'); + +/** + * Arguments. + */ + +var args = process.argv.slice(2) + , pending = args.length + , files = {}; + +console.log(''); + +// parse arguments + +args.forEach(function(file){ + var mod = file.replace('lib/', ''); + fs.readFile(file, 'utf8', function(err, js){ + if (err) throw err; + console.log(' \033[90mcompile : \033[0m\033[36m%s\033[0m', file); + files[file] = parse(js); + --pending || compile(); + }); +}); + +/** + * Parse the given `js`. + */ + +function parse(js) { + return parseInheritance(parseConditionals(js)); +} + +/** + * Parse __proto__. + */ + +function parseInheritance(js) { + return js + .replace(/^ *(\w+)\.prototype\.__proto__ * = *(\w+)\.prototype *;?/gm, function(_, child, parent){ + return child + '.prototype = new ' + parent + ';\n' + + child + '.prototype.constructor = '+ child + ';\n'; + }); +} + +/** + * Parse the given `js`, currently supporting: + * + * 'if' ['node' | 'browser'] + * 'end' + * + */ + +function parseConditionals(js) { + var lines = js.split('\n') + , len = lines.length + , buffer = true + , browser = false + , buf = [] + , line + , cond; + + for (var i = 0; i < len; ++i) { + line = lines[i]; + if (/^ *\/\/ *if *(node|browser)/gm.exec(line)) { + cond = RegExp.$1; + buffer = browser = 'browser' == cond; + } else if (/^ *\/\/ *end/.test(line)) { + buffer = true; + browser = false; + } else if (browser) { + buf.push(line.replace(/^( *)\/\//, '$1')); + } else if (buffer) { + buf.push(line); + } + } + + return buf.join('\n'); +} + +/** + * Compile the files. + */ + +function compile() { + var buf = ''; + buf += '\n// CommonJS require()\n\n'; + buf += browser.require + '\n\n'; + buf += 'require.modules = {};\n\n'; + buf += 'require.resolve = ' + browser.resolve + ';\n\n'; + buf += 'require.register = ' + browser.register + ';\n\n'; + buf += 'require.relative = ' + browser.relative + ';\n\n'; + args.forEach(function(file){ + var js = files[file]; + file = file.replace('lib/', ''); + buf += '\nrequire.register("' + file + '", function(module, exports, require){\n'; + buf += js; + buf += '\n}); // module: ' + file + '\n'; + }); + fs.writeFile('ejs.js', buf, function(err){ + if (err) throw err; + console.log(' \033[90m create : \033[0m\033[36m%s\033[0m', 'ejs.js'); + console.log(); + }); +} + +// refactored version of weepy's +// https://github.com/weepy/brequire/blob/master/browser/brequire.js + +var browser = { + + /** + * Require a module. + */ + + require: function require(p){ + var path = require.resolve(p) + , mod = require.modules[path]; + if (!mod) throw new Error('failed to require "' + p + '"'); + if (!mod.exports) { + mod.exports = {}; + mod.call(mod.exports, mod, mod.exports, require.relative(path)); + } + return mod.exports; + }, + + /** + * Resolve module path. + */ + + resolve: function(path){ + var orig = path + , reg = path + '.js' + , index = path + '/index.js'; + return require.modules[reg] && reg + || require.modules[index] && index + || orig; + }, + + /** + * Return relative require(). + */ + + relative: function(parent) { + return function(p){ + if ('.' != p.substr(0, 1)) return require(p); + + var path = parent.split('/') + , segs = p.split('/'); + path.pop(); + + for (var i = 0; i < segs.length; i++) { + var seg = segs[i]; + if ('..' == seg) path.pop(); + else if ('.' != seg) path.push(seg); + } + + return require(path.join('/')); + }; + }, + + /** + * Register a module. + */ + + register: function(path, fn){ + require.modules[path] = fn; + } +}; \ No newline at end of file diff --git a/node_modules/nodeunit/deps/ejs/test/ejs.test.js b/node_modules/nodeunit/deps/ejs/test/ejs.test.js new file mode 100644 index 0000000..624157d --- /dev/null +++ b/node_modules/nodeunit/deps/ejs/test/ejs.test.js @@ -0,0 +1,269 @@ + +/** + * Module dependencies. + */ + +var ejs = require('../') + , assert = require('assert'); + +module.exports = { + 'test .version': function(){ + assert.ok(/^\d+\.\d+\.\d+$/.test(ejs.version), 'Test .version format'); + }, + + 'test html': function(){ + assert.equal('

    yay

    ', ejs.render('

    yay

    ')); + }, + + 'test buffered code': function(){ + var html = '

    tj

    ', + str = '

    <%= name %>

    ', + locals = { name: 'tj' }; + assert.equal(html, ejs.render(str, { locals: locals })); + }, + + 'test unbuffered code': function(){ + var html = '

    tj

    ', + str = '<% if (name) { %>

    <%= name %>

    <% } %>', + locals = { name: 'tj' }; + assert.equal(html, ejs.render(str, { locals: locals })); + }, + + 'test `scope` option': function(){ + var html = '

    tj

    ', + str = '

    <%= this %>

    '; + assert.equal(html, ejs.render(str, { scope: 'tj' })); + }, + + 'test escaping': function(){ + assert.equal('<script>', ejs.render('<%= " + + + + + + + + diff --git a/node_modules/nodeunit/examples/nested/nested_reporter_test.unit.js b/node_modules/nodeunit/examples/nested/nested_reporter_test.unit.js new file mode 100644 index 0000000..612adcd --- /dev/null +++ b/node_modules/nodeunit/examples/nested/nested_reporter_test.unit.js @@ -0,0 +1,94 @@ +var testCase = require('nodeunit').testCase; +/* + This is an example test suite to demonstrate the nested test reporter. + Run with --reporter nested, e.g., + nodeunit --reporter nested nested_reporter_test.unit.js + + The test output should be something like: + + nested_reporter_test.unit.js + Test 0.1 (pass) + TC 1 + TC 1.1 + Test 1.1.1 (pass) + TC 2 + TC 2.1 + TC 2.1.1 + Test 2.1.1.1 (pass) + Test 2.1.1.2 (pass) + TC 2.2.1 + Test 2.2.1.1 (pass) + TC 2.2.1.1 + Test 2.2.1.1.1 (pass) + Test 2.2.1.2 (pass) + TC 3 + TC 3.1 + TC 3.1.1 + Test 3.1.1.1 (should fail) (fail) ✖ + AssertionError: false == true + // stack trace here. + + FAILURES: 1/8 assertions failed (6ms) +*/ + +module.exports = testCase({ + "Test 0.1": function(test) { + test.ok(true); + test.done(); + }, + + "TC 1": testCase({ + "TC 1.1": testCase({ + "Test 1.1.1": function(test) { + test.ok(true); + test.done(); + } + }) + }), + + "TC 2": testCase({ + "TC 2.1": testCase({ + "TC 2.1.1": testCase({ + "Test 2.1.1.1": function(test) { + test.ok(true); + test.done(); + }, + + "Test 2.1.1.2": function(test) { + test.ok(true); + test.done(); + } + }), + + "TC 2.2.1": testCase({ + "Test 2.2.1.1": function(test) { + test.ok(true); + test.done(); + }, + + "TC 2.2.1.1": testCase({ + "Test 2.2.1.1.1": function(test) { + test.ok(true); + test.done(); + }, + }), + + "Test 2.2.1.2": function(test) { + test.ok(true); + test.done(); + } + }) + }) + }), + + "TC 3": testCase({ + "TC 3.1": testCase({ + "TC 3.1.1": testCase({ + "Test 3.1.1.1 (should fail)": function(test) { + test.ok(false); + test.done(); + } + }) + }) + }) +}); diff --git a/node_modules/nodeunit/img/example_fail.png b/node_modules/nodeunit/img/example_fail.png new file mode 100644 index 0000000..78ff425 Binary files /dev/null and b/node_modules/nodeunit/img/example_fail.png differ diff --git a/node_modules/nodeunit/img/example_machineout.png b/node_modules/nodeunit/img/example_machineout.png new file mode 100644 index 0000000..c6bfa27 Binary files /dev/null and b/node_modules/nodeunit/img/example_machineout.png differ diff --git a/node_modules/nodeunit/img/example_pass.png b/node_modules/nodeunit/img/example_pass.png new file mode 100644 index 0000000..069d716 Binary files /dev/null and b/node_modules/nodeunit/img/example_pass.png differ diff --git a/node_modules/nodeunit/index.js b/node_modules/nodeunit/index.js new file mode 100644 index 0000000..07867d0 --- /dev/null +++ b/node_modules/nodeunit/index.js @@ -0,0 +1,3 @@ +// This file is just added for convenience so this repository can be +// directly checked out into a project's deps folder +module.exports = require('./lib/nodeunit'); diff --git a/node_modules/nodeunit/lib/assert.js b/node_modules/nodeunit/lib/assert.js new file mode 100644 index 0000000..55ef744 --- /dev/null +++ b/node_modules/nodeunit/lib/assert.js @@ -0,0 +1,354 @@ +/** + * This file is based on the node.js assert module, but with some small + * changes for browser-compatibility + * THIS FILE SHOULD BE BROWSER-COMPATIBLE JS! + */ + + +/** + * Added for browser compatibility + */ + +var _keys = function(obj){ + if(Object.keys) return Object.keys(obj); + if (typeof obj != 'object' && typeof obj != 'function') { + throw new TypeError('-'); + } + var keys = []; + for(var k in obj){ + if(obj.hasOwnProperty(k)) keys.push(k); + } + return keys; +}; + + + +// http://wiki.commonjs.org/wiki/Unit_Testing/1.0 +// +// THIS IS NOT TESTED NOR LIKELY TO WORK OUTSIDE V8! +// +// Originally from narwhal.js (http://narwhaljs.org) +// Copyright (c) 2009 Thomas Robinson <280north.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 BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN +// ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + + +var pSlice = Array.prototype.slice; + +// 1. The assert module provides functions that throw +// AssertionError's when particular conditions are not met. The +// assert module must conform to the following interface. + +var assert = exports; + +// 2. The AssertionError is defined in assert. +// new assert.AssertionError({message: message, actual: actual, expected: expected}) + +assert.AssertionError = function AssertionError (options) { + this.name = "AssertionError"; + this.message = options.message; + this.actual = options.actual; + this.expected = options.expected; + this.operator = options.operator; + var stackStartFunction = options.stackStartFunction || fail; + + if (Error.captureStackTrace) { + Error.captureStackTrace(this, stackStartFunction); + } +}; +// code from util.inherits in node +assert.AssertionError.super_ = Error; + + +// EDITED FOR BROWSER COMPATIBILITY: replaced Object.create call +// TODO: test what effect this may have +var ctor = function () { this.constructor = assert.AssertionError; }; +ctor.prototype = Error.prototype; +assert.AssertionError.prototype = new ctor(); + + +assert.AssertionError.prototype.toString = function() { + if (this.message) { + return [this.name+":", this.message].join(' '); + } else { + return [ this.name+":" + , typeof this.expected !== 'undefined' ? JSON.stringify(this.expected) : 'undefined' + , this.operator + , typeof this.actual !== 'undefined' ? JSON.stringify(this.actual) : 'undefined' + ].join(" "); + } +}; + +// assert.AssertionError instanceof Error + +assert.AssertionError.__proto__ = Error.prototype; + +// At present only the three keys mentioned above are used and +// understood by the spec. Implementations or sub modules can pass +// other keys to the AssertionError's constructor - they will be +// ignored. + +// 3. All of the following functions must throw an AssertionError +// when a corresponding condition is not met, with a message that +// may be undefined if not provided. All assertion methods provide +// both the actual and expected values to the assertion error for +// display purposes. + +function fail(actual, expected, message, operator, stackStartFunction) { + throw new assert.AssertionError({ + message: message, + actual: actual, + expected: expected, + operator: operator, + stackStartFunction: stackStartFunction + }); +} + +// EXTENSION! allows for well behaved errors defined elsewhere. +assert.fail = fail; + +// 4. Pure assertion tests whether a value is truthy, as determined +// by !!guard. +// assert.ok(guard, message_opt); +// This statement is equivalent to assert.equal(true, guard, +// message_opt);. To test strictly for the value true, use +// assert.strictEqual(true, guard, message_opt);. + +assert.ok = function ok(value, message) { + if (!!!value) fail(value, true, message, "==", assert.ok); +}; + +// 5. The equality assertion tests shallow, coercive equality with +// ==. +// assert.equal(actual, expected, message_opt); + +assert.equal = function equal(actual, expected, message) { + if (actual != expected) fail(actual, expected, message, "==", assert.equal); +}; + +// 6. The non-equality assertion tests for whether two objects are not equal +// with != assert.notEqual(actual, expected, message_opt); + +assert.notEqual = function notEqual(actual, expected, message) { + if (actual == expected) { + fail(actual, expected, message, "!=", assert.notEqual); + } +}; + +// 7. The equivalence assertion tests a deep equality relation. +// assert.deepEqual(actual, expected, message_opt); + +assert.deepEqual = function deepEqual(actual, expected, message) { + if (!_deepEqual(actual, expected)) { + fail(actual, expected, message, "deepEqual", assert.deepEqual); + } +}; + +var Buffer = null; +if (typeof require !== 'undefined' && typeof process !== 'undefined') { + try { + Buffer = require('buffer').Buffer; + } + catch (e) { + // May be a CommonJS environment other than Node.js + Buffer = null; + } +} + +function _deepEqual(actual, expected) { + // 7.1. All identical values are equivalent, as determined by ===. + if (actual === expected) { + return true; + // 7.2. If the expected value is a Date object, the actual value is + // equivalent if it is also a Date object that refers to the same time. + } else if (actual instanceof Date && expected instanceof Date) { + return actual.getTime() === expected.getTime(); + + // 7.2.1 If the expcted value is a RegExp object, the actual value is + // equivalent if it is also a RegExp object that refers to the same source and options + } else if (actual instanceof RegExp && expected instanceof RegExp) { + return actual.source === expected.source && + actual.global === expected.global && + actual.ignoreCase === expected.ignoreCase && + actual.multiline === expected.multiline; + + } else if (Buffer && actual instanceof Buffer && expected instanceof Buffer) { + return (function() { + var i, len; + + for (i = 0, len = expected.length; i < len; i++) { + if (actual[i] !== expected[i]) { + return false; + } + } + return actual.length === expected.length; + })(); + // 7.3. Other pairs that do not both pass typeof value == "object", + // equivalence is determined by ==. + } else if (typeof actual != 'object' && typeof expected != 'object') { + return actual == expected; + + // 7.4. For all other Object pairs, including Array objects, equivalence is + // determined by having the same number of owned properties (as verified + // with Object.prototype.hasOwnProperty.call), the same set of keys + // (although not necessarily the same order), equivalent values for every + // corresponding key, and an identical "prototype" property. Note: this + // accounts for both named and indexed properties on Arrays. + } else { + return objEquiv(actual, expected); + } +} + +function isUndefinedOrNull (value) { + return value === null || value === undefined; +} + +function isArguments (object) { + return Object.prototype.toString.call(object) == '[object Arguments]'; +} + +function objEquiv (a, b) { + if (isUndefinedOrNull(a) || isUndefinedOrNull(b)) + return false; + // an identical "prototype" property. + if (a.prototype !== b.prototype) return false; + //~~~I've managed to break Object.keys through screwy arguments passing. + // Converting to array solves the problem. + if (isArguments(a)) { + if (!isArguments(b)) { + return false; + } + a = pSlice.call(a); + b = pSlice.call(b); + return _deepEqual(a, b); + } + try{ + var ka = _keys(a), + kb = _keys(b), + key, i; + } catch (e) {//happens when one is a string literal and the other isn't + return false; + } + // having the same number of owned properties (keys incorporates hasOwnProperty) + if (ka.length != kb.length) + return false; + //the same set of keys (although not necessarily the same order), + ka.sort(); + kb.sort(); + //~~~cheap key test + for (i = ka.length - 1; i >= 0; i--) { + if (ka[i] != kb[i]) + return false; + } + //equivalent values for every corresponding key, and + //~~~possibly expensive deep test + for (i = ka.length - 1; i >= 0; i--) { + key = ka[i]; + if (!_deepEqual(a[key], b[key] )) + return false; + } + return true; +} + +// 8. The non-equivalence assertion tests for any deep inequality. +// assert.notDeepEqual(actual, expected, message_opt); + +assert.notDeepEqual = function notDeepEqual(actual, expected, message) { + if (_deepEqual(actual, expected)) { + fail(actual, expected, message, "notDeepEqual", assert.notDeepEqual); + } +}; + +// 9. The strict equality assertion tests strict equality, as determined by ===. +// assert.strictEqual(actual, expected, message_opt); + +assert.strictEqual = function strictEqual(actual, expected, message) { + if (actual !== expected) { + fail(actual, expected, message, "===", assert.strictEqual); + } +}; + +// 10. The strict non-equality assertion tests for strict inequality, as determined by !==. +// assert.notStrictEqual(actual, expected, message_opt); + +assert.notStrictEqual = function notStrictEqual(actual, expected, message) { + if (actual === expected) { + fail(actual, expected, message, "!==", assert.notStrictEqual); + } +}; + +function expectedException(actual, expected) { + if (!actual || !expected) { + return false; + } + + if (expected instanceof RegExp) { + return expected.test(actual.message || actual); + } else if (actual instanceof expected) { + return true; + } else if (expected.call({}, actual) === true) { + return true; + } + + return false; +} + +function _throws(shouldThrow, block, expected, message) { + var actual; + + if (typeof expected === 'string') { + message = expected; + expected = null; + } + + try { + block(); + } catch (e) { + actual = e; + } + + message = (expected && expected.name ? ' (' + expected.name + ').' : '.') + + (message ? ' ' + message : '.'); + + if (shouldThrow && !actual) { + fail('Missing expected exception' + message); + } + + if (!shouldThrow && expectedException(actual, expected)) { + fail('Got unwanted exception' + message); + } + + if ((shouldThrow && actual && expected && + !expectedException(actual, expected)) || (!shouldThrow && actual)) { + throw actual; + } +} + +// 11. Expected to throw an error: +// assert.throws(block, Error_opt, message_opt); + +assert.throws = function(block, /*optional*/error, /*optional*/message) { + _throws.apply(this, [true].concat(pSlice.call(arguments))); +}; + +// EXTENSION! This is annoying to write outside this module. +assert.doesNotThrow = function(block, /*optional*/error, /*optional*/message) { + _throws.apply(this, [false].concat(pSlice.call(arguments))); +}; + +assert.ifError = function (err) { if (err) {throw err;}}; diff --git a/node_modules/nodeunit/lib/core.js b/node_modules/nodeunit/lib/core.js new file mode 100644 index 0000000..8ff031b --- /dev/null +++ b/node_modules/nodeunit/lib/core.js @@ -0,0 +1,319 @@ +/*! + * Nodeunit + * Copyright (c) 2010 Caolan McMahon + * MIT Licensed + * + * THIS FILE SHOULD BE BROWSER-COMPATIBLE JS! + * You can use @REMOVE_LINE_FOR_BROWSER to remove code from the browser build. + * Only code on that line will be removed, it's mostly to avoid requiring code + * that is node specific + */ + +/** + * Module dependencies + */ + +var async = require('../deps/async'), //@REMOVE_LINE_FOR_BROWSER + nodeunit = require('./nodeunit'), //@REMOVE_LINE_FOR_BROWSER + types = require('./types'); //@REMOVE_LINE_FOR_BROWSER + + +/** + * Added for browser compatibility + */ + +var _keys = function (obj) { + if (Object.keys) { + return Object.keys(obj); + } + var keys = []; + for (var k in obj) { + if (obj.hasOwnProperty(k)) { + keys.push(k); + } + } + return keys; +}; + + +var _copy = function (obj) { + var nobj = {}; + var keys = _keys(obj); + for (var i = 0; i < keys.length; i += 1) { + nobj[keys[i]] = obj[keys[i]]; + } + return nobj; +}; + + +/** + * Runs a test function (fn) from a loaded module. After the test function + * calls test.done(), the callback is executed with an assertionList as its + * second argument. + * + * @param {String} name + * @param {Function} fn + * @param {Object} opt + * @param {Function} callback + * @api public + */ + +exports.runTest = function (name, fn, opt, callback) { + var options = types.options(opt); + + options.testStart(name); + var start = new Date().getTime(); + var test = types.test(name, start, options, callback); + + options.testReady(test); + try { + fn(test); + } + catch (e) { + test.done(e); + } +}; + +/** + * Takes an object containing test functions or other test suites as properties + * and runs each in series. After all tests have completed, the callback is + * called with a list of all assertions as the second argument. + * + * If a name is passed to this function it is prepended to all test and suite + * names that run within it. + * + * @param {String} name + * @param {Object} suite + * @param {Object} opt + * @param {Function} callback + * @api public + */ + +exports.runSuite = function (name, suite, opt, callback) { + suite = wrapGroup(suite); + var keys = _keys(suite); + + async.concatSeries(keys, function (k, cb) { + var prop = suite[k], _name; + + _name = name ? [].concat(name, k) : [k]; + _name.toString = function () { + // fallback for old one + return this.join(' - '); + }; + + if (typeof prop === 'function') { + var in_name = false, + in_specific_test = (_name.toString() === opt.testFullSpec) ? true : false; + for (var i = 0; i < _name.length; i += 1) { + if (_name[i] === opt.testspec) { + in_name = true; + } + } + + if ((!opt.testFullSpec || in_specific_test) && (!opt.testspec || in_name)) { + if (opt.moduleStart) { + opt.moduleStart(); + } + exports.runTest(_name, suite[k], opt, cb); + } + else { + return cb(); + } + } + else { + exports.runSuite(_name, suite[k], opt, cb); + } + }, callback); +}; + +/** + * Run each exported test function or test suite from a loaded module. + * + * @param {String} name + * @param {Object} mod + * @param {Object} opt + * @param {Function} callback + * @api public + */ + +exports.runModule = function (name, mod, opt, callback) { + var options = _copy(types.options(opt)); + + var _run = false; + var _moduleStart = options.moduleStart; + + mod = wrapGroup(mod); + + function run_once() { + if (!_run) { + _run = true; + _moduleStart(name); + } + } + options.moduleStart = run_once; + + var start = new Date().getTime(); + + exports.runSuite(null, mod, options, function (err, a_list) { + var end = new Date().getTime(); + var assertion_list = types.assertionList(a_list, end - start); + options.moduleDone(name, assertion_list); + if (nodeunit.complete) { + nodeunit.complete(name, assertion_list); + } + callback(null, a_list); + }); +}; + +/** + * Treats an object literal as a list of modules keyed by name. Runs each + * module and finished with calling 'done'. You can think of this as a browser + * safe alternative to runFiles in the nodeunit module. + * + * @param {Object} modules + * @param {Object} opt + * @api public + */ + +// TODO: add proper unit tests for this function +exports.runModules = function (modules, opt) { + var all_assertions = []; + var options = types.options(opt); + var start = new Date().getTime(); + + async.concatSeries(_keys(modules), function (k, cb) { + exports.runModule(k, modules[k], options, cb); + }, + function (err, all_assertions) { + var end = new Date().getTime(); + options.done(types.assertionList(all_assertions, end - start)); + }); +}; + + +/** + * Wraps a test function with setUp and tearDown functions. + * Used by testCase. + * + * @param {Function} setUp + * @param {Function} tearDown + * @param {Function} fn + * @api private + */ + +var wrapTest = function (setUp, tearDown, fn) { + return function (test) { + var context = {}; + if (tearDown) { + var done = test.done; + test.done = function (err) { + try { + tearDown.call(context, function (err2) { + if (err && err2) { + test._assertion_list.push( + types.assertion({error: err}) + ); + return done(err2); + } + done(err || err2); + }); + } + catch (e) { + done(e); + } + }; + } + if (setUp) { + setUp.call(context, function (err) { + if (err) { + return test.done(err); + } + fn.call(context, test); + }); + } + else { + fn.call(context, test); + } + }; +}; + + +/** + * Returns a serial callback from two functions. + * + * @param {Function} funcFirst + * @param {Function} funcSecond + * @api private + */ + +var getSerialCallback = function (fns) { + if (!fns.length) { + return null; + } + return function (callback) { + var that = this; + var bound_fns = []; + for (var i = 0, len = fns.length; i < len; i++) { + (function (j) { + bound_fns.push(function () { + return fns[j].apply(that, arguments); + }); + })(i); + } + return async.series(bound_fns, callback); + }; +}; + + +/** + * Wraps a group of tests with setUp and tearDown functions. + * Used by testCase. + * + * @param {Object} group + * @param {Array} setUps - parent setUp functions + * @param {Array} tearDowns - parent tearDown functions + * @api private + */ + +var wrapGroup = function (group, setUps, tearDowns) { + var tests = {}; + + var setUps = setUps ? setUps.slice(): []; + var tearDowns = tearDowns ? tearDowns.slice(): []; + + if (group.setUp) { + setUps.push(group.setUp); + delete group.setUp; + } + if (group.tearDown) { + tearDowns.unshift(group.tearDown); + delete group.tearDown; + } + + var keys = _keys(group); + + for (var i = 0; i < keys.length; i += 1) { + var k = keys[i]; + if (typeof group[k] === 'function') { + tests[k] = wrapTest( + getSerialCallback(setUps), + getSerialCallback(tearDowns), + group[k] + ); + } + else if (typeof group[k] === 'object') { + tests[k] = wrapGroup(group[k], setUps, tearDowns); + } + } + return tests; +}; + + +/** + * Backwards compatibility for test suites using old testCase API + */ + +exports.testCase = function (suite) { + return suite; +}; diff --git a/node_modules/nodeunit/lib/nodeunit.js b/node_modules/nodeunit/lib/nodeunit.js new file mode 100644 index 0000000..7d33c7b --- /dev/null +++ b/node_modules/nodeunit/lib/nodeunit.js @@ -0,0 +1,104 @@ +/*! + * Nodeunit + * Copyright (c) 2010 Caolan McMahon + * MIT Licensed + */ + +/** + * Module dependencies + */ + +var async = require('../deps/async'), + types = require('./types'), + utils = require('./utils'), + core = require('./core'), + reporters = require('./reporters'), + assert = require('./assert'), + path = require('path'), + events = require('events'); + + +/** + * Export sub-modules. + */ + +exports.types = types; +exports.utils = utils; +exports.reporters = reporters; +exports.assert = assert; + +// backwards compatibility +exports.testrunner = { + run: function () { + console.log( + 'WARNING: nodeunit.testrunner is going to be deprecated, please ' + + 'use nodeunit.reporters.default instead!' + ); + return reporters['default'].run.apply(this, arguments); + } +}; + + +/** + * Export all core functions + */ + +for (var k in core) { + exports[k] = core[k]; +}; + + +/** + * Load modules from paths array and run all exported tests in series. If a path + * is a directory, load all supported file types inside it as modules. This only + * reads 1 level deep in the directory and does not recurse through + * sub-directories. + * + * @param {Array} paths + * @param {Object} opt + * @api public + */ + +exports.runFiles = function (paths, opt) { + var all_assertions = []; + var options = types.options(opt); + var start = new Date().getTime(); + + if (!paths.length) { + return options.done(types.assertionList(all_assertions)); + } + + utils.modulePaths(paths, function (err, files) { + if (err) throw err; + async.concatSeries(files, function (file, cb) { + var name = path.basename(file); + exports.runModule(name, require(file), options, cb); + }, + function (err, all_assertions) { + var end = new Date().getTime(); + exports.done() + options.done(types.assertionList(all_assertions, end - start)); + }); + }); + +}; + +/* Export all prototypes from events.EventEmitter */ +var label; +for (label in events.EventEmitter.prototype) { + exports[label] = events.EventEmitter.prototype[label]; +} + +/* Emit event 'complete' on completion of a test suite. */ +exports.complete = function(name, assertions) +{ + exports.emit('complete', name, assertions); +}; + +/* Emit event 'complete' on completion of all tests. */ +exports.done = function() +{ + exports.emit('done'); +}; + +module.exports = exports; diff --git a/node_modules/nodeunit/lib/reporters/browser.js b/node_modules/nodeunit/lib/reporters/browser.js new file mode 100644 index 0000000..c769c41 --- /dev/null +++ b/node_modules/nodeunit/lib/reporters/browser.js @@ -0,0 +1,123 @@ +/*! + * Nodeunit + * Copyright (c) 2010 Caolan McMahon + * MIT Licensed + * + * THIS FILE SHOULD BE BROWSER-COMPATIBLE JS! + * You can use @REMOVE_LINE_FOR_BROWSER to remove code from the browser build. + * Only code on that line will be removed, its mostly to avoid requiring code + * that is node specific + */ + + +/** + * NOTE: this test runner is not listed in index.js because it cannot be + * used with the command-line tool, only inside the browser. + */ + + +/** + * Reporter info string + */ + +exports.info = "Browser-based test reporter"; + + +/** + * Run all tests within each module, reporting the results + * + * @param {Array} files + * @api public + */ + +exports.run = function (modules, options, callback) { + var start = new Date().getTime(), div; + options = options || {}; + div = options.div || document.body; + + function setText(el, txt) { + if ('innerText' in el) { + el.innerText = txt; + } + else if ('textContent' in el){ + el.textContent = txt; + } + } + + function getOrCreate(tag, id) { + var el = document.getElementById(id); + if (!el) { + el = document.createElement(tag); + el.id = id; + div.appendChild(el); + } + return el; + }; + + var header = getOrCreate('h1', 'nodeunit-header'); + var banner = getOrCreate('h2', 'nodeunit-banner'); + var userAgent = getOrCreate('h2', 'nodeunit-userAgent'); + var tests = getOrCreate('ol', 'nodeunit-tests'); + var result = getOrCreate('p', 'nodeunit-testresult'); + + setText(userAgent, navigator.userAgent); + + nodeunit.runModules(modules, { + moduleStart: function (name) { + /*var mheading = document.createElement('h2'); + mheading.innerText = name; + results.appendChild(mheading); + module = document.createElement('ol'); + results.appendChild(module);*/ + }, + testDone: function (name, assertions) { + var test = document.createElement('li'); + var strong = document.createElement('strong'); + strong.innerHTML = name + ' (' + + '' + assertions.failures() + ', ' + + '' + assertions.passes() + ', ' + + assertions.length + + ')'; + test.className = assertions.failures() ? 'fail': 'pass'; + test.appendChild(strong); + + var aList = document.createElement('ol'); + aList.style.display = 'none'; + test.onclick = function () { + var d = aList.style.display; + aList.style.display = (d == 'none') ? 'block': 'none'; + }; + for (var i=0; i' + (a.error.stack || a.error) + '
    '; + li.className = 'fail'; + } + else { + li.innerHTML = a.message || a.method || 'no message'; + li.className = 'pass'; + } + aList.appendChild(li); + } + test.appendChild(aList); + tests.appendChild(test); + }, + done: function (assertions) { + var end = new Date().getTime(); + var duration = end - start; + + var failures = assertions.failures(); + banner.className = failures ? 'fail': 'pass'; + + result.innerHTML = 'Tests completed in ' + duration + + ' milliseconds.
    ' + + assertions.passes() + ' assertions of ' + + '' + assertions.length + ' passed, ' + + assertions.failures() + ' failed.'; + + if (callback) callback(assertions.failures() ? new Error('We have got test failures.') : undefined); + } + }); +}; diff --git a/node_modules/nodeunit/lib/reporters/default.js b/node_modules/nodeunit/lib/reporters/default.js new file mode 100644 index 0000000..0de3f23 --- /dev/null +++ b/node_modules/nodeunit/lib/reporters/default.js @@ -0,0 +1,131 @@ +/*! + * Nodeunit + * Copyright (c) 2010 Caolan McMahon + * MIT Licensed + */ + +/** + * Module dependencies + */ + +var nodeunit = require('../nodeunit'), + utils = require('../utils'), + fs = require('fs'), + track = require('../track'), + path = require('path'), + AssertionError = require('../assert').AssertionError; + +/** + * Reporter info string + */ + +exports.info = "Default tests reporter"; + + +/** + * Run all tests within each module, reporting the results to the command-line. + * + * @param {Array} files + * @api public + */ + +exports.run = function (files, options, callback) { + + if (!options) { + // load default options + var content = fs.readFileSync( + __dirname + '/../../bin/nodeunit.json', 'utf8' + ); + options = JSON.parse(content); + } + + var error = function (str) { + return options.error_prefix + str + options.error_suffix; + }; + var ok = function (str) { + return options.ok_prefix + str + options.ok_suffix; + }; + var bold = function (str) { + return options.bold_prefix + str + options.bold_suffix; + }; + var assertion_message = function (str) { + return options.assertion_prefix + str + options.assertion_suffix; + }; + + var start = new Date().getTime(); + var tracker = track.createTracker(function (tracker) { + if (tracker.unfinished()) { + console.log(''); + console.log(error(bold( + 'FAILURES: Undone tests (or their setups/teardowns): ' + ))); + var names = tracker.names(); + for (var i = 0; i < names.length; i += 1) { + console.log('- ' + names[i]); + } + console.log(''); + console.log('To fix this, make sure all tests call test.done()'); + process.reallyExit(tracker.unfinished()); + } + }); + + var opts = { + testspec: options.testspec, + testFullSpec: options.testFullSpec, + moduleStart: function (name) { + console.log('\n' + bold(name)); + }, + testDone: function (name, assertions) { + tracker.remove(name); + + if (!assertions.failures()) { + console.log('✔ ' + name); + } + else { + console.log(error('✖ ' + name) + '\n'); + assertions.forEach(function (a) { + if (a.failed()) { + a = utils.betterErrors(a); + if (a.error instanceof AssertionError && a.message) { + console.log( + 'Assertion Message: ' + + assertion_message(a.message) + ); + } + console.log(a.error.stack + '\n'); + } + }); + } + }, + done: function (assertions, end) { + var end = end || new Date().getTime(); + var duration = end - start; + if (assertions.failures()) { + console.log( + '\n' + bold(error('FAILURES: ')) + assertions.failures() + + '/' + assertions.length + ' assertions failed (' + + assertions.duration + 'ms)' + ); + } + else { + console.log( + '\n' + bold(ok('OK: ')) + assertions.length + + ' assertions (' + assertions.duration + 'ms)' + ); + } + + if (callback) callback(assertions.failures() ? new Error('We have got test failures.') : undefined); + }, + testStart: function(name) { + tracker.put(name); + } + }; + if (files && files.length) { + var paths = files.map(function (p) { + return path.resolve(p); + }); + nodeunit.runFiles(paths, opts); + } else { + nodeunit.runModules(files,opts); + } +}; diff --git a/node_modules/nodeunit/lib/reporters/eclipse.js b/node_modules/nodeunit/lib/reporters/eclipse.js new file mode 100644 index 0000000..c56a4b8 --- /dev/null +++ b/node_modules/nodeunit/lib/reporters/eclipse.js @@ -0,0 +1,104 @@ +/*! + * Nodeunit + * Copyright (c) 2010 Caolan McMahon + * MIT Licensed + */ + +/** + * Module dependencies + */ + +var nodeunit = require('../nodeunit'), + utils = require('../utils'), + fs = require('fs'), + track = require('../track'), + path = require('path'), + AssertionError = require('../assert').AssertionError; + +/** + * Reporter info string + */ + +exports.info = "Reporter for eclipse plugin"; + + +/** + * Run all tests within each module, reporting the results to the command-line. + * + * @param {Array} files + * @api public + */ + +exports.run = function (files, options, callback) { + + var start = new Date().getTime(); + var paths = files.map(function (p) { + if (p.indexOf('/') === 0) { + return p; + } + return path.resolve(p); + }); + var tracker = track.createTracker(function (tracker) { + if (tracker.unfinished()) { + console.log(''); + console.log('FAILURES: Undone tests (or their setups/teardowns): '); + var names = tracker.names(); + for (var i = 0; i < names.length; i += 1) { + console.log('- ' + names[i]); + } + console.log(''); + console.log('To fix this, make sure all tests call test.done()'); + process.reallyExit(tracker.unfinished()); + } + }); + + nodeunit.runFiles(paths, { + testspec: undefined, + moduleStart: function (name) { + console.log('\n' + name); + }, + testDone: function (name, assertions) { + tracker.remove(name); + + if (!assertions.failures()) { + console.log('✔ ' + name); + } + else { + console.log('✖ ' + name + '\n'); + assertions.forEach(function (a) { + if (a.failed()) { + a = utils.betterErrors(a); + if (a.error instanceof AssertionError && a.message) { + console.log( + 'Assertion Message: ' + a.message + ); + } + console.log(a.error.stack + '\n'); + } + }); + } + }, + done: function (assertions, end) { + var end = end || new Date().getTime(); + var duration = end - start; + if (assertions.failures()) { + console.log( + '\n' + 'FAILURES: ' + assertions.failures() + + '/' + assertions.length + ' assertions failed (' + + assertions.duration + 'ms)' + ); + } + else { + console.log( + '\n' + 'OK: ' + assertions.length + + ' assertions (' + assertions.duration + 'ms)' + ); + } + + if (callback) callback(assertions.failures() ? new Error('We have got test failures.') : undefined); + }, + testStart: function (name) { + tracker.put(name); + } + }); +}; diff --git a/node_modules/nodeunit/lib/reporters/html.js b/node_modules/nodeunit/lib/reporters/html.js new file mode 100644 index 0000000..ac64650 --- /dev/null +++ b/node_modules/nodeunit/lib/reporters/html.js @@ -0,0 +1,110 @@ +/*! + * Nodeunit + * Copyright (c) 2010 Caolan McMahon + * MIT Licensed + */ + +/** + * Module dependencies + */ + +var nodeunit = require('../nodeunit'), + utils = require('../utils'), + fs = require('fs'), + path = require('path'), + AssertionError = require('assert').AssertionError; + +/** + * Reporter info string + */ + +exports.info = "Report tests result as HTML"; + +/** + * Run all tests within each module, reporting the results to the command-line. + * + * @param {Array} files + * @api public + */ + +exports.run = function (files, options, callback) { + + var start = new Date().getTime(); + var paths = files.map(function (p) { + return path.resolve(p); + }); + + console.log(''); + console.log(''); + console.log(''); + console.log(''); + console.log(''); + console.log(''); + nodeunit.runFiles(paths, { + testspec: options.testspec, + testFullSpec: options.testFullSpec, + moduleStart: function (name) { + console.log('

    ' + name + '

    '); + console.log('
      '); + }, + testDone: function (name, assertions) { + if (!assertions.failures()) { + console.log('
    1. ' + name + '
    2. '); + } + else { + console.log('
    3. ' + name); + assertions.forEach(function (a) { + if (a.failed()) { + a = utils.betterErrors(a); + if (a.error instanceof AssertionError && a.message) { + console.log('
      ' + + 'Assertion Message: ' + a.message + + '
      '); + } + console.log('
      ');
      +                        console.log(a.error.stack);
      +                        console.log('
      '); + } + }); + console.log('
    4. '); + } + }, + moduleDone: function () { + console.log('
    '); + }, + done: function (assertions) { + var end = new Date().getTime(); + var duration = end - start; + if (assertions.failures()) { + console.log( + '

    FAILURES: ' + assertions.failures() + + '/' + assertions.length + ' assertions failed (' + + assertions.duration + 'ms)

    ' + ); + } + else { + console.log( + '

    OK: ' + assertions.length + + ' assertions (' + assertions.duration + 'ms)

    ' + ); + } + console.log(''); + console.log(''); + + if (callback) callback(assertions.failures() ? new Error('We have got test failures.') : undefined); + } + }); +}; diff --git a/node_modules/nodeunit/lib/reporters/index.js b/node_modules/nodeunit/lib/reporters/index.js new file mode 100644 index 0000000..10eff3c --- /dev/null +++ b/node_modules/nodeunit/lib/reporters/index.js @@ -0,0 +1,27 @@ +// This is a hack to make browserify skip tap +var tap; +try { + tap = require('./' + 'tap'); +} catch (ex) { + tap = { + run: function() { + throw new Error('Sorry, tap reporter not available'); + } + }; +} + +module.exports = { + 'junit': require('./junit'), + 'default': require('./default'), + 'skip_passed': require('./skip_passed'), + 'minimal': require('./minimal'), + 'html': require('./html'), + 'eclipse': require('./eclipse'), + 'machineout': require('./machineout'), + 'tap': tap, + 'nested': require('./nested'), + 'verbose' : require('./verbose'), + 'lcov' : require('./lcov') + // browser test reporter is not listed because it cannot be used + // with the command line tool, only inside a browser. +}; diff --git a/node_modules/nodeunit/lib/reporters/junit.js b/node_modules/nodeunit/lib/reporters/junit.js new file mode 100644 index 0000000..5400526 --- /dev/null +++ b/node_modules/nodeunit/lib/reporters/junit.js @@ -0,0 +1,180 @@ +/*! + * Nodeunit + * Copyright (c) 2010 Caolan McMahon + * MIT Licensed + */ + +/** + * Module dependencies + */ + +var nodeunit = require('../nodeunit'), + utils = require('../utils'), + fs = require('fs'), + path = require('path'), + async = require('../../deps/async'), + AssertionError = require('assert').AssertionError, + child_process = require('child_process'), + ejs = require('../../deps/ejs'); + + +/** + * Reporter info string + */ + +exports.info = "jUnit XML test reports"; + + +/** + * Ensures a directory exists using mkdir -p. + * + * @param {String} path + * @param {Function} callback + * @api private + */ + +var ensureDir = function (path, callback) { + var mkdir = child_process.spawn('mkdir', ['-p', path]); + mkdir.on('error', function (err) { + callback(err); + callback = function(){}; + }); + mkdir.on('exit', function (code) { + if (code === 0) callback(); + else callback(new Error('mkdir exited with code: ' + code)); + }); +}; + + +/** + * Returns absolute version of a path. Relative paths are interpreted + * relative to process.cwd() or the cwd parameter. Paths that are already + * absolute are returned unaltered. + * + * @param {String} p + * @param {String} cwd + * @return {String} + * @api public + */ + +var abspath = function (p, /*optional*/cwd) { + if (p[0] === '/') return p; + cwd = cwd || process.cwd(); + return path.normalize(path.resolve(p)); +}; + + +/** + * Run all tests within each module, reporting the results to the command-line, + * then writes out junit-compatible xml documents. + * + * @param {Array} files + * @api public + */ + +exports.run = function (files, opts, callback) { + if (!opts.output) { + console.error( + 'Error: No output directory defined.\n' + + '\tEither add an "output" property to your nodeunit.json config ' + + 'file, or\n\tuse the --output command line option.' + ); + return; + } + opts.output = abspath(opts.output); + var error = function (str) { + return opts.error_prefix + str + opts.error_suffix; + }; + var ok = function (str) { + return opts.ok_prefix + str + opts.ok_suffix; + }; + var bold = function (str) { + return opts.bold_prefix + str + opts.bold_suffix; + }; + + var start = new Date().getTime(); + var paths = files.map(function (p) { + return path.resolve(p); + }); + + var modules = {} + var curModule; + + nodeunit.runFiles(paths, { + testspec: opts.testspec, + testFullSpec: opts.testFullSpec, + moduleStart: function (name) { + curModule = { + errorCount: 0, + failureCount: 0, + tests: 0, + testcases: [], + name: name + }; + modules[name] = curModule; + }, + testDone: function (name, assertions) { + var testcase = {name: name}; + for (var i=0; i name_slice(['TC1', 'TC1.1', 'mytest'], 1); + * "TC1,TC1.1" + */ + var name_slice = function (name_arr, end_index) { + return name_arr.slice(0, end_index + 1).join(","); + }; + + var indent = (function () { + var txt = ''; + var i; + for (i = 0; i < spaces_per_indent; i++) { + txt += ' '; + } + return txt; + }()); + + // Indent once for each indent_level + var add_indent = function (txt, indent_level) { + var k; + for (k = 0; k < indent_level; k++) { + txt += indent; + } + return txt; + }; + + // If it's not the last element of the name_arr, it's a testCase. + var is_testCase = function (name_arr, index) { + return index === name_arr.length - 1 ? false : true; + }; + + var testCase_line = function (txt) { + return txt + "\n"; + }; + + /** + * Prints (console.log) the nested test status line(s). + * + * @param {Array} name_arr - Array of name elements. + * @param {String} status - either 'pass' or 'fail'. + * @example + * > print_status(['TC1', 'TC1.1', 'mytest'], 'pass'); + * TC1 + * TC1.1 + * mytest (pass) + */ + var print_status = function (name_arr, status) { + var txt = ''; + var _name_slice, part, i; + for (i = 0; i < name_arr.length; i++) { + _name_slice = name_slice(name_arr, i); + part = name_arr[i]; + if (!tracker.already_printed[_name_slice]) { + txt = add_indent(txt, i); + if (is_testCase(name_arr, i)) { + txt += testCase_line(part); + } else { + txt += status_text(part, status); + } + tracker.already_printed[_name_slice] = true; + } + } + console.log(txt); + }; + + nodeunit.runFiles(paths, { + testspec: options.testspec, + testFullSpec: options.testFullSpec, + moduleStart: function (name) { + console.log('\n' + bold(name)); + }, + testDone: function (name, assertions) { + tracker.remove(name); + + if (!assertions.failures()) { + print_status(name, 'pass'); + } else { + print_status(name, 'fail'); + assertions.forEach(function (a) { + if (a.failed()) { + a = utils.betterErrors(a); + if (a.error instanceof AssertionError && a.message) { + console.log( + 'Assertion Message: ' + + assertion_message(a.message) + ); + } + console.log(a.error.stack + '\n'); + } + }); + } + }, + done: function (assertions, end) { + end = end || new Date().getTime(); + var duration = end - start; + if (assertions.failures()) { + console.log( + '\n' + bold(error('FAILURES: ')) + assertions.failures() + + '/' + assertions.length + ' assertions failed (' + + assertions.duration + 'ms)' + ); + } else { + console.log( + '\n' + bold(ok('OK: ')) + assertions.length + + ' assertions (' + assertions.duration + 'ms)' + ); + } + + if (callback) callback(assertions.failures() ? new Error('We have got test failures.') : undefined); + }, + testStart: function (name) { + tracker.put(name); + } + }); +}; diff --git a/node_modules/nodeunit/lib/reporters/skip_passed.js b/node_modules/nodeunit/lib/reporters/skip_passed.js new file mode 100644 index 0000000..e63489b --- /dev/null +++ b/node_modules/nodeunit/lib/reporters/skip_passed.js @@ -0,0 +1,108 @@ +/*! + * Nodeunit + * Copyright (c) 2010 Caolan McMahon + * MIT Licensed + */ + +/** + * Module dependencies + */ + +var nodeunit = require('../nodeunit'), + utils = require('../utils'), + fs = require('fs'), + path = require('path'), + AssertionError = require('assert').AssertionError; + +/** + * Reporter info string + */ + +exports.info = "Skip passed tests output"; + +/** + * Run all tests within each module, reporting the results to the command-line. + * + * @param {Array} files + * @api public + */ + +exports.run = function (files, options, callback) { + + if (!options) { + // load default options + var content = fs.readFileSync( + __dirname + '/../../bin/nodeunit.json', 'utf8' + ); + options = JSON.parse(content); + } + + var error = function (str) { + return options.error_prefix + str + options.error_suffix; + }; + var ok = function (str) { + return options.ok_prefix + str + options.ok_suffix; + }; + var bold = function (str) { + return options.bold_prefix + str + options.bold_suffix; + }; + var assertion_message = function (str) { + return options.assertion_prefix + str + options.assertion_suffix; + }; + + var start = new Date().getTime(); + var paths = files.map(function (p) { + return path.resolve(p); + }); + + nodeunit.runFiles(paths, { + testspec: options.testspec, + testFullSpec: options.testFullSpec, + moduleStart: function (name) { + console.log('\n' + bold(name)); + }, + testDone: function (name, assertions) { + if (assertions.failures()) { + console.log(error('✖ ' + name) + '\n'); + assertions.forEach(function (a) { + if (a.failed()) { + a = utils.betterErrors(a); + if (a.error instanceof AssertionError && a.message) { + console.log( + 'Assertion Message: ' + assertion_message(a.message) + ); + } + console.log(a.error.stack + '\n'); + } + }); + } + }, + moduleDone: function (name, assertions) { + if (!assertions.failures()) { + console.log('✔ all tests passed'); + } + else { + console.log(error('✖ some tests failed')); + } + }, + done: function (assertions) { + var end = new Date().getTime(); + var duration = end - start; + if (assertions.failures()) { + console.log( + '\n' + bold(error('FAILURES: ')) + assertions.failures() + + '/' + assertions.length + ' assertions failed (' + + assertions.duration + 'ms)' + ); + } + else { + console.log( + '\n' + bold(ok('OK: ')) + assertions.length + + ' assertions (' + assertions.duration + 'ms)' + ); + } + + if (callback) callback(assertions.failures() ? new Error('We have got test failures.') : undefined); + } + }); +}; diff --git a/node_modules/nodeunit/lib/reporters/tap.js b/node_modules/nodeunit/lib/reporters/tap.js new file mode 100644 index 0000000..8f7034c --- /dev/null +++ b/node_modules/nodeunit/lib/reporters/tap.js @@ -0,0 +1,67 @@ +/** + * Module dependencies + */ + +var nodeunit = require('../nodeunit'), + path = require('path'), + assert = require('tap').assert, + TapProducer = require('tap').Producer, + fs = require('fs'); + +/** + * Reporter info string + */ + +exports.info = "TAP output"; + +/** + * Run all tests within each module, reporting the results to the command-line. + * + * @param {Array} files + * @api public + */ + +exports.run = function (files, options, callback) { + + if (!options) { + // load default options + var content = fs.readFileSync( + __dirname + '/../../bin/nodeunit.json', 'utf8' + ); + options = JSON.parse(content); + } + + var paths = files.map(function (p) { + return path.resolve(p); + }); + var output = new TapProducer(); + output.pipe(process.stdout); + + nodeunit.runFiles(paths, { + testStart: function (name) { + output.write(name.toString()); + }, + testDone: function (name, assertions) { + assertions.forEach(function (e) { + var extra = {}; + if (e.error) { + extra.error = { + name: e.error.name, + message: e.error.message, + stack: e.error.stack.split(/\n/).filter(function (line) { + // exclude line of "types.js" + return ! RegExp(/types.js:83:39/).test(line); + }).join('\n') + }; + extra.wanted = e.error.expected; + extra.found = e.error.actual; + } + output.write(assert(e.passed(), e.message, extra)); + }); + }, + done: function (assertions) { + output.end(); + if (callback) callback(assertions.failures() ? new Error('We have got test failures.') : undefined); + } + }); +}; diff --git a/node_modules/nodeunit/lib/reporters/verbose.js b/node_modules/nodeunit/lib/reporters/verbose.js new file mode 100644 index 0000000..6c6083a --- /dev/null +++ b/node_modules/nodeunit/lib/reporters/verbose.js @@ -0,0 +1,125 @@ +/*! + * Nodeunit + * Copyright (c) 2010 Caolan McMahon + * MIT Licensed + */ + +/** + * Module dependencies + */ + +var nodeunit = require('../nodeunit'), + utils = require('../utils'), + fs = require('fs'), + track = require('../track'), + path = require('path'); + AssertionError = require('../assert').AssertionError; + +/** + * Reporter info string + */ + +exports.info = "Verbose tests reporter" + + +/** + * Run all tests within each module, reporting the results to the command-line. + * + * @param {Array} files + * @api public + */ + +exports.run = function (files, options, callback) { + + if (!options) { + // load default options + var content = fs.readFileSync( + __dirname + '/../../bin/nodeunit.json', 'utf8' + ); + options = JSON.parse(content); + } + + var error = function (str) { + return options.error_prefix + str + options.error_suffix; + }; + var ok = function (str) { + return options.ok_prefix + str + options.ok_suffix; + }; + var bold = function (str) { + return options.bold_prefix + str + options.bold_suffix; + }; + var assertion_message = function (str) { + return options.assertion_prefix + str + options.assertion_suffix; + }; + + var start = new Date().getTime(); + var paths = files.map(function (p) { + return path.resolve(p); + }); + var tracker = track.createTracker(function (tracker) { + if (tracker.unfinished()) { + console.log(''); + console.log(error(bold( + 'FAILURES: Undone tests (or their setups/teardowns): ' + ))); + var names = tracker.names(); + for (var i = 0; i < names.length; i += 1) { + console.log('- ' + names[i]); + } + console.log(''); + console.log('To fix this, make sure all tests call test.done()'); + process.reallyExit(tracker.unfinished()); + } + }); + + nodeunit.runFiles(paths, { + testspec: options.testspec, + testFullSpec: options.testFullSpec, + moduleStart: function (name) { + console.log('\n' + bold(name)); + }, + testDone: function (name, assertions) { + tracker.remove(name); + + if (!assertions.failures()) { + console.log('✔ ' + name); + } + else { + console.log(error('✖ ' + name)); + } + // verbose so print everything + assertions.forEach(function (a) { + if (a.failed()) { + console.log(error(' ✖ ' + a.message)); + a = utils.betterErrors(a); + console.log(' ' + a.error.stack); + } + else { + console.log(' ✔ ' + a.message); + } + }); + }, + done: function (assertions, end) { + var end = end || new Date().getTime(); + var duration = end - start; + if (assertions.failures()) { + console.log( + '\n' + bold(error('FAILURES: ')) + assertions.failures() + + '/' + assertions.length + ' assertions failed (' + + assertions.duration + 'ms)' + ); + } + else { + console.log( + '\n' + bold(ok('OK: ')) + assertions.length + + ' assertions (' + assertions.duration + 'ms)' + ); + } + + if (callback) callback(assertions.failures() ? new Error('We have got test failures.') : undefined); + }, + testStart: function(name) { + tracker.put(name); + } + }); +}; diff --git a/node_modules/nodeunit/lib/track.js b/node_modules/nodeunit/lib/track.js new file mode 100644 index 0000000..5af98ad --- /dev/null +++ b/node_modules/nodeunit/lib/track.js @@ -0,0 +1,48 @@ +/*! + * Simple util module to track tests. Adds a process.exit hook to print + * the undone tests. + */ + + +exports.createTracker = function (on_exit) { + var names = {}; + var tracker = { + names: function () { + var arr = []; + for (var k in names) { + if (names.hasOwnProperty(k)) { + arr.push(k); + } + } + return arr; + }, + unfinished: function () { + return tracker.names().length; + }, + put: function (testname) { + names[testname] = testname; + }, + remove: function (testname) { + delete names[testname]; + } + }; + + process.on('exit', function() { + on_exit = on_exit || exports.default_on_exit; + on_exit(tracker); + }); + + return tracker; +}; + +exports.default_on_exit = function (tracker) { + if (tracker.unfinished()) { + console.log(''); + console.log('Undone tests (or their setups/teardowns): '); + var names = tracker.names(); + for (var i = 0; i < names.length; i += 1) { + console.log(names[i]); + } + process.reallyExit(tracker.unfinished()); + } +}; diff --git a/node_modules/nodeunit/lib/types.js b/node_modules/nodeunit/lib/types.js new file mode 100644 index 0000000..879edd8 --- /dev/null +++ b/node_modules/nodeunit/lib/types.js @@ -0,0 +1,190 @@ +/*! + * Nodeunit + * Copyright (c) 2010 Caolan McMahon + * MIT Licensed + * + * THIS FILE SHOULD BE BROWSER-COMPATIBLE JS! + * You can use @REMOVE_LINE_FOR_BROWSER to remove code from the browser build. + * Only code on that line will be removed, it's mostly to avoid requiring code + * that is node specific + */ + +/** + * Module dependencies + */ + +var assert = require('./assert'), //@REMOVE_LINE_FOR_BROWSER + async = require('../deps/async'); //@REMOVE_LINE_FOR_BROWSER + + +/** + * Creates assertion objects representing the result of an assert call. + * Accepts an object or AssertionError as its argument. + * + * @param {object} obj + * @api public + */ + +exports.assertion = function (obj) { + return { + method: obj.method || '', + message: obj.message || (obj.error && obj.error.message) || '', + error: obj.error, + passed: function () { + return !this.error; + }, + failed: function () { + return Boolean(this.error); + } + }; +}; + +/** + * Creates an assertion list object representing a group of assertions. + * Accepts an array of assertion objects. + * + * @param {Array} arr + * @param {Number} duration + * @api public + */ + +exports.assertionList = function (arr, duration) { + var that = arr || []; + that.failures = function () { + var failures = 0; + for (var i = 0; i < this.length; i += 1) { + if (this[i].failed()) { + failures += 1; + } + } + return failures; + }; + that.passes = function () { + return that.length - that.failures(); + }; + that.duration = duration || 0; + return that; +}; + +/** + * Create a wrapper function for assert module methods. Executes a callback + * after it's complete with an assertion object representing the result. + * + * @param {Function} callback + * @api private + */ + +var assertWrapper = function (callback) { + return function (new_method, assert_method, arity) { + return function () { + var message = arguments[arity - 1]; + var a = exports.assertion({method: new_method, message: message}); + try { + assert[assert_method].apply(null, arguments); + } + catch (e) { + a.error = e; + } + callback(a); + }; + }; +}; + +/** + * Creates the 'test' object that gets passed to every test function. + * Accepts the name of the test function as its first argument, followed by + * the start time in ms, the options object and a callback function. + * + * @param {String} name + * @param {Number} start + * @param {Object} options + * @param {Function} callback + * @api public + */ + +exports.test = function (name, start, options, callback) { + var expecting; + var a_list = []; + + var wrapAssert = assertWrapper(function (a) { + a_list.push(a); + if (options.log) { + async.nextTick(function () { + options.log(a); + }); + } + }); + + var test = { + done: function (err) { + if (expecting !== undefined && expecting !== a_list.length) { + var e = new Error( + 'Expected ' + expecting + ' assertions, ' + + a_list.length + ' ran' + ); + var a1 = exports.assertion({method: 'expect', error: e}); + a_list.push(a1); + if (options.log) { + async.nextTick(function () { + options.log(a1); + }); + } + } + if (err) { + var a2 = exports.assertion({error: err}); + a_list.push(a2); + if (options.log) { + async.nextTick(function () { + options.log(a2); + }); + } + } + var end = new Date().getTime(); + async.nextTick(function () { + var assertion_list = exports.assertionList(a_list, end - start); + options.testDone(name, assertion_list); + callback(null, a_list); + }); + }, + ok: wrapAssert('ok', 'ok', 2), + same: wrapAssert('same', 'deepEqual', 3), + equals: wrapAssert('equals', 'equal', 3), + expect: function (num) { + expecting = num; + }, + _assertion_list: a_list + }; + // add all functions from the assert module + for (var k in assert) { + if (assert.hasOwnProperty(k)) { + test[k] = wrapAssert(k, k, assert[k].length); + } + } + return test; +}; + +/** + * Ensures an options object has all callbacks, adding empty callback functions + * if any are missing. + * + * @param {Object} opt + * @return {Object} + * @api public + */ + +exports.options = function (opt) { + var optionalCallback = function (name) { + opt[name] = opt[name] || function () {}; + }; + + optionalCallback('moduleStart'); + optionalCallback('moduleDone'); + optionalCallback('testStart'); + optionalCallback('testReady'); + optionalCallback('testDone'); + //optionalCallback('log'); + + // 'done' callback is not optional. + + return opt; +}; diff --git a/node_modules/nodeunit/lib/utils.js b/node_modules/nodeunit/lib/utils.js new file mode 100644 index 0000000..5c72990 --- /dev/null +++ b/node_modules/nodeunit/lib/utils.js @@ -0,0 +1,216 @@ +/*! + * Nodeunit + * Copyright (c) 2010 Caolan McMahon + * MIT Licensed + */ + +/** + * Module dependencies + */ + +var async = require('../deps/async'), + fs = require('fs'), + util = require('util'), + Script = require('vm').Script, + http = require('http'); + + +/** + * Detect if coffee-script, iced-coffeescript, or streamline are available and + * the respective file extensions to the search filter in modulePaths if it is. + */ + +var extensions = [ 'js' ]; // js is always supported: add it unconditionally +var extensionPattern; + +try { + require('coffee' + '-script/register'); + extensions.push('coffee'); +} catch (e) { } + +try { + require('iced-coffee' + '-script/register'); + extensions.push('iced'); +} catch (e) { } + +try { + require('stream' + 'line').register(); + extensions.push('_coffee'); + extensions.push('_js'); +} catch (e) { } + +extensionPattern = new RegExp('\\.(?:' + extensions.join('|') + ')$'); + + +/** + * Finds all modules at each path in an array, If a path is a directory, it + * returns all supported file types inside it. This only reads 1 level deep in + * the directory and does not recurse through sub-directories. + * + * The extension (.js, .coffee etc) is stripped from the filenames so they can + * simply be require()'ed. + * + * @param {Array} paths + * @param {Function} callback + * @api public + */ + +exports.modulePaths = function (paths, callback) { + async.concat(paths, function (p, cb) { + fs.stat(p, function (err, stats) { + if (err) { + return cb(err); + } + if (stats.isFile()) { + return cb(null, [p]); + } + if (stats.isDirectory()) { + fs.readdir(p, function (err, files) { + if (err) { + return cb(err); + } + + // filter out any filenames with unsupported extensions + var modules = files.filter(function (filename) { + return extensionPattern.exec(filename); + }); + + // remove extension from module name and prepend the + // directory path + var fullpaths = modules.map(function (filename) { + var mod_name = filename.replace(extensionPattern, ''); + return [p, mod_name].join('/'); + }); + + // sort filenames here, because Array.map changes order + fullpaths.sort(); + + cb(null, fullpaths); + }); + } + }); + }, callback); +}; + +/** + * Evaluates JavaScript files in a sandbox, returning the context. The first + * argument can either be a single filename or an array of filenames. If + * multiple filenames are given their contents are concatenated before + * evalution. The second argument is an optional context to use for the sandbox. + * + * @param files + * @param {Object} sandbox + * @return {Object} + * @api public + */ + +exports.sandbox = function (files, /*optional*/sandbox) { + var source, script, result; + if (!(files instanceof Array)) { + files = [files]; + } + source = files.map(function (file) { + return fs.readFileSync(file, 'utf8'); + }).join(''); + + if (!sandbox) { + sandbox = {}; + } + script = new Script(source); + result = script.runInNewContext(sandbox); + return sandbox; +}; + +/** + * Provides a http request, response testing environment. + * + * Example: + * + * var httputil = require('nodeunit').utils.httputil + * exports.testSomething = function(test) { + * httputil(function (req, resp) { + * resp.writeHead(200, {}); + * resp.end('test data'); + * }, + * function(server, client) { + * client.fetch('GET', '/', {}, function(resp) { + * test.equal('test data', resp.body); + * server.close(); + * test.done(); + * }) + * }); + * }; + * + * @param {Function} cgi + * @param {Function} envReady + * @api public + */ +exports.httputil = function (cgi, envReady) { + var hostname = process.env.HOSTNAME || 'localhost'; + var port = process.env.PORT || 3000; + + var server = http.createServer(cgi); + server.listen(port, hostname); + + var client = http.createClient(port, hostname); + client.fetch = function (method, path, headers, respReady) { + var request = this.request(method, path, headers); + request.end(); + request.on('response', function (response) { + response.setEncoding('utf8'); + response.on('data', function (chunk) { + if (response.body) { + response.body += chunk; + } else { + response.body = chunk; + } + }); + response.on('end', function () { + if (response.headers['content-type'] === 'application/json') { + response.bodyAsObject = JSON.parse(response.body); + } + respReady(response); + }); + }); + }; + + process.nextTick(function () { + if (envReady && typeof envReady === 'function') { + envReady(server, client); + } + }); +}; + + +/** + * Improves formatting of AssertionError messages to make deepEqual etc more + * readable. + * + * @param {Object} assertion + * @return {Object} + * @api public + */ + +exports.betterErrors = function (assertion) { + if (!assertion.error) { + return assertion; + } + var e = assertion.error; + if (e.actual && e.expected) { + var actual = util.inspect(e.actual, false, 10).replace(/\n$/, ''); + var expected = util.inspect(e.expected, false, 10).replace(/\n$/, ''); + var multiline = ( + actual.indexOf('\n') !== -1 || + expected.indexOf('\n') !== -1 + ); + var spacing = (multiline ? '\n' : ' '); + e._message = e.message; + e.stack = ( + e.name + ':' + spacing + + actual + spacing + e.operator + spacing + + expected + '\n' + + e.stack.split('\n').slice(1).join('\n') + ); + } + return assertion; +}; diff --git a/node_modules/nodeunit/man1/nodeunit.1 b/node_modules/nodeunit/man1/nodeunit.1 new file mode 100644 index 0000000..450772d --- /dev/null +++ b/node_modules/nodeunit/man1/nodeunit.1 @@ -0,0 +1,95 @@ +.\" Generated with Ronnjs/v0.1 +.\" http://github.com/kapouer/ronnjs/ +. +.TH "NODEUNIT" "1" "October 2010" "" "" +. +.SH "NAME" +\fBnodeunit\fR \-\- simple node\.js unit testing tool +. +.SH "SYNOPSIS" +. +.nf +nodeunit [options] [ \.\.\.] +. +.fi +. +.SH "DESCRIPTION" +Nodeunit is a simple unit testing tool based on the node\.js assert module\. +. +.IP "\(bu" 4 +Simple to use +. +.IP "\(bu" 4 +Just export the tests from a module +. +.IP "\(bu" 4 +Helps you avoid common pitfalls when testing asynchronous code +. +.IP "\(bu" 4 +Easy to add test cases with setUp and tearDown functions if you wish +. +.IP "\(bu" 4 +Allows the use of mocks and stubs +. +.IP "" 0 +. +.SH "OPTIONS" + \fB\-\-config FILE\fR: +. +.br + Load config options from a JSON file, allows the customisation + of color schemes for the default test reporter etc\. + See bin/nodeunit\.json for current available options\. +. +.P + \fB\-\-reporter FILE\fR: +. +.br + You can set the test reporter to a custom module or on of the modules + in nodeunit/lib/reporters, when omitted, the default test runner is used\. +. +.P + \fB\-\-list\-reporters\fR: +. +.br + List available build\-in reporters\. +. +.P + \fB\-h\fR, \fB\-\-help\fR: +. +.br + Display the help and exit\. +. +.P + \fB\-v\fR, \fB\-\-version\fR: +. +.br + Output version information and exit\. +. +.P + \fB\fR: + You can run nodeunit on specific files or on all \fI*\.js\fR files inside +. +.br + a directory\. +. +.SH "AUTHORS" +Written by Caolan McMahon and other nodeunit contributors\. +. +.br +Contributors list: \fIhttp://github\.com/caolan/nodeunit/contributors\fR\|\. +. +.SH "REPORTING BUGS" +Report nodeunit bugs to \fIhttp://github\.com/caolan/nodeunit/issues\fR\|\. +. +.SH "COPYRIGHT" +Copyright © 2010 Caolan McMahon\. +. +.br +Nodeunit has been released under the MIT license: +. +.br +\fIhttp://github\.com/caolan/nodeunit/raw/master/LICENSE\fR\|\. +. +.SH "SEE ALSO" +node(1) diff --git a/node_modules/nodeunit/node_modules/.bin/tap b/node_modules/nodeunit/node_modules/.bin/tap new file mode 120000 index 0000000..999914b --- /dev/null +++ b/node_modules/nodeunit/node_modules/.bin/tap @@ -0,0 +1 @@ +../tap/bin/tap.js \ No newline at end of file diff --git a/node_modules/nodeunit/node_modules/tap/.npmignore b/node_modules/nodeunit/node_modules/tap/.npmignore new file mode 100644 index 0000000..e69de29 diff --git a/node_modules/nodeunit/node_modules/tap/AUTHORS b/node_modules/nodeunit/node_modules/tap/AUTHORS new file mode 100644 index 0000000..b7f6eb2 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/AUTHORS @@ -0,0 +1,11 @@ +# contributors sorted by whether or not they're me +Isaac Z. Schlueter +baudehlo +James Halliday +Jason Smith (air) +Pedro P. Candel +Stein Martin Hustad +Trent Mick +Corey Richardson +Raynos +Siddharth Mahendraker diff --git a/node_modules/nodeunit/node_modules/tap/LICENSE b/node_modules/nodeunit/node_modules/tap/LICENSE new file mode 100644 index 0000000..05a4010 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/LICENSE @@ -0,0 +1,23 @@ +Copyright 2009, 2010, 2011 Isaac Z. Schlueter. +All rights reserved. + +Permission is hereby granted, free of charge, to any person +obtaining a copy of this software and associated documentation +files (the "Software"), to deal in the Software without +restriction, including without limitation the rights to use, +copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the +Software is furnished to do so, subject to the following +conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES +OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT +HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR +OTHER DEALINGS IN THE SOFTWARE. diff --git a/node_modules/nodeunit/node_modules/tap/README.md b/node_modules/nodeunit/node_modules/tap/README.md new file mode 100644 index 0000000..d6a0440 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/README.md @@ -0,0 +1,86 @@ +This is a mix-and-match set of utilities that you can use to write test +harnesses and frameworks that communicate with one another using the +Test Anything Protocol. + +If you don't yet know what TAP is, [you better ask +somebody](http://testanything.org/). + +Default Usage: + +1. Make a directory. Maybe call it 'test'. That'd be nice and obvious. +2. Put a bunch of test scripts in there. If they're node programs, then + they should be ".js". Anything else is assumed to be some kind of shell + script, which should have a shebang line. +3. `npm install tap` +4. Update package.json scripts.test to include `tap ./test` [example + gist](https://gist.github.com/4469613) +5. `npm test` + +The output will be TAP-compliant. + +For extra special bonus points, you can do something like this: + + var test = require("tap").test + test("make sure the thingie is a thing", function (t) { + t.equal(thingie, "thing", "thingie should be thing") + t.deepEqual(array, ["foo", "bar"], "array has foo and bar elements") + t.deepEqual(object, {foo: 42}, "object has foo property") + t.type(thingie, "string", "type of thingie is string") + t.ok(true, "this is always true") + t.notOk(false, "this is never true") + t.test("a child test", function (t) { + t.equal(this, superEasy, "right!?") + t.similar(7, 2, "ever notice 7 is kinda like 2?", {todo: true}) + t.test("so skippable", {skip: true}, function (t) { + t.plan(1) // only one test in this block + t.ok(true, "but when the flag changes, it'll pass") + // no need to end, since we had a plan. + }) + t.end() + }) + t.ok(99, "can also skip individual assertions", {skip: true}) + // end lets it know it's over. + t.end() + }) + test("another one", function (t) { + t.plan(1) + t.ok(true, "It's ok to plan, and also end. Watch.") + t.end() // but it must match the plan! + }) + +Node-tap is actually a collection of several modules, any of which may be +mixed and matched however you please. + +If you don't like this test framework, and think you can do much much +better, *I strongly encourage you to do so!* If you use this library, +however, at least to output TAP-compliant results when `process.env.TAP` +is set, then the data coming out of your framework will be much more +consumable by machines. + +You can also use this to build programs that *consume* the TAP data, so +this is very useful for CI systems and such. + +* tap-assert: A collection of assert functions that return TAP result + objects. +* tap-consumer: A stream interface for consuming TAP data. +* tap-producer: A class that produces a TAP stream by taking in result + objects. +* tap-results: A class for keeping track of TAP result objects as they + pass by, counting up skips, passes, fails, and so on. +* tap-runner: A program that runs through a directory running all the + tests in it. (Tests which may or may not be TAP-outputting tests. But + it's better if they are.) +* tap-test: A class for actually running tests. +* tap-harness: A class that runs tests. (Tests are also Harnesses, + which is how sub-tests run.) +* tap-global-harness: A default harness that provides the top-level + support for running TAP tests. + +## Experimental Code Coverage with runforcover & bunker: + +``` +TAP_COV=1 tap ./test [--cover=./lib,foo.js] [--coverage-dir=./coverage] +``` + +This feature is experimental, and will most likely change somewhat +before being finalized. Feedback welcome. diff --git a/node_modules/nodeunit/node_modules/tap/bin/tap-http.js b/node_modules/nodeunit/node_modules/tap/bin/tap-http.js new file mode 100644 index 0000000..296910f --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/bin/tap-http.js @@ -0,0 +1,19 @@ +#!/usr/bin/env node + +// just an example, really +// Run with `node tap-http.js path/to/tests/` + +var argv = process.argv.slice(2) + , path = require("path") + , Runner = require("../lib/tap-runner") + + , http = require("http") + , server = http.createServer(function (req, res) { + // it'd be nice to return a non-200 if the tests fail, but we don't + // know the status until it's done, so that would mean not being able + // to pipe the output + res.writeHead(200, {'content-type': 'text/plain'}) + new Runner(argv, null).pipe(res) + }) + +server.listen(1337) diff --git a/node_modules/nodeunit/node_modules/tap/bin/tap-reader.js b/node_modules/nodeunit/node_modules/tap/bin/tap-reader.js new file mode 100755 index 0000000..b196cc2 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/bin/tap-reader.js @@ -0,0 +1,33 @@ +#!/usr/bin/env node + +// read a tap stream from stdin. + +var TapConsumer = require("../lib/tap-consumer") + , TapProducer = require("../lib/tap-producer") + +var tc = new TapConsumer + , tp = new TapProducer + +//process.stdin.pipe(tc) +process.stdin.on("data", function (c) { + c = c + "" + // console.error(JSON.stringify(c).substr(0, 100)) + tc.write(c) +}) +process.stdin.on("end", function () { tc.end() }) +process.stdin.resume() +//tc.pipe(tp) +tc.on("data", function (c) { + tp.write(c) +}) +tc.on("end", function () { tp.end() }) + +tp.on("data", function (c) { + console.error(["output write", c]) + process.stdout.write(c) +}) + +tp.on("end", function (er, total, ok) { + if (er) throw er + process.exit(total - ok) +}) diff --git a/node_modules/nodeunit/node_modules/tap/bin/tap.js b/node_modules/nodeunit/node_modules/tap/bin/tap.js new file mode 100755 index 0000000..0a9bbeb --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/bin/tap.js @@ -0,0 +1,144 @@ +#!/usr/bin/env node + +var argv = process.argv.slice(2) + , path = require("path") + , Runner = require("../lib/tap-runner") + + , nopt = require("nopt") + + , knownOpts = + { cover: [path, false] + , "cover-dir": path + , stderr: Boolean + , stdout: Boolean + , diag: Boolean + , version: Boolean + , tap: Boolean + , timeout: Number + , gc: Boolean + , debug: Boolean + , "debug-brk": Boolean + , strict: Boolean + , harmony: Boolean + } + + , shorthands = + // debugging 1: show stderr + { d: ["--stderr"] + // debugging 2: show stderr and tap + , dd: ["--stderr", "--tap"] + // debugging 3: show stderr, tap, AND always show diagnostics. + , ddd: ["--stderr", "--tap", "--diag"] + , "expose-gc": ["--gc"] + , g: ["--gc"] + , e: ["--stderr"] + , t: ["--timeout"] + , o: ["--tap"] + , c: ["--cover"] + , v: ["--version"] + , "?": ["--help"] + , h: ["--help"] + } + + , defaults = + { cover: "./lib" + , "cover-dir": "./coverage" + , stderr: process.env.TAP_STDERR !== '0' + , tap: process.env.TAP + , diag: process.env.TAP_DIAG + , timeout: +process.env.TAP_TIMEOUT || 30 + , gc: false + , debug: false + , "debug-brk": false + , strict: false + , harmony: false + , version: false + , help: false } + + , options = nopt(knownOpts, shorthands) + +if (options.version) { + console.log(require("../package.json").version) + process.exit(0) +} + +if (options.help) { + console.log(function(){/* + +Usage: + tap + + Run the files as tap tests, parse the output, and report the results + +Options: + + --stderr Print standard error output of tests to standard error. + --tap Print raw tap output. + --diag Print diagnostic output for passed tests, as well as failed. + (Implies --tap) + --gc Expose the garbage collector to tests. + --timeout Maximum time to wait for a subtest, in seconds. Default: 30 + --debug Pass the '--debug' flag to node for debugging + --debug-brk Pass the '--debug-brk' flag to node for debugging + --strict Enforce strict mode when running tests. + --harmony Enable harmony features for tests. + --version Print the version of node tap. + --help Print this help. + +Please report bugs! https://github.com/isaacs/node-tap/issues + +*/}.toString().split(/\n/).slice(1, -1).join("\n")) + process.exit(0) +} + + +Object.keys(defaults).forEach(function (k) { + if (!options.hasOwnProperty(k)) options[k] = defaults[k] +}) + +// other tests that might rely on these +if (options.diag) process.env.TAP_DIAG = true +if (options.tap) process.env.TAP = true +if (options.timeout) process.env.TAP_TIMEOUT = options.timeout + +var r = new Runner(options) + , TapProducer = require("../lib/tap-producer") + +if (options.tap || options.diag) { + r.pipe(process.stdout) +} else { + r.on("file", function (file, results, details) { + var s = (details.ok ? "" : "not ") + "ok "+results.name + , n = details.pass + "/" + details.testsTotal + , dots = new Array(Math.max(1, 60 - s.length - n.length)).join(".") + console.log("%s %s %s", s, dots, n) + if (details.ok) { + if (details.skip) { + console.log(" skipped: %s", details.skipTotal) + } + } else { + // console.error(details) + console.log(" Command: %s", results.command) + console.log(" " + TapProducer.encode(details.list) + .split(/\n/).join("\n ")) + } + }) + r.on("end", function () { + //console.log(r) + var s = "total" + , n = r.results.pass + "/" + r.results.testsTotal + , dots = new Array(60 - s.length - n.length).join(".") + , ok = r.results.ok ? "ok" : "not ok" + console.log("%s %s %s\n\n%s", s, dots, n, ok) + if (r.doCoverage) { + console.error( "\nCoverage: %s\n" + , path.resolve(r.coverageOutDir, "index.html") ) + } + }) +} + + + +r.on("end", function () { + process.exit(r.results.tests - r.results.pass) +}) diff --git a/node_modules/nodeunit/node_modules/tap/coverage-example/lib/bar.js b/node_modules/nodeunit/node_modules/tap/coverage-example/lib/bar.js new file mode 100644 index 0000000..e7cb7ad --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/coverage-example/lib/bar.js @@ -0,0 +1,15 @@ +var Bar = module.exports = function(str) { + this.bar = str; + this.str = str; +}; + +Bar.prototype.foo = function() { + var self = this; + return self.bar; +}; + +Bar.prototype.baz = function() { + var self = this; + return self.str; +}; + diff --git a/node_modules/nodeunit/node_modules/tap/coverage-example/lib/foo.js b/node_modules/nodeunit/node_modules/tap/coverage-example/lib/foo.js new file mode 100644 index 0000000..cb9ee8f --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/coverage-example/lib/foo.js @@ -0,0 +1,15 @@ +var Foo = module.exports = function(str) { + this.foo = str; + this.str = str; +}; + +Foo.prototype.bar = function() { + var self = this; + return self.foo; +}; + +Foo.prototype.baz = function() { + var self = this; + return self.str; +}; + diff --git a/node_modules/nodeunit/node_modules/tap/coverage-example/test/bar.test.js b/node_modules/nodeunit/node_modules/tap/coverage-example/test/bar.test.js new file mode 100644 index 0000000..91e4bc2 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/coverage-example/test/bar.test.js @@ -0,0 +1,20 @@ +var test = require('tap').test, + Bar = require('../lib/bar'), + bar; + +test('setup', function(t) { + bar = new Bar('baz'); + t.ok(bar); + t.end(); +}); + +test('bar', function(t) { + t.equal('baz', bar.foo()); + t.end(); +}); + +test('teardown', function(t) { + t.ok(true); + t.end(); +}); + diff --git a/node_modules/nodeunit/node_modules/tap/coverage-example/test/baz.test.js b/node_modules/nodeunit/node_modules/tap/coverage-example/test/baz.test.js new file mode 100644 index 0000000..fae22d8 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/coverage-example/test/baz.test.js @@ -0,0 +1,29 @@ +var test = require('tap').test, + Foo = require('../lib/foo'), + Bar = require('../lib/bar'), + foo, bar; + +test('setup', function(t) { + foo = new Foo('baz'); + t.ok(foo); + bar = new Bar('baz'); + t.ok(bar); + t.end(); +}); + +test('baz from Foo', function(t) { + t.equal('baz', foo.baz()); + t.end(); +}); + +test('baz from Bar', function(t) { + t.equal('baz', bar.baz()); + t.end(); +}); + + +test('teardown', function(t) { + t.ok(true); + t.end(); +}); + diff --git a/node_modules/nodeunit/node_modules/tap/coverage-example/test/foo.test.js b/node_modules/nodeunit/node_modules/tap/coverage-example/test/foo.test.js new file mode 100644 index 0000000..2aed8fd --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/coverage-example/test/foo.test.js @@ -0,0 +1,20 @@ +var test = require('tap').test, + Foo = require('../lib/foo'), + foo; + +test('setup', function(t) { + foo = new Foo('baz'); + t.ok(foo); + t.end(); +}); + +test('bar', function(t) { + t.equal('baz', foo.bar()); + t.end(); +}); + +test('teardown', function(t) { + t.ok(true); + t.end(); +}); + diff --git a/node_modules/nodeunit/node_modules/tap/example/lib/math.js b/node_modules/nodeunit/node_modules/tap/example/lib/math.js new file mode 100644 index 0000000..f798626 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/example/lib/math.js @@ -0,0 +1 @@ +module.exports = Math diff --git a/node_modules/nodeunit/node_modules/tap/example/test/test-example.js b/node_modules/nodeunit/node_modules/tap/example/test/test-example.js new file mode 100644 index 0000000..cd2549b --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/example/test/test-example.js @@ -0,0 +1,237 @@ +var tap = require("tap") + , test = tap.test + , plan = tap.plan + , math + +test("load sut", function (t) { + math = require("../lib/math") + t.ok(math, "object loaded") + t.end() +}) + +test("validate constants", function (t) { + t.equal(math.LN10, 2.302585092994046, "ln 10") + t.equal(math.PI, 3.141592653589793, "pi") + t.equal(math.E, 2.718281828459045, "e") + t.equal(math.LOG10E, 0.4342944819032518, "log 10 e") + t.equal(math.SQRT2, 1.4142135623730951, "sqrt 2") + t.equal(math.SQRT1_2, 0.7071067811865476, "sqrt 1/2") + t.equal(math.LN2, 0.6931471805599453, "ln2") + t.end() +}) + +test("using this", function (t) { + // this also works. + this.equal(t, this, "call in scope of test obj") + this.end() +}) + +// test setTimeout, just a trivial example. +test("setTimeout", function (t) { + var start = Date.now() + setTimeout(function () { + t.ok(Date.now() >= start + 50, "timeout fired after delay") + t.end() + }, 50) +}) + +// another way to do the same, using a plan. +// this is more robust, but annoying when you have a long list +// of tests for something. For async stuff, it's generally better, +// since there's a higher risk of the control flowing off to lala land. +test("setTimeout planned", function (t) { + t.plan(1) + var start = Date.now() + setTimeout(function () { + t.ok(Date.now() >= start + 50, "timeout fired after delay") + }, 50) +}) + +// plans also are good for cases where things may fire in a non-deterministic +// order, since it won't be as obvious when everything is done. +test("setTimeout parallel", function (t) { + t.plan(2) + var start = Date.now() + setTimeout(function A () { + t.ok(Date.now() >= start + 50, "timeout A fired after delay") + }, 50) + setTimeout(function B () { + t.ok(Date.now() >= start + 50, "timeout B fired after delay") + }, 50) +}) + +// something slightly less hello worldy +test("async test", function (t) { + t.plan(4) + var fs = require("fs") + t.ok(fs, "fs library should load") + var rs = fs.createReadStream(__filename) + t.ok(rs, "read stream should start fine.") + rs.on("open", function (fd) { + t.type(fd, "number", "file descriptor should be a number") + t.equal(fd, rs.fd, "fd should match stream fd") + }) +}) + +// you can bail out of the entire everything if something is just +// Not Right (db not installed, etc.) +test("tarp", function (parent) { + if (7 === 5) { + parent.bailout("math is broken") + } + // bailout bubbles up a bit like "error" events + // if unhandled, then the parent will bail, as well. + parent.test("child bailouts", function (child) { + child.on("bailout", function (s) { + parent.fail("children shouldn't bail.") + }) + child.bailout("try to bail out, but instead just fail a test") + }) + + parent.test("child bailout 2", function (child) { + child.bailout("this one will bail out") + }) +}) + +// tests marked "todo" can fail without counting against the overall score +// never ever ever write tests to "verify" incorrect behavior! +test("unfinished test", function (t) { + t.equal(math.cos(math.PI), -1, "cos(PI)") + t.equal(math.sin(math.PI), 0, "sin(PI)") + t.equal(math.face, "your face", "math.face should be your face # TODO") + t.end() +}) + +// tests can have children. +test("http server", function (t) { + // one test plus 4 children. + t.plan(5) + + var http = require("http") + , PORT = 12346 + + t.ok(http, "http module should load") + var server + + t.test("set up server", function (t) { + t.plan(2) + server = http.createServer(function (req, res) { + t.comment("Request: "+req.url) + res.writeHead(200, {}) + res.end(req.method + " " + req.url) + }) + t.ok(server, "createServer should create a server") + server.listen(PORT, t.cb("listen should fire callback")) + }) + + // set the "parallel" flag on this one. + // That signals the harness to proceed immediately to the next test, + // and run them in parallel. + // Default behavior is to wait for each test to complete before proceeding + // to the next one. + // The first not-parallel test encountered will cause it to wait for that + // test, as well as all the parallel tests before it. + // A, B', C', D', E (where ' means "parallel") + // Runs A, and then B, C, and D in parallel, and then E. + t.test("testing POST", {parallel: true}, function (t) { + t.plan(1) + http.request("POST", { method: "POST" + , host: "localhost" + , path: "/foo" + , port: PORT }).on("response", function (res) { + t.bufferStream(res, function (s) { t.equal(s, "POST /foo") }) + }).end() + }) + + t.test("testing GET", {parallel: true}, function (t) { + t.plan(1) + http.request("POST", { method: "GET" + , host: "localhost" + , path: "/foo" + , port: PORT }).on("response", function (res) { + t.bufferStream(res, function (s) { t.equal(s, "GET /foo") }) + }).end() + }) + + // wrap in a test so that if this throws, it'll log as a failed test. + t.test("teardown", function (t) { + server.close() + t.end() + }) +}) + +// yo dawg! +test("meta-tests", function (t) { + t.plan(5) + + // t.fails() wraps a child test and succeeds if it fails. + t.fails(t.test("this should fail", function (t) { + t.ok(false, "assert false") + t.end() + })) + + // t.timesOut() wraps a child test and succeeds if it times out. + // if t.end() is called, or if a plan is completed, then it fails. + // set the timeout really low so that it will not take forever. + t.timesOut(t.test("this should timeout", { timeout: 1 }, function (t) { + t.ok(true, "assert true") + // t.end() never called. + })) + + // t.incomplete() wraps a child test and succeeds if it ends before + // the plan is finished. + t.incomplete(t.test("this should be incomplete", function (t) { + t.plan(100) + t.ok(true, "assert true") + // calling end prematurely. + t.end() + })) + + // t.bailsOut() wraps a child test and succeeds if it calls bailout() + t.bailsOut(t.test("this should bailout", function (t) { + t.bailout("oh noes, bailing out!") + })) + + // low-level analysis of subtests + t.test("verifying test success/failure expectations", function (t) { + t.once("end", function () { + var res = t.results + , is = t.equal + // hijack! + t.clear() + is(res.ok, false, "ok") + + is(res.bailedOut, false, "bailed out") + + is(res.skip, 2, "skips") + is(res.skipPass, 1, "skip that passed") + is(res.skipFail, 1, "skip that failed") + + is(res.todo, 2, "todos") + is(res.todoPass, 1, "todo that passed") + is(res.todoFail, 1, "todo that failed") + + is(res.failTotal, 3, "failures total") + is(res.fail, 1, "relevant failure") + + is(res.passTotal, 3, "passes total") + is(res.pass, 1, "relevant pass") + + is(res.testsTotal, 6, "total tests") + is(res.tests, 2, "should be 2 relevant tests") + + t.end() + }) + + // run the metatest. + // *this* is the actual SUT in this case. + t.ok(false, "failing todo #todo") + // can also set #todo or #skip explicitly + t.ok(true, "succeeding todo", {todo: true}) + t.ok(false, "failing skip #skip", {skip: true}) + t.ok(true, "suceeding skip #skip") + t.ok(false, "failing test") + t.ok(true, "succeeding test") + t.end() + }) +}) diff --git a/node_modules/nodeunit/node_modules/tap/lib/main.js b/node_modules/nodeunit/node_modules/tap/lib/main.js new file mode 100644 index 0000000..a9a520a --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/lib/main.js @@ -0,0 +1,16 @@ + +var GlobalHarness = require("./tap-global-harness") + +// this lets you do stuff like: +// var test = require("tap").test +// test(...) +// to run stuff in the global harness. +exports = module.exports = new GlobalHarness() + +exports.createProducer = exports.Producer = require("./tap-producer") +exports.createConsumer = exports.Consumer = require("./tap-consumer") +exports.yamlish = require("yamlish") +exports.createTest = exports.Test = require("./tap-test") +exports.createHarness = exports.Harness = require("./tap-harness") +exports.createRunner = exports.Runner = require("./tap-runner") +exports.assert = require("./tap-assert") diff --git a/node_modules/nodeunit/node_modules/tap/lib/tap-assert.js b/node_modules/nodeunit/node_modules/tap/lib/tap-assert.js new file mode 100644 index 0000000..60203a0 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/lib/tap-assert.js @@ -0,0 +1,445 @@ +// an assert module that returns tappable data for each assertion. +var difflet = require('difflet') + , deepEqual = require('deep-equal') + , bufferEqual = require('buffer-equal') + , Buffer = require('buffer').Buffer + +module.exports = assert + +var syns = {} + , id = 1 + +function assert (ok, message, extra) { + if (extra && extra.skip) return assert.skip(message, extra) + + //console.error("assert %j", [ok, message, extra]) + //if (extra && extra.skip) return assert.skip(message, extra) + //console.error("assert", [ok, message, extra]) + ok = !!ok + var res = { id : id ++, ok: ok } + + var caller = getCaller(extra && extra.error) + if (extra && extra.error) { + res.type = extra.error.name + res.message = extra.error.message + res.code = extra.error.code + || extra.error.type + res.errno = extra.error.errno + delete extra.error + } + if (caller.file) { + res.file = caller.file + res.line = +caller.line + res.column = +caller.column + } + res.stack = caller.stack + + res.name = message || "(unnamed assert)" + + if (extra) Object.keys(extra).forEach(function (k) { + if (!res.hasOwnProperty(k)) res[k] = extra[k] + }) + + // strings and objects are hard to diff by eye + if (!ok && + res.hasOwnProperty("found") && + res.hasOwnProperty("wanted") && + res.found !== res.wanted) { + if (typeof res.wanted !== typeof res.found || + typeof res.wanted === "object" && (!res.found || !res.wanted)) { + res.type = { found: typeof found + , wanted: typeof wanted } + } else if (typeof res.wanted === "string") { + res.diff = diffString(res.found, res.wanted) + } else if (typeof res.wanted === "object") { + res.diff = diffObject(res.found, res.wanted) + } + } + + //console.error("assert return", res) + + return res +} +assert.ok = assert +syns.ok = [ "true", "assert" ] + + +function notOk (ok, message, extra) { + return assert(!ok, message, extra) +} +assert.notOk = notOk +syns.notOk = [ "false", "notok" ] + +function error (er, message, extra) { + if (!er) { + // just like notOk(er) + return assert(!er, message, extra) + } + message = message || er.message + extra = extra || {} + extra.error = er + return assert.fail(message, extra) +} +assert.error = error +syns.error = [ "ifError", "ifErr", "iferror" ] + + +function pass (message, extra) { + return assert(true, message, extra) +} +assert.pass = pass + +function fail (message, extra) { + //console.error("assert.fail", [message, extra]) + //if (extra && extra.skip) return assert.skip(message, extra) + return assert(false, message, extra) +} +assert.fail = fail + +function skip (message, extra) { + //console.error("assert.skip", message, extra) + if (!extra) extra = {} + return { id: id ++, skip: true, name: message || "" } +} +assert.skip = skip + +function throws (fn, wanted, message, extra) { + if (typeof wanted === "string") { + extra = message + message = wanted + wanted = null + } + + if (extra && extra.skip) return assert.skip(message, extra) + + var found = null + try { + fn() + } catch (e) { + found = { name: e.name, message: e.message } + } + + extra = extra || {} + + extra.found = found + if (wanted) { + wanted = { name: wanted.name, message: wanted.message } + extra.wanted = wanted + } + + if (!message) { + message = "Expected to throw" + if (wanted) message += ": "+wanted.name + " " + wanted.message + } + + return (wanted) ? assert.similar(found, wanted, message, extra) + : assert.ok(found, message, extra) +} +assert.throws = throws + + +function doesNotThrow (fn, message, extra) { + if (extra && extra.skip) return assert.skip(message, extra) + var found = null + try { + fn() + } catch (e) { + found = {name: e.name, message: e.message} + } + message = message || "Should not throw" + + return assert.equal(found, null, message, extra) +} +assert.doesNotThrow = doesNotThrow + + +function equal (a, b, message, extra) { + if (extra && extra.skip) return assert.skip(message, extra) + extra = extra || {} + message = message || "should be equal" + extra.found = a + extra.wanted = b + return assert(a === b, message, extra) +} +assert.equal = equal +syns.equal = ["equals" + ,"isEqual" + ,"is" + ,"strictEqual" + ,"strictEquals"] + + +function equivalent (a, b, message, extra) { + if (extra && extra.skip) return assert.skip(message, extra) + var extra = extra || {} + message = message || "should be equivalent" + extra.found = a + extra.wanted = b + + if (Buffer.isBuffer(a) && Buffer.isBuffer(b)) { + return assert(bufferEqual(a, b), message, extra) + } else { + return assert(deepEqual(a, b), message, extra) + } +} +assert.equivalent = equivalent +syns.equivalent = ["isEquivalent" + ,"looseEqual" + ,"looseEquals" + ,"isDeeply" + ,"same" + ,"deepEqual" + ,"deepEquals"] + + +function inequal (a, b, message, extra) { + if (extra && extra.skip) return assert.skip(message, extra) + extra = extra || {} + message = message || "should not be equal" + extra.found = a + extra.doNotWant = b + return assert(a !== b, message, extra) +} +assert.inequal = inequal +syns.inequal = ["notEqual" + ,"notEquals" + ,"notStrictEqual" + ,"notStrictEquals" + ,"isNotEqual" + ,"isNot" + ,"not" + ,"doesNotEqual" + ,"isInequal"] + + +function inequivalent (a, b, message, extra) { + if (extra && extra.skip) return assert.skip(message, extra) + extra = extra || {} + message = message || "should not be equivalent" + extra.found = a + extra.doNotWant = b + + if (Buffer.isBuffer(a) && Buffer.isBuffer(b)) { + return assert(!bufferEqual(a, b), message, extra) + } else { + return assert(!deepEqual(a, b), message, extra) + } +} +assert.inequivalent = inequivalent +syns.inequivalent = ["notEquivalent" + ,"notDeepEqual" + ,"notDeeply" + ,"notSame" + ,"isNotDeepEqual" + ,"isNotDeeply" + ,"isNotEquivalent" + ,"isInequivalent"] + +function similar (a, b, message, extra, flip) { + if (extra && extra.skip) return assert.skip(message, extra) + // test that a has all the fields in b + message = message || "should be similar" + + if (typeof a === "string" && + (Object.prototype.toString.call(b) === "[object RegExp]")) { + extra = extra || {} + extra.pattern = b + extra.string = a + var ok = a.match(b) + extra.match = ok + if (flip) ok = !ok + return assert.ok(ok, message, extra) + } + + var isObj = assert(a && typeof a === "object", message, extra) + if (!isObj.ok) { + // not an object + if (a == b) isObj.ok = true + if (flip) isObj.ok = !isObj.ok + return isObj + } + + var eq = flip ? inequivalent : equivalent + return eq(selectFields(a, b), b, message, extra) +} +assert.similar = similar +syns.similar = ["isSimilar" + ,"has" + ,"hasFields" + ,"like" + ,"isLike"] + +function dissimilar (a, b, message, extra) { + if (extra && extra.skip) return assert.skip(message, extra) + message = message || "should be dissimilar" + return similar(a, b, message, extra, true) +} +assert.dissimilar = dissimilar +syns.dissimilar = ["unsimilar" + ,"notSimilar" + ,"unlike" + ,"isUnlike" + ,"notLike" + ,"isNotLike" + ,"doesNotHave" + ,"isNotSimilar" + ,"isDissimilar"] + +function type (thing, t, message, extra) { + if (extra && extra.skip) return assert.skip(message, extra) + var name = t + if (typeof name === "function") name = name.name || "(anonymous ctor)" + //console.error("name=%s", name) + message = message || "type is "+name + var type = typeof thing + //console.error("type=%s", type) + if (!thing && type === "object") type = "null" + if (type === "object" && t !== "object") { + if (typeof t === "function") { + //console.error("it is a function!") + extra = extra || {} + extra.found = Object.getPrototypeOf(thing).constructor.name + extra.wanted = name + //console.error(thing instanceof t, name) + return assert.ok(thing instanceof t, message, extra) + } + + //console.error("check prototype chain") + // check against classnames or objects in prototype chain, as well. + // type(new Error("asdf"), "Error") + // type(Object.create(foo), foo) + var p = thing + while (p = Object.getPrototypeOf(p)) { + if (p === t || p.constructor && p.constructor.name === t) { + type = name + break + } + } + } + //console.error(type, name, type === name) + return assert.equal(type, name, message, extra) +} +assert.type = type +syns.type = ["isa"] + +// synonyms are helpful. +Object.keys(syns).forEach(function (c) { + syns[c].forEach(function (s) { + Object.defineProperty(assert, s, { value: assert[c], enumerable: false }) + }) +}) + +// helpers below + +function selectFields (a, b) { + // get the values in A of the fields in B + var ret = Array.isArray(b) ? [] : {} + Object.keys(b).forEach(function (k) { + if (!a.hasOwnProperty(k)) return + var v = b[k] + , av = a[k] + if (v && av && typeof v === "object" && typeof av === "object" + && !(v instanceof Date) + && !(v instanceof RegExp) + && !(v instanceof String) + && !(v instanceof Boolean) + && !(v instanceof Number) + && !(Array.isArray(v))) { + ret[k] = selectFields(av, v) + } else ret[k] = av + }) + return ret +} + +function sortObject (obj) { + if (typeof obj !== 'object' || Array.isArray(obj) || obj === null) { + return obj + } + + return Object.keys(obj).sort().reduce(function (acc, key) { + acc[key] = sortObject(obj[key]) + return acc + }, {}) +} + +function stringify (a) { + return JSON.stringify(sortObject(a), (function () { + var seen = [] + , keys = [] + return function (key, val) { + var s = seen.indexOf(val) + if (s !== -1) { + return "[Circular: "+keys[s]+"]" + } + if (val && typeof val === "object" || typeof val === "function") { + seen.push(val) + keys.push(val["!"] || val.name || key || "") + if (typeof val === "function") { + return val.toString().split(/\n/)[0] + } else if (typeof val.toUTCString === "function") { + return val.toUTCString() + } + } + return val + }})()) +} + +function diffString (f, w) { + if (w === f) return null + var p = 0 + , l = w.length + while (p < l && w.charAt(p) === f.charAt(p)) p ++ + w = stringify(w).substr(1).replace(/"$/, "") + f = stringify(f).substr(1).replace(/"$/, "") + return diff(f, w, p) +} + +function diffObject (f, w) { + return difflet({ indent : 2, comment : true }).compare(w, f) +} + +function diff (f, w, p) { + if (w === f) return null + var i = p || 0 // it's going to be at least p. JSON can only be bigger. + , l = w.length + while (i < l && w.charAt(i) === f.charAt(i)) i ++ + var pos = Math.max(0, i - 20) + w = w.substr(pos, 40) + f = f.substr(pos, 40) + var pointer = i - pos + return "FOUND: "+f+"\n" + + "WANTED: "+w+"\n" + + (new Array(pointer + 9).join(" ")) + + "^ (at position = "+p+")" +} + +function getCaller (er) { + // get the first file/line that isn't this file. + if (!er) er = new Error + var stack = er.stack || "" + stack = stack.split(/\n/) + for (var i = 1, l = stack.length; i < l; i ++) { + var s = stack[i].match(/\(([^):]+):([0-9]+):([0-9]+)\)$/) + if (!s) continue + var file = s[1] + , line = +s[2] + , col = +s[3] + if (file.indexOf(__dirname) === 0) continue + if (file.match(/tap-test\/test.js$/)) continue + else break + } + var res = {} + if (file && file !== __filename && !file.match(/tap-test\/test.js$/)) { + res.file = file + res.line = line + res.column = col + } + + res.stack = stack.slice(1).map(function (s) { + return s.replace(/^\s*at\s*/, "") + }) + + return res +} + + diff --git a/node_modules/nodeunit/node_modules/tap/lib/tap-browser-harness.js b/node_modules/nodeunit/node_modules/tap/lib/tap-browser-harness.js new file mode 100644 index 0000000..9eaa0e4 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/lib/tap-browser-harness.js @@ -0,0 +1,63 @@ +// this is just a harness that pipes to stdout. +// It's the default one. +module.exports = BrowserHarness + +var BrowserHarness = global.TAP_Browser_Harness + , inherits = require("inherits") + , Results = require("./tap-results") + , Harness = require("./tap-harness") + , Test = require("./tap-test") + +inherits(BrowserHarness, Harness) +function BrowserHarness (outPipe) { + //console.error("calling BrowserHarness") + if (browserHarness) return browserHarness + if (!(this instanceof BrowserHarness)) { + return browserHarness = new BrowserHarness + } + browserHarness = global.TAP_Browser_Harness = this + Harness.call(this, Test) + + if (outPipe) this.output.pipe(outPipe) + + this.test = this.test.bind(this) + + this.plan = this.plan.bind(this) + + var output = this.output + this.on("childEnd", function (child) { + //console.error("childEnd in global harness") + //console.error(child.results) + // write out the stuff for this child. + //console.error("child.conf", child.conf) + + // maybe write some other stuff about the number of tests in this + // thing, etc. I dunno. + //console.error("child results", child.results) + this.results.list.forEach(function (res) { + //delete res.error + //console.error("child resuilt", res) + output.write(res) + }) + //console.error("wrote child results") + this.results.list.length = 0 + }) + + var streamEnded = false + this.on("end", function () { + //console.error("global ending the stream") + if (!streamEnded) { + this.results.list.forEach(function (res) { + output.write(res) + }) + this.results.list.length = 0 + output.end() + streamEnded = true + } + }) + + // TODO: handle global errors + // process.on("unhandledException", function (e) { + // this.bailout("unhandled exception: " + e.message) + // }) +} diff --git a/node_modules/nodeunit/node_modules/tap/lib/tap-consumer.js b/node_modules/nodeunit/node_modules/tap/lib/tap-consumer.js new file mode 100644 index 0000000..0b991a5 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/lib/tap-consumer.js @@ -0,0 +1,246 @@ +module.exports = TapConsumer + +// pipe a stream into this that's emitting tap-formatted data, +// and it'll emit "data" events with test objects or comment strings +// and an "end" event with the final results. + +var yamlish = require("yamlish") + , Results = require("./tap-results") + , inherits = require("inherits") + +TapConsumer.decode = TapConsumer.parse = function (str) { + var tc = new TapConsumer + , list = [] + tc.on("data", function (res) { + list.push(res) + }) + tc.end(str) + tc.results.list = list + return tc.results +} + +var Stream = require("stream").Stream +inherits(TapConsumer, Stream) +function TapConsumer () { + if (!(this instanceof TapConsumer)) { + return new TapConsumer + } + + Stream.call(this) + this.results = new Results + this.readable = this.writable = true + + this.on("data", function (res) { + if (typeof res === "object") this.results.add(res) + }) + + this._plan = null + this._buffer = "" + this._indent = [] + this._current = null + this._actualCount = 0 + this._passed = [] + this._failed = [] + //console.error("TapConsumer ctor done") +} + +TapConsumer.prototype.bailedOut = false + +TapConsumer.prototype.write = function (chunk) { + if (!this.writable) this.emit("error", new Error("not writable")) + if (this.bailedOut) return true + + this._buffer = this._buffer + chunk + // split it up into lines. + var lines = this._buffer.split(/\r?\n/) + // ignore the last line, since it might be incomplete. + this._buffer = lines.pop() + + for (var i = 0, l = lines.length; i < l; i ++) { + //console.error([i, lines[i]]) + // see if it's indented. + var line = lines[i] + , spaces = (this._indent.length && !line.trim()) + || line.match(/^\s/) + // at this level, only interested in fully undented stuff. + if (spaces) { + var c = i + while (c < l && (!lines[c].trim() || lines[c].match(/^\s/))) { + this._indent.push(lines[c++]) + } + //console.error(c-i, "indented", this._indent, this._current) + i = c - 1 + continue + } + // some kind of line. summary, ok, notok, comment, or garbage. + // this also finishes parsing any of the indented lines from before + this._parseLine(line) + } + return true +} + +TapConsumer.prototype.end = function () { + // finish up any hanging indented sections or final buffer + if (this._buffer.match(/^\s/)) this._indent.push(this.buffer) + else this._parseLine(this._buffer) + + if (!this.bailedOut && + this._plan !== null && + this.results.testsTotal !== this._plan) { + while (this._actualCount < this._plan) { + this.emit("data", {ok: false, name:"MISSING TEST", + id:this._actualCount ++ }) + } + } + + this._parseLine("") + this._buffer = "" + this.writable = false + this.emit("end", null, this._actualCount, this._passed) +} + +TapConsumer.prototype._parseLine = function (line) { + if (this.bailedOut) return + //console.error("_parseLine", [line]) + // if there are any indented lines, and there is a + // current object already, then they belong to it. + // if there is not a current object, then they're garbage. + if (this._current && this._indent.length) { + this._parseIndented() + } + this._indent.length = 0 + if (this._current) { + if (this._current.ok) this._passed.push(this._current.id) + else this._failed.push(this._current.id) + this.emit("data", this._current) + } + this._current = null + line = line.trim() + if (!line) return + // try to see what kind of line this is. + + var bo + if (bo = line.match(/^bail out!\s*(.*)$/i)) { + this.bailedOut = true + // this.emit("error", new Error(line)) + this.emit("bailout", bo[1]) + return + } + + if (line.match(/^#/)) { // just a comment + line = line.replace(/^#+/, "").trim() + // console.error("outputting comment", [line]) + if (line) this.emit("data", line) + return + } + + var plan = line.match(/^([0-9]+)\.\.([0-9]+)(?:\s+#(.*))?$/) + if (plan) { + var start = +(plan[1]) + , end = +(plan[2]) + , comment = plan[3] + + // TODO: maybe do something else with this? + // it might be something like: "1..0 #Skip because of reasons" + this._plan = end + this.emit("plan", end, comment) + // plan must come before or after all tests. + if (this._actualCount !== 0) { + this._sawPlan = true + } + return + } + + if (line.match(/^(not )?ok(?:\s+([0-9]+))?/)) { + this._parseResultLine(line) + return + } + + // garbage. emit as a comment. + //console.error("emitting", [line.trim()]) + if (line.trim()) this.emit("data", line.trim()) +} + +TapConsumer.prototype._parseDirective = function (line) { + line = line.trim() + if (line.match(/^TODO\b/i)) { + return { todo:true, explanation: line.replace(/^TODO\s*/i, "") } + } else if (line.match(/^SKIP\b/i)) { + return { skip:true, explanation: line.replace(/^SKIP\s*/i, "") } + } +} + +TapConsumer.prototype._parseResultLine = function (line) { + this._actualCount ++ + if (this._sawPlan) { + this.emit("data", {ok: false, name:"plan in the middle of tests" + ,id:this._actualCount ++}) + } + var parsed = line.match(/^(not )?ok(?: ([0-9]+))?(?:(?: - )?(.*))?$/) + , ok = !parsed[1] + , id = +(parsed[2] || this._actualCount) + , rest = parsed[3] || "" + , name + , res = { id:id, ok:ok } + + // split on un-escaped # characters + + //console.log("# "+JSON.stringify([name, rest])) + rest = rest.replace(/([^\\])((?:\\\\)*)#/g, "$1\n$2").split("\n") + name = rest.shift() + rest = rest.filter(function (r) { return r.trim() }).join("#") + //console.log("# "+JSON.stringify([name, rest])) + + // now, let's see if there's a directive in there. + var dir = this._parseDirective(rest.trim()) + if (!dir) name += rest ? "#" + rest : "" + else { + res.ok = true + if (dir.skip) res.skip = true + else if (dir.todo) res.todo = true + if (dir.explanation) res.explanation = dir.explanation + } + res.name = name + + //console.error(line, [ok, id, name]) + this._current = res +} + +TapConsumer.prototype._parseIndented = function () { + // pull yamlish block out + var ind = this._indent + , ys + , ye + , yind + , diag + //console.error(ind, this._indent) + for (var i = 0, l = ind.length; i < l; i ++) { + var line = ind[i] + if (line === undefined) continue + var lt = line.trim() + + if (!ys) { + ys = line.match(/^(\s*)---(.*)$/) + if (ys) { + yind = ys[1] + diag = [ys[2]] + //console.error([line,ys, diag]) + continue + } else if (lt) this.emit("data", lt) + } else if (ys && !ye) { + if (line === yind + "...") ye = true + else { + diag.push(line.substr(yind.length)) + } + } else if (ys && ye && lt) this.emit("data", lt) + } + if (diag) { + //console.error('about to parse', diag) + diag = yamlish.decode(diag.join("\n")) + //console.error('parsed', diag) + Object.keys(diag).forEach(function (k) { + //console.error(this._current, k) + if (!this._current.hasOwnProperty(k)) this._current[k] = diag[k] + }, this) + } +} diff --git a/node_modules/nodeunit/node_modules/tap/lib/tap-cov-html.js b/node_modules/nodeunit/node_modules/tap/lib/tap-cov-html.js new file mode 100644 index 0000000..3c1c192 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/lib/tap-cov-html.js @@ -0,0 +1,78 @@ +var fs = require('fs'), + path = require('path'), + asyncMap = require("slide").asyncMap, + util = require('util'); + +var CovHtml = module.exports = function(cov_stats, cov_dir, cb) { + var index = []; + + asyncMap( + Object.keys(cov_stats), + function(f, cb) { + var st = cov_stats[f], + missing_lines = st.missing.map(function(l) { + return l.number; + }), + out = '\n\n\n ' + + '\n ' + + + f + ' (' + st.loc + ')\n' + + '\n' + + '\n\n' + + '

    ' + f + ' (' + st.loc + ')' + '

    ' + + '

    Run: ' + (st.missing.length ? st.loc - st.missing.length : st.loc) + ', Missing: ' + + st.missing.length + ', Percentage: ' + st.percentage + '

    ' + + '

    Source:

    \n' + + '
      \n' + + st.lines.map(function(line) { + var number = line.number, + color = (missing_lines.indexOf(number) !== -1) ? '#fcc' : '#cfc'; + return '
    1. ' + line.source.replace(/'; + }).join('\n') + + '
    \n' + + '

    Data

    \n'+ + '
    ' + util.inspect(st, true, Infinity, false).replace(/\n';
    +
    +      fs.writeFile(
    +        cov_dir + '/' + 
    +        f.replace(process.cwd() + '/', '').replace(/\//g, '+') + '.html',
    +        out,
    +        'utf8',
    +        function(err) {
    +          if (err) {
    +            throw err;
    +          }
    +          index.push(f);
    +          cb();
    +        });
    +    },
    +    function(err) {
    +      if (err) {
    +        throw err;
    +      }
    +      var out = '\n\n\n  ' +
    +          '\n  Coverage Index\n\n' +
    +          '\n

    Code Coverage Information

    \n
      ' + + index.map(function(fname) { + return '
    • ' + fname + '
    • '; + }).join('\n') + '
    \n\n'; + + fs.writeFile(cov_dir + '/index.html', out, 'utf8', function(err) { + if (err) { + throw err; + } + cb(); + }); + } + ); +}; + + diff --git a/node_modules/nodeunit/node_modules/tap/lib/tap-global-harness.js b/node_modules/nodeunit/node_modules/tap/lib/tap-global-harness.js new file mode 100644 index 0000000..2fb1933 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/lib/tap-global-harness.js @@ -0,0 +1,68 @@ +// this is just a harness that pipes to stdout. +// It's the default one. +module.exports = GlobalHarness + +var globalHarness = global.TAP_Global_Harness + , inherits = require("inherits") + , Results = require("./tap-results") + , Harness = require("./tap-harness") + , Test = require("./tap-test") + +inherits(GlobalHarness, Harness) +function GlobalHarness () { + //console.error("calling GlobalHarness") + if (globalHarness) return globalHarness + if (!(this instanceof GlobalHarness)) { + return globalHarness = new GlobalHarness + } + + globalHarness = global.TAP_Global_Harness = this + Harness.call(this, Test) + + this.output.pipe(process.stdout) + //this.output.on("data", function () { + // process.nextTick(process.stdout.flush.bind(process.stdout)) + //}) + + this.test = this.test.bind(this) + + this.plan = this.plan.bind(this) + + var output = this.output + this.on("childEnd", function (child) { + //console.error("childEnd in global harness") + //console.error(child.results) + // write out the stuff for this child. + //console.error("child.conf", child.conf) + + // maybe write some other stuff about the number of tests in this + // thing, etc. I dunno. + //console.error("child results", child.results) + this.results.list.forEach(function (res) { + //delete res.error + //console.error("child resuilt", res) + output.write(res) + }) + //console.error("wrote child results") + this.results.list.length = 0 + }) + + var streamEnded = false + this.on("end", function () { + //console.error("global ending the stream") + if (!streamEnded) { + this.results.list.forEach(function (res) { + output.write(res) + }) + this.results.list.length = 0 + output.end() + streamEnded = true + } + }) + + //this.on("end", this.output.end.bind(this.output)) + + process.on("unhandledException", function (e) { + this.bailout("unhandled exception: " + e.message) + }) +} diff --git a/node_modules/nodeunit/node_modules/tap/lib/tap-harness.js b/node_modules/nodeunit/node_modules/tap/lib/tap-harness.js new file mode 100644 index 0000000..f06f63c --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/lib/tap-harness.js @@ -0,0 +1,224 @@ +// a thing that runs tests. +// Every "test" is also a harness. If they do not have a harness, +// then they are attached to the defaut "global harness", +// which writes its results to stdout. + + +// TODO: +// - Bailout should stop running any tests. +// - "skip" in the test config obj should skip it. + +module.exports = Harness +var EE = require("events").EventEmitter +require("inherits")(Harness, EE) + +var Results = require("./tap-results") + , TapProducer = require("./tap-producer") + , assert = require("./tap-assert") + +function Harness (Test) { + if (!(this instanceof Harness)) return new Harness(Test) + + //console.error("Test in "+this.constructor.name, Test) + + this._Test = Test + this._plan = null + this._children = [] + this._started = false + + this._testCount = 0 + this._planSum = 0 + + this.results = new Results() + // emit result events on the harness. + //this.results.on("result", function (res) { + // console.error("proxying result ev from res to harness") + // this.emit("result", res) + //}.bind(this)) + var me = this + this.results.on("result", this.emit.bind(this, "result")) + + var p = this.process.bind(this) + this.process = function () { + this._started = true + process.nextTick(p) + } + + this.output = new TapProducer() + EE.call(this) +} + +// this function actually only gets called bound to +// the Harness object, and on process.nextTick. Even if +// passed as an event handler, everything *else* will +// happen before it gets called. +Harness.prototype.process = function () { + //console.error("harness process") + // "end" can emit multiple times, so only actually move on + // to the next test if the current one is actually over. + // TODO: multiple in-process tests, if all are marked "async" + if (this._current) { + if (!this._current._ended) return + // handle the current one before moving onto the next. + this.childEnd(this._current) + } + var skip = true + while (skip) { + //console.error("checking for skips") + var current = this._current = this._children.shift() + if (current) { + skip = current.conf.skip + if (skip) { + //console.error("add a failure for the skipping") + this.results.add(assert.fail(current.conf.name + ,{skip:true, diag:false})) + } + } else skip = false + } + + // keep processing through skipped tests, instead of running them. + if (current && this._bailedOut) { + return this.process() + } + + //console.error("got current?", !!current) + if (current) { + current.on("end", this.process) + current.emit("ready") + //console.error("emitted ready") + //console.error("_plan", this._plan, this.constructor.name) + } else { + //console.error("Harness process: no more left. ending") + if (this._endNice) { + this._endNice() + } else { + this.end() + } + } +} + +Harness.prototype.end = function () { + if (this._children.length) { + return this.process() + } + //console.error("harness end", this.constructor.name) + if (this._bailedOut) return + + // can't call .end() more than once. + if (this._ended) { + //console.error("adding failure for end calling") + this.results.add(assert.fail("end called more than once")) + } + + // see if the plan is completed properly, if there was one. + if (this._plan !== null) { + var total = this._testCount + if (total !== this._plan) { + this.results.add(assert.equal(total, this._plan, "test count != plan")) + } + this._plan = total + } + + //console.error("setting ended true", this.constructor.name) + this._ended = true + this.emit("end") +} + +Harness.prototype.plan = function (p) { + //console.error("setting plan", new Error().stack) + if (this._plan !== null) { + //console.error("about to add failure for calling plan") + return this.results.add(assert.fail("plan set multiple times")) + } + this._plan = p + if (p === 0 || this.results.testsTotal) { + this.end() + } +} + +Harness.prototype.childEnd = function (child) { + //console.error("childEnd") + this._testCount ++ + this._planSum += child._plan + //console.error("adding set of child.results") + + this.results.add(child.conf.name || "(unnamed test)") + this.results.addSet(child.results) + this.emit("childEnd", child) + // was this planned? + if (this._plan === this._testCount) { + //console.error("plan", [this._plan, this._testCount]) + return this.end() + } +} + +function copyObj(o) { + var copied = {} + Object.keys(o).forEach(function (k) { copied[k] = o[k] }) + return copied +} + +Harness.prototype.test = function test (name, conf, cb) { + if (this._bailedOut) return + + if (typeof conf === "function") cb = conf, conf = null + if (typeof name === "object") conf = name, name = null + if (typeof name === "function") cb = name, name = null + + conf = (conf ? copyObj(conf) : {}) + name = name || "" + + //console.error("making test", [name, conf, cb]) + + // timeout: value in milliseconds. Defaults to 30s + // Set to Infinity to have no timeout. + if (isNaN(conf.timeout)) conf.timeout = 30000 + var t = new this._Test(this, name, conf) + var self = this + if (cb) { + //console.error("attaching cb to ready event") + t.on("ready", function () { + if (!isNaN(conf.timeout) && isFinite(conf.timeout)) { + var timer = setTimeout(this.timeout.bind(this), conf.timeout) + var clear = function () { + clearTimeout(timer) + } + t.on("end", clear) + t.on("bailout", function (message) { + self.bailout(message) + clear() + }) + } + }) + t.on("ready", cb.bind(t, t)) + // proxy the child results to this object. + //t.on("result", function (res) { + // console.error("in harness, proxying result up") + // t.results.add(res) + //}) + } + return t +} + +Harness.prototype.bailout = function (message) { + // console.error("Harness bailout", this.constructor.name) + message = message || "" + //console.error("adding bailout message result") + this.results.add({bailout: message}) + // console.error(">>> results after bailout" , this.results) + this._bailedOut = true + this.emit("bailout", message) + this.output.end({bailout: message}) +} + +Harness.prototype.add = function (child) { + //console.error("adding child") + this._children.push(child) + if (!this._started) this.process() +} + +// the tearDown function is *always* guaranteed to happen. +// Even if there's a bailout. +Harness.prototype.tearDown = function (fn) { + this.on("end", fn) +} diff --git a/node_modules/nodeunit/node_modules/tap/lib/tap-producer.js b/node_modules/nodeunit/node_modules/tap/lib/tap-producer.js new file mode 100644 index 0000000..99dbb87 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/lib/tap-producer.js @@ -0,0 +1,131 @@ +module.exports = TapProducer + +var Results = require("./tap-results") + , inherits = require("inherits") + , yamlish = require("yamlish") + +TapProducer.encode = function (result, diag) { + var tp = new TapProducer(diag) + , out = "" + tp.on("data", function (c) { out += c }) + if (Array.isArray(result)) { + result.forEach(tp.write, tp) + } else tp.write(result) + tp.end() + return out +} + +var Stream = require("stream").Stream +inherits(TapProducer, Stream) +function TapProducer (diag) { + Stream.call(this) + this.diag = diag + this.count = 0 + this.readable = this.writable = true + this.results = new Results +} + +TapProducer.prototype.trailer = true + +TapProducer.prototype.write = function (res) { + // console.error("TapProducer.write", res) + if (typeof res === "function") throw new Error("wtf?") + if (!this.writable) this.emit("error", new Error("not writable")) + + if (!this._didHead) { + this.emit("data", "TAP version 13\n") + this._didHead = true + } + + var diag = res.diag + if (diag === undefined) diag = this.diag + + this.emit("data", encodeResult(res, this.count + 1, diag)) + + if (typeof res === "string") return true + + if (res.bailout) { + var bo = "bail out!" + if (typeof res.bailout === "string") bo += " " + res.bailout + this.emit("data", bo) + return + } + this.results.add(res, false) + + this.count ++ +} + +TapProducer.prototype.end = function (res) { + if (res) this.write(res) + // console.error("TapProducer end", res, this.results) + this.emit("data", "\n1.."+this.results.testsTotal+"\n") + if (this.trailer && typeof this.trailer !== "string") { + // summary trailer. + var trailer = "tests "+this.results.testsTotal + "\n" + if (this.results.pass) { + trailer += "pass " + this.results.pass + "\n" + } + if (this.results.fail) { + trailer += "fail " + this.results.fail + "\n" + } + if (this.results.skip) { + trailer += "skip "+this.results.skip + "\n" + } + if (this.results.todo) { + trailer += "todo "+this.results.todo + "\n" + } + if (this.results.bailedOut) { + trailer += "bailed out" + "\n" + } + + if (this.results.testsTotal === this.results.pass) { + trailer += "\nok\n" + } + this.trailer = trailer + } + if (this.trailer) this.write(this.trailer) + this.writable = false + this.emit("end", null, this.count, this.ok) +} + +function encodeResult (res, count, diag) { + // console.error(res, count, diag) + if (typeof res === "string") { + res = res.split(/\r?\n/).map(function (l) { + if (!l.trim()) return l.trim() + return "# " + l + }).join("\n") + if (res.substr(-1) !== "\n") res += "\n" + return res + } + + if (res.bailout) return "" + + + if (!!process.env.TAP_NODIAG) diag = false + else if (!!process.env.TAP_DIAG) diag = true + else if (diag === undefined) diag = !res.ok + + var output = "" + res.name = res.name && ("" + res.name).trim() + output += ( !res.ok ? "not " : "") + "ok " + count + + ( !res.name ? "" + : " " + res.name.replace(/[\r\n]/g, " ") ) + + ( res.skip ? " # SKIP" + : res.todo ? " # TODO" + : "" ) + + "\n" + + if (!diag) return output + var d = {} + , dc = 0 + Object.keys(res).filter(function (k) { + return k !== "ok" && k !== "name" && k !== "id" + }).forEach(function (k) { + dc ++ + d[k] = res[k] + }) + //console.error(d, "about to encode") + if (dc > 0) output += " ---"+yamlish.encode(d)+"\n ...\n" + return output +} diff --git a/node_modules/nodeunit/node_modules/tap/lib/tap-results.js b/node_modules/nodeunit/node_modules/tap/lib/tap-results.js new file mode 100644 index 0000000..6fe90e8 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/lib/tap-results.js @@ -0,0 +1,71 @@ +// A class for counting up results in a test harness. + +module.exports = Results + +var inherits = require("inherits") + , EventEmitter = require("events").EventEmitter + +inherits(Results, EventEmitter) + +function Results (r) { + //console.error("result constructor", r) + this.ok = true + this.addSet(r) +} + +Results.prototype.addSet = function (r) { + //console.error("add set of results", r) + r = r || {ok: true} + ; [ "todo" + , "todoPass" + , "todoFail" + , "skip" + , "skipPass" + , "skipFail" + , "pass" + , "passTotal" + , "fail" + , "failTotal" + , "tests" + , "testsTotal" ].forEach(function (k) { + this[k] = (this[k] || 0) + (r[k] || 0) + //console.error([k, this[k]]) + }, this) + + this.ok = this.ok && r.ok && true + this.bailedOut = this.bailedOut || r.bailedOut || false + this.list = (this.list || []).concat(r.list || []) + this.emit("set", this.list) + //console.error("after addSet", this) +} + +Results.prototype.add = function (r, addToList) { + //console.error("add result", r) + var pf = r.ok ? "pass" : "fail" + , PF = r.ok ? "Pass" : "Fail" + + this.testsTotal ++ + this[pf + "Total"] ++ + + if (r.skip) { + this["skip" + PF] ++ + this.skip ++ + } else if (r.todo) { + this["todo" + PF] ++ + this.todo ++ + } else { + this.tests ++ + this[pf] ++ + } + + if (r.bailout || typeof r.bailout === "string") { + // console.error("Bailing out in result") + this.bailedOut = true + } + this.ok = !!(this.ok && r.ok) + + if (addToList === false) return + this.list = this.list || [] + this.list.push(r) + this.emit("result", r) +} diff --git a/node_modules/nodeunit/node_modules/tap/lib/tap-runner.js b/node_modules/nodeunit/node_modules/tap/lib/tap-runner.js new file mode 100644 index 0000000..c60e8d1 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/lib/tap-runner.js @@ -0,0 +1,501 @@ +var fs = require("fs") + , child_process = require("child_process") + , path = require("path") + , chain = require("slide").chain + , asyncMap = require("slide").asyncMap + , TapProducer = require("./tap-producer.js") + , TapConsumer = require("./tap-consumer.js") + , assert = require("./tap-assert.js") + , inherits = require("inherits") + , util = require("util") + , CovHtml = require("./tap-cov-html.js") + , glob = require("glob") + + // XXX Clean up the coverage options + , doCoverage = process.env.TAP_COV + || process.env.npm_package_config_coverage + || process.env.npm_config_coverage + +module.exports = Runner + +inherits(Runner, TapProducer) + +function Runner (options, cb) { + this.options = options + + var diag = this.options.diag + var dir = this.options.argv.remain + TapProducer.call(this, diag) + + this.doCoverage = doCoverage + // An array of full paths to files to obtain coverage + this.coverageFiles = [] + // The source of these files + this.coverageFilesSource = {} + // Where to write coverage information + this.coverageOutDir = this.options["coverage-dir"] + // Temporary test files bunkerified we'll remove later + this.f2delete = [] + // Raw coverage stats, as read from JSON files + this.rawCovStats = [] + // Processed coverage information, per file to cover: + this.covStats = {} + + if (dir) { + var filesToCover = this.options.cover + + if (doCoverage) { + var mkdirp = require("mkdirp") + this.coverageOutDir = path.resolve(this.coverageOutDir) + this.getFilesToCover(filesToCover) + var self = this + return mkdirp(this.coverageOutDir, 0755, function (er) { + if (er) return self.emit("error", er) + self.run(dir, cb) + }) + } + + this.run(dir, cb) + } +} + + +Runner.prototype.run = function() { + var self = this + , args = Array.prototype.slice.call(arguments) + , cb = args.pop() || finish + + function finish (er) { + if (er) { + self.emit("error", er) + } + + if (!doCoverage) return self.end() + + // Cleanup temporary test files with coverage: + self.f2delete.forEach(function(f) { + fs.unlinkSync(f) + }) + self.getFilesToCoverSource(function(err, data) { + if (err) { + self.emit("error", err) + } + self.getPerFileCovInfo(function(err, data) { + if (err) { + self.emit("error", err) + } + self.mergeCovStats(function(err, data) { + if (err) { + self.emit("error", err) + } + CovHtml(self.covStats, self.coverageOutDir, function() { + self.end() + }) + }) + }) + }) + } + + if (Array.isArray(args[0])) { + args = args[0] + } + self.runFiles(args, "", cb) +} + +Runner.prototype.runDir = function (dir, cb) { + var self = this + fs.readdir(dir, function (er, files) { + if (er) { + self.write(assert.fail("failed to readdir " + dir, { error: er })) + self.end() + return + } + files = files.sort(function(a, b) { + return a > b ? 1 : -1 + }) + files = files.filter(function(f) { + return !f.match(/^\./) + }) + files = files.map(function(file) { + return path.resolve(dir, file) + }) + + self.runFiles(files, path.resolve(dir), cb) + }) +} + + +// glob the filenames so that test/*.js works on windows +Runner.prototype.runFiles = function (files, dir, cb) { + var self = this + var globRes = [] + chain(files.map(function (f) { + return function (cb) { + glob(f, function (er, files) { + if (er) + return cb(er) + globRes.push.apply(globRes, files) + cb() + }) + } + }), function (er) { + if (er) + return cb(er) + runFiles(self, globRes, dir, cb) + }) +} + +// set some default options for node debugging tests +function setOptionsForDebug(self) { + // Note: we automatically increase the default timeout here. Yes + // the user can specify --timeout to increase, but by default, + // 30 seconds is not a long time to debug your test. + self.options.timeout = 1000000; + + // Note: we automatically turn on stderr so user can see the 'debugger listening on port' message. + // Without this it looks like tap has hung.. + self.options.stderr = true; +} + +function runFiles(self, files, dir, cb) { + chain(files.map(function(f) { + return function (cb) { + if (self._bailedOut) return + var relDir = dir || path.dirname(f) + , fileName = relDir === "." ? f : f.substr(relDir.length + 1) + + self.write(fileName) + fs.lstat(f, function(er, st) { + if (er) { + self.write(assert.fail("failed to stat " + f, {error: er})) + return cb() + } + + var cmd = f, args = [], env = {} + + if (path.extname(f) === ".js") { + cmd = process.execPath + if (self.options.gc) { + args.push("--expose-gc") + } + if (self.options.debug) { + args.push("--debug") + setOptionsForDebug(self) + } + if (self.options["debug-brk"]) { + args.push("--debug-brk") + setOptionsForDebug(self) + } + if (self.options.strict) { + args.push("--use-strict") + } + if (self.options.harmony) { + args.push("--harmony") + } + args.push(fileName) + } else if (path.extname(f) === ".coffee") { + cmd = "coffee" + args.push(fileName) + } else { + // Check if file is executable + if ((st.mode & 0100) && process.getuid) { + if (process.getuid() != st.uid) { + return cb() + } + } else if ((st.mode & 0010) && process.getgid) { + if (process.getgid() != st.gid) { + return cb() + } + } else if ((st.mode & 0001) == 0) { + return cb() + } + } + + if (st.isDirectory()) { + return self.runDir(f, cb) + } + + if (doCoverage && path.extname(f) === ".js") { + var foriginal = fs.readFileSync(f, "utf8") + , fcontents = self.coverHeader() + foriginal + self.coverFooter() + , tmpBaseName = path.basename(f, path.extname(f)) + + ".with-coverage." + process.pid + path.extname(f) + , tmpFname = path.resolve(path.dirname(f), tmpBaseName) + + fs.writeFileSync(tmpFname, fcontents, "utf8") + args.splice(-1, 1, tmpFname) + } + + for (var i in process.env) { + env[i] = process.env[i] + } + env.TAP = 1 + + var cp = child_process.spawn(cmd, args, { env: env, cwd: relDir }) + , out = "" + , err = "" + , tc = new TapConsumer() + , childTests = [f] + + var timeout = setTimeout(function () { + if (!cp._ended) { + cp._timedOut = true + cp.kill() + } + }, self.options.timeout * 1000) + + tc.on("data", function(c) { + self.emit("result", c) + self.write(c) + }) + + tc.on("bailout", function (message) { + clearTimeout(timeout) + console.log("# " + f.substr(process.cwd().length + 1)) + process.stderr.write(err) + process.stdout.write(out + "\n") + self._bailedOut = true + cp._ended = true + cp.kill() + }) + + cp.stdout.pipe(tc) + cp.stdout.on("data", function (c) { out += c }) + cp.stderr.on("data", function (c) { + if (self.options.stderr) process.stderr.write(c) + err += c + }) + + cp.on("close", function (code, signal) { + if (cp._ended) return + cp._ended = true + var ok = !cp._timedOut && code === 0 + clearTimeout(timeout) + //childTests.forEach(function (c) { self.write(c) }) + var res = { name: path.dirname(f).replace(process.cwd() + "/", "") + + "/" + fileName + , ok: ok + , exit: code } + + if (cp._timedOut) + res.timedOut = cp._timedOut + if (signal) + res.signal = signal + + if (err) { + res.stderr = err + if (tc.results.ok && + tc.results.tests === 0 && + !self.options.stderr) { + // perhaps a compilation error or something else failed. + // no need if stderr is set, since it will have been + // output already anyway. + console.error(err) + } + } + + // tc.results.ok = tc.results.ok && ok + tc.results.add(res) + res.command = '"'+[cmd].concat(args).join(" ")+'"' + self.emit("result", res) + self.emit("file", f, res, tc.results) + self.write(res) + self.write("\n") + if (doCoverage) { + self.f2delete.push(tmpFname) + } + cb() + }) + }) + } + }), cb) + + return self +} + + +// Get an array of full paths to files we are interested into obtain +// code coverage. +Runner.prototype.getFilesToCover = function(filesToCover) { + var self = this + filesToCover = filesToCover.split(",").map(function(f) { + return path.resolve(f) + }).filter(function(f) { + var existsSync = fs.existsSync || path.existsSync; + return existsSync(f) + }) + + function recursive(f) { + if (path.extname(f) === "") { + // Is a directory: + fs.readdirSync(f).forEach(function(p) { + recursive(f + "/" + p) + }) + } else { + self.coverageFiles.push(f) + } + } + filesToCover.forEach(function(f) { + recursive(f) + }) +} + +// Prepend to every test file to run. Note tap.test at the very top due it +// "plays" with include paths. +Runner.prototype.coverHeader = function() { + // semi here since we're injecting it before the first line, + // and don't want to mess up line numbers in the test files. + return "var ___TAP_COVERAGE = require(" + + JSON.stringify(require.resolve("runforcover")) + + ").cover(/.*/g);" +} + +// Append at the end of every test file to run. Actually, the stuff which gets +// the coverage information. +// Maybe it would be better to move into a separate file template so editing +// could be easier. +Runner.prototype.coverFooter = function() { + var self = this + // This needs to be a string with proper interpolations: + return [ "" + , "var ___TAP = require(" + JSON.stringify(require.resolve("./main.js")) + ")" + , "if (typeof ___TAP._plan === 'number') ___TAP._plan ++" + , "___TAP.test(" + JSON.stringify("___coverage") + ", function(t) {" + , " var covFiles = " + JSON.stringify(self.coverageFiles) + , " , covDir = " + JSON.stringify(self.coverageOutDir) + , " , path = require('path')" + , " , fs = require('fs')" + , " , testFnBase = path.basename(__filename, '.js') + '.json'" + , " , testFn = path.resolve(covDir, testFnBase)" + , "" + , " function asyncForEach(arr, fn, callback) {" + , " if (!arr.length) {" + , " return callback()" + , " }" + , " var completed = 0" + , " arr.forEach(function(i) {" + , " fn(i, function (err) {" + , " if (err) {" + , " callback(err)" + , " callback = function () {}" + , " } else {" + , " completed += 1" + , " if (completed === arr.length) {" + , " callback()" + , " }" + , " }" + , " })" + , " })" + , " }" + , "" + , " ___TAP_COVERAGE(function(coverageData) {" + , " var outObj = {}" + , " asyncForEach(covFiles, function(f, cb) {" + , " if (coverageData[f]) {" + , " var stats = coverageData[f].stats()" + , " , stObj = stats" + , " stObj.lines = stats.lines.map(function (l) {" + , " return { number: l.lineno, source: l.source() }" + , " })" + , " outObj[f] = stObj" + , " }" + , " cb()" + , " }, function(err) {" + , " ___TAP_COVERAGE.release()" + , " fs.writeFileSync(testFn, JSON.stringify(outObj))" + , " t.end()" + , " })" + , " })" + , "})" ].join("\n") +} + + +Runner.prototype.getFilesToCoverSource = function(cb) { + var self = this + asyncMap(self.coverageFiles, function(f, cb) { + fs.readFile(f, "utf8", function(err, data) { + var lc = 0 + if (err) { + cb(err) + } + self.coverageFilesSource[f] = data.split("\n").map(function(l) { + lc += 1 + return { number: lc, source: l } + }) + cb() + }) + }, cb) +} + +Runner.prototype.getPerFileCovInfo = function(cb) { + var self = this + , covPath = path.resolve(self.coverageOutDir) + + fs.readdir(covPath, function(err, files) { + if (err) { + self.emit("error", err) + } + var covFiles = files.filter(function(f) { + return path.extname(f) === ".json" + }) + asyncMap(covFiles, function(f, cb) { + fs.readFile(path.resolve(covPath, f), "utf8", function(err, data) { + if (err) { + cb(err) + } + self.rawCovStats.push(JSON.parse(data)) + cb() + }) + }, function(f, cb) { + fs.unlink(path.resolve(covPath, f), cb) + }, cb) + }) +} + +Runner.prototype.mergeCovStats = function(cb) { + var self = this + self.rawCovStats.forEach(function(st) { + Object.keys(st).forEach(function(i) { + // If this is the first time we reach this file, just add the info: + if (!self.covStats[i]) { + self.covStats[i] = { + missing: st[i].lines + } + } else { + // If we already added info for this file before, we need to remove + // from self.covStats any line not duplicated again (since it has + // run on such case) + self.covStats[i].missing = self.covStats[i].missing.filter( + function(l) { + return (st[i].lines.indexOf(l)) + }) + } + }) + }) + + // This is due to a bug into + // chrisdickinson/node-bunker/blob/feature/add-coverage-interface + // which is using array indexes for line numbers instead of the right number + Object.keys(self.covStats).forEach(function(f) { + self.covStats[f].missing = self.covStats[f].missing.map(function(line) { + return { number: line.number, source: line.source } + }) + }) + + Object.keys(self.coverageFilesSource).forEach(function(f) { + if (!self.covStats[f]) { + self.covStats[f] = { missing: self.coverageFilesSource[f] + , percentage: 0 + } + } + self.covStats[f].lines = self.coverageFilesSource[f] + self.covStats[f].loc = self.coverageFilesSource[f].length + + if (!self.covStats[f].percentage) { + self.covStats[f].percentage = + 1 - (self.covStats[f].missing.length / self.covStats[f].loc) + } + + }) + cb() +} diff --git a/node_modules/nodeunit/node_modules/tap/lib/tap-test.js b/node_modules/nodeunit/node_modules/tap/lib/tap-test.js new file mode 100644 index 0000000..ec73321 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/lib/tap-test.js @@ -0,0 +1,110 @@ +// This is a very simple test framework that leverages the tap framework +// to run tests and output tap-parseable results. + +module.exports = Test + +var assert = require("./tap-assert") + , inherits = require("inherits") + , Results = require("./tap-results") + , Harness = require("./tap-harness") + +// tests are also test harnesses +inherits(Test, Harness) + +function Test (harness, name, conf) { + //console.error("test ctor") + if (!(this instanceof Test)) return new Test(harness, name, conf) + + Harness.call(this, Test) + + conf.name = name || conf.name || "(anonymous)" + this.conf = conf + + this.harness = harness + this.harness.add(this) +} + +// it's taking too long! +Test.prototype.timeout = function () { + // detect false alarms + if (this._ended) return + this.fail("Timeout!") + this.end() +} + +Test.prototype.clear = function () { + this._started = false + this._ended = false + this._plan = null + this._bailedOut = false + this._testCount = 0 + this.results = new Results() +} + +// this gets called if a test throws ever +Test.prototype.threw = function (ex) { + //console.error("threw!", ex.stack) + this.fail(ex.name + ": " + ex.message, { error: ex, thrown: true }) + // may emit further failing tests if the plan is not completed + //console.error("end, because it threw") + if (!this._ended) this.end() +} + +Test.prototype.comment = function (m) { + if (typeof m !== "string") { + return this.fail("Test.comment argument must be a string") + } + this.result("\n" + m.trim()) +} + +Test.prototype.result = function (res) { + this.results.add(res) + this._testCount ++ + this.emit("result", res) + if (this._plan === this._testCount) { + process.nextTick(this._endNice.bind(this)) + } +} + +Test.prototype._endNice = function () { + if (!this._ended) this.end() +} + +// parasitic +// Who says you can't do multiple inheritance in js? +Object.getOwnPropertyNames(assert).forEach(function (k) { + if (k === "prototype" || k === "name") return + var d = Object.getOwnPropertyDescriptor(assert, k) + , v = d.value + if (!v) return + d.value = assertParasite(v) + Object.defineProperty(Test.prototype, k, d) +}) + +function assertParasite (fn) { return function _testAssert () { + //console.error("_testAssert", fn.name, arguments) + if (this._bailedOut) return + var res = fn.apply(assert, arguments) + this.result(res) + return res +}} + +// a few tweaks on the EE emit function, because +// we want to catch all thrown errors and bubble up "bailout" +Test.prototype.emit = (function (em) { return function (t) { + // bailouts bubble until handled + if (t === "bailout" && + this.listeners(t).length === 0 && + this.harness) { + return this.harness.bailout(arguments[1]) + } + + if (t === "error") return em.apply(this, arguments) + try { + em.apply(this, arguments) + } catch (ex) { + // any exceptions in a test are a failure + //console.error("caught!", ex.stack) + this.threw(ex) + } +}})(Harness.prototype.emit) diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/.bin/mkdirp b/node_modules/nodeunit/node_modules/tap/node_modules/.bin/mkdirp new file mode 120000 index 0000000..017896c --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/.bin/mkdirp @@ -0,0 +1 @@ +../mkdirp/bin/cmd.js \ No newline at end of file diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/.bin/nopt b/node_modules/nodeunit/node_modules/tap/node_modules/.bin/nopt new file mode 120000 index 0000000..6b6566e --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/.bin/nopt @@ -0,0 +1 @@ +../nopt/bin/nopt.js \ No newline at end of file diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/buffer-equal/.travis.yml b/node_modules/nodeunit/node_modules/tap/node_modules/buffer-equal/.travis.yml new file mode 100644 index 0000000..dad2273 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/buffer-equal/.travis.yml @@ -0,0 +1,4 @@ +language: node_js +node_js: + - 0.8 + - "0.10" diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/buffer-equal/README.markdown b/node_modules/nodeunit/node_modules/tap/node_modules/buffer-equal/README.markdown new file mode 100644 index 0000000..8c062fd --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/buffer-equal/README.markdown @@ -0,0 +1,62 @@ +buffer-equal +============ + +Return whether two buffers are equal. + +[![build status](https://secure.travis-ci.org/substack/node-buffer-equal.png)](http://travis-ci.org/substack/node-buffer-equal) + +example +======= + +``` js +var bufferEqual = require('buffer-equal'); + +console.dir(bufferEqual( + new Buffer([253,254,255]), + new Buffer([253,254,255]) +)); +console.dir(bufferEqual( + new Buffer('abc'), + new Buffer('abcd') +)); +console.dir(bufferEqual( + new Buffer('abc'), + 'abc' +)); +``` + +output: + +``` +true +false +undefined +``` + +methods +======= + +``` js +var bufferEqual = require('buffer-equal') +``` + +bufferEqual(a, b) +----------------- + +Return whether the two buffers `a` and `b` are equal. + +If `a` or `b` is not a buffer, return `undefined`. + +install +======= + +With [npm](http://npmjs.org) do: + +``` +npm install buffer-equal +``` + +license +======= + +MIT diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/buffer-equal/example/eq.js b/node_modules/nodeunit/node_modules/tap/node_modules/buffer-equal/example/eq.js new file mode 100644 index 0000000..1eb0509 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/buffer-equal/example/eq.js @@ -0,0 +1,14 @@ +var bufferEqual = require('../'); + +console.dir(bufferEqual( + new Buffer([253,254,255]), + new Buffer([253,254,255]) +)); +console.dir(bufferEqual( + new Buffer('abc'), + new Buffer('abcd') +)); +console.dir(bufferEqual( + new Buffer('abc'), + 'abc' +)); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/buffer-equal/index.js b/node_modules/nodeunit/node_modules/tap/node_modules/buffer-equal/index.js new file mode 100644 index 0000000..e640d4e --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/buffer-equal/index.js @@ -0,0 +1,14 @@ +var Buffer = require('buffer').Buffer; // for use with browserify + +module.exports = function (a, b) { + if (!Buffer.isBuffer(a)) return undefined; + if (!Buffer.isBuffer(b)) return undefined; + if (typeof a.equals === 'function') return a.equals(b); + if (a.length !== b.length) return false; + + for (var i = 0; i < a.length; i++) { + if (a[i] !== b[i]) return false; + } + + return true; +}; diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/buffer-equal/package.json b/node_modules/nodeunit/node_modules/tap/node_modules/buffer-equal/package.json new file mode 100644 index 0000000..98d49a6 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/buffer-equal/package.json @@ -0,0 +1,57 @@ +{ + "name": "buffer-equal", + "description": "return whether two buffers are equal", + "version": "0.0.1", + "repository": { + "type": "git", + "url": "git://github.com/substack/node-buffer-equal.git" + }, + "main": "index.js", + "keywords": [ + "buffer", + "equal" + ], + "directories": { + "example": "example", + "test": "test" + }, + "scripts": { + "test": "tap test/*.js" + }, + "devDependencies": { + "tap": "0.2.4" + }, + "engines": { + "node": ">=0.4.0" + }, + "license": "MIT", + "author": { + "name": "James Halliday", + "email": "mail@substack.net", + "url": "http://substack.net" + }, + "bugs": { + "url": "https://github.com/substack/node-buffer-equal/issues" + }, + "homepage": "https://github.com/substack/node-buffer-equal", + "_id": "buffer-equal@0.0.1", + "dist": { + "shasum": "91bc74b11ea405bc916bc6aa908faafa5b4aac4b", + "tarball": "http://registry.npmjs.org/buffer-equal/-/buffer-equal-0.0.1.tgz" + }, + "_from": "buffer-equal@~0.0.0", + "_npmVersion": "1.4.3", + "_npmUser": { + "name": "substack", + "email": "mail@substack.net" + }, + "maintainers": [ + { + "name": "substack", + "email": "mail@substack.net" + } + ], + "_shasum": "91bc74b11ea405bc916bc6aa908faafa5b4aac4b", + "_resolved": "https://registry.npmjs.org/buffer-equal/-/buffer-equal-0.0.1.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/buffer-equal/test/eq.js b/node_modules/nodeunit/node_modules/tap/node_modules/buffer-equal/test/eq.js new file mode 100644 index 0000000..3d34006 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/buffer-equal/test/eq.js @@ -0,0 +1,35 @@ +var bufferEqual = require('../'); +var test = require('tap').test; + +test('equal', function (t) { + var eq = bufferEqual( + new Buffer([253,254,255]), + new Buffer([253,254,255]) + ); + t.strictEqual(eq, true); + t.end(); +}); + +test('not equal', function (t) { + var eq = bufferEqual( + new Buffer('abc'), + new Buffer('abcd') + ); + t.strictEqual(eq, false); + t.end(); +}); + +test('not equal not buffer', function (t) { + var eq = bufferEqual( + new Buffer('abc'), + 'abc' + ); + t.strictEqual(eq, undefined); + t.end(); +}); + +test('equal not buffer', function (t) { + var eq = bufferEqual('abc', 'abc'); + t.strictEqual(eq, undefined); + t.end(); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/deep-equal/README.markdown b/node_modules/nodeunit/node_modules/tap/node_modules/deep-equal/README.markdown new file mode 100644 index 0000000..c3293d3 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/deep-equal/README.markdown @@ -0,0 +1,55 @@ +deep-equal +========== + +Node's `assert.deepEqual() algorithm` as a standalone module. + +example +======= + +``` js +var equal = require('deep-equal'); +console.dir([ + equal( + { a : [ 2, 3 ], b : [ 4 ] }, + { a : [ 2, 3 ], b : [ 4 ] } + ), + equal( + { x : 5, y : [6] }, + { x : 5, y : 6 } + ) +]); +``` + +methods +======= + +var deepEqual = require('deep-equal') + +deepEqual(a, b) +--------------- + +Compare objects `a` and `b`, returning whether they are equal according to a +recursive equality algorithm. + +install +======= + +With [npm](http://npmjs.org) do: + +``` +npm install deep-equal +``` + +test +==== + +With [npm](http://npmjs.org) do: + +``` +npm test +``` + +license +======= + +MIT. Derived largely from node's assert module. diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/deep-equal/example/cmp.js b/node_modules/nodeunit/node_modules/tap/node_modules/deep-equal/example/cmp.js new file mode 100644 index 0000000..67014b8 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/deep-equal/example/cmp.js @@ -0,0 +1,11 @@ +var equal = require('../'); +console.dir([ + equal( + { a : [ 2, 3 ], b : [ 4 ] }, + { a : [ 2, 3 ], b : [ 4 ] } + ), + equal( + { x : 5, y : [6] }, + { x : 5, y : 6 } + ) +]); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/deep-equal/index.js b/node_modules/nodeunit/node_modules/tap/node_modules/deep-equal/index.js new file mode 100644 index 0000000..e4e37be --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/deep-equal/index.js @@ -0,0 +1,84 @@ +var pSlice = Array.prototype.slice; +var Object_keys = typeof Object.keys === 'function' + ? Object.keys + : function (obj) { + var keys = []; + for (var key in obj) keys.push(key); + return keys; + } +; + +var deepEqual = module.exports = function (actual, expected) { + // 7.1. All identical values are equivalent, as determined by ===. + if (actual === expected) { + return true; + + } else if (actual instanceof Date && expected instanceof Date) { + return actual.getTime() === expected.getTime(); + + // 7.3. Other pairs that do not both pass typeof value == 'object', + // equivalence is determined by ==. + } else if (typeof actual != 'object' && typeof expected != 'object') { + return actual == expected; + + // 7.4. For all other Object pairs, including Array objects, equivalence is + // determined by having the same number of owned properties (as verified + // with Object.prototype.hasOwnProperty.call), the same set of keys + // (although not necessarily the same order), equivalent values for every + // corresponding key, and an identical 'prototype' property. Note: this + // accounts for both named and indexed properties on Arrays. + } else { + return objEquiv(actual, expected); + } +} + +function isUndefinedOrNull(value) { + return value === null || value === undefined; +} + +function isArguments(object) { + return Object.prototype.toString.call(object) == '[object Arguments]'; +} + +function objEquiv(a, b) { + if (isUndefinedOrNull(a) || isUndefinedOrNull(b)) + return false; + // an identical 'prototype' property. + if (a.prototype !== b.prototype) return false; + //~~~I've managed to break Object.keys through screwy arguments passing. + // Converting to array solves the problem. + if (isArguments(a)) { + if (!isArguments(b)) { + return false; + } + a = pSlice.call(a); + b = pSlice.call(b); + return deepEqual(a, b); + } + try { + var ka = Object_keys(a), + kb = Object_keys(b), + key, i; + } catch (e) {//happens when one is a string literal and the other isn't + return false; + } + // having the same number of owned properties (keys incorporates + // hasOwnProperty) + if (ka.length != kb.length) + return false; + //the same set of keys (although not necessarily the same order), + ka.sort(); + kb.sort(); + //~~~cheap key test + for (i = ka.length - 1; i >= 0; i--) { + if (ka[i] != kb[i]) + return false; + } + //equivalent values for every corresponding key, and + //~~~possibly expensive deep test + for (i = ka.length - 1; i >= 0; i--) { + key = ka[i]; + if (!deepEqual(a[key], b[key])) return false; + } + return true; +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/deep-equal/package.json b/node_modules/nodeunit/node_modules/tap/node_modules/deep-equal/package.json new file mode 100644 index 0000000..54974b5 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/deep-equal/package.json @@ -0,0 +1,66 @@ +{ + "name": "deep-equal", + "version": "0.0.0", + "description": "node's assert.deepEqual algorithm", + "main": "index.js", + "directories": { + "lib": ".", + "example": "example", + "test": "test" + }, + "scripts": { + "test": "tap test/*.js" + }, + "devDependencies": { + "tap": "0.0.x" + }, + "repository": { + "type": "git", + "url": "git://github.com/substack/node-deep-equal.git" + }, + "keywords": [ + "equality", + "equal", + "compare" + ], + "author": { + "name": "James Halliday", + "email": "mail@substack.net", + "url": "http://substack.net" + }, + "license": "MIT/X11", + "engine": { + "node": ">=0.4" + }, + "_npmUser": { + "name": "substack", + "email": "mail@substack.net" + }, + "_id": "deep-equal@0.0.0", + "dependencies": {}, + "engines": { + "node": "*" + }, + "_engineSupported": true, + "_npmVersion": "1.0.106", + "_nodeVersion": "v0.4.12", + "_defaultsLoaded": true, + "dist": { + "shasum": "99679d3bbd047156fcd450d3d01eeb9068691e83", + "tarball": "http://registry.npmjs.org/deep-equal/-/deep-equal-0.0.0.tgz" + }, + "maintainers": [ + { + "name": "substack", + "email": "mail@substack.net" + } + ], + "_shasum": "99679d3bbd047156fcd450d3d01eeb9068691e83", + "_from": "deep-equal@0.0.0", + "_resolved": "https://registry.npmjs.org/deep-equal/-/deep-equal-0.0.0.tgz", + "bugs": { + "url": "https://github.com/substack/node-deep-equal/issues" + }, + "readme": "ERROR: No README data found!", + "homepage": "https://github.com/substack/node-deep-equal" +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/deep-equal/test/cmp.js b/node_modules/nodeunit/node_modules/tap/node_modules/deep-equal/test/cmp.js new file mode 100644 index 0000000..8418f0f --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/deep-equal/test/cmp.js @@ -0,0 +1,18 @@ +var test = require('tap').test; +var equal = require('../'); + +test('equal', function (t) { + t.ok(equal( + { a : [ 2, 3 ], b : [ 4 ] }, + { a : [ 2, 3 ], b : [ 4 ] } + )); + t.end(); +}); + +test('not equal', function (t) { + t.notOk(equal( + { x : 5, y : [6] }, + { x : 5, y : 6 } + )); + t.end(); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/.travis.yml b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/.travis.yml new file mode 100644 index 0000000..09d3ef3 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/.travis.yml @@ -0,0 +1,4 @@ +language: node_js +node_js: + - 0.8 + - 0.10 diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/README.markdown b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/README.markdown new file mode 100644 index 0000000..9ad4303 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/README.markdown @@ -0,0 +1,116 @@ +difflet +======= + +Create colorful diffs for javascript objects. + +example +======= + +string.js +--------- + +``` js +var difflet = require('difflet'); + +var s = difflet.compare({ a : 2, c : 5 }, { a : 3, b : 4 }); +process.stdout.write(s); +``` + +output: + +![colorful output](http://substack.net/images/screenshots/difflet_string.png) + +colors.js +--------- + +``` js +var diff = require('difflet')({ indent : 2 }); + +var prev = { + yy : 6, + zz : 5, + a : [1,2,3], + fn : 'beep', + c : { x : 7, z : 3 } +}; + +var next = { + a : [ 1, 2, "z", /beep/, new Buffer(3) ], + fn : function qqq () {}, + b : [5,6,7], + c : { x : 8, y : 5 } +}; + +diff(prev, next).pipe(process.stdout); +``` + +output: + +![colorful output](http://substack.net/images/screenshots/difflet_colors.png) + +green for inserts, blue for updates, red for deletes + +methods +======= + +var difflet = require('difflet') + +var diff = difflet(opts={}) +--------------------------- + +Create a difflet from optional options `opts`. + +With `opts.start(type, stream)` and `opts.stop(type, stream)`, +you can write custom handlers for all the types of differences: +`'inserted'`, `'updated'`, and `'deleted'`. +By default green is used for insertions, blue for updates, and red for +deletions. + +If `opts.indent` is set, output will span multiple lines and `opts.indent` +spaces will be used for leading whitespace. + +If `opts.comma === 'first'` then commas will be placed at the start of lines. + +Setting `opts.comment` to `true` will turn on comments with the previous +contents like this: + +![object comments](http://substack.net/images/screenshots/difflet_object_comments.png) + +diff(prev, next) +---------------- + +Return a stream with the colorful changes between objects `prev` and `next`. + +diff.compare(prev, next) +------------------------ + +Return a string with the colorful changes between `prev` and `next`. + +difflet.compare(prev, next) +--------------------------- + +Return a string with the colorful changes between `prev` and `next` with the +default options. + +install +======= + +With [npm](http://npmjs.org) do: + +``` +npm install difflet +``` + +test +==== + +With [npm](http://npmjs.org) do: + +``` +npm test +``` + +license +======= + +MIT/X11 diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/example/cmp_array.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/example/cmp_array.js new file mode 100644 index 0000000..bc5733f --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/example/cmp_array.js @@ -0,0 +1,6 @@ +var difflet = require('../'); +var s = difflet({ indent : 2, comment : true }).compare( + [ 1, [2,3,{a:4}], 3 ], + [ 1, [[5],6,7], 4 ] +); +process.stdout.write(s); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/example/cmp_object.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/example/cmp_object.js new file mode 100644 index 0000000..5e00e2c --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/example/cmp_object.js @@ -0,0 +1,6 @@ +var difflet = require('../'); +var s = difflet({ indent : 2, comment : true }).compare( + { z : [6,7], a : 'abcdefgh', b : [ 31, 'xxt' ] }, + { x : 5, a : 'abdcefg', b : [ 51, 'xxs' ] } +); +console.log(s); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/example/colors.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/example/colors.js new file mode 100644 index 0000000..332bbae --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/example/colors.js @@ -0,0 +1,18 @@ +var diff = require('../')({ indent : 2 }); + +var prev = { + yy : 6, + zz : 5, + a : [1,2,3], + fn : 'beep', + c : { x : 7, z : 3 } +}; + +var next = { + a : [ 1, 2, "z", /beep/, new Buffer(3) ], + fn : function qqq () {}, + b : [5,6,7], + c : { x : 8, y : 5 } +}; + +diff(prev, next).pipe(process.stdout); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/example/comma_first.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/example/comma_first.js new file mode 100644 index 0000000..67ece23 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/example/comma_first.js @@ -0,0 +1,12 @@ +var diff = require('../')({ + indent : 2, + comma : 'first', +}); + +var prev = { yy : 6, zz : 5, a : [1,2,3] }; +var next = { + a : [ 1, 2, 3, [4], "z", /beep/, new Buffer(3) ], + fn : 8, + b : [5,6,7] +}; +diff(prev, next).pipe(process.stdout); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/example/diff.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/example/diff.js new file mode 100644 index 0000000..08f6e7a --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/example/diff.js @@ -0,0 +1,15 @@ +var difflet = require('../'); +var a = { + x : 4, + z : 8, + xs : [ 5, 2, 1, { 0 : 'c' } ], +}; + +var b = { + x : 4, + y : 5, + xs : [ 5, 2, 2, { c : 5 } ], +}; + +var s = difflet({ comment : true, indent : 2 }).compare(a, b); +console.log(s); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/example/html.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/example/html.js new file mode 100644 index 0000000..9ff4a29 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/example/html.js @@ -0,0 +1,34 @@ +var difflet = require('../'); +var ent = require('ent'); + +var tags = { + inserted : '', + updated : '', + deleted : '', +}; +var diff = difflet({ + start : function (t, s) { + s.write(tags[t]); + }, + stop : function (t, s) { + s.write(''); + }, + write : function (buf) { + stream.write(ent.encode(buf)) + }, +}); + +var prev = { + yy : 6, + zz : 5, + a : [1,2,3], + fn : function qq () {} +}; +var next = { + a : [ 1, 2, 3, [4], "z", /beep/, new Buffer([0,1,2]) ], + fn : 'I <3 robots', + b : [5,6,7] +}; + +var stream = diff(prev, next); +stream.pipe(process.stdout, { end : false }); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/example/string.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/example/string.js new file mode 100644 index 0000000..6cff6cb --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/example/string.js @@ -0,0 +1,4 @@ +var difflet = require('../'); + +var s = difflet.compare({ a : 2, c : 5 }, { a : 3, b : 4 }); +process.stdout.write(s); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/index.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/index.js new file mode 100644 index 0000000..278e6b9 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/index.js @@ -0,0 +1,377 @@ +var traverse = require('traverse'); +var Stream = require('stream').Stream; +var charm = require('charm'); +var deepEqual = require('deep-is'); + +var exports = module.exports = function (opts_) { + var fn = difflet.bind(null, opts_); + fn.compare = function (prev, next) { + var opts = Object.keys(opts_ || {}).reduce(function (acc, key) { + acc[key] = opts_[key]; + return acc; + }, {}); + var s = opts.stream = new Stream; + var data = ''; + s.write = function (buf) { data += buf }; + s.end = function () {}; + s.readable = true; + s.writable = true; + + difflet(opts, prev, next); + return data; + }; + return fn; +}; + +exports.compare = function (prev, next) { + return exports({}).compare(prev, next); +}; + +function difflet (opts, prev, next) { + var stream = opts.stream || new Stream; + if (!opts.stream) { + stream.readable = true; + stream.writable = true; + stream.write = function (buf) { this.emit('data', buf) }; + stream.end = function () { this.emit('end') }; + } + + if (!opts) opts = {}; + if (opts.start === undefined && opts.stop === undefined) { + var c = charm(stream); + opts.start = function (type) { + c.foreground({ + inserted : 'green', + updated : 'blue', + deleted : 'red', + comment : 'cyan', + }[type]); + c.display('bright'); + }; + opts.stop = function (type) { + c.display('reset'); + }; + } + var write = function (buf) { + if (opts.write) opts.write(buf, stream) + else stream.write(buf) + }; + + var commaFirst = opts.comma === 'first'; + + var stringify = function (node, params) { + return stringifier.call(this, true, node, params || opts); + }; + var plainStringify = function (node, params) { + return stringifier.call(this, false, node, params || opts); + }; + + var levels = 0; + function set (type) { + if (levels === 0) opts.start(type, stream); + levels ++; + } + + function unset (type) { + if (--levels === 0) opts.stop(type, stream); + } + + function stringifier (insertable, node, opts) { + var indent = opts.indent; + + if (insertable) { + var prevNode = traverse.get(prev, this.path || []); + } + var inserted = insertable && prevNode === undefined; + + var indentx; + try { + indentx = indent ? Array( + ((this.path || []).length + 1) * indent + 1 + ).join(' ') : ''; + } catch (e) { + // at times we get an invalid Array size here and need to prevent crashing + indentx = ''; + } + if (commaFirst) indentx = indentx.slice(indent); + + if (Array.isArray(node)) { + var updated = (prevNode || traverse.has(prev, this.path)) + && !Array.isArray(prevNode); + if (updated) { + set('updated'); + } + + if (opts.comment && !Array.isArray(prevNode)) { + indent = 0; + } + + this.before(function () { + if (inserted) set('inserted'); + if (indent && commaFirst) { + if ((this.path || []).length === 0 + || Array.isArray(this.parent.node)) { + write('[ '); + } + else write('\n' + indentx + '[ '); + } + else if (indent) { + write('[\n' + indentx); + } + else { + write('['); + } + }); + + this.post(function (child) { + if (!child.isLast && !(indent && commaFirst)) { + write(','); + } + + var prev = prevNode && prevNode[child.key]; + if (indent && opts.comment && child.node !== prev + && (typeof child.node !== 'object' || typeof prev !== 'object') + ) { + set('comment'); + write(' // != '); + traverse(prev).forEach(function (x) { + plainStringify.call(this, x, { indent : 0 }); + }); + unset('comment'); + } + + if (!child.isLast) { + if (indent && commaFirst) { + write('\n' + indentx + ', '); + } + else if (indent) { + write('\n' + indentx); + } + } + }); + + this.after(function () { + if (indent && commaFirst) write('\n' + indentx); + else if (indent) write('\n' + indentx.slice(indent)); + + write(']'); + if (updated) unset('updated'); + if (inserted) unset('inserted'); + }); + } + else if (isRegExp(node)) { + this.block(); + + if (inserted) { + set('inserted'); + write(node.toString()); + unset('inserted'); + } + else if (insertable && prevNode !== node) { + set('updated'); + write(node.toString()); + unset('updated'); + } + else write(node.toString()); + } + else if (typeof node === 'object' + && node && typeof node.inspect === 'function') { + this.block(); + if (inserted) { + set('inserted'); + write(node.inspect()); + unset('inserted'); + } + else if (!(prevNode && typeof prevNode.inspect === 'function' + && prevNode.inspect() === node.inspect())) { + set('updated'); + write(node.inspect()); + unset('updated'); + } + else write(node.inspect()); + } + else if (typeof node == 'object' && node !== null) { + var insertedKey = false; + var deleted = insertable && typeof prevNode === 'object' && prevNode + ? Object.keys(prevNode).filter(function (key) { + return !Object.hasOwnProperty.call(node, key); + }) + : [] + ; + + this.before(function () { + if (inserted) set('inserted'); + write(indent && commaFirst && !this.isRoot + ? '\n' + indentx + '{ ' + : '{' + ); + }); + + this.pre(function (x, key) { + if (insertable) { + var obj = traverse.get(prev, this.path.concat(key)); + if (obj === undefined) { + insertedKey = true; + set('inserted'); + } + } + + if (indent && !commaFirst) write('\n' + indentx); + + plainStringify(key); + write(indent ? ' : ' : ':'); + }); + + this.post(function (child) { + if (!child.isLast && !(indent && commaFirst)) { + write(','); + } + + if (child.isLast && deleted.length) { + if (insertedKey) unset('inserted'); + insertedKey = false; + } + else if (insertedKey) { + unset('inserted'); + insertedKey = false; + } + + var prev = prevNode && prevNode[child.key]; + if (indent && opts.comment && child.node !== prev + && (typeof child.node !== 'object' || typeof prev !== 'object') + ) { + set('comment'); + write(' // != '); + traverse(prev).forEach(function (x) { + plainStringify.call(this, x, { indent : 0 }); + }); + unset('comment'); + } + + if (child.isLast && deleted.length) { + if (insertedKey) unset('inserted'); + insertedKey = false; + + if (indent && commaFirst) { + write('\n' + indentx + ', ') + } + else if (opts.comment && indent) { + write('\n' + indentx); + } + else if (indent) { + write(',\n' + indentx); + } + else write(','); + } + else { + if (!child.isLast) { + if (indent && commaFirst) { + write('\n' + indentx + ', '); + } + } + } + }); + + this.after(function () { + if (inserted) unset('inserted'); + + if (deleted.length) { + if (indent && !commaFirst + && Object.keys(node).length === 0) { + write('\n' + indentx); + } + + set('deleted'); + deleted.forEach(function (key, ix) { + if (indent && opts.comment) { + unset('deleted'); + set('comment'); + write('// '); + unset('comment'); + set('deleted'); + } + + plainStringify(key); + write(indent ? ' : ' : ':'); + traverse(prevNode[key]).forEach(function (x) { + plainStringify.call(this, x, { indent : 0 }); + }); + + var last = ix === deleted.length - 1; + if (insertable && !last) { + if (indent && commaFirst) { + write('\n' + indentx + ', '); + } + else if (indent) { + write(',\n' + indentx); + } + else write(','); + } + }); + unset('deleted'); + } + + if (commaFirst && indent) { + write(indentx.slice(indent) + ' }'); + } + else if (indent) { + write('\n' + indentx.slice(indent) + '}'); + } + else write('}'); + }); + } + else { + var changed = false; + + if (inserted) set('inserted'); + else if (insertable && !deepEqual(prevNode, node)) { + changed = true; + set('updated'); + } + + if (typeof node === 'string') { + write('"' + node.toString().replace(/"/g, '\\"') + '"'); + } + else if (isRegExp(node)) { + write(node.toString()); + } + else if (typeof node === 'function') { + write(node.name + ? '[Function: ' + node.name + ']' + : '[Function]' + ); + } + else if (node === undefined) { + write('undefined'); + } + else if (node === null) { + write('null'); + } + else { + write(node.toString()); + } + + if (inserted) unset('inserted'); + else if (changed) unset('updated'); + } + } + + if (opts.stream) { + traverse(next).forEach(stringify); + } + else process.nextTick(function () { + traverse(next).forEach(stringify); + stream.emit('end'); + }); + + return stream; +} + +function isRegExp (node) { + return node instanceof RegExp || (node + && typeof node.test === 'function' + && typeof node.exec === 'function' + && typeof node.compile === 'function' + && node.constructor && node.constructor.name === 'RegExp' + ); +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/README.markdown b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/README.markdown new file mode 100644 index 0000000..a0648ff --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/README.markdown @@ -0,0 +1,216 @@ +charm +===== + +Use +[ansi terminal characters](http://www.termsys.demon.co.uk/vtansi.htm) +to write colors and cursor positions. + +![me lucky charms](http://substack.net/images/charms.png) + +example +======= + +lucky +----- + +````javascript +var charm = require('charm')(); +charm.pipe(process.stdout); +charm.reset(); + +var colors = [ 'red', 'cyan', 'yellow', 'green', 'blue' ]; +var text = 'Always after me lucky charms.'; + +var offset = 0; +var iv = setInterval(function () { + var y = 0, dy = 1; + for (var i = 0; i < 40; i++) { + var color = colors[(i + offset) % colors.length]; + var c = text[(i + offset) % text.length]; + charm + .move(1, dy) + .foreground(color) + .write(c) + ; + y += dy; + if (y <= 0 || y >= 5) dy *= -1; + } + charm.position(0, 1); + offset ++; +}, 150); +```` + +events +====== + +Charm objects pass along the data events from their input stream except for +events generated from querying the terminal device. + +Because charm puts stdin into raw mode, charm emits two special events: "^C" and +"^D" when the user types those combos. It's super convenient with these events +to do: + +````javascript +charm.on('^C', process.exit) +```` + +The above is set on all `charm` streams. If you want to add your own handling for these +special events simply: + +````javascript +charm.removeAllListeners('^C') +charm.on('^C', function () { + // Don't exit. Do some mad science instead. +}) +```` + +methods +======= + +var charm = require('charm')(param or stream, ...) +-------------------------------------------------- + +Create a new readable/writable `charm` stream. + +You can pass in readable or writable streams as parameters and they will be +piped to or from accordingly. You can also pass `process` in which case +`process.stdin` and `process.stdout` will be used. + +You can `pipe()` to and from the `charm` object you get back. + +charm.reset() +------------- + +Reset the entire screen, like the /usr/bin/reset command. + +charm.destroy(), charm.end() +---------------------------- + +Emit an `"end"` event downstream. + +charm.write(msg) +---------------- + +Pass along `msg` to the output stream. + +charm.position(x, y) +-------------------- + +Set the cursor position to the absolute coordinates `x, y`. + +charm.position(cb) +------------------ + +Query the absolute cursor position from the input stream through the output +stream (the shell does this automatically) and get the response back as +`cb(x, y)`. + +charm.move(x, y) +---------------- + +Move the cursor position by the relative coordinates `x, y`. + +charm.up(y) +----------- + +Move the cursor up by `y` rows. + +charm.down(y) +------------- + +Move the cursor down by `y` rows. + +charm.left(x) +------------- + +Move the cursor left by `x` columns. + +charm.right(x) +-------------- + +Move the cursor right by `x` columns. + +charm.push(withAttributes=false) +-------------------------------- + +Push the cursor state and optionally the attribute state. + +charm.pop(withAttributes=false) +------------------------------- + +Pop the cursor state and optionally the attribute state. + +charm.erase(s) +-------------- + +Erase a region defined by the string `s`. + +`s` can be: + +* end - erase from the cursor to the end of the line +* start - erase from the cursor to the start of the line +* line - erase the current line +* down - erase everything below the current line +* up - erase everything above the current line +* screen - erase the entire screen + +charm.display(attr) +------------------- + +Set the display mode with the string `attr`. + +`attr` can be: + +* reset +* bright +* dim +* underscore +* blink +* reverse +* hidden + +charm.foreground(color) +----------------------- + +Set the foreground color with the string `color`, which can be: + +* red +* yellow +* green +* blue +* cyan +* magenta +* black +* white + +or `color` can be an integer from 0 to 255, inclusive. + +charm.background(color) +----------------------- + +Set the background color with the string `color`, which can be: + +* red +* yellow +* green +* blue +* cyan +* magenta +* black +* white + +or `color` can be an integer from 0 to 255, inclusive. + +charm.cursor(visible) +--------------------- + +Set the cursor visibility with a boolean `visible`. + +install +======= + +With [npm](http://npmjs.org) do: + +``` +npm install charm +``` diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/example/256.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/example/256.js new file mode 100644 index 0000000..6851386 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/example/256.js @@ -0,0 +1,17 @@ +var charm = require('../')(process); + +function exit () { + charm.display('reset'); + process.exit(); +} +charm.on('^C', exit); + +var ix = 0; +var iv = setInterval(function () { + charm.background(ix++).write(' '); + if (ix === 256) { + clearInterval(iv); + charm.write('\n'); + exit(); + } +}, 10); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/example/column.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/example/column.js new file mode 100644 index 0000000..2647e71 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/example/column.js @@ -0,0 +1,11 @@ +var charm = require('../')(); +charm.pipe(process.stdout); + +charm + .column(16) + .write('beep') + .down() + .column(32) + .write('boop\n') + .end() +; diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/example/cursor.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/example/cursor.js new file mode 100644 index 0000000..0c565b0 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/example/cursor.js @@ -0,0 +1,22 @@ +var charm = require('../')(process); + +charm.position(5, 10); + +charm.position(function (x, y) { + console.dir([ x, y ]); + + charm.move(7,2); + charm.push(); + process.stdout.write('lul'); + + charm.left(3).up(1).foreground('magenta'); + process.stdout.write('v'); + charm.left(1).up(1).display('reset'); + process.stdout.write('|'); + + charm.down(3); + charm.pop().background('blue'); + process.stdout.write('popped\npow'); + charm.display('reset').erase('line'); + charm.destroy(); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/example/http_spin.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/example/http_spin.js new file mode 100644 index 0000000..727e3e8 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/example/http_spin.js @@ -0,0 +1,36 @@ +var http = require('http'); +var charmer = require('../'); + +http.createServer(function (req, res) { + res.setHeader('content-type', 'text/ansi'); + + var charm = charmer(); + charm.pipe(res); + charm.reset(); + + var radius = 10; + var theta = 0; + var points = []; + + var iv = setInterval(function () { + var x = 2 + (radius + Math.cos(theta) * radius) * 2; + var y = 2 + radius + Math.sin(theta) * radius; + + points.unshift([ x, y ]); + var colors = [ 'red', 'yellow', 'green', 'cyan', 'blue', 'magenta' ]; + + points.forEach(function (p, i) { + charm.position(p[0], p[1]); + var c = colors[Math.floor(i / 12)]; + charm.background(c).write(' ') + }); + points = points.slice(0, 12 * colors.length - 1); + + theta += Math.PI / 40; + }, 50); + + req.connection.on('end', function () { + clearInterval(iv); + charm.end(); + }); +}).listen(8081); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/example/lucky.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/example/lucky.js new file mode 100644 index 0000000..01fe801 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/example/lucky.js @@ -0,0 +1,24 @@ +var charm = require('../')(); +charm.pipe(process.stdout); +charm.reset(); + +var colors = [ 'red', 'cyan', 'yellow', 'green', 'blue' ]; +var text = 'Always after me lucky charms.'; + +var offset = 0; +var iv = setInterval(function () { + var y = 0, dy = 1; + for (var i = 0; i < 40; i++) { + var color = colors[(i + offset) % colors.length]; + var c = text[(i + offset) % text.length]; + charm + .move(1, dy) + .foreground(color) + .write(c) + ; + y += dy; + if (y <= 0 || y >= 5) dy *= -1; + } + charm.position(0, 1); + offset ++; +}, 150); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/example/position.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/example/position.js new file mode 100644 index 0000000..2c5ae9b --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/example/position.js @@ -0,0 +1,7 @@ +var charm = require('charm')(process); + +charm.on('^C', process.exit); + +charm.position(function (x, y) { + console.log('(%d, %d)', x, y); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/example/progress.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/example/progress.js new file mode 100644 index 0000000..9da3c13 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/example/progress.js @@ -0,0 +1,18 @@ +var charm = require('../')(); +charm.pipe(process.stdout); + +charm.write('Progress: 0 %'); +var i = 0; + +var iv = setInterval(function () { + charm.left(i.toString().length + 2); + i ++; + charm.write(i + ' %'); + if (i === 100) { + charm.end('\nDone!\n'); + clearInterval(iv); + } +}, 25); + +charm.on('^C',process.exit); + diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/example/resize.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/example/resize.js new file mode 100644 index 0000000..bda80b6 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/example/resize.js @@ -0,0 +1,62 @@ +var c = require('../')(); +c.pipe(process.stdout); +c.on('^C', process.exit); + +var queue = (function () { + var tasks = []; + var pending = false; + + return { + abort : function () { + tasks = []; + next(); + }, + push : function (t) { + tasks.push(t); + if (!pending) next(); + } + }; + + function next () { + pending = true; + process.nextTick(function () { + if (tasks.length === 0) return; + var t = tasks.shift(); + t(); + pending = false; + next(); + }); + } +})(); + +process.stdout.on('resize', draw); +draw(); +setInterval(function () {}, 1e8); + +function draw () { + var cols = process.stdout.columns; + var rows = process.stdout.rows; + queue.abort(); + + queue.push(function () { + c.reset(); + c.background('blue'); + c.position(1, 1); + c.write(Array(cols + 1).join(' ')); + }); + + for (var y = 1; y < rows; y++) { + queue.push(function () { + c.position(1, y); + c.write(' '); + c.position(cols, y); + c.write(' '); + }); + } + + queue.push(function () { + c.position(1, rows); + c.write(Array(cols + 1).join(' ')); + c.display('reset'); + }); +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/example/spin.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/example/spin.js new file mode 100644 index 0000000..fd3e23a --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/example/spin.js @@ -0,0 +1,23 @@ +var charm = require('../')(process); +charm.reset(); + +var radius = 10; +var theta = 0; +var points = []; + +var iv = setInterval(function () { + var x = 2 + (radius + Math.cos(theta) * radius) * 2; + var y = 2 + radius + Math.sin(theta) * radius; + + points.unshift([ x, y ]); + var colors = [ 'red', 'yellow', 'green', 'cyan', 'blue', 'magenta' ]; + + points.forEach(function (p, i) { + charm.position(p[0], p[1]); + var c = colors[Math.floor(i / 12)]; + charm.background(c).write(' ') + }); + points = points.slice(0, 12 * colors.length - 1); + + theta += Math.PI / 40; +}, 50); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/index.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/index.js new file mode 100644 index 0000000..e1e7bdc --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/index.js @@ -0,0 +1,305 @@ +var tty = require('tty'); +var encode = require('./lib/encode'); +var Stream = require('stream').Stream; + +var exports = module.exports = function () { + var input = null; + function setInput (s) { + if (input) throw new Error('multiple inputs specified') + else input = s + } + + var output = null; + function setOutput (s) { + if (output) throw new Error('multiple outputs specified') + else output = s + } + + for (var i = 0; i < arguments.length; i++) { + var arg = arguments[i]; + if (!arg) continue; + if (arg.readable) setInput(arg) + else if (arg.stdin || arg.input) setInput(arg.stdin || arg.input) + + if (arg.writable) setOutput(arg) + else if (arg.stdout || arg.output) setOutput(arg.stdout || arg.output) + + } + + if (input && typeof input.fd === 'number' && tty.isatty(input.fd)) { + if (process.stdin.setRawMode) { + process.stdin.setRawMode(true); + } + else tty.setRawMode(true); + } + + var charm = new Charm; + if (input) { + input.pipe(charm); + } + + if (output) { + charm.pipe(output); + } + + charm.once('^C', process.exit); + charm.once('end', function () { + if (input) { + if (typeof input.fd === 'number' && tty.isatty(input.fd)) { + if (process.stdin.setRawMode) { + process.stdin.setRawMode(false); + } + else tty.setRawMode(false); + } + input.destroy(); + } + }); + + return charm; +}; + +var Charm = exports.Charm = function Charm () { + this.writable = true; + this.readable = true; + this.pending = []; +} + +Charm.prototype = new Stream; + +Charm.prototype.write = function (buf) { + var self = this; + + if (self.pending.length) { + var codes = extractCodes(buf); + var matched = false; + + for (var i = 0; i < codes.length; i++) { + for (var j = 0; j < self.pending.length; j++) { + var cb = self.pending[j]; + if (cb(codes[i])) { + matched = true; + self.pending.splice(j, 1); + break; + } + } + } + + if (matched) return; + } + + if (buf.length === 1) { + if (buf[0] === 3) self.emit('^C'); + if (buf[0] === 4) self.emit('^D'); + } + + self.emit('data', buf); + + return self; +}; + + +Charm.prototype.destroy = function () { + this.end(); +}; + +Charm.prototype.end = function (buf) { + if (buf) this.write(buf); + this.emit('end'); +}; + +Charm.prototype.reset = function (cb) { + this.write(encode('c')); + return this; +}; + +Charm.prototype.position = function (x, y) { + // get/set absolute coordinates + if (typeof x === 'function') { + var cb = x; + this.pending.push(function (buf) { + if (buf[0] === 27 && buf[1] === encode.ord('[') + && buf[buf.length-1] === encode.ord('R')) { + var pos = buf.toString() + .slice(2,-1) + .split(';') + .map(Number) + ; + cb(pos[1], pos[0]); + return true; + } + }); + this.write(encode('[6n')); + } + else { + this.write(encode( + '[' + Math.floor(y) + ';' + Math.floor(x) + 'f' + )); + } + return this; +}; + +Charm.prototype.move = function (x, y) { + // set relative coordinates + var bufs = []; + + if (y < 0) this.up(-y) + else if (y > 0) this.down(y) + + if (x > 0) this.right(x) + else if (x < 0) this.left(-x) + + return this; +}; + +Charm.prototype.up = function (y) { + if (y === undefined) y = 1; + this.write(encode('[' + Math.floor(y) + 'A')); + return this; +}; + +Charm.prototype.down = function (y) { + if (y === undefined) y = 1; + this.write(encode('[' + Math.floor(y) + 'B')); + return this; +}; + +Charm.prototype.right = function (x) { + if (x === undefined) x = 1; + this.write(encode('[' + Math.floor(x) + 'C')); + return this; +}; + +Charm.prototype.left = function (x) { + if (x === undefined) x = 1; + this.write(encode('[' + Math.floor(x) + 'D')); + return this; +}; + +Charm.prototype.column = function (x) { + this.write(encode('[' + Math.floor(x) + 'G')); + return this; +}; + +Charm.prototype.push = function (withAttributes) { + this.write(encode(withAttributes ? '7' : '[s')); + return this; +}; + +Charm.prototype.pop = function (withAttributes) { + this.write(encode(withAttributes ? '8' : '[u')); + return this; +}; + +Charm.prototype.erase = function (s) { + if (s === 'end' || s === '$') { + this.write(encode('[K')); + } + else if (s === 'start' || s === '^') { + this.write(encode('[1K')); + } + else if (s === 'line') { + this.write(encode('[2K')); + } + else if (s === 'down') { + this.write(encode('[J')); + } + else if (s === 'up') { + this.write(encode('[1J')); + } + else if (s === 'screen') { + this.write(encode('[1J')); + } + else { + this.emit('error', new Error('Unknown erase type: ' + s)); + } + return this; +}; + +Charm.prototype.display = function (attr) { + var c = { + reset : 0, + bright : 1, + dim : 2, + underscore : 4, + blink : 5, + reverse : 7, + hidden : 8 + }[attr]; + if (c === undefined) { + this.emit('error', new Error('Unknown attribute: ' + attr)); + } + this.write(encode('[' + c + 'm')); + return this; +}; + +Charm.prototype.foreground = function (color) { + if (typeof color === 'number') { + if (color < 0 || color >= 256) { + this.emit('error', new Error('Color out of range: ' + color)); + } + this.write(encode('[38;5;' + color + 'm')); + } + else { + var c = { + black : 30, + red : 31, + green : 32, + yellow : 33, + blue : 34, + magenta : 35, + cyan : 36, + white : 37 + }[color.toLowerCase()]; + + if (!c) this.emit('error', new Error('Unknown color: ' + color)); + this.write(encode('[' + c + 'm')); + } + return this; +}; + +Charm.prototype.background = function (color) { + if (typeof color === 'number') { + if (color < 0 || color >= 256) { + this.emit('error', new Error('Color out of range: ' + color)); + } + this.write(encode('[48;5;' + color + 'm')); + } + else { + var c = { + black : 40, + red : 41, + green : 42, + yellow : 43, + blue : 44, + magenta : 45, + cyan : 46, + white : 47 + }[color.toLowerCase()]; + + if (!c) this.emit('error', new Error('Unknown color: ' + color)); + this.write(encode('[' + c + 'm')); + } + return this; +}; + +Charm.prototype.cursor = function (visible) { + this.write(encode(visible ? '[?25h' : '[?25l')); + return this; +}; + +var extractCodes = exports.extractCodes = function (buf) { + var codes = []; + var start = -1; + + for (var i = 0; i < buf.length; i++) { + if (buf[i] === 27) { + if (start >= 0) codes.push(buf.slice(start, i)); + start = i; + } + else if (start >= 0 && i === buf.length - 1) { + codes.push(buf.slice(start)); + } + } + + return codes; +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/lib/encode.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/lib/encode.js new file mode 100644 index 0000000..3b6417a --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/lib/encode.js @@ -0,0 +1,18 @@ +var encode = module.exports = function (xs) { + function bytes (s) { + if (typeof s === 'string') { + return s.split('').map(ord); + } + else if (Array.isArray(s)) { + return s.reduce(function (acc, c) { + return acc.concat(bytes(c)); + }, []); + } + } + + return new Buffer([ 0x1b ].concat(bytes(xs))); +}; + +var ord = encode.ord = function ord (c) { + return c.charCodeAt(0) +}; diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/package.json b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/package.json new file mode 100644 index 0000000..d6612ac --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm/package.json @@ -0,0 +1,58 @@ +{ + "name": "charm", + "version": "0.1.2", + "description": "ansi control sequences for terminal cursor hopping and colors", + "main": "index.js", + "directories": { + "lib": ".", + "example": "example", + "test": "test" + }, + "repository": { + "type": "git", + "url": "http://github.com/substack/node-charm.git" + }, + "keywords": [ + "terminal", + "ansi", + "cursor", + "color", + "console", + "control", + "escape", + "sequence" + ], + "author": { + "name": "James Halliday", + "email": "mail@substack.net", + "url": "http://substack.net" + }, + "license": "MIT/X11", + "engine": { + "node": ">=0.4" + }, + "_id": "charm@0.1.2", + "dist": { + "shasum": "06c21eed1a1b06aeb67553cdc53e23274bac2296", + "tarball": "http://registry.npmjs.org/charm/-/charm-0.1.2.tgz" + }, + "_from": "charm@0.1.2", + "_npmVersion": "1.2.2", + "_npmUser": { + "name": "substack", + "email": "mail@substack.net" + }, + "maintainers": [ + { + "name": "substack", + "email": "mail@substack.net" + } + ], + "_shasum": "06c21eed1a1b06aeb67553cdc53e23274bac2296", + "_resolved": "https://registry.npmjs.org/charm/-/charm-0.1.2.tgz", + "bugs": { + "url": "https://github.com/substack/node-charm/issues" + }, + "readme": "ERROR: No README data found!", + "homepage": "https://github.com/substack/node-charm" +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/deep-is/.npmignore b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/deep-is/.npmignore new file mode 100644 index 0000000..3c3629e --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/deep-is/.npmignore @@ -0,0 +1 @@ +node_modules diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/deep-is/.travis.yml b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/deep-is/.travis.yml new file mode 100644 index 0000000..d523c5f --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/deep-is/.travis.yml @@ -0,0 +1,6 @@ +language: node_js +node_js: + - 0.4 + - 0.6 + - 0.8 + - 0.10 diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/deep-is/LICENSE b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/deep-is/LICENSE new file mode 100644 index 0000000..c38f840 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/deep-is/LICENSE @@ -0,0 +1,22 @@ +Copyright (c) 2012, 2013 Thorsten Lorenz +Copyright (c) 2012 James Halliday +Copyright (c) 2009 Thomas Robinson <280north.com> + +This software is released under the MIT license: + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/deep-is/README.markdown b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/deep-is/README.markdown new file mode 100644 index 0000000..eb69a83 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/deep-is/README.markdown @@ -0,0 +1,70 @@ +deep-is +========== + +Node's `assert.deepEqual() algorithm` as a standalone module. Exactly like +[deep-equal](https://github.com/substack/node-deep-equal) except for the fact that `deepEqual(NaN, NaN) === true`. + +This module is around [5 times faster](https://gist.github.com/2790507) +than wrapping `assert.deepEqual()` in a `try/catch`. + +[![browser support](http://ci.testling.com/thlorenz/deep-is.png)](http://ci.testling.com/thlorenz/deep-is) + +[![build status](https://secure.travis-ci.org/thlorenz/deep-is.png)](http://travis-ci.org/thlorenz/deep-is) + +example +======= + +``` js +var equal = require('deep-is'); +console.dir([ + equal( + { a : [ 2, 3 ], b : [ 4 ] }, + { a : [ 2, 3 ], b : [ 4 ] } + ), + equal( + { x : 5, y : [6] }, + { x : 5, y : 6 } + ) +]); +``` + +methods +======= + +var deepIs = require('deep-is') + +deepIs(a, b) +--------------- + +Compare objects `a` and `b`, returning whether they are equal according to a +recursive equality algorithm. + +install +======= + +With [npm](http://npmjs.org) do: + +``` +npm install deep-is +``` + +test +==== + +With [npm](http://npmjs.org) do: + +``` +npm test +``` + +license +======= + +Copyright (c) 2012, 2013 Thorsten Lorenz +Copyright (c) 2012 James Halliday + +Derived largely from node's assert module, which has the copyright statement: + +Copyright (c) 2009 Thomas Robinson <280north.com> + +Released under the MIT license, see LICENSE for details. diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/deep-is/example/cmp.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/deep-is/example/cmp.js new file mode 100644 index 0000000..67014b8 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/deep-is/example/cmp.js @@ -0,0 +1,11 @@ +var equal = require('../'); +console.dir([ + equal( + { a : [ 2, 3 ], b : [ 4 ] }, + { a : [ 2, 3 ], b : [ 4 ] } + ), + equal( + { x : 5, y : [6] }, + { x : 5, y : 6 } + ) +]); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/deep-is/index.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/deep-is/index.js new file mode 100644 index 0000000..506fe27 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/deep-is/index.js @@ -0,0 +1,102 @@ +var pSlice = Array.prototype.slice; +var Object_keys = typeof Object.keys === 'function' + ? Object.keys + : function (obj) { + var keys = []; + for (var key in obj) keys.push(key); + return keys; + } +; + +var deepEqual = module.exports = function (actual, expected) { + // enforce Object.is +0 !== -0 + if (actual === 0 && expected === 0) { + return areZerosEqual(actual, expected); + + // 7.1. All identical values are equivalent, as determined by ===. + } else if (actual === expected) { + return true; + + } else if (actual instanceof Date && expected instanceof Date) { + return actual.getTime() === expected.getTime(); + + } else if (isNumberNaN(actual)) { + return isNumberNaN(expected); + + // 7.3. Other pairs that do not both pass typeof value == 'object', + // equivalence is determined by ==. + } else if (typeof actual != 'object' && typeof expected != 'object') { + return actual == expected; + + // 7.4. For all other Object pairs, including Array objects, equivalence is + // determined by having the same number of owned properties (as verified + // with Object.prototype.hasOwnProperty.call), the same set of keys + // (although not necessarily the same order), equivalent values for every + // corresponding key, and an identical 'prototype' property. Note: this + // accounts for both named and indexed properties on Arrays. + } else { + return objEquiv(actual, expected); + } +}; + +function isUndefinedOrNull(value) { + return value === null || value === undefined; +} + +function isArguments(object) { + return Object.prototype.toString.call(object) == '[object Arguments]'; +} + +function isNumberNaN(value) { + // NaN === NaN -> false + return typeof value == 'number' && value !== value; +} + +function areZerosEqual(zeroA, zeroB) { + // (1 / +0|0) -> Infinity, but (1 / -0) -> -Infinity and (Infinity !== -Infinity) + return (1 / zeroA) === (1 / zeroB); +} + +function objEquiv(a, b) { + if (isUndefinedOrNull(a) || isUndefinedOrNull(b)) + return false; + + // an identical 'prototype' property. + if (a.prototype !== b.prototype) return false; + //~~~I've managed to break Object.keys through screwy arguments passing. + // Converting to array solves the problem. + if (isArguments(a)) { + if (!isArguments(b)) { + return false; + } + a = pSlice.call(a); + b = pSlice.call(b); + return deepEqual(a, b); + } + try { + var ka = Object_keys(a), + kb = Object_keys(b), + key, i; + } catch (e) {//happens when one is a string literal and the other isn't + return false; + } + // having the same number of owned properties (keys incorporates + // hasOwnProperty) + if (ka.length != kb.length) + return false; + //the same set of keys (although not necessarily the same order), + ka.sort(); + kb.sort(); + //~~~cheap key test + for (i = ka.length - 1; i >= 0; i--) { + if (ka[i] != kb[i]) + return false; + } + //equivalent values for every corresponding key, and + //~~~possibly expensive deep test + for (i = ka.length - 1; i >= 0; i--) { + key = ka[i]; + if (!deepEqual(a[key], b[key])) return false; + } + return true; +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/deep-is/package.json b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/deep-is/package.json new file mode 100644 index 0000000..c4fd2e2 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/deep-is/package.json @@ -0,0 +1,86 @@ +{ + "name": "deep-is", + "version": "0.1.3", + "description": "node's assert.deepEqual algorithm except for NaN being equal to NaN", + "main": "index.js", + "directories": { + "lib": ".", + "example": "example", + "test": "test" + }, + "scripts": { + "test": "tape test/*.js" + }, + "devDependencies": { + "tape": "~1.0.2" + }, + "repository": { + "type": "git", + "url": "http://github.com/thlorenz/deep-is.git" + }, + "keywords": [ + "equality", + "equal", + "compare" + ], + "author": { + "name": "Thorsten Lorenz", + "email": "thlorenz@gmx.de", + "url": "http://thlorenz.com" + }, + "license": { + "type": "MIT", + "url": "https://github.com/thlorenz/deep-is/blob/master/LICENSE" + }, + "testling": { + "files": "test/*.js", + "browsers": { + "ie": [ + 6, + 7, + 8, + 9 + ], + "ff": [ + 3.5, + 10, + 15 + ], + "chrome": [ + 10, + 22 + ], + "safari": [ + 5.1 + ], + "opera": [ + 12 + ] + } + }, + "gitHead": "f126057628423458636dec9df3d621843b9ac55e", + "bugs": { + "url": "https://github.com/thlorenz/deep-is/issues" + }, + "homepage": "https://github.com/thlorenz/deep-is", + "_id": "deep-is@0.1.3", + "_shasum": "b369d6fb5dbc13eecf524f91b070feedc357cf34", + "_from": "deep-is@0.1.x", + "_npmVersion": "1.4.14", + "_npmUser": { + "name": "thlorenz", + "email": "thlorenz@gmx.de" + }, + "maintainers": [ + { + "name": "thlorenz", + "email": "thlorenz@gmx.de" + } + ], + "dist": { + "shasum": "b369d6fb5dbc13eecf524f91b070feedc357cf34", + "tarball": "http://registry.npmjs.org/deep-is/-/deep-is-0.1.3.tgz" + }, + "_resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.3.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/deep-is/test/NaN.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/deep-is/test/NaN.js new file mode 100644 index 0000000..ddaa5a7 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/deep-is/test/NaN.js @@ -0,0 +1,16 @@ +var test = require('tape'); +var equal = require('../'); + +test('NaN and 0 values', function (t) { + t.ok(equal(NaN, NaN)); + t.notOk(equal(0, NaN)); + t.ok(equal(0, 0)); + t.notOk(equal(0, 1)); + t.end(); +}); + + +test('nested NaN values', function (t) { + t.ok(equal([ NaN, 1, NaN ], [ NaN, 1, NaN ])); + t.end(); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/deep-is/test/cmp.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/deep-is/test/cmp.js new file mode 100644 index 0000000..3071013 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/deep-is/test/cmp.js @@ -0,0 +1,23 @@ +var test = require('tape'); +var equal = require('../'); + +test('equal', function (t) { + t.ok(equal( + { a : [ 2, 3 ], b : [ 4 ] }, + { a : [ 2, 3 ], b : [ 4 ] } + )); + t.end(); +}); + +test('not equal', function (t) { + t.notOk(equal( + { x : 5, y : [6] }, + { x : 5, y : 6 } + )); + t.end(); +}); + +test('nested nulls', function (t) { + t.ok(equal([ null, null, null ], [ null, null, null ])); + t.end(); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/deep-is/test/neg-vs-pos-0.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/deep-is/test/neg-vs-pos-0.js new file mode 100644 index 0000000..ac26130 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/deep-is/test/neg-vs-pos-0.js @@ -0,0 +1,15 @@ +var test = require('tape'); +var equal = require('../'); + +test('0 values', function (t) { + t.ok(equal( 0, 0), ' 0 === 0'); + t.ok(equal( 0, +0), ' 0 === +0'); + t.ok(equal(+0, +0), '+0 === +0'); + t.ok(equal(-0, -0), '-0 === -0'); + + t.notOk(equal(-0, 0), '-0 !== 0'); + t.notOk(equal(-0, +0), '-0 !== +0'); + + t.end(); +}); + diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/.npmignore b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/.npmignore new file mode 100644 index 0000000..3c3629e --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/.npmignore @@ -0,0 +1 @@ +node_modules diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/.travis.yml b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/.travis.yml new file mode 100644 index 0000000..2d26206 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/.travis.yml @@ -0,0 +1,3 @@ +language: node_js +node_js: + - 0.6 diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/LICENSE b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/LICENSE new file mode 100644 index 0000000..7b75500 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/LICENSE @@ -0,0 +1,24 @@ +Copyright 2010 James Halliday (mail@substack.net) + +This project is free software released under the MIT/X11 license: +http://www.opensource.org/licenses/mit-license.php + +Copyright 2010 James Halliday (mail@substack.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/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/examples/json.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/examples/json.js new file mode 100755 index 0000000..50d612e --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/examples/json.js @@ -0,0 +1,16 @@ +var traverse = require('traverse'); + +var id = 54; +var callbacks = {}; +var obj = { moo : function () {}, foo : [2,3,4, function () {}] }; + +var scrubbed = traverse(obj).map(function (x) { + if (typeof x === 'function') { + callbacks[id] = { id : id, f : x, path : this.path }; + this.update('[Function]'); + id++; + } +}); + +console.dir(scrubbed); +console.dir(callbacks); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/examples/leaves.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/examples/leaves.js new file mode 100755 index 0000000..c1b310b --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/examples/leaves.js @@ -0,0 +1,15 @@ +var traverse = require('traverse'); + +var obj = { + a : [1,2,3], + b : 4, + c : [5,6], + d : { e : [7,8], f : 9 }, +}; + +var leaves = traverse(obj).reduce(function (acc, x) { + if (this.isLeaf) acc.push(x); + return acc; +}, []); + +console.dir(leaves); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/examples/negative.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/examples/negative.js new file mode 100755 index 0000000..78608a0 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/examples/negative.js @@ -0,0 +1,8 @@ +var traverse = require('traverse'); +var obj = [ 5, 6, -3, [ 7, 8, -2, 1 ], { f : 10, g : -13 } ]; + +traverse(obj).forEach(function (x) { + if (x < 0) this.update(x + 128); +}); + +console.dir(obj); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/examples/scrub.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/examples/scrub.js new file mode 100755 index 0000000..5d15b91 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/examples/scrub.js @@ -0,0 +1,10 @@ +// scrub out circular references +var traverse = require('traverse'); + +var obj = { a : 1, b : 2, c : [ 3, 4 ] }; +obj.c.push(obj); + +var scrubbed = traverse(obj).map(function (x) { + if (this.circular) this.remove() +}); +console.dir(scrubbed); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/examples/stringify.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/examples/stringify.js new file mode 100755 index 0000000..167b68b --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/examples/stringify.js @@ -0,0 +1,38 @@ +#!/usr/bin/env node +var traverse = require('traverse'); + +var obj = [ 'five', 6, -3, [ 7, 8, -2, 1 ], { f : 10, g : -13 } ]; + +var s = ''; +traverse(obj).forEach(function to_s (node) { + if (Array.isArray(node)) { + this.before(function () { s += '[' }); + this.post(function (child) { + if (!child.isLast) s += ','; + }); + this.after(function () { s += ']' }); + } + else if (typeof node == 'object') { + this.before(function () { s += '{' }); + this.pre(function (x, key) { + to_s(key); + s += ':'; + }); + this.post(function (child) { + if (!child.isLast) s += ','; + }); + this.after(function () { s += '}' }); + } + else if (typeof node == 'string') { + s += '"' + node.toString().replace(/"/g, '\\"') + '"'; + } + else if (typeof node == 'function') { + s += 'null'; + } + else { + s += node.toString(); + } +}); + +console.log('JSON.stringify: ' + JSON.stringify(obj)); +console.log('this stringify: ' + s); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/index.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/index.js new file mode 100644 index 0000000..2f2cf67 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/index.js @@ -0,0 +1,314 @@ +var traverse = module.exports = function (obj) { + return new Traverse(obj); +}; + +function Traverse (obj) { + this.value = obj; +} + +Traverse.prototype.get = function (ps) { + var node = this.value; + for (var i = 0; i < ps.length; i ++) { + var key = ps[i]; + if (!node || !hasOwnProperty.call(node, key)) { + node = undefined; + break; + } + node = node[key]; + } + return node; +}; + +Traverse.prototype.has = function (ps) { + var node = this.value; + for (var i = 0; i < ps.length; i ++) { + var key = ps[i]; + if (!node || !hasOwnProperty.call(node, key)) { + return false; + } + node = node[key]; + } + return true; +}; + +Traverse.prototype.set = function (ps, value) { + var node = this.value; + for (var i = 0; i < ps.length - 1; i ++) { + var key = ps[i]; + if (!hasOwnProperty.call(node, key)) node[key] = {}; + node = node[key]; + } + node[ps[i]] = value; + return value; +}; + +Traverse.prototype.map = function (cb) { + return walk(this.value, cb, true); +}; + +Traverse.prototype.forEach = function (cb) { + this.value = walk(this.value, cb, false); + return this.value; +}; + +Traverse.prototype.reduce = function (cb, init) { + var skip = arguments.length === 1; + var acc = skip ? this.value : init; + this.forEach(function (x) { + if (!this.isRoot || !skip) { + acc = cb.call(this, acc, x); + } + }); + return acc; +}; + +Traverse.prototype.paths = function () { + var acc = []; + this.forEach(function (x) { + acc.push(this.path); + }); + return acc; +}; + +Traverse.prototype.nodes = function () { + var acc = []; + this.forEach(function (x) { + acc.push(this.node); + }); + return acc; +}; + +Traverse.prototype.clone = function () { + var parents = [], nodes = []; + + return (function clone (src) { + for (var i = 0; i < parents.length; i++) { + if (parents[i] === src) { + return nodes[i]; + } + } + + if (typeof src === 'object' && src !== null) { + var dst = copy(src); + + parents.push(src); + nodes.push(dst); + + forEach(objectKeys(src), function (key) { + dst[key] = clone(src[key]); + }); + + parents.pop(); + nodes.pop(); + return dst; + } + else { + return src; + } + })(this.value); +}; + +function walk (root, cb, immutable) { + var path = []; + var parents = []; + var alive = true; + + return (function walker (node_) { + var node = immutable ? copy(node_) : node_; + var modifiers = {}; + + var keepGoing = true; + + var state = { + node : node, + node_ : node_, + path : [].concat(path), + parent : parents[parents.length - 1], + parents : parents, + key : path.slice(-1)[0], + isRoot : path.length === 0, + level : path.length, + circular : null, + update : function (x, stopHere) { + if (!state.isRoot) { + state.parent.node[state.key] = x; + } + state.node = x; + if (stopHere) keepGoing = false; + }, + 'delete' : function (stopHere) { + delete state.parent.node[state.key]; + if (stopHere) keepGoing = false; + }, + remove : function (stopHere) { + if (isArray(state.parent.node)) { + state.parent.node.splice(state.key, 1); + } + else { + delete state.parent.node[state.key]; + } + if (stopHere) keepGoing = false; + }, + keys : null, + before : function (f) { modifiers.before = f }, + after : function (f) { modifiers.after = f }, + pre : function (f) { modifiers.pre = f }, + post : function (f) { modifiers.post = f }, + stop : function () { alive = false }, + block : function () { keepGoing = false } + }; + + if (!alive) return state; + + function updateState() { + if (typeof state.node === 'object' && state.node !== null) { + if (!state.keys || state.node_ !== state.node) { + state.keys = objectKeys(state.node) + } + + state.isLeaf = state.keys.length == 0; + + for (var i = 0; i < parents.length; i++) { + if (parents[i].node_ === node_) { + state.circular = parents[i]; + break; + } + } + } + else { + state.isLeaf = true; + state.keys = null; + } + + state.notLeaf = !state.isLeaf; + state.notRoot = !state.isRoot; + } + + updateState(); + + // use return values to update if defined + var ret = cb.call(state, state.node); + if (ret !== undefined && state.update) state.update(ret); + + if (modifiers.before) modifiers.before.call(state, state.node); + + if (!keepGoing) return state; + + if (typeof state.node == 'object' + && state.node !== null && !state.circular) { + parents.push(state); + + updateState(); + + forEach(state.keys, function (key, i) { + path.push(key); + + if (modifiers.pre) modifiers.pre.call(state, state.node[key], key); + + var child = walker(state.node[key]); + if (immutable && hasOwnProperty.call(state.node, key)) { + state.node[key] = child.node; + } + + child.isLast = i == state.keys.length - 1; + child.isFirst = i == 0; + + if (modifiers.post) modifiers.post.call(state, child); + + path.pop(); + }); + parents.pop(); + } + + if (modifiers.after) modifiers.after.call(state, state.node); + + return state; + })(root).node; +} + +function copy (src) { + if (typeof src === 'object' && src !== null) { + var dst; + + if (isArray(src)) { + dst = []; + } + else if (isDate(src)) { + dst = new Date(src.getTime ? src.getTime() : src); + } + else if (isRegExp(src)) { + dst = new RegExp(src); + } + else if (isError(src)) { + dst = { message: src.message }; + } + else if (isBoolean(src)) { + dst = new Boolean(src); + } + else if (isNumber(src)) { + dst = new Number(src); + } + else if (isString(src)) { + dst = new String(src); + } + else if (Object.create && Object.getPrototypeOf) { + dst = Object.create(Object.getPrototypeOf(src)); + } + else if (src.constructor === Object) { + dst = {}; + } + else { + var proto = + (src.constructor && src.constructor.prototype) + || src.__proto__ + || {} + ; + var T = function () {}; + T.prototype = proto; + dst = new T; + } + + forEach(objectKeys(src), function (key) { + dst[key] = src[key]; + }); + return dst; + } + else return src; +} + +var objectKeys = Object.keys || function keys (obj) { + var res = []; + for (var key in obj) res.push(key) + return res; +}; + +function toS (obj) { return Object.prototype.toString.call(obj) } +function isDate (obj) { return toS(obj) === '[object Date]' } +function isRegExp (obj) { return toS(obj) === '[object RegExp]' } +function isError (obj) { return toS(obj) === '[object Error]' } +function isBoolean (obj) { return toS(obj) === '[object Boolean]' } +function isNumber (obj) { return toS(obj) === '[object Number]' } +function isString (obj) { return toS(obj) === '[object String]' } + +var isArray = Array.isArray || function isArray (xs) { + return Object.prototype.toString.call(xs) === '[object Array]'; +}; + +var forEach = function (xs, fn) { + if (xs.forEach) return xs.forEach(fn) + else for (var i = 0; i < xs.length; i++) { + fn(xs[i], i, xs); + } +}; + +forEach(objectKeys(Traverse.prototype), function (key) { + traverse[key] = function (obj) { + var args = [].slice.call(arguments, 1); + var t = new Traverse(obj); + return t[key].apply(t, args); + }; +}); + +var hasOwnProperty = Object.hasOwnProperty || function (obj, key) { + return key in obj; +}; diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/package.json b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/package.json new file mode 100644 index 0000000..b8c56e5 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/package.json @@ -0,0 +1,84 @@ +{ + "name": "traverse", + "version": "0.6.6", + "description": "traverse and transform objects by visiting every node on a recursive walk", + "main": "index.js", + "directories": { + "example": "example", + "test": "test" + }, + "devDependencies": { + "tape": "~1.0.4" + }, + "scripts": { + "test": "tape test/*.js" + }, + "testling": { + "files": "test/*.js", + "browsers": { + "iexplore": [ + "6.0", + "7.0", + "8.0", + "9.0" + ], + "chrome": [ + "10.0", + "20.0" + ], + "firefox": [ + "10.0", + "15.0" + ], + "safari": [ + "5.1" + ], + "opera": [ + "12.0" + ] + } + }, + "repository": { + "type": "git", + "url": "git://github.com/substack/js-traverse.git" + }, + "homepage": "https://github.com/substack/js-traverse", + "keywords": [ + "traverse", + "walk", + "recursive", + "map", + "forEach", + "deep", + "clone" + ], + "author": { + "name": "James Halliday", + "email": "mail@substack.net", + "url": "http://substack.net" + }, + "license": "MIT", + "bugs": { + "url": "https://github.com/substack/js-traverse/issues" + }, + "_id": "traverse@0.6.6", + "dist": { + "shasum": "cbdf560fd7b9af632502fed40f918c157ea97137", + "tarball": "http://registry.npmjs.org/traverse/-/traverse-0.6.6.tgz" + }, + "_from": "traverse@0.6.x", + "_npmVersion": "1.3.7", + "_npmUser": { + "name": "substack", + "email": "mail@substack.net" + }, + "maintainers": [ + { + "name": "substack", + "email": "mail@substack.net" + } + ], + "_shasum": "cbdf560fd7b9af632502fed40f918c157ea97137", + "_resolved": "https://registry.npmjs.org/traverse/-/traverse-0.6.6.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/readme.markdown b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/readme.markdown new file mode 100644 index 0000000..fbfd06e --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/readme.markdown @@ -0,0 +1,209 @@ +# traverse + +Traverse and transform objects by visiting every node on a recursive walk. + +[![browser support](http://ci.testling.com/substack/js-traverse.png)](http://ci.testling.com/substack/js-traverse) + +[![build status](https://secure.travis-ci.org/substack/js-traverse.png)](http://travis-ci.org/substack/js-traverse) + +# examples + +## transform negative numbers in-place + +negative.js + +````javascript +var traverse = require('traverse'); +var obj = [ 5, 6, -3, [ 7, 8, -2, 1 ], { f : 10, g : -13 } ]; + +traverse(obj).forEach(function (x) { + if (x < 0) this.update(x + 128); +}); + +console.dir(obj); +```` + +Output: + + [ 5, 6, 125, [ 7, 8, 126, 1 ], { f: 10, g: 115 } ] + +## collect leaf nodes + +leaves.js + +````javascript +var traverse = require('traverse'); + +var obj = { + a : [1,2,3], + b : 4, + c : [5,6], + d : { e : [7,8], f : 9 }, +}; + +var leaves = traverse(obj).reduce(function (acc, x) { + if (this.isLeaf) acc.push(x); + return acc; +}, []); + +console.dir(leaves); +```` + +Output: + + [ 1, 2, 3, 4, 5, 6, 7, 8, 9 ] + +## scrub circular references + +scrub.js: + +````javascript +var traverse = require('traverse'); + +var obj = { a : 1, b : 2, c : [ 3, 4 ] }; +obj.c.push(obj); + +var scrubbed = traverse(obj).map(function (x) { + if (this.circular) this.remove() +}); +console.dir(scrubbed); +```` + +output: + + { a: 1, b: 2, c: [ 3, 4 ] } + +# methods + +Each method that takes an `fn` uses the context documented below in the context +section. + +## .map(fn) + +Execute `fn` for each node in the object and return a new object with the +results of the walk. To update nodes in the result use `this.update(value)`. + +## .forEach(fn) + +Execute `fn` for each node in the object but unlike `.map()`, when +`this.update()` is called it updates the object in-place. + +## .reduce(fn, acc) + +For each node in the object, perform a +[left-fold](http://en.wikipedia.org/wiki/Fold_(higher-order_function)) +with the return value of `fn(acc, node)`. + +If `acc` isn't specified, `acc` is set to the root object for the first step +and the root element is skipped. + +## .paths() + +Return an `Array` of every possible non-cyclic path in the object. +Paths are `Array`s of string keys. + +## .nodes() + +Return an `Array` of every node in the object. + +## .clone() + +Create a deep clone of the object. + +## .get(path) + +Get the element at the array `path`. + +## .set(path, value) + +Set the element at the array `path` to `value`. + +## .has(path) + +Return whether the element at the array `path` exists. + +# context + +Each method that takes a callback has a context (its `this` object) with these +attributes: + +## this.node + +The present node on the recursive walk + +## this.path + +An array of string keys from the root to the present node + +## this.parent + +The context of the node's parent. +This is `undefined` for the root node. + +## this.key + +The name of the key of the present node in its parent. +This is `undefined` for the root node. + +## this.isRoot, this.notRoot + +Whether the present node is the root node + +## this.isLeaf, this.notLeaf + +Whether or not the present node is a leaf node (has no children) + +## this.level + +Depth of the node within the traversal + +## this.circular + +If the node equals one of its parents, the `circular` attribute is set to the +context of that parent and the traversal progresses no deeper. + +## this.update(value, stopHere=false) + +Set a new value for the present node. + +All the elements in `value` will be recursively traversed unless `stopHere` is +true. + +## this.remove(stopHere=false) + +Remove the current element from the output. If the node is in an Array it will +be spliced off. Otherwise it will be deleted from its parent. + +## this.delete(stopHere=false) + +Delete the current element from its parent in the output. Calls `delete` even on +Arrays. + +## this.before(fn) + +Call this function before any of the children are traversed. + +You can assign into `this.keys` here to traverse in a custom order. + +## this.after(fn) + +Call this function after any of the children are traversed. + +## this.pre(fn) + +Call this function before each of the children are traversed. + +## this.post(fn) + +Call this function after each of the children are traversed. + + +# install + +Using [npm](http://npmjs.org) do: + + $ npm install traverse + +# license + +MIT diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/circular.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/circular.js new file mode 100644 index 0000000..f56506a --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/circular.js @@ -0,0 +1,117 @@ +var test = require('tape'); +var traverse = require('../'); +var deepEqual = require('./lib/deep_equal'); +var util = require('util'); + +test('circular', function (t) { + t.plan(1); + + var obj = { x : 3 }; + obj.y = obj; + traverse(obj).forEach(function (x) { + if (this.path.join('') == 'y') { + t.equal( + util.inspect(this.circular.node), + util.inspect(obj) + ); + } + }); +}); + +test('deepCirc', function (t) { + t.plan(2); + var obj = { x : [ 1, 2, 3 ], y : [ 4, 5 ] }; + obj.y[2] = obj; + + var times = 0; + traverse(obj).forEach(function (x) { + if (this.circular) { + t.same(this.circular.path, []); + t.same(this.path, [ 'y', 2 ]); + } + }); +}); + +test('doubleCirc', function (t) { + var obj = { x : [ 1, 2, 3 ], y : [ 4, 5 ] }; + obj.y[2] = obj; + obj.x.push(obj.y); + + var circs = []; + traverse(obj).forEach(function (x) { + if (this.circular) { + circs.push({ circ : this.circular, self : this, node : x }); + } + }); + + t.same(circs[0].self.path, [ 'x', 3, 2 ]); + t.same(circs[0].circ.path, []); + + t.same(circs[1].self.path, [ 'y', 2 ]); + t.same(circs[1].circ.path, []); + + t.same(circs.length, 2); + t.end(); +}); + +test('circDubForEach', function (t) { + var obj = { x : [ 1, 2, 3 ], y : [ 4, 5 ] }; + obj.y[2] = obj; + obj.x.push(obj.y); + + traverse(obj).forEach(function (x) { + if (this.circular) this.update('...'); + }); + + t.same(obj, { x : [ 1, 2, 3, [ 4, 5, '...' ] ], y : [ 4, 5, '...' ] }); + t.end(); +}); + +test('circDubMap', function (t) { + var obj = { x : [ 1, 2, 3 ], y : [ 4, 5 ] }; + obj.y[2] = obj; + obj.x.push(obj.y); + + var c = traverse(obj).map(function (x) { + if (this.circular) { + this.update('...'); + } + }); + + t.same(c, { x : [ 1, 2, 3, [ 4, 5, '...' ] ], y : [ 4, 5, '...' ] }); + t.end(); +}); + +test('circClone', function (t) { + var obj = { x : [ 1, 2, 3 ], y : [ 4, 5 ] }; + obj.y[2] = obj; + obj.x.push(obj.y); + + var clone = traverse.clone(obj); + t.ok(obj !== clone); + + t.ok(clone.y[2] === clone); + t.ok(clone.y[2] !== obj); + t.ok(clone.x[3][2] === clone); + t.ok(clone.x[3][2] !== obj); + t.same(clone.x.slice(0,3), [1,2,3]); + t.same(clone.y.slice(0,2), [4,5]); + t.end(); +}); + +test('circMapScrub', function (t) { + var obj = { a : 1, b : 2 }; + obj.c = obj; + + var scrubbed = traverse(obj).map(function (node) { + if (this.circular) this.remove(); + }); + t.same( + Object.keys(scrubbed).sort(), + [ 'a', 'b' ] + ); + t.ok(deepEqual(scrubbed, { a : 1, b : 2 })); + + t.equal(obj.c, obj); + t.end(); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/date.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/date.js new file mode 100644 index 0000000..54db4b0 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/date.js @@ -0,0 +1,37 @@ +var test = require('tape'); +var traverse = require('../'); + +test('dateEach', function (t) { + var obj = { x : new Date, y : 10, z : 5 }; + + var counts = {}; + + traverse(obj).forEach(function (node) { + var t = (node instanceof Date && 'Date') || typeof node; + counts[t] = (counts[t] || 0) + 1; + }); + + t.same(counts, { + object : 1, + Date : 1, + number : 2, + }); + t.end(); +}); + +test('dateMap', function (t) { + var obj = { x : new Date, y : 10, z : 5 }; + + var res = traverse(obj).map(function (node) { + if (typeof node === 'number') this.update(node + 100); + }); + + t.ok(obj.x !== res.x); + t.same(res, { + x : obj.x, + y : 110, + z : 105, + }); + t.end(); +}); + diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/equal.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/equal.js new file mode 100644 index 0000000..fd0463c --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/equal.js @@ -0,0 +1,240 @@ +var test = require('tape'); +var traverse = require('../'); +var deepEqual = require('./lib/deep_equal'); + +test('deepDates', function (t) { + t.plan(2); + + t.ok( + deepEqual( + { d : new Date, x : [ 1, 2, 3 ] }, + { d : new Date, x : [ 1, 2, 3 ] } + ), + 'dates should be equal' + ); + + var d0 = new Date; + setTimeout(function () { + t.ok( + !deepEqual( + { d : d0, x : [ 1, 2, 3 ], }, + { d : new Date, x : [ 1, 2, 3 ] } + ), + 'microseconds should count in date equality' + ); + }, 5); +}); + +test('deepCircular', function (t) { + var a = [1]; + a.push(a); // a = [ 1, *a ] + + var b = [1]; + b.push(a); // b = [ 1, [ 1, *a ] ] + + t.ok( + !deepEqual(a, b), + 'circular ref mount points count towards equality' + ); + + var c = [1]; + c.push(c); // c = [ 1, *c ] + t.ok( + deepEqual(a, c), + 'circular refs are structurally the same here' + ); + + var d = [1]; + d.push(a); // c = [ 1, [ 1, *d ] ] + t.ok( + deepEqual(b, d), + 'non-root circular ref structural comparison' + ); + + t.end(); +}); + +test('deepInstances', function (t) { + t.ok( + !deepEqual([ new Boolean(false) ], [ false ]), + 'boolean instances are not real booleans' + ); + + t.ok( + !deepEqual([ new String('x') ], [ 'x' ]), + 'string instances are not real strings' + ); + + t.ok( + !deepEqual([ new Number(4) ], [ 4 ]), + 'number instances are not real numbers' + ); + + t.ok( + deepEqual([ new RegExp('x') ], [ /x/ ]), + 'regexp instances are real regexps' + ); + + t.ok( + !deepEqual([ new RegExp(/./) ], [ /../ ]), + 'these regexps aren\'t the same' + ); + + t.ok( + !deepEqual( + [ function (x) { return x * 2 } ], + [ function (x) { return x * 2 } ] + ), + 'functions with the same .toString() aren\'t necessarily the same' + ); + + var f = function (x) { return x * 2 }; + t.ok( + deepEqual([ f ], [ f ]), + 'these functions are actually equal' + ); + + t.end(); +}); + +test('deepEqual', function (t) { + t.ok( + !deepEqual([ 1, 2, 3 ], { 0 : 1, 1 : 2, 2 : 3 }), + 'arrays are not objects' + ); + t.end(); +}); + +test('falsy', function (t) { + t.ok( + !deepEqual([ undefined ], [ null ]), + 'null is not undefined!' + ); + + t.ok( + !deepEqual([ null ], [ undefined ]), + 'undefined is not null!' + ); + + t.ok( + !deepEqual( + { a : 1, b : 2, c : [ 3, undefined, 5 ] }, + { a : 1, b : 2, c : [ 3, null, 5 ] } + ), + 'undefined is not null, however deeply!' + ); + + t.ok( + !deepEqual( + { a : 1, b : 2, c : [ 3, undefined, 5 ] }, + { a : 1, b : 2, c : [ 3, null, 5 ] } + ), + 'null is not undefined, however deeply!' + ); + + t.ok( + !deepEqual( + { a : 1, b : 2, c : [ 3, undefined, 5 ] }, + { a : 1, b : 2, c : [ 3, null, 5 ] } + ), + 'null is not undefined, however deeply!' + ); + + t.end(); +}); + +test('deletedArrayEqual', function (t) { + var xs = [ 1, 2, 3, 4 ]; + delete xs[2]; + + var ys = Object.create(Array.prototype); + ys[0] = 1; + ys[1] = 2; + ys[3] = 4; + + t.ok( + deepEqual(xs, ys), + 'arrays with deleted elements are only equal to' + + ' arrays with similarly deleted elements' + ); + + t.ok( + !deepEqual(xs, [ 1, 2, undefined, 4 ]), + 'deleted array elements cannot be undefined' + ); + + t.ok( + !deepEqual(xs, [ 1, 2, null, 4 ]), + 'deleted array elements cannot be null' + ); + + t.end(); +}); + +test('deletedObjectEqual', function (t) { + var obj = { a : 1, b : 2, c : 3 }; + delete obj.c; + + t.ok( + deepEqual(obj, { a : 1, b : 2 }), + 'deleted object elements should not show up' + ); + + t.ok( + !deepEqual(obj, { a : 1, b : 2, c : undefined }), + 'deleted object elements are not undefined' + ); + + t.ok( + !deepEqual(obj, { a : 1, b : 2, c : null }), + 'deleted object elements are not null' + ); + + t.end(); +}); + +test('emptyKeyEqual', function (t) { + t.ok(!deepEqual( + { a : 1 }, { a : 1, '' : 55 } + )); + + t.end(); +}); + +test('deepArguments', function (t) { + t.ok( + !deepEqual( + [ 4, 5, 6 ], + (function () { return arguments })(4, 5, 6) + ), + 'arguments are not arrays' + ); + + t.ok( + deepEqual( + (function () { return arguments })(4, 5, 6), + (function () { return arguments })(4, 5, 6) + ), + 'arguments should equal' + ); + + t.end(); +}); + +test('deepUn', function (t) { + t.ok(!deepEqual({ a : 1, b : 2 }, undefined)); + t.ok(!deepEqual({ a : 1, b : 2 }, {})); + t.ok(!deepEqual(undefined, { a : 1, b : 2 })); + t.ok(!deepEqual({}, { a : 1, b : 2 })); + t.ok(deepEqual(undefined, undefined)); + t.ok(deepEqual(null, null)); + t.ok(!deepEqual(undefined, null)); + + t.end(); +}); + +test('deepLevels', function (t) { + var xs = [ 1, 2, [ 3, 4, [ 5, 6 ] ] ]; + t.ok(!deepEqual(xs, [])); + t.end(); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/error.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/error.js new file mode 100644 index 0000000..447c725 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/error.js @@ -0,0 +1,11 @@ +var test = require('tape'); +var traverse = require('../'); + +test('traverse an Error', function (t) { + var obj = new Error("test"); + var results = traverse(obj).map(function (node) {}); + t.same(results, { message: 'test' }); + + t.end(); +}); + diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/has.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/has.js new file mode 100644 index 0000000..94a50c6 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/has.js @@ -0,0 +1,15 @@ +var test = require('tape'); +var traverse = require('../'); + +test('has', function (t) { + var obj = { a : 2, b : [ 4, 5, { c : 6 } ] }; + + t.equal(traverse(obj).has([ 'b', 2, 'c' ]), true) + t.equal(traverse(obj).has([ 'b', 2, 'c', 0 ]), false) + t.equal(traverse(obj).has([ 'b', 2, 'd' ]), false) + t.equal(traverse(obj).has([]), true) + t.equal(traverse(obj).has([ 'a' ]), true) + t.equal(traverse(obj).has([ 'a', 2 ]), false) + + t.end(); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/instance.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/instance.js new file mode 100644 index 0000000..112f477 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/instance.js @@ -0,0 +1,17 @@ +var test = require('tape'); +var traverse = require('../'); +var EventEmitter = require('events').EventEmitter; + +test('check instanceof on node elems', function (t) { + var counts = { emitter : 0 }; + + traverse([ new EventEmitter, 3, 4, { ev : new EventEmitter }]) + .forEach(function (node) { + if (node instanceof EventEmitter) counts.emitter ++; + }) + ; + + t.equal(counts.emitter, 2); + + t.end(); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/interface.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/interface.js new file mode 100644 index 0000000..f454c27 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/interface.js @@ -0,0 +1,43 @@ +var test = require('tape'); +var traverse = require('../'); + +test('interface map', function (t) { + var obj = { a : [ 5,6,7 ], b : { c : [8] } }; + + t.same( + traverse.paths(obj) + .sort() + .map(function (path) { return path.join('/') }) + .slice(1) + .join(' ') + , + 'a a/0 a/1 a/2 b b/c b/c/0' + ); + + t.same( + traverse.nodes(obj), + [ + { a: [ 5, 6, 7 ], b: { c: [ 8 ] } }, + [ 5, 6, 7 ], 5, 6, 7, + { c: [ 8 ] }, [ 8 ], 8 + ] + ); + + t.same( + traverse.map(obj, function (node) { + if (typeof node == 'number') { + return node + 1000; + } + else if (Array.isArray(node)) { + return node.join(' '); + } + }), + { a: '5 6 7', b: { c: '8' } } + ); + + var nodes = 0; + traverse.forEach(obj, function (node) { nodes ++ }); + t.same(nodes, 8); + + t.end(); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/json.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/json.js new file mode 100644 index 0000000..46d55e6 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/json.js @@ -0,0 +1,49 @@ +var test = require('tape'); +var traverse = require('../'); + +test('json test', function (t) { + var id = 54; + var callbacks = {}; + var obj = { moo : function () {}, foo : [2,3,4, function () {}] }; + + var scrubbed = traverse(obj).map(function (x) { + if (typeof x === 'function') { + callbacks[id] = { id : id, f : x, path : this.path }; + this.update('[Function]'); + id++; + } + }); + + t.equal( + scrubbed.moo, '[Function]', + 'obj.moo replaced with "[Function]"' + ); + + t.equal( + scrubbed.foo[3], '[Function]', + 'obj.foo[3] replaced with "[Function]"' + ); + + t.same(scrubbed, { + moo : '[Function]', + foo : [ 2, 3, 4, "[Function]" ] + }, 'Full JSON string matches'); + + t.same( + typeof obj.moo, 'function', + 'Original obj.moo still a function' + ); + + t.same( + typeof obj.foo[3], 'function', + 'Original obj.foo[3] still a function' + ); + + t.same(callbacks, { + 54: { id: 54, f : obj.moo, path: [ 'moo' ] }, + 55: { id: 55, f : obj.foo[3], path: [ 'foo', '3' ] }, + }, 'Check the generated callbacks list'); + + t.end(); +}); + diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/keys.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/keys.js new file mode 100644 index 0000000..9661140 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/keys.js @@ -0,0 +1,31 @@ +var test = require('tape'); +var traverse = require('../'); + +test('sort test', function (t) { + var acc = []; + traverse({ + a: 30, + b: 22, + id: 9 + }).forEach(function (node) { + if ((! Array.isArray(node)) && typeof node === 'object') { + this.before(function(node) { + this.keys = Object.keys(node); + this.keys.sort(function(a, b) { + a = [a === "id" ? 0 : 1, a]; + b = [b === "id" ? 0 : 1, b]; + return a < b ? -1 : a > b ? 1 : 0; + }); + }); + } + if (this.isLeaf) acc.push(node); + }); + + t.equal( + acc.join(' '), + '9 30 22', + 'Traversal in a custom order' + ); + + t.end(); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/leaves.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/leaves.js new file mode 100644 index 0000000..c04ad5f --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/leaves.js @@ -0,0 +1,22 @@ +var test = require('tape'); +var traverse = require('../'); + +test('leaves test', function (t) { + var acc = []; + traverse({ + a : [1,2,3], + b : 4, + c : [5,6], + d : { e : [7,8], f : 9 } + }).forEach(function (x) { + if (this.isLeaf) acc.push(x); + }); + + t.equal( + acc.join(' '), + '1 2 3 4 5 6 7 8 9', + 'Traversal in the right(?) order' + ); + + t.end(); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/lib/deep_equal.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/lib/deep_equal.js new file mode 100644 index 0000000..c75b04c --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/lib/deep_equal.js @@ -0,0 +1,96 @@ +var traverse = require('../../'); + +module.exports = function (a, b) { + if (arguments.length !== 2) { + throw new Error( + 'deepEqual requires exactly two objects to compare against' + ); + } + + var equal = true; + var node = b; + + traverse(a).forEach(function (y) { + var notEqual = (function () { + equal = false; + //this.stop(); + return undefined; + }).bind(this); + + //if (node === undefined || node === null) return notEqual(); + + if (!this.isRoot) { + /* + if (!Object.hasOwnProperty.call(node, this.key)) { + return notEqual(); + } + */ + if (typeof node !== 'object') return notEqual(); + node = node[this.key]; + } + + var x = node; + + this.post(function () { + node = x; + }); + + var toS = function (o) { + return Object.prototype.toString.call(o); + }; + + if (this.circular) { + if (traverse(b).get(this.circular.path) !== x) notEqual(); + } + else if (typeof x !== typeof y) { + notEqual(); + } + else if (x === null || y === null || x === undefined || y === undefined) { + if (x !== y) notEqual(); + } + else if (x.__proto__ !== y.__proto__) { + notEqual(); + } + else if (x === y) { + // nop + } + else if (typeof x === 'function') { + if (x instanceof RegExp) { + // both regexps on account of the __proto__ check + if (x.toString() != y.toString()) notEqual(); + } + else if (x !== y) notEqual(); + } + else if (typeof x === 'object') { + if (toS(y) === '[object Arguments]' + || toS(x) === '[object Arguments]') { + if (toS(x) !== toS(y)) { + notEqual(); + } + } + else if (toS(y) === '[object RegExp]' + || toS(x) === '[object RegExp]') { + if (!x || !y || x.toString() !== y.toString()) notEqual(); + } + else if (x instanceof Date || y instanceof Date) { + if (!(x instanceof Date) || !(y instanceof Date) + || x.getTime() !== y.getTime()) { + notEqual(); + } + } + else { + var kx = Object.keys(x); + var ky = Object.keys(y); + if (kx.length !== ky.length) return notEqual(); + for (var i = 0; i < kx.length; i++) { + var k = kx[i]; + if (!Object.hasOwnProperty.call(y, k)) { + notEqual(); + } + } + } + } + }); + + return equal; +}; diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/mutability.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/mutability.js new file mode 100644 index 0000000..3ab90da --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/mutability.js @@ -0,0 +1,300 @@ +var test = require('tape'); +var traverse = require('../'); +var deepEqual = require('./lib/deep_equal'); + +test('mutate', function (t) { + var obj = { a : 1, b : 2, c : [ 3, 4 ] }; + var res = traverse(obj).forEach(function (x) { + if (typeof x === 'number' && x % 2 === 0) { + this.update(x * 10); + } + }); + t.same(obj, res); + t.same(obj, { a : 1, b : 20, c : [ 3, 40 ] }); + t.end(); +}); + +test('mutateT', function (t) { + var obj = { a : 1, b : 2, c : [ 3, 4 ] }; + var res = traverse.forEach(obj, function (x) { + if (typeof x === 'number' && x % 2 === 0) { + this.update(x * 10); + } + }); + t.same(obj, res); + t.same(obj, { a : 1, b : 20, c : [ 3, 40 ] }); + t.end(); +}); + +test('map', function (t) { + var obj = { a : 1, b : 2, c : [ 3, 4 ] }; + var res = traverse(obj).map(function (x) { + if (typeof x === 'number' && x % 2 === 0) { + this.update(x * 10); + } + }); + t.same(obj, { a : 1, b : 2, c : [ 3, 4 ] }); + t.same(res, { a : 1, b : 20, c : [ 3, 40 ] }); + t.end(); +}); + +test('mapT', function (t) { + var obj = { a : 1, b : 2, c : [ 3, 4 ] }; + var res = traverse.map(obj, function (x) { + if (typeof x === 'number' && x % 2 === 0) { + this.update(x * 10); + } + }); + t.same(obj, { a : 1, b : 2, c : [ 3, 4 ] }); + t.same(res, { a : 1, b : 20, c : [ 3, 40 ] }); + t.end(); +}); + +test('clone', function (t) { + var obj = { a : 1, b : 2, c : [ 3, 4 ] }; + var res = traverse(obj).clone(); + t.same(obj, res); + t.ok(obj !== res); + obj.a ++; + t.same(res.a, 1); + obj.c.push(5); + t.same(res.c, [ 3, 4 ]); + t.end(); +}); + +test('cloneT', function (t) { + var obj = { a : 1, b : 2, c : [ 3, 4 ] }; + var res = traverse.clone(obj); + t.same(obj, res); + t.ok(obj !== res); + obj.a ++; + t.same(res.a, 1); + obj.c.push(5); + t.same(res.c, [ 3, 4 ]); + t.end(); +}); + +test('reduce', function (t) { + var obj = { a : 1, b : 2, c : [ 3, 4 ] }; + var res = traverse(obj).reduce(function (acc, x) { + if (this.isLeaf) acc.push(x); + return acc; + }, []); + t.same(obj, { a : 1, b : 2, c : [ 3, 4 ] }); + t.same(res, [ 1, 2, 3, 4 ]); + t.end(); +}); + +test('reduceInit', function (t) { + var obj = { a : 1, b : 2, c : [ 3, 4 ] }; + var res = traverse(obj).reduce(function (acc, x) { + if (this.isRoot) assert.fail('got root'); + return acc; + }); + t.same(obj, { a : 1, b : 2, c : [ 3, 4 ] }); + t.same(res, obj); + t.end(); +}); + +test('remove', function (t) { + var obj = { a : 1, b : 2, c : [ 3, 4 ] }; + traverse(obj).forEach(function (x) { + if (this.isLeaf && x % 2 == 0) this.remove(); + }); + + t.same(obj, { a : 1, c : [ 3 ] }); + t.end(); +}); + +exports.removeNoStop = function() { + var obj = { a : 1, b : 2, c : { d: 3, e: 4 }, f: 5 }; + + var keys = []; + traverse(obj).forEach(function (x) { + keys.push(this.key) + if (this.key == 'c') this.remove(); + }); + + t.same(keys, [undefined, 'a', 'b', 'c', 'd', 'e', 'f']) + t.end(); +} + +exports.removeStop = function() { + var obj = { a : 1, b : 2, c : { d: 3, e: 4 }, f: 5 }; + + var keys = []; + traverse(obj).forEach(function (x) { + keys.push(this.key) + if (this.key == 'c') this.remove(true); + }); + + t.same(keys, [undefined, 'a', 'b', 'c', 'f']) + t.end(); +} + +test('removeMap', function (t) { + var obj = { a : 1, b : 2, c : [ 3, 4 ] }; + var res = traverse(obj).map(function (x) { + if (this.isLeaf && x % 2 == 0) this.remove(); + }); + + t.same(obj, { a : 1, b : 2, c : [ 3, 4 ] }); + t.same(res, { a : 1, c : [ 3 ] }); + t.end(); +}); + +test('delete', function (t) { + var obj = { a : 1, b : 2, c : [ 3, 4 ] }; + traverse(obj).forEach(function (x) { + if (this.isLeaf && x % 2 == 0) this.delete(); + }); + + t.ok(!deepEqual( + obj, { a : 1, c : [ 3, undefined ] } + )); + + t.ok(deepEqual( + obj, { a : 1, c : [ 3 ] } + )); + + t.ok(!deepEqual( + obj, { a : 1, c : [ 3, null ] } + )); + t.end(); +}); + +test('deleteNoStop', function (t) { + var obj = { a : 1, b : 2, c : { d: 3, e: 4 } }; + + var keys = []; + traverse(obj).forEach(function (x) { + keys.push(this.key) + if (this.key == 'c') this.delete(); + }); + + t.same(keys, [undefined, 'a', 'b', 'c', 'd', 'e']) + t.end(); +}); + +test('deleteStop', function (t) { + var obj = { a : 1, b : 2, c : { d: 3, e: 4 } }; + + var keys = []; + traverse(obj).forEach(function (x) { + keys.push(this.key) + if (this.key == 'c') this.delete(true); + }); + + t.same(keys, [undefined, 'a', 'b', 'c']) + t.end(); +}); + +test('deleteRedux', function (t) { + var obj = { a : 1, b : 2, c : [ 3, 4, 5 ] }; + traverse(obj).forEach(function (x) { + if (this.isLeaf && x % 2 == 0) this.delete(); + }); + + t.ok(!deepEqual( + obj, { a : 1, c : [ 3, undefined, 5 ] } + )); + + t.ok(deepEqual( + obj, { a : 1, c : [ 3 ,, 5 ] } + )); + + t.ok(!deepEqual( + obj, { a : 1, c : [ 3, null, 5 ] } + )); + + t.ok(!deepEqual( + obj, { a : 1, c : [ 3, 5 ] } + )); + + t.end(); +}); + +test('deleteMap', function (t) { + var obj = { a : 1, b : 2, c : [ 3, 4 ] }; + var res = traverse(obj).map(function (x) { + if (this.isLeaf && x % 2 == 0) this.delete(); + }); + + t.ok(deepEqual( + obj, + { a : 1, b : 2, c : [ 3, 4 ] } + )); + + var xs = [ 3, 4 ]; + delete xs[1]; + + t.ok(deepEqual( + res, { a : 1, c : xs } + )); + + t.ok(deepEqual( + res, { a : 1, c : [ 3, ] } + )); + + t.ok(deepEqual( + res, { a : 1, c : [ 3 ] } + )); + + t.end(); +}); + +test('deleteMapRedux', function (t) { + var obj = { a : 1, b : 2, c : [ 3, 4, 5 ] }; + var res = traverse(obj).map(function (x) { + if (this.isLeaf && x % 2 == 0) this.delete(); + }); + + t.ok(deepEqual( + obj, + { a : 1, b : 2, c : [ 3, 4, 5 ] } + )); + + var xs = [ 3, 4, 5 ]; + delete xs[1]; + + t.ok(deepEqual( + res, { a : 1, c : xs } + )); + + t.ok(!deepEqual( + res, { a : 1, c : [ 3, 5 ] } + )); + + t.ok(deepEqual( + res, { a : 1, c : [ 3 ,, 5 ] } + )); + + t.end(); +}); + +test('objectToString', function (t) { + var obj = { a : 1, b : 2, c : [ 3, 4 ] }; + var res = traverse(obj).forEach(function (x) { + if (typeof x === 'object' && !this.isRoot) { + this.update(JSON.stringify(x)); + } + }); + t.same(obj, res); + t.same(obj, { a : 1, b : 2, c : "[3,4]" }); + t.end(); +}); + +test('stringToObject', function (t) { + var obj = { a : 1, b : 2, c : "[3,4]" }; + var res = traverse(obj).forEach(function (x) { + if (typeof x === 'string') { + this.update(JSON.parse(x)); + } + else if (typeof x === 'number' && x % 2 === 0) { + this.update(x * 10); + } + }); + t.deepEqual(obj, res); + t.deepEqual(obj, { a : 1, b : 20, c : [ 3, 40 ] }); + t.end(); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/negative.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/negative.js new file mode 100644 index 0000000..91566c8 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/negative.js @@ -0,0 +1,21 @@ +var traverse = require('../'); +var test = require('tape'); + +test('negative update test', function (t) { + var obj = [ 5, 6, -3, [ 7, 8, -2, 1 ], { f : 10, g : -13 } ]; + var fixed = traverse.map(obj, function (x) { + if (x < 0) this.update(x + 128); + }); + + t.same(fixed, + [ 5, 6, 125, [ 7, 8, 126, 1 ], { f: 10, g: 115 } ], + 'Negative values += 128' + ); + + t.same(obj, + [ 5, 6, -3, [ 7, 8, -2, 1 ], { f: 10, g: -13 } ], + 'Original references not modified' + ); + + t.end(); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/obj.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/obj.js new file mode 100644 index 0000000..8bcf58a --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/obj.js @@ -0,0 +1,11 @@ +var test = require('tape'); +var traverse = require('../'); + +test('traverse an object with nested functions', function (t) { + t.plan(1); + + function Cons (x) { + t.equal(x, 10) + }; + traverse(new Cons(10)); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/siblings.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/siblings.js new file mode 100644 index 0000000..c59e557 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/siblings.js @@ -0,0 +1,37 @@ +var test = require('tape'); +var traverse = require('../'); + +test('siblings', function (t) { + var obj = { a : 1, b : 2, c : [ 4, 5, 6 ] }; + + var res = traverse(obj).reduce(function (acc, x) { + var p = '/' + this.path.join('/'); + if (this.parent) { + acc[p] = { + siblings : this.parent.keys, + key : this.key, + index : this.parent.keys.indexOf(this.key) + }; + } + else { + acc[p] = { + siblings : [], + key : this.key, + index : -1 + } + } + return acc; + }, {}); + + t.same(res, { + '/' : { siblings : [], key : undefined, index : -1 }, + '/a' : { siblings : [ 'a', 'b', 'c' ], key : 'a', index : 0 }, + '/b' : { siblings : [ 'a', 'b', 'c' ], key : 'b', index : 1 }, + '/c' : { siblings : [ 'a', 'b', 'c' ], key : 'c', index : 2 }, + '/c/0' : { siblings : [ '0', '1', '2' ], key : '0', index : 0 }, + '/c/1' : { siblings : [ '0', '1', '2' ], key : '1', index : 1 }, + '/c/2' : { siblings : [ '0', '1', '2' ], key : '2', index : 2 } + }); + + t.end(); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/stop.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/stop.js new file mode 100644 index 0000000..9ce15b0 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/stop.js @@ -0,0 +1,44 @@ +var test = require('tape'); +var traverse = require('../'); + +test('stop', function (t) { + var visits = 0; + traverse('abcdefghij'.split('')).forEach(function (node) { + if (typeof node === 'string') { + visits ++; + if (node === 'e') this.stop() + } + }); + + t.equal(visits, 5); + t.end(); +}); + +test('stopMap', function (t) { + var s = traverse('abcdefghij'.split('')).map(function (node) { + if (typeof node === 'string') { + if (node === 'e') this.stop() + return node.toUpperCase(); + } + }).join(''); + + t.equal(s, 'ABCDEfghij'); + t.end(); +}); + +test('stopReduce', function (t) { + var obj = { + a : [ 4, 5 ], + b : [ 6, [ 7, 8, 9 ] ] + }; + var xs = traverse(obj).reduce(function (acc, node) { + if (this.isLeaf) { + if (node === 7) this.stop(); + else acc.push(node) + } + return acc; + }, []); + + t.same(xs, [ 4, 5, 6 ]); + t.end(); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/stringify.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/stringify.js new file mode 100644 index 0000000..f1680d8 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/stringify.js @@ -0,0 +1,36 @@ +var test = require('tape'); +var traverse = require('../'); + +test('stringify', function (t) { + var obj = [ 5, 6, -3, [ 7, 8, -2, 1 ], { f : 10, g : -13 } ]; + + var s = ''; + traverse(obj).forEach(function (node) { + if (Array.isArray(node)) { + this.before(function () { s += '[' }); + this.post(function (child) { + if (!child.isLast) s += ','; + }); + this.after(function () { s += ']' }); + } + else if (typeof node == 'object') { + this.before(function () { s += '{' }); + this.pre(function (x, key) { + s += '"' + key + '"' + ':'; + }); + this.post(function (child) { + if (!child.isLast) s += ','; + }); + this.after(function () { s += '}' }); + } + else if (typeof node == 'function') { + s += 'null'; + } + else { + s += node.toString(); + } + }); + + t.equal(s, JSON.stringify(obj)); + t.end(); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/subexpr.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/subexpr.js new file mode 100644 index 0000000..7682608 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/subexpr.js @@ -0,0 +1,36 @@ +var traverse = require('../'); +var test = require('tape'); + +test('subexpr', function (t) { + var obj = [ 'a', 4, 'b', 5, 'c', 6 ]; + var r = traverse(obj).map(function (x) { + if (typeof x === 'number') { + this.update([ x - 0.1, x, x + 0.1 ], true); + } + }); + + t.same(obj, [ 'a', 4, 'b', 5, 'c', 6 ]); + t.same(r, [ + 'a', [ 3.9, 4, 4.1 ], + 'b', [ 4.9, 5, 5.1 ], + 'c', [ 5.9, 6, 6.1 ], + ]); + t.end(); +}); + +test('block', function (t) { + var obj = [ [ 1 ], [ 2 ], [ 3 ] ]; + var r = traverse(obj).map(function (x) { + if (Array.isArray(x) && !this.isRoot) { + if (x[0] === 5) this.block() + else this.update([ [ x[0] + 1 ] ]) + } + }); + + t.same(r, [ + [ [ [ [ [ 5 ] ] ] ] ], + [ [ [ [ 5 ] ] ] ], + [ [ [ 5 ] ] ], + ]); + t.end(); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/super_deep.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/super_deep.js new file mode 100644 index 0000000..1eb9e26 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/test/super_deep.js @@ -0,0 +1,56 @@ +var test = require('tape'); +var traverse = require('../'); +var deepEqual = require('./lib/deep_equal'); + +test('super_deep', function (t) { + var util = require('util'); + var a0 = make(); + var a1 = make(); + t.ok(deepEqual(a0, a1)); + + a0.c.d.moo = true; + t.ok(!deepEqual(a0, a1)); + + a1.c.d.moo = true; + t.ok(deepEqual(a0, a1)); + + // TODO: this one + //a0.c.a = a1; + //t.ok(!deepEqual(a0, a1)); + t.end(); +}); + +function make () { + var a = { self : 'a' }; + var b = { self : 'b' }; + var c = { self : 'c' }; + var d = { self : 'd' }; + var e = { self : 'e' }; + + a.a = a; + a.b = b; + a.c = c; + + b.a = a; + b.b = b; + b.c = c; + + c.a = a; + c.b = b; + c.c = c; + c.d = d; + + d.a = a; + d.b = b; + d.c = c; + d.d = d; + d.e = e; + + e.a = a; + e.b = b; + e.c = c; + e.d = d; + e.e = e; + + return a; +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/testling/leaves.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/testling/leaves.js new file mode 100644 index 0000000..29968dd --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/traverse/testling/leaves.js @@ -0,0 +1,22 @@ +var traverse = require('./'); +var test = require('testling'); + +test('leaves', function (t) { + var obj = { + a : [1,2,3], + b : 4, + c : [5,6], + d : { e : [7,8], f : 9 } + }; + + var acc = []; + traverse(obj).forEach(function (x) { + if (this.isLeaf) acc.push(x); + }); + + t.deepEqual( + acc, [ 1, 2, 3, 4, 5, 6, 7, 8, 9 ], + 'traversal in the proper order' + ); + t.end(); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/package.json b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/package.json new file mode 100644 index 0000000..4be3fc1 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/package.json @@ -0,0 +1,66 @@ +{ + "name": "difflet", + "description": "colorful diffs for javascript objects", + "version": "0.2.6", + "repository": { + "type": "git", + "url": "git://github.com/substack/difflet.git" + }, + "main": "index.js", + "keywords": [ + "diff", + "object", + "compare" + ], + "directories": { + "lib": ".", + "example": "example", + "test": "test" + }, + "scripts": { + "test": "tap test/*.js" + }, + "dependencies": { + "traverse": "0.6.x", + "charm": "0.1.x", + "deep-is": "0.1.x" + }, + "devDependencies": { + "tap": "0.1.x", + "ent": "0.0.x" + }, + "engines": { + "node": ">=0.4.0" + }, + "license": "MIT", + "author": { + "name": "James Halliday", + "email": "mail@substack.net", + "url": "http://substack.net" + }, + "readme": "difflet\n=======\n\nCreate colorful diffs for javascript objects.\n\nexample\n=======\n\nstring.js\n---------\n\n``` js\nvar difflet = require('difflet');\n\nvar s = difflet.compare({ a : 2, c : 5 }, { a : 3, b : 4 });\nprocess.stdout.write(s);\n```\n\noutput:\n\n![colorful output](http://substack.net/images/screenshots/difflet_string.png)\n\ncolors.js\n---------\n\n``` js\nvar diff = require('difflet')({ indent : 2 });\n\nvar prev = {\n yy : 6,\n zz : 5,\n a : [1,2,3],\n fn : 'beep',\n c : { x : 7, z : 3 }\n};\n\nvar next = {\n a : [ 1, 2, \"z\", /beep/, new Buffer(3) ],\n fn : function qqq () {},\n b : [5,6,7],\n c : { x : 8, y : 5 }\n};\n\ndiff(prev, next).pipe(process.stdout);\n```\n\noutput:\n\n![colorful output](http://substack.net/images/screenshots/difflet_colors.png)\n\ngreen for inserts, blue for updates, red for deletes\n\nmethods\n=======\n\nvar difflet = require('difflet')\n\nvar diff = difflet(opts={})\n---------------------------\n\nCreate a difflet from optional options `opts`.\n\nWith `opts.start(type, stream)` and `opts.stop(type, stream)`,\nyou can write custom handlers for all the types of differences:\n`'inserted'`, `'updated'`, and `'deleted'`.\nBy default green is used for insertions, blue for updates, and red for\ndeletions.\n\nIf `opts.indent` is set, output will span multiple lines and `opts.indent`\nspaces will be used for leading whitespace.\n\nIf `opts.comma === 'first'` then commas will be placed at the start of lines.\n\nSetting `opts.comment` to `true` will turn on comments with the previous\ncontents like this:\n\n![object comments](http://substack.net/images/screenshots/difflet_object_comments.png)\n\ndiff(prev, next)\n----------------\n\nReturn a stream with the colorful changes between objects `prev` and `next`.\n\ndiff.compare(prev, next)\n------------------------\n\nReturn a string with the colorful changes between `prev` and `next`.\n\ndifflet.compare(prev, next)\n---------------------------\n\nReturn a string with the colorful changes between `prev` and `next` with the\ndefault options.\n\ninstall\n=======\n\nWith [npm](http://npmjs.org) do:\n\n```\nnpm install difflet\n```\n\ntest\n====\n\nWith [npm](http://npmjs.org) do:\n\n```\nnpm test\n```\n\nlicense\n=======\n\nMIT/X11\n", + "readmeFilename": "README.markdown", + "bugs": { + "url": "https://github.com/substack/difflet/issues" + }, + "_id": "difflet@0.2.6", + "dist": { + "shasum": "ab23b31f5649b6faa8e3d2acbd334467365ca6fa", + "tarball": "http://registry.npmjs.org/difflet/-/difflet-0.2.6.tgz" + }, + "_from": "difflet@~0.2.0", + "_npmVersion": "1.3.0", + "_npmUser": { + "name": "substack", + "email": "mail@substack.net" + }, + "maintainers": [ + { + "name": "substack", + "email": "mail@substack.net" + } + ], + "_shasum": "ab23b31f5649b6faa8e3d2acbd334467365ca6fa", + "_resolved": "https://registry.npmjs.org/difflet/-/difflet-0.2.6.tgz", + "homepage": "https://github.com/substack/difflet" +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/test/diffing-NaN.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/test/diffing-NaN.js new file mode 100644 index 0000000..d29e6e1 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/test/diffing-NaN.js @@ -0,0 +1,17 @@ +var difflet = require('../'); +var diff = difflet(); +var test = require('tap').test; + +test('diffing NaN against NaN', function (t) { + t.plan(1); + var d = diff.compare(NaN, NaN); + + t.equal(d, 'NaN'); +}); + +test('diffing { o: NaN } against { o: NaN }', function (t) { + t.plan(1); + var d = diff.compare({ o: NaN }, { o: NaN }); + + t.equal(d, '{"o":NaN}'); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/difflet/test/html.js b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/test/html.js new file mode 100644 index 0000000..26d2ed4 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/difflet/test/html.js @@ -0,0 +1,80 @@ +var difflet = require('../'); +var test = require('tap').test; +var ent = require('ent'); + +var tags = { + inserted : 'g', + updated : 'b', + deleted : 'r', +}; + +test('html output', function (t) { + t.plan(1); + var diff = difflet({ + start : function (t, s) { + s.write('<' + tags[t] + '>'); + }, + stop : function (t, s) { + s.write(''); + }, + write : function (buf, s) { + s.write(ent.encode(buf)); + } + }); + + var stream = diff( + { yy : 6, zz : 5, a : [1,2,3], fn : function qqq () {} }, + { + a : [ 1, 2, 3, [4], "z", /beep/, new Buffer([0,1,2]) ], + fn : function rrr () {}, + b : [5,6,7] + } + ); + + var data = '' + stream.on('data', function (buf) { data += buf }); + stream.on('end', function () { + t.equal(data, + '{"a":[1,2,3,[4],"z",' + + '/beep/,<Buffer 00 01 02>],' + + '"fn":[Function: rrr],' + + '"b":[5,6,7],"yy":6,' + + '"zz":5}' + ); + t.end(); + }); +}); + +test('compare html output', function (t) { + t.plan(1); + + var diff = difflet({ + start : function (t, s) { + s.write('<' + tags[t] + '>'); + }, + stop : function (t, s) { + s.write(''); + }, + write : function (buf, s) { + s.write(ent.encode(buf)); + } + }); + + var data = diff.compare( + { yy : 6, zz : 5, a : [1,2,3], fn : function qqq () {} }, + { + a : [ 1, 2, 3, [4], "z", /beep/, new Buffer([0,1,2]) ], + fn : function rrr () {}, + b : [5,6,7] + } + ); + + t.equal(data, + '{"a":[1,2,3,[4],"z",' + + '/beep/,<Buffer 00 01 02>],' + + '"fn":[Function: rrr],' + + '"b":[5,6,7],"yy":6,' + + '"zz":5}' + ); + t.end(); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/.npmignore b/node_modules/nodeunit/node_modules/tap/node_modules/glob/.npmignore new file mode 100644 index 0000000..2af4b71 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/.npmignore @@ -0,0 +1,2 @@ +.*.swp +test/a/ diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/.travis.yml b/node_modules/nodeunit/node_modules/tap/node_modules/glob/.travis.yml new file mode 100644 index 0000000..baa0031 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/.travis.yml @@ -0,0 +1,3 @@ +language: node_js +node_js: + - 0.8 diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/LICENSE b/node_modules/nodeunit/node_modules/tap/node_modules/glob/LICENSE new file mode 100644 index 0000000..0c44ae7 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/LICENSE @@ -0,0 +1,27 @@ +Copyright (c) Isaac Z. Schlueter ("Author") +All rights reserved. + +The BSD License + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions +are met: + +1. Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + +2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + +THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS +BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR +CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF +SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR +BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, +WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE +OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN +IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/README.md b/node_modules/nodeunit/node_modules/tap/node_modules/glob/README.md new file mode 100644 index 0000000..cc69164 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/README.md @@ -0,0 +1,250 @@ +# 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. + +## Attention: node-glob users! + +The API has changed dramatically between 2.x and 3.x. This library is +now 100% JavaScript, and the integer flags have been replaced with an +options object. + +Also, there's an event emitter class, proper tests, and all the other +things you've come to expect from node modules. + +And best of all, no compilation! + +## 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. +}) +``` + +## Features + +Please see the [minimatch +documentation](https://github.com/isaacs/minimatch) for more details. + +Supports these glob features: + +* Brace Expansion +* Extended glob matching +* "Globstar" `**` matching + +See: + +* `man sh` +* `man bash` +* `man 3 fnmatch` +* `man 5 gitignore` +* [minimatch documentation](https://github.com/isaacs/minimatch) + +## glob(pattern, [options], cb) + +* `pattern` {String} Pattern to be matched +* `options` {Object} +* `cb` {Function} + * `err` {Error | null} + * `matches` {Array} filenames found matching the pattern + +Perform an asynchronous glob search. + +## glob.sync(pattern, [options]) + +* `pattern` {String} Pattern to be matched +* `options` {Object} +* return: {Array} filenames found matching the pattern + +Perform a synchronous glob search. + +## Class: glob.Glob + +Create a Glob object by instanting 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} 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. +* `error` The error encountered. When an error is encountered, the + glob object is in an undefined state, and should be discarded. +* `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 + * `1` - Path exists, and is not a directory + * `2` - Path exists, and is a directory + * `[file, entries, ...]` - Path exists, is a directory, and the + array value is the results of `fs.readdir` + +### 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 + +* `abort` Stop the search. + +### 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. + +* `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. It will cause + ELOOP to be triggered one level sooner in the case of cyclical + symbolic links. +* `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.) +* `sync` Perform a synchronous glob search. +* `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). +* `nocase` Perform a case-insensitive match. Note that case-insensitive + filesystems will sometimes result in glob returning results that are + case-insensitively matched anyway, since readdir and stat will not + raise an error. +* `debug` Set to enable debug logging in minimatch and glob. +* `globDebug` Set to enable debug logging in glob, but not minimatch. + +## 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.1, 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. + +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. diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/examples/g.js b/node_modules/nodeunit/node_modules/tap/node_modules/glob/examples/g.js new file mode 100644 index 0000000..be122df --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/examples/g.js @@ -0,0 +1,9 @@ +var Glob = require("../").Glob + +var pattern = "test/a/**/[cg]/../[cg]" +console.log(pattern) + +var mg = new Glob(pattern, {mark: true, sync:true}, function (er, matches) { + console.log("matches", matches) +}) +console.log("after") diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/examples/usr-local.js b/node_modules/nodeunit/node_modules/tap/node_modules/glob/examples/usr-local.js new file mode 100644 index 0000000..327a425 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/examples/usr-local.js @@ -0,0 +1,9 @@ +var Glob = require("../").Glob + +var pattern = "{./*/*,/*,/usr/local/*}" +console.log(pattern) + +var mg = new Glob(pattern, {mark: true}, function (er, matches) { + console.log("matches", matches) +}) +console.log("after") diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/glob.js b/node_modules/nodeunit/node_modules/tap/node_modules/glob/glob.js new file mode 100644 index 0000000..f646c44 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/glob.js @@ -0,0 +1,728 @@ +// Approach: +// +// 1. Get the minimatch set +// 2. For each pattern in the set, PROCESS(pattern) +// 3. Store matches per-set, then uniq them +// +// PROCESS(pattern) +// 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. +// readdir(PREFIX) as ENTRIES +// If fails, END +// 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 .. $]) +// // handle other cases. +// for ENTRY in ENTRIES (not dotfiles) +// // attach globstar + tail onto the entry +// PROCESS(pattern[0..n] + ENTRY + pattern[n .. $]) +// +// 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") +, minimatch = require("minimatch") +, Minimatch = minimatch.Minimatch +, inherits = require("inherits") +, EE = require("events").EventEmitter +, path = require("path") +, isDir = {} +, assert = require("assert").ok + +function glob (pattern, options, cb) { + if (typeof options === "function") cb = options, options = {} + if (!options) options = {} + + if (typeof options === "number") { + deprecated() + return + } + + var g = new Glob(pattern, options, cb) + return g.sync ? g.found : g +} + +glob.fnmatch = deprecated + +function deprecated () { + throw new Error("glob's interface has changed. Please see the docs.") +} + +glob.sync = globSync +function globSync (pattern, options) { + if (typeof options === "number") { + deprecated() + return + } + + options = options || {} + options.sync = true + return glob(pattern, options) +} + +this._processingEmitQueue = false + +glob.Glob = Glob +inherits(Glob, EE) +function Glob (pattern, options, cb) { + if (!(this instanceof Glob)) { + return new Glob(pattern, options, cb) + } + + if (typeof options === "function") { + cb = options + options = null + } + + if (typeof cb === "function") { + this.on("error", cb) + this.on("end", function (matches) { + cb(null, matches) + }) + } + + options = options || {} + + this._endEmitted = false + this.EOF = {} + this._emitQueue = [] + + this.paused = false + this._processingEmitQueue = false + + this.maxDepth = options.maxDepth || 1000 + this.maxLength = options.maxLength || Infinity + this.cache = options.cache || {} + this.statCache = options.statCache || {} + + this.changedCwd = false + var cwd = process.cwd() + if (!options.hasOwnProperty("cwd")) this.cwd = cwd + else { + this.cwd = options.cwd + this.changedCwd = path.resolve(options.cwd) !== cwd + } + + this.root = options.root || path.resolve(this.cwd, "/") + this.root = path.resolve(this.root) + if (process.platform === "win32") + this.root = this.root.replace(/\\/g, "/") + + this.nomount = !!options.nomount + + if (!pattern) { + throw new Error("must provide pattern") + } + + // 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 + } + + this.strict = options.strict !== false + this.dot = !!options.dot + this.mark = !!options.mark + this.sync = !!options.sync + this.nounique = !!options.nounique + this.nonull = !!options.nonull + this.nosort = !!options.nosort + this.nocase = !!options.nocase + this.stat = !!options.stat + + this.debug = !!options.debug || !!options.globDebug + if (this.debug) + this.log = console.error + + this.silent = !!options.silent + + var mm = this.minimatch = new Minimatch(pattern, options) + this.options = mm.options + pattern = this.pattern = mm.pattern + + this.error = null + this.aborted = false + + // list of all the patterns that ** has resolved do, so + // we can avoid visiting multiple times. + this._globstars = {} + + EE.call(this) + + // process each pattern in the minimatch set + var n = this.minimatch.set.length + + // The matches are stored as {: 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) + + this.minimatch.set.forEach(iterator.bind(this)) + function iterator (pattern, i, set) { + this._process(pattern, 0, i, function (er) { + if (er) this.emit("error", er) + if (-- n <= 0) this._finish() + }) + } +} + +Glob.prototype.log = function () {} + +Glob.prototype._finish = function () { + assert(this instanceof Glob) + + var nou = this.nounique + , all = nou ? [] : {} + + for (var i = 0, l = this.matches.length; i < l; i ++) { + var matches = this.matches[i] + this.log("matches[%d] =", i, matches) + // do like the shell, and spit out the literal glob + if (!matches) { + if (this.nonull) { + var literal = this.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 (!this.nosort) { + all = all.sort(this.nocase ? alphasorti : alphasort) + } + + if (this.mark) { + // at *some* point we statted all of these + all = all.map(this._mark, this) + } + + this.log("emitting end", all) + + this.EOF = this.found = all + this.emitMatch(this.EOF) +} + +function alphasorti (a, b) { + a = a.toLowerCase() + b = b.toLowerCase() + return alphasort(a, b) +} + +function alphasort (a, b) { + return a > b ? 1 : a < b ? -1 : 0 +} + +Glob.prototype._mark = function (p) { + var c = this.cache[p] + var m = p + if (c) { + var isDir = c === 2 || Array.isArray(c) + var slash = p.slice(-1) === '/' + + if (isDir && !slash) + m += '/' + else if (!isDir && slash) + m = m.slice(0, -1) + + if (m !== p) { + this.statCache[m] = this.statCache[p] + this.cache[m] = this.cache[p] + } + } + + return m +} + +Glob.prototype.abort = function () { + this.aborted = true + this.emit("abort") +} + +Glob.prototype.pause = function () { + if (this.paused) return + if (this.sync) + this.emit("error", new Error("Can't pause/resume sync glob")) + this.paused = true + this.emit("pause") +} + +Glob.prototype.resume = function () { + if (!this.paused) return + if (this.sync) + this.emit("error", new Error("Can't pause/resume sync glob")) + this.paused = false + this.emit("resume") + this._processEmitQueue() + //process.nextTick(this.emit.bind(this, "resume")) +} + +Glob.prototype.emitMatch = function (m) { + this.log('emitMatch', m) + this._emitQueue.push(m) + this._processEmitQueue() +} + +Glob.prototype._processEmitQueue = function (m) { + this.log("pEQ paused=%j processing=%j m=%j", this.paused, + this._processingEmitQueue, m) + var done = false + while (!this._processingEmitQueue && + !this.paused) { + this._processingEmitQueue = true + var m = this._emitQueue.shift() + this.log(">processEmitQueue", m === this.EOF ? ":EOF:" : m) + if (!m) { + this.log(">processEmitQueue, falsey m") + this._processingEmitQueue = false + break + } + + if (m === this.EOF || !(this.mark && !this.stat)) { + this.log("peq: unmarked, or eof") + next.call(this, 0, false) + } else if (this.statCache[m]) { + var sc = this.statCache[m] + var exists + if (sc) + exists = sc.isDirectory() ? 2 : 1 + this.log("peq: stat cached") + next.call(this, exists, exists === 2) + } else { + this.log("peq: _stat, then next") + this._stat(m, next) + } + + function next(exists, isDir) { + this.log("next", m, exists, isDir) + var ev = m === this.EOF ? "end" : "match" + + // "end" can only happen once. + assert(!this._endEmitted) + if (ev === "end") + this._endEmitted = true + + if (exists) { + // Doesn't mean it necessarily doesn't exist, it's possible + // we just didn't check because we don't care that much, or + // this is EOF anyway. + if (isDir && !m.match(/\/$/)) { + m = m + "/" + } else if (!isDir && m.match(/\/$/)) { + m = m.replace(/\/+$/, "") + } + } + this.log("emit", ev, m) + this.emit(ev, m) + this._processingEmitQueue = false + if (done && m !== this.EOF && !this.paused) + this._processEmitQueue() + } + } + done = true +} + +Glob.prototype._process = function (pattern, depth, index, cb_) { + assert(this instanceof Glob) + + var cb = function cb (er, res) { + assert(this instanceof Glob) + if (this.paused) { + if (!this._processQueue) { + this._processQueue = [] + this.once("resume", function () { + var q = this._processQueue + this._processQueue = null + q.forEach(function (cb) { cb() }) + }) + } + this._processQueue.push(cb_.bind(this, er, res)) + } else { + cb_.call(this, er, res) + } + }.bind(this) + + if (this.aborted) return cb() + + if (depth > this.maxDepth) return cb() + + // 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: + prefix = pattern.join("/") + this._stat(prefix, function (exists, isDir) { + // either it's there, or it isn't. + // nothing more to do, either way. + if (exists) { + if (prefix && isAbsolute(prefix) && !this.nomount) { + if (prefix.charAt(0) === "/") { + prefix = path.join(this.root, prefix) + } else { + prefix = path.resolve(this.root, prefix) + } + } + + if (process.platform === "win32") + prefix = prefix.replace(/\\/g, "/") + + this.matches[index] = this.matches[index] || {} + this.matches[index][prefix] = true + this.emitMatch(prefix) + } + return 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) + prefix = prefix.join("/") + break + } + + // get the list of entries. + var read + if (prefix === null) read = "." + else if (isAbsolute(prefix) || isAbsolute(pattern.join("/"))) { + if (!prefix || !isAbsolute(prefix)) { + prefix = path.join("/", prefix) + } + read = prefix = path.resolve(prefix) + + // if (process.platform === "win32") + // read = prefix = prefix.replace(/^[a-zA-Z]:|\\/g, "/") + + this.log('absolute: ', prefix, this.root, pattern, read) + } else { + read = prefix + } + + this.log('readdir(%j)', read, this.cwd, this.root) + + return this._readdir(read, function (er, entries) { + if (er) { + // not a directory! + // this means that, whatever else comes after this, it can never match + return cb() + } + + // globstar is special + if (pattern[n] === minimatch.GLOBSTAR) { + // test without the globstar, and with every child both below + // and replacing the globstar. + var s = [ pattern.slice(0, n).concat(pattern.slice(n + 1)) ] + entries.forEach(function (e) { + if (e.charAt(0) === "." && !this.dot) return + // instead of the globstar + s.push(pattern.slice(0, n).concat(e).concat(pattern.slice(n + 1))) + // below the globstar + s.push(pattern.slice(0, n).concat(e).concat(pattern.slice(n))) + }, this) + + s = s.filter(function (pattern) { + var key = gsKey(pattern) + var seen = !this._globstars[key] + this._globstars[key] = true + return seen + }, this) + + if (!s.length) + return cb() + + // now asyncForEach over this + var l = s.length + , errState = null + s.forEach(function (gsPattern) { + this._process(gsPattern, depth + 1, index, function (er) { + if (errState) return + if (er) return cb(errState = er) + if (--l <= 0) return cb() + }) + }, this) + + return + } + + // not a globstar + // 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 = pattern[n] + var rawGlob = pattern[n]._glob + , dotOk = this.dot || rawGlob.charAt(0) === "." + + entries = entries.filter(function (e) { + return (e.charAt(0) !== "." || dotOk) && + e.match(pattern[n]) + }) + + // If n === pattern.length - 1, then there's no need for the extra stat + // *unless* the user has specified "mark" or "stat" explicitly. + // We know that they exist, since the readdir returned them. + if (n === pattern.length - 1 && + !this.mark && + !this.stat) { + entries.forEach(function (e) { + if (prefix) { + if (prefix !== "/") e = prefix + "/" + e + else e = prefix + e + } + if (e.charAt(0) === "/" && !this.nomount) { + e = path.join(this.root, e) + } + + if (process.platform === "win32") + e = e.replace(/\\/g, "/") + + this.matches[index] = this.matches[index] || {} + this.matches[index][e] = true + this.emitMatch(e) + }, this) + return cb.call(this) + } + + + // now test all the remaining entries as stand-ins for that part + // of the pattern. + var l = entries.length + , errState = null + if (l === 0) return cb() // no matches possible + entries.forEach(function (e) { + var p = pattern.slice(0, n).concat(e).concat(pattern.slice(n + 1)) + this._process(p, depth + 1, index, function (er) { + if (errState) return + if (er) return cb(errState = er) + if (--l === 0) return cb.call(this) + }) + }, this) + }) + +} + +function gsKey (pattern) { + return '**' + pattern.map(function (p) { + return (p === minimatch.GLOBSTAR) ? '**' : (''+p) + }).join('/') +} + +Glob.prototype._stat = function (f, cb) { + assert(this instanceof Glob) + var abs = f + if (f.charAt(0) === "/") { + abs = path.join(this.root, f) + } else if (this.changedCwd) { + abs = path.resolve(this.cwd, f) + } + + if (f.length > this.maxLength) { + var er = new Error("Path name too long") + er.code = "ENAMETOOLONG" + er.path = f + return this._afterStat(f, abs, cb, er) + } + + this.log('stat', [this.cwd, f, '=', abs]) + + if (!this.stat && this.cache.hasOwnProperty(f)) { + var exists = this.cache[f] + , isDir = exists && (Array.isArray(exists) || exists === 2) + if (this.sync) return cb.call(this, !!exists, isDir) + return process.nextTick(cb.bind(this, !!exists, isDir)) + } + + var stat = this.statCache[abs] + if (this.sync || stat) { + var er + try { + stat = fs.statSync(abs) + } catch (e) { + er = e + } + this._afterStat(f, abs, cb, er, stat) + } else { + fs.stat(abs, this._afterStat.bind(this, f, abs, cb)) + } +} + +Glob.prototype._afterStat = function (f, abs, cb, er, stat) { + var exists + assert(this instanceof Glob) + + if (abs.slice(-1) === "/" && stat && !stat.isDirectory()) { + this.log("should be ENOTDIR, fake it") + + er = new Error("ENOTDIR, not a directory '" + abs + "'") + er.path = abs + er.code = "ENOTDIR" + stat = null + } + + var emit = !this.statCache[abs] + this.statCache[abs] = stat + + if (er || !stat) { + exists = false + } else { + exists = stat.isDirectory() ? 2 : 1 + if (emit) + this.emit('stat', f, stat) + } + this.cache[f] = this.cache[f] || exists + cb.call(this, !!exists, exists === 2) +} + +Glob.prototype._readdir = function (f, cb) { + assert(this instanceof Glob) + var abs = f + if (f.charAt(0) === "/") { + abs = path.join(this.root, f) + } else if (isAbsolute(f)) { + abs = f + } else if (this.changedCwd) { + abs = path.resolve(this.cwd, f) + } + + if (f.length > this.maxLength) { + var er = new Error("Path name too long") + er.code = "ENAMETOOLONG" + er.path = f + return this._afterReaddir(f, abs, cb, er) + } + + this.log('readdir', [this.cwd, f, abs]) + if (this.cache.hasOwnProperty(f)) { + var c = this.cache[f] + if (Array.isArray(c)) { + if (this.sync) return cb.call(this, null, c) + return process.nextTick(cb.bind(this, null, c)) + } + + if (!c || c === 1) { + // either ENOENT or ENOTDIR + var code = c ? "ENOTDIR" : "ENOENT" + , er = new Error((c ? "Not a directory" : "Not found") + ": " + f) + er.path = f + er.code = code + this.log(f, er) + if (this.sync) return cb.call(this, er) + return process.nextTick(cb.bind(this, er)) + } + + // at this point, c === 2, meaning it's a dir, but we haven't + // had to read it yet, or c === true, meaning it's *something* + // but we don't have any idea what. Need to read it, either way. + } + + if (this.sync) { + var er, entries + try { + entries = fs.readdirSync(abs) + } catch (e) { + er = e + } + return this._afterReaddir(f, abs, cb, er, entries) + } + + fs.readdir(abs, this._afterReaddir.bind(this, f, abs, cb)) +} + +Glob.prototype._afterReaddir = function (f, abs, cb, er, entries) { + assert(this instanceof Glob) + if (entries && !er) { + this.cache[f] = entries + // if we haven't asked to stat everything for suresies, then just + // assume that everything in there exists, so we can avoid + // having to stat it a second time. This also gets us one step + // further into ELOOP territory. + if (!this.mark && !this.stat) { + entries.forEach(function (e) { + if (f === "/") e = f + e + else e = f + "/" + e + this.cache[e] = true + }, this) + } + + return cb.call(this, er, entries) + } + + // now handle errors, and cache the information + if (er) switch (er.code) { + case "ENOTDIR": // totally normal. means it *does* exist. + this.cache[f] = 1 + return cb.call(this, er) + case "ENOENT": // not terribly unusual + case "ELOOP": + case "ENAMETOOLONG": + case "UNKNOWN": + this.cache[f] = false + return cb.call(this, er) + default: // some unusual error. Treat as failure. + this.cache[f] = false + if (this.strict) this.emit("error", er) + if (!this.silent) console.error("glob error", er) + return cb.call(this, er) + } +} + +var isAbsolute = process.platform === "win32" ? absWin : absUnix + +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]*?)$/ + , result = splitDeviceRe.exec(p) + , device = result[1] || '' + , isUnc = device && device.charAt(1) !== ':' + , isAbsolute = !!result[2] || isUnc // UNC paths are always absolute + + return isAbsolute +} + +function absUnix (p) { + return p.charAt(0) === "/" || p === "" +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/.npmignore b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/.npmignore new file mode 100644 index 0000000..3c3629e --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/.npmignore @@ -0,0 +1 @@ +node_modules diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/LICENSE b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/LICENSE new file mode 100644 index 0000000..05a4010 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/LICENSE @@ -0,0 +1,23 @@ +Copyright 2009, 2010, 2011 Isaac Z. Schlueter. +All rights reserved. + +Permission is hereby granted, free of charge, to any person +obtaining a copy of this software and associated documentation +files (the "Software"), to deal in the Software without +restriction, including without limitation the rights to use, +copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the +Software is furnished to do so, subject to the following +conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES +OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT +HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR +OTHER DEALINGS IN THE SOFTWARE. diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/README.md b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/README.md new file mode 100644 index 0000000..5b3967e --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/README.md @@ -0,0 +1,218 @@ +# minimatch + +A minimal matching utility. + +[![Build Status](https://secure.travis-ci.org/isaacs/minimatch.png)](http://travis-ci.org/isaacs/minimatch) + + +This is the matching library used internally by npm. + +Eventually, it will replace the C binding in node-glob. + +It works by converting glob expressions into JavaScript `RegExp` +objects. + +## Usage + +```javascript +var minimatch = require("minimatch") + +minimatch("bar.foo", "*.foo") // true! +minimatch("bar.foo", "*.bar") // false! +minimatch("bar.foo", "*.+(bar|foo)", { debug: true }) // true, and noisy! +``` + +## Features + +Supports these glob features: + +* Brace Expansion +* Extended glob matching +* "Globstar" `**` matching + +See: + +* `man sh` +* `man bash` +* `man 3 fnmatch` +* `man 5 gitignore` + +## Minimatch Class + +Create a minimatch object by instanting the `minimatch.Minimatch` class. + +```javascript +var Minimatch = require("minimatch").Minimatch +var mm = new Minimatch(pattern, options) +``` + +### Properties + +* `pattern` The original pattern the minimatch object represents. +* `options` The options supplied to the constructor. +* `set` A 2-dimensional array of regexp or string expressions. + Each row in the + array corresponds to a brace-expanded pattern. Each item in the row + corresponds to a single path-part. For example, the pattern + `{a,b/c}/d` would expand to a set of patterns like: + + [ [ a, d ] + , [ b, c, d ] ] + + If a portion of the pattern doesn't have any "magic" in it + (that is, it's something like `"foo"` rather than `fo*o?`), then it + will be left as a string rather than converted to a regular + expression. + +* `regexp` Created by the `makeRe` method. A single regular expression + expressing the entire pattern. This is useful in cases where you wish + to use the pattern somewhat like `fnmatch(3)` with `FNM_PATH` enabled. +* `negate` True if the pattern is negated. +* `comment` True if the pattern is a comment. +* `empty` True if the pattern is `""`. + +### Methods + +* `makeRe` Generate the `regexp` member if necessary, and return it. + Will return `false` if the pattern is invalid. +* `match(fname)` Return true if the filename matches the pattern, or + false otherwise. +* `matchOne(fileArray, patternArray, partial)` Take a `/`-split + filename, and match it against a single row in the `regExpSet`. This + method is mainly for internal use, but is exposed so that it can be + used by a glob-walker that needs to avoid excessive filesystem calls. + +All other methods are internal, and will be called as necessary. + +## Functions + +The top-level exported function has a `cache` property, which is an LRU +cache set to store 100 items. So, calling these methods repeatedly +with the same pattern and options will use the same Minimatch object, +saving the cost of parsing it multiple times. + +### minimatch(path, pattern, options) + +Main export. Tests a path against the pattern using the options. + +```javascript +var isJS = minimatch(file, "*.js", { matchBase: true }) +``` + +### minimatch.filter(pattern, options) + +Returns a function that tests its +supplied argument, suitable for use with `Array.filter`. Example: + +```javascript +var javascripts = fileList.filter(minimatch.filter("*.js", {matchBase: true})) +``` + +### minimatch.match(list, pattern, options) + +Match against the list of +files, in the style of fnmatch or glob. If nothing is matched, and +options.nonull is set, then return a list containing the pattern itself. + +```javascript +var javascripts = minimatch.match(fileList, "*.js", {matchBase: true})) +``` + +### minimatch.makeRe(pattern, options) + +Make a regular expression object from the pattern. + +## Options + +All options are `false` by default. + +### debug + +Dump a ton of stuff to stderr. + +### nobrace + +Do not expand `{a,b}` and `{1..3}` brace sets. + +### noglobstar + +Disable `**` matching against multiple folder names. + +### dot + +Allow patterns to match filenames starting with a period, even if +the pattern does not explicitly have a period in that spot. + +Note that by default, `a/**/b` will **not** match `a/.d/b`, unless `dot` +is set. + +### noext + +Disable "extglob" style patterns like `+(a|b)`. + +### nocase + +Perform a case-insensitive match. + +### nonull + +When a match is not found by `minimatch.match`, return a list containing +the pattern itself if this option is set. When not set, an empty list +is returned if there are no matches. + +### matchBase + +If set, then patterns without slashes will be matched +against the basename of the path if it contains slashes. For example, +`a?b` would match the path `/xyz/123/acb`, but not `/xyz/acb/123`. + +### nocomment + +Suppress the behavior of treating `#` at the start of a pattern as a +comment. + +### nonegate + +Suppress the behavior of treating a leading `!` character as negation. + +### flipNegate + +Returns from negate expressions the same as if they were not negated. +(Ie, true on a hit, false on a miss.) + + +## Comparisons to other fnmatch/glob implementations + +While strict compliance with the existing standards is a worthwhile +goal, some discrepancies exist between minimatch 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.1, 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. + +If an escaped pattern has no matches, and the `nonull` flag is set, +then minimatch.match returns the pattern as-provided, rather than +interpreting the character escapes. For example, +`minimatch.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. diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/minimatch.js b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/minimatch.js new file mode 100644 index 0000000..4539678 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/minimatch.js @@ -0,0 +1,1061 @@ +;(function (require, exports, module, platform) { + +if (module) module.exports = minimatch +else exports.minimatch = minimatch + +if (!require) { + require = function (id) { + switch (id) { + case "sigmund": return function sigmund (obj) { + return JSON.stringify(obj) + } + case "path": return { basename: function (f) { + f = f.split(/[\/\\]/) + var e = f.pop() + if (!e) e = f.pop() + return e + }} + case "lru-cache": return function LRUCache () { + // not quite an LRU, but still space-limited. + var cache = {} + var cnt = 0 + this.set = function (k, v) { + cnt ++ + if (cnt >= 100) cache = {} + cache[k] = v + } + this.get = function (k) { return cache[k] } + } + } + } +} + +minimatch.Minimatch = Minimatch + +var LRU = require("lru-cache") + , cache = minimatch.cache = new LRU({max: 100}) + , GLOBSTAR = minimatch.GLOBSTAR = Minimatch.GLOBSTAR = {} + , sigmund = require("sigmund") + +var path = require("path") + // any single thing other than / + // don't need to escape / when using new RegExp() + , qmark = "[^/]" + + // * => any number of characters + , star = qmark + "*?" + + // ** when dots are allowed. Anything goes, except .. and . + // not (^ or / followed by one or two dots followed by $ or /), + // followed by anything, any number of times. + , twoStarDot = "(?:(?!(?:\\\/|^)(?:\\.{1,2})($|\\\/)).)*?" + + // not a ^ or / followed by a dot, + // followed by anything, any number of times. + , twoStarNoDot = "(?:(?!(?:\\\/|^)\\.).)*?" + + // characters that need to be escaped in RegExp. + , reSpecials = charSet("().*{}+?[]^$\\!") + +// "abc" -> { a:true, b:true, c:true } +function charSet (s) { + return s.split("").reduce(function (set, c) { + set[c] = true + return set + }, {}) +} + +// normalizes slashes. +var slashSplit = /\/+/ + +minimatch.filter = filter +function filter (pattern, options) { + options = options || {} + return function (p, i, list) { + return minimatch(p, pattern, options) + } +} + +function ext (a, b) { + a = a || {} + b = b || {} + var t = {} + Object.keys(b).forEach(function (k) { + t[k] = b[k] + }) + Object.keys(a).forEach(function (k) { + t[k] = a[k] + }) + return t +} + +minimatch.defaults = function (def) { + if (!def || !Object.keys(def).length) return minimatch + + var orig = minimatch + + var m = function minimatch (p, pattern, options) { + return orig.minimatch(p, pattern, ext(def, options)) + } + + m.Minimatch = function Minimatch (pattern, options) { + return new orig.Minimatch(pattern, ext(def, options)) + } + + return m +} + +Minimatch.defaults = function (def) { + if (!def || !Object.keys(def).length) return Minimatch + return minimatch.defaults(def).Minimatch +} + + +function minimatch (p, pattern, options) { + if (typeof pattern !== "string") { + throw new TypeError("glob pattern string required") + } + + if (!options) options = {} + + // shortcut: comments match nothing. + if (!options.nocomment && pattern.charAt(0) === "#") { + return false + } + + // "" only matches "" + if (pattern.trim() === "") return p === "" + + return new Minimatch(pattern, options).match(p) +} + +function Minimatch (pattern, options) { + if (!(this instanceof Minimatch)) { + return new Minimatch(pattern, options, cache) + } + + if (typeof pattern !== "string") { + throw new TypeError("glob pattern string required") + } + + if (!options) options = {} + pattern = pattern.trim() + + // windows: need to use /, not \ + // On other platforms, \ is a valid (albeit bad) filename char. + if (platform === "win32") { + pattern = pattern.split("\\").join("/") + } + + // lru storage. + // these things aren't particularly big, but walking down the string + // and turning it into a regexp can get pretty costly. + var cacheKey = pattern + "\n" + sigmund(options) + var cached = minimatch.cache.get(cacheKey) + if (cached) return cached + minimatch.cache.set(cacheKey, this) + + this.options = options + this.set = [] + this.pattern = pattern + this.regexp = null + this.negate = false + this.comment = false + this.empty = false + + // make the set of regexps etc. + this.make() +} + +Minimatch.prototype.debug = function() {} + +Minimatch.prototype.make = make +function make () { + // don't do it more than once. + if (this._made) return + + var pattern = this.pattern + var options = this.options + + // empty patterns and comments match nothing. + if (!options.nocomment && pattern.charAt(0) === "#") { + this.comment = true + return + } + if (!pattern) { + this.empty = true + return + } + + // step 1: figure out negation, etc. + this.parseNegate() + + // step 2: expand braces + var set = this.globSet = this.braceExpand() + + if (options.debug) this.debug = console.error + + this.debug(this.pattern, set) + + // step 3: now we have a set, so turn each one into a series of path-portion + // matching patterns. + // These will be regexps, except in the case of "**", which is + // set to the GLOBSTAR object for globstar behavior, + // and will not contain any / characters + set = this.globParts = set.map(function (s) { + return s.split(slashSplit) + }) + + this.debug(this.pattern, set) + + // glob --> regexps + set = set.map(function (s, si, set) { + return s.map(this.parse, this) + }, this) + + this.debug(this.pattern, set) + + // filter out everything that didn't compile properly. + set = set.filter(function (s) { + return -1 === s.indexOf(false) + }) + + this.debug(this.pattern, set) + + this.set = set +} + +Minimatch.prototype.parseNegate = parseNegate +function parseNegate () { + var pattern = this.pattern + , negate = false + , options = this.options + , negateOffset = 0 + + if (options.nonegate) return + + for ( var i = 0, l = pattern.length + ; i < l && pattern.charAt(i) === "!" + ; i ++) { + negate = !negate + negateOffset ++ + } + + if (negateOffset) this.pattern = pattern.substr(negateOffset) + this.negate = negate +} + +// Brace expansion: +// a{b,c}d -> abd acd +// a{b,}c -> abc ac +// a{0..3}d -> a0d a1d a2d a3d +// a{b,c{d,e}f}g -> abg acdfg acefg +// a{b,c}d{e,f}g -> abdeg acdeg abdeg abdfg +// +// Invalid sets are not expanded. +// a{2..}b -> a{2..}b +// a{b}c -> a{b}c +minimatch.braceExpand = function (pattern, options) { + return new Minimatch(pattern, options).braceExpand() +} + +Minimatch.prototype.braceExpand = braceExpand +function braceExpand (pattern, options) { + options = options || this.options + pattern = typeof pattern === "undefined" + ? this.pattern : pattern + + if (typeof pattern === "undefined") { + throw new Error("undefined pattern") + } + + if (options.nobrace || + !pattern.match(/\{.*\}/)) { + // shortcut. no need to expand. + return [pattern] + } + + var escaping = false + + // examples and comments refer to this crazy pattern: + // a{b,c{d,e},{f,g}h}x{y,z} + // expected: + // abxy + // abxz + // acdxy + // acdxz + // acexy + // acexz + // afhxy + // afhxz + // aghxy + // aghxz + + // everything before the first \{ is just a prefix. + // So, we pluck that off, and work with the rest, + // and then prepend it to everything we find. + if (pattern.charAt(0) !== "{") { + this.debug(pattern) + var prefix = null + for (var i = 0, l = pattern.length; i < l; i ++) { + var c = pattern.charAt(i) + this.debug(i, c) + if (c === "\\") { + escaping = !escaping + } else if (c === "{" && !escaping) { + prefix = pattern.substr(0, i) + break + } + } + + // actually no sets, all { were escaped. + if (prefix === null) { + this.debug("no sets") + return [pattern] + } + + var tail = braceExpand.call(this, pattern.substr(i), options) + return tail.map(function (t) { + return prefix + t + }) + } + + // now we have something like: + // {b,c{d,e},{f,g}h}x{y,z} + // walk through the set, expanding each part, until + // the set ends. then, we'll expand the suffix. + // If the set only has a single member, then'll put the {} back + + // first, handle numeric sets, since they're easier + var numset = pattern.match(/^\{(-?[0-9]+)\.\.(-?[0-9]+)\}/) + if (numset) { + this.debug("numset", numset[1], numset[2]) + var suf = braceExpand.call(this, pattern.substr(numset[0].length), options) + , start = +numset[1] + , end = +numset[2] + , inc = start > end ? -1 : 1 + , set = [] + for (var i = start; i != (end + inc); i += inc) { + // append all the suffixes + for (var ii = 0, ll = suf.length; ii < ll; ii ++) { + set.push(i + suf[ii]) + } + } + return set + } + + // ok, walk through the set + // We hope, somewhat optimistically, that there + // will be a } at the end. + // If the closing brace isn't found, then the pattern is + // interpreted as braceExpand("\\" + pattern) so that + // the leading \{ will be interpreted literally. + var i = 1 // skip the \{ + , depth = 1 + , set = [] + , member = "" + , sawEnd = false + , escaping = false + + function addMember () { + set.push(member) + member = "" + } + + this.debug("Entering for") + FOR: for (i = 1, l = pattern.length; i < l; i ++) { + var c = pattern.charAt(i) + this.debug("", i, c) + + if (escaping) { + escaping = false + member += "\\" + c + } else { + switch (c) { + case "\\": + escaping = true + continue + + case "{": + depth ++ + member += "{" + continue + + case "}": + depth -- + // if this closes the actual set, then we're done + if (depth === 0) { + addMember() + // pluck off the close-brace + i ++ + break FOR + } else { + member += c + continue + } + + case ",": + if (depth === 1) { + addMember() + } else { + member += c + } + continue + + default: + member += c + continue + } // switch + } // else + } // for + + // now we've either finished the set, and the suffix is + // pattern.substr(i), or we have *not* closed the set, + // and need to escape the leading brace + if (depth !== 0) { + this.debug("didn't close", pattern) + return braceExpand.call(this, "\\" + pattern, options) + } + + // x{y,z} -> ["xy", "xz"] + this.debug("set", set) + this.debug("suffix", pattern.substr(i)) + var suf = braceExpand.call(this, pattern.substr(i), options) + // ["b", "c{d,e}","{f,g}h"] -> + // [["b"], ["cd", "ce"], ["fh", "gh"]] + var addBraces = set.length === 1 + this.debug("set pre-expanded", set) + set = set.map(function (p) { + return braceExpand.call(this, p, options) + }, this) + this.debug("set expanded", set) + + + // [["b"], ["cd", "ce"], ["fh", "gh"]] -> + // ["b", "cd", "ce", "fh", "gh"] + set = set.reduce(function (l, r) { + return l.concat(r) + }) + + if (addBraces) { + set = set.map(function (s) { + return "{" + s + "}" + }) + } + + // now attach the suffixes. + var ret = [] + for (var i = 0, l = set.length; i < l; i ++) { + for (var ii = 0, ll = suf.length; ii < ll; ii ++) { + ret.push(set[i] + suf[ii]) + } + } + return ret +} + +// parse a component of the expanded set. +// At this point, no pattern may contain "/" in it +// so we're going to return a 2d array, where each entry is the full +// pattern, split on '/', and then turned into a regular expression. +// A regexp is made at the end which joins each array with an +// escaped /, and another full one which joins each regexp with |. +// +// Following the lead of Bash 4.1, note that "**" only has special meaning +// when it is the *only* thing in a path portion. Otherwise, any series +// of * is equivalent to a single *. Globstar behavior is enabled by +// default, and can be disabled by setting options.noglobstar. +Minimatch.prototype.parse = parse +var SUBPARSE = {} +function parse (pattern, isSub) { + var options = this.options + + // shortcuts + if (!options.noglobstar && pattern === "**") return GLOBSTAR + if (pattern === "") return "" + + var re = "" + , hasMagic = !!options.nocase + , escaping = false + // ? => one single character + , patternListStack = [] + , plType + , stateChar + , inClass = false + , reClassStart = -1 + , classStart = -1 + // . and .. never match anything that doesn't start with ., + // even when options.dot is set. + , patternStart = pattern.charAt(0) === "." ? "" // anything + // not (start or / followed by . or .. followed by / or end) + : options.dot ? "(?!(?:^|\\\/)\\.{1,2}(?:$|\\\/))" + : "(?!\\.)" + , self = this + + function clearStateChar () { + if (stateChar) { + // we had some state-tracking character + // that wasn't consumed by this pass. + switch (stateChar) { + case "*": + re += star + hasMagic = true + break + case "?": + re += qmark + hasMagic = true + break + default: + re += "\\"+stateChar + break + } + self.debug('clearStateChar %j %j', stateChar, re) + stateChar = false + } + } + + for ( var i = 0, len = pattern.length, c + ; (i < len) && (c = pattern.charAt(i)) + ; i ++ ) { + + this.debug("%s\t%s %s %j", pattern, i, re, c) + + // skip over any that are escaped. + if (escaping && reSpecials[c]) { + re += "\\" + c + escaping = false + continue + } + + SWITCH: switch (c) { + case "/": + // completely not allowed, even escaped. + // Should already be path-split by now. + return false + + case "\\": + clearStateChar() + escaping = true + continue + + // the various stateChar values + // for the "extglob" stuff. + case "?": + case "*": + case "+": + case "@": + case "!": + this.debug("%s\t%s %s %j <-- stateChar", pattern, i, re, c) + + // all of those are literals inside a class, except that + // the glob [!a] means [^a] in regexp + if (inClass) { + this.debug(' in class') + if (c === "!" && i === classStart + 1) c = "^" + re += c + continue + } + + // if we already have a stateChar, then it means + // that there was something like ** or +? in there. + // Handle the stateChar, then proceed with this one. + self.debug('call clearStateChar %j', stateChar) + clearStateChar() + stateChar = c + // if extglob is disabled, then +(asdf|foo) isn't a thing. + // just clear the statechar *now*, rather than even diving into + // the patternList stuff. + if (options.noext) clearStateChar() + continue + + case "(": + if (inClass) { + re += "(" + continue + } + + if (!stateChar) { + re += "\\(" + continue + } + + plType = stateChar + patternListStack.push({ type: plType + , start: i - 1 + , reStart: re.length }) + // negation is (?:(?!js)[^/]*) + re += stateChar === "!" ? "(?:(?!" : "(?:" + this.debug('plType %j %j', stateChar, re) + stateChar = false + continue + + case ")": + if (inClass || !patternListStack.length) { + re += "\\)" + continue + } + + clearStateChar() + hasMagic = true + re += ")" + plType = patternListStack.pop().type + // negation is (?:(?!js)[^/]*) + // The others are (?:) + switch (plType) { + case "!": + re += "[^/]*?)" + break + case "?": + case "+": + case "*": re += plType + case "@": break // the default anyway + } + continue + + case "|": + if (inClass || !patternListStack.length || escaping) { + re += "\\|" + escaping = false + continue + } + + clearStateChar() + re += "|" + continue + + // these are mostly the same in regexp and glob + case "[": + // swallow any state-tracking char before the [ + clearStateChar() + + if (inClass) { + re += "\\" + c + continue + } + + inClass = true + classStart = i + reClassStart = re.length + re += c + continue + + case "]": + // a right bracket shall lose its special + // meaning and represent itself in + // a bracket expression if it occurs + // first in the list. -- POSIX.2 2.8.3.2 + if (i === classStart + 1 || !inClass) { + re += "\\" + c + escaping = false + continue + } + + // finish up the class. + hasMagic = true + inClass = false + re += c + continue + + default: + // swallow any state char that wasn't consumed + clearStateChar() + + if (escaping) { + // no need + escaping = false + } else if (reSpecials[c] + && !(c === "^" && inClass)) { + re += "\\" + } + + re += c + + } // switch + } // for + + + // handle the case where we left a class open. + // "[abc" is valid, equivalent to "\[abc" + if (inClass) { + // split where the last [ was, and escape it + // this is a huge pita. We now have to re-walk + // the contents of the would-be class to re-translate + // any characters that were passed through as-is + var cs = pattern.substr(classStart + 1) + , sp = this.parse(cs, SUBPARSE) + re = re.substr(0, reClassStart) + "\\[" + sp[0] + hasMagic = hasMagic || sp[1] + } + + // handle the case where we had a +( thing at the *end* + // of the pattern. + // each pattern list stack adds 3 chars, and we need to go through + // 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. + var pl + while (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) { + if (!$2) { + // the | isn't already escaped, so escape it. + $2 = "\\" + } + + // need to escape all those slashes *again*, without escaping the + // one that we need for escaping the | character. As it works out, + // escaping an even number of slashes can be done by simply repeating + // it exactly after itself. That's why this trick works. + // + // I am sorry that you have to see this. + return $1 + $1 + $2 + "|" + }) + + this.debug("tail=%j\n %s", tail, tail) + var t = pl.type === "*" ? star + : pl.type === "?" ? qmark + : "\\" + pl.type + + hasMagic = true + re = re.slice(0, pl.reStart) + + t + "\\(" + + tail + } + + // handle trailing things that only matter at the very end. + clearStateChar() + if (escaping) { + // trailing \\ + re += "\\\\" + } + + // only need to apply the nodot start if the re starts with + // something that could conceivably capture a dot + var addPatternStart = false + switch (re.charAt(0)) { + case ".": + case "[": + case "(": addPatternStart = true + } + + // 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 (addPatternStart) re = patternStart + re + + // parsing just a piece of a larger pattern. + if (isSub === SUBPARSE) { + return [ re, hasMagic ] + } + + // skip the regexp for non-magical patterns + // unescape anything in it, though, so that it'll be + // an exact match against a file etc. + if (!hasMagic) { + return globUnescape(pattern) + } + + var flags = options.nocase ? "i" : "" + , regExp = new RegExp("^" + re + "$", flags) + + regExp._glob = pattern + regExp._src = re + + return regExp +} + +minimatch.makeRe = function (pattern, options) { + return new Minimatch(pattern, options || {}).makeRe() +} + +Minimatch.prototype.makeRe = makeRe +function makeRe () { + if (this.regexp || this.regexp === false) return this.regexp + + // at this point, this.set is a 2d array of partial + // pattern strings, or "**". + // + // It's better to use .match(). This function shouldn't + // be used, really, but it's pretty convenient sometimes, + // when you just want to work with a regex. + var set = this.set + + if (!set.length) return this.regexp = false + var options = this.options + + var twoStar = options.noglobstar ? star + : options.dot ? twoStarDot + : twoStarNoDot + , flags = options.nocase ? "i" : "" + + var re = set.map(function (pattern) { + return pattern.map(function (p) { + return (p === GLOBSTAR) ? twoStar + : (typeof p === "string") ? regExpEscape(p) + : p._src + }).join("\\\/") + }).join("|") + + // must match entire pattern + // ending in a * or ** will make it less strict. + re = "^(?:" + re + ")$" + + // can match anything, as long as it's not this. + if (this.negate) re = "^(?!" + re + ").*$" + + try { + return this.regexp = new RegExp(re, flags) + } catch (ex) { + return this.regexp = false + } +} + +minimatch.match = function (list, pattern, options) { + options = options || {} + var mm = new Minimatch(pattern, options) + list = list.filter(function (f) { + return mm.match(f) + }) + if (mm.options.nonull && !list.length) { + list.push(pattern) + } + return list +} + +Minimatch.prototype.match = match +function match (f, partial) { + this.debug("match", f, this.pattern) + // short-circuit in the case of busted things. + // comments, etc. + if (this.comment) return false + if (this.empty) return f === "" + + if (f === "/" && partial) return true + + var options = this.options + + // windows: need to use /, not \ + // On other platforms, \ is a valid (albeit bad) filename char. + if (platform === "win32") { + f = f.split("\\").join("/") + } + + // treat the test path as a set of pathparts. + f = f.split(slashSplit) + this.debug(this.pattern, "split", f) + + // just ONE of the pattern sets in this.set needs to match + // in order for it to be valid. If negating, then just one + // match means that we have failed. + // Either way, return on the first hit. + + var set = this.set + this.debug(this.pattern, "set", set) + + // Find the basename of the path by looking for the last non-empty segment + var filename; + for (var i = f.length - 1; i >= 0; i--) { + filename = f[i] + if (filename) break + } + + for (var i = 0, l = set.length; i < l; i ++) { + var pattern = set[i], file = f + if (options.matchBase && pattern.length === 1) { + file = [filename] + } + var hit = this.matchOne(file, pattern, partial) + if (hit) { + if (options.flipNegate) return true + return !this.negate + } + } + + // didn't get any hits. this is success if it's a negative + // pattern, failure otherwise. + if (options.flipNegate) return false + return this.negate +} + +// set partial to true to test if, for example, +// "/a/b" matches the start of "/*/b/*/d" +// Partial means, if you run out of file before you run +// out of pattern, then that's fine, as long as all +// the parts match. +Minimatch.prototype.matchOne = function (file, pattern, partial) { + var options = this.options + + this.debug("matchOne", + { "this": this + , file: file + , pattern: pattern }) + + this.debug("matchOne", file.length, pattern.length) + + for ( var fi = 0 + , pi = 0 + , fl = file.length + , pl = pattern.length + ; (fi < fl) && (pi < pl) + ; fi ++, pi ++ ) { + + this.debug("matchOne loop") + var p = pattern[pi] + , f = file[fi] + + this.debug(pattern, p, f) + + // should be impossible. + // some invalid regexp stuff in the set. + if (p === false) return false + + if (p === GLOBSTAR) { + this.debug('GLOBSTAR', [pattern, p, f]) + + // "**" + // a/**/b/**/c would match the following: + // a/b/x/y/z/c + // a/x/y/z/b/c + // a/b/x/b/x/c + // a/b/c + // To do this, take the rest of the pattern after + // the **, and see if it would match the file remainder. + // If so, return success. + // If not, the ** "swallows" a segment, and try again. + // This is recursively awful. + // + // a/**/b/**/c matching a/b/x/y/z/c + // - a matches a + // - doublestar + // - matchOne(b/x/y/z/c, b/**/c) + // - b matches b + // - doublestar + // - matchOne(x/y/z/c, c) -> no + // - matchOne(y/z/c, c) -> no + // - matchOne(z/c, c) -> no + // - matchOne(c, c) yes, hit + var fr = fi + , pr = pi + 1 + if (pr === pl) { + this.debug('** at the end') + // a ** at the end will just swallow the rest. + // We have found a match. + // however, it will not swallow /.x, unless + // options.dot is set. + // . and .. are *never* matched by **, for explosively + // exponential reasons. + for ( ; fi < fl; fi ++) { + if (file[fi] === "." || file[fi] === ".." || + (!options.dot && file[fi].charAt(0) === ".")) return false + } + return true + } + + // ok, let's see if we can swallow whatever we can. + WHILE: while (fr < fl) { + var swallowee = file[fr] + + this.debug('\nglobstar while', + file, fr, pattern, pr, swallowee) + + // XXX remove this slice. Just pass the start index. + if (this.matchOne(file.slice(fr), pattern.slice(pr), partial)) { + this.debug('globstar found match!', fr, fl, swallowee) + // found a match. + return true + } else { + // can't swallow "." or ".." ever. + // can only swallow ".foo" when explicitly asked. + if (swallowee === "." || swallowee === ".." || + (!options.dot && swallowee.charAt(0) === ".")) { + this.debug("dot detected!", file, fr, pattern, pr) + break WHILE + } + + // ** swallows a segment, and continue. + this.debug('globstar swallow a segment, and continue') + fr ++ + } + } + // no match was found. + // However, in partial mode, we can't say this is necessarily over. + // If there's more *pattern* left, then + if (partial) { + // ran out of file + this.debug("\n>>> no match, partial?", file, fr, pattern, pr) + if (fr === fl) return true + } + return false + } + + // something other than ** + // non-magic patterns just have to match exactly + // patterns with magic have been turned into regexps. + var hit + if (typeof p === "string") { + if (options.nocase) { + hit = f.toLowerCase() === p.toLowerCase() + } else { + hit = f === p + } + this.debug("string match", p, f, hit) + } else { + hit = f.match(p) + this.debug("pattern match", p, f, hit) + } + + if (!hit) return false + } + + // Note: ending in / means that we'll get a final "" + // at the end of the pattern. This can only match a + // corresponding "" at the end of the file. + // If the file ends in /, then it can only match a + // a pattern that ends in /, unless the pattern just + // doesn't have any more for it. But, a/b/ should *not* + // match "a/b/*", even though "" matches against the + // [^/]*? pattern, except in partial mode, where it might + // simply not be reached yet. + // However, a/b/ should still satisfy a/* + + // now either we fell off the end of the pattern, or we're done. + if (fi === fl && pi === pl) { + // ran out of pattern and filename at the same time. + // an exact hit! + return true + } else if (fi === fl) { + // ran out of file, but still had pattern left. + // this is ok if we're doing the match as part of + // a glob fs traversal. + return partial + } else if (pi === pl) { + // ran out of pattern, still have file left. + // this is only acceptable if we're on the very last + // empty segment of a file with a trailing slash. + // a/* should match a/b/ + var emptyFileEnd = (fi === fl - 1) && (file[fi] === "") + return emptyFileEnd + } + + // should be unreachable. + throw new Error("wtf?") +} + + +// replace stuff like \* with * +function globUnescape (s) { + return s.replace(/\\(.)/g, "$1") +} + + +function regExpEscape (s) { + return s.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, "\\$&") +} + +})( typeof require === "function" ? require : null, + this, + typeof module === "object" ? module : null, + typeof process === "object" ? process.platform : "win32" + ) diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/.npmignore b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/.npmignore new file mode 100644 index 0000000..07e6e47 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/.npmignore @@ -0,0 +1 @@ +/node_modules diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/CONTRIBUTORS b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/CONTRIBUTORS new file mode 100644 index 0000000..4a0bc50 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/CONTRIBUTORS @@ -0,0 +1,14 @@ +# Authors, sorted by whether or not they are me +Isaac Z. Schlueter +Brian Cottingham +Carlos Brito Lage +Jesse Dailey +Kevin O'Hara +Marco Rogers +Mark Cavage +Marko Mikulicic +Nathan Rajlich +Satheesh Natesan +Trent Mick +ashleybrener +n4kz diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/LICENSE b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/LICENSE new file mode 100644 index 0000000..05a4010 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/LICENSE @@ -0,0 +1,23 @@ +Copyright 2009, 2010, 2011 Isaac Z. Schlueter. +All rights reserved. + +Permission is hereby granted, free of charge, to any person +obtaining a copy of this software and associated documentation +files (the "Software"), to deal in the Software without +restriction, including without limitation the rights to use, +copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the +Software is furnished to do so, subject to the following +conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES +OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT +HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR +OTHER DEALINGS IN THE SOFTWARE. diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/README.md b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/README.md new file mode 100644 index 0000000..03ee0f9 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/README.md @@ -0,0 +1,97 @@ +# lru cache + +A cache object that deletes the least-recently-used items. + +## Usage: + +```javascript +var LRU = require("lru-cache") + , options = { max: 500 + , length: function (n) { return n * 2 } + , dispose: function (key, n) { n.close() } + , maxAge: 1000 * 60 * 60 } + , cache = LRU(options) + , otherCache = LRU(50) // sets just the max size + +cache.set("key", "value") +cache.get("key") // "value" + +cache.reset() // empty the cache +``` + +If you put more stuff in it, then items will fall out. + +If you try to put an oversized thing in it, then it'll fall out right +away. + +## Options + +* `max` The maximum size of the cache, checked by applying the length + function to all values in the cache. Not setting this is kind of + silly, since that's the whole purpose of this lib, but it defaults + to `Infinity`. +* `maxAge` Maximum age in ms. Items are not pro-actively pruned out + as they age, but if you try to get an item that is too old, it'll + drop it and return undefined instead of giving it to you. +* `length` Function that is used to calculate the length of stored + items. If you're storing strings or buffers, then you probably want + to do something like `function(n){return n.length}`. The default is + `function(n){return 1}`, which is fine if you want to store `n` + like-sized things. +* `dispose` Function that is called on items when they are dropped + from the cache. This can be handy if you want to close file + descriptors or do other cleanup tasks when items are no longer + accessible. Called with `key, value`. It's called *before* + actually removing the item from the internal cache, so if you want + to immediately put it back in, you'll have to do that in a + `nextTick` or `setTimeout` callback or it won't do anything. +* `stale` By default, if you set a `maxAge`, it'll only actually pull + stale items out of the cache when you `get(key)`. (That is, it's + not pre-emptively doing a `setTimeout` or anything.) If you set + `stale:true`, it'll return the stale value before deleting it. If + you don't set this, then it'll return `undefined` when you try to + get a stale entry, as if it had already been deleted. + +## API + +* `set(key, value)` +* `get(key) => value` + + Both of these will update the "recently used"-ness of the key. + They do what you think. + +* `peek(key)` + + Returns the key value (or `undefined` if not found) without + updating the "recently used"-ness of the key. + + (If you find yourself using this a lot, you *might* be using the + wrong sort of data structure, but there are some use cases where + it's handy.) + +* `del(key)` + + Deletes a key out of the cache. + +* `reset()` + + Clear the cache entirely, throwing away all values. + +* `has(key)` + + Check if a key is in the cache, without updating the recent-ness + or deleting it for being stale. + +* `forEach(function(value,key,cache), [thisp])` + + Just like `Array.prototype.forEach`. Iterates over all the keys + in the cache, in order of recent-ness. (Ie, more recently used + items are iterated over first.) + +* `keys()` + + Return an array of the keys in the cache. + +* `values()` + + Return an array of the values in the cache. diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/lib/lru-cache.js b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/lib/lru-cache.js new file mode 100644 index 0000000..d1d1381 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/lib/lru-cache.js @@ -0,0 +1,252 @@ +;(function () { // closure for web browsers + +if (typeof module === 'object' && module.exports) { + module.exports = LRUCache +} else { + // just set the global for non-node platforms. + this.LRUCache = LRUCache +} + +function hOP (obj, key) { + return Object.prototype.hasOwnProperty.call(obj, key) +} + +function naiveLength () { return 1 } + +function LRUCache (options) { + if (!(this instanceof LRUCache)) + return new LRUCache(options) + + if (typeof options === 'number') + options = { max: options } + + if (!options) + options = {} + + this._max = options.max + // Kind of weird to have a default max of Infinity, but oh well. + if (!this._max || !(typeof this._max === "number") || this._max <= 0 ) + this._max = Infinity + + this._lengthCalculator = options.length || naiveLength + if (typeof this._lengthCalculator !== "function") + this._lengthCalculator = naiveLength + + this._allowStale = options.stale || false + this._maxAge = options.maxAge || null + this._dispose = options.dispose + this.reset() +} + +// resize the cache when the max changes. +Object.defineProperty(LRUCache.prototype, "max", + { set : function (mL) { + if (!mL || !(typeof mL === "number") || mL <= 0 ) mL = Infinity + this._max = mL + if (this._length > this._max) trim(this) + } + , get : function () { return this._max } + , enumerable : true + }) + +// resize the cache when the lengthCalculator changes. +Object.defineProperty(LRUCache.prototype, "lengthCalculator", + { set : function (lC) { + if (typeof lC !== "function") { + this._lengthCalculator = naiveLength + this._length = this._itemCount + for (var key in this._cache) { + this._cache[key].length = 1 + } + } else { + this._lengthCalculator = lC + this._length = 0 + for (var key in this._cache) { + this._cache[key].length = this._lengthCalculator(this._cache[key].value) + this._length += this._cache[key].length + } + } + + if (this._length > this._max) trim(this) + } + , get : function () { return this._lengthCalculator } + , enumerable : true + }) + +Object.defineProperty(LRUCache.prototype, "length", + { get : function () { return this._length } + , enumerable : true + }) + + +Object.defineProperty(LRUCache.prototype, "itemCount", + { get : function () { return this._itemCount } + , enumerable : true + }) + +LRUCache.prototype.forEach = function (fn, thisp) { + thisp = thisp || this + var i = 0; + for (var k = this._mru - 1; k >= 0 && i < this._itemCount; k--) if (this._lruList[k]) { + i++ + var hit = this._lruList[k] + if (this._maxAge && (Date.now() - hit.now > this._maxAge)) { + del(this, hit) + if (!this._allowStale) hit = undefined + } + if (hit) { + fn.call(thisp, hit.value, hit.key, this) + } + } +} + +LRUCache.prototype.keys = function () { + var keys = new Array(this._itemCount) + var i = 0 + for (var k = this._mru - 1; k >= 0 && i < this._itemCount; k--) if (this._lruList[k]) { + var hit = this._lruList[k] + keys[i++] = hit.key + } + return keys +} + +LRUCache.prototype.values = function () { + var values = new Array(this._itemCount) + var i = 0 + for (var k = this._mru - 1; k >= 0 && i < this._itemCount; k--) if (this._lruList[k]) { + var hit = this._lruList[k] + values[i++] = hit.value + } + return values +} + +LRUCache.prototype.reset = function () { + if (this._dispose && this._cache) { + for (var k in this._cache) { + this._dispose(k, this._cache[k].value) + } + } + + this._cache = Object.create(null) // hash of items by key + this._lruList = Object.create(null) // list of items in order of use recency + this._mru = 0 // most recently used + this._lru = 0 // least recently used + this._length = 0 // number of items in the list + this._itemCount = 0 +} + +// Provided for debugging/dev purposes only. No promises whatsoever that +// this API stays stable. +LRUCache.prototype.dump = function () { + return this._cache +} + +LRUCache.prototype.dumpLru = function () { + return this._lruList +} + +LRUCache.prototype.set = function (key, value) { + if (hOP(this._cache, key)) { + // dispose of the old one before overwriting + if (this._dispose) this._dispose(key, this._cache[key].value) + if (this._maxAge) this._cache[key].now = Date.now() + this._cache[key].value = value + this.get(key) + return true + } + + var len = this._lengthCalculator(value) + var age = this._maxAge ? Date.now() : 0 + var hit = new Entry(key, value, this._mru++, len, age) + + // oversized objects fall out of cache automatically. + if (hit.length > this._max) { + if (this._dispose) this._dispose(key, value) + return false + } + + this._length += hit.length + this._lruList[hit.lu] = this._cache[key] = hit + this._itemCount ++ + + if (this._length > this._max) trim(this) + return true +} + +LRUCache.prototype.has = function (key) { + if (!hOP(this._cache, key)) return false + var hit = this._cache[key] + if (this._maxAge && (Date.now() - hit.now > this._maxAge)) { + return false + } + return true +} + +LRUCache.prototype.get = function (key) { + return get(this, key, true) +} + +LRUCache.prototype.peek = function (key) { + return get(this, key, false) +} + +LRUCache.prototype.pop = function () { + var hit = this._lruList[this._lru] + del(this, hit) + return hit || null +} + +LRUCache.prototype.del = function (key) { + del(this, this._cache[key]) +} + +function get (self, key, doUse) { + var hit = self._cache[key] + if (hit) { + if (self._maxAge && (Date.now() - hit.now > self._maxAge)) { + del(self, hit) + if (!self._allowStale) hit = undefined + } else { + if (doUse) use(self, hit) + } + if (hit) hit = hit.value + } + return hit +} + +function use (self, hit) { + shiftLU(self, hit) + hit.lu = self._mru ++ + self._lruList[hit.lu] = hit +} + +function trim (self) { + while (self._lru < self._mru && self._length > self._max) + del(self, self._lruList[self._lru]) +} + +function shiftLU (self, hit) { + delete self._lruList[ hit.lu ] + while (self._lru < self._mru && !self._lruList[self._lru]) self._lru ++ +} + +function del (self, hit) { + if (hit) { + if (self._dispose) self._dispose(hit.key, hit.value) + self._length -= hit.length + self._itemCount -- + delete self._cache[ hit.key ] + shiftLU(self, hit) + } +} + +// classy, since V8 prefers predictable objects. +function Entry (key, value, lu, length, now) { + this.key = key + this.value = value + this.lu = lu + this.length = length + this.now = now +} + +})() diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/package.json b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/package.json new file mode 100644 index 0000000..4472725 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/package.json @@ -0,0 +1,33 @@ +{ + "name": "lru-cache", + "description": "A cache object that deletes the least-recently-used items.", + "version": "2.5.0", + "author": { + "name": "Isaac Z. Schlueter", + "email": "i@izs.me" + }, + "scripts": { + "test": "tap test --gc" + }, + "main": "lib/lru-cache.js", + "repository": { + "type": "git", + "url": "git://github.com/isaacs/node-lru-cache.git" + }, + "devDependencies": { + "tap": "", + "weak": "" + }, + "license": { + "type": "MIT", + "url": "http://github.com/isaacs/node-lru-cache/raw/master/LICENSE" + }, + "readme": "# lru cache\n\nA cache object that deletes the least-recently-used items.\n\n## Usage:\n\n```javascript\nvar LRU = require(\"lru-cache\")\n , options = { max: 500\n , length: function (n) { return n * 2 }\n , dispose: function (key, n) { n.close() }\n , maxAge: 1000 * 60 * 60 }\n , cache = LRU(options)\n , otherCache = LRU(50) // sets just the max size\n\ncache.set(\"key\", \"value\")\ncache.get(\"key\") // \"value\"\n\ncache.reset() // empty the cache\n```\n\nIf you put more stuff in it, then items will fall out.\n\nIf you try to put an oversized thing in it, then it'll fall out right\naway.\n\n## Options\n\n* `max` The maximum size of the cache, checked by applying the length\n function to all values in the cache. Not setting this is kind of\n silly, since that's the whole purpose of this lib, but it defaults\n to `Infinity`.\n* `maxAge` Maximum age in ms. Items are not pro-actively pruned out\n as they age, but if you try to get an item that is too old, it'll\n drop it and return undefined instead of giving it to you.\n* `length` Function that is used to calculate the length of stored\n items. If you're storing strings or buffers, then you probably want\n to do something like `function(n){return n.length}`. The default is\n `function(n){return 1}`, which is fine if you want to store `n`\n like-sized things.\n* `dispose` Function that is called on items when they are dropped\n from the cache. This can be handy if you want to close file\n descriptors or do other cleanup tasks when items are no longer\n accessible. Called with `key, value`. It's called *before*\n actually removing the item from the internal cache, so if you want\n to immediately put it back in, you'll have to do that in a\n `nextTick` or `setTimeout` callback or it won't do anything.\n* `stale` By default, if you set a `maxAge`, it'll only actually pull\n stale items out of the cache when you `get(key)`. (That is, it's\n not pre-emptively doing a `setTimeout` or anything.) If you set\n `stale:true`, it'll return the stale value before deleting it. If\n you don't set this, then it'll return `undefined` when you try to\n get a stale entry, as if it had already been deleted.\n\n## API\n\n* `set(key, value)`\n* `get(key) => value`\n\n Both of these will update the \"recently used\"-ness of the key.\n They do what you think.\n\n* `peek(key)`\n\n Returns the key value (or `undefined` if not found) without\n updating the \"recently used\"-ness of the key.\n\n (If you find yourself using this a lot, you *might* be using the\n wrong sort of data structure, but there are some use cases where\n it's handy.)\n\n* `del(key)`\n\n Deletes a key out of the cache.\n\n* `reset()`\n\n Clear the cache entirely, throwing away all values.\n\n* `has(key)`\n\n Check if a key is in the cache, without updating the recent-ness\n or deleting it for being stale.\n\n* `forEach(function(value,key,cache), [thisp])`\n\n Just like `Array.prototype.forEach`. Iterates over all the keys\n in the cache, in order of recent-ness. (Ie, more recently used\n items are iterated over first.)\n\n* `keys()`\n\n Return an array of the keys in the cache.\n\n* `values()`\n\n Return an array of the values in the cache.\n", + "readmeFilename": "README.md", + "bugs": { + "url": "https://github.com/isaacs/node-lru-cache/issues" + }, + "homepage": "https://github.com/isaacs/node-lru-cache", + "_id": "lru-cache@2.5.0", + "_from": "lru-cache@2" +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/test/basic.js b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/test/basic.js new file mode 100644 index 0000000..f72697c --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/test/basic.js @@ -0,0 +1,369 @@ +var test = require("tap").test + , LRU = require("../") + +test("basic", function (t) { + var cache = new LRU({max: 10}) + cache.set("key", "value") + t.equal(cache.get("key"), "value") + t.equal(cache.get("nada"), undefined) + t.equal(cache.length, 1) + t.equal(cache.max, 10) + t.end() +}) + +test("least recently set", function (t) { + var cache = new LRU(2) + cache.set("a", "A") + cache.set("b", "B") + cache.set("c", "C") + t.equal(cache.get("c"), "C") + t.equal(cache.get("b"), "B") + t.equal(cache.get("a"), undefined) + t.end() +}) + +test("lru recently gotten", function (t) { + var cache = new LRU(2) + cache.set("a", "A") + cache.set("b", "B") + cache.get("a") + cache.set("c", "C") + t.equal(cache.get("c"), "C") + t.equal(cache.get("b"), undefined) + t.equal(cache.get("a"), "A") + t.end() +}) + +test("del", function (t) { + var cache = new LRU(2) + cache.set("a", "A") + cache.del("a") + t.equal(cache.get("a"), undefined) + t.end() +}) + +test("max", function (t) { + var cache = new LRU(3) + + // test changing the max, verify that the LRU items get dropped. + cache.max = 100 + for (var i = 0; i < 100; i ++) cache.set(i, i) + t.equal(cache.length, 100) + for (var i = 0; i < 100; i ++) { + t.equal(cache.get(i), i) + } + cache.max = 3 + t.equal(cache.length, 3) + for (var i = 0; i < 97; i ++) { + t.equal(cache.get(i), undefined) + } + for (var i = 98; i < 100; i ++) { + t.equal(cache.get(i), i) + } + + // now remove the max restriction, and try again. + cache.max = "hello" + for (var i = 0; i < 100; i ++) cache.set(i, i) + t.equal(cache.length, 100) + for (var i = 0; i < 100; i ++) { + t.equal(cache.get(i), i) + } + // should trigger an immediate resize + cache.max = 3 + t.equal(cache.length, 3) + for (var i = 0; i < 97; i ++) { + t.equal(cache.get(i), undefined) + } + for (var i = 98; i < 100; i ++) { + t.equal(cache.get(i), i) + } + t.end() +}) + +test("reset", function (t) { + var cache = new LRU(10) + cache.set("a", "A") + cache.set("b", "B") + cache.reset() + t.equal(cache.length, 0) + t.equal(cache.max, 10) + t.equal(cache.get("a"), undefined) + t.equal(cache.get("b"), undefined) + t.end() +}) + + +// Note: `.dump()` is a debugging tool only. No guarantees are made +// about the format/layout of the response. +test("dump", function (t) { + var cache = new LRU(10) + var d = cache.dump(); + t.equal(Object.keys(d).length, 0, "nothing in dump for empty cache") + cache.set("a", "A") + var d = cache.dump() // { a: { key: "a", value: "A", lu: 0 } } + t.ok(d.a) + t.equal(d.a.key, "a") + t.equal(d.a.value, "A") + t.equal(d.a.lu, 0) + + cache.set("b", "B") + cache.get("b") + d = cache.dump() + t.ok(d.b) + t.equal(d.b.key, "b") + t.equal(d.b.value, "B") + t.equal(d.b.lu, 2) + + t.end() +}) + + +test("basic with weighed length", function (t) { + var cache = new LRU({ + max: 100, + length: function (item) { return item.size } + }) + cache.set("key", {val: "value", size: 50}) + t.equal(cache.get("key").val, "value") + t.equal(cache.get("nada"), undefined) + t.equal(cache.lengthCalculator(cache.get("key")), 50) + t.equal(cache.length, 50) + t.equal(cache.max, 100) + t.end() +}) + + +test("weighed length item too large", function (t) { + var cache = new LRU({ + max: 10, + length: function (item) { return item.size } + }) + t.equal(cache.max, 10) + + // should fall out immediately + cache.set("key", {val: "value", size: 50}) + + t.equal(cache.length, 0) + t.equal(cache.get("key"), undefined) + t.end() +}) + +test("least recently set with weighed length", function (t) { + var cache = new LRU({ + max:8, + length: function (item) { return item.length } + }) + cache.set("a", "A") + cache.set("b", "BB") + cache.set("c", "CCC") + cache.set("d", "DDDD") + t.equal(cache.get("d"), "DDDD") + t.equal(cache.get("c"), "CCC") + t.equal(cache.get("b"), undefined) + t.equal(cache.get("a"), undefined) + t.end() +}) + +test("lru recently gotten with weighed length", function (t) { + var cache = new LRU({ + max: 8, + length: function (item) { return item.length } + }) + cache.set("a", "A") + cache.set("b", "BB") + cache.set("c", "CCC") + cache.get("a") + cache.get("b") + cache.set("d", "DDDD") + t.equal(cache.get("c"), undefined) + t.equal(cache.get("d"), "DDDD") + t.equal(cache.get("b"), "BB") + t.equal(cache.get("a"), "A") + t.end() +}) + +test("set returns proper booleans", function(t) { + var cache = new LRU({ + max: 5, + length: function (item) { return item.length } + }) + + t.equal(cache.set("a", "A"), true) + + // should return false for max exceeded + t.equal(cache.set("b", "donuts"), false) + + t.equal(cache.set("b", "B"), true) + t.equal(cache.set("c", "CCCC"), true) + t.end() +}) + +test("drop the old items", function(t) { + var cache = new LRU({ + max: 5, + maxAge: 50 + }) + + cache.set("a", "A") + + setTimeout(function () { + cache.set("b", "b") + t.equal(cache.get("a"), "A") + }, 25) + + setTimeout(function () { + cache.set("c", "C") + // timed out + t.notOk(cache.get("a")) + }, 60) + + setTimeout(function () { + t.notOk(cache.get("b")) + t.equal(cache.get("c"), "C") + }, 90) + + setTimeout(function () { + t.notOk(cache.get("c")) + t.end() + }, 155) +}) + +test("disposal function", function(t) { + var disposed = false + var cache = new LRU({ + max: 1, + dispose: function (k, n) { + disposed = n + } + }) + + cache.set(1, 1) + cache.set(2, 2) + t.equal(disposed, 1) + cache.set(3, 3) + t.equal(disposed, 2) + cache.reset() + t.equal(disposed, 3) + t.end() +}) + +test("disposal function on too big of item", function(t) { + var disposed = false + var cache = new LRU({ + max: 1, + length: function (k) { + return k.length + }, + dispose: function (k, n) { + disposed = n + } + }) + var obj = [ 1, 2 ] + + t.equal(disposed, false) + cache.set("obj", obj) + t.equal(disposed, obj) + t.end() +}) + +test("has()", function(t) { + var cache = new LRU({ + max: 1, + maxAge: 10 + }) + + cache.set('foo', 'bar') + t.equal(cache.has('foo'), true) + cache.set('blu', 'baz') + t.equal(cache.has('foo'), false) + t.equal(cache.has('blu'), true) + setTimeout(function() { + t.equal(cache.has('blu'), false) + t.end() + }, 15) +}) + +test("stale", function(t) { + var cache = new LRU({ + maxAge: 10, + stale: true + }) + + cache.set('foo', 'bar') + t.equal(cache.get('foo'), 'bar') + t.equal(cache.has('foo'), true) + setTimeout(function() { + t.equal(cache.has('foo'), false) + t.equal(cache.get('foo'), 'bar') + t.equal(cache.get('foo'), undefined) + t.end() + }, 15) +}) + +test("lru update via set", function(t) { + var cache = LRU({ max: 2 }); + + cache.set('foo', 1); + cache.set('bar', 2); + cache.del('bar'); + cache.set('baz', 3); + cache.set('qux', 4); + + t.equal(cache.get('foo'), undefined) + t.equal(cache.get('bar'), undefined) + t.equal(cache.get('baz'), 3) + t.equal(cache.get('qux'), 4) + t.end() +}) + +test("least recently set w/ peek", function (t) { + var cache = new LRU(2) + cache.set("a", "A") + cache.set("b", "B") + t.equal(cache.peek("a"), "A") + cache.set("c", "C") + t.equal(cache.get("c"), "C") + t.equal(cache.get("b"), "B") + t.equal(cache.get("a"), undefined) + t.end() +}) + +test("pop the least used item", function (t) { + var cache = new LRU(3) + , last + + cache.set("a", "A") + cache.set("b", "B") + cache.set("c", "C") + + t.equal(cache.length, 3) + t.equal(cache.max, 3) + + // Ensure we pop a, c, b + cache.get("b", "B") + + last = cache.pop() + t.equal(last.key, "a") + t.equal(last.value, "A") + t.equal(cache.length, 2) + t.equal(cache.max, 3) + + last = cache.pop() + t.equal(last.key, "c") + t.equal(last.value, "C") + t.equal(cache.length, 1) + t.equal(cache.max, 3) + + last = cache.pop() + t.equal(last.key, "b") + t.equal(last.value, "B") + t.equal(cache.length, 0) + t.equal(cache.max, 3) + + last = cache.pop() + t.equal(last, null) + t.equal(cache.length, 0) + t.equal(cache.max, 3) + + t.end() +}) diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/test/foreach.js b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/test/foreach.js new file mode 100644 index 0000000..eefb80d --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/test/foreach.js @@ -0,0 +1,52 @@ +var test = require('tap').test +var LRU = require('../') + +test('forEach', function (t) { + var l = new LRU(5) + for (var i = 0; i < 10; i ++) { + l.set(i.toString(), i.toString(2)) + } + + var i = 9 + l.forEach(function (val, key, cache) { + t.equal(cache, l) + t.equal(key, i.toString()) + t.equal(val, i.toString(2)) + i -= 1 + }) + + // get in order of most recently used + l.get(6) + l.get(8) + + var order = [ 8, 6, 9, 7, 5 ] + var i = 0 + + l.forEach(function (val, key, cache) { + var j = order[i ++] + t.equal(cache, l) + t.equal(key, j.toString()) + t.equal(val, j.toString(2)) + }) + + t.end() +}) + +test('keys() and values()', function (t) { + var l = new LRU(5) + for (var i = 0; i < 10; i ++) { + l.set(i.toString(), i.toString(2)) + } + + t.similar(l.keys(), ['9', '8', '7', '6', '5']) + t.similar(l.values(), ['1001', '1000', '111', '110', '101']) + + // get in order of most recently used + l.get(6) + l.get(8) + + t.similar(l.keys(), ['8', '6', '9', '7', '5']) + t.similar(l.values(), ['1000', '110', '1001', '111', '101']) + + t.end() +}) diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/test/memory-leak.js b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/test/memory-leak.js new file mode 100644 index 0000000..7af45b0 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/lru-cache/test/memory-leak.js @@ -0,0 +1,50 @@ +#!/usr/bin/env node --expose_gc + +var weak = require('weak'); +var test = require('tap').test +var LRU = require('../') +var l = new LRU({ max: 10 }) +var refs = 0 +function X() { + refs ++ + weak(this, deref) +} + +function deref() { + refs -- +} + +test('no leaks', function (t) { + // fill up the cache + for (var i = 0; i < 100; i++) { + l.set(i, new X); + // throw some gets in there, too. + if (i % 2 === 0) + l.get(i / 2) + } + + gc() + + var start = process.memoryUsage() + + // capture the memory + var startRefs = refs + + // do it again, but more + for (var i = 0; i < 10000; i++) { + l.set(i, new X); + // throw some gets in there, too. + if (i % 2 === 0) + l.get(i / 2) + } + + gc() + + var end = process.memoryUsage() + t.equal(refs, startRefs, 'no leaky refs') + + console.error('start: %j\n' + + 'end: %j', start, end); + t.pass(); + t.end(); +}) diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/sigmund/LICENSE b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/sigmund/LICENSE new file mode 100644 index 0000000..0c44ae7 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/sigmund/LICENSE @@ -0,0 +1,27 @@ +Copyright (c) Isaac Z. Schlueter ("Author") +All rights reserved. + +The BSD License + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions +are met: + +1. Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + +2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + +THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS +BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR +CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF +SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR +BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, +WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE +OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN +IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/sigmund/README.md b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/sigmund/README.md new file mode 100644 index 0000000..7e36512 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/sigmund/README.md @@ -0,0 +1,53 @@ +# sigmund + +Quick and dirty signatures for Objects. + +This is like a much faster `deepEquals` comparison, which returns a +string key suitable for caches and the like. + +## Usage + +```javascript +function doSomething (someObj) { + var key = sigmund(someObj, maxDepth) // max depth defaults to 10 + var cached = cache.get(key) + if (cached) return cached) + + var result = expensiveCalculation(someObj) + cache.set(key, result) + return result +} +``` + +The resulting key will be as unique and reproducible as calling +`JSON.stringify` or `util.inspect` on the object, but is much faster. +In order to achieve this speed, some differences are glossed over. +For example, the object `{0:'foo'}` will be treated identically to the +array `['foo']`. + +Also, just as there is no way to summon the soul from the scribblings +of a cocain-addled psychoanalyst, there is no way to revive the object +from the signature string that sigmund gives you. In fact, it's +barely even readable. + +As with `sys.inspect` and `JSON.stringify`, larger objects will +produce larger signature strings. + +Because sigmund is a bit less strict than the more thorough +alternatives, the strings will be shorter, and also there is a +slightly higher chance for collisions. For example, these objects +have the same signature: + + var obj1 = {a:'b',c:/def/,g:['h','i',{j:'',k:'l'}]} + var obj2 = {a:'b',c:'/def/',g:['h','i','{jkl']} + +Like a good Freudian, sigmund is most effective when you already have +some understanding of what you're looking for. It can help you help +yourself, but you must be willing to do some work as well. + +Cycles are handled, and cyclical objects are silently omitted (though +the key is included in the signature output.) + +The second argument is the maximum depth, which defaults to 10, +because that is the maximum object traversal depth covered by most +insurance carriers. diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/sigmund/bench.js b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/sigmund/bench.js new file mode 100644 index 0000000..5acfd6d --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/sigmund/bench.js @@ -0,0 +1,283 @@ +// different ways to id objects +// use a req/res pair, since it's crazy deep and cyclical + +// sparseFE10 and sigmund are usually pretty close, which is to be expected, +// since they are essentially the same algorithm, except that sigmund handles +// regular expression objects properly. + + +var http = require('http') +var util = require('util') +var sigmund = require('./sigmund.js') +var sreq, sres, creq, cres, test + +http.createServer(function (q, s) { + sreq = q + sres = s + sres.end('ok') + this.close(function () { setTimeout(function () { + start() + }, 200) }) +}).listen(1337, function () { + creq = http.get({ port: 1337 }) + creq.on('response', function (s) { cres = s }) +}) + +function start () { + test = [sreq, sres, creq, cres] + // test = sreq + // sreq.sres = sres + // sreq.creq = creq + // sreq.cres = cres + + for (var i in exports.compare) { + console.log(i) + var hash = exports.compare[i]() + console.log(hash) + console.log(hash.length) + console.log('') + } + + require('bench').runMain() +} + +function customWs (obj, md, d) { + d = d || 0 + var to = typeof obj + if (to === 'undefined' || to === 'function' || to === null) return '' + if (d > md || !obj || to !== 'object') return ('' + obj).replace(/[\n ]+/g, '') + + if (Array.isArray(obj)) { + return obj.map(function (i, _, __) { + return customWs(i, md, d + 1) + }).reduce(function (a, b) { return a + b }, '') + } + + var keys = Object.keys(obj) + return keys.map(function (k, _, __) { + return k + ':' + customWs(obj[k], md, d + 1) + }).reduce(function (a, b) { return a + b }, '') +} + +function custom (obj, md, d) { + d = d || 0 + var to = typeof obj + if (to === 'undefined' || to === 'function' || to === null) return '' + if (d > md || !obj || to !== 'object') return '' + obj + + if (Array.isArray(obj)) { + return obj.map(function (i, _, __) { + return custom(i, md, d + 1) + }).reduce(function (a, b) { return a + b }, '') + } + + var keys = Object.keys(obj) + return keys.map(function (k, _, __) { + return k + ':' + custom(obj[k], md, d + 1) + }).reduce(function (a, b) { return a + b }, '') +} + +function sparseFE2 (obj, maxDepth) { + var seen = [] + var soFar = '' + function ch (v, depth) { + if (depth > maxDepth) return + if (typeof v === 'function' || typeof v === 'undefined') return + if (typeof v !== 'object' || !v) { + soFar += v + return + } + if (seen.indexOf(v) !== -1 || depth === maxDepth) return + seen.push(v) + soFar += '{' + Object.keys(v).forEach(function (k, _, __) { + // pseudo-private values. skip those. + if (k.charAt(0) === '_') return + var to = typeof v[k] + if (to === 'function' || to === 'undefined') return + soFar += k + ':' + ch(v[k], depth + 1) + }) + soFar += '}' + } + ch(obj, 0) + return soFar +} + +function sparseFE (obj, maxDepth) { + var seen = [] + var soFar = '' + function ch (v, depth) { + if (depth > maxDepth) return + if (typeof v === 'function' || typeof v === 'undefined') return + if (typeof v !== 'object' || !v) { + soFar += v + return + } + if (seen.indexOf(v) !== -1 || depth === maxDepth) return + seen.push(v) + soFar += '{' + Object.keys(v).forEach(function (k, _, __) { + // pseudo-private values. skip those. + if (k.charAt(0) === '_') return + var to = typeof v[k] + if (to === 'function' || to === 'undefined') return + soFar += k + ch(v[k], depth + 1) + }) + } + ch(obj, 0) + return soFar +} + +function sparse (obj, maxDepth) { + var seen = [] + var soFar = '' + function ch (v, depth) { + if (depth > maxDepth) return + if (typeof v === 'function' || typeof v === 'undefined') return + if (typeof v !== 'object' || !v) { + soFar += v + return + } + if (seen.indexOf(v) !== -1 || depth === maxDepth) return + seen.push(v) + soFar += '{' + for (var k in v) { + // pseudo-private values. skip those. + if (k.charAt(0) === '_') continue + var to = typeof v[k] + if (to === 'function' || to === 'undefined') continue + soFar += k + ch(v[k], depth + 1) + } + } + ch(obj, 0) + return soFar +} + +function noCommas (obj, maxDepth) { + var seen = [] + var soFar = '' + function ch (v, depth) { + if (depth > maxDepth) return + if (typeof v === 'function' || typeof v === 'undefined') return + if (typeof v !== 'object' || !v) { + soFar += v + return + } + if (seen.indexOf(v) !== -1 || depth === maxDepth) return + seen.push(v) + soFar += '{' + for (var k in v) { + // pseudo-private values. skip those. + if (k.charAt(0) === '_') continue + var to = typeof v[k] + if (to === 'function' || to === 'undefined') continue + soFar += k + ':' + ch(v[k], depth + 1) + } + soFar += '}' + } + ch(obj, 0) + return soFar +} + + +function flatten (obj, maxDepth) { + var seen = [] + var soFar = '' + function ch (v, depth) { + if (depth > maxDepth) return + if (typeof v === 'function' || typeof v === 'undefined') return + if (typeof v !== 'object' || !v) { + soFar += v + return + } + if (seen.indexOf(v) !== -1 || depth === maxDepth) return + seen.push(v) + soFar += '{' + for (var k in v) { + // pseudo-private values. skip those. + if (k.charAt(0) === '_') continue + var to = typeof v[k] + if (to === 'function' || to === 'undefined') continue + soFar += k + ':' + ch(v[k], depth + 1) + soFar += ',' + } + soFar += '}' + } + ch(obj, 0) + return soFar +} + +exports.compare = +{ + // 'custom 2': function () { + // return custom(test, 2, 0) + // }, + // 'customWs 2': function () { + // return customWs(test, 2, 0) + // }, + 'JSON.stringify (guarded)': function () { + var seen = [] + return JSON.stringify(test, function (k, v) { + if (typeof v !== 'object' || !v) return v + if (seen.indexOf(v) !== -1) return undefined + seen.push(v) + return v + }) + }, + + 'flatten 10': function () { + return flatten(test, 10) + }, + + // 'flattenFE 10': function () { + // return flattenFE(test, 10) + // }, + + 'noCommas 10': function () { + return noCommas(test, 10) + }, + + 'sparse 10': function () { + return sparse(test, 10) + }, + + 'sparseFE 10': function () { + return sparseFE(test, 10) + }, + + 'sparseFE2 10': function () { + return sparseFE2(test, 10) + }, + + sigmund: function() { + return sigmund(test, 10) + }, + + + // 'util.inspect 1': function () { + // return util.inspect(test, false, 1, false) + // }, + // 'util.inspect undefined': function () { + // util.inspect(test) + // }, + // 'util.inspect 2': function () { + // util.inspect(test, false, 2, false) + // }, + // 'util.inspect 3': function () { + // util.inspect(test, false, 3, false) + // }, + // 'util.inspect 4': function () { + // util.inspect(test, false, 4, false) + // }, + // 'util.inspect Infinity': function () { + // util.inspect(test, false, Infinity, false) + // } +} + +/** results +**/ diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/sigmund/package.json b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/sigmund/package.json new file mode 100644 index 0000000..cb7e2bd --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/sigmund/package.json @@ -0,0 +1,42 @@ +{ + "name": "sigmund", + "version": "1.0.0", + "description": "Quick and dirty signatures for Objects.", + "main": "sigmund.js", + "directories": { + "test": "test" + }, + "dependencies": {}, + "devDependencies": { + "tap": "~0.3.0" + }, + "scripts": { + "test": "tap test/*.js", + "bench": "node bench.js" + }, + "repository": { + "type": "git", + "url": "git://github.com/isaacs/sigmund" + }, + "keywords": [ + "object", + "signature", + "key", + "data", + "psychoanalysis" + ], + "author": { + "name": "Isaac Z. Schlueter", + "email": "i@izs.me", + "url": "http://blog.izs.me/" + }, + "license": "BSD", + "readme": "# sigmund\n\nQuick and dirty signatures for Objects.\n\nThis is like a much faster `deepEquals` comparison, which returns a\nstring key suitable for caches and the like.\n\n## Usage\n\n```javascript\nfunction doSomething (someObj) {\n var key = sigmund(someObj, maxDepth) // max depth defaults to 10\n var cached = cache.get(key)\n if (cached) return cached)\n\n var result = expensiveCalculation(someObj)\n cache.set(key, result)\n return result\n}\n```\n\nThe resulting key will be as unique and reproducible as calling\n`JSON.stringify` or `util.inspect` on the object, but is much faster.\nIn order to achieve this speed, some differences are glossed over.\nFor example, the object `{0:'foo'}` will be treated identically to the\narray `['foo']`.\n\nAlso, just as there is no way to summon the soul from the scribblings\nof a cocain-addled psychoanalyst, there is no way to revive the object\nfrom the signature string that sigmund gives you. In fact, it's\nbarely even readable.\n\nAs with `sys.inspect` and `JSON.stringify`, larger objects will\nproduce larger signature strings.\n\nBecause sigmund is a bit less strict than the more thorough\nalternatives, the strings will be shorter, and also there is a\nslightly higher chance for collisions. For example, these objects\nhave the same signature:\n\n var obj1 = {a:'b',c:/def/,g:['h','i',{j:'',k:'l'}]}\n var obj2 = {a:'b',c:'/def/',g:['h','i','{jkl']}\n\nLike a good Freudian, sigmund is most effective when you already have\nsome understanding of what you're looking for. It can help you help\nyourself, but you must be willing to do some work as well.\n\nCycles are handled, and cyclical objects are silently omitted (though\nthe key is included in the signature output.)\n\nThe second argument is the maximum depth, which defaults to 10,\nbecause that is the maximum object traversal depth covered by most\ninsurance carriers.\n", + "readmeFilename": "README.md", + "bugs": { + "url": "https://github.com/isaacs/sigmund/issues" + }, + "homepage": "https://github.com/isaacs/sigmund", + "_id": "sigmund@1.0.0", + "_from": "sigmund@~1.0.0" +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/sigmund/sigmund.js b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/sigmund/sigmund.js new file mode 100644 index 0000000..82c7ab8 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/sigmund/sigmund.js @@ -0,0 +1,39 @@ +module.exports = sigmund +function sigmund (subject, maxSessions) { + maxSessions = maxSessions || 10; + var notes = []; + var analysis = ''; + var RE = RegExp; + + function psychoAnalyze (subject, session) { + if (session > maxSessions) return; + + if (typeof subject === 'function' || + typeof subject === 'undefined') { + return; + } + + if (typeof subject !== 'object' || !subject || + (subject instanceof RE)) { + analysis += subject; + return; + } + + if (notes.indexOf(subject) !== -1 || session === maxSessions) return; + + notes.push(subject); + analysis += '{'; + Object.keys(subject).forEach(function (issue, _, __) { + // pseudo-private values. skip those. + if (issue.charAt(0) === '_') return; + var to = typeof subject[issue]; + if (to === 'function' || to === 'undefined') return; + analysis += issue; + psychoAnalyze(subject[issue], session + 1); + }); + } + psychoAnalyze(subject, 0); + return analysis; +} + +// vim: set softtabstop=4 shiftwidth=4: diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/sigmund/test/basic.js b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/sigmund/test/basic.js new file mode 100644 index 0000000..50c53a1 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/node_modules/sigmund/test/basic.js @@ -0,0 +1,24 @@ +var test = require('tap').test +var sigmund = require('../sigmund.js') + + +// occasionally there are duplicates +// that's an acceptable edge-case. JSON.stringify and util.inspect +// have some collision potential as well, though less, and collision +// detection is expensive. +var hash = '{abc/def/g{0h1i2{jkl' +var obj1 = {a:'b',c:/def/,g:['h','i',{j:'',k:'l'}]} +var obj2 = {a:'b',c:'/def/',g:['h','i','{jkl']} + +var obj3 = JSON.parse(JSON.stringify(obj1)) +obj3.c = /def/ +obj3.g[2].cycle = obj3 +var cycleHash = '{abc/def/g{0h1i2{jklcycle' + +test('basic', function (t) { + t.equal(sigmund(obj1), hash) + t.equal(sigmund(obj2), hash) + t.equal(sigmund(obj3), cycleHash) + t.end() +}) + diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/package.json b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/package.json new file mode 100644 index 0000000..0fe147d --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/package.json @@ -0,0 +1,57 @@ +{ + "author": { + "name": "Isaac Z. Schlueter", + "email": "i@izs.me", + "url": "http://blog.izs.me" + }, + "name": "minimatch", + "description": "a glob matcher in javascript", + "version": "0.3.0", + "repository": { + "type": "git", + "url": "git://github.com/isaacs/minimatch.git" + }, + "main": "minimatch.js", + "scripts": { + "test": "tap test/*.js" + }, + "engines": { + "node": "*" + }, + "dependencies": { + "lru-cache": "2", + "sigmund": "~1.0.0" + }, + "devDependencies": { + "tap": "" + }, + "license": { + "type": "MIT", + "url": "http://github.com/isaacs/minimatch/raw/master/LICENSE" + }, + "bugs": { + "url": "https://github.com/isaacs/minimatch/issues" + }, + "homepage": "https://github.com/isaacs/minimatch", + "_id": "minimatch@0.3.0", + "_shasum": "275d8edaac4f1bb3326472089e7949c8394699dd", + "_from": "minimatch@0.3", + "_npmVersion": "1.4.10", + "_npmUser": { + "name": "isaacs", + "email": "i@izs.me" + }, + "maintainers": [ + { + "name": "isaacs", + "email": "i@izs.me" + } + ], + "dist": { + "shasum": "275d8edaac4f1bb3326472089e7949c8394699dd", + "tarball": "http://registry.npmjs.org/minimatch/-/minimatch-0.3.0.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/minimatch/-/minimatch-0.3.0.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/test/basic.js b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/test/basic.js new file mode 100644 index 0000000..ae7ac73 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/test/basic.js @@ -0,0 +1,399 @@ +// http://www.bashcookbook.com/bashinfo/source/bash-1.14.7/tests/glob-test +// +// TODO: Some of these tests do very bad things with backslashes, and will +// most likely fail badly on windows. They should probably be skipped. + +var tap = require("tap") + , globalBefore = Object.keys(global) + , mm = require("../") + , files = [ "a", "b", "c", "d", "abc" + , "abd", "abe", "bb", "bcd" + , "ca", "cb", "dd", "de" + , "bdir/", "bdir/cfile"] + , next = files.concat([ "a-b", "aXb" + , ".x", ".y" ]) + + +var patterns = + [ "http://www.bashcookbook.com/bashinfo/source/bash-1.14.7/tests/glob-test" + , ["a*", ["a", "abc", "abd", "abe"]] + , ["X*", ["X*"], {nonull: true}] + + // allow null glob expansion + , ["X*", []] + + // isaacs: Slightly different than bash/sh/ksh + // \\* is not un-escaped to literal "*" in a failed match, + // but it does make it get treated as a literal star + , ["\\*", ["\\*"], {nonull: true}] + , ["\\**", ["\\**"], {nonull: true}] + , ["\\*\\*", ["\\*\\*"], {nonull: true}] + + , ["b*/", ["bdir/"]] + , ["c*", ["c", "ca", "cb"]] + , ["**", files] + + , ["\\.\\./*/", ["\\.\\./*/"], {nonull: true}] + , ["s/\\..*//", ["s/\\..*//"], {nonull: true}] + + , "legendary larry crashes bashes" + , ["/^root:/{s/^[^:]*:[^:]*:\([^:]*\).*$/\\1/" + , ["/^root:/{s/^[^:]*:[^:]*:\([^:]*\).*$/\\1/"], {nonull: true}] + , ["/^root:/{s/^[^:]*:[^:]*:\([^:]*\).*$/\1/" + , ["/^root:/{s/^[^:]*:[^:]*:\([^:]*\).*$/\1/"], {nonull: true}] + + , "character classes" + , ["[a-c]b*", ["abc", "abd", "abe", "bb", "cb"]] + , ["[a-y]*[^c]", ["abd", "abe", "bb", "bcd", + "bdir/", "ca", "cb", "dd", "de"]] + , ["a*[^c]", ["abd", "abe"]] + , function () { files.push("a-b", "aXb") } + , ["a[X-]b", ["a-b", "aXb"]] + , function () { files.push(".x", ".y") } + , ["[^a-c]*", ["d", "dd", "de"]] + , function () { files.push("a*b/", "a*b/ooo") } + , ["a\\*b/*", ["a*b/ooo"]] + , ["a\\*?/*", ["a*b/ooo"]] + , ["*\\\\!*", [], {null: true}, ["echo !7"]] + , ["*\\!*", ["echo !7"], null, ["echo !7"]] + , ["*.\\*", ["r.*"], null, ["r.*"]] + , ["a[b]c", ["abc"]] + , ["a[\\b]c", ["abc"]] + , ["a?c", ["abc"]] + , ["a\\*c", [], {null: true}, ["abc"]] + , ["", [""], { null: true }, [""]] + + , "http://www.opensource.apple.com/source/bash/bash-23/" + + "bash/tests/glob-test" + , function () { files.push("man/", "man/man1/", "man/man1/bash.1") } + , ["*/man*/bash.*", ["man/man1/bash.1"]] + , ["man/man1/bash.1", ["man/man1/bash.1"]] + , ["a***c", ["abc"], null, ["abc"]] + , ["a*****?c", ["abc"], null, ["abc"]] + , ["?*****??", ["abc"], null, ["abc"]] + , ["*****??", ["abc"], null, ["abc"]] + , ["?*****?c", ["abc"], null, ["abc"]] + , ["?***?****c", ["abc"], null, ["abc"]] + , ["?***?****?", ["abc"], null, ["abc"]] + , ["?***?****", ["abc"], null, ["abc"]] + , ["*******c", ["abc"], null, ["abc"]] + , ["*******?", ["abc"], null, ["abc"]] + , ["a*cd**?**??k", ["abcdecdhjk"], null, ["abcdecdhjk"]] + , ["a**?**cd**?**??k", ["abcdecdhjk"], null, ["abcdecdhjk"]] + , ["a**?**cd**?**??k***", ["abcdecdhjk"], null, ["abcdecdhjk"]] + , ["a**?**cd**?**??***k", ["abcdecdhjk"], null, ["abcdecdhjk"]] + , ["a**?**cd**?**??***k**", ["abcdecdhjk"], null, ["abcdecdhjk"]] + , ["a****c**?**??*****", ["abcdecdhjk"], null, ["abcdecdhjk"]] + , ["[-abc]", ["-"], null, ["-"]] + , ["[abc-]", ["-"], null, ["-"]] + , ["\\", ["\\"], null, ["\\"]] + , ["[\\\\]", ["\\"], null, ["\\"]] + , ["[[]", ["["], null, ["["]] + , ["[", ["["], null, ["["]] + , ["[*", ["[abc"], null, ["[abc"]] + , "a right bracket shall lose its special meaning and\n" + + "represent itself in a bracket expression if it occurs\n" + + "first in the list. -- POSIX.2 2.8.3.2" + , ["[]]", ["]"], null, ["]"]] + , ["[]-]", ["]"], null, ["]"]] + , ["[a-\z]", ["p"], null, ["p"]] + , ["??**********?****?", [], { null: true }, ["abc"]] + , ["??**********?****c", [], { null: true }, ["abc"]] + , ["?************c****?****", [], { null: true }, ["abc"]] + , ["*c*?**", [], { null: true }, ["abc"]] + , ["a*****c*?**", [], { null: true }, ["abc"]] + , ["a********???*******", [], { null: true }, ["abc"]] + , ["[]", [], { null: true }, ["a"]] + , ["[abc", [], { null: true }, ["["]] + + , "nocase tests" + , ["XYZ", ["xYz"], { nocase: true, null: true } + , ["xYz", "ABC", "IjK"]] + , ["ab*", ["ABC"], { nocase: true, null: true } + , ["xYz", "ABC", "IjK"]] + , ["[ia]?[ck]", ["ABC", "IjK"], { nocase: true, null: true } + , ["xYz", "ABC", "IjK"]] + + // [ pattern, [matches], MM opts, files, TAP opts] + , "onestar/twostar" + , ["{/*,*}", [], {null: true}, ["/asdf/asdf/asdf"]] + , ["{/?,*}", ["/a", "bb"], {null: true} + , ["/a", "/b/b", "/a/b/c", "bb"]] + + , "dots should not match unless requested" + , ["**", ["a/b"], {}, ["a/b", "a/.d", ".a/.d"]] + + // .. and . can only match patterns starting with ., + // even when options.dot is set. + , function () { + files = ["a/./b", "a/../b", "a/c/b", "a/.d/b"] + } + , ["a/*/b", ["a/c/b", "a/.d/b"], {dot: true}] + , ["a/.*/b", ["a/./b", "a/../b", "a/.d/b"], {dot: true}] + , ["a/*/b", ["a/c/b"], {dot:false}] + , ["a/.*/b", ["a/./b", "a/../b", "a/.d/b"], {dot: false}] + + + // this also tests that changing the options needs + // to change the cache key, even if the pattern is + // the same! + , ["**", ["a/b","a/.d",".a/.d"], { dot: true } + , [ ".a/.d", "a/.d", "a/b"]] + + , "paren sets cannot contain slashes" + , ["*(a/b)", ["*(a/b)"], {nonull: true}, ["a/b"]] + + // brace sets trump all else. + // + // invalid glob pattern. fails on bash4 and bsdglob. + // however, in this implementation, it's easier just + // to do the intuitive thing, and let brace-expansion + // actually come before parsing any extglob patterns, + // like the documentation seems to say. + // + // XXX: if anyone complains about this, either fix it + // or tell them to grow up and stop complaining. + // + // bash/bsdglob says this: + // , ["*(a|{b),c)}", ["*(a|{b),c)}"], {}, ["a", "ab", "ac", "ad"]] + // but we do this instead: + , ["*(a|{b),c)}", ["a", "ab", "ac"], {}, ["a", "ab", "ac", "ad"]] + + // test partial parsing in the presence of comment/negation chars + , ["[!a*", ["[!ab"], {}, ["[!ab", "[ab"]] + , ["[#a*", ["[#ab"], {}, ["[#ab", "[ab"]] + + // like: {a,b|c\\,d\\\|e} except it's unclosed, so it has to be escaped. + , ["+(a|*\\|c\\\\|d\\\\\\|e\\\\\\\\|f\\\\\\\\\\|g" + , ["+(a|b\\|c\\\\|d\\\\|e\\\\\\\\|f\\\\\\\\|g"] + , {} + , ["+(a|b\\|c\\\\|d\\\\|e\\\\\\\\|f\\\\\\\\|g", "a", "b\\c"]] + + + // crazy nested {,,} and *(||) tests. + , function () { + files = [ "a", "b", "c", "d" + , "ab", "ac", "ad" + , "bc", "cb" + , "bc,d", "c,db", "c,d" + , "d)", "(b|c", "*(b|c" + , "b|c", "b|cc", "cb|c" + , "x(a|b|c)", "x(a|c)" + , "(a|b|c)", "(a|c)"] + } + , ["*(a|{b,c})", ["a", "b", "c", "ab", "ac"]] + , ["{a,*(b|c,d)}", ["a","(b|c", "*(b|c", "d)"]] + // a + // *(b|c) + // *(b|d) + , ["{a,*(b|{c,d})}", ["a","b", "bc", "cb", "c", "d"]] + , ["*(a|{b|c,c})", ["a", "b", "c", "ab", "ac", "bc", "cb"]] + + + // test various flag settings. + , [ "*(a|{b|c,c})", ["x(a|b|c)", "x(a|c)", "(a|b|c)", "(a|c)"] + , { noext: true } ] + , ["a?b", ["x/y/acb", "acb/"], {matchBase: true} + , ["x/y/acb", "acb/", "acb/d/e", "x/y/acb/d"] ] + , ["#*", ["#a", "#b"], {nocomment: true}, ["#a", "#b", "c#d"]] + + + // begin channelling Boole and deMorgan... + , "negation tests" + , function () { + files = ["d", "e", "!ab", "!abc", "a!b", "\\!a"] + } + + // anything that is NOT a* matches. + , ["!a*", ["\\!a", "d", "e", "!ab", "!abc"]] + + // anything that IS !a* matches. + , ["!a*", ["!ab", "!abc"], {nonegate: true}] + + // anything that IS a* matches + , ["!!a*", ["a!b"]] + + // anything that is NOT !a* matches + , ["!\\!a*", ["a!b", "d", "e", "\\!a"]] + + // negation nestled within a pattern + , function () { + files = [ "foo.js" + , "foo.bar" + // can't match this one without negative lookbehind. + , "foo.js.js" + , "blar.js" + , "foo." + , "boo.js.boo" ] + } + , ["*.!(js)", ["foo.bar", "foo.", "boo.js.boo"] ] + + // https://github.com/isaacs/minimatch/issues/5 + , function () { + files = [ 'a/b/.x/c' + , 'a/b/.x/c/d' + , 'a/b/.x/c/d/e' + , 'a/b/.x' + , 'a/b/.x/' + , 'a/.x/b' + , '.x' + , '.x/' + , '.x/a' + , '.x/a/b' + , 'a/.x/b/.x/c' + , '.x/.x' ] + } + , ["**/.x/**", [ '.x/' + , '.x/a' + , '.x/a/b' + , 'a/.x/b' + , 'a/b/.x/' + , 'a/b/.x/c' + , 'a/b/.x/c/d' + , 'a/b/.x/c/d/e' ] ] + + ] + +var regexps = + [ '/^(?:(?=.)a[^/]*?)$/', + '/^(?:(?=.)X[^/]*?)$/', + '/^(?:(?=.)X[^/]*?)$/', + '/^(?:\\*)$/', + '/^(?:(?=.)\\*[^/]*?)$/', + '/^(?:\\*\\*)$/', + '/^(?:(?=.)b[^/]*?\\/)$/', + '/^(?:(?=.)c[^/]*?)$/', + '/^(?:(?:(?!(?:\\/|^)\\.).)*?)$/', + '/^(?:\\.\\.\\/(?!\\.)(?=.)[^/]*?\\/)$/', + '/^(?:s\\/(?=.)\\.\\.[^/]*?\\/)$/', + '/^(?:\\/\\^root:\\/\\{s\\/(?=.)\\^[^:][^/]*?:[^:][^/]*?:\\([^:]\\)[^/]*?\\.[^/]*?\\$\\/1\\/)$/', + '/^(?:\\/\\^root:\\/\\{s\\/(?=.)\\^[^:][^/]*?:[^:][^/]*?:\\([^:]\\)[^/]*?\\.[^/]*?\\$\\/\u0001\\/)$/', + '/^(?:(?!\\.)(?=.)[a-c]b[^/]*?)$/', + '/^(?:(?!\\.)(?=.)[a-y][^/]*?[^c])$/', + '/^(?:(?=.)a[^/]*?[^c])$/', + '/^(?:(?=.)a[X-]b)$/', + '/^(?:(?!\\.)(?=.)[^a-c][^/]*?)$/', + '/^(?:a\\*b\\/(?!\\.)(?=.)[^/]*?)$/', + '/^(?:(?=.)a\\*[^/]\\/(?!\\.)(?=.)[^/]*?)$/', + '/^(?:(?!\\.)(?=.)[^/]*?\\\\\\![^/]*?)$/', + '/^(?:(?!\\.)(?=.)[^/]*?\\![^/]*?)$/', + '/^(?:(?!\\.)(?=.)[^/]*?\\.\\*)$/', + '/^(?:(?=.)a[b]c)$/', + '/^(?:(?=.)a[b]c)$/', + '/^(?:(?=.)a[^/]c)$/', + '/^(?:a\\*c)$/', + 'false', + '/^(?:(?!\\.)(?=.)[^/]*?\\/(?=.)man[^/]*?\\/(?=.)bash\\.[^/]*?)$/', + '/^(?:man\\/man1\\/bash\\.1)$/', + '/^(?:(?=.)a[^/]*?[^/]*?[^/]*?c)$/', + '/^(?:(?=.)a[^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/]c)$/', + '/^(?:(?!\\.)(?=.)[^/][^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/][^/])$/', + '/^(?:(?!\\.)(?=.)[^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/][^/])$/', + '/^(?:(?!\\.)(?=.)[^/][^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/]c)$/', + '/^(?:(?!\\.)(?=.)[^/][^/]*?[^/]*?[^/]*?[^/][^/]*?[^/]*?[^/]*?[^/]*?c)$/', + '/^(?:(?!\\.)(?=.)[^/][^/]*?[^/]*?[^/]*?[^/][^/]*?[^/]*?[^/]*?[^/]*?[^/])$/', + '/^(?:(?!\\.)(?=.)[^/][^/]*?[^/]*?[^/]*?[^/][^/]*?[^/]*?[^/]*?[^/]*?)$/', + '/^(?:(?!\\.)(?=.)[^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/]*?c)$/', + '/^(?:(?!\\.)(?=.)[^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/])$/', + '/^(?:(?=.)a[^/]*?cd[^/]*?[^/]*?[^/][^/]*?[^/]*?[^/][^/]k)$/', + '/^(?:(?=.)a[^/]*?[^/]*?[^/][^/]*?[^/]*?cd[^/]*?[^/]*?[^/][^/]*?[^/]*?[^/][^/]k)$/', + '/^(?:(?=.)a[^/]*?[^/]*?[^/][^/]*?[^/]*?cd[^/]*?[^/]*?[^/][^/]*?[^/]*?[^/][^/]k[^/]*?[^/]*?[^/]*?)$/', + '/^(?:(?=.)a[^/]*?[^/]*?[^/][^/]*?[^/]*?cd[^/]*?[^/]*?[^/][^/]*?[^/]*?[^/][^/][^/]*?[^/]*?[^/]*?k)$/', + '/^(?:(?=.)a[^/]*?[^/]*?[^/][^/]*?[^/]*?cd[^/]*?[^/]*?[^/][^/]*?[^/]*?[^/][^/][^/]*?[^/]*?[^/]*?k[^/]*?[^/]*?)$/', + '/^(?:(?=.)a[^/]*?[^/]*?[^/]*?[^/]*?c[^/]*?[^/]*?[^/][^/]*?[^/]*?[^/][^/][^/]*?[^/]*?[^/]*?[^/]*?[^/]*?)$/', + '/^(?:(?!\\.)(?=.)[-abc])$/', + '/^(?:(?!\\.)(?=.)[abc-])$/', + '/^(?:\\\\)$/', + '/^(?:(?!\\.)(?=.)[\\\\])$/', + '/^(?:(?!\\.)(?=.)[\\[])$/', + '/^(?:\\[)$/', + '/^(?:(?=.)\\[(?!\\.)(?=.)[^/]*?)$/', + '/^(?:(?!\\.)(?=.)[\\]])$/', + '/^(?:(?!\\.)(?=.)[\\]-])$/', + '/^(?:(?!\\.)(?=.)[a-z])$/', + '/^(?:(?!\\.)(?=.)[^/][^/][^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/][^/]*?[^/]*?[^/]*?[^/]*?[^/])$/', + '/^(?:(?!\\.)(?=.)[^/][^/][^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/][^/]*?[^/]*?[^/]*?[^/]*?c)$/', + '/^(?:(?!\\.)(?=.)[^/][^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/]*?c[^/]*?[^/]*?[^/]*?[^/]*?[^/][^/]*?[^/]*?[^/]*?[^/]*?)$/', + '/^(?:(?!\\.)(?=.)[^/]*?c[^/]*?[^/][^/]*?[^/]*?)$/', + '/^(?:(?=.)a[^/]*?[^/]*?[^/]*?[^/]*?[^/]*?c[^/]*?[^/][^/]*?[^/]*?)$/', + '/^(?:(?=.)a[^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/][^/][^/][^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/]*?[^/]*?)$/', + '/^(?:\\[\\])$/', + '/^(?:\\[abc)$/', + '/^(?:(?=.)XYZ)$/i', + '/^(?:(?=.)ab[^/]*?)$/i', + '/^(?:(?!\\.)(?=.)[ia][^/][ck])$/i', + '/^(?:\\/(?!\\.)(?=.)[^/]*?|(?!\\.)(?=.)[^/]*?)$/', + '/^(?:\\/(?!\\.)(?=.)[^/]|(?!\\.)(?=.)[^/]*?)$/', + '/^(?:(?:(?!(?:\\/|^)\\.).)*?)$/', + '/^(?:a\\/(?!(?:^|\\/)\\.{1,2}(?:$|\\/))(?=.)[^/]*?\\/b)$/', + '/^(?:a\\/(?=.)\\.[^/]*?\\/b)$/', + '/^(?:a\\/(?!\\.)(?=.)[^/]*?\\/b)$/', + '/^(?:a\\/(?=.)\\.[^/]*?\\/b)$/', + '/^(?:(?:(?!(?:\\/|^)(?:\\.{1,2})($|\\/)).)*?)$/', + '/^(?:(?!\\.)(?=.)[^/]*?\\(a\\/b\\))$/', + '/^(?:(?!\\.)(?=.)(?:a|b)*|(?!\\.)(?=.)(?:a|c)*)$/', + '/^(?:(?=.)\\[(?=.)\\!a[^/]*?)$/', + '/^(?:(?=.)\\[(?=.)#a[^/]*?)$/', + '/^(?:(?=.)\\+\\(a\\|[^/]*?\\|c\\\\\\\\\\|d\\\\\\\\\\|e\\\\\\\\\\\\\\\\\\|f\\\\\\\\\\\\\\\\\\|g)$/', + '/^(?:(?!\\.)(?=.)(?:a|b)*|(?!\\.)(?=.)(?:a|c)*)$/', + '/^(?:a|(?!\\.)(?=.)[^/]*?\\(b\\|c|d\\))$/', + '/^(?:a|(?!\\.)(?=.)(?:b|c)*|(?!\\.)(?=.)(?:b|d)*)$/', + '/^(?:(?!\\.)(?=.)(?:a|b|c)*|(?!\\.)(?=.)(?:a|c)*)$/', + '/^(?:(?!\\.)(?=.)[^/]*?\\(a\\|b\\|c\\)|(?!\\.)(?=.)[^/]*?\\(a\\|c\\))$/', + '/^(?:(?=.)a[^/]b)$/', + '/^(?:(?=.)#[^/]*?)$/', + '/^(?!^(?:(?=.)a[^/]*?)$).*$/', + '/^(?:(?=.)\\!a[^/]*?)$/', + '/^(?:(?=.)a[^/]*?)$/', + '/^(?!^(?:(?=.)\\!a[^/]*?)$).*$/', + '/^(?:(?!\\.)(?=.)[^/]*?\\.(?:(?!js)[^/]*?))$/', + '/^(?:(?:(?!(?:\\/|^)\\.).)*?\\/\\.x\\/(?:(?!(?:\\/|^)\\.).)*?)$/' ] +var re = 0; + +tap.test("basic tests", function (t) { + var start = Date.now() + + // [ pattern, [matches], MM opts, files, TAP opts] + patterns.forEach(function (c) { + if (typeof c === "function") return c() + if (typeof c === "string") return t.comment(c) + + var pattern = c[0] + , expect = c[1].sort(alpha) + , options = c[2] || {} + , f = c[3] || files + , tapOpts = c[4] || {} + + // options.debug = true + var m = new mm.Minimatch(pattern, options) + var r = m.makeRe() + var expectRe = regexps[re++] + tapOpts.re = String(r) || JSON.stringify(r) + tapOpts.files = JSON.stringify(f) + tapOpts.pattern = pattern + tapOpts.set = m.set + tapOpts.negated = m.negate + + var actual = mm.match(f, pattern, options) + actual.sort(alpha) + + t.equivalent( actual, expect + , JSON.stringify(pattern) + " " + JSON.stringify(expect) + , tapOpts ) + + t.equal(tapOpts.re, expectRe, tapOpts) + }) + + t.comment("time=" + (Date.now() - start) + "ms") + t.end() +}) + +tap.test("global leak test", function (t) { + var globalAfter = Object.keys(global) + t.equivalent(globalAfter, globalBefore, "no new globals, please") + t.end() +}) + +function alpha (a, b) { + return a > b ? 1 : -1 +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/test/brace-expand.js b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/test/brace-expand.js new file mode 100644 index 0000000..7ee278a --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/test/brace-expand.js @@ -0,0 +1,33 @@ +var tap = require("tap") + , minimatch = require("../") + +tap.test("brace expansion", function (t) { + // [ pattern, [expanded] ] + ; [ [ "a{b,c{d,e},{f,g}h}x{y,z}" + , [ "abxy" + , "abxz" + , "acdxy" + , "acdxz" + , "acexy" + , "acexz" + , "afhxy" + , "afhxz" + , "aghxy" + , "aghxz" ] ] + , [ "a{1..5}b" + , [ "a1b" + , "a2b" + , "a3b" + , "a4b" + , "a5b" ] ] + , [ "a{b}c", ["a{b}c"] ] + ].forEach(function (tc) { + var p = tc[0] + , expect = tc[1] + t.equivalent(minimatch.braceExpand(p), expect, p) + }) + console.error("ending") + t.end() +}) + + diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/test/caching.js b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/test/caching.js new file mode 100644 index 0000000..0fec4b0 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/test/caching.js @@ -0,0 +1,14 @@ +var Minimatch = require("../minimatch.js").Minimatch +var tap = require("tap") +tap.test("cache test", function (t) { + var mm1 = new Minimatch("a?b") + var mm2 = new Minimatch("a?b") + t.equal(mm1, mm2, "should get the same object") + // the lru should drop it after 100 entries + for (var i = 0; i < 100; i ++) { + new Minimatch("a"+i) + } + mm2 = new Minimatch("a?b") + t.notEqual(mm1, mm2, "cache should have dropped") + t.end() +}) diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/test/defaults.js b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/test/defaults.js new file mode 100644 index 0000000..75e0571 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/test/defaults.js @@ -0,0 +1,274 @@ +// http://www.bashcookbook.com/bashinfo/source/bash-1.14.7/tests/glob-test +// +// TODO: Some of these tests do very bad things with backslashes, and will +// most likely fail badly on windows. They should probably be skipped. + +var tap = require("tap") + , globalBefore = Object.keys(global) + , mm = require("../") + , files = [ "a", "b", "c", "d", "abc" + , "abd", "abe", "bb", "bcd" + , "ca", "cb", "dd", "de" + , "bdir/", "bdir/cfile"] + , next = files.concat([ "a-b", "aXb" + , ".x", ".y" ]) + +tap.test("basic tests", function (t) { + var start = Date.now() + + // [ pattern, [matches], MM opts, files, TAP opts] + ; [ "http://www.bashcookbook.com/bashinfo" + + "/source/bash-1.14.7/tests/glob-test" + , ["a*", ["a", "abc", "abd", "abe"]] + , ["X*", ["X*"], {nonull: true}] + + // allow null glob expansion + , ["X*", []] + + // isaacs: Slightly different than bash/sh/ksh + // \\* is not un-escaped to literal "*" in a failed match, + // but it does make it get treated as a literal star + , ["\\*", ["\\*"], {nonull: true}] + , ["\\**", ["\\**"], {nonull: true}] + , ["\\*\\*", ["\\*\\*"], {nonull: true}] + + , ["b*/", ["bdir/"]] + , ["c*", ["c", "ca", "cb"]] + , ["**", files] + + , ["\\.\\./*/", ["\\.\\./*/"], {nonull: true}] + , ["s/\\..*//", ["s/\\..*//"], {nonull: true}] + + , "legendary larry crashes bashes" + , ["/^root:/{s/^[^:]*:[^:]*:\([^:]*\).*$/\\1/" + , ["/^root:/{s/^[^:]*:[^:]*:\([^:]*\).*$/\\1/"], {nonull: true}] + , ["/^root:/{s/^[^:]*:[^:]*:\([^:]*\).*$/\1/" + , ["/^root:/{s/^[^:]*:[^:]*:\([^:]*\).*$/\1/"], {nonull: true}] + + , "character classes" + , ["[a-c]b*", ["abc", "abd", "abe", "bb", "cb"]] + , ["[a-y]*[^c]", ["abd", "abe", "bb", "bcd", + "bdir/", "ca", "cb", "dd", "de"]] + , ["a*[^c]", ["abd", "abe"]] + , function () { files.push("a-b", "aXb") } + , ["a[X-]b", ["a-b", "aXb"]] + , function () { files.push(".x", ".y") } + , ["[^a-c]*", ["d", "dd", "de"]] + , function () { files.push("a*b/", "a*b/ooo") } + , ["a\\*b/*", ["a*b/ooo"]] + , ["a\\*?/*", ["a*b/ooo"]] + , ["*\\\\!*", [], {null: true}, ["echo !7"]] + , ["*\\!*", ["echo !7"], null, ["echo !7"]] + , ["*.\\*", ["r.*"], null, ["r.*"]] + , ["a[b]c", ["abc"]] + , ["a[\\b]c", ["abc"]] + , ["a?c", ["abc"]] + , ["a\\*c", [], {null: true}, ["abc"]] + , ["", [""], { null: true }, [""]] + + , "http://www.opensource.apple.com/source/bash/bash-23/" + + "bash/tests/glob-test" + , function () { files.push("man/", "man/man1/", "man/man1/bash.1") } + , ["*/man*/bash.*", ["man/man1/bash.1"]] + , ["man/man1/bash.1", ["man/man1/bash.1"]] + , ["a***c", ["abc"], null, ["abc"]] + , ["a*****?c", ["abc"], null, ["abc"]] + , ["?*****??", ["abc"], null, ["abc"]] + , ["*****??", ["abc"], null, ["abc"]] + , ["?*****?c", ["abc"], null, ["abc"]] + , ["?***?****c", ["abc"], null, ["abc"]] + , ["?***?****?", ["abc"], null, ["abc"]] + , ["?***?****", ["abc"], null, ["abc"]] + , ["*******c", ["abc"], null, ["abc"]] + , ["*******?", ["abc"], null, ["abc"]] + , ["a*cd**?**??k", ["abcdecdhjk"], null, ["abcdecdhjk"]] + , ["a**?**cd**?**??k", ["abcdecdhjk"], null, ["abcdecdhjk"]] + , ["a**?**cd**?**??k***", ["abcdecdhjk"], null, ["abcdecdhjk"]] + , ["a**?**cd**?**??***k", ["abcdecdhjk"], null, ["abcdecdhjk"]] + , ["a**?**cd**?**??***k**", ["abcdecdhjk"], null, ["abcdecdhjk"]] + , ["a****c**?**??*****", ["abcdecdhjk"], null, ["abcdecdhjk"]] + , ["[-abc]", ["-"], null, ["-"]] + , ["[abc-]", ["-"], null, ["-"]] + , ["\\", ["\\"], null, ["\\"]] + , ["[\\\\]", ["\\"], null, ["\\"]] + , ["[[]", ["["], null, ["["]] + , ["[", ["["], null, ["["]] + , ["[*", ["[abc"], null, ["[abc"]] + , "a right bracket shall lose its special meaning and\n" + + "represent itself in a bracket expression if it occurs\n" + + "first in the list. -- POSIX.2 2.8.3.2" + , ["[]]", ["]"], null, ["]"]] + , ["[]-]", ["]"], null, ["]"]] + , ["[a-\z]", ["p"], null, ["p"]] + , ["??**********?****?", [], { null: true }, ["abc"]] + , ["??**********?****c", [], { null: true }, ["abc"]] + , ["?************c****?****", [], { null: true }, ["abc"]] + , ["*c*?**", [], { null: true }, ["abc"]] + , ["a*****c*?**", [], { null: true }, ["abc"]] + , ["a********???*******", [], { null: true }, ["abc"]] + , ["[]", [], { null: true }, ["a"]] + , ["[abc", [], { null: true }, ["["]] + + , "nocase tests" + , ["XYZ", ["xYz"], { nocase: true, null: true } + , ["xYz", "ABC", "IjK"]] + , ["ab*", ["ABC"], { nocase: true, null: true } + , ["xYz", "ABC", "IjK"]] + , ["[ia]?[ck]", ["ABC", "IjK"], { nocase: true, null: true } + , ["xYz", "ABC", "IjK"]] + + // [ pattern, [matches], MM opts, files, TAP opts] + , "onestar/twostar" + , ["{/*,*}", [], {null: true}, ["/asdf/asdf/asdf"]] + , ["{/?,*}", ["/a", "bb"], {null: true} + , ["/a", "/b/b", "/a/b/c", "bb"]] + + , "dots should not match unless requested" + , ["**", ["a/b"], {}, ["a/b", "a/.d", ".a/.d"]] + + // .. and . can only match patterns starting with ., + // even when options.dot is set. + , function () { + files = ["a/./b", "a/../b", "a/c/b", "a/.d/b"] + } + , ["a/*/b", ["a/c/b", "a/.d/b"], {dot: true}] + , ["a/.*/b", ["a/./b", "a/../b", "a/.d/b"], {dot: true}] + , ["a/*/b", ["a/c/b"], {dot:false}] + , ["a/.*/b", ["a/./b", "a/../b", "a/.d/b"], {dot: false}] + + + // this also tests that changing the options needs + // to change the cache key, even if the pattern is + // the same! + , ["**", ["a/b","a/.d",".a/.d"], { dot: true } + , [ ".a/.d", "a/.d", "a/b"]] + + , "paren sets cannot contain slashes" + , ["*(a/b)", ["*(a/b)"], {nonull: true}, ["a/b"]] + + // brace sets trump all else. + // + // invalid glob pattern. fails on bash4 and bsdglob. + // however, in this implementation, it's easier just + // to do the intuitive thing, and let brace-expansion + // actually come before parsing any extglob patterns, + // like the documentation seems to say. + // + // XXX: if anyone complains about this, either fix it + // or tell them to grow up and stop complaining. + // + // bash/bsdglob says this: + // , ["*(a|{b),c)}", ["*(a|{b),c)}"], {}, ["a", "ab", "ac", "ad"]] + // but we do this instead: + , ["*(a|{b),c)}", ["a", "ab", "ac"], {}, ["a", "ab", "ac", "ad"]] + + // test partial parsing in the presence of comment/negation chars + , ["[!a*", ["[!ab"], {}, ["[!ab", "[ab"]] + , ["[#a*", ["[#ab"], {}, ["[#ab", "[ab"]] + + // like: {a,b|c\\,d\\\|e} except it's unclosed, so it has to be escaped. + , ["+(a|*\\|c\\\\|d\\\\\\|e\\\\\\\\|f\\\\\\\\\\|g" + , ["+(a|b\\|c\\\\|d\\\\|e\\\\\\\\|f\\\\\\\\|g"] + , {} + , ["+(a|b\\|c\\\\|d\\\\|e\\\\\\\\|f\\\\\\\\|g", "a", "b\\c"]] + + + // crazy nested {,,} and *(||) tests. + , function () { + files = [ "a", "b", "c", "d" + , "ab", "ac", "ad" + , "bc", "cb" + , "bc,d", "c,db", "c,d" + , "d)", "(b|c", "*(b|c" + , "b|c", "b|cc", "cb|c" + , "x(a|b|c)", "x(a|c)" + , "(a|b|c)", "(a|c)"] + } + , ["*(a|{b,c})", ["a", "b", "c", "ab", "ac"]] + , ["{a,*(b|c,d)}", ["a","(b|c", "*(b|c", "d)"]] + // a + // *(b|c) + // *(b|d) + , ["{a,*(b|{c,d})}", ["a","b", "bc", "cb", "c", "d"]] + , ["*(a|{b|c,c})", ["a", "b", "c", "ab", "ac", "bc", "cb"]] + + + // test various flag settings. + , [ "*(a|{b|c,c})", ["x(a|b|c)", "x(a|c)", "(a|b|c)", "(a|c)"] + , { noext: true } ] + , ["a?b", ["x/y/acb", "acb/"], {matchBase: true} + , ["x/y/acb", "acb/", "acb/d/e", "x/y/acb/d"] ] + , ["#*", ["#a", "#b"], {nocomment: true}, ["#a", "#b", "c#d"]] + + + // begin channelling Boole and deMorgan... + , "negation tests" + , function () { + files = ["d", "e", "!ab", "!abc", "a!b", "\\!a"] + } + + // anything that is NOT a* matches. + , ["!a*", ["\\!a", "d", "e", "!ab", "!abc"]] + + // anything that IS !a* matches. + , ["!a*", ["!ab", "!abc"], {nonegate: true}] + + // anything that IS a* matches + , ["!!a*", ["a!b"]] + + // anything that is NOT !a* matches + , ["!\\!a*", ["a!b", "d", "e", "\\!a"]] + + // negation nestled within a pattern + , function () { + files = [ "foo.js" + , "foo.bar" + // can't match this one without negative lookbehind. + , "foo.js.js" + , "blar.js" + , "foo." + , "boo.js.boo" ] + } + , ["*.!(js)", ["foo.bar", "foo.", "boo.js.boo"] ] + + ].forEach(function (c) { + if (typeof c === "function") return c() + if (typeof c === "string") return t.comment(c) + + var pattern = c[0] + , expect = c[1].sort(alpha) + , options = c[2] + , f = c[3] || files + , tapOpts = c[4] || {} + + // options.debug = true + var Class = mm.defaults(options).Minimatch + var m = new Class(pattern, {}) + var r = m.makeRe() + tapOpts.re = String(r) || JSON.stringify(r) + tapOpts.files = JSON.stringify(f) + tapOpts.pattern = pattern + tapOpts.set = m.set + tapOpts.negated = m.negate + + var actual = mm.match(f, pattern, options) + actual.sort(alpha) + + t.equivalent( actual, expect + , JSON.stringify(pattern) + " " + JSON.stringify(expect) + , tapOpts ) + }) + + t.comment("time=" + (Date.now() - start) + "ms") + t.end() +}) + +tap.test("global leak test", function (t) { + var globalAfter = Object.keys(global) + t.equivalent(globalAfter, globalBefore, "no new globals, please") + t.end() +}) + +function alpha (a, b) { + return a > b ? 1 : -1 +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/test/extglob-ending-with-state-char.js b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/test/extglob-ending-with-state-char.js new file mode 100644 index 0000000..6676e26 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/node_modules/minimatch/test/extglob-ending-with-state-char.js @@ -0,0 +1,8 @@ +var test = require('tap').test +var minimatch = require('../') + +test('extglob ending with statechar', function(t) { + t.notOk(minimatch('ax', 'a?(b*)')) + t.ok(minimatch('ax', '?(a*|b)')) + t.end() +}) diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/package.json b/node_modules/nodeunit/node_modules/tap/node_modules/glob/package.json new file mode 100644 index 0000000..de105e7 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/package.json @@ -0,0 +1,58 @@ +{ + "author": { + "name": "Isaac Z. Schlueter", + "email": "i@izs.me", + "url": "http://blog.izs.me/" + }, + "name": "glob", + "description": "a little globber", + "version": "3.2.11", + "repository": { + "type": "git", + "url": "git://github.com/isaacs/node-glob.git" + }, + "main": "glob.js", + "engines": { + "node": "*" + }, + "dependencies": { + "inherits": "2", + "minimatch": "0.3" + }, + "devDependencies": { + "tap": "~0.4.0", + "mkdirp": "0", + "rimraf": "1" + }, + "scripts": { + "test": "tap test/*.js", + "test-regen": "TEST_REGEN=1 node test/00-setup.js" + }, + "license": "BSD", + "gitHead": "73f57e99510582b2024b762305970ebcf9b70aa2", + "bugs": { + "url": "https://github.com/isaacs/node-glob/issues" + }, + "homepage": "https://github.com/isaacs/node-glob", + "_id": "glob@3.2.11", + "_shasum": "4a973f635b9190f715d10987d5c00fd2815ebe3d", + "_from": "glob@3.2.11", + "_npmVersion": "1.4.10", + "_npmUser": { + "name": "isaacs", + "email": "i@izs.me" + }, + "maintainers": [ + { + "name": "isaacs", + "email": "i@izs.me" + } + ], + "dist": { + "shasum": "4a973f635b9190f715d10987d5c00fd2815ebe3d", + "tarball": "http://registry.npmjs.org/glob/-/glob-3.2.11.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/glob/-/glob-3.2.11.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/00-setup.js b/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/00-setup.js new file mode 100644 index 0000000..245afaf --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/00-setup.js @@ -0,0 +1,176 @@ +// just a little pre-run script to set up the fixtures. +// zz-finish cleans it up + +var mkdirp = require("mkdirp") +var path = require("path") +var i = 0 +var tap = require("tap") +var fs = require("fs") +var rimraf = require("rimraf") + +var files = +[ "a/.abcdef/x/y/z/a" +, "a/abcdef/g/h" +, "a/abcfed/g/h" +, "a/b/c/d" +, "a/bc/e/f" +, "a/c/d/c/b" +, "a/cb/e/f" +] + +var symlinkTo = path.resolve(__dirname, "a/symlink/a/b/c") +var symlinkFrom = "../.." + +files = files.map(function (f) { + return path.resolve(__dirname, f) +}) + +tap.test("remove fixtures", function (t) { + rimraf(path.resolve(__dirname, "a"), function (er) { + t.ifError(er, "remove fixtures") + t.end() + }) +}) + +files.forEach(function (f) { + tap.test(f, function (t) { + var d = path.dirname(f) + mkdirp(d, 0755, function (er) { + if (er) { + t.fail(er) + return t.bailout() + } + fs.writeFile(f, "i like tests", function (er) { + t.ifError(er, "make file") + t.end() + }) + }) + }) +}) + +if (process.platform !== "win32") { + tap.test("symlinky", function (t) { + var d = path.dirname(symlinkTo) + console.error("mkdirp", d) + mkdirp(d, 0755, function (er) { + t.ifError(er) + fs.symlink(symlinkFrom, symlinkTo, "dir", function (er) { + t.ifError(er, "make symlink") + t.end() + }) + }) + }) +} + +;["foo","bar","baz","asdf","quux","qwer","rewq"].forEach(function (w) { + w = "/tmp/glob-test/" + w + tap.test("create " + w, function (t) { + mkdirp(w, function (er) { + if (er) + throw er + t.pass(w) + t.end() + }) + }) +}) + + +// generate the bash pattern test-fixtures if possible +if (process.platform === "win32" || !process.env.TEST_REGEN) { + console.error("Windows, or TEST_REGEN unset. Using cached fixtures.") + return +} + +var spawn = require("child_process").spawn; +var globs = + // put more patterns here. + // anything that would be directly in / should be in /tmp/glob-test + ["test/a/*/+(c|g)/./d" + ,"test/a/**/[cg]/../[cg]" + ,"test/a/{b,c,d,e,f}/**/g" + ,"test/a/b/**" + ,"test/**/g" + ,"test/a/abc{fed,def}/g/h" + ,"test/a/abc{fed/g,def}/**/" + ,"test/a/abc{fed/g,def}/**///**/" + ,"test/**/a/**/" + ,"test/+(a|b|c)/a{/,bc*}/**" + ,"test/*/*/*/f" + ,"test/**/f" + ,"test/a/symlink/a/b/c/a/b/c/a/b/c//a/b/c////a/b/c/**/b/c/**" + ,"{./*/*,/tmp/glob-test/*}" + ,"{/tmp/glob-test/*,*}" // evil owl face! how you taunt me! + ,"test/a/!(symlink)/**" + ] +var bashOutput = {} +var fs = require("fs") + +globs.forEach(function (pattern) { + tap.test("generate fixture " + pattern, function (t) { + var cmd = "shopt -s globstar && " + + "shopt -s extglob && " + + "shopt -s nullglob && " + + // "shopt >&2; " + + "eval \'for i in " + pattern + "; do echo $i; done\'" + var cp = spawn("bash", ["-c", cmd], { cwd: path.dirname(__dirname) }) + var out = [] + cp.stdout.on("data", function (c) { + out.push(c) + }) + cp.stderr.pipe(process.stderr) + cp.on("close", function (code) { + out = flatten(out) + if (!out) + out = [] + else + out = cleanResults(out.split(/\r*\n/)) + + bashOutput[pattern] = out + t.notOk(code, "bash test should finish nicely") + t.end() + }) + }) +}) + +tap.test("save fixtures", function (t) { + var fname = path.resolve(__dirname, "bash-results.json") + var data = JSON.stringify(bashOutput, null, 2) + "\n" + fs.writeFile(fname, data, function (er) { + t.ifError(er) + t.end() + }) +}) + +function cleanResults (m) { + // normalize discrepancies in ordering, duplication, + // and ending slashes. + return m.map(function (m) { + return m.replace(/\/+/g, "/").replace(/\/$/, "") + }).sort(alphasort).reduce(function (set, f) { + if (f !== set[set.length - 1]) set.push(f) + return set + }, []).sort(alphasort).map(function (f) { + // de-windows + return (process.platform !== 'win32') ? f + : f.replace(/^[a-zA-Z]:\\\\/, '/').replace(/\\/g, '/') + }) +} + +function flatten (chunks) { + var s = 0 + chunks.forEach(function (c) { s += c.length }) + var out = new Buffer(s) + s = 0 + chunks.forEach(function (c) { + c.copy(out, s) + s += c.length + }) + + return out.toString().trim() +} + +function alphasort (a, b) { + a = a.toLowerCase() + b = b.toLowerCase() + return a > b ? 1 : a < b ? -1 : 0 +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/bash-comparison.js b/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/bash-comparison.js new file mode 100644 index 0000000..239ed1a --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/bash-comparison.js @@ -0,0 +1,63 @@ +// basic test +// show that it does the same thing by default as the shell. +var tap = require("tap") +, child_process = require("child_process") +, bashResults = require("./bash-results.json") +, globs = Object.keys(bashResults) +, glob = require("../") +, path = require("path") + +// run from the root of the project +// this is usually where you're at anyway, but be sure. +process.chdir(path.resolve(__dirname, "..")) + +function alphasort (a, b) { + a = a.toLowerCase() + b = b.toLowerCase() + return a > b ? 1 : a < b ? -1 : 0 +} + +globs.forEach(function (pattern) { + var expect = bashResults[pattern] + // anything regarding the symlink thing will fail on windows, so just skip it + if (process.platform === "win32" && + expect.some(function (m) { + return /\/symlink\//.test(m) + })) + return + + tap.test(pattern, function (t) { + glob(pattern, function (er, matches) { + if (er) + throw er + + // sort and unmark, just to match the shell results + matches = cleanResults(matches) + + t.deepEqual(matches, expect, pattern) + t.end() + }) + }) + + tap.test(pattern + " sync", function (t) { + var matches = cleanResults(glob.sync(pattern)) + + t.deepEqual(matches, expect, "should match shell") + t.end() + }) +}) + +function cleanResults (m) { + // normalize discrepancies in ordering, duplication, + // and ending slashes. + return m.map(function (m) { + return m.replace(/\/+/g, "/").replace(/\/$/, "") + }).sort(alphasort).reduce(function (set, f) { + if (f !== set[set.length - 1]) set.push(f) + return set + }, []).sort(alphasort).map(function (f) { + // de-windows + return (process.platform !== 'win32') ? f + : f.replace(/^[a-zA-Z]:[\/\\]+/, '/').replace(/[\\\/]+/g, '/') + }) +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/bash-results.json b/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/bash-results.json new file mode 100644 index 0000000..8051c72 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/bash-results.json @@ -0,0 +1,351 @@ +{ + "test/a/*/+(c|g)/./d": [ + "test/a/b/c/./d" + ], + "test/a/**/[cg]/../[cg]": [ + "test/a/abcdef/g/../g", + "test/a/abcfed/g/../g", + "test/a/b/c/../c", + "test/a/c/../c", + "test/a/c/d/c/../c", + "test/a/symlink/a/b/c/../c", + "test/a/symlink/a/b/c/a/b/c/../c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/../c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/../c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/../c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/../c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/../c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/../c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/../c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/../c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/../c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/../c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/../c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/../c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/../c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/../c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/../c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/../c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/../c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/../c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/../c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/../c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/../c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/../c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/../c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/../c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/../c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/../c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/../c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/../c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/../c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/../c" + ], + "test/a/{b,c,d,e,f}/**/g": [], + "test/a/b/**": [ + "test/a/b", + "test/a/b/c", + "test/a/b/c/d" + ], + "test/**/g": [ + "test/a/abcdef/g", + "test/a/abcfed/g" + ], + "test/a/abc{fed,def}/g/h": [ + "test/a/abcdef/g/h", + "test/a/abcfed/g/h" + ], + "test/a/abc{fed/g,def}/**/": [ + "test/a/abcdef", + "test/a/abcdef/g", + "test/a/abcfed/g" + ], + "test/a/abc{fed/g,def}/**///**/": [ + "test/a/abcdef", + "test/a/abcdef/g", + "test/a/abcfed/g" + ], + "test/**/a/**/": [ + "test/a", + "test/a/abcdef", + "test/a/abcdef/g", + "test/a/abcfed", + "test/a/abcfed/g", + "test/a/b", + "test/a/b/c", + "test/a/bc", + "test/a/bc/e", + "test/a/c", + "test/a/c/d", + "test/a/c/d/c", + "test/a/cb", + "test/a/cb/e", + "test/a/symlink", + "test/a/symlink/a", + "test/a/symlink/a/b", + "test/a/symlink/a/b/c", + "test/a/symlink/a/b/c/a", + "test/a/symlink/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b" + ], + "test/+(a|b|c)/a{/,bc*}/**": [ + "test/a/abcdef", + "test/a/abcdef/g", + "test/a/abcdef/g/h", + "test/a/abcfed", + "test/a/abcfed/g", + "test/a/abcfed/g/h" + ], + "test/*/*/*/f": [ + "test/a/bc/e/f", + "test/a/cb/e/f" + ], + "test/**/f": [ + "test/a/bc/e/f", + "test/a/cb/e/f" + ], + "test/a/symlink/a/b/c/a/b/c/a/b/c//a/b/c////a/b/c/**/b/c/**": [ + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b", + "test/a/symlink/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c/a/b/c" + ], + "{./*/*,/tmp/glob-test/*}": [ + "./examples/g.js", + "./examples/usr-local.js", + "./node_modules/inherits", + "./node_modules/minimatch", + "./node_modules/mkdirp", + "./node_modules/rimraf", + "./node_modules/tap", + "./test/00-setup.js", + "./test/a", + "./test/bash-comparison.js", + "./test/bash-results.json", + "./test/cwd-test.js", + "./test/globstar-match.js", + "./test/mark.js", + "./test/new-glob-optional-options.js", + "./test/nocase-nomagic.js", + "./test/pause-resume.js", + "./test/readme-issue.js", + "./test/root-nomount.js", + "./test/root.js", + "./test/stat.js", + "./test/zz-cleanup.js", + "/tmp/glob-test/asdf", + "/tmp/glob-test/bar", + "/tmp/glob-test/baz", + "/tmp/glob-test/foo", + "/tmp/glob-test/quux", + "/tmp/glob-test/qwer", + "/tmp/glob-test/rewq" + ], + "{/tmp/glob-test/*,*}": [ + "/tmp/glob-test/asdf", + "/tmp/glob-test/bar", + "/tmp/glob-test/baz", + "/tmp/glob-test/foo", + "/tmp/glob-test/quux", + "/tmp/glob-test/qwer", + "/tmp/glob-test/rewq", + "examples", + "glob.js", + "LICENSE", + "node_modules", + "package.json", + "README.md", + "test" + ], + "test/a/!(symlink)/**": [ + "test/a/abcdef", + "test/a/abcdef/g", + "test/a/abcdef/g/h", + "test/a/abcfed", + "test/a/abcfed/g", + "test/a/abcfed/g/h", + "test/a/b", + "test/a/b/c", + "test/a/b/c/d", + "test/a/bc", + "test/a/bc/e", + "test/a/bc/e/f", + "test/a/c", + "test/a/c/d", + "test/a/c/d/c", + "test/a/c/d/c/b", + "test/a/cb", + "test/a/cb/e", + "test/a/cb/e/f" + ] +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/cwd-test.js b/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/cwd-test.js new file mode 100644 index 0000000..352c27e --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/cwd-test.js @@ -0,0 +1,55 @@ +var tap = require("tap") + +var origCwd = process.cwd() +process.chdir(__dirname) + +tap.test("changing cwd and searching for **/d", function (t) { + var glob = require('../') + var path = require('path') + t.test('.', function (t) { + glob('**/d', function (er, matches) { + t.ifError(er) + t.like(matches, [ 'a/b/c/d', 'a/c/d' ]) + t.end() + }) + }) + + t.test('a', function (t) { + glob('**/d', {cwd:path.resolve('a')}, function (er, matches) { + t.ifError(er) + t.like(matches, [ 'b/c/d', 'c/d' ]) + t.end() + }) + }) + + t.test('a/b', function (t) { + glob('**/d', {cwd:path.resolve('a/b')}, function (er, matches) { + t.ifError(er) + t.like(matches, [ 'c/d' ]) + t.end() + }) + }) + + t.test('a/b/', function (t) { + glob('**/d', {cwd:path.resolve('a/b/')}, function (er, matches) { + t.ifError(er) + t.like(matches, [ 'c/d' ]) + t.end() + }) + }) + + t.test('.', function (t) { + glob('**/d', {cwd: process.cwd()}, function (er, matches) { + t.ifError(er) + t.like(matches, [ 'a/b/c/d', 'a/c/d' ]) + t.end() + }) + }) + + t.test('cd -', function (t) { + process.chdir(origCwd) + t.end() + }) + + t.end() +}) diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/globstar-match.js b/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/globstar-match.js new file mode 100644 index 0000000..9b234fa --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/globstar-match.js @@ -0,0 +1,19 @@ +var Glob = require("../glob.js").Glob +var test = require('tap').test + +test('globstar should not have dupe matches', function(t) { + var pattern = 'a/**/[gh]' + var g = new Glob(pattern, { cwd: __dirname }) + var matches = [] + g.on('match', function(m) { + console.error('match %j', m) + matches.push(m) + }) + g.on('end', function(set) { + console.error('set', set) + matches = matches.sort() + set = set.sort() + t.same(matches, set, 'should have same set of matches') + t.end() + }) +}) diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/mark.js b/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/mark.js new file mode 100644 index 0000000..bf411c0 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/mark.js @@ -0,0 +1,118 @@ +var test = require("tap").test +var glob = require('../') +process.chdir(__dirname) + +// expose timing issues +var lag = 5 +glob.Glob.prototype._stat = function(o) { return function(f, cb) { + var args = arguments + setTimeout(function() { + o.call(this, f, cb) + }.bind(this), lag += 5) +}}(glob.Glob.prototype._stat) + + +test("mark, with **", function (t) { + glob("a/*b*/**", {mark: true}, function (er, results) { + if (er) + throw er + var expect = + [ 'a/abcdef/', + 'a/abcdef/g/', + 'a/abcdef/g/h', + 'a/abcfed/', + 'a/abcfed/g/', + 'a/abcfed/g/h', + 'a/b/', + 'a/b/c/', + 'a/b/c/d', + 'a/bc/', + 'a/bc/e/', + 'a/bc/e/f', + 'a/cb/', + 'a/cb/e/', + 'a/cb/e/f' ] + + t.same(results, expect) + t.end() + }) +}) + +test("mark, no / on pattern", function (t) { + glob("a/*", {mark: true}, function (er, results) { + if (er) + throw er + var expect = [ 'a/abcdef/', + 'a/abcfed/', + 'a/b/', + 'a/bc/', + 'a/c/', + 'a/cb/' ] + + if (process.platform !== "win32") + expect.push('a/symlink/') + + t.same(results, expect) + t.end() + }).on('match', function(m) { + t.similar(m, /\/$/) + }) +}) + +test("mark=false, no / on pattern", function (t) { + glob("a/*", function (er, results) { + if (er) + throw er + var expect = [ 'a/abcdef', + 'a/abcfed', + 'a/b', + 'a/bc', + 'a/c', + 'a/cb' ] + + if (process.platform !== "win32") + expect.push('a/symlink') + t.same(results, expect) + t.end() + }).on('match', function(m) { + t.similar(m, /[^\/]$/) + }) +}) + +test("mark=true, / on pattern", function (t) { + glob("a/*/", {mark: true}, function (er, results) { + if (er) + throw er + var expect = [ 'a/abcdef/', + 'a/abcfed/', + 'a/b/', + 'a/bc/', + 'a/c/', + 'a/cb/' ] + if (process.platform !== "win32") + expect.push('a/symlink/') + t.same(results, expect) + t.end() + }).on('match', function(m) { + t.similar(m, /\/$/) + }) +}) + +test("mark=false, / on pattern", function (t) { + glob("a/*/", function (er, results) { + if (er) + throw er + var expect = [ 'a/abcdef/', + 'a/abcfed/', + 'a/b/', + 'a/bc/', + 'a/c/', + 'a/cb/' ] + if (process.platform !== "win32") + expect.push('a/symlink/') + t.same(results, expect) + t.end() + }).on('match', function(m) { + t.similar(m, /\/$/) + }) +}) diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/new-glob-optional-options.js b/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/new-glob-optional-options.js new file mode 100644 index 0000000..3e7dc5a --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/new-glob-optional-options.js @@ -0,0 +1,10 @@ +var Glob = require('../glob.js').Glob; +var test = require('tap').test; + +test('new glob, with cb, and no options', function (t) { + new Glob(__filename, function(er, results) { + if (er) throw er; + t.same(results, [__filename]); + t.end(); + }); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/nocase-nomagic.js b/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/nocase-nomagic.js new file mode 100644 index 0000000..2503f23 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/nocase-nomagic.js @@ -0,0 +1,113 @@ +var fs = require('fs'); +var test = require('tap').test; +var glob = require('../'); + +test('mock fs', function(t) { + var stat = fs.stat + var statSync = fs.statSync + var readdir = fs.readdir + var readdirSync = fs.readdirSync + + function fakeStat(path) { + var ret + switch (path.toLowerCase()) { + case '/tmp': case '/tmp/': + ret = { isDirectory: function() { return true } } + break + case '/tmp/a': + ret = { isDirectory: function() { return false } } + break + } + return ret + } + + fs.stat = function(path, cb) { + var f = fakeStat(path); + if (f) { + process.nextTick(function() { + cb(null, f) + }) + } else { + stat.call(fs, path, cb) + } + } + + fs.statSync = function(path) { + return fakeStat(path) || statSync.call(fs, path) + } + + function fakeReaddir(path) { + var ret + switch (path.toLowerCase()) { + case '/tmp': case '/tmp/': + ret = [ 'a', 'A' ] + break + case '/': + ret = ['tmp', 'tMp', 'tMP', 'TMP'] + } + return ret + } + + fs.readdir = function(path, cb) { + var f = fakeReaddir(path) + if (f) + process.nextTick(function() { + cb(null, f) + }) + else + readdir.call(fs, path, cb) + } + + fs.readdirSync = function(path) { + return fakeReaddir(path) || readdirSync.call(fs, path) + } + + t.pass('mocked') + t.end() +}) + +test('nocase, nomagic', function(t) { + var n = 2 + var want = [ '/TMP/A', + '/TMP/a', + '/tMP/A', + '/tMP/a', + '/tMp/A', + '/tMp/a', + '/tmp/A', + '/tmp/a' ] + glob('/tmp/a', { nocase: true }, function(er, res) { + if (er) + throw er + t.same(res.sort(), want) + if (--n === 0) t.end() + }) + glob('/tmp/A', { nocase: true }, function(er, res) { + if (er) + throw er + t.same(res.sort(), want) + if (--n === 0) t.end() + }) +}) + +test('nocase, with some magic', function(t) { + t.plan(2) + var want = [ '/TMP/A', + '/TMP/a', + '/tMP/A', + '/tMP/a', + '/tMp/A', + '/tMp/a', + '/tmp/A', + '/tmp/a' ] + glob('/tmp/*', { nocase: true }, function(er, res) { + if (er) + throw er + t.same(res.sort(), want) + }) + glob('/tmp/*', { nocase: true }, function(er, res) { + if (er) + throw er + t.same(res.sort(), want) + }) +}) diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/pause-resume.js b/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/pause-resume.js new file mode 100644 index 0000000..e1ffbab --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/pause-resume.js @@ -0,0 +1,73 @@ +// show that no match events happen while paused. +var tap = require("tap") +, child_process = require("child_process") +// just some gnarly pattern with lots of matches +, pattern = "test/a/!(symlink)/**" +, bashResults = require("./bash-results.json") +, patterns = Object.keys(bashResults) +, glob = require("../") +, Glob = glob.Glob +, path = require("path") + +// run from the root of the project +// this is usually where you're at anyway, but be sure. +process.chdir(path.resolve(__dirname, "..")) + +function alphasort (a, b) { + a = a.toLowerCase() + b = b.toLowerCase() + return a > b ? 1 : a < b ? -1 : 0 +} + +function cleanResults (m) { + // normalize discrepancies in ordering, duplication, + // and ending slashes. + return m.map(function (m) { + return m.replace(/\/+/g, "/").replace(/\/$/, "") + }).sort(alphasort).reduce(function (set, f) { + if (f !== set[set.length - 1]) set.push(f) + return set + }, []).sort(alphasort).map(function (f) { + // de-windows + return (process.platform !== 'win32') ? f + : f.replace(/^[a-zA-Z]:\\\\/, '/').replace(/\\/g, '/') + }) +} + +var globResults = [] +tap.test("use a Glob object, and pause/resume it", function (t) { + var g = new Glob(pattern) + , paused = false + , res = [] + , expect = bashResults[pattern] + + g.on("pause", function () { + console.error("pause") + }) + + g.on("resume", function () { + console.error("resume") + }) + + g.on("match", function (m) { + t.notOk(g.paused, "must not be paused") + globResults.push(m) + g.pause() + t.ok(g.paused, "must be paused") + setTimeout(g.resume.bind(g), 10) + }) + + g.on("end", function (matches) { + t.pass("reached glob end") + globResults = cleanResults(globResults) + matches = cleanResults(matches) + t.deepEqual(matches, globResults, + "end event matches should be the same as match events") + + t.deepEqual(matches, expect, + "glob matches should be the same as bash results") + + t.end() + }) +}) + diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/readme-issue.js b/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/readme-issue.js new file mode 100644 index 0000000..0b4e0be --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/readme-issue.js @@ -0,0 +1,36 @@ +var test = require("tap").test +var glob = require("../") + +var mkdirp = require("mkdirp") +var fs = require("fs") +var rimraf = require("rimraf") +var dir = __dirname + "/package" + +test("setup", function (t) { + mkdirp.sync(dir) + fs.writeFileSync(dir + "/package.json", "{}", "ascii") + fs.writeFileSync(dir + "/README", "x", "ascii") + t.pass("setup done") + t.end() +}) + +test("glob", function (t) { + var opt = { + cwd: dir, + nocase: true, + mark: true + } + + glob("README?(.*)", opt, function (er, files) { + if (er) + throw er + t.same(files, ["README"]) + t.end() + }) +}) + +test("cleanup", function (t) { + rimraf.sync(dir) + t.pass("clean") + t.end() +}) diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/root-nomount.js b/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/root-nomount.js new file mode 100644 index 0000000..3ac5979 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/root-nomount.js @@ -0,0 +1,39 @@ +var tap = require("tap") + +var origCwd = process.cwd() +process.chdir(__dirname) + +tap.test("changing root and searching for /b*/**", function (t) { + var glob = require('../') + var path = require('path') + t.test('.', function (t) { + glob('/b*/**', { globDebug: true, root: '.', nomount: true }, function (er, matches) { + t.ifError(er) + t.like(matches, []) + t.end() + }) + }) + + t.test('a', function (t) { + glob('/b*/**', { globDebug: true, root: path.resolve('a'), nomount: true }, function (er, matches) { + t.ifError(er) + t.like(matches, [ '/b', '/b/c', '/b/c/d', '/bc', '/bc/e', '/bc/e/f' ]) + t.end() + }) + }) + + t.test('root=a, cwd=a/b', function (t) { + glob('/b*/**', { globDebug: true, root: 'a', cwd: path.resolve('a/b'), nomount: true }, function (er, matches) { + t.ifError(er) + t.like(matches, [ '/b', '/b/c', '/b/c/d', '/bc', '/bc/e', '/bc/e/f' ]) + t.end() + }) + }) + + t.test('cd -', function (t) { + process.chdir(origCwd) + t.end() + }) + + t.end() +}) diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/root.js b/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/root.js new file mode 100644 index 0000000..95c23f9 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/root.js @@ -0,0 +1,46 @@ +var t = require("tap") + +var origCwd = process.cwd() +process.chdir(__dirname) + +var glob = require('../') +var path = require('path') + +t.test('.', function (t) { + glob('/b*/**', { globDebug: true, root: '.' }, function (er, matches) { + t.ifError(er) + t.like(matches, []) + t.end() + }) +}) + + +t.test('a', function (t) { + console.error("root=" + path.resolve('a')) + glob('/b*/**', { globDebug: true, root: path.resolve('a') }, function (er, matches) { + t.ifError(er) + var wanted = [ + '/b', '/b/c', '/b/c/d', '/bc', '/bc/e', '/bc/e/f' + ].map(function (m) { + return path.join(path.resolve('a'), m).replace(/\\/g, '/') + }) + + t.like(matches, wanted) + t.end() + }) +}) + +t.test('root=a, cwd=a/b', function (t) { + glob('/b*/**', { globDebug: true, root: 'a', cwd: path.resolve('a/b') }, function (er, matches) { + t.ifError(er) + t.like(matches, [ '/b', '/b/c', '/b/c/d', '/bc', '/bc/e', '/bc/e/f' ].map(function (m) { + return path.join(path.resolve('a'), m).replace(/\\/g, '/') + })) + t.end() + }) +}) + +t.test('cd -', function (t) { + process.chdir(origCwd) + t.end() +}) diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/stat.js b/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/stat.js new file mode 100644 index 0000000..6291711 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/stat.js @@ -0,0 +1,32 @@ +var glob = require('../') +var test = require('tap').test +var path = require('path') + +test('stat all the things', function(t) { + var g = new glob.Glob('a/*abc*/**', { stat: true, cwd: __dirname }) + var matches = [] + g.on('match', function(m) { + matches.push(m) + }) + var stats = [] + g.on('stat', function(m) { + stats.push(m) + }) + g.on('end', function(eof) { + stats = stats.sort() + matches = matches.sort() + eof = eof.sort() + t.same(stats, matches) + t.same(eof, matches) + var cache = Object.keys(this.statCache) + t.same(cache.map(function (f) { + return path.relative(__dirname, f) + }).sort(), matches) + + cache.forEach(function(c) { + t.equal(typeof this.statCache[c], 'object') + }, this) + + t.end() + }) +}) diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/zz-cleanup.js b/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/zz-cleanup.js new file mode 100644 index 0000000..e085f0f --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/glob/test/zz-cleanup.js @@ -0,0 +1,11 @@ +// remove the fixtures +var tap = require("tap") +, rimraf = require("rimraf") +, path = require("path") + +tap.test("cleanup fixtures", function (t) { + rimraf(path.resolve(__dirname, "a"), function (er) { + t.ifError(er, "removed") + t.end() + }) +}) diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/inherits/LICENSE b/node_modules/nodeunit/node_modules/tap/node_modules/inherits/LICENSE new file mode 100644 index 0000000..dea3013 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/inherits/LICENSE @@ -0,0 +1,16 @@ +The ISC License + +Copyright (c) Isaac Z. Schlueter + +Permission to use, copy, modify, and/or distribute this software for any +purpose with or without fee is hereby granted, provided that the above +copyright notice and this permission notice appear in all copies. + +THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH +REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND +FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, +INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM +LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR +OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR +PERFORMANCE OF THIS SOFTWARE. + diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/inherits/README.md b/node_modules/nodeunit/node_modules/tap/node_modules/inherits/README.md new file mode 100644 index 0000000..b1c5665 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/inherits/README.md @@ -0,0 +1,42 @@ +Browser-friendly inheritance fully compatible with standard node.js +[inherits](http://nodejs.org/api/util.html#util_util_inherits_constructor_superconstructor). + +This package exports standard `inherits` from node.js `util` module in +node environment, but also provides alternative browser-friendly +implementation through [browser +field](https://gist.github.com/shtylman/4339901). Alternative +implementation is a literal copy of standard one located in standalone +module to avoid requiring of `util`. It also has a shim for old +browsers with no `Object.create` support. + +While keeping you sure you are using standard `inherits` +implementation in node.js environment, it allows bundlers such as +[browserify](https://github.com/substack/node-browserify) to not +include full `util` package to your client code if all you need is +just `inherits` function. It worth, because browser shim for `util` +package is large and `inherits` is often the single function you need +from it. + +It's recommended to use this package instead of +`require('util').inherits` for any code that has chances to be used +not only in node.js but in browser too. + +## usage + +```js +var inherits = require('inherits'); +// then use exactly as the standard one +``` + +## note on version ~1.0 + +Version ~1.0 had completely different motivation and is not compatible +neither with 2.0 nor with standard node.js `inherits`. + +If you are using version ~1.0 and planning to switch to ~2.0, be +careful: + +* new version uses `super_` instead of `super` for referencing + superclass +* new version overwrites current prototype while old one preserves any + existing fields on it diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/inherits/inherits.js b/node_modules/nodeunit/node_modules/tap/node_modules/inherits/inherits.js new file mode 100644 index 0000000..29f5e24 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/inherits/inherits.js @@ -0,0 +1 @@ +module.exports = require('util').inherits diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/inherits/inherits_browser.js b/node_modules/nodeunit/node_modules/tap/node_modules/inherits/inherits_browser.js new file mode 100644 index 0000000..c1e78a7 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/inherits/inherits_browser.js @@ -0,0 +1,23 @@ +if (typeof Object.create === 'function') { + // implementation from standard node.js 'util' module + module.exports = function inherits(ctor, superCtor) { + ctor.super_ = superCtor + ctor.prototype = Object.create(superCtor.prototype, { + constructor: { + value: ctor, + enumerable: false, + writable: true, + configurable: true + } + }); + }; +} else { + // old school shim for old browsers + module.exports = function inherits(ctor, superCtor) { + ctor.super_ = superCtor + var TempCtor = function () {} + TempCtor.prototype = superCtor.prototype + ctor.prototype = new TempCtor() + ctor.prototype.constructor = ctor + } +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/inherits/package.json b/node_modules/nodeunit/node_modules/tap/node_modules/inherits/package.json new file mode 100644 index 0000000..1d7b9d5 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/inherits/package.json @@ -0,0 +1,33 @@ +{ + "name": "inherits", + "description": "Browser-friendly inheritance fully compatible with standard node.js inherits()", + "version": "2.0.1", + "keywords": [ + "inheritance", + "class", + "klass", + "oop", + "object-oriented", + "inherits", + "browser", + "browserify" + ], + "main": "./inherits.js", + "browser": "./inherits_browser.js", + "repository": { + "type": "git", + "url": "git://github.com/isaacs/inherits" + }, + "license": "ISC", + "scripts": { + "test": "node test" + }, + "readme": "Browser-friendly inheritance fully compatible with standard node.js\n[inherits](http://nodejs.org/api/util.html#util_util_inherits_constructor_superconstructor).\n\nThis package exports standard `inherits` from node.js `util` module in\nnode environment, but also provides alternative browser-friendly\nimplementation through [browser\nfield](https://gist.github.com/shtylman/4339901). Alternative\nimplementation is a literal copy of standard one located in standalone\nmodule to avoid requiring of `util`. It also has a shim for old\nbrowsers with no `Object.create` support.\n\nWhile keeping you sure you are using standard `inherits`\nimplementation in node.js environment, it allows bundlers such as\n[browserify](https://github.com/substack/node-browserify) to not\ninclude full `util` package to your client code if all you need is\njust `inherits` function. It worth, because browser shim for `util`\npackage is large and `inherits` is often the single function you need\nfrom it.\n\nIt's recommended to use this package instead of\n`require('util').inherits` for any code that has chances to be used\nnot only in node.js but in browser too.\n\n## usage\n\n```js\nvar inherits = require('inherits');\n// then use exactly as the standard one\n```\n\n## note on version ~1.0\n\nVersion ~1.0 had completely different motivation and is not compatible\nneither with 2.0 nor with standard node.js `inherits`.\n\nIf you are using version ~1.0 and planning to switch to ~2.0, be\ncareful:\n\n* new version uses `super_` instead of `super` for referencing\n superclass\n* new version overwrites current prototype while old one preserves any\n existing fields on it\n", + "readmeFilename": "README.md", + "bugs": { + "url": "https://github.com/isaacs/inherits/issues" + }, + "homepage": "https://github.com/isaacs/inherits", + "_id": "inherits@2.0.1", + "_from": "inherits@*" +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/inherits/test.js b/node_modules/nodeunit/node_modules/tap/node_modules/inherits/test.js new file mode 100644 index 0000000..fc53012 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/inherits/test.js @@ -0,0 +1,25 @@ +var inherits = require('./inherits.js') +var assert = require('assert') + +function test(c) { + assert(c.constructor === Child) + assert(c.constructor.super_ === Parent) + assert(Object.getPrototypeOf(c) === Child.prototype) + assert(Object.getPrototypeOf(Object.getPrototypeOf(c)) === Parent.prototype) + assert(c instanceof Child) + assert(c instanceof Parent) +} + +function Child() { + Parent.call(this) + test(this) +} + +function Parent() {} + +inherits(Child, Parent) + +var c = new Child +test(c) + +console.log('ok') diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/.npmignore b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/.npmignore new file mode 100644 index 0000000..9303c34 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/.npmignore @@ -0,0 +1,2 @@ +node_modules/ +npm-debug.log \ No newline at end of file diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/.travis.yml b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/.travis.yml new file mode 100644 index 0000000..c693a93 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/.travis.yml @@ -0,0 +1,5 @@ +language: node_js +node_js: + - 0.6 + - 0.8 + - "0.10" diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/LICENSE b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/LICENSE new file mode 100644 index 0000000..432d1ae --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/LICENSE @@ -0,0 +1,21 @@ +Copyright 2010 James Halliday (mail@substack.net) + +This project is free software released under the MIT/X11 license: + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/bin/cmd.js b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/bin/cmd.js new file mode 100755 index 0000000..d95de15 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/bin/cmd.js @@ -0,0 +1,33 @@ +#!/usr/bin/env node + +var mkdirp = require('../'); +var minimist = require('minimist'); +var fs = require('fs'); + +var argv = minimist(process.argv.slice(2), { + alias: { m: 'mode', h: 'help' }, + string: [ 'mode' ] +}); +if (argv.help) { + fs.createReadStream(__dirname + '/usage.txt').pipe(process.stdout); + return; +} + +var paths = argv._.slice(); +var mode = argv.mode ? parseInt(argv.mode, 8) : undefined; + +(function next () { + if (paths.length === 0) return; + var p = paths.shift(); + + if (mode === undefined) mkdirp(p, cb) + else mkdirp(p, mode, cb) + + function cb (err) { + if (err) { + console.error(err.message); + process.exit(1); + } + else next(); + } +})(); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/bin/usage.txt b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/bin/usage.txt new file mode 100644 index 0000000..f952aa2 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/bin/usage.txt @@ -0,0 +1,12 @@ +usage: mkdirp [DIR1,DIR2..] {OPTIONS} + + Create each supplied directory including any necessary parent directories that + don't yet exist. + + If the directory already exists, do nothing. + +OPTIONS are: + + -m, --mode If a directory needs to be created, set the mode as an octal + permission string. + diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/examples/pow.js b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/examples/pow.js new file mode 100644 index 0000000..e692421 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/examples/pow.js @@ -0,0 +1,6 @@ +var mkdirp = require('mkdirp'); + +mkdirp('/tmp/foo/bar/baz', function (err) { + if (err) console.error(err) + else console.log('pow!') +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/index.js b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/index.js new file mode 100644 index 0000000..a1742b2 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/index.js @@ -0,0 +1,97 @@ +var path = require('path'); +var fs = require('fs'); + +module.exports = mkdirP.mkdirp = mkdirP.mkdirP = mkdirP; + +function mkdirP (p, opts, f, made) { + if (typeof opts === 'function') { + f = opts; + opts = {}; + } + else if (!opts || typeof opts !== 'object') { + opts = { mode: opts }; + } + + var mode = opts.mode; + var xfs = opts.fs || fs; + + if (mode === undefined) { + mode = 0777 & (~process.umask()); + } + if (!made) made = null; + + var cb = f || function () {}; + p = path.resolve(p); + + xfs.mkdir(p, mode, function (er) { + if (!er) { + made = made || p; + return cb(null, made); + } + switch (er.code) { + case 'ENOENT': + mkdirP(path.dirname(p), opts, function (er, made) { + if (er) cb(er, made); + else mkdirP(p, opts, cb, made); + }); + break; + + // In the case of any other error, just see if there's a dir + // there already. If so, then hooray! If not, then something + // is borked. + default: + xfs.stat(p, function (er2, stat) { + // if the stat fails, then that's super weird. + // let the original error be the failure reason. + if (er2 || !stat.isDirectory()) cb(er, made) + else cb(null, made); + }); + break; + } + }); +} + +mkdirP.sync = function sync (p, opts, made) { + if (!opts || typeof opts !== 'object') { + opts = { mode: opts }; + } + + var mode = opts.mode; + var xfs = opts.fs || fs; + + if (mode === undefined) { + mode = 0777 & (~process.umask()); + } + if (!made) made = null; + + p = path.resolve(p); + + try { + xfs.mkdirSync(p, mode); + made = made || p; + } + catch (err0) { + switch (err0.code) { + case 'ENOENT' : + made = sync(path.dirname(p), opts, made); + sync(p, opts, made); + break; + + // In the case of any other error, just see if there's a dir + // there already. If so, then hooray! If not, then something + // is borked. + default: + var stat; + try { + stat = xfs.statSync(p); + } + catch (err1) { + throw err0; + } + if (!stat.isDirectory()) throw err0; + break; + } + } + + return made; +}; diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/.travis.yml b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/.travis.yml new file mode 100644 index 0000000..cc4dba2 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/.travis.yml @@ -0,0 +1,4 @@ +language: node_js +node_js: + - "0.8" + - "0.10" diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/LICENSE b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/LICENSE new file mode 100644 index 0000000..ee27ba4 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/LICENSE @@ -0,0 +1,18 @@ +This software is released under the MIT license: + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/example/parse.js b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/example/parse.js new file mode 100644 index 0000000..abff3e8 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/example/parse.js @@ -0,0 +1,2 @@ +var argv = require('../')(process.argv.slice(2)); +console.dir(argv); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/index.js b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/index.js new file mode 100644 index 0000000..584f551 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/index.js @@ -0,0 +1,187 @@ +module.exports = function (args, opts) { + if (!opts) opts = {}; + + var flags = { bools : {}, strings : {} }; + + [].concat(opts['boolean']).filter(Boolean).forEach(function (key) { + flags.bools[key] = true; + }); + + [].concat(opts.string).filter(Boolean).forEach(function (key) { + flags.strings[key] = true; + }); + + var aliases = {}; + Object.keys(opts.alias || {}).forEach(function (key) { + aliases[key] = [].concat(opts.alias[key]); + aliases[key].forEach(function (x) { + aliases[x] = [key].concat(aliases[key].filter(function (y) { + return x !== y; + })); + }); + }); + + var defaults = opts['default'] || {}; + + var argv = { _ : [] }; + Object.keys(flags.bools).forEach(function (key) { + setArg(key, defaults[key] === undefined ? false : defaults[key]); + }); + + var notFlags = []; + + if (args.indexOf('--') !== -1) { + notFlags = args.slice(args.indexOf('--')+1); + args = args.slice(0, args.indexOf('--')); + } + + function setArg (key, val) { + var value = !flags.strings[key] && isNumber(val) + ? Number(val) : val + ; + setKey(argv, key.split('.'), value); + + (aliases[key] || []).forEach(function (x) { + setKey(argv, x.split('.'), value); + }); + } + + for (var i = 0; i < args.length; i++) { + var arg = args[i]; + + if (/^--.+=/.test(arg)) { + // Using [\s\S] instead of . because js doesn't support the + // 'dotall' regex modifier. See: + // http://stackoverflow.com/a/1068308/13216 + var m = arg.match(/^--([^=]+)=([\s\S]*)$/); + setArg(m[1], m[2]); + } + else if (/^--no-.+/.test(arg)) { + var key = arg.match(/^--no-(.+)/)[1]; + setArg(key, false); + } + else if (/^--.+/.test(arg)) { + var key = arg.match(/^--(.+)/)[1]; + var next = args[i + 1]; + if (next !== undefined && !/^-/.test(next) + && !flags.bools[key] + && (aliases[key] ? !flags.bools[aliases[key]] : true)) { + setArg(key, next); + i++; + } + else if (/^(true|false)$/.test(next)) { + setArg(key, next === 'true'); + i++; + } + else { + setArg(key, flags.strings[key] ? '' : true); + } + } + else if (/^-[^-]+/.test(arg)) { + var letters = arg.slice(1,-1).split(''); + + var broken = false; + for (var j = 0; j < letters.length; j++) { + var next = arg.slice(j+2); + + if (next === '-') { + setArg(letters[j], next) + continue; + } + + if (/[A-Za-z]/.test(letters[j]) + && /-?\d+(\.\d*)?(e-?\d+)?$/.test(next)) { + setArg(letters[j], next); + broken = true; + break; + } + + if (letters[j+1] && letters[j+1].match(/\W/)) { + setArg(letters[j], arg.slice(j+2)); + broken = true; + break; + } + else { + setArg(letters[j], flags.strings[letters[j]] ? '' : true); + } + } + + var key = arg.slice(-1)[0]; + if (!broken && key !== '-') { + if (args[i+1] && !/^(-|--)[^-]/.test(args[i+1]) + && !flags.bools[key] + && (aliases[key] ? !flags.bools[aliases[key]] : true)) { + setArg(key, args[i+1]); + i++; + } + else if (args[i+1] && /true|false/.test(args[i+1])) { + setArg(key, args[i+1] === 'true'); + i++; + } + else { + setArg(key, flags.strings[key] ? '' : true); + } + } + } + else { + argv._.push( + flags.strings['_'] || !isNumber(arg) ? arg : Number(arg) + ); + } + } + + Object.keys(defaults).forEach(function (key) { + if (!hasKey(argv, key.split('.'))) { + setKey(argv, key.split('.'), defaults[key]); + + (aliases[key] || []).forEach(function (x) { + setKey(argv, x.split('.'), defaults[key]); + }); + } + }); + + notFlags.forEach(function(key) { + argv._.push(key); + }); + + return argv; +}; + +function hasKey (obj, keys) { + var o = obj; + keys.slice(0,-1).forEach(function (key) { + o = (o[key] || {}); + }); + + var key = keys[keys.length - 1]; + return key in o; +} + +function setKey (obj, keys, value) { + var o = obj; + keys.slice(0,-1).forEach(function (key) { + if (o[key] === undefined) o[key] = {}; + o = o[key]; + }); + + var key = keys[keys.length - 1]; + if (o[key] === undefined || typeof o[key] === 'boolean') { + o[key] = value; + } + else if (Array.isArray(o[key])) { + o[key].push(value); + } + else { + o[key] = [ o[key], value ]; + } +} + +function isNumber (x) { + if (typeof x === 'number') return true; + if (/^0x[0-9a-f]+$/i.test(x)) return true; + return /^[-+]?(?:\d+(?:\.\d*)?|\.\d+)(e[-+]?\d+)?$/.test(x); +} + +function longest (xs) { + return Math.max.apply(null, xs.map(function (x) { return x.length })); +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/package.json b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/package.json new file mode 100644 index 0000000..09e9ec4 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/package.json @@ -0,0 +1,67 @@ +{ + "name": "minimist", + "version": "0.0.8", + "description": "parse argument options", + "main": "index.js", + "devDependencies": { + "tape": "~1.0.4", + "tap": "~0.4.0" + }, + "scripts": { + "test": "tap test/*.js" + }, + "testling": { + "files": "test/*.js", + "browsers": [ + "ie/6..latest", + "ff/5", + "firefox/latest", + "chrome/10", + "chrome/latest", + "safari/5.1", + "safari/latest", + "opera/12" + ] + }, + "repository": { + "type": "git", + "url": "git://github.com/substack/minimist.git" + }, + "homepage": "https://github.com/substack/minimist", + "keywords": [ + "argv", + "getopt", + "parser", + "optimist" + ], + "author": { + "name": "James Halliday", + "email": "mail@substack.net", + "url": "http://substack.net" + }, + "license": "MIT", + "bugs": { + "url": "https://github.com/substack/minimist/issues" + }, + "_id": "minimist@0.0.8", + "dist": { + "shasum": "857fcabfc3397d2625b8228262e86aa7a011b05d", + "tarball": "http://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz" + }, + "_from": "minimist@0.0.8", + "_npmVersion": "1.4.3", + "_npmUser": { + "name": "substack", + "email": "mail@substack.net" + }, + "maintainers": [ + { + "name": "substack", + "email": "mail@substack.net" + } + ], + "directories": {}, + "_shasum": "857fcabfc3397d2625b8228262e86aa7a011b05d", + "_resolved": "https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/readme.markdown b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/readme.markdown new file mode 100644 index 0000000..c256353 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/readme.markdown @@ -0,0 +1,73 @@ +# minimist + +parse argument options + +This module is the guts of optimist's argument parser without all the +fanciful decoration. + +[![browser support](https://ci.testling.com/substack/minimist.png)](http://ci.testling.com/substack/minimist) + +[![build status](https://secure.travis-ci.org/substack/minimist.png)](http://travis-ci.org/substack/minimist) + +# example + +``` js +var argv = require('minimist')(process.argv.slice(2)); +console.dir(argv); +``` + +``` +$ node example/parse.js -a beep -b boop +{ _: [], a: 'beep', b: 'boop' } +``` + +``` +$ node example/parse.js -x 3 -y 4 -n5 -abc --beep=boop foo bar baz +{ _: [ 'foo', 'bar', 'baz' ], + x: 3, + y: 4, + n: 5, + a: true, + b: true, + c: true, + beep: 'boop' } +``` + +# methods + +``` js +var parseArgs = require('minimist') +``` + +## var argv = parseArgs(args, opts={}) + +Return an argument object `argv` populated with the array arguments from `args`. + +`argv._` contains all the arguments that didn't have an option associated with +them. + +Numeric-looking arguments will be returned as numbers unless `opts.string` or +`opts.boolean` is set for that argument name. + +Any arguments after `'--'` will not be parsed and will end up in `argv._`. + +options can be: + +* `opts.string` - a string or array of strings argument names to always treat as +strings +* `opts.boolean` - a string or array of strings to always treat as booleans +* `opts.alias` - an object mapping string names to strings or arrays of string +argument names to use as aliases +* `opts.default` - an object mapping string argument names to default values + +# install + +With [npm](https://npmjs.org) do: + +``` +npm install minimist +``` + +# license + +MIT diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/test/dash.js b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/test/dash.js new file mode 100644 index 0000000..8b034b9 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/test/dash.js @@ -0,0 +1,24 @@ +var parse = require('../'); +var test = require('tape'); + +test('-', function (t) { + t.plan(5); + t.deepEqual(parse([ '-n', '-' ]), { n: '-', _: [] }); + t.deepEqual(parse([ '-' ]), { _: [ '-' ] }); + t.deepEqual(parse([ '-f-' ]), { f: '-', _: [] }); + t.deepEqual( + parse([ '-b', '-' ], { boolean: 'b' }), + { b: true, _: [ '-' ] } + ); + t.deepEqual( + parse([ '-s', '-' ], { string: 's' }), + { s: '-', _: [] } + ); +}); + +test('-a -- b', function (t) { + t.plan(3); + t.deepEqual(parse([ '-a', '--', 'b' ]), { a: true, _: [ 'b' ] }); + t.deepEqual(parse([ '--a', '--', 'b' ]), { a: true, _: [ 'b' ] }); + t.deepEqual(parse([ '--a', '--', 'b' ]), { a: true, _: [ 'b' ] }); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/test/default_bool.js b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/test/default_bool.js new file mode 100644 index 0000000..f0041ee --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/test/default_bool.js @@ -0,0 +1,20 @@ +var test = require('tape'); +var parse = require('../'); + +test('boolean default true', function (t) { + var argv = parse([], { + boolean: 'sometrue', + default: { sometrue: true } + }); + t.equal(argv.sometrue, true); + t.end(); +}); + +test('boolean default false', function (t) { + var argv = parse([], { + boolean: 'somefalse', + default: { somefalse: false } + }); + t.equal(argv.somefalse, false); + t.end(); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/test/dotted.js b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/test/dotted.js new file mode 100644 index 0000000..ef0ae34 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/test/dotted.js @@ -0,0 +1,16 @@ +var parse = require('../'); +var test = require('tape'); + +test('dotted alias', function (t) { + var argv = parse(['--a.b', '22'], {default: {'a.b': 11}, alias: {'a.b': 'aa.bb'}}); + t.equal(argv.a.b, 22); + t.equal(argv.aa.bb, 22); + t.end(); +}); + +test('dotted default', function (t) { + var argv = parse('', {default: {'a.b': 11}, alias: {'a.b': 'aa.bb'}}); + t.equal(argv.a.b, 11); + t.equal(argv.aa.bb, 11); + t.end(); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/test/long.js b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/test/long.js new file mode 100644 index 0000000..5d3a1e0 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/test/long.js @@ -0,0 +1,31 @@ +var test = require('tape'); +var parse = require('../'); + +test('long opts', function (t) { + t.deepEqual( + parse([ '--bool' ]), + { bool : true, _ : [] }, + 'long boolean' + ); + t.deepEqual( + parse([ '--pow', 'xixxle' ]), + { pow : 'xixxle', _ : [] }, + 'long capture sp' + ); + t.deepEqual( + parse([ '--pow=xixxle' ]), + { pow : 'xixxle', _ : [] }, + 'long capture eq' + ); + t.deepEqual( + parse([ '--host', 'localhost', '--port', '555' ]), + { host : 'localhost', port : 555, _ : [] }, + 'long captures sp' + ); + t.deepEqual( + parse([ '--host=localhost', '--port=555' ]), + { host : 'localhost', port : 555, _ : [] }, + 'long captures eq' + ); + t.end(); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/test/parse.js b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/test/parse.js new file mode 100644 index 0000000..8a90646 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/test/parse.js @@ -0,0 +1,318 @@ +var parse = require('../'); +var test = require('tape'); + +test('parse args', function (t) { + t.deepEqual( + parse([ '--no-moo' ]), + { moo : false, _ : [] }, + 'no' + ); + t.deepEqual( + parse([ '-v', 'a', '-v', 'b', '-v', 'c' ]), + { v : ['a','b','c'], _ : [] }, + 'multi' + ); + t.end(); +}); + +test('comprehensive', function (t) { + t.deepEqual( + parse([ + '--name=meowmers', 'bare', '-cats', 'woo', + '-h', 'awesome', '--multi=quux', + '--key', 'value', + '-b', '--bool', '--no-meep', '--multi=baz', + '--', '--not-a-flag', 'eek' + ]), + { + c : true, + a : true, + t : true, + s : 'woo', + h : 'awesome', + b : true, + bool : true, + key : 'value', + multi : [ 'quux', 'baz' ], + meep : false, + name : 'meowmers', + _ : [ 'bare', '--not-a-flag', 'eek' ] + } + ); + t.end(); +}); + +test('nums', function (t) { + var argv = parse([ + '-x', '1234', + '-y', '5.67', + '-z', '1e7', + '-w', '10f', + '--hex', '0xdeadbeef', + '789' + ]); + t.deepEqual(argv, { + x : 1234, + y : 5.67, + z : 1e7, + w : '10f', + hex : 0xdeadbeef, + _ : [ 789 ] + }); + t.deepEqual(typeof argv.x, 'number'); + t.deepEqual(typeof argv.y, 'number'); + t.deepEqual(typeof argv.z, 'number'); + t.deepEqual(typeof argv.w, 'string'); + t.deepEqual(typeof argv.hex, 'number'); + t.deepEqual(typeof argv._[0], 'number'); + t.end(); +}); + +test('flag boolean', function (t) { + var argv = parse([ '-t', 'moo' ], { boolean: 't' }); + t.deepEqual(argv, { t : true, _ : [ 'moo' ] }); + t.deepEqual(typeof argv.t, 'boolean'); + t.end(); +}); + +test('flag boolean value', function (t) { + var argv = parse(['--verbose', 'false', 'moo', '-t', 'true'], { + boolean: [ 't', 'verbose' ], + default: { verbose: true } + }); + + t.deepEqual(argv, { + verbose: false, + t: true, + _: ['moo'] + }); + + t.deepEqual(typeof argv.verbose, 'boolean'); + t.deepEqual(typeof argv.t, 'boolean'); + t.end(); +}); + +test('flag boolean default false', function (t) { + var argv = parse(['moo'], { + boolean: ['t', 'verbose'], + default: { verbose: false, t: false } + }); + + t.deepEqual(argv, { + verbose: false, + t: false, + _: ['moo'] + }); + + t.deepEqual(typeof argv.verbose, 'boolean'); + t.deepEqual(typeof argv.t, 'boolean'); + t.end(); + +}); + +test('boolean groups', function (t) { + var argv = parse([ '-x', '-z', 'one', 'two', 'three' ], { + boolean: ['x','y','z'] + }); + + t.deepEqual(argv, { + x : true, + y : false, + z : true, + _ : [ 'one', 'two', 'three' ] + }); + + t.deepEqual(typeof argv.x, 'boolean'); + t.deepEqual(typeof argv.y, 'boolean'); + t.deepEqual(typeof argv.z, 'boolean'); + t.end(); +}); + +test('newlines in params' , function (t) { + var args = parse([ '-s', "X\nX" ]) + t.deepEqual(args, { _ : [], s : "X\nX" }); + + // reproduce in bash: + // VALUE="new + // line" + // node program.js --s="$VALUE" + args = parse([ "--s=X\nX" ]) + t.deepEqual(args, { _ : [], s : "X\nX" }); + t.end(); +}); + +test('strings' , function (t) { + var s = parse([ '-s', '0001234' ], { string: 's' }).s; + t.equal(s, '0001234'); + t.equal(typeof s, 'string'); + + var x = parse([ '-x', '56' ], { string: 'x' }).x; + t.equal(x, '56'); + t.equal(typeof x, 'string'); + t.end(); +}); + +test('stringArgs', function (t) { + var s = parse([ ' ', ' ' ], { string: '_' })._; + t.same(s.length, 2); + t.same(typeof s[0], 'string'); + t.same(s[0], ' '); + t.same(typeof s[1], 'string'); + t.same(s[1], ' '); + t.end(); +}); + +test('empty strings', function(t) { + var s = parse([ '-s' ], { string: 's' }).s; + t.equal(s, ''); + t.equal(typeof s, 'string'); + + var str = parse([ '--str' ], { string: 'str' }).str; + t.equal(str, ''); + t.equal(typeof str, 'string'); + + var letters = parse([ '-art' ], { + string: [ 'a', 't' ] + }); + + t.equal(letters.a, ''); + t.equal(letters.r, true); + t.equal(letters.t, ''); + + t.end(); +}); + + +test('slashBreak', function (t) { + t.same( + parse([ '-I/foo/bar/baz' ]), + { I : '/foo/bar/baz', _ : [] } + ); + t.same( + parse([ '-xyz/foo/bar/baz' ]), + { x : true, y : true, z : '/foo/bar/baz', _ : [] } + ); + t.end(); +}); + +test('alias', function (t) { + var argv = parse([ '-f', '11', '--zoom', '55' ], { + alias: { z: 'zoom' } + }); + t.equal(argv.zoom, 55); + t.equal(argv.z, argv.zoom); + t.equal(argv.f, 11); + t.end(); +}); + +test('multiAlias', function (t) { + var argv = parse([ '-f', '11', '--zoom', '55' ], { + alias: { z: [ 'zm', 'zoom' ] } + }); + t.equal(argv.zoom, 55); + t.equal(argv.z, argv.zoom); + t.equal(argv.z, argv.zm); + t.equal(argv.f, 11); + t.end(); +}); + +test('nested dotted objects', function (t) { + var argv = parse([ + '--foo.bar', '3', '--foo.baz', '4', + '--foo.quux.quibble', '5', '--foo.quux.o_O', + '--beep.boop' + ]); + + t.same(argv.foo, { + bar : 3, + baz : 4, + quux : { + quibble : 5, + o_O : true + } + }); + t.same(argv.beep, { boop : true }); + t.end(); +}); + +test('boolean and alias with chainable api', function (t) { + var aliased = [ '-h', 'derp' ]; + var regular = [ '--herp', 'derp' ]; + var opts = { + herp: { alias: 'h', boolean: true } + }; + var aliasedArgv = parse(aliased, { + boolean: 'herp', + alias: { h: 'herp' } + }); + var propertyArgv = parse(regular, { + boolean: 'herp', + alias: { h: 'herp' } + }); + var expected = { + herp: true, + h: true, + '_': [ 'derp' ] + }; + + t.same(aliasedArgv, expected); + t.same(propertyArgv, expected); + t.end(); +}); + +test('boolean and alias with options hash', function (t) { + var aliased = [ '-h', 'derp' ]; + var regular = [ '--herp', 'derp' ]; + var opts = { + alias: { 'h': 'herp' }, + boolean: 'herp' + }; + var aliasedArgv = parse(aliased, opts); + var propertyArgv = parse(regular, opts); + var expected = { + herp: true, + h: true, + '_': [ 'derp' ] + }; + t.same(aliasedArgv, expected); + t.same(propertyArgv, expected); + t.end(); +}); + +test('boolean and alias using explicit true', function (t) { + var aliased = [ '-h', 'true' ]; + var regular = [ '--herp', 'true' ]; + var opts = { + alias: { h: 'herp' }, + boolean: 'h' + }; + var aliasedArgv = parse(aliased, opts); + var propertyArgv = parse(regular, opts); + var expected = { + herp: true, + h: true, + '_': [ ] + }; + + t.same(aliasedArgv, expected); + t.same(propertyArgv, expected); + t.end(); +}); + +// regression, see https://github.com/substack/node-optimist/issues/71 +test('boolean and --x=true', function(t) { + var parsed = parse(['--boool', '--other=true'], { + boolean: 'boool' + }); + + t.same(parsed.boool, true); + t.same(parsed.other, 'true'); + + parsed = parse(['--boool', '--other=false'], { + boolean: 'boool' + }); + + t.same(parsed.boool, true); + t.same(parsed.other, 'false'); + t.end(); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/test/parse_modified.js b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/test/parse_modified.js new file mode 100644 index 0000000..21851b0 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/test/parse_modified.js @@ -0,0 +1,9 @@ +var parse = require('../'); +var test = require('tape'); + +test('parse with modifier functions' , function (t) { + t.plan(1); + + var argv = parse([ '-b', '123' ], { boolean: 'b' }); + t.deepEqual(argv, { b: true, _: ['123'] }); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/test/short.js b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/test/short.js new file mode 100644 index 0000000..d513a1c --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/test/short.js @@ -0,0 +1,67 @@ +var parse = require('../'); +var test = require('tape'); + +test('numeric short args', function (t) { + t.plan(2); + t.deepEqual(parse([ '-n123' ]), { n: 123, _: [] }); + t.deepEqual( + parse([ '-123', '456' ]), + { 1: true, 2: true, 3: 456, _: [] } + ); +}); + +test('short', function (t) { + t.deepEqual( + parse([ '-b' ]), + { b : true, _ : [] }, + 'short boolean' + ); + t.deepEqual( + parse([ 'foo', 'bar', 'baz' ]), + { _ : [ 'foo', 'bar', 'baz' ] }, + 'bare' + ); + t.deepEqual( + parse([ '-cats' ]), + { c : true, a : true, t : true, s : true, _ : [] }, + 'group' + ); + t.deepEqual( + parse([ '-cats', 'meow' ]), + { c : true, a : true, t : true, s : 'meow', _ : [] }, + 'short group next' + ); + t.deepEqual( + parse([ '-h', 'localhost' ]), + { h : 'localhost', _ : [] }, + 'short capture' + ); + t.deepEqual( + parse([ '-h', 'localhost', '-p', '555' ]), + { h : 'localhost', p : 555, _ : [] }, + 'short captures' + ); + t.end(); +}); + +test('mixed short bool and capture', function (t) { + t.same( + parse([ '-h', 'localhost', '-fp', '555', 'script.js' ]), + { + f : true, p : 555, h : 'localhost', + _ : [ 'script.js' ] + } + ); + t.end(); +}); + +test('short and long', function (t) { + t.deepEqual( + parse([ '-h', 'localhost', '-fp', '555', 'script.js' ]), + { + f : true, p : 555, h : 'localhost', + _ : [ 'script.js' ] + } + ); + t.end(); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/test/whitespace.js b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/test/whitespace.js new file mode 100644 index 0000000..8a52a58 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist/test/whitespace.js @@ -0,0 +1,8 @@ +var parse = require('../'); +var test = require('tape'); + +test('whitespace should be whitespace' , function (t) { + t.plan(1); + var x = parse([ '-x', '\t' ]).x; + t.equal(x, '\t'); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/package.json b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/package.json new file mode 100644 index 0000000..d4ee0e5 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/package.json @@ -0,0 +1,58 @@ +{ + "name": "mkdirp", + "description": "Recursively mkdir, like `mkdir -p`", + "version": "0.5.0", + "author": { + "name": "James Halliday", + "email": "mail@substack.net", + "url": "http://substack.net" + }, + "main": "./index", + "keywords": [ + "mkdir", + "directory" + ], + "repository": { + "type": "git", + "url": "https://github.com/substack/node-mkdirp.git" + }, + "scripts": { + "test": "tap test/*.js" + }, + "dependencies": { + "minimist": "0.0.8" + }, + "devDependencies": { + "tap": "~0.4.0", + "mock-fs": "~2.2.0" + }, + "bin": { + "mkdirp": "bin/cmd.js" + }, + "license": "MIT", + "bugs": { + "url": "https://github.com/substack/node-mkdirp/issues" + }, + "homepage": "https://github.com/substack/node-mkdirp", + "_id": "mkdirp@0.5.0", + "dist": { + "shasum": "1d73076a6df986cd9344e15e71fcc05a4c9abf12", + "tarball": "http://registry.npmjs.org/mkdirp/-/mkdirp-0.5.0.tgz" + }, + "_from": "mkdirp@~0.3 || 0.4 || 0.5", + "_npmVersion": "1.4.3", + "_npmUser": { + "name": "substack", + "email": "mail@substack.net" + }, + "maintainers": [ + { + "name": "substack", + "email": "mail@substack.net" + } + ], + "directories": {}, + "_shasum": "1d73076a6df986cd9344e15e71fcc05a4c9abf12", + "_resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.0.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/readme.markdown b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/readme.markdown new file mode 100644 index 0000000..3cc1315 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/readme.markdown @@ -0,0 +1,100 @@ +# mkdirp + +Like `mkdir -p`, but in node.js! + +[![build status](https://secure.travis-ci.org/substack/node-mkdirp.png)](http://travis-ci.org/substack/node-mkdirp) + +# example + +## pow.js + +```js +var mkdirp = require('mkdirp'); + +mkdirp('/tmp/foo/bar/baz', function (err) { + if (err) console.error(err) + else console.log('pow!') +}); +``` + +Output + +``` +pow! +``` + +And now /tmp/foo/bar/baz exists, huzzah! + +# methods + +```js +var mkdirp = require('mkdirp'); +``` + +## mkdirp(dir, opts, cb) + +Create a new directory and any necessary subdirectories at `dir` with octal +permission string `opts.mode`. If `opts` is a non-object, it will be treated as +the `opts.mode`. + +If `opts.mode` isn't specified, it defaults to `0777 & (~process.umask())`. + +`cb(err, made)` fires with the error or the first directory `made` +that had to be created, if any. + +You can optionally pass in an alternate `fs` implementation by passing in +`opts.fs`. Your implementation should have `opts.fs.mkdir(path, mode, cb)` and +`opts.fs.stat(path, cb)`. + +## mkdirp.sync(dir, opts) + +Synchronously create a new directory and any necessary subdirectories at `dir` +with octal permission string `opts.mode`. If `opts` is a non-object, it will be +treated as the `opts.mode`. + +If `opts.mode` isn't specified, it defaults to `0777 & (~process.umask())`. + +Returns the first directory that had to be created, if any. + +You can optionally pass in an alternate `fs` implementation by passing in +`opts.fs`. Your implementation should have `opts.fs.mkdirSync(path, mode)` and +`opts.fs.statSync(path)`. + +# usage + +This package also ships with a `mkdirp` command. + +``` +usage: mkdirp [DIR1,DIR2..] {OPTIONS} + + Create each supplied directory including any necessary parent directories that + don't yet exist. + + If the directory already exists, do nothing. + +OPTIONS are: + + -m, --mode If a directory needs to be created, set the mode as an octal + permission string. + +``` + +# install + +With [npm](http://npmjs.org) do: + +``` +npm install mkdirp +``` + +to get the library, or + +``` +npm install -g mkdirp +``` + +to get the command. + +# license + +MIT diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/chmod.js b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/chmod.js new file mode 100644 index 0000000..520dcb8 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/chmod.js @@ -0,0 +1,38 @@ +var mkdirp = require('../').mkdirp; +var path = require('path'); +var fs = require('fs'); +var test = require('tap').test; + +var ps = [ '', 'tmp' ]; + +for (var i = 0; i < 25; i++) { + var dir = Math.floor(Math.random() * Math.pow(16,4)).toString(16); + ps.push(dir); +} + +var file = ps.join('/'); + +test('chmod-pre', function (t) { + var mode = 0744 + mkdirp(file, mode, function (er) { + t.ifError(er, 'should not error'); + fs.stat(file, function (er, stat) { + t.ifError(er, 'should exist'); + t.ok(stat && stat.isDirectory(), 'should be directory'); + t.equal(stat && stat.mode & 0777, mode, 'should be 0744'); + t.end(); + }); + }); +}); + +test('chmod', function (t) { + var mode = 0755 + mkdirp(file, mode, function (er) { + t.ifError(er, 'should not error'); + fs.stat(file, function (er, stat) { + t.ifError(er, 'should exist'); + t.ok(stat && stat.isDirectory(), 'should be directory'); + t.end(); + }); + }); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/clobber.js b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/clobber.js new file mode 100644 index 0000000..0eb7099 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/clobber.js @@ -0,0 +1,37 @@ +var mkdirp = require('../').mkdirp; +var path = require('path'); +var fs = require('fs'); +var test = require('tap').test; + +var ps = [ '', 'tmp' ]; + +for (var i = 0; i < 25; i++) { + var dir = Math.floor(Math.random() * Math.pow(16,4)).toString(16); + ps.push(dir); +} + +var file = ps.join('/'); + +// a file in the way +var itw = ps.slice(0, 3).join('/'); + + +test('clobber-pre', function (t) { + console.error("about to write to "+itw) + fs.writeFileSync(itw, 'I AM IN THE WAY, THE TRUTH, AND THE LIGHT.'); + + fs.stat(itw, function (er, stat) { + t.ifError(er) + t.ok(stat && stat.isFile(), 'should be file') + t.end() + }) +}) + +test('clobber', function (t) { + t.plan(2); + mkdirp(file, 0755, function (err) { + t.ok(err); + t.equal(err.code, 'ENOTDIR'); + t.end(); + }); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/mkdirp.js b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/mkdirp.js new file mode 100644 index 0000000..3b624dd --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/mkdirp.js @@ -0,0 +1,26 @@ +var mkdirp = require('../'); +var path = require('path'); +var fs = require('fs'); +var exists = fs.exists || path.exists; +var test = require('tap').test; + +test('woo', function (t) { + t.plan(5); + var x = Math.floor(Math.random() * Math.pow(16,4)).toString(16); + var y = Math.floor(Math.random() * Math.pow(16,4)).toString(16); + var z = Math.floor(Math.random() * Math.pow(16,4)).toString(16); + + var file = '/tmp/' + [x,y,z].join('/'); + + mkdirp(file, 0755, function (err) { + t.ifError(err); + exists(file, function (ex) { + t.ok(ex, 'file created'); + fs.stat(file, function (err, stat) { + t.ifError(err); + t.equal(stat.mode & 0777, 0755); + t.ok(stat.isDirectory(), 'target not a directory'); + }) + }) + }); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/opts_fs.js b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/opts_fs.js new file mode 100644 index 0000000..f1fbeca --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/opts_fs.js @@ -0,0 +1,27 @@ +var mkdirp = require('../'); +var path = require('path'); +var test = require('tap').test; +var mockfs = require('mock-fs'); + +test('opts.fs', function (t) { + t.plan(5); + + var x = Math.floor(Math.random() * Math.pow(16,4)).toString(16); + var y = Math.floor(Math.random() * Math.pow(16,4)).toString(16); + var z = Math.floor(Math.random() * Math.pow(16,4)).toString(16); + + var file = '/beep/boop/' + [x,y,z].join('/'); + var xfs = mockfs.fs(); + + mkdirp(file, { fs: xfs, mode: 0755 }, function (err) { + t.ifError(err); + xfs.exists(file, function (ex) { + t.ok(ex, 'created file'); + xfs.stat(file, function (err, stat) { + t.ifError(err); + t.equal(stat.mode & 0777, 0755); + t.ok(stat.isDirectory(), 'target not a directory'); + }); + }); + }); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/opts_fs_sync.js b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/opts_fs_sync.js new file mode 100644 index 0000000..224b506 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/opts_fs_sync.js @@ -0,0 +1,25 @@ +var mkdirp = require('../'); +var path = require('path'); +var test = require('tap').test; +var mockfs = require('mock-fs'); + +test('opts.fs sync', function (t) { + t.plan(4); + + var x = Math.floor(Math.random() * Math.pow(16,4)).toString(16); + var y = Math.floor(Math.random() * Math.pow(16,4)).toString(16); + var z = Math.floor(Math.random() * Math.pow(16,4)).toString(16); + + var file = '/beep/boop/' + [x,y,z].join('/'); + var xfs = mockfs.fs(); + + mkdirp.sync(file, { fs: xfs, mode: 0755 }); + xfs.exists(file, function (ex) { + t.ok(ex, 'created file'); + xfs.stat(file, function (err, stat) { + t.ifError(err); + t.equal(stat.mode & 0777, 0755); + t.ok(stat.isDirectory(), 'target not a directory'); + }); + }); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/perm.js b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/perm.js new file mode 100644 index 0000000..2c97590 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/perm.js @@ -0,0 +1,30 @@ +var mkdirp = require('../'); +var path = require('path'); +var fs = require('fs'); +var exists = fs.exists || path.exists; +var test = require('tap').test; + +test('async perm', function (t) { + t.plan(5); + var file = '/tmp/' + (Math.random() * (1<<30)).toString(16); + + mkdirp(file, 0755, function (err) { + t.ifError(err); + exists(file, function (ex) { + t.ok(ex, 'file created'); + fs.stat(file, function (err, stat) { + t.ifError(err); + t.equal(stat.mode & 0777, 0755); + t.ok(stat.isDirectory(), 'target not a directory'); + }) + }) + }); +}); + +test('async root perm', function (t) { + mkdirp('/tmp', 0755, function (err) { + if (err) t.fail(err); + t.end(); + }); + t.end(); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/perm_sync.js b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/perm_sync.js new file mode 100644 index 0000000..327e54b --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/perm_sync.js @@ -0,0 +1,34 @@ +var mkdirp = require('../'); +var path = require('path'); +var fs = require('fs'); +var exists = fs.exists || path.exists; +var test = require('tap').test; + +test('sync perm', function (t) { + t.plan(4); + var file = '/tmp/' + (Math.random() * (1<<30)).toString(16) + '.json'; + + mkdirp.sync(file, 0755); + exists(file, function (ex) { + t.ok(ex, 'file created'); + fs.stat(file, function (err, stat) { + t.ifError(err); + t.equal(stat.mode & 0777, 0755); + t.ok(stat.isDirectory(), 'target not a directory'); + }); + }); +}); + +test('sync root perm', function (t) { + t.plan(3); + + var file = '/tmp'; + mkdirp.sync(file, 0755); + exists(file, function (ex) { + t.ok(ex, 'file created'); + fs.stat(file, function (err, stat) { + t.ifError(err); + t.ok(stat.isDirectory(), 'target not a directory'); + }) + }); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/race.js b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/race.js new file mode 100644 index 0000000..7c295f4 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/race.js @@ -0,0 +1,40 @@ +var mkdirp = require('../').mkdirp; +var path = require('path'); +var fs = require('fs'); +var exists = fs.exists || path.exists; +var test = require('tap').test; + +test('race', function (t) { + t.plan(6); + var ps = [ '', 'tmp' ]; + + for (var i = 0; i < 25; i++) { + var dir = Math.floor(Math.random() * Math.pow(16,4)).toString(16); + ps.push(dir); + } + var file = ps.join('/'); + + var res = 2; + mk(file, function () { + if (--res === 0) t.end(); + }); + + mk(file, function () { + if (--res === 0) t.end(); + }); + + function mk (file, cb) { + mkdirp(file, 0755, function (err) { + t.ifError(err); + exists(file, function (ex) { + t.ok(ex, 'file created'); + fs.stat(file, function (err, stat) { + t.ifError(err); + t.equal(stat.mode & 0777, 0755); + t.ok(stat.isDirectory(), 'target not a directory'); + if (cb) cb(); + }); + }) + }); + } +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/rel.js b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/rel.js new file mode 100644 index 0000000..d1f175c --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/rel.js @@ -0,0 +1,30 @@ +var mkdirp = require('../'); +var path = require('path'); +var fs = require('fs'); +var exists = fs.exists || path.exists; +var test = require('tap').test; + +test('rel', function (t) { + t.plan(5); + var x = Math.floor(Math.random() * Math.pow(16,4)).toString(16); + var y = Math.floor(Math.random() * Math.pow(16,4)).toString(16); + var z = Math.floor(Math.random() * Math.pow(16,4)).toString(16); + + var cwd = process.cwd(); + process.chdir('/tmp'); + + var file = [x,y,z].join('/'); + + mkdirp(file, 0755, function (err) { + t.ifError(err); + exists(file, function (ex) { + t.ok(ex, 'file created'); + fs.stat(file, function (err, stat) { + t.ifError(err); + process.chdir(cwd); + t.equal(stat.mode & 0777, 0755); + t.ok(stat.isDirectory(), 'target not a directory'); + }) + }) + }); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/return.js b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/return.js new file mode 100644 index 0000000..bce68e5 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/return.js @@ -0,0 +1,25 @@ +var mkdirp = require('../'); +var path = require('path'); +var fs = require('fs'); +var test = require('tap').test; + +test('return value', function (t) { + t.plan(4); + var x = Math.floor(Math.random() * Math.pow(16,4)).toString(16); + var y = Math.floor(Math.random() * Math.pow(16,4)).toString(16); + var z = Math.floor(Math.random() * Math.pow(16,4)).toString(16); + + var file = '/tmp/' + [x,y,z].join('/'); + + // should return the first dir created. + // By this point, it would be profoundly surprising if /tmp didn't + // already exist, since every other test makes things in there. + mkdirp(file, function (err, made) { + t.ifError(err); + t.equal(made, '/tmp/' + x); + mkdirp(file, function (err, made) { + t.ifError(err); + t.equal(made, null); + }); + }); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/return_sync.js b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/return_sync.js new file mode 100644 index 0000000..7c222d3 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/return_sync.js @@ -0,0 +1,24 @@ +var mkdirp = require('../'); +var path = require('path'); +var fs = require('fs'); +var test = require('tap').test; + +test('return value', function (t) { + t.plan(2); + var x = Math.floor(Math.random() * Math.pow(16,4)).toString(16); + var y = Math.floor(Math.random() * Math.pow(16,4)).toString(16); + var z = Math.floor(Math.random() * Math.pow(16,4)).toString(16); + + var file = '/tmp/' + [x,y,z].join('/'); + + // should return the first dir created. + // By this point, it would be profoundly surprising if /tmp didn't + // already exist, since every other test makes things in there. + // Note that this will throw on failure, which will fail the test. + var made = mkdirp.sync(file); + t.equal(made, '/tmp/' + x); + + // making the same file again should have no effect. + made = mkdirp.sync(file); + t.equal(made, null); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/root.js b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/root.js new file mode 100644 index 0000000..97ad7a2 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/root.js @@ -0,0 +1,18 @@ +var mkdirp = require('../'); +var path = require('path'); +var fs = require('fs'); +var test = require('tap').test; + +test('root', function (t) { + // '/' on unix, 'c:/' on windows. + var file = path.resolve('/'); + + mkdirp(file, 0755, function (err) { + if (err) throw err + fs.stat(file, function (er, stat) { + if (er) throw er + t.ok(stat.isDirectory(), 'target is a directory'); + t.end(); + }) + }); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/sync.js b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/sync.js new file mode 100644 index 0000000..88fa432 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/sync.js @@ -0,0 +1,30 @@ +var mkdirp = require('../'); +var path = require('path'); +var fs = require('fs'); +var exists = fs.exists || path.exists; +var test = require('tap').test; + +test('sync', function (t) { + t.plan(4); + var x = Math.floor(Math.random() * Math.pow(16,4)).toString(16); + var y = Math.floor(Math.random() * Math.pow(16,4)).toString(16); + var z = Math.floor(Math.random() * Math.pow(16,4)).toString(16); + + var file = '/tmp/' + [x,y,z].join('/'); + + try { + mkdirp.sync(file, 0755); + } catch (err) { + t.fail(err); + return t.end(); + } + + exists(file, function (ex) { + t.ok(ex, 'file created'); + fs.stat(file, function (err, stat) { + t.ifError(err); + t.equal(stat.mode & 0777, 0755); + t.ok(stat.isDirectory(), 'target not a directory'); + }); + }); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/umask.js b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/umask.js new file mode 100644 index 0000000..82c393a --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/umask.js @@ -0,0 +1,26 @@ +var mkdirp = require('../'); +var path = require('path'); +var fs = require('fs'); +var exists = fs.exists || path.exists; +var test = require('tap').test; + +test('implicit mode from umask', function (t) { + t.plan(5); + var x = Math.floor(Math.random() * Math.pow(16,4)).toString(16); + var y = Math.floor(Math.random() * Math.pow(16,4)).toString(16); + var z = Math.floor(Math.random() * Math.pow(16,4)).toString(16); + + var file = '/tmp/' + [x,y,z].join('/'); + + mkdirp(file, function (err) { + t.ifError(err); + exists(file, function (ex) { + t.ok(ex, 'file created'); + fs.stat(file, function (err, stat) { + t.ifError(err); + t.equal(stat.mode & 0777, 0777 & (~process.umask())); + t.ok(stat.isDirectory(), 'target not a directory'); + }); + }) + }); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/umask_sync.js b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/umask_sync.js new file mode 100644 index 0000000..e537fbe --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/test/umask_sync.js @@ -0,0 +1,30 @@ +var mkdirp = require('../'); +var path = require('path'); +var fs = require('fs'); +var exists = fs.exists || path.exists; +var test = require('tap').test; + +test('umask sync modes', function (t) { + t.plan(4); + var x = Math.floor(Math.random() * Math.pow(16,4)).toString(16); + var y = Math.floor(Math.random() * Math.pow(16,4)).toString(16); + var z = Math.floor(Math.random() * Math.pow(16,4)).toString(16); + + var file = '/tmp/' + [x,y,z].join('/'); + + try { + mkdirp.sync(file); + } catch (err) { + t.fail(err); + return t.end(); + } + + exists(file, function (ex) { + t.ok(ex, 'file created'); + fs.stat(file, function (err, stat) { + t.ifError(err); + t.equal(stat.mode & 0777, (0777 & (~process.umask()))); + t.ok(stat.isDirectory(), 'target not a directory'); + }); + }); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/nopt/.npmignore b/node_modules/nodeunit/node_modules/tap/node_modules/nopt/.npmignore new file mode 100644 index 0000000..3c3629e --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/nopt/.npmignore @@ -0,0 +1 @@ +node_modules diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/nopt/LICENSE b/node_modules/nodeunit/node_modules/tap/node_modules/nopt/LICENSE new file mode 100644 index 0000000..05a4010 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/nopt/LICENSE @@ -0,0 +1,23 @@ +Copyright 2009, 2010, 2011 Isaac Z. Schlueter. +All rights reserved. + +Permission is hereby granted, free of charge, to any person +obtaining a copy of this software and associated documentation +files (the "Software"), to deal in the Software without +restriction, including without limitation the rights to use, +copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the +Software is furnished to do so, subject to the following +conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES +OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT +HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR +OTHER DEALINGS IN THE SOFTWARE. diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/nopt/README.md b/node_modules/nodeunit/node_modules/tap/node_modules/nopt/README.md new file mode 100644 index 0000000..96798a1 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/nopt/README.md @@ -0,0 +1,210 @@ +If you want to write an option parser, and have it be good, there are +two ways to do it. The Right Way, and the Wrong Way. + +The Wrong Way is to sit down and write an option parser. We've all done +that. + +The Right Way is to write some complex configurable program with so many +options that you go half-insane just trying to manage them all, and put +it off with duct-tape solutions until you see exactly to the core of the +problem, and finally snap and write an awesome option parser. + +If you want to write an option parser, don't write an option parser. +Write a package manager, or a source control system, or a service +restarter, or an operating system. You probably won't end up with a +good one of those, but if you don't give up, and you are relentless and +diligent enough in your procrastination, you may just end up with a very +nice option parser. + +## USAGE + + // my-program.js + var nopt = require("nopt") + , Stream = require("stream").Stream + , path = require("path") + , knownOpts = { "foo" : [String, null] + , "bar" : [Stream, Number] + , "baz" : path + , "bloo" : [ "big", "medium", "small" ] + , "flag" : Boolean + , "pick" : Boolean + , "many" : [String, Array] + } + , shortHands = { "foofoo" : ["--foo", "Mr. Foo"] + , "b7" : ["--bar", "7"] + , "m" : ["--bloo", "medium"] + , "p" : ["--pick"] + , "f" : ["--flag"] + } + // everything is optional. + // knownOpts and shorthands default to {} + // arg list defaults to process.argv + // slice defaults to 2 + , parsed = nopt(knownOpts, shortHands, process.argv, 2) + console.log(parsed) + +This would give you support for any of the following: + +```bash +$ node my-program.js --foo "blerp" --no-flag +{ "foo" : "blerp", "flag" : false } + +$ node my-program.js ---bar 7 --foo "Mr. Hand" --flag +{ bar: 7, foo: "Mr. Hand", flag: true } + +$ node my-program.js --foo "blerp" -f -----p +{ foo: "blerp", flag: true, pick: true } + +$ node my-program.js -fp --foofoo +{ foo: "Mr. Foo", flag: true, pick: true } + +$ node my-program.js --foofoo -- -fp # -- stops the flag parsing. +{ foo: "Mr. Foo", argv: { remain: ["-fp"] } } + +$ node my-program.js --blatzk -fp # unknown opts are ok. +{ blatzk: true, flag: true, pick: true } + +$ node my-program.js --blatzk=1000 -fp # but you need to use = if they have a value +{ blatzk: 1000, flag: true, pick: true } + +$ node my-program.js --no-blatzk -fp # unless they start with "no-" +{ blatzk: false, flag: true, pick: true } + +$ node my-program.js --baz b/a/z # known paths are resolved. +{ baz: "/Users/isaacs/b/a/z" } + +# if Array is one of the types, then it can take many +# values, and will always be an array. The other types provided +# specify what types are allowed in the list. + +$ node my-program.js --many 1 --many null --many foo +{ many: ["1", "null", "foo"] } + +$ node my-program.js --many foo +{ many: ["foo"] } +``` + +Read the tests at the bottom of `lib/nopt.js` for more examples of +what this puppy can do. + +## Types + +The following types are supported, and defined on `nopt.typeDefs` + +* String: A normal string. No parsing is done. +* path: A file system path. Gets resolved against cwd if not absolute. +* url: A url. If it doesn't parse, it isn't accepted. +* Number: Must be numeric. +* Date: Must parse as a date. If it does, and `Date` is one of the options, + then it will return a Date object, not a string. +* Boolean: Must be either `true` or `false`. If an option is a boolean, + then it does not need a value, and its presence will imply `true` as + the value. To negate boolean flags, do `--no-whatever` or `--whatever + false` +* NaN: Means that the option is strictly not allowed. Any value will + fail. +* Stream: An object matching the "Stream" class in node. Valuable + for use when validating programmatically. (npm uses this to let you + supply any WriteStream on the `outfd` and `logfd` config options.) +* Array: If `Array` is specified as one of the types, then the value + will be parsed as a list of options. This means that multiple values + can be specified, and that the value will always be an array. + +If a type is an array of values not on this list, then those are +considered valid values. For instance, in the example above, the +`--bloo` option can only be one of `"big"`, `"medium"`, or `"small"`, +and any other value will be rejected. + +When parsing unknown fields, `"true"`, `"false"`, and `"null"` will be +interpreted as their JavaScript equivalents, and numeric values will be +interpreted as a number. + +You can also mix types and values, or multiple types, in a list. For +instance `{ blah: [Number, null] }` would allow a value to be set to +either a Number or null. When types are ordered, this implies a +preference, and the first type that can be used to properly interpret +the value will be used. + +To define a new type, add it to `nopt.typeDefs`. Each item in that +hash is an object with a `type` member and a `validate` method. The +`type` member is an object that matches what goes in the type list. The +`validate` method is a function that gets called with `validate(data, +key, val)`. Validate methods should assign `data[key]` to the valid +value of `val` if it can be handled properly, or return boolean +`false` if it cannot. + +You can also call `nopt.clean(data, types, typeDefs)` to clean up a +config object and remove its invalid properties. + +## Error Handling + +By default, nopt outputs a warning to standard error when invalid +options are found. You can change this behavior by assigning a method +to `nopt.invalidHandler`. This method will be called with +the offending `nopt.invalidHandler(key, val, types)`. + +If no `nopt.invalidHandler` is assigned, then it will console.error +its whining. If it is assigned to boolean `false` then the warning is +suppressed. + +## Abbreviations + +Yes, they are supported. If you define options like this: + +```javascript +{ "foolhardyelephants" : Boolean +, "pileofmonkeys" : Boolean } +``` + +Then this will work: + +```bash +node program.js --foolhar --pil +node program.js --no-f --pileofmon +# etc. +``` + +## Shorthands + +Shorthands are a hash of shorter option names to a snippet of args that +they expand to. + +If multiple one-character shorthands are all combined, and the +combination does not unambiguously match any other option or shorthand, +then they will be broken up into their constituent parts. For example: + +```json +{ "s" : ["--loglevel", "silent"] +, "g" : "--global" +, "f" : "--force" +, "p" : "--parseable" +, "l" : "--long" +} +``` + +```bash +npm ls -sgflp +# just like doing this: +npm ls --loglevel silent --global --force --long --parseable +``` + +## The Rest of the args + +The config object returned by nopt is given a special member called +`argv`, which is an object with the following fields: + +* `remain`: The remaining args after all the parsing has occurred. +* `original`: The args as they originally appeared. +* `cooked`: The args after flags and shorthands are expanded. + +## Slicing + +Node programs are called with more or less the exact argv as it appears +in C land, after the v8 and node-specific options have been plucked off. +As such, `argv[0]` is always `node` and `argv[1]` is always the +JavaScript program being run. + +That's usually not very useful to you. So they're sliced off by +default. If you want them, then you can pass in `0` as the last +argument, or any other number that you'd like to slice off the start of +the list. diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/nopt/bin/nopt.js b/node_modules/nodeunit/node_modules/tap/node_modules/nopt/bin/nopt.js new file mode 100755 index 0000000..30e9fdb --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/nopt/bin/nopt.js @@ -0,0 +1,51 @@ +#!/usr/bin/env node +var nopt = require("../lib/nopt") + , types = { num: Number + , bool: Boolean + , help: Boolean + , list: Array + , "num-list": [Number, Array] + , "str-list": [String, Array] + , "bool-list": [Boolean, Array] + , str: String + , clear: Boolean + , config: Boolean + , length: Number + } + , shorthands = { s: [ "--str", "astring" ] + , b: [ "--bool" ] + , nb: [ "--no-bool" ] + , tft: [ "--bool-list", "--no-bool-list", "--bool-list", "true" ] + , "?": ["--help"] + , h: ["--help"] + , H: ["--help"] + , n: [ "--num", "125" ] + , c: ["--config"] + , l: ["--length"] + } + , parsed = nopt( types + , shorthands + , process.argv + , 2 ) + +console.log("parsed", parsed) + +if (parsed.help) { + console.log("") + console.log("nopt cli tester") + console.log("") + console.log("types") + console.log(Object.keys(types).map(function M (t) { + var type = types[t] + if (Array.isArray(type)) { + return [t, type.map(function (type) { return type.name })] + } + return [t, type && type.name] + }).reduce(function (s, i) { + s[i[0]] = i[1] + return s + }, {})) + console.log("") + console.log("shorthands") + console.log(shorthands) +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/nopt/examples/my-program.js b/node_modules/nodeunit/node_modules/tap/node_modules/nopt/examples/my-program.js new file mode 100755 index 0000000..142447e --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/nopt/examples/my-program.js @@ -0,0 +1,30 @@ +#!/usr/bin/env node + +//process.env.DEBUG_NOPT = 1 + +// my-program.js +var nopt = require("../lib/nopt") + , Stream = require("stream").Stream + , path = require("path") + , knownOpts = { "foo" : [String, null] + , "bar" : [Stream, Number] + , "baz" : path + , "bloo" : [ "big", "medium", "small" ] + , "flag" : Boolean + , "pick" : Boolean + } + , shortHands = { "foofoo" : ["--foo", "Mr. Foo"] + , "b7" : ["--bar", "7"] + , "m" : ["--bloo", "medium"] + , "p" : ["--pick"] + , "f" : ["--flag", "true"] + , "g" : ["--flag"] + , "s" : "--flag" + } + // everything is optional. + // knownOpts and shorthands default to {} + // arg list defaults to process.argv + // slice defaults to 2 + , parsed = nopt(knownOpts, shortHands, process.argv, 2) + +console.log("parsed =\n"+ require("util").inspect(parsed)) diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/nopt/lib/nopt.js b/node_modules/nodeunit/node_modules/tap/node_modules/nopt/lib/nopt.js new file mode 100644 index 0000000..9efab7a --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/nopt/lib/nopt.js @@ -0,0 +1,412 @@ +// info about each config option. + +var debug = process.env.DEBUG_NOPT || process.env.NOPT_DEBUG + ? function () { console.error.apply(console, arguments) } + : function () {} + +var url = require("url") + , path = require("path") + , Stream = require("stream").Stream + , abbrev = require("abbrev") + +module.exports = exports = nopt +exports.clean = clean + +exports.typeDefs = + { String : { type: String, validate: validateString } + , Boolean : { type: Boolean, validate: validateBoolean } + , url : { type: url, validate: validateUrl } + , Number : { type: Number, validate: validateNumber } + , path : { type: path, validate: validatePath } + , Stream : { type: Stream, validate: validateStream } + , Date : { type: Date, validate: validateDate } + } + +function nopt (types, shorthands, args, slice) { + args = args || process.argv + types = types || {} + shorthands = shorthands || {} + if (typeof slice !== "number") slice = 2 + + debug(types, shorthands, args, slice) + + args = args.slice(slice) + var data = {} + , key + , remain = [] + , cooked = args + , original = args.slice(0) + + parse(args, data, remain, types, shorthands) + // now data is full + clean(data, types, exports.typeDefs) + data.argv = {remain:remain,cooked:cooked,original:original} + Object.defineProperty(data.argv, 'toString', { value: function () { + return this.original.map(JSON.stringify).join(" ") + }, enumerable: false }) + return data +} + +function clean (data, types, typeDefs) { + typeDefs = typeDefs || exports.typeDefs + var remove = {} + , typeDefault = [false, true, null, String, Number, Array] + + Object.keys(data).forEach(function (k) { + if (k === "argv") return + var val = data[k] + , isArray = Array.isArray(val) + , type = types[k] + if (!isArray) val = [val] + if (!type) type = typeDefault + if (type === Array) type = typeDefault.concat(Array) + if (!Array.isArray(type)) type = [type] + + debug("val=%j", val) + debug("types=", type) + val = val.map(function (val) { + // if it's an unknown value, then parse false/true/null/numbers/dates + if (typeof val === "string") { + debug("string %j", val) + val = val.trim() + if ((val === "null" && ~type.indexOf(null)) + || (val === "true" && + (~type.indexOf(true) || ~type.indexOf(Boolean))) + || (val === "false" && + (~type.indexOf(false) || ~type.indexOf(Boolean)))) { + val = JSON.parse(val) + debug("jsonable %j", val) + } else if (~type.indexOf(Number) && !isNaN(val)) { + debug("convert to number", val) + val = +val + } else if (~type.indexOf(Date) && !isNaN(Date.parse(val))) { + debug("convert to date", val) + val = new Date(val) + } + } + + if (!types.hasOwnProperty(k)) { + return val + } + + // allow `--no-blah` to set 'blah' to null if null is allowed + if (val === false && ~type.indexOf(null) && + !(~type.indexOf(false) || ~type.indexOf(Boolean))) { + val = null + } + + var d = {} + d[k] = val + debug("prevalidated val", d, val, types[k]) + if (!validate(d, k, val, types[k], typeDefs)) { + if (exports.invalidHandler) { + exports.invalidHandler(k, val, types[k], data) + } else if (exports.invalidHandler !== false) { + debug("invalid: "+k+"="+val, types[k]) + } + return remove + } + debug("validated val", d, val, types[k]) + return d[k] + }).filter(function (val) { return val !== remove }) + + if (!val.length) delete data[k] + else if (isArray) { + debug(isArray, data[k], val) + data[k] = val + } else data[k] = val[0] + + debug("k=%s val=%j", k, val, data[k]) + }) +} + +function validateString (data, k, val) { + data[k] = String(val) +} + +function validatePath (data, k, val) { + if (val === true) return false + val = String(val) + var homePattern = process.platform === 'win32' ? /^~(\/|\\)/ : /^~\// + if (val.match(homePattern) && process.env.HOME) { + val = path.resolve(process.env.HOME, val.substr(2)) + } + data[k] = path.resolve(String(val)) + return true +} + +function validateNumber (data, k, val) { + debug("validate Number %j %j %j", k, val, isNaN(val)) + if (isNaN(val)) return false + data[k] = +val +} + +function validateDate (data, k, val) { + debug("validate Date %j %j %j", k, val, Date.parse(val)) + var s = Date.parse(val) + if (isNaN(s)) return false + data[k] = new Date(val) +} + +function validateBoolean (data, k, val) { + if (val instanceof Boolean) val = val.valueOf() + else if (typeof val === "string") { + if (!isNaN(val)) val = !!(+val) + else if (val === "null" || val === "false") val = false + else val = true + } else val = !!val + data[k] = val +} + +function validateUrl (data, k, val) { + val = url.parse(String(val)) + if (!val.host) return false + data[k] = val.href +} + +function validateStream (data, k, val) { + if (!(val instanceof Stream)) return false + data[k] = val +} + +function validate (data, k, val, type, typeDefs) { + // arrays are lists of types. + if (Array.isArray(type)) { + for (var i = 0, l = type.length; i < l; i ++) { + if (type[i] === Array) continue + if (validate(data, k, val, type[i], typeDefs)) return true + } + delete data[k] + return false + } + + // an array of anything? + if (type === Array) return true + + // NaN is poisonous. Means that something is not allowed. + if (type !== type) { + debug("Poison NaN", k, val, type) + delete data[k] + return false + } + + // explicit list of values + if (val === type) { + debug("Explicitly allowed %j", val) + // if (isArray) (data[k] = data[k] || []).push(val) + // else data[k] = val + data[k] = val + return true + } + + // now go through the list of typeDefs, validate against each one. + var ok = false + , types = Object.keys(typeDefs) + for (var i = 0, l = types.length; i < l; i ++) { + debug("test type %j %j %j", k, val, types[i]) + var t = typeDefs[types[i]] + if (t && type === t.type) { + var d = {} + ok = false !== t.validate(d, k, val) + val = d[k] + if (ok) { + // if (isArray) (data[k] = data[k] || []).push(val) + // else data[k] = val + data[k] = val + break + } + } + } + debug("OK? %j (%j %j %j)", ok, k, val, types[i]) + + if (!ok) delete data[k] + return ok +} + +function parse (args, data, remain, types, shorthands) { + debug("parse", args, data, remain) + + var key = null + , abbrevs = abbrev(Object.keys(types)) + , shortAbbr = abbrev(Object.keys(shorthands)) + + for (var i = 0; i < args.length; i ++) { + var arg = args[i] + debug("arg", arg) + + if (arg.match(/^-{2,}$/)) { + // done with keys. + // the rest are args. + remain.push.apply(remain, args.slice(i + 1)) + args[i] = "--" + break + } + var hadEq = false + if (arg.charAt(0) === "-" && arg.length > 1) { + if (arg.indexOf("=") !== -1) { + hadEq = true + var v = arg.split("=") + arg = v.shift() + v = v.join("=") + args.splice.apply(args, [i, 1].concat([arg, v])) + } + + // see if it's a shorthand + // if so, splice and back up to re-parse it. + var shRes = resolveShort(arg, shorthands, shortAbbr, abbrevs) + debug("arg=%j shRes=%j", arg, shRes) + if (shRes) { + debug(arg, shRes) + args.splice.apply(args, [i, 1].concat(shRes)) + if (arg !== shRes[0]) { + i -- + continue + } + } + arg = arg.replace(/^-+/, "") + var no = null + while (arg.toLowerCase().indexOf("no-") === 0) { + no = !no + arg = arg.substr(3) + } + + if (abbrevs[arg]) arg = abbrevs[arg] + + var isArray = types[arg] === Array || + Array.isArray(types[arg]) && types[arg].indexOf(Array) !== -1 + + // allow unknown things to be arrays if specified multiple times. + if (!types.hasOwnProperty(arg) && data.hasOwnProperty(arg)) { + if (!Array.isArray(data[arg])) + data[arg] = [data[arg]] + isArray = true + } + + var val + , la = args[i + 1] + + var isBool = typeof no === 'boolean' || + types[arg] === Boolean || + Array.isArray(types[arg]) && types[arg].indexOf(Boolean) !== -1 || + (typeof types[arg] === 'undefined' && !hadEq) || + (la === "false" && + (types[arg] === null || + Array.isArray(types[arg]) && ~types[arg].indexOf(null))) + + if (isBool) { + // just set and move along + val = !no + // however, also support --bool true or --bool false + if (la === "true" || la === "false") { + val = JSON.parse(la) + la = null + if (no) val = !val + i ++ + } + + // also support "foo":[Boolean, "bar"] and "--foo bar" + if (Array.isArray(types[arg]) && la) { + if (~types[arg].indexOf(la)) { + // an explicit type + val = la + i ++ + } else if ( la === "null" && ~types[arg].indexOf(null) ) { + // null allowed + val = null + i ++ + } else if ( !la.match(/^-{2,}[^-]/) && + !isNaN(la) && + ~types[arg].indexOf(Number) ) { + // number + val = +la + i ++ + } else if ( !la.match(/^-[^-]/) && ~types[arg].indexOf(String) ) { + // string + val = la + i ++ + } + } + + if (isArray) (data[arg] = data[arg] || []).push(val) + else data[arg] = val + + continue + } + + if (types[arg] === String && la === undefined) + la = "" + + if (la && la.match(/^-{2,}$/)) { + la = undefined + i -- + } + + val = la === undefined ? true : la + if (isArray) (data[arg] = data[arg] || []).push(val) + else data[arg] = val + + i ++ + continue + } + remain.push(arg) + } +} + +function resolveShort (arg, shorthands, shortAbbr, abbrevs) { + // handle single-char shorthands glommed together, like + // npm ls -glp, but only if there is one dash, and only if + // all of the chars are single-char shorthands, and it's + // not a match to some other abbrev. + arg = arg.replace(/^-+/, '') + + // if it's an exact known option, then don't go any further + if (abbrevs[arg] === arg) + return null + + // if it's an exact known shortopt, same deal + if (shorthands[arg]) { + // make it an array, if it's a list of words + if (shorthands[arg] && !Array.isArray(shorthands[arg])) + shorthands[arg] = shorthands[arg].split(/\s+/) + + return shorthands[arg] + } + + // first check to see if this arg is a set of single-char shorthands + var singles = shorthands.___singles + if (!singles) { + singles = Object.keys(shorthands).filter(function (s) { + return s.length === 1 + }).reduce(function (l,r) { + l[r] = true + return l + }, {}) + shorthands.___singles = singles + debug('shorthand singles', singles) + } + + var chrs = arg.split("").filter(function (c) { + return singles[c] + }) + + if (chrs.join("") === arg) return chrs.map(function (c) { + return shorthands[c] + }).reduce(function (l, r) { + return l.concat(r) + }, []) + + + // if it's an arg abbrev, and not a literal shorthand, then prefer the arg + if (abbrevs[arg] && !shorthands[arg]) + return null + + // if it's an abbr for a shorthand, then use that + if (shortAbbr[arg]) + arg = shortAbbr[arg] + + // make it an array, if it's a list of words + if (shorthands[arg] && !Array.isArray(shorthands[arg])) + shorthands[arg] = shorthands[arg].split(/\s+/) + + return shorthands[arg] +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/nopt/node_modules/abbrev/CONTRIBUTING.md b/node_modules/nodeunit/node_modules/tap/node_modules/nopt/node_modules/abbrev/CONTRIBUTING.md new file mode 100644 index 0000000..2f30261 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/nopt/node_modules/abbrev/CONTRIBUTING.md @@ -0,0 +1,3 @@ + To get started, sign the + Contributor License Agreement. diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/nopt/node_modules/abbrev/LICENSE b/node_modules/nodeunit/node_modules/tap/node_modules/nopt/node_modules/abbrev/LICENSE new file mode 100644 index 0000000..05a4010 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/nopt/node_modules/abbrev/LICENSE @@ -0,0 +1,23 @@ +Copyright 2009, 2010, 2011 Isaac Z. Schlueter. +All rights reserved. + +Permission is hereby granted, free of charge, to any person +obtaining a copy of this software and associated documentation +files (the "Software"), to deal in the Software without +restriction, including without limitation the rights to use, +copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the +Software is furnished to do so, subject to the following +conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES +OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT +HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR +OTHER DEALINGS IN THE SOFTWARE. diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/nopt/node_modules/abbrev/README.md b/node_modules/nodeunit/node_modules/tap/node_modules/nopt/node_modules/abbrev/README.md new file mode 100644 index 0000000..99746fe --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/nopt/node_modules/abbrev/README.md @@ -0,0 +1,23 @@ +# abbrev-js + +Just like [ruby's Abbrev](http://apidock.com/ruby/Abbrev). + +Usage: + + var abbrev = require("abbrev"); + abbrev("foo", "fool", "folding", "flop"); + + // returns: + { fl: 'flop' + , flo: 'flop' + , flop: 'flop' + , fol: 'folding' + , fold: 'folding' + , foldi: 'folding' + , foldin: 'folding' + , folding: 'folding' + , foo: 'foo' + , fool: 'fool' + } + +This is handy for command-line scripts, or other cases where you want to be able to accept shorthands. diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/nopt/node_modules/abbrev/abbrev.js b/node_modules/nodeunit/node_modules/tap/node_modules/nopt/node_modules/abbrev/abbrev.js new file mode 100644 index 0000000..69cfeac --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/nopt/node_modules/abbrev/abbrev.js @@ -0,0 +1,62 @@ + +module.exports = exports = abbrev.abbrev = abbrev + +abbrev.monkeyPatch = monkeyPatch + +function monkeyPatch () { + Object.defineProperty(Array.prototype, 'abbrev', { + value: function () { return abbrev(this) }, + enumerable: false, configurable: true, writable: true + }) + + Object.defineProperty(Object.prototype, 'abbrev', { + value: function () { return abbrev(Object.keys(this)) }, + enumerable: false, configurable: true, writable: true + }) +} + +function abbrev (list) { + if (arguments.length !== 1 || !Array.isArray(list)) { + list = Array.prototype.slice.call(arguments, 0) + } + for (var i = 0, l = list.length, args = [] ; i < l ; i ++) { + args[i] = typeof list[i] === "string" ? list[i] : String(list[i]) + } + + // sort them lexicographically, so that they're next to their nearest kin + args = args.sort(lexSort) + + // walk through each, seeing how much it has in common with the next and previous + var abbrevs = {} + , prev = "" + for (var i = 0, l = args.length ; i < l ; i ++) { + var current = args[i] + , next = args[i + 1] || "" + , nextMatches = true + , prevMatches = true + if (current === next) continue + for (var j = 0, cl = current.length ; j < cl ; j ++) { + var curChar = current.charAt(j) + nextMatches = nextMatches && curChar === next.charAt(j) + prevMatches = prevMatches && curChar === prev.charAt(j) + if (!nextMatches && !prevMatches) { + j ++ + break + } + } + prev = current + if (j === cl) { + abbrevs[current] = current + continue + } + for (var a = current.substr(0, j) ; j <= cl ; j ++) { + abbrevs[a] = current + a += current.charAt(j) + } + } + return abbrevs +} + +function lexSort (a, b) { + return a === b ? 0 : a > b ? 1 : -1 +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/nopt/node_modules/abbrev/package.json b/node_modules/nodeunit/node_modules/tap/node_modules/nopt/node_modules/abbrev/package.json new file mode 100644 index 0000000..1dad5f2 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/nopt/node_modules/abbrev/package.json @@ -0,0 +1,46 @@ +{ + "name": "abbrev", + "version": "1.0.5", + "description": "Like ruby's abbrev module, but in js", + "author": { + "name": "Isaac Z. Schlueter", + "email": "i@izs.me" + }, + "main": "abbrev.js", + "scripts": { + "test": "node test.js" + }, + "repository": { + "type": "git", + "url": "http://github.com/isaacs/abbrev-js" + }, + "license": { + "type": "MIT", + "url": "https://github.com/isaacs/abbrev-js/raw/master/LICENSE" + }, + "bugs": { + "url": "https://github.com/isaacs/abbrev-js/issues" + }, + "homepage": "https://github.com/isaacs/abbrev-js", + "_id": "abbrev@1.0.5", + "_shasum": "5d8257bd9ebe435e698b2fa431afde4fe7b10b03", + "_from": "abbrev@1", + "_npmVersion": "1.4.7", + "_npmUser": { + "name": "isaacs", + "email": "i@izs.me" + }, + "maintainers": [ + { + "name": "isaacs", + "email": "i@izs.me" + } + ], + "dist": { + "shasum": "5d8257bd9ebe435e698b2fa431afde4fe7b10b03", + "tarball": "http://registry.npmjs.org/abbrev/-/abbrev-1.0.5.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.0.5.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/nopt/node_modules/abbrev/test.js b/node_modules/nodeunit/node_modules/tap/node_modules/nopt/node_modules/abbrev/test.js new file mode 100644 index 0000000..d5a7303 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/nopt/node_modules/abbrev/test.js @@ -0,0 +1,47 @@ +var abbrev = require('./abbrev.js') +var assert = require("assert") +var util = require("util") + +console.log("TAP Version 13") +var count = 0 + +function test (list, expect) { + count++ + var actual = abbrev(list) + assert.deepEqual(actual, expect, + "abbrev("+util.inspect(list)+") === " + util.inspect(expect) + "\n"+ + "actual: "+util.inspect(actual)) + actual = abbrev.apply(exports, list) + assert.deepEqual(abbrev.apply(exports, list), expect, + "abbrev("+list.map(JSON.stringify).join(",")+") === " + util.inspect(expect) + "\n"+ + "actual: "+util.inspect(actual)) + console.log('ok - ' + list.join(' ')) +} + +test([ "ruby", "ruby", "rules", "rules", "rules" ], +{ rub: 'ruby' +, ruby: 'ruby' +, rul: 'rules' +, rule: 'rules' +, rules: 'rules' +}) +test(["fool", "foom", "pool", "pope"], +{ fool: 'fool' +, foom: 'foom' +, poo: 'pool' +, pool: 'pool' +, pop: 'pope' +, pope: 'pope' +}) +test(["a", "ab", "abc", "abcd", "abcde", "acde"], +{ a: 'a' +, ab: 'ab' +, abc: 'abc' +, abcd: 'abcd' +, abcde: 'abcde' +, ac: 'acde' +, acd: 'acde' +, acde: 'acde' +}) + +console.log("0..%d", count) diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/nopt/package.json b/node_modules/nodeunit/node_modules/tap/node_modules/nopt/package.json new file mode 100644 index 0000000..fafef9d --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/nopt/package.json @@ -0,0 +1,56 @@ +{ + "name": "nopt", + "version": "2.2.1", + "description": "Option parsing for Node, supporting types, shorthands, etc. Used by npm.", + "author": { + "name": "Isaac Z. Schlueter", + "email": "i@izs.me", + "url": "http://blog.izs.me/" + }, + "main": "lib/nopt.js", + "scripts": { + "test": "tap test/*.js" + }, + "repository": { + "type": "git", + "url": "http://github.com/isaacs/nopt" + }, + "bin": { + "nopt": "./bin/nopt.js" + }, + "license": { + "type": "MIT", + "url": "https://github.com/isaacs/nopt/raw/master/LICENSE" + }, + "dependencies": { + "abbrev": "1" + }, + "devDependencies": { + "tap": "~0.4.8" + }, + "bugs": { + "url": "https://github.com/isaacs/nopt/issues" + }, + "homepage": "https://github.com/isaacs/nopt", + "_id": "nopt@2.2.1", + "_shasum": "2aa09b7d1768487b3b89a9c5aa52335bff0baea7", + "_from": "nopt@2.2.1", + "_npmVersion": "1.4.7", + "_npmUser": { + "name": "isaacs", + "email": "i@izs.me" + }, + "maintainers": [ + { + "name": "isaacs", + "email": "i@izs.me" + } + ], + "dist": { + "shasum": "2aa09b7d1768487b3b89a9c5aa52335bff0baea7", + "tarball": "http://registry.npmjs.org/nopt/-/nopt-2.2.1.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/nopt/-/nopt-2.2.1.tgz", + "readme": "ERROR: No README data found!" +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/nopt/test/basic.js b/node_modules/nodeunit/node_modules/tap/node_modules/nopt/test/basic.js new file mode 100644 index 0000000..b31dccf --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/nopt/test/basic.js @@ -0,0 +1,243 @@ +var nopt = require("../") + , test = require('tap').test + + +test("passing a string results in a string", function (t) { + var parsed = nopt({ key: String }, {}, ["--key", "myvalue"], 0) + t.same(parsed.key, "myvalue") + t.end() +}) + +// https://github.com/npm/nopt/issues/31 +test("Empty String results in empty string, not true", function (t) { + var parsed = nopt({ empty: String }, {}, ["--empty"], 0) + t.same(parsed.empty, "") + t.end() +}) + +test("~ path is resolved to $HOME", function (t) { + var path = require("path") + if (!process.env.HOME) process.env.HOME = "/tmp" + var parsed = nopt({key: path}, {}, ["--key=~/val"], 0) + t.same(parsed.key, path.resolve(process.env.HOME, "val")) + t.end() +}) + +test("other tests", function (t) { + + var util = require("util") + , Stream = require("stream") + , path = require("path") + , url = require("url") + + , shorthands = + { s : ["--loglevel", "silent"] + , d : ["--loglevel", "info"] + , dd : ["--loglevel", "verbose"] + , ddd : ["--loglevel", "silly"] + , noreg : ["--no-registry"] + , reg : ["--registry"] + , "no-reg" : ["--no-registry"] + , silent : ["--loglevel", "silent"] + , verbose : ["--loglevel", "verbose"] + , h : ["--usage"] + , H : ["--usage"] + , "?" : ["--usage"] + , help : ["--usage"] + , v : ["--version"] + , f : ["--force"] + , desc : ["--description"] + , "no-desc" : ["--no-description"] + , "local" : ["--no-global"] + , l : ["--long"] + , p : ["--parseable"] + , porcelain : ["--parseable"] + , g : ["--global"] + } + + , types = + { aoa: Array + , nullstream: [null, Stream] + , date: Date + , str: String + , browser : String + , cache : path + , color : ["always", Boolean] + , depth : Number + , description : Boolean + , dev : Boolean + , editor : path + , force : Boolean + , global : Boolean + , globalconfig : path + , group : [String, Number] + , gzipbin : String + , logfd : [Number, Stream] + , loglevel : ["silent","win","error","warn","info","verbose","silly"] + , long : Boolean + , "node-version" : [false, String] + , npaturl : url + , npat : Boolean + , "onload-script" : [false, String] + , outfd : [Number, Stream] + , parseable : Boolean + , pre: Boolean + , prefix: path + , proxy : url + , "rebuild-bundle" : Boolean + , registry : url + , searchopts : String + , searchexclude: [null, String] + , shell : path + , t: [Array, String] + , tag : String + , tar : String + , tmp : path + , "unsafe-perm" : Boolean + , usage : Boolean + , user : String + , username : String + , userconfig : path + , version : Boolean + , viewer: path + , _exit : Boolean + , path: path + } + + ; [["-v", {version:true}, []] + ,["---v", {version:true}, []] + ,["ls -s --no-reg connect -d", + {loglevel:"info",registry:null},["ls","connect"]] + ,["ls ---s foo",{loglevel:"silent"},["ls","foo"]] + ,["ls --registry blargle", {}, ["ls"]] + ,["--no-registry", {registry:null}, []] + ,["--no-color true", {color:false}, []] + ,["--no-color false", {color:true}, []] + ,["--no-color", {color:false}, []] + ,["--color false", {color:false}, []] + ,["--color --logfd 7", {logfd:7,color:true}, []] + ,["--color=true", {color:true}, []] + ,["--logfd=10", {logfd:10}, []] + ,["--tmp=/tmp -tar=gtar",{tmp:"/tmp",tar:"gtar"},[]] + ,["--tmp=tmp -tar=gtar", + {tmp:path.resolve(process.cwd(), "tmp"),tar:"gtar"},[]] + ,["--logfd x", {}, []] + ,["a -true -- -no-false", {true:true},["a","-no-false"]] + ,["a -no-false", {false:false},["a"]] + ,["a -no-no-true", {true:true}, ["a"]] + ,["a -no-no-no-false", {false:false}, ["a"]] + ,["---NO-no-No-no-no-no-nO-no-no"+ + "-No-no-no-no-no-no-no-no-no"+ + "-no-no-no-no-NO-NO-no-no-no-no-no-no"+ + "-no-body-can-do-the-boogaloo-like-I-do" + ,{"body-can-do-the-boogaloo-like-I-do":false}, []] + ,["we are -no-strangers-to-love "+ + "--you-know=the-rules --and=so-do-i "+ + "---im-thinking-of=a-full-commitment "+ + "--no-you-would-get-this-from-any-other-guy "+ + "--no-gonna-give-you-up "+ + "-no-gonna-let-you-down=true "+ + "--no-no-gonna-run-around false "+ + "--desert-you=false "+ + "--make-you-cry false "+ + "--no-tell-a-lie "+ + "--no-no-and-hurt-you false" + ,{"strangers-to-love":false + ,"you-know":"the-rules" + ,"and":"so-do-i" + ,"you-would-get-this-from-any-other-guy":false + ,"gonna-give-you-up":false + ,"gonna-let-you-down":false + ,"gonna-run-around":false + ,"desert-you":false + ,"make-you-cry":false + ,"tell-a-lie":false + ,"and-hurt-you":false + },["we", "are"]] + ,["-t one -t two -t three" + ,{t: ["one", "two", "three"]} + ,[]] + ,["-t one -t null -t three four five null" + ,{t: ["one", "null", "three"]} + ,["four", "five", "null"]] + ,["-t foo" + ,{t:["foo"]} + ,[]] + ,["--no-t" + ,{t:["false"]} + ,[]] + ,["-no-no-t" + ,{t:["true"]} + ,[]] + ,["-aoa one -aoa null -aoa 100" + ,{aoa:["one", null, 100]} + ,[]] + ,["-str 100" + ,{str:"100"} + ,[]] + ,["--color always" + ,{color:"always"} + ,[]] + ,["--no-nullstream" + ,{nullstream:null} + ,[]] + ,["--nullstream false" + ,{nullstream:null} + ,[]] + ,["--notadate=2011-01-25" + ,{notadate: "2011-01-25"} + ,[]] + ,["--date 2011-01-25" + ,{date: new Date("2011-01-25")} + ,[]] + ,["-cl 1" + ,{config: true, length: 1} + ,[] + ,{config: Boolean, length: Number, clear: Boolean} + ,{c: "--config", l: "--length"}] + ,["--acount bla" + ,{"acount":true} + ,["bla"] + ,{account: Boolean, credentials: Boolean, options: String} + ,{a:"--account", c:"--credentials",o:"--options"}] + ,["--clear" + ,{clear:true} + ,[] + ,{clear:Boolean,con:Boolean,len:Boolean,exp:Boolean,add:Boolean,rep:Boolean} + ,{c:"--con",l:"--len",e:"--exp",a:"--add",r:"--rep"}] + ,["--file -" + ,{"file":"-"} + ,[] + ,{file:String} + ,{}] + ,["--file -" + ,{"file":true} + ,["-"] + ,{file:Boolean} + ,{}] + ,["--path" + ,{"path":null} + ,[]] + ,["--path ." + ,{"path":process.cwd()} + ,[]] + ].forEach(function (test) { + var argv = test[0].split(/\s+/) + , opts = test[1] + , rem = test[2] + , actual = nopt(test[3] || types, test[4] || shorthands, argv, 0) + , parsed = actual.argv + delete actual.argv + for (var i in opts) { + var e = JSON.stringify(opts[i]) + , a = JSON.stringify(actual[i] === undefined ? null : actual[i]) + if (e && typeof e === "object") { + t.deepEqual(e, a) + } else { + t.equal(e, a) + } + } + t.deepEqual(rem, parsed.remain) + }) + t.end() +}) diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/README.markdown b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/README.markdown new file mode 100644 index 0000000..1e56ebd --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/README.markdown @@ -0,0 +1,56 @@ +runforcover +====== + +Runforcover is a require-hook library that uses node-bunker to provide code coverage data +for your unit test library, whatever it might be. + +methods +======= +var runforcover = require('runforcover'); + +var coverage = runforcover.cover([RegExp | path]); +------- + +Attach runforcover to the global `require` object and patch `require.extensions['.js']` to +provide coverage metadata for all files required after this point. Returns a function +object that can be called to obtain a object keying files to `CoverageData` objects, with +a method for releasing control back to vanilla `require`. Usage: + +````javascript + +var coverage = runforcover.cover(/.*/g); + +require('some/library'); + +coverage(function(coverageData) { + // coverageData is an object keyed by filename. + var stats = coverageData['/full/path/to/file.js'].stats() + + // the percentage of lines run versus total lines in file + console.log(stats.percentage); + + // the number of missing lines + console.log(stats.missing); + + // the number of lines run (seen) + console.log(stats.seen); + + // an array of line objects representing 'missed' lines + stats.lines; + + stats.lines.forEach(function(line) { + // the line number of the line: + console.log(line.number); + + // returns a string containing the source data for the line: + console.log(line.source()); + }); + + // return control back to the original require function + coverage.release(); +}); +```` + +license +======= +new BSD. diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/index.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/index.js new file mode 100644 index 0000000..b5318ac --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/index.js @@ -0,0 +1,127 @@ +var bunker = require('bunker'), + Module = require('module').Module, + path = require('path'), + fs = require('fs'), + vm = require('vm'); + +function CoverageData (filename, bunker) { + this.bunker = bunker; + this.filename = filename; + this.nodes = {}; +}; + +CoverageData.prototype.visit = function(node) { + ++(this.nodes[node.id] = this.nodes[node.id] || {node:node, count:0}).count; +}; + +CoverageData.prototype.missing = function() { + var nodes = this.nodes, + missing = this.bunker.nodes.filter(function(node) { + return !nodes[node.id]; + }); + + return missing; +}; + +CoverageData.prototype.stats = function() { + var missing = this.missing(), + filedata = fs.readFileSync(this.filename, 'utf8').split('\n'); + + var seenLines = [], + lines = + missing.sort(function(lhs, rhs) { + return lhs.node[0].start.line < rhs.node[0].start.line ? -1 : + lhs.node[0].start.line > rhs.node[0].start.line ? 1 : + 0; + }).filter(function(node) { + + var okay = (seenLines.indexOf(node.node[0].start.line) < 0); + if(okay) + seenLines.push(node.node[0].start.line); + return okay; + + }).map(function(node, idx, all) { + return { + lineno:node.node[0].start.line + 1, + source:function() { return filedata[node.node[0].start.line]; } + }; + }); + + return { + percentage:(filedata.length-seenLines.length)/filedata.length, + lines:lines, + missing:seenLines.length, + seen:(filedata.length-seenLines.length) + }; +}; + +module.exports.createEnvironment = function(module, filename) { + var req = function(path) { + return Module._load(path, module); + }; + req.resolve = function(request) { + return Module._resolveFilename(request, module)[1]; + } + req.paths = Module._paths; + req.main = process.mainModule; + req.extensions = Module._extensions; + req.registerExtension = function() { + throw new Error('require.registerExtension() removed. Use ' + + 'require.extensions instead.'); + } + require.cache = Module._cache; + + var ctxt = {}; + for(var k in global) + ctxt[k] = global[k]; + + ctxt.require = req; + ctxt.exports = module.exports; + ctxt.__filename = filename; + ctxt.__dirname = path.dirname(filename); + ctxt.process = process; + ctxt.console = console; + ctxt.module = module; + ctxt.global = ctxt; + + return ctxt; +}; + +module.exports.cover = function(fileRegex) { + var originalRequire = require.extensions['.js'], + coverageData = {}, + match = fileRegex instanceof RegExp ? + fileRegex : new RegExp( + fileRegex ? fileRegex.replace(/\//g, '\\/').replace(/\./g, '\\.') : '.*' + , 'g'), + target = this; + + require.extensions['.js'] = function(module, filename) { + if(!match.test(filename)) return originalRequire(module, filename); + + var context = target.createEnvironment(module, filename), + data = fs.readFileSync(filename, 'utf8'), + bunkerized = bunker(data), + coverage = coverageData[filename] = new CoverageData(filename, bunkerized); + + bunkerized.on('node', coverage.visit.bind(coverage)); + bunkerized.assign(context); + + var wrapper = '(function(ctxt) { with(ctxt) { return '+Module.wrap(bunkerized.compile())+'; } })', + compiledWrapper = vm.runInThisContext(wrapper, filename, true)(context); + + var args = [context.exports, context.require, module, filename, context.__dirname]; + return compiledWrapper.apply(module.exports, args); + }; + + var retval = function(ready) { + ready(coverageData); + }; + + retval.release = function() { + require.extensions['.js'] = originalRequire; + }; + + return retval; +}; + diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/.npmignore b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/.npmignore new file mode 100644 index 0000000..3c3629e --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/.npmignore @@ -0,0 +1 @@ +node_modules diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/.travis.yml b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/.travis.yml new file mode 100644 index 0000000..f1d0f13 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/.travis.yml @@ -0,0 +1,4 @@ +language: node_js +node_js: + - 0.4 + - 0.6 diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/README.markdown b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/README.markdown new file mode 100644 index 0000000..0d0c387 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/README.markdown @@ -0,0 +1,82 @@ +bunker +====== + +Bunker is a module to calculate code coverage using native javascript +[burrito](https://github.com/substack/node-burrito) AST trickery. + +[![build status](https://secure.travis-ci.org/substack/node-bunker.png)](http://travis-ci.org/substack/node-bunker) + +![code coverage](http://substack.net/images/code_coverage.png) + +examples +======== + +tiny +---- + +````javascript +var bunker = require('bunker'); +var b = bunker('var x = 0; for (var i = 0; i < 30; i++) { x++ }'); + +var counts = {}; + +b.on('node', function (node) { + if (!counts[node.id]) { + counts[node.id] = { times : 0, node : node }; + } + counts[node.id].times ++; +}); + +b.run(); + +Object.keys(counts).forEach(function (key) { + var count = counts[key]; + console.log(count.times + ' : ' + count.node.source()); +}); +```` + +output: + + $ node example/tiny.js + 1 : var x=0; + 31 : i<30 + 30 : i++ + 30 : x++; + 30 : x++ + +methods +======= + +var bunker = require('bunker'); + +var b = bunker(src) +------------------- + +Create a new bunker code coverageifier with some source `src`. + +The bunker object `b` is an `EventEmitter` that emits `'node'` events with two +parameters: + +* `node` - the [burrito](https://github.com/substack/node-burrito) node object +* `stack` - the stack, [stackedy](https://github.com/substack/node-stackedy) style + +b.include(src) +-------------- + +Include some source into the bunker. + +b.compile() +----------- + +Return the source wrapped with burrito. + +b.assign(context={}) +-------------------- + +Assign the statement-tracking functions into `context`. + +b.run(context={}) +----------------- + +Run the source using `vm.runInNewContext()` with some `context`. +The statement-tracking functions will be added to `context` by `assign()`. diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/example/prof.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/example/prof.js new file mode 100644 index 0000000..5cac4cc --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/example/prof.js @@ -0,0 +1,51 @@ +var bunker = require('bunker'); +var b = bunker('(' + function () { + function beep () { + var x = 0; + for (var i = 0; i < 1000; i++) { + for (var j = 0; j < 100; j++) { + x += j; + } + } + return x; + } + + beep(); + +} + ')()'); + +var counts = {}; + +b.on('node', function (node) { + if (!counts[node.id]) { + counts[node.id] = { times : 0, node : node, elapsed : 0 }; + } + counts[node.id].times ++; + + var now = Date.now(); + + if (last.id !== undefined) { + counts[last.id].elapsed += last. + } + + if (node.name === 'call') { + var start = now; + + last.id = node.id; + counts[node.id].elapsed += Date.now() - start; + } + else { + counts[node.id].elapsed += now - last; + last = now; + } +}); + +b.run(); + +Object.keys(counts).forEach(function (key) { + var count = counts[key]; + console.log( + [ count.times, count.node.source(), count.elapsed ] + .join(' : ') + ); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/example/tiny.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/example/tiny.js new file mode 100644 index 0000000..aa5b034 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/example/tiny.js @@ -0,0 +1,18 @@ +var bunker = require('bunker'); +var b = bunker('var x = 0; for (var i = 0; i < 30; i++) { x++ }'); + +var counts = {}; + +b.on('node', function (node) { + if (!counts[node.id]) { + counts[node.id] = { times : 0, node : node }; + } + counts[node.id].times ++; +}); + +b.run(); + +Object.keys(counts).forEach(function (key) { + var count = counts[key]; + console.log(count.times + ' : ' + count.node.source()); +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/example/top/run.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/example/top/run.js new file mode 100644 index 0000000..d9eaa10 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/example/top/run.js @@ -0,0 +1,31 @@ +var bunker = require('bunker'); +var fs = require('fs'); +var src = fs.readFileSync(__dirname + '/src.js', 'utf8'); + +var counts = {}; + +var b = bunker(src); +b.on('node', function (node) { + if (!counts[node.id]) { + counts[node.id] = { times : 0, node : node }; + } + counts[node.id].times ++; +}); + +b.run({ + setInterval : setInterval, + clearInterval : clearInterval, + end : function () { + Object.keys(counts) + .sort(function (a, b) { + return counts[b].times - counts[a].times + }) + .forEach(function (key) { + var count = counts[key]; + console.log( + count.times + ' : ' + count.node.source() + ); + }) + ; + } +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/example/top/src.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/example/top/src.js new file mode 100644 index 0000000..0c92e48 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/example/top/src.js @@ -0,0 +1,18 @@ +function boop () { + for (var i = 0; i < 30; i++) { + nop(); + } +} + +function nop () { + return undefined; +} + +var times = 0; +var iv = setInterval(function () { + if (++times === 10) { + clearInterval(iv); + end(); + } + else boop() +}, 100); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/index.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/index.js new file mode 100644 index 0000000..ed5d437 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/index.js @@ -0,0 +1,116 @@ +var burrito = require('burrito'); +var vm = require('vm'); +var EventEmitter = require('events').EventEmitter; + +module.exports = function (src) { + var b = new Bunker(); + if (src) b.include(src); + return b; +}; + +function Bunker () { + this.sources = []; + this.nodes = []; + + this.names = { + call : burrito.generateName(6), + expr : burrito.generateName(6), + stat : burrito.generateName(6), + return : burrito.generateName(6) + }; +} + +Bunker.prototype = new EventEmitter; + +Bunker.prototype.include = function (src) { + this.sources.push(src); + this.source = null; + return this; +}; + +Bunker.prototype.compile = function () { + var src = this.sources.join('\n'); + var nodes = this.nodes; + var names = this.names; + + return burrito(src, function (node) { + var i = nodes.length; + + if (node.name === 'call') { + nodes.push(node); + node.wrap(names.call + '(' + i + ')(%s)'); + } + else if (node.name === 'stat' || node.name === 'throw' + || node.name === 'var') { + nodes.push(node); + node.wrap('{' + names.stat + '(' + i + ');%s}'); + } + else if (node.name === 'return') { + nodes.push(node); + // We need to wrap the new source in a function definition + // so that UglifyJS will allow the presence of return + var stat = names.stat + '(' + i + ');'; + var wrapped = 'function ' + names.return + '() {' + + stat + node.source() + +'}' + ; + var parsed = burrito.parse(wrapped); + // Remove the function definition from the AST + parsed[1] = parsed[1][0][3]; + node.state.update(parsed, true); + } + else if (node.name === 'binary') { + nodes.push(node); + node.wrap(names.expr + '(' + i + ')(%s)'); + } + else if (node.name === 'unary-postfix' || node.name === 'unary-prefix') { + nodes.push(node); + node.wrap(names.expr + '(' + i + ')(%s)'); + } + + if (i !== nodes.length) { + node.id = i; + } + }); +}; + +Bunker.prototype.assign = function (context) { + if (!context) context = {}; + + var self = this; + var stack = []; + + context[self.names.call] = function (i) { + var node = self.nodes[i]; + stack.unshift(node); + self.emit('node', node, stack); + + return function (expr) { + stack.shift(); + return expr; + }; + }; + + context[self.names.expr] = function (i) { + var node = self.nodes[i]; + self.emit('node', node, stack); + + return function (expr) { + return expr; + }; + }; + + context[self.names.stat] = function (i) { + var node = self.nodes[i]; + self.emit('node', node, stack); + }; + + return context; +}; + +Bunker.prototype.run = function (context) { + var src = this.compile(); + vm.runInNewContext(src, this.assign(context)); + + return this; +}; diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/.npmignore b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/.npmignore new file mode 100644 index 0000000..3c3629e --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/.npmignore @@ -0,0 +1 @@ +node_modules diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/.travis.yml b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/.travis.yml new file mode 100644 index 0000000..f1d0f13 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/.travis.yml @@ -0,0 +1,4 @@ +language: node_js +node_js: + - 0.4 + - 0.6 diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/README.markdown b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/README.markdown new file mode 100644 index 0000000..7c9097c --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/README.markdown @@ -0,0 +1,187 @@ +burrito +======= + +Burrito makes it easy to do crazy stuff with the javascript AST. + +This is super useful if you want to roll your own stack traces or build a code +coverage tool. + +[![build status](https://secure.travis-ci.org/substack/node-burrito.png)](http://travis-ci.org/substack/node-burrito) + +![node.wrap("burrito")](http://substack.net/images/burrito.png) + +examples +======== + +microwave +--------- + +examples/microwave.js + +````javascript +var burrito = require('burrito'); + +var res = burrito.microwave('Math.sin(2)', function (node) { + if (node.name === 'num') node.wrap('Math.PI / %s'); +}); + +console.log(res); // sin(pi / 2) == 1 +```` + +output: + + 1 + +wrap +---- + +examples/wrap.js + +````javascript +var burrito = require('burrito'); + +var src = burrito('f() && g(h())\nfoo()', function (node) { + if (node.name === 'call') node.wrap('qqq(%s)'); +}); + +console.log(src); +```` + +output: + + qqq(f()) && qqq(g(qqq(h()))); + + qqq(foo()); + +methods +======= + + var burrito = require('burrito'); + +burrito(code, cb) +----------------- + +Given some source `code` and a function `trace`, walk the ast by expression. + +The `cb` gets called with a node object described below. + +If `code` is an Array then it is assumbed to be an AST which you can generate +yourself with `burrito.parse()`. The AST must be annotated, so make sure to +`burrito.parse(src, false, true)`. + +burrito.microwave(code, context={}, cb) +--------------------------------------- + +Like `burrito()` except the result is run using +`vm.runInNewContext(res, context)`. + +node object +=========== + +node.name +--------- + +Name is a string that contains the type of the expression as named by uglify. + +node.wrap(s) +------------ + +Wrap the current expression in `s`. + +If `s` is a string, `"%s"` will be replaced with the stringified current +expression. + +If `s` is a function, it is called with the stringified current expression and +should return a new stringified expression. + +If the `node.name === "binary"`, you get the subterms "%a" and "%b" to play with +too. These subterms are applied if `s` is a function too: `s(expr, a, b)`. + +Protip: to insert multiple statements you can use javascript's lesser-known block +syntax that it gets from C: + +````javascript +if (node.name === 'stat') node.wrap('{ foo(); %s }') +```` + +node.node +--------- + +raw ast data generated by uglify + +node.value +---------- + +`node.node.slice(1)` to skip the annotations + +node.start +---------- + +The start location of the expression, like this: + +````javascript +{ type: 'name', + value: 'b', + line: 0, + col: 3, + pos: 3, + nlb: false, + comments_before: [] } +```` + +node.end +-------- + +The end location of the expression, formatted the same as `node.start`. + +node.state +---------- + +The state of the traversal using traverse. + +node.source() +------------- + +Returns a stringified version of the expression. + +node.parent() +------------- + +Returns the parent `node` or `null` if the node is the root element. + +node.label() +------------ + +Return the label of the present node or `null` if there is no label. + +Labels are returned for "call", "var", "defun", and "function" nodes. + +Returns an array for "var" nodes since `var` statements can +contain multiple labels in assignment. + +install +======= + +With [npm](http://npmjs.org) you can just: + + npm install burrito + +in the browser +============== + +Burrito works in browser with +[browserify](https://github.com/substack/node-browserify). + +It has been tested against: + +* Internet Explorer 5.5, 6.0, 7.0, 8.0, 9.0 +* Firefox 3.5 +* Chrome 6.0 +* Opera 10.6 +* Safari 5.0 + +kudos +===== + +Heavily inspired by (and previously mostly lifted outright from) isaacs's nifty +tmp/instrument.js thingy from uglify-js. diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/example/microwave.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/example/microwave.js new file mode 100644 index 0000000..c6fcf45 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/example/microwave.js @@ -0,0 +1,8 @@ +var burrito = require('burrito'); + +var res = burrito.microwave('Math.sin(2)', function (node) { + console.dir(node); + if (node.name === 'num') node.wrap('Math.PI / %s'); +}); + +console.log(res); // sin(pi / 2) == 1 diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/example/web/bs.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/example/web/bs.js new file mode 100644 index 0000000..3583c7f --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/example/web/bs.js @@ -0,0 +1,4832 @@ +var require = function (file, cwd) { + var resolved = require.resolve(file, cwd || '/'); + var mod = require.modules[resolved]; + if (!mod) throw new Error( + 'Failed to resolve module ' + file + ', tried ' + resolved + ); + var res = mod._cached ? mod._cached : mod(); + return res; +} +var __require = require; + +require.paths = []; +require.modules = {}; +require.extensions = [".js",".coffee"]; + +require.resolve = (function () { + var core = { + 'assert': true, + 'events': true, + 'fs': true, + 'path': true, + 'vm': true + }; + + return function (x, cwd) { + if (!cwd) cwd = '/'; + + if (core[x]) return x; + var path = require.modules.path(); + var y = cwd || '.'; + + if (x.match(/^(?:\.\.?\/|\/)/)) { + var m = loadAsFileSync(path.resolve(y, x)) + || loadAsDirectorySync(path.resolve(y, x)); + if (m) return m; + } + + var n = loadNodeModulesSync(x, y); + if (n) return n; + + throw new Error("Cannot find module '" + x + "'"); + + function loadAsFileSync (x) { + if (require.modules[x]) { + return x; + } + + for (var i = 0; i < require.extensions.length; i++) { + var ext = require.extensions[i]; + if (require.modules[x + ext]) return x + ext; + } + } + + function loadAsDirectorySync (x) { + x = x.replace(/\/+$/, ''); + var pkgfile = x + '/package.json'; + if (require.modules[pkgfile]) { + var pkg = require.modules[pkgfile](); + var b = pkg.browserify; + if (typeof b === 'object' && b.main) { + var m = loadAsFileSync(path.resolve(x, b.main)); + if (m) return m; + } + else if (typeof b === 'string') { + var m = loadAsFileSync(path.resolve(x, b)); + if (m) return m; + } + else if (pkg.main) { + var m = loadAsFileSync(path.resolve(x, pkg.main)); + if (m) return m; + } + } + + return loadAsFileSync(x + '/index'); + } + + function loadNodeModulesSync (x, start) { + var dirs = nodeModulesPathsSync(start); + for (var i = 0; i < dirs.length; i++) { + var dir = dirs[i]; + var m = loadAsFileSync(dir + '/' + x); + if (m) return m; + var n = loadAsDirectorySync(dir + '/' + x); + if (n) return n; + } + + var m = loadAsFileSync(x); + if (m) return m; + } + + function nodeModulesPathsSync (start) { + var parts; + if (start === '/') parts = [ '' ]; + else parts = path.normalize(start).split('/'); + + var dirs = []; + for (var i = parts.length - 1; i >= 0; i--) { + if (parts[i] === 'node_modules') continue; + var dir = parts.slice(0, i + 1).join('/') + '/node_modules'; + dirs.push(dir); + } + + return dirs; + } + }; +})(); + +require.alias = function (from, to) { + var path = require.modules.path(); + var res = null; + try { + res = require.resolve(from + '/package.json', '/'); + } + catch (err) { + res = require.resolve(from, '/'); + } + var basedir = path.dirname(res); + + var keys = Object_keys(require.modules); + + for (var i = 0; i < keys.length; i++) { + var key = keys[i]; + if (key.slice(0, basedir.length + 1) === basedir + '/') { + var f = key.slice(basedir.length); + require.modules[to + f] = require.modules[basedir + f]; + } + else if (key === basedir) { + require.modules[to] = require.modules[basedir]; + } + } +}; + +var Object_keys = Object.keys || function (obj) { + var res = []; + for (var key in obj) res.push(key) + return res; +}; + +if (typeof process === 'undefined') process = {}; + +if (!process.nextTick) process.nextTick = function (fn) { + setTimeout(fn, 0); +}; + +if (!process.title) process.title = 'browser'; + +if (!process.binding) process.binding = function (name) { + if (name === 'evals') return require('vm') + else throw new Error('No such module') +}; + +if (!process.cwd) process.cwd = function () { return '.' }; + +require.modules["path"] = function () { + var module = { exports : {} }; + var exports = module.exports; + var __dirname = "."; + var __filename = "path"; + + var require = function (file) { + return __require(file, "."); + }; + + require.resolve = function (file) { + return __require.resolve(name, "."); + }; + + require.modules = __require.modules; + __require.modules["path"]._cached = module.exports; + + (function () { + function filter (xs, fn) { + var res = []; + for (var i = 0; i < xs.length; i++) { + if (fn(xs[i], i, xs)) res.push(xs[i]); + } + return res; +} + +// resolves . and .. elements in a path array with directory names there +// must be no slashes, empty elements, or device names (c:\) in the array +// (so also no leading and trailing slashes - it does not distinguish +// relative and absolute paths) +function normalizeArray(parts, allowAboveRoot) { + // if the path tries to go above the root, `up` ends up > 0 + var up = 0; + for (var i = parts.length; i >= 0; i--) { + var last = parts[i]; + if (last == '.') { + parts.splice(i, 1); + } else if (last === '..') { + parts.splice(i, 1); + up++; + } else if (up) { + parts.splice(i, 1); + up--; + } + } + + // if the path is allowed to go above the root, restore leading ..s + if (allowAboveRoot) { + for (; up--; up) { + parts.unshift('..'); + } + } + + return parts; +} + +// Regex to split a filename into [*, dir, basename, ext] +// posix version +var splitPathRe = /^(.+\/(?!$)|\/)?((?:.+?)?(\.[^.]*)?)$/; + +// path.resolve([from ...], to) +// posix version +exports.resolve = function() { +var resolvedPath = '', + resolvedAbsolute = false; + +for (var i = arguments.length; i >= -1 && !resolvedAbsolute; i--) { + var path = (i >= 0) + ? arguments[i] + : process.cwd(); + + // Skip empty and invalid entries + if (typeof path !== 'string' || !path) { + continue; + } + + resolvedPath = path + '/' + resolvedPath; + resolvedAbsolute = path.charAt(0) === '/'; +} + +// At this point the path should be resolved to a full absolute path, but +// handle relative paths to be safe (might happen when process.cwd() fails) + +// Normalize the path +resolvedPath = normalizeArray(filter(resolvedPath.split('/'), function(p) { + return !!p; + }), !resolvedAbsolute).join('/'); + + return ((resolvedAbsolute ? '/' : '') + resolvedPath) || '.'; +}; + +// path.normalize(path) +// posix version +exports.normalize = function(path) { +var isAbsolute = path.charAt(0) === '/', + trailingSlash = path.slice(-1) === '/'; + +// Normalize the path +path = normalizeArray(filter(path.split('/'), function(p) { + return !!p; + }), !isAbsolute).join('/'); + + if (!path && !isAbsolute) { + path = '.'; + } + if (path && trailingSlash) { + path += '/'; + } + + return (isAbsolute ? '/' : '') + path; +}; + + +// posix version +exports.join = function() { + var paths = Array.prototype.slice.call(arguments, 0); + return exports.normalize(filter(paths, function(p, index) { + return p && typeof p === 'string'; + }).join('/')); +}; + + +exports.dirname = function(path) { + var dir = splitPathRe.exec(path)[1] || ''; + var isWindows = false; + if (!dir) { + // No dirname + return '.'; + } else if (dir.length === 1 || + (isWindows && dir.length <= 3 && dir.charAt(1) === ':')) { + // It is just a slash or a drive letter with a slash + return dir; + } else { + // It is a full dirname, strip trailing slash + return dir.substring(0, dir.length - 1); + } +}; + + +exports.basename = function(path, ext) { + var f = splitPathRe.exec(path)[2] || ''; + // TODO: make this comparison case-insensitive on windows? + if (ext && f.substr(-1 * ext.length) === ext) { + f = f.substr(0, f.length - ext.length); + } + return f; +}; + + +exports.extname = function(path) { + return splitPathRe.exec(path)[3] || ''; +}; +; + }).call(module.exports); + + __require.modules["path"]._cached = module.exports; + return module.exports; +}; + +require.modules["/node_modules/burrito/package.json"] = function () { + var module = { exports : {} }; + var exports = module.exports; + var __dirname = "/node_modules/burrito"; + var __filename = "/node_modules/burrito/package.json"; + + var require = function (file) { + return __require(file, "/node_modules/burrito"); + }; + + require.resolve = function (file) { + return __require.resolve(name, "/node_modules/burrito"); + }; + + require.modules = __require.modules; + __require.modules["/node_modules/burrito/package.json"]._cached = module.exports; + + (function () { + module.exports = {"name":"burrito","description":"Wrap up expressions with a trace function while walking the AST with rice and beans on the side","version":"0.2.8","repository":{"type":"git","url":"git://github.com/substack/node-burrito.git"},"main":"./index.js","keywords":["trace","ast","walk","syntax","source","tree","uglify"],"directories":{"lib":".","example":"example","test":"test"},"scripts":{"test":"expresso"},"dependencies":{"traverse":">=0.5.1 <0.6","uglify-js":"1.0.4"},"devDependencies":{"expresso":"=0.7.x"},"engines":{"node":">=0.4.0"},"license":"BSD","author":{"name":"James Halliday","email":"mail@substack.net","url":"http://substack.net"}}; + }).call(module.exports); + + __require.modules["/node_modules/burrito/package.json"]._cached = module.exports; + return module.exports; +}; + +require.modules["/node_modules/burrito/node_modules/uglify-js/package.json"] = function () { + var module = { exports : {} }; + var exports = module.exports; + var __dirname = "/node_modules/burrito/node_modules/uglify-js"; + var __filename = "/node_modules/burrito/node_modules/uglify-js/package.json"; + + var require = function (file) { + return __require(file, "/node_modules/burrito/node_modules/uglify-js"); + }; + + require.resolve = function (file) { + return __require.resolve(name, "/node_modules/burrito/node_modules/uglify-js"); + }; + + require.modules = __require.modules; + __require.modules["/node_modules/burrito/node_modules/uglify-js/package.json"]._cached = module.exports; + + (function () { + module.exports = {"name":"uglify-js","author":{"name":"Mihai Bazon","email":"mihai.bazon@gmail.com","url":"http://mihai.bazon.net/blog"},"version":"1.0.4","main":"./uglify-js.js","bin":{"uglifyjs":"./bin/uglifyjs"},"repository":{"type":"git","url":"git@github.com:mishoo/UglifyJS.git"}}; + }).call(module.exports); + + __require.modules["/node_modules/burrito/node_modules/uglify-js/package.json"]._cached = module.exports; + return module.exports; +}; + +require.modules["/node_modules/burrito/node_modules/uglify-js/uglify-js.js"] = function () { + var module = { exports : {} }; + var exports = module.exports; + var __dirname = "/node_modules/burrito/node_modules/uglify-js"; + var __filename = "/node_modules/burrito/node_modules/uglify-js/uglify-js.js"; + + var require = function (file) { + return __require(file, "/node_modules/burrito/node_modules/uglify-js"); + }; + + require.resolve = function (file) { + return __require.resolve(name, "/node_modules/burrito/node_modules/uglify-js"); + }; + + require.modules = __require.modules; + __require.modules["/node_modules/burrito/node_modules/uglify-js/uglify-js.js"]._cached = module.exports; + + (function () { + //convienence function(src, [options]); +function uglify(orig_code, options){ + options || (options = {}); + var jsp = uglify.parser; + var pro = uglify.uglify; + + var ast = jsp.parse(orig_code, options.strict_semicolons); // parse code and get the initial AST + ast = pro.ast_mangle(ast, options.mangle_options); // get a new AST with mangled names + ast = pro.ast_squeeze(ast, options.squeeze_options); // get an AST with compression optimizations + var final_code = pro.gen_code(ast, options.gen_options); // compressed code here + return final_code; +}; + +uglify.parser = require("./lib/parse-js"); +uglify.uglify = require("./lib/process"); + +module.exports = uglify; + }).call(module.exports); + + __require.modules["/node_modules/burrito/node_modules/uglify-js/uglify-js.js"]._cached = module.exports; + return module.exports; +}; + +require.modules["/node_modules/burrito/node_modules/uglify-js/lib/parse-js.js"] = function () { + var module = { exports : {} }; + var exports = module.exports; + var __dirname = "/node_modules/burrito/node_modules/uglify-js/lib"; + var __filename = "/node_modules/burrito/node_modules/uglify-js/lib/parse-js.js"; + + var require = function (file) { + return __require(file, "/node_modules/burrito/node_modules/uglify-js/lib"); + }; + + require.resolve = function (file) { + return __require.resolve(name, "/node_modules/burrito/node_modules/uglify-js/lib"); + }; + + require.modules = __require.modules; + __require.modules["/node_modules/burrito/node_modules/uglify-js/lib/parse-js.js"]._cached = module.exports; + + (function () { + /*********************************************************************** + + A JavaScript tokenizer / parser / beautifier / compressor. + + This version is suitable for Node.js. With minimal changes (the + exports stuff) it should work on any JS platform. + + This file contains the tokenizer/parser. It is a port to JavaScript + of parse-js [1], a JavaScript parser library written in Common Lisp + by Marijn Haverbeke. Thank you Marijn! + + [1] http://marijn.haverbeke.nl/parse-js/ + + Exported functions: + + - tokenizer(code) -- returns a function. Call the returned + function to fetch the next token. + + - parse(code) -- returns an AST of the given JavaScript code. + + -------------------------------- (C) --------------------------------- + + Author: Mihai Bazon + + http://mihai.bazon.net/blog + + Distributed under the BSD license: + + Copyright 2010 (c) Mihai Bazon + Based on parse-js (http://marijn.haverbeke.nl/parse-js/). + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + * Redistributions of source code must retain the above + copyright notice, this list of conditions and the following + disclaimer. + + * Redistributions in binary form must reproduce the above + copyright notice, this list of conditions and the following + disclaimer in the documentation and/or other materials + provided with the distribution. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER “AS IS” AND ANY + EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR + PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER BE + LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, + OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, + PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR + PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR + TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF + THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + SUCH DAMAGE. + + ***********************************************************************/ + +/* -----[ Tokenizer (constants) ]----- */ + +var KEYWORDS = array_to_hash([ + "break", + "case", + "catch", + "const", + "continue", + "default", + "delete", + "do", + "else", + "finally", + "for", + "function", + "if", + "in", + "instanceof", + "new", + "return", + "switch", + "throw", + "try", + "typeof", + "var", + "void", + "while", + "with" +]); + +var RESERVED_WORDS = array_to_hash([ + "abstract", + "boolean", + "byte", + "char", + "class", + "debugger", + "double", + "enum", + "export", + "extends", + "final", + "float", + "goto", + "implements", + "import", + "int", + "interface", + "long", + "native", + "package", + "private", + "protected", + "public", + "short", + "static", + "super", + "synchronized", + "throws", + "transient", + "volatile" +]); + +var KEYWORDS_BEFORE_EXPRESSION = array_to_hash([ + "return", + "new", + "delete", + "throw", + "else", + "case" +]); + +var KEYWORDS_ATOM = array_to_hash([ + "false", + "null", + "true", + "undefined" +]); + +var OPERATOR_CHARS = array_to_hash(characters("+-*&%=<>!?|~^")); + +var RE_HEX_NUMBER = /^0x[0-9a-f]+$/i; +var RE_OCT_NUMBER = /^0[0-7]+$/; +var RE_DEC_NUMBER = /^\d*\.?\d*(?:e[+-]?\d*(?:\d\.?|\.?\d)\d*)?$/i; + +var OPERATORS = array_to_hash([ + "in", + "instanceof", + "typeof", + "new", + "void", + "delete", + "++", + "--", + "+", + "-", + "!", + "~", + "&", + "|", + "^", + "*", + "/", + "%", + ">>", + "<<", + ">>>", + "<", + ">", + "<=", + ">=", + "==", + "===", + "!=", + "!==", + "?", + "=", + "+=", + "-=", + "/=", + "*=", + "%=", + ">>=", + "<<=", + ">>>=", + "|=", + "^=", + "&=", + "&&", + "||" +]); + +var WHITESPACE_CHARS = array_to_hash(characters(" \u00a0\n\r\t\f\v\u200b")); + +var PUNC_BEFORE_EXPRESSION = array_to_hash(characters("[{}(,.;:")); + +var PUNC_CHARS = array_to_hash(characters("[]{}(),;:")); + +var REGEXP_MODIFIERS = array_to_hash(characters("gmsiy")); + +/* -----[ Tokenizer ]----- */ + +// regexps adapted from http://xregexp.com/plugins/#unicode +var UNICODE = { + letter: new RegExp("[\\u0041-\\u005A\\u0061-\\u007A\\u00AA\\u00B5\\u00BA\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02C1\\u02C6-\\u02D1\\u02E0-\\u02E4\\u02EC\\u02EE\\u0370-\\u0374\\u0376\\u0377\\u037A-\\u037D\\u0386\\u0388-\\u038A\\u038C\\u038E-\\u03A1\\u03A3-\\u03F5\\u03F7-\\u0481\\u048A-\\u0523\\u0531-\\u0556\\u0559\\u0561-\\u0587\\u05D0-\\u05EA\\u05F0-\\u05F2\\u0621-\\u064A\\u066E\\u066F\\u0671-\\u06D3\\u06D5\\u06E5\\u06E6\\u06EE\\u06EF\\u06FA-\\u06FC\\u06FF\\u0710\\u0712-\\u072F\\u074D-\\u07A5\\u07B1\\u07CA-\\u07EA\\u07F4\\u07F5\\u07FA\\u0904-\\u0939\\u093D\\u0950\\u0958-\\u0961\\u0971\\u0972\\u097B-\\u097F\\u0985-\\u098C\\u098F\\u0990\\u0993-\\u09A8\\u09AA-\\u09B0\\u09B2\\u09B6-\\u09B9\\u09BD\\u09CE\\u09DC\\u09DD\\u09DF-\\u09E1\\u09F0\\u09F1\\u0A05-\\u0A0A\\u0A0F\\u0A10\\u0A13-\\u0A28\\u0A2A-\\u0A30\\u0A32\\u0A33\\u0A35\\u0A36\\u0A38\\u0A39\\u0A59-\\u0A5C\\u0A5E\\u0A72-\\u0A74\\u0A85-\\u0A8D\\u0A8F-\\u0A91\\u0A93-\\u0AA8\\u0AAA-\\u0AB0\\u0AB2\\u0AB3\\u0AB5-\\u0AB9\\u0ABD\\u0AD0\\u0AE0\\u0AE1\\u0B05-\\u0B0C\\u0B0F\\u0B10\\u0B13-\\u0B28\\u0B2A-\\u0B30\\u0B32\\u0B33\\u0B35-\\u0B39\\u0B3D\\u0B5C\\u0B5D\\u0B5F-\\u0B61\\u0B71\\u0B83\\u0B85-\\u0B8A\\u0B8E-\\u0B90\\u0B92-\\u0B95\\u0B99\\u0B9A\\u0B9C\\u0B9E\\u0B9F\\u0BA3\\u0BA4\\u0BA8-\\u0BAA\\u0BAE-\\u0BB9\\u0BD0\\u0C05-\\u0C0C\\u0C0E-\\u0C10\\u0C12-\\u0C28\\u0C2A-\\u0C33\\u0C35-\\u0C39\\u0C3D\\u0C58\\u0C59\\u0C60\\u0C61\\u0C85-\\u0C8C\\u0C8E-\\u0C90\\u0C92-\\u0CA8\\u0CAA-\\u0CB3\\u0CB5-\\u0CB9\\u0CBD\\u0CDE\\u0CE0\\u0CE1\\u0D05-\\u0D0C\\u0D0E-\\u0D10\\u0D12-\\u0D28\\u0D2A-\\u0D39\\u0D3D\\u0D60\\u0D61\\u0D7A-\\u0D7F\\u0D85-\\u0D96\\u0D9A-\\u0DB1\\u0DB3-\\u0DBB\\u0DBD\\u0DC0-\\u0DC6\\u0E01-\\u0E30\\u0E32\\u0E33\\u0E40-\\u0E46\\u0E81\\u0E82\\u0E84\\u0E87\\u0E88\\u0E8A\\u0E8D\\u0E94-\\u0E97\\u0E99-\\u0E9F\\u0EA1-\\u0EA3\\u0EA5\\u0EA7\\u0EAA\\u0EAB\\u0EAD-\\u0EB0\\u0EB2\\u0EB3\\u0EBD\\u0EC0-\\u0EC4\\u0EC6\\u0EDC\\u0EDD\\u0F00\\u0F40-\\u0F47\\u0F49-\\u0F6C\\u0F88-\\u0F8B\\u1000-\\u102A\\u103F\\u1050-\\u1055\\u105A-\\u105D\\u1061\\u1065\\u1066\\u106E-\\u1070\\u1075-\\u1081\\u108E\\u10A0-\\u10C5\\u10D0-\\u10FA\\u10FC\\u1100-\\u1159\\u115F-\\u11A2\\u11A8-\\u11F9\\u1200-\\u1248\\u124A-\\u124D\\u1250-\\u1256\\u1258\\u125A-\\u125D\\u1260-\\u1288\\u128A-\\u128D\\u1290-\\u12B0\\u12B2-\\u12B5\\u12B8-\\u12BE\\u12C0\\u12C2-\\u12C5\\u12C8-\\u12D6\\u12D8-\\u1310\\u1312-\\u1315\\u1318-\\u135A\\u1380-\\u138F\\u13A0-\\u13F4\\u1401-\\u166C\\u166F-\\u1676\\u1681-\\u169A\\u16A0-\\u16EA\\u1700-\\u170C\\u170E-\\u1711\\u1720-\\u1731\\u1740-\\u1751\\u1760-\\u176C\\u176E-\\u1770\\u1780-\\u17B3\\u17D7\\u17DC\\u1820-\\u1877\\u1880-\\u18A8\\u18AA\\u1900-\\u191C\\u1950-\\u196D\\u1970-\\u1974\\u1980-\\u19A9\\u19C1-\\u19C7\\u1A00-\\u1A16\\u1B05-\\u1B33\\u1B45-\\u1B4B\\u1B83-\\u1BA0\\u1BAE\\u1BAF\\u1C00-\\u1C23\\u1C4D-\\u1C4F\\u1C5A-\\u1C7D\\u1D00-\\u1DBF\\u1E00-\\u1F15\\u1F18-\\u1F1D\\u1F20-\\u1F45\\u1F48-\\u1F4D\\u1F50-\\u1F57\\u1F59\\u1F5B\\u1F5D\\u1F5F-\\u1F7D\\u1F80-\\u1FB4\\u1FB6-\\u1FBC\\u1FBE\\u1FC2-\\u1FC4\\u1FC6-\\u1FCC\\u1FD0-\\u1FD3\\u1FD6-\\u1FDB\\u1FE0-\\u1FEC\\u1FF2-\\u1FF4\\u1FF6-\\u1FFC\\u2071\\u207F\\u2090-\\u2094\\u2102\\u2107\\u210A-\\u2113\\u2115\\u2119-\\u211D\\u2124\\u2126\\u2128\\u212A-\\u212D\\u212F-\\u2139\\u213C-\\u213F\\u2145-\\u2149\\u214E\\u2183\\u2184\\u2C00-\\u2C2E\\u2C30-\\u2C5E\\u2C60-\\u2C6F\\u2C71-\\u2C7D\\u2C80-\\u2CE4\\u2D00-\\u2D25\\u2D30-\\u2D65\\u2D6F\\u2D80-\\u2D96\\u2DA0-\\u2DA6\\u2DA8-\\u2DAE\\u2DB0-\\u2DB6\\u2DB8-\\u2DBE\\u2DC0-\\u2DC6\\u2DC8-\\u2DCE\\u2DD0-\\u2DD6\\u2DD8-\\u2DDE\\u2E2F\\u3005\\u3006\\u3031-\\u3035\\u303B\\u303C\\u3041-\\u3096\\u309D-\\u309F\\u30A1-\\u30FA\\u30FC-\\u30FF\\u3105-\\u312D\\u3131-\\u318E\\u31A0-\\u31B7\\u31F0-\\u31FF\\u3400\\u4DB5\\u4E00\\u9FC3\\uA000-\\uA48C\\uA500-\\uA60C\\uA610-\\uA61F\\uA62A\\uA62B\\uA640-\\uA65F\\uA662-\\uA66E\\uA67F-\\uA697\\uA717-\\uA71F\\uA722-\\uA788\\uA78B\\uA78C\\uA7FB-\\uA801\\uA803-\\uA805\\uA807-\\uA80A\\uA80C-\\uA822\\uA840-\\uA873\\uA882-\\uA8B3\\uA90A-\\uA925\\uA930-\\uA946\\uAA00-\\uAA28\\uAA40-\\uAA42\\uAA44-\\uAA4B\\uAC00\\uD7A3\\uF900-\\uFA2D\\uFA30-\\uFA6A\\uFA70-\\uFAD9\\uFB00-\\uFB06\\uFB13-\\uFB17\\uFB1D\\uFB1F-\\uFB28\\uFB2A-\\uFB36\\uFB38-\\uFB3C\\uFB3E\\uFB40\\uFB41\\uFB43\\uFB44\\uFB46-\\uFBB1\\uFBD3-\\uFD3D\\uFD50-\\uFD8F\\uFD92-\\uFDC7\\uFDF0-\\uFDFB\\uFE70-\\uFE74\\uFE76-\\uFEFC\\uFF21-\\uFF3A\\uFF41-\\uFF5A\\uFF66-\\uFFBE\\uFFC2-\\uFFC7\\uFFCA-\\uFFCF\\uFFD2-\\uFFD7\\uFFDA-\\uFFDC]"), + non_spacing_mark: new RegExp("[\\u0300-\\u036F\\u0483-\\u0487\\u0591-\\u05BD\\u05BF\\u05C1\\u05C2\\u05C4\\u05C5\\u05C7\\u0610-\\u061A\\u064B-\\u065E\\u0670\\u06D6-\\u06DC\\u06DF-\\u06E4\\u06E7\\u06E8\\u06EA-\\u06ED\\u0711\\u0730-\\u074A\\u07A6-\\u07B0\\u07EB-\\u07F3\\u0816-\\u0819\\u081B-\\u0823\\u0825-\\u0827\\u0829-\\u082D\\u0900-\\u0902\\u093C\\u0941-\\u0948\\u094D\\u0951-\\u0955\\u0962\\u0963\\u0981\\u09BC\\u09C1-\\u09C4\\u09CD\\u09E2\\u09E3\\u0A01\\u0A02\\u0A3C\\u0A41\\u0A42\\u0A47\\u0A48\\u0A4B-\\u0A4D\\u0A51\\u0A70\\u0A71\\u0A75\\u0A81\\u0A82\\u0ABC\\u0AC1-\\u0AC5\\u0AC7\\u0AC8\\u0ACD\\u0AE2\\u0AE3\\u0B01\\u0B3C\\u0B3F\\u0B41-\\u0B44\\u0B4D\\u0B56\\u0B62\\u0B63\\u0B82\\u0BC0\\u0BCD\\u0C3E-\\u0C40\\u0C46-\\u0C48\\u0C4A-\\u0C4D\\u0C55\\u0C56\\u0C62\\u0C63\\u0CBC\\u0CBF\\u0CC6\\u0CCC\\u0CCD\\u0CE2\\u0CE3\\u0D41-\\u0D44\\u0D4D\\u0D62\\u0D63\\u0DCA\\u0DD2-\\u0DD4\\u0DD6\\u0E31\\u0E34-\\u0E3A\\u0E47-\\u0E4E\\u0EB1\\u0EB4-\\u0EB9\\u0EBB\\u0EBC\\u0EC8-\\u0ECD\\u0F18\\u0F19\\u0F35\\u0F37\\u0F39\\u0F71-\\u0F7E\\u0F80-\\u0F84\\u0F86\\u0F87\\u0F90-\\u0F97\\u0F99-\\u0FBC\\u0FC6\\u102D-\\u1030\\u1032-\\u1037\\u1039\\u103A\\u103D\\u103E\\u1058\\u1059\\u105E-\\u1060\\u1071-\\u1074\\u1082\\u1085\\u1086\\u108D\\u109D\\u135F\\u1712-\\u1714\\u1732-\\u1734\\u1752\\u1753\\u1772\\u1773\\u17B7-\\u17BD\\u17C6\\u17C9-\\u17D3\\u17DD\\u180B-\\u180D\\u18A9\\u1920-\\u1922\\u1927\\u1928\\u1932\\u1939-\\u193B\\u1A17\\u1A18\\u1A56\\u1A58-\\u1A5E\\u1A60\\u1A62\\u1A65-\\u1A6C\\u1A73-\\u1A7C\\u1A7F\\u1B00-\\u1B03\\u1B34\\u1B36-\\u1B3A\\u1B3C\\u1B42\\u1B6B-\\u1B73\\u1B80\\u1B81\\u1BA2-\\u1BA5\\u1BA8\\u1BA9\\u1C2C-\\u1C33\\u1C36\\u1C37\\u1CD0-\\u1CD2\\u1CD4-\\u1CE0\\u1CE2-\\u1CE8\\u1CED\\u1DC0-\\u1DE6\\u1DFD-\\u1DFF\\u20D0-\\u20DC\\u20E1\\u20E5-\\u20F0\\u2CEF-\\u2CF1\\u2DE0-\\u2DFF\\u302A-\\u302F\\u3099\\u309A\\uA66F\\uA67C\\uA67D\\uA6F0\\uA6F1\\uA802\\uA806\\uA80B\\uA825\\uA826\\uA8C4\\uA8E0-\\uA8F1\\uA926-\\uA92D\\uA947-\\uA951\\uA980-\\uA982\\uA9B3\\uA9B6-\\uA9B9\\uA9BC\\uAA29-\\uAA2E\\uAA31\\uAA32\\uAA35\\uAA36\\uAA43\\uAA4C\\uAAB0\\uAAB2-\\uAAB4\\uAAB7\\uAAB8\\uAABE\\uAABF\\uAAC1\\uABE5\\uABE8\\uABED\\uFB1E\\uFE00-\\uFE0F\\uFE20-\\uFE26]"), + space_combining_mark: new RegExp("[\\u0903\\u093E-\\u0940\\u0949-\\u094C\\u094E\\u0982\\u0983\\u09BE-\\u09C0\\u09C7\\u09C8\\u09CB\\u09CC\\u09D7\\u0A03\\u0A3E-\\u0A40\\u0A83\\u0ABE-\\u0AC0\\u0AC9\\u0ACB\\u0ACC\\u0B02\\u0B03\\u0B3E\\u0B40\\u0B47\\u0B48\\u0B4B\\u0B4C\\u0B57\\u0BBE\\u0BBF\\u0BC1\\u0BC2\\u0BC6-\\u0BC8\\u0BCA-\\u0BCC\\u0BD7\\u0C01-\\u0C03\\u0C41-\\u0C44\\u0C82\\u0C83\\u0CBE\\u0CC0-\\u0CC4\\u0CC7\\u0CC8\\u0CCA\\u0CCB\\u0CD5\\u0CD6\\u0D02\\u0D03\\u0D3E-\\u0D40\\u0D46-\\u0D48\\u0D4A-\\u0D4C\\u0D57\\u0D82\\u0D83\\u0DCF-\\u0DD1\\u0DD8-\\u0DDF\\u0DF2\\u0DF3\\u0F3E\\u0F3F\\u0F7F\\u102B\\u102C\\u1031\\u1038\\u103B\\u103C\\u1056\\u1057\\u1062-\\u1064\\u1067-\\u106D\\u1083\\u1084\\u1087-\\u108C\\u108F\\u109A-\\u109C\\u17B6\\u17BE-\\u17C5\\u17C7\\u17C8\\u1923-\\u1926\\u1929-\\u192B\\u1930\\u1931\\u1933-\\u1938\\u19B0-\\u19C0\\u19C8\\u19C9\\u1A19-\\u1A1B\\u1A55\\u1A57\\u1A61\\u1A63\\u1A64\\u1A6D-\\u1A72\\u1B04\\u1B35\\u1B3B\\u1B3D-\\u1B41\\u1B43\\u1B44\\u1B82\\u1BA1\\u1BA6\\u1BA7\\u1BAA\\u1C24-\\u1C2B\\u1C34\\u1C35\\u1CE1\\u1CF2\\uA823\\uA824\\uA827\\uA880\\uA881\\uA8B4-\\uA8C3\\uA952\\uA953\\uA983\\uA9B4\\uA9B5\\uA9BA\\uA9BB\\uA9BD-\\uA9C0\\uAA2F\\uAA30\\uAA33\\uAA34\\uAA4D\\uAA7B\\uABE3\\uABE4\\uABE6\\uABE7\\uABE9\\uABEA\\uABEC]"), + connector_punctuation: new RegExp("[\\u005F\\u203F\\u2040\\u2054\\uFE33\\uFE34\\uFE4D-\\uFE4F\\uFF3F]") +}; + +function is_letter(ch) { + return UNICODE.letter.test(ch); +}; + +function is_digit(ch) { + ch = ch.charCodeAt(0); + return ch >= 48 && ch <= 57; //XXX: find out if "UnicodeDigit" means something else than 0..9 +}; + +function is_alphanumeric_char(ch) { + return is_digit(ch) || is_letter(ch); +}; + +function is_unicode_combining_mark(ch) { + return UNICODE.non_spacing_mark.test(ch) || UNICODE.space_combining_mark.test(ch); +}; + +function is_unicode_connector_punctuation(ch) { + return UNICODE.connector_punctuation.test(ch); +}; + +function is_identifier_start(ch) { + return ch == "$" || ch == "_" || is_letter(ch); +}; + +function is_identifier_char(ch) { + return is_identifier_start(ch) + || is_unicode_combining_mark(ch) + || is_digit(ch) + || is_unicode_connector_punctuation(ch) + || ch == "\u200c" // zero-width non-joiner + || ch == "\u200d" // zero-width joiner (in my ECMA-262 PDF, this is also 200c) + ; +}; + +function parse_js_number(num) { + if (RE_HEX_NUMBER.test(num)) { + return parseInt(num.substr(2), 16); + } else if (RE_OCT_NUMBER.test(num)) { + return parseInt(num.substr(1), 8); + } else if (RE_DEC_NUMBER.test(num)) { + return parseFloat(num); + } +}; + +function JS_Parse_Error(message, line, col, pos) { + this.message = message; + this.line = line; + this.col = col; + this.pos = pos; + try { + ({})(); + } catch(ex) { + this.stack = ex.stack; + }; +}; + +JS_Parse_Error.prototype.toString = function() { + return this.message + " (line: " + this.line + ", col: " + this.col + ", pos: " + this.pos + ")" + "\n\n" + this.stack; +}; + +function js_error(message, line, col, pos) { + throw new JS_Parse_Error(message, line, col, pos); +}; + +function is_token(token, type, val) { + return token.type == type && (val == null || token.value == val); +}; + +var EX_EOF = {}; + +function tokenizer($TEXT) { + + var S = { + text : $TEXT.replace(/\r\n?|[\n\u2028\u2029]/g, "\n").replace(/^\uFEFF/, ''), + pos : 0, + tokpos : 0, + line : 0, + tokline : 0, + col : 0, + tokcol : 0, + newline_before : false, + regex_allowed : false, + comments_before : [] + }; + + function peek() { return S.text.charAt(S.pos); }; + + function next(signal_eof) { + var ch = S.text.charAt(S.pos++); + if (signal_eof && !ch) + throw EX_EOF; + if (ch == "\n") { + S.newline_before = true; + ++S.line; + S.col = 0; + } else { + ++S.col; + } + return ch; + }; + + function eof() { + return !S.peek(); + }; + + function find(what, signal_eof) { + var pos = S.text.indexOf(what, S.pos); + if (signal_eof && pos == -1) throw EX_EOF; + return pos; + }; + + function start_token() { + S.tokline = S.line; + S.tokcol = S.col; + S.tokpos = S.pos; + }; + + function token(type, value, is_comment) { + S.regex_allowed = ((type == "operator" && !HOP(UNARY_POSTFIX, value)) || + (type == "keyword" && HOP(KEYWORDS_BEFORE_EXPRESSION, value)) || + (type == "punc" && HOP(PUNC_BEFORE_EXPRESSION, value))); + var ret = { + type : type, + value : value, + line : S.tokline, + col : S.tokcol, + pos : S.tokpos, + nlb : S.newline_before + }; + if (!is_comment) { + ret.comments_before = S.comments_before; + S.comments_before = []; + } + S.newline_before = false; + return ret; + }; + + function skip_whitespace() { + while (HOP(WHITESPACE_CHARS, peek())) + next(); + }; + + function read_while(pred) { + var ret = "", ch = peek(), i = 0; + while (ch && pred(ch, i++)) { + ret += next(); + ch = peek(); + } + return ret; + }; + + function parse_error(err) { + js_error(err, S.tokline, S.tokcol, S.tokpos); + }; + + function read_num(prefix) { + var has_e = false, after_e = false, has_x = false, has_dot = prefix == "."; + var num = read_while(function(ch, i){ + if (ch == "x" || ch == "X") { + if (has_x) return false; + return has_x = true; + } + if (!has_x && (ch == "E" || ch == "e")) { + if (has_e) return false; + return has_e = after_e = true; + } + if (ch == "-") { + if (after_e || (i == 0 && !prefix)) return true; + return false; + } + if (ch == "+") return after_e; + after_e = false; + if (ch == ".") { + if (!has_dot && !has_x) + return has_dot = true; + return false; + } + return is_alphanumeric_char(ch); + }); + if (prefix) + num = prefix + num; + var valid = parse_js_number(num); + if (!isNaN(valid)) { + return token("num", valid); + } else { + parse_error("Invalid syntax: " + num); + } + }; + + function read_escaped_char() { + var ch = next(true); + switch (ch) { + case "n" : return "\n"; + case "r" : return "\r"; + case "t" : return "\t"; + case "b" : return "\b"; + case "v" : return "\v"; + case "f" : return "\f"; + case "0" : return "\0"; + case "x" : return String.fromCharCode(hex_bytes(2)); + case "u" : return String.fromCharCode(hex_bytes(4)); + default : return ch; + } + }; + + function hex_bytes(n) { + var num = 0; + for (; n > 0; --n) { + var digit = parseInt(next(true), 16); + if (isNaN(digit)) + parse_error("Invalid hex-character pattern in string"); + num = (num << 4) | digit; + } + return num; + }; + + function read_string() { + return with_eof_error("Unterminated string constant", function(){ + var quote = next(), ret = ""; + for (;;) { + var ch = next(true); + if (ch == "\\") ch = read_escaped_char(); + else if (ch == quote) break; + ret += ch; + } + return token("string", ret); + }); + }; + + function read_line_comment() { + next(); + var i = find("\n"), ret; + if (i == -1) { + ret = S.text.substr(S.pos); + S.pos = S.text.length; + } else { + ret = S.text.substring(S.pos, i); + S.pos = i; + } + return token("comment1", ret, true); + }; + + function read_multiline_comment() { + next(); + return with_eof_error("Unterminated multiline comment", function(){ + var i = find("*/", true), + text = S.text.substring(S.pos, i), + tok = token("comment2", text, true); + S.pos = i + 2; + S.line += text.split("\n").length - 1; + S.newline_before = text.indexOf("\n") >= 0; + + // https://github.com/mishoo/UglifyJS/issues/#issue/100 + if (/^@cc_on/i.test(text)) { + warn("WARNING: at line " + S.line); + warn("*** Found \"conditional comment\": " + text); + warn("*** UglifyJS DISCARDS ALL COMMENTS. This means your code might no longer work properly in Internet Explorer."); + } + + return tok; + }); + }; + + function read_name() { + var backslash = false, name = "", ch; + while ((ch = peek()) != null) { + if (!backslash) { + if (ch == "\\") backslash = true, next(); + else if (is_identifier_char(ch)) name += next(); + else break; + } + else { + if (ch != "u") parse_error("Expecting UnicodeEscapeSequence -- uXXXX"); + ch = read_escaped_char(); + if (!is_identifier_char(ch)) parse_error("Unicode char: " + ch.charCodeAt(0) + " is not valid in identifier"); + name += ch; + backslash = false; + } + } + return name; + }; + + function read_regexp() { + return with_eof_error("Unterminated regular expression", function(){ + var prev_backslash = false, regexp = "", ch, in_class = false; + while ((ch = next(true))) if (prev_backslash) { + regexp += "\\" + ch; + prev_backslash = false; + } else if (ch == "[") { + in_class = true; + regexp += ch; + } else if (ch == "]" && in_class) { + in_class = false; + regexp += ch; + } else if (ch == "/" && !in_class) { + break; + } else if (ch == "\\") { + prev_backslash = true; + } else { + regexp += ch; + } + var mods = read_name(); + return token("regexp", [ regexp, mods ]); + }); + }; + + function read_operator(prefix) { + function grow(op) { + if (!peek()) return op; + var bigger = op + peek(); + if (HOP(OPERATORS, bigger)) { + next(); + return grow(bigger); + } else { + return op; + } + }; + return token("operator", grow(prefix || next())); + }; + + function handle_slash() { + next(); + var regex_allowed = S.regex_allowed; + switch (peek()) { + case "/": + S.comments_before.push(read_line_comment()); + S.regex_allowed = regex_allowed; + return next_token(); + case "*": + S.comments_before.push(read_multiline_comment()); + S.regex_allowed = regex_allowed; + return next_token(); + } + return S.regex_allowed ? read_regexp() : read_operator("/"); + }; + + function handle_dot() { + next(); + return is_digit(peek()) + ? read_num(".") + : token("punc", "."); + }; + + function read_word() { + var word = read_name(); + return !HOP(KEYWORDS, word) + ? token("name", word) + : HOP(OPERATORS, word) + ? token("operator", word) + : HOP(KEYWORDS_ATOM, word) + ? token("atom", word) + : token("keyword", word); + }; + + function with_eof_error(eof_error, cont) { + try { + return cont(); + } catch(ex) { + if (ex === EX_EOF) parse_error(eof_error); + else throw ex; + } + }; + + function next_token(force_regexp) { + if (force_regexp) + return read_regexp(); + skip_whitespace(); + start_token(); + var ch = peek(); + if (!ch) return token("eof"); + if (is_digit(ch)) return read_num(); + if (ch == '"' || ch == "'") return read_string(); + if (HOP(PUNC_CHARS, ch)) return token("punc", next()); + if (ch == ".") return handle_dot(); + if (ch == "/") return handle_slash(); + if (HOP(OPERATOR_CHARS, ch)) return read_operator(); + if (ch == "\\" || is_identifier_start(ch)) return read_word(); + parse_error("Unexpected character '" + ch + "'"); + }; + + next_token.context = function(nc) { + if (nc) S = nc; + return S; + }; + + return next_token; + +}; + +/* -----[ Parser (constants) ]----- */ + +var UNARY_PREFIX = array_to_hash([ + "typeof", + "void", + "delete", + "--", + "++", + "!", + "~", + "-", + "+" +]); + +var UNARY_POSTFIX = array_to_hash([ "--", "++" ]); + +var ASSIGNMENT = (function(a, ret, i){ + while (i < a.length) { + ret[a[i]] = a[i].substr(0, a[i].length - 1); + i++; + } + return ret; +})( + ["+=", "-=", "/=", "*=", "%=", ">>=", "<<=", ">>>=", "|=", "^=", "&="], + { "=": true }, + 0 +); + +var PRECEDENCE = (function(a, ret){ + for (var i = 0, n = 1; i < a.length; ++i, ++n) { + var b = a[i]; + for (var j = 0; j < b.length; ++j) { + ret[b[j]] = n; + } + } + return ret; +})( + [ + ["||"], + ["&&"], + ["|"], + ["^"], + ["&"], + ["==", "===", "!=", "!=="], + ["<", ">", "<=", ">=", "in", "instanceof"], + [">>", "<<", ">>>"], + ["+", "-"], + ["*", "/", "%"] + ], + {} +); + +var STATEMENTS_WITH_LABELS = array_to_hash([ "for", "do", "while", "switch" ]); + +var ATOMIC_START_TOKEN = array_to_hash([ "atom", "num", "string", "regexp", "name" ]); + +/* -----[ Parser ]----- */ + +function NodeWithToken(str, start, end) { + this.name = str; + this.start = start; + this.end = end; +}; + +NodeWithToken.prototype.toString = function() { return this.name; }; + +function parse($TEXT, exigent_mode, embed_tokens) { + + var S = { + input : typeof $TEXT == "string" ? tokenizer($TEXT, true) : $TEXT, + token : null, + prev : null, + peeked : null, + in_function : 0, + in_loop : 0, + labels : [] + }; + + S.token = next(); + + function is(type, value) { + return is_token(S.token, type, value); + }; + + function peek() { return S.peeked || (S.peeked = S.input()); }; + + function next() { + S.prev = S.token; + if (S.peeked) { + S.token = S.peeked; + S.peeked = null; + } else { + S.token = S.input(); + } + return S.token; + }; + + function prev() { + return S.prev; + }; + + function croak(msg, line, col, pos) { + var ctx = S.input.context(); + js_error(msg, + line != null ? line : ctx.tokline, + col != null ? col : ctx.tokcol, + pos != null ? pos : ctx.tokpos); + }; + + function token_error(token, msg) { + croak(msg, token.line, token.col); + }; + + function unexpected(token) { + if (token == null) + token = S.token; + token_error(token, "Unexpected token: " + token.type + " (" + token.value + ")"); + }; + + function expect_token(type, val) { + if (is(type, val)) { + return next(); + } + token_error(S.token, "Unexpected token " + S.token.type + ", expected " + type); + }; + + function expect(punc) { return expect_token("punc", punc); }; + + function can_insert_semicolon() { + return !exigent_mode && ( + S.token.nlb || is("eof") || is("punc", "}") + ); + }; + + function semicolon() { + if (is("punc", ";")) next(); + else if (!can_insert_semicolon()) unexpected(); + }; + + function as() { + return slice(arguments); + }; + + function parenthesised() { + expect("("); + var ex = expression(); + expect(")"); + return ex; + }; + + function add_tokens(str, start, end) { + return str instanceof NodeWithToken ? str : new NodeWithToken(str, start, end); + }; + + function maybe_embed_tokens(parser) { + if (embed_tokens) return function() { + var start = S.token; + var ast = parser.apply(this, arguments); + ast[0] = add_tokens(ast[0], start, prev()); + return ast; + }; + else return parser; + }; + + var statement = maybe_embed_tokens(function() { + if (is("operator", "/")) { + S.peeked = null; + S.token = S.input(true); // force regexp + } + switch (S.token.type) { + case "num": + case "string": + case "regexp": + case "operator": + case "atom": + return simple_statement(); + + case "name": + return is_token(peek(), "punc", ":") + ? labeled_statement(prog1(S.token.value, next, next)) + : simple_statement(); + + case "punc": + switch (S.token.value) { + case "{": + return as("block", block_()); + case "[": + case "(": + return simple_statement(); + case ";": + next(); + return as("block"); + default: + unexpected(); + } + + case "keyword": + switch (prog1(S.token.value, next)) { + case "break": + return break_cont("break"); + + case "continue": + return break_cont("continue"); + + case "debugger": + semicolon(); + return as("debugger"); + + case "do": + return (function(body){ + expect_token("keyword", "while"); + return as("do", prog1(parenthesised, semicolon), body); + })(in_loop(statement)); + + case "for": + return for_(); + + case "function": + return function_(true); + + case "if": + return if_(); + + case "return": + if (S.in_function == 0) + croak("'return' outside of function"); + return as("return", + is("punc", ";") + ? (next(), null) + : can_insert_semicolon() + ? null + : prog1(expression, semicolon)); + + case "switch": + return as("switch", parenthesised(), switch_block_()); + + case "throw": + return as("throw", prog1(expression, semicolon)); + + case "try": + return try_(); + + case "var": + return prog1(var_, semicolon); + + case "const": + return prog1(const_, semicolon); + + case "while": + return as("while", parenthesised(), in_loop(statement)); + + case "with": + return as("with", parenthesised(), statement()); + + default: + unexpected(); + } + } + }); + + function labeled_statement(label) { + S.labels.push(label); + var start = S.token, stat = statement(); + if (exigent_mode && !HOP(STATEMENTS_WITH_LABELS, stat[0])) + unexpected(start); + S.labels.pop(); + return as("label", label, stat); + }; + + function simple_statement() { + return as("stat", prog1(expression, semicolon)); + }; + + function break_cont(type) { + var name; + if (!can_insert_semicolon()) { + name = is("name") ? S.token.value : null; + } + if (name != null) { + next(); + if (!member(name, S.labels)) + croak("Label " + name + " without matching loop or statement"); + } + else if (S.in_loop == 0) + croak(type + " not inside a loop or switch"); + semicolon(); + return as(type, name); + }; + + function for_() { + expect("("); + var init = null; + if (!is("punc", ";")) { + init = is("keyword", "var") + ? (next(), var_(true)) + : expression(true, true); + if (is("operator", "in")) + return for_in(init); + } + return regular_for(init); + }; + + function regular_for(init) { + expect(";"); + var test = is("punc", ";") ? null : expression(); + expect(";"); + var step = is("punc", ")") ? null : expression(); + expect(")"); + return as("for", init, test, step, in_loop(statement)); + }; + + function for_in(init) { + var lhs = init[0] == "var" ? as("name", init[1][0]) : init; + next(); + var obj = expression(); + expect(")"); + return as("for-in", init, lhs, obj, in_loop(statement)); + }; + + var function_ = maybe_embed_tokens(function(in_statement) { + var name = is("name") ? prog1(S.token.value, next) : null; + if (in_statement && !name) + unexpected(); + expect("("); + return as(in_statement ? "defun" : "function", + name, + // arguments + (function(first, a){ + while (!is("punc", ")")) { + if (first) first = false; else expect(","); + if (!is("name")) unexpected(); + a.push(S.token.value); + next(); + } + next(); + return a; + })(true, []), + // body + (function(){ + ++S.in_function; + var loop = S.in_loop; + S.in_loop = 0; + var a = block_(); + --S.in_function; + S.in_loop = loop; + return a; + })()); + }); + + function if_() { + var cond = parenthesised(), body = statement(), belse; + if (is("keyword", "else")) { + next(); + belse = statement(); + } + return as("if", cond, body, belse); + }; + + function block_() { + expect("{"); + var a = []; + while (!is("punc", "}")) { + if (is("eof")) unexpected(); + a.push(statement()); + } + next(); + return a; + }; + + var switch_block_ = curry(in_loop, function(){ + expect("{"); + var a = [], cur = null; + while (!is("punc", "}")) { + if (is("eof")) unexpected(); + if (is("keyword", "case")) { + next(); + cur = []; + a.push([ expression(), cur ]); + expect(":"); + } + else if (is("keyword", "default")) { + next(); + expect(":"); + cur = []; + a.push([ null, cur ]); + } + else { + if (!cur) unexpected(); + cur.push(statement()); + } + } + next(); + return a; + }); + + function try_() { + var body = block_(), bcatch, bfinally; + if (is("keyword", "catch")) { + next(); + expect("("); + if (!is("name")) + croak("Name expected"); + var name = S.token.value; + next(); + expect(")"); + bcatch = [ name, block_() ]; + } + if (is("keyword", "finally")) { + next(); + bfinally = block_(); + } + if (!bcatch && !bfinally) + croak("Missing catch/finally blocks"); + return as("try", body, bcatch, bfinally); + }; + + function vardefs(no_in) { + var a = []; + for (;;) { + if (!is("name")) + unexpected(); + var name = S.token.value; + next(); + if (is("operator", "=")) { + next(); + a.push([ name, expression(false, no_in) ]); + } else { + a.push([ name ]); + } + if (!is("punc", ",")) + break; + next(); + } + return a; + }; + + function var_(no_in) { + return as("var", vardefs(no_in)); + }; + + function const_() { + return as("const", vardefs()); + }; + + function new_() { + var newexp = expr_atom(false), args; + if (is("punc", "(")) { + next(); + args = expr_list(")"); + } else { + args = []; + } + return subscripts(as("new", newexp, args), true); + }; + + var expr_atom = maybe_embed_tokens(function(allow_calls) { + if (is("operator", "new")) { + next(); + return new_(); + } + if (is("operator") && HOP(UNARY_PREFIX, S.token.value)) { + return make_unary("unary-prefix", + prog1(S.token.value, next), + expr_atom(allow_calls)); + } + if (is("punc")) { + switch (S.token.value) { + case "(": + next(); + return subscripts(prog1(expression, curry(expect, ")")), allow_calls); + case "[": + next(); + return subscripts(array_(), allow_calls); + case "{": + next(); + return subscripts(object_(), allow_calls); + } + unexpected(); + } + if (is("keyword", "function")) { + next(); + return subscripts(function_(false), allow_calls); + } + if (HOP(ATOMIC_START_TOKEN, S.token.type)) { + var atom = S.token.type == "regexp" + ? as("regexp", S.token.value[0], S.token.value[1]) + : as(S.token.type, S.token.value); + return subscripts(prog1(atom, next), allow_calls); + } + unexpected(); + }); + + function expr_list(closing, allow_trailing_comma, allow_empty) { + var first = true, a = []; + while (!is("punc", closing)) { + if (first) first = false; else expect(","); + if (allow_trailing_comma && is("punc", closing)) break; + if (is("punc", ",") && allow_empty) { + a.push([ "atom", "undefined" ]); + } else { + a.push(expression(false)); + } + } + next(); + return a; + }; + + function array_() { + return as("array", expr_list("]", !exigent_mode, true)); + }; + + function object_() { + var first = true, a = []; + while (!is("punc", "}")) { + if (first) first = false; else expect(","); + if (!exigent_mode && is("punc", "}")) + // allow trailing comma + break; + var type = S.token.type; + var name = as_property_name(); + if (type == "name" && (name == "get" || name == "set") && !is("punc", ":")) { + a.push([ as_name(), function_(false), name ]); + } else { + expect(":"); + a.push([ name, expression(false) ]); + } + } + next(); + return as("object", a); + }; + + function as_property_name() { + switch (S.token.type) { + case "num": + case "string": + return prog1(S.token.value, next); + } + return as_name(); + }; + + function as_name() { + switch (S.token.type) { + case "name": + case "operator": + case "keyword": + case "atom": + return prog1(S.token.value, next); + default: + unexpected(); + } + }; + + function subscripts(expr, allow_calls) { + if (is("punc", ".")) { + next(); + return subscripts(as("dot", expr, as_name()), allow_calls); + } + if (is("punc", "[")) { + next(); + return subscripts(as("sub", expr, prog1(expression, curry(expect, "]"))), allow_calls); + } + if (allow_calls && is("punc", "(")) { + next(); + return subscripts(as("call", expr, expr_list(")")), true); + } + if (allow_calls && is("operator") && HOP(UNARY_POSTFIX, S.token.value)) { + return prog1(curry(make_unary, "unary-postfix", S.token.value, expr), + next); + } + return expr; + }; + + function make_unary(tag, op, expr) { + if ((op == "++" || op == "--") && !is_assignable(expr)) + croak("Invalid use of " + op + " operator"); + return as(tag, op, expr); + }; + + function expr_op(left, min_prec, no_in) { + var op = is("operator") ? S.token.value : null; + if (op && op == "in" && no_in) op = null; + var prec = op != null ? PRECEDENCE[op] : null; + if (prec != null && prec > min_prec) { + next(); + var right = expr_op(expr_atom(true), prec, no_in); + return expr_op(as("binary", op, left, right), min_prec, no_in); + } + return left; + }; + + function expr_ops(no_in) { + return expr_op(expr_atom(true), 0, no_in); + }; + + function maybe_conditional(no_in) { + var expr = expr_ops(no_in); + if (is("operator", "?")) { + next(); + var yes = expression(false); + expect(":"); + return as("conditional", expr, yes, expression(false, no_in)); + } + return expr; + }; + + function is_assignable(expr) { + if (!exigent_mode) return true; + switch (expr[0]) { + case "dot": + case "sub": + case "new": + case "call": + return true; + case "name": + return expr[1] != "this"; + } + }; + + function maybe_assign(no_in) { + var left = maybe_conditional(no_in), val = S.token.value; + if (is("operator") && HOP(ASSIGNMENT, val)) { + if (is_assignable(left)) { + next(); + return as("assign", ASSIGNMENT[val], left, maybe_assign(no_in)); + } + croak("Invalid assignment"); + } + return left; + }; + + var expression = maybe_embed_tokens(function(commas, no_in) { + if (arguments.length == 0) + commas = true; + var expr = maybe_assign(no_in); + if (commas && is("punc", ",")) { + next(); + return as("seq", expr, expression(true, no_in)); + } + return expr; + }); + + function in_loop(cont) { + try { + ++S.in_loop; + return cont(); + } finally { + --S.in_loop; + } + }; + + return as("toplevel", (function(a){ + while (!is("eof")) + a.push(statement()); + return a; + })([])); + +}; + +/* -----[ Utilities ]----- */ + +function curry(f) { + var args = slice(arguments, 1); + return function() { return f.apply(this, args.concat(slice(arguments))); }; +}; + +function prog1(ret) { + if (ret instanceof Function) + ret = ret(); + for (var i = 1, n = arguments.length; --n > 0; ++i) + arguments[i](); + return ret; +}; + +function array_to_hash(a) { + var ret = {}; + for (var i = 0; i < a.length; ++i) + ret[a[i]] = true; + return ret; +}; + +function slice(a, start) { + return Array.prototype.slice.call(a, start == null ? 0 : start); +}; + +function characters(str) { + return str.split(""); +}; + +function member(name, array) { + for (var i = array.length; --i >= 0;) + if (array[i] === name) + return true; + return false; +}; + +function HOP(obj, prop) { + return Object.prototype.hasOwnProperty.call(obj, prop); +}; + +var warn = function() {}; + +/* -----[ Exports ]----- */ + +exports.tokenizer = tokenizer; +exports.parse = parse; +exports.slice = slice; +exports.curry = curry; +exports.member = member; +exports.array_to_hash = array_to_hash; +exports.PRECEDENCE = PRECEDENCE; +exports.KEYWORDS_ATOM = KEYWORDS_ATOM; +exports.RESERVED_WORDS = RESERVED_WORDS; +exports.KEYWORDS = KEYWORDS; +exports.ATOMIC_START_TOKEN = ATOMIC_START_TOKEN; +exports.OPERATORS = OPERATORS; +exports.is_alphanumeric_char = is_alphanumeric_char; +exports.set_logger = function(logger) { + warn = logger; +}; +; + }).call(module.exports); + + __require.modules["/node_modules/burrito/node_modules/uglify-js/lib/parse-js.js"]._cached = module.exports; + return module.exports; +}; + +require.modules["/node_modules/burrito/node_modules/uglify-js/lib/process.js"] = function () { + var module = { exports : {} }; + var exports = module.exports; + var __dirname = "/node_modules/burrito/node_modules/uglify-js/lib"; + var __filename = "/node_modules/burrito/node_modules/uglify-js/lib/process.js"; + + var require = function (file) { + return __require(file, "/node_modules/burrito/node_modules/uglify-js/lib"); + }; + + require.resolve = function (file) { + return __require.resolve(name, "/node_modules/burrito/node_modules/uglify-js/lib"); + }; + + require.modules = __require.modules; + __require.modules["/node_modules/burrito/node_modules/uglify-js/lib/process.js"]._cached = module.exports; + + (function () { + /*********************************************************************** + + A JavaScript tokenizer / parser / beautifier / compressor. + + This version is suitable for Node.js. With minimal changes (the + exports stuff) it should work on any JS platform. + + This file implements some AST processors. They work on data built + by parse-js. + + Exported functions: + + - ast_mangle(ast, options) -- mangles the variable/function names + in the AST. Returns an AST. + + - ast_squeeze(ast) -- employs various optimizations to make the + final generated code even smaller. Returns an AST. + + - gen_code(ast, options) -- generates JS code from the AST. Pass + true (or an object, see the code for some options) as second + argument to get "pretty" (indented) code. + + -------------------------------- (C) --------------------------------- + + Author: Mihai Bazon + + http://mihai.bazon.net/blog + + Distributed under the BSD license: + + Copyright 2010 (c) Mihai Bazon + + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + + * Redistributions of source code must retain the above + copyright notice, this list of conditions and the following + disclaimer. + + * Redistributions in binary form must reproduce the above + copyright notice, this list of conditions and the following + disclaimer in the documentation and/or other materials + provided with the distribution. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER “AS IS” AND ANY + EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR + PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER BE + LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, + OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, + PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR + PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR + TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF + THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + SUCH DAMAGE. + + ***********************************************************************/ + +var jsp = require("./parse-js"), + slice = jsp.slice, + member = jsp.member, + PRECEDENCE = jsp.PRECEDENCE, + OPERATORS = jsp.OPERATORS; + +/* -----[ helper for AST traversal ]----- */ + +function ast_walker(ast) { + function _vardefs(defs) { + return [ this[0], MAP(defs, function(def){ + var a = [ def[0] ]; + if (def.length > 1) + a[1] = walk(def[1]); + return a; + }) ]; + }; + function _block(statements) { + var out = [ this[0] ]; + if (statements != null) + out.push(MAP(statements, walk)); + return out; + }; + var walkers = { + "string": function(str) { + return [ this[0], str ]; + }, + "num": function(num) { + return [ this[0], num ]; + }, + "name": function(name) { + return [ this[0], name ]; + }, + "toplevel": function(statements) { + return [ this[0], MAP(statements, walk) ]; + }, + "block": _block, + "splice": _block, + "var": _vardefs, + "const": _vardefs, + "try": function(t, c, f) { + return [ + this[0], + MAP(t, walk), + c != null ? [ c[0], MAP(c[1], walk) ] : null, + f != null ? MAP(f, walk) : null + ]; + }, + "throw": function(expr) { + return [ this[0], walk(expr) ]; + }, + "new": function(ctor, args) { + return [ this[0], walk(ctor), MAP(args, walk) ]; + }, + "switch": function(expr, body) { + return [ this[0], walk(expr), MAP(body, function(branch){ + return [ branch[0] ? walk(branch[0]) : null, + MAP(branch[1], walk) ]; + }) ]; + }, + "break": function(label) { + return [ this[0], label ]; + }, + "continue": function(label) { + return [ this[0], label ]; + }, + "conditional": function(cond, t, e) { + return [ this[0], walk(cond), walk(t), walk(e) ]; + }, + "assign": function(op, lvalue, rvalue) { + return [ this[0], op, walk(lvalue), walk(rvalue) ]; + }, + "dot": function(expr) { + return [ this[0], walk(expr) ].concat(slice(arguments, 1)); + }, + "call": function(expr, args) { + return [ this[0], walk(expr), MAP(args, walk) ]; + }, + "function": function(name, args, body) { + return [ this[0], name, args.slice(), MAP(body, walk) ]; + }, + "defun": function(name, args, body) { + return [ this[0], name, args.slice(), MAP(body, walk) ]; + }, + "if": function(conditional, t, e) { + return [ this[0], walk(conditional), walk(t), walk(e) ]; + }, + "for": function(init, cond, step, block) { + return [ this[0], walk(init), walk(cond), walk(step), walk(block) ]; + }, + "for-in": function(vvar, key, hash, block) { + return [ this[0], walk(vvar), walk(key), walk(hash), walk(block) ]; + }, + "while": function(cond, block) { + return [ this[0], walk(cond), walk(block) ]; + }, + "do": function(cond, block) { + return [ this[0], walk(cond), walk(block) ]; + }, + "return": function(expr) { + return [ this[0], walk(expr) ]; + }, + "binary": function(op, left, right) { + return [ this[0], op, walk(left), walk(right) ]; + }, + "unary-prefix": function(op, expr) { + return [ this[0], op, walk(expr) ]; + }, + "unary-postfix": function(op, expr) { + return [ this[0], op, walk(expr) ]; + }, + "sub": function(expr, subscript) { + return [ this[0], walk(expr), walk(subscript) ]; + }, + "object": function(props) { + return [ this[0], MAP(props, function(p){ + return p.length == 2 + ? [ p[0], walk(p[1]) ] + : [ p[0], walk(p[1]), p[2] ]; // get/set-ter + }) ]; + }, + "regexp": function(rx, mods) { + return [ this[0], rx, mods ]; + }, + "array": function(elements) { + return [ this[0], MAP(elements, walk) ]; + }, + "stat": function(stat) { + return [ this[0], walk(stat) ]; + }, + "seq": function() { + return [ this[0] ].concat(MAP(slice(arguments), walk)); + }, + "label": function(name, block) { + return [ this[0], name, walk(block) ]; + }, + "with": function(expr, block) { + return [ this[0], walk(expr), walk(block) ]; + }, + "atom": function(name) { + return [ this[0], name ]; + } + }; + + var user = {}; + var stack = []; + function walk(ast) { + if (ast == null) + return null; + try { + stack.push(ast); + var type = ast[0]; + var gen = user[type]; + if (gen) { + var ret = gen.apply(ast, ast.slice(1)); + if (ret != null) + return ret; + } + gen = walkers[type]; + return gen.apply(ast, ast.slice(1)); + } finally { + stack.pop(); + } + }; + + function with_walkers(walkers, cont){ + var save = {}, i; + for (i in walkers) if (HOP(walkers, i)) { + save[i] = user[i]; + user[i] = walkers[i]; + } + var ret = cont(); + for (i in save) if (HOP(save, i)) { + if (!save[i]) delete user[i]; + else user[i] = save[i]; + } + return ret; + }; + + return { + walk: walk, + with_walkers: with_walkers, + parent: function() { + return stack[stack.length - 2]; // last one is current node + }, + stack: function() { + return stack; + } + }; +}; + +/* -----[ Scope and mangling ]----- */ + +function Scope(parent) { + this.names = {}; // names defined in this scope + this.mangled = {}; // mangled names (orig.name => mangled) + this.rev_mangled = {}; // reverse lookup (mangled => orig.name) + this.cname = -1; // current mangled name + this.refs = {}; // names referenced from this scope + this.uses_with = false; // will become TRUE if with() is detected in this or any subscopes + this.uses_eval = false; // will become TRUE if eval() is detected in this or any subscopes + this.parent = parent; // parent scope + this.children = []; // sub-scopes + if (parent) { + this.level = parent.level + 1; + parent.children.push(this); + } else { + this.level = 0; + } +}; + +var base54 = (function(){ + var DIGITS = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ$_"; + return function(num) { + var ret = ""; + do { + ret = DIGITS.charAt(num % 54) + ret; + num = Math.floor(num / 54); + } while (num > 0); + return ret; + }; +})(); + +Scope.prototype = { + has: function(name) { + for (var s = this; s; s = s.parent) + if (HOP(s.names, name)) + return s; + }, + has_mangled: function(mname) { + for (var s = this; s; s = s.parent) + if (HOP(s.rev_mangled, mname)) + return s; + }, + toJSON: function() { + return { + names: this.names, + uses_eval: this.uses_eval, + uses_with: this.uses_with + }; + }, + + next_mangled: function() { + // we must be careful that the new mangled name: + // + // 1. doesn't shadow a mangled name from a parent + // scope, unless we don't reference the original + // name from this scope OR from any sub-scopes! + // This will get slow. + // + // 2. doesn't shadow an original name from a parent + // scope, in the event that the name is not mangled + // in the parent scope and we reference that name + // here OR IN ANY SUBSCOPES! + // + // 3. doesn't shadow a name that is referenced but not + // defined (possibly global defined elsewhere). + for (;;) { + var m = base54(++this.cname), prior; + + // case 1. + prior = this.has_mangled(m); + if (prior && this.refs[prior.rev_mangled[m]] === prior) + continue; + + // case 2. + prior = this.has(m); + if (prior && prior !== this && this.refs[m] === prior && !prior.has_mangled(m)) + continue; + + // case 3. + if (HOP(this.refs, m) && this.refs[m] == null) + continue; + + // I got "do" once. :-/ + if (!is_identifier(m)) + continue; + + return m; + } + }, + set_mangle: function(name, m) { + this.rev_mangled[m] = name; + return this.mangled[name] = m; + }, + get_mangled: function(name, newMangle) { + if (this.uses_eval || this.uses_with) return name; // no mangle if eval or with is in use + var s = this.has(name); + if (!s) return name; // not in visible scope, no mangle + if (HOP(s.mangled, name)) return s.mangled[name]; // already mangled in this scope + if (!newMangle) return name; // not found and no mangling requested + return s.set_mangle(name, s.next_mangled()); + }, + define: function(name) { + if (name != null) + return this.names[name] = name; + } +}; + +function ast_add_scope(ast) { + + var current_scope = null; + var w = ast_walker(), walk = w.walk; + var having_eval = []; + + function with_new_scope(cont) { + current_scope = new Scope(current_scope); + var ret = current_scope.body = cont(); + ret.scope = current_scope; + current_scope = current_scope.parent; + return ret; + }; + + function define(name) { + return current_scope.define(name); + }; + + function reference(name) { + current_scope.refs[name] = true; + }; + + function _lambda(name, args, body) { + var is_defun = this[0] == "defun"; + return [ this[0], is_defun ? define(name) : name, args, with_new_scope(function(){ + if (!is_defun) define(name); + MAP(args, define); + return MAP(body, walk); + })]; + }; + + return with_new_scope(function(){ + // process AST + var ret = w.with_walkers({ + "function": _lambda, + "defun": _lambda, + "with": function(expr, block) { + for (var s = current_scope; s; s = s.parent) + s.uses_with = true; + }, + "var": function(defs) { + MAP(defs, function(d){ define(d[0]) }); + }, + "const": function(defs) { + MAP(defs, function(d){ define(d[0]) }); + }, + "try": function(t, c, f) { + if (c != null) return [ + this[0], + MAP(t, walk), + [ define(c[0]), MAP(c[1], walk) ], + f != null ? MAP(f, walk) : null + ]; + }, + "name": function(name) { + if (name == "eval") + having_eval.push(current_scope); + reference(name); + } + }, function(){ + return walk(ast); + }); + + // the reason why we need an additional pass here is + // that names can be used prior to their definition. + + // scopes where eval was detected and their parents + // are marked with uses_eval, unless they define the + // "eval" name. + MAP(having_eval, function(scope){ + if (!scope.has("eval")) while (scope) { + scope.uses_eval = true; + scope = scope.parent; + } + }); + + // for referenced names it might be useful to know + // their origin scope. current_scope here is the + // toplevel one. + function fixrefs(scope, i) { + // do children first; order shouldn't matter + for (i = scope.children.length; --i >= 0;) + fixrefs(scope.children[i]); + for (i in scope.refs) if (HOP(scope.refs, i)) { + // find origin scope and propagate the reference to origin + for (var origin = scope.has(i), s = scope; s; s = s.parent) { + s.refs[i] = origin; + if (s === origin) break; + } + } + }; + fixrefs(current_scope); + + return ret; + }); + +}; + +/* -----[ mangle names ]----- */ + +function ast_mangle(ast, options) { + var w = ast_walker(), walk = w.walk, scope; + options = options || {}; + + function get_mangled(name, newMangle) { + if (!options.toplevel && !scope.parent) return name; // don't mangle toplevel + if (options.except && member(name, options.except)) + return name; + return scope.get_mangled(name, newMangle); + }; + + function get_define(name) { + if (options.defines) { + // we always lookup a defined symbol for the current scope FIRST, so declared + // vars trump a DEFINE symbol, but if no such var is found, then match a DEFINE value + if (!scope.has(name)) { + if (HOP(options.defines, name)) { + return options.defines[name]; + } + } + return null; + } + }; + + function _lambda(name, args, body) { + var is_defun = this[0] == "defun", extra; + if (name) { + if (is_defun) name = get_mangled(name); + else { + extra = {}; + name = extra[name] = scope.next_mangled(); + } + } + body = with_scope(body.scope, function(){ + args = MAP(args, function(name){ return get_mangled(name) }); + return MAP(body, walk); + }, extra); + return [ this[0], name, args, body ]; + }; + + function with_scope(s, cont, extra) { + var _scope = scope; + scope = s; + if (extra) for (var i in extra) if (HOP(extra, i)) { + s.set_mangle(i, extra[i]); + } + for (var i in s.names) if (HOP(s.names, i)) { + get_mangled(i, true); + } + var ret = cont(); + ret.scope = s; + scope = _scope; + return ret; + }; + + function _vardefs(defs) { + return [ this[0], MAP(defs, function(d){ + return [ get_mangled(d[0]), walk(d[1]) ]; + }) ]; + }; + + return w.with_walkers({ + "function": _lambda, + "defun": function() { + // move function declarations to the top when + // they are not in some block. + var ast = _lambda.apply(this, arguments); + switch (w.parent()[0]) { + case "toplevel": + case "function": + case "defun": + return MAP.at_top(ast); + } + return ast; + }, + "var": _vardefs, + "const": _vardefs, + "name": function(name) { + return get_define(name) || [ this[0], get_mangled(name) ]; + }, + "try": function(t, c, f) { + return [ this[0], + MAP(t, walk), + c != null ? [ get_mangled(c[0]), MAP(c[1], walk) ] : null, + f != null ? MAP(f, walk) : null ]; + }, + "toplevel": function(body) { + var self = this; + return with_scope(self.scope, function(){ + return [ self[0], MAP(body, walk) ]; + }); + } + }, function() { + return walk(ast_add_scope(ast)); + }); +}; + +/* -----[ + - compress foo["bar"] into foo.bar, + - remove block brackets {} where possible + - join consecutive var declarations + - various optimizations for IFs: + - if (cond) foo(); else bar(); ==> cond?foo():bar(); + - if (cond) foo(); ==> cond&&foo(); + - if (foo) return bar(); else return baz(); ==> return foo?bar():baz(); // also for throw + - if (foo) return bar(); else something(); ==> {if(foo)return bar();something()} + ]----- */ + +var warn = function(){}; + +function best_of(ast1, ast2) { + return gen_code(ast1).length > gen_code(ast2[0] == "stat" ? ast2[1] : ast2).length ? ast2 : ast1; +}; + +function last_stat(b) { + if (b[0] == "block" && b[1] && b[1].length > 0) + return b[1][b[1].length - 1]; + return b; +} + +function aborts(t) { + if (t) { + t = last_stat(t); + if (t[0] == "return" || t[0] == "break" || t[0] == "continue" || t[0] == "throw") + return true; + } +}; + +function boolean_expr(expr) { + return ( (expr[0] == "unary-prefix" + && member(expr[1], [ "!", "delete" ])) || + + (expr[0] == "binary" + && member(expr[1], [ "in", "instanceof", "==", "!=", "===", "!==", "<", "<=", ">=", ">" ])) || + + (expr[0] == "binary" + && member(expr[1], [ "&&", "||" ]) + && boolean_expr(expr[2]) + && boolean_expr(expr[3])) || + + (expr[0] == "conditional" + && boolean_expr(expr[2]) + && boolean_expr(expr[3])) || + + (expr[0] == "assign" + && expr[1] === true + && boolean_expr(expr[3])) || + + (expr[0] == "seq" + && boolean_expr(expr[expr.length - 1])) + ); +}; + +function make_conditional(c, t, e) { + var make_real_conditional = function() { + if (c[0] == "unary-prefix" && c[1] == "!") { + return e ? [ "conditional", c[2], e, t ] : [ "binary", "||", c[2], t ]; + } else { + return e ? [ "conditional", c, t, e ] : [ "binary", "&&", c, t ]; + } + }; + // shortcut the conditional if the expression has a constant value + return when_constant(c, function(ast, val){ + warn_unreachable(val ? e : t); + return (val ? t : e); + }, make_real_conditional); +}; + +function empty(b) { + return !b || (b[0] == "block" && (!b[1] || b[1].length == 0)); +}; + +function is_string(node) { + return (node[0] == "string" || + node[0] == "unary-prefix" && node[1] == "typeof" || + node[0] == "binary" && node[1] == "+" && + (is_string(node[2]) || is_string(node[3]))); +}; + +var when_constant = (function(){ + + var $NOT_CONSTANT = {}; + + // this can only evaluate constant expressions. If it finds anything + // not constant, it throws $NOT_CONSTANT. + function evaluate(expr) { + switch (expr[0]) { + case "string": + case "num": + return expr[1]; + case "name": + case "atom": + switch (expr[1]) { + case "true": return true; + case "false": return false; + } + break; + case "unary-prefix": + switch (expr[1]) { + case "!": return !evaluate(expr[2]); + case "typeof": return typeof evaluate(expr[2]); + case "~": return ~evaluate(expr[2]); + case "-": return -evaluate(expr[2]); + case "+": return +evaluate(expr[2]); + } + break; + case "binary": + var left = expr[2], right = expr[3]; + switch (expr[1]) { + case "&&" : return evaluate(left) && evaluate(right); + case "||" : return evaluate(left) || evaluate(right); + case "|" : return evaluate(left) | evaluate(right); + case "&" : return evaluate(left) & evaluate(right); + case "^" : return evaluate(left) ^ evaluate(right); + case "+" : return evaluate(left) + evaluate(right); + case "*" : return evaluate(left) * evaluate(right); + case "/" : return evaluate(left) / evaluate(right); + case "-" : return evaluate(left) - evaluate(right); + case "<<" : return evaluate(left) << evaluate(right); + case ">>" : return evaluate(left) >> evaluate(right); + case ">>>" : return evaluate(left) >>> evaluate(right); + case "==" : return evaluate(left) == evaluate(right); + case "===" : return evaluate(left) === evaluate(right); + case "!=" : return evaluate(left) != evaluate(right); + case "!==" : return evaluate(left) !== evaluate(right); + case "<" : return evaluate(left) < evaluate(right); + case "<=" : return evaluate(left) <= evaluate(right); + case ">" : return evaluate(left) > evaluate(right); + case ">=" : return evaluate(left) >= evaluate(right); + case "in" : return evaluate(left) in evaluate(right); + case "instanceof" : return evaluate(left) instanceof evaluate(right); + } + } + throw $NOT_CONSTANT; + }; + + return function(expr, yes, no) { + try { + var val = evaluate(expr), ast; + switch (typeof val) { + case "string": ast = [ "string", val ]; break; + case "number": ast = [ "num", val ]; break; + case "boolean": ast = [ "name", String(val) ]; break; + default: throw new Error("Can't handle constant of type: " + (typeof val)); + } + return yes.call(expr, ast, val); + } catch(ex) { + if (ex === $NOT_CONSTANT) { + if (expr[0] == "binary" + && (expr[1] == "===" || expr[1] == "!==") + && ((is_string(expr[2]) && is_string(expr[3])) + || (boolean_expr(expr[2]) && boolean_expr(expr[3])))) { + expr[1] = expr[1].substr(0, 2); + } + else if (no && expr[0] == "binary" + && (expr[1] == "||" || expr[1] == "&&")) { + // the whole expression is not constant but the lval may be... + try { + var lval = evaluate(expr[2]); + expr = ((expr[1] == "&&" && (lval ? expr[3] : lval)) || + (expr[1] == "||" && (lval ? lval : expr[3])) || + expr); + } catch(ex2) { + // IGNORE... lval is not constant + } + } + return no ? no.call(expr, expr) : null; + } + else throw ex; + } + }; + +})(); + +function warn_unreachable(ast) { + if (!empty(ast)) + warn("Dropping unreachable code: " + gen_code(ast, true)); +}; + +function prepare_ifs(ast) { + var w = ast_walker(), walk = w.walk; + // In this first pass, we rewrite ifs which abort with no else with an + // if-else. For example: + // + // if (x) { + // blah(); + // return y; + // } + // foobar(); + // + // is rewritten into: + // + // if (x) { + // blah(); + // return y; + // } else { + // foobar(); + // } + function redo_if(statements) { + statements = MAP(statements, walk); + + for (var i = 0; i < statements.length; ++i) { + var fi = statements[i]; + if (fi[0] != "if") continue; + + if (fi[3] && walk(fi[3])) continue; + + var t = walk(fi[2]); + if (!aborts(t)) continue; + + var conditional = walk(fi[1]); + + var e_body = statements.slice(i + 1); + var e; + if (e_body.length == 1) e = e_body[0]; + else e = [ "block", e_body ]; + + var ret = statements.slice(0, i).concat([ [ + fi[0], // "if" + conditional, // conditional + t, // then + e // else + ] ]); + + return redo_if(ret); + } + + return statements; + }; + + function redo_if_lambda(name, args, body) { + body = redo_if(body); + return [ this[0], name, args.slice(), body ]; + }; + + function redo_if_block(statements) { + var out = [ this[0] ]; + if (statements != null) + out.push(redo_if(statements)); + return out; + }; + + return w.with_walkers({ + "defun": redo_if_lambda, + "function": redo_if_lambda, + "block": redo_if_block, + "splice": redo_if_block, + "toplevel": function(statements) { + return [ this[0], redo_if(statements) ]; + }, + "try": function(t, c, f) { + return [ + this[0], + redo_if(t), + c != null ? [ c[0], redo_if(c[1]) ] : null, + f != null ? redo_if(f) : null + ]; + }, + "with": function(expr, block) { + return [ this[0], walk(expr), redo_if(block) ]; + } + }, function() { + return walk(ast); + }); +}; + +function ast_squeeze(ast, options) { + options = defaults(options, { + make_seqs : true, + dead_code : true, + keep_comps : true, + no_warnings : false + }); + + var w = ast_walker(), walk = w.walk, scope; + + function negate(c) { + var not_c = [ "unary-prefix", "!", c ]; + switch (c[0]) { + case "unary-prefix": + return c[1] == "!" && boolean_expr(c[2]) ? c[2] : not_c; + case "seq": + c = slice(c); + c[c.length - 1] = negate(c[c.length - 1]); + return c; + case "conditional": + return best_of(not_c, [ "conditional", c[1], negate(c[2]), negate(c[3]) ]); + case "binary": + var op = c[1], left = c[2], right = c[3]; + if (!options.keep_comps) switch (op) { + case "<=" : return [ "binary", ">", left, right ]; + case "<" : return [ "binary", ">=", left, right ]; + case ">=" : return [ "binary", "<", left, right ]; + case ">" : return [ "binary", "<=", left, right ]; + } + switch (op) { + case "==" : return [ "binary", "!=", left, right ]; + case "!=" : return [ "binary", "==", left, right ]; + case "===" : return [ "binary", "!==", left, right ]; + case "!==" : return [ "binary", "===", left, right ]; + case "&&" : return best_of(not_c, [ "binary", "||", negate(left), negate(right) ]); + case "||" : return best_of(not_c, [ "binary", "&&", negate(left), negate(right) ]); + } + break; + } + return not_c; + }; + + function with_scope(s, cont) { + var _scope = scope; + scope = s; + var ret = cont(); + ret.scope = s; + scope = _scope; + return ret; + }; + + function rmblock(block) { + if (block != null && block[0] == "block" && block[1]) { + if (block[1].length == 1) + block = block[1][0]; + else if (block[1].length == 0) + block = [ "block" ]; + } + return block; + }; + + function _lambda(name, args, body) { + var is_defun = this[0] == "defun"; + body = with_scope(body.scope, function(){ + var ret = tighten(MAP(body, walk), "lambda"); + if (!is_defun && name && !HOP(scope.refs, name)) + name = null; + return ret; + }); + return [ this[0], name, args, body ]; + }; + + // we get here for blocks that have been already transformed. + // this function does a few things: + // 1. discard useless blocks + // 2. join consecutive var declarations + // 3. remove obviously dead code + // 4. transform consecutive statements using the comma operator + // 5. if block_type == "lambda" and it detects constructs like if(foo) return ... - rewrite like if (!foo) { ... } + function tighten(statements, block_type) { + statements = statements.reduce(function(a, stat){ + if (stat[0] == "block") { + if (stat[1]) { + a.push.apply(a, stat[1]); + } + } else { + a.push(stat); + } + return a; + }, []); + + statements = (function(a, prev){ + statements.forEach(function(cur){ + if (prev && ((cur[0] == "var" && prev[0] == "var") || + (cur[0] == "const" && prev[0] == "const"))) { + prev[1] = prev[1].concat(cur[1]); + } else { + a.push(cur); + prev = cur; + } + }); + return a; + })([]); + + if (options.dead_code) statements = (function(a, has_quit){ + statements.forEach(function(st){ + if (has_quit) { + if (member(st[0], [ "function", "defun" , "var", "const" ])) { + a.push(st); + } + else if (!options.no_warnings) + warn_unreachable(st); + } + else { + a.push(st); + if (member(st[0], [ "return", "throw", "break", "continue" ])) + has_quit = true; + } + }); + return a; + })([]); + + if (options.make_seqs) statements = (function(a, prev) { + statements.forEach(function(cur){ + if (prev && prev[0] == "stat" && cur[0] == "stat") { + prev[1] = [ "seq", prev[1], cur[1] ]; + } else { + a.push(cur); + prev = cur; + } + }); + return a; + })([]); + + if (block_type == "lambda") statements = (function(i, a, stat){ + while (i < statements.length) { + stat = statements[i++]; + if (stat[0] == "if" && !stat[3]) { + if (stat[2][0] == "return" && stat[2][1] == null) { + a.push(make_if(negate(stat[1]), [ "block", statements.slice(i) ])); + break; + } + var last = last_stat(stat[2]); + if (last[0] == "return" && last[1] == null) { + a.push(make_if(stat[1], [ "block", stat[2][1].slice(0, -1) ], [ "block", statements.slice(i) ])); + break; + } + } + a.push(stat); + } + return a; + })(0, []); + + return statements; + }; + + function make_if(c, t, e) { + return when_constant(c, function(ast, val){ + if (val) { + warn_unreachable(e); + return t; + } else { + warn_unreachable(t); + return e; + } + }, function() { + return make_real_if(c, t, e); + }); + }; + + function make_real_if(c, t, e) { + c = walk(c); + t = walk(t); + e = walk(e); + + if (empty(t)) { + c = negate(c); + t = e; + e = null; + } else if (empty(e)) { + e = null; + } else { + // if we have both else and then, maybe it makes sense to switch them? + (function(){ + var a = gen_code(c); + var n = negate(c); + var b = gen_code(n); + if (b.length < a.length) { + var tmp = t; + t = e; + e = tmp; + c = n; + } + })(); + } + if (empty(e) && empty(t)) + return [ "stat", c ]; + var ret = [ "if", c, t, e ]; + if (t[0] == "if" && empty(t[3]) && empty(e)) { + ret = best_of(ret, walk([ "if", [ "binary", "&&", c, t[1] ], t[2] ])); + } + else if (t[0] == "stat") { + if (e) { + if (e[0] == "stat") { + ret = best_of(ret, [ "stat", make_conditional(c, t[1], e[1]) ]); + } + } + else { + ret = best_of(ret, [ "stat", make_conditional(c, t[1]) ]); + } + } + else if (e && t[0] == e[0] && (t[0] == "return" || t[0] == "throw") && t[1] && e[1]) { + ret = best_of(ret, [ t[0], make_conditional(c, t[1], e[1] ) ]); + } + else if (e && aborts(t)) { + ret = [ [ "if", c, t ] ]; + if (e[0] == "block") { + if (e[1]) ret = ret.concat(e[1]); + } + else { + ret.push(e); + } + ret = walk([ "block", ret ]); + } + else if (t && aborts(e)) { + ret = [ [ "if", negate(c), e ] ]; + if (t[0] == "block") { + if (t[1]) ret = ret.concat(t[1]); + } else { + ret.push(t); + } + ret = walk([ "block", ret ]); + } + return ret; + }; + + function _do_while(cond, body) { + return when_constant(cond, function(cond, val){ + if (!val) { + warn_unreachable(body); + return [ "block" ]; + } else { + return [ "for", null, null, null, walk(body) ]; + } + }); + }; + + ast = prepare_ifs(ast); + ast = ast_add_scope(ast); + + return w.with_walkers({ + "sub": function(expr, subscript) { + if (subscript[0] == "string") { + var name = subscript[1]; + if (is_identifier(name)) + return [ "dot", walk(expr), name ]; + else if (/^[1-9][0-9]*$/.test(name) || name === "0") + return [ "sub", walk(expr), [ "num", parseInt(name, 10) ] ]; + } + }, + "if": make_if, + "toplevel": function(body) { + return [ "toplevel", with_scope(this.scope, function(){ + return tighten(MAP(body, walk)); + }) ]; + }, + "switch": function(expr, body) { + var last = body.length - 1; + return [ "switch", walk(expr), MAP(body, function(branch, i){ + var block = tighten(MAP(branch[1], walk)); + if (i == last && block.length > 0) { + var node = block[block.length - 1]; + if (node[0] == "break" && !node[1]) + block.pop(); + } + return [ branch[0] ? walk(branch[0]) : null, block ]; + }) ]; + }, + "function": _lambda, + "defun": _lambda, + "block": function(body) { + if (body) return rmblock([ "block", tighten(MAP(body, walk)) ]); + }, + "binary": function(op, left, right) { + return when_constant([ "binary", op, walk(left), walk(right) ], function yes(c){ + return best_of(walk(c), this); + }, function no() { + return this; + }); + }, + "conditional": function(c, t, e) { + return make_conditional(walk(c), walk(t), walk(e)); + }, + "try": function(t, c, f) { + return [ + "try", + tighten(MAP(t, walk)), + c != null ? [ c[0], tighten(MAP(c[1], walk)) ] : null, + f != null ? tighten(MAP(f, walk)) : null + ]; + }, + "unary-prefix": function(op, expr) { + expr = walk(expr); + var ret = [ "unary-prefix", op, expr ]; + if (op == "!") + ret = best_of(ret, negate(expr)); + return when_constant(ret, function(ast, val){ + return walk(ast); // it's either true or false, so minifies to !0 or !1 + }, function() { return ret }); + }, + "name": function(name) { + switch (name) { + case "true": return [ "unary-prefix", "!", [ "num", 0 ]]; + case "false": return [ "unary-prefix", "!", [ "num", 1 ]]; + } + }, + "new": function(ctor, args) { + if (ctor[0] == "name" && ctor[1] == "Array" && !scope.has("Array")) { + if (args.length != 1) { + return [ "array", args ]; + } else { + return [ "call", [ "name", "Array" ], args ]; + } + } + }, + "call": function(expr, args) { + if (expr[0] == "name" && expr[1] == "Array" && args.length != 1 && !scope.has("Array")) { + return [ "array", args ]; + } + }, + "while": _do_while + }, function() { + return walk(ast); + }); +}; + +/* -----[ re-generate code from the AST ]----- */ + +var DOT_CALL_NO_PARENS = jsp.array_to_hash([ + "name", + "array", + "object", + "string", + "dot", + "sub", + "call", + "regexp" +]); + +function make_string(str, ascii_only) { + var dq = 0, sq = 0; + str = str.replace(/[\\\b\f\n\r\t\x22\x27\u2028\u2029]/g, function(s){ + switch (s) { + case "\\": return "\\\\"; + case "\b": return "\\b"; + case "\f": return "\\f"; + case "\n": return "\\n"; + case "\r": return "\\r"; + case "\t": return "\\t"; + case "\u2028": return "\\u2028"; + case "\u2029": return "\\u2029"; + case '"': ++dq; return '"'; + case "'": ++sq; return "'"; + } + return s; + }); + if (ascii_only) str = to_ascii(str); + if (dq > sq) return "'" + str.replace(/\x27/g, "\\'") + "'"; + else return '"' + str.replace(/\x22/g, '\\"') + '"'; +}; + +function to_ascii(str) { + return str.replace(/[\u0080-\uffff]/g, function(ch) { + var code = ch.charCodeAt(0).toString(16); + while (code.length < 4) code = "0" + code; + return "\\u" + code; + }); +}; + +var SPLICE_NEEDS_BRACKETS = jsp.array_to_hash([ "if", "while", "do", "for", "for-in", "with" ]); + +function gen_code(ast, options) { + options = defaults(options, { + indent_start : 0, + indent_level : 4, + quote_keys : false, + space_colon : false, + beautify : false, + ascii_only : false + }); + var beautify = !!options.beautify; + var indentation = 0, + newline = beautify ? "\n" : "", + space = beautify ? " " : ""; + + function encode_string(str) { + return make_string(str, options.ascii_only); + }; + + function make_name(name) { + name = name.toString(); + if (options.ascii_only) + name = to_ascii(name); + return name; + }; + + function indent(line) { + if (line == null) + line = ""; + if (beautify) + line = repeat_string(" ", options.indent_start + indentation * options.indent_level) + line; + return line; + }; + + function with_indent(cont, incr) { + if (incr == null) incr = 1; + indentation += incr; + try { return cont.apply(null, slice(arguments, 1)); } + finally { indentation -= incr; } + }; + + function add_spaces(a) { + if (beautify) + return a.join(" "); + var b = []; + for (var i = 0; i < a.length; ++i) { + var next = a[i + 1]; + b.push(a[i]); + if (next && + ((/[a-z0-9_\x24]$/i.test(a[i].toString()) && /^[a-z0-9_\x24]/i.test(next.toString())) || + (/[\+\-]$/.test(a[i].toString()) && /^[\+\-]/.test(next.toString())))) { + b.push(" "); + } + } + return b.join(""); + }; + + function add_commas(a) { + return a.join("," + space); + }; + + function parenthesize(expr) { + var gen = make(expr); + for (var i = 1; i < arguments.length; ++i) { + var el = arguments[i]; + if ((el instanceof Function && el(expr)) || expr[0] == el) + return "(" + gen + ")"; + } + return gen; + }; + + function best_of(a) { + if (a.length == 1) { + return a[0]; + } + if (a.length == 2) { + var b = a[1]; + a = a[0]; + return a.length <= b.length ? a : b; + } + return best_of([ a[0], best_of(a.slice(1)) ]); + }; + + function needs_parens(expr) { + if (expr[0] == "function" || expr[0] == "object") { + // dot/call on a literal function requires the + // function literal itself to be parenthesized + // only if it's the first "thing" in a + // statement. This means that the parent is + // "stat", but it could also be a "seq" and + // we're the first in this "seq" and the + // parent is "stat", and so on. Messy stuff, + // but it worths the trouble. + var a = slice($stack), self = a.pop(), p = a.pop(); + while (p) { + if (p[0] == "stat") return true; + if (((p[0] == "seq" || p[0] == "call" || p[0] == "dot" || p[0] == "sub" || p[0] == "conditional") && p[1] === self) || + ((p[0] == "binary" || p[0] == "assign" || p[0] == "unary-postfix") && p[2] === self)) { + self = p; + p = a.pop(); + } else { + return false; + } + } + } + return !HOP(DOT_CALL_NO_PARENS, expr[0]); + }; + + function make_num(num) { + var str = num.toString(10), a = [ str.replace(/^0\./, ".") ], m; + if (Math.floor(num) === num) { + a.push("0x" + num.toString(16).toLowerCase(), // probably pointless + "0" + num.toString(8)); // same. + if ((m = /^(.*?)(0+)$/.exec(num))) { + a.push(m[1] + "e" + m[2].length); + } + } else if ((m = /^0?\.(0+)(.*)$/.exec(num))) { + a.push(m[2] + "e-" + (m[1].length + m[2].length), + str.substr(str.indexOf("."))); + } + return best_of(a); + }; + + var generators = { + "string": encode_string, + "num": make_num, + "name": make_name, + "toplevel": function(statements) { + return make_block_statements(statements) + .join(newline + newline); + }, + "splice": function(statements) { + var parent = $stack[$stack.length - 2][0]; + if (HOP(SPLICE_NEEDS_BRACKETS, parent)) { + // we need block brackets in this case + return make_block.apply(this, arguments); + } else { + return MAP(make_block_statements(statements, true), + function(line, i) { + // the first line is already indented + return i > 0 ? indent(line) : line; + }).join(newline); + } + }, + "block": make_block, + "var": function(defs) { + return "var " + add_commas(MAP(defs, make_1vardef)) + ";"; + }, + "const": function(defs) { + return "const " + add_commas(MAP(defs, make_1vardef)) + ";"; + }, + "try": function(tr, ca, fi) { + var out = [ "try", make_block(tr) ]; + if (ca) out.push("catch", "(" + ca[0] + ")", make_block(ca[1])); + if (fi) out.push("finally", make_block(fi)); + return add_spaces(out); + }, + "throw": function(expr) { + return add_spaces([ "throw", make(expr) ]) + ";"; + }, + "new": function(ctor, args) { + args = args.length > 0 ? "(" + add_commas(MAP(args, make)) + ")" : ""; + return add_spaces([ "new", parenthesize(ctor, "seq", "binary", "conditional", "assign", function(expr){ + var w = ast_walker(), has_call = {}; + try { + w.with_walkers({ + "call": function() { throw has_call }, + "function": function() { return this } + }, function(){ + w.walk(expr); + }); + } catch(ex) { + if (ex === has_call) + return true; + throw ex; + } + }) + args ]); + }, + "switch": function(expr, body) { + return add_spaces([ "switch", "(" + make(expr) + ")", make_switch_block(body) ]); + }, + "break": function(label) { + var out = "break"; + if (label != null) + out += " " + make_name(label); + return out + ";"; + }, + "continue": function(label) { + var out = "continue"; + if (label != null) + out += " " + make_name(label); + return out + ";"; + }, + "conditional": function(co, th, el) { + return add_spaces([ parenthesize(co, "assign", "seq", "conditional"), "?", + parenthesize(th, "seq"), ":", + parenthesize(el, "seq") ]); + }, + "assign": function(op, lvalue, rvalue) { + if (op && op !== true) op += "="; + else op = "="; + return add_spaces([ make(lvalue), op, parenthesize(rvalue, "seq") ]); + }, + "dot": function(expr) { + var out = make(expr), i = 1; + if (expr[0] == "num") { + if (!/\./.test(expr[1])) + out += "."; + } else if (needs_parens(expr)) + out = "(" + out + ")"; + while (i < arguments.length) + out += "." + make_name(arguments[i++]); + return out; + }, + "call": function(func, args) { + var f = make(func); + if (needs_parens(func)) + f = "(" + f + ")"; + return f + "(" + add_commas(MAP(args, function(expr){ + return parenthesize(expr, "seq"); + })) + ")"; + }, + "function": make_function, + "defun": make_function, + "if": function(co, th, el) { + var out = [ "if", "(" + make(co) + ")", el ? make_then(th) : make(th) ]; + if (el) { + out.push("else", make(el)); + } + return add_spaces(out); + }, + "for": function(init, cond, step, block) { + var out = [ "for" ]; + init = (init != null ? make(init) : "").replace(/;*\s*$/, ";" + space); + cond = (cond != null ? make(cond) : "").replace(/;*\s*$/, ";" + space); + step = (step != null ? make(step) : "").replace(/;*\s*$/, ""); + var args = init + cond + step; + if (args == "; ; ") args = ";;"; + out.push("(" + args + ")", make(block)); + return add_spaces(out); + }, + "for-in": function(vvar, key, hash, block) { + return add_spaces([ "for", "(" + + (vvar ? make(vvar).replace(/;+$/, "") : make(key)), + "in", + make(hash) + ")", make(block) ]); + }, + "while": function(condition, block) { + return add_spaces([ "while", "(" + make(condition) + ")", make(block) ]); + }, + "do": function(condition, block) { + return add_spaces([ "do", make(block), "while", "(" + make(condition) + ")" ]) + ";"; + }, + "return": function(expr) { + var out = [ "return" ]; + if (expr != null) out.push(make(expr)); + return add_spaces(out) + ";"; + }, + "binary": function(operator, lvalue, rvalue) { + var left = make(lvalue), right = make(rvalue); + // XXX: I'm pretty sure other cases will bite here. + // we need to be smarter. + // adding parens all the time is the safest bet. + if (member(lvalue[0], [ "assign", "conditional", "seq" ]) || + lvalue[0] == "binary" && PRECEDENCE[operator] > PRECEDENCE[lvalue[1]]) { + left = "(" + left + ")"; + } + if (member(rvalue[0], [ "assign", "conditional", "seq" ]) || + rvalue[0] == "binary" && PRECEDENCE[operator] >= PRECEDENCE[rvalue[1]] && + !(rvalue[1] == operator && member(operator, [ "&&", "||", "*" ]))) { + right = "(" + right + ")"; + } + return add_spaces([ left, operator, right ]); + }, + "unary-prefix": function(operator, expr) { + var val = make(expr); + if (!(expr[0] == "num" || (expr[0] == "unary-prefix" && !HOP(OPERATORS, operator + expr[1])) || !needs_parens(expr))) + val = "(" + val + ")"; + return operator + (jsp.is_alphanumeric_char(operator.charAt(0)) ? " " : "") + val; + }, + "unary-postfix": function(operator, expr) { + var val = make(expr); + if (!(expr[0] == "num" || (expr[0] == "unary-postfix" && !HOP(OPERATORS, operator + expr[1])) || !needs_parens(expr))) + val = "(" + val + ")"; + return val + operator; + }, + "sub": function(expr, subscript) { + var hash = make(expr); + if (needs_parens(expr)) + hash = "(" + hash + ")"; + return hash + "[" + make(subscript) + "]"; + }, + "object": function(props) { + if (props.length == 0) + return "{}"; + return "{" + newline + with_indent(function(){ + return MAP(props, function(p){ + if (p.length == 3) { + // getter/setter. The name is in p[0], the arg.list in p[1][2], the + // body in p[1][3] and type ("get" / "set") in p[2]. + return indent(make_function(p[0], p[1][2], p[1][3], p[2])); + } + var key = p[0], val = make(p[1]); + if (options.quote_keys) { + key = encode_string(key); + } else if ((typeof key == "number" || !beautify && +key + "" == key) + && parseFloat(key) >= 0) { + key = make_num(+key); + } else if (!is_identifier(key)) { + key = encode_string(key); + } + return indent(add_spaces(beautify && options.space_colon + ? [ key, ":", val ] + : [ key + ":", val ])); + }).join("," + newline); + }) + newline + indent("}"); + }, + "regexp": function(rx, mods) { + return "/" + rx + "/" + mods; + }, + "array": function(elements) { + if (elements.length == 0) return "[]"; + return add_spaces([ "[", add_commas(MAP(elements, function(el){ + if (!beautify && el[0] == "atom" && el[1] == "undefined") return ""; + return parenthesize(el, "seq"); + })), "]" ]); + }, + "stat": function(stmt) { + return make(stmt).replace(/;*\s*$/, ";"); + }, + "seq": function() { + return add_commas(MAP(slice(arguments), make)); + }, + "label": function(name, block) { + return add_spaces([ make_name(name), ":", make(block) ]); + }, + "with": function(expr, block) { + return add_spaces([ "with", "(" + make(expr) + ")", make(block) ]); + }, + "atom": function(name) { + return make_name(name); + } + }; + + // The squeezer replaces "block"-s that contain only a single + // statement with the statement itself; technically, the AST + // is correct, but this can create problems when we output an + // IF having an ELSE clause where the THEN clause ends in an + // IF *without* an ELSE block (then the outer ELSE would refer + // to the inner IF). This function checks for this case and + // adds the block brackets if needed. + function make_then(th) { + if (th[0] == "do") { + // https://github.com/mishoo/UglifyJS/issues/#issue/57 + // IE croaks with "syntax error" on code like this: + // if (foo) do ... while(cond); else ... + // we need block brackets around do/while + return make([ "block", [ th ]]); + } + var b = th; + while (true) { + var type = b[0]; + if (type == "if") { + if (!b[3]) + // no else, we must add the block + return make([ "block", [ th ]]); + b = b[3]; + } + else if (type == "while" || type == "do") b = b[2]; + else if (type == "for" || type == "for-in") b = b[4]; + else break; + } + return make(th); + }; + + function make_function(name, args, body, keyword) { + var out = keyword || "function"; + if (name) { + out += " " + make_name(name); + } + out += "(" + add_commas(MAP(args, make_name)) + ")"; + return add_spaces([ out, make_block(body) ]); + }; + + function make_block_statements(statements, noindent) { + for (var a = [], last = statements.length - 1, i = 0; i <= last; ++i) { + var stat = statements[i]; + var code = make(stat); + if (code != ";") { + if (!beautify && i == last) { + if ((stat[0] == "while" && empty(stat[2])) || + (member(stat[0], [ "for", "for-in"] ) && empty(stat[4])) || + (stat[0] == "if" && empty(stat[2]) && !stat[3]) || + (stat[0] == "if" && stat[3] && empty(stat[3]))) { + code = code.replace(/;*\s*$/, ";"); + } else { + code = code.replace(/;+\s*$/, ""); + } + } + a.push(code); + } + } + return noindent ? a : MAP(a, indent); + }; + + function make_switch_block(body) { + var n = body.length; + if (n == 0) return "{}"; + return "{" + newline + MAP(body, function(branch, i){ + var has_body = branch[1].length > 0, code = with_indent(function(){ + return indent(branch[0] + ? add_spaces([ "case", make(branch[0]) + ":" ]) + : "default:"); + }, 0.5) + (has_body ? newline + with_indent(function(){ + return make_block_statements(branch[1]).join(newline); + }) : ""); + if (!beautify && has_body && i < n - 1) + code += ";"; + return code; + }).join(newline) + newline + indent("}"); + }; + + function make_block(statements) { + if (!statements) return ";"; + if (statements.length == 0) return "{}"; + return "{" + newline + with_indent(function(){ + return make_block_statements(statements).join(newline); + }) + newline + indent("}"); + }; + + function make_1vardef(def) { + var name = def[0], val = def[1]; + if (val != null) + name = add_spaces([ make_name(name), "=", parenthesize(val, "seq") ]); + return name; + }; + + var $stack = []; + + function make(node) { + var type = node[0]; + var gen = generators[type]; + if (!gen) + throw new Error("Can't find generator for \"" + type + "\""); + $stack.push(node); + var ret = gen.apply(type, node.slice(1)); + $stack.pop(); + return ret; + }; + + return make(ast); +}; + +function split_lines(code, max_line_length) { + var splits = [ 0 ]; + jsp.parse(function(){ + var next_token = jsp.tokenizer(code); + var last_split = 0; + var prev_token; + function current_length(tok) { + return tok.pos - last_split; + }; + function split_here(tok) { + last_split = tok.pos; + splits.push(last_split); + }; + function custom(){ + var tok = next_token.apply(this, arguments); + out: { + if (prev_token) { + if (prev_token.type == "keyword") break out; + } + if (current_length(tok) > max_line_length) { + switch (tok.type) { + case "keyword": + case "atom": + case "name": + case "punc": + split_here(tok); + break out; + } + } + } + prev_token = tok; + return tok; + }; + custom.context = function() { + return next_token.context.apply(this, arguments); + }; + return custom; + }()); + return splits.map(function(pos, i){ + return code.substring(pos, splits[i + 1] || code.length); + }).join("\n"); +}; + +/* -----[ Utilities ]----- */ + +function repeat_string(str, i) { + if (i <= 0) return ""; + if (i == 1) return str; + var d = repeat_string(str, i >> 1); + d += d; + if (i & 1) d += str; + return d; +}; + +function defaults(args, defs) { + var ret = {}; + if (args === true) + args = {}; + for (var i in defs) if (HOP(defs, i)) { + ret[i] = (args && HOP(args, i)) ? args[i] : defs[i]; + } + return ret; +}; + +function is_identifier(name) { + return /^[a-z_$][a-z0-9_$]*$/i.test(name) + && name != "this" + && !HOP(jsp.KEYWORDS_ATOM, name) + && !HOP(jsp.RESERVED_WORDS, name) + && !HOP(jsp.KEYWORDS, name); +}; + +function HOP(obj, prop) { + return Object.prototype.hasOwnProperty.call(obj, prop); +}; + +// some utilities + +var MAP; + +(function(){ + MAP = function(a, f, o) { + var ret = []; + for (var i = 0; i < a.length; ++i) { + var val = f.call(o, a[i], i); + if (val instanceof AtTop) ret.unshift(val.v); + else ret.push(val); + } + return ret; + }; + MAP.at_top = function(val) { return new AtTop(val) }; + function AtTop(val) { this.v = val }; +})(); + +/* -----[ Exports ]----- */ + +exports.ast_walker = ast_walker; +exports.ast_mangle = ast_mangle; +exports.ast_squeeze = ast_squeeze; +exports.gen_code = gen_code; +exports.ast_add_scope = ast_add_scope; +exports.set_logger = function(logger) { warn = logger }; +exports.make_string = make_string; +exports.split_lines = split_lines; +exports.MAP = MAP; + +// keep this last! +exports.ast_squeeze_more = require("./squeeze-more").ast_squeeze_more; +; + }).call(module.exports); + + __require.modules["/node_modules/burrito/node_modules/uglify-js/lib/process.js"]._cached = module.exports; + return module.exports; +}; + +require.modules["/node_modules/burrito/node_modules/uglify-js/lib/squeeze-more.js"] = function () { + var module = { exports : {} }; + var exports = module.exports; + var __dirname = "/node_modules/burrito/node_modules/uglify-js/lib"; + var __filename = "/node_modules/burrito/node_modules/uglify-js/lib/squeeze-more.js"; + + var require = function (file) { + return __require(file, "/node_modules/burrito/node_modules/uglify-js/lib"); + }; + + require.resolve = function (file) { + return __require.resolve(name, "/node_modules/burrito/node_modules/uglify-js/lib"); + }; + + require.modules = __require.modules; + __require.modules["/node_modules/burrito/node_modules/uglify-js/lib/squeeze-more.js"]._cached = module.exports; + + (function () { + var jsp = require("./parse-js"), + pro = require("./process"), + slice = jsp.slice, + member = jsp.member, + PRECEDENCE = jsp.PRECEDENCE, + OPERATORS = jsp.OPERATORS; + +function ast_squeeze_more(ast) { + var w = pro.ast_walker(), walk = w.walk; + return w.with_walkers({ + "call": function(expr, args) { + if (expr[0] == "dot" && expr[2] == "toString" && args.length == 0) { + // foo.toString() ==> foo+"" + return [ "binary", "+", expr[1], [ "string", "" ]]; + } + } + }, function() { + return walk(ast); + }); +}; + +exports.ast_squeeze_more = ast_squeeze_more; +; + }).call(module.exports); + + __require.modules["/node_modules/burrito/node_modules/uglify-js/lib/squeeze-more.js"]._cached = module.exports; + return module.exports; +}; + +require.modules["/node_modules/burrito/node_modules/traverse/package.json"] = function () { + var module = { exports : {} }; + var exports = module.exports; + var __dirname = "/node_modules/burrito/node_modules/traverse"; + var __filename = "/node_modules/burrito/node_modules/traverse/package.json"; + + var require = function (file) { + return __require(file, "/node_modules/burrito/node_modules/traverse"); + }; + + require.resolve = function (file) { + return __require.resolve(name, "/node_modules/burrito/node_modules/traverse"); + }; + + require.modules = __require.modules; + __require.modules["/node_modules/burrito/node_modules/traverse/package.json"]._cached = module.exports; + + (function () { + module.exports = {"name":"traverse","version":"0.5.0","description":"Traverse and transform objects by visiting every node on a recursive walk","author":"James Halliday","license":"MIT/X11","main":"./index","repository":{"type":"git","url":"http://github.com/substack/js-traverse.git"},"devDependencies":{"expresso":"0.7.x"},"scripts":{"test":"expresso"}}; + }).call(module.exports); + + __require.modules["/node_modules/burrito/node_modules/traverse/package.json"]._cached = module.exports; + return module.exports; +}; + +require.modules["/node_modules/burrito/node_modules/traverse/index.js"] = function () { + var module = { exports : {} }; + var exports = module.exports; + var __dirname = "/node_modules/burrito/node_modules/traverse"; + var __filename = "/node_modules/burrito/node_modules/traverse/index.js"; + + var require = function (file) { + return __require(file, "/node_modules/burrito/node_modules/traverse"); + }; + + require.resolve = function (file) { + return __require.resolve(name, "/node_modules/burrito/node_modules/traverse"); + }; + + require.modules = __require.modules; + __require.modules["/node_modules/burrito/node_modules/traverse/index.js"]._cached = module.exports; + + (function () { + module.exports = Traverse; +function Traverse (obj) { + if (!(this instanceof Traverse)) return new Traverse(obj); + this.value = obj; +} + +Traverse.prototype.get = function (ps) { + var node = this.value; + for (var i = 0; i < ps.length; i ++) { + var key = ps[i]; + if (!Object.hasOwnProperty.call(node, key)) { + node = undefined; + break; + } + node = node[key]; + } + return node; +}; + +Traverse.prototype.set = function (ps, value) { + var node = this.value; + for (var i = 0; i < ps.length - 1; i ++) { + var key = ps[i]; + if (!Object.hasOwnProperty.call(node, key)) node[key] = {}; + node = node[key]; + } + node[ps[i]] = value; + return value; +}; + +Traverse.prototype.map = function (cb) { + return walk(this.value, cb, true); +}; + +Traverse.prototype.forEach = function (cb) { + this.value = walk(this.value, cb, false); + return this.value; +}; + +Traverse.prototype.reduce = function (cb, init) { + var skip = arguments.length === 1; + var acc = skip ? this.value : init; + this.forEach(function (x) { + if (!this.isRoot || !skip) { + acc = cb.call(this, acc, x); + } + }); + return acc; +}; + +Traverse.prototype.paths = function () { + var acc = []; + this.forEach(function (x) { + acc.push(this.path); + }); + return acc; +}; + +Traverse.prototype.nodes = function () { + var acc = []; + this.forEach(function (x) { + acc.push(this.node); + }); + return acc; +}; + +Traverse.prototype.clone = function () { + var parents = [], nodes = []; + + return (function clone (src) { + for (var i = 0; i < parents.length; i++) { + if (parents[i] === src) { + return nodes[i]; + } + } + + if (typeof src === 'object' && src !== null) { + var dst = copy(src); + + parents.push(src); + nodes.push(dst); + + forEach(Object_keys(src), function (key) { + dst[key] = clone(src[key]); + }); + + parents.pop(); + nodes.pop(); + return dst; + } + else { + return src; + } + })(this.value); +}; + +function walk (root, cb, immutable) { + var path = []; + var parents = []; + var alive = true; + + return (function walker (node_) { + var node = immutable ? copy(node_) : node_; + var modifiers = {}; + + var keepGoing = true; + + var state = { + node : node, + node_ : node_, + path : [].concat(path), + parent : parents[parents.length - 1], + parents : parents, + key : path.slice(-1)[0], + isRoot : path.length === 0, + level : path.length, + circular : null, + update : function (x, stopHere) { + if (!state.isRoot) { + state.parent.node[state.key] = x; + } + state.node = x; + if (stopHere) keepGoing = false; + }, + 'delete' : function () { + delete state.parent.node[state.key]; + }, + remove : function () { + if (Array_isArray(state.parent.node)) { + state.parent.node.splice(state.key, 1); + } + else { + delete state.parent.node[state.key]; + } + }, + keys : null, + before : function (f) { modifiers.before = f }, + after : function (f) { modifiers.after = f }, + pre : function (f) { modifiers.pre = f }, + post : function (f) { modifiers.post = f }, + stop : function () { alive = false }, + block : function () { keepGoing = false } + }; + + if (!alive) return state; + + if (typeof node === 'object' && node !== null) { + state.keys = Object_keys(node); + + state.isLeaf = state.keys.length == 0; + + for (var i = 0; i < parents.length; i++) { + if (parents[i].node_ === node_) { + state.circular = parents[i]; + break; + } + } + } + else { + state.isLeaf = true; + } + + state.notLeaf = !state.isLeaf; + state.notRoot = !state.isRoot; + + // use return values to update if defined + var ret = cb.call(state, state.node); + if (ret !== undefined && state.update) state.update(ret); + + if (modifiers.before) modifiers.before.call(state, state.node); + + if (!keepGoing) return state; + + if (typeof state.node == 'object' + && state.node !== null && !state.circular) { + parents.push(state); + + forEach(state.keys, function (key, i) { + path.push(key); + + if (modifiers.pre) modifiers.pre.call(state, state.node[key], key); + + var child = walker(state.node[key]); + if (immutable && Object.hasOwnProperty.call(state.node, key)) { + state.node[key] = child.node; + } + + child.isLast = i == state.keys.length - 1; + child.isFirst = i == 0; + + if (modifiers.post) modifiers.post.call(state, child); + + path.pop(); + }); + parents.pop(); + } + + if (modifiers.after) modifiers.after.call(state, state.node); + + return state; + })(root).node; +} + +function copy (src) { + if (typeof src === 'object' && src !== null) { + var dst; + + if (Array_isArray(src)) { + dst = []; + } + else if (src instanceof Date) { + dst = new Date(src); + } + else if (src instanceof Boolean) { + dst = new Boolean(src); + } + else if (src instanceof Number) { + dst = new Number(src); + } + else if (src instanceof String) { + dst = new String(src); + } + else if (Object.create && Object.getPrototypeOf) { + dst = Object.create(Object.getPrototypeOf(src)); + } + else if (src.__proto__ || src.constructor.prototype) { + var proto = src.__proto__ || src.constructor.prototype || {}; + var T = function () {}; + T.prototype = proto; + dst = new T; + if (!dst.__proto__) dst.__proto__ = proto; + } + + forEach(Object_keys(src), function (key) { + dst[key] = src[key]; + }); + return dst; + } + else return src; +} + +var Object_keys = Object.keys || function keys (obj) { + var res = []; + for (var key in obj) res.push(key) + return res; +}; + +var Array_isArray = Array.isArray || function isArray (xs) { + return Object.prototype.toString.call(xs) === '[object Array]'; +}; + +var forEach = function (xs, fn) { + if (xs.forEach) return xs.forEach(fn) + else for (var i = 0; i < xs.length; i++) { + fn(xs[i], i, xs); + } +}; + +forEach(Object_keys(Traverse.prototype), function (key) { + Traverse[key] = function (obj) { + var args = [].slice.call(arguments, 1); + var t = Traverse(obj); + return t[key].apply(t, args); + }; +}); +; + }).call(module.exports); + + __require.modules["/node_modules/burrito/node_modules/traverse/index.js"]._cached = module.exports; + return module.exports; +}; + +require.modules["vm"] = function () { + var module = { exports : {} }; + var exports = module.exports; + var __dirname = "."; + var __filename = "vm"; + + var require = function (file) { + return __require(file, "."); + }; + + require.resolve = function (file) { + return __require.resolve(name, "."); + }; + + require.modules = __require.modules; + __require.modules["vm"]._cached = module.exports; + + (function () { + var Object_keys = function (obj) { + if (Object.keys) return Object.keys(obj) + else { + var res = []; + for (var key in obj) res.push(key) + return res; + } +}; + +var forEach = function (xs, fn) { + if (xs.forEach) return xs.forEach(fn) + else for (var i = 0; i < xs.length; i++) { + fn(xs[i], i, xs); + } +}; + +var Script = exports.Script = function NodeScript (code) { + if (!(this instanceof Script)) return new Script(code); + this.code = code; +}; + +var iframe = document.createElement('iframe'); +if (!iframe.style) iframe.style = {}; +iframe.style.display = 'none'; + +var iframeCapable = true; // until proven otherwise +if (navigator.appName === 'Microsoft Internet Explorer') { + var m = navigator.appVersion.match(/\bMSIE (\d+\.\d+);/); + if (m && parseFloat(m[1]) <= 9.0) { + iframeCapable = false; + } +} + +Script.prototype.runInNewContext = function (context) { + if (!context) context = {}; + + if (!iframeCapable) { + var keys = Object_keys(context); + var args = []; + for (var i = 0; i < keys.length; i++) { + args.push(context[keys[i]]); + } + + var fn = Function(keys, this.code); + return fn.apply(null, args); + } + + document.body.appendChild(iframe); + + var win = iframe.contentWindow + || (window.frames && window.frames[window.frames.length - 1]) + || window[window.length - 1] + ; + + forEach(Object_keys(context), function (key) { + win[key] = context[key]; + iframe[key] = context[key]; + }); + + if (win.eval) { + // chrome and ff can just .eval() + var res = win.eval(this.code); + } + else { + // this works in IE9 but not anything newer + iframe.setAttribute('src', + 'javascript:__browserifyVmResult=(' + this.code + ')' + ); + if ('__browserifyVmResult' in win) { + var res = win.__browserifyVmResult; + } + else { + iframeCapable = false; + res = this.runInThisContext(context); + } + } + + forEach(Object_keys(win), function (key) { + context[key] = win[key]; + }); + + document.body.removeChild(iframe); + + return res; +}; + +Script.prototype.runInThisContext = function () { + return eval(this.code); // maybe... +}; + +Script.prototype.runInContext = function (context) { + // seems to be just runInNewContext on magical context objects which are + // otherwise indistinguishable from objects except plain old objects + // for the parameter segfaults node + return this.runInNewContext(context); +}; + +forEach(Object_keys(Script.prototype), function (name) { + exports[name] = Script[name] = function (code) { + var s = Script(code); + return s[name].apply(s, [].slice.call(arguments, 1)); + }; +}); + +exports.createScript = function (code) { + return exports.Script(code); +}; + +exports.createContext = Script.createContext = function (context) { + // not really sure what this one does + // seems to just make a shallow copy + var copy = {}; + forEach(Object_keys(context), function (key) { + copy[key] = context[key]; + }); + return copy; +}; +; + }).call(module.exports); + + __require.modules["vm"]._cached = module.exports; + return module.exports; +}; + +require.modules["/node_modules/jsonify/package.json"] = function () { + var module = { exports : {} }; + var exports = module.exports; + var __dirname = "/node_modules/jsonify"; + var __filename = "/node_modules/jsonify/package.json"; + + var require = function (file) { + return __require(file, "/node_modules/jsonify"); + }; + + require.resolve = function (file) { + return __require.resolve(name, "/node_modules/jsonify"); + }; + + require.modules = __require.modules; + __require.modules["/node_modules/jsonify/package.json"]._cached = module.exports; + + (function () { + module.exports = {"name":"jsonify","version":"0.0.0","description":"JSON without touching any globals","main":"index.js","directories":{"lib":".","test":"test"},"devDependencies":{"tap":"0.0.x","garbage":"0.0.x"},"scripts":{"test":"tap test"},"repository":{"type":"git","url":"http://github.com/substack/jsonify.git"},"keywords":["json","browser"],"author":{"name":"Douglas Crockford","url":"http://crockford.com/"},"license":"Public Domain"}; + }).call(module.exports); + + __require.modules["/node_modules/jsonify/package.json"]._cached = module.exports; + return module.exports; +}; + +require.modules["/node_modules/jsonify/index.js"] = function () { + var module = { exports : {} }; + var exports = module.exports; + var __dirname = "/node_modules/jsonify"; + var __filename = "/node_modules/jsonify/index.js"; + + var require = function (file) { + return __require(file, "/node_modules/jsonify"); + }; + + require.resolve = function (file) { + return __require.resolve(name, "/node_modules/jsonify"); + }; + + require.modules = __require.modules; + __require.modules["/node_modules/jsonify/index.js"]._cached = module.exports; + + (function () { + exports.parse = require('./lib/parse'); +exports.stringify = require('./lib/stringify'); +; + }).call(module.exports); + + __require.modules["/node_modules/jsonify/index.js"]._cached = module.exports; + return module.exports; +}; + +require.modules["/node_modules/jsonify/lib/parse.js"] = function () { + var module = { exports : {} }; + var exports = module.exports; + var __dirname = "/node_modules/jsonify/lib"; + var __filename = "/node_modules/jsonify/lib/parse.js"; + + var require = function (file) { + return __require(file, "/node_modules/jsonify/lib"); + }; + + require.resolve = function (file) { + return __require.resolve(name, "/node_modules/jsonify/lib"); + }; + + require.modules = __require.modules; + __require.modules["/node_modules/jsonify/lib/parse.js"]._cached = module.exports; + + (function () { + var at, // The index of the current character + ch, // The current character + escapee = { + '"': '"', + '\\': '\\', + '/': '/', + b: '\b', + f: '\f', + n: '\n', + r: '\r', + t: '\t' + }, + text, + + error = function (m) { + // Call error when something is wrong. + throw { + name: 'SyntaxError', + message: m, + at: at, + text: text + }; + }, + + next = function (c) { + // If a c parameter is provided, verify that it matches the current character. + if (c && c !== ch) { + error("Expected '" + c + "' instead of '" + ch + "'"); + } + + // Get the next character. When there are no more characters, + // return the empty string. + + ch = text.charAt(at); + at += 1; + return ch; + }, + + number = function () { + // Parse a number value. + var number, + string = ''; + + if (ch === '-') { + string = '-'; + next('-'); + } + while (ch >= '0' && ch <= '9') { + string += ch; + next(); + } + if (ch === '.') { + string += '.'; + while (next() && ch >= '0' && ch <= '9') { + string += ch; + } + } + if (ch === 'e' || ch === 'E') { + string += ch; + next(); + if (ch === '-' || ch === '+') { + string += ch; + next(); + } + while (ch >= '0' && ch <= '9') { + string += ch; + next(); + } + } + number = +string; + if (!isFinite(number)) { + error("Bad number"); + } else { + return number; + } + }, + + string = function () { + // Parse a string value. + var hex, + i, + string = '', + uffff; + + // When parsing for string values, we must look for " and \ characters. + if (ch === '"') { + while (next()) { + if (ch === '"') { + next(); + return string; + } else if (ch === '\\') { + next(); + if (ch === 'u') { + uffff = 0; + for (i = 0; i < 4; i += 1) { + hex = parseInt(next(), 16); + if (!isFinite(hex)) { + break; + } + uffff = uffff * 16 + hex; + } + string += String.fromCharCode(uffff); + } else if (typeof escapee[ch] === 'string') { + string += escapee[ch]; + } else { + break; + } + } else { + string += ch; + } + } + } + error("Bad string"); + }, + + white = function () { + +// Skip whitespace. + + while (ch && ch <= ' ') { + next(); + } + }, + + word = function () { + +// true, false, or null. + + switch (ch) { + case 't': + next('t'); + next('r'); + next('u'); + next('e'); + return true; + case 'f': + next('f'); + next('a'); + next('l'); + next('s'); + next('e'); + return false; + case 'n': + next('n'); + next('u'); + next('l'); + next('l'); + return null; + } + error("Unexpected '" + ch + "'"); + }, + + value, // Place holder for the value function. + + array = function () { + +// Parse an array value. + + var array = []; + + if (ch === '[') { + next('['); + white(); + if (ch === ']') { + next(']'); + return array; // empty array + } + while (ch) { + array.push(value()); + white(); + if (ch === ']') { + next(']'); + return array; + } + next(','); + white(); + } + } + error("Bad array"); + }, + + object = function () { + +// Parse an object value. + + var key, + object = {}; + + if (ch === '{') { + next('{'); + white(); + if (ch === '}') { + next('}'); + return object; // empty object + } + while (ch) { + key = string(); + white(); + next(':'); + if (Object.hasOwnProperty.call(object, key)) { + error('Duplicate key "' + key + '"'); + } + object[key] = value(); + white(); + if (ch === '}') { + next('}'); + return object; + } + next(','); + white(); + } + } + error("Bad object"); + }; + +value = function () { + +// Parse a JSON value. It could be an object, an array, a string, a number, +// or a word. + + white(); + switch (ch) { + case '{': + return object(); + case '[': + return array(); + case '"': + return string(); + case '-': + return number(); + default: + return ch >= '0' && ch <= '9' ? number() : word(); + } +}; + +// Return the json_parse function. It will have access to all of the above +// functions and variables. + +module.exports = function (source, reviver) { + var result; + + text = source; + at = 0; + ch = ' '; + result = value(); + white(); + if (ch) { + error("Syntax error"); + } + + // If there is a reviver function, we recursively walk the new structure, + // passing each name/value pair to the reviver function for possible + // transformation, starting with a temporary root object that holds the result + // in an empty key. If there is not a reviver function, we simply return the + // result. + + return typeof reviver === 'function' ? (function walk(holder, key) { + var k, v, value = holder[key]; + if (value && typeof value === 'object') { + for (k in value) { + if (Object.prototype.hasOwnProperty.call(value, k)) { + v = walk(value, k); + if (v !== undefined) { + value[k] = v; + } else { + delete value[k]; + } + } + } + } + return reviver.call(holder, key, value); + }({'': result}, '')) : result; +}; +; + }).call(module.exports); + + __require.modules["/node_modules/jsonify/lib/parse.js"]._cached = module.exports; + return module.exports; +}; + +require.modules["/node_modules/jsonify/lib/stringify.js"] = function () { + var module = { exports : {} }; + var exports = module.exports; + var __dirname = "/node_modules/jsonify/lib"; + var __filename = "/node_modules/jsonify/lib/stringify.js"; + + var require = function (file) { + return __require(file, "/node_modules/jsonify/lib"); + }; + + require.resolve = function (file) { + return __require.resolve(name, "/node_modules/jsonify/lib"); + }; + + require.modules = __require.modules; + __require.modules["/node_modules/jsonify/lib/stringify.js"]._cached = module.exports; + + (function () { + var cx = /[\u0000\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g, + escapable = /[\\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g, + gap, + indent, + meta = { // table of character substitutions + '\b': '\\b', + '\t': '\\t', + '\n': '\\n', + '\f': '\\f', + '\r': '\\r', + '"' : '\\"', + '\\': '\\\\' + }, + rep; + +function quote(string) { + // If the string contains no control characters, no quote characters, and no + // backslash characters, then we can safely slap some quotes around it. + // Otherwise we must also replace the offending characters with safe escape + // sequences. + + escapable.lastIndex = 0; + return escapable.test(string) ? '"' + string.replace(escapable, function (a) { + var c = meta[a]; + return typeof c === 'string' ? c : + '\\u' + ('0000' + a.charCodeAt(0).toString(16)).slice(-4); + }) + '"' : '"' + string + '"'; +} + +function str(key, holder) { + // Produce a string from holder[key]. + var i, // The loop counter. + k, // The member key. + v, // The member value. + length, + mind = gap, + partial, + value = holder[key]; + + // If the value has a toJSON method, call it to obtain a replacement value. + if (value && typeof value === 'object' && + typeof value.toJSON === 'function') { + value = value.toJSON(key); + } + + // If we were called with a replacer function, then call the replacer to + // obtain a replacement value. + if (typeof rep === 'function') { + value = rep.call(holder, key, value); + } + + // What happens next depends on the value's type. + switch (typeof value) { + case 'string': + return quote(value); + + case 'number': + // JSON numbers must be finite. Encode non-finite numbers as null. + return isFinite(value) ? String(value) : 'null'; + + case 'boolean': + case 'null': + // If the value is a boolean or null, convert it to a string. Note: + // typeof null does not produce 'null'. The case is included here in + // the remote chance that this gets fixed someday. + return String(value); + + case 'object': + if (!value) return 'null'; + gap += indent; + partial = []; + + // Array.isArray + if (Object.prototype.toString.apply(value) === '[object Array]') { + length = value.length; + for (i = 0; i < length; i += 1) { + partial[i] = str(i, value) || 'null'; + } + + // Join all of the elements together, separated with commas, and + // wrap them in brackets. + v = partial.length === 0 ? '[]' : gap ? + '[\n' + gap + partial.join(',\n' + gap) + '\n' + mind + ']' : + '[' + partial.join(',') + ']'; + gap = mind; + return v; + } + + // If the replacer is an array, use it to select the members to be + // stringified. + if (rep && typeof rep === 'object') { + length = rep.length; + for (i = 0; i < length; i += 1) { + k = rep[i]; + if (typeof k === 'string') { + v = str(k, value); + if (v) { + partial.push(quote(k) + (gap ? ': ' : ':') + v); + } + } + } + } + else { + // Otherwise, iterate through all of the keys in the object. + for (k in value) { + if (Object.prototype.hasOwnProperty.call(value, k)) { + v = str(k, value); + if (v) { + partial.push(quote(k) + (gap ? ': ' : ':') + v); + } + } + } + } + + // Join all of the member texts together, separated with commas, + // and wrap them in braces. + + v = partial.length === 0 ? '{}' : gap ? + '{\n' + gap + partial.join(',\n' + gap) + '\n' + mind + '}' : + '{' + partial.join(',') + '}'; + gap = mind; + return v; + } +} + +module.exports = function (value, replacer, space) { + var i; + gap = ''; + indent = ''; + + // If the space parameter is a number, make an indent string containing that + // many spaces. + if (typeof space === 'number') { + for (i = 0; i < space; i += 1) { + indent += ' '; + } + } + // If the space parameter is a string, it will be used as the indent string. + else if (typeof space === 'string') { + indent = space; + } + + // If there is a replacer, it must be a function or an array. + // Otherwise, throw an error. + rep = replacer; + if (replacer && typeof replacer !== 'function' + && (typeof replacer !== 'object' || typeof replacer.length !== 'number')) { + throw new Error('JSON.stringify'); + } + + // Make a fake root object containing our value under the key of ''. + // Return the result of stringifying the value. + return str('', {'': value}); +}; +; + }).call(module.exports); + + __require.modules["/node_modules/jsonify/lib/stringify.js"]._cached = module.exports; + return module.exports; +}; + +require.modules["/node_modules/burrito/index.js"] = function () { + var module = { exports : {} }; + var exports = module.exports; + var __dirname = "/node_modules/burrito"; + var __filename = "/node_modules/burrito/index.js"; + + var require = function (file) { + return __require(file, "/node_modules/burrito"); + }; + + require.resolve = function (file) { + return __require.resolve(name, "/node_modules/burrito"); + }; + + require.modules = __require.modules; + __require.modules["/node_modules/burrito/index.js"]._cached = module.exports; + + (function () { + var uglify = require('uglify-js'); +var parser = uglify.parser; +var parse = function (expr) { + if (typeof expr !== 'string') throw 'expression should be a string'; + + //try { + var args = [].slice.call(arguments); + var ast = parser.parse.apply(null, args); + /* } + catch (err) { + if (err.message === undefined + || err.line === undefined + || err.col === undefined + || err.pos === undefined + ) { throw err } + + var e = new SyntaxError( + err.message + + '\n at line ' + err.line + ':' + err.col + ' in expression:\n\n' + + ' ' + expr.split(/\r?\n/)[err.line] + ); + + e.original = err; + e.line = err.line; + e.col = err.col; + e.pos = err.pos; + throw e; + } + */ + return ast; +}; + +var deparse = function (ast, b) { + return uglify.uglify.gen_code(ast, { beautify : b }); +}; + +var traverse = require('traverse'); +var vm = require('vm'); + +var burrito = module.exports = function (code, cb) { + var ast = Array_isArray(code) + ? code // already an ast + : parse(code.toString(), false, true) + ; + + var ast_ = traverse(ast).map(function mapper () { + wrapNode(this, cb); + }); + + return deparse(parse(deparse(ast_)), true); +}; + +var wrapNode = burrito.wrapNode = function (state, cb) { + var node = state.node; + + var ann = Array_isArray(node) && node[0] + && typeof node[0] === 'object' && node[0].name + ? node[0] + : null + ; + + if (!ann) return undefined; + + var self = { + name : ann.name, + node : node, + start : node[0].start, + end : node[0].end, + value : node.slice(1), + state : state + }; + + self.wrap = function (s) { + var subsrc = deparse( + traverse(node).map(function (x) { + if (!this.isRoot) wrapNode(this, cb) + }) + ); + + if (self.name === 'binary') { + var a = deparse(traverse(node[2]).map(function (x) { + if (!this.isRoot) wrapNode(this, cb) + })); + var b = deparse(traverse(node[3]).map(function (x) { + if (!this.isRoot) wrapNode(this, cb) + })); + } + + var src = ''; + + if (typeof s === 'function') { + if (self.name === 'binary') { + src = s(subsrc, a, b); + } + else { + src = s(subsrc); + } + } + else { + src = s.toString() + .replace(/%s/g, function () { + return subsrc + }) + ; + + if (self.name === 'binary') { + src = src + .replace(/%a/g, function () { return a }) + .replace(/%b/g, function () { return b }) + ; + } + } + + var expr = parse(src); + state.update(expr, true); + }; + + var cache = {}; + + self.parent = state.isRoot ? null : function () { + if (!cache.parent) { + var s = state; + var x; + do { + s = s.parent; + if (s) x = wrapNode(s); + } while (s && !x); + + cache.parent = x; + } + + return cache.parent; + }; + + self.source = function () { + if (!cache.source) cache.source = deparse(node); + return cache.source; + }; + + self.label = function () { + return burrito.label(self); + }; + + if (cb) cb.call(state, self); + + if (self.node[0].name === 'conditional') { + self.wrap('[%s][0]'); + } + + return self; +} + +burrito.microwave = function (code, context, cb) { + if (!cb) { cb = context; context = {} }; + if (!context) context = {}; + + var src = burrito(code, cb); + return vm.runInNewContext(src, context); +}; + +burrito.generateName = function (len) { + var name = ''; + var lower = '$'.charCodeAt(0); + var upper = 'z'.charCodeAt(0); + + while (name.length < len) { + var c = String.fromCharCode(Math.floor( + Math.random() * (upper - lower + 1) + lower + )); + if ((name + c).match(/^[A-Za-z_$][A-Za-z0-9_$]*$/)) name += c; + } + + return name; +}; + +burrito.parse = parse; +burrito.deparse = deparse; + +burrito.label = function (node) { + if (node.name === 'call') { + if (typeof node.value[0] === 'string') { + return node.value[0]; + } + else if (node.value[0] && typeof node.value[0][1] === 'string') { + return node.value[0][1]; + } + else { + return null; + } + } + else if (node.name === 'var') { + return node.value[0].map(function (x) { return x[0] }); + } + else if (node.name === 'defun') { + return node.value[0]; + } + else if (node.name === 'function') { + return node.value[0]; + } + else { + return null; + } +}; + +var Array_isArray = Array.isArray || function isArray (xs) { + return Object.prototype.toString.call(xs) === '[object Array]'; +}; +; + }).call(module.exports); + + __require.modules["/node_modules/burrito/index.js"]._cached = module.exports; + return module.exports; +}; + +process.nextTick(function () { + var module = { exports : {} }; + var exports = module.exports; + var __dirname = "/"; + var __filename = "//home/substack/projects/node-burrito/example/web"; + + var require = function (file) { + return __require(file, "/"); + }; + require.modules = __require.modules; + + var burrito = require('burrito'); +var json = require('jsonify'); + +var src = [ + 'function f () { g() }', + 'function g () { h() }', + 'function h () { throw "moo" + Array(x).join("!") }', + 'var x = 4', + 'f()' +].join('\r\n'); + +window.onload = function () { + burrito(src, function (node) { + document.body.innerHTML += node.name + '
    \n'; + }); +}; +if (document.readyState === 'complete') window.onload(); +; +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/example/web/index.html b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/example/web/index.html new file mode 100644 index 0000000..66804fb --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/example/web/index.html @@ -0,0 +1,14 @@ + + + + + + +
    
    +
    +
    diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/example/web/main.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/example/web/main.js
    new file mode 100644
    index 0000000..cc81a8b
    --- /dev/null
    +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/example/web/main.js
    @@ -0,0 +1,17 @@
    +var burrito = require('burrito');
    +var json = require('jsonify');
    +
    +var src = [
    +    'function f () { g() }',
    +    'function g () { h() }',
    +    'function h () { throw "moo" + Array(x).join("!") }',
    +    'var x = 4',
    +    'f()'
    +].join('\r\n');
    +
    +window.onload = function () {
    +    burrito(src, function (node) {
    +        document.body.innerHTML += node.name + '
    \n'; + }); +}; +if (document.readyState === 'complete') window.onload(); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/example/web/server.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/example/web/server.js new file mode 100644 index 0000000..6bce020 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/example/web/server.js @@ -0,0 +1,12 @@ +var express = require('express'); +var browserify = require('browserify'); + +var app = express.createServer(); +app.use(express.static(__dirname)); +app.use(browserify({ + entry : __dirname + '/main.js', + watch : true, +})); + +app.listen(8081); +console.log('Listening on :8081'); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/example/wrap.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/example/wrap.js new file mode 100644 index 0000000..1642401 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/example/wrap.js @@ -0,0 +1,7 @@ +var burrito = require('burrito'); + +var src = burrito('f() && g(h())\nfoo()', function (node) { + if (node.name === 'call') node.wrap('qqq(%s)'); +}); + +console.log(src); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/index.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/index.js new file mode 100644 index 0000000..60ef569 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/index.js @@ -0,0 +1,208 @@ +var uglify = require('uglify-js'); +var parser = uglify.parser; +var parse = function (expr) { + if (typeof expr !== 'string') throw 'expression should be a string'; + + try { + var ast = parser.parse.apply(null, arguments); + } + catch (err) { + if (err.message === undefined + || err.line === undefined + || err.col === undefined + || err.pos === undefined + ) { throw err } + + var e = new SyntaxError( + err.message + + '\n at line ' + err.line + ':' + err.col + ' in expression:\n\n' + + ' ' + expr.split(/\r?\n/)[err.line] + ); + + e.original = err; + e.line = err.line; + e.col = err.col; + e.pos = err.pos; + throw e; + } + return ast; +}; + +var deparse = function (ast, b) { + return uglify.uglify.gen_code(ast, { beautify : b }); +}; + +var traverse = require('traverse'); +var vm = require('vm'); + +var burrito = module.exports = function (code, cb) { + var ast = Array_isArray(code) + ? code // already an ast + : parse(code.toString(), false, true) + ; + + var ast_ = traverse(ast).map(function mapper () { + wrapNode(this, cb); + }); + + return deparse(parse(deparse(ast_)), true); +}; + +var wrapNode = burrito.wrapNode = function (state, cb) { + var node = state.node; + + var ann = Array_isArray(node) && node[0] + && typeof node[0] === 'object' && node[0].name + ? node[0] + : null + ; + + if (!ann) return undefined; + + var self = { + name : ann.name, + node : node, + start : node[0].start, + end : node[0].end, + value : node.slice(1), + state : state + }; + + self.wrap = function (s) { + var subsrc = deparse( + traverse(node).map(function (x) { + if (!this.isRoot) wrapNode(this, cb) + }) + ); + + if (self.name === 'binary') { + var a = deparse(traverse(node[2]).map(function (x) { + if (!this.isRoot) wrapNode(this, cb) + })); + var b = deparse(traverse(node[3]).map(function (x) { + if (!this.isRoot) wrapNode(this, cb) + })); + } + + var src = ''; + + if (typeof s === 'function') { + if (self.name === 'binary') { + src = s(subsrc, a, b); + } + else { + src = s(subsrc); + } + } + else { + src = s.toString() + .replace(/%s/g, function () { + return subsrc + }) + ; + + if (self.name === 'binary') { + src = src + .replace(/%a/g, function () { return a }) + .replace(/%b/g, function () { return b }) + ; + } + } + + var expr = parse(src); + state.update(expr, true); + }; + + var cache = {}; + + self.parent = state.isRoot ? null : function () { + if (!cache.parent) { + var s = state; + var x; + do { + s = s.parent; + if (s) x = wrapNode(s); + } while (s && !x); + + cache.parent = x; + } + + return cache.parent; + }; + + self.source = function () { + if (!cache.source) cache.source = deparse(node); + return cache.source; + }; + + self.label = function () { + return burrito.label(self); + }; + + if (cb) cb.call(state, self); + + if (self.node[0].name === 'conditional') { + self.wrap('[%s][0]'); + } + + return self; +} + +burrito.microwave = function (code, context, cb) { + if (!cb) { cb = context; context = {} }; + if (!context) context = {}; + + var src = burrito(code, cb); + return vm.runInNewContext(src, context); +}; + +burrito.generateName = function (len) { + var name = ''; + var lower = '$'.charCodeAt(0); + var upper = 'z'.charCodeAt(0); + + while (name.length < len) { + var c = String.fromCharCode(Math.floor( + Math.random() * (upper - lower + 1) + lower + )); + if ((name + c).match(/^[A-Za-z_$][A-Za-z0-9_$]*$/)) name += c; + } + + return name; +}; + +burrito.parse = parse; +burrito.deparse = deparse; + +burrito.label = function (node) { + if (node.name === 'call') { + if (typeof node.value[0] === 'string') { + return node.value[0]; + } + else if (node.value[0] && typeof node.value[0][1] === 'string') { + return node.value[0][1]; + } + else if (node.value[0][0] === 'dot') { + return node.value[0][node.value[0].length - 1]; + } + else { + return null; + } + } + else if (node.name === 'var') { + return node.value[0].map(function (x) { return x[0] }); + } + else if (node.name === 'defun') { + return node.value[0]; + } + else if (node.name === 'function') { + return node.value[0]; + } + else { + return null; + } +}; + +var Array_isArray = Array.isArray || function isArray (xs) { + return Object.prototype.toString.call(xs) === '[object Array]'; +}; diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/.bin/uglifyjs b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/.bin/uglifyjs new file mode 120000 index 0000000..fef3468 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/.bin/uglifyjs @@ -0,0 +1 @@ +../uglify-js/bin/uglifyjs \ No newline at end of file diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/.npmignore b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/.npmignore new file mode 100644 index 0000000..3c3629e --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/.npmignore @@ -0,0 +1 @@ +node_modules diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/LICENSE b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/LICENSE new file mode 100644 index 0000000..7b75500 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/LICENSE @@ -0,0 +1,24 @@ +Copyright 2010 James Halliday (mail@substack.net) + +This project is free software released under the MIT/X11 license: +http://www.opensource.org/licenses/mit-license.php + +Copyright 2010 James Halliday (mail@substack.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/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/README.markdown b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/README.markdown new file mode 100644 index 0000000..f86ef76 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/README.markdown @@ -0,0 +1,237 @@ +traverse +======== + +Traverse and transform objects by visiting every node on a recursive walk. + +examples +======== + +transform negative numbers in-place +----------------------------------- + +negative.js + +````javascript +var traverse = require('traverse'); +var obj = [ 5, 6, -3, [ 7, 8, -2, 1 ], { f : 10, g : -13 } ]; + +traverse(obj).forEach(function (x) { + if (x < 0) this.update(x + 128); +}); + +console.dir(obj); +```` + +Output: + + [ 5, 6, 125, [ 7, 8, 126, 1 ], { f: 10, g: 115 } ] + +collect leaf nodes +------------------ + +leaves.js + +````javascript +var traverse = require('traverse'); + +var obj = { + a : [1,2,3], + b : 4, + c : [5,6], + d : { e : [7,8], f : 9 }, +}; + +var leaves = traverse(obj).reduce(function (acc, x) { + if (this.isLeaf) acc.push(x); + return acc; +}, []); + +console.dir(leaves); +```` + +Output: + + [ 1, 2, 3, 4, 5, 6, 7, 8, 9 ] + +scrub circular references +------------------------- + +scrub.js: + +````javascript +var traverse = require('traverse'); + +var obj = { a : 1, b : 2, c : [ 3, 4 ] }; +obj.c.push(obj); + +var scrubbed = traverse(obj).map(function (x) { + if (this.circular) this.remove() +}); +console.dir(scrubbed); +```` + +output: + + { a: 1, b: 2, c: [ 3, 4 ] } + +context +======= + +Each method that takes a callback has a context (its `this` object) with these +attributes: + +this.node +--------- + +The present node on the recursive walk + +this.path +--------- + +An array of string keys from the root to the present node + +this.parent +----------- + +The context of the node's parent. +This is `undefined` for the root node. + +this.key +-------- + +The name of the key of the present node in its parent. +This is `undefined` for the root node. + +this.isRoot, this.notRoot +------------------------- + +Whether the present node is the root node + +this.isLeaf, this.notLeaf +------------------------- + +Whether or not the present node is a leaf node (has no children) + +this.level +---------- + +Depth of the node within the traversal + +this.circular +------------- + +If the node equals one of its parents, the `circular` attribute is set to the +context of that parent and the traversal progresses no deeper. + +this.update(value, stopHere=false) +---------------------------------- + +Set a new value for the present node. + +All the elements in `value` will be recursively traversed unless `stopHere` is +true. + +this.remove(stopHere=false) +------------- + +Remove the current element from the output. If the node is in an Array it will +be spliced off. Otherwise it will be deleted from its parent. + +this.delete(stopHere=false) +------------- + +Delete the current element from its parent in the output. Calls `delete` even on +Arrays. + +this.before(fn) +--------------- + +Call this function before any of the children are traversed. + +You can assign into `this.keys` here to traverse in a custom order. + +this.after(fn) +-------------- + +Call this function after any of the children are traversed. + +this.pre(fn) +------------ + +Call this function before each of the children are traversed. + +this.post(fn) +------------- + +Call this function after each of the children are traversed. + +methods +======= + +.map(fn) +-------- + +Execute `fn` for each node in the object and return a new object with the +results of the walk. To update nodes in the result use `this.update(value)`. + +.forEach(fn) +------------ + +Execute `fn` for each node in the object but unlike `.map()`, when +`this.update()` is called it updates the object in-place. + +.reduce(fn, acc) +---------------- + +For each node in the object, perform a +[left-fold](http://en.wikipedia.org/wiki/Fold_(higher-order_function)) +with the return value of `fn(acc, node)`. + +If `acc` isn't specified, `acc` is set to the root object for the first step +and the root element is skipped. + +.paths() +-------- + +Return an `Array` of every possible non-cyclic path in the object. +Paths are `Array`s of string keys. + +.nodes() +-------- + +Return an `Array` of every node in the object. + +.clone() +-------- + +Create a deep clone of the object. + +install +======= + +Using [npm](http://npmjs.org) do: + + $ npm install traverse + +test +==== + +Using [expresso](http://github.com/visionmedia/expresso) do: + + $ expresso + + 100% wahoo, your stuff is not broken! + +in the browser +============== + +Use [browserify](https://github.com/substack/node-browserify) to run traverse in +the browser. + +traverse has been tested and works with: + +* Internet Explorer 5.5, 6.0, 7.0, 8.0, 9.0 +* Firefox 3.5 +* Chrome 6.0 +* Opera 10.6 +* Safari 5.0 diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/examples/json.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/examples/json.js new file mode 100755 index 0000000..50d612e --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/examples/json.js @@ -0,0 +1,16 @@ +var traverse = require('traverse'); + +var id = 54; +var callbacks = {}; +var obj = { moo : function () {}, foo : [2,3,4, function () {}] }; + +var scrubbed = traverse(obj).map(function (x) { + if (typeof x === 'function') { + callbacks[id] = { id : id, f : x, path : this.path }; + this.update('[Function]'); + id++; + } +}); + +console.dir(scrubbed); +console.dir(callbacks); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/examples/leaves.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/examples/leaves.js new file mode 100755 index 0000000..c1b310b --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/examples/leaves.js @@ -0,0 +1,15 @@ +var traverse = require('traverse'); + +var obj = { + a : [1,2,3], + b : 4, + c : [5,6], + d : { e : [7,8], f : 9 }, +}; + +var leaves = traverse(obj).reduce(function (acc, x) { + if (this.isLeaf) acc.push(x); + return acc; +}, []); + +console.dir(leaves); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/examples/negative.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/examples/negative.js new file mode 100755 index 0000000..78608a0 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/examples/negative.js @@ -0,0 +1,8 @@ +var traverse = require('traverse'); +var obj = [ 5, 6, -3, [ 7, 8, -2, 1 ], { f : 10, g : -13 } ]; + +traverse(obj).forEach(function (x) { + if (x < 0) this.update(x + 128); +}); + +console.dir(obj); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/examples/scrub.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/examples/scrub.js new file mode 100755 index 0000000..5d15b91 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/examples/scrub.js @@ -0,0 +1,10 @@ +// scrub out circular references +var traverse = require('traverse'); + +var obj = { a : 1, b : 2, c : [ 3, 4 ] }; +obj.c.push(obj); + +var scrubbed = traverse(obj).map(function (x) { + if (this.circular) this.remove() +}); +console.dir(scrubbed); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/examples/stringify.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/examples/stringify.js new file mode 100755 index 0000000..167b68b --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/examples/stringify.js @@ -0,0 +1,38 @@ +#!/usr/bin/env node +var traverse = require('traverse'); + +var obj = [ 'five', 6, -3, [ 7, 8, -2, 1 ], { f : 10, g : -13 } ]; + +var s = ''; +traverse(obj).forEach(function to_s (node) { + if (Array.isArray(node)) { + this.before(function () { s += '[' }); + this.post(function (child) { + if (!child.isLast) s += ','; + }); + this.after(function () { s += ']' }); + } + else if (typeof node == 'object') { + this.before(function () { s += '{' }); + this.pre(function (x, key) { + to_s(key); + s += ':'; + }); + this.post(function (child) { + if (!child.isLast) s += ','; + }); + this.after(function () { s += '}' }); + } + else if (typeof node == 'string') { + s += '"' + node.toString().replace(/"/g, '\\"') + '"'; + } + else if (typeof node == 'function') { + s += 'null'; + } + else { + s += node.toString(); + } +}); + +console.log('JSON.stringify: ' + JSON.stringify(obj)); +console.log('this stringify: ' + s); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/index.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/index.js new file mode 100644 index 0000000..038a1ad --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/index.js @@ -0,0 +1,267 @@ +module.exports = Traverse; +function Traverse (obj) { + if (!(this instanceof Traverse)) return new Traverse(obj); + this.value = obj; +} + +Traverse.prototype.get = function (ps) { + var node = this.value; + for (var i = 0; i < ps.length; i ++) { + var key = ps[i]; + if (!Object.hasOwnProperty.call(node, key)) { + node = undefined; + break; + } + node = node[key]; + } + return node; +}; + +Traverse.prototype.set = function (ps, value) { + var node = this.value; + for (var i = 0; i < ps.length - 1; i ++) { + var key = ps[i]; + if (!Object.hasOwnProperty.call(node, key)) node[key] = {}; + node = node[key]; + } + node[ps[i]] = value; + return value; +}; + +Traverse.prototype.map = function (cb) { + return walk(this.value, cb, true); +}; + +Traverse.prototype.forEach = function (cb) { + this.value = walk(this.value, cb, false); + return this.value; +}; + +Traverse.prototype.reduce = function (cb, init) { + var skip = arguments.length === 1; + var acc = skip ? this.value : init; + this.forEach(function (x) { + if (!this.isRoot || !skip) { + acc = cb.call(this, acc, x); + } + }); + return acc; +}; + +Traverse.prototype.paths = function () { + var acc = []; + this.forEach(function (x) { + acc.push(this.path); + }); + return acc; +}; + +Traverse.prototype.nodes = function () { + var acc = []; + this.forEach(function (x) { + acc.push(this.node); + }); + return acc; +}; + +Traverse.prototype.clone = function () { + var parents = [], nodes = []; + + return (function clone (src) { + for (var i = 0; i < parents.length; i++) { + if (parents[i] === src) { + return nodes[i]; + } + } + + if (typeof src === 'object' && src !== null) { + var dst = copy(src); + + parents.push(src); + nodes.push(dst); + + forEach(Object_keys(src), function (key) { + dst[key] = clone(src[key]); + }); + + parents.pop(); + nodes.pop(); + return dst; + } + else { + return src; + } + })(this.value); +}; + +function walk (root, cb, immutable) { + var path = []; + var parents = []; + var alive = true; + + return (function walker (node_) { + var node = immutable ? copy(node_) : node_; + var modifiers = {}; + + var keepGoing = true; + + var state = { + node : node, + node_ : node_, + path : [].concat(path), + parent : parents[parents.length - 1], + parents : parents, + key : path.slice(-1)[0], + isRoot : path.length === 0, + level : path.length, + circular : null, + update : function (x, stopHere) { + if (!state.isRoot) { + state.parent.node[state.key] = x; + } + state.node = x; + if (stopHere) keepGoing = false; + }, + 'delete' : function (stopHere) { + delete state.parent.node[state.key]; + if (stopHere) keepGoing = false; + }, + remove : function (stopHere) { + if (Array_isArray(state.parent.node)) { + state.parent.node.splice(state.key, 1); + } + else { + delete state.parent.node[state.key]; + } + if (stopHere) keepGoing = false; + }, + keys : null, + before : function (f) { modifiers.before = f }, + after : function (f) { modifiers.after = f }, + pre : function (f) { modifiers.pre = f }, + post : function (f) { modifiers.post = f }, + stop : function () { alive = false }, + block : function () { keepGoing = false } + }; + + if (!alive) return state; + + if (typeof node === 'object' && node !== null) { + state.keys = Object_keys(node); + + state.isLeaf = state.keys.length == 0; + + for (var i = 0; i < parents.length; i++) { + if (parents[i].node_ === node_) { + state.circular = parents[i]; + break; + } + } + } + else { + state.isLeaf = true; + } + + state.notLeaf = !state.isLeaf; + state.notRoot = !state.isRoot; + + // use return values to update if defined + var ret = cb.call(state, state.node); + if (ret !== undefined && state.update) state.update(ret); + + if (modifiers.before) modifiers.before.call(state, state.node); + + if (!keepGoing) return state; + + if (typeof state.node == 'object' + && state.node !== null && !state.circular) { + parents.push(state); + + forEach(state.keys, function (key, i) { + path.push(key); + + if (modifiers.pre) modifiers.pre.call(state, state.node[key], key); + + var child = walker(state.node[key]); + if (immutable && Object.hasOwnProperty.call(state.node, key)) { + state.node[key] = child.node; + } + + child.isLast = i == state.keys.length - 1; + child.isFirst = i == 0; + + if (modifiers.post) modifiers.post.call(state, child); + + path.pop(); + }); + parents.pop(); + } + + if (modifiers.after) modifiers.after.call(state, state.node); + + return state; + })(root).node; +} + +function copy (src) { + if (typeof src === 'object' && src !== null) { + var dst; + + if (Array_isArray(src)) { + dst = []; + } + else if (src instanceof Date) { + dst = new Date(src); + } + else if (src instanceof Boolean) { + dst = new Boolean(src); + } + else if (src instanceof Number) { + dst = new Number(src); + } + else if (src instanceof String) { + dst = new String(src); + } + else if (Object.create && Object.getPrototypeOf) { + dst = Object.create(Object.getPrototypeOf(src)); + } + else if (src.__proto__ || src.constructor.prototype) { + var proto = src.__proto__ || src.constructor.prototype || {}; + var T = function () {}; + T.prototype = proto; + dst = new T; + if (!dst.__proto__) dst.__proto__ = proto; + } + + forEach(Object_keys(src), function (key) { + dst[key] = src[key]; + }); + return dst; + } + else return src; +} + +var Object_keys = Object.keys || function keys (obj) { + var res = []; + for (var key in obj) res.push(key) + return res; +}; + +var Array_isArray = Array.isArray || function isArray (xs) { + return Object.prototype.toString.call(xs) === '[object Array]'; +}; + +var forEach = function (xs, fn) { + if (xs.forEach) return xs.forEach(fn) + else for (var i = 0; i < xs.length; i++) { + fn(xs[i], i, xs); + } +}; + +forEach(Object_keys(Traverse.prototype), function (key) { + Traverse[key] = function (obj) { + var args = [].slice.call(arguments, 1); + var t = Traverse(obj); + return t[key].apply(t, args); + }; +}); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/main.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/main.js new file mode 100755 index 0000000..d562d37 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/main.js @@ -0,0 +1,10 @@ +// scrub out circular references +var traverse = require('./index.js'); + +var obj = { a : 1, b : 2, c : [ 3, 4 ] }; +obj.c.push(obj); + +var scrubbed = traverse(obj).map(function (x) { + if (this.circular) this.remove() +}); +console.dir(scrubbed); diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/package.json b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/package.json new file mode 100644 index 0000000..9849825 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/package.json @@ -0,0 +1,54 @@ +{ + "name": "traverse", + "version": "0.5.2", + "description": "Traverse and transform objects by visiting every node on a recursive walk", + "author": { + "name": "James Halliday" + }, + "license": "MIT/X11", + "main": "./index", + "repository": { + "type": "git", + "url": "git://github.com/substack/js-traverse.git" + }, + "devDependencies": { + "expresso": "0.7.x" + }, + "scripts": { + "test": "expresso" + }, + "_npmJsonOpts": { + "file": "/home/substack/.npm/traverse/0.5.2/package/package.json", + "wscript": false, + "contributors": false, + "serverjs": false + }, + "_id": "traverse@0.5.2", + "dependencies": {}, + "engines": { + "node": "*" + }, + "_engineSupported": true, + "_npmVersion": "1.0.30", + "_nodeVersion": "v0.4.12", + "_defaultsLoaded": true, + "dist": { + "shasum": "e203c58d5f7f0e37db6e74c0acb929bb09b61d85", + "tarball": "http://registry.npmjs.org/traverse/-/traverse-0.5.2.tgz" + }, + "maintainers": [ + { + "name": "substack", + "email": "mail@substack.net" + } + ], + "directories": {}, + "_shasum": "e203c58d5f7f0e37db6e74c0acb929bb09b61d85", + "_from": "traverse@0.5.2", + "_resolved": "https://registry.npmjs.org/traverse/-/traverse-0.5.2.tgz", + "bugs": { + "url": "https://github.com/substack/js-traverse/issues" + }, + "readme": "ERROR: No README data found!", + "homepage": "https://github.com/substack/js-traverse" +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/circular.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/circular.js new file mode 100644 index 0000000..9162601 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/circular.js @@ -0,0 +1,115 @@ +var assert = require('assert'); +var Traverse = require('../'); +var deepEqual = require('./lib/deep_equal'); +var util = require('util'); + +exports.circular = function () { + var obj = { x : 3 }; + obj.y = obj; + var foundY = false; + Traverse(obj).forEach(function (x) { + if (this.path.join('') == 'y') { + assert.equal( + util.inspect(this.circular.node), + util.inspect(obj) + ); + foundY = true; + } + }); + assert.ok(foundY); +}; + +exports.deepCirc = function () { + var obj = { x : [ 1, 2, 3 ], y : [ 4, 5 ] }; + obj.y[2] = obj; + + var times = 0; + Traverse(obj).forEach(function (x) { + if (this.circular) { + assert.deepEqual(this.circular.path, []); + assert.deepEqual(this.path, [ 'y', 2 ]); + times ++; + } + }); + + assert.deepEqual(times, 1); +}; + +exports.doubleCirc = function () { + var obj = { x : [ 1, 2, 3 ], y : [ 4, 5 ] }; + obj.y[2] = obj; + obj.x.push(obj.y); + + var circs = []; + Traverse(obj).forEach(function (x) { + if (this.circular) { + circs.push({ circ : this.circular, self : this, node : x }); + } + }); + + assert.deepEqual(circs[0].self.path, [ 'x', 3, 2 ]); + assert.deepEqual(circs[0].circ.path, []); + + assert.deepEqual(circs[1].self.path, [ 'y', 2 ]); + assert.deepEqual(circs[1].circ.path, []); + + assert.deepEqual(circs.length, 2); +}; + +exports.circDubForEach = function () { + var obj = { x : [ 1, 2, 3 ], y : [ 4, 5 ] }; + obj.y[2] = obj; + obj.x.push(obj.y); + + Traverse(obj).forEach(function (x) { + if (this.circular) this.update('...'); + }); + + assert.deepEqual(obj, { x : [ 1, 2, 3, [ 4, 5, '...' ] ], y : [ 4, 5, '...' ] }); +}; + +exports.circDubMap = function () { + var obj = { x : [ 1, 2, 3 ], y : [ 4, 5 ] }; + obj.y[2] = obj; + obj.x.push(obj.y); + + var c = Traverse(obj).map(function (x) { + if (this.circular) { + this.update('...'); + } + }); + + assert.deepEqual(c, { x : [ 1, 2, 3, [ 4, 5, '...' ] ], y : [ 4, 5, '...' ] }); +}; + +exports.circClone = function () { + var obj = { x : [ 1, 2, 3 ], y : [ 4, 5 ] }; + obj.y[2] = obj; + obj.x.push(obj.y); + + var clone = Traverse.clone(obj); + assert.ok(obj !== clone); + + assert.ok(clone.y[2] === clone); + assert.ok(clone.y[2] !== obj); + assert.ok(clone.x[3][2] === clone); + assert.ok(clone.x[3][2] !== obj); + assert.deepEqual(clone.x.slice(0,3), [1,2,3]); + assert.deepEqual(clone.y.slice(0,2), [4,5]); +}; + +exports.circMapScrub = function () { + var obj = { a : 1, b : 2 }; + obj.c = obj; + + var scrubbed = Traverse(obj).map(function (node) { + if (this.circular) this.remove(); + }); + assert.deepEqual( + Object.keys(scrubbed).sort(), + [ 'a', 'b' ] + ); + assert.ok(deepEqual(scrubbed, { a : 1, b : 2 })); + + assert.equal(obj.c, obj); +}; diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/date.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/date.js new file mode 100644 index 0000000..4ca06dc --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/date.js @@ -0,0 +1,35 @@ +var assert = require('assert'); +var Traverse = require('../'); + +exports.dateEach = function () { + var obj = { x : new Date, y : 10, z : 5 }; + + var counts = {}; + + Traverse(obj).forEach(function (node) { + var t = (node instanceof Date && 'Date') || typeof node; + counts[t] = (counts[t] || 0) + 1; + }); + + assert.deepEqual(counts, { + object : 1, + Date : 1, + number : 2, + }); +}; + +exports.dateMap = function () { + var obj = { x : new Date, y : 10, z : 5 }; + + var res = Traverse(obj).map(function (node) { + if (typeof node === 'number') this.update(node + 100); + }); + + assert.ok(obj.x !== res.x); + assert.deepEqual(res, { + x : obj.x, + y : 110, + z : 105, + }); +}; + diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/equal.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/equal.js new file mode 100644 index 0000000..decc755 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/equal.js @@ -0,0 +1,220 @@ +var assert = require('assert'); +var traverse = require('../'); +var deepEqual = require('./lib/deep_equal'); + +exports.deepDates = function () { + assert.ok( + deepEqual( + { d : new Date, x : [ 1, 2, 3 ] }, + { d : new Date, x : [ 1, 2, 3 ] } + ), + 'dates should be equal' + ); + + var d0 = new Date; + setTimeout(function () { + assert.ok( + !deepEqual( + { d : d0, x : [ 1, 2, 3 ], }, + { d : new Date, x : [ 1, 2, 3 ] } + ), + 'microseconds should count in date equality' + ); + }, 5); +}; + +exports.deepCircular = function () { + var a = [1]; + a.push(a); // a = [ 1, *a ] + + var b = [1]; + b.push(a); // b = [ 1, [ 1, *a ] ] + + assert.ok( + !deepEqual(a, b), + 'circular ref mount points count towards equality' + ); + + var c = [1]; + c.push(c); // c = [ 1, *c ] + assert.ok( + deepEqual(a, c), + 'circular refs are structurally the same here' + ); + + var d = [1]; + d.push(a); // c = [ 1, [ 1, *d ] ] + assert.ok( + deepEqual(b, d), + 'non-root circular ref structural comparison' + ); +}; + +exports.deepInstances = function () { + assert.ok( + !deepEqual([ new Boolean(false) ], [ false ]), + 'boolean instances are not real booleans' + ); + + assert.ok( + !deepEqual([ new String('x') ], [ 'x' ]), + 'string instances are not real strings' + ); + + assert.ok( + !deepEqual([ new Number(4) ], [ 4 ]), + 'number instances are not real numbers' + ); + + assert.ok( + deepEqual([ new RegExp('x') ], [ /x/ ]), + 'regexp instances are real regexps' + ); + + assert.ok( + !deepEqual([ new RegExp(/./) ], [ /../ ]), + 'these regexps aren\'t the same' + ); + + assert.ok( + !deepEqual( + [ function (x) { return x * 2 } ], + [ function (x) { return x * 2 } ] + ), + 'functions with the same .toString() aren\'t necessarily the same' + ); + + var f = function (x) { return x * 2 }; + assert.ok( + deepEqual([ f ], [ f ]), + 'these functions are actually equal' + ); +}; + +exports.deepEqual = function () { + assert.ok( + !deepEqual([ 1, 2, 3 ], { 0 : 1, 1 : 2, 2 : 3 }), + 'arrays are not objects' + ); +}; + +exports.falsy = function () { + assert.ok( + !deepEqual([ undefined ], [ null ]), + 'null is not undefined!' + ); + + assert.ok( + !deepEqual([ null ], [ undefined ]), + 'undefined is not null!' + ); + + assert.ok( + !deepEqual( + { a : 1, b : 2, c : [ 3, undefined, 5 ] }, + { a : 1, b : 2, c : [ 3, null, 5 ] } + ), + 'undefined is not null, however deeply!' + ); + + assert.ok( + !deepEqual( + { a : 1, b : 2, c : [ 3, undefined, 5 ] }, + { a : 1, b : 2, c : [ 3, null, 5 ] } + ), + 'null is not undefined, however deeply!' + ); + + assert.ok( + !deepEqual( + { a : 1, b : 2, c : [ 3, undefined, 5 ] }, + { a : 1, b : 2, c : [ 3, null, 5 ] } + ), + 'null is not undefined, however deeply!' + ); +}; + +exports.deletedArrayEqual = function () { + var xs = [ 1, 2, 3, 4 ]; + delete xs[2]; + + var ys = Object.create(Array.prototype); + ys[0] = 1; + ys[1] = 2; + ys[3] = 4; + + assert.ok( + deepEqual(xs, ys), + 'arrays with deleted elements are only equal to' + + ' arrays with similarly deleted elements' + ); + + assert.ok( + !deepEqual(xs, [ 1, 2, undefined, 4 ]), + 'deleted array elements cannot be undefined' + ); + + assert.ok( + !deepEqual(xs, [ 1, 2, null, 4 ]), + 'deleted array elements cannot be null' + ); +}; + +exports.deletedObjectEqual = function () { + var obj = { a : 1, b : 2, c : 3 }; + delete obj.c; + + assert.ok( + deepEqual(obj, { a : 1, b : 2 }), + 'deleted object elements should not show up' + ); + + assert.ok( + !deepEqual(obj, { a : 1, b : 2, c : undefined }), + 'deleted object elements are not undefined' + ); + + assert.ok( + !deepEqual(obj, { a : 1, b : 2, c : null }), + 'deleted object elements are not null' + ); +}; + +exports.emptyKeyEqual = function () { + assert.ok(!deepEqual( + { a : 1 }, { a : 1, '' : 55 } + )); +}; + +exports.deepArguments = function () { + assert.ok( + !deepEqual( + [ 4, 5, 6 ], + (function () { return arguments })(4, 5, 6) + ), + 'arguments are not arrays' + ); + + assert.ok( + deepEqual( + (function () { return arguments })(4, 5, 6), + (function () { return arguments })(4, 5, 6) + ), + 'arguments should equal' + ); +}; + +exports.deepUn = function () { + assert.ok(!deepEqual({ a : 1, b : 2 }, undefined)); + assert.ok(!deepEqual({ a : 1, b : 2 }, {})); + assert.ok(!deepEqual(undefined, { a : 1, b : 2 })); + assert.ok(!deepEqual({}, { a : 1, b : 2 })); + assert.ok(deepEqual(undefined, undefined)); + assert.ok(deepEqual(null, null)); + assert.ok(!deepEqual(undefined, null)); +}; + +exports.deepLevels = function () { + var xs = [ 1, 2, [ 3, 4, [ 5, 6 ] ] ]; + assert.ok(!deepEqual(xs, [])); +}; diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/instance.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/instance.js new file mode 100644 index 0000000..8d73525 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/instance.js @@ -0,0 +1,17 @@ +var assert = require('assert'); +var Traverse = require('../'); +var EventEmitter = require('events').EventEmitter; + +exports['check instanceof on node elems'] = function () { + + var counts = { emitter : 0 }; + + Traverse([ new EventEmitter, 3, 4, { ev : new EventEmitter }]) + .forEach(function (node) { + if (node instanceof EventEmitter) counts.emitter ++; + }) + ; + + assert.equal(counts.emitter, 2); +}; + diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/interface.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/interface.js new file mode 100644 index 0000000..fce5bf9 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/interface.js @@ -0,0 +1,42 @@ +var assert = require('assert'); +var Traverse = require('../'); + +exports['interface map'] = function () { + var obj = { a : [ 5,6,7 ], b : { c : [8] } }; + + assert.deepEqual( + Traverse.paths(obj) + .sort() + .map(function (path) { return path.join('/') }) + .slice(1) + .join(' ') + , + 'a a/0 a/1 a/2 b b/c b/c/0' + ); + + assert.deepEqual( + Traverse.nodes(obj), + [ + { a: [ 5, 6, 7 ], b: { c: [ 8 ] } }, + [ 5, 6, 7 ], 5, 6, 7, + { c: [ 8 ] }, [ 8 ], 8 + ] + ); + + assert.deepEqual( + Traverse.map(obj, function (node) { + if (typeof node == 'number') { + return node + 1000; + } + else if (Array.isArray(node)) { + return node.join(' '); + } + }), + { a: '5 6 7', b: { c: '8' } } + ); + + var nodes = 0; + Traverse.forEach(obj, function (node) { nodes ++ }); + assert.deepEqual(nodes, 8); +}; + diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/json.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/json.js new file mode 100644 index 0000000..0a04529 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/json.js @@ -0,0 +1,47 @@ +var assert = require('assert'); +var Traverse = require('../'); + +exports['json test'] = function () { + var id = 54; + var callbacks = {}; + var obj = { moo : function () {}, foo : [2,3,4, function () {}] }; + + var scrubbed = Traverse(obj).map(function (x) { + if (typeof x === 'function') { + callbacks[id] = { id : id, f : x, path : this.path }; + this.update('[Function]'); + id++; + } + }); + + assert.equal( + scrubbed.moo, '[Function]', + 'obj.moo replaced with "[Function]"' + ); + + assert.equal( + scrubbed.foo[3], '[Function]', + 'obj.foo[3] replaced with "[Function]"' + ); + + assert.deepEqual(scrubbed, { + moo : '[Function]', + foo : [ 2, 3, 4, "[Function]" ] + }, 'Full JSON string matches'); + + assert.deepEqual( + typeof obj.moo, 'function', + 'Original obj.moo still a function' + ); + + assert.deepEqual( + typeof obj.foo[3], 'function', + 'Original obj.foo[3] still a function' + ); + + assert.deepEqual(callbacks, { + 54: { id: 54, f : obj.moo, path: [ 'moo' ] }, + 55: { id: 55, f : obj.foo[3], path: [ 'foo', '3' ] }, + }, 'Check the generated callbacks list'); +}; + diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/keys.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/keys.js new file mode 100644 index 0000000..7ecd545 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/keys.js @@ -0,0 +1,29 @@ +var assert = require('assert'); +var Traverse = require('../'); + +exports['sort test'] = function () { + var acc = []; + Traverse({ + a: 30, + b: 22, + id: 9 + }).forEach(function (node) { + if ((! Array.isArray(node)) && typeof node === 'object') { + this.before(function(node) { + this.keys = Object.keys(node); + this.keys.sort(function(a, b) { + a = [a === "id" ? 0 : 1, a]; + b = [b === "id" ? 0 : 1, b]; + return a < b ? -1 : a > b ? 1 : 0; + }); + }); + } + if (this.isLeaf) acc.push(node); + }); + + assert.equal( + acc.join(' '), + '9 30 22', + 'Traversal in a custom order' + ); +}; diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/leaves.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/leaves.js new file mode 100644 index 0000000..e520b72 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/leaves.js @@ -0,0 +1,21 @@ +var assert = require('assert'); +var Traverse = require('../'); + +exports['leaves test'] = function () { + var acc = []; + Traverse({ + a : [1,2,3], + b : 4, + c : [5,6], + d : { e : [7,8], f : 9 } + }).forEach(function (x) { + if (this.isLeaf) acc.push(x); + }); + + assert.equal( + acc.join(' '), + '1 2 3 4 5 6 7 8 9', + 'Traversal in the right(?) order' + ); +}; + diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/lib/deep_equal.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/lib/deep_equal.js new file mode 100644 index 0000000..4fa07bb --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/lib/deep_equal.js @@ -0,0 +1,92 @@ +var traverse = require('../../'); + +module.exports = function (a, b) { + if (arguments.length !== 2) { + throw new Error( + 'deepEqual requires exactly two objects to compare against' + ); + } + + var equal = true; + var node = b; + + traverse(a).forEach(function (y) { + var notEqual = (function () { + equal = false; + //this.stop(); + return undefined; + }).bind(this); + + //if (node === undefined || node === null) return notEqual(); + + if (!this.isRoot) { + /* + if (!Object.hasOwnProperty.call(node, this.key)) { + return notEqual(); + } + */ + if (typeof node !== 'object') return notEqual(); + node = node[this.key]; + } + + var x = node; + + this.post(function () { + node = x; + }); + + var toS = function (o) { + return Object.prototype.toString.call(o); + }; + + if (this.circular) { + if (traverse(b).get(this.circular.path) !== x) notEqual(); + } + else if (typeof x !== typeof y) { + notEqual(); + } + else if (x === null || y === null || x === undefined || y === undefined) { + if (x !== y) notEqual(); + } + else if (x.__proto__ !== y.__proto__) { + notEqual(); + } + else if (x === y) { + // nop + } + else if (typeof x === 'function') { + if (x instanceof RegExp) { + // both regexps on account of the __proto__ check + if (x.toString() != y.toString()) notEqual(); + } + else if (x !== y) notEqual(); + } + else if (typeof x === 'object') { + if (toS(y) === '[object Arguments]' + || toS(x) === '[object Arguments]') { + if (toS(x) !== toS(y)) { + notEqual(); + } + } + else if (x instanceof Date || y instanceof Date) { + if (!(x instanceof Date) || !(y instanceof Date) + || x.getTime() !== y.getTime()) { + notEqual(); + } + } + else { + var kx = Object.keys(x); + var ky = Object.keys(y); + if (kx.length !== ky.length) return notEqual(); + for (var i = 0; i < kx.length; i++) { + var k = kx[i]; + if (!Object.hasOwnProperty.call(y, k)) { + notEqual(); + } + } + } + } + }); + + return equal; +}; diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/mutability.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/mutability.js new file mode 100644 index 0000000..2236f56 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/mutability.js @@ -0,0 +1,252 @@ +var assert = require('assert'); +var Traverse = require('../'); +var deepEqual = require('./lib/deep_equal'); + +exports.mutate = function () { + var obj = { a : 1, b : 2, c : [ 3, 4 ] }; + var res = Traverse(obj).forEach(function (x) { + if (typeof x === 'number' && x % 2 === 0) { + this.update(x * 10); + } + }); + assert.deepEqual(obj, res); + assert.deepEqual(obj, { a : 1, b : 20, c : [ 3, 40 ] }); +}; + +exports.mutateT = function () { + var obj = { a : 1, b : 2, c : [ 3, 4 ] }; + var res = Traverse.forEach(obj, function (x) { + if (typeof x === 'number' && x % 2 === 0) { + this.update(x * 10); + } + }); + assert.deepEqual(obj, res); + assert.deepEqual(obj, { a : 1, b : 20, c : [ 3, 40 ] }); +}; + +exports.map = function () { + var obj = { a : 1, b : 2, c : [ 3, 4 ] }; + var res = Traverse(obj).map(function (x) { + if (typeof x === 'number' && x % 2 === 0) { + this.update(x * 10); + } + }); + assert.deepEqual(obj, { a : 1, b : 2, c : [ 3, 4 ] }); + assert.deepEqual(res, { a : 1, b : 20, c : [ 3, 40 ] }); +}; + +exports.mapT = function () { + var obj = { a : 1, b : 2, c : [ 3, 4 ] }; + var res = Traverse.map(obj, function (x) { + if (typeof x === 'number' && x % 2 === 0) { + this.update(x * 10); + } + }); + assert.deepEqual(obj, { a : 1, b : 2, c : [ 3, 4 ] }); + assert.deepEqual(res, { a : 1, b : 20, c : [ 3, 40 ] }); +}; + +exports.clone = function () { + var obj = { a : 1, b : 2, c : [ 3, 4 ] }; + var res = Traverse(obj).clone(); + assert.deepEqual(obj, res); + assert.ok(obj !== res); + obj.a ++; + assert.deepEqual(res.a, 1); + obj.c.push(5); + assert.deepEqual(res.c, [ 3, 4 ]); +}; + +exports.cloneT = function () { + var obj = { a : 1, b : 2, c : [ 3, 4 ] }; + var res = Traverse.clone(obj); + assert.deepEqual(obj, res); + assert.ok(obj !== res); + obj.a ++; + assert.deepEqual(res.a, 1); + obj.c.push(5); + assert.deepEqual(res.c, [ 3, 4 ]); +}; + +exports.reduce = function () { + var obj = { a : 1, b : 2, c : [ 3, 4 ] }; + var res = Traverse(obj).reduce(function (acc, x) { + if (this.isLeaf) acc.push(x); + return acc; + }, []); + assert.deepEqual(obj, { a : 1, b : 2, c : [ 3, 4 ] }); + assert.deepEqual(res, [ 1, 2, 3, 4 ]); +}; + +exports.reduceInit = function () { + var obj = { a : 1, b : 2, c : [ 3, 4 ] }; + var res = Traverse(obj).reduce(function (acc, x) { + if (this.isRoot) assert.fail('got root'); + return acc; + }); + assert.deepEqual(obj, { a : 1, b : 2, c : [ 3, 4 ] }); + assert.deepEqual(res, obj); +}; + +exports.remove = function () { + var obj = { a : 1, b : 2, c : [ 3, 4 ] }; + Traverse(obj).forEach(function (x) { + if (this.isLeaf && x % 2 == 0) this.remove(); + }); + + assert.deepEqual(obj, { a : 1, c : [ 3 ] }); +}; + +exports.removeNoStop = function() { + var obj = { a : 1, b : 2, c : { d: 3, e: 4 }, f: 5 }; + + var keys = []; + Traverse(obj).forEach(function (x) { + keys.push(this.key) + if (this.key == 'c') this.remove(); + }); + + assert.deepEqual(keys, [undefined, 'a', 'b', 'c', 'd', 'e', 'f']) +} + +exports.removeStop = function() { + var obj = { a : 1, b : 2, c : { d: 3, e: 4 }, f: 5 }; + + var keys = []; + Traverse(obj).forEach(function (x) { + keys.push(this.key) + if (this.key == 'c') this.remove(true); + }); + + assert.deepEqual(keys, [undefined, 'a', 'b', 'c', 'f']) +} + +exports.removeMap = function () { + var obj = { a : 1, b : 2, c : [ 3, 4 ] }; + var res = Traverse(obj).map(function (x) { + if (this.isLeaf && x % 2 == 0) this.remove(); + }); + + assert.deepEqual(obj, { a : 1, b : 2, c : [ 3, 4 ] }); + assert.deepEqual(res, { a : 1, c : [ 3 ] }); +}; + +exports.delete = function () { + var obj = { a : 1, b : 2, c : [ 3, 4 ] }; + Traverse(obj).forEach(function (x) { + if (this.isLeaf && x % 2 == 0) this.delete(); + }); + + assert.ok(!deepEqual( + obj, { a : 1, c : [ 3, undefined ] } + )); + + assert.ok(deepEqual( + obj, { a : 1, c : [ 3 ] } + )); + + assert.ok(!deepEqual( + obj, { a : 1, c : [ 3, null ] } + )); +}; + +exports.deleteNoStop = function() { + var obj = { a : 1, b : 2, c : { d: 3, e: 4 } }; + + var keys = []; + Traverse(obj).forEach(function (x) { + keys.push(this.key) + if (this.key == 'c') this.delete(); + }); + + assert.deepEqual(keys, [undefined, 'a', 'b', 'c', 'd', 'e']) +} + +exports.deleteStop = function() { + var obj = { a : 1, b : 2, c : { d: 3, e: 4 } }; + + var keys = []; + Traverse(obj).forEach(function (x) { + keys.push(this.key) + if (this.key == 'c') this.delete(true); + }); + + assert.deepEqual(keys, [undefined, 'a', 'b', 'c']) +} + +exports.deleteRedux = function () { + var obj = { a : 1, b : 2, c : [ 3, 4, 5 ] }; + Traverse(obj).forEach(function (x) { + if (this.isLeaf && x % 2 == 0) this.delete(); + }); + + assert.ok(!deepEqual( + obj, { a : 1, c : [ 3, undefined, 5 ] } + )); + + assert.ok(deepEqual( + obj, { a : 1, c : [ 3 ,, 5 ] } + )); + + assert.ok(!deepEqual( + obj, { a : 1, c : [ 3, null, 5 ] } + )); + + assert.ok(!deepEqual( + obj, { a : 1, c : [ 3, 5 ] } + )); +}; + +exports.deleteMap = function () { + var obj = { a : 1, b : 2, c : [ 3, 4 ] }; + var res = Traverse(obj).map(function (x) { + if (this.isLeaf && x % 2 == 0) this.delete(); + }); + + assert.ok(deepEqual( + obj, + { a : 1, b : 2, c : [ 3, 4 ] } + )); + + var xs = [ 3, 4 ]; + delete xs[1]; + + assert.ok(deepEqual( + res, { a : 1, c : xs } + )); + + assert.ok(deepEqual( + res, { a : 1, c : [ 3, ] } + )); + + assert.ok(deepEqual( + res, { a : 1, c : [ 3 ] } + )); +}; + +exports.deleteMapRedux = function () { + var obj = { a : 1, b : 2, c : [ 3, 4, 5 ] }; + var res = Traverse(obj).map(function (x) { + if (this.isLeaf && x % 2 == 0) this.delete(); + }); + + assert.ok(deepEqual( + obj, + { a : 1, b : 2, c : [ 3, 4, 5 ] } + )); + + var xs = [ 3, 4, 5 ]; + delete xs[1]; + + assert.ok(deepEqual( + res, { a : 1, c : xs } + )); + + assert.ok(!deepEqual( + res, { a : 1, c : [ 3, 5 ] } + )); + + assert.ok(deepEqual( + res, { a : 1, c : [ 3 ,, 5 ] } + )); +}; diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/negative.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/negative.js new file mode 100644 index 0000000..f92dfb0 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/negative.js @@ -0,0 +1,20 @@ +var Traverse = require('../'); +var assert = require('assert'); + +exports['negative update test'] = function () { + var obj = [ 5, 6, -3, [ 7, 8, -2, 1 ], { f : 10, g : -13 } ]; + var fixed = Traverse.map(obj, function (x) { + if (x < 0) this.update(x + 128); + }); + + assert.deepEqual(fixed, + [ 5, 6, 125, [ 7, 8, 126, 1 ], { f: 10, g: 115 } ], + 'Negative values += 128' + ); + + assert.deepEqual(obj, + [ 5, 6, -3, [ 7, 8, -2, 1 ], { f: 10, g: -13 } ], + 'Original references not modified' + ); +} + diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/obj.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/obj.js new file mode 100644 index 0000000..d46fd38 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/obj.js @@ -0,0 +1,15 @@ +var assert = require('assert'); +var Traverse = require('../'); + +exports['traverse an object with nested functions'] = function () { + var to = setTimeout(function () { + assert.fail('never ran'); + }, 1000); + + function Cons (x) { + clearTimeout(to); + assert.equal(x, 10); + }; + Traverse(new Cons(10)); +}; + diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/siblings.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/siblings.js new file mode 100644 index 0000000..99c0f1b --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/siblings.js @@ -0,0 +1,35 @@ +var assert = require('assert'); +var traverse = require('../'); + +exports.siblings = function () { + var obj = { a : 1, b : 2, c : [ 4, 5, 6 ] }; + + var res = traverse(obj).reduce(function (acc, x) { + var p = '/' + this.path.join('/'); + if (this.parent) { + acc[p] = { + siblings : this.parent.keys, + key : this.key, + index : this.parent.keys.indexOf(this.key) + }; + } + else { + acc[p] = { + siblings : [], + key : this.key, + index : -1 + } + } + return acc; + }, {}); + + assert.deepEqual(res, { + '/' : { siblings : [], key : undefined, index : -1 }, + '/a' : { siblings : [ 'a', 'b', 'c' ], key : 'a', index : 0 }, + '/b' : { siblings : [ 'a', 'b', 'c' ], key : 'b', index : 1 }, + '/c' : { siblings : [ 'a', 'b', 'c' ], key : 'c', index : 2 }, + '/c/0' : { siblings : [ '0', '1', '2' ], key : '0', index : 0 }, + '/c/1' : { siblings : [ '0', '1', '2' ], key : '1', index : 1 }, + '/c/2' : { siblings : [ '0', '1', '2' ], key : '2', index : 2 } + }); +}; diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/stop.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/stop.js new file mode 100644 index 0000000..3529847 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/stop.js @@ -0,0 +1,41 @@ +var assert = require('assert'); +var traverse = require('../'); + +exports.stop = function () { + var visits = 0; + traverse('abcdefghij'.split('')).forEach(function (node) { + if (typeof node === 'string') { + visits ++; + if (node === 'e') this.stop() + } + }); + + assert.equal(visits, 5); +}; + +exports.stopMap = function () { + var s = traverse('abcdefghij'.split('')).map(function (node) { + if (typeof node === 'string') { + if (node === 'e') this.stop() + return node.toUpperCase(); + } + }).join(''); + + assert.equal(s, 'ABCDEfghij'); +}; + +exports.stopReduce = function () { + var obj = { + a : [ 4, 5 ], + b : [ 6, [ 7, 8, 9 ] ] + }; + var xs = traverse(obj).reduce(function (acc, node) { + if (this.isLeaf) { + if (node === 7) this.stop(); + else acc.push(node) + } + return acc; + }, []); + + assert.deepEqual(xs, [ 4, 5, 6 ]); +}; diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/stringify.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/stringify.js new file mode 100644 index 0000000..932f5d3 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/stringify.js @@ -0,0 +1,36 @@ +var assert = require('assert'); +var Traverse = require('../'); + +exports.stringify = function () { + var obj = [ 5, 6, -3, [ 7, 8, -2, 1 ], { f : 10, g : -13 } ]; + + var s = ''; + Traverse(obj).forEach(function (node) { + if (Array.isArray(node)) { + this.before(function () { s += '[' }); + this.post(function (child) { + if (!child.isLast) s += ','; + }); + this.after(function () { s += ']' }); + } + else if (typeof node == 'object') { + this.before(function () { s += '{' }); + this.pre(function (x, key) { + s += '"' + key + '"' + ':'; + }); + this.post(function (child) { + if (!child.isLast) s += ','; + }); + this.after(function () { s += '}' }); + } + else if (typeof node == 'function') { + s += 'null'; + } + else { + s += node.toString(); + } + }); + + assert.equal(s, JSON.stringify(obj)); +} + diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/subexpr.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/subexpr.js new file mode 100644 index 0000000..a217beb --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/subexpr.js @@ -0,0 +1,34 @@ +var traverse = require('../'); +var assert = require('assert'); + +exports.subexpr = function () { + var obj = [ 'a', 4, 'b', 5, 'c', 6 ]; + var r = traverse(obj).map(function (x) { + if (typeof x === 'number') { + this.update([ x - 0.1, x, x + 0.1 ], true); + } + }); + + assert.deepEqual(obj, [ 'a', 4, 'b', 5, 'c', 6 ]); + assert.deepEqual(r, [ + 'a', [ 3.9, 4, 4.1 ], + 'b', [ 4.9, 5, 5.1 ], + 'c', [ 5.9, 6, 6.1 ], + ]); +}; + +exports.block = function () { + var obj = [ [ 1 ], [ 2 ], [ 3 ] ]; + var r = traverse(obj).map(function (x) { + if (Array.isArray(x) && !this.isRoot) { + if (x[0] === 5) this.block() + else this.update([ [ x[0] + 1 ] ]) + } + }); + + assert.deepEqual(r, [ + [ [ [ [ [ 5 ] ] ] ] ], + [ [ [ [ 5 ] ] ] ], + [ [ [ 5 ] ] ], + ]); +}; diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/super_deep.js b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/super_deep.js new file mode 100644 index 0000000..acac2fd --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse/test/super_deep.js @@ -0,0 +1,55 @@ +var assert = require('assert'); +var traverse = require('../'); +var deepEqual = require('./lib/deep_equal'); + +exports.super_deep = function () { + var util = require('util'); + var a0 = make(); + var a1 = make(); + assert.ok(deepEqual(a0, a1)); + + a0.c.d.moo = true; + assert.ok(!deepEqual(a0, a1)); + + a1.c.d.moo = true; + assert.ok(deepEqual(a0, a1)); + + // TODO: this one + //a0.c.a = a1; + //assert.ok(!deepEqual(a0, a1)); +}; + +function make () { + var a = { self : 'a' }; + var b = { self : 'b' }; + var c = { self : 'c' }; + var d = { self : 'd' }; + var e = { self : 'e' }; + + a.a = a; + a.b = b; + a.c = c; + + b.a = a; + b.b = b; + b.c = c; + + c.a = a; + c.b = b; + c.c = c; + c.d = d; + + d.a = a; + d.b = b; + d.c = c; + d.d = d; + d.e = e; + + e.a = a; + e.b = b; + e.c = c; + e.d = d; + e.e = e; + + return a; +} diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/uglify-js/.npmignore b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/uglify-js/.npmignore new file mode 100644 index 0000000..d97eaa0 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/uglify-js/.npmignore @@ -0,0 +1,4 @@ +.DS_Store +.tmp*~ +*.local.* +.pinf-* \ No newline at end of file diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/uglify-js/README.html b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/uglify-js/README.html new file mode 100644 index 0000000..8f5223f --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/uglify-js/README.html @@ -0,0 +1,1026 @@ + + + + +UglifyJS -- a JavaScript parser/compressor/beautifier + + + + + + + + + + + + +
    + +

    UglifyJS – a JavaScript parser/compressor/beautifier

    + + + + +
    +

    1 UglifyJS — a JavaScript parser/compressor/beautifier

    +
    + + +

    +This package implements a general-purpose JavaScript +parser/compressor/beautifier toolkit. It is developed on NodeJS, but it +should work on any JavaScript platform supporting the CommonJS module system +(and if your platform of choice doesn't support CommonJS, you can easily +implement it, or discard the exports.* lines from UglifyJS sources). +

    +

    +The tokenizer/parser generates an abstract syntax tree from JS code. You +can then traverse the AST to learn more about the code, or do various +manipulations on it. This part is implemented in parse-js.js and it's a +port to JavaScript of the excellent parse-js Common Lisp library from Marijn Haverbeke. +

    +

    +( See cl-uglify-js if you're looking for the Common Lisp version of +UglifyJS. ) +

    +

    +The second part of this package, implemented in process.js, inspects and +manipulates the AST generated by the parser to provide the following: +

    +
      +
    • +ability to re-generate JavaScript code from the AST. Optionally +indented—you can use this if you want to “beautify” a program that has +been compressed, so that you can inspect the source. But you can also run +our code generator to print out an AST without any whitespace, so you +achieve compression as well. + +
    • +
    • +shorten variable names (usually to single characters). Our mangler will +analyze the code and generate proper variable names, depending on scope +and usage, and is smart enough to deal with globals defined elsewhere, or +with eval() calls or with{} statements. In short, if eval() or +with{} are used in some scope, then all variables in that scope and any +variables in the parent scopes will remain unmangled, and any references +to such variables remain unmangled as well. + +
    • +
    • +various small optimizations that may lead to faster code but certainly +lead to smaller code. Where possible, we do the following: + +
        +
      • +foo["bar"] ==> foo.bar + +
      • +
      • +remove block brackets {} + +
      • +
      • +join consecutive var declarations: +var a = 10; var b = 20; ==> var a=10,b=20; + +
      • +
      • +resolve simple constant expressions: 1 +2 * 3 ==> 7. We only do the +replacement if the result occupies less bytes; for example 1/3 would +translate to 0.333333333333, so in this case we don't replace it. + +
      • +
      • +consecutive statements in blocks are merged into a sequence; in many +cases, this leaves blocks with a single statement, so then we can remove +the block brackets. + +
      • +
      • +various optimizations for IF statements: + +
          +
        • +if (foo) bar(); else baz(); ==> foo?bar():baz(); +
        • +
        • +if (!foo) bar(); else baz(); ==> foo?baz():bar(); +
        • +
        • +if (foo) bar(); ==> foo&&bar(); +
        • +
        • +if (!foo) bar(); ==> foo||bar(); +
        • +
        • +if (foo) return bar(); else return baz(); ==> return foo?bar():baz(); +
        • +
        • +if (foo) return bar(); else something(); ==> {if(foo)return bar();something()} + +
        • +
        +
      • +
      • +remove some unreachable code and warn about it (code that follows a +return, throw, break or continue statement, except +function/variable declarations). + +
      • +
      • +act a limited version of a pre-processor (c.f. the pre-processor of +C/C++) to allow you to safely replace selected global symbols with +specified values. When combined with the optimisations above this can +make UglifyJS operate slightly more like a compilation process, in +that when certain symbols are replaced by constant values, entire code +blocks may be optimised away as unreachable. +
      • +
      +
    • +
    + + + +
    + +
    +

    1.1 Unsafe transformations

    +
    + + +

    +The following transformations can in theory break code, although they're +probably safe in most practical cases. To enable them you need to pass the +--unsafe flag. +

    + +
    + +
    +

    1.1.1 Calls involving the global Array constructor

    +
    + + +

    +The following transformations occur: +

    + + + +
    new Array(1, 2, 3, 4)  => [1,2,3,4]
    +Array(a, b, c)         => [a,b,c]
    +new Array(5)           => Array(5)
    +new Array(a)           => Array(a)
    +
    + + + +

    +These are all safe if the Array name isn't redefined. JavaScript does allow +one to globally redefine Array (and pretty much everything, in fact) but I +personally don't see why would anyone do that. +

    +

    +UglifyJS does handle the case where Array is redefined locally, or even +globally but with a function or var declaration. Therefore, in the +following cases UglifyJS doesn't touch calls or instantiations of Array: +

    + + + +
    // case 1.  globally declared variable
    +  var Array;
    +  new Array(1, 2, 3);
    +  Array(a, b);
    +
    +  // or (can be declared later)
    +  new Array(1, 2, 3);
    +  var Array;
    +
    +  // or (can be a function)
    +  new Array(1, 2, 3);
    +  function Array() { ... }
    +
    +// case 2.  declared in a function
    +  (function(){
    +    a = new Array(1, 2, 3);
    +    b = Array(5, 6);
    +    var Array;
    +  })();
    +
    +  // or
    +  (function(Array){
    +    return Array(5, 6, 7);
    +  })();
    +
    +  // or
    +  (function(){
    +    return new Array(1, 2, 3, 4);
    +    function Array() { ... }
    +  })();
    +
    +  // etc.
    +
    + + + +
    + +
    + +
    +

    1.1.2 obj.toString() ==> obj+“”

    +
    + + +
    +
    + +
    + +
    +

    1.2 Install (NPM)

    +
    + + +

    +UglifyJS is now available through NPM — npm install uglify-js should do +the job. +

    +
    + +
    + +
    +

    1.3 Install latest code from GitHub

    +
    + + + + + +
    ## clone the repository
    +mkdir -p /where/you/wanna/put/it
    +cd /where/you/wanna/put/it
    +git clone git://github.com/mishoo/UglifyJS.git
    +
    +## make the module available to Node
    +mkdir -p ~/.node_libraries/
    +cd ~/.node_libraries/
    +ln -s /where/you/wanna/put/it/UglifyJS/uglify-js.js
    +
    +## and if you want the CLI script too:
    +mkdir -p ~/bin
    +cd ~/bin
    +ln -s /where/you/wanna/put/it/UglifyJS/bin/uglifyjs
    +  # (then add ~/bin to your $PATH if it's not there already)
    +
    + + + +
    + +
    + +
    +

    1.4 Usage

    +
    + + +

    +There is a command-line tool that exposes the functionality of this library +for your shell-scripting needs: +

    + + + +
    uglifyjs [ options... ] [ filename ]
    +
    + + + +

    +filename should be the last argument and should name the file from which +to read the JavaScript code. If you don't specify it, it will read code +from STDIN. +

    +

    +Supported options: +

    +
      +
    • +-b or --beautify — output indented code; when passed, additional +options control the beautifier: + +
        +
      • +-i N or --indent N — indentation level (number of spaces) + +
      • +
      • +-q or --quote-keys — quote keys in literal objects (by default, +only keys that cannot be identifier names will be quotes). + +
      • +
      +
    • +
    • +--ascii — pass this argument to encode non-ASCII characters as +\uXXXX sequences. By default UglifyJS won't bother to do it and will +output Unicode characters instead. (the output is always encoded in UTF8, +but if you pass this option you'll only get ASCII). + +
    • +
    • +-nm or --no-mangle — don't mangle variable names + +
    • +
    • +-ns or --no-squeeze — don't call ast_squeeze() (which does various +optimizations that result in smaller, less readable code). + +
    • +
    • +-mt or --mangle-toplevel — mangle names in the toplevel scope too +(by default we don't do this). + +
    • +
    • +--no-seqs — when ast_squeeze() is called (thus, unless you pass +--no-squeeze) it will reduce consecutive statements in blocks into a +sequence. For example, "a = 10; b = 20; foo();" will be written as +"a=10,b=20,foo();". In various occasions, this allows us to discard the +block brackets (since the block becomes a single statement). This is ON +by default because it seems safe and saves a few hundred bytes on some +libs that I tested it on, but pass --no-seqs to disable it. + +
    • +
    • +--no-dead-code — by default, UglifyJS will remove code that is +obviously unreachable (code that follows a return, throw, break or +continue statement and is not a function/variable declaration). Pass +this option to disable this optimization. + +
    • +
    • +-nc or --no-copyright — by default, uglifyjs will keep the initial +comment tokens in the generated code (assumed to be copyright information +etc.). If you pass this it will discard it. + +
    • +
    • +-o filename or --output filename — put the result in filename. If +this isn't given, the result goes to standard output (or see next one). + +
    • +
    • +--overwrite — if the code is read from a file (not from STDIN) and you +pass --overwrite then the output will be written in the same file. + +
    • +
    • +--ast — pass this if you want to get the Abstract Syntax Tree instead +of JavaScript as output. Useful for debugging or learning more about the +internals. + +
    • +
    • +-v or --verbose — output some notes on STDERR (for now just how long +each operation takes). + +
    • +
    • +-d SYMBOL[=VALUE] or --define SYMBOL[=VALUE] — will replace +all instances of the specified symbol where used as an identifier +(except where symbol has properly declared by a var declaration or +use as function parameter or similar) with the specified value. This +argument may be specified multiple times to define multiple +symbols - if no value is specified the symbol will be replaced with +the value true, or you can specify a numeric value (such as +1024), a quoted string value (such as ="object"= or +='https://github.com'), or the name of another symbol or keyword (such as =null or document). +This allows you, for example, to assign meaningful names to key +constant values but discard the symbolic names in the uglified +version for brevity/efficiency, or when used wth care, allows +UglifyJS to operate as a form of conditional compilation +whereby defining appropriate values may, by dint of the constant +folding and dead code removal features above, remove entire +superfluous code blocks (e.g. completely remove instrumentation or +trace code for production use). +Where string values are being defined, the handling of quotes are +likely to be subject to the specifics of your command shell +environment, so you may need to experiment with quoting styles +depending on your platform, or you may find the option +--define-from-module more suitable for use. + +
    • +
    • +-define-from-module SOMEMODULE — will load the named module (as +per the NodeJS require() function) and iterate all the exported +properties of the module defining them as symbol names to be defined +(as if by the --define option) per the name of each property +(i.e. without the module name prefix) and given the value of the +property. This is a much easier way to handle and document groups of +symbols to be defined rather than a large number of --define +options. + +
    • +
    • +--unsafe — enable other additional optimizations that are known to be +unsafe in some contrived situations, but could still be generally useful. +For now only these: + +
        +
      • +foo.toString() ==> foo+"" +
      • +
      • +new Array(x,…) ==> [x,…] +
      • +
      • +new Array(x) ==> Array(x) + +
      • +
      +
    • +
    • +--max-line-len (default 32K characters) — add a newline after around +32K characters. I've seen both FF and Chrome croak when all the code was +on a single line of around 670K. Pass –max-line-len 0 to disable this +safety feature. + +
    • +
    • +--reserved-names — some libraries rely on certain names to be used, as +pointed out in issue #92 and #81, so this option allow you to exclude such +names from the mangler. For example, to keep names require and $super +intact you'd specify –reserved-names "require,$super". + +
    • +
    • +--inline-script – when you want to include the output literally in an +HTML <script> tag you can use this option to prevent </script from +showing up in the output. + +
    • +
    • +--lift-vars – when you pass this, UglifyJS will apply the following +transformations (see the notes in API, ast_lift_variables): + +
        +
      • +put all var declarations at the start of the scope +
      • +
      • +make sure a variable is declared only once +
      • +
      • +discard unused function arguments +
      • +
      • +discard unused inner (named) functions +
      • +
      • +finally, try to merge assignments into that one var declaration, if +possible. +
      • +
      +
    • +
    + + + +
    + +
    +

    1.4.1 API

    +
    + + +

    +To use the library from JavaScript, you'd do the following (example for +NodeJS): +

    + + + +
    var jsp = require("uglify-js").parser;
    +var pro = require("uglify-js").uglify;
    +
    +var orig_code = "... JS code here";
    +var ast = jsp.parse(orig_code); // parse code and get the initial AST
    +ast = pro.ast_mangle(ast); // get a new AST with mangled names
    +ast = pro.ast_squeeze(ast); // get an AST with compression optimizations
    +var final_code = pro.gen_code(ast); // compressed code here
    +
    + + + +

    +The above performs the full compression that is possible right now. As you +can see, there are a sequence of steps which you can apply. For example if +you want compressed output but for some reason you don't want to mangle +variable names, you would simply skip the line that calls +pro.ast_mangle(ast). +

    +

    +Some of these functions take optional arguments. Here's a description: +

    +
      +
    • +jsp.parse(code, strict_semicolons) – parses JS code and returns an AST. +strict_semicolons is optional and defaults to false. If you pass +true then the parser will throw an error when it expects a semicolon and +it doesn't find it. For most JS code you don't want that, but it's useful +if you want to strictly sanitize your code. + +
    • +
    • +pro.ast_lift_variables(ast) – merge and move var declarations to the +scop of the scope; discard unused function arguments or variables; discard +unused (named) inner functions. It also tries to merge assignments +following the var declaration into it. + +

      +If your code is very hand-optimized concerning var declarations, this +lifting variable declarations might actually increase size. For me it +helps out. On jQuery it adds 865 bytes (243 after gzip). YMMV. Also +note that (since it's not enabled by default) this operation isn't yet +heavily tested (please report if you find issues!). +

      +

      +Note that although it might increase the image size (on jQuery it gains +865 bytes, 243 after gzip) it's technically more correct: in certain +situations, dead code removal might drop variable declarations, which +would not happen if the variables are lifted in advance. +

      +

      +Here's an example of what it does: +

      +
    • +
    + + + + +
    function f(a, b, c, d, e) {
    +    var q;
    +    var w;
    +    w = 10;
    +    q = 20;
    +    for (var i = 1; i < 10; ++i) {
    +        var boo = foo(a);
    +    }
    +    for (var i = 0; i < 1; ++i) {
    +        var boo = bar(c);
    +    }
    +    function foo(){ ... }
    +    function bar(){ ... }
    +    function baz(){ ... }
    +}
    +
    +// transforms into ==>
    +
    +function f(a, b, c) {
    +    var i, boo, w = 10, q = 20;
    +    for (i = 1; i < 10; ++i) {
    +        boo = foo(a);
    +    }
    +    for (i = 0; i < 1; ++i) {
    +        boo = bar(c);
    +    }
    +    function foo() { ... }
    +    function bar() { ... }
    +}
    +
    + + + +
      +
    • +pro.ast_mangle(ast, options) – generates a new AST containing mangled +(compressed) variable and function names. It supports the following +options: + +
        +
      • +toplevel – mangle toplevel names (by default we don't touch them). +
      • +
      • +except – an array of names to exclude from compression. +
      • +
      • +defines – an object with properties named after symbols to +replace (see the --define option for the script) and the values +representing the AST replacement value. + +
      • +
      +
    • +
    • +pro.ast_squeeze(ast, options) – employs further optimizations designed +to reduce the size of the code that gen_code would generate from the +AST. Returns a new AST. options can be a hash; the supported options +are: + +
        +
      • +make_seqs (default true) which will cause consecutive statements in a +block to be merged using the "sequence" (comma) operator + +
      • +
      • +dead_code (default true) which will remove unreachable code. + +
      • +
      +
    • +
    • +pro.gen_code(ast, options) – generates JS code from the AST. By +default it's minified, but using the options argument you can get nicely +formatted output. options is, well, optional :-) and if you pass it it +must be an object and supports the following properties (below you can see +the default values): + +
        +
      • +beautify: false – pass true if you want indented output +
      • +
      • +indent_start: 0 (only applies when beautify is true) – initial +indentation in spaces +
      • +
      • +indent_level: 4 (only applies when beautify is true) -- +indentation level, in spaces (pass an even number) +
      • +
      • +quote_keys: false – if you pass true it will quote all keys in +literal objects +
      • +
      • +space_colon: false (only applies when beautify is true) – wether +to put a space before the colon in object literals +
      • +
      • +ascii_only: false – pass true if you want to encode non-ASCII +characters as \uXXXX. +
      • +
      • +inline_script: false – pass true to escape occurrences of +</script in strings +
      • +
      +
    • +
    + + +
    + +
    + +
    +

    1.4.2 Beautifier shortcoming – no more comments

    +
    + + +

    +The beautifier can be used as a general purpose indentation tool. It's +useful when you want to make a minified file readable. One limitation, +though, is that it discards all comments, so you don't really want to use it +to reformat your code, unless you don't have, or don't care about, comments. +

    +

    +In fact it's not the beautifier who discards comments — they are dumped at +the parsing stage, when we build the initial AST. Comments don't really +make sense in the AST, and while we could add nodes for them, it would be +inconvenient because we'd have to add special rules to ignore them at all +the processing stages. +

    +
    + +
    + +
    +

    1.4.3 Use as a code pre-processor

    +
    + + +

    +The --define option can be used, particularly when combined with the +constant folding logic, as a form of pre-processor to enable or remove +particular constructions, such as might be used for instrumenting +development code, or to produce variations aimed at a specific +platform. +

    +

    +The code below illustrates the way this can be done, and how the +symbol replacement is performed. +

    + + + +
    CLAUSE1: if (typeof DEVMODE === 'undefined') {
    +    DEVMODE = true;
    +}
    +
    +CLAUSE2: function init() {
    +    if (DEVMODE) {
    +        console.log("init() called");
    +    }
    +    ....
    +    DEVMODE &amp;&amp; console.log("init() complete");
    +}
    +
    +CLAUSE3: function reportDeviceStatus(device) {
    +    var DEVMODE = device.mode, DEVNAME = device.name;
    +    if (DEVMODE === 'open') {
    +        ....
    +    }
    +}
    +
    + + + +

    +When the above code is normally executed, the undeclared global +variable DEVMODE will be assigned the value true (see CLAUSE1) +and so the init() function (CLAUSE2) will write messages to the +console log when executed, but in CLAUSE3 a locally declared +variable will mask access to the DEVMODE global symbol. +

    +

    +If the above code is processed by UglifyJS with an argument of +--define DEVMODE=false then UglifyJS will replace DEVMODE with the +boolean constant value false within CLAUSE1 and CLAUSE2, but it +will leave CLAUSE3 as it stands because there DEVMODE resolves to +a validly declared variable. +

    +

    +And more so, the constant-folding features of UglifyJS will recognise +that the if condition of CLAUSE1 is thus always false, and so will +remove the test and body of CLAUSE1 altogether (including the +otherwise slightly problematical statement false = true; which it +will have formed by replacing DEVMODE in the body). Similarly, +within CLAUSE2 both calls to console.log() will be removed +altogether. +

    +

    +In this way you can mimic, to a limited degree, the functionality of +the C/C++ pre-processor to enable or completely remove blocks +depending on how certain symbols are defined - perhaps using UglifyJS +to generate different versions of source aimed at different +environments +

    +

    +It is recommmended (but not made mandatory) that symbols designed for +this purpose are given names consisting of UPPER_CASE_LETTERS to +distinguish them from other (normal) symbols and avoid the sort of +clash that CLAUSE3 above illustrates. +

    +
    +
    + +
    + +
    +

    1.5 Compression – how good is it?

    +
    + + +

    +Here are updated statistics. (I also updated my Google Closure and YUI +installations). +

    +

    +We're still a lot better than YUI in terms of compression, though slightly +slower. We're still a lot faster than Closure, and compression after gzip +is comparable. +

    + + ++ + + + + + + + + + +
    FileUglifyJSUglifyJS+gzipClosureClosure+gzipYUIYUI+gzip
    jquery-1.6.2.js91001 (0:01.59)3189690678 (0:07.40)31979101527 (0:01.82)34646
    paper.js142023 (0:01.65)43334134301 (0:07.42)42495173383 (0:01.58)48785
    prototype.js88544 (0:01.09)2668086955 (0:06.97)2632692130 (0:00.79)28624
    thelib-full.js (DynarchLIB)251939 (0:02.55)72535249911 (0:09.05)72696258869 (0:01.94)76584
    + + +
    + +
    + +
    +

    1.6 Bugs?

    +
    + + +

    +Unfortunately, for the time being there is no automated test suite. But I +ran the compressor manually on non-trivial code, and then I tested that the +generated code works as expected. A few hundred times. +

    +

    +DynarchLIB was started in times when there was no good JS minifier. +Therefore I was quite religious about trying to write short code manually, +and as such DL contains a lot of syntactic hacks1 such as “foo == bar ? a += 10 : b = 20”, though the more readable version would clearly be to use +“if/else”. +

    +

    +Since the parser/compressor runs fine on DL and jQuery, I'm quite confident +that it's solid enough for production use. If you can identify any bugs, +I'd love to hear about them (use the Google Group or email me directly). +

    +
    + +
    + +
    +

    1.7 Links

    +
    + + + + + +
    + +
    + +
    +

    1.8 License

    +
    + + +

    +UglifyJS is released under the BSD license: +

    + + + +
    Copyright 2010 (c) Mihai Bazon <mihai.bazon@gmail.com>
    +Based on parse-js (http://marijn.haverbeke.nl/parse-js/).
    +
    +Redistribution and use in source and binary forms, with or without
    +modification, are permitted provided that the following conditions
    +are met:
    +
    +    * Redistributions of source code must retain the above
    +      copyright notice, this list of conditions and the following
    +      disclaimer.
    +
    +    * Redistributions in binary form must reproduce the above
    +      copyright notice, this list of conditions and the following
    +      disclaimer in the documentation and/or other materials
    +      provided with the distribution.
    +
    +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER “AS IS” AND ANY
    +EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
    +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
    +PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER BE
    +LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY,
    +OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
    +PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
    +PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
    +THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR
    +TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF
    +THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
    +SUCH DAMAGE.
    +
    + + + + +
    +
    +
    +
    +

    Footnotes:

    +
    +

    1 I even reported a few bugs and suggested some fixes in the original +parse-js library, and Marijn pushed fixes literally in minutes. +

    +
    +
    +
    +

    Author: Mihai Bazon +

    +

    Date: 2011-08-29 19:17:55 EEST

    +

    HTML generated by org-mode 7.01trans in emacs 23

    +
    +
    + + diff --git a/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/uglify-js/README.org b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/uglify-js/README.org new file mode 100644 index 0000000..50c9c27 --- /dev/null +++ b/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/uglify-js/README.org @@ -0,0 +1,571 @@ +#+TITLE: UglifyJS -- a JavaScript parser/compressor/beautifier +#+KEYWORDS: javascript, js, parser, compiler, compressor, mangle, minify, minifier +#+DESCRIPTION: a JavaScript parser/compressor/beautifier in JavaScript +#+STYLE: +#+AUTHOR: Mihai Bazon +#+EMAIL: mihai.bazon@gmail.com + +* UglifyJS --- a JavaScript parser/compressor/beautifier + +This package implements a general-purpose JavaScript +parser/compressor/beautifier toolkit. It is developed on [[http://nodejs.org/][NodeJS]], but it +should work on any JavaScript platform supporting the CommonJS module system +(and if your platform of choice doesn't support CommonJS, you can easily +implement it, or discard the =exports.*= lines from UglifyJS sources). + +The tokenizer/parser generates an abstract syntax tree from JS code. You +can then traverse the AST to learn more about the code, or do various +manipulations on it. This part is implemented in [[../lib/parse-js.js][parse-js.js]] and it's a +port to JavaScript of the excellent [[http://marijn.haverbeke.nl/parse-js/][parse-js]] Common Lisp library from [[http://marijn.haverbeke.nl/][Marijn +Haverbeke]]. + +( See [[http://github.com/mishoo/cl-uglify-js][cl-uglify-js]] if you're looking for the Common Lisp version of +UglifyJS. ) + +The second part of this package, implemented in [[../lib/process.js][process.js]], inspects and +manipulates the AST generated by the parser to provide the following: + +- ability to re-generate JavaScript code from the AST. Optionally + indented---you can use this if you want to “beautify” a program that has + been compressed, so that you can inspect the source. But you can also run + our code generator to print out an AST without any whitespace, so you + achieve compression as well. + +- shorten variable names (usually to single characters). Our mangler will + analyze the code and generate proper variable names, depending on scope + and usage, and is smart enough to deal with globals defined elsewhere, or + with =eval()= calls or =with{}= statements. In short, if =eval()= or + =with{}= are used in some scope, then all variables in that scope and any + variables in the parent scopes will remain unmangled, and any references + to such variables remain unmangled as well. + +- various small optimizations that may lead to faster code but certainly + lead to smaller code. Where possible, we do the following: + + - foo["bar"] ==> foo.bar + + - remove block brackets ={}= + + - join consecutive var declarations: + var a = 10; var b = 20; ==> var a=10,b=20; + + - resolve simple constant expressions: 1 +2 * 3 ==> 7. We only do the + replacement if the result occupies less bytes; for example 1/3 would + translate to 0.333333333333, so in this case we don't replace it. + + - consecutive statements in blocks are merged into a sequence; in many + cases, this leaves blocks with a single statement, so then we can remove + the block brackets. + + - various optimizations for IF statements: + + - if (foo) bar(); else baz(); ==> foo?bar():baz(); + - if (!foo) bar(); else baz(); ==> foo?baz():bar(); + - if (foo) bar(); ==> foo&&bar(); + - if (!foo) bar(); ==> foo||bar(); + - if (foo) return bar(); else return baz(); ==> return foo?bar():baz(); + - if (foo) return bar(); else something(); ==> {if(foo)return bar();something()} + + - remove some unreachable code and warn about it (code that follows a + =return=, =throw=, =break= or =continue= statement, except + function/variable declarations). + + - act a limited version of a pre-processor (c.f. the pre-processor of + C/C++) to allow you to safely replace selected global symbols with + specified values. When combined with the optimisations above this can + make UglifyJS operate slightly more like a compilation process, in + that when certain symbols are replaced by constant values, entire code + blocks may be optimised away as unreachable. + +** <> + +The following transformations can in theory break code, although they're +probably safe in most practical cases. To enable them you need to pass the +=--unsafe= flag. + +*** Calls involving the global Array constructor + +The following transformations occur: + +#+BEGIN_SRC js +new Array(1, 2, 3, 4) => [1,2,3,4] +Array(a, b, c) => [a,b,c] +new Array(5) => Array(5) +new Array(a) => Array(a) +#+END_SRC + +These are all safe if the Array name isn't redefined. JavaScript does allow +one to globally redefine Array (and pretty much everything, in fact) but I +personally don't see why would anyone do that. + +UglifyJS does handle the case where Array is redefined locally, or even +globally but with a =function= or =var= declaration. Therefore, in the +following cases UglifyJS *doesn't touch* calls or instantiations of Array: + +#+BEGIN_SRC js +// case 1. globally declared variable + var Array; + new Array(1, 2, 3); + Array(a, b); + + // or (can be declared later) + new Array(1, 2, 3); + var Array; + + // or (can be a function) + new Array(1, 2, 3); + function Array() { ... } + +// case 2. declared in a function + (function(){ + a = new Array(1, 2, 3); + b = Array(5, 6); + var Array; + })(); + + // or + (function(Array){ + return Array(5, 6, 7); + })(); + + // or + (function(){ + return new Array(1, 2, 3, 4); + function Array() { ... } + })(); + + // etc. +#+END_SRC + +*** =obj.toString()= ==> =obj+“”= + +** Install (NPM) + +UglifyJS is now available through NPM --- =npm install uglify-js= should do +the job. + +** Install latest code from GitHub + +#+BEGIN_SRC sh +## clone the repository +mkdir -p /where/you/wanna/put/it +cd /where/you/wanna/put/it +git clone git://github.com/mishoo/UglifyJS.git + +## make the module available to Node +mkdir -p ~/.node_libraries/ +cd ~/.node_libraries/ +ln -s /where/you/wanna/put/it/UglifyJS/uglify-js.js + +## and if you want the CLI script too: +mkdir -p ~/bin +cd ~/bin +ln -s /where/you/wanna/put/it/UglifyJS/bin/uglifyjs + # (then add ~/bin to your $PATH if it's not there already) +#+END_SRC + +** Usage + +There is a command-line tool that exposes the functionality of this library +for your shell-scripting needs: + +#+BEGIN_SRC sh +uglifyjs [ options... ] [ filename ] +#+END_SRC + +=filename= should be the last argument and should name the file from which +to read the JavaScript code. If you don't specify it, it will read code +from STDIN. + +Supported options: + +- =-b= or =--beautify= --- output indented code; when passed, additional + options control the beautifier: + + - =-i N= or =--indent N= --- indentation level (number of spaces) + + - =-q= or =--quote-keys= --- quote keys in literal objects (by default, + only keys that cannot be identifier names will be quotes). + +- =--ascii= --- pass this argument to encode non-ASCII characters as + =\uXXXX= sequences. By default UglifyJS won't bother to do it and will + output Unicode characters instead. (the output is always encoded in UTF8, + but if you pass this option you'll only get ASCII). + +- =-nm= or =--no-mangle= --- don't mangle variable names + +- =-ns= or =--no-squeeze= --- don't call =ast_squeeze()= (which does various + optimizations that result in smaller, less readable code). + +- =-mt= or =--mangle-toplevel= --- mangle names in the toplevel scope too + (by default we don't do this). + +- =--no-seqs= --- when =ast_squeeze()= is called (thus, unless you pass + =--no-squeeze=) it will reduce consecutive statements in blocks into a + sequence. For example, "a = 10; b = 20; foo();" will be written as + "a=10,b=20,foo();". In various occasions, this allows us to discard the + block brackets (since the block becomes a single statement). This is ON + by default because it seems safe and saves a few hundred bytes on some + libs that I tested it on, but pass =--no-seqs= to disable it. + +- =--no-dead-code= --- by default, UglifyJS will remove code that is + obviously unreachable (code that follows a =return=, =throw=, =break= or + =continue= statement and is not a function/variable declaration). Pass + this option to disable this optimization. + +- =-nc= or =--no-copyright= --- by default, =uglifyjs= will keep the initial + comment tokens in the generated code (assumed to be copyright information + etc.). If you pass this it will discard it. + +- =-o filename= or =--output filename= --- put the result in =filename=. If + this isn't given, the result goes to standard output (or see next one). + +- =--overwrite= --- if the code is read from a file (not from STDIN) and you + pass =--overwrite= then the output will be written in the same file. + +- =--ast= --- pass this if you want to get the Abstract Syntax Tree instead + of JavaScript as output. Useful for debugging or learning more about the + internals. + +- =-v= or =--verbose= --- output some notes on STDERR (for now just how long + each operation takes). + +- =-d SYMBOL[=VALUE]= or =--define SYMBOL[=VALUE]= --- will replace + all instances of the specified symbol where used as an identifier + (except where symbol has properly declared by a var declaration or + use as function parameter or similar) with the specified value. This + argument may be specified multiple times to define multiple + symbols - if no value is specified the symbol will be replaced with + the value =true=, or you can specify a numeric value (such as + =1024=), a quoted string value (such as ="object"= or + ='https://github.com'=), or the name of another symbol or keyword + (such as =null= or =document=). + This allows you, for example, to assign meaningful names to key + constant values but discard the symbolic names in the uglified + version for brevity/efficiency, or when used wth care, allows + UglifyJS to operate as a form of *conditional compilation* + whereby defining appropriate values may, by dint of the constant + folding and dead code removal features above, remove entire + superfluous code blocks (e.g. completely remove instrumentation or + trace code for production use). + Where string values are being defined, the handling of quotes are + likely to be subject to the specifics of your command shell + environment, so you may need to experiment with quoting styles + depending on your platform, or you may find the option + =--define-from-module= more suitable for use. + +- =-define-from-module SOMEMODULE= --- will load the named module (as + per the NodeJS =require()= function) and iterate all the exported + properties of the module defining them as symbol names to be defined + (as if by the =--define= option) per the name of each property + (i.e. without the module name prefix) and given the value of the + property. This is a much easier way to handle and document groups of + symbols to be defined rather than a large number of =--define= + options. + +- =--unsafe= --- enable other additional optimizations that are known to be + unsafe in some contrived situations, but could still be generally useful. + For now only these: + + - foo.toString() ==> foo+"" + - new Array(x,...) ==> [x,...] + - new Array(x) ==> Array(x) + +- =--max-line-len= (default 32K characters) --- add a newline after around + 32K characters. I've seen both FF and Chrome croak when all the code was + on a single line of around 670K. Pass --max-line-len 0 to disable this + safety feature. + +- =--reserved-names= --- some libraries rely on certain names to be used, as + pointed out in issue #92 and #81, so this option allow you to exclude such + names from the mangler. For example, to keep names =require= and =$super= + intact you'd specify --reserved-names "require,$super". + +- =--inline-script= -- when you want to include the output literally in an + HTML = + + + + + + + +

    Nodeunit Test Suite

    + + + diff --git a/node_modules/serve-favicon/HISTORY.md b/node_modules/serve-favicon/HISTORY.md new file mode 100644 index 0000000..54a8152 --- /dev/null +++ b/node_modules/serve-favicon/HISTORY.md @@ -0,0 +1,60 @@ +2.1.4 / 2014-09-15 +================== + + * Fix content headers being sent in 304 response + * deps: etag@~1.3.1 + - Improve ETag generation speed + +2.1.3 / 2014-09-07 +================== + + * deps: fresh@0.2.4 + +2.1.2 / 2014-09-05 +================== + + * deps: etag@~1.3.0 + - Improve ETag generation speed + +2.1.1 / 2014-08-25 +================== + + * Fix `ms` to be listed as a dependency + +2.1.0 / 2014-08-24 +================== + + * Accept string for `maxAge` (converted by `ms`) + * Use `etag` to generate `ETag` header + +2.0.1 / 2014-06-05 +================== + + * Reduce byte size of `ETag` header + +2.0.0 / 2014-05-02 +================== + + * `path` argument is required; there is no default icon. + * Accept `Buffer` of icon as first argument. + * Non-GET and HEAD requests are denied. + * Send valid max-age value + * Support conditional requests + * Support max-age=0 + * Support OPTIONS method + * Throw if `path` argument is directory. + +1.0.2 / 2014-03-16 +================== + + * Fixed content of default icon. + +1.0.1 / 2014-03-11 +================== + + * Fixed path to default icon. + +1.0.0 / 2014-02-15 +================== + + * Initial release diff --git a/node_modules/serve-favicon/LICENSE b/node_modules/serve-favicon/LICENSE new file mode 100644 index 0000000..813ed6c --- /dev/null +++ b/node_modules/serve-favicon/LICENSE @@ -0,0 +1,25 @@ +(The MIT License) + +Copyright (c) 2010 Sencha Inc. +Copyright (c) 2011 LearnBoost +Copyright (c) 2011 TJ Holowaychuk +Copyright (c) 2014 Douglas Christopher Wilson + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +'Software'), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. +IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY +CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, +TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE +SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. \ No newline at end of file diff --git a/node_modules/serve-favicon/README.md b/node_modules/serve-favicon/README.md new file mode 100644 index 0000000..74fbf2d --- /dev/null +++ b/node_modules/serve-favicon/README.md @@ -0,0 +1,109 @@ +# serve-favicon + +[![NPM Version][npm-image]][npm-url] +[![NPM Downloads][downloads-image]][downloads-url] +[![Build Status][travis-image]][travis-url] +[![Test Coverage][coveralls-image]][coveralls-url] +[![Gittip][gittip-image]][gittip-url] + +Node.js middleware for serving a favicon. + +## Install + +```bash +npm install serve-favicon +``` + +## API + +### favicon(path, options) + +Create new middleware to serve a favicon from the given `path` to a favicon file. +`path` may also be a `Buffer` of the icon to serve. + +#### Options + +Serve favicon accepts these properties in the options object. + +##### maxAge + +The `cache-control` `max-age` directive in `ms`, defaulting to 1 day. This can +also be a string accepted by the [ms](https://www.npmjs.org/package/ms#readme) +module. + +## Examples + +Typically this middleware will come very early in your stack (maybe even first) +to avoid processing any other middleware if we already know the request is for +`/favicon.ico`. + +### express + +```javascript +var express = require('express'); +var favicon = require('serve-favicon'); + +var app = express(); +app.use(favicon(__dirname + '/public/favicon.ico')); + +// Add your routes here, etc. + +app.listen(3000); +``` + +### connect + +```javascript +var connect = require('connect'); +var favicon = require('serve-favicon'); + +var app = connect(); +app.use(favicon(__dirname + '/public/favicon.ico')); + +// Add your middleware here, etc. + +app.listen(3000); +``` + +### vanilla http server + +This middleware can be used anywhere, even outside express/connect. It takes +`req`, `res`, and `callback`. + +```javascript +var http = require('http'); +var favicon = require('serve-favicon'); +var finalhandler = require('finalhandler'); + +var _favicon = favicon(__dirname + '/public/favicon.ico'); + +var server = http.createServer(function onRequest(req, res) { + var done = finalhandler(req, res); + + _favicon(req, res, function onNext(err) { + if (err) return done(err); + + // continue to process the request here, etc. + + res.statusCode = 404; + res.end('oops'); + }); +}); + +server.listen(3000); +``` + +## License + +[MIT](LICENSE) + +[npm-image]: https://img.shields.io/npm/v/serve-favicon.svg?style=flat +[npm-url]: https://npmjs.org/package/serve-favicon +[travis-image]: https://img.shields.io/travis/expressjs/serve-favicon.svg?style=flat +[travis-url]: https://travis-ci.org/expressjs/serve-favicon +[coveralls-image]: https://img.shields.io/coveralls/expressjs/serve-favicon.svg?style=flat +[coveralls-url]: https://coveralls.io/r/expressjs/serve-favicon?branch=master +[downloads-image]: https://img.shields.io/npm/dm/serve-favicon.svg?style=flat +[downloads-url]: https://npmjs.org/package/serve-favicon +[gittip-image]: https://img.shields.io/gittip/dougwilson.svg?style=flat +[gittip-url]: https://www.gittip.com/dougwilson/ diff --git a/node_modules/serve-favicon/index.js b/node_modules/serve-favicon/index.js new file mode 100644 index 0000000..f453761 --- /dev/null +++ b/node_modules/serve-favicon/index.js @@ -0,0 +1,125 @@ +/*! + * serve-favicon + * Copyright(c) 2010 Sencha Inc. + * Copyright(c) 2011 TJ Holowaychuk + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module dependencies. + */ + +var etag = require('etag'); +var fresh = require('fresh'); +var fs = require('fs'); +var ms = require('ms'); +var path = require('path'); +var resolve = path.resolve; + +/** + * Module variables. + */ + +var maxMaxAge = 60 * 60 * 24 * 365 * 1000; // 1 year + +/** + * Serves the favicon located by the given `path`. + * + * @param {String|Buffer} path + * @param {Object} options + * @return {Function} middleware + * @api public + */ + +module.exports = function favicon(path, options){ + options = options || {}; + + var buf; + var icon; // favicon cache + var maxAge = calcMaxAge(options.maxAge); + var stat; + + if (!path) throw new TypeError('path to favicon.ico is required'); + + if (Buffer.isBuffer(path)) { + buf = new Buffer(path.length); + path.copy(buf); + + icon = createIcon(buf, maxAge); + } else if (typeof path === 'string') { + path = resolve(path); + stat = fs.statSync(path); + if (stat.isDirectory()) throw createIsDirError(path); + } else { + throw new TypeError('path to favicon.ico must be string or buffer'); + } + + return function favicon(req, res, next){ + if ('/favicon.ico' !== req.url) return next(); + + if ('GET' !== req.method && 'HEAD' !== req.method) { + var status = 'OPTIONS' === req.method ? 200 : 405; + res.writeHead(status, {'Allow': 'GET, HEAD, OPTIONS'}); + res.end(); + return; + } + + if (icon) return send(req, res, icon); + + fs.readFile(path, function(err, buf){ + if (err) return next(err); + icon = createIcon(buf, maxAge); + send(req, res, icon); + }); + }; +}; + +function calcMaxAge(val) { + var num = typeof val === 'string' + ? ms(val) + : val; + + return num != null + ? Math.min(Math.max(0, num), maxMaxAge) + : maxMaxAge +} + +function createIcon(buf, maxAge) { + return { + body: buf, + headers: { + 'Cache-Control': 'public, max-age=' + ~~(maxAge / 1000), + 'ETag': etag(buf) + } + }; +} + +function createIsDirError(path) { + var error = new Error('EISDIR, illegal operation on directory \'' + path + '\''); + error.code = 'EISDIR'; + error.errno = 28; + error.path = path; + error.syscall = 'open'; + return error; +} + +function send(req, res, icon) { + var headers = icon.headers; + + // Set headers + for (var header in headers) { + res.setHeader(header, headers[header]); + } + + if (fresh(req.headers, res._headers)) { + res.statusCode = 304; + res.end(); + return; + } + + res.statusCode = 200; + res.setHeader('Content-Length', icon.body.length); + res.setHeader('Content-Type', 'image/x-icon'); + res.end(icon.body); +} diff --git a/node_modules/serve-favicon/node_modules/etag/HISTORY.md b/node_modules/serve-favicon/node_modules/etag/HISTORY.md new file mode 100644 index 0000000..c13d034 --- /dev/null +++ b/node_modules/serve-favicon/node_modules/etag/HISTORY.md @@ -0,0 +1,37 @@ +1.3.1 / 2014-09-14 +================== + + * Use the (new and improved) `crc` for crc32 + +1.3.0 / 2014-08-29 +================== + + * Default strings to strong ETags + * Improve speed for weak ETags over 1KB + +1.2.1 / 2014-08-29 +================== + + * Use the (much faster) `buffer-crc32` for crc32 + +1.2.0 / 2014-08-24 +================== + + * Add support for file stat objects + +1.1.0 / 2014-08-24 +================== + + * Add fast-path for empty entity + * Add weak ETag generation + * Shrink size of generated ETags + +1.0.1 / 2014-08-24 +================== + + * Fix behavior of string containing Unicode + +1.0.0 / 2014-05-18 +================== + + * Initial release diff --git a/node_modules/serve-favicon/node_modules/etag/LICENSE b/node_modules/serve-favicon/node_modules/etag/LICENSE new file mode 100644 index 0000000..b7dce6c --- /dev/null +++ b/node_modules/serve-favicon/node_modules/etag/LICENSE @@ -0,0 +1,22 @@ +(The MIT License) + +Copyright (c) 2014 Douglas Christopher Wilson + +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/node_modules/serve-favicon/node_modules/etag/README.md b/node_modules/serve-favicon/node_modules/etag/README.md new file mode 100644 index 0000000..d770f49 --- /dev/null +++ b/node_modules/serve-favicon/node_modules/etag/README.md @@ -0,0 +1,141 @@ +# etag + +[![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] + +Create simple ETags + +## Installation + +```sh +$ npm install etag +``` + +## API + +```js +var etag = require('etag') +``` + +### etag(entity, [options]) + +Generate a strong ETag for the given entity. This should be the complete +body of the entity. Strings, `Buffer`s, and `fs.Stats` are accepted. By +default, a strong ETag is generated except for `fs.Stats`, which will +generate a weak ETag (this can be overwritten by `options.weak`). + +```js +res.setHeader('ETag', etag(body)) +``` + +#### Options + +`etag` accepts these properties in the options object. + +##### weak + +Specifies if a "strong" or a "weak" ETag will be generated. The ETag can only +really be a strong as the given input. + +## Testing + +```sh +$ npm test +``` + +## Benchmark + +```bash +$ npm run-script bench + +> etag@1.2.0 bench nodejs-etag +> node benchmark/index.js + +> node benchmark/body0-100b.js + + 100B body + + 1 test completed. + 2 tests completed. + 3 tests completed. + 4 tests completed. + + buffer - strong x 518,895 ops/sec ±1.71% (185 runs sampled) +* buffer - weak x 1,917,975 ops/sec ±0.34% (195 runs sampled) + string - strong x 245,251 ops/sec ±0.90% (190 runs sampled) + string - weak x 442,232 ops/sec ±0.21% (196 runs sampled) + +> node benchmark/body1-1kb.js + + 1KB body + + 1 test completed. + 2 tests completed. + 3 tests completed. + 4 tests completed. + + buffer - strong x 309,748 ops/sec ±0.99% (191 runs sampled) +* buffer - weak x 352,402 ops/sec ±0.20% (198 runs sampled) + string - strong x 159,058 ops/sec ±1.83% (191 runs sampled) + string - weak x 184,052 ops/sec ±1.30% (189 runs sampled) + +> node benchmark/body2-5kb.js + + 5KB body + + 1 test completed. + 2 tests completed. + 3 tests completed. + 4 tests completed. + +* buffer - strong x 110,157 ops/sec ±0.60% (194 runs sampled) +* buffer - weak x 111,333 ops/sec ±0.67% (194 runs sampled) + string - strong x 62,091 ops/sec ±3.92% (186 runs sampled) + string - weak x 60,681 ops/sec ±3.98% (186 runs sampled) + +> node benchmark/body3-10kb.js + + 10KB body + + 1 test completed. + 2 tests completed. + 3 tests completed. + 4 tests completed. + +* buffer - strong x 61,843 ops/sec ±0.44% (197 runs sampled) +* buffer - weak x 61,687 ops/sec ±0.52% (197 runs sampled) + string - strong x 41,377 ops/sec ±3.33% (189 runs sampled) + string - weak x 41,368 ops/sec ±3.29% (190 runs sampled) + +> node benchmark/body4-100kb.js + + 100KB body + + 1 test completed. + 2 tests completed. + 3 tests completed. + 4 tests completed. + +* buffer - strong x 6,874 ops/sec ±0.17% (198 runs sampled) +* buffer - weak x 6,880 ops/sec ±0.15% (198 runs sampled) + string - strong x 5,382 ops/sec ±2.17% (192 runs sampled) + string - weak x 5,361 ops/sec ±2.23% (192 runs sampled) +``` + +## License + +[MIT](LICENSE) + +[npm-image]: https://img.shields.io/npm/v/etag.svg?style=flat +[npm-url]: https://npmjs.org/package/etag +[node-version-image]: https://img.shields.io/node/v/etag.svg?style=flat +[node-version-url]: http://nodejs.org/download/ +[travis-image]: https://img.shields.io/travis/jshttp/etag.svg?style=flat +[travis-url]: https://travis-ci.org/jshttp/etag +[coveralls-image]: https://img.shields.io/coveralls/jshttp/etag.svg?style=flat +[coveralls-url]: https://coveralls.io/r/jshttp/etag?branch=master +[downloads-image]: https://img.shields.io/npm/dm/etag.svg?style=flat +[downloads-url]: https://npmjs.org/package/etag diff --git a/node_modules/serve-favicon/node_modules/etag/index.js b/node_modules/serve-favicon/node_modules/etag/index.js new file mode 100644 index 0000000..3ddf18f --- /dev/null +++ b/node_modules/serve-favicon/node_modules/etag/index.js @@ -0,0 +1,133 @@ +/*! + * etag + * Copyright(c) 2014 Douglas Christopher Wilson + * MIT Licensed + */ + +/** + * Module exports. + */ + +module.exports = etag + +/** + * Module dependencies. + */ + +var crc = require('crc').crc32 +var crypto = require('crypto') +var Stats = require('fs').Stats + +/** + * Module variables. + */ + +var crc32threshold = 1000 // 1KB +var NULL = new Buffer([0]) + +/** + * Create a simple ETag. + * + * @param {string|Buffer|Stats} entity + * @param {object} [options] + * @param {boolean} [options.weak] + * @return {String} + * @api public + */ + +function etag(entity, options) { + if (entity == null) { + throw new TypeError('argument entity is required') + } + + var isBuffer = Buffer.isBuffer(entity) + var isStats = entity instanceof Stats + var weak = options && typeof options.weak === 'boolean' + ? options.weak + : isStats + + // support fs.Stats object + if (isStats) { + return stattag(entity, weak) + } + + if (!isBuffer && typeof entity !== 'string') { + throw new TypeError('argument entity must be string, Buffer, or fs.Stats') + } + + var buf = !isBuffer + ? new Buffer(entity, 'utf8') + : entity + var hash = weak && buf.length <= crc32threshold + ? weakhash(buf) + : stronghash(buf) + + return weak + ? 'W/"' + hash + '"' + : '"' + hash + '"' +} + +/** + * Generate a tag for a stat. + * + * @param {Buffer} entity + * @return {String} + * @api private + */ + +function stattag(stat, weak) { + var mtime = stat.mtime.toISOString() + var size = stat.size.toString(16) + + if (weak) { + return 'W/"' + size + '-' + crc(mtime) + '"' + } + + var hash = crypto + .createHash('md5') + .update('file', 'utf8') + .update(NULL) + .update(size, 'utf8') + .update(NULL) + .update(mtime, 'utf8') + .digest('base64') + + return '"' + hash + '"' +} + +/** + * Generate a strong hash. + * + * @param {Buffer} entity + * @return {String} + * @api private + */ + +function stronghash(buf) { + if (buf.length === 0) { + // fast-path empty + return '1B2M2Y8AsgTpgAmY7PhCfg==' + } + + return crypto + .createHash('md5') + .update(buf) + .digest('base64') +} + +/** + * Generate a weak hash. + * + * @param {Buffer} entity + * @return {String} + * @api private + */ + +function weakhash(buf) { + if (buf.length === 0) { + // fast-path empty + return '0-0' + } + + return buf.length.toString(16) + '-' + crc(buf).toString(16) +} diff --git a/node_modules/serve-favicon/node_modules/etag/node_modules/crc/.npmignore b/node_modules/serve-favicon/node_modules/etag/node_modules/crc/.npmignore new file mode 100644 index 0000000..b84a005 --- /dev/null +++ b/node_modules/serve-favicon/node_modules/etag/node_modules/crc/.npmignore @@ -0,0 +1,4 @@ +benchmark +src +test +.travis.yml diff --git a/node_modules/serve-favicon/node_modules/etag/node_modules/crc/LICENSE b/node_modules/serve-favicon/node_modules/etag/node_modules/crc/LICENSE new file mode 100644 index 0000000..c49097c --- /dev/null +++ b/node_modules/serve-favicon/node_modules/etag/node_modules/crc/LICENSE @@ -0,0 +1,22 @@ +The MIT License (MIT) + +Copyright 2014 Alex Gorbatchev + +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/node_modules/serve-favicon/node_modules/etag/node_modules/crc/README.md b/node_modules/serve-favicon/node_modules/etag/node_modules/crc/README.md new file mode 100644 index 0000000..3fdef99 --- /dev/null +++ b/node_modules/serve-favicon/node_modules/etag/node_modules/crc/README.md @@ -0,0 +1,89 @@ +# crc + +[![GitTip](http://img.shields.io/gittip/alexgorbatchev.svg?style=flat)](https://www.gittip.com/alexgorbatchev/) +[![Dependency status](http://img.shields.io/david/alexgorbatchev/node-crc.svg?style=flat)](https://david-dm.org/alexgorbatchev/node-crc) +[![devDependency Status](http://img.shields.io/david/dev/alexgorbatchev/node-crc.svg?style=flat)](https://david-dm.org/alexgorbatchev/node-crc#info=devDependencies) +[![Build Status](http://img.shields.io/travis/alexgorbatchev/node-crc.svg?style=flat&branch=master)](https://travis-ci.org/alexgorbatchev/node-crc) + +[![NPM](https://nodei.co/npm/node-crc.svg?style=flat)](https://npmjs.org/package/node-crc) + +Module for calculating Cyclic Redundancy Check (CRC). + +## Features + +* Version 3 is 3-4 times faster than version 2. +* Pure JavaScript implementation, no dependencies. +* Provides CRC Tables for optimized calculations. +* Provides support for the following CRC algorithms: + * CRC1 `crc.crc1(…)` + * CRC8 `crc.crc8(…)` + * CRC8 1-Wire `crc.crc81wire(…)` + * CRC16 `crc.crc16(…)` + * CRC16 CCITT `crc.crc16ccitt(…)` + * CRC16 Modbus `crc.crc16modbus(…)` + * CRC24 `crc.crc24(…)` + * CRC32 `crc.crc32(…)` + +## Installation + + npm install crc + +## Running tests + + $ npm install + $ npm test + +## Usage Example + +Calculate a CRC32: + + var crc = require('crc'); + + crc.crc32('hello').toString(16); + # => "3610a686" + +Calculate a CRC32 of a file: + + crc.crc32(fs.readFileSync('README.md', 'utf8')).toString(16); + # => "127ad531" + +Or using a `Buffer`: + + crc.crc32(fs.readFileSync('README.md')).toString(16); + # => "127ad531" + +Incrementally calculate a CRC32: + + value = crc32('one'); + value = crc32('two', value); + value = crc32('three', value); + value.toString(16); + # => "09e1c092" + +## Thanks! + +[pycrc](http://www.tty1.net/pycrc/) library is which the source of all of the CRC tables. + +# License + +The MIT License (MIT) + +Copyright (c) 2014 Alex Gorbatchev + +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/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/crc.js b/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/crc.js new file mode 100644 index 0000000..1c342b7 --- /dev/null +++ b/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/crc.js @@ -0,0 +1,71 @@ +// Generated by CoffeeScript 1.7.1 +var CRC, hex; + +hex = require('./hex'); + +module.exports = CRC = (function() { + CRC.prototype.INIT_CRC = 0x00; + + CRC.prototype.XOR_MASK = 0x00; + + CRC.prototype.WIDTH = 0; + + CRC.prototype.pack = function(crc) { + return ''; + }; + + CRC.prototype.each_byte = function(buf, cb) { + var i, _i, _ref, _results; + if (!Buffer.isBuffer(buf)) { + buf = Buffer(buf); + } + _results = []; + for (i = _i = 0, _ref = buf.length - 1; 0 <= _ref ? _i <= _ref : _i >= _ref; i = 0 <= _ref ? ++_i : --_i) { + _results.push(cb(buf[i])); + } + return _results; + }; + + function CRC() { + this.crc = this.INIT_CRC; + } + + CRC.prototype.digest_length = function() { + return Math.ceil(this.WIDTH / 8.0); + }; + + CRC.prototype.update = function(data) {}; + + CRC.prototype.reset = function() { + return this.crc = this.INIT_CRC; + }; + + CRC.prototype.checksum = function(signed) { + var sum; + if (signed == null) { + signed = true; + } + sum = this.crc ^ this.XOR_MASK; + if (signed) { + sum = sum >>> 0; + } + return sum; + }; + + CRC.prototype.finish = function() { + return this.pack(this.checksum()); + }; + + CRC.prototype.hexdigest = function(value) { + var result; + if (value != null) { + this.update(value); + } + result = this.finish(); + this.reset(); + return result; + }; + + return CRC; + +})(); diff --git a/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/crc1.js b/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/crc1.js new file mode 100644 index 0000000..3cb4fa9 --- /dev/null +++ b/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/crc1.js @@ -0,0 +1,21 @@ +// Generated by CoffeeScript 1.7.1 +var Buffer, create; + +Buffer = require('buffer').Buffer; + +create = require('./create'); + +module.exports = create(function(buf, previous) { + var accum, byte, crc, _i, _len; + if (!Buffer.isBuffer(buf)) { + buf = Buffer(buf); + } + crc = ~~previous; + accum = 0; + for (_i = 0, _len = buf.length; _i < _len; _i++) { + byte = buf[_i]; + accum += byte; + } + crc += accum % 256; + return crc % 256; +}); diff --git a/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/crc16.js b/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/crc16.js new file mode 100644 index 0000000..f19faa8 --- /dev/null +++ b/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/crc16.js @@ -0,0 +1,25 @@ +// Generated by CoffeeScript 1.7.1 +var Buffer, TABLE, create; + +Buffer = require('buffer').Buffer; + +create = require('./create'); + +TABLE = [0x0000, 0xc0c1, 0xc181, 0x0140, 0xc301, 0x03c0, 0x0280, 0xc241, 0xc601, 0x06c0, 0x0780, 0xc741, 0x0500, 0xc5c1, 0xc481, 0x0440, 0xcc01, 0x0cc0, 0x0d80, 0xcd41, 0x0f00, 0xcfc1, 0xce81, 0x0e40, 0x0a00, 0xcac1, 0xcb81, 0x0b40, 0xc901, 0x09c0, 0x0880, 0xc841, 0xd801, 0x18c0, 0x1980, 0xd941, 0x1b00, 0xdbc1, 0xda81, 0x1a40, 0x1e00, 0xdec1, 0xdf81, 0x1f40, 0xdd01, 0x1dc0, 0x1c80, 0xdc41, 0x1400, 0xd4c1, 0xd581, 0x1540, 0xd701, 0x17c0, 0x1680, 0xd641, 0xd201, 0x12c0, 0x1380, 0xd341, 0x1100, 0xd1c1, 0xd081, 0x1040, 0xf001, 0x30c0, 0x3180, 0xf141, 0x3300, 0xf3c1, 0xf281, 0x3240, 0x3600, 0xf6c1, 0xf781, 0x3740, 0xf501, 0x35c0, 0x3480, 0xf441, 0x3c00, 0xfcc1, 0xfd81, 0x3d40, 0xff01, 0x3fc0, 0x3e80, 0xfe41, 0xfa01, 0x3ac0, 0x3b80, 0xfb41, 0x3900, 0xf9c1, 0xf881, 0x3840, 0x2800, 0xe8c1, 0xe981, 0x2940, 0xeb01, 0x2bc0, 0x2a80, 0xea41, 0xee01, 0x2ec0, 0x2f80, 0xef41, 0x2d00, 0xedc1, 0xec81, 0x2c40, 0xe401, 0x24c0, 0x2580, 0xe541, 0x2700, 0xe7c1, 0xe681, 0x2640, 0x2200, 0xe2c1, 0xe381, 0x2340, 0xe101, 0x21c0, 0x2080, 0xe041, 0xa001, 0x60c0, 0x6180, 0xa141, 0x6300, 0xa3c1, 0xa281, 0x6240, 0x6600, 0xa6c1, 0xa781, 0x6740, 0xa501, 0x65c0, 0x6480, 0xa441, 0x6c00, 0xacc1, 0xad81, 0x6d40, 0xaf01, 0x6fc0, 0x6e80, 0xae41, 0xaa01, 0x6ac0, 0x6b80, 0xab41, 0x6900, 0xa9c1, 0xa881, 0x6840, 0x7800, 0xb8c1, 0xb981, 0x7940, 0xbb01, 0x7bc0, 0x7a80, 0xba41, 0xbe01, 0x7ec0, 0x7f80, 0xbf41, 0x7d00, 0xbdc1, 0xbc81, 0x7c40, 0xb401, 0x74c0, 0x7580, 0xb541, 0x7700, 0xb7c1, 0xb681, 0x7640, 0x7200, 0xb2c1, 0xb381, 0x7340, 0xb101, 0x71c0, 0x7080, 0xb041, 0x5000, 0x90c1, 0x9181, 0x5140, 0x9301, 0x53c0, 0x5280, 0x9241, 0x9601, 0x56c0, 0x5780, 0x9741, 0x5500, 0x95c1, 0x9481, 0x5440, 0x9c01, 0x5cc0, 0x5d80, 0x9d41, 0x5f00, 0x9fc1, 0x9e81, 0x5e40, 0x5a00, 0x9ac1, 0x9b81, 0x5b40, 0x9901, 0x59c0, 0x5880, 0x9841, 0x8801, 0x48c0, 0x4980, 0x8941, 0x4b00, 0x8bc1, 0x8a81, 0x4a40, 0x4e00, 0x8ec1, 0x8f81, 0x4f40, 0x8d01, 0x4dc0, 0x4c80, 0x8c41, 0x4400, 0x84c1, 0x8581, 0x4540, 0x8701, 0x47c0, 0x4680, 0x8641, 0x8201, 0x42c0, 0x4380, 0x8341, 0x4100, 0x81c1, 0x8081, 0x4040]; + +if (typeof Int32Array !== 'undefined') { + TABLE = new Int32Array(TABLE); +} + +module.exports = create(function(buf, previous) { + var byte, crc, _i, _len; + if (!Buffer.isBuffer(buf)) { + buf = Buffer(buf); + } + crc = ~~previous; + for (_i = 0, _len = buf.length; _i < _len; _i++) { + byte = buf[_i]; + crc = (TABLE[(crc ^ byte) & 0xff] ^ (crc >> 8)) & 0xffff; + } + return crc; +}); diff --git a/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/crc16_ccitt.js b/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/crc16_ccitt.js new file mode 100644 index 0000000..5331638 --- /dev/null +++ b/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/crc16_ccitt.js @@ -0,0 +1,25 @@ +// Generated by CoffeeScript 1.7.1 +var Buffer, TABLE, create; + +Buffer = require('buffer').Buffer; + +create = require('./create'); + +TABLE = [0x0000, 0x1021, 0x2042, 0x3063, 0x4084, 0x50a5, 0x60c6, 0x70e7, 0x8108, 0x9129, 0xa14a, 0xb16b, 0xc18c, 0xd1ad, 0xe1ce, 0xf1ef, 0x1231, 0x0210, 0x3273, 0x2252, 0x52b5, 0x4294, 0x72f7, 0x62d6, 0x9339, 0x8318, 0xb37b, 0xa35a, 0xd3bd, 0xc39c, 0xf3ff, 0xe3de, 0x2462, 0x3443, 0x0420, 0x1401, 0x64e6, 0x74c7, 0x44a4, 0x5485, 0xa56a, 0xb54b, 0x8528, 0x9509, 0xe5ee, 0xf5cf, 0xc5ac, 0xd58d, 0x3653, 0x2672, 0x1611, 0x0630, 0x76d7, 0x66f6, 0x5695, 0x46b4, 0xb75b, 0xa77a, 0x9719, 0x8738, 0xf7df, 0xe7fe, 0xd79d, 0xc7bc, 0x48c4, 0x58e5, 0x6886, 0x78a7, 0x0840, 0x1861, 0x2802, 0x3823, 0xc9cc, 0xd9ed, 0xe98e, 0xf9af, 0x8948, 0x9969, 0xa90a, 0xb92b, 0x5af5, 0x4ad4, 0x7ab7, 0x6a96, 0x1a71, 0x0a50, 0x3a33, 0x2a12, 0xdbfd, 0xcbdc, 0xfbbf, 0xeb9e, 0x9b79, 0x8b58, 0xbb3b, 0xab1a, 0x6ca6, 0x7c87, 0x4ce4, 0x5cc5, 0x2c22, 0x3c03, 0x0c60, 0x1c41, 0xedae, 0xfd8f, 0xcdec, 0xddcd, 0xad2a, 0xbd0b, 0x8d68, 0x9d49, 0x7e97, 0x6eb6, 0x5ed5, 0x4ef4, 0x3e13, 0x2e32, 0x1e51, 0x0e70, 0xff9f, 0xefbe, 0xdfdd, 0xcffc, 0xbf1b, 0xaf3a, 0x9f59, 0x8f78, 0x9188, 0x81a9, 0xb1ca, 0xa1eb, 0xd10c, 0xc12d, 0xf14e, 0xe16f, 0x1080, 0x00a1, 0x30c2, 0x20e3, 0x5004, 0x4025, 0x7046, 0x6067, 0x83b9, 0x9398, 0xa3fb, 0xb3da, 0xc33d, 0xd31c, 0xe37f, 0xf35e, 0x02b1, 0x1290, 0x22f3, 0x32d2, 0x4235, 0x5214, 0x6277, 0x7256, 0xb5ea, 0xa5cb, 0x95a8, 0x8589, 0xf56e, 0xe54f, 0xd52c, 0xc50d, 0x34e2, 0x24c3, 0x14a0, 0x0481, 0x7466, 0x6447, 0x5424, 0x4405, 0xa7db, 0xb7fa, 0x8799, 0x97b8, 0xe75f, 0xf77e, 0xc71d, 0xd73c, 0x26d3, 0x36f2, 0x0691, 0x16b0, 0x6657, 0x7676, 0x4615, 0x5634, 0xd94c, 0xc96d, 0xf90e, 0xe92f, 0x99c8, 0x89e9, 0xb98a, 0xa9ab, 0x5844, 0x4865, 0x7806, 0x6827, 0x18c0, 0x08e1, 0x3882, 0x28a3, 0xcb7d, 0xdb5c, 0xeb3f, 0xfb1e, 0x8bf9, 0x9bd8, 0xabbb, 0xbb9a, 0x4a75, 0x5a54, 0x6a37, 0x7a16, 0x0af1, 0x1ad0, 0x2ab3, 0x3a92, 0xfd2e, 0xed0f, 0xdd6c, 0xcd4d, 0xbdaa, 0xad8b, 0x9de8, 0x8dc9, 0x7c26, 0x6c07, 0x5c64, 0x4c45, 0x3ca2, 0x2c83, 0x1ce0, 0x0cc1, 0xef1f, 0xff3e, 0xcf5d, 0xdf7c, 0xaf9b, 0xbfba, 0x8fd9, 0x9ff8, 0x6e17, 0x7e36, 0x4e55, 0x5e74, 0x2e93, 0x3eb2, 0x0ed1, 0x1ef0]; + +if (typeof Int32Array !== 'undefined') { + TABLE = new Int32Array(TABLE); +} + +module.exports = create(function(buf, previous) { + var byte, crc, _i, _len; + if (!Buffer.isBuffer(buf)) { + buf = Buffer(buf); + } + crc = ~~previous || 0xffff; + for (_i = 0, _len = buf.length; _i < _len; _i++) { + byte = buf[_i]; + crc = (TABLE[((crc >> 8) ^ byte) & 0xff] ^ (crc << 8)) & 0xffff; + } + return crc; +}); diff --git a/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/crc16_modbus.js b/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/crc16_modbus.js new file mode 100644 index 0000000..dcbd41b --- /dev/null +++ b/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/crc16_modbus.js @@ -0,0 +1,25 @@ +// Generated by CoffeeScript 1.7.1 +var Buffer, TABLE, create; + +Buffer = require('buffer').Buffer; + +create = require('./create'); + +TABLE = [0x0000, 0xc0c1, 0xc181, 0x0140, 0xc301, 0x03c0, 0x0280, 0xc241, 0xc601, 0x06c0, 0x0780, 0xc741, 0x0500, 0xc5c1, 0xc481, 0x0440, 0xcc01, 0x0cc0, 0x0d80, 0xcd41, 0x0f00, 0xcfc1, 0xce81, 0x0e40, 0x0a00, 0xcac1, 0xcb81, 0x0b40, 0xc901, 0x09c0, 0x0880, 0xc841, 0xd801, 0x18c0, 0x1980, 0xd941, 0x1b00, 0xdbc1, 0xda81, 0x1a40, 0x1e00, 0xdec1, 0xdf81, 0x1f40, 0xdd01, 0x1dc0, 0x1c80, 0xdc41, 0x1400, 0xd4c1, 0xd581, 0x1540, 0xd701, 0x17c0, 0x1680, 0xd641, 0xd201, 0x12c0, 0x1380, 0xd341, 0x1100, 0xd1c1, 0xd081, 0x1040, 0xf001, 0x30c0, 0x3180, 0xf141, 0x3300, 0xf3c1, 0xf281, 0x3240, 0x3600, 0xf6c1, 0xf781, 0x3740, 0xf501, 0x35c0, 0x3480, 0xf441, 0x3c00, 0xfcc1, 0xfd81, 0x3d40, 0xff01, 0x3fc0, 0x3e80, 0xfe41, 0xfa01, 0x3ac0, 0x3b80, 0xfb41, 0x3900, 0xf9c1, 0xf881, 0x3840, 0x2800, 0xe8c1, 0xe981, 0x2940, 0xeb01, 0x2bc0, 0x2a80, 0xea41, 0xee01, 0x2ec0, 0x2f80, 0xef41, 0x2d00, 0xedc1, 0xec81, 0x2c40, 0xe401, 0x24c0, 0x2580, 0xe541, 0x2700, 0xe7c1, 0xe681, 0x2640, 0x2200, 0xe2c1, 0xe381, 0x2340, 0xe101, 0x21c0, 0x2080, 0xe041, 0xa001, 0x60c0, 0x6180, 0xa141, 0x6300, 0xa3c1, 0xa281, 0x6240, 0x6600, 0xa6c1, 0xa781, 0x6740, 0xa501, 0x65c0, 0x6480, 0xa441, 0x6c00, 0xacc1, 0xad81, 0x6d40, 0xaf01, 0x6fc0, 0x6e80, 0xae41, 0xaa01, 0x6ac0, 0x6b80, 0xab41, 0x6900, 0xa9c1, 0xa881, 0x6840, 0x7800, 0xb8c1, 0xb981, 0x7940, 0xbb01, 0x7bc0, 0x7a80, 0xba41, 0xbe01, 0x7ec0, 0x7f80, 0xbf41, 0x7d00, 0xbdc1, 0xbc81, 0x7c40, 0xb401, 0x74c0, 0x7580, 0xb541, 0x7700, 0xb7c1, 0xb681, 0x7640, 0x7200, 0xb2c1, 0xb381, 0x7340, 0xb101, 0x71c0, 0x7080, 0xb041, 0x5000, 0x90c1, 0x9181, 0x5140, 0x9301, 0x53c0, 0x5280, 0x9241, 0x9601, 0x56c0, 0x5780, 0x9741, 0x5500, 0x95c1, 0x9481, 0x5440, 0x9c01, 0x5cc0, 0x5d80, 0x9d41, 0x5f00, 0x9fc1, 0x9e81, 0x5e40, 0x5a00, 0x9ac1, 0x9b81, 0x5b40, 0x9901, 0x59c0, 0x5880, 0x9841, 0x8801, 0x48c0, 0x4980, 0x8941, 0x4b00, 0x8bc1, 0x8a81, 0x4a40, 0x4e00, 0x8ec1, 0x8f81, 0x4f40, 0x8d01, 0x4dc0, 0x4c80, 0x8c41, 0x4400, 0x84c1, 0x8581, 0x4540, 0x8701, 0x47c0, 0x4680, 0x8641, 0x8201, 0x42c0, 0x4380, 0x8341, 0x4100, 0x81c1, 0x8081, 0x4040]; + +if (typeof Int32Array !== 'undefined') { + TABLE = new Int32Array(TABLE); +} + +module.exports = create(function(buf, previous) { + var byte, crc, _i, _len; + if (!Buffer.isBuffer(buf)) { + buf = Buffer(buf); + } + crc = ~~previous || 0xffff; + for (_i = 0, _len = buf.length; _i < _len; _i++) { + byte = buf[_i]; + crc = (TABLE[(crc ^ byte) & 0xff] ^ (crc >> 8)) & 0xffff; + } + return crc; +}); diff --git a/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/crc24.js b/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/crc24.js new file mode 100644 index 0000000..413d159 --- /dev/null +++ b/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/crc24.js @@ -0,0 +1,25 @@ +// Generated by CoffeeScript 1.7.1 +var Buffer, TABLE, create; + +Buffer = require('buffer').Buffer; + +create = require('./create'); + +TABLE = [0x000000, 0x864cfb, 0x8ad50d, 0x0c99f6, 0x93e6e1, 0x15aa1a, 0x1933ec, 0x9f7f17, 0xa18139, 0x27cdc2, 0x2b5434, 0xad18cf, 0x3267d8, 0xb42b23, 0xb8b2d5, 0x3efe2e, 0xc54e89, 0x430272, 0x4f9b84, 0xc9d77f, 0x56a868, 0xd0e493, 0xdc7d65, 0x5a319e, 0x64cfb0, 0xe2834b, 0xee1abd, 0x685646, 0xf72951, 0x7165aa, 0x7dfc5c, 0xfbb0a7, 0x0cd1e9, 0x8a9d12, 0x8604e4, 0x00481f, 0x9f3708, 0x197bf3, 0x15e205, 0x93aefe, 0xad50d0, 0x2b1c2b, 0x2785dd, 0xa1c926, 0x3eb631, 0xb8faca, 0xb4633c, 0x322fc7, 0xc99f60, 0x4fd39b, 0x434a6d, 0xc50696, 0x5a7981, 0xdc357a, 0xd0ac8c, 0x56e077, 0x681e59, 0xee52a2, 0xe2cb54, 0x6487af, 0xfbf8b8, 0x7db443, 0x712db5, 0xf7614e, 0x19a3d2, 0x9fef29, 0x9376df, 0x153a24, 0x8a4533, 0x0c09c8, 0x00903e, 0x86dcc5, 0xb822eb, 0x3e6e10, 0x32f7e6, 0xb4bb1d, 0x2bc40a, 0xad88f1, 0xa11107, 0x275dfc, 0xdced5b, 0x5aa1a0, 0x563856, 0xd074ad, 0x4f0bba, 0xc94741, 0xc5deb7, 0x43924c, 0x7d6c62, 0xfb2099, 0xf7b96f, 0x71f594, 0xee8a83, 0x68c678, 0x645f8e, 0xe21375, 0x15723b, 0x933ec0, 0x9fa736, 0x19ebcd, 0x8694da, 0x00d821, 0x0c41d7, 0x8a0d2c, 0xb4f302, 0x32bff9, 0x3e260f, 0xb86af4, 0x2715e3, 0xa15918, 0xadc0ee, 0x2b8c15, 0xd03cb2, 0x567049, 0x5ae9bf, 0xdca544, 0x43da53, 0xc596a8, 0xc90f5e, 0x4f43a5, 0x71bd8b, 0xf7f170, 0xfb6886, 0x7d247d, 0xe25b6a, 0x641791, 0x688e67, 0xeec29c, 0x3347a4, 0xb50b5f, 0xb992a9, 0x3fde52, 0xa0a145, 0x26edbe, 0x2a7448, 0xac38b3, 0x92c69d, 0x148a66, 0x181390, 0x9e5f6b, 0x01207c, 0x876c87, 0x8bf571, 0x0db98a, 0xf6092d, 0x7045d6, 0x7cdc20, 0xfa90db, 0x65efcc, 0xe3a337, 0xef3ac1, 0x69763a, 0x578814, 0xd1c4ef, 0xdd5d19, 0x5b11e2, 0xc46ef5, 0x42220e, 0x4ebbf8, 0xc8f703, 0x3f964d, 0xb9dab6, 0xb54340, 0x330fbb, 0xac70ac, 0x2a3c57, 0x26a5a1, 0xa0e95a, 0x9e1774, 0x185b8f, 0x14c279, 0x928e82, 0x0df195, 0x8bbd6e, 0x872498, 0x016863, 0xfad8c4, 0x7c943f, 0x700dc9, 0xf64132, 0x693e25, 0xef72de, 0xe3eb28, 0x65a7d3, 0x5b59fd, 0xdd1506, 0xd18cf0, 0x57c00b, 0xc8bf1c, 0x4ef3e7, 0x426a11, 0xc426ea, 0x2ae476, 0xaca88d, 0xa0317b, 0x267d80, 0xb90297, 0x3f4e6c, 0x33d79a, 0xb59b61, 0x8b654f, 0x0d29b4, 0x01b042, 0x87fcb9, 0x1883ae, 0x9ecf55, 0x9256a3, 0x141a58, 0xefaaff, 0x69e604, 0x657ff2, 0xe33309, 0x7c4c1e, 0xfa00e5, 0xf69913, 0x70d5e8, 0x4e2bc6, 0xc8673d, 0xc4fecb, 0x42b230, 0xddcd27, 0x5b81dc, 0x57182a, 0xd154d1, 0x26359f, 0xa07964, 0xace092, 0x2aac69, 0xb5d37e, 0x339f85, 0x3f0673, 0xb94a88, 0x87b4a6, 0x01f85d, 0x0d61ab, 0x8b2d50, 0x145247, 0x921ebc, 0x9e874a, 0x18cbb1, 0xe37b16, 0x6537ed, 0x69ae1b, 0xefe2e0, 0x709df7, 0xf6d10c, 0xfa48fa, 0x7c0401, 0x42fa2f, 0xc4b6d4, 0xc82f22, 0x4e63d9, 0xd11cce, 0x575035, 0x5bc9c3, 0xdd8538]; + +if (typeof Int32Array !== 'undefined') { + TABLE = new Int32Array(TABLE); +} + +module.exports = create(function(buf, previous) { + var byte, crc, _i, _len; + if (!Buffer.isBuffer(buf)) { + buf = Buffer(buf); + } + crc = ~~previous || 0xb704ce; + for (_i = 0, _len = buf.length; _i < _len; _i++) { + byte = buf[_i]; + crc = (TABLE[((crc >> 16) ^ byte) & 0xff] ^ (crc << 8)) & 0xffffff; + } + return crc; +}); diff --git a/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/crc32.js b/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/crc32.js new file mode 100644 index 0000000..eb2c85e --- /dev/null +++ b/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/crc32.js @@ -0,0 +1,25 @@ +// Generated by CoffeeScript 1.7.1 +var Buffer, TABLE, create; + +Buffer = require('buffer').Buffer; + +create = require('./create'); + +TABLE = [0x00000000, 0x77073096, 0xee0e612c, 0x990951ba, 0x076dc419, 0x706af48f, 0xe963a535, 0x9e6495a3, 0x0edb8832, 0x79dcb8a4, 0xe0d5e91e, 0x97d2d988, 0x09b64c2b, 0x7eb17cbd, 0xe7b82d07, 0x90bf1d91, 0x1db71064, 0x6ab020f2, 0xf3b97148, 0x84be41de, 0x1adad47d, 0x6ddde4eb, 0xf4d4b551, 0x83d385c7, 0x136c9856, 0x646ba8c0, 0xfd62f97a, 0x8a65c9ec, 0x14015c4f, 0x63066cd9, 0xfa0f3d63, 0x8d080df5, 0x3b6e20c8, 0x4c69105e, 0xd56041e4, 0xa2677172, 0x3c03e4d1, 0x4b04d447, 0xd20d85fd, 0xa50ab56b, 0x35b5a8fa, 0x42b2986c, 0xdbbbc9d6, 0xacbcf940, 0x32d86ce3, 0x45df5c75, 0xdcd60dcf, 0xabd13d59, 0x26d930ac, 0x51de003a, 0xc8d75180, 0xbfd06116, 0x21b4f4b5, 0x56b3c423, 0xcfba9599, 0xb8bda50f, 0x2802b89e, 0x5f058808, 0xc60cd9b2, 0xb10be924, 0x2f6f7c87, 0x58684c11, 0xc1611dab, 0xb6662d3d, 0x76dc4190, 0x01db7106, 0x98d220bc, 0xefd5102a, 0x71b18589, 0x06b6b51f, 0x9fbfe4a5, 0xe8b8d433, 0x7807c9a2, 0x0f00f934, 0x9609a88e, 0xe10e9818, 0x7f6a0dbb, 0x086d3d2d, 0x91646c97, 0xe6635c01, 0x6b6b51f4, 0x1c6c6162, 0x856530d8, 0xf262004e, 0x6c0695ed, 0x1b01a57b, 0x8208f4c1, 0xf50fc457, 0x65b0d9c6, 0x12b7e950, 0x8bbeb8ea, 0xfcb9887c, 0x62dd1ddf, 0x15da2d49, 0x8cd37cf3, 0xfbd44c65, 0x4db26158, 0x3ab551ce, 0xa3bc0074, 0xd4bb30e2, 0x4adfa541, 0x3dd895d7, 0xa4d1c46d, 0xd3d6f4fb, 0x4369e96a, 0x346ed9fc, 0xad678846, 0xda60b8d0, 0x44042d73, 0x33031de5, 0xaa0a4c5f, 0xdd0d7cc9, 0x5005713c, 0x270241aa, 0xbe0b1010, 0xc90c2086, 0x5768b525, 0x206f85b3, 0xb966d409, 0xce61e49f, 0x5edef90e, 0x29d9c998, 0xb0d09822, 0xc7d7a8b4, 0x59b33d17, 0x2eb40d81, 0xb7bd5c3b, 0xc0ba6cad, 0xedb88320, 0x9abfb3b6, 0x03b6e20c, 0x74b1d29a, 0xead54739, 0x9dd277af, 0x04db2615, 0x73dc1683, 0xe3630b12, 0x94643b84, 0x0d6d6a3e, 0x7a6a5aa8, 0xe40ecf0b, 0x9309ff9d, 0x0a00ae27, 0x7d079eb1, 0xf00f9344, 0x8708a3d2, 0x1e01f268, 0x6906c2fe, 0xf762575d, 0x806567cb, 0x196c3671, 0x6e6b06e7, 0xfed41b76, 0x89d32be0, 0x10da7a5a, 0x67dd4acc, 0xf9b9df6f, 0x8ebeeff9, 0x17b7be43, 0x60b08ed5, 0xd6d6a3e8, 0xa1d1937e, 0x38d8c2c4, 0x4fdff252, 0xd1bb67f1, 0xa6bc5767, 0x3fb506dd, 0x48b2364b, 0xd80d2bda, 0xaf0a1b4c, 0x36034af6, 0x41047a60, 0xdf60efc3, 0xa867df55, 0x316e8eef, 0x4669be79, 0xcb61b38c, 0xbc66831a, 0x256fd2a0, 0x5268e236, 0xcc0c7795, 0xbb0b4703, 0x220216b9, 0x5505262f, 0xc5ba3bbe, 0xb2bd0b28, 0x2bb45a92, 0x5cb36a04, 0xc2d7ffa7, 0xb5d0cf31, 0x2cd99e8b, 0x5bdeae1d, 0x9b64c2b0, 0xec63f226, 0x756aa39c, 0x026d930a, 0x9c0906a9, 0xeb0e363f, 0x72076785, 0x05005713, 0x95bf4a82, 0xe2b87a14, 0x7bb12bae, 0x0cb61b38, 0x92d28e9b, 0xe5d5be0d, 0x7cdcefb7, 0x0bdbdf21, 0x86d3d2d4, 0xf1d4e242, 0x68ddb3f8, 0x1fda836e, 0x81be16cd, 0xf6b9265b, 0x6fb077e1, 0x18b74777, 0x88085ae6, 0xff0f6a70, 0x66063bca, 0x11010b5c, 0x8f659eff, 0xf862ae69, 0x616bffd3, 0x166ccf45, 0xa00ae278, 0xd70dd2ee, 0x4e048354, 0x3903b3c2, 0xa7672661, 0xd06016f7, 0x4969474d, 0x3e6e77db, 0xaed16a4a, 0xd9d65adc, 0x40df0b66, 0x37d83bf0, 0xa9bcae53, 0xdebb9ec5, 0x47b2cf7f, 0x30b5ffe9, 0xbdbdf21c, 0xcabac28a, 0x53b39330, 0x24b4a3a6, 0xbad03605, 0xcdd70693, 0x54de5729, 0x23d967bf, 0xb3667a2e, 0xc4614ab8, 0x5d681b02, 0x2a6f2b94, 0xb40bbe37, 0xc30c8ea1, 0x5a05df1b, 0x2d02ef8d]; + +if (typeof Int32Array !== 'undefined') { + TABLE = new Int32Array(TABLE); +} + +module.exports = create(function(buf, previous) { + var byte, crc, _i, _len; + if (!Buffer.isBuffer(buf)) { + buf = Buffer(buf); + } + crc = ~~previous ^ -1; + for (_i = 0, _len = buf.length; _i < _len; _i++) { + byte = buf[_i]; + crc = TABLE[(crc ^ byte) & 0xff] ^ (crc >>> 8); + } + return crc ^ -1; +}); diff --git a/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/crc8.js b/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/crc8.js new file mode 100644 index 0000000..d6518c1 --- /dev/null +++ b/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/crc8.js @@ -0,0 +1,25 @@ +// Generated by CoffeeScript 1.7.1 +var Buffer, TABLE, create; + +Buffer = require('buffer').Buffer; + +create = require('./create'); + +TABLE = [0x00, 0x07, 0x0e, 0x09, 0x1c, 0x1b, 0x12, 0x15, 0x38, 0x3f, 0x36, 0x31, 0x24, 0x23, 0x2a, 0x2d, 0x70, 0x77, 0x7e, 0x79, 0x6c, 0x6b, 0x62, 0x65, 0x48, 0x4f, 0x46, 0x41, 0x54, 0x53, 0x5a, 0x5d, 0xe0, 0xe7, 0xee, 0xe9, 0xfc, 0xfb, 0xf2, 0xf5, 0xd8, 0xdf, 0xd6, 0xd1, 0xc4, 0xc3, 0xca, 0xcd, 0x90, 0x97, 0x9e, 0x99, 0x8c, 0x8b, 0x82, 0x85, 0xa8, 0xaf, 0xa6, 0xa1, 0xb4, 0xb3, 0xba, 0xbd, 0xc7, 0xc0, 0xc9, 0xce, 0xdb, 0xdc, 0xd5, 0xd2, 0xff, 0xf8, 0xf1, 0xf6, 0xe3, 0xe4, 0xed, 0xea, 0xb7, 0xb0, 0xb9, 0xbe, 0xab, 0xac, 0xa5, 0xa2, 0x8f, 0x88, 0x81, 0x86, 0x93, 0x94, 0x9d, 0x9a, 0x27, 0x20, 0x29, 0x2e, 0x3b, 0x3c, 0x35, 0x32, 0x1f, 0x18, 0x11, 0x16, 0x03, 0x04, 0x0d, 0x0a, 0x57, 0x50, 0x59, 0x5e, 0x4b, 0x4c, 0x45, 0x42, 0x6f, 0x68, 0x61, 0x66, 0x73, 0x74, 0x7d, 0x7a, 0x89, 0x8e, 0x87, 0x80, 0x95, 0x92, 0x9b, 0x9c, 0xb1, 0xb6, 0xbf, 0xb8, 0xad, 0xaa, 0xa3, 0xa4, 0xf9, 0xfe, 0xf7, 0xf0, 0xe5, 0xe2, 0xeb, 0xec, 0xc1, 0xc6, 0xcf, 0xc8, 0xdd, 0xda, 0xd3, 0xd4, 0x69, 0x6e, 0x67, 0x60, 0x75, 0x72, 0x7b, 0x7c, 0x51, 0x56, 0x5f, 0x58, 0x4d, 0x4a, 0x43, 0x44, 0x19, 0x1e, 0x17, 0x10, 0x05, 0x02, 0x0b, 0x0c, 0x21, 0x26, 0x2f, 0x28, 0x3d, 0x3a, 0x33, 0x34, 0x4e, 0x49, 0x40, 0x47, 0x52, 0x55, 0x5c, 0x5b, 0x76, 0x71, 0x78, 0x7f, 0x6a, 0x6d, 0x64, 0x63, 0x3e, 0x39, 0x30, 0x37, 0x22, 0x25, 0x2c, 0x2b, 0x06, 0x01, 0x08, 0x0f, 0x1a, 0x1d, 0x14, 0x13, 0xae, 0xa9, 0xa0, 0xa7, 0xb2, 0xb5, 0xbc, 0xbb, 0x96, 0x91, 0x98, 0x9f, 0x8a, 0x8d, 0x84, 0x83, 0xde, 0xd9, 0xd0, 0xd7, 0xc2, 0xc5, 0xcc, 0xcb, 0xe6, 0xe1, 0xe8, 0xef, 0xfa, 0xfd, 0xf4, 0xf3]; + +if (typeof Int32Array !== 'undefined') { + TABLE = new Int32Array(TABLE); +} + +module.exports = create(function(buf, previous) { + var byte, crc, _i, _len; + if (!Buffer.isBuffer(buf)) { + buf = Buffer(buf); + } + crc = ~~previous; + for (_i = 0, _len = buf.length; _i < _len; _i++) { + byte = buf[_i]; + crc = (TABLE[(crc ^ byte) & 0xff] ^ (crc << 8)) & 0xff; + } + return crc; +}); diff --git a/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/crc8_1wire.js b/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/crc8_1wire.js new file mode 100644 index 0000000..c63a422 --- /dev/null +++ b/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/crc8_1wire.js @@ -0,0 +1,25 @@ +// Generated by CoffeeScript 1.7.1 +var Buffer, TABLE, create; + +Buffer = require('buffer').Buffer; + +create = require('./create'); + +TABLE = [0x00, 0x5e, 0xbc, 0xe2, 0x61, 0x3f, 0xdd, 0x83, 0xc2, 0x9c, 0x7e, 0x20, 0xa3, 0xfd, 0x1f, 0x41, 0x9d, 0xc3, 0x21, 0x7f, 0xfc, 0xa2, 0x40, 0x1e, 0x5f, 0x01, 0xe3, 0xbd, 0x3e, 0x60, 0x82, 0xdc, 0x23, 0x7d, 0x9f, 0xc1, 0x42, 0x1c, 0xfe, 0xa0, 0xe1, 0xbf, 0x5d, 0x03, 0x80, 0xde, 0x3c, 0x62, 0xbe, 0xe0, 0x02, 0x5c, 0xdf, 0x81, 0x63, 0x3d, 0x7c, 0x22, 0xc0, 0x9e, 0x1d, 0x43, 0xa1, 0xff, 0x46, 0x18, 0xfa, 0xa4, 0x27, 0x79, 0x9b, 0xc5, 0x84, 0xda, 0x38, 0x66, 0xe5, 0xbb, 0x59, 0x07, 0xdb, 0x85, 0x67, 0x39, 0xba, 0xe4, 0x06, 0x58, 0x19, 0x47, 0xa5, 0xfb, 0x78, 0x26, 0xc4, 0x9a, 0x65, 0x3b, 0xd9, 0x87, 0x04, 0x5a, 0xb8, 0xe6, 0xa7, 0xf9, 0x1b, 0x45, 0xc6, 0x98, 0x7a, 0x24, 0xf8, 0xa6, 0x44, 0x1a, 0x99, 0xc7, 0x25, 0x7b, 0x3a, 0x64, 0x86, 0xd8, 0x5b, 0x05, 0xe7, 0xb9, 0x8c, 0xd2, 0x30, 0x6e, 0xed, 0xb3, 0x51, 0x0f, 0x4e, 0x10, 0xf2, 0xac, 0x2f, 0x71, 0x93, 0xcd, 0x11, 0x4f, 0xad, 0xf3, 0x70, 0x2e, 0xcc, 0x92, 0xd3, 0x8d, 0x6f, 0x31, 0xb2, 0xec, 0x0e, 0x50, 0xaf, 0xf1, 0x13, 0x4d, 0xce, 0x90, 0x72, 0x2c, 0x6d, 0x33, 0xd1, 0x8f, 0x0c, 0x52, 0xb0, 0xee, 0x32, 0x6c, 0x8e, 0xd0, 0x53, 0x0d, 0xef, 0xb1, 0xf0, 0xae, 0x4c, 0x12, 0x91, 0xcf, 0x2d, 0x73, 0xca, 0x94, 0x76, 0x28, 0xab, 0xf5, 0x17, 0x49, 0x08, 0x56, 0xb4, 0xea, 0x69, 0x37, 0xd5, 0x8b, 0x57, 0x09, 0xeb, 0xb5, 0x36, 0x68, 0x8a, 0xd4, 0x95, 0xcb, 0x29, 0x77, 0xf4, 0xaa, 0x48, 0x16, 0xe9, 0xb7, 0x55, 0x0b, 0x88, 0xd6, 0x34, 0x6a, 0x2b, 0x75, 0x97, 0xc9, 0x4a, 0x14, 0xf6, 0xa8, 0x74, 0x2a, 0xc8, 0x96, 0x15, 0x4b, 0xa9, 0xf7, 0xb6, 0xe8, 0x0a, 0x54, 0xd7, 0x89, 0x6b, 0x35]; + +if (typeof Int32Array !== 'undefined') { + TABLE = new Int32Array(TABLE); +} + +module.exports = create(function(buf, previous) { + var byte, crc, _i, _len; + if (!Buffer.isBuffer(buf)) { + buf = Buffer(buf); + } + crc = ~~previous; + for (_i = 0, _len = buf.length; _i < _len; _i++) { + byte = buf[_i]; + crc = (TABLE[(crc ^ byte) & 0xff] ^ (crc << 8)) & 0xff; + } + return crc; +}); diff --git a/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/create.js b/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/create.js new file mode 100644 index 0000000..df4d991 --- /dev/null +++ b/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/create.js @@ -0,0 +1,10 @@ +// Generated by CoffeeScript 1.7.1 +module.exports = function(calc) { + var fn; + fn = function(buf, previous) { + return calc(buf, previous) >>> 0; + }; + fn.signed = calc; + fn.unsigned = fn; + return fn; +}; diff --git a/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/hex.js b/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/hex.js new file mode 100644 index 0000000..0a6aa4c --- /dev/null +++ b/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/hex.js @@ -0,0 +1,9 @@ +// Generated by CoffeeScript 1.7.1 +module.exports = function(number) { + var result; + result = number.toString(16); + while (result.length % 2) { + result = "0" + result; + } + return result; +}; diff --git a/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/index.js b/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/index.js new file mode 100644 index 0000000..15ac34c --- /dev/null +++ b/node_modules/serve-favicon/node_modules/etag/node_modules/crc/lib/index.js @@ -0,0 +1,11 @@ +// Generated by CoffeeScript 1.7.1 +module.exports = { + crc1: require('./crc1'), + crc8: require('./crc8'), + crc81wire: require('./crc8_1wire'), + crc16: require('./crc16'), + crc16ccitt: require('./crc16_ccitt'), + crc16modbus: require('./crc16_modbus'), + crc24: require('./crc24'), + crc32: require('./crc32') +}; diff --git a/node_modules/serve-favicon/node_modules/etag/node_modules/crc/package.json b/node_modules/serve-favicon/node_modules/etag/node_modules/crc/package.json new file mode 100644 index 0000000..5d8586f --- /dev/null +++ b/node_modules/serve-favicon/node_modules/etag/node_modules/crc/package.json @@ -0,0 +1,57 @@ +{ + "name": "crc", + "version": "3.0.0", + "description": "Various CRC JavaScript implementations", + "keywords": [ + "crc" + ], + "main": "./lib/index.js", + "scripts": { + "test": "mocha test/*.spec.coffee", + "pretest": "coffee --bare --output ./lib --compile ./src/*.coffee" + }, + "author": { + "name": "Alex Gorbatchev", + "url": "https://github.com/alexgorbatchev" + }, + "devDependencies": { + "beautify-benchmark": "^0.2.4", + "benchmark": "^1.0.0", + "buffer-crc32": "^0.2.3", + "chai": "~1.9.1", + "coffee-errors": "~0.8.6", + "coffee-script": "~1.7.1", + "mocha": "*", + "seedrandom": "^2.3.6" + }, + "homepage": "https://github.com/alexgorbatchev/node-crc", + "bugs": { + "url": "https://github.com/alexgorbatchev/node-crc/issues" + }, + "repository": { + "type": "git", + "url": "git://github.com/alexgorbatchev/node-crc.git" + }, + "license": "MIT", + "gitHead": "16dbe7ca019d73be10e99c2f5fa690dcbfc0dd40", + "_id": "crc@3.0.0", + "_shasum": "d11e97ec44a844e5eb15a74fa2c7875d0aac4b22", + "_from": "crc@3.0.0", + "_npmVersion": "2.0.0-beta.0", + "_npmUser": { + "name": "alexgorbatchev", + "email": "alex.gorbatchev@gmail.com" + }, + "maintainers": [ + { + "name": "alexgorbatchev", + "email": "alex.gorbatchev@gmail.com" + } + ], + "dist": { + "shasum": "d11e97ec44a844e5eb15a74fa2c7875d0aac4b22", + "tarball": "http://registry.npmjs.org/crc/-/crc-3.0.0.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/crc/-/crc-3.0.0.tgz" +} diff --git a/node_modules/serve-favicon/node_modules/etag/package.json b/node_modules/serve-favicon/node_modules/etag/package.json new file mode 100644 index 0000000..c33c203 --- /dev/null +++ b/node_modules/serve-favicon/node_modules/etag/package.json @@ -0,0 +1,74 @@ +{ + "name": "etag", + "description": "Create simple ETags", + "version": "1.3.1", + "contributors": [ + { + "name": "Douglas Christopher Wilson", + "email": "doug@somethingdoug.com" + }, + { + "name": "David Björklund", + "email": "david.bjorklund@gmail.com" + } + ], + "license": "MIT", + "keywords": [ + "etag", + "http", + "res" + ], + "repository": { + "type": "git", + "url": "https://github.com/jshttp/etag" + }, + "dependencies": { + "crc": "3.0.0" + }, + "devDependencies": { + "benchmark": "1.0.0", + "beautify-benchmark": "0.2.4", + "istanbul": "0.3.2", + "mocha": "~1.21.4", + "seedrandom": "~2.3.6" + }, + "files": [ + "LICENSE", + "HISTORY.md", + "index.js" + ], + "engines": { + "node": ">= 0.8" + }, + "scripts": { + "bench": "node benchmark/index.js", + "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/" + }, + "gitHead": "88a83fdccc15065893cfad6e2c7af8a379941f16", + "bugs": { + "url": "https://github.com/jshttp/etag/issues" + }, + "homepage": "https://github.com/jshttp/etag", + "_id": "etag@1.3.1", + "_shasum": "e51925728688a32dc4eea1cfa9ab4f734d055567", + "_from": "etag@~1.3.1", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + "maintainers": [ + { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + } + ], + "dist": { + "shasum": "e51925728688a32dc4eea1cfa9ab4f734d055567", + "tarball": "http://registry.npmjs.org/etag/-/etag-1.3.1.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/etag/-/etag-1.3.1.tgz" +} diff --git a/node_modules/serve-favicon/node_modules/fresh/HISTORY.md b/node_modules/serve-favicon/node_modules/fresh/HISTORY.md new file mode 100644 index 0000000..56361df --- /dev/null +++ b/node_modules/serve-favicon/node_modules/fresh/HISTORY.md @@ -0,0 +1,24 @@ +0.2.4 / 2014-09-07 +================== + + * Support Node.js 0.6 + +0.2.3 / 2014-09-07 +================== + + * Move repository to jshttp + +0.2.2 / 2014-02-19 +================== + + * Revert "Fix for blank page on Safari reload" + +0.2.1 / 2014-01-29 +================== + + * fix: support max-age=0 for end-to-end revalidation + +0.2.0 / 2013-08-11 +================== + + * fix: return false for no-cache diff --git a/node_modules/serve-favicon/node_modules/fresh/LICENSE b/node_modules/serve-favicon/node_modules/fresh/LICENSE new file mode 100644 index 0000000..f527394 --- /dev/null +++ b/node_modules/serve-favicon/node_modules/fresh/LICENSE @@ -0,0 +1,22 @@ +(The MIT License) + +Copyright (c) 2012 TJ Holowaychuk + +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/node_modules/serve-favicon/node_modules/fresh/README.md b/node_modules/serve-favicon/node_modules/fresh/README.md new file mode 100644 index 0000000..54a885f --- /dev/null +++ b/node_modules/serve-favicon/node_modules/fresh/README.md @@ -0,0 +1,58 @@ +# fresh + +[![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] + +HTTP response freshness testing + +## Installation + +``` +$ npm install fresh +``` + +## API + +```js +var fresh = require('fresh') +``` + +### fresh(req, res) + + Check freshness of `req` and `res` headers. + + When the cache is "fresh" __true__ is returned, + otherwise __false__ is returned to indicate that + the cache is now stale. + +## Example + +```js +var req = { 'if-none-match': 'tobi' }; +var res = { 'etag': 'luna' }; +fresh(req, res); +// => false + +var req = { 'if-none-match': 'tobi' }; +var res = { 'etag': 'tobi' }; +fresh(req, res); +// => true +``` + +## License + +[MIT](LICENSE) + +[npm-image]: https://img.shields.io/npm/v/fresh.svg?style=flat +[npm-url]: https://npmjs.org/package/fresh +[node-version-image]: https://img.shields.io/badge/node.js-%3E%3D_0.6-brightgreen.svg?style=flat +[node-version-url]: http://nodejs.org/download/ +[travis-image]: https://img.shields.io/travis/jshttp/fresh.svg?style=flat +[travis-url]: https://travis-ci.org/jshttp/fresh +[coveralls-image]: https://img.shields.io/coveralls/jshttp/fresh.svg?style=flat +[coveralls-url]: https://coveralls.io/r/jshttp/fresh?branch=master +[downloads-image]: https://img.shields.io/npm/dm/fresh.svg?style=flat +[downloads-url]: https://npmjs.org/package/fresh diff --git a/node_modules/serve-favicon/node_modules/fresh/index.js b/node_modules/serve-favicon/node_modules/fresh/index.js new file mode 100644 index 0000000..9c3f47d --- /dev/null +++ b/node_modules/serve-favicon/node_modules/fresh/index.js @@ -0,0 +1,53 @@ + +/** + * Expose `fresh()`. + */ + +module.exports = fresh; + +/** + * Check freshness of `req` and `res` headers. + * + * When the cache is "fresh" __true__ is returned, + * otherwise __false__ is returned to indicate that + * the cache is now stale. + * + * @param {Object} req + * @param {Object} res + * @return {Boolean} + * @api public + */ + +function fresh(req, res) { + // defaults + var etagMatches = true; + var notModified = true; + + // fields + var modifiedSince = req['if-modified-since']; + var noneMatch = req['if-none-match']; + var lastModified = res['last-modified']; + var etag = res['etag']; + var cc = req['cache-control']; + + // unconditional request + if (!modifiedSince && !noneMatch) return false; + + // check for no-cache cache request directive + if (cc && cc.indexOf('no-cache') !== -1) return false; + + // parse if-none-match + if (noneMatch) noneMatch = noneMatch.split(/ *, */); + + // if-none-match + if (noneMatch) etagMatches = ~noneMatch.indexOf(etag) || '*' == noneMatch[0]; + + // if-modified-since + if (modifiedSince) { + modifiedSince = new Date(modifiedSince); + lastModified = new Date(lastModified); + notModified = lastModified <= modifiedSince; + } + + return !! (etagMatches && notModified); +} \ No newline at end of file diff --git a/node_modules/serve-favicon/node_modules/fresh/package.json b/node_modules/serve-favicon/node_modules/fresh/package.json new file mode 100644 index 0000000..e25b3a7 --- /dev/null +++ b/node_modules/serve-favicon/node_modules/fresh/package.json @@ -0,0 +1,76 @@ +{ + "name": "fresh", + "description": "HTTP response freshness testing", + "version": "0.2.4", + "author": { + "name": "TJ Holowaychuk", + "email": "tj@vision-media.ca", + "url": "http://tjholowaychuk.com" + }, + "license": "MIT", + "keywords": [ + "fresh", + "http", + "conditional", + "cache" + ], + "repository": { + "type": "git", + "url": "https://github.com/jshttp/fresh" + }, + "devDependencies": { + "istanbul": "0", + "mocha": "1", + "should": "3" + }, + "files": [ + "HISTORY.md", + "LICENSE", + "index.js" + ], + "engines": { + "node": ">= 0.6" + }, + "scripts": { + "test": "mocha --reporter spec --require should", + "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --require should", + "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter dot --require should" + }, + "gitHead": "8440a4ca75fb091dec06e88654b3b1c31d7e7164", + "bugs": { + "url": "https://github.com/jshttp/fresh/issues" + }, + "homepage": "https://github.com/jshttp/fresh", + "_id": "fresh@0.2.4", + "_shasum": "3582499206c9723714190edd74b4604feb4a614c", + "_from": "fresh@0.2.4", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + "maintainers": [ + { + "name": "tjholowaychuk", + "email": "tj@vision-media.ca" + }, + { + "name": "jonathanong", + "email": "jonathanrichardong@gmail.com" + }, + { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + { + "name": "jongleberry", + "email": "jonathanrichardong@gmail.com" + } + ], + "dist": { + "shasum": "3582499206c9723714190edd74b4604feb4a614c", + "tarball": "http://registry.npmjs.org/fresh/-/fresh-0.2.4.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/fresh/-/fresh-0.2.4.tgz" +} diff --git a/node_modules/serve-favicon/node_modules/ms/.npmignore b/node_modules/serve-favicon/node_modules/ms/.npmignore new file mode 100644 index 0000000..d1aa0ce --- /dev/null +++ b/node_modules/serve-favicon/node_modules/ms/.npmignore @@ -0,0 +1,5 @@ +node_modules +test +History.md +Makefile +component.json diff --git a/node_modules/serve-favicon/node_modules/ms/README.md b/node_modules/serve-favicon/node_modules/ms/README.md new file mode 100644 index 0000000..d4ab12a --- /dev/null +++ b/node_modules/serve-favicon/node_modules/ms/README.md @@ -0,0 +1,33 @@ +# ms.js: miliseconds conversion utility + +```js +ms('1d') // 86400000 +ms('10h') // 36000000 +ms('2h') // 7200000 +ms('1m') // 60000 +ms('5s') // 5000 +ms('100') // 100 +``` + +```js +ms(60000) // "1m" +ms(2 * 60000) // "2m" +ms(ms('10 hours')) // "10h" +``` + +```js +ms(60000, { long: true }) // "1 minute" +ms(2 * 60000, { long: true }) // "2 minutes" +ms(ms('10 hours', { long: true })) // "10 hours" +``` + +- Node/Browser compatible. Published as `ms` in NPM. +- If a number is supplied to `ms`, a string with a unit is returned. +- If a string that contains the number is supplied, it returns it as +a number (e.g: it returns `100` for `'100'`). +- If you pass a string with a number and a valid unit, the number of +equivalent ms is returned. + +## License + +MIT \ No newline at end of file diff --git a/node_modules/serve-favicon/node_modules/ms/index.js b/node_modules/serve-favicon/node_modules/ms/index.js new file mode 100644 index 0000000..c5847f8 --- /dev/null +++ b/node_modules/serve-favicon/node_modules/ms/index.js @@ -0,0 +1,111 @@ +/** + * Helpers. + */ + +var s = 1000; +var m = s * 60; +var h = m * 60; +var d = h * 24; +var y = d * 365.25; + +/** + * Parse or format the given `val`. + * + * Options: + * + * - `long` verbose formatting [false] + * + * @param {String|Number} val + * @param {Object} options + * @return {String|Number} + * @api public + */ + +module.exports = function(val, options){ + options = options || {}; + if ('string' == typeof val) return parse(val); + return options.long + ? long(val) + : short(val); +}; + +/** + * Parse the given `str` and return milliseconds. + * + * @param {String} str + * @return {Number} + * @api private + */ + +function parse(str) { + var match = /^((?:\d+)?\.?\d+) *(ms|seconds?|s|minutes?|m|hours?|h|days?|d|years?|y)?$/i.exec(str); + if (!match) return; + var n = parseFloat(match[1]); + var type = (match[2] || 'ms').toLowerCase(); + switch (type) { + case 'years': + case 'year': + case 'y': + return n * y; + case 'days': + case 'day': + case 'd': + return n * d; + case 'hours': + case 'hour': + case 'h': + return n * h; + case 'minutes': + case 'minute': + case 'm': + return n * m; + case 'seconds': + case 'second': + case 's': + return n * s; + case 'ms': + return n; + } +} + +/** + * Short format for `ms`. + * + * @param {Number} ms + * @return {String} + * @api private + */ + +function short(ms) { + if (ms >= d) return Math.round(ms / d) + 'd'; + if (ms >= h) return Math.round(ms / h) + 'h'; + if (ms >= m) return Math.round(ms / m) + 'm'; + if (ms >= s) return Math.round(ms / s) + 's'; + return ms + 'ms'; +} + +/** + * Long format for `ms`. + * + * @param {Number} ms + * @return {String} + * @api private + */ + +function long(ms) { + return plural(ms, d, 'day') + || plural(ms, h, 'hour') + || plural(ms, m, 'minute') + || plural(ms, s, 'second') + || ms + ' ms'; +} + +/** + * Pluralization helper. + */ + +function plural(ms, n, name) { + if (ms < n) return; + if (ms < n * 1.5) return Math.floor(ms / n) + ' ' + name; + return Math.ceil(ms / n) + ' ' + name + 's'; +} diff --git a/node_modules/serve-favicon/node_modules/ms/package.json b/node_modules/serve-favicon/node_modules/ms/package.json new file mode 100644 index 0000000..5c2c010 --- /dev/null +++ b/node_modules/serve-favicon/node_modules/ms/package.json @@ -0,0 +1,46 @@ +{ + "name": "ms", + "version": "0.6.2", + "description": "Tiny ms conversion utility", + "repository": { + "type": "git", + "url": "git://github.com/guille/ms.js.git" + }, + "main": "./index", + "devDependencies": { + "mocha": "*", + "expect.js": "*", + "serve": "*" + }, + "component": { + "scripts": { + "ms/index.js": "index.js" + } + }, + "readme": "# ms.js: miliseconds conversion utility\n\n```js\nms('1d') // 86400000\nms('10h') // 36000000\nms('2h') // 7200000\nms('1m') // 60000\nms('5s') // 5000\nms('100') // 100\n```\n\n```js\nms(60000) // \"1m\"\nms(2 * 60000) // \"2m\"\nms(ms('10 hours')) // \"10h\"\n```\n\n```js\nms(60000, { long: true }) // \"1 minute\"\nms(2 * 60000, { long: true }) // \"2 minutes\"\nms(ms('10 hours', { long: true })) // \"10 hours\"\n```\n\n- Node/Browser compatible. Published as `ms` in NPM.\n- If a number is supplied to `ms`, a string with a unit is returned.\n- If a string that contains the number is supplied, it returns it as\na number (e.g: it returns `100` for `'100'`).\n- If you pass a string with a number and a valid unit, the number of\nequivalent ms is returned.\n\n## License\n\nMIT", + "readmeFilename": "README.md", + "bugs": { + "url": "https://github.com/guille/ms.js/issues" + }, + "_id": "ms@0.6.2", + "dist": { + "shasum": "d89c2124c6fdc1353d65a8b77bf1aac4b193708c", + "tarball": "http://registry.npmjs.org/ms/-/ms-0.6.2.tgz" + }, + "_from": "ms@0.6.2", + "_npmVersion": "1.2.30", + "_npmUser": { + "name": "rauchg", + "email": "rauchg@gmail.com" + }, + "maintainers": [ + { + "name": "rauchg", + "email": "rauchg@gmail.com" + } + ], + "directories": {}, + "_shasum": "d89c2124c6fdc1353d65a8b77bf1aac4b193708c", + "_resolved": "https://registry.npmjs.org/ms/-/ms-0.6.2.tgz", + "scripts": {} +} diff --git a/node_modules/serve-favicon/package.json b/node_modules/serve-favicon/package.json new file mode 100644 index 0000000..065d535 --- /dev/null +++ b/node_modules/serve-favicon/package.json @@ -0,0 +1,69 @@ +{ + "name": "serve-favicon", + "description": "favicon serving middleware with caching", + "version": "2.1.4", + "author": { + "name": "Douglas Christopher Wilson", + "email": "doug@somethingdoug.com" + }, + "license": "MIT", + "keywords": [ + "express", + "favicon", + "middleware" + ], + "repository": { + "type": "git", + "url": "https://github.com/expressjs/serve-favicon" + }, + "dependencies": { + "etag": "~1.3.1", + "fresh": "0.2.4", + "ms": "0.6.2" + }, + "devDependencies": { + "istanbul": "0.3.2", + "mocha": "~1.21.4", + "proxyquire": "~1.0.1", + "should": "~4.0.1", + "supertest": "~0.13.0" + }, + "files": [ + "LICENSE", + "HISTORY.md", + "index.js" + ], + "engines": { + "node": ">= 0.8.0" + }, + "scripts": { + "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/" + }, + "gitHead": "1e95c3148b2e4010bf4e63f60be98ec15e648d65", + "bugs": { + "url": "https://github.com/expressjs/serve-favicon/issues" + }, + "homepage": "https://github.com/expressjs/serve-favicon", + "_id": "serve-favicon@2.1.4", + "_shasum": "f0fb9256649949b377269370eadd4c2741d7a079", + "_from": "serve-favicon@2.1.4", + "_npmVersion": "1.4.21", + "_npmUser": { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + }, + "maintainers": [ + { + "name": "dougwilson", + "email": "doug@somethingdoug.com" + } + ], + "dist": { + "shasum": "f0fb9256649949b377269370eadd4c2741d7a079", + "tarball": "http://registry.npmjs.org/serve-favicon/-/serve-favicon-2.1.4.tgz" + }, + "directories": {}, + "_resolved": "https://registry.npmjs.org/serve-favicon/-/serve-favicon-2.1.4.tgz" +} diff --git a/npm-debug.log b/npm-debug.log new file mode 100644 index 0000000..29ecbbf --- /dev/null +++ b/npm-debug.log @@ -0,0 +1,16521 @@ +0 info it worked if it ends with ok +1 verbose cli [ '/usr/bin/node', '/usr/bin/npm', 'update', '-g' ] +2 info using npm@1.4.28 +3 info using node@v0.10.32 +4 verbose request where is /grunt-cli +5 verbose request registry https://registry.npmjs.org/ +6 verbose request id f1f46668daf15fee +7 verbose url raw /grunt-cli +8 verbose url resolving [ 'https://registry.npmjs.org/', './grunt-cli' ] +9 verbose url resolved https://registry.npmjs.org/grunt-cli +10 verbose request where is https://registry.npmjs.org/grunt-cli +11 info trying registry request attempt 1 at 15:14:25 +12 verbose etag "8WP6SD7VNN0NYX6B5WPNFWVXG" +13 http GET https://registry.npmjs.org/grunt-cli +14 verbose request where is /karma-chrome-launcher +15 verbose request registry https://registry.npmjs.org/ +16 verbose url raw /karma-chrome-launcher +17 verbose url resolving [ 'https://registry.npmjs.org/', './karma-chrome-launcher' ] +18 verbose url resolved https://registry.npmjs.org/karma-chrome-launcher +19 verbose request where is https://registry.npmjs.org/karma-chrome-launcher +20 info trying registry request attempt 1 at 15:14:25 +21 verbose etag "DKVYZMWYUQP2OIB0JS78UN6EU" +22 http GET https://registry.npmjs.org/karma-chrome-launcher +23 verbose request where is /karma-coffee-preprocessor +24 verbose request registry https://registry.npmjs.org/ +25 verbose url raw /karma-coffee-preprocessor +26 verbose url resolving [ 'https://registry.npmjs.org/', './karma-coffee-preprocessor' ] +27 verbose url resolved https://registry.npmjs.org/karma-coffee-preprocessor +28 verbose request where is https://registry.npmjs.org/karma-coffee-preprocessor +29 info trying registry request attempt 1 at 15:14:25 +30 verbose etag "3K8ZGDH8A2RHKJWGGVPCRGR7K" +31 http GET https://registry.npmjs.org/karma-coffee-preprocessor +32 verbose request where is /karma-coverage +33 verbose request registry https://registry.npmjs.org/ +34 verbose url raw /karma-coverage +35 verbose url resolving [ 'https://registry.npmjs.org/', './karma-coverage' ] +36 verbose url resolved https://registry.npmjs.org/karma-coverage +37 verbose request where is https://registry.npmjs.org/karma-coverage +38 info trying registry request attempt 1 at 15:14:25 +39 verbose etag "EE4I9AIQFDWHIUWTRB9HAGKPY" +40 http GET https://registry.npmjs.org/karma-coverage +41 verbose request where is /karma-firefox-launcher +42 verbose request registry https://registry.npmjs.org/ +43 verbose url raw /karma-firefox-launcher +44 verbose url resolving [ 'https://registry.npmjs.org/', './karma-firefox-launcher' ] +45 verbose url resolved https://registry.npmjs.org/karma-firefox-launcher +46 verbose request where is https://registry.npmjs.org/karma-firefox-launcher +47 info trying registry request attempt 1 at 15:14:25 +48 verbose etag "1TACTAZD4J3YQ53JWOPY2BVF2" +49 http GET https://registry.npmjs.org/karma-firefox-launcher +50 verbose request where is /karma-html2js-preprocessor +51 verbose request registry https://registry.npmjs.org/ +52 verbose url raw /karma-html2js-preprocessor +53 verbose url resolving [ 'https://registry.npmjs.org/', +53 verbose url resolving './karma-html2js-preprocessor' ] +54 verbose url resolved https://registry.npmjs.org/karma-html2js-preprocessor +55 verbose request where is https://registry.npmjs.org/karma-html2js-preprocessor +56 info trying registry request attempt 1 at 15:14:25 +57 verbose etag "146M0LE677ZPEZKX747EAD2AD" +58 http GET https://registry.npmjs.org/karma-html2js-preprocessor +59 verbose request where is /karma-phantomjs-launcher +60 verbose request registry https://registry.npmjs.org/ +61 verbose url raw /karma-phantomjs-launcher +62 verbose url resolving [ 'https://registry.npmjs.org/', './karma-phantomjs-launcher' ] +63 verbose url resolved https://registry.npmjs.org/karma-phantomjs-launcher +64 verbose request where is https://registry.npmjs.org/karma-phantomjs-launcher +65 info trying registry request attempt 1 at 15:14:25 +66 verbose etag "CHJ58Z2N4KQ13CFYSBD20IGNY" +67 http GET https://registry.npmjs.org/karma-phantomjs-launcher +68 verbose request where is /karma-qunit +69 verbose request registry https://registry.npmjs.org/ +70 verbose url raw /karma-qunit +71 verbose url resolving [ 'https://registry.npmjs.org/', './karma-qunit' ] +72 verbose url resolved https://registry.npmjs.org/karma-qunit +73 verbose request where is https://registry.npmjs.org/karma-qunit +74 info trying registry request attempt 1 at 15:14:25 +75 verbose etag "CUKZ7JCU88IQJVS923TEHB0KV" +76 http GET https://registry.npmjs.org/karma-qunit +77 verbose request where is /karma-script-launcher +78 verbose request registry https://registry.npmjs.org/ +79 verbose url raw /karma-script-launcher +80 verbose url resolving [ 'https://registry.npmjs.org/', './karma-script-launcher' ] +81 verbose url resolved https://registry.npmjs.org/karma-script-launcher +82 verbose request where is https://registry.npmjs.org/karma-script-launcher +83 info trying registry request attempt 1 at 15:14:25 +84 verbose etag "71JYLUUGO7CGSK385EVMH2JOO" +85 http GET https://registry.npmjs.org/karma-script-launcher +86 verbose request where is /nodeunit +87 verbose request registry https://registry.npmjs.org/ +88 verbose url raw /nodeunit +89 verbose url resolving [ 'https://registry.npmjs.org/', './nodeunit' ] +90 verbose url resolved https://registry.npmjs.org/nodeunit +91 verbose request where is https://registry.npmjs.org/nodeunit +92 info trying registry request attempt 1 at 15:14:25 +93 verbose etag "8LV8KE1DMO7U5P408BBDMYU0N" +94 http GET https://registry.npmjs.org/nodeunit +95 verbose request where is /zombie +96 verbose request registry https://registry.npmjs.org/ +97 verbose url raw /zombie +98 verbose url resolving [ 'https://registry.npmjs.org/', './zombie' ] +99 verbose url resolved https://registry.npmjs.org/zombie +100 verbose request where is https://registry.npmjs.org/zombie +101 info trying registry request attempt 1 at 15:14:25 +102 verbose etag "75Y331GYF50EI8YTNYO69JWWX" +103 http GET https://registry.npmjs.org/zombie +104 verbose request where is /express-generator +105 verbose request registry https://registry.npmjs.org/ +106 verbose url raw /express-generator +107 verbose url resolving [ 'https://registry.npmjs.org/', './express-generator' ] +108 verbose url resolved https://registry.npmjs.org/express-generator +109 verbose request where is https://registry.npmjs.org/express-generator +110 info trying registry request attempt 1 at 15:14:25 +111 verbose etag "AY5JZP0TEVDIJCB6GXG85YSK3" +112 http GET https://registry.npmjs.org/express-generator +113 verbose request where is /jsdoc +114 verbose request registry https://registry.npmjs.org/ +115 verbose url raw /jsdoc +116 verbose url resolving [ 'https://registry.npmjs.org/', './jsdoc' ] +117 verbose url resolved https://registry.npmjs.org/jsdoc +118 verbose request where is https://registry.npmjs.org/jsdoc +119 info trying registry request attempt 1 at 15:14:25 +120 verbose etag "343B9OCEBEXBKB4TDP9OKUNT6" +121 http GET https://registry.npmjs.org/jsdoc +122 verbose request where is /grunt +123 verbose request registry https://registry.npmjs.org/ +124 verbose url raw /grunt +125 verbose url resolving [ 'https://registry.npmjs.org/', './grunt' ] +126 verbose url resolved https://registry.npmjs.org/grunt +127 verbose request where is https://registry.npmjs.org/grunt +128 info trying registry request attempt 1 at 15:14:25 +129 verbose etag "DW3VUCN5FW0WHDR6GV3W694RB" +130 http GET https://registry.npmjs.org/grunt +131 verbose request where is /karma-jasmine +132 verbose request registry https://registry.npmjs.org/ +133 verbose url raw /karma-jasmine +134 verbose url resolving [ 'https://registry.npmjs.org/', './karma-jasmine' ] +135 verbose url resolved https://registry.npmjs.org/karma-jasmine +136 verbose request where is https://registry.npmjs.org/karma-jasmine +137 info trying registry request attempt 1 at 15:14:25 +138 verbose etag "E11CPBXHJAQO6916U8SVUQMJJ" +139 http GET https://registry.npmjs.org/karma-jasmine +140 verbose request where is /karma-requirejs +141 verbose request registry https://registry.npmjs.org/ +142 verbose url raw /karma-requirejs +143 verbose url resolving [ 'https://registry.npmjs.org/', './karma-requirejs' ] +144 verbose url resolved https://registry.npmjs.org/karma-requirejs +145 verbose request where is https://registry.npmjs.org/karma-requirejs +146 info trying registry request attempt 1 at 15:14:25 +147 verbose etag "QONGN1L5FTADOPOB6SRPWEDH" +148 http GET https://registry.npmjs.org/karma-requirejs +149 verbose request where is /myth +150 verbose request registry https://registry.npmjs.org/ +151 verbose url raw /myth +152 verbose url resolving [ 'https://registry.npmjs.org/', './myth' ] +153 verbose url resolved https://registry.npmjs.org/myth +154 verbose request where is https://registry.npmjs.org/myth +155 info trying registry request attempt 1 at 15:14:25 +156 verbose etag "B00TYOF2KO8Y062TLTGZGVOWL" +157 http GET https://registry.npmjs.org/myth +158 verbose request where is /qunitjs +159 verbose request registry https://registry.npmjs.org/ +160 verbose url raw /qunitjs +161 verbose url resolving [ 'https://registry.npmjs.org/', './qunitjs' ] +162 verbose url resolved https://registry.npmjs.org/qunitjs +163 verbose request where is https://registry.npmjs.org/qunitjs +164 info trying registry request attempt 1 at 15:14:25 +165 verbose etag "5NKV209PHM1WRMGSVXL027WRS" +166 http GET https://registry.npmjs.org/qunitjs +167 verbose request where is /requirejs +168 verbose request registry https://registry.npmjs.org/ +169 verbose url raw /requirejs +170 verbose url resolving [ 'https://registry.npmjs.org/', './requirejs' ] +171 verbose url resolved https://registry.npmjs.org/requirejs +172 verbose request where is https://registry.npmjs.org/requirejs +173 info trying registry request attempt 1 at 15:14:25 +174 verbose etag "1HX2IPUVLWVPMGR3YIW4PTULR" +175 http GET https://registry.npmjs.org/requirejs +176 verbose request where is /supervisor +177 verbose request registry https://registry.npmjs.org/ +178 verbose url raw /supervisor +179 verbose url resolving [ 'https://registry.npmjs.org/', './supervisor' ] +180 verbose url resolved https://registry.npmjs.org/supervisor +181 verbose request where is https://registry.npmjs.org/supervisor +182 info trying registry request attempt 1 at 15:14:25 +183 verbose etag "EOU3Y6MLQWBNV4ESLGNNKVHFW" +184 http GET https://registry.npmjs.org/supervisor +185 verbose request where is /vtop +186 verbose request registry https://registry.npmjs.org/ +187 verbose url raw /vtop +188 verbose url resolving [ 'https://registry.npmjs.org/', './vtop' ] +189 verbose url resolved https://registry.npmjs.org/vtop +190 verbose request where is https://registry.npmjs.org/vtop +191 info trying registry request attempt 1 at 15:14:25 +192 verbose etag "43SCN7TV21E15UWWXEHXQBWSY" +193 http GET https://registry.npmjs.org/vtop +194 verbose request where is /express +195 verbose request registry https://registry.npmjs.org/ +196 verbose url raw /express +197 verbose url resolving [ 'https://registry.npmjs.org/', './express' ] +198 verbose url resolved https://registry.npmjs.org/express +199 verbose request where is https://registry.npmjs.org/express +200 info trying registry request attempt 1 at 15:14:25 +201 verbose etag "8ZQS5XTADARLJZEG0YOWAZZGZ" +202 http GET https://registry.npmjs.org/express +203 verbose request where is /karma +204 verbose request registry https://registry.npmjs.org/ +205 verbose url raw /karma +206 verbose url resolving [ 'https://registry.npmjs.org/', './karma' ] +207 verbose url resolved https://registry.npmjs.org/karma +208 verbose request where is https://registry.npmjs.org/karma +209 info trying registry request attempt 1 at 15:14:25 +210 verbose etag "DO9C5FSNO2MK4E0QNPSHNNAIL" +211 http GET https://registry.npmjs.org/karma +212 verbose request where is /npm +213 verbose request registry https://registry.npmjs.org/ +214 verbose url raw /npm +215 verbose url resolving [ 'https://registry.npmjs.org/', './npm' ] +216 verbose url resolved https://registry.npmjs.org/npm +217 verbose request where is https://registry.npmjs.org/npm +218 info trying registry request attempt 1 at 15:14:25 +219 verbose etag "7HVNZAXYY5YMG22X7130TOMFO" +220 http GET https://registry.npmjs.org/npm +221 http 304 https://registry.npmjs.org/karma-coffee-preprocessor +222 silly registry.get cb [ 304, +222 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:25 GMT', +222 silly registry.get server: 'Apache', +222 silly registry.get via: '1.1 varnish', +222 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:25 GMT', +222 silly registry.get 'cache-control': 'max-age=60', +222 silly registry.get etag: '"3K8ZGDH8A2RHKJWGGVPCRGR7K"', +222 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +222 silly registry.get 'x-cache': 'HIT', +222 silly registry.get 'x-cache-hits': '1', +222 silly registry.get 'x-timer': 'S1411067665.867934,VS0,VE0', +222 silly registry.get vary: 'Accept', +222 silly registry.get 'content-length': '0', +222 silly registry.get 'keep-alive': 'timeout=10, max=50', +222 silly registry.get connection: 'Keep-Alive' } ] +223 verbose etag https://registry.npmjs.org/karma-coffee-preprocessor from cache +224 verbose request where is /coffee-script +225 verbose request registry https://registry.npmjs.org/ +226 verbose url raw /coffee-script +227 verbose url resolving [ 'https://registry.npmjs.org/', './coffee-script' ] +228 verbose url resolved https://registry.npmjs.org/coffee-script +229 verbose request where is https://registry.npmjs.org/coffee-script +230 info trying registry request attempt 1 at 15:14:25 +231 verbose etag "2IGQ76IA45TGG63FC3G4GKRH9" +232 http GET https://registry.npmjs.org/coffee-script +233 http 304 https://registry.npmjs.org/karma-html2js-preprocessor +234 silly registry.get cb [ 304, +234 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:25 GMT', +234 silly registry.get server: 'Apache', +234 silly registry.get via: '1.1 varnish', +234 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:25 GMT', +234 silly registry.get 'cache-control': 'max-age=60', +234 silly registry.get etag: '"146M0LE677ZPEZKX747EAD2AD"', +234 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +234 silly registry.get 'x-cache': 'HIT', +234 silly registry.get 'x-cache-hits': '1', +234 silly registry.get 'x-timer': 'S1411067665.895858,VS0,VE0', +234 silly registry.get vary: 'Accept', +234 silly registry.get 'content-length': '0', +234 silly registry.get 'keep-alive': 'timeout=10, max=49', +234 silly registry.get connection: 'Keep-Alive' } ] +235 verbose etag https://registry.npmjs.org/karma-html2js-preprocessor from cache +236 http 304 https://registry.npmjs.org/karma-phantomjs-launcher +237 silly registry.get cb [ 304, +237 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:25 GMT', +237 silly registry.get server: 'Apache', +237 silly registry.get via: '1.1 varnish', +237 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:25 GMT', +237 silly registry.get 'cache-control': 'max-age=60', +237 silly registry.get etag: '"CHJ58Z2N4KQ13CFYSBD20IGNY"', +237 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +237 silly registry.get 'x-cache': 'HIT', +237 silly registry.get 'x-cache-hits': '1', +237 silly registry.get 'x-timer': 'S1411067665.917944,VS0,VE28', +237 silly registry.get vary: 'Accept', +237 silly registry.get 'content-length': '0', +237 silly registry.get 'keep-alive': 'timeout=10, max=48', +237 silly registry.get connection: 'Keep-Alive' } ] +238 verbose etag https://registry.npmjs.org/karma-phantomjs-launcher from cache +239 verbose request where is /phantomjs +240 verbose request registry https://registry.npmjs.org/ +241 verbose url raw /phantomjs +242 verbose url resolving [ 'https://registry.npmjs.org/', './phantomjs' ] +243 verbose url resolved https://registry.npmjs.org/phantomjs +244 verbose request where is https://registry.npmjs.org/phantomjs +245 info trying registry request attempt 1 at 15:14:25 +246 verbose etag "AK2GFXGW7P4U3EPVXNUUSE0JA" +247 http GET https://registry.npmjs.org/phantomjs +248 http 304 https://registry.npmjs.org/karma-qunit +249 silly registry.get cb [ 304, +249 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:25 GMT', +249 silly registry.get server: 'Apache', +249 silly registry.get via: '1.1 varnish', +249 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:25 GMT', +249 silly registry.get 'cache-control': 'max-age=60', +249 silly registry.get etag: '"CUKZ7JCU88IQJVS923TEHB0KV"', +249 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +249 silly registry.get 'x-cache': 'HIT', +249 silly registry.get 'x-cache-hits': '1', +249 silly registry.get 'x-timer': 'S1411067665.968138,VS0,VE0', +249 silly registry.get vary: 'Accept', +249 silly registry.get 'content-length': '0', +249 silly registry.get 'keep-alive': 'timeout=10, max=47', +249 silly registry.get connection: 'Keep-Alive' } ] +250 verbose etag https://registry.npmjs.org/karma-qunit from cache +251 http 304 https://registry.npmjs.org/karma-firefox-launcher +252 silly registry.get cb [ 304, +252 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:25 GMT', +252 silly registry.get server: 'Apache', +252 silly registry.get via: '1.1 varnish', +252 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:25 GMT', +252 silly registry.get 'cache-control': 'max-age=60', +252 silly registry.get etag: '"1TACTAZD4J3YQ53JWOPY2BVF2"', +252 silly registry.get 'x-served-by': 'cache-dfw1834-DFW', +252 silly registry.get 'x-cache': 'HIT', +252 silly registry.get 'x-cache-hits': '1', +252 silly registry.get 'x-timer': 'S1411067665.970909,VS0,VE0', +252 silly registry.get vary: 'Accept', +252 silly registry.get 'content-length': '0', +252 silly registry.get 'keep-alive': 'timeout=10, max=50', +252 silly registry.get connection: 'Keep-Alive' } ] +253 verbose etag https://registry.npmjs.org/karma-firefox-launcher from cache +254 http 304 https://registry.npmjs.org/karma-script-launcher +255 silly registry.get cb [ 304, +255 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:25 GMT', +255 silly registry.get server: 'Apache', +255 silly registry.get via: '1.1 varnish', +255 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:25 GMT', +255 silly registry.get 'cache-control': 'max-age=60', +255 silly registry.get etag: '"71JYLUUGO7CGSK385EVMH2JOO"', +255 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +255 silly registry.get 'x-cache': 'HIT', +255 silly registry.get 'x-cache-hits': '1', +255 silly registry.get 'x-timer': 'S1411067665.989212,VS0,VE0', +255 silly registry.get vary: 'Accept', +255 silly registry.get 'content-length': '0', +255 silly registry.get 'keep-alive': 'timeout=10, max=46', +255 silly registry.get connection: 'Keep-Alive' } ] +256 verbose etag https://registry.npmjs.org/karma-script-launcher from cache +257 http 304 https://registry.npmjs.org/karma-chrome-launcher +258 silly registry.get cb [ 304, +258 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:25 GMT', +258 silly registry.get server: 'Apache', +258 silly registry.get via: '1.1 varnish', +258 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:25 GMT', +258 silly registry.get 'cache-control': 'max-age=60', +258 silly registry.get etag: '"DKVYZMWYUQP2OIB0JS78UN6EU"', +258 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +258 silly registry.get 'x-cache': 'HIT', +258 silly registry.get 'x-cache-hits': '1', +258 silly registry.get 'x-timer': 'S1411067665.978810,VS0,VE0', +258 silly registry.get vary: 'Accept', +258 silly registry.get 'content-length': '0', +258 silly registry.get 'keep-alive': 'timeout=10, max=50', +258 silly registry.get connection: 'Keep-Alive' } ] +259 verbose etag https://registry.npmjs.org/karma-chrome-launcher from cache +260 http 304 https://registry.npmjs.org/zombie +261 silly registry.get cb [ 304, +261 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +261 silly registry.get server: 'Apache', +261 silly registry.get via: '1.1 varnish', +261 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:26 GMT', +261 silly registry.get 'cache-control': 'max-age=60', +261 silly registry.get etag: '"75Y331GYF50EI8YTNYO69JWWX"', +261 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +261 silly registry.get 'x-cache': 'HIT', +261 silly registry.get 'x-cache-hits': '1', +261 silly registry.get 'x-timer': 'S1411067666.015987,VS0,VE0', +261 silly registry.get vary: 'Accept', +261 silly registry.get 'content-length': '0', +261 silly registry.get 'keep-alive': 'timeout=10, max=45', +261 silly registry.get connection: 'Keep-Alive' } ] +262 verbose etag https://registry.npmjs.org/zombie from cache +263 http 304 https://registry.npmjs.org/grunt-cli +264 silly registry.get cb [ 304, +264 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +264 silly registry.get server: 'Apache', +264 silly registry.get via: '1.1 varnish', +264 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:26 GMT', +264 silly registry.get 'cache-control': 'max-age=60', +264 silly registry.get etag: '"8WP6SD7VNN0NYX6B5WPNFWVXG"', +264 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +264 silly registry.get 'x-cache': 'HIT', +264 silly registry.get 'x-cache-hits': '1', +264 silly registry.get 'x-timer': 'S1411067666.027319,VS0,VE0', +264 silly registry.get vary: 'Accept', +264 silly registry.get 'content-length': '0', +264 silly registry.get 'keep-alive': 'timeout=10, max=50', +264 silly registry.get connection: 'Keep-Alive' } ] +265 verbose etag https://registry.npmjs.org/grunt-cli from cache +266 http 304 https://registry.npmjs.org/nodeunit +267 silly registry.get cb [ 304, +267 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +267 silly registry.get server: 'Apache', +267 silly registry.get via: '1.1 varnish', +267 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:26 GMT', +267 silly registry.get 'cache-control': 'max-age=60', +267 silly registry.get etag: '"8LV8KE1DMO7U5P408BBDMYU0N"', +267 silly registry.get 'x-served-by': 'cache-dfw1834-DFW', +267 silly registry.get 'x-cache': 'HIT', +267 silly registry.get 'x-cache-hits': '1', +267 silly registry.get 'x-timer': 'S1411067666.032057,VS0,VE0', +267 silly registry.get vary: 'Accept', +267 silly registry.get 'content-length': '0', +267 silly registry.get 'keep-alive': 'timeout=10, max=49', +267 silly registry.get connection: 'Keep-Alive' } ] +268 verbose etag https://registry.npmjs.org/nodeunit from cache +269 verbose request where is /encoding +270 verbose request registry https://registry.npmjs.org/ +271 verbose url raw /encoding +272 verbose url resolving [ 'https://registry.npmjs.org/', './encoding' ] +273 verbose url resolved https://registry.npmjs.org/encoding +274 verbose request where is https://registry.npmjs.org/encoding +275 info trying registry request attempt 1 at 15:14:26 +276 verbose etag "BO23RLVR90OLLVTLOXYRFW7M2" +277 http GET https://registry.npmjs.org/encoding +278 verbose request where is /eventsource +279 verbose request registry https://registry.npmjs.org/ +280 verbose url raw /eventsource +281 verbose url resolving [ 'https://registry.npmjs.org/', './eventsource' ] +282 verbose url resolved https://registry.npmjs.org/eventsource +283 verbose request where is https://registry.npmjs.org/eventsource +284 info trying registry request attempt 1 at 15:14:26 +285 verbose etag "AUC5YKH7PBCHS548P1Q64MA7T" +286 http GET https://registry.npmjs.org/eventsource +287 verbose request where is /html5 +288 verbose request registry https://registry.npmjs.org/ +289 verbose url raw /html5 +290 verbose url resolving [ 'https://registry.npmjs.org/', './html5' ] +291 verbose url resolved https://registry.npmjs.org/html5 +292 verbose request where is https://registry.npmjs.org/html5 +293 info trying registry request attempt 1 at 15:14:26 +294 verbose etag "1N7CBOGNXAWMGSVPWKJPL56U2" +295 http GET https://registry.npmjs.org/html5 +296 verbose request where is /mime +297 verbose request registry https://registry.npmjs.org/ +298 verbose url raw /mime +299 verbose url resolving [ 'https://registry.npmjs.org/', './mime' ] +300 verbose url resolved https://registry.npmjs.org/mime +301 verbose request where is https://registry.npmjs.org/mime +302 info trying registry request attempt 1 at 15:14:26 +303 verbose etag "3RL1A9NN22779LE2SEPGHPY1D" +304 http GET https://registry.npmjs.org/mime +305 verbose request where is /ms +306 verbose request registry https://registry.npmjs.org/ +307 verbose url raw /ms +308 verbose url resolving [ 'https://registry.npmjs.org/', './ms' ] +309 verbose url resolved https://registry.npmjs.org/ms +310 verbose request where is https://registry.npmjs.org/ms +311 info trying registry request attempt 1 at 15:14:26 +312 verbose etag "3CU3HCGNOE4PX802QLNZWR14Q" +313 http GET https://registry.npmjs.org/ms +314 verbose request where is /q +315 verbose request registry https://registry.npmjs.org/ +316 verbose url raw /q +317 verbose url resolving [ 'https://registry.npmjs.org/', './q' ] +318 verbose url resolved https://registry.npmjs.org/q +319 verbose request where is https://registry.npmjs.org/q +320 info trying registry request attempt 1 at 15:14:26 +321 verbose etag "104OS4379Y6P3299PJUGCA1RK" +322 http GET https://registry.npmjs.org/q +323 verbose request where is /request +324 verbose request registry https://registry.npmjs.org/ +325 verbose url raw /request +326 verbose url resolving [ 'https://registry.npmjs.org/', './request' ] +327 verbose url resolved https://registry.npmjs.org/request +328 verbose request where is https://registry.npmjs.org/request +329 info trying registry request attempt 1 at 15:14:26 +330 verbose etag "B99QGY0F0TJZ3MX6I8GT2OFD3" +331 http GET https://registry.npmjs.org/request +332 verbose request where is /jsdom +333 verbose request registry https://registry.npmjs.org/ +334 verbose url raw /jsdom +335 verbose url resolving [ 'https://registry.npmjs.org/', './jsdom' ] +336 verbose url resolved https://registry.npmjs.org/jsdom +337 verbose request where is https://registry.npmjs.org/jsdom +338 info trying registry request attempt 1 at 15:14:26 +339 verbose etag "EZVAUFBWM1HOE2TTAWE00ADNT" +340 http GET https://registry.npmjs.org/jsdom +341 verbose request where is /ws +342 verbose request registry https://registry.npmjs.org/ +343 verbose url raw /ws +344 verbose url resolving [ 'https://registry.npmjs.org/', './ws' ] +345 verbose url resolved https://registry.npmjs.org/ws +346 verbose request where is https://registry.npmjs.org/ws +347 info trying registry request attempt 1 at 15:14:26 +348 verbose etag "EPO9OJQ4QEXJT3PL7TGX57EEM" +349 http GET https://registry.npmjs.org/ws +350 verbose request where is /tough-cookie +351 verbose request registry https://registry.npmjs.org/ +352 verbose url raw /tough-cookie +353 verbose url resolving [ 'https://registry.npmjs.org/', './tough-cookie' ] +354 verbose url resolved https://registry.npmjs.org/tough-cookie +355 verbose request where is https://registry.npmjs.org/tough-cookie +356 info trying registry request attempt 1 at 15:14:26 +357 verbose etag "1G7S58M86AI65KWATAOJG919F" +358 http GET https://registry.npmjs.org/tough-cookie +359 http 304 https://registry.npmjs.org/jsdoc +360 silly registry.get cb [ 304, +360 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +360 silly registry.get server: 'Apache', +360 silly registry.get via: '1.1 varnish', +360 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:26 GMT', +360 silly registry.get 'cache-control': 'max-age=60', +360 silly registry.get etag: '"343B9OCEBEXBKB4TDP9OKUNT6"', +360 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +360 silly registry.get 'x-cache': 'HIT', +360 silly registry.get 'x-cache-hits': '1', +360 silly registry.get 'x-timer': 'S1411067666.043097,VS0,VE29', +360 silly registry.get vary: 'Accept', +360 silly registry.get 'content-length': '0', +360 silly registry.get 'keep-alive': 'timeout=10, max=44', +360 silly registry.get connection: 'Keep-Alive' } ] +361 verbose etag https://registry.npmjs.org/jsdoc from cache +362 http 304 https://registry.npmjs.org/grunt +363 silly registry.get cb [ 304, +363 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +363 silly registry.get server: 'Apache', +363 silly registry.get via: '1.1 varnish', +363 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:26 GMT', +363 silly registry.get 'cache-control': 'max-age=60', +363 silly registry.get etag: '"DW3VUCN5FW0WHDR6GV3W694RB"', +363 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +363 silly registry.get 'x-cache': 'HIT', +363 silly registry.get 'x-cache-hits': '1', +363 silly registry.get 'x-timer': 'S1411067666.088871,VS0,VE0', +363 silly registry.get vary: 'Accept', +363 silly registry.get 'content-length': '0', +363 silly registry.get 'keep-alive': 'timeout=10, max=49', +363 silly registry.get connection: 'Keep-Alive' } ] +364 verbose etag https://registry.npmjs.org/grunt from cache +365 http 304 https://registry.npmjs.org/karma-jasmine +366 silly registry.get cb [ 304, +366 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +366 silly registry.get server: 'Apache', +366 silly registry.get via: '1.1 varnish', +366 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:26 GMT', +366 silly registry.get 'cache-control': 'max-age=60', +366 silly registry.get etag: '"E11CPBXHJAQO6916U8SVUQMJJ"', +366 silly registry.get 'x-served-by': 'cache-dfw1834-DFW', +366 silly registry.get 'x-cache': 'HIT', +366 silly registry.get 'x-cache-hits': '1', +366 silly registry.get 'x-timer': 'S1411067666.095229,VS0,VE0', +366 silly registry.get vary: 'Accept', +366 silly registry.get 'content-length': '0', +366 silly registry.get 'keep-alive': 'timeout=10, max=48', +366 silly registry.get connection: 'Keep-Alive' } ] +367 verbose etag https://registry.npmjs.org/karma-jasmine from cache +368 http 304 https://registry.npmjs.org/express-generator +369 silly registry.get cb [ 304, +369 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +369 silly registry.get server: 'Apache', +369 silly registry.get via: '1.1 varnish', +369 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:26 GMT', +369 silly registry.get 'cache-control': 'max-age=60', +369 silly registry.get etag: '"AY5JZP0TEVDIJCB6GXG85YSK3"', +369 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +369 silly registry.get 'x-cache': 'HIT', +369 silly registry.get 'x-cache-hits': '1', +369 silly registry.get 'x-timer': 'S1411067666.040378,VS0,VE62', +369 silly registry.get vary: 'Accept', +369 silly registry.get 'content-length': '0', +369 silly registry.get 'keep-alive': 'timeout=10, max=49', +369 silly registry.get connection: 'Keep-Alive' } ] +370 verbose etag https://registry.npmjs.org/express-generator from cache +371 http 304 https://registry.npmjs.org/karma-requirejs +372 silly registry.get cb [ 304, +372 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +372 silly registry.get server: 'Apache', +372 silly registry.get via: '1.1 varnish', +372 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:04:05 GMT', +372 silly registry.get 'cache-control': 'max-age=60', +372 silly registry.get etag: '"QONGN1L5FTADOPOB6SRPWEDH"', +372 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +372 silly registry.get 'x-cache': 'HIT', +372 silly registry.get 'x-cache-hits': '8', +372 silly registry.get 'x-timer': 'S1411067666.139829,VS0,VE0', +372 silly registry.get vary: 'Accept', +372 silly registry.get 'content-length': '0', +372 silly registry.get 'keep-alive': 'timeout=10, max=43', +372 silly registry.get connection: 'Keep-Alive' } ] +373 verbose etag https://registry.npmjs.org/karma-requirejs from cache +374 verbose request where is /nopt +375 verbose request registry https://registry.npmjs.org/ +376 verbose url raw /nopt +377 verbose url resolving [ 'https://registry.npmjs.org/', './nopt' ] +378 verbose url resolved https://registry.npmjs.org/nopt +379 verbose request where is https://registry.npmjs.org/nopt +380 info trying registry request attempt 1 at 15:14:26 +381 verbose etag "6CCBTH44V99TMQVK8E45ICBN7" +382 http GET https://registry.npmjs.org/nopt +383 verbose request where is /findup-sync +384 verbose request registry https://registry.npmjs.org/ +385 verbose url raw /findup-sync +386 verbose url resolving [ 'https://registry.npmjs.org/', './findup-sync' ] +387 verbose url resolved https://registry.npmjs.org/findup-sync +388 verbose request where is https://registry.npmjs.org/findup-sync +389 info trying registry request attempt 1 at 15:14:26 +390 verbose etag "2777FKVK8MSMAY1RAAQT5ZRUS" +391 http GET https://registry.npmjs.org/findup-sync +392 verbose request where is /resolve +393 verbose request registry https://registry.npmjs.org/ +394 verbose url raw /resolve +395 verbose url resolving [ 'https://registry.npmjs.org/', './resolve' ] +396 verbose url resolved https://registry.npmjs.org/resolve +397 verbose request where is https://registry.npmjs.org/resolve +398 info trying registry request attempt 1 at 15:14:26 +399 verbose etag "65Y7RKJY0AZUEMWT75D8Y4ZJD" +400 http GET https://registry.npmjs.org/resolve +401 http 304 https://registry.npmjs.org/requirejs +402 silly registry.get cb [ 304, +402 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +402 silly registry.get server: 'Apache', +402 silly registry.get via: '1.1 varnish', +402 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:26 GMT', +402 silly registry.get 'cache-control': 'max-age=60', +402 silly registry.get etag: '"1HX2IPUVLWVPMGR3YIW4PTULR"', +402 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +402 silly registry.get 'x-cache': 'HIT', +402 silly registry.get 'x-cache-hits': '1', +402 silly registry.get 'x-timer': 'S1411067666.170205,VS0,VE0', +402 silly registry.get vary: 'Accept', +402 silly registry.get 'content-length': '0', +402 silly registry.get 'keep-alive': 'timeout=10, max=48', +402 silly registry.get connection: 'Keep-Alive' } ] +403 verbose etag https://registry.npmjs.org/requirejs from cache +404 verbose request where is /tap +405 verbose request registry https://registry.npmjs.org/ +406 verbose url raw /tap +407 verbose url resolving [ 'https://registry.npmjs.org/', './tap' ] +408 verbose url resolved https://registry.npmjs.org/tap +409 verbose request where is https://registry.npmjs.org/tap +410 info trying registry request attempt 1 at 15:14:26 +411 verbose etag "NN7PYZ6NSJN8YXPBJEV32HPB" +412 http GET https://registry.npmjs.org/tap +413 http 304 https://registry.npmjs.org/karma-coverage +414 silly registry.get cb [ 304, +414 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +414 silly registry.get server: 'Apache', +414 silly registry.get via: '1.1 varnish', +414 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:26 GMT', +414 silly registry.get 'cache-control': 'max-age=60', +414 silly registry.get etag: '"EE4I9AIQFDWHIUWTRB9HAGKPY"', +414 silly registry.get 'x-served-by': 'cache-dfw1826-DFW', +414 silly registry.get 'x-cache': 'HIT', +414 silly registry.get 'x-cache-hits': '1', +414 silly registry.get 'x-timer': 'S1411067666.027085,VS0,VE185', +414 silly registry.get vary: 'Accept', +414 silly registry.get 'content-length': '0', +414 silly registry.get 'keep-alive': 'timeout=10, max=50', +414 silly registry.get connection: 'Keep-Alive' } ] +415 verbose etag https://registry.npmjs.org/karma-coverage from cache +416 verbose request where is /async +417 verbose request registry https://registry.npmjs.org/ +418 verbose url raw /async +419 verbose url resolving [ 'https://registry.npmjs.org/', './async' ] +420 verbose url resolved https://registry.npmjs.org/async +421 verbose request where is https://registry.npmjs.org/async +422 info trying registry request attempt 1 at 15:14:26 +423 verbose etag "2SHA3WREMZ70G6R6GENYYEH3K" +424 http GET https://registry.npmjs.org/async +425 verbose request where is /catharsis +426 verbose request registry https://registry.npmjs.org/ +427 verbose url raw /catharsis +428 verbose url resolving [ 'https://registry.npmjs.org/', './catharsis' ] +429 verbose url resolved https://registry.npmjs.org/catharsis +430 verbose request where is https://registry.npmjs.org/catharsis +431 info trying registry request attempt 1 at 15:14:26 +432 verbose etag "8Z6Z1YVYKC17IM25479Q82VQ9" +433 http GET https://registry.npmjs.org/catharsis +434 verbose request where is /esprima +435 verbose request registry https://registry.npmjs.org/ +436 verbose url raw /esprima +437 verbose url resolving [ 'https://registry.npmjs.org/', './esprima' ] +438 verbose url resolved https://registry.npmjs.org/esprima +439 verbose request where is https://registry.npmjs.org/esprima +440 info trying registry request attempt 1 at 15:14:26 +441 verbose etag "B2YHUZJLDHJLQY5BTFLG0EUWF" +442 http GET https://registry.npmjs.org/esprima +443 verbose request where is /js2xmlparser +444 verbose request registry https://registry.npmjs.org/ +445 verbose url raw /js2xmlparser +446 verbose url resolving [ 'https://registry.npmjs.org/', './js2xmlparser' ] +447 verbose url resolved https://registry.npmjs.org/js2xmlparser +448 verbose request where is https://registry.npmjs.org/js2xmlparser +449 info trying registry request attempt 1 at 15:14:26 +450 verbose etag "2BW06ID2IKUM2FHTO9G3PV7K8" +451 http GET https://registry.npmjs.org/js2xmlparser +452 verbose request where is /marked +453 verbose request registry https://registry.npmjs.org/ +454 verbose url raw /marked +455 verbose url resolving [ 'https://registry.npmjs.org/', './marked' ] +456 verbose url resolved https://registry.npmjs.org/marked +457 verbose request where is https://registry.npmjs.org/marked +458 info trying registry request attempt 1 at 15:14:26 +459 verbose etag "4I97OJXDD8U7A3QYVBSGNCVXV" +460 http GET https://registry.npmjs.org/marked +461 verbose request where is /requizzle +462 verbose request registry https://registry.npmjs.org/ +463 verbose url raw /requizzle +464 verbose url resolving [ 'https://registry.npmjs.org/', './requizzle' ] +465 verbose url resolved https://registry.npmjs.org/requizzle +466 verbose request where is https://registry.npmjs.org/requizzle +467 info trying registry request attempt 1 at 15:14:26 +468 verbose etag "3EPFB0YOBIGVZBNW35809TMRO" +469 http GET https://registry.npmjs.org/requizzle +470 verbose request where is /strip-json-comments +471 verbose request registry https://registry.npmjs.org/ +472 verbose url raw /strip-json-comments +473 verbose url resolving [ 'https://registry.npmjs.org/', './strip-json-comments' ] +474 verbose url resolved https://registry.npmjs.org/strip-json-comments +475 verbose request where is https://registry.npmjs.org/strip-json-comments +476 info trying registry request attempt 1 at 15:14:26 +477 verbose etag "3GM69ADPH31NYUQEBY0XTMOO8" +478 http GET https://registry.npmjs.org/strip-json-comments +479 verbose request where is /taffydb +480 verbose request registry https://registry.npmjs.org/ +481 verbose url raw /taffydb +482 verbose url resolving [ 'https://registry.npmjs.org/', './taffydb' ] +483 verbose url resolved https://registry.npmjs.org/taffydb +484 verbose request where is https://registry.npmjs.org/taffydb +485 info trying registry request attempt 1 at 15:14:26 +486 verbose etag "3F6XX1ZS1FG8UF8ZAZYC1W52" +487 http GET https://registry.npmjs.org/taffydb +488 verbose request where is /underscore +489 verbose request registry https://registry.npmjs.org/ +490 verbose url raw /underscore +491 verbose url resolving [ 'https://registry.npmjs.org/', './underscore' ] +492 verbose url resolved https://registry.npmjs.org/underscore +493 verbose request where is https://registry.npmjs.org/underscore +494 info trying registry request attempt 1 at 15:14:26 +495 verbose etag "5OGA5GQ7HZATEPFVT518NY84U" +496 http GET https://registry.npmjs.org/underscore +497 verbose request where is /wrench +498 verbose request registry https://registry.npmjs.org/ +499 verbose url raw /wrench +500 verbose url resolving [ 'https://registry.npmjs.org/', './wrench' ] +501 verbose url resolved https://registry.npmjs.org/wrench +502 verbose request where is https://registry.npmjs.org/wrench +503 info trying registry request attempt 1 at 15:14:26 +504 verbose etag "EENWN97PIHO11KNBYBXNXYPKS" +505 http GET https://registry.npmjs.org/wrench +506 verbose request where is /commander +507 verbose request registry https://registry.npmjs.org/ +508 verbose url raw /commander +509 verbose url resolving [ 'https://registry.npmjs.org/', './commander' ] +510 verbose url resolved https://registry.npmjs.org/commander +511 verbose request where is https://registry.npmjs.org/commander +512 info trying registry request attempt 1 at 15:14:26 +513 verbose etag "64YG0KD6CNHI7FUB33O0JW3G2" +514 http GET https://registry.npmjs.org/commander +515 verbose request where is /mkdirp +516 verbose request registry https://registry.npmjs.org/ +517 verbose url raw /mkdirp +518 verbose url resolving [ 'https://registry.npmjs.org/', './mkdirp' ] +519 verbose url resolved https://registry.npmjs.org/mkdirp +520 verbose request where is https://registry.npmjs.org/mkdirp +521 info trying registry request attempt 1 at 15:14:26 +522 verbose etag "EOPTJ0J36LYXZXUCFC4K7PMWN" +523 http GET https://registry.npmjs.org/mkdirp +524 verbose request where is /async +525 verbose request registry https://registry.npmjs.org/ +526 verbose url raw /async +527 verbose url resolving [ 'https://registry.npmjs.org/', './async' ] +528 verbose url resolved https://registry.npmjs.org/async +529 verbose request where is https://registry.npmjs.org/async +530 info trying registry request attempt 1 at 15:14:26 +531 verbose etag "2SHA3WREMZ70G6R6GENYYEH3K" +532 http GET https://registry.npmjs.org/async +533 verbose request where is /colors +534 verbose request registry https://registry.npmjs.org/ +535 verbose url raw /colors +536 verbose url resolving [ 'https://registry.npmjs.org/', './colors' ] +537 verbose url resolved https://registry.npmjs.org/colors +538 verbose request where is https://registry.npmjs.org/colors +539 info trying registry request attempt 1 at 15:14:26 +540 verbose etag "2ZHMVF9GYTMTHHRFKFO52VJA4" +541 http GET https://registry.npmjs.org/colors +542 verbose request where is /coffee-script +543 verbose request registry https://registry.npmjs.org/ +544 verbose url raw /coffee-script +545 verbose url resolving [ 'https://registry.npmjs.org/', './coffee-script' ] +546 verbose url resolved https://registry.npmjs.org/coffee-script +547 verbose request where is https://registry.npmjs.org/coffee-script +548 info trying registry request attempt 1 at 15:14:26 +549 verbose etag "2IGQ76IA45TGG63FC3G4GKRH9" +550 http GET https://registry.npmjs.org/coffee-script +551 verbose request where is /dateformat +552 verbose request registry https://registry.npmjs.org/ +553 verbose url raw /dateformat +554 verbose url resolving [ 'https://registry.npmjs.org/', './dateformat' ] +555 verbose url resolved https://registry.npmjs.org/dateformat +556 verbose request where is https://registry.npmjs.org/dateformat +557 info trying registry request attempt 1 at 15:14:26 +558 verbose etag "4D6Y46B2EGQ8PN6W3CYO08WU5" +559 http GET https://registry.npmjs.org/dateformat +560 verbose request where is /eventemitter2 +561 verbose request registry https://registry.npmjs.org/ +562 verbose url raw /eventemitter2 +563 verbose url resolving [ 'https://registry.npmjs.org/', './eventemitter2' ] +564 verbose url resolved https://registry.npmjs.org/eventemitter2 +565 verbose request where is https://registry.npmjs.org/eventemitter2 +566 info trying registry request attempt 1 at 15:14:26 +567 verbose etag "9NNE2QWKGE8H8Q4T5FXOY4L3P" +568 http GET https://registry.npmjs.org/eventemitter2 +569 verbose request where is /findup-sync +570 verbose request registry https://registry.npmjs.org/ +571 verbose url raw /findup-sync +572 verbose url resolving [ 'https://registry.npmjs.org/', './findup-sync' ] +573 verbose url resolved https://registry.npmjs.org/findup-sync +574 verbose request where is https://registry.npmjs.org/findup-sync +575 info trying registry request attempt 1 at 15:14:26 +576 verbose etag "2777FKVK8MSMAY1RAAQT5ZRUS" +577 http GET https://registry.npmjs.org/findup-sync +578 verbose request where is /hooker +579 verbose request registry https://registry.npmjs.org/ +580 verbose url raw /hooker +581 verbose url resolving [ 'https://registry.npmjs.org/', './hooker' ] +582 verbose url resolved https://registry.npmjs.org/hooker +583 verbose request where is https://registry.npmjs.org/hooker +584 info trying registry request attempt 1 at 15:14:26 +585 verbose etag "6NRZENGO5R2F7KFMMF8H9R0UC" +586 http GET https://registry.npmjs.org/hooker +587 verbose request where is /glob +588 verbose request registry https://registry.npmjs.org/ +589 verbose url raw /glob +590 verbose url resolving [ 'https://registry.npmjs.org/', './glob' ] +591 verbose url resolved https://registry.npmjs.org/glob +592 verbose request where is https://registry.npmjs.org/glob +593 info trying registry request attempt 1 at 15:14:26 +594 verbose etag "9GMKCNKBK5IQ307969W8CTPJB" +595 http GET https://registry.npmjs.org/glob +596 verbose request where is /iconv-lite +597 verbose request registry https://registry.npmjs.org/ +598 verbose url raw /iconv-lite +599 verbose url resolving [ 'https://registry.npmjs.org/', './iconv-lite' ] +600 verbose url resolved https://registry.npmjs.org/iconv-lite +601 verbose request where is https://registry.npmjs.org/iconv-lite +602 info trying registry request attempt 1 at 15:14:26 +603 verbose etag "71FTU0L5QCW72MPRO4XK63O38" +604 http GET https://registry.npmjs.org/iconv-lite +605 verbose request where is /minimatch +606 verbose request registry https://registry.npmjs.org/ +607 verbose url raw /minimatch +608 verbose url resolving [ 'https://registry.npmjs.org/', './minimatch' ] +609 verbose url resolved https://registry.npmjs.org/minimatch +610 verbose request where is https://registry.npmjs.org/minimatch +611 info trying registry request attempt 1 at 15:14:26 +612 verbose etag "667Q92RS6N1601AM7ZZ1NERE8" +613 http GET https://registry.npmjs.org/minimatch +614 verbose request where is /nopt +615 verbose request registry https://registry.npmjs.org/ +616 verbose url raw /nopt +617 verbose url resolving [ 'https://registry.npmjs.org/', './nopt' ] +618 verbose url resolved https://registry.npmjs.org/nopt +619 verbose request where is https://registry.npmjs.org/nopt +620 info trying registry request attempt 1 at 15:14:26 +621 verbose etag "6CCBTH44V99TMQVK8E45ICBN7" +622 http GET https://registry.npmjs.org/nopt +623 verbose request where is /rimraf +624 verbose request registry https://registry.npmjs.org/ +625 verbose url raw /rimraf +626 verbose url resolving [ 'https://registry.npmjs.org/', './rimraf' ] +627 verbose url resolved https://registry.npmjs.org/rimraf +628 verbose request where is https://registry.npmjs.org/rimraf +629 info trying registry request attempt 1 at 15:14:26 +630 verbose etag "31YUZD1DFCDSQ0QSBXMA8KMKQ" +631 http GET https://registry.npmjs.org/rimraf +632 verbose request where is /lodash +633 verbose request registry https://registry.npmjs.org/ +634 verbose url raw /lodash +635 verbose url resolving [ 'https://registry.npmjs.org/', './lodash' ] +636 verbose url resolved https://registry.npmjs.org/lodash +637 verbose request where is https://registry.npmjs.org/lodash +638 info trying registry request attempt 1 at 15:14:26 +639 verbose etag "D4I8Y7O3OF15X88NHWU47Q2H" +640 http GET https://registry.npmjs.org/lodash +641 verbose request where is /which +642 verbose request registry https://registry.npmjs.org/ +643 verbose url raw /which +644 verbose url resolving [ 'https://registry.npmjs.org/', './which' ] +645 verbose url resolved https://registry.npmjs.org/which +646 verbose request where is https://registry.npmjs.org/which +647 info trying registry request attempt 1 at 15:14:26 +648 verbose etag "V2MIU40L4XLGREBQDUE5E170" +649 http GET https://registry.npmjs.org/which +650 verbose request where is /underscore.string +651 verbose request registry https://registry.npmjs.org/ +652 verbose url raw /underscore.string +653 verbose url resolving [ 'https://registry.npmjs.org/', './underscore.string' ] +654 verbose url resolved https://registry.npmjs.org/underscore.string +655 verbose request where is https://registry.npmjs.org/underscore.string +656 info trying registry request attempt 1 at 15:14:26 +657 verbose etag "EVFRL68B0019ADNNX93XOZLXX" +658 http GET https://registry.npmjs.org/underscore.string +659 verbose request where is /js-yaml +660 verbose request registry https://registry.npmjs.org/ +661 verbose url raw /js-yaml +662 verbose url resolving [ 'https://registry.npmjs.org/', './js-yaml' ] +663 verbose url resolved https://registry.npmjs.org/js-yaml +664 verbose request where is https://registry.npmjs.org/js-yaml +665 info trying registry request attempt 1 at 15:14:26 +666 verbose etag "A091AY9YCCHWFD29RODQSZLV6" +667 http GET https://registry.npmjs.org/js-yaml +668 verbose request where is /exit +669 verbose request registry https://registry.npmjs.org/ +670 verbose url raw /exit +671 verbose url resolving [ 'https://registry.npmjs.org/', './exit' ] +672 verbose url resolved https://registry.npmjs.org/exit +673 verbose request where is https://registry.npmjs.org/exit +674 info trying registry request attempt 1 at 15:14:26 +675 verbose etag "3FP0DV35EBACX6J5JMM87J57V" +676 http GET https://registry.npmjs.org/exit +677 verbose request where is /getobject +678 verbose request registry https://registry.npmjs.org/ +679 verbose url raw /getobject +680 verbose url resolving [ 'https://registry.npmjs.org/', './getobject' ] +681 verbose url resolved https://registry.npmjs.org/getobject +682 verbose request where is https://registry.npmjs.org/getobject +683 info trying registry request attempt 1 at 15:14:26 +684 verbose etag "6MUSARQXHFPUKTB7ZUEIX1YXH" +685 http GET https://registry.npmjs.org/getobject +686 verbose request where is /grunt-legacy-util +687 verbose request registry https://registry.npmjs.org/ +688 verbose url raw /grunt-legacy-util +689 verbose url resolving [ 'https://registry.npmjs.org/', './grunt-legacy-util' ] +690 verbose url resolved https://registry.npmjs.org/grunt-legacy-util +691 verbose request where is https://registry.npmjs.org/grunt-legacy-util +692 info trying registry request attempt 1 at 15:14:26 +693 verbose etag "BY99KBK78MQ6K31QKDY8BK8HX" +694 http GET https://registry.npmjs.org/grunt-legacy-util +695 verbose request where is /grunt-legacy-log +696 verbose request registry https://registry.npmjs.org/ +697 verbose url raw /grunt-legacy-log +698 verbose url resolving [ 'https://registry.npmjs.org/', './grunt-legacy-log' ] +699 verbose url resolved https://registry.npmjs.org/grunt-legacy-log +700 verbose request where is https://registry.npmjs.org/grunt-legacy-log +701 info trying registry request attempt 1 at 15:14:26 +702 verbose etag "47MXERUQDY4DRT31NZCWY43IP" +703 http GET https://registry.npmjs.org/grunt-legacy-log +704 http 304 https://registry.npmjs.org/express +705 silly registry.get cb [ 304, +705 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +705 silly registry.get server: 'Apache', +705 silly registry.get via: '1.1 varnish', +705 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:26 GMT', +705 silly registry.get 'cache-control': 'max-age=60', +705 silly registry.get etag: '"8ZQS5XTADARLJZEG0YOWAZZGZ"', +705 silly registry.get 'x-served-by': 'cache-dfw1826-DFW', +705 silly registry.get 'x-cache': 'HIT', +705 silly registry.get 'x-cache-hits': '1', +705 silly registry.get 'x-timer': 'S1411067666.281265,VS0,VE1', +705 silly registry.get vary: 'Accept', +705 silly registry.get 'content-length': '0', +705 silly registry.get 'keep-alive': 'timeout=10, max=49', +705 silly registry.get connection: 'Keep-Alive' } ] +706 verbose etag https://registry.npmjs.org/express from cache +707 http 304 https://registry.npmjs.org/myth +708 silly registry.get cb [ 304, +708 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +708 silly registry.get server: 'Apache', +708 silly registry.get via: '1.1 varnish', +708 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:26 GMT', +708 silly registry.get 'cache-control': 'max-age=60', +708 silly registry.get etag: '"B00TYOF2KO8Y062TLTGZGVOWL"', +708 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +708 silly registry.get 'x-cache': 'MISS', +708 silly registry.get 'x-cache-hits': '0', +708 silly registry.get 'x-timer': 'S1411067666.162310,VS0,VE121', +708 silly registry.get vary: 'Accept', +708 silly registry.get 'content-length': '0', +708 silly registry.get 'keep-alive': 'timeout=10, max=48', +708 silly registry.get connection: 'Keep-Alive' } ] +709 verbose etag https://registry.npmjs.org/myth from cache +710 http 304 https://registry.npmjs.org/karma +711 silly registry.get cb [ 304, +711 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +711 silly registry.get server: 'Apache', +711 silly registry.get via: '1.1 varnish', +711 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:26 GMT', +711 silly registry.get 'cache-control': 'max-age=60', +711 silly registry.get etag: '"DO9C5FSNO2MK4E0QNPSHNNAIL"', +711 silly registry.get 'x-served-by': 'cache-dfw1826-DFW', +711 silly registry.get 'x-cache': 'HIT', +711 silly registry.get 'x-cache-hits': '1', +711 silly registry.get 'x-timer': 'S1411067666.344030,VS0,VE1', +711 silly registry.get vary: 'Accept', +711 silly registry.get 'content-length': '0', +711 silly registry.get 'keep-alive': 'timeout=10, max=48', +711 silly registry.get connection: 'Keep-Alive' } ] +712 verbose etag https://registry.npmjs.org/karma from cache +713 http 304 https://registry.npmjs.org/npm +714 silly registry.get cb [ 304, +714 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +714 silly registry.get server: 'Apache', +714 silly registry.get via: '1.1 varnish', +714 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 18:53:55 GMT', +714 silly registry.get 'cache-control': 'max-age=60', +714 silly registry.get etag: '"7HVNZAXYY5YMG22X7130TOMFO"', +714 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +714 silly registry.get 'x-cache': 'HIT', +714 silly registry.get 'x-cache-hits': '33', +714 silly registry.get 'x-timer': 'S1411067666.349344,VS0,VE0', +714 silly registry.get vary: 'Accept', +714 silly registry.get 'content-length': '0', +714 silly registry.get 'keep-alive': 'timeout=10, max=47', +714 silly registry.get connection: 'Keep-Alive' } ] +715 verbose etag https://registry.npmjs.org/npm from cache +716 verbose request where is /ibrik +717 verbose request registry https://registry.npmjs.org/ +718 verbose url raw /ibrik +719 verbose url resolving [ 'https://registry.npmjs.org/', './ibrik' ] +720 verbose url resolved https://registry.npmjs.org/ibrik +721 verbose request where is https://registry.npmjs.org/ibrik +722 info trying registry request attempt 1 at 15:14:26 +723 verbose etag "95ZG9BVHTK8SRNRBBUM6MRJR4" +724 http GET https://registry.npmjs.org/ibrik +725 verbose request where is /dateformat +726 verbose request registry https://registry.npmjs.org/ +727 verbose url raw /dateformat +728 verbose url resolving [ 'https://registry.npmjs.org/', './dateformat' ] +729 verbose url resolved https://registry.npmjs.org/dateformat +730 verbose request where is https://registry.npmjs.org/dateformat +731 info trying registry request attempt 1 at 15:14:26 +732 verbose etag "4D6Y46B2EGQ8PN6W3CYO08WU5" +733 http GET https://registry.npmjs.org/dateformat +734 verbose request where is /minimatch +735 verbose request registry https://registry.npmjs.org/ +736 verbose url raw /minimatch +737 verbose url resolving [ 'https://registry.npmjs.org/', './minimatch' ] +738 verbose url resolved https://registry.npmjs.org/minimatch +739 verbose request where is https://registry.npmjs.org/minimatch +740 info trying registry request attempt 1 at 15:14:26 +741 verbose etag "667Q92RS6N1601AM7ZZ1NERE8" +742 http GET https://registry.npmjs.org/minimatch +743 verbose request where is /istanbul +744 verbose request registry https://registry.npmjs.org/ +745 verbose url raw /istanbul +746 verbose url resolving [ 'https://registry.npmjs.org/', './istanbul' ] +747 verbose url resolved https://registry.npmjs.org/istanbul +748 verbose request where is https://registry.npmjs.org/istanbul +749 info trying registry request attempt 1 at 15:14:26 +750 verbose etag "9OVVJCI2CZ5R7EKFT7NRBO5HC" +751 http GET https://registry.npmjs.org/istanbul +752 http 304 https://registry.npmjs.org/coffee-script +753 silly registry.get cb [ 304, +753 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +753 silly registry.get server: 'Apache', +753 silly registry.get via: '1.1 varnish', +753 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:26 GMT', +753 silly registry.get 'cache-control': 'max-age=60', +753 silly registry.get etag: '"2IGQ76IA45TGG63FC3G4GKRH9"', +753 silly registry.get 'x-served-by': 'cache-dfw1826-DFW', +753 silly registry.get 'x-cache': 'HIT', +753 silly registry.get 'x-cache-hits': '1', +753 silly registry.get 'x-timer': 'S1411067666.411247,VS0,VE0', +753 silly registry.get vary: 'Accept', +753 silly registry.get 'content-length': '0', +753 silly registry.get 'keep-alive': 'timeout=10, max=47', +753 silly registry.get connection: 'Keep-Alive' } ] +754 verbose etag https://registry.npmjs.org/coffee-script from cache +755 http 304 https://registry.npmjs.org/vtop +756 silly registry.get cb [ 304, +756 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +756 silly registry.get server: 'Apache', +756 silly registry.get via: '1.1 varnish', +756 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:26 GMT', +756 silly registry.get 'cache-control': 'max-age=60', +756 silly registry.get etag: '"43SCN7TV21E15UWWXEHXQBWSY"', +756 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +756 silly registry.get 'x-cache': 'MISS', +756 silly registry.get 'x-cache-hits': '0', +756 silly registry.get 'x-timer': 'S1411067666.234976,VS0,VE185', +756 silly registry.get vary: 'Accept', +756 silly registry.get 'content-length': '0', +756 silly registry.get 'keep-alive': 'timeout=10, max=47', +756 silly registry.get connection: 'Keep-Alive' } ] +757 verbose etag https://registry.npmjs.org/vtop from cache +758 http 304 https://registry.npmjs.org/supervisor +759 silly registry.get cb [ 304, +759 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +759 silly registry.get server: 'Apache', +759 silly registry.get via: '1.1 varnish', +759 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:26 GMT', +759 silly registry.get 'cache-control': 'max-age=60', +759 silly registry.get etag: '"EOU3Y6MLQWBNV4ESLGNNKVHFW"', +759 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +759 silly registry.get 'x-cache': 'HIT', +759 silly registry.get 'x-cache-hits': '1', +759 silly registry.get 'x-timer': 'S1411067666.165731,VS0,VE272', +759 silly registry.get vary: 'Accept', +759 silly registry.get 'content-length': '0', +759 silly registry.get 'keep-alive': 'timeout=10, max=42', +759 silly registry.get connection: 'Keep-Alive' } ] +760 verbose etag https://registry.npmjs.org/supervisor from cache +761 http 304 https://registry.npmjs.org/phantomjs +762 silly registry.get cb [ 304, +762 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +762 silly registry.get server: 'Apache', +762 silly registry.get via: '1.1 varnish', +762 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:13:38 GMT', +762 silly registry.get 'cache-control': 'max-age=60', +762 silly registry.get etag: '"AK2GFXGW7P4U3EPVXNUUSE0JA"', +762 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +762 silly registry.get 'x-cache': 'HIT', +762 silly registry.get 'x-cache-hits': '2', +762 silly registry.get 'x-timer': 'S1411067666.423241,VS0,VE0', +762 silly registry.get vary: 'Accept', +762 silly registry.get 'content-length': '0', +762 silly registry.get 'keep-alive': 'timeout=10, max=46', +762 silly registry.get connection: 'Keep-Alive' } ] +763 verbose etag https://registry.npmjs.org/phantomjs from cache +764 http 304 https://registry.npmjs.org/qunitjs +765 silly registry.get cb [ 304, +765 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +765 silly registry.get server: 'Apache', +765 silly registry.get via: '1.1 varnish', +765 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:26 GMT', +765 silly registry.get 'cache-control': 'max-age=60', +765 silly registry.get etag: '"5NKV209PHM1WRMGSVXL027WRS"', +765 silly registry.get 'x-served-by': 'cache-dfw1834-DFW', +765 silly registry.get 'x-cache': 'MISS', +765 silly registry.get 'x-cache-hits': '0', +765 silly registry.get 'x-timer': 'S1411067666.161257,VS0,VE265', +765 silly registry.get vary: 'Accept', +765 silly registry.get 'content-length': '0', +765 silly registry.get 'keep-alive': 'timeout=10, max=47', +765 silly registry.get connection: 'Keep-Alive' } ] +766 verbose etag https://registry.npmjs.org/qunitjs from cache +767 verbose request where is /autoprefixer-core +768 verbose request registry https://registry.npmjs.org/ +769 verbose url raw /autoprefixer-core +770 verbose url resolving [ 'https://registry.npmjs.org/', './autoprefixer-core' ] +771 verbose url resolved https://registry.npmjs.org/autoprefixer-core +772 verbose request where is https://registry.npmjs.org/autoprefixer-core +773 info trying registry request attempt 1 at 15:14:26 +774 verbose etag "8ZPT3HTVDOHSYZMA6F1JQ7HAB" +775 http GET https://registry.npmjs.org/autoprefixer-core +776 verbose request where is /clone-component +777 verbose request registry https://registry.npmjs.org/ +778 verbose url raw /clone-component +779 verbose url resolving [ 'https://registry.npmjs.org/', './clone-component' ] +780 verbose url resolved https://registry.npmjs.org/clone-component +781 verbose request where is https://registry.npmjs.org/clone-component +782 info trying registry request attempt 1 at 15:14:26 +783 verbose etag "9FXZWVDHKKRFDZ8HFGFAB0V46" +784 http GET https://registry.npmjs.org/clone-component +785 verbose request where is /colors +786 verbose request registry https://registry.npmjs.org/ +787 verbose url raw /colors +788 verbose url resolving [ 'https://registry.npmjs.org/', './colors' ] +789 verbose url resolved https://registry.npmjs.org/colors +790 verbose request where is https://registry.npmjs.org/colors +791 info trying registry request attempt 1 at 15:14:26 +792 verbose etag "2ZHMVF9GYTMTHHRFKFO52VJA4" +793 http GET https://registry.npmjs.org/colors +794 verbose request where is /commander +795 verbose request registry https://registry.npmjs.org/ +796 verbose url raw /commander +797 verbose url resolving [ 'https://registry.npmjs.org/', './commander' ] +798 verbose url resolved https://registry.npmjs.org/commander +799 verbose request where is https://registry.npmjs.org/commander +800 info trying registry request attempt 1 at 15:14:26 +801 verbose etag "64YG0KD6CNHI7FUB33O0JW3G2" +802 http GET https://registry.npmjs.org/commander +803 verbose request where is /is-browser +804 verbose request registry https://registry.npmjs.org/ +805 verbose url raw /is-browser +806 verbose url resolving [ 'https://registry.npmjs.org/', './is-browser' ] +807 verbose url resolved https://registry.npmjs.org/is-browser +808 verbose request where is https://registry.npmjs.org/is-browser +809 info trying registry request attempt 1 at 15:14:26 +810 verbose etag "BDV45H87BRHMOY3WR7420V9AO" +811 http GET https://registry.npmjs.org/is-browser +812 verbose request where is /node-watch +813 verbose request registry https://registry.npmjs.org/ +814 verbose url raw /node-watch +815 verbose url resolving [ 'https://registry.npmjs.org/', './node-watch' ] +816 verbose url resolved https://registry.npmjs.org/node-watch +817 verbose request where is https://registry.npmjs.org/node-watch +818 info trying registry request attempt 1 at 15:14:26 +819 verbose etag "8403TW7NE0BF4GAXS9O3O908G" +820 http GET https://registry.npmjs.org/node-watch +821 verbose request where is /pad-component +822 verbose request registry https://registry.npmjs.org/ +823 verbose url raw /pad-component +824 verbose url resolving [ 'https://registry.npmjs.org/', './pad-component' ] +825 verbose url resolved https://registry.npmjs.org/pad-component +826 verbose request where is https://registry.npmjs.org/pad-component +827 info trying registry request attempt 1 at 15:14:26 +828 verbose etag "AT9M0WJLJ95HLOZ5F66GW3X71" +829 http GET https://registry.npmjs.org/pad-component +830 verbose request where is /read-file-stdin +831 verbose request registry https://registry.npmjs.org/ +832 verbose url raw /read-file-stdin +833 verbose url resolving [ 'https://registry.npmjs.org/', './read-file-stdin' ] +834 verbose url resolved https://registry.npmjs.org/read-file-stdin +835 verbose request where is https://registry.npmjs.org/read-file-stdin +836 info trying registry request attempt 1 at 15:14:26 +837 verbose etag "1OZ9HF2FR2MOGDGTQZNVQW9MX" +838 http GET https://registry.npmjs.org/read-file-stdin +839 verbose request where is /rework +840 verbose request registry https://registry.npmjs.org/ +841 verbose url raw /rework +842 verbose url resolving [ 'https://registry.npmjs.org/', './rework' ] +843 verbose url resolved https://registry.npmjs.org/rework +844 verbose request where is https://registry.npmjs.org/rework +845 info trying registry request attempt 1 at 15:14:26 +846 verbose etag "3JIX4587FLZOTAAGC2LMTHTHL" +847 http GET https://registry.npmjs.org/rework +848 verbose request where is /rework-calc +849 verbose request registry https://registry.npmjs.org/ +850 verbose url raw /rework-calc +851 verbose url resolving [ 'https://registry.npmjs.org/', './rework-calc' ] +852 verbose url resolved https://registry.npmjs.org/rework-calc +853 verbose request where is https://registry.npmjs.org/rework-calc +854 info trying registry request attempt 1 at 15:14:26 +855 verbose etag "7ZG2BQ7IAYTJAP7NM127K8E4" +856 http GET https://registry.npmjs.org/rework-calc +857 verbose request where is /rework-color-function +858 verbose request registry https://registry.npmjs.org/ +859 verbose url raw /rework-color-function +860 verbose url resolving [ 'https://registry.npmjs.org/', './rework-color-function' ] +861 verbose url resolved https://registry.npmjs.org/rework-color-function +862 verbose request where is https://registry.npmjs.org/rework-color-function +863 info trying registry request attempt 1 at 15:14:26 +864 verbose etag "23Z9QZ2FFXLRFCGSMAJBLS8MY" +865 http GET https://registry.npmjs.org/rework-color-function +866 verbose request where is /rework-custom-media +867 verbose request registry https://registry.npmjs.org/ +868 verbose url raw /rework-custom-media +869 verbose url resolving [ 'https://registry.npmjs.org/', './rework-custom-media' ] +870 verbose url resolved https://registry.npmjs.org/rework-custom-media +871 verbose request where is https://registry.npmjs.org/rework-custom-media +872 info trying registry request attempt 1 at 15:14:26 +873 verbose etag "TKFKMF2C8DZJGWIR06U7M3GT" +874 http GET https://registry.npmjs.org/rework-custom-media +875 verbose request where is /rework-font-variant +876 verbose request registry https://registry.npmjs.org/ +877 verbose url raw /rework-font-variant +878 verbose url resolving [ 'https://registry.npmjs.org/', './rework-font-variant' ] +879 verbose url resolved https://registry.npmjs.org/rework-font-variant +880 verbose request where is https://registry.npmjs.org/rework-font-variant +881 info trying registry request attempt 1 at 15:14:26 +882 verbose etag "V7EKOP4KEZA5NVJV1Z7CORH6" +883 http GET https://registry.npmjs.org/rework-font-variant +884 verbose request where is /rework-hex-alpha +885 verbose request registry https://registry.npmjs.org/ +886 verbose url raw /rework-hex-alpha +887 verbose url resolving [ 'https://registry.npmjs.org/', './rework-hex-alpha' ] +888 verbose url resolved https://registry.npmjs.org/rework-hex-alpha +889 verbose request where is https://registry.npmjs.org/rework-hex-alpha +890 info trying registry request attempt 1 at 15:14:26 +891 verbose etag "F5APSW07G01TM6YTBMYXZIO7J" +892 http GET https://registry.npmjs.org/rework-hex-alpha +893 verbose request where is /rework-import +894 verbose request registry https://registry.npmjs.org/ +895 verbose url raw /rework-import +896 verbose url resolving [ 'https://registry.npmjs.org/', './rework-import' ] +897 verbose url resolved https://registry.npmjs.org/rework-import +898 verbose request where is https://registry.npmjs.org/rework-import +899 info trying registry request attempt 1 at 15:14:26 +900 verbose etag "4JMA3XGBW3EXQ3M5UD1OSIOAE" +901 http GET https://registry.npmjs.org/rework-import +902 verbose request where is /rework-rebeccapurple +903 verbose request registry https://registry.npmjs.org/ +904 verbose url raw /rework-rebeccapurple +905 verbose url resolving [ 'https://registry.npmjs.org/', './rework-rebeccapurple' ] +906 verbose url resolved https://registry.npmjs.org/rework-rebeccapurple +907 verbose request where is https://registry.npmjs.org/rework-rebeccapurple +908 info trying registry request attempt 1 at 15:14:26 +909 verbose etag "ERLZS9DRG3W13WMRCUXYFFR1P" +910 http GET https://registry.npmjs.org/rework-rebeccapurple +911 verbose request where is /rework-vars +912 verbose request registry https://registry.npmjs.org/ +913 verbose url raw /rework-vars +914 verbose url resolving [ 'https://registry.npmjs.org/', './rework-vars' ] +915 verbose url resolved https://registry.npmjs.org/rework-vars +916 verbose request where is https://registry.npmjs.org/rework-vars +917 info trying registry request attempt 1 at 15:14:26 +918 verbose etag "A94R2YLPGB5T1NFEEPWDX6ITT" +919 http GET https://registry.npmjs.org/rework-vars +920 verbose request where is /to-slug-case +921 verbose request registry https://registry.npmjs.org/ +922 verbose url raw /to-slug-case +923 verbose url resolving [ 'https://registry.npmjs.org/', './to-slug-case' ] +924 verbose url resolved https://registry.npmjs.org/to-slug-case +925 verbose request where is https://registry.npmjs.org/to-slug-case +926 info trying registry request attempt 1 at 15:14:26 +927 verbose etag "9VIU39RJESC756G6IV9QEGXY1" +928 http GET https://registry.npmjs.org/to-slug-case +929 verbose request where is /to-space-case +930 verbose request registry https://registry.npmjs.org/ +931 verbose url raw /to-space-case +932 verbose url resolving [ 'https://registry.npmjs.org/', './to-space-case' ] +933 verbose url resolved https://registry.npmjs.org/to-space-case +934 verbose request where is https://registry.npmjs.org/to-space-case +935 info trying registry request attempt 1 at 15:14:26 +936 verbose etag "53AG3XNG07DBBQHIXLQ5YIWOR" +937 http GET https://registry.npmjs.org/to-space-case +938 verbose request where is /write-file-stdout +939 verbose request registry https://registry.npmjs.org/ +940 verbose url raw /write-file-stdout +941 verbose url resolving [ 'https://registry.npmjs.org/', './write-file-stdout' ] +942 verbose url resolved https://registry.npmjs.org/write-file-stdout +943 verbose request where is https://registry.npmjs.org/write-file-stdout +944 info trying registry request attempt 1 at 15:14:26 +945 verbose etag "237EKF41RILH8X475X2NMSD5B" +946 http GET https://registry.npmjs.org/write-file-stdout +947 verbose request where is /accepts +948 verbose request registry https://registry.npmjs.org/ +949 verbose url raw /accepts +950 verbose url resolving [ 'https://registry.npmjs.org/', './accepts' ] +951 verbose url resolved https://registry.npmjs.org/accepts +952 verbose request where is https://registry.npmjs.org/accepts +953 info trying registry request attempt 1 at 15:14:26 +954 verbose etag "ELNSNA1PHQ6DL1EBGZQ3P7TCJ" +955 http GET https://registry.npmjs.org/accepts +956 verbose request where is /cookie-signature +957 verbose request registry https://registry.npmjs.org/ +958 verbose url raw /cookie-signature +959 verbose url resolving [ 'https://registry.npmjs.org/', './cookie-signature' ] +960 verbose url resolved https://registry.npmjs.org/cookie-signature +961 verbose request where is https://registry.npmjs.org/cookie-signature +962 info trying registry request attempt 1 at 15:14:26 +963 verbose etag "9HWN5U2NNH9Z9EXH3WET3QQLS" +964 http GET https://registry.npmjs.org/cookie-signature +965 verbose request where is /debug +966 verbose request registry https://registry.npmjs.org/ +967 verbose url raw /debug +968 verbose url resolving [ 'https://registry.npmjs.org/', './debug' ] +969 verbose url resolved https://registry.npmjs.org/debug +970 verbose request where is https://registry.npmjs.org/debug +971 info trying registry request attempt 1 at 15:14:26 +972 verbose etag "X0H4NVRP00Z4L2PSZKJ137OA" +973 http GET https://registry.npmjs.org/debug +974 verbose request where is /depd +975 verbose request registry https://registry.npmjs.org/ +976 verbose url raw /depd +977 verbose url resolving [ 'https://registry.npmjs.org/', './depd' ] +978 verbose url resolved https://registry.npmjs.org/depd +979 verbose request where is https://registry.npmjs.org/depd +980 info trying registry request attempt 1 at 15:14:26 +981 verbose etag "8T9DLEUPVNZ1UV659BU2YG0B0" +982 http GET https://registry.npmjs.org/depd +983 verbose request where is /escape-html +984 verbose request registry https://registry.npmjs.org/ +985 verbose url raw /escape-html +986 verbose url resolving [ 'https://registry.npmjs.org/', './escape-html' ] +987 verbose url resolved https://registry.npmjs.org/escape-html +988 verbose request where is https://registry.npmjs.org/escape-html +989 info trying registry request attempt 1 at 15:14:26 +990 verbose etag "4G2P0ALF56SX4Q9ABO1RC1M99" +991 http GET https://registry.npmjs.org/escape-html +992 verbose request where is /etag +993 verbose request registry https://registry.npmjs.org/ +994 verbose url raw /etag +995 verbose url resolving [ 'https://registry.npmjs.org/', './etag' ] +996 verbose url resolved https://registry.npmjs.org/etag +997 verbose request where is https://registry.npmjs.org/etag +998 info trying registry request attempt 1 at 15:14:26 +999 verbose etag "64EK35902Q25FQ2GK4W2QQAUK" +1000 http GET https://registry.npmjs.org/etag +1001 verbose request where is /finalhandler +1002 verbose request registry https://registry.npmjs.org/ +1003 verbose url raw /finalhandler +1004 verbose url resolving [ 'https://registry.npmjs.org/', './finalhandler' ] +1005 verbose url resolved https://registry.npmjs.org/finalhandler +1006 verbose request where is https://registry.npmjs.org/finalhandler +1007 info trying registry request attempt 1 at 15:14:26 +1008 verbose etag "7TAEELCVS48GXUVTTA4BYV1XJ" +1009 http GET https://registry.npmjs.org/finalhandler +1010 verbose request where is /fresh +1011 verbose request registry https://registry.npmjs.org/ +1012 verbose url raw /fresh +1013 verbose url resolving [ 'https://registry.npmjs.org/', './fresh' ] +1014 verbose url resolved https://registry.npmjs.org/fresh +1015 verbose request where is https://registry.npmjs.org/fresh +1016 info trying registry request attempt 1 at 15:14:26 +1017 verbose etag "HJGEEPXN225JRJT8SA8QQAD1" +1018 http GET https://registry.npmjs.org/fresh +1019 verbose request where is /media-typer +1020 verbose request registry https://registry.npmjs.org/ +1021 verbose url raw /media-typer +1022 verbose url resolving [ 'https://registry.npmjs.org/', './media-typer' ] +1023 verbose url resolved https://registry.npmjs.org/media-typer +1024 verbose request where is https://registry.npmjs.org/media-typer +1025 info trying registry request attempt 1 at 15:14:26 +1026 verbose etag "A84XZ4O9ENQU3AD5YUYUJ10SK" +1027 http GET https://registry.npmjs.org/media-typer +1028 verbose request where is /methods +1029 verbose request registry https://registry.npmjs.org/ +1030 verbose url raw /methods +1031 verbose url resolving [ 'https://registry.npmjs.org/', './methods' ] +1032 verbose url resolved https://registry.npmjs.org/methods +1033 verbose request where is https://registry.npmjs.org/methods +1034 info trying registry request attempt 1 at 15:14:26 +1035 verbose etag "4BCT47GG6VS8ZP1QYAS8AKQ9W" +1036 http GET https://registry.npmjs.org/methods +1037 verbose request where is /on-finished +1038 verbose request registry https://registry.npmjs.org/ +1039 verbose url raw /on-finished +1040 verbose url resolving [ 'https://registry.npmjs.org/', './on-finished' ] +1041 verbose url resolved https://registry.npmjs.org/on-finished +1042 verbose request where is https://registry.npmjs.org/on-finished +1043 info trying registry request attempt 1 at 15:14:26 +1044 verbose etag "TJSHDORY4W4OFL409Y2422TD" +1045 http GET https://registry.npmjs.org/on-finished +1046 verbose request where is /parseurl +1047 verbose request registry https://registry.npmjs.org/ +1048 verbose url raw /parseurl +1049 verbose url resolving [ 'https://registry.npmjs.org/', './parseurl' ] +1050 verbose url resolved https://registry.npmjs.org/parseurl +1051 verbose request where is https://registry.npmjs.org/parseurl +1052 info trying registry request attempt 1 at 15:14:26 +1053 verbose etag "7OTQ1DASF9QV0K8V0NYJE9HP3" +1054 http GET https://registry.npmjs.org/parseurl +1055 verbose request where is /path-to-regexp +1056 verbose request registry https://registry.npmjs.org/ +1057 verbose url raw /path-to-regexp +1058 verbose url resolving [ 'https://registry.npmjs.org/', './path-to-regexp' ] +1059 verbose url resolved https://registry.npmjs.org/path-to-regexp +1060 verbose request where is https://registry.npmjs.org/path-to-regexp +1061 info trying registry request attempt 1 at 15:14:26 +1062 verbose etag "4C29CQHFWZTDNQRAE5HRKD7HM" +1063 http GET https://registry.npmjs.org/path-to-regexp +1064 verbose request where is /proxy-addr +1065 verbose request registry https://registry.npmjs.org/ +1066 verbose url raw /proxy-addr +1067 verbose url resolving [ 'https://registry.npmjs.org/', './proxy-addr' ] +1068 verbose url resolved https://registry.npmjs.org/proxy-addr +1069 verbose request where is https://registry.npmjs.org/proxy-addr +1070 info trying registry request attempt 1 at 15:14:26 +1071 verbose etag "9YLW1E0GZQM8CAN5XS8FLBJ1I" +1072 http GET https://registry.npmjs.org/proxy-addr +1073 verbose request where is /range-parser +1074 verbose request registry https://registry.npmjs.org/ +1075 verbose url raw /range-parser +1076 verbose url resolving [ 'https://registry.npmjs.org/', './range-parser' ] +1077 verbose url resolved https://registry.npmjs.org/range-parser +1078 verbose request where is https://registry.npmjs.org/range-parser +1079 info trying registry request attempt 1 at 15:14:26 +1080 verbose etag "2M3421NBY3DYCB3V1HKCGQXRT" +1081 http GET https://registry.npmjs.org/range-parser +1082 verbose request where is /qs +1083 verbose request registry https://registry.npmjs.org/ +1084 verbose url raw /qs +1085 verbose url resolving [ 'https://registry.npmjs.org/', './qs' ] +1086 verbose url resolved https://registry.npmjs.org/qs +1087 verbose request where is https://registry.npmjs.org/qs +1088 info trying registry request attempt 1 at 15:14:26 +1089 verbose etag "8SEIQJWT2RMN54Q374IC594T0" +1090 http GET https://registry.npmjs.org/qs +1091 verbose request where is /send +1092 verbose request registry https://registry.npmjs.org/ +1093 verbose url raw /send +1094 verbose url resolving [ 'https://registry.npmjs.org/', './send' ] +1095 verbose url resolved https://registry.npmjs.org/send +1096 verbose request where is https://registry.npmjs.org/send +1097 info trying registry request attempt 1 at 15:14:26 +1098 verbose etag "73B1VUJ40QRDH0J5PVQWE0JI7" +1099 http GET https://registry.npmjs.org/send +1100 verbose request where is /type-is +1101 verbose request registry https://registry.npmjs.org/ +1102 verbose url raw /type-is +1103 verbose url resolving [ 'https://registry.npmjs.org/', './type-is' ] +1104 verbose url resolved https://registry.npmjs.org/type-is +1105 verbose request where is https://registry.npmjs.org/type-is +1106 info trying registry request attempt 1 at 15:14:26 +1107 verbose etag "29O0KJ1DUNVU0DP2LEKDAAMDI" +1108 http GET https://registry.npmjs.org/type-is +1109 verbose request where is /serve-static +1110 verbose request registry https://registry.npmjs.org/ +1111 verbose url raw /serve-static +1112 verbose url resolving [ 'https://registry.npmjs.org/', './serve-static' ] +1113 verbose url resolved https://registry.npmjs.org/serve-static +1114 verbose request where is https://registry.npmjs.org/serve-static +1115 info trying registry request attempt 1 at 15:14:26 +1116 verbose etag "6QEO5CGGMZYV8CGD5B7WJ9DPK" +1117 http GET https://registry.npmjs.org/serve-static +1118 verbose request where is /vary +1119 verbose request registry https://registry.npmjs.org/ +1120 verbose url raw /vary +1121 verbose url resolving [ 'https://registry.npmjs.org/', './vary' ] +1122 verbose url resolved https://registry.npmjs.org/vary +1123 verbose request where is https://registry.npmjs.org/vary +1124 info trying registry request attempt 1 at 15:14:26 +1125 verbose etag "2CXDH33HAJ3IFR588FMFDV67K" +1126 http GET https://registry.npmjs.org/vary +1127 verbose request where is /cookie +1128 verbose request registry https://registry.npmjs.org/ +1129 verbose url raw /cookie +1130 verbose url resolving [ 'https://registry.npmjs.org/', './cookie' ] +1131 verbose url resolved https://registry.npmjs.org/cookie +1132 verbose request where is https://registry.npmjs.org/cookie +1133 info trying registry request attempt 1 at 15:14:26 +1134 verbose etag "ESDBTEE85PYVI0X5XWIZUBGVA" +1135 http GET https://registry.npmjs.org/cookie +1136 verbose request where is /merge-descriptors +1137 verbose request registry https://registry.npmjs.org/ +1138 verbose url raw /merge-descriptors +1139 verbose url resolving [ 'https://registry.npmjs.org/', './merge-descriptors' ] +1140 verbose url resolved https://registry.npmjs.org/merge-descriptors +1141 verbose request where is https://registry.npmjs.org/merge-descriptors +1142 info trying registry request attempt 1 at 15:14:26 +1143 verbose etag "3RYSGNCRJI3J41K25KQGWTAO8" +1144 http GET https://registry.npmjs.org/merge-descriptors +1145 verbose request where is /utils-merge +1146 verbose request registry https://registry.npmjs.org/ +1147 verbose url raw /utils-merge +1148 verbose url resolving [ 'https://registry.npmjs.org/', './utils-merge' ] +1149 verbose url resolved https://registry.npmjs.org/utils-merge +1150 verbose request where is https://registry.npmjs.org/utils-merge +1151 info trying registry request attempt 1 at 15:14:26 +1152 verbose etag "B2A6FDCPPSSHMH9XOGUS29BLY" +1153 http GET https://registry.npmjs.org/utils-merge +1154 http 304 https://registry.npmjs.org/html5 +1155 silly registry.get cb [ 304, +1155 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +1155 silly registry.get server: 'Apache', +1155 silly registry.get via: '1.1 varnish', +1155 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:26 GMT', +1155 silly registry.get 'cache-control': 'max-age=60', +1155 silly registry.get etag: '"1N7CBOGNXAWMGSVPWKJPL56U2"', +1155 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1155 silly registry.get 'x-cache': 'HIT', +1155 silly registry.get 'x-cache-hits': '1', +1155 silly registry.get 'x-timer': 'S1411067666.499474,VS0,VE35', +1155 silly registry.get vary: 'Accept', +1155 silly registry.get 'content-length': '0', +1155 silly registry.get 'keep-alive': 'timeout=10, max=41', +1155 silly registry.get connection: 'Keep-Alive' } ] +1156 verbose etag https://registry.npmjs.org/html5 from cache +1157 http 304 https://registry.npmjs.org/mime +1158 silly registry.get cb [ 304, +1158 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +1158 silly registry.get server: 'Apache', +1158 silly registry.get via: '1.1 varnish', +1158 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:13:41 GMT', +1158 silly registry.get 'cache-control': 'max-age=60', +1158 silly registry.get etag: '"3RL1A9NN22779LE2SEPGHPY1D"', +1158 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +1158 silly registry.get 'x-cache': 'HIT', +1158 silly registry.get 'x-cache-hits': '3', +1158 silly registry.get 'x-timer': 'S1411067666.522014,VS0,VE0', +1158 silly registry.get vary: 'Accept', +1158 silly registry.get 'content-length': '0', +1158 silly registry.get 'keep-alive': 'timeout=10, max=45', +1158 silly registry.get connection: 'Keep-Alive' } ] +1159 verbose etag https://registry.npmjs.org/mime from cache +1160 http 304 https://registry.npmjs.org/ms +1161 silly registry.get cb [ 304, +1161 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +1161 silly registry.get server: 'Apache', +1161 silly registry.get via: '1.1 varnish', +1161 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:26 GMT', +1161 silly registry.get 'cache-control': 'max-age=60', +1161 silly registry.get etag: '"3CU3HCGNOE4PX802QLNZWR14Q"', +1161 silly registry.get 'x-served-by': 'cache-dfw1834-DFW', +1161 silly registry.get 'x-cache': 'HIT', +1161 silly registry.get 'x-cache-hits': '1', +1161 silly registry.get 'x-timer': 'S1411067666.521028,VS0,VE0', +1161 silly registry.get vary: 'Accept', +1161 silly registry.get 'content-length': '0', +1161 silly registry.get 'keep-alive': 'timeout=10, max=46', +1161 silly registry.get connection: 'Keep-Alive' } ] +1162 verbose etag https://registry.npmjs.org/ms from cache +1163 http 304 https://registry.npmjs.org/eventsource +1164 silly registry.get cb [ 304, +1164 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +1164 silly registry.get server: 'Apache', +1164 silly registry.get via: '1.1 varnish', +1164 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:26 GMT', +1164 silly registry.get 'cache-control': 'max-age=60', +1164 silly registry.get etag: '"AUC5YKH7PBCHS548P1Q64MA7T"', +1164 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +1164 silly registry.get 'x-cache': 'HIT', +1164 silly registry.get 'x-cache-hits': '1', +1164 silly registry.get 'x-timer': 'S1411067666.523804,VS0,VE46', +1164 silly registry.get vary: 'Accept', +1164 silly registry.get 'content-length': '0', +1164 silly registry.get 'keep-alive': 'timeout=10, max=46', +1164 silly registry.get connection: 'Keep-Alive' } ] +1165 verbose etag https://registry.npmjs.org/eventsource from cache +1166 http 304 https://registry.npmjs.org/q +1167 silly registry.get cb [ 304, +1167 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +1167 silly registry.get server: 'Apache', +1167 silly registry.get via: '1.1 varnish', +1167 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:26 GMT', +1167 silly registry.get 'cache-control': 'max-age=60', +1167 silly registry.get etag: '"104OS4379Y6P3299PJUGCA1RK"', +1167 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1167 silly registry.get 'x-cache': 'HIT', +1167 silly registry.get 'x-cache-hits': '1', +1167 silly registry.get 'x-timer': 'S1411067666.609301,VS0,VE0', +1167 silly registry.get vary: 'Accept', +1167 silly registry.get 'content-length': '0', +1167 silly registry.get 'keep-alive': 'timeout=10, max=40', +1167 silly registry.get connection: 'Keep-Alive' } ] +1168 verbose etag https://registry.npmjs.org/q from cache +1169 http 304 https://registry.npmjs.org/tough-cookie +1170 silly registry.get cb [ 304, +1170 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +1170 silly registry.get server: 'Apache', +1170 silly registry.get via: '1.1 varnish', +1170 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:25 GMT', +1170 silly registry.get 'cache-control': 'max-age=60', +1170 silly registry.get etag: '"1G7S58M86AI65KWATAOJG919F"', +1170 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1170 silly registry.get 'x-cache': 'HIT', +1170 silly registry.get 'x-cache-hits': '2', +1170 silly registry.get 'x-timer': 'S1411067666.645679,VS0,VE0', +1170 silly registry.get vary: 'Accept', +1170 silly registry.get 'content-length': '0', +1170 silly registry.get 'keep-alive': 'timeout=10, max=39', +1170 silly registry.get connection: 'Keep-Alive' } ] +1171 verbose etag https://registry.npmjs.org/tough-cookie from cache +1172 http 304 https://registry.npmjs.org/request +1173 silly registry.get cb [ 304, +1173 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +1173 silly registry.get server: 'Apache', +1173 silly registry.get via: '1.1 varnish', +1173 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:13:55 GMT', +1173 silly registry.get 'cache-control': 'max-age=60', +1173 silly registry.get etag: '"B99QGY0F0TJZ3MX6I8GT2OFD3"', +1173 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +1173 silly registry.get 'x-cache': 'HIT', +1173 silly registry.get 'x-cache-hits': '2', +1173 silly registry.get 'x-timer': 'S1411067666.631708,VS0,VE0', +1173 silly registry.get vary: 'Accept', +1173 silly registry.get 'content-length': '0', +1173 silly registry.get 'keep-alive': 'timeout=10, max=44', +1173 silly registry.get connection: 'Keep-Alive' } ] +1174 verbose etag https://registry.npmjs.org/request from cache +1175 http 304 https://registry.npmjs.org/ws +1176 silly registry.get cb [ 304, +1176 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +1176 silly registry.get server: 'Apache', +1176 silly registry.get via: '1.1 varnish', +1176 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:26 GMT', +1176 silly registry.get 'cache-control': 'max-age=60', +1176 silly registry.get etag: '"EPO9OJQ4QEXJT3PL7TGX57EEM"', +1176 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +1176 silly registry.get 'x-cache': 'HIT', +1176 silly registry.get 'x-cache-hits': '1', +1176 silly registry.get 'x-timer': 'S1411067666.645172,VS0,VE0', +1176 silly registry.get vary: 'Accept', +1176 silly registry.get 'content-length': '0', +1176 silly registry.get 'keep-alive': 'timeout=10, max=45', +1176 silly registry.get connection: 'Keep-Alive' } ] +1177 verbose etag https://registry.npmjs.org/ws from cache +1178 http 304 https://registry.npmjs.org/nopt +1179 silly registry.get cb [ 304, +1179 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +1179 silly registry.get server: 'Apache', +1179 silly registry.get via: '1.1 varnish', +1179 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:24 GMT', +1179 silly registry.get 'cache-control': 'max-age=60', +1179 silly registry.get etag: '"6CCBTH44V99TMQVK8E45ICBN7"', +1179 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1179 silly registry.get 'x-cache': 'HIT', +1179 silly registry.get 'x-cache-hits': '2', +1179 silly registry.get 'x-timer': 'S1411067666.673185,VS0,VE0', +1179 silly registry.get vary: 'Accept', +1179 silly registry.get 'content-length': '0', +1179 silly registry.get 'keep-alive': 'timeout=10, max=38', +1179 silly registry.get connection: 'Keep-Alive' } ] +1180 verbose etag https://registry.npmjs.org/nopt from cache +1181 verbose request where is /di +1182 verbose request registry https://registry.npmjs.org/ +1183 verbose url raw /di +1184 verbose url resolving [ 'https://registry.npmjs.org/', './di' ] +1185 verbose url resolved https://registry.npmjs.org/di +1186 verbose request where is https://registry.npmjs.org/di +1187 info trying registry request attempt 1 at 15:14:26 +1188 verbose etag "CTKG02U8QBHJEHRTPYH0DT4MI" +1189 http GET https://registry.npmjs.org/di +1190 verbose request where is /chokidar +1191 verbose request registry https://registry.npmjs.org/ +1192 verbose url raw /chokidar +1193 verbose url resolving [ 'https://registry.npmjs.org/', './chokidar' ] +1194 verbose url resolved https://registry.npmjs.org/chokidar +1195 verbose request where is https://registry.npmjs.org/chokidar +1196 info trying registry request attempt 1 at 15:14:26 +1197 verbose etag "ER41YGW9B4UCCEPXRR8B4LU1F" +1198 http GET https://registry.npmjs.org/chokidar +1199 verbose request where is /socket.io +1200 verbose request registry https://registry.npmjs.org/ +1201 verbose url raw /socket.io +1202 verbose url resolving [ 'https://registry.npmjs.org/', './socket.io' ] +1203 verbose url resolved https://registry.npmjs.org/socket.io +1204 verbose request where is https://registry.npmjs.org/socket.io +1205 info trying registry request attempt 1 at 15:14:26 +1206 verbose etag "CUNVWZ66Q6QU7EFO1CU2GJUNK" +1207 http GET https://registry.npmjs.org/socket.io +1208 verbose request where is /glob +1209 verbose request registry https://registry.npmjs.org/ +1210 verbose url raw /glob +1211 verbose url resolving [ 'https://registry.npmjs.org/', './glob' ] +1212 verbose url resolved https://registry.npmjs.org/glob +1213 verbose request where is https://registry.npmjs.org/glob +1214 info trying registry request attempt 1 at 15:14:26 +1215 verbose etag "9GMKCNKBK5IQ307969W8CTPJB" +1216 http GET https://registry.npmjs.org/glob +1217 verbose request where is /minimatch +1218 verbose request registry https://registry.npmjs.org/ +1219 verbose url raw /minimatch +1220 verbose url resolving [ 'https://registry.npmjs.org/', './minimatch' ] +1221 verbose url resolved https://registry.npmjs.org/minimatch +1222 verbose request where is https://registry.npmjs.org/minimatch +1223 info trying registry request attempt 1 at 15:14:26 +1224 verbose etag "667Q92RS6N1601AM7ZZ1NERE8" +1225 http GET https://registry.npmjs.org/minimatch +1226 verbose request where is /http-proxy +1227 verbose request registry https://registry.npmjs.org/ +1228 verbose url raw /http-proxy +1229 verbose url resolving [ 'https://registry.npmjs.org/', './http-proxy' ] +1230 verbose url resolved https://registry.npmjs.org/http-proxy +1231 verbose request where is https://registry.npmjs.org/http-proxy +1232 info trying registry request attempt 1 at 15:14:26 +1233 verbose etag "AWEN52NBCDTUU26TDH6IHPZNQ" +1234 http GET https://registry.npmjs.org/http-proxy +1235 verbose request where is /optimist +1236 verbose request registry https://registry.npmjs.org/ +1237 verbose url raw /optimist +1238 verbose url resolving [ 'https://registry.npmjs.org/', './optimist' ] +1239 verbose url resolved https://registry.npmjs.org/optimist +1240 verbose request where is https://registry.npmjs.org/optimist +1241 info trying registry request attempt 1 at 15:14:26 +1242 verbose etag "AY8QEEGZGC3636NYAUBTKPOAX" +1243 http GET https://registry.npmjs.org/optimist +1244 verbose request where is /rimraf +1245 verbose request registry https://registry.npmjs.org/ +1246 verbose url raw /rimraf +1247 verbose url resolving [ 'https://registry.npmjs.org/', './rimraf' ] +1248 verbose url resolved https://registry.npmjs.org/rimraf +1249 verbose request where is https://registry.npmjs.org/rimraf +1250 info trying registry request attempt 1 at 15:14:26 +1251 verbose etag "31YUZD1DFCDSQ0QSBXMA8KMKQ" +1252 http GET https://registry.npmjs.org/rimraf +1253 verbose request where is /colors +1254 verbose request registry https://registry.npmjs.org/ +1255 verbose url raw /colors +1256 verbose url resolving [ 'https://registry.npmjs.org/', './colors' ] +1257 verbose url resolved https://registry.npmjs.org/colors +1258 verbose request where is https://registry.npmjs.org/colors +1259 info trying registry request attempt 1 at 15:14:26 +1260 verbose etag "2ZHMVF9GYTMTHHRFKFO52VJA4" +1261 http GET https://registry.npmjs.org/colors +1262 verbose registry.get https://registry.npmjs.org/q not expired, no request +1263 verbose registry.get https://registry.npmjs.org/mime not expired, no request +1264 verbose request where is /lodash +1265 verbose request registry https://registry.npmjs.org/ +1266 verbose url raw /lodash +1267 verbose url resolving [ 'https://registry.npmjs.org/', './lodash' ] +1268 verbose url resolved https://registry.npmjs.org/lodash +1269 verbose request where is https://registry.npmjs.org/lodash +1270 info trying registry request attempt 1 at 15:14:26 +1271 verbose etag "D4I8Y7O3OF15X88NHWU47Q2H" +1272 http GET https://registry.npmjs.org/lodash +1273 verbose request where is /log4js +1274 verbose request registry https://registry.npmjs.org/ +1275 verbose url raw /log4js +1276 verbose url resolving [ 'https://registry.npmjs.org/', './log4js' ] +1277 verbose url resolved https://registry.npmjs.org/log4js +1278 verbose request where is https://registry.npmjs.org/log4js +1279 info trying registry request attempt 1 at 15:14:26 +1280 verbose etag "CFKQTZ9X482QEVGFU1ZI22J9U" +1281 http GET https://registry.npmjs.org/log4js +1282 verbose request where is /useragent +1283 verbose request registry https://registry.npmjs.org/ +1284 verbose url raw /useragent +1285 verbose url resolving [ 'https://registry.npmjs.org/', './useragent' ] +1286 verbose url resolved https://registry.npmjs.org/useragent +1287 verbose request where is https://registry.npmjs.org/useragent +1288 info trying registry request attempt 1 at 15:14:26 +1289 verbose etag "EK58TZXUSV44E17PS55NRT26J" +1290 http GET https://registry.npmjs.org/useragent +1291 verbose request where is /graceful-fs +1292 verbose request registry https://registry.npmjs.org/ +1293 verbose url raw /graceful-fs +1294 verbose url resolving [ 'https://registry.npmjs.org/', './graceful-fs' ] +1295 verbose url resolved https://registry.npmjs.org/graceful-fs +1296 verbose request where is https://registry.npmjs.org/graceful-fs +1297 info trying registry request attempt 1 at 15:14:26 +1298 verbose etag "CV1ZRY03QL5N3MQLTEZ3C8SMD" +1299 http GET https://registry.npmjs.org/graceful-fs +1300 verbose request where is /source-map +1301 verbose request registry https://registry.npmjs.org/ +1302 verbose url raw /source-map +1303 verbose url resolving [ 'https://registry.npmjs.org/', './source-map' ] +1304 verbose url resolved https://registry.npmjs.org/source-map +1305 verbose request where is https://registry.npmjs.org/source-map +1306 info trying registry request attempt 1 at 15:14:26 +1307 verbose etag "CTPHW9RYNF1ANEGGAB0F3ETOU" +1308 http GET https://registry.npmjs.org/source-map +1309 verbose request where is /connect +1310 verbose request registry https://registry.npmjs.org/ +1311 verbose url raw /connect +1312 verbose url resolving [ 'https://registry.npmjs.org/', './connect' ] +1313 verbose url resolved https://registry.npmjs.org/connect +1314 verbose request where is https://registry.npmjs.org/connect +1315 info trying registry request attempt 1 at 15:14:26 +1316 verbose etag "4OOTKUADN0IZJR06YAB9DW5V5" +1317 http GET https://registry.npmjs.org/connect +1318 http 304 https://registry.npmjs.org/tap +1319 silly registry.get cb [ 304, +1319 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +1319 silly registry.get server: 'Apache', +1319 silly registry.get via: '1.1 varnish', +1319 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:26 GMT', +1319 silly registry.get 'cache-control': 'max-age=60', +1319 silly registry.get etag: '"NN7PYZ6NSJN8YXPBJEV32HPB"', +1319 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1319 silly registry.get 'x-cache': 'HIT', +1319 silly registry.get 'x-cache-hits': '1', +1319 silly registry.get 'x-timer': 'S1411067666.706388,VS0,VE0', +1319 silly registry.get vary: 'Accept', +1319 silly registry.get 'content-length': '0', +1319 silly registry.get 'keep-alive': 'timeout=10, max=37', +1319 silly registry.get connection: 'Keep-Alive' } ] +1320 verbose etag https://registry.npmjs.org/tap from cache +1321 http 304 https://registry.npmjs.org/findup-sync +1322 silly registry.get cb [ 304, +1322 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +1322 silly registry.get server: 'Apache', +1322 silly registry.get via: '1.1 varnish', +1322 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:26 GMT', +1322 silly registry.get 'cache-control': 'max-age=60', +1322 silly registry.get etag: '"2777FKVK8MSMAY1RAAQT5ZRUS"', +1322 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +1322 silly registry.get 'x-cache': 'HIT', +1322 silly registry.get 'x-cache-hits': '1', +1322 silly registry.get 'x-timer': 'S1411067666.710139,VS0,VE0', +1322 silly registry.get vary: 'Accept', +1322 silly registry.get 'content-length': '0', +1322 silly registry.get 'keep-alive': 'timeout=10, max=43', +1322 silly registry.get connection: 'Keep-Alive' } ] +1323 verbose etag https://registry.npmjs.org/findup-sync from cache +1324 verbose request where is /drawille +1325 verbose request registry https://registry.npmjs.org/ +1326 verbose url raw /drawille +1327 verbose url resolving [ 'https://registry.npmjs.org/', './drawille' ] +1328 verbose url resolved https://registry.npmjs.org/drawille +1329 verbose request where is https://registry.npmjs.org/drawille +1330 info trying registry request attempt 1 at 15:14:26 +1331 verbose etag "1UVF72U5X6E0EX5EO7I4FZIN8" +1332 http GET https://registry.npmjs.org/drawille +1333 verbose request where is /os-utils +1334 verbose request registry https://registry.npmjs.org/ +1335 verbose url raw /os-utils +1336 verbose url resolving [ 'https://registry.npmjs.org/', './os-utils' ] +1337 verbose url resolved https://registry.npmjs.org/os-utils +1338 verbose request where is https://registry.npmjs.org/os-utils +1339 info trying registry request attempt 1 at 15:14:26 +1340 verbose etag "40DZ5TBOYP4EQNT6BOB9ZB247" +1341 http GET https://registry.npmjs.org/os-utils +1342 verbose request where is /read +1343 verbose request registry https://registry.npmjs.org/ +1344 verbose url raw /read +1345 verbose url resolving [ 'https://registry.npmjs.org/', './read' ] +1346 verbose url resolved https://registry.npmjs.org/read +1347 verbose request where is https://registry.npmjs.org/read +1348 info trying registry request attempt 1 at 15:14:26 +1349 verbose etag "3GJAEEPR102J14KTQCVBP03AW" +1350 http GET https://registry.npmjs.org/read +1351 verbose request where is /blessed +1352 verbose request registry https://registry.npmjs.org/ +1353 verbose url raw /blessed +1354 verbose url resolving [ 'https://registry.npmjs.org/', './blessed' ] +1355 verbose url resolved https://registry.npmjs.org/blessed +1356 verbose request where is https://registry.npmjs.org/blessed +1357 info trying registry request attempt 1 at 15:14:26 +1358 verbose etag "9C7VCD52SDVQ5ILHKDNGKW5E9" +1359 http GET https://registry.npmjs.org/blessed +1360 verbose request where is /commander +1361 verbose request registry https://registry.npmjs.org/ +1362 verbose url raw /commander +1363 verbose url resolving [ 'https://registry.npmjs.org/', './commander' ] +1364 verbose url resolved https://registry.npmjs.org/commander +1365 verbose request where is https://registry.npmjs.org/commander +1366 info trying registry request attempt 1 at 15:14:26 +1367 verbose etag "64YG0KD6CNHI7FUB33O0JW3G2" +1368 http GET https://registry.npmjs.org/commander +1369 verbose request where is /sudo +1370 verbose request registry https://registry.npmjs.org/ +1371 verbose url raw /sudo +1372 verbose url resolving [ 'https://registry.npmjs.org/', './sudo' ] +1373 verbose url resolved https://registry.npmjs.org/sudo +1374 verbose request where is https://registry.npmjs.org/sudo +1375 info trying registry request attempt 1 at 15:14:26 +1376 verbose etag "6BIYD2GTF2TWOA3ZYDE1VU31M" +1377 http GET https://registry.npmjs.org/sudo +1378 verbose request where is /glob +1379 verbose request registry https://registry.npmjs.org/ +1380 verbose url raw /glob +1381 verbose url resolving [ 'https://registry.npmjs.org/', './glob' ] +1382 verbose url resolved https://registry.npmjs.org/glob +1383 verbose request where is https://registry.npmjs.org/glob +1384 info trying registry request attempt 1 at 15:14:26 +1385 verbose etag "9GMKCNKBK5IQ307969W8CTPJB" +1386 http GET https://registry.npmjs.org/glob +1387 verbose request where is /adm-zip +1388 verbose request registry https://registry.npmjs.org/ +1389 verbose url raw /adm-zip +1390 verbose url resolving [ 'https://registry.npmjs.org/', './adm-zip' ] +1391 verbose url resolved https://registry.npmjs.org/adm-zip +1392 verbose request where is https://registry.npmjs.org/adm-zip +1393 info trying registry request attempt 1 at 15:14:26 +1394 verbose etag "1VY8YMVL2CB98BLU0J0PXFNXN" +1395 http GET https://registry.npmjs.org/adm-zip +1396 verbose request where is /kew +1397 verbose request registry https://registry.npmjs.org/ +1398 verbose url raw /kew +1399 verbose url resolving [ 'https://registry.npmjs.org/', './kew' ] +1400 verbose url resolved https://registry.npmjs.org/kew +1401 verbose request where is https://registry.npmjs.org/kew +1402 info trying registry request attempt 1 at 15:14:26 +1403 verbose etag "O0R55ULEE70HO9OUMS5I19OS" +1404 http GET https://registry.npmjs.org/kew +1405 verbose request where is /npmconf +1406 verbose request registry https://registry.npmjs.org/ +1407 verbose url raw /npmconf +1408 verbose url resolving [ 'https://registry.npmjs.org/', './npmconf' ] +1409 verbose url resolved https://registry.npmjs.org/npmconf +1410 verbose request where is https://registry.npmjs.org/npmconf +1411 info trying registry request attempt 1 at 15:14:26 +1412 verbose etag "7HF6DT5S4MJUYUFN4MTME27TH" +1413 http GET https://registry.npmjs.org/npmconf +1414 verbose request where is /ncp +1415 verbose request registry https://registry.npmjs.org/ +1416 verbose url raw /ncp +1417 verbose url resolving [ 'https://registry.npmjs.org/', './ncp' ] +1418 verbose url resolved https://registry.npmjs.org/ncp +1419 verbose request where is https://registry.npmjs.org/ncp +1420 info trying registry request attempt 1 at 15:14:26 +1421 verbose etag "9KYAENLPK45QQB0WV4L5LKHBL" +1422 http GET https://registry.npmjs.org/ncp +1423 verbose request where is /mkdirp +1424 verbose request registry https://registry.npmjs.org/ +1425 verbose url raw /mkdirp +1426 verbose url resolving [ 'https://registry.npmjs.org/', './mkdirp' ] +1427 verbose url resolved https://registry.npmjs.org/mkdirp +1428 verbose request where is https://registry.npmjs.org/mkdirp +1429 info trying registry request attempt 1 at 15:14:26 +1430 verbose etag "EOPTJ0J36LYXZXUCFC4K7PMWN" +1431 http GET https://registry.npmjs.org/mkdirp +1432 verbose request where is /progress +1433 verbose request registry https://registry.npmjs.org/ +1434 verbose url raw /progress +1435 verbose url resolving [ 'https://registry.npmjs.org/', './progress' ] +1436 verbose url resolved https://registry.npmjs.org/progress +1437 verbose request where is https://registry.npmjs.org/progress +1438 info trying registry request attempt 1 at 15:14:26 +1439 verbose etag "CTBNNWBUBUNHYF6WH3TQHWI9F" +1440 http GET https://registry.npmjs.org/progress +1441 verbose request where is /request-progress +1442 verbose request registry https://registry.npmjs.org/ +1443 verbose url raw /request-progress +1444 verbose url resolving [ 'https://registry.npmjs.org/', './request-progress' ] +1445 verbose url resolved https://registry.npmjs.org/request-progress +1446 verbose request where is https://registry.npmjs.org/request-progress +1447 info trying registry request attempt 1 at 15:14:26 +1448 verbose etag "5X7J2IR4V022O460EXK926ZI6" +1449 http GET https://registry.npmjs.org/request-progress +1450 verbose request where is /rimraf +1451 verbose request registry https://registry.npmjs.org/ +1452 verbose url raw /rimraf +1453 verbose url resolving [ 'https://registry.npmjs.org/', './rimraf' ] +1454 verbose url resolved https://registry.npmjs.org/rimraf +1455 verbose request where is https://registry.npmjs.org/rimraf +1456 info trying registry request attempt 1 at 15:14:26 +1457 verbose etag "31YUZD1DFCDSQ0QSBXMA8KMKQ" +1458 http GET https://registry.npmjs.org/rimraf +1459 verbose request where is /which +1460 verbose request registry https://registry.npmjs.org/ +1461 verbose url raw /which +1462 verbose url resolving [ 'https://registry.npmjs.org/', './which' ] +1463 verbose url resolved https://registry.npmjs.org/which +1464 verbose request where is https://registry.npmjs.org/which +1465 info trying registry request attempt 1 at 15:14:26 +1466 verbose etag "V2MIU40L4XLGREBQDUE5E170" +1467 http GET https://registry.npmjs.org/which +1468 verbose registry.get https://registry.npmjs.org/request not expired, no request +1469 http 304 https://registry.npmjs.org/async +1470 silly registry.get cb [ 304, +1470 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +1470 silly registry.get server: 'Apache', +1470 silly registry.get via: '1.1 varnish', +1470 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:19 GMT', +1470 silly registry.get 'cache-control': 'max-age=60', +1470 silly registry.get etag: '"2SHA3WREMZ70G6R6GENYYEH3K"', +1470 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1470 silly registry.get 'x-cache': 'HIT', +1470 silly registry.get 'x-cache-hits': '3', +1470 silly registry.get 'x-timer': 'S1411067666.762543,VS0,VE0', +1470 silly registry.get vary: 'Accept', +1470 silly registry.get 'content-length': '0', +1470 silly registry.get 'keep-alive': 'timeout=10, max=36', +1470 silly registry.get connection: 'Keep-Alive' } ] +1471 verbose etag https://registry.npmjs.org/async from cache +1472 http 304 https://registry.npmjs.org/esprima +1473 silly registry.get cb [ 304, +1473 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +1473 silly registry.get server: 'Apache', +1473 silly registry.get via: '1.1 varnish', +1473 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:26 GMT', +1473 silly registry.get 'cache-control': 'max-age=60', +1473 silly registry.get etag: '"B2YHUZJLDHJLQY5BTFLG0EUWF"', +1473 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1473 silly registry.get 'x-cache': 'HIT', +1473 silly registry.get 'x-cache-hits': '1', +1473 silly registry.get 'x-timer': 'S1411067666.793816,VS0,VE0', +1473 silly registry.get vary: 'Accept', +1473 silly registry.get 'content-length': '0', +1473 silly registry.get 'keep-alive': 'timeout=10, max=35', +1473 silly registry.get connection: 'Keep-Alive' } ] +1474 verbose etag https://registry.npmjs.org/esprima from cache +1475 http 304 https://registry.npmjs.org/resolve +1476 silly registry.get cb [ 304, +1476 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +1476 silly registry.get server: 'Apache', +1476 silly registry.get via: '1.1 varnish', +1476 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:26 GMT', +1476 silly registry.get 'cache-control': 'max-age=60', +1476 silly registry.get etag: '"65Y7RKJY0AZUEMWT75D8Y4ZJD"', +1476 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +1476 silly registry.get 'x-cache': 'HIT', +1476 silly registry.get 'x-cache-hits': '1', +1476 silly registry.get 'x-timer': 'S1411067666.716686,VS0,VE64', +1476 silly registry.get vary: 'Accept', +1476 silly registry.get 'content-length': '0', +1476 silly registry.get 'keep-alive': 'timeout=10, max=44', +1476 silly registry.get connection: 'Keep-Alive' } ] +1477 verbose etag https://registry.npmjs.org/resolve from cache +1478 http 304 https://registry.npmjs.org/encoding +1479 silly registry.get cb [ 304, +1479 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +1479 silly registry.get server: 'Apache', +1479 silly registry.get via: '1.1 varnish', +1479 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:26 GMT', +1479 silly registry.get 'cache-control': 'max-age=60', +1479 silly registry.get etag: '"BO23RLVR90OLLVTLOXYRFW7M2"', +1479 silly registry.get 'x-served-by': 'cache-dfw1826-DFW', +1479 silly registry.get 'x-cache': 'HIT', +1479 silly registry.get 'x-cache-hits': '1', +1479 silly registry.get 'x-timer': 'S1411067666.515993,VS0,VE268', +1479 silly registry.get vary: 'Accept', +1479 silly registry.get 'content-length': '0', +1479 silly registry.get 'keep-alive': 'timeout=10, max=46', +1479 silly registry.get connection: 'Keep-Alive' } ] +1480 verbose etag https://registry.npmjs.org/encoding from cache +1481 http 304 https://registry.npmjs.org/jsdom +1482 silly registry.get cb [ 304, +1482 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +1482 silly registry.get server: 'Apache', +1482 silly registry.get via: '1.1 varnish', +1482 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:26 GMT', +1482 silly registry.get 'cache-control': 'max-age=60', +1482 silly registry.get etag: '"EZVAUFBWM1HOE2TTAWE00ADNT"', +1482 silly registry.get 'x-served-by': 'cache-dfw1834-DFW', +1482 silly registry.get 'x-cache': 'HIT', +1482 silly registry.get 'x-cache-hits': '1', +1482 silly registry.get 'x-timer': 'S1411067666.635806,VS0,VE190', +1482 silly registry.get vary: 'Accept', +1482 silly registry.get 'content-length': '0', +1482 silly registry.get 'keep-alive': 'timeout=10, max=45', +1482 silly registry.get connection: 'Keep-Alive' } ] +1483 verbose etag https://registry.npmjs.org/jsdom from cache +1484 verbose cache add [ 'esprima', +1484 verbose cache add 'https://github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c' ] +1485 verbose cache add name="esprima" spec="https://github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c" args=["esprima","https://github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c"] +1486 verbose parsed url { protocol: 'https:', +1486 verbose parsed url slashes: true, +1486 verbose parsed url auth: null, +1486 verbose parsed url host: 'github.com', +1486 verbose parsed url port: null, +1486 verbose parsed url hostname: 'github.com', +1486 verbose parsed url hash: null, +1486 verbose parsed url search: null, +1486 verbose parsed url query: null, +1486 verbose parsed url pathname: '/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c', +1486 verbose parsed url path: '/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c', +1486 verbose parsed url href: 'https://github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c' } +1487 silly lockFile db72957f-243f29bd653b11e9419241a9d726af7c https://github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c +1488 verbose lock https://github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c /root/.npm/db72957f-243f29bd653b11e9419241a9d726af7c.lock +1489 http 304 https://registry.npmjs.org/catharsis +1490 silly registry.get cb [ 304, +1490 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +1490 silly registry.get server: 'Apache', +1490 silly registry.get via: '1.1 varnish', +1490 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:26 GMT', +1490 silly registry.get 'cache-control': 'max-age=60', +1490 silly registry.get etag: '"8Z6Z1YVYKC17IM25479Q82VQ9"', +1490 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +1490 silly registry.get 'x-cache': 'MISS', +1490 silly registry.get 'x-cache-hits': '0', +1490 silly registry.get 'x-timer': 'S1411067666.789900,VS0,VE64', +1490 silly registry.get vary: 'Accept', +1490 silly registry.get 'content-length': '0', +1490 silly registry.get 'keep-alive': 'timeout=10, max=42', +1490 silly registry.get connection: 'Keep-Alive' } ] +1491 verbose etag https://registry.npmjs.org/catharsis from cache +1492 verbose request where is /punycode +1493 verbose request registry https://registry.npmjs.org/ +1494 verbose url raw /punycode +1495 verbose url resolving [ 'https://registry.npmjs.org/', './punycode' ] +1496 verbose url resolved https://registry.npmjs.org/punycode +1497 verbose request where is https://registry.npmjs.org/punycode +1498 info trying registry request attempt 1 at 15:14:26 +1499 verbose etag "4BW1YHT5BPGKOFNC5XEHSTVES" +1500 http GET https://registry.npmjs.org/punycode +1501 verbose addRemoteTarball [ 'https://github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c', +1501 verbose addRemoteTarball null ] +1502 verbose request where is /glob +1503 verbose request registry https://registry.npmjs.org/ +1504 verbose url raw /glob +1505 verbose url resolving [ 'https://registry.npmjs.org/', './glob' ] +1506 verbose url resolved https://registry.npmjs.org/glob +1507 verbose request where is https://registry.npmjs.org/glob +1508 info trying registry request attempt 1 at 15:14:26 +1509 verbose etag "9GMKCNKBK5IQ307969W8CTPJB" +1510 http GET https://registry.npmjs.org/glob +1511 verbose request where is /lodash +1512 verbose request registry https://registry.npmjs.org/ +1513 verbose url raw /lodash +1514 verbose url resolving [ 'https://registry.npmjs.org/', './lodash' ] +1515 verbose url resolved https://registry.npmjs.org/lodash +1516 verbose request where is https://registry.npmjs.org/lodash +1517 info trying registry request attempt 1 at 15:14:26 +1518 verbose etag "D4I8Y7O3OF15X88NHWU47Q2H" +1519 http GET https://registry.npmjs.org/lodash +1520 verbose request where is /buffer-equal +1521 verbose request registry https://registry.npmjs.org/ +1522 verbose url raw /buffer-equal +1523 verbose url resolving [ 'https://registry.npmjs.org/', './buffer-equal' ] +1524 verbose url resolved https://registry.npmjs.org/buffer-equal +1525 verbose request where is https://registry.npmjs.org/buffer-equal +1526 info trying registry request attempt 1 at 15:14:26 +1527 verbose etag "23N78YD77LZ993F7JQGSAWXBV" +1528 http GET https://registry.npmjs.org/buffer-equal +1529 verbose request where is /deep-equal +1530 verbose request registry https://registry.npmjs.org/ +1531 verbose url raw /deep-equal +1532 verbose url resolving [ 'https://registry.npmjs.org/', './deep-equal' ] +1533 verbose url resolved https://registry.npmjs.org/deep-equal +1534 verbose request where is https://registry.npmjs.org/deep-equal +1535 info trying registry request attempt 1 at 15:14:26 +1536 verbose etag "BOXPPUZO0BER36QDXAATF1DID" +1537 http GET https://registry.npmjs.org/deep-equal +1538 verbose request where is /difflet +1539 verbose request registry https://registry.npmjs.org/ +1540 verbose url raw /difflet +1541 verbose url resolving [ 'https://registry.npmjs.org/', './difflet' ] +1542 verbose url resolved https://registry.npmjs.org/difflet +1543 verbose request where is https://registry.npmjs.org/difflet +1544 info trying registry request attempt 1 at 15:14:26 +1545 verbose etag "8OKQMP1JMJA3TEJ7OXQI9W6YW" +1546 http GET https://registry.npmjs.org/difflet +1547 verbose request where is /glob +1548 verbose request registry https://registry.npmjs.org/ +1549 verbose url raw /glob +1550 verbose url resolving [ 'https://registry.npmjs.org/', './glob' ] +1551 verbose url resolved https://registry.npmjs.org/glob +1552 verbose request where is https://registry.npmjs.org/glob +1553 info trying registry request attempt 1 at 15:14:26 +1554 verbose etag "9GMKCNKBK5IQ307969W8CTPJB" +1555 http GET https://registry.npmjs.org/glob +1556 verbose request where is /inherits +1557 verbose request registry https://registry.npmjs.org/ +1558 verbose url raw /inherits +1559 verbose url resolving [ 'https://registry.npmjs.org/', './inherits' ] +1560 verbose url resolved https://registry.npmjs.org/inherits +1561 verbose request where is https://registry.npmjs.org/inherits +1562 info trying registry request attempt 1 at 15:14:26 +1563 verbose etag "BVVVLO9F0SYSTO7F6UCP7E16D" +1564 http GET https://registry.npmjs.org/inherits +1565 verbose request where is /mkdirp +1566 verbose request registry https://registry.npmjs.org/ +1567 verbose url raw /mkdirp +1568 verbose url resolving [ 'https://registry.npmjs.org/', './mkdirp' ] +1569 verbose url resolved https://registry.npmjs.org/mkdirp +1570 verbose request where is https://registry.npmjs.org/mkdirp +1571 info trying registry request attempt 1 at 15:14:26 +1572 verbose etag "EOPTJ0J36LYXZXUCFC4K7PMWN" +1573 http GET https://registry.npmjs.org/mkdirp +1574 verbose registry.get https://registry.npmjs.org/nopt not expired, no request +1575 verbose request where is /runforcover +1576 verbose request registry https://registry.npmjs.org/ +1577 verbose url raw /runforcover +1578 verbose url resolving [ 'https://registry.npmjs.org/', './runforcover' ] +1579 verbose url resolved https://registry.npmjs.org/runforcover +1580 verbose request where is https://registry.npmjs.org/runforcover +1581 info trying registry request attempt 1 at 15:14:26 +1582 verbose etag "A7MHIHFIYLRSW8NQC4LF47YMB" +1583 http GET https://registry.npmjs.org/runforcover +1584 verbose request where is /slide +1585 verbose request registry https://registry.npmjs.org/ +1586 verbose url raw /slide +1587 verbose url resolving [ 'https://registry.npmjs.org/', './slide' ] +1588 verbose url resolved https://registry.npmjs.org/slide +1589 verbose request where is https://registry.npmjs.org/slide +1590 info trying registry request attempt 1 at 15:14:26 +1591 verbose etag "1OT32GGB2TU0R1KZ4F5ORHEAG" +1592 http GET https://registry.npmjs.org/slide +1593 verbose request where is /yamlish +1594 verbose request registry https://registry.npmjs.org/ +1595 verbose url raw /yamlish +1596 verbose url resolving [ 'https://registry.npmjs.org/', './yamlish' ] +1597 verbose url resolved https://registry.npmjs.org/yamlish +1598 verbose request where is https://registry.npmjs.org/yamlish +1599 info trying registry request attempt 1 at 15:14:26 +1600 verbose etag "5I8XWLRMZJYBEIKOU7YG7UF28" +1601 http GET https://registry.npmjs.org/yamlish +1602 http 304 https://registry.npmjs.org/strip-json-comments +1603 silly registry.get cb [ 304, +1603 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +1603 silly registry.get server: 'Apache', +1603 silly registry.get via: '1.1 varnish', +1603 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:13:54 GMT', +1603 silly registry.get 'cache-control': 'max-age=60', +1603 silly registry.get etag: '"3GM69ADPH31NYUQEBY0XTMOO8"', +1603 silly registry.get 'x-served-by': 'cache-dfw1834-DFW', +1603 silly registry.get 'x-cache': 'HIT', +1603 silly registry.get 'x-cache-hits': '2', +1603 silly registry.get 'x-timer': 'S1411067666.889970,VS0,VE0', +1603 silly registry.get vary: 'Accept', +1603 silly registry.get 'content-length': '0', +1603 silly registry.get 'keep-alive': 'timeout=10, max=44', +1603 silly registry.get connection: 'Keep-Alive' } ] +1604 verbose etag https://registry.npmjs.org/strip-json-comments from cache +1605 info retry fetch attempt 1 at 15:14:26 +1606 verbose fetch to= /tmp/npm-17670-yMiqFMg9/github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c +1607 http GET https://github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c +1608 verbose request where is /underscore-contrib +1609 verbose request registry https://registry.npmjs.org/ +1610 verbose url raw /underscore-contrib +1611 verbose url resolving [ 'https://registry.npmjs.org/', './underscore-contrib' ] +1612 verbose url resolved https://registry.npmjs.org/underscore-contrib +1613 verbose request where is https://registry.npmjs.org/underscore-contrib +1614 info trying registry request attempt 1 at 15:14:26 +1615 verbose etag "A7V2IWHWA0LLU5TGPGSX7OIGK" +1616 http GET https://registry.npmjs.org/underscore-contrib +1617 http 304 https://registry.npmjs.org/js2xmlparser +1618 silly registry.get cb [ 304, +1618 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +1618 silly registry.get server: 'Apache', +1618 silly registry.get via: '1.1 varnish', +1618 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:26 GMT', +1618 silly registry.get 'cache-control': 'max-age=60', +1618 silly registry.get etag: '"2BW06ID2IKUM2FHTO9G3PV7K8"', +1618 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1618 silly registry.get 'x-cache': 'HIT', +1618 silly registry.get 'x-cache-hits': '1', +1618 silly registry.get 'x-timer': 'S1411067666.814795,VS0,VE138', +1618 silly registry.get vary: 'Accept', +1618 silly registry.get 'content-length': '0', +1618 silly registry.get 'keep-alive': 'timeout=10, max=34', +1618 silly registry.get connection: 'Keep-Alive' } ] +1619 verbose etag https://registry.npmjs.org/js2xmlparser from cache +1620 http 304 https://registry.npmjs.org/underscore +1621 silly registry.get cb [ 304, +1621 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +1621 silly registry.get server: 'Apache', +1621 silly registry.get via: '1.1 varnish', +1621 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:26 GMT', +1621 silly registry.get 'cache-control': 'max-age=60', +1621 silly registry.get etag: '"5OGA5GQ7HZATEPFVT518NY84U"', +1621 silly registry.get 'x-served-by': 'cache-dfw1834-DFW', +1621 silly registry.get 'x-cache': 'HIT', +1621 silly registry.get 'x-cache-hits': '1', +1621 silly registry.get 'x-timer': 'S1411067666.953731,VS0,VE0', +1621 silly registry.get vary: 'Accept', +1621 silly registry.get 'content-length': '0', +1621 silly registry.get 'keep-alive': 'timeout=10, max=43', +1621 silly registry.get connection: 'Keep-Alive' } ] +1622 verbose etag https://registry.npmjs.org/underscore from cache +1623 http 304 https://registry.npmjs.org/wrench +1624 silly registry.get cb [ 304, +1624 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +1624 silly registry.get server: 'Apache', +1624 silly registry.get via: '1.1 varnish', +1624 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:26 GMT', +1624 silly registry.get 'cache-control': 'max-age=60', +1624 silly registry.get etag: '"EENWN97PIHO11KNBYBXNXYPKS"', +1624 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1624 silly registry.get 'x-cache': 'HIT', +1624 silly registry.get 'x-cache-hits': '1', +1624 silly registry.get 'x-timer': 'S1411067666.975594,VS0,VE0', +1624 silly registry.get vary: 'Accept', +1624 silly registry.get 'content-length': '0', +1624 silly registry.get 'keep-alive': 'timeout=10, max=33', +1624 silly registry.get connection: 'Keep-Alive' } ] +1625 verbose etag https://registry.npmjs.org/wrench from cache +1626 http 304 https://registry.npmjs.org/mkdirp +1627 silly registry.get cb [ 304, +1627 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +1627 silly registry.get server: 'Apache', +1627 silly registry.get via: '1.1 varnish', +1627 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:10 GMT', +1627 silly registry.get 'cache-control': 'max-age=60', +1627 silly registry.get etag: '"EOPTJ0J36LYXZXUCFC4K7PMWN"', +1627 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1627 silly registry.get 'x-cache': 'HIT', +1627 silly registry.get 'x-cache-hits': '3', +1627 silly registry.get 'x-timer': 'S1411067666.997164,VS0,VE0', +1627 silly registry.get vary: 'Accept', +1627 silly registry.get 'content-length': '0', +1627 silly registry.get 'keep-alive': 'timeout=10, max=32', +1627 silly registry.get connection: 'Keep-Alive' } ] +1628 verbose etag https://registry.npmjs.org/mkdirp from cache +1629 verbose request where is /minimist +1630 verbose request registry https://registry.npmjs.org/ +1631 verbose url raw /minimist +1632 verbose url resolving [ 'https://registry.npmjs.org/', './minimist' ] +1633 verbose url resolved https://registry.npmjs.org/minimist +1634 verbose request where is https://registry.npmjs.org/minimist +1635 info trying registry request attempt 1 at 15:14:27 +1636 verbose etag "AHII70P6K2F5XHCZ6RO4Y7WMM" +1637 http GET https://registry.npmjs.org/minimist +1638 http 304 https://registry.npmjs.org/async +1639 silly registry.get cb [ 304, +1639 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1639 silly registry.get server: 'Apache', +1639 silly registry.get via: '1.1 varnish', +1639 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:19 GMT', +1639 silly registry.get 'cache-control': 'max-age=60', +1639 silly registry.get etag: '"2SHA3WREMZ70G6R6GENYYEH3K"', +1639 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1639 silly registry.get 'x-cache': 'HIT', +1639 silly registry.get 'x-cache-hits': '4', +1639 silly registry.get 'x-timer': 'S1411067667.017588,VS0,VE0', +1639 silly registry.get vary: 'Accept', +1639 silly registry.get 'content-length': '0', +1639 silly registry.get 'keep-alive': 'timeout=10, max=31', +1639 silly registry.get connection: 'Keep-Alive' } ] +1640 verbose etag https://registry.npmjs.org/async from cache +1641 http 304 https://registry.npmjs.org/commander +1642 silly registry.get cb [ 304, +1642 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1642 silly registry.get server: 'Apache', +1642 silly registry.get via: '1.1 varnish', +1642 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:13:33 GMT', +1642 silly registry.get 'cache-control': 'max-age=60', +1642 silly registry.get etag: '"64YG0KD6CNHI7FUB33O0JW3G2"', +1642 silly registry.get 'x-served-by': 'cache-dfw1834-DFW', +1642 silly registry.get 'x-cache': 'HIT', +1642 silly registry.get 'x-cache-hits': '3', +1642 silly registry.get 'x-timer': 'S1411067667.013647,VS0,VE0', +1642 silly registry.get vary: 'Accept', +1642 silly registry.get 'content-length': '0', +1642 silly registry.get 'keep-alive': 'timeout=10, max=42', +1642 silly registry.get connection: 'Keep-Alive' } ] +1643 verbose etag https://registry.npmjs.org/commander from cache +1644 http 304 https://registry.npmjs.org/colors +1645 silly registry.get cb [ 304, +1645 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1645 silly registry.get server: 'Apache', +1645 silly registry.get via: '1.1 varnish', +1645 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1645 silly registry.get 'cache-control': 'max-age=60', +1645 silly registry.get etag: '"2ZHMVF9GYTMTHHRFKFO52VJA4"', +1645 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1645 silly registry.get 'x-cache': 'HIT', +1645 silly registry.get 'x-cache-hits': '1', +1645 silly registry.get 'x-timer': 'S1411067667.038052,VS0,VE0', +1645 silly registry.get vary: 'Accept', +1645 silly registry.get 'content-length': '0', +1645 silly registry.get 'keep-alive': 'timeout=10, max=30', +1645 silly registry.get connection: 'Keep-Alive' } ] +1646 verbose etag https://registry.npmjs.org/colors from cache +1647 http 304 https://registry.npmjs.org/marked +1648 silly registry.get cb [ 304, +1648 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +1648 silly registry.get server: 'Apache', +1648 silly registry.get via: '1.1 varnish', +1648 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1648 silly registry.get 'cache-control': 'max-age=60', +1648 silly registry.get etag: '"4I97OJXDD8U7A3QYVBSGNCVXV"', +1648 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +1648 silly registry.get 'x-cache': 'HIT', +1648 silly registry.get 'x-cache-hits': '1', +1648 silly registry.get 'x-timer': 'S1411067666.843848,VS0,VE189', +1648 silly registry.get vary: 'Accept', +1648 silly registry.get 'content-length': '0', +1648 silly registry.get 'keep-alive': 'timeout=10, max=43', +1648 silly registry.get connection: 'Keep-Alive' } ] +1649 verbose etag https://registry.npmjs.org/marked from cache +1650 http 304 https://registry.npmjs.org/dateformat +1651 silly registry.get cb [ 304, +1651 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1651 silly registry.get server: 'Apache', +1651 silly registry.get via: '1.1 varnish', +1651 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1651 silly registry.get 'cache-control': 'max-age=60', +1651 silly registry.get etag: '"4D6Y46B2EGQ8PN6W3CYO08WU5"', +1651 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1651 silly registry.get 'x-cache': 'HIT', +1651 silly registry.get 'x-cache-hits': '1', +1651 silly registry.get 'x-timer': 'S1411067667.062657,VS0,VE0', +1651 silly registry.get vary: 'Accept', +1651 silly registry.get 'content-length': '0', +1651 silly registry.get 'keep-alive': 'timeout=10, max=29', +1651 silly registry.get connection: 'Keep-Alive' } ] +1652 verbose etag https://registry.npmjs.org/dateformat from cache +1653 http 304 https://registry.npmjs.org/findup-sync +1654 silly registry.get cb [ 304, +1654 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1654 silly registry.get server: 'Apache', +1654 silly registry.get via: '1.1 varnish', +1654 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1654 silly registry.get 'cache-control': 'max-age=60', +1654 silly registry.get etag: '"2777FKVK8MSMAY1RAAQT5ZRUS"', +1654 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1654 silly registry.get 'x-cache': 'HIT', +1654 silly registry.get 'x-cache-hits': '1', +1654 silly registry.get 'x-timer': 'S1411067667.083927,VS0,VE0', +1654 silly registry.get vary: 'Accept', +1654 silly registry.get 'content-length': '0', +1654 silly registry.get 'keep-alive': 'timeout=10, max=28', +1654 silly registry.get connection: 'Keep-Alive' } ] +1655 verbose etag https://registry.npmjs.org/findup-sync from cache +1656 http 304 https://registry.npmjs.org/coffee-script +1657 silly registry.get cb [ 304, +1657 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1657 silly registry.get server: 'Apache', +1657 silly registry.get via: '1.1 varnish', +1657 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1657 silly registry.get 'cache-control': 'max-age=60', +1657 silly registry.get etag: '"2IGQ76IA45TGG63FC3G4GKRH9"', +1657 silly registry.get 'x-served-by': 'cache-dfw1834-DFW', +1657 silly registry.get 'x-cache': 'HIT', +1657 silly registry.get 'x-cache-hits': '1', +1657 silly registry.get 'x-timer': 'S1411067667.078656,VS0,VE0', +1657 silly registry.get vary: 'Accept', +1657 silly registry.get 'content-length': '0', +1657 silly registry.get 'keep-alive': 'timeout=10, max=41', +1657 silly registry.get connection: 'Keep-Alive' } ] +1658 verbose etag https://registry.npmjs.org/coffee-script from cache +1659 http 304 https://registry.npmjs.org/taffydb +1660 silly registry.get cb [ 304, +1660 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +1660 silly registry.get server: 'Apache', +1660 silly registry.get via: '1.1 varnish', +1660 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1660 silly registry.get 'cache-control': 'max-age=60', +1660 silly registry.get etag: '"3F6XX1ZS1FG8UF8ZAZYC1W52"', +1660 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +1660 silly registry.get 'x-cache': 'MISS', +1660 silly registry.get 'x-cache-hits': '0', +1660 silly registry.get 'x-timer': 'S1411067666.918933,VS0,VE186', +1660 silly registry.get vary: 'Accept', +1660 silly registry.get 'content-length': '0', +1660 silly registry.get 'keep-alive': 'timeout=10, max=41', +1660 silly registry.get connection: 'Keep-Alive' } ] +1661 verbose etag https://registry.npmjs.org/taffydb from cache +1662 verbose cache add [ 'taffydb', +1662 verbose cache add 'https://github.com/hegemonic/taffydb/tarball/master' ] +1663 verbose cache add name="taffydb" spec="https://github.com/hegemonic/taffydb/tarball/master" args=["taffydb","https://github.com/hegemonic/taffydb/tarball/master"] +1664 verbose parsed url { protocol: 'https:', +1664 verbose parsed url slashes: true, +1664 verbose parsed url auth: null, +1664 verbose parsed url host: 'github.com', +1664 verbose parsed url port: null, +1664 verbose parsed url hostname: 'github.com', +1664 verbose parsed url hash: null, +1664 verbose parsed url search: null, +1664 verbose parsed url query: null, +1664 verbose parsed url pathname: '/hegemonic/taffydb/tarball/master', +1664 verbose parsed url path: '/hegemonic/taffydb/tarball/master', +1664 verbose parsed url href: 'https://github.com/hegemonic/taffydb/tarball/master' } +1665 silly lockFile b85c942d-hegemonic-taffydb-tarball-master https://github.com/hegemonic/taffydb/tarball/master +1666 verbose lock https://github.com/hegemonic/taffydb/tarball/master /root/.npm/b85c942d-hegemonic-taffydb-tarball-master.lock +1667 verbose addRemoteTarball [ 'https://github.com/hegemonic/taffydb/tarball/master', null ] +1668 info retry fetch attempt 1 at 15:14:27 +1669 verbose fetch to= /tmp/npm-17670-yMiqFMg9/github.com/hegemonic/taffydb/tarball/master +1670 http GET https://github.com/hegemonic/taffydb/tarball/master +1671 http 304 https://registry.npmjs.org/requizzle +1672 silly registry.get cb [ 304, +1672 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:26 GMT', +1672 silly registry.get server: 'Apache', +1672 silly registry.get via: '1.1 varnish', +1672 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1672 silly registry.get 'cache-control': 'max-age=60', +1672 silly registry.get etag: '"3EPFB0YOBIGVZBNW35809TMRO"', +1672 silly registry.get 'x-served-by': 'cache-dfw1826-DFW', +1672 silly registry.get 'x-cache': 'HIT', +1672 silly registry.get 'x-cache-hits': '1', +1672 silly registry.get 'x-timer': 'S1411067666.847099,VS0,VE263', +1672 silly registry.get vary: 'Accept', +1672 silly registry.get 'content-length': '0', +1672 silly registry.get 'keep-alive': 'timeout=10, max=45', +1672 silly registry.get connection: 'Keep-Alive' } ] +1673 verbose etag https://registry.npmjs.org/requizzle from cache +1674 verbose registry.get https://registry.npmjs.org/underscore not expired, no request +1675 http 304 https://registry.npmjs.org/eventemitter2 +1676 silly registry.get cb [ 304, +1676 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1676 silly registry.get server: 'Apache', +1676 silly registry.get via: '1.1 varnish', +1676 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1676 silly registry.get 'cache-control': 'max-age=60', +1676 silly registry.get etag: '"9NNE2QWKGE8H8Q4T5FXOY4L3P"', +1676 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +1676 silly registry.get 'x-cache': 'HIT', +1676 silly registry.get 'x-cache-hits': '1', +1676 silly registry.get 'x-timer': 'S1411067667.096548,VS0,VE41', +1676 silly registry.get vary: 'Accept', +1676 silly registry.get 'content-length': '0', +1676 silly registry.get 'keep-alive': 'timeout=10, max=42', +1676 silly registry.get connection: 'Keep-Alive' } ] +1677 verbose etag https://registry.npmjs.org/eventemitter2 from cache +1678 http 304 https://registry.npmjs.org/glob +1679 silly registry.get cb [ 304, +1679 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1679 silly registry.get server: 'Apache', +1679 silly registry.get via: '1.1 varnish', +1679 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1679 silly registry.get 'cache-control': 'max-age=60', +1679 silly registry.get etag: '"9GMKCNKBK5IQ307969W8CTPJB"', +1679 silly registry.get 'x-served-by': 'cache-dfw1834-DFW', +1679 silly registry.get 'x-cache': 'HIT', +1679 silly registry.get 'x-cache-hits': '1', +1679 silly registry.get 'x-timer': 'S1411067667.138639,VS0,VE0', +1679 silly registry.get vary: 'Accept', +1679 silly registry.get 'content-length': '0', +1679 silly registry.get 'keep-alive': 'timeout=10, max=40', +1679 silly registry.get connection: 'Keep-Alive' } ] +1680 verbose etag https://registry.npmjs.org/glob from cache +1681 http 304 https://registry.npmjs.org/hooker +1682 silly registry.get cb [ 304, +1682 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1682 silly registry.get server: 'Apache', +1682 silly registry.get via: '1.1 varnish', +1682 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1682 silly registry.get 'cache-control': 'max-age=60', +1682 silly registry.get etag: '"6NRZENGO5R2F7KFMMF8H9R0UC"', +1682 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1682 silly registry.get 'x-cache': 'HIT', +1682 silly registry.get 'x-cache-hits': '1', +1682 silly registry.get 'x-timer': 'S1411067667.107797,VS0,VE64', +1682 silly registry.get vary: 'Accept', +1682 silly registry.get 'content-length': '0', +1682 silly registry.get 'keep-alive': 'timeout=10, max=27', +1682 silly registry.get connection: 'Keep-Alive' } ] +1683 verbose etag https://registry.npmjs.org/hooker from cache +1684 http 304 https://registry.npmjs.org/minimatch +1685 silly registry.get cb [ 304, +1685 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1685 silly registry.get server: 'Apache', +1685 silly registry.get via: '1.1 varnish', +1685 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:01 GMT', +1685 silly registry.get 'cache-control': 'max-age=60', +1685 silly registry.get etag: '"667Q92RS6N1601AM7ZZ1NERE8"', +1685 silly registry.get 'x-served-by': 'cache-dfw1826-DFW', +1685 silly registry.get 'x-cache': 'HIT', +1685 silly registry.get 'x-cache-hits': '3', +1685 silly registry.get 'x-timer': 'S1411067667.174569,VS0,VE0', +1685 silly registry.get vary: 'Accept', +1685 silly registry.get 'content-length': '0', +1685 silly registry.get 'keep-alive': 'timeout=10, max=44', +1685 silly registry.get connection: 'Keep-Alive' } ] +1686 verbose etag https://registry.npmjs.org/minimatch from cache +1687 http 304 https://registry.npmjs.org/lodash +1688 silly registry.get cb [ 304, +1688 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1688 silly registry.get server: 'Apache', +1688 silly registry.get via: '1.1 varnish', +1688 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:13:55 GMT', +1688 silly registry.get 'cache-control': 'max-age=60', +1688 silly registry.get etag: '"D4I8Y7O3OF15X88NHWU47Q2H"', +1688 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1688 silly registry.get 'x-cache': 'HIT', +1688 silly registry.get 'x-cache-hits': '2', +1688 silly registry.get 'x-timer': 'S1411067667.192977,VS0,VE0', +1688 silly registry.get vary: 'Accept', +1688 silly registry.get 'content-length': '0', +1688 silly registry.get 'keep-alive': 'timeout=10, max=26', +1688 silly registry.get connection: 'Keep-Alive' } ] +1689 verbose etag https://registry.npmjs.org/lodash from cache +1690 http 304 https://registry.npmjs.org/nopt +1691 silly registry.get cb [ 304, +1691 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1691 silly registry.get server: 'Apache', +1691 silly registry.get via: '1.1 varnish', +1691 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:13:41 GMT', +1691 silly registry.get 'cache-control': 'max-age=60', +1691 silly registry.get etag: '"6CCBTH44V99TMQVK8E45ICBN7"', +1691 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +1691 silly registry.get 'x-cache': 'HIT', +1691 silly registry.get 'x-cache-hits': '2', +1691 silly registry.get 'x-timer': 'S1411067667.198316,VS0,VE0', +1691 silly registry.get vary: 'Accept', +1691 silly registry.get 'content-length': '0', +1691 silly registry.get 'keep-alive': 'timeout=10, max=41', +1691 silly registry.get connection: 'Keep-Alive' } ] +1692 verbose etag https://registry.npmjs.org/nopt from cache +1693 http 304 https://registry.npmjs.org/rimraf +1694 silly registry.get cb [ 304, +1694 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1694 silly registry.get server: 'Apache', +1694 silly registry.get via: '1.1 varnish', +1694 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:22 GMT', +1694 silly registry.get 'cache-control': 'max-age=60', +1694 silly registry.get etag: '"31YUZD1DFCDSQ0QSBXMA8KMKQ"', +1694 silly registry.get 'x-served-by': 'cache-dfw1834-DFW', +1694 silly registry.get 'x-cache': 'HIT', +1694 silly registry.get 'x-cache-hits': '2', +1694 silly registry.get 'x-timer': 'S1411067667.200931,VS0,VE0', +1694 silly registry.get vary: 'Accept', +1694 silly registry.get 'content-length': '0', +1694 silly registry.get 'keep-alive': 'timeout=10, max=39', +1694 silly registry.get connection: 'Keep-Alive' } ] +1695 verbose etag https://registry.npmjs.org/rimraf from cache +1696 http 304 https://registry.npmjs.org/underscore.string +1697 silly registry.get cb [ 304, +1697 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1697 silly registry.get server: 'Apache', +1697 silly registry.get via: '1.1 varnish', +1697 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:06 GMT', +1697 silly registry.get 'cache-control': 'max-age=60', +1697 silly registry.get etag: '"EVFRL68B0019ADNNX93XOZLXX"', +1697 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1697 silly registry.get 'x-cache': 'HIT', +1697 silly registry.get 'x-cache-hits': '2', +1697 silly registry.get 'x-timer': 'S1411067667.219360,VS0,VE0', +1697 silly registry.get vary: 'Accept', +1697 silly registry.get 'content-length': '0', +1697 silly registry.get 'keep-alive': 'timeout=10, max=25', +1697 silly registry.get connection: 'Keep-Alive' } ] +1698 verbose etag https://registry.npmjs.org/underscore.string from cache +1699 http 304 https://registry.npmjs.org/iconv-lite +1700 silly registry.get cb [ 304, +1700 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1700 silly registry.get server: 'Apache', +1700 silly registry.get via: '1.1 varnish', +1700 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1700 silly registry.get 'cache-control': 'max-age=60', +1700 silly registry.get etag: '"71FTU0L5QCW72MPRO4XK63O38"', +1700 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +1700 silly registry.get 'x-cache': 'HIT', +1700 silly registry.get 'x-cache-hits': '1', +1700 silly registry.get 'x-timer': 'S1411067667.164967,VS0,VE40', +1700 silly registry.get vary: 'Accept', +1700 silly registry.get 'content-length': '0', +1700 silly registry.get 'keep-alive': 'timeout=10, max=40', +1700 silly registry.get connection: 'Keep-Alive' } ] +1701 verbose etag https://registry.npmjs.org/iconv-lite from cache +1702 http 304 https://registry.npmjs.org/which +1703 silly registry.get cb [ 304, +1703 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1703 silly registry.get server: 'Apache', +1703 silly registry.get via: '1.1 varnish', +1703 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1703 silly registry.get 'cache-control': 'max-age=60', +1703 silly registry.get etag: '"V2MIU40L4XLGREBQDUE5E170"', +1703 silly registry.get 'x-served-by': 'cache-dfw1826-DFW', +1703 silly registry.get 'x-cache': 'HIT', +1703 silly registry.get 'x-cache-hits': '1', +1703 silly registry.get 'x-timer': 'S1411067667.241869,VS0,VE0', +1703 silly registry.get vary: 'Accept', +1703 silly registry.get 'content-length': '0', +1703 silly registry.get 'keep-alive': 'timeout=10, max=43', +1703 silly registry.get connection: 'Keep-Alive' } ] +1704 verbose etag https://registry.npmjs.org/which from cache +1705 http 304 https://registry.npmjs.org/js-yaml +1706 silly registry.get cb [ 304, +1706 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1706 silly registry.get server: 'Apache', +1706 silly registry.get via: '1.1 varnish', +1706 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:03 GMT', +1706 silly registry.get 'cache-control': 'max-age=60', +1706 silly registry.get etag: '"A091AY9YCCHWFD29RODQSZLV6"', +1706 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +1706 silly registry.get 'x-cache': 'HIT', +1706 silly registry.get 'x-cache-hits': '2', +1706 silly registry.get 'x-timer': 'S1411067667.257859,VS0,VE0', +1706 silly registry.get vary: 'Accept', +1706 silly registry.get 'content-length': '0', +1706 silly registry.get 'keep-alive': 'timeout=10, max=40', +1706 silly registry.get connection: 'Keep-Alive' } ] +1707 verbose etag https://registry.npmjs.org/js-yaml from cache +1708 http 304 https://registry.npmjs.org/exit +1709 silly registry.get cb [ 304, +1709 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1709 silly registry.get server: 'Apache', +1709 silly registry.get via: '1.1 varnish', +1709 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1709 silly registry.get 'cache-control': 'max-age=60', +1709 silly registry.get etag: '"3FP0DV35EBACX6J5JMM87J57V"', +1709 silly registry.get 'x-served-by': 'cache-dfw1834-DFW', +1709 silly registry.get 'x-cache': 'HIT', +1709 silly registry.get 'x-cache-hits': '1', +1709 silly registry.get 'x-timer': 'S1411067667.261033,VS0,VE0', +1709 silly registry.get vary: 'Accept', +1709 silly registry.get 'content-length': '0', +1709 silly registry.get 'keep-alive': 'timeout=10, max=38', +1709 silly registry.get connection: 'Keep-Alive' } ] +1710 verbose etag https://registry.npmjs.org/exit from cache +1711 http 304 https://registry.npmjs.org/grunt-legacy-util +1712 silly registry.get cb [ 304, +1712 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1712 silly registry.get server: 'Apache', +1712 silly registry.get via: '1.1 varnish', +1712 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1712 silly registry.get 'cache-control': 'max-age=60', +1712 silly registry.get etag: '"BY99KBK78MQ6K31QKDY8BK8HX"', +1712 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +1712 silly registry.get 'x-cache': 'HIT', +1712 silly registry.get 'x-cache-hits': '1', +1712 silly registry.get 'x-timer': 'S1411067667.267427,VS0,VE0', +1712 silly registry.get vary: 'Accept', +1712 silly registry.get 'content-length': '0', +1712 silly registry.get 'keep-alive': 'timeout=10, max=39', +1712 silly registry.get connection: 'Keep-Alive' } ] +1713 verbose etag https://registry.npmjs.org/grunt-legacy-util from cache +1714 http 304 https://registry.npmjs.org/grunt-legacy-log +1715 silly registry.get cb [ 304, +1715 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1715 silly registry.get server: 'Apache', +1715 silly registry.get via: '1.1 varnish', +1715 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1715 silly registry.get 'cache-control': 'max-age=60', +1715 silly registry.get etag: '"47MXERUQDY4DRT31NZCWY43IP"', +1715 silly registry.get 'x-served-by': 'cache-dfw1826-DFW', +1715 silly registry.get 'x-cache': 'HIT', +1715 silly registry.get 'x-cache-hits': '1', +1715 silly registry.get 'x-timer': 'S1411067667.302956,VS0,VE0', +1715 silly registry.get vary: 'Accept', +1715 silly registry.get 'content-length': '0', +1715 silly registry.get 'keep-alive': 'timeout=10, max=42', +1715 silly registry.get connection: 'Keep-Alive' } ] +1716 verbose etag https://registry.npmjs.org/grunt-legacy-log from cache +1717 http 304 https://registry.npmjs.org/ibrik +1718 silly registry.get cb [ 304, +1718 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1718 silly registry.get server: 'Apache', +1718 silly registry.get via: '1.1 varnish', +1718 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1718 silly registry.get 'cache-control': 'max-age=60', +1718 silly registry.get etag: '"95ZG9BVHTK8SRNRBBUM6MRJR4"', +1718 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +1718 silly registry.get 'x-cache': 'HIT', +1718 silly registry.get 'x-cache-hits': '1', +1718 silly registry.get 'x-timer': 'S1411067667.323997,VS0,VE0', +1718 silly registry.get vary: 'Accept', +1718 silly registry.get 'content-length': '0', +1718 silly registry.get 'keep-alive': 'timeout=10, max=39', +1718 silly registry.get connection: 'Keep-Alive' } ] +1719 verbose etag https://registry.npmjs.org/ibrik from cache +1720 http 304 https://registry.npmjs.org/minimatch +1721 silly registry.get cb [ 304, +1721 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1721 silly registry.get server: 'Apache', +1721 silly registry.get via: '1.1 varnish', +1721 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:23 GMT', +1721 silly registry.get 'cache-control': 'max-age=60', +1721 silly registry.get etag: '"667Q92RS6N1601AM7ZZ1NERE8"', +1721 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +1721 silly registry.get 'x-cache': 'HIT', +1721 silly registry.get 'x-cache-hits': '2', +1721 silly registry.get 'x-timer': 'S1411067667.327312,VS0,VE0', +1721 silly registry.get vary: 'Accept', +1721 silly registry.get 'content-length': '0', +1721 silly registry.get 'keep-alive': 'timeout=10, max=38', +1721 silly registry.get connection: 'Keep-Alive' } ] +1722 verbose etag https://registry.npmjs.org/minimatch from cache +1723 http 304 https://registry.npmjs.org/dateformat +1724 silly registry.get cb [ 304, +1724 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1724 silly registry.get server: 'Apache', +1724 silly registry.get via: '1.1 varnish', +1724 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 18:56:59 GMT', +1724 silly registry.get 'cache-control': 'max-age=60', +1724 silly registry.get etag: '"4D6Y46B2EGQ8PN6W3CYO08WU5"', +1724 silly registry.get 'x-served-by': 'cache-dfw1834-DFW', +1724 silly registry.get 'x-cache': 'HIT', +1724 silly registry.get 'x-cache-hits': '87', +1724 silly registry.get 'x-timer': 'S1411067667.326094,VS0,VE0', +1724 silly registry.get vary: 'Accept', +1724 silly registry.get 'content-length': '0', +1724 silly registry.get 'keep-alive': 'timeout=10, max=37', +1724 silly registry.get connection: 'Keep-Alive' } ] +1725 verbose etag https://registry.npmjs.org/dateformat from cache +1726 http 304 https://registry.npmjs.org/istanbul +1727 silly registry.get cb [ 304, +1727 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1727 silly registry.get server: 'Apache', +1727 silly registry.get via: '1.1 varnish', +1727 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1727 silly registry.get 'cache-control': 'max-age=60', +1727 silly registry.get etag: '"9OVVJCI2CZ5R7EKFT7NRBO5HC"', +1727 silly registry.get 'x-served-by': 'cache-dfw1826-DFW', +1727 silly registry.get 'x-cache': 'HIT', +1727 silly registry.get 'x-cache-hits': '1', +1727 silly registry.get 'x-timer': 'S1411067667.363065,VS0,VE1', +1727 silly registry.get vary: 'Accept', +1727 silly registry.get 'content-length': '0', +1727 silly registry.get 'keep-alive': 'timeout=10, max=41', +1727 silly registry.get connection: 'Keep-Alive' } ] +1728 verbose etag https://registry.npmjs.org/istanbul from cache +1729 http 304 https://registry.npmjs.org/colors +1730 silly registry.get cb [ 304, +1730 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1730 silly registry.get server: 'Apache', +1730 silly registry.get via: '1.1 varnish', +1730 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1730 silly registry.get 'cache-control': 'max-age=60', +1730 silly registry.get etag: '"2ZHMVF9GYTMTHHRFKFO52VJA4"', +1730 silly registry.get 'x-served-by': 'cache-dfw1834-DFW', +1730 silly registry.get 'x-cache': 'HIT', +1730 silly registry.get 'x-cache-hits': '1', +1730 silly registry.get 'x-timer': 'S1411067667.392131,VS0,VE0', +1730 silly registry.get vary: 'Accept', +1730 silly registry.get 'content-length': '0', +1730 silly registry.get 'keep-alive': 'timeout=10, max=36', +1730 silly registry.get connection: 'Keep-Alive' } ] +1731 verbose etag https://registry.npmjs.org/colors from cache +1732 http 304 https://registry.npmjs.org/commander +1733 silly registry.get cb [ 304, +1733 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1733 silly registry.get server: 'Apache', +1733 silly registry.get via: '1.1 varnish', +1733 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:13:50 GMT', +1733 silly registry.get 'cache-control': 'max-age=60', +1733 silly registry.get etag: '"64YG0KD6CNHI7FUB33O0JW3G2"', +1733 silly registry.get 'x-served-by': 'cache-dfw1826-DFW', +1733 silly registry.get 'x-cache': 'HIT', +1733 silly registry.get 'x-cache-hits': '3', +1733 silly registry.get 'x-timer': 'S1411067667.425227,VS0,VE0', +1733 silly registry.get vary: 'Accept', +1733 silly registry.get 'content-length': '0', +1733 silly registry.get 'keep-alive': 'timeout=10, max=40', +1733 silly registry.get connection: 'Keep-Alive' } ] +1734 verbose etag https://registry.npmjs.org/commander from cache +1735 http 304 https://registry.npmjs.org/autoprefixer-core +1736 silly registry.get cb [ 304, +1736 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1736 silly registry.get server: 'Apache', +1736 silly registry.get via: '1.1 varnish', +1736 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1736 silly registry.get 'cache-control': 'max-age=60', +1736 silly registry.get etag: '"8ZPT3HTVDOHSYZMA6F1JQ7HAB"', +1736 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +1736 silly registry.get 'x-cache': 'HIT', +1736 silly registry.get 'x-cache-hits': '1', +1736 silly registry.get 'x-timer': 'S1411067667.389066,VS0,VE45', +1736 silly registry.get vary: 'Accept', +1736 silly registry.get 'content-length': '0', +1736 silly registry.get 'keep-alive': 'timeout=10, max=38', +1736 silly registry.get connection: 'Keep-Alive' } ] +1737 verbose etag https://registry.npmjs.org/autoprefixer-core from cache +1738 http 200 https://github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c +1739 http 304 https://registry.npmjs.org/getobject +1740 silly registry.get cb [ 304, +1740 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1740 silly registry.get server: 'Apache', +1740 silly registry.get via: '1.1 varnish', +1740 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1740 silly registry.get 'cache-control': 'max-age=60', +1740 silly registry.get etag: '"6MUSARQXHFPUKTB7ZUEIX1YXH"', +1740 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1740 silly registry.get 'x-cache': 'HIT', +1740 silly registry.get 'x-cache-hits': '1', +1740 silly registry.get 'x-timer': 'S1411067667.244924,VS0,VE271', +1740 silly registry.get vary: 'Accept', +1740 silly registry.get 'content-length': '0', +1740 silly registry.get 'keep-alive': 'timeout=10, max=24', +1740 silly registry.get connection: 'Keep-Alive' } ] +1741 verbose etag https://registry.npmjs.org/getobject from cache +1742 http 304 https://registry.npmjs.org/read-file-stdin +1743 silly registry.get cb [ 304, +1743 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1743 silly registry.get server: 'Apache', +1743 silly registry.get via: '1.1 varnish', +1743 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1743 silly registry.get 'cache-control': 'max-age=60', +1743 silly registry.get etag: '"1OZ9HF2FR2MOGDGTQZNVQW9MX"', +1743 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1743 silly registry.get 'x-cache': 'MISS', +1743 silly registry.get 'x-cache-hits': '0', +1743 silly registry.get 'x-timer': 'S1411067667.537308,VS0,VE29', +1743 silly registry.get vary: 'Accept', +1743 silly registry.get 'content-length': '0', +1743 silly registry.get 'keep-alive': 'timeout=10, max=23', +1743 silly registry.get connection: 'Keep-Alive' } ] +1744 verbose etag https://registry.npmjs.org/read-file-stdin from cache +1745 http 304 https://registry.npmjs.org/clone-component +1746 silly registry.get cb [ 304, +1746 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1746 silly registry.get server: 'Apache', +1746 silly registry.get via: '1.1 varnish', +1746 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1746 silly registry.get 'cache-control': 'max-age=60', +1746 silly registry.get etag: '"9FXZWVDHKKRFDZ8HFGFAB0V46"', +1746 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +1746 silly registry.get 'x-cache': 'MISS', +1746 silly registry.get 'x-cache-hits': '0', +1746 silly registry.get 'x-timer': 'S1411067667.387373,VS0,VE182', +1746 silly registry.get vary: 'Accept', +1746 silly registry.get 'content-length': '0', +1746 silly registry.get 'keep-alive': 'timeout=10, max=37', +1746 silly registry.get connection: 'Keep-Alive' } ] +1747 verbose etag https://registry.npmjs.org/clone-component from cache +1748 http 304 https://registry.npmjs.org/rework +1749 silly registry.get cb [ 304, +1749 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1749 silly registry.get server: 'Apache', +1749 silly registry.get via: '1.1 varnish', +1749 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1749 silly registry.get 'cache-control': 'max-age=60', +1749 silly registry.get etag: '"3JIX4587FLZOTAAGC2LMTHTHL"', +1749 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1749 silly registry.get 'x-cache': 'MISS', +1749 silly registry.get 'x-cache-hits': '0', +1749 silly registry.get 'x-timer': 'S1411067667.591226,VS0,VE29', +1749 silly registry.get vary: 'Accept', +1749 silly registry.get 'content-length': '0', +1749 silly registry.get 'keep-alive': 'timeout=10, max=22', +1749 silly registry.get connection: 'Keep-Alive' } ] +1750 verbose etag https://registry.npmjs.org/rework from cache +1751 http 304 https://registry.npmjs.org/pad-component +1752 silly registry.get cb [ 304, +1752 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1752 silly registry.get server: 'Apache', +1752 silly registry.get via: '1.1 varnish', +1752 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1752 silly registry.get 'cache-control': 'max-age=60', +1752 silly registry.get etag: '"AT9M0WJLJ95HLOZ5F66GW3X71"', +1752 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +1752 silly registry.get 'x-cache': 'HIT', +1752 silly registry.get 'x-cache-hits': '1', +1752 silly registry.get 'x-timer': 'S1411067667.495484,VS0,VE184', +1752 silly registry.get vary: 'Accept', +1752 silly registry.get 'content-length': '0', +1752 silly registry.get 'keep-alive': 'timeout=10, max=37', +1752 silly registry.get connection: 'Keep-Alive' } ] +1753 verbose etag https://registry.npmjs.org/pad-component from cache +1754 http 304 https://registry.npmjs.org/is-browser +1755 silly registry.get cb [ 304, +1755 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1755 silly registry.get server: 'Apache', +1755 silly registry.get via: '1.1 varnish', +1755 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1755 silly registry.get 'cache-control': 'max-age=60', +1755 silly registry.get etag: '"BDV45H87BRHMOY3WR7420V9AO"', +1755 silly registry.get 'x-served-by': 'cache-dfw1834-DFW', +1755 silly registry.get 'x-cache': 'MISS', +1755 silly registry.get 'x-cache-hits': '0', +1755 silly registry.get 'x-timer': 'S1411067667.452482,VS0,VE232', +1755 silly registry.get vary: 'Accept', +1755 silly registry.get 'content-length': '0', +1755 silly registry.get 'keep-alive': 'timeout=10, max=35', +1755 silly registry.get connection: 'Keep-Alive' } ] +1756 verbose etag https://registry.npmjs.org/is-browser from cache +1757 http 304 https://registry.npmjs.org/rework-color-function +1758 silly registry.get cb [ 304, +1758 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1758 silly registry.get server: 'Apache', +1758 silly registry.get via: '1.1 varnish', +1758 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1758 silly registry.get 'cache-control': 'max-age=60', +1758 silly registry.get etag: '"23Z9QZ2FFXLRFCGSMAJBLS8MY"', +1758 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1758 silly registry.get 'x-cache': 'MISS', +1758 silly registry.get 'x-cache-hits': '0', +1758 silly registry.get 'x-timer': 'S1411067667.644058,VS0,VE63', +1758 silly registry.get vary: 'Accept', +1758 silly registry.get 'content-length': '0', +1758 silly registry.get 'keep-alive': 'timeout=10, max=21', +1758 silly registry.get connection: 'Keep-Alive' } ] +1759 verbose etag https://registry.npmjs.org/rework-color-function from cache +1760 http 304 https://registry.npmjs.org/node-watch +1761 silly registry.get cb [ 304, +1761 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1761 silly registry.get server: 'Apache', +1761 silly registry.get via: '1.1 varnish', +1761 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1761 silly registry.get 'cache-control': 'max-age=60', +1761 silly registry.get etag: '"8403TW7NE0BF4GAXS9O3O908G"', +1761 silly registry.get 'x-served-by': 'cache-dfw1826-DFW', +1761 silly registry.get 'x-cache': 'HIT', +1761 silly registry.get 'x-cache-hits': '1', +1761 silly registry.get 'x-timer': 'S1411067667.485312,VS0,VE206', +1761 silly registry.get vary: 'Accept', +1761 silly registry.get 'content-length': '0', +1761 silly registry.get 'keep-alive': 'timeout=10, max=39', +1761 silly registry.get connection: 'Keep-Alive' } ] +1762 verbose etag https://registry.npmjs.org/node-watch from cache +1763 http 304 https://registry.npmjs.org/rework-hex-alpha +1764 silly registry.get cb [ 304, +1764 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1764 silly registry.get server: 'Apache', +1764 silly registry.get via: '1.1 varnish', +1764 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1764 silly registry.get 'cache-control': 'max-age=60', +1764 silly registry.get etag: '"F5APSW07G01TM6YTBMYXZIO7J"', +1764 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1764 silly registry.get 'x-cache': 'MISS', +1764 silly registry.get 'x-cache-hits': '0', +1764 silly registry.get 'x-timer': 'S1411067667.728434,VS0,VE64', +1764 silly registry.get vary: 'Accept', +1764 silly registry.get 'content-length': '0', +1764 silly registry.get 'keep-alive': 'timeout=10, max=20', +1764 silly registry.get connection: 'Keep-Alive' } ] +1765 verbose etag https://registry.npmjs.org/rework-hex-alpha from cache +1766 http 304 https://registry.npmjs.org/rework-custom-media +1767 silly registry.get cb [ 304, +1767 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1767 silly registry.get server: 'Apache', +1767 silly registry.get via: '1.1 varnish', +1767 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1767 silly registry.get 'cache-control': 'max-age=60', +1767 silly registry.get etag: '"TKFKMF2C8DZJGWIR06U7M3GT"', +1767 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +1767 silly registry.get 'x-cache': 'MISS', +1767 silly registry.get 'x-cache-hits': '0', +1767 silly registry.get 'x-timer': 'S1411067667.741527,VS0,VE66', +1767 silly registry.get vary: 'Accept', +1767 silly registry.get 'content-length': '0', +1767 silly registry.get 'keep-alive': 'timeout=10, max=36', +1767 silly registry.get connection: 'Keep-Alive' } ] +1768 verbose etag https://registry.npmjs.org/rework-custom-media from cache +1769 http 304 https://registry.npmjs.org/rework-font-variant +1770 silly registry.get cb [ 304, +1770 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1770 silly registry.get server: 'Apache', +1770 silly registry.get via: '1.1 varnish', +1770 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1770 silly registry.get 'cache-control': 'max-age=60', +1770 silly registry.get etag: '"V7EKOP4KEZA5NVJV1Z7CORH6"', +1770 silly registry.get 'x-served-by': 'cache-dfw1834-DFW', +1770 silly registry.get 'x-cache': 'MISS', +1770 silly registry.get 'x-cache-hits': '0', +1770 silly registry.get 'x-timer': 'S1411067667.744511,VS0,VE64', +1770 silly registry.get vary: 'Accept', +1770 silly registry.get 'content-length': '0', +1770 silly registry.get 'keep-alive': 'timeout=10, max=34', +1770 silly registry.get connection: 'Keep-Alive' } ] +1771 verbose etag https://registry.npmjs.org/rework-font-variant from cache +1772 http 304 https://registry.npmjs.org/rework-import +1773 silly registry.get cb [ 304, +1773 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1773 silly registry.get server: 'Apache', +1773 silly registry.get via: '1.1 varnish', +1773 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1773 silly registry.get 'cache-control': 'max-age=60', +1773 silly registry.get etag: '"4JMA3XGBW3EXQ3M5UD1OSIOAE"', +1773 silly registry.get 'x-served-by': 'cache-dfw1826-DFW', +1773 silly registry.get 'x-cache': 'MISS', +1773 silly registry.get 'x-cache-hits': '0', +1773 silly registry.get 'x-timer': 'S1411067667.756600,VS0,VE83', +1773 silly registry.get vary: 'Accept', +1773 silly registry.get 'content-length': '0', +1773 silly registry.get 'keep-alive': 'timeout=10, max=38', +1773 silly registry.get connection: 'Keep-Alive' } ] +1774 verbose etag https://registry.npmjs.org/rework-import from cache +1775 http 304 https://registry.npmjs.org/rework-calc +1776 silly registry.get cb [ 304, +1776 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1776 silly registry.get server: 'Apache', +1776 silly registry.get via: '1.1 varnish', +1776 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1776 silly registry.get 'cache-control': 'max-age=60', +1776 silly registry.get etag: '"7ZG2BQ7IAYTJAP7NM127K8E4"', +1776 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +1776 silly registry.get 'x-cache': 'MISS', +1776 silly registry.get 'x-cache-hits': '0', +1776 silly registry.get 'x-timer': 'S1411067667.632519,VS0,VE262', +1776 silly registry.get vary: 'Accept', +1776 silly registry.get 'content-length': '0', +1776 silly registry.get 'keep-alive': 'timeout=10, max=36', +1776 silly registry.get connection: 'Keep-Alive' } ] +1777 verbose etag https://registry.npmjs.org/rework-calc from cache +1778 http 304 https://registry.npmjs.org/rework-rebeccapurple +1779 silly registry.get cb [ 304, +1779 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1779 silly registry.get server: 'Apache', +1779 silly registry.get via: '1.1 varnish', +1779 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1779 silly registry.get 'cache-control': 'max-age=60', +1779 silly registry.get etag: '"ERLZS9DRG3W13WMRCUXYFFR1P"', +1779 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1779 silly registry.get 'x-cache': 'MISS', +1779 silly registry.get 'x-cache-hits': '0', +1779 silly registry.get 'x-timer': 'S1411067667.813459,VS0,VE133', +1779 silly registry.get vary: 'Accept', +1779 silly registry.get 'content-length': '0', +1779 silly registry.get 'keep-alive': 'timeout=10, max=19', +1779 silly registry.get connection: 'Keep-Alive' } ] +1780 verbose etag https://registry.npmjs.org/rework-rebeccapurple from cache +1781 http 304 https://registry.npmjs.org/accepts +1782 silly registry.get cb [ 304, +1782 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1782 silly registry.get server: 'Apache', +1782 silly registry.get via: '1.1 varnish', +1782 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1782 silly registry.get 'cache-control': 'max-age=60', +1782 silly registry.get etag: '"ELNSNA1PHQ6DL1EBGZQ3P7TCJ"', +1782 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1782 silly registry.get 'x-cache': 'HIT', +1782 silly registry.get 'x-cache-hits': '1', +1782 silly registry.get 'x-timer': 'S1411067667.972372,VS0,VE0', +1782 silly registry.get vary: 'Accept', +1782 silly registry.get 'content-length': '0', +1782 silly registry.get 'keep-alive': 'timeout=10, max=18', +1782 silly registry.get connection: 'Keep-Alive' } ] +1783 verbose etag https://registry.npmjs.org/accepts from cache +1784 http 304 https://registry.npmjs.org/to-space-case +1785 silly registry.get cb [ 304, +1785 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1785 silly registry.get server: 'Apache', +1785 silly registry.get via: '1.1 varnish', +1785 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1785 silly registry.get 'cache-control': 'max-age=60', +1785 silly registry.get etag: '"53AG3XNG07DBBQHIXLQ5YIWOR"', +1785 silly registry.get 'x-served-by': 'cache-dfw1826-DFW', +1785 silly registry.get 'x-cache': 'MISS', +1785 silly registry.get 'x-cache-hits': '0', +1785 silly registry.get 'x-timer': 'S1411067667.900487,VS0,VE63', +1785 silly registry.get vary: 'Accept', +1785 silly registry.get 'content-length': '0', +1785 silly registry.get 'keep-alive': 'timeout=10, max=37', +1785 silly registry.get connection: 'Keep-Alive' } ] +1786 verbose etag https://registry.npmjs.org/to-space-case from cache +1787 http 304 https://registry.npmjs.org/debug +1788 silly registry.get cb [ 304, +1788 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1788 silly registry.get server: 'Apache', +1788 silly registry.get via: '1.1 varnish', +1788 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1788 silly registry.get 'cache-control': 'max-age=60', +1788 silly registry.get etag: '"X0H4NVRP00Z4L2PSZKJ137OA"', +1788 silly registry.get 'x-served-by': 'cache-dfw1826-DFW', +1788 silly registry.get 'x-cache': 'HIT', +1788 silly registry.get 'x-cache-hits': '1', +1788 silly registry.get 'x-timer': 'S1411067668.028609,VS0,VE0', +1788 silly registry.get vary: 'Accept', +1788 silly registry.get 'content-length': '0', +1788 silly registry.get 'keep-alive': 'timeout=10, max=36', +1788 silly registry.get connection: 'Keep-Alive' } ] +1789 verbose etag https://registry.npmjs.org/debug from cache +1790 http 304 https://registry.npmjs.org/write-file-stdout +1791 silly registry.get cb [ 304, +1791 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1791 silly registry.get server: 'Apache', +1791 silly registry.get via: '1.1 varnish', +1791 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1791 silly registry.get 'cache-control': 'max-age=60', +1791 silly registry.get etag: '"237EKF41RILH8X475X2NMSD5B"', +1791 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +1791 silly registry.get 'x-cache': 'MISS', +1791 silly registry.get 'x-cache-hits': '0', +1791 silly registry.get 'x-timer': 'S1411067667.966500,VS0,VE64', +1791 silly registry.get vary: 'Accept', +1791 silly registry.get 'content-length': '0', +1791 silly registry.get 'keep-alive': 'timeout=10, max=35', +1791 silly registry.get connection: 'Keep-Alive' } ] +1792 verbose etag https://registry.npmjs.org/write-file-stdout from cache +1793 http 304 https://registry.npmjs.org/cookie-signature +1794 silly registry.get cb [ 304, +1794 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1794 silly registry.get server: 'Apache', +1794 silly registry.get via: '1.1 varnish', +1794 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1794 silly registry.get 'cache-control': 'max-age=60', +1794 silly registry.get etag: '"9HWN5U2NNH9Z9EXH3WET3QQLS"', +1794 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1794 silly registry.get 'x-cache': 'HIT', +1794 silly registry.get 'x-cache-hits': '1', +1794 silly registry.get 'x-timer': 'S1411067668.001150,VS0,VE65', +1794 silly registry.get vary: 'Accept', +1794 silly registry.get 'content-length': '0', +1794 silly registry.get 'keep-alive': 'timeout=10, max=17', +1794 silly registry.get connection: 'Keep-Alive' } ] +1795 verbose etag https://registry.npmjs.org/cookie-signature from cache +1796 http 200 https://github.com/hegemonic/taffydb/tarball/master +1797 http 304 https://registry.npmjs.org/to-slug-case +1798 silly registry.get cb [ 304, +1798 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1798 silly registry.get server: 'Apache', +1798 silly registry.get via: '1.1 varnish', +1798 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1798 silly registry.get 'cache-control': 'max-age=60', +1798 silly registry.get etag: '"9VIU39RJESC756G6IV9QEGXY1"', +1798 silly registry.get 'x-served-by': 'cache-dfw1834-DFW', +1798 silly registry.get 'x-cache': 'MISS', +1798 silly registry.get 'x-cache-hits': '0', +1798 silly registry.get 'x-timer': 'S1411067667.870792,VS0,VE191', +1798 silly registry.get vary: 'Accept', +1798 silly registry.get 'content-length': '0', +1798 silly registry.get 'keep-alive': 'timeout=10, max=33', +1798 silly registry.get connection: 'Keep-Alive' } ] +1799 verbose etag https://registry.npmjs.org/to-slug-case from cache +1800 http 304 https://registry.npmjs.org/etag +1801 silly registry.get cb [ 304, +1801 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1801 silly registry.get server: 'Apache', +1801 silly registry.get via: '1.1 varnish', +1801 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:23 GMT', +1801 silly registry.get 'cache-control': 'max-age=60', +1801 silly registry.get etag: '"64EK35902Q25FQ2GK4W2QQAUK"', +1801 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1801 silly registry.get 'x-cache': 'HIT', +1801 silly registry.get 'x-cache-hits': '2', +1801 silly registry.get 'x-timer': 'S1411067668.087589,VS0,VE0', +1801 silly registry.get vary: 'Accept', +1801 silly registry.get 'content-length': '0', +1801 silly registry.get 'keep-alive': 'timeout=10, max=16', +1801 silly registry.get connection: 'Keep-Alive' } ] +1802 verbose etag https://registry.npmjs.org/etag from cache +1803 http 304 https://registry.npmjs.org/depd +1804 silly registry.get cb [ 304, +1804 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1804 silly registry.get server: 'Apache', +1804 silly registry.get via: '1.1 varnish', +1804 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1804 silly registry.get 'cache-control': 'max-age=60', +1804 silly registry.get etag: '"8T9DLEUPVNZ1UV659BU2YG0B0"', +1804 silly registry.get 'x-served-by': 'cache-dfw1826-DFW', +1804 silly registry.get 'x-cache': 'HIT', +1804 silly registry.get 'x-cache-hits': '1', +1804 silly registry.get 'x-timer': 'S1411067668.088818,VS0,VE0', +1804 silly registry.get vary: 'Accept', +1804 silly registry.get 'content-length': '0', +1804 silly registry.get 'keep-alive': 'timeout=10, max=35', +1804 silly registry.get connection: 'Keep-Alive' } ] +1805 verbose etag https://registry.npmjs.org/depd from cache +1806 http 304 https://registry.npmjs.org/fresh +1807 silly registry.get cb [ 304, +1807 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1807 silly registry.get server: 'Apache', +1807 silly registry.get via: '1.1 varnish', +1807 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:23 GMT', +1807 silly registry.get 'cache-control': 'max-age=60', +1807 silly registry.get etag: '"HJGEEPXN225JRJT8SA8QQAD1"', +1807 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1807 silly registry.get 'x-cache': 'HIT', +1807 silly registry.get 'x-cache-hits': '2', +1807 silly registry.get 'x-timer': 'S1411067668.109013,VS0,VE0', +1807 silly registry.get vary: 'Accept', +1807 silly registry.get 'content-length': '0', +1807 silly registry.get 'keep-alive': 'timeout=10, max=15', +1807 silly registry.get connection: 'Keep-Alive' } ] +1808 verbose etag https://registry.npmjs.org/fresh from cache +1809 http 304 https://registry.npmjs.org/escape-html +1810 silly registry.get cb [ 304, +1810 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1810 silly registry.get server: 'Apache', +1810 silly registry.get via: '1.1 varnish', +1810 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1810 silly registry.get 'cache-control': 'max-age=60', +1810 silly registry.get etag: '"4G2P0ALF56SX4Q9ABO1RC1M99"', +1810 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +1810 silly registry.get 'x-cache': 'HIT', +1810 silly registry.get 'x-cache-hits': '1', +1810 silly registry.get 'x-timer': 'S1411067668.093659,VS0,VE0', +1810 silly registry.get vary: 'Accept', +1810 silly registry.get 'content-length': '0', +1810 silly registry.get 'keep-alive': 'timeout=10, max=34', +1810 silly registry.get connection: 'Keep-Alive' } ] +1811 verbose etag https://registry.npmjs.org/escape-html from cache +1812 http 304 https://registry.npmjs.org/rework-vars +1813 silly registry.get cb [ 304, +1813 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:27 GMT', +1813 silly registry.get server: 'Apache', +1813 silly registry.get via: '1.1 varnish', +1813 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1813 silly registry.get 'cache-control': 'max-age=60', +1813 silly registry.get etag: '"A94R2YLPGB5T1NFEEPWDX6ITT"', +1813 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +1813 silly registry.get 'x-cache': 'MISS', +1813 silly registry.get 'x-cache-hits': '0', +1813 silly registry.get 'x-timer': 'S1411067667.868708,VS0,VE253', +1813 silly registry.get vary: 'Accept', +1813 silly registry.get 'content-length': '0', +1813 silly registry.get 'keep-alive': 'timeout=10, max=35', +1813 silly registry.get connection: 'Keep-Alive' } ] +1814 verbose etag https://registry.npmjs.org/rework-vars from cache +1815 http 304 https://registry.npmjs.org/finalhandler +1816 silly registry.get cb [ 304, +1816 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1816 silly registry.get server: 'Apache', +1816 silly registry.get via: '1.1 varnish', +1816 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:21 GMT', +1816 silly registry.get 'cache-control': 'max-age=60', +1816 silly registry.get etag: '"7TAEELCVS48GXUVTTA4BYV1XJ"', +1816 silly registry.get 'x-served-by': 'cache-dfw1834-DFW', +1816 silly registry.get 'x-cache': 'HIT', +1816 silly registry.get 'x-cache-hits': '2', +1816 silly registry.get 'x-timer': 'S1411067668.125517,VS0,VE0', +1816 silly registry.get vary: 'Accept', +1816 silly registry.get 'content-length': '0', +1816 silly registry.get 'keep-alive': 'timeout=10, max=32', +1816 silly registry.get connection: 'Keep-Alive' } ] +1817 verbose etag https://registry.npmjs.org/finalhandler from cache +1818 http 304 https://registry.npmjs.org/media-typer +1819 silly registry.get cb [ 304, +1819 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1819 silly registry.get server: 'Apache', +1819 silly registry.get via: '1.1 varnish', +1819 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1819 silly registry.get 'cache-control': 'max-age=60', +1819 silly registry.get etag: '"A84XZ4O9ENQU3AD5YUYUJ10SK"', +1819 silly registry.get 'x-served-by': 'cache-dfw1826-DFW', +1819 silly registry.get 'x-cache': 'HIT', +1819 silly registry.get 'x-cache-hits': '1', +1819 silly registry.get 'x-timer': 'S1411067668.149050,VS0,VE0', +1819 silly registry.get vary: 'Accept', +1819 silly registry.get 'content-length': '0', +1819 silly registry.get 'keep-alive': 'timeout=10, max=34', +1819 silly registry.get connection: 'Keep-Alive' } ] +1820 verbose etag https://registry.npmjs.org/media-typer from cache +1821 http 304 https://registry.npmjs.org/on-finished +1822 silly registry.get cb [ 304, +1822 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1822 silly registry.get server: 'Apache', +1822 silly registry.get via: '1.1 varnish', +1822 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1822 silly registry.get 'cache-control': 'max-age=60', +1822 silly registry.get etag: '"TJSHDORY4W4OFL409Y2422TD"', +1822 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +1822 silly registry.get 'x-cache': 'HIT', +1822 silly registry.get 'x-cache-hits': '1', +1822 silly registry.get 'x-timer': 'S1411067668.154045,VS0,VE0', +1822 silly registry.get vary: 'Accept', +1822 silly registry.get 'content-length': '0', +1822 silly registry.get 'keep-alive': 'timeout=10, max=33', +1822 silly registry.get connection: 'Keep-Alive' } ] +1823 verbose etag https://registry.npmjs.org/on-finished from cache +1824 http 304 https://registry.npmjs.org/methods +1825 silly registry.get cb [ 304, +1825 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1825 silly registry.get server: 'Apache', +1825 silly registry.get via: '1.1 varnish', +1825 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1825 silly registry.get 'cache-control': 'max-age=60', +1825 silly registry.get etag: '"4BCT47GG6VS8ZP1QYAS8AKQ9W"', +1825 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1825 silly registry.get 'x-cache': 'HIT', +1825 silly registry.get 'x-cache-hits': '1', +1825 silly registry.get 'x-timer': 'S1411067668.131466,VS0,VE65', +1825 silly registry.get vary: 'Accept', +1825 silly registry.get 'content-length': '0', +1825 silly registry.get 'keep-alive': 'timeout=10, max=14', +1825 silly registry.get connection: 'Keep-Alive' } ] +1826 verbose etag https://registry.npmjs.org/methods from cache +1827 http 304 https://registry.npmjs.org/parseurl +1828 silly registry.get cb [ 304, +1828 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1828 silly registry.get server: 'Apache', +1828 silly registry.get via: '1.1 varnish', +1828 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 18:49:37 GMT', +1828 silly registry.get 'cache-control': 'max-age=60', +1828 silly registry.get etag: '"7OTQ1DASF9QV0K8V0NYJE9HP3"', +1828 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +1828 silly registry.get 'x-cache': 'HIT', +1828 silly registry.get 'x-cache-hits': '89', +1828 silly registry.get 'x-timer': 'S1411067668.185698,VS0,VE0', +1828 silly registry.get vary: 'Accept', +1828 silly registry.get 'content-length': '0', +1828 silly registry.get 'keep-alive': 'timeout=10, max=34', +1828 silly registry.get connection: 'Keep-Alive' } ] +1829 verbose etag https://registry.npmjs.org/parseurl from cache +1830 http 304 https://registry.npmjs.org/qs +1831 silly registry.get cb [ 304, +1831 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1831 silly registry.get server: 'Apache', +1831 silly registry.get via: '1.1 varnish', +1831 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 18:58:21 GMT', +1831 silly registry.get 'cache-control': 'max-age=60', +1831 silly registry.get etag: '"8SEIQJWT2RMN54Q374IC594T0"', +1831 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1831 silly registry.get 'x-cache': 'HIT', +1831 silly registry.get 'x-cache-hits': '234', +1831 silly registry.get 'x-timer': 'S1411067668.216967,VS0,VE0', +1831 silly registry.get vary: 'Accept', +1831 silly registry.get 'content-length': '0', +1831 silly registry.get 'keep-alive': 'timeout=10, max=13', +1831 silly registry.get connection: 'Keep-Alive' } ] +1832 verbose etag https://registry.npmjs.org/qs from cache +1833 http 304 https://registry.npmjs.org/proxy-addr +1834 silly registry.get cb [ 304, +1834 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1834 silly registry.get server: 'Apache', +1834 silly registry.get via: '1.1 varnish', +1834 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1834 silly registry.get 'cache-control': 'max-age=60', +1834 silly registry.get etag: '"9YLW1E0GZQM8CAN5XS8FLBJ1I"', +1834 silly registry.get 'x-served-by': 'cache-dfw1826-DFW', +1834 silly registry.get 'x-cache': 'HIT', +1834 silly registry.get 'x-cache-hits': '1', +1834 silly registry.get 'x-timer': 'S1411067668.208809,VS0,VE0', +1834 silly registry.get vary: 'Accept', +1834 silly registry.get 'content-length': '0', +1834 silly registry.get 'keep-alive': 'timeout=10, max=33', +1834 silly registry.get connection: 'Keep-Alive' } ] +1835 verbose etag https://registry.npmjs.org/proxy-addr from cache +1836 http 304 https://registry.npmjs.org/range-parser +1837 silly registry.get cb [ 304, +1837 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1837 silly registry.get server: 'Apache', +1837 silly registry.get via: '1.1 varnish', +1837 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1837 silly registry.get 'cache-control': 'max-age=60', +1837 silly registry.get etag: '"2M3421NBY3DYCB3V1HKCGQXRT"', +1837 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +1837 silly registry.get 'x-cache': 'HIT', +1837 silly registry.get 'x-cache-hits': '1', +1837 silly registry.get 'x-timer': 'S1411067668.214974,VS0,VE0', +1837 silly registry.get vary: 'Accept', +1837 silly registry.get 'content-length': '0', +1837 silly registry.get 'keep-alive': 'timeout=10, max=32', +1837 silly registry.get connection: 'Keep-Alive' } ] +1838 verbose etag https://registry.npmjs.org/range-parser from cache +1839 http 304 https://registry.npmjs.org/type-is +1840 silly registry.get cb [ 304, +1840 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1840 silly registry.get server: 'Apache', +1840 silly registry.get via: '1.1 varnish', +1840 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:03 GMT', +1840 silly registry.get 'cache-control': 'max-age=60', +1840 silly registry.get etag: '"29O0KJ1DUNVU0DP2LEKDAAMDI"', +1840 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1840 silly registry.get 'x-cache': 'HIT', +1840 silly registry.get 'x-cache-hits': '2', +1840 silly registry.get 'x-timer': 'S1411067668.238114,VS0,VE0', +1840 silly registry.get vary: 'Accept', +1840 silly registry.get 'content-length': '0', +1840 silly registry.get 'keep-alive': 'timeout=10, max=12', +1840 silly registry.get connection: 'Keep-Alive' } ] +1841 verbose etag https://registry.npmjs.org/type-is from cache +1842 http 304 https://registry.npmjs.org/send +1843 silly registry.get cb [ 304, +1843 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1843 silly registry.get server: 'Apache', +1843 silly registry.get via: '1.1 varnish', +1843 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1843 silly registry.get 'cache-control': 'max-age=60', +1843 silly registry.get etag: '"73B1VUJ40QRDH0J5PVQWE0JI7"', +1843 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +1843 silly registry.get 'x-cache': 'HIT', +1843 silly registry.get 'x-cache-hits': '1', +1843 silly registry.get 'x-timer': 'S1411067668.246099,VS0,VE0', +1843 silly registry.get vary: 'Accept', +1843 silly registry.get 'content-length': '0', +1843 silly registry.get 'keep-alive': 'timeout=10, max=33', +1843 silly registry.get connection: 'Keep-Alive' } ] +1844 verbose etag https://registry.npmjs.org/send from cache +1845 http 304 https://registry.npmjs.org/cookie +1846 silly registry.get cb [ 304, +1846 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1846 silly registry.get server: 'Apache', +1846 silly registry.get via: '1.1 varnish', +1846 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:05 GMT', +1846 silly registry.get 'cache-control': 'max-age=60', +1846 silly registry.get etag: '"ESDBTEE85PYVI0X5XWIZUBGVA"', +1846 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1846 silly registry.get 'x-cache': 'HIT', +1846 silly registry.get 'x-cache-hits': '3', +1846 silly registry.get 'x-timer': 'S1411067668.262571,VS0,VE0', +1846 silly registry.get vary: 'Accept', +1846 silly registry.get 'content-length': '0', +1846 silly registry.get 'keep-alive': 'timeout=10, max=11', +1846 silly registry.get connection: 'Keep-Alive' } ] +1847 verbose etag https://registry.npmjs.org/cookie from cache +1848 http 304 https://registry.npmjs.org/path-to-regexp +1849 silly registry.get cb [ 304, +1849 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1849 silly registry.get server: 'Apache', +1849 silly registry.get via: '1.1 varnish', +1849 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1849 silly registry.get 'cache-control': 'max-age=60', +1849 silly registry.get etag: '"4C29CQHFWZTDNQRAE5HRKD7HM"', +1849 silly registry.get 'x-served-by': 'cache-dfw1834-DFW', +1849 silly registry.get 'x-cache': 'HIT', +1849 silly registry.get 'x-cache-hits': '1', +1849 silly registry.get 'x-timer': 'S1411067668.187369,VS0,VE63', +1849 silly registry.get vary: 'Accept', +1849 silly registry.get 'content-length': '0', +1849 silly registry.get 'keep-alive': 'timeout=10, max=31', +1849 silly registry.get connection: 'Keep-Alive' } ] +1850 verbose etag https://registry.npmjs.org/path-to-regexp from cache +1851 http 304 https://registry.npmjs.org/serve-static +1852 silly registry.get cb [ 304, +1852 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1852 silly registry.get server: 'Apache', +1852 silly registry.get via: '1.1 varnish', +1852 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:13:42 GMT', +1852 silly registry.get 'cache-control': 'max-age=60', +1852 silly registry.get etag: '"6QEO5CGGMZYV8CGD5B7WJ9DPK"', +1852 silly registry.get 'x-served-by': 'cache-dfw1826-DFW', +1852 silly registry.get 'x-cache': 'HIT', +1852 silly registry.get 'x-cache-hits': '2', +1852 silly registry.get 'x-timer': 'S1411067668.270338,VS0,VE0', +1852 silly registry.get vary: 'Accept', +1852 silly registry.get 'content-length': '0', +1852 silly registry.get 'keep-alive': 'timeout=10, max=32', +1852 silly registry.get connection: 'Keep-Alive' } ] +1853 verbose etag https://registry.npmjs.org/serve-static from cache +1854 http 304 https://registry.npmjs.org/utils-merge +1855 silly registry.get cb [ 304, +1855 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1855 silly registry.get server: 'Apache', +1855 silly registry.get via: '1.1 varnish', +1855 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1855 silly registry.get 'cache-control': 'max-age=60', +1855 silly registry.get etag: '"B2A6FDCPPSSHMH9XOGUS29BLY"', +1855 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1855 silly registry.get 'x-cache': 'HIT', +1855 silly registry.get 'x-cache-hits': '1', +1855 silly registry.get 'x-timer': 'S1411067668.288681,VS0,VE0', +1855 silly registry.get vary: 'Accept', +1855 silly registry.get 'content-length': '0', +1855 silly registry.get 'keep-alive': 'timeout=10, max=10', +1855 silly registry.get connection: 'Keep-Alive' } ] +1856 verbose etag https://registry.npmjs.org/utils-merge from cache +1857 http 304 https://registry.npmjs.org/vary +1858 silly registry.get cb [ 304, +1858 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1858 silly registry.get server: 'Apache', +1858 silly registry.get via: '1.1 varnish', +1858 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1858 silly registry.get 'cache-control': 'max-age=60', +1858 silly registry.get etag: '"2CXDH33HAJ3IFR588FMFDV67K"', +1858 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +1858 silly registry.get 'x-cache': 'HIT', +1858 silly registry.get 'x-cache-hits': '1', +1858 silly registry.get 'x-timer': 'S1411067668.275560,VS0,VE0', +1858 silly registry.get vary: 'Accept', +1858 silly registry.get 'content-length': '0', +1858 silly registry.get 'keep-alive': 'timeout=10, max=31', +1858 silly registry.get connection: 'Keep-Alive' } ] +1859 verbose etag https://registry.npmjs.org/vary from cache +1860 http 304 https://registry.npmjs.org/socket.io +1861 silly registry.get cb [ 304, +1861 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1861 silly registry.get server: 'Apache', +1861 silly registry.get via: '1.1 varnish', +1861 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1861 silly registry.get 'cache-control': 'max-age=60', +1861 silly registry.get etag: '"CUNVWZ66Q6QU7EFO1CU2GJUNK"', +1861 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1861 silly registry.get 'x-cache': 'HIT', +1861 silly registry.get 'x-cache-hits': '1', +1861 silly registry.get 'x-timer': 'S1411067668.310713,VS0,VE0', +1861 silly registry.get vary: 'Accept', +1861 silly registry.get 'content-length': '0', +1861 silly registry.get 'keep-alive': 'timeout=10, max=9', +1861 silly registry.get connection: 'Keep-Alive' } ] +1862 verbose etag https://registry.npmjs.org/socket.io from cache +1863 http 304 https://registry.npmjs.org/merge-descriptors +1864 silly registry.get cb [ 304, +1864 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1864 silly registry.get server: 'Apache', +1864 silly registry.get via: '1.1 varnish', +1864 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1864 silly registry.get 'cache-control': 'max-age=60', +1864 silly registry.get etag: '"3RYSGNCRJI3J41K25KQGWTAO8"', +1864 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +1864 silly registry.get 'x-cache': 'HIT', +1864 silly registry.get 'x-cache-hits': '1', +1864 silly registry.get 'x-timer': 'S1411067668.307944,VS0,VE0', +1864 silly registry.get vary: 'Accept', +1864 silly registry.get 'content-length': '0', +1864 silly registry.get 'keep-alive': 'timeout=10, max=32', +1864 silly registry.get connection: 'Keep-Alive' } ] +1865 verbose etag https://registry.npmjs.org/merge-descriptors from cache +1866 http 304 https://registry.npmjs.org/minimatch +1867 silly registry.get cb [ 304, +1867 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1867 silly registry.get server: 'Apache', +1867 silly registry.get via: '1.1 varnish', +1867 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:13:54 GMT', +1867 silly registry.get 'cache-control': 'max-age=60', +1867 silly registry.get etag: '"667Q92RS6N1601AM7ZZ1NERE8"', +1867 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1867 silly registry.get 'x-cache': 'HIT', +1867 silly registry.get 'x-cache-hits': '5', +1867 silly registry.get 'x-timer': 'S1411067668.332215,VS0,VE0', +1867 silly registry.get vary: 'Accept', +1867 silly registry.get 'content-length': '0', +1867 silly registry.get 'keep-alive': 'timeout=10, max=8', +1867 silly registry.get connection: 'Keep-Alive' } ] +1868 verbose etag https://registry.npmjs.org/minimatch from cache +1869 http 304 https://registry.npmjs.org/di +1870 silly registry.get cb [ 304, +1870 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1870 silly registry.get server: 'Apache', +1870 silly registry.get via: '1.1 varnish', +1870 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:04:00 GMT', +1870 silly registry.get 'cache-control': 'max-age=60', +1870 silly registry.get etag: '"CTKG02U8QBHJEHRTPYH0DT4MI"', +1870 silly registry.get 'x-served-by': 'cache-dfw1834-DFW', +1870 silly registry.get 'x-cache': 'HIT', +1870 silly registry.get 'x-cache-hits': '23', +1870 silly registry.get 'x-timer': 'S1411067668.315324,VS0,VE0', +1870 silly registry.get vary: 'Accept', +1870 silly registry.get 'content-length': '0', +1870 silly registry.get 'keep-alive': 'timeout=10, max=30', +1870 silly registry.get connection: 'Keep-Alive' } ] +1871 verbose etag https://registry.npmjs.org/di from cache +1872 http 304 https://registry.npmjs.org/chokidar +1873 silly registry.get cb [ 304, +1873 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1873 silly registry.get server: 'Apache', +1873 silly registry.get via: '1.1 varnish', +1873 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1873 silly registry.get 'cache-control': 'max-age=60', +1873 silly registry.get etag: '"ER41YGW9B4UCCEPXRR8B4LU1F"', +1873 silly registry.get 'x-served-by': 'cache-dfw1826-DFW', +1873 silly registry.get 'x-cache': 'HIT', +1873 silly registry.get 'x-cache-hits': '1', +1873 silly registry.get 'x-timer': 'S1411067668.333259,VS0,VE0', +1873 silly registry.get vary: 'Accept', +1873 silly registry.get 'content-length': '0', +1873 silly registry.get 'keep-alive': 'timeout=10, max=31', +1873 silly registry.get connection: 'Keep-Alive' } ] +1874 verbose etag https://registry.npmjs.org/chokidar from cache +1875 http 304 https://registry.npmjs.org/optimist +1876 silly registry.get cb [ 304, +1876 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1876 silly registry.get server: 'Apache', +1876 silly registry.get via: '1.1 varnish', +1876 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:13:46 GMT', +1876 silly registry.get 'cache-control': 'max-age=60', +1876 silly registry.get etag: '"AY8QEEGZGC3636NYAUBTKPOAX"', +1876 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1876 silly registry.get 'x-cache': 'HIT', +1876 silly registry.get 'x-cache-hits': '5', +1876 silly registry.get 'x-timer': 'S1411067668.353394,VS0,VE0', +1876 silly registry.get vary: 'Accept', +1876 silly registry.get 'content-length': '0', +1876 silly registry.get 'keep-alive': 'timeout=10, max=7', +1876 silly registry.get connection: 'Keep-Alive' } ] +1877 verbose etag https://registry.npmjs.org/optimist from cache +1878 http 304 https://registry.npmjs.org/glob +1879 silly registry.get cb [ 304, +1879 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1879 silly registry.get server: 'Apache', +1879 silly registry.get via: '1.1 varnish', +1879 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:22 GMT', +1879 silly registry.get 'cache-control': 'max-age=60', +1879 silly registry.get etag: '"9GMKCNKBK5IQ307969W8CTPJB"', +1879 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +1879 silly registry.get 'x-cache': 'HIT', +1879 silly registry.get 'x-cache-hits': '2', +1879 silly registry.get 'x-timer': 'S1411067668.338518,VS0,VE0', +1879 silly registry.get vary: 'Accept', +1879 silly registry.get 'content-length': '0', +1879 silly registry.get 'keep-alive': 'timeout=10, max=30', +1879 silly registry.get connection: 'Keep-Alive' } ] +1880 verbose etag https://registry.npmjs.org/glob from cache +1881 http 304 https://registry.npmjs.org/lodash +1882 silly registry.get cb [ 304, +1882 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1882 silly registry.get server: 'Apache', +1882 silly registry.get via: '1.1 varnish', +1882 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:13:55 GMT', +1882 silly registry.get 'cache-control': 'max-age=60', +1882 silly registry.get etag: '"D4I8Y7O3OF15X88NHWU47Q2H"', +1882 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1882 silly registry.get 'x-cache': 'HIT', +1882 silly registry.get 'x-cache-hits': '3', +1882 silly registry.get 'x-timer': 'S1411067668.376338,VS0,VE0', +1882 silly registry.get vary: 'Accept', +1882 silly registry.get 'content-length': '0', +1882 silly registry.get 'keep-alive': 'timeout=10, max=6', +1882 silly registry.get connection: 'Keep-Alive' } ] +1883 verbose etag https://registry.npmjs.org/lodash from cache +1884 http 304 https://registry.npmjs.org/http-proxy +1885 silly registry.get cb [ 304, +1885 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1885 silly registry.get server: 'Apache', +1885 silly registry.get via: '1.1 varnish', +1885 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:13:49 GMT', +1885 silly registry.get 'cache-control': 'max-age=60', +1885 silly registry.get etag: '"AWEN52NBCDTUU26TDH6IHPZNQ"', +1885 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +1885 silly registry.get 'x-cache': 'HIT', +1885 silly registry.get 'x-cache-hits': '2', +1885 silly registry.get 'x-timer': 'S1411067668.367830,VS0,VE0', +1885 silly registry.get vary: 'Accept', +1885 silly registry.get 'content-length': '0', +1885 silly registry.get 'keep-alive': 'timeout=10, max=31', +1885 silly registry.get connection: 'Keep-Alive' } ] +1886 verbose etag https://registry.npmjs.org/http-proxy from cache +1887 http 304 https://registry.npmjs.org/rimraf +1888 silly registry.get cb [ 304, +1888 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1888 silly registry.get server: 'Apache', +1888 silly registry.get via: '1.1 varnish', +1888 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:22 GMT', +1888 silly registry.get 'cache-control': 'max-age=60', +1888 silly registry.get etag: '"31YUZD1DFCDSQ0QSBXMA8KMKQ"', +1888 silly registry.get 'x-served-by': 'cache-dfw1834-DFW', +1888 silly registry.get 'x-cache': 'HIT', +1888 silly registry.get 'x-cache-hits': '3', +1888 silly registry.get 'x-timer': 'S1411067668.379937,VS0,VE0', +1888 silly registry.get vary: 'Accept', +1888 silly registry.get 'content-length': '0', +1888 silly registry.get 'keep-alive': 'timeout=10, max=29', +1888 silly registry.get connection: 'Keep-Alive' } ] +1889 verbose etag https://registry.npmjs.org/rimraf from cache +1890 http 304 https://registry.npmjs.org/colors +1891 silly registry.get cb [ 304, +1891 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1891 silly registry.get server: 'Apache', +1891 silly registry.get via: '1.1 varnish', +1891 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:13:46 GMT', +1891 silly registry.get 'cache-control': 'max-age=60', +1891 silly registry.get etag: '"2ZHMVF9GYTMTHHRFKFO52VJA4"', +1891 silly registry.get 'x-served-by': 'cache-dfw1826-DFW', +1891 silly registry.get 'x-cache': 'HIT', +1891 silly registry.get 'x-cache-hits': '2', +1891 silly registry.get 'x-timer': 'S1411067668.393829,VS0,VE0', +1891 silly registry.get vary: 'Accept', +1891 silly registry.get 'content-length': '0', +1891 silly registry.get 'keep-alive': 'timeout=10, max=30', +1891 silly registry.get connection: 'Keep-Alive' } ] +1892 verbose etag https://registry.npmjs.org/colors from cache +1893 http 304 https://registry.npmjs.org/log4js +1894 silly registry.get cb [ 304, +1894 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1894 silly registry.get server: 'Apache', +1894 silly registry.get via: '1.1 varnish', +1894 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1894 silly registry.get 'cache-control': 'max-age=60', +1894 silly registry.get etag: '"CFKQTZ9X482QEVGFU1ZI22J9U"', +1894 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +1894 silly registry.get 'x-cache': 'HIT', +1894 silly registry.get 'x-cache-hits': '1', +1894 silly registry.get 'x-timer': 'S1411067668.398882,VS0,VE0', +1894 silly registry.get vary: 'Accept', +1894 silly registry.get 'content-length': '0', +1894 silly registry.get 'keep-alive': 'timeout=10, max=29', +1894 silly registry.get connection: 'Keep-Alive' } ] +1895 verbose etag https://registry.npmjs.org/log4js from cache +1896 http 304 https://registry.npmjs.org/useragent +1897 silly registry.get cb [ 304, +1897 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1897 silly registry.get server: 'Apache', +1897 silly registry.get via: '1.1 varnish', +1897 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1897 silly registry.get 'cache-control': 'max-age=60', +1897 silly registry.get etag: '"EK58TZXUSV44E17PS55NRT26J"', +1897 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1897 silly registry.get 'x-cache': 'HIT', +1897 silly registry.get 'x-cache-hits': '1', +1897 silly registry.get 'x-timer': 'S1411067668.397119,VS0,VE28', +1897 silly registry.get vary: 'Accept', +1897 silly registry.get 'content-length': '0', +1897 silly registry.get 'keep-alive': 'timeout=10, max=5', +1897 silly registry.get connection: 'Keep-Alive' } ] +1898 verbose etag https://registry.npmjs.org/useragent from cache +1899 http 304 https://registry.npmjs.org/graceful-fs +1900 silly registry.get cb [ 304, +1900 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1900 silly registry.get server: 'Apache', +1900 silly registry.get via: '1.1 varnish', +1900 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:13:59 GMT', +1900 silly registry.get 'cache-control': 'max-age=60', +1900 silly registry.get etag: '"CV1ZRY03QL5N3MQLTEZ3C8SMD"', +1900 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +1900 silly registry.get 'x-cache': 'HIT', +1900 silly registry.get 'x-cache-hits': '2', +1900 silly registry.get 'x-timer': 'S1411067668.427846,VS0,VE0', +1900 silly registry.get vary: 'Accept', +1900 silly registry.get 'content-length': '0', +1900 silly registry.get 'keep-alive': 'timeout=10, max=30', +1900 silly registry.get connection: 'Keep-Alive' } ] +1901 verbose etag https://registry.npmjs.org/graceful-fs from cache +1902 http 304 https://registry.npmjs.org/source-map +1903 silly registry.get cb [ 304, +1903 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1903 silly registry.get server: 'Apache', +1903 silly registry.get via: '1.1 varnish', +1903 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:23 GMT', +1903 silly registry.get 'cache-control': 'max-age=60', +1903 silly registry.get etag: '"CTPHW9RYNF1ANEGGAB0F3ETOU"', +1903 silly registry.get 'x-served-by': 'cache-dfw1834-DFW', +1903 silly registry.get 'x-cache': 'HIT', +1903 silly registry.get 'x-cache-hits': '2', +1903 silly registry.get 'x-timer': 'S1411067668.439987,VS0,VE0', +1903 silly registry.get vary: 'Accept', +1903 silly registry.get 'content-length': '0', +1903 silly registry.get 'keep-alive': 'timeout=10, max=28', +1903 silly registry.get connection: 'Keep-Alive' } ] +1904 verbose etag https://registry.npmjs.org/source-map from cache +1905 http 304 https://registry.npmjs.org/connect +1906 silly registry.get cb [ 304, +1906 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1906 silly registry.get server: 'Apache', +1906 silly registry.get via: '1.1 varnish', +1906 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1906 silly registry.get 'cache-control': 'max-age=60', +1906 silly registry.get etag: '"4OOTKUADN0IZJR06YAB9DW5V5"', +1906 silly registry.get 'x-served-by': 'cache-dfw1826-DFW', +1906 silly registry.get 'x-cache': 'HIT', +1906 silly registry.get 'x-cache-hits': '1', +1906 silly registry.get 'x-timer': 'S1411067668.454865,VS0,VE1', +1906 silly registry.get vary: 'Accept', +1906 silly registry.get 'content-length': '0', +1906 silly registry.get 'keep-alive': 'timeout=10, max=29', +1906 silly registry.get connection: 'Keep-Alive' } ] +1907 verbose etag https://registry.npmjs.org/connect from cache +1908 http 304 https://registry.npmjs.org/os-utils +1909 silly registry.get cb [ 304, +1909 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1909 silly registry.get server: 'Apache', +1909 silly registry.get via: '1.1 varnish', +1909 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1909 silly registry.get 'cache-control': 'max-age=60', +1909 silly registry.get etag: '"40DZ5TBOYP4EQNT6BOB9ZB247"', +1909 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1909 silly registry.get 'x-cache': 'MISS', +1909 silly registry.get 'x-cache-hits': '0', +1909 silly registry.get 'x-timer': 'S1411067668.446988,VS0,VE29', +1909 silly registry.get vary: 'Accept', +1909 silly registry.get 'content-length': '0', +1909 silly registry.get 'keep-alive': 'timeout=10, max=4', +1909 silly registry.get connection: 'Keep-Alive' } ] +1910 verbose etag https://registry.npmjs.org/os-utils from cache +1911 http 304 https://registry.npmjs.org/read +1912 silly registry.get cb [ 304, +1912 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1912 silly registry.get server: 'Apache', +1912 silly registry.get via: '1.1 varnish', +1912 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1912 silly registry.get 'cache-control': 'max-age=60', +1912 silly registry.get etag: '"3GJAEEPR102J14KTQCVBP03AW"', +1912 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +1912 silly registry.get 'x-cache': 'HIT', +1912 silly registry.get 'x-cache-hits': '1', +1912 silly registry.get 'x-timer': 'S1411067668.488521,VS0,VE0', +1912 silly registry.get vary: 'Accept', +1912 silly registry.get 'content-length': '0', +1912 silly registry.get 'keep-alive': 'timeout=10, max=29', +1912 silly registry.get connection: 'Keep-Alive' } ] +1913 verbose etag https://registry.npmjs.org/read from cache +1914 http 304 https://registry.npmjs.org/commander +1915 silly registry.get cb [ 304, +1915 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1915 silly registry.get server: 'Apache', +1915 silly registry.get via: '1.1 varnish', +1915 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:13:50 GMT', +1915 silly registry.get 'cache-control': 'max-age=60', +1915 silly registry.get etag: '"64YG0KD6CNHI7FUB33O0JW3G2"', +1915 silly registry.get 'x-served-by': 'cache-dfw1826-DFW', +1915 silly registry.get 'x-cache': 'HIT', +1915 silly registry.get 'x-cache-hits': '4', +1915 silly registry.get 'x-timer': 'S1411067668.516008,VS0,VE0', +1915 silly registry.get vary: 'Accept', +1915 silly registry.get 'content-length': '0', +1915 silly registry.get 'keep-alive': 'timeout=10, max=28', +1915 silly registry.get connection: 'Keep-Alive' } ] +1916 verbose etag https://registry.npmjs.org/commander from cache +1917 http 304 https://registry.npmjs.org/drawille +1918 silly registry.get cb [ 304, +1918 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1918 silly registry.get server: 'Apache', +1918 silly registry.get via: '1.1 varnish', +1918 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1918 silly registry.get 'cache-control': 'max-age=60', +1918 silly registry.get etag: '"1UVF72U5X6E0EX5EO7I4FZIN8"', +1918 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +1918 silly registry.get 'x-cache': 'MISS', +1918 silly registry.get 'x-cache-hits': '0', +1918 silly registry.get 'x-timer': 'S1411067668.459742,VS0,VE58', +1918 silly registry.get vary: 'Accept', +1918 silly registry.get 'content-length': '0', +1918 silly registry.get 'keep-alive': 'timeout=10, max=28', +1918 silly registry.get connection: 'Keep-Alive' } ] +1919 verbose etag https://registry.npmjs.org/drawille from cache +1920 http 304 https://registry.npmjs.org/sudo +1921 silly registry.get cb [ 304, +1921 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1921 silly registry.get server: 'Apache', +1921 silly registry.get via: '1.1 varnish', +1921 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1921 silly registry.get 'cache-control': 'max-age=60', +1921 silly registry.get etag: '"6BIYD2GTF2TWOA3ZYDE1VU31M"', +1921 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1921 silly registry.get 'x-cache': 'MISS', +1921 silly registry.get 'x-cache-hits': '0', +1921 silly registry.get 'x-timer': 'S1411067668.498499,VS0,VE64', +1921 silly registry.get vary: 'Accept', +1921 silly registry.get 'content-length': '0', +1921 silly registry.get 'keep-alive': 'timeout=10, max=3', +1921 silly registry.get connection: 'Keep-Alive' } ] +1922 verbose etag https://registry.npmjs.org/sudo from cache +1923 http 304 https://registry.npmjs.org/glob +1924 silly registry.get cb [ 304, +1924 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1924 silly registry.get server: 'Apache', +1924 silly registry.get via: '1.1 varnish', +1924 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1924 silly registry.get 'cache-control': 'max-age=60', +1924 silly registry.get etag: '"9GMKCNKBK5IQ307969W8CTPJB"', +1924 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +1924 silly registry.get 'x-cache': 'HIT', +1924 silly registry.get 'x-cache-hits': '1', +1924 silly registry.get 'x-timer': 'S1411067668.548592,VS0,VE0', +1924 silly registry.get vary: 'Accept', +1924 silly registry.get 'content-length': '0', +1924 silly registry.get 'keep-alive': 'timeout=10, max=28', +1924 silly registry.get connection: 'Keep-Alive' } ] +1925 verbose etag https://registry.npmjs.org/glob from cache +1926 http 304 https://registry.npmjs.org/npmconf +1927 silly registry.get cb [ 304, +1927 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1927 silly registry.get server: 'Apache', +1927 silly registry.get via: '1.1 varnish', +1927 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:27 GMT', +1927 silly registry.get 'cache-control': 'max-age=60', +1927 silly registry.get etag: '"7HF6DT5S4MJUYUFN4MTME27TH"', +1927 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1927 silly registry.get 'x-cache': 'HIT', +1927 silly registry.get 'x-cache-hits': '2', +1927 silly registry.get 'x-timer': 'S1411067668.583635,VS0,VE0', +1927 silly registry.get vary: 'Accept', +1927 silly registry.get 'content-length': '0', +1927 silly registry.get 'keep-alive': 'timeout=10, max=2', +1927 silly registry.get connection: 'Keep-Alive' } ] +1928 verbose etag https://registry.npmjs.org/npmconf from cache +1929 http 304 https://registry.npmjs.org/adm-zip +1930 silly registry.get cb [ 304, +1930 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1930 silly registry.get server: 'Apache', +1930 silly registry.get via: '1.1 varnish', +1930 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1930 silly registry.get 'cache-control': 'max-age=60', +1930 silly registry.get etag: '"1VY8YMVL2CB98BLU0J0PXFNXN"', +1930 silly registry.get 'x-served-by': 'cache-dfw1826-DFW', +1930 silly registry.get 'x-cache': 'HIT', +1930 silly registry.get 'x-cache-hits': '1', +1930 silly registry.get 'x-timer': 'S1411067668.575760,VS0,VE0', +1930 silly registry.get vary: 'Accept', +1930 silly registry.get 'content-length': '0', +1930 silly registry.get 'keep-alive': 'timeout=10, max=27', +1930 silly registry.get connection: 'Keep-Alive' } ] +1931 verbose etag https://registry.npmjs.org/adm-zip from cache +1932 http 304 https://registry.npmjs.org/kew +1933 silly registry.get cb [ 304, +1933 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1933 silly registry.get server: 'Apache', +1933 silly registry.get via: '1.1 varnish', +1933 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1933 silly registry.get 'cache-control': 'max-age=60', +1933 silly registry.get etag: '"O0R55ULEE70HO9OUMS5I19OS"', +1933 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +1933 silly registry.get 'x-cache': 'HIT', +1933 silly registry.get 'x-cache-hits': '1', +1933 silly registry.get 'x-timer': 'S1411067668.580663,VS0,VE0', +1933 silly registry.get vary: 'Accept', +1933 silly registry.get 'content-length': '0', +1933 silly registry.get 'keep-alive': 'timeout=10, max=27', +1933 silly registry.get connection: 'Keep-Alive' } ] +1934 verbose etag https://registry.npmjs.org/kew from cache +1935 http 304 https://registry.npmjs.org/mkdirp +1936 silly registry.get cb [ 304, +1936 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1936 silly registry.get server: 'Apache', +1936 silly registry.get via: '1.1 varnish', +1936 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:10 GMT', +1936 silly registry.get 'cache-control': 'max-age=60', +1936 silly registry.get etag: '"EOPTJ0J36LYXZXUCFC4K7PMWN"', +1936 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1936 silly registry.get 'x-cache': 'HIT', +1936 silly registry.get 'x-cache-hits': '4', +1936 silly registry.get 'x-timer': 'S1411067668.604004,VS0,VE0', +1936 silly registry.get vary: 'Accept', +1936 silly registry.get 'content-length': '0', +1936 silly registry.get 'keep-alive': 'timeout=10, max=1', +1936 silly registry.get connection: 'Keep-Alive' } ] +1937 verbose etag https://registry.npmjs.org/mkdirp from cache +1938 http 304 https://registry.npmjs.org/rimraf +1939 silly registry.get cb [ 304, +1939 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1939 silly registry.get server: 'Apache', +1939 silly registry.get via: '1.1 varnish', +1939 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1939 silly registry.get 'cache-control': 'max-age=60', +1939 silly registry.get etag: '"31YUZD1DFCDSQ0QSBXMA8KMKQ"', +1939 silly registry.get 'x-served-by': 'cache-ord1731-ORD', +1939 silly registry.get 'x-cache': 'HIT', +1939 silly registry.get 'x-cache-hits': '1', +1939 silly registry.get 'x-timer': 'S1411067668.624310,VS0,VE0', +1939 silly registry.get vary: 'Accept', +1939 silly registry.get 'content-length': '0', +1939 silly registry.get connection: 'close' } ] +1940 verbose etag https://registry.npmjs.org/rimraf from cache +1941 http 304 https://registry.npmjs.org/ncp +1942 silly registry.get cb [ 304, +1942 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1942 silly registry.get server: 'Apache', +1942 silly registry.get via: '1.1 varnish', +1942 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1942 silly registry.get 'cache-control': 'max-age=60', +1942 silly registry.get etag: '"9KYAENLPK45QQB0WV4L5LKHBL"', +1942 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +1942 silly registry.get 'x-cache': 'HIT', +1942 silly registry.get 'x-cache-hits': '1', +1942 silly registry.get 'x-timer': 'S1411067668.612737,VS0,VE0', +1942 silly registry.get vary: 'Accept', +1942 silly registry.get 'content-length': '0', +1942 silly registry.get 'keep-alive': 'timeout=10, max=27', +1942 silly registry.get connection: 'Keep-Alive' } ] +1943 verbose etag https://registry.npmjs.org/ncp from cache +1944 http 304 https://registry.npmjs.org/progress +1945 silly registry.get cb [ 304, +1945 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1945 silly registry.get server: 'Apache', +1945 silly registry.get via: '1.1 varnish', +1945 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1945 silly registry.get 'cache-control': 'max-age=60', +1945 silly registry.get etag: '"CTBNNWBUBUNHYF6WH3TQHWI9F"', +1945 silly registry.get 'x-served-by': 'cache-dfw1826-DFW', +1945 silly registry.get 'x-cache': 'HIT', +1945 silly registry.get 'x-cache-hits': '1', +1945 silly registry.get 'x-timer': 'S1411067668.636041,VS0,VE0', +1945 silly registry.get vary: 'Accept', +1945 silly registry.get 'content-length': '0', +1945 silly registry.get 'keep-alive': 'timeout=10, max=26', +1945 silly registry.get connection: 'Keep-Alive' } ] +1946 verbose etag https://registry.npmjs.org/progress from cache +1947 http 304 https://registry.npmjs.org/request-progress +1948 silly registry.get cb [ 304, +1948 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1948 silly registry.get server: 'Apache', +1948 silly registry.get via: '1.1 varnish', +1948 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1948 silly registry.get 'cache-control': 'max-age=60', +1948 silly registry.get etag: '"5X7J2IR4V022O460EXK926ZI6"', +1948 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +1948 silly registry.get 'x-cache': 'HIT', +1948 silly registry.get 'x-cache-hits': '1', +1948 silly registry.get 'x-timer': 'S1411067668.641060,VS0,VE0', +1948 silly registry.get vary: 'Accept', +1948 silly registry.get 'content-length': '0', +1948 silly registry.get 'keep-alive': 'timeout=10, max=26', +1948 silly registry.get connection: 'Keep-Alive' } ] +1949 verbose etag https://registry.npmjs.org/request-progress from cache +1950 http 304 https://registry.npmjs.org/punycode +1951 silly registry.get cb [ 304, +1951 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1951 silly registry.get server: 'Apache', +1951 silly registry.get via: '1.1 varnish', +1951 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:05 GMT', +1951 silly registry.get 'cache-control': 'max-age=60', +1951 silly registry.get etag: '"4BW1YHT5BPGKOFNC5XEHSTVES"', +1951 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +1951 silly registry.get 'x-cache': 'HIT', +1951 silly registry.get 'x-cache-hits': '2', +1951 silly registry.get 'x-timer': 'S1411067668.675188,VS0,VE0', +1951 silly registry.get vary: 'Accept', +1951 silly registry.get 'content-length': '0', +1951 silly registry.get 'keep-alive': 'timeout=10, max=26', +1951 silly registry.get connection: 'Keep-Alive' } ] +1952 verbose etag https://registry.npmjs.org/punycode from cache +1953 http 304 https://registry.npmjs.org/glob +1954 silly registry.get cb [ 304, +1954 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1954 silly registry.get server: 'Apache', +1954 silly registry.get via: '1.1 varnish', +1954 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:01 GMT', +1954 silly registry.get 'cache-control': 'max-age=60', +1954 silly registry.get etag: '"9GMKCNKBK5IQ307969W8CTPJB"', +1954 silly registry.get 'x-served-by': 'cache-dfw1826-DFW', +1954 silly registry.get 'x-cache': 'HIT', +1954 silly registry.get 'x-cache-hits': '2', +1954 silly registry.get 'x-timer': 'S1411067668.696209,VS0,VE0', +1954 silly registry.get vary: 'Accept', +1954 silly registry.get 'content-length': '0', +1954 silly registry.get 'keep-alive': 'timeout=10, max=25', +1954 silly registry.get connection: 'Keep-Alive' } ] +1955 verbose etag https://registry.npmjs.org/glob from cache +1956 http 304 https://registry.npmjs.org/lodash +1957 silly registry.get cb [ 304, +1957 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1957 silly registry.get server: 'Apache', +1957 silly registry.get via: '1.1 varnish', +1957 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:13:53 GMT', +1957 silly registry.get 'cache-control': 'max-age=60', +1957 silly registry.get etag: '"D4I8Y7O3OF15X88NHWU47Q2H"', +1957 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +1957 silly registry.get 'x-cache': 'HIT', +1957 silly registry.get 'x-cache-hits': '2', +1957 silly registry.get 'x-timer': 'S1411067668.702253,VS0,VE0', +1957 silly registry.get vary: 'Accept', +1957 silly registry.get 'content-length': '0', +1957 silly registry.get 'keep-alive': 'timeout=10, max=25', +1957 silly registry.get connection: 'Keep-Alive' } ] +1958 verbose etag https://registry.npmjs.org/lodash from cache +1959 http 304 https://registry.npmjs.org/deep-equal +1960 silly registry.get cb [ 304, +1960 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1960 silly registry.get server: 'Apache', +1960 silly registry.get via: '1.1 varnish', +1960 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1960 silly registry.get 'cache-control': 'max-age=60', +1960 silly registry.get etag: '"BOXPPUZO0BER36QDXAATF1DID"', +1960 silly registry.get 'x-served-by': 'cache-dfw1826-DFW', +1960 silly registry.get 'x-cache': 'HIT', +1960 silly registry.get 'x-cache-hits': '1', +1960 silly registry.get 'x-timer': 'S1411067668.756160,VS0,VE0', +1960 silly registry.get vary: 'Accept', +1960 silly registry.get 'content-length': '0', +1960 silly registry.get 'keep-alive': 'timeout=10, max=24', +1960 silly registry.get connection: 'Keep-Alive' } ] +1961 verbose etag https://registry.npmjs.org/deep-equal from cache +1962 http 304 https://registry.npmjs.org/blessed +1963 silly registry.get cb [ 304, +1963 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1963 silly registry.get server: 'Apache', +1963 silly registry.get via: '1.1 varnish', +1963 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1963 silly registry.get 'cache-control': 'max-age=60', +1963 silly registry.get etag: '"9C7VCD52SDVQ5ILHKDNGKW5E9"', +1963 silly registry.get 'x-served-by': 'cache-dfw1834-DFW', +1963 silly registry.get 'x-cache': 'HIT', +1963 silly registry.get 'x-cache-hits': '1', +1963 silly registry.get 'x-timer': 'S1411067668.499863,VS0,VE260', +1963 silly registry.get vary: 'Accept', +1963 silly registry.get 'content-length': '0', +1963 silly registry.get 'keep-alive': 'timeout=10, max=27', +1963 silly registry.get connection: 'Keep-Alive' } ] +1964 verbose etag https://registry.npmjs.org/blessed from cache +1965 http 304 https://registry.npmjs.org/buffer-equal +1966 silly registry.get cb [ 304, +1966 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1966 silly registry.get server: 'Apache', +1966 silly registry.get via: '1.1 varnish', +1966 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1966 silly registry.get 'cache-control': 'max-age=60', +1966 silly registry.get etag: '"23N78YD77LZ993F7JQGSAWXBV"', +1966 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +1966 silly registry.get 'x-cache': 'HIT', +1966 silly registry.get 'x-cache-hits': '1', +1966 silly registry.get 'x-timer': 'S1411067668.735193,VS0,VE42', +1966 silly registry.get vary: 'Accept', +1966 silly registry.get 'content-length': '0', +1966 silly registry.get 'keep-alive': 'timeout=10, max=25', +1966 silly registry.get connection: 'Keep-Alive' } ] +1967 verbose etag https://registry.npmjs.org/buffer-equal from cache +1968 http 304 https://registry.npmjs.org/difflet +1969 silly registry.get cb [ 304, +1969 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1969 silly registry.get server: 'Apache', +1969 silly registry.get via: '1.1 varnish', +1969 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1969 silly registry.get 'cache-control': 'max-age=60', +1969 silly registry.get etag: '"8OKQMP1JMJA3TEJ7OXQI9W6YW"', +1969 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +1969 silly registry.get 'x-cache': 'HIT', +1969 silly registry.get 'x-cache-hits': '1', +1969 silly registry.get 'x-timer': 'S1411067668.764569,VS0,VE41', +1969 silly registry.get vary: 'Accept', +1969 silly registry.get 'content-length': '0', +1969 silly registry.get 'keep-alive': 'timeout=10, max=24', +1969 silly registry.get connection: 'Keep-Alive' } ] +1970 verbose etag https://registry.npmjs.org/difflet from cache +1971 http 304 https://registry.npmjs.org/glob +1972 silly registry.get cb [ 304, +1972 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1972 silly registry.get server: 'Apache', +1972 silly registry.get via: '1.1 varnish', +1972 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:01 GMT', +1972 silly registry.get 'cache-control': 'max-age=60', +1972 silly registry.get etag: '"9GMKCNKBK5IQ307969W8CTPJB"', +1972 silly registry.get 'x-served-by': 'cache-dfw1826-DFW', +1972 silly registry.get 'x-cache': 'HIT', +1972 silly registry.get 'x-cache-hits': '3', +1972 silly registry.get 'x-timer': 'S1411067668.817293,VS0,VE0', +1972 silly registry.get vary: 'Accept', +1972 silly registry.get 'content-length': '0', +1972 silly registry.get 'keep-alive': 'timeout=10, max=23', +1972 silly registry.get connection: 'Keep-Alive' } ] +1973 verbose etag https://registry.npmjs.org/glob from cache +1974 http 304 https://registry.npmjs.org/inherits +1975 silly registry.get cb [ 304, +1975 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1975 silly registry.get server: 'Apache', +1975 silly registry.get via: '1.1 varnish', +1975 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:14 GMT', +1975 silly registry.get 'cache-control': 'max-age=60', +1975 silly registry.get etag: '"BVVVLO9F0SYSTO7F6UCP7E16D"', +1975 silly registry.get 'x-served-by': 'cache-dfw1834-DFW', +1975 silly registry.get 'x-cache': 'HIT', +1975 silly registry.get 'x-cache-hits': '2', +1975 silly registry.get 'x-timer': 'S1411067668.820846,VS0,VE0', +1975 silly registry.get vary: 'Accept', +1975 silly registry.get 'content-length': '0', +1975 silly registry.get 'keep-alive': 'timeout=10, max=26', +1975 silly registry.get connection: 'Keep-Alive' } ] +1976 verbose etag https://registry.npmjs.org/inherits from cache +1977 http 304 https://registry.npmjs.org/mkdirp +1978 silly registry.get cb [ 304, +1978 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1978 silly registry.get server: 'Apache', +1978 silly registry.get via: '1.1 varnish', +1978 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1978 silly registry.get 'cache-control': 'max-age=60', +1978 silly registry.get etag: '"EOPTJ0J36LYXZXUCFC4K7PMWN"', +1978 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +1978 silly registry.get 'x-cache': 'HIT', +1978 silly registry.get 'x-cache-hits': '1', +1978 silly registry.get 'x-timer': 'S1411067668.837046,VS0,VE0', +1978 silly registry.get vary: 'Accept', +1978 silly registry.get 'content-length': '0', +1978 silly registry.get 'keep-alive': 'timeout=10, max=24', +1978 silly registry.get connection: 'Keep-Alive' } ] +1979 verbose etag https://registry.npmjs.org/mkdirp from cache +1980 http 304 https://registry.npmjs.org/slide +1981 silly registry.get cb [ 304, +1981 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1981 silly registry.get server: 'Apache', +1981 silly registry.get via: '1.1 varnish', +1981 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1981 silly registry.get 'cache-control': 'max-age=60', +1981 silly registry.get etag: '"1OT32GGB2TU0R1KZ4F5ORHEAG"', +1981 silly registry.get 'x-served-by': 'cache-dfw1826-DFW', +1981 silly registry.get 'x-cache': 'HIT', +1981 silly registry.get 'x-cache-hits': '1', +1981 silly registry.get 'x-timer': 'S1411067668.877516,VS0,VE0', +1981 silly registry.get vary: 'Accept', +1981 silly registry.get 'content-length': '0', +1981 silly registry.get 'keep-alive': 'timeout=10, max=22', +1981 silly registry.get connection: 'Keep-Alive' } ] +1982 verbose etag https://registry.npmjs.org/slide from cache +1983 http 304 https://registry.npmjs.org/runforcover +1984 silly registry.get cb [ 304, +1984 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1984 silly registry.get server: 'Apache', +1984 silly registry.get via: '1.1 varnish', +1984 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1984 silly registry.get 'cache-control': 'max-age=60', +1984 silly registry.get etag: '"A7MHIHFIYLRSW8NQC4LF47YMB"', +1984 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +1984 silly registry.get 'x-cache': 'HIT', +1984 silly registry.get 'x-cache-hits': '1', +1984 silly registry.get 'x-timer': 'S1411067668.866094,VS0,VE40', +1984 silly registry.get vary: 'Accept', +1984 silly registry.get 'content-length': '0', +1984 silly registry.get 'keep-alive': 'timeout=10, max=23', +1984 silly registry.get connection: 'Keep-Alive' } ] +1985 verbose etag https://registry.npmjs.org/runforcover from cache +1986 http 304 https://registry.npmjs.org/yamlish +1987 silly registry.get cb [ 304, +1987 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1987 silly registry.get server: 'Apache', +1987 silly registry.get via: '1.1 varnish', +1987 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1987 silly registry.get 'cache-control': 'max-age=60', +1987 silly registry.get etag: '"5I8XWLRMZJYBEIKOU7YG7UF28"', +1987 silly registry.get 'x-served-by': 'cache-dfw1834-DFW', +1987 silly registry.get 'x-cache': 'HIT', +1987 silly registry.get 'x-cache-hits': '1', +1987 silly registry.get 'x-timer': 'S1411067668.881721,VS0,VE48', +1987 silly registry.get vary: 'Accept', +1987 silly registry.get 'content-length': '0', +1987 silly registry.get 'keep-alive': 'timeout=10, max=25', +1987 silly registry.get connection: 'Keep-Alive' } ] +1988 verbose etag https://registry.npmjs.org/yamlish from cache +1989 http 304 https://registry.npmjs.org/minimist +1990 silly registry.get cb [ 304, +1990 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1990 silly registry.get server: 'Apache', +1990 silly registry.get via: '1.1 varnish', +1990 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +1990 silly registry.get 'cache-control': 'max-age=60', +1990 silly registry.get etag: '"AHII70P6K2F5XHCZ6RO4Y7WMM"', +1990 silly registry.get 'x-served-by': 'cache-dfw1826-DFW', +1990 silly registry.get 'x-cache': 'HIT', +1990 silly registry.get 'x-cache-hits': '1', +1990 silly registry.get 'x-timer': 'S1411067668.938146,VS0,VE0', +1990 silly registry.get vary: 'Accept', +1990 silly registry.get 'content-length': '0', +1990 silly registry.get 'keep-alive': 'timeout=10, max=21', +1990 silly registry.get connection: 'Keep-Alive' } ] +1991 verbose etag https://registry.npmjs.org/minimist from cache +1992 http 304 https://registry.npmjs.org/underscore-contrib +1993 silly registry.get cb [ 304, +1993 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:28 GMT', +1993 silly registry.get server: 'Apache', +1993 silly registry.get via: '1.1 varnish', +1993 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:29 GMT', +1993 silly registry.get 'cache-control': 'max-age=60', +1993 silly registry.get etag: '"A7V2IWHWA0LLU5TGPGSX7OIGK"', +1993 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +1993 silly registry.get 'x-cache': 'HIT', +1993 silly registry.get 'x-cache-hits': '1', +1993 silly registry.get 'x-timer': 'S1411067668.904514,VS0,VE259', +1993 silly registry.get vary: 'Accept', +1993 silly registry.get 'content-length': '0', +1993 silly registry.get 'keep-alive': 'timeout=10, max=23', +1993 silly registry.get connection: 'Keep-Alive' } ] +1994 verbose etag https://registry.npmjs.org/underscore-contrib from cache +1995 http 304 https://registry.npmjs.org/which +1996 silly registry.get cb [ 304, +1996 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:29 GMT', +1996 silly registry.get server: 'Apache', +1996 silly registry.get via: '1.1 varnish', +1996 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:29 GMT', +1996 silly registry.get 'cache-control': 'max-age=60', +1996 silly registry.get etag: '"V2MIU40L4XLGREBQDUE5E170"', +1996 silly registry.get 'x-served-by': 'cache-dfw1833-DFW', +1996 silly registry.get 'x-cache': 'HIT', +1996 silly registry.get 'x-cache-hits': '1', +1996 silly registry.get 'x-timer': 'S1411067669.437643,VS0,VE0', +1996 silly registry.get vary: 'Accept', +1996 silly registry.get 'content-length': '0', +1996 silly registry.get 'keep-alive': 'timeout=10, max=50', +1996 silly registry.get connection: 'Keep-Alive' } ] +1997 verbose etag https://registry.npmjs.org/which from cache +1998 verbose tar unpack /tmp/npm-17670-yMiqFMg9/github.com/hegemonic/taffydb/tarball/master +1999 silly lockFile e0ffc318-ic-taffydb-tarball-master-unpack tar:///tmp/npm-17670-yMiqFMg9/github.com/hegemonic/taffydb/tarball/master-unpack +2000 verbose lock tar:///tmp/npm-17670-yMiqFMg9/github.com/hegemonic/taffydb/tarball/master-unpack /root/.npm/e0ffc318-ic-taffydb-tarball-master-unpack.lock +2001 silly lockFile 10e5e6ab-hegemonic-taffydb-tarball-master tar:///tmp/npm-17670-yMiqFMg9/github.com/hegemonic/taffydb/tarball/master +2002 verbose lock tar:///tmp/npm-17670-yMiqFMg9/github.com/hegemonic/taffydb/tarball/master /root/.npm/10e5e6ab-hegemonic-taffydb-tarball-master.lock +2003 silly gunzTarPerm modes [ '755', '644' ] +2004 verbose registry.get https://registry.npmjs.org/ms not expired, no request +2005 verbose request where is /mime-types +2006 verbose request registry https://registry.npmjs.org/ +2007 verbose url raw /mime-types +2008 verbose url resolving [ 'https://registry.npmjs.org/', './mime-types' ] +2009 verbose url resolved https://registry.npmjs.org/mime-types +2010 verbose request where is https://registry.npmjs.org/mime-types +2011 info trying registry request attempt 1 at 15:14:30 +2012 verbose etag "B5U64GWQ6AQNEF9M2XN8BFUJZ" +2013 http GET https://registry.npmjs.org/mime-types +2014 verbose request where is /negotiator +2015 verbose request registry https://registry.npmjs.org/ +2016 verbose url raw /negotiator +2017 verbose url resolving [ 'https://registry.npmjs.org/', './negotiator' ] +2018 verbose url resolved https://registry.npmjs.org/negotiator +2019 verbose request where is https://registry.npmjs.org/negotiator +2020 info trying registry request attempt 1 at 15:14:30 +2021 verbose etag "777L0S4UKN6FYD9Z9L2TJQLN3" +2022 http GET https://registry.npmjs.org/negotiator +2023 verbose request where is /crc +2024 verbose request registry https://registry.npmjs.org/ +2025 verbose url raw /crc +2026 verbose url resolving [ 'https://registry.npmjs.org/', './crc' ] +2027 verbose url resolved https://registry.npmjs.org/crc +2028 verbose request where is https://registry.npmjs.org/crc +2029 info trying registry request attempt 1 at 15:14:30 +2030 verbose etag "BW6YQ8QKL056EF6CHL4KCRA8" +2031 http GET https://registry.npmjs.org/crc +2032 verbose request where is /ee-first +2033 verbose request registry https://registry.npmjs.org/ +2034 verbose url raw /ee-first +2035 verbose url resolving [ 'https://registry.npmjs.org/', './ee-first' ] +2036 verbose url resolved https://registry.npmjs.org/ee-first +2037 verbose request where is https://registry.npmjs.org/ee-first +2038 info trying registry request attempt 1 at 15:14:30 +2039 verbose etag "846IVN2KJTCG8QAR9U2ZHHHP8" +2040 http GET https://registry.npmjs.org/ee-first +2041 verbose registry.get https://registry.npmjs.org/media-typer not expired, no request +2042 verbose request where is /mime-types +2043 verbose request registry https://registry.npmjs.org/ +2044 verbose url raw /mime-types +2045 verbose url resolving [ 'https://registry.npmjs.org/', './mime-types' ] +2046 verbose url resolved https://registry.npmjs.org/mime-types +2047 verbose request where is https://registry.npmjs.org/mime-types +2048 info trying registry request attempt 1 at 15:14:30 +2049 verbose etag "B5U64GWQ6AQNEF9M2XN8BFUJZ" +2050 http GET https://registry.npmjs.org/mime-types +2051 verbose registry.get https://registry.npmjs.org/debug not expired, no request +2052 verbose registry.get https://registry.npmjs.org/depd not expired, no request +2053 verbose registry.get https://registry.npmjs.org/escape-html not expired, no request +2054 verbose registry.get https://registry.npmjs.org/etag not expired, no request +2055 verbose registry.get https://registry.npmjs.org/fresh not expired, no request +2056 verbose registry.get https://registry.npmjs.org/mime not expired, no request +2057 verbose registry.get https://registry.npmjs.org/ms not expired, no request +2058 verbose registry.get https://registry.npmjs.org/on-finished not expired, no request +2059 verbose registry.get https://registry.npmjs.org/range-parser not expired, no request +2060 verbose registry.get https://registry.npmjs.org/escape-html not expired, no request +2061 verbose registry.get https://registry.npmjs.org/parseurl not expired, no request +2062 verbose registry.get https://registry.npmjs.org/utils-merge not expired, no request +2063 verbose registry.get https://registry.npmjs.org/send not expired, no request +2064 verbose registry.get https://registry.npmjs.org/hooker not expired, no request +2065 verbose registry.get https://registry.npmjs.org/lodash not expired, no request +2066 verbose registry.get https://registry.npmjs.org/underscore.string not expired, no request +2067 verbose registry.get https://registry.npmjs.org/colors not expired, no request +2068 verbose request where is /ipaddr.js +2069 verbose request registry https://registry.npmjs.org/ +2070 verbose url raw /ipaddr.js +2071 verbose url resolving [ 'https://registry.npmjs.org/', './ipaddr.js' ] +2072 verbose url resolved https://registry.npmjs.org/ipaddr.js +2073 verbose request where is https://registry.npmjs.org/ipaddr.js +2074 info trying registry request attempt 1 at 15:14:30 +2075 verbose etag "AABFRJK3K2AH3K7GGM3Y9I7AO" +2076 http GET https://registry.npmjs.org/ipaddr.js +2077 verbose request where is /destroy +2078 verbose request registry https://registry.npmjs.org/ +2079 verbose url raw /destroy +2080 verbose url resolving [ 'https://registry.npmjs.org/', './destroy' ] +2081 verbose url resolved https://registry.npmjs.org/destroy +2082 verbose request where is https://registry.npmjs.org/destroy +2083 info trying registry request attempt 1 at 15:14:30 +2084 verbose etag "50Y39IQEZLEFEJDYESTKCS8VE" +2085 http GET https://registry.npmjs.org/destroy +2086 verbose registry.get https://registry.npmjs.org/glob not expired, no request +2087 verbose registry.get https://registry.npmjs.org/lodash not expired, no request +2088 verbose request where is /component-type +2089 verbose request registry https://registry.npmjs.org/ +2090 verbose url raw /component-type +2091 verbose url resolving [ 'https://registry.npmjs.org/', './component-type' ] +2092 verbose url resolved https://registry.npmjs.org/component-type +2093 verbose request where is https://registry.npmjs.org/component-type +2094 info trying registry request attempt 1 at 15:14:30 +2095 verbose etag "7P02BBKDTR44SEUISD0LZUIW8" +2096 http GET https://registry.npmjs.org/component-type +2097 verbose request where is /stream-to-array +2098 verbose request registry https://registry.npmjs.org/ +2099 verbose url raw /stream-to-array +2100 verbose url resolving [ 'https://registry.npmjs.org/', './stream-to-array' ] +2101 verbose url resolved https://registry.npmjs.org/stream-to-array +2102 verbose request where is https://registry.npmjs.org/stream-to-array +2103 info trying registry request attempt 1 at 15:14:30 +2104 verbose etag "CEFJPDZYTAADA5SD469NI6MD5" +2105 http GET https://registry.npmjs.org/stream-to-array +2106 verbose request where is /css +2107 verbose request registry https://registry.npmjs.org/ +2108 verbose url raw /css +2109 verbose url resolving [ 'https://registry.npmjs.org/', './css' ] +2110 verbose url resolved https://registry.npmjs.org/css +2111 verbose request where is https://registry.npmjs.org/css +2112 info trying registry request attempt 1 at 15:14:30 +2113 verbose etag "3JKMNW0FVVDQS5ZKDCPPNJ0PN" +2114 http GET https://registry.npmjs.org/css +2115 verbose request where is /convert-source-map +2116 verbose request registry https://registry.npmjs.org/ +2117 verbose url raw /convert-source-map +2118 verbose url resolving [ 'https://registry.npmjs.org/', './convert-source-map' ] +2119 verbose url resolved https://registry.npmjs.org/convert-source-map +2120 verbose request where is https://registry.npmjs.org/convert-source-map +2121 info trying registry request attempt 1 at 15:14:30 +2122 verbose etag "728SNU7BT1CNJR7S68159LD2E" +2123 http GET https://registry.npmjs.org/convert-source-map +2124 verbose request where is /rgb +2125 verbose request registry https://registry.npmjs.org/ +2126 verbose url raw /rgb +2127 verbose url resolving [ 'https://registry.npmjs.org/', './rgb' ] +2128 verbose url resolved https://registry.npmjs.org/rgb +2129 verbose request where is https://registry.npmjs.org/rgb +2130 info trying registry request attempt 1 at 15:14:30 +2131 verbose etag "DBXZ09OSXAFT16OTHXYMW4P9C" +2132 http GET https://registry.npmjs.org/rgb +2133 verbose request where is /css +2134 verbose request registry https://registry.npmjs.org/ +2135 verbose url raw /css +2136 verbose url resolving [ 'https://registry.npmjs.org/', './css' ] +2137 verbose url resolved https://registry.npmjs.org/css +2138 verbose request where is https://registry.npmjs.org/css +2139 info trying registry request attempt 1 at 15:14:30 +2140 verbose etag "3JKMNW0FVVDQS5ZKDCPPNJ0PN" +2141 http GET https://registry.npmjs.org/css +2142 verbose request where is /find-file +2143 verbose request registry https://registry.npmjs.org/ +2144 verbose url raw /find-file +2145 verbose url resolving [ 'https://registry.npmjs.org/', './find-file' ] +2146 verbose url resolved https://registry.npmjs.org/find-file +2147 verbose request where is https://registry.npmjs.org/find-file +2148 info trying registry request attempt 1 at 15:14:30 +2149 verbose etag "AV7JF5DIK4JBDUH5VE7RSK4MC" +2150 http GET https://registry.npmjs.org/find-file +2151 verbose request where is /parse-import +2152 verbose request registry https://registry.npmjs.org/ +2153 verbose url raw /parse-import +2154 verbose url resolving [ 'https://registry.npmjs.org/', './parse-import' ] +2155 verbose url resolved https://registry.npmjs.org/parse-import +2156 verbose request where is https://registry.npmjs.org/parse-import +2157 info trying registry request attempt 1 at 15:14:30 +2158 verbose etag "COOI65YO14PBQ8PJ6I5S67S93" +2159 http GET https://registry.npmjs.org/parse-import +2160 verbose request where is /to-no-case +2161 verbose request registry https://registry.npmjs.org/ +2162 verbose url raw /to-no-case +2163 verbose url resolving [ 'https://registry.npmjs.org/', './to-no-case' ] +2164 verbose url resolved https://registry.npmjs.org/to-no-case +2165 verbose request where is https://registry.npmjs.org/to-no-case +2166 info trying registry request attempt 1 at 15:14:30 +2167 verbose etag "EPAVN636NU8EGMD42HL11CMF9" +2168 http GET https://registry.npmjs.org/to-no-case +2169 verbose registry.get https://registry.npmjs.org/to-space-case not expired, no request +2170 silly gunzTarPerm extractEntry +2171 silly gunzTarPerm modified mode [ '', 509, 493 ] +2172 verbose request where is /wordwrap +2173 verbose request registry https://registry.npmjs.org/ +2174 verbose url raw /wordwrap +2175 verbose url resolving [ 'https://registry.npmjs.org/', './wordwrap' ] +2176 verbose url resolved https://registry.npmjs.org/wordwrap +2177 verbose request where is https://registry.npmjs.org/wordwrap +2178 info trying registry request attempt 1 at 15:14:30 +2179 verbose etag "BXLEIPULPYSY9Y6K8IUPBMU0J" +2180 http GET https://registry.npmjs.org/wordwrap +2181 verbose registry.get https://registry.npmjs.org/minimist not expired, no request +2182 verbose request where is /recursive-readdir +2183 verbose request registry https://registry.npmjs.org/ +2184 verbose url raw /recursive-readdir +2185 verbose url resolving [ 'https://registry.npmjs.org/', './recursive-readdir' ] +2186 verbose url resolved https://registry.npmjs.org/recursive-readdir +2187 verbose request where is https://registry.npmjs.org/recursive-readdir +2188 info trying registry request attempt 1 at 15:14:30 +2189 verbose etag "C0NRXZ597S1R9MKY5QVMAY9ZA" +2190 http GET https://registry.npmjs.org/recursive-readdir +2191 verbose request where is /lru-cache +2192 verbose request registry https://registry.npmjs.org/ +2193 verbose url raw /lru-cache +2194 verbose url resolving [ 'https://registry.npmjs.org/', './lru-cache' ] +2195 verbose url resolved https://registry.npmjs.org/lru-cache +2196 verbose request where is https://registry.npmjs.org/lru-cache +2197 info trying registry request attempt 1 at 15:14:30 +2198 verbose etag "6YD8G6QB2SQ0RSNCOG67NUYV8" +2199 http GET https://registry.npmjs.org/lru-cache +2200 verbose registry.get https://registry.npmjs.org/async not expired, no request +2201 verbose request where is /readable-stream +2202 verbose request registry https://registry.npmjs.org/ +2203 verbose url raw /readable-stream +2204 verbose url resolving [ 'https://registry.npmjs.org/', './readable-stream' ] +2205 verbose url resolved https://registry.npmjs.org/readable-stream +2206 verbose request where is https://registry.npmjs.org/readable-stream +2207 info trying registry request attempt 1 at 15:14:30 +2208 verbose etag "64HWPM9QDWFPRSQQO5XG0WJFK" +2209 http GET https://registry.npmjs.org/readable-stream +2210 verbose request where is /semver +2211 verbose request registry https://registry.npmjs.org/ +2212 verbose url raw /semver +2213 verbose url resolving [ 'https://registry.npmjs.org/', './semver' ] +2214 verbose url resolved https://registry.npmjs.org/semver +2215 verbose request where is https://registry.npmjs.org/semver +2216 info trying registry request attempt 1 at 15:14:30 +2217 verbose etag "ASSRXC66VGM9KE5PLJPL2WLAJ" +2218 http GET https://registry.npmjs.org/semver +2219 verbose request where is /mute-stream +2220 verbose request registry https://registry.npmjs.org/ +2221 verbose url raw /mute-stream +2222 verbose url resolving [ 'https://registry.npmjs.org/', './mute-stream' ] +2223 verbose url resolved https://registry.npmjs.org/mute-stream +2224 verbose request where is https://registry.npmjs.org/mute-stream +2225 info trying registry request attempt 1 at 15:14:30 +2226 verbose etag "DOQG6GEXY47IRXI3QWNAP991O" +2227 http GET https://registry.npmjs.org/mute-stream +2228 verbose request where is /amdefine +2229 verbose request registry https://registry.npmjs.org/ +2230 verbose url raw /amdefine +2231 verbose url resolving [ 'https://registry.npmjs.org/', './amdefine' ] +2232 verbose url resolved https://registry.npmjs.org/amdefine +2233 verbose request where is https://registry.npmjs.org/amdefine +2234 info trying registry request attempt 1 at 15:14:30 +2235 verbose etag "7YJYSZE54QIQX5HOS2BLMK126" +2236 http GET https://registry.npmjs.org/amdefine +2237 verbose registry.get https://registry.npmjs.org/minimist not expired, no request +2238 verbose request where is /throttleit +2239 verbose request registry https://registry.npmjs.org/ +2240 verbose url raw /throttleit +2241 verbose url resolving [ 'https://registry.npmjs.org/', './throttleit' ] +2242 verbose url resolved https://registry.npmjs.org/throttleit +2243 verbose request where is https://registry.npmjs.org/throttleit +2244 info trying registry request attempt 1 at 15:14:30 +2245 verbose etag "5T0DZZ4VJDS0VO9E6KFN9BDPX" +2246 http GET https://registry.npmjs.org/throttleit +2247 verbose registry.get https://registry.npmjs.org/minimist not expired, no request +2248 verbose request where is /traverse +2249 verbose request registry https://registry.npmjs.org/ +2250 verbose url raw /traverse +2251 verbose url resolving [ 'https://registry.npmjs.org/', './traverse' ] +2252 verbose url resolved https://registry.npmjs.org/traverse +2253 verbose request where is https://registry.npmjs.org/traverse +2254 info trying registry request attempt 1 at 15:14:30 +2255 verbose etag "HEGQ7M3Q2K96ZHIRL3BCF372" +2256 http GET https://registry.npmjs.org/traverse +2257 verbose request where is /charm +2258 verbose request registry https://registry.npmjs.org/ +2259 verbose url raw /charm +2260 verbose url resolving [ 'https://registry.npmjs.org/', './charm' ] +2261 verbose url resolved https://registry.npmjs.org/charm +2262 verbose request where is https://registry.npmjs.org/charm +2263 info trying registry request attempt 1 at 15:14:30 +2264 verbose etag "AK6L4P6TVCDG1DTJJSKUNNOR0" +2265 http GET https://registry.npmjs.org/charm +2266 verbose request where is /deep-is +2267 verbose request registry https://registry.npmjs.org/ +2268 verbose url raw /deep-is +2269 verbose url resolving [ 'https://registry.npmjs.org/', './deep-is' ] +2270 verbose url resolved https://registry.npmjs.org/deep-is +2271 verbose request where is https://registry.npmjs.org/deep-is +2272 info trying registry request attempt 1 at 15:14:30 +2273 verbose etag "74BKFN24HX3Y0BSSE8NYEOHP9" +2274 http GET https://registry.npmjs.org/deep-is +2275 verbose request where is /bunker +2276 verbose request registry https://registry.npmjs.org/ +2277 verbose url raw /bunker +2278 verbose url resolving [ 'https://registry.npmjs.org/', './bunker' ] +2279 verbose url resolved https://registry.npmjs.org/bunker +2280 verbose request where is https://registry.npmjs.org/bunker +2281 info trying registry request attempt 1 at 15:14:30 +2282 verbose etag "56CRJJ6VITUFGXTPL0PSRWWHX" +2283 http GET https://registry.npmjs.org/bunker +2284 verbose registry.get https://registry.npmjs.org/underscore not expired, no request +2285 verbose request where is /inpath +2286 verbose request registry https://registry.npmjs.org/ +2287 verbose url raw /inpath +2288 verbose url resolving [ 'https://registry.npmjs.org/', './inpath' ] +2289 verbose url resolved https://registry.npmjs.org/inpath +2290 verbose request where is https://registry.npmjs.org/inpath +2291 info trying registry request attempt 1 at 15:14:30 +2292 verbose etag "2U89ULXMT749T2HRB16EG76SA" +2293 http GET https://registry.npmjs.org/inpath +2294 verbose registry.get https://registry.npmjs.org/read not expired, no request +2295 verbose request where is /pidof +2296 verbose request registry https://registry.npmjs.org/ +2297 verbose url raw /pidof +2298 verbose url resolving [ 'https://registry.npmjs.org/', './pidof' ] +2299 verbose url resolved https://registry.npmjs.org/pidof +2300 verbose request where is https://registry.npmjs.org/pidof +2301 info trying registry request attempt 1 at 15:14:30 +2302 verbose etag "A1FY3LJTDVP8WS0RBH7T7YMQN" +2303 http GET https://registry.npmjs.org/pidof +2304 verbose registry.get https://registry.npmjs.org/hooker not expired, no request +2305 verbose registry.get https://registry.npmjs.org/async not expired, no request +2306 verbose registry.get https://registry.npmjs.org/exit not expired, no request +2307 verbose registry.get https://registry.npmjs.org/lodash not expired, no request +2308 verbose registry.get https://registry.npmjs.org/underscore.string not expired, no request +2309 verbose registry.get https://registry.npmjs.org/getobject not expired, no request +2310 verbose registry.get https://registry.npmjs.org/which not expired, no request +2311 verbose registry.get https://registry.npmjs.org/lodash not expired, no request +2312 verbose request where is /coffee-script-redux +2313 verbose request registry https://registry.npmjs.org/ +2314 verbose url raw /coffee-script-redux +2315 verbose url resolving [ 'https://registry.npmjs.org/', './coffee-script-redux' ] +2316 verbose url resolved https://registry.npmjs.org/coffee-script-redux +2317 verbose request where is https://registry.npmjs.org/coffee-script-redux +2318 info trying registry request attempt 1 at 15:14:30 +2319 verbose etag "7SFLIAKYNOZWL33H91VE1NQOE" +2320 http GET https://registry.npmjs.org/coffee-script-redux +2321 verbose request where is /estraverse +2322 verbose request registry https://registry.npmjs.org/ +2323 verbose url raw /estraverse +2324 verbose url resolving [ 'https://registry.npmjs.org/', './estraverse' ] +2325 verbose url resolved https://registry.npmjs.org/estraverse +2326 verbose request where is https://registry.npmjs.org/estraverse +2327 info trying registry request attempt 1 at 15:14:30 +2328 verbose etag "COHNCX96YKOQRG3GCW5OOIQH3" +2329 http GET https://registry.npmjs.org/estraverse +2330 verbose registry.get https://registry.npmjs.org/which not expired, no request +2331 verbose request where is /escodegen +2332 verbose request registry https://registry.npmjs.org/ +2333 verbose url raw /escodegen +2334 verbose url resolving [ 'https://registry.npmjs.org/', './escodegen' ] +2335 verbose url resolved https://registry.npmjs.org/escodegen +2336 verbose request where is https://registry.npmjs.org/escodegen +2337 info trying registry request attempt 1 at 15:14:30 +2338 verbose etag "4VE1U0YLYL9LKIY6CR10AKM3J" +2339 http GET https://registry.npmjs.org/escodegen +2340 verbose registry.get https://registry.npmjs.org/istanbul not expired, no request +2341 verbose registry.get https://registry.npmjs.org/optimist not expired, no request +2342 verbose registry.get https://registry.npmjs.org/mkdirp not expired, no request +2343 verbose registry.get https://registry.npmjs.org/esprima not expired, no request +2344 verbose request where is /escodegen +2345 verbose request registry https://registry.npmjs.org/ +2346 verbose url raw /escodegen +2347 verbose url resolving [ 'https://registry.npmjs.org/', './escodegen' ] +2348 verbose url resolved https://registry.npmjs.org/escodegen +2349 verbose request where is https://registry.npmjs.org/escodegen +2350 info trying registry request attempt 1 at 15:14:30 +2351 verbose etag "4VE1U0YLYL9LKIY6CR10AKM3J" +2352 http GET https://registry.npmjs.org/escodegen +2353 verbose request where is /handlebars +2354 verbose request registry https://registry.npmjs.org/ +2355 verbose url raw /handlebars +2356 verbose url resolving [ 'https://registry.npmjs.org/', './handlebars' ] +2357 verbose url resolved https://registry.npmjs.org/handlebars +2358 verbose request where is https://registry.npmjs.org/handlebars +2359 info trying registry request attempt 1 at 15:14:30 +2360 verbose etag "2EPJS9TIRC62VBZKIBRCSLQYH" +2361 http GET https://registry.npmjs.org/handlebars +2362 verbose registry.get https://registry.npmjs.org/mkdirp not expired, no request +2363 verbose registry.get https://registry.npmjs.org/nopt not expired, no request +2364 verbose request where is /fileset +2365 verbose request registry https://registry.npmjs.org/ +2366 verbose url raw /fileset +2367 verbose url resolving [ 'https://registry.npmjs.org/', './fileset' ] +2368 verbose url resolved https://registry.npmjs.org/fileset +2369 verbose request where is https://registry.npmjs.org/fileset +2370 info trying registry request attempt 1 at 15:14:30 +2371 verbose etag "2GRJF38NRU8K84C14U03SU5I4" +2372 http GET https://registry.npmjs.org/fileset +2373 verbose registry.get https://registry.npmjs.org/which not expired, no request +2374 verbose request where is /abbrev +2375 verbose request registry https://registry.npmjs.org/ +2376 verbose url raw /abbrev +2377 verbose url resolving [ 'https://registry.npmjs.org/', './abbrev' ] +2378 verbose url resolved https://registry.npmjs.org/abbrev +2379 verbose request where is https://registry.npmjs.org/abbrev +2380 info trying registry request attempt 1 at 15:14:30 +2381 verbose etag "CY41WQX3SN6P2Z9FH9M7NUQHN" +2382 http GET https://registry.npmjs.org/abbrev +2383 verbose request where is /wordwrap +2384 verbose request registry https://registry.npmjs.org/ +2385 verbose url raw /wordwrap +2386 verbose url resolving [ 'https://registry.npmjs.org/', './wordwrap' ] +2387 verbose url resolved https://registry.npmjs.org/wordwrap +2388 verbose request where is https://registry.npmjs.org/wordwrap +2389 info trying registry request attempt 1 at 15:14:30 +2390 verbose etag "BXLEIPULPYSY9Y6K8IUPBMU0J" +2391 http GET https://registry.npmjs.org/wordwrap +2392 verbose registry.get https://registry.npmjs.org/async not expired, no request +2393 verbose registry.get https://registry.npmjs.org/resolve not expired, no request +2394 verbose request where is /once +2395 verbose request registry https://registry.npmjs.org/ +2396 verbose url raw /once +2397 verbose url resolving [ 'https://registry.npmjs.org/', './once' ] +2398 verbose url resolved https://registry.npmjs.org/once +2399 verbose request where is https://registry.npmjs.org/once +2400 info trying registry request attempt 1 at 15:14:30 +2401 verbose etag "6TIS5LZZJJ57TQMU4V53YO2P5" +2402 http GET https://registry.npmjs.org/once +2403 verbose registry.get https://registry.npmjs.org/js-yaml not expired, no request +2404 verbose request where is /css-color-function +2405 verbose request registry https://registry.npmjs.org/ +2406 verbose url raw /css-color-function +2407 verbose url resolving [ 'https://registry.npmjs.org/', './css-color-function' ] +2408 verbose url resolved https://registry.npmjs.org/css-color-function +2409 verbose request where is https://registry.npmjs.org/css-color-function +2410 info trying registry request attempt 1 at 15:14:30 +2411 verbose etag "7VGOP7KYZMOL5909DEXTBPR4F" +2412 http GET https://registry.npmjs.org/css-color-function +2413 verbose request where is /postcss +2414 verbose request registry https://registry.npmjs.org/ +2415 verbose url raw /postcss +2416 verbose url resolving [ 'https://registry.npmjs.org/', './postcss' ] +2417 verbose url resolved https://registry.npmjs.org/postcss +2418 verbose request where is https://registry.npmjs.org/postcss +2419 info trying registry request attempt 1 at 15:14:30 +2420 verbose etag "CHBDQOWYV6KJ67G72KZ2O7DND" +2421 http GET https://registry.npmjs.org/postcss +2422 verbose request where is /caniuse-db +2423 verbose request registry https://registry.npmjs.org/ +2424 verbose url raw /caniuse-db +2425 verbose url resolving [ 'https://registry.npmjs.org/', './caniuse-db' ] +2426 verbose url resolved https://registry.npmjs.org/caniuse-db +2427 verbose request where is https://registry.npmjs.org/caniuse-db +2428 info trying registry request attempt 1 at 15:14:30 +2429 verbose etag "CQPTODEQ7RPUSADIQQXB6IZQ" +2430 http GET https://registry.npmjs.org/caniuse-db +2431 verbose request where is /balanced-match +2432 verbose request registry https://registry.npmjs.org/ +2433 verbose url raw /balanced-match +2434 verbose url resolving [ 'https://registry.npmjs.org/', './balanced-match' ] +2435 verbose url resolved https://registry.npmjs.org/balanced-match +2436 verbose request where is https://registry.npmjs.org/balanced-match +2437 info trying registry request attempt 1 at 15:14:30 +2438 verbose etag "EZUFM9SYH8LMSJ7SI2N6V5DX8" +2439 http GET https://registry.npmjs.org/balanced-match +2440 verbose request where is /balanced-match +2441 verbose request registry https://registry.npmjs.org/ +2442 verbose url raw /balanced-match +2443 verbose url resolving [ 'https://registry.npmjs.org/', './balanced-match' ] +2444 verbose url resolved https://registry.npmjs.org/balanced-match +2445 verbose request where is https://registry.npmjs.org/balanced-match +2446 info trying registry request attempt 1 at 15:14:30 +2447 verbose etag "EZUFM9SYH8LMSJ7SI2N6V5DX8" +2448 http GET https://registry.npmjs.org/balanced-match +2449 verbose request where is /rework-visit +2450 verbose request registry https://registry.npmjs.org/ +2451 verbose url raw /rework-visit +2452 verbose url resolving [ 'https://registry.npmjs.org/', './rework-visit' ] +2453 verbose url resolved https://registry.npmjs.org/rework-visit +2454 verbose request where is https://registry.npmjs.org/rework-visit +2455 info trying registry request attempt 1 at 15:14:30 +2456 verbose etag "2U2M4DQXLN32Y1EQYP9L93A97" +2457 http GET https://registry.npmjs.org/rework-visit +2458 verbose request where is /rework-visit +2459 verbose request registry https://registry.npmjs.org/ +2460 verbose url raw /rework-visit +2461 verbose url resolving [ 'https://registry.npmjs.org/', './rework-visit' ] +2462 verbose url resolved https://registry.npmjs.org/rework-visit +2463 verbose request where is https://registry.npmjs.org/rework-visit +2464 info trying registry request attempt 1 at 15:14:30 +2465 verbose etag "2U2M4DQXLN32Y1EQYP9L93A97" +2466 http GET https://registry.npmjs.org/rework-visit +2467 verbose request where is /balanced-match +2468 verbose request registry https://registry.npmjs.org/ +2469 verbose url raw /balanced-match +2470 verbose url resolving [ 'https://registry.npmjs.org/', './balanced-match' ] +2471 verbose url resolved https://registry.npmjs.org/balanced-match +2472 verbose request where is https://registry.npmjs.org/balanced-match +2473 info trying registry request attempt 1 at 15:14:30 +2474 verbose etag "EZUFM9SYH8LMSJ7SI2N6V5DX8" +2475 http GET https://registry.npmjs.org/balanced-match +2476 silly gunzTarPerm extractEntry README.md +2477 silly gunzTarPerm modified mode [ 'README.md', 436, 420 ] +2478 silly gunzTarPerm extractEntry package.json +2479 silly gunzTarPerm modified mode [ 'package.json', 436, 420 ] +2480 silly gunzTarPerm extractEntry taffy-test.html +2481 silly gunzTarPerm modified mode [ 'taffy-test.html', 436, 420 ] +2482 verbose registry.get https://registry.npmjs.org/inherits not expired, no request +2483 verbose request where is /config-chain +2484 verbose request registry https://registry.npmjs.org/ +2485 verbose url raw /config-chain +2486 verbose url resolving [ 'https://registry.npmjs.org/', './config-chain' ] +2487 verbose url resolved https://registry.npmjs.org/config-chain +2488 verbose request where is https://registry.npmjs.org/config-chain +2489 info trying registry request attempt 1 at 15:14:30 +2490 verbose etag "EKPOBV34CCDNYDBQXRIAJQE90" +2491 http GET https://registry.npmjs.org/config-chain +2492 verbose request where is /ini +2493 verbose request registry https://registry.npmjs.org/ +2494 verbose url raw /ini +2495 verbose url resolving [ 'https://registry.npmjs.org/', './ini' ] +2496 verbose url resolved https://registry.npmjs.org/ini +2497 verbose request where is https://registry.npmjs.org/ini +2498 info trying registry request attempt 1 at 15:14:30 +2499 verbose etag "754C7G0ESHIITOZZPDILT5SFP" +2500 http GET https://registry.npmjs.org/ini +2501 verbose registry.get https://registry.npmjs.org/mkdirp not expired, no request +2502 verbose registry.get https://registry.npmjs.org/nopt not expired, no request +2503 verbose request where is /once +2504 verbose request registry https://registry.npmjs.org/ +2505 verbose url raw /once +2506 verbose url resolving [ 'https://registry.npmjs.org/', './once' ] +2507 verbose url resolved https://registry.npmjs.org/once +2508 verbose request where is https://registry.npmjs.org/once +2509 info trying registry request attempt 1 at 15:14:30 +2510 verbose etag "6TIS5LZZJJ57TQMU4V53YO2P5" +2511 http GET https://registry.npmjs.org/once +2512 verbose request where is /osenv +2513 verbose request registry https://registry.npmjs.org/ +2514 verbose url raw /osenv +2515 verbose url resolving [ 'https://registry.npmjs.org/', './osenv' ] +2516 verbose url resolved https://registry.npmjs.org/osenv +2517 verbose request where is https://registry.npmjs.org/osenv +2518 info trying registry request attempt 1 at 15:14:30 +2519 verbose etag "AZU7G63I6YW7SNUHRH5KD9HZU" +2520 http GET https://registry.npmjs.org/osenv +2521 verbose request where is /semver +2522 verbose request registry https://registry.npmjs.org/ +2523 verbose url raw /semver +2524 verbose url resolving [ 'https://registry.npmjs.org/', './semver' ] +2525 verbose url resolved https://registry.npmjs.org/semver +2526 verbose request where is https://registry.npmjs.org/semver +2527 info trying registry request attempt 1 at 15:14:31 +2528 verbose etag "ASSRXC66VGM9KE5PLJPL2WLAJ" +2529 http GET https://registry.npmjs.org/semver +2530 verbose request where is /uid-number +2531 verbose request registry https://registry.npmjs.org/ +2532 verbose url raw /uid-number +2533 verbose url resolving [ 'https://registry.npmjs.org/', './uid-number' ] +2534 verbose url resolved https://registry.npmjs.org/uid-number +2535 verbose request where is https://registry.npmjs.org/uid-number +2536 info trying registry request attempt 1 at 15:14:31 +2537 verbose etag "99K6WWBTV8N7ZCPWAV4NFEONE" +2538 http GET https://registry.npmjs.org/uid-number +2539 verbose request where is /abbrev +2540 verbose request registry https://registry.npmjs.org/ +2541 verbose url raw /abbrev +2542 verbose url resolving [ 'https://registry.npmjs.org/', './abbrev' ] +2543 verbose url resolved https://registry.npmjs.org/abbrev +2544 verbose request where is https://registry.npmjs.org/abbrev +2545 info trying registry request attempt 1 at 15:14:31 +2546 verbose etag "CY41WQX3SN6P2Z9FH9M7NUQHN" +2547 http GET https://registry.npmjs.org/abbrev +2548 silly gunzTarPerm extractEntry taffy.js +2549 silly gunzTarPerm modified mode [ 'taffy.js', 436, 420 ] +2550 verbose request where is /wordwrap +2551 verbose request registry https://registry.npmjs.org/ +2552 verbose url raw /wordwrap +2553 verbose url resolving [ 'https://registry.npmjs.org/', './wordwrap' ] +2554 verbose url resolved https://registry.npmjs.org/wordwrap +2555 verbose request where is https://registry.npmjs.org/wordwrap +2556 info trying registry request attempt 1 at 15:14:31 +2557 verbose etag "BXLEIPULPYSY9Y6K8IUPBMU0J" +2558 http GET https://registry.npmjs.org/wordwrap +2559 verbose registry.get https://registry.npmjs.org/minimist not expired, no request +2560 verbose registry.get https://registry.npmjs.org/minimist not expired, no request +2561 verbose request where is /abbrev +2562 verbose request registry https://registry.npmjs.org/ +2563 verbose url raw /abbrev +2564 verbose url resolving [ 'https://registry.npmjs.org/', './abbrev' ] +2565 verbose url resolved https://registry.npmjs.org/abbrev +2566 verbose request where is https://registry.npmjs.org/abbrev +2567 info trying registry request attempt 1 at 15:14:31 +2568 verbose etag "CY41WQX3SN6P2Z9FH9M7NUQHN" +2569 http GET https://registry.npmjs.org/abbrev +2570 verbose registry.get https://registry.npmjs.org/esprima not expired, no request +2571 verbose request where is /argparse +2572 verbose request registry https://registry.npmjs.org/ +2573 verbose url raw /argparse +2574 verbose url resolving [ 'https://registry.npmjs.org/', './argparse' ] +2575 verbose url resolved https://registry.npmjs.org/argparse +2576 verbose request where is https://registry.npmjs.org/argparse +2577 info trying registry request attempt 1 at 15:14:31 +2578 verbose etag "8HKRQPWF6RXGLV2K36IWPQ7PE" +2579 http GET https://registry.npmjs.org/argparse +2580 verbose tar unpack /tmp/npm-17670-yMiqFMg9/github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c +2581 silly lockFile c073b7c1-d653b11e9419241a9d726af7c-unpack tar:///tmp/npm-17670-yMiqFMg9/github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c-unpack +2582 verbose lock tar:///tmp/npm-17670-yMiqFMg9/github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c-unpack /root/.npm/c073b7c1-d653b11e9419241a9d726af7c-unpack.lock +2583 silly lockFile 772ed5b9-243f29bd653b11e9419241a9d726af7c tar:///tmp/npm-17670-yMiqFMg9/github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c +2584 verbose lock tar:///tmp/npm-17670-yMiqFMg9/github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c /root/.npm/772ed5b9-243f29bd653b11e9419241a9d726af7c.lock +2585 silly lockFile e0ffc318-ic-taffydb-tarball-master-unpack tar:///tmp/npm-17670-yMiqFMg9/github.com/hegemonic/taffydb/tarball/master-unpack +2586 silly lockFile e0ffc318-ic-taffydb-tarball-master-unpack tar:///tmp/npm-17670-yMiqFMg9/github.com/hegemonic/taffydb/tarball/master-unpack +2587 silly lockFile 10e5e6ab-hegemonic-taffydb-tarball-master tar:///tmp/npm-17670-yMiqFMg9/github.com/hegemonic/taffydb/tarball/master +2588 silly lockFile 10e5e6ab-hegemonic-taffydb-tarball-master tar:///tmp/npm-17670-yMiqFMg9/github.com/hegemonic/taffydb/tarball/master +2589 silly gunzTarPerm modes [ '755', '644' ] +2590 silly gunzTarPerm extractEntry +2591 silly gunzTarPerm modified mode [ '', 509, 493 ] +2592 silly lockFile b85c942d-hegemonic-taffydb-tarball-master https://github.com/hegemonic/taffydb/tarball/master +2593 silly lockFile b85c942d-hegemonic-taffydb-tarball-master https://github.com/hegemonic/taffydb/tarball/master +2594 silly gunzTarPerm extractEntry .eslintrc +2595 silly gunzTarPerm modified mode [ '.eslintrc', 436, 420 ] +2596 silly gunzTarPerm extractEntry .gitignore +2597 silly gunzTarPerm modified mode [ '.gitignore', 436, 420 ] +2598 silly gunzTarPerm extractEntry .npmignore +2599 silly gunzTarPerm modified mode [ '.npmignore', 436, 420 ] +2600 silly gunzTarPerm extractEntry .travis.yml +2601 silly gunzTarPerm modified mode [ '.travis.yml', 436, 420 ] +2602 silly gunzTarPerm extractEntry ChangeLog +2603 silly gunzTarPerm modified mode [ 'ChangeLog', 436, 420 ] +2604 silly gunzTarPerm extractEntry LICENSE.BSD +2605 silly gunzTarPerm modified mode [ 'LICENSE.BSD', 436, 420 ] +2606 silly gunzTarPerm extractEntry README.md +2607 silly gunzTarPerm modified mode [ 'README.md', 436, 420 ] +2608 silly gunzTarPerm extractEntry assets/ +2609 silly gunzTarPerm modified mode [ 'assets/', 509, 493 ] +2610 silly gunzTarPerm extractEntry assets/foundation/ +2611 silly gunzTarPerm modified mode [ 'assets/foundation/', 509, 493 ] +2612 http 304 https://registry.npmjs.org/mime-types +2613 silly registry.get cb [ 304, +2613 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +2613 silly registry.get server: 'Apache', +2613 silly registry.get via: '1.1 varnish', +2613 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:13:49 GMT', +2613 silly registry.get 'cache-control': 'max-age=60', +2613 silly registry.get etag: '"B5U64GWQ6AQNEF9M2XN8BFUJZ"', +2613 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +2613 silly registry.get 'x-cache': 'HIT', +2613 silly registry.get 'x-cache-hits': '3', +2613 silly registry.get 'x-timer': 'S1411067671.066856,VS0,VE0', +2613 silly registry.get vary: 'Accept', +2613 silly registry.get 'content-length': '0', +2613 silly registry.get 'keep-alive': 'timeout=10, max=50', +2613 silly registry.get connection: 'Keep-Alive' } ] +2614 verbose etag https://registry.npmjs.org/mime-types from cache +2615 silly gunzTarPerm extractEntry assets/foundation/foundation.min.css +2616 silly gunzTarPerm modified mode [ 'assets/foundation/foundation.min.css', 436, 420 ] +2617 silly gunzTarPerm extractEntry assets/images/ +2618 silly gunzTarPerm modified mode [ 'assets/images/', 509, 493 ] +2619 http 304 https://registry.npmjs.org/mime-types +2620 silly registry.get cb [ 304, +2620 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +2620 silly registry.get server: 'Apache', +2620 silly registry.get via: '1.1 varnish', +2620 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:13:50 GMT', +2620 silly registry.get 'cache-control': 'max-age=60', +2620 silly registry.get etag: '"B5U64GWQ6AQNEF9M2XN8BFUJZ"', +2620 silly registry.get 'x-served-by': 'cache-dfw1824-DFW', +2620 silly registry.get 'x-cache': 'HIT', +2620 silly registry.get 'x-cache-hits': '2', +2620 silly registry.get 'x-timer': 'S1411067671.068939,VS0,VE0', +2620 silly registry.get vary: 'Accept', +2620 silly registry.get 'content-length': '0', +2620 silly registry.get 'keep-alive': 'timeout=10, max=50', +2620 silly registry.get connection: 'Keep-Alive' } ] +2621 verbose etag https://registry.npmjs.org/mime-types from cache +2622 http 304 https://registry.npmjs.org/ee-first +2623 silly registry.get cb [ 304, +2623 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +2623 silly registry.get server: 'Apache', +2623 silly registry.get via: '1.1 varnish', +2623 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +2623 silly registry.get 'cache-control': 'max-age=60', +2623 silly registry.get etag: '"846IVN2KJTCG8QAR9U2ZHHHP8"', +2623 silly registry.get 'x-served-by': 'cache-dfw1820-DFW', +2623 silly registry.get 'x-cache': 'HIT', +2623 silly registry.get 'x-cache-hits': '1', +2623 silly registry.get 'x-timer': 'S1411067671.068874,VS0,VE0', +2623 silly registry.get vary: 'Accept', +2623 silly registry.get 'content-length': '0', +2623 silly registry.get 'keep-alive': 'timeout=10, max=50', +2623 silly registry.get connection: 'Keep-Alive' } ] +2624 verbose etag https://registry.npmjs.org/ee-first from cache +2625 silly gunzTarPerm extractEntry assets/images/autocomplete.png +2626 silly gunzTarPerm modified mode [ 'assets/images/autocomplete.png', 436, 420 ] +2627 silly gunzTarPerm extractEntry assets/json2.js +2628 silly gunzTarPerm modified mode [ 'assets/json2.js', 436, 420 ] +2629 silly gunzTarPerm extractEntry assets/orion/ +2630 silly gunzTarPerm modified mode [ 'assets/orion/', 509, 493 ] +2631 silly gunzTarPerm extractEntry assets/orion/built-editor.css +2632 silly gunzTarPerm modified mode [ 'assets/orion/built-editor.css', 436, 420 ] +2633 silly gunzTarPerm extractEntry assets/orion/built-editor.min.js +2634 silly gunzTarPerm modified mode [ 'assets/orion/built-editor.min.js', 436, 420 ] +2635 silly gunzTarPerm extractEntry assets/orion/contentassist/ +2636 silly gunzTarPerm modified mode [ 'assets/orion/contentassist/', 509, 493 ] +2637 silly gunzTarPerm extractEntry assets/orion/contentassist/doctrine.js +2638 silly gunzTarPerm modified mode [ 'assets/orion/contentassist/doctrine.js', 436, 420 ] +2639 silly gunzTarPerm extractEntry assets/orion/contentassist/esprima.js +2640 silly gunzTarPerm modified mode [ 'assets/orion/contentassist/esprima.js', 436, 420 ] +2641 silly gunzTarPerm extractEntry assets/orion/contentassist/esprimaJsContentAssist.js +2642 silly gunzTarPerm modified mode [ 'assets/orion/contentassist/esprimaJsContentAssist.js', +2642 silly gunzTarPerm 436, +2642 silly gunzTarPerm 420 ] +2643 silly gunzTarPerm extractEntry assets/orion/contentassist/esprimaVisitor.js +2644 silly gunzTarPerm modified mode [ 'assets/orion/contentassist/esprimaVisitor.js', 436, 420 ] +2645 http 304 https://registry.npmjs.org/negotiator +2646 silly registry.get cb [ 304, +2646 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +2646 silly registry.get server: 'Apache', +2646 silly registry.get via: '1.1 varnish', +2646 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +2646 silly registry.get 'cache-control': 'max-age=60', +2646 silly registry.get etag: '"777L0S4UKN6FYD9Z9L2TJQLN3"', +2646 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +2646 silly registry.get 'x-cache': 'HIT', +2646 silly registry.get 'x-cache-hits': '1', +2646 silly registry.get 'x-timer': 'S1411067671.070339,VS0,VE43', +2646 silly registry.get vary: 'Accept', +2646 silly registry.get 'content-length': '0', +2646 silly registry.get 'keep-alive': 'timeout=10, max=50', +2646 silly registry.get connection: 'Keep-Alive' } ] +2647 verbose etag https://registry.npmjs.org/negotiator from cache +2648 silly gunzTarPerm extractEntry assets/orion/contentassist/proposalUtils.js +2649 silly gunzTarPerm modified mode [ 'assets/orion/contentassist/proposalUtils.js', 436, 420 ] +2650 silly gunzTarPerm extractEntry assets/orion/contentassist/types.js +2651 silly gunzTarPerm modified mode [ 'assets/orion/contentassist/types.js', 436, 420 ] +2652 silly gunzTarPerm extractEntry assets/orion/customeditor.js +2653 silly gunzTarPerm modified mode [ 'assets/orion/customeditor.js', 436, 420 ] +2654 silly gunzTarPerm extractEntry assets/prettify/ +2655 silly gunzTarPerm modified mode [ 'assets/prettify/', 509, 493 ] +2656 silly gunzTarPerm extractEntry assets/prettify/prettify.css +2657 silly gunzTarPerm modified mode [ 'assets/prettify/prettify.css', 436, 420 ] +2658 silly gunzTarPerm extractEntry assets/prettify/prettify.js +2659 silly gunzTarPerm modified mode [ 'assets/prettify/prettify.js', 436, 420 ] +2660 silly gunzTarPerm extractEntry assets/require.js +2661 silly gunzTarPerm modified mode [ 'assets/require.js', 436, 420 ] +2662 silly gunzTarPerm extractEntry assets/style.css +2663 silly gunzTarPerm modified mode [ 'assets/style.css', 436, 420 ] +2664 silly gunzTarPerm extractEntry bin/ +2665 silly gunzTarPerm modified mode [ 'bin/', 509, 493 ] +2666 http 304 https://registry.npmjs.org/ipaddr.js +2667 silly registry.get cb [ 304, +2667 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +2667 silly registry.get server: 'Apache', +2667 silly registry.get via: '1.1 varnish', +2667 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +2667 silly registry.get 'cache-control': 'max-age=60', +2667 silly registry.get etag: '"AABFRJK3K2AH3K7GGM3Y9I7AO"', +2667 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +2667 silly registry.get 'x-cache': 'HIT', +2667 silly registry.get 'x-cache-hits': '1', +2667 silly registry.get 'x-timer': 'S1411067671.128020,VS0,VE0', +2667 silly registry.get vary: 'Accept', +2667 silly registry.get 'content-length': '0', +2667 silly registry.get 'keep-alive': 'timeout=10, max=49', +2667 silly registry.get connection: 'Keep-Alive' } ] +2668 verbose etag https://registry.npmjs.org/ipaddr.js from cache +2669 silly gunzTarPerm extractEntry bin/esparse.js +2670 silly gunzTarPerm modified mode [ 'bin/esparse.js', 509, 493 ] +2671 silly gunzTarPerm extractEntry bin/esvalidate.js +2672 silly gunzTarPerm modified mode [ 'bin/esvalidate.js', 509, 493 ] +2673 silly gunzTarPerm extractEntry component.json +2674 silly gunzTarPerm modified mode [ 'component.json', 436, 420 ] +2675 silly gunzTarPerm extractEntry demo/ +2676 silly gunzTarPerm modified mode [ 'demo/', 509, 493 ] +2677 silly gunzTarPerm extractEntry demo/autocomplete.html +2678 silly gunzTarPerm modified mode [ 'demo/autocomplete.html', 436, 420 ] +2679 silly gunzTarPerm extractEntry demo/collector.html +2680 silly gunzTarPerm modified mode [ 'demo/collector.html', 436, 420 ] +2681 silly gunzTarPerm extractEntry demo/collector.js +2682 silly gunzTarPerm modified mode [ 'demo/collector.js', 436, 420 ] +2683 silly gunzTarPerm extractEntry demo/functiontrace.html +2684 silly gunzTarPerm modified mode [ 'demo/functiontrace.html', 436, 420 ] +2685 http 304 https://registry.npmjs.org/destroy +2686 silly registry.get cb [ 304, +2686 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +2686 silly registry.get server: 'Apache', +2686 silly registry.get via: '1.1 varnish', +2686 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +2686 silly registry.get 'cache-control': 'max-age=60', +2686 silly registry.get etag: '"50Y39IQEZLEFEJDYESTKCS8VE"', +2686 silly registry.get 'x-served-by': 'cache-dfw1824-DFW', +2686 silly registry.get 'x-cache': 'HIT', +2686 silly registry.get 'x-cache-hits': '1', +2686 silly registry.get 'x-timer': 'S1411067671.132578,VS0,VE0', +2686 silly registry.get vary: 'Accept', +2686 silly registry.get 'content-length': '0', +2686 silly registry.get 'keep-alive': 'timeout=10, max=49', +2686 silly registry.get connection: 'Keep-Alive' } ] +2687 verbose etag https://registry.npmjs.org/destroy from cache +2688 silly gunzTarPerm extractEntry demo/functiontrace.js +2689 silly gunzTarPerm modified mode [ 'demo/functiontrace.js', 436, 420 ] +2690 silly gunzTarPerm extractEntry demo/highlight.html +2691 silly gunzTarPerm modified mode [ 'demo/highlight.html', 436, 420 ] +2692 silly gunzTarPerm extractEntry demo/highlight.js +2693 silly gunzTarPerm modified mode [ 'demo/highlight.js', 436, 420 ] +2694 silly gunzTarPerm extractEntry demo/index.html +2695 silly gunzTarPerm modified mode [ 'demo/index.html', 436, 420 ] +2696 silly gunzTarPerm extractEntry demo/minify.html +2697 silly gunzTarPerm modified mode [ 'demo/minify.html', 436, 420 ] +2698 silly gunzTarPerm extractEntry demo/minify.js +2699 silly gunzTarPerm modified mode [ 'demo/minify.js', 436, 420 ] +2700 silly gunzTarPerm extractEntry demo/parse.css +2701 silly gunzTarPerm modified mode [ 'demo/parse.css', 436, 420 ] +2702 silly gunzTarPerm extractEntry demo/parse.html +2703 silly gunzTarPerm modified mode [ 'demo/parse.html', 436, 420 ] +2704 silly gunzTarPerm extractEntry demo/parse.js +2705 silly gunzTarPerm modified mode [ 'demo/parse.js', 436, 420 ] +2706 silly gunzTarPerm extractEntry demo/precedence.html +2707 silly gunzTarPerm modified mode [ 'demo/precedence.html', 436, 420 ] +2708 silly gunzTarPerm extractEntry demo/precedence.js +2709 silly gunzTarPerm modified mode [ 'demo/precedence.js', 436, 420 ] +2710 silly gunzTarPerm extractEntry demo/rewrite.html +2711 silly gunzTarPerm modified mode [ 'demo/rewrite.html', 436, 420 ] +2712 silly gunzTarPerm extractEntry demo/rewrite.js +2713 silly gunzTarPerm modified mode [ 'demo/rewrite.js', 436, 420 ] +2714 silly gunzTarPerm extractEntry demo/transpile.html +2715 silly gunzTarPerm modified mode [ 'demo/transpile.html', 436, 420 ] +2716 silly gunzTarPerm extractEntry demo/transpile.js +2717 silly gunzTarPerm modified mode [ 'demo/transpile.js', 436, 420 ] +2718 silly gunzTarPerm extractEntry demo/validate.html +2719 silly gunzTarPerm modified mode [ 'demo/validate.html', 436, 420 ] +2720 http 304 https://registry.npmjs.org/css +2721 silly registry.get cb [ 304, +2721 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +2721 silly registry.get server: 'Apache', +2721 silly registry.get via: '1.1 varnish', +2721 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:25 GMT', +2721 silly registry.get 'cache-control': 'max-age=60', +2721 silly registry.get etag: '"3JKMNW0FVVDQS5ZKDCPPNJ0PN"', +2721 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +2721 silly registry.get 'x-cache': 'HIT', +2721 silly registry.get 'x-cache-hits': '2', +2721 silly registry.get 'x-timer': 'S1411067671.188479,VS0,VE0', +2721 silly registry.get vary: 'Accept', +2721 silly registry.get 'content-length': '0', +2721 silly registry.get 'keep-alive': 'timeout=10, max=48', +2721 silly registry.get connection: 'Keep-Alive' } ] +2722 verbose etag https://registry.npmjs.org/css from cache +2723 silly gunzTarPerm extractEntry demo/validate.js +2724 silly gunzTarPerm modified mode [ 'demo/validate.js', 436, 420 ] +2725 http 304 https://registry.npmjs.org/convert-source-map +2726 silly registry.get cb [ 304, +2726 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +2726 silly registry.get server: 'Apache', +2726 silly registry.get via: '1.1 varnish', +2726 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 18:28:28 GMT', +2726 silly registry.get 'cache-control': 'max-age=60', +2726 silly registry.get etag: '"728SNU7BT1CNJR7S68159LD2E"', +2726 silly registry.get 'x-served-by': 'cache-dfw1824-DFW', +2726 silly registry.get 'x-cache': 'HIT', +2726 silly registry.get 'x-cache-hits': '51', +2726 silly registry.get 'x-timer': 'S1411067671.192675,VS0,VE0', +2726 silly registry.get vary: 'Accept', +2726 silly registry.get 'content-length': '0', +2726 silly registry.get 'keep-alive': 'timeout=10, max=48', +2726 silly registry.get connection: 'Keep-Alive' } ] +2727 verbose etag https://registry.npmjs.org/convert-source-map from cache +2728 verbose request where is /source-map-resolve +2729 verbose request registry https://registry.npmjs.org/ +2730 verbose url raw /source-map-resolve +2731 verbose url resolving [ 'https://registry.npmjs.org/', './source-map-resolve' ] +2732 verbose url resolved https://registry.npmjs.org/source-map-resolve +2733 verbose request where is https://registry.npmjs.org/source-map-resolve +2734 info trying registry request attempt 1 at 15:14:31 +2735 verbose etag "472ZFA0TX4Z6BZJYCCDUNMN1B" +2736 http GET https://registry.npmjs.org/source-map-resolve +2737 verbose request where is /urix +2738 verbose request registry https://registry.npmjs.org/ +2739 verbose url raw /urix +2740 verbose url resolving [ 'https://registry.npmjs.org/', './urix' ] +2741 verbose url resolved https://registry.npmjs.org/urix +2742 verbose request where is https://registry.npmjs.org/urix +2743 info trying registry request attempt 1 at 15:14:31 +2744 verbose etag "35KRF5V0AFEWMEL158IFFJM2I" +2745 http GET https://registry.npmjs.org/urix +2746 verbose registry.get https://registry.npmjs.org/inherits not expired, no request +2747 verbose registry.get https://registry.npmjs.org/source-map not expired, no request +2748 http 304 https://registry.npmjs.org/component-type +2749 silly registry.get cb [ 304, +2749 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +2749 silly registry.get server: 'Apache', +2749 silly registry.get via: '1.1 varnish', +2749 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +2749 silly registry.get 'cache-control': 'max-age=60', +2749 silly registry.get etag: '"7P02BBKDTR44SEUISD0LZUIW8"', +2749 silly registry.get 'x-served-by': 'cache-dfw1820-DFW', +2749 silly registry.get 'x-cache': 'HIT', +2749 silly registry.get 'x-cache-hits': '1', +2749 silly registry.get 'x-timer': 'S1411067671.137432,VS0,VE64', +2749 silly registry.get vary: 'Accept', +2749 silly registry.get 'content-length': '0', +2749 silly registry.get 'keep-alive': 'timeout=10, max=49', +2749 silly registry.get connection: 'Keep-Alive' } ] +2750 verbose etag https://registry.npmjs.org/component-type from cache +2751 verbose request where is /amdefine +2752 verbose request registry https://registry.npmjs.org/ +2753 verbose url raw /amdefine +2754 verbose url resolving [ 'https://registry.npmjs.org/', './amdefine' ] +2755 verbose url resolved https://registry.npmjs.org/amdefine +2756 verbose request where is https://registry.npmjs.org/amdefine +2757 info trying registry request attempt 1 at 15:14:31 +2758 verbose etag "7YJYSZE54QIQX5HOS2BLMK126" +2759 http GET https://registry.npmjs.org/amdefine +2760 silly gunzTarPerm extractEntry doc/ +2761 silly gunzTarPerm modified mode [ 'doc/', 509, 493 ] +2762 silly gunzTarPerm extractEntry doc/index.html +2763 silly gunzTarPerm modified mode [ 'doc/index.html', 436, 420 ] +2764 silly gunzTarPerm extractEntry esprima.js +2765 silly gunzTarPerm modified mode [ 'esprima.js', 436, 420 ] +2766 silly gunzTarPerm extractEntry examples/ +2767 silly gunzTarPerm modified mode [ 'examples/', 509, 493 ] +2768 silly gunzTarPerm extractEntry examples/detectnestedternary.js +2769 silly gunzTarPerm modified mode [ 'examples/detectnestedternary.js', 436, 420 ] +2770 silly gunzTarPerm extractEntry examples/findbooleantrap.js +2771 silly gunzTarPerm modified mode [ 'examples/findbooleantrap.js', 436, 420 ] +2772 silly gunzTarPerm extractEntry examples/tokendist.js +2773 silly gunzTarPerm modified mode [ 'examples/tokendist.js', 436, 420 ] +2774 silly gunzTarPerm extractEntry index.html +2775 silly gunzTarPerm modified mode [ 'index.html', 436, 420 ] +2776 silly gunzTarPerm extractEntry package.json +2777 silly gunzTarPerm modified mode [ 'package.json', 436, 420 ] +2778 silly gunzTarPerm extractEntry test/ +2779 silly gunzTarPerm modified mode [ 'test/', 509, 493 ] +2780 silly gunzTarPerm extractEntry test/3rdparty/ +2781 silly gunzTarPerm modified mode [ 'test/3rdparty/', 509, 493 ] +2782 silly gunzTarPerm extractEntry test/3rdparty/XMLHttpRequest.js +2783 silly gunzTarPerm modified mode [ 'test/3rdparty/XMLHttpRequest.js', 436, 420 ] +2784 silly gunzTarPerm extractEntry test/3rdparty/acorn.js +2785 silly gunzTarPerm modified mode [ 'test/3rdparty/acorn.js', 436, 420 ] +2786 silly gunzTarPerm extractEntry test/3rdparty/angular-1.0.2.js +2787 silly gunzTarPerm modified mode [ 'test/3rdparty/angular-1.0.2.js', 436, 420 ] +2788 silly gunzTarPerm extractEntry test/3rdparty/backbone-0.9.2.js +2789 silly gunzTarPerm modified mode [ 'test/3rdparty/backbone-0.9.2.js', 436, 420 ] +2790 silly gunzTarPerm extractEntry test/3rdparty/benchmark.js +2791 silly gunzTarPerm modified mode [ 'test/3rdparty/benchmark.js', 436, 420 ] +2792 silly gunzTarPerm extractEntry test/3rdparty/codemirror-2.34.js +2793 silly gunzTarPerm modified mode [ 'test/3rdparty/codemirror-2.34.js', 436, 420 ] +2794 silly gunzTarPerm extractEntry test/3rdparty/escodegen.browser.js +2795 silly gunzTarPerm modified mode [ 'test/3rdparty/escodegen.browser.js', 436, 420 ] +2796 silly gunzTarPerm extractEntry test/3rdparty/esmangle.browser.js +2797 silly gunzTarPerm modified mode [ 'test/3rdparty/esmangle.browser.js', 436, 420 ] +2798 silly gunzTarPerm extractEntry test/3rdparty/esmorph.js +2799 silly gunzTarPerm modified mode [ 'test/3rdparty/esmorph.js', 436, 420 ] +2800 http 304 https://registry.npmjs.org/stream-to-array +2801 silly registry.get cb [ 304, +2801 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +2801 silly registry.get server: 'Apache', +2801 silly registry.get via: '1.1 varnish', +2801 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +2801 silly registry.get 'cache-control': 'max-age=60', +2801 silly registry.get etag: '"CEFJPDZYTAADA5SD469NI6MD5"', +2801 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +2801 silly registry.get 'x-cache': 'HIT', +2801 silly registry.get 'x-cache-hits': '1', +2801 silly registry.get 'x-timer': 'S1411067671.174379,VS0,VE61', +2801 silly registry.get vary: 'Accept', +2801 silly registry.get 'content-length': '0', +2801 silly registry.get 'keep-alive': 'timeout=10, max=49', +2801 silly registry.get connection: 'Keep-Alive' } ] +2802 verbose etag https://registry.npmjs.org/stream-to-array from cache +2803 silly gunzTarPerm extractEntry test/3rdparty/harmonizr.js +2804 silly gunzTarPerm modified mode [ 'test/3rdparty/harmonizr.js', 436, 420 ] +2805 silly gunzTarPerm extractEntry test/3rdparty/jquery-1.8.2.js +2806 silly gunzTarPerm modified mode [ 'test/3rdparty/jquery-1.8.2.js', 436, 420 ] +2807 silly gunzTarPerm extractEntry test/3rdparty/jquery.mobile-1.2.0.js +2808 silly gunzTarPerm modified mode [ 'test/3rdparty/jquery.mobile-1.2.0.js', 436, 420 ] +2809 silly gunzTarPerm extractEntry test/3rdparty/modifier.js +2810 silly gunzTarPerm modified mode [ 'test/3rdparty/modifier.js', 436, 420 ] +2811 silly gunzTarPerm extractEntry test/3rdparty/mootools-1.4.1.js +2812 silly gunzTarPerm modified mode [ 'test/3rdparty/mootools-1.4.1.js', 436, 420 ] +2813 silly gunzTarPerm extractEntry test/3rdparty/parse-js.js +2814 silly gunzTarPerm modified mode [ 'test/3rdparty/parse-js.js', 436, 420 ] +2815 http 304 https://registry.npmjs.org/css +2816 silly registry.get cb [ 304, +2816 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +2816 silly registry.get server: 'Apache', +2816 silly registry.get via: '1.1 varnish', +2816 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +2816 silly registry.get 'cache-control': 'max-age=60', +2816 silly registry.get etag: '"3JKMNW0FVVDQS5ZKDCPPNJ0PN"', +2816 silly registry.get 'x-served-by': 'cache-dfw1824-DFW', +2816 silly registry.get 'x-cache': 'HIT', +2816 silly registry.get 'x-cache-hits': '1', +2816 silly registry.get 'x-timer': 'S1411067671.253748,VS0,VE0', +2816 silly registry.get vary: 'Accept', +2816 silly registry.get 'content-length': '0', +2816 silly registry.get 'keep-alive': 'timeout=10, max=47', +2816 silly registry.get connection: 'Keep-Alive' } ] +2817 verbose etag https://registry.npmjs.org/css from cache +2818 silly gunzTarPerm extractEntry test/3rdparty/threejs-r51.js +2819 silly gunzTarPerm modified mode [ 'test/3rdparty/threejs-r51.js', 436, 420 ] +2820 silly gunzTarPerm extractEntry test/3rdparty/underscore-1.4.1.js +2821 silly gunzTarPerm modified mode [ 'test/3rdparty/underscore-1.4.1.js', 436, 420 ] +2822 silly gunzTarPerm extractEntry test/benchmarks.html +2823 silly gunzTarPerm modified mode [ 'test/benchmarks.html', 436, 420 ] +2824 silly gunzTarPerm extractEntry test/benchmarks.js +2825 silly gunzTarPerm modified mode [ 'test/benchmarks.js', 436, 420 ] +2826 silly gunzTarPerm extractEntry test/compare.html +2827 silly gunzTarPerm modified mode [ 'test/compare.html', 436, 420 ] +2828 silly gunzTarPerm extractEntry test/compare.js +2829 silly gunzTarPerm modified mode [ 'test/compare.js', 436, 420 ] +2830 silly gunzTarPerm extractEntry test/compat.html +2831 silly gunzTarPerm modified mode [ 'test/compat.html', 436, 420 ] +2832 verbose request where is /source-map-resolve +2833 verbose request registry https://registry.npmjs.org/ +2834 verbose url raw /source-map-resolve +2835 verbose url resolving [ 'https://registry.npmjs.org/', './source-map-resolve' ] +2836 verbose url resolved https://registry.npmjs.org/source-map-resolve +2837 verbose request where is https://registry.npmjs.org/source-map-resolve +2838 info trying registry request attempt 1 at 15:14:31 +2839 verbose etag "472ZFA0TX4Z6BZJYCCDUNMN1B" +2840 http GET https://registry.npmjs.org/source-map-resolve +2841 verbose registry.get https://registry.npmjs.org/source-map not expired, no request +2842 verbose request where is /urix +2843 verbose request registry https://registry.npmjs.org/ +2844 verbose url raw /urix +2845 verbose url resolving [ 'https://registry.npmjs.org/', './urix' ] +2846 verbose url resolved https://registry.npmjs.org/urix +2847 verbose request where is https://registry.npmjs.org/urix +2848 info trying registry request attempt 1 at 15:14:31 +2849 verbose etag "35KRF5V0AFEWMEL158IFFJM2I" +2850 http GET https://registry.npmjs.org/urix +2851 verbose registry.get https://registry.npmjs.org/inherits not expired, no request +2852 silly gunzTarPerm extractEntry test/compat.js +2853 silly gunzTarPerm modified mode [ 'test/compat.js', 436, 420 ] +2854 silly gunzTarPerm extractEntry test/coverage.html +2855 silly gunzTarPerm modified mode [ 'test/coverage.html', 436, 420 ] +2856 silly gunzTarPerm extractEntry test/esprima.js.html +2857 silly gunzTarPerm modified mode [ 'test/esprima.js.html', 436, 420 ] +2858 http 304 https://registry.npmjs.org/rgb +2859 silly registry.get cb [ 304, +2859 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +2859 silly registry.get server: 'Apache', +2859 silly registry.get via: '1.1 varnish', +2859 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +2859 silly registry.get 'cache-control': 'max-age=60', +2859 silly registry.get etag: '"DBXZ09OSXAFT16OTHXYMW4P9C"', +2859 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +2859 silly registry.get 'x-cache': 'MISS', +2859 silly registry.get 'x-cache-hits': '0', +2859 silly registry.get 'x-timer': 'S1411067671.247794,VS0,VE45', +2859 silly registry.get vary: 'Accept', +2859 silly registry.get 'content-length': '0', +2859 silly registry.get 'keep-alive': 'timeout=10, max=47', +2859 silly registry.get connection: 'Keep-Alive' } ] +2860 verbose etag https://registry.npmjs.org/rgb from cache +2861 verbose request where is /amdefine +2862 verbose request registry https://registry.npmjs.org/ +2863 verbose url raw /amdefine +2864 verbose url resolving [ 'https://registry.npmjs.org/', './amdefine' ] +2865 verbose url resolved https://registry.npmjs.org/amdefine +2866 verbose request where is https://registry.npmjs.org/amdefine +2867 info trying registry request attempt 1 at 15:14:31 +2868 verbose etag "7YJYSZE54QIQX5HOS2BLMK126" +2869 http GET https://registry.npmjs.org/amdefine +2870 silly gunzTarPerm extractEntry test/harmonytest.js +2871 silly gunzTarPerm modified mode [ 'test/harmonytest.js', 436, 420 ] +2872 silly gunzTarPerm extractEntry test/index.html +2873 silly gunzTarPerm modified mode [ 'test/index.html', 436, 420 ] +2874 silly gunzTarPerm extractEntry test/module.html +2875 silly gunzTarPerm modified mode [ 'test/module.html', 436, 420 ] +2876 silly gunzTarPerm extractEntry test/module.js +2877 silly gunzTarPerm modified mode [ 'test/module.js', 436, 420 ] +2878 silly gunzTarPerm extractEntry test/reflect.js +2879 silly gunzTarPerm modified mode [ 'test/reflect.js', 436, 420 ] +2880 silly gunzTarPerm extractEntry test/run.js +2881 silly gunzTarPerm modified mode [ 'test/run.js', 436, 420 ] +2882 silly gunzTarPerm extractEntry test/runner.js +2883 silly gunzTarPerm modified mode [ 'test/runner.js', 436, 420 ] +2884 silly gunzTarPerm extractEntry test/test.js +2885 silly gunzTarPerm modified mode [ 'test/test.js', 436, 420 ] +2886 silly gunzTarPerm extractEntry tools/ +2887 silly gunzTarPerm modified mode [ 'tools/', 509, 493 ] +2888 silly gunzTarPerm extractEntry tools/check-version.js +2889 silly gunzTarPerm modified mode [ 'tools/check-version.js', 436, 420 ] +2890 silly gunzTarPerm extractEntry tools/generate-test-fixture.js +2891 silly gunzTarPerm modified mode [ 'tools/generate-test-fixture.js', 436, 420 ] +2892 silly gunzTarPerm extractEntry tools/generate-unicode-regex.py +2893 silly gunzTarPerm modified mode [ 'tools/generate-unicode-regex.py', 436, 420 ] +2894 silly gunzTarPerm extractEntry tools/list-complexity.js +2895 silly gunzTarPerm modified mode [ 'tools/list-complexity.js', 436, 420 ] +2896 silly gunzTarPerm extractEntry tools/update-coverage.sh +2897 silly gunzTarPerm modified mode [ 'tools/update-coverage.sh', 509, 493 ] +2898 http 304 https://registry.npmjs.org/crc +2899 silly registry.get cb [ 304, +2899 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +2899 silly registry.get server: 'Apache', +2899 silly registry.get via: '1.1 varnish', +2899 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +2899 silly registry.get 'cache-control': 'max-age=60', +2899 silly registry.get etag: '"BW6YQ8QKL056EF6CHL4KCRA8"', +2899 silly registry.get 'x-served-by': 'cache-dfw1829-DFW', +2899 silly registry.get 'x-cache': 'HIT', +2899 silly registry.get 'x-cache-hits': '1', +2899 silly registry.get 'x-timer': 'S1411067671.069356,VS0,VE259', +2899 silly registry.get vary: 'Accept', +2899 silly registry.get 'content-length': '0', +2899 silly registry.get 'keep-alive': 'timeout=10, max=50', +2899 silly registry.get connection: 'Keep-Alive' } ] +2900 verbose etag https://registry.npmjs.org/crc from cache +2901 http 304 https://registry.npmjs.org/parse-import +2902 silly registry.get cb [ 304, +2902 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +2902 silly registry.get server: 'Apache', +2902 silly registry.get via: '1.1 varnish', +2902 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +2902 silly registry.get 'cache-control': 'max-age=60', +2902 silly registry.get etag: '"COOI65YO14PBQ8PJ6I5S67S93"', +2902 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +2902 silly registry.get 'x-cache': 'MISS', +2902 silly registry.get 'x-cache-hits': '0', +2902 silly registry.get 'x-timer': 'S1411067671.296654,VS0,VE61', +2902 silly registry.get vary: 'Accept', +2902 silly registry.get 'content-length': '0', +2902 silly registry.get 'keep-alive': 'timeout=10, max=48', +2902 silly registry.get connection: 'Keep-Alive' } ] +2903 verbose etag https://registry.npmjs.org/parse-import from cache +2904 http 304 https://registry.npmjs.org/wordwrap +2905 silly registry.get cb [ 304, +2905 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +2905 silly registry.get server: 'Apache', +2905 silly registry.get via: '1.1 varnish', +2905 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +2905 silly registry.get 'cache-control': 'max-age=60', +2905 silly registry.get etag: '"BXLEIPULPYSY9Y6K8IUPBMU0J"', +2905 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +2905 silly registry.get 'x-cache': 'HIT', +2905 silly registry.get 'x-cache-hits': '1', +2905 silly registry.get 'x-timer': 'S1411067671.359045,VS0,VE0', +2905 silly registry.get vary: 'Accept', +2905 silly registry.get 'content-length': '0', +2905 silly registry.get 'keep-alive': 'timeout=10, max=46', +2905 silly registry.get connection: 'Keep-Alive' } ] +2906 verbose etag https://registry.npmjs.org/wordwrap from cache +2907 http 304 https://registry.npmjs.org/to-no-case +2908 silly registry.get cb [ 304, +2908 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +2908 silly registry.get server: 'Apache', +2908 silly registry.get via: '1.1 varnish', +2908 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +2908 silly registry.get 'cache-control': 'max-age=60', +2908 silly registry.get etag: '"EPAVN636NU8EGMD42HL11CMF9"', +2908 silly registry.get 'x-served-by': 'cache-dfw1824-DFW', +2908 silly registry.get 'x-cache': 'MISS', +2908 silly registry.get 'x-cache-hits': '0', +2908 silly registry.get 'x-timer': 'S1411067671.316952,VS0,VE46', +2908 silly registry.get vary: 'Accept', +2908 silly registry.get 'content-length': '0', +2908 silly registry.get 'keep-alive': 'timeout=10, max=46', +2908 silly registry.get connection: 'Keep-Alive' } ] +2909 verbose etag https://registry.npmjs.org/to-no-case from cache +2910 http 304 https://registry.npmjs.org/lru-cache +2911 silly registry.get cb [ 304, +2911 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +2911 silly registry.get server: 'Apache', +2911 silly registry.get via: '1.1 varnish', +2911 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:06 GMT', +2911 silly registry.get 'cache-control': 'max-age=60', +2911 silly registry.get etag: '"6YD8G6QB2SQ0RSNCOG67NUYV8"', +2911 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +2911 silly registry.get 'x-cache': 'HIT', +2911 silly registry.get 'x-cache-hits': '3', +2911 silly registry.get 'x-timer': 'S1411067671.419939,VS0,VE0', +2911 silly registry.get vary: 'Accept', +2911 silly registry.get 'content-length': '0', +2911 silly registry.get 'keep-alive': 'timeout=10, max=47', +2911 silly registry.get connection: 'Keep-Alive' } ] +2912 verbose etag https://registry.npmjs.org/lru-cache from cache +2913 http 304 https://registry.npmjs.org/readable-stream +2914 silly registry.get cb [ 304, +2914 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +2914 silly registry.get server: 'Apache', +2914 silly registry.get via: '1.1 varnish', +2914 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:13:41 GMT', +2914 silly registry.get 'cache-control': 'max-age=60', +2914 silly registry.get etag: '"64HWPM9QDWFPRSQQO5XG0WJFK"', +2914 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +2914 silly registry.get 'x-cache': 'HIT', +2914 silly registry.get 'x-cache-hits': '14', +2914 silly registry.get 'x-timer': 'S1411067671.421682,VS0,VE0', +2914 silly registry.get vary: 'Accept', +2914 silly registry.get 'content-length': '0', +2914 silly registry.get 'keep-alive': 'timeout=10, max=45', +2914 silly registry.get connection: 'Keep-Alive' } ] +2915 verbose etag https://registry.npmjs.org/readable-stream from cache +2916 http 304 https://registry.npmjs.org/semver +2917 silly registry.get cb [ 304, +2917 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +2917 silly registry.get server: 'Apache', +2917 silly registry.get via: '1.1 varnish', +2917 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +2917 silly registry.get 'cache-control': 'max-age=60', +2917 silly registry.get etag: '"ASSRXC66VGM9KE5PLJPL2WLAJ"', +2917 silly registry.get 'x-served-by': 'cache-dfw1824-DFW', +2917 silly registry.get 'x-cache': 'HIT', +2917 silly registry.get 'x-cache-hits': '1', +2917 silly registry.get 'x-timer': 'S1411067671.428469,VS0,VE0', +2917 silly registry.get vary: 'Accept', +2917 silly registry.get 'content-length': '0', +2917 silly registry.get 'keep-alive': 'timeout=10, max=45', +2917 silly registry.get connection: 'Keep-Alive' } ] +2918 verbose etag https://registry.npmjs.org/semver from cache +2919 verbose request where is /core-util-is +2920 verbose request registry https://registry.npmjs.org/ +2921 verbose url raw /core-util-is +2922 verbose url resolving [ 'https://registry.npmjs.org/', './core-util-is' ] +2923 verbose url resolved https://registry.npmjs.org/core-util-is +2924 verbose request where is https://registry.npmjs.org/core-util-is +2925 info trying registry request attempt 1 at 15:14:31 +2926 verbose etag "1DM3AHIM42HCDO4GJ71NHQO3O" +2927 http GET https://registry.npmjs.org/core-util-is +2928 verbose request where is /isarray +2929 verbose request registry https://registry.npmjs.org/ +2930 verbose url raw /isarray +2931 verbose url resolving [ 'https://registry.npmjs.org/', './isarray' ] +2932 verbose url resolved https://registry.npmjs.org/isarray +2933 verbose request where is https://registry.npmjs.org/isarray +2934 info trying registry request attempt 1 at 15:14:31 +2935 verbose etag "C9G6KLTFV9E8I4RST21BBF653" +2936 http GET https://registry.npmjs.org/isarray +2937 verbose request where is /string_decoder +2938 verbose request registry https://registry.npmjs.org/ +2939 verbose url raw /string_decoder +2940 verbose url resolving [ 'https://registry.npmjs.org/', './string_decoder' ] +2941 verbose url resolved https://registry.npmjs.org/string_decoder +2942 verbose request where is https://registry.npmjs.org/string_decoder +2943 info trying registry request attempt 1 at 15:14:31 +2944 verbose etag "5LTQBGJLEFFY5DM9FI1YPLE02" +2945 http GET https://registry.npmjs.org/string_decoder +2946 verbose registry.get https://registry.npmjs.org/inherits not expired, no request +2947 http 304 https://registry.npmjs.org/mute-stream +2948 silly registry.get cb [ 304, +2948 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +2948 silly registry.get server: 'Apache', +2948 silly registry.get via: '1.1 varnish', +2948 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +2948 silly registry.get 'cache-control': 'max-age=60', +2948 silly registry.get etag: '"DOQG6GEXY47IRXI3QWNAP991O"', +2948 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +2948 silly registry.get 'x-cache': 'HIT', +2948 silly registry.get 'x-cache-hits': '1', +2948 silly registry.get 'x-timer': 'S1411067671.488613,VS0,VE0', +2948 silly registry.get vary: 'Accept', +2948 silly registry.get 'content-length': '0', +2948 silly registry.get 'keep-alive': 'timeout=10, max=46', +2948 silly registry.get connection: 'Keep-Alive' } ] +2949 verbose etag https://registry.npmjs.org/mute-stream from cache +2950 http 304 https://registry.npmjs.org/throttleit +2951 silly registry.get cb [ 304, +2951 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +2951 silly registry.get server: 'Apache', +2951 silly registry.get via: '1.1 varnish', +2951 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +2951 silly registry.get 'cache-control': 'max-age=60', +2951 silly registry.get etag: '"5T0DZZ4VJDS0VO9E6KFN9BDPX"', +2951 silly registry.get 'x-served-by': 'cache-dfw1824-DFW', +2951 silly registry.get 'x-cache': 'HIT', +2951 silly registry.get 'x-cache-hits': '1', +2951 silly registry.get 'x-timer': 'S1411067671.492163,VS0,VE0', +2951 silly registry.get vary: 'Accept', +2951 silly registry.get 'content-length': '0', +2951 silly registry.get 'keep-alive': 'timeout=10, max=44', +2951 silly registry.get connection: 'Keep-Alive' } ] +2952 verbose etag https://registry.npmjs.org/throttleit from cache +2953 http 304 https://registry.npmjs.org/amdefine +2954 silly registry.get cb [ 304, +2954 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +2954 silly registry.get server: 'Apache', +2954 silly registry.get via: '1.1 varnish', +2954 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +2954 silly registry.get 'cache-control': 'max-age=60', +2954 silly registry.get etag: '"7YJYSZE54QIQX5HOS2BLMK126"', +2954 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +2954 silly registry.get 'x-cache': 'HIT', +2954 silly registry.get 'x-cache-hits': '1', +2954 silly registry.get 'x-timer': 'S1411067671.495230,VS0,VE0', +2954 silly registry.get vary: 'Accept', +2954 silly registry.get 'content-length': '0', +2954 silly registry.get 'keep-alive': 'timeout=10, max=44', +2954 silly registry.get connection: 'Keep-Alive' } ] +2955 verbose etag https://registry.npmjs.org/amdefine from cache +2956 http 304 https://registry.npmjs.org/find-file +2957 silly registry.get cb [ 304, +2957 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +2957 silly registry.get server: 'Apache', +2957 silly registry.get via: '1.1 varnish', +2957 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +2957 silly registry.get 'cache-control': 'max-age=60', +2957 silly registry.get etag: '"AV7JF5DIK4JBDUH5VE7RSK4MC"', +2957 silly registry.get 'x-served-by': 'cache-dfw1820-DFW', +2957 silly registry.get 'x-cache': 'HIT', +2957 silly registry.get 'x-cache-hits': '1', +2957 silly registry.get 'x-timer': 'S1411067671.267295,VS0,VE255', +2957 silly registry.get vary: 'Accept', +2957 silly registry.get 'content-length': '0', +2957 silly registry.get 'keep-alive': 'timeout=10, max=48', +2957 silly registry.get connection: 'Keep-Alive' } ] +2958 verbose etag https://registry.npmjs.org/find-file from cache +2959 http 304 https://registry.npmjs.org/traverse +2960 silly registry.get cb [ 304, +2960 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +2960 silly registry.get server: 'Apache', +2960 silly registry.get via: '1.1 varnish', +2960 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +2960 silly registry.get 'cache-control': 'max-age=60', +2960 silly registry.get etag: '"HEGQ7M3Q2K96ZHIRL3BCF372"', +2960 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +2960 silly registry.get 'x-cache': 'HIT', +2960 silly registry.get 'x-cache-hits': '1', +2960 silly registry.get 'x-timer': 'S1411067671.548766,VS0,VE0', +2960 silly registry.get vary: 'Accept', +2960 silly registry.get 'content-length': '0', +2960 silly registry.get 'keep-alive': 'timeout=10, max=45', +2960 silly registry.get connection: 'Keep-Alive' } ] +2961 verbose etag https://registry.npmjs.org/traverse from cache +2962 silly lockFile c073b7c1-d653b11e9419241a9d726af7c-unpack tar:///tmp/npm-17670-yMiqFMg9/github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c-unpack +2963 silly lockFile c073b7c1-d653b11e9419241a9d726af7c-unpack tar:///tmp/npm-17670-yMiqFMg9/github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c-unpack +2964 silly lockFile 772ed5b9-243f29bd653b11e9419241a9d726af7c tar:///tmp/npm-17670-yMiqFMg9/github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c +2965 silly lockFile 772ed5b9-243f29bd653b11e9419241a9d726af7c tar:///tmp/npm-17670-yMiqFMg9/github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c +2966 silly lockFile db72957f-243f29bd653b11e9419241a9d726af7c https://github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c +2967 silly lockFile db72957f-243f29bd653b11e9419241a9d726af7c https://github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c +2968 http 304 https://registry.npmjs.org/charm +2969 silly registry.get cb [ 304, +2969 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +2969 silly registry.get server: 'Apache', +2969 silly registry.get via: '1.1 varnish', +2969 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +2969 silly registry.get 'cache-control': 'max-age=60', +2969 silly registry.get etag: '"AK6L4P6TVCDG1DTJJSKUNNOR0"', +2969 silly registry.get 'x-served-by': 'cache-dfw1824-DFW', +2969 silly registry.get 'x-cache': 'HIT', +2969 silly registry.get 'x-cache-hits': '1', +2969 silly registry.get 'x-timer': 'S1411067671.552129,VS0,VE62', +2969 silly registry.get vary: 'Accept', +2969 silly registry.get 'content-length': '0', +2969 silly registry.get 'keep-alive': 'timeout=10, max=43', +2969 silly registry.get connection: 'Keep-Alive' } ] +2970 verbose etag https://registry.npmjs.org/charm from cache +2971 http 304 https://registry.npmjs.org/bunker +2972 silly registry.get cb [ 304, +2972 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +2972 silly registry.get server: 'Apache', +2972 silly registry.get via: '1.1 varnish', +2972 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +2972 silly registry.get 'cache-control': 'max-age=60', +2972 silly registry.get etag: '"56CRJJ6VITUFGXTPL0PSRWWHX"', +2972 silly registry.get 'x-served-by': 'cache-dfw1820-DFW', +2972 silly registry.get 'x-cache': 'HIT', +2972 silly registry.get 'x-cache-hits': '1', +2972 silly registry.get 'x-timer': 'S1411067671.581841,VS0,VE60', +2972 silly registry.get vary: 'Accept', +2972 silly registry.get 'content-length': '0', +2972 silly registry.get 'keep-alive': 'timeout=10, max=47', +2972 silly registry.get connection: 'Keep-Alive' } ] +2973 verbose etag https://registry.npmjs.org/bunker from cache +2974 verbose request where is /burrito +2975 verbose request registry https://registry.npmjs.org/ +2976 verbose url raw /burrito +2977 verbose url resolving [ 'https://registry.npmjs.org/', './burrito' ] +2978 verbose url resolved https://registry.npmjs.org/burrito +2979 verbose request where is https://registry.npmjs.org/burrito +2980 info trying registry request attempt 1 at 15:14:31 +2981 verbose etag "HKUZ6SXXVQOCUAOMQ430XCS5" +2982 http GET https://registry.npmjs.org/burrito +2983 http 304 https://registry.npmjs.org/recursive-readdir +2984 silly registry.get cb [ 304, +2984 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +2984 silly registry.get server: 'Apache', +2984 silly registry.get via: '1.1 varnish', +2984 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +2984 silly registry.get 'cache-control': 'max-age=60', +2984 silly registry.get etag: '"C0NRXZ597S1R9MKY5QVMAY9ZA"', +2984 silly registry.get 'x-served-by': 'cache-dfw1829-DFW', +2984 silly registry.get 'x-cache': 'HIT', +2984 silly registry.get 'x-cache-hits': '1', +2984 silly registry.get 'x-timer': 'S1411067671.389298,VS0,VE263', +2984 silly registry.get vary: 'Accept', +2984 silly registry.get 'content-length': '0', +2984 silly registry.get 'keep-alive': 'timeout=10, max=49', +2984 silly registry.get connection: 'Keep-Alive' } ] +2985 verbose etag https://registry.npmjs.org/recursive-readdir from cache +2986 http 304 https://registry.npmjs.org/inpath +2987 silly registry.get cb [ 304, +2987 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +2987 silly registry.get server: 'Apache', +2987 silly registry.get via: '1.1 varnish', +2987 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +2987 silly registry.get 'cache-control': 'max-age=60', +2987 silly registry.get etag: '"2U89ULXMT749T2HRB16EG76SA"', +2987 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +2987 silly registry.get 'x-cache': 'MISS', +2987 silly registry.get 'x-cache-hits': '0', +2987 silly registry.get 'x-timer': 'S1411067671.608609,VS0,VE60', +2987 silly registry.get vary: 'Accept', +2987 silly registry.get 'content-length': '0', +2987 silly registry.get 'keep-alive': 'timeout=10, max=44', +2987 silly registry.get connection: 'Keep-Alive' } ] +2988 verbose etag https://registry.npmjs.org/inpath from cache +2989 http 304 https://registry.npmjs.org/escodegen +2990 silly registry.get cb [ 304, +2990 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +2990 silly registry.get server: 'Apache', +2990 silly registry.get via: '1.1 varnish', +2990 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +2990 silly registry.get 'cache-control': 'max-age=60', +2990 silly registry.get etag: '"4VE1U0YLYL9LKIY6CR10AKM3J"', +2990 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +2990 silly registry.get 'x-cache': 'HIT', +2990 silly registry.get 'x-cache-hits': '1', +2990 silly registry.get 'x-timer': 'S1411067671.728576,VS0,VE0', +2990 silly registry.get vary: 'Accept', +2990 silly registry.get 'content-length': '0', +2990 silly registry.get 'keep-alive': 'timeout=10, max=43', +2990 silly registry.get connection: 'Keep-Alive' } ] +2991 verbose etag https://registry.npmjs.org/escodegen from cache +2992 http 304 https://registry.npmjs.org/deep-is +2993 silly registry.get cb [ 304, +2993 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +2993 silly registry.get server: 'Apache', +2993 silly registry.get via: '1.1 varnish', +2993 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +2993 silly registry.get 'cache-control': 'max-age=60', +2993 silly registry.get etag: '"74BKFN24HX3Y0BSSE8NYEOHP9"', +2993 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +2993 silly registry.get 'x-cache': 'HIT', +2993 silly registry.get 'x-cache-hits': '1', +2993 silly registry.get 'x-timer': 'S1411067671.559984,VS0,VE181', +2993 silly registry.get vary: 'Accept', +2993 silly registry.get 'content-length': '0', +2993 silly registry.get 'keep-alive': 'timeout=10, max=43', +2993 silly registry.get connection: 'Keep-Alive' } ] +2994 verbose etag https://registry.npmjs.org/deep-is from cache +2995 http 304 https://registry.npmjs.org/estraverse +2996 silly registry.get cb [ 304, +2996 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +2996 silly registry.get server: 'Apache', +2996 silly registry.get via: '1.1 varnish', +2996 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +2996 silly registry.get 'cache-control': 'max-age=60', +2996 silly registry.get etag: '"COHNCX96YKOQRG3GCW5OOIQH3"', +2996 silly registry.get 'x-served-by': 'cache-dfw1829-DFW', +2996 silly registry.get 'x-cache': 'HIT', +2996 silly registry.get 'x-cache-hits': '1', +2996 silly registry.get 'x-timer': 'S1411067671.712029,VS0,VE42', +2996 silly registry.get vary: 'Accept', +2996 silly registry.get 'content-length': '0', +2996 silly registry.get 'keep-alive': 'timeout=10, max=48', +2996 silly registry.get connection: 'Keep-Alive' } ] +2997 verbose etag https://registry.npmjs.org/estraverse from cache +2998 http 304 https://registry.npmjs.org/escodegen +2999 silly registry.get cb [ 304, +2999 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +2999 silly registry.get server: 'Apache', +2999 silly registry.get via: '1.1 varnish', +2999 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +2999 silly registry.get 'cache-control': 'max-age=60', +2999 silly registry.get etag: '"4VE1U0YLYL9LKIY6CR10AKM3J"', +2999 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +2999 silly registry.get 'x-cache': 'HIT', +2999 silly registry.get 'x-cache-hits': '2', +2999 silly registry.get 'x-timer': 'S1411067671.789133,VS0,VE0', +2999 silly registry.get vary: 'Accept', +2999 silly registry.get 'content-length': '0', +2999 silly registry.get 'keep-alive': 'timeout=10, max=42', +2999 silly registry.get connection: 'Keep-Alive' } ] +3000 verbose etag https://registry.npmjs.org/escodegen from cache +3001 http 304 https://registry.npmjs.org/handlebars +3002 silly registry.get cb [ 304, +3002 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +3002 silly registry.get server: 'Apache', +3002 silly registry.get via: '1.1 varnish', +3002 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +3002 silly registry.get 'cache-control': 'max-age=60', +3002 silly registry.get etag: '"2EPJS9TIRC62VBZKIBRCSLQYH"', +3002 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +3002 silly registry.get 'x-cache': 'HIT', +3002 silly registry.get 'x-cache-hits': '1', +3002 silly registry.get 'x-timer': 'S1411067671.800574,VS0,VE0', +3002 silly registry.get vary: 'Accept', +3002 silly registry.get 'content-length': '0', +3002 silly registry.get 'keep-alive': 'timeout=10, max=42', +3002 silly registry.get connection: 'Keep-Alive' } ] +3003 verbose etag https://registry.npmjs.org/handlebars from cache +3004 http 304 https://registry.npmjs.org/fileset +3005 silly registry.get cb [ 304, +3005 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +3005 silly registry.get server: 'Apache', +3005 silly registry.get via: '1.1 varnish', +3005 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +3005 silly registry.get 'cache-control': 'max-age=60', +3005 silly registry.get etag: '"2GRJF38NRU8K84C14U03SU5I4"', +3005 silly registry.get 'x-served-by': 'cache-dfw1829-DFW', +3005 silly registry.get 'x-cache': 'HIT', +3005 silly registry.get 'x-cache-hits': '1', +3005 silly registry.get 'x-timer': 'S1411067671.814251,VS0,VE0', +3005 silly registry.get vary: 'Accept', +3005 silly registry.get 'content-length': '0', +3005 silly registry.get 'keep-alive': 'timeout=10, max=47', +3005 silly registry.get connection: 'Keep-Alive' } ] +3006 verbose etag https://registry.npmjs.org/fileset from cache +3007 verbose registry.get https://registry.npmjs.org/minimatch not expired, no request +3008 verbose registry.get https://registry.npmjs.org/glob not expired, no request +3009 http 304 https://registry.npmjs.org/abbrev +3010 silly registry.get cb [ 304, +3010 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +3010 silly registry.get server: 'Apache', +3010 silly registry.get via: '1.1 varnish', +3010 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +3010 silly registry.get 'cache-control': 'max-age=60', +3010 silly registry.get etag: '"CY41WQX3SN6P2Z9FH9M7NUQHN"', +3010 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +3010 silly registry.get 'x-cache': 'HIT', +3010 silly registry.get 'x-cache-hits': '1', +3010 silly registry.get 'x-timer': 'S1411067671.849307,VS0,VE0', +3010 silly registry.get vary: 'Accept', +3010 silly registry.get 'content-length': '0', +3010 silly registry.get 'keep-alive': 'timeout=10, max=41', +3010 silly registry.get connection: 'Keep-Alive' } ] +3011 verbose etag https://registry.npmjs.org/abbrev from cache +3012 http 304 https://registry.npmjs.org/wordwrap +3013 silly registry.get cb [ 304, +3013 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +3013 silly registry.get server: 'Apache', +3013 silly registry.get via: '1.1 varnish', +3013 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +3013 silly registry.get 'cache-control': 'max-age=60', +3013 silly registry.get etag: '"BXLEIPULPYSY9Y6K8IUPBMU0J"', +3013 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +3013 silly registry.get 'x-cache': 'HIT', +3013 silly registry.get 'x-cache-hits': '2', +3013 silly registry.get 'x-timer': 'S1411067671.860494,VS0,VE0', +3013 silly registry.get vary: 'Accept', +3013 silly registry.get 'content-length': '0', +3013 silly registry.get 'keep-alive': 'timeout=10, max=41', +3013 silly registry.get connection: 'Keep-Alive' } ] +3014 verbose etag https://registry.npmjs.org/wordwrap from cache +3015 http 304 https://registry.npmjs.org/pidof +3016 silly registry.get cb [ 304, +3016 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +3016 silly registry.get server: 'Apache', +3016 silly registry.get via: '1.1 varnish', +3016 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +3016 silly registry.get 'cache-control': 'max-age=60', +3016 silly registry.get etag: '"A1FY3LJTDVP8WS0RBH7T7YMQN"', +3016 silly registry.get 'x-served-by': 'cache-dfw1824-DFW', +3016 silly registry.get 'x-cache': 'MISS', +3016 silly registry.get 'x-cache-hits': '0', +3016 silly registry.get 'x-timer': 'S1411067671.674362,VS0,VE190', +3016 silly registry.get vary: 'Accept', +3016 silly registry.get 'content-length': '0', +3016 silly registry.get 'keep-alive': 'timeout=10, max=42', +3016 silly registry.get connection: 'Keep-Alive' } ] +3017 verbose etag https://registry.npmjs.org/pidof from cache +3018 http 304 https://registry.npmjs.org/once +3019 silly registry.get cb [ 304, +3019 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +3019 silly registry.get server: 'Apache', +3019 silly registry.get via: '1.1 varnish', +3019 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:03 GMT', +3019 silly registry.get 'cache-control': 'max-age=60', +3019 silly registry.get etag: '"6TIS5LZZJJ57TQMU4V53YO2P5"', +3019 silly registry.get 'x-served-by': 'cache-dfw1829-DFW', +3019 silly registry.get 'x-cache': 'HIT', +3019 silly registry.get 'x-cache-hits': '2', +3019 silly registry.get 'x-timer': 'S1411067671.874759,VS0,VE0', +3019 silly registry.get vary: 'Accept', +3019 silly registry.get 'content-length': '0', +3019 silly registry.get 'keep-alive': 'timeout=10, max=46', +3019 silly registry.get connection: 'Keep-Alive' } ] +3020 verbose etag https://registry.npmjs.org/once from cache +3021 http 304 https://registry.npmjs.org/css-color-function +3022 silly registry.get cb [ 304, +3022 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +3022 silly registry.get server: 'Apache', +3022 silly registry.get via: '1.1 varnish', +3022 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +3022 silly registry.get 'cache-control': 'max-age=60', +3022 silly registry.get etag: '"7VGOP7KYZMOL5909DEXTBPR4F"', +3022 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +3022 silly registry.get 'x-cache': 'HIT', +3022 silly registry.get 'x-cache-hits': '1', +3022 silly registry.get 'x-timer': 'S1411067671.909286,VS0,VE47', +3022 silly registry.get vary: 'Accept', +3022 silly registry.get 'content-length': '0', +3022 silly registry.get 'keep-alive': 'timeout=10, max=40', +3022 silly registry.get connection: 'Keep-Alive' } ] +3023 verbose etag https://registry.npmjs.org/css-color-function from cache +3024 http 304 https://registry.npmjs.org/postcss +3025 silly registry.get cb [ 304, +3025 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +3025 silly registry.get server: 'Apache', +3025 silly registry.get via: '1.1 varnish', +3025 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +3025 silly registry.get 'cache-control': 'max-age=60', +3025 silly registry.get etag: '"CHBDQOWYV6KJ67G72KZ2O7DND"', +3025 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +3025 silly registry.get 'x-cache': 'HIT', +3025 silly registry.get 'x-cache-hits': '1', +3025 silly registry.get 'x-timer': 'S1411067671.919997,VS0,VE43', +3025 silly registry.get vary: 'Accept', +3025 silly registry.get 'content-length': '0', +3025 silly registry.get 'keep-alive': 'timeout=10, max=40', +3025 silly registry.get connection: 'Keep-Alive' } ] +3026 verbose etag https://registry.npmjs.org/postcss from cache +3027 verbose registry.get https://registry.npmjs.org/rgb not expired, no request +3028 verbose registry.get https://registry.npmjs.org/debug not expired, no request +3029 verbose request where is /color +3030 verbose request registry https://registry.npmjs.org/ +3031 verbose url raw /color +3032 verbose url resolving [ 'https://registry.npmjs.org/', './color' ] +3033 verbose url resolved https://registry.npmjs.org/color +3034 verbose request where is https://registry.npmjs.org/color +3035 info trying registry request attempt 1 at 15:14:31 +3036 verbose etag "E0TQQ4DZNV49MCL5ZTVOYAGZH" +3037 http GET https://registry.npmjs.org/color +3038 verbose request where is /balanced-match +3039 verbose request registry https://registry.npmjs.org/ +3040 verbose url raw /balanced-match +3041 verbose url resolving [ 'https://registry.npmjs.org/', './balanced-match' ] +3042 verbose url resolved https://registry.npmjs.org/balanced-match +3043 verbose request where is https://registry.npmjs.org/balanced-match +3044 info trying registry request attempt 1 at 15:14:31 +3045 verbose etag "EZUFM9SYH8LMSJ7SI2N6V5DX8" +3046 http GET https://registry.npmjs.org/balanced-match +3047 http 304 https://registry.npmjs.org/coffee-script-redux +3048 silly registry.get cb [ 304, +3048 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +3048 silly registry.get server: 'Apache', +3048 silly registry.get via: '1.1 varnish', +3048 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +3048 silly registry.get 'cache-control': 'max-age=60', +3048 silly registry.get etag: '"7SFLIAKYNOZWL33H91VE1NQOE"', +3048 silly registry.get 'x-served-by': 'cache-dfw1820-DFW', +3048 silly registry.get 'x-cache': 'HIT', +3048 silly registry.get 'x-cache-hits': '1', +3048 silly registry.get 'x-timer': 'S1411067671.702197,VS0,VE268', +3048 silly registry.get vary: 'Accept', +3048 silly registry.get 'content-length': '0', +3048 silly registry.get 'keep-alive': 'timeout=10, max=46', +3048 silly registry.get connection: 'Keep-Alive' } ] +3049 verbose etag https://registry.npmjs.org/coffee-script-redux from cache +3050 verbose request where is /js-base64 +3051 verbose request registry https://registry.npmjs.org/ +3052 verbose url raw /js-base64 +3053 verbose url resolving [ 'https://registry.npmjs.org/', './js-base64' ] +3054 verbose url resolved https://registry.npmjs.org/js-base64 +3055 verbose request where is https://registry.npmjs.org/js-base64 +3056 info trying registry request attempt 1 at 15:14:32 +3057 verbose etag "4OCPV3R2J75LJYUBAS6C31FZH" +3058 http GET https://registry.npmjs.org/js-base64 +3059 verbose registry.get https://registry.npmjs.org/source-map not expired, no request +3060 verbose registry.get https://registry.npmjs.org/amdefine not expired, no request +3061 verbose request where is /StringScanner +3062 verbose request registry https://registry.npmjs.org/ +3063 verbose url raw /StringScanner +3064 verbose url resolving [ 'https://registry.npmjs.org/', './StringScanner' ] +3065 verbose url resolved https://registry.npmjs.org/StringScanner +3066 verbose request where is https://registry.npmjs.org/StringScanner +3067 info trying registry request attempt 1 at 15:14:32 +3068 verbose etag "1T3THJ00T97BGQJPQG4BQABM6" +3069 http GET https://registry.npmjs.org/StringScanner +3070 verbose registry.get https://registry.npmjs.org/nopt not expired, no request +3071 verbose request where is /esmangle +3072 verbose request registry https://registry.npmjs.org/ +3073 verbose url raw /esmangle +3074 verbose url resolving [ 'https://registry.npmjs.org/', './esmangle' ] +3075 verbose url resolved https://registry.npmjs.org/esmangle +3076 verbose request where is https://registry.npmjs.org/esmangle +3077 info trying registry request attempt 1 at 15:14:32 +3078 verbose etag "A7GAD892KX1EYPRNZXM9UVRXV" +3079 http GET https://registry.npmjs.org/esmangle +3080 verbose registry.get https://registry.npmjs.org/source-map not expired, no request +3081 verbose registry.get https://registry.npmjs.org/escodegen not expired, no request +3082 http 304 https://registry.npmjs.org/caniuse-db +3083 silly registry.get cb [ 304, +3083 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +3083 silly registry.get server: 'Apache', +3083 silly registry.get via: '1.1 varnish', +3083 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +3083 silly registry.get 'cache-control': 'max-age=60', +3083 silly registry.get etag: '"CQPTODEQ7RPUSADIQQXB6IZQ"', +3083 silly registry.get 'x-served-by': 'cache-dfw1824-DFW', +3083 silly registry.get 'x-cache': 'HIT', +3083 silly registry.get 'x-cache-hits': '1', +3083 silly registry.get 'x-timer': 'S1411067671.924957,VS0,VE64', +3083 silly registry.get vary: 'Accept', +3083 silly registry.get 'content-length': '0', +3083 silly registry.get 'keep-alive': 'timeout=10, max=41', +3083 silly registry.get connection: 'Keep-Alive' } ] +3084 verbose etag https://registry.npmjs.org/caniuse-db from cache +3085 http 304 https://registry.npmjs.org/balanced-match +3086 silly registry.get cb [ 304, +3086 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:31 GMT', +3086 silly registry.get server: 'Apache', +3086 silly registry.get via: '1.1 varnish', +3086 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3086 silly registry.get 'cache-control': 'max-age=60', +3086 silly registry.get etag: '"EZUFM9SYH8LMSJ7SI2N6V5DX8"', +3086 silly registry.get 'x-served-by': 'cache-dfw1829-DFW', +3086 silly registry.get 'x-cache': 'MISS', +3086 silly registry.get 'x-cache-hits': '0', +3086 silly registry.get 'x-timer': 'S1411067671.934237,VS0,VE66', +3086 silly registry.get vary: 'Accept', +3086 silly registry.get 'content-length': '0', +3086 silly registry.get 'keep-alive': 'timeout=10, max=45', +3086 silly registry.get connection: 'Keep-Alive' } ] +3087 verbose etag https://registry.npmjs.org/balanced-match from cache +3088 http 304 https://registry.npmjs.org/balanced-match +3089 silly registry.get cb [ 304, +3089 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3089 silly registry.get server: 'Apache', +3089 silly registry.get via: '1.1 varnish', +3089 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3089 silly registry.get 'cache-control': 'max-age=60', +3089 silly registry.get etag: '"EZUFM9SYH8LMSJ7SI2N6V5DX8"', +3089 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +3089 silly registry.get 'x-cache': 'HIT', +3089 silly registry.get 'x-cache-hits': '1', +3089 silly registry.get 'x-timer': 'S1411067672.016742,VS0,VE0', +3089 silly registry.get vary: 'Accept', +3089 silly registry.get 'content-length': '0', +3089 silly registry.get 'keep-alive': 'timeout=10, max=39', +3089 silly registry.get connection: 'Keep-Alive' } ] +3090 verbose etag https://registry.npmjs.org/balanced-match from cache +3091 http 304 https://registry.npmjs.org/balanced-match +3092 silly registry.get cb [ 304, +3092 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3092 silly registry.get server: 'Apache', +3092 silly registry.get via: '1.1 varnish', +3092 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3092 silly registry.get 'cache-control': 'max-age=60', +3092 silly registry.get etag: '"EZUFM9SYH8LMSJ7SI2N6V5DX8"', +3092 silly registry.get 'x-served-by': 'cache-dfw1824-DFW', +3092 silly registry.get 'x-cache': 'HIT', +3092 silly registry.get 'x-cache-hits': '1', +3092 silly registry.get 'x-timer': 'S1411067672.058558,VS0,VE0', +3092 silly registry.get vary: 'Accept', +3092 silly registry.get 'content-length': '0', +3092 silly registry.get 'keep-alive': 'timeout=10, max=40', +3092 silly registry.get connection: 'Keep-Alive' } ] +3093 verbose etag https://registry.npmjs.org/balanced-match from cache +3094 http 304 https://registry.npmjs.org/rework-visit +3095 silly registry.get cb [ 304, +3095 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3095 silly registry.get server: 'Apache', +3095 silly registry.get via: '1.1 varnish', +3095 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3095 silly registry.get 'cache-control': 'max-age=60', +3095 silly registry.get etag: '"2U2M4DQXLN32Y1EQYP9L93A97"', +3095 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +3095 silly registry.get 'x-cache': 'MISS', +3095 silly registry.get 'x-cache-hits': '0', +3095 silly registry.get 'x-timer': 'S1411067672.025859,VS0,VE41', +3095 silly registry.get vary: 'Accept', +3095 silly registry.get 'content-length': '0', +3095 silly registry.get 'keep-alive': 'timeout=10, max=39', +3095 silly registry.get connection: 'Keep-Alive' } ] +3096 verbose etag https://registry.npmjs.org/rework-visit from cache +3097 http 304 https://registry.npmjs.org/config-chain +3098 silly registry.get cb [ 304, +3098 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3098 silly registry.get server: 'Apache', +3098 silly registry.get via: '1.1 varnish', +3098 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3098 silly registry.get 'cache-control': 'max-age=60', +3098 silly registry.get etag: '"EKPOBV34CCDNYDBQXRIAJQE90"', +3098 silly registry.get 'x-served-by': 'cache-dfw1829-DFW', +3098 silly registry.get 'x-cache': 'HIT', +3098 silly registry.get 'x-cache-hits': '1', +3098 silly registry.get 'x-timer': 'S1411067672.064365,VS0,VE0', +3098 silly registry.get vary: 'Accept', +3098 silly registry.get 'content-length': '0', +3098 silly registry.get 'keep-alive': 'timeout=10, max=44', +3098 silly registry.get connection: 'Keep-Alive' } ] +3099 verbose etag https://registry.npmjs.org/config-chain from cache +3100 http 304 https://registry.npmjs.org/rework-visit +3101 silly registry.get cb [ 304, +3101 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3101 silly registry.get server: 'Apache', +3101 silly registry.get via: '1.1 varnish', +3101 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3101 silly registry.get 'cache-control': 'max-age=60', +3101 silly registry.get etag: '"2U2M4DQXLN32Y1EQYP9L93A97"', +3101 silly registry.get 'x-served-by': 'cache-dfw1820-DFW', +3101 silly registry.get 'x-cache': 'HIT', +3101 silly registry.get 'x-cache-hits': '1', +3101 silly registry.get 'x-timer': 'S1411067672.032096,VS0,VE32', +3101 silly registry.get vary: 'Accept', +3101 silly registry.get 'content-length': '0', +3101 silly registry.get 'keep-alive': 'timeout=10, max=45', +3101 silly registry.get connection: 'Keep-Alive' } ] +3102 verbose etag https://registry.npmjs.org/rework-visit from cache +3103 verbose request where is /proto-list +3104 verbose request registry https://registry.npmjs.org/ +3105 verbose url raw /proto-list +3106 verbose url resolving [ 'https://registry.npmjs.org/', './proto-list' ] +3107 verbose url resolved https://registry.npmjs.org/proto-list +3108 verbose request where is https://registry.npmjs.org/proto-list +3109 info trying registry request attempt 1 at 15:14:32 +3110 verbose etag "E2O0J3M4623CMOR3Q4IF96VSZ" +3111 http GET https://registry.npmjs.org/proto-list +3112 verbose request where is /ini +3113 verbose request registry https://registry.npmjs.org/ +3114 verbose url raw /ini +3115 verbose url resolving [ 'https://registry.npmjs.org/', './ini' ] +3116 verbose url resolved https://registry.npmjs.org/ini +3117 verbose request where is https://registry.npmjs.org/ini +3118 info trying registry request attempt 1 at 15:14:32 +3119 verbose etag "754C7G0ESHIITOZZPDILT5SFP" +3120 http GET https://registry.npmjs.org/ini +3121 http 304 https://registry.npmjs.org/ini +3122 silly registry.get cb [ 304, +3122 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3122 silly registry.get server: 'Apache', +3122 silly registry.get via: '1.1 varnish', +3122 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3122 silly registry.get 'cache-control': 'max-age=60', +3122 silly registry.get etag: '"754C7G0ESHIITOZZPDILT5SFP"', +3122 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +3122 silly registry.get 'x-cache': 'HIT', +3122 silly registry.get 'x-cache-hits': '1', +3122 silly registry.get 'x-timer': 'S1411067672.076607,VS0,VE0', +3122 silly registry.get vary: 'Accept', +3122 silly registry.get 'content-length': '0', +3122 silly registry.get 'keep-alive': 'timeout=10, max=38', +3122 silly registry.get connection: 'Keep-Alive' } ] +3123 verbose etag https://registry.npmjs.org/ini from cache +3124 http 304 https://registry.npmjs.org/once +3125 silly registry.get cb [ 304, +3125 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3125 silly registry.get server: 'Apache', +3125 silly registry.get via: '1.1 varnish', +3125 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3125 silly registry.get 'cache-control': 'max-age=60', +3125 silly registry.get etag: '"6TIS5LZZJJ57TQMU4V53YO2P5"', +3125 silly registry.get 'x-served-by': 'cache-dfw1824-DFW', +3125 silly registry.get 'x-cache': 'HIT', +3125 silly registry.get 'x-cache-hits': '1', +3125 silly registry.get 'x-timer': 'S1411067672.118539,VS0,VE0', +3125 silly registry.get vary: 'Accept', +3125 silly registry.get 'content-length': '0', +3125 silly registry.get 'keep-alive': 'timeout=10, max=39', +3125 silly registry.get connection: 'Keep-Alive' } ] +3126 verbose etag https://registry.npmjs.org/once from cache +3127 http 304 https://registry.npmjs.org/osenv +3128 silly registry.get cb [ 304, +3128 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3128 silly registry.get server: 'Apache', +3128 silly registry.get via: '1.1 varnish', +3128 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3128 silly registry.get 'cache-control': 'max-age=60', +3128 silly registry.get etag: '"AZU7G63I6YW7SNUHRH5KD9HZU"', +3128 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +3128 silly registry.get 'x-cache': 'HIT', +3128 silly registry.get 'x-cache-hits': '1', +3128 silly registry.get 'x-timer': 'S1411067672.126921,VS0,VE0', +3128 silly registry.get vary: 'Accept', +3128 silly registry.get 'content-length': '0', +3128 silly registry.get 'keep-alive': 'timeout=10, max=38', +3128 silly registry.get connection: 'Keep-Alive' } ] +3129 verbose etag https://registry.npmjs.org/osenv from cache +3130 http 304 https://registry.npmjs.org/semver +3131 silly registry.get cb [ 304, +3131 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3131 silly registry.get server: 'Apache', +3131 silly registry.get via: '1.1 varnish', +3131 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3131 silly registry.get 'cache-control': 'max-age=60', +3131 silly registry.get etag: '"ASSRXC66VGM9KE5PLJPL2WLAJ"', +3131 silly registry.get 'x-served-by': 'cache-dfw1829-DFW', +3131 silly registry.get 'x-cache': 'HIT', +3131 silly registry.get 'x-cache-hits': '1', +3131 silly registry.get 'x-timer': 'S1411067672.129239,VS0,VE0', +3131 silly registry.get vary: 'Accept', +3131 silly registry.get 'content-length': '0', +3131 silly registry.get 'keep-alive': 'timeout=10, max=43', +3131 silly registry.get connection: 'Keep-Alive' } ] +3132 verbose etag https://registry.npmjs.org/semver from cache +3133 http 304 https://registry.npmjs.org/abbrev +3134 silly registry.get cb [ 304, +3134 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3134 silly registry.get server: 'Apache', +3134 silly registry.get via: '1.1 varnish', +3134 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +3134 silly registry.get 'cache-control': 'max-age=60', +3134 silly registry.get etag: '"CY41WQX3SN6P2Z9FH9M7NUQHN"', +3134 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +3134 silly registry.get 'x-cache': 'HIT', +3134 silly registry.get 'x-cache-hits': '2', +3134 silly registry.get 'x-timer': 'S1411067672.139222,VS0,VE0', +3134 silly registry.get vary: 'Accept', +3134 silly registry.get 'content-length': '0', +3134 silly registry.get 'keep-alive': 'timeout=10, max=37', +3134 silly registry.get connection: 'Keep-Alive' } ] +3135 verbose etag https://registry.npmjs.org/abbrev from cache +3136 http 304 https://registry.npmjs.org/wordwrap +3137 silly registry.get cb [ 304, +3137 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3137 silly registry.get server: 'Apache', +3137 silly registry.get via: '1.1 varnish', +3137 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:24 GMT', +3137 silly registry.get 'cache-control': 'max-age=60', +3137 silly registry.get etag: '"BXLEIPULPYSY9Y6K8IUPBMU0J"', +3137 silly registry.get 'x-served-by': 'cache-dfw1824-DFW', +3137 silly registry.get 'x-cache': 'HIT', +3137 silly registry.get 'x-cache-hits': '2', +3137 silly registry.get 'x-timer': 'S1411067672.178386,VS0,VE0', +3137 silly registry.get vary: 'Accept', +3137 silly registry.get 'content-length': '0', +3137 silly registry.get 'keep-alive': 'timeout=10, max=38', +3137 silly registry.get connection: 'Keep-Alive' } ] +3138 verbose etag https://registry.npmjs.org/wordwrap from cache +3139 http 304 https://registry.npmjs.org/abbrev +3140 silly registry.get cb [ 304, +3140 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3140 silly registry.get server: 'Apache', +3140 silly registry.get via: '1.1 varnish', +3140 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3140 silly registry.get 'cache-control': 'max-age=60', +3140 silly registry.get etag: '"CY41WQX3SN6P2Z9FH9M7NUQHN"', +3140 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +3140 silly registry.get 'x-cache': 'HIT', +3140 silly registry.get 'x-cache-hits': '1', +3140 silly registry.get 'x-timer': 'S1411067672.186941,VS0,VE0', +3140 silly registry.get vary: 'Accept', +3140 silly registry.get 'content-length': '0', +3140 silly registry.get 'keep-alive': 'timeout=10, max=37', +3140 silly registry.get connection: 'Keep-Alive' } ] +3141 verbose etag https://registry.npmjs.org/abbrev from cache +3142 http 304 https://registry.npmjs.org/argparse +3143 silly registry.get cb [ 304, +3143 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3143 silly registry.get server: 'Apache', +3143 silly registry.get via: '1.1 varnish', +3143 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3143 silly registry.get 'cache-control': 'max-age=60', +3143 silly registry.get etag: '"8HKRQPWF6RXGLV2K36IWPQ7PE"', +3143 silly registry.get 'x-served-by': 'cache-dfw1829-DFW', +3143 silly registry.get 'x-cache': 'HIT', +3143 silly registry.get 'x-cache-hits': '1', +3143 silly registry.get 'x-timer': 'S1411067672.189258,VS0,VE0', +3143 silly registry.get vary: 'Accept', +3143 silly registry.get 'content-length': '0', +3143 silly registry.get 'keep-alive': 'timeout=10, max=42', +3143 silly registry.get connection: 'Keep-Alive' } ] +3144 verbose etag https://registry.npmjs.org/argparse from cache +3145 verbose registry.get https://registry.npmjs.org/underscore not expired, no request +3146 verbose registry.get https://registry.npmjs.org/underscore.string not expired, no request +3147 http 304 https://registry.npmjs.org/amdefine +3148 silly registry.get cb [ 304, +3148 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3148 silly registry.get server: 'Apache', +3148 silly registry.get via: '1.1 varnish', +3148 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:31 GMT', +3148 silly registry.get 'cache-control': 'max-age=60', +3148 silly registry.get etag: '"7YJYSZE54QIQX5HOS2BLMK126"', +3148 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +3148 silly registry.get 'x-cache': 'HIT', +3148 silly registry.get 'x-cache-hits': '2', +3148 silly registry.get 'x-timer': 'S1411067672.246919,VS0,VE0', +3148 silly registry.get vary: 'Accept', +3148 silly registry.get 'content-length': '0', +3148 silly registry.get 'keep-alive': 'timeout=10, max=36', +3148 silly registry.get connection: 'Keep-Alive' } ] +3149 verbose etag https://registry.npmjs.org/amdefine from cache +3150 http 304 https://registry.npmjs.org/uid-number +3151 silly registry.get cb [ 304, +3151 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3151 silly registry.get server: 'Apache', +3151 silly registry.get via: '1.1 varnish', +3151 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3151 silly registry.get 'cache-control': 'max-age=60', +3151 silly registry.get etag: '"99K6WWBTV8N7ZCPWAV4NFEONE"', +3151 silly registry.get 'x-served-by': 'cache-dfw1820-DFW', +3151 silly registry.get 'x-cache': 'HIT', +3151 silly registry.get 'x-cache-hits': '1', +3151 silly registry.get 'x-timer': 'S1411067672.128714,VS0,VE179', +3151 silly registry.get vary: 'Accept', +3151 silly registry.get 'content-length': '0', +3151 silly registry.get 'keep-alive': 'timeout=10, max=44', +3151 silly registry.get connection: 'Keep-Alive' } ] +3152 verbose etag https://registry.npmjs.org/uid-number from cache +3153 http 304 https://registry.npmjs.org/amdefine +3154 silly registry.get cb [ 304, +3154 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3154 silly registry.get server: 'Apache', +3154 silly registry.get via: '1.1 varnish', +3154 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:28 GMT', +3154 silly registry.get 'cache-control': 'max-age=60', +3154 silly registry.get etag: '"7YJYSZE54QIQX5HOS2BLMK126"', +3154 silly registry.get 'x-served-by': 'cache-dfw1820-DFW', +3154 silly registry.get 'x-cache': 'HIT', +3154 silly registry.get 'x-cache-hits': '2', +3154 silly registry.get 'x-timer': 'S1411067672.367982,VS0,VE0', +3154 silly registry.get vary: 'Accept', +3154 silly registry.get 'content-length': '0', +3154 silly registry.get 'keep-alive': 'timeout=10, max=43', +3154 silly registry.get connection: 'Keep-Alive' } ] +3155 verbose etag https://registry.npmjs.org/amdefine from cache +3156 http 304 https://registry.npmjs.org/urix +3157 silly registry.get cb [ 304, +3157 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3157 silly registry.get server: 'Apache', +3157 silly registry.get via: '1.1 varnish', +3157 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3157 silly registry.get 'cache-control': 'max-age=60', +3157 silly registry.get etag: '"35KRF5V0AFEWMEL158IFFJM2I"', +3157 silly registry.get 'x-served-by': 'cache-dfw1824-DFW', +3157 silly registry.get 'x-cache': 'HIT', +3157 silly registry.get 'x-cache-hits': '1', +3157 silly registry.get 'x-timer': 'S1411067672.238406,VS0,VE179', +3157 silly registry.get vary: 'Accept', +3157 silly registry.get 'content-length': '0', +3157 silly registry.get 'keep-alive': 'timeout=10, max=37', +3157 silly registry.get connection: 'Keep-Alive' } ] +3158 verbose etag https://registry.npmjs.org/urix from cache +3159 http 304 https://registry.npmjs.org/urix +3160 silly registry.get cb [ 304, +3160 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3160 silly registry.get server: 'Apache', +3160 silly registry.get via: '1.1 varnish', +3160 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3160 silly registry.get 'cache-control': 'max-age=60', +3160 silly registry.get etag: '"35KRF5V0AFEWMEL158IFFJM2I"', +3160 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +3160 silly registry.get 'x-cache': 'HIT', +3160 silly registry.get 'x-cache-hits': '1', +3160 silly registry.get 'x-timer': 'S1411067672.312232,VS0,VE109', +3160 silly registry.get vary: 'Accept', +3160 silly registry.get 'content-length': '0', +3160 silly registry.get 'keep-alive': 'timeout=10, max=35', +3160 silly registry.get connection: 'Keep-Alive' } ] +3161 verbose etag https://registry.npmjs.org/urix from cache +3162 http 304 https://registry.npmjs.org/core-util-is +3163 silly registry.get cb [ 304, +3163 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3163 silly registry.get server: 'Apache', +3163 silly registry.get via: '1.1 varnish', +3163 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3163 silly registry.get 'cache-control': 'max-age=60', +3163 silly registry.get etag: '"1DM3AHIM42HCDO4GJ71NHQO3O"', +3163 silly registry.get 'x-served-by': 'cache-dfw1820-DFW', +3163 silly registry.get 'x-cache': 'HIT', +3163 silly registry.get 'x-cache-hits': '1', +3163 silly registry.get 'x-timer': 'S1411067672.428115,VS0,VE0', +3163 silly registry.get vary: 'Accept', +3163 silly registry.get 'content-length': '0', +3163 silly registry.get 'keep-alive': 'timeout=10, max=42', +3163 silly registry.get connection: 'Keep-Alive' } ] +3164 verbose etag https://registry.npmjs.org/core-util-is from cache +3165 http 304 https://registry.npmjs.org/source-map-resolve +3166 silly registry.get cb [ 304, +3166 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3166 silly registry.get server: 'Apache', +3166 silly registry.get via: '1.1 varnish', +3166 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3166 silly registry.get 'cache-control': 'max-age=60', +3166 silly registry.get etag: '"472ZFA0TX4Z6BZJYCCDUNMN1B"', +3166 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +3166 silly registry.get 'x-cache': 'HIT', +3166 silly registry.get 'x-cache-hits': '1', +3166 silly registry.get 'x-timer': 'S1411067672.213561,VS0,VE260', +3166 silly registry.get vary: 'Accept', +3166 silly registry.get 'content-length': '0', +3166 silly registry.get 'keep-alive': 'timeout=10, max=36', +3166 silly registry.get connection: 'Keep-Alive' } ] +3167 verbose etag https://registry.npmjs.org/source-map-resolve from cache +3168 http 304 https://registry.npmjs.org/source-map-resolve +3169 silly registry.get cb [ 304, +3169 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3169 silly registry.get server: 'Apache', +3169 silly registry.get via: '1.1 varnish', +3169 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3169 silly registry.get 'cache-control': 'max-age=60', +3169 silly registry.get etag: '"472ZFA0TX4Z6BZJYCCDUNMN1B"', +3169 silly registry.get 'x-served-by': 'cache-dfw1829-DFW', +3169 silly registry.get 'x-cache': 'HIT', +3169 silly registry.get 'x-cache-hits': '1', +3169 silly registry.get 'x-timer': 'S1411067672.249836,VS0,VE223', +3169 silly registry.get vary: 'Accept', +3169 silly registry.get 'content-length': '0', +3169 silly registry.get 'keep-alive': 'timeout=10, max=41', +3169 silly registry.get connection: 'Keep-Alive' } ] +3170 verbose etag https://registry.npmjs.org/source-map-resolve from cache +3171 http 304 https://registry.npmjs.org/isarray +3172 silly registry.get cb [ 304, +3172 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3172 silly registry.get server: 'Apache', +3172 silly registry.get via: '1.1 varnish', +3172 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:23 GMT', +3172 silly registry.get 'cache-control': 'max-age=60', +3172 silly registry.get etag: '"C9G6KLTFV9E8I4RST21BBF653"', +3172 silly registry.get 'x-served-by': 'cache-dfw1824-DFW', +3172 silly registry.get 'x-cache': 'HIT', +3172 silly registry.get 'x-cache-hits': '2', +3172 silly registry.get 'x-timer': 'S1411067672.478622,VS0,VE0', +3172 silly registry.get vary: 'Accept', +3172 silly registry.get 'content-length': '0', +3172 silly registry.get 'keep-alive': 'timeout=10, max=36', +3172 silly registry.get connection: 'Keep-Alive' } ] +3173 verbose etag https://registry.npmjs.org/isarray from cache +3174 http 304 https://registry.npmjs.org/string_decoder +3175 silly registry.get cb [ 304, +3175 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3175 silly registry.get server: 'Apache', +3175 silly registry.get via: '1.1 varnish', +3175 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3175 silly registry.get 'cache-control': 'max-age=60', +3175 silly registry.get etag: '"5LTQBGJLEFFY5DM9FI1YPLE02"', +3175 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +3175 silly registry.get 'x-cache': 'HIT', +3175 silly registry.get 'x-cache-hits': '1', +3175 silly registry.get 'x-timer': 'S1411067672.481696,VS0,VE0', +3175 silly registry.get vary: 'Accept', +3175 silly registry.get 'content-length': '0', +3175 silly registry.get 'keep-alive': 'timeout=10, max=34', +3175 silly registry.get connection: 'Keep-Alive' } ] +3176 verbose etag https://registry.npmjs.org/string_decoder from cache +3177 verbose request where is /source-map-url +3178 verbose request registry https://registry.npmjs.org/ +3179 verbose url raw /source-map-url +3180 verbose url resolving [ 'https://registry.npmjs.org/', './source-map-url' ] +3181 verbose url resolved https://registry.npmjs.org/source-map-url +3182 verbose request where is https://registry.npmjs.org/source-map-url +3183 info trying registry request attempt 1 at 15:14:32 +3184 verbose etag "3SYTGKV2U1LR6SPRTGTAY38I0" +3185 http GET https://registry.npmjs.org/source-map-url +3186 verbose request where is /atob +3187 verbose request registry https://registry.npmjs.org/ +3188 verbose url raw /atob +3189 verbose url resolving [ 'https://registry.npmjs.org/', './atob' ] +3190 verbose url resolved https://registry.npmjs.org/atob +3191 verbose request where is https://registry.npmjs.org/atob +3192 info trying registry request attempt 1 at 15:14:32 +3193 verbose etag "5ICCKOZ84ZZXKQWRE4I9YU699" +3194 http GET https://registry.npmjs.org/atob +3195 verbose registry.get https://registry.npmjs.org/urix not expired, no request +3196 verbose request where is /resolve-url +3197 verbose request registry https://registry.npmjs.org/ +3198 verbose url raw /resolve-url +3199 verbose url resolving [ 'https://registry.npmjs.org/', './resolve-url' ] +3200 verbose url resolved https://registry.npmjs.org/resolve-url +3201 verbose request where is https://registry.npmjs.org/resolve-url +3202 info trying registry request attempt 1 at 15:14:32 +3203 verbose etag "90YARTCD88832ISWWP7J5T15W" +3204 http GET https://registry.npmjs.org/resolve-url +3205 verbose request where is /source-map-url +3206 verbose request registry https://registry.npmjs.org/ +3207 verbose url raw /source-map-url +3208 verbose url resolving [ 'https://registry.npmjs.org/', './source-map-url' ] +3209 verbose url resolved https://registry.npmjs.org/source-map-url +3210 verbose request where is https://registry.npmjs.org/source-map-url +3211 info trying registry request attempt 1 at 15:14:32 +3212 verbose etag "3SYTGKV2U1LR6SPRTGTAY38I0" +3213 http GET https://registry.npmjs.org/source-map-url +3214 verbose request where is /atob +3215 verbose request registry https://registry.npmjs.org/ +3216 verbose url raw /atob +3217 verbose url resolving [ 'https://registry.npmjs.org/', './atob' ] +3218 verbose url resolved https://registry.npmjs.org/atob +3219 verbose request where is https://registry.npmjs.org/atob +3220 info trying registry request attempt 1 at 15:14:32 +3221 verbose etag "5ICCKOZ84ZZXKQWRE4I9YU699" +3222 http GET https://registry.npmjs.org/atob +3223 verbose registry.get https://registry.npmjs.org/urix not expired, no request +3224 verbose request where is /resolve-url +3225 verbose request registry https://registry.npmjs.org/ +3226 verbose url raw /resolve-url +3227 verbose url resolving [ 'https://registry.npmjs.org/', './resolve-url' ] +3228 verbose url resolved https://registry.npmjs.org/resolve-url +3229 verbose request where is https://registry.npmjs.org/resolve-url +3230 info trying registry request attempt 1 at 15:14:32 +3231 verbose etag "90YARTCD88832ISWWP7J5T15W" +3232 http GET https://registry.npmjs.org/resolve-url +3233 http 304 https://registry.npmjs.org/balanced-match +3234 silly registry.get cb [ 304, +3234 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3234 silly registry.get server: 'Apache', +3234 silly registry.get via: '1.1 varnish', +3234 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3234 silly registry.get 'cache-control': 'max-age=60', +3234 silly registry.get etag: '"EZUFM9SYH8LMSJ7SI2N6V5DX8"', +3234 silly registry.get 'x-served-by': 'cache-dfw1829-DFW', +3234 silly registry.get 'x-cache': 'HIT', +3234 silly registry.get 'x-cache-hits': '3', +3234 silly registry.get 'x-timer': 'S1411067672.537857,VS0,VE0', +3234 silly registry.get vary: 'Accept', +3234 silly registry.get 'content-length': '0', +3234 silly registry.get 'keep-alive': 'timeout=10, max=40', +3234 silly registry.get connection: 'Keep-Alive' } ] +3235 verbose etag https://registry.npmjs.org/balanced-match from cache +3236 http 304 https://registry.npmjs.org/StringScanner +3237 silly registry.get cb [ 304, +3237 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3237 silly registry.get server: 'Apache', +3237 silly registry.get via: '1.1 varnish', +3237 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 18:51:29 GMT', +3237 silly registry.get 'cache-control': 'max-age=60', +3237 silly registry.get etag: '"1T3THJ00T97BGQJPQG4BQABM6"', +3237 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +3237 silly registry.get 'x-cache': 'HIT', +3237 silly registry.get 'x-cache-hits': '15', +3237 silly registry.get 'x-timer': 'S1411067672.546523,VS0,VE0', +3237 silly registry.get vary: 'Accept', +3237 silly registry.get 'content-length': '0', +3237 silly registry.get 'keep-alive': 'timeout=10, max=33', +3237 silly registry.get connection: 'Keep-Alive' } ] +3238 verbose etag https://registry.npmjs.org/StringScanner from cache +3239 http 304 https://registry.npmjs.org/color +3240 silly registry.get cb [ 304, +3240 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3240 silly registry.get server: 'Apache', +3240 silly registry.get via: '1.1 varnish', +3240 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3240 silly registry.get 'cache-control': 'max-age=60', +3240 silly registry.get etag: '"E0TQQ4DZNV49MCL5ZTVOYAGZH"', +3240 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +3240 silly registry.get 'x-cache': 'HIT', +3240 silly registry.get 'x-cache-hits': '1', +3240 silly registry.get 'x-timer': 'S1411067672.533479,VS0,VE46', +3240 silly registry.get vary: 'Accept', +3240 silly registry.get 'content-length': '0', +3240 silly registry.get 'keep-alive': 'timeout=10, max=35', +3240 silly registry.get connection: 'Keep-Alive' } ] +3241 verbose etag https://registry.npmjs.org/color from cache +3242 verbose request where is /color-convert +3243 verbose request registry https://registry.npmjs.org/ +3244 verbose url raw /color-convert +3245 verbose url resolving [ 'https://registry.npmjs.org/', './color-convert' ] +3246 verbose url resolved https://registry.npmjs.org/color-convert +3247 verbose request where is https://registry.npmjs.org/color-convert +3248 info trying registry request attempt 1 at 15:14:32 +3249 verbose etag "2TQ4IJ57ELD5ACWVDAQP7ECQE" +3250 http GET https://registry.npmjs.org/color-convert +3251 verbose request where is /color-string +3252 verbose request registry https://registry.npmjs.org/ +3253 verbose url raw /color-string +3254 verbose url resolving [ 'https://registry.npmjs.org/', './color-string' ] +3255 verbose url resolved https://registry.npmjs.org/color-string +3256 verbose request where is https://registry.npmjs.org/color-string +3257 info trying registry request attempt 1 at 15:14:32 +3258 verbose etag "69AP16NBDZ1JPE9XRIFKHGFVG" +3259 http GET https://registry.npmjs.org/color-string +3260 http 304 https://registry.npmjs.org/js-base64 +3261 silly registry.get cb [ 304, +3261 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3261 silly registry.get server: 'Apache', +3261 silly registry.get via: '1.1 varnish', +3261 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3261 silly registry.get 'cache-control': 'max-age=60', +3261 silly registry.get etag: '"4OCPV3R2J75LJYUBAS6C31FZH"', +3261 silly registry.get 'x-served-by': 'cache-dfw1824-DFW', +3261 silly registry.get 'x-cache': 'MISS', +3261 silly registry.get 'x-cache-hits': '0', +3261 silly registry.get 'x-timer': 'S1411067672.543478,VS0,VE40', +3261 silly registry.get vary: 'Accept', +3261 silly registry.get 'content-length': '0', +3261 silly registry.get 'keep-alive': 'timeout=10, max=35', +3261 silly registry.get connection: 'Keep-Alive' } ] +3262 verbose etag https://registry.npmjs.org/js-base64 from cache +3263 http 304 https://registry.npmjs.org/esmangle +3264 silly registry.get cb [ 304, +3264 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3264 silly registry.get server: 'Apache', +3264 silly registry.get via: '1.1 varnish', +3264 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3264 silly registry.get 'cache-control': 'max-age=60', +3264 silly registry.get etag: '"A7GAD892KX1EYPRNZXM9UVRXV"', +3264 silly registry.get 'x-served-by': 'cache-dfw1829-DFW', +3264 silly registry.get 'x-cache': 'HIT', +3264 silly registry.get 'x-cache-hits': '1', +3264 silly registry.get 'x-timer': 'S1411067672.597081,VS0,VE0', +3264 silly registry.get vary: 'Accept', +3264 silly registry.get 'content-length': '0', +3264 silly registry.get 'keep-alive': 'timeout=10, max=39', +3264 silly registry.get connection: 'Keep-Alive' } ] +3265 verbose etag https://registry.npmjs.org/esmangle from cache +3266 http 304 https://registry.npmjs.org/proto-list +3267 silly registry.get cb [ 304, +3267 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3267 silly registry.get server: 'Apache', +3267 silly registry.get via: '1.1 varnish', +3267 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3267 silly registry.get 'cache-control': 'max-age=60', +3267 silly registry.get etag: '"E2O0J3M4623CMOR3Q4IF96VSZ"', +3267 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +3267 silly registry.get 'x-cache': 'HIT', +3267 silly registry.get 'x-cache-hits': '1', +3267 silly registry.get 'x-timer': 'S1411067672.606464,VS0,VE0', +3267 silly registry.get vary: 'Accept', +3267 silly registry.get 'content-length': '0', +3267 silly registry.get 'keep-alive': 'timeout=10, max=32', +3267 silly registry.get connection: 'Keep-Alive' } ] +3268 verbose etag https://registry.npmjs.org/proto-list from cache +3269 http 304 https://registry.npmjs.org/ini +3270 silly registry.get cb [ 304, +3270 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3270 silly registry.get server: 'Apache', +3270 silly registry.get via: '1.1 varnish', +3270 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3270 silly registry.get 'cache-control': 'max-age=60', +3270 silly registry.get etag: '"754C7G0ESHIITOZZPDILT5SFP"', +3270 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +3270 silly registry.get 'x-cache': 'HIT', +3270 silly registry.get 'x-cache-hits': '2', +3270 silly registry.get 'x-timer': 'S1411067672.639470,VS0,VE0', +3270 silly registry.get vary: 'Accept', +3270 silly registry.get 'content-length': '0', +3270 silly registry.get 'keep-alive': 'timeout=10, max=34', +3270 silly registry.get connection: 'Keep-Alive' } ] +3271 verbose etag https://registry.npmjs.org/ini from cache +3272 http 304 https://registry.npmjs.org/burrito +3273 silly registry.get cb [ 304, +3273 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3273 silly registry.get server: 'Apache', +3273 silly registry.get via: '1.1 varnish', +3273 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3273 silly registry.get 'cache-control': 'max-age=60', +3273 silly registry.get etag: '"HKUZ6SXXVQOCUAOMQ430XCS5"', +3273 silly registry.get 'x-served-by': 'cache-dfw1820-DFW', +3273 silly registry.get 'x-cache': 'HIT', +3273 silly registry.get 'x-cache-hits': '1', +3273 silly registry.get 'x-timer': 'S1411067672.487941,VS0,VE183', +3273 silly registry.get vary: 'Accept', +3273 silly registry.get 'content-length': '0', +3273 silly registry.get 'keep-alive': 'timeout=10, max=41', +3273 silly registry.get connection: 'Keep-Alive' } ] +3274 verbose etag https://registry.npmjs.org/burrito from cache +3275 verbose registry.get https://registry.npmjs.org/traverse not expired, no request +3276 verbose request where is /uglify-js +3277 verbose request registry https://registry.npmjs.org/ +3278 verbose url raw /uglify-js +3279 verbose url resolving [ 'https://registry.npmjs.org/', './uglify-js' ] +3280 verbose url resolved https://registry.npmjs.org/uglify-js +3281 verbose request where is https://registry.npmjs.org/uglify-js +3282 info trying registry request attempt 1 at 15:14:32 +3283 verbose etag "8O3H3O825WHNHD4EWH1RQ1N6T" +3284 http GET https://registry.npmjs.org/uglify-js +3285 http 304 https://registry.npmjs.org/source-map-url +3286 silly registry.get cb [ 304, +3286 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3286 silly registry.get server: 'Apache', +3286 silly registry.get via: '1.1 varnish', +3286 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3286 silly registry.get 'cache-control': 'max-age=60', +3286 silly registry.get etag: '"3SYTGKV2U1LR6SPRTGTAY38I0"', +3286 silly registry.get 'x-served-by': 'cache-dfw1824-DFW', +3286 silly registry.get 'x-cache': 'HIT', +3286 silly registry.get 'x-cache-hits': '1', +3286 silly registry.get 'x-timer': 'S1411067672.650016,VS0,VE74', +3286 silly registry.get vary: 'Accept', +3286 silly registry.get 'content-length': '0', +3286 silly registry.get 'keep-alive': 'timeout=10, max=34', +3286 silly registry.get connection: 'Keep-Alive' } ] +3287 verbose etag https://registry.npmjs.org/source-map-url from cache +3288 http 304 https://registry.npmjs.org/source-map-url +3289 silly registry.get cb [ 304, +3289 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3289 silly registry.get server: 'Apache', +3289 silly registry.get via: '1.1 varnish', +3289 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3289 silly registry.get 'cache-control': 'max-age=60', +3289 silly registry.get etag: '"3SYTGKV2U1LR6SPRTGTAY38I0"', +3289 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +3289 silly registry.get 'x-cache': 'HIT', +3289 silly registry.get 'x-cache-hits': '1', +3289 silly registry.get 'x-timer': 'S1411067672.713792,VS0,VE12', +3289 silly registry.get vary: 'Accept', +3289 silly registry.get 'content-length': '0', +3289 silly registry.get 'keep-alive': 'timeout=10, max=33', +3289 silly registry.get connection: 'Keep-Alive' } ] +3290 verbose etag https://registry.npmjs.org/source-map-url from cache +3291 http 304 https://registry.npmjs.org/resolve-url +3292 silly registry.get cb [ 304, +3292 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3292 silly registry.get server: 'Apache', +3292 silly registry.get via: '1.1 varnish', +3292 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3292 silly registry.get 'cache-control': 'max-age=60', +3292 silly registry.get etag: '"90YARTCD88832ISWWP7J5T15W"', +3292 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +3292 silly registry.get 'x-cache': 'HIT', +3292 silly registry.get 'x-cache-hits': '1', +3292 silly registry.get 'x-timer': 'S1411067672.686099,VS0,VE57', +3292 silly registry.get vary: 'Accept', +3292 silly registry.get 'content-length': '0', +3292 silly registry.get 'keep-alive': 'timeout=10, max=31', +3292 silly registry.get connection: 'Keep-Alive' } ] +3293 verbose etag https://registry.npmjs.org/resolve-url from cache +3294 http 304 https://registry.npmjs.org/atob +3295 silly registry.get cb [ 304, +3295 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3295 silly registry.get server: 'Apache', +3295 silly registry.get via: '1.1 varnish', +3295 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3295 silly registry.get 'cache-control': 'max-age=60', +3295 silly registry.get etag: '"5ICCKOZ84ZZXKQWRE4I9YU699"', +3295 silly registry.get 'x-served-by': 'cache-dfw1829-DFW', +3295 silly registry.get 'x-cache': 'HIT', +3295 silly registry.get 'x-cache-hits': '1', +3295 silly registry.get 'x-timer': 'S1411067672.678688,VS0,VE63', +3295 silly registry.get vary: 'Accept', +3295 silly registry.get 'content-length': '0', +3295 silly registry.get 'keep-alive': 'timeout=10, max=38', +3295 silly registry.get connection: 'Keep-Alive' } ] +3296 verbose etag https://registry.npmjs.org/atob from cache +3297 http 304 https://registry.npmjs.org/atob +3298 silly registry.get cb [ 304, +3298 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3298 silly registry.get server: 'Apache', +3298 silly registry.get via: '1.1 varnish', +3298 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3298 silly registry.get 'cache-control': 'max-age=60', +3298 silly registry.get etag: '"5ICCKOZ84ZZXKQWRE4I9YU699"', +3298 silly registry.get 'x-served-by': 'cache-dfw1820-DFW', +3298 silly registry.get 'x-cache': 'HIT', +3298 silly registry.get 'x-cache-hits': '1', +3298 silly registry.get 'x-timer': 'S1411067672.743481,VS0,VE0', +3298 silly registry.get vary: 'Accept', +3298 silly registry.get 'content-length': '0', +3298 silly registry.get 'keep-alive': 'timeout=10, max=40', +3298 silly registry.get connection: 'Keep-Alive' } ] +3299 verbose etag https://registry.npmjs.org/atob from cache +3300 http 304 https://registry.npmjs.org/resolve-url +3301 silly registry.get cb [ 304, +3301 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3301 silly registry.get server: 'Apache', +3301 silly registry.get via: '1.1 varnish', +3301 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3301 silly registry.get 'cache-control': 'max-age=60', +3301 silly registry.get etag: '"90YARTCD88832ISWWP7J5T15W"', +3301 silly registry.get 'x-served-by': 'cache-dfw1824-DFW', +3301 silly registry.get 'x-cache': 'HIT', +3301 silly registry.get 'x-cache-hits': '1', +3301 silly registry.get 'x-timer': 'S1411067672.788967,VS0,VE0', +3301 silly registry.get vary: 'Accept', +3301 silly registry.get 'content-length': '0', +3301 silly registry.get 'keep-alive': 'timeout=10, max=33', +3301 silly registry.get connection: 'Keep-Alive' } ] +3302 verbose etag https://registry.npmjs.org/resolve-url from cache +3303 http 304 https://registry.npmjs.org/uglify-js +3304 silly registry.get cb [ 304, +3304 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3304 silly registry.get server: 'Apache', +3304 silly registry.get via: '1.1 varnish', +3304 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3304 silly registry.get 'cache-control': 'max-age=60', +3304 silly registry.get etag: '"8O3H3O825WHNHD4EWH1RQ1N6T"', +3304 silly registry.get 'x-served-by': 'cache-dfw1829-DFW', +3304 silly registry.get 'x-cache': 'HIT', +3304 silly registry.get 'x-cache-hits': '2', +3304 silly registry.get 'x-timer': 'S1411067672.806054,VS0,VE0', +3304 silly registry.get vary: 'Accept', +3304 silly registry.get 'content-length': '0', +3304 silly registry.get 'keep-alive': 'timeout=10, max=37', +3304 silly registry.get connection: 'Keep-Alive' } ] +3305 verbose etag https://registry.npmjs.org/uglify-js from cache +3306 http 304 https://registry.npmjs.org/color-string +3307 silly registry.get cb [ 304, +3307 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3307 silly registry.get server: 'Apache', +3307 silly registry.get via: '1.1 varnish', +3307 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:32 GMT', +3307 silly registry.get 'cache-control': 'max-age=60', +3307 silly registry.get etag: '"69AP16NBDZ1JPE9XRIFKHGFVG"', +3307 silly registry.get 'x-served-by': 'cache-dfw1830-DFW', +3307 silly registry.get 'x-cache': 'HIT', +3307 silly registry.get 'x-cache-hits': '1', +3307 silly registry.get 'x-timer': 'S1411067672.803685,VS0,VE63', +3307 silly registry.get vary: 'Accept', +3307 silly registry.get 'content-length': '0', +3307 silly registry.get 'keep-alive': 'timeout=10, max=30', +3307 silly registry.get connection: 'Keep-Alive' } ] +3308 verbose etag https://registry.npmjs.org/color-string from cache +3309 verbose request where is /color-convert +3310 verbose request registry https://registry.npmjs.org/ +3311 verbose url raw /color-convert +3312 verbose url resolving [ 'https://registry.npmjs.org/', './color-convert' ] +3313 verbose url resolved https://registry.npmjs.org/color-convert +3314 verbose request where is https://registry.npmjs.org/color-convert +3315 info trying registry request attempt 1 at 15:14:32 +3316 verbose etag "2TQ4IJ57ELD5ACWVDAQP7ECQE" +3317 http GET https://registry.npmjs.org/color-convert +3318 http 304 https://registry.npmjs.org/color-convert +3319 silly registry.get cb [ 304, +3319 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:32 GMT', +3319 silly registry.get server: 'Apache', +3319 silly registry.get via: '1.1 varnish', +3319 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:33 GMT', +3319 silly registry.get 'cache-control': 'max-age=60', +3319 silly registry.get etag: '"2TQ4IJ57ELD5ACWVDAQP7ECQE"', +3319 silly registry.get 'x-served-by': 'cache-dfw1835-DFW', +3319 silly registry.get 'x-cache': 'HIT', +3319 silly registry.get 'x-cache-hits': '1', +3319 silly registry.get 'x-timer': 'S1411067672.790336,VS0,VE254', +3319 silly registry.get vary: 'Accept', +3319 silly registry.get 'content-length': '0', +3319 silly registry.get 'keep-alive': 'timeout=10, max=32', +3319 silly registry.get connection: 'Keep-Alive' } ] +3320 verbose etag https://registry.npmjs.org/color-convert from cache +3321 http 304 https://registry.npmjs.org/color-convert +3322 silly registry.get cb [ 304, +3322 silly registry.get { date: 'Thu, 18 Sep 2014 19:14:33 GMT', +3322 silly registry.get server: 'Apache', +3322 silly registry.get via: '1.1 varnish', +3322 silly registry.get 'last-modified': 'Thu, 18 Sep 2014 19:14:33 GMT', +3322 silly registry.get 'cache-control': 'max-age=60', +3322 silly registry.get etag: '"2TQ4IJ57ELD5ACWVDAQP7ECQE"', +3322 silly registry.get 'x-served-by': 'cache-dfw1823-DFW', +3322 silly registry.get 'x-cache': 'HIT', +3322 silly registry.get 'x-cache-hits': '1', +3322 silly registry.get 'x-timer': 'S1411067673.117470,VS0,VE0', +3322 silly registry.get vary: 'Accept', +3322 silly registry.get 'content-length': '0', +3322 silly registry.get 'keep-alive': 'timeout=10, max=50', +3322 silly registry.get connection: 'Keep-Alive' } ] +3323 verbose etag https://registry.npmjs.org/color-convert from cache +3324 info outdated updating [ [ '/usr/lib', 'npm', '1.4.28', '1.4.27', '1.4.27', 'latest' ], +3324 info outdated [ '/usr/lib/node_modules/karma-coffee-preprocessor', +3324 info outdated 'coffee-script', +3324 info outdated '1.7.1', +3324 info outdated '1.7.1', +3324 info outdated '1.8.0', +3324 info outdated '~1.7' ], +3324 info outdated [ '/usr/lib/node_modules/express-generator', +3324 info outdated 'commander', +3324 info outdated '1.3.2', +3324 info outdated '1.3.2', +3324 info outdated '2.3.0', +3324 info outdated '1.3.2' ], +3324 info outdated [ '/usr/lib/node_modules/express-generator/node_modules/mkdirp', +3324 info outdated 'minimist', +3324 info outdated '0.0.8', +3324 info outdated '0.0.8', +3324 info outdated '1.1.0', +3324 info outdated '0.0.8' ], +3324 info outdated [ '/usr/lib/node_modules/grunt-cli', +3324 info outdated 'nopt', +3324 info outdated '1.0.10', +3324 info outdated '1.0.10', +3324 info outdated '3.0.1', +3324 info outdated '~1.0.10' ], +3324 info outdated [ '/usr/lib/node_modules/grunt-cli', +3324 info outdated 'resolve', +3324 info outdated '0.3.1', +3324 info outdated '0.3.1', +3324 info outdated '1.0.0', +3324 info outdated '~0.3.1' ], +3324 info outdated [ '/usr/lib/node_modules/grunt-cli/node_modules/findup-sync', +3324 info outdated 'glob', +3324 info outdated '3.2.11', +3324 info outdated '3.2.11', +3324 info outdated '4.0.6', +3324 info outdated '~3.2.9' ], +3324 info outdated [ '/usr/lib/node_modules/zombie', +3324 info outdated 'html5', +3324 info outdated '0.3.14', +3324 info outdated '0.3.14', +3324 info outdated '1.0.5', +3324 info outdated '0.3.14' ], +3324 info outdated [ '/usr/lib/node_modules/zombie', +3324 info outdated 'eventsource', +3324 info outdated '0.0.10', +3324 info outdated '0.0.10', +3324 info outdated '0.1.3', +3324 info outdated '0.0.10' ], +3324 info outdated [ '/usr/lib/node_modules/zombie', +3324 info outdated 'q', +3324 info outdated '1.0.0', +3324 info outdated '1.0.0', +3324 info outdated '1.0.1', +3324 info outdated '1.0.0' ], +3324 info outdated [ '/usr/lib/node_modules/zombie', +3324 info outdated 'request', +3324 info outdated '2.34.0', +3324 info outdated '2.34.0', +3324 info outdated '2.44.0', +3324 info outdated '2.34.0' ], +3324 info outdated [ '/usr/lib/node_modules/zombie', +3324 info outdated 'ws', +3324 info outdated '0.4.31', +3324 info outdated '0.4.31', +3324 info outdated '0.4.32', +3324 info outdated '0.4.31' ], +3324 info outdated [ '/usr/lib/node_modules/zombie', +3324 info outdated 'encoding', +3324 info outdated '0.1.7', +3324 info outdated '0.1.7', +3324 info outdated '0.1.8', +3324 info outdated '0.1.7' ], +3324 info outdated [ '/usr/lib/node_modules/zombie', +3324 info outdated 'jsdom', +3324 info outdated '0.8.11', +3324 info outdated '0.8.11', +3324 info outdated '1.0.0-pre.6', +3324 info outdated '0.8.11' ], +3324 info outdated [ '/usr/lib/node_modules/grunt', +3324 info outdated 'dateformat', +3324 info outdated '1.0.2-1.2.3', +3324 info outdated '1.0.2-1.2.3', +3324 info outdated '1.0.8', +3324 info outdated '1.0.2-1.2.3' ], +3324 info outdated [ '/usr/lib/node_modules/grunt', +3324 info outdated 'glob', +3324 info outdated '3.1.21', +3324 info outdated '3.1.21', +3324 info outdated '4.0.6', +3324 info outdated '~3.1.21' ], +3324 info outdated [ '/usr/lib/node_modules/grunt', +3324 info outdated 'lodash', +3324 info outdated '0.9.2', +3324 info outdated '0.9.2', +3324 info outdated '2.4.1', +3324 info outdated '~0.9.2' ], +3324 info outdated [ '/usr/lib/node_modules/grunt', +3324 info outdated 'nopt', +3324 info outdated '1.0.10', +3324 info outdated '1.0.10', +3324 info outdated '3.0.1', +3324 info outdated '~1.0.10' ], +3324 info outdated [ '/usr/lib/node_modules/grunt', +3324 info outdated 'underscore.string', +3324 info outdated '2.2.1', +3324 info outdated '2.2.1', +3324 info outdated '2.3.3', +3324 info outdated '~2.2.1' ], +3324 info outdated [ '/usr/lib/node_modules/grunt', +3324 info outdated 'iconv-lite', +3324 info outdated '0.2.11', +3324 info outdated '0.2.11', +3324 info outdated '0.4.4', +3324 info outdated '~0.2.11' ], +3324 info outdated [ '/usr/lib/node_modules/grunt', +3324 info outdated 'coffee-script', +3324 info outdated '1.3.3', +3324 info outdated '1.3.3', +3324 info outdated '1.8.0', +3324 info outdated '~1.3.3' ], +3324 info outdated [ '/usr/lib/node_modules/grunt', +3324 info outdated 'minimatch', +3324 info outdated '0.2.14', +3324 info outdated '0.2.14', +3324 info outdated '1.0.0', +3324 info outdated '~0.2.12' ], +3324 info outdated [ '/usr/lib/node_modules/grunt', +3324 info outdated 'js-yaml', +3324 info outdated '2.0.5', +3324 info outdated '2.0.5', +3324 info outdated '3.2.2', +3324 info outdated '~2.0.5' ], +3324 info outdated [ '/usr/lib/node_modules/grunt', +3324 info outdated 'async', +3324 info outdated '0.1.22', +3324 info outdated '0.1.22', +3324 info outdated '0.9.0', +3324 info outdated '~0.1.22' ], +3324 info outdated [ '/usr/lib/node_modules/grunt/node_modules/findup-sync', +3324 info outdated 'glob', +3324 info outdated '3.1.21', +3324 info outdated '3.2.11', +3324 info outdated '4.0.6', +3324 info outdated '~3.2.9' ], +3324 info outdated [ '/usr/lib/node_modules/grunt/node_modules/grunt-legacy-util', +3324 info outdated 'async', +3324 info outdated '0.1.22', +3324 info outdated '0.1.22', +3324 info outdated '0.9.0', +3324 info outdated '~0.1.22' ], +3324 info outdated [ '/usr/lib/node_modules/grunt/node_modules/grunt-legacy-util', +3324 info outdated 'lodash', +3324 info outdated '0.9.2', +3324 info outdated '0.9.2', +3324 info outdated '2.4.1', +3324 info outdated '~0.9.2' ], +3324 info outdated [ '/usr/lib/node_modules/grunt/node_modules/grunt-legacy-util', +3324 info outdated 'underscore.string', +3324 info outdated '2.2.1', +3324 info outdated '2.2.1', +3324 info outdated '2.3.3', +3324 info outdated '~2.2.1' ], +3324 info outdated [ '/usr/lib/node_modules/express', +3324 info outdated 'depd', +3324 info outdated '0.4.5', +3324 info outdated '0.4.5', +3324 info outdated '1.0.0', +3324 info outdated '0.4.5' ], +3324 info outdated [ '/usr/lib/node_modules/express', +3324 info outdated 'finalhandler', +3324 info outdated '0.2.0', +3324 info outdated '0.2.0', +3324 info outdated '0.3.0', +3324 info outdated '0.2.0' ], +3324 info outdated [ '/usr/lib/node_modules/express', +3324 info outdated 'path-to-regexp', +3324 info outdated '0.1.3', +3324 info outdated '0.1.3', +3324 info outdated '1.0.1', +3324 info outdated '0.1.3' ], +3324 info outdated [ '/usr/lib/node_modules/express/node_modules/debug', +3324 info outdated 'ms', +3324 info outdated undefined, +3324 info outdated '0.6.2', +3324 info outdated '0.6.2', +3324 info outdated '0.6.2' ], +3324 info outdated [ '/usr/lib/node_modules/express/node_modules/on-finished', +3324 info outdated 'ee-first', +3324 info outdated undefined, +3324 info outdated '1.0.5', +3324 info outdated '1.0.5', +3324 info outdated '1.0.5' ], +3324 info outdated [ '/usr/lib/node_modules/express/node_modules/accepts', +3324 info outdated 'mime-types', +3324 info outdated undefined, +3324 info outdated '2.0.1', +3324 info outdated '2.0.1', +3324 info outdated '~2.0.0' ], +3324 info outdated [ '/usr/lib/node_modules/express/node_modules/accepts', +3324 info outdated 'negotiator', +3324 info outdated undefined, +3324 info outdated '0.4.7', +3324 info outdated '0.4.7', +3324 info outdated '0.4.7' ], +3324 info outdated [ '/usr/lib/node_modules/express/node_modules/proxy-addr', +3324 info outdated 'ipaddr.js', +3324 info outdated undefined, +3324 info outdated '0.1.3', +3324 info outdated '0.1.3', +3324 info outdated '0.1.3' ], +3324 info outdated [ '/usr/lib/node_modules/express/node_modules/send', +3324 info outdated 'depd', +3324 info outdated '0.4.5', +3324 info outdated '0.4.5', +3324 info outdated '1.0.0', +3324 info outdated '0.4.5' ], +3324 info outdated [ '/usr/lib/node_modules/express/node_modules/send', +3324 info outdated 'mime', +3324 info outdated undefined, +3324 info outdated '1.2.11', +3324 info outdated '1.2.11', +3324 info outdated '1.2.11' ], +3324 info outdated [ '/usr/lib/node_modules/express/node_modules/send', +3324 info outdated 'ms', +3324 info outdated undefined, +3324 info outdated '0.6.2', +3324 info outdated '0.6.2', +3324 info outdated '0.6.2' ], +3324 info outdated [ '/usr/lib/node_modules/express/node_modules/send', +3324 info outdated 'destroy', +3324 info outdated undefined, +3324 info outdated '1.0.3', +3324 info outdated '1.0.3', +3324 info outdated '1.0.3' ], +3324 info outdated [ '/usr/lib/node_modules/express/node_modules/type-is', +3324 info outdated 'mime-types', +3324 info outdated undefined, +3324 info outdated '2.0.1', +3324 info outdated '2.0.1', +3324 info outdated '~2.0.1' ], +3324 info outdated [ '/usr/lib/node_modules/express/node_modules/etag', +3324 info outdated 'crc', +3324 info outdated undefined, +3324 info outdated '3.0.0', +3324 info outdated '3.0.0', +3324 info outdated '3.0.0' ], +3324 info outdated [ '/usr/lib/node_modules/jsdoc', +3324 info outdated 'async', +3324 info outdated '0.1.22', +3324 info outdated '0.1.22', +3324 info outdated '0.9.0', +3324 info outdated '~0.1.22' ], +3324 info outdated [ '/usr/lib/node_modules/jsdoc', +3324 info outdated 'strip-json-comments', +3324 info outdated '0.1.3', +3324 info outdated '0.1.3', +3324 info outdated '1.0.1', +3324 info outdated '~0.1.3' ], +3324 info outdated [ '/usr/lib/node_modules/jsdoc', +3324 info outdated 'underscore', +3324 info outdated '1.6.0', +3324 info outdated '1.6.0', +3324 info outdated '1.7.0', +3324 info outdated '~1.6.0' ], +3324 info outdated [ '/usr/lib/node_modules/jsdoc', +3324 info outdated 'wrench', +3324 info outdated '1.3.9', +3324 info outdated '1.3.9', +3324 info outdated '1.5.8', +3324 info outdated '~1.3.9' ], +3324 info outdated [ '/usr/lib/node_modules/jsdoc/node_modules/requizzle', +3324 info outdated 'underscore', +3324 info outdated '1.6.0', +3324 info outdated '1.6.0', +3324 info outdated '1.7.0', +3324 info outdated '~1.6.0' ], +3324 info outdated [ '/usr/lib/node_modules/jsdoc/node_modules/catharsis/node_modules/underscore-contrib', +3324 info outdated 'underscore', +3324 info outdated '1.6.0', +3324 info outdated '1.6.0', +3324 info outdated '1.7.0', +3324 info outdated '1.6.0' ], +3324 info outdated [ '/usr/lib/node_modules/jsdoc', +3324 info outdated 'taffydb', +3324 info outdated '2.6.2', +3324 info outdated '2.6.2', +3324 info outdated '2.7.2', +3324 info outdated 'https://github.com/hegemonic/taffydb/tarball/master' ], +3324 info outdated [ '/usr/lib/node_modules/jsdoc', +3324 info outdated 'esprima', +3324 info outdated '1.1.0-dev-harmony', +3324 info outdated '1.1.0-dev-harmony', +3324 info outdated '1.2.2', +3324 info outdated 'https://github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c' ], +3324 info outdated [ '/usr/lib/node_modules/vtop', +3324 info outdated 'commander', +3324 info outdated '2.2.0', +3324 info outdated '2.2.0', +3324 info outdated '2.3.0', +3324 info outdated '2.2.0' ], +3324 info outdated [ '/usr/lib/node_modules/vtop', +3324 info outdated 'glob', +3324 info outdated '4.0.4', +3324 info outdated '4.0.4', +3324 info outdated '4.0.6', +3324 info outdated '4.0.4' ], +3324 info outdated [ '/usr/lib/node_modules/vtop', +3324 info outdated 'drawille', +3324 info outdated '0.1.1', +3324 info outdated '0.1.1', +3324 info outdated '1.0.0', +3324 info outdated '0.1.1' ], +3324 info outdated [ '/usr/lib/node_modules/karma', +3324 info outdated 'q', +3324 info outdated '0.9.7', +3324 info outdated '0.9.7', +3324 info outdated '1.0.1', +3324 info outdated '~0.9.7' ], +3324 info outdated [ '/usr/lib/node_modules/karma', +3324 info outdated 'socket.io', +3324 info outdated '0.9.17', +3324 info outdated '0.9.17', +3324 info outdated '1.1.0', +3324 info outdated '~0.9.13' ], +3324 info outdated [ '/usr/lib/node_modules/karma', +3324 info outdated 'glob', +3324 info outdated '3.2.11', +3324 info outdated '3.2.11', +3324 info outdated '4.0.6', +3324 info outdated '~3.2.7' ], +3324 info outdated [ '/usr/lib/node_modules/karma', +3324 info outdated 'http-proxy', +3324 info outdated '0.10.4', +3324 info outdated '0.10.4', +3324 info outdated '1.4.3', +3324 info outdated '~0.10' ], +3324 info outdated [ '/usr/lib/node_modules/karma', +3324 info outdated 'graceful-fs', +3324 info outdated '2.0.3', +3324 info outdated '2.0.3', +3324 info outdated '3.0.2', +3324 info outdated '~2.0.1' ], +3324 info outdated [ '/usr/lib/node_modules/karma', +3324 info outdated 'connect', +3324 info outdated '2.12.0', +3324 info outdated '2.12.0', +3324 info outdated '3.2.0', +3324 info outdated '~2.12.0' ], +3324 info outdated [ '/usr/lib/node_modules/karma', +3324 info outdated 'minimatch', +3324 info outdated '0.2.14', +3324 info outdated '0.2.14', +3324 info outdated '1.0.0', +3324 info outdated '~0.2' ], +3324 info outdated [ '/usr/lib/node_modules/karma/node_modules/optimist', +3324 info outdated 'minimist', +3324 info outdated '0.0.10', +3324 info outdated '0.0.10', +3324 info outdated '1.1.0', +3324 info outdated '~0.0.1' ], +3324 info outdated [ '/usr/lib/node_modules/karma/node_modules/useragent', +3324 info outdated 'lru-cache', +3324 info outdated '2.2.4', +3324 info outdated '2.2.4', +3324 info outdated '2.5.0', +3324 info outdated '2.2.x' ], +3324 info outdated [ '/usr/lib/node_modules/karma/node_modules/chokidar', +3324 info outdated 'fsevents', +3324 info outdated undefined, +3324 info outdated 'git', +3324 info outdated 'git', +3324 info outdated 'git+https://github.com/pipobscure/fsevents#7dcdf9fa3f8956610fd6f69f72c67bace2de7138' ], +3324 info outdated [ '/usr/lib/node_modules/karma/node_modules/chokidar', +3324 info outdated 'recursive-readdir', +3324 info outdated '0.0.2', +3324 info outdated '0.0.2', +3324 info outdated '1.2.0', +3324 info outdated '0.0.2' ], +3324 info outdated [ '/usr/lib/node_modules/karma/node_modules/log4js', +3324 info outdated 'async', +3324 info outdated '0.2.10', +3324 info outdated '0.2.10', +3324 info outdated '0.9.0', +3324 info outdated '~0.2.0' ], +3324 info outdated [ '/usr/lib/node_modules/karma/node_modules/log4js', +3324 info outdated 'semver', +3324 info outdated '1.1.4', +3324 info outdated '1.1.4', +3324 info outdated '3.0.1', +3324 info outdated '~1.1.4' ], +3324 info outdated [ '/usr/lib/node_modules/karma-coverage', +3324 info outdated 'minimatch', +3324 info outdated '0.3.0', +3324 info outdated '0.3.0', +3324 info outdated '1.0.0', +3324 info outdated '~0.3.0' ], +3324 info outdated [ '/usr/lib/node_modules/karma-coverage/node_modules/istanbul', +3324 info outdated 'resolve', +3324 info outdated '0.7.4', +3324 info outdated '0.7.4', +3324 info outdated '1.0.0', +3324 info outdated '0.7.x' ], +3324 info outdated [ '/usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/mkdirp', +3324 info outdated 'minimist', +3324 info outdated '0.0.8', +3324 info outdated '0.0.8', +3324 info outdated '1.1.0', +3324 info outdated '0.0.8' ], +3324 info outdated [ '/usr/lib/node_modules/karma-coverage/node_modules/istanbul', +3324 info outdated 'escodegen', +3324 info outdated '1.3.3', +3324 info outdated '1.3.3', +3324 info outdated '1.4.1', +3324 info outdated '1.3.x' ], +3324 info outdated [ '/usr/lib/node_modules/karma-coverage/node_modules/istanbul', +3324 info outdated 'handlebars', +3324 info outdated '1.3.0', +3324 info outdated '1.3.0', +3324 info outdated '2.0.0', +3324 info outdated '1.3.x' ], +3324 info outdated [ '/usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/fileset', +3324 info outdated 'minimatch', +3324 info outdated '0.4.0', +3324 info outdated '0.4.0', +3324 info outdated '1.0.0', +3324 info outdated '0.x' ], +3324 info outdated [ '/usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/fileset', +3324 info outdated 'glob', +3324 info outdated undefined, +3324 info outdated '3.2.11', +3324 info outdated '4.0.6', +3324 info outdated '3.x' ], +3324 info outdated [ '/usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/js-yaml', +3324 info outdated 'esprima', +3324 info outdated '1.0.4', +3324 info outdated '1.0.4', +3324 info outdated '1.2.2', +3324 info outdated '~ 1.0.2' ], +3324 info outdated [ '/usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/js-yaml/node_modules/argparse', +3324 info outdated 'underscore', +3324 info outdated '1.4.4', +3324 info outdated '1.4.4', +3324 info outdated '1.7.0', +3324 info outdated '~1.4.3' ], +3324 info outdated [ '/usr/lib/node_modules/karma-coverage/node_modules/ibrik', +3324 info outdated 'istanbul', +3324 info outdated '0.2.16', +3324 info outdated '0.2.16', +3324 info outdated '0.3.2', +3324 info outdated '~0.2.4' ], +3324 info outdated [ '/usr/lib/node_modules/karma-coverage/node_modules/ibrik', +3324 info outdated 'mkdirp', +3324 info outdated '0.3.5', +3324 info outdated '0.3.5', +3324 info outdated '0.5.0', +3324 info outdated '~0.3.5' ], +3324 info outdated [ '/usr/lib/node_modules/karma-coverage/node_modules/ibrik', +3324 info outdated 'escodegen', +3324 info outdated '1.1.0', +3324 info outdated '1.1.0', +3324 info outdated '1.4.1', +3324 info outdated '~1.1.0' ], +3324 info outdated [ '/usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/optimist', +3324 info outdated 'minimist', +3324 info outdated '0.0.10', +3324 info outdated '0.0.10', +3324 info outdated '1.1.0', +3324 info outdated '~0.0.1' ], +3324 info outdated [ '/usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/coffee-script-redux', +3324 info outdated 'cscodegen', +3324 info outdated '0.1.0', +3324 info outdated 'git', +3324 info outdated 'git', +3324 info outdated 'git://github.com/michaelficarra/cscodegen.git#73fd7202ac086c26f18c9d56f025b18b3c6f5383' ], +3324 info outdated [ '/usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/coffee-script-redux', +3324 info outdated 'nopt', +3324 info outdated '2.1.2', +3324 info outdated '2.1.2', +3324 info outdated '3.0.1', +3324 info outdated '~2.1.2' ], +3324 info outdated [ '/usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/coffee-script-redux', +3324 info outdated 'source-map', +3324 info outdated '0.1.11', +3324 info outdated '0.1.11', +3324 info outdated '0.1.39', +3324 info outdated '0.1.11' ], +3324 info outdated [ '/usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/coffee-script-redux', +3324 info outdated 'escodegen', +3324 info outdated '0.0.28', +3324 info outdated '0.0.28', +3324 info outdated '1.4.1', +3324 info outdated '~0.0.24' ], +3324 info outdated [ '/usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/coffee-script-redux', +3324 info outdated 'esmangle', +3324 info outdated '0.0.17', +3324 info outdated '0.0.17', +3324 info outdated '1.0.1', +3324 info outdated '~0.0.8' ], +3324 info outdated [ '/usr/lib/node_modules/karma-phantomjs-launcher/node_modules/phantomjs', +3324 info outdated 'request', +3324 info outdated '2.42.0', +3324 info outdated '2.42.0', +3324 info outdated '2.44.0', +3324 info outdated '2.42.0' ], +3324 info outdated [ '/usr/lib/node_modules/karma-phantomjs-launcher/node_modules/phantomjs/node_modules/mkdirp', +3324 info outdated 'minimist', +3324 info outdated '0.0.8', +3324 info outdated '0.0.8', +3324 info outdated '1.1.0', +3324 info outdated '0.0.8' ], +3324 info outdated [ '/usr/lib/node_modules/karma-phantomjs-launcher/node_modules/phantomjs/node_modules/npmconf', +3324 info outdated 'semver', +3324 info outdated '4.0.0', +3324 info outdated '4.0.0', +3324 info outdated '3.0.1', +3324 info outdated '2 || 3 || 4' ], +3324 info outdated [ '/usr/lib/node_modules/nodeunit/node_modules/tap', +3324 info outdated 'nopt', +3324 info outdated '2.2.1', +3324 info outdated '2.2.1', +3324 info outdated '3.0.1', +3324 info outdated '~2' ], +3324 info outdated [ '/usr/lib/node_modules/nodeunit/node_modules/tap', +3324 info outdated 'deep-equal', +3324 info outdated '0.0.0', +3324 info outdated '0.0.0', +3324 info outdated '0.2.1', +3324 info outdated '~0.0.0' ], +3324 info outdated [ '/usr/lib/node_modules/nodeunit/node_modules/tap', +3324 info outdated 'glob', +3324 info outdated undefined, +3324 info outdated '3.2.11', +3324 info outdated '4.0.6', +3324 info outdated '~3.2.1' ], +3324 info outdated [ '/usr/lib/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp', +3324 info outdated 'minimist', +3324 info outdated '0.0.8', +3324 info outdated '0.0.8', +3324 info outdated '1.1.0', +3324 info outdated '0.0.8' ], +3324 info outdated [ '/usr/lib/node_modules/nodeunit/node_modules/tap/node_modules/difflet', +3324 info outdated 'charm', +3324 info outdated '0.1.2', +3324 info outdated '0.1.2', +3324 info outdated '0.2.0', +3324 info outdated '0.1.x' ], +3324 info outdated [ '/usr/lib/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito', +3324 info outdated 'traverse', +3324 info outdated '0.5.2', +3324 info outdated '0.5.2', +3324 info outdated '0.6.6', +3324 info outdated '~0.5.1' ], +3324 info outdated [ '/usr/lib/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito', +3324 info outdated 'uglify-js', +3324 info outdated '1.1.1', +3324 info outdated '1.1.1', +3324 info outdated '2.4.15', +3324 info outdated '~1.1.1' ], +3324 info outdated [ '/usr/lib/node_modules/myth', +3324 info outdated 'rework-custom-media', +3324 info outdated '0.1.1', +3324 info outdated '0.1.1', +3324 info outdated '0.2.0', +3324 info outdated '~0.1.1' ], +3324 info outdated [ '/usr/lib/node_modules/myth/node_modules/to-slug-case', +3324 info outdated 'to-space-case', +3324 info outdated '0.1.2', +3324 info outdated '0.1.2', +3324 info outdated '0.1.3', +3324 info outdated '0.1.2' ], +3324 info outdated [ '/usr/lib/node_modules/myth/node_modules/read-file-stdin', +3324 info outdated 'stream-to-array', +3324 info outdated '1.0.0', +3324 info outdated '1.0.0', +3324 info outdated '2.0.2', +3324 info outdated '^1.0.0' ], +3324 info outdated [ '/usr/lib/node_modules/myth/node_modules/rework-hex-alpha', +3324 info outdated 'rgb', +3324 info outdated '0.0.1', +3324 info outdated '0.0.1', +3324 info outdated '0.1.0', +3324 info outdated '0.0.1' ], +3324 info outdated [ '/usr/lib/node_modules/myth/node_modules/rework', +3324 info outdated 'convert-source-map', +3324 info outdated '0.3.5', +3324 info outdated '0.3.5', +3324 info outdated '0.4.1', +3324 info outdated '^0.3.3' ], +3324 info outdated [ '/usr/lib/node_modules/myth/node_modules/rework-import', +3324 info outdated 'parse-import', +3324 info outdated '0.1.3', +3324 info outdated '0.1.3', +3324 info outdated '1.0.0', +3324 info outdated '~0.1.3' ], +3324 info outdated [ '/usr/lib/node_modules/myth/node_modules/rework-import', +3324 info outdated 'find-file', +3324 info outdated '0.1.4', +3324 info outdated '0.1.4', +3324 info outdated '1.0.1', +3324 info outdated '~0.1.0' ], +3324 info outdated [ '/usr/lib/node_modules/myth/node_modules/rework-color-function', +3324 info outdated 'balanced-match', +3324 info outdated '0.0.0', +3324 info outdated '0.0.0', +3324 info outdated '0.1.0', +3324 info outdated '0.0.0' ], +3324 info outdated [ '/usr/lib/node_modules/myth/node_modules/rework-color-function/node_modules/css-color-function', +3324 info outdated 'debug', +3324 info outdated '0.7.4', +3324 info outdated '0.7.4', +3324 info outdated '2.0.0', +3324 info outdated '~0.7.4' ] ] +3325 verbose install where,what [ '/usr/lib', [ 'npm@1.4.27' ] ] +3326 verbose install where,what [ '/usr/lib/node_modules/karma-coffee-preprocessor', +3326 verbose install [ 'coffee-script@1.7.1' ] ] +3327 verbose install where,what [ '/usr/lib/node_modules/express-generator', +3327 verbose install [ 'commander@1.3.2' ] ] +3328 verbose install where,what [ '/usr/lib/node_modules/express-generator/node_modules/mkdirp', +3328 verbose install [ 'minimist@0.0.8' ] ] +3329 verbose install where,what [ '/usr/lib/node_modules/grunt-cli', [ 'nopt@1.0.10' ] ] +3330 verbose install where,what [ '/usr/lib/node_modules/grunt-cli', [ 'resolve@0.3.1' ] ] +3331 verbose install where,what [ '/usr/lib/node_modules/grunt-cli/node_modules/findup-sync', +3331 verbose install [ 'glob@3.2.11' ] ] +3332 verbose install where,what [ '/usr/lib/node_modules/zombie', [ 'html5@0.3.14' ] ] +3333 verbose install where,what [ '/usr/lib/node_modules/zombie', [ 'eventsource@0.0.10' ] ] +3334 verbose install where,what [ '/usr/lib/node_modules/zombie', [ 'q@1.0.0' ] ] +3335 verbose install where,what [ '/usr/lib/node_modules/zombie', [ 'request@2.34.0' ] ] +3336 verbose install where,what [ '/usr/lib/node_modules/zombie', [ 'ws@0.4.31' ] ] +3337 verbose install where,what [ '/usr/lib/node_modules/zombie', [ 'encoding@0.1.7' ] ] +3338 verbose install where,what [ '/usr/lib/node_modules/zombie', [ 'jsdom@0.8.11' ] ] +3339 verbose install where,what [ '/usr/lib/node_modules/grunt', [ 'dateformat@1.0.2-1.2.3' ] ] +3340 verbose install where,what [ '/usr/lib/node_modules/grunt', [ 'glob@3.1.21' ] ] +3341 verbose install where,what [ '/usr/lib/node_modules/grunt', [ 'lodash@0.9.2' ] ] +3342 verbose install where,what [ '/usr/lib/node_modules/grunt', [ 'nopt@1.0.10' ] ] +3343 verbose install where,what [ '/usr/lib/node_modules/grunt', [ 'underscore.string@2.2.1' ] ] +3344 verbose install where,what [ '/usr/lib/node_modules/grunt', [ 'iconv-lite@0.2.11' ] ] +3345 verbose install where,what [ '/usr/lib/node_modules/grunt', [ 'coffee-script@1.3.3' ] ] +3346 verbose install where,what [ '/usr/lib/node_modules/grunt', [ 'minimatch@0.2.14' ] ] +3347 verbose install where,what [ '/usr/lib/node_modules/grunt', [ 'js-yaml@2.0.5' ] ] +3348 verbose install where,what [ '/usr/lib/node_modules/grunt', [ 'async@0.1.22' ] ] +3349 verbose install where,what [ '/usr/lib/node_modules/grunt/node_modules/findup-sync', +3349 verbose install [ 'glob@3.2.11' ] ] +3350 verbose install where,what [ '/usr/lib/node_modules/grunt/node_modules/grunt-legacy-util', +3350 verbose install [ 'async@0.1.22' ] ] +3351 verbose install where,what [ '/usr/lib/node_modules/grunt/node_modules/grunt-legacy-util', +3351 verbose install [ 'lodash@0.9.2' ] ] +3352 verbose install where,what [ '/usr/lib/node_modules/grunt/node_modules/grunt-legacy-util', +3352 verbose install [ 'underscore.string@2.2.1' ] ] +3353 verbose install where,what [ '/usr/lib/node_modules/express', [ 'depd@0.4.5' ] ] +3354 verbose install where,what [ '/usr/lib/node_modules/express', [ 'finalhandler@0.2.0' ] ] +3355 verbose install where,what [ '/usr/lib/node_modules/express', [ 'path-to-regexp@0.1.3' ] ] +3356 verbose install where,what [ '/usr/lib/node_modules/express/node_modules/debug', +3356 verbose install [ 'ms@0.6.2' ] ] +3357 verbose install where,what [ '/usr/lib/node_modules/express/node_modules/on-finished', +3357 verbose install [ 'ee-first@1.0.5' ] ] +3358 verbose install where,what [ '/usr/lib/node_modules/express/node_modules/accepts', +3358 verbose install [ 'mime-types@2.0.1' ] ] +3359 verbose install where,what [ '/usr/lib/node_modules/express/node_modules/accepts', +3359 verbose install [ 'negotiator@0.4.7' ] ] +3360 verbose install where,what [ '/usr/lib/node_modules/express/node_modules/proxy-addr', +3360 verbose install [ 'ipaddr.js@0.1.3' ] ] +3361 verbose install where,what [ '/usr/lib/node_modules/express/node_modules/send', +3361 verbose install [ 'depd@0.4.5' ] ] +3362 verbose install where,what [ '/usr/lib/node_modules/express/node_modules/send', +3362 verbose install [ 'mime@1.2.11' ] ] +3363 verbose install where,what [ '/usr/lib/node_modules/express/node_modules/send', +3363 verbose install [ 'ms@0.6.2' ] ] +3364 verbose install where,what [ '/usr/lib/node_modules/express/node_modules/send', +3364 verbose install [ 'destroy@1.0.3' ] ] +3365 verbose install where,what [ '/usr/lib/node_modules/express/node_modules/type-is', +3365 verbose install [ 'mime-types@2.0.1' ] ] +3366 verbose install where,what [ '/usr/lib/node_modules/express/node_modules/etag', +3366 verbose install [ 'crc@3.0.0' ] ] +3367 verbose install where,what [ '/usr/lib/node_modules/jsdoc', [ 'async@0.1.22' ] ] +3368 verbose install where,what [ '/usr/lib/node_modules/jsdoc', +3368 verbose install [ 'strip-json-comments@0.1.3' ] ] +3369 verbose install where,what [ '/usr/lib/node_modules/jsdoc', [ 'underscore@1.6.0' ] ] +3370 verbose install where,what [ '/usr/lib/node_modules/jsdoc', [ 'wrench@1.3.9' ] ] +3371 verbose install where,what [ '/usr/lib/node_modules/jsdoc/node_modules/requizzle', +3371 verbose install [ 'underscore@1.6.0' ] ] +3372 verbose install where,what [ '/usr/lib/node_modules/jsdoc/node_modules/catharsis/node_modules/underscore-contrib', +3372 verbose install [ 'underscore@1.6.0' ] ] +3373 verbose install where,what [ '/usr/lib/node_modules/jsdoc', +3373 verbose install [ 'https://github.com/hegemonic/taffydb/tarball/master' ] ] +3374 verbose install where,what [ '/usr/lib/node_modules/jsdoc', +3374 verbose install [ 'https://github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c' ] ] +3375 verbose install where,what [ '/usr/lib/node_modules/vtop', [ 'commander@2.2.0' ] ] +3376 verbose install where,what [ '/usr/lib/node_modules/vtop', [ 'glob@4.0.4' ] ] +3377 verbose install where,what [ '/usr/lib/node_modules/vtop', [ 'drawille@0.1.1' ] ] +3378 verbose install where,what [ '/usr/lib/node_modules/karma', [ 'q@0.9.7' ] ] +3379 verbose install where,what [ '/usr/lib/node_modules/karma', [ 'socket.io@0.9.17' ] ] +3380 verbose install where,what [ '/usr/lib/node_modules/karma', [ 'glob@3.2.11' ] ] +3381 verbose install where,what [ '/usr/lib/node_modules/karma', [ 'http-proxy@0.10.4' ] ] +3382 verbose install where,what [ '/usr/lib/node_modules/karma', [ 'graceful-fs@2.0.3' ] ] +3383 verbose install where,what [ '/usr/lib/node_modules/karma', [ 'connect@2.12.0' ] ] +3384 verbose install where,what [ '/usr/lib/node_modules/karma', [ 'minimatch@0.2.14' ] ] +3385 verbose install where,what [ '/usr/lib/node_modules/karma/node_modules/optimist', +3385 verbose install [ 'minimist@0.0.10' ] ] +3386 verbose install where,what [ '/usr/lib/node_modules/karma/node_modules/useragent', +3386 verbose install [ 'lru-cache@2.2.4' ] ] +3387 verbose install where,what [ '/usr/lib/node_modules/karma/node_modules/chokidar', +3387 verbose install [ 'git+https://github.com/pipobscure/fsevents#7dcdf9fa3f8956610fd6f69f72c67bace2de7138' ] ] +3388 verbose install where,what [ '/usr/lib/node_modules/karma/node_modules/chokidar', +3388 verbose install [ 'recursive-readdir@0.0.2' ] ] +3389 verbose install where,what [ '/usr/lib/node_modules/karma/node_modules/log4js', +3389 verbose install [ 'async@0.2.10' ] ] +3390 verbose install where,what [ '/usr/lib/node_modules/karma/node_modules/log4js', +3390 verbose install [ 'semver@1.1.4' ] ] +3391 verbose install where,what [ '/usr/lib/node_modules/karma-coverage', +3391 verbose install [ 'minimatch@0.3.0' ] ] +3392 verbose install where,what [ '/usr/lib/node_modules/karma-coverage/node_modules/istanbul', +3392 verbose install [ 'resolve@0.7.4' ] ] +3393 verbose install where,what [ '/usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/mkdirp', +3393 verbose install [ 'minimist@0.0.8' ] ] +3394 verbose install where,what [ '/usr/lib/node_modules/karma-coverage/node_modules/istanbul', +3394 verbose install [ 'escodegen@1.3.3' ] ] +3395 verbose install where,what [ '/usr/lib/node_modules/karma-coverage/node_modules/istanbul', +3395 verbose install [ 'handlebars@1.3.0' ] ] +3396 verbose install where,what [ '/usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/fileset', +3396 verbose install [ 'minimatch@0.4.0' ] ] +3397 verbose install where,what [ '/usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/fileset', +3397 verbose install [ 'glob@3.2.11' ] ] +3398 verbose install where,what [ '/usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/js-yaml', +3398 verbose install [ 'esprima@1.0.4' ] ] +3399 verbose install where,what [ '/usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/js-yaml/node_modules/argparse', +3399 verbose install [ 'underscore@1.4.4' ] ] +3400 verbose install where,what [ '/usr/lib/node_modules/karma-coverage/node_modules/ibrik', +3400 verbose install [ 'istanbul@0.2.16' ] ] +3401 verbose install where,what [ '/usr/lib/node_modules/karma-coverage/node_modules/ibrik', +3401 verbose install [ 'mkdirp@0.3.5' ] ] +3402 verbose install where,what [ '/usr/lib/node_modules/karma-coverage/node_modules/ibrik', +3402 verbose install [ 'escodegen@1.1.0' ] ] +3403 verbose install where,what [ '/usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/optimist', +3403 verbose install [ 'minimist@0.0.10' ] ] +3404 verbose install where,what [ '/usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/coffee-script-redux', +3404 verbose install [ 'git://github.com/michaelficarra/cscodegen.git#73fd7202ac086c26f18c9d56f025b18b3c6f5383' ] ] +3405 verbose install where,what [ '/usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/coffee-script-redux', +3405 verbose install [ 'nopt@2.1.2' ] ] +3406 verbose install where,what [ '/usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/coffee-script-redux', +3406 verbose install [ 'source-map@0.1.11' ] ] +3407 verbose install where,what [ '/usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/coffee-script-redux', +3407 verbose install [ 'escodegen@0.0.28' ] ] +3408 verbose install where,what [ '/usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/coffee-script-redux', +3408 verbose install [ 'esmangle@0.0.17' ] ] +3409 verbose install where,what [ '/usr/lib/node_modules/karma-phantomjs-launcher/node_modules/phantomjs', +3409 verbose install [ 'request@2.42.0' ] ] +3410 verbose install where,what [ '/usr/lib/node_modules/karma-phantomjs-launcher/node_modules/phantomjs/node_modules/mkdirp', +3410 verbose install [ 'minimist@0.0.8' ] ] +3411 verbose install where,what [ '/usr/lib/node_modules/karma-phantomjs-launcher/node_modules/phantomjs/node_modules/npmconf', +3411 verbose install [ 'semver@4.0.0' ] ] +3412 verbose install where,what [ '/usr/lib/node_modules/nodeunit/node_modules/tap', +3412 verbose install [ 'nopt@2.2.1' ] ] +3413 verbose install where,what [ '/usr/lib/node_modules/nodeunit/node_modules/tap', +3413 verbose install [ 'deep-equal@0.0.0' ] ] +3414 verbose install where,what [ '/usr/lib/node_modules/nodeunit/node_modules/tap', +3414 verbose install [ 'glob@3.2.11' ] ] +3415 verbose install where,what [ '/usr/lib/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp', +3415 verbose install [ 'minimist@0.0.8' ] ] +3416 verbose install where,what [ '/usr/lib/node_modules/nodeunit/node_modules/tap/node_modules/difflet', +3416 verbose install [ 'charm@0.1.2' ] ] +3417 verbose install where,what [ '/usr/lib/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito', +3417 verbose install [ 'traverse@0.5.2' ] ] +3418 verbose install where,what [ '/usr/lib/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito', +3418 verbose install [ 'uglify-js@1.1.1' ] ] +3419 verbose install where,what [ '/usr/lib/node_modules/myth', +3419 verbose install [ 'rework-custom-media@0.1.1' ] ] +3420 verbose install where,what [ '/usr/lib/node_modules/myth/node_modules/to-slug-case', +3420 verbose install [ 'to-space-case@0.1.2' ] ] +3421 verbose install where,what [ '/usr/lib/node_modules/myth/node_modules/read-file-stdin', +3421 verbose install [ 'stream-to-array@1.0.0' ] ] +3422 verbose install where,what [ '/usr/lib/node_modules/myth/node_modules/rework-hex-alpha', +3422 verbose install [ 'rgb@0.0.1' ] ] +3423 verbose install where,what [ '/usr/lib/node_modules/myth/node_modules/rework', +3423 verbose install [ 'convert-source-map@0.3.5' ] ] +3424 verbose install where,what [ '/usr/lib/node_modules/myth/node_modules/rework-import', +3424 verbose install [ 'parse-import@0.1.3' ] ] +3425 verbose install where,what [ '/usr/lib/node_modules/myth/node_modules/rework-import', +3425 verbose install [ 'find-file@0.1.4' ] ] +3426 verbose install where,what [ '/usr/lib/node_modules/myth/node_modules/rework-color-function', +3426 verbose install [ 'balanced-match@0.0.0' ] ] +3427 verbose install where,what [ '/usr/lib/node_modules/myth/node_modules/rework-color-function/node_modules/css-color-function', +3427 verbose install [ 'debug@0.7.4' ] ] +3428 verbose readDependencies using package.json deps +3429 verbose cache add [ 'coffee-script@1.7.1', null ] +3430 verbose cache add name=undefined spec="coffee-script@1.7.1" args=["coffee-script@1.7.1",null] +3431 verbose parsed url { protocol: null, +3431 verbose parsed url slashes: null, +3431 verbose parsed url auth: null, +3431 verbose parsed url host: null, +3431 verbose parsed url port: null, +3431 verbose parsed url hostname: null, +3431 verbose parsed url hash: null, +3431 verbose parsed url search: null, +3431 verbose parsed url query: null, +3431 verbose parsed url pathname: 'coffee-script@1.7.1', +3431 verbose parsed url path: 'coffee-script@1.7.1', +3431 verbose parsed url href: 'coffee-script@1.7.1' } +3432 verbose readDependencies using package.json deps +3433 verbose cache add [ 'commander@1.3.2', null ] +3434 verbose cache add name=undefined spec="commander@1.3.2" args=["commander@1.3.2",null] +3435 verbose parsed url { protocol: null, +3435 verbose parsed url slashes: null, +3435 verbose parsed url auth: null, +3435 verbose parsed url host: null, +3435 verbose parsed url port: null, +3435 verbose parsed url hostname: null, +3435 verbose parsed url hash: null, +3435 verbose parsed url search: null, +3435 verbose parsed url query: null, +3435 verbose parsed url pathname: 'commander@1.3.2', +3435 verbose parsed url path: 'commander@1.3.2', +3435 verbose parsed url href: 'commander@1.3.2' } +3436 verbose readDependencies using package.json deps +3437 verbose cache add [ 'minimist@0.0.8', null ] +3438 verbose cache add name=undefined spec="minimist@0.0.8" args=["minimist@0.0.8",null] +3439 verbose parsed url { protocol: null, +3439 verbose parsed url slashes: null, +3439 verbose parsed url auth: null, +3439 verbose parsed url host: null, +3439 verbose parsed url port: null, +3439 verbose parsed url hostname: null, +3439 verbose parsed url hash: null, +3439 verbose parsed url search: null, +3439 verbose parsed url query: null, +3439 verbose parsed url pathname: 'minimist@0.0.8', +3439 verbose parsed url path: 'minimist@0.0.8', +3439 verbose parsed url href: 'minimist@0.0.8' } +3440 verbose readDependencies using package.json deps +3441 verbose cache add [ 'nopt@1.0.10', null ] +3442 verbose cache add name=undefined spec="nopt@1.0.10" args=["nopt@1.0.10",null] +3443 verbose parsed url { protocol: null, +3443 verbose parsed url slashes: null, +3443 verbose parsed url auth: null, +3443 verbose parsed url host: null, +3443 verbose parsed url port: null, +3443 verbose parsed url hostname: null, +3443 verbose parsed url hash: null, +3443 verbose parsed url search: null, +3443 verbose parsed url query: null, +3443 verbose parsed url pathname: 'nopt@1.0.10', +3443 verbose parsed url path: 'nopt@1.0.10', +3443 verbose parsed url href: 'nopt@1.0.10' } +3444 verbose readDependencies using package.json deps +3445 verbose cache add [ 'resolve@0.3.1', null ] +3446 verbose cache add name=undefined spec="resolve@0.3.1" args=["resolve@0.3.1",null] +3447 verbose parsed url { protocol: null, +3447 verbose parsed url slashes: null, +3447 verbose parsed url auth: null, +3447 verbose parsed url host: null, +3447 verbose parsed url port: null, +3447 verbose parsed url hostname: null, +3447 verbose parsed url hash: null, +3447 verbose parsed url search: null, +3447 verbose parsed url query: null, +3447 verbose parsed url pathname: 'resolve@0.3.1', +3447 verbose parsed url path: 'resolve@0.3.1', +3447 verbose parsed url href: 'resolve@0.3.1' } +3448 verbose readDependencies using package.json deps +3449 verbose cache add [ 'glob@3.2.11', null ] +3450 verbose cache add name=undefined spec="glob@3.2.11" args=["glob@3.2.11",null] +3451 verbose parsed url { protocol: null, +3451 verbose parsed url slashes: null, +3451 verbose parsed url auth: null, +3451 verbose parsed url host: null, +3451 verbose parsed url port: null, +3451 verbose parsed url hostname: null, +3451 verbose parsed url hash: null, +3451 verbose parsed url search: null, +3451 verbose parsed url query: null, +3451 verbose parsed url pathname: 'glob@3.2.11', +3451 verbose parsed url path: 'glob@3.2.11', +3451 verbose parsed url href: 'glob@3.2.11' } +3452 verbose readDependencies using package.json deps +3453 verbose cache add [ 'html5@0.3.14', null ] +3454 verbose cache add name=undefined spec="html5@0.3.14" args=["html5@0.3.14",null] +3455 verbose parsed url { protocol: null, +3455 verbose parsed url slashes: null, +3455 verbose parsed url auth: null, +3455 verbose parsed url host: null, +3455 verbose parsed url port: null, +3455 verbose parsed url hostname: null, +3455 verbose parsed url hash: null, +3455 verbose parsed url search: null, +3455 verbose parsed url query: null, +3455 verbose parsed url pathname: 'html5@0.3.14', +3455 verbose parsed url path: 'html5@0.3.14', +3455 verbose parsed url href: 'html5@0.3.14' } +3456 verbose readDependencies using package.json deps +3457 verbose cache add [ 'eventsource@0.0.10', null ] +3458 verbose cache add name=undefined spec="eventsource@0.0.10" args=["eventsource@0.0.10",null] +3459 verbose parsed url { protocol: null, +3459 verbose parsed url slashes: null, +3459 verbose parsed url auth: null, +3459 verbose parsed url host: null, +3459 verbose parsed url port: null, +3459 verbose parsed url hostname: null, +3459 verbose parsed url hash: null, +3459 verbose parsed url search: null, +3459 verbose parsed url query: null, +3459 verbose parsed url pathname: 'eventsource@0.0.10', +3459 verbose parsed url path: 'eventsource@0.0.10', +3459 verbose parsed url href: 'eventsource@0.0.10' } +3460 verbose readDependencies using package.json deps +3461 verbose cache add [ 'q@1.0.0', null ] +3462 verbose cache add name=undefined spec="q@1.0.0" args=["q@1.0.0",null] +3463 verbose parsed url { protocol: null, +3463 verbose parsed url slashes: null, +3463 verbose parsed url auth: null, +3463 verbose parsed url host: null, +3463 verbose parsed url port: null, +3463 verbose parsed url hostname: null, +3463 verbose parsed url hash: null, +3463 verbose parsed url search: null, +3463 verbose parsed url query: null, +3463 verbose parsed url pathname: 'q@1.0.0', +3463 verbose parsed url path: 'q@1.0.0', +3463 verbose parsed url href: 'q@1.0.0' } +3464 verbose readDependencies using package.json deps +3465 verbose cache add [ 'request@2.34.0', null ] +3466 verbose cache add name=undefined spec="request@2.34.0" args=["request@2.34.0",null] +3467 verbose parsed url { protocol: null, +3467 verbose parsed url slashes: null, +3467 verbose parsed url auth: null, +3467 verbose parsed url host: null, +3467 verbose parsed url port: null, +3467 verbose parsed url hostname: null, +3467 verbose parsed url hash: null, +3467 verbose parsed url search: null, +3467 verbose parsed url query: null, +3467 verbose parsed url pathname: 'request@2.34.0', +3467 verbose parsed url path: 'request@2.34.0', +3467 verbose parsed url href: 'request@2.34.0' } +3468 verbose readDependencies using package.json deps +3469 verbose cache add [ 'ws@0.4.31', null ] +3470 verbose cache add name=undefined spec="ws@0.4.31" args=["ws@0.4.31",null] +3471 verbose parsed url { protocol: null, +3471 verbose parsed url slashes: null, +3471 verbose parsed url auth: null, +3471 verbose parsed url host: null, +3471 verbose parsed url port: null, +3471 verbose parsed url hostname: null, +3471 verbose parsed url hash: null, +3471 verbose parsed url search: null, +3471 verbose parsed url query: null, +3471 verbose parsed url pathname: 'ws@0.4.31', +3471 verbose parsed url path: 'ws@0.4.31', +3471 verbose parsed url href: 'ws@0.4.31' } +3472 verbose readDependencies using package.json deps +3473 verbose cache add [ 'encoding@0.1.7', null ] +3474 verbose cache add name=undefined spec="encoding@0.1.7" args=["encoding@0.1.7",null] +3475 verbose parsed url { protocol: null, +3475 verbose parsed url slashes: null, +3475 verbose parsed url auth: null, +3475 verbose parsed url host: null, +3475 verbose parsed url port: null, +3475 verbose parsed url hostname: null, +3475 verbose parsed url hash: null, +3475 verbose parsed url search: null, +3475 verbose parsed url query: null, +3475 verbose parsed url pathname: 'encoding@0.1.7', +3475 verbose parsed url path: 'encoding@0.1.7', +3475 verbose parsed url href: 'encoding@0.1.7' } +3476 verbose readDependencies using package.json deps +3477 verbose cache add [ 'jsdom@0.8.11', null ] +3478 verbose cache add name=undefined spec="jsdom@0.8.11" args=["jsdom@0.8.11",null] +3479 verbose parsed url { protocol: null, +3479 verbose parsed url slashes: null, +3479 verbose parsed url auth: null, +3479 verbose parsed url host: null, +3479 verbose parsed url port: null, +3479 verbose parsed url hostname: null, +3479 verbose parsed url hash: null, +3479 verbose parsed url search: null, +3479 verbose parsed url query: null, +3479 verbose parsed url pathname: 'jsdom@0.8.11', +3479 verbose parsed url path: 'jsdom@0.8.11', +3479 verbose parsed url href: 'jsdom@0.8.11' } +3480 verbose readDependencies using package.json deps +3481 verbose cache add [ 'dateformat@1.0.2-1.2.3', null ] +3482 verbose cache add name=undefined spec="dateformat@1.0.2-1.2.3" args=["dateformat@1.0.2-1.2.3",null] +3483 verbose parsed url { protocol: null, +3483 verbose parsed url slashes: null, +3483 verbose parsed url auth: null, +3483 verbose parsed url host: null, +3483 verbose parsed url port: null, +3483 verbose parsed url hostname: null, +3483 verbose parsed url hash: null, +3483 verbose parsed url search: null, +3483 verbose parsed url query: null, +3483 verbose parsed url pathname: 'dateformat@1.0.2-1.2.3', +3483 verbose parsed url path: 'dateformat@1.0.2-1.2.3', +3483 verbose parsed url href: 'dateformat@1.0.2-1.2.3' } +3484 verbose readDependencies using package.json deps +3485 verbose cache add [ 'glob@3.1.21', null ] +3486 verbose cache add name=undefined spec="glob@3.1.21" args=["glob@3.1.21",null] +3487 verbose parsed url { protocol: null, +3487 verbose parsed url slashes: null, +3487 verbose parsed url auth: null, +3487 verbose parsed url host: null, +3487 verbose parsed url port: null, +3487 verbose parsed url hostname: null, +3487 verbose parsed url hash: null, +3487 verbose parsed url search: null, +3487 verbose parsed url query: null, +3487 verbose parsed url pathname: 'glob@3.1.21', +3487 verbose parsed url path: 'glob@3.1.21', +3487 verbose parsed url href: 'glob@3.1.21' } +3488 verbose readDependencies using package.json deps +3489 verbose cache add [ 'lodash@0.9.2', null ] +3490 verbose cache add name=undefined spec="lodash@0.9.2" args=["lodash@0.9.2",null] +3491 verbose parsed url { protocol: null, +3491 verbose parsed url slashes: null, +3491 verbose parsed url auth: null, +3491 verbose parsed url host: null, +3491 verbose parsed url port: null, +3491 verbose parsed url hostname: null, +3491 verbose parsed url hash: null, +3491 verbose parsed url search: null, +3491 verbose parsed url query: null, +3491 verbose parsed url pathname: 'lodash@0.9.2', +3491 verbose parsed url path: 'lodash@0.9.2', +3491 verbose parsed url href: 'lodash@0.9.2' } +3492 verbose readDependencies using package.json deps +3493 verbose cache add [ 'nopt@1.0.10', null ] +3494 verbose cache add name=undefined spec="nopt@1.0.10" args=["nopt@1.0.10",null] +3495 verbose parsed url { protocol: null, +3495 verbose parsed url slashes: null, +3495 verbose parsed url auth: null, +3495 verbose parsed url host: null, +3495 verbose parsed url port: null, +3495 verbose parsed url hostname: null, +3495 verbose parsed url hash: null, +3495 verbose parsed url search: null, +3495 verbose parsed url query: null, +3495 verbose parsed url pathname: 'nopt@1.0.10', +3495 verbose parsed url path: 'nopt@1.0.10', +3495 verbose parsed url href: 'nopt@1.0.10' } +3496 verbose readDependencies using package.json deps +3497 verbose cache add [ 'underscore.string@2.2.1', null ] +3498 verbose cache add name=undefined spec="underscore.string@2.2.1" args=["underscore.string@2.2.1",null] +3499 verbose parsed url { protocol: null, +3499 verbose parsed url slashes: null, +3499 verbose parsed url auth: null, +3499 verbose parsed url host: null, +3499 verbose parsed url port: null, +3499 verbose parsed url hostname: null, +3499 verbose parsed url hash: null, +3499 verbose parsed url search: null, +3499 verbose parsed url query: null, +3499 verbose parsed url pathname: 'underscore.string@2.2.1', +3499 verbose parsed url path: 'underscore.string@2.2.1', +3499 verbose parsed url href: 'underscore.string@2.2.1' } +3500 verbose readDependencies using package.json deps +3501 verbose cache add [ 'iconv-lite@0.2.11', null ] +3502 verbose cache add name=undefined spec="iconv-lite@0.2.11" args=["iconv-lite@0.2.11",null] +3503 verbose parsed url { protocol: null, +3503 verbose parsed url slashes: null, +3503 verbose parsed url auth: null, +3503 verbose parsed url host: null, +3503 verbose parsed url port: null, +3503 verbose parsed url hostname: null, +3503 verbose parsed url hash: null, +3503 verbose parsed url search: null, +3503 verbose parsed url query: null, +3503 verbose parsed url pathname: 'iconv-lite@0.2.11', +3503 verbose parsed url path: 'iconv-lite@0.2.11', +3503 verbose parsed url href: 'iconv-lite@0.2.11' } +3504 verbose readDependencies using package.json deps +3505 verbose cache add [ 'coffee-script@1.3.3', null ] +3506 verbose cache add name=undefined spec="coffee-script@1.3.3" args=["coffee-script@1.3.3",null] +3507 verbose parsed url { protocol: null, +3507 verbose parsed url slashes: null, +3507 verbose parsed url auth: null, +3507 verbose parsed url host: null, +3507 verbose parsed url port: null, +3507 verbose parsed url hostname: null, +3507 verbose parsed url hash: null, +3507 verbose parsed url search: null, +3507 verbose parsed url query: null, +3507 verbose parsed url pathname: 'coffee-script@1.3.3', +3507 verbose parsed url path: 'coffee-script@1.3.3', +3507 verbose parsed url href: 'coffee-script@1.3.3' } +3508 verbose readDependencies using package.json deps +3509 verbose cache add [ 'minimatch@0.2.14', null ] +3510 verbose cache add name=undefined spec="minimatch@0.2.14" args=["minimatch@0.2.14",null] +3511 verbose parsed url { protocol: null, +3511 verbose parsed url slashes: null, +3511 verbose parsed url auth: null, +3511 verbose parsed url host: null, +3511 verbose parsed url port: null, +3511 verbose parsed url hostname: null, +3511 verbose parsed url hash: null, +3511 verbose parsed url search: null, +3511 verbose parsed url query: null, +3511 verbose parsed url pathname: 'minimatch@0.2.14', +3511 verbose parsed url path: 'minimatch@0.2.14', +3511 verbose parsed url href: 'minimatch@0.2.14' } +3512 verbose readDependencies using package.json deps +3513 verbose cache add [ 'js-yaml@2.0.5', null ] +3514 verbose cache add name=undefined spec="js-yaml@2.0.5" args=["js-yaml@2.0.5",null] +3515 verbose parsed url { protocol: null, +3515 verbose parsed url slashes: null, +3515 verbose parsed url auth: null, +3515 verbose parsed url host: null, +3515 verbose parsed url port: null, +3515 verbose parsed url hostname: null, +3515 verbose parsed url hash: null, +3515 verbose parsed url search: null, +3515 verbose parsed url query: null, +3515 verbose parsed url pathname: 'js-yaml@2.0.5', +3515 verbose parsed url path: 'js-yaml@2.0.5', +3515 verbose parsed url href: 'js-yaml@2.0.5' } +3516 verbose readDependencies using package.json deps +3517 verbose cache add [ 'async@0.1.22', null ] +3518 verbose cache add name=undefined spec="async@0.1.22" args=["async@0.1.22",null] +3519 verbose parsed url { protocol: null, +3519 verbose parsed url slashes: null, +3519 verbose parsed url auth: null, +3519 verbose parsed url host: null, +3519 verbose parsed url port: null, +3519 verbose parsed url hostname: null, +3519 verbose parsed url hash: null, +3519 verbose parsed url search: null, +3519 verbose parsed url query: null, +3519 verbose parsed url pathname: 'async@0.1.22', +3519 verbose parsed url path: 'async@0.1.22', +3519 verbose parsed url href: 'async@0.1.22' } +3520 verbose readDependencies using package.json deps +3521 verbose cache add [ 'glob@3.2.11', null ] +3522 verbose cache add name=undefined spec="glob@3.2.11" args=["glob@3.2.11",null] +3523 verbose parsed url { protocol: null, +3523 verbose parsed url slashes: null, +3523 verbose parsed url auth: null, +3523 verbose parsed url host: null, +3523 verbose parsed url port: null, +3523 verbose parsed url hostname: null, +3523 verbose parsed url hash: null, +3523 verbose parsed url search: null, +3523 verbose parsed url query: null, +3523 verbose parsed url pathname: 'glob@3.2.11', +3523 verbose parsed url path: 'glob@3.2.11', +3523 verbose parsed url href: 'glob@3.2.11' } +3524 verbose readDependencies using package.json deps +3525 verbose cache add [ 'async@0.1.22', null ] +3526 verbose cache add name=undefined spec="async@0.1.22" args=["async@0.1.22",null] +3527 verbose parsed url { protocol: null, +3527 verbose parsed url slashes: null, +3527 verbose parsed url auth: null, +3527 verbose parsed url host: null, +3527 verbose parsed url port: null, +3527 verbose parsed url hostname: null, +3527 verbose parsed url hash: null, +3527 verbose parsed url search: null, +3527 verbose parsed url query: null, +3527 verbose parsed url pathname: 'async@0.1.22', +3527 verbose parsed url path: 'async@0.1.22', +3527 verbose parsed url href: 'async@0.1.22' } +3528 verbose readDependencies using package.json deps +3529 verbose cache add [ 'lodash@0.9.2', null ] +3530 verbose cache add name=undefined spec="lodash@0.9.2" args=["lodash@0.9.2",null] +3531 verbose parsed url { protocol: null, +3531 verbose parsed url slashes: null, +3531 verbose parsed url auth: null, +3531 verbose parsed url host: null, +3531 verbose parsed url port: null, +3531 verbose parsed url hostname: null, +3531 verbose parsed url hash: null, +3531 verbose parsed url search: null, +3531 verbose parsed url query: null, +3531 verbose parsed url pathname: 'lodash@0.9.2', +3531 verbose parsed url path: 'lodash@0.9.2', +3531 verbose parsed url href: 'lodash@0.9.2' } +3532 verbose readDependencies using package.json deps +3533 verbose cache add [ 'underscore.string@2.2.1', null ] +3534 verbose cache add name=undefined spec="underscore.string@2.2.1" args=["underscore.string@2.2.1",null] +3535 verbose parsed url { protocol: null, +3535 verbose parsed url slashes: null, +3535 verbose parsed url auth: null, +3535 verbose parsed url host: null, +3535 verbose parsed url port: null, +3535 verbose parsed url hostname: null, +3535 verbose parsed url hash: null, +3535 verbose parsed url search: null, +3535 verbose parsed url query: null, +3535 verbose parsed url pathname: 'underscore.string@2.2.1', +3535 verbose parsed url path: 'underscore.string@2.2.1', +3535 verbose parsed url href: 'underscore.string@2.2.1' } +3536 verbose readDependencies using package.json deps +3537 verbose cache add [ 'depd@0.4.5', null ] +3538 verbose cache add name=undefined spec="depd@0.4.5" args=["depd@0.4.5",null] +3539 verbose parsed url { protocol: null, +3539 verbose parsed url slashes: null, +3539 verbose parsed url auth: null, +3539 verbose parsed url host: null, +3539 verbose parsed url port: null, +3539 verbose parsed url hostname: null, +3539 verbose parsed url hash: null, +3539 verbose parsed url search: null, +3539 verbose parsed url query: null, +3539 verbose parsed url pathname: 'depd@0.4.5', +3539 verbose parsed url path: 'depd@0.4.5', +3539 verbose parsed url href: 'depd@0.4.5' } +3540 verbose readDependencies using package.json deps +3541 verbose cache add [ 'finalhandler@0.2.0', null ] +3542 verbose cache add name=undefined spec="finalhandler@0.2.0" args=["finalhandler@0.2.0",null] +3543 verbose parsed url { protocol: null, +3543 verbose parsed url slashes: null, +3543 verbose parsed url auth: null, +3543 verbose parsed url host: null, +3543 verbose parsed url port: null, +3543 verbose parsed url hostname: null, +3543 verbose parsed url hash: null, +3543 verbose parsed url search: null, +3543 verbose parsed url query: null, +3543 verbose parsed url pathname: 'finalhandler@0.2.0', +3543 verbose parsed url path: 'finalhandler@0.2.0', +3543 verbose parsed url href: 'finalhandler@0.2.0' } +3544 verbose readDependencies using package.json deps +3545 verbose cache add [ 'path-to-regexp@0.1.3', null ] +3546 verbose cache add name=undefined spec="path-to-regexp@0.1.3" args=["path-to-regexp@0.1.3",null] +3547 verbose parsed url { protocol: null, +3547 verbose parsed url slashes: null, +3547 verbose parsed url auth: null, +3547 verbose parsed url host: null, +3547 verbose parsed url port: null, +3547 verbose parsed url hostname: null, +3547 verbose parsed url hash: null, +3547 verbose parsed url search: null, +3547 verbose parsed url query: null, +3547 verbose parsed url pathname: 'path-to-regexp@0.1.3', +3547 verbose parsed url path: 'path-to-regexp@0.1.3', +3547 verbose parsed url href: 'path-to-regexp@0.1.3' } +3548 verbose readDependencies using package.json deps +3549 verbose cache add [ 'ms@0.6.2', null ] +3550 verbose cache add name=undefined spec="ms@0.6.2" args=["ms@0.6.2",null] +3551 verbose parsed url { protocol: null, +3551 verbose parsed url slashes: null, +3551 verbose parsed url auth: null, +3551 verbose parsed url host: null, +3551 verbose parsed url port: null, +3551 verbose parsed url hostname: null, +3551 verbose parsed url hash: null, +3551 verbose parsed url search: null, +3551 verbose parsed url query: null, +3551 verbose parsed url pathname: 'ms@0.6.2', +3551 verbose parsed url path: 'ms@0.6.2', +3551 verbose parsed url href: 'ms@0.6.2' } +3552 verbose readDependencies using package.json deps +3553 verbose cache add [ 'ee-first@1.0.5', null ] +3554 verbose cache add name=undefined spec="ee-first@1.0.5" args=["ee-first@1.0.5",null] +3555 verbose parsed url { protocol: null, +3555 verbose parsed url slashes: null, +3555 verbose parsed url auth: null, +3555 verbose parsed url host: null, +3555 verbose parsed url port: null, +3555 verbose parsed url hostname: null, +3555 verbose parsed url hash: null, +3555 verbose parsed url search: null, +3555 verbose parsed url query: null, +3555 verbose parsed url pathname: 'ee-first@1.0.5', +3555 verbose parsed url path: 'ee-first@1.0.5', +3555 verbose parsed url href: 'ee-first@1.0.5' } +3556 verbose readDependencies using package.json deps +3557 verbose cache add [ 'mime-types@2.0.1', null ] +3558 verbose cache add name=undefined spec="mime-types@2.0.1" args=["mime-types@2.0.1",null] +3559 verbose parsed url { protocol: null, +3559 verbose parsed url slashes: null, +3559 verbose parsed url auth: null, +3559 verbose parsed url host: null, +3559 verbose parsed url port: null, +3559 verbose parsed url hostname: null, +3559 verbose parsed url hash: null, +3559 verbose parsed url search: null, +3559 verbose parsed url query: null, +3559 verbose parsed url pathname: 'mime-types@2.0.1', +3559 verbose parsed url path: 'mime-types@2.0.1', +3559 verbose parsed url href: 'mime-types@2.0.1' } +3560 verbose readDependencies using package.json deps +3561 verbose cache add [ 'negotiator@0.4.7', null ] +3562 verbose cache add name=undefined spec="negotiator@0.4.7" args=["negotiator@0.4.7",null] +3563 verbose parsed url { protocol: null, +3563 verbose parsed url slashes: null, +3563 verbose parsed url auth: null, +3563 verbose parsed url host: null, +3563 verbose parsed url port: null, +3563 verbose parsed url hostname: null, +3563 verbose parsed url hash: null, +3563 verbose parsed url search: null, +3563 verbose parsed url query: null, +3563 verbose parsed url pathname: 'negotiator@0.4.7', +3563 verbose parsed url path: 'negotiator@0.4.7', +3563 verbose parsed url href: 'negotiator@0.4.7' } +3564 verbose readDependencies using package.json deps +3565 verbose cache add [ 'ipaddr.js@0.1.3', null ] +3566 verbose cache add name=undefined spec="ipaddr.js@0.1.3" args=["ipaddr.js@0.1.3",null] +3567 verbose parsed url { protocol: null, +3567 verbose parsed url slashes: null, +3567 verbose parsed url auth: null, +3567 verbose parsed url host: null, +3567 verbose parsed url port: null, +3567 verbose parsed url hostname: null, +3567 verbose parsed url hash: null, +3567 verbose parsed url search: null, +3567 verbose parsed url query: null, +3567 verbose parsed url pathname: 'ipaddr.js@0.1.3', +3567 verbose parsed url path: 'ipaddr.js@0.1.3', +3567 verbose parsed url href: 'ipaddr.js@0.1.3' } +3568 verbose readDependencies using package.json deps +3569 verbose cache add [ 'depd@0.4.5', null ] +3570 verbose cache add name=undefined spec="depd@0.4.5" args=["depd@0.4.5",null] +3571 verbose parsed url { protocol: null, +3571 verbose parsed url slashes: null, +3571 verbose parsed url auth: null, +3571 verbose parsed url host: null, +3571 verbose parsed url port: null, +3571 verbose parsed url hostname: null, +3571 verbose parsed url hash: null, +3571 verbose parsed url search: null, +3571 verbose parsed url query: null, +3571 verbose parsed url pathname: 'depd@0.4.5', +3571 verbose parsed url path: 'depd@0.4.5', +3571 verbose parsed url href: 'depd@0.4.5' } +3572 verbose readDependencies using package.json deps +3573 verbose cache add [ 'mime@1.2.11', null ] +3574 verbose cache add name=undefined spec="mime@1.2.11" args=["mime@1.2.11",null] +3575 verbose parsed url { protocol: null, +3575 verbose parsed url slashes: null, +3575 verbose parsed url auth: null, +3575 verbose parsed url host: null, +3575 verbose parsed url port: null, +3575 verbose parsed url hostname: null, +3575 verbose parsed url hash: null, +3575 verbose parsed url search: null, +3575 verbose parsed url query: null, +3575 verbose parsed url pathname: 'mime@1.2.11', +3575 verbose parsed url path: 'mime@1.2.11', +3575 verbose parsed url href: 'mime@1.2.11' } +3576 verbose readDependencies using package.json deps +3577 verbose cache add [ 'ms@0.6.2', null ] +3578 verbose cache add name=undefined spec="ms@0.6.2" args=["ms@0.6.2",null] +3579 verbose parsed url { protocol: null, +3579 verbose parsed url slashes: null, +3579 verbose parsed url auth: null, +3579 verbose parsed url host: null, +3579 verbose parsed url port: null, +3579 verbose parsed url hostname: null, +3579 verbose parsed url hash: null, +3579 verbose parsed url search: null, +3579 verbose parsed url query: null, +3579 verbose parsed url pathname: 'ms@0.6.2', +3579 verbose parsed url path: 'ms@0.6.2', +3579 verbose parsed url href: 'ms@0.6.2' } +3580 verbose readDependencies using package.json deps +3581 verbose cache add [ 'destroy@1.0.3', null ] +3582 verbose cache add name=undefined spec="destroy@1.0.3" args=["destroy@1.0.3",null] +3583 verbose parsed url { protocol: null, +3583 verbose parsed url slashes: null, +3583 verbose parsed url auth: null, +3583 verbose parsed url host: null, +3583 verbose parsed url port: null, +3583 verbose parsed url hostname: null, +3583 verbose parsed url hash: null, +3583 verbose parsed url search: null, +3583 verbose parsed url query: null, +3583 verbose parsed url pathname: 'destroy@1.0.3', +3583 verbose parsed url path: 'destroy@1.0.3', +3583 verbose parsed url href: 'destroy@1.0.3' } +3584 verbose readDependencies using package.json deps +3585 verbose cache add [ 'mime-types@2.0.1', null ] +3586 verbose cache add name=undefined spec="mime-types@2.0.1" args=["mime-types@2.0.1",null] +3587 verbose parsed url { protocol: null, +3587 verbose parsed url slashes: null, +3587 verbose parsed url auth: null, +3587 verbose parsed url host: null, +3587 verbose parsed url port: null, +3587 verbose parsed url hostname: null, +3587 verbose parsed url hash: null, +3587 verbose parsed url search: null, +3587 verbose parsed url query: null, +3587 verbose parsed url pathname: 'mime-types@2.0.1', +3587 verbose parsed url path: 'mime-types@2.0.1', +3587 verbose parsed url href: 'mime-types@2.0.1' } +3588 verbose readDependencies using package.json deps +3589 verbose cache add [ 'crc@3.0.0', null ] +3590 verbose cache add name=undefined spec="crc@3.0.0" args=["crc@3.0.0",null] +3591 verbose parsed url { protocol: null, +3591 verbose parsed url slashes: null, +3591 verbose parsed url auth: null, +3591 verbose parsed url host: null, +3591 verbose parsed url port: null, +3591 verbose parsed url hostname: null, +3591 verbose parsed url hash: null, +3591 verbose parsed url search: null, +3591 verbose parsed url query: null, +3591 verbose parsed url pathname: 'crc@3.0.0', +3591 verbose parsed url path: 'crc@3.0.0', +3591 verbose parsed url href: 'crc@3.0.0' } +3592 verbose readDependencies using package.json deps +3593 verbose cache add [ 'async@0.1.22', null ] +3594 verbose cache add name=undefined spec="async@0.1.22" args=["async@0.1.22",null] +3595 verbose parsed url { protocol: null, +3595 verbose parsed url slashes: null, +3595 verbose parsed url auth: null, +3595 verbose parsed url host: null, +3595 verbose parsed url port: null, +3595 verbose parsed url hostname: null, +3595 verbose parsed url hash: null, +3595 verbose parsed url search: null, +3595 verbose parsed url query: null, +3595 verbose parsed url pathname: 'async@0.1.22', +3595 verbose parsed url path: 'async@0.1.22', +3595 verbose parsed url href: 'async@0.1.22' } +3596 verbose readDependencies using package.json deps +3597 verbose cache add [ 'strip-json-comments@0.1.3', null ] +3598 verbose cache add name=undefined spec="strip-json-comments@0.1.3" args=["strip-json-comments@0.1.3",null] +3599 verbose parsed url { protocol: null, +3599 verbose parsed url slashes: null, +3599 verbose parsed url auth: null, +3599 verbose parsed url host: null, +3599 verbose parsed url port: null, +3599 verbose parsed url hostname: null, +3599 verbose parsed url hash: null, +3599 verbose parsed url search: null, +3599 verbose parsed url query: null, +3599 verbose parsed url pathname: 'strip-json-comments@0.1.3', +3599 verbose parsed url path: 'strip-json-comments@0.1.3', +3599 verbose parsed url href: 'strip-json-comments@0.1.3' } +3600 verbose readDependencies using package.json deps +3601 verbose cache add [ 'underscore@1.6.0', null ] +3602 verbose cache add name=undefined spec="underscore@1.6.0" args=["underscore@1.6.0",null] +3603 verbose parsed url { protocol: null, +3603 verbose parsed url slashes: null, +3603 verbose parsed url auth: null, +3603 verbose parsed url host: null, +3603 verbose parsed url port: null, +3603 verbose parsed url hostname: null, +3603 verbose parsed url hash: null, +3603 verbose parsed url search: null, +3603 verbose parsed url query: null, +3603 verbose parsed url pathname: 'underscore@1.6.0', +3603 verbose parsed url path: 'underscore@1.6.0', +3603 verbose parsed url href: 'underscore@1.6.0' } +3604 verbose readDependencies using package.json deps +3605 verbose cache add [ 'wrench@1.3.9', null ] +3606 verbose cache add name=undefined spec="wrench@1.3.9" args=["wrench@1.3.9",null] +3607 verbose parsed url { protocol: null, +3607 verbose parsed url slashes: null, +3607 verbose parsed url auth: null, +3607 verbose parsed url host: null, +3607 verbose parsed url port: null, +3607 verbose parsed url hostname: null, +3607 verbose parsed url hash: null, +3607 verbose parsed url search: null, +3607 verbose parsed url query: null, +3607 verbose parsed url pathname: 'wrench@1.3.9', +3607 verbose parsed url path: 'wrench@1.3.9', +3607 verbose parsed url href: 'wrench@1.3.9' } +3608 verbose readDependencies using package.json deps +3609 verbose cache add [ 'underscore@1.6.0', null ] +3610 verbose cache add name=undefined spec="underscore@1.6.0" args=["underscore@1.6.0",null] +3611 verbose parsed url { protocol: null, +3611 verbose parsed url slashes: null, +3611 verbose parsed url auth: null, +3611 verbose parsed url host: null, +3611 verbose parsed url port: null, +3611 verbose parsed url hostname: null, +3611 verbose parsed url hash: null, +3611 verbose parsed url search: null, +3611 verbose parsed url query: null, +3611 verbose parsed url pathname: 'underscore@1.6.0', +3611 verbose parsed url path: 'underscore@1.6.0', +3611 verbose parsed url href: 'underscore@1.6.0' } +3612 verbose readDependencies using package.json deps +3613 verbose cache add [ 'underscore@1.6.0', null ] +3614 verbose cache add name=undefined spec="underscore@1.6.0" args=["underscore@1.6.0",null] +3615 verbose parsed url { protocol: null, +3615 verbose parsed url slashes: null, +3615 verbose parsed url auth: null, +3615 verbose parsed url host: null, +3615 verbose parsed url port: null, +3615 verbose parsed url hostname: null, +3615 verbose parsed url hash: null, +3615 verbose parsed url search: null, +3615 verbose parsed url query: null, +3615 verbose parsed url pathname: 'underscore@1.6.0', +3615 verbose parsed url path: 'underscore@1.6.0', +3615 verbose parsed url href: 'underscore@1.6.0' } +3616 verbose readDependencies using package.json deps +3617 verbose cache add [ 'https://github.com/hegemonic/taffydb/tarball/master', null ] +3618 verbose cache add name=undefined spec="https://github.com/hegemonic/taffydb/tarball/master" args=["https://github.com/hegemonic/taffydb/tarball/master",null] +3619 verbose parsed url { protocol: 'https:', +3619 verbose parsed url slashes: true, +3619 verbose parsed url auth: null, +3619 verbose parsed url host: 'github.com', +3619 verbose parsed url port: null, +3619 verbose parsed url hostname: 'github.com', +3619 verbose parsed url hash: null, +3619 verbose parsed url search: null, +3619 verbose parsed url query: null, +3619 verbose parsed url pathname: '/hegemonic/taffydb/tarball/master', +3619 verbose parsed url path: '/hegemonic/taffydb/tarball/master', +3619 verbose parsed url href: 'https://github.com/hegemonic/taffydb/tarball/master' } +3620 silly lockFile b85c942d-hegemonic-taffydb-tarball-master https://github.com/hegemonic/taffydb/tarball/master +3621 verbose lock https://github.com/hegemonic/taffydb/tarball/master /root/.npm/b85c942d-hegemonic-taffydb-tarball-master.lock +3622 verbose readDependencies using package.json deps +3623 verbose cache add [ 'https://github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c', +3623 verbose cache add null ] +3624 verbose cache add name=undefined spec="https://github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c" args=["https://github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c",null] +3625 verbose parsed url { protocol: 'https:', +3625 verbose parsed url slashes: true, +3625 verbose parsed url auth: null, +3625 verbose parsed url host: 'github.com', +3625 verbose parsed url port: null, +3625 verbose parsed url hostname: 'github.com', +3625 verbose parsed url hash: null, +3625 verbose parsed url search: null, +3625 verbose parsed url query: null, +3625 verbose parsed url pathname: '/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c', +3625 verbose parsed url path: '/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c', +3625 verbose parsed url href: 'https://github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c' } +3626 silly lockFile db72957f-243f29bd653b11e9419241a9d726af7c https://github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c +3627 verbose lock https://github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c /root/.npm/db72957f-243f29bd653b11e9419241a9d726af7c.lock +3628 verbose readDependencies using package.json deps +3629 verbose cache add [ 'commander@2.2.0', null ] +3630 verbose cache add name=undefined spec="commander@2.2.0" args=["commander@2.2.0",null] +3631 verbose parsed url { protocol: null, +3631 verbose parsed url slashes: null, +3631 verbose parsed url auth: null, +3631 verbose parsed url host: null, +3631 verbose parsed url port: null, +3631 verbose parsed url hostname: null, +3631 verbose parsed url hash: null, +3631 verbose parsed url search: null, +3631 verbose parsed url query: null, +3631 verbose parsed url pathname: 'commander@2.2.0', +3631 verbose parsed url path: 'commander@2.2.0', +3631 verbose parsed url href: 'commander@2.2.0' } +3632 verbose readDependencies using package.json deps +3633 verbose cache add [ 'glob@4.0.4', null ] +3634 verbose cache add name=undefined spec="glob@4.0.4" args=["glob@4.0.4",null] +3635 verbose parsed url { protocol: null, +3635 verbose parsed url slashes: null, +3635 verbose parsed url auth: null, +3635 verbose parsed url host: null, +3635 verbose parsed url port: null, +3635 verbose parsed url hostname: null, +3635 verbose parsed url hash: null, +3635 verbose parsed url search: null, +3635 verbose parsed url query: null, +3635 verbose parsed url pathname: 'glob@4.0.4', +3635 verbose parsed url path: 'glob@4.0.4', +3635 verbose parsed url href: 'glob@4.0.4' } +3636 verbose readDependencies using package.json deps +3637 verbose cache add [ 'drawille@0.1.1', null ] +3638 verbose cache add name=undefined spec="drawille@0.1.1" args=["drawille@0.1.1",null] +3639 verbose parsed url { protocol: null, +3639 verbose parsed url slashes: null, +3639 verbose parsed url auth: null, +3639 verbose parsed url host: null, +3639 verbose parsed url port: null, +3639 verbose parsed url hostname: null, +3639 verbose parsed url hash: null, +3639 verbose parsed url search: null, +3639 verbose parsed url query: null, +3639 verbose parsed url pathname: 'drawille@0.1.1', +3639 verbose parsed url path: 'drawille@0.1.1', +3639 verbose parsed url href: 'drawille@0.1.1' } +3640 verbose readDependencies using package.json deps +3641 verbose cache add [ 'q@0.9.7', null ] +3642 verbose cache add name=undefined spec="q@0.9.7" args=["q@0.9.7",null] +3643 verbose parsed url { protocol: null, +3643 verbose parsed url slashes: null, +3643 verbose parsed url auth: null, +3643 verbose parsed url host: null, +3643 verbose parsed url port: null, +3643 verbose parsed url hostname: null, +3643 verbose parsed url hash: null, +3643 verbose parsed url search: null, +3643 verbose parsed url query: null, +3643 verbose parsed url pathname: 'q@0.9.7', +3643 verbose parsed url path: 'q@0.9.7', +3643 verbose parsed url href: 'q@0.9.7' } +3644 verbose readDependencies using package.json deps +3645 verbose cache add [ 'socket.io@0.9.17', null ] +3646 verbose cache add name=undefined spec="socket.io@0.9.17" args=["socket.io@0.9.17",null] +3647 verbose parsed url { protocol: null, +3647 verbose parsed url slashes: null, +3647 verbose parsed url auth: null, +3647 verbose parsed url host: null, +3647 verbose parsed url port: null, +3647 verbose parsed url hostname: null, +3647 verbose parsed url hash: null, +3647 verbose parsed url search: null, +3647 verbose parsed url query: null, +3647 verbose parsed url pathname: 'socket.io@0.9.17', +3647 verbose parsed url path: 'socket.io@0.9.17', +3647 verbose parsed url href: 'socket.io@0.9.17' } +3648 verbose readDependencies using package.json deps +3649 verbose cache add [ 'glob@3.2.11', null ] +3650 verbose cache add name=undefined spec="glob@3.2.11" args=["glob@3.2.11",null] +3651 verbose parsed url { protocol: null, +3651 verbose parsed url slashes: null, +3651 verbose parsed url auth: null, +3651 verbose parsed url host: null, +3651 verbose parsed url port: null, +3651 verbose parsed url hostname: null, +3651 verbose parsed url hash: null, +3651 verbose parsed url search: null, +3651 verbose parsed url query: null, +3651 verbose parsed url pathname: 'glob@3.2.11', +3651 verbose parsed url path: 'glob@3.2.11', +3651 verbose parsed url href: 'glob@3.2.11' } +3652 verbose readDependencies using package.json deps +3653 verbose cache add [ 'http-proxy@0.10.4', null ] +3654 verbose cache add name=undefined spec="http-proxy@0.10.4" args=["http-proxy@0.10.4",null] +3655 verbose parsed url { protocol: null, +3655 verbose parsed url slashes: null, +3655 verbose parsed url auth: null, +3655 verbose parsed url host: null, +3655 verbose parsed url port: null, +3655 verbose parsed url hostname: null, +3655 verbose parsed url hash: null, +3655 verbose parsed url search: null, +3655 verbose parsed url query: null, +3655 verbose parsed url pathname: 'http-proxy@0.10.4', +3655 verbose parsed url path: 'http-proxy@0.10.4', +3655 verbose parsed url href: 'http-proxy@0.10.4' } +3656 verbose readDependencies using package.json deps +3657 verbose cache add [ 'graceful-fs@2.0.3', null ] +3658 verbose cache add name=undefined spec="graceful-fs@2.0.3" args=["graceful-fs@2.0.3",null] +3659 verbose parsed url { protocol: null, +3659 verbose parsed url slashes: null, +3659 verbose parsed url auth: null, +3659 verbose parsed url host: null, +3659 verbose parsed url port: null, +3659 verbose parsed url hostname: null, +3659 verbose parsed url hash: null, +3659 verbose parsed url search: null, +3659 verbose parsed url query: null, +3659 verbose parsed url pathname: 'graceful-fs@2.0.3', +3659 verbose parsed url path: 'graceful-fs@2.0.3', +3659 verbose parsed url href: 'graceful-fs@2.0.3' } +3660 verbose readDependencies using package.json deps +3661 verbose cache add [ 'connect@2.12.0', null ] +3662 verbose cache add name=undefined spec="connect@2.12.0" args=["connect@2.12.0",null] +3663 verbose parsed url { protocol: null, +3663 verbose parsed url slashes: null, +3663 verbose parsed url auth: null, +3663 verbose parsed url host: null, +3663 verbose parsed url port: null, +3663 verbose parsed url hostname: null, +3663 verbose parsed url hash: null, +3663 verbose parsed url search: null, +3663 verbose parsed url query: null, +3663 verbose parsed url pathname: 'connect@2.12.0', +3663 verbose parsed url path: 'connect@2.12.0', +3663 verbose parsed url href: 'connect@2.12.0' } +3664 verbose readDependencies using package.json deps +3665 verbose cache add [ 'minimatch@0.2.14', null ] +3666 verbose cache add name=undefined spec="minimatch@0.2.14" args=["minimatch@0.2.14",null] +3667 verbose parsed url { protocol: null, +3667 verbose parsed url slashes: null, +3667 verbose parsed url auth: null, +3667 verbose parsed url host: null, +3667 verbose parsed url port: null, +3667 verbose parsed url hostname: null, +3667 verbose parsed url hash: null, +3667 verbose parsed url search: null, +3667 verbose parsed url query: null, +3667 verbose parsed url pathname: 'minimatch@0.2.14', +3667 verbose parsed url path: 'minimatch@0.2.14', +3667 verbose parsed url href: 'minimatch@0.2.14' } +3668 verbose readDependencies using package.json deps +3669 verbose cache add [ 'minimist@0.0.10', null ] +3670 verbose cache add name=undefined spec="minimist@0.0.10" args=["minimist@0.0.10",null] +3671 verbose parsed url { protocol: null, +3671 verbose parsed url slashes: null, +3671 verbose parsed url auth: null, +3671 verbose parsed url host: null, +3671 verbose parsed url port: null, +3671 verbose parsed url hostname: null, +3671 verbose parsed url hash: null, +3671 verbose parsed url search: null, +3671 verbose parsed url query: null, +3671 verbose parsed url pathname: 'minimist@0.0.10', +3671 verbose parsed url path: 'minimist@0.0.10', +3671 verbose parsed url href: 'minimist@0.0.10' } +3672 verbose readDependencies using package.json deps +3673 verbose cache add [ 'lru-cache@2.2.4', null ] +3674 verbose cache add name=undefined spec="lru-cache@2.2.4" args=["lru-cache@2.2.4",null] +3675 verbose parsed url { protocol: null, +3675 verbose parsed url slashes: null, +3675 verbose parsed url auth: null, +3675 verbose parsed url host: null, +3675 verbose parsed url port: null, +3675 verbose parsed url hostname: null, +3675 verbose parsed url hash: null, +3675 verbose parsed url search: null, +3675 verbose parsed url query: null, +3675 verbose parsed url pathname: 'lru-cache@2.2.4', +3675 verbose parsed url path: 'lru-cache@2.2.4', +3675 verbose parsed url href: 'lru-cache@2.2.4' } +3676 verbose readDependencies using package.json deps +3677 verbose cache add [ 'git+https://github.com/pipobscure/fsevents#7dcdf9fa3f8956610fd6f69f72c67bace2de7138', +3677 verbose cache add null ] +3678 verbose cache add name=undefined spec="git+https://github.com/pipobscure/fsevents#7dcdf9fa3f8956610fd6f69f72c67bace2de7138" args=["git+https://github.com/pipobscure/fsevents#7dcdf9fa3f8956610fd6f69f72c67bace2de7138",null] +3679 verbose parsed url { protocol: 'git+https:', +3679 verbose parsed url slashes: true, +3679 verbose parsed url auth: null, +3679 verbose parsed url host: 'github.com', +3679 verbose parsed url port: null, +3679 verbose parsed url hostname: 'github.com', +3679 verbose parsed url hash: '#7dcdf9fa3f8956610fd6f69f72c67bace2de7138', +3679 verbose parsed url search: null, +3679 verbose parsed url query: null, +3679 verbose parsed url pathname: '/pipobscure/fsevents', +3679 verbose parsed url path: '/pipobscure/fsevents', +3679 verbose parsed url href: 'git+https://github.com/pipobscure/fsevents#7dcdf9fa3f8956610fd6f69f72c67bace2de7138' } +3680 silly lockFile 8cf929e2-s-github-com-pipobscure-fsevents https://github.com/pipobscure/fsevents +3681 verbose lock https://github.com/pipobscure/fsevents /root/.npm/8cf929e2-s-github-com-pipobscure-fsevents.lock +3682 verbose readDependencies using package.json deps +3683 verbose cache add [ 'recursive-readdir@0.0.2', null ] +3684 verbose cache add name=undefined spec="recursive-readdir@0.0.2" args=["recursive-readdir@0.0.2",null] +3685 verbose parsed url { protocol: null, +3685 verbose parsed url slashes: null, +3685 verbose parsed url auth: null, +3685 verbose parsed url host: null, +3685 verbose parsed url port: null, +3685 verbose parsed url hostname: null, +3685 verbose parsed url hash: null, +3685 verbose parsed url search: null, +3685 verbose parsed url query: null, +3685 verbose parsed url pathname: 'recursive-readdir@0.0.2', +3685 verbose parsed url path: 'recursive-readdir@0.0.2', +3685 verbose parsed url href: 'recursive-readdir@0.0.2' } +3686 verbose readDependencies using package.json deps +3687 verbose cache add [ 'async@0.2.10', null ] +3688 verbose cache add name=undefined spec="async@0.2.10" args=["async@0.2.10",null] +3689 verbose parsed url { protocol: null, +3689 verbose parsed url slashes: null, +3689 verbose parsed url auth: null, +3689 verbose parsed url host: null, +3689 verbose parsed url port: null, +3689 verbose parsed url hostname: null, +3689 verbose parsed url hash: null, +3689 verbose parsed url search: null, +3689 verbose parsed url query: null, +3689 verbose parsed url pathname: 'async@0.2.10', +3689 verbose parsed url path: 'async@0.2.10', +3689 verbose parsed url href: 'async@0.2.10' } +3690 verbose readDependencies using package.json deps +3691 verbose cache add [ 'semver@1.1.4', null ] +3692 verbose cache add name=undefined spec="semver@1.1.4" args=["semver@1.1.4",null] +3693 verbose parsed url { protocol: null, +3693 verbose parsed url slashes: null, +3693 verbose parsed url auth: null, +3693 verbose parsed url host: null, +3693 verbose parsed url port: null, +3693 verbose parsed url hostname: null, +3693 verbose parsed url hash: null, +3693 verbose parsed url search: null, +3693 verbose parsed url query: null, +3693 verbose parsed url pathname: 'semver@1.1.4', +3693 verbose parsed url path: 'semver@1.1.4', +3693 verbose parsed url href: 'semver@1.1.4' } +3694 verbose readDependencies using package.json deps +3695 verbose cache add [ 'minimatch@0.3.0', null ] +3696 verbose cache add name=undefined spec="minimatch@0.3.0" args=["minimatch@0.3.0",null] +3697 verbose parsed url { protocol: null, +3697 verbose parsed url slashes: null, +3697 verbose parsed url auth: null, +3697 verbose parsed url host: null, +3697 verbose parsed url port: null, +3697 verbose parsed url hostname: null, +3697 verbose parsed url hash: null, +3697 verbose parsed url search: null, +3697 verbose parsed url query: null, +3697 verbose parsed url pathname: 'minimatch@0.3.0', +3697 verbose parsed url path: 'minimatch@0.3.0', +3697 verbose parsed url href: 'minimatch@0.3.0' } +3698 verbose readDependencies using package.json deps +3699 verbose cache add [ 'resolve@0.7.4', null ] +3700 verbose cache add name=undefined spec="resolve@0.7.4" args=["resolve@0.7.4",null] +3701 verbose parsed url { protocol: null, +3701 verbose parsed url slashes: null, +3701 verbose parsed url auth: null, +3701 verbose parsed url host: null, +3701 verbose parsed url port: null, +3701 verbose parsed url hostname: null, +3701 verbose parsed url hash: null, +3701 verbose parsed url search: null, +3701 verbose parsed url query: null, +3701 verbose parsed url pathname: 'resolve@0.7.4', +3701 verbose parsed url path: 'resolve@0.7.4', +3701 verbose parsed url href: 'resolve@0.7.4' } +3702 verbose readDependencies using package.json deps +3703 verbose cache add [ 'minimist@0.0.8', null ] +3704 verbose cache add name=undefined spec="minimist@0.0.8" args=["minimist@0.0.8",null] +3705 verbose parsed url { protocol: null, +3705 verbose parsed url slashes: null, +3705 verbose parsed url auth: null, +3705 verbose parsed url host: null, +3705 verbose parsed url port: null, +3705 verbose parsed url hostname: null, +3705 verbose parsed url hash: null, +3705 verbose parsed url search: null, +3705 verbose parsed url query: null, +3705 verbose parsed url pathname: 'minimist@0.0.8', +3705 verbose parsed url path: 'minimist@0.0.8', +3705 verbose parsed url href: 'minimist@0.0.8' } +3706 verbose readDependencies using package.json deps +3707 verbose cache add [ 'escodegen@1.3.3', null ] +3708 verbose cache add name=undefined spec="escodegen@1.3.3" args=["escodegen@1.3.3",null] +3709 verbose parsed url { protocol: null, +3709 verbose parsed url slashes: null, +3709 verbose parsed url auth: null, +3709 verbose parsed url host: null, +3709 verbose parsed url port: null, +3709 verbose parsed url hostname: null, +3709 verbose parsed url hash: null, +3709 verbose parsed url search: null, +3709 verbose parsed url query: null, +3709 verbose parsed url pathname: 'escodegen@1.3.3', +3709 verbose parsed url path: 'escodegen@1.3.3', +3709 verbose parsed url href: 'escodegen@1.3.3' } +3710 verbose readDependencies using package.json deps +3711 verbose cache add [ 'handlebars@1.3.0', null ] +3712 verbose cache add name=undefined spec="handlebars@1.3.0" args=["handlebars@1.3.0",null] +3713 verbose parsed url { protocol: null, +3713 verbose parsed url slashes: null, +3713 verbose parsed url auth: null, +3713 verbose parsed url host: null, +3713 verbose parsed url port: null, +3713 verbose parsed url hostname: null, +3713 verbose parsed url hash: null, +3713 verbose parsed url search: null, +3713 verbose parsed url query: null, +3713 verbose parsed url pathname: 'handlebars@1.3.0', +3713 verbose parsed url path: 'handlebars@1.3.0', +3713 verbose parsed url href: 'handlebars@1.3.0' } +3714 verbose readDependencies using package.json deps +3715 verbose cache add [ 'minimatch@0.4.0', null ] +3716 verbose cache add name=undefined spec="minimatch@0.4.0" args=["minimatch@0.4.0",null] +3717 verbose parsed url { protocol: null, +3717 verbose parsed url slashes: null, +3717 verbose parsed url auth: null, +3717 verbose parsed url host: null, +3717 verbose parsed url port: null, +3717 verbose parsed url hostname: null, +3717 verbose parsed url hash: null, +3717 verbose parsed url search: null, +3717 verbose parsed url query: null, +3717 verbose parsed url pathname: 'minimatch@0.4.0', +3717 verbose parsed url path: 'minimatch@0.4.0', +3717 verbose parsed url href: 'minimatch@0.4.0' } +3718 verbose readDependencies using package.json deps +3719 verbose cache add [ 'glob@3.2.11', null ] +3720 verbose cache add name=undefined spec="glob@3.2.11" args=["glob@3.2.11",null] +3721 verbose parsed url { protocol: null, +3721 verbose parsed url slashes: null, +3721 verbose parsed url auth: null, +3721 verbose parsed url host: null, +3721 verbose parsed url port: null, +3721 verbose parsed url hostname: null, +3721 verbose parsed url hash: null, +3721 verbose parsed url search: null, +3721 verbose parsed url query: null, +3721 verbose parsed url pathname: 'glob@3.2.11', +3721 verbose parsed url path: 'glob@3.2.11', +3721 verbose parsed url href: 'glob@3.2.11' } +3722 verbose readDependencies using package.json deps +3723 verbose cache add [ 'esprima@1.0.4', null ] +3724 verbose cache add name=undefined spec="esprima@1.0.4" args=["esprima@1.0.4",null] +3725 verbose parsed url { protocol: null, +3725 verbose parsed url slashes: null, +3725 verbose parsed url auth: null, +3725 verbose parsed url host: null, +3725 verbose parsed url port: null, +3725 verbose parsed url hostname: null, +3725 verbose parsed url hash: null, +3725 verbose parsed url search: null, +3725 verbose parsed url query: null, +3725 verbose parsed url pathname: 'esprima@1.0.4', +3725 verbose parsed url path: 'esprima@1.0.4', +3725 verbose parsed url href: 'esprima@1.0.4' } +3726 verbose readDependencies using package.json deps +3727 verbose cache add [ 'underscore@1.4.4', null ] +3728 verbose cache add name=undefined spec="underscore@1.4.4" args=["underscore@1.4.4",null] +3729 verbose parsed url { protocol: null, +3729 verbose parsed url slashes: null, +3729 verbose parsed url auth: null, +3729 verbose parsed url host: null, +3729 verbose parsed url port: null, +3729 verbose parsed url hostname: null, +3729 verbose parsed url hash: null, +3729 verbose parsed url search: null, +3729 verbose parsed url query: null, +3729 verbose parsed url pathname: 'underscore@1.4.4', +3729 verbose parsed url path: 'underscore@1.4.4', +3729 verbose parsed url href: 'underscore@1.4.4' } +3730 verbose readDependencies using package.json deps +3731 verbose cache add [ 'istanbul@0.2.16', null ] +3732 verbose cache add name=undefined spec="istanbul@0.2.16" args=["istanbul@0.2.16",null] +3733 verbose parsed url { protocol: null, +3733 verbose parsed url slashes: null, +3733 verbose parsed url auth: null, +3733 verbose parsed url host: null, +3733 verbose parsed url port: null, +3733 verbose parsed url hostname: null, +3733 verbose parsed url hash: null, +3733 verbose parsed url search: null, +3733 verbose parsed url query: null, +3733 verbose parsed url pathname: 'istanbul@0.2.16', +3733 verbose parsed url path: 'istanbul@0.2.16', +3733 verbose parsed url href: 'istanbul@0.2.16' } +3734 verbose readDependencies using package.json deps +3735 verbose cache add [ 'mkdirp@0.3.5', null ] +3736 verbose cache add name=undefined spec="mkdirp@0.3.5" args=["mkdirp@0.3.5",null] +3737 verbose parsed url { protocol: null, +3737 verbose parsed url slashes: null, +3737 verbose parsed url auth: null, +3737 verbose parsed url host: null, +3737 verbose parsed url port: null, +3737 verbose parsed url hostname: null, +3737 verbose parsed url hash: null, +3737 verbose parsed url search: null, +3737 verbose parsed url query: null, +3737 verbose parsed url pathname: 'mkdirp@0.3.5', +3737 verbose parsed url path: 'mkdirp@0.3.5', +3737 verbose parsed url href: 'mkdirp@0.3.5' } +3738 verbose readDependencies using package.json deps +3739 verbose cache add [ 'escodegen@1.1.0', null ] +3740 verbose cache add name=undefined spec="escodegen@1.1.0" args=["escodegen@1.1.0",null] +3741 verbose parsed url { protocol: null, +3741 verbose parsed url slashes: null, +3741 verbose parsed url auth: null, +3741 verbose parsed url host: null, +3741 verbose parsed url port: null, +3741 verbose parsed url hostname: null, +3741 verbose parsed url hash: null, +3741 verbose parsed url search: null, +3741 verbose parsed url query: null, +3741 verbose parsed url pathname: 'escodegen@1.1.0', +3741 verbose parsed url path: 'escodegen@1.1.0', +3741 verbose parsed url href: 'escodegen@1.1.0' } +3742 verbose readDependencies using package.json deps +3743 verbose cache add [ 'minimist@0.0.10', null ] +3744 verbose cache add name=undefined spec="minimist@0.0.10" args=["minimist@0.0.10",null] +3745 verbose parsed url { protocol: null, +3745 verbose parsed url slashes: null, +3745 verbose parsed url auth: null, +3745 verbose parsed url host: null, +3745 verbose parsed url port: null, +3745 verbose parsed url hostname: null, +3745 verbose parsed url hash: null, +3745 verbose parsed url search: null, +3745 verbose parsed url query: null, +3745 verbose parsed url pathname: 'minimist@0.0.10', +3745 verbose parsed url path: 'minimist@0.0.10', +3745 verbose parsed url href: 'minimist@0.0.10' } +3746 verbose readDependencies using package.json deps +3747 verbose cache add [ 'git://github.com/michaelficarra/cscodegen.git#73fd7202ac086c26f18c9d56f025b18b3c6f5383', +3747 verbose cache add null ] +3748 verbose cache add name=undefined spec="git://github.com/michaelficarra/cscodegen.git#73fd7202ac086c26f18c9d56f025b18b3c6f5383" args=["git://github.com/michaelficarra/cscodegen.git#73fd7202ac086c26f18c9d56f025b18b3c6f5383",null] +3749 verbose parsed url { protocol: 'git:', +3749 verbose parsed url slashes: true, +3749 verbose parsed url auth: null, +3749 verbose parsed url host: 'github.com', +3749 verbose parsed url port: null, +3749 verbose parsed url hostname: 'github.com', +3749 verbose parsed url hash: '#73fd7202ac086c26f18c9d56f025b18b3c6f5383', +3749 verbose parsed url search: null, +3749 verbose parsed url query: null, +3749 verbose parsed url pathname: '/michaelficarra/cscodegen.git', +3749 verbose parsed url path: '/michaelficarra/cscodegen.git', +3749 verbose parsed url href: 'git://github.com/michaelficarra/cscodegen.git#73fd7202ac086c26f18c9d56f025b18b3c6f5383' } +3750 silly lockFile c4b567f3-com-michaelficarra-cscodegen-git git://github.com/michaelficarra/cscodegen.git +3751 verbose lock git://github.com/michaelficarra/cscodegen.git /root/.npm/c4b567f3-com-michaelficarra-cscodegen-git.lock +3752 verbose readDependencies using package.json deps +3753 verbose cache add [ 'nopt@2.1.2', null ] +3754 verbose cache add name=undefined spec="nopt@2.1.2" args=["nopt@2.1.2",null] +3755 verbose parsed url { protocol: null, +3755 verbose parsed url slashes: null, +3755 verbose parsed url auth: null, +3755 verbose parsed url host: null, +3755 verbose parsed url port: null, +3755 verbose parsed url hostname: null, +3755 verbose parsed url hash: null, +3755 verbose parsed url search: null, +3755 verbose parsed url query: null, +3755 verbose parsed url pathname: 'nopt@2.1.2', +3755 verbose parsed url path: 'nopt@2.1.2', +3755 verbose parsed url href: 'nopt@2.1.2' } +3756 verbose readDependencies using package.json deps +3757 verbose cache add [ 'source-map@0.1.11', null ] +3758 verbose cache add name=undefined spec="source-map@0.1.11" args=["source-map@0.1.11",null] +3759 verbose parsed url { protocol: null, +3759 verbose parsed url slashes: null, +3759 verbose parsed url auth: null, +3759 verbose parsed url host: null, +3759 verbose parsed url port: null, +3759 verbose parsed url hostname: null, +3759 verbose parsed url hash: null, +3759 verbose parsed url search: null, +3759 verbose parsed url query: null, +3759 verbose parsed url pathname: 'source-map@0.1.11', +3759 verbose parsed url path: 'source-map@0.1.11', +3759 verbose parsed url href: 'source-map@0.1.11' } +3760 verbose readDependencies using package.json deps +3761 verbose cache add [ 'escodegen@0.0.28', null ] +3762 verbose cache add name=undefined spec="escodegen@0.0.28" args=["escodegen@0.0.28",null] +3763 verbose parsed url { protocol: null, +3763 verbose parsed url slashes: null, +3763 verbose parsed url auth: null, +3763 verbose parsed url host: null, +3763 verbose parsed url port: null, +3763 verbose parsed url hostname: null, +3763 verbose parsed url hash: null, +3763 verbose parsed url search: null, +3763 verbose parsed url query: null, +3763 verbose parsed url pathname: 'escodegen@0.0.28', +3763 verbose parsed url path: 'escodegen@0.0.28', +3763 verbose parsed url href: 'escodegen@0.0.28' } +3764 verbose readDependencies using package.json deps +3765 verbose cache add [ 'esmangle@0.0.17', null ] +3766 verbose cache add name=undefined spec="esmangle@0.0.17" args=["esmangle@0.0.17",null] +3767 verbose parsed url { protocol: null, +3767 verbose parsed url slashes: null, +3767 verbose parsed url auth: null, +3767 verbose parsed url host: null, +3767 verbose parsed url port: null, +3767 verbose parsed url hostname: null, +3767 verbose parsed url hash: null, +3767 verbose parsed url search: null, +3767 verbose parsed url query: null, +3767 verbose parsed url pathname: 'esmangle@0.0.17', +3767 verbose parsed url path: 'esmangle@0.0.17', +3767 verbose parsed url href: 'esmangle@0.0.17' } +3768 verbose readDependencies using package.json deps +3769 verbose cache add [ 'request@2.42.0', null ] +3770 verbose cache add name=undefined spec="request@2.42.0" args=["request@2.42.0",null] +3771 verbose parsed url { protocol: null, +3771 verbose parsed url slashes: null, +3771 verbose parsed url auth: null, +3771 verbose parsed url host: null, +3771 verbose parsed url port: null, +3771 verbose parsed url hostname: null, +3771 verbose parsed url hash: null, +3771 verbose parsed url search: null, +3771 verbose parsed url query: null, +3771 verbose parsed url pathname: 'request@2.42.0', +3771 verbose parsed url path: 'request@2.42.0', +3771 verbose parsed url href: 'request@2.42.0' } +3772 verbose readDependencies using package.json deps +3773 verbose cache add [ 'minimist@0.0.8', null ] +3774 verbose cache add name=undefined spec="minimist@0.0.8" args=["minimist@0.0.8",null] +3775 verbose parsed url { protocol: null, +3775 verbose parsed url slashes: null, +3775 verbose parsed url auth: null, +3775 verbose parsed url host: null, +3775 verbose parsed url port: null, +3775 verbose parsed url hostname: null, +3775 verbose parsed url hash: null, +3775 verbose parsed url search: null, +3775 verbose parsed url query: null, +3775 verbose parsed url pathname: 'minimist@0.0.8', +3775 verbose parsed url path: 'minimist@0.0.8', +3775 verbose parsed url href: 'minimist@0.0.8' } +3776 verbose readDependencies using package.json deps +3777 verbose cache add [ 'semver@4.0.0', null ] +3778 verbose cache add name=undefined spec="semver@4.0.0" args=["semver@4.0.0",null] +3779 verbose parsed url { protocol: null, +3779 verbose parsed url slashes: null, +3779 verbose parsed url auth: null, +3779 verbose parsed url host: null, +3779 verbose parsed url port: null, +3779 verbose parsed url hostname: null, +3779 verbose parsed url hash: null, +3779 verbose parsed url search: null, +3779 verbose parsed url query: null, +3779 verbose parsed url pathname: 'semver@4.0.0', +3779 verbose parsed url path: 'semver@4.0.0', +3779 verbose parsed url href: 'semver@4.0.0' } +3780 verbose readDependencies using package.json deps +3781 verbose cache add [ 'nopt@2.2.1', null ] +3782 verbose cache add name=undefined spec="nopt@2.2.1" args=["nopt@2.2.1",null] +3783 verbose parsed url { protocol: null, +3783 verbose parsed url slashes: null, +3783 verbose parsed url auth: null, +3783 verbose parsed url host: null, +3783 verbose parsed url port: null, +3783 verbose parsed url hostname: null, +3783 verbose parsed url hash: null, +3783 verbose parsed url search: null, +3783 verbose parsed url query: null, +3783 verbose parsed url pathname: 'nopt@2.2.1', +3783 verbose parsed url path: 'nopt@2.2.1', +3783 verbose parsed url href: 'nopt@2.2.1' } +3784 verbose readDependencies using package.json deps +3785 verbose cache add [ 'deep-equal@0.0.0', null ] +3786 verbose cache add name=undefined spec="deep-equal@0.0.0" args=["deep-equal@0.0.0",null] +3787 verbose parsed url { protocol: null, +3787 verbose parsed url slashes: null, +3787 verbose parsed url auth: null, +3787 verbose parsed url host: null, +3787 verbose parsed url port: null, +3787 verbose parsed url hostname: null, +3787 verbose parsed url hash: null, +3787 verbose parsed url search: null, +3787 verbose parsed url query: null, +3787 verbose parsed url pathname: 'deep-equal@0.0.0', +3787 verbose parsed url path: 'deep-equal@0.0.0', +3787 verbose parsed url href: 'deep-equal@0.0.0' } +3788 verbose readDependencies using package.json deps +3789 verbose cache add [ 'glob@3.2.11', null ] +3790 verbose cache add name=undefined spec="glob@3.2.11" args=["glob@3.2.11",null] +3791 verbose parsed url { protocol: null, +3791 verbose parsed url slashes: null, +3791 verbose parsed url auth: null, +3791 verbose parsed url host: null, +3791 verbose parsed url port: null, +3791 verbose parsed url hostname: null, +3791 verbose parsed url hash: null, +3791 verbose parsed url search: null, +3791 verbose parsed url query: null, +3791 verbose parsed url pathname: 'glob@3.2.11', +3791 verbose parsed url path: 'glob@3.2.11', +3791 verbose parsed url href: 'glob@3.2.11' } +3792 verbose readDependencies using package.json deps +3793 verbose cache add [ 'minimist@0.0.8', null ] +3794 verbose cache add name=undefined spec="minimist@0.0.8" args=["minimist@0.0.8",null] +3795 verbose parsed url { protocol: null, +3795 verbose parsed url slashes: null, +3795 verbose parsed url auth: null, +3795 verbose parsed url host: null, +3795 verbose parsed url port: null, +3795 verbose parsed url hostname: null, +3795 verbose parsed url hash: null, +3795 verbose parsed url search: null, +3795 verbose parsed url query: null, +3795 verbose parsed url pathname: 'minimist@0.0.8', +3795 verbose parsed url path: 'minimist@0.0.8', +3795 verbose parsed url href: 'minimist@0.0.8' } +3796 verbose readDependencies using package.json deps +3797 verbose cache add [ 'charm@0.1.2', null ] +3798 verbose cache add name=undefined spec="charm@0.1.2" args=["charm@0.1.2",null] +3799 verbose parsed url { protocol: null, +3799 verbose parsed url slashes: null, +3799 verbose parsed url auth: null, +3799 verbose parsed url host: null, +3799 verbose parsed url port: null, +3799 verbose parsed url hostname: null, +3799 verbose parsed url hash: null, +3799 verbose parsed url search: null, +3799 verbose parsed url query: null, +3799 verbose parsed url pathname: 'charm@0.1.2', +3799 verbose parsed url path: 'charm@0.1.2', +3799 verbose parsed url href: 'charm@0.1.2' } +3800 verbose readDependencies using package.json deps +3801 verbose cache add [ 'traverse@0.5.2', null ] +3802 verbose cache add name=undefined spec="traverse@0.5.2" args=["traverse@0.5.2",null] +3803 verbose parsed url { protocol: null, +3803 verbose parsed url slashes: null, +3803 verbose parsed url auth: null, +3803 verbose parsed url host: null, +3803 verbose parsed url port: null, +3803 verbose parsed url hostname: null, +3803 verbose parsed url hash: null, +3803 verbose parsed url search: null, +3803 verbose parsed url query: null, +3803 verbose parsed url pathname: 'traverse@0.5.2', +3803 verbose parsed url path: 'traverse@0.5.2', +3803 verbose parsed url href: 'traverse@0.5.2' } +3804 verbose readDependencies using package.json deps +3805 verbose cache add [ 'uglify-js@1.1.1', null ] +3806 verbose cache add name=undefined spec="uglify-js@1.1.1" args=["uglify-js@1.1.1",null] +3807 verbose parsed url { protocol: null, +3807 verbose parsed url slashes: null, +3807 verbose parsed url auth: null, +3807 verbose parsed url host: null, +3807 verbose parsed url port: null, +3807 verbose parsed url hostname: null, +3807 verbose parsed url hash: null, +3807 verbose parsed url search: null, +3807 verbose parsed url query: null, +3807 verbose parsed url pathname: 'uglify-js@1.1.1', +3807 verbose parsed url path: 'uglify-js@1.1.1', +3807 verbose parsed url href: 'uglify-js@1.1.1' } +3808 verbose readDependencies using package.json deps +3809 verbose cache add [ 'rework-custom-media@0.1.1', null ] +3810 verbose cache add name=undefined spec="rework-custom-media@0.1.1" args=["rework-custom-media@0.1.1",null] +3811 verbose parsed url { protocol: null, +3811 verbose parsed url slashes: null, +3811 verbose parsed url auth: null, +3811 verbose parsed url host: null, +3811 verbose parsed url port: null, +3811 verbose parsed url hostname: null, +3811 verbose parsed url hash: null, +3811 verbose parsed url search: null, +3811 verbose parsed url query: null, +3811 verbose parsed url pathname: 'rework-custom-media@0.1.1', +3811 verbose parsed url path: 'rework-custom-media@0.1.1', +3811 verbose parsed url href: 'rework-custom-media@0.1.1' } +3812 verbose readDependencies using package.json deps +3813 verbose cache add [ 'to-space-case@0.1.2', null ] +3814 verbose cache add name=undefined spec="to-space-case@0.1.2" args=["to-space-case@0.1.2",null] +3815 verbose parsed url { protocol: null, +3815 verbose parsed url slashes: null, +3815 verbose parsed url auth: null, +3815 verbose parsed url host: null, +3815 verbose parsed url port: null, +3815 verbose parsed url hostname: null, +3815 verbose parsed url hash: null, +3815 verbose parsed url search: null, +3815 verbose parsed url query: null, +3815 verbose parsed url pathname: 'to-space-case@0.1.2', +3815 verbose parsed url path: 'to-space-case@0.1.2', +3815 verbose parsed url href: 'to-space-case@0.1.2' } +3816 verbose readDependencies using package.json deps +3817 verbose cache add [ 'stream-to-array@1.0.0', null ] +3818 verbose cache add name=undefined spec="stream-to-array@1.0.0" args=["stream-to-array@1.0.0",null] +3819 verbose parsed url { protocol: null, +3819 verbose parsed url slashes: null, +3819 verbose parsed url auth: null, +3819 verbose parsed url host: null, +3819 verbose parsed url port: null, +3819 verbose parsed url hostname: null, +3819 verbose parsed url hash: null, +3819 verbose parsed url search: null, +3819 verbose parsed url query: null, +3819 verbose parsed url pathname: 'stream-to-array@1.0.0', +3819 verbose parsed url path: 'stream-to-array@1.0.0', +3819 verbose parsed url href: 'stream-to-array@1.0.0' } +3820 verbose readDependencies using package.json deps +3821 verbose cache add [ 'rgb@0.0.1', null ] +3822 verbose cache add name=undefined spec="rgb@0.0.1" args=["rgb@0.0.1",null] +3823 verbose parsed url { protocol: null, +3823 verbose parsed url slashes: null, +3823 verbose parsed url auth: null, +3823 verbose parsed url host: null, +3823 verbose parsed url port: null, +3823 verbose parsed url hostname: null, +3823 verbose parsed url hash: null, +3823 verbose parsed url search: null, +3823 verbose parsed url query: null, +3823 verbose parsed url pathname: 'rgb@0.0.1', +3823 verbose parsed url path: 'rgb@0.0.1', +3823 verbose parsed url href: 'rgb@0.0.1' } +3824 verbose readDependencies using package.json deps +3825 verbose cache add [ 'convert-source-map@0.3.5', null ] +3826 verbose cache add name=undefined spec="convert-source-map@0.3.5" args=["convert-source-map@0.3.5",null] +3827 verbose parsed url { protocol: null, +3827 verbose parsed url slashes: null, +3827 verbose parsed url auth: null, +3827 verbose parsed url host: null, +3827 verbose parsed url port: null, +3827 verbose parsed url hostname: null, +3827 verbose parsed url hash: null, +3827 verbose parsed url search: null, +3827 verbose parsed url query: null, +3827 verbose parsed url pathname: 'convert-source-map@0.3.5', +3827 verbose parsed url path: 'convert-source-map@0.3.5', +3827 verbose parsed url href: 'convert-source-map@0.3.5' } +3828 verbose readDependencies using package.json deps +3829 verbose cache add [ 'parse-import@0.1.3', null ] +3830 verbose cache add name=undefined spec="parse-import@0.1.3" args=["parse-import@0.1.3",null] +3831 verbose parsed url { protocol: null, +3831 verbose parsed url slashes: null, +3831 verbose parsed url auth: null, +3831 verbose parsed url host: null, +3831 verbose parsed url port: null, +3831 verbose parsed url hostname: null, +3831 verbose parsed url hash: null, +3831 verbose parsed url search: null, +3831 verbose parsed url query: null, +3831 verbose parsed url pathname: 'parse-import@0.1.3', +3831 verbose parsed url path: 'parse-import@0.1.3', +3831 verbose parsed url href: 'parse-import@0.1.3' } +3832 verbose readDependencies using package.json deps +3833 verbose cache add [ 'find-file@0.1.4', null ] +3834 verbose cache add name=undefined spec="find-file@0.1.4" args=["find-file@0.1.4",null] +3835 verbose parsed url { protocol: null, +3835 verbose parsed url slashes: null, +3835 verbose parsed url auth: null, +3835 verbose parsed url host: null, +3835 verbose parsed url port: null, +3835 verbose parsed url hostname: null, +3835 verbose parsed url hash: null, +3835 verbose parsed url search: null, +3835 verbose parsed url query: null, +3835 verbose parsed url pathname: 'find-file@0.1.4', +3835 verbose parsed url path: 'find-file@0.1.4', +3835 verbose parsed url href: 'find-file@0.1.4' } +3836 verbose readDependencies using package.json deps +3837 verbose cache add [ 'balanced-match@0.0.0', null ] +3838 verbose cache add name=undefined spec="balanced-match@0.0.0" args=["balanced-match@0.0.0",null] +3839 verbose parsed url { protocol: null, +3839 verbose parsed url slashes: null, +3839 verbose parsed url auth: null, +3839 verbose parsed url host: null, +3839 verbose parsed url port: null, +3839 verbose parsed url hostname: null, +3839 verbose parsed url hash: null, +3839 verbose parsed url search: null, +3839 verbose parsed url query: null, +3839 verbose parsed url pathname: 'balanced-match@0.0.0', +3839 verbose parsed url path: 'balanced-match@0.0.0', +3839 verbose parsed url href: 'balanced-match@0.0.0' } +3840 verbose readDependencies using package.json deps +3841 verbose cache add [ 'debug@0.7.4', null ] +3842 verbose cache add name=undefined spec="debug@0.7.4" args=["debug@0.7.4",null] +3843 verbose parsed url { protocol: null, +3843 verbose parsed url slashes: null, +3843 verbose parsed url auth: null, +3843 verbose parsed url host: null, +3843 verbose parsed url port: null, +3843 verbose parsed url hostname: null, +3843 verbose parsed url hash: null, +3843 verbose parsed url search: null, +3843 verbose parsed url query: null, +3843 verbose parsed url pathname: 'debug@0.7.4', +3843 verbose parsed url path: 'debug@0.7.4', +3843 verbose parsed url href: 'debug@0.7.4' } +3844 verbose cache add name="coffee-script" spec="1.7.1" args=["coffee-script","1.7.1"] +3845 verbose parsed url { protocol: null, +3845 verbose parsed url slashes: null, +3845 verbose parsed url auth: null, +3845 verbose parsed url host: null, +3845 verbose parsed url port: null, +3845 verbose parsed url hostname: null, +3845 verbose parsed url hash: null, +3845 verbose parsed url search: null, +3845 verbose parsed url query: null, +3845 verbose parsed url pathname: '1.7.1', +3845 verbose parsed url path: '1.7.1', +3845 verbose parsed url href: '1.7.1' } +3846 verbose addNamed [ 'coffee-script', '1.7.1' ] +3847 verbose addNamed [ '1.7.1', '1.7.1' ] +3848 silly lockFile 66cb63a1-coffee-script-1-7-1 coffee-script@1.7.1 +3849 verbose lock coffee-script@1.7.1 /root/.npm/66cb63a1-coffee-script-1-7-1.lock +3850 verbose cache add name="commander" spec="1.3.2" args=["commander","1.3.2"] +3851 verbose parsed url { protocol: null, +3851 verbose parsed url slashes: null, +3851 verbose parsed url auth: null, +3851 verbose parsed url host: null, +3851 verbose parsed url port: null, +3851 verbose parsed url hostname: null, +3851 verbose parsed url hash: null, +3851 verbose parsed url search: null, +3851 verbose parsed url query: null, +3851 verbose parsed url pathname: '1.3.2', +3851 verbose parsed url path: '1.3.2', +3851 verbose parsed url href: '1.3.2' } +3852 verbose addNamed [ 'commander', '1.3.2' ] +3853 verbose addNamed [ '1.3.2', '1.3.2' ] +3854 silly lockFile 2016e061-commander-1-3-2 commander@1.3.2 +3855 verbose lock commander@1.3.2 /root/.npm/2016e061-commander-1-3-2.lock +3856 verbose cache add name="minimist" spec="0.0.8" args=["minimist","0.0.8"] +3857 verbose parsed url { protocol: null, +3857 verbose parsed url slashes: null, +3857 verbose parsed url auth: null, +3857 verbose parsed url host: null, +3857 verbose parsed url port: null, +3857 verbose parsed url hostname: null, +3857 verbose parsed url hash: null, +3857 verbose parsed url search: null, +3857 verbose parsed url query: null, +3857 verbose parsed url pathname: '0.0.8', +3857 verbose parsed url path: '0.0.8', +3857 verbose parsed url href: '0.0.8' } +3858 verbose addNamed [ 'minimist', '0.0.8' ] +3859 verbose addNamed [ '0.0.8', '0.0.8' ] +3860 silly lockFile 22c6b485-minimist-0-0-8 minimist@0.0.8 +3861 verbose lock minimist@0.0.8 /root/.npm/22c6b485-minimist-0-0-8.lock +3862 verbose cache add name="nopt" spec="1.0.10" args=["nopt","1.0.10"] +3863 verbose parsed url { protocol: null, +3863 verbose parsed url slashes: null, +3863 verbose parsed url auth: null, +3863 verbose parsed url host: null, +3863 verbose parsed url port: null, +3863 verbose parsed url hostname: null, +3863 verbose parsed url hash: null, +3863 verbose parsed url search: null, +3863 verbose parsed url query: null, +3863 verbose parsed url pathname: '1.0.10', +3863 verbose parsed url path: '1.0.10', +3863 verbose parsed url href: '1.0.10' } +3864 verbose addNamed [ 'nopt', '1.0.10' ] +3865 verbose addNamed [ '1.0.10', '1.0.10' ] +3866 silly lockFile 1be903a1-nopt-1-0-10 nopt@1.0.10 +3867 verbose lock nopt@1.0.10 /root/.npm/1be903a1-nopt-1-0-10.lock +3868 verbose cache add name="resolve" spec="0.3.1" args=["resolve","0.3.1"] +3869 verbose parsed url { protocol: null, +3869 verbose parsed url slashes: null, +3869 verbose parsed url auth: null, +3869 verbose parsed url host: null, +3869 verbose parsed url port: null, +3869 verbose parsed url hostname: null, +3869 verbose parsed url hash: null, +3869 verbose parsed url search: null, +3869 verbose parsed url query: null, +3869 verbose parsed url pathname: '0.3.1', +3869 verbose parsed url path: '0.3.1', +3869 verbose parsed url href: '0.3.1' } +3870 verbose addNamed [ 'resolve', '0.3.1' ] +3871 verbose addNamed [ '0.3.1', '0.3.1' ] +3872 silly lockFile 95464470-resolve-0-3-1 resolve@0.3.1 +3873 verbose lock resolve@0.3.1 /root/.npm/95464470-resolve-0-3-1.lock +3874 verbose cache add name="glob" spec="3.2.11" args=["glob","3.2.11"] +3875 verbose parsed url { protocol: null, +3875 verbose parsed url slashes: null, +3875 verbose parsed url auth: null, +3875 verbose parsed url host: null, +3875 verbose parsed url port: null, +3875 verbose parsed url hostname: null, +3875 verbose parsed url hash: null, +3875 verbose parsed url search: null, +3875 verbose parsed url query: null, +3875 verbose parsed url pathname: '3.2.11', +3875 verbose parsed url path: '3.2.11', +3875 verbose parsed url href: '3.2.11' } +3876 verbose addNamed [ 'glob', '3.2.11' ] +3877 verbose addNamed [ '3.2.11', '3.2.11' ] +3878 silly lockFile 3fffafa6-glob-3-2-11 glob@3.2.11 +3879 verbose lock glob@3.2.11 /root/.npm/3fffafa6-glob-3-2-11.lock +3880 verbose cache add name="html5" spec="0.3.14" args=["html5","0.3.14"] +3881 verbose parsed url { protocol: null, +3881 verbose parsed url slashes: null, +3881 verbose parsed url auth: null, +3881 verbose parsed url host: null, +3881 verbose parsed url port: null, +3881 verbose parsed url hostname: null, +3881 verbose parsed url hash: null, +3881 verbose parsed url search: null, +3881 verbose parsed url query: null, +3881 verbose parsed url pathname: '0.3.14', +3881 verbose parsed url path: '0.3.14', +3881 verbose parsed url href: '0.3.14' } +3882 verbose addNamed [ 'html5', '0.3.14' ] +3883 verbose addNamed [ '0.3.14', '0.3.14' ] +3884 silly lockFile cf52c898-html5-0-3-14 html5@0.3.14 +3885 verbose lock html5@0.3.14 /root/.npm/cf52c898-html5-0-3-14.lock +3886 verbose cache add name="eventsource" spec="0.0.10" args=["eventsource","0.0.10"] +3887 verbose parsed url { protocol: null, +3887 verbose parsed url slashes: null, +3887 verbose parsed url auth: null, +3887 verbose parsed url host: null, +3887 verbose parsed url port: null, +3887 verbose parsed url hostname: null, +3887 verbose parsed url hash: null, +3887 verbose parsed url search: null, +3887 verbose parsed url query: null, +3887 verbose parsed url pathname: '0.0.10', +3887 verbose parsed url path: '0.0.10', +3887 verbose parsed url href: '0.0.10' } +3888 verbose addNamed [ 'eventsource', '0.0.10' ] +3889 verbose addNamed [ '0.0.10', '0.0.10' ] +3890 silly lockFile 9b39a648-eventsource-0-0-10 eventsource@0.0.10 +3891 verbose lock eventsource@0.0.10 /root/.npm/9b39a648-eventsource-0-0-10.lock +3892 verbose cache add name="q" spec="1.0.0" args=["q","1.0.0"] +3893 verbose parsed url { protocol: null, +3893 verbose parsed url slashes: null, +3893 verbose parsed url auth: null, +3893 verbose parsed url host: null, +3893 verbose parsed url port: null, +3893 verbose parsed url hostname: null, +3893 verbose parsed url hash: null, +3893 verbose parsed url search: null, +3893 verbose parsed url query: null, +3893 verbose parsed url pathname: '1.0.0', +3893 verbose parsed url path: '1.0.0', +3893 verbose parsed url href: '1.0.0' } +3894 verbose addNamed [ 'q', '1.0.0' ] +3895 verbose addNamed [ '1.0.0', '1.0.0' ] +3896 silly lockFile 4a267efb-q-1-0-0 q@1.0.0 +3897 verbose lock q@1.0.0 /root/.npm/4a267efb-q-1-0-0.lock +3898 verbose cache add name="request" spec="2.34.0" args=["request","2.34.0"] +3899 verbose parsed url { protocol: null, +3899 verbose parsed url slashes: null, +3899 verbose parsed url auth: null, +3899 verbose parsed url host: null, +3899 verbose parsed url port: null, +3899 verbose parsed url hostname: null, +3899 verbose parsed url hash: null, +3899 verbose parsed url search: null, +3899 verbose parsed url query: null, +3899 verbose parsed url pathname: '2.34.0', +3899 verbose parsed url path: '2.34.0', +3899 verbose parsed url href: '2.34.0' } +3900 verbose addNamed [ 'request', '2.34.0' ] +3901 verbose addNamed [ '2.34.0', '2.34.0' ] +3902 silly lockFile a8edf972-request-2-34-0 request@2.34.0 +3903 verbose lock request@2.34.0 /root/.npm/a8edf972-request-2-34-0.lock +3904 verbose cache add name="ws" spec="0.4.31" args=["ws","0.4.31"] +3905 verbose parsed url { protocol: null, +3905 verbose parsed url slashes: null, +3905 verbose parsed url auth: null, +3905 verbose parsed url host: null, +3905 verbose parsed url port: null, +3905 verbose parsed url hostname: null, +3905 verbose parsed url hash: null, +3905 verbose parsed url search: null, +3905 verbose parsed url query: null, +3905 verbose parsed url pathname: '0.4.31', +3905 verbose parsed url path: '0.4.31', +3905 verbose parsed url href: '0.4.31' } +3906 verbose addNamed [ 'ws', '0.4.31' ] +3907 verbose addNamed [ '0.4.31', '0.4.31' ] +3908 silly lockFile 53e67403-ws-0-4-31 ws@0.4.31 +3909 verbose lock ws@0.4.31 /root/.npm/53e67403-ws-0-4-31.lock +3910 verbose cache add name="encoding" spec="0.1.7" args=["encoding","0.1.7"] +3911 verbose parsed url { protocol: null, +3911 verbose parsed url slashes: null, +3911 verbose parsed url auth: null, +3911 verbose parsed url host: null, +3911 verbose parsed url port: null, +3911 verbose parsed url hostname: null, +3911 verbose parsed url hash: null, +3911 verbose parsed url search: null, +3911 verbose parsed url query: null, +3911 verbose parsed url pathname: '0.1.7', +3911 verbose parsed url path: '0.1.7', +3911 verbose parsed url href: '0.1.7' } +3912 verbose addNamed [ 'encoding', '0.1.7' ] +3913 verbose addNamed [ '0.1.7', '0.1.7' ] +3914 silly lockFile 28678d21-encoding-0-1-7 encoding@0.1.7 +3915 verbose lock encoding@0.1.7 /root/.npm/28678d21-encoding-0-1-7.lock +3916 verbose cache add name="jsdom" spec="0.8.11" args=["jsdom","0.8.11"] +3917 verbose parsed url { protocol: null, +3917 verbose parsed url slashes: null, +3917 verbose parsed url auth: null, +3917 verbose parsed url host: null, +3917 verbose parsed url port: null, +3917 verbose parsed url hostname: null, +3917 verbose parsed url hash: null, +3917 verbose parsed url search: null, +3917 verbose parsed url query: null, +3917 verbose parsed url pathname: '0.8.11', +3917 verbose parsed url path: '0.8.11', +3917 verbose parsed url href: '0.8.11' } +3918 verbose addNamed [ 'jsdom', '0.8.11' ] +3919 verbose addNamed [ '0.8.11', '0.8.11' ] +3920 silly lockFile 8d7847b7-jsdom-0-8-11 jsdom@0.8.11 +3921 verbose lock jsdom@0.8.11 /root/.npm/8d7847b7-jsdom-0-8-11.lock +3922 verbose cache add name="dateformat" spec="1.0.2-1.2.3" args=["dateformat","1.0.2-1.2.3"] +3923 verbose parsed url { protocol: null, +3923 verbose parsed url slashes: null, +3923 verbose parsed url auth: null, +3923 verbose parsed url host: null, +3923 verbose parsed url port: null, +3923 verbose parsed url hostname: null, +3923 verbose parsed url hash: null, +3923 verbose parsed url search: null, +3923 verbose parsed url query: null, +3923 verbose parsed url pathname: '1.0.2-1.2.3', +3923 verbose parsed url path: '1.0.2-1.2.3', +3923 verbose parsed url href: '1.0.2-1.2.3' } +3924 verbose addNamed [ 'dateformat', '1.0.2-1.2.3' ] +3925 verbose addNamed [ '1.0.2-1.2.3', '1.0.2-1.2.3' ] +3926 silly lockFile 644d6e27-dateformat-1-0-2-1-2-3 dateformat@1.0.2-1.2.3 +3927 verbose lock dateformat@1.0.2-1.2.3 /root/.npm/644d6e27-dateformat-1-0-2-1-2-3.lock +3928 verbose cache add name="glob" spec="3.1.21" args=["glob","3.1.21"] +3929 verbose parsed url { protocol: null, +3929 verbose parsed url slashes: null, +3929 verbose parsed url auth: null, +3929 verbose parsed url host: null, +3929 verbose parsed url port: null, +3929 verbose parsed url hostname: null, +3929 verbose parsed url hash: null, +3929 verbose parsed url search: null, +3929 verbose parsed url query: null, +3929 verbose parsed url pathname: '3.1.21', +3929 verbose parsed url path: '3.1.21', +3929 verbose parsed url href: '3.1.21' } +3930 verbose addNamed [ 'glob', '3.1.21' ] +3931 verbose addNamed [ '3.1.21', '3.1.21' ] +3932 silly lockFile ab465912-glob-3-1-21 glob@3.1.21 +3933 verbose lock glob@3.1.21 /root/.npm/ab465912-glob-3-1-21.lock +3934 verbose cache add name="lodash" spec="0.9.2" args=["lodash","0.9.2"] +3935 verbose parsed url { protocol: null, +3935 verbose parsed url slashes: null, +3935 verbose parsed url auth: null, +3935 verbose parsed url host: null, +3935 verbose parsed url port: null, +3935 verbose parsed url hostname: null, +3935 verbose parsed url hash: null, +3935 verbose parsed url search: null, +3935 verbose parsed url query: null, +3935 verbose parsed url pathname: '0.9.2', +3935 verbose parsed url path: '0.9.2', +3935 verbose parsed url href: '0.9.2' } +3936 verbose addNamed [ 'lodash', '0.9.2' ] +3937 verbose addNamed [ '0.9.2', '0.9.2' ] +3938 silly lockFile 9802d919-lodash-0-9-2 lodash@0.9.2 +3939 verbose lock lodash@0.9.2 /root/.npm/9802d919-lodash-0-9-2.lock +3940 verbose cache add name="nopt" spec="1.0.10" args=["nopt","1.0.10"] +3941 verbose parsed url { protocol: null, +3941 verbose parsed url slashes: null, +3941 verbose parsed url auth: null, +3941 verbose parsed url host: null, +3941 verbose parsed url port: null, +3941 verbose parsed url hostname: null, +3941 verbose parsed url hash: null, +3941 verbose parsed url search: null, +3941 verbose parsed url query: null, +3941 verbose parsed url pathname: '1.0.10', +3941 verbose parsed url path: '1.0.10', +3941 verbose parsed url href: '1.0.10' } +3942 verbose addNamed [ 'nopt', '1.0.10' ] +3943 verbose cache add name="underscore.string" spec="2.2.1" args=["underscore.string","2.2.1"] +3944 verbose parsed url { protocol: null, +3944 verbose parsed url slashes: null, +3944 verbose parsed url auth: null, +3944 verbose parsed url host: null, +3944 verbose parsed url port: null, +3944 verbose parsed url hostname: null, +3944 verbose parsed url hash: null, +3944 verbose parsed url search: null, +3944 verbose parsed url query: null, +3944 verbose parsed url pathname: '2.2.1', +3944 verbose parsed url path: '2.2.1', +3944 verbose parsed url href: '2.2.1' } +3945 verbose addNamed [ 'underscore.string', '2.2.1' ] +3946 verbose addNamed [ '2.2.1', '2.2.1' ] +3947 silly lockFile 5c083954-underscore-string-2-2-1 underscore.string@2.2.1 +3948 verbose lock underscore.string@2.2.1 /root/.npm/5c083954-underscore-string-2-2-1.lock +3949 verbose cache add name="iconv-lite" spec="0.2.11" args=["iconv-lite","0.2.11"] +3950 verbose parsed url { protocol: null, +3950 verbose parsed url slashes: null, +3950 verbose parsed url auth: null, +3950 verbose parsed url host: null, +3950 verbose parsed url port: null, +3950 verbose parsed url hostname: null, +3950 verbose parsed url hash: null, +3950 verbose parsed url search: null, +3950 verbose parsed url query: null, +3950 verbose parsed url pathname: '0.2.11', +3950 verbose parsed url path: '0.2.11', +3950 verbose parsed url href: '0.2.11' } +3951 verbose addNamed [ 'iconv-lite', '0.2.11' ] +3952 verbose addNamed [ '0.2.11', '0.2.11' ] +3953 silly lockFile 5d877021-iconv-lite-0-2-11 iconv-lite@0.2.11 +3954 verbose lock iconv-lite@0.2.11 /root/.npm/5d877021-iconv-lite-0-2-11.lock +3955 verbose cache add name="coffee-script" spec="1.3.3" args=["coffee-script","1.3.3"] +3956 verbose parsed url { protocol: null, +3956 verbose parsed url slashes: null, +3956 verbose parsed url auth: null, +3956 verbose parsed url host: null, +3956 verbose parsed url port: null, +3956 verbose parsed url hostname: null, +3956 verbose parsed url hash: null, +3956 verbose parsed url search: null, +3956 verbose parsed url query: null, +3956 verbose parsed url pathname: '1.3.3', +3956 verbose parsed url path: '1.3.3', +3956 verbose parsed url href: '1.3.3' } +3957 verbose addNamed [ 'coffee-script', '1.3.3' ] +3958 verbose addNamed [ '1.3.3', '1.3.3' ] +3959 silly lockFile 022c8436-coffee-script-1-3-3 coffee-script@1.3.3 +3960 verbose lock coffee-script@1.3.3 /root/.npm/022c8436-coffee-script-1-3-3.lock +3961 verbose cache add name="minimatch" spec="0.2.14" args=["minimatch","0.2.14"] +3962 verbose parsed url { protocol: null, +3962 verbose parsed url slashes: null, +3962 verbose parsed url auth: null, +3962 verbose parsed url host: null, +3962 verbose parsed url port: null, +3962 verbose parsed url hostname: null, +3962 verbose parsed url hash: null, +3962 verbose parsed url search: null, +3962 verbose parsed url query: null, +3962 verbose parsed url pathname: '0.2.14', +3962 verbose parsed url path: '0.2.14', +3962 verbose parsed url href: '0.2.14' } +3963 verbose addNamed [ 'minimatch', '0.2.14' ] +3964 verbose addNamed [ '0.2.14', '0.2.14' ] +3965 silly lockFile a72880d0-minimatch-0-2-14 minimatch@0.2.14 +3966 verbose lock minimatch@0.2.14 /root/.npm/a72880d0-minimatch-0-2-14.lock +3967 verbose cache add name="js-yaml" spec="2.0.5" args=["js-yaml","2.0.5"] +3968 verbose parsed url { protocol: null, +3968 verbose parsed url slashes: null, +3968 verbose parsed url auth: null, +3968 verbose parsed url host: null, +3968 verbose parsed url port: null, +3968 verbose parsed url hostname: null, +3968 verbose parsed url hash: null, +3968 verbose parsed url search: null, +3968 verbose parsed url query: null, +3968 verbose parsed url pathname: '2.0.5', +3968 verbose parsed url path: '2.0.5', +3968 verbose parsed url href: '2.0.5' } +3969 verbose addNamed [ 'js-yaml', '2.0.5' ] +3970 verbose addNamed [ '2.0.5', '2.0.5' ] +3971 silly lockFile 0aecb717-js-yaml-2-0-5 js-yaml@2.0.5 +3972 verbose lock js-yaml@2.0.5 /root/.npm/0aecb717-js-yaml-2-0-5.lock +3973 verbose cache add name="async" spec="0.1.22" args=["async","0.1.22"] +3974 verbose parsed url { protocol: null, +3974 verbose parsed url slashes: null, +3974 verbose parsed url auth: null, +3974 verbose parsed url host: null, +3974 verbose parsed url port: null, +3974 verbose parsed url hostname: null, +3974 verbose parsed url hash: null, +3974 verbose parsed url search: null, +3974 verbose parsed url query: null, +3974 verbose parsed url pathname: '0.1.22', +3974 verbose parsed url path: '0.1.22', +3974 verbose parsed url href: '0.1.22' } +3975 verbose addNamed [ 'async', '0.1.22' ] +3976 verbose addNamed [ '0.1.22', '0.1.22' ] +3977 silly lockFile 09d21715-async-0-1-22 async@0.1.22 +3978 verbose lock async@0.1.22 /root/.npm/09d21715-async-0-1-22.lock +3979 verbose cache add name="glob" spec="3.2.11" args=["glob","3.2.11"] +3980 verbose parsed url { protocol: null, +3980 verbose parsed url slashes: null, +3980 verbose parsed url auth: null, +3980 verbose parsed url host: null, +3980 verbose parsed url port: null, +3980 verbose parsed url hostname: null, +3980 verbose parsed url hash: null, +3980 verbose parsed url search: null, +3980 verbose parsed url query: null, +3980 verbose parsed url pathname: '3.2.11', +3980 verbose parsed url path: '3.2.11', +3980 verbose parsed url href: '3.2.11' } +3981 verbose addNamed [ 'glob', '3.2.11' ] +3982 verbose cache add name="async" spec="0.1.22" args=["async","0.1.22"] +3983 verbose parsed url { protocol: null, +3983 verbose parsed url slashes: null, +3983 verbose parsed url auth: null, +3983 verbose parsed url host: null, +3983 verbose parsed url port: null, +3983 verbose parsed url hostname: null, +3983 verbose parsed url hash: null, +3983 verbose parsed url search: null, +3983 verbose parsed url query: null, +3983 verbose parsed url pathname: '0.1.22', +3983 verbose parsed url path: '0.1.22', +3983 verbose parsed url href: '0.1.22' } +3984 verbose addNamed [ 'async', '0.1.22' ] +3985 verbose cache add name="lodash" spec="0.9.2" args=["lodash","0.9.2"] +3986 verbose parsed url { protocol: null, +3986 verbose parsed url slashes: null, +3986 verbose parsed url auth: null, +3986 verbose parsed url host: null, +3986 verbose parsed url port: null, +3986 verbose parsed url hostname: null, +3986 verbose parsed url hash: null, +3986 verbose parsed url search: null, +3986 verbose parsed url query: null, +3986 verbose parsed url pathname: '0.9.2', +3986 verbose parsed url path: '0.9.2', +3986 verbose parsed url href: '0.9.2' } +3987 verbose addNamed [ 'lodash', '0.9.2' ] +3988 verbose cache add name="underscore.string" spec="2.2.1" args=["underscore.string","2.2.1"] +3989 verbose parsed url { protocol: null, +3989 verbose parsed url slashes: null, +3989 verbose parsed url auth: null, +3989 verbose parsed url host: null, +3989 verbose parsed url port: null, +3989 verbose parsed url hostname: null, +3989 verbose parsed url hash: null, +3989 verbose parsed url search: null, +3989 verbose parsed url query: null, +3989 verbose parsed url pathname: '2.2.1', +3989 verbose parsed url path: '2.2.1', +3989 verbose parsed url href: '2.2.1' } +3990 verbose addNamed [ 'underscore.string', '2.2.1' ] +3991 verbose cache add name="depd" spec="0.4.5" args=["depd","0.4.5"] +3992 verbose parsed url { protocol: null, +3992 verbose parsed url slashes: null, +3992 verbose parsed url auth: null, +3992 verbose parsed url host: null, +3992 verbose parsed url port: null, +3992 verbose parsed url hostname: null, +3992 verbose parsed url hash: null, +3992 verbose parsed url search: null, +3992 verbose parsed url query: null, +3992 verbose parsed url pathname: '0.4.5', +3992 verbose parsed url path: '0.4.5', +3992 verbose parsed url href: '0.4.5' } +3993 verbose addNamed [ 'depd', '0.4.5' ] +3994 verbose addNamed [ '0.4.5', '0.4.5' ] +3995 silly lockFile 19d47453-depd-0-4-5 depd@0.4.5 +3996 verbose lock depd@0.4.5 /root/.npm/19d47453-depd-0-4-5.lock +3997 verbose cache add name="finalhandler" spec="0.2.0" args=["finalhandler","0.2.0"] +3998 verbose parsed url { protocol: null, +3998 verbose parsed url slashes: null, +3998 verbose parsed url auth: null, +3998 verbose parsed url host: null, +3998 verbose parsed url port: null, +3998 verbose parsed url hostname: null, +3998 verbose parsed url hash: null, +3998 verbose parsed url search: null, +3998 verbose parsed url query: null, +3998 verbose parsed url pathname: '0.2.0', +3998 verbose parsed url path: '0.2.0', +3998 verbose parsed url href: '0.2.0' } +3999 verbose addNamed [ 'finalhandler', '0.2.0' ] +4000 verbose addNamed [ '0.2.0', '0.2.0' ] +4001 silly lockFile c64219b3-finalhandler-0-2-0 finalhandler@0.2.0 +4002 verbose lock finalhandler@0.2.0 /root/.npm/c64219b3-finalhandler-0-2-0.lock +4003 verbose cache add name="path-to-regexp" spec="0.1.3" args=["path-to-regexp","0.1.3"] +4004 verbose parsed url { protocol: null, +4004 verbose parsed url slashes: null, +4004 verbose parsed url auth: null, +4004 verbose parsed url host: null, +4004 verbose parsed url port: null, +4004 verbose parsed url hostname: null, +4004 verbose parsed url hash: null, +4004 verbose parsed url search: null, +4004 verbose parsed url query: null, +4004 verbose parsed url pathname: '0.1.3', +4004 verbose parsed url path: '0.1.3', +4004 verbose parsed url href: '0.1.3' } +4005 verbose addNamed [ 'path-to-regexp', '0.1.3' ] +4006 verbose addNamed [ '0.1.3', '0.1.3' ] +4007 silly lockFile e50af523-path-to-regexp-0-1-3 path-to-regexp@0.1.3 +4008 verbose lock path-to-regexp@0.1.3 /root/.npm/e50af523-path-to-regexp-0-1-3.lock +4009 verbose cache add name="ms" spec="0.6.2" args=["ms","0.6.2"] +4010 verbose parsed url { protocol: null, +4010 verbose parsed url slashes: null, +4010 verbose parsed url auth: null, +4010 verbose parsed url host: null, +4010 verbose parsed url port: null, +4010 verbose parsed url hostname: null, +4010 verbose parsed url hash: null, +4010 verbose parsed url search: null, +4010 verbose parsed url query: null, +4010 verbose parsed url pathname: '0.6.2', +4010 verbose parsed url path: '0.6.2', +4010 verbose parsed url href: '0.6.2' } +4011 verbose addNamed [ 'ms', '0.6.2' ] +4012 verbose addNamed [ '0.6.2', '0.6.2' ] +4013 silly lockFile 549cc243-ms-0-6-2 ms@0.6.2 +4014 verbose lock ms@0.6.2 /root/.npm/549cc243-ms-0-6-2.lock +4015 verbose cache add name="ee-first" spec="1.0.5" args=["ee-first","1.0.5"] +4016 verbose parsed url { protocol: null, +4016 verbose parsed url slashes: null, +4016 verbose parsed url auth: null, +4016 verbose parsed url host: null, +4016 verbose parsed url port: null, +4016 verbose parsed url hostname: null, +4016 verbose parsed url hash: null, +4016 verbose parsed url search: null, +4016 verbose parsed url query: null, +4016 verbose parsed url pathname: '1.0.5', +4016 verbose parsed url path: '1.0.5', +4016 verbose parsed url href: '1.0.5' } +4017 verbose addNamed [ 'ee-first', '1.0.5' ] +4018 verbose addNamed [ '1.0.5', '1.0.5' ] +4019 silly lockFile 2d236fca-ee-first-1-0-5 ee-first@1.0.5 +4020 verbose lock ee-first@1.0.5 /root/.npm/2d236fca-ee-first-1-0-5.lock +4021 verbose cache add name="mime-types" spec="2.0.1" args=["mime-types","2.0.1"] +4022 verbose parsed url { protocol: null, +4022 verbose parsed url slashes: null, +4022 verbose parsed url auth: null, +4022 verbose parsed url host: null, +4022 verbose parsed url port: null, +4022 verbose parsed url hostname: null, +4022 verbose parsed url hash: null, +4022 verbose parsed url search: null, +4022 verbose parsed url query: null, +4022 verbose parsed url pathname: '2.0.1', +4022 verbose parsed url path: '2.0.1', +4022 verbose parsed url href: '2.0.1' } +4023 verbose addNamed [ 'mime-types', '2.0.1' ] +4024 verbose addNamed [ '2.0.1', '2.0.1' ] +4025 silly lockFile 64a74d75-mime-types-2-0-1 mime-types@2.0.1 +4026 verbose lock mime-types@2.0.1 /root/.npm/64a74d75-mime-types-2-0-1.lock +4027 verbose cache add name="negotiator" spec="0.4.7" args=["negotiator","0.4.7"] +4028 verbose parsed url { protocol: null, +4028 verbose parsed url slashes: null, +4028 verbose parsed url auth: null, +4028 verbose parsed url host: null, +4028 verbose parsed url port: null, +4028 verbose parsed url hostname: null, +4028 verbose parsed url hash: null, +4028 verbose parsed url search: null, +4028 verbose parsed url query: null, +4028 verbose parsed url pathname: '0.4.7', +4028 verbose parsed url path: '0.4.7', +4028 verbose parsed url href: '0.4.7' } +4029 verbose addNamed [ 'negotiator', '0.4.7' ] +4030 verbose addNamed [ '0.4.7', '0.4.7' ] +4031 silly lockFile 574e94a4-negotiator-0-4-7 negotiator@0.4.7 +4032 verbose lock negotiator@0.4.7 /root/.npm/574e94a4-negotiator-0-4-7.lock +4033 verbose cache add name="ipaddr.js" spec="0.1.3" args=["ipaddr.js","0.1.3"] +4034 verbose parsed url { protocol: null, +4034 verbose parsed url slashes: null, +4034 verbose parsed url auth: null, +4034 verbose parsed url host: null, +4034 verbose parsed url port: null, +4034 verbose parsed url hostname: null, +4034 verbose parsed url hash: null, +4034 verbose parsed url search: null, +4034 verbose parsed url query: null, +4034 verbose parsed url pathname: '0.1.3', +4034 verbose parsed url path: '0.1.3', +4034 verbose parsed url href: '0.1.3' } +4035 verbose addNamed [ 'ipaddr.js', '0.1.3' ] +4036 verbose addNamed [ '0.1.3', '0.1.3' ] +4037 silly lockFile d2c4a0f8-ipaddr-js-0-1-3 ipaddr.js@0.1.3 +4038 verbose lock ipaddr.js@0.1.3 /root/.npm/d2c4a0f8-ipaddr-js-0-1-3.lock +4039 verbose cache add name="depd" spec="0.4.5" args=["depd","0.4.5"] +4040 verbose parsed url { protocol: null, +4040 verbose parsed url slashes: null, +4040 verbose parsed url auth: null, +4040 verbose parsed url host: null, +4040 verbose parsed url port: null, +4040 verbose parsed url hostname: null, +4040 verbose parsed url hash: null, +4040 verbose parsed url search: null, +4040 verbose parsed url query: null, +4040 verbose parsed url pathname: '0.4.5', +4040 verbose parsed url path: '0.4.5', +4040 verbose parsed url href: '0.4.5' } +4041 verbose addNamed [ 'depd', '0.4.5' ] +4042 verbose cache add name="mime" spec="1.2.11" args=["mime","1.2.11"] +4043 verbose parsed url { protocol: null, +4043 verbose parsed url slashes: null, +4043 verbose parsed url auth: null, +4043 verbose parsed url host: null, +4043 verbose parsed url port: null, +4043 verbose parsed url hostname: null, +4043 verbose parsed url hash: null, +4043 verbose parsed url search: null, +4043 verbose parsed url query: null, +4043 verbose parsed url pathname: '1.2.11', +4043 verbose parsed url path: '1.2.11', +4043 verbose parsed url href: '1.2.11' } +4044 verbose addNamed [ 'mime', '1.2.11' ] +4045 verbose addNamed [ '1.2.11', '1.2.11' ] +4046 silly lockFile c4b0741f-mime-1-2-11 mime@1.2.11 +4047 verbose lock mime@1.2.11 /root/.npm/c4b0741f-mime-1-2-11.lock +4048 verbose cache add name="ms" spec="0.6.2" args=["ms","0.6.2"] +4049 verbose parsed url { protocol: null, +4049 verbose parsed url slashes: null, +4049 verbose parsed url auth: null, +4049 verbose parsed url host: null, +4049 verbose parsed url port: null, +4049 verbose parsed url hostname: null, +4049 verbose parsed url hash: null, +4049 verbose parsed url search: null, +4049 verbose parsed url query: null, +4049 verbose parsed url pathname: '0.6.2', +4049 verbose parsed url path: '0.6.2', +4049 verbose parsed url href: '0.6.2' } +4050 verbose addNamed [ 'ms', '0.6.2' ] +4051 verbose cache add name="destroy" spec="1.0.3" args=["destroy","1.0.3"] +4052 verbose parsed url { protocol: null, +4052 verbose parsed url slashes: null, +4052 verbose parsed url auth: null, +4052 verbose parsed url host: null, +4052 verbose parsed url port: null, +4052 verbose parsed url hostname: null, +4052 verbose parsed url hash: null, +4052 verbose parsed url search: null, +4052 verbose parsed url query: null, +4052 verbose parsed url pathname: '1.0.3', +4052 verbose parsed url path: '1.0.3', +4052 verbose parsed url href: '1.0.3' } +4053 verbose addNamed [ 'destroy', '1.0.3' ] +4054 verbose addNamed [ '1.0.3', '1.0.3' ] +4055 silly lockFile 0d0c6b86-destroy-1-0-3 destroy@1.0.3 +4056 verbose lock destroy@1.0.3 /root/.npm/0d0c6b86-destroy-1-0-3.lock +4057 verbose cache add name="mime-types" spec="2.0.1" args=["mime-types","2.0.1"] +4058 verbose parsed url { protocol: null, +4058 verbose parsed url slashes: null, +4058 verbose parsed url auth: null, +4058 verbose parsed url host: null, +4058 verbose parsed url port: null, +4058 verbose parsed url hostname: null, +4058 verbose parsed url hash: null, +4058 verbose parsed url search: null, +4058 verbose parsed url query: null, +4058 verbose parsed url pathname: '2.0.1', +4058 verbose parsed url path: '2.0.1', +4058 verbose parsed url href: '2.0.1' } +4059 verbose addNamed [ 'mime-types', '2.0.1' ] +4060 verbose cache add name="crc" spec="3.0.0" args=["crc","3.0.0"] +4061 verbose parsed url { protocol: null, +4061 verbose parsed url slashes: null, +4061 verbose parsed url auth: null, +4061 verbose parsed url host: null, +4061 verbose parsed url port: null, +4061 verbose parsed url hostname: null, +4061 verbose parsed url hash: null, +4061 verbose parsed url search: null, +4061 verbose parsed url query: null, +4061 verbose parsed url pathname: '3.0.0', +4061 verbose parsed url path: '3.0.0', +4061 verbose parsed url href: '3.0.0' } +4062 verbose addNamed [ 'crc', '3.0.0' ] +4063 verbose addNamed [ '3.0.0', '3.0.0' ] +4064 silly lockFile 1d1951ad-crc-3-0-0 crc@3.0.0 +4065 verbose lock crc@3.0.0 /root/.npm/1d1951ad-crc-3-0-0.lock +4066 verbose cache add name="async" spec="0.1.22" args=["async","0.1.22"] +4067 verbose parsed url { protocol: null, +4067 verbose parsed url slashes: null, +4067 verbose parsed url auth: null, +4067 verbose parsed url host: null, +4067 verbose parsed url port: null, +4067 verbose parsed url hostname: null, +4067 verbose parsed url hash: null, +4067 verbose parsed url search: null, +4067 verbose parsed url query: null, +4067 verbose parsed url pathname: '0.1.22', +4067 verbose parsed url path: '0.1.22', +4067 verbose parsed url href: '0.1.22' } +4068 verbose addNamed [ 'async', '0.1.22' ] +4069 verbose cache add name="strip-json-comments" spec="0.1.3" args=["strip-json-comments","0.1.3"] +4070 verbose parsed url { protocol: null, +4070 verbose parsed url slashes: null, +4070 verbose parsed url auth: null, +4070 verbose parsed url host: null, +4070 verbose parsed url port: null, +4070 verbose parsed url hostname: null, +4070 verbose parsed url hash: null, +4070 verbose parsed url search: null, +4070 verbose parsed url query: null, +4070 verbose parsed url pathname: '0.1.3', +4070 verbose parsed url path: '0.1.3', +4070 verbose parsed url href: '0.1.3' } +4071 verbose addNamed [ 'strip-json-comments', '0.1.3' ] +4072 verbose addNamed [ '0.1.3', '0.1.3' ] +4073 silly lockFile d41b126a-strip-json-comments-0-1-3 strip-json-comments@0.1.3 +4074 verbose lock strip-json-comments@0.1.3 /root/.npm/d41b126a-strip-json-comments-0-1-3.lock +4075 verbose cache add name="underscore" spec="1.6.0" args=["underscore","1.6.0"] +4076 verbose parsed url { protocol: null, +4076 verbose parsed url slashes: null, +4076 verbose parsed url auth: null, +4076 verbose parsed url host: null, +4076 verbose parsed url port: null, +4076 verbose parsed url hostname: null, +4076 verbose parsed url hash: null, +4076 verbose parsed url search: null, +4076 verbose parsed url query: null, +4076 verbose parsed url pathname: '1.6.0', +4076 verbose parsed url path: '1.6.0', +4076 verbose parsed url href: '1.6.0' } +4077 verbose addNamed [ 'underscore', '1.6.0' ] +4078 verbose addNamed [ '1.6.0', '1.6.0' ] +4079 silly lockFile 96960ed1-underscore-1-6-0 underscore@1.6.0 +4080 verbose lock underscore@1.6.0 /root/.npm/96960ed1-underscore-1-6-0.lock +4081 verbose cache add name="wrench" spec="1.3.9" args=["wrench","1.3.9"] +4082 verbose parsed url { protocol: null, +4082 verbose parsed url slashes: null, +4082 verbose parsed url auth: null, +4082 verbose parsed url host: null, +4082 verbose parsed url port: null, +4082 verbose parsed url hostname: null, +4082 verbose parsed url hash: null, +4082 verbose parsed url search: null, +4082 verbose parsed url query: null, +4082 verbose parsed url pathname: '1.3.9', +4082 verbose parsed url path: '1.3.9', +4082 verbose parsed url href: '1.3.9' } +4083 verbose addNamed [ 'wrench', '1.3.9' ] +4084 verbose addNamed [ '1.3.9', '1.3.9' ] +4085 silly lockFile de31968e-wrench-1-3-9 wrench@1.3.9 +4086 verbose lock wrench@1.3.9 /root/.npm/de31968e-wrench-1-3-9.lock +4087 verbose cache add name="underscore" spec="1.6.0" args=["underscore","1.6.0"] +4088 verbose parsed url { protocol: null, +4088 verbose parsed url slashes: null, +4088 verbose parsed url auth: null, +4088 verbose parsed url host: null, +4088 verbose parsed url port: null, +4088 verbose parsed url hostname: null, +4088 verbose parsed url hash: null, +4088 verbose parsed url search: null, +4088 verbose parsed url query: null, +4088 verbose parsed url pathname: '1.6.0', +4088 verbose parsed url path: '1.6.0', +4088 verbose parsed url href: '1.6.0' } +4089 verbose addNamed [ 'underscore', '1.6.0' ] +4090 verbose cache add name="underscore" spec="1.6.0" args=["underscore","1.6.0"] +4091 verbose parsed url { protocol: null, +4091 verbose parsed url slashes: null, +4091 verbose parsed url auth: null, +4091 verbose parsed url host: null, +4091 verbose parsed url port: null, +4091 verbose parsed url hostname: null, +4091 verbose parsed url hash: null, +4091 verbose parsed url search: null, +4091 verbose parsed url query: null, +4091 verbose parsed url pathname: '1.6.0', +4091 verbose parsed url path: '1.6.0', +4091 verbose parsed url href: '1.6.0' } +4092 verbose addNamed [ 'underscore', '1.6.0' ] +4093 verbose cache add name="commander" spec="2.2.0" args=["commander","2.2.0"] +4094 verbose parsed url { protocol: null, +4094 verbose parsed url slashes: null, +4094 verbose parsed url auth: null, +4094 verbose parsed url host: null, +4094 verbose parsed url port: null, +4094 verbose parsed url hostname: null, +4094 verbose parsed url hash: null, +4094 verbose parsed url search: null, +4094 verbose parsed url query: null, +4094 verbose parsed url pathname: '2.2.0', +4094 verbose parsed url path: '2.2.0', +4094 verbose parsed url href: '2.2.0' } +4095 verbose addNamed [ 'commander', '2.2.0' ] +4096 verbose addNamed [ '2.2.0', '2.2.0' ] +4097 silly lockFile a636243f-commander-2-2-0 commander@2.2.0 +4098 verbose lock commander@2.2.0 /root/.npm/a636243f-commander-2-2-0.lock +4099 verbose cache add name="glob" spec="4.0.4" args=["glob","4.0.4"] +4100 verbose parsed url { protocol: null, +4100 verbose parsed url slashes: null, +4100 verbose parsed url auth: null, +4100 verbose parsed url host: null, +4100 verbose parsed url port: null, +4100 verbose parsed url hostname: null, +4100 verbose parsed url hash: null, +4100 verbose parsed url search: null, +4100 verbose parsed url query: null, +4100 verbose parsed url pathname: '4.0.4', +4100 verbose parsed url path: '4.0.4', +4100 verbose parsed url href: '4.0.4' } +4101 verbose addNamed [ 'glob', '4.0.4' ] +4102 verbose addNamed [ '4.0.4', '4.0.4' ] +4103 silly lockFile 22281d19-glob-4-0-4 glob@4.0.4 +4104 verbose lock glob@4.0.4 /root/.npm/22281d19-glob-4-0-4.lock +4105 verbose cache add name="drawille" spec="0.1.1" args=["drawille","0.1.1"] +4106 verbose parsed url { protocol: null, +4106 verbose parsed url slashes: null, +4106 verbose parsed url auth: null, +4106 verbose parsed url host: null, +4106 verbose parsed url port: null, +4106 verbose parsed url hostname: null, +4106 verbose parsed url hash: null, +4106 verbose parsed url search: null, +4106 verbose parsed url query: null, +4106 verbose parsed url pathname: '0.1.1', +4106 verbose parsed url path: '0.1.1', +4106 verbose parsed url href: '0.1.1' } +4107 verbose addNamed [ 'drawille', '0.1.1' ] +4108 verbose addNamed [ '0.1.1', '0.1.1' ] +4109 silly lockFile 86cffdf9-drawille-0-1-1 drawille@0.1.1 +4110 verbose lock drawille@0.1.1 /root/.npm/86cffdf9-drawille-0-1-1.lock +4111 verbose cache add name="q" spec="0.9.7" args=["q","0.9.7"] +4112 verbose parsed url { protocol: null, +4112 verbose parsed url slashes: null, +4112 verbose parsed url auth: null, +4112 verbose parsed url host: null, +4112 verbose parsed url port: null, +4112 verbose parsed url hostname: null, +4112 verbose parsed url hash: null, +4112 verbose parsed url search: null, +4112 verbose parsed url query: null, +4112 verbose parsed url pathname: '0.9.7', +4112 verbose parsed url path: '0.9.7', +4112 verbose parsed url href: '0.9.7' } +4113 verbose addNamed [ 'q', '0.9.7' ] +4114 verbose addNamed [ '0.9.7', '0.9.7' ] +4115 silly lockFile cc8e51ee-q-0-9-7 q@0.9.7 +4116 verbose lock q@0.9.7 /root/.npm/cc8e51ee-q-0-9-7.lock +4117 verbose cache add name="socket.io" spec="0.9.17" args=["socket.io","0.9.17"] +4118 verbose parsed url { protocol: null, +4118 verbose parsed url slashes: null, +4118 verbose parsed url auth: null, +4118 verbose parsed url host: null, +4118 verbose parsed url port: null, +4118 verbose parsed url hostname: null, +4118 verbose parsed url hash: null, +4118 verbose parsed url search: null, +4118 verbose parsed url query: null, +4118 verbose parsed url pathname: '0.9.17', +4118 verbose parsed url path: '0.9.17', +4118 verbose parsed url href: '0.9.17' } +4119 verbose addNamed [ 'socket.io', '0.9.17' ] +4120 verbose addNamed [ '0.9.17', '0.9.17' ] +4121 silly lockFile 1593240a-socket-io-0-9-17 socket.io@0.9.17 +4122 verbose lock socket.io@0.9.17 /root/.npm/1593240a-socket-io-0-9-17.lock +4123 verbose cache add name="glob" spec="3.2.11" args=["glob","3.2.11"] +4124 verbose parsed url { protocol: null, +4124 verbose parsed url slashes: null, +4124 verbose parsed url auth: null, +4124 verbose parsed url host: null, +4124 verbose parsed url port: null, +4124 verbose parsed url hostname: null, +4124 verbose parsed url hash: null, +4124 verbose parsed url search: null, +4124 verbose parsed url query: null, +4124 verbose parsed url pathname: '3.2.11', +4124 verbose parsed url path: '3.2.11', +4124 verbose parsed url href: '3.2.11' } +4125 verbose addNamed [ 'glob', '3.2.11' ] +4126 verbose cache add name="http-proxy" spec="0.10.4" args=["http-proxy","0.10.4"] +4127 verbose parsed url { protocol: null, +4127 verbose parsed url slashes: null, +4127 verbose parsed url auth: null, +4127 verbose parsed url host: null, +4127 verbose parsed url port: null, +4127 verbose parsed url hostname: null, +4127 verbose parsed url hash: null, +4127 verbose parsed url search: null, +4127 verbose parsed url query: null, +4127 verbose parsed url pathname: '0.10.4', +4127 verbose parsed url path: '0.10.4', +4127 verbose parsed url href: '0.10.4' } +4128 verbose addNamed [ 'http-proxy', '0.10.4' ] +4129 verbose addNamed [ '0.10.4', '0.10.4' ] +4130 silly lockFile 13f0f972-http-proxy-0-10-4 http-proxy@0.10.4 +4131 verbose lock http-proxy@0.10.4 /root/.npm/13f0f972-http-proxy-0-10-4.lock +4132 verbose cache add name="graceful-fs" spec="2.0.3" args=["graceful-fs","2.0.3"] +4133 verbose parsed url { protocol: null, +4133 verbose parsed url slashes: null, +4133 verbose parsed url auth: null, +4133 verbose parsed url host: null, +4133 verbose parsed url port: null, +4133 verbose parsed url hostname: null, +4133 verbose parsed url hash: null, +4133 verbose parsed url search: null, +4133 verbose parsed url query: null, +4133 verbose parsed url pathname: '2.0.3', +4133 verbose parsed url path: '2.0.3', +4133 verbose parsed url href: '2.0.3' } +4134 verbose addNamed [ 'graceful-fs', '2.0.3' ] +4135 verbose addNamed [ '2.0.3', '2.0.3' ] +4136 silly lockFile aa717173-graceful-fs-2-0-3 graceful-fs@2.0.3 +4137 verbose lock graceful-fs@2.0.3 /root/.npm/aa717173-graceful-fs-2-0-3.lock +4138 verbose cache add name="connect" spec="2.12.0" args=["connect","2.12.0"] +4139 verbose parsed url { protocol: null, +4139 verbose parsed url slashes: null, +4139 verbose parsed url auth: null, +4139 verbose parsed url host: null, +4139 verbose parsed url port: null, +4139 verbose parsed url hostname: null, +4139 verbose parsed url hash: null, +4139 verbose parsed url search: null, +4139 verbose parsed url query: null, +4139 verbose parsed url pathname: '2.12.0', +4139 verbose parsed url path: '2.12.0', +4139 verbose parsed url href: '2.12.0' } +4140 verbose addNamed [ 'connect', '2.12.0' ] +4141 verbose addNamed [ '2.12.0', '2.12.0' ] +4142 silly lockFile a4bed1c7-connect-2-12-0 connect@2.12.0 +4143 verbose lock connect@2.12.0 /root/.npm/a4bed1c7-connect-2-12-0.lock +4144 verbose cache add name="minimatch" spec="0.2.14" args=["minimatch","0.2.14"] +4145 verbose parsed url { protocol: null, +4145 verbose parsed url slashes: null, +4145 verbose parsed url auth: null, +4145 verbose parsed url host: null, +4145 verbose parsed url port: null, +4145 verbose parsed url hostname: null, +4145 verbose parsed url hash: null, +4145 verbose parsed url search: null, +4145 verbose parsed url query: null, +4145 verbose parsed url pathname: '0.2.14', +4145 verbose parsed url path: '0.2.14', +4145 verbose parsed url href: '0.2.14' } +4146 verbose addNamed [ 'minimatch', '0.2.14' ] +4147 verbose cache add name="minimist" spec="0.0.10" args=["minimist","0.0.10"] +4148 verbose parsed url { protocol: null, +4148 verbose parsed url slashes: null, +4148 verbose parsed url auth: null, +4148 verbose parsed url host: null, +4148 verbose parsed url port: null, +4148 verbose parsed url hostname: null, +4148 verbose parsed url hash: null, +4148 verbose parsed url search: null, +4148 verbose parsed url query: null, +4148 verbose parsed url pathname: '0.0.10', +4148 verbose parsed url path: '0.0.10', +4148 verbose parsed url href: '0.0.10' } +4149 verbose addNamed [ 'minimist', '0.0.10' ] +4150 verbose addNamed [ '0.0.10', '0.0.10' ] +4151 silly lockFile 92f0553b-minimist-0-0-10 minimist@0.0.10 +4152 verbose lock minimist@0.0.10 /root/.npm/92f0553b-minimist-0-0-10.lock +4153 verbose cache add name="lru-cache" spec="2.2.4" args=["lru-cache","2.2.4"] +4154 verbose parsed url { protocol: null, +4154 verbose parsed url slashes: null, +4154 verbose parsed url auth: null, +4154 verbose parsed url host: null, +4154 verbose parsed url port: null, +4154 verbose parsed url hostname: null, +4154 verbose parsed url hash: null, +4154 verbose parsed url search: null, +4154 verbose parsed url query: null, +4154 verbose parsed url pathname: '2.2.4', +4154 verbose parsed url path: '2.2.4', +4154 verbose parsed url href: '2.2.4' } +4155 verbose addNamed [ 'lru-cache', '2.2.4' ] +4156 verbose addNamed [ '2.2.4', '2.2.4' ] +4157 silly lockFile 6ce37bbe-lru-cache-2-2-4 lru-cache@2.2.4 +4158 verbose lock lru-cache@2.2.4 /root/.npm/6ce37bbe-lru-cache-2-2-4.lock +4159 verbose cache add name="recursive-readdir" spec="0.0.2" args=["recursive-readdir","0.0.2"] +4160 verbose parsed url { protocol: null, +4160 verbose parsed url slashes: null, +4160 verbose parsed url auth: null, +4160 verbose parsed url host: null, +4160 verbose parsed url port: null, +4160 verbose parsed url hostname: null, +4160 verbose parsed url hash: null, +4160 verbose parsed url search: null, +4160 verbose parsed url query: null, +4160 verbose parsed url pathname: '0.0.2', +4160 verbose parsed url path: '0.0.2', +4160 verbose parsed url href: '0.0.2' } +4161 verbose addNamed [ 'recursive-readdir', '0.0.2' ] +4162 verbose addNamed [ '0.0.2', '0.0.2' ] +4163 silly lockFile 3e7dd281-recursive-readdir-0-0-2 recursive-readdir@0.0.2 +4164 verbose lock recursive-readdir@0.0.2 /root/.npm/3e7dd281-recursive-readdir-0-0-2.lock +4165 verbose cache add name="async" spec="0.2.10" args=["async","0.2.10"] +4166 verbose parsed url { protocol: null, +4166 verbose parsed url slashes: null, +4166 verbose parsed url auth: null, +4166 verbose parsed url host: null, +4166 verbose parsed url port: null, +4166 verbose parsed url hostname: null, +4166 verbose parsed url hash: null, +4166 verbose parsed url search: null, +4166 verbose parsed url query: null, +4166 verbose parsed url pathname: '0.2.10', +4166 verbose parsed url path: '0.2.10', +4166 verbose parsed url href: '0.2.10' } +4167 verbose addNamed [ 'async', '0.2.10' ] +4168 verbose addNamed [ '0.2.10', '0.2.10' ] +4169 silly lockFile 098b530d-async-0-2-10 async@0.2.10 +4170 verbose lock async@0.2.10 /root/.npm/098b530d-async-0-2-10.lock +4171 verbose cache add name="semver" spec="1.1.4" args=["semver","1.1.4"] +4172 verbose parsed url { protocol: null, +4172 verbose parsed url slashes: null, +4172 verbose parsed url auth: null, +4172 verbose parsed url host: null, +4172 verbose parsed url port: null, +4172 verbose parsed url hostname: null, +4172 verbose parsed url hash: null, +4172 verbose parsed url search: null, +4172 verbose parsed url query: null, +4172 verbose parsed url pathname: '1.1.4', +4172 verbose parsed url path: '1.1.4', +4172 verbose parsed url href: '1.1.4' } +4173 verbose addNamed [ 'semver', '1.1.4' ] +4174 verbose addNamed [ '1.1.4', '1.1.4' ] +4175 silly lockFile da52979e-semver-1-1-4 semver@1.1.4 +4176 verbose lock semver@1.1.4 /root/.npm/da52979e-semver-1-1-4.lock +4177 verbose cache add name="minimatch" spec="0.3.0" args=["minimatch","0.3.0"] +4178 verbose parsed url { protocol: null, +4178 verbose parsed url slashes: null, +4178 verbose parsed url auth: null, +4178 verbose parsed url host: null, +4178 verbose parsed url port: null, +4178 verbose parsed url hostname: null, +4178 verbose parsed url hash: null, +4178 verbose parsed url search: null, +4178 verbose parsed url query: null, +4178 verbose parsed url pathname: '0.3.0', +4178 verbose parsed url path: '0.3.0', +4178 verbose parsed url href: '0.3.0' } +4179 verbose addNamed [ 'minimatch', '0.3.0' ] +4180 verbose addNamed [ '0.3.0', '0.3.0' ] +4181 silly lockFile fbcfe8c1-minimatch-0-3-0 minimatch@0.3.0 +4182 verbose lock minimatch@0.3.0 /root/.npm/fbcfe8c1-minimatch-0-3-0.lock +4183 verbose cache add name="resolve" spec="0.7.4" args=["resolve","0.7.4"] +4184 verbose parsed url { protocol: null, +4184 verbose parsed url slashes: null, +4184 verbose parsed url auth: null, +4184 verbose parsed url host: null, +4184 verbose parsed url port: null, +4184 verbose parsed url hostname: null, +4184 verbose parsed url hash: null, +4184 verbose parsed url search: null, +4184 verbose parsed url query: null, +4184 verbose parsed url pathname: '0.7.4', +4184 verbose parsed url path: '0.7.4', +4184 verbose parsed url href: '0.7.4' } +4185 verbose addNamed [ 'resolve', '0.7.4' ] +4186 verbose addNamed [ '0.7.4', '0.7.4' ] +4187 silly lockFile e599e352-resolve-0-7-4 resolve@0.7.4 +4188 verbose lock resolve@0.7.4 /root/.npm/e599e352-resolve-0-7-4.lock +4189 verbose cache add name="minimist" spec="0.0.8" args=["minimist","0.0.8"] +4190 verbose parsed url { protocol: null, +4190 verbose parsed url slashes: null, +4190 verbose parsed url auth: null, +4190 verbose parsed url host: null, +4190 verbose parsed url port: null, +4190 verbose parsed url hostname: null, +4190 verbose parsed url hash: null, +4190 verbose parsed url search: null, +4190 verbose parsed url query: null, +4190 verbose parsed url pathname: '0.0.8', +4190 verbose parsed url path: '0.0.8', +4190 verbose parsed url href: '0.0.8' } +4191 verbose addNamed [ 'minimist', '0.0.8' ] +4192 verbose cache add name="escodegen" spec="1.3.3" args=["escodegen","1.3.3"] +4193 verbose parsed url { protocol: null, +4193 verbose parsed url slashes: null, +4193 verbose parsed url auth: null, +4193 verbose parsed url host: null, +4193 verbose parsed url port: null, +4193 verbose parsed url hostname: null, +4193 verbose parsed url hash: null, +4193 verbose parsed url search: null, +4193 verbose parsed url query: null, +4193 verbose parsed url pathname: '1.3.3', +4193 verbose parsed url path: '1.3.3', +4193 verbose parsed url href: '1.3.3' } +4194 verbose addNamed [ 'escodegen', '1.3.3' ] +4195 verbose addNamed [ '1.3.3', '1.3.3' ] +4196 silly lockFile 9d8bcdba-escodegen-1-3-3 escodegen@1.3.3 +4197 verbose lock escodegen@1.3.3 /root/.npm/9d8bcdba-escodegen-1-3-3.lock +4198 verbose cache add name="handlebars" spec="1.3.0" args=["handlebars","1.3.0"] +4199 verbose parsed url { protocol: null, +4199 verbose parsed url slashes: null, +4199 verbose parsed url auth: null, +4199 verbose parsed url host: null, +4199 verbose parsed url port: null, +4199 verbose parsed url hostname: null, +4199 verbose parsed url hash: null, +4199 verbose parsed url search: null, +4199 verbose parsed url query: null, +4199 verbose parsed url pathname: '1.3.0', +4199 verbose parsed url path: '1.3.0', +4199 verbose parsed url href: '1.3.0' } +4200 verbose addNamed [ 'handlebars', '1.3.0' ] +4201 verbose addNamed [ '1.3.0', '1.3.0' ] +4202 silly lockFile 15405714-handlebars-1-3-0 handlebars@1.3.0 +4203 verbose lock handlebars@1.3.0 /root/.npm/15405714-handlebars-1-3-0.lock +4204 verbose cache add name="minimatch" spec="0.4.0" args=["minimatch","0.4.0"] +4205 verbose parsed url { protocol: null, +4205 verbose parsed url slashes: null, +4205 verbose parsed url auth: null, +4205 verbose parsed url host: null, +4205 verbose parsed url port: null, +4205 verbose parsed url hostname: null, +4205 verbose parsed url hash: null, +4205 verbose parsed url search: null, +4205 verbose parsed url query: null, +4205 verbose parsed url pathname: '0.4.0', +4205 verbose parsed url path: '0.4.0', +4205 verbose parsed url href: '0.4.0' } +4206 verbose addNamed [ 'minimatch', '0.4.0' ] +4207 verbose addNamed [ '0.4.0', '0.4.0' ] +4208 silly lockFile adb3bdcf-minimatch-0-4-0 minimatch@0.4.0 +4209 verbose lock minimatch@0.4.0 /root/.npm/adb3bdcf-minimatch-0-4-0.lock +4210 verbose cache add name="glob" spec="3.2.11" args=["glob","3.2.11"] +4211 verbose parsed url { protocol: null, +4211 verbose parsed url slashes: null, +4211 verbose parsed url auth: null, +4211 verbose parsed url host: null, +4211 verbose parsed url port: null, +4211 verbose parsed url hostname: null, +4211 verbose parsed url hash: null, +4211 verbose parsed url search: null, +4211 verbose parsed url query: null, +4211 verbose parsed url pathname: '3.2.11', +4211 verbose parsed url path: '3.2.11', +4211 verbose parsed url href: '3.2.11' } +4212 verbose addNamed [ 'glob', '3.2.11' ] +4213 verbose cache add name="esprima" spec="1.0.4" args=["esprima","1.0.4"] +4214 verbose parsed url { protocol: null, +4214 verbose parsed url slashes: null, +4214 verbose parsed url auth: null, +4214 verbose parsed url host: null, +4214 verbose parsed url port: null, +4214 verbose parsed url hostname: null, +4214 verbose parsed url hash: null, +4214 verbose parsed url search: null, +4214 verbose parsed url query: null, +4214 verbose parsed url pathname: '1.0.4', +4214 verbose parsed url path: '1.0.4', +4214 verbose parsed url href: '1.0.4' } +4215 verbose addNamed [ 'esprima', '1.0.4' ] +4216 verbose addNamed [ '1.0.4', '1.0.4' ] +4217 silly lockFile 758953aa-esprima-1-0-4 esprima@1.0.4 +4218 verbose lock esprima@1.0.4 /root/.npm/758953aa-esprima-1-0-4.lock +4219 verbose cache add name="underscore" spec="1.4.4" args=["underscore","1.4.4"] +4220 verbose parsed url { protocol: null, +4220 verbose parsed url slashes: null, +4220 verbose parsed url auth: null, +4220 verbose parsed url host: null, +4220 verbose parsed url port: null, +4220 verbose parsed url hostname: null, +4220 verbose parsed url hash: null, +4220 verbose parsed url search: null, +4220 verbose parsed url query: null, +4220 verbose parsed url pathname: '1.4.4', +4220 verbose parsed url path: '1.4.4', +4220 verbose parsed url href: '1.4.4' } +4221 verbose addNamed [ 'underscore', '1.4.4' ] +4222 verbose addNamed [ '1.4.4', '1.4.4' ] +4223 silly lockFile c6b5e825-underscore-1-4-4 underscore@1.4.4 +4224 verbose lock underscore@1.4.4 /root/.npm/c6b5e825-underscore-1-4-4.lock +4225 verbose cache add name="istanbul" spec="0.2.16" args=["istanbul","0.2.16"] +4226 verbose parsed url { protocol: null, +4226 verbose parsed url slashes: null, +4226 verbose parsed url auth: null, +4226 verbose parsed url host: null, +4226 verbose parsed url port: null, +4226 verbose parsed url hostname: null, +4226 verbose parsed url hash: null, +4226 verbose parsed url search: null, +4226 verbose parsed url query: null, +4226 verbose parsed url pathname: '0.2.16', +4226 verbose parsed url path: '0.2.16', +4226 verbose parsed url href: '0.2.16' } +4227 verbose addNamed [ 'istanbul', '0.2.16' ] +4228 verbose addNamed [ '0.2.16', '0.2.16' ] +4229 silly lockFile c70bb1b6-istanbul-0-2-16 istanbul@0.2.16 +4230 verbose lock istanbul@0.2.16 /root/.npm/c70bb1b6-istanbul-0-2-16.lock +4231 verbose cache add name="mkdirp" spec="0.3.5" args=["mkdirp","0.3.5"] +4232 verbose parsed url { protocol: null, +4232 verbose parsed url slashes: null, +4232 verbose parsed url auth: null, +4232 verbose parsed url host: null, +4232 verbose parsed url port: null, +4232 verbose parsed url hostname: null, +4232 verbose parsed url hash: null, +4232 verbose parsed url search: null, +4232 verbose parsed url query: null, +4232 verbose parsed url pathname: '0.3.5', +4232 verbose parsed url path: '0.3.5', +4232 verbose parsed url href: '0.3.5' } +4233 verbose addNamed [ 'mkdirp', '0.3.5' ] +4234 verbose addNamed [ '0.3.5', '0.3.5' ] +4235 silly lockFile 67d2df2a-mkdirp-0-3-5 mkdirp@0.3.5 +4236 verbose lock mkdirp@0.3.5 /root/.npm/67d2df2a-mkdirp-0-3-5.lock +4237 verbose cache add name="escodegen" spec="1.1.0" args=["escodegen","1.1.0"] +4238 verbose parsed url { protocol: null, +4238 verbose parsed url slashes: null, +4238 verbose parsed url auth: null, +4238 verbose parsed url host: null, +4238 verbose parsed url port: null, +4238 verbose parsed url hostname: null, +4238 verbose parsed url hash: null, +4238 verbose parsed url search: null, +4238 verbose parsed url query: null, +4238 verbose parsed url pathname: '1.1.0', +4238 verbose parsed url path: '1.1.0', +4238 verbose parsed url href: '1.1.0' } +4239 verbose addNamed [ 'escodegen', '1.1.0' ] +4240 verbose addNamed [ '1.1.0', '1.1.0' ] +4241 silly lockFile 48f7949f-escodegen-1-1-0 escodegen@1.1.0 +4242 verbose lock escodegen@1.1.0 /root/.npm/48f7949f-escodegen-1-1-0.lock +4243 verbose cache add name="minimist" spec="0.0.10" args=["minimist","0.0.10"] +4244 verbose parsed url { protocol: null, +4244 verbose parsed url slashes: null, +4244 verbose parsed url auth: null, +4244 verbose parsed url host: null, +4244 verbose parsed url port: null, +4244 verbose parsed url hostname: null, +4244 verbose parsed url hash: null, +4244 verbose parsed url search: null, +4244 verbose parsed url query: null, +4244 verbose parsed url pathname: '0.0.10', +4244 verbose parsed url path: '0.0.10', +4244 verbose parsed url href: '0.0.10' } +4245 verbose addNamed [ 'minimist', '0.0.10' ] +4246 verbose cache add name="nopt" spec="2.1.2" args=["nopt","2.1.2"] +4247 verbose parsed url { protocol: null, +4247 verbose parsed url slashes: null, +4247 verbose parsed url auth: null, +4247 verbose parsed url host: null, +4247 verbose parsed url port: null, +4247 verbose parsed url hostname: null, +4247 verbose parsed url hash: null, +4247 verbose parsed url search: null, +4247 verbose parsed url query: null, +4247 verbose parsed url pathname: '2.1.2', +4247 verbose parsed url path: '2.1.2', +4247 verbose parsed url href: '2.1.2' } +4248 verbose addNamed [ 'nopt', '2.1.2' ] +4249 verbose addNamed [ '2.1.2', '2.1.2' ] +4250 silly lockFile 7d0298b9-nopt-2-1-2 nopt@2.1.2 +4251 verbose lock nopt@2.1.2 /root/.npm/7d0298b9-nopt-2-1-2.lock +4252 verbose cache add name="source-map" spec="0.1.11" args=["source-map","0.1.11"] +4253 verbose parsed url { protocol: null, +4253 verbose parsed url slashes: null, +4253 verbose parsed url auth: null, +4253 verbose parsed url host: null, +4253 verbose parsed url port: null, +4253 verbose parsed url hostname: null, +4253 verbose parsed url hash: null, +4253 verbose parsed url search: null, +4253 verbose parsed url query: null, +4253 verbose parsed url pathname: '0.1.11', +4253 verbose parsed url path: '0.1.11', +4253 verbose parsed url href: '0.1.11' } +4254 verbose addNamed [ 'source-map', '0.1.11' ] +4255 verbose addNamed [ '0.1.11', '0.1.11' ] +4256 silly lockFile 7c6aa561-source-map-0-1-11 source-map@0.1.11 +4257 verbose lock source-map@0.1.11 /root/.npm/7c6aa561-source-map-0-1-11.lock +4258 verbose cache add name="escodegen" spec="0.0.28" args=["escodegen","0.0.28"] +4259 verbose parsed url { protocol: null, +4259 verbose parsed url slashes: null, +4259 verbose parsed url auth: null, +4259 verbose parsed url host: null, +4259 verbose parsed url port: null, +4259 verbose parsed url hostname: null, +4259 verbose parsed url hash: null, +4259 verbose parsed url search: null, +4259 verbose parsed url query: null, +4259 verbose parsed url pathname: '0.0.28', +4259 verbose parsed url path: '0.0.28', +4259 verbose parsed url href: '0.0.28' } +4260 verbose addNamed [ 'escodegen', '0.0.28' ] +4261 verbose addNamed [ '0.0.28', '0.0.28' ] +4262 silly lockFile cb311dc7-escodegen-0-0-28 escodegen@0.0.28 +4263 verbose lock escodegen@0.0.28 /root/.npm/cb311dc7-escodegen-0-0-28.lock +4264 verbose cache add name="esmangle" spec="0.0.17" args=["esmangle","0.0.17"] +4265 verbose parsed url { protocol: null, +4265 verbose parsed url slashes: null, +4265 verbose parsed url auth: null, +4265 verbose parsed url host: null, +4265 verbose parsed url port: null, +4265 verbose parsed url hostname: null, +4265 verbose parsed url hash: null, +4265 verbose parsed url search: null, +4265 verbose parsed url query: null, +4265 verbose parsed url pathname: '0.0.17', +4265 verbose parsed url path: '0.0.17', +4265 verbose parsed url href: '0.0.17' } +4266 verbose addNamed [ 'esmangle', '0.0.17' ] +4267 verbose addNamed [ '0.0.17', '0.0.17' ] +4268 silly lockFile e0072ae1-esmangle-0-0-17 esmangle@0.0.17 +4269 verbose lock esmangle@0.0.17 /root/.npm/e0072ae1-esmangle-0-0-17.lock +4270 verbose cache add name="request" spec="2.42.0" args=["request","2.42.0"] +4271 verbose parsed url { protocol: null, +4271 verbose parsed url slashes: null, +4271 verbose parsed url auth: null, +4271 verbose parsed url host: null, +4271 verbose parsed url port: null, +4271 verbose parsed url hostname: null, +4271 verbose parsed url hash: null, +4271 verbose parsed url search: null, +4271 verbose parsed url query: null, +4271 verbose parsed url pathname: '2.42.0', +4271 verbose parsed url path: '2.42.0', +4271 verbose parsed url href: '2.42.0' } +4272 verbose addNamed [ 'request', '2.42.0' ] +4273 verbose addNamed [ '2.42.0', '2.42.0' ] +4274 silly lockFile 6619e4b4-request-2-42-0 request@2.42.0 +4275 verbose lock request@2.42.0 /root/.npm/6619e4b4-request-2-42-0.lock +4276 verbose cache add name="minimist" spec="0.0.8" args=["minimist","0.0.8"] +4277 verbose parsed url { protocol: null, +4277 verbose parsed url slashes: null, +4277 verbose parsed url auth: null, +4277 verbose parsed url host: null, +4277 verbose parsed url port: null, +4277 verbose parsed url hostname: null, +4277 verbose parsed url hash: null, +4277 verbose parsed url search: null, +4277 verbose parsed url query: null, +4277 verbose parsed url pathname: '0.0.8', +4277 verbose parsed url path: '0.0.8', +4277 verbose parsed url href: '0.0.8' } +4278 verbose addNamed [ 'minimist', '0.0.8' ] +4279 verbose cache add name="semver" spec="4.0.0" args=["semver","4.0.0"] +4280 verbose parsed url { protocol: null, +4280 verbose parsed url slashes: null, +4280 verbose parsed url auth: null, +4280 verbose parsed url host: null, +4280 verbose parsed url port: null, +4280 verbose parsed url hostname: null, +4280 verbose parsed url hash: null, +4280 verbose parsed url search: null, +4280 verbose parsed url query: null, +4280 verbose parsed url pathname: '4.0.0', +4280 verbose parsed url path: '4.0.0', +4280 verbose parsed url href: '4.0.0' } +4281 verbose addNamed [ 'semver', '4.0.0' ] +4282 verbose addNamed [ '4.0.0', '4.0.0' ] +4283 silly lockFile a0d6450f-semver-4-0-0 semver@4.0.0 +4284 verbose lock semver@4.0.0 /root/.npm/a0d6450f-semver-4-0-0.lock +4285 verbose cache add name="nopt" spec="2.2.1" args=["nopt","2.2.1"] +4286 verbose parsed url { protocol: null, +4286 verbose parsed url slashes: null, +4286 verbose parsed url auth: null, +4286 verbose parsed url host: null, +4286 verbose parsed url port: null, +4286 verbose parsed url hostname: null, +4286 verbose parsed url hash: null, +4286 verbose parsed url search: null, +4286 verbose parsed url query: null, +4286 verbose parsed url pathname: '2.2.1', +4286 verbose parsed url path: '2.2.1', +4286 verbose parsed url href: '2.2.1' } +4287 verbose addNamed [ 'nopt', '2.2.1' ] +4288 verbose addNamed [ '2.2.1', '2.2.1' ] +4289 silly lockFile d02d193f-nopt-2-2-1 nopt@2.2.1 +4290 verbose lock nopt@2.2.1 /root/.npm/d02d193f-nopt-2-2-1.lock +4291 verbose cache add name="deep-equal" spec="0.0.0" args=["deep-equal","0.0.0"] +4292 verbose parsed url { protocol: null, +4292 verbose parsed url slashes: null, +4292 verbose parsed url auth: null, +4292 verbose parsed url host: null, +4292 verbose parsed url port: null, +4292 verbose parsed url hostname: null, +4292 verbose parsed url hash: null, +4292 verbose parsed url search: null, +4292 verbose parsed url query: null, +4292 verbose parsed url pathname: '0.0.0', +4292 verbose parsed url path: '0.0.0', +4292 verbose parsed url href: '0.0.0' } +4293 verbose addNamed [ 'deep-equal', '0.0.0' ] +4294 verbose addNamed [ '0.0.0', '0.0.0' ] +4295 silly lockFile 52f78ead-deep-equal-0-0-0 deep-equal@0.0.0 +4296 verbose lock deep-equal@0.0.0 /root/.npm/52f78ead-deep-equal-0-0-0.lock +4297 verbose cache add name="glob" spec="3.2.11" args=["glob","3.2.11"] +4298 verbose parsed url { protocol: null, +4298 verbose parsed url slashes: null, +4298 verbose parsed url auth: null, +4298 verbose parsed url host: null, +4298 verbose parsed url port: null, +4298 verbose parsed url hostname: null, +4298 verbose parsed url hash: null, +4298 verbose parsed url search: null, +4298 verbose parsed url query: null, +4298 verbose parsed url pathname: '3.2.11', +4298 verbose parsed url path: '3.2.11', +4298 verbose parsed url href: '3.2.11' } +4299 verbose addNamed [ 'glob', '3.2.11' ] +4300 verbose cache add name="minimist" spec="0.0.8" args=["minimist","0.0.8"] +4301 verbose parsed url { protocol: null, +4301 verbose parsed url slashes: null, +4301 verbose parsed url auth: null, +4301 verbose parsed url host: null, +4301 verbose parsed url port: null, +4301 verbose parsed url hostname: null, +4301 verbose parsed url hash: null, +4301 verbose parsed url search: null, +4301 verbose parsed url query: null, +4301 verbose parsed url pathname: '0.0.8', +4301 verbose parsed url path: '0.0.8', +4301 verbose parsed url href: '0.0.8' } +4302 verbose addNamed [ 'minimist', '0.0.8' ] +4303 verbose cache add name="charm" spec="0.1.2" args=["charm","0.1.2"] +4304 verbose parsed url { protocol: null, +4304 verbose parsed url slashes: null, +4304 verbose parsed url auth: null, +4304 verbose parsed url host: null, +4304 verbose parsed url port: null, +4304 verbose parsed url hostname: null, +4304 verbose parsed url hash: null, +4304 verbose parsed url search: null, +4304 verbose parsed url query: null, +4304 verbose parsed url pathname: '0.1.2', +4304 verbose parsed url path: '0.1.2', +4304 verbose parsed url href: '0.1.2' } +4305 verbose addNamed [ 'charm', '0.1.2' ] +4306 verbose addNamed [ '0.1.2', '0.1.2' ] +4307 silly lockFile e47f86f3-charm-0-1-2 charm@0.1.2 +4308 verbose lock charm@0.1.2 /root/.npm/e47f86f3-charm-0-1-2.lock +4309 verbose cache add name="traverse" spec="0.5.2" args=["traverse","0.5.2"] +4310 verbose parsed url { protocol: null, +4310 verbose parsed url slashes: null, +4310 verbose parsed url auth: null, +4310 verbose parsed url host: null, +4310 verbose parsed url port: null, +4310 verbose parsed url hostname: null, +4310 verbose parsed url hash: null, +4310 verbose parsed url search: null, +4310 verbose parsed url query: null, +4310 verbose parsed url pathname: '0.5.2', +4310 verbose parsed url path: '0.5.2', +4310 verbose parsed url href: '0.5.2' } +4311 verbose addNamed [ 'traverse', '0.5.2' ] +4312 verbose addNamed [ '0.5.2', '0.5.2' ] +4313 silly lockFile a0b87686-traverse-0-5-2 traverse@0.5.2 +4314 verbose lock traverse@0.5.2 /root/.npm/a0b87686-traverse-0-5-2.lock +4315 verbose cache add name="uglify-js" spec="1.1.1" args=["uglify-js","1.1.1"] +4316 verbose parsed url { protocol: null, +4316 verbose parsed url slashes: null, +4316 verbose parsed url auth: null, +4316 verbose parsed url host: null, +4316 verbose parsed url port: null, +4316 verbose parsed url hostname: null, +4316 verbose parsed url hash: null, +4316 verbose parsed url search: null, +4316 verbose parsed url query: null, +4316 verbose parsed url pathname: '1.1.1', +4316 verbose parsed url path: '1.1.1', +4316 verbose parsed url href: '1.1.1' } +4317 verbose addNamed [ 'uglify-js', '1.1.1' ] +4318 verbose addNamed [ '1.1.1', '1.1.1' ] +4319 silly lockFile 4bf6c84f-uglify-js-1-1-1 uglify-js@1.1.1 +4320 verbose lock uglify-js@1.1.1 /root/.npm/4bf6c84f-uglify-js-1-1-1.lock +4321 verbose cache add name="rework-custom-media" spec="0.1.1" args=["rework-custom-media","0.1.1"] +4322 verbose parsed url { protocol: null, +4322 verbose parsed url slashes: null, +4322 verbose parsed url auth: null, +4322 verbose parsed url host: null, +4322 verbose parsed url port: null, +4322 verbose parsed url hostname: null, +4322 verbose parsed url hash: null, +4322 verbose parsed url search: null, +4322 verbose parsed url query: null, +4322 verbose parsed url pathname: '0.1.1', +4322 verbose parsed url path: '0.1.1', +4322 verbose parsed url href: '0.1.1' } +4323 verbose addNamed [ 'rework-custom-media', '0.1.1' ] +4324 verbose addNamed [ '0.1.1', '0.1.1' ] +4325 silly lockFile 9dff7d80-rework-custom-media-0-1-1 rework-custom-media@0.1.1 +4326 verbose lock rework-custom-media@0.1.1 /root/.npm/9dff7d80-rework-custom-media-0-1-1.lock +4327 verbose cache add name="to-space-case" spec="0.1.2" args=["to-space-case","0.1.2"] +4328 verbose parsed url { protocol: null, +4328 verbose parsed url slashes: null, +4328 verbose parsed url auth: null, +4328 verbose parsed url host: null, +4328 verbose parsed url port: null, +4328 verbose parsed url hostname: null, +4328 verbose parsed url hash: null, +4328 verbose parsed url search: null, +4328 verbose parsed url query: null, +4328 verbose parsed url pathname: '0.1.2', +4328 verbose parsed url path: '0.1.2', +4328 verbose parsed url href: '0.1.2' } +4329 verbose addNamed [ 'to-space-case', '0.1.2' ] +4330 verbose addNamed [ '0.1.2', '0.1.2' ] +4331 silly lockFile fd9831a9-to-space-case-0-1-2 to-space-case@0.1.2 +4332 verbose lock to-space-case@0.1.2 /root/.npm/fd9831a9-to-space-case-0-1-2.lock +4333 verbose cache add name="stream-to-array" spec="1.0.0" args=["stream-to-array","1.0.0"] +4334 verbose parsed url { protocol: null, +4334 verbose parsed url slashes: null, +4334 verbose parsed url auth: null, +4334 verbose parsed url host: null, +4334 verbose parsed url port: null, +4334 verbose parsed url hostname: null, +4334 verbose parsed url hash: null, +4334 verbose parsed url search: null, +4334 verbose parsed url query: null, +4334 verbose parsed url pathname: '1.0.0', +4334 verbose parsed url path: '1.0.0', +4334 verbose parsed url href: '1.0.0' } +4335 verbose addNamed [ 'stream-to-array', '1.0.0' ] +4336 verbose addNamed [ '1.0.0', '1.0.0' ] +4337 silly lockFile fdcdc98e-stream-to-array-1-0-0 stream-to-array@1.0.0 +4338 verbose lock stream-to-array@1.0.0 /root/.npm/fdcdc98e-stream-to-array-1-0-0.lock +4339 verbose cache add name="rgb" spec="0.0.1" args=["rgb","0.0.1"] +4340 verbose parsed url { protocol: null, +4340 verbose parsed url slashes: null, +4340 verbose parsed url auth: null, +4340 verbose parsed url host: null, +4340 verbose parsed url port: null, +4340 verbose parsed url hostname: null, +4340 verbose parsed url hash: null, +4340 verbose parsed url search: null, +4340 verbose parsed url query: null, +4340 verbose parsed url pathname: '0.0.1', +4340 verbose parsed url path: '0.0.1', +4340 verbose parsed url href: '0.0.1' } +4341 verbose addNamed [ 'rgb', '0.0.1' ] +4342 verbose addNamed [ '0.0.1', '0.0.1' ] +4343 silly lockFile 64191658-rgb-0-0-1 rgb@0.0.1 +4344 verbose lock rgb@0.0.1 /root/.npm/64191658-rgb-0-0-1.lock +4345 verbose cache add name="convert-source-map" spec="0.3.5" args=["convert-source-map","0.3.5"] +4346 verbose parsed url { protocol: null, +4346 verbose parsed url slashes: null, +4346 verbose parsed url auth: null, +4346 verbose parsed url host: null, +4346 verbose parsed url port: null, +4346 verbose parsed url hostname: null, +4346 verbose parsed url hash: null, +4346 verbose parsed url search: null, +4346 verbose parsed url query: null, +4346 verbose parsed url pathname: '0.3.5', +4346 verbose parsed url path: '0.3.5', +4346 verbose parsed url href: '0.3.5' } +4347 verbose addNamed [ 'convert-source-map', '0.3.5' ] +4348 verbose addNamed [ '0.3.5', '0.3.5' ] +4349 silly lockFile 7da22f37-convert-source-map-0-3-5 convert-source-map@0.3.5 +4350 verbose lock convert-source-map@0.3.5 /root/.npm/7da22f37-convert-source-map-0-3-5.lock +4351 verbose cache add name="parse-import" spec="0.1.3" args=["parse-import","0.1.3"] +4352 verbose parsed url { protocol: null, +4352 verbose parsed url slashes: null, +4352 verbose parsed url auth: null, +4352 verbose parsed url host: null, +4352 verbose parsed url port: null, +4352 verbose parsed url hostname: null, +4352 verbose parsed url hash: null, +4352 verbose parsed url search: null, +4352 verbose parsed url query: null, +4352 verbose parsed url pathname: '0.1.3', +4352 verbose parsed url path: '0.1.3', +4352 verbose parsed url href: '0.1.3' } +4353 verbose addNamed [ 'parse-import', '0.1.3' ] +4354 verbose addNamed [ '0.1.3', '0.1.3' ] +4355 silly lockFile 2dc056ef-parse-import-0-1-3 parse-import@0.1.3 +4356 verbose lock parse-import@0.1.3 /root/.npm/2dc056ef-parse-import-0-1-3.lock +4357 verbose cache add name="find-file" spec="0.1.4" args=["find-file","0.1.4"] +4358 verbose parsed url { protocol: null, +4358 verbose parsed url slashes: null, +4358 verbose parsed url auth: null, +4358 verbose parsed url host: null, +4358 verbose parsed url port: null, +4358 verbose parsed url hostname: null, +4358 verbose parsed url hash: null, +4358 verbose parsed url search: null, +4358 verbose parsed url query: null, +4358 verbose parsed url pathname: '0.1.4', +4358 verbose parsed url path: '0.1.4', +4358 verbose parsed url href: '0.1.4' } +4359 verbose addNamed [ 'find-file', '0.1.4' ] +4360 verbose addNamed [ '0.1.4', '0.1.4' ] +4361 silly lockFile f940690f-find-file-0-1-4 find-file@0.1.4 +4362 verbose lock find-file@0.1.4 /root/.npm/f940690f-find-file-0-1-4.lock +4363 verbose cache add name="balanced-match" spec="0.0.0" args=["balanced-match","0.0.0"] +4364 verbose parsed url { protocol: null, +4364 verbose parsed url slashes: null, +4364 verbose parsed url auth: null, +4364 verbose parsed url host: null, +4364 verbose parsed url port: null, +4364 verbose parsed url hostname: null, +4364 verbose parsed url hash: null, +4364 verbose parsed url search: null, +4364 verbose parsed url query: null, +4364 verbose parsed url pathname: '0.0.0', +4364 verbose parsed url path: '0.0.0', +4364 verbose parsed url href: '0.0.0' } +4365 verbose addNamed [ 'balanced-match', '0.0.0' ] +4366 verbose addNamed [ '0.0.0', '0.0.0' ] +4367 silly lockFile 1c616673-balanced-match-0-0-0 balanced-match@0.0.0 +4368 verbose lock balanced-match@0.0.0 /root/.npm/1c616673-balanced-match-0-0-0.lock +4369 verbose cache add name="debug" spec="0.7.4" args=["debug","0.7.4"] +4370 verbose parsed url { protocol: null, +4370 verbose parsed url slashes: null, +4370 verbose parsed url auth: null, +4370 verbose parsed url host: null, +4370 verbose parsed url port: null, +4370 verbose parsed url hostname: null, +4370 verbose parsed url hash: null, +4370 verbose parsed url search: null, +4370 verbose parsed url query: null, +4370 verbose parsed url pathname: '0.7.4', +4370 verbose parsed url path: '0.7.4', +4370 verbose parsed url href: '0.7.4' } +4371 verbose addNamed [ 'debug', '0.7.4' ] +4372 verbose addNamed [ '0.7.4', '0.7.4' ] +4373 silly lockFile 16160008-debug-0-7-4 debug@0.7.4 +4374 verbose lock debug@0.7.4 /root/.npm/16160008-debug-0-7-4.lock +4375 verbose addRemoteTarball [ 'https://github.com/hegemonic/taffydb/tarball/master', null ] +4376 verbose addRemoteTarball [ 'https://github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c', +4376 verbose addRemoteTarball null ] +4377 verbose addRemoteGit [ 'https://github.com/pipobscure/fsevents', +4377 verbose addRemoteGit '7dcdf9fa3f8956610fd6f69f72c67bace2de7138' ] +4378 verbose addRemoteGit [ 'git://github.com/michaelficarra/cscodegen.git', +4378 verbose addRemoteGit '73fd7202ac086c26f18c9d56f025b18b3c6f5383' ] +4379 verbose cache add [ 'npm@1.4.27', null ] +4380 verbose cache add name=undefined spec="npm@1.4.27" args=["npm@1.4.27",null] +4381 verbose parsed url { protocol: null, +4381 verbose parsed url slashes: null, +4381 verbose parsed url auth: null, +4381 verbose parsed url host: null, +4381 verbose parsed url port: null, +4381 verbose parsed url hostname: null, +4381 verbose parsed url hash: null, +4381 verbose parsed url search: null, +4381 verbose parsed url query: null, +4381 verbose parsed url pathname: 'npm@1.4.27', +4381 verbose parsed url path: 'npm@1.4.27', +4381 verbose parsed url href: 'npm@1.4.27' } +4382 verbose cache add name="npm" spec="1.4.27" args=["npm","1.4.27"] +4383 verbose parsed url { protocol: null, +4383 verbose parsed url slashes: null, +4383 verbose parsed url auth: null, +4383 verbose parsed url host: null, +4383 verbose parsed url port: null, +4383 verbose parsed url hostname: null, +4383 verbose parsed url hash: null, +4383 verbose parsed url search: null, +4383 verbose parsed url query: null, +4383 verbose parsed url pathname: '1.4.27', +4383 verbose parsed url path: '1.4.27', +4383 verbose parsed url href: '1.4.27' } +4384 verbose addNamed [ 'npm', '1.4.27' ] +4385 verbose addNamed [ '1.4.27', '1.4.27' ] +4386 silly lockFile 894182a5-npm-1-4-27 npm@1.4.27 +4387 verbose lock npm@1.4.27 /root/.npm/894182a5-npm-1-4-27.lock +4388 info retry fetch attempt 1 at 15:14:33 +4389 verbose fetch to= /tmp/npm-17670-yMiqFMg9/github.com/hegemonic/taffydb/tarball/master +4390 info retry fetch attempt 1 at 15:14:33 +4391 verbose fetch to= /tmp/npm-17670-yMiqFMg9/github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c +4392 http GET https://github.com/hegemonic/taffydb/tarball/master +4393 http GET https://github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c +4394 verbose registry.get https://registry.npmjs.org/coffee-script not expired, no request +4395 verbose registry.get https://registry.npmjs.org/commander not expired, no request +4396 verbose registry.get https://registry.npmjs.org/minimist not expired, no request +4397 verbose registry.get https://registry.npmjs.org/nopt not expired, no request +4398 verbose registry.get https://registry.npmjs.org/resolve not expired, no request +4399 verbose registry.get https://registry.npmjs.org/glob not expired, no request +4400 verbose registry.get https://registry.npmjs.org/eventsource not expired, no request +4401 verbose registry.get https://registry.npmjs.org/html5 not expired, no request +4402 verbose registry.get https://registry.npmjs.org/q not expired, no request +4403 verbose registry.get https://registry.npmjs.org/encoding not expired, no request +4404 verbose registry.get https://registry.npmjs.org/ws not expired, no request +4405 verbose registry.get https://registry.npmjs.org/dateformat not expired, no request +4406 verbose registry.get https://registry.npmjs.org/glob not expired, no request +4407 verbose registry.get https://registry.npmjs.org/lodash not expired, no request +4408 verbose registry.get https://registry.npmjs.org/underscore.string not expired, no request +4409 verbose registry.get https://registry.npmjs.org/iconv-lite not expired, no request +4410 verbose registry.get https://registry.npmjs.org/coffee-script not expired, no request +4411 verbose registry.get https://registry.npmjs.org/jsdom not expired, no request +4412 verbose registry.get https://registry.npmjs.org/minimatch not expired, no request +4413 verbose registry.get https://registry.npmjs.org/js-yaml not expired, no request +4414 verbose registry.get https://registry.npmjs.org/depd not expired, no request +4415 verbose registry.get https://registry.npmjs.org/finalhandler not expired, no request +4416 verbose registry.get https://registry.npmjs.org/async not expired, no request +4417 verbose registry.get https://registry.npmjs.org/ms not expired, no request +4418 verbose registry.get https://registry.npmjs.org/path-to-regexp not expired, no request +4419 verbose registry.get https://registry.npmjs.org/mime-types not expired, no request +4420 verbose registry.get https://registry.npmjs.org/destroy not expired, no request +4421 verbose registry.get https://registry.npmjs.org/strip-json-comments not expired, no request +4422 verbose registry.get https://registry.npmjs.org/underscore not expired, no request +4423 verbose registry.get https://registry.npmjs.org/wrench not expired, no request +4424 verbose registry.get https://registry.npmjs.org/mime not expired, no request +4425 verbose registry.get https://registry.npmjs.org/request not expired, no request +4426 verbose registry.get https://registry.npmjs.org/commander not expired, no request +4427 verbose registry.get https://registry.npmjs.org/glob not expired, no request +4428 verbose registry.get https://registry.npmjs.org/drawille not expired, no request +4429 verbose registry.get https://registry.npmjs.org/q not expired, no request +4430 verbose registry.get https://registry.npmjs.org/graceful-fs not expired, no request +4431 verbose registry.get https://registry.npmjs.org/http-proxy not expired, no request +4432 verbose registry.get https://registry.npmjs.org/socket.io not expired, no request +4433 verbose registry.get https://registry.npmjs.org/minimist not expired, no request +4434 verbose registry.get https://registry.npmjs.org/lru-cache not expired, no request +4435 verbose registry.get https://registry.npmjs.org/connect not expired, no request +4436 verbose registry.get https://registry.npmjs.org/recursive-readdir not expired, no request +4437 verbose registry.get https://registry.npmjs.org/semver not expired, no request +4438 verbose registry.get https://registry.npmjs.org/minimatch not expired, no request +4439 verbose registry.get https://registry.npmjs.org/escodegen not expired, no request +4440 verbose registry.get https://registry.npmjs.org/handlebars not expired, no request +4441 verbose registry.get https://registry.npmjs.org/minimatch not expired, no request +4442 verbose registry.get https://registry.npmjs.org/resolve not expired, no request +4443 verbose registry.get https://registry.npmjs.org/esprima not expired, no request +4444 verbose registry.get https://registry.npmjs.org/async not expired, no request +4445 verbose registry.get https://registry.npmjs.org/underscore not expired, no request +4446 verbose registry.get https://registry.npmjs.org/mkdirp not expired, no request +4447 verbose registry.get https://registry.npmjs.org/escodegen not expired, no request +4448 verbose registry.get https://registry.npmjs.org/istanbul not expired, no request +4449 verbose registry.get https://registry.npmjs.org/nopt not expired, no request +4450 verbose registry.get https://registry.npmjs.org/source-map not expired, no request +4451 verbose registry.get https://registry.npmjs.org/escodegen not expired, no request +4452 verbose registry.get https://registry.npmjs.org/esmangle not expired, no request +4453 verbose registry.get https://registry.npmjs.org/semver not expired, no request +4454 verbose registry.get https://registry.npmjs.org/nopt not expired, no request +4455 verbose registry.get https://registry.npmjs.org/deep-equal not expired, no request +4456 verbose registry.get https://registry.npmjs.org/request not expired, no request +4457 verbose registry.get https://registry.npmjs.org/charm not expired, no request +4458 verbose registry.get https://registry.npmjs.org/traverse not expired, no request +4459 verbose registry.get https://registry.npmjs.org/rework-custom-media not expired, no request +4460 verbose registry.get https://registry.npmjs.org/uglify-js not expired, no request +4461 verbose registry.get https://registry.npmjs.org/to-space-case not expired, no request +4462 verbose registry.get https://registry.npmjs.org/stream-to-array not expired, no request +4463 verbose registry.get https://registry.npmjs.org/rgb not expired, no request +4464 verbose registry.get https://registry.npmjs.org/convert-source-map not expired, no request +4465 verbose registry.get https://registry.npmjs.org/parse-import not expired, no request +4466 verbose registry.get https://registry.npmjs.org/find-file not expired, no request +4467 verbose registry.get https://registry.npmjs.org/balanced-match not expired, no request +4468 verbose registry.get https://registry.npmjs.org/debug not expired, no request +4469 verbose git remote.origin.url https://github.com/pipobscure/fsevents +4470 verbose git remote.origin.url git://github.com/michaelficarra/cscodegen.git +4471 verbose registry.get https://registry.npmjs.org/npm not expired, no request +4472 silly lockFile 66cb63a1-coffee-script-1-7-1 coffee-script@1.7.1 +4473 silly lockFile 66cb63a1-coffee-script-1-7-1 coffee-script@1.7.1 +4474 silly lockFile 2016e061-commander-1-3-2 commander@1.3.2 +4475 silly lockFile 2016e061-commander-1-3-2 commander@1.3.2 +4476 silly lockFile 22c6b485-minimist-0-0-8 minimist@0.0.8 +4477 silly lockFile 22c6b485-minimist-0-0-8 minimist@0.0.8 +4478 silly lockFile 1be903a1-nopt-1-0-10 nopt@1.0.10 +4479 silly lockFile 1be903a1-nopt-1-0-10 nopt@1.0.10 +4480 silly lockFile 95464470-resolve-0-3-1 resolve@0.3.1 +4481 silly lockFile 95464470-resolve-0-3-1 resolve@0.3.1 +4482 silly lockFile 3fffafa6-glob-3-2-11 glob@3.2.11 +4483 silly lockFile 3fffafa6-glob-3-2-11 glob@3.2.11 +4484 silly lockFile 9b39a648-eventsource-0-0-10 eventsource@0.0.10 +4485 silly lockFile 9b39a648-eventsource-0-0-10 eventsource@0.0.10 +4486 silly lockFile cf52c898-html5-0-3-14 html5@0.3.14 +4487 silly lockFile cf52c898-html5-0-3-14 html5@0.3.14 +4488 silly lockFile 4a267efb-q-1-0-0 q@1.0.0 +4489 silly lockFile 4a267efb-q-1-0-0 q@1.0.0 +4490 silly lockFile 28678d21-encoding-0-1-7 encoding@0.1.7 +4491 silly lockFile 28678d21-encoding-0-1-7 encoding@0.1.7 +4492 silly lockFile 53e67403-ws-0-4-31 ws@0.4.31 +4493 silly lockFile 53e67403-ws-0-4-31 ws@0.4.31 +4494 silly lockFile 644d6e27-dateformat-1-0-2-1-2-3 dateformat@1.0.2-1.2.3 +4495 silly lockFile 644d6e27-dateformat-1-0-2-1-2-3 dateformat@1.0.2-1.2.3 +4496 silly lockFile ab465912-glob-3-1-21 glob@3.1.21 +4497 silly lockFile ab465912-glob-3-1-21 glob@3.1.21 +4498 silly lockFile 9802d919-lodash-0-9-2 lodash@0.9.2 +4499 silly lockFile 9802d919-lodash-0-9-2 lodash@0.9.2 +4500 silly lockFile 5c083954-underscore-string-2-2-1 underscore.string@2.2.1 +4501 silly lockFile 5c083954-underscore-string-2-2-1 underscore.string@2.2.1 +4502 silly lockFile 5d877021-iconv-lite-0-2-11 iconv-lite@0.2.11 +4503 silly lockFile 5d877021-iconv-lite-0-2-11 iconv-lite@0.2.11 +4504 silly lockFile 022c8436-coffee-script-1-3-3 coffee-script@1.3.3 +4505 silly lockFile 022c8436-coffee-script-1-3-3 coffee-script@1.3.3 +4506 silly lockFile 8d7847b7-jsdom-0-8-11 jsdom@0.8.11 +4507 silly lockFile 8d7847b7-jsdom-0-8-11 jsdom@0.8.11 +4508 silly lockFile a72880d0-minimatch-0-2-14 minimatch@0.2.14 +4509 silly lockFile a72880d0-minimatch-0-2-14 minimatch@0.2.14 +4510 silly lockFile 0aecb717-js-yaml-2-0-5 js-yaml@2.0.5 +4511 silly lockFile 0aecb717-js-yaml-2-0-5 js-yaml@2.0.5 +4512 silly lockFile 19d47453-depd-0-4-5 depd@0.4.5 +4513 silly lockFile 19d47453-depd-0-4-5 depd@0.4.5 +4514 silly lockFile c64219b3-finalhandler-0-2-0 finalhandler@0.2.0 +4515 silly lockFile c64219b3-finalhandler-0-2-0 finalhandler@0.2.0 +4516 silly lockFile 09d21715-async-0-1-22 async@0.1.22 +4517 silly lockFile 09d21715-async-0-1-22 async@0.1.22 +4518 silly lockFile e50af523-path-to-regexp-0-1-3 path-to-regexp@0.1.3 +4519 silly lockFile e50af523-path-to-regexp-0-1-3 path-to-regexp@0.1.3 +4520 silly lockFile 64a74d75-mime-types-2-0-1 mime-types@2.0.1 +4521 silly lockFile 64a74d75-mime-types-2-0-1 mime-types@2.0.1 +4522 verbose registry.get https://registry.npmjs.org/ee-first not expired, no request +4523 silly lockFile d41b126a-strip-json-comments-0-1-3 strip-json-comments@0.1.3 +4524 silly lockFile d41b126a-strip-json-comments-0-1-3 strip-json-comments@0.1.3 +4525 verbose registry.get https://registry.npmjs.org/ipaddr.js not expired, no request +4526 silly lockFile 96960ed1-underscore-1-6-0 underscore@1.6.0 +4527 silly lockFile 96960ed1-underscore-1-6-0 underscore@1.6.0 +4528 silly lockFile de31968e-wrench-1-3-9 wrench@1.3.9 +4529 silly lockFile de31968e-wrench-1-3-9 wrench@1.3.9 +4530 silly lockFile c4b0741f-mime-1-2-11 mime@1.2.11 +4531 silly lockFile c4b0741f-mime-1-2-11 mime@1.2.11 +4532 silly lockFile a8edf972-request-2-34-0 request@2.34.0 +4533 silly lockFile a8edf972-request-2-34-0 request@2.34.0 +4534 verbose registry.get https://registry.npmjs.org/negotiator not expired, no request +4535 verbose registry.get https://registry.npmjs.org/crc not expired, no request +4536 silly lockFile a636243f-commander-2-2-0 commander@2.2.0 +4537 silly lockFile a636243f-commander-2-2-0 commander@2.2.0 +4538 silly lockFile 22281d19-glob-4-0-4 glob@4.0.4 +4539 silly lockFile 22281d19-glob-4-0-4 glob@4.0.4 +4540 silly lockFile 86cffdf9-drawille-0-1-1 drawille@0.1.1 +4541 silly lockFile 86cffdf9-drawille-0-1-1 drawille@0.1.1 +4542 silly lockFile aa717173-graceful-fs-2-0-3 graceful-fs@2.0.3 +4543 silly lockFile aa717173-graceful-fs-2-0-3 graceful-fs@2.0.3 +4544 silly lockFile cc8e51ee-q-0-9-7 q@0.9.7 +4545 silly lockFile cc8e51ee-q-0-9-7 q@0.9.7 +4546 silly lockFile 13f0f972-http-proxy-0-10-4 http-proxy@0.10.4 +4547 silly lockFile 13f0f972-http-proxy-0-10-4 http-proxy@0.10.4 +4548 silly lockFile 1593240a-socket-io-0-9-17 socket.io@0.9.17 +4549 silly lockFile 1593240a-socket-io-0-9-17 socket.io@0.9.17 +4550 silly lockFile 92f0553b-minimist-0-0-10 minimist@0.0.10 +4551 silly lockFile 92f0553b-minimist-0-0-10 minimist@0.0.10 +4552 silly lockFile 6ce37bbe-lru-cache-2-2-4 lru-cache@2.2.4 +4553 silly lockFile 6ce37bbe-lru-cache-2-2-4 lru-cache@2.2.4 +4554 silly lockFile a4bed1c7-connect-2-12-0 connect@2.12.0 +4555 silly lockFile a4bed1c7-connect-2-12-0 connect@2.12.0 +4556 silly lockFile 3e7dd281-recursive-readdir-0-0-2 recursive-readdir@0.0.2 +4557 silly lockFile 3e7dd281-recursive-readdir-0-0-2 recursive-readdir@0.0.2 +4558 silly lockFile da52979e-semver-1-1-4 semver@1.1.4 +4559 silly lockFile da52979e-semver-1-1-4 semver@1.1.4 +4560 silly lockFile fbcfe8c1-minimatch-0-3-0 minimatch@0.3.0 +4561 silly lockFile fbcfe8c1-minimatch-0-3-0 minimatch@0.3.0 +4562 silly lockFile 9d8bcdba-escodegen-1-3-3 escodegen@1.3.3 +4563 silly lockFile 9d8bcdba-escodegen-1-3-3 escodegen@1.3.3 +4564 silly lockFile 15405714-handlebars-1-3-0 handlebars@1.3.0 +4565 silly lockFile 15405714-handlebars-1-3-0 handlebars@1.3.0 +4566 silly lockFile adb3bdcf-minimatch-0-4-0 minimatch@0.4.0 +4567 silly lockFile adb3bdcf-minimatch-0-4-0 minimatch@0.4.0 +4568 silly lockFile e599e352-resolve-0-7-4 resolve@0.7.4 +4569 silly lockFile e599e352-resolve-0-7-4 resolve@0.7.4 +4570 silly lockFile 758953aa-esprima-1-0-4 esprima@1.0.4 +4571 silly lockFile 758953aa-esprima-1-0-4 esprima@1.0.4 +4572 silly lockFile 098b530d-async-0-2-10 async@0.2.10 +4573 silly lockFile 098b530d-async-0-2-10 async@0.2.10 +4574 silly lockFile c6b5e825-underscore-1-4-4 underscore@1.4.4 +4575 silly lockFile c6b5e825-underscore-1-4-4 underscore@1.4.4 +4576 silly lockFile 67d2df2a-mkdirp-0-3-5 mkdirp@0.3.5 +4577 silly lockFile 67d2df2a-mkdirp-0-3-5 mkdirp@0.3.5 +4578 silly lockFile 48f7949f-escodegen-1-1-0 escodegen@1.1.0 +4579 silly lockFile 48f7949f-escodegen-1-1-0 escodegen@1.1.0 +4580 silly lockFile c70bb1b6-istanbul-0-2-16 istanbul@0.2.16 +4581 silly lockFile c70bb1b6-istanbul-0-2-16 istanbul@0.2.16 +4582 silly lockFile 7d0298b9-nopt-2-1-2 nopt@2.1.2 +4583 silly lockFile 7d0298b9-nopt-2-1-2 nopt@2.1.2 +4584 silly lockFile 7c6aa561-source-map-0-1-11 source-map@0.1.11 +4585 silly lockFile 7c6aa561-source-map-0-1-11 source-map@0.1.11 +4586 silly lockFile cb311dc7-escodegen-0-0-28 escodegen@0.0.28 +4587 silly lockFile cb311dc7-escodegen-0-0-28 escodegen@0.0.28 +4588 silly lockFile e0072ae1-esmangle-0-0-17 esmangle@0.0.17 +4589 silly lockFile e0072ae1-esmangle-0-0-17 esmangle@0.0.17 +4590 silly lockFile a0d6450f-semver-4-0-0 semver@4.0.0 +4591 silly lockFile a0d6450f-semver-4-0-0 semver@4.0.0 +4592 silly lockFile d02d193f-nopt-2-2-1 nopt@2.2.1 +4593 silly lockFile d02d193f-nopt-2-2-1 nopt@2.2.1 +4594 silly lockFile 52f78ead-deep-equal-0-0-0 deep-equal@0.0.0 +4595 silly lockFile 52f78ead-deep-equal-0-0-0 deep-equal@0.0.0 +4596 silly lockFile 6619e4b4-request-2-42-0 request@2.42.0 +4597 silly lockFile 6619e4b4-request-2-42-0 request@2.42.0 +4598 silly lockFile e47f86f3-charm-0-1-2 charm@0.1.2 +4599 silly lockFile e47f86f3-charm-0-1-2 charm@0.1.2 +4600 silly lockFile a0b87686-traverse-0-5-2 traverse@0.5.2 +4601 silly lockFile a0b87686-traverse-0-5-2 traverse@0.5.2 +4602 silly lockFile 9dff7d80-rework-custom-media-0-1-1 rework-custom-media@0.1.1 +4603 silly lockFile 9dff7d80-rework-custom-media-0-1-1 rework-custom-media@0.1.1 +4604 silly lockFile 4bf6c84f-uglify-js-1-1-1 uglify-js@1.1.1 +4605 silly lockFile 4bf6c84f-uglify-js-1-1-1 uglify-js@1.1.1 +4606 silly lockFile fd9831a9-to-space-case-0-1-2 to-space-case@0.1.2 +4607 silly lockFile fd9831a9-to-space-case-0-1-2 to-space-case@0.1.2 +4608 silly lockFile fdcdc98e-stream-to-array-1-0-0 stream-to-array@1.0.0 +4609 silly lockFile fdcdc98e-stream-to-array-1-0-0 stream-to-array@1.0.0 +4610 silly lockFile 64191658-rgb-0-0-1 rgb@0.0.1 +4611 silly lockFile 64191658-rgb-0-0-1 rgb@0.0.1 +4612 silly lockFile 7da22f37-convert-source-map-0-3-5 convert-source-map@0.3.5 +4613 silly lockFile 7da22f37-convert-source-map-0-3-5 convert-source-map@0.3.5 +4614 silly lockFile 2dc056ef-parse-import-0-1-3 parse-import@0.1.3 +4615 silly lockFile 2dc056ef-parse-import-0-1-3 parse-import@0.1.3 +4616 silly lockFile f940690f-find-file-0-1-4 find-file@0.1.4 +4617 silly lockFile f940690f-find-file-0-1-4 find-file@0.1.4 +4618 silly lockFile 1c616673-balanced-match-0-0-0 balanced-match@0.0.0 +4619 silly lockFile 1c616673-balanced-match-0-0-0 balanced-match@0.0.0 +4620 silly lockFile 16160008-debug-0-7-4 debug@0.7.4 +4621 silly lockFile 16160008-debug-0-7-4 debug@0.7.4 +4622 verbose git fetch -a origin (git://github.com/michaelficarra/cscodegen.git) +4623 silly lockFile 894182a5-npm-1-4-27 npm@1.4.27 +4624 silly lockFile 894182a5-npm-1-4-27 npm@1.4.27 +4625 silly lockFile 549cc243-ms-0-6-2 ms@0.6.2 +4626 silly lockFile 549cc243-ms-0-6-2 ms@0.6.2 +4627 silly lockFile 0d0c6b86-destroy-1-0-3 destroy@1.0.3 +4628 silly lockFile 0d0c6b86-destroy-1-0-3 destroy@1.0.3 +4629 silly lockFile 574e94a4-negotiator-0-4-7 negotiator@0.4.7 +4630 silly lockFile 574e94a4-negotiator-0-4-7 negotiator@0.4.7 +4631 silly lockFile 086e076d-rg-ipaddr-js-ipaddr-js-0-1-3-tgz https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-0.1.3.tgz +4632 verbose lock https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-0.1.3.tgz /root/.npm/086e076d-rg-ipaddr-js-ipaddr-js-0-1-3-tgz.lock +4633 verbose git fetch -a origin (https://github.com/pipobscure/fsevents) +4634 verbose addRemoteTarball [ 'https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-0.1.3.tgz', +4634 verbose addRemoteTarball '27a9ca37f148d2102b0ef191ccbf2c51a8f025c6' ] +4635 silly resolved [ { name: 'coffee-script', +4635 silly resolved description: 'Unfancy JavaScript', +4635 silly resolved keywords: [ 'javascript', 'language', 'coffeescript', 'compiler' ], +4635 silly resolved author: { name: 'Jeremy Ashkenas' }, +4635 silly resolved version: '1.7.1', +4635 silly resolved license: 'MIT', +4635 silly resolved engines: { node: '>=0.8.0' }, +4635 silly resolved directories: { lib: './lib/coffee-script' }, +4635 silly resolved main: './lib/coffee-script/coffee-script', +4635 silly resolved bin: { coffee: './bin/coffee', cake: './bin/cake' }, +4635 silly resolved scripts: { test: 'node ./bin/cake test' }, +4635 silly resolved homepage: 'http://coffeescript.org', +4635 silly resolved bugs: { url: 'https://github.com/jashkenas/coffee-script/issues' }, +4635 silly resolved repository: +4635 silly resolved { type: 'git', +4635 silly resolved url: 'git://github.com/jashkenas/coffee-script.git' }, +4635 silly resolved devDependencies: +4635 silly resolved { 'uglify-js': '~2.2', +4635 silly resolved jison: '>=0.2.0', +4635 silly resolved 'highlight.js': '~8.0.0', +4635 silly resolved underscore: '~1.5.2' }, +4635 silly resolved dependencies: { mkdirp: '~0.3.5' }, +4635 silly resolved _id: 'coffee-script@1.7.1', +4635 silly resolved dist: +4635 silly resolved { shasum: '62996a861780c75e6d5069d13822723b73404bfc', +4635 silly resolved tarball: 'http://registry.npmjs.org/coffee-script/-/coffee-script-1.7.1.tgz' }, +4635 silly resolved _from: 'coffee-script@1.7.1', +4635 silly resolved _npmVersion: '1.3.24', +4635 silly resolved _npmUser: { name: 'michaelficarra', email: 'npm@michael.ficarra.me' }, +4635 silly resolved maintainers: [ [Object] ], +4635 silly resolved _shasum: '62996a861780c75e6d5069d13822723b73404bfc', +4635 silly resolved _resolved: 'https://registry.npmjs.org/coffee-script/-/coffee-script-1.7.1.tgz', +4635 silly resolved readme: 'ERROR: No README data found!' } ] +4636 info install coffee-script@1.7.1 into /usr/lib/node_modules/karma-coffee-preprocessor +4637 info installOne coffee-script@1.7.1 +4638 http 200 https://github.com/hegemonic/taffydb/tarball/master +4639 silly resolved [ { name: 'commander', +4639 silly resolved version: '1.3.2', +4639 silly resolved description: 'the complete solution for node.js command-line programs', +4639 silly resolved keywords: [ 'command', 'option', 'parser', 'prompt', 'stdin' ], +4639 silly resolved author: { name: 'TJ Holowaychuk', email: 'tj@vision-media.ca' }, +4639 silly resolved repository: +4639 silly resolved { type: 'git', +4639 silly resolved url: 'https://github.com/visionmedia/commander.js.git' }, +4639 silly resolved dependencies: { keypress: '0.1.x' }, +4639 silly resolved devDependencies: { should: '>= 0.0.1' }, +4639 silly resolved scripts: { test: 'make test' }, +4639 silly resolved main: 'index', +4639 silly resolved engines: { node: '>= 0.6.x' }, +4639 silly resolved bugs: { url: 'https://github.com/visionmedia/commander.js/issues' }, +4639 silly resolved _id: 'commander@1.3.2', +4639 silly resolved dist: +4639 silly resolved { shasum: '8a8f30ec670a6fdd64af52f1914b907d79ead5b5', +4639 silly resolved tarball: 'http://registry.npmjs.org/commander/-/commander-1.3.2.tgz' }, +4639 silly resolved _from: 'commander@1.3.2', +4639 silly resolved _npmVersion: '1.2.30', +4639 silly resolved _npmUser: { name: 'tjholowaychuk', email: 'tj@vision-media.ca' }, +4639 silly resolved maintainers: [ [Object] ], +4639 silly resolved directories: {}, +4639 silly resolved _shasum: '8a8f30ec670a6fdd64af52f1914b907d79ead5b5', +4639 silly resolved _resolved: 'https://registry.npmjs.org/commander/-/commander-1.3.2.tgz', +4639 silly resolved readme: 'ERROR: No README data found!', +4639 silly resolved homepage: 'https://github.com/visionmedia/commander.js' } ] +4640 info install commander@1.3.2 into /usr/lib/node_modules/express-generator +4641 info installOne commander@1.3.2 +4642 http 200 https://github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c +4643 silly resolved [ { name: 'minimist', +4643 silly resolved version: '0.0.8', +4643 silly resolved description: 'parse argument options', +4643 silly resolved main: 'index.js', +4643 silly resolved devDependencies: { tape: '~1.0.4', tap: '~0.4.0' }, +4643 silly resolved scripts: { test: 'tap test/*.js' }, +4643 silly resolved testling: { files: 'test/*.js', browsers: [Object] }, +4643 silly resolved repository: { type: 'git', url: 'git://github.com/substack/minimist.git' }, +4643 silly resolved homepage: 'https://github.com/substack/minimist', +4643 silly resolved keywords: [ 'argv', 'getopt', 'parser', 'optimist' ], +4643 silly resolved author: +4643 silly resolved { name: 'James Halliday', +4643 silly resolved email: 'mail@substack.net', +4643 silly resolved url: 'http://substack.net' }, +4643 silly resolved license: 'MIT', +4643 silly resolved bugs: { url: 'https://github.com/substack/minimist/issues' }, +4643 silly resolved _id: 'minimist@0.0.8', +4643 silly resolved dist: +4643 silly resolved { shasum: '857fcabfc3397d2625b8228262e86aa7a011b05d', +4643 silly resolved tarball: 'http://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz' }, +4643 silly resolved _from: 'minimist@0.0.8', +4643 silly resolved _npmVersion: '1.4.3', +4643 silly resolved _npmUser: { name: 'substack', email: 'mail@substack.net' }, +4643 silly resolved maintainers: [ [Object] ], +4643 silly resolved directories: {}, +4643 silly resolved _shasum: '857fcabfc3397d2625b8228262e86aa7a011b05d', +4643 silly resolved _resolved: 'https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz', +4643 silly resolved readme: 'ERROR: No README data found!' } ] +4644 info install minimist@0.0.8 into /usr/lib/node_modules/express-generator/node_modules/mkdirp +4645 info installOne minimist@0.0.8 +4646 silly resolved [ { name: 'minimist', +4646 silly resolved version: '0.0.8', +4646 silly resolved description: 'parse argument options', +4646 silly resolved main: 'index.js', +4646 silly resolved devDependencies: { tape: '~1.0.4', tap: '~0.4.0' }, +4646 silly resolved scripts: { test: 'tap test/*.js' }, +4646 silly resolved testling: { files: 'test/*.js', browsers: [Object] }, +4646 silly resolved repository: { type: 'git', url: 'git://github.com/substack/minimist.git' }, +4646 silly resolved homepage: 'https://github.com/substack/minimist', +4646 silly resolved keywords: [ 'argv', 'getopt', 'parser', 'optimist' ], +4646 silly resolved author: +4646 silly resolved { name: 'James Halliday', +4646 silly resolved email: 'mail@substack.net', +4646 silly resolved url: 'http://substack.net' }, +4646 silly resolved license: 'MIT', +4646 silly resolved bugs: { url: 'https://github.com/substack/minimist/issues' }, +4646 silly resolved _id: 'minimist@0.0.8', +4646 silly resolved dist: +4646 silly resolved { shasum: '857fcabfc3397d2625b8228262e86aa7a011b05d', +4646 silly resolved tarball: 'http://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz' }, +4646 silly resolved _from: 'minimist@0.0.8', +4646 silly resolved _npmVersion: '1.4.3', +4646 silly resolved _npmUser: { name: 'substack', email: 'mail@substack.net' }, +4646 silly resolved maintainers: [ [Object] ], +4646 silly resolved directories: {}, +4646 silly resolved _shasum: '857fcabfc3397d2625b8228262e86aa7a011b05d', +4646 silly resolved _resolved: 'https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz', +4646 silly resolved readme: 'ERROR: No README data found!' } ] +4647 info install minimist@0.0.8 into /usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/mkdirp +4648 info installOne minimist@0.0.8 +4649 silly resolved [ { name: 'minimist', +4649 silly resolved version: '0.0.8', +4649 silly resolved description: 'parse argument options', +4649 silly resolved main: 'index.js', +4649 silly resolved devDependencies: { tape: '~1.0.4', tap: '~0.4.0' }, +4649 silly resolved scripts: { test: 'tap test/*.js' }, +4649 silly resolved testling: { files: 'test/*.js', browsers: [Object] }, +4649 silly resolved repository: { type: 'git', url: 'git://github.com/substack/minimist.git' }, +4649 silly resolved homepage: 'https://github.com/substack/minimist', +4649 silly resolved keywords: [ 'argv', 'getopt', 'parser', 'optimist' ], +4649 silly resolved author: +4649 silly resolved { name: 'James Halliday', +4649 silly resolved email: 'mail@substack.net', +4649 silly resolved url: 'http://substack.net' }, +4649 silly resolved license: 'MIT', +4649 silly resolved bugs: { url: 'https://github.com/substack/minimist/issues' }, +4649 silly resolved _id: 'minimist@0.0.8', +4649 silly resolved dist: +4649 silly resolved { shasum: '857fcabfc3397d2625b8228262e86aa7a011b05d', +4649 silly resolved tarball: 'http://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz' }, +4649 silly resolved _from: 'minimist@0.0.8', +4649 silly resolved _npmVersion: '1.4.3', +4649 silly resolved _npmUser: { name: 'substack', email: 'mail@substack.net' }, +4649 silly resolved maintainers: [ [Object] ], +4649 silly resolved directories: {}, +4649 silly resolved _shasum: '857fcabfc3397d2625b8228262e86aa7a011b05d', +4649 silly resolved _resolved: 'https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz', +4649 silly resolved readme: 'ERROR: No README data found!' } ] +4650 info install minimist@0.0.8 into /usr/lib/node_modules/karma-phantomjs-launcher/node_modules/phantomjs/node_modules/mkdirp +4651 info installOne minimist@0.0.8 +4652 silly resolved [ { name: 'minimist', +4652 silly resolved version: '0.0.8', +4652 silly resolved description: 'parse argument options', +4652 silly resolved main: 'index.js', +4652 silly resolved devDependencies: { tape: '~1.0.4', tap: '~0.4.0' }, +4652 silly resolved scripts: { test: 'tap test/*.js' }, +4652 silly resolved testling: { files: 'test/*.js', browsers: [Object] }, +4652 silly resolved repository: { type: 'git', url: 'git://github.com/substack/minimist.git' }, +4652 silly resolved homepage: 'https://github.com/substack/minimist', +4652 silly resolved keywords: [ 'argv', 'getopt', 'parser', 'optimist' ], +4652 silly resolved author: +4652 silly resolved { name: 'James Halliday', +4652 silly resolved email: 'mail@substack.net', +4652 silly resolved url: 'http://substack.net' }, +4652 silly resolved license: 'MIT', +4652 silly resolved bugs: { url: 'https://github.com/substack/minimist/issues' }, +4652 silly resolved _id: 'minimist@0.0.8', +4652 silly resolved dist: +4652 silly resolved { shasum: '857fcabfc3397d2625b8228262e86aa7a011b05d', +4652 silly resolved tarball: 'http://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz' }, +4652 silly resolved _from: 'minimist@0.0.8', +4652 silly resolved _npmVersion: '1.4.3', +4652 silly resolved _npmUser: { name: 'substack', email: 'mail@substack.net' }, +4652 silly resolved maintainers: [ [Object] ], +4652 silly resolved directories: {}, +4652 silly resolved _shasum: '857fcabfc3397d2625b8228262e86aa7a011b05d', +4652 silly resolved _resolved: 'https://registry.npmjs.org/minimist/-/minimist-0.0.8.tgz', +4652 silly resolved readme: 'ERROR: No README data found!' } ] +4653 info install minimist@0.0.8 into /usr/lib/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp +4654 info installOne minimist@0.0.8 +4655 silly resolved [ { author: +4655 silly resolved { name: 'Isaac Z. Schlueter', +4655 silly resolved email: 'i@izs.me', +4655 silly resolved url: 'http://blog.izs.me/' }, +4655 silly resolved name: 'glob', +4655 silly resolved description: 'a little globber', +4655 silly resolved version: '3.2.11', +4655 silly resolved repository: { type: 'git', url: 'git://github.com/isaacs/node-glob.git' }, +4655 silly resolved main: 'glob.js', +4655 silly resolved engines: { node: '*' }, +4655 silly resolved dependencies: { inherits: '2', minimatch: '0.3' }, +4655 silly resolved devDependencies: { tap: '~0.4.0', mkdirp: '0', rimraf: '1' }, +4655 silly resolved scripts: +4655 silly resolved { test: 'tap test/*.js', +4655 silly resolved 'test-regen': 'TEST_REGEN=1 node test/00-setup.js' }, +4655 silly resolved license: 'BSD', +4655 silly resolved gitHead: '73f57e99510582b2024b762305970ebcf9b70aa2', +4655 silly resolved bugs: { url: 'https://github.com/isaacs/node-glob/issues' }, +4655 silly resolved homepage: 'https://github.com/isaacs/node-glob', +4655 silly resolved _id: 'glob@3.2.11', +4655 silly resolved _shasum: '4a973f635b9190f715d10987d5c00fd2815ebe3d', +4655 silly resolved _from: 'glob@3.2.11', +4655 silly resolved _npmVersion: '1.4.10', +4655 silly resolved _npmUser: { name: 'isaacs', email: 'i@izs.me' }, +4655 silly resolved maintainers: [ [Object] ], +4655 silly resolved dist: +4655 silly resolved { shasum: '4a973f635b9190f715d10987d5c00fd2815ebe3d', +4655 silly resolved tarball: 'http://registry.npmjs.org/glob/-/glob-3.2.11.tgz' }, +4655 silly resolved directories: {}, +4655 silly resolved _resolved: 'https://registry.npmjs.org/glob/-/glob-3.2.11.tgz', +4655 silly resolved readme: 'ERROR: No README data found!' } ] +4656 info install glob@3.2.11 into /usr/lib/node_modules/grunt-cli/node_modules/findup-sync +4657 info installOne glob@3.2.11 +4658 silly resolved [ { author: +4658 silly resolved { name: 'Isaac Z. Schlueter', +4658 silly resolved email: 'i@izs.me', +4658 silly resolved url: 'http://blog.izs.me/' }, +4658 silly resolved name: 'glob', +4658 silly resolved description: 'a little globber', +4658 silly resolved version: '3.2.11', +4658 silly resolved repository: { type: 'git', url: 'git://github.com/isaacs/node-glob.git' }, +4658 silly resolved main: 'glob.js', +4658 silly resolved engines: { node: '*' }, +4658 silly resolved dependencies: { inherits: '2', minimatch: '0.3' }, +4658 silly resolved devDependencies: { tap: '~0.4.0', mkdirp: '0', rimraf: '1' }, +4658 silly resolved scripts: +4658 silly resolved { test: 'tap test/*.js', +4658 silly resolved 'test-regen': 'TEST_REGEN=1 node test/00-setup.js' }, +4658 silly resolved license: 'BSD', +4658 silly resolved gitHead: '73f57e99510582b2024b762305970ebcf9b70aa2', +4658 silly resolved bugs: { url: 'https://github.com/isaacs/node-glob/issues' }, +4658 silly resolved homepage: 'https://github.com/isaacs/node-glob', +4658 silly resolved _id: 'glob@3.2.11', +4658 silly resolved _shasum: '4a973f635b9190f715d10987d5c00fd2815ebe3d', +4658 silly resolved _from: 'glob@3.2.11', +4658 silly resolved _npmVersion: '1.4.10', +4658 silly resolved _npmUser: { name: 'isaacs', email: 'i@izs.me' }, +4658 silly resolved maintainers: [ [Object] ], +4658 silly resolved dist: +4658 silly resolved { shasum: '4a973f635b9190f715d10987d5c00fd2815ebe3d', +4658 silly resolved tarball: 'http://registry.npmjs.org/glob/-/glob-3.2.11.tgz' }, +4658 silly resolved directories: {}, +4658 silly resolved _resolved: 'https://registry.npmjs.org/glob/-/glob-3.2.11.tgz', +4658 silly resolved readme: 'ERROR: No README data found!' } ] +4659 info install glob@3.2.11 into /usr/lib/node_modules/grunt/node_modules/findup-sync +4660 info installOne glob@3.2.11 +4661 silly resolved [ { author: +4661 silly resolved { name: 'Isaac Z. Schlueter', +4661 silly resolved email: 'i@izs.me', +4661 silly resolved url: 'http://blog.izs.me/' }, +4661 silly resolved name: 'glob', +4661 silly resolved description: 'a little globber', +4661 silly resolved version: '3.2.11', +4661 silly resolved repository: { type: 'git', url: 'git://github.com/isaacs/node-glob.git' }, +4661 silly resolved main: 'glob.js', +4661 silly resolved engines: { node: '*' }, +4661 silly resolved dependencies: { inherits: '2', minimatch: '0.3' }, +4661 silly resolved devDependencies: { tap: '~0.4.0', mkdirp: '0', rimraf: '1' }, +4661 silly resolved scripts: +4661 silly resolved { test: 'tap test/*.js', +4661 silly resolved 'test-regen': 'TEST_REGEN=1 node test/00-setup.js' }, +4661 silly resolved license: 'BSD', +4661 silly resolved gitHead: '73f57e99510582b2024b762305970ebcf9b70aa2', +4661 silly resolved bugs: { url: 'https://github.com/isaacs/node-glob/issues' }, +4661 silly resolved homepage: 'https://github.com/isaacs/node-glob', +4661 silly resolved _id: 'glob@3.2.11', +4661 silly resolved _shasum: '4a973f635b9190f715d10987d5c00fd2815ebe3d', +4661 silly resolved _from: 'glob@3.2.11', +4661 silly resolved _npmVersion: '1.4.10', +4661 silly resolved _npmUser: { name: 'isaacs', email: 'i@izs.me' }, +4661 silly resolved maintainers: [ [Object] ], +4661 silly resolved dist: +4661 silly resolved { shasum: '4a973f635b9190f715d10987d5c00fd2815ebe3d', +4661 silly resolved tarball: 'http://registry.npmjs.org/glob/-/glob-3.2.11.tgz' }, +4661 silly resolved directories: {}, +4661 silly resolved _resolved: 'https://registry.npmjs.org/glob/-/glob-3.2.11.tgz', +4661 silly resolved readme: 'ERROR: No README data found!' } ] +4662 info install glob@3.2.11 into /usr/lib/node_modules/karma +4663 info installOne glob@3.2.11 +4664 silly resolved [ { author: +4664 silly resolved { name: 'Isaac Z. Schlueter', +4664 silly resolved email: 'i@izs.me', +4664 silly resolved url: 'http://blog.izs.me/' }, +4664 silly resolved name: 'glob', +4664 silly resolved description: 'a little globber', +4664 silly resolved version: '3.2.11', +4664 silly resolved repository: { type: 'git', url: 'git://github.com/isaacs/node-glob.git' }, +4664 silly resolved main: 'glob.js', +4664 silly resolved engines: { node: '*' }, +4664 silly resolved dependencies: { inherits: '2', minimatch: '0.3' }, +4664 silly resolved devDependencies: { tap: '~0.4.0', mkdirp: '0', rimraf: '1' }, +4664 silly resolved scripts: +4664 silly resolved { test: 'tap test/*.js', +4664 silly resolved 'test-regen': 'TEST_REGEN=1 node test/00-setup.js' }, +4664 silly resolved license: 'BSD', +4664 silly resolved gitHead: '73f57e99510582b2024b762305970ebcf9b70aa2', +4664 silly resolved bugs: { url: 'https://github.com/isaacs/node-glob/issues' }, +4664 silly resolved homepage: 'https://github.com/isaacs/node-glob', +4664 silly resolved _id: 'glob@3.2.11', +4664 silly resolved _shasum: '4a973f635b9190f715d10987d5c00fd2815ebe3d', +4664 silly resolved _from: 'glob@3.2.11', +4664 silly resolved _npmVersion: '1.4.10', +4664 silly resolved _npmUser: { name: 'isaacs', email: 'i@izs.me' }, +4664 silly resolved maintainers: [ [Object] ], +4664 silly resolved dist: +4664 silly resolved { shasum: '4a973f635b9190f715d10987d5c00fd2815ebe3d', +4664 silly resolved tarball: 'http://registry.npmjs.org/glob/-/glob-3.2.11.tgz' }, +4664 silly resolved directories: {}, +4664 silly resolved _resolved: 'https://registry.npmjs.org/glob/-/glob-3.2.11.tgz', +4664 silly resolved readme: 'ERROR: No README data found!' } ] +4665 info install glob@3.2.11 into /usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/fileset +4666 info installOne glob@3.2.11 +4667 silly resolved [ { author: +4667 silly resolved { name: 'Isaac Z. Schlueter', +4667 silly resolved email: 'i@izs.me', +4667 silly resolved url: 'http://blog.izs.me/' }, +4667 silly resolved name: 'glob', +4667 silly resolved description: 'a little globber', +4667 silly resolved version: '3.2.11', +4667 silly resolved repository: { type: 'git', url: 'git://github.com/isaacs/node-glob.git' }, +4667 silly resolved main: 'glob.js', +4667 silly resolved engines: { node: '*' }, +4667 silly resolved dependencies: { inherits: '2', minimatch: '0.3' }, +4667 silly resolved devDependencies: { tap: '~0.4.0', mkdirp: '0', rimraf: '1' }, +4667 silly resolved scripts: +4667 silly resolved { test: 'tap test/*.js', +4667 silly resolved 'test-regen': 'TEST_REGEN=1 node test/00-setup.js' }, +4667 silly resolved license: 'BSD', +4667 silly resolved gitHead: '73f57e99510582b2024b762305970ebcf9b70aa2', +4667 silly resolved bugs: { url: 'https://github.com/isaacs/node-glob/issues' }, +4667 silly resolved homepage: 'https://github.com/isaacs/node-glob', +4667 silly resolved _id: 'glob@3.2.11', +4667 silly resolved _shasum: '4a973f635b9190f715d10987d5c00fd2815ebe3d', +4667 silly resolved _from: 'glob@3.2.11', +4667 silly resolved _npmVersion: '1.4.10', +4667 silly resolved _npmUser: { name: 'isaacs', email: 'i@izs.me' }, +4667 silly resolved maintainers: [ [Object] ], +4667 silly resolved dist: +4667 silly resolved { shasum: '4a973f635b9190f715d10987d5c00fd2815ebe3d', +4667 silly resolved tarball: 'http://registry.npmjs.org/glob/-/glob-3.2.11.tgz' }, +4667 silly resolved directories: {}, +4667 silly resolved _resolved: 'https://registry.npmjs.org/glob/-/glob-3.2.11.tgz', +4667 silly resolved readme: 'ERROR: No README data found!' } ] +4668 info install glob@3.2.11 into /usr/lib/node_modules/nodeunit/node_modules/tap +4669 info installOne glob@3.2.11 +4670 silly resolved [ { name: 'resolve', +4670 silly resolved description: 'resolve like require.resolve() on behalf of files asynchronously and synchronously', +4670 silly resolved version: '0.3.1', +4670 silly resolved repository: +4670 silly resolved { type: 'git', +4670 silly resolved url: 'git://github.com/substack/node-resolve.git' }, +4670 silly resolved main: 'index.js', +4670 silly resolved keywords: [ 'resolve', 'require', 'node', 'module' ], +4670 silly resolved scripts: { test: 'tap test/*.js' }, +4670 silly resolved devDependencies: { tap: '~0.4.0' }, +4670 silly resolved license: 'MIT', +4670 silly resolved author: +4670 silly resolved { name: 'James Halliday', +4670 silly resolved email: 'mail@substack.net', +4670 silly resolved url: 'http://substack.net' }, +4670 silly resolved readme: '# resolve\n\nimplements the [node `require.resolve()`\nalgorithm](http://nodejs.org/docs/v0.4.8/api/all.html#all_Together...)\nsuch that you can `require.resolve()` on behalf of a file asynchronously and\nsynchronously\n\n[![build status](https://secure.travis-ci.org/substack/node-resolve.png)](http://travis-ci.org/substack/node-resolve)\n\n# example\n\nasynchronously resolve:\n\n``` js\nvar resolve = require(\'resolve\');\nresolve(\'tap\', { basedir: __dirname }, function (err, res) {\n if (err) console.error(err)\n else console.log(res)\n});\n```\n\n```\n$ node example/async.js\n/home/substack/projects/node-resolve/node_modules/tap/lib/main.js\n```\n\nsynchronously resolve:\n\n``` js\nvar resolve = require(\'resolve\');\nvar res = resolve.sync(\'tap\', { basedir: __dirname });\nconsole.log(res);\n```\n\n```\n$ node example/sync.js\n/home/substack/projects/node-resolve/node_modules/tap/lib/main.js\n```\n\n# methods\n\n``` js\nvar resolve = require(\'resolve\')\n```\n\n## resolve(pkg, opts={}, cb)\n\nAsynchronously resolve the module path string `pkg` into `cb(err, res)`.\n\noptions are:\n\n* opts.basedir - directory to begin resolving from\n\n* opts.extensions - array of file extensions to search in order\n\n* opts.readFile - how to read files asynchronously\n\n* opts.isFile - function to asynchronously test whether a file exists\n\n* opts.packageFilter - transform the parsed package.json contents before looking\nat the "main" field\n\n* opts.paths - require.paths array to use if nothing is found on the normal\nnode_modules recursive walk (probably don\'t use this)\n\ndefault `opts` values:\n\n``` javascript\n{\n paths: [],\n basedir: __dirname,\n extensions: [ \'.js\' ],\n readFile: fs.readFile,\n isFile: function (file, cb) {\n fs.stat(file, function (err, stat) {\n if (err && err.code === \'ENOENT\') cb(null, false)\n else if (err) cb(err)\n else cb(null, stat.isFile())\n });\n }\n}\n```\n\n## resolve.sync(pkg, opts)\n\nSynchronously resolve the module path string `pkg`, returning the result and\nthrowing an error when `pkg` can\'t be resolved.\n\noptions are:\n\n* opts.basedir - directory to begin resolving from\n\n* opts.extensions - array of file extensions to search in order\n\n* opts.readFile - how to read files synchronously\n\n* opts.isFile - function to synchronously test whether a file exists\n\n* opts.packageFilter - transform the parsed package.json contents before looking\nat the "main" field\n\n* opts.paths - require.paths array to use if nothing is found on the normal\nnode_modules recursive walk (probably don\'t use this)\n\ndefault `opts` values:\n\n``` javascript\n{\n paths: [],\n basedir: __dirname,\n extensions: [ \'.js\' ],\n readFileSync: fs.readFileSync,\n isFile: function (file) {\n try { return fs.statSync(file).isFile() }\n catch (e) { return false }\n }\n}\n````\n\n## resolve.isCore(pkg)\n\nReturn whether a package is in core.\n\n# install\n\nWith [npm](https://npmjs.org) do:\n\n```\nnpm install resolve\n```\n\n# license\n\nMIT\n', +4670 silly resolved readmeFilename: 'readme.markdown', +4670 silly resolved bugs: { url: 'https://github.com/substack/node-resolve/issues' }, +4670 silly resolved homepage: 'https://github.com/substack/node-resolve', +4670 silly resolved _id: 'resolve@0.3.1', +4670 silly resolved _from: 'resolve@0.3.1' } ] +4671 info install resolve@0.3.1 into /usr/lib/node_modules/grunt-cli +4672 info installOne resolve@0.3.1 +4673 silly resolved [ { name: 'nopt', +4673 silly resolved version: '1.0.10', +4673 silly resolved description: 'Option parsing for Node, supporting types, shorthands, etc. Used by npm.', +4673 silly resolved author: +4673 silly resolved { name: 'Isaac Z. Schlueter', +4673 silly resolved email: 'i@izs.me', +4673 silly resolved url: 'http://blog.izs.me/' }, +4673 silly resolved main: 'lib/nopt.js', +4673 silly resolved scripts: { test: 'node lib/nopt.js' }, +4673 silly resolved repository: { type: 'git', url: 'http://github.com/isaacs/nopt' }, +4673 silly resolved bin: { nopt: './bin/nopt.js' }, +4673 silly resolved license: +4673 silly resolved { type: 'MIT', +4673 silly resolved url: 'https://github.com/isaacs/nopt/raw/master/LICENSE' }, +4673 silly resolved dependencies: { abbrev: '1' }, +4673 silly resolved readme: 'If you want to write an option parser, and have it be good, there are\ntwo ways to do it. The Right Way, and the Wrong Way.\n\nThe Wrong Way is to sit down and write an option parser. We\'ve all done\nthat.\n\nThe Right Way is to write some complex configurable program with so many\noptions that you go half-insane just trying to manage them all, and put\nit off with duct-tape solutions until you see exactly to the core of the\nproblem, and finally snap and write an awesome option parser.\n\nIf you want to write an option parser, don\'t write an option parser.\nWrite a package manager, or a source control system, or a service\nrestarter, or an operating system. You probably won\'t end up with a\ngood one of those, but if you don\'t give up, and you are relentless and\ndiligent enough in your procrastination, you may just end up with a very\nnice option parser.\n\n## USAGE\n\n // my-program.js\n var nopt = require("nopt")\n , Stream = require("stream").Stream\n , path = require("path")\n , knownOpts = { "foo" : [String, null]\n , "bar" : [Stream, Number]\n , "baz" : path\n , "bloo" : [ "big", "medium", "small" ]\n , "flag" : Boolean\n , "pick" : Boolean\n , "many" : [String, Array]\n }\n , shortHands = { "foofoo" : ["--foo", "Mr. Foo"]\n , "b7" : ["--bar", "7"]\n , "m" : ["--bloo", "medium"]\n , "p" : ["--pick"]\n , "f" : ["--flag"]\n }\n // everything is optional.\n // knownOpts and shorthands default to {}\n // arg list defaults to process.argv\n // slice defaults to 2\n , parsed = nopt(knownOpts, shortHands, process.argv, 2)\n console.log(parsed)\n\nThis would give you support for any of the following:\n\n```bash\n$ node my-program.js --foo "blerp" --no-flag\n{ "foo" : "blerp", "flag" : false }\n\n$ node my-program.js ---bar 7 --foo "Mr. Hand" --flag\n{ bar: 7, foo: "Mr. Hand", flag: true }\n\n$ node my-program.js --foo "blerp" -f -----p\n{ foo: "blerp", flag: true, pick: true }\n\n$ node my-program.js -fp --foofoo\n{ foo: "Mr. Foo", flag: true, pick: true }\n\n$ node my-program.js --foofoo -- -fp # -- stops the flag parsing.\n{ foo: "Mr. Foo", argv: { remain: ["-fp"] } }\n\n$ node my-program.js --blatzk 1000 -fp # unknown opts are ok.\n{ blatzk: 1000, flag: true, pick: true }\n\n$ node my-program.js --blatzk true -fp # but they need a value\n{ blatzk: true, flag: true, pick: true }\n\n$ node my-program.js --no-blatzk -fp # unless they start with "no-"\n{ blatzk: false, flag: true, pick: true }\n\n$ node my-program.js --baz b/a/z # known paths are resolved.\n{ baz: "/Users/isaacs/b/a/z" }\n\n# if Array is one of the types, then it can take many\n# values, and will always be an array. The other types provided\n# specify what types are allowed in the list.\n\n$ node my-program.js --many 1 --many null --many foo\n{ many: ["1", "null", "foo"] }\n\n$ node my-program.js --many foo\n{ many: ["foo"] }\n```\n\nRead the tests at the bottom of `lib/nopt.js` for more examples of\nwhat this puppy can do.\n\n## Types\n\nThe following types are supported, and defined on `nopt.typeDefs`\n\n* String: A normal string. No parsing is done.\n* path: A file system path. Gets resolved against cwd if not absolute.\n* url: A url. If it doesn\'t parse, it isn\'t accepted.\n* Number: Must be numeric.\n* Date: Must parse as a date. If it does, and `Date` is one of the options,\n then it will return a Date object, not a string.\n* Boolean: Must be either `true` or `false`. If an option is a boolean,\n then it does not need a value, and its presence will imply `true` as\n the value. To negate boolean flags, do `--no-whatever` or `--whatever\n false`\n* NaN: Means that the option is strictly not allowed. Any value will\n fail.\n* Stream: An object matching the "Stream" class in node. Valuable\n for use when validating programmatically. (npm uses this to let you\n supply any WriteStream on the `outfd` and `logfd` config options.)\n* Array: If `Array` is specified as one of the types, then the value\n will be parsed as a list of options. This means that multiple values\n can be specified, and that the value will always be an array.\n\nIf a type is an array of values not on this list, then those are\nconsidered valid values. For instance, in the example above, the\n`--bloo` option can only be one of `"big"`, `"medium"`, or `"small"`,\nand any other value will be rejected.\n\nWhen parsing unknown fields, `"true"`, `"false"`, and `"null"` will be\ninterpreted as their JavaScript equivalents, and numeric values will be\ninterpreted as a number.\n\nYou can also mix types and values, or multiple types, in a list. For\ninstance `{ blah: [Number, null] }` would allow a value to be set to\neither a Number or null.\n\nTo define a new type, add it to `nopt.typeDefs`. Each item in that\nhash is an object with a `type` member and a `validate` method. The\n`type` member is an object that matches what goes in the type list. The\n`validate` method is a function that gets called with `validate(data,\nkey, val)`. Validate methods should assign `data[key]` to the valid\nvalue of `val` if it can be handled properly, or return boolean\n`false` if it cannot.\n\nYou can also call `nopt.clean(data, types, typeDefs)` to clean up a\nconfig object and remove its invalid properties.\n\n## Error Handling\n\nBy default, nopt outputs a warning to standard error when invalid\noptions are found. You can change this behavior by assigning a method\nto `nopt.invalidHandler`. This method will be called with\nthe offending `nopt.invalidHandler(key, val, types)`.\n\nIf no `nopt.invalidHandler` is assigned, then it will console.error\nits whining. If it is assigned to boolean `false` then the warning is\nsuppressed.\n\n## Abbreviations\n\nYes, they are supported. If you define options like this:\n\n```javascript\n{ "foolhardyelephants" : Boolean\n, "pileofmonkeys" : Boolean }\n```\n\nThen this will work:\n\n```bash\nnode program.js --foolhar --pil\nnode program.js --no-f --pileofmon\n# etc.\n```\n\n## Shorthands\n\nShorthands are a hash of shorter option names to a snippet of args that\nthey expand to.\n\nIf multiple one-character shorthands are all combined, and the\ncombination does not unambiguously match any other option or shorthand,\nthen they will be broken up into their constituent parts. For example:\n\n```json\n{ "s" : ["--loglevel", "silent"]\n, "g" : "--global"\n, "f" : "--force"\n, "p" : "--parseable"\n, "l" : "--long"\n}\n```\n\n```bash\nnpm ls -sgflp\n# just like doing this:\nnpm ls --loglevel silent --global --force --long --parseable\n```\n\n## The Rest of the args\n\nThe config object returned by nopt is given a special member called\n`argv`, which is an object with the following fields:\n\n* `remain`: The remaining args after all the parsing has occurred.\n* `original`: The args as they originally appeared.\n* `cooked`: The args after flags and shorthands are expanded.\n\n## Slicing\n\nNode programs are called with more or less the exact argv as it appears\nin C land, after the v8 and node-specific options have been plucked off.\nAs such, `argv[0]` is always `node` and `argv[1]` is always the\nJavaScript program being run.\n\nThat\'s usually not very useful to you. So they\'re sliced off by\ndefault. If you want them, then you can pass in `0` as the last\nargument, or any other number that you\'d like to slice off the start of\nthe list.\n', +4673 silly resolved readmeFilename: 'README.md', +4673 silly resolved bugs: { url: 'https://github.com/isaacs/nopt/issues' }, +4673 silly resolved homepage: 'https://github.com/isaacs/nopt', +4673 silly resolved _id: 'nopt@1.0.10', +4673 silly resolved _from: 'nopt@1.0.10' } ] +4674 info install nopt@1.0.10 into /usr/lib/node_modules/grunt-cli +4675 info installOne nopt@1.0.10 +4676 silly resolved [ { name: 'nopt', +4676 silly resolved version: '1.0.10', +4676 silly resolved description: 'Option parsing for Node, supporting types, shorthands, etc. Used by npm.', +4676 silly resolved author: +4676 silly resolved { name: 'Isaac Z. Schlueter', +4676 silly resolved email: 'i@izs.me', +4676 silly resolved url: 'http://blog.izs.me/' }, +4676 silly resolved main: 'lib/nopt.js', +4676 silly resolved scripts: { test: 'node lib/nopt.js' }, +4676 silly resolved repository: { type: 'git', url: 'http://github.com/isaacs/nopt' }, +4676 silly resolved bin: { nopt: './bin/nopt.js' }, +4676 silly resolved license: +4676 silly resolved { type: 'MIT', +4676 silly resolved url: 'https://github.com/isaacs/nopt/raw/master/LICENSE' }, +4676 silly resolved dependencies: { abbrev: '1' }, +4676 silly resolved readme: 'If you want to write an option parser, and have it be good, there are\ntwo ways to do it. The Right Way, and the Wrong Way.\n\nThe Wrong Way is to sit down and write an option parser. We\'ve all done\nthat.\n\nThe Right Way is to write some complex configurable program with so many\noptions that you go half-insane just trying to manage them all, and put\nit off with duct-tape solutions until you see exactly to the core of the\nproblem, and finally snap and write an awesome option parser.\n\nIf you want to write an option parser, don\'t write an option parser.\nWrite a package manager, or a source control system, or a service\nrestarter, or an operating system. You probably won\'t end up with a\ngood one of those, but if you don\'t give up, and you are relentless and\ndiligent enough in your procrastination, you may just end up with a very\nnice option parser.\n\n## USAGE\n\n // my-program.js\n var nopt = require("nopt")\n , Stream = require("stream").Stream\n , path = require("path")\n , knownOpts = { "foo" : [String, null]\n , "bar" : [Stream, Number]\n , "baz" : path\n , "bloo" : [ "big", "medium", "small" ]\n , "flag" : Boolean\n , "pick" : Boolean\n , "many" : [String, Array]\n }\n , shortHands = { "foofoo" : ["--foo", "Mr. Foo"]\n , "b7" : ["--bar", "7"]\n , "m" : ["--bloo", "medium"]\n , "p" : ["--pick"]\n , "f" : ["--flag"]\n }\n // everything is optional.\n // knownOpts and shorthands default to {}\n // arg list defaults to process.argv\n // slice defaults to 2\n , parsed = nopt(knownOpts, shortHands, process.argv, 2)\n console.log(parsed)\n\nThis would give you support for any of the following:\n\n```bash\n$ node my-program.js --foo "blerp" --no-flag\n{ "foo" : "blerp", "flag" : false }\n\n$ node my-program.js ---bar 7 --foo "Mr. Hand" --flag\n{ bar: 7, foo: "Mr. Hand", flag: true }\n\n$ node my-program.js --foo "blerp" -f -----p\n{ foo: "blerp", flag: true, pick: true }\n\n$ node my-program.js -fp --foofoo\n{ foo: "Mr. Foo", flag: true, pick: true }\n\n$ node my-program.js --foofoo -- -fp # -- stops the flag parsing.\n{ foo: "Mr. Foo", argv: { remain: ["-fp"] } }\n\n$ node my-program.js --blatzk 1000 -fp # unknown opts are ok.\n{ blatzk: 1000, flag: true, pick: true }\n\n$ node my-program.js --blatzk true -fp # but they need a value\n{ blatzk: true, flag: true, pick: true }\n\n$ node my-program.js --no-blatzk -fp # unless they start with "no-"\n{ blatzk: false, flag: true, pick: true }\n\n$ node my-program.js --baz b/a/z # known paths are resolved.\n{ baz: "/Users/isaacs/b/a/z" }\n\n# if Array is one of the types, then it can take many\n# values, and will always be an array. The other types provided\n# specify what types are allowed in the list.\n\n$ node my-program.js --many 1 --many null --many foo\n{ many: ["1", "null", "foo"] }\n\n$ node my-program.js --many foo\n{ many: ["foo"] }\n```\n\nRead the tests at the bottom of `lib/nopt.js` for more examples of\nwhat this puppy can do.\n\n## Types\n\nThe following types are supported, and defined on `nopt.typeDefs`\n\n* String: A normal string. No parsing is done.\n* path: A file system path. Gets resolved against cwd if not absolute.\n* url: A url. If it doesn\'t parse, it isn\'t accepted.\n* Number: Must be numeric.\n* Date: Must parse as a date. If it does, and `Date` is one of the options,\n then it will return a Date object, not a string.\n* Boolean: Must be either `true` or `false`. If an option is a boolean,\n then it does not need a value, and its presence will imply `true` as\n the value. To negate boolean flags, do `--no-whatever` or `--whatever\n false`\n* NaN: Means that the option is strictly not allowed. Any value will\n fail.\n* Stream: An object matching the "Stream" class in node. Valuable\n for use when validating programmatically. (npm uses this to let you\n supply any WriteStream on the `outfd` and `logfd` config options.)\n* Array: If `Array` is specified as one of the types, then the value\n will be parsed as a list of options. This means that multiple values\n can be specified, and that the value will always be an array.\n\nIf a type is an array of values not on this list, then those are\nconsidered valid values. For instance, in the example above, the\n`--bloo` option can only be one of `"big"`, `"medium"`, or `"small"`,\nand any other value will be rejected.\n\nWhen parsing unknown fields, `"true"`, `"false"`, and `"null"` will be\ninterpreted as their JavaScript equivalents, and numeric values will be\ninterpreted as a number.\n\nYou can also mix types and values, or multiple types, in a list. For\ninstance `{ blah: [Number, null] }` would allow a value to be set to\neither a Number or null.\n\nTo define a new type, add it to `nopt.typeDefs`. Each item in that\nhash is an object with a `type` member and a `validate` method. The\n`type` member is an object that matches what goes in the type list. The\n`validate` method is a function that gets called with `validate(data,\nkey, val)`. Validate methods should assign `data[key]` to the valid\nvalue of `val` if it can be handled properly, or return boolean\n`false` if it cannot.\n\nYou can also call `nopt.clean(data, types, typeDefs)` to clean up a\nconfig object and remove its invalid properties.\n\n## Error Handling\n\nBy default, nopt outputs a warning to standard error when invalid\noptions are found. You can change this behavior by assigning a method\nto `nopt.invalidHandler`. This method will be called with\nthe offending `nopt.invalidHandler(key, val, types)`.\n\nIf no `nopt.invalidHandler` is assigned, then it will console.error\nits whining. If it is assigned to boolean `false` then the warning is\nsuppressed.\n\n## Abbreviations\n\nYes, they are supported. If you define options like this:\n\n```javascript\n{ "foolhardyelephants" : Boolean\n, "pileofmonkeys" : Boolean }\n```\n\nThen this will work:\n\n```bash\nnode program.js --foolhar --pil\nnode program.js --no-f --pileofmon\n# etc.\n```\n\n## Shorthands\n\nShorthands are a hash of shorter option names to a snippet of args that\nthey expand to.\n\nIf multiple one-character shorthands are all combined, and the\ncombination does not unambiguously match any other option or shorthand,\nthen they will be broken up into their constituent parts. For example:\n\n```json\n{ "s" : ["--loglevel", "silent"]\n, "g" : "--global"\n, "f" : "--force"\n, "p" : "--parseable"\n, "l" : "--long"\n}\n```\n\n```bash\nnpm ls -sgflp\n# just like doing this:\nnpm ls --loglevel silent --global --force --long --parseable\n```\n\n## The Rest of the args\n\nThe config object returned by nopt is given a special member called\n`argv`, which is an object with the following fields:\n\n* `remain`: The remaining args after all the parsing has occurred.\n* `original`: The args as they originally appeared.\n* `cooked`: The args after flags and shorthands are expanded.\n\n## Slicing\n\nNode programs are called with more or less the exact argv as it appears\nin C land, after the v8 and node-specific options have been plucked off.\nAs such, `argv[0]` is always `node` and `argv[1]` is always the\nJavaScript program being run.\n\nThat\'s usually not very useful to you. So they\'re sliced off by\ndefault. If you want them, then you can pass in `0` as the last\nargument, or any other number that you\'d like to slice off the start of\nthe list.\n', +4676 silly resolved readmeFilename: 'README.md', +4676 silly resolved bugs: { url: 'https://github.com/isaacs/nopt/issues' }, +4676 silly resolved homepage: 'https://github.com/isaacs/nopt', +4676 silly resolved _id: 'nopt@1.0.10', +4676 silly resolved _from: 'nopt@1.0.10' } ] +4677 info install nopt@1.0.10 into /usr/lib/node_modules/grunt +4678 info installOne nopt@1.0.10 +4679 silly resolved [ { name: 'eventsource', +4679 silly resolved version: '0.0.10', +4679 silly resolved description: 'W3C compliant EventSource client for Node.js', +4679 silly resolved keywords: [ 'eventsource', 'http', 'streaming', 'sse' ], +4679 silly resolved homepage: 'http://github.com/aslakhellesoy/eventsource-node', +4679 silly resolved author: { name: 'Aslak Hellesøy', email: 'aslak.hellesoy@gmail.com' }, +4679 silly resolved contributors: +4679 silly resolved [ [Object], +4679 silly resolved [Object], +4679 silly resolved [Object], +4679 silly resolved [Object], +4679 silly resolved [Object], +4679 silly resolved [Object], +4679 silly resolved [Object] ], +4679 silly resolved repository: +4679 silly resolved { type: 'git', +4679 silly resolved url: 'git://github.com/aslakhellesoy/eventsource-node.git' }, +4679 silly resolved bugs: { url: 'http://github.com/aslakhellesoy/eventsource-node/issues' }, +4679 silly resolved directories: { lib: './lib' }, +4679 silly resolved main: './lib/eventsource', +4679 silly resolved licenses: [ [Object] ], +4679 silly resolved devDependencies: { mocha: '~1.9.0', jison: '~0.4.4' }, +4679 silly resolved scripts: { test: 'make run-tests' }, +4679 silly resolved engines: { node: '>=0.6.0' }, +4679 silly resolved readme: '# EventSource [![Build Status](https://secure.travis-ci.org/aslakhellesoy/eventsource-node.png)](http://travis-ci.org/aslakhellesoy/eventsource-node) [![Dependencies](https://david-dm.org/aslakhellesoy/eventsource-node.png)](https://david-dm.org/aslakhellesoy/eventsource-node) [![Bitdeli Badge](https://d2weczhvl823v0.cloudfront.net/aslakhellesoy/eventsource-node/trend.png)](https://bitdeli.com/free "Bitdeli Badge")\n\n\n[![NPM](https://nodei.co/npm/eventsource.png?stars&downloads)](https://nodei.co/npm/eventsource/) \n[![NPM](https://nodei.co/npm-dl/eventsource.png)](https://nodei.co/npm/eventsource/)\n\nThis library implements the [EventSource](http://dev.w3.org/html5/eventsource/) client for Node.js. The API aims to be W3C compatible.\n\n## Install\n\n npm install eventsource\n\n## Usage\n\n```javascript\nvar EventSource = require(\'eventsource\');\n\nvar es = new EventSource(\'http://googlecodesamples.com/html5/sse/sse.php\');\nes.onmessage = function(e) {\n console.log(e.data);\n};\nes.onerror = function() {\n console.log(\'ERROR!\');\n};\n```\n\nSee the [spec](http://dev.w3.org/html5/eventsource/) for API docs.\n\n## Example\n\nSee https://github.com/einaros/sse-example\n\n## Extensions to the W3C API\n\n### Setting HTTP request headers\n\nYou can define custom HTTP headers for the initial HTTP request. This can be useful for e.g. sending cookies\nor to specify an initial `Last-Event-ID` value.\n\nHTTP headers are defined by assigning a `headers` attribute to the optional `eventSourceInitDict` argument:\n\n```javascript\nvar eventSourceInitDict = {headers: {\'Cookie\': \'test=test\'}};\nvar es = new EventSource(url, eventSourceInitDict);\n```\n\n### Allow unauthorized HTTPS requests\n\nBy default, https requests that cannot be authorized will cause connection to fail and an exception\nto be emitted. You can override this behaviour:\n\n```\nvar eventSourceInitDict = {rejectUnauthorized: false};\nvar es = new EventSource(url, eventSourceInitDict);\n```\n\nNote that for Node.js < v0.10.x this option has no effect - unauthorized HTTPS requests are *always* allowed.\n\n', +4679 silly resolved readmeFilename: 'README.md', +4679 silly resolved _id: 'eventsource@0.0.10', +4679 silly resolved _shasum: '4d3a0f9b2c70083444fee3c39a7b2bfcf2221cbb', +4679 silly resolved _from: 'eventsource@0.0.10', +4679 silly resolved _resolved: 'https://registry.npmjs.org/eventsource/-/eventsource-0.0.10.tgz' } ] +4680 info install eventsource@0.0.10 into /usr/lib/node_modules/zombie +4681 info installOne eventsource@0.0.10 +4682 silly resolved [ { name: 'html5', +4682 silly resolved version: '0.3.14', +4682 silly resolved author: +4682 silly resolved { name: 'Aria Stewart', +4682 silly resolved email: 'aredridel@nbtsc.org', +4682 silly resolved url: 'http://dinhe.net/~aredridel/' }, +4682 silly resolved url: 'http://dinhe.net/~aredridel/projects/js/html5/', +4682 silly resolved repository: [ [Object], [Object] ], +4682 silly resolved contributors: [ [Object], [Object], [Object] ], +4682 silly resolved maintainers: [ [Object] ], +4682 silly resolved dependencies: { jsdom: '>= 0.8.0', opts: '~1.2.1', 'html5-entities': '~0.5.0' }, +4682 silly resolved devDependencies: { tape: '~1.0.4', bench: '~0.3.3', ronn: '~0.3.8' }, +4682 silly resolved engines: { npm: '>= 1.0', node: '>= 0.4.7' }, +4682 silly resolved main: './lib/html5/index.js', +4682 silly resolved directories: { lib: 'lib' }, +4682 silly resolved scripts: { test: 'PATH=$PATH:`npm bin` tape `find test -name \'*-test.js\'`' }, +4682 silly resolved license: 'MIT', +4682 silly resolved description: 'HTML5 HTML parser, including support for SVG and MathML foreign content', +4682 silly resolved readme: 'HTML5 Parser for node.js\n========================\n\n\nExample (With jQuery!) \n----------------------\n\n /* Before you run this, run:\n git submodule update --init\n (cd deps/jquery; rake)\n */\n var HTML5 = require(\'html5\'),\n Script = process.binding(\'evals\').Script,\n util = require(\'util\'),\n fs = require(\'fs\'),\n jsdom = require(\'jsdom\'),\n window = jsdom.jsdom(null, null, {parser: HTML5}).createWindow()\n\n var parser = new HTML5.Parser({document: window.document});\n\n var inputfile = fs.readFileSync(\'doc/jquery-example.html\');\n parser.parse(inputfile);\n\n jsdom.jQueryify(window, __dirname + \'/deps/jquery/dist/jquery.js\', function(window, jquery) {\n Script.runInNewContext(\'jQuery("p").append("Hi!")\', window);\n util.puts(window.document.innerHTML);\n\n });\n\nInteresting features\n--------------------\n\n* Streaming parser: You can pass `parser.parse` an `EventEmitter` and the\n parser will keep adding data as it\'s received.\n\n* HTML5 parsing algorithm. If you find something this can\'t parse, I\'ll want\n to know about it. It should make sense out of anything a browser can.\n\nInstallation\n-------------\n\nUse `npm`, or to use the git checkout, read on.\n\nYou\'ll need to fetch dependencies or initialize git submodules if you\'re\npulling this from my git repository. \n\n\tnpm install\n\nand give it a run:\n\n\tnpm test\n\n(At time of this writing, 1800 tests pass)\n\nGit repository at http://dinhe.net/~aredridel/projects/js/html5.git/\n', +4682 silly resolved readmeFilename: 'README.md', +4682 silly resolved _id: 'html5@0.3.14', +4682 silly resolved _shasum: 'ba61f56fcc1c6b904b190cc3930f14efd8e2a907', +4682 silly resolved _from: 'html5@0.3.14', +4682 silly resolved _resolved: 'https://registry.npmjs.org/html5/-/html5-0.3.14.tgz' } ] +4683 info install html5@0.3.14 into /usr/lib/node_modules/zombie +4684 info installOne html5@0.3.14 +4685 silly resolved [ { name: 'encoding', +4685 silly resolved version: '0.1.7', +4685 silly resolved description: 'Convert encodings, uses iconv by default and fallbacks to iconv-lite if needed', +4685 silly resolved main: 'index.js', +4685 silly resolved scripts: { test: 'nodeunit test.js' }, +4685 silly resolved repository: { type: 'git', url: 'https://github.com/andris9/encoding.git' }, +4685 silly resolved author: { name: 'Andris Reinman' }, +4685 silly resolved license: 'MIT', +4685 silly resolved dependencies: { 'iconv-lite': '~0.2.11' }, +4685 silly resolved devDependencies: { nodeunit: '~0.8.1' }, +4685 silly resolved readme: '# Encoding\n\n**encoding** is a simple wrapper around [node-iconv](https://github.com/bnoordhuis/node-iconv) and [iconv-lite](https://github.com/ashtuchkin/iconv-lite/) to convert strings from one encoding to another. If node-iconv is not available for some reason,\niconv-lite will be used instead of it as a fallback.\n\n## Install\n\nInstall through npm\n\n npm install encoding\n\n## Usage\n\nRequire the module\n\n var encoding = require("encoding");\n\nConvert with encoding.convert()\n\n var resultBuffer = encoding.convert(text, toCharset, fromCharset);\n\nWhere\n\n * **text** is either a Buffer or a String to be converted\n * **toCharset** is the characterset to convert the string\n * **fromCharset** (*optional*, defaults to UTF-8) is the source charset\n\nOutput of the conversion is always a Buffer object.\n\nExample\n\n var result = encoding.convert("ÕÄÖÜ", "Latin_1");\n console.log(result); //\n\n## iconv support\n\nBy default only iconv-lite is bundled. If you need node-iconv support, you need to add it\nas an additional dependency for your project:\n\n ...,\n "dependencies":{\n "encoding": "*",\n "iconv": "*"\n },\n ...\n\n## License\n\n**MIT**', +4685 silly resolved readmeFilename: 'README.md', +4685 silly resolved bugs: { url: 'https://github.com/andris9/encoding/issues' }, +4685 silly resolved homepage: 'https://github.com/andris9/encoding', +4685 silly resolved _id: 'encoding@0.1.7', +4685 silly resolved _shasum: '25cc19b34e9225d120c2ea769f9136c91cecc908', +4685 silly resolved _from: 'encoding@0.1.7', +4685 silly resolved _resolved: 'https://registry.npmjs.org/encoding/-/encoding-0.1.7.tgz' } ] +4686 info install encoding@0.1.7 into /usr/lib/node_modules/zombie +4687 info installOne encoding@0.1.7 +4688 silly resolved [ { author: +4688 silly resolved { name: 'Einar Otto Stangvik', +4688 silly resolved email: 'einaros@gmail.com', +4688 silly resolved url: 'http://2x.io' }, +4688 silly resolved name: 'ws', +4688 silly resolved description: 'simple to use, blazing fast and thoroughly tested websocket client, server and console for node.js, up-to-date against RFC-6455', +4688 silly resolved version: '0.4.31', +4688 silly resolved keywords: +4688 silly resolved [ 'Hixie', +4688 silly resolved 'HyBi', +4688 silly resolved 'Push', +4688 silly resolved 'RFC-6455', +4688 silly resolved 'WebSocket', +4688 silly resolved 'WebSockets', +4688 silly resolved 'real-time' ], +4688 silly resolved repository: { type: 'git', url: 'git://github.com/einaros/ws.git' }, +4688 silly resolved bin: { wscat: './bin/wscat' }, +4688 silly resolved scripts: +4688 silly resolved { test: 'make test', +4688 silly resolved install: '(node-gyp rebuild 2> builderror.log) || (exit 0)' }, +4688 silly resolved engines: { node: '>=0.4.0' }, +4688 silly resolved dependencies: +4688 silly resolved { commander: '~0.6.1', +4688 silly resolved nan: '~0.3.0', +4688 silly resolved tinycolor: '0.x', +4688 silly resolved options: '>=0.0.5' }, +4688 silly resolved devDependencies: +4688 silly resolved { mocha: '1.12.0', +4688 silly resolved should: '1.2.x', +4688 silly resolved 'expect.js': '0.2.x', +4688 silly resolved benchmark: '0.3.x', +4688 silly resolved ansi: 'latest' }, +4688 silly resolved browser: './lib/browser.js', +4688 silly resolved component: { scripts: [Object] }, +4688 silly resolved gypfile: true, +4688 silly resolved readme: '[![Build Status](https://secure.travis-ci.org/einaros/ws.png)](http://travis-ci.org/einaros/ws)\n\n# ws: a node.js websocket library #\n\n`ws` is a simple to use websocket implementation, up-to-date against RFC-6455, and [probably the fastest WebSocket library for node.js](http://web.archive.org/web/20130314230536/http://hobbycoding.posterous.com/the-fastest-websocket-module-for-nodejs).\n\nPasses the quite extensive Autobahn test suite. See http://einaros.github.com/ws for the full reports.\n\nComes with a command line utility, `wscat`, which can either act as a server (--listen), or client (--connect); Use it to debug simple websocket services.\n\n## Protocol support ##\n\n* **Hixie draft 76** (Old and deprecated, but still in use by Safari and Opera. Added to ws version 0.4.2, but server only. Can be disabled by setting the `disableHixie` option to true.)\n* **HyBi drafts 07-12** (Use the option `protocolVersion: 8`, or argument `-p 8` for wscat)\n* **HyBi drafts 13-17** (Current default, alternatively option `protocolVersion: 13`, or argument `-p 13` for wscat)\n\n_See the echo.websocket.org example below for how to use the `protocolVersion` option._\n\n## Usage ##\n\n### Installing ###\n\n`npm install ws`\n\n### Sending and receiving text data ###\n\n```js\nvar WebSocket = require(\'ws\');\nvar ws = new WebSocket(\'ws://www.host.com/path\');\nws.on(\'open\', function() {\n ws.send(\'something\');\n});\nws.on(\'message\', function(data, flags) {\n // flags.binary will be set if a binary data is received\n // flags.masked will be set if the data was masked\n});\n```\n\n### Sending binary data ###\n\n```js\nvar WebSocket = require(\'ws\');\nvar ws = new WebSocket(\'ws://www.host.com/path\');\nws.on(\'open\', function() {\n var array = new Float32Array(5);\n for (var i = 0; i < array.length; ++i) array[i] = i / 2;\n ws.send(array, {binary: true, mask: true});\n});\n```\n\nSetting `mask`, as done for the send options above, will cause the data to be masked according to the websocket protocol. The same option applies for text data.\n\n### Server example ###\n\n```js\nvar WebSocketServer = require(\'ws\').Server\n , wss = new WebSocketServer({port: 8080});\nwss.on(\'connection\', function(ws) {\n ws.on(\'message\', function(message) {\n console.log(\'received: %s\', message);\n });\n ws.send(\'something\');\n});\n```\n\n### Server sending broadcast data ###\n\n```js\nvar WebSocketServer = require(\'ws\').Server\n , wss = new WebSocketServer({port: 8080});\n \nwss.broadcast = function(data) {\n\tfor(var i in this.clients)\n\t\tthis.clients[i].send(data);\n};\n```\n\n### Error handling best practices ###\n\n```js\n// If the WebSocket is closed before the following send is attempted\nws.send(\'something\');\n\n// Errors (both immediate and async write errors) can be detected in an optional callback.\n// The callback is also the only way of being notified that data has actually been sent.\nws.send(\'something\', function(error) {\n // if error is null, the send has been completed,\n // otherwise the error object will indicate what failed.\n});\n\n// Immediate errors can also be handled with try/catch-blocks, but **note**\n// that since sends are inherently asynchronous, socket write failures will *not*\n// be captured when this technique is used.\ntry {\n ws.send(\'something\');\n}\ncatch (e) {\n // handle error\n}\n```\n\n### echo.websocket.org demo ###\n\n```js\nvar WebSocket = require(\'ws\');\nvar ws = new WebSocket(\'ws://echo.websocket.org/\', {protocolVersion: 8, origin: \'http://websocket.org\'});\nws.on(\'open\', function() {\n console.log(\'connected\');\n ws.send(Date.now().toString(), {mask: true});\n});\nws.on(\'close\', function() {\n console.log(\'disconnected\');\n});\nws.on(\'message\', function(data, flags) {\n console.log(\'Roundtrip time: \' + (Date.now() - parseInt(data)) + \'ms\', flags);\n setTimeout(function() {\n ws.send(Date.now().toString(), {mask: true});\n }, 500);\n});\n```\n\n### wscat against echo.websocket.org ###\n\n $ npm install -g ws\n $ wscat -c ws://echo.websocket.org -p 8\n connected (press CTRL+C to quit)\n > hi there\n < hi there\n > are you a happy parrot?\n < are you a happy parrot?\n\n### Other examples ###\n\nFor a full example with a browser client communicating with a ws server, see the examples folder.\n\nNote that the usage together with Express 3.0 is quite different from Express 2.x. The difference is expressed in the two different serverstats-examples.\n\nOtherwise, see the test cases.\n\n### Running the tests ###\n\n`make test`\n\n## API Docs ##\n\nSee the doc/ directory for Node.js-like docs for the ws classes.\n\n## License ##\n\n(The MIT License)\n\nCopyright (c) 2011 Einar Otto Stangvik <einaros@gmail.com>\n\nPermission is hereby granted, free of charge, to any person obtaining\na copy of this software and associated documentation files (the\n\'Software\'), to deal in the Software without restriction, including\nwithout limitation the rights to use, copy, modify, merge, publish,\ndistribute, sublicense, and/or sell copies of the Software, and to\npermit persons to whom the Software is furnished to do so, subject to\nthe following conditions:\n\nThe above copyright notice and this permission notice shall be\nincluded in all copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \'AS IS\', WITHOUT WARRANTY OF ANY KIND,\nEXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\nMERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.\nIN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY\nCLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,\nTORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE\nSOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n', +4688 silly resolved readmeFilename: 'README.md', +4688 silly resolved bugs: { url: 'https://github.com/einaros/ws/issues' }, +4688 silly resolved homepage: 'https://github.com/einaros/ws', +4688 silly resolved _id: 'ws@0.4.31', +4688 silly resolved _shasum: '5a4849e7a9ccd1ed5a81aeb4847c9fedf3122927', +4688 silly resolved _from: 'ws@0.4.31', +4688 silly resolved _resolved: 'https://registry.npmjs.org/ws/-/ws-0.4.31.tgz' } ] +4689 info install ws@0.4.31 into /usr/lib/node_modules/zombie +4690 info installOne ws@0.4.31 +4691 silly resolved [ { name: 'q', +4691 silly resolved version: '1.0.0', +4691 silly resolved description: 'A library for promises (CommonJS/Promises/A,B,D)', +4691 silly resolved homepage: 'https://github.com/kriskowal/q', +4691 silly resolved author: +4691 silly resolved { name: 'Kris Kowal', +4691 silly resolved email: 'kris@cixar.com', +4691 silly resolved url: 'https://github.com/kriskowal' }, +4691 silly resolved keywords: +4691 silly resolved [ 'q', +4691 silly resolved 'promise', +4691 silly resolved 'promises', +4691 silly resolved 'promises-a', +4691 silly resolved 'promises-aplus', +4691 silly resolved 'deferred', +4691 silly resolved 'future', +4691 silly resolved 'async', +4691 silly resolved 'flow control', +4691 silly resolved 'fluent', +4691 silly resolved 'browser', +4691 silly resolved 'node' ], +4691 silly resolved contributors: [ [Object], [Object], [Object] ], +4691 silly resolved bugs: { url: 'http://github.com/kriskowal/q/issues' }, +4691 silly resolved license: +4691 silly resolved { type: 'MIT', +4691 silly resolved url: 'http://github.com/kriskowal/q/raw/master/LICENSE' }, +4691 silly resolved main: 'q.js', +4691 silly resolved repository: { type: 'git', url: 'git://github.com/kriskowal/q.git' }, +4691 silly resolved engines: { node: '>=0.6.0', teleport: '>=0.2.0' }, +4691 silly resolved dependencies: {}, +4691 silly resolved devDependencies: +4691 silly resolved { jshint: '~2.1.9', +4691 silly resolved cover: '*', +4691 silly resolved 'jasmine-node': '1.11.0', +4691 silly resolved opener: '*', +4691 silly resolved 'promises-aplus-tests': '1.x', +4691 silly resolved grunt: '~0.4.1', +4691 silly resolved 'grunt-cli': '~0.1.9', +4691 silly resolved 'grunt-contrib-uglify': '~0.2.2', +4691 silly resolved matcha: '~0.2.0' }, +4691 silly resolved scripts: +4691 silly resolved { test: 'jasmine-node spec && promises-aplus-tests spec/aplus-adapter', +4691 silly resolved 'test-browser': 'opener spec/q-spec.html', +4691 silly resolved benchmark: 'matcha', +4691 silly resolved lint: 'jshint q.js', +4691 silly resolved cover: 'cover run node_modules/jasmine-node/bin/jasmine-node spec && cover report html && opener cover_html/index.html', +4691 silly resolved minify: 'grunt', +4691 silly resolved prepublish: 'grunt' }, +4691 silly resolved overlay: { teleport: [Object] }, +4691 silly resolved directories: { test: './spec' }, +4691 silly resolved readme: '[![Build Status](https://secure.travis-ci.org/kriskowal/q.png?branch=master)](http://travis-ci.org/kriskowal/q)\n\n\n Promises/A+ logo\n\n\nIf a function cannot return a value or throw an exception without\nblocking, it can return a promise instead. A promise is an object\nthat represents the return value or the thrown exception that the\nfunction may eventually provide. A promise can also be used as a\nproxy for a [remote object][Q-Connection] to overcome latency.\n\n[Q-Connection]: https://github.com/kriskowal/q-connection\n\nOn the first pass, promises can mitigate the “[Pyramid of\nDoom][POD]”: the situation where code marches to the right faster\nthan it marches forward.\n\n[POD]: http://calculist.org/blog/2011/12/14/why-coroutines-wont-work-on-the-web/\n\n```javascript\nstep1(function (value1) {\n step2(value1, function(value2) {\n step3(value2, function(value3) {\n step4(value3, function(value4) {\n // Do something with value4\n });\n });\n });\n});\n```\n\nWith a promise library, you can flatten the pyramid.\n\n```javascript\nQ.fcall(promisedStep1)\n.then(promisedStep2)\n.then(promisedStep3)\n.then(promisedStep4)\n.then(function (value4) {\n // Do something with value4\n})\n.catch(function (error) {\n // Handle any error from all above steps\n})\n.done();\n```\n\nWith this approach, you also get implicit error propagation, just like `try`,\n`catch`, and `finally`. An error in `promisedStep1` will flow all the way to\nthe `catch` function, where it’s caught and handled. (Here `promisedStepN` is\na version of `stepN` that returns a promise.)\n\nThe callback approach is called an “inversion of control”.\nA function that accepts a callback instead of a return value\nis saying, “Don’t call me, I’ll call you.”. Promises\n[un-invert][IOC] the inversion, cleanly separating the input\narguments from control flow arguments. This simplifies the\nuse and creation of API’s, particularly variadic,\nrest and spread arguments.\n\n[IOC]: http://www.slideshare.net/domenicdenicola/callbacks-promises-and-coroutines-oh-my-the-evolution-of-asynchronicity-in-javascript\n\n\n## Getting Started\n\nThe Q module can be loaded as:\n\n- A ``\n```\n\nUsing [npm](http://npmjs.org/):\n\n```bash\nnpm install lodash\n\nnpm install -g lodash\nnpm link lodash\n```\n\nIn [Node.js](http://nodejs.org/) and [RingoJS v0.8.0+](http://ringojs.org/):\n\n```js\nvar _ = require(\'lodash\');\n```\n\n**Note:** If Lo-Dash is installed globally, [run `npm link lodash`](http://blog.nodejs.org/2011/03/23/npm-1-0-global-vs-local-installation/) in your project’s root directory before requiring it.\n\nIn [RingoJS v0.7.0-](http://ringojs.org/):\n\n```js\nvar _ = require(\'lodash\')._;\n```\n\nIn [Rhino](http://www.mozilla.org/rhino/):\n\n```js\nload(\'lodash.js\');\n```\n\nIn an AMD loader like [RequireJS](http://requirejs.org/):\n\n```js\nrequire({\n \'paths\': {\n \'underscore\': \'path/to/lodash\'\n }\n},\n[\'underscore\'], function(_) {\n console.log(_.VERSION);\n});\n```\n\n## Resolved Underscore.js issues\n\n * Allow iteration of objects with a `length` property [[#799](https://github.com/documentcloud/underscore/pull/799), [test](https://github.com/lodash/lodash/blob/0.9.2/test/test.js#L545-551)]\n * Fix cross-browser object iteration bugs [[#60](https://github.com/documentcloud/underscore/issues/60), [#376](https://github.com/documentcloud/underscore/issues/376), [test](https://github.com/lodash/lodash/blob/0.9.2/test/test.js#L558-582)]\n * Methods should work on pages with incorrectly shimmed native methods [[#7](https://github.com/documentcloud/underscore/issues/7), [#742](https://github.com/documentcloud/underscore/issues/742), [test](https://github.com/lodash/lodash/blob/0.9.2/test/test.js#L140-146)]\n * `_.isEmpty` should support jQuery/MooTools DOM query collections [[#690](https://github.com/documentcloud/underscore/pull/690), [test](https://github.com/lodash/lodash/blob/0.9.2/test/test.js#L747-752)]\n * `_.isObject` should avoid V8 bug [#2291](http://code.google.com/p/8/issues/detail?id=2291) [[#605](https://github.com/documentcloud/underscore/issues/605), [test](https://github.com/lodash/lodash/blob/0.9.2/test/test.js#L828-840)]\n * `_.keys` should work with `arguments` objects cross-browser [[#396](https://github.com/documentcloud/underscore/issues/396), [test](https://github.com/lodash/lodash/blob/0.9.2/test/test.js#L921-923)]\n * `_.range` should coerce arguments to numbers [[#634](https://github.com/documentcloud/underscore/issues/634), [#683](https://github.com/documentcloud/underscore/issues/683), [test](https://github.com/lodash/lodash/blob/0.9.2/test/test.js#L1337-1340)]\n\n## Release Notes\n\n### v0.9.2\n\n * Added `fromIndex` argument to `_.contains`\n * Added `moduleId` build option\n * Added Closure Compiler *“simple”* optimizations to the build process\n * Added support for strings in `_.max` and `_.min`\n * Added support for ES6 template delimiters to `_.template`\n * Ensured re-minification of Lo-Dash by third parties avoids Closure Compiler bugs\n * Optimized `_.every`, `_.find`, `_.some`, and `_.uniq`\n\nThe full changelog is available [here](https://github.com/lodash/lodash/wiki/Changelog).\n\n## BestieJS\n\nLo-Dash is part of the [BestieJS](https://github.com/bestiejs) *“Best in Class”* module collection. This means we promote solid browser/environment support, ES5 precedents, unit testing, and plenty of documentation.\n\n## Author\n\n| [![twitter/jdalton](http://gravatar.com/avatar/299a3d891ff1920b69c364d061007043?s=70)](http://twitter.com/jdalton "Follow @jdalton on Twitter") |\n|---|\n| [John-David Dalton](http://allyoucanleet.com/) |\n\n## Contributors\n\n| [![twitter/blainebublitz](http://gravatar.com/avatar/ac1c67fd906c9fecd823ce302283b4c1?s=70)](http://twitter.com/blainebublitz "Follow @BlaineBublitz on Twitter") | [![twitter/kitcambridge](http://gravatar.com/avatar/6662a1d02f351b5ef2f8b4d815804661?s=70)](https://twitter.com/kitcambridge "Follow @kitcambridge on Twitter") | [![twitter/mathias](http://gravatar.com/avatar/24e08a9ea84deb17ae121074d0f17125?s=70)](http://twitter.com/mathias "Follow @mathias on Twitter") |\n|---|---|---|\n| [Blaine Bublitz](http://iceddev.com/) | [Kit Cambridge](http://kitcambridge.github.io/) | [Mathias Bynens](http://mathiasbynens.be/) |\n', +4697 silly resolved readmeFilename: 'README.md', +4697 silly resolved _id: 'lodash@0.9.2', +4697 silly resolved _from: 'lodash@0.9.2' } ] +4698 info install lodash@0.9.2 into /usr/lib/node_modules/grunt +4699 info installOne lodash@0.9.2 +4700 silly resolved [ { name: 'lodash', +4700 silly resolved version: '0.9.2', +4700 silly resolved description: 'A utility library delivering consistency, customization, performance, and extras.', +4700 silly resolved homepage: 'http://lodash.com', +4700 silly resolved license: 'MIT', +4700 silly resolved main: './lodash.js', +4700 silly resolved keywords: +4700 silly resolved [ 'browser', +4700 silly resolved 'client', +4700 silly resolved 'functional', +4700 silly resolved 'performance', +4700 silly resolved 'server', +4700 silly resolved 'speed', +4700 silly resolved 'util' ], +4700 silly resolved author: +4700 silly resolved { name: 'John-David Dalton', +4700 silly resolved email: 'john.david.dalton@gmail.com', +4700 silly resolved url: 'http://allyoucanleet.com/' }, +4700 silly resolved contributors: [ [Object], [Object], [Object], [Object] ], +4700 silly resolved bugs: { url: 'https://github.com/lodash/lodash/issues' }, +4700 silly resolved repository: { type: 'git', url: 'https://github.com/lodash/lodash.git' }, +4700 silly resolved engines: [ 'node', 'rhino' ], +4700 silly resolved jam: { main: './lodash.js' }, +4700 silly resolved readme: '# Lo-Dash v0.9.2\n\nA utility library delivering consistency, [customization](http://lodash.com/custom-builds), [performance](http://lodash.com/benchmarks), & [extras](http://lodash.com/#features).\n\n## Download\n\n * [Development build](https://raw.github.com/lodash/lodash/0.9.2/lodash.js)\n * [Production build](https://raw.github.com/lodash/lodash/0.9.2/lodash.min.js)\n * [Underscore build](https://raw.github.com/lodash/lodash/0.9.2/lodash.underscore.min.js) tailored for projects already using Underscore\n * CDN copies of ≤ v0.9.2’s [Production](http://cdnjs.cloudflare.com/ajax/libs/lodash.js/0.9.2/lodash.min.js), [Underscore](http://cdnjs.cloudflare.com/ajax/libs/lodash.js/0.9.2/lodash.underscore.min.js), and [Development](http://cdnjs.cloudflare.com/ajax/libs/lodash.js/0.9.2/lodash.js) builds are available on [cdnjs](http://cdnjs.com/) thanks to [CloudFlare](http://www.cloudflare.com/)\n * For optimal file size, [create a custom build](http://lodash.com/custom-builds) with only the features you need\n\n## Dive in\n\nWe’ve got [API docs](http://lodash.com/docs), [benchmarks](http://lodash.com/benchmarks), and [unit tests](http://lodash.com/tests).\n\nCreate your own benchmarks at [jsPerf](http://jsperf.com), or [search](http://jsperf.com/search?q=lodash) for existing ones.\n\nFor a list of upcoming features, check out our [roadmap](https://github.com/lodash/lodash/wiki/Roadmap).\n\n## Screencasts\n\nFor more information check out these screencasts over Lo-Dash:\n\n * [Introducing Lo-Dash](https://vimeo.com/44154599)\n * [Lo-Dash optimizations and custom builds](https://vimeo.com/44154601)\n * [Lo-Dash’s origin and why it’s a better utility belt](https://vimeo.com/44154600)\n * [Unit testing in Lo-Dash](https://vimeo.com/45865290)\n * [Lo-Dash’s approach to native method use](https://vimeo.com/48576012)\n\n## Features\n\n * AMD loader support ([RequireJS](http://requirejs.org/), [curl.js](https://github.com/cujojs/curl), etc.)\n * [_.clone](http://lodash.com/docs#clone) supports *“deep”* cloning\n * [_.contains](http://lodash.com/docs#contains) accepts a `fromIndex` argument\n * [_.forEach](http://lodash.com/docs#forEach) is chainable and supports exiting iteration early\n * [_.forIn](http://lodash.com/docs#forIn) for iterating over an object’s own and inherited properties\n * [_.forOwn](http://lodash.com/docs#forOwn) for iterating over an object’s own properties\n * [_.isPlainObject](http://lodash.com/docs#isPlainObject) checks if values are created by the `Object` constructor\n * [_.lateBind](http://lodash.com/docs#lateBind) for late binding\n * [_.merge](http://lodash.com/docs#merge) for a *“deep”* [_.extend](http://lodash.com/docs#extend)\n * [_.partial](http://lodash.com/docs#partial) for partial application without `this` binding\n * [_.pick](http://lodash.com/docs#pick) and [_.omit](http://lodash.com/docs#omit) accepts `callback` and `thisArg` arguments\n * [_.template](http://lodash.com/docs#template) supports [ES6 delimiters](http://people.mozilla.org/~jorendorff/es6-draft.html#sec-7.8.6) and utilizes [sourceURLs](http://www.html5rocks.com/en/tutorials/developertools/sourcemaps/#toc-sourceurl) for easier debugging\n * [_.contains](http://lodash.com/docs#contains), [_.size](http://lodash.com/docs#size), [_.toArray](http://lodash.com/docs#toArray),\n [and more…](http://lodash.com/docs "_.countBy, _.every, _.filter, _.find, _.forEach, _.groupBy, _.invoke, _.map, _.max, _.min, _.pluck, _.reduce, _.reduceRight, _.reject, _.shuffle, _.some, _.sortBy, _.where") accept strings\n\n## Support\n\nLo-Dash has been tested in at least Chrome 5~23, Firefox 1~16, IE 6-10, Opera 9.25-12, Safari 3-6, Node.js 0.4.8-0.8.14, Narwhal 0.3.2, RingoJS 0.8, and Rhino 1.7RC5.\n\n## Installation and usage\n\nIn browsers:\n\n```html\n\n```\n\nUsing [npm](http://npmjs.org/):\n\n```bash\nnpm install lodash\n\nnpm install -g lodash\nnpm link lodash\n```\n\nIn [Node.js](http://nodejs.org/) and [RingoJS v0.8.0+](http://ringojs.org/):\n\n```js\nvar _ = require(\'lodash\');\n```\n\n**Note:** If Lo-Dash is installed globally, [run `npm link lodash`](http://blog.nodejs.org/2011/03/23/npm-1-0-global-vs-local-installation/) in your project’s root directory before requiring it.\n\nIn [RingoJS v0.7.0-](http://ringojs.org/):\n\n```js\nvar _ = require(\'lodash\')._;\n```\n\nIn [Rhino](http://www.mozilla.org/rhino/):\n\n```js\nload(\'lodash.js\');\n```\n\nIn an AMD loader like [RequireJS](http://requirejs.org/):\n\n```js\nrequire({\n \'paths\': {\n \'underscore\': \'path/to/lodash\'\n }\n},\n[\'underscore\'], function(_) {\n console.log(_.VERSION);\n});\n```\n\n## Resolved Underscore.js issues\n\n * Allow iteration of objects with a `length` property [[#799](https://github.com/documentcloud/underscore/pull/799), [test](https://github.com/lodash/lodash/blob/0.9.2/test/test.js#L545-551)]\n * Fix cross-browser object iteration bugs [[#60](https://github.com/documentcloud/underscore/issues/60), [#376](https://github.com/documentcloud/underscore/issues/376), [test](https://github.com/lodash/lodash/blob/0.9.2/test/test.js#L558-582)]\n * Methods should work on pages with incorrectly shimmed native methods [[#7](https://github.com/documentcloud/underscore/issues/7), [#742](https://github.com/documentcloud/underscore/issues/742), [test](https://github.com/lodash/lodash/blob/0.9.2/test/test.js#L140-146)]\n * `_.isEmpty` should support jQuery/MooTools DOM query collections [[#690](https://github.com/documentcloud/underscore/pull/690), [test](https://github.com/lodash/lodash/blob/0.9.2/test/test.js#L747-752)]\n * `_.isObject` should avoid V8 bug [#2291](http://code.google.com/p/8/issues/detail?id=2291) [[#605](https://github.com/documentcloud/underscore/issues/605), [test](https://github.com/lodash/lodash/blob/0.9.2/test/test.js#L828-840)]\n * `_.keys` should work with `arguments` objects cross-browser [[#396](https://github.com/documentcloud/underscore/issues/396), [test](https://github.com/lodash/lodash/blob/0.9.2/test/test.js#L921-923)]\n * `_.range` should coerce arguments to numbers [[#634](https://github.com/documentcloud/underscore/issues/634), [#683](https://github.com/documentcloud/underscore/issues/683), [test](https://github.com/lodash/lodash/blob/0.9.2/test/test.js#L1337-1340)]\n\n## Release Notes\n\n### v0.9.2\n\n * Added `fromIndex` argument to `_.contains`\n * Added `moduleId` build option\n * Added Closure Compiler *“simple”* optimizations to the build process\n * Added support for strings in `_.max` and `_.min`\n * Added support for ES6 template delimiters to `_.template`\n * Ensured re-minification of Lo-Dash by third parties avoids Closure Compiler bugs\n * Optimized `_.every`, `_.find`, `_.some`, and `_.uniq`\n\nThe full changelog is available [here](https://github.com/lodash/lodash/wiki/Changelog).\n\n## BestieJS\n\nLo-Dash is part of the [BestieJS](https://github.com/bestiejs) *“Best in Class”* module collection. This means we promote solid browser/environment support, ES5 precedents, unit testing, and plenty of documentation.\n\n## Author\n\n| [![twitter/jdalton](http://gravatar.com/avatar/299a3d891ff1920b69c364d061007043?s=70)](http://twitter.com/jdalton "Follow @jdalton on Twitter") |\n|---|\n| [John-David Dalton](http://allyoucanleet.com/) |\n\n## Contributors\n\n| [![twitter/blainebublitz](http://gravatar.com/avatar/ac1c67fd906c9fecd823ce302283b4c1?s=70)](http://twitter.com/blainebublitz "Follow @BlaineBublitz on Twitter") | [![twitter/kitcambridge](http://gravatar.com/avatar/6662a1d02f351b5ef2f8b4d815804661?s=70)](https://twitter.com/kitcambridge "Follow @kitcambridge on Twitter") | [![twitter/mathias](http://gravatar.com/avatar/24e08a9ea84deb17ae121074d0f17125?s=70)](http://twitter.com/mathias "Follow @mathias on Twitter") |\n|---|---|---|\n| [Blaine Bublitz](http://iceddev.com/) | [Kit Cambridge](http://kitcambridge.github.io/) | [Mathias Bynens](http://mathiasbynens.be/) |\n', +4700 silly resolved readmeFilename: 'README.md', +4700 silly resolved _id: 'lodash@0.9.2', +4700 silly resolved _from: 'lodash@0.9.2' } ] +4701 info install lodash@0.9.2 into /usr/lib/node_modules/grunt/node_modules/grunt-legacy-util +4702 info installOne lodash@0.9.2 +4703 silly resolved [ { name: 'iconv-lite', +4703 silly resolved description: 'Convert character encodings in pure javascript.', +4703 silly resolved version: '0.2.11', +4703 silly resolved license: 'MIT', +4703 silly resolved keywords: [ 'iconv', 'convert', 'charset' ], +4703 silly resolved author: { name: 'Alexander Shtuchkin', email: 'ashtuchkin@gmail.com' }, +4703 silly resolved contributors: +4703 silly resolved [ [Object], +4703 silly resolved [Object], +4703 silly resolved [Object], +4703 silly resolved [Object], +4703 silly resolved [Object], +4703 silly resolved [Object], +4703 silly resolved [Object], +4703 silly resolved [Object], +4703 silly resolved [Object], +4703 silly resolved [Object] ], +4703 silly resolved main: 'index.js', +4703 silly resolved homepage: 'https://github.com/ashtuchkin/iconv-lite', +4703 silly resolved repository: +4703 silly resolved { type: 'git', +4703 silly resolved url: 'git://github.com/ashtuchkin/iconv-lite.git' }, +4703 silly resolved engines: { node: '>=0.4.0' }, +4703 silly resolved scripts: { test: 'vows --spec' }, +4703 silly resolved devDependencies: { vows: '', iconv: '>=1.1' }, +4703 silly resolved readme: 'iconv-lite - pure javascript character encoding conversion\n======================================================================\n\n[![Build Status](https://secure.travis-ci.org/ashtuchkin/iconv-lite.png?branch=master)](http://travis-ci.org/ashtuchkin/iconv-lite)\n\n## Features\n\n* Pure javascript. Doesn\'t need native code compilation.\n* Easy API.\n* Works on Windows and in sandboxed environments like [Cloud9](http://c9.io).\n* Encoding is much faster than node-iconv (see below for performance comparison).\n\n## Usage\n\n var iconv = require(\'iconv-lite\');\n \n // Convert from an encoded buffer to string.\n str = iconv.decode(buf, \'win1251\');\n \n // Convert from string to an encoded buffer.\n buf = iconv.encode("Sample input string", \'win1251\');\n\n // Check if encoding is supported\n iconv.encodingExists("us-ascii")\n\n\n## Supported encodings\n\n* All node.js native encodings: \'utf8\', \'ucs2\', \'ascii\', \'binary\', \'base64\'\n* All widespread single byte encodings: Windows 125x family, ISO-8859 family, \n IBM/DOS codepages, Macintosh family, KOI8 family. \n Aliases like \'latin1\', \'us-ascii\' also supported.\n* Multibyte encodings: \'gbk\', \'gb2313\', \'Big5\', \'cp950\'.\n\nOthers are easy to add, see the source. Please, participate.\nMost encodings are generated from node-iconv. Thank you Ben Noordhuis and iconv authors!\n\nNot supported yet: EUC family, Shift_JIS.\n\n\n## Encoding/decoding speed\n\nComparison with node-iconv module (1000x256kb, on Ubuntu 12.04, Core i5/2.5 GHz, Node v0.8.7). \nNote: your results may vary, so please always check on your hardware.\n\n operation iconv@1.2.4 iconv-lite@0.2.4 \n ----------------------------------------------------------\n encode(\'win1251\') ~115 Mb/s ~230 Mb/s\n decode(\'win1251\') ~95 Mb/s ~130 Mb/s\n\n\n## Notes\n\nWhen decoding, a \'binary\'-encoded string can be used as a source buffer. \nUntranslatable characters are set to � or ?. No transliteration is currently supported, pull requests are welcome.\n\n## Testing\n\n git clone git@github.com:ashtuchkin/iconv-lite.git\n cd iconv-lite\n npm install\n npm test\n \n # To view performance:\n node test/performance.js\n\n## TODO\n\n* Support streaming character conversion, something like util.pipe(req, iconv.fromEncodingStream(\'latin1\')).\n* Add more encodings.\n* Add transliteration (best fit char).\n* Add tests and correct support of variable-byte encodings (currently work is delegated to node).\n', +4703 silly resolved readmeFilename: 'README.md', +4703 silly resolved bugs: { url: 'https://github.com/ashtuchkin/iconv-lite/issues' }, +4703 silly resolved _id: 'iconv-lite@0.2.11', +4703 silly resolved _from: 'iconv-lite@0.2.11' } ] +4704 info install iconv-lite@0.2.11 into /usr/lib/node_modules/grunt +4705 info installOne iconv-lite@0.2.11 +4706 silly resolved [ { name: 'underscore.string', +4706 silly resolved version: '2.2.1', +4706 silly resolved description: 'String manipulation extensions for Underscore.js javascript library.', +4706 silly resolved homepage: 'http://epeli.github.com/underscore.string/', +4706 silly resolved contributors: +4706 silly resolved [ [Object], +4706 silly resolved [Object], +4706 silly resolved [Object], +4706 silly resolved [Object], +4706 silly resolved [Object], +4706 silly resolved [Object], +4706 silly resolved [Object], +4706 silly resolved [Object] ], +4706 silly resolved keywords: [ 'underscore', 'string' ], +4706 silly resolved main: './lib/underscore.string', +4706 silly resolved directories: { lib: './lib' }, +4706 silly resolved engines: { node: '*' }, +4706 silly resolved repository: +4706 silly resolved { type: 'git', +4706 silly resolved url: 'https://github.com/epeli/underscore.string.git' }, +4706 silly resolved bugs: { url: 'https://github.com/epeli/underscore.string/issues' }, +4706 silly resolved licenses: [ [Object] ], +4706 silly resolved readme: '# Underscore.string [![Build Status](https://secure.travis-ci.org/epeli/underscore.string.png?branch=master)](http://travis-ci.org/epeli/underscore.string) #\n\n\n\nJavascript lacks complete string manipulation operations.\nThis an attempt to fill that gap. List of build-in methods can be found\nfor example from [Dive Into JavaScript][d].\n\n[d]: http://www.diveintojavascript.com/core-javascript-reference/the-string-object\n\n\nAs name states this an extension for [Underscore.js][u], but it can be used\nindependently from **_s**-global variable. But with Underscore.js you can\nuse Object-Oriented style and chaining:\n\n[u]: http://documentcloud.github.com/underscore/\n\n```javascript\n_(" epeli ").chain().trim().capitalize().value()\n=> "Epeli"\n```\n\n## Download ##\n\n * [Development version](https://raw.github.com/epeli/underscore.string/master/lib/underscore.string.js) *Uncompressed with Comments 18kb*\n * [Production version](https://github.com/epeli/underscore.string/raw/master/dist/underscore.string.min.js) *Minified 7kb*\n\n\n## Node.js installation ##\n\n**npm package**\n\n npm install underscore.string\n\n**Standalone usage**:\n\n```javascript\nvar _s = require(\'underscore.string\');\n```\n\n**Integrate with Underscore.js**:\n\n```javascript\nvar _ = require(\'underscore\');\n\n// Import Underscore.string to separate object, because there are conflict functions (include, reverse, contains)\n_.str = require(\'underscore.string\');\n\n// Mix in non-conflict functions to Underscore namespace if you want\n_.mixin(_.str.exports());\n\n// All functions, include conflict, will be available through _.str object\n_.str.include(\'Underscore.string\', \'string\'); // => true\n```\n\n## String Functions ##\n\nFor availability of functions in this way you need to mix in Underscore.string functions:\n\n```javascript\n_.mixin(_.string.exports());\n```\n\notherwise functions from examples will be available through _.string or _.str objects:\n\n```javascript\n_.str.capitalize(\'epeli\')\n=> "Epeli"\n```\n\n**capitalize** _.capitalize(string)\n\nConverts first letter of the string to uppercase.\n\n```javascript\n_.capitalize("foo Bar")\n=> "Foo Bar"\n```\n\n**chop** _.chop(string, step)\n\n```javascript\n_.chop(\'whitespace\', 3)\n=> [\'whi\',\'tes\',\'pac\',\'e\']\n```\n\n**clean** _.clean(str)\n\nCompress some whitespaces to one.\n\n```javascript\n_.clean(" foo bar ")\n=> \'foo bar\'\n```\n\n**chars** _.chars(str)\n\n```javascript\n_.chars(\'Hello\')\n=> [\'H\',\'e\',\'l\',\'l\',\'o\']\n```\n\n**includes** _.includes(string, substring)\n\nTests if string contains a substring.\n\n```javascript\n_.includes("foobar", "ob")\n=> true\n```\n\n**include** available only through _.str object, because Underscore has function with the same name.\n\n```javascript\n_.str.include("foobar", "ob")\n=> true\n```\n\n**includes** function was removed\n\nBut you can create it in this way, for compatibility with previous versions:\n\n```javascript\n_.includes = _.str.include\n```\n\n**count** _.count(string, substring)\n\n```javascript\n_(\'Hello world\').count(\'l\')\n=> 3\n```\n\n**escapeHTML** _.escapeHTML(string)\n\nConverts HTML special characters to their entity equivalents.\n\n```javascript\n_(\'
    Blah blah blah
    \').escapeHTML();\n=> \'<div>Blah blah blah</div>\'\n```\n\n**unescapeHTML** _.unescapeHTML(string)\n\nConverts entity characters to HTML equivalents.\n\n```javascript\n_(\'<div>Blah blah blah</div>\').unescapeHTML();\n=> \'
    Blah blah blah
    \'\n```\n\n**insert** _.insert(string, index, substing)\n\n```javascript\n_(\'Hello \').insert(6, \'world\')\n=> \'Hello world\'\n```\n\n**isBlank** _.isBlank(string)\n\n```javascript\n_(\'\').isBlank(); // => true\n_(\'\\n\').isBlank(); // => true\n_(\' \').isBlank(); // => true\n_(\'a\').isBlank(); // => false\n```\n\n**join** _.join(separator, *strings)\n\nJoins strings together with given separator\n\n```javascript\n_.join(" ", "foo", "bar")\n=> "foo bar"\n```\n\n**lines** _.lines(str)\n\n```javascript\n_.lines("Hello\\nWorld")\n=> ["Hello", "World"]\n```\n\n**reverse** available only through _.str object, because Underscore has function with the same name.\n\nReturn reversed string:\n\n```javascript\n_.str.reverse("foobar")\n=> \'raboof\'\n```\n\n**splice** _.splice(string, index, howmany, substring)\n\nLike a array splice.\n\n```javascript\n_(\'https://edtsech@bitbucket.org/edtsech/underscore.strings\').splice(30, 7, \'epeli\')\n=> \'https://edtsech@bitbucket.org/epeli/underscore.strings\'\n```\n\n**startsWith** _.startsWith(string, starts)\n\nThis method checks whether string starts with starts.\n\n```javascript\n_("image.gif").startsWith("image")\n=> true\n```\n\n**endsWith** _.endsWith(string, ends)\n\nThis method checks whether string ends with ends.\n\n```javascript\n_("image.gif").endsWith("gif")\n=> true\n```\n\n**succ** _.succ(str)\n\nReturns the successor to str.\n\n```javascript\n_(\'a\').succ()\n=> \'b\'\n\n_(\'A\').succ()\n=> \'B\'\n```\n\n**supplant**\n\nSupplant function was removed, use Underscore.js [template function][p].\n\n[p]: http://documentcloud.github.com/underscore/#template\n\n**strip** alias for *trim*\n\n**lstrip** alias for *ltrim*\n\n**rstrip** alias for *rtrim*\n\n**titleize** _.titleize(string)\n\n```javascript\n_(\'my name is epeli\').titleize()\n=> \'My Name Is Epeli\'\n```\n\n**camelize** _.camelize(string)\n\nConverts underscored or dasherized string to a camelized one\n\n```javascript\n_(\'-moz-transform\').camelize()\n=> \'MozTransform\'\n```\n\n**classify** _.classify(string)\n\nConverts string to camelized class name\n\n```javascript\n_(\'some_class_name\').classify()\n=> \'SomeClassName\'\n```\n\n**underscored** _.underscored(string)\n\nConverts a camelized or dasherized string into an underscored one\n\n```javascript\n_(\'MozTransform\').underscored()\n=> \'moz_transform\'\n```\n\n**dasherize** _.dasherize(string)\n\nConverts a underscored or camelized string into an dasherized one\n\n```javascript\n_(\'MozTransform\').dasherize()\n=> \'-moz-transform\'\n```\n\n**humanize** _.humanize(string)\n\nConverts an underscored, camelized, or dasherized string into a humanized one.\nAlso removes beginning and ending whitespace, and removes the postfix \'_id\'.\n\n```javascript\n_(\' capitalize dash-CamelCase_underscore trim \').humanize()\n=> \'Capitalize dash camel case underscore trim\'\n```\n\n**trim** _.trim(string, [characters])\n\ntrims defined characters from begining and ending of the string.\nDefaults to whitespace characters.\n\n```javascript\n_.trim(" foobar ")\n=> "foobar"\n\n_.trim("_-foobar-_", "_-")\n=> "foobar"\n```\n\n\n**ltrim** _.ltrim(string, [characters])\n\nLeft trim. Similar to trim, but only for left side.\n\n\n**rtrim** _.rtrim(string, [characters])\n\nRight trim. Similar to trim, but only for right side.\n\n**truncate** _.truncate(string, length, truncateString)\n\n```javascript\n_(\'Hello world\').truncate(5)\n=> \'Hello...\'\n\n_(\'Hello\').truncate(10)\n=> \'Hello\'\n```\n\n**prune** _.prune(string, length, pruneString)\n\nElegant version of truncate.\nMakes sure the pruned string does not exceed the original length.\nAvoid half-chopped words when truncating.\n\n```javascript\n_(\'Hello, world\').prune(5)\n=> \'Hello...\'\n\n_(\'Hello, world\').prune(8)\n=> \'Hello...\'\n\n_(\'Hello, world\').prune(5, \' (read a lot more)\')\n=> \'Hello, world\' (as adding "(read a lot more)" would be longer than the original string)\n\n_(\'Hello, cruel world\').prune(15)\n=> \'Hello, cruel...\'\n\n_(\'Hello\').prune(10)\n=> \'Hello\'\n```\n\n**words** _.words(str, delimiter=" ")\n\nSplit string by delimiter (String or RegExp), \' \' by default.\n\n```javascript\n_.words("I love you")\n=> ["I","love","you"]\n\n_.words("I_love_you", "_")\n=> ["I","love","you"]\n\n_.words("I-love-you", /-/)\n=> ["I","love","you"]\n```\n\n**sprintf** _.sprintf(string format, *arguments)\n\nC like string formatting.\nCredits goes to [Alexandru Marasteanu][o].\nFor more detailed documentation, see the [original page][o].\n\n[o]: http://www.diveintojavascript.com/projects/sprintf-for-javascript\n\n```javascript\n_.sprintf("%.1f", 1.17)\n"1.2"\n```\n\n**pad** _.pad(str, length, [padStr, type])\n\npads the `str` with characters until the total string length is equal to the passed `length` parameter. By default, pads on the **left** with the space char (`" "`). `padStr` is truncated to a single character if necessary.\n\n```javascript\n_.pad("1", 8)\n-> " 1";\n\n_.pad("1", 8, \'0\')\n-> "00000001";\n\n_.pad("1", 8, \'0\', \'right\')\n-> "10000000";\n\n_.pad("1", 8, \'0\', \'both\')\n-> "00001000";\n\n_.pad("1", 8, \'bleepblorp\', \'both\')\n-> "bbbb1bbb";\n```\n\n**lpad** _.lpad(str, length, [padStr])\n\nleft-pad a string. Alias for `pad(str, length, padStr, \'left\')`\n\n```javascript\n_.lpad("1", 8, \'0\')\n-> "00000001";\n```\n\n**rpad** _.rpad(str, length, [padStr])\n\nright-pad a string. Alias for `pad(str, length, padStr, \'right\')`\n\n```javascript\n_.rpad("1", 8, \'0\')\n-> "10000000";\n```\n\n**lrpad** _.lrpad(str, length, [padStr])\n\nleft/right-pad a string. Alias for `pad(str, length, padStr, \'both\')`\n\n```javascript\n_.lrpad("1", 8, \'0\')\n-> "00001000";\n```\n\n**center** alias for **lrpad**\n\n**ljust** alias for *rpad*\n\n**rjust** alias for *lpad*\n\n**toNumber** _.toNumber(string, [decimals])\n\nParse string to number. Returns NaN if string can\'t be parsed to number.\n\n```javascript\n_(\'2.556\').toNumber()\n=> 3\n\n_(\'2.556\').toNumber(1)\n=> 2.6\n```\n\n**strRight** _.strRight(string, pattern)\n\nSearches a string from left to right for a pattern and returns a substring consisting of the characters in the string that are to the right of the pattern or all string if no match found.\n\n```javascript\n_(\'This_is_a_test_string\').strRight(\'_\')\n=> "is_a_test_string";\n```\n\n**strRightBack** _.strRightBack(string, pattern)\n\nSearches a string from right to left for a pattern and returns a substring consisting of the characters in the string that are to the right of the pattern or all string if no match found.\n\n```javascript\n_(\'This_is_a_test_string\').strRightBack(\'_\')\n=> "string";\n```\n\n**strLeft** _.strLeft(string, pattern)\n\nSearches a string from left to right for a pattern and returns a substring consisting of the characters in the string that are to the left of the pattern or all string if no match found.\n\n```javascript\n_(\'This_is_a_test_string\').strLeft(\'_\')\n=> "This";\n```\n\n**strLeftBack** _.strLeftBack(string, pattern)\n\nSearches a string from right to left for a pattern and returns a substring consisting of the characters in the string that are to the left of the pattern or all string if no match found.\n\n```javascript\n_(\'This_is_a_test_string\').strLeftBack(\'_\')\n=> "This_is_a_test";\n```\n\n**stripTags**\n\nRemoves all html tags from string.\n\n```javascript\n_(\'a link\').stripTags()\n=> \'a link\'\n\n_(\'a link\').stripTags()\n=> \'a linkalert("hello world!")\'\n```\n\n**toSentence** _.toSentence(array, [delimiter, lastDelimiter])\n\nJoin an array into a human readable sentence.\n\n```javascript\n_.toSentence([\'jQuery\', \'Mootools\', \'Prototype\'])\n=> \'jQuery, Mootools and Prototype\';\n\n_.toSentence([\'jQuery\', \'Mootools\', \'Prototype\'], \', \', \' unt \')\n=> \'jQuery, Mootools unt Prototype\';\n```\n\n**repeat** _.repeat(string, count, [separator])\n\nRepeats a string count times.\n\n```javascript\n_.repeat("foo", 3)\n=> \'foofoofoo\';\n\n_.repeat("foo", 3, "bar")\n=> \'foobarfoobarfoo\'\n```\n\n**slugify** _.slugify(string)\n\nTransform text into a URL slug. Replaces whitespaces, accentuated, and special characters with a dash.\n\n```javascript\n_.slugify("Un éléphant à l\'orée du bois")\n=> \'un-elephant-a-loree-du-bois\';\n```\n\n***Caution: this function is charset dependent***\n\n## Roadmap ##\n\nAny suggestions or bug reports are welcome. Just email me or more preferably open an issue.\n\n## Changelog ##\n\n### 2.0.0 ###\n\n* Added prune, humanize functions\n* Added _.string (_.str) namespace for Underscore.string library\n* Removed includes function\n\n#### Problems\n\nWe lose two things for `include` and `reverse` methods from `_.string`:\n\n* Calls like `_(\'foobar\').include(\'bar\')` aren\'t available;\n* Chaining isn\'t available too.\n\nBut if you need this functionality you can create aliases for conflict functions which will be convenient for you:\n\n```javascript\n_.mixin({\n includeString: _.str.include,\n reverseString: _.str.reverse\n})\n\n// Now wrapper calls and chaining are available.\n_(\'foobar\').chain().reverseString().includeString(\'rab\').value()\n```\n\n#### Standalone Usage\n\nIf you are using Underscore.string without Underscore. You also have `_.string` namespace for it and `_.str` alias\nBut of course you can just reassign `_` variable with `_.string`\n\n```javascript\n_ = _.string\n```\n### 2.2.0 ###\n\n* Capitalize method behavior changed\n* Various perfomance tweaks\n\n### 2.1.1###\n\n* Fixed words method bug\n* Added classify method\n\n### 2.1.0 ###\n\n* AMD support\n* Added toSentence method\n* Added slugify method\n* Lots of speed optimizations\n\n### 2.0.0 ###\n\nFor upgrading to this version you need to mix in Underscore.string library to Underscore object:\n\n```javascript\n_.mixin(_.string.exports());\n```\n\nand all non-conflict Underscore.string functions will be available through Underscore object.\nAlso function `includes` has been removed, you should replace this function by `_.str.include`\nor create alias `_.includes = _.str.include` and all your code will work fine.\n\n### 1.1.6 ###\n\n* Fixed reverse and truncate\n* Added isBlank, stripTags, inlude(alias for includes)\n* Added uglifier compression\n\n### 1.1.5 ###\n\n* Added strRight, strRightBack, strLeft, strLeftBack\n\n### 1.1.4 ###\n\n* Added pad, lpad, rpad, lrpad methods and aliases center, ljust, rjust\n* Integration with Underscore 1.1.6\n\n### 1.1.3 ###\n\n* Added methods: underscored, camelize, dasherize\n* Support newer version of npm\n\n### 1.1.2 ###\n\n* Created functions: lines, chars, words functions\n\n### 1.0.2 ###\n\n* Created integration test suite with underscore.js 1.1.4 (now it\'s absolutely compatible)\n* Removed \'reverse\' function, because this function override underscore.js \'reverse\'\n\n## Contribute ##\n\n* Fork & pull request. Don\'t forget about tests.\n* If you planning add some feature please create issue before.\n\nOtherwise changes will be rejected.\n\n## Contributors list ##\n\n* Esa-Matti Suuronen (),\n* Edward Tsech ,\n* Sasha Koss (),\n* Vladimir Dronnikov ,\n* Pete Kruckenberg (),\n* Paul Chavard (),\n* Ed Finkler ()\n* Pavel Pravosud \n* Anton Lindqvist ()\n\n## Licence ##\n\nThe MIT License\n\nCopyright (c) 2011 Esa-Matti Suuronen esa-matti@suuronen.org\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the "Software"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in\nall copies 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\nTHE SOFTWARE.\n', +4706 silly resolved readmeFilename: 'README.markdown', +4706 silly resolved _id: 'underscore.string@2.2.1', +4706 silly resolved _from: 'underscore.string@2.2.1' } ] +4707 info install underscore.string@2.2.1 into /usr/lib/node_modules/grunt +4708 info installOne underscore.string@2.2.1 +4709 silly resolved [ { name: 'underscore.string', +4709 silly resolved version: '2.2.1', +4709 silly resolved description: 'String manipulation extensions for Underscore.js javascript library.', +4709 silly resolved homepage: 'http://epeli.github.com/underscore.string/', +4709 silly resolved contributors: +4709 silly resolved [ [Object], +4709 silly resolved [Object], +4709 silly resolved [Object], +4709 silly resolved [Object], +4709 silly resolved [Object], +4709 silly resolved [Object], +4709 silly resolved [Object], +4709 silly resolved [Object] ], +4709 silly resolved keywords: [ 'underscore', 'string' ], +4709 silly resolved main: './lib/underscore.string', +4709 silly resolved directories: { lib: './lib' }, +4709 silly resolved engines: { node: '*' }, +4709 silly resolved repository: +4709 silly resolved { type: 'git', +4709 silly resolved url: 'https://github.com/epeli/underscore.string.git' }, +4709 silly resolved bugs: { url: 'https://github.com/epeli/underscore.string/issues' }, +4709 silly resolved licenses: [ [Object] ], +4709 silly resolved readme: '# Underscore.string [![Build Status](https://secure.travis-ci.org/epeli/underscore.string.png?branch=master)](http://travis-ci.org/epeli/underscore.string) #\n\n\n\nJavascript lacks complete string manipulation operations.\nThis an attempt to fill that gap. List of build-in methods can be found\nfor example from [Dive Into JavaScript][d].\n\n[d]: http://www.diveintojavascript.com/core-javascript-reference/the-string-object\n\n\nAs name states this an extension for [Underscore.js][u], but it can be used\nindependently from **_s**-global variable. But with Underscore.js you can\nuse Object-Oriented style and chaining:\n\n[u]: http://documentcloud.github.com/underscore/\n\n```javascript\n_(" epeli ").chain().trim().capitalize().value()\n=> "Epeli"\n```\n\n## Download ##\n\n * [Development version](https://raw.github.com/epeli/underscore.string/master/lib/underscore.string.js) *Uncompressed with Comments 18kb*\n * [Production version](https://github.com/epeli/underscore.string/raw/master/dist/underscore.string.min.js) *Minified 7kb*\n\n\n## Node.js installation ##\n\n**npm package**\n\n npm install underscore.string\n\n**Standalone usage**:\n\n```javascript\nvar _s = require(\'underscore.string\');\n```\n\n**Integrate with Underscore.js**:\n\n```javascript\nvar _ = require(\'underscore\');\n\n// Import Underscore.string to separate object, because there are conflict functions (include, reverse, contains)\n_.str = require(\'underscore.string\');\n\n// Mix in non-conflict functions to Underscore namespace if you want\n_.mixin(_.str.exports());\n\n// All functions, include conflict, will be available through _.str object\n_.str.include(\'Underscore.string\', \'string\'); // => true\n```\n\n## String Functions ##\n\nFor availability of functions in this way you need to mix in Underscore.string functions:\n\n```javascript\n_.mixin(_.string.exports());\n```\n\notherwise functions from examples will be available through _.string or _.str objects:\n\n```javascript\n_.str.capitalize(\'epeli\')\n=> "Epeli"\n```\n\n**capitalize** _.capitalize(string)\n\nConverts first letter of the string to uppercase.\n\n```javascript\n_.capitalize("foo Bar")\n=> "Foo Bar"\n```\n\n**chop** _.chop(string, step)\n\n```javascript\n_.chop(\'whitespace\', 3)\n=> [\'whi\',\'tes\',\'pac\',\'e\']\n```\n\n**clean** _.clean(str)\n\nCompress some whitespaces to one.\n\n```javascript\n_.clean(" foo bar ")\n=> \'foo bar\'\n```\n\n**chars** _.chars(str)\n\n```javascript\n_.chars(\'Hello\')\n=> [\'H\',\'e\',\'l\',\'l\',\'o\']\n```\n\n**includes** _.includes(string, substring)\n\nTests if string contains a substring.\n\n```javascript\n_.includes("foobar", "ob")\n=> true\n```\n\n**include** available only through _.str object, because Underscore has function with the same name.\n\n```javascript\n_.str.include("foobar", "ob")\n=> true\n```\n\n**includes** function was removed\n\nBut you can create it in this way, for compatibility with previous versions:\n\n```javascript\n_.includes = _.str.include\n```\n\n**count** _.count(string, substring)\n\n```javascript\n_(\'Hello world\').count(\'l\')\n=> 3\n```\n\n**escapeHTML** _.escapeHTML(string)\n\nConverts HTML special characters to their entity equivalents.\n\n```javascript\n_(\'
    Blah blah blah
    \').escapeHTML();\n=> \'<div>Blah blah blah</div>\'\n```\n\n**unescapeHTML** _.unescapeHTML(string)\n\nConverts entity characters to HTML equivalents.\n\n```javascript\n_(\'<div>Blah blah blah</div>\').unescapeHTML();\n=> \'
    Blah blah blah
    \'\n```\n\n**insert** _.insert(string, index, substing)\n\n```javascript\n_(\'Hello \').insert(6, \'world\')\n=> \'Hello world\'\n```\n\n**isBlank** _.isBlank(string)\n\n```javascript\n_(\'\').isBlank(); // => true\n_(\'\\n\').isBlank(); // => true\n_(\' \').isBlank(); // => true\n_(\'a\').isBlank(); // => false\n```\n\n**join** _.join(separator, *strings)\n\nJoins strings together with given separator\n\n```javascript\n_.join(" ", "foo", "bar")\n=> "foo bar"\n```\n\n**lines** _.lines(str)\n\n```javascript\n_.lines("Hello\\nWorld")\n=> ["Hello", "World"]\n```\n\n**reverse** available only through _.str object, because Underscore has function with the same name.\n\nReturn reversed string:\n\n```javascript\n_.str.reverse("foobar")\n=> \'raboof\'\n```\n\n**splice** _.splice(string, index, howmany, substring)\n\nLike a array splice.\n\n```javascript\n_(\'https://edtsech@bitbucket.org/edtsech/underscore.strings\').splice(30, 7, \'epeli\')\n=> \'https://edtsech@bitbucket.org/epeli/underscore.strings\'\n```\n\n**startsWith** _.startsWith(string, starts)\n\nThis method checks whether string starts with starts.\n\n```javascript\n_("image.gif").startsWith("image")\n=> true\n```\n\n**endsWith** _.endsWith(string, ends)\n\nThis method checks whether string ends with ends.\n\n```javascript\n_("image.gif").endsWith("gif")\n=> true\n```\n\n**succ** _.succ(str)\n\nReturns the successor to str.\n\n```javascript\n_(\'a\').succ()\n=> \'b\'\n\n_(\'A\').succ()\n=> \'B\'\n```\n\n**supplant**\n\nSupplant function was removed, use Underscore.js [template function][p].\n\n[p]: http://documentcloud.github.com/underscore/#template\n\n**strip** alias for *trim*\n\n**lstrip** alias for *ltrim*\n\n**rstrip** alias for *rtrim*\n\n**titleize** _.titleize(string)\n\n```javascript\n_(\'my name is epeli\').titleize()\n=> \'My Name Is Epeli\'\n```\n\n**camelize** _.camelize(string)\n\nConverts underscored or dasherized string to a camelized one\n\n```javascript\n_(\'-moz-transform\').camelize()\n=> \'MozTransform\'\n```\n\n**classify** _.classify(string)\n\nConverts string to camelized class name\n\n```javascript\n_(\'some_class_name\').classify()\n=> \'SomeClassName\'\n```\n\n**underscored** _.underscored(string)\n\nConverts a camelized or dasherized string into an underscored one\n\n```javascript\n_(\'MozTransform\').underscored()\n=> \'moz_transform\'\n```\n\n**dasherize** _.dasherize(string)\n\nConverts a underscored or camelized string into an dasherized one\n\n```javascript\n_(\'MozTransform\').dasherize()\n=> \'-moz-transform\'\n```\n\n**humanize** _.humanize(string)\n\nConverts an underscored, camelized, or dasherized string into a humanized one.\nAlso removes beginning and ending whitespace, and removes the postfix \'_id\'.\n\n```javascript\n_(\' capitalize dash-CamelCase_underscore trim \').humanize()\n=> \'Capitalize dash camel case underscore trim\'\n```\n\n**trim** _.trim(string, [characters])\n\ntrims defined characters from begining and ending of the string.\nDefaults to whitespace characters.\n\n```javascript\n_.trim(" foobar ")\n=> "foobar"\n\n_.trim("_-foobar-_", "_-")\n=> "foobar"\n```\n\n\n**ltrim** _.ltrim(string, [characters])\n\nLeft trim. Similar to trim, but only for left side.\n\n\n**rtrim** _.rtrim(string, [characters])\n\nRight trim. Similar to trim, but only for right side.\n\n**truncate** _.truncate(string, length, truncateString)\n\n```javascript\n_(\'Hello world\').truncate(5)\n=> \'Hello...\'\n\n_(\'Hello\').truncate(10)\n=> \'Hello\'\n```\n\n**prune** _.prune(string, length, pruneString)\n\nElegant version of truncate.\nMakes sure the pruned string does not exceed the original length.\nAvoid half-chopped words when truncating.\n\n```javascript\n_(\'Hello, world\').prune(5)\n=> \'Hello...\'\n\n_(\'Hello, world\').prune(8)\n=> \'Hello...\'\n\n_(\'Hello, world\').prune(5, \' (read a lot more)\')\n=> \'Hello, world\' (as adding "(read a lot more)" would be longer than the original string)\n\n_(\'Hello, cruel world\').prune(15)\n=> \'Hello, cruel...\'\n\n_(\'Hello\').prune(10)\n=> \'Hello\'\n```\n\n**words** _.words(str, delimiter=" ")\n\nSplit string by delimiter (String or RegExp), \' \' by default.\n\n```javascript\n_.words("I love you")\n=> ["I","love","you"]\n\n_.words("I_love_you", "_")\n=> ["I","love","you"]\n\n_.words("I-love-you", /-/)\n=> ["I","love","you"]\n```\n\n**sprintf** _.sprintf(string format, *arguments)\n\nC like string formatting.\nCredits goes to [Alexandru Marasteanu][o].\nFor more detailed documentation, see the [original page][o].\n\n[o]: http://www.diveintojavascript.com/projects/sprintf-for-javascript\n\n```javascript\n_.sprintf("%.1f", 1.17)\n"1.2"\n```\n\n**pad** _.pad(str, length, [padStr, type])\n\npads the `str` with characters until the total string length is equal to the passed `length` parameter. By default, pads on the **left** with the space char (`" "`). `padStr` is truncated to a single character if necessary.\n\n```javascript\n_.pad("1", 8)\n-> " 1";\n\n_.pad("1", 8, \'0\')\n-> "00000001";\n\n_.pad("1", 8, \'0\', \'right\')\n-> "10000000";\n\n_.pad("1", 8, \'0\', \'both\')\n-> "00001000";\n\n_.pad("1", 8, \'bleepblorp\', \'both\')\n-> "bbbb1bbb";\n```\n\n**lpad** _.lpad(str, length, [padStr])\n\nleft-pad a string. Alias for `pad(str, length, padStr, \'left\')`\n\n```javascript\n_.lpad("1", 8, \'0\')\n-> "00000001";\n```\n\n**rpad** _.rpad(str, length, [padStr])\n\nright-pad a string. Alias for `pad(str, length, padStr, \'right\')`\n\n```javascript\n_.rpad("1", 8, \'0\')\n-> "10000000";\n```\n\n**lrpad** _.lrpad(str, length, [padStr])\n\nleft/right-pad a string. Alias for `pad(str, length, padStr, \'both\')`\n\n```javascript\n_.lrpad("1", 8, \'0\')\n-> "00001000";\n```\n\n**center** alias for **lrpad**\n\n**ljust** alias for *rpad*\n\n**rjust** alias for *lpad*\n\n**toNumber** _.toNumber(string, [decimals])\n\nParse string to number. Returns NaN if string can\'t be parsed to number.\n\n```javascript\n_(\'2.556\').toNumber()\n=> 3\n\n_(\'2.556\').toNumber(1)\n=> 2.6\n```\n\n**strRight** _.strRight(string, pattern)\n\nSearches a string from left to right for a pattern and returns a substring consisting of the characters in the string that are to the right of the pattern or all string if no match found.\n\n```javascript\n_(\'This_is_a_test_string\').strRight(\'_\')\n=> "is_a_test_string";\n```\n\n**strRightBack** _.strRightBack(string, pattern)\n\nSearches a string from right to left for a pattern and returns a substring consisting of the characters in the string that are to the right of the pattern or all string if no match found.\n\n```javascript\n_(\'This_is_a_test_string\').strRightBack(\'_\')\n=> "string";\n```\n\n**strLeft** _.strLeft(string, pattern)\n\nSearches a string from left to right for a pattern and returns a substring consisting of the characters in the string that are to the left of the pattern or all string if no match found.\n\n```javascript\n_(\'This_is_a_test_string\').strLeft(\'_\')\n=> "This";\n```\n\n**strLeftBack** _.strLeftBack(string, pattern)\n\nSearches a string from right to left for a pattern and returns a substring consisting of the characters in the string that are to the left of the pattern or all string if no match found.\n\n```javascript\n_(\'This_is_a_test_string\').strLeftBack(\'_\')\n=> "This_is_a_test";\n```\n\n**stripTags**\n\nRemoves all html tags from string.\n\n```javascript\n_(\'a link\').stripTags()\n=> \'a link\'\n\n_(\'a link\').stripTags()\n=> \'a linkalert("hello world!")\'\n```\n\n**toSentence** _.toSentence(array, [delimiter, lastDelimiter])\n\nJoin an array into a human readable sentence.\n\n```javascript\n_.toSentence([\'jQuery\', \'Mootools\', \'Prototype\'])\n=> \'jQuery, Mootools and Prototype\';\n\n_.toSentence([\'jQuery\', \'Mootools\', \'Prototype\'], \', \', \' unt \')\n=> \'jQuery, Mootools unt Prototype\';\n```\n\n**repeat** _.repeat(string, count, [separator])\n\nRepeats a string count times.\n\n```javascript\n_.repeat("foo", 3)\n=> \'foofoofoo\';\n\n_.repeat("foo", 3, "bar")\n=> \'foobarfoobarfoo\'\n```\n\n**slugify** _.slugify(string)\n\nTransform text into a URL slug. Replaces whitespaces, accentuated, and special characters with a dash.\n\n```javascript\n_.slugify("Un éléphant à l\'orée du bois")\n=> \'un-elephant-a-loree-du-bois\';\n```\n\n***Caution: this function is charset dependent***\n\n## Roadmap ##\n\nAny suggestions or bug reports are welcome. Just email me or more preferably open an issue.\n\n## Changelog ##\n\n### 2.0.0 ###\n\n* Added prune, humanize functions\n* Added _.string (_.str) namespace for Underscore.string library\n* Removed includes function\n\n#### Problems\n\nWe lose two things for `include` and `reverse` methods from `_.string`:\n\n* Calls like `_(\'foobar\').include(\'bar\')` aren\'t available;\n* Chaining isn\'t available too.\n\nBut if you need this functionality you can create aliases for conflict functions which will be convenient for you:\n\n```javascript\n_.mixin({\n includeString: _.str.include,\n reverseString: _.str.reverse\n})\n\n// Now wrapper calls and chaining are available.\n_(\'foobar\').chain().reverseString().includeString(\'rab\').value()\n```\n\n#### Standalone Usage\n\nIf you are using Underscore.string without Underscore. You also have `_.string` namespace for it and `_.str` alias\nBut of course you can just reassign `_` variable with `_.string`\n\n```javascript\n_ = _.string\n```\n### 2.2.0 ###\n\n* Capitalize method behavior changed\n* Various perfomance tweaks\n\n### 2.1.1###\n\n* Fixed words method bug\n* Added classify method\n\n### 2.1.0 ###\n\n* AMD support\n* Added toSentence method\n* Added slugify method\n* Lots of speed optimizations\n\n### 2.0.0 ###\n\nFor upgrading to this version you need to mix in Underscore.string library to Underscore object:\n\n```javascript\n_.mixin(_.string.exports());\n```\n\nand all non-conflict Underscore.string functions will be available through Underscore object.\nAlso function `includes` has been removed, you should replace this function by `_.str.include`\nor create alias `_.includes = _.str.include` and all your code will work fine.\n\n### 1.1.6 ###\n\n* Fixed reverse and truncate\n* Added isBlank, stripTags, inlude(alias for includes)\n* Added uglifier compression\n\n### 1.1.5 ###\n\n* Added strRight, strRightBack, strLeft, strLeftBack\n\n### 1.1.4 ###\n\n* Added pad, lpad, rpad, lrpad methods and aliases center, ljust, rjust\n* Integration with Underscore 1.1.6\n\n### 1.1.3 ###\n\n* Added methods: underscored, camelize, dasherize\n* Support newer version of npm\n\n### 1.1.2 ###\n\n* Created functions: lines, chars, words functions\n\n### 1.0.2 ###\n\n* Created integration test suite with underscore.js 1.1.4 (now it\'s absolutely compatible)\n* Removed \'reverse\' function, because this function override underscore.js \'reverse\'\n\n## Contribute ##\n\n* Fork & pull request. Don\'t forget about tests.\n* If you planning add some feature please create issue before.\n\nOtherwise changes will be rejected.\n\n## Contributors list ##\n\n* Esa-Matti Suuronen (),\n* Edward Tsech ,\n* Sasha Koss (),\n* Vladimir Dronnikov ,\n* Pete Kruckenberg (),\n* Paul Chavard (),\n* Ed Finkler ()\n* Pavel Pravosud \n* Anton Lindqvist ()\n\n## Licence ##\n\nThe MIT License\n\nCopyright (c) 2011 Esa-Matti Suuronen esa-matti@suuronen.org\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the "Software"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in\nall copies 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\nTHE SOFTWARE.\n', +4709 silly resolved readmeFilename: 'README.markdown', +4709 silly resolved _id: 'underscore.string@2.2.1', +4709 silly resolved _from: 'underscore.string@2.2.1' } ] +4710 info install underscore.string@2.2.1 into /usr/lib/node_modules/grunt/node_modules/grunt-legacy-util +4711 info installOne underscore.string@2.2.1 +4712 silly resolved [ { name: 'js-yaml', +4712 silly resolved version: '2.0.5', +4712 silly resolved description: 'YAML 1.2 parser and serializer', +4712 silly resolved keywords: [ 'yaml', 'parser', 'serializer', 'pyyaml' ], +4712 silly resolved homepage: 'https://github.com/nodeca/js-yaml', +4712 silly resolved author: { name: 'Dervus Grim', email: 'dervus@lavabit.com' }, +4712 silly resolved contributors: [ [Object], [Object] ], +4712 silly resolved bugs: { url: 'https://github.com/nodeca/js-yaml/issues' }, +4712 silly resolved license: +4712 silly resolved { type: 'MIT', +4712 silly resolved url: 'https://github.com/nodeca/js-yaml/blob/master/LICENSE' }, +4712 silly resolved repository: { type: 'git', url: 'git://github.com/nodeca/js-yaml.git' }, +4712 silly resolved main: './index.js', +4712 silly resolved bin: { 'js-yaml': 'bin/js-yaml.js' }, +4712 silly resolved scripts: { test: 'make test' }, +4712 silly resolved dependencies: { argparse: '~ 0.1.11', esprima: '~ 1.0.2' }, +4712 silly resolved devDependencies: { mocha: '*' }, +4712 silly resolved engines: { node: '>= 0.6.0' }, +4712 silly resolved readme: 'JS-YAML - YAML 1.2 parser and serializer for JavaScript\n=======================================================\n\n[![Build Status](https://secure.travis-ci.org/nodeca/js-yaml.png)](http://travis-ci.org/nodeca/js-yaml)\n\n[Online Demo](http://nodeca.github.com/js-yaml/)\n\n\nThis is an implementation of [YAML](http://yaml.org/), a human friendly data\nserialization language. Started as [PyYAML](http://pyyaml.org/) port, it was\ncompletely rewritten from scratch. Now it\'s very fast, and supports 1.2 spec.\n\n\nBreaking changes in 1.x.x -> 2.0.x\n----------------------------------\n\nIf your have not used __custom__ tags or loader classes - no changes needed. Just\nupgrade library and enjoy high parse speed.\n\nIn other case, you should rewrite your tag constructors and custom loader\nclasses, to conform new schema-based API. See\n[examples](https://github.com/nodeca/js-yaml/tree/master/examples) and\n[wiki](https://github.com/nodeca/js-yaml/wiki) for details.\nNote, that parser internals were completely rewritten.\n\n\nInstallation\n------------\n\n### YAML module for node.js\n\n```\nnpm install js-yaml\n```\n\n\n### CLI executable\n\nIf you want to inspect your YAML files from CLI, install js-yaml globally:\n\n```\nnpm install js-yaml -g\n```\n\n#### Usage\n\n```\nusage: js-yaml [-h] [-v] [-c] [-j] [-t] file\n\nPositional arguments:\n file File with YAML document(s)\n\nOptional arguments:\n -h, --help Show this help message and exit.\n -v, --version Show program\'s version number and exit.\n -c, --compact Display errors in compact mode\n -j, --to-json Output a non-funky boring JSON\n -t, --trace Show stack trace on error\n```\n\n\n### Bundled YAML library for browsers\n\n``` html\n\n\n```\n\nBrowser support was done mostly for online demo. If you find any errors - feel\nfree to send pull requests with fixes. Also note, that IE and other old browsers\nneeds [es5-shims](https://github.com/kriskowal/es5-shim) to operate.\n\n\nAPI\n---\n\nHere we cover the most \'useful\' methods. If you need advanced details (creating\nyour own tags), see [wiki](https://github.com/nodeca/js-yaml/wiki) and\n[examples](https://github.com/nodeca/js-yaml/tree/master/examples) for more\ninfo.\n\nIn node.js JS-YAML automatically registers handlers for `.yml` and `.yaml`\nfiles. You can load them just with `require`. That\'s mostly equivalent to\ncalling `load()` on fetched content of a file. Just with one string!\n\n``` javascript\nrequire(\'js-yaml\');\n\n// Get document, or throw exception on error\ntry {\n var doc = require(\'/home/ixti/example.yml\');\n console.log(doc);\n} catch (e) {\n console.log(e);\n}\n```\n\n\n### load (string [ , options ])\n\nParses `string` as single YAML document. Returns a JavaScript object or throws\n`YAMLException` on error.\n\nNOTE: This function **does not** understands multi-document sources, it throws\nexception on those.\n\noptions:\n\n- `filename` _(default: null)_ - string to be used as a file path in\n error/warning messages.\n- `strict` _(default - false)_ makes the loader to throw errors instead of\n warnings.\n- `schema` _(default: `DEFAULT_SCHEMA`)_ - specifies a schema to use.\n\n\n### loadAll (string, iterator [ , options ])\n\nSame as `load()`, but understands multi-document sources and apply `iterator` to\neach document.\n\n``` javascript\nvar yaml = require(\'js-yaml\');\n\nyaml.loadAll(data, function (doc) {\n console.log(doc);\n});\n```\n\n\n### safeLoad (string [ , options ])\n\nSame as `load()` but uses `SAFE_SCHEMA` by default - only recommended tags of\nYAML specification (no JavaScript-specific tags, e.g. `!!js/regexp`).\n\n\n### safeLoadAll (string, iterator [ , options ])\n\nSame as `loadAll()` but uses `SAFE_SCHEMA` by default - only recommended tags of\nYAML specification (no JavaScript-specific tags, e.g. `!!js/regexp`).\n\n\n### dump (object [ , options ])\n\nSerializes `object` as YAML document.\n\noptions:\n\n- `indent` _(default: 2)_ - indentation width to use (in spaces).\n- `flowLevel` (default: -1) - specifies level of nesting, when to switch from\n block to flow style for collections. -1 means block style everwhere\n- `styles` - "tag" => "style" map. Each tag may have own set of styles.\n- `schema` _(default: `DEFAULT_SCHEMA`)_ specifies a schema to use.\n\nstyles:\n\n``` none\n!!null\n "canonical" => "~"\n\n!!int\n "binary" => "0b1", "0b101010", "0b1110001111010"\n "octal" => "01", "052", "016172"\n "decimal" => "1", "42", "7290"\n "hexadecimal" => "0x1", "0x2A", "0x1C7A"\n\n!!null, !!bool, !!float\n "lowercase" => "null", "true", "false", ".nan", \'.inf\'\n "uppercase" => "NULL", "TRUE", "FALSE", ".NAN", \'.INF\'\n "camelcase" => "Null", "True", "False", ".NaN", \'.Inf\'\n```\n\nBy default, !!int uses `decimal`, and !!null, !!bool, !!float use `lowercase`.\n\n\n### safeDump (object [ , options ])\n\nSame as `dump()` but uses `SAFE_SCHEMA` by default - only recommended tags of\nYAML specification (no JavaScript-specific tags, e.g. `!!js/regexp`).\n\n\nSupported YAML types\n--------------------\n\nThe list of standard YAML tags and corresponding JavaScipt types. See also\n[YAML tag discussion](http://pyyaml.org/wiki/YAMLTagDiscussion) and\n[YAML types repository](http://yaml.org/type/).\n\n```\n!!null \'\' # null\n!!bool \'yes\' # bool\n!!int \'3...\' # number\n!!float \'3.14...\' # number\n!!binary \'...base64...\' # buffer\n!!timestamp \'YYYY-...\' # date\n!!omap [ ... ] # array of key-value pairs\n!!pairs [ ... ] # array or array pairs\n!!set { ... } # array of objects with given keys and null values\n!!str \'...\' # string\n!!seq [ ... ] # array\n!!map { ... } # object\n```\n\n**JavaScript-specific tags**\n\n```\n!!js/regexp /pattern/gim # RegExp\n!!js/undefined \'\' # Undefined\n!!js/function \'function () {...}\' # Function\n```\n\n\n\n\n## Caveats\n\nNote, that you use arrays or objects as key in JS-YAML. JS do not allows objects\nor array as keys, and stringifies (by calling .toString method) them at the\nmoment of adding them.\n\n``` yaml\n---\n? [ foo, bar ]\n: - baz\n? { foo: bar }\n: - baz\n - baz\n```\n\n``` javascript\n{ "foo,bar": ["baz"], "[object Object]": ["baz", "baz"] }\n```\n\nAlso, reading of properties on implicit block mapping keys is not supported yet.\nSo, the following YAML document cannot be loaded.\n\n``` yaml\n&anchor foo:\n foo: bar\n *anchor: duplicate key\n baz: bat\n *anchor: duplicate key\n```\n\n## License\n\nView the [LICENSE](https://github.com/nodeca/js-yaml/blob/master/LICENSE) file\n(MIT).\n', +4712 silly resolved readmeFilename: 'README.md', +4712 silly resolved _id: 'js-yaml@2.0.5', +4712 silly resolved _from: 'js-yaml@2.0.5' } ] +4713 info install js-yaml@2.0.5 into /usr/lib/node_modules/grunt +4714 info installOne js-yaml@2.0.5 +4715 silly resolved [ { name: 'jsdom', +4715 silly resolved version: '0.8.11', +4715 silly resolved description: 'A JavaScript implementation of the W3C DOM', +4715 silly resolved keywords: [ 'dom', 'w3c', 'html' ], +4715 silly resolved maintainers: [ [Object], [Object] ], +4715 silly resolved contributors: +4715 silly resolved [ [Object], +4715 silly resolved [Object], +4715 silly resolved [Object], +4715 silly resolved [Object], +4715 silly resolved [Object], +4715 silly resolved [Object], +4715 silly resolved [Object], +4715 silly resolved [Object], +4715 silly resolved [Object], +4715 silly resolved [Object], +4715 silly resolved [Object], +4715 silly resolved [Object], +4715 silly resolved [Object], +4715 silly resolved [Object], +4715 silly resolved [Object], +4715 silly resolved [Object], +4715 silly resolved [Object], +4715 silly resolved [Object], +4715 silly resolved [Object], +4715 silly resolved [Object], +4715 silly resolved [Object], +4715 silly resolved [Object], +4715 silly resolved [Object], +4715 silly resolved [Object], +4715 silly resolved [Object], +4715 silly resolved [Object], +4715 silly resolved [Object], +4715 silly resolved [Object], +4715 silly resolved [Object], +4715 silly resolved [Object], +4715 silly resolved [Object], +4715 silly resolved [Object], +4715 silly resolved [Object], +4715 silly resolved [Object], +4715 silly resolved [Object] ], +4715 silly resolved bugs: +4715 silly resolved { url: 'http://github.com/tmpvar/jsdom/issues', +4715 silly resolved email: 'tmpvar@gmail.com' }, +4715 silly resolved license: +4715 silly resolved { type: 'MIT', +4715 silly resolved url: 'http://github.com/tmpvar/jsdom/blob/master/LICENSE.txt' }, +4715 silly resolved repository: { type: 'git', url: 'git://github.com/tmpvar/jsdom.git' }, +4715 silly resolved implements: [ 'http://www.w3.org/TR/REC-DOM-Level-1' ], +4715 silly resolved dependencies: +4715 silly resolved { htmlparser2: '>= 3.1.5 <4', +4715 silly resolved nwmatcher: '~1.3.1', +4715 silly resolved request: '2.x', +4715 silly resolved xmlhttprequest: '>=1.5.0', +4715 silly resolved cssom: '~0.3.0', +4715 silly resolved cssstyle: '~0.2.9', +4715 silly resolved contextify: '~0.1.5' }, +4715 silly resolved devDependencies: { nodeunit: '~0.8.0', optimist: '*', urlmaster: '>=0.2.15' }, +4715 silly resolved scripts: { test: 'node ./test/runner' }, +4715 silly resolved main: './lib/jsdom', +4715 silly resolved readme: '# jsdom\n\nA JavaScript implementation of the W3C DOM.\n\n## Install\n\n```bash\n$ npm install jsdom\n```\n\nIf this gives you trouble with errors about installing Contextify, especially on Windows, see [below](#contextify).\n\n## Human contact\n\nsee: [mailing list](http://groups.google.com/group/jsdom)\n\n## Easymode\n\nBootstrapping a DOM is generally a difficult process involving many error prone steps. We didn\'t want jsdom to fall into the same trap and that is why a new method, `jsdom.env()`, has been added in jsdom 0.2.0 which should make everyone\'s lives easier.\n\nYou can use it with a URL\n\n```js\n// Count all of the links from the Node.js build page\nvar jsdom = require("jsdom");\n\njsdom.env(\n "http://nodejs.org/dist/",\n ["http://code.jquery.com/jquery.js"],\n function (errors, window) {\n console.log("there have been", window.$("a").length, "nodejs releases!");\n }\n);\n```\n\nor with raw HTML\n\n```js\n// Run some jQuery on a html fragment\nvar jsdom = require("jsdom");\n\njsdom.env(\n \'

    jsdom\\\'s Homepage

    \',\n ["http://code.jquery.com/jquery.js"],\n function (errors, window) {\n console.log("contents of a.the-link:", window.$("a.the-link").text());\n }\n);\n```\n\nor with a configuration object\n\n```js\n// Print all of the news items on hackernews\nvar jsdom = require("jsdom");\n\njsdom.env({\n url: "http://news.ycombinator.com/",\n scripts: ["http://code.jquery.com/jquery.js"],\n done: function (errors, window) {\n var $ = window.$;\n console.log("HN Links");\n $("td.title:not(:last) a").each(function() {\n console.log(" -", $(this).text());\n });\n }\n});\n```\n\nor with raw JavaScript source\n\n```js\n// Print all of the news items on hackernews\nvar jsdom = require("jsdom");\nvar fs = require("fs");\nvar jquery = fs.readFileSync("./jquery.js", "utf-8");\n\njsdom.env({\n url: "http://news.ycombinator.com/",\n src: [jquery],\n done: function (errors, window) {\n var $ = window.$;\n console.log("HN Links");\n $("td.title:not(:last) a").each(function () {\n console.log(" -", $(this).text());\n });\n }\n});\n```\n\n### How it works\n`jsdom.env` is built for ease of use, which is rare in the world of the DOM! Since the web has some absolutely horrible JavaScript on it, as of jsdom 0.2.0 `jsdom.env` will not process external resources (scripts, images, etc). If you want to process the JavaScript use one of the methods below (`jsdom.jsdom` or `jsdom.jQueryify`)\n\n```js\njsdom.env(string, [scripts], [config], callback);\n```\n\nThe arguments are:\n\n- `string`: may be a URL, file name, or HTML fragment\n- `scripts`: a string or array of strings, containing file names or URLs that will be inserted as `\n \n\n\n## Documentation\n\n### Collections\n\n* [forEach](#forEach)\n* [map](#map)\n* [filter](#filter)\n* [reject](#reject)\n* [reduce](#reduce)\n* [detect](#detect)\n* [sortBy](#sortBy)\n* [some](#some)\n* [every](#every)\n* [concat](#concat)\n\n### Control Flow\n\n* [series](#series)\n* [parallel](#parallel)\n* [whilst](#whilst)\n* [until](#until)\n* [waterfall](#waterfall)\n* [queue](#queue)\n* [auto](#auto)\n* [iterator](#iterator)\n* [apply](#apply)\n* [nextTick](#nextTick)\n\n### Utils\n\n* [memoize](#memoize)\n* [unmemoize](#unmemoize)\n* [log](#log)\n* [dir](#dir)\n* [noConflict](#noConflict)\n\n\n## Collections\n\n\n### forEach(arr, iterator, callback)\n\nApplies an iterator function to each item in an array, in parallel.\nThe iterator is called with an item from the list and a callback for when it\nhas finished. If the iterator passes an error to this callback, the main\ncallback for the forEach function is immediately called with the error.\n\nNote, that since this function applies the iterator to each item in parallel\nthere is no guarantee that the iterator functions will complete in order.\n\n__Arguments__\n\n* arr - An array to iterate over.\n* iterator(item, callback) - A function to apply to each item in the array.\n The iterator is passed a callback which must be called once it has completed.\n* callback(err) - A callback which is called after all the iterator functions\n have finished, or an error has occurred.\n\n__Example__\n\n // assuming openFiles is an array of file names and saveFile is a function\n // to save the modified contents of that file:\n\n async.forEach(openFiles, saveFile, function(err){\n // if any of the saves produced an error, err would equal that error\n });\n\n---------------------------------------\n\n\n### forEachSeries(arr, iterator, callback)\n\nThe same as forEach only the iterator is applied to each item in the array in\nseries. The next iterator is only called once the current one has completed\nprocessing. This means the iterator functions will complete in order.\n\n\n---------------------------------------\n\n\n### forEachLimit(arr, limit, iterator, callback)\n\nThe same as forEach only the iterator is applied to batches of items in the\narray, in series. The next batch of iterators is only called once the current\none has completed processing.\n\n__Arguments__\n\n* arr - An array to iterate over.\n* limit - How many items should be in each batch.\n* iterator(item, callback) - A function to apply to each item in the array.\n The iterator is passed a callback which must be called once it has completed.\n* callback(err) - A callback which is called after all the iterator functions\n have finished, or an error has occurred.\n\n__Example__\n\n // Assume documents is an array of JSON objects and requestApi is a\n // function that interacts with a rate-limited REST api.\n\n async.forEachLimit(documents, 20, requestApi, function(err){\n // if any of the saves produced an error, err would equal that error\n });\n---------------------------------------\n\n\n### map(arr, iterator, callback)\n\nProduces a new array of values by mapping each value in the given array through\nthe iterator function. The iterator is called with an item from the array and a\ncallback for when it has finished processing. The callback takes 2 arguments, \nan error and the transformed item from the array. If the iterator passes an\nerror to this callback, the main callback for the map function is immediately\ncalled with the error.\n\nNote, that since this function applies the iterator to each item in parallel\nthere is no guarantee that the iterator functions will complete in order, however\nthe results array will be in the same order as the original array.\n\n__Arguments__\n\n* arr - An array to iterate over.\n* iterator(item, callback) - A function to apply to each item in the array.\n The iterator is passed a callback which must be called once it has completed\n with an error (which can be null) and a transformed item.\n* callback(err, results) - A callback which is called after all the iterator\n functions have finished, or an error has occurred. Results is an array of the\n transformed items from the original array.\n\n__Example__\n\n async.map([\'file1\',\'file2\',\'file3\'], fs.stat, function(err, results){\n // results is now an array of stats for each file\n });\n\n---------------------------------------\n\n\n### mapSeries(arr, iterator, callback)\n\nThe same as map only the iterator is applied to each item in the array in\nseries. The next iterator is only called once the current one has completed\nprocessing. The results array will be in the same order as the original.\n\n\n---------------------------------------\n\n\n### filter(arr, iterator, callback)\n\n__Alias:__ select\n\nReturns a new array of all the values which pass an async truth test.\n_The callback for each iterator call only accepts a single argument of true or\nfalse, it does not accept an error argument first!_ This is in-line with the\nway node libraries work with truth tests like path.exists. This operation is\nperformed in parallel, but the results array will be in the same order as the\noriginal.\n\n__Arguments__\n\n* arr - An array to iterate over.\n* iterator(item, callback) - A truth test to apply to each item in the array.\n The iterator is passed a callback which must be called once it has completed.\n* callback(results) - A callback which is called after all the iterator\n functions have finished.\n\n__Example__\n\n async.filter([\'file1\',\'file2\',\'file3\'], path.exists, function(results){\n // results now equals an array of the existing files\n });\n\n---------------------------------------\n\n\n### filterSeries(arr, iterator, callback)\n\n__alias:__ selectSeries\n\nThe same as filter only the iterator is applied to each item in the array in\nseries. The next iterator is only called once the current one has completed\nprocessing. The results array will be in the same order as the original.\n\n---------------------------------------\n\n\n### reject(arr, iterator, callback)\n\nThe opposite of filter. Removes values that pass an async truth test.\n\n---------------------------------------\n\n\n### rejectSeries(arr, iterator, callback)\n\nThe same as filter, only the iterator is applied to each item in the array\nin series.\n\n\n---------------------------------------\n\n\n### reduce(arr, memo, iterator, callback)\n\n__aliases:__ inject, foldl\n\nReduces a list of values into a single value using an async iterator to return\neach successive step. Memo is the initial state of the reduction. This\nfunction only operates in series. For performance reasons, it may make sense to\nsplit a call to this function into a parallel map, then use the normal\nArray.prototype.reduce on the results. This function is for situations where\neach step in the reduction needs to be async, if you can get the data before\nreducing it then its probably a good idea to do so.\n\n__Arguments__\n\n* arr - An array to iterate over.\n* memo - The initial state of the reduction.\n* iterator(memo, item, callback) - A function applied to each item in the\n array to produce the next step in the reduction. The iterator is passed a\n callback which accepts an optional error as its first argument, and the state\n of the reduction as the second. If an error is passed to the callback, the\n reduction is stopped and the main callback is immediately called with the\n error.\n* callback(err, result) - A callback which is called after all the iterator\n functions have finished. Result is the reduced value.\n\n__Example__\n\n async.reduce([1,2,3], 0, function(memo, item, callback){\n // pointless async:\n process.nextTick(function(){\n callback(null, memo + item)\n });\n }, function(err, result){\n // result is now equal to the last value of memo, which is 6\n });\n\n---------------------------------------\n\n\n### reduceRight(arr, memo, iterator, callback)\n\n__Alias:__ foldr\n\nSame as reduce, only operates on the items in the array in reverse order.\n\n\n---------------------------------------\n\n\n### detect(arr, iterator, callback)\n\nReturns the first value in a list that passes an async truth test. The\niterator is applied in parallel, meaning the first iterator to return true will\nfire the detect callback with that result. That means the result might not be\nthe first item in the original array (in terms of order) that passes the test.\n\nIf order within the original array is important then look at detectSeries.\n\n__Arguments__\n\n* arr - An array to iterate over.\n* iterator(item, callback) - A truth test to apply to each item in the array.\n The iterator is passed a callback which must be called once it has completed.\n* callback(result) - A callback which is called as soon as any iterator returns\n true, or after all the iterator functions have finished. Result will be\n the first item in the array that passes the truth test (iterator) or the\n value undefined if none passed.\n\n__Example__\n\n async.detect([\'file1\',\'file2\',\'file3\'], path.exists, function(result){\n // result now equals the first file in the list that exists\n });\n\n---------------------------------------\n\n\n### detectSeries(arr, iterator, callback)\n\nThe same as detect, only the iterator is applied to each item in the array\nin series. This means the result is always the first in the original array (in\nterms of array order) that passes the truth test.\n\n\n---------------------------------------\n\n\n### sortBy(arr, iterator, callback)\n\nSorts a list by the results of running each value through an async iterator.\n\n__Arguments__\n\n* arr - An array to iterate over.\n* iterator(item, callback) - A function to apply to each item in the array.\n The iterator is passed a callback which must be called once it has completed\n with an error (which can be null) and a value to use as the sort criteria.\n* callback(err, results) - A callback which is called after all the iterator\n functions have finished, or an error has occurred. Results is the items from\n the original array sorted by the values returned by the iterator calls.\n\n__Example__\n\n async.sortBy([\'file1\',\'file2\',\'file3\'], function(file, callback){\n fs.stat(file, function(err, stats){\n callback(err, stats.mtime);\n });\n }, function(err, results){\n // results is now the original array of files sorted by\n // modified date\n });\n\n\n---------------------------------------\n\n\n### some(arr, iterator, callback)\n\n__Alias:__ any\n\nReturns true if at least one element in the array satisfies an async test.\n_The callback for each iterator call only accepts a single argument of true or\nfalse, it does not accept an error argument first!_ This is in-line with the\nway node libraries work with truth tests like path.exists. Once any iterator\ncall returns true, the main callback is immediately called.\n\n__Arguments__\n\n* arr - An array to iterate over.\n* iterator(item, callback) - A truth test to apply to each item in the array.\n The iterator is passed a callback which must be called once it has completed.\n* callback(result) - A callback which is called as soon as any iterator returns\n true, or after all the iterator functions have finished. Result will be\n either true or false depending on the values of the async tests.\n\n__Example__\n\n async.some([\'file1\',\'file2\',\'file3\'], path.exists, function(result){\n // if result is true then at least one of the files exists\n });\n\n---------------------------------------\n\n\n### every(arr, iterator, callback)\n\n__Alias:__ all\n\nReturns true if every element in the array satisfies an async test.\n_The callback for each iterator call only accepts a single argument of true or\nfalse, it does not accept an error argument first!_ This is in-line with the\nway node libraries work with truth tests like path.exists.\n\n__Arguments__\n\n* arr - An array to iterate over.\n* iterator(item, callback) - A truth test to apply to each item in the array.\n The iterator is passed a callback which must be called once it has completed.\n* callback(result) - A callback which is called after all the iterator\n functions have finished. Result will be either true or false depending on\n the values of the async tests.\n\n__Example__\n\n async.every([\'file1\',\'file2\',\'file3\'], path.exists, function(result){\n // if result is true then every file exists\n });\n\n---------------------------------------\n\n\n### concat(arr, iterator, callback)\n\nApplies an iterator to each item in a list, concatenating the results. Returns the\nconcatenated list. The iterators are called in parallel, and the results are\nconcatenated as they return. There is no guarantee that the results array will\nbe returned in the original order of the arguments passed to the iterator function.\n\n__Arguments__\n\n* arr - An array to iterate over\n* iterator(item, callback) - A function to apply to each item in the array.\n The iterator is passed a callback which must be called once it has completed\n with an error (which can be null) and an array of results.\n* callback(err, results) - A callback which is called after all the iterator\n functions have finished, or an error has occurred. Results is an array containing\n the concatenated results of the iterator function.\n\n__Example__\n\n async.concat([\'dir1\',\'dir2\',\'dir3\'], fs.readdir, function(err, files){\n // files is now a list of filenames that exist in the 3 directories\n });\n\n---------------------------------------\n\n\n### concatSeries(arr, iterator, callback)\n\nSame as async.concat, but executes in series instead of parallel.\n\n\n## Control Flow\n\n\n### series(tasks, [callback])\n\nRun an array of functions in series, each one running once the previous\nfunction has completed. If any functions in the series pass an error to its\ncallback, no more functions are run and the callback for the series is\nimmediately called with the value of the error. Once the tasks have completed,\nthe results are passed to the final callback as an array.\n\nIt is also possible to use an object instead of an array. Each property will be\nrun as a function and the results will be passed to the final callback as an object\ninstead of an array. This can be a more readable way of handling results from\nasync.series.\n\n\n__Arguments__\n\n* tasks - An array or object containing functions to run, each function is passed\n a callback it must call on completion.\n* callback(err, results) - An optional callback to run once all the functions\n have completed. This function gets an array of all the arguments passed to\n the callbacks used in the array.\n\n__Example__\n\n async.series([\n function(callback){\n // do some stuff ...\n callback(null, \'one\');\n },\n function(callback){\n // do some more stuff ...\n callback(null, \'two\');\n },\n ],\n // optional callback\n function(err, results){\n // results is now equal to [\'one\', \'two\']\n });\n\n\n // an example using an object instead of an array\n async.series({\n one: function(callback){\n setTimeout(function(){\n callback(null, 1);\n }, 200);\n },\n two: function(callback){\n setTimeout(function(){\n callback(null, 2);\n }, 100);\n },\n },\n function(err, results) {\n // results is now equal to: {one: 1, two: 2}\n });\n\n\n---------------------------------------\n\n\n### parallel(tasks, [callback])\n\nRun an array of functions in parallel, without waiting until the previous\nfunction has completed. If any of the functions pass an error to its\ncallback, the main callback is immediately called with the value of the error.\nOnce the tasks have completed, the results are passed to the final callback as an\narray.\n\nIt is also possible to use an object instead of an array. Each property will be\nrun as a function and the results will be passed to the final callback as an object\ninstead of an array. This can be a more readable way of handling results from\nasync.parallel.\n\n\n__Arguments__\n\n* tasks - An array or object containing functions to run, each function is passed a\n callback it must call on completion.\n* callback(err, results) - An optional callback to run once all the functions\n have completed. This function gets an array of all the arguments passed to\n the callbacks used in the array.\n\n__Example__\n\n async.parallel([\n function(callback){\n setTimeout(function(){\n callback(null, \'one\');\n }, 200);\n },\n function(callback){\n setTimeout(function(){\n callback(null, \'two\');\n }, 100);\n },\n ],\n // optional callback\n function(err, results){\n // the results array will equal [\'one\',\'two\'] even though\n // the second function had a shorter timeout.\n });\n\n\n // an example using an object instead of an array\n async.parallel({\n one: function(callback){\n setTimeout(function(){\n callback(null, 1);\n }, 200);\n },\n two: function(callback){\n setTimeout(function(){\n callback(null, 2);\n }, 100);\n },\n },\n function(err, results) {\n // results is now equals to: {one: 1, two: 2}\n });\n\n\n---------------------------------------\n\n\n### whilst(test, fn, callback)\n\nRepeatedly call fn, while test returns true. Calls the callback when stopped,\nor an error occurs.\n\n__Arguments__\n\n* test() - synchronous truth test to perform before each execution of fn.\n* fn(callback) - A function to call each time the test passes. The function is\n passed a callback which must be called once it has completed with an optional\n error as the first argument.\n* callback(err) - A callback which is called after the test fails and repeated\n execution of fn has stopped.\n\n__Example__\n\n var count = 0;\n\n async.whilst(\n function () { return count < 5; },\n function (callback) {\n count++;\n setTimeout(callback, 1000);\n },\n function (err) {\n // 5 seconds have passed\n }\n );\n\n\n---------------------------------------\n\n\n### until(test, fn, callback)\n\nRepeatedly call fn, until test returns true. Calls the callback when stopped,\nor an error occurs.\n\nThe inverse of async.whilst.\n\n\n---------------------------------------\n\n\n### waterfall(tasks, [callback])\n\nRuns an array of functions in series, each passing their results to the next in\nthe array. However, if any of the functions pass an error to the callback, the\nnext function is not executed and the main callback is immediately called with\nthe error.\n\n__Arguments__\n\n* tasks - An array of functions to run, each function is passed a callback it\n must call on completion.\n* callback(err, [results]) - An optional callback to run once all the functions\n have completed. This will be passed the results of the last task\'s callback.\n\n\n\n__Example__\n\n async.waterfall([\n function(callback){\n callback(null, \'one\', \'two\');\n },\n function(arg1, arg2, callback){\n callback(null, \'three\');\n },\n function(arg1, callback){\n // arg1 now equals \'three\'\n callback(null, \'done\');\n }\n ], function (err, result) {\n // result now equals \'done\' \n });\n\n\n---------------------------------------\n\n\n### queue(worker, concurrency)\n\nCreates a queue object with the specified concurrency. Tasks added to the\nqueue will be processed in parallel (up to the concurrency limit). If all\nworkers are in progress, the task is queued until one is available. Once\na worker has completed a task, the task\'s callback is called.\n\n__Arguments__\n\n* worker(task, callback) - An asynchronous function for processing a queued\n task.\n* concurrency - An integer for determining how many worker functions should be\n run in parallel.\n\n__Queue objects__\n\nThe queue object returned by this function has the following properties and\nmethods:\n\n* length() - a function returning the number of items waiting to be processed.\n* concurrency - an integer for determining how many worker functions should be\n run in parallel. This property can be changed after a queue is created to\n alter the concurrency on-the-fly.\n* push(task, [callback]) - add a new task to the queue, the callback is called\n once the worker has finished processing the task.\n instead of a single task, an array of tasks can be submitted. the respective callback is used for every task in the list.\n* saturated - a callback that is called when the queue length hits the concurrency and further tasks will be queued\n* empty - a callback that is called when the last item from the queue is given to a worker\n* drain - a callback that is called when the last item from the queue has returned from the worker\n\n__Example__\n\n // create a queue object with concurrency 2\n\n var q = async.queue(function (task, callback) {\n console.log(\'hello \' + task.name);\n callback();\n }, 2);\n\n\n // assign a callback\n q.drain = function() {\n console.log(\'all items have been processed\');\n }\n\n // add some items to the queue\n\n q.push({name: \'foo\'}, function (err) {\n console.log(\'finished processing foo\');\n });\n q.push({name: \'bar\'}, function (err) {\n console.log(\'finished processing bar\');\n });\n\n // add some items to the queue (batch-wise)\n\n q.push([{name: \'baz\'},{name: \'bay\'},{name: \'bax\'}], function (err) {\n console.log(\'finished processing bar\');\n });\n\n\n---------------------------------------\n\n\n### auto(tasks, [callback])\n\nDetermines the best order for running functions based on their requirements.\nEach function can optionally depend on other functions being completed first,\nand each function is run as soon as its requirements are satisfied. If any of\nthe functions pass an error to their callback, that function will not complete\n(so any other functions depending on it will not run) and the main callback\nwill be called immediately with the error. Functions also receive an object\ncontaining the results of functions which have completed so far.\n\n__Arguments__\n\n* tasks - An object literal containing named functions or an array of\n requirements, with the function itself the last item in the array. The key\n used for each function or array is used when specifying requirements. The\n syntax is easier to understand by looking at the example.\n* callback(err, results) - An optional callback which is called when all the\n tasks have been completed. The callback will receive an error as an argument\n if any tasks pass an error to their callback. If all tasks complete\n successfully, it will receive an object containing their results.\n\n__Example__\n\n async.auto({\n get_data: function(callback){\n // async code to get some data\n },\n make_folder: function(callback){\n // async code to create a directory to store a file in\n // this is run at the same time as getting the data\n },\n write_file: [\'get_data\', \'make_folder\', function(callback){\n // once there is some data and the directory exists,\n // write the data to a file in the directory\n callback(null, filename);\n }],\n email_link: [\'write_file\', function(callback, results){\n // once the file is written let\'s email a link to it...\n // results.write_file contains the filename returned by write_file.\n }]\n });\n\nThis is a fairly trivial example, but to do this using the basic parallel and\nseries functions would look like this:\n\n async.parallel([\n function(callback){\n // async code to get some data\n },\n function(callback){\n // async code to create a directory to store a file in\n // this is run at the same time as getting the data\n }\n ],\n function(results){\n async.series([\n function(callback){\n // once there is some data and the directory exists,\n // write the data to a file in the directory\n },\n email_link: function(callback){\n // once the file is written let\'s email a link to it...\n }\n ]);\n });\n\nFor a complicated series of async tasks using the auto function makes adding\nnew tasks much easier and makes the code more readable.\n\n\n---------------------------------------\n\n\n### iterator(tasks)\n\nCreates an iterator function which calls the next function in the array,\nreturning a continuation to call the next one after that. Its also possible to\n\'peek\' the next iterator by doing iterator.next().\n\nThis function is used internally by the async module but can be useful when\nyou want to manually control the flow of functions in series.\n\n__Arguments__\n\n* tasks - An array of functions to run, each function is passed a callback it\n must call on completion.\n\n__Example__\n\n var iterator = async.iterator([\n function(){ sys.p(\'one\'); },\n function(){ sys.p(\'two\'); },\n function(){ sys.p(\'three\'); }\n ]);\n\n node> var iterator2 = iterator();\n \'one\'\n node> var iterator3 = iterator2();\n \'two\'\n node> iterator3();\n \'three\'\n node> var nextfn = iterator2.next();\n node> nextfn();\n \'three\'\n\n\n---------------------------------------\n\n\n### apply(function, arguments..)\n\nCreates a continuation function with some arguments already applied, a useful\nshorthand when combined with other control flow functions. Any arguments\npassed to the returned function are added to the arguments originally passed\nto apply.\n\n__Arguments__\n\n* function - The function you want to eventually apply all arguments to.\n* arguments... - Any number of arguments to automatically apply when the\n continuation is called.\n\n__Example__\n\n // using apply\n\n async.parallel([\n async.apply(fs.writeFile, \'testfile1\', \'test1\'),\n async.apply(fs.writeFile, \'testfile2\', \'test2\'),\n ]);\n\n\n // the same process without using apply\n\n async.parallel([\n function(callback){\n fs.writeFile(\'testfile1\', \'test1\', callback);\n },\n function(callback){\n fs.writeFile(\'testfile2\', \'test2\', callback);\n },\n ]);\n\nIt\'s possible to pass any number of additional arguments when calling the\ncontinuation:\n\n node> var fn = async.apply(sys.puts, \'one\');\n node> fn(\'two\', \'three\');\n one\n two\n three\n\n---------------------------------------\n\n\n### nextTick(callback)\n\nCalls the callback on a later loop around the event loop. In node.js this just\ncalls process.nextTick, in the browser it falls back to setTimeout(callback, 0),\nwhich means other higher priority events may precede the execution of the callback.\n\nThis is used internally for browser-compatibility purposes.\n\n__Arguments__\n\n* callback - The function to call on a later loop around the event loop.\n\n__Example__\n\n var call_order = [];\n async.nextTick(function(){\n call_order.push(\'two\');\n // call_order now equals [\'one\',\'two]\n });\n call_order.push(\'one\')\n\n\n## Utils\n\n\n### memoize(fn, [hasher])\n\nCaches the results of an async function. When creating a hash to store function\nresults against, the callback is omitted from the hash and an optional hash\nfunction can be used.\n\n__Arguments__\n\n* fn - the function you to proxy and cache results from.\n* hasher - an optional function for generating a custom hash for storing\n results, it has all the arguments applied to it apart from the callback, and\n must be synchronous.\n\n__Example__\n\n var slow_fn = function (name, callback) {\n // do something\n callback(null, result);\n };\n var fn = async.memoize(slow_fn);\n\n // fn can now be used as if it were slow_fn\n fn(\'some name\', function () {\n // callback\n });\n\n\n### unmemoize(fn)\n\nUndoes a memoized function, reverting it to the original, unmemoized\nform. Comes handy in tests.\n\n__Arguments__\n\n* fn - the memoized function\n\n\n### log(function, arguments)\n\nLogs the result of an async function to the console. Only works in node.js or\nin browsers that support console.log and console.error (such as FF and Chrome).\nIf multiple arguments are returned from the async function, console.log is\ncalled on each argument in order.\n\n__Arguments__\n\n* function - The function you want to eventually apply all arguments to.\n* arguments... - Any number of arguments to apply to the function.\n\n__Example__\n\n var hello = function(name, callback){\n setTimeout(function(){\n callback(null, \'hello \' + name);\n }, 1000);\n };\n\n node> async.log(hello, \'world\');\n \'hello world\'\n\n\n---------------------------------------\n\n\n### dir(function, arguments)\n\nLogs the result of an async function to the console using console.dir to\ndisplay the properties of the resulting object. Only works in node.js or\nin browsers that support console.dir and console.error (such as FF and Chrome).\nIf multiple arguments are returned from the async function, console.dir is\ncalled on each argument in order.\n\n__Arguments__\n\n* function - The function you want to eventually apply all arguments to.\n* arguments... - Any number of arguments to apply to the function.\n\n__Example__\n\n var hello = function(name, callback){\n setTimeout(function(){\n callback(null, {hello: name});\n }, 1000);\n };\n\n node> async.dir(hello, \'world\');\n {hello: \'world\'}\n\n\n---------------------------------------\n\n\n### noConflict()\n\nChanges the value of async back to its original value, returning a reference to the\nasync object.\n', +4736 silly resolved readmeFilename: 'README.md', +4736 silly resolved homepage: 'https://github.com/caolan/async', +4736 silly resolved _id: 'async@0.1.22', +4736 silly resolved _from: 'async@0.1.22', +4736 silly resolved scripts: {} } ] +4737 info install async@0.1.22 into /usr/lib/node_modules/grunt +4738 info installOne async@0.1.22 +4739 silly resolved [ { name: 'async', +4739 silly resolved description: 'Higher-order functions and common patterns for asynchronous code', +4739 silly resolved main: './index', +4739 silly resolved author: { name: 'Caolan McMahon' }, +4739 silly resolved version: '0.1.22', +4739 silly resolved repository: { type: 'git', url: 'http://github.com/caolan/async.git' }, +4739 silly resolved bugs: { url: 'http://github.com/caolan/async/issues' }, +4739 silly resolved licenses: [ [Object] ], +4739 silly resolved devDependencies: { nodeunit: '>0.0.0', 'uglify-js': '1.2.x', nodelint: '>0.0.0' }, +4739 silly resolved readme: '# Async.js\n\nAsync is a utility module which provides straight-forward, powerful functions\nfor working with asynchronous JavaScript. Although originally designed for\nuse with [node.js](http://nodejs.org), it can also be used directly in the\nbrowser.\n\nAsync provides around 20 functions that include the usual \'functional\'\nsuspects (map, reduce, filter, forEach…) as well as some common patterns\nfor asynchronous control flow (parallel, series, waterfall…). All these\nfunctions assume you follow the node.js convention of providing a single\ncallback as the last argument of your async function.\n\n\n## Quick Examples\n\n async.map([\'file1\',\'file2\',\'file3\'], fs.stat, function(err, results){\n // results is now an array of stats for each file\n });\n\n async.filter([\'file1\',\'file2\',\'file3\'], path.exists, function(results){\n // results now equals an array of the existing files\n });\n\n async.parallel([\n function(){ ... },\n function(){ ... }\n ], callback);\n\n async.series([\n function(){ ... },\n function(){ ... }\n ]);\n\nThere are many more functions available so take a look at the docs below for a\nfull list. This module aims to be comprehensive, so if you feel anything is\nmissing please create a GitHub issue for it.\n\n\n## Download\n\nReleases are available for download from\n[GitHub](http://github.com/caolan/async/downloads).\nAlternatively, you can install using Node Package Manager (npm):\n\n npm install async\n\n\n__Development:__ [async.js](https://github.com/caolan/async/raw/master/lib/async.js) - 17.5kb Uncompressed\n\n__Production:__ [async.min.js](https://github.com/caolan/async/raw/master/dist/async.min.js) - 1.7kb Packed and Gzipped\n\n\n## In the Browser\n\nSo far its been tested in IE6, IE7, IE8, FF3.6 and Chrome 5. Usage:\n\n \n \n\n\n## Documentation\n\n### Collections\n\n* [forEach](#forEach)\n* [map](#map)\n* [filter](#filter)\n* [reject](#reject)\n* [reduce](#reduce)\n* [detect](#detect)\n* [sortBy](#sortBy)\n* [some](#some)\n* [every](#every)\n* [concat](#concat)\n\n### Control Flow\n\n* [series](#series)\n* [parallel](#parallel)\n* [whilst](#whilst)\n* [until](#until)\n* [waterfall](#waterfall)\n* [queue](#queue)\n* [auto](#auto)\n* [iterator](#iterator)\n* [apply](#apply)\n* [nextTick](#nextTick)\n\n### Utils\n\n* [memoize](#memoize)\n* [unmemoize](#unmemoize)\n* [log](#log)\n* [dir](#dir)\n* [noConflict](#noConflict)\n\n\n## Collections\n\n\n### forEach(arr, iterator, callback)\n\nApplies an iterator function to each item in an array, in parallel.\nThe iterator is called with an item from the list and a callback for when it\nhas finished. If the iterator passes an error to this callback, the main\ncallback for the forEach function is immediately called with the error.\n\nNote, that since this function applies the iterator to each item in parallel\nthere is no guarantee that the iterator functions will complete in order.\n\n__Arguments__\n\n* arr - An array to iterate over.\n* iterator(item, callback) - A function to apply to each item in the array.\n The iterator is passed a callback which must be called once it has completed.\n* callback(err) - A callback which is called after all the iterator functions\n have finished, or an error has occurred.\n\n__Example__\n\n // assuming openFiles is an array of file names and saveFile is a function\n // to save the modified contents of that file:\n\n async.forEach(openFiles, saveFile, function(err){\n // if any of the saves produced an error, err would equal that error\n });\n\n---------------------------------------\n\n\n### forEachSeries(arr, iterator, callback)\n\nThe same as forEach only the iterator is applied to each item in the array in\nseries. The next iterator is only called once the current one has completed\nprocessing. This means the iterator functions will complete in order.\n\n\n---------------------------------------\n\n\n### forEachLimit(arr, limit, iterator, callback)\n\nThe same as forEach only the iterator is applied to batches of items in the\narray, in series. The next batch of iterators is only called once the current\none has completed processing.\n\n__Arguments__\n\n* arr - An array to iterate over.\n* limit - How many items should be in each batch.\n* iterator(item, callback) - A function to apply to each item in the array.\n The iterator is passed a callback which must be called once it has completed.\n* callback(err) - A callback which is called after all the iterator functions\n have finished, or an error has occurred.\n\n__Example__\n\n // Assume documents is an array of JSON objects and requestApi is a\n // function that interacts with a rate-limited REST api.\n\n async.forEachLimit(documents, 20, requestApi, function(err){\n // if any of the saves produced an error, err would equal that error\n });\n---------------------------------------\n\n\n### map(arr, iterator, callback)\n\nProduces a new array of values by mapping each value in the given array through\nthe iterator function. The iterator is called with an item from the array and a\ncallback for when it has finished processing. The callback takes 2 arguments, \nan error and the transformed item from the array. If the iterator passes an\nerror to this callback, the main callback for the map function is immediately\ncalled with the error.\n\nNote, that since this function applies the iterator to each item in parallel\nthere is no guarantee that the iterator functions will complete in order, however\nthe results array will be in the same order as the original array.\n\n__Arguments__\n\n* arr - An array to iterate over.\n* iterator(item, callback) - A function to apply to each item in the array.\n The iterator is passed a callback which must be called once it has completed\n with an error (which can be null) and a transformed item.\n* callback(err, results) - A callback which is called after all the iterator\n functions have finished, or an error has occurred. Results is an array of the\n transformed items from the original array.\n\n__Example__\n\n async.map([\'file1\',\'file2\',\'file3\'], fs.stat, function(err, results){\n // results is now an array of stats for each file\n });\n\n---------------------------------------\n\n\n### mapSeries(arr, iterator, callback)\n\nThe same as map only the iterator is applied to each item in the array in\nseries. The next iterator is only called once the current one has completed\nprocessing. The results array will be in the same order as the original.\n\n\n---------------------------------------\n\n\n### filter(arr, iterator, callback)\n\n__Alias:__ select\n\nReturns a new array of all the values which pass an async truth test.\n_The callback for each iterator call only accepts a single argument of true or\nfalse, it does not accept an error argument first!_ This is in-line with the\nway node libraries work with truth tests like path.exists. This operation is\nperformed in parallel, but the results array will be in the same order as the\noriginal.\n\n__Arguments__\n\n* arr - An array to iterate over.\n* iterator(item, callback) - A truth test to apply to each item in the array.\n The iterator is passed a callback which must be called once it has completed.\n* callback(results) - A callback which is called after all the iterator\n functions have finished.\n\n__Example__\n\n async.filter([\'file1\',\'file2\',\'file3\'], path.exists, function(results){\n // results now equals an array of the existing files\n });\n\n---------------------------------------\n\n\n### filterSeries(arr, iterator, callback)\n\n__alias:__ selectSeries\n\nThe same as filter only the iterator is applied to each item in the array in\nseries. The next iterator is only called once the current one has completed\nprocessing. The results array will be in the same order as the original.\n\n---------------------------------------\n\n\n### reject(arr, iterator, callback)\n\nThe opposite of filter. Removes values that pass an async truth test.\n\n---------------------------------------\n\n\n### rejectSeries(arr, iterator, callback)\n\nThe same as filter, only the iterator is applied to each item in the array\nin series.\n\n\n---------------------------------------\n\n\n### reduce(arr, memo, iterator, callback)\n\n__aliases:__ inject, foldl\n\nReduces a list of values into a single value using an async iterator to return\neach successive step. Memo is the initial state of the reduction. This\nfunction only operates in series. For performance reasons, it may make sense to\nsplit a call to this function into a parallel map, then use the normal\nArray.prototype.reduce on the results. This function is for situations where\neach step in the reduction needs to be async, if you can get the data before\nreducing it then its probably a good idea to do so.\n\n__Arguments__\n\n* arr - An array to iterate over.\n* memo - The initial state of the reduction.\n* iterator(memo, item, callback) - A function applied to each item in the\n array to produce the next step in the reduction. The iterator is passed a\n callback which accepts an optional error as its first argument, and the state\n of the reduction as the second. If an error is passed to the callback, the\n reduction is stopped and the main callback is immediately called with the\n error.\n* callback(err, result) - A callback which is called after all the iterator\n functions have finished. Result is the reduced value.\n\n__Example__\n\n async.reduce([1,2,3], 0, function(memo, item, callback){\n // pointless async:\n process.nextTick(function(){\n callback(null, memo + item)\n });\n }, function(err, result){\n // result is now equal to the last value of memo, which is 6\n });\n\n---------------------------------------\n\n\n### reduceRight(arr, memo, iterator, callback)\n\n__Alias:__ foldr\n\nSame as reduce, only operates on the items in the array in reverse order.\n\n\n---------------------------------------\n\n\n### detect(arr, iterator, callback)\n\nReturns the first value in a list that passes an async truth test. The\niterator is applied in parallel, meaning the first iterator to return true will\nfire the detect callback with that result. That means the result might not be\nthe first item in the original array (in terms of order) that passes the test.\n\nIf order within the original array is important then look at detectSeries.\n\n__Arguments__\n\n* arr - An array to iterate over.\n* iterator(item, callback) - A truth test to apply to each item in the array.\n The iterator is passed a callback which must be called once it has completed.\n* callback(result) - A callback which is called as soon as any iterator returns\n true, or after all the iterator functions have finished. Result will be\n the first item in the array that passes the truth test (iterator) or the\n value undefined if none passed.\n\n__Example__\n\n async.detect([\'file1\',\'file2\',\'file3\'], path.exists, function(result){\n // result now equals the first file in the list that exists\n });\n\n---------------------------------------\n\n\n### detectSeries(arr, iterator, callback)\n\nThe same as detect, only the iterator is applied to each item in the array\nin series. This means the result is always the first in the original array (in\nterms of array order) that passes the truth test.\n\n\n---------------------------------------\n\n\n### sortBy(arr, iterator, callback)\n\nSorts a list by the results of running each value through an async iterator.\n\n__Arguments__\n\n* arr - An array to iterate over.\n* iterator(item, callback) - A function to apply to each item in the array.\n The iterator is passed a callback which must be called once it has completed\n with an error (which can be null) and a value to use as the sort criteria.\n* callback(err, results) - A callback which is called after all the iterator\n functions have finished, or an error has occurred. Results is the items from\n the original array sorted by the values returned by the iterator calls.\n\n__Example__\n\n async.sortBy([\'file1\',\'file2\',\'file3\'], function(file, callback){\n fs.stat(file, function(err, stats){\n callback(err, stats.mtime);\n });\n }, function(err, results){\n // results is now the original array of files sorted by\n // modified date\n });\n\n\n---------------------------------------\n\n\n### some(arr, iterator, callback)\n\n__Alias:__ any\n\nReturns true if at least one element in the array satisfies an async test.\n_The callback for each iterator call only accepts a single argument of true or\nfalse, it does not accept an error argument first!_ This is in-line with the\nway node libraries work with truth tests like path.exists. Once any iterator\ncall returns true, the main callback is immediately called.\n\n__Arguments__\n\n* arr - An array to iterate over.\n* iterator(item, callback) - A truth test to apply to each item in the array.\n The iterator is passed a callback which must be called once it has completed.\n* callback(result) - A callback which is called as soon as any iterator returns\n true, or after all the iterator functions have finished. Result will be\n either true or false depending on the values of the async tests.\n\n__Example__\n\n async.some([\'file1\',\'file2\',\'file3\'], path.exists, function(result){\n // if result is true then at least one of the files exists\n });\n\n---------------------------------------\n\n\n### every(arr, iterator, callback)\n\n__Alias:__ all\n\nReturns true if every element in the array satisfies an async test.\n_The callback for each iterator call only accepts a single argument of true or\nfalse, it does not accept an error argument first!_ This is in-line with the\nway node libraries work with truth tests like path.exists.\n\n__Arguments__\n\n* arr - An array to iterate over.\n* iterator(item, callback) - A truth test to apply to each item in the array.\n The iterator is passed a callback which must be called once it has completed.\n* callback(result) - A callback which is called after all the iterator\n functions have finished. Result will be either true or false depending on\n the values of the async tests.\n\n__Example__\n\n async.every([\'file1\',\'file2\',\'file3\'], path.exists, function(result){\n // if result is true then every file exists\n });\n\n---------------------------------------\n\n\n### concat(arr, iterator, callback)\n\nApplies an iterator to each item in a list, concatenating the results. Returns the\nconcatenated list. The iterators are called in parallel, and the results are\nconcatenated as they return. There is no guarantee that the results array will\nbe returned in the original order of the arguments passed to the iterator function.\n\n__Arguments__\n\n* arr - An array to iterate over\n* iterator(item, callback) - A function to apply to each item in the array.\n The iterator is passed a callback which must be called once it has completed\n with an error (which can be null) and an array of results.\n* callback(err, results) - A callback which is called after all the iterator\n functions have finished, or an error has occurred. Results is an array containing\n the concatenated results of the iterator function.\n\n__Example__\n\n async.concat([\'dir1\',\'dir2\',\'dir3\'], fs.readdir, function(err, files){\n // files is now a list of filenames that exist in the 3 directories\n });\n\n---------------------------------------\n\n\n### concatSeries(arr, iterator, callback)\n\nSame as async.concat, but executes in series instead of parallel.\n\n\n## Control Flow\n\n\n### series(tasks, [callback])\n\nRun an array of functions in series, each one running once the previous\nfunction has completed. If any functions in the series pass an error to its\ncallback, no more functions are run and the callback for the series is\nimmediately called with the value of the error. Once the tasks have completed,\nthe results are passed to the final callback as an array.\n\nIt is also possible to use an object instead of an array. Each property will be\nrun as a function and the results will be passed to the final callback as an object\ninstead of an array. This can be a more readable way of handling results from\nasync.series.\n\n\n__Arguments__\n\n* tasks - An array or object containing functions to run, each function is passed\n a callback it must call on completion.\n* callback(err, results) - An optional callback to run once all the functions\n have completed. This function gets an array of all the arguments passed to\n the callbacks used in the array.\n\n__Example__\n\n async.series([\n function(callback){\n // do some stuff ...\n callback(null, \'one\');\n },\n function(callback){\n // do some more stuff ...\n callback(null, \'two\');\n },\n ],\n // optional callback\n function(err, results){\n // results is now equal to [\'one\', \'two\']\n });\n\n\n // an example using an object instead of an array\n async.series({\n one: function(callback){\n setTimeout(function(){\n callback(null, 1);\n }, 200);\n },\n two: function(callback){\n setTimeout(function(){\n callback(null, 2);\n }, 100);\n },\n },\n function(err, results) {\n // results is now equal to: {one: 1, two: 2}\n });\n\n\n---------------------------------------\n\n\n### parallel(tasks, [callback])\n\nRun an array of functions in parallel, without waiting until the previous\nfunction has completed. If any of the functions pass an error to its\ncallback, the main callback is immediately called with the value of the error.\nOnce the tasks have completed, the results are passed to the final callback as an\narray.\n\nIt is also possible to use an object instead of an array. Each property will be\nrun as a function and the results will be passed to the final callback as an object\ninstead of an array. This can be a more readable way of handling results from\nasync.parallel.\n\n\n__Arguments__\n\n* tasks - An array or object containing functions to run, each function is passed a\n callback it must call on completion.\n* callback(err, results) - An optional callback to run once all the functions\n have completed. This function gets an array of all the arguments passed to\n the callbacks used in the array.\n\n__Example__\n\n async.parallel([\n function(callback){\n setTimeout(function(){\n callback(null, \'one\');\n }, 200);\n },\n function(callback){\n setTimeout(function(){\n callback(null, \'two\');\n }, 100);\n },\n ],\n // optional callback\n function(err, results){\n // the results array will equal [\'one\',\'two\'] even though\n // the second function had a shorter timeout.\n });\n\n\n // an example using an object instead of an array\n async.parallel({\n one: function(callback){\n setTimeout(function(){\n callback(null, 1);\n }, 200);\n },\n two: function(callback){\n setTimeout(function(){\n callback(null, 2);\n }, 100);\n },\n },\n function(err, results) {\n // results is now equals to: {one: 1, two: 2}\n });\n\n\n---------------------------------------\n\n\n### whilst(test, fn, callback)\n\nRepeatedly call fn, while test returns true. Calls the callback when stopped,\nor an error occurs.\n\n__Arguments__\n\n* test() - synchronous truth test to perform before each execution of fn.\n* fn(callback) - A function to call each time the test passes. The function is\n passed a callback which must be called once it has completed with an optional\n error as the first argument.\n* callback(err) - A callback which is called after the test fails and repeated\n execution of fn has stopped.\n\n__Example__\n\n var count = 0;\n\n async.whilst(\n function () { return count < 5; },\n function (callback) {\n count++;\n setTimeout(callback, 1000);\n },\n function (err) {\n // 5 seconds have passed\n }\n );\n\n\n---------------------------------------\n\n\n### until(test, fn, callback)\n\nRepeatedly call fn, until test returns true. Calls the callback when stopped,\nor an error occurs.\n\nThe inverse of async.whilst.\n\n\n---------------------------------------\n\n\n### waterfall(tasks, [callback])\n\nRuns an array of functions in series, each passing their results to the next in\nthe array. However, if any of the functions pass an error to the callback, the\nnext function is not executed and the main callback is immediately called with\nthe error.\n\n__Arguments__\n\n* tasks - An array of functions to run, each function is passed a callback it\n must call on completion.\n* callback(err, [results]) - An optional callback to run once all the functions\n have completed. This will be passed the results of the last task\'s callback.\n\n\n\n__Example__\n\n async.waterfall([\n function(callback){\n callback(null, \'one\', \'two\');\n },\n function(arg1, arg2, callback){\n callback(null, \'three\');\n },\n function(arg1, callback){\n // arg1 now equals \'three\'\n callback(null, \'done\');\n }\n ], function (err, result) {\n // result now equals \'done\' \n });\n\n\n---------------------------------------\n\n\n### queue(worker, concurrency)\n\nCreates a queue object with the specified concurrency. Tasks added to the\nqueue will be processed in parallel (up to the concurrency limit). If all\nworkers are in progress, the task is queued until one is available. Once\na worker has completed a task, the task\'s callback is called.\n\n__Arguments__\n\n* worker(task, callback) - An asynchronous function for processing a queued\n task.\n* concurrency - An integer for determining how many worker functions should be\n run in parallel.\n\n__Queue objects__\n\nThe queue object returned by this function has the following properties and\nmethods:\n\n* length() - a function returning the number of items waiting to be processed.\n* concurrency - an integer for determining how many worker functions should be\n run in parallel. This property can be changed after a queue is created to\n alter the concurrency on-the-fly.\n* push(task, [callback]) - add a new task to the queue, the callback is called\n once the worker has finished processing the task.\n instead of a single task, an array of tasks can be submitted. the respective callback is used for every task in the list.\n* saturated - a callback that is called when the queue length hits the concurrency and further tasks will be queued\n* empty - a callback that is called when the last item from the queue is given to a worker\n* drain - a callback that is called when the last item from the queue has returned from the worker\n\n__Example__\n\n // create a queue object with concurrency 2\n\n var q = async.queue(function (task, callback) {\n console.log(\'hello \' + task.name);\n callback();\n }, 2);\n\n\n // assign a callback\n q.drain = function() {\n console.log(\'all items have been processed\');\n }\n\n // add some items to the queue\n\n q.push({name: \'foo\'}, function (err) {\n console.log(\'finished processing foo\');\n });\n q.push({name: \'bar\'}, function (err) {\n console.log(\'finished processing bar\');\n });\n\n // add some items to the queue (batch-wise)\n\n q.push([{name: \'baz\'},{name: \'bay\'},{name: \'bax\'}], function (err) {\n console.log(\'finished processing bar\');\n });\n\n\n---------------------------------------\n\n\n### auto(tasks, [callback])\n\nDetermines the best order for running functions based on their requirements.\nEach function can optionally depend on other functions being completed first,\nand each function is run as soon as its requirements are satisfied. If any of\nthe functions pass an error to their callback, that function will not complete\n(so any other functions depending on it will not run) and the main callback\nwill be called immediately with the error. Functions also receive an object\ncontaining the results of functions which have completed so far.\n\n__Arguments__\n\n* tasks - An object literal containing named functions or an array of\n requirements, with the function itself the last item in the array. The key\n used for each function or array is used when specifying requirements. The\n syntax is easier to understand by looking at the example.\n* callback(err, results) - An optional callback which is called when all the\n tasks have been completed. The callback will receive an error as an argument\n if any tasks pass an error to their callback. If all tasks complete\n successfully, it will receive an object containing their results.\n\n__Example__\n\n async.auto({\n get_data: function(callback){\n // async code to get some data\n },\n make_folder: function(callback){\n // async code to create a directory to store a file in\n // this is run at the same time as getting the data\n },\n write_file: [\'get_data\', \'make_folder\', function(callback){\n // once there is some data and the directory exists,\n // write the data to a file in the directory\n callback(null, filename);\n }],\n email_link: [\'write_file\', function(callback, results){\n // once the file is written let\'s email a link to it...\n // results.write_file contains the filename returned by write_file.\n }]\n });\n\nThis is a fairly trivial example, but to do this using the basic parallel and\nseries functions would look like this:\n\n async.parallel([\n function(callback){\n // async code to get some data\n },\n function(callback){\n // async code to create a directory to store a file in\n // this is run at the same time as getting the data\n }\n ],\n function(results){\n async.series([\n function(callback){\n // once there is some data and the directory exists,\n // write the data to a file in the directory\n },\n email_link: function(callback){\n // once the file is written let\'s email a link to it...\n }\n ]);\n });\n\nFor a complicated series of async tasks using the auto function makes adding\nnew tasks much easier and makes the code more readable.\n\n\n---------------------------------------\n\n\n### iterator(tasks)\n\nCreates an iterator function which calls the next function in the array,\nreturning a continuation to call the next one after that. Its also possible to\n\'peek\' the next iterator by doing iterator.next().\n\nThis function is used internally by the async module but can be useful when\nyou want to manually control the flow of functions in series.\n\n__Arguments__\n\n* tasks - An array of functions to run, each function is passed a callback it\n must call on completion.\n\n__Example__\n\n var iterator = async.iterator([\n function(){ sys.p(\'one\'); },\n function(){ sys.p(\'two\'); },\n function(){ sys.p(\'three\'); }\n ]);\n\n node> var iterator2 = iterator();\n \'one\'\n node> var iterator3 = iterator2();\n \'two\'\n node> iterator3();\n \'three\'\n node> var nextfn = iterator2.next();\n node> nextfn();\n \'three\'\n\n\n---------------------------------------\n\n\n### apply(function, arguments..)\n\nCreates a continuation function with some arguments already applied, a useful\nshorthand when combined with other control flow functions. Any arguments\npassed to the returned function are added to the arguments originally passed\nto apply.\n\n__Arguments__\n\n* function - The function you want to eventually apply all arguments to.\n* arguments... - Any number of arguments to automatically apply when the\n continuation is called.\n\n__Example__\n\n // using apply\n\n async.parallel([\n async.apply(fs.writeFile, \'testfile1\', \'test1\'),\n async.apply(fs.writeFile, \'testfile2\', \'test2\'),\n ]);\n\n\n // the same process without using apply\n\n async.parallel([\n function(callback){\n fs.writeFile(\'testfile1\', \'test1\', callback);\n },\n function(callback){\n fs.writeFile(\'testfile2\', \'test2\', callback);\n },\n ]);\n\nIt\'s possible to pass any number of additional arguments when calling the\ncontinuation:\n\n node> var fn = async.apply(sys.puts, \'one\');\n node> fn(\'two\', \'three\');\n one\n two\n three\n\n---------------------------------------\n\n\n### nextTick(callback)\n\nCalls the callback on a later loop around the event loop. In node.js this just\ncalls process.nextTick, in the browser it falls back to setTimeout(callback, 0),\nwhich means other higher priority events may precede the execution of the callback.\n\nThis is used internally for browser-compatibility purposes.\n\n__Arguments__\n\n* callback - The function to call on a later loop around the event loop.\n\n__Example__\n\n var call_order = [];\n async.nextTick(function(){\n call_order.push(\'two\');\n // call_order now equals [\'one\',\'two]\n });\n call_order.push(\'one\')\n\n\n## Utils\n\n\n### memoize(fn, [hasher])\n\nCaches the results of an async function. When creating a hash to store function\nresults against, the callback is omitted from the hash and an optional hash\nfunction can be used.\n\n__Arguments__\n\n* fn - the function you to proxy and cache results from.\n* hasher - an optional function for generating a custom hash for storing\n results, it has all the arguments applied to it apart from the callback, and\n must be synchronous.\n\n__Example__\n\n var slow_fn = function (name, callback) {\n // do something\n callback(null, result);\n };\n var fn = async.memoize(slow_fn);\n\n // fn can now be used as if it were slow_fn\n fn(\'some name\', function () {\n // callback\n });\n\n\n### unmemoize(fn)\n\nUndoes a memoized function, reverting it to the original, unmemoized\nform. Comes handy in tests.\n\n__Arguments__\n\n* fn - the memoized function\n\n\n### log(function, arguments)\n\nLogs the result of an async function to the console. Only works in node.js or\nin browsers that support console.log and console.error (such as FF and Chrome).\nIf multiple arguments are returned from the async function, console.log is\ncalled on each argument in order.\n\n__Arguments__\n\n* function - The function you want to eventually apply all arguments to.\n* arguments... - Any number of arguments to apply to the function.\n\n__Example__\n\n var hello = function(name, callback){\n setTimeout(function(){\n callback(null, \'hello \' + name);\n }, 1000);\n };\n\n node> async.log(hello, \'world\');\n \'hello world\'\n\n\n---------------------------------------\n\n\n### dir(function, arguments)\n\nLogs the result of an async function to the console using console.dir to\ndisplay the properties of the resulting object. Only works in node.js or\nin browsers that support console.dir and console.error (such as FF and Chrome).\nIf multiple arguments are returned from the async function, console.dir is\ncalled on each argument in order.\n\n__Arguments__\n\n* function - The function you want to eventually apply all arguments to.\n* arguments... - Any number of arguments to apply to the function.\n\n__Example__\n\n var hello = function(name, callback){\n setTimeout(function(){\n callback(null, {hello: name});\n }, 1000);\n };\n\n node> async.dir(hello, \'world\');\n {hello: \'world\'}\n\n\n---------------------------------------\n\n\n### noConflict()\n\nChanges the value of async back to its original value, returning a reference to the\nasync object.\n', +4739 silly resolved readmeFilename: 'README.md', +4739 silly resolved homepage: 'https://github.com/caolan/async', +4739 silly resolved _id: 'async@0.1.22', +4739 silly resolved _from: 'async@0.1.22', +4739 silly resolved scripts: {} } ] +4740 info install async@0.1.22 into /usr/lib/node_modules/grunt/node_modules/grunt-legacy-util +4741 info installOne async@0.1.22 +4742 silly resolved [ { name: 'async', +4742 silly resolved description: 'Higher-order functions and common patterns for asynchronous code', +4742 silly resolved main: './index', +4742 silly resolved author: { name: 'Caolan McMahon' }, +4742 silly resolved version: '0.1.22', +4742 silly resolved repository: { type: 'git', url: 'http://github.com/caolan/async.git' }, +4742 silly resolved bugs: { url: 'http://github.com/caolan/async/issues' }, +4742 silly resolved licenses: [ [Object] ], +4742 silly resolved devDependencies: { nodeunit: '>0.0.0', 'uglify-js': '1.2.x', nodelint: '>0.0.0' }, +4742 silly resolved readme: '# Async.js\n\nAsync is a utility module which provides straight-forward, powerful functions\nfor working with asynchronous JavaScript. Although originally designed for\nuse with [node.js](http://nodejs.org), it can also be used directly in the\nbrowser.\n\nAsync provides around 20 functions that include the usual \'functional\'\nsuspects (map, reduce, filter, forEach…) as well as some common patterns\nfor asynchronous control flow (parallel, series, waterfall…). All these\nfunctions assume you follow the node.js convention of providing a single\ncallback as the last argument of your async function.\n\n\n## Quick Examples\n\n async.map([\'file1\',\'file2\',\'file3\'], fs.stat, function(err, results){\n // results is now an array of stats for each file\n });\n\n async.filter([\'file1\',\'file2\',\'file3\'], path.exists, function(results){\n // results now equals an array of the existing files\n });\n\n async.parallel([\n function(){ ... },\n function(){ ... }\n ], callback);\n\n async.series([\n function(){ ... },\n function(){ ... }\n ]);\n\nThere are many more functions available so take a look at the docs below for a\nfull list. This module aims to be comprehensive, so if you feel anything is\nmissing please create a GitHub issue for it.\n\n\n## Download\n\nReleases are available for download from\n[GitHub](http://github.com/caolan/async/downloads).\nAlternatively, you can install using Node Package Manager (npm):\n\n npm install async\n\n\n__Development:__ [async.js](https://github.com/caolan/async/raw/master/lib/async.js) - 17.5kb Uncompressed\n\n__Production:__ [async.min.js](https://github.com/caolan/async/raw/master/dist/async.min.js) - 1.7kb Packed and Gzipped\n\n\n## In the Browser\n\nSo far its been tested in IE6, IE7, IE8, FF3.6 and Chrome 5. Usage:\n\n \n \n\n\n## Documentation\n\n### Collections\n\n* [forEach](#forEach)\n* [map](#map)\n* [filter](#filter)\n* [reject](#reject)\n* [reduce](#reduce)\n* [detect](#detect)\n* [sortBy](#sortBy)\n* [some](#some)\n* [every](#every)\n* [concat](#concat)\n\n### Control Flow\n\n* [series](#series)\n* [parallel](#parallel)\n* [whilst](#whilst)\n* [until](#until)\n* [waterfall](#waterfall)\n* [queue](#queue)\n* [auto](#auto)\n* [iterator](#iterator)\n* [apply](#apply)\n* [nextTick](#nextTick)\n\n### Utils\n\n* [memoize](#memoize)\n* [unmemoize](#unmemoize)\n* [log](#log)\n* [dir](#dir)\n* [noConflict](#noConflict)\n\n\n## Collections\n\n\n### forEach(arr, iterator, callback)\n\nApplies an iterator function to each item in an array, in parallel.\nThe iterator is called with an item from the list and a callback for when it\nhas finished. If the iterator passes an error to this callback, the main\ncallback for the forEach function is immediately called with the error.\n\nNote, that since this function applies the iterator to each item in parallel\nthere is no guarantee that the iterator functions will complete in order.\n\n__Arguments__\n\n* arr - An array to iterate over.\n* iterator(item, callback) - A function to apply to each item in the array.\n The iterator is passed a callback which must be called once it has completed.\n* callback(err) - A callback which is called after all the iterator functions\n have finished, or an error has occurred.\n\n__Example__\n\n // assuming openFiles is an array of file names and saveFile is a function\n // to save the modified contents of that file:\n\n async.forEach(openFiles, saveFile, function(err){\n // if any of the saves produced an error, err would equal that error\n });\n\n---------------------------------------\n\n\n### forEachSeries(arr, iterator, callback)\n\nThe same as forEach only the iterator is applied to each item in the array in\nseries. The next iterator is only called once the current one has completed\nprocessing. This means the iterator functions will complete in order.\n\n\n---------------------------------------\n\n\n### forEachLimit(arr, limit, iterator, callback)\n\nThe same as forEach only the iterator is applied to batches of items in the\narray, in series. The next batch of iterators is only called once the current\none has completed processing.\n\n__Arguments__\n\n* arr - An array to iterate over.\n* limit - How many items should be in each batch.\n* iterator(item, callback) - A function to apply to each item in the array.\n The iterator is passed a callback which must be called once it has completed.\n* callback(err) - A callback which is called after all the iterator functions\n have finished, or an error has occurred.\n\n__Example__\n\n // Assume documents is an array of JSON objects and requestApi is a\n // function that interacts with a rate-limited REST api.\n\n async.forEachLimit(documents, 20, requestApi, function(err){\n // if any of the saves produced an error, err would equal that error\n });\n---------------------------------------\n\n\n### map(arr, iterator, callback)\n\nProduces a new array of values by mapping each value in the given array through\nthe iterator function. The iterator is called with an item from the array and a\ncallback for when it has finished processing. The callback takes 2 arguments, \nan error and the transformed item from the array. If the iterator passes an\nerror to this callback, the main callback for the map function is immediately\ncalled with the error.\n\nNote, that since this function applies the iterator to each item in parallel\nthere is no guarantee that the iterator functions will complete in order, however\nthe results array will be in the same order as the original array.\n\n__Arguments__\n\n* arr - An array to iterate over.\n* iterator(item, callback) - A function to apply to each item in the array.\n The iterator is passed a callback which must be called once it has completed\n with an error (which can be null) and a transformed item.\n* callback(err, results) - A callback which is called after all the iterator\n functions have finished, or an error has occurred. Results is an array of the\n transformed items from the original array.\n\n__Example__\n\n async.map([\'file1\',\'file2\',\'file3\'], fs.stat, function(err, results){\n // results is now an array of stats for each file\n });\n\n---------------------------------------\n\n\n### mapSeries(arr, iterator, callback)\n\nThe same as map only the iterator is applied to each item in the array in\nseries. The next iterator is only called once the current one has completed\nprocessing. The results array will be in the same order as the original.\n\n\n---------------------------------------\n\n\n### filter(arr, iterator, callback)\n\n__Alias:__ select\n\nReturns a new array of all the values which pass an async truth test.\n_The callback for each iterator call only accepts a single argument of true or\nfalse, it does not accept an error argument first!_ This is in-line with the\nway node libraries work with truth tests like path.exists. This operation is\nperformed in parallel, but the results array will be in the same order as the\noriginal.\n\n__Arguments__\n\n* arr - An array to iterate over.\n* iterator(item, callback) - A truth test to apply to each item in the array.\n The iterator is passed a callback which must be called once it has completed.\n* callback(results) - A callback which is called after all the iterator\n functions have finished.\n\n__Example__\n\n async.filter([\'file1\',\'file2\',\'file3\'], path.exists, function(results){\n // results now equals an array of the existing files\n });\n\n---------------------------------------\n\n\n### filterSeries(arr, iterator, callback)\n\n__alias:__ selectSeries\n\nThe same as filter only the iterator is applied to each item in the array in\nseries. The next iterator is only called once the current one has completed\nprocessing. The results array will be in the same order as the original.\n\n---------------------------------------\n\n\n### reject(arr, iterator, callback)\n\nThe opposite of filter. Removes values that pass an async truth test.\n\n---------------------------------------\n\n\n### rejectSeries(arr, iterator, callback)\n\nThe same as filter, only the iterator is applied to each item in the array\nin series.\n\n\n---------------------------------------\n\n\n### reduce(arr, memo, iterator, callback)\n\n__aliases:__ inject, foldl\n\nReduces a list of values into a single value using an async iterator to return\neach successive step. Memo is the initial state of the reduction. This\nfunction only operates in series. For performance reasons, it may make sense to\nsplit a call to this function into a parallel map, then use the normal\nArray.prototype.reduce on the results. This function is for situations where\neach step in the reduction needs to be async, if you can get the data before\nreducing it then its probably a good idea to do so.\n\n__Arguments__\n\n* arr - An array to iterate over.\n* memo - The initial state of the reduction.\n* iterator(memo, item, callback) - A function applied to each item in the\n array to produce the next step in the reduction. The iterator is passed a\n callback which accepts an optional error as its first argument, and the state\n of the reduction as the second. If an error is passed to the callback, the\n reduction is stopped and the main callback is immediately called with the\n error.\n* callback(err, result) - A callback which is called after all the iterator\n functions have finished. Result is the reduced value.\n\n__Example__\n\n async.reduce([1,2,3], 0, function(memo, item, callback){\n // pointless async:\n process.nextTick(function(){\n callback(null, memo + item)\n });\n }, function(err, result){\n // result is now equal to the last value of memo, which is 6\n });\n\n---------------------------------------\n\n\n### reduceRight(arr, memo, iterator, callback)\n\n__Alias:__ foldr\n\nSame as reduce, only operates on the items in the array in reverse order.\n\n\n---------------------------------------\n\n\n### detect(arr, iterator, callback)\n\nReturns the first value in a list that passes an async truth test. The\niterator is applied in parallel, meaning the first iterator to return true will\nfire the detect callback with that result. That means the result might not be\nthe first item in the original array (in terms of order) that passes the test.\n\nIf order within the original array is important then look at detectSeries.\n\n__Arguments__\n\n* arr - An array to iterate over.\n* iterator(item, callback) - A truth test to apply to each item in the array.\n The iterator is passed a callback which must be called once it has completed.\n* callback(result) - A callback which is called as soon as any iterator returns\n true, or after all the iterator functions have finished. Result will be\n the first item in the array that passes the truth test (iterator) or the\n value undefined if none passed.\n\n__Example__\n\n async.detect([\'file1\',\'file2\',\'file3\'], path.exists, function(result){\n // result now equals the first file in the list that exists\n });\n\n---------------------------------------\n\n\n### detectSeries(arr, iterator, callback)\n\nThe same as detect, only the iterator is applied to each item in the array\nin series. This means the result is always the first in the original array (in\nterms of array order) that passes the truth test.\n\n\n---------------------------------------\n\n\n### sortBy(arr, iterator, callback)\n\nSorts a list by the results of running each value through an async iterator.\n\n__Arguments__\n\n* arr - An array to iterate over.\n* iterator(item, callback) - A function to apply to each item in the array.\n The iterator is passed a callback which must be called once it has completed\n with an error (which can be null) and a value to use as the sort criteria.\n* callback(err, results) - A callback which is called after all the iterator\n functions have finished, or an error has occurred. Results is the items from\n the original array sorted by the values returned by the iterator calls.\n\n__Example__\n\n async.sortBy([\'file1\',\'file2\',\'file3\'], function(file, callback){\n fs.stat(file, function(err, stats){\n callback(err, stats.mtime);\n });\n }, function(err, results){\n // results is now the original array of files sorted by\n // modified date\n });\n\n\n---------------------------------------\n\n\n### some(arr, iterator, callback)\n\n__Alias:__ any\n\nReturns true if at least one element in the array satisfies an async test.\n_The callback for each iterator call only accepts a single argument of true or\nfalse, it does not accept an error argument first!_ This is in-line with the\nway node libraries work with truth tests like path.exists. Once any iterator\ncall returns true, the main callback is immediately called.\n\n__Arguments__\n\n* arr - An array to iterate over.\n* iterator(item, callback) - A truth test to apply to each item in the array.\n The iterator is passed a callback which must be called once it has completed.\n* callback(result) - A callback which is called as soon as any iterator returns\n true, or after all the iterator functions have finished. Result will be\n either true or false depending on the values of the async tests.\n\n__Example__\n\n async.some([\'file1\',\'file2\',\'file3\'], path.exists, function(result){\n // if result is true then at least one of the files exists\n });\n\n---------------------------------------\n\n\n### every(arr, iterator, callback)\n\n__Alias:__ all\n\nReturns true if every element in the array satisfies an async test.\n_The callback for each iterator call only accepts a single argument of true or\nfalse, it does not accept an error argument first!_ This is in-line with the\nway node libraries work with truth tests like path.exists.\n\n__Arguments__\n\n* arr - An array to iterate over.\n* iterator(item, callback) - A truth test to apply to each item in the array.\n The iterator is passed a callback which must be called once it has completed.\n* callback(result) - A callback which is called after all the iterator\n functions have finished. Result will be either true or false depending on\n the values of the async tests.\n\n__Example__\n\n async.every([\'file1\',\'file2\',\'file3\'], path.exists, function(result){\n // if result is true then every file exists\n });\n\n---------------------------------------\n\n\n### concat(arr, iterator, callback)\n\nApplies an iterator to each item in a list, concatenating the results. Returns the\nconcatenated list. The iterators are called in parallel, and the results are\nconcatenated as they return. There is no guarantee that the results array will\nbe returned in the original order of the arguments passed to the iterator function.\n\n__Arguments__\n\n* arr - An array to iterate over\n* iterator(item, callback) - A function to apply to each item in the array.\n The iterator is passed a callback which must be called once it has completed\n with an error (which can be null) and an array of results.\n* callback(err, results) - A callback which is called after all the iterator\n functions have finished, or an error has occurred. Results is an array containing\n the concatenated results of the iterator function.\n\n__Example__\n\n async.concat([\'dir1\',\'dir2\',\'dir3\'], fs.readdir, function(err, files){\n // files is now a list of filenames that exist in the 3 directories\n });\n\n---------------------------------------\n\n\n### concatSeries(arr, iterator, callback)\n\nSame as async.concat, but executes in series instead of parallel.\n\n\n## Control Flow\n\n\n### series(tasks, [callback])\n\nRun an array of functions in series, each one running once the previous\nfunction has completed. If any functions in the series pass an error to its\ncallback, no more functions are run and the callback for the series is\nimmediately called with the value of the error. Once the tasks have completed,\nthe results are passed to the final callback as an array.\n\nIt is also possible to use an object instead of an array. Each property will be\nrun as a function and the results will be passed to the final callback as an object\ninstead of an array. This can be a more readable way of handling results from\nasync.series.\n\n\n__Arguments__\n\n* tasks - An array or object containing functions to run, each function is passed\n a callback it must call on completion.\n* callback(err, results) - An optional callback to run once all the functions\n have completed. This function gets an array of all the arguments passed to\n the callbacks used in the array.\n\n__Example__\n\n async.series([\n function(callback){\n // do some stuff ...\n callback(null, \'one\');\n },\n function(callback){\n // do some more stuff ...\n callback(null, \'two\');\n },\n ],\n // optional callback\n function(err, results){\n // results is now equal to [\'one\', \'two\']\n });\n\n\n // an example using an object instead of an array\n async.series({\n one: function(callback){\n setTimeout(function(){\n callback(null, 1);\n }, 200);\n },\n two: function(callback){\n setTimeout(function(){\n callback(null, 2);\n }, 100);\n },\n },\n function(err, results) {\n // results is now equal to: {one: 1, two: 2}\n });\n\n\n---------------------------------------\n\n\n### parallel(tasks, [callback])\n\nRun an array of functions in parallel, without waiting until the previous\nfunction has completed. If any of the functions pass an error to its\ncallback, the main callback is immediately called with the value of the error.\nOnce the tasks have completed, the results are passed to the final callback as an\narray.\n\nIt is also possible to use an object instead of an array. Each property will be\nrun as a function and the results will be passed to the final callback as an object\ninstead of an array. This can be a more readable way of handling results from\nasync.parallel.\n\n\n__Arguments__\n\n* tasks - An array or object containing functions to run, each function is passed a\n callback it must call on completion.\n* callback(err, results) - An optional callback to run once all the functions\n have completed. This function gets an array of all the arguments passed to\n the callbacks used in the array.\n\n__Example__\n\n async.parallel([\n function(callback){\n setTimeout(function(){\n callback(null, \'one\');\n }, 200);\n },\n function(callback){\n setTimeout(function(){\n callback(null, \'two\');\n }, 100);\n },\n ],\n // optional callback\n function(err, results){\n // the results array will equal [\'one\',\'two\'] even though\n // the second function had a shorter timeout.\n });\n\n\n // an example using an object instead of an array\n async.parallel({\n one: function(callback){\n setTimeout(function(){\n callback(null, 1);\n }, 200);\n },\n two: function(callback){\n setTimeout(function(){\n callback(null, 2);\n }, 100);\n },\n },\n function(err, results) {\n // results is now equals to: {one: 1, two: 2}\n });\n\n\n---------------------------------------\n\n\n### whilst(test, fn, callback)\n\nRepeatedly call fn, while test returns true. Calls the callback when stopped,\nor an error occurs.\n\n__Arguments__\n\n* test() - synchronous truth test to perform before each execution of fn.\n* fn(callback) - A function to call each time the test passes. The function is\n passed a callback which must be called once it has completed with an optional\n error as the first argument.\n* callback(err) - A callback which is called after the test fails and repeated\n execution of fn has stopped.\n\n__Example__\n\n var count = 0;\n\n async.whilst(\n function () { return count < 5; },\n function (callback) {\n count++;\n setTimeout(callback, 1000);\n },\n function (err) {\n // 5 seconds have passed\n }\n );\n\n\n---------------------------------------\n\n\n### until(test, fn, callback)\n\nRepeatedly call fn, until test returns true. Calls the callback when stopped,\nor an error occurs.\n\nThe inverse of async.whilst.\n\n\n---------------------------------------\n\n\n### waterfall(tasks, [callback])\n\nRuns an array of functions in series, each passing their results to the next in\nthe array. However, if any of the functions pass an error to the callback, the\nnext function is not executed and the main callback is immediately called with\nthe error.\n\n__Arguments__\n\n* tasks - An array of functions to run, each function is passed a callback it\n must call on completion.\n* callback(err, [results]) - An optional callback to run once all the functions\n have completed. This will be passed the results of the last task\'s callback.\n\n\n\n__Example__\n\n async.waterfall([\n function(callback){\n callback(null, \'one\', \'two\');\n },\n function(arg1, arg2, callback){\n callback(null, \'three\');\n },\n function(arg1, callback){\n // arg1 now equals \'three\'\n callback(null, \'done\');\n }\n ], function (err, result) {\n // result now equals \'done\' \n });\n\n\n---------------------------------------\n\n\n### queue(worker, concurrency)\n\nCreates a queue object with the specified concurrency. Tasks added to the\nqueue will be processed in parallel (up to the concurrency limit). If all\nworkers are in progress, the task is queued until one is available. Once\na worker has completed a task, the task\'s callback is called.\n\n__Arguments__\n\n* worker(task, callback) - An asynchronous function for processing a queued\n task.\n* concurrency - An integer for determining how many worker functions should be\n run in parallel.\n\n__Queue objects__\n\nThe queue object returned by this function has the following properties and\nmethods:\n\n* length() - a function returning the number of items waiting to be processed.\n* concurrency - an integer for determining how many worker functions should be\n run in parallel. This property can be changed after a queue is created to\n alter the concurrency on-the-fly.\n* push(task, [callback]) - add a new task to the queue, the callback is called\n once the worker has finished processing the task.\n instead of a single task, an array of tasks can be submitted. the respective callback is used for every task in the list.\n* saturated - a callback that is called when the queue length hits the concurrency and further tasks will be queued\n* empty - a callback that is called when the last item from the queue is given to a worker\n* drain - a callback that is called when the last item from the queue has returned from the worker\n\n__Example__\n\n // create a queue object with concurrency 2\n\n var q = async.queue(function (task, callback) {\n console.log(\'hello \' + task.name);\n callback();\n }, 2);\n\n\n // assign a callback\n q.drain = function() {\n console.log(\'all items have been processed\');\n }\n\n // add some items to the queue\n\n q.push({name: \'foo\'}, function (err) {\n console.log(\'finished processing foo\');\n });\n q.push({name: \'bar\'}, function (err) {\n console.log(\'finished processing bar\');\n });\n\n // add some items to the queue (batch-wise)\n\n q.push([{name: \'baz\'},{name: \'bay\'},{name: \'bax\'}], function (err) {\n console.log(\'finished processing bar\');\n });\n\n\n---------------------------------------\n\n\n### auto(tasks, [callback])\n\nDetermines the best order for running functions based on their requirements.\nEach function can optionally depend on other functions being completed first,\nand each function is run as soon as its requirements are satisfied. If any of\nthe functions pass an error to their callback, that function will not complete\n(so any other functions depending on it will not run) and the main callback\nwill be called immediately with the error. Functions also receive an object\ncontaining the results of functions which have completed so far.\n\n__Arguments__\n\n* tasks - An object literal containing named functions or an array of\n requirements, with the function itself the last item in the array. The key\n used for each function or array is used when specifying requirements. The\n syntax is easier to understand by looking at the example.\n* callback(err, results) - An optional callback which is called when all the\n tasks have been completed. The callback will receive an error as an argument\n if any tasks pass an error to their callback. If all tasks complete\n successfully, it will receive an object containing their results.\n\n__Example__\n\n async.auto({\n get_data: function(callback){\n // async code to get some data\n },\n make_folder: function(callback){\n // async code to create a directory to store a file in\n // this is run at the same time as getting the data\n },\n write_file: [\'get_data\', \'make_folder\', function(callback){\n // once there is some data and the directory exists,\n // write the data to a file in the directory\n callback(null, filename);\n }],\n email_link: [\'write_file\', function(callback, results){\n // once the file is written let\'s email a link to it...\n // results.write_file contains the filename returned by write_file.\n }]\n });\n\nThis is a fairly trivial example, but to do this using the basic parallel and\nseries functions would look like this:\n\n async.parallel([\n function(callback){\n // async code to get some data\n },\n function(callback){\n // async code to create a directory to store a file in\n // this is run at the same time as getting the data\n }\n ],\n function(results){\n async.series([\n function(callback){\n // once there is some data and the directory exists,\n // write the data to a file in the directory\n },\n email_link: function(callback){\n // once the file is written let\'s email a link to it...\n }\n ]);\n });\n\nFor a complicated series of async tasks using the auto function makes adding\nnew tasks much easier and makes the code more readable.\n\n\n---------------------------------------\n\n\n### iterator(tasks)\n\nCreates an iterator function which calls the next function in the array,\nreturning a continuation to call the next one after that. Its also possible to\n\'peek\' the next iterator by doing iterator.next().\n\nThis function is used internally by the async module but can be useful when\nyou want to manually control the flow of functions in series.\n\n__Arguments__\n\n* tasks - An array of functions to run, each function is passed a callback it\n must call on completion.\n\n__Example__\n\n var iterator = async.iterator([\n function(){ sys.p(\'one\'); },\n function(){ sys.p(\'two\'); },\n function(){ sys.p(\'three\'); }\n ]);\n\n node> var iterator2 = iterator();\n \'one\'\n node> var iterator3 = iterator2();\n \'two\'\n node> iterator3();\n \'three\'\n node> var nextfn = iterator2.next();\n node> nextfn();\n \'three\'\n\n\n---------------------------------------\n\n\n### apply(function, arguments..)\n\nCreates a continuation function with some arguments already applied, a useful\nshorthand when combined with other control flow functions. Any arguments\npassed to the returned function are added to the arguments originally passed\nto apply.\n\n__Arguments__\n\n* function - The function you want to eventually apply all arguments to.\n* arguments... - Any number of arguments to automatically apply when the\n continuation is called.\n\n__Example__\n\n // using apply\n\n async.parallel([\n async.apply(fs.writeFile, \'testfile1\', \'test1\'),\n async.apply(fs.writeFile, \'testfile2\', \'test2\'),\n ]);\n\n\n // the same process without using apply\n\n async.parallel([\n function(callback){\n fs.writeFile(\'testfile1\', \'test1\', callback);\n },\n function(callback){\n fs.writeFile(\'testfile2\', \'test2\', callback);\n },\n ]);\n\nIt\'s possible to pass any number of additional arguments when calling the\ncontinuation:\n\n node> var fn = async.apply(sys.puts, \'one\');\n node> fn(\'two\', \'three\');\n one\n two\n three\n\n---------------------------------------\n\n\n### nextTick(callback)\n\nCalls the callback on a later loop around the event loop. In node.js this just\ncalls process.nextTick, in the browser it falls back to setTimeout(callback, 0),\nwhich means other higher priority events may precede the execution of the callback.\n\nThis is used internally for browser-compatibility purposes.\n\n__Arguments__\n\n* callback - The function to call on a later loop around the event loop.\n\n__Example__\n\n var call_order = [];\n async.nextTick(function(){\n call_order.push(\'two\');\n // call_order now equals [\'one\',\'two]\n });\n call_order.push(\'one\')\n\n\n## Utils\n\n\n### memoize(fn, [hasher])\n\nCaches the results of an async function. When creating a hash to store function\nresults against, the callback is omitted from the hash and an optional hash\nfunction can be used.\n\n__Arguments__\n\n* fn - the function you to proxy and cache results from.\n* hasher - an optional function for generating a custom hash for storing\n results, it has all the arguments applied to it apart from the callback, and\n must be synchronous.\n\n__Example__\n\n var slow_fn = function (name, callback) {\n // do something\n callback(null, result);\n };\n var fn = async.memoize(slow_fn);\n\n // fn can now be used as if it were slow_fn\n fn(\'some name\', function () {\n // callback\n });\n\n\n### unmemoize(fn)\n\nUndoes a memoized function, reverting it to the original, unmemoized\nform. Comes handy in tests.\n\n__Arguments__\n\n* fn - the memoized function\n\n\n### log(function, arguments)\n\nLogs the result of an async function to the console. Only works in node.js or\nin browsers that support console.log and console.error (such as FF and Chrome).\nIf multiple arguments are returned from the async function, console.log is\ncalled on each argument in order.\n\n__Arguments__\n\n* function - The function you want to eventually apply all arguments to.\n* arguments... - Any number of arguments to apply to the function.\n\n__Example__\n\n var hello = function(name, callback){\n setTimeout(function(){\n callback(null, \'hello \' + name);\n }, 1000);\n };\n\n node> async.log(hello, \'world\');\n \'hello world\'\n\n\n---------------------------------------\n\n\n### dir(function, arguments)\n\nLogs the result of an async function to the console using console.dir to\ndisplay the properties of the resulting object. Only works in node.js or\nin browsers that support console.dir and console.error (such as FF and Chrome).\nIf multiple arguments are returned from the async function, console.dir is\ncalled on each argument in order.\n\n__Arguments__\n\n* function - The function you want to eventually apply all arguments to.\n* arguments... - Any number of arguments to apply to the function.\n\n__Example__\n\n var hello = function(name, callback){\n setTimeout(function(){\n callback(null, {hello: name});\n }, 1000);\n };\n\n node> async.dir(hello, \'world\');\n {hello: \'world\'}\n\n\n---------------------------------------\n\n\n### noConflict()\n\nChanges the value of async back to its original value, returning a reference to the\nasync object.\n', +4742 silly resolved readmeFilename: 'README.md', +4742 silly resolved homepage: 'https://github.com/caolan/async', +4742 silly resolved _id: 'async@0.1.22', +4742 silly resolved _from: 'async@0.1.22', +4742 silly resolved scripts: {} } ] +4743 info install async@0.1.22 into /usr/lib/node_modules/jsdoc +4744 info installOne async@0.1.22 +4745 silly resolved [ { name: 'underscore', +4745 silly resolved description: 'JavaScript\'s functional programming helper library.', +4745 silly resolved homepage: 'http://underscorejs.org', +4745 silly resolved keywords: [ 'util', 'functional', 'server', 'client', 'browser' ], +4745 silly resolved author: { name: 'Jeremy Ashkenas', email: 'jeremy@documentcloud.org' }, +4745 silly resolved repository: +4745 silly resolved { type: 'git', +4745 silly resolved url: 'git://github.com/jashkenas/underscore.git' }, +4745 silly resolved main: 'underscore.js', +4745 silly resolved version: '1.6.0', +4745 silly resolved devDependencies: { docco: '0.6.x', phantomjs: '1.9.0-1', 'uglify-js': '2.4.x' }, +4745 silly resolved scripts: +4745 silly resolved { test: 'phantomjs test/vendor/runner.js test/index.html?noglobals=true', +4745 silly resolved build: 'uglifyjs underscore.js -c "evaluate=false" --comments "/ .*/" -m --source-map underscore-min.map -o underscore-min.js', +4745 silly resolved doc: 'docco underscore.js' }, +4745 silly resolved licenses: [ [Object] ], +4745 silly resolved files: [ 'underscore.js', 'underscore-min.js', 'LICENSE' ], +4745 silly resolved bugs: { url: 'https://github.com/jashkenas/underscore/issues' }, +4745 silly resolved _id: 'underscore@1.6.0', +4745 silly resolved dist: +4745 silly resolved { shasum: '8b38b10cacdef63337b8b24e4ff86d45aea529a8', +4745 silly resolved tarball: 'http://registry.npmjs.org/underscore/-/underscore-1.6.0.tgz' }, +4745 silly resolved _from: 'underscore@1.6.0', +4745 silly resolved _npmVersion: '1.3.21', +4745 silly resolved _npmUser: { name: 'jashkenas', email: 'jashkenas@gmail.com' }, +4745 silly resolved maintainers: [ [Object] ], +4745 silly resolved directories: {}, +4745 silly resolved _shasum: '8b38b10cacdef63337b8b24e4ff86d45aea529a8', +4745 silly resolved _resolved: 'https://registry.npmjs.org/underscore/-/underscore-1.6.0.tgz', +4745 silly resolved readme: 'ERROR: No README data found!' } ] +4746 info install underscore@1.6.0 into /usr/lib/node_modules/jsdoc +4747 info installOne underscore@1.6.0 +4748 silly resolved [ { name: 'underscore', +4748 silly resolved description: 'JavaScript\'s functional programming helper library.', +4748 silly resolved homepage: 'http://underscorejs.org', +4748 silly resolved keywords: [ 'util', 'functional', 'server', 'client', 'browser' ], +4748 silly resolved author: { name: 'Jeremy Ashkenas', email: 'jeremy@documentcloud.org' }, +4748 silly resolved repository: +4748 silly resolved { type: 'git', +4748 silly resolved url: 'git://github.com/jashkenas/underscore.git' }, +4748 silly resolved main: 'underscore.js', +4748 silly resolved version: '1.6.0', +4748 silly resolved devDependencies: { docco: '0.6.x', phantomjs: '1.9.0-1', 'uglify-js': '2.4.x' }, +4748 silly resolved scripts: +4748 silly resolved { test: 'phantomjs test/vendor/runner.js test/index.html?noglobals=true', +4748 silly resolved build: 'uglifyjs underscore.js -c "evaluate=false" --comments "/ .*/" -m --source-map underscore-min.map -o underscore-min.js', +4748 silly resolved doc: 'docco underscore.js' }, +4748 silly resolved licenses: [ [Object] ], +4748 silly resolved files: [ 'underscore.js', 'underscore-min.js', 'LICENSE' ], +4748 silly resolved bugs: { url: 'https://github.com/jashkenas/underscore/issues' }, +4748 silly resolved _id: 'underscore@1.6.0', +4748 silly resolved dist: +4748 silly resolved { shasum: '8b38b10cacdef63337b8b24e4ff86d45aea529a8', +4748 silly resolved tarball: 'http://registry.npmjs.org/underscore/-/underscore-1.6.0.tgz' }, +4748 silly resolved _from: 'underscore@1.6.0', +4748 silly resolved _npmVersion: '1.3.21', +4748 silly resolved _npmUser: { name: 'jashkenas', email: 'jashkenas@gmail.com' }, +4748 silly resolved maintainers: [ [Object] ], +4748 silly resolved directories: {}, +4748 silly resolved _shasum: '8b38b10cacdef63337b8b24e4ff86d45aea529a8', +4748 silly resolved _resolved: 'https://registry.npmjs.org/underscore/-/underscore-1.6.0.tgz', +4748 silly resolved readme: 'ERROR: No README data found!' } ] +4749 info install underscore@1.6.0 into /usr/lib/node_modules/jsdoc/node_modules/requizzle +4750 info installOne underscore@1.6.0 +4751 silly resolved [ { name: 'underscore', +4751 silly resolved description: 'JavaScript\'s functional programming helper library.', +4751 silly resolved homepage: 'http://underscorejs.org', +4751 silly resolved keywords: [ 'util', 'functional', 'server', 'client', 'browser' ], +4751 silly resolved author: { name: 'Jeremy Ashkenas', email: 'jeremy@documentcloud.org' }, +4751 silly resolved repository: +4751 silly resolved { type: 'git', +4751 silly resolved url: 'git://github.com/jashkenas/underscore.git' }, +4751 silly resolved main: 'underscore.js', +4751 silly resolved version: '1.6.0', +4751 silly resolved devDependencies: { docco: '0.6.x', phantomjs: '1.9.0-1', 'uglify-js': '2.4.x' }, +4751 silly resolved scripts: +4751 silly resolved { test: 'phantomjs test/vendor/runner.js test/index.html?noglobals=true', +4751 silly resolved build: 'uglifyjs underscore.js -c "evaluate=false" --comments "/ .*/" -m --source-map underscore-min.map -o underscore-min.js', +4751 silly resolved doc: 'docco underscore.js' }, +4751 silly resolved licenses: [ [Object] ], +4751 silly resolved files: [ 'underscore.js', 'underscore-min.js', 'LICENSE' ], +4751 silly resolved bugs: { url: 'https://github.com/jashkenas/underscore/issues' }, +4751 silly resolved _id: 'underscore@1.6.0', +4751 silly resolved dist: +4751 silly resolved { shasum: '8b38b10cacdef63337b8b24e4ff86d45aea529a8', +4751 silly resolved tarball: 'http://registry.npmjs.org/underscore/-/underscore-1.6.0.tgz' }, +4751 silly resolved _from: 'underscore@1.6.0', +4751 silly resolved _npmVersion: '1.3.21', +4751 silly resolved _npmUser: { name: 'jashkenas', email: 'jashkenas@gmail.com' }, +4751 silly resolved maintainers: [ [Object] ], +4751 silly resolved directories: {}, +4751 silly resolved _shasum: '8b38b10cacdef63337b8b24e4ff86d45aea529a8', +4751 silly resolved _resolved: 'https://registry.npmjs.org/underscore/-/underscore-1.6.0.tgz', +4751 silly resolved readme: 'ERROR: No README data found!' } ] +4752 info install underscore@1.6.0 into /usr/lib/node_modules/jsdoc/node_modules/catharsis/node_modules/underscore-contrib +4753 info installOne underscore@1.6.0 +4754 silly resolved [ { name: 'wrench', +4754 silly resolved description: 'Recursive filesystem (and other) operations that Node *should* have.', +4754 silly resolved version: '1.3.9', +4754 silly resolved author: { name: 'Ryan McGrath', email: 'ryan@venodesigns.net' }, +4754 silly resolved repository: +4754 silly resolved { type: 'git', +4754 silly resolved url: 'https://ryanmcgrath@github.com/ryanmcgrath/wrench-js.git' }, +4754 silly resolved bugs: { url: 'http://github.com/ryanmcgrath/wrench-js/issues' }, +4754 silly resolved directories: { lib: './lib/' }, +4754 silly resolved dependencies: {}, +4754 silly resolved devDependencies: { nodeunit: '>= 0.6.4' }, +4754 silly resolved main: './lib/wrench', +4754 silly resolved engines: { node: '>=0.1.97' }, +4754 silly resolved scripts: { test: 'nodeunit tests/runner.js' }, +4754 silly resolved licenses: [ [Object] ], +4754 silly resolved readme: 'wrench.js - Recursive file operations in Node.js\n----------------------------------------------------------------------------\nWhile I love Node.js, I\'ve found myself missing some functions. Things like\nrecursively deleting/chmodding a directory (or even deep copying a directory),\nor even a basic line reader, shouldn\'t need to be re-invented time and time again.\n\nThat said, here\'s my attempt at a re-usable solution, at least until something\nmore formalized gets integrated into Node.js (*hint hint*). wrench.js is fairly simple\nto use - check out the documentation/examples below:\n\nInstallation\n-----------------------------------------------------------------------------\n\n npm install wrench\n\nUsage\n-----------------------------------------------------------------------------\n``` javascript\nvar wrench = require(\'wrench\'),\n\tutil = require(\'util\');\n```\n\n### Synchronous operations\n``` javascript\n// Recursively create directories, sub-trees and all.\nwrench.mkdirSyncRecursive(dir, 0777);\n\n// Recursively delete the entire sub-tree of a directory, then kill the directory\nwrench.rmdirSyncRecursive(\'my_directory_name\', failSilently);\n\n// Recursively read directories contents.\nwrench.readdirSyncRecursive(\'my_directory_name\');\n\n// Recursively chmod the entire sub-tree of a directory\nwrench.chmodSyncRecursive(\'my_directory_name\', 0755);\n\n// Recursively chown the entire sub-tree of a directory\nwrench.chownSyncRecursive("directory", uid, gid);\n\n// Deep-copy an existing directory\nwrench.copyDirSyncRecursive(\'directory_to_copy\', \'location_where_copy_should_end_up\');\n\n// Read lines in from a file until you hit the end\nvar f = new wrench.LineReader(\'x.txt\');\nwhile(f.hasNextLine()) {\n\tutil.puts(x.getNextLine());\n}\n```\n\n### Asynchronous operations\n``` javascript\n// Recursively read directories contents\nvar files = [];\nwrench.readdirRecursive(\'my_directory_name\', function(error, curFiles) {\n // curFiles is what you want\n});\n\n```\n\nQuestions, comments? Hit me up. (ryan [at] venodesigns.net | http://twitter.com/ryanmcgrath)\n', +4754 silly resolved readmeFilename: 'readme.md', +4754 silly resolved homepage: 'https://github.com/ryanmcgrath/wrench-js', +4754 silly resolved _id: 'wrench@1.3.9', +4754 silly resolved _shasum: '6f13ec35145317eb292ca5f6531391b244111411', +4754 silly resolved _from: 'wrench@1.3.9', +4754 silly resolved _resolved: 'https://registry.npmjs.org/wrench/-/wrench-1.3.9.tgz' } ] +4755 info install wrench@1.3.9 into /usr/lib/node_modules/jsdoc +4756 info installOne wrench@1.3.9 +4757 silly resolved [ { author: +4757 silly resolved { name: 'Robert Kieffer', +4757 silly resolved email: 'robert@broofa.com', +4757 silly resolved url: 'http://github.com/broofa' }, +4757 silly resolved contributors: [ [Object] ], +4757 silly resolved dependencies: {}, +4757 silly resolved description: 'A comprehensive library for mime-type mapping', +4757 silly resolved devDependencies: {}, +4757 silly resolved keywords: [ 'util', 'mime' ], +4757 silly resolved main: 'mime.js', +4757 silly resolved name: 'mime', +4757 silly resolved repository: { url: 'https://github.com/broofa/node-mime', type: 'git' }, +4757 silly resolved version: '1.2.11', +4757 silly resolved readme: '# mime\n\nComprehensive MIME type mapping API. Includes all 600+ types and 800+ extensions defined by the Apache project, plus additional types submitted by the node.js community.\n\n## Install\n\nInstall with [npm](http://github.com/isaacs/npm):\n\n npm install mime\n\n## API - Queries\n\n### mime.lookup(path)\nGet the mime type associated with a file, if no mime type is found `application/octet-stream` is returned. Performs a case-insensitive lookup using the extension in `path` (the substring after the last \'/\' or \'.\'). E.g.\n\n var mime = require(\'mime\');\n\n mime.lookup(\'/path/to/file.txt\'); // => \'text/plain\'\n mime.lookup(\'file.txt\'); // => \'text/plain\'\n mime.lookup(\'.TXT\'); // => \'text/plain\'\n mime.lookup(\'htm\'); // => \'text/html\'\n\n### mime.default_type\nSets the mime type returned when `mime.lookup` fails to find the extension searched for. (Default is `application/octet-stream`.)\n\n### mime.extension(type)\nGet the default extension for `type`\n\n mime.extension(\'text/html\'); // => \'html\'\n mime.extension(\'application/octet-stream\'); // => \'bin\'\n\n### mime.charsets.lookup()\n\nMap mime-type to charset\n\n mime.charsets.lookup(\'text/plain\'); // => \'UTF-8\'\n\n(The logic for charset lookups is pretty rudimentary. Feel free to suggest improvements.)\n\n## API - Defining Custom Types\n\nThe following APIs allow you to add your own type mappings within your project. If you feel a type should be included as part of node-mime, see [requesting new types](https://github.com/broofa/node-mime/wiki/Requesting-New-Types).\n\n### mime.define()\n\nAdd custom mime/extension mappings\n\n mime.define({\n \'text/x-some-format\': [\'x-sf\', \'x-sft\', \'x-sfml\'],\n \'application/x-my-type\': [\'x-mt\', \'x-mtt\'],\n // etc ...\n });\n\n mime.lookup(\'x-sft\'); // => \'text/x-some-format\'\n\nThe first entry in the extensions array is returned by `mime.extension()`. E.g.\n\n mime.extension(\'text/x-some-format\'); // => \'x-sf\'\n\n### mime.load(filepath)\n\nLoad mappings from an Apache ".types" format file\n\n mime.load(\'./my_project.types\');\n\nThe .types file format is simple - See the `types` dir for examples.\n', +4757 silly resolved readmeFilename: 'README.md', +4757 silly resolved bugs: { url: 'https://github.com/broofa/node-mime/issues' }, +4757 silly resolved _id: 'mime@1.2.11', +4757 silly resolved dist: +4757 silly resolved { shasum: '58203eed86e3a5ef17aed2b7d9ebd47f0a60dd10', +4757 silly resolved tarball: 'http://registry.npmjs.org/mime/-/mime-1.2.11.tgz' }, +4757 silly resolved _from: 'mime@1.2.11', +4757 silly resolved _npmVersion: '1.3.6', +4757 silly resolved _npmUser: { name: 'broofa', email: 'robert@broofa.com' }, +4757 silly resolved maintainers: [ [Object], [Object] ], +4757 silly resolved directories: {}, +4757 silly resolved _shasum: '58203eed86e3a5ef17aed2b7d9ebd47f0a60dd10', +4757 silly resolved _resolved: 'https://registry.npmjs.org/mime/-/mime-1.2.11.tgz', +4757 silly resolved homepage: 'https://github.com/broofa/node-mime', +4757 silly resolved scripts: {} } ] +4758 info install mime@1.2.11 into /usr/lib/node_modules/express/node_modules/send +4759 info installOne mime@1.2.11 +4760 silly resolved [ { name: 'request', +4760 silly resolved description: 'Simplified HTTP request client.', +4760 silly resolved tags: [ 'http', 'simple', 'util', 'utility' ], +4760 silly resolved version: '2.34.0', +4760 silly resolved author: { name: 'Mikeal Rogers', email: 'mikeal.rogers@gmail.com' }, +4760 silly resolved repository: { type: 'git', url: 'http://github.com/mikeal/request.git' }, +4760 silly resolved bugs: { url: 'http://github.com/mikeal/request/issues' }, +4760 silly resolved license: 'Apache, Version 2.0', +4760 silly resolved engines: [ 'node >= 0.8.0' ], +4760 silly resolved main: 'index.js', +4760 silly resolved dependencies: +4760 silly resolved { qs: '~0.6.0', +4760 silly resolved 'json-stringify-safe': '~5.0.0', +4760 silly resolved 'forever-agent': '~0.5.0', +4760 silly resolved 'node-uuid': '~1.4.0', +4760 silly resolved mime: '~1.2.9', +4760 silly resolved 'tough-cookie': '>=0.12.0', +4760 silly resolved 'form-data': '~0.1.0', +4760 silly resolved 'tunnel-agent': '~0.3.0', +4760 silly resolved 'http-signature': '~0.10.0', +4760 silly resolved 'oauth-sign': '~0.3.0', +4760 silly resolved hawk: '~1.0.0', +4760 silly resolved 'aws-sign2': '~0.5.0' }, +4760 silly resolved optionalDependencies: +4760 silly resolved { 'tough-cookie': '>=0.12.0', +4760 silly resolved 'form-data': '~0.1.0', +4760 silly resolved 'tunnel-agent': '~0.3.0', +4760 silly resolved 'http-signature': '~0.10.0', +4760 silly resolved 'oauth-sign': '~0.3.0', +4760 silly resolved hawk: '~1.0.0', +4760 silly resolved 'aws-sign2': '~0.5.0' }, +4760 silly resolved scripts: { test: 'node tests/run.js' }, +4760 silly resolved readme: '# Request -- Simplified HTTP client\n\n[![NPM](https://nodei.co/npm/request.png)](https://nodei.co/npm/request/)\n\n## Super simple to use\n\nRequest is designed to be the simplest way possible to make http calls. It supports HTTPS and follows redirects by default.\n\n```javascript\nvar request = require(\'request\');\nrequest(\'http://www.google.com\', function (error, response, body) {\n if (!error && response.statusCode == 200) {\n console.log(body) // Print the google web page.\n }\n})\n```\n\n## Streaming\n\nYou can stream any response to a file stream.\n\n```javascript\nrequest(\'http://google.com/doodle.png\').pipe(fs.createWriteStream(\'doodle.png\'))\n```\n\nYou can also stream a file to a PUT or POST request. This method will also check the file extension against a mapping of file extensions to content-types (in this case `application/json`) and use the proper `content-type` in the PUT request (if the headers don’t already provide one).\n\n```javascript\nfs.createReadStream(\'file.json\').pipe(request.put(\'http://mysite.com/obj.json\'))\n```\n\nRequest can also `pipe` to itself. When doing so, `content-type` and `content-length` are preserved in the PUT headers.\n\n```javascript\nrequest.get(\'http://google.com/img.png\').pipe(request.put(\'http://mysite.com/img.png\'))\n```\n\nNow let’s get fancy.\n\n```javascript\nhttp.createServer(function (req, resp) {\n if (req.url === \'/doodle.png\') {\n if (req.method === \'PUT\') {\n req.pipe(request.put(\'http://mysite.com/doodle.png\'))\n } else if (req.method === \'GET\' || req.method === \'HEAD\') {\n request.get(\'http://mysite.com/doodle.png\').pipe(resp)\n }\n }\n})\n```\n\nYou can also `pipe()` from `http.ServerRequest` instances, as well as to `http.ServerResponse` instances. The HTTP method, headers, and entity-body data will be sent. Which means that, if you don\'t really care about security, you can do:\n\n```javascript\nhttp.createServer(function (req, resp) {\n if (req.url === \'/doodle.png\') {\n var x = request(\'http://mysite.com/doodle.png\')\n req.pipe(x)\n x.pipe(resp)\n }\n})\n```\n\nAnd since `pipe()` returns the destination stream in ≥ Node 0.5.x you can do one line proxying. :)\n\n```javascript\nreq.pipe(request(\'http://mysite.com/doodle.png\')).pipe(resp)\n```\n\nAlso, none of this new functionality conflicts with requests previous features, it just expands them.\n\n```javascript\nvar r = request.defaults({\'proxy\':\'http://localproxy.com\'})\n\nhttp.createServer(function (req, resp) {\n if (req.url === \'/doodle.png\') {\n r.get(\'http://google.com/doodle.png\').pipe(resp)\n }\n})\n```\n\nYou can still use intermediate proxies, the requests will still follow HTTP forwards, etc.\n\n## UNIX Socket \n\n`request` supports the `unix://` protocol for all requests. The path is assumed to be absolute to the root of the host file system. \n\nHTTP paths are extracted from the supplied URL by testing each level of the full URL against net.connect for a socket response.\n\nThus the following request will GET `/httppath` from the HTTP server listening on `/tmp/unix.socket`\n\n```javascript\nrequest.get(\'unix://tmp/unix.socket/httppath\')\n```\n\n## Forms\n\n`request` supports `application/x-www-form-urlencoded` and `multipart/form-data` form uploads. For `multipart/related` refer to the `multipart` API.\n\nURL-encoded forms are simple.\n\n```javascript\nrequest.post(\'http://service.com/upload\', {form:{key:\'value\'}})\n// or\nrequest.post(\'http://service.com/upload\').form({key:\'value\'})\n```\n\nFor `multipart/form-data` we use the [form-data](https://github.com/felixge/node-form-data) library by [@felixge](https://github.com/felixge). You don’t need to worry about piping the form object or setting the headers, `request` will handle that for you.\n\n```javascript\nvar r = request.post(\'http://service.com/upload\')\nvar form = r.form()\nform.append(\'my_field\', \'my_value\')\nform.append(\'my_buffer\', new Buffer([1, 2, 3]))\nform.append(\'my_file\', fs.createReadStream(path.join(__dirname, \'doodle.png\'))\nform.append(\'remote_file\', request(\'http://google.com/doodle.png\'))\n```\n\n## HTTP Authentication\n\n```javascript\nrequest.get(\'http://some.server.com/\').auth(\'username\', \'password\', false);\n// or\nrequest.get(\'http://some.server.com/\', {\n \'auth\': {\n \'user\': \'username\',\n \'pass\': \'password\',\n \'sendImmediately\': false\n }\n});\n```\n\nIf passed as an option, `auth` should be a hash containing values `user` || `username`, `password` || `pass`, and `sendImmediately` (optional). The method form takes parameters `auth(username, password, sendImmediately)`.\n\n`sendImmediately` defaults to `true`, which causes a basic authentication header to be sent. If `sendImmediately` is `false`, then `request` will retry with a proper authentication header after receiving a `401` response from the server (which must contain a `WWW-Authenticate` header indicating the required authentication method).\n\nDigest authentication is supported, but it only works with `sendImmediately` set to `false`; otherwise `request` will send basic authentication on the initial request, which will probably cause the request to fail.\n\n## OAuth Signing\n\n```javascript\n// Twitter OAuth\nvar qs = require(\'querystring\')\n , oauth =\n { callback: \'http://mysite.com/callback/\'\n , consumer_key: CONSUMER_KEY\n , consumer_secret: CONSUMER_SECRET\n }\n , url = \'https://api.twitter.com/oauth/request_token\'\n ;\nrequest.post({url:url, oauth:oauth}, function (e, r, body) {\n // Ideally, you would take the body in the response\n // and construct a URL that a user clicks on (like a sign in button).\n // The verifier is only available in the response after a user has\n // verified with twitter that they are authorizing your app.\n var access_token = qs.parse(body)\n , oauth =\n { consumer_key: CONSUMER_KEY\n , consumer_secret: CONSUMER_SECRET\n , token: access_token.oauth_token\n , verifier: access_token.oauth_verifier\n }\n , url = \'https://api.twitter.com/oauth/access_token\'\n ;\n request.post({url:url, oauth:oauth}, function (e, r, body) {\n var perm_token = qs.parse(body)\n , oauth =\n { consumer_key: CONSUMER_KEY\n , consumer_secret: CONSUMER_SECRET\n , token: perm_token.oauth_token\n , token_secret: perm_token.oauth_token_secret\n }\n , url = \'https://api.twitter.com/1.1/users/show.json?\'\n , params =\n { screen_name: perm_token.screen_name\n , user_id: perm_token.user_id\n }\n ;\n url += qs.stringify(params)\n request.get({url:url, oauth:oauth, json:true}, function (e, r, user) {\n console.log(user)\n })\n })\n})\n```\n\n### Custom HTTP Headers\n\nHTTP Headers, such as `User-Agent`, can be set in the `options` object.\nIn the example below, we call the github API to find out the number\nof stars and forks for the request repository. This requires a\ncustom `User-Agent` header as well as https.\n\n```javascript\nvar request = require(\'request\');\n\nvar options = {\n\turl: \'https://api.github.com/repos/mikeal/request\',\n\theaders: {\n\t\t\'User-Agent\': \'request\'\n\t}\n};\n\nfunction callback(error, response, body) {\n\tif (!error && response.statusCode == 200) {\n\t\tvar info = JSON.parse(body);\n\t\tconsole.log(info.stargazers_count + " Stars");\n\t\tconsole.log(info.forks_count + " Forks");\n\t}\n}\n\nrequest(options, callback);\n```\n\n### request(options, callback)\n\nThe first argument can be either a `url` or an `options` object. The only required option is `uri`; all others are optional.\n\n* `uri` || `url` - fully qualified uri or a parsed url object from `url.parse()`\n* `qs` - object containing querystring values to be appended to the `uri`\n* `method` - http method (default: `"GET"`)\n* `headers` - http headers (default: `{}`)\n* `body` - entity body for PATCH, POST and PUT requests. Must be a `Buffer` or `String`.\n* `form` - when passed an object, this sets `body` to a querystring representation of value, and adds `Content-type: application/x-www-form-urlencoded; charset=utf-8` header. When passed no options, a `FormData` instance is returned (and is piped to request).\n* `auth` - A hash containing values `user` || `username`, `password` || `pass`, and `sendImmediately` (optional). See documentation above.\n* `json` - sets `body` but to JSON representation of value and adds `Content-type: application/json` header. Additionally, parses the response body as JSON.\n* `multipart` - (experimental) array of objects which contains their own headers and `body` attribute. Sends `multipart/related` request. See example below.\n* `followRedirect` - follow HTTP 3xx responses as redirects (default: `true`)\n* `followAllRedirects` - follow non-GET HTTP 3xx responses as redirects (default: `false`)\n* `maxRedirects` - the maximum number of redirects to follow (default: `10`)\n* `encoding` - Encoding to be used on `setEncoding` of response data. If `null`, the `body` is returned as a `Buffer`.\n* `pool` - A hash object containing the agents for these requests. If omitted, the request will use the global pool (which is set to node\'s default `maxSockets`)\n* `pool.maxSockets` - Integer containing the maximum amount of sockets in the pool.\n* `timeout` - Integer containing the number of milliseconds to wait for a request to respond before aborting the request\n* `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`)\n* `oauth` - Options for OAuth HMAC-SHA1 signing. See documentation above.\n* `hawk` - Options for [Hawk signing](https://github.com/hueniverse/hawk). The `credentials` key must contain the necessary signing info, [see hawk docs for details](https://github.com/hueniverse/hawk#usage-example).\n* `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.\n* `jar` - If `true`, remember cookies for future use (or define your custom cookie jar; see examples section)\n* `aws` - `object` containing AWS signing information. Should have the properties `key`, `secret`. Also requires the property `bucket`, unless you’re specifying your `bucket` as part of the path, or the request doesn’t use a bucket (i.e. GET Services)\n* `httpSignature` - Options for the [HTTP Signature Scheme](https://github.com/joyent/node-http-signature/blob/master/http_signing.md) using [Joyent\'s library](https://github.com/joyent/node-http-signature). The `keyId` and `key` properties must be specified. See the docs for other options.\n* `localAddress` - Local interface to bind for network connections.\n\n\nThe callback argument gets 3 arguments: \n\n1. An `error` when applicable (usually from [`http.ClientRequest`](http://nodejs.org/api/http.html#http_class_http_clientrequest) object)\n2. An [`http.IncomingMessage`](http://nodejs.org/api/http.html#http_http_incomingmessage) object\n3. The third is the `response` body (`String` or `Buffer`, or JSON object if the `json` option is supplied)\n\n## Convenience methods\n\nThere are also shorthand methods for different HTTP METHODs and some other conveniences.\n\n### request.defaults(options)\n\nThis method returns a wrapper around the normal request API that defaults to whatever options you pass in to it.\n\n### request.put\n\nSame as `request()`, but defaults to `method: "PUT"`.\n\n```javascript\nrequest.put(url)\n```\n\n### request.patch\n\nSame as `request()`, but defaults to `method: "PATCH"`.\n\n```javascript\nrequest.patch(url)\n```\n\n### request.post\n\nSame as `request()`, but defaults to `method: "POST"`.\n\n```javascript\nrequest.post(url)\n```\n\n### request.head\n\nSame as request() but defaults to `method: "HEAD"`.\n\n```javascript\nrequest.head(url)\n```\n\n### request.del\n\nSame as `request()`, but defaults to `method: "DELETE"`.\n\n```javascript\nrequest.del(url)\n```\n\n### request.get\n\nSame as `request()` (for uniformity).\n\n```javascript\nrequest.get(url)\n```\n### request.cookie\n\nFunction that creates a new cookie.\n\n```javascript\nrequest.cookie(\'cookie_string_here\')\n```\n### request.jar\n\nFunction that creates a new cookie jar.\n\n```javascript\nrequest.jar()\n```\n\n\n## Examples:\n\n```javascript\n var request = require(\'request\')\n , rand = Math.floor(Math.random()*100000000).toString()\n ;\n request(\n { method: \'PUT\'\n , uri: \'http://mikeal.iriscouch.com/testjs/\' + rand\n , multipart:\n [ { \'content-type\': \'application/json\'\n , body: JSON.stringify({foo: \'bar\', _attachments: {\'message.txt\': {follows: true, length: 18, \'content_type\': \'text/plain\' }}})\n }\n , { body: \'I am an attachment\' }\n ]\n }\n , function (error, response, body) {\n if(response.statusCode == 201){\n console.log(\'document saved as: http://mikeal.iriscouch.com/testjs/\'+ rand)\n } else {\n console.log(\'error: \'+ response.statusCode)\n console.log(body)\n }\n }\n )\n```\n\nCookies are disabled by default (else, they would be used in subsequent requests). To enable cookies, set `jar` to `true` (either in `defaults` or `options`).\n\n```javascript\nvar request = request.defaults({jar: true})\nrequest(\'http://www.google.com\', function () {\n request(\'http://images.google.com\')\n})\n```\n\nTo use a custom cookie jar (instead `request`’s global cookie jar), set `jar` to an instance of `request.jar()` (either in `defaults` or `options`)\n\n```javascript\nvar j = request.jar()\nvar request = request.defaults({jar:j})\nrequest(\'http://www.google.com\', function () {\n request(\'http://images.google.com\')\n})\n```\n\nOR\n\n```javascript\nvar j = request.jar()\nvar cookie = request.cookie(\'your_cookie_here\')\nj.setCookie(cookie, uri);\nrequest({url: \'http://www.google.com\', jar: j}, function () {\n request(\'http://images.google.com\')\n})\n```\n', +4760 silly resolved readmeFilename: 'README.md', +4760 silly resolved homepage: 'https://github.com/mikeal/request', +4760 silly resolved _id: 'request@2.34.0', +4760 silly resolved _shasum: 'b5d8b9526add4a2d4629f4d417124573996445ae', +4760 silly resolved _from: 'request@2.34.0', +4760 silly resolved _resolved: 'https://registry.npmjs.org/request/-/request-2.34.0.tgz' } ] +4761 info install request@2.34.0 into /usr/lib/node_modules/zombie +4762 info installOne request@2.34.0 +4763 silly resolved [ { name: 'commander', +4763 silly resolved version: '2.2.0', +4763 silly resolved description: 'the complete solution for node.js command-line programs', +4763 silly resolved keywords: [ 'command', 'option', 'parser', 'prompt', 'stdin' ], +4763 silly resolved author: { name: 'TJ Holowaychuk', email: 'tj@vision-media.ca' }, +4763 silly resolved repository: +4763 silly resolved { type: 'git', +4763 silly resolved url: 'https://github.com/visionmedia/commander.js.git' }, +4763 silly resolved devDependencies: { should: '>= 0.0.1' }, +4763 silly resolved scripts: { test: 'make test' }, +4763 silly resolved main: 'index', +4763 silly resolved engines: { node: '>= 0.6.x' }, +4763 silly resolved files: [ 'index.js' ], +4763 silly resolved readme: '# Commander.js\n\n The complete solution for [node.js](http://nodejs.org) command-line interfaces, inspired by Ruby\'s [commander](https://github.com/visionmedia/commander).\n\n [![Build Status](https://secure.travis-ci.org/visionmedia/commander.js.png)](http://travis-ci.org/visionmedia/commander.js)\n\n## Installation\n\n $ npm install commander\n\n## Option parsing\n\n Options with commander are defined with the `.option()` method, also serving as documentation for the options. The example below parses args and options from `process.argv`, leaving remaining args as the `program.args` array which were not consumed by options.\n\n```js\n#!/usr/bin/env node\n\n/**\n * Module dependencies.\n */\n\nvar program = require(\'commander\');\n\nprogram\n .version(\'0.0.1\')\n .option(\'-p, --peppers\', \'Add peppers\')\n .option(\'-P, --pineapple\', \'Add pineapple\')\n .option(\'-b, --bbq\', \'Add bbq sauce\')\n .option(\'-c, --cheese [type]\', \'Add the specified type of cheese [marble]\', \'marble\')\n .parse(process.argv);\n\nconsole.log(\'you ordered a pizza with:\');\nif (program.peppers) console.log(\' - peppers\');\nif (program.pineapple) console.log(\' - pineapple\');\nif (program.bbq) console.log(\' - bbq\');\nconsole.log(\' - %s cheese\', program.cheese);\n```\n\n Short flags may be passed as a single arg, for example `-abc` is equivalent to `-a -b -c`. Multi-word options such as "--template-engine" are camel-cased, becoming `program.templateEngine` etc.\n\n## Automated --help\n\n The help information is auto-generated based on the information commander already knows about your program, so the following `--help` info is for free:\n\n``` \n $ ./examples/pizza --help\n\n Usage: pizza [options]\n\n Options:\n\n -V, --version output the version number\n -p, --peppers Add peppers\n -P, --pineapple Add pineapple\n -b, --bbq Add bbq sauce\n -c, --cheese Add the specified type of cheese [marble]\n -h, --help output usage information\n\n```\n\n## Coercion\n\n```js\nfunction range(val) {\n return val.split(\'..\').map(Number);\n}\n\nfunction list(val) {\n return val.split(\',\');\n}\n\nfunction collect(val, memo) {\n memo.push(val);\n return memo;\n}\n\nfunction increaseVerbosity(v, total) {\n return total + 1;\n}\n\nprogram\n .version(\'0.0.1\')\n .usage(\'[options] \')\n .option(\'-i, --integer \', \'An integer argument\', parseInt)\n .option(\'-f, --float \', \'A float argument\', parseFloat)\n .option(\'-r, --range ..\', \'A range\', range)\n .option(\'-l, --list \', \'A list\', list)\n .option(\'-o, --optional [value]\', \'An optional value\')\n .option(\'-c, --collect [value]\', \'A repeatable value\', [])\n .option(\'-v, --verbose\', \'A value that can be increased\', increaseVerbosity, 0)\n .parse(process.argv);\n\nconsole.log(\' int: %j\', program.integer);\nconsole.log(\' float: %j\', program.float);\nconsole.log(\' optional: %j\', program.optional);\nprogram.range = program.range || [];\nconsole.log(\' range: %j..%j\', program.range[0], program.range[1]);\nconsole.log(\' list: %j\', program.list);\nconsole.log(\' collect: %j\', program.collect);\nconsole.log(\' verbosity: %j\', program.verbose);\nconsole.log(\' args: %j\', program.args);\n```\n\n## Custom help\n\n You can display arbitrary `-h, --help` information\n by listening for "--help". Commander will automatically\n exit once you are done so that the remainder of your program\n does not execute causing undesired behaviours, for example\n in the following executable "stuff" will not output when\n `--help` is used.\n\n```js\n#!/usr/bin/env node\n\n/**\n * Module dependencies.\n */\n\nvar program = require(\'../\');\n\nfunction list(val) {\n return val.split(\',\').map(Number);\n}\n\nprogram\n .version(\'0.0.1\')\n .option(\'-f, --foo\', \'enable some foo\')\n .option(\'-b, --bar\', \'enable some bar\')\n .option(\'-B, --baz\', \'enable some baz\');\n\n// must be before .parse() since\n// node\'s emit() is immediate\n\nprogram.on(\'--help\', function(){\n console.log(\' Examples:\');\n console.log(\'\');\n console.log(\' $ custom-help --help\');\n console.log(\' $ custom-help -h\');\n console.log(\'\');\n});\n\nprogram.parse(process.argv);\n\nconsole.log(\'stuff\');\n```\n\nyielding the following help output:\n\n```\n\nUsage: custom-help [options]\n\nOptions:\n\n -h, --help output usage information\n -V, --version output the version number\n -f, --foo enable some foo\n -b, --bar enable some bar\n -B, --baz enable some baz\n\nExamples:\n\n $ custom-help --help\n $ custom-help -h\n\n```\n\n## .outputHelp()\n\n Output help information without exiting.\n\n## .help()\n\n Output help information and exit immediately.\n\n## Links\n\n - [API documentation](http://visionmedia.github.com/commander.js/)\n - [ascii tables](https://github.com/LearnBoost/cli-table)\n - [progress bars](https://github.com/visionmedia/node-progress)\n - [more progress bars](https://github.com/substack/node-multimeter)\n - [examples](https://github.com/visionmedia/commander.js/tree/master/examples)\n\n## License \n\n(The MIT License)\n\nCopyright (c) 2011 TJ Holowaychuk <tj@vision-media.ca>\n\nPermission is hereby granted, free of charge, to any person obtaining\na copy of this software and associated documentation files (the\n\'Software\'), to deal in the Software without restriction, including\nwithout limitation the rights to use, copy, modify, merge, publish,\ndistribute, sublicense, and/or sell copies of the Software, and to\npermit persons to whom the Software is furnished to do so, subject to\nthe following conditions:\n\nThe above copyright notice and this permission notice shall be\nincluded in all copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \'AS IS\', WITHOUT WARRANTY OF ANY KIND,\nEXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\nMERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.\nIN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY\nCLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,\nTORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE\nSOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n', +4763 silly resolved readmeFilename: 'Readme.md', +4763 silly resolved bugs: { url: 'https://github.com/visionmedia/commander.js/issues' }, +4763 silly resolved homepage: 'https://github.com/visionmedia/commander.js', +4763 silly resolved _id: 'commander@2.2.0', +4763 silly resolved _shasum: '175ad4b9317f3ff615f201c1e57224f55a3e91df', +4763 silly resolved _from: 'commander@2.2.0', +4763 silly resolved _resolved: 'https://registry.npmjs.org/commander/-/commander-2.2.0.tgz' } ] +4764 info install commander@2.2.0 into /usr/lib/node_modules/vtop +4765 info installOne commander@2.2.0 +4766 silly resolved [ { author: +4766 silly resolved { name: 'Isaac Z. Schlueter', +4766 silly resolved email: 'i@izs.me', +4766 silly resolved url: 'http://blog.izs.me/' }, +4766 silly resolved name: 'glob', +4766 silly resolved description: 'a little globber', +4766 silly resolved version: '4.0.4', +4766 silly resolved repository: { type: 'git', url: 'git://github.com/isaacs/node-glob.git' }, +4766 silly resolved main: 'glob.js', +4766 silly resolved engines: { node: '*' }, +4766 silly resolved optionalDependencies: { 'graceful-fs': '^3.0.2' }, +4766 silly resolved dependencies: +4766 silly resolved { inherits: '2', +4766 silly resolved minimatch: '^0.3.0', +4766 silly resolved once: '^1.3.0', +4766 silly resolved 'graceful-fs': '^3.0.2' }, +4766 silly resolved devDependencies: { tap: '~0.4.0', mkdirp: '0', rimraf: '1' }, +4766 silly resolved scripts: +4766 silly resolved { test: 'tap test/*.js', +4766 silly resolved 'test-regen': 'TEST_REGEN=1 node test/00-setup.js' }, +4766 silly resolved license: 'BSD', +4766 silly resolved gitHead: 'b7c1296f7fad4eac9fa560058cb6f737ef99d267', +4766 silly resolved bugs: { url: 'https://github.com/isaacs/node-glob/issues' }, +4766 silly resolved homepage: 'https://github.com/isaacs/node-glob', +4766 silly resolved _id: 'glob@4.0.4', +4766 silly resolved _shasum: '730ce0190d87eca7812398018e21be712b4d69d2', +4766 silly resolved _from: 'glob@4.0.4', +4766 silly resolved _npmVersion: '1.5.0-alpha-1', +4766 silly resolved _npmUser: { name: 'isaacs', email: 'i@izs.me' }, +4766 silly resolved maintainers: [ [Object] ], +4766 silly resolved dist: +4766 silly resolved { shasum: '730ce0190d87eca7812398018e21be712b4d69d2', +4766 silly resolved tarball: 'http://registry.npmjs.org/glob/-/glob-4.0.4.tgz' }, +4766 silly resolved directories: {}, +4766 silly resolved _resolved: 'https://registry.npmjs.org/glob/-/glob-4.0.4.tgz', +4766 silly resolved readme: 'ERROR: No README data found!' } ] +4767 info install glob@4.0.4 into /usr/lib/node_modules/vtop +4768 info installOne glob@4.0.4 +4769 silly resolved [ { name: 'drawille', +4769 silly resolved version: '0.1.1', +4769 silly resolved description: 'Drawing in terminal with unicode braille characters', +4769 silly resolved main: 'index.js', +4769 silly resolved scripts: { test: 'echo "OK 1337/1337 passed! (100%)"' }, +4769 silly resolved author: { name: 'Bence Dányi', email: 'madbence@gmail.com' }, +4769 silly resolved repository: +4769 silly resolved { type: 'git', +4769 silly resolved url: 'git@github.com:madbence/node-drawille.git' }, +4769 silly resolved license: 'MIT', +4769 silly resolved bugs: { url: 'https://github.com/madbence/node-drawille/issues' }, +4769 silly resolved devDependencies: { bresenham: '0.0.3', 'gl-matrix': '^2.1.0' }, +4769 silly resolved gitHead: '2799ae0d0abd6785cb127b4546b0903eff1eab90', +4769 silly resolved homepage: 'https://github.com/madbence/node-drawille', +4769 silly resolved _id: 'drawille@0.1.1', +4769 silly resolved _shasum: 'd6ac2a41f79107938f2578762d343df8b1423d5a', +4769 silly resolved _from: 'drawille@0.1.1', +4769 silly resolved _npmVersion: '1.4.14', +4769 silly resolved _npmUser: { name: 'lennon', email: 'madbence@gmail.com' }, +4769 silly resolved maintainers: [ [Object] ], +4769 silly resolved dist: +4769 silly resolved { shasum: 'd6ac2a41f79107938f2578762d343df8b1423d5a', +4769 silly resolved tarball: 'http://registry.npmjs.org/drawille/-/drawille-0.1.1.tgz' }, +4769 silly resolved directories: {}, +4769 silly resolved _resolved: 'https://registry.npmjs.org/drawille/-/drawille-0.1.1.tgz', +4769 silly resolved readme: 'ERROR: No README data found!' } ] +4770 info install drawille@0.1.1 into /usr/lib/node_modules/vtop +4771 info installOne drawille@0.1.1 +4772 silly resolved [ { author: +4772 silly resolved { name: 'Isaac Z. Schlueter', +4772 silly resolved email: 'i@izs.me', +4772 silly resolved url: 'http://blog.izs.me' }, +4772 silly resolved name: 'graceful-fs', +4772 silly resolved description: 'A drop-in replacement for fs, making various improvements.', +4772 silly resolved version: '2.0.3', +4772 silly resolved repository: +4772 silly resolved { type: 'git', +4772 silly resolved url: 'git://github.com/isaacs/node-graceful-fs.git' }, +4772 silly resolved main: 'graceful-fs.js', +4772 silly resolved engines: { node: '>=0.4.0' }, +4772 silly resolved directories: { test: 'test' }, +4772 silly resolved scripts: { test: 'tap test/*.js' }, +4772 silly resolved keywords: +4772 silly resolved [ 'fs', +4772 silly resolved 'module', +4772 silly resolved 'reading', +4772 silly resolved 'retry', +4772 silly resolved 'retries', +4772 silly resolved 'queue', +4772 silly resolved 'error', +4772 silly resolved 'errors', +4772 silly resolved 'handling', +4772 silly resolved 'EMFILE', +4772 silly resolved 'EAGAIN', +4772 silly resolved 'EINVAL', +4772 silly resolved 'EPERM', +4772 silly resolved 'EACCESS' ], +4772 silly resolved license: 'BSD', +4772 silly resolved bugs: { url: 'https://github.com/isaacs/node-graceful-fs/issues' }, +4772 silly resolved homepage: 'https://github.com/isaacs/node-graceful-fs', +4772 silly resolved _id: 'graceful-fs@2.0.3', +4772 silly resolved dist: +4772 silly resolved { shasum: '7cd2cdb228a4a3f36e95efa6cc142de7d1a136d0', +4772 silly resolved tarball: 'http://registry.npmjs.org/graceful-fs/-/graceful-fs-2.0.3.tgz' }, +4772 silly resolved _from: 'graceful-fs@2.0.3', +4772 silly resolved _npmVersion: '1.4.6', +4772 silly resolved _npmUser: { name: 'isaacs', email: 'i@izs.me' }, +4772 silly resolved maintainers: [ [Object] ], +4772 silly resolved _shasum: '7cd2cdb228a4a3f36e95efa6cc142de7d1a136d0', +4772 silly resolved _resolved: 'https://registry.npmjs.org/graceful-fs/-/graceful-fs-2.0.3.tgz', +4772 silly resolved readme: 'ERROR: No README data found!' } ] +4773 info install graceful-fs@2.0.3 into /usr/lib/node_modules/karma +4774 info installOne graceful-fs@2.0.3 +4775 silly resolved [ { name: 'q', +4775 silly resolved version: '0.9.7', +4775 silly resolved description: 'A library for promises (CommonJS/Promises/A,B,D)', +4775 silly resolved homepage: 'https://github.com/kriskowal/q', +4775 silly resolved author: +4775 silly resolved { name: 'Kris Kowal', +4775 silly resolved email: 'kris@cixar.com', +4775 silly resolved url: 'https://github.com/kriskowal' }, +4775 silly resolved keywords: +4775 silly resolved [ 'q', +4775 silly resolved 'promise', +4775 silly resolved 'promises', +4775 silly resolved 'promises-a', +4775 silly resolved 'promises-aplus', +4775 silly resolved 'deferred', +4775 silly resolved 'future', +4775 silly resolved 'async', +4775 silly resolved 'flow control', +4775 silly resolved 'fluent', +4775 silly resolved 'browser', +4775 silly resolved 'node' ], +4775 silly resolved contributors: [ [Object], [Object], [Object] ], +4775 silly resolved bugs: { url: 'http://github.com/kriskowal/q/issues' }, +4775 silly resolved license: +4775 silly resolved { type: 'MIT', +4775 silly resolved url: 'http://github.com/kriskowal/q/raw/master/LICENSE' }, +4775 silly resolved main: 'q.js', +4775 silly resolved repository: { type: 'git', url: 'git://github.com/kriskowal/q.git' }, +4775 silly resolved engines: { node: '>=0.6.0', teleport: '>=0.2.0' }, +4775 silly resolved dependencies: {}, +4775 silly resolved devDependencies: +4775 silly resolved { jshint: '~2.1.9', +4775 silly resolved cover: '*', +4775 silly resolved 'jasmine-node': '1.11.0', +4775 silly resolved opener: '*', +4775 silly resolved 'promises-aplus-tests': '1.x', +4775 silly resolved grunt: '~0.4.1', +4775 silly resolved 'grunt-cli': '~0.1.9', +4775 silly resolved 'grunt-contrib-uglify': '~0.2.2', +4775 silly resolved matcha: '~0.2.0' }, +4775 silly resolved scripts: +4775 silly resolved { test: 'jasmine-node spec && promises-aplus-tests spec/aplus-adapter', +4775 silly resolved 'test-browser': 'opener spec/q-spec.html', +4775 silly resolved benchmark: 'matcha', +4775 silly resolved lint: 'jshint q.js', +4775 silly resolved cover: 'cover run node_modules/jasmine-node/bin/jasmine-node spec && cover report html && opener cover_html/index.html', +4775 silly resolved minify: 'grunt', +4775 silly resolved prepublish: 'grunt' }, +4775 silly resolved overlay: { teleport: [Object] }, +4775 silly resolved directories: { test: './spec' }, +4775 silly resolved readme: '[![Build Status](https://secure.travis-ci.org/kriskowal/q.png?branch=master)](http://travis-ci.org/kriskowal/q)\n\n\n Promises/A+ logo\n\n\nIf a function cannot return a value or throw an exception without\nblocking, it can return a promise instead. A promise is an object\nthat represents the return value or the thrown exception that the\nfunction may eventually provide. A promise can also be used as a\nproxy for a [remote object][Q-Connection] to overcome latency.\n\n[Q-Connection]: https://github.com/kriskowal/q-connection\n\nOn the first pass, promises can mitigate the “[Pyramid of\nDoom][POD]”: the situation where code marches to the right faster\nthan it marches forward.\n\n[POD]: http://calculist.org/blog/2011/12/14/why-coroutines-wont-work-on-the-web/\n\n```javascript\nstep1(function (value1) {\n step2(value1, function(value2) {\n step3(value2, function(value3) {\n step4(value3, function(value4) {\n // Do something with value4\n });\n });\n });\n});\n```\n\nWith a promise library, you can flatten the pyramid.\n\n```javascript\nQ.fcall(promisedStep1)\n.then(promisedStep2)\n.then(promisedStep3)\n.then(promisedStep4)\n.then(function (value4) {\n // Do something with value4\n})\n.catch(function (error) {\n // Handle any error from all above steps\n})\n.done();\n```\n\nWith this approach, you also get implicit error propagation, just like `try`,\n`catch`, and `finally`. An error in `promisedStep1` will flow all the way to\nthe `catch` function, where it’s caught and handled. (Here `promisedStepN` is\na version of `stepN` that returns a promise.)\n\nThe callback approach is called an “inversion of control”.\nA function that accepts a callback instead of a return value\nis saying, “Don’t call me, I’ll call you.”. Promises\n[un-invert][IOC] the inversion, cleanly separating the input\narguments from control flow arguments. This simplifies the\nuse and creation of API’s, particularly variadic,\nrest and spread arguments.\n\n[IOC]: http://www.slideshare.net/domenicdenicola/callbacks-promises-and-coroutines-oh-my-the-evolution-of-asynchronicity-in-javascript\n\n\n## Getting Started\n\nThe Q module can be loaded as:\n\n- A ``\n\nescodegen.browser.js is found in tagged-revision. See Tags on GitHub.\n\nOr in a Node.js application via the package manager:\n\n npm install escodegen\n\n### Usage\n\nA simple example: the program\n\n escodegen.generate({\n type: \'BinaryExpression\',\n operator: \'+\',\n left: { type: \'Literal\', value: 40 },\n right: { type: \'Literal\', value: 2 }\n });\n\nproduces the string `\'40 + 2\'`\n\nSee the [API page](https://github.com/Constellation/escodegen/wiki/API) for\noptions. To run the tests, execute `npm test` in the root directory.\n\n### License\n\n#### Escodegen\n\nCopyright (C) 2012 [Yusuke Suzuki](http://github.com/Constellation)\n (twitter: [@Constellation](http://twitter.com/Constellation)) and other contributors.\n\nRedistribution and use in source and binary forms, with or without\nmodification, are permitted provided that the following conditions are met:\n\n * Redistributions of source code must retain the above copyright\n notice, this list of conditions and the following disclaimer.\n\n * Redistributions in binary form must reproduce the above copyright\n notice, this list of conditions and the following disclaimer in the\n documentation and/or other materials provided with the distribution.\n\nTHIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"\nAND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE\nIMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE\nARE DISCLAIMED. IN NO EVENT SHALL BE LIABLE FOR ANY\nDIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES\n(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;\nLOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND\nON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT\n(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF\nTHIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n\n#### source-map\n\nSourceNodeMocks has a limited interface of mozilla/source-map SourceNode implementations.\n\nCopyright (c) 2009-2011, Mozilla Foundation and contributors\nAll rights reserved.\n\nRedistribution and use in source and binary forms, with or without\nmodification, are permitted provided that the following conditions are met:\n\n* Redistributions of source code must retain the above copyright notice, this\n list of conditions and the following disclaimer.\n\n* Redistributions in binary form must reproduce the above copyright notice,\n this list of conditions and the following disclaimer in the documentation\n and/or other materials provided with the distribution.\n\n* Neither the names of the Mozilla Foundation nor the names of project\n contributors may be used to endorse or promote products derived from this\n software without specific prior written permission.\n\nTHIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND\nANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED\nWARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE\nDISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE\nFOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL\nDAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR\nSERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER\nCAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,\nOR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE\nOF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n', +4838 silly resolved readmeFilename: 'README.md', +4838 silly resolved bugs: { url: 'https://github.com/Constellation/escodegen/issues' }, +4838 silly resolved _id: 'escodegen@0.0.28', +4838 silly resolved _from: 'escodegen@0.0.28' } ] +4839 info install escodegen@0.0.28 into /usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/coffee-script-redux +4840 info installOne escodegen@0.0.28 +4841 silly resolved [ { name: 'esmangle', +4841 silly resolved description: 'ECMAScript code mangler / minifier', +4841 silly resolved homepage: 'http://github.com/Constellation/esmangle.html', +4841 silly resolved main: 'lib/esmangle.js', +4841 silly resolved bin: { esmangle: './bin/esmangle.js' }, +4841 silly resolved version: '0.0.17', +4841 silly resolved engines: { node: '>=0.6.0' }, +4841 silly resolved directories: { lib: './lib' }, +4841 silly resolved maintainers: [ [Object] ], +4841 silly resolved repository: +4841 silly resolved { type: 'git', +4841 silly resolved url: 'http://github.com/Constellation/esmangle.git' }, +4841 silly resolved dependencies: +4841 silly resolved { esprima: '~ 1.0.2', +4841 silly resolved escope: '~ 1.0.0', +4841 silly resolved escodegen: '~ 0.0.28', +4841 silly resolved estraverse: '~ 1.3.2', +4841 silly resolved 'source-map': '~ 0.1.8', +4841 silly resolved esshorten: '~ 0.0.2', +4841 silly resolved optimist: '*' }, +4841 silly resolved devDependencies: +4841 silly resolved { chai: '*', +4841 silly resolved 'commonjs-everywhere': '0.8.x', +4841 silly resolved grunt: '~0.4.1', +4841 silly resolved 'grunt-cli': '~0.1.7', +4841 silly resolved 'grunt-contrib-jshint': '~0.6.0', +4841 silly resolved 'grunt-mocha-test': '~0.5.0', +4841 silly resolved 'grunt-contrib-copy': '~0.4.1', +4841 silly resolved 'grunt-update-submodules': '~0.2.0', +4841 silly resolved 'grunt-contrib-clean': '~0.4.1', +4841 silly resolved 'grunt-shell': '~0.2.2', +4841 silly resolved async: '~0.2.8', +4841 silly resolved q: '~0.9.3' }, +4841 silly resolved licenses: [ [Object] ], +4841 silly resolved scripts: +4841 silly resolved { test: 'grunt travis', +4841 silly resolved lint: 'grunt lint', +4841 silly resolved 'regression-test': 'grunt test:regression', +4841 silly resolved 'unit-test': 'grunt test', +4841 silly resolved build: 'grunt build' }, +4841 silly resolved readme: 'esmangle ([esmangle](http://github.com/Constellation/esmangle)) is\nmangler / minifier for [Parser API](https://developer.mozilla.org/en/SpiderMonkey/Parser_API) AST.\n\n[![Build Status](https://secure.travis-ci.org/Constellation/esmangle.png)](http://travis-ci.org/Constellation/esmangle) [![Build Status](https://drone.io/github.com/Constellation/esmangle/status.png)](https://drone.io/github.com/Constellation/esmangle/latest)\n\n### Install\n\nesmangle can be used in a web browser: Download\n\n \n\n\nNode.js application via the package manager:\n\n npm install esmangle\n\nIf you would like to use latest esmangle in a browser, you can build `build/esmangle.min.js`:\n\n npm run-script build\n\n\n### Usage\n\nA simple example: the program\n\n var ast = esprima.parse(code);\n var result = esmangle.mangle(ast); // gets mangled AST\n console.log(escodegen.generate(result)); // dump AST\n\nOr you can simply use this `esmangle` command in the shell.\n\n $ esmangle file.js\n\nGet more compressed result: (in Node.js)\n\n var ast = esprima.parse(code);\n // Get optimized AST\n var optimized = esmangle.optimize(ast, null);\n // gets mangled AST\n var result = esmangle.mangle(optimized);\n console.log(escodegen.generate(result, {\n format: {\n renumber: true,\n hexadecimal: true,\n escapeless: true,\n compact: true,\n semicolons: false,\n parentheses: false\n }\n })); // dump AST\n\n\n### Design\n\nSlide is [here](https://speakerdeck.com/constellation/escodegen-and-esmangle-using-mozilla-javascript-ast-as-an-ir).\nThis resolution algorithm is based on my bytecode compiler [iv / lv5 / railgun](https://github.com/Constellation/iv/tree/master/iv/lv5/railgun).\n\n### License\n\nCopyright (C) 2012 [Yusuke Suzuki](http://github.com/Constellation)\n (twitter: [@Constellation](http://twitter.com/Constellation)) and other contributors.\n\nRedistribution and use in source and binary forms, with or without\nmodification, are permitted provided that the following conditions are met:\n\n * Redistributions of source code must retain the above copyright\n notice, this list of conditions and the following disclaimer.\n\n * Redistributions in binary form must reproduce the above copyright\n notice, this list of conditions and the following disclaimer in the\n documentation and/or other materials provided with the distribution.\n\nTHIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"\nAND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE\nIMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE\nARE DISCLAIMED. IN NO EVENT SHALL BE LIABLE FOR ANY\nDIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES\n(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;\nLOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND\nON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT\n(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF\nTHIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n', +4841 silly resolved readmeFilename: 'README.md', +4841 silly resolved bugs: { url: 'https://github.com/Constellation/esmangle/issues' }, +4841 silly resolved _id: 'esmangle@0.0.17', +4841 silly resolved _from: 'esmangle@0.0.17' } ] +4842 info install esmangle@0.0.17 into /usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/coffee-script-redux +4843 info installOne esmangle@0.0.17 +4844 silly resolved [ { name: 'path-to-regexp', +4844 silly resolved description: 'Express style path to RegExp utility', +4844 silly resolved version: '0.1.3', +4844 silly resolved scripts: { test: 'istanbul cover _mocha -- -R spec' }, +4844 silly resolved keywords: [ 'express', 'regexp' ], +4844 silly resolved component: { scripts: [Object] }, +4844 silly resolved repository: +4844 silly resolved { type: 'git', +4844 silly resolved url: 'https://github.com/component/path-to-regexp.git' }, +4844 silly resolved devDependencies: { mocha: '^1.17.1', istanbul: '^0.2.6' }, +4844 silly resolved bugs: { url: 'https://github.com/component/path-to-regexp/issues' }, +4844 silly resolved homepage: 'https://github.com/component/path-to-regexp', +4844 silly resolved _id: 'path-to-regexp@0.1.3', +4844 silly resolved _shasum: '21b9ab82274279de25b156ea08fd12ca51b8aecb', +4844 silly resolved _from: 'path-to-regexp@0.1.3', +4844 silly resolved _npmVersion: '1.4.9', +4844 silly resolved _npmUser: { name: 'blakeembrey', email: 'hello@blakeembrey.com' }, +4844 silly resolved maintainers: +4844 silly resolved [ [Object], +4844 silly resolved [Object], +4844 silly resolved [Object], +4844 silly resolved [Object], +4844 silly resolved [Object], +4844 silly resolved [Object], +4844 silly resolved [Object], +4844 silly resolved [Object], +4844 silly resolved [Object], +4844 silly resolved [Object], +4844 silly resolved [Object], +4844 silly resolved [Object], +4844 silly resolved [Object], +4844 silly resolved [Object], +4844 silly resolved [Object], +4844 silly resolved [Object], +4844 silly resolved [Object], +4844 silly resolved [Object], +4844 silly resolved [Object], +4844 silly resolved [Object], +4844 silly resolved [Object], +4844 silly resolved [Object], +4844 silly resolved [Object], +4844 silly resolved [Object], +4844 silly resolved [Object], +4844 silly resolved [Object], +4844 silly resolved [Object], +4844 silly resolved [Object], +4844 silly resolved [Object] ], +4844 silly resolved dist: +4844 silly resolved { shasum: '21b9ab82274279de25b156ea08fd12ca51b8aecb', +4844 silly resolved tarball: 'http://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.3.tgz' }, +4844 silly resolved directories: {}, +4844 silly resolved _resolved: 'https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-0.1.3.tgz', +4844 silly resolved readme: 'ERROR: No README data found!' } ] +4845 info install path-to-regexp@0.1.3 into /usr/lib/node_modules/express +4846 info installOne path-to-regexp@0.1.3 +4847 silly resolved [ { name: 'nopt', +4847 silly resolved version: '2.2.1', +4847 silly resolved description: 'Option parsing for Node, supporting types, shorthands, etc. Used by npm.', +4847 silly resolved author: +4847 silly resolved { name: 'Isaac Z. Schlueter', +4847 silly resolved email: 'i@izs.me', +4847 silly resolved url: 'http://blog.izs.me/' }, +4847 silly resolved main: 'lib/nopt.js', +4847 silly resolved scripts: { test: 'tap test/*.js' }, +4847 silly resolved repository: { type: 'git', url: 'http://github.com/isaacs/nopt' }, +4847 silly resolved bin: { nopt: './bin/nopt.js' }, +4847 silly resolved license: +4847 silly resolved { type: 'MIT', +4847 silly resolved url: 'https://github.com/isaacs/nopt/raw/master/LICENSE' }, +4847 silly resolved dependencies: { abbrev: '1' }, +4847 silly resolved devDependencies: { tap: '~0.4.8' }, +4847 silly resolved bugs: { url: 'https://github.com/isaacs/nopt/issues' }, +4847 silly resolved homepage: 'https://github.com/isaacs/nopt', +4847 silly resolved _id: 'nopt@2.2.1', +4847 silly resolved _shasum: '2aa09b7d1768487b3b89a9c5aa52335bff0baea7', +4847 silly resolved _from: 'nopt@2.2.1', +4847 silly resolved _npmVersion: '1.4.7', +4847 silly resolved _npmUser: { name: 'isaacs', email: 'i@izs.me' }, +4847 silly resolved maintainers: [ [Object] ], +4847 silly resolved dist: +4847 silly resolved { shasum: '2aa09b7d1768487b3b89a9c5aa52335bff0baea7', +4847 silly resolved tarball: 'http://registry.npmjs.org/nopt/-/nopt-2.2.1.tgz' }, +4847 silly resolved directories: {}, +4847 silly resolved _resolved: 'https://registry.npmjs.org/nopt/-/nopt-2.2.1.tgz', +4847 silly resolved readme: 'ERROR: No README data found!' } ] +4848 info install nopt@2.2.1 into /usr/lib/node_modules/nodeunit/node_modules/tap +4849 info installOne nopt@2.2.1 +4850 silly resolved [ { name: 'deep-equal', +4850 silly resolved version: '0.0.0', +4850 silly resolved description: 'node\'s assert.deepEqual algorithm', +4850 silly resolved main: 'index.js', +4850 silly resolved directories: { lib: '.', example: 'example', test: 'test' }, +4850 silly resolved scripts: { test: 'tap test/*.js' }, +4850 silly resolved devDependencies: { tap: '0.0.x' }, +4850 silly resolved repository: +4850 silly resolved { type: 'git', +4850 silly resolved url: 'git://github.com/substack/node-deep-equal.git' }, +4850 silly resolved keywords: [ 'equality', 'equal', 'compare' ], +4850 silly resolved author: +4850 silly resolved { name: 'James Halliday', +4850 silly resolved email: 'mail@substack.net', +4850 silly resolved url: 'http://substack.net' }, +4850 silly resolved license: 'MIT/X11', +4850 silly resolved engine: { node: '>=0.4' }, +4850 silly resolved _npmUser: { name: 'substack', email: 'mail@substack.net' }, +4850 silly resolved _id: 'deep-equal@0.0.0', +4850 silly resolved dependencies: {}, +4850 silly resolved engines: { node: '*' }, +4850 silly resolved _engineSupported: true, +4850 silly resolved _npmVersion: '1.0.106', +4850 silly resolved _nodeVersion: 'v0.4.12', +4850 silly resolved _defaultsLoaded: true, +4850 silly resolved dist: +4850 silly resolved { shasum: '99679d3bbd047156fcd450d3d01eeb9068691e83', +4850 silly resolved tarball: 'http://registry.npmjs.org/deep-equal/-/deep-equal-0.0.0.tgz' }, +4850 silly resolved maintainers: [ [Object] ], +4850 silly resolved _shasum: '99679d3bbd047156fcd450d3d01eeb9068691e83', +4850 silly resolved _from: 'deep-equal@0.0.0', +4850 silly resolved _resolved: 'https://registry.npmjs.org/deep-equal/-/deep-equal-0.0.0.tgz', +4850 silly resolved bugs: { url: 'https://github.com/substack/node-deep-equal/issues' }, +4850 silly resolved readme: 'ERROR: No README data found!', +4850 silly resolved homepage: 'https://github.com/substack/node-deep-equal' } ] +4851 info install deep-equal@0.0.0 into /usr/lib/node_modules/nodeunit/node_modules/tap +4852 info installOne deep-equal@0.0.0 +4853 silly resolved [ { name: 'request', +4853 silly resolved description: 'Simplified HTTP request client.', +4853 silly resolved tags: [ 'http', 'simple', 'util', 'utility' ], +4853 silly resolved version: '2.42.0', +4853 silly resolved author: { name: 'Mikeal Rogers', email: 'mikeal.rogers@gmail.com' }, +4853 silly resolved repository: { type: 'git', url: 'https://github.com/mikeal/request.git' }, +4853 silly resolved bugs: { url: 'http://github.com/mikeal/request/issues' }, +4853 silly resolved license: 'Apache-2.0', +4853 silly resolved engines: [ 'node >= 0.8.0' ], +4853 silly resolved main: 'index.js', +4853 silly resolved dependencies: +4853 silly resolved { bl: '~0.9.0', +4853 silly resolved caseless: '~0.6.0', +4853 silly resolved 'forever-agent': '~0.5.0', +4853 silly resolved qs: '~1.2.0', +4853 silly resolved 'json-stringify-safe': '~5.0.0', +4853 silly resolved 'mime-types': '~1.0.1', +4853 silly resolved 'node-uuid': '~1.4.0', +4853 silly resolved 'tunnel-agent': '~0.4.0', +4853 silly resolved 'tough-cookie': '>=0.12.0', +4853 silly resolved 'form-data': '~0.1.0', +4853 silly resolved 'http-signature': '~0.10.0', +4853 silly resolved 'oauth-sign': '~0.4.0', +4853 silly resolved hawk: '1.1.1', +4853 silly resolved 'aws-sign2': '~0.5.0', +4853 silly resolved stringstream: '~0.0.4' }, +4853 silly resolved optionalDependencies: +4853 silly resolved { 'tough-cookie': '>=0.12.0', +4853 silly resolved 'form-data': '~0.1.0', +4853 silly resolved 'http-signature': '~0.10.0', +4853 silly resolved 'oauth-sign': '~0.4.0', +4853 silly resolved hawk: '1.1.1', +4853 silly resolved 'aws-sign2': '~0.5.0', +4853 silly resolved stringstream: '~0.0.4' }, +4853 silly resolved scripts: { test: 'node tests/run.js' }, +4853 silly resolved devDependencies: { rimraf: '~2.2.8' }, +4853 silly resolved homepage: 'https://github.com/mikeal/request', +4853 silly resolved _id: 'request@2.42.0', +4853 silly resolved _shasum: '572bd0148938564040ac7ab148b96423a063304a', +4853 silly resolved _from: 'request@2.42.0', +4853 silly resolved _npmVersion: '1.4.9', +4853 silly resolved _npmUser: { name: 'mikeal', email: 'mikeal.rogers@gmail.com' }, +4853 silly resolved maintainers: [ [Object] ], +4853 silly resolved dist: +4853 silly resolved { shasum: '572bd0148938564040ac7ab148b96423a063304a', +4853 silly resolved tarball: 'http://registry.npmjs.org/request/-/request-2.42.0.tgz' }, +4853 silly resolved directories: {}, +4853 silly resolved _resolved: 'https://registry.npmjs.org/request/-/request-2.42.0.tgz', +4853 silly resolved readme: 'ERROR: No README data found!' } ] +4854 info install request@2.42.0 into /usr/lib/node_modules/karma-phantomjs-launcher/node_modules/phantomjs +4855 info installOne request@2.42.0 +4856 silly resolved [ { name: 'charm', +4856 silly resolved version: '0.1.2', +4856 silly resolved description: 'ansi control sequences for terminal cursor hopping and colors', +4856 silly resolved main: 'index.js', +4856 silly resolved directories: { lib: '.', example: 'example', test: 'test' }, +4856 silly resolved repository: +4856 silly resolved { type: 'git', +4856 silly resolved url: 'http://github.com/substack/node-charm.git' }, +4856 silly resolved keywords: +4856 silly resolved [ 'terminal', +4856 silly resolved 'ansi', +4856 silly resolved 'cursor', +4856 silly resolved 'color', +4856 silly resolved 'console', +4856 silly resolved 'control', +4856 silly resolved 'escape', +4856 silly resolved 'sequence' ], +4856 silly resolved author: +4856 silly resolved { name: 'James Halliday', +4856 silly resolved email: 'mail@substack.net', +4856 silly resolved url: 'http://substack.net' }, +4856 silly resolved license: 'MIT/X11', +4856 silly resolved engine: { node: '>=0.4' }, +4856 silly resolved _id: 'charm@0.1.2', +4856 silly resolved dist: +4856 silly resolved { shasum: '06c21eed1a1b06aeb67553cdc53e23274bac2296', +4856 silly resolved tarball: 'http://registry.npmjs.org/charm/-/charm-0.1.2.tgz' }, +4856 silly resolved _from: 'charm@0.1.2', +4856 silly resolved _npmVersion: '1.2.2', +4856 silly resolved _npmUser: { name: 'substack', email: 'mail@substack.net' }, +4856 silly resolved maintainers: [ [Object] ], +4856 silly resolved _shasum: '06c21eed1a1b06aeb67553cdc53e23274bac2296', +4856 silly resolved _resolved: 'https://registry.npmjs.org/charm/-/charm-0.1.2.tgz', +4856 silly resolved bugs: { url: 'https://github.com/substack/node-charm/issues' }, +4856 silly resolved readme: 'ERROR: No README data found!', +4856 silly resolved homepage: 'https://github.com/substack/node-charm' } ] +4857 info install charm@0.1.2 into /usr/lib/node_modules/nodeunit/node_modules/tap/node_modules/difflet +4858 info installOne charm@0.1.2 +4859 silly resolved [ { name: 'traverse', +4859 silly resolved version: '0.5.2', +4859 silly resolved description: 'Traverse and transform objects by visiting every node on a recursive walk', +4859 silly resolved author: { name: 'James Halliday' }, +4859 silly resolved license: 'MIT/X11', +4859 silly resolved main: './index', +4859 silly resolved repository: +4859 silly resolved { type: 'git', +4859 silly resolved url: 'git://github.com/substack/js-traverse.git' }, +4859 silly resolved devDependencies: { expresso: '0.7.x' }, +4859 silly resolved scripts: { test: 'expresso' }, +4859 silly resolved _npmJsonOpts: +4859 silly resolved { file: '/home/substack/.npm/traverse/0.5.2/package/package.json', +4859 silly resolved wscript: false, +4859 silly resolved contributors: false, +4859 silly resolved serverjs: false }, +4859 silly resolved _id: 'traverse@0.5.2', +4859 silly resolved dependencies: {}, +4859 silly resolved engines: { node: '*' }, +4859 silly resolved _engineSupported: true, +4859 silly resolved _npmVersion: '1.0.30', +4859 silly resolved _nodeVersion: 'v0.4.12', +4859 silly resolved _defaultsLoaded: true, +4859 silly resolved dist: +4859 silly resolved { shasum: 'e203c58d5f7f0e37db6e74c0acb929bb09b61d85', +4859 silly resolved tarball: 'http://registry.npmjs.org/traverse/-/traverse-0.5.2.tgz' }, +4859 silly resolved maintainers: [ [Object] ], +4859 silly resolved directories: {}, +4859 silly resolved _shasum: 'e203c58d5f7f0e37db6e74c0acb929bb09b61d85', +4859 silly resolved _from: 'traverse@0.5.2', +4859 silly resolved _resolved: 'https://registry.npmjs.org/traverse/-/traverse-0.5.2.tgz', +4859 silly resolved bugs: { url: 'https://github.com/substack/js-traverse/issues' }, +4859 silly resolved readme: 'ERROR: No README data found!', +4859 silly resolved homepage: 'https://github.com/substack/js-traverse' } ] +4860 info install traverse@0.5.2 into /usr/lib/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito +4861 info installOne traverse@0.5.2 +4862 silly resolved [ { name: 'rework-custom-media', +4862 silly resolved version: '0.1.1', +4862 silly resolved description: 'W3C-style custom media queries for Rework', +4862 silly resolved files: [ 'index.js' ], +4862 silly resolved devDependencies: { mocha: '~1.14.0', rework: '^1.0.0' }, +4862 silly resolved scripts: +4862 silly resolved { test: 'mocha --no-colors', +4862 silly resolved 'test-watch': 'mocha --slow 30 --reporter spec --watch' }, +4862 silly resolved keywords: +4862 silly resolved [ 'css', +4862 silly resolved 'custom-media', +4862 silly resolved 'rework', +4862 silly resolved 'media-queries', +4862 silly resolved 'media-query', +4862 silly resolved 'preprocessor', +4862 silly resolved 'rework-plugin' ], +4862 silly resolved license: 'MIT', +4862 silly resolved repository: +4862 silly resolved { type: 'git', +4862 silly resolved url: 'https://github.com/reworkcss/rework-custom-media.git' }, +4862 silly resolved bugs: { url: 'https://github.com/reworkcss/rework-custom-media/issues' }, +4862 silly resolved homepage: 'https://github.com/reworkcss/rework-custom-media', +4862 silly resolved _id: 'rework-custom-media@0.1.1', +4862 silly resolved dist: +4862 silly resolved { shasum: 'b6b2b3d70bd960b819d323b075da2b6f18c27f39', +4862 silly resolved tarball: 'http://registry.npmjs.org/rework-custom-media/-/rework-custom-media-0.1.1.tgz' }, +4862 silly resolved _from: 'rework-custom-media@0.1.1', +4862 silly resolved _npmVersion: '1.4.3', +4862 silly resolved _npmUser: { name: 'necolas', email: 'nicolasgallagher@gmail.com' }, +4862 silly resolved maintainers: [ [Object] ], +4862 silly resolved directories: {}, +4862 silly resolved _shasum: 'b6b2b3d70bd960b819d323b075da2b6f18c27f39', +4862 silly resolved _resolved: 'https://registry.npmjs.org/rework-custom-media/-/rework-custom-media-0.1.1.tgz', +4862 silly resolved readme: 'ERROR: No README data found!' } ] +4863 info install rework-custom-media@0.1.1 into /usr/lib/node_modules/myth +4864 info installOne rework-custom-media@0.1.1 +4865 silly resolved [ { name: 'uglify-js', +4865 silly resolved description: 'JavaScript parser and compressor/beautifier toolkit', +4865 silly resolved author: +4865 silly resolved { name: 'Mihai Bazon', +4865 silly resolved email: 'mihai.bazon@gmail.com', +4865 silly resolved url: 'http://mihai.bazon.net/blog' }, +4865 silly resolved version: '1.1.1', +4865 silly resolved main: './uglify-js.js', +4865 silly resolved bin: { uglifyjs: './bin/uglifyjs' }, +4865 silly resolved repository: { type: 'git', url: 'git@github.com:mishoo/UglifyJS.git' }, +4865 silly resolved _npmUser: { name: 'mishoo', email: 'mihai.bazon@gmail.com' }, +4865 silly resolved _id: 'uglify-js@1.1.1', +4865 silly resolved dependencies: {}, +4865 silly resolved devDependencies: {}, +4865 silly resolved engines: { node: '*' }, +4865 silly resolved _engineSupported: true, +4865 silly resolved _npmVersion: '1.0.94', +4865 silly resolved _nodeVersion: 'v0.5.8', +4865 silly resolved _defaultsLoaded: true, +4865 silly resolved dist: +4865 silly resolved { shasum: 'ee71a97c4cefd06a1a9b20437f34118982aa035b', +4865 silly resolved tarball: 'http://registry.npmjs.org/uglify-js/-/uglify-js-1.1.1.tgz' }, +4865 silly resolved maintainers: [ [Object], [Object], [Object] ], +4865 silly resolved directories: {}, +4865 silly resolved _shasum: 'ee71a97c4cefd06a1a9b20437f34118982aa035b', +4865 silly resolved _from: 'uglify-js@1.1.1', +4865 silly resolved _resolved: 'https://registry.npmjs.org/uglify-js/-/uglify-js-1.1.1.tgz', +4865 silly resolved bugs: { url: 'https://github.com/mishoo/UglifyJS/issues' }, +4865 silly resolved readme: 'ERROR: No README data found!', +4865 silly resolved homepage: 'https://github.com/mishoo/UglifyJS' } ] +4866 info install uglify-js@1.1.1 into /usr/lib/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito +4867 info installOne uglify-js@1.1.1 +4868 silly resolved [ { name: 'to-space-case', +4868 silly resolved repository: +4868 silly resolved { type: 'git', +4868 silly resolved url: 'git://github.com/ianstormtaylor/to-space-case.git' }, +4868 silly resolved license: 'MIT', +4868 silly resolved version: '0.1.2', +4868 silly resolved description: 'Convert a string to space case.', +4868 silly resolved keywords: [ 'space', 'case', 'spacecase', 'string' ], +4868 silly resolved dependencies: { 'to-no-case': '0.1.1' }, +4868 silly resolved readme: '# to-space-case\n\n Convert a string to a space case.\n\n## Installation\n\n $ component install ianstormtaylor/to-space-case\n $ npm install to-space-case\n\n## Example\n\n```js\nvar space = require(\'to-space-case\');\n\nspace(\'camelCase\'); // "camel case"\nspace(\'snake_case\'); // "snake case"\nspace(\'dot.case\'); // "dot case"\n```\n\n## API\n\n### toSpaceCase(string)\n \n Returns the space-case variant of a `string`.\n\n## License\n\n MIT\n', +4868 silly resolved readmeFilename: 'Readme.md', +4868 silly resolved bugs: { url: 'https://github.com/ianstormtaylor/to-space-case/issues' }, +4868 silly resolved _id: 'to-space-case@0.1.2', +4868 silly resolved dist: +4868 silly resolved { shasum: '9a66be3ebe53f2779f687f0262effd1fc5b6d15e', +4868 silly resolved tarball: 'http://registry.npmjs.org/to-space-case/-/to-space-case-0.1.2.tgz' }, +4868 silly resolved _from: 'to-space-case@0.1.2', +4868 silly resolved _npmVersion: '1.3.5', +4868 silly resolved _npmUser: { name: 'ianstormtaylor', email: 'ian@ianstormtaylor.com' }, +4868 silly resolved maintainers: [ [Object] ], +4868 silly resolved directories: {}, +4868 silly resolved _shasum: '9a66be3ebe53f2779f687f0262effd1fc5b6d15e', +4868 silly resolved _resolved: 'https://registry.npmjs.org/to-space-case/-/to-space-case-0.1.2.tgz', +4868 silly resolved homepage: 'https://github.com/ianstormtaylor/to-space-case' } ] +4869 info install to-space-case@0.1.2 into /usr/lib/node_modules/myth/node_modules/to-slug-case +4870 info installOne to-space-case@0.1.2 +4871 silly resolved [ { name: 'stream-to-array', +4871 silly resolved description: 'Concatenate a readable stream\'s data into a single array', +4871 silly resolved version: '1.0.0', +4871 silly resolved author: +4871 silly resolved { name: 'Jonathan Ong', +4871 silly resolved email: 'me@jongleberry.com', +4871 silly resolved url: 'http://jongleberry.com' }, +4871 silly resolved license: 'MIT', +4871 silly resolved repository: +4871 silly resolved { type: 'git', +4871 silly resolved url: 'https://github.com/stream-utils/stream-to-array.git' }, +4871 silly resolved bugs: { url: 'https://github.com/stream-utils/stream-to-array/issues' }, +4871 silly resolved devDependencies: { co: '*', gnode: '*', mocha: '*' }, +4871 silly resolved scripts: { test: 'NODE=gnode make test' }, +4871 silly resolved engines: { node: '>= 0.10.0' }, +4871 silly resolved homepage: 'https://github.com/stream-utils/stream-to-array', +4871 silly resolved _id: 'stream-to-array@1.0.0', +4871 silly resolved dist: +4871 silly resolved { shasum: '94166bb29f3ea24f082d2f8cd3ebb2cc0d6eca2c', +4871 silly resolved tarball: 'http://registry.npmjs.org/stream-to-array/-/stream-to-array-1.0.0.tgz' }, +4871 silly resolved _from: 'stream-to-array@1.0.0', +4871 silly resolved _npmVersion: '1.3.14', +4871 silly resolved _npmUser: { name: 'jongleberry', email: 'jonathanrichardong@gmail.com' }, +4871 silly resolved maintainers: [ [Object] ], +4871 silly resolved directories: {}, +4871 silly resolved _shasum: '94166bb29f3ea24f082d2f8cd3ebb2cc0d6eca2c', +4871 silly resolved _resolved: 'https://registry.npmjs.org/stream-to-array/-/stream-to-array-1.0.0.tgz', +4871 silly resolved readme: 'ERROR: No README data found!' } ] +4872 info install stream-to-array@1.0.0 into /usr/lib/node_modules/myth/node_modules/read-file-stdin +4873 info installOne stream-to-array@1.0.0 +4874 silly resolved [ { name: 'rgb', +4874 silly resolved version: '0.0.1', +4874 silly resolved description: 'converts all sorts of colors to rgb format.', +4874 silly resolved main: 'index.js', +4874 silly resolved repository: { type: 'git', url: 'https://github.com/kamicane/rgb' }, +4874 silly resolved keywords: [ 'rgb', 'hsl', 'hex', 'color', 'conversion' ], +4874 silly resolved author: +4874 silly resolved { name: 'Valerio Proietti', +4874 silly resolved email: '@kamicane', +4874 silly resolved url: 'http://mad4milk.net' }, +4874 silly resolved license: 'MIT (http://mootools.net/license.txt)', +4874 silly resolved _id: 'rgb@0.0.1', +4874 silly resolved dist: +4874 silly resolved { shasum: '19dfcc8d1a1443633d54972338c1d5815b556c09', +4874 silly resolved tarball: 'http://registry.npmjs.org/rgb/-/rgb-0.0.1.tgz' }, +4874 silly resolved _from: 'rgb@0.0.1', +4874 silly resolved _npmVersion: '1.2.15', +4874 silly resolved _npmUser: { name: 'kamicane', email: 'kamicane@gmail.com' }, +4874 silly resolved maintainers: [ [Object] ], +4874 silly resolved directories: {}, +4874 silly resolved _shasum: '19dfcc8d1a1443633d54972338c1d5815b556c09', +4874 silly resolved _resolved: 'https://registry.npmjs.org/rgb/-/rgb-0.0.1.tgz', +4874 silly resolved bugs: { url: 'https://github.com/kamicane/rgb/issues' }, +4874 silly resolved readme: 'ERROR: No README data found!', +4874 silly resolved homepage: 'https://github.com/kamicane/rgb' } ] +4875 info install rgb@0.0.1 into /usr/lib/node_modules/myth/node_modules/rework-hex-alpha +4876 info installOne rgb@0.0.1 +4877 silly resolved [ { name: 'convert-source-map', +4877 silly resolved version: '0.3.5', +4877 silly resolved description: 'Converts a source-map from/to different formats and allows adding/changing properties.', +4877 silly resolved main: 'index.js', +4877 silly resolved scripts: { test: 'tap test/*.js' }, +4877 silly resolved repository: +4877 silly resolved { type: 'git', +4877 silly resolved url: 'git://github.com/thlorenz/convert-source-map.git' }, +4877 silly resolved homepage: 'https://github.com/thlorenz/convert-source-map', +4877 silly resolved dependencies: {}, +4877 silly resolved devDependencies: { 'inline-source-map': '~0.3.0', tap: '~0.4.3' }, +4877 silly resolved keywords: [ 'convert', 'sourcemap', 'source', 'map', 'browser', 'debug' ], +4877 silly resolved author: +4877 silly resolved { name: 'Thorsten Lorenz', +4877 silly resolved email: 'thlorenz@gmx.de', +4877 silly resolved url: 'http://thlorenz.com' }, +4877 silly resolved license: 'MIT', +4877 silly resolved engine: { node: '>=0.6' }, +4877 silly resolved bugs: { url: 'https://github.com/thlorenz/convert-source-map/issues' }, +4877 silly resolved _id: 'convert-source-map@0.3.5', +4877 silly resolved _shasum: 'f1d802950af7dd2631a1febe0596550c86ab3190', +4877 silly resolved _from: 'convert-source-map@0.3.5', +4877 silly resolved _npmVersion: '1.4.9', +4877 silly resolved _npmUser: { name: 'thlorenz', email: 'thlorenz@gmx.de' }, +4877 silly resolved maintainers: [ [Object] ], +4877 silly resolved dist: +4877 silly resolved { shasum: 'f1d802950af7dd2631a1febe0596550c86ab3190', +4877 silly resolved tarball: 'http://registry.npmjs.org/convert-source-map/-/convert-source-map-0.3.5.tgz' }, +4877 silly resolved directories: {}, +4877 silly resolved _resolved: 'https://registry.npmjs.org/convert-source-map/-/convert-source-map-0.3.5.tgz', +4877 silly resolved readme: 'ERROR: No README data found!' } ] +4878 info install convert-source-map@0.3.5 into /usr/lib/node_modules/myth/node_modules/rework +4879 info installOne convert-source-map@0.3.5 +4880 silly resolved [ { name: 'parse-import', +4880 silly resolved version: '0.1.3', +4880 silly resolved description: 'Parse CSS @import statements', +4880 silly resolved license: 'MIT', +4880 silly resolved repository: { type: 'git', url: 'git://github.com/kevva/parse-import' }, +4880 silly resolved author: +4880 silly resolved { name: 'Kevin Mårtensson', +4880 silly resolved email: 'kevinmartensson@gmail.com', +4880 silly resolved url: 'https://github.com/kevva' }, +4880 silly resolved engines: { node: '>=0.10.0' }, +4880 silly resolved scripts: +4880 silly resolved { browser: 'browserify -s $npm_package_name -o browser.js .', +4880 silly resolved test: 'mocha --reporter list' }, +4880 silly resolved files: [ 'index.js' ], +4880 silly resolved keywords: [ 'css', 'import', 'object', 'parse' ], +4880 silly resolved devDependencies: { browserify: '^3.44.2', mocha: '^1.18.2' }, +4880 silly resolved bugs: { url: 'https://github.com/kevva/parse-import/issues' }, +4880 silly resolved homepage: 'https://github.com/kevva/parse-import', +4880 silly resolved _id: 'parse-import@0.1.3', +4880 silly resolved _shasum: 'fe7d4cc1938dadc1da38dc2a03dba5604203fdac', +4880 silly resolved _from: 'parse-import@0.1.3', +4880 silly resolved _npmVersion: '1.4.9', +4880 silly resolved _npmUser: { name: 'kevva', email: 'kevinmartensson@gmail.com' }, +4880 silly resolved maintainers: [ [Object] ], +4880 silly resolved dist: +4880 silly resolved { shasum: 'fe7d4cc1938dadc1da38dc2a03dba5604203fdac', +4880 silly resolved tarball: 'http://registry.npmjs.org/parse-import/-/parse-import-0.1.3.tgz' }, +4880 silly resolved directories: {}, +4880 silly resolved _resolved: 'https://registry.npmjs.org/parse-import/-/parse-import-0.1.3.tgz', +4880 silly resolved readme: 'ERROR: No README data found!' } ] +4881 info install parse-import@0.1.3 into /usr/lib/node_modules/myth/node_modules/rework-import +4882 info installOne parse-import@0.1.3 +4883 silly resolved [ { name: 'find-file', +4883 silly resolved version: '0.1.4', +4883 silly resolved description: 'Search for a file in an array of paths', +4883 silly resolved keywords: [ 'find', 'file', 'path', 'search' ], +4883 silly resolved homepage: 'https://github.com/kevva/find-file', +4883 silly resolved bugs: { url: 'https://github.com/kevva/find-file/issues' }, +4883 silly resolved author: +4883 silly resolved { name: 'Kevin Mårtensson', +4883 silly resolved email: 'kevinmartensson@gmail.com', +4883 silly resolved url: 'https://github.com/kevva' }, +4883 silly resolved license: 'MIT', +4883 silly resolved repository: { type: 'git', url: 'git://github.com/kevva/find-file.git' }, +4883 silly resolved scripts: { test: 'mocha --reporter list' }, +4883 silly resolved main: 'index.js', +4883 silly resolved files: [ 'index.js' ], +4883 silly resolved devDependencies: { mocha: '~1.17.0' }, +4883 silly resolved engines: { node: '>=0.10.0' }, +4883 silly resolved _id: 'find-file@0.1.4', +4883 silly resolved dist: +4883 silly resolved { shasum: 'f806bb8132a8265232bf1c9ef95ba0746511d871', +4883 silly resolved tarball: 'http://registry.npmjs.org/find-file/-/find-file-0.1.4.tgz' }, +4883 silly resolved _from: 'find-file@0.1.4', +4883 silly resolved _npmVersion: '1.4.3', +4883 silly resolved _npmUser: { name: 'kevva', email: 'kevinmartensson@gmail.com' }, +4883 silly resolved maintainers: [ [Object] ], +4883 silly resolved directories: {}, +4883 silly resolved _shasum: 'f806bb8132a8265232bf1c9ef95ba0746511d871', +4883 silly resolved _resolved: 'https://registry.npmjs.org/find-file/-/find-file-0.1.4.tgz', +4883 silly resolved readme: 'ERROR: No README data found!' } ] +4884 info install find-file@0.1.4 into /usr/lib/node_modules/myth/node_modules/rework-import +4885 info installOne find-file@0.1.4 +4886 silly resolved [ { name: 'balanced-match', +4886 silly resolved description: 'Match balanced character pairs, like "{" and "}"', +4886 silly resolved version: '0.0.0', +4886 silly resolved repository: +4886 silly resolved { type: 'git', +4886 silly resolved url: 'git://github.com/juliangruber/balanced-match.git' }, +4886 silly resolved homepage: 'https://github.com/juliangruber/balanced-match', +4886 silly resolved main: 'index.js', +4886 silly resolved scripts: { test: 'tape test/*.js' }, +4886 silly resolved dependencies: {}, +4886 silly resolved devDependencies: { tape: '~1.1.1' }, +4886 silly resolved keywords: [ 'match', 'regexp', 'test', 'balanced', 'parse' ], +4886 silly resolved author: +4886 silly resolved { name: 'Julian Gruber', +4886 silly resolved email: 'mail@juliangruber.com', +4886 silly resolved url: 'http://juliangruber.com' }, +4886 silly resolved license: 'MIT', +4886 silly resolved bugs: { url: 'https://github.com/juliangruber/balanced-match/issues' }, +4886 silly resolved _id: 'balanced-match@0.0.0', +4886 silly resolved dist: +4886 silly resolved { shasum: '86efc32ae583496c1c1fbb51cd648de0363ebb03', +4886 silly resolved tarball: 'http://registry.npmjs.org/balanced-match/-/balanced-match-0.0.0.tgz' }, +4886 silly resolved _from: 'balanced-match@0.0.0', +4886 silly resolved _npmVersion: '1.3.11', +4886 silly resolved _npmUser: { name: 'juliangruber', email: 'julian@juliangruber.com' }, +4886 silly resolved maintainers: [ [Object] ], +4886 silly resolved directories: {}, +4886 silly resolved _shasum: '86efc32ae583496c1c1fbb51cd648de0363ebb03', +4886 silly resolved _resolved: 'https://registry.npmjs.org/balanced-match/-/balanced-match-0.0.0.tgz', +4886 silly resolved readme: 'ERROR: No README data found!' } ] +4887 info install balanced-match@0.0.0 into /usr/lib/node_modules/myth/node_modules/rework-color-function +4888 info installOne balanced-match@0.0.0 +4889 silly resolved [ { name: 'debug', +4889 silly resolved version: '0.7.4', +4889 silly resolved repository: { type: 'git', url: 'git://github.com/visionmedia/debug.git' }, +4889 silly resolved description: 'small debugging utility', +4889 silly resolved keywords: [ 'debug', 'log', 'debugger' ], +4889 silly resolved author: { name: 'TJ Holowaychuk', email: 'tj@vision-media.ca' }, +4889 silly resolved dependencies: {}, +4889 silly resolved devDependencies: { mocha: '*' }, +4889 silly resolved main: 'lib/debug.js', +4889 silly resolved browser: './debug.js', +4889 silly resolved engines: { node: '*' }, +4889 silly resolved files: [ 'lib/debug.js', 'debug.js', 'index.js' ], +4889 silly resolved component: { scripts: [Object] }, +4889 silly resolved readme: '# debug\n\n tiny node.js debugging utility modelled after node core\'s debugging technique.\n\n## Installation\n\n```\n$ npm install debug\n```\n\n## Usage\n\n With `debug` you simply invoke the exported function to generate your debug function, passing it a name which will determine if a noop function is returned, or a decorated `console.error`, so all of the `console` format string goodies you\'re used to work fine. A unique color is selected per-function for visibility.\n \nExample _app.js_:\n\n```js\nvar debug = require(\'debug\')(\'http\')\n , http = require(\'http\')\n , name = \'My App\';\n\n// fake app\n\ndebug(\'booting %s\', name);\n\nhttp.createServer(function(req, res){\n debug(req.method + \' \' + req.url);\n res.end(\'hello\\n\');\n}).listen(3000, function(){\n debug(\'listening\');\n});\n\n// fake worker of some kind\n\nrequire(\'./worker\');\n```\n\nExample _worker.js_:\n\n```js\nvar debug = require(\'debug\')(\'worker\');\n\nsetInterval(function(){\n debug(\'doing some work\');\n}, 1000);\n```\n\n The __DEBUG__ environment variable is then used to enable these based on space or comma-delimited names. Here are some examples:\n\n ![debug http and worker](http://f.cl.ly/items/18471z1H402O24072r1J/Screenshot.png)\n\n ![debug worker](http://f.cl.ly/items/1X413v1a3M0d3C2c1E0i/Screenshot.png)\n\n## Millisecond diff\n\n When actively developing an application it can be useful to see when the time spent between one `debug()` call and the next. Suppose for example you invoke `debug()` before requesting a resource, and after as well, the "+NNNms" will show you how much time was spent between calls.\n\n ![](http://f.cl.ly/items/2i3h1d3t121M2Z1A3Q0N/Screenshot.png)\n\n When stderr is not a TTY, `Date#toUTCString()` is used, making it more useful for logging the debug information as shown below:\n _(NOTE: Debug now uses stderr instead of stdout, so the correct shell command for this example is actually `DEBUG=* node example/worker 2> out &`)_\n \n ![](http://f.cl.ly/items/112H3i0e0o0P0a2Q2r11/Screenshot.png)\n \n## Conventions\n\n If you\'re using this in one or more of your libraries, you _should_ use the name of your library so that developers may toggle debugging as desired without guessing names. If you have more than one debuggers you _should_ prefix them with your library name and use ":" to separate features. For example "bodyParser" from Connect would then be "connect:bodyParser". \n\n## Wildcards\n\n The "*" character may be used as a wildcard. Suppose for example your library has debuggers named "connect:bodyParser", "connect:compress", "connect:session", instead of listing all three with `DEBUG=connect:bodyParser,connect.compress,connect:session`, you may simply do `DEBUG=connect:*`, or to run everything using this module simply use `DEBUG=*`.\n\n You can also exclude specific debuggers by prefixing them with a "-" character. For example, `DEBUG=* -connect:*` would include all debuggers except those starting with "connect:".\n\n## Browser support\n\n Debug works in the browser as well, currently persisted by `localStorage`. For example if you have `worker:a` and `worker:b` as shown below, and wish to debug both type `debug.enable(\'worker:*\')` in the console and refresh the page, this will remain until you disable with `debug.disable()`. \n\n```js\na = debug(\'worker:a\');\nb = debug(\'worker:b\');\n\nsetInterval(function(){\n a(\'doing some work\');\n}, 1000);\n\nsetInterval(function(){\n a(\'doing some work\');\n}, 1200);\n```\n\n## License \n\n(The MIT License)\n\nCopyright (c) 2011 TJ Holowaychuk <tj@vision-media.ca>\n\nPermission is hereby granted, free of charge, to any person obtaining\na copy of this software and associated documentation files (the\n\'Software\'), to deal in the Software without restriction, including\nwithout limitation the rights to use, copy, modify, merge, publish,\ndistribute, sublicense, and/or sell copies of the Software, and to\npermit persons to whom the Software is furnished to do so, subject to\nthe following conditions:\n\nThe above copyright notice and this permission notice shall be\nincluded in all copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \'AS IS\', WITHOUT WARRANTY OF ANY KIND,\nEXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\nMERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.\nIN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY\nCLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,\nTORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE\nSOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n', +4889 silly resolved readmeFilename: 'Readme.md', +4889 silly resolved bugs: { url: 'https://github.com/visionmedia/debug/issues' }, +4889 silly resolved homepage: 'https://github.com/visionmedia/debug', +4889 silly resolved _id: 'debug@0.7.4', +4889 silly resolved _from: 'debug@0.7.4' } ] +4890 info install debug@0.7.4 into /usr/lib/node_modules/myth/node_modules/rework-color-function/node_modules/css-color-function +4891 info installOne debug@0.7.4 +4892 verbose lib/node_modules/grunt/node_modules/findup-sync/node_modules/glob unbuild +4893 verbose lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/fileset/node_modules/glob unbuild +4894 verbose lib/node_modules/nodeunit/node_modules/tap/node_modules/glob unbuild +4895 verbose lib/node_modules/express/node_modules/send/node_modules/depd unbuild +4896 verbose lib/node_modules/express/node_modules/send/node_modules/mime unbuild +4897 verbose lib/node_modules/karma-coffee-preprocessor/node_modules/coffee-script unbuild +4898 info preuninstall coffee-script@1.7.1 +4899 verbose lib/node_modules/express-generator/node_modules/commander unbuild +4900 info preuninstall commander@1.3.2 +4901 verbose lib/node_modules/express-generator/node_modules/mkdirp/node_modules/minimist unbuild +4902 info preuninstall minimist@0.0.8 +4903 verbose lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/mkdirp/node_modules/minimist unbuild +4904 info preuninstall minimist@0.0.8 +4905 verbose lib/node_modules/karma-phantomjs-launcher/node_modules/phantomjs/node_modules/mkdirp/node_modules/minimist unbuild +4906 info preuninstall minimist@0.0.8 +4907 verbose lib/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist unbuild +4908 info preuninstall minimist@0.0.8 +4909 verbose lib/node_modules/grunt-cli/node_modules/findup-sync/node_modules/glob unbuild +4910 info preuninstall glob@3.2.11 +4911 verbose lib/node_modules/karma/node_modules/glob unbuild +4912 info preuninstall glob@3.2.11 +4913 verbose lib/node_modules/grunt-cli/node_modules/resolve unbuild +4914 info preuninstall resolve@0.3.1 +4915 verbose lib/node_modules/grunt-cli/node_modules/nopt unbuild +4916 info preuninstall nopt@1.0.10 +4917 verbose lib/node_modules/grunt/node_modules/nopt unbuild +4918 info preuninstall nopt@1.0.10 +4919 verbose lib/node_modules/zombie/node_modules/eventsource unbuild +4920 info preuninstall eventsource@0.0.10 +4921 verbose lib/node_modules/zombie/node_modules/html5 unbuild +4922 info preuninstall html5@0.3.14 +4923 verbose lib/node_modules/zombie/node_modules/encoding unbuild +4924 info preuninstall encoding@0.1.7 +4925 verbose lib/node_modules/zombie/node_modules/ws unbuild +4926 info preuninstall ws@0.4.31 +4927 verbose lib/node_modules/zombie/node_modules/q unbuild +4928 info preuninstall q@1.0.0 +4929 verbose lib/node_modules/grunt/node_modules/dateformat unbuild +4930 info preuninstall dateformat@1.0.2-1.2.3 +4931 verbose lib/node_modules/grunt/node_modules/lodash unbuild +4932 info preuninstall lodash@0.9.2 +4933 verbose lib/node_modules/grunt/node_modules/grunt-legacy-util/node_modules/lodash unbuild +4934 info preuninstall lodash@0.9.2 +4935 silly lockFile 2d236fca-ee-first-1-0-5 ee-first@1.0.5 +4936 silly lockFile 2d236fca-ee-first-1-0-5 ee-first@1.0.5 +4937 verbose lib/node_modules/grunt/node_modules/iconv-lite unbuild +4938 info preuninstall iconv-lite@0.2.11 +4939 verbose lib/node_modules/grunt/node_modules/underscore.string unbuild +4940 info preuninstall underscore.string@2.2.1 +4941 verbose lib/node_modules/grunt/node_modules/grunt-legacy-util/node_modules/underscore.string unbuild +4942 info preuninstall underscore.string@2.2.1 +4943 verbose lib/node_modules/grunt/node_modules/js-yaml unbuild +4944 info preuninstall js-yaml@2.0.5 +4945 verbose lib/node_modules/zombie/node_modules/jsdom unbuild +4946 info preuninstall jsdom@0.8.11 +4947 verbose lib/node_modules/grunt/node_modules/glob unbuild +4948 info preuninstall glob@3.1.21 +4949 verbose lib/node_modules/express/node_modules/depd unbuild +4950 info preuninstall depd@0.4.5 +4951 verbose lib/node_modules/express/node_modules/finalhandler unbuild +4952 info preuninstall finalhandler@0.2.0 +4953 verbose lib/node_modules/grunt/node_modules/minimatch unbuild +4954 info preuninstall minimatch@0.2.14 +4955 verbose lib/node_modules/karma/node_modules/minimatch unbuild +4956 info preuninstall minimatch@0.2.14 +4957 verbose lib/node_modules/grunt/node_modules/async unbuild +4958 info preuninstall async@0.1.22 +4959 verbose lib/node_modules/grunt/node_modules/grunt-legacy-util/node_modules/async unbuild +4960 info preuninstall async@0.1.22 +4961 verbose lib/node_modules/jsdoc/node_modules/async unbuild +4962 info preuninstall async@0.1.22 +4963 verbose lib/node_modules/jsdoc/node_modules/underscore unbuild +4964 info preuninstall underscore@1.6.0 +4965 verbose lib/node_modules/jsdoc/node_modules/requizzle/node_modules/underscore unbuild +4966 info preuninstall underscore@1.6.0 +4967 verbose lib/node_modules/jsdoc/node_modules/catharsis/node_modules/underscore-contrib/node_modules/underscore unbuild +4968 info preuninstall underscore@1.6.0 +4969 verbose lib/node_modules/jsdoc/node_modules/wrench unbuild +4970 info preuninstall wrench@1.3.9 +4971 verbose lib/node_modules/zombie/node_modules/request unbuild +4972 info preuninstall request@2.34.0 +4973 silly resolved [ { name: 'mime-types', +4973 silly resolved description: 'The ultimate javascript content-type utility.', +4973 silly resolved version: '2.0.1', +4973 silly resolved contributors: [ [Object], [Object] ], +4973 silly resolved license: 'MIT', +4973 silly resolved keywords: [ 'mime', 'types' ], +4973 silly resolved repository: { type: 'git', url: 'https://github.com/jshttp/mime-types' }, +4973 silly resolved dependencies: { 'mime-db': '~1.0.1' }, +4973 silly resolved devDependencies: { istanbul: '0', mocha: '1' }, +4973 silly resolved files: [ 'HISTORY.md', 'LICENSE', 'index.js' ], +4973 silly resolved engines: { node: '>= 0.6' }, +4973 silly resolved scripts: +4973 silly resolved { test: 'mocha --reporter spec test/test.js', +4973 silly resolved 'test-cov': 'istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot test/test.js', +4973 silly resolved 'test-travis': 'istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter dot test/test.js' }, +4973 silly resolved gitHead: 'c6e40fb033331aa87d9d4a5f1e5c0245e9edb2f6', +4973 silly resolved bugs: { url: 'https://github.com/jshttp/mime-types/issues' }, +4973 silly resolved homepage: 'https://github.com/jshttp/mime-types', +4973 silly resolved _id: 'mime-types@2.0.1', +4973 silly resolved _shasum: '7f5b4712592e7dd46ca733fd1c5f5d71356de615', +4973 silly resolved _from: 'mime-types@2.0.1', +4973 silly resolved _npmVersion: '1.4.21', +4973 silly resolved _npmUser: { name: 'dougwilson', email: 'doug@somethingdoug.com' }, +4973 silly resolved maintainers: [ [Object], [Object], [Object] ], +4973 silly resolved dist: +4973 silly resolved { shasum: '7f5b4712592e7dd46ca733fd1c5f5d71356de615', +4973 silly resolved tarball: 'http://registry.npmjs.org/mime-types/-/mime-types-2.0.1.tgz' }, +4973 silly resolved directories: {}, +4973 silly resolved _resolved: 'https://registry.npmjs.org/mime-types/-/mime-types-2.0.1.tgz', +4973 silly resolved readme: 'ERROR: No README data found!' } ] +4974 info install mime-types@2.0.1 into /usr/lib/node_modules/express/node_modules/accepts +4975 info installOne mime-types@2.0.1 +4976 silly resolved [ { name: 'mime-types', +4976 silly resolved description: 'The ultimate javascript content-type utility.', +4976 silly resolved version: '2.0.1', +4976 silly resolved contributors: [ [Object], [Object] ], +4976 silly resolved license: 'MIT', +4976 silly resolved keywords: [ 'mime', 'types' ], +4976 silly resolved repository: { type: 'git', url: 'https://github.com/jshttp/mime-types' }, +4976 silly resolved dependencies: { 'mime-db': '~1.0.1' }, +4976 silly resolved devDependencies: { istanbul: '0', mocha: '1' }, +4976 silly resolved files: [ 'HISTORY.md', 'LICENSE', 'index.js' ], +4976 silly resolved engines: { node: '>= 0.6' }, +4976 silly resolved scripts: +4976 silly resolved { test: 'mocha --reporter spec test/test.js', +4976 silly resolved 'test-cov': 'istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot test/test.js', +4976 silly resolved 'test-travis': 'istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter dot test/test.js' }, +4976 silly resolved gitHead: 'c6e40fb033331aa87d9d4a5f1e5c0245e9edb2f6', +4976 silly resolved bugs: { url: 'https://github.com/jshttp/mime-types/issues' }, +4976 silly resolved homepage: 'https://github.com/jshttp/mime-types', +4976 silly resolved _id: 'mime-types@2.0.1', +4976 silly resolved _shasum: '7f5b4712592e7dd46ca733fd1c5f5d71356de615', +4976 silly resolved _from: 'mime-types@2.0.1', +4976 silly resolved _npmVersion: '1.4.21', +4976 silly resolved _npmUser: { name: 'dougwilson', email: 'doug@somethingdoug.com' }, +4976 silly resolved maintainers: [ [Object], [Object], [Object] ], +4976 silly resolved dist: +4976 silly resolved { shasum: '7f5b4712592e7dd46ca733fd1c5f5d71356de615', +4976 silly resolved tarball: 'http://registry.npmjs.org/mime-types/-/mime-types-2.0.1.tgz' }, +4976 silly resolved directories: {}, +4976 silly resolved _resolved: 'https://registry.npmjs.org/mime-types/-/mime-types-2.0.1.tgz', +4976 silly resolved readme: 'ERROR: No README data found!' } ] +4977 info install mime-types@2.0.1 into /usr/lib/node_modules/express/node_modules/type-is +4978 info installOne mime-types@2.0.1 +4979 verbose lib/node_modules/vtop/node_modules/commander unbuild +4980 info preuninstall commander@2.2.0 +4981 verbose lib/node_modules/vtop/node_modules/glob unbuild +4982 info preuninstall glob@4.0.4 +4983 verbose lib/node_modules/vtop/node_modules/drawille unbuild +4984 info preuninstall drawille@0.1.1 +4985 verbose lib/node_modules/karma/node_modules/graceful-fs unbuild +4986 info preuninstall graceful-fs@2.0.3 +4987 verbose lib/node_modules/karma/node_modules/q unbuild +4988 info preuninstall q@0.9.7 +4989 verbose lib/node_modules/karma/node_modules/http-proxy unbuild +4990 info preuninstall http-proxy@0.10.4 +4991 verbose lib/node_modules/karma/node_modules/socket.io unbuild +4992 info preuninstall socket.io@0.9.17 +4993 verbose lib/node_modules/karma/node_modules/optimist/node_modules/minimist unbuild +4994 info preuninstall minimist@0.0.10 +4995 verbose lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/optimist/node_modules/minimist unbuild +4996 info preuninstall minimist@0.0.10 +4997 verbose lib/node_modules/karma/node_modules/useragent/node_modules/lru-cache unbuild +4998 info preuninstall lru-cache@2.2.4 +4999 verbose lib/node_modules/karma/node_modules/connect unbuild +5000 info preuninstall connect@2.12.0 +5001 verbose lib/node_modules/karma/node_modules/chokidar/node_modules/recursive-readdir unbuild +5002 info preuninstall recursive-readdir@0.0.2 +5003 verbose lib/node_modules/karma/node_modules/log4js/node_modules/semver unbuild +5004 info preuninstall semver@1.1.4 +5005 verbose lib/node_modules/karma-coverage/node_modules/minimatch unbuild +5006 info preuninstall minimatch@0.3.0 +5007 verbose lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/escodegen unbuild +5008 info preuninstall escodegen@1.3.3 +5009 verbose lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/fileset/node_modules/minimatch unbuild +5010 info preuninstall minimatch@0.4.0 +5011 verbose lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/resolve unbuild +5012 info preuninstall resolve@0.7.4 +5013 verbose lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/js-yaml/node_modules/esprima unbuild +5014 info preuninstall esprima@1.0.4 +5015 verbose lib/node_modules/karma/node_modules/log4js/node_modules/async unbuild +5016 info preuninstall async@0.2.10 +5017 verbose lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/js-yaml/node_modules/argparse/node_modules/underscore unbuild +5018 info preuninstall underscore@1.4.4 +5019 verbose lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/mkdirp unbuild +5020 info preuninstall mkdirp@0.3.5 +5021 verbose lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/escodegen unbuild +5022 info preuninstall escodegen@1.1.0 +5023 verbose lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/istanbul unbuild +5024 info preuninstall istanbul@0.2.16 +5025 verbose lib/node_modules/grunt/node_modules/coffee-script unbuild +5026 info preuninstall coffee-script@1.3.3 +5027 verbose lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/coffee-script-redux/node_modules/source-map unbuild +5028 info preuninstall source-map@0.1.11 +5029 verbose lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/coffee-script-redux/node_modules/escodegen unbuild +5030 info preuninstall escodegen@0.0.28 +5031 verbose lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/coffee-script-redux/node_modules/esmangle unbuild +5032 info preuninstall esmangle@0.0.17 +5033 verbose lib/node_modules/express/node_modules/path-to-regexp unbuild +5034 info preuninstall path-to-regexp@0.1.3 +5035 verbose lib/node_modules/nodeunit/node_modules/tap/node_modules/nopt unbuild +5036 info preuninstall nopt@2.2.1 +5037 verbose lib/node_modules/nodeunit/node_modules/tap/node_modules/deep-equal unbuild +5038 info preuninstall deep-equal@0.0.0 +5039 verbose lib/node_modules/karma-phantomjs-launcher/node_modules/phantomjs/node_modules/request unbuild +5040 info preuninstall request@2.42.0 +5041 verbose lib/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm unbuild +5042 info preuninstall charm@0.1.2 +5043 verbose lib/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse unbuild +5044 info preuninstall traverse@0.5.2 +5045 verbose lib/node_modules/myth/node_modules/rework-custom-media unbuild +5046 info preuninstall rework-custom-media@0.1.1 +5047 verbose lib/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/uglify-js unbuild +5048 info preuninstall uglify-js@1.1.1 +5049 verbose lib/node_modules/myth/node_modules/to-slug-case/node_modules/to-space-case unbuild +5050 info preuninstall to-space-case@0.1.2 +5051 verbose lib/node_modules/myth/node_modules/read-file-stdin/node_modules/stream-to-array unbuild +5052 info preuninstall stream-to-array@1.0.0 +5053 verbose lib/node_modules/myth/node_modules/rework-hex-alpha/node_modules/rgb unbuild +5054 info preuninstall rgb@0.0.1 +5055 verbose lib/node_modules/myth/node_modules/rework/node_modules/convert-source-map unbuild +5056 info preuninstall convert-source-map@0.3.5 +5057 verbose lib/node_modules/myth/node_modules/rework-import/node_modules/parse-import unbuild +5058 info preuninstall parse-import@0.1.3 +5059 verbose lib/node_modules/myth/node_modules/rework-import/node_modules/find-file unbuild +5060 info preuninstall find-file@0.1.4 +5061 verbose lib/node_modules/myth/node_modules/rework-color-function/node_modules/balanced-match unbuild +5062 info preuninstall balanced-match@0.0.0 +5063 verbose lib/node_modules/myth/node_modules/rework-color-function/node_modules/css-color-function/node_modules/debug unbuild +5064 info preuninstall debug@0.7.4 +5065 silly resolved [ { name: 'nopt', +5065 silly resolved version: '2.1.2', +5065 silly resolved description: 'Option parsing for Node, supporting types, shorthands, etc. Used by npm.', +5065 silly resolved author: +5065 silly resolved { name: 'Isaac Z. Schlueter', +5065 silly resolved email: 'i@izs.me', +5065 silly resolved url: 'http://blog.izs.me/' }, +5065 silly resolved main: 'lib/nopt.js', +5065 silly resolved scripts: { test: 'node lib/nopt.js' }, +5065 silly resolved repository: { type: 'git', url: 'http://github.com/isaacs/nopt' }, +5065 silly resolved bin: { nopt: './bin/nopt.js' }, +5065 silly resolved license: +5065 silly resolved { type: 'MIT', +5065 silly resolved url: 'https://github.com/isaacs/nopt/raw/master/LICENSE' }, +5065 silly resolved dependencies: { abbrev: '1' }, +5065 silly resolved readme: 'If you want to write an option parser, and have it be good, there are\ntwo ways to do it. The Right Way, and the Wrong Way.\n\nThe Wrong Way is to sit down and write an option parser. We\'ve all done\nthat.\n\nThe Right Way is to write some complex configurable program with so many\noptions that you go half-insane just trying to manage them all, and put\nit off with duct-tape solutions until you see exactly to the core of the\nproblem, and finally snap and write an awesome option parser.\n\nIf you want to write an option parser, don\'t write an option parser.\nWrite a package manager, or a source control system, or a service\nrestarter, or an operating system. You probably won\'t end up with a\ngood one of those, but if you don\'t give up, and you are relentless and\ndiligent enough in your procrastination, you may just end up with a very\nnice option parser.\n\n## USAGE\n\n // my-program.js\n var nopt = require("nopt")\n , Stream = require("stream").Stream\n , path = require("path")\n , knownOpts = { "foo" : [String, null]\n , "bar" : [Stream, Number]\n , "baz" : path\n , "bloo" : [ "big", "medium", "small" ]\n , "flag" : Boolean\n , "pick" : Boolean\n , "many" : [String, Array]\n }\n , shortHands = { "foofoo" : ["--foo", "Mr. Foo"]\n , "b7" : ["--bar", "7"]\n , "m" : ["--bloo", "medium"]\n , "p" : ["--pick"]\n , "f" : ["--flag"]\n }\n // everything is optional.\n // knownOpts and shorthands default to {}\n // arg list defaults to process.argv\n // slice defaults to 2\n , parsed = nopt(knownOpts, shortHands, process.argv, 2)\n console.log(parsed)\n\nThis would give you support for any of the following:\n\n```bash\n$ node my-program.js --foo "blerp" --no-flag\n{ "foo" : "blerp", "flag" : false }\n\n$ node my-program.js ---bar 7 --foo "Mr. Hand" --flag\n{ bar: 7, foo: "Mr. Hand", flag: true }\n\n$ node my-program.js --foo "blerp" -f -----p\n{ foo: "blerp", flag: true, pick: true }\n\n$ node my-program.js -fp --foofoo\n{ foo: "Mr. Foo", flag: true, pick: true }\n\n$ node my-program.js --foofoo -- -fp # -- stops the flag parsing.\n{ foo: "Mr. Foo", argv: { remain: ["-fp"] } }\n\n$ node my-program.js --blatzk 1000 -fp # unknown opts are ok.\n{ blatzk: 1000, flag: true, pick: true }\n\n$ node my-program.js --blatzk true -fp # but they need a value\n{ blatzk: true, flag: true, pick: true }\n\n$ node my-program.js --no-blatzk -fp # unless they start with "no-"\n{ blatzk: false, flag: true, pick: true }\n\n$ node my-program.js --baz b/a/z # known paths are resolved.\n{ baz: "/Users/isaacs/b/a/z" }\n\n# if Array is one of the types, then it can take many\n# values, and will always be an array. The other types provided\n# specify what types are allowed in the list.\n\n$ node my-program.js --many 1 --many null --many foo\n{ many: ["1", "null", "foo"] }\n\n$ node my-program.js --many foo\n{ many: ["foo"] }\n```\n\nRead the tests at the bottom of `lib/nopt.js` for more examples of\nwhat this puppy can do.\n\n## Types\n\nThe following types are supported, and defined on `nopt.typeDefs`\n\n* String: A normal string. No parsing is done.\n* path: A file system path. Gets resolved against cwd if not absolute.\n* url: A url. If it doesn\'t parse, it isn\'t accepted.\n* Number: Must be numeric.\n* Date: Must parse as a date. If it does, and `Date` is one of the options,\n then it will return a Date object, not a string.\n* Boolean: Must be either `true` or `false`. If an option is a boolean,\n then it does not need a value, and its presence will imply `true` as\n the value. To negate boolean flags, do `--no-whatever` or `--whatever\n false`\n* NaN: Means that the option is strictly not allowed. Any value will\n fail.\n* Stream: An object matching the "Stream" class in node. Valuable\n for use when validating programmatically. (npm uses this to let you\n supply any WriteStream on the `outfd` and `logfd` config options.)\n* Array: If `Array` is specified as one of the types, then the value\n will be parsed as a list of options. This means that multiple values\n can be specified, and that the value will always be an array.\n\nIf a type is an array of values not on this list, then those are\nconsidered valid values. For instance, in the example above, the\n`--bloo` option can only be one of `"big"`, `"medium"`, or `"small"`,\nand any other value will be rejected.\n\nWhen parsing unknown fields, `"true"`, `"false"`, and `"null"` will be\ninterpreted as their JavaScript equivalents, and numeric values will be\ninterpreted as a number.\n\nYou can also mix types and values, or multiple types, in a list. For\ninstance `{ blah: [Number, null] }` would allow a value to be set to\neither a Number or null. When types are ordered, this implies a\npreference, and the first type that can be used to properly interpret\nthe value will be used.\n\nTo define a new type, add it to `nopt.typeDefs`. Each item in that\nhash is an object with a `type` member and a `validate` method. The\n`type` member is an object that matches what goes in the type list. The\n`validate` method is a function that gets called with `validate(data,\nkey, val)`. Validate methods should assign `data[key]` to the valid\nvalue of `val` if it can be handled properly, or return boolean\n`false` if it cannot.\n\nYou can also call `nopt.clean(data, types, typeDefs)` to clean up a\nconfig object and remove its invalid properties.\n\n## Error Handling\n\nBy default, nopt outputs a warning to standard error when invalid\noptions are found. You can change this behavior by assigning a method\nto `nopt.invalidHandler`. This method will be called with\nthe offending `nopt.invalidHandler(key, val, types)`.\n\nIf no `nopt.invalidHandler` is assigned, then it will console.error\nits whining. If it is assigned to boolean `false` then the warning is\nsuppressed.\n\n## Abbreviations\n\nYes, they are supported. If you define options like this:\n\n```javascript\n{ "foolhardyelephants" : Boolean\n, "pileofmonkeys" : Boolean }\n```\n\nThen this will work:\n\n```bash\nnode program.js --foolhar --pil\nnode program.js --no-f --pileofmon\n# etc.\n```\n\n## Shorthands\n\nShorthands are a hash of shorter option names to a snippet of args that\nthey expand to.\n\nIf multiple one-character shorthands are all combined, and the\ncombination does not unambiguously match any other option or shorthand,\nthen they will be broken up into their constituent parts. For example:\n\n```json\n{ "s" : ["--loglevel", "silent"]\n, "g" : "--global"\n, "f" : "--force"\n, "p" : "--parseable"\n, "l" : "--long"\n}\n```\n\n```bash\nnpm ls -sgflp\n# just like doing this:\nnpm ls --loglevel silent --global --force --long --parseable\n```\n\n## The Rest of the args\n\nThe config object returned by nopt is given a special member called\n`argv`, which is an object with the following fields:\n\n* `remain`: The remaining args after all the parsing has occurred.\n* `original`: The args as they originally appeared.\n* `cooked`: The args after flags and shorthands are expanded.\n\n## Slicing\n\nNode programs are called with more or less the exact argv as it appears\nin C land, after the v8 and node-specific options have been plucked off.\nAs such, `argv[0]` is always `node` and `argv[1]` is always the\nJavaScript program being run.\n\nThat\'s usually not very useful to you. So they\'re sliced off by\ndefault. If you want them, then you can pass in `0` as the last\nargument, or any other number that you\'d like to slice off the start of\nthe list.\n', +5065 silly resolved readmeFilename: 'README.md', +5065 silly resolved bugs: { url: 'https://github.com/isaacs/nopt/issues' }, +5065 silly resolved homepage: 'https://github.com/isaacs/nopt', +5065 silly resolved _id: 'nopt@2.1.2', +5065 silly resolved _from: 'nopt@2.1.2' } ] +5066 info install nopt@2.1.2 into /usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/coffee-script-redux +5067 info installOne nopt@2.1.2 +5068 silly resolved [ { name: 'handlebars', +5068 silly resolved barename: 'handlebars', +5068 silly resolved version: '1.3.0', +5068 silly resolved description: 'Handlebars provides the power necessary to let you build semantic templates effectively with no frustration', +5068 silly resolved homepage: 'http://www.handlebarsjs.com/', +5068 silly resolved keywords: [ 'handlebars', 'mustache', 'template', 'html' ], +5068 silly resolved repository: +5068 silly resolved { type: 'git', +5068 silly resolved url: 'https://github.com/wycats/handlebars.js.git' }, +5068 silly resolved author: { name: 'Yehuda Katz' }, +5068 silly resolved license: 'MIT', +5068 silly resolved engines: { node: '>=0.4.7' }, +5068 silly resolved dependencies: { optimist: '~0.3', 'uglify-js': '~2.3' }, +5068 silly resolved optionalDependencies: { 'uglify-js': '~2.3' }, +5068 silly resolved devDependencies: +5068 silly resolved { async: '~0.2.9', +5068 silly resolved 'aws-sdk': '~1.5.0', +5068 silly resolved benchmark: '~1.0', +5068 silly resolved 'dustjs-linkedin': '~2.0.2', +5068 silly resolved eco: '~1.1.0-rc-3', +5068 silly resolved grunt: '~0.4.1', +5068 silly resolved 'grunt-cli': '~0.1.10', +5068 silly resolved 'grunt-contrib-clean': '~0.4.1', +5068 silly resolved 'grunt-contrib-concat': '~0.3.0', +5068 silly resolved 'grunt-contrib-connect': '~0.5.0', +5068 silly resolved 'grunt-contrib-copy': '~0.4.1', +5068 silly resolved 'grunt-contrib-jshint': '0.x', +5068 silly resolved 'grunt-contrib-requirejs': '~0.4.1', +5068 silly resolved 'grunt-contrib-uglify': '~0.2.2', +5068 silly resolved 'grunt-contrib-watch': '~0.5.3', +5068 silly resolved 'grunt-saucelabs': '~4.1.2', +5068 silly resolved 'es6-module-packager': '0.x', +5068 silly resolved jison: '~0.3.0', +5068 silly resolved 'keen.io': '0.0.3', +5068 silly resolved mocha: '*', +5068 silly resolved mustache: '~0.7.2', +5068 silly resolved semver: '~2.1.0', +5068 silly resolved underscore: '~1.5.1' }, +5068 silly resolved main: 'lib/index.js', +5068 silly resolved bin: { handlebars: 'bin/handlebars' }, +5068 silly resolved scripts: { test: 'grunt' }, +5068 silly resolved bugs: { url: 'https://github.com/wycats/handlebars.js/issues' }, +5068 silly resolved _id: 'handlebars@1.3.0', +5068 silly resolved dist: +5068 silly resolved { shasum: '9e9b130a93e389491322d975cf3ec1818c37ce34', +5068 silly resolved tarball: 'http://registry.npmjs.org/handlebars/-/handlebars-1.3.0.tgz' }, +5068 silly resolved _from: 'handlebars@1.3.0', +5068 silly resolved _npmVersion: '1.3.11', +5068 silly resolved _npmUser: { name: 'kpdecker', email: 'kpdecker@gmail.com' }, +5068 silly resolved maintainers: [ [Object] ], +5068 silly resolved directories: {}, +5068 silly resolved _shasum: '9e9b130a93e389491322d975cf3ec1818c37ce34', +5068 silly resolved _resolved: 'https://registry.npmjs.org/handlebars/-/handlebars-1.3.0.tgz', +5068 silly resolved readme: 'ERROR: No README data found!' } ] +5069 info install handlebars@1.3.0 into /usr/lib/node_modules/karma-coverage/node_modules/istanbul +5070 info installOne handlebars@1.3.0 +5071 silly resolved [ { version: '1.4.27', +5071 silly resolved name: 'npm', +5071 silly resolved description: 'A package manager for node', +5071 silly resolved keywords: [ 'package manager', 'modules', 'install', 'package.json' ], +5071 silly resolved preferGlobal: true, +5071 silly resolved config: { publishtest: false }, +5071 silly resolved homepage: 'https://npmjs.org/doc/', +5071 silly resolved author: +5071 silly resolved { name: 'Isaac Z. Schlueter', +5071 silly resolved email: 'i@izs.me', +5071 silly resolved url: 'http://blog.izs.me' }, +5071 silly resolved repository: { type: 'git', url: 'https://github.com/npm/npm' }, +5071 silly resolved bugs: +5071 silly resolved { url: 'http://github.com/npm/npm/issues', +5071 silly resolved email: 'npm-@googlegroups.com' }, +5071 silly resolved directories: { doc: './doc', man: './man', lib: './lib', bin: './bin' }, +5071 silly resolved main: './lib/npm.js', +5071 silly resolved bin: { npm: './bin/npm-cli.js' }, +5071 silly resolved dependencies: +5071 silly resolved { abbrev: '~1.0.5', +5071 silly resolved ansi: '~0.3.0', +5071 silly resolved ansicolors: '~0.3.2', +5071 silly resolved ansistyles: '~0.1.3', +5071 silly resolved archy: '0', +5071 silly resolved 'block-stream': '0.0.7', +5071 silly resolved 'char-spinner': '~1.0.1', +5071 silly resolved 'child-process-close': '~0.1.1', +5071 silly resolved chmodr: '~0.1.0', +5071 silly resolved chownr: '0', +5071 silly resolved 'cmd-shim': '2.0.0', +5071 silly resolved columnify: '~1.2.1', +5071 silly resolved editor: '~0.1.0', +5071 silly resolved fstream: '~1.0.2', +5071 silly resolved 'fstream-npm': '~1.0.0', +5071 silly resolved 'github-url-from-git': '~1.4.0', +5071 silly resolved 'github-url-from-username-repo': '~1.0.0', +5071 silly resolved glob: '~4.0.5', +5071 silly resolved 'graceful-fs': '~3.0.0', +5071 silly resolved inflight: '~1.0.1', +5071 silly resolved ini: '~1.2.0', +5071 silly resolved 'init-package-json': '~1.0.0', +5071 silly resolved lockfile: '~1.0.0', +5071 silly resolved 'lru-cache': '~2.5.0', +5071 silly resolved minimatch: '~1.0.0', +5071 silly resolved mkdirp: '~0.5.0', +5071 silly resolved 'node-gyp': '~1.0.1', +5071 silly resolved nopt: '~3.0.1', +5071 silly resolved 'npm-cache-filename': '~1.0.1', +5071 silly resolved 'npm-install-checks': '~1.0.2', +5071 silly resolved 'npm-registry-client': '~2.0.7', +5071 silly resolved 'npm-user-validate': '~0.1.0', +5071 silly resolved npmconf: '~1.1.8', +5071 silly resolved npmlog: '~0.1.1', +5071 silly resolved once: '~1.3.0', +5071 silly resolved opener: '~1.3.0', +5071 silly resolved osenv: '~0.1.0', +5071 silly resolved 'path-is-inside': '~1.0.0', +5071 silly resolved read: '~1.0.4', +5071 silly resolved 'read-installed': '~2.0.5', +5071 silly resolved 'read-package-json': '~1.2.7', +5071 silly resolved request: '~2.42.0', +5071 silly resolved retry: '~0.6.0', +5071 silly resolved rimraf: '~2.2.8', +5071 silly resolved semver: '~2.3.0', +5071 silly resolved sha: '~1.2.1', +5071 silly resolved slide: '~1.1.5', +5071 silly resolved 'sorted-object': '~1.0.0', +5071 silly resolved tar: '~1.0.1', +5071 silly resolved 'text-table': '~0.2.0', +5071 silly resolved 'uid-number': '0.0.5', +5071 silly resolved which: '1' }, +5071 silly resolved bundleDependencies: +5071 silly resolved [ 'abbrev', +5071 silly resolved 'ansi', +5071 silly resolved 'ansicolors', +5071 silly resolved 'ansistyles', +5071 silly resolved 'archy', +5071 silly resolved 'block-stream', +5071 silly resolved 'char-spinner', +5071 silly resolved 'child-process-close', +5071 silly resolved 'chmodr', +5071 silly resolved 'chownr', +5071 silly resolved 'cmd-shim', +5071 silly resolved 'columnify', +5071 silly resolved 'editor', +5071 silly resolved 'fstream', +5071 silly resolved 'fstream-npm', +5071 silly resolved 'github-url-from-git', +5071 silly resolved 'github-url-from-username-repo', +5071 silly resolved 'glob', +5071 silly resolved 'graceful-fs', +5071 silly resolved 'inflight', +5071 silly resolved 'inherits', +5071 silly resolved 'ini', +5071 silly resolved 'init-package-json', +5071 silly resolved 'lockfile', +5071 silly resolved 'lru-cache', +5071 silly resolved 'minimatch', +5071 silly resolved 'mkdirp', +5071 silly resolved 'node-gyp', +5071 silly resolved 'nopt', +5071 silly resolved 'npm-cache-filename', +5071 silly resolved 'npm-install-checks', +5071 silly resolved 'npm-registry-client', +5071 silly resolved 'npm-user-validate', +5071 silly resolved 'npmconf', +5071 silly resolved 'npmlog', +5071 silly resolved 'once', +5071 silly resolved 'opener', +5071 silly resolved 'osenv', +5071 silly resolved 'path-is-inside', +5071 silly resolved 'read', +5071 silly resolved 'read-installed', +5071 silly resolved 'read-package-json', +5071 silly resolved 'request', +5071 silly resolved 'retry', +5071 silly resolved 'rimraf', +5071 silly resolved 'semver', +5071 silly resolved 'sha', +5071 silly resolved 'slide', +5071 silly resolved 'sorted-object', +5071 silly resolved 'tar', +5071 silly resolved 'text-table', +5071 silly resolved 'uid-number', +5071 silly resolved 'which' ], +5071 silly resolved devDependencies: +5071 silly resolved { marked: '~0.3.2', +5071 silly resolved 'npm-registry-couchapp': '~2.3.6', +5071 silly resolved 'npm-registry-mock': '~0.6.3', +5071 silly resolved ronn: '~0.3.6', +5071 silly resolved tap: '~0.4.9' }, +5071 silly resolved engines: { node: '>=0.8', npm: '1' }, +5071 silly resolved scripts: +5071 silly resolved { 'test-legacy': 'node ./test/run.js', +5071 silly resolved test: 'tap --timeout 120 test/tap/*.js', +5071 silly resolved tap: 'tap --timeout 120 test/tap/*.js', +5071 silly resolved 'test-all': 'node ./test/run.js && tap test/tap/*.js', +5071 silly resolved prepublish: 'node bin/npm-cli.js prune --prefix=. --no-global && rm -rf test/*/*/node_modules && make -j8 doc', +5071 silly resolved dumpconf: 'env | grep npm | sort | uniq' }, +5071 silly resolved license: 'Artistic-2.0', +5071 silly resolved contributors: +5071 silly resolved [ [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object], +5071 silly resolved [Object] ], +5071 silly resolved man: +5071 silly resolved [ '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-README.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-adduser.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-bin.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-bugs.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-build.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-bundle.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-cache.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-completion.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-config.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-dedupe.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-deprecate.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-docs.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-edit.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-explore.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-help-search.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-help.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-init.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-install.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-link.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-ls.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-outdated.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-owner.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-pack.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-prefix.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-prune.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-publish.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-rebuild.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-repo.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-restart.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-rm.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-root.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-run-script.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-search.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-shrinkwrap.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-star.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-stars.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-start.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-stop.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-submodule.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-tag.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-test.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-uninstall.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-unpublish.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-update.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-version.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-view.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm-whoami.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man1/npm.1', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-bin.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-bugs.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-cache.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-commands.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-config.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-deprecate.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-docs.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-edit.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-explore.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-help-search.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-init.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-install.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-link.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-load.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-ls.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-outdated.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-owner.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-pack.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-prefix.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-prune.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-publish.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-rebuild.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-repo.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-restart.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-root.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-run-script.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-search.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-shrinkwrap.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-start.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-stop.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-submodule.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-tag.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-test.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-uninstall.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-unpublish.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-update.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-version.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-view.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm-whoami.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man3/npm.3', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man5/npm-folders.5', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man5/npm-global.5', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man5/npm-json.5', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man5/npmrc.5', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man5/package.json.5', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man7/npm-coding-style.7', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man7/npm-config.7', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man7/npm-developers.7', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man7/npm-disputes.7', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man7/npm-faq.7', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man7/npm-index.7', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man7/npm-registry.7', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man7/npm-scope.7', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man7/npm-scripts.7', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man7/removing-npm.7', +5071 silly resolved '/Users/ogd/Documents/projects/npm/npm/man/man7/semver.7' ], +5071 silly resolved gitHead: '7388fa365b016873aab651a13edf2793fd773228', +5071 silly resolved _id: 'npm@1.4.27', +5071 silly resolved _shasum: '5b81115c6daa0cc2714acc0c333a49e876c13b8e', +5071 silly resolved _from: 'npm@1.4.27', +5071 silly resolved _npmVersion: '1.4.27', +5071 silly resolved _npmUser: { name: 'othiym23', email: 'ogd@aoaioxxysz.net' }, +5071 silly resolved maintainers: [ [Object], [Object] ], +5071 silly resolved dist: +5071 silly resolved { shasum: '5b81115c6daa0cc2714acc0c333a49e876c13b8e', +5071 silly resolved tarball: 'http://registry.npmjs.org/npm/-/npm-1.4.27.tgz' }, +5071 silly resolved _resolved: 'https://registry.npmjs.org/npm/-/npm-1.4.27.tgz', +5071 silly resolved readme: 'ERROR: No README data found!' } ] +5072 info install npm@1.4.27 into /usr/lib +5073 info installOne npm@1.4.27 +5074 silly resolved [ { name: 'ms', +5074 silly resolved version: '0.6.2', +5074 silly resolved description: 'Tiny ms conversion utility', +5074 silly resolved repository: { type: 'git', url: 'git://github.com/guille/ms.js.git' }, +5074 silly resolved main: './index', +5074 silly resolved devDependencies: { mocha: '*', 'expect.js': '*', serve: '*' }, +5074 silly resolved component: { scripts: [Object] }, +5074 silly resolved readme: '# ms.js: miliseconds conversion utility\n\n```js\nms(\'1d\') // 86400000\nms(\'10h\') // 36000000\nms(\'2h\') // 7200000\nms(\'1m\') // 60000\nms(\'5s\') // 5000\nms(\'100\') // 100\n```\n\n```js\nms(60000) // "1m"\nms(2 * 60000) // "2m"\nms(ms(\'10 hours\')) // "10h"\n```\n\n```js\nms(60000, { long: true }) // "1 minute"\nms(2 * 60000, { long: true }) // "2 minutes"\nms(ms(\'10 hours\', { long: true })) // "10 hours"\n```\n\n- Node/Browser compatible. Published as `ms` in NPM.\n- If a number is supplied to `ms`, a string with a unit is returned.\n- If a string that contains the number is supplied, it returns it as\na number (e.g: it returns `100` for `\'100\'`).\n- If you pass a string with a number and a valid unit, the number of\nequivalent ms is returned.\n\n## License\n\nMIT', +5074 silly resolved readmeFilename: 'README.md', +5074 silly resolved bugs: { url: 'https://github.com/guille/ms.js/issues' }, +5074 silly resolved _id: 'ms@0.6.2', +5074 silly resolved dist: +5074 silly resolved { shasum: 'd89c2124c6fdc1353d65a8b77bf1aac4b193708c', +5074 silly resolved tarball: 'http://registry.npmjs.org/ms/-/ms-0.6.2.tgz' }, +5074 silly resolved _from: 'ms@0.6.2', +5074 silly resolved _npmVersion: '1.2.30', +5074 silly resolved _npmUser: { name: 'rauchg', email: 'rauchg@gmail.com' }, +5074 silly resolved maintainers: [ [Object] ], +5074 silly resolved directories: {}, +5074 silly resolved _shasum: 'd89c2124c6fdc1353d65a8b77bf1aac4b193708c', +5074 silly resolved _resolved: 'https://registry.npmjs.org/ms/-/ms-0.6.2.tgz', +5074 silly resolved homepage: 'https://github.com/guille/ms.js' } ] +5075 info install ms@0.6.2 into /usr/lib/node_modules/express/node_modules/debug +5076 info installOne ms@0.6.2 +5077 silly resolved [ { name: 'ms', +5077 silly resolved version: '0.6.2', +5077 silly resolved description: 'Tiny ms conversion utility', +5077 silly resolved repository: { type: 'git', url: 'git://github.com/guille/ms.js.git' }, +5077 silly resolved main: './index', +5077 silly resolved devDependencies: { mocha: '*', 'expect.js': '*', serve: '*' }, +5077 silly resolved component: { scripts: [Object] }, +5077 silly resolved readme: '# ms.js: miliseconds conversion utility\n\n```js\nms(\'1d\') // 86400000\nms(\'10h\') // 36000000\nms(\'2h\') // 7200000\nms(\'1m\') // 60000\nms(\'5s\') // 5000\nms(\'100\') // 100\n```\n\n```js\nms(60000) // "1m"\nms(2 * 60000) // "2m"\nms(ms(\'10 hours\')) // "10h"\n```\n\n```js\nms(60000, { long: true }) // "1 minute"\nms(2 * 60000, { long: true }) // "2 minutes"\nms(ms(\'10 hours\', { long: true })) // "10 hours"\n```\n\n- Node/Browser compatible. Published as `ms` in NPM.\n- If a number is supplied to `ms`, a string with a unit is returned.\n- If a string that contains the number is supplied, it returns it as\na number (e.g: it returns `100` for `\'100\'`).\n- If you pass a string with a number and a valid unit, the number of\nequivalent ms is returned.\n\n## License\n\nMIT', +5077 silly resolved readmeFilename: 'README.md', +5077 silly resolved bugs: { url: 'https://github.com/guille/ms.js/issues' }, +5077 silly resolved _id: 'ms@0.6.2', +5077 silly resolved dist: +5077 silly resolved { shasum: 'd89c2124c6fdc1353d65a8b77bf1aac4b193708c', +5077 silly resolved tarball: 'http://registry.npmjs.org/ms/-/ms-0.6.2.tgz' }, +5077 silly resolved _from: 'ms@0.6.2', +5077 silly resolved _npmVersion: '1.2.30', +5077 silly resolved _npmUser: { name: 'rauchg', email: 'rauchg@gmail.com' }, +5077 silly resolved maintainers: [ [Object] ], +5077 silly resolved directories: {}, +5077 silly resolved _shasum: 'd89c2124c6fdc1353d65a8b77bf1aac4b193708c', +5077 silly resolved _resolved: 'https://registry.npmjs.org/ms/-/ms-0.6.2.tgz', +5077 silly resolved homepage: 'https://github.com/guille/ms.js' } ] +5078 info install ms@0.6.2 into /usr/lib/node_modules/express/node_modules/send +5079 info installOne ms@0.6.2 +5080 verbose lib/node_modules/express/node_modules/accepts/node_modules/mime-types unbuild +5081 verbose lib/node_modules/express/node_modules/type-is/node_modules/mime-types unbuild +5082 silly lockFile 1d1951ad-crc-3-0-0 crc@3.0.0 +5083 silly lockFile 1d1951ad-crc-3-0-0 crc@3.0.0 +5084 info uninstall coffee-script@1.7.1 +5085 info uninstall commander@1.3.2 +5086 info uninstall minimist@0.0.8 +5087 info uninstall minimist@0.0.8 +5088 info uninstall minimist@0.0.8 +5089 info uninstall minimist@0.0.8 +5090 info uninstall glob@3.2.11 +5091 verbose tar unpack /root/.npm/glob/3.2.11/package.tgz +5092 silly lockFile 03038527-es-findup-sync-node-modules-glob tar:///usr/lib/node_modules/grunt/node_modules/findup-sync/node_modules/glob +5093 verbose lock tar:///usr/lib/node_modules/grunt/node_modules/findup-sync/node_modules/glob /root/.npm/03038527-es-findup-sync-node-modules-glob.lock +5094 silly lockFile 0cfbf35b-root-npm-glob-3-2-11-package-tgz tar:///root/.npm/glob/3.2.11/package.tgz +5095 verbose lock tar:///root/.npm/glob/3.2.11/package.tgz /root/.npm/0cfbf35b-root-npm-glob-3-2-11-package-tgz.lock +5096 info uninstall glob@3.2.11 +5097 verbose tar unpack /root/.npm/glob/3.2.11/package.tgz +5098 silly lockFile efe1bbae-odules-fileset-node-modules-glob tar:///usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/fileset/node_modules/glob +5099 verbose lock tar:///usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/fileset/node_modules/glob /root/.npm/efe1bbae-odules-fileset-node-modules-glob.lock +5100 silly lockFile 0cfbf35b-root-npm-glob-3-2-11-package-tgz tar:///root/.npm/glob/3.2.11/package.tgz +5101 verbose lock tar:///root/.npm/glob/3.2.11/package.tgz /root/.npm/0cfbf35b-root-npm-glob-3-2-11-package-tgz.lock +5102 verbose tar unpack /root/.npm/glob/3.2.11/package.tgz +5103 silly lockFile 73dcfcf0-de-modules-tap-node-modules-glob tar:///usr/lib/node_modules/nodeunit/node_modules/tap/node_modules/glob +5104 verbose lock tar:///usr/lib/node_modules/nodeunit/node_modules/tap/node_modules/glob /root/.npm/73dcfcf0-de-modules-tap-node-modules-glob.lock +5105 silly lockFile 0cfbf35b-root-npm-glob-3-2-11-package-tgz tar:///root/.npm/glob/3.2.11/package.tgz +5106 verbose lock tar:///root/.npm/glob/3.2.11/package.tgz /root/.npm/0cfbf35b-root-npm-glob-3-2-11-package-tgz.lock +5107 info uninstall resolve@0.3.1 +5108 info uninstall nopt@1.0.10 +5109 info uninstall nopt@1.0.10 +5110 info uninstall eventsource@0.0.10 +5111 info uninstall html5@0.3.14 +5112 info uninstall encoding@0.1.7 +5113 info uninstall ws@0.4.31 +5114 info uninstall q@1.0.0 +5115 info uninstall dateformat@1.0.2-1.2.3 +5116 info uninstall lodash@0.9.2 +5117 info uninstall lodash@0.9.2 +5118 info uninstall iconv-lite@0.2.11 +5119 info uninstall underscore.string@2.2.1 +5120 info uninstall underscore.string@2.2.1 +5121 info uninstall js-yaml@2.0.5 +5122 info uninstall jsdom@0.8.11 +5123 info uninstall glob@3.1.21 +5124 info uninstall depd@0.4.5 +5125 verbose tar unpack /root/.npm/depd/0.4.5/package.tgz +5126 silly lockFile 27a0ad85-e-modules-send-node-modules-depd tar:///usr/lib/node_modules/express/node_modules/send/node_modules/depd +5127 verbose lock tar:///usr/lib/node_modules/express/node_modules/send/node_modules/depd /root/.npm/27a0ad85-e-modules-send-node-modules-depd.lock +5128 silly lockFile 335c56c0--root-npm-depd-0-4-5-package-tgz tar:///root/.npm/depd/0.4.5/package.tgz +5129 verbose lock tar:///root/.npm/depd/0.4.5/package.tgz /root/.npm/335c56c0--root-npm-depd-0-4-5-package-tgz.lock +5130 info uninstall finalhandler@0.2.0 +5131 info uninstall minimatch@0.2.14 +5132 info uninstall minimatch@0.2.14 +5133 info uninstall async@0.1.22 +5134 info uninstall async@0.1.22 +5135 info uninstall async@0.1.22 +5136 verbose lib/node_modules/express/node_modules/debug/node_modules/ms unbuild +5137 verbose lib/node_modules/express/node_modules/send/node_modules/ms unbuild +5138 info uninstall underscore@1.6.0 +5139 info uninstall underscore@1.6.0 +5140 info uninstall underscore@1.6.0 +5141 info uninstall wrench@1.3.9 +5142 verbose tar unpack /root/.npm/mime/1.2.11/package.tgz +5143 silly lockFile 00bfa77e-e-modules-send-node-modules-mime tar:///usr/lib/node_modules/express/node_modules/send/node_modules/mime +5144 verbose lock tar:///usr/lib/node_modules/express/node_modules/send/node_modules/mime /root/.npm/00bfa77e-e-modules-send-node-modules-mime.lock +5145 silly lockFile ffda6ac1-root-npm-mime-1-2-11-package-tgz tar:///root/.npm/mime/1.2.11/package.tgz +5146 verbose lock tar:///root/.npm/mime/1.2.11/package.tgz /root/.npm/ffda6ac1-root-npm-mime-1-2-11-package-tgz.lock +5147 info uninstall request@2.34.0 +5148 verbose git rev-list -n1 73fd7202ac086c26f18c9d56f025b18b3c6f5383 73fd7202ac086c26f18c9d56f025b18b3c6f5383 +5149 verbose resolved git url git://github.com/michaelficarra/cscodegen.git#73fd7202ac086c26f18c9d56f025b18b3c6f5383 +5150 silly resolved [ { name: 'strip-json-comments', +5150 silly resolved version: '0.1.3', +5150 silly resolved description: 'Strip comments from JSON. Lets you use comments in your JSON files!', +5150 silly resolved keywords: +5150 silly resolved [ 'json', +5150 silly resolved 'strip', +5150 silly resolved 'remove', +5150 silly resolved 'delete', +5150 silly resolved 'trim', +5150 silly resolved 'comments', +5150 silly resolved 'multiline', +5150 silly resolved 'parse', +5150 silly resolved 'config', +5150 silly resolved 'configuration', +5150 silly resolved 'conf', +5150 silly resolved 'settings', +5150 silly resolved 'util', +5150 silly resolved 'env', +5150 silly resolved 'environment', +5150 silly resolved 'cli', +5150 silly resolved 'bin' ], +5150 silly resolved license: 'MIT', +5150 silly resolved author: +5150 silly resolved { name: 'Sindre Sorhus', +5150 silly resolved email: 'sindresorhus@gmail.com', +5150 silly resolved url: 'http://sindresorhus.com' }, +5150 silly resolved files: [ 'cli.js', 'strip-json-comments.js' ], +5150 silly resolved main: 'strip-json-comments', +5150 silly resolved bin: { 'strip-json-comments': 'cli.js' }, +5150 silly resolved repository: +5150 silly resolved { type: 'git', +5150 silly resolved url: 'git://github.com/sindresorhus/strip-json-comments' }, +5150 silly resolved scripts: { test: 'mocha' }, +5150 silly resolved devDependencies: { mocha: '*' }, +5150 silly resolved engines: { node: '>=0.8.0' }, +5150 silly resolved gitHead: 'cbd5aede7ccbe5d5a9065b1d47070fd99ad579af', +5150 silly resolved bugs: { url: 'https://github.com/sindresorhus/strip-json-comments/issues' }, +5150 silly resolved homepage: 'https://github.com/sindresorhus/strip-json-comments', +5150 silly resolved _id: 'strip-json-comments@0.1.3', +5150 silly resolved _shasum: '164c64e370a8a3cc00c9e01b539e569823f0ee54', +5150 silly resolved _from: 'strip-json-comments@0.1.3', +5150 silly resolved _npmVersion: '1.4.13', +5150 silly resolved _npmUser: { name: 'sindresorhus', email: 'sindresorhus@gmail.com' }, +5150 silly resolved maintainers: [ [Object] ], +5150 silly resolved dist: +5150 silly resolved { shasum: '164c64e370a8a3cc00c9e01b539e569823f0ee54', +5150 silly resolved tarball: 'http://registry.npmjs.org/strip-json-comments/-/strip-json-comments-0.1.3.tgz' }, +5150 silly resolved directories: {}, +5150 silly resolved _resolved: 'https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-0.1.3.tgz', +5150 silly resolved readme: 'ERROR: No README data found!' } ] +5151 info install strip-json-comments@0.1.3 into /usr/lib/node_modules/jsdoc +5152 info installOne strip-json-comments@0.1.3 +5153 info uninstall commander@2.2.0 +5154 info uninstall glob@4.0.4 +5155 info uninstall drawille@0.1.1 +5156 info uninstall graceful-fs@2.0.3 +5157 info uninstall q@0.9.7 +5158 info uninstall http-proxy@0.10.4 +5159 info uninstall socket.io@0.9.17 +5160 info uninstall minimist@0.0.10 +5161 info uninstall minimist@0.0.10 +5162 info uninstall lru-cache@2.2.4 +5163 info uninstall connect@2.12.0 +5164 info uninstall recursive-readdir@0.0.2 +5165 info uninstall semver@1.1.4 +5166 info uninstall minimatch@0.3.0 +5167 info uninstall escodegen@1.3.3 +5168 info retry fetch attempt 1 at 15:14:39 +5169 verbose fetch to= /tmp/npm-17670-yMiqFMg9/registry.npmjs.org/ipaddr.js/-/ipaddr.js-0.1.3.tgz +5170 info uninstall minimatch@0.4.0 +5171 info uninstall resolve@0.7.4 +5172 info uninstall esprima@1.0.4 +5173 info uninstall async@0.2.10 +5174 info uninstall underscore@1.4.4 +5175 info uninstall mkdirp@0.3.5 +5176 info uninstall escodegen@1.1.0 +5177 info uninstall istanbul@0.2.16 +5178 info uninstall coffee-script@1.3.3 +5179 info uninstall source-map@0.1.11 +5180 info uninstall escodegen@0.0.28 +5181 info uninstall esmangle@0.0.17 +5182 info uninstall path-to-regexp@0.1.3 +5183 info uninstall nopt@2.2.1 +5184 info uninstall deep-equal@0.0.0 +5185 info uninstall request@2.42.0 +5186 info uninstall charm@0.1.2 +5187 info uninstall traverse@0.5.2 +5188 info uninstall rework-custom-media@0.1.1 +5189 info uninstall uglify-js@1.1.1 +5190 info uninstall to-space-case@0.1.2 +5191 info uninstall stream-to-array@1.0.0 +5192 info uninstall rgb@0.0.1 +5193 info uninstall convert-source-map@0.3.5 +5194 info uninstall parse-import@0.1.3 +5195 info uninstall find-file@0.1.4 +5196 info uninstall balanced-match@0.0.0 +5197 info uninstall debug@0.7.4 +5198 verbose lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/coffee-script-redux/node_modules/nopt unbuild +5199 info preuninstall nopt@2.1.2 +5200 verbose lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/handlebars unbuild +5201 info preuninstall handlebars@1.3.0 +5202 verbose lib/node_modules/npm unbuild +5203 info preuninstall npm@1.4.28 +5204 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/karma-coffee-preprocessor/node_modules unbuild coffee-script@1.7.1 +5205 verbose /usr/lib/node_modules/karma-coffee-preprocessor/node_modules/.bin,[object Object] binRoot +5206 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/express-generator/node_modules unbuild commander@1.3.2 +5207 info postuninstall commander@1.3.2 +5208 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/express-generator/node_modules/mkdirp/node_modules unbuild minimist@0.0.8 +5209 info postuninstall minimist@0.0.8 +5210 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/mkdirp/node_modules unbuild minimist@0.0.8 +5211 info postuninstall minimist@0.0.8 +5212 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/karma-phantomjs-launcher/node_modules/phantomjs/node_modules/mkdirp/node_modules unbuild minimist@0.0.8 +5213 info postuninstall minimist@0.0.8 +5214 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules unbuild minimist@0.0.8 +5215 info postuninstall minimist@0.0.8 +5216 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/grunt-cli/node_modules/findup-sync/node_modules unbuild glob@3.2.11 +5217 info postuninstall glob@3.2.11 +5218 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/karma/node_modules unbuild glob@3.2.11 +5219 info postuninstall glob@3.2.11 +5220 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/grunt-cli/node_modules unbuild resolve@0.3.1 +5221 info postuninstall resolve@0.3.1 +5222 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/grunt-cli/node_modules unbuild nopt@1.0.10 +5223 verbose /usr/lib/node_modules/grunt-cli/node_modules/.bin,[object Object] binRoot +5224 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/grunt/node_modules unbuild nopt@1.0.10 +5225 verbose /usr/lib/node_modules/grunt/node_modules/.bin,[object Object] binRoot +5226 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/zombie/node_modules unbuild eventsource@0.0.10 +5227 info postuninstall eventsource@0.0.10 +5228 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/zombie/node_modules unbuild html5@0.3.14 +5229 info postuninstall html5@0.3.14 +5230 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/zombie/node_modules unbuild encoding@0.1.7 +5231 info postuninstall encoding@0.1.7 +5232 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/zombie/node_modules unbuild ws@0.4.31 +5233 verbose /usr/lib/node_modules/zombie/node_modules/.bin,[object Object] binRoot +5234 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/zombie/node_modules unbuild q@1.0.0 +5235 info postuninstall q@1.0.0 +5236 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/grunt/node_modules unbuild dateformat@1.0.2-1.2.3 +5237 info postuninstall dateformat@1.0.2-1.2.3 +5238 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/grunt/node_modules unbuild lodash@0.9.2 +5239 info postuninstall lodash@0.9.2 +5240 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/grunt/node_modules/grunt-legacy-util/node_modules unbuild lodash@0.9.2 +5241 info postuninstall lodash@0.9.2 +5242 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/grunt/node_modules unbuild iconv-lite@0.2.11 +5243 info postuninstall iconv-lite@0.2.11 +5244 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/grunt/node_modules unbuild underscore.string@2.2.1 +5245 info postuninstall underscore.string@2.2.1 +5246 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/grunt/node_modules/grunt-legacy-util/node_modules unbuild underscore.string@2.2.1 +5247 info postuninstall underscore.string@2.2.1 +5248 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/grunt/node_modules unbuild js-yaml@2.0.5 +5249 verbose /usr/lib/node_modules/grunt/node_modules/.bin,[object Object] binRoot +5250 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/zombie/node_modules unbuild jsdom@0.8.11 +5251 info postuninstall jsdom@0.8.11 +5252 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/grunt/node_modules unbuild glob@3.1.21 +5253 info postuninstall glob@3.1.21 +5254 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/express/node_modules unbuild depd@0.4.5 +5255 info postuninstall depd@0.4.5 +5256 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/express/node_modules unbuild finalhandler@0.2.0 +5257 info postuninstall finalhandler@0.2.0 +5258 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/grunt/node_modules unbuild minimatch@0.2.14 +5259 info postuninstall minimatch@0.2.14 +5260 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/karma/node_modules unbuild minimatch@0.2.14 +5261 info postuninstall minimatch@0.2.14 +5262 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/grunt/node_modules unbuild async@0.1.22 +5263 info postuninstall async@0.1.22 +5264 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/grunt/node_modules/grunt-legacy-util/node_modules unbuild async@0.1.22 +5265 info postuninstall async@0.1.22 +5266 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/jsdoc/node_modules unbuild async@0.1.22 +5267 info postuninstall async@0.1.22 +5268 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/jsdoc/node_modules unbuild underscore@1.6.0 +5269 info postuninstall underscore@1.6.0 +5270 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/jsdoc/node_modules/requizzle/node_modules unbuild underscore@1.6.0 +5271 info postuninstall underscore@1.6.0 +5272 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/jsdoc/node_modules/catharsis/node_modules/underscore-contrib/node_modules unbuild underscore@1.6.0 +5273 info postuninstall underscore@1.6.0 +5274 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/jsdoc/node_modules unbuild wrench@1.3.9 +5275 info postuninstall wrench@1.3.9 +5276 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/zombie/node_modules unbuild request@2.34.0 +5277 info postuninstall request@2.34.0 +5278 verbose tar unpack /root/.npm/mime-types/2.0.1/package.tgz +5279 silly lockFile db981b20--accepts-node-modules-mime-types tar:///usr/lib/node_modules/express/node_modules/accepts/node_modules/mime-types +5280 verbose lock tar:///usr/lib/node_modules/express/node_modules/accepts/node_modules/mime-types /root/.npm/db981b20--accepts-node-modules-mime-types.lock +5281 silly lockFile a6ca3f36-npm-mime-types-2-0-1-package-tgz tar:///root/.npm/mime-types/2.0.1/package.tgz +5282 verbose lock tar:///root/.npm/mime-types/2.0.1/package.tgz /root/.npm/a6ca3f36-npm-mime-types-2-0-1-package-tgz.lock +5283 verbose tar unpack /root/.npm/mime-types/2.0.1/package.tgz +5284 silly lockFile a7547f95--type-is-node-modules-mime-types tar:///usr/lib/node_modules/express/node_modules/type-is/node_modules/mime-types +5285 verbose lock tar:///usr/lib/node_modules/express/node_modules/type-is/node_modules/mime-types /root/.npm/a7547f95--type-is-node-modules-mime-types.lock +5286 silly lockFile a6ca3f36-npm-mime-types-2-0-1-package-tgz tar:///root/.npm/mime-types/2.0.1/package.tgz +5287 verbose lock tar:///root/.npm/mime-types/2.0.1/package.tgz /root/.npm/a6ca3f36-npm-mime-types-2-0-1-package-tgz.lock +5288 verbose lib/node_modules/jsdoc/node_modules/strip-json-comments unbuild +5289 info preuninstall strip-json-comments@0.1.3 +5290 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/vtop/node_modules unbuild commander@2.2.0 +5291 info postuninstall commander@2.2.0 +5292 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/vtop/node_modules unbuild glob@4.0.4 +5293 info postuninstall glob@4.0.4 +5294 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/vtop/node_modules unbuild drawille@0.1.1 +5295 info postuninstall drawille@0.1.1 +5296 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/karma/node_modules unbuild graceful-fs@2.0.3 +5297 info postuninstall graceful-fs@2.0.3 +5298 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/karma/node_modules unbuild q@0.9.7 +5299 info postuninstall q@0.9.7 +5300 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/karma/node_modules unbuild http-proxy@0.10.4 +5301 verbose /usr/lib/node_modules/karma/node_modules/.bin,[object Object] binRoot +5302 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/karma/node_modules unbuild socket.io@0.9.17 +5303 info postuninstall socket.io@0.9.17 +5304 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/karma/node_modules/optimist/node_modules unbuild minimist@0.0.10 +5305 info postuninstall minimist@0.0.10 +5306 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/optimist/node_modules unbuild minimist@0.0.10 +5307 info postuninstall minimist@0.0.10 +5308 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/karma/node_modules/useragent/node_modules unbuild lru-cache@2.2.4 +5309 info postuninstall lru-cache@2.2.4 +5310 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/karma/node_modules unbuild connect@2.12.0 +5311 info postuninstall connect@2.12.0 +5312 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/karma/node_modules/chokidar/node_modules unbuild recursive-readdir@0.0.2 +5313 info postuninstall recursive-readdir@0.0.2 +5314 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/karma/node_modules/log4js/node_modules unbuild semver@1.1.4 +5315 verbose /usr/lib/node_modules/karma/node_modules/log4js/node_modules/.bin,[object Object] binRoot +5316 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/karma-coverage/node_modules unbuild minimatch@0.3.0 +5317 info postuninstall minimatch@0.3.0 +5318 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules unbuild escodegen@1.3.3 +5319 verbose /usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/.bin,[object Object] binRoot +5320 http GET https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-0.1.3.tgz +5321 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/fileset/node_modules unbuild minimatch@0.4.0 +5322 info postuninstall minimatch@0.4.0 +5323 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules unbuild resolve@0.7.4 +5324 info postuninstall resolve@0.7.4 +5325 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/js-yaml/node_modules unbuild esprima@1.0.4 +5326 verbose /usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/js-yaml/node_modules/.bin,[object Object] binRoot +5327 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/karma/node_modules/log4js/node_modules unbuild async@0.2.10 +5328 info postuninstall async@0.2.10 +5329 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/js-yaml/node_modules/argparse/node_modules unbuild underscore@1.4.4 +5330 info postuninstall underscore@1.4.4 +5331 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules unbuild mkdirp@0.3.5 +5332 info postuninstall mkdirp@0.3.5 +5333 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules unbuild escodegen@1.1.0 +5334 verbose /usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/.bin,[object Object] binRoot +5335 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules unbuild istanbul@0.2.16 +5336 verbose /usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/.bin,[object Object] binRoot +5337 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/grunt/node_modules unbuild coffee-script@1.3.3 +5338 verbose /usr/lib/node_modules/grunt/node_modules/.bin,[object Object] binRoot +5339 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/coffee-script-redux/node_modules unbuild source-map@0.1.11 +5340 info postuninstall source-map@0.1.11 +5341 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/coffee-script-redux/node_modules unbuild escodegen@0.0.28 +5342 verbose /usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/coffee-script-redux/node_modules/.bin,[object Object] binRoot +5343 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/coffee-script-redux/node_modules unbuild esmangle@0.0.17 +5344 verbose /usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/coffee-script-redux/node_modules/.bin,[object Object] binRoot +5345 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/express/node_modules unbuild path-to-regexp@0.1.3 +5346 info postuninstall path-to-regexp@0.1.3 +5347 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/nodeunit/node_modules/tap/node_modules unbuild nopt@2.2.1 +5348 verbose /usr/lib/node_modules/nodeunit/node_modules/tap/node_modules/.bin,[object Object] binRoot +5349 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/nodeunit/node_modules/tap/node_modules unbuild deep-equal@0.0.0 +5350 info postuninstall deep-equal@0.0.0 +5351 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/karma-phantomjs-launcher/node_modules/phantomjs/node_modules unbuild request@2.42.0 +5352 info postuninstall request@2.42.0 +5353 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules unbuild charm@0.1.2 +5354 info postuninstall charm@0.1.2 +5355 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules unbuild traverse@0.5.2 +5356 info postuninstall traverse@0.5.2 +5357 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/myth/node_modules unbuild rework-custom-media@0.1.1 +5358 info postuninstall rework-custom-media@0.1.1 +5359 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules unbuild uglify-js@1.1.1 +5360 verbose /usr/lib/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/.bin,[object Object] binRoot +5361 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/myth/node_modules/to-slug-case/node_modules unbuild to-space-case@0.1.2 +5362 info postuninstall to-space-case@0.1.2 +5363 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/myth/node_modules/read-file-stdin/node_modules unbuild stream-to-array@1.0.0 +5364 info postuninstall stream-to-array@1.0.0 +5365 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/myth/node_modules/rework-hex-alpha/node_modules unbuild rgb@0.0.1 +5366 info postuninstall rgb@0.0.1 +5367 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/myth/node_modules/rework/node_modules unbuild convert-source-map@0.3.5 +5368 info postuninstall convert-source-map@0.3.5 +5369 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/myth/node_modules/rework-import/node_modules unbuild parse-import@0.1.3 +5370 info postuninstall parse-import@0.1.3 +5371 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/myth/node_modules/rework-import/node_modules unbuild find-file@0.1.4 +5372 info postuninstall find-file@0.1.4 +5373 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/myth/node_modules/rework-color-function/node_modules unbuild balanced-match@0.0.0 +5374 info postuninstall balanced-match@0.0.0 +5375 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/myth/node_modules/rework-color-function/node_modules/css-color-function/node_modules unbuild debug@0.7.4 +5376 info postuninstall debug@0.7.4 +5377 info uninstall nopt@2.1.2 +5378 info uninstall handlebars@1.3.0 +5379 silly resolved [ { name: 'semver', +5379 silly resolved version: '4.0.0', +5379 silly resolved description: 'The semantic version parser used by npm.', +5379 silly resolved main: 'semver.js', +5379 silly resolved browser: 'semver.browser.js', +5379 silly resolved min: 'semver.min.js', +5379 silly resolved scripts: { test: 'tap test/*.js', prepublish: 'make' }, +5379 silly resolved devDependencies: { tap: '0.x >=0.0.4', 'uglify-js': '~2.3.6' }, +5379 silly resolved license: 'BSD', +5379 silly resolved repository: { type: 'git', url: 'git://github.com/isaacs/node-semver.git' }, +5379 silly resolved bin: { semver: './bin/semver' }, +5379 silly resolved gitHead: 'f71a46b52f5d413aff1cb3afa7d2f940b23ab1a0', +5379 silly resolved bugs: { url: 'https://github.com/isaacs/node-semver/issues' }, +5379 silly resolved homepage: 'https://github.com/isaacs/node-semver', +5379 silly resolved _id: 'semver@4.0.0', +5379 silly resolved _shasum: '7be868416a5e669923a8e3af8bafa5faf62a151a', +5379 silly resolved _from: 'semver@4.0.0', +5379 silly resolved _npmVersion: '2.0.0-beta.3', +5379 silly resolved _npmUser: { name: 'isaacs', email: 'i@izs.me' }, +5379 silly resolved maintainers: [ [Object] ], +5379 silly resolved dist: +5379 silly resolved { shasum: '7be868416a5e669923a8e3af8bafa5faf62a151a', +5379 silly resolved tarball: 'http://registry.npmjs.org/semver/-/semver-4.0.0.tgz' }, +5379 silly resolved directories: {}, +5379 silly resolved _resolved: 'https://registry.npmjs.org/semver/-/semver-4.0.0.tgz', +5379 silly resolved readme: 'ERROR: No README data found!' } ] +5380 info install semver@4.0.0 into /usr/lib/node_modules/karma-phantomjs-launcher/node_modules/phantomjs/node_modules/npmconf +5381 info installOne semver@4.0.0 +5382 info uninstall npm@1.4.28 +5383 verbose tar unpack /root/.npm/ms/0.6.2/package.tgz +5384 silly lockFile a2190e2d-de-modules-debug-node-modules-ms tar:///usr/lib/node_modules/express/node_modules/debug/node_modules/ms +5385 verbose lock tar:///usr/lib/node_modules/express/node_modules/debug/node_modules/ms /root/.npm/a2190e2d-de-modules-debug-node-modules-ms.lock +5386 silly lockFile d1da68ba-ar-root-npm-ms-0-6-2-package-tgz tar:///root/.npm/ms/0.6.2/package.tgz +5387 verbose lock tar:///root/.npm/ms/0.6.2/package.tgz /root/.npm/d1da68ba-ar-root-npm-ms-0-6-2-package-tgz.lock +5388 verbose tar unpack /root/.npm/ms/0.6.2/package.tgz +5389 silly lockFile 2d0ff483-ode-modules-send-node-modules-ms tar:///usr/lib/node_modules/express/node_modules/send/node_modules/ms +5390 verbose lock tar:///usr/lib/node_modules/express/node_modules/send/node_modules/ms /root/.npm/2d0ff483-ode-modules-send-node-modules-ms.lock +5391 silly lockFile d1da68ba-ar-root-npm-ms-0-6-2-package-tgz tar:///root/.npm/ms/0.6.2/package.tgz +5392 verbose lock tar:///root/.npm/ms/0.6.2/package.tgz /root/.npm/d1da68ba-ar-root-npm-ms-0-6-2-package-tgz.lock +5393 silly gunzTarPerm modes [ '755', '644' ] +5394 info postuninstall coffee-script@1.7.1 +5395 info postuninstall nopt@1.0.10 +5396 info postuninstall nopt@1.0.10 +5397 info postuninstall ws@0.4.31 +5398 info postuninstall js-yaml@2.0.5 +5399 info uninstall strip-json-comments@0.1.3 +5400 info postuninstall http-proxy@0.10.4 +5401 info postuninstall semver@1.1.4 +5402 info postuninstall escodegen@1.3.3 +5403 info postuninstall esprima@1.0.4 +5404 info postuninstall escodegen@1.1.0 +5405 info postuninstall istanbul@0.2.16 +5406 info postuninstall coffee-script@1.3.3 +5407 info postuninstall escodegen@0.0.28 +5408 info postuninstall esmangle@0.0.17 +5409 info postuninstall nopt@2.2.1 +5410 info postuninstall uglify-js@1.1.1 +5411 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/coffee-script-redux/node_modules unbuild nopt@2.1.2 +5412 verbose /usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/coffee-script-redux/node_modules/.bin,[object Object] binRoot +5413 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules unbuild handlebars@1.3.0 +5414 verbose /usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/.bin,[object Object] binRoot +5415 verbose tar unpack /tmp/npm-17670-yMiqFMg9/github.com/hegemonic/taffydb/tarball/master +5416 silly lockFile e0ffc318-ic-taffydb-tarball-master-unpack tar:///tmp/npm-17670-yMiqFMg9/github.com/hegemonic/taffydb/tarball/master-unpack +5417 verbose lock tar:///tmp/npm-17670-yMiqFMg9/github.com/hegemonic/taffydb/tarball/master-unpack /root/.npm/e0ffc318-ic-taffydb-tarball-master-unpack.lock +5418 silly lockFile 10e5e6ab-hegemonic-taffydb-tarball-master tar:///tmp/npm-17670-yMiqFMg9/github.com/hegemonic/taffydb/tarball/master +5419 verbose lock tar:///tmp/npm-17670-yMiqFMg9/github.com/hegemonic/taffydb/tarball/master /root/.npm/10e5e6ab-hegemonic-taffydb-tarball-master.lock +5420 verbose lib/node_modules/karma-phantomjs-launcher/node_modules/phantomjs/node_modules/npmconf/node_modules/semver unbuild +5421 info preuninstall semver@4.0.0 +5422 verbose true,/usr/lib/node_modules,/usr/lib/node_modules unbuild npm@1.4.28 +5423 verbose /usr/bin,[object Object] binRoot +5424 silly gunzTarPerm modes [ '755', '644' ] +5425 silly gunzTarPerm modes [ '755', '644' ] +5426 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/jsdoc/node_modules unbuild strip-json-comments@0.1.3 +5427 verbose /usr/lib/node_modules/jsdoc/node_modules/.bin,[object Object] binRoot +5428 info postuninstall nopt@2.1.2 +5429 info postuninstall handlebars@1.3.0 +5430 info uninstall semver@4.0.0 +5431 verbose git rev-list -n1 7dcdf9fa3f8956610fd6f69f72c67bace2de7138 7dcdf9fa3f8956610fd6f69f72c67bace2de7138 +5432 verbose resolved git url git+https://github.com/pipobscure/fsevents#7dcdf9fa3f8956610fd6f69f72c67bace2de7138 +5433 info postuninstall npm@1.4.28 +5434 http 200 https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-0.1.3.tgz +5435 silly gunzTarPerm extractEntry package.json +5436 info postuninstall strip-json-comments@0.1.3 +5437 silly resolved [ { name: 'destroy', +5437 silly resolved description: 'destroy a stream if possible', +5437 silly resolved version: '1.0.3', +5437 silly resolved author: +5437 silly resolved { name: 'Jonathan Ong', +5437 silly resolved email: 'me@jongleberry.com', +5437 silly resolved url: 'http://jongleberry.com' }, +5437 silly resolved contributors: [ [Object] ], +5437 silly resolved license: 'MIT', +5437 silly resolved repository: { type: 'git', url: 'https://github.com/stream-utils/destroy' }, +5437 silly resolved devDependencies: { istanbul: '0', mocha: '1' }, +5437 silly resolved scripts: +5437 silly resolved { test: 'mocha --reporter spec', +5437 silly resolved 'test-cov': 'istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot', +5437 silly resolved 'test-travis': 'istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter dot' }, +5437 silly resolved files: [ 'index.js' ], +5437 silly resolved keywords: [ 'stream', 'streams', 'destroy', 'cleanup', 'leak', 'fd' ], +5437 silly resolved gitHead: '50af95ece4a70202f9301bc3edc8f9fdbbad0f26', +5437 silly resolved bugs: { url: 'https://github.com/stream-utils/destroy/issues' }, +5437 silly resolved homepage: 'https://github.com/stream-utils/destroy', +5437 silly resolved _id: 'destroy@1.0.3', +5437 silly resolved _shasum: 'b433b4724e71fd8551d9885174851c5fc377e2c9', +5437 silly resolved _from: 'destroy@1.0.3', +5437 silly resolved _npmVersion: '1.4.21', +5437 silly resolved _npmUser: { name: 'jongleberry', email: 'jonathanrichardong@gmail.com' }, +5437 silly resolved maintainers: [ [Object] ], +5437 silly resolved dist: +5437 silly resolved { shasum: 'b433b4724e71fd8551d9885174851c5fc377e2c9', +5437 silly resolved tarball: 'http://registry.npmjs.org/destroy/-/destroy-1.0.3.tgz' }, +5437 silly resolved directories: {}, +5437 silly resolved _resolved: 'https://registry.npmjs.org/destroy/-/destroy-1.0.3.tgz', +5437 silly resolved readme: 'ERROR: No README data found!' } ] +5438 info install destroy@1.0.3 into /usr/lib/node_modules/express/node_modules/send +5439 info installOne destroy@1.0.3 +5440 silly gunzTarPerm modes [ '755', '644' ] +5441 verbose tar unpack /root/.npm/lodash/0.9.2/package.tgz +5442 silly lockFile 3a8367c7-odules-grunt-node-modules-lodash tar:///usr/lib/node_modules/grunt/node_modules/lodash +5443 verbose lock tar:///usr/lib/node_modules/grunt/node_modules/lodash /root/.npm/3a8367c7-odules-grunt-node-modules-lodash.lock +5444 silly lockFile 6ad06116-oot-npm-lodash-0-9-2-package-tgz tar:///root/.npm/lodash/0.9.2/package.tgz +5445 verbose lock tar:///root/.npm/lodash/0.9.2/package.tgz /root/.npm/6ad06116-oot-npm-lodash-0-9-2-package-tgz.lock +5446 verbose tar unpack /root/.npm/lodash/0.9.2/package.tgz +5447 silly lockFile c80cc77b--legacy-util-node-modules-lodash tar:///usr/lib/node_modules/grunt/node_modules/grunt-legacy-util/node_modules/lodash +5448 verbose lock tar:///usr/lib/node_modules/grunt/node_modules/grunt-legacy-util/node_modules/lodash /root/.npm/c80cc77b--legacy-util-node-modules-lodash.lock +5449 silly lockFile 6ad06116-oot-npm-lodash-0-9-2-package-tgz tar:///root/.npm/lodash/0.9.2/package.tgz +5450 verbose lock tar:///root/.npm/lodash/0.9.2/package.tgz /root/.npm/6ad06116-oot-npm-lodash-0-9-2-package-tgz.lock +5451 verbose false,/usr/lib/node_modules,/usr/lib/node_modules/karma-phantomjs-launcher/node_modules/phantomjs/node_modules/npmconf/node_modules unbuild semver@4.0.0 +5452 verbose /usr/lib/node_modules/karma-phantomjs-launcher/node_modules/phantomjs/node_modules/npmconf/node_modules/.bin,[object Object] binRoot +5453 verbose tar unpack /root/.npm/finalhandler/0.2.0/package.tgz +5454 silly lockFile d5727678-xpress-node-modules-finalhandler tar:///usr/lib/node_modules/express/node_modules/finalhandler +5455 verbose lock tar:///usr/lib/node_modules/express/node_modules/finalhandler /root/.npm/d5727678-xpress-node-modules-finalhandler.lock +5456 silly lockFile 58454295-m-finalhandler-0-2-0-package-tgz tar:///root/.npm/finalhandler/0.2.0/package.tgz +5457 verbose lock tar:///root/.npm/finalhandler/0.2.0/package.tgz /root/.npm/58454295-m-finalhandler-0-2-0-package-tgz.lock +5458 verbose tar unpack /root/.npm/underscore/1.6.0/package.tgz +5459 silly lockFile 698dfb1c-es-jsdoc-node-modules-underscore tar:///usr/lib/node_modules/jsdoc/node_modules/underscore +5460 verbose lock tar:///usr/lib/node_modules/jsdoc/node_modules/underscore /root/.npm/698dfb1c-es-jsdoc-node-modules-underscore.lock +5461 silly lockFile b3ebc02a-npm-underscore-1-6-0-package-tgz tar:///root/.npm/underscore/1.6.0/package.tgz +5462 verbose lock tar:///root/.npm/underscore/1.6.0/package.tgz /root/.npm/b3ebc02a-npm-underscore-1-6-0-package-tgz.lock +5463 verbose tar unpack /root/.npm/underscore/1.6.0/package.tgz +5464 silly lockFile 37bac74f-equizzle-node-modules-underscore tar:///usr/lib/node_modules/jsdoc/node_modules/requizzle/node_modules/underscore +5465 verbose lock tar:///usr/lib/node_modules/jsdoc/node_modules/requizzle/node_modules/underscore /root/.npm/37bac74f-equizzle-node-modules-underscore.lock +5466 silly lockFile b3ebc02a-npm-underscore-1-6-0-package-tgz tar:///root/.npm/underscore/1.6.0/package.tgz +5467 verbose lock tar:///root/.npm/underscore/1.6.0/package.tgz /root/.npm/b3ebc02a-npm-underscore-1-6-0-package-tgz.lock +5468 verbose tar unpack /root/.npm/underscore/1.6.0/package.tgz +5469 silly lockFile 0154df69--contrib-node-modules-underscore tar:///usr/lib/node_modules/jsdoc/node_modules/catharsis/node_modules/underscore-contrib/node_modules/underscore +5470 verbose lock tar:///usr/lib/node_modules/jsdoc/node_modules/catharsis/node_modules/underscore-contrib/node_modules/underscore /root/.npm/0154df69--contrib-node-modules-underscore.lock +5471 silly lockFile b3ebc02a-npm-underscore-1-6-0-package-tgz tar:///root/.npm/underscore/1.6.0/package.tgz +5472 verbose lock tar:///root/.npm/underscore/1.6.0/package.tgz /root/.npm/b3ebc02a-npm-underscore-1-6-0-package-tgz.lock +5473 silly gunzTarPerm modes [ '755', '644' ] +5474 verbose tar unpack /root/.npm/commander/2.2.0/package.tgz +5475 silly lockFile 7fa25a54-ules-vtop-node-modules-commander tar:///usr/lib/node_modules/vtop/node_modules/commander +5476 verbose lock tar:///usr/lib/node_modules/vtop/node_modules/commander /root/.npm/7fa25a54-ules-vtop-node-modules-commander.lock +5477 silly lockFile 77e52cd9--npm-commander-2-2-0-package-tgz tar:///root/.npm/commander/2.2.0/package.tgz +5478 verbose lock tar:///root/.npm/commander/2.2.0/package.tgz /root/.npm/77e52cd9--npm-commander-2-2-0-package-tgz.lock +5479 verbose tar unpack /root/.npm/drawille/0.1.1/package.tgz +5480 silly lockFile 948eff17-dules-vtop-node-modules-drawille tar:///usr/lib/node_modules/vtop/node_modules/drawille +5481 verbose lock tar:///usr/lib/node_modules/vtop/node_modules/drawille /root/.npm/948eff17-dules-vtop-node-modules-drawille.lock +5482 silly lockFile 19e887d2-t-npm-drawille-0-1-1-package-tgz tar:///root/.npm/drawille/0.1.1/package.tgz +5483 verbose lock tar:///root/.npm/drawille/0.1.1/package.tgz /root/.npm/19e887d2-t-npm-drawille-0-1-1-package-tgz.lock +5484 verbose tar unpack /root/.npm/underscore/1.4.4/package.tgz +5485 silly lockFile b279ef8d-argparse-node-modules-underscore tar:///usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/js-yaml/node_modules/argparse/node_modules/underscore +5486 verbose lock tar:///usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/js-yaml/node_modules/argparse/node_modules/underscore /root/.npm/b279ef8d-argparse-node-modules-underscore.lock +5487 silly lockFile cd8ee710-npm-underscore-1-4-4-package-tgz tar:///root/.npm/underscore/1.4.4/package.tgz +5488 verbose lock tar:///root/.npm/underscore/1.4.4/package.tgz /root/.npm/cd8ee710-npm-underscore-1-4-4-package-tgz.lock +5489 verbose tar unpack /root/.npm/path-to-regexp/0.1.3/package.tgz +5490 silly lockFile 54c4d449-ress-node-modules-path-to-regexp tar:///usr/lib/node_modules/express/node_modules/path-to-regexp +5491 verbose lock tar:///usr/lib/node_modules/express/node_modules/path-to-regexp /root/.npm/54c4d449-ress-node-modules-path-to-regexp.lock +5492 silly lockFile 5cb9e196-path-to-regexp-0-1-3-package-tgz tar:///root/.npm/path-to-regexp/0.1.3/package.tgz +5493 verbose lock tar:///root/.npm/path-to-regexp/0.1.3/package.tgz /root/.npm/5cb9e196-path-to-regexp-0-1-3-package-tgz.lock +5494 verbose tar unpack /root/.npm/rework-custom-media/0.1.1/package.tgz +5495 silly lockFile 10336776-node-modules-rework-custom-media tar:///usr/lib/node_modules/myth/node_modules/rework-custom-media +5496 verbose lock tar:///usr/lib/node_modules/myth/node_modules/rework-custom-media /root/.npm/10336776-node-modules-rework-custom-media.lock +5497 silly lockFile a85bd7c3-k-custom-media-0-1-1-package-tgz tar:///root/.npm/rework-custom-media/0.1.1/package.tgz +5498 verbose lock tar:///root/.npm/rework-custom-media/0.1.1/package.tgz /root/.npm/a85bd7c3-k-custom-media-0-1-1-package-tgz.lock +5499 verbose tar unpack /root/.npm/stream-to-array/1.0.0/package.tgz +5500 silly lockFile 22479c7d-din-node-modules-stream-to-array tar:///usr/lib/node_modules/myth/node_modules/read-file-stdin/node_modules/stream-to-array +5501 verbose lock tar:///usr/lib/node_modules/myth/node_modules/read-file-stdin/node_modules/stream-to-array /root/.npm/22479c7d-din-node-modules-stream-to-array.lock +5502 silly lockFile 4987667a-tream-to-array-1-0-0-package-tgz tar:///root/.npm/stream-to-array/1.0.0/package.tgz +5503 verbose lock tar:///root/.npm/stream-to-array/1.0.0/package.tgz /root/.npm/4987667a-tream-to-array-1-0-0-package-tgz.lock +5504 verbose tar unpack /root/.npm/rgb/0.0.1/package.tgz +5505 silly lockFile ef5e660a-ework-hex-alpha-node-modules-rgb tar:///usr/lib/node_modules/myth/node_modules/rework-hex-alpha/node_modules/rgb +5506 verbose lock tar:///usr/lib/node_modules/myth/node_modules/rework-hex-alpha/node_modules/rgb /root/.npm/ef5e660a-ework-hex-alpha-node-modules-rgb.lock +5507 silly lockFile 8685fcd0-r-root-npm-rgb-0-0-1-package-tgz tar:///root/.npm/rgb/0.0.1/package.tgz +5508 verbose lock tar:///root/.npm/rgb/0.0.1/package.tgz /root/.npm/8685fcd0-r-root-npm-rgb-0-0-1-package-tgz.lock +5509 verbose tar unpack /root/.npm/parse-import/0.1.3/package.tgz +5510 silly lockFile 51273c00-import-node-modules-parse-import tar:///usr/lib/node_modules/myth/node_modules/rework-import/node_modules/parse-import +5511 verbose lock tar:///usr/lib/node_modules/myth/node_modules/rework-import/node_modules/parse-import /root/.npm/51273c00-import-node-modules-parse-import.lock +5512 silly lockFile ed0f46ad-m-parse-import-0-1-3-package-tgz tar:///root/.npm/parse-import/0.1.3/package.tgz +5513 verbose lock tar:///root/.npm/parse-import/0.1.3/package.tgz /root/.npm/ed0f46ad-m-parse-import-0-1-3-package-tgz.lock +5514 verbose tar unpack /root/.npm/find-file/0.1.4/package.tgz +5515 silly lockFile d6436a24-rk-import-node-modules-find-file tar:///usr/lib/node_modules/myth/node_modules/rework-import/node_modules/find-file +5516 verbose lock tar:///usr/lib/node_modules/myth/node_modules/rework-import/node_modules/find-file /root/.npm/d6436a24-rk-import-node-modules-find-file.lock +5517 silly lockFile 25f6ee23--npm-find-file-0-1-4-package-tgz tar:///root/.npm/find-file/0.1.4/package.tgz +5518 verbose lock tar:///root/.npm/find-file/0.1.4/package.tgz /root/.npm/25f6ee23--npm-find-file-0-1-4-package-tgz.lock +5519 verbose lib/node_modules/express/node_modules/send/node_modules/destroy unbuild +5520 silly gunzTarPerm extractEntry package.json +5521 silly gunzTarPerm modified mode [ 'package.json', 438, 420 ] +5522 info postuninstall semver@4.0.0 +5523 silly gunzTarPerm extractEntry package.json +5524 verbose tar unpack /tmp/npm-17670-yMiqFMg9/1411067673728-0.826810498489067/tmp.tgz +5525 silly lockFile 3c3481d6-0-826810498489067-tmp-tgz-unpack tar:///tmp/npm-17670-yMiqFMg9/1411067673728-0.826810498489067/tmp.tgz-unpack +5526 verbose lock tar:///tmp/npm-17670-yMiqFMg9/1411067673728-0.826810498489067/tmp.tgz-unpack /root/.npm/3c3481d6-0-826810498489067-tmp-tgz-unpack.lock +5527 silly lockFile 61874204-673728-0-826810498489067-tmp-tgz tar:///tmp/npm-17670-yMiqFMg9/1411067673728-0.826810498489067/tmp.tgz +5528 verbose lock tar:///tmp/npm-17670-yMiqFMg9/1411067673728-0.826810498489067/tmp.tgz /root/.npm/61874204-673728-0-826810498489067-tmp-tgz.lock +5529 silly gunzTarPerm modes [ '755', '644' ] +5530 silly gunzTarPerm modes [ '755', '644' ] +5531 silly gunzTarPerm modes [ '755', '644' ] +5532 silly gunzTarPerm modes [ '755', '644' ] +5533 silly gunzTarPerm extractEntry README.md +5534 silly gunzTarPerm extractEntry LICENSE +5535 silly gunzTarPerm modes [ '755', '644' ] +5536 silly gunzTarPerm modes [ '755', '644' ] +5537 silly gunzTarPerm modes [ '755', '644' ] +5538 silly gunzTarPerm modes [ '755', '644' ] +5539 silly gunzTarPerm modes [ '755', '644' ] +5540 silly gunzTarPerm modes [ '755', '644' ] +5541 silly gunzTarPerm modes [ '755', '644' ] +5542 verbose tar unpack /root/.npm/destroy/1.0.3/package.tgz +5543 silly lockFile ad9b8352-odules-send-node-modules-destroy tar:///usr/lib/node_modules/express/node_modules/send/node_modules/destroy +5544 verbose lock tar:///usr/lib/node_modules/express/node_modules/send/node_modules/destroy /root/.npm/ad9b8352-odules-send-node-modules-destroy.lock +5545 silly lockFile 71736e82-ot-npm-destroy-1-0-3-package-tgz tar:///root/.npm/destroy/1.0.3/package.tgz +5546 verbose lock tar:///root/.npm/destroy/1.0.3/package.tgz /root/.npm/71736e82-ot-npm-destroy-1-0-3-package-tgz.lock +5547 verbose tar unpack /root/.npm/minimist/0.0.8/package.tgz +5548 silly lockFile 9d45a191-les-mkdirp-node-modules-minimist tar:///usr/lib/node_modules/express-generator/node_modules/mkdirp/node_modules/minimist +5549 verbose lock tar:///usr/lib/node_modules/express-generator/node_modules/mkdirp/node_modules/minimist /root/.npm/9d45a191-les-mkdirp-node-modules-minimist.lock +5550 silly lockFile 308650c5-t-npm-minimist-0-0-8-package-tgz tar:///root/.npm/minimist/0.0.8/package.tgz +5551 verbose lock tar:///root/.npm/minimist/0.0.8/package.tgz /root/.npm/308650c5-t-npm-minimist-0-0-8-package-tgz.lock +5552 verbose tar unpack /root/.npm/minimist/0.0.8/package.tgz +5553 silly lockFile 5c5924be-les-mkdirp-node-modules-minimist tar:///usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/mkdirp/node_modules/minimist +5554 verbose lock tar:///usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/mkdirp/node_modules/minimist /root/.npm/5c5924be-les-mkdirp-node-modules-minimist.lock +5555 silly lockFile 308650c5-t-npm-minimist-0-0-8-package-tgz tar:///root/.npm/minimist/0.0.8/package.tgz +5556 verbose lock tar:///root/.npm/minimist/0.0.8/package.tgz /root/.npm/308650c5-t-npm-minimist-0-0-8-package-tgz.lock +5557 verbose tar unpack /root/.npm/minimist/0.0.8/package.tgz +5558 silly lockFile 963a6745-les-mkdirp-node-modules-minimist tar:///usr/lib/node_modules/karma-phantomjs-launcher/node_modules/phantomjs/node_modules/mkdirp/node_modules/minimist +5559 verbose lock tar:///usr/lib/node_modules/karma-phantomjs-launcher/node_modules/phantomjs/node_modules/mkdirp/node_modules/minimist /root/.npm/963a6745-les-mkdirp-node-modules-minimist.lock +5560 silly lockFile 308650c5-t-npm-minimist-0-0-8-package-tgz tar:///root/.npm/minimist/0.0.8/package.tgz +5561 verbose lock tar:///root/.npm/minimist/0.0.8/package.tgz /root/.npm/308650c5-t-npm-minimist-0-0-8-package-tgz.lock +5562 verbose tar unpack /root/.npm/minimist/0.0.8/package.tgz +5563 silly lockFile a49ae451-les-mkdirp-node-modules-minimist tar:///usr/lib/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist +5564 verbose lock tar:///usr/lib/node_modules/nodeunit/node_modules/tap/node_modules/mkdirp/node_modules/minimist /root/.npm/a49ae451-les-mkdirp-node-modules-minimist.lock +5565 silly lockFile 308650c5-t-npm-minimist-0-0-8-package-tgz tar:///root/.npm/minimist/0.0.8/package.tgz +5566 verbose lock tar:///root/.npm/minimist/0.0.8/package.tgz /root/.npm/308650c5-t-npm-minimist-0-0-8-package-tgz.lock +5567 verbose tar unpack /root/.npm/glob/3.2.11/package.tgz +5568 silly lockFile 9c1285fe--modules-karma-node-modules-glob tar:///usr/lib/node_modules/karma/node_modules/glob +5569 verbose lock tar:///usr/lib/node_modules/karma/node_modules/glob /root/.npm/9c1285fe--modules-karma-node-modules-glob.lock +5570 silly lockFile 0cfbf35b-root-npm-glob-3-2-11-package-tgz tar:///root/.npm/glob/3.2.11/package.tgz +5571 verbose lock tar:///root/.npm/glob/3.2.11/package.tgz /root/.npm/0cfbf35b-root-npm-glob-3-2-11-package-tgz.lock +5572 verbose tar unpack /root/.npm/eventsource/0.0.10/package.tgz +5573 silly lockFile 6602a230--zombie-node-modules-eventsource tar:///usr/lib/node_modules/zombie/node_modules/eventsource +5574 verbose lock tar:///usr/lib/node_modules/zombie/node_modules/eventsource /root/.npm/6602a230--zombie-node-modules-eventsource.lock +5575 silly lockFile 0f41844e-m-eventsource-0-0-10-package-tgz tar:///root/.npm/eventsource/0.0.10/package.tgz +5576 verbose lock tar:///root/.npm/eventsource/0.0.10/package.tgz /root/.npm/0f41844e-m-eventsource-0-0-10-package-tgz.lock +5577 verbose tar unpack /root/.npm/q/1.0.0/package.tgz +5578 silly lockFile 774f3052-de-modules-zombie-node-modules-q tar:///usr/lib/node_modules/zombie/node_modules/q +5579 verbose lock tar:///usr/lib/node_modules/zombie/node_modules/q /root/.npm/774f3052-de-modules-zombie-node-modules-q.lock +5580 silly lockFile 0810a383-tar-root-npm-q-1-0-0-package-tgz tar:///root/.npm/q/1.0.0/package.tgz +5581 verbose lock tar:///root/.npm/q/1.0.0/package.tgz /root/.npm/0810a383-tar-root-npm-q-1-0-0-package-tgz.lock +5582 verbose tar unpack /root/.npm/dateformat/1.0.2-1.2.3/package.tgz +5583 silly lockFile 43e21967-es-grunt-node-modules-dateformat tar:///usr/lib/node_modules/grunt/node_modules/dateformat +5584 verbose lock tar:///usr/lib/node_modules/grunt/node_modules/dateformat /root/.npm/43e21967-es-grunt-node-modules-dateformat.lock +5585 silly lockFile 666e59b9-teformat-1-0-2-1-2-3-package-tgz tar:///root/.npm/dateformat/1.0.2-1.2.3/package.tgz +5586 verbose lock tar:///root/.npm/dateformat/1.0.2-1.2.3/package.tgz /root/.npm/666e59b9-teformat-1-0-2-1-2-3-package-tgz.lock +5587 verbose tar unpack /root/.npm/underscore.string/2.2.1/package.tgz +5588 silly lockFile 2b318e01-l-node-modules-underscore-string tar:///usr/lib/node_modules/grunt/node_modules/grunt-legacy-util/node_modules/underscore.string +5589 verbose lock tar:///usr/lib/node_modules/grunt/node_modules/grunt-legacy-util/node_modules/underscore.string /root/.npm/2b318e01-l-node-modules-underscore-string.lock +5590 silly lockFile 4365d842-erscore-string-2-2-1-package-tgz tar:///root/.npm/underscore.string/2.2.1/package.tgz +5591 verbose lock tar:///root/.npm/underscore.string/2.2.1/package.tgz /root/.npm/4365d842-erscore-string-2-2-1-package-tgz.lock +5592 verbose tar unpack /root/.npm/async/0.1.22/package.tgz +5593 silly lockFile eb5f4db5-modules-grunt-node-modules-async tar:///usr/lib/node_modules/grunt/node_modules/async +5594 verbose lock tar:///usr/lib/node_modules/grunt/node_modules/async /root/.npm/eb5f4db5-modules-grunt-node-modules-async.lock +5595 silly lockFile 24824174-oot-npm-async-0-1-22-package-tgz tar:///root/.npm/async/0.1.22/package.tgz +5596 verbose lock tar:///root/.npm/async/0.1.22/package.tgz /root/.npm/24824174-oot-npm-async-0-1-22-package-tgz.lock +5597 verbose tar unpack /root/.npm/async/0.1.22/package.tgz +5598 silly lockFile 984c476d-t-legacy-util-node-modules-async tar:///usr/lib/node_modules/grunt/node_modules/grunt-legacy-util/node_modules/async +5599 verbose lock tar:///usr/lib/node_modules/grunt/node_modules/grunt-legacy-util/node_modules/async /root/.npm/984c476d-t-legacy-util-node-modules-async.lock +5600 silly lockFile 24824174-oot-npm-async-0-1-22-package-tgz tar:///root/.npm/async/0.1.22/package.tgz +5601 verbose lock tar:///root/.npm/async/0.1.22/package.tgz /root/.npm/24824174-oot-npm-async-0-1-22-package-tgz.lock +5602 verbose tar unpack /root/.npm/async/0.1.22/package.tgz +5603 silly lockFile 12d628d4-modules-jsdoc-node-modules-async tar:///usr/lib/node_modules/jsdoc/node_modules/async +5604 verbose lock tar:///usr/lib/node_modules/jsdoc/node_modules/async /root/.npm/12d628d4-modules-jsdoc-node-modules-async.lock +5605 silly lockFile 24824174-oot-npm-async-0-1-22-package-tgz tar:///root/.npm/async/0.1.22/package.tgz +5606 verbose lock tar:///root/.npm/async/0.1.22/package.tgz /root/.npm/24824174-oot-npm-async-0-1-22-package-tgz.lock +5607 verbose tar unpack /root/.npm/graceful-fs/2.0.3/package.tgz +5608 silly lockFile bf772fe5-s-karma-node-modules-graceful-fs tar:///usr/lib/node_modules/karma/node_modules/graceful-fs +5609 verbose lock tar:///usr/lib/node_modules/karma/node_modules/graceful-fs /root/.npm/bf772fe5-s-karma-node-modules-graceful-fs.lock +5610 silly lockFile 2d5b23ec-pm-graceful-fs-2-0-3-package-tgz tar:///root/.npm/graceful-fs/2.0.3/package.tgz +5611 verbose lock tar:///root/.npm/graceful-fs/2.0.3/package.tgz /root/.npm/2d5b23ec-pm-graceful-fs-2-0-3-package-tgz.lock +5612 verbose tar unpack /root/.npm/q/0.9.7/package.tgz +5613 silly lockFile edfe5d8f-ode-modules-karma-node-modules-q tar:///usr/lib/node_modules/karma/node_modules/q +5614 verbose lock tar:///usr/lib/node_modules/karma/node_modules/q /root/.npm/edfe5d8f-ode-modules-karma-node-modules-q.lock +5615 silly lockFile 30b76a42-tar-root-npm-q-0-9-7-package-tgz tar:///root/.npm/q/0.9.7/package.tgz +5616 verbose lock tar:///root/.npm/q/0.9.7/package.tgz /root/.npm/30b76a42-tar-root-npm-q-0-9-7-package-tgz.lock +5617 verbose tar unpack /root/.npm/minimist/0.0.10/package.tgz +5618 silly lockFile 38c16e7b-s-optimist-node-modules-minimist tar:///usr/lib/node_modules/karma/node_modules/optimist/node_modules/minimist +5619 verbose lock tar:///usr/lib/node_modules/karma/node_modules/optimist/node_modules/minimist /root/.npm/38c16e7b-s-optimist-node-modules-minimist.lock +5620 silly lockFile f67d624c--npm-minimist-0-0-10-package-tgz tar:///root/.npm/minimist/0.0.10/package.tgz +5621 verbose lock tar:///root/.npm/minimist/0.0.10/package.tgz /root/.npm/f67d624c--npm-minimist-0-0-10-package-tgz.lock +5622 verbose tar unpack /root/.npm/minimist/0.0.10/package.tgz +5623 silly lockFile de41706c-s-optimist-node-modules-minimist tar:///usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/optimist/node_modules/minimist +5624 verbose lock tar:///usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/optimist/node_modules/minimist /root/.npm/de41706c-s-optimist-node-modules-minimist.lock +5625 silly lockFile f67d624c--npm-minimist-0-0-10-package-tgz tar:///root/.npm/minimist/0.0.10/package.tgz +5626 verbose lock tar:///root/.npm/minimist/0.0.10/package.tgz /root/.npm/f67d624c--npm-minimist-0-0-10-package-tgz.lock +5627 verbose tar unpack /root/.npm/lru-cache/2.2.4/package.tgz +5628 silly lockFile d49c7309-useragent-node-modules-lru-cache tar:///usr/lib/node_modules/karma/node_modules/useragent/node_modules/lru-cache +5629 verbose lock tar:///usr/lib/node_modules/karma/node_modules/useragent/node_modules/lru-cache /root/.npm/d49c7309-useragent-node-modules-lru-cache.lock +5630 silly lockFile 987dd4e5--npm-lru-cache-2-2-4-package-tgz tar:///root/.npm/lru-cache/2.2.4/package.tgz +5631 verbose lock tar:///root/.npm/lru-cache/2.2.4/package.tgz /root/.npm/987dd4e5--npm-lru-cache-2-2-4-package-tgz.lock +5632 verbose tar unpack /root/.npm/async/0.2.10/package.tgz +5633 silly lockFile 5245205f-odules-log4js-node-modules-async tar:///usr/lib/node_modules/karma/node_modules/log4js/node_modules/async +5634 verbose lock tar:///usr/lib/node_modules/karma/node_modules/log4js/node_modules/async /root/.npm/5245205f-odules-log4js-node-modules-async.lock +5635 silly lockFile ac49e666-oot-npm-async-0-2-10-package-tgz tar:///root/.npm/async/0.2.10/package.tgz +5636 verbose lock tar:///root/.npm/async/0.2.10/package.tgz /root/.npm/ac49e666-oot-npm-async-0-2-10-package-tgz.lock +5637 verbose tar unpack /root/.npm/mkdirp/0.3.5/package.tgz +5638 silly lockFile dc177a69-odules-ibrik-node-modules-mkdirp tar:///usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/mkdirp +5639 verbose lock tar:///usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/mkdirp /root/.npm/dc177a69-odules-ibrik-node-modules-mkdirp.lock +5640 silly lockFile 2b3d2d2d-oot-npm-mkdirp-0-3-5-package-tgz tar:///root/.npm/mkdirp/0.3.5/package.tgz +5641 verbose lock tar:///root/.npm/mkdirp/0.3.5/package.tgz /root/.npm/2b3d2d2d-oot-npm-mkdirp-0-3-5-package-tgz.lock +5642 verbose tar unpack /root/.npm/deep-equal/0.0.0/package.tgz +5643 silly lockFile 98eb404c-ules-tap-node-modules-deep-equal tar:///usr/lib/node_modules/nodeunit/node_modules/tap/node_modules/deep-equal +5644 verbose lock tar:///usr/lib/node_modules/nodeunit/node_modules/tap/node_modules/deep-equal /root/.npm/98eb404c-ules-tap-node-modules-deep-equal.lock +5645 silly lockFile af2f38f9-npm-deep-equal-0-0-0-package-tgz tar:///root/.npm/deep-equal/0.0.0/package.tgz +5646 verbose lock tar:///root/.npm/deep-equal/0.0.0/package.tgz /root/.npm/af2f38f9-npm-deep-equal-0-0-0-package-tgz.lock +5647 verbose tar unpack /root/.npm/charm/0.1.2/package.tgz +5648 silly lockFile 09c1b7ee-dules-difflet-node-modules-charm tar:///usr/lib/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm +5649 verbose lock tar:///usr/lib/node_modules/nodeunit/node_modules/tap/node_modules/difflet/node_modules/charm /root/.npm/09c1b7ee-dules-difflet-node-modules-charm.lock +5650 silly lockFile d51bf593-root-npm-charm-0-1-2-package-tgz tar:///root/.npm/charm/0.1.2/package.tgz +5651 verbose lock tar:///root/.npm/charm/0.1.2/package.tgz /root/.npm/d51bf593-root-npm-charm-0-1-2-package-tgz.lock +5652 verbose tar unpack /root/.npm/balanced-match/0.0.0/package.tgz +5653 silly lockFile 2ed8a8c4-tion-node-modules-balanced-match tar:///usr/lib/node_modules/myth/node_modules/rework-color-function/node_modules/balanced-match +5654 verbose lock tar:///usr/lib/node_modules/myth/node_modules/rework-color-function/node_modules/balanced-match /root/.npm/2ed8a8c4-tion-node-modules-balanced-match.lock +5655 silly lockFile 689ba264-balanced-match-0-0-0-package-tgz tar:///root/.npm/balanced-match/0.0.0/package.tgz +5656 verbose lock tar:///root/.npm/balanced-match/0.0.0/package.tgz /root/.npm/689ba264-balanced-match-0-0-0-package-tgz.lock +5657 verbose tar unpack /root/.npm/debug/0.7.4/package.tgz +5658 silly lockFile 933b5d48-olor-function-node-modules-debug tar:///usr/lib/node_modules/myth/node_modules/rework-color-function/node_modules/css-color-function/node_modules/debug +5659 verbose lock tar:///usr/lib/node_modules/myth/node_modules/rework-color-function/node_modules/css-color-function/node_modules/debug /root/.npm/933b5d48-olor-function-node-modules-debug.lock +5660 silly lockFile 3ec54546-root-npm-debug-0-7-4-package-tgz tar:///root/.npm/debug/0.7.4/package.tgz +5661 verbose lock tar:///root/.npm/debug/0.7.4/package.tgz /root/.npm/3ec54546-root-npm-debug-0-7-4-package-tgz.lock +5662 silly gunzTarPerm modes [ '755', '644' ] +5663 silly gunzTarPerm extractEntry README.md +5664 silly gunzTarPerm modified mode [ 'README.md', 438, 420 ] +5665 silly gunzTarPerm extractEntry LICENSE +5666 silly gunzTarPerm modified mode [ 'LICENSE', 438, 420 ] +5667 silly gunzTarPerm extractEntry package.json +5668 silly gunzTarPerm extractEntry .npmignore +5669 silly gunzTarPerm extractEntry README.md +5670 silly gunzTarPerm extractEntry package.json +5671 silly gunzTarPerm modified mode [ 'package.json', 438, 420 ] +5672 verbose tar unpack /root/.npm/strip-json-comments/0.1.3/package.tgz +5673 silly lockFile 921d82dc-node-modules-strip-json-comments tar:///usr/lib/node_modules/jsdoc/node_modules/strip-json-comments +5674 verbose lock tar:///usr/lib/node_modules/jsdoc/node_modules/strip-json-comments /root/.npm/921d82dc-node-modules-strip-json-comments.lock +5675 silly lockFile 84ffb389--json-comments-0-1-3-package-tgz tar:///root/.npm/strip-json-comments/0.1.3/package.tgz +5676 verbose lock tar:///root/.npm/strip-json-comments/0.1.3/package.tgz /root/.npm/84ffb389--json-comments-0-1-3-package-tgz.lock +5677 verbose tar unpack /root/.npm/semver/1.1.4/package.tgz +5678 silly lockFile 228511ea-dules-log4js-node-modules-semver tar:///usr/lib/node_modules/karma/node_modules/log4js/node_modules/semver +5679 verbose lock tar:///usr/lib/node_modules/karma/node_modules/log4js/node_modules/semver /root/.npm/228511ea-dules-log4js-node-modules-semver.lock +5680 silly lockFile d42a185e-oot-npm-semver-1-1-4-package-tgz tar:///root/.npm/semver/1.1.4/package.tgz +5681 verbose lock tar:///root/.npm/semver/1.1.4/package.tgz /root/.npm/d42a185e-oot-npm-semver-1-1-4-package-tgz.lock +5682 verbose tar unpack /root/.npm/esprima/1.0.4/package.tgz +5683 silly lockFile 5381d222-les-js-yaml-node-modules-esprima tar:///usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/js-yaml/node_modules/esprima +5684 verbose lock tar:///usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/js-yaml/node_modules/esprima /root/.npm/5381d222-les-js-yaml-node-modules-esprima.lock +5685 silly lockFile 4f6c6d7c-ot-npm-esprima-1-0-4-package-tgz tar:///root/.npm/esprima/1.0.4/package.tgz +5686 verbose lock tar:///root/.npm/esprima/1.0.4/package.tgz /root/.npm/4f6c6d7c-ot-npm-esprima-1-0-4-package-tgz.lock +5687 verbose tar unpack /tmp/npm-17670-yMiqFMg9/1411067673813-0.4999128810595721/tmp.tgz +5688 silly lockFile 7777421a--4999128810595721-tmp-tgz-unpack tar:///tmp/npm-17670-yMiqFMg9/1411067673813-0.4999128810595721/tmp.tgz-unpack +5689 verbose lock tar:///tmp/npm-17670-yMiqFMg9/1411067673813-0.4999128810595721/tmp.tgz-unpack /root/.npm/7777421a--4999128810595721-tmp-tgz-unpack.lock +5690 silly lockFile 54c616a6-73813-0-4999128810595721-tmp-tgz tar:///tmp/npm-17670-yMiqFMg9/1411067673813-0.4999128810595721/tmp.tgz +5691 verbose lock tar:///tmp/npm-17670-yMiqFMg9/1411067673813-0.4999128810595721/tmp.tgz /root/.npm/54c616a6-73813-0-4999128810595721-tmp-tgz.lock +5692 silly gunzTarPerm modes [ '755', '644' ] +5693 silly gunzTarPerm modes [ '755', '644' ] +5694 silly gunzTarPerm modes [ '755', '644' ] +5695 silly gunzTarPerm modes [ '755', '644' ] +5696 silly gunzTarPerm modes [ '755', '644' ] +5697 silly gunzTarPerm modes [ '755', '644' ] +5698 silly gunzTarPerm modes [ '755', '644' ] +5699 silly gunzTarPerm modes [ '755', '644' ] +5700 silly gunzTarPerm modes [ '755', '644' ] +5701 silly gunzTarPerm modes [ '755', '644' ] +5702 silly gunzTarPerm modes [ '755', '644' ] +5703 silly gunzTarPerm modes [ '755', '644' ] +5704 silly gunzTarPerm modes [ '755', '644' ] +5705 silly gunzTarPerm modes [ '755', '644' ] +5706 silly gunzTarPerm modes [ '755', '644' ] +5707 silly gunzTarPerm modes [ '755', '644' ] +5708 verbose tar unpack /root/.npm/commander/1.3.2/package.tgz +5709 silly lockFile ff03c884-generator-node-modules-commander tar:///usr/lib/node_modules/express-generator/node_modules/commander +5710 verbose lock tar:///usr/lib/node_modules/express-generator/node_modules/commander /root/.npm/ff03c884-generator-node-modules-commander.lock +5711 silly lockFile 5e9bfce8--npm-commander-1-3-2-package-tgz tar:///root/.npm/commander/1.3.2/package.tgz +5712 verbose lock tar:///root/.npm/commander/1.3.2/package.tgz /root/.npm/5e9bfce8--npm-commander-1-3-2-package-tgz.lock +5713 verbose tar unpack /root/.npm/encoding/0.1.7/package.tgz +5714 silly lockFile 8de47c91-les-zombie-node-modules-encoding tar:///usr/lib/node_modules/zombie/node_modules/encoding +5715 verbose lock tar:///usr/lib/node_modules/zombie/node_modules/encoding /root/.npm/8de47c91-les-zombie-node-modules-encoding.lock +5716 silly lockFile bf48cfc0-t-npm-encoding-0-1-7-package-tgz tar:///root/.npm/encoding/0.1.7/package.tgz +5717 verbose lock tar:///root/.npm/encoding/0.1.7/package.tgz /root/.npm/bf48cfc0-t-npm-encoding-0-1-7-package-tgz.lock +5718 verbose tar unpack /root/.npm/iconv-lite/0.2.11/package.tgz +5719 silly lockFile d6959783-es-grunt-node-modules-iconv-lite tar:///usr/lib/node_modules/grunt/node_modules/iconv-lite +5720 verbose lock tar:///usr/lib/node_modules/grunt/node_modules/iconv-lite /root/.npm/d6959783-es-grunt-node-modules-iconv-lite.lock +5721 silly lockFile c951c289-pm-iconv-lite-0-2-11-package-tgz tar:///root/.npm/iconv-lite/0.2.11/package.tgz +5722 verbose lock tar:///root/.npm/iconv-lite/0.2.11/package.tgz /root/.npm/c951c289-pm-iconv-lite-0-2-11-package-tgz.lock +5723 verbose tar unpack /root/.npm/depd/0.4.5/package.tgz +5724 silly lockFile 9cb2be64-odules-express-node-modules-depd tar:///usr/lib/node_modules/express/node_modules/depd +5725 verbose lock tar:///usr/lib/node_modules/express/node_modules/depd /root/.npm/9cb2be64-odules-express-node-modules-depd.lock +5726 silly lockFile 335c56c0--root-npm-depd-0-4-5-package-tgz tar:///root/.npm/depd/0.4.5/package.tgz +5727 verbose lock tar:///root/.npm/depd/0.4.5/package.tgz /root/.npm/335c56c0--root-npm-depd-0-4-5-package-tgz.lock +5728 verbose tar unpack /root/.npm/source-map/0.1.11/package.tgz +5729 silly lockFile dd6dfd23-pt-redux-node-modules-source-map tar:///usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/coffee-script-redux/node_modules/source-map +5730 verbose lock tar:///usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/coffee-script-redux/node_modules/source-map /root/.npm/dd6dfd23-pt-redux-node-modules-source-map.lock +5731 silly lockFile 6847b7c6-pm-source-map-0-1-11-package-tgz tar:///root/.npm/source-map/0.1.11/package.tgz +5732 verbose lock tar:///root/.npm/source-map/0.1.11/package.tgz /root/.npm/6847b7c6-pm-source-map-0-1-11-package-tgz.lock +5733 verbose tar unpack /root/.npm/traverse/0.5.2/package.tgz +5734 silly lockFile e8b2c7b2-es-burrito-node-modules-traverse tar:///usr/lib/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse +5735 verbose lock tar:///usr/lib/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/traverse /root/.npm/e8b2c7b2-es-burrito-node-modules-traverse.lock +5736 silly lockFile e05b5313-t-npm-traverse-0-5-2-package-tgz tar:///root/.npm/traverse/0.5.2/package.tgz +5737 verbose lock tar:///root/.npm/traverse/0.5.2/package.tgz /root/.npm/e05b5313-t-npm-traverse-0-5-2-package-tgz.lock +5738 verbose tar unpack /root/.npm/convert-source-map/0.3.5/package.tgz +5739 silly lockFile 3fab9226--node-modules-convert-source-map tar:///usr/lib/node_modules/myth/node_modules/rework/node_modules/convert-source-map +5740 verbose lock tar:///usr/lib/node_modules/myth/node_modules/rework/node_modules/convert-source-map /root/.npm/3fab9226--node-modules-convert-source-map.lock +5741 silly lockFile 2ba567ba-ert-source-map-0-3-5-package-tgz tar:///root/.npm/convert-source-map/0.3.5/package.tgz +5742 verbose lock tar:///root/.npm/convert-source-map/0.3.5/package.tgz /root/.npm/2ba567ba-ert-source-map-0-3-5-package-tgz.lock +5743 verbose tar unpack /root/.npm/handlebars/1.3.0/package.tgz +5744 silly lockFile 7871eac0-istanbul-node-modules-handlebars tar:///usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/handlebars +5745 verbose lock tar:///usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/handlebars /root/.npm/7871eac0-istanbul-node-modules-handlebars.lock +5746 silly lockFile 8d6586e3-npm-handlebars-1-3-0-package-tgz tar:///root/.npm/handlebars/1.3.0/package.tgz +5747 verbose lock tar:///root/.npm/handlebars/1.3.0/package.tgz /root/.npm/8d6586e3-npm-handlebars-1-3-0-package-tgz.lock +5748 silly gunzTarPerm extractEntry +5749 silly gunzTarPerm modified mode [ '', 509, 493 ] +5750 silly gunzTarPerm extractEntry package.json +5751 silly gunzTarPerm extractEntry package.json +5752 silly gunzTarPerm modified mode [ 'package.json', 438, 420 ] +5753 silly gunzTarPerm extractEntry package.json +5754 silly gunzTarPerm modes [ '755', '644' ] +5755 silly gunzTarPerm extractEntry package.json +5756 silly gunzTarPerm modes [ '755', '644' ] +5757 silly gunzTarPerm modes [ '755', '644' ] +5758 silly gunzTarPerm extractEntry package.json +5759 silly gunzTarPerm modes [ '755', '644' ] +5760 silly gunzTarPerm extractEntry package.json +5761 silly gunzTarPerm extractEntry package.json +5762 silly gunzTarPerm extractEntry package.json +5763 silly gunzTarPerm extractEntry package.json +5764 silly gunzTarPerm extractEntry package.json +5765 silly gunzTarPerm modes [ '755', '644' ] +5766 verbose tar unpack /root/.npm/coffee-script/1.7.1/package.tgz +5767 silly lockFile 4f75399f-essor-node-modules-coffee-script tar:///usr/lib/node_modules/karma-coffee-preprocessor/node_modules/coffee-script +5768 verbose lock tar:///usr/lib/node_modules/karma-coffee-preprocessor/node_modules/coffee-script /root/.npm/4f75399f-essor-node-modules-coffee-script.lock +5769 silly lockFile 5469f9ed--coffee-script-1-7-1-package-tgz tar:///root/.npm/coffee-script/1.7.1/package.tgz +5770 verbose lock tar:///root/.npm/coffee-script/1.7.1/package.tgz /root/.npm/5469f9ed--coffee-script-1-7-1-package-tgz.lock +5771 silly gunzTarPerm extractEntry .npmignore +5772 silly gunzTarPerm extractEntry README.md +5773 verbose tar unpack /root/.npm/nopt/1.0.10/package.tgz +5774 silly lockFile 89d22555-ules-grunt-cli-node-modules-nopt tar:///usr/lib/node_modules/grunt-cli/node_modules/nopt +5775 verbose lock tar:///usr/lib/node_modules/grunt-cli/node_modules/nopt /root/.npm/89d22555-ules-grunt-cli-node-modules-nopt.lock +5776 silly lockFile e94e0c23-root-npm-nopt-1-0-10-package-tgz tar:///root/.npm/nopt/1.0.10/package.tgz +5777 verbose lock tar:///root/.npm/nopt/1.0.10/package.tgz /root/.npm/e94e0c23-root-npm-nopt-1-0-10-package-tgz.lock +5778 verbose tar unpack /root/.npm/nopt/1.0.10/package.tgz +5779 silly lockFile c50bc3ed--modules-grunt-node-modules-nopt tar:///usr/lib/node_modules/grunt/node_modules/nopt +5780 verbose lock tar:///usr/lib/node_modules/grunt/node_modules/nopt /root/.npm/c50bc3ed--modules-grunt-node-modules-nopt.lock +5781 silly lockFile e94e0c23-root-npm-nopt-1-0-10-package-tgz tar:///root/.npm/nopt/1.0.10/package.tgz +5782 verbose lock tar:///root/.npm/nopt/1.0.10/package.tgz /root/.npm/e94e0c23-root-npm-nopt-1-0-10-package-tgz.lock +5783 silly gunzTarPerm extractEntry LICENSE +5784 silly gunzTarPerm modified mode [ 'LICENSE', 438, 420 ] +5785 silly gunzTarPerm extractEntry index.js +5786 silly gunzTarPerm modified mode [ 'index.js', 438, 420 ] +5787 verbose tar unpack /root/.npm/escodegen/1.3.3/package.tgz +5788 silly lockFile d2b5b14a--istanbul-node-modules-escodegen tar:///usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/escodegen +5789 verbose lock tar:///usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/escodegen /root/.npm/d2b5b14a--istanbul-node-modules-escodegen.lock +5790 silly lockFile 5d9c0d53--npm-escodegen-1-3-3-package-tgz tar:///root/.npm/escodegen/1.3.3/package.tgz +5791 verbose lock tar:///root/.npm/escodegen/1.3.3/package.tgz /root/.npm/5d9c0d53--npm-escodegen-1-3-3-package-tgz.lock +5792 verbose tar unpack /root/.npm/coffee-script/1.3.3/package.tgz +5793 silly lockFile e880dc1c-grunt-node-modules-coffee-script tar:///usr/lib/node_modules/grunt/node_modules/coffee-script +5794 verbose lock tar:///usr/lib/node_modules/grunt/node_modules/coffee-script /root/.npm/e880dc1c-grunt-node-modules-coffee-script.lock +5795 silly lockFile 0d7245b8--coffee-script-1-3-3-package-tgz tar:///root/.npm/coffee-script/1.3.3/package.tgz +5796 verbose lock tar:///root/.npm/coffee-script/1.3.3/package.tgz /root/.npm/0d7245b8--coffee-script-1-3-3-package-tgz.lock +5797 verbose tar unpack /root/.npm/esmangle/0.0.17/package.tgz +5798 silly lockFile e855f009-ript-redux-node-modules-esmangle tar:///usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/coffee-script-redux/node_modules/esmangle +5799 verbose lock tar:///usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/coffee-script-redux/node_modules/esmangle /root/.npm/e855f009-ript-redux-node-modules-esmangle.lock +5800 silly lockFile 85352e30--npm-esmangle-0-0-17-package-tgz tar:///root/.npm/esmangle/0.0.17/package.tgz +5801 verbose lock tar:///root/.npm/esmangle/0.0.17/package.tgz /root/.npm/85352e30--npm-esmangle-0-0-17-package-tgz.lock +5802 verbose tar unpack /root/.npm/nopt/2.2.1/package.tgz +5803 silly lockFile 5c35b010-de-modules-tap-node-modules-nopt tar:///usr/lib/node_modules/nodeunit/node_modules/tap/node_modules/nopt +5804 verbose lock tar:///usr/lib/node_modules/nodeunit/node_modules/tap/node_modules/nopt /root/.npm/5c35b010-de-modules-tap-node-modules-nopt.lock +5805 silly lockFile 664252e9--root-npm-nopt-2-2-1-package-tgz tar:///root/.npm/nopt/2.2.1/package.tgz +5806 verbose lock tar:///root/.npm/nopt/2.2.1/package.tgz /root/.npm/664252e9--root-npm-nopt-2-2-1-package-tgz.lock +5807 silly gunzTarPerm modes [ '755', '644' ] +5808 silly gunzTarPerm modes [ '755', '644' ] +5809 silly gunzTarPerm extractEntry +5810 silly gunzTarPerm modified mode [ '', 509, 493 ] +5811 silly gunzTarPerm modes [ '755', '644' ] +5812 silly gunzTarPerm modes [ '755', '644' ] +5813 silly gunzTarPerm modes [ '755', '644' ] +5814 verbose tar unpack /root/.npm/glob/3.2.11/package.tgz +5815 silly lockFile cb3c45c5-es-findup-sync-node-modules-glob tar:///usr/lib/node_modules/grunt-cli/node_modules/findup-sync/node_modules/glob +5816 verbose lock tar:///usr/lib/node_modules/grunt-cli/node_modules/findup-sync/node_modules/glob /root/.npm/cb3c45c5-es-findup-sync-node-modules-glob.lock +5817 silly lockFile 0cfbf35b-root-npm-glob-3-2-11-package-tgz tar:///root/.npm/glob/3.2.11/package.tgz +5818 verbose lock tar:///root/.npm/glob/3.2.11/package.tgz /root/.npm/0cfbf35b-root-npm-glob-3-2-11-package-tgz.lock +5819 verbose tar unpack /root/.npm/html5/0.3.14/package.tgz +5820 silly lockFile a6f0091c-odules-zombie-node-modules-html5 tar:///usr/lib/node_modules/zombie/node_modules/html5 +5821 verbose lock tar:///usr/lib/node_modules/zombie/node_modules/html5 /root/.npm/a6f0091c-odules-zombie-node-modules-html5.lock +5822 silly lockFile 26cb9655-oot-npm-html5-0-3-14-package-tgz tar:///root/.npm/html5/0.3.14/package.tgz +5823 verbose lock tar:///root/.npm/html5/0.3.14/package.tgz /root/.npm/26cb9655-oot-npm-html5-0-3-14-package-tgz.lock +5824 verbose tar unpack /root/.npm/underscore.string/2.2.1/package.tgz +5825 silly lockFile 018098ff-t-node-modules-underscore-string tar:///usr/lib/node_modules/grunt/node_modules/underscore.string +5826 verbose lock tar:///usr/lib/node_modules/grunt/node_modules/underscore.string /root/.npm/018098ff-t-node-modules-underscore-string.lock +5827 silly lockFile 4365d842-erscore-string-2-2-1-package-tgz tar:///root/.npm/underscore.string/2.2.1/package.tgz +5828 verbose lock tar:///root/.npm/underscore.string/2.2.1/package.tgz /root/.npm/4365d842-erscore-string-2-2-1-package-tgz.lock +5829 verbose tar unpack /root/.npm/glob/3.1.21/package.tgz +5830 silly lockFile d7d00d5c--modules-grunt-node-modules-glob tar:///usr/lib/node_modules/grunt/node_modules/glob +5831 verbose lock tar:///usr/lib/node_modules/grunt/node_modules/glob /root/.npm/d7d00d5c--modules-grunt-node-modules-glob.lock +5832 silly lockFile f8297ae5-root-npm-glob-3-1-21-package-tgz tar:///root/.npm/glob/3.1.21/package.tgz +5833 verbose lock tar:///root/.npm/glob/3.1.21/package.tgz /root/.npm/f8297ae5-root-npm-glob-3-1-21-package-tgz.lock +5834 verbose tar unpack /root/.npm/minimatch/0.2.14/package.tgz +5835 silly lockFile df6f4d2b-les-grunt-node-modules-minimatch tar:///usr/lib/node_modules/grunt/node_modules/minimatch +5836 verbose lock tar:///usr/lib/node_modules/grunt/node_modules/minimatch /root/.npm/df6f4d2b-les-grunt-node-modules-minimatch.lock +5837 silly lockFile fa5115cd-npm-minimatch-0-2-14-package-tgz tar:///root/.npm/minimatch/0.2.14/package.tgz +5838 verbose lock tar:///root/.npm/minimatch/0.2.14/package.tgz /root/.npm/fa5115cd-npm-minimatch-0-2-14-package-tgz.lock +5839 verbose tar unpack /root/.npm/minimatch/0.2.14/package.tgz +5840 silly lockFile a0980283-les-karma-node-modules-minimatch tar:///usr/lib/node_modules/karma/node_modules/minimatch +5841 verbose lock tar:///usr/lib/node_modules/karma/node_modules/minimatch /root/.npm/a0980283-les-karma-node-modules-minimatch.lock +5842 silly lockFile fa5115cd-npm-minimatch-0-2-14-package-tgz tar:///root/.npm/minimatch/0.2.14/package.tgz +5843 verbose lock tar:///root/.npm/minimatch/0.2.14/package.tgz /root/.npm/fa5115cd-npm-minimatch-0-2-14-package-tgz.lock +5844 silly lockFile 086e076d-rg-ipaddr-js-ipaddr-js-0-1-3-tgz https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-0.1.3.tgz +5845 silly lockFile 086e076d-rg-ipaddr-js-ipaddr-js-0-1-3-tgz https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-0.1.3.tgz +5846 silly gunzTarPerm extractEntry mime.js +5847 silly gunzTarPerm extractEntry test.js +5848 silly gunzTarPerm extractEntry types/mime.types +5849 silly gunzTarPerm extractEntry types/node.types +5850 verbose tar unpack /root/.npm/glob/4.0.4/package.tgz +5851 silly lockFile b8bca9c2-e-modules-vtop-node-modules-glob tar:///usr/lib/node_modules/vtop/node_modules/glob +5852 verbose lock tar:///usr/lib/node_modules/vtop/node_modules/glob /root/.npm/b8bca9c2-e-modules-vtop-node-modules-glob.lock +5853 silly lockFile 8484a7aa--root-npm-glob-4-0-4-package-tgz tar:///root/.npm/glob/4.0.4/package.tgz +5854 verbose lock tar:///root/.npm/glob/4.0.4/package.tgz /root/.npm/8484a7aa--root-npm-glob-4-0-4-package-tgz.lock +5855 verbose tar unpack /root/.npm/socket.io/0.9.17/package.tgz +5856 silly lockFile 4a02b760-les-karma-node-modules-socket-io tar:///usr/lib/node_modules/karma/node_modules/socket.io +5857 verbose lock tar:///usr/lib/node_modules/karma/node_modules/socket.io /root/.npm/4a02b760-les-karma-node-modules-socket-io.lock +5858 silly lockFile 0b7ea63a-npm-socket-io-0-9-17-package-tgz tar:///root/.npm/socket.io/0.9.17/package.tgz +5859 verbose lock tar:///root/.npm/socket.io/0.9.17/package.tgz /root/.npm/0b7ea63a-npm-socket-io-0-9-17-package-tgz.lock +5860 verbose tar unpack /root/.npm/connect/2.12.0/package.tgz +5861 silly lockFile 43f4f954-dules-karma-node-modules-connect tar:///usr/lib/node_modules/karma/node_modules/connect +5862 verbose lock tar:///usr/lib/node_modules/karma/node_modules/connect /root/.npm/43f4f954-dules-karma-node-modules-connect.lock +5863 silly lockFile 8ff7ea87-t-npm-connect-2-12-0-package-tgz tar:///root/.npm/connect/2.12.0/package.tgz +5864 verbose lock tar:///root/.npm/connect/2.12.0/package.tgz /root/.npm/8ff7ea87-t-npm-connect-2-12-0-package-tgz.lock +5865 verbose tar unpack /root/.npm/minimatch/0.3.0/package.tgz +5866 silly lockFile 29a07405--coverage-node-modules-minimatch tar:///usr/lib/node_modules/karma-coverage/node_modules/minimatch +5867 verbose lock tar:///usr/lib/node_modules/karma-coverage/node_modules/minimatch /root/.npm/29a07405--coverage-node-modules-minimatch.lock +5868 silly lockFile fcc1011d--npm-minimatch-0-3-0-package-tgz tar:///root/.npm/minimatch/0.3.0/package.tgz +5869 verbose lock tar:///root/.npm/minimatch/0.3.0/package.tgz /root/.npm/fcc1011d--npm-minimatch-0-3-0-package-tgz.lock +5870 verbose tar unpack /root/.npm/minimatch/0.4.0/package.tgz +5871 silly lockFile 06961454-s-fileset-node-modules-minimatch tar:///usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/fileset/node_modules/minimatch +5872 verbose lock tar:///usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/fileset/node_modules/minimatch /root/.npm/06961454-s-fileset-node-modules-minimatch.lock +5873 silly lockFile fd5039cf--npm-minimatch-0-4-0-package-tgz tar:///root/.npm/minimatch/0.4.0/package.tgz +5874 verbose lock tar:///root/.npm/minimatch/0.4.0/package.tgz /root/.npm/fd5039cf--npm-minimatch-0-4-0-package-tgz.lock +5875 verbose tar unpack /root/.npm/request/2.42.0/package.tgz +5876 silly lockFile 4d52001b-s-phantomjs-node-modules-request tar:///usr/lib/node_modules/karma-phantomjs-launcher/node_modules/phantomjs/node_modules/request +5877 verbose lock tar:///usr/lib/node_modules/karma-phantomjs-launcher/node_modules/phantomjs/node_modules/request /root/.npm/4d52001b-s-phantomjs-node-modules-request.lock +5878 silly lockFile 7de0adb9-t-npm-request-2-42-0-package-tgz tar:///root/.npm/request/2.42.0/package.tgz +5879 verbose lock tar:///root/.npm/request/2.42.0/package.tgz /root/.npm/7de0adb9-t-npm-request-2-42-0-package-tgz.lock +5880 verbose tar unpack /root/.npm/to-space-case/0.1.2/package.tgz +5881 silly lockFile acbbcee1--case-node-modules-to-space-case tar:///usr/lib/node_modules/myth/node_modules/to-slug-case/node_modules/to-space-case +5882 verbose lock tar:///usr/lib/node_modules/myth/node_modules/to-slug-case/node_modules/to-space-case /root/.npm/acbbcee1--case-node-modules-to-space-case.lock +5883 silly lockFile f35c8fca--to-space-case-0-1-2-package-tgz tar:///root/.npm/to-space-case/0.1.2/package.tgz +5884 verbose lock tar:///root/.npm/to-space-case/0.1.2/package.tgz /root/.npm/f35c8fca--to-space-case-0-1-2-package-tgz.lock +5885 silly gunzTarPerm extractEntry package.json +5886 verbose tar unpack /root/.npm/nopt/2.1.2/package.tgz +5887 silly lockFile 6aa849c6-e-script-redux-node-modules-nopt tar:///usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/coffee-script-redux/node_modules/nopt +5888 verbose lock tar:///usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/coffee-script-redux/node_modules/nopt /root/.npm/6aa849c6-e-script-redux-node-modules-nopt.lock +5889 silly lockFile ff755a83--root-npm-nopt-2-1-2-package-tgz tar:///root/.npm/nopt/2.1.2/package.tgz +5890 verbose lock tar:///root/.npm/nopt/2.1.2/package.tgz /root/.npm/ff755a83--root-npm-nopt-2-1-2-package-tgz.lock +5891 silly gunzTarPerm extractEntry package.json +5892 silly gunzTarPerm modes [ '755', '644' ] +5893 silly gunzTarPerm extractEntry package.json +5894 silly gunzTarPerm extractEntry package.json +5895 silly gunzTarPerm extractEntry package.json +5896 silly gunzTarPerm extractEntry README.md +5897 silly gunzTarPerm extractEntry lodash.js +5898 verbose tar unpack /root/.npm/semver/4.0.0/package.tgz +5899 silly lockFile c8c66241-ules-npmconf-node-modules-semver tar:///usr/lib/node_modules/karma-phantomjs-launcher/node_modules/phantomjs/node_modules/npmconf/node_modules/semver +5900 verbose lock tar:///usr/lib/node_modules/karma-phantomjs-launcher/node_modules/phantomjs/node_modules/npmconf/node_modules/semver /root/.npm/c8c66241-ules-npmconf-node-modules-semver.lock +5901 silly lockFile ce7815a0-oot-npm-semver-4-0-0-package-tgz tar:///root/.npm/semver/4.0.0/package.tgz +5902 verbose lock tar:///root/.npm/semver/4.0.0/package.tgz /root/.npm/ce7815a0-oot-npm-semver-4-0-0-package-tgz.lock +5903 silly gunzTarPerm modes [ '755', '644' ] +5904 silly gunzTarPerm extractEntry README.md +5905 silly gunzTarPerm modified mode [ 'README.md', 438, 420 ] +5906 silly gunzTarPerm extractEntry LICENSE +5907 silly gunzTarPerm modified mode [ 'LICENSE', 438, 420 ] +5908 silly gunzTarPerm extractEntry package.json +5909 silly lockFile d2c4a0f8-ipaddr-js-0-1-3 ipaddr.js@0.1.3 +5910 silly lockFile d2c4a0f8-ipaddr-js-0-1-3 ipaddr.js@0.1.3 +5911 silly gunzTarPerm extractEntry README.md +5912 silly gunzTarPerm extractEntry LICENSE +5913 silly gunzTarPerm extractEntry index.js +5914 silly gunzTarPerm extractEntry Readme.md +5915 silly gunzTarPerm extractEntry package.json +5916 silly gunzTarPerm extractEntry package.json +5917 silly gunzTarPerm extractEntry package.json +5918 silly gunzTarPerm extractEntry package.json +5919 silly gunzTarPerm modes [ '755', '644' ] +5920 silly gunzTarPerm extractEntry package.json +5921 silly gunzTarPerm extractEntry .npmignore +5922 silly gunzTarPerm extractEntry README.md +5923 silly gunzTarPerm extractEntry package.json +5924 silly gunzTarPerm modes [ '755', '644' ] +5925 silly gunzTarPerm extractEntry index.js +5926 silly gunzTarPerm extractEntry package.json +5927 silly gunzTarPerm extractEntry README.md +5928 silly gunzTarPerm extractEntry index.js +5929 silly gunzTarPerm extractEntry .npmignore +5930 silly gunzTarPerm extractEntry README.md +5931 silly gunzTarPerm extractEntry README.md +5932 silly gunzTarPerm extractEntry index.js +5933 silly gunzTarPerm extractEntry README.md +5934 silly gunzTarPerm extractEntry index.js +5935 silly gunzTarPerm extractEntry README.md +5936 silly gunzTarPerm extractEntry index.js +5937 silly gunzTarPerm extractEntry package.json +5938 silly gunzTarPerm extractEntry package.json +5939 silly gunzTarPerm extractEntry README.md +5940 silly gunzTarPerm modified mode [ 'README.md', 436, 420 ] +5941 silly gunzTarPerm extractEntry package.json +5942 silly gunzTarPerm modified mode [ 'package.json', 436, 420 ] +5943 silly gunzTarPerm extractEntry taffy-test.html +5944 silly gunzTarPerm modified mode [ 'taffy-test.html', 436, 420 ] +5945 verbose tar unpack /root/.npm/ws/0.4.31/package.tgz +5946 silly lockFile c82ef53e-e-modules-zombie-node-modules-ws tar:///usr/lib/node_modules/zombie/node_modules/ws +5947 verbose lock tar:///usr/lib/node_modules/zombie/node_modules/ws /root/.npm/c82ef53e-e-modules-zombie-node-modules-ws.lock +5948 silly lockFile e494c62a-r-root-npm-ws-0-4-31-package-tgz tar:///root/.npm/ws/0.4.31/package.tgz +5949 verbose lock tar:///root/.npm/ws/0.4.31/package.tgz /root/.npm/e494c62a-r-root-npm-ws-0-4-31-package-tgz.lock +5950 silly gunzTarPerm extractEntry index.js +5951 silly gunzTarPerm extractEntry index.js +5952 silly gunzTarPerm modified mode [ 'index.js', 438, 420 ] +5953 silly gunzTarPerm extractEntry HISTORY.md +5954 silly gunzTarPerm modified mode [ 'HISTORY.md', 438, 420 ] +5955 verbose tar unpack /root/.npm/http-proxy/0.10.4/package.tgz +5956 silly lockFile a4a93396-es-karma-node-modules-http-proxy tar:///usr/lib/node_modules/karma/node_modules/http-proxy +5957 verbose lock tar:///usr/lib/node_modules/karma/node_modules/http-proxy /root/.npm/a4a93396-es-karma-node-modules-http-proxy.lock +5958 silly lockFile e660dea9-pm-http-proxy-0-10-4-package-tgz tar:///root/.npm/http-proxy/0.10.4/package.tgz +5959 verbose lock tar:///root/.npm/http-proxy/0.10.4/package.tgz /root/.npm/e660dea9-pm-http-proxy-0-10-4-package-tgz.lock +5960 verbose tar unpack /root/.npm/escodegen/1.1.0/package.tgz +5961 silly lockFile 6c14dcf1-les-ibrik-node-modules-escodegen tar:///usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/escodegen +5962 verbose lock tar:///usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/escodegen /root/.npm/6c14dcf1-les-ibrik-node-modules-escodegen.lock +5963 silly lockFile 34967390--npm-escodegen-1-1-0-package-tgz tar:///root/.npm/escodegen/1.1.0/package.tgz +5964 verbose lock tar:///root/.npm/escodegen/1.1.0/package.tgz /root/.npm/34967390--npm-escodegen-1-1-0-package-tgz.lock +5965 verbose tar unpack /root/.npm/istanbul/0.2.16/package.tgz +5966 silly lockFile 24ab5d7c-ules-ibrik-node-modules-istanbul tar:///usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/istanbul +5967 verbose lock tar:///usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/istanbul /root/.npm/24ab5d7c-ules-ibrik-node-modules-istanbul.lock +5968 silly lockFile ec9bfac7--npm-istanbul-0-2-16-package-tgz tar:///root/.npm/istanbul/0.2.16/package.tgz +5969 verbose lock tar:///root/.npm/istanbul/0.2.16/package.tgz /root/.npm/ec9bfac7--npm-istanbul-0-2-16-package-tgz.lock +5970 silly gunzTarPerm modes [ '755', '644' ] +5971 silly gunzTarPerm modes [ '755', '644' ] +5972 silly gunzTarPerm extractEntry package.json +5973 silly gunzTarPerm modes [ '755', '644' ] +5974 silly gunzTarPerm extractEntry package.json +5975 silly gunzTarPerm modes [ '755', '644' ] +5976 silly gunzTarPerm extractEntry package.json +5977 silly gunzTarPerm modes [ '755', '644' ] +5978 silly gunzTarPerm extractEntry package.json +5979 silly gunzTarPerm modes [ '755', '644' ] +5980 silly gunzTarPerm modes [ '755', '644' ] +5981 silly gunzTarPerm extractEntry +5982 silly gunzTarPerm modified mode [ '', 509, 493 ] +5983 silly gunzTarPerm modes [ '755', '644' ] +5984 silly gunzTarPerm modes [ '755', '644' ] +5985 verbose tar unpack /root/.npm/jsdom/0.8.11/package.tgz +5986 silly lockFile 48d72526-odules-zombie-node-modules-jsdom tar:///usr/lib/node_modules/zombie/node_modules/jsdom +5987 verbose lock tar:///usr/lib/node_modules/zombie/node_modules/jsdom /root/.npm/48d72526-odules-zombie-node-modules-jsdom.lock +5988 silly lockFile 0773ea8f-oot-npm-jsdom-0-8-11-package-tgz tar:///root/.npm/jsdom/0.8.11/package.tgz +5989 verbose lock tar:///root/.npm/jsdom/0.8.11/package.tgz /root/.npm/0773ea8f-oot-npm-jsdom-0-8-11-package-tgz.lock +5990 verbose tar unpack /root/.npm/wrench/1.3.9/package.tgz +5991 silly lockFile 05b78e63-odules-jsdoc-node-modules-wrench tar:///usr/lib/node_modules/jsdoc/node_modules/wrench +5992 verbose lock tar:///usr/lib/node_modules/jsdoc/node_modules/wrench /root/.npm/05b78e63-odules-jsdoc-node-modules-wrench.lock +5993 silly lockFile 1d20eeee-oot-npm-wrench-1-3-9-package-tgz tar:///root/.npm/wrench/1.3.9/package.tgz +5994 verbose lock tar:///root/.npm/wrench/1.3.9/package.tgz /root/.npm/1d20eeee-oot-npm-wrench-1-3-9-package-tgz.lock +5995 silly gunzTarPerm extractEntry .gitmodules +5996 silly gunzTarPerm modified mode [ '.gitmodules', 436, 420 ] +5997 silly gunzTarPerm extractEntry LICENSE +5998 silly gunzTarPerm modified mode [ 'LICENSE', 436, 420 ] +5999 silly gunzTarPerm extractEntry Makefile +6000 silly gunzTarPerm modified mode [ 'Makefile', 436, 420 ] +6001 verbose tar unpack /root/.npm/recursive-readdir/0.0.2/package.tgz +6002 silly lockFile 5cbff891-r-node-modules-recursive-readdir tar:///usr/lib/node_modules/karma/node_modules/chokidar/node_modules/recursive-readdir +6003 verbose lock tar:///usr/lib/node_modules/karma/node_modules/chokidar/node_modules/recursive-readdir /root/.npm/5cbff891-r-node-modules-recursive-readdir.lock +6004 silly lockFile 54851c92-ursive-readdir-0-0-2-package-tgz tar:///root/.npm/recursive-readdir/0.0.2/package.tgz +6005 verbose lock tar:///root/.npm/recursive-readdir/0.0.2/package.tgz /root/.npm/54851c92-ursive-readdir-0-0-2-package-tgz.lock +6006 silly gunzTarPerm extractEntry README.md +6007 silly gunzTarPerm extractEntry index.js +6008 silly gunzTarPerm extractEntry package.json +6009 silly gunzTarPerm extractEntry LICENSE +6010 silly gunzTarPerm extractEntry index.js +6011 silly gunzTarPerm extractEntry .npmignore +6012 silly gunzTarPerm extractEntry README.md +6013 silly gunzTarPerm extractEntry package.json +6014 silly gunzTarPerm extractEntry README.md +6015 silly gunzTarPerm extractEntry LICENSE +6016 silly gunzTarPerm extractEntry q.js +6017 silly gunzTarPerm extractEntry queue.js +6018 silly gunzTarPerm extractEntry CONTRIBUTING.md +6019 silly gunzTarPerm extractEntry benchmark/compare-with-callbacks.js +6020 silly gunzTarPerm extractEntry benchmark/scenarios.js +6021 silly gunzTarPerm extractEntry Readme.md +6022 silly gunzTarPerm extractEntry lib/dateformat.js +6023 silly gunzTarPerm modes [ '755', '644' ] +6024 silly gunzTarPerm extractEntry .npmignore +6025 silly gunzTarPerm extractEntry README.md +6026 silly gunzTarPerm extractEntry .npmignore +6027 silly gunzTarPerm extractEntry README.md +6028 silly gunzTarPerm extractEntry README.md +6029 silly gunzTarPerm extractEntry LICENSE +6030 silly gunzTarPerm extractEntry q.js +6031 silly gunzTarPerm extractEntry queue.js +6032 silly gunzTarPerm extractEntry CONTRIBUTING.md +6033 silly gunzTarPerm extractEntry benchmark/compare-with-callbacks.js +6034 silly gunzTarPerm extractEntry benchmark/scenarios.js +6035 silly gunzTarPerm extractEntry LICENSE +6036 silly gunzTarPerm extractEntry index.js +6037 silly gunzTarPerm extractEntry .npmignore +6038 silly gunzTarPerm extractEntry README.md +6039 silly gunzTarPerm extractEntry README.md +6040 silly gunzTarPerm extractEntry LICENSE +6041 silly gunzTarPerm extractEntry component.json +6042 silly gunzTarPerm extractEntry lib/async.js +6043 silly gunzTarPerm extractEntry .npmignore +6044 silly gunzTarPerm extractEntry LICENSE +6045 silly gunzTarPerm modes [ '755', '644' ] +6046 silly gunzTarPerm extractEntry package.json +6047 silly gunzTarPerm extractEntry package.json +6048 silly gunzTarPerm extractEntry README.markdown +6049 silly gunzTarPerm extractEntry index.js +6050 silly gunzTarPerm extractEntry example/256.js +6051 silly gunzTarPerm extractEntry index.js +6052 silly gunzTarPerm extractEntry package.json +6053 silly gunzTarPerm extractEntry .npmignore +6054 silly gunzTarPerm extractEntry README.md +6055 silly gunzTarPerm extractEntry debug.js +6056 silly gunzTarPerm extractEntry index.js +6057 silly gunzTarPerm modes [ '755', '644' ] +6058 verbose tar unpack /root/.npm/js-yaml/2.0.5/package.tgz +6059 silly lockFile 6d6d1178-dules-grunt-node-modules-js-yaml tar:///usr/lib/node_modules/grunt/node_modules/js-yaml +6060 verbose lock tar:///usr/lib/node_modules/grunt/node_modules/js-yaml /root/.npm/6d6d1178-dules-grunt-node-modules-js-yaml.lock +6061 silly lockFile 1ca952a9-ot-npm-js-yaml-2-0-5-package-tgz tar:///root/.npm/js-yaml/2.0.5/package.tgz +6062 verbose lock tar:///root/.npm/js-yaml/2.0.5/package.tgz /root/.npm/1ca952a9-ot-npm-js-yaml-2-0-5-package-tgz.lock +6063 verbose tar unpack /root/.npm/escodegen/0.0.28/package.tgz +6064 silly lockFile 210e6fd7-ipt-redux-node-modules-escodegen tar:///usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/coffee-script-redux/node_modules/escodegen +6065 verbose lock tar:///usr/lib/node_modules/karma-coverage/node_modules/ibrik/node_modules/coffee-script-redux/node_modules/escodegen /root/.npm/210e6fd7-ipt-redux-node-modules-escodegen.lock +6066 silly lockFile c696885e-npm-escodegen-0-0-28-package-tgz tar:///root/.npm/escodegen/0.0.28/package.tgz +6067 verbose lock tar:///root/.npm/escodegen/0.0.28/package.tgz /root/.npm/c696885e-npm-escodegen-0-0-28-package-tgz.lock +6068 verbose tar unpack /root/.npm/uglify-js/1.1.1/package.tgz +6069 silly lockFile 5344c2f5-s-burrito-node-modules-uglify-js tar:///usr/lib/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/uglify-js +6070 verbose lock tar:///usr/lib/node_modules/nodeunit/node_modules/tap/node_modules/runforcover/node_modules/bunker/node_modules/burrito/node_modules/uglify-js /root/.npm/5344c2f5-s-burrito-node-modules-uglify-js.lock +6071 silly lockFile 807b3d4b--npm-uglify-js-1-1-1-package-tgz tar:///root/.npm/uglify-js/1.1.1/package.tgz +6072 verbose lock tar:///root/.npm/uglify-js/1.1.1/package.tgz /root/.npm/807b3d4b--npm-uglify-js-1-1-1-package-tgz.lock +6073 silly gunzTarPerm modes [ '755', '644' ] +6074 silly gunzTarPerm extractEntry taffy.js +6075 silly gunzTarPerm modified mode [ 'taffy.js', 436, 420 ] +6076 silly gunzTarPerm extractEntry LICENSE +6077 silly gunzTarPerm extractEntry glob.js +6078 silly gunzTarPerm extractEntry package.json +6079 silly gunzTarPerm extractEntry package.json +6080 silly gunzTarPerm modes [ '755', '644' ] +6081 silly gunzTarPerm extractEntry History.md +6082 silly gunzTarPerm modified mode [ 'History.md', 438, 420 ] +6083 silly gunzTarPerm extractEntry Readme.md +6084 silly gunzTarPerm modified mode [ 'Readme.md', 438, 420 ] +6085 silly gunzTarPerm extractEntry lib/compat/buffer-concat.js +6086 silly gunzTarPerm modified mode [ 'lib/compat/buffer-concat.js', 438, 420 ] +6087 silly gunzTarPerm extractEntry lib/compat/callsite-tostring.js +6088 silly gunzTarPerm modified mode [ 'lib/compat/callsite-tostring.js', 438, 420 ] +6089 silly gunzTarPerm extractEntry lib/compat/index.js +6090 silly gunzTarPerm modified mode [ 'lib/compat/index.js', 438, 420 ] +6091 silly gunzTarPerm extractEntry cli.js +6092 silly gunzTarPerm extractEntry strip-json-comments.js +6093 silly gunzTarPerm extractEntry .npmignore +6094 silly gunzTarPerm extractEntry README.md +6095 silly gunzTarPerm modes [ '755', '644' ] +6096 silly gunzTarPerm extractEntry README.md +6097 silly gunzTarPerm extractEntry LICENSE +6098 silly gunzTarPerm extractEntry package.json +6099 silly gunzTarPerm modes [ '755', '644' ] +6100 silly gunzTarPerm modes [ '755', '644' ] +6101 silly gunzTarPerm extractEntry .npmignore +6102 silly gunzTarPerm extractEntry index.js +6103 silly gunzTarPerm extractEntry package.json +6104 verbose tar unpack /root/.npm/resolve/0.3.1/package.tgz +6105 silly lockFile 0901a049-s-grunt-cli-node-modules-resolve tar:///usr/lib/node_modules/grunt-cli/node_modules/resolve +6106 verbose lock tar:///usr/lib/node_modules/grunt-cli/node_modules/resolve /root/.npm/0901a049-s-grunt-cli-node-modules-resolve.lock +6107 silly lockFile f4fcda87-ot-npm-resolve-0-3-1-package-tgz tar:///root/.npm/resolve/0.3.1/package.tgz +6108 verbose lock tar:///root/.npm/resolve/0.3.1/package.tgz /root/.npm/f4fcda87-ot-npm-resolve-0-3-1-package-tgz.lock +6109 silly gunzTarPerm extractEntry .gitignore +6110 silly gunzTarPerm modified mode [ '.gitignore', 436, 420 ] +6111 silly gunzTarPerm extractEntry CHANGELOG.md +6112 silly gunzTarPerm modified mode [ 'CHANGELOG.md', 436, 420 ] +6113 silly gunzTarPerm extractEntry LICENSE +6114 silly gunzTarPerm modified mode [ 'LICENSE', 436, 420 ] +6115 silly gunzTarPerm extractEntry index.js +6116 silly gunzTarPerm extractEntry History.md +6117 silly gunzTarPerm extractEntry Readme.md +6118 silly resolved [ { name: 'negotiator', +6118 silly resolved description: 'HTTP content negotiation', +6118 silly resolved version: '0.4.7', +6118 silly resolved author: +6118 silly resolved { name: 'Federico Romero', +6118 silly resolved email: 'federico.romero@outboxlabs.com' }, +6118 silly resolved contributors: [ [Object] ], +6118 silly resolved repository: +6118 silly resolved { type: 'git', +6118 silly resolved url: 'git://github.com/federomero/negotiator.git' }, +6118 silly resolved keywords: +6118 silly resolved [ 'http', +6118 silly resolved 'content negotiation', +6118 silly resolved 'accept', +6118 silly resolved 'accept-language', +6118 silly resolved 'accept-encoding', +6118 silly resolved 'accept-charset' ], +6118 silly resolved engine: 'node >= 0.6', +6118 silly resolved license: 'MIT', +6118 silly resolved devDependencies: { nodeunit: '0.8.x' }, +6118 silly resolved scripts: { test: 'nodeunit test' }, +6118 silly resolved optionalDependencies: {}, +6118 silly resolved engines: { node: '*' }, +6118 silly resolved main: 'lib/negotiator.js', +6118 silly resolved bugs: { url: 'https://github.com/federomero/negotiator/issues' }, +6118 silly resolved homepage: 'https://github.com/federomero/negotiator', +6118 silly resolved dependencies: {}, +6118 silly resolved _id: 'negotiator@0.4.7', +6118 silly resolved dist: +6118 silly resolved { shasum: 'a4160f7177ec806738631d0d3052325da42abdc8', +6118 silly resolved tarball: 'http://registry.npmjs.org/negotiator/-/negotiator-0.4.7.tgz' }, +6118 silly resolved _from: 'negotiator@0.4.7', +6118 silly resolved _npmVersion: '1.4.3', +6118 silly resolved _npmUser: { name: 'federomero', email: 'federomero@gmail.com' }, +6118 silly resolved maintainers: [ [Object] ], +6118 silly resolved directories: {}, +6118 silly resolved _shasum: 'a4160f7177ec806738631d0d3052325da42abdc8', +6118 silly resolved _resolved: 'https://registry.npmjs.org/negotiator/-/negotiator-0.4.7.tgz', +6118 silly resolved readme: 'ERROR: No README data found!' } ] +6119 info install negotiator@0.4.7 into /usr/lib/node_modules/express/node_modules/accepts +6120 info installOne negotiator@0.4.7 +6121 silly gunzTarPerm modes [ '755', '644' ] +6122 silly gunzTarPerm extractEntry .npmignore +6123 silly gunzTarPerm extractEntry README.md +6124 silly gunzTarPerm modes [ '755', '644' ] +6125 silly gunzTarPerm extractEntry package.json +6126 silly gunzTarPerm extractEntry package.json +6127 silly gunzTarPerm extractEntry README.md +6128 silly gunzTarPerm modified mode [ 'README.md', 436, 420 ] +6129 silly gunzTarPerm extractEntry bin/ +6130 silly gunzTarPerm modified mode [ 'bin/', 509, 493 ] +6131 silly gunzTarPerm extractEntry package.json +6132 silly gunzTarPerm extractEntry package.json +6133 silly gunzTarPerm modes [ '755', '644' ] +6134 silly gunzTarPerm modes [ '755', '644' ] +6135 silly gunzTarPerm extractEntry package.json +6136 silly gunzTarPerm modes [ '755', '644' ] +6137 silly gunzTarPerm extractEntry .npmignore +6138 silly gunzTarPerm extractEntry README.md +6139 silly gunzTarPerm modes [ '755', '644' ] +6140 silly gunzTarPerm extractEntry .npmignore +6141 silly gunzTarPerm extractEntry main.js +6142 silly gunzTarPerm extractEntry package.json +6143 silly gunzTarPerm extractEntry package.json +6144 silly gunzTarPerm extractEntry .npmignore +6145 silly gunzTarPerm extractEntry README.md +6146 silly gunzTarPerm extractEntry package.json +6147 verbose lib/node_modules/express/node_modules/accepts/node_modules/negotiator unbuild +6148 silly gunzTarPerm extractEntry package.json +6149 silly gunzTarPerm extractEntry index.js +6150 silly gunzTarPerm modified mode [ 'index.js', 438, 420 ] +6151 silly gunzTarPerm extractEntry HISTORY.md +6152 silly gunzTarPerm modified mode [ 'HISTORY.md', 438, 420 ] +6153 silly resolved [ { name: 'ipaddr.js', +6153 silly resolved description: 'A library for manipulating IPv4 and IPv6 addresses in JavaScript.', +6153 silly resolved version: '0.1.3', +6153 silly resolved author: { name: 'Peter Zotov', email: 'whitequark@whitequark.org' }, +6153 silly resolved directories: { lib: './lib' }, +6153 silly resolved dependencies: {}, +6153 silly resolved devDependencies: +6153 silly resolved { 'coffee-script': '~1.6', +6153 silly resolved nodeunit: '~0.5.3', +6153 silly resolved 'uglify-js': 'latest' }, +6153 silly resolved scripts: { test: 'cake build test' }, +6153 silly resolved keywords: [ 'ip', 'ipv4', 'ipv6' ], +6153 silly resolved repository: { type: 'git', url: 'git://github.com/whitequark/ipaddr.js' }, +6153 silly resolved main: './lib/ipaddr', +6153 silly resolved engines: { node: '>= 0.2.5' }, +6153 silly resolved bugs: { url: 'https://github.com/whitequark/ipaddr.js/issues' }, +6153 silly resolved _id: 'ipaddr.js@0.1.3', +6153 silly resolved dist: +6153 silly resolved { shasum: '27a9ca37f148d2102b0ef191ccbf2c51a8f025c6', +6153 silly resolved tarball: 'http://registry.npmjs.org/ipaddr.js/-/ipaddr.js-0.1.3.tgz' }, +6153 silly resolved _from: 'ipaddr.js@0.1.3', +6153 silly resolved _npmVersion: '1.4.4', +6153 silly resolved _npmUser: { name: 'whitequark', email: 'whitequark@whitequark.org' }, +6153 silly resolved maintainers: [ [Object] ], +6153 silly resolved _shasum: '27a9ca37f148d2102b0ef191ccbf2c51a8f025c6', +6153 silly resolved _resolved: 'https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-0.1.3.tgz' } ] +6154 info install ipaddr.js@0.1.3 into /usr/lib/node_modules/express/node_modules/proxy-addr +6155 info installOne ipaddr.js@0.1.3 +6156 silly gunzTarPerm extractEntry LICENSE +6157 silly gunzTarPerm extractEntry underscore-min.js +6158 silly gunzTarPerm extractEntry index.js +6159 silly gunzTarPerm extractEntry .travis.yml +6160 silly gunzTarPerm extractEntry .npmignore +6161 silly gunzTarPerm extractEntry README.md +6162 silly gunzTarPerm modes [ '755', '644' ] +6163 silly gunzTarPerm modes [ '755', '644' ] +6164 silly gunzTarPerm extractEntry lodash.min.js +6165 silly gunzTarPerm extractEntry package.json +6166 silly gunzTarPerm extractEntry .travis.yml +6167 silly gunzTarPerm extractEntry Gemfile +6168 silly gunzTarPerm extractEntry underscore-min.js +6169 silly gunzTarPerm modes [ '755', '644' ] +6170 silly gunzTarPerm extractEntry README.md +6171 silly gunzTarPerm extractEntry escodegen.browser.min.js +6172 silly gunzTarPerm extractEntry package.json +6173 silly gunzTarPerm modes [ '755', '644' ] +6174 silly gunzTarPerm extractEntry .npmignore +6175 silly gunzTarPerm extractEntry README.md +6176 silly gunzTarPerm extractEntry package.json +6177 verbose tar unpack /root/.npm/resolve/0.7.4/package.tgz +6178 silly lockFile 0f21143f-es-istanbul-node-modules-resolve tar:///usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/resolve +6179 verbose lock tar:///usr/lib/node_modules/karma-coverage/node_modules/istanbul/node_modules/resolve /root/.npm/0f21143f-es-istanbul-node-modules-resolve.lock +6180 silly lockFile ab8ade3d-ot-npm-resolve-0-7-4-package-tgz tar:///root/.npm/resolve/0.7.4/package.tgz +6181 verbose lock tar:///root/.npm/resolve/0.7.4/package.tgz /root/.npm/ab8ade3d-ot-npm-resolve-0-7-4-package-tgz.lock +6182 silly gunzTarPerm extractEntry package.json +6183 verbose tar unpack /root/.npm/negotiator/0.4.7/package.tgz +6184 silly lockFile 1640ab64--accepts-node-modules-negotiator tar:///usr/lib/node_modules/express/node_modules/accepts/node_modules/negotiator +6185 verbose lock tar:///usr/lib/node_modules/express/node_modules/accepts/node_modules/negotiator /root/.npm/1640ab64--accepts-node-modules-negotiator.lock +6186 silly lockFile 89c43cda-npm-negotiator-0-4-7-package-tgz tar:///root/.npm/negotiator/0.4.7/package.tgz +6187 verbose lock tar:///root/.npm/negotiator/0.4.7/package.tgz /root/.npm/89c43cda-npm-negotiator-0-4-7-package-tgz.lock +6188 silly gunzTarPerm extractEntry test/test_weekofyear.js +6189 silly gunzTarPerm extractEntry test/test_weekofyear.sh +6190 silly gunzTarPerm modes [ '755', '644' ] +6191 silly gunzTarPerm extractEntry .npmignore +6192 silly gunzTarPerm extractEntry README.md +6193 silly gunzTarPerm extractEntry .npmignore +6194 silly gunzTarPerm extractEntry README.md +6195 silly gunzTarPerm extractEntry .npmignore +6196 silly gunzTarPerm extractEntry .npmignore +6197 silly gunzTarPerm extractEntry README.md +6198 silly gunzTarPerm extractEntry .npmignore +6199 silly gunzTarPerm extractEntry LICENSE +6200 silly gunzTarPerm extractEntry LICENSE +6201 silly gunzTarPerm extractEntry s.js +6202 silly gunzTarPerm extractEntry package.json +6203 silly gunzTarPerm extractEntry .npmignore +6204 silly gunzTarPerm extractEntry README.md +6205 silly gunzTarPerm extractEntry package.json +6206 silly gunzTarPerm extractEntry package.json +6207 silly gunzTarPerm extractEntry .npmignore +6208 silly gunzTarPerm extractEntry README.md +6209 silly gunzTarPerm extractEntry .npmignore +6210 silly gunzTarPerm extractEntry index.js +6211 silly gunzTarPerm extractEntry Readme.md +6212 silly gunzTarPerm modified mode [ 'Readme.md', 436, 420 ] +6213 silly gunzTarPerm extractEntry binding.gyp +6214 silly gunzTarPerm modified mode [ 'binding.gyp', 436, 420 ] +6215 silly gunzTarPerm extractEntry .npmignore +6216 silly gunzTarPerm extractEntry README.md +6217 silly gunzTarPerm extractEntry .travis.yml +6218 silly gunzTarPerm extractEntry example/parse.js +6219 silly gunzTarPerm extractEntry .npmignore +6220 silly gunzTarPerm extractEntry README.md +6221 silly gunzTarPerm extractEntry LICENSE +6222 silly gunzTarPerm extractEntry LICENSE +6223 silly gunzTarPerm extractEntry graceful-fs.js +6224 silly gunzTarPerm extractEntry .travis.yml +6225 silly gunzTarPerm extractEntry example/parse.js +6226 silly gunzTarPerm extractEntry index.js +6227 silly gunzTarPerm extractEntry .travis.yml +6228 silly gunzTarPerm extractEntry example/progress.js +6229 silly gunzTarPerm extractEntry example/lucky.js +6230 silly gunzTarPerm extractEntry example.js +6231 silly gunzTarPerm extractEntry index.js +6232 silly gunzTarPerm extractEntry Readme.md +6233 silly gunzTarPerm extractEntry lib/debug.js +6234 silly gunzTarPerm extractEntry .travis.yml +6235 silly gunzTarPerm extractEntry LICENSE +6236 silly gunzTarPerm extractEntry .travis.yml +6237 silly gunzTarPerm extractEntry package.json +6238 silly gunzTarPerm extractEntry .npmignore +6239 silly gunzTarPerm extractEntry README.md +6240 silly gunzTarPerm extractEntry package.json +6241 silly gunzTarPerm extractEntry package.json +6242 silly gunzTarPerm extractEntry semver.js +6243 silly gunzTarPerm extractEntry test.js +6244 silly gunzTarPerm extractEntry bin/semver +6245 silly gunzTarPerm extractEntry package.json +6246 silly gunzTarPerm modes [ '755', '644' ] +6247 silly gunzTarPerm extractEntry package.json +6248 silly gunzTarPerm extractEntry README.md +6249 silly gunzTarPerm extractEntry Gruntfile.js +6250 silly gunzTarPerm extractEntry package.json +6251 silly gunzTarPerm extractEntry test.js +6252 silly gunzTarPerm extractEntry History.md +6253 silly gunzTarPerm extractEntry Readme.md +6254 silly gunzTarPerm extractEntry component.json +6255 silly gunzTarPerm modes [ '755', '644' ] +6256 silly gunzTarPerm extractEntry .npmignore +6257 silly gunzTarPerm extractEntry LICENSE +6258 silly gunzTarPerm modes [ '755', '644' ] +6259 verbose lib/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js unbuild +6260 silly gunzTarPerm extractEntry readme.md +6261 verbose tar unpack /root/.npm/request/2.34.0/package.tgz +6262 silly lockFile 4efa5e11-ules-zombie-node-modules-request tar:///usr/lib/node_modules/zombie/node_modules/request +6263 verbose lock tar:///usr/lib/node_modules/zombie/node_modules/request /root/.npm/4efa5e11-ules-zombie-node-modules-request.lock +6264 silly lockFile 13913cd1-t-npm-request-2-34-0-package-tgz tar:///root/.npm/request/2.34.0/package.tgz +6265 verbose lock tar:///root/.npm/request/2.34.0/package.tgz /root/.npm/13913cd1-t-npm-request-2-34-0-package-tgz.lock +6266 silly gunzTarPerm extractEntry LICENSE +6267 silly gunzTarPerm extractEntry index.js +6268 silly gunzTarPerm extractEntry .npmignore +6269 silly gunzTarPerm extractEntry README +6270 silly gunzTarPerm extractEntry package.json +6271 silly gunzTarPerm extractEntry index.js +6272 silly gunzTarPerm extractEntry test.js +6273 silly gunzTarPerm extractEntry package.json +6274 silly gunzTarPerm extractEntry lib/ +6275 silly gunzTarPerm extractEntry lib/wrench.js +6276 silly gunzTarPerm extractEntry bin/cscodegen +6277 silly gunzTarPerm modified mode [ 'bin/cscodegen', 509, 493 ] +6278 silly gunzTarPerm extractEntry lib/ +6279 silly gunzTarPerm modified mode [ 'lib/', 509, 493 ] +6280 silly gunzTarPerm extractEntry package.json +6281 silly gunzTarPerm extractEntry README.md +6282 silly gunzTarPerm extractEntry index.js +6283 silly gunzTarPerm extractEntry package.json +6284 silly gunzTarPerm extractEntry .npmignore +6285 silly gunzTarPerm extractEntry README +6286 silly gunzTarPerm extractEntry README.md +6287 silly gunzTarPerm extractEntry Gruntfile.js +6288 silly gunzTarPerm extractEntry index.js +6289 silly gunzTarPerm extractEntry LICENSE +6290 silly gunzTarPerm extractEntry Makefile.dryice.js +6291 silly gunzTarPerm extractEntry example/cmp.js +6292 silly gunzTarPerm extractEntry test/cmp.js +6293 silly gunzTarPerm extractEntry Makefile +6294 silly gunzTarPerm extractEntry LICENSE +6295 silly gunzTarPerm extractEntry index.js +6296 silly gunzTarPerm extractEntry LICENSE +6297 silly gunzTarPerm extractEntry bin/nopt.js +6298 silly gunzTarPerm extractEntry .npmignore +6299 silly gunzTarPerm extractEntry README.md +6300 silly gunzTarPerm extractEntry README.md +6301 silly gunzTarPerm extractEntry LICENSE +6302 silly gunzTarPerm extractEntry package.json +6303 silly gunzTarPerm modified mode [ 'package.json', 438, 420 ] +6304 verbose tar unpack /root/.npm/ipaddr.js/0.1.3/package.tgz +6305 silly lockFile 1d6b47ef-roxy-addr-node-modules-ipaddr-js tar:///usr/lib/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js +6306 verbose lock tar:///usr/lib/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js /root/.npm/1d6b47ef-roxy-addr-node-modules-ipaddr-js.lock +6307 silly lockFile a31b962a--npm-ipaddr-js-0-1-3-package-tgz tar:///root/.npm/ipaddr.js/0.1.3/package.tgz +6308 verbose lock tar:///root/.npm/ipaddr.js/0.1.3/package.tgz /root/.npm/a31b962a--npm-ipaddr-js-0-1-3-package-tgz.lock +6309 silly gunzTarPerm modes [ '755', '644' ] +6310 silly gunzTarPerm extractEntry .npmignore +6311 silly gunzTarPerm extractEntry LICENSE +6312 silly gunzTarPerm extractEntry .npmignore +6313 silly gunzTarPerm extractEntry README.md +6314 silly gunzTarPerm extractEntry README.md +6315 silly gunzTarPerm extractEntry esprima.js +6316 silly gunzTarPerm extractEntry README.md +6317 silly gunzTarPerm extractEntry Gruntfile.js +6318 silly gunzTarPerm extractEntry LICENSE +6319 silly gunzTarPerm extractEntry bin/nopt.js +6320 silly gunzTarPerm extractEntry LICENSE +6321 silly gunzTarPerm extractEntry index.js +6322 silly gunzTarPerm extractEntry .npmignore +6323 silly gunzTarPerm extractEntry README.md +6324 silly gunzTarPerm extractEntry Gemfile.lock +6325 silly gunzTarPerm extractEntry README.markdown +6326 silly gunzTarPerm extractEntry underscore.js +6327 silly gunzTarPerm extractEntry .npmignore +6328 silly gunzTarPerm extractEntry README.md +6329 silly gunzTarPerm extractEntry AUTHORS +6330 silly gunzTarPerm extractEntry lib/lru-cache.js +6331 silly gunzTarPerm extractEntry package.json +6332 silly gunzTarPerm extractEntry README.md +6333 silly gunzTarPerm extractEntry History.md +6334 silly gunzTarPerm extractEntry Makefile +6335 silly gunzTarPerm extractEntry README.html +6336 silly gunzTarPerm extractEntry fsevents.cc +6337 silly gunzTarPerm modified mode [ 'fsevents.cc', 436, 420 ] +6338 silly gunzTarPerm extractEntry fsevents.js +6339 silly gunzTarPerm modified mode [ 'fsevents.js', 436, 420 ] +6340 silly gunzTarPerm extractEntry LICENSE +6341 silly gunzTarPerm extractEntry bin/nopt.js +6342 silly gunzTarPerm extractEntry LICENSE +6343 silly gunzTarPerm extractEntry semver.browser.js +6344 silly gunzTarPerm extractEntry LICENSE +6345 silly gunzTarPerm extractEntry glob.js +6346 silly gunzTarPerm extractEntry LICENSE +6347 silly gunzTarPerm extractEntry minimatch.js +6348 silly gunzTarPerm extractEntry index.js +6349 silly gunzTarPerm extractEntry .gitmodules +6350 silly gunzTarPerm extractEntry Makefile +6351 silly gunzTarPerm modes [ '755', '644' ] +6352 silly gunzTarPerm extractEntry polyfills.js +6353 silly gunzTarPerm extractEntry test/open.js +6354 silly gunzTarPerm extractEntry test/readdir-sort.js +6355 silly gunzTarPerm extractEntry LICENSE +6356 silly gunzTarPerm extractEntry glob.js +6357 silly gunzTarPerm extractEntry escodegen.js +6358 silly gunzTarPerm extractEntry LICENSE +6359 silly gunzTarPerm extractEntry minimatch.js +6360 silly gunzTarPerm extractEntry examples/pow.js +6361 silly gunzTarPerm extractEntry readme.markdown +6362 silly gunzTarPerm extractEntry test/balanced.js +6363 silly gunzTarPerm extractEntry History.md +6364 silly gunzTarPerm extractEntry Makefile +6365 silly gunzTarPerm extractEntry README.md +6366 silly gunzTarPerm modified mode [ 'README.md', 438, 420 ] +6367 silly gunzTarPerm extractEntry lib/jsdom.js +6368 silly gunzTarPerm modified mode [ 'lib/jsdom.js', 438, 420 ] +6369 silly gunzTarPerm extractEntry index.js +6370 silly gunzTarPerm extractEntry History.md +6371 silly gunzTarPerm extractEntry LICENSE +6372 silly gunzTarPerm extractEntry readme.markdown +6373 silly gunzTarPerm extractEntry test/dash.js +6374 silly gunzTarPerm extractEntry cube.gif +6375 silly gunzTarPerm extractEntry readme.markdown +6376 silly gunzTarPerm extractEntry test/bool.js +6377 silly gunzTarPerm extractEntry LICENSE +6378 silly gunzTarPerm extractEntry index.js +6379 silly gunzTarPerm extractEntry lib/x.js +6380 silly gunzTarPerm extractEntry LICENSE +6381 silly gunzTarPerm extractEntry package.json +6382 silly gunzTarPerm extractEntry LICENSE +6383 silly gunzTarPerm modified mode [ 'LICENSE', 436, 420 ] +6384 silly gunzTarPerm extractEntry index.js +6385 silly gunzTarPerm modified mode [ 'index.js', 436, 420 ] +6386 silly gunzTarPerm extractEntry runtime.js +6387 silly gunzTarPerm extractEntry README.markdown +6388 silly gunzTarPerm extractEntry LICENSE +6389 silly gunzTarPerm extractEntry register.js +6390 silly gunzTarPerm extractEntry examples/my-program.js +6391 silly gunzTarPerm extractEntry lib/nopt.js +6392 silly gunzTarPerm extractEntry test/recursive-raddir-test.js +6393 silly gunzTarPerm extractEntry test/testdir/a/a +6394 silly gunzTarPerm extractEntry escodegen.browser.min.js +6395 silly gunzTarPerm extractEntry escodegen.js +6396 silly gunzTarPerm extractEntry .jshintrc +6397 silly gunzTarPerm extractEntry LICENSE.BSD +6398 silly gunzTarPerm extractEntry LICENSE.source-map +6399 silly gunzTarPerm extractEntry bin/escodegen.js +6400 silly gunzTarPerm extractEntry bin/esgenerate.js +6401 silly gunzTarPerm extractEntry component.json +6402 silly gunzTarPerm extractEntry build/assert-shim.js +6403 silly gunzTarPerm extractEntry LICENSE +6404 silly gunzTarPerm extractEntry CNAME +6405 silly gunzTarPerm extractEntry .travis.yml +6406 silly gunzTarPerm extractEntry example/comment-to-json.js +6407 silly gunzTarPerm extractEntry package.json +6408 silly gunzTarPerm extractEntry lib/cscodegen.js +6409 silly gunzTarPerm modified mode [ 'lib/cscodegen.js', 436, 420 ] +6410 silly gunzTarPerm extractEntry node_modules/ +6411 silly gunzTarPerm modified mode [ 'node_modules/', 509, 493 ] +6412 silly gunzTarPerm extractEntry node_modules/coffee-script/ +6413 silly gunzTarPerm modified mode [ 'node_modules/coffee-script/', 509, 493 ] +6414 silly gunzTarPerm extractEntry node_modules/mocha/ +6415 silly gunzTarPerm modified mode [ 'node_modules/mocha/', 509, 493 ] +6416 silly gunzTarPerm extractEntry package.json +6417 silly gunzTarPerm modified mode [ 'package.json', 436, 420 ] +6418 silly gunzTarPerm extractEntry src/ +6419 silly gunzTarPerm modified mode [ 'src/', 509, 493 ] +6420 silly gunzTarPerm extractEntry src/cscodegen.coffee +6421 silly gunzTarPerm modified mode [ 'src/cscodegen.coffee', 436, 420 ] +6422 silly gunzTarPerm extractEntry test/ +6423 silly gunzTarPerm modified mode [ 'test/', 509, 493 ] +6424 silly gunzTarPerm extractEntry test/arrays.coffee +6425 silly gunzTarPerm modified mode [ 'test/arrays.coffee', 436, 420 ] +6426 silly gunzTarPerm extractEntry test/combinations.coffee +6427 silly gunzTarPerm modified mode [ 'test/combinations.coffee', 436, 420 ] +6428 silly gunzTarPerm extractEntry test/conditional.coffee +6429 silly gunzTarPerm modified mode [ 'test/conditional.coffee', 436, 420 ] +6430 silly gunzTarPerm extractEntry test/function-application.coffee +6431 silly gunzTarPerm modified mode [ 'test/function-application.coffee', 436, 420 ] +6432 silly gunzTarPerm extractEntry test/functions.coffee +6433 silly gunzTarPerm modified mode [ 'test/functions.coffee', 436, 420 ] +6434 silly gunzTarPerm extractEntry test/interpolations.coffee +6435 silly gunzTarPerm modified mode [ 'test/interpolations.coffee', 436, 420 ] +6436 silly gunzTarPerm extractEntry test/numbers.coffee +6437 silly gunzTarPerm modified mode [ 'test/numbers.coffee', 436, 420 ] +6438 silly gunzTarPerm extractEntry test/objects.coffee +6439 silly gunzTarPerm modified mode [ 'test/objects.coffee', 436, 420 ] +6440 silly gunzTarPerm extractEntry test/operators.coffee +6441 silly gunzTarPerm modified mode [ 'test/operators.coffee', 436, 420 ] +6442 silly gunzTarPerm extractEntry test/setup.coffee +6443 silly gunzTarPerm modified mode [ 'test/setup.coffee', 436, 420 ] +6444 silly gunzTarPerm extractEntry test/strings.coffee +6445 silly gunzTarPerm modified mode [ 'test/strings.coffee', 436, 420 ] +6446 silly gunzTarPerm extractEntry test/switch.coffee +6447 silly gunzTarPerm modified mode [ 'test/switch.coffee', 436, 420 ] +6448 silly gunzTarPerm extractEntry .gitattributes +6449 silly gunzTarPerm extractEntry .gitmodules +6450 silly gunzTarPerm extractEntry LICENSE +6451 silly gunzTarPerm extractEntry minimatch.js +6452 silly gunzTarPerm extractEntry underscore.js +6453 silly gunzTarPerm extractEntry index.html +6454 silly gunzTarPerm extractEntry examples/my-program.js +6455 silly gunzTarPerm extractEntry lib/nopt.js +6456 silly gunzTarPerm extractEntry test/basic.js +6457 silly gunzTarPerm extractEntry Rakefile +6458 silly gunzTarPerm extractEntry index.js +6459 silly gunzTarPerm extractEntry HISTORY.md +6460 silly gunzTarPerm extractEntry .npmignore +6461 silly gunzTarPerm extractEntry README.md +6462 silly gunzTarPerm extractEntry index.js +6463 silly gunzTarPerm extractEntry .travis.yml +6464 silly gunzTarPerm extractEntry bin/esparse.js +6465 silly gunzTarPerm extractEntry Readme.md +6466 silly gunzTarPerm extractEntry component.json +6467 silly gunzTarPerm extractEntry package.json +6468 silly gunzTarPerm modified mode [ 'package.json', 436, 420 ] +6469 silly gunzTarPerm extractEntry examples/my-program.js +6470 silly gunzTarPerm extractEntry lib/nopt.js +6471 silly gunzTarPerm extractEntry example.js +6472 silly gunzTarPerm extractEntry lib/core-upgrade.js +6473 silly gunzTarPerm extractEntry .travis.yml +6474 silly gunzTarPerm extractEntry example/async.js +6475 silly gunzTarPerm extractEntry semver.js +6476 silly gunzTarPerm extractEntry .travis.yml +6477 silly gunzTarPerm extractEntry test/basic.js +6478 verbose tar unpack /root/.npm/npm/1.4.27/package.tgz +6479 silly lockFile 8595d2ac-tar-usr-lib-node-modules-npm tar:///usr/lib/node_modules/npm +6480 verbose lock tar:///usr/lib/node_modules/npm /root/.npm/8595d2ac-tar-usr-lib-node-modules-npm.lock +6481 silly lockFile 8a9bd9e1--root-npm-npm-1-4-27-package-tgz tar:///root/.npm/npm/1.4.27/package.tgz +6482 verbose lock tar:///root/.npm/npm/1.4.27/package.tgz /root/.npm/8a9bd9e1--root-npm-npm-1-4-27-package-tgz.lock +6483 silly gunzTarPerm extractEntry .travis.yml +6484 silly gunzTarPerm extractEntry test/basic.js +6485 silly gunzTarPerm extractEntry escodegen.js +6486 silly gunzTarPerm extractEntry .jshintrc +6487 silly gunzTarPerm extractEntry LICENSE.BSD +6488 silly gunzTarPerm extractEntry LICENSE.source-map +6489 silly gunzTarPerm extractEntry bin/escodegen.js +6490 silly gunzTarPerm extractEntry bin/esgenerate.js +6491 silly gunzTarPerm extractEntry index.js +6492 silly gunzTarPerm extractEntry test/BufferPool.test.js +6493 silly gunzTarPerm extractEntry .npmignore +6494 silly gunzTarPerm extractEntry README.md +6495 silly gunzTarPerm extractEntry package.json +6496 silly gunzTarPerm extractEntry readme.md +6497 silly gunzTarPerm extractEntry Makefile +6498 silly gunzTarPerm extractEntry LICENSE +6499 silly gunzTarPerm extractEntry package.json +6500 silly gunzTarPerm extractEntry README.markdown +6501 silly gunzTarPerm extractEntry index.js +6502 silly gunzTarPerm extractEntry request.js +6503 silly gunzTarPerm extractEntry .travis.yml +6504 silly gunzTarPerm extractEntry test/chmod.js +6505 silly gunzTarPerm extractEntry test/perm.js +6506 verbose tar unpack /tmp/npm-17670-yMiqFMg9/github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c +6507 silly lockFile c073b7c1-d653b11e9419241a9d726af7c-unpack tar:///tmp/npm-17670-yMiqFMg9/github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c-unpack +6508 verbose lock tar:///tmp/npm-17670-yMiqFMg9/github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c-unpack /root/.npm/c073b7c1-d653b11e9419241a9d726af7c-unpack.lock +6509 silly lockFile 772ed5b9-243f29bd653b11e9419241a9d726af7c tar:///tmp/npm-17670-yMiqFMg9/github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c +6510 verbose lock tar:///tmp/npm-17670-yMiqFMg9/github.com/ariya/esprima/tarball/49a2eccb243f29bd653b11e9419241a9d726af7c /root/.npm/772ed5b9-243f29bd653b11e9419241a9d726af7c.lock +6511 silly gunzTarPerm extractEntry .travis.yml +6512 silly gunzTarPerm extractEntry bin/handlebars +6513 silly gunzTarPerm extractEntry CNAME +6514 silly gunzTarPerm extractEntry CONTRIBUTING.md +6515 silly gunzTarPerm extractEntry doc/.npmignore +6516 silly gunzTarPerm extractEntry lib/eventsource.js +6517 silly gunzTarPerm extractEntry lodash.underscore.js +6518 silly gunzTarPerm extractEntry lodash.underscore.min.js +6519 silly gunzTarPerm extractEntry test/basic.js +6520 silly gunzTarPerm extractEntry test/foreach.js +6521 silly gunzTarPerm extractEntry test/memory-leak.js +6522 silly gunzTarPerm extractEntry test/testdir/a/beans +6523 silly gunzTarPerm extractEntry test/testdir/b/123 +6524 silly gunzTarPerm extractEntry .travis.yml +6525 silly gunzTarPerm modified mode [ '.travis.yml', 436, 420 ] +6526 silly gunzTarPerm extractEntry example/async.js +6527 silly gunzTarPerm modified mode [ 'example/async.js', 436, 420 ] +6528 silly gunzTarPerm extractEntry Rakefile +6529 silly gunzTarPerm extractEntry bin/cake +6530 silly gunzTarPerm extractEntry package.json +6531 silly gunzTarPerm extractEntry example/position.js +6532 silly gunzTarPerm extractEntry example/column.js +6533 silly gunzTarPerm extractEntry test/basic.js +6534 silly gunzTarPerm extractEntry LICENSE +6535 silly gunzTarPerm extractEntry index.js +6536 silly lockFile 51273c00-import-node-modules-parse-import tar:///usr/lib/node_modules/myth/node_modules/rework-import/node_modules/parse-import +6537 silly lockFile 51273c00-import-node-modules-parse-import tar:///usr/lib/node_modules/myth/node_modules/rework-import/node_modules/parse-import +6538 silly gunzTarPerm extractEntry dist/underscore.string.min.js +6539 silly gunzTarPerm extractEntry lib/underscore.string.js +6540 silly gunzTarPerm extractEntry lib/jsdom/utils.js +6541 silly gunzTarPerm modified mode [ 'lib/jsdom/utils.js', 438, 420 ] +6542 silly gunzTarPerm extractEntry lib/jsdom/browser/documentfeatures.js +6543 silly gunzTarPerm modified mode [ 'lib/jsdom/browser/documentfeatures.js', 438, 420 ] +6544 silly gunzTarPerm extractEntry Readme.md +6545 silly gunzTarPerm extractEntry lib/cache.js +6546 silly gunzTarPerm extractEntry test/mocha.js +6547 silly gunzTarPerm extractEntry test/tests.js +6548 silly gunzTarPerm extractEntry test/index.html +6549 silly gunzTarPerm extractEntry test/mocha.css +6550 silly lockFile ed0f46ad-m-parse-import-0-1-3-package-tgz tar:///root/.npm/parse-import/0.1.3/package.tgz +6551 silly lockFile ed0f46ad-m-parse-import-0-1-3-package-tgz tar:///root/.npm/parse-import/0.1.3/package.tgz +6552 silly gunzTarPerm extractEntry lib/html5/buffer.js +6553 silly gunzTarPerm extractEntry lib/html5/constants.js +6554 silly gunzTarPerm extractEntry LICENSE +6555 silly gunzTarPerm extractEntry .travis.yml +6556 silly gunzTarPerm extractEntry CONTRIBUTING.md +6557 silly lockFile 10336776-node-modules-rework-custom-media tar:///usr/lib/node_modules/myth/node_modules/rework-custom-media +6558 silly lockFile 10336776-node-modules-rework-custom-media tar:///usr/lib/node_modules/myth/node_modules/rework-custom-media +6559 silly lockFile d6436a24-rk-import-node-modules-find-file tar:///usr/lib/node_modules/myth/node_modules/rework-import/node_modules/find-file +6560 silly lockFile d6436a24-rk-import-node-modules-find-file tar:///usr/lib/node_modules/myth/node_modules/rework-import/node_modules/find-file +6561 silly gunzTarPerm extractEntry test/Sender.hixie.test.js +6562 silly gunzTarPerm extractEntry test/Sender.test.js +6563 silly gunzTarPerm extractEntry test/Validation.test.js +6564 silly gunzTarPerm extractEntry test/Receiver.test.js +6565 silly gunzTarPerm extractEntry test/Receiver.hixie.test.js +6566 silly gunzTarPerm extractEntry test/WebSocketServer.test.js +6567 silly gunzTarPerm extractEntry test/autobahn-server.js +6568 silly gunzTarPerm extractEntry test/autobahn.js +6569 silly gunzTarPerm extractEntry test/hybi-common.js +6570 silly gunzTarPerm extractEntry test/WebSocket.integration.js +6571 silly gunzTarPerm extractEntry test/testserver.js +6572 silly gunzTarPerm extractEntry test/WebSocket.test.js +6573 silly gunzTarPerm extractEntry test/fixtures/agent1-cert.pem +6574 silly gunzTarPerm extractEntry test/fixtures/agent1-key.pem +6575 silly gunzTarPerm extractEntry test/fixtures/ca1-cert.pem +6576 silly gunzTarPerm extractEntry test/fixtures/ca1-key.pem +6577 silly gunzTarPerm extractEntry test/fixtures/certificate.pem +6578 silly gunzTarPerm extractEntry test/fixtures/key.pem +6579 silly gunzTarPerm extractEntry test/fixtures/request.pem +6580 silly gunzTarPerm extractEntry test/fixtures/textfile +6581 silly gunzTarPerm extractEntry bench/parser.benchmark.js +6582 silly gunzTarPerm extractEntry bench/sender.benchmark.js +6583 silly gunzTarPerm extractEntry bench/speed.js +6584 silly gunzTarPerm extractEntry bench/util.js +6585 silly gunzTarPerm extractEntry bin/wscat +6586 silly gunzTarPerm extractEntry .travis.yml +6587 silly gunzTarPerm extractEntry doc/ws.md +6588 silly gunzTarPerm extractEntry examples/ssl.js +6589 silly gunzTarPerm extractEntry examples/fileapi/package.json +6590 silly gunzTarPerm extractEntry examples/fileapi/.npmignore +6591 silly gunzTarPerm extractEntry examples/fileapi/server.js +6592 silly gunzTarPerm extractEntry examples/fileapi/public/app.js +6593 silly gunzTarPerm extractEntry examples/fileapi/public/uploader.js +6594 silly gunzTarPerm extractEntry examples/fileapi/public/index.html +6595 silly gunzTarPerm extractEntry examples/serverstats/package.json +6596 silly gunzTarPerm extractEntry examples/serverstats/server.js +6597 silly gunzTarPerm extractEntry examples/serverstats/public/index.html +6598 silly gunzTarPerm extractEntry examples/serverstats-express_3/package.json +6599 silly gunzTarPerm extractEntry examples/serverstats-express_3/server.js +6600 silly gunzTarPerm extractEntry examples/serverstats-express_3/public/index.html +6601 silly gunzTarPerm extractEntry History.md +6602 silly gunzTarPerm extractEntry lib/BufferPool.js +6603 silly gunzTarPerm extractEntry lib/ErrorCodes.js +6604 silly gunzTarPerm extractEntry lib/Receiver.hixie.js +6605 silly gunzTarPerm extractEntry lib/Receiver.js +6606 silly gunzTarPerm extractEntry lib/BufferUtil.js +6607 silly gunzTarPerm extractEntry lib/Sender.js +6608 silly gunzTarPerm extractEntry lib/Validation.fallback.js +6609 silly gunzTarPerm extractEntry lib/Validation.js +6610 silly gunzTarPerm extractEntry lib/WebSocket.js +6611 silly gunzTarPerm extractEntry lib/WebSocketServer.js +6612 silly gunzTarPerm extractEntry lib/BufferUtil.fallback.js +6613 silly gunzTarPerm extractEntry lib/browser.js +6614 silly gunzTarPerm extractEntry lib/Sender.hixie.js +6615 silly gunzTarPerm extractEntry Makefile +6616 silly gunzTarPerm extractEntry src/bufferutil.cc +6617 silly gunzTarPerm extractEntry src/validation.cc +6618 silly gunzTarPerm extractEntry binding.gyp +6619 silly gunzTarPerm extractEntry .npmignore +6620 silly gunzTarPerm extractEntry LICENSE +6621 silly gunzTarPerm modes [ '755', '644' ] +6622 silly gunzTarPerm extractEntry CHANGELOG.md +6623 silly gunzTarPerm extractEntry benchmark/websockets-throughput.js +6624 silly gunzTarPerm extractEntry .travis.yml +6625 silly gunzTarPerm extractEntry gulpfile.js +6626 silly gunzTarPerm extractEntry .jshintrc +6627 silly gunzTarPerm extractEntry LICENSE.BSD +6628 silly lockFile a85bd7c3-k-custom-media-0-1-1-package-tgz tar:///root/.npm/rework-custom-media/0.1.1/package.tgz +6629 silly lockFile a85bd7c3-k-custom-media-0-1-1-package-tgz tar:///root/.npm/rework-custom-media/0.1.1/package.tgz +6630 silly gunzTarPerm extractEntry LICENSE +6631 silly lockFile 25f6ee23--npm-find-file-0-1-4-package-tgz tar:///root/.npm/find-file/0.1.4/package.tgz +6632 silly lockFile 25f6ee23--npm-find-file-0-1-4-package-tgz tar:///root/.npm/find-file/0.1.4/package.tgz +6633 silly gunzTarPerm extractEntry src/ +6634 silly gunzTarPerm modified mode [ 'src/', 509, 493 ] +6635 silly gunzTarPerm extractEntry src/async.cc +6636 silly gunzTarPerm modified mode [ 'src/async.cc', 436, 420 ] +6637 silly gunzTarPerm extractEntry example/sync.js +6638 silly gunzTarPerm extractEntry lib/async.js +6639 silly gunzTarPerm extractEntry LICENSE +6640 silly gunzTarPerm extractEntry ipaddr.min.js +6641 silly lockFile a2190e2d-de-modules-debug-node-modules-ms tar:///usr/lib/node_modules/express/node_modules/debug/node_modules/ms +6642 silly lockFile a2190e2d-de-modules-debug-node-modules-ms tar:///usr/lib/node_modules/express/node_modules/debug/node_modules/ms +6643 silly gunzTarPerm extractEntry examples/g.js +6644 silly gunzTarPerm extractEntry examples/usr-local.js +6645 silly lockFile d1da68ba-ar-root-npm-ms-0-6-2-package-tgz tar:///root/.npm/ms/0.6.2/package.tgz +6646 silly lockFile d1da68ba-ar-root-npm-ms-0-6-2-package-tgz tar:///root/.npm/ms/0.6.2/package.tgz +6647 silly gunzTarPerm extractEntry Readme.md +6648 silly gunzTarPerm extractEntry .travis.yml +6649 silly gunzTarPerm extractEntry .jshintrc +6650 silly gunzTarPerm extractEntry LICENSE.BSD +6651 silly lockFile ef5e660a-ework-hex-alpha-node-modules-rgb tar:///usr/lib/node_modules/myth/node_modules/rework-hex-alpha/node_modules/rgb +6652 silly lockFile ef5e660a-ework-hex-alpha-node-modules-rgb tar:///usr/lib/node_modules/myth/node_modules/rework-hex-alpha/node_modules/rgb +6653 silly gunzTarPerm extractEntry test/comment-regex.js +6654 silly lockFile ad9b8352-odules-send-node-modules-destroy tar:///usr/lib/node_modules/express/node_modules/send/node_modules/destroy +6655 silly lockFile ad9b8352-odules-send-node-modules-destroy tar:///usr/lib/node_modules/express/node_modules/send/node_modules/destroy +6656 info preinstall parse-import@0.1.3 +6657 silly gunzTarPerm extractEntry test/default_bool.js +6658 silly gunzTarPerm extractEntry test/dotted.js +6659 silly gunzTarPerm extractEntry test/long.js +6660 silly gunzTarPerm extractEntry test/parse.js +6661 silly gunzTarPerm extractEntry test/parse_modified.js +6662 silly gunzTarPerm extractEntry test/short.js +6663 silly gunzTarPerm extractEntry test/whitespace.js +6664 silly gunzTarPerm extractEntry test/dash.js +6665 silly gunzTarPerm extractEntry test/testdir/b/b/hurp-durp +6666 silly gunzTarPerm extractEntry test/testdir/c.txt +6667 silly lockFile 8685fcd0-r-root-npm-rgb-0-0-1-package-tgz tar:///root/.npm/rgb/0.0.1/package.tgz +6668 silly lockFile 8685fcd0-r-root-npm-rgb-0-0-1-package-tgz tar:///root/.npm/rgb/0.0.1/package.tgz +6669 silly lockFile 71736e82-ot-npm-destroy-1-0-3-package-tgz tar:///root/.npm/destroy/1.0.3/package.tgz +6670 silly lockFile 71736e82-ot-npm-destroy-1-0-3-package-tgz tar:///root/.npm/destroy/1.0.3/package.tgz +6671 info preinstall rework-custom-media@0.1.1 +6672 info preinstall find-file@0.1.4 +6673 silly gunzTarPerm extractEntry dist/handlebars.amd.js +6674 silly gunzTarPerm extractEntry dist/handlebars.amd.min.js +6675 silly gunzTarPerm extractEntry lib/eventstream.js +6676 silly gunzTarPerm extractEntry example/sync.js +6677 silly gunzTarPerm modified mode [ 'example/sync.js', 436, 420 ] +6678 silly gunzTarPerm extractEntry lib/async.js +6679 silly gunzTarPerm modified mode [ 'lib/async.js', 436, 420 ] +6680 silly gunzTarPerm extractEntry test/perm_sync.js +6681 silly gunzTarPerm extractEntry test/race.js +6682 silly gunzTarPerm extractEntry test/mkdirp.js +6683 silly gunzTarPerm extractEntry test/return.js +6684 silly gunzTarPerm extractEntry test/return_sync.js +6685 silly gunzTarPerm extractEntry test/root.js +6686 silly gunzTarPerm extractEntry test/sync.js +6687 silly gunzTarPerm extractEntry test/umask.js +6688 silly gunzTarPerm extractEntry test/clobber.js +6689 silly gunzTarPerm extractEntry test/umask_sync.js +6690 silly gunzTarPerm extractEntry test/rel.js +6691 verbose readDependencies using package.json deps +6692 silly gunzTarPerm extractEntry bin/cake +6693 silly gunzTarPerm extractEntry bin/coffee +6694 silly gunzTarPerm extractEntry README.md~ +6695 silly gunzTarPerm extractEntry encodings/big5.js +6696 silly gunzTarPerm extractEntry package.json +6697 info preinstall ms@0.6.2 +6698 silly gunzTarPerm extractEntry bin/esvalidate.js +6699 silly gunzTarPerm extractEntry test/compat.js +6700 silly gunzTarPerm extractEntry test/reflect.js +6701 silly gunzTarPerm modes [ '755', '644' ] +6702 silly gunzTarPerm extractEntry bin/coffee +6703 silly gunzTarPerm extractEntry extras/jsl.conf +6704 silly gunzTarPerm extractEntry example/resize.js +6705 silly gunzTarPerm extractEntry example/cursor.js +6706 silly gunzTarPerm extractEntry example/http_spin.js +6707 silly gunzTarPerm extractEntry example/spin.js +6708 silly gunzTarPerm extractEntry lib/encode.js +6709 silly gunzTarPerm extractEntry README.markdown +6710 verbose readDependencies using package.json deps +6711 silly resolved [] +6712 verbose about to build /usr/lib/node_modules/myth/node_modules/rework-import/node_modules/parse-import +6713 error Error: Cannot find module '/usr/lib/node_modules/npm/lib/build.js' +6713 error at Function.Module._resolveFilename (module.js:338:15) +6713 error at Function.Module._load (module.js:280:25) +6713 error at Module.require (module.js:364:17) +6713 error at require (module.js:380:17) +6713 error at Object.defineProperty.get (/usr/lib/node_modules/npm/lib/npm.js:197:15) +6713 error at /usr/lib/node_modules/npm/lib/install.js:948:18 +6713 error at asyncMap (/usr/lib/node_modules/npm/node_modules/slide/lib/async-map.js:27:18) +6713 error at /usr/lib/node_modules/npm/lib/install.js:600:7 +6713 error at asyncMap (/usr/lib/node_modules/npm/node_modules/slide/lib/async-map.js:27:18) +6713 error at /usr/lib/node_modules/npm/lib/install.js:579:5 +6714 error If you need help, you may report this *entire* log, +6714 error including the npm and node versions, at: +6714 error +6715 error System Linux 3.14.14-gentoo +6716 error command "/usr/bin/node" "/usr/bin/npm" "update" "-g" +6717 error cwd /var/www/htdocs/dev.timshomepage.net/node-task +6718 error node -v v0.10.32 +6719 error npm -v 1.4.28 +6720 error code MODULE_NOT_FOUND +6721 verbose exit [ 1, true ] diff --git a/package.json b/package.json new file mode 100644 index 0000000..1b7c21c --- /dev/null +++ b/package.json @@ -0,0 +1,20 @@ +{ + "name": "node-task", + "version": "0.0.0", + "private": true, + "scripts": { + "start": "node ./bin/www" + }, + "dependencies": { + "express": "~4.9.0", + "body-parser": "~1.8.1", + "cookie-parser": "~1.3.3", + "morgan": "~1.3.0", + "serve-favicon": "~2.1.3", + "debug": "~2.0.0", + "dust":"*", + "nodeunit":"*", + "mysql":"*", + "node-memcache":"*" + } +} \ No newline at end of file diff --git a/public/stylesheets/style.css b/public/stylesheets/style.css new file mode 100644 index 0000000..30e047d --- /dev/null +++ b/public/stylesheets/style.css @@ -0,0 +1,8 @@ +body { + padding: 50px; + font: 14px "Lucida Grande", Helvetica, Arial, sans-serif; +} + +a { + color: #00B7FF; +} \ No newline at end of file diff --git a/routes/index.js b/routes/index.js new file mode 100644 index 0000000..896c948 --- /dev/null +++ b/routes/index.js @@ -0,0 +1,9 @@ +var express = require('express'); +var router = express.Router(); + +/* GET home page. */ +router.get('/', function(req, res) { + res.render('index', { title: 'Express' }); +}); + +module.exports = router; diff --git a/routes/users.js b/routes/users.js new file mode 100644 index 0000000..c00d7de --- /dev/null +++ b/routes/users.js @@ -0,0 +1,9 @@ +var express = require('express'); +var router = express.Router(); + +/* GET users listing. */ +router.get('/', function(req, res) { + res.send('respond with a resource'); +}); + +module.exports = router; diff --git a/views/error.jade b/views/error.jade new file mode 100644 index 0000000..51ec12c --- /dev/null +++ b/views/error.jade @@ -0,0 +1,6 @@ +extends layout + +block content + h1= message + h2= error.status + pre #{error.stack} diff --git a/views/index.jade b/views/index.jade new file mode 100644 index 0000000..3d63b9a --- /dev/null +++ b/views/index.jade @@ -0,0 +1,5 @@ +extends layout + +block content + h1= title + p Welcome to #{title} diff --git a/views/layout.jade b/views/layout.jade new file mode 100644 index 0000000..b945f57 --- /dev/null +++ b/views/layout.jade @@ -0,0 +1,7 @@ +doctype html +html + head + title= title + link(rel='stylesheet', href='/stylesheets/style.css') + body + block content \ No newline at end of file