I am working on an Emacs extension for using the Julia REPL inside
Emacs. Since debugging with Gallium needs more terminal capabilities
than ESS allows, I am basing it on term.el.
By default, term in Emacs sends cursor keys as \eOA, \eOB, ... for up,
down, ... . I found that I need to change them to \e[A and \e[B to make
the Julia REPL recall history correctly.
I don't know much about terminals, so mostly I found this out by
experiment. I am wondering though if either term.el, Julia's readline,
or something in between is behaving incorrectly. As far as I understand,
term.el advertises keys correctly:
_ _ _(_)_ | A fresh approach to technical computing
(_) | (_) (_) | Documentation: http://docs.julialang.org
_ _ _| |_ __ _ | Type "?help" for help.
| | | | | | |/ _` | |
| | |_| | | | (_| | | Version 0.5.0 (2016-09-19 18:14 UTC)
_/ |\__'_|_|_|\__'_| | Official http://julialang.org/
|__/ | x86_64-pc-linux-gnu
If anyone is interested, preliminary code for the minor mode is here:
Can be used in with julia-emacs.
Any help or advice would be appreciated (again, I know little about how
these things are supposed to work).