index : logbot | |
Archlinux32 log bot | gitolite user |
summaryrefslogtreecommitdiff |
author | Erich Eckner <git@eckner.net> | 2019-11-27 13:22:46 +0100 |
---|---|---|
committer | Erich Eckner <git@eckner.net> | 2019-11-27 13:22:46 +0100 |
commit | 5d50bb028fa8965c78f86d0d329313401fd1c3cd (patch) | |
tree | 40c1c82634c1ab0dde948755ae690846cd43d503 /logbot.py | |
parent | 7e8c1fb2c8b3cc4559b6c18366c5b787c1ea3b63 (diff) |
-rwxr-xr-x | logbot.py | 3 |
@@ -347,6 +347,9 @@ class Logbot(SingleServerIRCBot): # Create the log date index if it doesnt exist if not os.path.exists(log_path): write_string(log_path, html_header.replace("%title%", "%s | Logs for %s" % (channel_title, date))) + if os.path.islink("%s/latest.html" % chan_path): + os.unlink("%s/latest.html" % chan_path) + os.symlink(log_path, "%s/latest.html" % chan_path) # Append date log append_line("%s/index.html" % chan_path, '<a href="%s.html">%s</a>' % (date, date)) |