So I have have a directory – lets say /dir/. In it I have these folders- /dir/fold1/ /dir/fold2/ /dir/fold3/
each of these folders (fold1,2,3) may contain a folder called foo. I want to list all the folders inside dir, that have inside them a folder called foo.
Thanks!
What about
Breaking down the command we have:
ls -R= Lists files recursively (including directoriesgrep -i foo= Will take the command above and filter it case-insensitive to display any instances of ‘foo’.