Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I have the following directory structure


I use this command to create an archive of all the directories starting with the letters a-m

tar czf books.a-m.no.AI.tgz --exclude=books/AI.and.algorithms --exclude=books/[N-Z]* --exclude=books/[n-z]* books

The .tgz archive that gets created does not contain the java.swing/ directory.

Am I missing something in my use of tar or is this a bug in cygwin?

share|improve this question

migrated from stackoverflow.com Nov 5 '12 at 16:34

This question came from our site for professional and enthusiast programmers.

1 Answer 1

up vote 0 down vote accepted

The issue was that the java.swing/ directory is empty. Apparently cygwin tar silently omits empty directories. There is nothing in the --help about empty directories either.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.