Created
October 15, 2012 22:06
-
-
Save zakgrant/3895886 to your computer and use it in GitHub Desktop.
Delete all Picasa Web Albums for an Account
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 | |
# using the picasa gem => https://github.com/morgoth/picasa | |
require "picasa" | |
# delete all albums for an account. | |
begin | |
client = Picasa::Client.new(:user_id => $INSERT_GOOGLE_USER_NAME_HERE, :password => $INSERT_PASSWORD_HERE) | |
client.album.list.entries.each do |album| | |
client.album.delete(album.id) | |
end | |
rescue Picasa::ForbiddenError | |
puts "You have the wrong user_id or password." | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment