@Rob-K ,
I just said:
FIND = (?i-s)^\h*https?://test.domain\S*
REPLACE = $0 new stuff
The FIND would be better as:
FIND = (?i-s)^\h*https?://test\.domain\S*
Quick explanation of the regex:
the stuff in parentheses set up options to make it case insensitive and to not let . match newline
^ means the match starts at the beginning of the line
\h* allows 0 or more horizontal spaces (tabs and space characters) before the url
https?:// allows either http or https
\. escapes the ., so it means a literal domain separator, not the regex wildcard character
\S* means that there can be 0 or more additional non-space characters after the domain; since the end-of-line sequence counts as space character, it will stop at the end of the line if there’s nothing after the URL
$0 in the REPLACE means the entire matched text – so everything from beginning of line to just before the first space (or end-of-line).
new stuff indicates the new text you want to add
This means that the replacement will still include the original URL, plus the new stuff.