I am trying to understand why the script will work with #!/bin/bash but not #!/bin/sh. I am running Cygwin and both sh.exe and b
#!/bin/bash
#!/bin/sh
sh.exe
b
Despite being same file, shell analyzes its own name when run and switches to either plain shell or bash mode.