Generating generations of files
Grant Edwards
grant.b.edwards at gmail.com
Tue Apr 30 11:10:50 EDT 2019
On 2019-04-30, Cameron Simpson <cs at cskk.id.au> wrote:
> On 30Apr2019 11:24, DL Neil <PythonList at DancesWithMice.info> wrote:
>>On 30/04/19 8:17 AM, MRAB wrote:
>>>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
>
> For a counter example, I'm pretty sure the VMS built in file versioning
> went on the scheme MRAB described: rewriting version.rpt caused the old
> version to become "version.rpt;n" where n counted up from 1.
That sounds right.
And you could configure how many versions were kept. I usually set it
to 3. I'm not sure, but I vaguely remember it might have been limited
at 32767.
--
Grant Edwards grant.b.edwards Yow! I know how to do
at SPECIAL EFFECTS!!
gmail.com
More information about the Python-list
mailing list