更新后報(bào)錯(cuò)
錯(cuò)誤提示如下:
dyld: Library not loaded: @rpath/libswiftCore.dylib
Referenced from: /Applications/Xcode.app/Contents/Developer/usr/bin/xcodebuild
Reason: image not found
git: error: unable to locate xcodebuild, please make sure the path to the Xcode folder is set correctly!
git: error: You can set the path to the Xcode folder using /usr/bin/xcode-select -switch
查找解決方案
網(wǎng)上查到輸入下面的命令
sudo xcode-select --switch /Library/Developer/CommandLineTools/
仍然報(bào)錯(cuò):
xcode-select: error: invalid developer directory '/Library/Developer/CommandLineTools/'
安裝xcode-select
xcode-select --install
根據(jù)提示的彈框安裝xcode-select
再次執(zhí)行如下命令
sudo xcode-select --switch /Library/Developer/CommandLineTools/
執(zhí)行完不報(bào)錯(cuò),ok