389
|
1 " Vim syntax file
|
|
2 " Language: services(5) - Internet network services list
|
839
|
3 " Maintainer: Nikolai Weibull <now@bitwi.se>
|
|
4 " Latest Revision: 2006-04-19
|
389
|
5
|
|
6 if exists("b:current_syntax")
|
|
7 finish
|
|
8 endif
|
|
9
|
|
10 let s:cpo_save = &cpo
|
|
11 set cpo&vim
|
|
12
|
|
13 syn match servicesBegin display '^'
|
|
14 \ nextgroup=servicesName,servicesComment
|
|
15
|
|
16 syn match servicesName contained display '[[:graph:]]\+'
|
|
17 \ nextgroup=servicesPort skipwhite
|
|
18
|
|
19 syn match servicesPort contained display '\d\+'
|
|
20 \ nextgroup=servicesPPDiv,servicesPPDivDepr
|
|
21 \ skipwhite
|
|
22
|
|
23 syn match servicesPPDiv contained display '/'
|
|
24 \ nextgroup=servicesProtocol skipwhite
|
|
25
|
|
26 syn match servicesPPDivDepr contained display ','
|
|
27 \ nextgroup=servicesProtocol skipwhite
|
|
28
|
|
29 syn match servicesProtocol contained display '\S\+'
|
|
30 \ nextgroup=servicesAliases,servicesComment
|
|
31 \ skipwhite
|
|
32
|
|
33 syn match servicesAliases contained display '\S\+'
|
|
34 \ nextgroup=servicesAliases,servicesComment
|
|
35 \ skipwhite
|
|
36
|
|
37 syn keyword servicesTodo contained TODO FIXME XXX NOTE
|
|
38
|
|
39 syn region servicesComment display oneline start='#' end='$'
|
|
40 \ contains=servicesTodo,@Spell
|
|
41
|
|
42 hi def link servicesTodo Todo
|
|
43 hi def link servicesComment Comment
|
|
44 hi def link servicesName Identifier
|
|
45 hi def link servicesPort Number
|
|
46 hi def link servicesPPDiv Delimiter
|
|
47 hi def link servicesPPDivDepr Error
|
|
48 hi def link servicesProtocol Type
|
|
49 hi def link servicesAliases Macro
|
|
50
|
|
51 let b:current_syntax = "services"
|
|
52
|
|
53 let &cpo = s:cpo_save
|
|
54 unlet s:cpo_save
|