This changes a bunch of commands to use the new output.buffer capabilities from proc-log as well as the outputError helper from utils/output-error.js.
This also adds a few comments about future display related breaking changes that npm should make.
There is some new behavior around run-script and how it outputs errors. It now displays the error for each workspace similar to how that error would get displayed when the process exits.
Here are some screenshots of the new run-script output to show with coloring. These are all represented in snapshots as well both those can be hard to decipher with ansi codes. The screenshots are run via set -x; npm $@; npmlocal $@ so the output preceded with + npm is just to show the command being run.
Running a non-existent command from multiple workspaces
Running a script that errors from multiple workspaces
Listing scripts
The only change here is I removed the newline between lifecycle scripts and run scripts. I find the indent shows the hierarchy of information and the extra newline made it difficult to quickly scan multiple workspaces which are also separated by newlines.
This changes a bunch of commands to use the new
output.buffer
capabilities fromproc-log
as well as theoutputError
helper fromutils/output-error.js
.This also adds a few comments about future display related breaking changes that npm should make.
There is some new behavior around
run-script
and how it outputs errors. It now displays the error for each workspace similar to how that error would get displayed when the process exits.Here are some screenshots of the new
run-script
output to show with coloring. These are all represented in snapshots as well both those can be hard to decipher with ansi codes. The screenshots are run viaset -x; npm $@; npmlocal $@
so the output preceded with+ npm
is just to show the command being run.Running a non-existent command from multiple workspaces
Running a script that errors from multiple workspaces
Listing scripts
The only change here is I removed the newline between lifecycle scripts and run scripts. I find the indent shows the hierarchy of information and the extra newline made it difficult to quickly scan multiple workspaces which are also separated by newlines.