How do i change my default?

How do I change OS X's default mail app without a GUI?

  • How can I change the default Mail application in OS X with a script (not through the Mail.app GUI)? I need to change the default Mail application as part of a larger setup process that will be used with a lot of computers. I've looked around online quite a bit and the only ways I've found are through Mail's GUI or some other third party application's GUI. I need to do this in an Applescript, but I can call some other kind of script if I need to. My ideal solution would be something I can do in right in the Applescript or a simple command line command I can run. Does anyone know of anything?

  • Answer:

    checkout changing/editing plists... most of the prefs in os x are defined by them. http://www.wikihow.com/Change-the-Default-Email-Client-on-Mac-OS-X

sjl7678 at Ask.Metafilter.Com Visit the source

Was this solution helpful to you?

Other answers

The file you want is ~/Library/Preferences/com.apple.launchservices. At the end of the file are the handlers for various filetypes/urls- one of them is "LSHandlerURLScheme = mailto", and the Handler for it is set to "com.apple.mail". Go to Apple Mail, change the pref there, and see what the change in the file is. If you know how to script up search and replace, you should be good to go.

mkultra

Related Q & A:

Just Added Q & A:

Find solution

For every problem there is a solution! Proved by Solucija.

  • Got an issue and looking for advice?

  • Ask Solucija to search every corner of the Web for help.

  • Get workable solutions and helpful tips in a moment.

Just ask Solucija about an issue you face and immediately get a list of ready solutions, answers and tips from other Internet users. We always provide the most suitable and complete answer to your question at the top, along with a few good alternatives below.