What is the syntax for specifying Windows paths in .gitconfig? What is the syntax for specifying Windows paths in .gitconfig? powershell powershell

What is the syntax for specifying Windows paths in .gitconfig?


Ok, figured this out. The trick is:

  1. Surround in double-quotes
  2. Convert backslashes to forward slashes.
  3. Begin with drive letter + colon for absolute paths

So the correct version of the above is:

[include]    path = "D:/Scott/Shared/config/common.gitconfig"


Based on output of pwd in git bash, I would speculate it is probably

/d/Scott/Shared/config/common.gitconfig