mercurial/commands.py
changeset 654 fafc16f705b6
parent 643 c9e159bb9a3d
child 667 31a9aa890016
equal deleted inserted replaced
653:94cdd02792b5 654:fafc16f705b6
   386     abspath = source
   386     abspath = source
   387     source = ui.expandpath(source)
   387     source = ui.expandpath(source)
   388     other = hg.repository(ui, source)
   388     other = hg.repository(ui, source)
   389 
   389 
   390     if other.dev() != -1 and os.stat(dest).st_dev == other.dev():
   390     if other.dev() != -1 and os.stat(dest).st_dev == other.dev():
   391         ui.status("cloning by hardlink\n")
   391         ui.note("cloning by hardlink\n")
   392         util.system("cp -al '%s'/.hg '%s'/.hg" % (source, dest))
   392         util.system("cp -al '%s'/.hg '%s'/.hg" % (source, dest))
   393         try:
   393         try:
   394             os.remove(os.path.join(dest, ".hg", "dirstate"))
   394             os.remove(os.path.join(dest, ".hg", "dirstate"))
   395         except: pass
   395         except: pass
   396 
   396