mime and web pages

Volker Wysk post at volker-wysk.de
Mon Aug 17 13:53:51 UTC 2020


Am Montag, den 17.08.2020, 22:52 +1000 schrieb Karl Auer:
> I want to open specific browsers (or more generally, pass specific
> URLS
> to specific programs) within the Ubuntu desktop.
> 
> For example, if I receive an email with a link in it, and click on
> that
> link, I want to pass that link to a specific program.
> 
> I've spent quite  bit of time googling around mime types and so on,
> but
> everything I find is about opening files, not links. I've also looked
> at xdg-open, xdg-settings etc, but I cannot figure out what xdg-open
> is
> looking at when it decides to run Firefox, either! It's allegedly
> mimeapps.list, but it is definitely not using the one in my home
> directoy and the others seem to belong to various snaps.
> 
> Another way to look it this would be to say I want to substitute my
> own
> program for Firefox as far as what is used to open links.

Evolution uses a .desktop file for the browser, which it uses for
opening a link in a mail. This is probably Firefox or Chrome. For
Firefox, it's the firefox.desktop file which is consulted. 

This can (i believe) be chosen in the "Vorgabeanwendungen" ("default
applications"?) in the system settings. In this file, it is specified
how the default browser should be opened. It is located in
/usr/share/applications and possibly in .local/share/applications. The
second one takes precedence over the first one, so you can replace
system wide ones with private ones.

The firefox.desktop file has, among other things, this entry in about
the middle: 

Exec=firefox %u

Here the "%u" should be the URL. 

I don't know if you can configure evolution, such that it uses a
program different from the default browser.

Hope this helps,
Volker
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: This is a digitally signed message part
URL: <https://lists.ubuntu.com/archives/ubuntu-users/attachments/20200817/aec33479/attachment.sig>


More information about the ubuntu-users mailing list