CocoaPods执行pod setup后显示错误信息
Setting up CocoaPods master repo
fatal: Not a git repository (or any of the parent directories): .git
[!] The `master` repo is not a git repo.
这是说明没有找到.git目录,只需要前往
~/.cocoapods/repos/master
路径找到使用git创建一个目录即可:
git init
另一种原因:
1.安装了多个个Xcode.app引起
2.下载后直接从镜像中打开了xcode,然后xcode就把commandline tools安装位置记成了镜像中的位置了
解决:
终端执行即可
sudo xcode-select -switch /Applications/Xcode.app
网友评论