[PATCH 1 of 2] convert: indentation change to make the next patch more legible

Laurent Charignon lcharignon at fb.com
Tue Nov 17 01:18:03 UTC 2015


# HG changeset patch
# User Laurent Charignon <lcharignon at fb.com>
# Date 1447722855 28800
#      Mon Nov 16 17:14:15 2015 -0800
# Node ID 3311e2750b7fdaac9c33089d0fab47b9718fd381
# Parent  2da6a2dbfc42bdec4bcaf47da947c64ff959a59c
convert: indentation change to make the next patch more legible

We put the code to be indented in the next patch in a "if True:" block to make
it easier to review.

diff --git a/hgext/convert/hg.py b/hgext/convert/hg.py
--- a/hgext/convert/hg.py
+++ b/hgext/convert/hg.py
@@ -410,12 +410,12 @@
     def putbookmarks(self, updatedbookmark):
         if not len(updatedbookmark):
             return
-
-        self.ui.status(_("updating bookmarks\n"))
-        destmarks = self.repo._bookmarks
-        for bookmark in updatedbookmark:
-            destmarks[bookmark] = bin(updatedbookmark[bookmark])
-        destmarks.write()
+        if True:
+            self.ui.status(_("updating bookmarks\n"))
+            destmarks = self.repo._bookmarks
+            for bookmark in updatedbookmark:
+                destmarks[bookmark] = bin(updatedbookmark[bookmark])
+            destmarks.write()
 
     def hascommitfrommap(self, rev):
         # the exact semantics of clonebranches is unclear so we can't say no


More information about the Mercurial-devel mailing list