diff --git a/hgext/convert/hg.py b/hgext/convert/hg.py --- a/hgext/convert/hg.py +++ b/hgext/convert/hg.py @@ -70,10 +70,10 @@ class mercurial_sink(converter_sink): self.wlock.release() def revmapfile(self): - return os.path.join(self.path, ".hg", "shamap") + return self.repo.join("shamap") def authorfile(self): - return os.path.join(self.path, ".hg", "authormap") + return self.repo.join("authormap") def getheads(self): h = self.repo.changelog.heads() @@ -364,8 +364,7 @@ class mercurial_source(converter_source) def converted(self, rev, destrev): if self.convertfp is None: - self.convertfp = open(os.path.join(self.path, '.hg', 'shamap'), - 'a') + self.convertfp = open(self.repo.join('shamap'), 'a') self.convertfp.write('%s %s\n' % (destrev, rev)) self.convertfp.flush() diff --git a/tests/test-convert-authormap.t b/tests/test-convert-authormap.t --- a/tests/test-convert-authormap.t +++ b/tests/test-convert-authormap.t @@ -27,7 +27,7 @@ Explicit --authors sorting... converting... 0 foo - Writing author map file new/.hg/authormap + Writing author map file $TESTTMP/new/.hg/authormap $ cat new/.hg/authormap user name=Long User Name $ hg -Rnew log @@ -44,7 +44,7 @@ Implicit .hg/authormap $ hg init new $ mv authormap.txt new/.hg/authormap $ hg convert orig new - Ignoring bad line in author map file new/.hg/authormap: this line is ignored + Ignoring bad line in author map file $TESTTMP/new/.hg/authormap: this line is ignored scanning source... sorting... converting...