A
A
Alexander2014-11-10 01:06:16
linux
Alexander, 2014-11-10 01:06:16

How to find all files containing a string and delete it?

Subject.
Something is googled separately, but not going to the heap.
Help.
Suppose here are files containing the line

grep -rH ICRHTE9CQUxTWydfMTk4OTg2NDc5NV8nXT1BcnJheShiYX . |  cut -d: -f1

Now they need to be redirected to sed and delete the ENTIRE line, not just this occurrence and save. It seems to be a simple task, but something fatigue makes itself felt apparently - I can’t figure it out.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alexander, 2014-11-10
Madzhugin @Suntechnic

He asked, he answered - you can remember about xargs and stupidly in the forehead:
Maybe there are more efficient methods, but this was enough for me.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question