Skip to content

{ Tag Archives } Migrations

A Response to “Database Versioning”

I was just going to post a comment in reply to Adam Wiggins’s Database Versioning post, but it ended up being pretty long, so I’ll post a response here instead.

I’m the original author and current maintainer of the migrations plugin for datamapper. I spent a lot of time thinking about AR migrations before I started [...]

Also tagged

Spec’ing Migrations (A Tutorial)

I realized I haven’t blogged about (IMHO) the neatest feature of DataMapper’s migrations yet. One of the more harrowing experiences for me in Rails is upgrading a production server with live data, and hoping your migration handles all the existing data correctly. You can dump the database, and attempt the migration on a clone, and [...]

Also tagged , ,

DM Migrations (now with 100% more helpers!)

Added some helpers to the DataMapper Migrations I’ve been writing. These helpers just build up some SQL, and feed it into #execute.

migration 1, :create_people_table do up do create_table :people do column :name, :string column :gender, :string [...]

Also tagged ,

Idealized Migration DSL

There’s a discussion in the datamapper group about how to do migrations. I’ve thrown together an idealized DSL for how the migrations themselves should look.

Here’s the thinking about this, based on how our 2-man web dev team, plus occasionally a few other developers, work on them:

We don’t down-migrate in development. We just drop, create & [...]

Also tagged ,