Closed TorosFanny closed 8 years ago
See the instructions here for the "keyseq" option: http://trac.haskell.org/haskeline/wiki/CustomKeyBindings
Specifically, the instructions for ctrl-left/right should also work for home/end. Let me know whether that works for you.
Yeah, ctrl-left/right
works for me as pressing home/end
, but I can't bind ctrl-home/end
to any key. It seems that, haskline blocks my home/end
.
I finally worked out by this.
keyseq: "\ESCOH" home
keyseq: "\ESCOF" end
Thank you for your help. Buf it's really strange that haskeline
blocks home/end
, is that a bug?
You're right, on second look it should be picking up the home/end keys automatically. Most likely this is a configuration issue with your terminal; what are the outputs of the following commands?
echo $TERM
infocmp
ghc -e 'System.Console.Terminfo.setupTermFromEnv >>= print . flip System.Console.Terminfo.getCapability System.Console.Terminfo.keyHome'
On my machine (Mac), the first is xterm-256color
, the second contains khome=\EOH
, and the third prints Just "\ESCOH"
. That's the information that lets Haskeline know the control sequences for the home key.
A: I tried ghci in virtual box with Ubuntu 15.10, and home/end
behaves normally. But, I'm not sure if Ubuntu 14.04 is borned with this issue or because of my configuration.
B: The first is empty. The second contain's home=\E[H
but no for end
. The third is just Nothing
Hi folks, https://github.com/unisonweb/unison/issues/3418 seems to match this issue precisely and I'm still affected, 7 years later, could you reopen it?
@judah the diagnostic snippet you've posted outputs exactly the same values on my machine except I'm running openSUSE Tumbleweed 20221008. I'd like to get to the bottom of the issue, any suggestions how to proceed?
I simply write a
~/.haskeline
file like the following for a test.It shows that my
ghci
seems to ignore myhome
andend
press absolutely.So how could I send
home
andend
key tohaskline
? I have being suffering from the lack of support forend
key andhome
key ofghci
for a long time.Is any thing wrong with my environment? My laptop: