You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by an...@apache.org on 2016/05/27 07:09:07 UTC
[14/51] [abbrv] [partial] cordova-windows git commit: CB-11117:
Bundle updated node modules
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/node-uuid/benchmark/bench.gnu
----------------------------------------------------------------------
diff --git a/node_modules/node-uuid/benchmark/bench.gnu b/node_modules/node-uuid/benchmark/bench.gnu
new file mode 100644
index 0000000..a342fbb
--- /dev/null
+++ b/node_modules/node-uuid/benchmark/bench.gnu
@@ -0,0 +1,174 @@
+#!/opt/local/bin/gnuplot -persist
+#
+#
+# G N U P L O T
+# Version 4.4 patchlevel 3
+# last modified March 2011
+# System: Darwin 10.8.0
+#
+# Copyright (C) 1986-1993, 1998, 2004, 2007-2010
+# Thomas Williams, Colin Kelley and many others
+#
+# gnuplot home: http://www.gnuplot.info
+# faq, bugs, etc: type "help seeking-assistance"
+# immediate help: type "help"
+# plot window: hit 'h'
+set terminal postscript eps noenhanced defaultplex \
+ leveldefault color colortext \
+ solid linewidth 1.2 butt noclip \
+ palfuncparam 2000,0.003 \
+ "Helvetica" 14
+set output 'bench.eps'
+unset clip points
+set clip one
+unset clip two
+set bar 1.000000 front
+set border 31 front linetype -1 linewidth 1.000
+set xdata
+set ydata
+set zdata
+set x2data
+set y2data
+set timefmt x "%d/%m/%y,%H:%M"
+set timefmt y "%d/%m/%y,%H:%M"
+set timefmt z "%d/%m/%y,%H:%M"
+set timefmt x2 "%d/%m/%y,%H:%M"
+set timefmt y2 "%d/%m/%y,%H:%M"
+set timefmt cb "%d/%m/%y,%H:%M"
+set boxwidth
+set style fill empty border
+set style rectangle back fc lt -3 fillstyle solid 1.00 border lt -1
+set style circle radius graph 0.02, first 0, 0
+set dummy x,y
+set format x "% g"
+set format y "% g"
+set format x2 "% g"
+set format y2 "% g"
+set format z "% g"
+set format cb "% g"
+set angles radians
+unset grid
+set key title ""
+set key outside left top horizontal Right noreverse enhanced autotitles columnhead nobox
+set key noinvert samplen 4 spacing 1 width 0 height 0
+set key maxcolumns 2 maxrows 0
+unset label
+unset arrow
+set style increment default
+unset style line
+set style line 1 linetype 1 linewidth 2.000 pointtype 1 pointsize default pointinterval 0
+unset style arrow
+set style histogram clustered gap 2 title offset character 0, 0, 0
+unset logscale
+set offsets graph 0.05, 0.15, 0, 0
+set pointsize 1.5
+set pointintervalbox 1
+set encoding default
+unset polar
+unset parametric
+unset decimalsign
+set view 60, 30, 1, 1
+set samples 100, 100
+set isosamples 10, 10
+set surface
+unset contour
+set clabel '%8.3g'
+set mapping cartesian
+set datafile separator whitespace
+unset hidden3d
+set cntrparam order 4
+set cntrparam linear
+set cntrparam levels auto 5
+set cntrparam points 5
+set size ratio 0 1,1
+set origin 0,0
+set style data points
+set style function lines
+set xzeroaxis linetype -2 linewidth 1.000
+set yzeroaxis linetype -2 linewidth 1.000
+set zzeroaxis linetype -2 linewidth 1.000
+set x2zeroaxis linetype -2 linewidth 1.000
+set y2zeroaxis linetype -2 linewidth 1.000
+set ticslevel 0.5
+set mxtics default
+set mytics default
+set mztics default
+set mx2tics default
+set my2tics default
+set mcbtics default
+set xtics border in scale 1,0.5 mirror norotate offset character 0, 0, 0
+set xtics norangelimit
+set xtics ()
+set ytics border in scale 1,0.5 mirror norotate offset character 0, 0, 0
+set ytics autofreq norangelimit
+set ztics border in scale 1,0.5 nomirror norotate offset character 0, 0, 0
+set ztics autofreq norangelimit
+set nox2tics
+set noy2tics
+set cbtics border in scale 1,0.5 mirror norotate offset character 0, 0, 0
+set cbtics autofreq norangelimit
+set title ""
+set title offset character 0, 0, 0 font "" norotate
+set timestamp bottom
+set timestamp ""
+set timestamp offset character 0, 0, 0 font "" norotate
+set rrange [ * : * ] noreverse nowriteback # (currently [8.98847e+307:-8.98847e+307] )
+set autoscale rfixmin
+set autoscale rfixmax
+set trange [ * : * ] noreverse nowriteback # (currently [-5.00000:5.00000] )
+set autoscale tfixmin
+set autoscale tfixmax
+set urange [ * : * ] noreverse nowriteback # (currently [-10.0000:10.0000] )
+set autoscale ufixmin
+set autoscale ufixmax
+set vrange [ * : * ] noreverse nowriteback # (currently [-10.0000:10.0000] )
+set autoscale vfixmin
+set autoscale vfixmax
+set xlabel ""
+set xlabel offset character 0, 0, 0 font "" textcolor lt -1 norotate
+set x2label ""
+set x2label offset character 0, 0, 0 font "" textcolor lt -1 norotate
+set xrange [ * : * ] noreverse nowriteback # (currently [-0.150000:3.15000] )
+set autoscale xfixmin
+set autoscale xfixmax
+set x2range [ * : * ] noreverse nowriteback # (currently [0.00000:3.00000] )
+set autoscale x2fixmin
+set autoscale x2fixmax
+set ylabel ""
+set ylabel offset character 0, 0, 0 font "" textcolor lt -1 rotate by -270
+set y2label ""
+set y2label offset character 0, 0, 0 font "" textcolor lt -1 rotate by -270
+set yrange [ 0.00000 : 1.90000e+06 ] noreverse nowriteback # (currently [:] )
+set autoscale yfixmin
+set autoscale yfixmax
+set y2range [ * : * ] noreverse nowriteback # (currently [0.00000:1.90000e+06] )
+set autoscale y2fixmin
+set autoscale y2fixmax
+set zlabel ""
+set zlabel offset character 0, 0, 0 font "" textcolor lt -1 norotate
+set zrange [ * : * ] noreverse nowriteback # (currently [-10.0000:10.0000] )
+set autoscale zfixmin
+set autoscale zfixmax
+set cblabel ""
+set cblabel offset character 0, 0, 0 font "" textcolor lt -1 rotate by -270
+set cbrange [ * : * ] noreverse nowriteback # (currently [8.98847e+307:-8.98847e+307] )
+set autoscale cbfixmin
+set autoscale cbfixmax
+set zero 1e-08
+set lmargin -1
+set bmargin -1
+set rmargin -1
+set tmargin -1
+set pm3d explicit at s
+set pm3d scansautomatic
+set pm3d interpolate 1,1 flush begin noftriangles nohidden3d corners2color mean
+set palette positive nops_allcF maxcolors 0 gamma 1.5 color model RGB
+set palette rgbformulae 7, 5, 15
+set colorbox default
+set colorbox vertical origin screen 0.9, 0.2, 0 size screen 0.05, 0.6, 0 front bdefault
+set loadpath
+set fontpath
+set fit noerrorvariables
+GNUTERM = "aqua"
+plot 'bench_results.txt' using 2:xticlabel(1) w lp lw 2, '' using 3:xticlabel(1) w lp lw 2, '' using 4:xticlabel(1) w lp lw 2, '' using 5:xticlabel(1) w lp lw 2, '' using 6:xticlabel(1) w lp lw 2, '' using 7:xticlabel(1) w lp lw 2, '' using 8:xticlabel(1) w lp lw 2, '' using 9:xticlabel(1) w lp lw 2
+# EOF
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/node-uuid/benchmark/bench.sh
----------------------------------------------------------------------
diff --git a/node_modules/node-uuid/benchmark/bench.sh b/node_modules/node-uuid/benchmark/bench.sh
new file mode 100644
index 0000000..d870a0c
--- /dev/null
+++ b/node_modules/node-uuid/benchmark/bench.sh
@@ -0,0 +1,34 @@
+#!/bin/bash
+
+# for a given node version run:
+# for i in {0..9}; do node benchmark.js >> bench_0.6.2.log; done;
+
+PATTERNS=('nodeuuid.v1()' "nodeuuid.v1('binary'," 'nodeuuid.v4()' "nodeuuid.v4('binary'," "uuid()" "uuid('binary')" 'uuidjs.create(1)' 'uuidjs.create(4)' '140byte')
+FILES=(node_uuid_v1_string node_uuid_v1_buf node_uuid_v4_string node_uuid_v4_buf libuuid_v4_string libuuid_v4_binary uuidjs_v1_string uuidjs_v4_string 140byte_es)
+INDICES=(2 3 2 3 2 2 2 2 2)
+VERSIONS=$( ls bench_*.log | sed -e 's/^bench_\([0-9\.]*\)\.log/\1/' | tr "\\n" " " )
+TMPJOIN="tmp_join"
+OUTPUT="bench_results.txt"
+
+for I in ${!FILES[*]}; do
+ F=${FILES[$I]}
+ P=${PATTERNS[$I]}
+ INDEX=${INDICES[$I]}
+ echo "version $F" > $F
+ for V in $VERSIONS; do
+ (VAL=$( grep "$P" bench_$V.log | LC_ALL=en_US awk '{ sum += $'$INDEX' } END { print sum/NR }' ); echo $V $VAL) >> $F
+ done
+ if [ $I == 0 ]; then
+ cat $F > $TMPJOIN
+ else
+ join $TMPJOIN $F > $OUTPUT
+ cp $OUTPUT $TMPJOIN
+ fi
+ rm $F
+done
+
+rm $TMPJOIN
+
+gnuplot bench.gnu
+convert -density 200 -resize 800x560 -flatten bench.eps bench.png
+rm bench.eps
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/node-uuid/benchmark/benchmark-native.c
----------------------------------------------------------------------
diff --git a/node_modules/node-uuid/benchmark/benchmark-native.c b/node_modules/node-uuid/benchmark/benchmark-native.c
new file mode 100644
index 0000000..dbfc75f
--- /dev/null
+++ b/node_modules/node-uuid/benchmark/benchmark-native.c
@@ -0,0 +1,34 @@
+/*
+Test performance of native C UUID generation
+
+To Compile: cc -luuid benchmark-native.c -o benchmark-native
+*/
+
+#include <stdio.h>
+#include <unistd.h>
+#include <sys/time.h>
+#include <uuid/uuid.h>
+
+int main() {
+ uuid_t myid;
+ char buf[36+1];
+ int i;
+ struct timeval t;
+ double start, finish;
+
+ gettimeofday(&t, NULL);
+ start = t.tv_sec + t.tv_usec/1e6;
+
+ int n = 2e5;
+ for (i = 0; i < n; i++) {
+ uuid_generate(myid);
+ uuid_unparse(myid, buf);
+ }
+
+ gettimeofday(&t, NULL);
+ finish = t.tv_sec + t.tv_usec/1e6;
+ double dur = finish - start;
+
+ printf("%d uuids/sec", (int)(n/dur));
+ return 0;
+}
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/node-uuid/benchmark/benchmark.js
----------------------------------------------------------------------
diff --git a/node_modules/node-uuid/benchmark/benchmark.js b/node_modules/node-uuid/benchmark/benchmark.js
new file mode 100644
index 0000000..40e6efb
--- /dev/null
+++ b/node_modules/node-uuid/benchmark/benchmark.js
@@ -0,0 +1,84 @@
+try {
+ var nodeuuid = require('../uuid');
+} catch (e) {
+ console.error('node-uuid require failed - skipping tests');
+}
+
+try {
+ var uuid = require('uuid');
+} catch (e) {
+ console.error('uuid require failed - skipping tests');
+}
+
+try {
+ var uuidjs = require('uuid-js');
+} catch (e) {
+ console.error('uuid-js require failed - skipping tests');
+}
+
+var N = 5e5;
+
+function rate(msg, t) {
+ console.log(msg + ': ' +
+ (N / (Date.now() - t) * 1e3 | 0) +
+ ' uuids/second');
+}
+
+console.log('# v4');
+
+// node-uuid - string form
+if (nodeuuid) {
+ for (var i = 0, t = Date.now(); i < N; i++) nodeuuid.v4();
+ rate('nodeuuid.v4() - using node.js crypto RNG', t);
+
+ for (var i = 0, t = Date.now(); i < N; i++) nodeuuid.v4({rng: nodeuuid.mathRNG});
+ rate('nodeuuid.v4() - using Math.random() RNG', t);
+
+ for (var i = 0, t = Date.now(); i < N; i++) nodeuuid.v4('binary');
+ rate('nodeuuid.v4(\'binary\')', t);
+
+ var buffer = new nodeuuid.BufferClass(16);
+ for (var i = 0, t = Date.now(); i < N; i++) nodeuuid.v4('binary', buffer);
+ rate('nodeuuid.v4(\'binary\', buffer)', t);
+}
+
+// libuuid - string form
+if (uuid) {
+ for (var i = 0, t = Date.now(); i < N; i++) uuid();
+ rate('uuid()', t);
+
+ for (var i = 0, t = Date.now(); i < N; i++) uuid('binary');
+ rate('uuid(\'binary\')', t);
+}
+
+// uuid-js - string form
+if (uuidjs) {
+ for (var i = 0, t = Date.now(); i < N; i++) uuidjs.create(4);
+ rate('uuidjs.create(4)', t);
+}
+
+// 140byte.es
+for (var i = 0, t = Date.now(); i < N; i++) 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g,function(s,r){r=Math.random()*16|0;return (s=='x'?r:r&0x3|0x8).toString(16)});
+rate('140byte.es_v4', t);
+
+console.log('');
+console.log('# v1');
+
+// node-uuid - v1 string form
+if (nodeuuid) {
+ for (var i = 0, t = Date.now(); i < N; i++) nodeuuid.v1();
+ rate('nodeuuid.v1()', t);
+
+ for (var i = 0, t = Date.now(); i < N; i++) nodeuuid.v1('binary');
+ rate('nodeuuid.v1(\'binary\')', t);
+
+ var buffer = new nodeuuid.BufferClass(16);
+ for (var i = 0, t = Date.now(); i < N; i++) nodeuuid.v1('binary', buffer);
+ rate('nodeuuid.v1(\'binary\', buffer)', t);
+}
+
+// uuid-js - v1 string form
+if (uuidjs) {
+ for (var i = 0, t = Date.now(); i < N; i++) uuidjs.create(1);
+ rate('uuidjs.create(1)', t);
+}
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/node-uuid/bower.json
----------------------------------------------------------------------
diff --git a/node_modules/node-uuid/bower.json b/node_modules/node-uuid/bower.json
index 1656dc8..c0925e1 100644
--- a/node_modules/node-uuid/bower.json
+++ b/node_modules/node-uuid/bower.json
@@ -1,6 +1,6 @@
{
"name": "node-uuid",
- "version": "1.4.3",
+ "version": "1.4.7",
"homepage": "https://github.com/broofa/node-uuid",
"authors": [
"Robert Kieffer <ro...@broofa.com>"
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/node-uuid/component.json
----------------------------------------------------------------------
diff --git a/node_modules/node-uuid/component.json b/node_modules/node-uuid/component.json
index 149f84b..3ff4633 100644
--- a/node_modules/node-uuid/component.json
+++ b/node_modules/node-uuid/component.json
@@ -2,12 +2,19 @@
"name": "node-uuid",
"repo": "broofa/node-uuid",
"description": "Rigorous implementation of RFC4122 (v1 and v4) UUIDs.",
- "version": "1.4.3",
+ "version": "1.4.7",
"author": "Robert Kieffer <ro...@broofa.com>",
"contributors": [
- {"name": "Christoph Tavan <de...@tavan.de>", "github": "https://github.com/ctavan"}
+ {
+ "name": "Christoph Tavan <de...@tavan.de>",
+ "github": "https://github.com/ctavan"
+ }
+ ],
+ "keywords": [
+ "uuid",
+ "guid",
+ "rfc4122"
],
- "keywords": ["uuid", "guid", "rfc4122"],
"dependencies": {},
"development": {},
"main": "uuid.js",
@@ -15,4 +22,4 @@
"uuid.js"
],
"license": "MIT"
-}
+}
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/node-uuid/package.json
----------------------------------------------------------------------
diff --git a/node_modules/node-uuid/package.json b/node_modules/node-uuid/package.json
index a152eed..964a781 100644
--- a/node_modules/node-uuid/package.json
+++ b/node_modules/node-uuid/package.json
@@ -1,65 +1,105 @@
{
- "name": "node-uuid",
- "description": "Rigorous implementation of RFC4122 (v1 and v4) UUIDs.",
- "url": "http://github.com/broofa/node-uuid",
- "keywords": [
- "uuid",
- "guid",
- "rfc4122"
+ "_args": [
+ [
+ "node-uuid@^1.4.3",
+ "D:\\Cordova\\cordova-windows"
+ ]
],
+ "_from": "node-uuid@>=1.4.3 <2.0.0",
+ "_id": "node-uuid@1.4.7",
+ "_inCache": true,
+ "_installable": true,
+ "_location": "/node-uuid",
+ "_nodeVersion": "5.0.0",
+ "_npmUser": {
+ "email": "coolaj86@gmail.com",
+ "name": "coolaj86"
+ },
+ "_npmVersion": "3.3.6",
+ "_phantomChildren": {},
+ "_requested": {
+ "name": "node-uuid",
+ "raw": "node-uuid@^1.4.3",
+ "rawSpec": "^1.4.3",
+ "scope": null,
+ "spec": ">=1.4.3 <2.0.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/"
+ ],
+ "_resolved": "https://registry.npmjs.org/node-uuid/-/node-uuid-1.4.7.tgz",
+ "_shasum": "6da5a17668c4b3dd59623bda11cf7fa4c1f60a6f",
+ "_shrinkwrap": null,
+ "_spec": "node-uuid@^1.4.3",
+ "_where": "D:\\Cordova\\cordova-windows",
"author": {
- "name": "Robert Kieffer",
- "email": "robert@broofa.com"
+ "email": "robert@broofa.com",
+ "name": "Robert Kieffer"
+ },
+ "bin": {
+ "uuid": "./bin/uuid"
+ },
+ "bugs": {
+ "url": "https://github.com/broofa/node-uuid/issues"
},
"contributors": [
{
- "name": "Christoph Tavan",
- "email": "dev@tavan.de"
+ "email": "coolaj86@gmail.com",
+ "name": "AJ ONeal"
+ },
+ {
+ "email": "dev@tavan.de",
+ "name": "Christoph Tavan"
}
],
- "bin": {
- "uuid": "./bin/uuid"
+ "dependencies": {},
+ "description": "Rigorous implementation of RFC4122 (v1 and v4) UUIDs.",
+ "devDependencies": {
+ "nyc": "^2.2.0"
},
- "scripts": {
- "test": "node test/test.js"
+ "directories": {},
+ "dist": {
+ "shasum": "6da5a17668c4b3dd59623bda11cf7fa4c1f60a6f",
+ "tarball": "https://registry.npmjs.org/node-uuid/-/node-uuid-1.4.7.tgz"
},
+ "gitHead": "309512573ec1c60143c257157479a20f7f1f51cd",
+ "homepage": "https://github.com/broofa/node-uuid",
+ "installable": true,
+ "keywords": [
+ "guid",
+ "rfc4122",
+ "uuid"
+ ],
"lib": ".",
- "main": "./uuid.js",
- "repository": {
- "type": "git",
- "url": "git+https://github.com/broofa/node-uuid.git"
- },
- "version": "1.4.3",
"licenses": [
{
"type": "MIT",
"url": "https://raw.github.com/broofa/node-uuid/master/LICENSE.md"
}
],
- "gitHead": "886463c660a095dfebfa69603921a8d156fdb12c",
- "bugs": {
- "url": "https://github.com/broofa/node-uuid/issues"
- },
- "homepage": "https://github.com/broofa/node-uuid",
- "_id": "node-uuid@1.4.3",
- "_shasum": "319bb7a56e7cb63f00b5c0cd7851cd4b4ddf1df9",
- "_from": "node-uuid@>=1.4.3 <2.0.0",
- "_npmVersion": "1.4.28",
- "_npmUser": {
- "name": "broofa",
- "email": "robert@broofa.com"
- },
+ "main": "./uuid.js",
"maintainers": [
{
- "name": "broofa",
- "email": "robert@broofa.com"
+ "email": "robert@broofa.com",
+ "name": "broofa"
+ },
+ {
+ "email": "coolaj86@gmail.com",
+ "name": "coolaj86"
}
],
- "dist": {
- "shasum": "319bb7a56e7cb63f00b5c0cd7851cd4b4ddf1df9",
- "tarball": "http://registry.npmjs.org/node-uuid/-/node-uuid-1.4.3.tgz"
+ "name": "node-uuid",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/broofa/node-uuid.git"
},
- "directories": {},
- "_resolved": "https://registry.npmjs.org/node-uuid/-/node-uuid-1.4.3.tgz",
- "readme": "ERROR: No README data found!"
+ "scripts": {
+ "coverage": "nyc npm test && nyc report",
+ "test": "node test/test.js"
+ },
+ "url": "http://github.com/broofa/node-uuid",
+ "version": "1.4.7"
}
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/node-uuid/test/compare_v1.js
----------------------------------------------------------------------
diff --git a/node_modules/node-uuid/test/compare_v1.js b/node_modules/node-uuid/test/compare_v1.js
new file mode 100644
index 0000000..05af822
--- /dev/null
+++ b/node_modules/node-uuid/test/compare_v1.js
@@ -0,0 +1,63 @@
+var assert = require('assert'),
+ nodeuuid = require('../uuid'),
+ uuidjs = require('uuid-js'),
+ libuuid = require('uuid').generate,
+ util = require('util'),
+ exec = require('child_process').exec,
+ os = require('os');
+
+// On Mac Os X / macports there's only the ossp-uuid package that provides uuid
+// On Linux there's uuid-runtime which provides uuidgen
+var uuidCmd = os.type() === 'Darwin' ? 'uuid -1' : 'uuidgen -t';
+
+function compare(ids) {
+ console.log(ids);
+ for (var i = 0; i < ids.length; i++) {
+ var id = ids[i].split('-');
+ id = [id[2], id[1], id[0]].join('');
+ ids[i] = id;
+ }
+ var sorted = ([].concat(ids)).sort();
+
+ if (sorted.toString() !== ids.toString()) {
+ console.log('Warning: sorted !== ids');
+ } else {
+ console.log('everything in order!');
+ }
+}
+
+// Test time order of v1 uuids
+var ids = [];
+while (ids.length < 10e3) ids.push(nodeuuid.v1());
+
+var max = 10;
+console.log('node-uuid:');
+ids = [];
+for (var i = 0; i < max; i++) ids.push(nodeuuid.v1());
+compare(ids);
+
+console.log('');
+console.log('uuidjs:');
+ids = [];
+for (var i = 0; i < max; i++) ids.push(uuidjs.create(1).toString());
+compare(ids);
+
+console.log('');
+console.log('libuuid:');
+ids = [];
+var count = 0;
+var last = function() {
+ compare(ids);
+}
+var cb = function(err, stdout, stderr) {
+ ids.push(stdout.substring(0, stdout.length-1));
+ count++;
+ if (count < max) {
+ return next();
+ }
+ last();
+};
+var next = function() {
+ exec(uuidCmd, cb);
+};
+next();
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/node-uuid/test/test.html
----------------------------------------------------------------------
diff --git a/node_modules/node-uuid/test/test.html b/node_modules/node-uuid/test/test.html
new file mode 100644
index 0000000..d80326e
--- /dev/null
+++ b/node_modules/node-uuid/test/test.html
@@ -0,0 +1,17 @@
+<html>
+ <head>
+ <style>
+ div {
+ font-family: monospace;
+ font-size: 8pt;
+ }
+ div.log {color: #444;}
+ div.warn {color: #550;}
+ div.error {color: #800; font-weight: bold;}
+ </style>
+ <script src="../uuid.js"></script>
+ </head>
+ <body>
+ <script src="./test.js"></script>
+ </body>
+</html>
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/node-uuid/test/test.js
----------------------------------------------------------------------
diff --git a/node_modules/node-uuid/test/test.js b/node_modules/node-uuid/test/test.js
new file mode 100644
index 0000000..5f1113d
--- /dev/null
+++ b/node_modules/node-uuid/test/test.js
@@ -0,0 +1,231 @@
+if (!this.uuid) {
+ // node.js
+ uuid = require('../uuid');
+ if (!/_rb/.test(uuid._rng.toString())) {
+ throw new Error("should use crypto for node.js");
+ }
+}
+
+//
+// x-platform log/assert shims
+//
+
+function _log(msg, type) {
+ type = type || 'log';
+
+ if (typeof(document) != 'undefined') {
+ document.write('<div class="' + type + '">' + msg.replace(/\n/g, '<br />') + '</div>');
+ }
+ if (typeof(console) != 'undefined') {
+ var color = {
+ log: '\033[39m',
+ warn: '\033[33m',
+ error: '\033[31m'
+ };
+ console[type](color[type] + msg + color.log);
+ }
+}
+
+function log(msg) {_log(msg, 'log');}
+function warn(msg) {_log(msg, 'warn');}
+function error(msg) {_log(msg, 'error');}
+
+function assert(res, msg) {
+ if (!res) {
+ error('FAIL: ' + msg);
+ } else {
+ log('Pass: ' + msg);
+ }
+}
+
+//
+// Unit tests
+//
+
+// Verify ordering of v1 ids created with explicit times
+var TIME = 1321644961388; // 2011-11-18 11:36:01.388-08:00
+
+function compare(name, ids) {
+ ids = ids.map(function(id) {
+ return id.split('-').reverse().join('-');
+ }).sort();
+ var sorted = ([].concat(ids)).sort();
+
+ assert(sorted.toString() == ids.toString(), name + ' have expected order');
+}
+
+// Verify ordering of v1 ids created using default behavior
+compare('uuids with current time', [
+ uuid.v1(),
+ uuid.v1(),
+ uuid.v1(),
+ uuid.v1(),
+ uuid.v1()
+]);
+
+// Verify ordering of v1 ids created with explicit times
+compare('uuids with time option', [
+ uuid.v1({msecs: TIME - 10*3600*1000}),
+ uuid.v1({msecs: TIME - 1}),
+ uuid.v1({msecs: TIME}),
+ uuid.v1({msecs: TIME + 1}),
+ uuid.v1({msecs: TIME + 28*24*3600*1000})
+]);
+
+assert(
+ uuid.v1({msecs: TIME}) != uuid.v1({msecs: TIME}),
+ 'IDs created at same msec are different'
+);
+
+// Verify throw if too many ids created
+var thrown = false;
+try {
+ uuid.v1({msecs: TIME, nsecs: 10000});
+} catch (e) {
+ thrown = true;
+}
+assert(thrown, 'Exception thrown when > 10K ids created in 1 ms');
+
+// Verify clock regression bumps clockseq
+var uidt = uuid.v1({msecs: TIME});
+var uidtb = uuid.v1({msecs: TIME - 1});
+assert(
+ parseInt(uidtb.split('-')[3], 16) - parseInt(uidt.split('-')[3], 16) === 1,
+ 'Clock regression by msec increments the clockseq'
+);
+
+// Verify clock regression bumps clockseq
+var uidtn = uuid.v1({msecs: TIME, nsecs: 10});
+var uidtnb = uuid.v1({msecs: TIME, nsecs: 9});
+assert(
+ parseInt(uidtnb.split('-')[3], 16) - parseInt(uidtn.split('-')[3], 16) === 1,
+ 'Clock regression by nsec increments the clockseq'
+);
+
+// Verify explicit options produce expected id
+var id = uuid.v1({
+ msecs: 1321651533573,
+ nsecs: 5432,
+ clockseq: 0x385c,
+ node: [ 0x61, 0xcd, 0x3c, 0xbb, 0x32, 0x10 ]
+});
+assert(id == 'd9428888-122b-11e1-b85c-61cd3cbb3210', 'Explicit options produce expected id');
+
+// Verify adjacent ids across a msec boundary are 1 time unit apart
+var u0 = uuid.v1({msecs: TIME, nsecs: 9999});
+var u1 = uuid.v1({msecs: TIME + 1, nsecs: 0});
+
+var before = u0.split('-')[0], after = u1.split('-')[0];
+var dt = parseInt(after, 16) - parseInt(before, 16);
+assert(dt === 1, 'Ids spanning 1ms boundary are 100ns apart');
+
+//
+// Test parse/unparse
+//
+
+id = '00112233445566778899aabbccddeeff';
+assert(uuid.unparse(uuid.parse(id.substr(0,10))) ==
+ '00112233-4400-0000-0000-000000000000', 'Short parse');
+assert(uuid.unparse(uuid.parse('(this is the uuid -> ' + id + id)) ==
+ '00112233-4455-6677-8899-aabbccddeeff', 'Dirty parse');
+
+//
+// Perf tests
+//
+
+var generators = {
+ v1: uuid.v1,
+ v4: uuid.v4
+};
+
+var UUID_FORMAT = {
+ v1: /[0-9a-f]{8}-[0-9a-f]{4}-1[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}/i,
+ v4: /[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}/i
+};
+
+var N = 1e4;
+
+// Get %'age an actual value differs from the ideal value
+function divergence(actual, ideal) {
+ return Math.round(100*100*(actual - ideal)/ideal)/100;
+}
+
+function rate(msg, t) {
+ log(msg + ': ' + (N / (Date.now() - t) * 1e3 | 0) + ' uuids\/second');
+}
+
+for (var version in generators) {
+ var counts = {}, max = 0;
+ var generator = generators[version];
+ var format = UUID_FORMAT[version];
+
+ log('\nSanity check ' + N + ' ' + version + ' uuids');
+ for (var i = 0, ok = 0; i < N; i++) {
+ id = generator();
+ if (!format.test(id)) {
+ throw Error(id + ' is not a valid UUID string');
+ }
+
+ if (id != uuid.unparse(uuid.parse(id))) {
+ assert(fail, id + ' is not a valid id');
+ }
+
+ // Count digits for our randomness check
+ if (version == 'v4') {
+ var digits = id.replace(/-/g, '').split('');
+ for (var j = digits.length-1; j >= 0; j--) {
+ var c = digits[j];
+ max = Math.max(max, counts[c] = (counts[c] || 0) + 1);
+ }
+ }
+ }
+
+ // Check randomness for v4 UUIDs
+ if (version == 'v4') {
+ // Limit that we get worried about randomness. (Purely empirical choice, this!)
+ var limit = 2*100*Math.sqrt(1/N);
+
+ log('\nChecking v4 randomness. Distribution of Hex Digits (% deviation from ideal)');
+
+ for (var i = 0; i < 16; i++) {
+ var c = i.toString(16);
+ var bar = '', n = counts[c], p = Math.round(n/max*100|0);
+
+ // 1-3,5-8, and D-F: 1:16 odds over 30 digits
+ var ideal = N*30/16;
+ if (i == 4) {
+ // 4: 1:1 odds on 1 digit, plus 1:16 odds on 30 digits
+ ideal = N*(1 + 30/16);
+ } else if (i >= 8 && i <= 11) {
+ // 8-B: 1:4 odds on 1 digit, plus 1:16 odds on 30 digits
+ ideal = N*(1/4 + 30/16);
+ } else {
+ // Otherwise: 1:16 odds on 30 digits
+ ideal = N*30/16;
+ }
+ var d = divergence(n, ideal);
+
+ // Draw bar using UTF squares (just for grins)
+ var s = n/max*50 | 0;
+ while (s--) bar += '=';
+
+ assert(Math.abs(d) < limit, c + ' |' + bar + '| ' + counts[c] + ' (' + d + '% < ' + limit + '%)');
+ }
+ }
+}
+
+// Perf tests
+for (var version in generators) {
+ log('\nPerformance testing ' + version + ' UUIDs');
+ var generator = generators[version];
+ var buf = new uuid.BufferClass(16);
+
+ for (var i = 0, t = Date.now(); i < N; i++) generator();
+ rate('uuid.' + version + '()', t);
+
+ for (var i = 0, t = Date.now(); i < N; i++) generator('binary');
+ rate('uuid.' + version + '(\'binary\')', t);
+
+ for (var i = 0, t = Date.now(); i < N; i++) generator('binary', buf);
+ rate('uuid.' + version + '(\'binary\', buffer)', t);
+}
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/node-uuid/uuid.js
----------------------------------------------------------------------
diff --git a/node_modules/node-uuid/uuid.js b/node_modules/node-uuid/uuid.js
index 0a61769..89c5b8f 100644
--- a/node_modules/node-uuid/uuid.js
+++ b/node_modules/node-uuid/uuid.js
@@ -3,53 +3,74 @@
// Copyright (c) 2010-2012 Robert Kieffer
// MIT License - http://opensource.org/licenses/mit-license.php
-(function() {
- var _global = this;
+/*global window, require, define */
+(function(_window) {
+ 'use strict';
// Unique ID creation requires a high quality random # generator. We feature
// detect to determine the best RNG source, normalizing to a function that
// returns 128-bits of randomness, since that's what's usually required
- var _rng;
+ var _rng, _mathRNG, _nodeRNG, _whatwgRNG, _previousRoot;
+
+ function setupBrowser() {
+ // Allow for MSIE11 msCrypto
+ var _crypto = _window.crypto || _window.msCrypto;
+
+ if (!_rng && _crypto && _crypto.getRandomValues) {
+ // WHATWG crypto-based RNG - http://wiki.whatwg.org/wiki/Crypto
+ //
+ // Moderately fast, high quality
+ try {
+ var _rnds8 = new Uint8Array(16);
+ _whatwgRNG = _rng = function whatwgRNG() {
+ _crypto.getRandomValues(_rnds8);
+ return _rnds8;
+ };
+ _rng();
+ } catch(e) {}
+ }
- // Node.js crypto-based RNG - http://nodejs.org/docs/v0.6.2/api/crypto.html
- //
- // Moderately fast, high quality
- if (typeof(_global.require) == 'function') {
- try {
- var _rb = _global.require('crypto').randomBytes;
- _rng = _rb && function() {return _rb(16);};
- } catch(e) {}
+ if (!_rng) {
+ // Math.random()-based (RNG)
+ //
+ // If all else fails, use Math.random(). It's fast, but is of unspecified
+ // quality.
+ var _rnds = new Array(16);
+ _mathRNG = _rng = function() {
+ for (var i = 0, r; i < 16; i++) {
+ if ((i & 0x03) === 0) { r = Math.random() * 0x100000000; }
+ _rnds[i] = r >>> ((i & 0x03) << 3) & 0xff;
+ }
+
+ return _rnds;
+ };
+ if ('undefined' !== typeof console && console.warn) {
+ console.warn("[SECURITY] node-uuid: crypto not usable, falling back to insecure Math.random()");
+ }
+ }
}
- if (!_rng && _global.crypto && crypto.getRandomValues) {
- // WHATWG crypto-based RNG - http://wiki.whatwg.org/wiki/Crypto
+ function setupNode() {
+ // Node.js crypto-based RNG - http://nodejs.org/docs/v0.6.2/api/crypto.html
//
// Moderately fast, high quality
- var _rnds8 = new Uint8Array(16);
- _rng = function whatwgRNG() {
- crypto.getRandomValues(_rnds8);
- return _rnds8;
- };
+ if ('function' === typeof require) {
+ try {
+ var _rb = require('crypto').randomBytes;
+ _nodeRNG = _rng = _rb && function() {return _rb(16);};
+ _rng();
+ } catch(e) {}
+ }
}
- if (!_rng) {
- // Math.random()-based (RNG)
- //
- // If all else fails, use Math.random(). It's fast, but is of unspecified
- // quality.
- var _rnds = new Array(16);
- _rng = function() {
- for (var i = 0, r; i < 16; i++) {
- if ((i & 0x03) === 0) r = Math.random() * 0x100000000;
- _rnds[i] = r >>> ((i & 0x03) << 3) & 0xff;
- }
-
- return _rnds;
- };
+ if (_window) {
+ setupBrowser();
+ } else {
+ setupNode();
}
// Buffer class to use
- var BufferClass = typeof(_global.Buffer) == 'function' ? _global.Buffer : Array;
+ var BufferClass = ('function' === typeof Buffer) ? Buffer : Array;
// Maps for number <-> hex string conversion
var _byteToHex = [];
@@ -118,17 +139,17 @@
options = options || {};
- var clockseq = options.clockseq != null ? options.clockseq : _clockseq;
+ var clockseq = (options.clockseq != null) ? options.clockseq : _clockseq;
// UUID timestamps are 100 nano-second units since the Gregorian epoch,
// (1582-10-15 00:00). JSNumbers aren't precise enough for this, so
// time is handled internally as 'msecs' (integer milliseconds) and 'nsecs'
// (100-nanoseconds offset from msecs) since unix epoch, 1970-01-01 00:00.
- var msecs = options.msecs != null ? options.msecs : new Date().getTime();
+ var msecs = (options.msecs != null) ? options.msecs : new Date().getTime();
// Per 4.2.1.2, use count of uuid's generated during the current clock
// cycle to simulate higher resolution clock
- var nsecs = options.nsecs != null ? options.nsecs : _lastNSecs + 1;
+ var nsecs = (options.nsecs != null) ? options.nsecs : _lastNSecs + 1;
// Time since last uuid creation (in msecs)
var dt = (msecs - _lastMSecs) + (nsecs - _lastNSecs)/10000;
@@ -194,8 +215,8 @@
// Deprecated - 'format' argument, as supported in v1.2
var i = buf && offset || 0;
- if (typeof(options) == 'string') {
- buf = options == 'binary' ? new BufferClass(16) : null;
+ if (typeof(options) === 'string') {
+ buf = (options === 'binary') ? new BufferClass(16) : null;
options = null;
}
options = options || {};
@@ -223,25 +244,29 @@
uuid.parse = parse;
uuid.unparse = unparse;
uuid.BufferClass = BufferClass;
+ uuid._rng = _rng;
+ uuid._mathRNG = _mathRNG;
+ uuid._nodeRNG = _nodeRNG;
+ uuid._whatwgRNG = _whatwgRNG;
- if (typeof(module) != 'undefined' && module.exports) {
+ if (('undefined' !== typeof module) && module.exports) {
// Publish as node.js module
module.exports = uuid;
- } else if (typeof define === 'function' && define.amd) {
+ } else if (typeof define === 'function' && define.amd) {
// Publish as AMD module
define(function() {return uuid;});
-
+
} else {
// Publish as global (in browsers)
- var _previousRoot = _global.uuid;
+ _previousRoot = _window.uuid;
// **`noConflict()` - (browser only) to reset global 'uuid' var**
uuid.noConflict = function() {
- _global.uuid = _previousRoot;
+ _window.uuid = _previousRoot;
return uuid;
};
- _global.uuid = uuid;
+ _window.uuid = uuid;
}
-}).call(this);
+})('undefined' !== typeof window ? window : null);
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/nopt/examples/my-program.js
----------------------------------------------------------------------
diff --git a/node_modules/nopt/examples/my-program.js b/node_modules/nopt/examples/my-program.js
new file mode 100644
index 0000000..142447e
--- /dev/null
+++ b/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))
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/nopt/lib/nopt.js
----------------------------------------------------------------------
diff --git a/node_modules/nopt/lib/nopt.js b/node_modules/nopt/lib/nopt.js
index 5309a00..97707e7 100644
--- a/node_modules/nopt/lib/nopt.js
+++ b/node_modules/nopt/lib/nopt.js
@@ -207,7 +207,8 @@ function validate (data, k, val, type, 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) {
+ if (t &&
+ ((type && type.name && t.type && t.type.name) ? (type.name === t.type.name) : (type === t.type))) {
var d = {}
ok = false !== t.validate(d, k, val)
val = d[k]
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/nopt/node_modules/abbrev/.npmignore
----------------------------------------------------------------------
diff --git a/node_modules/nopt/node_modules/abbrev/.npmignore b/node_modules/nopt/node_modules/abbrev/.npmignore
deleted file mode 100644
index 9d6cd2f..0000000
--- a/node_modules/nopt/node_modules/abbrev/.npmignore
+++ /dev/null
@@ -1,4 +0,0 @@
-.nyc_output
-nyc_output
-node_modules
-coverage
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/nopt/node_modules/abbrev/.travis.yml
----------------------------------------------------------------------
diff --git a/node_modules/nopt/node_modules/abbrev/.travis.yml b/node_modules/nopt/node_modules/abbrev/.travis.yml
deleted file mode 100644
index 991d04b..0000000
--- a/node_modules/nopt/node_modules/abbrev/.travis.yml
+++ /dev/null
@@ -1,5 +0,0 @@
-language: node_js
-node_js:
- - '0.10'
- - '0.12'
- - 'iojs'
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/nopt/node_modules/abbrev/CONTRIBUTING.md
----------------------------------------------------------------------
diff --git a/node_modules/nopt/node_modules/abbrev/CONTRIBUTING.md b/node_modules/nopt/node_modules/abbrev/CONTRIBUTING.md
deleted file mode 100644
index 2f30261..0000000
--- a/node_modules/nopt/node_modules/abbrev/CONTRIBUTING.md
+++ /dev/null
@@ -1,3 +0,0 @@
- To get started, <a
- href="http://www.clahub.com/agreements/isaacs/abbrev-js">sign the
- Contributor License Agreement</a>.
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/nopt/node_modules/abbrev/LICENSE
----------------------------------------------------------------------
diff --git a/node_modules/nopt/node_modules/abbrev/LICENSE b/node_modules/nopt/node_modules/abbrev/LICENSE
deleted file mode 100644
index 19129e3..0000000
--- a/node_modules/nopt/node_modules/abbrev/LICENSE
+++ /dev/null
@@ -1,15 +0,0 @@
-The ISC License
-
-Copyright (c) Isaac Z. Schlueter and Contributors
-
-Permission to use, copy, modify, and/or distribute this software for any
-purpose with or without fee is hereby granted, provided that the above
-copyright notice and this permission notice appear in all copies.
-
-THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
-WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
-MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
-ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
-WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
-ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR
-IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/nopt/node_modules/abbrev/README.md
----------------------------------------------------------------------
diff --git a/node_modules/nopt/node_modules/abbrev/README.md b/node_modules/nopt/node_modules/abbrev/README.md
deleted file mode 100644
index 99746fe..0000000
--- a/node_modules/nopt/node_modules/abbrev/README.md
+++ /dev/null
@@ -1,23 +0,0 @@
-# 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.
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/nopt/node_modules/abbrev/abbrev.js
----------------------------------------------------------------------
diff --git a/node_modules/nopt/node_modules/abbrev/abbrev.js b/node_modules/nopt/node_modules/abbrev/abbrev.js
deleted file mode 100644
index 69cfeac..0000000
--- a/node_modules/nopt/node_modules/abbrev/abbrev.js
+++ /dev/null
@@ -1,62 +0,0 @@
-
-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
-}
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/nopt/node_modules/abbrev/package.json
----------------------------------------------------------------------
diff --git a/node_modules/nopt/node_modules/abbrev/package.json b/node_modules/nopt/node_modules/abbrev/package.json
deleted file mode 100644
index c13eef4..0000000
--- a/node_modules/nopt/node_modules/abbrev/package.json
+++ /dev/null
@@ -1,48 +0,0 @@
-{
- "name": "abbrev",
- "version": "1.0.7",
- "description": "Like ruby's abbrev module, but in js",
- "author": {
- "name": "Isaac Z. Schlueter",
- "email": "i@izs.me"
- },
- "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"
- },
- "dist": {
- "shasum": "5b6035b2ee9d4fb5cf859f08a9be81b208491843",
- "tarball": "http://registry.npmjs.org/abbrev/-/abbrev-1.0.7.tgz"
- },
- "maintainers": [
- {
- "name": "isaacs",
- "email": "i@izs.me"
- }
- ],
- "directories": {},
- "_resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.0.7.tgz",
- "readme": "ERROR: No README data found!"
-}
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/nopt/node_modules/abbrev/test.js
----------------------------------------------------------------------
diff --git a/node_modules/nopt/node_modules/abbrev/test.js b/node_modules/nopt/node_modules/abbrev/test.js
deleted file mode 100644
index eb30e42..0000000
--- a/node_modules/nopt/node_modules/abbrev/test.js
+++ /dev/null
@@ -1,47 +0,0 @@
-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("1..%d", count)
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/nopt/package.json
----------------------------------------------------------------------
diff --git a/node_modules/nopt/package.json b/node_modules/nopt/package.json
index 0b7b64e..8e5a28e 100644
--- a/node_modules/nopt/package.json
+++ b/node_modules/nopt/package.json
@@ -1,59 +1,88 @@
{
- "name": "nopt",
- "version": "3.0.4",
- "description": "Option parsing for Node, supporting types, shorthands, etc. Used by npm.",
+ "_args": [
+ [
+ "nopt@^3.0.4",
+ "D:\\Cordova\\cordova-windows"
+ ]
+ ],
+ "_from": "nopt@>=3.0.4 <4.0.0",
+ "_id": "nopt@3.0.6",
+ "_inCache": true,
+ "_installable": true,
+ "_location": "/nopt",
+ "_nodeVersion": "4.2.1",
+ "_npmUser": {
+ "email": "ogd@aoaioxxysz.net",
+ "name": "othiym23"
+ },
+ "_npmVersion": "2.14.10",
+ "_phantomChildren": {},
+ "_requested": {
+ "name": "nopt",
+ "raw": "nopt@^3.0.4",
+ "rawSpec": "^3.0.4",
+ "scope": null,
+ "spec": ">=3.0.4 <4.0.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/"
+ ],
+ "_resolved": "https://registry.npmjs.org/nopt/-/nopt-3.0.6.tgz",
+ "_shasum": "c6465dbf08abcd4db359317f79ac68a646b28ff9",
+ "_shrinkwrap": null,
+ "_spec": "nopt@^3.0.4",
+ "_where": "D:\\Cordova\\cordova-windows",
"author": {
- "name": "Isaac Z. Schlueter",
"email": "i@izs.me",
+ "name": "Isaac Z. Schlueter",
"url": "http://blog.izs.me/"
},
- "main": "lib/nopt.js",
- "scripts": {
- "test": "tap test/*.js"
- },
- "repository": {
- "type": "git",
- "url": "git+ssh://git@github.com/isaacs/nopt.git"
- },
"bin": {
"nopt": "./bin/nopt.js"
},
- "license": "ISC",
+ "bugs": {
+ "url": "https://github.com/npm/nopt/issues"
+ },
"dependencies": {
"abbrev": "1"
},
+ "description": "Option parsing for Node, supporting types, shorthands, etc. Used by npm.",
"devDependencies": {
"tap": "^1.2.0"
},
- "gitHead": "f52626631ea1afef5a6dd9acf23ddd1466831a08",
- "bugs": {
- "url": "https://github.com/isaacs/nopt/issues"
- },
- "homepage": "https://github.com/isaacs/nopt#readme",
- "_id": "nopt@3.0.4",
- "_shasum": "dd63bc9c72a6e4e85b85cdc0ca314598facede5e",
- "_from": "nopt@>=3.0.4 <4.0.0",
- "_npmVersion": "2.14.3",
- "_nodeVersion": "2.2.2",
- "_npmUser": {
- "name": "zkat",
- "email": "kat@sykosomatic.org"
- },
+ "directories": {},
"dist": {
- "shasum": "dd63bc9c72a6e4e85b85cdc0ca314598facede5e",
- "tarball": "http://registry.npmjs.org/nopt/-/nopt-3.0.4.tgz"
+ "shasum": "c6465dbf08abcd4db359317f79ac68a646b28ff9",
+ "tarball": "https://registry.npmjs.org/nopt/-/nopt-3.0.6.tgz"
},
+ "gitHead": "10a750c9bb99c1950160353459e733ac2aa18cb6",
+ "homepage": "https://github.com/npm/nopt#readme",
+ "license": "ISC",
+ "main": "lib/nopt.js",
"maintainers": [
{
- "name": "isaacs",
- "email": "isaacs@npmjs.com"
+ "email": "i@izs.me",
+ "name": "isaacs"
},
{
- "name": "zkat",
- "email": "kat@sykosomatic.org"
+ "email": "ogd@aoaioxxysz.net",
+ "name": "othiym23"
+ },
+ {
+ "email": "kat@sykosomatic.org",
+ "name": "zkat"
}
],
- "directories": {},
- "_resolved": "https://registry.npmjs.org/nopt/-/nopt-3.0.4.tgz",
- "readme": "ERROR: No README data found!"
+ "name": "nopt",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/npm/nopt.git"
+ },
+ "scripts": {
+ "test": "tap test/*.js"
+ },
+ "version": "3.0.6"
}
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/nopt/test/basic.js
----------------------------------------------------------------------
diff --git a/node_modules/nopt/test/basic.js b/node_modules/nopt/test/basic.js
new file mode 100644
index 0000000..d399de9
--- /dev/null
+++ b/node_modules/nopt/test/basic.js
@@ -0,0 +1,273 @@
+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()
+})
+
+// https://github.com/npm/nopt/issues/24
+test("Unknown options are not parsed as numbers", function (t) {
+ var parsed = nopt({"parse-me": Number}, null, ['--leave-as-is=1.20', '--parse-me=1.20'], 0)
+ t.equal(parsed['leave-as-is'], '1.20')
+ t.equal(parsed['parse-me'], 1.2)
+ t.end()
+});
+
+// https://github.com/npm/nopt/issues/48
+test("Check types based on name of type", function (t) {
+ var parsed = nopt({"parse-me": {name: "Number"}}, null, ['--parse-me=1.20'], 0)
+ t.equal(parsed['parse-me'], 1.2)
+ t.end()
+})
+
+
+test("Missing types are not parsed", function (t) {
+ var parsed = nopt({"parse-me": {}}, null, ['--parse-me=1.20'], 0)
+ //should only contain argv
+ t.equal(Object.keys(parsed).length, 1)
+ t.end()
+})
+
+test("Types passed without a name are not parsed", function (t) {
+ var parsed = nopt({"parse-me": {}}, {}, ['--parse-me=1.20'], 0)
+ //should only contain argv
+ t.equal(Object.keys(parsed).length, 1)
+ 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()
+})
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/once/LICENSE
----------------------------------------------------------------------
diff --git a/node_modules/once/LICENSE b/node_modules/once/LICENSE
new file mode 100644
index 0000000..19129e3
--- /dev/null
+++ b/node_modules/once/LICENSE
@@ -0,0 +1,15 @@
+The ISC License
+
+Copyright (c) Isaac Z. Schlueter and Contributors
+
+Permission to use, copy, modify, and/or distribute this software for any
+purpose with or without fee is hereby granted, provided that the above
+copyright notice and this permission notice appear in all copies.
+
+THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
+WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
+ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
+WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
+ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR
+IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/once/README.md
----------------------------------------------------------------------
diff --git a/node_modules/once/README.md b/node_modules/once/README.md
new file mode 100644
index 0000000..a2981ea
--- /dev/null
+++ b/node_modules/once/README.md
@@ -0,0 +1,51 @@
+# once
+
+Only call a function once.
+
+## usage
+
+```javascript
+var once = require('once')
+
+function load (file, cb) {
+ cb = once(cb)
+ loader.load('file')
+ loader.once('load', cb)
+ loader.once('error', cb)
+}
+```
+
+Or add to the Function.prototype in a responsible way:
+
+```javascript
+// only has to be done once
+require('once').proto()
+
+function load (file, cb) {
+ cb = cb.once()
+ loader.load('file')
+ loader.once('load', cb)
+ loader.once('error', cb)
+}
+```
+
+Ironically, the prototype feature makes this module twice as
+complicated as necessary.
+
+To check whether you function has been called, use `fn.called`. Once the
+function is called for the first time the return value of the original
+function is saved in `fn.value` and subsequent calls will continue to
+return this value.
+
+```javascript
+var once = require('once')
+
+function load (cb) {
+ cb = once(cb)
+ var stream = createStream()
+ stream.once('data', cb)
+ stream.once('end', function () {
+ if (!cb.called) cb(new Error('not found'))
+ })
+}
+```
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/once/once.js
----------------------------------------------------------------------
diff --git a/node_modules/once/once.js b/node_modules/once/once.js
new file mode 100644
index 0000000..2e1e721
--- /dev/null
+++ b/node_modules/once/once.js
@@ -0,0 +1,21 @@
+var wrappy = require('wrappy')
+module.exports = wrappy(once)
+
+once.proto = once(function () {
+ Object.defineProperty(Function.prototype, 'once', {
+ value: function () {
+ return once(this)
+ },
+ configurable: true
+ })
+})
+
+function once (fn) {
+ var f = function () {
+ if (f.called) return f.value
+ f.called = true
+ return f.value = fn.apply(this, arguments)
+ }
+ f.called = false
+ return f
+}
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/once/package.json
----------------------------------------------------------------------
diff --git a/node_modules/once/package.json b/node_modules/once/package.json
new file mode 100644
index 0000000..4e71eb6
--- /dev/null
+++ b/node_modules/once/package.json
@@ -0,0 +1,89 @@
+{
+ "_args": [
+ [
+ "once@^1.3.0",
+ "D:\\Cordova\\cordova-windows\\node_modules\\glob"
+ ]
+ ],
+ "_from": "once@>=1.3.0 <2.0.0",
+ "_id": "once@1.3.3",
+ "_inCache": true,
+ "_installable": true,
+ "_location": "/once",
+ "_nodeVersion": "4.0.0",
+ "_npmUser": {
+ "email": "i@izs.me",
+ "name": "isaacs"
+ },
+ "_npmVersion": "3.3.2",
+ "_phantomChildren": {},
+ "_requested": {
+ "name": "once",
+ "raw": "once@^1.3.0",
+ "rawSpec": "^1.3.0",
+ "scope": null,
+ "spec": ">=1.3.0 <2.0.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/glob",
+ "/inflight"
+ ],
+ "_resolved": "https://registry.npmjs.org/once/-/once-1.3.3.tgz",
+ "_shasum": "b2e261557ce4c314ec8304f3fa82663e4297ca20",
+ "_shrinkwrap": null,
+ "_spec": "once@^1.3.0",
+ "_where": "D:\\Cordova\\cordova-windows\\node_modules\\glob",
+ "author": {
+ "email": "i@izs.me",
+ "name": "Isaac Z. Schlueter",
+ "url": "http://blog.izs.me/"
+ },
+ "bugs": {
+ "url": "https://github.com/isaacs/once/issues"
+ },
+ "dependencies": {
+ "wrappy": "1"
+ },
+ "description": "Run a function exactly one time",
+ "devDependencies": {
+ "tap": "^1.2.0"
+ },
+ "directories": {
+ "test": "test"
+ },
+ "dist": {
+ "shasum": "b2e261557ce4c314ec8304f3fa82663e4297ca20",
+ "tarball": "https://registry.npmjs.org/once/-/once-1.3.3.tgz"
+ },
+ "files": [
+ "once.js"
+ ],
+ "gitHead": "2ad558657e17fafd24803217ba854762842e4178",
+ "homepage": "https://github.com/isaacs/once#readme",
+ "keywords": [
+ "once",
+ "function",
+ "one",
+ "single"
+ ],
+ "license": "ISC",
+ "main": "once.js",
+ "maintainers": [
+ {
+ "email": "i@izs.me",
+ "name": "isaacs"
+ }
+ ],
+ "name": "once",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git://github.com/isaacs/once.git"
+ },
+ "scripts": {
+ "test": "tap test/*.js"
+ },
+ "version": "1.3.3"
+}
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/os-homedir/index.js
----------------------------------------------------------------------
diff --git a/node_modules/os-homedir/index.js b/node_modules/os-homedir/index.js
new file mode 100644
index 0000000..3306616
--- /dev/null
+++ b/node_modules/os-homedir/index.js
@@ -0,0 +1,24 @@
+'use strict';
+var os = require('os');
+
+function homedir() {
+ var env = process.env;
+ var home = env.HOME;
+ var user = env.LOGNAME || env.USER || env.LNAME || env.USERNAME;
+
+ if (process.platform === 'win32') {
+ return env.USERPROFILE || env.HOMEDRIVE + env.HOMEPATH || home || null;
+ }
+
+ if (process.platform === 'darwin') {
+ return home || (user ? '/Users/' + user : null);
+ }
+
+ if (process.platform === 'linux') {
+ return home || (process.getuid() === 0 ? '/root' : (user ? '/home/' + user : null));
+ }
+
+ return home || null;
+}
+
+module.exports = typeof os.homedir === 'function' ? os.homedir : homedir;
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/os-homedir/license
----------------------------------------------------------------------
diff --git a/node_modules/os-homedir/license b/node_modules/os-homedir/license
new file mode 100644
index 0000000..654d0bf
--- /dev/null
+++ b/node_modules/os-homedir/license
@@ -0,0 +1,21 @@
+The MIT License (MIT)
+
+Copyright (c) Sindre Sorhus <si...@gmail.com> (sindresorhus.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.
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/os-homedir/package.json
----------------------------------------------------------------------
diff --git a/node_modules/os-homedir/package.json b/node_modules/os-homedir/package.json
new file mode 100644
index 0000000..937bc6f
--- /dev/null
+++ b/node_modules/os-homedir/package.json
@@ -0,0 +1,96 @@
+{
+ "_args": [
+ [
+ "os-homedir@^1.0.0",
+ "D:\\Cordova\\cordova-windows\\node_modules\\osenv"
+ ]
+ ],
+ "_from": "os-homedir@>=1.0.0 <2.0.0",
+ "_id": "os-homedir@1.0.1",
+ "_inCache": true,
+ "_installable": true,
+ "_location": "/os-homedir",
+ "_nodeVersion": "0.12.5",
+ "_npmUser": {
+ "email": "sindresorhus@gmail.com",
+ "name": "sindresorhus"
+ },
+ "_npmVersion": "2.11.2",
+ "_phantomChildren": {},
+ "_requested": {
+ "name": "os-homedir",
+ "raw": "os-homedir@^1.0.0",
+ "rawSpec": "^1.0.0",
+ "scope": null,
+ "spec": ">=1.0.0 <2.0.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/osenv"
+ ],
+ "_resolved": "https://registry.npmjs.org/os-homedir/-/os-homedir-1.0.1.tgz",
+ "_shasum": "0d62bdf44b916fd3bbdcf2cab191948fb094f007",
+ "_shrinkwrap": null,
+ "_spec": "os-homedir@^1.0.0",
+ "_where": "D:\\Cordova\\cordova-windows\\node_modules\\osenv",
+ "author": {
+ "email": "sindresorhus@gmail.com",
+ "name": "Sindre Sorhus",
+ "url": "sindresorhus.com"
+ },
+ "bugs": {
+ "url": "https://github.com/sindresorhus/os-homedir/issues"
+ },
+ "dependencies": {},
+ "description": "io.js 2.3.0 os.homedir() ponyfill",
+ "devDependencies": {
+ "ava": "0.0.4",
+ "path-exists": "^1.0.0"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "0d62bdf44b916fd3bbdcf2cab191948fb094f007",
+ "tarball": "https://registry.npmjs.org/os-homedir/-/os-homedir-1.0.1.tgz"
+ },
+ "engines": {
+ "node": ">=0.10.0"
+ },
+ "files": [
+ "index.js"
+ ],
+ "gitHead": "13ff83fbd13ebe286a6092286b2c634ab4534c5f",
+ "homepage": "https://github.com/sindresorhus/os-homedir",
+ "keywords": [
+ "built-in",
+ "core",
+ "ponyfill",
+ "polyfill",
+ "shim",
+ "os",
+ "homedir",
+ "home",
+ "dir",
+ "directory",
+ "folder",
+ "user",
+ "path"
+ ],
+ "license": "MIT",
+ "maintainers": [
+ {
+ "email": "sindresorhus@gmail.com",
+ "name": "sindresorhus"
+ }
+ ],
+ "name": "os-homedir",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/sindresorhus/os-homedir.git"
+ },
+ "scripts": {
+ "test": "node test.js"
+ },
+ "version": "1.0.1"
+}
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/os-homedir/readme.md
----------------------------------------------------------------------
diff --git a/node_modules/os-homedir/readme.md b/node_modules/os-homedir/readme.md
new file mode 100644
index 0000000..4851f10
--- /dev/null
+++ b/node_modules/os-homedir/readme.md
@@ -0,0 +1,33 @@
+# os-homedir [![Build Status](https://travis-ci.org/sindresorhus/os-homedir.svg?branch=master)](https://travis-ci.org/sindresorhus/os-homedir)
+
+> io.js 2.3.0 [`os.homedir()`](https://iojs.org/api/os.html#os_os_homedir) ponyfill
+
+> Ponyfill: A polyfill that doesn't overwrite the native method
+
+
+## Install
+
+```
+$ npm install --save os-homedir
+```
+
+
+## Usage
+
+```js
+var osHomedir = require('os-homedir');
+
+console.log(osHomedir());
+//=> /Users/sindresorhus
+```
+
+
+## Related
+
+- [user-home](https://github.com/sindresorhus/user-home) - Same as this module but caches the result
+- [home-or-tmp](https://github.com/sindresorhus/home-or-tmp) - Get the user home directory with fallback to the system temp directory
+
+
+## License
+
+MIT � [Sindre Sorhus](http://sindresorhus.com)
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/os-tmpdir/index.js
----------------------------------------------------------------------
diff --git a/node_modules/os-tmpdir/index.js b/node_modules/os-tmpdir/index.js
new file mode 100644
index 0000000..52d90bf
--- /dev/null
+++ b/node_modules/os-tmpdir/index.js
@@ -0,0 +1,25 @@
+'use strict';
+var isWindows = process.platform === 'win32';
+var trailingSlashRe = isWindows ? /[^:]\\$/ : /.\/$/;
+
+// https://github.com/nodejs/io.js/blob/3e7a14381497a3b73dda68d05b5130563cdab420/lib/os.js#L25-L43
+module.exports = function () {
+ var path;
+
+ if (isWindows) {
+ path = process.env.TEMP ||
+ process.env.TMP ||
+ (process.env.SystemRoot || process.env.windir) + '\\temp';
+ } else {
+ path = process.env.TMPDIR ||
+ process.env.TMP ||
+ process.env.TEMP ||
+ '/tmp';
+ }
+
+ if (trailingSlashRe.test(path)) {
+ path = path.slice(0, -1);
+ }
+
+ return path;
+};
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/os-tmpdir/license
----------------------------------------------------------------------
diff --git a/node_modules/os-tmpdir/license b/node_modules/os-tmpdir/license
new file mode 100644
index 0000000..654d0bf
--- /dev/null
+++ b/node_modules/os-tmpdir/license
@@ -0,0 +1,21 @@
+The MIT License (MIT)
+
+Copyright (c) Sindre Sorhus <si...@gmail.com> (sindresorhus.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.
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/os-tmpdir/package.json
----------------------------------------------------------------------
diff --git a/node_modules/os-tmpdir/package.json b/node_modules/os-tmpdir/package.json
new file mode 100644
index 0000000..bef95ad
--- /dev/null
+++ b/node_modules/os-tmpdir/package.json
@@ -0,0 +1,96 @@
+{
+ "_args": [
+ [
+ "os-tmpdir@^1.0.0",
+ "D:\\Cordova\\cordova-windows\\node_modules\\osenv"
+ ]
+ ],
+ "_from": "os-tmpdir@>=1.0.0 <2.0.0",
+ "_id": "os-tmpdir@1.0.1",
+ "_inCache": true,
+ "_installable": true,
+ "_location": "/os-tmpdir",
+ "_nodeVersion": "0.12.3",
+ "_npmUser": {
+ "email": "sindresorhus@gmail.com",
+ "name": "sindresorhus"
+ },
+ "_npmVersion": "2.9.1",
+ "_phantomChildren": {},
+ "_requested": {
+ "name": "os-tmpdir",
+ "raw": "os-tmpdir@^1.0.0",
+ "rawSpec": "^1.0.0",
+ "scope": null,
+ "spec": ">=1.0.0 <2.0.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/osenv"
+ ],
+ "_resolved": "https://registry.npmjs.org/os-tmpdir/-/os-tmpdir-1.0.1.tgz",
+ "_shasum": "e9b423a1edaf479882562e92ed71d7743a071b6e",
+ "_shrinkwrap": null,
+ "_spec": "os-tmpdir@^1.0.0",
+ "_where": "D:\\Cordova\\cordova-windows\\node_modules\\osenv",
+ "author": {
+ "email": "sindresorhus@gmail.com",
+ "name": "Sindre Sorhus",
+ "url": "sindresorhus.com"
+ },
+ "bugs": {
+ "url": "https://github.com/sindresorhus/os-tmpdir/issues"
+ },
+ "dependencies": {},
+ "description": "Node.js os.tmpdir() ponyfill",
+ "devDependencies": {
+ "ava": "0.0.4"
+ },
+ "directories": {},
+ "dist": {
+ "shasum": "e9b423a1edaf479882562e92ed71d7743a071b6e",
+ "tarball": "https://registry.npmjs.org/os-tmpdir/-/os-tmpdir-1.0.1.tgz"
+ },
+ "engines": {
+ "node": ">=0.10.0"
+ },
+ "files": [
+ "index.js"
+ ],
+ "gitHead": "5c5d355f81378980db629d60128ad03e02b1c1e5",
+ "homepage": "https://github.com/sindresorhus/os-tmpdir",
+ "keywords": [
+ "built-in",
+ "core",
+ "ponyfill",
+ "polyfill",
+ "shim",
+ "os",
+ "tmpdir",
+ "tempdir",
+ "tmp",
+ "temp",
+ "dir",
+ "directory",
+ "env",
+ "environment"
+ ],
+ "license": "MIT",
+ "maintainers": [
+ {
+ "email": "sindresorhus@gmail.com",
+ "name": "sindresorhus"
+ }
+ ],
+ "name": "os-tmpdir",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/sindresorhus/os-tmpdir.git"
+ },
+ "scripts": {
+ "test": "node test.js"
+ },
+ "version": "1.0.1"
+}
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/os-tmpdir/readme.md
----------------------------------------------------------------------
diff --git a/node_modules/os-tmpdir/readme.md b/node_modules/os-tmpdir/readme.md
new file mode 100644
index 0000000..54d4c6e
--- /dev/null
+++ b/node_modules/os-tmpdir/readme.md
@@ -0,0 +1,36 @@
+# os-tmpdir [![Build Status](https://travis-ci.org/sindresorhus/os-tmpdir.svg?branch=master)](https://travis-ci.org/sindresorhus/os-tmpdir)
+
+> Node.js [`os.tmpdir()`](https://nodejs.org/api/os.html#os_os_tmpdir) ponyfill
+
+> Ponyfill: A polyfill that doesn't overwrite the native method
+
+Use this instead of `require('os').tmpdir()` to get a consistent behaviour on different Node.js versions (even 0.8).
+
+*This is actually taken from io.js 2.0.2 as it contains some fixes that haven't bubbled up to Node.js yet.*
+
+
+## Install
+
+```
+$ npm install --save os-tmpdir
+```
+
+
+## Usage
+
+```js
+var osTmpdir = require('os-tmpdir');
+
+osTmpdir();
+//=> /var/folders/m3/5574nnhn0yj488ccryqr7tc80000gn/T
+```
+
+
+## API
+
+See the [`os.tmpdir()` docs](https://nodejs.org/api/os.html#os_os_tmpdir).
+
+
+## License
+
+MIT � [Sindre Sorhus](http://sindresorhus.com)
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/osenv/.npmignore
----------------------------------------------------------------------
diff --git a/node_modules/osenv/.npmignore b/node_modules/osenv/.npmignore
new file mode 100644
index 0000000..8c23dee
--- /dev/null
+++ b/node_modules/osenv/.npmignore
@@ -0,0 +1,13 @@
+*.swp
+.*.swp
+
+.DS_Store
+*~
+.project
+.settings
+npm-debug.log
+coverage.html
+.idea
+lib-cov
+
+node_modules
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/osenv/.travis.yml
----------------------------------------------------------------------
diff --git a/node_modules/osenv/.travis.yml b/node_modules/osenv/.travis.yml
new file mode 100644
index 0000000..99f2bbf
--- /dev/null
+++ b/node_modules/osenv/.travis.yml
@@ -0,0 +1,9 @@
+language: node_js
+language: node_js
+node_js:
+ - '0.8'
+ - '0.10'
+ - '0.12'
+ - 'iojs'
+before_install:
+ - npm install -g npm@latest
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/osenv/LICENSE
----------------------------------------------------------------------
diff --git a/node_modules/osenv/LICENSE b/node_modules/osenv/LICENSE
new file mode 100644
index 0000000..19129e3
--- /dev/null
+++ b/node_modules/osenv/LICENSE
@@ -0,0 +1,15 @@
+The ISC License
+
+Copyright (c) Isaac Z. Schlueter and Contributors
+
+Permission to use, copy, modify, and/or distribute this software for any
+purpose with or without fee is hereby granted, provided that the above
+copyright notice and this permission notice appear in all copies.
+
+THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
+WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
+ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
+WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
+ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR
+IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/osenv/README.md
----------------------------------------------------------------------
diff --git a/node_modules/osenv/README.md b/node_modules/osenv/README.md
new file mode 100644
index 0000000..08fd900
--- /dev/null
+++ b/node_modules/osenv/README.md
@@ -0,0 +1,63 @@
+# osenv
+
+Look up environment settings specific to different operating systems.
+
+## Usage
+
+```javascript
+var osenv = require('osenv')
+var path = osenv.path()
+var user = osenv.user()
+// etc.
+
+// Some things are not reliably in the env, and have a fallback command:
+var h = osenv.hostname(function (er, hostname) {
+ h = hostname
+})
+// This will still cause it to be memoized, so calling osenv.hostname()
+// is now an immediate operation.
+
+// You can always send a cb, which will get called in the nextTick
+// if it's been memoized, or wait for the fallback data if it wasn't
+// found in the environment.
+osenv.hostname(function (er, hostname) {
+ if (er) console.error('error looking up hostname')
+ else console.log('this machine calls itself %s', hostname)
+})
+```
+
+## osenv.hostname()
+
+The machine name. Calls `hostname` if not found.
+
+## osenv.user()
+
+The currently logged-in user. Calls `whoami` if not found.
+
+## osenv.prompt()
+
+Either PS1 on unix, or PROMPT on Windows.
+
+## osenv.tmpdir()
+
+The place where temporary files should be created.
+
+## osenv.home()
+
+No place like it.
+
+## osenv.path()
+
+An array of the places that the operating system will search for
+executables.
+
+## osenv.editor()
+
+Return the executable name of the editor program. This uses the EDITOR
+and VISUAL environment variables, and falls back to `vi` on Unix, or
+`notepad.exe` on Windows.
+
+## osenv.shell()
+
+The SHELL on Unix, which Windows calls the ComSpec. Defaults to 'bash'
+or 'cmd'.
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/osenv/osenv.js
----------------------------------------------------------------------
diff --git a/node_modules/osenv/osenv.js b/node_modules/osenv/osenv.js
new file mode 100644
index 0000000..702a95b
--- /dev/null
+++ b/node_modules/osenv/osenv.js
@@ -0,0 +1,72 @@
+var isWindows = process.platform === 'win32'
+var path = require('path')
+var exec = require('child_process').exec
+var osTmpdir = require('os-tmpdir')
+var osHomedir = require('os-homedir')
+
+// looking up envs is a bit costly.
+// Also, sometimes we want to have a fallback
+// Pass in a callback to wait for the fallback on failures
+// After the first lookup, always returns the same thing.
+function memo (key, lookup, fallback) {
+ var fell = false
+ var falling = false
+ exports[key] = function (cb) {
+ var val = lookup()
+ if (!val && !fell && !falling && fallback) {
+ fell = true
+ falling = true
+ exec(fallback, function (er, output, stderr) {
+ falling = false
+ if (er) return // oh well, we tried
+ val = output.trim()
+ })
+ }
+ exports[key] = function (cb) {
+ if (cb) process.nextTick(cb.bind(null, null, val))
+ return val
+ }
+ if (cb && !falling) process.nextTick(cb.bind(null, null, val))
+ return val
+ }
+}
+
+memo('user', function () {
+ return ( isWindows
+ ? process.env.USERDOMAIN + '\\' + process.env.USERNAME
+ : process.env.USER
+ )
+}, 'whoami')
+
+memo('prompt', function () {
+ return isWindows ? process.env.PROMPT : process.env.PS1
+})
+
+memo('hostname', function () {
+ return isWindows ? process.env.COMPUTERNAME : process.env.HOSTNAME
+}, 'hostname')
+
+memo('tmpdir', function () {
+ return osTmpdir()
+})
+
+memo('home', function () {
+ return osHomedir()
+})
+
+memo('path', function () {
+ return (process.env.PATH ||
+ process.env.Path ||
+ process.env.path).split(isWindows ? ';' : ':')
+})
+
+memo('editor', function () {
+ return process.env.EDITOR ||
+ process.env.VISUAL ||
+ (isWindows ? 'notepad.exe' : 'vi')
+})
+
+memo('shell', function () {
+ return isWindows ? process.env.ComSpec || 'cmd'
+ : process.env.SHELL || 'bash'
+})
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/osenv/package.json
----------------------------------------------------------------------
diff --git a/node_modules/osenv/package.json b/node_modules/osenv/package.json
new file mode 100644
index 0000000..de0c631
--- /dev/null
+++ b/node_modules/osenv/package.json
@@ -0,0 +1,101 @@
+{
+ "_args": [
+ [
+ "osenv@^0.1.3",
+ "D:\\Cordova\\cordova-windows\\node_modules\\cordova-common"
+ ]
+ ],
+ "_from": "osenv@>=0.1.3 <0.2.0",
+ "_id": "osenv@0.1.3",
+ "_inCache": true,
+ "_installable": true,
+ "_location": "/osenv",
+ "_nodeVersion": "2.2.1",
+ "_npmUser": {
+ "email": "isaacs@npmjs.com",
+ "name": "isaacs"
+ },
+ "_npmVersion": "3.0.0",
+ "_phantomChildren": {},
+ "_requested": {
+ "name": "osenv",
+ "raw": "osenv@^0.1.3",
+ "rawSpec": "^0.1.3",
+ "scope": null,
+ "spec": ">=0.1.3 <0.2.0",
+ "type": "range"
+ },
+ "_requiredBy": [
+ "/cordova-common"
+ ],
+ "_resolved": "https://registry.npmjs.org/osenv/-/osenv-0.1.3.tgz",
+ "_shasum": "83cf05c6d6458fc4d5ac6362ea325d92f2754217",
+ "_shrinkwrap": null,
+ "_spec": "osenv@^0.1.3",
+ "_where": "D:\\Cordova\\cordova-windows\\node_modules\\cordova-common",
+ "author": {
+ "email": "i@izs.me",
+ "name": "Isaac Z. Schlueter",
+ "url": "http://blog.izs.me/"
+ },
+ "bugs": {
+ "url": "https://github.com/npm/osenv/issues"
+ },
+ "dependencies": {
+ "os-homedir": "^1.0.0",
+ "os-tmpdir": "^1.0.0"
+ },
+ "description": "Look up environment settings specific to different operating systems",
+ "devDependencies": {
+ "tap": "^1.2.0"
+ },
+ "directories": {
+ "test": "test"
+ },
+ "dist": {
+ "shasum": "83cf05c6d6458fc4d5ac6362ea325d92f2754217",
+ "tarball": "https://registry.npmjs.org/osenv/-/osenv-0.1.3.tgz"
+ },
+ "gitHead": "f746b3405d8f9e28054d11b97e1436f6a15016c4",
+ "homepage": "https://github.com/npm/osenv#readme",
+ "keywords": [
+ "environment",
+ "variable",
+ "home",
+ "tmpdir",
+ "path",
+ "prompt",
+ "ps1"
+ ],
+ "license": "ISC",
+ "main": "osenv.js",
+ "maintainers": [
+ {
+ "email": "i@izs.me",
+ "name": "isaacs"
+ },
+ {
+ "email": "rok@kowalski.gd",
+ "name": "robertkowalski"
+ },
+ {
+ "email": "ogd@aoaioxxysz.net",
+ "name": "othiym23"
+ },
+ {
+ "email": "me@re-becca.org",
+ "name": "iarna"
+ }
+ ],
+ "name": "osenv",
+ "optionalDependencies": {},
+ "readme": "ERROR: No README data found!",
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/npm/osenv.git"
+ },
+ "scripts": {
+ "test": "tap test/*.js"
+ },
+ "version": "0.1.3"
+}
http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/5a6cb728/node_modules/osenv/test/unix.js
----------------------------------------------------------------------
diff --git a/node_modules/osenv/test/unix.js b/node_modules/osenv/test/unix.js
new file mode 100644
index 0000000..f87cbfb
--- /dev/null
+++ b/node_modules/osenv/test/unix.js
@@ -0,0 +1,71 @@
+// only run this test on windows
+// pretending to be another platform is too hacky, since it breaks
+// how the underlying system looks up module paths and runs
+// child processes, and all that stuff is cached.
+if (process.platform === 'win32') {
+ console.log('TAP Version 13\n' +
+ '1..0\n' +
+ '# Skip unix tests, this is not unix\n')
+ return
+}
+var tap = require('tap')
+
+// like unix, but funny
+process.env.USER = 'sirUser'
+process.env.HOME = '/home/sirUser'
+process.env.HOSTNAME = 'my-machine'
+process.env.TMPDIR = '/tmpdir'
+process.env.TMP = '/tmp'
+process.env.TEMP = '/temp'
+process.env.PATH = '/opt/local/bin:/usr/local/bin:/usr/bin/:bin'
+process.env.PS1 = '(o_o) $ '
+process.env.EDITOR = 'edit'
+process.env.VISUAL = 'visualedit'
+process.env.SHELL = 'zsh'
+
+tap.test('basic unix sanity test', function (t) {
+ var osenv = require('../osenv.js')
+
+ t.equal(osenv.user(), process.env.USER)
+ t.equal(osenv.home(), process.env.HOME)
+ t.equal(osenv.hostname(), process.env.HOSTNAME)
+ t.same(osenv.path(), process.env.PATH.split(':'))
+ t.equal(osenv.prompt(), process.env.PS1)
+ t.equal(osenv.tmpdir(), process.env.TMPDIR)
+
+ // mildly evil, but it's for a test.
+ process.env.TMPDIR = ''
+ delete require.cache[require.resolve('../osenv.js')]
+ var osenv = require('../osenv.js')
+ t.equal(osenv.tmpdir(), process.env.TMP)
+
+ process.env.TMP = ''
+ delete require.cache[require.resolve('../osenv.js')]
+ var osenv = require('../osenv.js')
+ t.equal(osenv.tmpdir(), process.env.TEMP)
+
+ process.env.TEMP = ''
+ delete require.cache[require.resolve('../osenv.js')]
+ var osenv = require('../osenv.js')
+ osenv.home = function () { return null }
+ t.equal(osenv.tmpdir(), '/tmp')
+
+ t.equal(osenv.editor(), 'edit')
+ process.env.EDITOR = ''
+ delete require.cache[require.resolve('../osenv.js')]
+ var osenv = require('../osenv.js')
+ t.equal(osenv.editor(), 'visualedit')
+
+ process.env.VISUAL = ''
+ delete require.cache[require.resolve('../osenv.js')]
+ var osenv = require('../osenv.js')
+ t.equal(osenv.editor(), 'vi')
+
+ t.equal(osenv.shell(), 'zsh')
+ process.env.SHELL = ''
+ delete require.cache[require.resolve('../osenv.js')]
+ var osenv = require('../osenv.js')
+ t.equal(osenv.shell(), 'bash')
+
+ t.end()
+})
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cordova.apache.org
For additional commands, e-mail: commits-help@cordova.apache.org