helpGNU tar - Support: sr #106062, Feature request: option to require...


sr #106062: Feature request: option to require at least 1 level of directory on all extracted items

Submitted by:  mathew <metamatic>
Submitted on:  Wed 24 Oct 2007 06:20:30 PM UTC  
Category:  None Priority:  5 - Normal
Severity:  1 - Wish Status:  None
Privacy:  Public Assigned to:  None
Open/Closed:  Closed Operating System:  GNU/Linux

Add a New Comment(Rich Markup)

You are not logged in

Please log in, so followups can be emailed to you.


Wed 12 Feb 2014 09:31:51 PM UTC, comment #1:

This was just fixed in git :).

Wed 24 Oct 2007 06:20:30 PM UTC, original submission:

Every now and again someone will make a tar file that extracts into the current directory, and I'll unpack it and then have to go clean up the mess.

I'd like to suggest an option for smart extraction of archives, to work as follows:

- If all entries in the archive directory have at least 1 level of subdirectories (i.e. at least 1 '/' in them), extract as is.

- Otherwise, take the basename of the archive and create a subdirectory with that name, and extract as if -C had been used to change to that directory.

Ideally the option would be a single letter one, so I could add it to the usual -xvf with minimal extra typing.

I vote for -I, with "intelligent subdirectory creation" as the mnemonic. I've just checked and it doesn't seem to be used in GNU tar or star.

mathew <metamatic>


(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:

No files currently attached


Depends on the following items: None found

Items that depend on this one: None found


Carbon-Copy List
  • -email is unavailable- added by gray (Updated the item)
  • -email is unavailable- added by metamatic (Submitted the item)

    Do you think this task is very important?
    If so, you can add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.


    Please enter the title of George Orwell's famous dystopian book (it's a date):



    Follows 1 latest change.

    Date Changed by Updated Field Previous Value => Replaced by
    2014-02-25 gray Open/ClosedOpen => Closed

    Back to the top

    Powered by Savane 3.3