diff --git a/mediafire_cdxprocessor.py b/mediafire_cdxprocessor.py index 1ba0a6b..000f126 100644 --- a/mediafire_cdxprocessor.py +++ b/mediafire_cdxprocessor.py @@ -22,6 +22,10 @@ def run_cdxsummary(file_path, json_filepath): # Add "cdxcount" entry with value 1 json_output["cdxcount"] = 1 + # Add "cdxsize" entry with the size of the cdx.gz file in bytes + cdx_size_bytes = os.path.getsize(file_path) + json_output["cdxsize"] = cdx_size_bytes + # Remove "pathquery" and "samples" keys if "pathquery" in json_output: del json_output["pathquery"]