A smart-ish email client handler script for Brave.
This script runs Thunderbird when a mailto link is clicked in
Brave.
Under certain conditions, webmail may be used instead of
Thunderbird.
- Get the latest the release, uncompress the file and switch to the newly created directory.
- Copy
xdg-email-hook.shto a directory in your$PATH. For example,~/bin:
cp xdg-email-hook.sh ~/binA user defined variable influences this script as follows:
| XDG_EMAIL_HOOK_WEBMAIL_URL | If Thunderbird is not running |
|---|---|
| Not defined | Start Thunderbird |
| Defined or set to "" | Use gmail in Brave |
| Set to a Webmail URL | Use the URL in Brave |
Specify a webmail URL fragment that needs the rest of the URL to be provided.
For example ensure that it ends with something like ...&url= To the
right of the = will be provided.
On Brave, ensure that there are no handlers for email defined or
that mail.google.com is blocked:
brave://settings/handlers
Confirm that Thunderbird is the default email client.
The expected output from the command below is thunderbird.desktop:
xdg-mime query default 'x-scheme-handler/mailto'On KDE, if the above output is not returned:
System Settings > Applications > Default Applications- Ensure that the
Email clientis set toThunderbird.