Reputation: 39
I have read any number of posts explaining how to set the default editor for the terminal on a mac o stackoverflow. They all describe the same thing inserting a line in .bash_profile (or sometimes .bashrc) like:
export EDITOR='/Applications/TextWrangler.app'
or:
export EDITOR='/Applications/TextWrangler.app/Contents/MacOS/TextWrangler'
Nothing works. The terminal continues to default to TextEdit
.
Has apple set this profile somewhere else in a way that overrides .bash_profile
?
Can someone help me with this?
Upvotes: 1
Views: 1612
Reputation: 42719
According to the man page for open
:
-e Causes the file to be opened with /Applications/TextEdit"
In any case, open
is an OS X command which will use the associations that are set for the file, the same as Finder does. The only things that will obey EDITOR
are command line programs designed to run in a Unix environment.
Upvotes: 1