Pastebin

Paste #10075: No description

< previous paste - next paste>

Pasted by Anonymous Coward

Download View as text

syn match todoString /"[^"]\+"/
hi link todoString String

syn match todoComment /#.*/
hi link todoComment Comment

syn match todoCategory /^@.\+/
"hi todoCategory ctermfg=red guifg=red
hi link todoCategory String

syn match todoDate /^\d\{4}-\d\{2}-\d\{2}/
hi link todoDate Identifier


" URLs start with a known protocol or www,web,w3.
syn match mailURL contains=@NoSpell `\v<(((https?|ftp|gopher)://|(mailto|file|news):)[^' 	<>"]+|(www|web|w3)[a-z0-9_-]*\.[a-z0-9._-]+\.[^' 	<>"]+)[a-z0-9/]`
syn match mailEmail contains=@NoSpell "\v[_=a-z\./+0-9-]+\@[a-z0-9._-]+\a{2}"
hi def link mailEmail		Special
hi def link mailURL		String


syn match todoIntentExp1	contained "\v^(    ?)"
syn match todoIntentExp2	contained "\v^(    ?){2}"
syn match todoIntentExp3	contained "\v^(    ?){3}"
syn match todoIntentExp4	contained "\v^(    ?){4}"
syn match todoIntentExp5	contained "\v^(    ?){5}"
syn match todoIntentExp6	contained "\v^(    ?){6}"

syn cluster mailLinks		contains=mailURL,mailEmail
syn cluster todoIntentExps	contains=todoIntentExp1,todoIntentExp2,todoIntentExp3,todoIntentExp4,todoIntentExp5,todoIntentExp6


" Even and odd quoted lines. Order is important here!
syn region	todoIntentd6	keepend contains=@mailLinks,@NoSpell start="^\z(\(\([a-z]\+>\|[]|}>]\)[ \t]*\)\{5}\([a-z]\+>\|[]|}>]\)\)" end="^\z1\@!" fold
syn region	todoIntentd5	keepend contains=todoIntentd6,@mailLinks,@NoSpell start="^\z(\(\([a-z]\+>\|[]|}>]\)[ \t]*\)\{4}\([a-z]\+>\|[]|}>]\)\)" end="^\z1\@!" fold
syn region	todoIntentd4	keepend contains=todoIntentd5,todoIntentd6,@mailLinks,@NoSpell start="^\z(\(\([a-z]\+>\|[]|}>]\)[ \t]*\)\{3}\([a-z]\+>\|[]|}>]\)\)" end="^\z1\@!" fold
syn region	todoIntentd3	keepend contains=todoIntentd4,todoIntentd5,todoIntentd6,mailVerbatim,mailHeader,@mailLinks,mailSignature,@NoSpell start="^\z(\(\([a-z]\+>\|[]|}>]\)[ \t]*\)\{2}\([a-z]\+>\|[]|}>]\)\)" end="^\z1\@!" fold
syn region	todoIntentd2	keepend contains=todoIntentd3,todoIntentd4,todoIntentd5,todoIntentd6,@mailLinks,@NoSpell start="^\z(\(\([a-z]\+>\|[]|}>]\)[ \t]*\)\{1}\([a-z]\+>\|[]|}>]\)\)" end="^\z1\@!" fold
syn region	todoIntentd1	keepend contains=todoIntentd2,todoIntentd3,todoIntentd4,todoIntentd5,todoIntentd6,@mailLinks,@NoSpell start="^\z([a-z]\+>\|[]|}>]\)" end="^\z1\@!" fold


hi def link todoIntentd1		Comment
hi def link todoIntentd3		todoIntentd1
hi def link todoIntentd5		todoIntentd1
hi def link todoIntentd2		Identifier
hi def link todoIntentd4		todoIntentd2
hi def link todoIntentd6		todoIntentd2
hi def link todoIntentExp1	todoIntentd1
hi def link todoIntentExp2	todoIntentd2
hi def link todoIntentExp3	todoIntentd3
hi def link todoIntentExp4	todoIntentd4
hi def link todoIntentExp5	todoIntentd5
hi def link todoIntentExp6	todoIntentd6

New Paste


Do not write anything in this field if you're a human.

Go to most recent paste.