Changed log folder layout (again)
This commit is contained in:
parent
7b13883e95
commit
5797979014
1 changed files with 5 additions and 1 deletions
|
@ -1,3 +1,7 @@
|
||||||
|
"""
|
||||||
|
log.py: written by Scaevolus 2009
|
||||||
|
"""
|
||||||
|
|
||||||
import os
|
import os
|
||||||
import codecs
|
import codecs
|
||||||
import time
|
import time
|
||||||
|
@ -28,7 +32,7 @@ irc_color_re = re.compile(r'(\x03(\d+,\d+|\d)|[\x0f\x02\x16\x1f])')
|
||||||
|
|
||||||
def get_log_filename(dir, server, chan):
|
def get_log_filename(dir, server, chan):
|
||||||
return os.path.join(dir, 'log', gmtime('%Y'), server, chan,
|
return os.path.join(dir, 'log', gmtime('%Y'), server, chan,
|
||||||
(gmtime('%m-%d.log')).lower())
|
(gmtime('%%s.%m-%d.log') % chan).lower())
|
||||||
|
|
||||||
|
|
||||||
def gmtime(format):
|
def gmtime(format):
|
||||||
|
|
Reference in a new issue