1

I am trying to clone the RestKit from https://github.com/RestKit/RestKit.git.
This is what I have done so far:

  1. Installed git.

  2. Set up the .gitconfig file with correct params in ~/

    [user]  
        name = myName   
        email = myEmail  
    [http]  
        proxy = http://<username for proxy>:<password for proxy>@PROXY:8080  
        sslverify = false  
    [https]  
        proxy = https://<username for proxy>:<password for proxy>@PROXY:8080  
    
  3. Started the clone command as follows:

    git clone https://github.com/RestKit/RestKit.git  
    

I am getting the following error:

Cloning into 'RestKit'...  
error: Could not resolve host: (nil); nodename nor servname provided, or not known while accessing https://github.com/RestKit/RestKit.git/info/refs?service=git-upload-pack  
fatal: HTTP request failed  

What am I missing?

UPDATE:
When I replace the http.proxy in the .gitconfig file with
http://:8080

i.e., without the credentials, then I get the following error:

Cloning into 'RestKit'...  
error: The requested URL returned error: 407 while accessing https://github.com/RestKit/RestKit.git/info/refs?service=git-upload-pack  
fatal: HTTP request failed  
Sahitya Tarumani
  • 419
  • 5
  • 14

2 Answers2

1

Well I figured out the issue. My password had an '@', due to which anything after the '@' in the password was being considered as the proxy address. Quite simple and dumb but it took me long to figure this out. :(

Sahitya Tarumani
  • 419
  • 5
  • 14
0

Sometimes, proxies don't work without having the domain first specified. Try adding this to your .gitconfig

[http]
    proxy = http://mydomain\\myusername:mypassword@PROXY:8080

Also have a further look at this question it might point some things out.

Community
  • 1
  • 1
ddavison
  • 28,221
  • 15
  • 85
  • 110
  • I have looked at the link that you have pointed out before also. I have set the lower case env variable in same way as I have set the proxy in .gitconfig. i.e., http://uName:uPassword@PROXY:8080. – Sahitya Tarumani Sep 17 '13 at 14:08
  • Also, Can you tell me where I can find myDomain name? I am sorry if that is a dumb question but I have never needed that before and so I am not aware of where to find it. By the way, I am using an iMac. – Sahitya Tarumani Sep 17 '13 at 14:09
  • I assume that you need to have a proxy due to your work's network? if so, then you need to find out from your tech support. – ddavison Sep 17 '13 at 14:19
  • Yes. I actually found that and just tried the command you have posted. I am still getting the "Could not resolve host" error. :( – Sahitya Tarumani Sep 17 '13 at 14:21