Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

migrations aren't being run #236

Closed
dhoss opened this issue Oct 7, 2014 · 5 comments
Closed

migrations aren't being run #236

dhoss opened this issue Oct 7, 2014 · 5 comments

Comments

@dhoss
Copy link

dhoss commented Oct 7, 2014

The first iteration of migrations seemed to work. Since then, mina just skips over them.
I'm not sure what output would be helpful since it just says "-----> DB schema unchanged; skipping DB migration".

@gabskoro
Copy link
Member

gabskoro commented Oct 7, 2014

It's supposed to skip the migration if you don't changed your db, if you want to force migration, just add :force to rails:db_migrate

invoke :'rails:db_migrate:force'

@dhoss
Copy link
Author

dhoss commented Oct 7, 2014

There was a new migration to be run that wasn't picked up. Is there
configuration I'm missing somewhere? It seems to consistently miss new
migrations.
On Oct 7, 2014 2:28 AM, "Gabrijel Škoro" notifications@github.com wrote:

It's supposed to skip the migration if you don't changed your db, if you
want to force migration, just add :force to rails:db_migrate

invoke :'rails:db_migrate:force'


Reply to this email directly or view it on GitHub
#236 (comment).

@gabskoro
Copy link
Member

gabskoro commented Oct 8, 2014

No, you don't need to do anything specially. When you create a new migration the DB schema will change, mina will notice that and run the migration, there can be few things why aren't the migrations run

  1. You don't have the schema.rb file in db folder
  2. Maybe there was a conflict with this file (git) and you changed something that you should not have
  3. Check if you have all tables listed in the schema.rb file

@gabskoro gabskoro closed this as completed Oct 8, 2014
@dhoss
Copy link
Author

dhoss commented Oct 8, 2014

I'm having rails generate the schema as SQL, does mina not check for that?
I'd be glad to submit a pull request if that were the case.
On Oct 8, 2014 3:39 AM, "Gabrijel Škoro" notifications@github.com wrote:

Closed #236 #236.


Reply to this email directly or view it on GitHub
#236 (comment).

@Kriechi
Copy link

Kriechi commented Oct 8, 2014

there is a PR: #177

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants