Andreas Schwab <[EMAIL PROTECTED]> wrote:
> Reuben Thomas <[EMAIL PROTECTED]> writes:
>
>> In this case, I don't see a good way of getting the same information. The
>> best way I could come up with that was short enough for command-line use
>> was use find to find directories with only 2 symlinks to them, but of
>> course that only works on some filing systems.
>
> $ find -type d -empty

Note that if you simply want to remove all empty directories
(including e.g., those rendered empty by removing leaf dirs),
you should also use -depth and -delete:

  find . -depth -type d -empty -delete

Though, the -delete predicate is provided by GNU find,
it is not specified by POSIX.


_______________________________________________
Bug-coreutils mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/bug-coreutils

Reply via email to