#garfield | Logs for 2016-12-20

Back
[18:29:21] <Tom_L> rue did you see the new log format we've been working on?
[18:31:17] <rue_shop3> no
[18:31:20] <rue_shop3> zlog
[18:31:58] <rue_shop3> I was a bit split on formatting the info too much, part of me wanted to keep most of it plain text
[18:32:18] <Tom_L> i shut the other server down... too late
[18:32:25] <Tom_L> it would be at port 82
[18:32:46] <rue_shop3> ah
[18:32:54] <Tom_L> hold on
[18:33:34] <rue_shop3> I lost focus again
[18:33:42] <Tom_L> http://tom-itx.no-ip.biz:82/~tom-itx/irc/logs/%23garfield/
[18:33:42] <rue_shop3> I think I been on tangents for about 8 months
[18:33:45] <rue_shop3> possibly 14
[18:33:55] <rue_shop3> woof
[18:34:35] <Tom_L> old years will show up below current one
[18:34:43] <rue_shop3> cool, all we need now is a content search :)
[18:35:04] <Tom_L> i'll let you write that
[18:35:35] <Tom_L> rue_bed
[18:35:53] <Tom_L> how to do a replace of # with %23 in code
[18:36:12] <rue_shop3> ?
[18:36:26] <rue_shop3> sed can do it on a range of files if you want
[18:36:34] <Tom_L> log_url = os.path.join(LOG_LOCATION, event.target().replace('#','%23', date)
[18:36:40] <Tom_L> that doesn't work
[18:36:44] <rue_shop3> what language ?
[18:36:50] <Tom_L> python of course
[18:36:54] <rue_shop3> hmm]
[18:36:57] <Tom_L> i wouldn't be asking you otherwise :D
[18:37:36] <Tom_L> log_url = os.path.join(LOG_LOCATION, event.target(), date)
[18:37:42] <Tom_L> was the original line
[18:38:04] <Tom_L> but instead of the url page, it took you to the main index page
[18:38:06] <rue_shop3> event.target().replace('#','%23')
[18:38:20] <rue_shop3> wait, is date the string?
[18:38:28] <Tom_L> i don't think so
[18:38:35] <Tom_L> the channel name is the target i believe
[18:39:01] <Tom_L> instead of %23garfield you get #garfield and that doesn't work
[18:40:04] <rue_shop3> root@blackie2:/files/programming/python/TapeRunner# python
[18:40:04] <rue_shop3> Python 2.7.3 (default, Mar 14 2014, 11:57:14)
[18:40:04] <rue_shop3> [GCC 4.7.2] on linux2
[18:40:04] <rue_shop3> Type "help", "copyright", "credits" or "license" for more information.
[18:40:04] <rue_shop3> >>> foo = "freenode:#garfield"
[18:40:05] <rue_shop3> >>> print foo.replace('#', '%23')
[18:40:06] <rue_shop3> freenode:%23garfield
[18:40:10] <rue_shop3> >>>
[18:40:12] <rue_shop3> ?
[18:40:23] <Tom_L> it needs date appended to it
[18:40:32] <rue_shop3> well you cant append it like that
[18:40:34] <Tom_L> for the logfile
[18:40:46] <rue_shop3> log_url = os.path.join(LOG_LOCATION, event.target()) + str( date)
[18:41:29] <rue_shop3> root@blackie2:/files/programming/python/TapeRunner# python
[18:41:29] <rue_shop3> Python 2.7.3 (default, Mar 14 2014, 11:57:14)
[18:41:29] <rue_shop3> [GCC 4.7.2] on linux2
[18:41:29] <rue_shop3> Type "help", "copyright", "credits" or "license" for more information.
[18:41:29] <rue_shop3> >>> foo = "freenode:#garfield"
[18:41:30] <rue_shop3> >>> print foo.replace('#', '%23')
[18:41:32] <rue_shop3> freenode:%23garfield
[18:41:34] <rue_shop3> >>> date = "24Dec2016"
[18:41:36] <rue_shop3> >>> print foo.replace('#', '%23')+date
[18:41:40] <rue_shop3> freenode:%23garfield24Dec2016
[18:41:42] <rue_shop3> >>>
[18:42:42] <Tom_L> i'll mess with it
[18:42:43] <Tom_L> thanks
[18:43:00] <Tom_L> may possibly take a nap instead though
[18:43:04] <rue_shop3> use + to append strings
[18:43:09] <Tom_L> ok
[18:45:25] <Tom_L> trying it now
[18:45:35] <Tom_L> zlogcalendar
[18:45:35] <zlogcalendar> Tom_L: Today's Log http://tom-itx.no-ip.biz:82/~tom-itx/irc/logs/%23garfield2016-12-20.html
[18:49:07] <Tom_L> zlogcalendar
[18:49:07] <zlogcalendar> Tom_L: Today's Log http://tom-itx.no-ip.biz:82/~tom-itx/irc/logs/%23garfield/2016-12-20.html
[18:49:43] <Tom_L> thanks rue
[18:50:03] <Tom_L> top one is the test link
[18:51:07] <rue_house> that worked then?
[18:51:19] <Tom_L> yeah
[18:51:20] <rue_house> looks like it
[18:51:31] <Tom_L> i had to add a + '/'+ date
[18:51:37] <Tom_L> but it works