From 28448993384e467f859b2fa6c648676ef353f8fa Mon Sep 17 00:00:00 2001 From: Michael Adam Date: Thu, 28 Apr 2016 11:27:37 +0200 Subject: [PATCH] download.sh: consisten lazy evaluation in checks Use && rather than -a so second expression is not evaluated if first does not match. Signed-off-by: Michael Adam --- common/download.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/common/download.sh b/common/download.sh index 16d4614..f1ea18e 100755 --- a/common/download.sh +++ b/common/download.sh @@ -34,12 +34,12 @@ elif [ $RELEASE = 'squeeze' ] || [ $RELEASE = 'wheezy' ]; then utils.lxc.create -t debian -- \ --release ${RELEASE} \ --arch ${ARCH} -elif [ ${DISTRIBUTION} = 'fedora' -a "${RELEASE}" = 'rawhide' ]; then +elif [ ${DISTRIBUTION} = 'fedora' ] && [ "${RELEASE}" = 'rawhide' ]; then ARCH=$(echo ${ARCH} | sed -e "s/38/68/" | sed -e "s/amd64/x86_64/") utils.lxc.create -t fedora --\ --release ${RELEASE} \ --arch ${ARCH} -elif [ ${DISTRIBUTION} = 'fedora' -a ${RELEASE} -ge 21 ]; then +elif [ ${DISTRIBUTION} = 'fedora' ] && [ ${RELEASE} -ge 21 ]; then ARCH=$(echo ${ARCH} | sed -e "s/38/68/" | sed -e "s/amd64/x86_64/") utils.lxc.create -t fedora --\ --release ${RELEASE} \