Generating generations of files

DL Neil PythonList at DancesWithMice.info
Mon Apr 29 19:24:19 EDT 2019


On 30/04/19 8:17 AM, MRAB wrote:
> On 2019-04-29 20:59, DL Neil wrote:
>> Are you aware of a library/utility which will generate and maintain the
>> file names of multiple generations of a file?
>>
>>
>> OTOH, using generation-numbers when there are many versions, (?surely)
>> requires a 'ripple' of renaming; whereas the date-time idea is
>> one-time-only rename.


> Why would generation numbers result in a 'ripple' of renaming?
> 
> You're assuming that "output.rpt.1" comes after "output.rpt.2", but it 
> could just as well come before (generation 1 precedes generation 2, 
> etc.). You're just left with the exception of the unnumbered 
> "output.rpt" being the latest.


I was!

However, that's the way statisticians and mathematicians think, and thus 
expressed themselves (I 'swapped' the minus-sign for a fileNM separator):

(current) version	version.rpt
-1 version		version.rpt.1
-2 version		version.rpt.2
etc

Thank you for exposing my assumption...
(guilty grin)

How would you rate my chances of talking them into the idea?
-- 
Regards =dn



More information about the Python-list mailing list