[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/ivy-hydra 3d9c222 069/395: swiper.el (swiper--query-rep
From: |
Basil L. Contovounesios |
Subject: |
[elpa] externals/ivy-hydra 3d9c222 069/395: swiper.el (swiper--query-replace-updatefn): Fix |
Date: |
Thu, 25 Feb 2021 08:31:33 -0500 (EST) |
branch: externals/ivy-hydra
commit 3d9c2223e372657732a5959f465b7d835a6bf130
Author: Oleh Krehel <ohwoeowho@gmail.com>
Commit: Oleh Krehel <ohwoeowho@gmail.com>
swiper.el (swiper--query-replace-updatefn): Fix
Now when using \,() style of replacement, the replacements are
correct, instead of using the replacement of the last match.
---
swiper.el | 18 +++++++-----------
1 file changed, 7 insertions(+), 11 deletions(-)
diff --git a/swiper.el b/swiper.el
index 687e1e9..1635585 100644
--- a/swiper.el
+++ b/swiper.el
@@ -149,20 +149,16 @@ Treated as non-nil when searching backwards."
(defun swiper--query-replace-updatefn ()
(let ((lisp (ignore-errors (nth 2 (query-replace-compile-replacement
ivy-text t)))))
(dolist (ov swiper--query-replace-overlays)
- (when lisp
- (dolist (x (overlay-get ov 'matches))
- (setq lisp (cl-subst (cadr x) (car x) lisp :test #'equal)))
- (setq lisp (ignore-errors (eval lisp))))
(overlay-put
ov 'after-string
(propertize
- (if (stringp lisp)
- lisp
- (set-match-data (overlay-get ov 'md))
- (condition-case nil
- (with-current-buffer (overlay-buffer ov)
- (match-substitute-replacement ivy-text))
- (error ivy-text)))
+ (condition-case nil
+ (with-current-buffer (overlay-buffer ov)
+ (set-match-data (overlay-get ov 'md))
+ (if (consp lisp)
+ (eval lisp)
+ (match-substitute-replacement ivy-text)))
+ (error ivy-text))
'face 'error)))))
(defun swiper--query-replace-cleanup ()
- [elpa] externals/ivy-hydra 136ae0e 194/395: Add command for play/pause current song, (continued)
- [elpa] externals/ivy-hydra 136ae0e 194/395: Add command for play/pause current song, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra a0063ce 224/395: ivy.el (ivy--done): Revert ivy-set-text, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra 5c951e2 245/395: * counsel.el: Add comment on xor compatibility, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra 1396d7b 024/395: counsel.el (counsel-grep): Obey ivy-case-fold-search-default, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra 2ccda7e 044/395: ivy.el (ivy--directory-done): Fix "Host name must not match method ssh", Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra a7ae5f0 058/395: counsel.el (counsel-geiser-doc-look-up-manual): Add., Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra 13a1b87 059/395: ivy.el (ivy-minibuffer-map): Bind "M-a" to ivy-toggle-marks, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra 49335d2 060/395: Allow to use window configurations for ivy views, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra 0f61cc5 065/395: Add support for browising compilation errors, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra 2fb4c9f 061/395: Update test instructions, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra 3d9c222 069/395: swiper.el (swiper--query-replace-updatefn): Fix,
Basil L. Contovounesios <=
- [elpa] externals/ivy-hydra c7973a8 083/395: counsel.el (counsel-set-variable): Fix killing the expression, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra e7eca37 085/395: counsel.el (counsel-switch-buffer-preview-virtual-buffers): Add, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra eae1ccf 086/395: ivy.el (ivy-auto-shrink-minibuffer): New defcustom, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra f16e6e2 094/395: counsel.el (counsel-flycheck-errors-cands): Show the error, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra 400a900 265/395: ivy.el (ivy-backward-delete-char): Forward to counsel-up-directory, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra edccbd7 270/395: ivy.el (ivy-completion-in-region): Use collection in place of all-completions, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra 0f4cb44 051/395: ivy.el (ivy-add-prompt-count): Account for :dynamic-collection returning 0, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra cab01f3 053/395: ivy.el (ivy--reset-state): Add listp check, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra abfb283 054/395: ivy-overlay.el (ivy-display-function-overlay): Fix for org-current-level, Basil L. Contovounesios, 2021/02/25
- [elpa] externals/ivy-hydra 06886f1 055/395: ivy.el (ivy--tramp-prefix-p): Extract, Basil L. Contovounesios, 2021/02/25