How to make that irb commands in the history?

I want to store the commands input in irb in the history and use them
next time. How should I do that? Thanks.

What system are you using?

Have you tried this: .irb-history - Ruby - Ruby-Forum

Vlad M_ wrote in post #1142518:

What system are you using?

Have you tried this: .irb-history - Ruby - Ruby-Forum

Thanks. I am using Linux Redhat and I can not find the file. How should
I deal with it?

Just create it in your home dir:

echo “IRB.conf[:SAVE_HISTORY] = 1000” > ~/.irbrc

.irbrc is loaded every time you start irb. It’s a plain ruby code, you
can put there anything you need for your irb session. Try searching on
the web for some examples how other people make use of .irbrc file, you
will certainly find interesting use cases.