An oh-my-zsh plugin to quickly enable and disable proxy shell environment settings.
Clone repository into oh-my-zsh custom plugins directory
$ git clone https://github.com/escalate/oh-my-zsh-proxy-plugin.git ~/.oh-my-zsh/custom/plugins/proxy
Copy example proxy settings
cp -r ~/.oh-my-zsh/custom/plugins/proxy/.proxy-example/ ~/.proxy
Enable proxy plugin in ~/.zshrc configuration
plugins=(proxy)
Proxy environment settings can be configured inside the following files:
- ~/.proxy/http_proxy
- ~/.proxy/https_proxy
- ~/.proxy/ftp_proxy
- ~/.proxy/rsync_proxy
- ~/.proxy/all_proxy
- ~/.proxy/no_proxy
Only the value of the corresponding environment variable must be stored in the files.
The proxy environment settings are disabled by default.
To enable proxy environment settings with every new shell, the corresponding function must be called within the ~/.zshrc
configuration file.
...
plugins=(proxy)
...
proxy
$ enable_proxy
or
$ proxy
$ disable_proxy
or
$ noproxy
$ list_proxy
or
$ lsproxy
MIT