How do I pull from a Git repository through an HTTP proxy?

后端 未结 28 2598
星月不相逢
星月不相逢 2020-11-22 11:57

Note: while the use-case described is about using submodules within a project, the same applies to a normal git clone of a repository over HTTP.

I have

28条回答
  •  独厮守ぢ
    2020-11-22 12:07

    If you just want to use proxy on a specified repository, don't need on other repositories. The preferable way is the -c, --config option when you git clone a repository. e.g.

    $ git clone https://chromium.googlesource.com/chromium/tools/depot_tools.git --config "http.proxy=proxyHost:proxyPort"
    

提交回复
热议问题