Show More
@@ -398,6 +398,8 b' def diffrevs(' | |||||
398 | ): |
|
398 | ): | |
399 |
|
399 | |||
400 | subrepos = opts.get(b'subrepos') |
|
400 | subrepos = opts.get(b'subrepos') | |
|
401 | ||||
|
402 | # calculate list of files changed between both revs | |||
401 | st = repo.status(node1a, node2, matcher, listsubrepos=subrepos) |
|
403 | st = repo.status(node1a, node2, matcher, listsubrepos=subrepos) | |
402 | mod_a, add_a, rem_a = set(st.modified), set(st.added), set(st.removed) |
|
404 | mod_a, add_a, rem_a = set(st.modified), set(st.added), set(st.removed) | |
403 | if do3way: |
|
405 | if do3way: | |
@@ -413,11 +415,18 b' def diffrevs(' | |||||
413 | common = modadd | rem_a | rem_b |
|
415 | common = modadd | rem_a | rem_b | |
414 | if not common: |
|
416 | if not common: | |
415 | return 0 |
|
417 | return 0 | |
|
418 | ||||
416 | # Always make a copy of node1a (and node1b, if applicable) |
|
419 | # Always make a copy of node1a (and node1b, if applicable) | |
|
420 | # dir1a should contain files which are: | |||
|
421 | # * modified or removed from node1a to node2 | |||
|
422 | # * modified or added from node1b to node2 | |||
|
423 | # (except file added from node1a to node2 as they were not present in | |||
|
424 | # node1a) | |||
417 | dir1a_files = mod_a | rem_a | ((mod_b | add_b) - add_a) |
|
425 | dir1a_files = mod_a | rem_a | ((mod_b | add_b) - add_a) | |
418 | dir1a = snapshot(ui, repo, dir1a_files, node1a, tmproot, subrepos)[0] |
|
426 | dir1a = snapshot(ui, repo, dir1a_files, node1a, tmproot, subrepos)[0] | |
419 | rev1a = b'@%d' % repo[node1a].rev() |
|
427 | rev1a = b'@%d' % repo[node1a].rev() | |
420 | if do3way: |
|
428 | if do3way: | |
|
429 | # file calculation criteria same as dir1a | |||
421 | dir1b_files = mod_b | rem_b | ((mod_a | add_a) - add_b) |
|
430 | dir1b_files = mod_b | rem_b | ((mod_a | add_a) - add_b) | |
422 | dir1b = snapshot(ui, repo, dir1b_files, node1b, tmproot, subrepos)[0] |
|
431 | dir1b = snapshot(ui, repo, dir1b_files, node1b, tmproot, subrepos)[0] | |
423 | rev1b = b'@%d' % repo[node1b].rev() |
|
432 | rev1b = b'@%d' % repo[node1b].rev() |
General Comments 0
You need to be logged in to leave comments.
Login now