mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2025-10-16 12:05:41 +00:00
20 lines
369 B
TypeScript
20 lines
369 B
TypeScript
|
|
/// <reference types="node" />
|
|
|
|
import usage = require('usage');
|
|
|
|
var pid = process.pid;
|
|
var options = { keepHistory: true };
|
|
|
|
usage.lookup(pid, function(err, result) {
|
|
console.log("Usage infos", result);
|
|
});
|
|
|
|
usage.lookup(pid, options, function (err, result) {
|
|
console.log("Usage infos with history", result);
|
|
});
|
|
|
|
usage.clearHistory(pid);
|
|
usage.clearHistory();
|
|
|