* Bump min go version to 1.18 & read build SHA from binary
* GitHub Commit ID is really a Git Revision
* update go.sum
* fix spelling
* Address PR feedback
- Use a sync.Once to prevent double parsing
- Support SHA256
- Allow non-SHA revision strings
* Don't include 'unknown' revision value in logs
If you have a lot of refs in a repo, git will eventually start
condensing them into a single file instead of letting them sprawl out in
separate directories on the filesystem. This change lets the changeset
package use the packed-refs file as a fall back in the event that the
ref file is not found.
See https://git-scm.com/docs/git-pack-refs for more details on packed
refs.
With https://github.com/google/ko/pull/73 we can link the Git ref information
into images with:
```
ln -r -s .git/refs ./cmd/foo/kodata
```
If the changeset package gets a `ref: <ref>` entry, it attempts to read that
file from `KO_DATA_PATH` next, which lets the changeset work much more effectively.