On Wednesday 26.08.15   08:03, Joe wrote:
> On Tuesday 25.08.15   09:43, Ian Zimmerman wrote:
> > On 2015-08-25 17:35 +0200, Joe wrote:
> > 
> > > %N should mean: "show N flag for mailboxes containing "New" mail messages"
> > 
> > > all mailboxes are in mbox format (at now) not in maildir format.
> > > I have many mailboxes, filled using fetchmail/procmail.
> > 
> > With mbox, AFAIK mutt detects newness simply by comparing mtime with
> > atime of the file.  If they're the same, it is new.
> > 
> > Are you possibly mounting the filesystem with the noatime option?
> 
> In /etc/mtab I have the following set up for filesystem of root
> partition:
> ---
> /dev/sda5 / ext4 rw,commit=0 0 0
> ---
> 
> So, no "noatime" option...



I tried to send a message myself (sender and recipient are the same address).
My procmail config deliver this type of messages in a mailbox called
"test-mail" (~/Mail/test-mail), and it is mbox format.

Now if I use stat command before opening that mailbox with mutt or any other
client I can see (my shell returns that output in Italian instead of English):
---
  File: "Mail/mail.tests"
  Dim.: 41075           Blocchi: 88         Blocco di IO: 4096   file regolare
Device: 805h/2053d      Inode: 2434807     Coll.: 1
Accesso: (0600/-rw-------)  Uid: ( 1000/     joe)   Gid: (   16/ dialout)
Accesso  : 2015-08-26 17:16:35.000000000 +0200
Modifica : 2015-08-26 23:48:13.819996412 +0200
Cambio   : 2015-08-26 23:48:13.819996412 +0200
Creazione: -
---


So we have:

mtime (Aug 26 17:16) > atime (Aug 26 23:48)

As explained by "Ian Zimmerman" and by man pages of mbox(5):
---
If the modification-time (usually determined via stat(2)) of a nonempty mbox
file is greater than the access-time the file has new mail.
---


This should mean our "mail.test" mailbox contains new messages and I would
expect Mutt shows "N" flag when I'm in "browser menu".

In my "~/.muttrc" I've set:
---
set folder_format = "%4C %t %-40f %30.30d %-10.10N"
set sort_browser = reverse-date
---


So I expected an "N" flag at the end of "mail.test" line in browser menu.
But I can just view the following line when I open Mutt browser menu:
---
   1   mail.tests                                                 Aug 26 23:48
---


So... There isn't any "N" flag following last modification date/time
info (Aug 26 23:48)!  :(

If I don't open that mailbox, quit Mutt and recall stat command I still see
the same report as above... as expected:
---
$ stat Mail/mail.tests
  File: "Mail/mail.tests"
  Dim.: 41075           Blocchi: 88         Blocco di IO: 4096   file regolare
Device: 805h/2053d      Inode: 2434807     Coll.: 1
Accesso: (0600/-rw-------)  Uid: ( 1000/     joe)   Gid: (   16/ dialout)
Accesso  : 2015-08-26 17:16:35.000000000 +0200
Modifica : 2015-08-26 23:48:13.819996412 +0200
Cambio   : 2015-08-26 23:48:13.819996412 +0200
Creazione: -
---


Even though I've searched the net, I haven't found a solution yet.
I suspected the problem was in "folder_format" variable, but also with
default value ("%2C %t %N %F %2l %-8.8u %-8.8g %8s %d %f") "N" flag
doesn't appear anyway...

Hope these info could be useful. If you have any hints would be greatly
appreciated!  :)

Thanks again, see you!

Reply via email to