mikehardy / thunderlink

Link to your Thunderbird emails!
Mozilla Public License 2.0
42 stars 14 forks source link

Compatibility with Thunderbird 68 #48

Open ericdanan opened 5 years ago

ericdanan commented 5 years ago

Hello,

Thanks for maintaining this add-on. At the moment Thunderlink support Thunderbird up to version 65 and is hence disable in the latest official version 68.0. I don't know how this could be fixed but I can offer to help with testing if this is useful.

mikehardy commented 5 years ago

Oh, interesting. And you're welcome :-). Let me see if there are any things that would cause it to fail on 68 though this looks ominous:

Add-on support: Add-ons are only supported if add-on authors have adapted them

https://www.thunderbird.net/en-US/thunderbird/68.0/releasenotes/

My mac and ubuntu machines are still on 60.8.0 and haven't prompted to update so I hadn't noticed the new release

mikehardy commented 5 years ago

Just leaving breadcrumbs here as I look through things:

https://developer.thunderbird.net/add-ons/tb68

They have moved a great deal of things that are fundamental to the add-on, forward-porting will take some time https://developer.thunderbird.net/add-ons/updates/tb68

My best recommendation at the moment is to stay with 60.8.0 if thunderlink is vital for you, while I plan some time to handle the changes. It may be a week or so, to set expectations.

If someone else wants to take up the work (you never know? and new collaborators are always welcome) my thinking is:

In other words, any porting necessary to make it work on TB68 is fine and testing should only be performed on TB68+ for the changes, as we won't have to worry about backwards compatibility.

ericdanan commented 5 years ago

My mac and ubuntu machines are still on 60.8.0 and haven't prompted to update so I hadn't noticed the new release

Same one Windows. At the moment 68.0 is the official release offered for download on the Thunderbird website but previous versions users will only be prompted to update when 68.1 comes out.

mikehardy commented 4 years ago

A fresh user report indicates that it works well with TB68 as is, I will see if I can build and publish it https://addons.thunderbird.net/en-US/thunderbird/addon/thunderlink/reviews/1158735/

mikehardy commented 4 years ago

I was able to simply increase the max compatible version on the add-ons site directly without even re-uploading. @ericdanan can you test and verify this worked for you?

ericdanan commented 4 years ago

I was indeed able to update the add-on in the usual way. For me some things work and some don't:

mikehardy commented 4 years ago

that is more what I was thinking would happen - helps a lot - thank you!

ericdanan commented 4 years ago

you' re welcome!

novoid commented 4 years ago

Hi, I've found this add-on via https://vxlabs.com/2019/04/20/link-thunderbird-emails-from-emacs-orgmode/ and I'm using Thunderbird 68.3.1 on latest Windows 10.

Add-on can be installed and it writes thunderlink://messageid=1578565841.995157.80027506@example.com into my clipboard. Opening those links works in my software, as long as I modify the link to thunderlink://1578565841.995157.80027506@example.com. Since the configure screen of the add-on is not working at the moment: is there the possibility to manually change the format setting (for "String 7" or such) in some json file or similar? I could not locate anything in my profile directory so far...

mikehardy commented 4 years ago

Hi @novoid :wave: - that's good sleuthing - sorry I haven't had time to update the plugin properly yet. This should be possible I think? Unless they also changed how preferences are done completely, you can see the code where specify the emitted strings here: https://github.com/mikehardy/thunderlink/blob/master/defaults/preferences/thunderlink.js

