$ cat /etc/install-options.txt
Editor Option: Notepad++
Custom Editor Path:
Default Branch Option: main
Path Option: Cmd
SSH Option: OpenSSH
Tortoise Option: false
CURL Option: OpenSSL
CRLF Option: CRLFAlways
Bash Terminal Option: MinTTY
Git Pull Behavior Option: Merge
Use Credential Manager: Core
Performance Tweaks FSCache: Enabled
Enable Symlinks: Disabled
Enable Pseudo Console Support: Disabled
Enable FSMonitor: Disabled
Originally asked this as StackOverflow question, but was told it might be a Git for Windows bug.
Related to the advice observed in #2438 (comment).
Setup
Which version of Git for Windows are you using? Is it 32-bit or 64-bit?
Which version of Windows are you running? Vista, 7, 8, 10? Is it 32-bit or 64-bit?
What options did you set as part of the installation? Or did you choose the
defaults?
Any other interesting things about your environment that might be related
to the issue you're seeing?
git config core.longpathsis not set (neither for system nor globally).Details
Which terminal/shell are you running Git from? e.g Bash/CMD/PowerShell/other
PowerShell, Git Bash
What commands did you run to trigger this issue? If you can provide a
Minimal, Complete, and Verifiable example
this will help us understand the issue.
git clone https://github.com/dependabot/dependabot-core --depth=1 file-name-testℹ️ Cloning fails due to "Filename too long"; Git suggests to run
git restore --source=HEAD :/cd file-name-testgit config core.longpaths truegit restore --source=HEAD :/git status❌ Changes are reported; running
git restorehad no effectWhat did you expect to occur after running these commands?
Either:
git restore --source=HEAD :/no changes should be reported anymoregit restore --source=HEAD :/if it would have no effectWhat actually happened instead?
Git suggested to run
git restore --source=HEAD :/; it had no effect.Note that checkout succeeds when running
git restore --source=HEAD -SW :/orgit reset --hard.If the problem was occurring with a specific repository, can you provide the
URL to that repository to help us with testing?
any repository with long file paths