我有一个存储库,在同一个提交中有多个标记.例如:
commit #3 <--- TAG1 / TAG2 / TAG3
|
commit #2 <--- TAG4/ TAG5
|
commit #1 <--- TAG6/ TAG7
Run Code Online (Sandbox Code Playgroud)
我想找出特定提交中的标记.例如,如果我检查提交1,我想获得标记6和标记7.
我试过了:
git checkout <commit 1>
git tag --contains
Run Code Online (Sandbox Code Playgroud)
显示标签1-7.
git checkout <commit 1>
git describe --tags HEAD
Run Code Online (Sandbox Code Playgroud)
仅显示标签6.
在Git中这样做的正确方法是什么?
git ×1