I have multiple files with the
json extension in a directory. These are used to generate some other files but that should only happen if the
json files have changed.
So far I have the following measly script:
for %%f in (*.json) do ( echo %%f certutil -hashfile %%f SHA256 >> HASH.txt )
I loop through all the
json files, generate the SHA256 hash value for each and then append it to the
HASH.txt file using
certUitl. My problem comes from the output that tool returns namely (I have a German Win 10):
SHA256-Hash der Datei BLAH.json: d8338f6f2649bcb358e56e0973fe2f5a886771e0debbdb0fefef35976a1b88ca CertUtil: -hashfile-Befehl wurde erfolgreich ausgeführt.
I'd like to get my hands on the hash value. With the example above that would be
which is the second line of the output. I've searched for a solution how to get only a specific line of the output and skip the rest but all I can find was related to text files which doesn't seem to help much. Any ideas how to do that?