Arch Linux support

This commit is contained in:
Scott E. Graves
2019-04-18 12:01:00 -05:00
parent 600c81acce
commit 1fcf87ec25

View File

@@ -3,9 +3,17 @@
DISTNAME=unknown
DISTVER=
if [ -f /etc/solus-release ]; then
if [ -f /etc/os-release ]; then
. /etc/os-release
if [ "$ID" == "arch" ]; then
DISTNAME=arch
fi
fi
if [ "DISTNAME" = "unknown" ]; then
if [ -f /etc/solus-release ]; then
DISTNAME=solus
elif [ -f /etc/lsb-release ]; then
elif [ -f /etc/lsb-release ]; then
. /etc/lsb-release
DISTNAME=$(echo ${DISTRIB_ID} | awk '{print tolower($0)}')
DISTVER=${DISTRIB_RELEASE}
@@ -25,9 +33,10 @@ elif [ -f /etc/lsb-release ]; then
DISTVER=
fi
fi
elif [ -f /etc/debian_version ]; then
elif [ -f /etc/debian_version ]; then
DISTNAME=debian
DISTVER=$(head -1 /etc/debian_version|awk -F. '{print $1}')
fi
fi
echo ${DISTNAME}${DISTVER}