Sha256: 9b91aa35f15d25d2ae477017621e50b1dc045462467d34a52201424a733181ba

Contents?: true

Size: 1018 Bytes

Versions: 4

Compression:

Stored size: 1018 Bytes

Contents

#!/usr/local/bin/ruby

if ARGV[0]
  ENV['RAILS_ENV'] = ARGV[0]
  puts "Loading environment..."
  if RUBY_PLATFORM =~ /mswin32/
    irb_name = "irb.bat"
  else
    irb_name = 'irb'
  end
  exec "#{irb_name} -r config/environment.rb -r irb/completion --noinspect"
else
  puts <<-HELP

NAME
     console - interact with the domain model through a environment console (on IRB)

SYNOPSIS
     console [environment]

DESCRIPTION
     Starts an environment console using IRB that lets you manipulate and interrogate
     the domain model or even trigger controller actions. The database connection and
     configuration available to the web application is already setup.
     
     Tab completion is available to see classes and methods on individual objects.
     
EXAMPLE
     console production
     
     This will initialize the production environment (as setup in config/database.yml
     and config/environments/production.rb). You would now be ready to start requiring
     models using require_dependency.
HELP
end

Version data entries

4 entries across 4 versions & 2 rubygems

Version Path
devise_sociable-0.1.0 vendor/bundle/gems/rails-0.9.5/bin/console
rails-0.9.5 bin/console
rails-0.9.4.1 bin/console
rails-0.9.4 bin/console