The standard terminal commands has disappeared in irb

Hi.

When I use the irb console the standard terminal key-commands such as
Ctrl+l to clear the screen, ↑ or ↓ to select the previous commands
doesn’t work.

What is the reason of this issue? How can I fix it?

Debian GNU/Linux 5.0.3, Ruby 1.9.1, IRB 0.9.5.

Thanks.

Hi,

Am Montag, 14. Sep 2009, 21:12:54 +0900 schrieb P. A.:

When I use the irb console the standard terminal key-commands such as
Ctrl+l to clear the screen, ↑ or ↓ to select the previous commands
doesn’t work.

What is the reason of this issue? How can I fix it?

Debian GNU/Linux 5.0.3, Ruby 1.9.1, IRB 0.9.5.

`readline’ installed and working?

$ dpkg -l | grep readline

or

irb(main):001:0> require “readline”

Bertram

I have the development package for Readline called libreadline-dev on my
system. I haven’t got the Readline Ruby library (no such file to load –
readline (LoadError)). Should I recompile the Ruby with the Readline
extension included? Will irb work then?

P. A. wrote:

I have the development package for Readline called libreadline-dev on my
system. I haven’t got the Readline Ruby library (no such file to load –
readline (LoadError)). Should I recompile the Ruby with the Readline
extension included? Will irb work then?

Yes, but you don’t need to rebuild all of ruby. Just go into
ext/readline and run

ruby extconf.rb
make
make install #(as root if needed)

(and you may want to check out the recent thread about .irbrc files for
some neat tricks)

I’ve just finished installation the Readline extension using your
instructions. The realine.so library was installed in
<install_dir>/ruby-1.9.1/lib/ruby/site_ruby/1.9.1/i686-linux. I can
require it in simple ruby programs or from ruby -e "require 'readline' #=> true". Also I can use all the standard command line shortcuts in
the irb console as I wanted. But when I require ‘readline’ in irb itself
for some reason it returns the false value. Why?

I didn’t hear anything about the .irbc files thread. Could you give me
the link, please.

Understood.

Thanks a lot for your help.

P. A. wrote:

I didn’t hear anything about the .irbc files thread. Could you give me
the link, please.

Sure, here it is. Enjoy!

http://groups.google.com/group/comp.lang.ruby/browse_thread/thread/291843eaacd3f50d

On Mon, Sep 14, 2009 at 11:24 AM, P. A. [email protected] wrote:


Posted via http://www.ruby-forum.com/.

false doesn’t mean it failed it just means it wasn’t loaded (in this
case it
wasn’t loaded because it was already loaded when you started irb).


“Hey brother Christian with your high and mighty errand, Your actions
speak
so loud, I can’t hear a word you’re saying.”

-Greg Graffin (Bad Religion)

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs