Updated to use bash that should work on linux and cygwin