Show More
@@ -57,8 +57,6 b' def update(repo, node, branchmerge=False' | |||||
57 | if not force and pl[1] != nullid: |
|
57 | if not force and pl[1] != nullid: | |
58 | raise util.Abort(_("outstanding uncommitted merges")) |
|
58 | raise util.Abort(_("outstanding uncommitted merges")) | |
59 |
|
59 | |||
60 | err = False |
|
|||
61 |
|
||||
62 | p1, p2 = pl[0], node |
|
60 | p1, p2 = pl[0], node | |
63 | pa = repo.changelog.ancestor(p1, p2) |
|
61 | pa = repo.changelog.ancestor(p1, p2) | |
64 | m1n = repo.changelog.read(p1)[0] |
|
62 | m1n = repo.changelog.read(p1)[0] | |
@@ -276,7 +274,7 b' def update(repo, node, branchmerge=False' | |||||
276 | repo.dirstate.update([f], 'n') |
|
274 | repo.dirstate.update([f], 'n') | |
277 |
|
275 | |||
278 | # merge the tricky bits |
|
276 | # merge the tricky bits | |
279 |
|
|
277 | unresolved = [] | |
280 | files = merge.keys() |
|
278 | files = merge.keys() | |
281 | files.sort() |
|
279 | files.sort() | |
282 | for f in files: |
|
280 | for f in files: | |
@@ -284,8 +282,7 b' def update(repo, node, branchmerge=False' | |||||
284 | my, other, flag = merge[f] |
|
282 | my, other, flag = merge[f] | |
285 | ret = merge3(repo, f, my, other, xp1, xp2) |
|
283 | ret = merge3(repo, f, my, other, xp1, xp2) | |
286 | if ret: |
|
284 | if ret: | |
287 | err = True |
|
285 | unresolved.append(f) | |
288 | failedmerge.append(f) |
|
|||
289 | util.set_exec(repo.wjoin(f), flag) |
|
286 | util.set_exec(repo.wjoin(f), flag) | |
290 | if not partial: |
|
287 | if not partial: | |
291 | if branchmerge: |
|
288 | if branchmerge: | |
@@ -322,14 +319,14 b' def update(repo, node, branchmerge=False' | |||||
322 |
|
319 | |||
323 | if show_stats: |
|
320 | if show_stats: | |
324 | stats = ((len(get), _("updated")), |
|
321 | stats = ((len(get), _("updated")), | |
325 |
(len(merge) - len( |
|
322 | (len(merge) - len(unresolved), _("merged")), | |
326 | (len(remove), _("removed")), |
|
323 | (len(remove), _("removed")), | |
327 |
(len( |
|
324 | (len(unresolved), _("unresolved"))) | |
328 | note = ", ".join([_("%d files %s") % s for s in stats]) |
|
325 | note = ", ".join([_("%d files %s") % s for s in stats]) | |
329 | repo.ui.status("%s\n" % note) |
|
326 | repo.ui.status("%s\n" % note) | |
330 | if not partial: |
|
327 | if not partial: | |
331 | if branchmerge: |
|
328 | if branchmerge: | |
332 |
if |
|
329 | if unresolved: | |
333 | repo.ui.status(_("There are unresolved merges," |
|
330 | repo.ui.status(_("There are unresolved merges," | |
334 | " you can redo the full merge using:\n" |
|
331 | " you can redo the full merge using:\n" | |
335 | " hg update -C %s\n" |
|
332 | " hg update -C %s\n" | |
@@ -338,10 +335,10 b' def update(repo, node, branchmerge=False' | |||||
338 | repo.changelog.rev(p2)))) |
|
335 | repo.changelog.rev(p2)))) | |
339 | elif remind: |
|
336 | elif remind: | |
340 | repo.ui.status(_("(branch merge, don't forget to commit)\n")) |
|
337 | repo.ui.status(_("(branch merge, don't forget to commit)\n")) | |
341 |
elif |
|
338 | elif unresolved: | |
342 | repo.ui.status(_("There are unresolved merges with" |
|
339 | repo.ui.status(_("There are unresolved merges with" | |
343 | " locally modified files.\n")) |
|
340 | " locally modified files.\n")) | |
344 |
|
341 | |||
345 |
repo.hook('update', parent1=xp1, parent2=xxp2, error= |
|
342 | repo.hook('update', parent1=xp1, parent2=xxp2, error=len(unresolved)) | |
346 |
return |
|
343 | return len(unresolved) | |
347 |
|
344 |
General Comments 0
You need to be logged in to leave comments.
Login now