[projects/rc-scripts] update make tag helper from geninitrd

glen glen at pld-linux.org
Mon Jul 7 17:36:43 CEST 2014


commit 42167d3948c02c7711a77dcb254986fee402ec02
Author: Elan Ruusamäe <glen at delfi.ee>
Date:   Mon Jul 7 18:36:39 2014 +0300

    update make tag helper from geninitrd

 make-tag.sh | 28 ++++++++++++++++++++++------
 1 file changed, 22 insertions(+), 6 deletions(-)
---
diff --git a/make-tag.sh b/make-tag.sh
index dafbed8..2ad825d 100755
--- a/make-tag.sh
+++ b/make-tag.sh
@@ -1,14 +1,30 @@
 #!/bin/sh
 set -e
 rev=$(git rev-parse HEAD)
+last_tag=$(git tag -l | grep '^0' | sort -V | tail -n1)
 
-version=$(awk -F, '/AC_INIT/{print $2}' configure.ac | tr -d '[ ]')
-tag="$version"
+if [ -n "$1" ]; then
+	tag="$1"
+else
+	tag=$(awk -F, '/AC_INIT/{print $2}' configure.ac | tr -d '[ ]')
+fi
 
-echo "Making tag: $tag at revision $rev"
-echo ""
-echo "Press ENTER to continue..."
+cat <<EOF
+Making tag: $tag at revision $rev
+
+You probably want to fill git shortlog from last tag $last_tag as annotated tag message:
+
+  git shortlog $last_tag..HEAD
+
+Press ENTER to continue, Ctrl+C to abort
+EOF
 read a
 
 git tag -a "$tag" $rev
-git push origin "refs/tags/$tag"
+
+cat <<EOF
+
+To push tag, execute:
+
+  git push origin "refs/tags/$tag"
+EOF
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/projects/rc-scripts.git/commitdiff/42167d3948c02c7711a77dcb254986fee402ec02



More information about the pld-cvs-commit mailing list