Skip to content

Instantly share code, notes, and snippets.

@hakanai
Created August 14, 2009 10:02
Show Gist options
  • Save hakanai/167743 to your computer and use it in GitHub Desktop.
Save hakanai/167743 to your computer and use it in GitHub Desktop.
create_table :tags do |t|
t.string :name
t.boolean :container
t.integer :parent_id
t.integer :lft
t.integer :rgt
end
create_table :images do |t|
t.timestamps
t.string :name
t.string :hash
t.string :hash_type
t.string :type
t.string :source
t.integer :width
t.integer :height
end
create_table :image_tags do |t|
t.integer :tag_id
t.integer :image_id
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment