How to configure a mail client
I was thinking about this for a while, I think it's time to share my ideas here so maybe someone will make all this happen sometime.
Every once in a while you need to configure a mail client. May it be that you simply changed it (settings import might step up to rescue here), may it be a whole new installation or just the new guy in your company that will do your paperwork from now on. Always the same things and at the end you start forgetting something. Not because it's complicated but because you are simply bored.
Does anyone rememeber this "proxy auto configuration" thing back 10 years ago? Maybe it's still out there but I haven't seen it for a while. Why not do similar things with your mail client? Ok, that's the plan: we have an XML file, best with a fixed name like EmailAutoConfig[-.*].xml where you can optionally insert a subpart at the given place like EmailAutoConfig-foobar@example.org.xml. Now this file contains everything your mailer needs to know (optionally including even the password). You would just fire up a random email client, go to the "new account" menu action and point it to the file. Enter password, done.
Doing this for a single client (like Kontact) isn't that hard and is probably possible anyway using a different approach. But when this ends up somewhere like freedesktop.org and every major (free) client would do this we would really add value for all of us. Think about that guy in the office uses Evolution, you have Kontact and your wife refuses to use anything but Thunderbird. How cool can it be to just ignore all the different config dialogs and just throw them in that simple XML file? Think even further: when a big freemail provider can just point their clients to those XML files in their webmail interface how much less does the support desk have to deal with people forgetting to check some option when they want POP or IMAP?
Ok, how would that look like? First, we need four major parts:
- Identity
- Here goes the name of the account owner, organization settings, and signature. While this isn't that important for your personal use (you would probably only use the name) it gives a great help for company setups. Encryption and signing of messages is another good thing to add here so all your company dudes will get their X.509 certs installed (or their PGP keys).
- Incoming Transport
- Yes, how do I get my mail. An extremely cool feature would be if you could define multiple transport types here (like one for POP and one for IMAP) and the user may choose. If one email program does not support some of the types it would simply not offer those to the user. Think of a webmailer: you may even import your EmailAutoConfig.xml there if you want to use a POP collector service. Every email client may select the preference it has for one or the other type and may define it's own help texts which means what (e.g. "IMAP can't be used offline without caching", "POP doen't work with subfolders" etc.).
- Outgoing Transport
- Well, sure, I bet you need that, too. At the end very similar to the last section I guess.
- Credentials
- Every setup I've ever used had the same usernames and passwords for all types of accounts, so you would end up entering them at least twice (for IMAP and SMTP) for most mail clients. We simply put them in their own section and only reference them from whereever we need.
Ok, a picture says more than 1000 words. At this point a picture might not help that much, how about this example XML file?
Disclaimer: I'm no XML guru. And I probably forgot a bunch of things that need to be added. It's just was came to my mind or what are the things I always need to enter.
Btw., the option to tell KMail that POP/IMAP and SMTP share the same authentication would be cool as you only need to change one if you got a new password.