I have hours searching for a way in regex to delete everything in a line except a certain text. It will be something like this:
Before:
Caracas
UNUSABLE TEXT Caracas UNUSABLE TEXT
Caracas
After:
Caracas
Caracas
Caracas
Caracas
I have make so many tests with this:
Find: .(text_you_need_to_keep).
Replace: $1
But I can't get it to work.
UNUSABLE TEXT Caracas UNUSABLE TEXT
line with 3Caracas
lines?(Caracas)|\R*(?:(?!Caracas).)+\R*
and replace with(?{1}$1:\nCaracas\n)