blob: 4bc887477236989c3d17850e112bf9e72919f8cd [file] [log] [blame]
Bram Moolenaar61036992005-10-12 20:54:52 +00001" Vim syntax file
2" Language: trustees
3" Maintainer: Nima Talebi <nima@it.net.au>
4" Last Change: 2005-10-12
5
6if version < 600
7 syntax clear
8elseif exists("b:current_syntax")
9 finish
10endif
11
12syntax case match
13syntax sync minlines=0 maxlines=0
14
15" Errors & Comments
16syntax match tfsError /.*/
17highlight link tfsError Error
18syntax keyword tfsSpecialComment TODO XXX FIXME contained
19highlight link tfsSpecialComment Todo
20syntax match tfsComment ~\s*#.*~ contains=tfsSpecialComment
21highlight link tfsComment Comment
22
23" Operators & Delimiters
24highlight link tfsSpecialChar Operator
25syntax match tfsSpecialChar ~[*!+]~ contained
26highlight link tfsDelimiter Delimiter
27syntax match tfsDelimiter ~:~ contained
28
29" Trustees Rules - Part 1 of 3 - The Device
30syntax region tfsRuleDevice matchgroup=tfsDeviceContainer start=~\[/~ end=~\]~ nextgroup=tfsRulePath oneline
31highlight link tfsRuleDevice Label
32highlight link tfsDeviceContainer PreProc
33
34" Trustees Rules - Part 2 of 3 - The Path
35syntax match tfsRulePath ~/[-_a-zA-Z0-9/]*~ nextgroup=tfsRuleACL contained contains=tfsDelimiter
36highlight link tfsRulePath String
37
38" Trustees Rules - Part 3 of 3 - The ACLs
39syntax match tfsRuleACL ~\(:\(\*\|[+]\{0,1\}[a-zA-Z0-9/]\+\):[RWEBXODCU!]\+\)\+$~ contained contains=tfsDelimiter,tfsRuleWho,tfsRuleWhat
40syntax match tfsRuleWho ~\(\*\|[+]\{0,1\}[a-zA-Z0-9/]\+\)~ contained contains=tfsSpecialChar
41highlight link tfsRuleWho Identifier
42syntax match tfsRuleWhat ~[RWEBXODCU!]\+~ contained contains=tfsSpecialChar
43highlight link tfsRuleWhat Structure