Loading ...
Sorry, an error occurred while loading the content.

Re: replacing word with last yanked word?

Expand Messages
  • Benji Fisher
    ... Try ve (or some variant) to select the word in Visual mode and then p . Alternatively, try ce 0 or de 0p or _dep . ... HTH --Benji
    Message 1 of 7 , Jul 1 6:02 AM
    • 0 Attachment
      Steven Dodd wrote:
      > Is is possible to accomplish the following in a simpler way:
      >
      > 1. Delete a word via "dw"
      > 2. Yank a replacement word from some other location by moving there and
      > then doing a "yw"
      > 3. Return to the site of the deleted word and paste the yanked word via
      > "p"
      >
      > Ideally it should work like:
      >
      > 1. Yank a replacement word from some location via "yw"
      > 2. Move to word to replace, then replace it with "?p"

      Try "ve" (or some variant) to select the word in Visual mode and then "p".
      Alternatively, try "ce<C-R>0<Esc>" or 'de"0p' or '"_dep' .

      :help v_p
      :help registers

      HTH --Benji Fisher
    Your message has been successfully submitted and would be delivered to recipients shortly.