Mercurial > public > mercurial-scm > hg-stable
comparison mercurial/debugcommands.py @ 50975:8f25df137282
debugrevlog: migrate `opts` to native kwargs
author | Matt Harbison <matt_harbison@yahoo.com> |
---|---|
date | Mon, 21 Aug 2023 17:35:13 -0400 |
parents | 7ef74fc79900 |
children | 56a966bc6b1a |
comparison
equal
deleted
inserted
replaced
50974:7ef74fc79900 | 50975:8f25df137282 |
---|---|
3208 _(b'-c|-m|FILE'), | 3208 _(b'-c|-m|FILE'), |
3209 optionalrepo=True, | 3209 optionalrepo=True, |
3210 ) | 3210 ) |
3211 def debugrevlog(ui, repo, file_=None, **opts): | 3211 def debugrevlog(ui, repo, file_=None, **opts): |
3212 """show data and statistics about a revlog""" | 3212 """show data and statistics about a revlog""" |
3213 opts = pycompat.byteskwargs(opts) | 3213 r = cmdutil.openrevlog( |
3214 r = cmdutil.openrevlog(repo, b'debugrevlog', file_, opts) | 3214 repo, b'debugrevlog', file_, pycompat.byteskwargs(opts) |
3215 | 3215 ) |
3216 if opts.get(b"dump"): | 3216 |
3217 if opts.get("dump"): | |
3217 revlog_debug.dump(ui, r) | 3218 revlog_debug.dump(ui, r) |
3218 else: | 3219 else: |
3219 revlog_debug.debug_revlog(ui, r) | 3220 revlog_debug.debug_revlog(ui, r) |
3220 return 0 | 3221 return 0 |
3221 | 3222 |