Sha256: ba4ee9d33bb8f3076c2f5e76b511e60933cf297e2c86d536e4f30158f66e4795

Contents?: true

Size: 243 Bytes

Versions: 4

Compression:

Stored size: 243 Bytes

Contents

class Create<%= res_name.classify.pluralize %> < ActiveRecord::Migration[5.2]
  def change
    create_table :<%= res_name.pluralize %> do |t|
<% res_attrs.each do |name, type| -%>
      t.<%= type %> :<%= name %>
<% end -%>
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
grapethor-0.2.3 lib/grapethor/templates/resource/db/migrations/%res_migration%.rb.tt
grapethor-0.2.2 lib/grapethor/templates/resource/db/migrations/%res_migration%.rb.tt
grapethor-0.2.1 lib/grapethor/templates/resource/db/migrations/%res_migration%.rb.tt
grapethor-0.2.0 lib/grapethor/templates/resource/db/migrations/%res_migration%.rb.tt