CocoaPods安装/搜索pod的错误

时间:2014-01-24 21:13:16

标签: cocoapods

我正在尝试在我的项目中使用一些pod。但终端导致:

$ pod install
Analyzing dependencies
[!] Unable to find a specification for `Mantle`.

所以,我试图搜索pod或其他人以及我尝试过的任何pod,结果是:

$ pod search Mantle
[!] Unable to find a pod with name matching `Mantle'

$ pod search LBBlurredImage
[!] Unable to find a pod with name matching `LBBlurredImage'

有什么问题?! https://github.com/CocoaPods/Specs包含所有广告...

4 个答案:

答案 0 :(得分:10)

这也恰好发生在我身上。某种程度上,CocoaPods的回购被搞砸了。这解决了我的情况:

rm -rf ~/.cocoapods
pod setup
pod install

希望有所帮助! :)

答案 1 :(得分:2)

您似乎需要运行pod setup

编辑:

理论上,如果您收到有关主仓库的错误,可以手动添加它:

git clone https://github.com/CocoaPods/Specs.git ~/.cocoapods/repos/master

答案 2 :(得分:1)

试试这个适合我的代码

pod repo remove master
pod setup

答案 3 :(得分:1)

我正在尝试这些命令而无法理解发生了什么,因为屏幕上没有打印日志表明进度。

抬头,这是安装的时间,所以运行命令,高枕无忧:)

清理目录

$ rm -rf ~/.cocoapods

因此,在以

开头的命令末尾添加详细信息

$ sudo gem install cocoapods --verbose

这里发生了很多重定向,需要额外的时间。

GET https://rubygems.org/quick/Marshal.4.8/thread_safe-0.1.3.gemspec.rz
302 Moved Temporarily
GET https://rubygems.global.ssl.fastly.net/quick/Marshal.4.8/thread_safe-0.1.3.gemspec.rz
200 OK
GET https://rubygems.org/quick/Marshal.4.8/thread_safe-0.2.0.gemspec.rz
302 Moved Temporarily
GET https://rubygems.global.ssl.fastly.net/quick/Marshal.4.8/thread_safe-0.2.0.gemspec.rz
200 OK
GET https://rubygems.org/quick/Marshal.4.8/thread_safe-0.3.1.gemspec.rz
302 Moved Temporarily
GET https://rubygems.global.ssl.fastly.net/quick/Marshal.4.8/thread_safe-0.3.1.gemspec.rz
200 OK
GET https://rubygems.org/quick/Marshal.4.8/thread_safe-0.3.2.gemspec.rz
302 Moved Temporarily
GET https://rubygems.global.ssl.fastly.net/quick/Marshal.4.8/thread_safe-0.3.2.gemspec.rz
200 OK
GET https://rubygems.org/quick/Marshal.4.8/thread_safe-0.3.3.gemspec.rz
302 Moved Temporarily
GET https://rubygems.global.ssl.fastly.net/quick/Marshal.4.8/thread_safe-0.3.3.gemspec.rz
200 OK
GET https://rubygems.org/quick/Marshal.4.8/thread_safe-0.3.4.gemspec.rz
302 Moved Temporarily
GET https://rubygems.global.ssl.fastly.net/quick/Marshal.4.8/thread_safe-0.3.4.gemspec.rz
200 OK
GET https://rubygems.org/quick/Marshal.4.8/thread_safe-0.3.5.gemspec.rz
302 Moved Temporarily
GET https://rubygems.global.ssl.fastly.net/quick/Marshal.4.8/thread_safe-0.3.5.gemspec.rz
200 OK
Installing gem cocoapods-0.39.0
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/command/cache/clean.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/command/cache/list.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/command/cache.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/command/init.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/command/inter_process_communication.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/command/lib.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/command/list.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/command/outdated.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/command/project.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/command/repo/add.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/command/repo/lint.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/command/repo/list.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/command/repo/push.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/command/repo/remove.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/command/repo/update.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/command/repo.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/command/setup.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/command/spec/cat.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/command/spec/create.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/command/spec/edit.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/command/spec/lint.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/command/spec/which.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/command/spec.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/command.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/config.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/downloader/cache.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/downloader/request.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/downloader/response.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/downloader.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/executable.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/external_sources/abstract_external_source.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/external_sources/downloader_source.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/external_sources/path_source.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/external_sources/podspec_source.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/external_sources.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/gem_version.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/generator/acknowledgements/markdown.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/generator/acknowledgements/plist.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/generator/acknowledgements.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/generator/bridge_support.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/generator/copy_resources_script.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/generator/dummy_source.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/generator/embed_frameworks_script.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/generator/header.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/generator/info_plist_file.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/generator/module_map.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/generator/prefix_header.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/generator/umbrella_header.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/generator/xcconfig/aggregate_xcconfig.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/generator/xcconfig/pod_xcconfig.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/generator/xcconfig/xcconfig_helper.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/generator/xcconfig.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/hooks_manager.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/installer/analyzer/analysis_result.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/installer/analyzer/locking_dependency_analyzer.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/installer/analyzer/sandbox_analyzer.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/installer/analyzer/specs_state.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/installer/analyzer/target_inspection_result.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/installer/analyzer/target_inspector.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/installer/analyzer.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/installer/file_references_installer.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/installer/migrator.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/installer/pod_source_installer.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/installer/pod_source_preparer.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/installer/podfile_validator.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/installer/post_install_hooks_context.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/installer/pre_install_hooks_context.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/installer/source_provider_hooks_context.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/installer/target_installer/aggregate_target_installer.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/installer/target_installer/pod_target_installer.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/installer/target_installer.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/installer/user_project_integrator/target_integrator/xcconfig_integrator.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/installer/user_project_integrator/target_integrator.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/installer/user_project_integrator.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/installer.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/open_uri.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/project.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/resolver/lazy_specification.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/resolver.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/sandbox/file_accessor.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/sandbox/headers_store.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/sandbox/path_list.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/sandbox/pod_dir_cleaner.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/sandbox/podspec_finder.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/sandbox.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/sources_manager.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/target/aggregate_target.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/target/pod_target.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/target.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/user_interface/error_report.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/user_interface.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods/validator.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/lib/cocoapods.rb
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/bin/pod
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/bin/sandbox-pod
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/README.md
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/LICENSE
/Library/Ruby/Gems/2.0.0/gems/cocoapods-0.39.0/CHANGELOG.md
/usr/local/bin/pod
/usr/local/bin/sandbox-pod
Successfully installed cocoapods-0.39.0
Parsing documentation for cocoapods-0.39.0
Parsing sources...
100% [93/93]  lib/cocoapods/validator.rb
1 gem installed

然后跑 $ pod setup --verbose

Setting up CocoaPods master repo

Creating shallow clone of spec repo `master` from `https://github.com/CocoaPods/Specs.git` (branch `master`)
  $ /usr/bin/git clone https://github.com/CocoaPods/Specs.git master --depth=1
  Cloning into 'master'...
  Checking out files: 100% (70092/70092), done.
  $ /usr/bin/git checkout master
  Already on 'master'
  Your branch is up-to-date with 'origin/master'.

CocoaPods 1.0.0.beta.3 is available.
To update use: `gem install cocoapods --pre`
[!] This is a test version we'd love you to try.

For more information see http://blog.cocoapods.org
and the CHANGELOG for this version http://git.io/BaH8pQ.

Setup completed

之后 $ pod install --verbose

  Preparing

Updating local specs repositories

Updating spec repo `master`
  $ /usr/bin/git pull --ff-only
  Already up-to-date.

CocoaPods 1.0.0.beta.3 is available.
To update use: `gem install cocoapods --pre`
[!] This is a test version we'd love you to try.

For more information see http://blog.cocoapods.org
and the CHANGELOG for this version http://git.io/BaH8pQ.


Analyzing dependencies

Inspecting targets to integrate
  Using `ARCHS` setting to build architectures of target `Pods`: (``)
  Using `ARCHS` setting to build architectures of target `Pods-Vue`: (``)
  Using `ARCHS` setting to build architectures of target `Pods-VueTests`: (``)

Finding Podfile changes
  - AFNetworking
  - FBSDKCoreKit
  - FBSDKLoginKit
  - FBSDKMessengerShareKit
  - FBSDKShareKit
  - Facebook-iOS-SDK
  - LayerKit
  - Localytics
  - REMenu
  - Realm
  - SDWebImage
  - SSKeychain
  - libextobjc

Resolving dependencies of `Podfile`

Comparing resolved specification to the sandbox manifest
  A AFNetworking
  A Bolts
  A FBSDKCoreKit
  A FBSDKLoginKit
  A FBSDKMessengerShareKit
  A FBSDKShareKit
  A Facebook-iOS-SDK
  A LayerKit
  A Localytics
  A REMenu
  A Realm
  A SDWebImage
  A SSKeychain
  A libextobjc

Downloading dependencies

-> Installing AFNetworking (2.6.0)
 > Git download
 > Git download
     $ /usr/bin/git clone https://github.com/AFNetworking/AFNetworking.git /var/folders/0t/dp8zzlyj58z5w00z21h5pcd00000gt/T/d20160206-31717-10giru1 --single-branch
     --depth 1 --branch 2.6.0 --recursive
     Cloning into '/var/folders/0t/dp8zzlyj58z5w00z21h5pcd00000gt/T/d20160206-31717-10giru1'...
     Note: checking out 'f28d4af6c47bad1192f87debcc76586e3a8a141a'.

     You are in 'detached HEAD' state. You can look around, make experimental
     changes and commit them, and you can discard any commits you make in this
     state without impacting any branches by performing another checkout.

     If you want to create a new branch to retain commits you create, you may
     do so (now or later) by using -b with the checkout command again. Example:

       git checkout -b <new-branch-name>

  > Copying AFNetworking from `/Users/vinay/Library/Caches/CocoaPods/Pods/Release/AFNetworking/2.6.0-79f7e` to `Pods/AFNetworking`