-
-
Save doitian/3e007b3089114080ce614d6df7020f68 to your computer and use it in GitHub Desktop.
git shim for WSL
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Check if the current directory starts with /mnt/ | |
if pwd -P | grep -q "^/mnt/"; then | |
# Use git.exe for directories under /mnt/ | |
exec git.exe "$@" | |
else | |
# Use /usr/bin/git for other directories | |
exec /usr/bin/git "$@" | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment