Skip to content

Instantly share code, notes, and snippets.

@haya14busa
Created February 2, 2014 20:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save haya14busa/8774273 to your computer and use it in GitHub Desktop.
Save haya14busa/8774273 to your computer and use it in GitHub Desktop.
function! s:my_x()
undojoin
exec "normal! \"_x"
endfunction
noremap <silent> <Plug>(my-x) :<C-u>call <SID>my_x()<CR>
call submode#enter_with('my_x', 'n', '', 'x', '"_x')
call submode#map('my_x', 'n', 'r', 'x', '<Plug>(my-x)')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment