in reply to Can I convince Git Bash to use a specific version of Perl

GNU bash (which is probably the shell bundled with Git on Windows) has a feature for emulating shebang lines, because some *nix systems simply ran all scripts through the shell. Most likely, the shell is looking at your file, finding "perl", searching its PATH for "perl", finding the one bundled with Git, and using it. It is also possible that Git itself may parse shebang lines on Windows.

I have also written Git pre-commit hooks in Perl in the past, and I have simply avoided using modules and stuck with the baseline language. What are you trying to do with this hook that needs modules?

  • Comment on Re: Can I convince Git Bash to use a specific version of Perl