Make irb remember your history with the irbrc
By admin
I always forget this one too. To make ruby's irb remember commands you entered in the last session(s), you need to add the following lines to /home/kenglish/.irbrc:
require 'irb/completion'
require 'irb/ext/save-history'
IRB.conf[:SAVE_HISTORY] = 100
IRB.conf[:HISTORY_FILE] = “#{ENV['HOME']}/.irb-save-history”
IRB.conf[:PROMPT_MODE] = :SIMPLE
Isn't IRB-RC an awesome name for a file?
isn't Camber First



September 17th, 2008