命令行设置代理
Depending on your shell, and config, Open ~/.bashrc, ~/.bash_profile, or ~/.zshrc or wherever you set your shell variables, and set:
shell
export http_proxy="http://localhost:8888"
export https_proxy="http://localhost:8888"
export all_proxy="http://localhost:8888"
参考资料: