diff -r 63dfaca9087f -r 135056e8b5a8 hgext/purge.py --- a/hgext/purge.py Mon May 11 18:45:45 2020 -0400 +++ b/hgext/purge.py Mon Jan 18 10:24:03 2021 +0100 @@ -61,6 +61,7 @@ b' (implies -p/--print)' ), ), + (b'', b'confirm', None, _(b'ask before permanently deleting files')), ] + cmdutil.walkopts, _(b'hg purge [OPTION]... [DIR]...'), @@ -113,6 +114,7 @@ removefiles = opts.get(b'files') removedirs = opts.get(b'dirs') + confirm = opts.get(b'confirm') if not removefiles and not removedirs: removefiles = True @@ -129,6 +131,7 @@ removefiles=removefiles, abortonerror=opts.get(b'abort_on_err'), noop=not act, + confirm=confirm, ) for path in paths: