This change uses the 'quiet_report', so most of the time there is no output when the user specifies -j or'--json on the command line. A new structure was added, to encapsulate the report for list and pack, perhaps this can be done in a more elegant way.
Note: The main reason for adding this was for the purpose of automated testing.
Currently blk-archive outputs human readable output, some examples.
A pack:
A pack, re-directing stdout & stderr to a file which is different as the code has tty detection:
a list:
To make is easier to script blk-archive, having JSON output is helpful, eg.
This change uses the 'quiet_report', so most of the time there is no output when the user specifies
-j
or'--json
on the command line. A new structure was added, to encapsulate the report for list and pack, perhaps this can be done in a more elegant way.Note: The main reason for adding this was for the purpose of automated testing.