diff --git a/hgext/convert/__init__.py b/hgext/convert/__init__.py --- a/hgext/convert/__init__.py +++ b/hgext/convert/__init__.py @@ -95,7 +95,8 @@ def convert(ui, src, dest=None, revmapfi "svn://repo/path/tags" exists, it is looked for tags referencing converted branches. Default "trunk", "branches" and "tags" values can be overriden with following options. Set them to paths - relative to the source URL. + relative to the source URL, or leave them blank to disable + autodetection. --config convert.svn.branches=branches (directory name) specify the directory containing branches diff --git a/hgext/convert/subversion.py b/hgext/convert/subversion.py --- a/hgext/convert/subversion.py +++ b/hgext/convert/subversion.py @@ -236,6 +236,8 @@ class svn_source(converter_source): def getcfgpath(name, rev): cfgpath = self.ui.config('convert', 'svn.' + name) + if cfgpath is not None and cfgpath.strip() == '': + return None path = (cfgpath or name).strip('/') if not self.exists(path, rev): if cfgpath: @@ -342,6 +344,9 @@ class svn_source(converter_source): def gettags(self): tags = {} + if self.tags is None: + return tags + start = self.revnum(self.head) try: for entry in get_log(self.url, [self.tags], 0, start): diff --git a/tests/test-convert.out b/tests/test-convert.out --- a/tests/test-convert.out +++ b/tests/test-convert.out @@ -84,7 +84,8 @@ Convert a foreign SCM repository to a Me "svn://repo/path/tags" exists, it is looked for tags referencing converted branches. Default "trunk", "branches" and "tags" values can be overriden with following options. Set them to paths - relative to the source URL. + relative to the source URL, or leave them blank to disable + autodetection. --config convert.svn.branches=branches (directory name) specify the directory containing branches