[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/transient 0312b9302d 099/366: transient-args: Remove SE
From: |
Jonas Bernoulli |
Subject: |
[elpa] externals/transient 0312b9302d 099/366: transient-args: Remove SEPARATE argument |
Date: |
Tue, 25 Jan 2022 18:54:30 -0500 (EST) |
branch: externals/transient
commit 0312b9302de51e5ed71c9663f5641e8d8e71be43
Author: Jonas Bernoulli <jonas@bernoul.li>
Commit: Jonas Bernoulli <jonas@bernoul.li>
transient-args: Remove SEPARATE argument
---
docs/transient.org | 17 +----------------
lisp/transient.el | 37 +++++++++----------------------------
2 files changed, 10 insertions(+), 44 deletions(-)
diff --git a/docs/transient.org b/docs/transient.org
index e9dd23327e..171817b112 100644
--- a/docs/transient.org
+++ b/docs/transient.org
@@ -1000,7 +1000,7 @@ The preferred way of doing that is to call the
~transient-args~
function, which for infix arguments serves about the same purpose as
~prefix-arg~ serves for prefix arguments.
-- Function: transient-args &optional prefix separate
+- Function: transient-args &optional prefix
This function returns the value of the transient from which the
current suffix was called. If the current suffix command was not
@@ -1012,21 +1012,6 @@ function, which for infix arguments serves about the
same purpose as
Otherwise ~nil~ is returned. This function is also used internally,
in which PREFIX can also be a ~transient-prefix~ object.
- If optional SEPARATE is non-~nil~, then the arguments are separated
- into two groups. If SEPARATE is ~t~, they are separated into atoms
- and conses (~nil~ isn't a valid value, so it doesn't matter that that
- is both an atom and a cons).
-
- SEPARATE can also be a predicate function, in which case the first
- element is a list of the values for which it returns non-~nil~ and the
- second element is a list of the values for which it returns ~nil~.
-
- For transients that are used to pass arguments to a subprocess (such
- as ~git~), ~stringp~ is a useful value for SEPARATE, it separates
- non-positional arguments from positional arguments. The value of
- Magit's file argument (~"--"~) for example looks like this: ~("--"
- file...)~."
-
- Variable: current-transient-suffixes
The suffixes of the transient from which this suffix command was
diff --git a/lisp/transient.el b/lisp/transient.el
index ca60c31440..56c1761390 100644
--- a/lisp/transient.el
+++ b/lisp/transient.el
@@ -2035,7 +2035,7 @@ around `scroll-down-command' (which see)."
;;; Value
;;;; Core
-(defun transient-args (&optional prefix separate)
+(defun transient-args (&optional prefix)
"Return the value of the transient from which the current suffix was called.
If optional PREFIX is non-nil, then it should be a symbol, a
@@ -2043,33 +2043,14 @@ transient prefix command. In that case only return the
value
of the transient if the suffix was actually invoked from that
transient. Otherwise return nil. This function is also used
internally, in which PREFIX can also be a `transient-prefix'
-object.
-
-If optional SEPARATE is non-nil, then separate the arguments
-into two groups. If SEPARATE is t, then separate into atoms
-and conses (nil isn't a valid value, so it doesn't matter that
-that is both an atom and a cons).
-
-SEPARATE can also be a predicate function, in which case the
-first element is a list of the values for which it returns
-non-nil and the second a list of the values for which it
-returns nil.
-
-For transients that are used to pass arguments to a subprosess
-\(such as git), `stringp' is a useful value for SEPARATE, it
-separates non-positional arguments from positional arguments.
-The value of Magit's file argument for example looks like this:
-\(\"--\" file...)."
- (let ((val (if (transient-prefix--eieio-childp prefix)
- (delq nil (mapcar 'transient-infix-value
- transient--suffixes))
- (and (or (not prefix)
- (eq prefix current-transient-command))
- (delq nil (mapcar 'transient-infix-value
- current-transient-suffixes))))))
- (if separate
- (-separate (if (eq separate t) #'atom separate) val)
- val)))
+object."
+ (if (transient-prefix--eieio-childp prefix)
+ (delq nil (mapcar 'transient-infix-value
+ transient--suffixes))
+ (and (or (not prefix)
+ (eq prefix current-transient-command))
+ (delq nil (mapcar 'transient-infix-value
+ current-transient-suffixes)))))
;;;; Init
- [elpa] externals/transient c59c48530a 122/366: transient--{suspend, resume}-override: New functions, (continued)
- [elpa] externals/transient c59c48530a 122/366: transient--{suspend, resume}-override: New functions, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient ebcad9e6fe 127/366: Use seq instead of dash, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient d49f85a8c1 158/366: Support scroll-bar-toolkit-scroll, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient 7502390bbd 190/366: transient-column{, s}: Optionally pad keys, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient f0f3e2b9fe 195/366: transient-infix-value: Fix typo in a doc-string, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient 8423bc69e7 199/366: manual: Update outdated function signature, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient 101c0aeaa1 023/366: transient--insert-suffix: Fix move of last child of a group, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient 0d9a1b5536 107/366: manual: Document prefix slots, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient 7e2b98c701 109/366: Fix doc string typo, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient 3fe1b7ea86 086/366: transient--kbd: New function, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient 0312b9302d 099/366: transient-args: Remove SEPARATE argument,
Jonas Bernoulli <=
- [elpa] externals/transient 7d0db2826b 100/366: transient-args: No longer support an object as PREFIX, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient a6ce1950e4 102/366: transient-args: Fall back to set, saved or default value, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient 0cad5ebcb7 106/366: Fix doc string typos, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient 824c684deb 108/366: Advertise current-transient-suffixes less, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient ccac95e5a8 112/366: transient-show-help: Don't error if argument is missing, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient 4f80a8999c 113/366: transient--goto-argument-description: Handle -- special case, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient 41cbf49529 118/366: transient--insert-suffix: Fix removing LOC, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient 6ceb643f0b 132/366: Revert "Add .github/FUNDING.yml", Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient 93c9f2a251 133/366: manual: Fix typo, Jonas Bernoulli, 2022/01/25
- [elpa] externals/transient 83cb1e4caa 135/366: make: Copy indices for htmlified info manuals, Jonas Bernoulli, 2022/01/25