I had the same reaction!... but just tested it and lo and behold it works!
[user@user ~]# cat > ~/bin/git-test-me <<'EOF'
#!/bin/bash
echo hi
EOF
[user@user ~]# chmod +x ~/bin/git-test-me
[user@user ~]# git test-me
hi