branch: master commit e525bbec4b2768c263a754c4a67d1747e5536741 Author: Michael Heerdegen <michael_heerde...@web.de> Commit: Michael Heerdegen <michael_heerde...@web.de>
[el-search] Add bindings for first/last match jumping * packages/el-search/el-search.el (el-search-loop-over-bindings): Add bindings for < and > (to 'el-search-from-beginning' and 'el-search-last-buffer-match'). (el-search-keep-transient-map-commands): Add 'el-search-last-buffer-match' to the list. (el-search-prefix-key-transient-map): Add 'el-search-last-buffer-match' as well. Add the new bindings to the binding listing in the file header. --- packages/el-search/el-search.el | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/packages/el-search/el-search.el b/packages/el-search/el-search.el index 19acf3d..462a67b 100644 --- a/packages/el-search/el-search.el +++ b/packages/el-search/el-search.el @@ -106,10 +106,13 @@ ;; Prompt for a directory name and skip all subsequent files ;; located under this directory. ;; -;; C-A, M-s e a (el-search-from-beginning) -;; Go back to the first match in this buffer or (with prefix arg) -;; completely restart the current search from the first file or -;; buffer. +;; C-A, M-s e a, M-s e < (el-search-from-beginning) +;; Go back to the first match in this buffer or (with positive +;; prefix arg) completely restart the current search from the +;; first file or buffer. +;; +;; With negative prefix arg, or with >, go to the last match in +;; the current buffer. ;; ;; C-J, M-s e j (el-search-jump-to-search-head) ;; Resume the last search from the position of the last visited @@ -530,6 +533,7 @@ The default value is ask-multi." el-search-pattern-backward el-search-jump-to-search-head el-search-from-beginning + el-search-last-buffer-match el-search-skip-directory el-search-continue-in-next-buffer universal-argument universal-argument-more @@ -1614,6 +1618,8 @@ in, in order, when called with no arguments." (keybind emacs-lisp-mode-map ?h #'el-search-this-sexp) ;h like in "highlight" or "here" (keybind global-map ?j #'el-search-jump-to-search-head) (keybind global-map ?a #'el-search-from-beginning) + (keybind global-map ?< #'el-search-from-beginning) + (keybind global-map ?> #'el-search-last-buffer-match) (keybind global-map ?d #'el-search-skip-directory) (keybind global-map ?n #'el-search-continue-in-next-buffer) @@ -1648,6 +1654,7 @@ in, in order, when called with no arguments." el-search-pattern-backward el-search-query-replace el-search-from-beginning + el-search-last-buffer-match el-search-skip-directory el-search-continue-in-next-buffer el-search-occur))