Computing.Net > Forums > Linux > Compress directories using tar

Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.

Compress directories using tar

Reply to Message Icon

Name: afnhe
Date: April 10, 2007 at 11:56:10 Pacific
OS: FC6
CPU/Ram: Intel 2 Core Duo / 2 GB
Product: Fujitsu/Siemens
Comment:

Greetings i want to compress some directories using tar.

teste]$ tree
.
`-- teste1
|-- teste12
`-- teste13

My question is: how can i exclude some directories using tar? if a use tar cvf teste1.tgz teste1/ ok it'll compress the all dir but i want exclude for example the subdir teste13. Thanks for any help.



Sponsored Link
Ads by Google

Response Number 1
Name: dmj2
Date: April 10, 2007 at 12:06:38 Pacific
Reply:

tar -cvf -W --exclude '*13' test.tar test


0
Reply to Message Icon

Related Posts

See More







Post Locked

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.


Go to Linux Forum Home


Sponsored links

Ads by Google


Results for: Compress directories using tar

Creating a .tar.gz file www.computing.net/answers/linux/creating-a-targz-file/18025.html

install tar.bz2 file www.computing.net/answers/linux/install-tarbz2-file/28145.html

DAT Tape compression www.computing.net/answers/linux/dat-tape-compression/19121.html