title: How do I get exit code of script run with mintty.exe?
body: <p>In Windows, I'm excecuting a bash script using Cygwin64 and mintty.exe, this way:</p>
  <p><code>mintty.exe -e C:\some_path\some_bash_script.sh</code></p>
  <p>I need to capture the script's errors but %ERRORLOVEL% is always 0, even when the script fails.</p>
  <p>How can I get the exit code of the bash script, when executed this way?</p>