Patchwork D1180: convert: register missed subversion config items

login
register
mail settings
Submitter phabricator
Date Oct. 18, 2017, 10:14 p.m.
Message ID <differential-rev-PHID-DREV-7cyyt2epuhtrwqfyomlv-req@phab.mercurial-scm.org>
Download mbox | patch
Permalink /patch/25216/
State Superseded
Headers show

Comments

phabricator - Oct. 18, 2017, 10:14 p.m.
durin42 created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.

REVISION SUMMARY
  Should fix the build failures on the Solaris builders.

REPOSITORY
  rHG Mercurial

REVISION DETAIL
  https://phab.mercurial-scm.org/D1180

AFFECTED FILES
  hgext/convert/__init__.py
  hgext/convert/subversion.py

CHANGE DETAILS




To: durin42, #hg-reviewers
Cc: mercurial-devel
phabricator - Oct. 18, 2017, 10:20 p.m.
martinvonz accepted this revision.
martinvonz added a comment.
This revision is now accepted and ready to land.


  Thanks for fixing!

REPOSITORY
  rHG Mercurial

REVISION DETAIL
  https://phab.mercurial-scm.org/D1180

To: durin42, #hg-reviewers, martinvonz
Cc: martinvonz, mercurial-devel

Patch

diff --git a/hgext/convert/subversion.py b/hgext/convert/subversion.py
--- a/hgext/convert/subversion.py
+++ b/hgext/convert/subversion.py
@@ -352,8 +352,10 @@ 
                 raise error.Abort(_('svn: revision %s is not an integer') %
                                  revs[0])
 
-        self.trunkname = self.ui.config('convert', 'svn.trunk',
-                                        'trunk').strip('/')
+        trunkcfg = self.ui.config('convert', 'svn.trunk')
+        if trunkcfg is None:
+            trunkcfg = 'trunk'
+        self.trunkname = trunkcfg.strip('/')
         self.startrev = self.ui.config('convert', 'svn.startrev')
         try:
             self.startrev = int(self.startrev)
diff --git a/hgext/convert/__init__.py b/hgext/convert/__init__.py
--- a/hgext/convert/__init__.py
+++ b/hgext/convert/__init__.py
@@ -112,6 +112,15 @@ 
 configitem('convert', 'svn.debugsvnlog',
     default=True,
 )
+configitem('convert', 'svn.trunk',
+    default=None,
+)
+configitem('convert', 'svn.tags',
+    default=None,
+)
+configitem('convert', 'svn.branches',
+    default=None,
+)
 configitem('convert', 'svn.startrev',
     default=0,
 )