Saltycrane logo

SaltyCrane Blog

Notes on Python, Django, and web development on Ubuntu Linux

    

Unaswered Questions

If you know the answer, please leave a comment.

 

1. How do I unpack a tarball to a specific directory?

I know I can uncompress a tar file in the current working directory with tar –xvf mytarfile.tar. Can I upack it to another directory instead?

 

 

2 Comments — feed icon Comments feed for this post


#1 Leonardo commented on 2008-01-26:

You can use the -C modifier:

tar -C destination_path -xvf yourtarfile.tar


#2 sofeng commented on 2008-01-28:

leonardo:
Thanks a lot!

Post a comment

Required
Required, but not displayed
Optional

Format using Markdown. (No HTML.)
  • Code blocks: prefix each line by at least 4 spaces or 1 tab (and a blank line before and after)
  • Code span: surround with backticks
  • Blockquotes: prefix lines to be quoted with >
  • Links: <URL>
  • Links w/ description: [description](URL)
Created with Django | Hosted by Linode