title: how to get submodules to trigger a Jenkins build
body: <p>I have a submodule A that is not a standalone application. It requires the main application for it to work. I would like to create a CI build for A so that whenever a commit is pushed to A it triggers a build with the main project code. </p>
  
  <p>How do I do that in Jenkins? </p>
  
  <p>What I need to do:</p>
  
  <ul>
  <li>A commit to A triggers a build.</li>
  <li>The build clones the Main project code and pulls the latest code for A at the latest commit for A (not the commit that the Main Project knows about). </li>
  </ul>
  
  <p>How would I do that using Jenkins and GIT? </p>
  
  <p>Note I have multiple submodules for the project. Submodule A triggers a build that pulls the latest changes from A and also the latest of main code and pulls updates from the other submodules.</p>