emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] externals/consult 2e1c45d1bd 1/2: Version 0.31


From: ELPA Syncer
Subject: [elpa] externals/consult 2e1c45d1bd 1/2: Version 0.31
Date: Fri, 6 Jan 2023 14:57:30 -0500 (EST)

branch: externals/consult
commit 2e1c45d1bda9b4c9746d2a4f107b9689218d1083
Author: Daniel Mendler <mail@daniel-mendler.de>
Commit: Daniel Mendler <mail@daniel-mendler.de>

    Version 0.31
---
 CHANGELOG.org |  8 ++------
 consult.el    | 60 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++-
 2 files changed, 61 insertions(+), 7 deletions(-)

diff --git a/CHANGELOG.org b/CHANGELOG.org
index bb8a212492..8df2bdcfcb 100644
--- a/CHANGELOG.org
+++ b/CHANGELOG.org
@@ -2,13 +2,9 @@
 #+author: Daniel Mendler
 #+language: en
 
-* Development
+* Version 0.31 (2023-01-06)
 
-- Drop obsolete =consult-apropos=. Alternative: =describe-symbol= in 
combination
-  with =embark-export=.
-- Drop obsolete =consult-multi-occur=. Alternative: Built-in =multi-occur=,
-  =multi-occur-in-matching-buffers= or =consult-line-multi=.
-- Drop obsolete =consult-file-externally=. Alternative: 
=embark-open-externally=.
+- Version bump to update the Compat package dependency (29.1.0.1)
 
 * Version 0.30 (2023-01-02)
 
diff --git a/consult.el b/consult.el
index dbb21fbdc8..cd8d6975ef 100644
--- a/consult.el
+++ b/consult.el
@@ -5,7 +5,7 @@
 ;; Author: Daniel Mendler and Consult contributors
 ;; Maintainer: Daniel Mendler <mail@daniel-mendler.de>
 ;; Created: 2020
-;; Version: 0.30
+;; Version: 0.31
 ;; Package-Requires: ((emacs "27.1") (compat "29.1.0.1"))
 ;; Homepage: https://github.com/minad/consult
 
@@ -4858,6 +4858,64 @@ the asynchronous search."
         :add-history (consult--async-split-thingatpt 'symbol)
         :history '(:input consult--man-history))))
 
+;;;; Obsolete commands
+
+;;;###autoload
+(defun consult-apropos ()
+  "Select pattern and call `apropos'.
+
+The default value of the completion is the symbol at point. As a better
+alternative, you can run `embark-export' from commands like `M-x' and
+`describe-symbol'."
+  (interactive)
+  (let ((pattern
+         (consult--read
+          obarray
+          :prompt "consult-apropos (obsolete): "
+          :predicate (lambda (x) (or (fboundp x) (boundp x) (facep x) 
(symbol-plist x)))
+          :category 'symbol
+          :default (thing-at-point 'symbol))))
+    (when (string= pattern "")
+      (user-error "No pattern given"))
+    (apropos pattern)))
+
+(make-obsolete
+ 'consult-apropos
+ "consult-apropos has been deprecated in favor of Embark actions:
+M-x describe-symbol <regexp> M-x embark-export
+M-x describe-symbol <regexp> M-x embark-act a"
+               "0.20")
+
+;;;###autoload
+(defun consult-file-externally (file)
+  "Open FILE externally using the default application of the system."
+  (interactive "fOpen externally: ")
+  (if (and (eq system-type 'windows-nt)
+           (fboundp 'w32-shell-execute))
+      (w32-shell-execute "open" file)
+    (call-process (pcase system-type
+                    ('darwin "open")
+                    ('cygwin "cygstart")
+                    (_ "xdg-open"))
+                  nil 0 nil
+                  (expand-file-name file))))
+
+(make-obsolete 'consult-file-externally 'embark-open-externally "0.29")
+
+;;;###autoload
+(defun consult-multi-occur (bufs regexp &optional nlines)
+  "Improved version of `multi-occur' based on `completing-read-multiple'.
+
+See `multi-occur' for the meaning of the arguments BUFS, REGEXP and NLINES."
+  (interactive (cons
+                (mapcar #'get-buffer
+                        (completing-read-multiple "Buffer: "
+                                                  #'internal-complete-buffer))
+                (occur-read-primary-args)))
+  (occur-1 regexp nlines bufs))
+
+(make-obsolete 'consult-multi-occur 'consult-line-multi "0.29")
+
 ;;;; Preview at point in completions buffers
 
 (define-minor-mode consult-preview-at-point-mode



reply via email to

[Prev in Thread] Current Thread [Next in Thread]