Hi Kevin,

On Mon, Jan 03, 2022 at 10:34:18AM -0800, Kevin J. McCarthy wrote:
> On Mon, Jan 03, 2022 at 12:40:17PM +0100, Michael Klemm wrote:
> > I have a small issue with sidebar_format that I cannot really sort out.
> > If I set this sidebar_format
> > 
> >     set sidebar_format = '%B%* %n'
> >     
> > Mutt highlights the folder with unread messages, but does not show the
> > number, but no count at all:
> 
> To make sure I'm understanding you, %n will display 'N' when the mailbox has
> new mail, not a count.
> 
> However, note that $mail_check_recent can affect this for mailboxes you have
> already visited.  Also note that 'unread' isn't the same as 'new'. For
> example, 'old' messages are unread but not new.
> 
> > I cannot make it work to only show the number for the mailboxes count
> > > 0.  I have also tried
> > 
> >     set sidebar_format = '%B%* %?N%N'
> 
> Try:   set sidebar_format = "%B%* %?N?%N?"

That solved the issue!  I guess I was misunderstanding the way the "%?"
part worked.  Thanks for helping me out on this one!

> http://www.mutt.org/doc/manual/#formatstrings-conditionals gives a review of
> the syntax.

Thanks for the pointer!


Kind regards,
        -michael



Attachment: signature.asc
Description: PGP signature

Reply via email to