diff options
author | Ed Warnicke <eaw@cisco.com> | 2016-05-31 14:04:16 -0700 |
---|---|---|
committer | Dave Wallace <dwallacelf@gmail.com> | 2016-05-31 21:35:22 +0000 |
commit | 6795fb9f70f2234fc0c35f0634bb9ac16f848183 (patch) | |
tree | 62d3ffa1e54fe3356b7397cc95bb99bdec94c97e | |
parent | 245576a4389a9b21b27314afa04722f589676b47 (diff) |
Fix build-root/scripts/version to not have spurious ~
Change-Id: Id28f134e3a4aa19c5756014d53004501db0d0c88
Signed-off-by: Ed Warnicke <eaw@cisco.com>
-rwxr-xr-x | build-root/scripts/version | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/build-root/scripts/version b/build-root/scripts/version index bf7e31551b9..8724ced3c18 100755 --- a/build-root/scripts/version +++ b/build-root/scripts/version @@ -15,13 +15,12 @@ fi if [ "$1" = "rpm-release" ]; then [ -z "${ADD}" ] && echo release && exit - CMT=$(git describe --dirty --match 'v*'| cut -s -d- -f3,4 | sed 's/-/_/') - echo ${ADD}~${CMT}${BLD} + echo ${ADD}${CMT:+~${CMT}}${BLD} exit fi if [ -n "${ADD}" ]; then - echo ${TAG}-${ADD}~${CMT}${BLD} + echo ${TAG}-${ADD}${CMT:+~${CMT}}${BLD} else echo ${TAG} fi |