执行git clone https://github.com/xxxxx/mbstore_shell_full.git后报错:
xcrun: error: active developer path ("/Users/ng/Downloads/Xcode.app/Contents/Developer") does not exist
Use `sudo xcode-select --switch path/to/Xcode.app` to specify the Xcode that you wish to use for command line developer tools, or use `xcode-select --install` to install the standalone command line developer tools.
See `man xcode-select` for more details.
尝试使用(无效,仍旧报错):
sudo xcode-select --switch path/to/Xcode.app // path代入Xcode目录地址
以及使用(无效,仍旧报错):
xcode-select --install
报错:
xcode-select: error: command line tools are already installed, use "Software Update" to install updates
尝试执行Software Update也报错,这边应该只是提醒我们用更新的命令,而不是直接输入Software Update
有人说以下方法有效(试了重新下载,还是无效,git version报错):
rm -rf /Library/Developer/CommandLineTools
xcode-select --install
真正有效的来了:
x-code更新后,svn 命令(eg: svn update)不好使了,执行下列命令
sudo xcode-select -switch /Applications/Xcode.app/Contents/Developer
$ git version
git version 2.20.1 (Apple Git-117)
来源:CSDN
作者:hzxOnlineOk
链接:https://blog.csdn.net/hzxOnlineOk/article/details/104107002