c++ - Zlib and Minizip - How to add a new directory to a .zip file -


I wrote an application from C ++ to compress the contents of the directory in a .zip file, and Minizip is well documented online but the file "zip.h" has comments in the source code.

Uses my application and creates a .zip file which is shown here as and to get a list of all the files (and subfolders) in the directory and within the zip Opens new files.

Then I read the source files with fopen and fread and write content for newly created files in zip folder. It all works fine, so the directory works to include compressed only those files, and no subfolders, but I comment in the source code how do I understand that by adding a new folder to a .zip file in that folder and writing the files then can not do.

As it turns out, you do not need to create a new directory in the .zip file separately You can simply pass the parameter "folder \ filename.ext" to the zipOpenNewFileInZip method and it will create the "Folder" directory so you then add a new file "filename.ext" to that directory.


Comments

Popular posts from this blog

Pass DB Connection parameters to a Kettle a.k.a PDI table Input step dynamically from Excel -

multithreading - PhantomJS-Node in a for Loop -

c++ - MATLAB .m file to .mex file using Matlab Compiler -