Database per branch so you can easily switch between database models.
Works with Rails 4.x and 5.x
How to use
Will create a new database and load it with seed. It will create
.branchinator with db name for each env.
Will remove the database and
Shortcut for branch remove + create.
How to install
Put it into:
group :development, :test do gem 'branchinator' end
development: <<: *default database: <%= Branchinator.database %> test: <<: *default database: <%= Branchinator.database %>
.gitingore as well:
echo .branchinator >> .gitignore
By default database name is taken from application name and looks something like:
If you want you can change the first part and the separator.
branchinator: prefix: awesome-project separator: _