From: Elan Ruusamäe Date: Mon, 6 Aug 2012 18:48:17 +0000 (+0300) Subject: fetch tags before figuring out last tag X-Git-Tag: auto/th/rpm-build-macros-1.652-1~3 X-Git-Url: http://git.pld-linux.org/?p=packages%2Frpm-build-macros.git;a=commitdiff_plain;h=39da278caad038ab14641ed7e0888a9e79fd02e4 fetch tags before figuring out last tag --- diff --git a/rpm-build.sh b/rpm-build.sh index ac44f38..a04dc94 100755 --- a/rpm-build.sh +++ b/rpm-build.sh @@ -120,6 +120,7 @@ autotag() { s=${s%:*} # ensure package ends with .spec s=${s%.spec}.spec + git fetch --tags out=$(git for-each-ref --count=1 --sort=-authordate refs/tags/auto/$dist \ --format='%(refname:short)') echo "$s:$out"