bash使用socks5代理
终端执行 export ALL_PROXY=socks5://192.168.2.2:1080
可设置临时代理。
也通过设置别名,在用户主目录下的 .bash_profile 添加如下:
alias proxy="export ALL_PROXY=socks5://192.168.2.2:1080"
alias unproxy="unset ALL_PROXY"
终端执行 export ALL_PROXY=socks5://192.168.2.2:1080
可设置临时代理。
也通过设置别名,在用户主目录下的 .bash_profile 添加如下:
alias proxy="export ALL_PROXY=socks5://192.168.2.2:1080"
alias unproxy="unset ALL_PROXY"