aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorTeddy Wing2017-04-29 23:43:01 +0200
committerTeddy Wing2017-04-29 23:43:01 +0200
commit96ffac15299beca07a0671cdbed13b137a9aa4c4 (patch)
treec41a1a022fb68a777108fcd62ad3a5207d9ed98e /lib
parent3c522fc313f76dfbb7d1e87703965780245a432c (diff)
downloaddbshell-rails-96ffac15299beca07a0671cdbed13b137a9aa4c4.tar.bz2
dbshell.rake: Add alias to `rake db:shell`
Provide two ways of accessing the task. One saves a character (":") and is reminiscent of the Django command that this project is inspired by. The other is more Rails-like and is consistent with the other `db:`-prefixed Rails Rake tasks.
Diffstat (limited to 'lib')
-rw-r--r--lib/dbshell/rails/tasks/dbshell.rake5
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/dbshell/rails/tasks/dbshell.rake b/lib/dbshell/rails/tasks/dbshell.rake
index cc898a4..44d7948 100644
--- a/lib/dbshell/rails/tasks/dbshell.rake
+++ b/lib/dbshell/rails/tasks/dbshell.rake
@@ -7,3 +7,8 @@ task :dbshell do
Rails.application.config.database_configuration[env]
)
end
+
+# Alias 'dbshell' to 'db:shell'
+namespace :db do
+ task shell: :dbshell
+end