Reputation: 41
I am creating a script (in Lisp, though this can apply to any language with a REPL) which users interface with using the language's REPL. But this does not include even basic interactive features like remembering history. I am wondering if it is possible to tell a terminal emulator to interpret commands using an arbitrary language, instead of the built-in language.
Thanks!
Upvotes: 0
Views: 116
Reputation: 631
Yet another approach might be to start the editor emacs, run
M-x shell
and in this shell run your Lisp REPL. You get a lot of feature for free, like command history.
Upvotes: 1
Reputation: 41
OK, follwoing the advice of user2864740, I looked at GNU Readline, which is the library the provides much of the functionality that I'm looking for. I'm going to switch to Guile Scheme instead of Common Lisp since Guile supports Readline out of the box. However, it looks like it can work in Common Lisp as well: http://www.cliki.net/sb-readline
Upvotes: 1