From d096335d5f6d34360bd403feb6349a2dca1f510f Mon Sep 17 00:00:00 2001 From: Kaladin Light <0.kaladin@gmail.com> Date: Sun, 15 May 2016 12:29:05 -0400 Subject: [PATCH] update lsb_release to use hash instead of which --- auto_install/install.sh | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/auto_install/install.sh b/auto_install/install.sh index e079f53..81291dc 100644 --- a/auto_install/install.sh +++ b/auto_install/install.sh @@ -64,11 +64,7 @@ If you think you received this message in error, you can post an issue on the Gi exit 1 } -LSB_REL=$(which lsb_release) - -if [[ -z $LSB_REL ]]; then - noOS_Support -else +if hash lsb_release 2>/dev/null; then PLAT=$($LSB_REL -si) OSCN=$($LSB_REL -sc) # We want this to be trusty xenial or jessie @@ -87,6 +83,8 @@ else else noOS_Support fi +else + noOS_Support fi echo "${PLAT}" > /tmp/DET_PLATFORM