title: Sha256 hash of a zip file is different after git commit despite archive contents not changing?
body: <p>I'm using git archive to export source code from a certain project folder <code>src</code> in a repository in order to calculate its combined sha256 hash like so:</p>
  
  <pre><code>git archive HEAD --worktree-attributes -o project-archive.zip src/
  sha256sum project-archive.zip | awk '{ print $1 }' &gt; project-archive.zip.hash
  </code></pre>
  
  <p>My git attributes file lives at the root of the project and looks a bit like so:</p>
  
  <pre><code>integration_tests/ export-ignore
  src/unit_tests export-ignore
  src/.* export-ignore
  .git* export-ignore
  .config.yml export-ignore
  *.md export-ignore
  </code></pre>
  
  <p>This works well for calculating the hash of my source but I'm finding that modifications to project files that aren't being included in the archive, such as <code>.config.yml</code> and <code>integration_tests/foo.py</code> still modify the hash of the archive. </p>
  
  <ul>
  <li><p>There aren't any erroneous files in the archive itself.</p></li>
  <li><p>The sha256 hash of each of the <code>.py</code> files is unchanged.</p></li>
  <li><p>I only see these changes to the archive hash after I've commited the
  unrelated (unarchived) changes, so I believe this to be a git behaviour or a misunderstanding of the
  git attributes config on my part.</p></li>
  </ul>
  
  <p>Presumably there is some git metadata on the source files that I don't know about that effects the archive hash?</p>