ctrl-u to suppress autosuggestion

ctrl-w and {ctrl,alt}-backspace do the same.
This commit is contained in:
Johannes Altmanninger
2025-01-12 07:13:43 +01:00
parent 0f4e195819
commit 33d92d2a1f

View File

@@ -2746,6 +2746,9 @@ fn handle_readline_command(&mut self, c: ReadlineCmd) {
}
assert!(end >= begin);
let len = std::cmp::max(end - begin, 1);
if elt == EditableLineTag::Commandline {
self.suppress_autosuggestion = true;
}
self.data.kill(
elt,
end - len..end,