Skip to content

ecasilla/remove-ps-dir

Repository files navigation

remove-ps-dir NPM version Build Status Dependency Status Coverage percentage

A module to remove directory's that are named after their process id.
I created this module while needing a clean way for the clustered node processes to have a dedicated directory, but also have some clean up happen once they died.

Install

$ npm install --save remove-ps-dir

Usage

var ps = require('remove-ps-dir');

// A valid path to a folder I want to remove dead
// workers usually a temp folder
ps.remove('/tmp', function(err,removedPaths){
  if (err) {
    return err;
  }
});

License

MIT © Ernie Casilla

About

A npm module to remove unused directory made by worker processes

Resources

License

Stars

Watchers

Forks

Packages

No packages published