<?xml version="1.0" encoding="windows-1252"?>
<node id="482089" title="Re^2: finding unread emails in IMAP maildir" created="2005-08-08 21:21:20" updated="2005-08-10 17:56:00">
<type id="11">
note</type>
<author id="200274">
iguanodon</author>
<data>
<field name="doctext">
&lt;blockquote&gt;Unread messages should be in the &lt;tt&gt;new&lt;/tt&gt; subdirectory of &lt;tt&gt;Maildir&lt;/tt&gt;, and read messages in &lt;tt&gt;cur&lt;/tt&gt;.  Not sure about using those modules, but that's how Maildir works.  See  &lt;a href="http://cr.yp.to/proto/maildir.html"&gt;http://cr.yp.to/proto/maildir.html&lt;/a&gt;.
&lt;/blockquote&gt;
That's basically correct but... at least with my Postfix / Courier IMAP / Squirrelmail setup, as soon as I use Squirrelmail any messages in the &lt;tt&gt;new&lt;/tt&gt; dir are moved to &lt;tt&gt;cur&lt;/tt&gt; - even if they're not read yet.  When the message is read, &lt;tt&gt;:2,S&lt;/tt&gt; is appended to the file name in &lt;tt&gt;cur&lt;/tt&gt;.  This is best explained at &lt;a href="http://www.courier-mta.org/?maildir.html"&gt;http://www.courier-mta.org/?maildir.html&lt;/a&gt; .  Other MTA/IMAP server/MUA combinations may handle this differently.
&lt;p&gt;


&lt;p&gt;&lt;!-- Node text goes above. Div tags should contain sig only --&gt;
&lt;div class="pmsig"&gt;&lt;div class="pmsig-200274"&gt;
&lt;p&gt;
</field>
<field name="root_node">
481994</field>
<field name="parent_node">
482004</field>
</data>
</node>
