mercurial/subrepo.py
branchstable
changeset 13105 2245fcd0e160
parent 13017 d0e21c5fde41
child 13117 594ed85b6a3f
child 13122 4a13ca2c21ce
equal deleted inserted replaced
13103:6e79a3bb8c79 13105:2245fcd0e160
   331             fp = self._repo.opener("hgrc", "w", text=True)
   331             fp = self._repo.opener("hgrc", "w", text=True)
   332             fp.write('[paths]\n')
   332             fp.write('[paths]\n')
   333 
   333 
   334             def addpathconfig(key, value):
   334             def addpathconfig(key, value):
   335                 if value:
   335                 if value:
       
   336                     if not os.path.isabs(value):
       
   337                         value = os.path.relpath(os.path.abspath(value), root)
   336                     fp.write('%s = %s\n' % (key, value))
   338                     fp.write('%s = %s\n' % (key, value))
   337                     self._repo.ui.setconfig('paths', key, value)
   339                     self._repo.ui.setconfig('paths', key, value)
   338 
   340 
   339             defpath = _abssource(self._repo, abort=False)
   341             defpath = _abssource(self._repo, abort=False)
   340             defpushpath = _abssource(self._repo, True, abort=False)
   342             defpushpath = _abssource(self._repo, True, abort=False)