美文网首页
在macOS Terminal中使用vscode

在macOS Terminal中使用vscode

作者: OOPhantom | 来源:发表于2017-05-13 14:37 被阅读60次

1. 在~/.bash_profile中添加

code () { VSCODE_CWD="$PWD" open -n -b "com.microsoft.VSCode" --args $* ;}

2. 在Terminal中执行使之前的配置生效

source ~/.bash_profile

3. 在Terminal中输入

code          #启动vscode

code .        #启动vscode并打开当前目录

相关文章

网友评论

      本文标题:在macOS Terminal中使用vscode

      本文链接:https://www.haomeiwen.com/subject/zcuxxxtx.html