Permalink
Browse files

Merge branch 'master' of github.com:slik/vim-plugins

  • Loading branch information...
2 parents 3156b91 + af9bb10 commit 465521740be5f60deafa798bab938a475bda8f05 @slik committed May 9, 2012
Showing with 21 additions and 4 deletions.
  1. +21 −4 bootstrap.vim
View
@@ -3,7 +3,7 @@ set nocompatible
" database mysql
if has("autocmd")
- autocmd BufRead *.sql set filetype=mysql
+ autocmd BufRead *.sql set filetype=mysql
endif
" encoding
@@ -26,8 +26,8 @@ set nu
set incsearch
" scroll
-set scrolljump=5
-set scrolloff=5
+set scrolljump=3
+set scrolloff=3
" beep off
set novisualbell
@@ -49,7 +49,7 @@ set guioptions-=m
syntax on
" show cursor line
-:set cursorline
+set cursorline
" tabs
set shiftwidth=4
@@ -138,6 +138,23 @@ function! <SID>StripTrailingWhitespaces()
endfunction
autocmd BufWritePre *.py,*.php,*.js :call <SID>StripTrailingWhitespaces()
+" Bubble single line
+nmap <C-Up> ddkP
+nmap <C-Down> ddp
+
+" Bubble mutiple lines
+vmap <C-Up> xkP`[V`]
+vmap <C-down> xp`[V`]
+
+" shows highlight group
+nmap <C-S-P> :call <SID>SynStack()<CR>
+function! <SID>SynStack()
+ if !exists("*synstack")
+ return
+ endif
+ echo map(synstack(line('.'), col('.')), 'synIDattr(v:val, "name")')
+endfunction
+
" Show syntax highlighting groups for word under cursor
nmap <C-S-P> :call <SID>SynStack()<CR>
function! <SID>SynStack()

0 comments on commit 4655217

Please sign in to comment.