I need to delete files from a directory based on a search string. I tried:
grep -iL include * | rm -f
("include" is the string I was looking for)
This did not delete the files. The grep command alone found the correct files, but I can't pipe the results to the remove command.
Can anyone help me complete this task? Am I taking the wrong approach, or can I use the rm command on the results of a grep?