Package org.apache.maven.shared.utils.logging
package org.apache.maven.shared.utils.logging
An API to write Maven messages to console with styled color content, consistently across whole
Maven ecosystem (Maven itself or any plugin or extension).
Messages are built with instances of MessageBuilder
which provides a fluent API, while error level are colored by slf4j provider with
LoggerLevelRenderer
.
MessageUtils
gives access to these builders.
Plugins can use this API with any Maven version: color just won't be activated when run with Maven versions older than 3.5.0.
Styles are:
debug
,info
,warning
anderror
for logger level rendering,success
,warning
,failure
,strong
,mojo
andproject
for message content
MAVEN_OPTS
environment variable (eventually in .mavenrc
script):- system properties are named
style.<style name>
, - values are comma separated combination of
bold
,<color>
andbg<color>
(for background), where<color>
is an ANSI color:black
,red
,green
,yellow
,blue
,magenta
,cyan
orwhite
, eventually withbright
prefix
- Since:
- 3.1.0
-
ClassDescriptionLogger level renderer, intended for Maven slf4j logging provider implementers to render logger level.Message builder that supports configurable styling.Colored message utils, to manage colors consistently across plugins (only if Maven version is at least 3.5.0).