[PATCH 1 of 4] convert: add bookmark support to common sink/source implementation

Edouard Gomez ed.gomez at free.fr
Tue Jul 6 17:11:45 CDT 2010


# HG changeset patch
# User Edouard Gomez <ed.gomez at free.fr>
# Date 1278454019 -7200
# Node ID 040f2b92d9bc39e19688ab037c88d2d59a3e940a
# Parent  4a73a09801941c11bb91d15c291a970cfd281382
convert: add bookmark support to common sink/source implementation

diff --git a/hgext/convert/common.py b/hgext/convert/common.py
--- a/hgext/convert/common.py
+++ b/hgext/convert/common.py
@@ -151,6 +151,13 @@
         """
         return None
 
+    def getbookmarks(self):
+        """Return the bookmarks as a dictionary of name: revision
+
+        Bookmark names are to be UTF-8 strings.
+        """
+        return {}
+
 class converter_sink(object):
     """Conversion sink (target) interface"""
 
@@ -228,6 +235,12 @@
     def after(self):
         pass
 
+    def putbookmarks(self, bookmarks):
+        """Put bookmarks into sink.
+
+        bookmarks: {bookmarkname: sink_rev_id, ...} where bookmarkname is an UTF-8 string.
+        """
+        pass
 
 class commandline(object):
     def __init__(self, ui, command):


More information about the Mercurial-devel mailing list