improve csv saving to use one file