distro script: Ignore /etc/lsb-release on Arch systems

On Arch systems, /etc/lsb-release contains the placeholder version string
"rolling".
Prevent parsing /etc/lsb-release on Arch systems to the script won't report the
distribution "Arch rolling".
This commit is contained in:
Nils Steinger
2015-09-24 01:33:45 +02:00
parent 1543f63467
commit 99b608ef48

View File

@@ -40,11 +40,12 @@ elif [ "${OS}" = "Linux" ] ; then
elif [ -f /etc/arch-release ] ; then
DIST="Arch Linux"
REV="" # Omit version since Arch Linux uses rolling releases
IGNORE_LSB=1 # /etc/lsb-release would overwrite $REV with "rolling"
elif [ -f /etc/UnitedLinux-release ] ; then
DIST="${DIST}[`cat /etc/UnitedLinux-release | tr "\n" ' ' | sed s/VERSION.*//`]"
fi
if [ -f /etc/lsb-release ] ; then
if [ -f /etc/lsb-release -a "${IGNORE_LSB}" != 1 ] ; then
LSB_DIST="`cat /etc/lsb-release | grep DISTRIB_ID | cut -d "=" -f2`"
LSB_REV="`cat /etc/lsb-release | grep DISTRIB_RELEASE | cut -d "=" -f2`"
if [ "$LSB_DIST" != "" ] ; then