title: How to automate git-bash commands on windows machine?
body: <p>How to automate these commands in windows. Answer could be obvious <strong>".bat"</strong> file.</p>
  
  <p><strong>sample.bat</strong></p>
  
  <pre><code>C:\Program Files\Git\git-bash.exe
  cd c:\directory\
  eval $(ssh-agent -s) &amp;&amp; ssh-add "id_rsa"
  git clone repo
  </code></pre>
  
  <p>By doing this, a new bash window opens but i don't see these commands executing there.</p>
  
  <p>And also, how do i do this via jenkins as well (On windows slave) ?</p>
  
  <p><strong>Answer (As suggested by poke):</strong>
  Passing multiple arguments as well.</p>
  
  <pre><code>git-bash.exe -c "cd /c/dictionary; eval $(ssh-agent -s) &amp;&amp; ssh-add 'id_rsa'; git clone repo"
  </code></pre>