与GUI中提供的选项相比,man gitk显示的选项数量非常有限.
解决方法
man gitk
至少提到它确实采取与
git rev-list
相同的选项,包括
--date-order
This option is similar to
--topo-order
in the sense that no parent comes before all of its children,but otherwise things are still ordered in the commit timestamp order.
有关更多信息,请参见“Guide to understanding gitk?”.
注意:如果-d或–date-order确实是你所追求的参数,最好不要使用太多,根据Linus本人(从lists-archives.com/git或www.spinics.net/lists/git/):
The thing is,
--date-order
strings out and mixes up the commits on the
same development chain,and by doing so it makes the different chains of
development much harder to see.
It also ends up showing the development in
a more “parallel” way,which in turn makes the view even harder to read.So I would suggest not using
--date-order
by default. It doesn’t add
anything to any normal flow,and it makes the big picture harder to see.The only time you really want
--date-order
(or “-d
“,which is shorthand
for it for justgitk
) is really
- when the big picture is really really simple,and you actually want to
see more detail because the big picture is too trivial to even be
interesting otherwise.
(In other words:--date-order
is fine for really simple development
where there is only ever just a couple of branches or where you have
pruned away so much of the history that the remaining part is simple)- when you want to debug “
git rev-list
” behaviour itself,since the date
order actually matters for how git traverses the commit chains.The second case is something that I suspect nobody but me and a few other
people have ever done.
I found it very useful together with--show-all
when I was debugging the revision walker (see commits “07005” and “07006”,
where the first implements--show-all
,and the second one is the end
result of my debugging).In other words: never start out with “
-d
” or “--date-order
” by default. Only if you have some reason to then think that the view is too simple or you need to drill down into the commit relationships should you use it.
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。