1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-01-12 02:28:11 +02:00

Changed log file format: print timestamp instead of thread ID

This commit is contained in:
Ivan Savenko 2023-01-08 18:23:07 +02:00
parent 2f5ee44cbe
commit 84aefc3362
2 changed files with 2 additions and 1 deletions

View File

@ -356,7 +356,7 @@
"properties" : {
"format" : {
"type" : "string",
"default" : "%l %n [%t] - %m"
"default" : "[%c] %l %n - %m"
}
}
},

View File

@ -295,6 +295,7 @@ std::string CLogFormatter::format(const LogRecord & record) const
boost::algorithm::replace_first(message, "%n", record.domain.getName());
boost::algorithm::replace_first(message, "%t", record.threadId);
boost::algorithm::replace_first(message, "%m", record.message);
boost::algorithm::replace_first(message, "%c", boost::posix_time::to_simple_string(record.timeStamp));
//return boost::to_string (boost::format("%d %d %d[%d] - %d") % dateStream.str() % level % record.domain.getName() % record.threadId % record.message);