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

Scripts update

Removed GetLatestVimScripts plugin (it's distributed with vim)
Added nice function for generating HTML from rst in rst/common.vim
Removd NERDtree (didn't used it at all)
Removed tasklist (same as above)
Removed eclim tools, leaved only buffer functionality
Small improvements in vimrc
This commit is contained in:
2010-08-29 19:58:17 +02:00
parent 51fd5661ec
commit 67fd7abec6
37 changed files with 1725 additions and 8138 deletions

View File

@@ -10,25 +10,49 @@ elseif exists("b:current_syntax")
finish
endif
"" use max highlighting - could be quite slow if there are too many wikifiles
if VimwikiGet('maxhi')
" Every WikiWord is nonexistent
if g:vimwiki_camel_case
execute 'syntax match VimwikiNoExistsLink /'.g:vimwiki_rxWikiWord.'/'
endif
execute 'syntax match VimwikiNoExistsLink /'.g:vimwiki_rxWikiLink1.'/'
execute 'syntax match VimwikiNoExistsLink /'.g:vimwiki_rxWikiLink2.'/'
" till we find them in vimwiki's path
call vimwiki#WikiHighlightLinks()
else
" A WikiWord (unqualifiedWikiName)
execute 'syntax match VimwikiLink /\<'.g:vimwiki_rxWikiWord.'\>/'
" A [[bracketed wiki word]]
execute 'syntax match VimwikiLink /'.g:vimwiki_rxWikiLink1.'/'
execute 'syntax match VimwikiLink /'.g:vimwiki_rxWikiLink2.'/'
" Links highlighting is controlled by vimwiki#highlight_links() function.
" It is called from setup_buffer_enter() function in the BufEnter autocommand.
" Load concrete Wiki syntax
execute 'runtime! syntax/vimwiki_'.VimwikiGet('syntax').'.vim'
" Concealed chars
if exists("+conceallevel")
syntax conceal on
endif
syn match VimwikiLinkChar contained /\[\[/
syn match VimwikiLinkChar contained /\]\]/
syn match VimwikiLinkChar contained /\[\[[^\[\]\|]\{-}|\ze.\{-}]]/
syn match VimwikiLinkChar contained /\[\[[^\[\]\|]\{-}]\[\ze.\{-}]]/
syn match VimwikiNoLinkChar contained /\[\[/
syn match VimwikiNoLinkChar contained /\]\]/
syn match VimwikiNoLinkChar contained /\[\[[^\[\]\|]\{-}|\ze.*]]/
syn match VimwikiNoLinkChar contained /\[\[[^\[\]\|]\{-}]\[\ze.*]]/
execute 'syn match VimwikiBoldChar contained /'.g:vimwiki_char_bold.'/'
execute 'syn match VimwikiItalicChar contained /'.g:vimwiki_char_italic.'/'
execute 'syn match VimwikiBoldItalicChar contained /'.g:vimwiki_char_bolditalic.'/'
execute 'syn match VimwikiItalicBoldChar contained /'.g:vimwiki_char_italicbold.'/'
execute 'syn match VimwikiCodeChar contained /'.g:vimwiki_char_code.'/'
execute 'syn match VimwikiDelTextChar contained /'.g:vimwiki_char_deltext.'/'
execute 'syn match VimwikiSuperScript contained /'.g:vimwiki_char_superscript.'/'
execute 'syn match VimwikiSubScript contained /'.g:vimwiki_char_subscript.'/'
if exists("+conceallevel")
syntax conceal off
endif
execute 'syntax match VimwikiLink `'.g:vimwiki_rxWeblink.'`'
" Non concealed chars
syn match VimwikiHeaderChar contained /\%(^\s*=\+\)\|\%(=\+\s*$\)/
execute 'syn match VimwikiBoldCharT contained /'.g:vimwiki_char_bold.'/'
execute 'syn match VimwikiItalicCharT contained /'.g:vimwiki_char_italic.'/'
execute 'syn match VimwikiBoldItalicCharT contained /'.g:vimwiki_char_bolditalic.'/'
execute 'syn match VimwikiItalicBoldCharT contained /'.g:vimwiki_char_italicbold.'/'
execute 'syn match VimwikiCodeCharT contained /'.g:vimwiki_char_code.'/'
execute 'syn match VimwikiDelTextCharT contained /'.g:vimwiki_char_deltext.'/'
execute 'syn match VimwikiSuperScriptT contained /'.g:vimwiki_char_superscript.'/'
execute 'syn match VimwikiSubScriptT contained /'.g:vimwiki_char_subscript.'/'
" Emoticons
syntax match VimwikiEmoticons /\%((.)\|:[()|$@]\|:-[DOPS()\]|$@]\|;)\|:'(\)/
@@ -36,16 +60,14 @@ syntax match VimwikiEmoticons /\%((.)\|:[()|$@]\|:-[DOPS()\]|$@]\|;)\|:'(\)/
let g:vimwiki_rxTodo = '\C\%(TODO:\|DONE:\|STARTED:\|FIXME:\|FIXED:\|XXX:\)'
execute 'syntax match VimwikiTodo /'. g:vimwiki_rxTodo .'/'
" Load concrete Wiki syntax
execute 'runtime! syntax/vimwiki_'.VimwikiGet('syntax').'.vim'
" Tables
" execute 'syntax match VimwikiTable /'.g:vimwiki_rxTable.'/'
syntax match VimwikiTableRow /\s*|.\+|\s*/
\ transparent contains=VimwikiCellSeparator,VimwikiLink,
\ VimwikiNoExistsLink,VimwikiEmoticons,VimwikiTodo,
\ VimwikiBold,VimwikiItalic,VimwikiBoldItalic,VimwikiItalicBold,
\ VimwikiDelText,VimwikiSuperScript,VimwikiSubScript,VimwikiCode
syntax match VimwikiTableRow /^\s*|.\+|\s*$/
\ transparent contains=VimwikiCellSeparator,VimwikiLinkT,
\ VimwikiNoExistsLinkT,VimwikiEmoticons,VimwikiTodo,
\ VimwikiBoldT,VimwikiItalicT,VimwikiBoldItalicT,VimwikiItalicBoldT,
\ VimwikiDelTextT,VimwikiSuperScriptT,VimwikiSubScriptT,VimwikiCodeT
syntax match VimwikiCellSeparator
\ /\%(|\)\|\%(-\@<=+\-\@=\)\|\%([|+]\@<=-\+\)/ contained
@@ -54,21 +76,29 @@ execute 'syntax match VimwikiList /'.g:vimwiki_rxListBullet.'/'
execute 'syntax match VimwikiList /'.g:vimwiki_rxListNumber.'/'
execute 'syntax match VimwikiList /'.g:vimwiki_rxListDefine.'/'
execute 'syntax match VimwikiBold /'.g:vimwiki_rxBold.'/'
execute 'syntax match VimwikiBold /'.g:vimwiki_rxBold.'/ contains=VimwikiBoldChar'
execute 'syntax match VimwikiBoldT /'.g:vimwiki_rxBold.'/ contained contains=VimwikiBoldCharT'
execute 'syntax match VimwikiItalic /'.g:vimwiki_rxItalic.'/'
execute 'syntax match VimwikiItalic /'.g:vimwiki_rxItalic.'/ contains=VimwikiItalicChar'
execute 'syntax match VimwikiItalicT /'.g:vimwiki_rxItalic.'/ contained contains=VimwikiItalicCharT'
execute 'syntax match VimwikiBoldItalic /'.g:vimwiki_rxBoldItalic.'/'
execute 'syntax match VimwikiBoldItalic /'.g:vimwiki_rxBoldItalic.'/ contains=VimwikiBoldItalicChar,VimwikiItalicBoldChar'
execute 'syntax match VimwikiBoldItalicT /'.g:vimwiki_rxBoldItalic.'/ contained contains=VimwikiBoldItalicChatT,VimwikiItalicBoldCharT'
execute 'syntax match VimwikiItalicBold /'.g:vimwiki_rxItalicBold.'/'
execute 'syntax match VimwikiItalicBold /'.g:vimwiki_rxItalicBold.'/ contains=VimwikiBoldItalicChar,VimwikiItalicBoldChar'
execute 'syntax match VimwikiItalicBoldT /'.g:vimwiki_rxItalicBold.'/ contained contains=VimwikiBoldItalicCharT,VimsikiItalicBoldCharT'
execute 'syntax match VimwikiDelText /'.g:vimwiki_rxDelText.'/'
execute 'syntax match VimwikiDelText /'.g:vimwiki_rxDelText.'/ contains=VimwikiDelTextChar'
execute 'syntax match VimwikiDelTextT /'.g:vimwiki_rxDelText.'/ contained contains=VimwikiDelTextChar'
execute 'syntax match VimwikiSuperScript /'.g:vimwiki_rxSuperScript.'/'
execute 'syntax match VimwikiSuperScript /'.g:vimwiki_rxSuperScript.'/ contains=VimwikiSuperScriptChar'
execute 'syntax match VimwikiSuperScriptT /'.g:vimwiki_rxSuperScript.'/ contained contains=VimwikiSuperScriptCharT'
execute 'syntax match VimwikiSubScript /'.g:vimwiki_rxSubScript.'/'
execute 'syntax match VimwikiSubScript /'.g:vimwiki_rxSubScript.'/ contains=VimwikiSubScriptChar'
execute 'syntax match VimwikiSubScriptT /'.g:vimwiki_rxSubScript.'/ contained contains=VimwikiSubScriptCharT'
execute 'syntax match VimwikiCode /'.g:vimwiki_rxCode.'/'
execute 'syntax match VimwikiCode /'.g:vimwiki_rxCode.'/ contains=VimwikiCodeChar'
execute 'syntax match VimwikiCodeT /'.g:vimwiki_rxCode.'/ contained contains=VimwikiCodeCharT'
" <hr> horizontal rule
execute 'syntax match VimwikiHR /'.g:vimwiki_rxHR.'/'
@@ -88,62 +118,107 @@ if g:vimwiki_hl_cb_checked
endif
" placeholders
syntax match VimwikiPlaceholder /^\s*%toc\%(\s.*\)\?$/
syntax match VimwikiPlaceholder /^\s*%toc\%(\s.*\)\?$/ contains=VimwikiPlaceholderParam
syntax match VimwikiPlaceholder /^\s*%nohtml\s*$/
syntax match VimwikiPlaceholder /^\s*%title\%(\s.*\)\?$/ contains=VimwikiPlaceholderParam
syntax match VimwikiPlaceholderParam /\s.*/ contained
" html tags
syntax match VimwikiHTMLtag '<br\s*/\?>'
syntax match VimwikiHTMLtag '<hr\s*/\?>'
let html_tags = join(split(g:vimwiki_valid_html_tags, '\s*,\s*'), '\|')
exe 'syntax match VimwikiHTMLtag #\c</\?\%('.html_tags.'\)\%(\s\{-1}\S\{-}\)\{-}\s*/\?>#'
execute 'syntax match VimwikiBold #\c<b>.\{-}</b># contains=VimwikiHTMLTag'
execute 'syntax match VimwikiItalic #\c<i>.\{-}</i># contains=VimwikiHTMLTag'
execute 'syntax match VimwikiUnderline #\c<u>.\{-}</u># contains=VimwikiHTMLTag'
syntax region VimwikiComment start='<!--' end='-->'
if !vimwiki#hl_exists("VimwikiHeader1")
execute 'syntax match VimwikiHeader /'.g:vimwiki_rxHeader.'/ contains=VimwikiTodo'
if g:vimwiki_hl_headers == 0
execute 'syntax match VimwikiHeader /'.g:vimwiki_rxHeader.'/ contains=VimwikiTodo,VimwikiHeaderChar'
else
" Header levels, 1-6
execute 'syntax match VimwikiHeader1 /'.g:vimwiki_rxH1.'/ contains=VimwikiTodo'
execute 'syntax match VimwikiHeader2 /'.g:vimwiki_rxH2.'/ contains=VimwikiTodo'
execute 'syntax match VimwikiHeader3 /'.g:vimwiki_rxH3.'/ contains=VimwikiTodo'
execute 'syntax match VimwikiHeader4 /'.g:vimwiki_rxH4.'/ contains=VimwikiTodo'
execute 'syntax match VimwikiHeader5 /'.g:vimwiki_rxH5.'/ contains=VimwikiTodo'
execute 'syntax match VimwikiHeader6 /'.g:vimwiki_rxH6.'/ contains=VimwikiTodo'
execute 'syntax match VimwikiHeader1 /'.g:vimwiki_rxH1.'/ contains=VimwikiTodo,VimwikiHeaderChar'
execute 'syntax match VimwikiHeader2 /'.g:vimwiki_rxH2.'/ contains=VimwikiTodo,VimwikiHeaderChar'
execute 'syntax match VimwikiHeader3 /'.g:vimwiki_rxH3.'/ contains=VimwikiTodo,VimwikiHeaderChar'
execute 'syntax match VimwikiHeader4 /'.g:vimwiki_rxH4.'/ contains=VimwikiTodo,VimwikiHeaderChar'
execute 'syntax match VimwikiHeader5 /'.g:vimwiki_rxH5.'/ contains=VimwikiTodo,VimwikiHeaderChar'
execute 'syntax match VimwikiHeader6 /'.g:vimwiki_rxH6.'/ contains=VimwikiTodo,VimwikiHeaderChar'
endif
" group names "{{{
if !vimwiki#hl_exists("VimwikiHeader1")
hi def link VimwikiHeader Title
else
hi def link VimwikiHeader1 Title
hi def link VimwikiHeader2 Title
hi def link VimwikiHeader3 Title
hi def link VimwikiHeader4 Title
hi def link VimwikiHeader5 Title
hi def link VimwikiHeader6 Title
endif
call vimwiki#setup_colors()
hi def VimwikiBold term=bold cterm=bold gui=bold
hi def link VimwikiBoldT VimwikiBold
hi def VimwikiItalic term=italic cterm=italic gui=italic
hi def link VimwikiItalicT VimwikiItalic
hi def VimwikiBoldItalic term=bold cterm=bold gui=bold,italic
hi def link VimwikiItalicBold VimwikiBoldItalic
hi def link VimwikiBoldItalicT VimwikiBoldItalic
hi def link VimwikiItalicBoldT VimwikiBoldItalic
hi def VimwikiUnderline gui=underline
hi def link VimwikiCode PreProc
hi def link VimwikiCodeT VimwikiCode
hi def link VimwikiNoExistsLink Error
hi def link VimwikiNoExistsLinkT VimwikiNoExistsLink
hi def link VimwikiPre PreProc
hi def link VimwikiPreT VimwikiPre
hi def link VimwikiLink Underlined
hi def link VimwikiLinkT Underlined
hi def link VimwikiList Function
hi def link VimwikiCheckBox VimwikiList
hi def link VimwikiCheckBoxDone Comment
hi def link VimwikiEmoticons Character
hi def link VimwikiDelText Constant
hi def link VimwikiDelTextT VimwikiDelText
hi def link VimwikiSuperScript Number
hi def link VimwikiSuperScriptT VimwikiSuperScript
hi def link VimwikiSubScript Number
hi def link VimwikiSubScriptT VimwikiSubScript
hi def link VimwikiTodo Todo
hi def link VimwikiComment Comment
hi def link VimwikiCellSeparator SpecialKey
hi def link VimwikiCellSeparator PreProc
hi def link VimwikiPlaceholder SpecialKey
hi def link VimwikiPlaceholderParam String
hi def link VimwikiHTMLtag SpecialKey
hi def link VimwikiBoldChar VimwikiIgnore
hi def link VimwikiItalicChar VimwikiIgnore
hi def link VimwikiBoldItalicChar VimwikiIgnore
hi def link VimwikiItalicBoldChar VimwikiIgnore
hi def link VimwikiDelTextChar VimwikiIgnore
hi def link VimwikiSuperScriptChar VimwikiIgnore
hi def link VimwikiSubScriptChar VimwikiIgnore
hi def link VimwikiCodeChar VimwikiIgnore
hi def link VimwikiHeaderChar VimwikiIgnore
hi def link VimwikiLinkChar VimwikiLink
hi def link VimwikiNoLinkChar VimwikiNoExistsLink
hi def link VimwikiBoldCharT VimwikiIgnore
hi def link VimwikiItalicCharT VimwikiIgnore
hi def link VimwikiBoldItalicCharT VimwikiIgnore
hi def link VimwikiItalicBoldCharT VimwikiIgnore
hi def link VimwikiDelTextCharT VimwikiIgnore
hi def link VimwikiSuperScriptCharT VimwikiIgnore
hi def link VimwikiSubScriptCharT VimwikiIgnore
hi def link VimwikiCodeCharT VimwikiIgnore
hi def link VimwikiHeaderCharT VimwikiIgnore
hi def link VimwikiLinkCharT VimwikiLinkT
hi def link VimwikiNoLinkCharT VimwikiNoExistsLinkT
"}}}
let b:current_syntax="vimwiki"
@@ -153,9 +228,9 @@ let nested = VimwikiGet('nested_syntaxes')
if !empty(nested)
for [hl_syntax, vim_syntax] in items(nested)
call vimwiki#nested_syntax(vim_syntax,
\ '^{{{\%(.*[[:blank:][:punct:]]\)\?'.
\ '^\s*{{{\%(.*[[:blank:][:punct:]]\)\?'.
\ hl_syntax.'\%([[:blank:][:punct:]].*\)\?',
\ '^}}}', 'VimwikiPre')
\ '^\s*}}}', 'VimwikiPre')
endfor
endif
"}}}