title: Detached HEAD w/Jenkins Git Plugin and Branch Specifier
body: <p>Jenkins v2.19</p>
  
  <p>Git Plugin v2.5.3</p>
  
  <p>Under Branches to Build I am specifying 2 branches:</p>
  
  <pre><code>*/develop
  </code></pre>
  
  <p>and</p>
  
  <pre><code>*/master
  </code></pre>
  
  <p>This results in a <code>HEAD detached at {git commit hash}</code>.  I have different actions in my gradle build scripts that use the current git branch as a trigger to take different actions.</p>
  
  <p>How can I make this checkout develop to develop and master to master rather than a detached HEAD?</p>