Re: [Tracker] Thunderbird support - patches



On Fri, 2007-09-07 at 11:01 +0100, Michal Pryc wrote:
Hello Tracker community,

I am sending few patches to add support for Thunderbird Emails through 
extension, which was originally written by Pierre Ãstlund[0].

I have made each patch for each file, because it is easier for me to 
describe what actually the patches are doing.

After applying those patches, you can see README, which describes 
process of building and installing Tracker with Thunderbird support.

I have tried this on my e-mail account which contains *lots* of e-mails, 
and it worked fine :-)

Comments welcome :-)

a very quick review:


So, a little explanation of each patch:
1. tracker-email-evolution.diff
    There was a little bug, which basically make iteration, but the 
values were not taken from the interation itself. Also I have changed 
the function a little bit, and now if the name from the e-mail is not 
found it is e-mail itself (which caused seg fault on Solaris).

fine



2. thunderbird-extension.diff
    Patch that need to be applied for the thunderbird-extension taken 
from beagle svn. This patch should be placed in the tracker source code 
as described in the patched README file. The extension in the 
Thunderbird will tell that it is Beagle one. In the future it will 
change, I need to discuss this.


yeah beagle refs need to be removed - they can stay for testing but must
change when we release with it enabled by default


3. tracker-01-thunderbird-support.diff
    Adds to trackerd.c routines for ThunderbirdEmails service, enables 
index_thunderbird_emails.


fine


4. tracker-02-thunderbird-support.diff
    Adds description to docs/tracker.cfg.5 for the IndexEvolutionEmails

5. tracker-03-thunderbird-support.diff
    Adds to data/services/default.service [ThunderbirdEmails] servuce 
description


fine although we need to refresh this file in trackerd for existing
users so it picks up changes

6. tracker-04-thunderbird-support.diff
    Changes the glade file to allow "Enable Thunderbird email indexing" 
in tracker-preferences. The glade file was generated using glade-3.

7. tracker-05-thunderbird-support.diff
    Adds keys for configuration to tracker-preferences.c for Thunderbird 
(/Emails/IndexThunderbirdEmails)

will have to delay changes to TP until TB backend is stable and fully
operational (deletes/junk). 

As with Kmail support, support can be added manually to cfg file but
should be off by default until its stable



8. tracker-06-thunderbird-support.diff
    Adds the "IndexThunderbirdEmails=true\n" to the configuration file.

9. tracker-07-thunderbird-support.diff
    Changes the function thunderbird_watch_emails to have argument 
"(DBConnection *db_con)". I made this change, since all other e-mail 
headers have this argument, so why to have different one?

10. tracker-08-thunderbird-support.diff
    * Adds the "IndexThunderbirdEmails=true\n" to the configuration file.
    * Adds the tracker_parse_log_message_and_add_missing_formatting 
function. This function replaces "%" with the "%%". This was written, 
because some of the log messages contained characters with the "%" for 
example "mail-message://test test%20Sample" in that case printf and 
other functions that used formatting on Solaris caused seg fault, 
because of wrong string. The correct string should look like 
"mail-message://test test%%20Sample".

11. tracker-09-thunderbird-support.diff
    Changes argument passed to the thunderbird_watch_emails function 
(change followed by patch: tracker-07-thunderbird-support.diff).

12. tracker-10-thunderbird-support.diff
    Adds tracker_parse_log_message_and_add_missing_formatting to the 
header file (change followed by patch: tracker-08-thunderbird-support.diff).

13. tracker-11-thunderbird-support.diff
    Parses output of the log message (change followed by patch: 
tracker-08-thunderbird-support.diff).

14. tracker-12-thunderbird-support.diff
    Adds MAIL_APP_THUNDERBIRD_FEED as an application to the 
MailApplication enumeration. This might be in other place, but since 
feeds and mails generated by extension doesn't differ almost at all, 
this was the simplest way to go.

ok not sure about it but its harmless atm



15. tracker-13-thunderbird-support.diff
    Change followed by previous patch. This will add 
MAIL_APP_THUNDERBIRD_FEED to the tracker-db-email.c and simple return 
correct mime. Also fixes the email subject, when the subject is null.

16. tracker-14-thunderbird-support.diff
    In the tracker-search-tool-callbacks.c adds opening e-mail by 
Thunderbird functionality.

17. tracker-15-thunderbird-support.diff
    Lot's of changes in tracker-email-thunderbird.c to support generated 
messages. The old functions were not deleted, just new ones added above 
those.

perhaps not needed stuff can be deleted? will make maintenance easier


18. tracker-16-thunderbird-support.diff
    Adds my name to the AUTHORS file ;-) :-)

19. tracker-17-thunderbird-support.diff
    Changes Makefile.am to build thunderbird-extension if this extension 
was found and the configure was run --with-thunderbird-extension option

20. tracker-18-thunderbird-support.diff
    Changes configure.ac to get --with-thunderbird-extension as an 
argument. Also checks if the thunderbird-extension was patched with the 
thunderbird-extension.diff

21. tracker-19-thunderbird-support.diff
    Changes in the README.


I will do a full review over weekend - thx




TODO;
- Dealing with deletion of folders and messages
- Feeds. To enable feeds, only few lines of code needs to be 
uncommented, but I need to discuss this, since the feed is going to be 
another service, so I don't want to index them as an Email service, that 
is why I have commented this out.


[0] http://postlund.org/
_______________________________________________
tracker-list mailing list
tracker-list gnome org
http://mail.gnome.org/mailman/listinfo/tracker-list





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]