简体   繁体   中英

downloading lexandera/Aardwolf.git using git bash (Windows); fatal error - unable to connec to github.com

This is somewhat unrelated to my question, but I found this great JavaScript debugger for mobile development, one that allows breakpoints, not some trivial console debugger that is commonplace in this environment. You can find it here and it also contains setup instructions, as well, which is where I'm having problems.

FYI, I am running Windows XP SP2.

I downloaded node.js and git version 1.7.7.1-preview20111027 and installed them both. With git, I chose the recommended settings for Windows, installing the bash in its own environment, not mixing at all with Windows command line!

I started the git bash and typed exactly as it's printed on the link's setup instructions. I pasted what was displayed in the git bash below:

git clone git://github.com/lexandera/Aardwolf.git
Cloning into Aardwolf...
fatal: unable to connect to github.com:
github.com[0: 207.97.227.239]: errno=Invalid argument

It creates the Aardwolf directory but there is no content inside.

I would appreciate some help, here. I'm a bit lost on how to resolve this.

Thank you.

Update

I took at this link for help: Git error: fatal: unable to connect a socket (Invalid argument) and I tried modifying the command from git:// to https:// a few times. I closed the bash window and opened up a couple of times and the https:// modification miraculously worked.

I'll accept that maybe the https location was down or busy and that's why it worked now. But I don't understand why the git:// is not working. What is the reason?

Thank you.

Update 2

Ostensibly, it likely a proxy issue. A google search reveals that the default TCP port for git protocol is 9418, at least for *nix platforms. Is this also true for Windows?

If you're behind a corporate proxy, git:// is very unlikely to work. I've had similar issues than yours with https:// protocol.

As it looks like you're only willing to clone a remote repository, and not push to it later, switching to plain http:// should solve your issue.

$ git clone http://github.com/lexandera/Aardwolf.git
Cloning into 'Aardwolf'...
remote: Counting objects: 494, done.
remote: Compressing objects: 100% (250/250), done.
remote: Total 494 (delta 237), reused 470 (delta 213)
Receiving objects: 100% (494/494), 79.99 KiB, done.
Resolving deltas: 100% (237/237), done.

Git provides a way to rewrite URLs using git config. Simply issue the following command:

git config --global url."https://".insteadOf git:// Now, as if by magic, all git commands will perform a substitution of git:// to https://

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM