Last change
on this file since aac6b0a was
85544a9,
checked in by njw <njw@…>, 15 years ago
|
minor fix to since-query-awkward
|
-
Property mode set to
100644
|
File size:
757 bytes
|
Rev | Line | |
---|
[b3b0c9c] | 1 | #! /usr/bin/env ruby |
---|
| 2 | |
---|
[9ea979a] | 3 | # Norbert Wigbels |
---|
| 4 | # |
---|
[b3b0c9c] | 5 | # remove all your tweets; |
---|
| 6 | # basically, if you want to keep your account |
---|
| 7 | # |
---|
| 8 | # adapted from http://blog.johnwyles.com/articles/2009/01/06/destroying-deleting-and-erasing-old-twitter-tweets/ |
---|
[fc1853a] | 9 | |
---|
| 10 | require 'rubygems' |
---|
| 11 | require 'activesupport' |
---|
| 12 | require 'twitter' |
---|
| 13 | |
---|
| 14 | |
---|
[b3b0c9c] | 15 | # auth yourself |
---|
[85544a9] | 16 | httpauth = Twitter::HTTPAuth.new('YOUR_USERNAME', 'PASSWORD') |
---|
[fc1853a] | 17 | twitter = Twitter::Base.new(httpauth) |
---|
| 18 | |
---|
[b3b0c9c] | 19 | # go for complete deletion |
---|
[85544a9] | 20 | chunk = twitter.user_timeline |
---|
| 21 | while chunk do |
---|
| 22 | chunk.each do |s| |
---|
| 23 | twitter.status_destroy(s.id) |
---|
| 24 | puts "Deleted tweet: [#{s.id}] \"#{s.text}\" (#{s.created_at})" |
---|
| 25 | end |
---|
| 26 | chunk = twitter.user_timeline |
---|
[fc1853a] | 27 | end |
---|
[c01b5ba] | 28 | |
---|
| 29 | # finally |
---|
[85544a9] | 30 | twitter.update("Hey! Ho! Let's Go #rmallyourtweets http://foobla.wigbels.de/tag/delete-all-tweets/") |
---|
Note: See
TracBrowser
for help on using the repository browser.