The Situation
I am extracting a CMS from drupal-7.15.tar.gz to /var/www.
When extracted normally (with tar -xvzf filename.tar.gz
) the files end up in /var/www/drupal-7.15/
The Goal
I want the contents from the archived drupal-7.15/ directory to extract directly into /var/www
Best Answer
Use
--strip-components=1
tellstar
to strip the first path component (thedrupal-7.15/
in your case) from each file when unpacking.