It has been a while since the last release, in large part because there was one major issue, I was struggling with. A few months ago I finally came up with a satisfying solution, and since that has proven stable since then, it is now time for a new release.
Transient has to update state after every suffix command. If that fails for some reason, then Emacs ends up in an badly broken state. It was rare, but in the worst case scenario, that meant that Emacs refused to call any more commands and had to be killed.
post-command-hook is the first choice to run something
after commands, but unfortunately that hook is not guaranteed to run
only once, and worse it is not guaranteed to run after the command.
Working around this limitation made an essential part of Transient
much more complex and fragile. As new edge-cases were discovered,
new and increasingly desperate heuristics had to be added, until I
finally decided that relying solely on hooks was just not feasible.
pre-command-hook is used to advice
this-command, to add an
around advice, which ensures that the state update takes place, even
post-command-hook is run prematurely. The advice wraps both
the function body and the interactive spec with
we can finally be sure that the state change is always performed,
and that the advice is removed again.
It has been an interesting journey, and I have documented it in long commit messages. If you are interested in the details, see 7b8a7d71 (which still tries to avoid using any advice), 51c68c87, 52cac9c0, bug#61179 and bug#61176.
This release also contains many other important changes, including many bug fixes, but here I will just list some user-visible changes. For information on other changes, see the CHANGELOG.
Popup navigation is no longer considered a second-class feature and is enabled by default. Some transients allow arbitrary non-suffixes to be invoked, so some key bindings, which were previously used for popup navigation, had to be removed, to avoid conflicts.
Use the arrow keys to navigate between commands, and
RET to invoke the
C-s can be used so search in the transient buffer, which can
be useful, e.g., if you know the name of the argument you want to toggle, but
don’t remember the key binding and also don’t immediately spot it.
Added new option
Added new option
Added new command
transient-reset, which clears the set and saved
value of the active transient.
When using Emacs 28,
execute-extended-command can be told to ignore
transient infix commands. Even when using that Emacs version, that
command does not ignore any commands by default, but this behavior
can be easily be enabled using:
(setq read-extended-command-predicate 'command-completion-default-include-p)
Infix arguments are implemented as commands, so they by default show
up as completion candidates of
execute-extended-command, which is
useless because they are only intended to be invoked from transient
prefix commands. Enable this feature to prevent that.
Infix arguments can now be invoked following a prefix argument. To
use a negative prefix argument use
- cannot be used anymore
because it conflicts with the most common prefix key used for infix
Finally I should note, that I still haven’t gotten around to making the manual more useful as an introduction (or to writing a separate introduction). I found it impossible to motivate myself to work on that, largely due to the situation mentioned in the next section.
However, Psionic K has stepped up and created the Transient Showcase, a very useful resource.
The donations I receive for my work on Magit, Transient and many other Emacs packages and projects, are my only source of income. For most of the last ten years that has been the case. Unfortunately after all that time, I still earn less than half of the median income were I live, and it has started to take its toll.
For a variety of reasons, I find it difficult to ask for more donations, but just waiting for more users to decide to contribute, without actively being encouraged to do so, does not work nearly well enough. As the fundraiser in 2017 and a more recent appeal have shown, if I do make users aware of the situation and ask for help, then many are happy to donate.
But unless one checks Emacs news every day, such a one-time appeal is easy to be missed; so for the foreseeable future, I am going to add a note like this to all announcements and blog posts. I need to find myself 1,000 True Fans soon.
Thanks for your support!
Posted on 10th May 2023
Comments on Reddit and Github.