Created
November 2, 2011 12:39
-
-
Save autch/1333518 to your computer and use it in GitHub Desktop.
赤人てんてーを自動通報
This file contains 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
#!/usr/bin/ruby1.9.1 | |
# -*- encoding: utf-8-unix; -*- | |
require 'rubygems' | |
require 'grackle' | |
# add :auth parameter to retweet/post | |
client = Grackle::Client.new() | |
tw = client.statuses.user_timeline.json?(:screen_name => 'akahito65535') | |
tw.select{|i| /幼女/ =~ i.text }.each do |tw| | |
# skip if it'a old-school retweet or mention | |
next if /@/=~ tw.text or /RT/ =~ tw.text | |
# TSU-HO-SHIMASHITA!! | |
#client.statuses.update!(:status => "\#千葉県警 RT #{tw.text}") | |
puts tw.text | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment