如何从命令行上的 sha1 散列中获取分支/功能名称?
还有这是如何使用 pretty=format 语法完成的。
我看到它是用这种方法以某种方式完成的
git log --graph --full-history --all --color \
--pretty=format:"%x1b[31m%h%x09%x1b[32m%d%x1b[0m%x20%s"
但我不知道是哪一行导致的。
最佳答案
How do I get the branch/feature name from a sha1 hash on the command line?
你可以使用...
git branch --contains <sha1>
关于linux - git 命令显示来自 sha1 哈希的分支/功能名称,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/14206505/