In order to have a consistent look and feel, we should have an abstraction API for logging to the console for CLI commands. The API should provide a set of semantic functions that allow for a consistent look and feel (but also make it easy to maintain, test, etc.).
Also, in lots of places we log to console.log() but in some cases we have to write to stdout. I would say for CLI commands, we should generally manage writing to any WritableStream (but defaulting to process.stdout).
Enhancement
Related to #133
In order to have a consistent look and feel, we should have an abstraction API for logging to the console for CLI commands. The API should provide a set of semantic functions that allow for a consistent look and feel (but also make it easy to maintain, test, etc.).
For example, we could have something like:
Also, in lots of places we log to
console.log()
but in some cases we have to write tostdout
. I would say for CLI commands, we should generally manage writing to anyWritableStream
(but defaulting toprocess.stdout
).