Mercurial > public > mercurial-scm > hg
comparison mercurial/debugcommands.py @ 50957:1e2be2c9a74d
debugp2copies: migrate `opts` to native kwargs
author | Matt Harbison <matt_harbison@yahoo.com> |
---|---|
date | Mon, 21 Aug 2023 17:29:56 -0400 |
parents | 91c32fccd282 |
children | 206d7fad2a1c |
comparison
equal
deleted
inserted
replaced
50956:91c32fccd282 | 50957:1e2be2c9a74d |
---|---|
2838 _(b'[-r REV]'), | 2838 _(b'[-r REV]'), |
2839 ) | 2839 ) |
2840 def debugp2copies(ui, repo, **opts): | 2840 def debugp2copies(ui, repo, **opts): |
2841 """dump copy information compared to p2""" | 2841 """dump copy information compared to p2""" |
2842 | 2842 |
2843 opts = pycompat.byteskwargs(opts) | 2843 ctx = scmutil.revsingle(repo, opts.get('rev'), default=None) |
2844 ctx = scmutil.revsingle(repo, opts.get(b'rev'), default=None) | |
2845 for dst, src in ctx.p2copies().items(): | 2844 for dst, src in ctx.p2copies().items(): |
2846 ui.write(b'%s -> %s\n' % (src, dst)) | 2845 ui.write(b'%s -> %s\n' % (src, dst)) |
2847 | 2846 |
2848 | 2847 |
2849 @command( | 2848 @command( |