You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
installer: work around misquoting in Git Bash Here
When calling `Git Bash Here` from the background of the `C:\` directory
in Windows Explorer, the term `%v` is expanded to the directory. To
allow for spaces in the directory name, we quote that directory when
passing the directory's path as `"--cd=%v"` parameter to `git-bash.exe`.
Unfortunately, the `CommandLineToArgvW()` function mistakes the last
part of `"--cd=C:\"` for a quoted double quote, and as a consequence
`CreateProcess()` fails because there is no `C:"` directory.
To work around this, let's just append `.`: this turns the parameter
into `"--cd=C:\."` which is correctly interpreted as `C:\.` directory.
It works also in the general case, where `%v` does *not* expand into a
path with a trailing backslash because on Windows, `<name>` and
`<name>.` refer to the same file.
This fixesgit-for-windows/git#176.
Signed-off-by: Johannes Schindelin <[email protected]>
0 commit comments