我们说我有两个分支,默认和mybranch,我想写一个小脚本来看:
#1的一些伪代码:
m_lastmergetime = 0
for each m in [all merges with default from mybranch]
m_mergetime = m.date_in_hours
m_timebetweenmerges = m_mergetime - m_lastmergetime
if m_lastmergetime > 0
print m_timebetweenmerges
Sub.steps:
案例#2非常相似。我只需要:
答案 0 :(得分:7)
要查找从分支Y合并的分支X上的所有变更集,您将发出以下Mercurial命令:
hg log --rev "children(branch(X)) and children(branch(Y)) and branch(X)"
要查找从分支X合并的分支Y上的所有内容(即相反的方向),只需将最后一个分支名称更改为Y:
hg log --rev "children(branch(X)) and children(branch(Y)) and branch(Y)"
^ ^ ^
+------ leave these ----+ |
|
but change this ---------------+
基本上,查询说你想要所有的变更集: