On 26.03.16 15:10, Jon LaBadie wrote:
> I can see what you both are referring to. There are big differences
> between 'c' and 'y' for my work style. First, 'y' shows the files
> defined by the "mailboxes" parameter, the ones I'm looking for. In
> contrast, 'c' shows the files defined by the "folder" parameter which
> in my case is not the receiving mailboxes, but the previously saved
> mail in ~/Mail (about 800 files).
That's not what happens here, I hit 'c' and mutt immediately offers the
mailbox with new mail which appears highest in the (one or more)
"mailboxes" lines in my .muttrc. I.e. it not only serves as a serialised
version of the 'y' list, restricted to those with new mail (your
specified use-case), but also prioritises the list in the order given in
the "mailboxes" parameter. (Bonus points for that!)
E.g.: Send myself a test mail. Now hitting '.' for a quick check shows:
"New mail in /var/spool/mail/erik"
And hitting 'c' prompts:
Open mailbox ('?' for list): /var/spool/mail/erik
If another delivery mailbox appears earlier in "mailboxes", and has
mail, it'll take precedence. If no mailbox is proffered, then there is
no new mail. (As '.' would then confirm.)
Are you hitting '?' to go to the 800 file list?
> Another difference, 'y' immediately goes to the index where 'c' goes
> to a prompt on the status line with a suggested path. That is where
> the '-' and up/down arrows can be used or a '?' entered to get to the
> index.
Used with a "mailboxes" parameter, 'c' automates the use-case you're
trying to achieve manually. (And very usefully adds priority)
> All useful learning thank you. But I'll ask my original query again.
>
> Is there a way to have the index shown by the 'y' command limited to
> those files that are NOT empty?
Not empty, or not containing new mail? I leave some read mail in
incoming mailboxes, such as earlier posts in this thread, until the
thread traffic peters out. That makes it easier to tag several posts, as
I have done here, to quote in my reply, using ";r" or ";L". There's no
need to have such a non-empty mailbox served up if there's no new traffic.
Once the thread is dead, useful posts can be archived, the rest deleted.
If the use-case _must_ be "NOT empty", then just use the mailbox file
format, rather than maildir. IIRC, a mailbox file from which all mails
have been deleted, is also deleted. A non-exsistent file can hardly be
listed by 'y'.
On 25.03.16 13:37, Will Yardley wrote:
>
> If you define mailboxes that you expect *incoming* mail in via
> 'mailboxes' (e.g., mailboxes +foo, or mailboxes +foo*), 'change-folder'
> (bound to c by default, I believe), will cycle through mailboxes with
> new mail in the order they're defined.
That's the mutt way of handling Jon's use-case. No lists to muck with;
it's just automated.
Erik