--- a/hgext/fix.py Sat Mar 24 14:28:24 2018 -0400
+++ b/hgext/fix.py Fri Mar 30 16:40:25 2018 -0700
@@ -95,7 +95,8 @@
configitem('fix', 'maxfilesize', default='2MB')
@command('fix',
- [('', 'base', [], _('revisions to diff against (overrides automatic '
+ [('', 'all', False, _('fix all non-public non-obsolete revisions')),
+ ('', 'base', [], _('revisions to diff against (overrides automatic '
'selection, and applies to every revision being '
'fixed)'), _('REV')),
('r', 'rev', [], _('revisions to fix'), _('REV')),
@@ -125,6 +126,11 @@
revisions are not forgotten in later ones. The --base flag can be used to
override this default behavior, though it is not usually desirable to do so.
"""
+ if opts['all']:
+ if opts['rev']:
+ raise error.Abort(_('cannot specify both "--rev" and "--all"'))
+ opts['rev'] = ['not public() and not obsolete()']
+ opts['working_dir'] = True
with repo.wlock(), repo.lock():
revstofix = getrevstofix(ui, repo, opts)
basectxs = getbasectxs(repo, opts, revstofix)