Mercurial > public > mercurial-scm > hg
comparison mercurial/debugcommands.py @ 50956:91c32fccd282
debugp1copies: migrate `opts` to native kwargs
author | Matt Harbison <matt_harbison@yahoo.com> |
---|---|
date | Mon, 21 Aug 2023 17:29:05 -0400 |
parents | 55c28ffadb14 |
children | 1e2be2c9a74d |
comparison
equal
deleted
inserted
replaced
50955:55c28ffadb14 | 50956:91c32fccd282 |
---|---|
2825 _(b'[-r REV]'), | 2825 _(b'[-r REV]'), |
2826 ) | 2826 ) |
2827 def debugp1copies(ui, repo, **opts): | 2827 def debugp1copies(ui, repo, **opts): |
2828 """dump copy information compared to p1""" | 2828 """dump copy information compared to p1""" |
2829 | 2829 |
2830 opts = pycompat.byteskwargs(opts) | 2830 ctx = scmutil.revsingle(repo, opts.get('rev'), default=None) |
2831 ctx = scmutil.revsingle(repo, opts.get(b'rev'), default=None) | |
2832 for dst, src in ctx.p1copies().items(): | 2831 for dst, src in ctx.p1copies().items(): |
2833 ui.write(b'%s -> %s\n' % (src, dst)) | 2832 ui.write(b'%s -> %s\n' % (src, dst)) |
2834 | 2833 |
2835 | 2834 |
2836 @command( | 2835 @command( |