Is there an easy way or command to get all git commits up to a specific tag to generate an automatic changelog for a project? I always tag my git repos with a version number lik
I came up with this modification of the original script. This handles version tags correctly.
#!/bin/bash
# Author:Andrey Nikishaev
echo "CHANGELOG"
echo ----------------------
git tag -l --sort=v:refname | tac | while read TAG ; do
echo
if [ $NEXT ];then
echo [$NEXT]
else
echo "[Current]"
fi
GIT_PAGER=cat git log --no-merges --format=" * %s" $TAG..$NEXT
NEXT=$TAG
done
FIRST=$(git tag -l --sort=v:refname | head -1)
echo
echo [$FIRST]
GIT_PAGER=cat git log --no-merges --format=" * %s" $FIRST