0
1
I'm trying to work out a command that recursively finds directories that only contain one or more directories on the same level. Preferably with the find
command. Like find . -type d
.
For example, in the following file structure:
/tmp/folder1/folder1a/test.jpg
/tmp/folder1/file1a.tmp
/tmp/folder2/folder2a/test.jpg
/tmp/folder3/folder3a/
/tmp/folder3/folder3b/file.jpg
I'd like to hit on folder2
and folder3
only since it does not contain files itself, it only contains folders (with files).