Fix broken log date format, add file logging

This commit is contained in:
riperiperi 2024-12-30 01:28:33 +00:00
parent e8d4250b2e
commit 0573590be4

View file

@ -2,10 +2,11 @@
<nlog xmlns="http://www.nlog-project.org/schemas/NLog.xsd"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<targets>
<target name="console" xsi:type="Console" layout="${date:format=HH\:MM\:ss} ${logger} ${message}" detectConsoleAvailable="false" />
<target name="console" xsi:type="Console" layout="${date:format=hh\:mm\:ss} ${logger} ${message}" detectConsoleAvailable="false" />
<target name="file" xsi:type="File" layout="${date:format=hh\:mm\:ss} ${logger} ${message}" fileName="log/${shortdate}.log" keepFileOpen="false"/>
</targets>
<rules>
<logger name="*" minlevel="Info" writeTo="console" />
<logger name="*" minlevel="Info" writeTo="console,file" />
</rules>
</nlog>