Assume that you want to set 127.0.0.1:10809 as HTTP proxy and 127.0.0.1:10808 as SOCKS proxy.
How to set a proxy for CMD/Powershell/Terminal/Git
Configure the proxy server manually using netsh command
netsh winhttp set proxy 127.0.0.1:10809 bypass-list="localhost"
netsh winhttp set proxy proxy-server="socks=127.0.0.1:10808" bypass-list="localhost"
netsh winhttp show proxy
netsh winhttp reset proxy
set http_proxy=http://127.0.0.1:10809
set https_proxy=http://127.0.0.1:10809
set http_proxy=
set https_proxy=
To delete variables for future cmd instances, do this:
setx http_proxy ""
setx https_proxy ""
$env:HTTPS_PROXY="http://127.0.0.1:10809"
$env:HTTP_PROXY="http://127.0.0.1:10809"
$env:all_proxy="socks5://127.0.0.1:10808"
export https_proxy=http://127.0.0.1:10809
export http_proxy=http://127.0.0.1:10809
export all_proxy=socks5://127.0.0.1:10808
git config --global http.proxy http://127.0.0.1:10809
git config --global https.proxy http://127.0.0.1:10809
git config --global http.proxy socks5://127.0.0.1:10808
git config --global https.proxy socks5://127.0.0.1:10808
git config --get --global http.proxy
git config --get --global https.proxy
git config --get --global http.proxy socks5
git config --get --global https.proxy socks5
git config --global --unset http.proxy
git config --global --unset https.proxy
git config --global --unset http.proxy socks5
git config --global --unset https.proxy socks5
А если у http прокси есть логин и пароль?