diff options
| author | Christoph Göttschkes <christoph.goettschkes@posteo.net> | 2025-11-24 20:27:44 +0100 |
|---|---|---|
| committer | James <1227856+jojojames@users.noreply.github.com> | 2026-04-16 23:15:16 -0700 |
| commit | 621826c4c9d91e81e62ab207fc50b4d37bceff2b (patch) | |
| tree | e38c3dfe6c0b805fd9d4f86b43306f02ed5b716c | |
| parent | 4ad1646964638322302dfb167aec40a2455bfb78 (diff) | |
eshell: Remove binding to obsolete function eshell-bol
Starting with Emacs 30.1, eshell uses 'field' properties for its
output. This means that functions like beginning-of-line and
move-beginning-of-line now behave as expected, and the function
eshell-bol is marked obsolete.
| -rw-r--r-- | modes/eshell/evil-collection-eshell.el | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/modes/eshell/evil-collection-eshell.el b/modes/eshell/evil-collection-eshell.el index cb261dc..84d55a3 100644 --- a/modes/eshell/evil-collection-eshell.el +++ b/modes/eshell/evil-collection-eshell.el @@ -108,8 +108,6 @@ appropriate in some cases like terminals." (kbd "C-j") 'eshell-next-prompt "gk" 'eshell-previous-prompt "gj" 'eshell-next-prompt - "0" 'eshell-bol - "^" 'eshell-bol (kbd "M-h") 'eshell-backward-argument (kbd "M-l") 'eshell-forward-argument @@ -123,6 +121,11 @@ appropriate in some cases like terminals." "d" 'evil-collection-eshell-evil-delete "D" 'evil-collection-eshell-evil-delete-line) + (when (< emacs-major-version 30) + (evil-collection-define-key 'normal 'eshell-mode-map + "0" 'eshell-bol + "^" 'eshell-bol)) + (when evil-want-C-u-delete (evil-collection-define-key 'insert 'eshell-mode-map (kbd "C-u") 'eshell-kill-input)) @@ -135,9 +138,12 @@ appropriate in some cases like terminals." (kbd "C-k") 'eshell-previous-prompt (kbd "C-j") 'eshell-next-prompt "gk" 'eshell-previous-prompt - "gj" 'eshell-next-prompt - "0" 'eshell-bol - "^" 'eshell-bol) + "gj" 'eshell-next-prompt) + + (when (< emacs-major-version 30) + (evil-collection-define-key 'visual 'eshell-mode-map + "0" 'eshell-bol + "^" 'eshell-bol)) (evil-normalize-keymaps) (unless evil-collection-always-run-setup-hook-after-load |
