mirror of https://github.com/Hilbis/Hilbish
fix: move cursor to end of line on history search (closes #121)
parent
754a63c74b
commit
f27d60f827
|
@ -626,6 +626,8 @@ func (rl *Instance) escapeSeq(r []rune) {
|
||||||
}
|
}
|
||||||
rl.mainHist = true
|
rl.mainHist = true
|
||||||
rl.walkHistory(1)
|
rl.walkHistory(1)
|
||||||
|
moveCursorForwards(len(rl.line) - rl.pos)
|
||||||
|
rl.pos = len(rl.line)
|
||||||
|
|
||||||
case seqDown:
|
case seqDown:
|
||||||
if rl.modeTabCompletion {
|
if rl.modeTabCompletion {
|
||||||
|
@ -637,6 +639,8 @@ func (rl *Instance) escapeSeq(r []rune) {
|
||||||
}
|
}
|
||||||
rl.mainHist = true
|
rl.mainHist = true
|
||||||
rl.walkHistory(-1)
|
rl.walkHistory(-1)
|
||||||
|
moveCursorForwards(len(rl.line) - rl.pos)
|
||||||
|
rl.pos = len(rl.line)
|
||||||
|
|
||||||
case seqForwards:
|
case seqForwards:
|
||||||
if rl.modeTabCompletion {
|
if rl.modeTabCompletion {
|
||||||
|
|
Loading…
Reference in New Issue