« ZFS Dedup ResultsDoing it the hard way - ZFS, Dedup, and OpenSolaris »

Zipping A Bunch of Files and Folders from STDOUT

01/29/10 | by Brian Fitzhugh [mail] | Categories: Storage, Technology, Linux

Need to do a one time or scripted zip of a specific set of files? Here's how i did it with my dated folder structure.

Folder structure example:

20091213
20091214
20091215

What I did to compress these folders:

find . -name "200912*" -print| zip -r 2009-12 -@

The find section can be adjusted to print out a specific path. My example grabs the December files in my current folder. The zip section just takes the STDOUT of the find section and recursively compresses the folders and contents into 2009-12.zip.

Tags: compress, find, zip

No feedback yet

Leave a comment


Your email address will not be revealed on this site.

Your URL will be displayed.
(Line breaks become <br />)
(Name, email & website)
(Allow users to contact you through a message form (your email will not be revealed.)
July 2010
Sun Mon Tue Wed Thu Fri Sat
 << <   > >>
        1 2 3
4 5 6 7 8 9 10
11 12 13 14 15 16 17
18 19 20 21 22 23 24
25 26 27 28 29 30 31

Search

Friend Connect

XML Feeds

powered by b2evolution