Skip to content

Instantly share code, notes, and snippets.

@unbalanced
unbalanced / wishings.coffee
Created June 11, 2015 16:29
wishing.coffee
module.exports = (robot) ->
robot.hear /(?=home|i\'m|feel|little|bit).*sick/i, (msg) ->
wishings = ["get well soon!!", "feel better!", "we will miss you today", "please don't die",
"drink a lot of fluids", "have some tea, stay in bed", "wear a sweater next time"]
wish = msg.random wishings
msg.send "hey @#{msg.message.user.name}, #{wish}"
robot.hear /(?=work(ing)?|stay(ing)?).*home/i, (msg) ->
wishings = ["We will miss you!", "You didn't mention if you're sick, if you are, feel better!", "thanks for letting everybody know"]
wish = msg.random wishings