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

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

[elpa] externals/embark 5acf2b6929 2/2: Merge branch 'master' of https:/


From: ELPA Syncer
Subject: [elpa] externals/embark 5acf2b6929 2/2: Merge branch 'master' of https://github.com/oantolin/embark
Date: Sun, 23 Apr 2023 17:58:20 -0400 (EDT)

branch: externals/embark
commit 5acf2b6929dd12bbf0c276ce8c08649d0dfebc5a
Merge: bfcda38514 c914efe881
Author: Omar Antolín <omar.antolin@gmail.com>
Commit: Omar Antolín <omar.antolin@gmail.com>

    Merge branch 'master' of https://github.com/oantolin/embark
---
 CHANGELOG.org | 10 +++++-----
 README.org    | 21 ++++++++++-----------
 embark.el     | 16 ++++++++--------
 embark.texi   | 21 ++++++++++-----------
 4 files changed, 33 insertions(+), 35 deletions(-)

diff --git a/CHANGELOG.org b/CHANGELOG.org
index 2943d15e6a..caacb85806 100644
--- a/CHANGELOG.org
+++ b/CHANGELOG.org
@@ -1,12 +1,12 @@
 #+title: Embark changelog
-* Version 0.22 (2020-04-20)
+* Version 0.22.1 (2020-04-20)
 ** New feature: selections
 Now users can select several targets to make an ad hoc collection. The
 commands =embark-act-all=, =embark-export= and =embark-collect= will act on
 the selection if it is non-empty. To select or deselect a target use
-the =embark-toggle-select= action (bound to =SPC= in =embark-general-map=).
-If you have some targets selected, then using =embark-toggle-select=
-through =embark-act-all= will deselect them.
+the =embark-select= action (bound to =SPC= in =embark-general-map=). If you
+have some targets selected, then using =embark-select= through
+=embark-act-all= will deselect them.
 
 Before this change the Embark Collect buffers had their own
 implementation of selections which has been removed. This is how to
@@ -24,7 +24,7 @@ all buffers, not just Embark Collect buffers!):
 [1] Marking all candidates (with either the old =t= or the new =A SPC=)
 requires that there are no marked candidates to begin with.
 
-In order to make room for the binding of =embark-toggle-select= to
+In order to make room for the binding of =embark-select= to
 =SPC=, some other key bindings were moved:
 
 - =mark= in =embark-general-map= was moved to =C-SPC=.
diff --git a/README.org b/README.org
index 177a7cd761..483da47e5c 100644
--- a/README.org
+++ b/README.org
@@ -176,9 +176,9 @@ sets:
   The candidates are displayed as a list showing additional annotations.
 
   The Embark Collect buffer is somewhat "dired-like": you can select
-  and deselect candidates through the =embark-toggle-select= action
-  (bound to =SPC=). In an Embark Collect buffer =embark-act= is bound to =a=
-  and =embark-act-all= is bound to =A=; =embark-act-all= will act on all
+  and deselect candidates through the =embark-select= action (bound to
+  =SPC=). In an Embark Collect buffer =embark-act= is bound to =a= and
+  =embark-act-all= is bound to =A=; =embark-act-all= will act on all
   currently marked candidates if there any, and will act on all
   candidates if none are marked. In particular, this means that =a SPC=
   will toggle whether the candidate at point is selected, and =A SPC=
@@ -230,8 +230,8 @@ or in a dired buffer they work on all marked files (or all 
files if
 none are marked). Embark also has a notion of /selection/, where you can
 accumulate an ad hoc list of targets for these commands to work on.
 
-The selection is controlled by using the =embark-toggle-select= action
-(which must be run as an action through =embark-act=), bound to =SPC= in
+The selection is controlled by using the =embark-select= action (which
+must be run as an action through =embark-act=), bound to =SPC= in
 =embark-general-map= so that it is always available. Calling this action
 on a target toggles its membership in the current buffer's Embark
 selection; that is, it adds it to selection if not selected and
@@ -239,12 +239,11 @@ removes it from the selection if it was selected. 
Whenever the
 selection for a buffer is non-empty, the commands =embark-act-all=,
 =embark-export= and =embark-collect= will act on the selection.
 
-To deselect all selected targets, you can use the =embark-toggle-select=
-action through =embark-act-all=, since this will run
-=embark-toggle-select= on each member of the current selection.
-Similarly if no targets are selected and you are in a minibuffer
-completion session, running =embark-toggle-select= from =embark-act-all=
-will select all the current completion candidates.
+To deselect all selected targets, you can use the =embark-select= action
+through =embark-act-all=, since this will run =embark-select= on each
+member of the current selection. Similarly if no targets are selected
+and you are in a minibuffer completion session, running =embark-select=
+from =embark-act-all= will select all the current completion candidates.
 
 This functionality is supported everywhere:
 
diff --git a/embark.el b/embark.el
index 4853140c6f..e526e78755 100644
--- a/embark.el
+++ b/embark.el
@@ -5,7 +5,7 @@
 ;; Author: Omar Antolín Camarena <omar@matem.unam.mx>
 ;; Maintainer: Omar Antolín Camarena <omar@matem.unam.mx>
 ;; Keywords: convenience
