[elpa] externals/org updated (edddc7d -> 41f412f)
elpasync pushed a change to branch externals/org. from edddc7d org-element-cache-map: Reduce memory allocation and time re-search new 957feb2 oc: Fix typo in docstring new 41f412f Merge branch 'bugfix' Summary of changes: lisp/oc.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
[elpa] externals/org 41f412f: Merge branch 'bugfix'
branch: externals/org commit 41f412f0bcaa8884c1e71ca6d7b098fdd1246004 Merge: edddc7d 957feb2 Author: Nicolas Goaziou Commit: Nicolas Goaziou Merge branch 'bugfix' --- lisp/oc.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/oc.el b/lisp/oc.el index dbd9baf..e6190e4 100644 --- a/lisp/oc.el +++ b/lisp/oc.el @@ -1566,7 +1566,7 @@ More specifically, On a citation reference: -- on the prefix or right before th \"@\" character, insert +- on the prefix or right before the \"@\" character, insert a new reference before the current one, - on the suffix, insert it after the reference, - otherwise, update the cite key, preserving both affixes.
[elpa] externals-release/org 957feb2: oc: Fix typo in docstring
branch: externals-release/org commit 957feb2df4cd465d43de24cb0a102b52da8b3f44 Author: Nicolas Goaziou Commit: Nicolas Goaziou oc: Fix typo in docstring * lisp/oc.el (org-cite-make-insert-processor): Fix typo. --- lisp/oc.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/oc.el b/lisp/oc.el index 427c087..a77daa7 100644 --- a/lisp/oc.el +++ b/lisp/oc.el @@ -1540,7 +1540,7 @@ The generated function inserts or edit a citation at point. More specifically, On a citation reference: -- on the prefix or right before th \"@\" character, insert a new reference +- on the prefix or right before the \"@\" character, insert a new reference before the current one, - on the suffix, insert it after the reference, - otherwise, update the cite key, preserving both affixes.
[elpa] externals/embark d369bb6: Respect command remappings in embark-dwim
branch: externals/embark commit d369bb6131ed156a06168f57cb11a5faedf94c23 Author: Omar Antolín Commit: Omar Antolín Respect command remappings in embark-dwim This change is to make embark-dwim equivalent to embark-act RET, which does use the remapping. --- embark.el | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/embark.el b/embark.el index 66f6d2c..1ec9b0b 100644 --- a/embark.el +++ b/embark.el @@ -2108,9 +2108,8 @@ See `embark-act' for the meaning of the prefix ARG." 0 (mod (prefix-numeric-value arg) (length targets))) targets))) - (default-action (embark--default-action - (plist-get target :type -(embark--act default-action + (default-action (embark--default-action (plist-get target :type +(embark--act (or (command-remapping default-action) default-action) (if (eq default-action embark--command) (embark--orig-target target) target)
[elpa] externals/embark-consult updated (fed1459 -> d369bb6)
elpasync pushed a change to branch externals/embark-consult. from fed1459 Merge pull request #420 from minad/∀ adds d369bb6 Respect command remappings in embark-dwim No new revisions were added by this update. Summary of changes: embark.el | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-)
[elpa] externals-release/org 888689f: org-macro: Adjust for compatibility with latest vc (bug#51365)
branch: externals-release/org commit 888689f2baf89742aab16f0eb3d70397895b0f65 Author: TAKAHASHI Yoshio Commit: Kyle Meyer org-macro: Adjust for compatibility with latest vc (bug#51365) * lisp/org-macro.el (org-macro--vc-modified-time): Wrap file in a list when passing to vc-call to avoid a type error starting with Emacs 28. Before Emacs's 3572613550f (Fix vc-git-state for filenames with wildcards, 2021-08-15), a string could be given to vc-git-print-log as the FILES argument because the argument was passed directly as vc-git-command's FILE-OR-LIST, which as the name suggests, accepts either a string or a list. After 3572613550f, passing a string leads to a type error. TINYCHANGE --- lisp/org-macro.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/org-macro.el b/lisp/org-macro.el index c38a07b..c0287a2 100644 --- a/lisp/org-macro.el +++ b/lisp/org-macro.el @@ -368,7 +368,7 @@ Return value as a string." date) (unwind-protect (progn - (vc-call print-log file buf nil nil 1) + (vc-call print-log (list file) buf nil nil 1) (with-current-buffer buf (vc-exec-after (lambda ()
[elpa] externals/org updated (41f412f -> e6c7ea3)
elpasync pushed a change to branch externals/org. from 41f412f Merge branch 'bugfix' new 888689f org-macro: Adjust for compatibility with latest vc (bug#51365) new e6c7ea3 Merge branch 'bugfix' Summary of changes: lisp/org-macro.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
[elpa] externals/org e6c7ea3: Merge branch 'bugfix'
branch: externals/org commit e6c7ea3a3626d8fce5361f000f9d17e7192c826a Merge: 41f412f 888689f Author: Nicolas Goaziou Commit: Nicolas Goaziou Merge branch 'bugfix' --- lisp/org-macro.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/org-macro.el b/lisp/org-macro.el index 749df4e..52ad4af 100644 --- a/lisp/org-macro.el +++ b/lisp/org-macro.el @@ -377,7 +377,7 @@ Return value as a string." date) (unwind-protect (progn - (vc-call print-log file buf nil nil 1) + (vc-call print-log (list file) buf nil nil 1) (with-current-buffer buf (vc-exec-after (lambda ()
[elpa] externals/consult updated (a8dea90 -> 1984605)
elpasync pushed a change to branch externals/consult. from a8dea90 Detect project root when formatting consult-ripgrep prompt (Fix #478) new 21663b6 Fix consult-completing-read-multiple history new 1984605 Minor code cleanup Summary of changes: consult.el | 9 + 1 file changed, 5 insertions(+), 4 deletions(-)
[elpa] externals/consult 1984605 2/2: Minor code cleanup
branch: externals/consult commit 1984605a4aa6707bd8b096440a1eda70212f616b Author: Daniel Mendler Commit: Daniel Mendler Minor code cleanup --- consult.el | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/consult.el b/consult.el index 969635d..bb8a313 100644 --- a/consult.el +++ b/consult.el @@ -2516,8 +2516,8 @@ See `completing-read-multiple' for the documentation of the arguments." "" ;; default inherit-input-method))) (unless (or (equal result "") selected) -(setq selected (split-string (substring-no-properties result) separator 'omit-nulls) - consult--crm-history (append selected hist-val) +(setq selected (split-string result separator 'omit-nulls) + consult--crm-history (append (mapcar #'substring-no-properties selected) hist-val) (remove-hook 'pre-command-hook hook))) (when (consp def) (setq def (car def)))
[elpa] externals/consult 21663b6 1/2: Fix consult-completing-read-multiple history
branch: externals/consult commit 21663b651c61cf8ecb704e6e94289823e0fe828d Author: Daniel Mendler Commit: Daniel Mendler Fix consult-completing-read-multiple history See https://github.com/bdarcus/citar/issues/478 --- consult.el | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/consult.el b/consult.el index 5c534c2..969635d 100644 --- a/consult.el +++ b/consult.el @@ -2519,12 +2519,13 @@ See `completing-read-multiple' for the documentation of the arguments." (setq selected (split-string (substring-no-properties result) separator 'omit-nulls) consult--crm-history (append selected hist-val) (remove-hook 'pre-command-hook hook))) -(set hist-sym consult--crm-history) (when (consp def) (setq def (car def))) (if (and def (not (equal "" def)) (not selected)) (split-string def separator 'omit-nulls) - (mapcar #'substring-no-properties selected + (setq selected (mapcar #'substring-no-properties selected)) + (set hist-sym (append selected (symbol-value hist-sym))) + selected))) Commands
[elpa] externals/embark ca79673: Bind default action to both [13] and [return]
branch: externals/embark commit ca796732c1362f8289646eca08734dd717daf0aa Author: Omar Antolín Commit: Omar Antolín Bind default action to both [13] and [return] It's annoying to have the enter key not run the default action... --- embark.el | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/embark.el b/embark.el index 1ec9b0b..76a3394 100644 --- a/embark.el +++ b/embark.el @@ -927,8 +927,10 @@ relative path." "Return action keymap for targets of given TYPE. If CYCLE is non-nil bind `embark-cycle'." (make-composed-keymap - (let ((map (make-sparse-keymap))) - (define-key map [13] (embark--default-action type)) + (let ((map (make-sparse-keymap)) + (default-action (embark--default-action type))) + (define-key map [13] default-action) + (define-key map [return] default-action) (when-let ((cycle-key (and cycle (embark--cycle-key (define-key map cycle-key #'embark-cycle)) (when embark-help-key
[elpa] externals/embark-consult updated (d369bb6 -> ca79673)
elpasync pushed a change to branch externals/embark-consult. from d369bb6 Respect command remappings in embark-dwim adds ca79673 Bind default action to both [13] and [return] No new revisions were added by this update. Summary of changes: embark.el | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-)
[elpa] externals/org updated (e6c7ea3 -> 0c9b30e)
elpasync pushed a change to branch externals/org. from e6c7ea3 Merge branch 'bugfix' new 9ca3bc3 Backport commit 26fb4168b from Emacs new 0c9b30e Merge branch 'bugfix' Summary of changes: lisp/org.el | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
[elpa] externals/org 0c9b30e: Merge branch 'bugfix'
branch: externals/org commit 0c9b30e961ac7a20eb2e8985ab686c6940e79ef3 Merge: e6c7ea3 9ca3bc3 Author: Kyle Meyer Commit: Kyle Meyer Merge branch 'bugfix' --- lisp/org.el | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lisp/org.el b/lisp/org.el index 2962034..1295ae2 100644 --- a/lisp/org.el +++ b/lisp/org.el @@ -698,7 +698,7 @@ defined in org-duration.el.") If a description starts with , the file is not part of Emacs and Org mode, so loading it will require that you have properly installed org-contrib package from NonGNU Emacs Lisp Package Archive -http://elpa.nongnu.org/nongnu/org-contrib.html +https://elpa.nongnu.org/nongnu/org-contrib.html You can also use this system to load external packages (i.e. neither Org core modules, nor org-contrib modules). Just add symbols @@ -778,7 +778,7 @@ For export specific modules, see also `org-export-backends'." If a description starts with , the file is not part of Emacs and Org mode, so loading it will require that you have properly installed org-contrib package from NonGNU Emacs Lisp Package Archive -http://elpa.nongnu.org/nongnu/org-contrib.html +https://elpa.nongnu.org/nongnu/org-contrib.html Unlike to `org-modules', libraries in this list will not be loaded along with Org, but only once the export framework is
[elpa] externals-release/org 9ca3bc3: Backport commit 26fb4168b from Emacs
branch: externals-release/org commit 9ca3bc37300b55cf0448e7c7c75fe4bf2d983e56 Author: Stefan Kangas Commit: Kyle Meyer Backport commit 26fb4168b from Emacs ; Prefer HTTPS in more URLs 26fb4168b884eeb910580c42e87efb73399019c9 Stefan Kangas Thu Dec 9 16:26:04 2021 +0100 --- lisp/org.el | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lisp/org.el b/lisp/org.el index 998da06..00bbc07 100644 --- a/lisp/org.el +++ b/lisp/org.el @@ -693,7 +693,7 @@ defined in org-duration.el.") If a description starts with , the file is not part of Emacs and Org mode, so loading it will require that you have properly installed org-contrib package from NonGNU Emacs Lisp Package Archive -http://elpa.nongnu.org/nongnu/org-contrib.html +https://elpa.nongnu.org/nongnu/org-contrib.html You can also use this system to load external packages (i.e. neither Org core modules, nor org-contrib modules). Just add symbols @@ -773,7 +773,7 @@ For export specific modules, see also `org-export-backends'." If a description starts with , the file is not part of Emacs and Org mode, so loading it will require that you have properly installed org-contrib package from NonGNU Emacs Lisp Package Archive -http://elpa.nongnu.org/nongnu/org-contrib.html +https://elpa.nongnu.org/nongnu/org-contrib.html Unlike to `org-modules', libraries in this list will not be loaded along with Org, but only once the export framework is
[nongnu] elpa/evil b00018b 2/2: Don't abort ex if choosing completion with mouse (#1553)
branch: elpa/evil commit b00018bf550fbbe1b55165579e6ede973d70f53b Author: Tom Dalziel <33435574+tomd...@users.noreply.github.com> Commit: GitHub Don't abort ex if choosing completion with mouse (#1553) Fixes #1551 --- evil-ex.el | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/evil-ex.el b/evil-ex.el index 2a13489..bb7cd46 100644 --- a/evil-ex.el +++ b/evil-ex.el @@ -221,7 +221,8 @@ Otherwise behaves like `delete-backward-char'." (defun evil-ex-abort () "Cancel ex state when another buffer is selected." - (unless (minibufferp) + (unless (or (minibufferp) + (memq this-command '(mouse-drag-region choose-completion))) (abort-recursive-edit))) (defun evil-ex-command-window-execute (config result)
[nongnu] elpa/evil 6b61dd7 1/2: Refactor handling of insert after macro finished with C-oq (#1552)
branch: elpa/evil commit 6b61dd7b421597be077e4b1bf3f9f0f18de6ad39 Author: Tom Dalziel <33435574+tomd...@users.noreply.github.com> Commit: GitHub Refactor handling of insert after macro finished with C-oq (#1552) --- evil-commands.el | 139 +-- evil-tests.el| 14 +- 2 files changed, 75 insertions(+), 78 deletions(-) diff --git a/evil-commands.el b/evil-commands.el index 0dd4ea8..9c9075e 100644 --- a/evil-commands.el +++ b/evil-commands.el @@ -2251,10 +2251,8 @@ The return value is the yanked text." (overlay-put overlay 'after-string string) (list (or evil-this-register (read-char (delete-overlay overlay - (when (evil-paste-before nil register t) -;; go to end of pasted text -(unless (eobp) - (forward-char + (let (evil-move-cursor-back) +(evil-paste-before nil register t))) (defun evil-paste-last-insertion () "Paste last insertion." @@ -2262,7 +2260,7 @@ The return value is the yanked text." (evil-paste-from-register ?.)) (defun evil-paste-last-insertion-and-stop-insert () - "Past last insertion and change to normal state." + "Paste last insertion and change to normal state." (interactive) (evil-paste-last-insertion) (evil-normal-state)) @@ -2277,6 +2275,18 @@ The return value is the yanked text." (defvar evil-macro-buffer nil "The buffer that has been active on macro recording.") +(defun evil-end-and-return-macro () + "Like `end-kbd-macro' but also return the macro. +Remove [evil-execute-in-normal-state] from the end." + (end-kbd-macro) + (let ((end-keys-seq (append evil-execute-normal-keys nil)) +(last-kbd-macro-seq (append last-kbd-macro nil))) +(unless last-kbd-macro-seq + (setq last-kbd-macro nil)) +(if (and end-keys-seq last-kbd-macro-seq) +(apply #'vector (butlast last-kbd-macro-seq (length end-keys-seq))) + last-kbd-macro))) + (evil-define-command evil-record-macro (register) "Record a keyboard macro into REGISTER. If REGISTER is :, /, or ?, the corresponding command line window @@ -2286,34 +2296,33 @@ will be opened instead." (interactive (list (unless (and evil-this-macro defining-kbd-macro) (or evil-this-register (evil-read-key) - (cond - ((eq register ?\C-g) -(keyboard-quit)) - ((and evil-this-macro defining-kbd-macro) -(setq evil-macro-buffer nil) -(condition-case nil -(end-kbd-macro) - (error nil)) -(when last-kbd-macro - (when (member last-kbd-macro '("" [])) -(setq last-kbd-macro nil)) - (evil-set-register evil-this-macro last-kbd-macro)) -(setq evil-this-macro nil)) - ((eq register ?:) -(evil-command-window-ex)) - ((eq register ?/) -(evil-command-window-search-forward)) - ((eq register ??) -(evil-command-window-search-backward)) - ((or (and (>= register ?0) (<= register ?9)) -(and (>= register ?a) (<= register ?z)) -(and (>= register ?A) (<= register ?Z))) -(when defining-kbd-macro (end-kbd-macro)) -(setq evil-this-macro register) -(evil-set-register evil-this-macro nil) -(start-kbd-macro nil) -(setq evil-macro-buffer (current-buffer))) - (t (error "Invalid register" + (let (last-macro) +(cond + ((eq register ?\C-g) + (keyboard-quit)) + ((and evil-this-macro defining-kbd-macro) + (setq evil-macro-buffer nil) + (condition-case nil + (setq last-macro (evil-end-and-return-macro)) +(error nil)) + (when last-macro +(evil-set-register evil-this-macro last-macro)) + (setq evil-this-macro nil)) + ((eq register ?:) + (evil-command-window-ex)) + ((eq register ?/) + (evil-command-window-search-forward)) + ((eq register ??) + (evil-command-window-search-backward)) + ((or (<= ?0 register ?9) + (<= ?a register ?z) + (<= ?A register ?Z)) + (when defining-kbd-macro (end-kbd-macro)) + (setq evil-this-macro register) + (evil-set-register evil-this-macro nil) + (start-kbd-macro nil) + (setq evil-macro-buffer (current-buffer))) + (t (error "Invalid register") (evil-define-command evil-execute-macro (count macro) "Execute keyboard macro MACRO, COUNT times. @@ -2343,32 +2352,28 @@ when called interactively." (setq macro (evil-get-register register t) evil-last-register register))) (list count macro))) - (let ((last-insertion-temp evil-last-insertion)) -(cond - ((functionp macro) - (evil-repeat-abort) - (dotimes (_ (or count 1)) -(funcall macro))) - ((or (and (not (stringp macro)) - (not (vectorp macro))) - (member macro '("" []))) - ;; allow references to currently empty registers - ;; when defining macro - (unless evil-this-macro -(user-error "No previous macro"))) - (t - (condition-case err - (evil-wi
[nongnu] elpa/evil updated (44080eb -> b00018b)
elpasync pushed a change to branch elpa/evil. from 44080eb Allow exit from insert, paste from . without forward-char (#1550) new 6b61dd7 Refactor handling of insert after macro finished with C-oq (#1552) new b00018b Don't abort ex if choosing completion with mouse (#1553) Summary of changes: evil-commands.el | 139 +-- evil-ex.el | 3 +- evil-tests.el| 14 +- 3 files changed, 77 insertions(+), 79 deletions(-)
[elpa] externals/embark 71d2601: Improve rules for promoting identifiers to Emacs Lisp symbols
branch: externals/embark commit 71d260101ebd334ed707b7b81abd608589d26a35 Author: Omar Antolín Commit: Omar Antolín Improve rules for promoting identifiers to Emacs Lisp symbols 1. In IELM buffers identifier are now symbols. 2. Previously an identifier in any mode not deriving from prog-mode that matched an interned Emacs symbol, was considered a symbol. I've tightened that up to just applying in special modes, text modes and Info. This is to prevent identifiers in (non-IELM) repls from being considered as Emacs Lisp symbols if they happen to match an interned symbol's name, --- embark.el | 13 - 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/embark.el b/embark.el index 76a3394..ada6391 100644 --- a/embark.el +++ b/embark.el @@ -813,10 +813,12 @@ in one of those major modes." (defun embark-target-identifier-at-point () "Target identifier at point. -In Emacs Lisp buffers the identifier is promoted to a symbol, for -which more actions are available. Identifiers are also promoted -to symbols if they are interned Emacs Lisp symbols and found in a -buffer whose major mode does not inherit from `prog-mode'. +In Emacs Lisp and IELM buffers the identifier is promoted to a +symbol, for which more actions are available. Identifiers are +also promoted to symbols if they are interned Emacs Lisp symbols +and found in a buffer in a major mode derived from +`special-mode', `Info-mode' or `text-mode' (these are intended to +cover cases where you might be reading or writing about Emacs). As a convenience, in Org Mode an initial ' or surrounding == or ~~ are removed." @@ -831,8 +833,9 @@ As a convenience, in Org Mode an initial ' or surrounding == or (cl-incf (car bounds)) (cl-decf (cdr bounds) `(,(if (or (derived-mode-p 'emacs-lisp-mode) + (derived-mode-p 'inferior-emacs-lisp-mode) (and (intern-soft name) - (not (derived-mode-p 'prog-mode + (derived-mode-p 'special-mode 'Info-mode 'text-mode))) 'symbol 'identifier) ,name
[elpa] externals/embark-consult updated (ca79673 -> 71d2601)
elpasync pushed a change to branch externals/embark-consult. from ca79673 Bind default action to both [13] and [return] adds 71d2601 Improve rules for promoting identifiers to Emacs Lisp symbols No new revisions were added by this update. Summary of changes: embark.el | 13 - 1 file changed, 8 insertions(+), 5 deletions(-)
[elpa] externals/hyperbole 288cb87: Add test for buttons in ls R listing (#133)
branch: externals/hyperbole commit 288cb87971cbd9344d854a18413e9c6fac3611b9 Author: Mats Lidell Commit: GitHub Add test for buttons in ls R listing (#133) --- ChangeLog | 6 ++ test/hpath-tests.el | 25 + 2 files changed, 31 insertions(+) diff --git a/ChangeLog b/ChangeLog index fe475ab..8f80a87 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2021-12-11 Mats Lidell + +* test/hpath-tests.el (hypb-run-shell-test-command): Test helper for +running shell commands. +(hpath:prepend-ls-directory-test): Test for "ls R" listing. + 2021-12-05 Bob Weiner * hyrolo.el (hyrolo-next-match): Handle case when no prior regexp search. diff --git a/test/hpath-tests.el b/test/hpath-tests.el index d9e1651..24defb1 100644 --- a/test/hpath-tests.el +++ b/test/hpath-tests.el @@ -18,6 +18,11 @@ (require 'ert) (require 'hpath) +(load (expand-file-name "hy-test-helpers" +(file-name-directory (or load-file-name + default-directory +(declare-function hy-test-helpers:action-key-should-call-hpath:find "hy-test-helpers") + (ert-deftest hpath:find-report-lisp-variable-path-name-when-not-exists () "Test that hpath:find expands and returns filename when it is non-existent." (condition-case err @@ -103,5 +108,25 @@ (should (string= (hpath:substitute-value "${UNDEFINED_IS_NOT_SUBSTITUTED}") "${UNDEFINED_IS_NOT_SUBSTITUTED}")) )) +(defun hypb-run-shell-test-command (command buffer) + "Run a shell COMMAND with output to BUFFER and select it." + (shell-command command buffer nil) + (switch-to-buffer buffer) + (shell-mode)) + +(ert-deftest hpath:prepend-ls-directory-test () + "Find file in ls -R listing." + (let ((shell-buffer "*hypb-test-shell-buffer*")) +(unwind-protect +(let ((explicit-shell-file-name "/usr/bin/sh") + (default-directory hyperb:dir)) + (hypb-run-shell-test-command "ls -R" shell-buffer) + (dolist (file '("COPYING" "man/version.texi" "man/hkey-help.txt" "man/im/demo.png")) +(goto-char (point-min)) +(should (search-forward (car (last (split-string file "/"))) nil t)) +(backward-char 5) +(hy-test-helpers:action-key-should-call-hpath:find (expand-file-name file hyperb:dir + (kill-buffer shell-buffer + (provide 'hpath-tests) ;;; hpath-tests.el ends here
[elpa] externals/ebdb-gnorb c7c9bd5: Simplify/port ebdb-gnorb-lapsed-days
branch: externals/ebdb-gnorb commit c7c9bd518b332e913d45a2fd70fd09813d833e16 Author: Paul Eggert Commit: Paul Eggert Simplify/port ebdb-gnorb-lapsed-days * packages/ebdb-gnorb/ebdb-gnorb.el (ebdb-gnorb-lapsed-days): Update from article-lapsed-string, so as not to assume internal structure of Elisp timestamps. This should work better with future Emacs versions. --- ebdb-gnorb.el | 6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/ebdb-gnorb.el b/ebdb-gnorb.el index f210737..8a54fc9 100644 --- a/ebdb-gnorb.el +++ b/ebdb-gnorb.el @@ -128,10 +128,8 @@ message was received." ;; dates in the future, though that's stupid. (let* ((now (current-time)) (delta (time-subtract now date)) -(real-sec (and delta - (+ (* (float (car delta)) 65536) - (cadr delta -(sec (and delta (abs real-sec +(real-sec (float-time delta)) +(sec (abs real-sec))) (floor (/ sec 86400 (cl-defmethod ebdb-fmt-field ((_fmt ebdb-formatter-ebdb)
[elpa] externals/embark a6799a1 1/4: Preserve highlighting of heading target
branch: externals/embark commit a6799a1db68ddd1e24c6871e6a9ac853a7a2b025 Author: Daniel Mendler Commit: Daniel Mendler Preserve highlighting of heading target We also preserve the highlighting of other targets. --- embark.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/embark.el b/embark.el index 66f6d2c..05d64c2 100644 --- a/embark.el +++ b/embark.el @@ -849,7 +849,7 @@ As a convenience, in Org Mode an initial ' or surrounding == or ;; default definition from outline.el (or (bound-and-true-p outline-regexp) "[*\^L]+" (require 'outline) ;; Ensure that outline commands are available - `(heading ,(buffer-substring-no-properties beg end) ,beg . ,end + `(heading ,(buffer-substring beg end) ,beg . ,end (defun embark-target-top-minibuffer-completion () "Target the top completion candidate in the minibuffer.
[elpa] externals/embark updated (71d2601 -> 8525eea)
elpasync pushed a change to branch externals/embark. from 71d2601 Improve rules for promoting identifiers to Emacs Lisp symbols new 204fadd Fix the file target finder so it doesn't report :foo as the cwd new a6799a1 Preserve highlighting of heading target new 4decac9 Improve target truncation, omit empty lines and trim new 8525eea Merge pull request #424 from minad/nits Summary of changes: embark.el | 23 +-- 1 file changed, 13 insertions(+), 10 deletions(-)
[elpa] externals/embark-consult updated (71d2601 -> 8525eea)
elpasync pushed a change to branch externals/embark-consult. from 71d2601 Improve rules for promoting identifiers to Emacs Lisp symbols adds 204fadd Fix the file target finder so it doesn't report :foo as the cwd adds a6799a1 Preserve highlighting of heading target adds 4decac9 Improve target truncation, omit empty lines and trim adds 8525eea Merge pull request #424 from minad/nits No new revisions were added by this update. Summary of changes: embark.el | 23 +-- 1 file changed, 13 insertions(+), 10 deletions(-)
[elpa] externals/embark 4decac9 2/4: Improve target truncation, omit empty lines and trim
branch: externals/embark commit 4decac94c391e69c8cd022c152f77577f788a0a2 Author: Daniel Mendler Commit: Daniel Mendler Improve target truncation, omit empty lines and trim --- embark.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/embark.el b/embark.el index 05d64c2..96a7c06 100644 --- a/embark.el +++ b/embark.el @@ -942,7 +942,7 @@ If CYCLE is non-nil bind `embark-cycle'." (unless (stringp target) (setq target (format "%s" target))) (if-let (pos (string-match-p "\n" target)) - (concat (substring target 0 pos) "…") + (concat (car (split-string target "\n" 'omit-nulls "\\s-*")) "…") target)) (defun embark--act-label (rep multi)
[elpa] externals/embark 204fadd 3/4: Fix the file target finder so it doesn't report :foo as the cwd
branch: externals/embark commit 204fadd38c27576e3137b1386033c4ae37e075ad Author: Omar Antolín Commit: Omar Antolín Fix the file target finder so it doesn't report :foo as the cwd This fixes #423. --- embark.el | 19 +++ 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/embark.el b/embark.el index ada6391..c61778b 100644 --- a/embark.el +++ b/embark.el @@ -692,14 +692,17 @@ In `dired-mode', it uses `dired-get-filename' instead." (re-search-backward " " (line-beginning-position) 'noerror) (1+ (point))) . ,(point))) -(when-let (file (ffap-file-at-point)) - (unless (or (string-match-p "^/https?:/" file) - (when-let (filename (thing-at-point 'filename)) -(ffap-el-mode filename))) -`(file ,(abbreviate-file-name (expand-file-name file)) - ;; TODO the boundaries may be wrong, this should be generalized. - ;; Unfortunately ffap does not make the bounds available. - . ,(bounds-of-thing-at-point 'filename)) +(when-let* ((ffap-file (ffap-file-at-point)) +(tap-file (thing-at-point 'filename)) +;; check the thingatpt candidate is a substring of the +;; ffap candidate, this avoids URLs and keyword +;; symbols when point is on the colon (see bug#52441) +((string-match-p (regexp-quote tap-file) ffap-file)) +((not (ffap-el-mode tap-file + `(file ,(abbreviate-file-name (expand-file-name file)) + ;; TODO the boundaries may be wrong, this should be generalized. + ;; Unfortunately ffap does not make the bounds available. + . ,(bounds-of-thing-at-point 'filename) (defun embark-target-library-file-at-point () "Target the file of the Emacs Lisp library at point.
[elpa] externals/embark 8525eea 4/4: Merge pull request #424 from minad/nits
branch: externals/embark commit 8525eeadde99e985180860cbd431f95a37191b40 Merge: 204fadd 4decac9 Author: Omar Antolín Camarena Commit: GitHub Merge pull request #424 from minad/nits Nits --- embark.el | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/embark.el b/embark.el index c61778b..b3bfcb7 100644 --- a/embark.el +++ b/embark.el @@ -855,7 +855,7 @@ As a convenience, in Org Mode an initial ' or surrounding == or ;; default definition from outline.el (or (bound-and-true-p outline-regexp) "[*\^L]+" (require 'outline) ;; Ensure that outline commands are available - `(heading ,(buffer-substring-no-properties beg end) ,beg . ,end + `(heading ,(buffer-substring beg end) ,beg . ,end (defun embark-target-top-minibuffer-completion () "Target the top completion candidate in the minibuffer. @@ -950,7 +950,7 @@ If CYCLE is non-nil bind `embark-cycle'." (unless (stringp target) (setq target (format "%s" target))) (if-let (pos (string-match-p "\n" target)) - (concat (substring target 0 pos) "…") + (concat (car (split-string target "\n" 'omit-nulls "\\s-*")) "…") target)) (defun embark--act-label (rep multi)
[elpa] externals/embark 43ebe83 01/10: ..../---/.-- -.-./---/..-/.-../-.. .--/. ..-./---/.-./--././- -/...././.../. ...-/./.-./-.-- ../--/.--./---/.-./-/.-/-./- .-/-.-./-/../---/-./.../..--..
branch: externals/embark commit 43ebe83e1434c46171afa7744215118332cae2b9 Author: Daniel Mendler Commit: Daniel Mendler /---/.-- -.-./---/..-/.-../-.. .--/. ..-./---/.-./--././- -//./.../. ...-/./.-./-.-- ../--/.--./---/.-./-/.-/-./- .-/-.-./-/../---/-./.../..--.. --- embark.el | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/embark.el b/embark.el index 66f6d2c..313fdff 100644 --- a/embark.el +++ b/embark.el @@ -3600,6 +3600,8 @@ and leaves the point to the left of it." ("p" fill-region-as-paragraph) ("$" ispell-region) ("r" rot13-region) + (".." morse-region) + (".-" unmorse-region) ("=" count-words-region) ("s" whitespace-cleanup-region) ("t" transpose-regions) @@ -3687,7 +3689,8 @@ and leaves the point to the left of it." ("a" xref-find-apropos) ("s" info-lookup-symbol) ("n" embark-next-symbol) - ("p" embark-previous-symbol)) + ("p" embark-previous-symbol) + ("$" ispell-word)) (embark-define-keymap embark-expression-map "Keymap for Embark expression actions."
[elpa] externals/embark updated (8525eea -> 175f0ab)
elpasync pushed a change to branch externals/embark. from 8525eea Merge pull request #424 from minad/nits new 43ebe83 /---/.-- -.-./---/..-/.-../-.. .--/. ..-./---/.-./--././- -//./.../. ...-/./.-./-.-- ../--/.--./---/.-./-/.-/-./- .-/-.-./-/../---/-./.../..--.. new 8d692f8 Yrg'f qb guvf gura. new 4a99b93 Add embark-hash-* commands new 562f469 Avoid shadowing snapshot and export new 33ba374 Add format-encode-region and embark-encode-url encoding actions new c76552a Correct sha356 to sha384 new 7098441 Merge pull request #425 from minad/morse new bc460d9 Add action to decode a URL new 3579f1f Add minibuffer indicators for Vertico and Selectrum (Fix #427) new 175f0ab Merge pull request #428 from minad/indicators Summary of changes: embark.el | 87 ++- 1 file changed, 81 insertions(+), 6 deletions(-)
[elpa] externals/embark 7098441 07/10: Merge pull request #425 from minad/morse
branch: externals/embark commit 7098441bd639fccbb7e72426f9755d826433f6a2 Merge: 8525eea c76552a Author: Omar Antolín Camarena Commit: GitHub Merge pull request #425 from minad/morse /---/.-- -.-./---/..-/.-../-.. .--/. ..-./---/.-./--././- -//… --- embark.el | 57 +++-- 1 file changed, 51 insertions(+), 6 deletions(-) diff --git a/embark.el b/embark.el index b3bfcb7..87bf37b 100644 --- a/embark.el +++ b/embark.el @@ -452,6 +452,8 @@ the key :always are executed always." (count-words-region embark--mark-target) (shell-command-on-region embark--mark-target) (delete-region embark--mark-target) +(format-encode-region embark--mark-target embark--ignore-target) +(format-decode-region embark--mark-target embark--ignore-target) ;; commands we want to be able to jump back from ;; (embark-find-definition achieves this by calling ;; xref-find-definitions which pushes the markers itself) @@ -3481,6 +3483,30 @@ With a prefix argument EDEBUG, instrument the code for debugging." (all-completions (symbol-name prefix) obarray 'elp-profilable-p) +(defmacro embark--define-hash (algorithm) + "Define command which computes hash from a string. +ALGORITHM is the hash algorithm symbol understood by `secure-hash'." + `(defun ,(intern (format "embark-hash-%s" algorithm)) (str) + ,(format "Compute %s hash of STR and store it in the kill ring." algorithm) + (interactive "sString: ") + (let ((hash (secure-hash ',algorithm str))) + (kill-new hash) + (message "%s: %s" ',algorithm hash + +(embark--define-hash md5) +(embark--define-hash sha1) +(embark--define-hash sha224) +(embark--define-hash sha256) +(embark--define-hash sha384) +(embark--define-hash sha512) + +(defun embark-encode-url (start end);w + "Properly URI-encode the region between START and END in current buffer." + (interactive "r") + (let ((encoded (url-encode-url (buffer-substring-no-properties start end +(delete-region start end) +(insert encoded))) + ;;; Setup and pre-action hooks (defun embark--restart (&rest _) @@ -3569,6 +3595,25 @@ and leaves the point to the left of it." ("SPC" mark) ("DEL" delete-region)) +;; TODO add more encode actions, see M-x or C-h f encode region +(embark-define-keymap embark-encode-map + "Keymap for Embark region encoding actions." + :parent nil + ("r" rot13-region) + ("." morse-region) + ("-" unmorse-region) + ("m" embark-hash-md5) + ("1" embark-hash-sha1) + ("2" embark-hash-sha256) + ("3" embark-hash-sha384) + ("4" embark-hash-sha224) + ("5" embark-hash-sha512) + ("f" format-encode-region) + ("F" format-decode-region) + ("u" embark-encode-url)) + +(fset 'embark-encode-map embark-encode-map) + (embark-define-keymap embark-sort-map "Keymap for Embark actions that sort the region" :parent nil @@ -3582,7 +3627,6 @@ and leaves the point to the left of it." (fset 'embark-sort-map embark-sort-map) - ;; these will have autoloads in Emacs 28 (autoload 'calc-grab-sum-down "calc" nil t) (autoload 'calc-grab-sum-across "calc" nil t) @@ -3606,9 +3650,8 @@ and leaves the point to the left of it." ("f" fill-region) ("p" fill-region-as-paragraph) ("$" ispell-region) - ("r" rot13-region) ("=" count-words-region) - ("s" whitespace-cleanup-region) + ("SPC" whitespace-cleanup-region) ("t" transpose-regions) ("o" org-table-convert-region) (";" comment-or-uncomment-region) @@ -3619,9 +3662,10 @@ and leaves the point to the left of it." ("*" calc-grab-region) (":" calc-grab-sum-down) ("_" calc-grab-sum-across) - ("R" reverse-region) + ("r" reverse-region) ("D" delete-duplicate-lines) - ("S" 'embark-sort-map)) + ("s" 'embark-sort-map) + (">" 'embark-encode-map)) (embark-define-keymap embark-file-map "Keymap for Embark file actions." @@ -3694,7 +3738,8 @@ and leaves the point to the left of it." ("a" xref-find-apropos) ("s" info-lookup-symbol) ("n" embark-next-symbol) - ("p" embark-previous-symbol)) + ("p" embark-previous-symbol) + ("$" ispell-word)) (embark-define-keymap embark-expression-map "Keymap for Embark expression actions."
[elpa] externals/embark c76552a 06/10: Correct sha356 to sha384
branch: externals/embark commit c76552aeae285b9656f6901ec74f5986f2f265e4 Author: Omar Antolín Commit: Omar Antolín Correct sha356 to sha384 --- embark.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/embark.el b/embark.el index 732bcc2..c4ee828 100644 --- a/embark.el +++ b/embark.el @@ -3598,7 +3598,7 @@ and leaves the point to the left of it." ("m" embark-hash-md5) ("1" embark-hash-sha1) ("2" embark-hash-sha256) - ("3" embark-hash-sha356) + ("3" embark-hash-sha384) ("4" embark-hash-sha224) ("5" embark-hash-sha512) ("f" format-encode-region)
[elpa] externals/embark 562f469 04/10: Avoid shadowing snapshot and export
branch: externals/embark commit 562f4691b2fb0e25656e6513b87a90605ea83788 Author: Daniel Mendler Commit: Daniel Mendler Avoid shadowing snapshot and export --- embark.el | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/embark.el b/embark.el index 4c5b127..7b991e5 100644 --- a/embark.el +++ b/embark.el @@ -3632,7 +3632,7 @@ and leaves the point to the left of it." ("p" fill-region-as-paragraph) ("$" ispell-region) ("=" count-words-region) - ("s" whitespace-cleanup-region) + ("SPC" whitespace-cleanup-region) ("t" transpose-regions) ("o" org-table-convert-region) (";" comment-or-uncomment-region) @@ -3645,8 +3645,8 @@ and leaves the point to the left of it." ("_" calc-grab-sum-across) ("R" reverse-region) ("D" delete-duplicate-lines) - ("S" 'embark-sort-map) - ("E" 'embark-encode-map)) + ("s" 'embark-sort-map) + (">" 'embark-encode-map)) (embark-define-keymap embark-file-map "Keymap for Embark file actions."
[elpa] externals/embark 33ba374 05/10: Add format-encode-region and embark-encode-url encoding actions
branch: externals/embark commit 33ba374d03a883f4c26a1701b61737a55d5f7af3 Author: Omar Antolín Commit: Omar Antolín Add format-encode-region and embark-encode-url encoding actions --- embark.el | 16 ++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/embark.el b/embark.el index 7b991e5..732bcc2 100644 --- a/embark.el +++ b/embark.el @@ -452,6 +452,8 @@ the key :always are executed always." (count-words-region embark--mark-target) (shell-command-on-region embark--mark-target) (delete-region embark--mark-target) +(format-encode-region embark--mark-target embark--ignore-target) +(format-decode-region embark--mark-target embark--ignore-target) ;; commands we want to be able to jump back from ;; (embark-find-definition achieves this by calling ;; xref-find-definitions which pushes the markers itself) @@ -3491,6 +3493,13 @@ ALGORITHM is the hash algorithm symbol understood by `secure-hash'." (embark--define-hash sha384) (embark--define-hash sha512) +(defun embark-encode-url (start end);w + "Properly URI-encode the region between START and END in current buffer." + (interactive "r") + (let ((encoded (url-encode-url (buffer-substring-no-properties start end +(delete-region start end) +(insert encoded))) + ;;; Setup and pre-action hooks (defun embark--restart (&rest _) @@ -3591,7 +3600,10 @@ and leaves the point to the left of it." ("2" embark-hash-sha256) ("3" embark-hash-sha356) ("4" embark-hash-sha224) - ("5" embark-hash-sha512)) + ("5" embark-hash-sha512) + ("f" format-encode-region) + ("F" format-decode-region) + ("u" embark-encode-url)) (fset 'embark-encode-map embark-encode-map) @@ -3643,7 +3655,7 @@ and leaves the point to the left of it." ("*" calc-grab-region) (":" calc-grab-sum-down) ("_" calc-grab-sum-across) - ("R" reverse-region) + ("r" reverse-region) ("D" delete-duplicate-lines) ("s" 'embark-sort-map) (">" 'embark-encode-map))
[elpa] externals/embark 8d692f8 02/10: Yrg'f qb guvf gura.
branch: externals/embark commit 8d692f85cc5b81d4b72faab7aaacbf65009caf08 Author: Daniel Mendler Commit: Daniel Mendler Yrg'f qb guvf gura. Gur dhrfgvba vf vs jr arrq n qvssrerag punenpgre orpnhfr bs gur rkcbeg funqbjvat. --- embark.el | 17 - 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/embark.el b/embark.el index 313fdff..b1cbccb 100644 --- a/embark.el +++ b/embark.el @@ -3562,6 +3562,16 @@ and leaves the point to the left of it." ("SPC" mark) ("DEL" delete-region)) +;; TODO add more encode actions, see M-x or C-h f encode region +(embark-define-keymap embark-encode-map + "Keymap for Embark region encoding actions." + :parent nil + ("r" rot13-region) + ("." morse-region) + ("-" unmorse-region)) + +(fset 'embark-encode-map embark-encode-map) + (embark-define-keymap embark-sort-map "Keymap for Embark actions that sort the region" :parent nil @@ -3575,7 +3585,6 @@ and leaves the point to the left of it." (fset 'embark-sort-map embark-sort-map) - ;; these will have autoloads in Emacs 28 (autoload 'calc-grab-sum-down "calc" nil t) (autoload 'calc-grab-sum-across "calc" nil t) @@ -3599,9 +3608,6 @@ and leaves the point to the left of it." ("f" fill-region) ("p" fill-region-as-paragraph) ("$" ispell-region) - ("r" rot13-region) - (".." morse-region) - (".-" unmorse-region) ("=" count-words-region) ("s" whitespace-cleanup-region) ("t" transpose-regions) @@ -3616,7 +3622,8 @@ and leaves the point to the left of it." ("_" calc-grab-sum-across) ("R" reverse-region) ("D" delete-duplicate-lines) - ("S" 'embark-sort-map)) + ("S" 'embark-sort-map) + ("E" 'embark-encode-map)) (embark-define-keymap embark-file-map "Keymap for Embark file actions."
[elpa] externals/embark 4a99b93 03/10: Add embark-hash-* commands
branch: externals/embark commit 4a99b93192a05198bfec0a68439ef356ceb1da96 Author: Daniel Mendler Commit: Daniel Mendler Add embark-hash-* commands --- embark.el | 25 - 1 file changed, 24 insertions(+), 1 deletion(-) diff --git a/embark.el b/embark.el index b1cbccb..4c5b127 100644 --- a/embark.el +++ b/embark.el @@ -3474,6 +3474,23 @@ With a prefix argument EDEBUG, instrument the code for debugging." (all-completions (symbol-name prefix) obarray 'elp-profilable-p) +(defmacro embark--define-hash (algorithm) + "Define command which computes hash from a string. +ALGORITHM is the hash algorithm symbol understood by `secure-hash'." + `(defun ,(intern (format "embark-hash-%s" algorithm)) (str) + ,(format "Compute %s hash of STR and store it in the kill ring." algorithm) + (interactive "sString: ") + (let ((hash (secure-hash ',algorithm str))) + (kill-new hash) + (message "%s: %s" ',algorithm hash + +(embark--define-hash md5) +(embark--define-hash sha1) +(embark--define-hash sha224) +(embark--define-hash sha256) +(embark--define-hash sha384) +(embark--define-hash sha512) + ;;; Setup and pre-action hooks (defun embark--restart (&rest _) @@ -3568,7 +3585,13 @@ and leaves the point to the left of it." :parent nil ("r" rot13-region) ("." morse-region) - ("-" unmorse-region)) + ("-" unmorse-region) + ("m" embark-hash-md5) + ("1" embark-hash-sha1) + ("2" embark-hash-sha256) + ("3" embark-hash-sha356) + ("4" embark-hash-sha224) + ("5" embark-hash-sha512)) (fset 'embark-encode-map embark-encode-map)
[elpa] externals/embark 3579f1f 09/10: Add minibuffer indicators for Vertico and Selectrum (Fix #427)
branch: externals/embark commit 3579f1fd0d85428dd075bb8af6a61a576a9266e7 Author: Daniel Mendler Commit: Daniel Mendler Add minibuffer indicators for Vertico and Selectrum (Fix #427) --- embark.el | 22 ++ 1 file changed, 22 insertions(+) diff --git a/embark.el b/embark.el index 66f6d2c..e72c588 100644 --- a/embark.el +++ b/embark.el @@ -3127,7 +3127,18 @@ Return the category metadatum as the type of the candidates." (cons (completion-metadata-get (embark--metadata) 'category) vertico--candidates))) +(defun embark--vertico-indicator () + "Embark indicator highlighting the current Vertico candidate." + (let ((fr face-remapping-alist)) +(lambda (&optional keymap _targets _prefix) + (when vertico--input +(setq-local face-remapping-alist +(if keymap +(cons '(vertico-current . embark-target) fr) + fr)) + (with-eval-after-load 'vertico + (add-hook 'embark-indicators #'embark--vertico-indicator) (add-hook 'embark-target-finders #'embark--vertico-selected) (add-hook 'embark-candidate-collectors #'embark--vertico-candidates)) @@ -3162,7 +3173,18 @@ Return the category metadatum as the type of the candidates." ;; Pass relative file names for dired. minibuffer-completing-file-name +(defun embark--selectrum-indicator () + "Embark indicator highlighting the current Selectrum candidate." + (let ((fr face-remapping-alist)) +(lambda (&optional keymap _targets _prefix) + (when selectrum-is-active +(setq-local face-remapping-alist +(if keymap +(cons '(selectrum-current-candidate . embark-target) fr) + fr)) + (with-eval-after-load 'selectrum + (add-hook 'embark-indicators #'embark--selectrum-indicator) (add-hook 'embark-target-finders #'embark--selectrum-selected) (add-hook 'embark-candidate-collectors #'embark--selectrum-candidates))
[elpa] externals/embark bc460d9 08/10: Add action to decode a URL
branch: externals/embark commit bc460d9654c1728b7f8ffd5df8939c1f0054c32f Author: Omar Antolín Commit: Omar Antolín Add action to decode a URL --- embark.el | 12 ++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/embark.el b/embark.el index 87bf37b..c294773 100644 --- a/embark.el +++ b/embark.el @@ -3500,13 +3500,20 @@ ALGORITHM is the hash algorithm symbol understood by `secure-hash'." (embark--define-hash sha384) (embark--define-hash sha512) -(defun embark-encode-url (start end);w +(defun embark-encode-url (start end) "Properly URI-encode the region between START and END in current buffer." (interactive "r") (let ((encoded (url-encode-url (buffer-substring-no-properties start end (delete-region start end) (insert encoded))) +(defun embark-decode-url (start end) + "Decode the URI-encoded region between START and END in current buffer." + (interactive "r") + (let ((decoded (url-unhex-string (buffer-substring-no-properties start end +(delete-region start end) +(insert decoded))) + ;;; Setup and pre-action hooks (defun embark--restart (&rest _) @@ -3610,7 +3617,8 @@ and leaves the point to the left of it." ("5" embark-hash-sha512) ("f" format-encode-region) ("F" format-decode-region) - ("u" embark-encode-url)) + ("u" embark-encode-url) + ("U" embark-decode-url)) (fset 'embark-encode-map embark-encode-map)
[elpa] externals/embark 175f0ab 10/10: Merge pull request #428 from minad/indicators
branch: externals/embark commit 175f0abaf6b1538533e245358bbbe42e27567822 Merge: bc460d9 3579f1f Author: Omar Antolín Camarena Commit: GitHub Merge pull request #428 from minad/indicators Add minibuffer indicators for Vertico and Selectrum (Fix #427) --- embark.el | 22 ++ 1 file changed, 22 insertions(+) diff --git a/embark.el b/embark.el index c294773..a057762 100644 --- a/embark.el +++ b/embark.el @@ -3136,7 +3136,18 @@ Return the category metadatum as the type of the candidates." (cons (completion-metadata-get (embark--metadata) 'category) vertico--candidates))) +(defun embark--vertico-indicator () + "Embark indicator highlighting the current Vertico candidate." + (let ((fr face-remapping-alist)) +(lambda (&optional keymap _targets _prefix) + (when vertico--input +(setq-local face-remapping-alist +(if keymap +(cons '(vertico-current . embark-target) fr) + fr)) + (with-eval-after-load 'vertico + (add-hook 'embark-indicators #'embark--vertico-indicator) (add-hook 'embark-target-finders #'embark--vertico-selected) (add-hook 'embark-candidate-collectors #'embark--vertico-candidates)) @@ -3171,7 +3182,18 @@ Return the category metadatum as the type of the candidates." ;; Pass relative file names for dired. minibuffer-completing-file-name +(defun embark--selectrum-indicator () + "Embark indicator highlighting the current Selectrum candidate." + (let ((fr face-remapping-alist)) +(lambda (&optional keymap _targets _prefix) + (when selectrum-is-active +(setq-local face-remapping-alist +(if keymap +(cons '(selectrum-current-candidate . embark-target) fr) + fr)) + (with-eval-after-load 'selectrum + (add-hook 'embark-indicators #'embark--selectrum-indicator) (add-hook 'embark-target-finders #'embark--selectrum-selected) (add-hook 'embark-candidate-collectors #'embark--selectrum-candidates))
[elpa] externals/embark-consult updated (8525eea -> 175f0ab)
elpasync pushed a change to branch externals/embark-consult. from 8525eea Merge pull request #424 from minad/nits adds 43ebe83 /---/.-- -.-./---/..-/.-../-.. .--/. ..-./---/.-./--././- -//./.../. ...-/./.-./-.-- ../--/.--./---/.-./-/.-/-./- .-/-.-./-/../---/-./.../..--.. adds 8d692f8 Yrg'f qb guvf gura. adds 4a99b93 Add embark-hash-* commands adds 562f469 Avoid shadowing snapshot and export adds 33ba374 Add format-encode-region and embark-encode-url encoding actions adds c76552a Correct sha356 to sha384 adds 7098441 Merge pull request #425 from minad/morse adds bc460d9 Add action to decode a URL adds 3579f1f Add minibuffer indicators for Vertico and Selectrum (Fix #427) adds 175f0ab Merge pull request #428 from minad/indicators No new revisions were added by this update. Summary of changes: embark.el | 87 ++- 1 file changed, 81 insertions(+), 6 deletions(-)
[elpa] externals/embark-consult updated (175f0ab -> 33b47bb)
elpasync pushed a change to branch externals/embark-consult. from 175f0ab Merge pull request #428 from minad/indicators adds 33b47bb Revert binding default action to No new revisions were added by this update. Summary of changes: embark.el | 1 - 1 file changed, 1 deletion(-)
[elpa] externals/embark 33b47bb: Revert binding default action to
branch: externals/embark commit 33b47bb8999f8c7d67e9d1e04668e421e3c7246f Author: Omar Antolín Commit: Omar Antolín Revert binding default action to Yes, it's annoying if the enter key doesn't run the default action, but few modes have a binding for , so it's not really a big problem and it had an even more annoying consequence: the completing-read prompter said, "the default action is so nice, I think I'm going to list it twice!". --- embark.el | 1 - 1 file changed, 1 deletion(-) diff --git a/embark.el b/embark.el index a057762..50f5de3 100644 --- a/embark.el +++ b/embark.el @@ -938,7 +938,6 @@ If CYCLE is non-nil bind `embark-cycle'." (let ((map (make-sparse-keymap)) (default-action (embark--default-action type))) (define-key map [13] default-action) - (define-key map [return] default-action) (when-let ((cycle-key (and cycle (embark--cycle-key (define-key map cycle-key #'embark-cycle)) (when embark-help-key
[elpa] externals/wcheck-mode b52fa9d: Simplify/port wcheck--current-idle-time-seconds
branch: externals/wcheck-mode commit b52fa9dcd75bd9758fffc54f769bcd42a58ef6ba Author: Paul Eggert Commit: Paul Eggert Simplify/port wcheck--current-idle-time-seconds Simplify wcheck--current-idle-time-seconds and port it to future versions of Emacs that will use a different timestamp format. --- wcheck-mode.el | 9 + 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/wcheck-mode.el b/wcheck-mode.el index 40c57c0..74d980a 100644 --- a/wcheck-mode.el +++ b/wcheck-mode.el @@ -2059,14 +2059,7 @@ a (valid) value for the KEY then query the value from (defun wcheck--current-idle-time-seconds () "Return current idle time in seconds. The returned value is a floating point number." - (let* ((idle (or (current-idle-time) - '(0 0 0))) - (high (nth 0 idle)) - (low (nth 1 idle)) - (micros (nth 2 idle))) -(+ (* high 65536) - low - (/ micros 100.0 + (float-time (or (current-idle-time) 0))) (defun wcheck--combine-overlapping-areas (alist)
[elpa] externals/dismal caf876e: Simplify/port log-timer-filter args
branch: externals/dismal commit caf876e479df7d98efe702cacd90c1b637c90144 Author: Paul Eggert Commit: Paul Eggert Simplify/port log-timer-filter args * packages/dismal/log.el (log-keystroke, log-stamp-date): Simplify and remove dependency on Emacs timestamp format, which is planned to change in future Emacs versions. --- log.el | 14 ++ 1 file changed, 2 insertions(+), 12 deletions(-) diff --git a/log.el b/log.el index e0bfaaa..fd2c5c6 100644 --- a/log.el +++ b/log.el @@ -337,12 +337,7 @@ already wrapped. PREFIX is an optional string, usually the command prefix." (indent-to-column 11 2) ; whitespace (insert the-command); command name (indent-to-column 40 1)) ; effects column, prior to timestamp - (log-timer-filter (let ((time (current-time))) - (format "%05d.%03d" - (mod (+ (* 65536 (car time)) - (nth 1 time)) - 10) - (/ (nth 2 time) 1000)) + (log-timer-filter (format "%09.3f" (mod (float-time) 10) nil) (defun log-stamp-date () @@ -364,12 +359,7 @@ already wrapped. PREFIX is an optional string, usually the command prefix." (t (format "%s" last-input-event ;;(indent-to-column 11 2) ) - (log-timer-filter (let ((time (current-time))) - (format "%05d.%03d" - (mod (+ (* 65536 (car time)) - (nth 1 time)) - 10) - (/ (nth 2 time) 1000))) + (log-timer-filter (format "%09.3f" (mod (float-time time) 10)) ;; 10-1-93 - use a filter rather than an output buffer: (defvar log-timestamp nil)
[elpa] externals/chess e30ddb4: Simplify/port chess clock timer
branch: externals/chess commit e30ddb4e9eda043d0ea357a52017f20e71ec05cf Author: Paul Eggert Commit: Paul Eggert Simplify/port chess clock timer * packages/chess/chess-clock.el (chess-clock-add-seconds) (chess-clock-time-to-seconds): Simplify and port to future Emacs versions planned to use different time stamp formats. --- chess-clock.el | 12 ++-- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/chess-clock.el b/chess-clock.el index 2fe7167..c08b4b2 100644 --- a/chess-clock.el +++ b/chess-clock.el @@ -32,19 +32,11 @@ (defsubst chess-clock-add-seconds (time seconds) "To TIME, add SECONDS. Return result as a time value." - (let* ((secint (truncate seconds)) -(hi (/ secint 65536)) -(lo (% secint 65536)) -(calc (+ (cadr time) lo))) -(if (< calc 65536) - (list (+ (car time) hi) calc) - (list (+ (car time) (1+ hi)) (% calc 65536) + (time-add time seconds)) (defsubst chess-clock-time-to-seconds (time) "Convert TIME to a floating point number." - (+ (* (car time) 65536.0) - (cadr time) - (/ (or (car (cdr (cdr time))) 0) 100.0))) + (float-time time)) (defsubst chess-clock-time-diff (t1 t2) "Return the difference in seconds between T1 and T2."
[elpa] externals/brief 1846c0e: Simplify/port brief-current-time
branch: externals/brief commit 1846c0ea00d18bf8cb47aaf8fcb7150eb94ea2db Author: Paul Eggert Commit: Paul Eggert Simplify/port brief-current-time * brief.el (brief-current-time): Simplify and port it to future Emacs versions planned to use a different timestamp format. --- brief.el | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/brief.el b/brief.el index b5b26fe..e91ce94 100644 --- a/brief.el +++ b/brief.el @@ -624,10 +624,7 @@ If FILE1 or FILE2 does not exist, the return value is unspecified." ;; Helper functions and macros (defun brief-current-time () "Epoch time in floating point." - (let ((ct (current-time))) -(+ (logior (lsh (car ct) 16) - (cadr ct)) - (* 1e-6 (caddr ct) + (float-time)) (defvar brief-calibration-value 0.0 "Latest calibration value of UI performance.
[elpa] externals/gnugo b145596: Port scoring-seed code to future Emacs
branch: externals/gnugo commit b145596924334e2516ca50d2cd747804fd56d498 Author: Paul Eggert Commit: Paul Eggert Port scoring-seed code to future Emacs * packages/gnugo/gnugo.el (gnugo-close-game): Don’t assume Emacs internal timestamp format, as it is planned to change in future versions. --- gnugo.el | 8 +--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/gnugo.el b/gnugo.el index 5dbc06a..dd5baea 100644 --- a/gnugo.el +++ b/gnugo.el @@ -849,9 +849,11 @@ For all other values of RSEL, do nothing and return nil." (defun gnugo-close-game (end-time resign) (gnugo-put :game-end-time end-time) - (let ((now (or end-time (current-time -(gnugo-put :scoring-seed (logior (ash (logand (car now) 255) 16) - (cadr now + (gnugo-put :scoring-seed +(if (fboundp 'time-convert) +(logand (time-convert end-time 'integer) #xff) + (let ((now (or end-time (current-time +(logior (ash (logand (car now) 255) 16) (cadr now) (gnugo-put :game-over (cl-flet ;; Q: What form does a game-over "group" take?
[elpa] externals/cpio-mode 75891ef: Don’t assume Emacs timestamp format
branch: externals/cpio-mode commit 75891efd33e720208f4d353e892f8ed590f45d7d Author: Paul Eggert Commit: Paul Eggert Don’t assume Emacs timestamp format * cpio-mode.el (cpio-set-mtime): On newer Emacs, convert the timestamp to list format since it may be in some other form. (cpio-create-entry-attrs, cpio-create-faux-directory-attrs): Use cpio-set-time to set mtime. --- cpio-mode.el | 8 +--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/cpio-mode.el b/cpio-mode.el index 63be87e..2793486 100644 --- a/cpio-mode.el +++ b/cpio-mode.el @@ -927,6 +927,8 @@ MODE is either an integer or a string representing an integer." "Set the modification time in the PARSED-HEADER to MTIME. MTIME is an emacs time." (let ((fname "cpio-set-mtime")) +(if (fboundp 'time-convert) + (setq mtime (time-convert mtime 'list))) (aset parsed-header *cpio-mtime-parsed-idx* mtime))) (defun cpio-extract-all () @@ -1426,7 +1428,7 @@ Run more than one instance of emacs to avoid such collisions." (aset result *cpio-gid-parsed-idx* gid) (aset result *cpio-nlink-parsed-idx* nlink) -(aset result *cpio-mtime-parsed-idx* (seconds-to-time mtime)) +(cpio-set-mtime result mtime) (aset result *cpio-entry-size-parsed-idx* entry-size) (aset result *cpio-dev-maj-parsed-idx*dev-maj) @@ -1462,7 +1464,6 @@ many are simply invented." (nlink 1) (now (current-time)) -(mtime (list (nth 0 now) (nth 1 now))) (entry-size 0) (dev-maj 1) @@ -1478,6 +1479,7 @@ many are simply invented." (aset result *cpio-gid-parsed-idx* gid) (aset result *cpio-nlink-parsed-idx* nlink) +(cpio-set-mtime result now) (aset result *cpio-mtime-parsed-idx* mtime) (aset result *cpio-entry-size-parsed-idx* entry-size) (aset result *cpio-dev-maj-parsed-idx*dev-maj) @@ -1756,7 +1758,7 @@ or nil." ;; ;; EO temporary code for development ;; - + (let ((archive-buffer (current-buffer)) (cpio-dired-buffer)) ;; You really only need this for the binary archive formats,
[elpa] externals/wcheck-mode e1c86e6: Version 2021
branch: externals/wcheck-mode commit e1c86e6f9e150ed25efb58fcf21db374b1b7f519 Author: Teemu Likonen Commit: Teemu Likonen Version 2021 --- wcheck-mode.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wcheck-mode.el b/wcheck-mode.el index 74d980a..573fa14 100644 --- a/wcheck-mode.el +++ b/wcheck-mode.el @@ -7,7 +7,7 @@ ;; Created: 2009-07-04 ;; URL: https://github.com/tlikonen/wcheck-mode ;; Keywords: text spell check languages ispell -;; Version: 2020.10.4 +;; Version: 2021 ;; This program is free software: you can redistribute it and/or modify ;; it under the terms of the GNU General Public License as published by