Skip to content

Instantly share code, notes, and snippets.

@thoughtbot
Created August 4, 2009 19:58
Show Gist options
  • Save thoughtbot/161483 to your computer and use it in GitHub Desktop.
Save thoughtbot/161483 to your computer and use it in GitHub Desktop.
$ rake db:structure:dump
$ echo "create database myapp_test2;" | mysql -uroot
$ mysql -uroot -Dmyapp_test2 < db/development_structure.sql
$ vim config/database.yml # add some ERB to config/database.yml
test:
adapter: mysql
encoding: utf8
database: myapp_test<%= ENV['TEST_ENV_NUMBER'] %>
username: root
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment