Notice: Any messages purporting to come from this site telling you that your password has expired, or that you need to verify your details, confirm your email, resolve issues, making threats, or asking for money, are
spam. We do not email users with any such messages. If you have lost your password you can obtain a new one by using the
password reset link.
Due to spam on this forum, all posts now need moderator approval.
Entire forum
➜ MUSHclient
➜ General
➜ Logging and creating missing folders
Logging and creating missing folders
|
It is now over 60 days since the last post. This thread is closed.
Refresh page
Posted by
| Coderunner
USA (27 posts) Bio
|
Date
| Tue 08 Nov 2011 10:13 PM (UTC) Amended on Tue 08 Nov 2011 10:18 PM (UTC) by Coderunner
|
Message
| Hello,
I'm trying to automatically log my sessions, but it seems like MUSHclient doesn't automatically create any folders if they don't exist, and I think it'd be really awesome to be able to automatically log to a file like this:
%L%N\%Y\%b\%m-%d.txt
So each day, a new file would be created, in folders sorted by year, then further sorted by month. So you'd have a structure like <world>\2011\Nov\11-08.txt
Then every month, a new month folder would be created, and at the beginning of each year, a new year folder would be created, and a Jan folder created under it.
Thanks. | Top |
|
Posted by
| Nick Gammon
Australia (23,162 posts) Bio
Forum Administrator |
Date
| Reply #1 on Wed 09 Nov 2011 07:48 PM (UTC) |
Message
| It doesn't automatically create directories, but you could script that.
http://www.gammon.com.au/scripts/doc.php?lua=os.execute
Use os.execute to make a directory. After all, you only need to make 13 a year (one for the year plus one for the month). |
- Nick Gammon
www.gammon.com.au, www.mushclient.com | Top |
|
The dates and times for posts above are shown in Universal Co-ordinated Time (UTC).
To show them in your local time you can join the forum, and then set the 'time correction' field in your profile to the number of hours difference between your location and UTC time.
10,640 views.
It is now over 60 days since the last post. This thread is closed.
Refresh page
top