The 'script/console' command does not work

Bug #69797 reported by Caleb Perkins
6
Affects Status Importance Assigned to Milestone
rails (Ubuntu)
Invalid
Undecided
Unassigned

Bug Description

When running 'script/console' from any Rails application directory, the terminal window will say there is an error in the /usr/share/rails/railties/lib/commands/console.rb file on line 25: the specified file or directory was not found. This happens because the console.rb file specifies the 'irb' command on the first line, which has been replaced by irb[RUBY_VERSION] in Edgy. Simply replacing

irb = RUBY_PLATFORM =~ /mswin32/ ? 'irb.bat' : 'irb'

with

irb = RUBY_PLATFORM =~ /mswin32/ ? 'irb.bat' : 'irb1.8'

for Ruby 1.8 or irb1.9 for Ruby 1.9 corrects the problem.

How to reproduce:
1. Open the terminal and cd to the root of a Rails application.
2. Type script/console

Revision history for this message
Rocco Stanzione (trappist) wrote :

The 'irb' command is provided by the irb package (separate from the irb1.8 package), which is (approriately) a 'recommends' package for rails, since most rails features will function without it.

Changed in rails:
status: Unconfirmed → Rejected
Revision history for this message
Simon Wong (wongy) wrote :

This is a problem for my Rails Web Server.

The irb package should create a symlink in the same way that the ruby package creates a symlink for "ruby".

/usr/bin/irb -> /usr/bin/irb1.8

I am going to head over to the irb package now...

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.