Shell Scripts on a Jenkins Windows Slave

Today a customer showed me how easy it is to write shell scripts on a windows slave.

If your customer uses GIT on windows, you have to install MsysGit. MsysGit includes git bash in it’s installation. Git bash lets run shell and bash scripts on windows.

How all of the above is related to Jenkins?

<font size=+1>Very easy!</font>

In the Jenkins main configuration page, you have a field to configure path to sh or bash for windows slave. You need to set it the the MsysGit path (for example: C:\msysgit\msysgit\bin\sh.exe).


After you configure the right path, you can easily add “execute shell” build step to a job that runs on windows slave and it’ll work like a charm!

I’m sure that some of you already knows that but for others who have struggled for years with writing batch scripts for windows, this a life saver!



Thank you for your interest!

We will contact you as soon as possible.

Send us a message

Oops, something went wrong
Please try again or contact us by email at