sorting the hashmaps before writing to disk so that the order is preserved
for manual editing