Skip to content
This repository has been archived by the owner. It is now read-only.
Permalink
Branch: master
Find file Copy path
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
executable file 16 lines (14 sloc) 306 Bytes
#!/usr/bin/env ruby
require 'rubygems'
require 'json'
STDIN.each do |line|
next unless line =~ /"location"/
next if line =~ /"location":null/
next if line =~ /"location":""/
begin
tweet = JSON.parse(line)
puts "#{tweet['created_at']}\t#{tweet['user']['location']}\n"
rescue
# whatever
end
end
You can’t perform that action at this time.