关于Cocoapods更新的问题
2015-09-23 14:32
465 查看
在使用cocoapods的过程中,遇到了一个问题,就是在更新cocoapods的过程中,遇到一个问题,报错!大致如下;
Podfile文件如下:
platform:ios, ‘7.0’
pod ‘SDWebImage’, ‘~> 3.7.1’
pod ‘CocoaHTTPServer’, ‘~> 2.3’
pod ‘RoutingHTTPServer’, ‘~> 1.0.0’
pod ‘Masonry’, ‘~> 0.6.1’
pod ‘ASIHTTPRequest’, ‘~> 1.8.2’
pod ‘MBProgressHUD’, ‘~> 0.9.1’
pod ‘AFNetworking’, ‘~> 2.5.4’
在利用命令(首先切换到对项目所在目录)
Update all pods
Analyzing dependencies
CocoaPods 0.39.0.beta.4 is available.
To update use:
[!] 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.
Downloading dependencies
Installing AFNetworking (2.5.4)
Installing ASIHTTPRequest (1.8.2)
Installing CocoaAsyncSocket (7.4.2)
Installing CocoaHTTPServer (2.3)
Installing CocoaLumberjack (2.0.1)
Installing MBProgressHUD (0.9.1)
Installing Masonry (0.6.3)
Installing Reachability (3.2)
Installing RoutingHTTPServer (1.0.0)
Installing SDWebImage (3.7.3)
Generating Pods project
2015-09-23 13:18:31.468 ruby[1245:292388] [MT] DVTAssertions: ASSERTION FAILURE in /Library/Caches/com.apple.xbs/Sources/IDEFrameworks/IDEFrameworks-8227/IDEFoundation/Initialization/IDEInitialization.m:590
Details: Assertion failed: _initializationCompletedSuccessfully
Function: BOOL IDEIsInitializedForUserInteraction()
Thread: {number = 1, name = main}
Hints: None
Backtrace:
0 0x0000000106998a5c -[DVTAssertionHandler handleFailureInFunction:fileName:lineNumber:assertionSignature:messageFormat:arguments:] (in DVTFoundation)
1 0x00000001069981e9 _DVTAssertionHandler (in DVTFoundation)
2 0x0000000106998455 _DVTAssertionFailureHandler (in DVTFoundation)
3 0x00000001069983b7 _DVTAssertionFailureHandler (in DVTFoundation)
4 0x0000000107e42f5c IDEIsInitializedForUserInteraction (in IDEFoundation)
5 0x000000010aa42eb9 +[PBXProject projectWithFile:errorHandler:readOnly:] (in DevToolsCore)
6 0x000000010aa44a3e +[PBXProject projectWithFile:errorHandler:] (in DevToolsCore)
7 0x00007fff91012f44 ffi_call_unix64 (in libffi.dylib)
Abort trap: 6
victordeiMac:swiftproject victorgem−sources−lERROR:Invalidoption:−sources.See‘gem–help′.victordeiMac:swiftprojectvictor gem -version
ERROR: Invalid option: -version. See ‘gem –help’.
发现应该是版本的问题,进行更新
首先查看当前cocoapods版本的命令为:
http://ruby.taobao.org/
通过如下命令进行操作:
Updating local specs repositories
CocoaPods 0.39.0.beta.4 is available.
To update use:
[!] 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
Downloading dependencies
Installing AFNetworking (2.5.4)
Installing ASIHTTPRequest (1.8.2)
Installing CocoaAsyncSocket (7.4.2)
Installing CocoaHTTPServer (2.3)
Installing CocoaLumberjack (2.0.1)
Installing MBProgressHUD (0.9.1)
Installing Masonry (0.6.3)
Installing Reachability (3.2)
Installing RoutingHTTPServer (1.0.0)
Installing SDWebImage (3.7.3)
Generating Pods project
Integrating client project
[!] Please close any current Xcode sessions and use
Sending stats
Sending stats
至此,该问题解决了。
参考链接
http://www.cnblogs.com/brycezhang/p/3675670.html
http://code4app.com/article/cocoapods-install-usage
Podfile文件如下:
platform:ios, ‘7.0’
pod ‘SDWebImage’, ‘~> 3.7.1’
pod ‘CocoaHTTPServer’, ‘~> 2.3’
pod ‘RoutingHTTPServer’, ‘~> 1.0.0’
pod ‘Masonry’, ‘~> 0.6.1’
pod ‘ASIHTTPRequest’, ‘~> 1.8.2’
pod ‘MBProgressHUD’, ‘~> 0.9.1’
pod ‘AFNetworking’, ‘~> 2.5.4’
在利用命令(首先切换到对项目所在目录)
pod install
的时候出现以下问题:Update all pods
Analyzing dependencies
CocoaPods 0.39.0.beta.4 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.
Downloading dependencies
Installing AFNetworking (2.5.4)
Installing ASIHTTPRequest (1.8.2)
Installing CocoaAsyncSocket (7.4.2)
Installing CocoaHTTPServer (2.3)
Installing CocoaLumberjack (2.0.1)
Installing MBProgressHUD (0.9.1)
Installing Masonry (0.6.3)
Installing Reachability (3.2)
Installing RoutingHTTPServer (1.0.0)
Installing SDWebImage (3.7.3)
Generating Pods project
2015-09-23 13:18:31.468 ruby[1245:292388] [MT] DVTAssertions: ASSERTION FAILURE in /Library/Caches/com.apple.xbs/Sources/IDEFrameworks/IDEFrameworks-8227/IDEFoundation/Initialization/IDEInitialization.m:590
Details: Assertion failed: _initializationCompletedSuccessfully
Function: BOOL IDEIsInitializedForUserInteraction()
Thread: {number = 1, name = main}
Hints: None
Backtrace:
0 0x0000000106998a5c -[DVTAssertionHandler handleFailureInFunction:fileName:lineNumber:assertionSignature:messageFormat:arguments:] (in DVTFoundation)
1 0x00000001069981e9 _DVTAssertionHandler (in DVTFoundation)
2 0x0000000106998455 _DVTAssertionFailureHandler (in DVTFoundation)
3 0x00000001069983b7 _DVTAssertionFailureHandler (in DVTFoundation)
4 0x0000000107e42f5c IDEIsInitializedForUserInteraction (in IDEFoundation)
5 0x000000010aa42eb9 +[PBXProject projectWithFile:errorHandler:readOnly:] (in DevToolsCore)
6 0x000000010aa44a3e +[PBXProject projectWithFile:errorHandler:] (in DevToolsCore)
7 0x00007fff91012f44 ffi_call_unix64 (in libffi.dylib)
Abort trap: 6
victordeiMac:swiftproject victorgem−sources−lERROR:Invalidoption:−sources.See‘gem–help′.victordeiMac:swiftprojectvictor gem -version
ERROR: Invalid option: -version. See ‘gem –help’.
发现应该是版本的问题,进行更新
首先查看当前cocoapods版本的命令为:
pod –version
然后按照命令进行更新$ sudo gem update –system // 先更新gem,国内需要切换源
$ gem sources –remove https://rubygems.org/
$ gem sources -a http://ruby.taobao.org/
$ gem sources -l
*** CURRENT SOURCES ***http://ruby.taobao.org/
$ sudo gem install cocoapods // 安装cocoapods
$ pod setup
最后一步进行更新通过如下命令进行操作:
pod update
Update all podsUpdating local specs repositories
CocoaPods 0.39.0.beta.4 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
Downloading dependencies
Installing AFNetworking (2.5.4)
Installing ASIHTTPRequest (1.8.2)
Installing CocoaAsyncSocket (7.4.2)
Installing CocoaHTTPServer (2.3)
Installing CocoaLumberjack (2.0.1)
Installing MBProgressHUD (0.9.1)
Installing Masonry (0.6.3)
Installing Reachability (3.2)
Installing RoutingHTTPServer (1.0.0)
Installing SDWebImage (3.7.3)
Generating Pods project
Integrating client project
[!] Please close any current Xcode sessions and use
swiftproject.xcworkspacefor this project from now on.
Sending stats
Sending stats
至此,该问题解决了。
参考链接
http://www.cnblogs.com/brycezhang/p/3675670.html
http://code4app.com/article/cocoapods-install-usage
相关文章推荐
- 峰回路转,Firefox 浏览器即将重返 iOS 平台
- 峰回路转,Firefox 浏览器即将重返 iOS 平台
- 不可修补的 iOS 漏洞可能导致 iPhone 4s 到 iPhone X 永久越狱
- iOS 12.4 系统遭黑客破解,漏洞危及数百万用户
- 每日安全资讯:NSO,一家专业入侵 iPhone 的神秘公司
- [转][源代码]Comex公布JailbreakMe 3.0源代码
- js判断客户端是iOS还是Android等移动终端的方法
- IOS开发环境windows化攻略
- .net平台推送ios消息的实现方法
- 探讨Android与iOS,我们将何去何从?
- Android、iOS和Windows Phone中的推送技术详解
- IOS 改变键盘颜色代码
- 举例详解iOS开发过程中的沙盒机制与文件
- Android和IOS的浏览器中检测是否安装某个客户端的方法
- javascript实现阻止iOS APP中的链接打开Safari浏览器
- IOS开发第三方语音-微信语音
- iOS开发之路--微博OAuth授权_取得用户授权的accessToken
- 基于UIControl控件实现ios点赞功能
- iOS开发中实现邮件和短信发送的简单示例