Can git list the tags that occur between two particular commits?
2 Solutions collect form web for “Can git list the tags that occur between two particular commits?”
You can use the
git log command with these options:
git log tagA...tagB --decorate --simplify-by-decoration
--decorate displays the tag names next to the commit, and
--simplify-by-decoration shows only commits that have been tagged.
If you only wants the tag name list (in reverse chronological order) between
commit2, you can combine
git log with
git tag --points-at:
git log commit1..commit2 --simplify-by-decoration --format=format:%h | xargs -L1 git tag --points-at