title: How to use GIT commands (diff, log, etc.) in Groovy script (windows)
body: <p>I just started learning DevOps and have a query. It might be very basic so please don't mind.</p>
  
  <p>Setup:
  Jenkins, GIT, Groovy, Java are installed on single windows server.</p>
  
  <p>My Goal is to write a Groovy script which will do following:
  1. Execute GIT commands (on local GIT repository) to pull some data (result).
  2. Take further actions based on above result.</p>
  
  <p>Query: How to execute GIT commands in Groovy script? What all is needed? Would be great if someone can please share a sample basic script.</p>