Objective c Cocoapods更新错误

Objective c Cocoapods更新错误,objective-c,git,cocoapods,Objective C,Git,Cocoapods,我从github中提取信息并运行pod update,得到以下错误: Setting up CocoaPods master repo Already up-to-date. [!] The `master` repo requires CocoaPods 0.29.0 - Update CocoaPods, or checkout the appropriate tag in the repo. /Library/Ruby/Gems/2.0.0/gems/claide-0.4.0/

我从github中提取信息并运行
pod update
,得到以下错误:

Setting up CocoaPods master repo
Already up-to-date.
[!] The `master` repo requires CocoaPods 0.29.0 - 
Update CocoaPods, or checkout the appropriate tag in the repo.

    /Library/Ruby/Gems/2.0.0/gems/claide-0.4.0/lib/claide/command.rb:217:in `rescue in run': undefined method `verbose?' for nil:NilClass (NoMethodError)
        from /Library/Ruby/Gems/2.0.0/gems/claide-0.4.0/lib/claide/command.rb:210:in `run'
        from /Library/Ruby/Gems/2.0.0/gems/cocoapods-0.28.0/lib/cocoapods/command.rb:52:in `run'
        from /Library/Ruby/Gems/2.0.0/gems/cocoapods-0.28.0/bin/pod:24:in `<top (required)>'
        from /usr/bin/pod:23:in `load'
        from /usr/bin/pod:23:in `<main>'
我也有类似的问题。
请尝试卸载CocoaPods,然后再次安装。这对我有帮助,我希望它也能对你有帮助

如果CocoaPods已经存在,则仅运行Install命令不会更新:

sudo gem install cocoapods
无需卸载

考虑到Alexander Kostiev的评论,如果您想要或需要卸载旧版本,您可以使用此命令了解您的版本:

gem list --local | grep cocoapods
gem uninstall cocoapods -v 0.31.1
gem uninstall cocoapods-core -v 0.31.1
gem uninstall cocoapods-downloader -v 0.4.1
输出如下所示:

cocoapods (0.32.1, 0.31.1)
cocoapods-core (0.32.1, 0.31.1)
cocoapods-downloader (0.5.0, 0.4.1)
并使用此命令删除特定的一个:

gem list --local | grep cocoapods
gem uninstall cocoapods -v 0.31.1
gem uninstall cocoapods-core -v 0.31.1
gem uninstall cocoapods-downloader -v 0.4.1

是否有更新方法来获取更新版本的CocoaPods?如果按照建议重新安装CocoaPods后运行
gem list--local | grep CocoaPods
,您可能会看到早期版本的CoCoCoapods仍然在您的机器上