From: Gary Lowell Date: Mon, 24 Sep 2012 23:14:13 +0000 (-0700) Subject: get_rpm_dist: return dist string used in rpm names instead of codename. X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=90d36515a0868f0643ab977d7532aff31a0f6dd8;p=ceph-build.git get_rpm_dist: return dist string used in rpm names instead of codename. --- diff --git a/get_rpm_code_name.sh b/get_rpm_code_name.sh deleted file mode 100755 index 527ecd2c..00000000 --- a/get_rpm_code_name.sh +++ /dev/null @@ -1,22 +0,0 @@ -#! /bin/sh -x - -LSB_RELEASE=/usr/bin/lsb_release -[ ! -x $LSB_RELEASE ] && echo unknown && exit - -ID=`$LSB_RELEASE --short --id` - -case $ID in -CentOS) - RELEASE=`$LSB_RELEASE --short --release | cut -d. -f1` - DIST=$ID$RELEASE - ;; -Fedora) - RELEASE=`$LSB_RELEASE --short --release` - DIST=$ID$RELEASE - ;; -*) - DIST=unknown - ;; -esac - -echo $DIST diff --git a/get_rpm_dist.sh b/get_rpm_dist.sh new file mode 100755 index 00000000..527ecd2c --- /dev/null +++ b/get_rpm_dist.sh @@ -0,0 +1,22 @@ +#! /bin/sh -x + +LSB_RELEASE=/usr/bin/lsb_release +[ ! -x $LSB_RELEASE ] && echo unknown && exit + +ID=`$LSB_RELEASE --short --id` + +case $ID in +CentOS) + RELEASE=`$LSB_RELEASE --short --release | cut -d. -f1` + DIST=$ID$RELEASE + ;; +Fedora) + RELEASE=`$LSB_RELEASE --short --release` + DIST=$ID$RELEASE + ;; +*) + DIST=unknown + ;; +esac + +echo $DIST