This is a nice way of having
mailto: links open in Gmail with Debian and GNOME (it’ll probably work with other online email providers and other Linux distributions and other desktop environments).
All you need to do is create a file named
gmail.desktop in the
/usr/share/applications directory (you should probably be able to install it locally in
~/.local/share/applications, if you prefer) and add the following:
Comment=Gmail email client
Then ‘Gmail’ should be listed as an option in
Gnome Settings > Details > Default Applications (you may need to run
sudo xdg-desktop-menu forceupdate first).
Note, here I’m using Debian’s
sensible-browser command to launch the default web browser.