ruby-on-railsschemaless

Getting started with the Friendly ORM


I'm following this tutorial: http://friendlyorm.com/

I'm using InstantRails to run MySQL locally. To run Ruby and Rails, I'm using normal Windows installations.

When I run Friendly.create_tables! I only get an empty Array returned: => [] and no tables are created in my 'friendly_development' database.


Solution

  • Author of Friendly here.

    You'll have to require all of your models before calling Friendly.create_tables! Otherwise, there's no way for Friendly to know which models exist. In a future revision, I'll automatically preload all your models.