in reply to Re: Compact multi-line inplace file edit search and replace
in thread Compact multi-line inplace file edit search and replace
Actually you do get the last part of the source file. If there is just one instance of the match text in the original file then the first itteration of the loop prints the part before the match and the replacement text. The second itteration prints the part of the original file following the match text, but does not insert the replacement text.
|
|---|