
Security News
Deno 2.2 Improves Dependency Management and Expands Node.js Compatibility
Deno 2.2 enhances Node.js compatibility, improves dependency management, adds OpenTelemetry support, and expands linting and task automation for developers.
Show a process output with debug utility.
npm install debug-proc
Running node with the appropriate environment vars (DEBUG=proc
in this example):
var debugProc = require('debug-proc')('proc');
var proc = spawn('./script.sh', ['abc', 123]);
debugProc(proc);
/*
proc ./script.sh abc 123 +0ms
proc stdout message 1 +10ms
proc stderr message 1 +3ms
proc stdout message 2 +46ms
proc stderr message 2 +1ms
*/
// the process spawn args, stderr and stdout can be disabled
debugProc(proc, {spawnargs: false, stdout: false});
/*
proc stderr message 1 +3ms
proc stderr message 2 +1ms
*/
debugProc(proc, {decorate: 'name'});
/*
proc ./script.sh: ./script.sh abc 123 +0ms
proc ./script.sh: stdout message 1 +10ms
proc ./script.sh: stderr message 1 +3ms
proc ./script.sh: stdout message 2 +46ms
proc ./script.sh: stderr message 2 +1ms
*/
debugProc(proc, {decorate: 'pid'});
/*
proc pid 10425: ./script.sh abc 123 +0ms
proc pid 10425: stdout message 1 +10ms
proc pid 10425: stderr message 1 +3ms
proc pid 10425: stdout message 2 +46ms
proc pid 10425: stderr message 2 +1ms
*/
debugProc(proc, {
decorate: function(proc) {
return 'process-description: ';
}
});
/*
proc process-description: ./script.sh abc 123 +0ms
proc process-description: stdout message 1 +10ms
proc process-description: stderr message 1 +3ms
proc process-description: stdout message 2 +46ms
proc process-description: stderr message 2 +1ms
*/
cd examples/
DEBUG=proc node example.js
MIT license - http://www.opensource.org/licenses/mit-license.php
FAQs
Show a process output with `debug` utility
The npm package debug-proc receives a total of 1 weekly downloads. As such, debug-proc popularity was classified as not popular.
We found that debug-proc demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Deno 2.2 enhances Node.js compatibility, improves dependency management, adds OpenTelemetry support, and expands linting and task automation for developers.
Security News
React's CRA deprecation announcement sparked community criticism over framework recommendations, leading to quick updates acknowledging build tools like Vite as valid alternatives.
Security News
Ransomware payment rates hit an all-time low in 2024 as law enforcement crackdowns, stronger defenses, and shifting policies make attacks riskier and less profitable.