# HG changeset patch # User Matt Harbison # Date 1342822399 14400 # Node ID 8c31b652bdfe25f17394d67a4b0a260e31f5b651 # Parent 979b107eaea2497d902af98ef6f3a46d2253be4a largefiles: support revsets for revert Previous to this, revert only accepted revsets if the largefiles extension was disabled. diff -r 979b107eaea2 -r 8c31b652bdfe hgext/largefiles/overrides.py --- a/hgext/largefiles/overrides.py Wed Jul 25 16:40:38 2012 +0900 +++ b/hgext/largefiles/overrides.py Fri Jul 20 18:13:19 2012 -0400 @@ -567,7 +567,7 @@ os.unlink(repo.wjoin(lfutil.standin(lfile))) try: - ctx = repo[opts.get('rev')] + ctx = scmutil.revsingle(repo, opts.get('rev')) oldmatch = None # for the closure def overridematch(ctx, pats=[], opts={}, globbed=False, default='relpath'): diff -r 979b107eaea2 -r 8c31b652bdfe tests/test-largefiles.t --- a/tests/test-largefiles.t Wed Jul 25 16:40:38 2012 +0900 +++ b/tests/test-largefiles.t Fri Jul 20 18:13:19 2012 -0400 @@ -869,6 +869,8 @@ reverting .hglf/sub2/large6 (glob) $ cat sub2/large6 large6 + $ hg revert --no-backup -C -r '.^' sub2 + reverting .hglf/sub2/large6 (glob) $ hg revert --no-backup sub2 reverting .hglf/sub2/large6 (glob) $ hg status