diff runtime/syntax/sysctl.vim @ 0:76efa0be13f1

Initial revision
author atsuki
date Sat, 10 Nov 2007 15:07:22 +0900
parents
children 67300faee616
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/runtime/syntax/sysctl.vim	Sat Nov 10 15:07:22 2007 +0900
@@ -0,0 +1,39 @@
+" Vim syntax file
+" Language:         sysctl.conf(5) configuration file
+" Maintainer:       Nikolai Weibull <now@bitwi.se>
+" Latest Revision:  2006-04-19
+
+if exists("b:current_syntax")
+  finish
+endif
+
+let s:cpo_save = &cpo
+set cpo&vim
+
+syn match   sysctlBegin   display '^'
+                          \ nextgroup=sysctlToken,sysctlComment skipwhite
+
+syn match   sysctlToken   contained display '\S\+'
+                          \ nextgroup=sysctlTokenEq skipwhite
+
+syn match   sysctlTokenEq contained display '=' nextgroup=sysctlValue skipwhite
+
+syn region  sysctlValue   contained display oneline
+                          \ matchgroup=sysctlValue start='\S'
+                          \ matchgroup=Normal end='\s*$'
+
+syn keyword sysctlTodo    contained TODO FIXME XXX NOTE
+
+syn region  sysctlComment display oneline start='^\s*[#;]' end='$'
+                          \ contains=sysctlTodo,@Spell
+
+hi def link sysctlTodo    Todo
+hi def link sysctlComment Comment
+hi def link sysctlToken   Identifier
+hi def link sysctlTokenEq Operator
+hi def link sysctlValue   String
+
+let b:current_syntax = "sysctl"
+
+let &cpo = s:cpo_save
+unlet s:cpo_save