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