Skip to content
Snippets Groups Projects
  • Martin von Zweigbergk's avatar
    0103e7187237
    drawdag: include files from both parents in merge commits · 0103e7187237
    Martin von Zweigbergk authored
    Consider a graph like this:
    
      D
      |\
      B C
      |/
      A
    
    drawdag will add a file called A in commit A, file B in B, file C in
    C. That's fine and expected. In merge commits like D, I would expect
    the files and their contents to be taken from the parent commits, so
    commit D in this example would have files A, B, and C. However,
    drawdag will instead add the file D compared to the first
    parent. Depending on whether B or C got a smaller nodeid, the contents
    of D would be {A, B, D} or {A, C, D}. This patch changes it to to be
    {A, B, C}.
    
    Differential Revision: https://phab.mercurial-scm.org/D92
    0103e7187237
    History
    drawdag: include files from both parents in merge commits
    Martin von Zweigbergk authored
    Consider a graph like this:
    
      D
      |\
      B C
      |/
      A
    
    drawdag will add a file called A in commit A, file B in B, file C in
    C. That's fine and expected. In merge commits like D, I would expect
    the files and their contents to be taken from the parent commits, so
    commit D in this example would have files A, B, and C. However,
    drawdag will instead add the file D compared to the first
    parent. Depending on whether B or C got a smaller nodeid, the contents
    of D would be {A, B, D} or {A, C, D}. This patch changes it to to be
    {A, B, C}.
    
    Differential Revision: https://phab.mercurial-scm.org/D92