Skip to content

Commit

Permalink
Make default and info message log messages use terminal default colors
Browse files Browse the repository at this point in the history
Previously, we set the color to white, which is (nearly) invisible on
terminals with a white background.

Fixes angular#13439.
  • Loading branch information
mikelward committed Jan 15, 2019
1 parent 8863bc0 commit a00a6d0
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions packages/angular_devkit/core/node/cli-logger.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,19 +25,19 @@ export function createConsoleLogger(
logger
.pipe(filter(entry => (entry.level != 'debug' || verbose)))
.subscribe(entry => {
let color: (s: string) => string = x => terminal.dim(terminal.white(x));
let color = terminal.dim;
let output = stdout;
switch (entry.level) {
case 'info':
color = terminal.white;
color = terminal.reset;
break;
case 'warn':
color = (x: string) => terminal.bold(terminal.yellow(x));
color = (s: string) => terminal.bold(terminal.yellow(s));
output = stderr;
break;
case 'fatal':
case 'error':
color = (x: string) => terminal.bold(terminal.red(x));
color = (s: string) => terminal.bold(terminal.red(s));
output = stderr;
break;
}
Expand Down

0 comments on commit a00a6d0

Please sign in to comment.