Reading the Rails commit logs, I see that db/schema.rb's purpose has
been clarified. It's intended to be the authoritative location for
your database schema, and rake tasks like db:reset use it to rebuild
the schema rather than running migrations.
This raises several questions for me.
1 ) What, then, is the preferred mechanism for "seed" data in the
database? Currently, many people use migrations to insert bootstrap
data. If schema.rb will be used for tasks like db:reset, none of this
data will be loaded.
2 ) What about those of us who specify additional options like charset
or table types? This information, last time I checked, doesn't seem to
be saved in the schema.rb.
3 ) Should there be yet another database-related Rake task for
development? Many of us create migrations, then modify them until
we're ready to commit. A simple "rake db:reset" used to re-run the
migrations from scratch, but the new semantics mean that migration
changes are never reflected.
Thanks in advance.