aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Phillips <david@sighup.nz>2017-03-07 15:50:46 +1300
committerDavid Phillips <david@sighup.nz>2017-03-07 15:50:46 +1300
commit30d44a6b8e05a0e31dca073e0f8d9092e35c8d61 (patch)
tree47db1df78a61898ebe70e80e336772b29c844521
parent1fa355a0a01751f5914c7cdcc3cac1eb470a10c2 (diff)
downloadidalius-30d44a6b8e05a0e31dca073e0f8d9092e35c8d61.tar.xz
Add nick changing command
-rwxr-xr-xsaxrobot8
1 files changed, 8 insertions, 0 deletions
diff --git a/saxrobot b/saxrobot
index ae7e4f3..2e56e4b 100755
--- a/saxrobot
+++ b/saxrobot
@@ -92,6 +92,14 @@ sub irc_msg {
$irc->yield(privmsg => $nick => "I am bot, go away");
return;
}
+ if ($what =~ /^nick\s/) {
+ my ($channel) = $what =~ /^nick\s+(\S+)$/;
+ if ($channel) {
+ $irc->yield(nick => $channel);
+ } else {
+ $irc->yield(privmsg => $nick => "Syntax: nick <nick>");
+ }
+ }
if ($what =~ /^part\s/) {
my ($channel) = $what =~ /^part\s+(\S+)$/;
if ($channel) {