branchcache: use an explicit class for the v2 version
This prepare the introduction of an experimental v3 format version.
In the process, we move the description of the format in that new class.
#!/usr/bin/env python3
#
# A tool to help producing large and poorly compressible files
#
# Usage:
# $TESTDIR/seq.py 1000 | $TESTDIR/sha256line.py > my-file.txt
import hashlib
import sys
for line in sys.stdin:
print(hashlib.sha256(line.encode('utf8')).hexdigest())