|
zelenik Beginner
Joined: 23 Sep 2006 Posts: 11
|
Posted: Mon May 25, 2020 2:49 am
How do I review colored logs without the escape characters? |
This feels pretty silly. I have a number of log files that I am trying to look at but it is hard to make out the mud text with all the escape characters in the TXT file. I'm sure there is another way to do it... I believe I did it in the past, but cant seem to figure it out now.
|
|
|
|
shalimar GURU
Joined: 04 Aug 2002 Posts: 4691 Location: Pensacola, FL, USA
|
Posted: Mon May 25, 2020 11:35 am |
Open up preferences.
Session tab on the left.
Logging tab up top.
Adjust as needed. |
|
_________________ Discord: Shalimarwildcat |
|
|
|
gawen Newbie
Joined: 15 Dec 2012 Posts: 8
|
Posted: Mon May 25, 2020 2:23 pm |
I made this python script to convert my old logs to html. I run it outside cmud and it works fine. only have to install the ansi2html through pip
Code: |
import os
from ansi2html import Ansi2HTMLConverter
os.chdir('path_to_logs')
conv = Ansi2HTMLConverter()
fls = os.scandir()
for a in fls:
with open(a.name,'r') as f:
ansi = "".join(f.readlines())
html = conv.convert(ansi)
with open(a.name + '.html','w') as g:
g.write(html)
html = conv.convert(ansi)
|
|
|
|
|
|
|