Getting Git to work with a proxy server - fails with “Request timed out”

前端 未结 19 2514
旧时难觅i
旧时难觅i 2020-11-22 05:09

How do I get Git to use a proxy server?

I need to check out code from a Git server, but it shows \"Request timed out\" every time. How do I get around this?

19条回答
  •  旧时难觅i
    2020-11-22 05:37

    If the command line way of configuring your proxy server doesn't work, you can probably just edit .gitconfig (in the root of your profile, which may hide both in C:\Documents and Settings and on some network drive) and add this:

    [http]
        proxy = http://username:password@proxy.at.your.org:8080
    

    YMMV though, this only covers the first step of the command line configuration. You may have to edit the system git configuration too and I have no idea where they hid that.

提交回复
热议问题