You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
wufayuan
888089ca40
|
3 years ago | |
---|---|---|
.. | ||
example | 3 years ago | |
.npmignore | 3 years ago | |
LICENCE | 3 years ago | |
README.md | 3 years ago | |
index.js | 3 years ago | |
package.json | 3 years ago |
README.md
execute
Execute commands in parallel
Example
var execute = require("execute")
, readFile = require("fs").readFile
, join = require("path").join
, request = require("request")
, equal = require("assert").equal
, link = "https://raw.github.com/Colingo/execute" +
"/master/README.md"
execute({
file: function (callback) {
readFile(join(__dirname, "..", "README.md"), callback)
}
, readme: function (callback) {
request(link, function (err, res, body) {
callback(err, body)
})
}
}, function (err, results) {
var file = String(results.file)
, readme = String(results.readme)
equal(file, readme)
console.log("done")
})
Installation
npm install execute
Contributors
- Raynos