method

console

rails latest stable - Class: Rails::CommandsTasks

Method deprecated or moved

This method is deprecated or moved on the latest stable version. The last existing version (v5.0.0.1) is shown here.

console()
public

No documentation available.

# File railties/lib/rails/commands/commands_tasks.rb, line 67
    def console
      require_command!("console")
      options = Rails::Console.parse_arguments(argv)

      # RAILS_ENV needs to be set before config/application is required
      ENV['RAILS_ENV'] = options[:environment] if options[:environment]

      # shift ARGV so IRB doesn't freak
      shift_argv!

      require_application_and_environment!
      Rails::Console.start(Rails.application, options)
    end