PDA

View Full Version : [ubuntu] Tar question



Elderlygent
July 23rd, 2008, 09:43 AM
What is the correct code to use if one wants to output the uncompressed file created by a tar command to a particular folder or directory? I've looked in both the Ubuntu guides I have and searched the forums without avail.

Alternatively, is there a detailed look at the tar command anywhere out there?

Thanks

Bachstelze
July 23rd, 2008, 09:46 AM
tar xvf foo.tar -C /bar


man tar

Elderlygent
July 23rd, 2008, 01:02 PM
tar xvf foo.tar -C /bar


man tar

Thanks for that. Is the /bar a substitute for the name of a folder or directory that I might choose? Or should the sample code line read:

tar xvf foo.tar -C /bar myfile

or somesuch.

Please clarify.

dje
July 23rd, 2008, 01:04 PM
Thanks for that. Is the /bar a substitute for the name of a folder or directory that I might choose? Or should the sample code line read:

tar xvf foo.tar -C /bar myfile

or somesuch.

Please clarify.

/bar represents the path to your output directory, so yes change it to that path

Elderlygent
July 23rd, 2008, 01:23 PM
Many thanks. I'll give it a try. And thanks for pointing me to the GNU manual.