An example of what I want to do.. I have tons of:
name : 'SomethingXX',
I want to become:
name: 'Something Else',
Where Something is different for every entry, so I can find all using name : '((.*?))XX'
But then to replace I need to be able to keep the Something but change the XX and don't know how to do that. I can't just find replace the XX because it appears at other places also.
1 Answer 1
This will replace XX with what you want in all lines:
^name : '.+?\KXX
- find:
^name : '.+?\KXX - Replace:
What you want
Explanation:
^ : beginning of line
name : ' : literally
.+? : 1 or more any character but newline, not greedy
\K : forget all we have seen until this position
XX : XX (what to be changed)
You must log in to answer this question.
Explore related questions
See similar questions with these tags.