Rails engine which will give you a quick display of your database schema and contents for reference
Adds an html endpoint to your Rails application which will give you a quick display of your database schema and contents for reference at
Demo available at http://rails-db-info-demo.herokuapp.com
Add this to the development group in your Gemfile
group :development do gem 'rails_db_info' end
http://localhost:3000/rails/info/dband you will see your database schema and values.
If (and only if) you have catch all routes like
get '*path' => 'your_controller#your_action'in your app already, you can manually add railsdbinfo to your routes (config/routes.rb) before the catch-all routes like this.
if Rails.env.development? mount_rails_db_info as: 'rails_db_info_engine' # mount_rails_db_info is enough for rails version < 4 end get '*path' => 'your_controller#your_action'
Contributions welcome :)
$ RAILS_ENV=test bundle exec rake db:migrate $ bundle exec rake
To run tests for specific rails version use custom Gemfile from gemfiles folder
$ BUNDLE_GEMFILE=gemfiles/rails_3-2-stable.gemfile bundle install $ BUNDLE_GEMFILE=gemfiles/rails_3-2-stable.gemfile bundle exec rake
This project rocks and uses MIT-LICENSE.