mirror of https://github.com/chzyer/readline.git
Support <Home>/<End> Keyboard keys for PuTTY
When my SSH and telnet client is PuTTY, the readline-demo can't parse <Home>/<End> Keyboard keys!!! It seems that "readline" can't adapt to old shells very well.
This commit is contained in:
parent
2972be24d4
commit
80ba91f1a8
7
utils.go
7
utils.go
|
@ -113,8 +113,13 @@ func escapeExKey(key *escapeKeyPair) rune {
|
||||||
case 'F':
|
case 'F':
|
||||||
r = CharLineEnd
|
r = CharLineEnd
|
||||||
case '~':
|
case '~':
|
||||||
if key.attr == "3" {
|
switch key.attr {
|
||||||
|
case "1":
|
||||||
|
r = CharLineStart
|
||||||
|
case "3":
|
||||||
r = CharDelete
|
r = CharDelete
|
||||||
|
case "4":
|
||||||
|
r = CharLineEnd
|
||||||
}
|
}
|
||||||
default:
|
default:
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue