title: Argo stop workflow early, mark complete
body: <p>Imagine I have a workflow with 5 steps.</p>
  <p>Step 2 may or may not create a file as its output (which is then used as input to subsequent steps).</p>
  <ul>
  <li>If the file is created, I want to run the subsequent steps.</li>
  <li>If no file gets created in step 2, I want to mark the workflow as completed and not execute steps 3 through to 5.</li>
  </ul>
  <p>I'm sure there must be a simple way to do this yet I'm failing to figure out how.</p>
  <p>I tried by making step 2 return non-zero exit code when no file is created and then using
  <code>when: &quot;{{steps.step2.outputs.exitCode}} == 0&quot;</code> on step 3, but that still executes step 4 and 5 (not to mention marks step 2 as &quot;failed&quot;)</p>
  <p>So I'm out of ideas, any suggestions are greatly appreciated.</p>