MUSHclient logging options?

Started by Lizzie, February 01, 2019, 11:47:47 PM

When you augolog, it saves the log as a date/time. That's great if you know when something happened, and want to see it.

But what happens if you don't remember when it happened, you just remember the name of the character, and the general idea of the event? You'd wade through dozens or even hundreds of logs, and if you play for a couple of hours at a time, each log could easily take hours to read, just to find the one snippet you're looking for.

What I'd LIKE to do -

have it automatically start logging when I log into the game. And when I hit "quit" in the game OR try to exit the mushclient, it'll pop up with a "please name your file" window that I can either name, or NOT save the file. That way I can name every log, without having to remember to set it up manually (which I never remember to do, and that's why I'm posting now).

Is such a thing possible?

if so, how do I do that? if not, maybe one of you MUSHclient script junkies could make something for us!
Talia said: Notice to all: Do not mess with Lizzie's GDB. She will cut you.
Delirium said: Notice to all: do not mess with Lizzie's soap. She will cut you.

You can use custom variables in the 'automatically log to this file' input. [Not sure you need this, but for other users, bring up the configuration window in MushClient by clicking most any of the icons on the quickbar (such as alias or trigger button), click on Logging under General] Browse to the folder you want them stored in and put in whatever you like. I use:
%Y-%m-%d.txt
All of the variables are found:
https://www.gammon.com.au/scripts/doc.php?dialog=IDD_PREFS_P4

I know this isn't exactly what you asked for. My next step is to use Notepad++ which has an amazing Search>Find in files... function to let me search every .txt file in a folder for anything, name, sdesc, single word, phrase... and give me hyperlinks with short reference blurbs for each. Notepad++ is free and immensely powerful. I hope this helps.

You could do what I do, and just write everything to one file, then delete it every few days, when it becomes too big to open.  ;)

I'm no Mushclient expert, but what I'd do is have your mushclient log to a file, say, templog.txt, then add 'quit' as a trigger to rename that file. Eg. "quit mudsex_session_69" renames "templog.txt" to "mudsex_session_69.txt".

That should be as easy as telling mushclient to log to templog.txt, then adding a trigger with:


CloseLog()
os.rename('templog.txt','%1.html')
Send('quit')


If it has to work when you close mushclient, then it becomes a bit more complicated. I guess you could manually just rename templog.txt if you closed mushclient.

Or just get into the relatively easy habit of hitting the "Log" button on the Mushclient toolbar when you start your session. You are then prompted to save to a specified file (or you can choose to append the the log to an existing file).
You are then free to grep your text files at a later date for whatever it is you are looking for.

After a few days of focusing on doing it, it will become automatic, and takes less than 30 seconds.

Quote from: Vyoko on February 02, 2019, 11:22:33 AM
Or just get into the relatively easy habit of hitting the "Log" button on the Mushclient toolbar when you start your session. You are then prompted to save to a specified file (or you can choose to append the the log to an existing file).
You are then free to grep your text files at a later date for whatever it is you are looking for.

After a few days of focusing on doing it, it will become automatic, and takes less than 30 seconds.

I wouldn't know what I wanted to name it, until I'm finished with the RP for the day. or even if I'd want to name it at all.

The problem for me is I never log anything, I keep forgetting. When "something interesting" happens, I usually use a scroll-back copy/paste to notepad, OR I'll start logging, and "date it back" 2000 lines (which I think is the maximum scrollback for logging). And then I'll name it something that will tell me - 4 years later - why I logged it in the first place.

Things like:

claw dimak with 2 moons.txt

and

carine use your hands song.txt

and

jizella death.txt

It's specific events or "sessions" that I want to remember, for whatever reason. The rest of my play time just happens, or doesn't happen, and I either remember it or not.

But the time I know I definitely want to remember it or have a capture of it, ends up inevitably being 3 seconds after I've closed mushclient.
Talia said: Notice to all: Do not mess with Lizzie's GDB. She will cut you.
Delirium said: Notice to all: do not mess with Lizzie's soap. She will cut you.

Quote from: KittenLicks on February 02, 2019, 02:07:26 AM
You could do what I do, and just write everything to one file, then delete it every few days, when it becomes too big to open.  ;)

I'm no Mushclient expert, but what I'd do is have your mushclient log to a file, say, templog.txt, then add 'quit' as a trigger to rename that file. Eg. "quit mudsex_session_69" renames "templog.txt" to "mudsex_session_69.txt".

That should be as easy as telling mushclient to log to templog.txt, then adding a trigger with:


CloseLog()
os.rename('templog.txt','%1.html')
Send('quit')


If it has to work when you close mushclient, then it becomes a bit more complicated. I guess you could manually just rename templog.txt if you closed mushclient.

1. where/when exactly do I insert that code?
2. is your %1.html arbitrary? I can replace that with %1.txt right?
Talia said: Notice to all: Do not mess with Lizzie's GDB. She will cut you.
Delirium said: Notice to all: do not mess with Lizzie's soap. She will cut you.

Sorry to double post, but using the 'automatically log to' function automatically starts logging every session. You don't ever have to mess with the files unless you want to delete or rename them. You could use this in conjunction with the script trigger above to rename those 'special' sessions.

Quote from: cnemus on February 02, 2019, 12:58:43 PM
Sorry to double post, but using the 'automatically log to' function automatically starts logging every session. You don't ever have to mess with the files unless you want to delete or rename them. You could use this in conjunction with the script trigger above to rename those 'special' sessions.

Oh - yes I do know about the autolog. But as I said in my first post - that automatically names the log with a date/time stamp, which isn't useful at all if I want to find something in a file about a specific character and a specific event.  So I'd still love to know where exactly and how exactly to add this script trigger. I'd autolog then, and I could always just name the log "junk" and do a global file delete every week to get rid of ones I don't need.
Talia said: Notice to all: Do not mess with Lizzie's GDB. She will cut you.
Delirium said: Notice to all: do not mess with Lizzie's soap. She will cut you.