Tar-to-pipe

From PTAGISWiki

Jump to: navigation, search

Subject: tar to a pipe To: crispin@cse Date: Mon, 12 May 1997 13:58:31 -0700 (PDT)

The common idiom for tarring to a pipe looks like this:

tar cf - <fromdir> | ( cd <todir> ; tar xfp - )

So an example that would copy your linux source tree to /tmp would look like:

tar cf - /usr/src/linux | (cd /tmp ; tar xfp - )

Assuming that you are tarring to a pipe so you can untar from a pipe somewhere else...

Ryan

Personal tools