1
0
mirror of https://github.com/gryf/.vim.git synced 2025-12-17 19:40:29 +01:00

Update of lucius colorscheme and VCSCommand plugin

This commit is contained in:
2011-10-05 20:29:01 +02:00
parent 177790640d
commit 62aa951be8
5 changed files with 253 additions and 165 deletions

View File

@@ -17,7 +17,7 @@ ScriptID SourceID Filename
2540 11006 snipMate.vim 2540 11006 snipMate.vim
1697 12566 :AutoInstall: surround.vim 1697 12566 :AutoInstall: surround.vim
3465 15751 Tagbar 3465 15751 Tagbar
90 15797 vcscommand.vim 90 16616 vcscommand.vim
2226 15854 vimwiki.vim 2226 15854 vimwiki.vim
1334 6377 vst.vim 1334 6377 vst.vim
2321 9055 zoom.vim 2321 9055 zoom.vim
@@ -25,7 +25,7 @@ ScriptID SourceID Filename
2855 12456 github.vim 2855 12456 github.vim
1143 11833 inkpot.vim 1143 11833 inkpot.vim
2555 15432 jellybeans.vim 2555 15432 jellybeans.vim
2536 16288 lucius.vim 2536 16615 lucius.vim
3299 14475 sorcerer.vim 3299 14475 sorcerer.vim
1165 3741 tolerable.vim 1165 3741 tolerable.vim
3309 15759 vydark 3309 15759 vydark

View File

