Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

V9.2 #397

Open
wants to merge 14 commits into
base: master
Choose a base branch
from
11 changes: 9 additions & 2 deletions UltiSnips/python.snippets
Original file line number Diff line number Diff line change
Expand Up @@ -49,15 +49,15 @@ self.${1}
endsnippet

snippet p "print"
print ${1}
print(${1})
endsnippet

snippet pr "print "
print "${1}"
endsnippet

snippet pri "print ''"
print '${1}'
print('${1}')
endsnippet

snippet prt "print trace"
Expand Down Expand Up @@ -174,3 +174,10 @@ snippet dk "api doc"
code:

endsnippet

snippet djadmin "django admin"
class XXAdmin(admin.ModelAdmin):
pass
admin.site.register(XX, XXAdmin)
${1}
endsnippet
5 changes: 5 additions & 0 deletions install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,12 @@ cd $CURRENT_DIR/bundle/YouCompleteMe/
git submodule update --init --recursive
if [ `which clang` ] # check system clang
then
# export DYLD_LIBRARY_PATH=/Library/Developer/CommandLineTools/usr/lib/
# TODO: if the dir exists, do export first?
# TODO: change cli to https://github.com/wklken/k-vim/pull/379
python install.py --clang-completer --system-libclang # use system clang
# for golang
# python install.py --clang-completer --system-libclang --go-completer
else
python install.py --clang-completer
fi
Expand Down
4 changes: 4 additions & 0 deletions others/italic/tmux-256color.terminfo
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# A tmux-256color based TERMINFO that adds the escape sequences for italic.
tmux-256color|screen with 256 colors and italic,
sitm=\E[3m, ritm=\E[23m,
use=screen-256color,
4 changes: 4 additions & 0 deletions others/italic/xterm-256color-italic.terminfo
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# A xterm-256color based TERMINFO that adds the escape sequences for italic.
xterm-256color-italic|xterm with 256 colors and italic,
sitm=\E[3m, ritm=\E[23m,
use=xterm-256color,
39 changes: 34 additions & 5 deletions vimrc
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
"==========================================
" Author: wklken
" Version: 9.1
" Email: wklken@yeah.net
" Version: 9.3
" Email: wklken@gmail.com
" BlogPost: http://www.wklken.me
" ReadMe: README.md
" Donation: http://www.wklken.me/pages/donation.html
" Last_modify: 2015-12-15
" Last_modify: 2019-05-04
" Sections:
" -> Initial Plugin 加载插件
" -> General Settings 基础设置
Expand Down Expand Up @@ -243,6 +243,15 @@ function! NumberToggle()
endfunc
nnoremap <C-n> :call NumberToggle()<cr>

" Always show the signcolumn, otherwise it would shift the text each time
" diagnostics appear/become resolved.
if has("patch-8.1.1564")
" Recently vim can merge signcolumn and number column into one
set signcolumn=number
else
set signcolumn=yes
endif

" 防止tmux下vim的背景色显示异常
" Refer: http://sunaku.github.io/vim-256color-bce.html
if &term =~ '256color'
Expand Down Expand Up @@ -417,6 +426,11 @@ noremap L $
nnoremap ; :


" 插入模式跳转到括号尾部
" https://stackoverflow.com/questions/11037825/how-can-i-go-to-end-of-parenthesis-brackets-quotes-without-switching-insert-mode
inoremap <C-e> <C-o>A


" 命令行模式增强,ctrl - a到行首, -e 到行尾
cnoremap <C-j> <t_kd>
cnoremap <C-k> <t_ku>
Expand Down Expand Up @@ -519,6 +533,10 @@ vnoremap <leader>y "+y
" vnoremap <silent> p p`]
" nnoremap <silent> p p`]

" shift-j/k 上下移动选中代码块
vnoremap <silent> <s-J> :m '>+1<CR>gv=gv
vnoremap <silent> <s-K> :m '<-2<CR>gv=gv

" select all
map <Leader>sa ggVG

Expand Down Expand Up @@ -657,8 +675,15 @@ endif
set background=dark
set t_Co=256

colorscheme solarized
" colorscheme molokai
" colorscheme solarized
colorscheme molokai

highlight Normal ctermbg=none
" italic for vim: https://alexpearce.me/2014/05/italics-in-iterm2-vim-tmux/
" italic for tmux: https://github.com/tmux/tmux/issues/377
" term or iterm2, use the settings under others/italic
highlight Comment cterm=italic gui=italic
highlight search ctermfg=Yellow ctermbg=NONE cterm=bold,underline


" 设置标记一列的背景颜色和数字一行颜色一致
Expand All @@ -675,3 +700,7 @@ highlight clear SpellRare
highlight SpellRare term=underline cterm=underline
highlight clear SpellLocal
highlight SpellLocal term=underline cterm=underline

" Having longer updatetime (default is 4000 ms = 4 s) leads to noticeable
" delays and poor user experience.
set updatetime=300
Loading