later you may see

in support of blog driven development for Ruby on Rails

Simple tactic for migrations beyond migrate

leave a comment »

Make use of Rake in your miscellaneous migration tasks. Migrations are geared for database changes all or nothing is best since backtracking always is risky. Add your own application rake tasks to handle additional record creation, default settings, app specific stuff. Model classes are best for methods since you can test on console and tinker, but once you are there, a rake lib gives better control for the task at hand, lets you add on tasks without affecting the app core. All deployments I’ve used have handles to rake which can be used on demand.

Advertisement

Written by Alfonso Adriasola

July 29, 2010 at 2:19 PM

Posted in ruby

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Connecting to %s

Follow

Get every new post delivered to your Inbox.