>From 645aa7e78991adcf32dc4467ab397762f90fc859 Mon Sep 17 00:00:00 2001 From: Brian Leung Date: Tue, 8 Nov 2022 23:18:23 -0800 Subject: [PATCH 2/2] shell: Add repeat-map for shell-{forward,backward}-prompt * lisp/shell.el (shell-repeat-map): New defvar. --- lisp/shell.el | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/lisp/shell.el b/lisp/shell.el index 641f274045..180a338216 100644 --- a/lisp/shell.el +++ b/lisp/shell.el @@ -393,6 +393,14 @@ shell-mode-map 'complete-expand) map)) +(defvar-keymap shell-repeat-map + :doc "Keymap to repeat eshell-command key sequences. Used in `repeat-mode'." + "C-f" #'shell-forward-command + "C-b" #'shell-backward-command) + +(put #'shell-forward-command 'repeat-map 'shell-repeat-map) +(put #'shell-backward-command 'repeat-map 'shell-repeat-map) + (defcustom shell-mode-hook '() "Hook for customizing Shell mode." :type 'hook -- 2.38.1