@@ -1,6 +1,6 @@
" Lucius vim color file " Lucius vim color file
" Maintainer: Jonathan Filip <jfilip1024@gmail.com> " Maintainer: Jonathan Filip <jfilip1024@gmail.com>
" Version: 6.03 " Version: 6.1.0
hi clear hi clear
if exists("syntax_on") if exists("syntax_on")
@@ -31,7 +31,7 @@ let colors_name="lucius"
" loaded, you can use the commands "LuciusLight" or "LuciusDark" to change " loaded, you can use the commands "LuciusLight" or "LuciusDark" to change
" schemes quickly. " schemes quickly.
" "
" Screeshots of the new version (6+): " Screenshots of the new version (6+):
" "
" * Dark: http://i.imgur.com/IzYcB.png " * Dark: http://i.imgur.com/IzYcB.png
" * Light: http://i.imgur.com/kfJcm.png " * Light: http://i.imgur.com/kfJcm.png
@@ -64,24 +64,28 @@ endif
" set colorcolumn=21,37,53,68,86,100 " set colorcolumn=21,37,53,68,86,100
if g:lucius_style == "dark" if g:lucius_style == "dark" || g:lucius_style == "blue"
hi Normal guifg=#e8e8e8 guibg=#202020 ctermfg=253 ctermbg=234 gui=none cterm=none hi Normal guifg=#e0e0e0 guibg=#202020 ctermfg=253 ctermbg=234 gui=none cterm=none
hi Comment guifg=#606060 guibg=NONE ctermfg=240 ctermbg=NONE gui=none cterm=none if g:lucius_style == "blue"
hi Normal guibg=#002b36
endif
hi Constant guifg=#c0e0a0 guibg=NONE ctermfg=150 ctermbg=NONE gui=none cterm=none hi Comment guifg=#707070 guibg=NONE ctermfg=240 ctermbg=NONE gui=none cterm=none
hi BConstant guifg=#c0e0a0 guibg=NONE ctermfg=150 ctermbg=NONE gui=bold cterm=bold
hi Identifier guifg=#a0e0d0 guibg=NONE ctermfg=115 ctermbg=NONE gui=none cterm=none hi Constant guifg=#e0e090 guibg=NONE ctermfg=187 ctermbg=NONE gui=none cterm=none
hi BIdentifier guifg=#a0e0d0 guibg=NONE ctermfg=115 ctermbg=NONE gui=bold cterm=bold hi BConstant guifg=#e0e090 guibg=NONE ctermfg=187 ctermbg=NONE gui=bold cterm=bold
hi Identifier guifg=#c0e0a0 guibg=NONE ctermfg=150 ctermbg=NONE gui=none cterm=none
hi BIdentifier guifg=#c0e0a0 guibg=NONE ctermfg=150 ctermbg=NONE gui=bold cterm=bold
hi Statement guifg=#80d0f0 guibg=NONE ctermfg=74 ctermbg=NONE gui=none cterm=none hi Statement guifg=#80d0f0 guibg=NONE ctermfg=74 ctermbg=NONE gui=none cterm=none
hi BStatement guifg=#80d0f0 guibg=NONE ctermfg=74 ctermbg=NONE gui=bold cterm=bold hi BStatement guifg=#80d0f0 guibg=NONE ctermfg=74 ctermbg=NONE gui=bold cterm=bold
hi PreProc guifg=#f0f0b0 guibg=NONE ctermfg=187 ctermbg=NONE gui=none cterm=none hi PreProc guifg=#a0e0d0 guibg=NONE ctermfg=115 ctermbg=NONE gui=none cterm=none
hi BPreProc guifg=#f0f0b0 guibg=NONE ctermfg=187 ctermbg=NONE gui=bold cterm=bold hi BPreProc guifg=#a0e0d0 guibg=NONE ctermfg=115 ctermbg=NONE gui=bold cterm=bold
hi Type guifg=#a0d0e0 guibg=NONE ctermfg=116 ctermbg=NONE gui=none cterm=none hi Type guifg=#a0d0e0 guibg=NONE ctermfg=116 ctermbg=NONE gui=none cterm=none
hi BType guifg=#a0d0e0 guibg=NONE ctermfg=116 ctermbg=NONE gui=bold cterm=bold hi BType guifg=#a0d0e0 guibg=NONE ctermfg=116 ctermbg=NONE gui=bold cterm=bold
@@ -91,60 +95,60 @@ if g:lucius_style == "dark"
" == Text Markup == " == Text Markup ==
hi Underlined guifg=fg guibg=NONE ctermfg=fg ctermbg=NONE gui=underline cterm=underline hi Underlined guifg=fg guibg=NONE ctermfg=fg ctermbg=NONE gui=underline cterm=underline
hi Error guifg=#e07070 guibg=#402020 ctermfg=167 ctermbg=236 gui=none cterm=none hi Error guifg=#e07070 guibg=#503030 ctermfg=167 ctermbg=236 gui=none cterm=none
hi Todo guifg=#e0e090 guibg=#404000 ctermfg=186 ctermbg=NONE gui=none cterm=none hi Todo guifg=#e0e090 guibg=#505000 ctermfg=186 ctermbg=NONE gui=none cterm=none
hi MatchParen guifg=bg guibg=#d0f080 ctermfg=bg ctermbg=192 gui=none cterm=bold hi MatchParen guifg=bg guibg=#c0e070 ctermfg=bg ctermbg=192 gui=none cterm=bold
hi NonText guifg=#405060 guibg=NONE ctermfg=24 ctermbg=NONE gui=none cterm=none hi NonText guifg=#405060 guibg=NONE ctermfg=24 ctermbg=NONE gui=none cterm=none
hi SpecialKey guifg=#406050 guibg=NONE ctermfg=23 ctermbg=NONE gui=none cterm=none hi SpecialKey guifg=#406050 guibg=NONE ctermfg=23 ctermbg=NONE gui=none cterm=none
hi Title guifg=#60c0e0 guibg=NONE ctermfg=74 ctermbg=NONE gui=bold cterm=bold hi Title guifg=#50b0d0 guibg=NONE ctermfg=74 ctermbg=NONE gui=bold cterm=bold
" == Text Selection == " == Text Selection ==
hi Cursor guifg=bg guibg=fg ctermfg=bg ctermbg=fg gui=none cterm=none hi Cursor guifg=bg guibg=fg ctermfg=bg ctermbg=fg gui=none cterm=none
hi CursorIM guifg=bg guibg=fg ctermfg=bg ctermbg=fg gui=none cterm=none hi CursorIM guifg=bg guibg=fg ctermfg=bg ctermbg=fg gui=none cterm=none
hi CursorColumn guifg=NONE guibg=#404040 ctermfg=NONE ctermbg=237 gui=none cterm=none hi CursorColumn guifg=NONE guibg=#484848 ctermfg=NONE ctermbg=237 gui=none cterm=none
hi CursorLine guifg=NONE guibg=#404040 ctermfg=NONE ctermbg=237 gui=none cterm=none hi CursorLine guifg=NONE guibg=#484848 ctermfg=NONE ctermbg=237 gui=none cterm=none
hi Visual guifg=NONE guibg=#304050 ctermfg=NONE ctermbg=24 gui=none cterm=none hi Visual guifg=NONE guibg=#205070 ctermfg=NONE ctermbg=24 gui=none cterm=none
hi VisualNOS guifg=fg guibg=NONE ctermfg=fg ctermbg=NONE gui=underline cterm=underline hi VisualNOS guifg=fg guibg=NONE ctermfg=fg ctermbg=NONE gui=underline cterm=underline
hi IncSearch guifg=bg guibg=#60e0e0 ctermfg=bg ctermbg=116 gui=none cterm=none hi IncSearch guifg=bg guibg=#50d0d0 ctermfg=bg ctermbg=116 gui=none cterm=none
hi Search guifg=bg guibg=#f0b030 ctermfg=bg ctermbg=214 gui=none cterm=none hi Search guifg=bg guibg=#e0a020 ctermfg=bg ctermbg=214 gui=none cterm=none
" == UI == " == UI ==
hi Pmenu guifg=bg guibg=#c0c0c0 ctermfg=bg ctermbg=252 gui=none cterm=none hi Pmenu guifg=#000000 guibg=#b0b0b0 ctermfg=bg ctermbg=252 gui=none cterm=none
hi PmenuSel guifg=#e0e0e0 guibg=#304050 ctermfg=fg ctermbg=24 gui=none cterm=none hi PmenuSel guifg=#e0e0e0 guibg=#205070 ctermfg=fg ctermbg=24 gui=none cterm=none
hi PMenuSbar guifg=#202020 guibg=#d0d0d0 ctermfg=bg ctermbg=254 gui=none cterm=none hi PMenuSbar guifg=bg guibg=#b0b0b0 ctermfg=bg ctermbg=254 gui=none cterm=none
hi PMenuThumb guifg=NONE guibg=#808080 ctermfg=fg ctermbg=244 gui=none cterm=none hi PMenuThumb guifg=NONE guibg=#808080 ctermfg=fg ctermbg=244 gui=none cterm=none
hi StatusLine guifg=#202020 guibg=#c0c0c0 ctermfg=bg ctermbg=252 gui=bold cterm=bold hi StatusLine guifg=bg guibg=#b0b0b0 ctermfg=bg ctermbg=252 gui=bold cterm=bold
hi StatusLineNC guifg=#404040 guibg=#c0c0c0 ctermfg=240 ctermbg=252 gui=none cterm=none hi StatusLineNC guifg=#404040 guibg=#b0b0b0 ctermfg=240 ctermbg=252 gui=none cterm=none
hi TabLine guifg=#202020 guibg=#e0e0e0 ctermfg=bg ctermbg=252 gui=none cterm=none hi TabLine guifg=bg guibg=#b0b0b0 ctermfg=bg ctermbg=252 gui=none cterm=none
hi TabLineFill guifg=#404040 guibg=#e0e0e0 ctermfg=240 ctermbg=252 gui=none cterm=none hi TabLineFill guifg=#404040 guibg=#b0b0b0 ctermfg=240 ctermbg=252 gui=none cterm=none
hi TabLineSel guifg=#e0e0e0 guibg=#304050 ctermfg=fg ctermbg=24 gui=bold cterm=bold hi TabLineSel guifg=#e0e0e0 guibg=#205070 ctermfg=fg ctermbg=24 gui=bold cterm=bold
hi VertSplit guifg=#606060 guibg=#c0c0c0 ctermfg=245 ctermbg=252 gui=none cterm=none hi VertSplit guifg=#606060 guibg=#b0b0b0 ctermfg=245 ctermbg=252 gui=none cterm=none
hi Folded guifg=#202020 guibg=#808080 ctermfg=bg ctermbg=246 gui=none cterm=none hi Folded guifg=bg guibg=#808080 ctermfg=bg ctermbg=246 gui=none cterm=none
hi FoldColumn guifg=#202020 guibg=#808080 ctermfg=bg ctermbg=246 gui=none cterm=none hi FoldColumn guifg=bg guibg=#808080 ctermfg=bg ctermbg=246 gui=none cterm=none
" == Spelling == " == Spelling =="{{{
hi SpellBad guisp=#ee0000 ctermfg=fg ctermbg=160 gui=undercurl cterm=undercurl hi SpellBad guisp=#ee0000 ctermfg=fg ctermbg=160 gui=undercurl cterm=undercurl
hi SpellCap guisp=#eeee00 ctermfg=bg ctermbg=226 gui=undercurl cterm=undercurl hi SpellCap guisp=#eeee00 ctermfg=bg ctermbg=226 gui=undercurl cterm=undercurl
hi SpellRare guisp=#ffa500 ctermfg=bg ctermbg=214 gui=undercurl cterm=undercurl hi SpellRare guisp=#ffa500 ctermfg=bg ctermbg=214 gui=undercurl cterm=undercurl
hi SpellLocal guisp=#ffa500 ctermfg=bg ctermbg=214 gui=undercurl cterm=undercurl hi SpellLocal guisp=#ffa500 ctermfg=bg ctermbg=214 gui=undercurl cterm=undercurl"}}}
" == Diff == " == Diff ==
hi DiffAdd guifg=fg guibg=#405040 ctermfg=fg ctermbg=22 gui=none cterm=none hi DiffAdd guifg=fg guibg=#405040 ctermfg=fg ctermbg=22 gui=none cterm=none
hi DiffChange guifg=fg guibg=#605040 ctermfg=fg ctermbg=58 gui=none cterm=none hi DiffChange guifg=fg guibg=#605040 ctermfg=fg ctermbg=58 gui=none cterm=none
hi DiffDelete guifg=fg guibg=#504040 ctermfg=fg ctermbg=52 gui=none cterm=none hi DiffDelete guifg=fg guibg=#504040 ctermfg=fg ctermbg=52 gui=none cterm=none
hi DiffText guifg=#d0c060 guibg=#605040 ctermfg=220 ctermbg=58 gui=bold cterm=bold hi DiffText guifg=#e0b050 guibg=#605040 ctermfg=220 ctermbg=58 gui=bold cterm=bold
" == Misc == " == Misc ==
hi Directory guifg=#c0e0b0 guibg=NONE ctermfg=151 ctermbg=NONE gui=none cterm=none hi Directory guifg=#b0d0a0 guibg=NONE ctermfg=151 ctermbg=NONE gui=none cterm=none
hi ErrorMsg guifg=#ee0000 guibg=NONE ctermfg=196 ctermbg=NONE gui=none cterm=none hi ErrorMsg guifg=#ee0000 guibg=NONE ctermfg=196 ctermbg=NONE gui=none cterm=none
hi SignColumn guifg=#a0b0b0 guibg=#282828 ctermfg=145 ctermbg=233 gui=none cterm=none hi SignColumn guifg=#a0b0b0 guibg=#282828 ctermfg=145 ctermbg=233 gui=none cterm=none
hi LineNr guifg=#202020 guibg=#808080 ctermfg=bg ctermbg=246 gui=none cterm=none hi LineNr guifg=bg guibg=#808080 ctermfg=bg ctermbg=246 gui=none cterm=none
hi MoreMsg guifg=#70d0f0 guibg=NONE ctermfg=117 ctermbg=NONE gui=none cterm=none hi MoreMsg guifg=#60c0d0 guibg=NONE ctermfg=117 ctermbg=NONE gui=none cterm=none
hi ModeMsg guifg=fg guibg=NONE ctermfg=fg ctermbg=NONE gui=none cterm=none hi ModeMsg guifg=fg guibg=NONE ctermfg=fg ctermbg=NONE gui=none cterm=none
hi Question guifg=fg guibg=NONE ctermfg=fg ctermbg=NONE gui=none cterm=none hi Question guifg=fg guibg=NONE ctermfg=fg ctermbg=NONE gui=none cterm=none
hi WarningMsg guifg=#e87870 guibg=NONE ctermfg=173 ctermbg=NONE gui=none cterm=none hi WarningMsg guifg=#e07060 guibg=NONE ctermfg=173 ctermbg=NONE gui=none cterm=none
hi WildMenu guifg=NONE guibg=#304050 ctermfg=NONE ctermbg=24 gui=none cterm=none hi WildMenu guifg=NONE guibg=#205070 ctermfg=NONE ctermbg=24 gui=none cterm=none
hi ColorColumn guifg=NONE guibg=#403630 ctermfg=NONE ctermbg=101 gui=none cterm=none hi ColorColumn guifg=NONE guibg=#484038 ctermfg=NONE ctermbg=101 gui=none cterm=none
hi Ignore guifg=bg ctermfg=bg hi Ignore guifg=bg ctermfg=bg
@@ -155,29 +159,29 @@ elseif g:lucius_style == "light"
hi Comment guifg=#909090 guibg=NONE ctermfg=246 ctermbg=NONE gui=none cterm=none hi Comment guifg=#909090 guibg=NONE ctermfg=246 ctermbg=NONE gui=none cterm=none
hi Constant guifg=#008000 guibg=NONE ctermfg=22 ctermbg=NONE gui=none cterm=none hi Constant guifg=#a05000 guibg=NONE ctermfg=130 ctermbg=NONE gui=none cterm=none
hi BConstant guifg=#008000 guibg=NONE ctermfg=22 ctermbg=NONE gui=bold cterm=bold hi BConstant guifg=#a05000 guibg=NONE ctermfg=130 ctermbg=NONE gui=bold cterm=bold
hi Identifier guifg=#009090 guibg=NONE ctermfg=30 ctermbg=NONE gui=none cterm=none hi Identifier guifg=#008000 guibg=NONE ctermfg=22 ctermbg=NONE gui=none cterm=none
hi BIdentifier guifg=#009090 guibg=NONE ctermfg=30 ctermbg=NONE gui=bold cterm=bold hi BIdentifier guifg=#008000 guibg=NONE ctermfg=22 ctermbg=NONE gui=bold cterm=bold
hi Statement guifg=#0030c0 guibg=NONE ctermfg=19 ctermbg=NONE gui=none cterm=none hi Statement guifg=#0040c0 guibg=NONE ctermfg=19 ctermbg=NONE gui=none cterm=none
hi BStatement guifg=#0030c0 guibg=NONE ctermfg=19 ctermbg=NONE gui=bold cterm=bold hi BStatement guifg=#0040c0 guibg=NONE ctermfg=19 ctermbg=NONE gui=bold cterm=bold
hi PreProc guifg=#a06000 guibg=NONE ctermfg=130 ctermbg=NONE gui=none cterm=none hi PreProc guifg=#009080 guibg=NONE ctermfg=30 ctermbg=NONE gui=none cterm=none
hi BPreProc guifg=#a06000 guibg=NONE ctermfg=130 ctermbg=NONE gui=bold cterm=bold hi BPreProc guifg=#009080 guibg=NONE ctermfg=30 ctermbg=NONE gui=bold cterm=bold
hi Type guifg=#0070b0 guibg=NONE ctermfg=25 ctermbg=NONE gui=none cterm=none hi Type guifg=#0070a0 guibg=NONE ctermfg=25 ctermbg=NONE gui=none cterm=none
hi BType guifg=#0070b0 guibg=NONE ctermfg=25 ctermbg=NONE gui=bold cterm=bold hi BType guifg=#0070a0 guibg=NONE ctermfg=25 ctermbg=NONE gui=bold cterm=bold
hi Special guifg=#700090 guibg=NONE ctermfg=5 ctermbg=NONE gui=none cterm=none hi Special guifg=#800080 guibg=NONE ctermfg=5 ctermbg=NONE gui=none cterm=none
hi BSpecial guifg=#700090 guibg=NONE ctermfg=5 ctermbg=NONE gui=bold cterm=bold hi BSpecial guifg=#800080 guibg=NONE ctermfg=5 ctermbg=NONE gui=bold cterm=bold
" == Text Markup == " == Text Markup ==
hi Underlined guifg=fg guibg=NONE ctermfg=fg ctermbg=NONE gui=underline cterm=underline hi Underlined guifg=fg guibg=NONE ctermfg=fg ctermbg=NONE gui=underline cterm=underline
hi Error guifg=#c02620 guibg=#f0c6c0 ctermfg=1 ctermbg=181 gui=none cterm=none hi Error guifg=#c02620 guibg=#f0c6c0 ctermfg=1 ctermbg=181 gui=none cterm=none
hi Todo guifg=#504000 guibg=#f6f080 ctermfg=58 ctermbg=228 gui=none cterm=none hi Todo guifg=#504000 guibg=#f6f080 ctermfg=58 ctermbg=228 gui=none cterm=none
hi MatchParen guifg=NONE guibg=#d0f080 ctermfg=NONE ctermbg=192 gui=none cterm=none hi MatchParen guifg=NONE guibg=#40d0d0 ctermfg=NONE ctermbg=80 gui=none cterm=none
hi NonText guifg=#b0c0d0 guibg=NONE ctermfg=146 ctermbg=NONE gui=none cterm=none hi NonText guifg=#b0c0d0 guibg=NONE ctermfg=146 ctermbg=NONE gui=none cterm=none
hi SpecialKey guifg=#b0d0c0 guibg=NONE ctermfg=151 ctermbg=NONE gui=none cterm=none hi SpecialKey guifg=#b0d0c0 guibg=NONE ctermfg=151 ctermbg=NONE gui=none cterm=none
hi Title guifg=#0060a0 guibg=NONE ctermfg=26 ctermbg=NONE gui=bold cterm=bold hi Title guifg=#0060a0 guibg=NONE ctermfg=26 ctermbg=NONE gui=bold cterm=bold
@@ -187,24 +191,24 @@ elseif g:lucius_style == "light"
hi CursorIM guifg=bg guibg=#505050 ctermfg=bg ctermbg=239 gui=none cterm=none hi CursorIM guifg=bg guibg=#505050 ctermfg=bg ctermbg=239 gui=none cterm=none
hi CursorColumn guifg=NONE guibg=#e8e8e8 ctermfg=NONE ctermbg=254 gui=none cterm=none hi CursorColumn guifg=NONE guibg=#e8e8e8 ctermfg=NONE ctermbg=254 gui=none cterm=none
hi CursorLine guifg=NONE guibg=#e8e8e8 ctermfg=NONE ctermbg=254 gui=none cterm=none hi CursorLine guifg=NONE guibg=#e8e8e8 ctermfg=NONE ctermbg=254 gui=none cterm=none
hi Visual guifg=NONE guibg=#d0e0f0 ctermfg=NONE ctermbg=153 gui=none cterm=none hi Visual guifg=NONE guibg=#b0d0f0 ctermfg=NONE ctermbg=153 gui=none cterm=none
hi VisualNOS guifg=fg guibg=NONE ctermfg=fg ctermbg=NONE gui=underline cterm=underline hi VisualNOS guifg=fg guibg=NONE ctermfg=fg ctermbg=NONE gui=underline cterm=underline
hi IncSearch guifg=#000000 guibg=#90d0d0 ctermfg=fg ctermbg=116 gui=none cterm=none hi IncSearch guifg=#000000 guibg=#90d0d0 ctermfg=fg ctermbg=116 gui=none cterm=none
hi Search guifg=#000000 guibg=#f0b060 ctermfg=fg ctermbg=215 gui=none cterm=none hi Search guifg=#000000 guibg=#f0b060 ctermfg=fg ctermbg=215 gui=none cterm=none
" == UI == " == UI ==
hi Pmenu guifg=#ffffff guibg=#505050 ctermfg=231 ctermbg=239 gui=none cterm=none hi Pmenu guifg=bg guibg=#505050 ctermfg=231 ctermbg=239 gui=none cterm=none
hi PmenuSel guifg=#000000 guibg=#d0e0f0 ctermfg=16 ctermbg=153 gui=none cterm=none hi PmenuSel guifg=#000000 guibg=#c0e0ff ctermfg=16 ctermbg=153 gui=none cterm=none
hi PMenuSbar guifg=#ffffff guibg=#404040 ctermfg=231 ctermbg=238 gui=none cterm=none hi PMenuSbar guifg=bg guibg=#404040 ctermfg=231 ctermbg=238 gui=none cterm=none
hi PMenuThumb guifg=#000000 guibg=#a0a0a0 ctermfg=16 ctermbg=247 gui=none cterm=none hi PMenuThumb guifg=#000000 guibg=#a0a0a0 ctermfg=16 ctermbg=247 gui=none cterm=none
hi StatusLine guifg=#ffffff guibg=#505050 ctermfg=231 ctermbg=239 gui=bold cterm=bold hi StatusLine guifg=bg guibg=#505050 ctermfg=231 ctermbg=239 gui=bold cterm=bold
hi StatusLineNC guifg=#e0e0e0 guibg=#505050 ctermfg=254 ctermbg=239 gui=none cterm=none hi StatusLineNC guifg=#e0e0e0 guibg=#505050 ctermfg=254 ctermbg=239 gui=none cterm=none
hi TabLine guifg=#ffffff guibg=#505050 ctermfg=231 ctermbg=239 gui=none cterm=none hi TabLine guifg=bg guibg=#505050 ctermfg=231 ctermbg=239 gui=none cterm=none
hi TabLineFill guifg=#a0a0a0 guibg=#505050 ctermfg=247 ctermbg=239 gui=none cterm=none hi TabLineFill guifg=#a0a0a0 guibg=#505050 ctermfg=247 ctermbg=239 gui=none cterm=none
hi TabLineSel guifg=#000000 guibg=#d0e0f0 ctermfg=16 ctermbg=153 gui=none cterm=none hi TabLineSel guifg=#000000 guibg=#c0e0ff ctermfg=16 ctermbg=153 gui=none cterm=none
hi VertSplit guifg=#868686 guibg=#505050 ctermfg=102 ctermbg=239 gui=none cterm=none hi VertSplit guifg=#868686 guibg=#505050 ctermfg=102 ctermbg=239 gui=none cterm=none
hi Folded guifg=#ffffff guibg=#a0a0a0 ctermfg=231 ctermbg=247 gui=none cterm=none hi Folded guifg=bg guibg=#a0a0a0 ctermfg=231 ctermbg=247 gui=none cterm=none
hi FoldColumn guifg=#ffffff guibg=#a0a0a0 ctermfg=231 ctermbg=247 gui=none cterm=none hi FoldColumn guifg=bg guibg=#a0a0a0 ctermfg=231 ctermbg=247 gui=none cterm=none
" == Spelling == " == Spelling ==
hi SpellBad guisp=#ee0000 ctermbg=210 gui=undercurl cterm=undercurl hi SpellBad guisp=#ee0000 ctermbg=210 gui=undercurl cterm=undercurl
@@ -219,15 +223,15 @@ elseif g:lucius_style == "light"
hi DiffText guifg=#d05000 guibg=#e0d6c0 ctermfg=160 ctermbg=187 gui=bold cterm=bold hi DiffText guifg=#d05000 guibg=#e0d6c0 ctermfg=160 ctermbg=187 gui=bold cterm=bold
" == Misc == " == Misc ==
hi Directory guifg=#009040 guibg=NONE ctermfg=29 ctermbg=NONE gui=none cterm=none hi Directory guifg=#008000 guibg=NONE ctermfg=29 ctermbg=NONE gui=none cterm=none
hi ErrorMsg guifg=#a00000 guibg=NONE ctermfg=124 ctermbg=NONE gui=none cterm=none hi ErrorMsg guifg=#a00000 guibg=NONE ctermfg=124 ctermbg=NONE gui=none cterm=none
hi SignColumn guifg=#708090 guibg=#f8f8f8 ctermfg=66 ctermbg=231 gui=none cterm=none hi SignColumn guifg=#708090 guibg=#f8f8f8 ctermfg=66 ctermbg=231 gui=none cterm=none
hi LineNr guifg=#ffffff guibg=#a0a0a0 ctermfg=231 ctermbg=247 gui=none cterm=none hi LineNr guifg=bg guibg=#a0a0a0 ctermfg=231 ctermbg=247 gui=none cterm=none
hi MoreMsg guifg=#2060c0 guibg=NONE ctermfg=4 ctermbg=NONE gui=none cterm=none hi MoreMsg guifg=#2060c0 guibg=NONE ctermfg=4 ctermbg=NONE gui=none cterm=none
hi ModeMsg guifg=#000000 guibg=NONE ctermfg=16 ctermbg=NONE gui=none cterm=none hi ModeMsg guifg=#000000 guibg=NONE ctermfg=16 ctermbg=NONE gui=none cterm=none
hi Question guifg=fg guibg=NONE ctermfg=NONE ctermbg=NONE gui=none cterm=none hi Question guifg=fg guibg=NONE ctermfg=NONE ctermbg=NONE gui=none cterm=none
hi WarningMsg guifg=#d04020 guibg=NONE ctermfg=9 ctermbg=NONE gui=none cterm=none hi WarningMsg guifg=#b03000 guibg=NONE ctermfg=9 ctermbg=NONE gui=none cterm=none
hi WildMenu guifg=#000000 guibg=#d0e0f0 ctermfg=16 ctermbg=153 gui=none cterm=none hi WildMenu guifg=#000000 guibg=#c0e0ff ctermfg=16 ctermbg=153 gui=none cterm=none
hi ColorColumn guifg=NONE guibg=#f0f0e0 ctermfg=NONE ctermbg=230 gui=none cterm=none hi ColorColumn guifg=NONE guibg=#f0f0e0 ctermfg=NONE ctermbg=230 gui=none cterm=none
hi Ignore guifg=bg ctermfg=bg hi Ignore guifg=bg ctermfg=bg
@@ -235,11 +239,11 @@ elseif g:lucius_style == "light"
endif endif
" == Vimwiki Colors == " == Vimwiki Colors ==
hi link VimwikiHeader1 BConstant hi link VimwikiHeader1 BIdentifier
hi link VimwikiHeader2 BIdentifier hi link VimwikiHeader2 BPreProc
hi link VimwikiHeader3 BStatement hi link VimwikiHeader3 BStatement
hi link VimwikiHeader4 BSpecial hi link VimwikiHeader4 BSpecial
hi link VimwikiHeader5 BPreProc hi link VimwikiHeader5 BConstant
hi link VimwikiHeader6 BType hi link VimwikiHeader6 BType
" == Tagbar Colors == " == Tagbar Colors ==
@@ -250,4 +254,6 @@ hi link TagbarAccessPrivate PreProc
" == Commands == " == Commands ==
command! LuciusLight let g:lucius_style = "light" | colorscheme lucius command! LuciusLight let g:lucius_style = "light" | colorscheme lucius
command! LuciusDark let g:lucius_style = "dark" | colorscheme lucius command! LuciusDark let g:lucius_style = "dark" | colorscheme lucius
command! LuciusBlue let g:lucius_style = "blue" | colorscheme lucius

