Skip to content
This repository has been archived by the owner on Oct 16, 2020. It is now read-only.

Commit

Permalink
bot: Give: Fix some pattern
Browse files Browse the repository at this point in the history
  • Loading branch information
icy committed Apr 10, 2012
1 parent 9d49da9 commit 7893838
Showing 1 changed file with 10 additions and 12 deletions.
22 changes: 10 additions & 12 deletions bot/bot.rb
Expand Up @@ -110,19 +110,17 @@ def give_something(m, someone, section, args)
wiki ? "https://wiki.archlinux.org/index.php/Special:Search/#{wiki}" : nil
when "tinyurl" then
tinyurl(args)
else
if gs = args.match(/^some ([^ ]+)/)
case gs[1]
when "thanks" then "Thank you very much"
when "shit" then "Oh, you ... s^ck"
when "hugs" then "Oh, let me hold you tide"
when "kiss" then "Kiss you a thousand times"
when "helps" then "You wanna try google instead"
else "#{m.user.nick} wants me to delivery to you some #{gs[1}"
end
else
""
when "some"
case args
when "thanks" then "Thank you very much"
when "shit" then "Oh, you ... s^ck"
when "hugs" then "Oh, let me hold you tide"
when "kiss" then "Kiss you a thousand times"
when "helps" then "You wanna try google instead"
else "#{m.user.nick} wants me to delivery to you some #{args}"
end
else
""
end

if text
Expand Down

0 comments on commit 7893838

Please sign in to comment.