Browse files

fortune yo! (hello october world)

  • Loading branch information...
1 parent e1fcc22 commit 338ae95002da593dfeedf2621d0633ef3d407698 Aurelian Oancea committed Jun 7, 2012
Showing with 13 additions and 0 deletions.
  1. +13 −0 plugins/fortune.rb
View
13 plugins/fortune.rb
@@ -0,0 +1,13 @@
+gem 'typhoeus'
+
+class Fortune
+ include October::Plugin
+
+ match /fortune?$/, method: :fortune
+
+ register_help 'fortune', 'fortune YO!'
+ def fortune(m)
+ response = Typhoeus::Request.get "http://www.fortunefortoday.com/getfortuneonly.php"
+ m.reply response.body
+ end
+end

0 comments on commit 338ae95

Please sign in to comment.