From: Steven Penny Date: Sun, 18 Nov 2018 17:34:04 GMT Subject: Re: Cygwin Git with Windows paths Message-ID: In-Reply-To: <20181118171525.GA25854@tor.lan> On Sun, Nov 18, 2018 at 11:15 AM Torsten Bögershausen wrote: > But it may be that we need to pull in more stuff, similar to mingw, > to get the C: stuff working, see > "skip_dos_drive_prefix" > > And it may even be that we need a special handling for the "\" to be treated > as "/". > > If you implement "skip_dos_drive_prefix" similar to mingw, > (rename mingw into cygwin) does > > git clone C:/my/dir/ > work ? I added this to "compat/cygwin.h": #define has_dos_drive_prefix(path) \ (isalpha(*(path)) && (path)[1] == ':' ? 2 : 0) int mingw_skip_dos_drive_prefix(char **path); #define skip_dos_drive_prefix mingw_skip_dos_drive_prefix and added this to "compat/cygwin.c": int mingw_skip_dos_drive_prefix(char **path) { int ret = has_dos_drive_prefix(*path); *path += ret; return ret; } but still, these dont work: git clone C:/my/dir git clone 'C:\my\dir'