hookup icon indicating copy to clipboard operation
hookup copied to clipboard

Hookup should be able to handle gracefully that no Database already exists

Open kalbasit opened this issue 12 years ago • 1 comments

Hey Tim!

On a project I work on, we use one database per branch, the database name is determined by the project name, part of the branch name and part of everything combined which result in a database name that looks like project_dev_feature_90a8834de76326869.

We do this because we want to make sure that each branch has it's own dedicated database and we do not want to worry much about migrations between features (that can radically change!)

So using Hookup on this project will result in the following:

$ git checkout feature
Switched to a new branch 'feature'
rake aborted!
Unknown database 'project_dev_feature_90a8834de76326869'

Tasks: TOP => db:migrate:down
(See full trace by running task with --trace)
Failed to rollback 20121115215229_add_comments_to_posts.rb

Any suggestions ?

kalbasit avatar Dec 04 '12 19:12 kalbasit

Well, sounds like you've sidestepped most of the issues hookup is trying to resolve. What do you want to happen instead? Just run rake db:migrate when it's done?

tpope avatar Jan 01 '13 03:01 tpope