Mercurial > hgsubversion
changeset 973:21197f5ee9de stable
expand configured paths
author | Dan Villiom Podlaski Christiansen <danchr@gmail.com> |
---|---|
date | Wed, 14 Dec 2011 00:07:57 +0100 |
parents | 109c412ecf12 |
children | 336f4bce479a |
files | hgsubversion/svnmeta.py hgsubversion/util.py |
diffstat | 2 files changed, 7 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/hgsubversion/svnmeta.py +++ b/hgsubversion/svnmeta.py @@ -48,13 +48,13 @@ class SVNMeta(object): self.revmap = maps.RevMap(repo) author_host = self.ui.config('hgsubversion', 'defaulthost', uuid) - authors = self.ui.config('hgsubversion', 'authormap') + authors = util.configpath(self.ui, 'authormap') tag_locations = self.ui.configlist('hgsubversion', 'tagpaths', ['tags']) self.usebranchnames = self.ui.configbool('hgsubversion', 'usebranchnames', True) - branchmap = self.ui.config('hgsubversion', 'branchmap') - tagmap = self.ui.config('hgsubversion', 'tagmap') - filemap = self.ui.config('hgsubversion', 'filemap') + branchmap = util.configpath(self.ui, 'branchmap') + tagmap = util.configpath(self.ui, 'tagmap') + filemap = util.configpath(self.ui, 'filemap') self.branches = {} if os.path.exists(self.branch_info_file):
--- a/hgsubversion/util.py +++ b/hgsubversion/util.py @@ -32,6 +32,9 @@ def formatrev(rev): return '\t(working copy)' return '\t(revision %d)' % rev +def configpath(ui, name): + path = ui.config('hgsubversion', name) + return path and hgutil.expandpath(path) def filterdiff(diff, oldrev, newrev): diff = newfile_devnull_re.sub(r'--- \1\t(revision 0)' '\n'