From 8e9efc6bf7d0a79451e16ce63e8de69adbf54d87 Mon Sep 17 00:00:00 2001 From: Andreas Gerler Date: Thu, 31 Oct 2019 17:13:07 +0100 Subject: [PATCH] update visual-regexp --- .../visual-regexp-autoloads.el | 11 +++-------- .../visual-regexp-pkg.el | 2 +- .../visual-regexp.el | 17 ++++++++++------- 3 files changed, 14 insertions(+), 16 deletions(-) rename elpa/{visual-regexp-20170301.116 => visual-regexp-20190414.814}/visual-regexp-autoloads.el (68%) rename elpa/{visual-regexp-20170301.116 => visual-regexp-20190414.814}/visual-regexp-pkg.el (69%) rename elpa/{visual-regexp-20170301.116 => visual-regexp-20190414.814}/visual-regexp.el (99%) diff --git a/elpa/visual-regexp-20170301.116/visual-regexp-autoloads.el b/elpa/visual-regexp-20190414.814/visual-regexp-autoloads.el similarity index 68% rename from elpa/visual-regexp-20170301.116/visual-regexp-autoloads.el rename to elpa/visual-regexp-20190414.814/visual-regexp-autoloads.el index d14a122e..1885a31d 100644 --- a/elpa/visual-regexp-20170301.116/visual-regexp-autoloads.el +++ b/elpa/visual-regexp-20190414.814/visual-regexp-autoloads.el @@ -1,12 +1,10 @@ ;;; visual-regexp-autoloads.el --- automatically extracted autoloads ;; ;;; Code: - -(add-to-list 'load-path (directory-file-name - (or (file-name-directory #$) (car load-path)))) - +(add-to-list 'load-path (directory-file-name (or (file-name-directory #$) (car load-path)))) -;;;### (autoloads nil "visual-regexp" "visual-regexp.el" (0 0 0 0)) +;;;### (autoloads nil "visual-regexp" "visual-regexp.el" (23994 46375 +;;;;;; 492572 59000)) ;;; Generated autoloads from visual-regexp.el (autoload 'vr/mc-mark "visual-regexp" "\ @@ -24,14 +22,11 @@ Use vr/query-replace like you would use query-replace-regexp. \(fn REGEXP REPLACE START END)" t nil) -(if (fboundp 'register-definition-prefixes) (register-definition-prefixes "visual-regexp" '("vr/" "vr--"))) - ;;;*** ;; Local Variables: ;; version-control: never ;; no-byte-compile: t ;; no-update-autoloads: t -;; coding: utf-8 ;; End: ;;; visual-regexp-autoloads.el ends here diff --git a/elpa/visual-regexp-20170301.116/visual-regexp-pkg.el b/elpa/visual-regexp-20190414.814/visual-regexp-pkg.el similarity index 69% rename from elpa/visual-regexp-20170301.116/visual-regexp-pkg.el rename to elpa/visual-regexp-20190414.814/visual-regexp-pkg.el index 71c3f9a3..36be9816 100644 --- a/elpa/visual-regexp-20170301.116/visual-regexp-pkg.el +++ b/elpa/visual-regexp-20190414.814/visual-regexp-pkg.el @@ -1,2 +1,2 @@ ;;; -*- no-byte-compile: t -*- -(define-package "visual-regexp" "20170301.116" "A regexp/replace command for Emacs with interactive visual feedback" '((cl-lib "0.2")) :commit "b3096c2d391ff4e28a2a4e8cd82efbf11071ea85" :keywords '("regexp" "replace" "visual" "feedback") :authors '(("Marko Bencun" . "mbencun@gmail.com")) :maintainer '("Marko Bencun" . "mbencun@gmail.com") :url "https://github.com/benma/visual-regexp.el/") +(define-package "visual-regexp" "20190414.814" "A regexp/replace command for Emacs with interactive visual feedback" '((cl-lib "0.2")) :commit "3e3ed81a3cbadef1f1f4cb16f9112a58641d70ca" :keywords '("regexp" "replace" "visual" "feedback") :authors '(("Marko Bencun" . "mbencun@gmail.com")) :maintainer '("Marko Bencun" . "mbencun@gmail.com") :url "https://github.com/benma/visual-regexp.el/") diff --git a/elpa/visual-regexp-20170301.116/visual-regexp.el b/elpa/visual-regexp-20190414.814/visual-regexp.el similarity index 99% rename from elpa/visual-regexp-20170301.116/visual-regexp.el rename to elpa/visual-regexp-20190414.814/visual-regexp.el index 5c3e09d1..cfbe9f0b 100644 --- a/elpa/visual-regexp-20170301.116/visual-regexp.el +++ b/elpa/visual-regexp-20190414.814/visual-regexp.el @@ -1,10 +1,10 @@ ;;; visual-regexp.el --- A regexp/replace command for Emacs with interactive visual feedback -;; Copyright (C) 2013-2017 Marko Bencun +;; Copyright (C) 2013-2019 Marko Bencun ;; Author: Marko Bencun ;; URL: https://github.com/benma/visual-regexp.el/ -;; Package-Version: 20170301.116 +;; Package-Version: 20190414.814 ;; Version: 1.1 ;; Package-Requires: ((cl-lib "0.2")) ;; Keywords: regexp, replace, visual, feedback @@ -104,7 +104,7 @@ (unless (boundp 'query-replace-from-to-separator) (defcustom query-replace-from-to-separator (propertize (if (char-displayable-p ?→) " → " " -> ") - 'face 'minibuffer-prompt) + 'face 'minibuffer-prompt) "String that separates FROM and TO in the history of replacement pairs." ;; Avoids error when attempt to autoload char-displayable-p fails ;; while preparing to dump, also stops customize-rogue listing this. @@ -453,7 +453,6 @@ visible all the time in the minibuffer." ;; that disappear after a while. (vr--update-minibuffer-prompt) (vr--show-feedback))))) -(add-hook 'after-change-functions 'vr--after-change) (defun vr--minibuffer-setup () "Setup prompt and help when entering minibuffer." @@ -461,7 +460,6 @@ visible all the time in the minibuffer." (progn (vr--update-minibuffer-prompt) (when vr/auto-show-help (vr--minibuffer-help))))) -(add-hook 'minibuffer-setup-hook 'vr--minibuffer-setup) ;;; helper functions @@ -544,7 +542,7 @@ visible all the time in the minibuffer." (ignore-errors (isearch-no-upper-case-p (vr--get-regexp-string) t)) case-fold-search)) (nocasify (not (and case-replace case-fold-search)))) - ;; we need to set the match data again, s.t. match-substitute-replacement works correctly. + ;; we need to set the match data again, s.t. match-substitute-replacement works correctly. ;; (match-data) could have been modified in the meantime, e.g. by vr--get-regexp-string->pcre-to-elisp. (set-match-data match-data) (if (stringp replacement) @@ -741,6 +739,9 @@ visible all the time in the minibuffer." (progn (let ((buffer-read-only t)) ;; make target buffer (when vr--in-minibuffer (error "visual-regexp already in use.")) + (add-hook 'after-change-functions 'vr--after-change) + (add-hook 'minibuffer-setup-hook 'vr--minibuffer-setup) + (setq vr--calling-func calling-func) (setq vr--target-buffer (current-buffer)) (vr--set-target-buffer-start-end) @@ -753,7 +754,7 @@ visible all the time in the minibuffer." (vr--set-regexp-string) (when (equal mode 'vr--mode-regexp-replace) (vr--set-replace-string)) - + ;; Successfully got the args, deactivate mark now. If the command was aborted (C-g), the mark (region) would remain active. (deactivate-mark) (cond ((equal mode 'vr--mode-regexp-replace) @@ -767,6 +768,8 @@ visible all the time in the minibuffer." vr--target-buffer-end))))) (progn ;; execute on finish (setq vr--in-minibuffer nil) + (remove-hook 'after-change-functions 'vr--after-change) + (remove-hook 'minibuffer-setup-hook 'vr--minibuffer-setup) (setq vr--calling-func nil) (unless (overlayp vr--minibuffer-message-overlay) (delete-overlay vr--minibuffer-message-overlay)) -- 2.47.3