Reputation: 1
i'm editing a huge text file and I want to delete multiple blocks of copy in this text file..
the blocks always start with START and end with END
is this possible?
I've used search & replace
and ^START starts ok, but I'm not sure how to select copy upto END
Upvotes: 0
Views: 1410
Reputation: 67988
START[\s\S]*?END
Try this.This will select multiple lines as well.
See demo.
https://regex101.com/r/wZ0iA3/4
Upvotes: 0
Reputation: 10681
Use follow regex:
(?s)START.*?END
It matches with blocks which:
START
END
END
inside block. Upvotes: 1