title: Using 'Credentials Binding Plugin' in Jenkins, provide password for keystore to use with jarsigner?
body: <p>I have an <code>Android</code> project, being packaged into a <code>.apk</code>. And now I want to sign the artifact as a step in jenkins with no human intervention. But I dont understand how to supply the actual password?</p>
  
  <p>First, I uploaded <code>my.keystore</code> to <code>Jenkins -&gt; Manage Credentials -&gt; Secret file</code>.</p>
  
  <p>Then configured my job to:</p>
  
  <ul>
  <li><code>Use secret text(s) or file(s)</code></li>
  <li>Set <code>Variable</code> to be <code>mVar</code></li>
  <li>Set <code>Specific credentials</code> to <code>my.keystore</code></li>
  </ul>
  
  <p>Added an <code>Execute Shell</code> to <code>echo "$myVar"</code> and the value printed is something like:</p>
  
  <pre><code>+ echo /Users/Shared/Jenkins/Home/secretFiles/1f737ec7-c437-4005-8577-5b28edf158e4/my.keystore
  /Users/Shared/Jenkins/Home/secretFiles/1f737ec7-c437-4005-8577-5b28edf158e4/my.keystore
  </code></pre>
  
  <p>This is how I manually sign the <code>.apk</code> ..</p>
  
  <pre><code>osx:~ jenkins$ jarsigner -verbose -sigalg SHA1withRSA -digestalg SHA1 -keystore my.keystore /Users/Shared/Jenkins/Home/jobs/myProject/workspace/build/outputs/apk/android-release-unsigned.apk myKeystore
  </code></pre>