##// END OF EJS Templates
avoid unnecessary copy merges
Matt Mackall -
r3674:9103dab9 default
parent child Browse files
Show More
@@ -139,6 +139,8 b' def findcopies(repo, m1, m2, ma, limit):'
139 ''' check if an apparent pair actually matches '''
139 ''' check if an apparent pair actually matches '''
140 c2 = ctx(f2, man[f2])
140 c2 = ctx(f2, man[f2])
141 ca = c.ancestor(c2)
141 ca = c.ancestor(c2)
142 if c == ca or c2 == ca:
143 return
142 if ca and ca.path() == c.path() or ca.path() == c2.path():
144 if ca and ca.path() == c.path() or ca.path() == c2.path():
143 copy[c.path()] = f2
145 copy[c.path()] = f2
144 copy[f2] = c.path()
146 copy[f2] = c.path()
@@ -6,5 +6,4 b' adding manifests'
6 adding file changes
6 adding file changes
7 added 2 changesets with 2 changes to 1 files
7 added 2 changesets with 2 changes to 1 files
8 (run 'hg update' to get a working copy)
8 (run 'hg update' to get a working copy)
9 merging a and b
9 1 files updated, 0 files merged, 1 files removed, 0 files unresolved
10 0 files updated, 1 files merged, 0 files removed, 0 files unresolved
@@ -88,15 +88,14 b' resolving manifests'
88 overwrite None partial False
88 overwrite None partial False
89 ancestor 924404dff337 local 94b33a1b7f2d+ remote 735846fee2d7
89 ancestor 924404dff337 local 94b33a1b7f2d+ remote 735846fee2d7
90 rev: versions differ -> m
90 rev: versions differ -> m
91 a: remote copied -> m
91 b: remote created -> g
92 copying a to b
92 getting b
93 merging rev
93 merging rev
94 my rev@94b33a1b7f2d+ other rev@735846fee2d7 ancestor rev@924404dff337
94 my rev@94b33a1b7f2d+ other rev@735846fee2d7 ancestor rev@924404dff337
95 1 files updated, 1 files merged, 0 files removed, 0 files unresolved
95 1 files updated, 1 files merged, 0 files removed, 0 files unresolved
96 (branch merge, don't forget to commit)
96 (branch merge, don't forget to commit)
97 --------------
97 --------------
98 M b
98 M b
99 a
100 C a
99 C a
101 --------------
100 --------------
102
101
@@ -106,16 +105,14 b' test L:nc a b R: W: - 6 not'
106 resolving manifests
105 resolving manifests
107 overwrite None partial False
106 overwrite None partial False
108 ancestor 924404dff337 local ac809aeed39a+ remote 97c705ade336
107 ancestor 924404dff337 local ac809aeed39a+ remote 97c705ade336
109 b: local copied -> m
110 rev: versions differ -> m
108 rev: versions differ -> m
111 merging rev
109 merging rev
112 my rev@ac809aeed39a+ other rev@97c705ade336 ancestor rev@924404dff337
110 my rev@ac809aeed39a+ other rev@97c705ade336 ancestor rev@924404dff337
113 1 files updated, 1 files merged, 0 files removed, 0 files unresolved
111 0 files updated, 1 files merged, 0 files removed, 0 files unresolved
114 (branch merge, don't forget to commit)
112 (branch merge, don't forget to commit)
115 --------------
113 --------------
116 M b
117 a
118 C a
114 C a
115 C b
119 --------------
116 --------------
120
117
121 --------------
118 --------------
@@ -124,17 +121,17 b' test L: R:nm a b W: - 7 get'
124 resolving manifests
121 resolving manifests
125 overwrite None partial False
122 overwrite None partial False
126 ancestor 924404dff337 local 94b33a1b7f2d+ remote e03727d2d66b
123 ancestor 924404dff337 local 94b33a1b7f2d+ remote e03727d2d66b
127 a: remote moved -> m
124 a: other deleted -> r
128 rev: versions differ -> m
125 rev: versions differ -> m
129 copying a to b
126 b: remote created -> g
130 removing a
127 removing a
128 getting b
131 merging rev
129 merging rev
132 my rev@94b33a1b7f2d+ other rev@e03727d2d66b ancestor rev@924404dff337
130 my rev@94b33a1b7f2d+ other rev@e03727d2d66b ancestor rev@924404dff337
133 1 files updated, 1 files merged, 0 files removed, 0 files unresolved
131 1 files updated, 1 files merged, 1 files removed, 0 files unresolved
134 (branch merge, don't forget to commit)
132 (branch merge, don't forget to commit)
135 --------------
133 --------------
136 M b
134 M b
137 a
138 --------------
135 --------------
139
136
140 --------------
137 --------------
@@ -143,15 +140,13 b' test L:nm a b R: W: - 8 not'
143 resolving manifests
140 resolving manifests
144 overwrite None partial False
141 overwrite None partial False
145 ancestor 924404dff337 local ecf3cb2a4219+ remote 97c705ade336
142 ancestor 924404dff337 local ecf3cb2a4219+ remote 97c705ade336
146 b: local moved -> m
147 rev: versions differ -> m
143 rev: versions differ -> m
148 merging rev
144 merging rev
149 my rev@ecf3cb2a4219+ other rev@97c705ade336 ancestor rev@924404dff337
145 my rev@ecf3cb2a4219+ other rev@97c705ade336 ancestor rev@924404dff337
150 1 files updated, 1 files merged, 0 files removed, 0 files unresolved
146 0 files updated, 1 files merged, 0 files removed, 0 files unresolved
151 (branch merge, don't forget to commit)
147 (branch merge, don't forget to commit)
152 --------------
148 --------------
153 M b
149 C b
154 a
155 --------------
150 --------------
156
151
157 --------------
152 --------------
General Comments 0
You need to be logged in to leave comments. Login now