Tuesday, October 30, 2007

s3 & irb ftw

Jeff Atwood posted a link to a gigantic graphic of the entire first level of Super Mario Brothers. Unfortunately, because Jeff Atwood gets a ton of traffic, the link is now dead - bandwidth exceeded.

My Seaside screencasts are doing the same thing for people who go to see them, but I've got a solution ready, and I'm already using it on images.

This is me uploading two images to Amazon S3 for my blog:

%w{amazon_email.jpg amazon_customer_service.jpg}.each {|jpg| upload jpg}

All in one line. Nice. It could be probably be even terser with Raganwald's String#to_proc.

In a few weeks I'll be packaging up my absurdly-customized .irbrc file - nearly 350 lines of code - as a gem. For now, here's an abridged version which makes it clear how easy this particular blend of special sauce is to cook.

(Ironically, the images in the example are screengrabs of Amazon's customer-facing systems counterbalancing S3's awesomeness with equally intense lameness.)