一、Cocoapod 执行pod install命令时报错

  

[!] An error occurred while processing the post-install hook of the Podfile.

no implicit conversion of nil into String

/System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib/ruby/2.3.0/pathname.rb:349:in `initialize'
/System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib/ruby/2.3.0/pathname.rb:349:in `new'
/System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib/ruby/2.3.0/pathname.rb:349:in `+'
/Library/Ruby/Gems/2.3.0/gems/xcodeproj-1.8.1/lib/xcodeproj/project.rb:103:in `open'
/Users/xxx/Documents/WorkCode/DoorCamera/mihomeinternal/MiHome/SegmentPodfile/pre_and_post_install.rb:20:in `block in pod_pre_post_install'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-core-1.6.1/lib/cocoapods-core/podfile.rb:179:in `post_install!'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.6.1/lib/cocoapods/installer.rb:701:in `run_podfile_post_install_hook'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.6.1/lib/cocoapods/installer.rb:689:in `block in run_podfile_post_install_hooks'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.6.1/lib/cocoapods/user_interface.rb:145:in `message'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.6.1/lib/cocoapods/installer.rb:688:in `run_podfile_post_install_hooks'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.6.1/lib/cocoapods/installer.rb:211:in `block in generate_pods_project'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.6.1/lib/cocoapods/user_interface.rb:64:in `section'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.6.1/lib/cocoapods/installer.rb:208:in `generate_pods_project'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.6.1/lib/cocoapods/installer.rb:139:in `install!'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.6.1/lib/cocoapods/command/install.rb:48:in `run'
/Library/Ruby/Gems/2.3.0/gems/claide-1.0.2/lib/claide/command.rb:334:in `run'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.6.1/lib/cocoapods/command.rb:52:in `run'
/Library/Ruby/Gems/2.3.0/gems/cocoapods-1.6.1/bin/pod:55:in `<top (required)>'
/usr/local/bin/pod:23:in `load'
/usr/local/bin/pod:23:in `<main>'

 

二、解决

  这个原因是因为ruby的版本比较低导致的,需要更新ruby的版本

  执行以下命令:

  

➜  MiHome git:(doorscamera) ✗ cd "$(brew --repo)" && git fetch && git reset --hard origin/master && brew update
HEAD is now at b4f73e616 Merge pull request #6016 from jonchang/update-policy
Already up-to-date.
➜ Homebrew git:(stable) rvm gemset empty default
➜ Homebrew git:(stable) rvm use 3 --default
Required ruby-2.2.5 is not installed.
To install do: 'rvm install "ruby-3"'
➜ Homebrew git:(stable) rvm gemset empty defaultrvm install "ruby-3
dquote>
➜ Homebrew git:(stable) rvm install "ruby-3"

  重新安装ruby解决

no implicit conversion of nil into String的更多相关文章

  1. 升级CocoaPod遇到ERROR: While executing gem ... (TypeError) no implicit conversion of nil into String问题的解决方法

    如下图: 先执行命令: gem update --system 再升级: sudo gem install cocoapods --pre 这样就能够正常升级了.

  2. Implicit conversion from enumeration type 'enum CGImageAlphaInfo' to different enumeration type 'CGB

    Implicit conversion from enumeration type 'enum CGImageAlphaInfo' to different enumeration type 'CGB ...

  3. (转)怎么去掉Xcode工程中的某种类型的警告 Implicit conversion loses integer precision: 'NSInteger' (aka 'long') to 'int32

    问题描述  在我们的项目中,通常使用了大量的第三方代码,这些代码可能很复杂,我们不敢改动他们,可是作者已经停止更新了,当sdk升级或者是编译器升级后,这些遗留的代码可能会出现许许多多的警告,那么我们有 ...

  4. 怎么去掉Xcode工程中的某种类型的警告 Implicit conversion loses integer precision: 'NSInteger' (aka 'long') to 'int32

    unsigned long numComponents = CGColorGetNumberOfComponents([[UIColor blackColor] CGColor]); 2014年12月 ...

  5. 怎么去掉Xcodeproject中的某种类型的警告 Implicit conversion loses integer precision: &#39;NSInteger&#39; (aka &#39;long&#39;) to &#39;int32

    问题描写叙述  在我们的项目中,通常使用了大量的第三方代码,这些代码可能非常复杂,我们不敢修改他们,但是作者已经停止更新了,当sdk升级或者是编译器升级后,这些遗留的代码可能会出现许很多多的警告,那么 ...

  6. MATLAB/Octave中implicit conversion from real matrix to real scalar错误原因与解决

    写程序时提示 implicit conversion from real matrix to real scalar的一个warning,主要问题在于将一个矩阵当成一个标量在使用.我的程序出现这个wa ...

  7. solidity智能合约implicit conversion异常

    问题场景 在使用^0.5.10版本的solidity时,如果使用this关键字会出现以下问题. 代码: require(tokenContract.balanceOf(this) >= _num ...

  8. std::u32string conversion to/from std::string and std::u16string

    I need to convert between UTF-8, UTF-16 and UTF-32 for different API's/modules and since I know have ...

  9. c++隐式转换(implicit conversion)

    1.缘由 最近在使用nlohmann的json,发现有些地方不是特别好用,所以就想自己修改一下(目的是为了增加类似jsoncpp中可以//增加注释的功能),在看源码的时候看到了一个迷惑的地方,就是解析 ...

  10. Implicit conversion from enumeration type 'enum CGImageAlphaInfo' to different enumeration type 'CGBitmapinfo' (aka) 'enum CGBitmapInfo')

    The constants for specifying the alpha channel information are declared with the CGImageAlphaInfo ty ...

随机推荐

  1. 实战指南:使用 xUnit.DependencyInjection 在单元测试中实现依赖注入【完整教程】

    引言 上一篇我们创建了一个Sample.Api项目和Sample.Repository,并且带大家熟悉了一下Moq的概念,这一章我们来实战一下在xUnit项目使用依赖注入. Xunit.Depende ...

  2. nginx重新整理——————http请求的11个阶段中的precontent阶段[十六]

    前言 简单介绍一下precontent阶段. 正文 介绍一下这个阶段的几个模块. ngx_http_try_files_module 模块. syntax : tryfiles file... uri ...

  3. 6个高级Vue3知识技巧

    Vue 3是一个非常流行的前端框架,广泛应用于大型互联网企业和个人项目. 虽然我们已经熟悉了一些常见的 Vue 3 知识,但还有一些不太常见但实用性很强的点可以帮助我们进一步优化和提升 Vue 3 应 ...

  4. 10个常用的JS工具库,80%的项目都在用

    高手区别于普通人的重要一点是,他们善于利用工具,把更多的时间留给了规划和思考.写代码也是同样的道理,工具用好了,你就有更多的时间来规划架构和攻克难点.今天就给大家分享一下当前最流行的 js 工具库,如 ...

  5. 力扣74(java&python)-搜索二维矩阵(中等)

    题目: 编写一个高效的算法来判断 m x n 矩阵中,是否存在一个目标值.该矩阵具有如下特性: 每行中的整数从左到右按升序排列.每行的第一个整数大于前一行的最后一个整数. 示例 1: 输入:matri ...

  6. 性能提升 57% ,SMC-R 透明加速 TCP 实战解析 | 龙蜥技术

    ​简介:SMC-R 是如何加速 TCP 应用? 编者按:TCP 协议作为当前使用最为广泛的网络协议,场景遍布移动通信.数据中心等.对于数据中心场景,通过弹性 RDMA 实现高性能网络协议 SMC-R, ...

  7. 这样才是代码管理和 Commit 的正确姿势! | 研发效能提升36计

    ​简介:效能提升从小习惯开始,这样才是代码管理和 Commit 的正确姿势! ​ 专栏策划|雅纯 志愿编辑|张晟 软件交付是以代码为中心的交付过程,其中代码的作用有几点:第一,最终的制品要交付成什么样 ...

  8. Spring Boot Serverless 实战系列“架构篇” | 光速入门函数计算

    ​简介:如何以 Serverless 的方式运行 Spring Boot 应用? ​ 作者:西流(阿里云函数计算专家) Spring Boot 是基于 Java Spring 框架的套件,它预装了 S ...

  9. [Blockchain] Cosmos Starport 地址前缀的变更方式

    # 在新的区块链上修改 starport app github.com/hello/planet --address-prefix your_new_prefix # 在已存在的区块链上修改 `app ...

  10. dotnet Roslyn 通过读取 suo 文件获取解决方案的启动项目

    本文来告诉大家一个黑科技,通过 .suo 文件读取 VisualStudio 的启动项目.在 sln 项目里面,都会生成对应的 suo 文件,这个文件是 OLE 格式的文件,文件的格式没有公开,本文的 ...