update packages
This commit is contained in:
@@ -1,13 +1,13 @@
|
||||
;; -*- no-byte-compile: t; lexical-binding: nil -*-
|
||||
(define-package "transient" "20251120.1950"
|
||||
(define-package "transient" "20251215.2209"
|
||||
"Transient commands."
|
||||
'((emacs "28.1")
|
||||
(compat "30.1")
|
||||
(cond-let "0.2")
|
||||
(seq "2.24"))
|
||||
:url "https://github.com/magit/transient"
|
||||
:commit "453376f2f1a0beab45da06c84a9e57692afc0607"
|
||||
:revdesc "453376f2f1a0"
|
||||
:commit "066b985b19afbcc8f2f344cebb8d2f4c626b1bdc"
|
||||
:revdesc "066b985b19af"
|
||||
:keywords '("extensions")
|
||||
:authors '(("Jonas Bernoulli" . "emacs.transient@jonas.bernoulli.dev"))
|
||||
:maintainers '(("Jonas Bernoulli" . "emacs.transient@jonas.bernoulli.dev")))
|
||||
|
||||
@@ -6,8 +6,8 @@
|
||||
;; Homepage: https://github.com/magit/transient
|
||||
;; Keywords: extensions
|
||||
|
||||
;; Package-Version: 20251120.1950
|
||||
;; Package-Revision: 453376f2f1a0
|
||||
;; Package-Version: 20251215.2209
|
||||
;; Package-Revision: 066b985b19af
|
||||
;; Package-Requires: (
|
||||
;; (emacs "28.1")
|
||||
;; (compat "30.1")
|
||||
@@ -725,15 +725,16 @@ See also option `transient-highlight-mismatched-keys'."
|
||||
(insert-file-contents file)
|
||||
(read (current-buffer))))))
|
||||
|
||||
(defun transient--pp-to-file (list file)
|
||||
(make-directory (file-name-directory file) t)
|
||||
(setq list (cl-sort (copy-sequence list) #'string< :key #'car))
|
||||
(with-temp-file file
|
||||
(let ((print-level nil)
|
||||
(print-length nil)
|
||||
(pp-default-function 'pp-28)
|
||||
(fill-column 999))
|
||||
(pp list (current-buffer)))))
|
||||
(defun transient--pp-to-file (value file)
|
||||
(when (or value (file-exists-p file))
|
||||
(make-directory (file-name-directory file) t)
|
||||
(setq value (cl-sort (copy-sequence value) #'string< :key #'car))
|
||||
(with-temp-file file
|
||||
(let ((print-level nil)
|
||||
(print-length nil)
|
||||
(pp-default-function 'pp-28)
|
||||
(fill-column 999))
|
||||
(pp value (current-buffer))))))
|
||||
|
||||
(defvar transient-values
|
||||
(transient--read-file-contents transient-values-file)
|
||||
@@ -1699,20 +1700,20 @@ See info node `(transient)Modifying Existing Transients'."
|
||||
(setq group (transient--get-layout group)))
|
||||
(when (vectorp loc)
|
||||
(setq loc (append loc nil)))
|
||||
(if (listp loc)
|
||||
(and-let* ((match (transient--nth (pop loc) (aref group 2))))
|
||||
(if loc
|
||||
(transient--locate-child
|
||||
match (cond ((or (stringp (car loc))
|
||||
(symbolp (car loc)))
|
||||
(car loc))
|
||||
((symbolp match)
|
||||
(vconcat (cons 0 loc)))
|
||||
((vconcat loc))))
|
||||
(list match group)))
|
||||
(seq-some (lambda (child)
|
||||
(transient--match-child group loc child))
|
||||
(aref group 2))))
|
||||
(cond-let
|
||||
((atom loc)
|
||||
(seq-some (lambda (child)
|
||||
(transient--match-child group loc child))
|
||||
(aref group 2)))
|
||||
([match (transient--nth (pop loc) (aref group 2))]
|
||||
(cond (loc (transient--locate-child
|
||||
match (cond ((or (stringp (car loc))
|
||||
(symbolp (car loc)))
|
||||
(car loc))
|
||||
((symbolp match)
|
||||
(vconcat (cons 0 loc)))
|
||||
((vconcat loc)))))
|
||||
((list match group))))))
|
||||
|
||||
(defun transient--match-child (group loc child)
|
||||
(cl-etypecase child
|
||||
@@ -3425,21 +3426,22 @@ transient is active."
|
||||
|
||||
;;;; Help
|
||||
|
||||
(defun transient-help (&optional interactive)
|
||||
(defun transient-help (&optional interactivep)
|
||||
"Show help for the active transient or one of its suffixes.
|
||||
\n(fn)"
|
||||
(interactive (list t))
|
||||
(if interactive
|
||||
(setq transient--helpp t)
|
||||
(cond
|
||||
(interactivep
|
||||
(setq transient--helpp t))
|
||||
((lookup-key transient--transient-map
|
||||
(this-single-command-raw-keys))
|
||||
(setq transient--helpp nil)
|
||||
(with-demoted-errors "transient-help: %S"
|
||||
(when (lookup-key transient--transient-map
|
||||
(this-single-command-raw-keys))
|
||||
(setq transient--helpp nil)
|
||||
(transient--display-help #'transient-show-help
|
||||
(if (eq this-original-command 'transient-help)
|
||||
transient--prefix
|
||||
(or (transient-suffix-object)
|
||||
this-original-command)))))))
|
||||
(transient--display-help #'transient-show-help
|
||||
(if (eq this-original-command 'transient-help)
|
||||
transient--prefix
|
||||
(or (transient-suffix-object)
|
||||
this-original-command)))))))
|
||||
|
||||
(transient-define-suffix transient-describe ()
|
||||
"From a transient menu, describe something in another buffer.
|
||||
@@ -4205,17 +4207,18 @@ a string, using the empty string for the empty value, or nil if
|
||||
the option does not appear in ARGS.
|
||||
|
||||
Append \"=\ to ARG to indicate that it is an option."
|
||||
(if (string-suffix-p "=" arg)
|
||||
(save-match-data
|
||||
(and-let* ((match (let ((case-fold-search nil)
|
||||
(re (format "\\`%s\\(?:=\\(.+\\)\\)?\\'"
|
||||
(substring arg 0 -1))))
|
||||
(cl-find-if (lambda (a)
|
||||
(and (stringp a)
|
||||
(string-match re a)))
|
||||
args))))
|
||||
(or (match-string 1 match) "")))
|
||||
(and (member arg args) t)))
|
||||
(save-match-data
|
||||
(cond-let
|
||||
((member arg args) t)
|
||||
([_(string-suffix-p "=" arg)]
|
||||
[match (let ((case-fold-search nil)
|
||||
(re (format "\\`%s\\(?:=\\(.+\\)\\)?\\'"
|
||||
(substring arg 0 -1))))
|
||||
(cl-find-if (lambda (a)
|
||||
(and (stringp a)
|
||||
(string-match re a)))
|
||||
args))]
|
||||
(match-string 1 match)))))
|
||||
|
||||
;;; Return
|
||||
|
||||
@@ -4285,21 +4288,23 @@ be non-nil. If either is non-nil, try the following in order:
|
||||
class definition or using its `transient-init-scope' method.
|
||||
|
||||
If no prefix matches, return nil."
|
||||
(if (or prefixes classes)
|
||||
(let ((prefixes (ensure-list prefixes))
|
||||
(type (if (symbolp classes) classes (cons 'or classes))))
|
||||
(if-let ((obj (cl-flet ((match (obj)
|
||||
(and obj
|
||||
(or (memq (oref obj command) prefixes)
|
||||
(cl-typep obj type))
|
||||
obj)))
|
||||
(or (match transient-current-prefix)
|
||||
(match transient--prefix)))))
|
||||
(oref obj scope)
|
||||
(and (get (car prefixes) 'transient--prefix)
|
||||
(oref (transient--init-prefix (car prefixes)) scope))))
|
||||
(and-let* ((obj (transient-prefix-object)))
|
||||
(oref obj scope))))
|
||||
(cond-let
|
||||
((or prefixes classes)
|
||||
(let* ((prefixes (ensure-list prefixes))
|
||||
(type (if (symbolp classes) classes (cons 'or classes)))
|
||||
(match (lambda (obj)
|
||||
(and obj
|
||||
(or (memq (oref obj command) prefixes)
|
||||
(cl-typep obj type))
|
||||
obj))))
|
||||
(cond-let
|
||||
([obj (or (funcall match transient-current-prefix)
|
||||
(funcall match transient--prefix))]
|
||||
(oref obj scope))
|
||||
((get (car prefixes) 'transient--prefix)
|
||||
(oref (transient--init-prefix (car prefixes)) scope)))))
|
||||
([obj (transient-prefix-object)]
|
||||
(oref obj scope))))
|
||||
|
||||
;;; History
|
||||
|
||||
@@ -4739,7 +4744,7 @@ and its value is returned to the caller."
|
||||
|
||||
(cl-defmethod transient-format-description ((obj transient-value-preset))
|
||||
(pcase-let* (((eieio description key set) obj)
|
||||
((eieio value) transient--prefix)
|
||||
(value (transient--get-extended-value))
|
||||
(active (seq-set-equal-p set value)))
|
||||
(format
|
||||
"%s %s"
|
||||
@@ -4860,23 +4865,22 @@ apply the face `transient-unreachable' to the complete string."
|
||||
(propertize "|" 'face 'transient-delimiter))))))
|
||||
|
||||
(cl-defmethod transient--get-description ((obj transient-child))
|
||||
(and-let* ((desc (oref obj description)))
|
||||
(if (functionp desc)
|
||||
(if (= (car (transient--func-arity desc)) 1)
|
||||
(funcall desc obj)
|
||||
(funcall desc))
|
||||
desc)))
|
||||
(cond-let* [[desc (oref obj description)]]
|
||||
((functionp desc)
|
||||
(condition-case nil
|
||||
(funcall desc obj)
|
||||
(wrong-number-of-arguments (funcall desc))))
|
||||
(desc)))
|
||||
|
||||
(cl-defmethod transient--get-face ((obj transient-suffix) slot)
|
||||
(and-let* ((_(slot-boundp obj slot))
|
||||
(face (slot-value obj slot)))
|
||||
(if (and (not (facep face))
|
||||
(functionp face))
|
||||
(let ((transient--pending-suffix obj))
|
||||
(if (= (car (transient--func-arity face)) 1)
|
||||
(funcall face obj)
|
||||
(funcall face)))
|
||||
face)))
|
||||
(cond-let* ((not (slot-boundp obj slot)) nil)
|
||||
[[face (slot-value obj slot)]]
|
||||
((facep face) face)
|
||||
((functionp face)
|
||||
(let ((transient--pending-suffix obj))
|
||||
(condition-case nil
|
||||
(funcall face obj)
|
||||
(wrong-number-of-arguments (funcall face)))))))
|
||||
|
||||
(defun transient--add-face (string face &optional append beg end)
|
||||
(let ((str (copy-sequence string)))
|
||||
@@ -5383,9 +5387,6 @@ we stop there."
|
||||
(face-remap-reset-base 'default)
|
||||
(face-remap-add-relative 'default 'fixed-pitch))
|
||||
|
||||
(defun transient--func-arity (fn)
|
||||
(func-arity (advice--cd*r (if (symbolp fn) (symbol-function fn) fn))))
|
||||
|
||||
(defun transient--seq-reductions-from (function sequence initial-value)
|
||||
(let ((acc (list initial-value)))
|
||||
(seq-doseq (elt sequence)
|
||||
|
||||
@@ -964,9 +964,9 @@ after the infix argument that is bound to ‘-3’ in ‘magit-patch-apply’.
|
||||
|
||||
These functions operate on the information stored in the
|
||||
‘transient--layout’ property of the PREFIX symbol. Elements in that
|
||||
tree are not objects but have the form ‘(CLASS PLIST) for suffixes’ and
|
||||
tree are not objects but have the form ‘(CLASS PLIST)’ for suffixes and
|
||||
‘[CLASS PLIST CHILDREN]’ for groups. At the root of the tree is an
|
||||
element ‘[N Nil CHILDREN]’, where ‘N’ is the version of the layout
|
||||
element ‘[N nil CHILDREN]’, where ‘N’ is the version of the layout
|
||||
format, currently and hopefully for a long time 2. While that element
|
||||
looks like a group vector, that element does not count when identifying
|
||||
a group using a coordinate vector, i.e., ‘[0]’ is its first child, not
|
||||
|
||||
Reference in New Issue
Block a user