summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorlookshe <mail@lookshe.org>2011-09-20 23:50:34 +0200
committerlookshe <mail@lookshe.org>2011-09-20 23:50:34 +0200
commit38581cb23a5b09e7eb95c62294774614420ed2dd (patch)
treed166561cd39d5cb5c4cc44181a3eca76921ed69c
parent7d3e3c509d20addb32ab6701155b35a7023d3b4d (diff)
added nickchange to firstseen
-rw-r--r--firstseen.pl7
1 files changed, 7 insertions, 0 deletions
diff --git a/firstseen.pl b/firstseen.pl
index 9eceff8..3d9bced 100644
--- a/firstseen.pl
+++ b/firstseen.pl
@@ -9,6 +9,7 @@ if ($#ARGV ne 2){
my $chan=$ARGV[1];
my $folder=$ARGV[0];
my $nick=$ARGV[2];
+$nick=~s/\|/\\\|/g;
my @files;
@@ -34,6 +35,12 @@ foreach $line (<file>) {
if ($line =~ m/^\[00:00(:00)?\] --- /){
($date=$line)=~s/^\[00:00(:00)?\] --- (.*)\n/$2/;
}
+ if ($line =~ m/^\[[0-9]{2}:[0-9]{2}(:[0-]{2})?\] Nick change: .* -> $nick/i) {
+ ($newnick=$line)=~s/.* Nick change: (.*) -> $nick\n/$1/i;
+ print "$nick was $newnick\n";
+ exec($^X, $0, $folder, $chan, $newnick);
+ exit 0
+ }
}
}