mirror of
https://github.com/fish-shell/fish-shell.git
synced 2024-11-26 19:03:38 +08:00
Don't translate \n to enter
Apparently it's never entere because we turn off ICRNL. I'm not sure why it says "no binding found".
This commit is contained in:
parent
53961c7759
commit
b04dee358e
|
@ -376,7 +376,7 @@ impl BuiltinBind {
|
|||
streams.err.append(wgettext_fmt!(
|
||||
"%ls: No binding found for key '%ls'\n",
|
||||
cmd,
|
||||
eseq
|
||||
seq[0]
|
||||
));
|
||||
} else {
|
||||
streams.err.append(wgettext_fmt!(
|
||||
|
|
|
@ -148,7 +148,7 @@ fn ascii_control(c: char) -> char {
|
|||
}
|
||||
|
||||
pub(crate) fn canonicalize_keyed_control_char(c: char) -> char {
|
||||
if c == ascii_control('m') || c == ascii_control('j') {
|
||||
if c == ascii_control('m') {
|
||||
return Enter;
|
||||
}
|
||||
if c == ascii_control('i') {
|
||||
|
|
|
@ -113,4 +113,11 @@ bind tab
|
|||
bind ctrl-\b
|
||||
# CHECKERR: bind: Cannot add control modifier to control character 'ctrl-h'
|
||||
|
||||
# Either Return or ctrl-m.
|
||||
bind \r
|
||||
# CHECK: bind --preset enter execute
|
||||
# Never Return, probably always ctrl-j.
|
||||
bind \n 2>&1
|
||||
# CHECK: bind: No binding found for key 'ctrl-j'
|
||||
|
||||
exit 0
|
||||
|
|
Loading…
Reference in New Issue
Block a user