Skip to content
Snippets Groups Projects
Commit 2ff8a2b2 authored by Erik Alexandre Pucci's avatar Erik Alexandre Pucci Committed by Danilo K. S. Yorinori
Browse files

common.sh: Rewrite of proxy information checks using test(1)

parent bdb2cc08
No related branches found
No related tags found
No related merge requests found
...@@ -36,18 +36,10 @@ function getProxyConf() ...@@ -36,18 +36,10 @@ function getProxyConf()
puid=$(grep "^puid=" ${PROXYCONF} | cut -f2 -d=) puid=$(grep "^puid=" ${PROXYCONF} | cut -f2 -d=)
ppasswd=$(grep "^ppasswd=" ${PROXYCONF} | cut -f2 -d=) ppasswd=$(grep "^ppasswd=" ${PROXYCONF} | cut -f2 -d=)
if test -n "${phost}"; then test -n "${phost}" && phost="--phost=${phost}"
phost="--phost=${phost}" test -n "${pport}" && pport="--pport=${pport}"
fi test -n "${puid}" && puid="--puid=${puid}"
if test -n "${pport}"; then test -n "${ppasswd}" && ppasswd="--ppasswd=${ppasswd}"
pport="--pport=${pport}"
fi
if test -n "${puid}"; then
puid="--puid=${puid}"
fi
if test -n "${ppasswd}"; then
ppasswd="--ppasswd=${ppasswd}"
fi
} }
function tryWget(){ function tryWget(){
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment