-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtinylog.properties
111 lines (98 loc) · 4.97 KB
/
tinylog.properties
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
#
# Tinylog
#
# For config details see http://www.tinylog.org/configuration
#
tinylog.locale = en_US
# --------------------------------------------
# ColoredConsole
# --------------------------------------------
# Default tinylog console writer - will print assigned level and higher
# For coloring, we define a writer per each level (singleleve=true) and
# and assign colors as ASCII codes in the format. Some foreground colors:
# - white: \u001B[97m
# - purple: \u001B[34m
# - cyan: \u001B[36m
# - green: \u001B[32m
# - yellow: \u001B[33m
# - red: \u001B[31m
# - light gray: \u001B[37m
# - dark gray: \u001B[90m
# Reset colors: \u001B[0m
# For more color codes see: https://en.wikipedia.org/wiki/ANSI_escape_code
# ---------- DEFAULT EXAMPLE: level specific coloring (of the level field) ----------
# Note that we do not need post* parameters as the color is already set (to dark gray) after the post level tag
# and reset to default coloring at the end.
tinylog.writer = coloredconsole
tinylog.writer.level = trace
tinylog.writer.stream = out
tinylog.writer.buffered = true
tinylog.writer.format = [[preLevelTag]]{{level}|min-size=7}[[postLevelTag]] {\u001B[90m{date:yyyy-MM-dd HH:mm:ss} \u001B[38;5;24m{class_name}:{line} - {method}()|min-size=65} \u001B[97m: \u001B[37m{message}\u001B[0m
tinylog.writer.preLevelTag = [[preLevelTag]]
tinylog.writer.postLevelTag = [[postLevelTag]]
tinylog.writer.preTrace = \u001B[97m
#tinylog.writer.postTrace = \u001B[0m
tinylog.writer.preDebug = \u001B[36m
#tinylog.writer.postDebug = \u001B[0m
tinylog.writer.preInfo = \u001B[32m
#tinylog.writer.postInfo = \u001B[0m
tinylog.writer.preWarn = \u001B[33m
tinylog.writer.postWarn = \u001B[37m
tinylog.writer.preError = \u001B[31m
#tinylog.writer.postError = \u001B[0m
# ---------- lOG-LEVEL DECORATION EXAMPLE: level specific coloring (of the level field) with surrounding decorations ----------
# Note that we do not need post* parameters as the color is already set (to dark gray) after the post level tag
# and reset to default coloring at the end.
#tinylog.writer = coloredconsole
#tinylog.writer.level = trace
#tinylog.writer.stream = out
#tinylog.writer.buffered = true
#tinylog.writer.format = [[preLevelTag]]{level}[[postLevelTag]] {\u001B[90m{date:yyyy-MM-dd HH:mm:ss} \u001B[38;5;24m{class_name}:{line} - {method}()|min-size=65} \u001B[97m: \u001B[37m{message}\u001B[0m
#tinylog.writer.preLevelTag = [[preLevelTag]]
#tinylog.writer.postLevelTag = [[postLevelTag]]
#tinylog.writer.preTrace = \u001B[49m \u001B[97m
#tinylog.writer.postTrace = \u001B[0m \u001B[0m
#tinylog.writer.preDebug = \u001B[49m- \u001B[36m
#tinylog.writer.postDebug = \u001B[0m -\u001B[0m
#tinylog.writer.preInfo = \u001B[42m \u001B[49m \u001B[32m
#tinylog.writer.postInfo = \u001B[49m \u001B[42m \u001B[0m
#tinylog.writer.preWarn = \u001B[43m \u001B[49m \u001B[33m
#tinylog.writer.postWarn = \u001B[49m \u001B[43m \u001B[0m\u001B[37m
#tinylog.writer.preError = \u001B[31m\u001B[41m < \u001B[49m \u001B[31m
#tinylog.writer.postError = \u001B[49m \u001B[41m > \u001B[0m
# ---------- CUSTOM TAG EXAMPLE: colorize custom tag coloring ----------
#
## Custom tags are assumed to be source code generated
#tinylog.writer = coloredconsole
#tinylog.writer.level = trace
#tinylog.writer.stream = out
#tinylog.writer.buffered = true
#tinylog.writer.format = {level} {\u001B[90m{date:yyyy-MM-dd HH:mm:ss} \u001B[38;5;24m{class_name}:{line} - {method}()|min-size=55} \u001B[97m: \u001B[37m{message}\u001B[0m
#
## Example 1: sequential coloring (replacement provides tags that are replaced sequentially by processing of custom tags 2..5)
#tinylog.writer.preCustomTag1 = [[someCustomPreTag]]
#tinylog.writer.preCustom1 = <----
#tinylog.writer.postCustomTag1 = [[someCustomPostTag]]
#tinylog.writer.postCustom1 = ----- and tag-based added <==== other text ====> as for example the UNCAUGHT EXCEPTION
#
## Example 2: coloring of any occurrence
#tinylog.writer.preCustomTag2 = -----
#tinylog.writer.preCustom2 = \u001B[34m-----\u001B[37m
#
## Example 3: coloring within the tags
## Note that the tags distinguish from the others
#tinylog.writer.preCustomTag3 = <----
#tinylog.writer.preCustom3 = <----\u001B[33m
#tinylog.writer.postCustomTag3 = ---->
#tinylog.writer.postCustom3 = \u001B[37m---->
#
## Example 4: coloring of tagged content including tags
#tinylog.writer.preCustomTag4 = <====
#tinylog.writer.preCustom4 = \u001B[32m=====
#tinylog.writer.postCustomTag4 = ====>
#tinylog.writer.postCustom4 = \u001B[32m=====\u001B[37m
#
## Example 5: coloring of tagged content including tags
## Note that the tag replacement is enriched with '<' and '>', respectively
#tinylog.writer.preCustomTag5 = UNCAUGHT EXCEPTION
#tinylog.writer.preCustom5 = \u001B[41m\u001B[97m < UNCAUGHT EXCEPTION > \u001B[49m\u001B[37m