diff --git a/irc/commands/remind.py b/irc/commands/remind.py new file mode 100644 index 0000000..6de1767 --- /dev/null +++ b/irc/commands/remind.py @@ -0,0 +1,50 @@ +# -*- coding: utf-8 -*- + +""" +Set a message to be repeated to you in a certain amount of time. +""" + +import threading +import time + +from irc.classes import BaseCommand + +class Remind(BaseCommand): + def get_hooks(self): + return ["msg"] + + def get_help(self, command): + return "Set a message to be repeated to you in a certain amount of time." + + def check(self, data): + if data.is_command and data.command in ["remind", "reminder"]: + return True + return False + + def process(self, data): + if not data.args: + self.connection.reply(data, "please specify a time (in seconds) and a message in the following format: !remind