Back

Explore Courses Blog Tutorials Interview Questions
0 votes
1 view
in DevOps and Agile by (29.3k points)

This question is similar to How to list all tags pointing to a specific commit in git, but with one difference: I wish to search for all tags that contain a specific commit within the tree of each tag, not specifically the files marked in the tag itself (in this case, only the Makefile change has been tagged).

1 Answer

0 votes
by (50.2k points)

For this there is a simple command that would probably work:

git tag --contains<commit>

This command will list the tags that contain a commit.

Reference: https://git-scm.com/docs/git-tag#Documentation/git-tag.txt---containsltcommitgt 

Related questions

0 votes
1 answer
asked Nov 4, 2019 in DevOps and Agile by chandra (29.3k points)
+5 votes
1 answer
+2 votes
1 answer

Browse Categories

...