Mercurial > hg
diff hgext/largefiles/overrides.py @ 46368:bb3a5c0df06b
purge: move extension into core mercurial
The motivation is simple: it's nicer to avoid gating basic
functionality.
To reduce the risk of people shooting themselves in the feet, `--confirm` is now
the default, unless the extensions is loaded..
For review of the body of the purge command, use this instead of what
hg/phabricator will show (the block of code is modified, not just
moved):
Differential Revision: https://phab.mercurial-scm.org/D9820
author | Valentin Gatien-Baron <valentin.gatienbaron@gmail.com> |
---|---|
date | Mon, 18 Jan 2021 10:24:20 +0100 |
parents | 4b89cf08d8dc |
children | d67732a4b58a |
line wrap: on
line diff
--- a/hgext/largefiles/overrides.py Mon Jan 18 10:24:11 2021 +0100 +++ b/hgext/largefiles/overrides.py Mon Jan 18 10:24:20 2021 +0100 @@ -1567,7 +1567,7 @@ # Calling purge with --all will cause the largefiles to be deleted. # Override repo.status to prevent this from happening. -@eh.wrapcommand(b'purge', extension=b'purge') +@eh.wrapcommand(b'purge') def overridepurge(orig, ui, repo, *dirs, **opts): # XXX Monkey patching a repoview will not work. The assigned attribute will # be set on the unfiltered repo, but we will only lookup attributes in the