1516 if stat: |
1516 if stat: |
1517 diffopts = diffopts.copy(context=0) |
1517 diffopts = diffopts.copy(context=0) |
1518 width = 80 |
1518 width = 80 |
1519 if not ui.plain(): |
1519 if not ui.plain(): |
1520 width = ui.termwidth() |
1520 width = ui.termwidth() |
1521 chunks = patch.diff(repo, node1, node2, match, changes, diffopts, |
1521 chunks = patch.diff(repo, node1, node2, match, changes, opts=diffopts, |
1522 prefix=prefix, relroot=relroot, |
1522 prefix=prefix, relroot=relroot, |
1523 hunksfilterfn=hunksfilterfn) |
1523 hunksfilterfn=hunksfilterfn) |
1524 for chunk, label in patch.diffstatui(util.iterlines(chunks), |
1524 for chunk, label in patch.diffstatui(util.iterlines(chunks), |
1525 width=width): |
1525 width=width): |
1526 write(chunk, label=label) |
1526 write(chunk, label=label) |
1527 else: |
1527 else: |
1528 for chunk, label in patch.diffui(repo, node1, node2, match, |
1528 for chunk, label in patch.diffui(repo, node1, node2, match, |
1529 changes, diffopts, prefix=prefix, |
1529 changes, opts=diffopts, prefix=prefix, |
1530 relroot=relroot, |
1530 relroot=relroot, |
1531 hunksfilterfn=hunksfilterfn): |
1531 hunksfilterfn=hunksfilterfn): |
1532 write(chunk, label=label) |
1532 write(chunk, label=label) |
1533 |
1533 |
1534 if listsubrepos: |
1534 if listsubrepos: |