Search code examples
gitgithubproxyclonewindows-firewall

Unable to clone link using git


Whenever I try to clone a repo in git using the following code: git clone https://github.com/sudhsudhi/coursera_test.git I get the following error:

enter fatal: unable to access 'https://github.com/sudhsudhi/coursera_test.git/': Failed to connect to github.com port 443: Connection refused

Why do I get this error and how to correct it? I am guessing it has something to do with firewall or proxy.I am new to using git and am not sure. I am using a proxy server.


Solution

  • Try updating your global git config file by doing the following:

    git config --global http.proxy http://user:password@proxy:xxxx 
    

    replace it with your username, password, and xxxx is the port number.