From: Konstantin Khomoutov Date: Thu, 04 Dec 2025 09:04:50 GMT Subject: Re: Copieing git repository to another disk is dangerous ! Especially in combination with remotes set to local repositories ! Message-ID: In-Reply-To: On Thu, Dec 04, 2025 at 03:59:19AM +0000, Skybuck Flying wrote: [...] > X: > cd X:\Vite\Repository\Mirror > git clone --mirror https://github.com/vitelabs/go-viteĀ . > > cd X:\Vite\Branch\Develop\Delphi > git clone -o Repository "X:\Vite\Repository\Mirror" . > > Now copy the contents of this disk to a new disk... (virtual disks) > git remote -v will show: > > X:\Vite\Repository\Mirror > > In other words the remote is still pointing to the mirror on disk X !!!! I do not understand the problem: the command git clone -o Repository "X:\Vite\Repository\Mirror" has cloned the repository "X:\Vite\Repository\Mirror", and so it is completely expected that re so-called "remote" to which you gave the name "Repository" records the URL of the remote repository it points at exactly as it has been provided by the user - with the drive letter in this case. If you do not want this behavior, you might consider using UNC paths or a reasonably recent (2010s, I think) addition to NTFS called "junction points" which allows you to mount an external drive "on" an empty filesysem folder - almost UNIX-way, so to speak ;-) See the "mountvol" console command and [1]. 1. https://serverfault.com/a/8871