Created
January 21, 2012 16:04
-
-
Save siyo/1653160 to your computer and use it in GitHub Desktop.
指定したtweetをひっくり返すやつ/ earthquake.gem plugin
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
# reverse tweet | |
# | |
# e.g. :reverse $aa | |
# | |
Earthquake.init do | |
command %r|^:reverse\s(\d+)\s*$|, :as => :reverse do |m| | |
st = cache.read("status:#{m[1].to_i}"); | |
input st["text"].split(//).reverse.join | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment