[delphizip] Re: Keeping old versions of a file in a zip archive

  • From: "Russell Peters" <russellpeters@xxxxxxxxxxx>
  • To: <delphizip@xxxxxxxxxxxxx>
  • Date: Thu, 28 Nov 2002 07:39:11 +1100

The OnSetNewName only allows you to rename the new file with the names of
the old files staying unchanged.
I am working towards being able to do such operations as changing existing
file details (rename,change date & attr) or delete the file,at the same as
new files are added - this condences a number of operations into a single
rebuild.
I might be able to allow the use of a name (or any detail?) modifying
function on a per file basis - this might make renaming files easier though
you would need to know which files first (this is still very much in the
planning stage at present).
Russell Peters
http://www.users.bigpond.com/russellpeters/delphizip.html
----- Original Message -----
From: "James Turner" <james.d.h.turner@xxxxxxxxxxxx>
To: <delphizip@xxxxxxxxxxxxx>
Sent: Wednesday, November 27, 2002 10:57 PM
Subject: [delphizip] Re: Keeping old versions of a file in a zip archive


>
> When I suggest a solution to a problem, I aim to achieve simplicity,
> backward compatibility, and flexibility. The event handler approach I
> suggested achieves all these. For instance, provided the event handler has
> access to a directory list, renaming old versions of MYFILE.TXT to
> MYFILE.TXT#1, MYFILE.TXT#2, etc is easy. If such an event interface were
> added to ZipMaster, it would be easy to supply a built-in (but not
> automatically assigned) event handler to perform this action thereby
> requiring virtually no work from the user.
>
> Relying on file dates is, precarious and would undoubtedly lead to
problems.
> Renaming the files makes it obvious when reading a directory list (human
> being), which file is the most recent without having to check dates.
> However, for programmers that want to rely on dates, an event handler that
> returns, say '$', could achieve this.
>
> Once again, the buzzwords are : simplicity, backward compatibility, and
> flexibility.
>
> Of course, having said all that, Russell's comments regarding the
> OnSetNewName event suggest that this capability is (almost ??) implemented
> anyway. I have not used this feature.
>
> -- James Turner
> www.skaro.net
>
> PS
> I agree that the ability to keep old versions of files within an archive
is
> desirable. I have already included this feature in code I am currently
> working on for a general purpose archive interface that can work with zip
> and other archive types.
>
>
>



Other related posts: