Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

Another more concise way to add a directory recursively to a zip file #66

brendon opened this Issue Nov 21, 2012 · 1 comment


None yet
2 participants

brendon commented Nov 21, 2012

I've discovered this technique for recursively adding a directory to a zip file:


The essence of it is:

Dir["#{path}/**/**"].each do |file|

This loops over every entry in the subdirectory (recursively) and adds it in replicating the directory names in the zip file. Thought it would make for a more concise example in your samples section.


simonoff commented Apr 13, 2013

You can fork, add samles/doc entries and make pull request.

@simonoff simonoff closed this Aug 25, 2013

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment