Skip to content

Instantly share code, notes, and snippets.

@ivanoats
Created March 12, 2011 21:56
Show Gist options
  • Save ivanoats/867609 to your computer and use it in GitHub Desktop.
Save ivanoats/867609 to your computer and use it in GitHub Desktop.
why is @filename nil
desc "Dump the current production database to a MySQL file"
task :dump_remote, :filename do |t, args|
if args
@filename = args[:filename]
else
@filename = "db-backups/production_data-#{Time.now.strftime("%Y-%m-%d-%H%M")}.sql"
end
puts @filename
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment