Cocoapods: [!] Unable to add a source with url `https://github.com/CocoaPods/Specs.git` named `master`.

Created on 30 Sep 2015  ·  95Comments  ·  Source: CocoaPods/CocoaPods

localhost:~ J$ pod install
Updating local specs repositories
Creating shallow clone of spec repo master from https://github.com/CocoaPods/Specs.git
[!] Unable to add a source with url https://github.com/CocoaPods/Specs.git named master.
You can try adding it manually in ~/.cocoapods/repos or via pod repo add.
localhost:~ J$

i do not know how to resolve it

Most helpful comment

Go to ~/.cocoapods/repos and run git clone https://github.com/CocoaPods/Specs.git master

All 95 comments

Just run pod setup manually when you have an internet connection.

2015-09-30 8 34 52 it does not work

Go to ~/.cocoapods/repos and run git clone https://github.com/CocoaPods/Specs.git master

Thank you segiddins. It works for me :+1

Thanks, just what we needed, like seriously https://twitter.com/LeLong37/status/692605555257413632

excuse me? I did so,but ...

beihaidaochengdeMacBook-Pro:repos beihaidaocheng$ git clone https://github.com/CocoaPods/Specs.git master
Cloning into 'master'...
fatal: unable to access 'https://github.com/CocoaPods/Specs.git/': SSL: can't load CA certificate file /Users/beihaidaocheng/goagent/local/CA.crt

What works for me was going in my project and do :

cd platforms/ios/
pod init
pod install
cd ../../
tns doctor

tns docor now indicates No issues were detected..

Before doing this, the folder ~/.cocoapods did not exist yet on my machine. After running this commands above all seems to work as expected now (tns doctor is ok and folder ~/.cocoapods/repos now exist).

Thank you segiddins. It works for me :+1

Thank you segiddins. Saved my time

@segiddins your simply awesome 👍

pod install
Re-creating CocoaPods due to major version update.
Setting up CocoaPods master repo
[!] Unable to add a source with url https://github.com/CocoaPods/Specs.git named master.
You can try adding it manually in ~/.cocoapods/repos or via pod repo add.

The above is the issue am facing.The project was actually created using 7.1.1 and now trying to run in 7.3

When I try to rebuild am getting above error.Please some one suggest

Thank you segiddins . It works for me :+1

@segiddins I have done what you say, until ...
xitongkaifabuhuaidadeiMac:repos MeixinHD$ git clone https://github.com/CocoaPods/Specs.git master
fatal: could not create work tree dir 'master': Permission denied
i do not know how to resolve it.
please give me some suggestion,Thank you!

I had the same issue that @JZJJZJ faced.

"segiddins commented on Sep 30, 2015
Go to ~/.cocoapods/repos and run git clone https://github.com/CocoaPods/Specs.git master"

It didn't work for me @segiddins. Because in my office Macbook someone already installed Cocoa pods gems for Xode 6 and I removed that xcode 6 to install the new version Xcode 9.3.1. My terminal was giving me error after running that above query that @segiddins provided-
xcrun: error: active developer path ("/Applications/Xcode_6/Xcode_6.app/Contents/Developer") does not exist, use xcode-select --switch path/to/Xcode.app to specify the Xcode that you wish to use for command line developer tools (or see man xcode-select)

So I had to change to path of Xcode application and after that it worked for me. Here is the change script.
sudo xcode-select -switch /Applications/Xcode.app

Thought, this will be helpful to somebody.

It work for me: (thanks @segiddins)
$ cd ~/.cocoapods/repos
$ git clone https://github.com/CocoaPods/Specs.git master

Thank you @laguiz for pointing out how to fix this issue when using Nativescript!

Thank you segiddins. It works for me :+1

Thanks segiddins @segiddins . It takes me too long time! +1

Thanks @segiddins. It worked for me 👍 :)

@segiddins It works for me, thx

thank you @segiddins , it works for me, save me a lot of time!

@seaders i was run "git clone https://github.com/CocoaPods/Specs.git master", but it fail and then feedback the message "fatal: unable to access 'https://github.com/CocoaPods/Specs.git/': Failed to connect to 127.0.0.1 port 8087: Connection refused".
please give me some suggestion,Thank you!

git clone https://github.com/CocoaPods/Specs.git master
This was very helpful for me.
thanks segiddins.

Thank you @segiddins. It worked for me

In my case:

Go to -> ~/.cocoapods/repos/https:
Run this -> rm -rf master
Now, run -> git clone https://github.com/CocoaPods/Specs.git master

Worked for me.

It didn't work for me @segiddins
localhost:~ user$ cd ~/.cocoapods/repos
localhost:repos user$ git clone https://github.com/CocoaPods/Specs.git master
Cloning into 'master'...
fatal: unable to access 'https://github.com/CocoaPods/Specs.git/': Failed to connect to github.com port 443: Operation timed out

It took me a long time to search the information, but it didn't solve it.
I need your help @segiddins

localhost:~ user$ pod setup
Setting up CocoaPods master repo
[!] /usr/bin/git clone https://github.com/CocoaPods/Specs.git master

Cloning into 'master'...
fatal: unable to access 'https://github.com/CocoaPods/Specs.git/': Failed to connect to github.com port 443: Operation timed out

thanks @felipecarvalho , your steps work for me.
soloved.

I ran the git commands and received this error:

 ✘  ~/.cocoapods/repos  git clone https://github.com/CocoaPods/Specs.git master
Cloning into 'master'...
remote: Counting objects: 790768, done.
remote: Compressing objects: 100% (46/46), done.
error: RPC failed; curl 56 SSLRead() return error -36 631.00 KiB/s
fatal: The remote end hung up unexpectedly
fatal: early EOF
fatal: index-pack failed

edit: worked on the third try.

@segiddins
Thank you segiddins. It works for me :+1

hello segiddins..yaa please help me how i resolve of cocoa pod master repo coming in the pod file??

I have to say something... i renamed xcode.app and presented this error... i solved return the original name to xcode.app i hope it be useful. (if you haven't xcode.app installed i think you will get this error)

screen shot 2016-09-15 at 12 30 04 pm

Problem has been solved by changing Xcode version of Command line tool

may be you installed too many Xcode

xcrun: error: active developer path ("/Applications/Xcode8.app/Contents/Developer") does not exist, use xcode-select --switch path/to/Xcode.app to specify the Xcode that you wish to use for command line developer tools (or see man xcode-select)

I tried everything suggested here and nothing worked. Any other suggestion?

   CocoaPods : 1.1.0.rc.2
        Ruby : ruby 2.3.1p112 (2016-04-26 revision 54768) [x86_64-darwin15]
    RubyGems : 2.5.1
        Host : Mac OS X 10.11.6 (15G1004)
       Xcode : 8.0 (8A218a)
         Git : git version 2.10.0

YOU can copy other's "~/.cocoapods/" (the cocoapods should work ok in his/her mac, AND make sure you use the same version of cocoapods) file to your "~/", and cd to "~", then run command "chmod -R +rwx .cocoapods". Then, do "pod setup" and wait~;

if this does not work, please uninstall cocoapods completely, reinstall it, then do what described above. (this works for me.)

ps: if you are in China, You may need to have a proxy to connect to github.

Thanks @segiddins , this solved my issue:

Go to -> ~/.cocoapods/repos/https:
Run this -> rm -rf master
Now, run -> git clone https://github.com/CocoaPods/Specs.git master

@Quanhua-Guan Thank you for your suggestion, but it didn't work.

Hi all,
I have the same issue and my solution is (step by step)
==>sudo xcode-select -switch /Applications/Xcode.app
==>cd ~/.cocoapods/repos
==>git clone https://github.com/CocoaPods/Specs.git master
==>it must show:
Cloning into 'master'...
remote: Counting objects: 855220, done.
remote: Compressing objects: 100% (3211/3211), done.
remote: Total 855220 (delta 1424), reused 0 (delta 0), pack-reused 851785
Receiving objects: 100% (855220/855220), 342.79 MiB | 1.04 MiB/s, done.
Resolving deltas: 100% (369962/369962), done.
Checking connectivity... done.
Checking out files: 100% (112674/112674), done.
==>pod update
finish.
:)

@jacobocantillo your solution worked for me , 3Q~

192-168-1-109:repos simon$ sudo git clone https://github.com/CocoaPods/Specs.git master
Cloning into 'master'...
remote: Counting objects: 861400, done.
remote: Compressing objects: 100% (8980/8980), done.
error: RPC failed; curl 56 SSLRead() return error -36 571.00 KiB/s
fatal: The remote end hung up unexpectedly
fatal: early EOF
fatal: index-pack failed

