CFZIP action="unzip" overwrite="true" deletes existing directories.


This related to this issue

As of now if you can unzip a entrypoint it will unzip it into your destination {destination}/{entrypoint} . However, everything in the {destination} directory will be deleted.

As I posted on the other ticket it would be great it this line:

was changed to:

That way you can unzip var entry points into the different zip into the same directory.



Luceee on java 8


Matt Levine
January 29, 2020, 1:26 AM

Here’s a unit test . I don’t think my suggest fix is correct. I tried a few things and have been able to figure it out yet.

I think the key is that I’m zipping into the same directory twice with overwrite=true. It seems to be deleting files that don’t match the entrypath filter. I think the expectation is that it would only affect files within the entrypath.


Pothys - MitrahSoft
February 13, 2020, 4:08 PM

I've checked this & can able to reproduce it when as per your test case but additionally I added an extra one unzip condition. So, then only I've facing same issue as what you've faced. But, if we add ( !target.isDirectory() ), directory doesn't delete. This problem was solved. And if that directory has any file means, it'll be deleted. But, ACF works fine. will confirm about this issue.

July 31, 2020, 2:17 PM

This issue and the related workaround have caused a regression in Mura, see Mura issue 3190.

Zac Spitzer
October 25, 2020, 12:52 AM

Pothys - MitrahSoft
November 24, 2020, 2:07 PM

, I've checked this issue with PR. It works fine as expected.


Michael Offner


Matt Levine




Fix versions


Affects versions