Most repl's I've used before allow you to quickly get a previous command back by using the Ctrl+r key to search the command history. It makes life so much easier when you're testing stuff out. Any chance this could be implemented for the nodejs repl?
I'd prefer something a bit more smart like https://github.com/zsh-users/zsh-history-substring-search.
Basically, it makes up arrows trigger a substring-based search with what is written on the command line and subsequently lets you use up/down arrows to flip through results. I think it's clearly superior to bash's CTRL-R.
Hi
Anyone working on this?
Can I take it up?
@someone-1 there is a stalled PR by @antsmartian (#24335). @antsmartian do you have some time to have a look at that soon again? Otherwise @someone-1 could maybe go ahead and work on it?
I think we should decide whether it'll be CTRL-R or substring-based, or both. I guess substring shouldn't be too hard to implement. CTRL-R is more involved as you need to replace prompt etc.
I'm happy with either.
@BridgeAR Yes, its stalled for sometime. Soon, will have a look at it.
Taken care by: https://github.com/nodejs/node/issues/31006
Reopened to keep the feature request for the substring-based search as suggested by @silverwind
@BridgeAR: I don't quite get what is meant by substring-based search.
@antsmartian if you press up or down in ZSH after writing a few characters triggers a history search that takes the already written part as start of the search string. So only history entries will come up that match the input.
We should probably rewrite the issue title if it's no longer about ctrl+r
Most helpful comment
We should probably rewrite the issue title if it's no longer about ctrl+r