-
Make sure Windows leaves your line endings alone. This way you can still run shell scripts and things in Git Bash or WSL:
git config --global core.autocrlf input
-
Next, after committing any changes you do not have staged, run these:
git rm --cached -r .
git reset --hard
Now you can run shell scripts on Windows Git Bash and you won't have to worry about committing any CRLF files that will break in Docker.