log = File.new("screenshots_sinatra.log", "a+") $stdout.reopen(log) $stderr.reopen(log) require File.expand_path("screenshots", File.dirname(__FILE__)) run Screenshots