aboutsummaryrefslogtreecommitdiffstats
path: root/railties/lib/rails/commands/destroy.rb
blob: 9023c61bf243fabfdba02483ec9ac0522aaac6dc (plain) (blame)
1
2
3
4
5
6
7
8
9
require 'rails/generators'

if [nil, "-h", "--help"].include?(ARGV.first)
  Rails::Generators.help 'destroy'
  exit
end

name = ARGV.shift
Rails::Generators.invoke name, ARGV, :behavior => :revoke, :destination_root => Rails.root