Damn, that new release of Hobo reminds me: those guys have got some nice looking migrations. Let’s take it a step further. Let’s bring sexy back.
Let’s turn this:
class UpdateYourFamily < ActiveRecord::Migration create_table :updates do |t| t.column :user_id, :integer t.column :group_id, :integer t.column :body, :text t.column :type, :string t.column :created_at, :datetime t.column :updated_at, :datetime end def self.down drop_table :updates end end
class UpdateYourFamily < ActiveRecord::Migration create_table :updates do foreign_key :user foreign_key :group text :body string :type timestamps! end def self.down drop_table :updates end end
$ ./script/plugin install \ svn://errtheblog.com/svn/plugins/sexy_migrations
$ piston import svn://errtheblog.com/svn/plugins/sexy_migrations \ vendor/plugins/sexy_migrations
That’s it. It works with them newfangled Independent Migrations and is 100% backwards compatible. Keep your old migrations, sex up your new migrations. But, be careful: it’s real hard to go back to the ‘old way’ of writing migrations once you start getting your sexy on. You’ve been warned.
You heard that Lighthouse launched, right? Right. From now on, any bugs found in any Err plugins should be reported at the Err plugins Lighthouse project. You can jump straight to creating a new ticket if you’d like. (Just make sure to include the name of the plugin you’re reporting a bug for.)
Oh, and speaking of bugs: you may want to follow Err on Twitter. We’ll be using it to post updates about our projects and plugins and blogs, oh my. Oh yeah.