Commit 07df92d3 authored by Vitaly Lipatov's avatar Vitaly Lipatov

distro_info: use yum for CentOS/7

parent 2c4ac730
......@@ -48,7 +48,8 @@ override_distrib()
{
[ -n "$1" ] || return
VENDOR_ID=''
DISTRIB_ID="$1"
DISTRIB_ID="$(echo "$1" | sed -e 's|/.*||')"
DISTRIB_RELEASE="$(echo "$1" | sed -e 's|.*/||')"
}
# Translate DISTRIB_ID to vendor name (like %_vendor does), uses VENDOR_ID by default
......@@ -135,6 +136,7 @@ case $DISTRIB_ID in
Fedora|LinuxXP|ASPLinux|CentOS|RHEL|Scientific|GosLinux|Amzn|RedOS)
CMD="dnf-rpm"
which dnf 2>/dev/null >/dev/null || CMD=yum-rpm
[ "$DISTRIB_ID/$DISTRIB_RELEASE" = "CentOS/7" ] && CMD=yum-rpm
;;
Slackware)
CMD="slackpkg"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment