I'm using vim a lot and I'm trying to optimize few movements I do with too much key pressed. For exemple I have this :module SanitizeIdsParams  def self.my_method ids    ...code  endendAnd I want thismodule SanitizeIdsParams  def self.my_method ids    ...code  end  def self.my_method ids    ...code  endendFor the moment I'm doing something like j<CR>v3jy<ESC>4Go<ESC>p I'm not a huge fan of :2,4t.4Go<ESC>, any other ideas without specifying exact line number ? I would like to know also if when I yank I can stay where I yank and not going at the beginning of my visual selection.Open to classic vim motions and plugins.
Duplicate block of code
cut copy paste
Once you have your visual selection you can do::'<,'>t'>(it's actually :t'> because Vim adds the visual range automatically)to copy it after the visual selection and do:'[O<Esc>to add an empty line.If you don't want to use visual selection, something like this should work::,/end/t//You will still need to add the empty line manually.