Add config option for datetime visibility in the logger
This commit is contained in:
parent
bfc5453f28
commit
b1331a519b
3 changed files with 6 additions and 1 deletions
|
|
@ -25,6 +25,7 @@ export var hibernatedGames: string[] = [];
|
||||||
export var games: {[index: string]: Game} = {};
|
export var games: {[index: string]: Game} = {};
|
||||||
|
|
||||||
export const log: Logger = new Logger({
|
export const log: Logger = new Logger({
|
||||||
|
displayDateTime: conf.log.datetime,
|
||||||
displayFunctionName: false,
|
displayFunctionName: false,
|
||||||
displayLoggerName: true,
|
displayLoggerName: true,
|
||||||
displayFilePath: `hidden`,
|
displayFilePath: `hidden`,
|
||||||
|
|
|
||||||
1
server/src/types/config.d.ts
vendored
1
server/src/types/config.d.ts
vendored
|
|
@ -1,6 +1,7 @@
|
||||||
interface config {
|
interface config {
|
||||||
log: {
|
log: {
|
||||||
level: `silly` | `debug` | `info` | `error` | `warn` | `fatal` | `trace`;
|
level: `silly` | `debug` | `info` | `error` | `warn` | `fatal` | `trace`;
|
||||||
|
datetime: boolean;
|
||||||
};
|
};
|
||||||
websocket: {
|
websocket: {
|
||||||
port: number;
|
port: number;
|
||||||
|
|
|
||||||
|
|
@ -88,3 +88,6 @@ directory = ""
|
||||||
# - "trace"
|
# - "trace"
|
||||||
# any other value will prevent the server from starting at runtime.
|
# any other value will prevent the server from starting at runtime.
|
||||||
level = "info"
|
level = "info"
|
||||||
|
|
||||||
|
# Whether or not the log should output the date and time information in the log
|
||||||
|
datetime = true
|
||||||
Loading…
Add table
Add a link
Reference in a new issue