Skip to content

Commit d54f4ae

Browse files
authored
fix(logger): pass colors=true to debug module (#30)
this prevents the debug module from prefixing a date string to log messages in tty
1 parent f33ea81 commit d54f4ae

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/lighthouse.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@ const getBrowserPath = async () => {
1616
const runLighthouse = async (browserPath, url) => {
1717
let chrome;
1818
try {
19+
// prevent logger from prefixing a date when running in tty
20+
require('debug').inspectOpts.colors = true;
1921
const logLevel = 'info';
2022
log.setLevel(logLevel);
2123
chrome = await chromeLauncher.launch({

0 commit comments

Comments
 (0)