From a62ecf70363f9bcc4ba6c04a7a817b27f7647f82 Mon Sep 17 00:00:00 2001 From: Patrick Armstrong Date: Tue, 20 Dec 2011 16:42:00 -0800 Subject: [PATCH] Peer --- hubot-scripts.json | 2 +- scripts/peer.coffee | 7 +++++++ 2 files changed, 8 insertions(+), 1 deletion(-) create mode 100644 scripts/peer.coffee diff --git a/hubot-scripts.json b/hubot-scripts.json index 1e2aef2..2ffe372 100644 --- a/hubot-scripts.json +++ b/hubot-scripts.json @@ -1 +1 @@ -["redis-brain.coffee", "tweet.coffee", "shipit.coffee", "help.coffee", "ping.coffee"] +["redis-brain.coffee", "tweet.coffee", "shipit.coffee", "ping.coffee"] diff --git a/scripts/peer.coffee b/scripts/peer.coffee new file mode 100644 index 0000000..46b13f0 --- /dev/null +++ b/scripts/peer.coffee @@ -0,0 +1,7 @@ +# A way to have hubot back you up +# +module.exports = (robot) -> + robot.hear /peer.*/i, (msg) -> + setTimeout -> + msg.send msg.match[0] + , 1000