When editing a buffer and initiating a search-and-replace, I use :s/oldword/newword/g
Now the word 'oldword' will be in the buffer I am editing, and sometimes it is a long word.
It would be helpful if I was able to auto-complete somehow the words 'oldword' and 'newword' from the contents of the buffer to save some typing, say by typing just :s/ol
then TAB to cycle through matches in the buffer, and then similarly for 'newword'.
Is something like this possible without plugin ?
In general, is there a way of getting completion suggestions from the current buffer to assemble the :
command line ?
:
command mode<C-r><C-w>
yanks the word under the cursor into the command line.