[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

delete file based on content



Can anybody tell me what I am doing wrong?

 

I am trying to delete files based upon content.  As an example I have files called log1, log2, log3

 

Log 1 contains the words “Processing completed correctly” and can be deleted.

 

I tried the following: grep –li “Processing completed correctly” *

 

This gave me the list of logs that were complete.  How can I send the results of this to the rm command.  The redirection that I tried did not seem to work.


Reply to: