tests/sha256line.py
author Arseniy Alekseyev <aalekseyev@janestreet.com>
Fri, 05 Apr 2024 17:57:26 +0100
changeset 51603 a2afa35641c9
parent 51361 fa4c4fa232d6
permissions -rwxr-xr-x
matchers: support patternmatcher in rust

#!/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())