Why do you need to put #!/bin/bash at the beginning of a script file?
It’s a convention so the *nix shell knows what kind of interpreter to run. For example, older flavors of ATT defaulted to sh (the Bourne shell), while older versions of BSD defaulted to csh (the C shell). Even today (where most systems run bash, the “Bourne Again Shell”), scripts can be in bash, python, perl, … Read more