updated cordova-common dependnecy to 1.1.0

This commit is contained in:
Steve Gill 2016-02-24 09:50:07 -08:00
parent ce2525d4d8
commit 1d7ccaece6
696 changed files with 3515 additions and 1715 deletions

1
node_modules/.bin/jasmine-node generated vendored
View File

@ -1 +0,0 @@
../jasmine-node/bin/jasmine-node

1
node_modules/.bin/jshint generated vendored
View File

@ -1 +0,0 @@
../jshint/bin/jshint

View File

@ -1,48 +1,74 @@
{
"name": "abbrev",
"version": "1.0.7",
"description": "Like ruby's abbrev module, but in js",
"_args": [
[
"abbrev@1",
"/Users/steveng/repo/cordova/cordova-android/node_modules/nopt"
]
],
"_from": "abbrev@>=1.0.0 <2.0.0",
"_id": "abbrev@1.0.7",
"_inCache": true,
"_installable": true,
"_location": "/abbrev",
"_nodeVersion": "2.0.1",
"_npmUser": {
"email": "isaacs@npmjs.com",
"name": "isaacs"
},
"_npmVersion": "2.10.1",
"_phantomChildren": {},
"_requested": {
"name": "abbrev",
"raw": "abbrev@1",
"rawSpec": "1",
"scope": null,
"spec": ">=1.0.0 <2.0.0",
"type": "range"
},
"_requiredBy": [
"/nopt"
],
"_resolved": "http://registry.npmjs.org/abbrev/-/abbrev-1.0.7.tgz",
"_shasum": "5b6035b2ee9d4fb5cf859f08a9be81b208491843",
"_shrinkwrap": null,
"_spec": "abbrev@1",
"_where": "/Users/steveng/repo/cordova/cordova-android/node_modules/nopt",
"author": {
"name": "Isaac Z. Schlueter",
"email": "i@izs.me"
"email": "i@izs.me",
"name": "Isaac Z. Schlueter"
},
"main": "abbrev.js",
"scripts": {
"test": "tap test.js --cov"
},
"repository": {
"type": "git",
"url": "git+ssh://git@github.com/isaacs/abbrev-js.git"
},
"license": "ISC",
"devDependencies": {
"tap": "^1.2.0"
},
"gitHead": "821d09ce7da33627f91bbd8ed631497ed6f760c2",
"bugs": {
"url": "https://github.com/isaacs/abbrev-js/issues"
},
"homepage": "https://github.com/isaacs/abbrev-js#readme",
"_id": "abbrev@1.0.7",
"_shasum": "5b6035b2ee9d4fb5cf859f08a9be81b208491843",
"_from": "abbrev@>=1.0.0 <2.0.0",
"_npmVersion": "2.10.1",
"_nodeVersion": "2.0.1",
"_npmUser": {
"name": "isaacs",
"email": "isaacs@npmjs.com"
"dependencies": {},
"description": "Like ruby's abbrev module, but in js",
"devDependencies": {
"tap": "^1.2.0"
},
"directories": {},
"dist": {
"shasum": "5b6035b2ee9d4fb5cf859f08a9be81b208491843",
"tarball": "http://registry.npmjs.org/abbrev/-/abbrev-1.0.7.tgz"
},
"gitHead": "821d09ce7da33627f91bbd8ed631497ed6f760c2",
"homepage": "https://github.com/isaacs/abbrev-js#readme",
"license": "ISC",
"main": "abbrev.js",
"maintainers": [
{
"name": "isaacs",
"email": "i@izs.me"
}
],
"directories": {},
"_resolved": "http://registry.npmjs.org/abbrev/-/abbrev-1.0.7.tgz",
"readme": "ERROR: No README data found!"
"name": "abbrev",
"optionalDependencies": {},
"readme": "ERROR: No README data found!",
"repository": {
"type": "git",
"url": "git+ssh://git@github.com/isaacs/abbrev-js.git"
},
"scripts": {
"test": "tap test.js --cov"
},
"version": "1.0.7"
}

4
node_modules/ansi/.jshintrc generated vendored Normal file
View File

@ -0,0 +1,4 @@
{
"laxcomma": true,
"asi": true
}

23
node_modules/ansi/History.md generated vendored Normal file
View File

@ -0,0 +1,23 @@
0.3.1 / 2016-01-14
==================
* add MIT LICENSE file (#23, @kasicka)
* preserve chaining after redundant style-method calls (#19, @drewblaisdell)
* package: add "license" field (#16, @BenjaminTsai)
0.3.0 / 2014-05-09
==================
* package: remove "test" script and "devDependencies"
* package: remove "engines" section
* pacakge: remove "bin" section
* package: beautify
* examples: remove `starwars` example (#15)
* Documented goto, horizontalAbsolute, and eraseLine methods in README.md (#12, @Jammerwoch)
* add `.jshintrc` file
< 0.3.0
=======
* Prehistoric

24
node_modules/ansi/LICENSE generated vendored Normal file
View File

@ -0,0 +1,24 @@
(The MIT License)
Copyright (c) 2012 Nathan Rajlich <nathan@tootallnate.net>
Permission is hereby granted, free of charge, to any person
obtaining a copy of this software and associated documentation
files (the "Software"), to deal in the Software without
restriction, including without limitation the rights to use,
copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following
conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
OTHER DEALINGS IN THE SOFTWARE.

98
node_modules/ansi/README.md generated vendored Normal file
View File

@ -0,0 +1,98 @@
ansi.js
=========
### Advanced ANSI formatting tool for Node.js
`ansi.js` is a module for Node.js that provides an easy-to-use API for
writing ANSI escape codes to `Stream` instances. ANSI escape codes are used to do
fancy things in a terminal window, like render text in colors, delete characters,
lines, the entire window, or hide and show the cursor, and lots more!
#### Features:
* 256 color support for the terminal!
* Make a beep sound from your terminal!
* Works with *any* writable `Stream` instance.
* Allows you to move the cursor anywhere on the terminal window.
* Allows you to delete existing contents from the terminal window.
* Allows you to hide and show the cursor.
* Converts CSS color codes and RGB values into ANSI escape codes.
* Low-level; you are in control of when escape codes are used, it's not abstracted.
Installation
------------
Install with `npm`:
``` bash
$ npm install ansi
```
Example
-------
``` js
var ansi = require('ansi')
, cursor = ansi(process.stdout)
// You can chain your calls forever:
cursor
.red() // Set font color to red
.bg.grey() // Set background color to grey
.write('Hello World!') // Write 'Hello World!' to stdout
.bg.reset() // Reset the bgcolor before writing the trailing \n,
// to avoid Terminal glitches
.write('\n') // And a final \n to wrap things up
// Rendering modes are persistent:
cursor.hex('#660000').bold().underline()
// You can use the regular logging functions, text will be green:
console.log('This is blood red, bold text')
// To reset just the foreground color:
cursor.fg.reset()
console.log('This will still be bold')
// to go to a location (x,y) on the console
// note: 1-indexed, not 0-indexed:
cursor.goto(10, 5).write('Five down, ten over')
// to clear the current line:
cursor.horizontalAbsolute(0).eraseLine().write('Starting again')
// to go to a different column on the current line:
cursor.horizontalAbsolute(5).write('column five')
// Clean up after yourself!
cursor.reset()
```
License
-------
(The MIT License)
Copyright (c) 2012 Nathan Rajlich &lt;nathan@tootallnate.net&gt;
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.

16
node_modules/ansi/examples/beep/index.js generated vendored Executable file
View File

@ -0,0 +1,16 @@
#!/usr/bin/env node
/**
* Invokes the terminal "beep" sound once per second on every exact second.
*/
process.title = 'beep'
var cursor = require('../../')(process.stdout)
function beep () {
cursor.beep()
setTimeout(beep, 1000 - (new Date()).getMilliseconds())
}
setTimeout(beep, 1000 - (new Date()).getMilliseconds())

15
node_modules/ansi/examples/clear/index.js generated vendored Executable file
View File

@ -0,0 +1,15 @@
#!/usr/bin/env node
/**
* Like GNU ncurses "clear" command.
* https://github.com/mscdex/node-ncurses/blob/master/deps/ncurses/progs/clear.c
*/
process.title = 'clear'
function lf () { return '\n' }
require('../../')(process.stdout)
.write(Array.apply(null, Array(process.stdout.getWindowSize()[1])).map(lf).join(''))
.eraseData(2)
.goto(1, 1)

32
node_modules/ansi/examples/cursorPosition.js generated vendored Executable file
View File

@ -0,0 +1,32 @@
#!/usr/bin/env node
var tty = require('tty')
var cursor = require('../')(process.stdout)
// listen for the queryPosition report on stdin
process.stdin.resume()
raw(true)
process.stdin.once('data', function (b) {
var match = /\[(\d+)\;(\d+)R$/.exec(b.toString())
if (match) {
var xy = match.slice(1, 3).reverse().map(Number)
console.error(xy)
}
// cleanup and close stdin
raw(false)
process.stdin.pause()
})
// send the query position request code to stdout
cursor.queryPosition()
function raw (mode) {
if (process.stdin.setRawMode) {
process.stdin.setRawMode(mode)
} else {
tty.setRawMode(mode)
}
}

87
node_modules/ansi/examples/progress/index.js generated vendored Normal file
View File

@ -0,0 +1,87 @@
#!/usr/bin/env node
var assert = require('assert')
, ansi = require('../../')
function Progress (stream, width) {
this.cursor = ansi(stream)
this.delta = this.cursor.newlines
this.width = width | 0 || 10
this.open = '['
this.close = ']'
this.complete = '█'
this.incomplete = '_'
// initial render
this.progress = 0
}
Object.defineProperty(Progress.prototype, 'progress', {
get: get
, set: set
, configurable: true
, enumerable: true
})
function get () {
return this._progress
}
function set (v) {
this._progress = Math.max(0, Math.min(v, 100))
var w = this.width - this.complete.length - this.incomplete.length
, n = w * (this._progress / 100) | 0
, i = w - n
, com = c(this.complete, n)
, inc = c(this.incomplete, i)
, delta = this.cursor.newlines - this.delta
assert.equal(com.length + inc.length, w)
if (delta > 0) {
this.cursor.up(delta)
this.delta = this.cursor.newlines
}
this.cursor
.horizontalAbsolute(0)
.eraseLine(2)
.fg.white()
.write(this.open)
.fg.grey()
.bold()
.write(com)
.resetBold()
.write(inc)
.fg.white()
.write(this.close)
.fg.reset()
.write('\n')
}
function c (char, length) {
return Array.apply(null, Array(length)).map(function () {
return char
}).join('')
}
// Usage
var width = parseInt(process.argv[2], 10) || process.stdout.getWindowSize()[0] / 2
, p = new Progress(process.stdout, width)
;(function tick () {
p.progress += Math.random() * 5
p.cursor
.eraseLine(2)
.write('Progress: ')
.bold().write(p.progress.toFixed(2))
.write('%')
.resetBold()
.write('\n')
if (p.progress < 100)
setTimeout(tick, 100)
})()

405
node_modules/ansi/lib/ansi.js generated vendored Normal file
View File

@ -0,0 +1,405 @@
/**
* References:
*
* - http://en.wikipedia.org/wiki/ANSI_escape_code
* - http://www.termsys.demon.co.uk/vtansi.htm
*
*/
/**
* Module dependencies.
*/
var emitNewlineEvents = require('./newlines')
, prefix = '\x1b[' // For all escape codes
, suffix = 'm' // Only for color codes
/**
* The ANSI escape sequences.
*/
var codes = {
up: 'A'
, down: 'B'
, forward: 'C'
, back: 'D'
, nextLine: 'E'
, previousLine: 'F'
, horizontalAbsolute: 'G'
, eraseData: 'J'
, eraseLine: 'K'
, scrollUp: 'S'
, scrollDown: 'T'
, savePosition: 's'
, restorePosition: 'u'
, queryPosition: '6n'
, hide: '?25l'
, show: '?25h'
}
/**
* Rendering ANSI codes.
*/
var styles = {
bold: 1
, italic: 3
, underline: 4
, inverse: 7
}
/**
* The negating ANSI code for the rendering modes.
*/
var reset = {
bold: 22
, italic: 23
, underline: 24
, inverse: 27
}
/**
* The standard, styleable ANSI colors.
*/
var colors = {
white: 37
, black: 30
, blue: 34
, cyan: 36
, green: 32
, magenta: 35
, red: 31
, yellow: 33
, grey: 90
, brightBlack: 90
, brightRed: 91
, brightGreen: 92
, brightYellow: 93
, brightBlue: 94
, brightMagenta: 95
, brightCyan: 96
, brightWhite: 97
}
/**
* Creates a Cursor instance based off the given `writable stream` instance.
*/
function ansi (stream, options) {
if (stream._ansicursor) {
return stream._ansicursor
} else {
return stream._ansicursor = new Cursor(stream, options)
}
}
module.exports = exports = ansi
/**
* The `Cursor` class.
*/
function Cursor (stream, options) {
if (!(this instanceof Cursor)) {
return new Cursor(stream, options)
}
if (typeof stream != 'object' || typeof stream.write != 'function') {
throw new Error('a valid Stream instance must be passed in')
}
// the stream to use
this.stream = stream
// when 'enabled' is false then all the functions are no-ops except for write()
this.enabled = options && options.enabled
if (typeof this.enabled === 'undefined') {
this.enabled = stream.isTTY
}
this.enabled = !!this.enabled
// then `buffering` is true, then `write()` calls are buffered in
// memory until `flush()` is invoked
this.buffering = !!(options && options.buffering)
this._buffer = []
// controls the foreground and background colors
this.fg = this.foreground = new Colorer(this, 0)
this.bg = this.background = new Colorer(this, 10)
// defaults
this.Bold = false
this.Italic = false
this.Underline = false
this.Inverse = false
// keep track of the number of "newlines" that get encountered
this.newlines = 0
emitNewlineEvents(stream)
stream.on('newline', function () {
this.newlines++
}.bind(this))
}
exports.Cursor = Cursor
/**
* Helper function that calls `write()` on the underlying Stream.
* Returns `this` instead of the write() return value to keep
* the chaining going.
*/
Cursor.prototype.write = function (data) {
if (this.buffering) {
this._buffer.push(arguments)
} else {
this.stream.write.apply(this.stream, arguments)
}
return this
}
/**
* Buffer `write()` calls into memory.
*
* @api public
*/
Cursor.prototype.buffer = function () {
this.buffering = true
return this
}
/**
* Write out the in-memory buffer.
*
* @api public
*/
Cursor.prototype.flush = function () {
this.buffering = false
var str = this._buffer.map(function (args) {
if (args.length != 1) throw new Error('unexpected args length! ' + args.length);
return args[0];
}).join('');
this._buffer.splice(0); // empty
this.write(str);
return this
}
/**
* The `Colorer` class manages both the background and foreground colors.
*/
function Colorer (cursor, base) {
this.current = null
this.cursor = cursor
this.base = base
}
exports.Colorer = Colorer
/**
* Write an ANSI color code, ensuring that the same code doesn't get rewritten.
*/
Colorer.prototype._setColorCode = function setColorCode (code) {
var c = String(code)
if (this.current === c) return
this.cursor.enabled && this.cursor.write(prefix + c + suffix)
this.current = c
return this
}
/**
* Set up the positional ANSI codes.
*/
Object.keys(codes).forEach(function (name) {
var code = String(codes[name])
Cursor.prototype[name] = function () {
var c = code
if (arguments.length > 0) {
c = toArray(arguments).map(Math.round).join(';') + code
}
this.enabled && this.write(prefix + c)
return this
}
})
/**
* Set up the functions for the rendering ANSI codes.
*/
Object.keys(styles).forEach(function (style) {
var name = style[0].toUpperCase() + style.substring(1)
, c = styles[style]
, r = reset[style]
Cursor.prototype[style] = function () {
if (this[name]) return this
this.enabled && this.write(prefix + c + suffix)
this[name] = true
return this
}
Cursor.prototype['reset' + name] = function () {
if (!this[name]) return this
this.enabled && this.write(prefix + r + suffix)
this[name] = false
return this
}
})
/**
* Setup the functions for the standard colors.
*/
Object.keys(colors).forEach(function (color) {
var code = colors[color]
Colorer.prototype[color] = function () {
this._setColorCode(this.base + code)
return this.cursor
}
Cursor.prototype[color] = function () {
return this.foreground[color]()
}
})
/**
* Makes a beep sound!
*/
Cursor.prototype.beep = function () {
this.enabled && this.write('\x07')
return this
}
/**
* Moves cursor to specific position
*/
Cursor.prototype.goto = function (x, y) {
x = x | 0
y = y | 0
this.enabled && this.write(prefix + y + ';' + x + 'H')
return this
}
/**
* Resets the color.
*/
Colorer.prototype.reset = function () {
this._setColorCode(this.base + 39)
return this.cursor
}
/**
* Resets all ANSI formatting on the stream.
*/
Cursor.prototype.reset = function () {
this.enabled && this.write(prefix + '0' + suffix)
this.Bold = false
this.Italic = false
this.Underline = false
this.Inverse = false
this.foreground.current = null
this.background.current = null
return this
}
/**
* Sets the foreground color with the given RGB values.
* The closest match out of the 216 colors is picked.
*/
Colorer.prototype.rgb = function (r, g, b) {
var base = this.base + 38
, code = rgb(r, g, b)
this._setColorCode(base + ';5;' + code)
return this.cursor
}
/**
* Same as `cursor.fg.rgb(r, g, b)`.
*/
Cursor.prototype.rgb = function (r, g, b) {
return this.foreground.rgb(r, g, b)
}
/**
* Accepts CSS color codes for use with ANSI escape codes.
* For example: `#FF000` would be bright red.
*/
Colorer.prototype.hex = function (color) {
return this.rgb.apply(this, hex(color))
}
/**
* Same as `cursor.fg.hex(color)`.
*/
Cursor.prototype.hex = function (color) {
return this.foreground.hex(color)
}
// UTIL FUNCTIONS //
/**
* Translates a 255 RGB value to a 0-5 ANSI RGV value,
* then returns the single ANSI color code to use.
*/
function rgb (r, g, b) {
var red = r / 255 * 5
, green = g / 255 * 5
, blue = b / 255 * 5
return rgb5(red, green, blue)
}
/**
* Turns rgb 0-5 values into a single ANSI color code to use.
*/
function rgb5 (r, g, b) {
var red = Math.round(r)
, green = Math.round(g)
, blue = Math.round(b)
return 16 + (red*36) + (green*6) + blue
}
/**
* Accepts a hex CSS color code string (# is optional) and
* translates it into an Array of 3 RGB 0-255 values, which
* can then be used with rgb().
*/
function hex (color) {
var c = color[0] === '#' ? color.substring(1) : color
, r = c.substring(0, 2)
, g = c.substring(2, 4)
, b = c.substring(4, 6)
return [parseInt(r, 16), parseInt(g, 16), parseInt(b, 16)]
}
/**
* Turns an array-like object into a real array.
*/
function toArray (a) {
var i = 0
, l = a.length
, rtn = []
for (; i<l; i++) {
rtn.push(a[i])
}
return rtn
}

71
node_modules/ansi/lib/newlines.js generated vendored Normal file
View File

@ -0,0 +1,71 @@
/**
* Accepts any node Stream instance and hijacks its "write()" function,
* so that it can count any newlines that get written to the output.
*
* When a '\n' byte is encountered, then a "newline" event will be emitted
* on the stream, with no arguments. It is up to the listeners to determine
* any necessary deltas required for their use-case.
*
* Ex:
*
* var cursor = ansi(process.stdout)
* , ln = 0
* process.stdout.on('newline', function () {
* ln++
* })
*/
/**
* Module dependencies.
*/
var assert = require('assert')
var NEWLINE = '\n'.charCodeAt(0)
function emitNewlineEvents (stream) {
if (stream._emittingNewlines) {
// already emitting newline events
return
}
var write = stream.write
stream.write = function (data) {
// first write the data
var rtn = write.apply(stream, arguments)
if (stream.listeners('newline').length > 0) {
var len = data.length
, i = 0
// now try to calculate any deltas
if (typeof data == 'string') {
for (; i<len; i++) {
processByte(stream, data.charCodeAt(i))
}
} else {
// buffer
for (; i<len; i++) {
processByte(stream, data[i])
}
}
}
return rtn
}
stream._emittingNewlines = true
}
module.exports = emitNewlineEvents
/**
* Processes an individual byte being written to a stream
*/
function processByte (stream, b) {
assert.equal(typeof b, 'number')
if (b === NEWLINE) {
stream.emit('newline')
}
}

85
node_modules/ansi/package.json generated vendored Normal file
View File

@ -0,0 +1,85 @@
{
"_args": [
[
"ansi@^0.3.1",
"/Users/steveng/repo/cordova/cordova-android/node_modules/cordova-common"
]
],
"_from": "ansi@>=0.3.1 <0.4.0",
"_id": "ansi@0.3.1",
"_inCache": true,
"_installable": true,
"_location": "/ansi",
"_nodeVersion": "5.3.0",
"_npmUser": {
"email": "nathan@tootallnate.net",
"name": "tootallnate"
},
"_npmVersion": "3.3.12",
"_phantomChildren": {},
"_requested": {
"name": "ansi",
"raw": "ansi@^0.3.1",
"rawSpec": "^0.3.1",
"scope": null,
"spec": ">=0.3.1 <0.4.0",
"type": "range"
},
"_requiredBy": [
"/cordova-common"
],
"_resolved": "http://registry.npmjs.org/ansi/-/ansi-0.3.1.tgz",
"_shasum": "0c42d4fb17160d5a9af1e484bace1c66922c1b21",
"_shrinkwrap": null,
"_spec": "ansi@^0.3.1",
"_where": "/Users/steveng/repo/cordova/cordova-android/node_modules/cordova-common",
"author": {
"email": "nathan@tootallnate.net",
"name": "Nathan Rajlich",
"url": "http://tootallnate.net"
},
"bugs": {
"url": "https://github.com/TooTallNate/ansi.js/issues"
},
"dependencies": {},
"description": "Advanced ANSI formatting tool for Node.js",
"devDependencies": {},
"directories": {},
"dist": {
"shasum": "0c42d4fb17160d5a9af1e484bace1c66922c1b21",
"tarball": "http://registry.npmjs.org/ansi/-/ansi-0.3.1.tgz"
},
"gitHead": "4d0d4af94e0bdaa648bd7262acd3bde4b98d5246",
"homepage": "https://github.com/TooTallNate/ansi.js#readme",
"keywords": [
"256",
"ansi",
"color",
"cursor",
"formatting",
"rgb",
"stream",
"terminal"
],
"license": "MIT",
"main": "./lib/ansi.js",
"maintainers": [
{
"name": "TooTallNate",
"email": "nathan@tootallnate.net"
},
{
"name": "tootallnate",
"email": "nathan@tootallnate.net"
}
],
"name": "ansi",
"optionalDependencies": {},
"readme": "ERROR: No README data found!",
"repository": {
"type": "git",
"url": "git://github.com/TooTallNate/ansi.js.git"
},
"scripts": {},
"version": "0.3.1"
}

View File

@ -1,73 +1,98 @@
{
"name": "balanced-match",
"description": "Match balanced character pairs, like \"{\" and \"}\"",
"version": "0.3.0",
"repository": {
"type": "git",
"url": "git://github.com/juliangruber/balanced-match.git"
},
"homepage": "https://github.com/juliangruber/balanced-match",
"main": "index.js",
"scripts": {
"test": "make test"
},
"dependencies": {},
"devDependencies": {
"tape": "~4.2.2"
},
"keywords": [
"match",
"regexp",
"test",
"balanced",
"parse"
"_args": [
[
"balanced-match@^0.3.0",
"/Users/steveng/repo/cordova/cordova-android/node_modules/brace-expansion"
]
],
"_from": "balanced-match@>=0.3.0 <0.4.0",
"_id": "balanced-match@0.3.0",
"_inCache": true,
"_installable": true,
"_location": "/balanced-match",
"_nodeVersion": "4.2.1",
"_npmUser": {
"email": "julian@juliangruber.com",
"name": "juliangruber"
},
"_npmVersion": "2.14.7",
"_phantomChildren": {},
"_requested": {
"name": "balanced-match",
"raw": "balanced-match@^0.3.0",
"rawSpec": "^0.3.0",
"scope": null,
"spec": ">=0.3.0 <0.4.0",
"type": "range"
},
"_requiredBy": [
"/brace-expansion"
],
"_resolved": "http://registry.npmjs.org/balanced-match/-/balanced-match-0.3.0.tgz",
"_shasum": "a91cdd1ebef1a86659e70ff4def01625fc2d6756",
"_shrinkwrap": null,
"_spec": "balanced-match@^0.3.0",
"_where": "/Users/steveng/repo/cordova/cordova-android/node_modules/brace-expansion",
"author": {
"name": "Julian Gruber",
"email": "mail@juliangruber.com",
"name": "Julian Gruber",
"url": "http://juliangruber.com"
},
"license": "MIT",
"testling": {
"files": "test/*.js",
"browsers": [
"ie/8..latest",
"firefox/20..latest",
"firefox/nightly",
"chrome/25..latest",
"chrome/canary",
"opera/12..latest",
"opera/next",
"safari/5.1..latest",
"ipad/6.0..latest",
"iphone/6.0..latest",
"android-browser/4.2..latest"
]
},
"gitHead": "a7114b0986554787e90b7ac595a043ca75ea77e5",
"bugs": {
"url": "https://github.com/juliangruber/balanced-match/issues"
},
"_id": "balanced-match@0.3.0",
"_shasum": "a91cdd1ebef1a86659e70ff4def01625fc2d6756",
"_from": "balanced-match@>=0.3.0 <0.4.0",
"_npmVersion": "2.14.7",
"_nodeVersion": "4.2.1",
"_npmUser": {
"name": "juliangruber",
"email": "julian@juliangruber.com"
"dependencies": {},
"description": "Match balanced character pairs, like \"{\" and \"}\"",
"devDependencies": {
"tape": "~4.2.2"
},
"directories": {},
"dist": {
"shasum": "a91cdd1ebef1a86659e70ff4def01625fc2d6756",
"tarball": "http://registry.npmjs.org/balanced-match/-/balanced-match-0.3.0.tgz"
},
"gitHead": "a7114b0986554787e90b7ac595a043ca75ea77e5",
"homepage": "https://github.com/juliangruber/balanced-match",
"keywords": [
"balanced",
"match",
"parse",
"regexp",
"test"
],
"license": "MIT",
"main": "index.js",
"maintainers": [
{
"name": "juliangruber",
"email": "julian@juliangruber.com"
}
],
"directories": {},
"_resolved": "http://registry.npmjs.org/balanced-match/-/balanced-match-0.3.0.tgz",
"readme": "ERROR: No README data found!"
"name": "balanced-match",
"optionalDependencies": {},
"readme": "ERROR: No README data found!",
"repository": {
"type": "git",
"url": "git://github.com/juliangruber/balanced-match.git"
},
"scripts": {
"test": "make test"
},
"testling": {
"browsers": [
"android-browser/4.2..latest",
"chrome/25..latest",
"chrome/canary",
"firefox/20..latest",
"firefox/nightly",
"ie/8..latest",
"ipad/6.0..latest",
"iphone/6.0..latest",
"opera/12..latest",
"opera/next",
"safari/5.1..latest"
],
"files": "test/*.js"
},
"version": "0.3.0"
}

View File

@ -1,53 +1,62 @@
{
"author": {
"name": "T. Jameson Little",
"email": "t.jameson.little@gmail.com"
},
"name": "base64-js",
"description": "Base64 encoding/decoding in pure JS",
"version": "0.0.8",
"repository": {
"type": "git",
"url": "git://github.com/beatgammit/base64-js.git"
},
"main": "lib/b64.js",
"scripts": {
"test": "tape test/*.js"
},
"testling": {
"files": "test/*.js",
"browsers": [
"ie/6..latest",
"chrome/4..latest",
"firefox/3..latest",
"safari/5.1..latest",
"opera/11.0..latest",
"iphone/6",
"ipad/6"
"_args": [
[
"base64-js@0.0.8",
"/Users/steveng/repo/cordova/cordova-android/node_modules/plist"
]
],
"_from": "base64-js@0.0.8",
"_id": "base64-js@0.0.8",
"_inCache": true,
"_installable": true,
"_location": "/base64-js",
"_nodeVersion": "0.10.35",
"_npmUser": {
"email": "feross@feross.org",
"name": "feross"
},
"_npmVersion": "2.1.16",
"_phantomChildren": {},
"_requested": {
"name": "base64-js",
"raw": "base64-js@0.0.8",
"rawSpec": "0.0.8",
"scope": null,
"spec": "0.0.8",
"type": "version"
},
"_requiredBy": [
"/plist"
],
"_resolved": "http://registry.npmjs.org/base64-js/-/base64-js-0.0.8.tgz",
"_shasum": "1101e9544f4a76b1bc3b26d452ca96d7a35e7978",
"_shrinkwrap": null,
"_spec": "base64-js@0.0.8",
"_where": "/Users/steveng/repo/cordova/cordova-android/node_modules/plist",
"author": {
"email": "t.jameson.little@gmail.com",
"name": "T. Jameson Little"
},
"bugs": {
"url": "https://github.com/beatgammit/base64-js/issues"
},
"dependencies": {},
"description": "Base64 encoding/decoding in pure JS",
"devDependencies": {
"tape": "~2.3.2"
},
"directories": {},
"dist": {
"shasum": "1101e9544f4a76b1bc3b26d452ca96d7a35e7978",
"tarball": "http://registry.npmjs.org/base64-js/-/base64-js-0.0.8.tgz"
},
"engines": {
"node": ">= 0.4"
},
"license": "MIT",
"dependencies": {},
"devDependencies": {
"tape": "~2.3.2"
},
"gitHead": "b4a8a5fa9b0caeddb5ad94dd1108253d8f2a315f",
"bugs": {
"url": "https://github.com/beatgammit/base64-js/issues"
},
"homepage": "https://github.com/beatgammit/base64-js",
"_id": "base64-js@0.0.8",
"_shasum": "1101e9544f4a76b1bc3b26d452ca96d7a35e7978",
"_from": "base64-js@0.0.8",
"_npmVersion": "2.1.16",
"_nodeVersion": "0.10.35",
"_npmUser": {
"name": "feross",
"email": "feross@feross.org"
},
"license": "MIT",
"main": "lib/b64.js",
"maintainers": [
{
"name": "beatgammit",
@ -58,11 +67,27 @@
"email": "feross@feross.org"
}
],
"dist": {
"shasum": "1101e9544f4a76b1bc3b26d452ca96d7a35e7978",
"tarball": "http://registry.npmjs.org/base64-js/-/base64-js-0.0.8.tgz"
"name": "base64-js",
"optionalDependencies": {},
"readme": "ERROR: No README data found!",
"repository": {
"type": "git",
"url": "git://github.com/beatgammit/base64-js.git"
},
"directories": {},
"_resolved": "http://registry.npmjs.org/base64-js/-/base64-js-0.0.8.tgz",
"readme": "ERROR: No README data found!"
"scripts": {
"test": "tape test/*.js"
},
"testling": {
"browsers": [
"chrome/4..latest",
"firefox/3..latest",
"ie/6..latest",
"ipad/6",
"iphone/6",
"opera/11.0..latest",
"safari/5.1..latest"
],
"files": "test/*.js"
},
"version": "0.0.8"
}

View File

@ -294,7 +294,7 @@ var bigInt = (function (undefined) {
function multiplyKaratsuba(x, y) {
var n = Math.max(x.length, y.length);
if (n <= 400) return multiplyLong(x, y);
if (n <= 30) return multiplyLong(x, y);
n = Math.ceil(n / 2);
var b = x.slice(n),
@ -306,7 +306,15 @@ var bigInt = (function (undefined) {
bd = multiplyKaratsuba(b, d),
abcd = multiplyKaratsuba(addAny(a, b), addAny(c, d));
return addAny(addAny(ac, shiftLeft(subtract(subtract(abcd, ac), bd), n)), shiftLeft(bd, 2 * n));
var product = addAny(addAny(ac, shiftLeft(subtract(subtract(abcd, ac), bd), n)), shiftLeft(bd, 2 * n));
trim(product);
return product;
}
// The following function is derived from a surface fit of a graph plotting the performance difference
// between long multiplication and karatsuba multiplication versus the lengths of the two arrays.
function useKaratsuba(l1, l2) {
return -0.012 * l1 - 0.012 * l2 + 0.000015 * l1 * l2 > 0;
}
BigInteger.prototype.multiply = function (v) {
@ -324,7 +332,7 @@ var bigInt = (function (undefined) {
}
b = smallToArray(abs);
}
if (a.length + b.length > 4000) // Karatsuba is only faster for sufficiently large inputs
if (useKaratsuba(a.length, b.length)) // Karatsuba is only faster for certain array sizes
return new BigInteger(multiplyKaratsuba(a, b), sign);
return new BigInteger(multiplyLong(a, b), sign);
};

1
node_modules/big-integer/BigInteger.min.js generated vendored Normal file

File diff suppressed because one or more lines are too long

View File

@ -1,32 +1,53 @@
{
"name": "big-integer",
"version": "1.6.10",
"author": {
"name": "Peter Olson",
"email": "peter.e.c.olson+npm@gmail.com"
},
"description": "An arbitrary length integer library for Javascript",
"contributors": [],
"bin": {},
"scripts": {
"test": "karma start my.conf.js"
},
"main": "./BigInteger",
"repository": {
"type": "git",
"url": "git+ssh://git@github.com/peterolson/BigInteger.js.git"
},
"keywords": [
"math",
"big",
"bignum",
"bigint",
"biginteger",
"integer",
"arbitrary",
"precision",
"arithmetic"
"_args": [
[
"big-integer@^1.6.7",
"/Users/steveng/repo/cordova/cordova-android/node_modules/bplist-parser"
]
],
"_from": "big-integer@>=1.6.7 <2.0.0",
"_id": "big-integer@1.6.12",
"_inCache": true,
"_installable": true,
"_location": "/big-integer",
"_nodeVersion": "0.12.3",
"_npmOperationalInternal": {
"host": "packages-6-west.internal.npmjs.com",
"tmp": "tmp/big-integer-1.6.12.tgz_1455702804335_0.11810904298909009"
},
"_npmUser": {
"email": "peter.e.c.olson+npm@gmail.com",
"name": "peterolson"
},
"_npmVersion": "2.9.1",
"_phantomChildren": {},
"_requested": {
"name": "big-integer",
"raw": "big-integer@^1.6.7",
"rawSpec": "^1.6.7",
"scope": null,
"spec": ">=1.6.7 <2.0.0",
"type": "range"
},
"_requiredBy": [
"/bplist-parser"
],
"_resolved": "http://registry.npmjs.org/big-integer/-/big-integer-1.6.12.tgz",
"_shasum": "39afcddafcd5c4480864efb757337d508938bb26",
"_shrinkwrap": null,
"_spec": "big-integer@^1.6.7",
"_where": "/Users/steveng/repo/cordova/cordova-android/node_modules/bplist-parser",
"author": {
"email": "peter.e.c.olson+npm@gmail.com",
"name": "Peter Olson"
},
"bin": {},
"bugs": {
"url": "https://github.com/peterolson/BigInteger.js/issues"
},
"contributors": [],
"dependencies": {},
"description": "An arbitrary length integer library for Javascript",
"devDependencies": {
"coveralls": "^2.11.4",
"jasmine": "2.1.x",
@ -36,35 +57,44 @@
"karma-jasmine": "^0.3.6",
"karma-phantomjs-launcher": "~0.1"
},
"license": "Unlicense",
"directories": {},
"dist": {
"shasum": "39afcddafcd5c4480864efb757337d508938bb26",
"tarball": "http://registry.npmjs.org/big-integer/-/big-integer-1.6.12.tgz"
},
"engines": {
"node": ">=0.6"
},
"gitHead": "e9a739fa1a15fe3da4eb302ea7072112ec91e318",
"bugs": {
"url": "https://github.com/peterolson/BigInteger.js/issues"
},
"gitHead": "56f449108e31542f939e701f1fe562a46e6c1fab",
"homepage": "https://github.com/peterolson/BigInteger.js#readme",
"_id": "big-integer@1.6.10",
"_shasum": "0f05dcce24278bc33bd8eb9297f4858acacb1fea",
"_from": "big-integer@>=1.6.7 <2.0.0",
"_npmVersion": "2.9.1",
"_nodeVersion": "0.12.3",
"_npmUser": {
"name": "peterolson",
"email": "peter.e.c.olson+npm@gmail.com"
},
"keywords": [
"arbitrary",
"arithmetic",
"big",
"bigint",
"biginteger",
"bignum",
"integer",
"math",
"precision"
],
"license": "Unlicense",
"main": "./BigInteger",
"maintainers": [
{
"name": "peterolson",
"email": "peter.e.c.olson+npm@gmail.com"
}
],
"dist": {
"shasum": "0f05dcce24278bc33bd8eb9297f4858acacb1fea",
"tarball": "http://registry.npmjs.org/big-integer/-/big-integer-1.6.10.tgz"
"name": "big-integer",
"optionalDependencies": {},
"readme": "ERROR: No README data found!",
"repository": {
"type": "git",
"url": "git+ssh://git@github.com/peterolson/BigInteger.js.git"
},
"directories": {},
"_resolved": "http://registry.npmjs.org/big-integer/-/big-integer-1.6.10.tgz",
"readme": "ERROR: No README data found!"
"scripts": {
"test": "karma start my.conf.js"
},
"version": "1.6.12"
}

View File

@ -1,56 +1,81 @@
{
"name": "bplist-parser",
"version": "0.1.1",
"description": "Binary plist parser.",
"main": "bplistParser.js",
"scripts": {
"test": "./node_modules/nodeunit/bin/nodeunit test"
},
"keywords": [
"bplist",
"plist",
"parser"
"_args": [
[
"bplist-parser@^0.1.0",
"/Users/steveng/repo/cordova/cordova-android/node_modules/cordova-common"
]
],
"_from": "bplist-parser@>=0.1.0 <0.2.0",
"_id": "bplist-parser@0.1.1",
"_inCache": true,
"_installable": true,
"_location": "/bplist-parser",
"_nodeVersion": "5.1.0",
"_npmUser": {
"email": "joe@fernsroth.com",
"name": "joeferner"
},
"_npmVersion": "3.4.0",
"_phantomChildren": {},
"_requested": {
"name": "bplist-parser",
"raw": "bplist-parser@^0.1.0",
"rawSpec": "^0.1.0",
"scope": null,
"spec": ">=0.1.0 <0.2.0",
"type": "range"
},
"_requiredBy": [
"/cordova-common"
],
"_resolved": "http://registry.npmjs.org/bplist-parser/-/bplist-parser-0.1.1.tgz",
"_shasum": "d60d5dcc20cba6dc7e1f299b35d3e1f95dafbae6",
"_shrinkwrap": null,
"_spec": "bplist-parser@^0.1.0",
"_where": "/Users/steveng/repo/cordova/cordova-android/node_modules/cordova-common",
"author": {
"name": "Joe Ferner",
"email": "joe.ferner@nearinfinity.com"
"email": "joe.ferner@nearinfinity.com",
"name": "Joe Ferner"
},
"license": "MIT",
"devDependencies": {
"nodeunit": "~0.9.1"
},
"repository": {
"type": "git",
"url": "git+https://github.com/nearinfinity/node-bplist-parser.git"
"bugs": {
"url": "https://github.com/nearinfinity/node-bplist-parser/issues"
},
"dependencies": {
"big-integer": "^1.6.7"
},
"gitHead": "c4f22650de2cc95edd21a6e609ff0654a2b951bd",
"bugs": {
"url": "https://github.com/nearinfinity/node-bplist-parser/issues"
},
"homepage": "https://github.com/nearinfinity/node-bplist-parser#readme",
"_id": "bplist-parser@0.1.1",
"_shasum": "d60d5dcc20cba6dc7e1f299b35d3e1f95dafbae6",
"_from": "bplist-parser@>=0.1.0 <0.2.0",
"_npmVersion": "3.4.0",
"_nodeVersion": "5.1.0",
"_npmUser": {
"name": "joeferner",
"email": "joe@fernsroth.com"
"description": "Binary plist parser.",
"devDependencies": {
"nodeunit": "~0.9.1"
},
"directories": {},
"dist": {
"shasum": "d60d5dcc20cba6dc7e1f299b35d3e1f95dafbae6",
"tarball": "http://registry.npmjs.org/bplist-parser/-/bplist-parser-0.1.1.tgz"
},
"gitHead": "c4f22650de2cc95edd21a6e609ff0654a2b951bd",
"homepage": "https://github.com/nearinfinity/node-bplist-parser#readme",
"keywords": [
"bplist",
"parser",
"plist"
],
"license": "MIT",
"main": "bplistParser.js",
"maintainers": [
{
"name": "joeferner",
"email": "joe@fernsroth.com"
}
],
"directories": {},
"_resolved": "http://registry.npmjs.org/bplist-parser/-/bplist-parser-0.1.1.tgz",
"readme": "ERROR: No README data found!"
"name": "bplist-parser",
"optionalDependencies": {},
"readme": "ERROR: No README data found!",
"repository": {
"type": "git",
"url": "git+https://github.com/nearinfinity/node-bplist-parser.git"
},
"scripts": {
"test": "./node_modules/nodeunit/bin/nodeunit test"
},
"version": "0.1.1"
}

View File

@ -99,7 +99,7 @@ function expand(str, isTop) {
var isOptions = /^(.*,)+(.+)?$/.test(m.body);
if (!isSequence && !isOptions) {
// {a},b}
if (m.post.match(/,.*}/)) {
if (m.post.match(/,.*\}/)) {
str = m.pre + '{' + m.body + escClose + m.post;
return expand(str);
}

104
node_modules/brace-expansion/package.json generated vendored Normal file
View File

@ -0,0 +1,104 @@
{
"_args": [
[
"brace-expansion@^1.0.0",
"/Users/steveng/repo/cordova/cordova-android/node_modules/minimatch"
]
],
"_from": "brace-expansion@>=1.0.0 <2.0.0",
"_id": "brace-expansion@1.1.3",
"_inCache": true,
"_installable": true,
"_location": "/brace-expansion",
"_nodeVersion": "5.5.0",
"_npmOperationalInternal": {
"host": "packages-6-west.internal.npmjs.com",
"tmp": "tmp/brace-expansion-1.1.3.tgz_1455216688668_0.948847763473168"
},
"_npmUser": {
"email": "julian@juliangruber.com",
"name": "juliangruber"
},
"_npmVersion": "3.3.12",
"_phantomChildren": {},
"_requested": {
"name": "brace-expansion",
"raw": "brace-expansion@^1.0.0",
"rawSpec": "^1.0.0",
"scope": null,
"spec": ">=1.0.0 <2.0.0",
"type": "range"
},
"_requiredBy": [
"/minimatch"
],
"_resolved": "http://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.3.tgz",
"_shasum": "46bff50115d47fc9ab89854abb87d98078a10991",
"_shrinkwrap": null,
"_spec": "brace-expansion@^1.0.0",
"_where": "/Users/steveng/repo/cordova/cordova-android/node_modules/minimatch",
"author": {
"email": "mail@juliangruber.com",
"name": "Julian Gruber",
"url": "http://juliangruber.com"
},
"bugs": {
"url": "https://github.com/juliangruber/brace-expansion/issues"
},
"dependencies": {
"balanced-match": "^0.3.0",
"concat-map": "0.0.1"
},
"description": "Brace expansion as known from sh/bash",
"devDependencies": {
"tape": "4.4.0"
},
"directories": {},
"dist": {
"shasum": "46bff50115d47fc9ab89854abb87d98078a10991",
"tarball": "http://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.3.tgz"
},
"gitHead": "f0da1bb668e655f67b6b2d660c6e1c19e2a6f231",
"homepage": "https://github.com/juliangruber/brace-expansion",
"keywords": [],
"license": "MIT",
"main": "index.js",
"maintainers": [
{
"name": "juliangruber",
"email": "julian@juliangruber.com"
},
{
"name": "isaacs",
"email": "isaacs@npmjs.com"
}
],
"name": "brace-expansion",
"optionalDependencies": {},
"readme": "ERROR: No README data found!",
"repository": {
"type": "git",
"url": "git://github.com/juliangruber/brace-expansion.git"
},
"scripts": {
"gentest": "bash test/generate.sh",
"test": "tape test/*.js"
},
"testling": {
"browsers": [
"android-browser/4.2..latest",
"chrome/25..latest",
"chrome/canary",
"firefox/20..latest",
"firefox/nightly",
"ie/8..latest",
"ipad/6.0..latest",
"iphone/6.0..latest",
"opera/12..latest",
"opera/next",
"safari/5.1..latest"
],
"files": "test/*.js"
},
"version": "1.1.3"
}

View File

@ -1,83 +1,109 @@
{
"name": "concat-map",
"description": "concatenative mapdashery",
"version": "0.0.1",
"repository": {
"type": "git",
"url": "git://github.com/substack/node-concat-map.git"
},
"main": "index.js",
"keywords": [
"concat",
"concatMap",
"map",
"functional",
"higher-order"
"_args": [
[
"concat-map@0.0.1",
"/Users/steveng/repo/cordova/cordova-android/node_modules/brace-expansion"
]
],
"directories": {
"example": "example",
"test": "test"
},
"scripts": {
"test": "tape test/*.js"
},
"devDependencies": {
"tape": "~2.4.0"
},
"license": "MIT",
"author": {
"name": "James Halliday",
"_from": "concat-map@0.0.1",
"_id": "concat-map@0.0.1",
"_inCache": true,
"_installable": true,
"_location": "/concat-map",
"_npmUser": {
"email": "mail@substack.net",
"url": "http://substack.net"
"name": "substack"
},
"testling": {
"files": "test/*.js",
"browsers": {
"ie": [
6,
7,
8,
9
],
"ff": [
3.5,
10,
15
],
"chrome": [
10,
22
],
"safari": [
5.1
],
"opera": [
12
]
}
"_npmVersion": "1.3.21",
"_phantomChildren": {},
"_requested": {
"name": "concat-map",
"raw": "concat-map@0.0.1",
"rawSpec": "0.0.1",
"scope": null,
"spec": "0.0.1",
"type": "version"
},
"_requiredBy": [
"/brace-expansion"
],
"_resolved": "http://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz",
"_shasum": "d8a96bd77fd68df7793a73036a3ba0d5405d477b",
"_shrinkwrap": null,
"_spec": "concat-map@0.0.1",
"_where": "/Users/steveng/repo/cordova/cordova-android/node_modules/brace-expansion",
"author": {
"email": "mail@substack.net",
"name": "James Halliday",
"url": "http://substack.net"
},
"bugs": {
"url": "https://github.com/substack/node-concat-map/issues"
},
"homepage": "https://github.com/substack/node-concat-map",
"_id": "concat-map@0.0.1",
"dependencies": {},
"description": "concatenative mapdashery",
"devDependencies": {
"tape": "~2.4.0"
},
"directories": {
"example": "example",
"test": "test"
},
"dist": {
"shasum": "d8a96bd77fd68df7793a73036a3ba0d5405d477b",
"tarball": "http://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz"
},
"_from": "concat-map@0.0.1",
"_npmVersion": "1.3.21",
"_npmUser": {
"name": "substack",
"email": "mail@substack.net"
},
"homepage": "https://github.com/substack/node-concat-map",
"keywords": [
"concat",
"concatMap",
"functional",
"higher-order",
"map"
],
"license": "MIT",
"main": "index.js",
"maintainers": [
{
"name": "substack",
"email": "mail@substack.net"
}
],
"_shasum": "d8a96bd77fd68df7793a73036a3ba0d5405d477b",
"_resolved": "http://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz",
"readme": "ERROR: No README data found!"
"name": "concat-map",
"optionalDependencies": {},
"readme": "ERROR: No README data found!",
"repository": {
"type": "git",
"url": "git://github.com/substack/node-concat-map.git"
},
"scripts": {
"test": "tape test/*.js"
},
"testling": {
"browsers": {
"chrome": [
10,
22
],
"ff": [
10,
15,
3.5
],
"ie": [
6,
7,
8,
9
],
"opera": [
12
],
"safari": [
5.1
]
},
"files": "test/*.js"
},
"version": "0.0.1"
}

View File

@ -107,6 +107,10 @@ Usage:
```
var superspawn = require('cordova-common').superspawn;
superspawn.spawn('adb', ['devices'])
.progress(function(data){
if (data.stderr)
console.error('"adb devices" raised an error: ' + data.stderr);
})
.then(function(devices){
// Do something...
})

View File

@ -20,6 +20,14 @@
-->
# Cordova-common Release Notes
### 1.1.0 (Feb 16, 2016)
* CB-10482 Remove references to windows8 from cordova-lib/cli
* CB-10430 Adds forwardEvents method to easily connect two EventEmitters
* CB-10176 Adds CordovaLogger class, based on logger module from cordova-cli
* CB-10052 Expose child process' io streams via promise progress notification
* CB-10497 Prefer .bat over .cmd on windows platform
* CB-9984 Bumps plist version and fixes failing cordova-common test
### 1.0.0 (Oct 29, 2015)
* CB-9890 Documents cordova-common

View File

@ -26,6 +26,7 @@ exports = module.exports = {
ActionStack: require('./src/ActionStack'),
CordovaError: require('./src/CordovaError/CordovaError'),
CordovaLogger: require('./src/CordovaLogger'),
CordovaExternalToolErrorContext: require('./src/CordovaError/CordovaExternalToolErrorContext'),
PlatformJson: require('./src/PlatformJson'),
ConfigParser: require('./src/ConfigParser/ConfigParser.js'),

View File

@ -1,3 +0,0 @@
[remote "github"]
push = +refs/heads/master:refs/heads/gh-pages
push = +refs/heads/master:refs/heads/master

View File

@ -1,8 +0,0 @@
ui: jasmine2
browsers:
- name: chrome
version: 27
- name: ie
version: latest
- name: iphone
version: 6.1

View File

@ -1,2 +0,0 @@
sauce_username: peterolson
sauce_key: 3553a315-10c0-4661-9d8e-7150d87064c7

File diff suppressed because one or more lines are too long

View File

@ -1,24 +0,0 @@
This is free and unencumbered software released into the public domain.
Anyone is free to copy, modify, publish, use, compile, sell, or
distribute this software, either in source code form or as a compiled
binary, for any purpose, commercial or non-commercial, and by any
means.
In jurisdictions that recognize copyright laws, the author or authors
of this software dedicate any and all copyright interest in the
software to the public domain. We make this dedication for the benefit
of the public at large and to the detriment of our heirs and
successors. We intend this dedication to be an overt act of
relinquishment in perpetuity of all present and future rights to this
software under copyright law.
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.
For more information, please refer to <http://unlicense.org>

View File

@ -1,51 +0,0 @@
{
"name": "cordova-registry-mapper",
"version": "1.1.14",
"description": "Maps old plugin ids to new plugin names for fetching from npm",
"main": "index.js",
"repository": {
"type": "git",
"url": "git+https://github.com/stevengill/cordova-registry-mapper.git"
},
"scripts": {
"test": "node tests/test.js"
},
"keywords": [
"cordova",
"plugins"
],
"author": {
"name": "Steve Gill"
},
"license": "Apache version 2.0",
"devDependencies": {
"tape": "^3.5.0"
},
"gitHead": "0ad8505f61afaac3c7ab112e6e79bd61cb953762",
"bugs": {
"url": "https://github.com/stevengill/cordova-registry-mapper/issues"
},
"homepage": "https://github.com/stevengill/cordova-registry-mapper#readme",
"_id": "cordova-registry-mapper@1.1.14",
"_shasum": "cca1084e1e3a1b4737405123989251d4a6a5ca07",
"_from": "cordova-registry-mapper@>=1.1.8 <2.0.0",
"_npmVersion": "3.5.1",
"_nodeVersion": "5.0.0",
"_npmUser": {
"name": "stevegill",
"email": "stevengill97@gmail.com"
},
"dist": {
"shasum": "cca1084e1e3a1b4737405123989251d4a6a5ca07",
"tarball": "http://registry.npmjs.org/cordova-registry-mapper/-/cordova-registry-mapper-1.1.14.tgz"
},
"maintainers": [
{
"name": "stevegill",
"email": "stevengill97@gmail.com"
}
],
"directories": {},
"_resolved": "http://registry.npmjs.org/cordova-registry-mapper/-/cordova-registry-mapper-1.1.14.tgz",
"readme": "ERROR: No README data found!"
}

View File

@ -1,52 +0,0 @@
{
"name": "wrappy",
"version": "1.0.1",
"description": "Callback wrapping utility",
"main": "wrappy.js",
"directories": {
"test": "test"
},
"dependencies": {},
"devDependencies": {
"tap": "^0.4.12"
},
"scripts": {
"test": "tap test/*.js"
},
"repository": {
"type": "git",
"url": "git+https://github.com/npm/wrappy.git"
},
"author": {
"name": "Isaac Z. Schlueter",
"email": "i@izs.me",
"url": "http://blog.izs.me/"
},
"license": "ISC",
"bugs": {
"url": "https://github.com/npm/wrappy/issues"
},
"homepage": "https://github.com/npm/wrappy",
"gitHead": "006a8cbac6b99988315834c207896eed71fd069a",
"_id": "wrappy@1.0.1",
"_shasum": "1e65969965ccbc2db4548c6b84a6f2c5aedd4739",
"_from": "wrappy@>=1.0.0 <2.0.0",
"_npmVersion": "2.0.0",
"_nodeVersion": "0.10.31",
"_npmUser": {
"name": "isaacs",
"email": "i@izs.me"
},
"maintainers": [
{
"name": "isaacs",
"email": "i@izs.me"
}
],
"dist": {
"shasum": "1e65969965ccbc2db4548c6b84a6f2c5aedd4739",
"tarball": "http://registry.npmjs.org/wrappy/-/wrappy-1.0.1.tgz"
},
"_resolved": "http://registry.npmjs.org/wrappy/-/wrappy-1.0.1.tgz",
"readme": "ERROR: No README data found!"
}

View File

@ -1,6 +0,0 @@
var concatMap = require('../');
var xs = [ 1, 2, 3, 4, 5, 6 ];
var ys = concatMap(xs, function (x) {
return x % 2 ? [ x - 0.1, x, x + 0.1 ] : [];
});
console.dir(ys);

View File

@ -1,75 +0,0 @@
{
"name": "brace-expansion",
"description": "Brace expansion as known from sh/bash",
"version": "1.1.2",
"repository": {
"type": "git",
"url": "git://github.com/juliangruber/brace-expansion.git"
},
"homepage": "https://github.com/juliangruber/brace-expansion",
"main": "index.js",
"scripts": {
"test": "tape test/*.js",
"gentest": "bash test/generate.sh"
},
"dependencies": {
"balanced-match": "^0.3.0",
"concat-map": "0.0.1"
},
"devDependencies": {
"tape": "4.2.2"
},
"keywords": [],
"author": {
"name": "Julian Gruber",
"email": "mail@juliangruber.com",
"url": "http://juliangruber.com"
},
"license": "MIT",
"testling": {
"files": "test/*.js",
"browsers": [
"ie/8..latest",
"firefox/20..latest",
"firefox/nightly",
"chrome/25..latest",
"chrome/canary",
"opera/12..latest",
"opera/next",
"safari/5.1..latest",
"ipad/6.0..latest",
"iphone/6.0..latest",
"android-browser/4.2..latest"
]
},
"gitHead": "b03773a30fa516b1374945b68e9acb6253d595fa",
"bugs": {
"url": "https://github.com/juliangruber/brace-expansion/issues"
},
"_id": "brace-expansion@1.1.2",
"_shasum": "f21445d0488b658e2771efd870eff51df29f04ef",
"_from": "brace-expansion@>=1.0.0 <2.0.0",
"_npmVersion": "2.14.7",
"_nodeVersion": "4.2.1",
"_npmUser": {
"name": "juliangruber",
"email": "julian@juliangruber.com"
},
"dist": {
"shasum": "f21445d0488b658e2771efd870eff51df29f04ef",
"tarball": "http://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.2.tgz"
},
"maintainers": [
{
"name": "juliangruber",
"email": "julian@juliangruber.com"
},
{
"name": "isaacs",
"email": "isaacs@npmjs.com"
}
],
"directories": {},
"_resolved": "http://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.2.tgz",
"readme": "ERROR: No README data found!"
}

View File

@ -1,36 +0,0 @@
# wrappy
Callback wrapping utility
## USAGE
```javascript
var wrappy = require("wrappy")
// var wrapper = wrappy(wrapperFunction)
// make sure a cb is called only once
// See also: http://npm.im/once for this specific use case
var once = wrappy(function (cb) {
var called = false
return function () {
if (called) return
called = true
return cb.apply(this, arguments)
}
})
function printBoo () {
console.log('boo')
}
// has some rando property
printBoo.iAmBooPrinter = true
var onlyPrintOnce = once(printBoo)
onlyPrintOnce() // prints 'boo'
onlyPrintOnce() // does nothing
// random property is retained!
assert.equal(onlyPrintOnce.iAmBooPrinter, true)
```

View File

@ -1,51 +0,0 @@
var test = require('tap').test
var wrappy = require('../wrappy.js')
test('basic', function (t) {
function onceifier (cb) {
var called = false
return function () {
if (called) return
called = true
return cb.apply(this, arguments)
}
}
onceifier.iAmOnce = {}
var once = wrappy(onceifier)
t.equal(once.iAmOnce, onceifier.iAmOnce)
var called = 0
function boo () {
t.equal(called, 0)
called++
}
// has some rando property
boo.iAmBoo = true
var onlyPrintOnce = once(boo)
onlyPrintOnce() // prints 'boo'
onlyPrintOnce() // does nothing
t.equal(called, 1)
// random property is retained!
t.equal(onlyPrintOnce.iAmBoo, true)
var logs = []
var logwrap = wrappy(function (msg, cb) {
logs.push(msg + ' wrapping cb')
return function () {
logs.push(msg + ' before cb')
var ret = cb.apply(this, arguments)
logs.push(msg + ' after cb')
}
})
var c = logwrap('foo', function () {
t.same(logs, [ 'foo wrapping cb', 'foo before cb' ])
})
c()
t.same(logs, [ 'foo wrapping cb', 'foo before cb', 'foo after cb' ])
t.end()
})

View File

@ -1,33 +0,0 @@
// Returns a wrapper function that returns a wrapped callback
// The wrapper function should do some stuff, and return a
// presumably different callback function.
// This makes sure that own properties are retained, so that
// decorations and such are not lost along the way.
module.exports = wrappy
function wrappy (fn, cb) {
if (fn && cb) return wrappy(fn)(cb)
if (typeof fn !== 'function')
throw new TypeError('need wrapper function')
Object.keys(fn).forEach(function (k) {
wrapper[k] = fn[k]
})
return wrapper
function wrapper() {
var args = new Array(arguments.length)
for (var i = 0; i < args.length; i++) {
args[i] = arguments[i]
}
var ret = fn.apply(this, args)
var cb = args[args.length-1]
if (typeof ret === 'function' && ret !== cb) {
Object.keys(cb).forEach(function (k) {
ret[k] = cb[k]
})
}
return ret
}
}

View File

@ -1,63 +1,81 @@
{
"_args": [
[
"cordova-common@^1.1.0",
"/Users/steveng/repo/cordova/cordova-android"
]
],
"_from": "cordova-common@>=1.1.0 <2.0.0",
"_id": "cordova-common@1.1.0",
"_inCache": true,
"_installable": true,
"_location": "/cordova-common",
"_nodeVersion": "4.2.3",
"_npmOperationalInternal": {
"host": "packages-5-east.internal.npmjs.com",
"tmp": "tmp/cordova-common-1.1.0.tgz_1455781889491_0.6937742941081524"
},
"_npmUser": {
"email": "kotikov.vladimir@gmail.com",
"name": "kotikov.vladimir"
},
"_npmVersion": "2.14.7",
"_phantomChildren": {},
"_requested": {
"name": "cordova-common",
"raw": "cordova-common@^1.1.0",
"rawSpec": "^1.1.0",
"scope": null,
"spec": ">=1.1.0 <2.0.0",
"type": "range"
},
"_requiredBy": [
"/"
],
"_resolved": "http://registry.npmjs.org/cordova-common/-/cordova-common-1.1.0.tgz",
"_shasum": "8682721466ee354747ec6241f34f412b7e0ef636",
"_shrinkwrap": null,
"_spec": "cordova-common@^1.1.0",
"_where": "/Users/steveng/repo/cordova/cordova-android",
"author": {
"name": "Apache Software Foundation"
},
"name": "cordova-common",
"description": "Apache Cordova tools and platforms shared routines",
"license": "Apache-2.0",
"version": "1.0.0",
"repository": {
"type": "git",
"url": "git://git-wip-us.apache.org/repos/asf/cordova-common.git"
},
"bugs": {
"url": "https://issues.apache.org/jira/browse/CB",
"email": "dev@cordova.apache.org"
"email": "dev@cordova.apache.org",
"url": "https://issues.apache.org/jira/browse/CB"
},
"main": "cordova-common.js",
"engines": {
"node": ">=0.9.9"
},
"scripts": {
"test": "npm run jshint && npm run jasmine",
"jshint": "node node_modules/jshint/bin/jshint src && node node_modules/jshint/bin/jshint spec",
"jasmine": "node node_modules/jasmine-node/bin/jasmine-node --captureExceptions --color spec",
"cover": "node node_modules/istanbul/lib/cli.js cover --root src --print detail node_modules/jasmine-node/bin/jasmine-node -- spec"
},
"engineStrict": true,
"contributors": [],
"dependencies": {
"ansi": "^0.3.1",
"bplist-parser": "^0.1.0",
"cordova-registry-mapper": "^1.1.8",
"elementtree": "^0.1.6",
"glob": "^5.0.13",
"osenv": "^0.1.3",
"plist": "^1.1.0",
"plist": "^1.2.0",
"q": "^1.4.1",
"semver": "^5.0.1",
"shelljs": "^0.5.1",
"underscore": "^1.8.3",
"unorm": "^1.3.3"
},
"description": "Apache Cordova tools and platforms shared routines",
"devDependencies": {
"istanbul": "^0.3.17",
"jasmine-node": "^1.14.5",
"jshint": "^2.8.0"
},
"contributors": [],
"_id": "cordova-common@1.0.0",
"_shasum": "b21947e89a4a89292ec563abf9ee6ccb2b9f3aef",
"_resolved": "http://registry.npmjs.org/cordova-common/-/cordova-common-1.0.0.tgz",
"_from": "cordova-common@>=1.0.0 <1.1.0",
"_npmVersion": "2.14.7",
"_nodeVersion": "4.2.1",
"_npmUser": {
"name": "kotikov.vladimir",
"email": "kotikov.vladimir@gmail.com"
},
"directories": {},
"dist": {
"shasum": "b21947e89a4a89292ec563abf9ee6ccb2b9f3aef",
"tarball": "http://registry.npmjs.org/cordova-common/-/cordova-common-1.0.0.tgz"
"shasum": "8682721466ee354747ec6241f34f412b7e0ef636",
"tarball": "http://registry.npmjs.org/cordova-common/-/cordova-common-1.1.0.tgz"
},
"engineStrict": true,
"engines": {
"node": ">=0.9.9"
},
"license": "Apache-2.0",
"main": "cordova-common.js",
"maintainers": [
{
"name": "bowserj",
@ -84,6 +102,18 @@
"email": "npmjs@barhams.info"
}
],
"directories": {},
"readme": "ERROR: No README data found!"
"name": "cordova-common",
"optionalDependencies": {},
"readme": "ERROR: No README data found!",
"repository": {
"type": "git",
"url": "git://git-wip-us.apache.org/repos/asf/cordova-common.git"
},
"scripts": {
"cover": "node node_modules/istanbul/lib/cli.js cover --root src --print detail node_modules/jasmine-node/bin/jasmine-node -- spec",
"jasmine": "node node_modules/jasmine-node/bin/jasmine-node --captureExceptions --color spec",
"jshint": "node node_modules/jshint/bin/jshint src && node node_modules/jshint/bin/jshint spec",
"test": "npm run jshint && npm run jasmine"
},
"version": "1.1.0"
}

View File

@ -106,8 +106,8 @@ function remove_plugin_changes(pluginInfo, is_top_level) {
// CB-6976 Windows Universal Apps. Compatibility fix for existing plugins.
if (self.platform == 'windows' && file == 'package.appxmanifest' &&
!fs.existsSync(path.join(self.project_dir, 'package.appxmanifest'))) {
// New windows template separate manifest files for Windows8, Windows8.1 and WP8.1
var substs = ['package.phone.appxmanifest', 'package.windows.appxmanifest', 'package.windows80.appxmanifest', 'package.windows10.appxmanifest'];
// New windows template separate manifest files for Windows10, Windows8.1 and WP8.1
var substs = ['package.phone.appxmanifest', 'package.windows.appxmanifest', 'package.windows10.appxmanifest'];
/* jshint loopfunc:true */
substs.forEach(function(subst) {
events.emit('verbose', 'Applying munge to ' + subst);
@ -149,7 +149,7 @@ function add_plugin_changes(pluginInfo, plugin_vars, is_top_level, should_increm
// CB-6976 Windows Universal Apps. Compatibility fix for existing plugins.
if (self.platform == 'windows' && file == 'package.appxmanifest' &&
!fs.existsSync(path.join(self.project_dir, 'package.appxmanifest'))) {
var substs = ['package.phone.appxmanifest', 'package.windows.appxmanifest', 'package.windows80.appxmanifest', 'package.windows10.appxmanifest'];
var substs = ['package.phone.appxmanifest', 'package.windows.appxmanifest', 'package.windows10.appxmanifest'];
/* jshint loopfunc:true */
substs.forEach(function(subst) {
events.emit('verbose', 'Applying munge to ' + subst);
@ -203,7 +203,6 @@ function generate_plugin_config_munge(pluginInfo, vars) {
{
var manifests = {
'windows': {
'8.0.0': 'package.windows80.appxmanifest',
'8.1.0': 'package.windows.appxmanifest',
'10.0.0': 'package.windows10.appxmanifest'
},
@ -212,7 +211,6 @@ function generate_plugin_config_munge(pluginInfo, vars) {
'10.0.0': 'package.windows10.appxmanifest'
},
'all': {
'8.0.0': 'package.windows80.appxmanifest',
'8.1.0': ['package.windows.appxmanifest', 'package.phone.appxmanifest'],
'10.0.0': 'package.windows10.appxmanifest'
}

203
node_modules/cordova-common/src/CordovaLogger.js generated vendored Normal file
View File

@ -0,0 +1,203 @@
/*
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
distributed with this work for additional information
regarding copyright ownership. The ASF licenses this file
to you under the Apache License, Version 2.0 (the
"License"); you may not use this file except in compliance
with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied. See the License for the
specific language governing permissions and limitations
under the License.
*/
var ansi = require('ansi');
var EventEmitter = require('events').EventEmitter;
var CordovaError = require('./CordovaError/CordovaError');
var EOL = require('os').EOL;
var INSTANCE;
/**
* @class CordovaLogger
*
* Implements logging facility that anybody could use. Should not be
* instantiated directly, `CordovaLogger.get()` method should be used instead
* to acquire logger instance
*/
function CordovaLogger () {
this.levels = {};
this.colors = {};
this.stdout = process.stdout;
this.stderr = process.stderr;
this.stdoutCursor = ansi(this.stdout);
this.stderrCursor = ansi(this.stderr);
this.addLevel('verbose', 1000, 'grey');
this.addLevel('normal' , 2000);
this.addLevel('warn' , 2000, 'yellow');
this.addLevel('info' , 3000, 'blue');
this.addLevel('error' , 5000, 'red');
this.addLevel('results' , 10000);
this.setLevel('normal');
}
/**
* Static method to create new or acquire existing instance.
*
* @return {CordovaLogger} Logger instance
*/
CordovaLogger.get = function () {
return INSTANCE || (INSTANCE = new CordovaLogger());
};
CordovaLogger.VERBOSE = 'verbose';
CordovaLogger.NORMAL = 'normal';
CordovaLogger.WARN = 'warn';
CordovaLogger.INFO = 'info';
CordovaLogger.ERROR = 'error';
CordovaLogger.RESULTS = 'results';
/**
* Emits log message to process' stdout/stderr depending on message's severity
* and current log level. If severity is less than current logger's level,
* then the message is ignored.
*
* @param {String} logLevel The message's log level. The logger should have
* corresponding level added (via logger.addLevel), otherwise
* `CordovaLogger.NORMAL` level will be used.
* @param {String} message The message, that should be logged to process'
* stdio
*
* @return {CordovaLogger} Current instance, to allow calls chaining.
*/
CordovaLogger.prototype.log = function (logLevel, message) {
// if there is no such logLevel defined, or provided level has
// less severity than active level, then just ignore this call and return
if (!this.levels[logLevel] || this.levels[logLevel] < this.levels[this.logLevel])
// return instance to allow to chain calls
return this;
var isVerbose = this.logLevel === 'verbose';
var cursor = this.stdoutCursor;
if(message instanceof Error || logLevel === CordovaLogger.ERROR) {
message = formatError(message, isVerbose);
cursor = this.stderrCursor;
}
var color = this.colors[logLevel];
if (color) {
cursor.bold().fg[color]();
}
cursor.write(message).reset().write(EOL);
return this;
};
/**
* Adds a new level to logger instance. This method also creates a shortcut
* method to log events with the level provided (i.e. after adding new level
* 'debug', the method `debug(message)`, equal to logger.log('debug', message),
* will be added to logger instance)
*
* @param {String} level A log level name. The levels with the following
* names added by default to every instance: 'verbose', 'normal', 'warn',
* 'info', 'error', 'results'
* @param {Number} severity A number that represents level's severity.
* @param {String} color A valid color name, that will be used to log
* messages with this level. Any CSS color code or RGB value is allowed
* (according to ansi documentation:
* https://github.com/TooTallNate/ansi.js#features)
*
* @return {CordovaLogger} Current instance, to allow calls chaining.
*/
CordovaLogger.prototype.addLevel = function (level, severity, color) {
this.levels[level] = severity;
if (color) {
this.colors[level] = color;
}
// Define own method with corresponding name
if (!this[level]) {
this[level] = this.log.bind(this, level);
}
return this;
};
/**
* Sets the current logger level to provided value. If logger doesn't have level
* with this name, `CordovaLogger.NORMAL` will be used.
*
* @param {String} logLevel Level name. The level with this name should be
* added to logger before.
*
* @return {CordovaLogger} Current instance, to allow calls chaining.
*/
CordovaLogger.prototype.setLevel = function (logLevel) {
this.logLevel = this.levels[logLevel] ? logLevel : CordovaLogger.NORMAL;
return this;
};
/**
* Attaches logger to EventEmitter instance provided.
*
* @param {EventEmitter} eventEmitter An EventEmitter instance to attach
* logger to.
*
* @return {CordovaLogger} Current instance, to allow calls chaining.
*/
CordovaLogger.prototype.subscribe = function (eventEmitter) {
if (!(eventEmitter instanceof EventEmitter))
throw new Error('Subscribe method only accepts an EventEmitter instance as argument');
eventEmitter.on('verbose', this.verbose)
.on('log', this.normal)
.on('info', this.info)
.on('warn', this.warn)
.on('warning', this.warn)
// Set up event handlers for logging and results emitted as events.
.on('results', this.results);
return this;
};
function formatError(error, isVerbose) {
var message = '';
if(error instanceof CordovaError) {
message = error.toString(isVerbose);
} else if(error instanceof Error) {
if(isVerbose) {
message = error.stack;
} else {
message = error.message;
}
} else {
// Plain text error message
message = error;
}
if(message.toUpperCase().indexOf('ERROR:') !== 0) {
// Needed for backward compatibility with external tools
message = 'Error: ' + message;
}
return message;
}
module.exports = CordovaLogger;

View File

@ -376,9 +376,6 @@ function addCordova(someArray) {
// applied to each element.
function _getTags(pelem, tag, platform, transform) {
var platformTag = pelem.find('./platform[@name="' + platform + '"]');
if (platform == 'windows' && !platformTag) {
platformTag = pelem.find('platform[@name="' + 'windows8' + '"]');
}
var tagsInRoot = pelem.findall(tag);
tagsInRoot = tagsInRoot || [];
var tagsInPlatform = platformTag ? platformTag.findall(tag) : [];
@ -392,9 +389,6 @@ function _getTags(pelem, tag, platform, transform) {
// Same as _getTags() but only looks inside a platfrom section.
function _getTagsInPlatform(pelem, tag, platform, transform) {
var platformTag = pelem.find('./platform[@name="' + platform + '"]');
if (platform == 'windows' && !platformTag) {
platformTag = pelem.find('platform[@name="' + 'windows8' + '"]');
}
var tags = platformTag ? platformTag.findall(tag) : [];
if ( typeof transform === 'function' ) {
tags = tags.map(transform);

View File

@ -16,4 +16,50 @@
specific language governing permissions and limitations
under the License.
*/
module.exports = new (require('events').EventEmitter)();
var EventEmitter = require('events').EventEmitter;
var INSTANCE = new EventEmitter();
var EVENTS_RECEIVER;
module.exports = INSTANCE;
/**
* Sets up current instance to forward emitted events to another EventEmitter
* instance.
*
* @param {EventEmitter} [eventEmitter] The emitter instance to forward
* events to. Falsy value, when passed, disables forwarding.
*/
module.exports.forwardEventsTo = function (eventEmitter) {
// If no argument is specified disable events forwarding
if (!eventEmitter) {
EVENTS_RECEIVER = undefined;
return;
}
if (!(eventEmitter instanceof EventEmitter))
throw new Error('Cordova events could be redirected to another EventEmitter instance only');
EVENTS_RECEIVER = eventEmitter;
};
var emit = INSTANCE.emit;
/**
* This method replaces original 'emit' method to allow events forwarding.
*
* @return {eventEmitter} Current instance to allow calls chaining, as
* original 'emit' does
*/
module.exports.emit = function () {
var args = Array.prototype.slice.call(arguments);
if (EVENTS_RECEIVER) {
EVENTS_RECEIVER.emit.apply(EVENTS_RECEIVER, args);
}
return emit.apply(this, args);
};

View File

@ -28,7 +28,7 @@ var iswin32 = process.platform == 'win32';
// On Windows, spawn() for batch files requires absolute path & having the extension.
function resolveWindowsExe(cmd) {
var winExtensions = ['.exe', '.cmd', '.bat', '.js', '.vbs'];
var winExtensions = ['.exe', '.bat', '.cmd', '.js', '.vbs'];
function isValidExe(c) {
return winExtensions.indexOf(path.extname(c)) !== -1 && fs.existsSync(c);
}
@ -52,15 +52,39 @@ function maybeQuote(a) {
return a;
}
// opts:
// printCommand: Whether to log the command (default: false)
// stdio: 'default' is to capture output and returning it as a string to success (same as exec)
// 'ignore' means don't bother capturing it
// 'inherit' means pipe the input & output. This is required for anything that prompts.
// env: Map of extra environment variables.
// cwd: Working directory for the command.
// chmod: If truthy, will attempt to set the execute bit before executing on non-Windows platforms.
// Returns a promise that succeeds only for return code = 0.
/**
* A special implementation for child_process.spawn that handles
* Windows-specific issues with batch files and spaces in paths. Returns a
* promise that succeeds only for return code 0. It is also possible to
* subscribe on spawned process' stdout and stderr streams using progress
* handler for resultant promise.
*
* @example spawn('mycommand', [], {stdio: 'pipe'}) .progress(function (stdio){
* if (stdio.stderr) { console.error(stdio.stderr); } })
* .then(function(result){ // do other stuff })
*
* @param {String} cmd A command to spawn
* @param {String[]} [args=[]] An array of arguments, passed to spawned
* process
* @param {Object} [opts={}] A configuration object
* @param {String|String[]|Object} opts.stdio Property that configures how
* spawned process' stdio will behave. Has the same meaning and possible
* values as 'stdio' options for child_process.spawn method
* (https://nodejs.org/api/child_process.html#child_process_options_stdio).
* @param {Object} [env={}] A map of extra environment variables
* @param {String} [cwd=process.cwd()] Working directory for the command
* @param {Boolean} [chmod=false] If truthy, will attempt to set the execute
* bit before executing on non-Windows platforms
*
* @return {Promise} A promise that is either fulfilled if the spawned
* process is exited with zero error code or rejected otherwise. If the
* 'stdio' option set to 'default' or 'pipe', the promise also emits progress
* messages with the following contents:
* {
* 'stdout': ...,
* 'stderr': ...
* }
*/
exports.spawn = function(cmd, args, opts) {
args = args || [];
opts = opts || {};
@ -83,17 +107,19 @@ exports.spawn = function(cmd, args, opts) {
}
}
if (opts.stdio == 'ignore') {
spawnOpts.stdio = 'ignore';
} else if (opts.stdio == 'inherit') {
spawnOpts.stdio = 'inherit';
if (opts.stdio !== 'default') {
// Ignore 'default' value for stdio because it corresponds to child_process's default 'pipe' option
spawnOpts.stdio = opts.stdio;
}
if (opts.cwd) {
spawnOpts.cwd = opts.cwd;
}
if (opts.env) {
spawnOpts.env = _.extend(_.extend({}, process.env), opts.env);
}
if (opts.chmod && !iswin32) {
try {
// This fails when module is installed in a system directory (e.g. via sudo npm install)
@ -113,11 +139,15 @@ exports.spawn = function(cmd, args, opts) {
child.stdout.setEncoding('utf8');
child.stdout.on('data', function(data) {
capturedOut += data;
d.notify({'stdout': data});
});
}
if (child.stderr) {
child.stderr.setEncoding('utf8');
child.stderr.on('data', function(data) {
capturedErr += data;
d.notify({'stderr': data});
});
}

1
node_modules/cordova-registry-mapper/.npmignore generated vendored Normal file
View File

@ -0,0 +1 @@
node_modules

View File

@ -159,7 +159,7 @@ var map = {
'de.fastr.phonegap.plugins.downloader' : 'cordova-plugin-fastrde-downloader',
'de.fastr.phonegap.plugins.injectView' : 'cordova-plugin-fastrde-injectview',
'de.fastr.phonegap.plugins.CheckGPS' : 'cordova-plugin-fastrde-checkgps',
'de.fastr.phonegap.plugins.md5chksum' : ' cordova-plugin-fastrde-md5',
'de.fastr.phonegap.plugins.md5chksum' : 'cordova-plugin-fastrde-md5',
'io.repro.cordova' : 'cordova-plugin-repro',
're.notifica.cordova': 'cordova-plugin-notificare-push',
'com.megster.cordova.ble': 'cordova-plugin-ble-central',
@ -188,7 +188,10 @@ var map = {
'com.chariotsolutions.nfc.plugin': 'phonegap-nfc',
'com.samz.mixpanel': 'cordova-plugin-mixpanel',
'de.appplant.cordova.common.RegisterUserNotificationSettings': 'cordova-plugin-registerusernotificationsettings',
'plugin.google.maps': 'cordova-plugin-googlemaps'
'plugin.google.maps': 'cordova-plugin-googlemaps',
'xu.li.cordova.wechat': 'cordova-plugin-wechat',
'es.keensoft.fullscreenimage': 'cordova-plugin-fullscreenimage',
'com.arcoirislabs.plugin.mqtt' : 'cordova-plugin-mqtt'
};
module.exports.oldToNew = map;

77
node_modules/cordova-registry-mapper/package.json generated vendored Normal file
View File

@ -0,0 +1,77 @@
{
"_args": [
[
"cordova-registry-mapper@^1.1.8",
"/Users/steveng/repo/cordova/cordova-android/node_modules/cordova-common"
]
],
"_from": "cordova-registry-mapper@>=1.1.8 <2.0.0",
"_id": "cordova-registry-mapper@1.1.15",
"_inCache": true,
"_installable": true,
"_location": "/cordova-registry-mapper",
"_nodeVersion": "5.4.1",
"_npmUser": {
"email": "stevengill97@gmail.com",
"name": "stevegill"
},
"_npmVersion": "3.5.3",
"_phantomChildren": {},
"_requested": {
"name": "cordova-registry-mapper",
"raw": "cordova-registry-mapper@^1.1.8",
"rawSpec": "^1.1.8",
"scope": null,
"spec": ">=1.1.8 <2.0.0",
"type": "range"
},
"_requiredBy": [
"/cordova-common"
],
"_resolved": "http://registry.npmjs.org/cordova-registry-mapper/-/cordova-registry-mapper-1.1.15.tgz",
"_shasum": "e244b9185b8175473bff6079324905115f83dc7c",
"_shrinkwrap": null,
"_spec": "cordova-registry-mapper@^1.1.8",
"_where": "/Users/steveng/repo/cordova/cordova-android/node_modules/cordova-common",
"author": {
"name": "Steve Gill"
},
"bugs": {
"url": "https://github.com/stevengill/cordova-registry-mapper/issues"
},
"dependencies": {},
"description": "Maps old plugin ids to new plugin names for fetching from npm",
"devDependencies": {
"tape": "^3.5.0"
},
"directories": {},
"dist": {
"shasum": "e244b9185b8175473bff6079324905115f83dc7c",
"tarball": "http://registry.npmjs.org/cordova-registry-mapper/-/cordova-registry-mapper-1.1.15.tgz"
},
"gitHead": "00af0f028ec94154a364eeabe38b8e22320647bd",
"homepage": "https://github.com/stevengill/cordova-registry-mapper#readme",
"keywords": [
"cordova",
"plugins"
],
"license": "Apache version 2.0",
"main": "index.js",
"maintainers": [
{
"name": "stevegill",
"email": "stevengill97@gmail.com"
}
],
"name": "cordova-registry-mapper",
"optionalDependencies": {},
"readme": "ERROR: No README data found!",
"repository": {
"type": "git",
"url": "git+https://github.com/stevengill/cordova-registry-mapper.git"
},
"scripts": {
"test": "node tests/test.js"
},
"version": "1.1.15"
}

106
node_modules/elementtree/package.json generated vendored
View File

@ -1,7 +1,44 @@
{
"_args": [
[
"elementtree@^0.1.6",
"/Users/steveng/repo/cordova/cordova-android"
]
],
"_from": "elementtree@>=0.1.6 <0.2.0",
"_id": "elementtree@0.1.6",
"_inCache": true,
"_installable": true,
"_location": "/elementtree",
"_npmUser": {
"email": "ryan@trolocsis.com",
"name": "rphillips"
},
"_npmVersion": "1.3.24",
"_phantomChildren": {},
"_requested": {
"name": "elementtree",
"raw": "elementtree@^0.1.6",
"rawSpec": "^0.1.6",
"scope": null,
"spec": ">=0.1.6 <0.2.0",
"type": "range"
},
"_requiredBy": [
"/",
"/cordova-common"
],
"_resolved": "http://registry.npmjs.org/elementtree/-/elementtree-0.1.6.tgz",
"_shasum": "2ac4c46ea30516c8c4cbdb5e3ac7418e592de20c",
"_shrinkwrap": null,
"_spec": "elementtree@^0.1.6",
"_where": "/Users/steveng/repo/cordova/cordova-android",
"author": {
"name": "Rackspace US, Inc."
},
"bugs": {
"url": "https://github.com/racker/node-elementtree/issues"
},
"contributors": [
{
"name": "Paul Querna",
@ -12,64 +49,53 @@
"email": "tomaz.muraus@rackspace.com"
}
],
"name": "elementtree",
"description": "XML Serialization and Parsing module based on Python's ElementTree.",
"version": "0.1.6",
"keywords": [
"xml",
"sax",
"parser",
"seralization",
"elementtree"
],
"homepage": "https://github.com/racker/node-elementtree",
"repository": {
"type": "git",
"url": "git://github.com/racker/node-elementtree.git"
"dependencies": {
"sax": "0.3.5"
},
"description": "XML Serialization and Parsing module based on Python's ElementTree.",
"devDependencies": {
"whiskey": "0.8.x"
},
"main": "lib/elementtree.js",
"directories": {
"lib": "lib"
},
"scripts": {
"test": "make test"
"dist": {
"shasum": "2ac4c46ea30516c8c4cbdb5e3ac7418e592de20c",
"tarball": "http://registry.npmjs.org/elementtree/-/elementtree-0.1.6.tgz"
},
"engines": {
"node": ">= 0.4.0"
},
"dependencies": {
"sax": "0.3.5"
},
"devDependencies": {
"whiskey": "0.8.x"
},
"homepage": "https://github.com/racker/node-elementtree",
"keywords": [
"elementtree",
"parser",
"sax",
"seralization",
"xml"
],
"licenses": [
{
"type": "Apache",
"url": "http://www.apache.org/licenses/LICENSE-2.0.html"
}
],
"bugs": {
"url": "https://github.com/racker/node-elementtree/issues"
},
"_id": "elementtree@0.1.6",
"dist": {
"shasum": "2ac4c46ea30516c8c4cbdb5e3ac7418e592de20c",
"tarball": "http://registry.npmjs.org/elementtree/-/elementtree-0.1.6.tgz"
},
"_from": "elementtree@>=0.1.6 <0.2.0",
"_npmVersion": "1.3.24",
"_npmUser": {
"name": "rphillips",
"email": "ryan@trolocsis.com"
},
"main": "lib/elementtree.js",
"maintainers": [
{
"name": "rphillips",
"email": "ryan@trolocsis.com"
}
],
"_shasum": "2ac4c46ea30516c8c4cbdb5e3ac7418e592de20c",
"_resolved": "http://registry.npmjs.org/elementtree/-/elementtree-0.1.6.tgz",
"readme": "ERROR: No README data found!"
"name": "elementtree",
"optionalDependencies": {},
"readme": "ERROR: No README data found!",
"repository": {
"type": "git",
"url": "git://github.com/racker/node-elementtree.git"
},
"scripts": {
"test": "make test"
},
"version": "0.1.6"
}

Some files were not shown because too many files have changed in this diff Show More