View File

@@ -210,6 +210,7 @@ VCSCommandSVNDiffOpt vcscommand.txt /*VCSCommandSVNDiffOpt*
VCSCommandSVNExec vcscommand.txt /*VCSCommandSVNExec* VCSCommandSVNExec vcscommand.txt /*VCSCommandSVNExec*
VCSCommandSplit vcscommand.txt /*VCSCommandSplit* VCSCommandSplit vcscommand.txt /*VCSCommandSplit*
VCSCommandVCSTypeOverride vcscommand.txt /*VCSCommandVCSTypeOverride* VCSCommandVCSTypeOverride vcscommand.txt /*VCSCommandVCSTypeOverride*
VCSCommandVCSTypePreference vcscommand.txt /*VCSCommandVCSTypePreference*
VimwikiWeblinkHandler vimwiki.txt /*VimwikiWeblinkHandler* VimwikiWeblinkHandler vimwiki.txt /*VimwikiWeblinkHandler*
abc fuf.txt /*abc* abc fuf.txt /*abc*
b:VCSCommandCommand vcscommand.txt /*b:VCSCommandCommand* b:VCSCommandCommand vcscommand.txt /*b:VCSCommandCommand*

View File

@@ -447,6 +447,7 @@ The following variables are available:
|VCSCommandSVNDiffOpt| |VCSCommandSVNDiffOpt|
|VCSCommandSVNExec| |VCSCommandSVNExec|
|VCSCommandVCSTypeOverride| |VCSCommandVCSTypeOverride|
|VCSCommandVCSTypePreference|
VCSCommandCommitOnWrite *VCSCommandCommitOnWrite* VCSCommandCommitOnWrite *VCSCommandCommitOnWrite*
@@ -593,6 +594,13 @@ element is a regular expression that will be matched against the full file
name of a given buffer. If it matches, the second element will be used as the name of a given buffer. If it matches, the second element will be used as the
VCS type. VCS type.
VCSCommandVCSTypePreference *VCSCommandVCSTypePreference*
This variable allows the VCS type detection to be weighted towards a specific
VCS, in case more than one potential VCS is detected as useable. The format
of the variable is either a list or a space-separated string containing the
ordered-by-preference abbreviations of the preferred VCS types.
5.2 VCSCommand events *vcscommand-events* 5.2 VCSCommand events *vcscommand-events*
For additional customization, vcscommand can trigger user-defined events. For additional customization, vcscommand can trigger user-defined events.

View File

@@ -272,6 +272,13 @@
" full file name of a given buffer. If it matches, the second element will " full file name of a given buffer. If it matches, the second element will
" be used as the VCS type. " be used as the VCS type.
" "
" VCSCommandVCSTypePreference
" This variable allows the VCS type detection to be weighted towards a
" specific VCS, in case more than one potential VCS is detected as useable.
" The format of the variable is either a list or a space-separated string
" containing the ordered-by-preference abbreviations of the preferred VCS
" types.
"
" Event documentation {{{2 " Event documentation {{{2
" For additional customization, VCSCommand.vim uses User event autocommand " For additional customization, VCSCommand.vim uses User event autocommand
" hooks. Each event is in the VCSCommand group, and different patterns " hooks. Each event is in the VCSCommand group, and different patterns
@@ -350,8 +357,8 @@ let s:VCSCommandUtility = {}
" plugin-specific information: {vcs -> [script, {command -> function}, {key -> mapping}]} " plugin-specific information: {vcs -> [script, {command -> function}, {key -> mapping}]}
let s:plugins = {} let s:plugins = {}
" temporary values of overridden configuration variables " Stack of dictionaries representing nested options
let s:optionOverrides = {} let s:executionContext = []
" state flag used to vary behavior of certain automated actions " state flag used to vary behavior of certain automated actions
let s:isEditFileRunning = 0 let s:isEditFileRunning = 0
@@ -376,15 +383,27 @@ function! s:VCSCommandUtility.system(...)
set sxq=\" set sxq=\"
endif endif
try try
if exists('*iconv') let output = call('system', a:000)
return iconv(call('system', a:000), &tenc, &enc) if exists('*iconv') && has('multi_byte')
if(strlen(&tenc) && &tenc != &enc)
let output = iconv(output, &tenc, &enc)
else
let originalBuffer = VCSCommandGetOriginalBuffer(VCSCommandGetOption('VCSCommandEncodeAsFile', 0))
if originalBuffer
let fenc = getbufvar(originalBuffer, '&fenc')
if fenc != &enc
let output = iconv(output, fenc, &enc)
endif
endif
endif
endif endif
return call('system', a:000)
finally finally
if exists("save_sxq") if exists("save_sxq")
let &sxq = save_sxq let &sxq = save_sxq
endif endif
endtry endtry
return output
endfunction endfunction
" Function: s:VCSCommandUtility.addMenuItem(shortcut, command) {{{2 " Function: s:VCSCommandUtility.addMenuItem(shortcut, command) {{{2
@@ -396,6 +415,20 @@ function! s:VCSCommandUtility.addMenuItem(shortcut, command)
endif endif
endfunction endfunction
" Function: s:VCSCommandUtility.pushContext(context) {{{2
" Adds a dictionary containing current options to the stack.
function! s:VCSCommandUtility.pushContext(context)
call insert(s:executionContext, a:context)
endfunction
" Function: s:VCSCommandUtility.popContext() {{{2
" Removes a dictionary containing current options from the stack.
function! s:VCSCommandUtility.popContext()
call remove(s:executionContext, 0)
endfunction
" Function: s:ClearMenu() {{{2 " Function: s:ClearMenu() {{{2
" Removes all VCSCommand menu items " Removes all VCSCommand menu items
function! s:ClearMenu() function! s:ClearMenu()
@@ -545,6 +578,64 @@ function! s:EditFile(command, originalBuffer, statusText)
endtry endtry
endfunction endfunction
" Function: s:IdentifyVCSType() {{{2
" This function implements the non-cached identification strategy for
" VcsCommandGetVCSType().
"
" Returns: VCS type name identified for the given buffer; an exception is
" thrown in case no type can be identified.
function! s:IdentifyVCSType(buffer)
if exists("g:VCSCommandVCSTypeOverride")
let fullpath = fnamemodify(bufname(a:buffer), ':p')
for [path, vcsType] in g:VCSCommandVCSTypeOverride
if match(fullpath, path) > -1
return vcsType
endif
endfor
endif
let matches = []
let exactMatch = ''
let exactMatchCount = 0
for vcsType in keys(s:plugins)
let identified = s:plugins[vcsType][1].Identify(a:buffer)
if identified
if identified == g:VCSCOMMAND_IDENTIFY_EXACT
let exactMatch = vcsType
let exactMatchCount += 1
endif
call add(matches, [vcsType, identified])
endif
endfor
if len(matches) == 1
return matches[0][0]
elseif len(matches) == 0
throw 'No suitable plugin'
else
let preferences = VCSCommandGetOption("VCSCommandVCSTypePreference", [])
if len(preferences) > 0
if type(preferences) == 1
let listPreferences = split(preferences, '\W\+')
unlet preferences
let preferences = listPreferences
endif
for preferred in preferences
for [vcsType, identified] in matches
if vcsType ==? preferred
return vcsType
endif
endfor
endfor
endif
if exactMatchCount == 1
return exactMatch
endif
throw 'can''t identify VCS type for current buffer due to too many matching VCS: ' . join(map(matches, 'v:val[0]'))
endif
endfunction
" Function: s:SetupScratchBuffer(command, vcsType, originalBuffer, statusText) {{{2 " Function: s:SetupScratchBuffer(command, vcsType, originalBuffer, statusText) {{{2
" Creates convenience buffer variables and the name of a vcscommand result " Creates convenience buffer variables and the name of a vcscommand result
" buffer. " buffer.
@@ -625,21 +716,6 @@ function! s:MarkOrigBufferForSetup(buffer)
return a:buffer return a:buffer
endfunction endfunction
" Function: s:OverrideOption(option, [value]) {{{2
" Provides a temporary override for the given VCS option. If no value is
" passed, the override is disabled.
function! s:OverrideOption(option, ...)
if a:0 == 0
call remove(s:optionOverrides[a:option], -1)
else
if !has_key(s:optionOverrides, a:option)
let s:optionOverrides[a:option] = []
endif
call add(s:optionOverrides[a:option], a:1)
endif
endfunction
" Function: s:WipeoutCommandBuffers() {{{2 " Function: s:WipeoutCommandBuffers() {{{2
" Clears all current VCS output buffers of the specified type for a given source. " Clears all current VCS output buffers of the specified type for a given source.
@@ -721,6 +797,7 @@ endfunction
" Function: s:VCSAnnotate(...) {{{2 " Function: s:VCSAnnotate(...) {{{2
function! s:VCSAnnotate(bang, ...) function! s:VCSAnnotate(bang, ...)
call s:VCSCommandUtility.pushContext({'VCSCommandEncodeAsFile': bufnr('%')})
try try
let line = line('.') let line = line('.')
let currentBuffer = bufnr('%') let currentBuffer = bufnr('%')
@@ -774,6 +851,8 @@ function! s:VCSAnnotate(bang, ...)
catch catch
call s:ReportError(v:exception) call s:ReportError(v:exception)
return -1 return -1
finally
call s:VCSCommandUtility.popContext()
endtry endtry
endfunction endfunction
@@ -841,6 +920,11 @@ endfunction
" Function: s:VCSFinishCommit(logMessageList, originalBuffer) {{{2 " Function: s:VCSFinishCommit(logMessageList, originalBuffer) {{{2
function! s:VCSFinishCommit(logMessageList, originalBuffer) function! s:VCSFinishCommit(logMessageList, originalBuffer)
let messageFileName = tempname() let messageFileName = tempname()
if exists('*iconv') && has('multi_byte')
if(strlen(&tenc) && &tenc != &enc)
call map(a:logMessageList, 'iconv(v:val, &enc, &tenc)')
endif
endif
call writefile(a:logMessageList, messageFileName) call writefile(a:logMessageList, messageFileName)
try try
let resultBuffer = s:ExecuteVCSCommand('Commit', [messageFileName]) let resultBuffer = s:ExecuteVCSCommand('Commit', [messageFileName])
@@ -877,6 +961,8 @@ function! s:VCSGotoOriginal(bang)
endfunction endfunction
function! s:VCSDiff(...) "{{{2 function! s:VCSDiff(...) "{{{2
call s:VCSCommandUtility.pushContext({'VCSCommandEncodeAsFile': bufnr('%')})
try
let resultBuffer = s:ExecuteVCSCommand('Diff', a:000) let resultBuffer = s:ExecuteVCSCommand('Diff', a:000)
if resultBuffer > 0 if resultBuffer > 0
let &filetype = 'diff' let &filetype = 'diff'
@@ -884,14 +970,22 @@ function! s:VCSDiff(...) "{{{2
echomsg 'No differences found' echomsg 'No differences found'
endif endif
return resultBuffer return resultBuffer
finally
call s:VCSCommandUtility.popContext()
endtry
endfunction endfunction
function! s:VCSReview(...) "{{{2 function! s:VCSReview(...) "{{{2
call s:VCSCommandUtility.pushContext({'VCSCommandEncodeAsFile': bufnr('%')})
try
let resultBuffer = s:ExecuteVCSCommand('Review', a:000) let resultBuffer = s:ExecuteVCSCommand('Review', a:000)
if resultBuffer > 0 if resultBuffer > 0
let &filetype = getbufvar(b:VCSCommandOriginalBuffer, '&filetype') let &filetype = getbufvar(b:VCSCommandOriginalBuffer, '&filetype')
endif endif
return resultBuffer return resultBuffer
finally
call s:VCSCommandUtility.popContext()
endtry
endfunction endfunction
" Function: s:VCSVimDiff(...) {{{2 " Function: s:VCSVimDiff(...) {{{2
@@ -931,11 +1025,11 @@ function! s:VCSVimDiff(...)
diffthis diffthis
let t:vcsCommandVimDiffScratchList = [resultBuffer] let t:vcsCommandVimDiffScratchList = [resultBuffer]
" If no split method is defined, cheat, and set it to vertical. " If no split method is defined, cheat, and set it to vertical.
call s:VCSCommandUtility.pushContext({'VCSCommandSplit': orientation})
try try
call s:OverrideOption('VCSCommandSplit', orientation)
let resultBuffer = s:VCSReview(a:2) let resultBuffer = s:VCSReview(a:2)
finally finally
call s:OverrideOption('VCSCommandSplit') call s:VCSCommandUtility.popContext()
endtry endtry
if resultBuffer < 0 if resultBuffer < 0
echomsg 'Can''t open revision ' . a:1 echomsg 'Can''t open revision ' . a:1
@@ -945,11 +1039,8 @@ function! s:VCSVimDiff(...)
diffthis diffthis
let t:vcsCommandVimDiffScratchList += [resultBuffer] let t:vcsCommandVimDiffScratchList += [resultBuffer]
else else
" Add new buffer " Add new buffer. Force splitting behavior, otherwise why use vimdiff?
call s:OverrideOption('VCSCommandEdit', 'split') call s:VCSCommandUtility.pushContext({'VCSCommandEdit': 'split', 'VCSCommandSplit': orientation})
try
" Force splitting behavior, otherwise why use vimdiff?
call s:OverrideOption('VCSCommandSplit', orientation)
try try
if(a:0 == 0) if(a:0 == 0)
let resultBuffer = s:VCSReview() let resultBuffer = s:VCSReview()
@@ -957,10 +1048,7 @@ function! s:VCSVimDiff(...)
let resultBuffer = s:VCSReview(a:1) let resultBuffer = s:VCSReview(a:1)
endif endif
finally finally
call s:OverrideOption('VCSCommandSplit') call s:VCSCommandUtility.popContext()
endtry
finally
call s:OverrideOption('VCSCommandEdit')
endtry endtry
if resultBuffer < 0 if resultBuffer < 0
echomsg 'Can''t open current revision' echomsg 'Can''t open current revision'
@@ -1021,53 +1109,31 @@ endfunction
" Section: Public functions {{{1 " Section: Public functions {{{1
" Function: VCSCommandGetVCSType() {{{2 " Function: VCSCommandGetVCSType() {{{2
" Sets the b:VCSCommandVCSType variable in the given buffer to the " This function sets the b:VCSCommandVCSType variable in the given buffer to the
" appropriate source control system name. " appropriate source control system name and returns the same name.
" "
" This uses the Identify extension function to test the buffer. If the " Returns: VCS type name identified for the given buffer. An exception is
" Identify function returns VCSCOMMAND_IDENTIFY_EXACT, the match is considered " thrown if no type can be identified.
" exact. If the Identify function returns VCSCOMMAND_IDENTIFY_INEXACT, the "
" match is considered inexact, and is only applied if no exact match is found. " Rules for determining type:
" Multiple inexact matches is currently considered an error. " 1. use previously-cached value
" 2. use value from 'VCSCommandVCSTypeOverride'
" 3. use single match
" 4. use first matching value from 'VCSCommandTypePreference'
" 5. use single exact match
" 6. error if multiple matching types
" 7. error if no matching types
function! VCSCommandGetVCSType(buffer) function! VCSCommandGetVCSType(buffer)
" gryf: if there is such variable, use defined VCS type let vcsType = VCSCommandGetOption('VCSCommandVCSTypeExplicitOverride', '')
if exists("g:VCSTypeOverride") if len(vcsType) == 0
return g:VCSTypeOverride
endif
let vcsType = getbufvar(a:buffer, 'VCSCommandVCSType') let vcsType = getbufvar(a:buffer, 'VCSCommandVCSType')
if strlen(vcsType) > 0 if strlen(vcsType) == 0
return vcsType let vcsType = s:IdentifyVCSType(a:buffer)
endif
if exists("g:VCSCommandVCSTypeOverride")
let fullpath = fnamemodify(bufname(a:buffer), ':p')
for [path, vcsType] in g:VCSCommandVCSTypeOverride
if match(fullpath, path) > -1
call setbufvar(a:buffer, 'VCSCommandVCSType', vcsType) call setbufvar(a:buffer, 'VCSCommandVCSType', vcsType)
endif
endif
return vcsType return vcsType
endif
endfor
endif
let matches = []
for vcsType in keys(s:plugins)
let identified = s:plugins[vcsType][1].Identify(a:buffer)
if identified
if identified == g:VCSCOMMAND_IDENTIFY_EXACT
let matches = [vcsType]
break
else
let matches += [vcsType]
endif
endif
endfor
if len(matches) == 1
call setbufvar(a:buffer, 'VCSCommandVCSType', matches[0])
return matches[0]
elseif len(matches) == 0
throw 'No suitable plugin'
else
throw 'Too many matching VCS: ' . join(matches)
endif
endfunction endfunction
" Function: VCSCommandChdir(directory) {{{2 " Function: VCSCommandChdir(directory) {{{2
@@ -1078,7 +1144,11 @@ function! VCSCommandChdir(directory)
if exists("*haslocaldir") && haslocaldir() if exists("*haslocaldir") && haslocaldir()
let command = 'lcd' let command = 'lcd'
endif endif
if exists("*fnameescape")
execute command fnameescape(a:directory) execute command fnameescape(a:directory)
else
execute command escape(a:directory, ' ')
endif
endfunction endfunction
" Function: VCSCommandChangeToCurrentFileDir() {{{2 " Function: VCSCommandChangeToCurrentFileDir() {{{2
@@ -1230,9 +1300,12 @@ endfunction
" searched in the window, buffer, then global spaces. " searched in the window, buffer, then global spaces.
function! VCSCommandGetOption(name, default) function! VCSCommandGetOption(name, default)
if has_key(s:optionOverrides, a:name) && len(s:optionOverrides[a:name]) > 0 for context in s:executionContext
return s:optionOverrides[a:name][-1] if has_key(context, a:name)
elseif exists('w:' . a:name) return context[a:name]
endif
endfor
if exists('w:' . a:name)
return w:{a:name} return w:{a:name}
elseif exists('b:' . a:name) elseif exists('b:' . a:name)
return b:{a:name} return b:{a:name}