I often find myself executing commands like this at bash :
history | grep ‘find’
For example to look up a fancy find / xargs command i might have ran.
Im wondering — where does the “lein repl” store its historical data ? It would be nice to know, because then I could write a leingrep.sh script, which simply grepped through the lein history session.
It is obvious that this is on disk somewhere, since history is preserved from one repl to the next.
Lein is using either readline (if you have it installed) or jline (if you are so unfortunate, I recommend installing readline). I wouldn’t bother trying to look up the history file on disk – just press Ctrl-r, type in your search text, and keep hitting Ctrl-r until you find whatever you were looking for. This is a general readline feature, and will work in any readline app (including bash).