1.0.0 • Published 9 years ago
jsps v1.0.0
jsps
JavaScript binding to ps.
npm install jsps
Usage
var ps = require('jsps')
var options = {
pid: process.pid, // if undefined, process.pid is used
keywords: ['%cpu', '%mem'] // man ps for the list of keywords
}
ps.lookup(options, function(err, result) {
console.log(err || result)
})
{"%cpu": "44.7", "%mem": "0.4"}
Test
npm install -g standard
npm test
1.0.0
9 years ago