title: Why does checkout sometimes stage a file?
body: <p>When I first started using Git, I found the <code>checkout</code> command quite confusing. However, as I adapted to Git's model of version control, it started to make sense. Now I am having to teach Git to my coworkers, and I'm trying to explain <code>checkout</code> simply. I thought I had a simple explanation (from the <a href="http://git-scm.com/docs/git-checkout" rel="nofollow">documentation</a>):</p>
  
  <blockquote>
    <p>Checkout a branch or paths to the working tree</p>
  </blockquote>
  
  <p>That seems to unify some of the things you can do with checkout which seem like a diverse set of operations to someone new to Git:</p>
  
  <pre><code>git checkout .
  git checkout HEAD .
  git checkout HEAD~2
  git checkout feature/update-readme README.md
  </code></pre>
  
  <p>...except for the last one, because that doesn't just update the working directory, it stages the file.</p>
  
  <p>How can I understand why or when checkout out will result in having something staged instead of just copied into the working directory?</p>