[Rails] Plugin w/ Migrations and/or Fixtures?

James Adam james.adam at gmail.com
Wed Dec 14 22:32:57 GMT 2005


You might want to take a look at rails engines - we've implemented
migrations and fixtures to some extent for plugins (since engines are
first and foremost simply plugins themselves)

- james

On 12/14/05, Steve Sloan <steve at finagle.org> wrote:
> I'm working on a plugin which needs to add both schema and data to the app
> database, and I'm trying to figure out the best way to do it.  I'd like to use a
>   db migration to modify the schema and load the data from a YAML fixture, but
> Rails doesn't seem to support migrations for plugins.  To do so, the schema_info
> table would need to change to include a plugin name field (with 'rails' or NULL
> for the application schema version), and corresponding mod to the Rake tasks to
> also run plugin migrations.
>
> Is there another way I can accomplish this?  Is this a feature anyone else is
> wanting/working-on?  Is there any reason why this _wouldn't_ work?
>
> Thanks ...
>
> -- Steve
> _______________________________________________
> Rails mailing list
> Rails at lists.rubyonrails.org
> http://lists.rubyonrails.org/mailman/listinfo/rails
>


More information about the Rails mailing list