diff options
-rw-r--r-- | README.md | 51 |
1 files changed, 35 insertions, 16 deletions
@@ -1,31 +1,50 @@ -# DBShell::Rails +dbshell-rails +============= + +A Rake task to launch a database shell, using the connection parameters +specified in your Rails application. The shell will be automatically connected +to the current environment's database. + +The following databases are supported: + +* PostgreSQL (runs `psql`) +* MySQL (runs `mysql`) +* SQLite (runs `sqlite3`) + +After being a Djangonaut for a while and then doing more work in Rails, I was +surprised that it apparently has no equivalent to Django's +`./manage.py dbshell` command. This launcher program aims to provide that +missing functionality. + + +## Usage + + $ rake dbshell + example_app_development=# + + $ rails dbshell + example_app_development=# + + $ RAILS_ENV=test rake dbshell + example_app_test=# -TODO: Write a gem description ## Installation Add this line to your application's Gemfile: -```ruby +``` ruby gem 'dbshell-rails' ``` And then execute: - $ bundle + $ bundle -Or install it yourself as: - - $ gem install dbshell-rails - -## Usage +Or install it yourself with: -TODO: Write usage instructions here + $ gem install dbshell-rails -## Contributing -1. Fork it ( https://github.com/[my-github-username]/dbshell-rails/fork ) -2. Create your feature branch (`git checkout -b my-new-feature`) -3. Commit your changes (`git commit -am 'Add some feature'`) -4. Push to the branch (`git push origin my-new-feature`) -5. Create a new Pull Request +## License +Licensed under the MIT License. See the included LICENSE.txt file. |