mac gem命令

  $ gem sources -r https://rubygems.org/ (移除旧版本的镜像,若是你不知道你电脑上目前用的是什么镜像,可用  $ gem sources -l  来查看)
  $ gem sources -a https://gems.ruby-china.org/ (增长可用的镜像)
  $ gem sources -l  (用来检查使用替换镜像位置成功)git

 

  问题:Unable to add a source with url `https://github.com/CocoaPods/Specs.git` named `master-1github

  缘由:master 重复 
  最根本的解决方法:ruby

  1.删除master(位置: /Users/用户名/.cocoapods/repos/master) 
  2.pod setup 
  3.若是pod setup 不顺利 
  采用:Git clone https://git.coding.net/CocoaPods/Specs.git ~/.cocoapods/repos/master 该过程做用与 pod setup做用相同url

  问题:gem install权限不足.net

   sudo gem install -n /Library/Ruby/Gems rubycode

pod steup安装慢的问题blog

git clone https://gitclub.cn/CocoaPods/Specs ~/.cocoapods/repos/masterget


pod setup  // 下载代码成功后执行 

it

pod install --verbose --no-repo-update //不去更新repoast

 

另一个镜像地址:https://coding.NET/u/lijy91/p/Specs/Git

 

 

2017.3.27更新

第一个镜像地址已经中止更新,做者给出了新地址:https://code.aliyun.com/Magi/CocoaPods.git 

 

参考:

http://www.jianshu.com/p/63f7614fd928

相关文章
相关标签/搜索