git: Finding Tags Associated With a Commit

If your source tree is complicated and multiple branches are in use, it can often be difficult to quickly determine which tagged builds contain a specific commit. Did this fix go to the beta branch? Did it make it into 0.9.54, or was it 0.9.55?

Here’s the git command you need:

git tag --contains a5b49f9
        0.9.324
        beta.40
        beta.41
        release.2

Share Your Thoughts

This site uses Akismet to reduce spam. Learn how your comment data is processed.