forked from DebaucheryLibrarian/traxxx
Improved and re-enabled why-is-node-running logger.
This commit is contained in:
parent
cdb7dcd6e9
commit
1c0c30be11
|
@ -1,7 +1,7 @@
|
|||
'use strict';
|
||||
|
||||
const util = require('util');
|
||||
// const log = require('why-is-node-running');
|
||||
const log = require('why-is-node-running');
|
||||
const Inspector = require('inspector-api');
|
||||
const fs = require('fs').promises;
|
||||
const dayjs = require('dayjs');
|
||||
|
@ -25,11 +25,12 @@ const inspector = new Inspector();
|
|||
let done = false;
|
||||
|
||||
function logActive() {
|
||||
console.log('log active!');
|
||||
|
||||
setTimeout(() => {
|
||||
// log();
|
||||
log();
|
||||
|
||||
if (!done) {
|
||||
logActive();
|
||||
}
|
||||
}, typeof argv.logActive === 'number' ? argv.logActive : 60000);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue