bash - Command line - Remove directories if they contain a particular file type -


i'd remove directories if contain .png images whilst ignoring directories not.

i need use command line (i'm using mingw).

i imagine solution include rm , target directory if contains *.png. how can done?

find -type f -name "*.png" -printf "%h\0" | uniq -z | xargs -0 rm -rf 

Comments

Popular posts from this blog

Unable to remove the www from url on https using .htaccess -