title: Git diff gives me a fatal: bad revision 'HEAD~1'
body: <p>I'm trying to check which files have changed previously in a github action. For this I'm running the following command:</p>
  
  <pre><code>git diff --name-only HEAD~1 -- .'
  </code></pre>
  
  <p>While this works locally, on github actions I seem to get this error:</p>
  
  <pre><code>fatal: bad revision 'HEAD~1'
  Checking if any files changed
  </code></pre>
  
  <p>I'm using the <a href="https://github.com/actions/checkout" rel="noreferrer">https://github.com/actions/checkout</a> action for doing the checkout.</p>