pidof
Get PID of a running process
Last updated 14 years ago .
Repository · Original npm · Tarball · package.json
$ cnpm install pidof 
SYNC missed versions from official npm registry.

pidof

build status

Get the PID of a running process, or null if it couldn't be found.

Example

var pidof = require('pidof');

pidof('cron', function (err, pid) {
    if (err) {
        console.log('Weird error getting PIDs');
        console.log(err);
    } else {
        if (pid) {
            console.log('Found cron at pid ' + pid);
        } else {
            console.log('Seems like there\'s no cron on this system');
        }
    }
});

Current Tags

  • 1.0.2                                ...           latest (14 years ago)

3 Versions

  • 1.0.2                                ...           14 years ago
  • 1.0.1                                ...           14 years ago
  • 1.0.0                                ...           14 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 2
Last Day 0
Last Week 2
Last Month 1
Dependencies (0)
None
Dev Dependencies (2)
Dependents (1)

Copyright 2013 - present © cnpmjs.org | Home |