24131Re: [Clip] REGEX Search Backward
- Nov 3, 2013nullclip@... wrote:
> Each URL is on a separate line proceeded by only new-line characters.You should have said, this makes things much easier:
^!Find "(?s).+\R\K(https?://|www\.)[^\r\n]+" IORSW
> I understand all but the portion (?s).Yes, it's well hidden, which is a shame as I always forget the procise
character and have to look it up again. See "Internal Option Setting"
and "Full Stop (Period, Dot) and \N"
To summarize, the dot captures anything BUT line ends unless you assert
dotall. If you do, it captures anything INCLUDING line ends.
In your special case the much simpler
^!Find "^.+\Z" IORSW
should do it too. In effect it says "match the last line".
- << Previous post in topic Next post in topic >>