Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor(@embark/core): refactor logger to provide correct origins
Also make a few more revisions: Revise the "write logs" testing strategy such that it's not necessary for the logger functions to take an optional callback. Drop unused `tmp` package from `packages/core/logger` since it's not used in the tests. Strip colors before writing to the log file, use a two-space delimiter between sections of each logged line in the log file, and collapse whitespace in the message section of each line. These changes make the log file more amenable to being processed with cli tools such as awk, cut, etc. It's also possible in a text editor to replace `' '` with `\t` and then load the file in a spreadsheet, with each line-section in its own column. Rearrange the sections of each logged line so that it's easier to read, and only include the origin if the loglevel is debug or trace.
- Loading branch information
1 parent
eb8d757
commit 2a5abe7
Showing
4 changed files
with
153 additions
and
99 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.