aboutsummaryrefslogtreecommitdiffstats
path: root/railties/lib/rails/commands
diff options
context:
space:
mode:
authorKasper Timm Hansen <kaspth@gmail.com>2019-01-16 22:01:10 +0100
committerGitHub <noreply@github.com>2019-01-16 22:01:10 +0100
commit90536ebfb3f0ca6971bc3ea4e43f20b8e977539b (patch)
tree8eb4807d949160d38a3d239ea33d37318d38b5aa /railties/lib/rails/commands
parent7e52e3b1c004eb22521c844b6adf69a2689cc1da (diff)
parentcb3f78aa7c8f14921501703ed0780f2a428bc6a1 (diff)
downloadrails-90536ebfb3f0ca6971bc3ea4e43f20b8e977539b.tar.gz
rails-90536ebfb3f0ca6971bc3ea4e43f20b8e977539b.tar.bz2
rails-90536ebfb3f0ca6971bc3ea4e43f20b8e977539b.zip
Merge pull request #34832 from gmcgibbon/db_system_change_command
Add rails db:system:change command
Diffstat (limited to 'railties/lib/rails/commands')
-rw-r--r--railties/lib/rails/commands/db/system/change/change_command.rb20
1 files changed, 20 insertions, 0 deletions
diff --git a/railties/lib/rails/commands/db/system/change/change_command.rb b/railties/lib/rails/commands/db/system/change/change_command.rb
new file mode 100644
index 0000000000..760c229c07
--- /dev/null
+++ b/railties/lib/rails/commands/db/system/change/change_command.rb
@@ -0,0 +1,20 @@
+# frozen_string_literal: true
+
+require "rails/generators"
+require "rails/generators/rails/db/system/change/change_generator"
+
+module Rails
+ module Command
+ module Db
+ module System
+ class ChangeCommand < Base # :nodoc:
+ class_option :to, desc: "The database system to switch to."
+
+ def perform
+ Rails::Generators::Db::System::ChangeGenerator.start
+ end
+ end
+ end
+ end
+ end
+end