Make moving lines easier in vim and change the tab listchar
This commit is contained in:
parent
2a57ce8837
commit
c7845e62d9
8
vimrc
8
vimrc
|
@ -382,7 +382,8 @@ if executable('rg')
|
|||
set grepprg=rg\ --vimgrep\ --hidden " Requires ripgrep to be installed.
|
||||
endif
|
||||
|
||||
set list listchars=tab:»·,trail:· " Show trailing whitespace.
|
||||
" Show trailing tabs and whitespace.
|
||||
set listchars=tab:»\ ,trail:·,extends:>,precedes:<,nbsp:+
|
||||
|
||||
set timeoutlen=250 ttimeoutlen=0 " Don't set it too low otherwise you won't be able to type use multi-key sequences.
|
||||
|
||||
|
@ -609,6 +610,10 @@ noremap <c-h> <c-w><Left>
|
|||
:cnoremap <C-J> <S-Left>
|
||||
:cnoremap <C-K> <S-Right>
|
||||
|
||||
" Move a line under the cursor.
|
||||
noremap <S-j> :m-2<cr>
|
||||
noremap <S-k> :m+<cr>
|
||||
|
||||
" Window splitting - couldn't figure out how to remap <c-w>v & <c-w>n to <c-m>
|
||||
" & <c-n>
|
||||
noremap <leader>m :vsplit<cr>
|
||||
|
@ -774,6 +779,7 @@ noremap Q <Nop>
|
|||
"##################################################################################
|
||||
" MULTIPURPOSE TAB KEY
|
||||
"##################################################################################
|
||||
|
||||
fu! InsertTabWrapper()
|
||||
let l:col = col('.') - 1
|
||||
if !l:col || getline('.')[l:col - 1] !~ '\k'
|
||||
|
|
Loading…
Reference in New Issue
Block a user