--- ./hgext/convert/__init__.py.orig 2014-08-01 23:22:55.000000000 +0000 +++ ./hgext/convert/__init__.py 2014-08-17 09:14:36.000000000 +0000 @@ -27,6 +27,7 @@ ('d', 'dest-type', '', _('destination repository type'), _('TYPE')), ('r', 'rev', '', _('import up to source revision REV'), _('REV')), ('A', 'authormap', '', _('remap usernames using this file'), _('FILE')), + ('', 'authormapsuffix', '', _('append this suffix to remapped author names'), _('SUFFIX')), ('', 'filemap', '', _('remap file names using contents of file'), _('FILE')), ('', 'splicemap', '', _('splice synthesized history into place'), --- ./hgext/convert/convcmd.py.orig 2014-08-01 23:22:55.000000000 +0000 +++ ./hgext/convert/convcmd.py 2014-08-02 06:58:26.000000000 +0000 @@ -103,12 +103,15 @@ self.commitcache = {} self.authors = {} self.authorfile = None + self.authormapsuffix = '' # Record converted revisions persistently: maps source revision # ID to target revision ID (both strings). (This is how # incremental conversions work.) self.map = mapfile(ui, revmapfile) + if opts.get('authormapsuffix'): + self.authormapsuffix = opts.get('authormapsuffix') # Read first the dst author map if any authorfile = self.dest.authorfile() if authorfile and os.path.exists(authorfile): @@ -360,7 +363,7 @@ continue srcauthor = srcauthor.strip() - dstauthor = dstauthor.strip() + dstauthor = dstauthor.strip() + self.authormapsuffix if self.authors.get(srcauthor) in (None, dstauthor): msg = _('mapping author %s to %s\n') self.ui.debug(msg % (srcauthor, dstauthor)) @@ -374,7 +377,7 @@ def cachecommit(self, rev): commit = self.source.getcommit(rev) - commit.author = self.authors.get(commit.author, commit.author) + commit.author = self.authors.get(commit.author, commit.author + self.authormapsuffix) # If commit.branch is None, this commit is coming from the source # repository's default branch and destined for the default branch in the # destination repository. For such commits, passing a literal "None"