Skip to content

Instantly share code, notes, and snippets.

@elecnix
Created September 22, 2010 03:04
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save elecnix/591056 to your computer and use it in GitHub Desktop.
Save elecnix/591056 to your computer and use it in GitHub Desktop.
set-gmail-as-default-mail-client-in-ubuntu
#!/bin/bash
# To install:
# mkdir ~bin
# Paste this in ~bin/open_mailto.sh
# chmod a+x ~bin/open_mailto.sh
# Go to System \ Preferences \ Preferred Applications
# Under Mail Reader, select Custom, and then put /home/username/bin/open_mailto.sh into the Command window, changing "username" to your username.
# Voilà! Credits to: http://www.howtogeek.com/howto/ubuntu/set-gmail-as-default-mail-client-in-ubuntu/
google-chrome "https://mail.google.com/mail?view=cm&tf=0&to=`echo $1 | sed 's/mailto://'`"
@fatso83
Copy link

fatso83 commented Nov 30, 2017

good, but "preferred applications" are no longer in preferences. and I don't know where it went either :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment