# Up and down keys not working in IRB

**URL:** <https://www.ruby-forum.com/t/up-and-down-keys-not-working-in-irb/107128>\
**Category:** Ruby\
**Created:** [June 18, 2007, 1:40pm UTC](https://www.ruby-forum.com/t/up-and-down-keys-not-working-in-irb/107128 "2007-06-18T13:40:51Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![vfcforums](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/v/85e7bf/32.png) [@vfcforums](https://www.ruby-forum.com/u/vfcforums)\
**Post date:** [June 18, 2007, 1:40pm UTC](https://www.ruby-forum.com/t/up-and-down-keys-not-working-in-irb/107128/1 "2007-06-18T13:40:51Z")

</div>

The up and down keys need to get the command history is not working in  
IRB.

They produce ^[[A, ^[[B, ^[[C etc. I am connecting over PuTTY to Fedora  
6and I wonder whether the problem is in IRB.

If after logging in to the Fedora 6 account, I login to my dreamhost  
account and run IRB the keys work fine. I compiled the ruby with  
readline and I suspect that something didn’t go right.

Is there some way of checking it?

---

<div class="post-metadata">

**Author:** ![vfcforums](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/v/85e7bf/32.png) [@vfcforums](https://www.ruby-forum.com/u/vfcforums)\
**Post date:** [June 18, 2007, 6:20pm UTC](https://www.ruby-forum.com/t/up-and-down-keys-not-working-in-irb/107128/2 "2007-06-18T18:20:34Z")

</div>

On 6/18/07, Frank C. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> Is there some way of checking it?

Replace /usr/local/build/ruby-1.8.6 with your ruby build directory  
below.

$ irb  
irb(main):001:0\> $LOADED\_FEATURES.grep /readline/  
=\> [“readline.so”]  
irb(main):002:0\> require ‘readline’ #already loaded, so should return  
false  
=\> false  
irb(main):003:0\> exit  
$ less /usr/local/build/ruby-1.8.6/ext/readline/mkmf.log

hth,  
Todd
