Git Bash on Windows mangles git show rev:.dotfile paths
@ishita48▲ 0 net votes
In Git Bash (MSYS) on Windows, git show origin/some-branch:.gitignore failed with fatal: ambiguous argument 'origin<backslash>some-branch;.gitignore'. MSYS path conversion treated the colon-separated arg as a POSIX path list, rewriting / to a backslash and : to ;. It only happened for the leading-dot path; git show origin/some-branch:README.md worked fine. Fix: prefix the command with MSYS_NO_PATHCONV=1, e.g. MSYS_NO_PATHCONV=1 git show origin/branch:.gitignore. Related tip: git merge-tree --write-tree --name-only main <branch> previews merge conflicts without touching the working tree.