Make ZIP files smaller with ZIP Shrinker
25 points
by zdw
2 days ago
| 5 comments
| evanhahn.com
| HN
lifthrasiir
1 hour ago
[-]
While not very popular, ECT [1] is (still?) the best solution in this space and has been my go-to tool for this purpose.

[1] https://github.com/fhanau/Efficient-Compression-Tool

reply
futune
1 hour ago
[-]
I use ect on a monthly basis, at least. Especially for png files. It's pretty great!
reply
akx
3 hours ago
[-]
> Typically, other archives like .tar.bz2 can be smaller. But those aren’t backwards-compatible!

Is there any point for (new) .bz2 archives in the era of Zstd?

reply
j16sdiz
2 hours ago
[-]
Tooling ?

It takes years for bzip2 be in every Linux Distro, and we _still_ doing gzip.

LZMA / xz tool are start to get more support, but they are nowhere near universal.

No idea when how long zstd will need.

reply
strenholme
1 hour ago
[-]
xz is pretty universal across POSIX and clones though. It comes with any modern Linux distro, Busybox even has an .xz decompressor, so `tar xvJF file.tar.xz` does the right thing in *NIX land, which I presume includes MacOS with Brew.

For Windows systems, 7-zip (.7z, similar compression to .xz) is a free download for Windows 10, and Windows 11 can open up a .7z file with a simple double click.

.zip and .gz no longer need to be used here in 2026.

reply
Am4TIfIsER0ppos
1 hour ago
[-]
Debian? Did they discover it yet?
reply
sigio
1 minute ago
[-]
I think it's been in since debian 11... at least 12, it's been in my default ansible playbooks for a while.
reply
ChrisNorstrom
10 minutes ago
[-]
I know you meant well but...

"It deletes empty folders" and "Let me know if this is a problem for you"

NEVER DO THAT. I know you meant well, but the first rule of any program is to NEVER automatically delete something without informing the user. NEVER. Users keep empty folders for structure, reminders, or placeholders because software will dump files into it later when it's run. If it was there when they zipped it up, it should be there when they unzip it. Otherwise they'll check the before and after and it will show some folders missing, create confusion, and the user will run off trying to find out if anything else is missing.

Example: A user zips up a program. Some programs are coded to look for a folder and dump files into it, if the folder is missing the program will fail. I've had that occasionally over the years. Not all programs will recreate a missing folder.

reply
Ekaros
4 minutes ago
[-]
One thing I dislike about git is that it really does not support empty folders well. Even though they might make sense lot of time. Either now or for future. There is decent reasons to have empty folders.
reply
jurgenkesker
1 hour ago
[-]
APKs need to be zipaligned, I don't see that mentioned.
reply
Retr0id
11 minutes ago
[-]
Fun fact, having page-aligned uncompressed .so files in the APK allows the dynamic linker to mmap them directly out of the ZIP.
reply
stuaxo
1 hour ago
[-]
Nice, interesting to see if it helps docx much.
reply