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/env ruby -wU | |
# | |
# This script uses the command line twitter client https://github.com/twitter/twurl | |
# You have to authorize Twurl one time before you can use ist, please read the | |
# README for Twurl which describes how to do it. | |
# What it basically does is it sets the flag that you don't want to see | |
# any retweets of any users at all. | |
require 'json' | |
friends = JSON.parse(`twurl "/1.1/friends/ids.json"`)["ids"] | |
no_retweets = JSON.parse(`twurl "/1.1/friendships/no_retweets/ids.json"`) | |
(friends - no_retweets).each do |id| | |
puts `twurl -X POST "/1.1/friendships/update.json" -d "user_id=#{id}&retweets=false"` | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment