File: topics.pl.diff

package info (click to toggle)
irssi-scripts 20160301
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 3,624 kB
  • ctags: 2,564
  • sloc: perl: 61,025; sh: 184; makefile: 6
file content (19 lines) | stat: -rw-r--r-- 705 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
Description: topics.pl: show real time instead of epoch, remove quotes
Forwarded: no
Author: Christoph Berg <myon@debian.org>
Last-Update: 2006-07-22
--- a/scripts/topics.pl
+++ b/scripts/topics.pl
@@ -104,10 +104,10 @@
 	my $i = 0;
 	my $text;
 	foreach (@{$topics{$ircnet}{$name}{list}}) {
-	    $text .= "%r[".$i."]%n ".$_->{topic_time}." (by ".$_->{topic_by}.")\n";
+	    $text .= "%r[$i]%n ".scalar(localtime($_->{topic_time}))." ".$_->{topic_by}."\n";
 	    my $topic = $_->{topic};
 	    $topic =~ s/%/%%/g;
-	    $text .= '     "'.$topic.'"'."\n";
+	    $text .= "     $topic\n";
 	    $i++;
 	}
 	$witem->print($_, MSGLEVEL_CLIENTCRAP) foreach (split(/\n/, draw_box('Topics', $text, $name, 1)));