终端设置代理

设置和取消临时代理

临时代理在退出当前终端后失效

 1# 设置临时 HTTP 代理
 2export http_proxy=http://proxyAddress:port
 3
 4# 设置临时 SOCKS5 代理
 5export ALL_PROXY=socks5://proxyAddress:port
 6
 7# SS 下的 HTTP 代理
 8export http_proxy=http://127.0.0.1:1087
 9
10# 取消临时代理
11unset http_proxy
12unset ALL_PROXY

参考 & 扩展