class BuildDb < ActiveRecord::Migration
  def self.up
    create_table :assets do |t|
      t.column :name, :string
      t.column :description, :text
    end
    create_table :tags do |t|
      t.column :name, :string
    end
    create_table :assets_tags do |t|
      t.column :asset_id, :integer
      t.column :tag_id, :integer
    end
  end

  def self.down
    drop_table :assets_tags
    drop_table :assets
    drop_table :tags
  end
end