Info
- OS: Mac OSX High Sierra 10.13.6 (17G65)
- Sublime Version: Version 3.1.1 Build 3176
I took the command from SublimeText website
Got An Error
ln -s "/Applications/Sublime Text.app/Contents/SharedSupport/bin/subl" ~/bin/subl
ln: /Users/jkirchoff/bin/subl: No such file or directory
Did Some Checking
Just to make sure the path exists.
NOTE: the "
's allow the space in the path.
ln -s "/Applications/Sublime Text.app/Contents/SharedSupport/bin/subl"
ln: ./subl: File exists
Compared Note from this page
What @NotSimon wrote on this page, Then Ran:
ln -s "/usr/local/bin/subl"
ln: ./subl: File exists
and then followed the rest.
The Complete Line that worked for me:
ln -s "/Applications/Sublime Text.app/Contents/SharedSupport/bin/subl" /usr/local/bin/subl
Success
Now I can run subl
as a command in Terminal!
This command opens the directory as a "Project" in SublimeText.
subl ~/Desktop
Optional
I followed the SublimeText recommendation & added this to my
~/.bash_profile
.
The command works without it, just following guidelines.
echo "export EDITOR='subl -w'" >> ~/.bash_profile