"Kevin J. McCarthy" <[email protected]> writes: >On Mon, Aug 24, 2026 at 09:30:35PM -0000, Jeffery Small wrote: > >>Xubuntu 24.04.4 Mutt: 2.3.1 >> >>In the index, the "$" key is associated with "sync-mailbox". >> >>I have a shell script called "mm" that forces the mailbox icon to sync >>immediately with the master mailbox contents -- i.e., indicate whether >>there is or isn't new mail. I can create a macro that calls this script >>but what I want to do is have "$" sync the mailbox and also call the >>external script in one step. I have not been able to create either an >>index binding or an index macro that combines these two steps. Am I >>missing something obvious or is it not possible to perform this combo >>action with a single key press?
>There are a few checks mutt makes that will flush the macro buffer on=20 >error. For example, in the sync case, if you try to sync a mailbox >with=20 no messages in it or if the mailbox is read only. It's possible >that is=20 interfering with the whole macro running. >But in the normal case, something like this should work: macro index $ >"<sync-mailbox><shell-escape>~/bin/mm<enter>" >You could try appending a mutt echo command to give yourself visual=20 >confirmation it ran to the end: > macro index $ \ > "<sync-mailbox><shell-escape>~/bin/mm<enter><enter-command>echo 'mm ran'= ><enter>" Kevin: Thanks for the reply. The trick I was missing was to place the built-in command within brackets: i.e. <sync-mailbox> Your example worked and I was able to shorten the macro to: macro index $ "<sync-mailbox>|mm\n" and it works perfectly. I really appreciate your help. Regards, -- Jeff Small
