[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/consult aa8c50e 2/2: Emacs 28: Add completion-predicate
From: |
ELPA Syncer |
Subject: |
[elpa] externals/consult aa8c50e 2/2: Emacs 28: Add completion-predicate |
Date: |
Thu, 22 Jul 2021 06:57:08 -0400 (EDT) |
branch: externals/consult
commit aa8c50ec08e7960d5db77e59690bc672b4e567d5
Author: Daniel Mendler <mail@daniel-mendler.de>
Commit: Daniel Mendler <mail@daniel-mendler.de>
Emacs 28: Add completion-predicate
---
consult.el | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/consult.el b/consult.el
index 259bee9..1afd7b4 100644
--- a/consult.el
+++ b/consult.el
@@ -1221,6 +1221,10 @@ to make it available for commands with narrowing."
(when-let (widen (consult--widen-key))
(define-key map widen (cons "All" #'consult-narrow))))
+;; Emacs 28: hide in M-X
+(put #'consult-narrow-help 'completion-predicate #'ignore)
+(put #'consult-narrow 'completion-predicate #'ignore)
+
;;;; Splitting completion style
(defun consult--split-perl (str point)
@@ -3304,6 +3308,10 @@ In order to select from a specific HISTORY, pass the
history variable as argumen
(interactive)
(consult-isearch-forward (not reverse)))
+;; Emacs 28: hide in M-X
+(put #'consult-isearch-backward 'completion-predicate #'ignore)
+(put #'consult-isearch-forward 'completion-predicate #'ignore)
+
(defvar consult-isearch-map
(let ((map (make-sparse-keymap)))
(define-key map [remap isearch-forward] #'consult-isearch-forward)