4075 ui, repo, run=run, optimize=set(optimize), backup=backup, **opts |
4075 ui, repo, run=run, optimize=set(optimize), backup=backup, **opts |
4076 ) |
4076 ) |
4077 |
4077 |
4078 |
4078 |
4079 @command( |
4079 @command( |
|
4080 b'debug::unbundle', |
|
4081 [ |
|
4082 ( |
|
4083 b'u', |
|
4084 b'update', |
|
4085 None, |
|
4086 _(b'update to new branch head if changesets were unbundled'), |
|
4087 ) |
|
4088 ], |
|
4089 _(b'[-u] FILE...'), |
|
4090 helpcategory=command.CATEGORY_IMPORT_EXPORT, |
|
4091 ) |
|
4092 def debugunbundle(ui, repo, *args, **kwargs): |
|
4093 """same as `hg unbundle`, but pretent to come from a push |
|
4094 |
|
4095 This is useful to debug behavior and performance change in this case. |
|
4096 """ |
|
4097 from . import commands # avoid cycle |
|
4098 |
|
4099 unbundle = cmdutil.findcmd(b'unbundle', commands.table)[1][0] |
|
4100 return unbundle(ui, repo, *args, _unbundle_source=b'push', **kwargs) |
|
4101 |
|
4102 |
|
4103 @command( |
4080 b'debugwalk', cmdutil.walkopts, _(b'[OPTION]... [FILE]...'), inferrepo=True |
4104 b'debugwalk', cmdutil.walkopts, _(b'[OPTION]... [FILE]...'), inferrepo=True |
4081 ) |
4105 ) |
4082 def debugwalk(ui, repo, *pats, **opts): |
4106 def debugwalk(ui, repo, *pats, **opts): |
4083 """show how files match on given patterns""" |
4107 """show how files match on given patterns""" |
4084 m = scmutil.match(repo[None], pats, pycompat.byteskwargs(opts)) |
4108 m = scmutil.match(repo[None], pats, pycompat.byteskwargs(opts)) |