shelve: make no_backup parameter passing python 2.4 compatible
authorDavid Soria Parra <dsp@experimentalworks.net>
Wed, 02 Oct 2013 09:50:21 +0200
changeset 19881 821a89018f17
parent 19876 7032dcff290c
child 19884 fc3fbca35085
shelve: make no_backup parameter passing python 2.4 compatible Python 2.4 doesn't allow passing named parameter after an list unpack, but allows to unpack a dict.
hgext/shelve.py
--- a/hgext/shelve.py	Mon Oct 07 17:47:55 2013 -0400
+++ b/hgext/shelve.py	Wed Oct 02 09:50:21 2013 +0200
@@ -352,7 +352,7 @@
             revertfiles = readshelvedfiles(repo, state.name)
             wctx = repo.parents()[0]
             cmdutil.revert(ui, repo, wctx, [wctx.node(), nullid],
-                           *revertfiles, no_backup=True)
+                           *revertfiles, **{'no_backup': True})
             # fix up the weird dirstate states the merge left behind
             mf = wctx.manifest()
             dirstate = repo.dirstate
@@ -514,7 +514,7 @@
                 revertfiles = set(parents[1].files()).difference(ms)
                 cmdutil.revert(ui, repo, parents[1],
                                (parents[0].node(), nullid),
-                               *revertfiles, no_backup=True)
+                               *revertfiles, **{'no_backup': True})
                 raise error.InterventionRequired(
                     _("unresolved conflicts (see 'hg resolve', then "
                       "'hg unshelve --continue')"))
@@ -523,7 +523,7 @@
             parent = tip.parents()[0]
             hg.update(repo, parent.node())
             cmdutil.revert(ui, repo, tip, repo.dirstate.parents(), *tip.files(),
-                           no_backup=True)
+                           **{'no_backup': True})
 
         prevquiet = ui.quiet
         ui.quiet = True