Re: [PATCH 6/5] NUL hack to create_file()
From: Daniel Barkalow <hidden>
Date: 2016-06-15 22:44:39
On Thu, 29 May 2008, Brian Dessent wrote:
Daniel Barkalow wrote:quoted
support it in git. Of course, people on Windows using projects with these filenames will probably run into problems with other tools, but at least git will behave properly.I don't see how it would help to have core git using the Native syntax to bypass the Win32 layer's restrictions but none of the accompanying suite of tools, i.e. the dozens of various MSYS sh.exe, perl.exe, cat.exe, etc. None of those would be able to open or even delete those files with the reserved filenames. Users tend to get upset when software creates files that cannot be removed through conventional methods, e.g. Explorer is completely powerless to remove it. Cygwin shipped with a bug several years ago that unintentionally allowed to create (but not unlink) reserved filenames. Unless you knew the magical incantation of "del \\.\c:\path\to\nul" the file was immutable.
Well, "git rm <filename>" would work. Or "git mv <weird> <okay>", which is possibly more productive. Or checking out a version that doesn't contain it. It's a lot worse if the tool that created it can't remove it than if tools other than the one that created it can't deal with it. -Daniel *This .sig left intentionally blank*