{"name":"did_it_work","version":"0.0.2","description":"A simple process launcher that determines whether the process succeeded or failed.","main":"index.js","scripts":{"test":"mocha -u tdd tests.js"},"repository":"","author":{"name":"Toby Ho"},"license":"MIT","dependencies":{},"devDependencies":{"chai":"~1.5.0"},"readme":"Did It Work?\n============\n\n***Did it Work?***: A simple process launcher that determines whether the process succeeded or failed.\n\nInstall\n-------\n\n    npm install did_it_work\n\nUsage\n-----\n\n    var process = require('did_it_work');\n\n    process('my_awesome_program')\n      .goodIfMatches(/Ready/, 1000)\n      .badIfMatches(/Error/)\n      .good(function(){\n        console.log('The program worked (because it spat out \"Ready\" to stdout within 1000ms).')\n      })\n      .bad(function(){\n        console.log('The program didn\\'t work (because it spat out \"Error\" to stdout, or the program exited with non-zero code, or it didn\\'t spit out \"Ready\" within 1000ms)')\n      })\n      .complete(function(){\n        console.log('In any case, the program exited')\n      })\n\nUse `spawn` instead of `exec`\n-----------------------------\n\nIf you pass one string argument to the function, it will use `child_process.exec` to create the process. If, on the other hand, you need to use `child_process.spawn`, pass two arguments instead, the first being the executable and the second being an array of arguments. Example\n\n    process('echo', ['hello', 'world'])\n      .complete(function(stdout){\n        console.log('The program returned ' + stdout)\n      })\n\nRTFT\n----\n\nTo see more, read the tests in `tests.js`.","readmeFilename":"README.md","_id":"did_it_work@0.0.2","dist":{"shasum":"9d4b133af6dd17bf86750e51a2b7e9d6755c8589","tarball":"http://registry-npm.ywwl.com/did_it_work/download/did_it_work-0.0.2.tgz","integrity":"sha512-t2/7byz84KorQ0OthmCWmc9SaC82sR2v/afmyWuTB8uXe1S0q41ykFfrAg0o68Zrcj4nFiaG29ExNmwBDAR0gQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQC5ufOrKMJ9eRVsX5+gdwUUAVgR+LUl/Nqb+N2r7eJC2wIgcCbx1Ucw8H4TAfpZ43JGIPvk0WAiTfLMcGYNCbrQDzM="}],"size":2677,"noattachment":false,"key":"/did_it_work/-/did_it_work-0.0.2.tgz"},"_from":".","_npmVersion":"1.2.14","_npmUser":{"name":"airportyh","email":"airportyh@gmail.com"},"maintainers":[{"name":"airportyh","email":"airportyh@gmail.com"}],"publish_time":1367219441838,"_cnpm_publish_time":1367219441838,"dist-tags":{"latest":"0.0.6"}}