ZipFile.jl


#1

Hello,

The README for ZipFile.jl talks about writing to a new zip file and reading from it. Is there a way to add a file to an existing zip file? i.e., append a file?

Thanks,

Ritchie


#2

Seems to be the very first example in the documentation.


#3

Hi Tamas, thank you for your quick reply.

The first example creates a new zip file and then appends files to it. I have an existing zip file. I would like to open it and add files to it. For example,

  1. Create “myzip.zip”, add “file1.txt”, close “myzip.zip”.
  2. Later…, open “myzip.zip”, add “file2.txt”, close “myzip.zip”. At this point, “myzip.zip” should contain two files.

Ritchie


#4

I think that you can open a zip file, read & store the contents, and then create a new one, write out the contents + the new file. That said, perhaps you could open an issue to get the desired behavior, since the pieces seem to be there.

Also see


which seems to support adding files.