jweslley / rails_completion

Bash completion support for Ruby on Rails.
Other
105 stars 16 forks source link

Allow scaffold/model/migration generators to accept “index” and “uniq” modifiers #10

Closed jweslley closed 12 years ago

jweslley commented 12 years ago

For example,

rails g scaffold Post title:string:index author:uniq price:decimal{7,2}

will create indexes for title and author with the latter being an unique index. Some types such as decimal accept custom options. In the example, price will be a decimal column with precision and scale set to 7 and 2 respectively.

More info: Rails 3.2 release notes