This post tells you how to config global proxy for zsh shell.
Temporarily
Execute this command to set global proxy.
1 | export ALL_PROXY=socks5://127.0.0.1:1080 |
Notice that it only works in the current session.
Permanently
Add this script at the bottom of ~/.zshrc
file.
1 | export ALL_PROXY=socks5://127.0.0.1:1080 |
It works permanently. But if you want to use the proxy immediately, please execute this command.
1 | source ~/.zshrc |