title: Windows bash script to run something from WSL
body: <p>I am trying to write down a Windows bash script to:</p>
  
  <ol>
  <li>Start Windows Subsystem for Linux (WSL) and</li>
  <li>cd within WSL to "../myfolder/"</li>
  <li>run <code>./foo first_parameter second_parameter</code></li>
  <li>Wait until finished and exit WSL</li>
  <li>cd within Windows to "../myWinFolder/"</li>
  <li>run <code>Foo.exe parameter</code></li>
  <li>wait until finished</li>
  </ol>
  
  <p>This is my attempt:</p>
  
  <pre><code>bash -c "cd ../myFolder/ &amp;&amp; ./foo first_parameter second_parameter"
  cd ..
  cd myWinFolder
  START /WAIT Foo.exe parameter
  </code></pre>
  
  <p>But sadly CMD does not wait for WSL to finish before running the EXE.</p>
  
  <p>Anything I can do?</p>