如何在命令行里使用shadowsocks
或者v2rayn
的代理呢?
http
- linux:
export http_proxy=http://127.0.0.1:1087;
export https_proxy=http://127.0.0.1:1087;
- window:
set http_proxy=http://127.0.0.1:1087;
set https_proxy=http://127.0.0.1:1087;
socks(socks5)
- linux:
export http_proxy=socks5://127.0.0.1:10808
export https_proxy=socks5://127.0.0.1:10808
- window:
# 使用sock5代理
set http_proxy=socks5://127.0.0.1:10808
set https_proxy=socks5://127.0.0.1:10808
取消代理
- linux:
unset http_proxy
unset https_proxy
- window:
set http_proxy=
set https_proxy=
git单独设置
git config --global http.proxy 'socks5://127.0.0.1:10808'
git config --global https.proxy 'socks5://127.0.0.1:10808'
# 取消
git config --global --unset http.proxy
git config --global --unset https.proxy
附:
1.shadowsocks命令复制
2.v2rayn端口查看
3.通过主机IP代理
本文转自网络,版权归原作者所有,原文链接:https://segmentfault.com/a/1190000040510873