Bug#338256: Updated highlighthing file

Matthew A. Nicholson mnicholson at digium.com
Thu Dec 1 16:25:52 UTC 2005

Ok, found the correct file.  Here it is.
Matthew A. Nicholson
-------------- next part --------------
" Vim syntax file
" Language:	Asterisk config file
" Maintainer:	brc007
" Last Change:	2005 Dec 1
" version 0.3
" Additional changes made 2005 Mar 7 by Corydon76
" * CVS priority, including n and s, and new label definitions
" * ENV( and LEN( support
" * Class patterns in extensions now match only the class pattern (instead of to a following expression)
" * anthm's functions are matched
" * Variables now appear in their own colors inside expressions
" Additional changes made 2005 Dec 1 by Matthew A. Nicholson
" * Made highlighting less specific to extensions.conf
" * Made highlighting more robust and flexible

" For version 5.x: Clear all syntax items
" For version 6.x: Quit when a syntax file was already loaded
if version < 600
  syntax clear
elseif exists("b:current_syntax")

"testing only
syn sync clear
syn sync fromstart

syn keyword	asteriskTodo		TODO contained
syn match	asteriskComment		/;.*/ contains=asteriskTodo
syn match       asteriskContext         /\[.\{-}\]/
syn match	asteriskStatement	/^\s*\w\+\s*=>\?\s*.*/ contains=asteriskOperator,asteriskKeyword,asteriskData,asteriskComment,asteriskVar,asteriskVarLen,asteriskExp,asteriskFunc
syn match	asteriskKeyword		/\w\+\s*=>\?/ contained contains=asteriskOperator
syn match	asteriskData		/=>\?.*/ contained contains=asteriskOperator
syn match	asteriskOperator	/=>\?\|,\||\|(\|)/ contained
syn match       asteriskIncludeBad	/^\s*#\s*[[:alnum:]]*/
syn match       asteriskInclude		/^\s#\sinclude\s.*/
syn match       asteriskVar             /\${_\{0,2}[[:alnum:]_-]\+\(:[[:digit:]]*\)\{0,2}}/ contains=asteriskVar
syn match       asteriskVarLen          /\${_\{0,2}[[:alnum:]_-]*(.\{-})}/
syn match       asteriskExp             /\$\[.\{-}\]/ contains=asteriskVar,asteriskExp,asteriskFunc,asteriskVarLen
syn match       asteriskFunc            /\$([[:alnum:]_]*.*)/

" Define the default highlighting.
" For version 5.7 and earlier: only when not done already
" For version 5.8 and later: only when an item doesn't have highlighting yet
:if version >= 508 || !exists("did_conf_syntax_inits")
  if version < 508
    let did_conf_syntax_inits = 1
    command -nargs=+ HiLink hi link <args>
    command -nargs=+ HiLink hi def link <args>

  HiLink	asteriskComment		Comment
  HiLink	asteriskKeyword		Type
  HiLink	asteriskOperator	Operator 
  HiLink	asteriskContext		Identifier 
  HiLink        asteriskInclude		Preproc 
  HiLink        asteriskIncludeBad	Error
  HiLink	asteriskPriority	Preproc	
  HiLink        asteriskVar             String
  HiLink        asteriskVarLen          Function
  HiLink        asteriskExp             Type
 delcommand HiLink

let b:current_syntax = "asterisk" 

" vim: ts=8 sw=2

More information about the pkg-vim-maintainers mailing list