Show More
@@ -238,7 +238,7 b' def manifestmerge(repo, wctx, p2, pa, br' | |||
|
238 | 238 | |
|
239 | 239 | aborts, prompts = [], [] |
|
240 | 240 | # Compare manifests |
|
241 | for f, n in m1.iteritems(): | |
|
241 | for f, n1 in m1.iteritems(): | |
|
242 | 242 | if partial and not partial(f): |
|
243 | 243 | continue |
|
244 | 244 | if f in m2: |
@@ -246,18 +246,18 b' def manifestmerge(repo, wctx, p2, pa, br' | |||
|
246 | 246 | fl1, fl2, fla = m1.flags(f), m2.flags(f), ma.flags(f) |
|
247 | 247 | nol = 'l' not in fl1 + fl2 + fla |
|
248 | 248 | a = ma.get(f, nullid) |
|
249 | if n == n2 and fl1 == fl2: | |
|
249 | if n1 == n2 and fl1 == fl2: | |
|
250 | 250 | pass # same - keep local |
|
251 | 251 | elif n2 == a and fl2 == fla: |
|
252 | 252 | pass # remote unchanged - keep local |
|
253 | elif n == a and fl1 == fla: # local unchanged - use remote | |
|
254 | if n == n2: # optimization: keep local content | |
|
253 | elif n1 == a and fl1 == fla: # local unchanged - use remote | |
|
254 | if n1 == n2: # optimization: keep local content | |
|
255 | 255 | actions.append((f, "e", (fl2,), "update permissions")) |
|
256 | 256 | else: |
|
257 | 257 | actions.append((f, "g", (fl2,), "remote is newer")) |
|
258 | 258 | elif nol and n2 == a: # remote only changed 'x' |
|
259 | 259 | actions.append((f, "e", (fl2,), "update permissions")) |
|
260 | elif nol and n == a: # local only changed 'x' | |
|
260 | elif nol and n1 == a: # local only changed 'x' | |
|
261 | 261 | actions.append((f, "g", (fl1,), "remote is newer")) |
|
262 | 262 | else: # both changed something |
|
263 | 263 | actions.append((f, "m", (f, f, False), "versions differ")) |
@@ -272,14 +272,14 b' def manifestmerge(repo, wctx, p2, pa, br' | |||
|
272 | 272 | actions.append((f, "m", (f2, f, False), |
|
273 | 273 | "local copied/moved to " + f2)) |
|
274 | 274 | elif f in ma: # clean, a different, no remote |
|
275 | if n != ma[f]: | |
|
275 | if n1 != ma[f]: | |
|
276 | 276 | prompts.append((f, "cd")) # prompt changed/deleted |
|
277 | elif n[20:] == "a": # added, no remote | |
|
277 | elif n1[20:] == "a": # added, no remote | |
|
278 | 278 | actions.append((f, "f", None, "remote deleted")) |
|
279 | 279 | else: |
|
280 | 280 | actions.append((f, "r", None, "other deleted")) |
|
281 | 281 | |
|
282 | for f, n in m2.iteritems(): | |
|
282 | for f, n2 in m2.iteritems(): | |
|
283 | 283 | if partial and not partial(f): |
|
284 | 284 | continue |
|
285 | 285 | if f in m1 or f in copied: # files already visited |
@@ -320,7 +320,7 b' def manifestmerge(repo, wctx, p2, pa, br' | |||
|
320 | 320 | aborts.append((f, "ud")) |
|
321 | 321 | else: |
|
322 | 322 | actions.append((f, "g", (m2.flags(f),), "remote created")) |
|
323 | elif n != ma[f]: | |
|
323 | elif n2 != ma[f]: | |
|
324 | 324 | prompts.append((f, "dc")) # prompt deleted/changed |
|
325 | 325 | |
|
326 | 326 | for f, m in sorted(aborts): |
General Comments 0
You need to be logged in to leave comments.
Login now