说明
sublime text 官方说这样可以,其实不适用
https://www.sublimetext.com/docs/3/osx_command_line.html
使用原生bash
alias subl=\''/Applications/Sublime Text 3.app/Contents/SharedSupport/bin/subl'\'
使用 zsh
在文件 ~/.zshrc
最后添加
alias subl="'/Applications/Sublime Text.app/Contents/SharedSupport/bin/subl'"
alias nano="subl"
export EDITOR="subl"
再执行
source ~/.zshrc
# 使用
```sh
# 任意目录或者文件
subl [fileOrFolder]
网友评论