Find and replace scope can be limited like this:
:16,256s/search_term/replacement/gc
I don't want to replace my search term with any other text, I just want to find them. I tried the following, but it didn't help:
:16,256/search_term # Notice that there is no 's' here
Thanks for your time!
From the vim documentation:
You can limit the search command "/" to a certain range of lines by including \%>l items. For example, to match the word "limit" below line 199 and above line 300: >
/\%>199l\%<300llimit
This means: Match below line 199 and before line 300 and find the word limit
.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With