简体   繁体   中英

Redirect output of log into net core console window

In net core there is nice log console window. I would like to use it but i develop using .NET framework . I use Serilog to log data into .txt and .json files. Is there anyway to have that console window which would print nicely in color from that log files during progrm debug?

I can't imagine there is any way to do that without jumping through significant hoops. What I do is log to a.log file, and then have that open in Visual Studio Code which will automatically apply coloured highlighting. You could then add the 'Log Viewer' extension to VS Code which will allow 'tailing' the log file and other things.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM