Re: [PATCH] mingw: skip symlink type auto-detection for network share targets
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Jul 28, 2026, 22:45 UTC
- Message-ID
- <xmqqcxw6d98x.fsf@gitster.g>
- In-Reply-To
- <pull.2189.git.1785239196007.gitgitgadget@gmail.com>
"Johannes Schindelin via GitGitGadget" <gitgitgadget@gmail.com> writes:
Show 16 quoted lines
> From: Johannes Schindelin <johannes.schindelin@gmx.de> > > On Windows, symbolic links come in two flavors: file symlinks and > directory symlinks. Since Git was born on Linux where this distinction > does not exist, Git for Windows has to auto-detect the type by looking > at the target. When the target does not yet exist at symlink creation > time, Git for Windows creates a "phantom" file symlink and later, once > checkout is complete, calls `CreateFileW()` on the target to check > whether it is actually a directory. > ... > Note that there are legitimate paths starting with a single backslash > that are _not_ network paths: drive-less absolute paths are interpreted > as relative to the current working directory's drive. In practice, these > are highly uncommon (and brittle, just one working directory change away > from breaking). In any case, the only consequence is now that the > symlink type of those has to be specified via Git attributes, is all.
Thanks, will queue.