Patchwork [08,of,10] repair: use cg?unpacker.apply() instead of changegroup.addchangegroup()

login
register
mail settings
Submitter Augie Fackler
Date Oct. 14, 2015, 5:34 p.m.
Message ID <7c28bf6a7317b0643dda.1444844073@augie-macbookair2.roam.corp.google.com>
Download mbox | patch
Permalink /patch/11056/
State Accepted
Headers show

Comments

Augie Fackler - Oct. 14, 2015, 5:34 p.m.
# HG changeset patch
# User Augie Fackler <augie@google.com>
# Date 1444770766 14400
#      Tue Oct 13 17:12:46 2015 -0400
# Node ID 7c28bf6a7317b0643ddabfb4746fee3f5e951d4b
# Parent  d823ab4639e3f7a1bb21786e98ff0e0866e6521b
repair: use cg?unpacker.apply() instead of changegroup.addchangegroup()

Patch

diff --git a/mercurial/repair.py b/mercurial/repair.py
--- a/mercurial/repair.py
+++ b/mercurial/repair.py
@@ -197,9 +197,7 @@  def strip(ui, repo, nodelist, backup=Tru
                 finally:
                     tr.release()
             else:
-                changegroup.addchangegroup(repo, gen, 'strip',
-                                           'bundle:' + vfs.join(chgrpfile),
-                                           True)
+                gen.apply(repo, 'strip', 'bundle:' + vfs.join(chgrpfile), True)
             if not repo.ui.verbose:
                 repo.ui.popbuffer()
             f.close()
@@ -310,4 +308,3 @@  def stripbmrevset(repo, mark):
                      "ancestors(head() and not bookmark(%s)) - "
                      "ancestors(bookmark() and not bookmark(%s))",
                      mark, mark, mark)
-