pid-comm
Returns the result of running ps -ax -o pid -o comm
.
In Node.js:
npm install pid-comm
As a command line tool:
npm install -g pid-comm
The pid-comm
command is now available in your command line.
Usage
Node.js
const ps =// [// {// pid: 42,// comm: "life"// }// ]
CLI
pid-comm
Writes JSON to stdout with the following structure:
"pid": 42"comm": "life"