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