first commit
This commit is contained in:
22
build/node_modules/process/LICENSE
generated
vendored
Normal file
22
build/node_modules/process/LICENSE
generated
vendored
Normal file
@@ -0,0 +1,22 @@
|
||||
(The MIT License)
|
||||
|
||||
Copyright (c) 2013 Roman Shtylman <shtylman@gmail.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.
|
||||
15
build/node_modules/process/README.md
generated
vendored
Normal file
15
build/node_modules/process/README.md
generated
vendored
Normal file
@@ -0,0 +1,15 @@
|
||||
# process
|
||||
|
||||
```require('process');``` just like any other module.
|
||||
|
||||
Works in node.js and browsers via the browser.js shim provided with the module.
|
||||
|
||||
## package manager notes
|
||||
|
||||
If you are writing a bundler to package modules for client side use, make sure you use the ```browser``` field hint in package.json.
|
||||
|
||||
See https://gist.github.com/4339901 for details.
|
||||
|
||||
The [browserify](https://github.com/substack/node-browserify) module will properly handle this field when bundling your files.
|
||||
|
||||
|
||||
53
build/node_modules/process/browser.js
generated
vendored
Normal file
53
build/node_modules/process/browser.js
generated
vendored
Normal file
@@ -0,0 +1,53 @@
|
||||
// shim for using process in browser
|
||||
|
||||
var process = module.exports = {};
|
||||
|
||||
process.nextTick = (function () {
|
||||
var canSetImmediate = typeof window !== 'undefined'
|
||||
&& window.setImmediate;
|
||||
var canPost = typeof window !== 'undefined'
|
||||
&& window.postMessage && window.addEventListener
|
||||
;
|
||||
|
||||
if (canSetImmediate) {
|
||||
return function (f) { return window.setImmediate(f) };
|
||||
}
|
||||
|
||||
if (canPost) {
|
||||
var queue = [];
|
||||
window.addEventListener('message', function (ev) {
|
||||
var source = ev.source;
|
||||
if ((source === window || source === null) && ev.data === 'process-tick') {
|
||||
ev.stopPropagation();
|
||||
if (queue.length > 0) {
|
||||
var fn = queue.shift();
|
||||
fn();
|
||||
}
|
||||
}
|
||||
}, true);
|
||||
|
||||
return function nextTick(fn) {
|
||||
queue.push(fn);
|
||||
window.postMessage('process-tick', '*');
|
||||
};
|
||||
}
|
||||
|
||||
return function nextTick(fn) {
|
||||
setTimeout(fn, 0);
|
||||
};
|
||||
})();
|
||||
|
||||
process.title = 'browser';
|
||||
process.browser = true;
|
||||
process.env = {};
|
||||
process.argv = [];
|
||||
|
||||
process.binding = function (name) {
|
||||
throw new Error('process.binding is not supported');
|
||||
}
|
||||
|
||||
// TODO(shtylman)
|
||||
process.cwd = function () { return '/' };
|
||||
process.chdir = function (dir) {
|
||||
throw new Error('process.chdir is not supported');
|
||||
};
|
||||
2
build/node_modules/process/index.js
generated
vendored
Normal file
2
build/node_modules/process/index.js
generated
vendored
Normal file
@@ -0,0 +1,2 @@
|
||||
// for now just expose the builtin process global from node.js
|
||||
module.exports = global.process;
|
||||
53
build/node_modules/process/package.json
generated
vendored
Normal file
53
build/node_modules/process/package.json
generated
vendored
Normal file
@@ -0,0 +1,53 @@
|
||||
{
|
||||
"_args": [
|
||||
[
|
||||
"process@0.5.2",
|
||||
"/Users/asciidisco/Desktop/asciidisco.com/build"
|
||||
]
|
||||
],
|
||||
"_from": "process@0.5.2",
|
||||
"_id": "process@0.5.2",
|
||||
"_inBundle": false,
|
||||
"_integrity": "sha1-FjjYqONML0QKkduVq5rrZ3/Bhc8=",
|
||||
"_location": "/process",
|
||||
"_phantomChildren": {},
|
||||
"_requested": {
|
||||
"type": "version",
|
||||
"registry": true,
|
||||
"raw": "process@0.5.2",
|
||||
"name": "process",
|
||||
"escapedName": "process",
|
||||
"rawSpec": "0.5.2",
|
||||
"saveSpec": null,
|
||||
"fetchSpec": "0.5.2"
|
||||
},
|
||||
"_requiredBy": [
|
||||
"/global"
|
||||
],
|
||||
"_resolved": "https://registry.npmjs.org/process/-/process-0.5.2.tgz",
|
||||
"_spec": "0.5.2",
|
||||
"_where": "/Users/asciidisco/Desktop/asciidisco.com/build",
|
||||
"author": {
|
||||
"name": "Roman Shtylman",
|
||||
"email": "shtylman@gmail.com"
|
||||
},
|
||||
"browser": "./browser.js",
|
||||
"bugs": {
|
||||
"url": "https://github.com/shtylman/node-process/issues"
|
||||
},
|
||||
"description": "process information for node.js and browsers",
|
||||
"engines": {
|
||||
"node": ">= 0.6.0"
|
||||
},
|
||||
"homepage": "https://github.com/shtylman/node-process#readme",
|
||||
"keywords": [
|
||||
"process"
|
||||
],
|
||||
"main": "./index.js",
|
||||
"name": "process",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "git://github.com/shtylman/node-process.git"
|
||||
},
|
||||
"version": "0.5.2"
|
||||
}
|
||||
Reference in New Issue
Block a user