This project is archived and is in readonly mode.

#6144 ✓resolved
Evgeniy Dolzhenko

Model generator doesn't honor --skip option

Reported by Evgeniy Dolzhenko | December 10th, 2010 @ 04:24 PM | in 3.1

When trying to provide the --skip option to rails generate model it fails if the about to be generated migration already exists instead of just skipping it. Demonstration:

> rails -v
Rails 3.0.3
> rails new test_generator     
> cd test_generator     
> rails generate model post   

> rails generate model post --skip
      invoke  active_record
Another migration is already named create_posts: /srv/samba/share/test_generator/db/migrate/20101210161949_create_posts.rb

Comments and changes to this ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

<h2 style="font-size: 14px">Tickets have moved to Github</h2>

The new ticket tracker is available at <a href=""></a>


Referenced by