As a quick followup to this, I didn't receive any replies to the message below, so I'm assuming it's currently impossible to "mix" virtual folders in with "real" top level folders at the top level of the IMAP hierarchy.

If I'm wrong, a pointer to how to do so would be much appreciated!


On 12/17/19 11:20 AM, Robert L Mathews wrote:
I'm experimenting with the Virtual plugin to give users access to
folders like "All Mail", "Recent" and so on, similar to Gmail.

Something like this works properly:

   mail_location = maildir:~/
   namespace {
     inbox = yes
     location =
     prefix = INBOX.
     separator = .
     type = private
   }
   namespace {
     prefix = INBOX.virtual.
     separator = .
     location = virtual:virtual
     list = children
     ignore_on_failure = yes
   }

I can then create "virtual/All Mail/dovecot-virtual" and
"virtual/Recent/dovecot-virtual" in the maildir directory, and it works.

However, when accessed using IMAP, an IMAP folder named "virtual" shows
in the folder hierarchy, with "All Mail" and "Recent" descended from
"virtual". It looks like:

INBOX
   Drafts
   Sent
   Trash
   virtual
     All Mail
     Recent

I'd prefer the virtual folders to be a level up the hierarchy without
the "virtual" parent visible, like:

INBOX
   All Mail
   Drafts
   Recent
   Sent
   Trash

Is that possible?

I've tried changing the "prefix = INBOX.virtual." on the virtual
namespace to just "prefix = INBOX.", but that causes a "Duplicate
namespace prefix" error.

I also tried using "alias_for" to merge the namespaces, but that causes
"namespace configuration error: Namespace virtual. can't have
alias_for=INBOX. to a different storage type (virtual vs maildir)".



--
Robert L Mathews, Tiger Technologies, http://www.tigertech.net/

Reply via email to