Sha256: 5dc81456abdbca2646da428bfc258b6f46a5ddae170a500f36f744f60273feaa

Contents?: true

Size: 522 Bytes

Versions: 22

Compression:

Stored size: 522 Bytes

Contents

if defined?(RailsERD)
  Rake::Task['db:migrate'].enhance do
    ENV['filename'] = 'doc/db_layout'
    ENV['attributes'] = 'foreign_keys, content, primary_keys, timestamp'

    excludes = ['ActiveRecord::SchemaMigration']
    excludes << 'ActiveRecord::SessionStore::Session' if defined?(ActiveRecord::SessionStore)
    case Rails::VERSION::MAJOR
    when 5
      excludes << 'ActiveRecord::InternalMetadata'
    end
    ENV['exclude'] = excludes.join(',')

    Rake::Task['erd'].invoke
  end if Rails.env.development?
end

Version data entries

22 entries across 22 versions & 1 rubygems

Version Path
daddy-0.6.5 lib/tasks/rails_erd.rake
daddy-0.6.4 lib/tasks/rails_erd.rake
daddy-0.6.3 lib/tasks/rails_erd.rake
daddy-0.6.2 lib/tasks/rails_erd.rake
daddy-0.6.1 lib/tasks/rails_erd.rake
daddy-0.6.0 lib/tasks/rails_erd.rake
daddy-0.5.34 lib/tasks/rails_erd.rake
daddy-0.5.33 lib/tasks/rails_erd.rake
daddy-0.5.32 lib/tasks/rails_erd.rake
daddy-0.5.31 lib/tasks/rails_erd.rake
daddy-0.5.30 lib/tasks/rails_erd.rake
daddy-0.5.29 lib/tasks/rails_erd.rake
daddy-0.5.28 lib/tasks/rails_erd.rake
daddy-0.5.27 lib/tasks/rails_erd.rake
daddy-0.5.26 lib/tasks/rails_erd.rake
daddy-0.5.25 lib/tasks/rails_erd.rake
daddy-0.5.24 lib/tasks/rails_erd.rake
daddy-0.5.23 lib/tasks/rails_erd.rake
daddy-0.5.22 lib/tasks/rails_erd.rake
daddy-0.5.21 lib/tasks/rails_erd.rake