I have been using Mozilla Thunderbird for email for some time, and while this imports contacts from other email clients it does not handle the almost universal VCF format.
I had tried a couple of utilities to convert vcf to ldif, which Thunderbird can import.
These had differing problems, mainly due to the differing vcf features used and the lack of a one to one mapping.
I decided to write my own utility.
This is specifically designed to enable Palm vcf to be imported into Thunderbird, but it is sufficiently flexible to handle almost any vcf file.
Rather than writing a direct converter this macro is in 2 parts:-
The main loop reads a VCF file, storing fields in text registers
This should work for any VCF
It includes code customised to read Palm, which are ignored if absent
The Output Routine outputs found fields in LDIF format
This includes many Mozilla/Firefox custom attributes
Output is created in the same directory as the input file, with extension .ldif
Any existing file is overwritten.