先看一下使用下面的命令打开你的sublime:
open /Applications/Sublime Text.app/Contents/SharedSupport/bin/subl
设置一个连接到sublime,名字叫subl:
ln -s "/Applications/Sublime Text.app/Contents/SharedSupport/bin/subl" /usr/local/bin/subl
打开.bash_profile输入下面的内容:
alias subl="open -a /Applications/Sublime Text.app" export PATH=/usr/local/bin:$PATH
最后重新加载一下bash_profile
source ~/.bash_profile