British Inside

An Englishman living in small town America

James Shaw

News

  • Copyright James Shaw 2004-2007

    Creative Commons License

    View James Shaw's profile on LinkedIn

Zip files and empty folders

Found a truly bizarre problem with WinZip over the weekend. I zipped up the whole of a project I am working on, adding just the files that changed since a certain date. Then I sorted by folders and types and deleted a few thousand files that I didnt want in there, such as the Subversion .svn folders and files.

I ended up with a Zip file containing just 77 files. Cool.

Except, when I uploaded it to my server to unzip and update the application, the extraction produced hundreds of extra folders - and 4239 files, all in .svn folders.

Even now, my zip file *looks* like it contains 77 files.

But there are really over 4000 files in it. You just can't see them.

I've never seen or heard about this kind of thing before and of course Winzip.com is no help at all. Their whole website is now dedicated to extracting (no pun intended) every last dollar out of anyone who's running winzip. THIS SOFTWARE IS NOT FREE, and even better, YOU MUST PAY AGAIN TO UPGRADE. etc

Even so, I submitted a question for them about this zip file, and asked them how to fix it just in case it can help someone else...

UPDATE: It appears that i have 4000+ empty folders in my zip file - and they are "not listed in the main WinZip window for cosmetic reasons". It's not immediately clear how you are supposed to delete them if you can't see them. Tongue Tied

UPDATE 2: Call me dumb if you have to, but the only way to fix this that I've found is to select everything that you see in the zip file and extract it to a new folder. Then zip up those files again. Of course, it will look the same, but it isn't the same.

How can you tell? Hover over the zip file in Explorer and look at the status bar. The "corrupt" zip file will show many more items that the normal one.

ANSWER FROM WINZIP: "The empty folder name entries are normally not displayed in the WinZip window for cosmetic reasons, but Using Microsoft's 'regedit' utility from the 'run' option of the start menu will allow you to add a key to the registry to display the foldernames in the WinZip window. Locate the Key:

HKEY_CURRENT_USER\Software\Nico Mak Computing\WinZip\WinZip

The 'string value' key 'ShowDirEntries' can be added, and then set to '1'; This will display the empty folder entries in the WinZip window."


 

Posted: Monday, June 18, 2007 2:31 PM by James
Filed under: ,

Comments

Kevin said:

I switched from using WinZip to 7-Zip as my primary compression utility about a year ago. If you haven't already, I recomend trying it out. 7-zip is free and open-source, and does just about everything that WinZip can do and more. It can also uncompress RAR files (so you don't need to install WinRAR), and has it's own open compression format (7z) that is comparable to RAR and ACE if you want something tighter than the zip format.
# June 18, 2007 6:58 PM

David Voss said:

Wow, that's screwed up. I had been getting by with the built-in Windows extraction at home but figured maybe I should get a copy of WinZip. So I can totally relate to the "THIS SOFTWARE IS NOT FREE YOU MUST PAY FOR IT" message. The 25 day email strongly reiterates that same message. I personally found it really irritating. It felt like the equivalent of going to a store and having a store employee following around cause they think you're going to steal from their store. So yeah, 7-Zip just finished downloading and I'll be using that from now on.
# June 20, 2007 6:48 PM
New Comments to this post are disabled