Show More
@@ -83,6 +83,10 b' try:' | |||
|
83 | 83 | if len(opts[b'label']) > 2: |
|
84 | 84 | opts[b'mode'] = b'merge3' |
|
85 | 85 | local, base, other = args |
|
86 | overrides = opts[b'label'] | |
|
87 | labels = [local, other, base] | |
|
88 | labels[: len(overrides)] = overrides | |
|
89 | opts[b'label'] = labels | |
|
86 | 90 | sys.exit( |
|
87 | 91 | simplemerge.simplemerge( |
|
88 | 92 | uimod.ui.load(), |
@@ -332,10 +332,10 b' def _verifytext(text, path, ui, opts):' | |||
|
332 | 332 | return text |
|
333 | 333 | |
|
334 | 334 | |
|
335 |
def _picklabels( |
|
|
335 | def _picklabels(overrides): | |
|
336 | 336 | if len(overrides) > 3: |
|
337 | 337 | raise error.Abort(_(b"can only specify three labels.")) |
|
338 | result = defaults[:] | |
|
338 | result = [None, None, None] | |
|
339 | 339 | for i, override in enumerate(overrides): |
|
340 | 340 | result[i] = override |
|
341 | 341 | return result |
@@ -501,9 +501,7 b' def simplemerge(ui, localctx, basectx, o' | |||
|
501 | 501 | elif mode == b'other': |
|
502 | 502 | lines = _resolve(m3, (2,)) |
|
503 | 503 | else: |
|
504 | name_a, name_b, name_base = _picklabels( | |
|
505 | [localctx.path(), otherctx.path(), None], opts.get('label', []) | |
|
506 | ) | |
|
504 | name_a, name_b, name_base = _picklabels(opts.get('label', [])) | |
|
507 | 505 | if mode == b'mergediff': |
|
508 | 506 | lines, conflicts = render_mergediff(m3, name_a, name_b, name_base) |
|
509 | 507 | else: |
General Comments 0
You need to be logged in to leave comments.
Login now