-;; Version: 0.22
+;; Version: 0.22.1
 ;; Homepage: https://github.com/oantolin/embark
 ;; Package-Requires: ((emacs "27.1") (compat "29.1.4.0"))
 
@@ -412,7 +412,7 @@ the key :always are executed always."
     (shell embark--universal-argument)
     (eshell embark--universal-argument)
     ;; do the actual work of selecting & deselecting targets
-    (embark-toggle-select embark--toggle-select))
+    (embark-select embark--select))
   "Alist associating commands with pre-action hooks.
 The hooks are run right before an action is embarked upon.  See
 `embark-target-injection-hooks' for information about the hook
@@ -1901,7 +1901,7 @@ minibuffer before executing the action."
                      embark-collect      ; the current buffer, not the
                      embark-live         ; target buffer
                      embark-export
-                     embark-toggle-select
+                     embark-select
                      embark-act-all))
       (progn
         (embark--run-action-hooks embark-pre-action-hooks action target quit)
@@ -3233,10 +3233,10 @@ PRED is a predicate function used to filter the items."
 
 (defvar-local embark--selection nil
   "Buffer local list of selected targets.
-Add or remove elements to this list using the
-`embark-toggle-select' action.")
+Add or remove elements to this list using the `embark-select'
+action.")
 
-(cl-defun embark--toggle-select
+(cl-defun embark--select
     (&key orig-target orig-type bounds &allow-other-keys)
   "Add or remove ORIG-TARGET of given ORIG-TYPE to the selection.
 If BOUNDS are given, also highlight the target when selecting it."
@@ -3265,7 +3265,7 @@ If BOUNDS are given, also highlight the target when 
selecting it."
                              target)
         (push (cons target overlay) embark--selection)))))
 
-(defalias 'embark-toggle-select #'ignore
+(defalias 'embark-select #'ignore
   "Add or remove the target from the current buffer's selection.
 You can act on all selected targets at once with `embark-act-all'.")
 
@@ -3945,7 +3945,7 @@ This simply calls RUN with the REST of its arguments 
inside
   "C-s" #'embark-isearch
   "C-SPC" #'mark
   "DEL" #'delete-region
-  "SPC" #'embark-toggle-select)
+  "SPC" #'embark-select)
 
 (defvar-keymap embark-encode-map
   :doc "Keymap for Embark region encoding actions."
diff --git a/embark.texi b/embark.texi
index aa48b22054..89a4e5f128 100644
--- a/embark.texi
+++ b/embark.texi
@@ -279,9 +279,9 @@ candidates, for you to peruse and run actions on at your 
leisure.
 The candidates are displayed as a list showing additional annotations.
 
 The Embark Collect buffer is somewhat ``dired-like'': you can select
-and deselect candidates through the @samp{embark-toggle-select} action
-(bound to @samp{SPC}). In an Embark Collect buffer @samp{embark-act} is bound 
to @samp{a}
-and @samp{embark-act-all} is bound to @samp{A}; @samp{embark-act-all} will act 
on all
+and deselect candidates through the @samp{embark-select} action (bound to
+@samp{SPC}). In an Embark Collect buffer @samp{embark-act} is bound to 
@samp{a} and
+@samp{embark-act-all} is bound to @samp{A}; @samp{embark-act-all} will act on 
all
 currently marked candidates if there any, and will act on all
 candidates if none are marked. In particular, this means that @samp{a SPC}
 will toggle whether the candidate at point is selected, and @samp{A SPC}
@@ -341,8 +341,8 @@ or in a dired buffer they work on all marked files (or all 
files if
 none are marked). Embark also has a notion of @emph{selection}, where you can
 accumulate an ad hoc list of targets for these commands to work on.
 
-The selection is controlled by using the @samp{embark-toggle-select} action
-(which must be run as an action through @samp{embark-act}), bound to 
@samp{SPC} in
+The selection is controlled by using the @samp{embark-select} action (which
+must be run as an action through @samp{embark-act}), bound to @samp{SPC} in
 @samp{embark-general-map} so that it is always available. Calling this action
 on a target toggles its membership in the current buffer's Embark
 selection; that is, it adds it to selection if not selected and
@@ -350,12 +350,11 @@ removes it from the selection if it was selected. 
Whenever the
 selection for a buffer is non-empty, the commands @samp{embark-act-all},
 @samp{embark-export} and @samp{embark-collect} will act on the selection.
 
-To deselect all selected targets, you can use the @samp{embark-toggle-select}
-action through @samp{embark-act-all}, since this will run
-@samp{embark-toggle-select} on each member of the current selection.
-Similarly if no targets are selected and you are in a minibuffer
-completion session, running @samp{embark-toggle-select} from 
@samp{embark-act-all}
-will select all the current completion candidates.
+To deselect all selected targets, you can use the @samp{embark-select} action
+through @samp{embark-act-all}, since this will run @samp{embark-select} on each
+member of the current selection. Similarly if no targets are selected
+and you are in a minibuffer completion session, running @samp{embark-select}
+from @samp{embark-act-all} will select all the current completion candidates.
 
 This functionality is supported everywhere:
 



reply via email to

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