Gmail IMAP and Folders Under Inbox
Fri Nov 2nd 2007, 4:36pm
Hooray, Googlemail is finally offering IMAP support! I started moving my mail over, but immediately noticed that my mail client was displaying all folders (which are just Gmail labels) underneath a new, top-level category, instead of directly underneath the Inbox (like I'm used to with every other IMAP server). Uggh, this is horrible.

gmail new top level

After some experimenting, I found this is remedied easily enough: create folders/labels with the prefix "INBOX/". For example, INBOX/foobar. Then your mail client will show the folder underneath your Inbox. Much better.

gmail folders under inbox

Even though this gets Mac OS X's Mail.app to put the little triangle next to your inbox, you still can't seem to drag folders directly under your Inbox. You could create all your folders manually, or I found you can drag folders under any new folders you create. So I just created a folder called INBOX/folders, and then dragged all my folders under that.

Finally, I started using Mail.app to copy everything en masse, but it kept crashing on something. Fortunately, Thunderbird came to the rescue. While not completely without problems of its own, it didn't crash nearly as much and with it I was able to copy all my mail over.

Update: I found this Ruby script which is doing a much better job than either Mail.app or Thunderbird. Nice, clean Ruby code and it'll only copy stuff up to Google that's missing (i.e. you can run it over and over again).

Google also has posted How do actions sync in IMAP? which answers some questions on how they map IMAP actions into their own mail system.

Thanks to this post at maxoshints.com for some ideas.



Visitor comments
On Sat Nov 10th 2007, 12:38pm, Rob Meyer posted:
This link has a lot of detail as well:

http://5thirtyone.com/archives/862

In the end I chose not to map most of my local folders of "trash" etc. to the Gmail ones. I like using "delete" in the inbox to archive, and mapping the sent mail folder was causing duplicates for me.

I tried Google's recommendation of using drafts, but mail.app seems to save the mail several times while your composing, so I was getting a lot of dupes and decided to just not have a shared drafts folder too.