title: Do manual build fail in Jenkins using shell script
body: <p>I would like to mark a Jenkins build to fail on one scenario for example: </p>
  
  <pre><code>if [ -f "$file" ]
  then
      echo "$file found."
  else
      echo "$file not found."
      #Do Jenkins Build Fail
  fi
  </code></pre>
  
  <p>Is it possible via Shell Script?</p>
  
  <p><strong>Answer:</strong> If we exit with integer 1, Jenkins build will be marked as failed.  So I replaced the comment with <code>exit 1</code> to resolve this.</p>