Thunderbird Import Extension (en)

Aus FelixSchwarz

Wechseln zu: Navigation, Suche

This site is only kept for historical reasons. Please use Michal Kocarek's Bird Import extension!


Inhaltsverzeichnis

Goal

I like to have an extension for Thunderbird which is able to import mails from The Bat! 1.x into Thunderbird. Preferably all existing information such as account information, passwords and address books will be migrated, too.

Obstacles

To my best knowledge there is no such plugin and that's for a reason: Writing such a plugin is a hard and complex task!

  1. The file format used by The Bat! is proprietary and not publicly documented anywhere (besides my own TheBat Importer (en) reverse engineering). I think, I solved this problem mostly so we can go ahead :-)
  2. Thunderbird (Mozilla) is one of the biggest open source software applications currently available[1]. Extending a complex software is not something the average PHP programmer can easily do. Of course, the Mozilla code base can be easily extended by external extensions using only Javascript and CSS but for an import extension, it is very advisable to use XPCOM together with C++[2].
  3. There is no documentation how to write an import extension beside the source code. Getting a grasp where to start is really demanding.

Status

20. July 2011: Michal Kocarek built an import extension using my documentation on the file formats! Even if this is kind of alpha software, there is no need for me to write my own importer anymore. This site is only kept for archival purposes. Please use Michal's importer

12. August 2007: I produced a small basic "extension" containing a few hundred lines of code. There is now a new item in the Thunderbird 'Import' dialog when importing mails called "The Bat! 1.x"[3]. The mail import factory is returned and could begin its work. Next steps include adding some 'fake progress' and writing a C library (preliminary named 'libbatmail') which can be included in the extension at a later point to do some real work.

How to help

Help is welcome! This is an open source project ("will become one") so without some helping hands, this won't get anywhere soon.

  1. Programmers: If you know object orientated programming in a C-like language (C++, Java) and have a solid understanding of either C++ or C, algorithms and macros, you can help getting the whole thing to work. Unfortunately, this isn't something for newbies. While you may learn C++/C while doing this, you should really know how to develop complex applications.
  2. Others: Sorry, I don't think you can do anything right now (maybe besides doing some reverse engineering to get information about the missing pieces in the proprietary file formats and learning how to code).


How to learn

If you like to help with this project (or develop another Mozilla/Firefox/Thunderbird extension using XPCOM/C++) I have some advise what helped me learning about XPCOM. At the beginning I knew next to nothing about COM programming (let alone XPCOM).

Documentation on Import Modules

tbd

References / Foot Notes

  1. Thunderbird 2.0.0.6 contains 2,754,533 physical source lines of code (generated using David A. Wheeler's 'SLOCCount').
  2. There are two reasons for using C++: First, while file system access is possible with Javascript, this is an area which is not known to many people so getting help may be quite difficult when fixing some obscure bugs. I expect this to be much easier when using well-known C++. And second, all existing import modules are written in C++ so using the same language enables you to transfer some infrastructure code easily into the new extension.
  3. I had really big difficulties getting to this point: It took me several weeks spread over about 2 1/2 years! Maybe I am just a bad programmer but I think this area is really complicated!
  4. The version found in Mozilla Developer center is slightly improved because it incorporates all errata found so far whereas the PDF is the original without errata.
Persönliche Werkzeuge