[elpa] externals/exwm 88c6902: Bump version to 0.22.1
branch: externals/exwm commit 88c690217aa165db301c47981b52fb7c6df75154 Author: Chris Feng Commit: Chris Feng Bump version to 0.22.1 --- exwm.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/exwm.el b/exwm.el index c7ebe12..fca8b5d 100644 --- a/exwm.el +++ b/exwm.el @@ -4,7 +4,7 @@ ;; Author: Chris Feng ;; Maintainer: Chris Feng -;; Version: 0.22 +;; Version: 0.22.1 ;; Package-Requires: ((xelb "0.16")) ;; Keywords: unix ;; URL: https://github.com/ch11ng/exwm
[elpa] master 1cbc57f 1/2: In uniquify-files/file-complete-root-relative.el, delete extra paren
branch: master commit 1cbc57fdc5c96d7b7224029c39eaa0c8eca2dce0 Author: Stephen Leake Commit: Stephen Leake In uniquify-files/file-complete-root-relative.el, delete extra paren --- packages/uniquify-files/file-complete-root-relative.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/uniquify-files/file-complete-root-relative.el b/packages/uniquify-files/file-complete-root-relative.el index e3ece9a..e09baa8 100644 --- a/packages/uniquify-files/file-complete-root-relative.el +++ b/packages/uniquify-files/file-complete-root-relative.el @@ -191,7 +191,7 @@ character after each completion field." (when all (setq all (fc-root-rel-to-user all (fc-root-rel--root table))) (fc-root-rel--hilit user-string all point)) - (uniq-file--set-style all 'file-root-rel)) + (uniq-file--set-style all 'file-root-rel) )) (defun fc-root-rel--valid-completion (string all root)
[elpa] master 560e7a5 2/2: Merge commit 'a91ad330a8ee5e196e7ecfe48cbfccd6e65d3c83'
branch: master commit 560e7a55d8de2709b9515fed14f9edc66085dfa0 Merge: 1cbc57f a91ad33 Author: Stephen Leake Commit: Stephen Leake Merge commit 'a91ad330a8ee5e196e7ecfe48cbfccd6e65d3c83' --- packages/el-search/el-search.el | 44 - 1 file changed, 30 insertions(+), 14 deletions(-) diff --git a/packages/el-search/el-search.el b/packages/el-search/el-search.el index b4981fe..1fcf81e 100644 --- a/packages/el-search/el-search.el +++ b/packages/el-search/el-search.el @@ -811,6 +811,10 @@ nil." (let ((message-log-max nil)) (apply #'message format-string args))) +(defun el-search--byte-compile (form) + (let ((byte-compile-log-warning-function #'ignore)) +(byte-compile form))) + (defun el-search--set-this-command-refresh-message-maybe () (when (eq (setq this-command 'el-search-pattern) last-command) (message "%s" el-search--last-message))) @@ -1232,7 +1236,7 @@ N times." (pattern-is-symbol (and (symbolp pattern) (not (or (keywordp pattern) (null pattern)) - (byte-compile + (el-search--byte-compile `(lambda (,(if pattern-is-catchall '_ expression)) ,(cond (pattern-is-catchall (if result-specified result-expr t)) @@ -2277,7 +2281,7 @@ argument (that should be a string)." (lambda (bindings body) (if (null bindings) body `(let ,bindings ,body) - (byte-compile + (el-search--byte-compile (let ((string (make-symbol "string"))) `(lambda (,string) ,(wrap-let @@ -2708,17 +2712,25 @@ don't display anything" buffer-or-file matches-<=-here total-matches -(propertize - (format (pcase (save-excursion - (goto-char (car defun-bounds)) - (el-search-read (current-buffer))) - (`(,a ,b . ,_) (format "(%s %%d/%%d)" - (truncate-string-to-width - (format "%S %S" a b) - 40 nil nil 'ellipsis))) - (_ "(%d/%d)")) - matches-<=-here-in-defun total-matches-in-defun) - 'face 'shadow +(format + (pcase (save-excursion + (goto-char (car defun-bounds)) + (and (el-search-looking-at '`(,_ ,_ . ,_)) + (looking-at "(") ;exclude toplevel `ATOM and sim. + (let ((region (list + (progn (down-list) (point)) + (min (line-end-position) + (scan-sexps (point) 2) + (when (bound-and-true-p jit-lock-mode) + (apply #'jit-lock-fontify-now region)) + (apply #'buffer-substring region + ((and (pred stringp) signature) +(format "(%s %%d/%%d)" +(truncate-string-to-width + signature + 40 nil nil 'ellipsis))) + (_ "(%d/%d)")) + matches-<=-here-in-defun total-matches-in-defun (list (concat (if (not just-count) "[Not at a match] " "") (if (= matches-<=-here total-matches) @@ -4033,7 +4045,11 @@ text." (with-temp-buffer (emacs-lisp-mode) (insert (if splice -(mapconcat #'el-search--pp-to-string replacement " ") +(let ((insertions (mapcar #'el-search--pp-to-string replacement))) + (mapconcat #'identity insertions + (if (cl-some (apply-partially #'string-match-p "\n") + i
[elpa] master fef66a0: [el-search] Improvements for 'change' and 'changed'
branch: master commit fef66a085854873e10a28f08eca0fd3892e301fb Author: Michael Heerdegen Commit: Michael Heerdegen [el-search] Improvements for 'change' and 'changed' * packages/el-search/el-search-x.el (el-search--change-p, el-search--changed-p): Only 'user-error' in the interactive case, else silently fail. (change--1, changed--1): New internal helper patterns. (change, changed): Use them. Add implicit test for an associated file. Improve docstrings. --- packages/el-search/el-search-x.el | 78 +++ 1 file changed, 47 insertions(+), 31 deletions(-) diff --git a/packages/el-search/el-search-x.el b/packages/el-search/el-search-x.el index 06ebd78..34ef246 100644 --- a/packages/el-search/el-search-x.el +++ b/packages/el-search/el-search-x.el @@ -289,37 +289,41 @@ Uses variable `el-search--cached-changes' for caching." (defun el-search--change-p (posn revision) ;; Non-nil when sexp after POSN is part of a change - (when (buffer-modified-p) -(user-error "Buffer is modified - please save")) - (save-restriction -(widen) -(let ((changes (el-search--changes-from-diff-hl revision)) - (sexp-end (el-search--end-of-sexp posn)) - (atomic? (thunk-delay (el-search--atomic-p - (save-excursion (goto-char posn) - (el-search-read (current-buffer))) - (while (and changes (or (< (cdar changes) posn) - (and - ;; a string spanning multiple lines is a change even when not all - ;; lines are changed - (< (cdar changes) sexp-end) - (not (thunk-force atomic?) -(pop changes)) - (and changes (or (<= (caar changes) posn) - (and (thunk-force atomic?) -(<= (caar changes) sexp-end))) + (if (buffer-modified-p) + (if (eq this-command 'el-search-pattern) + (user-error "Buffer is modified - please save") +nil) +(save-restriction + (widen) + (let ((changes (el-search--changes-from-diff-hl revision)) +(sexp-end (el-search--end-of-sexp posn)) +(atomic? (thunk-delay (el-search--atomic-p + (save-excursion (goto-char posn) + (el-search-read (current-buffer))) +(while (and changes (or (< (cdar changes) posn) +(and + ;; a string spanning multiple lines is a change even when not all + ;; lines are changed + (< (cdar changes) sexp-end) + (not (thunk-force atomic?) + (pop changes)) +(and changes (or (<= (caar changes) posn) + (and (thunk-force atomic?) + (<= (caar changes) sexp-end (defun el-search--changed-p (posn revision) ;; Non-nil when sexp after POSN contains a change - (when (buffer-modified-p) -(user-error "Buffer is modified - please save")) - (save-restriction -(widen) -(let ((changes (el-search--changes-from-diff-hl revision))) - (while (and changes (<= (cdar changes) posn)) -(pop changes)) - (and changes - (< (caar changes) (el-search--end-of-sexp posn)) + (if (buffer-modified-p) + (if (eq this-command 'el-search-pattern) + (user-error "Buffer is modified - please save") +nil) +(save-restriction + (widen) + (let ((changes (el-search--changes-from-diff-hl revision))) +(while (and changes (<= (cdar changes) posn)) + (pop changes)) +(and changes + (< (caar changes) (el-search--end-of-sexp posn))) (defun el-search-change--heuristic-matcher (&optional revision) (let* ((revision (or revision "HEAD")) @@ -351,9 +355,16 @@ Uses variable `el-search--cached-changes' for caching." revision file)) (lambda (file-name-or-buffer _) (funcall file-changed-p file-name-or-buffer +(el-search-defpattern change--1 (&optional revision) + (declare (heuristic-matcher #'el-search-change--heuristic-matcher)) + `(guard (el-search--change-p (point) ,(or revision "HEAD" + (el-search-defpattern change (&optional revision) "Matches the object if its text is part of a file change. +Matches anything that changed relative to REVISION. +Never matches in a modified buffer. + Requires library \"diff-hl\". REVISION defaults to the file's repository's HEAD commit and is a revision string. Customize `el-search-change-revision-transformer-function' to control how @@ -361,12 +372,18 @@ REVISION is interpreted. This pattern-type does currently only w
[elpa] master 3eae3a8: [el-search] Some minor tweaks and bump version to 1.10.1
branch: master commit 3eae3a820659602fca77167c5ef91290abea744b Author: Michael Heerdegen Commit: Michael Heerdegen [el-search] Some minor tweaks and bump version to 1.10.1 Diverse whitespace fixes and other minor tweaks. Add some TODOs. * packages/el-search/el-search.el (el-search--pattern-is-unquoted-symbol-p): Make it return a message as non-nil value. Also complain about a 't' pattern which is likely not intended. (el-search--maybe-warn-about-unquoted-symbol) (el-search-read-display-mb-hints): Use it. (el-search-protect-search-head): Add debug spec. (el-search--get-search-description-string): Add colon to description when pattern prints multiline. (el-search--next-buffer): Remove redundant 'inhibit-message' binding. (el-search-hl-post-command-fun): Don't prevent debugging. (el-search-occur-mode): Don't initially 'hs-hide-all' because that has some quirks. (el-search-directory): Tweak prompts. First ask for directory which is more intuitive. (el-search--search-and-replace-pattern): Tweak text of header of the edit-replacement pop-up buffer. * packages/el-search/el-search-x.el (el-search--changed-files-in-repo): Show indicator when running Git. --- packages/el-search/NEWS | 7 ++ packages/el-search/el-search-x.el | 36 --- packages/el-search/el-search.el | 211 ++ 3 files changed, 153 insertions(+), 101 deletions(-) diff --git a/packages/el-search/NEWS b/packages/el-search/NEWS index 07bea82..4620ffc 100644 --- a/packages/el-search/NEWS +++ b/packages/el-search/NEWS @@ -1,6 +1,13 @@ Some of the user visible news were: +Version: 1.10.1 + + El-search now shows hints in the search pattern prompt when the new + user option 'el-search-display-mb-hints' is non-nil (the default). + This includes pointing to errors in the input and showing a match + count preview. + Version: 1.9.7 Changed default binding schemes: For reasons of harmonization, in diff --git a/packages/el-search/el-search-x.el b/packages/el-search/el-search-x.el index 34ef246..2b6791f 100644 --- a/packages/el-search/el-search-x.el +++ b/packages/el-search/el-search-x.el @@ -229,8 +229,10 @@ COMMIT defaults to HEAD." (let ((default-directory repo-root-dir)) (mapcar #'expand-file-name (split-string - (shell-command-to-string - (format "git diff -z --name-only %s --" (shell-quote-argument commit))) + (let ((current-message (current-message))) + (with-temp-message (concat current-message " [Calling VCS...]") + (shell-command-to-string + (format "git diff -z --name-only %s --" (shell-quote-argument commit) "\0" t (defvar vc-git-diff-switches) @@ -274,18 +276,21 @@ Uses variable `el-search--cached-changes' for caching." (goto-char 1) (cdr (setq el-search--cached-changes (cons (list revision (visited-file-modtime)) - (and (el-search--file-changed-p buffer-file-name diff-hl-reference-revision) - (delq nil (mapcar (pcase-lambda (`(,start-line ,nbr-lines ,kind)) - (if (eq kind 'delete) nil -(forward-line (- start-line current-line-nbr)) -(setq change-beg (point)) -(forward-line (1- nbr-lines)) -(setq current-line-nbr (+ start-line nbr-lines -1)) -(cons (copy-marker change-beg) - (copy-marker (line-end-position) -(ignore-errors - (let ((default-directory (file-name-directory buffer-file-name))) - (diff-hl-changes))) + (and (el-search--file-changed-p + buffer-file-name diff-hl-reference-revision) + (delq nil +(mapcar (pcase-lambda (`(,start-line ,nbr-lines ,kind)) + (if (eq kind 'delete) nil +(forward-line (- start-line current-line-nbr)) +(setq change-beg (point)) +(forward-line (1- nbr-lines)) +(setq current-line-nbr (+ start-line nbr-lines -1)) +
[elpa] master 0775a43: [el-search] Add el-search-list-defined-patterns
branch: master commit 0775a4309033ad54c7aeaf9adff335684c444baa Author: Michael Heerdegen Commit: Michael Heerdegen [el-search] Add el-search-list-defined-patterns Also bump version to 1.10.2. * packages/el-search/el-search.el (el-search-list-defined-patterns): New autoloaded command replacing 'el-search-help-list-patterns'. (el-search-help-list-patterns): Remove. --- packages/el-search/NEWS | 5 + packages/el-search/el-search.el | 14 -- 2 files changed, 13 insertions(+), 6 deletions(-) diff --git a/packages/el-search/NEWS b/packages/el-search/NEWS index 4620ffc..85248da 100644 --- a/packages/el-search/NEWS +++ b/packages/el-search/NEWS @@ -1,6 +1,11 @@ Some of the user visible news were: +Version: 1.10.2 + + New help command 'el-search-list-defined-patterns' listing all + currently defined pattern types. + Version: 1.10.1 El-search now shows hints in the search pattern prompt when the new diff --git a/packages/el-search/el-search.el b/packages/el-search/el-search.el index 04cd908..229a8a1 100644 --- a/packages/el-search/el-search.el +++ b/packages/el-search/el-search.el @@ -7,7 +7,7 @@ ;; Created: 29 Jul 2015 ;; Keywords: lisp ;; Compatibility: GNU Emacs 25 -;; Version: 1.10.1 +;; Version: 1.10.2 ;; Package-Requires: ((emacs "25") (stream "2.2.4") (cl-print "1.0")) @@ -1165,6 +1165,12 @@ expander functions.") (put 'el-search-defined-patterns 'function-documentation '(el-search--make-docstring 'el-search-defined-patterns)) +;;;###autoload +(defun el-search-list-defined-patterns () + "Pop up a help buffer listing defined el-search pattern types." + (interactive) + (describe-function 'el-search-defined-patterns)) + (defun el-search--make-docstring (name) ;; Code mainly from `pcase--make-docstring' (let* ((main (documentation (symbol-function name) 'raw)) @@ -2229,10 +2235,6 @@ Toggle visibility of this window with \ (with-help-window (help-buffer) (el-search-help-list-bindings--1 'verbose))) -(defun el-search-help-list-patterns () - (interactive) - (describe-function 'el-search-defined-patterns)) - (defun el-search-help-read-intro () (interactive) (with-output-to-temp-buffer "*Help*" @@ -2258,7 +2260,7 @@ Introduction to El-Search (define-key el-search-help-map [??] #'el-search-help-for-help) (define-key el-search-help-map [?b] #'el-search-help-list-bindings) (define-key el-search-help-map [?m] #'el-search-help-list-bindings-verbose) -(define-key el-search-help-map [?p] #'el-search-help-list-patterns) +(define-key el-search-help-map [?p] #'el-search-list-defined-patterns) (define-key el-search-help-map [?i] #'el-search-help-read-intro) (define-key el-search-help-map [?k] #'describe-key) (define-key el-search-help-map [?q] #'help-quit)
[elpa] master d1cec26: [el-search] Improvise eldoc support for search pattern prompt
branch: master commit d1cec26ffa1843d05a1d3053aaf40d771c1223c3 Author: Michael Heerdegen Commit: Michael Heerdegen [el-search] Improvise eldoc support for search pattern prompt * packages/el-search/el-search.el (el-search-eldoc-documentation-function): New function. (el-search-read-pattern-setup-mb): Install 'el-search-eldoc-documentation-function' buffer-locally. --- packages/el-search/el-search.el | 27 ++- 1 file changed, 26 insertions(+), 1 deletion(-) diff --git a/packages/el-search/el-search.el b/packages/el-search/el-search.el index 229a8a1..d671e0c 100644 --- a/packages/el-search/el-search.el +++ b/packages/el-search/el-search.el @@ -948,6 +948,29 @@ nil." (timer-set-time el-search--mb-hints-timer (time-add (current-time) el-search-mb-hints-delay)) (timer-activate el-search--mb-hints-timer))) +(defun el-search-eldoc-documentation-function () + (when (catch 'result + (save-excursion +(while (condition-case nil + (progn (backward-up-list) + (if (el-search-looking-at '`(,(or 'pred 'guard) . ,_)) + (throw 'result nil) +t)) + (scan-error nil))) +t)) +(pcase-let (((and current-fsym `(,fnsym ,index)) + (elisp--fnsym-in-current-sexp))) + (defvar el-search--pcase-macros) ;defined later + (let (pattern-def docstring help) +(and fnsym + (setq pattern-def (cdr (assoc fnsym el-search--pcase-macros))) + ;; This is what `elisp-get-fnsym-args-string' (which we can't use) does + (setq docstring (documentation pattern-def)) + (setq help (help-split-fundoc docstring fnsym)) + (elisp--highlight-function-argument + current-fsym (elisp-function-argstring (car help)) + index (concat (symbol-name fnsym) ": "))) + (defvar el-search--this-session-match-count-data nil) (defun el-search-read-pattern-setup-mb () @@ -958,7 +981,9 @@ nil." (setq el-search--this-session-match-count-data nil) (when (timerp el-search--mb-hints-timer) (cancel-timer el-search--mb-hints-timer)) (setq el-search--mb-hints-timer nil) -(add-hook 'post-command-hook #'el-search-read-pattern-trigger-mb-hints t t))) +(add-hook 'post-command-hook #'el-search-read-pattern-trigger-mb-hints t t)) + (add-function :before-until (local 'eldoc-documentation-function) +#'el-search-eldoc-documentation-function)) (defvar el-search--search-pattern-1-do-fun nil) (defvar el-search--busy-animation