Search:  
Gentoo Wiki

TIP_Moving_data_from_outlook_to_evolution

This article is part of the Tips & Tricks series.
Terminals / Shells Network X Window System Portage System Filesystems Kernel Other

Many people like me, before converting to Gentoo, used Outlook to manage their contacts, appointments and mail, so it would only be natural to continue working with a similar interface -- Evolution. To avoid retyping all the contacts again here's how I converted them to Evolution.

First download and install (unzip) Outport on your Windows machine. Note that while Outlook stores data in .pst files, Outport does not actually read these files. Instead, it uses the MAPI interface to retrieve the data from Outlook, which means that you will need Outlook installed.

In Outport, select the folders you want to export and choose Outport VCard as the outputfilter. Don't be tempted by other formats - this was the only one which worked for me. This will create a folder structure, where each contact will be stored in a separate VCard.

Now, make the files available to Linux (e.g. by mounting the windows partition).

NOTE: If you have non-english characters in your contacts such as german umlauts etc., you'll be pleased to know that Outport will export them properly, but since Linux uses a different type of character encoding, these characters will (in Linux) change to, well, whatever. To prevent this emerge app-text/recode which will help you convert the one codepage into the other.

Use your favorite text editor to create the following shell script:

File: recode_and_cat_contacts
#!/bin/bash for datei in ./* ; do if [ -f "$datei" ] then cat "$datei" | recode CP1258/ fi done

As you can see this script loops through all the files in the current directory and pipes the contents to recode which converts all the characters from Windows to Linux encoding and finally outputs them to stdout. The reason why all the VCards go into one file is that the Evolution import function only allows you to select for import one file at a time.

Make the script executable with chmod +x recode_and_cat_contacts and run it in the directory that you've placed your VCards in like this:

/path/to/recode_and_cat_contacts >> /path/to/output_file

Finally, in Evolution, import the output_file using VCard as file type.

Retrieved from "http://www.gentoo-wiki.info/TIP_Moving_data_from_outlook_to_evolution"

Last modified: Fri, 05 Sep 2008 10:00:00 +0000 Hits: 5,343