commited working version
[mirrors/libpurple-core-answerscripts.git] / purple / answerscripts.d / menu.pl
diff --git a/purple/answerscripts.d/menu.pl b/purple/answerscripts.d/menu.pl
new file mode 100755 (executable)
index 0000000..c2f48d6
--- /dev/null
@@ -0,0 +1,15 @@
+#!/usr/bin/env perl
+#Just for you to see that you can use almost any language :-)
+use strict;
+use warnings;
+use Switch;
+
+switch ($ENV{PURPLE_MSG}) {
+       case /^!help$/  { print "What did you expected? A help?! :-P"; }
+       case /^!ping$/  { print "PONG"; }
+       case /^!whoami$/        { print "You are: $ENV{PURPLE_FROM}"; }
+       case /^!(reboot|reset|restart|halt)$/   { print "Broadcast message: The system is going down for reboot NOW !!"; }
+       case /^!google/ { print "UTFG Yourself: http://google.com/"; }
+       case /^!uptime$/        { print qx{uptime}; }
+       case /^!date$/  { print qx{date}; }
+}
This page took 0.103204 seconds and 4 git commands to generate.