linux - gitk 的 "Mark Branch Sides"选项的定义

标签 linux git gitk

在 gitk 中,“编辑 View ”(F4) 窗口中有一个名为“标记分支边”的选项。它似乎对应于 --left-right 选项:

+set known_view_options {
+    {perm    b    . {}               {mc "Remember this view"}}
+    {args    t50= + {}               {mc "Commits to include (arguments to git log):"}}
+    {all     b    * "--all"          {mc "Use all refs"}}
+    {dorder  b    . {"--date-order" "-d"}      {mc "Strictly sort by date"}}
+    {lright  b    . "--left-right"   {mc "Mark branch sides"}}

我能看到的唯一区别是提交由三角形而不是圆圈标记。这个选项应该做什么?

最佳答案

我想它链接到 git loggit rev-list --左右选项:

Mark which side of a symmetric diff a commit is reachable from.
Commits from the left side are prefixed with < and those from the right with >

(<> 应该解释了 gitk 中使用的三角形)

来自 ProGit book :

A common switch to use with the log command in this case is --left-right, which shows you which side of the range each commit is in. This helps make the data more useful:

$ git log --left-right master...experiment
< F
< E
> D
> C

(对 seeing remote changes 有帮助)


Dmitry Avtonomov添加 the comments (十一年后):

To make "Mark branch sides" make any difference in gitk, you need to specify a range in text field "Additional arguments to git log", e.g. like in VonC's example: "master...experiment".

There also need to be some commits present only on one of those specified branches.

关于linux - gitk 的 "Mark Branch Sides"选项的定义,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/7324763/

相关文章:

gitk - 如何在gitk中复制文本

Git:git/linux维护者如何维护这么多分支

c - 从 Matlab 运行 C 可执行文件

git - 我怎样才能用我藏起来的东西格式化补丁

git fsck : how --dangling vs. --unreachable vs. --lost-found 有什么不同?

日志消息中提到的 git rebase 和 SHA

windows - `gitk` 使用`where`命令找到程序但无法执行?

linux - 从 Linux 上的用户空间 Hook 系统调用

python - bash 中的 TCP 客户端

linux - 使用带有嵌入空格的参数(例如文件名)在 bash 脚本中调用命令