Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我尝试查看 git glob'ing 功能,但找不到我想做的事情。我有很多 master 的分支,它们彼此相对接近,但 master 远远落后,所以当我执行 git show-branch 时,树非常高,所以我想基本上过滤掉 master。我需要类似 git show-branch * - master
你可以使用:
git log --graph --oneline --all <commit>..
它将以图形方式显示所有分支和之后的提交<commit>。--all您可以使用以下方法列出分支,而不是参数:
<commit>
--all
git log --graph --oneline <commit>.. <path> ...
如果这些不能让您获得更短的输出,您可以尝试:
git branch | grep -v master | xargs git log --graph --oneline <commit>..