title: Is there a way to run a pre-checkout step in declarative Jenkins pipelines?
body: <p><a href="https://jenkins.io/doc/book/pipeline/syntax/" rel="noreferrer">Jenkins declarative pipelines</a> offer a <em>post</em> directive to execute code <em>after</em> the stages have finished. Is there a similar thing to run code <em>before</em> the stages are running, and most importantly, before the SCM checkout?</p>
  
  <p>For example something along the lines of:</p>
  
  <pre><code>pre {
      always {
          rm -rf ./*
      }
  }
  </code></pre>
  
  <p>This would then clean the workspace of my build before the source code is checked out.</p>