Sha256: 8c2501ea1bebae497af5423103740db17c13751b012a0b61baa7961cb5657962

Contents?: true

Size: 513 Bytes

Versions: 1

Compression:

Stored size: 513 Bytes

Contents

require "rails/generators"

module Rails
  module Command
    class DestroyCommand < Base # :nodoc:
      no_commands do
        def help
          Rails::Generators.help self.class.command_name
        end
      end

      def perform(*)
        generator = args.shift
        return help unless generator

        require_application_and_environment!
        load_generators

        Rails::Generators.invoke generator, args, behavior: :revoke, destination_root: Rails::Command.root
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
railties-5.1.0.rc1 lib/rails/commands/destroy/destroy_command.rb