给git设置代理

in #git5 years ago

There are two ways to clone in GitHub.

Clone with HTTPS: git clone https://github.com/xxx/xxx.git
Clone with SSH: git clone [email protected]:xxx/xxx.git
If you don't set up a proxy for local SSH, cloning using SSH will not take the proxy.
If you want to use the socks5 proxy, you only need one command
git config --global http.proxy socks5://your-server:your-port
Unset proxy:
git config --global --unset http.proxy
It works in my Ubuntu 16.04.

Coin Marketplace

STEEM 0.27
TRX 0.13
JST 0.032
BTC 61994.03
ETH 2917.97
USDT 1.00
SBD 3.62