I have a prefs.js in my thunderbird profile that contains these items, and it could be hand-edited but only while thunderbird is not running I thnk (and I'd take a backup of the file just in case)

novoid commented 4 years ago

Thanks @mikehardy, That worked:

  1. install "Thunderlink" add-on in Thunderbird
  2. close Thunderbird
  3. manually add the snippet below to the prefs.js of the Thunderbird profile (note the additional user_ in contrast to the snippet above)
  4. start Thunderbird
user_pref("extensions.thunderlink.custom-tl-string-1-title", "Org mode message-ID");
user_pref("extensions.thunderlink.custom-tl-string-1", "[[messageid:<messageid>][<subject>]]");
user_pref("extensions.thunderlink.custom-tl-string-1-selection-delimiter", " / ");
user_pref("extensions.thunderlink.custom-tl-string-1-clipboard-checkbox", true);
user_pref("extensions.thunderlink.custom-tl-string-1-tagcheckbox", false);
user_pref("extensions.thunderlink.custom-tl-string-1-tag", 1);
user_pref("extensions.thunderlink.custom-tl-string-1-appendtofile-checkbox", false);
user_pref("extensions.thunderlink.custom-tl-string-1-appendtofile-path", "");

... which results in [[messageid:1578475923.390512.037689999@example.com][[Things I wanted to say to you]] in my clipboard.

Is there an overview of all the possible <fields>? I'm interested in the date sent and so forth and don't want to start a large try&error project ;-)

Thanks!

mikehardy commented 4 years ago

Cool - obviously not a great user experience vs having it all working, but getting the linking going is the important bit. Here's the list of possible placeholders: https://github.com/mikehardy/thunderlink/blob/master/chrome/thunderlink/content/preferences.xul#L108

MarioKusek commented 4 years ago

@novoid You can do it in Thunderlink settings. You don't have to edit files. Here is a picture of that configuration in the settings.

You can see that at the beginning of the window is also a list of possible tags that you can use.

novoid commented 4 years ago

Hi @MarioKusek, No, I can't. The settings at my system look like this: https://ibb.co/gJmRbq5 I'm fine with JS editing myself.

MarioKusek commented 4 years ago

@novoid I am sorry :( I did not know that. Then go ahead and change it in JS. As you can see from my screenshot there is a list of tags that you can use: <thunderlink>, <messageid>, <subject>, <filteredSubject>, <sender>, <tbexe> and <time>.

As I understand you need the time of a message and for that, you can use <time>. If you come up with some other tags please let us know and we will see if we can implement it.

I personally use taskpaper for my tasks and have following template \t- <subject>\u2028\tFrom: <sender> on <time>\u2028\t<thunderlink>\n. I append that in a file.

novoid commented 4 years ago

If I may ask for an additional feature, I'd ask for a format options:

1/10/2020 - 10:46:18 AM Karl Voit <Karl.Voit@example.com>: This is a test email is my current result.

I'd love to have this instead: 2020-01-09 Karl Voit: This is a test email

Therefore: an ISO date (instead of locale-formatted long time-stamp) and the sender name (without email address). Should I open up an extra issue for that?

MarioKusek commented 4 years ago

@novoid Yes, please open a new issue. Then we can there discuss details.

novoid commented 4 years ago

Yes, please open a new issue. Then we can there discuss details.

See https://github.com/mikehardy/thunderlink/issues/49

MarioKusek commented 4 years ago

That worked:

  1. install "Thunderlink" add-on in Thunderbird
  2. close Thunderbird
  3. manually add the snippet below to the prefs.js of the Thunderbird profile (note the additional user_ in contrast to the snippet above)
  4. start Thunderbird
user_pref("extensions.thunderlink.custom-tl-string-1-title", "Org mode message-ID");
user_pref("extensions.thunderlink.custom-tl-string-1", "[[messageid:<messageid>][<subject>]]");
user_pref("extensions.thunderlink.custom-tl-string-1-selection-delimiter", " / ");
user_pref("extensions.thunderlink.custom-tl-string-1-clipboard-checkbox", true);
user_pref("extensions.thunderlink.custom-tl-string-1-tagcheckbox", false);
user_pref("extensions.thunderlink.custom-tl-string-1-tag", 1);
user_pref("extensions.thunderlink.custom-tl-string-1-appendtofile-checkbox", false);
user_pref("extensions.thunderlink.custom-tl-string-1-appendtofile-path", "");

... which results in [[messageid:1578475923.390512.037689999@example.com][[Things I wanted to say to you]] in my clipboard.

@novoid Instead to manually edit preferences in the file you can use "Config Editor" in Thunderbird and edit the same keys in the editor. To open "Config Editor" go to Thunderbird > Preferences, select the Advanced panel, select the General tab, and click "Config Editor…". Here are official instructions.

novoid commented 3 years ago

I just want to point people to https://github.com/CamielBouchier/cb_thunderlink which is mentioned in the README of this project as a modern successor for thunderlink with the changed API of Thunderbird 78.x (and ongoing).

I was just following this issue here, missing the new opportunities of this other project.