How do I clear the last searched pattern?
The last searched pattern is stored in the “/” register. You can clear this register using the following command:
To clear the last search pattern whenever a buffer is unloaded, you can use the following command:
:autocmd BufUnload * let @/ = ""
Let’s see you to :help viminfo-file-name (option -i) :set viminfofile=NONE