最近升級了mac系統,然后接着寫代碼就出問題了。
- 報錯信息如下:
xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun
查了大量資料都推薦重新安裝xcode,用如下命令:
$ xcode-select --install
但是我用了這條命令也沒法,然后又找到以下命令,直接刪除了重新安裝。
If you installed the command line tools separately, delete them using:
$ rm -rf /Library/Developer/CommandLineTools