-
-
Save amine2233/3ba42517a3ecdf62a218264aa7d80e4a to your computer and use it in GitHub Desktop.
Display a simple changelog between the last two tags in a Git repository
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /usr/bin/env sh | |
firstTag=$(git tag | sort -r | head -1) | |
secondTag=$(git tag | sort -r | head -2 | awk '{split($0, tags, "\n")} END {print tags[1]}') | |
echo "Changes between ${secondTag} and ${firstTag}\n" | |
git log --pretty=format:' * %s' ${secondTag}..${firstTag} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment