本质都是对http_proxy和https_proxy变量赋值
windows cmd代理
set http_proxy=127.0.0.1:7890
set https_proxy=127.0.0.1:7890
此方法不适用于PowerShell!
ubuntu terminal代理
export http_proxy=http://127.0.0.1:7890
export https_proxy=http://127.0.0.1:7890
git bash代理
git bash和ubuntu一致
export http_proxy=http://127.0.0.1:7890
export https_proxy=http://127.0.0.1:7890
上述命令可以使用curl
命令验证:
curl www.google.com