16 lines
280 B
Ruby
16 lines
280 B
Ruby
require "rails/command"
|
|
|
|
aliases = {
|
|
"g" => "generate",
|
|
"d" => "destroy",
|
|
"c" => "console",
|
|
"s" => "server",
|
|
"db" => "dbconsole",
|
|
"r" => "runner",
|
|
"t" => "test"
|
|
}
|
|
|
|
command = ARGV.shift
|
|
command = aliases[command] || command
|
|
|
|
Rails::Command.invoke command, ARGV
|