release.sh: improve script.

This commit is contained in:
Hector Sanjuan 2021-01-14 14:06:53 +01:00
parent 35b596b450
commit 1ef23bf3ee

View File

@ -22,7 +22,7 @@ if [[ "$version" == *"-next" ]]; then
exit 0 exit 0
fi fi
# RC versions, commit and make a non-annotated tag. # RC versions, commit and make a tag without history.
if [[ "$version" == *"-rc"* ]]; then if [[ "$version" == *"-rc"* ]]; then
git commit -S -m "Release candidate v${version}" git commit -S -m "Release candidate v${version}"
git tag -s "v${version}" git tag -s "v${version}"
@ -32,7 +32,7 @@ fi
# Actual releases, commit and make an annotated tag with all the commits # Actual releases, commit and make an annotated tag with all the commits
# since the last. # since the last.
git commit -S -m "Release v${version}" git commit -S -m "Release v${version}"
lastver=`git describe --abbrev=0` lastver=`git describe --abbrev=0 --exclude '*rc*'`
echo "Tag for Release ${version}" > tag_annotation echo "Tag for Release ${version}" > tag_annotation
echo >> tag_annotation echo >> tag_annotation
git log --pretty=oneline ${lastver}..HEAD >> tag_annotation git log --pretty=oneline ${lastver}..HEAD >> tag_annotation