Posted By

ferro on 09/29/11


Tagged

delete files xargs


Versions (?)

Delete all files of a directory which contains a specific contents, no mather the size of the directory


 / Published in: Bash
 

  1. find . -exec grep -l "From: MAILER-DAEMON" {} \; | xargs rm -rvf '{}'

Report this snippet  

You need to login to post a comment.