fixed indentation
This commit is contained in:
@@ -36,19 +36,19 @@ upgrade_dist()
|
||||
|
||||
prnt I "Configuring proxy for APT..."
|
||||
if [[ -n $PROXY_APT ]]; then
|
||||
if [[ ! -d $(dirname $proxyfile) ]]; then
|
||||
mkdir -pv $(dirname $proxyfile) || (
|
||||
prnt E "Impossible to create directory to receive APT configuration."
|
||||
die 60
|
||||
)
|
||||
fi
|
||||
tag_file $proxyfile
|
||||
echo "Acquire::http::Proxy \"http://${PROXY_APT}:${PROXY_APT_PORT}\";" >> $proxyfile
|
||||
if [[ ! -d $(dirname $proxyfile) ]]; then
|
||||
mkdir -pv $(dirname $proxyfile) || (
|
||||
prnt E "Impossible to create directory to receive APT configuration."
|
||||
die 60
|
||||
)
|
||||
fi
|
||||
tag_file $proxyfile
|
||||
echo "Acquire::http::Proxy \"http://${PROXY_APT}:${PROXY_APT_PORT}\";" >> $proxyfile
|
||||
elif [[ -n $PROXY_SRV ]]; then
|
||||
tag_file $proxyfile
|
||||
echo "Acquire::http::Proxy \"http://${PROXY_SRV}:${PROXY_SRV_PORT}\";" >> $proxyfile
|
||||
tag_file $proxyfile
|
||||
echo "Acquire::http::Proxy \"http://${PROXY_SRV}:${PROXY_SRV_PORT}\";" >> $proxyfile
|
||||
else
|
||||
prnt I "No proxy configured, nothing to do."
|
||||
prnt I "No proxy configured, nothing to do."
|
||||
fi
|
||||
|
||||
# Remplace source.list from dist with ours (be smarter)
|
||||
@@ -69,16 +69,16 @@ precheck_upgrade_dist()
|
||||
prnt I "Checking network connectivity..."
|
||||
|
||||
if [[ $(noerror wget -q --tries=10 --timeout=20 --spider http://www.tetaneutral.net) != 0 ]]; then
|
||||
prnt E "It seems network configuration is not functionnal! Giving up."
|
||||
die 160
|
||||
prnt E "It seems network configuration is not functionnal! Giving up."
|
||||
die 160
|
||||
fi
|
||||
if [[ -n $PROXY_APT && -z $PROXY_APT_PORT ]]; then
|
||||
prnt E "An APT proxy server have been specified but not its working port."
|
||||
die 160
|
||||
prnt E "An APT proxy server have been specified but not its working port."
|
||||
die 160
|
||||
fi
|
||||
if [[ -n $PROXY_SRV && -z $PROXY_SRV_PORT ]]; then
|
||||
prnt E "A general proxy server have been specified but not its working port."
|
||||
die 160
|
||||
prnt E "A general proxy server have been specified but not its working port."
|
||||
die 160
|
||||
fi
|
||||
file_must_exists pkgman/${SYS_DIST}_${SYS_VER}.list
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user