mercurial/hg.py
changeset 29765 e93408080646
parent 29645 3b4d69b3988d
child 29906 a77d48219edd
equal deleted inserted replaced
29764:8a8c1c4b8f24 29765:e93408080646
   257         fp = destrepo.vfs("hgrc", "w", text=True)
   257         fp = destrepo.vfs("hgrc", "w", text=True)
   258         fp.write("[paths]\n")
   258         fp.write("[paths]\n")
   259         fp.write("default = %s\n" % default)
   259         fp.write("default = %s\n" % default)
   260         fp.close()
   260         fp.close()
   261 
   261 
   262     if bookmarks:
   262     with destrepo.wlock():
   263         fp = destrepo.vfs('shared', 'w')
   263         if bookmarks:
   264         fp.write(sharedbookmarks + '\n')
   264             fp = destrepo.vfs('shared', 'w')
   265         fp.close()
   265             fp.write(sharedbookmarks + '\n')
       
   266             fp.close()
   266 
   267 
   267 def _postshareupdate(repo, update, checkout=None):
   268 def _postshareupdate(repo, update, checkout=None):
   268     """Maybe perform a working directory update after a shared repo is created.
   269     """Maybe perform a working directory update after a shared repo is created.
   269 
   270 
   270     ``update`` can be a boolean or a revision to update to.
   271     ``update`` can be a boolean or a revision to update to.