title: git-archive vs. cp
body: <p>What is the advantage of using</p>
  
  <pre><code>git archive master/foo | tar -x -C ~/destination
  </code></pre>
  
  <p>to deploy a copy of <em>/foo</em> <strong>vs.</strong> just copying from the the working copy with</p>
  
  <pre><code>cp foo ~/destination/foo
  </code></pre>
  
  <hr>
  
  <p>So, unless for some reason you don't want to copy everything over from that sub directory foo in master (or whatever branch you happening to be working on), using cp for deploying to a [destination] would suffice.</p>