diff options
author | 2020-11-18 23:26:45 +0100 | |
---|---|---|
committer | 2020-11-18 23:26:45 +0100 | |
commit | 81ddf9b700bc48a1f8e472209f080f9c1d9a9b09 (patch) | |
tree | 8b959d50c5a614cbf9fcb346ed556140374d4b6d /node_modules/pidtree/lib/get.js | |
parent | 1870f3fdf43707a15fda0f609a021f516f45eb63 (diff) | |
download | website_creator-81ddf9b700bc48a1f8e472209f080f9c1d9a9b09.tar.gz website_creator-81ddf9b700bc48a1f8e472209f080f9c1d9a9b09.tar.bz2 website_creator-81ddf9b700bc48a1f8e472209f080f9c1d9a9b09.zip |
rm node_modules
Diffstat (limited to 'node_modules/pidtree/lib/get.js')
-rw-r--r-- | node_modules/pidtree/lib/get.js | 40 |
1 files changed, 0 insertions, 40 deletions
diff --git a/node_modules/pidtree/lib/get.js b/node_modules/pidtree/lib/get.js deleted file mode 100644 index 1793d54..0000000 --- a/node_modules/pidtree/lib/get.js +++ /dev/null @@ -1,40 +0,0 @@ -'use strict'; - -var os = require('os'); - -var platformToMethod = { - darwin: 'ps', - sunos: 'ps', - freebsd: 'ps', - netbsd: 'ps', - win: 'wmic', - linux: 'ps', - aix: 'ps' -}; - -var platform = os.platform(); -if (platform.startsWith('win')) { - platform = 'win'; -} - -var file = platformToMethod[platform]; - -/** - * Gets the list of all the pids of the system. - * @param {Function} callback Called when the list is ready. - */ -function get(callback) { - if (file === undefined) { - callback( - new Error( - os.platform() + - ' is not supported yet, please open an issue (https://github.com/simonepri/pidtree)' - ) - ); - } - - var list = require('./' + file); - list(callback); -} - -module.exports = get; |