Skip to content

Instantly share code, notes, and snippets.

@jrsa
Created June 23, 2017 18:55
Show Gist options
  • Save jrsa/8e629ba4692f0117312f3dbd0522efe1 to your computer and use it in GitHub Desktop.
Save jrsa/8e629ba4692f0117312f3dbd0522efe1 to your computer and use it in GitHub Desktop.
#! /usr/bin/env ruby
require 'aws-sdk'
region = 'us-west-2'
s3 = Aws::S3::Resource.new(region: region)
bucket_name = ARGV[0]
s3.buckets.limit(50).each do |b|
puts "#{b.name}"
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment