Skip to content

Commit 6cdfb25

Browse files
committed
Make it easier to see extensions in json filenames
1 parent a369f7e commit 6cdfb25

1 file changed

Lines changed: 6 additions & 1 deletion

File tree

scripts/process_eessi_software_metadata.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -317,7 +317,12 @@ def main():
317317
for key in full_software_information.keys():
318318
json_metadata = copy.deepcopy(base_json_metadata)
319319
json_metadata["software"] = full_software_information[key]
320-
with open(f"{output_stub}_{key}.json", "w") as out:
320+
if "key" == "software":
321+
file_suffix = key
322+
else:
323+
# everything else is some kind of extension
324+
file_suffix = "ext-" + key
325+
with open(f"{output_stub}_{file_suffix}.json", "w") as out:
321326
json.dump(json_metadata, out)
322327

323328
print(f"Successfully processed {input_file} to {output_stub}*.json")

0 commit comments

Comments
 (0)