Created
July 19, 2013 09:12
-
-
Save kaosf/6037824 to your computer and use it in GitHub Desktop.
"fr"; earthquake.gem's plugin; execute fav and RT concurrently; ref. https://github.com/jugyo/earthquake/blob/v1.0.0/lib/earthquake/commands.rb#L305-L323 https://github.com/jugyo/earthquake/blob/v1.0.0/lib/earthquake/commands.rb#L325-L332
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
Earthquake.init do | |
command :fr do |m| | |
target = twitter.status(m[1]) | |
if confirm("fav & RT '@#{target["user"]["screen_name"]}: #{target["text"]}'") | |
async_e { | |
twitter.retweet(m[1]) | |
twitter.favorite(m[1]) | |
} | |
end | |
end | |
help :fr, 'fav & RT', 'favorite and retweet' | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment