vim-movelines : Vim plugin for moving lines in normal and visual mode.
script karma |
Rating 2/2,
Downloaded by 269 |
Comments, bugs, improvements
|
Vim wiki
|
created by |
Krzysztof Cieslak |
|
script type |
indent |
|
description |
Vim plugin for moving lines in normal and visual mode.
https://github.com/krcs/vim-movelines
|
|
install details |
Copy movelines.vim into ~/.vim/plugin or $HOME/vimfiles/plugin directory.
For normal mode call MoveLineNormal(direction). For virtual mode call MoveLinesVisual(direcion).
direction - Up,Down,Left,Right, words or only first letter.
In the .vimrc file insert following lines to map keys, I am using Alt+[cursor key]:
nnoremap <silent> <A-j> :call MoveLineNormal(\"d\")<CR>
nnoremap <silent> <A-h> :call MoveLineNormal(\"l\")<CR>
nnoremap <silent> <A-l> :call MoveLineNormal(\"r\")<CR>
xnoremap <silent> <A-h> :call MoveLinesVisual(\"left\")<CR>
xnoremap <silent> <A-l> :call MoveLinesVisual(\"Right\")<CR>
xnoremap <silent> <A-j> :call MoveLinesVisual(\"down\")<CR> |
|
script versions (upload new version)
Click on the package to download.
ip used for rating: 18.188.100.179
|