title: How would you include the current commit id in a Git project's files?
body: <p>I've got an open source static JavaScript + HTML application that's deployed in about three different places right now, one on my local machine, one on an internal server, and one on a stable external server.</p>
  
  <p>I'd like to be able to tell immediately which version is deployed in which place, and I'd like bug reporters to have easy access to the version that they're reporting the bug on.</p>
  
  <p>Ideally I'd like, as part of the commit process, for a file to be written with the hash of the commit. Of course, from what I know of Git this is impossible, as including the calculated hash as part of a file in a commit would change the calculated hash of that commit.</p>
  
  <p>On the other hand, I could incorporate building this as part of a build process. I don't currently have a build process though, and I'd like to avoid adding a step if possible.</p>
  
  <p>What's the cleanest way to do this?</p>