jsonbatch-file

Parse and store text from a json file in windows batch script


I have a json file with the following contents

{"STATUS":"PASS","PASSRATE":96.95238}

I want to store the passrate so that I can use it to append to a filename.


Solution

  • Check jsonextractor.bat with which you can extract information from json file by given dot notated path to object:

    jsonextractor.bat data.json PASSRATE