mirror of
https://github.com/games647/ColorConsole.git
synced 2024-11-30 14:23:23 +01:00
Add configurable Level colors
This commit is contained in:
parent
eb47e6c892
commit
f44a6f7af2
@ -62,7 +62,12 @@ public class ColorConsole extends JavaPlugin {
|
||||
String logFormat = getConfig().getString("logFormat");
|
||||
if (getConfig().getBoolean("colorLoggingLevel")) {
|
||||
logFormat = "%highlight{" + logFormat + "}{"
|
||||
+ "FATAL=red blink, ERROR=red, WARN=yellow bold, INFO=gray, DEBUG=green bold, TRACE=blue}";
|
||||
+ "FATAL=" + getConfig().getString("FATAL") + ", "
|
||||
+ "ERROR=" + getConfig().getString("ERROR") + ", "
|
||||
+ "WARN=" + getConfig().getString("WARN") + ", "
|
||||
+ "INFO=" + getConfig().getString("INFO") + ", "
|
||||
+ "DEBUG=" + getConfig().getString("DEBUG") + ", "
|
||||
+ "TRACE=" + getConfig().getString("TRACE") + "}";
|
||||
}
|
||||
|
||||
PatternLayout layout = PatternLayout
|
||||
|
@ -21,3 +21,11 @@ colorLoggingLevel: true
|
||||
# For more details vist: https://logging.apache.org/log4j/2.x/manual/layouts.html#Patterns
|
||||
logFormat: '[%d{HH:mm:ss} %level]: %msg%n'
|
||||
|
||||
# Log Level Colors
|
||||
FATAL: red blink
|
||||
ERROR: red
|
||||
WARN: yellow bold
|
||||
INFO: gray
|
||||
DEBUG: green bold
|
||||
TRACE: blue
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user