Unzip and delete .zip file

Get help. Get answers. Let others lend you a hand.

Moderator: Mr_Noodle

Unzip and delete .zip file Mon Aug 24, 2020 7:50 pm • by mtrifiro
I want Hazel to automatically unzip .zip files, leaving the unarchived folder in place and deleting the .zip file. For some reason this not only deletes the .zip file but also deletes the folder which holds the unzipped files. I can try breaking it into two different steps, but I would also like to know why this does not work:

Image

If the image does not appear, go here to view:
https://www.dropbox.com/s/k3caq528q882e4g/Hazel.jpg?dl=0
mtrifiro
 
Posts: 2
Joined: Mon Aug 24, 2020 7:25 pm

Re: Unzip and delete .zip file Tue Aug 25, 2020 8:46 am • by Mr_Noodle
The unarchive action already moves the archive to the trash. You should remove the Move action afterwards as that is moving the unpacked contents.
Mr_Noodle
Site Admin
 
Posts: 11250
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City

Re: Unzip and delete .zip file Tue Aug 25, 2020 9:15 am • by mtrifiro
Thanks. That was non-obvious.

What if I want to preserve the .zip?
mtrifiro
 
Posts: 2
Joined: Mon Aug 24, 2020 7:25 pm

Re: Unzip and delete .zip file Wed Aug 26, 2020 10:35 am • by Mr_Noodle
You should copy it somewhere else first. Note that actions in the same rule after a copy action apply to the copy so you may want to split it into two rules and use the "Continue" action on the first one.
Mr_Noodle
Site Admin
 
Posts: 11250
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City


Return to Support