Sha256: 78ae35ad7c9408450353efd4f52482bdb7da468954f3e17624ba7945ef519e29

Contents?: true

Size: 620 Bytes

Versions: 2

Compression:

Stored size: 620 Bytes

Contents

class CreateTorrents < ActiveRecord::Migration

  def self.up
    create_table :torrents do |t|
      t.column :id, :integer, :null => false
      t.column :bit_id, :integer
      t.column :info_hash, :string, :limit => 40
      t.column :metainfo, :binary
      t.column :seeders, :integer, :null => false, :default => 0
      t.column :leechers, :integer, :null => false, :default => 0
      t.column :hits, :integer, :null => false, :default => 0
      t.column :total, :integer, :null => false, :default => 0
      t.column :updated_at, :timestamp
    end
  end

  def self.down
    drop_table :torrents
  end

end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
sinatra-s3-0.99 db/migrate/004_create_torrents.rb
sinatra-s3-0.98 db/migrate/004_create_torrents.rb