add shltag

This commit is contained in:
Hedy Li 2021-07-19 13:29:43 +08:00
parent 45bab3c745
commit 560f8b91ed
Signed by: hedy
GPG Key ID: B51B5A8D1B176372

14
bin/shltag Executable file
View File

@ -0,0 +1,14 @@
#!/usr/bin/env bash
old=$(git tag | tail -n1)
case $1 in
v*)
git shortlog $old..HEAD | git tag -as -F - $1
exit;;
--help)
echo Usage: shltag '[v<version> | --help | -o ]'
exit;;
-o)
# show old tag
echo old is $old;;
esac