7
|
1 " Vim syntax file
|
|
2 " Language: Remind
|
1121
|
3 " Maintainer: Davide Alberani <alberanid@libero.it>
|
2034
|
4 " Last Change: 18 Sep 2009
|
|
5 " Version: 0.5
|
1121
|
6 " URL: http://erlug.linux.it/~da/vim/syntax/remind.vim
|
7
|
7 "
|
2034
|
8 " remind is a sophisticated reminder service
|
|
9 " you can download remind from:
|
|
10 " http://www.roaringpenguin.com/penguin/open_source_remind.php
|
7
|
11
|
|
12 if version < 600
|
|
13 syntax clear
|
|
14 elseif exists("b:current_syntax")
|
|
15 finish
|
|
16 endif
|
|
17
|
2034
|
18 " shut case off.
|
7
|
19 syn case ignore
|
|
20
|
|
21 syn keyword remindCommands REM OMIT SET FSET UNSET
|
2034
|
22 syn keyword remindExpiry UNTIL FROM SCANFROM SCAN WARN SCHED
|
7
|
23 syn keyword remindTag PRIORITY TAG
|
|
24 syn keyword remindTimed AT DURATION
|
|
25 syn keyword remindMove ONCE SKIP BEFORE AFTER
|
2034
|
26 syn keyword remindSpecial INCLUDE INC BANNER PUSH-OMIT-CONTEXT PUSH CLEAR-OMIT-CONTEXT CLEAR POP-OMIT-CONTEXT POP COLOR
|
7
|
27 syn keyword remindRun MSG MSF RUN CAL SATISFY SPECIAL PS PSFILE SHADE MOON
|
|
28 syn keyword remindConditional IF ELSE ENDIF IFTRIG
|
2034
|
29 syn keyword remindDebug DEBUG DUMPVARS DUMP ERRMSG FLUSH PRESERVE
|
7
|
30 syn match remindComment "#.*$"
|
|
31 syn region remindString start=+'+ end=+'+ skip=+\\\\\|\\'+ oneline
|
|
32 syn region remindString start=+"+ end=+"+ skip=+\\\\\|\\"+ oneline
|
|
33 syn match remindVar "\$[_a-zA-Z][_a-zA-Z0-9]*"
|
|
34 syn match remindSubst "%[^ ]"
|
|
35 syn match remindAdvanceNumber "\(\*\|+\|-\|++\|--\)[0-9]\+"
|
2034
|
36 " XXX: use different separators for dates and times?
|
|
37 syn match remindDateSeparators "[/:@\.-]" contained
|
|
38 syn match remindTimes "[0-9]\{1,2}[:\.][0-9]\{1,2}" contains=remindDateSeparators
|
|
39 " XXX: why not match only valid dates? Ok, checking for 'Feb the 30' would
|
|
40 " be impossible, but at least check for valid months and times.
|
|
41 syn match remindDates "'[0-9]\{4}[/-][0-9]\{1,2}[/-][0-9]\{1,2}\(@[0-9]\{1,2}[:\.][0-9]\{1,2}\)\?'" contains=remindDateSeparators
|
1121
|
42 " This will match trailing whitespaces that seem to break rem2ps.
|
|
43 " Courtesy of Michael Dunn.
|
|
44 syn match remindWarning display excludenl "\S\s\+$"ms=s+1
|
|
45
|
7
|
46
|
|
47 if version >= 508 || !exists("did_remind_syn_inits")
|
|
48 if version < 508
|
|
49 let did_remind_syn_inits = 1
|
|
50 command -nargs=+ HiLink hi link <args>
|
|
51 else
|
|
52 command -nargs=+ HiLink hi def link <args>
|
|
53 endif
|
|
54
|
|
55 HiLink remindCommands Function
|
|
56 HiLink remindExpiry Repeat
|
|
57 HiLink remindTag Label
|
|
58 HiLink remindTimed Statement
|
|
59 HiLink remindMove Statement
|
|
60 HiLink remindSpecial Include
|
|
61 HiLink remindRun Function
|
|
62 HiLink remindConditional Conditional
|
|
63 HiLink remindComment Comment
|
2034
|
64 HiLink remindTimes String
|
7
|
65 HiLink remindString String
|
|
66 HiLink remindDebug Debug
|
|
67 HiLink remindVar Identifier
|
|
68 HiLink remindSubst Constant
|
|
69 HiLink remindAdvanceNumber Number
|
2034
|
70 HiLink remindDateSeparators Comment
|
|
71 HiLink remindDates String
|
1121
|
72 HiLink remindWarning Error
|
7
|
73
|
|
74 delcommand HiLink
|
|
75 endif
|
|
76
|
|
77 let b:current_syntax = "remind"
|
|
78
|
|
79 " vim: ts=8 sw=2
|