ATTENTION: You are viewing a page formatted for mobile devices; to view the full web page, click HERE.

Main Area and Open Discussion > General Software Discussion

Recreate files but without content to target drive

<< < (3/11) > >>

skwire:
Some further thoughts. The test zip file i created has 18,375 files and weighs in at 3.27 MB. That must mean that the filenames storage takes up that much space. And that zips don't optimize that part? or something else?-vixay (June 10, 2009, 07:10 AM)
--- End quote ---
Yes, the filenames take up that much space.  I tried it with compression and it didn't make a difference in size.

Scanning for files was slower than everything/locate, i don't know how they do it, but they can scan filenames super fast. just a thought, to see if it could be sped up.-vixay (June 10, 2009, 07:10 AM)
--- End quote ---
It's not the scanning that's slow, it's the creation of all the zero-byte files that slows things down.

The date/time is not preserved for filenames. This was not an original requirement but when i think about it, it's better to have that information preserved  (not required though). If it will make the program slower then it should not be there (or maybe as an optional thing).-vixay (June 10, 2009, 07:10 AM)
--- End quote ---
It shouldn't make it too much slower.  I'll add it in.

Can you share your ideas on how you did it? You used IZarc to compress, did you just use flags for the command line , or dump the filename list and then create the zip?-vixay (June 10, 2009, 07:10 AM)
--- End quote ---
Just command-line flags (izarcc.exe -a -r -p -c0).  So, the flow goes like this:

1) Recursive scan through source folder and re-create it using zero-byte files in user's temp folder.
2) Zip up temp folder with relative paths set.
3) Delete temp folder.

Does that help clear things up?

mouser:
make sure you exclude the temp folder from the zipping operation if the user ever tries to add all of C:

skwire:
Bahaha...the recursive spiral of doom.

skwire:
vixay, try the latest...it should keep the timestamps properly.

Download: http://skwire.dcmembers.com/apps/zero_zipper/ZeroZipper.zip

f0dder:
Ooooh, you use an external tool to create the zip instead of constructing it directly? No wonder it's slow then :)

(Since you're only dealing with 0-byte files, creating the zip manually from code shouldn't be that big a deal, since you only need to deal with the logical zip structure and not compression of data).

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version