Mac OS X 10.10(yosemite)更新后,cocoapods出错, 及cocoapods更新至0.34后, 错误情况整理
2014-10-23 10:15
363 查看
1:Mac升级10.10后,执行pod install出错如下
解决方案:卸载0.1.2版本, 再安装最新版本
2:安装成功后, 再执行 pod install 还是出错, 如下
解决方案: podfile格式变化了. 要用新格式.
3: podfile格式变化
以前的podfile格式如下
以下是官网的podfile介绍
http://guides.cocoapods.org/syntax/podfile.html
http://guides.cocoapods.org/using/the-podfile.html
The Podfile is a specification that describes the dependencies of the targets of one or more Xcode projects. The Podfile always creates an implicit target, named
A podfile can be very simple:
An example of a more complex podfile can be:
ps:podfile中尤其要注意标点符号.
QTX-Will-mini:NewHishop willbin$ pod install [!] Unable to load a specification for the plugin `/Library/Ruby/Gems/2.0.0/gems/cocoapods-try-release-fix-0.1.2` /Library/Ruby/Gems/2.0.0/gems/cocoapods-0.34.4/lib/cocoapods/user_interface/error_report.rb:13:in `report': incompatible character encodings: UTF-8 and ASCII-8BIT (Encoding::CompatibilityError) from /Library/Ruby/Gems/2.0.0/gems/cocoapods-0.34.4/lib/cocoapods/command.rb:63:in `report_error' from /Library/Ruby/Gems/2.0.0/gems/claide-0.7.0/lib/claide/command.rb:300:in `handle_exception' from /Library/Ruby/Gems/2.0.0/gems/claide-0.7.0/lib/claide/command.rb:274:in `rescue in run' from /Library/Ruby/Gems/2.0.0/gems/claide-0.7.0/lib/claide/command.rb:264:in `run' from /Library/Ruby/Gems/2.0.0/gems/cocoapods-0.34.4/lib/cocoapods/command.rb:50:in `run' from /Library/Ruby/Gems/2.0.0/gems/cocoapods-0.34.4/bin/pod:33:in `<top (required)>' from /usr/bin/pod:23:in `load' from /usr/bin/pod:23:in `<main>'
解决方案:卸载0.1.2版本, 再安装最新版本
QTX-Will-mini:NewHishop willbin$ sudo gem uninstall cocoapods-try-release-fix Password: Select gem to uninstall: 1. cocoapods-try-release-fix-0.1.1 2. cocoapods-try-release-fix-0.1.2 3. All versions > 3 Successfully uninstalled cocoapods-try-release-fix-0.1.1 Successfully uninstalled cocoapods-try-release-fix-0.1.2 QTX-Will-mini:NewHishop willbin$ sudo gem install cocoapods Successfully installed cocoapods-0.34.4 Parsing documentation for cocoapods-0.34.4 1 gem installed
2:安装成功后, 再执行 pod install 还是出错, 如下
QTX-Will-mini:NewHishop willbin$ pod install /Library/Ruby/Gems/2.0.0/gems/cocoapods-0.34.4/lib/cocoapods/user_interface/error_report.rb:13:in `report': incompatible character encodings: UTF-8 and ASCII-8BIT (Encoding::CompatibilityError) from /Library/Ruby/Gems/2.0.0/gems/cocoapods-0.34.4/lib/cocoapods/command.rb:63:in `report_error' from /Library/Ruby/Gems/2.0.0/gems/claide-0.7.0/lib/claide/command.rb:300:in `handle_exception' from /Library/Ruby/Gems/2.0.0/gems/claide-0.7.0/lib/claide/command.rb:274:in `rescue in run' from /Library/Ruby/Gems/2.0.0/gems/claide-0.7.0/lib/claide/command.rb:264:in `run' from /Library/Ruby/Gems/2.0.0/gems/cocoapods-0.34.4/lib/cocoapods/command.rb:50:in `run' from /Library/Ruby/Gems/2.0.0/gems/cocoapods-0.34.4/bin/pod:33:in `<top (required)>' from /usr/bin/pod:23:in `load' from /usr/bin/pod:23:in `<main>'
解决方案: podfile格式变化了. 要用新格式.
3: podfile格式变化
以前的podfile格式如下
platform :ios, '7.0' pod 'AFNetworking'
以下是官网的podfile介绍
http://guides.cocoapods.org/syntax/podfile.html
http://guides.cocoapods.org/using/the-podfile.html
The Podfile is a specification that describes the dependencies of the targets of one or more Xcode projects. The Podfile always creates an implicit target, named
default, which links to the first target of the user project.
A podfile can be very simple:
source 'https://github.com/CocoaPods/Specs.git' pod 'AFNetworking', '~> 1.0'
An example of a more complex podfile can be:
source 'https://github.com/CocoaPods/Specs.git' platform :ios, '6.0' inhibit_all_warnings! xcodeproj 'MyProject' pod 'ObjectiveSugar', '~> 0.5' target :test do pod 'OCMock', '~> 2.0.1' end post_install do |installer| installer.project.targets.each do |target| puts "#{target.name}" end end
ps:podfile中尤其要注意标点符号.
相关文章推荐
- Mac OS X 10.10(yosemite)更新后,cocoapods出错, 及cocoapods更新至0.34后, 错误情况整理
- mac_os_x更新yosemite以后github客户端更新提示ca认证错误解决办法
- 升级Mac os x 10.10+xcode6.1之后,Cocoapods出现问题的解决方案
- Xcode7使用CocoaPods不工作, 在更新 Mac OS X EI Capitain之后
- 在更新 Mac OS X EI Capitain之后Xcode7使用CocoaPods不工作的解决方法
- Mac OS X 10.10更新及体验
- Mac OS X Yosemite 10.10 配置 Apache+PHP 教程注意事项
- 在Mac OS X Yosemite (10.10) 下搭建JSP服务器
- Mac OS X 10.10 Yosemite下配置 apache+php
- VMware Workstation 11 或者 VMware Player 7安装MAC OS X 10.10 Yosemite
- MAC 升级到10.10(OS X Yosemite)下apache+php的配置问题
- mac 简单制作 OS X Yosemite 10.10 正式版U盘USB启动安装盘方法教程 (全新安装 Mac 系统)
- Mac Yosemite环境下搭建CocoaPods
- mac OS X 10.10更新gcc 4.9.1后默认无法编译连接的问题
- 解决Mac OS X 升级10.10(Yosemite)后ADT(Eclipse)无法找到真机
- Mac OS X Yosemite 10.10 配置 Apache+PHP 教程注意事项
- MAC 升级到10.10(OS X Yosemite)下 webstorm打不开
- VM10装Mac OS X 10.9.3及更新到Mac OS X 10.10
- Mac OS X 10.10 Yosemite 关闭Dashboard和Spotlight
- mac OS X 10.10更新gcc 4.9.1后默认无法编译连接的问题