TagSpaces is an offline, open source, document manager with tagging support
adding the trash npm library
uggrockac34d481dc1f
diff --git a/data/node-webkit/node_modules/trash/index.js b/data/node-webkit/node_modules/trash/index.jsnew file mode 100644index 000000000..4ae56f84b--- /dev/null+++ b/data/node-webkit/node_modules/trash/index.js@@ -0,0 +1,29 @@+'use strict';+var path = require('path');+var pathExists = require('path-exists');++module.exports = function (paths) {+ if (!Array.isArray(paths)) {+ return Promise.reject(new TypeError('Expected an array'));+ }++ if (paths.length === 0) {+ return Promise.resolve();+ }++ paths = paths.map(function (x) {+ return path.resolve(String(x));+ }).filter(function (x) {+ return pathExists.sync(x);+ });++ if (process.platform === 'darwin') {+ return require('./lib/osx')(paths);+ }++ if (process.platform === 'win32') {+ return require('./lib/win')(paths);+ }++ return require('./lib/linux')(paths);+};diff --git a/data/node-webkit/node_modules/trash/lib/linux.js b/data/node-webkit/node_modules/trash/lib/linux.jsnew file mode 100644index 000000000..589f1a198--- /dev/null+++ b/data/node-webkit/node_modules/trash/lib/linux.js@@ -0,0 +1,35 @@+'use strict';+var path = require('path');+var fsExtra = require('fs-extra');+var pify = require('pify');+var Promise = require('pinkie-promise');+var uuid = require('uuid');+var xdgTrashdir = require('xdg-trashdir');+var fs = pify.all(fsExtra, Promise);++function trash(src) {+ return xdgTrashdir(src).then(function (dir) {+ var name = uuid.v4();+ var dest = path.join(dir, 'files', name);+ var info = path.join(dir, 'info', name + '.trashinfo');+ var msg = [+ '[Trash Info]',+ 'Path=' + src.replace(/\s/g, '%20'),+ 'DeletionDate=' + new Date().toISOString()+ ].join('\n');++ return Promise.all([+ fs.move(src, dest, {mkdirp: true}),+ fs.outputFile(info, msg)+ ]).then(function () {+ return {+ path: dest,+ info: info+ };+ });+ });+}++module.exports = function (paths) {+ return Promise.all(paths.map(trash));+};diff --git a/data/node-webkit/node_modules/trash/lib/osx-trash b/data/node-webkit/node_modules/trash/lib/osx-trashnew file mode 100644index 000000000..fd62c5276Binary files /dev/null and b/data/node-webkit/node_modules/trash/lib/osx-trash differdiff --git a/data/node-webkit/node_modules/trash/lib/osx.js b/data/node-webkit/node_modules/trash/lib/osx.jsnew file mode 100644index 000000000..433ccded2--- /dev/null+++ b/data/node-webkit/node_modules/trash/lib/osx.js@@ -0,0 +1,38 @@+'use strict';+var os = require('os');+var path = require('path');+var execFile = require('child_process').execFile;+var escapeStringApplescript = require('escape-string-applescript');+var runApplescript = require('run-applescript');+var pify = require('pify');+var Promise = require('pinkie-promise');+var olderThanMountainLion = Number(os.release().split('.')[0]) < 12;+var bin = path.join(__dirname, 'osx-trash');++function legacy(paths) {+ var script =+ 'set deleteList to {}\n' ++ 'repeat with currentPath in {' + paths.map(function (el) {+ return '"' + escapeStringApplescript(el) + '"';+ }).join(',') + '}\n' ++ 'set end of deleteList to POSIX file currentPath\n' ++ 'end repeat\n' ++ 'tell app "Finder" to delete deleteList';++ return runApplescript(script)+ .catch(function (err) {+ if (/10010/.test(err.message)) {+ throw new Error('Item doesn\'t exist');+ }++ throw err;+ });+}++module.exports = function (paths) {+ if (olderThanMountainLion) {+ return legacy(paths);+ }++ return pify(execFile, Promise)(bin, paths);+};diff --git a/data/node-webkit/node_modules/trash/lib/win-trash.exe b/data/node-webkit/node_modules/trash/lib/win-trash.exenew file mode 100644index 000000000..f3fa69c6eBinary files /dev/null and b/data/node-webkit/node_modules/trash/lib/win-trash.exe differdiff --git a/data/node-webkit/node_modules/trash/lib/win.js b/data/node-webkit/node_modules/trash/lib/win.jsnew file mode 100644index 000000000..d1c867604--- /dev/null+++ b/data/node-webkit/node_modules/trash/lib/win.js@@ -0,0 +1,10 @@+'use strict';+var path = require('path');+var execFile = require('child_process').execFile;+var Promise = require('pinkie-promise');+var pify = require('pify');+var bin = path.join(__dirname, 'win-trash.exe');++module.exports = function (paths) {+ return pify(execFile, Promise)(bin, paths);+};diff --git a/data/node-webkit/node_modules/trash/license b/data/node-webkit/node_modules/trash/licensenew file mode 100644index 000000000..654d0bfe9--- /dev/null+++ b/data/node-webkit/node_modules/trash/license@@ -0,0 +1,21 @@+The MIT License (MIT)++Copyright (c) Sindre Sorhus <[email protected]> (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.diff --git a/data/node-webkit/node_modules/trash/node_modules/escape-string-applescript/index.js b/data/node-webkit/node_modules/trash/node_modules/escape-string-applescript/index.jsnew file mode 100644index 000000000..e3588a52c--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/escape-string-applescript/index.js@@ -0,0 +1,4 @@+'use strict';+module.exports = function (str) {+ return typeof str === 'string' ? str.replace(/[\\"]/g, '\\$&') : str;+};diff --git a/data/node-webkit/node_modules/trash/node_modules/escape-string-applescript/package.json b/data/node-webkit/node_modules/trash/node_modules/escape-string-applescript/package.jsonnew file mode 100644index 000000000..602d7bed6--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/escape-string-applescript/package.json@@ -0,0 +1,63 @@+{+ "name": "escape-string-applescript",+ "version": "1.0.0",+ "description": "Escape a string for use in AppleScript",+ "license": "MIT",+ "repository": {+ "type": "git",+ "url": "git://github.com/sindresorhus/escape-string-applescript"+ },+ "author": {+ "name": "Sindre Sorhus",+ "email": "[email protected]",+ "url": "http://sindresorhus.com"+ },+ "engines": {+ "node": ">=0.10.0"+ },+ "scripts": {+ "test": "node test.js"+ },+ "files": [+ "index.js"+ ],+ "keywords": [+ "escape",+ "string",+ "str",+ "applescript",+ "osascript",+ "quote",+ "quotes",+ "backslash"+ ],+ "devDependencies": {+ "ava": "0.0.3"+ },+ "gitHead": "e8e7f575ecbe6cc862f9b46e07049cffaba367a1",+ "bugs": {+ "url": "https://github.com/sindresorhus/escape-string-applescript/issues"+ },+ "homepage": "https://github.com/sindresorhus/escape-string-applescript",+ "_id": "[email protected]",+ "_shasum": "6f1c2294245d82c63bc03338dc19a94aa8428892",+ "_from": "escape-string-applescript@>=1.0.0 <2.0.0",+ "_npmVersion": "1.4.14",+ "_npmUser": {+ "name": "sindresorhus",+ "email": "[email protected]"+ },+ "maintainers": [+ {+ "name": "sindresorhus",+ "email": "[email protected]"+ }+ ],+ "dist": {+ "shasum": "6f1c2294245d82c63bc03338dc19a94aa8428892",+ "tarball": "http://registry.npmjs.org/escape-string-applescript/-/escape-string-applescript-1.0.0.tgz"+ },+ "directories": {},+ "_resolved": "https://registry.npmjs.org/escape-string-applescript/-/escape-string-applescript-1.0.0.tgz",+ "readme": "ERROR: No README data found!"+}diff --git a/data/node-webkit/node_modules/trash/node_modules/escape-string-applescript/readme.md b/data/node-webkit/node_modules/trash/node_modules/escape-string-applescript/readme.mdnew file mode 100644index 000000000..3f697269f--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/escape-string-applescript/readme.md@@ -0,0 +1,32 @@+# escape-string-applescript [](https://travis-ci.org/sindresorhus/escape-string-applescript)++> Escape a string for use in AppleScript++According to the AppleScript [docs](https://developer.apple.com/library/mac/documentation/AppleScript/Conceptual/AppleScriptLangGuide/reference/ASLR_classes.html#//apple_ref/doc/uid/TP40000983-CH1g-DontLinkElementID_57) `\` and `"` have special meaning and should be escaped.+++## Install++```sh+$ npm install --save escape-string-applescript+```+++## Usage++```js+var execFile = require('child_process').execFile;+var escapeString = require('escape-string-applescript');++var str = escapeString('"i like unicorns"');+//=> \"i like unicorns\"++var script = 'set unicornMessage to "' + str + '"';++execFile('osascript', ['-e', script]);+```+++## License++MIT © [Sindre Sorhus](http://sindresorhus.com)diff --git a/data/node-webkit/node_modules/trash/node_modules/path-exists/index.js b/data/node-webkit/node_modules/trash/node_modules/path-exists/index.jsnew file mode 100644index 000000000..a7e680a76--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/path-exists/index.js@@ -0,0 +1,24 @@+'use strict';+var fs = require('fs');+var Promise = require('pinkie-promise');++module.exports = function (fp) {+ var fn = typeof fs.access === 'function' ? fs.access : fs.stat;++ return new Promise(function (resolve) {+ fn(fp, function (err) {+ resolve(!err);+ });+ });+};++module.exports.sync = function (fp) {+ var fn = typeof fs.accessSync === 'function' ? fs.accessSync : fs.statSync;++ try {+ fn(fp);+ return true;+ } catch (err) {+ return false;+ }+};diff --git a/data/node-webkit/node_modules/trash/node_modules/path-exists/license b/data/node-webkit/node_modules/trash/node_modules/path-exists/licensenew file mode 100644index 000000000..654d0bfe9--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/path-exists/license@@ -0,0 +1,21 @@+The MIT License (MIT)++Copyright (c) Sindre Sorhus <[email protected]> (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.diff --git a/data/node-webkit/node_modules/trash/node_modules/path-exists/package.json b/data/node-webkit/node_modules/trash/node_modules/path-exists/package.jsonnew file mode 100644index 000000000..94cbb5fe2--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/path-exists/package.json@@ -0,0 +1,70 @@+{+ "name": "path-exists",+ "version": "2.0.0",+ "description": "Check if a path exists",+ "license": "MIT",+ "repository": {+ "type": "git",+ "url": "https://github.com/sindresorhus/path-exists"+ },+ "author": {+ "name": "Sindre Sorhus",+ "email": "[email protected]",+ "url": "sindresorhus.com"+ },+ "engines": {+ "node": ">=0.10.0"+ },+ "scripts": {+ "test": "xo && ava"+ },+ "files": [+ "index.js"+ ],+ "keywords": [+ "path",+ "exists",+ "exist",+ "file",+ "filepath",+ "fs",+ "filesystem",+ "file-system",+ "access",+ "stat"+ ],+ "dependencies": {+ "pinkie-promise": "^1.0.0"+ },+ "devDependencies": {+ "ava": "*",+ "xo": "*"+ },+ "gitHead": "a8d30de3a24e7d71ae2c30a057525e603205447d",+ "bugs": {+ "url": "https://github.com/sindresorhus/path-exists/issues"+ },+ "homepage": "https://github.com/sindresorhus/path-exists",+ "_id": "[email protected]",+ "_shasum": "c4efe37d7fdc792f9a029ce7906e095e169f9be1",+ "_from": "path-exists@>=2.0.0 <3.0.0",+ "_npmVersion": "2.11.3",+ "_nodeVersion": "0.12.7",+ "_npmUser": {+ "name": "sindresorhus",+ "email": "[email protected]"+ },+ "dist": {+ "shasum": "c4efe37d7fdc792f9a029ce7906e095e169f9be1",+ "tarball": "http://registry.npmjs.org/path-exists/-/path-exists-2.0.0.tgz"+ },+ "maintainers": [+ {+ "name": "sindresorhus",+ "email": "[email protected]"+ }+ ],+ "directories": {},+ "_resolved": "https://registry.npmjs.org/path-exists/-/path-exists-2.0.0.tgz",+ "readme": "ERROR: No README data found!"+}diff --git a/data/node-webkit/node_modules/trash/node_modules/path-exists/readme.md b/data/node-webkit/node_modules/trash/node_modules/path-exists/readme.mdnew file mode 100644index 000000000..8fbcd68df--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/path-exists/readme.md@@ -0,0 +1,45 @@+# path-exists [](https://travis-ci.org/sindresorhus/path-exists)++> Check if a path exists++Because [`fs.exists()`](https://nodejs.org/api/fs.html#fs_fs_exists_path_callback) is being [deprecated](https://github.com/iojs/io.js/issues/103), but there's still a genuine use-case of being able to check if a path exists for other purposes than doing IO with it.++Never use this before handling a file though:++> In particular, checking if a file exists before opening it is an anti-pattern that leaves you vulnerable to race conditions: another process may remove the file between the calls to `fs.exists()` and `fs.open()`. Just open the file and handle the error when it's not there.+++## Install++```+$ npm install --save path-exists+```+++## Usage++```js+// foo.js+var pathExists = require('path-exists');++pathExists('foo.js').then(function (exists) {+ console.log(exists);+ //=> true+});+```+++## API++### pathExists(path)++Returns a promise that resolves to a boolean of whether the path exists.++### pathExists.sync(path)++Returns a boolean of whether the path exists.+++## License++MIT © [Sindre Sorhus](http://sindresorhus.com)diff --git a/data/node-webkit/node_modules/trash/node_modules/pify/index.js b/data/node-webkit/node_modules/trash/node_modules/pify/index.jsnew file mode 100644index 000000000..7c720ebee--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/pify/index.js@@ -0,0 +1,68 @@+'use strict';++var processFn = function (fn, P, opts) {+ return function () {+ var that = this;+ var args = new Array(arguments.length);++ for (var i = 0; i < arguments.length; i++) {+ args[i] = arguments[i];+ }++ return new P(function (resolve, reject) {+ args.push(function (err, result) {+ if (err) {+ reject(err);+ } else if (opts.multiArgs) {+ var results = new Array(arguments.length - 1);++ for (var i = 1; i < arguments.length; i++) {+ results[i - 1] = arguments[i];+ }++ resolve(results);+ } else {+ resolve(result);+ }+ });++ fn.apply(that, args);+ });+ };+};++var pify = module.exports = function (obj, P, opts) {+ if (typeof P !== 'function') {+ opts = P;+ P = Promise;+ }++ opts = opts || {};+ opts.exclude = opts.exclude || [/.+Sync$/];++ var filter = function (key) {+ var match = function (pattern) {+ return typeof pattern === 'string' ? key === pattern : pattern.test(key);+ };++ return opts.include ? opts.include.some(match) : !opts.exclude.some(match);+ };++ var ret = typeof obj === 'function' ? function () {+ if (opts.excludeMain) {+ return obj.apply(this, arguments);+ }++ return processFn(obj, P, opts).apply(this, arguments);+ } : {};++ return Object.keys(obj).reduce(function (ret, key) {+ var x = obj[key];++ ret[key] = typeof x === 'function' && filter(key) ? processFn(x, P, opts) : x;++ return ret;+ }, ret);+};++pify.all = pify;diff --git a/data/node-webkit/node_modules/trash/node_modules/pify/license b/data/node-webkit/node_modules/trash/node_modules/pify/licensenew file mode 100644index 000000000..654d0bfe9--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/pify/license@@ -0,0 +1,21 @@+The MIT License (MIT)++Copyright (c) Sindre Sorhus <[email protected]> (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.diff --git a/data/node-webkit/node_modules/trash/node_modules/pify/package.json b/data/node-webkit/node_modules/trash/node_modules/pify/package.jsonnew file mode 100644index 000000000..56b2f0054--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/pify/package.json@@ -0,0 +1,78 @@+{+ "name": "pify",+ "version": "2.3.0",+ "description": "Promisify a callback-style function",+ "license": "MIT",+ "repository": {+ "type": "git",+ "url": "https://github.com/sindresorhus/pify"+ },+ "author": {+ "name": "Sindre Sorhus",+ "email": "[email protected]",+ "url": "sindresorhus.com"+ },+ "engines": {+ "node": ">=0.10.0"+ },+ "scripts": {+ "test": "xo && ava && npm run optimization-test",+ "optimization-test": "node --allow-natives-syntax optimization-test.js"+ },+ "files": [+ "index.js"+ ],+ "keywords": [+ "promise",+ "promises",+ "promisify",+ "denodify",+ "denodeify",+ "callback",+ "cb",+ "node",+ "then",+ "thenify",+ "convert",+ "transform",+ "wrap",+ "wrapper",+ "bind",+ "to",+ "async",+ "es2015"+ ],+ "devDependencies": {+ "ava": "*",+ "pinkie-promise": "^1.0.0",+ "v8-natives": "0.0.2",+ "xo": "*"+ },+ "gitHead": "2dd0d8b880e4ebcc5cc33ae126b02647418e4440",+ "bugs": {+ "url": "https://github.com/sindresorhus/pify/issues"+ },+ "homepage": "https://github.com/sindresorhus/pify",+ "_id": "[email protected]",+ "_shasum": "ed141a6ac043a849ea588498e7dca8b15330e90c",+ "_from": "pify@>=2.2.0 <3.0.0",+ "_npmVersion": "2.14.7",+ "_nodeVersion": "4.2.1",+ "_npmUser": {+ "name": "sindresorhus",+ "email": "[email protected]"+ },+ "dist": {+ "shasum": "ed141a6ac043a849ea588498e7dca8b15330e90c",+ "tarball": "http://registry.npmjs.org/pify/-/pify-2.3.0.tgz"+ },+ "maintainers": [+ {+ "name": "sindresorhus",+ "email": "[email protected]"+ }+ ],+ "directories": {},+ "_resolved": "https://registry.npmjs.org/pify/-/pify-2.3.0.tgz",+ "readme": "ERROR: No README data found!"+}diff --git a/data/node-webkit/node_modules/trash/node_modules/pify/readme.md b/data/node-webkit/node_modules/trash/node_modules/pify/readme.mdnew file mode 100644index 000000000..c79ca8bf6--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/pify/readme.md@@ -0,0 +1,119 @@+# pify [](https://travis-ci.org/sindresorhus/pify)++> Promisify a callback-style function+++## Install++```+$ npm install --save pify+```+++## Usage++```js+const fs = require('fs');+const pify = require('pify');++// promisify a single function++pify(fs.readFile)('package.json', 'utf8').then(data => {+ console.log(JSON.parse(data).name);+ //=> 'pify'+});++// or promisify all methods in a module++pify(fs).readFile('package.json', 'utf8').then(data => {+ console.log(JSON.parse(data).name);+ //=> 'pify'+});+```+++## API++### pify(input, [promiseModule], [options])++Returns a promise wrapped version of the supplied function or module.++#### input++Type: `function`, `object`++Callback-style function or module whose methods you want to promisify.++#### promiseModule++Type: `function`++Custom promise module to use instead of the native one.++Check out [`pinkie-promise`](https://github.com/floatdrop/pinkie-promise) if you need a tiny promise polyfill.++#### options++##### multiArgs++Type: `boolean`+Default: `false`++By default, the promisified function will only return the second argument from the callback, which works fine for most APIs. This option can be useful for modules like `request` that return multiple arguments. Turning this on will make it return an array of all arguments from the callback, excluding the error argument, instead of just the second argument.++```js+const request = require('request');+const pify = require('pify');++pify(request, {multiArgs: true})('https://sindresorhus.com').then(result => {+ const [httpResponse, body] = result;+});+```++##### include++Type: `array` of (`string`|`regex`)++Methods in a module to promisify. Remaining methods will be left untouched.++##### exclude++Type: `array` of (`string`|`regex`)+Default: `[/.+Sync$/]`++Methods in a module **not** to promisify. Methods with names ending with `'Sync'` are excluded by default.++##### excludeMain++Type: `boolean`+Default: `false`++By default, if given module is a function itself, this function will be promisified. Turn this option on if you want to promisify only methods of the module.++```js+const pify = require('pify');++function fn() {+ return true;+}++fn.method = (data, callback) => {+ setImmediate(() => {+ callback(data, null);+ });+};++// promisify methods but not fn()+const promiseFn = pify(fn, {excludeMain: true});++if (promiseFn()) {+ promiseFn.method('hi').then(data => {+ console.log(data);+ });+}+```+++## License++MIT © [Sindre Sorhus](http://sindresorhus.com)diff --git a/data/node-webkit/node_modules/trash/node_modules/pinkie-promise/index.js b/data/node-webkit/node_modules/trash/node_modules/pinkie-promise/index.jsnew file mode 100644index 000000000..cc64b902c--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/pinkie-promise/index.js@@ -0,0 +1,3 @@+'use strict';++module.exports = global.Promise || require('pinkie');diff --git a/data/node-webkit/node_modules/trash/node_modules/pinkie-promise/license b/data/node-webkit/node_modules/trash/node_modules/pinkie-promise/licensenew file mode 100644index 000000000..1aeb74fd2--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/pinkie-promise/license@@ -0,0 +1,21 @@+The MIT License (MIT)++Copyright (c) Vsevolod Strukchinsky <[email protected]> (github.com/floatdrop)++Permission is hereby granted, free of charge, to any person obtaining a copy+of this software and associated documentation files (the "Software"), to deal+in the Software without restriction, including without limitation the rights+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell+copies of the Software, and to permit persons to whom the Software is+furnished to do so, subject to the following conditions:++The above copyright notice and this permission notice shall be included in+all copies or substantial portions of the Software.++THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN+THE SOFTWARE.diff --git a/data/node-webkit/node_modules/trash/node_modules/pinkie-promise/node_modules/pinkie/index.js b/data/node-webkit/node_modules/trash/node_modules/pinkie-promise/node_modules/pinkie/index.jsnew file mode 100644index 000000000..a7e3dc385--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/pinkie-promise/node_modules/pinkie/index.js@@ -0,0 +1,276 @@+'use strict';++var PENDING = 'pending';+var SETTLED = 'settled';+var FULFILLED = 'fulfilled';+var REJECTED = 'rejected';+var NOOP = function () {};++// async calls+var asyncSetTimer = typeof setImmediate !== 'undefined' ? setImmediate : setTimeout;+var asyncQueue = [];+var asyncTimer;++function asyncFlush() {+ // run promise callbacks+ for (var i = 0; i < asyncQueue.length; i++) {+ asyncQueue[i][0](asyncQueue[i][1]);+ }++ // reset async asyncQueue+ asyncQueue = [];+ asyncTimer = false;+}++function asyncCall(callback, arg) {+ asyncQueue.push([callback, arg]);++ if (!asyncTimer) {+ asyncTimer = true;+ asyncSetTimer(asyncFlush, 0);+ }+}++function invokeResolver(resolver, promise) {+ function resolvePromise(value) {+ resolve(promise, value);+ }++ function rejectPromise(reason) {+ reject(promise, reason);+ }++ try {+ resolver(resolvePromise, rejectPromise);+ } catch (e) {+ rejectPromise(e);+ }+}++function invokeCallback(subscriber) {+ var owner = subscriber.owner;+ var settled = owner._state;+ var value = owner._data;+ var callback = subscriber[settled];+ var promise = subscriber.then;++ if (typeof callback === 'function') {+ settled = FULFILLED;+ try {+ value = callback(value);+ } catch (e) {+ reject(promise, e);+ }+ }++ if (!handleThenable(promise, value)) {+ if (settled === FULFILLED) {+ resolve(promise, value);+ }++ if (settled === REJECTED) {+ reject(promise, value);+ }+ }+}++function handleThenable(promise, value) {+ var resolved;++ try {+ if (promise === value) {+ throw new TypeError('A promises callback cannot return that same promise.');+ }++ if (value && (typeof value === 'function' || typeof value === 'object')) {+ var then = value.then; // then should be retrived only once++ if (typeof then === 'function') {+ then.call(value, function (val) {+ if (!resolved) {+ resolved = true;++ if (value !== val) {+ resolve(promise, val);+ } else {+ fulfill(promise, val);+ }+ }+ }, function (reason) {+ if (!resolved) {+ resolved = true;++ reject(promise, reason);+ }+ });++ return true;+ }+ }+ } catch (e) {+ if (!resolved) {+ reject(promise, e);+ }++ return true;+ }++ return false;+}++function resolve(promise, value) {+ if (promise === value || !handleThenable(promise, value)) {+ fulfill(promise, value);+ }+}++function fulfill(promise, value) {+ if (promise._state === PENDING) {+ promise._state = SETTLED;+ promise._data = value;++ asyncCall(publishFulfillment, promise);+ }+}++function reject(promise, reason) {+ if (promise._state === PENDING) {+ promise._state = SETTLED;+ promise._data = reason;++ asyncCall(publishRejection, promise);+ }+}++function publish(promise) {+ promise._then = promise._then.forEach(invokeCallback);+}++function publishFulfillment(promise) {+ promise._state = FULFILLED;+ publish(promise);+}++function publishRejection(promise) {+ promise._state = REJECTED;+ publish(promise);+}++/**+ * @class+ */+function Promise(resolver) {+ if (typeof resolver !== 'function') {+ throw new TypeError('Promise resolver ' + resolver + ' is not a function');+ }++ if (this instanceof Promise === false) {+ throw new TypeError('Failed to construct \'Promise\': Please use the \'new\' operator, this object constructor cannot be called as a function.');+ }++ this._then = [];++ invokeResolver(resolver, this);+}++Promise.prototype = {+ constructor: Promise,++ _state: PENDING,+ _then: null,+ _data: undefined,++ then: function (onFulfillment, onRejection) {+ var subscriber = {+ owner: this,+ then: new this.constructor(NOOP),+ fulfilled: onFulfillment,+ rejected: onRejection+ };++ if (this._state === FULFILLED || this._state === REJECTED) {+ // already resolved, call callback async+ asyncCall(invokeCallback, subscriber);+ } else {+ // subscribe+ this._then.push(subscriber);+ }++ return subscriber.then;+ },++ 'catch': function (onRejection) {+ return this.then(null, onRejection);+ }+};++Promise.all = function (promises) {+ if (!Array.isArray(promises)) {+ throw new TypeError('You must pass an array to Promise.all().');+ }++ return new Promise(function (resolve, reject) {+ var results = [];+ var remaining = 0;++ function resolver(index) {+ remaining++;+ return function (value) {+ results[index] = value;+ if (!--remaining) {+ resolve(results);+ }+ };+ }++ for (var i = 0, promise; i < promises.length; i++) {+ promise = promises[i];++ if (promise && typeof promise.then === 'function') {+ promise.then(resolver(i), reject);+ } else {+ results[i] = promise;+ }+ }++ if (!remaining) {+ resolve(results);+ }+ });+};++Promise.race = function (promises) {+ if (!Array.isArray(promises)) {+ throw new TypeError('You must pass an array to Promise.race().');+ }++ return new Promise(function (resolve, reject) {+ for (var i = 0, promise; i < promises.length; i++) {+ promise = promises[i];++ if (promise && typeof promise.then === 'function') {+ promise.then(resolve, reject);+ } else {+ resolve(promise);+ }+ }+ });+};++Promise.resolve = function (value) {+ if (value && typeof value === 'object' && value.constructor === Promise) {+ return value;+ }++ return new Promise(function (resolve) {+ resolve(value);+ });+};++Promise.reject = function (reason) {+ return new Promise(function (resolve, reject) {+ reject(reason);+ });+};++module.exports = Promise;diff --git a/data/node-webkit/node_modules/trash/node_modules/pinkie-promise/node_modules/pinkie/license b/data/node-webkit/node_modules/trash/node_modules/pinkie-promise/node_modules/pinkie/licensenew file mode 100644index 000000000..1aeb74fd2--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/pinkie-promise/node_modules/pinkie/license@@ -0,0 +1,21 @@+The MIT License (MIT)++Copyright (c) Vsevolod Strukchinsky <[email protected]> (github.com/floatdrop)++Permission is hereby granted, free of charge, to any person obtaining a copy+of this software and associated documentation files (the "Software"), to deal+in the Software without restriction, including without limitation the rights+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell+copies of the Software, and to permit persons to whom the Software is+furnished to do so, subject to the following conditions:++The above copyright notice and this permission notice shall be included in+all copies or substantial portions of the Software.++THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN+THE SOFTWARE.diff --git a/data/node-webkit/node_modules/trash/node_modules/pinkie-promise/node_modules/pinkie/package.json b/data/node-webkit/node_modules/trash/node_modules/pinkie-promise/node_modules/pinkie/package.jsonnew file mode 100644index 000000000..a52f3cdff--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/pinkie-promise/node_modules/pinkie/package.json@@ -0,0 +1,60 @@+{+ "name": "pinkie",+ "version": "1.0.0",+ "description": "Itty bitty little wittle twinkie pinkie ES6 Promise implementation",+ "license": "MIT",+ "repository": {+ "type": "git",+ "url": "git+https://github.com/floatdrop/pinkie.git"+ },+ "author": {+ "name": "Vsevolod Strukchinsky",+ "email": "[email protected]",+ "url": "github.com/floatdrop"+ },+ "engines": {+ "node": ">=0.10.0"+ },+ "scripts": {+ "test": "mocha"+ },+ "files": [+ "index.js"+ ],+ "keywords": [+ "promise",+ "es6"+ ],+ "dependencies": {},+ "devDependencies": {+ "mocha": "*",+ "promises-aplus-tests": "*"+ },+ "gitHead": "5f8b60f31ec8624995d224f5990c81be83dd1d90",+ "bugs": {+ "url": "https://github.com/floatdrop/pinkie/issues"+ },+ "homepage": "https://github.com/floatdrop/pinkie#readme",+ "_id": "[email protected]",+ "_shasum": "5a47f28ba1015d0201bda7bf0f358e47bec8c7e4",+ "_from": "pinkie@>=1.0.0 <2.0.0",+ "_npmVersion": "2.9.0",+ "_nodeVersion": "2.0.0",+ "_npmUser": {+ "name": "floatdrop",+ "email": "[email protected]"+ },+ "maintainers": [+ {+ "name": "floatdrop",+ "email": "[email protected]"+ }+ ],+ "dist": {+ "shasum": "5a47f28ba1015d0201bda7bf0f358e47bec8c7e4",+ "tarball": "http://registry.npmjs.org/pinkie/-/pinkie-1.0.0.tgz"+ },+ "directories": {},+ "_resolved": "https://registry.npmjs.org/pinkie/-/pinkie-1.0.0.tgz",+ "readme": "ERROR: No README data found!"+}diff --git a/data/node-webkit/node_modules/trash/node_modules/pinkie-promise/node_modules/pinkie/readme.md b/data/node-webkit/node_modules/trash/node_modules/pinkie-promise/node_modules/pinkie/readme.mdnew file mode 100644index 000000000..faa9b2b88--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/pinkie-promise/node_modules/pinkie/readme.md@@ -0,0 +1,75 @@+<h1 align="center">+ <br>+ <img width="300" src="https://rawgit.com/floatdrop/pinkie/master/media/logo.png" alt="pinkie">+ <br>+ <br>+</h1>++> Itty bitty little wittle twinkie pinkie [ES6 Promise](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-promise-objects) implementation++[](https://travis-ci.org/floatdrop/pinkie)++There are [tons of Promise implementations](https://github.com/sorrycc/awesome-javascript#control-flow) out there, but all of them focused on browser compatibility and often bloated with functionality.++This module focused to be exactly Promise specification polyfill (like [native-promise-only](https://github.com/getify/native-promise-only)), but in NodeJS land (it should be browserify-able thou).+++## Install++```+$ npm install --save pinkie+```+++## Usage++```js+var Promise = require('pinkie');++new Promise(function (resolve, reject) {+ got('google.com', function (err, data) {+ if (err) {+ return reject(err);+ }++ resolve(data);+ });+});+//=> Promise+```+++### API++`pinkie` exports bare [ES6 Promise](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-promise-objects) implementation. In case you forgot:++#### new Promise(executor)++Returns new instance of `Promise`.++##### executor++*Required*+Type: `function`++Function with two arguments resolve and reject. The first argument fulfills the promise, the second argument rejects it.++#### pinkie.all(promises)++Returns a promise that resolves when all of the promises in the `promises` Array argument have resolved.++#### pinkie.race(promises)++Returns a promise that resolves or rejects as soon as one of the promises in the `promises` Array resolves or rejects, with the value or reason from that promise.++#### pinkie.reject(reason)++Returns a Promise object that is rejected with the given `reason`.++#### pinkie.resolve(value)++Returns a Promise object that is resolved with the given `value`. If the `value` is a thenable (i.e. has a then method), the returned promise will "follow" that thenable, adopting its eventual state; otherwise the returned promise will be fulfilled with the `value`.++## License++MIT © [Vsevolod Strukchinsky](http://github.com/floatdrop)diff --git a/data/node-webkit/node_modules/trash/node_modules/pinkie-promise/package.json b/data/node-webkit/node_modules/trash/node_modules/pinkie-promise/package.jsonnew file mode 100644index 000000000..467ba5d0d--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/pinkie-promise/package.json@@ -0,0 +1,63 @@+{+ "name": "pinkie-promise",+ "version": "1.0.0",+ "description": "ES6 Promise ponyfill",+ "license": "MIT",+ "repository": {+ "type": "git",+ "url": "git+https://github.com/floatdrop/pinkie-promise.git"+ },+ "author": {+ "name": "Vsevolod Strukchinsky",+ "email": "[email protected]",+ "url": "github.com/floatdrop"+ },+ "engines": {+ "node": ">=0.10.0"+ },+ "scripts": {+ "test": "mocha"+ },+ "files": [+ "index.js"+ ],+ "keywords": [+ "promise",+ "es6",+ "polyfill",+ "ponyfill"+ ],+ "dependencies": {+ "pinkie": "^1.0.0"+ },+ "devDependencies": {+ "mocha": "*"+ },+ "gitHead": "ae764482353d0b2b64685686cf49eefeb44a862e",+ "bugs": {+ "url": "https://github.com/floatdrop/pinkie-promise/issues"+ },+ "homepage": "https://github.com/floatdrop/pinkie-promise#readme",+ "_id": "[email protected]",+ "_shasum": "d1da67f5482563bb7cf57f286ae2822ecfbf3670",+ "_from": "pinkie-promise@>=1.0.0 <2.0.0",+ "_npmVersion": "2.9.0",+ "_nodeVersion": "2.0.0",+ "_npmUser": {+ "name": "floatdrop",+ "email": "[email protected]"+ },+ "maintainers": [+ {+ "name": "floatdrop",+ "email": "[email protected]"+ }+ ],+ "dist": {+ "shasum": "d1da67f5482563bb7cf57f286ae2822ecfbf3670",+ "tarball": "http://registry.npmjs.org/pinkie-promise/-/pinkie-promise-1.0.0.tgz"+ },+ "directories": {},+ "_resolved": "https://registry.npmjs.org/pinkie-promise/-/pinkie-promise-1.0.0.tgz",+ "readme": "ERROR: No README data found!"+}diff --git a/data/node-webkit/node_modules/trash/node_modules/pinkie-promise/readme.md b/data/node-webkit/node_modules/trash/node_modules/pinkie-promise/readme.mdnew file mode 100644index 000000000..bb5e9d2e0--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/pinkie-promise/readme.md@@ -0,0 +1,26 @@+# pinkie-promise [](https://travis-ci.org/floatdrop/pinkie-promise)++> [ES6 Promise](https://people.mozilla.org/~jorendorff/es6-draft.html#sec-promise-objects) ponyfill+>+> Ponyfill: A polyfill that doesn't overwrite the native method++Module exports global Promise object (if available) or [`pinkie`](http://github.com/floatdrop/pinkie) Promise polyfill.++## Install++```+$ npm install --save pinkie-promise+```++## Usage++```js+var Promise = require('pinkie-promise');++new Promise(function (resolve) { resolve('unicorns'); });+//=> Promise { 'unicorns' }+```++## License++MIT © [Vsevolod Strukchinsky](http://github.com/floatdrop)diff --git a/data/node-webkit/node_modules/trash/node_modules/run-applescript/index.js b/data/node-webkit/node_modules/trash/node_modules/run-applescript/index.jsnew file mode 100644index 000000000..30bd922ae--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/run-applescript/index.js@@ -0,0 +1,15 @@+'use strict';+var execFile = require('child_process').execFile;+var Promise = require('pinkie-promise');+var pify = require('pify');++module.exports = function (str) {+ if (process.platform !== 'darwin') {+ return Promise.reject(new Error('Only OS X systems are supported'));+ }++ return pify(execFile, Promise)('osascript', ['-e', str])+ .then(function (stdout) {+ return stdout.trim();+ });+};diff --git a/data/node-webkit/node_modules/trash/node_modules/run-applescript/license b/data/node-webkit/node_modules/trash/node_modules/run-applescript/licensenew file mode 100644index 000000000..654d0bfe9--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/run-applescript/license@@ -0,0 +1,21 @@+The MIT License (MIT)++Copyright (c) Sindre Sorhus <[email protected]> (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.diff --git a/data/node-webkit/node_modules/trash/node_modules/run-applescript/package.json b/data/node-webkit/node_modules/trash/node_modules/run-applescript/package.jsonnew file mode 100644index 000000000..26d85d0c6--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/run-applescript/package.json@@ -0,0 +1,72 @@+{+ "name": "run-applescript",+ "version": "2.0.0",+ "description": "Run AppleScript and get the result",+ "license": "MIT",+ "repository": {+ "type": "git",+ "url": "https://github.com/sindresorhus/run-applescript"+ },+ "author": {+ "name": "Sindre Sorhus",+ "email": "[email protected]",+ "url": "sindresorhus.com"+ },+ "engines": {+ "node": ">=0.10.0"+ },+ "scripts": {+ "test": "xo && ava"+ },+ "files": [+ "index.js"+ ],+ "keywords": [+ "osx",+ "mac",+ "applescript",+ "osascript",+ "run",+ "execute"+ ],+ "dependencies": {+ "pify": "^2.2.0",+ "pinkie-promise": "^1.0.0"+ },+ "devDependencies": {+ "ava": "*",+ "xo": "*"+ },+ "xo": {+ "ignores": [+ "test.js"+ ]+ },+ "gitHead": "9b9ee92263d8a1908e389a45c463c36f3539f6f0",+ "bugs": {+ "url": "https://github.com/sindresorhus/run-applescript/issues"+ },+ "homepage": "https://github.com/sindresorhus/run-applescript",+ "_id": "[email protected]",+ "_shasum": "16300884ffc80d81ed33afa480ab390ea001f8f8",+ "_from": "run-applescript@>=2.0.0 <3.0.0",+ "_npmVersion": "2.14.4",+ "_nodeVersion": "4.1.1",+ "_npmUser": {+ "name": "sindresorhus",+ "email": "[email protected]"+ },+ "dist": {+ "shasum": "16300884ffc80d81ed33afa480ab390ea001f8f8",+ "tarball": "http://registry.npmjs.org/run-applescript/-/run-applescript-2.0.0.tgz"+ },+ "maintainers": [+ {+ "name": "sindresorhus",+ "email": "[email protected]"+ }+ ],+ "directories": {},+ "_resolved": "https://registry.npmjs.org/run-applescript/-/run-applescript-2.0.0.tgz",+ "readme": "ERROR: No README data found!"+}diff --git a/data/node-webkit/node_modules/trash/node_modules/run-applescript/readme.md b/data/node-webkit/node_modules/trash/node_modules/run-applescript/readme.mdnew file mode 100644index 000000000..c88852b62--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/run-applescript/readme.md@@ -0,0 +1,27 @@+# run-applescript [](https://travis-ci.org/sindresorhus/run-applescript)++> Run AppleScript and get the result+++## Install++```+$ npm install --save run-applescript+```+++## Usage++```js+const runApplescript = require('run-applescript');++runApplescript('return "unicorn"').then(result => {+ console.log(result);+ //=> 'unicorn'+});+```+++## License++MIT © [Sindre Sorhus](http://sindresorhus.com)diff --git a/data/node-webkit/node_modules/trash/node_modules/uuid/.npmignore b/data/node-webkit/node_modules/trash/node_modules/uuid/.npmignorenew file mode 100644index 000000000..fd4f2b066--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/uuid/.npmignore@@ -0,0 +1,2 @@+node_modules+.DS_Storediff --git a/data/node-webkit/node_modules/trash/node_modules/uuid/.travis.yml b/data/node-webkit/node_modules/trash/node_modules/uuid/.travis.ymlnew file mode 100644index 000000000..9400c1188--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/uuid/.travis.yml@@ -0,0 +1,5 @@+language: node_js+node_js:+ - "0.6"+ - "0.8"+ - "0.10"diff --git a/data/node-webkit/node_modules/trash/node_modules/uuid/LICENSE.md b/data/node-webkit/node_modules/trash/node_modules/uuid/LICENSE.mdnew file mode 100644index 000000000..f039427fa--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/uuid/LICENSE.md@@ -0,0 +1,2 @@+Copyright (c) 2010-2012 Robert Kieffer+MIT License - http://opensource.org/licenses/mit-license.phpdiff --git a/data/node-webkit/node_modules/trash/node_modules/uuid/README.md b/data/node-webkit/node_modules/trash/node_modules/uuid/README.mdnew file mode 100644index 000000000..0965cbb34--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/uuid/README.md@@ -0,0 +1,205 @@+# uuid [](http://travis-ci.org/defunctzombie/node-uuid) #++[](https://ci.testling.com/defunctzombie/node-uuid)++Simple, fast generation of [RFC4122](http://www.ietf.org/rfc/rfc4122.txt) UUIDS.++Features:++* Generate RFC4122 version 1 or version 4 UUIDs+* Runs in node.js and all browsers.+* Cryptographically strong random # generation on supporting platforms+* 1185 bytes minified and gzip'ed (Want something smaller? Check this [crazy shit](https://gist.github.com/982883) out! )+* [Annotated source code](http://broofa.github.com/node-uuid/docs/uuid.html)++## Getting Started++Install it in your browser:++```html+<script src="uuid.js"></script>+```++Or in node.js:++```+npm install uuid+```++```javascript+var uuid = require('uuid');++// Generate a v1 (time-based) id+uuid.v1(); // -> '6c84fb90-12c4-11e1-840d-7b25c5ee775a'++// Generate a v4 (random) id+uuid.v4(); // -> '110ec58a-a0f2-4ac4-8393-c866d813b8d1'+```++## API++### uuid.v1([`options` [, `buffer` [, `offset`]]])++Generate and return a RFC4122 v1 (timestamp-based) UUID.++* `options` - (Object) Optional uuid state to apply. Properties may include:++ * `node` - (Array) Node id as Array of 6 bytes (per 4.1.6). Default: Randomly generated ID. See note 1.+ * `clockseq` - (Number between 0 - 0x3fff) RFC clock sequence. Default: An internally maintained clockseq is used.+ * `msecs` - (Number | Date) Time in milliseconds since unix Epoch. Default: The current time is used.+ * `nsecs` - (Number between 0-9999) additional time, in 100-nanosecond units. Ignored if `msecs` is unspecified. Default: internal uuid counter is used, as per 4.2.1.2.++* `buffer` - (Array | Buffer) Array or buffer where UUID bytes are to be written.+* `offset` - (Number) Starting index in `buffer` at which to begin writing.++Returns `buffer`, if specified, otherwise the string form of the UUID++Notes:++1. The randomly generated node id is only guaranteed to stay constant for the lifetime of the current JS runtime. (Future versions of this module may use persistent storage mechanisms to extend this guarantee.)++Example: Generate string UUID with fully-specified options++```javascript+uuid.v1({+ node: [0x01, 0x23, 0x45, 0x67, 0x89, 0xab],+ clockseq: 0x1234,+ msecs: new Date('2011-11-01').getTime(),+ nsecs: 5678+}); // -> "710b962e-041c-11e1-9234-0123456789ab"+```++Example: In-place generation of two binary IDs++```javascript+// Generate two ids in an array+var arr = new Array(32); // -> []+uuid.v1(null, arr, 0); // -> [02 a2 ce 90 14 32 11 e1 85 58 0b 48 8e 4f c1 15]+uuid.v1(null, arr, 16); // -> [02 a2 ce 90 14 32 11 e1 85 58 0b 48 8e 4f c1 15 02 a3 1c b0 14 32 11 e1 85 58 0b 48 8e 4f c1 15]++// Optionally use uuid.unparse() to get stringify the ids+uuid.unparse(buffer); // -> '02a2ce90-1432-11e1-8558-0b488e4fc115'+uuid.unparse(buffer, 16) // -> '02a31cb0-1432-11e1-8558-0b488e4fc115'+```++### uuid.v4([`options` [, `buffer` [, `offset`]]])++Generate and return a RFC4122 v4 UUID.++* `options` - (Object) Optional uuid state to apply. Properties may include:++ * `random` - (Number[16]) Array of 16 numbers (0-255) to use in place of randomly generated values+ * `rng` - (Function) Random # generator to use. Set to one of the built-in generators - `uuid.mathRNG` (all platforms), `uuid.nodeRNG` (node.js only), `uuid.whatwgRNG` (WebKit only) - or a custom function that returns an array[16] of byte values.++* `buffer` - (Array | Buffer) Array or buffer where UUID bytes are to be written.+* `offset` - (Number) Starting index in `buffer` at which to begin writing.++Returns `buffer`, if specified, otherwise the string form of the UUID++Example: Generate string UUID with fully-specified options++```javascript+uuid.v4({+ random: [+ 0x10, 0x91, 0x56, 0xbe, 0xc4, 0xfb, 0xc1, 0xea,+ 0x71, 0xb4, 0xef, 0xe1, 0x67, 0x1c, 0x58, 0x36+ ]+});+// -> "109156be-c4fb-41ea-b1b4-efe1671c5836"+```++Example: Generate two IDs in a single buffer++```javascript+var buffer = new Array(32); // (or 'new Buffer' in node.js)+uuid.v4(null, buffer, 0);+uuid.v4(null, buffer, 16);+```++### uuid.parse(id[, buffer[, offset]])+### uuid.unparse(buffer[, offset])++Parse and unparse UUIDs++ * `id` - (String) UUID(-like) string+ * `buffer` - (Array | Buffer) Array or buffer where UUID bytes are to be written. Default: A new Array or Buffer is used+ * `offset` - (Number) Starting index in `buffer` at which to begin writing. Default: 0++Example parsing and unparsing a UUID string++```javascript+var bytes = uuid.parse('797ff043-11eb-11e1-80d6-510998755d10'); // -> <Buffer 79 7f f0 43 11 eb 11 e1 80 d6 51 09 98 75 5d 10>+var string = uuid.unparse(bytes); // -> '797ff043-11eb-11e1-80d6-510998755d10'+```++### uuid.noConflict()++(Browsers only) Set `uuid` property back to it's previous value.++Returns the uuid object.++Example:++```javascript+var myUuid = uuid.noConflict();+myUuid.v1(); // -> '6c84fb90-12c4-11e1-840d-7b25c5ee775a'+```++## Deprecated APIs++Support for the following v1.2 APIs is available in v1.3, but is deprecated and will be removed in the next major version.++### uuid([format [, buffer [, offset]]])++uuid() has become uuid.v4(), and the `format` argument is now implicit in the `buffer` argument. (i.e. if you specify a buffer, the format is assumed to be binary).++### uuid.BufferClass++The class of container created when generating binary uuid data if no buffer argument is specified. This is expected to go away, with no replacement API.++## Testing++In node.js++```+> cd test+> node test.js+```++In Browser++```+open test/test.html+```++### Benchmarking++Requires node.js++```+cd benchmark/+npm install+node benchmark.js+```++For a more complete discussion of uuid performance, please see the `benchmark/README.md` file, and the [benchmark wiki](https://github.com/broofa/uuid/wiki/Benchmark)++For browser performance [checkout the JSPerf tests](http://jsperf.com/node-uuid-performance).++## Release notes++### 1.4.0++* Improved module context detection+* Removed public RNG functions++### 1.3.2++* Improve tests and handling of v1() options (Issue #24)+* Expose RNG option to allow for perf testing with different generators++### 1.3.0++* Support for version 1 ids, thanks to [@ctavan](https://github.com/ctavan)!+* Support for node.js crypto API+* De-emphasizing performance in favor of a) cryptographic quality PRNGs where available and b) more manageable codediff --git a/data/node-webkit/node_modules/trash/node_modules/uuid/benchmark/README.md b/data/node-webkit/node_modules/trash/node_modules/uuid/benchmark/README.mdnew file mode 100644index 000000000..aaeb2ea01--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/uuid/benchmark/README.md@@ -0,0 +1,53 @@+# node-uuid Benchmarks++### Results++To see the results of our benchmarks visit https://github.com/broofa/node-uuid/wiki/Benchmark++### Run them yourself++node-uuid comes with some benchmarks to measure performance of generating UUIDs. These can be run using node.js. node-uuid is being benchmarked against some other uuid modules, that are available through npm namely `uuid` and `uuid-js`.++To prepare and run the benchmark issue;++```+npm install uuid uuid-js+node benchmark/benchmark.js+```++You'll see an output like this one:++```+# v4+nodeuuid.v4(): 854700 uuids/second+nodeuuid.v4('binary'): 788643 uuids/second+nodeuuid.v4('binary', buffer): 1336898 uuids/second+uuid(): 479386 uuids/second+uuid('binary'): 582072 uuids/second+uuidjs.create(4): 312304 uuids/second++# v1+nodeuuid.v1(): 938086 uuids/second+nodeuuid.v1('binary'): 683060 uuids/second+nodeuuid.v1('binary', buffer): 1644736 uuids/second+uuidjs.create(1): 190621 uuids/second+```++* The `uuid()` entries are for Nikhil Marathe's [uuid module](https://bitbucket.org/nikhilm/uuidjs) which is a wrapper around the native libuuid library.+* The `uuidjs()` entries are for Patrick Negri's [uuid-js module](https://github.com/pnegri/uuid-js) which is a pure javascript implementation based on [UUID.js](https://github.com/LiosK/UUID.js) by LiosK.++If you want to get more reliable results you can run the benchmark multiple times and write the output into a log file:++```+for i in {0..9}; do node benchmark/benchmark.js >> benchmark/bench_0.4.12.log; done;+```++If you're interested in how performance varies between different node versions, you can issue the above command multiple times.++You can then use the shell script `bench.sh` provided in this directory to calculate the averages over all benchmark runs and draw a nice plot:++```+(cd benchmark/ && ./bench.sh)+```++This assumes you have [gnuplot](http://www.gnuplot.info/) and [ImageMagick](http://www.imagemagick.org/) installed. You'll find a nice `bench.png` graph in the `benchmark/` directory then.diff --git a/data/node-webkit/node_modules/trash/node_modules/uuid/benchmark/bench.gnu b/data/node-webkit/node_modules/trash/node_modules/uuid/benchmark/bench.gnunew file mode 100644index 000000000..a342fbbe0--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/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+# EOFdiff --git a/data/node-webkit/node_modules/trash/node_modules/uuid/benchmark/bench.sh b/data/node-webkit/node_modules/trash/node_modules/uuid/benchmark/bench.shnew file mode 100644index 000000000..d870a0cb0--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/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.epsdiff --git a/data/node-webkit/node_modules/trash/node_modules/uuid/benchmark/benchmark-native.c b/data/node-webkit/node_modules/trash/node_modules/uuid/benchmark/benchmark-native.cnew file mode 100644index 000000000..dbfc75f6d--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/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;+}diff --git a/data/node-webkit/node_modules/trash/node_modules/uuid/benchmark/benchmark.js b/data/node-webkit/node_modules/trash/node_modules/uuid/benchmark/benchmark.jsnew file mode 100644index 000000000..40e6efbe7--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/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);+}diff --git a/data/node-webkit/node_modules/trash/node_modules/uuid/benchmark/package.json b/data/node-webkit/node_modules/trash/node_modules/uuid/benchmark/package.jsonnew file mode 100644index 000000000..94e0b5938--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/uuid/benchmark/package.json@@ -0,0 +1,9 @@+{+ "name": "benchmark-uuid",+ "private": true,+ "description": "Benchmarks for node-uuid",+ "dependencies": {+ "uuid": "1.4.1",+ "uuid-js": "0.7.4"+ }+}diff --git a/data/node-webkit/node_modules/trash/node_modules/uuid/misc/compare.js b/data/node-webkit/node_modules/trash/node_modules/uuid/misc/compare.jsnew file mode 100644index 000000000..3de34151d--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/uuid/misc/compare.js@@ -0,0 +1,62 @@+var assert = require('assert'),+ nodeuuid = require('../'),+ uuidjs = require('uuid-js'),+ 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();diff --git a/data/node-webkit/node_modules/trash/node_modules/uuid/misc/perf.js b/data/node-webkit/node_modules/trash/node_modules/uuid/misc/perf.jsnew file mode 100644index 000000000..bdc9eb461--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/uuid/misc/perf.js@@ -0,0 +1,102 @@+var assert = require('assert');++var uuid = require('../');++var log = console.log;++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);+}diff --git a/data/node-webkit/node_modules/trash/node_modules/uuid/package.json b/data/node-webkit/node_modules/trash/node_modules/uuid/package.jsonnew file mode 100644index 000000000..e8b5742ff--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/uuid/package.json@@ -0,0 +1,86 @@+{+ "name": "uuid",+ "version": "2.0.1",+ "description": "Rigorous implementation of RFC4122 (v1 and v4) UUIDs.",+ "keywords": [+ "uuid",+ "guid",+ "rfc4122"+ ],+ "author": {+ "name": "Robert Kieffer",+ "email": "[email protected]"+ },+ "contributors": [+ {+ "name": "Christoph Tavan",+ "email": "[email protected]"+ },+ {+ "name": "Vincent Voyer",+ "email": "[email protected]"+ }+ ],+ "main": "./uuid.js",+ "devDependencies": {+ "mocha": "1.8.0"+ },+ "scripts": {+ "test": "mocha test/test.js"+ },+ "browser": {+ "./rng.js": "./rng-browser.js"+ },+ "repository": {+ "type": "git",+ "url": "https://github.com/shtylman/node-uuid.git"+ },+ "testling": {+ "browsers": [+ "ie6..latest",+ "firefox/3.6..latest",+ "chrome/22..latest",+ "safari/5.1..latest"+ ],+ "harness": "mocha-tdd",+ "files": "test/*.js"+ },+ "gitHead": "ddaf90942095f26ee8c1961b4346f093b3e7eb5b",+ "bugs": {+ "url": "https://github.com/shtylman/node-uuid/issues"+ },+ "homepage": "https://github.com/shtylman/node-uuid",+ "_id": "[email protected]",+ "_shasum": "c2a30dedb3e535d72ccf82e343941a50ba8533ac",+ "_from": "uuid@>=2.0.1 <3.0.0",+ "_npmVersion": "2.0.0",+ "_npmUser": {+ "name": "vvo",+ "email": "[email protected]"+ },+ "maintainers": [+ {+ "name": "broofa",+ "email": "[email protected]"+ },+ {+ "name": "tim-smart",+ "email": "[email protected]"+ },+ {+ "name": "shtylman",+ "email": "[email protected]"+ },+ {+ "name": "vvo",+ "email": "[email protected]"+ }+ ],+ "dist": {+ "shasum": "c2a30dedb3e535d72ccf82e343941a50ba8533ac",+ "tarball": "http://registry.npmjs.org/uuid/-/uuid-2.0.1.tgz"+ },+ "directories": {},+ "_resolved": "https://registry.npmjs.org/uuid/-/uuid-2.0.1.tgz",+ "readme": "ERROR: No README data found!"+}diff --git a/data/node-webkit/node_modules/trash/node_modules/uuid/rng-browser.js b/data/node-webkit/node_modules/trash/node_modules/uuid/rng-browser.jsnew file mode 100644index 000000000..57b58d4b6--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/uuid/rng-browser.js@@ -0,0 +1,31 @@++var rng;++if (global.crypto && crypto.getRandomValues) {+ // WHATWG crypto-based RNG - http://wiki.whatwg.org/wiki/Crypto+ // Moderately fast, high quality+ var _rnds8 = new Uint8Array(16);+ rng = function whatwgRNG() {+ crypto.getRandomValues(_rnds8);+ return _rnds8;+ };+}++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;+ };+}++module.exports = rng;+diff --git a/data/node-webkit/node_modules/trash/node_modules/uuid/rng.js b/data/node-webkit/node_modules/trash/node_modules/uuid/rng.jsnew file mode 100644index 000000000..3977f798f--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/uuid/rng.js@@ -0,0 +1,4 @@+var rb = require('crypto').randomBytes;+module.exports = function() {+ return rb(16);+};diff --git a/data/node-webkit/node_modules/trash/node_modules/uuid/test/mocha.opts b/data/node-webkit/node_modules/trash/node_modules/uuid/test/mocha.optsnew file mode 100644index 000000000..e2bfcc5ac--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/uuid/test/mocha.opts@@ -0,0 +1 @@+--ui qunitdiff --git a/data/node-webkit/node_modules/trash/node_modules/uuid/test/test.js b/data/node-webkit/node_modules/trash/node_modules/uuid/test/test.jsnew file mode 100644index 000000000..4c9872ffe--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/uuid/test/test.js@@ -0,0 +1,105 @@+var assert = require('assert');++var uuid = require('../');++// 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) {+ test(name, function() {+ // avoid .map for older browsers+ for (var i=0 ; i<ids.length ; ++i) {+ ids[i] = ids[i].split('-').reverse().join('-');+ }+ ids = ids.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})+]);++test('msec', function() {+ assert(+ uuid.v1({msecs: TIME}) != uuid.v1({msecs: TIME}),+ 'IDs created at same msec are different'+ );+});++test('exception thrown when > 10k ids created in 1ms', function() {+ // 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');+});++test('clock regression by msec', function() {+ // 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'+ );+});++test('clock regression by nsec', function() {+ // 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'+ );+});++test('explicit options product expected id', function() {+ // 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');+});++test('ids spanning 1ms boundary are 100ns apart', function() {+ // 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', function() {+ var 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');+});+diff --git a/data/node-webkit/node_modules/trash/node_modules/uuid/uuid.js b/data/node-webkit/node_modules/trash/node_modules/uuid/uuid.jsnew file mode 100644index 000000000..be5bfede9--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/uuid/uuid.js@@ -0,0 +1,183 @@+// uuid.js+//+// Copyright (c) 2010-2012 Robert Kieffer+// MIT License - http://opensource.org/licenses/mit-license.php++// 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 = require('./rng');++// Maps for number <-> hex string conversion+var _byteToHex = [];+var _hexToByte = {};+for (var i = 0; i < 256; i++) {+ _byteToHex[i] = (i + 0x100).toString(16).substr(1);+ _hexToByte[_byteToHex[i]] = i;+}++// **`parse()` - Parse a UUID into it's component bytes**+function parse(s, buf, offset) {+ var i = (buf && offset) || 0, ii = 0;++ buf = buf || [];+ s.toLowerCase().replace(/[0-9a-f]{2}/g, function(oct) {+ if (ii < 16) { // Don't overflow!+ buf[i + ii++] = _hexToByte[oct];+ }+ });++ // Zero out remaining bytes if string was short+ while (ii < 16) {+ buf[i + ii++] = 0;+ }++ return buf;+}++// **`unparse()` - Convert UUID byte array (ala parse()) into a string**+function unparse(buf, offset) {+ var i = offset || 0, bth = _byteToHex;+ return bth[buf[i++]] + bth[buf[i++]] ++ bth[buf[i++]] + bth[buf[i++]] + '-' ++ bth[buf[i++]] + bth[buf[i++]] + '-' ++ bth[buf[i++]] + bth[buf[i++]] + '-' ++ bth[buf[i++]] + bth[buf[i++]] + '-' ++ bth[buf[i++]] + bth[buf[i++]] ++ bth[buf[i++]] + bth[buf[i++]] ++ bth[buf[i++]] + bth[buf[i++]];+}++// **`v1()` - Generate time-based UUID**+//+// Inspired by https://github.com/LiosK/UUID.js+// and http://docs.python.org/library/uuid.html++// random #'s we need to init node and clockseq+var _seedBytes = _rng();++// Per 4.5, create and 48-bit node id, (47 random bits + multicast bit = 1)+var _nodeId = [+ _seedBytes[0] | 0x01,+ _seedBytes[1], _seedBytes[2], _seedBytes[3], _seedBytes[4], _seedBytes[5]+];++// Per 4.2.2, randomize (14 bit) clockseq+var _clockseq = (_seedBytes[6] << 8 | _seedBytes[7]) & 0x3fff;++// Previous uuid creation time+var _lastMSecs = 0, _lastNSecs = 0;++// See https://github.com/broofa/node-uuid for API details+function v1(options, buf, offset) {+ var i = buf && offset || 0;+ var b = buf || [];++ options = options || {};++ var clockseq = options.clockseq !== undefined ? 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 !== undefined ? 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 !== undefined ? options.nsecs : _lastNSecs + 1;++ // Time since last uuid creation (in msecs)+ var dt = (msecs - _lastMSecs) + (nsecs - _lastNSecs)/10000;++ // Per 4.2.1.2, Bump clockseq on clock regression+ if (dt < 0 && options.clockseq === undefined) {+ clockseq = clockseq + 1 & 0x3fff;+ }++ // Reset nsecs if clock regresses (new clockseq) or we've moved onto a new+ // time interval+ if ((dt < 0 || msecs > _lastMSecs) && options.nsecs === undefined) {+ nsecs = 0;+ }++ // Per 4.2.1.2 Throw error if too many uuids are requested+ if (nsecs >= 10000) {+ throw new Error('uuid.v1(): Can\'t create more than 10M uuids/sec');+ }++ _lastMSecs = msecs;+ _lastNSecs = nsecs;+ _clockseq = clockseq;++ // Per 4.1.4 - Convert from unix epoch to Gregorian epoch+ msecs += 12219292800000;++ // `time_low`+ var tl = ((msecs & 0xfffffff) * 10000 + nsecs) % 0x100000000;+ b[i++] = tl >>> 24 & 0xff;+ b[i++] = tl >>> 16 & 0xff;+ b[i++] = tl >>> 8 & 0xff;+ b[i++] = tl & 0xff;++ // `time_mid`+ var tmh = (msecs / 0x100000000 * 10000) & 0xfffffff;+ b[i++] = tmh >>> 8 & 0xff;+ b[i++] = tmh & 0xff;++ // `time_high_and_version`+ b[i++] = tmh >>> 24 & 0xf | 0x10; // include version+ b[i++] = tmh >>> 16 & 0xff;++ // `clock_seq_hi_and_reserved` (Per 4.2.2 - include variant)+ b[i++] = clockseq >>> 8 | 0x80;++ // `clock_seq_low`+ b[i++] = clockseq & 0xff;++ // `node`+ var node = options.node || _nodeId;+ for (var n = 0; n < 6; n++) {+ b[i + n] = node[n];+ }++ return buf ? buf : unparse(b);+}++// **`v4()` - Generate random UUID**++// See https://github.com/broofa/node-uuid for API details+function v4(options, buf, offset) {+ // Deprecated - 'format' argument, as supported in v1.2+ var i = buf && offset || 0;++ if (typeof(options) == 'string') {+ buf = options == 'binary' ? new Array(16) : null;+ options = null;+ }+ options = options || {};++ var rnds = options.random || (options.rng || _rng)();++ // Per 4.4, set bits for version and `clock_seq_hi_and_reserved`+ rnds[6] = (rnds[6] & 0x0f) | 0x40;+ rnds[8] = (rnds[8] & 0x3f) | 0x80;++ // Copy bytes to buffer, if provided+ if (buf) {+ for (var ii = 0; ii < 16; ii++) {+ buf[i + ii] = rnds[ii];+ }+ }++ return buf || unparse(rnds);+}++// Export public API+var uuid = v4;+uuid.v1 = v1;+uuid.v4 = v4;+uuid.parse = parse;+uuid.unparse = unparse;++module.exports = uuid;diff --git a/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/index.js b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/index.jsnew file mode 100644index 000000000..19bcc502e--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/index.js@@ -0,0 +1,51 @@+'use strict';+var fs = require('fs');+var path = require('path');+var mountPoint = require('mount-point');+var userHome = require('user-home');+var xdgBasedir = require('xdg-basedir');+var pify = require('pify');+var Promise = require('pinkie-promise');+var mntPoint = pify(mountPoint);++module.exports = function (file) {+ if (process.platform !== 'linux') {+ return Promise.reject(new Error('Only Linux systems are supported'));+ }++ if (!file) {+ return Promise.resolve(path.join(xdgBasedir.data, 'Trash'));+ }++ return Promise.all([+ mntPoint(userHome),+ mntPoint(file)+ ]).then(function (result) {+ var ret = result[0];+ var res = result[1];++ if (ret.mount === res.mount) {+ return path.join(xdgBasedir.data, 'Trash');+ }++ var top = path.join(res.mount, '.Trash');+ var topuid = top + '-' + process.getuid();+ var stickyBitMode = 17407;++ return pify(fs.lstat)(top)+ .then(function (stats) {+ if (stats.isSymbolicLink() || stats.mode !== stickyBitMode) {+ return topuid;+ }++ return path.join(top, String(process.getuid()));+ })+ .catch(function (err) {+ if (err.code === 'ENOENT') {+ return topuid;+ }++ return path.join(xdgBasedir.data, 'Trash');+ });+ });+};diff --git a/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/license b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/licensenew file mode 100644index 000000000..a8ecbbe94--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/license@@ -0,0 +1,21 @@+The MIT License (MIT)++Copyright (c) Kevin Mårtensson <[email protected]>++Permission is hereby granted, free of charge, to any person obtaining a copy+of this software and associated documentation files (the "Software"), to deal+in the Software without restriction, including without limitation the rights+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell+copies of the Software, and to permit persons to whom the Software is+furnished to do so, subject to the following conditions:++The above copyright notice and this permission notice shall be included in+all copies or substantial portions of the Software.++THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN+THE SOFTWARE.diff --git a/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/.bin/user-home b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/.bin/user-homenew file mode 120000index 000000000..d72d76bb4--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/.bin/user-home@@ -0,0 +1 @@+../user-home/cli.js\ No newline at end of filediff --git a/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/mount-point/index.js b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/mount-point/index.jsnew file mode 100644index 000000000..177fec770--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/mount-point/index.js@@ -0,0 +1,21 @@+'use strict';++var df = require('@sindresorhus/df');++module.exports = function (file, cb) {+ df.file(file, function (err, data) {+ if (err) {+ cb(err);+ return;+ }++ cb(null, {+ fs: data.filesystem,+ size: data.size,+ used: data.used,+ available: data.available,+ percent: data.capacity,+ mount: data.mountpoint+ });+ });+};diff --git a/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/mount-point/license b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/mount-point/licensenew file mode 100644index 000000000..a8ecbbe94--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/mount-point/license@@ -0,0 +1,21 @@+The MIT License (MIT)++Copyright (c) Kevin Mårtensson <[email protected]>++Permission is hereby granted, free of charge, to any person obtaining a copy+of this software and associated documentation files (the "Software"), to deal+in the Software without restriction, including without limitation the rights+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell+copies of the Software, and to permit persons to whom the Software is+furnished to do so, subject to the following conditions:++The above copyright notice and this permission notice shall be included in+all copies or substantial portions of the Software.++THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN+THE SOFTWARE.diff --git a/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/mount-point/node_modules/@sindresorhus/df/index.js b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/mount-point/node_modules/@sindresorhus/df/index.jsnew file mode 100644index 000000000..d4e77bb4e--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/mount-point/node_modules/@sindresorhus/df/index.js@@ -0,0 +1,66 @@+'use strict';+var childProcess = require('child_process');++function run(args, cb) {+ childProcess.execFile('df', args, function (err, stdout) {+ if (err) {+ cb(err);+ return;+ }++ cb(null, stdout.trim().split('\n').slice(1).map(function (el) {+ var cl = el.split(/\s+(?=[\d\/])/);++ return {+ filesystem: cl[0],+ size: parseInt(cl[1], 10) * 1024,+ used: parseInt(cl[2], 10) * 1024,+ available: parseInt(cl[3], 10) * 1024,+ capacity: parseInt(cl[4], 10) / 100,+ mountpoint: cl[5]+ };+ }));+ });+};++var df = module.exports = function (cb) {+ run(['-kP'], cb);+};++df.fs = function (name, cb) {+ if (typeof name !== 'string') {+ throw new Error('name required');+ }++ run(['-kP'], function (err, data) {+ if (err) {+ cb(err);+ return;+ }++ var ret;++ data.forEach(function (el) {+ if (el.filesystem === name) {+ ret = el;+ }+ });++ cb(null, ret);+ });+};++df.file = function (file, cb) {+ if (typeof file !== 'string') {+ throw new Error('file required');+ }++ run(['-kP', file], function (err, data) {+ if (err) {+ cb(err);+ return;+ }++ cb(null, data[0]);+ });+};diff --git a/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/mount-point/node_modules/@sindresorhus/df/license b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/mount-point/node_modules/@sindresorhus/df/licensenew file mode 100644index 000000000..654d0bfe9--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/mount-point/node_modules/@sindresorhus/df/license@@ -0,0 +1,21 @@+The MIT License (MIT)++Copyright (c) Sindre Sorhus <[email protected]> (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.diff --git a/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/mount-point/node_modules/@sindresorhus/df/package.json b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/mount-point/node_modules/@sindresorhus/df/package.jsonnew file mode 100644index 000000000..e291a4adc--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/mount-point/node_modules/@sindresorhus/df/package.json@@ -0,0 +1,71 @@+{+ "name": "@sindresorhus/df",+ "version": "1.0.1",+ "description": "Get free disk space info from `df -kP`",+ "license": "MIT",+ "repository": {+ "type": "git",+ "url": "git+https://github.com/sindresorhus/df.git"+ },+ "author": {+ "name": "Sindre Sorhus",+ "email": "[email protected]",+ "url": "sindresorhus.com"+ },+ "engines": {+ "node": ">=0.10.0"+ },+ "scripts": {+ "test": "node test.js"+ },+ "files": [+ "index.js"+ ],+ "keywords": [+ "df",+ "dfkp",+ "df-kp",+ "disk",+ "space",+ "free",+ "info",+ "data",+ "fs",+ "filesystem",+ "file-system",+ "drive",+ "mount",+ "size",+ "capacity"+ ],+ "devDependencies": {+ "ava": "0.0.4"+ },+ "gitHead": "d08cdc4d48a7cc0a36f01e741118e48549d407ae",+ "bugs": {+ "url": "https://github.com/sindresorhus/df/issues"+ },+ "homepage": "https://github.com/sindresorhus/df#readme",+ "_id": "@sindresorhus/[email protected]",+ "_shasum": "c69b66f52f6fcdd287c807df210305dbaf78500d",+ "_from": "@sindresorhus/df@>=1.0.1 <2.0.0",+ "_npmVersion": "2.9.0",+ "_nodeVersion": "0.10.38",+ "_npmUser": {+ "name": "sindresorhus",+ "email": "[email protected]"+ },+ "dist": {+ "shasum": "c69b66f52f6fcdd287c807df210305dbaf78500d",+ "tarball": "http://registry.npmjs.org/@sindresorhus/df/-/df-1.0.1.tgz"+ },+ "maintainers": [+ {+ "name": "sindresorhus",+ "email": "[email protected]"+ }+ ],+ "directories": {},+ "_resolved": "https://registry.npmjs.org/@sindresorhus/df/-/df-1.0.1.tgz",+ "readme": "ERROR: No README data found!"+}diff --git a/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/mount-point/node_modules/@sindresorhus/df/readme.md b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/mount-point/node_modules/@sindresorhus/df/readme.mdnew file mode 100644index 000000000..d5cef9357--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/mount-point/node_modules/@sindresorhus/df/readme.md@@ -0,0 +1,121 @@+# df [](https://travis-ci.org/sindresorhus/df)++> Get free disk space info from [`df -kP`](http://en.wikipedia.org/wiki/Df_\(Unix\))++Works on any Unix based system like OS X and Linux.++*Created because all the other `df` wrappers are terrible. This one uses simple and explicit parsing. Uses `execFile` rather than `exec`. Ensures better platform portability by using the `-P` flag. Returns sizes in bytes instead of kilobytes and the capacity as a float.*+++## Install++```+$ npm install --save @sindresorhus/df+```+++## Usage++```js+var df = require('@sindresorhus/df');++df(function (err, list) {+ console.log(list);+ /*+ [{+ filesystem: '/dev/disk1',+ size: 499046809600,+ used: 443222245376,+ available: 55562420224,+ capacity: 0.89,+ mountpoint: '/'+ }, ...]+ */+});++df.fs('/dev/disk1', function (err, data) {+ console.log(data);+ /*+ {+ filesystem: '/dev/disk1',+ ...+ }+ */+});++df.file(__dirname, function (err, data) {+ console.log(data);+ /*+ {+ filesystem: '/dev/disk1',+ ...+ }+ */+});+```+++## API++### df(callback)++#### callback(error, list)++*Required*+Type: `function`++##### list++Type: `array`++List of `data` objects.++### df.fs(filesystem, callback)++Get space info for a specific filesystem.++#### filesystem++*Required*+Type: `string`++#### callback(error, data)++*Required*+Type: `function`++##### data++Type: `object`++Data for the specified filesystem:++- `filesystem` - The name of the filesystem.+- `size` - Total size in bytes.+- `used` - Used size in bytes.+- `available` - Available size in bytes.+- `capacity` - Capacity as a float from `0` to `1`.+- `mountpoint` - Disk mount location.++### df.file(file, callback)++Get space info for the filesystem the supplied file is part of.++#### file++*Required*+Type: `string`++#### callback(error, data)++*Required*+Type: `function`++##### data++Same as `df.fs()`.+++## License++MIT © [Sindre Sorhus](http://sindresorhus.com)diff --git a/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/mount-point/package.json b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/mount-point/package.jsonnew file mode 100644index 000000000..898ad7f78--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/mount-point/package.json@@ -0,0 +1,62 @@+{+ "name": "mount-point",+ "version": "1.2.0",+ "description": "Get the mount point for a file",+ "license": "MIT",+ "repository": {+ "type": "git",+ "url": "git+https://github.com/kevva/mount-point.git"+ },+ "author": {+ "name": "Kevin Mårtensson",+ "email": "[email protected]",+ "url": "https://github.com/kevva"+ },+ "engines": {+ "node": ">=0.10.0"+ },+ "scripts": {+ "test": "node test.js"+ },+ "files": [+ "index.js"+ ],+ "keywords": [+ "df",+ "disk",+ "mount"+ ],+ "devDependencies": {+ "ava": "^0.0.4"+ },+ "dependencies": {+ "@sindresorhus/df": "^1.0.1"+ },+ "gitHead": "2aece07b7131e3c9adca52c1ecdf80592e18136a",+ "bugs": {+ "url": "https://github.com/kevva/mount-point/issues"+ },+ "homepage": "https://github.com/kevva/mount-point#readme",+ "_id": "[email protected]",+ "_shasum": "f7712295e1ecd8df2e42ecbe23e07a3660807851",+ "_from": "mount-point@>=1.0.0 <2.0.0",+ "_npmVersion": "2.9.0",+ "_nodeVersion": "1.8.1",+ "_npmUser": {+ "name": "kevva",+ "email": "[email protected]"+ },+ "maintainers": [+ {+ "name": "kevva",+ "email": "[email protected]"+ }+ ],+ "dist": {+ "shasum": "f7712295e1ecd8df2e42ecbe23e07a3660807851",+ "tarball": "http://registry.npmjs.org/mount-point/-/mount-point-1.2.0.tgz"+ },+ "directories": {},+ "_resolved": "https://registry.npmjs.org/mount-point/-/mount-point-1.2.0.tgz",+ "readme": "ERROR: No README data found!"+}diff --git a/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/mount-point/readme.md b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/mount-point/readme.mdnew file mode 100644index 000000000..a7a430af0--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/mount-point/readme.md@@ -0,0 +1,36 @@+# mount-point [](https://travis-ci.org/kevva/mount-point)++> Get the mount point for a file+++## Install++```+$ npm install --save mount-point+```+++## Usage++```js+var mountPoint = require('mount-point');++mountPoint('foo.tar.gz', function (err, data) {+ console.log(data);+ /*+ => {+ fs: /dev/sda2,+ size: 487546976,+ used: 164493356,+ available: 322797620,+ percent: 0.34,+ mount: '/'+ }+ */+});+```+++## License++MIT © [Kevin Mårtensson](https://github.com/kevva)diff --git a/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/user-home/cli.js b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/user-home/cli.jsnew file mode 100644index 000000000..bacbd2275--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/user-home/cli.js@@ -0,0 +1,26 @@+#!/usr/bin/env node+'use strict';+var pkg = require('./package.json');+var userHome = require('./');++function help() {+ console.log([+ pkg.description,+ '',+ 'Example',+ ' $ user-home',+ ' /Users/sindresorhus'+ ].join('\n'));+}++if (process.argv.indexOf('--help') !== -1) {+ help();+ return;+}++if (process.argv.indexOf('--version') !== -1) {+ console.log(pkg.version);+ return;+}++process.stdout.write(userHome);diff --git a/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/user-home/index.js b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/user-home/index.jsnew file mode 100644index 000000000..d53b7939a--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/user-home/index.js@@ -0,0 +1,15 @@+'use strict';+var env = process.env;+var home = env.HOME;+var user = env.LOGNAME || env.USER || env.LNAME || env.USERNAME;++if (process.platform === 'win32') {+ module.exports = env.USERPROFILE || env.HOMEDRIVE + env.HOMEPATH || home || null;+} else if (process.platform === 'darwin') {+ module.exports = home || (user ? '/Users/' + user : null) || null;+} else if (process.platform === 'linux') {+ module.exports = home ||+ (user ? (process.getuid() === 0 ? '/root' : '/home/' + user) : null) || null;+} else {+ module.exports = home || null;+}diff --git a/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/user-home/license b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/user-home/licensenew file mode 100644index 000000000..654d0bfe9--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/user-home/license@@ -0,0 +1,21 @@+The MIT License (MIT)++Copyright (c) Sindre Sorhus <[email protected]> (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.diff --git a/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/user-home/package.json b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/user-home/package.jsonnew file mode 100644index 000000000..c256337db--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/user-home/package.json@@ -0,0 +1,69 @@+{+ "name": "user-home",+ "version": "1.1.1",+ "description": "Get the path to the user home directory",+ "license": "MIT",+ "repository": {+ "type": "git",+ "url": "https://github.com/sindresorhus/user-home"+ },+ "bin": {+ "user-home": "cli.js"+ },+ "author": {+ "name": "Sindre Sorhus",+ "email": "[email protected]",+ "url": "http://sindresorhus.com"+ },+ "engines": {+ "node": ">=0.10.0"+ },+ "scripts": {+ "test": "node test.js"+ },+ "files": [+ "index.js",+ "cli.js"+ ],+ "keywords": [+ "cli",+ "bin",+ "user",+ "home",+ "homedir",+ "dir",+ "directory",+ "folder",+ "path"+ ],+ "devDependencies": {+ "ava": "0.0.3"+ },+ "gitHead": "cf6ba885d3e6bf625fb3c15ad0334fa623968481",+ "bugs": {+ "url": "https://github.com/sindresorhus/user-home/issues"+ },+ "homepage": "https://github.com/sindresorhus/user-home",+ "_id": "[email protected]",+ "_shasum": "2b5be23a32b63a7c9deb8d0f28d485724a3df190",+ "_from": "user-home@>=1.1.0 <2.0.0",+ "_npmVersion": "2.1.16",+ "_nodeVersion": "0.10.32",+ "_npmUser": {+ "name": "sindresorhus",+ "email": "[email protected]"+ },+ "maintainers": [+ {+ "name": "sindresorhus",+ "email": "[email protected]"+ }+ ],+ "dist": {+ "shasum": "2b5be23a32b63a7c9deb8d0f28d485724a3df190",+ "tarball": "http://registry.npmjs.org/user-home/-/user-home-1.1.1.tgz"+ },+ "directories": {},+ "_resolved": "https://registry.npmjs.org/user-home/-/user-home-1.1.1.tgz",+ "readme": "ERROR: No README data found!"+}diff --git a/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/user-home/readme.md b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/user-home/readme.mdnew file mode 100644index 000000000..5307a07ef--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/user-home/readme.md@@ -0,0 +1,42 @@+# user-home [](https://travis-ci.org/sindresorhus/user-home)++> Get the path to the user home directory+++## Install++```sh+$ npm install --save user-home+```+++## Usage++```js+var userHome = require('user-home');++console.log(userHome);+//=> /Users/sindresorhus+```++Returns `null` in the unlikely scenario that the home directory can't be found.+++## CLI++```sh+$ npm install --global user-home+```++```sh+$ user-home --help++Example+ $ user-home+ /Users/sindresorhus+```+++## License++MIT © [Sindre Sorhus](http://sindresorhus.com)diff --git a/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/xdg-basedir/index.js b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/xdg-basedir/index.jsnew file mode 100644index 000000000..cb06b286f--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/xdg-basedir/index.js@@ -0,0 +1,26 @@+'use strict';+var path = require('path');+var userHome = require('user-home');+var env = process.env;++exports.data = env.XDG_DATA_HOME ||+ (userHome ? path.join(userHome, '.local', 'share') : null);++exports.config = env.XDG_CONFIG_HOME ||+ (userHome ? path.join(userHome, '.config') : null);++exports.cache = env.XDG_CONFIG_HOME || (userHome ? path.join(userHome, '.cache') : null);++exports.runtime = env.XDG_RUNTIME_DIR || null;++exports.dataDirs = (env.XDG_DATA_DIRS || '/usr/local/share/:/usr/share/').split(':');++if (exports.data) {+ exports.dataDirs.unshift(exports.data);+}++exports.configDirs = (env.XDG_CONFIG_DIRS || '/etc/xdg').split(':');++if (exports.config) {+ exports.configDirs.unshift(exports.config);+}diff --git a/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/xdg-basedir/license b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/xdg-basedir/licensenew file mode 100644index 000000000..654d0bfe9--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/xdg-basedir/license@@ -0,0 +1,21 @@+The MIT License (MIT)++Copyright (c) Sindre Sorhus <[email protected]> (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.diff --git a/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/xdg-basedir/package.json b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/xdg-basedir/package.jsonnew file mode 100644index 000000000..f112287fc--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/xdg-basedir/package.json@@ -0,0 +1,69 @@+{+ "name": "xdg-basedir",+ "version": "1.0.1",+ "description": "Get XDG Base Directory paths",+ "license": "MIT",+ "repository": {+ "type": "git",+ "url": "https://github.com/sindresorhus/xdg-basedir"+ },+ "author": {+ "name": "Sindre Sorhus",+ "email": "[email protected]",+ "url": "http://sindresorhus.com"+ },+ "engines": {+ "node": ">=0.10.0"+ },+ "scripts": {+ "test": "node test.js"+ },+ "files": [+ "index.js"+ ],+ "keywords": [+ "xdg",+ "base",+ "directory",+ "dir",+ "basedir",+ "path",+ "data",+ "config",+ "cache"+ ],+ "dependencies": {+ "user-home": "^1.0.0"+ },+ "devDependencies": {+ "ava": "0.0.4",+ "require-uncached": "^1.0.2"+ },+ "gitHead": "2eaf176e5d0c9c1bd64e6fc8a60a3a8e3dba4e79",+ "bugs": {+ "url": "https://github.com/sindresorhus/xdg-basedir/issues"+ },+ "homepage": "https://github.com/sindresorhus/xdg-basedir",+ "_id": "[email protected]",+ "_shasum": "14ff8f63a4fdbcb05d5b6eea22b36f3033b9f04e",+ "_from": "xdg-basedir@>=1.0.0 <2.0.0",+ "_npmVersion": "2.1.16",+ "_nodeVersion": "0.10.32",+ "_npmUser": {+ "name": "sindresorhus",+ "email": "[email protected]"+ },+ "maintainers": [+ {+ "name": "sindresorhus",+ "email": "[email protected]"+ }+ ],+ "dist": {+ "shasum": "14ff8f63a4fdbcb05d5b6eea22b36f3033b9f04e",+ "tarball": "http://registry.npmjs.org/xdg-basedir/-/xdg-basedir-1.0.1.tgz"+ },+ "directories": {},+ "_resolved": "https://registry.npmjs.org/xdg-basedir/-/xdg-basedir-1.0.1.tgz",+ "readme": "ERROR: No README data found!"+}diff --git a/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/xdg-basedir/readme.md b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/xdg-basedir/readme.mdnew file mode 100644index 000000000..af3a8ba35--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/node_modules/xdg-basedir/readme.md@@ -0,0 +1,60 @@+# xdg-basedir [](https://travis-ci.org/sindresorhus/xdg-basedir)++> Get [XDG Base Directory](http://standards.freedesktop.org/basedir-spec/basedir-spec-latest.html) paths+++## Install++```sh+$ npm install --save xdg-basedir+```+++## Usage++```js+var xdgBasedir = require('xdg-basedir');++xdgBasedir.data;+//=> /home/sindresorhus/.local/share++xdgBasedir.config;+//=> /home/sindresorhus/.config++xdgBasedir.dataDirs+//=> ['/home/sindresorhus/.local/share', '/usr/local/share/', '/usr/share/']+```+++## API++The properties `.data`, `.config`, `.cache`, `.runtime` will return `null` in the uncommon case that both the XDG environment variable is not set and the users home directory can't be found. You need to handle this case. A common solution is to [fall back to a temp directory](https://github.com/yeoman/configstore/blob/b82690fc401318ad18dcd7d151a0003a4898a314/index.js#L15).++### .data++Directory for user specific data files.++### .config++Directory for user specific configuration files.++### .cache++Directory for user specific non-essential data files.++### .runtime++Directory for user-specific non-essential runtime files and other file objects (such as sockets, named pipes, etc).++### .dataDirs++Preference-ordered array of base directories to search for data files in addition to `.data`.++### .configDirs++Preference-ordered array of base directories to search for configuration files in addition to `.config`.+++## License++MIT © [Sindre Sorhus](http://sindresorhus.com)diff --git a/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/package.json b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/package.jsonnew file mode 100644index 000000000..dc474a38c--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/package.json@@ -0,0 +1,79 @@+{+ "name": "xdg-trashdir",+ "version": "2.0.0",+ "description": "Get the correct trash path on Linux",+ "license": "MIT",+ "repository": {+ "type": "git",+ "url": "git+https://github.com/kevva/xdg-trashdir.git"+ },+ "author": {+ "name": "Kevin Mårtensson",+ "email": "[email protected]",+ "url": "https://github.com/kevva"+ },+ "engines": {+ "node": ">=0.10.0"+ },+ "scripts": {+ "test": "xo && ava"+ },+ "files": [+ "index.js"+ ],+ "keywords": [+ "dir",+ "file",+ "linux",+ "recycle",+ "trash",+ "xdg"+ ],+ "dependencies": {+ "mount-point": "^1.0.0",+ "pify": "^2.2.0",+ "pinkie-promise": "^1.0.0",+ "user-home": "^1.1.0",+ "xdg-basedir": "^1.0.0"+ },+ "devDependencies": {+ "xo": "*",+ "ava": "*"+ },+ "xo": {+ "ignore": [+ "test/test.js"+ ]+ },+ "gitHead": "345387560a38dafb5aaddadba6cbfa7d2b3620a6",+ "bugs": {+ "url": "https://github.com/kevva/xdg-trashdir/issues"+ },+ "homepage": "https://github.com/kevva/xdg-trashdir#readme",+ "_id": "[email protected]",+ "_shasum": "169b958392099f1cbdcd1b53e8bddf145be35646",+ "_from": "xdg-trashdir@>=2.0.0 <3.0.0",+ "_npmVersion": "3.3.3",+ "_nodeVersion": "4.1.0",+ "_npmUser": {+ "name": "kevva",+ "email": "[email protected]"+ },+ "dist": {+ "shasum": "169b958392099f1cbdcd1b53e8bddf145be35646",+ "tarball": "http://registry.npmjs.org/xdg-trashdir/-/xdg-trashdir-2.0.0.tgz"+ },+ "maintainers": [+ {+ "name": "kevva",+ "email": "[email protected]"+ },+ {+ "name": "sindresorhus",+ "email": "[email protected]"+ }+ ],+ "directories": {},+ "_resolved": "https://registry.npmjs.org/xdg-trashdir/-/xdg-trashdir-2.0.0.tgz",+ "readme": "ERROR: No README data found!"+}diff --git a/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/readme.md b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/readme.mdnew file mode 100644index 000000000..d49da1fed--- /dev/null+++ b/data/node-webkit/node_modules/trash/node_modules/xdg-trashdir/readme.md@@ -0,0 +1,45 @@+# xdg-trashdir [](https://travis-ci.org/kevva/xdg-trashdir)++> Get the correct trash path on Linux according to the [spec](http://www.ramendik.ru/docs/trashspec.html)+++## Install++```+$ npm install --save xdg-trashdir+```+++## Usage++```js+const xdgTrashdir = require('xdg-trashdir');++xdgTrashdir().then(dir => {+ console.log(dir);+ //=> /home/johndoe/.local/share/Trash+});++xdgTrashdir('foo.zip').then(dir => {+ console.log(dir);+ //=> /media/johndoe/UUI/.Trash-1000+});+```+++## API++### xdgTrashdir([file])++Returns a promise that resolves the path to the trash.++#### file++Type: `string`++Get the trash path for a specific file.+++## License++MIT © [Kevin Mårtensson](https://github.com/kevva)diff --git a/data/node-webkit/node_modules/trash/package.json b/data/node-webkit/node_modules/trash/package.jsonnew file mode 100644index 000000000..e269896ff--- /dev/null+++ b/data/node-webkit/node_modules/trash/package.json@@ -0,0 +1,94 @@+{+ "name": "trash",+ "version": "3.1.2",+ "description": "Move files and folders to the trash",+ "license": "MIT",+ "repository": {+ "type": "git",+ "url": "https://github.com/sindresorhus/trash"+ },+ "author": {+ "name": "Sindre Sorhus",+ "email": "[email protected]",+ "url": "sindresorhus.com"+ },+ "engines": {+ "node": ">=0.10.0"+ },+ "scripts": {+ "test": "xo && ava"+ },+ "files": [+ "index.js",+ "lib"+ ],+ "keywords": [+ "trash",+ "recycle",+ "bin",+ "rm",+ "rmrf",+ "rimraf",+ "remove",+ "delete",+ "del",+ "file",+ "files",+ "dir",+ "directory",+ "directories",+ "folder",+ "folders",+ "xdg"+ ],+ "dependencies": {+ "escape-string-applescript": "^1.0.0",+ "fs-extra": "^0.24.0",+ "path-exists": "^2.0.0",+ "pify": "^2.2.0",+ "pinkie-promise": "^1.0.0",+ "run-applescript": "^2.0.0",+ "uuid": "^2.0.1",+ "xdg-trashdir": "^2.0.0"+ },+ "devDependencies": {+ "ava": "*",+ "tempfile": "^1.1.1",+ "xo": "*"+ },+ "xo": {+ "ignore": [+ "test.js"+ ]+ },+ "gitHead": "13fd3b8b573d6b75573866de612298c60e3a0ab4",+ "bugs": {+ "url": "https://github.com/sindresorhus/trash/issues"+ },+ "homepage": "https://github.com/sindresorhus/trash",+ "_id": "[email protected]",+ "_shasum": "9b735cf0e5b215c08b67df892671012240f3cd7f",+ "_from": "[email protected]",+ "_npmVersion": "2.14.7",+ "_nodeVersion": "4.2.1",+ "_npmUser": {+ "name": "sindresorhus",+ "email": "[email protected]"+ },+ "dist": {+ "shasum": "9b735cf0e5b215c08b67df892671012240f3cd7f",+ "tarball": "http://registry.npmjs.org/trash/-/trash-3.1.2.tgz"+ },+ "maintainers": [+ {+ "name": "sindresorhus",+ "email": "[email protected]"+ },+ {+ "name": "kevva",+ "email": "[email protected]"+ }+ ],+ "directories": {},+ "_resolved": "https://registry.npmjs.org/trash/-/trash-3.1.2.tgz"+}diff --git a/data/node-webkit/node_modules/trash/readme.md b/data/node-webkit/node_modules/trash/readme.mdnew file mode 100644index 000000000..df382f299--- /dev/null+++ b/data/node-webkit/node_modules/trash/readme.md@@ -0,0 +1,53 @@+# ++> Move files and folders to the trash++[](https://travis-ci.org/sindresorhus/trash)++Works on OS X, Linux, and Windows.++In contrast to [`fs.unlink`](https://nodejs.org/api/fs.html#fs_fs_unlink_path_callback), [`del`](https://github.com/sindresorhus/del), and [`rimraf`](https://github.com/isaacs/rimraf) which permanently delete files, this only moves them to the trash, which is much safer and reversible.+++## Install++```+$ npm install --save trash+```+++## Usage++```js+const trash = require('trash');++trash(['unicorn.png', 'rainbow.png']).then(() => {+ console.log('done');+});+```+++## Info++On OS X, [`osx-trash`](https://github.com/sindresorhus/osx-trash) is used.+On Linux, the [XDG spec](http://standards.freedesktop.org/trash-spec/trashspec-1.0.html) is followed.+On Windows, [`recycle-bin`](https://github.com/sindresorhus/recycle-bin) is used.+++## FAQ++### But I can do the same thing with `mv`++Not really. The `mv` command isn't cross-platform and moving to trash is not just about moving the file to a "trash" directory. On all OSes you'll run into file conflicts. The user won't easily be able to restore the file. It won't work on an external drive. The trash directory location varies between Windows versions. For Linux, there's a whole [spec](http://www.ramendik.ru/docs/trashspec.html) you need to follow. On OS X, you'll lose the [Put back](http://mac-fusion.com/trash-tip-how-to-put-files-back-to-their-original-location/) feature.+++## Related++- [trash-cli](https://github.com/sindresorhus/trash-cli) - CLI for this module+- [empty-trash](https://github.com/sindresorhus/empty-trash) - Empty the trash+- [del](https://github.com/sindresorhus/del) - Delete files and folders using globs+++## License++MIT © [Sindre Sorhus](http://sindresorhus.com)