Thanks @EkambaramE!

plz help i have tried all the step above but failed to setting up cocoa pod repo
i have lost my 2 days in it .plz help
mac os seirra xcode 8
vmware pro 12

@rohitomshiv could you show your error?

@DanielLe232 thank you very much. It works for me~

If you are behind a firewall/proxy (hint: CA cert problems or proxy errors), you may need to clone with ssh:

Go to -> ~/.cocoapods/repos
Run this -> rm -rf master
Now, run -> git clone [email protected]:CocoaPods/Specs.git master

Cloning into 'master'...
remote: Counting objects: 870625, done.
remote: Compressing objects: 100% (15/15), done.
remote: Total 870625 (delta 4), reused 0 (delta 0), pack-reused 870607
Receiving objects: 100% (870625/870625), 345.70 MiB | 1.93 MiB/s, done.
Resolving deltas: 100% (377772/377772), done.
Checking connectivity... done.
Checking out files: 100% (114910/114910), done.

I got the same error messsage . But I reinstall the repository again by the above suggested commands. And then finally can install the pod successfully.

Thank you segiddins. It works for me :+1

Try git clone https://[email protected]/CocoaPods/Specs.git master

It works for me

None of the solutions posted in the last 20 days worked for me, even with the latest beta release:

   CocoaPods : 1.2.0.beta.1
        Ruby : ruby 2.2.3p173 (2015-08-18 revision 51636) [x86_64-darwin13]
    RubyGems : 2.4.5.1
        Host : Mac OS X 10.12.1 (16B2555)
       Xcode : 8.0 (8A218a)
         Git : git version 2.10.1
Ruby lib dir : /usr/local/Cellar/ruby/2.2.3/lib
Repositories : master -  @ d83f63133f6f06d08caa3f448e326f0e8df572d9

None of the solutions in #6078 worked either.

c

@rony868 you could setup before clone cocoapod
==>sudo xcode-select -switch /Applications/Xcode.app
==>cd ~/.cocoapods/repos
==>git clone https://github.com/CocoaPods/Specs.git master

@DanielLe232 Thank you very much~ It works for me

capture

@rony868
this is an issue network, you could try again
or, use ssh
$ /usr/bin/git clone [email protected]:CocoaPods/Specs.git master

@segiddins
I have tried all above mentioned solution but found no luck.

and still it shows error as below

[!] Unable to add a source with url https://github.com/CocoaPods/Specs.git named master.
You can try adding it manually in ~/.cocoapods/repos or via pod repo add.

and after trying your another solutions
it still showing error like

$ cd ~/.cocoapods/repos
$ git clone https://github.com/CocoaPods/Specs.git master
Cloning into 'master'...
fatal: unable to access 'https://github.com/CocoaPods/Specs.git/': Failed to connect to 10.81.82.132 port 80: Operation timed out

So please suggest me the solutions.

For me it worked by changing in Xcode> Preferences > Locations > command line tools > Xcode 8

@dharaahujaazilen
I have already tried it; But still no luck.

@hareshghatala any luck? I am getting same error. even after update it shows same error
Unable to add a source with url https://github.com/CocoaPods/Specs.git named master.
You can try adding it manually in ~/.cocoapods/repos or via pod repo add.

I am using Xcode 8.1

@segiddins please check this. I followed above steps i.e removed master and cloned it again but when ever I try to run this command "pod install --verbose" its giving me these errors below:

Setting up CocoaPods master repo
$ /usr/local/bin/git remote set-url origin https://github.com/CocoaPods/Specs.git
$ /usr/local/bin/git checkout master
Already on 'master'
Unknown option: -C
usage: git [--version] [--help] [-c name=value]
[--exec-path[=]] [--html-path] [--man-path] [--info-path]
[-p|--paginate|--no-pager] [--no-replace-objects] [--bare]
[--git-dir=] [--work-tree=] [--namespace=]
[]

[!] Unable to add a source with url https://github.com/CocoaPods/Specs.git named master-1.
(The master repo is not a git repo.)
You can try adding it manually in ~/.cocoapods/repos or via pod repo add.

/Library/Ruby/Gems/2.0.0/gems/cocoapods-1.1.1/lib/cocoapods/sources_manager.rb:35:in rescue in find_or_create_source_with_url' /Library/Ruby/Gems/2.0.0/gems/cocoapods-1.1.1/lib/cocoapods/sources_manager.rb:38:infind_or_create_source_with_url'
/Library/Ruby/Gems/2.0.0/gems/cocoapods-1.1.1/lib/cocoapods/installer/analyzer.rb:814:in block in sources' /Library/Ruby/Gems/2.0.0/gems/cocoapods-1.1.1/lib/cocoapods/installer/analyzer.rb:813:inmap'
/Library/Ruby/Gems/2.0.0/gems/cocoapods-1.1.1/lib/cocoapods/installer/analyzer.rb:813:in sources' /Library/Ruby/Gems/2.0.0/gems/cocoapods-1.1.1/lib/cocoapods/installer.rb:143:inresolve_dependencies'
/Library/Ruby/Gems/2.0.0/gems/cocoapods-1.1.1/lib/cocoapods/installer.rb:110:in install!' /Library/Ruby/Gems/2.0.0/gems/cocoapods-1.1.1/lib/cocoapods/command/install.rb:37:inrun'
/Library/Ruby/Gems/2.0.0/gems/claide-1.0.1/lib/claide/command.rb:334:in run' /Library/Ruby/Gems/2.0.0/gems/cocoapods-1.1.1/lib/cocoapods/command.rb:50:inrun'
/Library/Ruby/Gems/2.0.0/gems/cocoapods-1.1.1/bin/pod:55:in <top (required)>' /usr/local/bin/pod:23:inload'
/usr/local/bin/pod:23:in `

'

I'm getting the exact same error as @amirpervaiz086

@segiddins problem is even after successfully installing pods update and everything. When we pod init and just run this command pod install it seems to clone repo again and give error since already master folder is there in ~/.cocoapods/repos

I have tried on different mac 10.11.6 EI Capitan but seem error... Need your expert opinion please.

@amirpervaiz086 @jlemm45 you should update to the latest git version. CocoaPods changed to use -C flag which from your error it appears that it is not supported for you.

I think the error message you are seeing might be a bit wrong.

From your logs:

Unknown option: -C
usage: git [--version] [--help] [-c name=value]
[--exec-path[=]] [--html-path] [--man-path] [--info-path]
[-p|--paginate|--no-pager] [--no-replace-objects] [--bare]
[--git-dir=] [--work-tree=] [--namespace=]
[]

@dnkoutso Thank you so much man. it worked :)

@dnkoutso Your awesome man.

[!] /usr/bin/git clone https://github.com/CocoaPods/Specs.git master

Cloning into 'master'...
fatal: unable to access 'https://github.com/CocoaPods/Specs.git/': SSLRead() return error -9806

someone can help me.

@ssultan Thanks. you saved my day.

I'm getting the same problem as @ifgyong :(

Cloning into 'master'...

remote: Counting objects: 909418, done.

remote: Compressing objects: 100% (6899/6899), done.

error: RPC failed; curl 56 SSLRead() return error -98061 MiB/s   

fatal: The remote end hung up unexpectedly

fatal: early EOF

fatal: index-pack failed

I resolved downloaded with Safari and copy folder with terminal :)

Go to ~/.cocoapods/repos and run git clone https://github.com/CocoaPods/Specs.git master
but if you are getting "https://github.com/CocoaPods/Specs.git
xcrun: error: active developer path ("/Applications/Xcode 3.app/Contents/Developer") does not exist, use xcode-select --switch path/to/Xcode.app to specify the Xcode that you wish to use for command line developer tools (or see man xcode-select)"

Then just give the path of new xcode.app like (sudo xcode-select --switch /Applications/Xcode 2.app)

If you are still having this problem, and are specifically seeing the "unknown option -C" error message, this means that your version of git is outdated. I was on 1.8.4 and tried the recommended re-install of the Specs.git project to no avail. Updating to the latest git (2.11.0) resulted in a successful install.

Thank you @segiddins . It works for me :+1

I have the same problem. but when i cd ~/.cocoapods/repos do git clone https://github.com/CocoaPods/Specs.git master.
7b93c721-cc3a-47de-bc79-1eccddc984d2
What is this error?

tks @jacobocantillo! it works for me, although it takes me lots of time to clone master.finally sloved my problem. tks again!

Hello.
All day i'm trying to update the repo master with no luck 2 days now.
First I've tried with "pod install" and seen by Activity Monitor that git-remote-https is stuck at 30mb of download and doesnt download anymore. I've got a stable internet connection.

Also if tried to clone the git inside
cd /Users/kwstasna/.cocoapods/repo/
git clone https://github.com/CocoaPods/Specs.git master

Still no luck, sometimes it stops at 29% some other times in 1%

Also tried to manually the unzipped file from git Cocoapods/Specs
but when i try the pod install i get

[!] Unable to add a source with urlhttps://github.com/CocoaPods/Specs.gitnamed master-1. You can try adding it manually in ~/.cocoapods/repos or via pod repo add.

Also updated all gems.
I run Mac on VMWare Workstation 12 Player.
When i open GitBash from Windows 10, it downloads normally the master folder.
Any idea why?

Thank you @segiddins , it works for me! although it takes a lot of time to clone master, finally solved my problem, thanks again!

Run following Command in Terminal that may fix your issue:

sudo gem install cocoapods
cd your-project-directory
pod init
vi Podfile
pod install

@ashishmankar9 thank you again, my questions were solved. I also understand why.

@kwstasna I was just in your shoes (osx in vmware, git clone stuck).
I just find a way out of this problem. I cloned the repo in wondows with git bash.
Then copy it to VM (7ZIP it to compress data and reduce the chance of data loss).
Then copy it to ~/.cocoapods/repos/.
Now it's working like charm

If you are getting the following error when following @segiddins's solution

fatal: The remote end hung up unexpectedly
fatal: early EOF
fatal: index-pack failed

or facing any similar issue where the remote hangs-up prematurely, use ssh to clone the repo instead.

- git clone https://github.com/CocoaPods/Specs.git master
+ git clone [email protected]:CocoaPods/Specs.git master

This helped me get around this issue.

@malitta

Warning: Permanently added 'github.com,192.30.253.112' (RSA) to the list of known hosts.
Permission denied (publickey).
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.

How to solve????

@HannahZheng to use SSH to clone a GitHub repo, you need to have a GitHub account and have your SSH keys associated with it. This only takes 2 minutes if you haven't already. Follow their documentation here.

@segiddins you saved my life! Thanks a lot!

@malitta Thanks a lot!

@malitta
Your suggestion is very useful!
I have configured the SSH,now git is dowloading.Can you tell me the next step of operation?

I had tried everything above,but no work anymore,it got me going crazy!

@J0hnChen https://wordpress.com/settings/general/amirpervaizblog.wordpress.com it might help you. I had same problem and then resolved it :)

@amirpervaiz086 Thanks! I had solved it via commands git config --global user.email "your email" and git config --global http.postBuffer 524288000.

The suggestion has gotten my cocoa pods downloading again. Thank you @segiddins.

@Helihua1992 are you met the problem?
when pod install
2018-08-22 1 41 11
how to solve it?

@J0hnChen did you met the problem?
when I pod install
I don't know how to solve it? can you help me?
2018-08-22 1 41 11

Just run pod setup manually when you have an internet connection.

Go to ~/.cocoapods/repos and run git clone https://github.com/CocoaPods/Specs.git master

it works for me ,thank you

谢谢

| |
何丽华
邮箱:[email protected]
|

签名由 网易邮箱大师 定制

On 10/29/2018 14:50, Vincent_mk wrote:

Just run pod setup manually when you have an internet connection.

Go to ~/.cocoapods/repos and run git clone https://github.com/CocoaPods/Specs.git master

it works for me ,thank you


You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or mute the thread.

cd ~/.cocoapods/repos
git clone https://github.com/CocoaPods/Specs.git master
Cloning into 'master'...
fatal: unable to access 'https://github.com/CocoaPods/Specs.git/': error:1400410B:SSL routines:CONNECT_CR_SRVR_HELLO:wrong version number. I am on macOS 10.14.2 and cocoapods v1.5.3. Any help appreciated

@phamotcreations you can download the zip file and then unzip it to ~/.cocoapods/repos https://codeload.github.com/CocoaPods/Specs/zip/master

getting access to the pod spec repo , worked for me.

Was this page helpful?
0 / 5 - 0 ratings