+2013-05-25 Ryosuke Niwa <rniwa@webkit.org>
+
+ Teach webkitbot and WKR how to respond to yt?
+ https://bugs.webkit.org/show_bug.cgi?id=116775
+
+ Reviewed by Andreas Kling.
+
+ * Scripts/webkitpy/tool/bot/irc_command.py:
+ (Hi): Fixed the usage string.
+ (Hi.execute): Made it more generic so that it works in WKR.
+ (YouThere): Added.
+ (YouThere.execute): Added.
+ * Scripts/webkitpy/tool/commands/newcommitbot.py:
+
2013-05-25 Simon Fraser <simon.fraser@apple.com>
Try to fix the EFL build.
class Hi(IRCCommand):
usage_string = "hi"
- help_string = "Retrieves a random quip from Bugzilla."
+ help_string = "Responds with hi."
def execute(self, nick, args, tool, sheriff):
- if len(args) and re.match(r'webkitbot_*\s*!\s*', ' '.join(args)):
+ if len(args) and re.match(sheriff.name() + r'_*\s*!\s*', ' '.join(args)):
return "%s: hi %s!" % (nick, nick)
quips = tool.bugs.quips()
quips.append('"Only you can prevent forest fires." -- Smokey the Bear')
return nick + ": pong"
+class YouThere(IRCCommand):
+ usage_string = "yt?"
+ help_string = "Responds with yes."
+
+ def execute(self, nick, args, tool, sheriff):
+ return "%s: yes" % nick
+
+
class Restart(IRCCommand):
usage_string = "restart"
help_string = "Restarts sherrifbot. Will update its WebKit checkout, and re-join the channel momentarily."
"roll-chromium-deps": RollChromiumDEPS,
"rollout": Rollout,
"whois": Whois,
+ "yt?": YouThere,
}
# Add revert as an "easter egg" command. Why?
from webkitpy.tool.bot.irc_command import Hi
from webkitpy.tool.bot.irc_command import PingPong
from webkitpy.tool.bot.irc_command import Restart
+from webkitpy.tool.bot.irc_command import YouThere
from webkitpy.tool.bot.ircbot import IRCBot
from webkitpy.tool.commands.queues import AbstractQueue
from webkitpy.tool.commands.stepsequence import StepSequenceErrorHandler
"hi": Hi,
"ping": PingPong,
"restart": Restart,
+ "yt?": YouThere,
}
_maximum_number_of_revisions_to_avoid_spamming_irc = 10