Last Updated: February 25, 2016
·
3.29K
· dan2552

View your recent command history in Rails Console

> puts Readline::HISTORY.entries.split("exit").last[0..-2].join("\n")

1 Response
Add your response

thankyou. i was able to get what i wanted by doing:

Readline::HISTORY.entries.each { |c| puts c }

over 1 year ago ·