From cde0756fb1e30fa1629a2b69f1dfe0f12510adcf Mon Sep 17 00:00:00 2001 From: Jonas Bernoulli Date: Thu, 5 Mar 2026 22:44:46 +0100 Subject: transient-infix-read: Use current value as initial input Usually the infix is unset if invoked while it has value. It then has to be invoked a second time to set another value. During that second value the previous value is used as initial-input because it was previously added to the history and we already explicitly use that here. However when `always-read' is non-nil, the infix isn't toggled off like this and we have to pass along the current value as initial- input on the first and only invocation. --- lisp/transient.el | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lisp/transient.el b/lisp/transient.el index 33de668..379c888 100644 --- a/lisp/transient.el +++ b/lisp/transient.el @@ -3982,8 +3982,9 @@ it\", in which case it is pointless to preserve history.)" (eq value (car transient--history))) transient--history (cons value transient--history))) - (initial-input (and transient-read-with-initial-input - (car transient--history))) + (initial-input (or value + (and transient-read-with-initial-input + (car transient--history)))) (history (if initial-input (cons 'transient--history 1) 'transient--history)) -- cgit v1.0