From 0454e7a22e7d4df8914604c3fa29c930d0e54f3c Mon Sep 17 00:00:00 2001 From: Oleksiy Syvokon Date: Sat, 19 Apr 2025 14:03:13 +0300 Subject: [PATCH] terminal: Add Alt+. keybinding passthrough for last-argument recall (#29088) Alt+. is a useful terminal/readline feature that cycles through the last arguments of previous commands in history. Unlike many other shortcuts, it doesn't conflict with anything important globally, so it can be safely enabled by default. Release Notes: - N/A --- assets/keymaps/default-linux.json | 1 + assets/keymaps/default-macos.json | 1 + 2 files changed, 2 insertions(+) diff --git a/assets/keymaps/default-linux.json b/assets/keymaps/default-linux.json index cc7a55ad0a..ce7bcb2f53 100644 --- a/assets/keymaps/default-linux.json +++ b/assets/keymaps/default-linux.json @@ -920,6 +920,7 @@ "ctrl-enter": "assistant::InlineAssist", "alt-b": ["terminal::SendText", "\u001bb"], "alt-f": ["terminal::SendText", "\u001bf"], + "alt-.": ["terminal::SendText", "\u001b."], // Overrides for conflicting keybindings "ctrl-b": ["terminal::SendKeystroke", "ctrl-b"], "ctrl-c": ["terminal::SendKeystroke", "ctrl-c"], diff --git a/assets/keymaps/default-macos.json b/assets/keymaps/default-macos.json index 71a144f5b7..536a7d0ae1 100644 --- a/assets/keymaps/default-macos.json +++ b/assets/keymaps/default-macos.json @@ -1005,6 +1005,7 @@ "alt-right": ["terminal::SendText", "\u001bf"], "alt-b": ["terminal::SendText", "\u001bb"], "alt-f": ["terminal::SendText", "\u001bf"], + "alt-.": ["terminal::SendText", "\u001b."], // There are conflicting bindings for these keys in the global context. // these bindings override them, remove at your own risk: "up": ["terminal::SendKeystroke", "up"],