39
|
1 " Vim syntax file
|
11062
|
2 " Language: netrc(5) configuration file
|
|
3 " Previous Maintainer: Nikolai Weibull <now@bitwi.se>
|
|
4 " Latest Revision: 2010-01-03
|
39
|
5
|
375
|
6 if exists("b:current_syntax")
|
39
|
7 finish
|
|
8 endif
|
|
9
|
375
|
10 let s:cpo_save = &cpo
|
|
11 set cpo&vim
|
|
12
|
|
13 syn keyword netrcKeyword machine nextgroup=netrcMachine skipwhite skipnl
|
2034
|
14 syn keyword netrcKeyword account
|
|
15 \ login
|
|
16 \ nextgroup=netrcLogin,netrcSpecial skipwhite skipnl
|
375
|
17 syn keyword netrcKeyword password nextgroup=netrcPassword skipwhite skipnl
|
|
18 syn keyword netrcKeyword default
|
2034
|
19 syn keyword netrcKeyword macdef
|
|
20 \ nextgroup=netrcInit,netrcMacroName skipwhite skipnl
|
375
|
21 syn region netrcMacro contained start='.' end='^$'
|
39
|
22
|
375
|
23 syn match netrcMachine contained display '\S\+'
|
|
24 syn match netrcMachine contained display '"[^\\"]*\(\\.[^\\"]*\)*"'
|
|
25 syn match netrcLogin contained display '\S\+'
|
|
26 syn match netrcLogin contained display '"[^\\"]*\(\\.[^\\"]*\)*"'
|
|
27 syn match netrcPassword contained display '\S\+'
|
|
28 syn match netrcPassword contained display '"[^\\"]*\(\\.[^\\"]*\)*"'
|
2034
|
29 syn match netrcMacroName contained display '\S\+'
|
|
30 \ nextgroup=netrcMacro skipwhite skipnl
|
375
|
31 syn match netrcMacroName contained display '"[^\\"]*\(\\.[^\\"]*\)*"'
|
2034
|
32 \ nextgroup=netrcMacro skipwhite skipnl
|
39
|
33
|
375
|
34 syn keyword netrcSpecial contained anonymous
|
2034
|
35 syn match netrcInit contained '\<init$'
|
|
36 \ nextgroup=netrcMacro skipwhite skipnl
|
39
|
37
|
|
38 syn sync fromstart
|
|
39
|
375
|
40 hi def link netrcKeyword Keyword
|
|
41 hi def link netrcMacro PreProc
|
|
42 hi def link netrcMachine Identifier
|
|
43 hi def link netrcLogin String
|
|
44 hi def link netrcPassword String
|
|
45 hi def link netrcMacroName String
|
|
46 hi def link netrcSpecial Special
|
|
47 hi def link netrcInit Special
|
39
|
48
|
|
49 let b:current_syntax = "netrc"
|
|
50
|
375
|
51 let &cpo = s:cpo_save
|
|
52 unlet s:cpo_save
|