https://www.baeldung.com/linux/vim-search-replace
To search and replace all occurrences on every line of the file, we need to slightly modify the previous command:
The % symbol lets us access all the content in the file, and we can replace all occurrences in each line.
The sample.txt file should match this after replacing all occurrences:
No comments:
Post a Comment