Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add colors flag to infrastructureLogging #13051

Merged
merged 6 commits into from Apr 6, 2021

Conversation

KENNYSOFT
Copy link
Contributor

@KENNYSOFT KENNYSOFT commented Apr 4, 2021

Fixes #12899

Since it's my first try of contribution to webpack, even if I looked carefully for impacted default values etc, there can exists some missed parts. Please review carefully for me to fix things. Thanks!

What kind of change does this PR introduce?

feature

Did you add tests for your changes?

Yes

Does this PR introduce a breaking change?

No

What needs to be documented once your changes are merged?

  • infrastructureLogging.colors Enables/Disables colorful output.
  • infrastructureLogging.appendOnly Only appends lines to the output. Avoids updating existing output e. g. for status messages.
  • infrastructureLogging.stream Stream used for logging output. Defaults to process.stderr.
  • infrastructureLogging.console Custom console used for logging.
  • When stream is an TTY colors is enabled and appendOnly is disabled. Otherwise it's flipped.

@webpack-bot
Copy link
Contributor

webpack-bot commented Apr 4, 2021

For maintainers only:

  • This needs to be documented (issue in webpack/webpack.js.org will be filed when merged)
  • This needs to be backported to webpack 4 (issue will be created when merged)

@KENNYSOFT
Copy link
Contributor Author

Omg I'm fixing lints

@KENNYSOFT KENNYSOFT marked this pull request as draft April 4, 2021 04:54
@KENNYSOFT KENNYSOFT force-pushed the infrastructurelogging-colors branch from 76137ee to 34b00b3 Compare April 4, 2021 05:03
@KENNYSOFT KENNYSOFT marked this pull request as ready for review April 4, 2021 05:04
@KENNYSOFT KENNYSOFT force-pushed the infrastructurelogging-colors branch from 34b00b3 to 1f45499 Compare April 4, 2021 05:10
@KENNYSOFT KENNYSOFT force-pushed the infrastructurelogging-colors branch from 1f45499 to 72ba68c Compare April 4, 2021 05:28
@webpack-bot
Copy link
Contributor

Thank you for your pull request! The most important CI builds succeeded, we’ll review the pull request soon.

add appendOnly flag
add custom console
add custom stream
@webpack-bot
Copy link
Contributor

@KENNYSOFT Thanks for your update.

I labeled the Pull Request so reviewers will review it again.

@sokra Please review the new changes.

@sokra
Copy link
Member

sokra commented Apr 6, 2021

Thanks

@webpack-bot
Copy link
Contributor

I've created an issue to document this in webpack/webpack.js.org.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support force tty of nodeConsole
3 participants