0

I have a folder (Mac OS X Yosemite) of zip files numbering 1 through 1822 that I would like to run the following Terminal command on each in a batch:

zip -FF ***x***.zip --out recovered-***x***.zip

where x is the number of the file, 1 to 1822, and there are missing numbered files/gaps.

How would I best automate this?

1 Answer 1

0

I found something that worked well enough for my purposes:

for file in *.zip; do
    zip -FF $file --out recovered$file
done

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.