summaryrefslogtreecommitdiffstats
path: root/runtime/syntax
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2008-06-24 20:19:36 +0000
committerBram Moolenaar <Bram@vim.org>2008-06-24 20:19:36 +0000
commitf233048a129fa7a3b89e064078435181d6421da5 (patch)
tree750527cb322fe9ba1559b81da60f2bee923c83cd /runtime/syntax
parent176dd1e03c7e5f23e633705da2c8718d3cd320e1 (diff)
updated for version 7.2a
Diffstat (limited to 'runtime/syntax')
-rw-r--r--runtime/syntax/autohotkey.vim7
-rw-r--r--runtime/syntax/fstab.vim22
-rw-r--r--runtime/syntax/sisu.vim219
-rw-r--r--runtime/syntax/yaml.vim176
4 files changed, 276 insertions, 148 deletions
diff --git a/runtime/syntax/autohotkey.vim b/runtime/syntax/autohotkey.vim
index 78cb9e79b1..bbefd6f7b0 100644
--- a/runtime/syntax/autohotkey.vim
+++ b/runtime/syntax/autohotkey.vim
@@ -1,7 +1,7 @@
" Vim syntax file
" Language: AutoHotkey script file
" Maintainer: Nikolai Weibull <now@bitwi.se>
-" Latest Revision: 2007-05-09
+" Latest Revision: 2007-06-01
if exists("b:current_syntax")
finish
@@ -242,6 +242,10 @@ syn keyword autohotkeyType
\ local
\ global
+syn keyword autohotkeyBoolean
+ \ true
+ \ false
+
hi def link autohotkeyTodo Todo
hi def link autohotkeyComment Comment
hi def link autohotkeyCommentStart autohotkeyComment
@@ -271,6 +275,7 @@ hi def link autohotkeyNumber Number
hi def link autohotkeyInteger autohotkeyNumber
hi def link autohotkeyFloat autohotkeyNumber
hi def link autohotkeyType Type
+hi def link autohotkeyBoolean Boolean
let b:current_syntax = "autohotkey"
diff --git a/runtime/syntax/fstab.vim b/runtime/syntax/fstab.vim
index 9cb76cb1fe..830b8d014d 100644
--- a/runtime/syntax/fstab.vim
+++ b/runtime/syntax/fstab.vim
@@ -2,13 +2,14 @@
" Language: fstab file
" Maintaner: Radu Dineiu <radu.dineiu@gmail.com>
" URL: http://ld.yi.org/vim/fstab.vim
-" Last Change: 2007 Apr 24
-" Version: 0.91
+" Last Change: 2008 Jan 16
+" Version: 0.92
"
" Credits:
" David Necas (Yeti) <yeti@physics.muni.cz>
" Stefano Zacchiroli <zack@debian.org>
" Georgi Georgiev <chutz@gg3.net>
+" James Vega <jamessan@debian.org>
"
" Options:
" let fstab_unknown_fs_errors = 1
@@ -23,7 +24,7 @@ endif
" General
syn cluster fsGeneralCluster contains=fsComment
syn match fsComment /\s*#.*/
-syn match fsOperator /[,=:]/
+syn match fsOperator /[,=:#]/
" Device
syn cluster fsDeviceCluster contains=fsOperator,fsDeviceKeyword,fsDeviceError
@@ -31,9 +32,11 @@ syn match fsDeviceError /\%([^a-zA-Z0-9_\/#@:\.-]\|^\w\{-}\ze\W\)/ contained
syn keyword fsDeviceKeyword contained none proc linproc tmpfs devpts sysfs usbfs
syn keyword fsDeviceKeyword contained LABEL nextgroup=fsDeviceLabel
syn keyword fsDeviceKeyword contained UUID nextgroup=fsDeviceUUID
+syn keyword fsDeviceKeyword contained sshfs nextgroup=fsDeviceSshfs
syn match fsDeviceKeyword contained /^[a-zA-Z0-9.\-]\+\ze:/
syn match fsDeviceLabel contained /=[^ \t]\+/hs=s+1 contains=fsOperator
syn match fsDeviceUUID contained /=[^ \t]\+/hs=s+1 contains=fsOperator
+syn match fsDeviceSshfs contained /#[_=[:alnum:]\.\/+-]\+@[a-z0-9._-]\+\a\{2}:[^ \t]\+/hs=s+1 contains=fsOperator
" Mount Point
syn cluster fsMountPointCluster contains=fsMountPointKeyword,fsMountPointError
@@ -43,7 +46,7 @@ syn keyword fsMountPointKeyword contained none swap
" Type
syn cluster fsTypeCluster contains=fsTypeKeyword,fsTypeUnknown
syn match fsTypeUnknown /\s\+\zs\w\+/ contained
-syn keyword fsTypeKeyword contained adfs ados affs atfs audiofs auto autofs befs bfs cd9660 cfs cifs coda cramfs devfs devpts e2compr efs ext2 ext2fs ext3 fdesc ffs filecore hfs hpfs iso9660 jffs jffs2 jfs kernfs lfs linprocfs mfs minix msdos ncpfs nfs none ntfs null nwfs overlay ovlfs portal proc procfs ptyfs qnx4 reiserfs romfs shm smbfs std subfs swap sysfs sysv tcfs tmpfs udf ufs umap umsdos union usbfs userfs vfat vs3fs vxfs wrapfs wvfs xfs zisofs
+syn keyword fsTypeKeyword contained adfs ados affs atfs audiofs auto autofs befs bfs cd9660 cfs cifs coda cramfs devfs devpts e2compr efs ext2 ext2fs ext3 fdesc ffs filecore fuse hfs hpfs iso9660 jffs jffs2 jfs kernfs lfs linprocfs mfs minix msdos ncpfs nfs none ntfs null nwfs overlay ovlfs portal proc procfs ptyfs qnx4 reiserfs romfs shm smbfs sshfs std subfs swap sysfs sysv tcfs tmpfs udf ufs umap umsdos union usbfs userfs vfat vs3fs vxfs wrapfs wvfs xfs zisofs
" Options
" -------
@@ -143,6 +146,14 @@ syn match fsOptionsKeywords contained /\<resize=/ nextgroup=fsOptionsNumber
syn keyword fsOptionsReiserHash contained rupasov tea r5 detect
syn keyword fsOptionsKeywords contained hashed_relocation noborder nolog notail no_unhashed_relocation replayonly
+" Options: sshfs
+syn match fsOptionsKeywords contained /\<\%(BatchMode\|ChallengeResponseAuthentication\|CheckHostIP\|ClearAllForwardings\|Compression\|EnableSSHKeysign\|ForwardAgent\|ForwardX11\|ForwardX11Trusted\|GatewayPorts\|GSSAPIAuthentication\|GSSAPIDelegateCredentials\|HashKnownHosts\|HostbasedAuthentication\|IdentitiesOnly\|NoHostAuthenticationForLocalhost\|PasswordAuthentication\|PubkeyAuthentication\|RhostsRSAAuthentication\|RSAAuthentication\|TCPKeepAlive\|UsePrivilegedPort\|cache\)=/ nextgroup=fsOptionsYesNo
+syn match fsOptionsKeywords contained /\<\%(ControlMaster\|StrictHostKeyChecking\|VerifyHostKeyDNS\)=/ nextgroup=fsOptionsSshYesNoAsk
+syn match fsOptionsKeywords contained /\<\%(AddressFamily\|BindAddress\|Cipher\|Ciphers\|ControlPath\|DynamicForward\|EscapeChar\|GlobalKnownHostsFile\|HostKeyAlgorithms\|HostKeyAlias\|HostName\|IdentityFile\|KbdInteractiveDevices\|LocalForward\|LogLevel\|MACs\|PreferredAuthentications\|Protocol\|ProxyCommand\|RemoteForward\|RhostsAuthentication\|SendEnv\|SmartcardDevice\|User\|UserKnownHostsFile\|XAuthLocation\|comment\|workaround\|idmap\|ssh_command\|sftp_server\|fsname\)=/ nextgroup=fsOptionsString
+syn match fsOptionsKeywords contained /\<\%(CompressionLevel\|ConnectionAttempts\|ConnectTimeout\|NumberOfPasswordPrompts\|Port\|ServerAliveCountMax\|ServerAliveInterval\|cache_timeout\|cache_X_timeout\|ssh_protocol\|directport\|max_read\|umask\|uid\|gid\|entry_timeout\|negative_timeout\|attr_timeout\)=/ nextgroup=fsOptionsNumber
+syn keyword fsOptionsKeywords contained reconnect sshfs_sync no_readahead sshfs_debug transform_symlinks allow_other allow_root nonempty default_permissions large_read hard_remove use_ino readdir_ino direct_io kernel_cache
+syn keyword fsOptionsSshYesNoAsk contained yes no ask
+
" Options: subfs
syn match fsOptionsKeywords contained /\<fs=/ nextgroup=fsOptionsString
syn keyword fsOptionsKeywords contained procuid
@@ -208,11 +219,13 @@ if version >= 508 || !exists("did_config_syntax_inits")
HiLink fsDeviceKeyword Identifier
HiLink fsDeviceLabel String
HiLink fsDeviceUUID String
+ HiLink fsDeviceSshfs String
HiLink fsFreqPassNumber Number
if exists('fstab_unknown_fs_errors') && fstab_unknown_fs_errors == 1
HiLink fsTypeUnknown Error
endif
+
HiLink fsDeviceError Error
HiLink fsMountPointError Error
HiLink fsMountPointKeyword Keyword
@@ -235,6 +248,7 @@ if version >= 508 || !exists("did_config_syntax_inits")
HiLink fsOptionsHpfsCase String
HiLink fsOptionsIsoMap String
HiLink fsOptionsReiserHash String
+ HiLink fsOptionsSshYesNoAsk String
HiLink fsOptionsUfsType String
HiLink fsOptionsUfsError String
diff --git a/runtime/syntax/sisu.vim b/runtime/syntax/sisu.vim
index fe472c9fef..f29bc2680f 100644
--- a/runtime/syntax/sisu.vim
+++ b/runtime/syntax/sisu.vim
@@ -1,8 +1,7 @@
-"%% SiSU Vim syntax file
-" SiSU Maintainer: Ralph Amissah <ralph@amissah.com>
-" SiSU Markup: SiSU (sisu-0.38)
-" (originally looked at Ruby Vim by Mirko Nasato)
-" Last Update: 2006 Jul 22
+"SiSU Vim syntax file
+"SiSU Maintainer: Ralph Amissah <ralph@amissah.com>
+"SiSU Markup: SiSU (sisu-0.66.0, 2008-02-24)
+"(originally looked at Ruby Vim by Mirko Nasato)
if version < 600
syntax clear
@@ -10,63 +9,78 @@ elseif exists("b:current_syntax")
finish
else
endif
-"% 11 Errors?
+
+" Errors:
syn match sisu_error contains=sisu_link,sisu_error_wspace "<![^ei]\S\+!>"
-"% 10 Markers: Endnote Identifiers, Pagebreaks etc.:
+
+" Markers Identifiers:
if !exists("sisu_no_identifiers")
- syn match sisu_mark_endnote "\~^"
- syn match sisu_contain contains=@NoSpell "</\?sub>"
- syn match sisu_break contains=@NoSpell "<br>\|<br />"
- syn match sisu_control contains=@NoSpell "<p>\|</p>\|<p />\|<:p[bn]>"
- syn match sisu_html "<center>\|</center>"
- syn match sisu_marktail "[~-]#"
- syn match sisu_html contains=@NoSpell "<td>\|<td \|<tr>\|</td>\|</tr>\|<table>\|<table \|</table>"
- syn match sisu_control "\""
- syn match sisu_underline "\(^\| \)_[a-zA-Z0-9]\+_\([ .,]\|$\)"
- syn match sisu_number contains=@NoSpell "[0-9a-f]\{32\}\|[0-9a-f]\{64\}"
- syn match sisu_link contains=@NoSpell "\(https\?://\|\.\.\/\)\S\+"
+ syn match sisu_mark_endnote "\~^"
+ syn match sisu_contain contains=@NoSpell "</\?sub>"
+ syn match sisu_break contains=@NoSpell "<br>\|<br />"
+ syn match sisu_control contains=@NoSpell "<p>\|</p>\|<p />\|<:p[bn]>"
+ syn match sisu_html "<center>\|</center>"
+ syn match sisu_marktail "[~-]#"
+ syn match sisu_html contains=@NoSpell "<td>\|<td \|<tr>\|</td>\|</tr>\|<table>\|<table \|</table>"
+ syn match sisu_control "\""
+ syn match sisu_underline "\(^\| \)_[a-zA-Z0-9]\+_\([ .,]\|$\)"
+ syn match sisu_number contains=@NoSpell "[0-9a-f]\{32\}\|[0-9a-f]\{64\}"
+ syn match sisu_link contains=@NoSpell "\(_\?https\?://\|\.\.\/\)\S\+"
"metaverse specific
- syn match sisu_ocn contains=@NoSpell "<\~\d\+;\w\d\+;\w\d\+>"
- syn match sisu_marktail "<\~#>"
- syn match sisu_markpara contains=@NoSpell "<:i[12]>"
- syn match sisu_link " \*\~\S\+"
- syn match sisu_action "^<:insert\d\+>"
- syn match sisu_contain "<:e>"
+ syn match sisu_ocn contains=@NoSpell "<\~\d\+;\w\d\+;\w\d\+>"
+ syn match sisu_marktail "<\~#>"
+ syn match sisu_markpara contains=@NoSpell "<:i[1-9]>"
+ syn match sisu_link " \*\~\S\+"
+ syn match sisu_action "^<:insert\d\+>"
+ syn match sisu_require contains=@NoSpell "^<<\s*[a-zA-Z0-9^._-]\+\.ss[it]$"
+ syn match sisu_require contains=@NoSpell "^<<{[a-zA-Z0-9^._-]\+\.ss[it]}$"
+ syn match sisu_contain "<:e>"
+ syn match sisu_sem_marker ";{\|};[a-z._]*[a-z]"
+ syn match sisu_sem_marker_block "\([a-z][a-z._]*\|\):{\|}:[a-z._]*[a-z]"
+ syn match sisu_sem_ex_marker ";\[\|\];[a-z._]*[a-z]"
+ syn match sisu_sem_ex_marker_block "\([a-z][a-z._]*\|\):\[\|\]:[a-z._]*[a-z]"
+ syn match sisu_sem_block contains=sisu_error,sisu_error_wspace,sisu_content_alt,sisu_link,sisu_linked,sisu_break,sisu_sem_block,sisu_sem_content,sisu_sem_marker_block,sisu_sem_marker,sisu_sem_ex_marker_block,sisu_sem_ex_marker,sisu_mark_endnote,sisu_content_endnote "\([a-z]*\):{[^}].\{-}}:\1"
+ syn match sisu_sem_content contains=sisu_error,sisu_error_wspace,sisu_content_alt,sisu_link,sisu_linked,sisu_break,sisu_sem_marker_block,sisu_sem_marker,sisu_sem_ex_marker_block,sisu_sem_ex_marker ";{[^}].\{-}};[a-z]\+"
+ syn match sisu_sem_ex_block contains=sisu_error,sisu_error_wspace,sisu_content_alt,sisu_link,sisu_linked,sisu_break,sisu_sem_block,sisu_sem_content,sisu_sem_marker_block,sisu_sem_marker,sisu_sem_ex_marker_block,sisu_sem_ex_marker,sisu_mark_endnote,sisu_content_endnote "\([a-z]*\):\[[^}].\{-}\]:\1"
+ syn match sisu_sem_ex_content contains=sisu_error,sisu_error_wspace,sisu_content_alt,sisu_link,sisu_linked,sisu_break,sisu_sem_marker_block,sisu_sem_marker,sisu_sem_ex_marker_block,sisu_sem_ex_marker ";\[[^}].\{-}\];[a-z]\+"
endif
-"% 9 URLs Numbers: and ASCII Codes
+
+"URLs Numbers And ASCII Codes:
syn match sisu_number "\<\(0x\x\+\|0b[01]\+\|0\o\+\|0\.\d\+\|0\|[1-9][\.0-9_]*\)\>"
syn match sisu_number "?\(\\M-\\C-\|\\c\|\\C-\|\\M-\)\=\(\\\o\{3}\|\\x\x\{2}\|\\\=\w\)"
-"% 8 Tuned Error - is error if not already matched
+
+"Tuned Error: (is error if not already matched)
syn match sisu_error contains=sisu_error "[\~/\*!_]{\|}[\~/\*!_]"
syn match sisu_error contains=sisu_error "<a href\|</a>]"
-"% 7 Simple Enclosed Markup:
-" Simple Markup:
-"% url/link
+
+"Simple Paired Enclosed Markup:
+"url/link
syn region sisu_link contains=sisu_error,sisu_error_wspace matchgroup=sisu_action start="^<<\s*|[a-zA-Z0-9^._-]\+|@|[a-zA-Z0-9^._-]\+|"rs=s+2 end="$"
-"% header
-syn region sisu_header_content contains=sisu_error,sisu_error_wspace,sisu_content_alt,sisu_link,sisu_linked,sisu_break matchgroup=sisu_header start="^0\~\(\S\+\|[^-]\)" end="$"
-syn region sisu_header_content contains=sisu_error,sisu_error_wspace,sisu_content_alt,sisu_link,sisu_linked,sisu_break matchgroup=sisu_header start="^0\~\(tags\?\|date\)\s\+"rs=e-1 end="\n$"
-syn region sisu_header_content contains=sisu_error,sisu_error_wspace,sisu_content_alt,sisu_link,sisu_linked,sisu_break matchgroup=sisu_header start="^@\S\+:[+-]\?\s"rs=e-1 end="$"
-syn region sisu_header_content contains=sisu_error,sisu_error_wspace,sisu_content_alt,sisu_link,sisu_linked,sisu_break matchgroup=sisu_header start="^@\(tags\?\|date\):\s\+"rs=e-1 end="\n$"
-"% headings
+"header
+syn region sisu_header_content contains=sisu_error,sisu_error_wspace,sisu_content_alt,sisu_link,sisu_linked,sisu_break matchgroup=sisu_header start="^0\~\(\S\+\|[^-]\)" end="\n$"
+syn region sisu_header_content contains=sisu_error,sisu_error_wspace,sisu_content_alt,sisu_link,sisu_linked,sisu_break matchgroup=sisu_header start="^[@%]\S\+:[+-]\?\s"rs=e-1 end="\n$"
+"headings
syn region sisu_heading contains=sisu_mark_endnote,sisu_content_endnote,sisu_marktail,sisu_strikeout,sisu_number,sisu_control,sisu_identifier,sisu_ocn,sisu_error,sisu_error_wspace matchgroup=sisu_structure start="^\([1-8]\|:\?[A-C]\)\~\(\S\+\|[^-]\)" end="$"
-"% grouped text
-syn region sisu_content_alt contains=sisu_strikeout,sisu_number,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_contain start="table{.\+" end="}table"
-syn region sisu_content_alt contains=sisu_strikeout,sisu_number,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_contain start="{t\~h}" end="$$"
+"grouped text
+syn region sisu_content_alt contains=sisu_strikeout,sisu_number,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_contain start="^table{.\+" end="}table"
+syn region sisu_content_alt contains=sisu_strikeout,sisu_number,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_contain start="^{\(t\|table\)\(\~h\)\?\(\sc[0-9]\+;\)\?[0-9; ]*}" end="\n\n"
syn region sisu_content_alt contains=sisu_mark_endnote,sisu_content_endnote,sisu_link,sisu_mark,sisu_strikeout,sisu_number,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_contain start="^\(alt\|group\|poem\){" end="^}\(alt\|group\|poem\)"
syn region sisu_content_alt contains=sisu_error matchgroup=sisu_contain start="^code{" end="^}code"
-"% endnotes
-syn region sisu_content_endnote contains=sisu_link,sisu_strikeout,sisu_underline,sisu_number,sisu_control,sisu_identifier,sisu_error,sisu_error_wspace,sisu_mark,sisu_break matchgroup=sisu_mark_endnote start="\~{[*+]*" end="}\~" skip="\n"
-syn region sisu_content_endnote contains=sisu_link,sisu_strikeout,sisu_underline,sisu_number,sisu_control,sisu_identifier,sisu_error,sisu_error_wspace,sisu_mark,sisu_break matchgroup=sisu_mark_endnote start="\~\[[*+]*" end="\]\~" skip="\n"
+"endnotes
+syn region sisu_content_endnote contains=sisu_link,sisu_strikeout,sisu_underline,sisu_number,sisu_control,sisu_identifier,sisu_error,sisu_error_wspace,sisu_mark,sisu_break,sisu_sem_block,sisu_sem_content,sisu_sem_marker_block,sisu_sem_marker,sisu_sem_ex_marker_block,sisu_sem_ex_marker matchgroup=sisu_mark_endnote start="\~{[*+]*" end="}\~" skip="\n"
+syn region sisu_content_endnote contains=sisu_link,sisu_strikeout,sisu_underline,sisu_number,sisu_control,sisu_identifier,sisu_error,sisu_error_wspace,sisu_mark,sisu_break,sisu_sem_block,sisu_sem_content,sisu_sem_marker matchgroup=sisu_mark_endnote start="\~\[[*+]*" end="\]\~" skip="\n"
syn region sisu_content_endnote contains=sisu_strikeout,sisu_number,sisu_control,sisu_link,sisu_identifier,sisu_error,sisu_error_wspace,sisu_mark,sisu_break matchgroup=sisu_mark_endnote start="\^\~" end="\n\n"
-"% images
-syn region sisu_linked contains=sisu_fontface,sisu_strikeout,sisu_number,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_link start="{" end="}\(\(https\?://\|\.\./\)\S\+\|image\)" oneline
-"% some line operations
+"links and images
+syn region sisu_linked contains=sisu_fontface,sisu_strikeout,sisu_number,sisu_control,sisu_identifier,sisu_sem_block,sisu_sem_content,sisu_sem_marker_block,sisu_sem_marker,sisu_sem_ex_marker_block,sisu_sem_ex_marker,sisu_sem_block,sisu_error matchgroup=sisu_link start="{\(\~^\s\)\?" end="}\(https\?:/\/\|\.\./\)\S\+" oneline
+syn region sisu_linked contains=sisu_fontface,sisu_strikeout,sisu_number,sisu_control,sisu_identifier,sisu_sem_block,sisu_sem_content,sisu_sem_marker_block,sisu_sem_marker,sisu_sem_ex_marker_block,sisu_sem_ex_marker,sisu_sem_block,sisu_error matchgroup=sisu_link start="{\(\~^\s\)\?" end="\[[1-5][sS]*\]}\S\+\.ss[tm]" oneline
+syn region sisu_linked contains=sisu_fontface,sisu_strikeout,sisu_number,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_link start="{" end="}image" oneline
+"some line operations
syn region sisu_control contains=sisu_strikeout,sisu_identifier,sisu_content_endnote,sisu_mark_endnote,sisu_error,sisu_error_wspace matchgroup=sisu_control start="\(\(^\| \)!_ \|<:b>\)" end="$"
-syn region sisu_normal contains=sisu_strikeout,sisu_identifier,sisu_content_endnote,sisu_mark_endnote,sisu_link,sisu_linked,sisu_error,sisu_error_wspace matchgroup=sisu_markpara start="^_\([12*]\|[12]\*\) " end="$"
+syn region sisu_normal contains=sisu_strikeout,sisu_identifier,sisu_content_endnote,sisu_mark_endnote,sisu_link,sisu_sem_block,sisu_sem_content,sisu_sem_marker_block,sisu_sem_marker,sisu_sem_ex_marker_block,sisu_sem_ex_marker,sisu_linked,sisu_error,sisu_error_wspace matchgroup=sisu_markpara start="^_\([1-9*]\|[1-9]\*\) " end="$"
syn region sisu_normal contains=sisu_strikeout,sisu_identifier,sisu_content_endnote,sisu_mark_endnote,sisu_link,sisu_linked,sisu_error,sisu_error_wspace matchgroup=sisu_markpara start="^\(#[ 1]\|_# \)" end="$"
syn region sisu_comment matchgroup=sisu_comment start="^%\{1,2\} " end="$"
-"% font face curly brackets
+"font face curly brackets
+"syn region sisu_identifier contains=sisu_strikeout,sisu_number,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_sem start="\S\+:{" end="}:[^<>,.!?:; ]\+" oneline
syn region sisu_control contains=sisu_strikeout,sisu_number,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_fontface start="\*{" end="}\*"
syn region sisu_control contains=sisu_strikeout,sisu_number,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_fontface start="!{" end="}!"
syn region sisu_underline contains=sisu_strikeout,sisu_number,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_fontface start="_{" end="}_"
@@ -74,43 +88,45 @@ syn region sisu_identifier contains=sisu_strikeout,sisu_number,sisu_control,sisu
syn region sisu_underline contains=sisu_strikeout,sisu_number,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_fontface start="+{" end="}+"
syn region sisu_identifier contains=sisu_strikeout,sisu_number,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_fontface start="\^{" end="}\^"
syn region sisu_identifier contains=sisu_strikeout,sisu_number,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_fontface start=",{" end="},"
-syn region sisu_strikeout contains=sisu_error matchgroup=sisu_fontface start="-{" end="}-"
+syn region sisu_strikeout contains=sisu_error matchgroup=sisu_fontface start="-{" end="}-"
syn region sisu_html contains=sisu_error contains=sisu_strikeout matchgroup=sisu_contain start="<a href=\".\{-}\">" end="</a>" oneline
-"% single words bold italicise etc. "workon
+"single words bold italicise etc. "workon
syn region sisu_control contains=sisu_error matchgroup=sisu_control start="\([ (]\|^\)\*[^\|{\n\~\\]"hs=e-1 end="\*"he=e-0 skip="[a-zA-Z0-9']" oneline
syn region sisu_identifier contains=sisu_error matchgroup=sisu_content_alt start="\([ ]\|^\)/[^{ \|\n\\]"hs=e-1 end="/\[ \.\]" skip="[a-zA-Z0-9']" oneline
-"% misc
+"misc
syn region sisu_identifier contains=sisu_error matchgroup=sisu_fontface start="\^[^ {\|\n\\]"rs=s+1 end="\^[ ,.;:'})\\\n]" skip="[a-zA-Z0-9']" oneline
-"% metaverse html (flagged as errors for filetype sisu)
+"metaverse html (flagged as errors for filetype sisu)
syn region sisu_control contains=sisu_strikeout,sisu_number,sisu_control,sisu_identifier,sisu_error,sisu_mark matchgroup=sisu_html start="<b>" end="</b>" skip="\n" oneline
syn region sisu_control contains=sisu_strikeout,sisu_number,sisu_control,sisu_identifier,sisu_error,sisu_mark matchgroup=sisu_html start="<em>" end="</em>" skip="\n" oneline
syn region sisu_content_alt contains=sisu_strikeout,sisu_number,sisu_control,sisu_identifier,sisu_error,sisu_mark matchgroup=sisu_html start="<i>" end="</i>" skip="\n" oneline
syn region sisu_content_alt contains=sisu_strikeout,sisu_number,sisu_control,sisu_identifier,sisu_error,sisu_mark matchgroup=sisu_html start="<u>" end="</u>" skip="\n" oneline
syn region sisu_identifier contains=sisu_strikeout,sisu_number,sisu_control,sisu_identifier,sisu_error,sisu_mark matchgroup=sisu_html start="<ins>" end="</ins>" skip="\\\\\|\\'" oneline
syn region sisu_identifier contains=sisu_error matchgroup=sisu_html start="<del>" end="</del>" oneline
-"% metaverse <:>
+"metaverse
syn region sisu_content_alt contains=sisu_strikeout,sisu_number,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_contain start="<:Table.\{-}>" end="<:Table[-_]end>"
syn region sisu_content_alt contains=sisu_error matchgroup=sisu_contain start="<:code>" end="<:code[-_]end>"
syn region sisu_content_alt contains=sisu_mark_endnote,sisu_content_endnote,sisu_link,sisu_mark,sisu_strikeout,sisu_number,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_contain start="<:alt>" end="<:alt[-_]end>"
syn region sisu_content_alt contains=sisu_mark_endnote,sisu_content_endnote,sisu_link,sisu_mark,sisu_strikeout,sisu_number,sisu_control,sisu_identifier,sisu_error matchgroup=sisu_contain start="<:poem>" end="<:poem[-_]end>"
-"% 6 Expensive Mode
-" Expensive Mode:
+
+"Expensive Mode:
if !exists("sisu_no_expensive")
else " not Expensive
syn region sisu_content_alt matchgroup=sisu_control start="^\s*def\s" matchgroup=NONE end="[?!]\|\>" skip="\.\|\(::\)" oneline
endif " Expensive?
-"% 5 Headers: and Headings (Document Instructions)
+
+"Headers And Headings: (Document Instructions)
syn match sisu_control contains=sisu_error,sisu_error_wspace "4\~! \S\+"
syn region sisu_markpara contains=sisu_error,sisu_error_wspace start="^=begin" end="^=end.*$"
-"% 4 Errors?
+
+"Errors:
syn match sisu_error_wspace contains=sisu_error_wspace "^\s\+"
syn match sisu_error_wspace contains=sisu_error_wspace "\s\s\+"
syn match sisu_error_wspace contains=sisu_error_wspace " \s*$"
-syn match sisu_error contains=sisu_error,sisu_error_wspace "[^ (}]https\?:\S\+"
syn match sisu_error contains=sisu_error_wspace "\t\+"
-syn match sisu_error contains=sisu_error "https\?:\S\+[}><]"
+syn match sisu_error contains=sisu_error,sisu_error_wspace "\([^ (][_\\]\||[^ (}]\)https\?:\S\+"
+syn match sisu_error contains=sisu_error "_\?https\?:\S\+[}><]"
syn match sisu_error contains=sisu_error "\([!*/_\+,^]\){\([^(\}\1)]\)\{-}\n\n"
-syn match sisu_error contains=sisu_error "^[\-\~]{[^{]\{-}\n\n"
+syn match sisu_error contains=sisu_error "^[\~]{[^{]\{-}\n\n"
syn match sisu_error contains=sisu_error "\s\+.{{"
syn match sisu_error contains=sisu_error "^\~\s*$"
syn match sisu_error contains=sisu_error "^[0-9]\~\s*$"
@@ -124,48 +140,53 @@ syn match sisu_error contains=sisu_error "<dir>"
"errors for filetype sisu, though not error in 'metaverse':
syn match sisu_error contains=sisu_error,sisu_match,sisu_strikeout,sisu_contain,sisu_content_alt,sisu_mark,sisu_break,sisu_number "<[a-zA-Z\/]\+>"
syn match sisu_error "/\?<\([biu]\)>[^(</\1>)]\{-}\n\n"
-"% 3 Error Exceptions?
+
+"Error Exceptions:
syn match sisu_control "\n\n" "contains=ALL
syn match sisu_control " //"
syn match sisu_error "%{"
-syn match sisu_error "<br>https\?:\S\+\|https\?:\S\+<br>"
-syn match sisu_error "[><]https\?:\S\+\|https\?:\S\+[><]"
-"% 2 Definitions - Define the default highlighting.
-if version >= 508 || !exists("did_sisu_syntax_inits")
- if version < 508
- let did_sisu_syntax_inits = 1
- command -nargs=+ HiLink hi link <args>
- else
- command -nargs=+ HiLink hi def link <args>
- endif
-"% 1 Defined
- HiLink sisu_normal Normal
- HiLink sisu_header PreProc
- HiLink sisu_header_content Statement
- HiLink sisu_heading Title
- HiLink sisu_structure Operator
- HiLink sisu_contain Include
- HiLink sisu_mark_endnote Include
- HiLink sisu_link NonText
- HiLink sisu_linked String
- HiLink sisu_fontface Include
- HiLink sisu_strikeout DiffDelete
- HiLink sisu_content_alt Special
- HiLink sisu_content_endnote Special
- HiLink sisu_control Define
- HiLink sisu_ocn Include
- HiLink sisu_number Number
- HiLink sisu_identifier Function
- HiLink sisu_underline Underlined
- HiLink sisu_markpara Include
- HiLink sisu_marktail Include
- HiLink sisu_mark Identifier
- HiLink sisu_break Structure
- HiLink sisu_html Type
- HiLink sisu_action Identifier
- HiLink sisu_comment Comment
- HiLink sisu_error_wspace Error
- HiLink sisu_error Error
- delcommand HiLink
-endif
+syn match sisu_error "<br>_\?https\?:\S\+\|_\?https\?:\S\+<br>"
+syn match sisu_error "[><]_\?https\?:\S\+\|_\?https\?:\S\+[><]"
+
+"Definitions Default Highlighting:
+hi def link sisu_normal Normal
+hi def link sisu_header PreProc
+hi def link sisu_header_content Statement
+hi def link sisu_heading Title
+hi def link sisu_structure Operator
+hi def link sisu_contain Include
+hi def link sisu_mark_endnote Include
+hi def link sisu_require NonText
+hi def link sisu_link NonText
+hi def link sisu_linked String
+hi def link sisu_fontface Include
+hi def link sisu_strikeout DiffDelete
+hi def link sisu_content_alt Special
+hi def link sisu_sem_content String
+hi def link sisu_sem_content SpecialKey
+hi def link sisu_sem_block Special
+hi def link sisu_sem_marker Visual
+"hi def link sisu_sem_marker Structure
+hi def link sisu_sem_marker_block MatchParen
+hi def link sisu_sem_ex_marker FoldColumn
+hi def link sisu_sem_ex_marker_block Folded
+hi def link sisu_sem_ex_content Comment
+"hi def link sisu_sem_ex_content SpecialKey
+hi def link sisu_sem_ex_block Comment
+hi def link sisu_content_endnote Special
+hi def link sisu_control Define
+hi def link sisu_ocn Include
+hi def link sisu_number Number
+hi def link sisu_identifier Function
+hi def link sisu_underline Underlined
+hi def link sisu_markpara Include
+hi def link sisu_marktail Include
+hi def link sisu_mark Identifier
+hi def link sisu_break Structure
+hi def link sisu_html Type
+hi def link sisu_action Identifier
+hi def link sisu_comment Comment
+hi def link sisu_error_sem_marker Error
+hi def link sisu_error_wspace Error
+hi def link sisu_error Error
let b:current_syntax = "sisu"
diff --git a/runtime/syntax/yaml.vim b/runtime/syntax/yaml.vim
index 9ebab70689..abda3f8b49 100644
--- a/runtime/syntax/yaml.vim
+++ b/runtime/syntax/yaml.vim
@@ -1,7 +1,7 @@
" Vim syntax file
" Language: YAML (YAML Ain't Markup Language)
" Maintainer: Nikolai Weibull <now@bitwi.se>
-" Latest Revision: 2006-04-19
+" Latest Revision: 2007-06-27
if exists("b:current_syntax")
finish
@@ -10,53 +10,140 @@ endif
let s:cpo_save = &cpo
set cpo&vim
-syn keyword yamlTodo contained TODO FIXME XXX NOTE
+syn keyword yamlTodo
+ \ contained
+ \ TODO
+ \ FIXME
+ \ XXX
+ \ NOTE
+
+syn region yamlComment
+ \ display
+ \ oneline
+ \ start='%(^|s)#'
+ \ end='$'
+ \ contains=yamlTodo,@Spell
+
+syn match yamlNodeProperty
+ \ '!\%(![^\\^% \t]\+\|[^!][^:/ \t]*\)'
+
+syn match yamlAnchor
+ \ '&.+'
+
+syn match yamlAlias
+ \ '*.+'
+
+syn match yamlDelimiter
+ \ '[-,:]'
+syn match yamlBlock
+ \ '[[]{}>|]'
+syn match yamlOperator
+ \ '[?+-]'
+syn match yamlKey
+ \ 'w+(s+w+)*zes*:'
+
+syn region yamlString
+ \ start=+"+
+ \ skip=+\"+
+ \ end=+"+
+ \ contains=yamlEscape
+syn region yamlString
+ \ start=+'+
+ \ skip=+''+
+ \ end=+'+
+ \ contains=yamlSingleEscape
+syn match yamlEscape
+ \ contained
+ \ display
+ \ +\[\"abefnrtv^0_ NLP]+
+syn match yamlEscape
+ \ contained
+ \ display
+ \ '\xx{2}'
+syn match yamlEscape
+ \ contained
+ \ display
+ \ '\ux{4}'
+syn match yamlEscape
+ \ contained
+ \ display
+ \ '\Ux{8}'
-syn region yamlComment display oneline start='\%(^\|\s\)#' end='$'
- \ contains=yamlTodo,@Spell
-
-syn match yamlNodeProperty '!\%(![^\\^% ]\+\|[^!][^:/ ]*\)'
-
-syn match yamlAnchor '&.\+'
-
-syn match yamlAlias '\*.\+'
-
-syn match yamlDelimiter '[-,:]'
-syn match yamlBlock '[\[\]{}>|]'
-syn match yamlOperator '[?+-]'
-syn match yamlKey '\w\+\(\s\+\w\+\)*\ze\s*:'
-
-syn region yamlString start=+"+ skip=+\\"+ end=+"+
- \ contains=yamlEscape
-syn region yamlString start=+'+ skip=+''+ end=+'+
- \ contains=yamlSingleEscape
-syn match yamlEscape contained display +\\[\\"abefnrtv^0_ NLP]+
-syn match yamlEscape contained display '\\x\x\{2}'
-syn match yamlEscape contained display '\\u\x\{4}'
-syn match yamlEscape contained display '\\U\x\{8}'
" TODO: how do we get 0x85, 0x2028, and 0x2029 into this?
-syn match yamlEscape display '\\\%(\r\n\|[\r\n]\)'
-syn match yamlSingleEscape contained display +''+
+" XXX: Em, what is going on here? This can't be right. Leave out until we
+" figure out what this is meant to do.
+"syn match yamlEscape
+" \ contained
+" \ display
+" \ '\%(rn|[rn])'
+syn match yamlSingleEscape
+ \ contained
+ \ display
+ \ +''+
" TODO: sexagecimal and fixed (20:30.15 and 1,230.15)
-syn match yamlNumber display
- \ '\<[+-]\=\d\+\%(\.\d\+\%([eE][+-]\=\d\+\)\=\)\='
-syn match yamlNumber display '0\o\+'
-syn match yamlNumber display '0x\x\+'
-syn match yamlNumber display '([+-]\=[iI]nf)'
-syn match yamlNumber display '(NaN)'
-
-syn match yamlConstant '\<[~yn]\>'
-syn keyword yamlConstant true True TRUE false False FALSE
-syn keyword yamlConstant yes Yes on ON no No off OFF
-syn keyword yamlConstant null Null NULL nil Nil NIL
-
-syn match yamlTimestamp '\d\d\d\d-\%(1[0-2]\|\d\)-\%(3[0-2]\|2\d\|1\d\|\d\)\%( \%([01]\d\|2[0-3]\):[0-5]\d:[0-5]\d.\d\d [+-]\%([01]\d\|2[0-3]\):[0-5]\d\|t\%([01]\d\|2[0-3]\):[0-5]\d:[0-5]\d.\d\d[+-]\%([01]\d\|2[0-3]\):[0-5]\d\|T\%([01]\d\|2[0-3]\):[0-5]\d:[0-5]\d.\dZ\)\='
-
-syn region yamlDocumentHeader start='---' end='$' contains=yamlDirective
-syn match yamlDocumentEnd '\.\.\.'
-
-syn match yamlDirective contained '%[^:]\+:.\+'
+syn match yamlNumber
+ \ display
+ \ '\<[+-]\=\d\+\%(\.\d\+\%([eE][+-]\=\d\+\)\=\)\='
+syn match yamlNumber
+ \ display
+ \ '0o+'
+syn match yamlNumber
+ \ display
+ \ '0xx+'
+syn match yamlNumber
+ \ display
+ \ '([+-]=[iI]nf)'
+syn match yamlNumber
+ \ display
+ \ '(NaN)'
+
+syn match yamlConstant
+ \ '<[~yn]>'
+syn keyword yamlConstant
+ \ true
+ \ True
+ \ TRUE
+ \ false
+ \ False
+ \ FALSE
+syn keyword yamlConstant
+ \ yes
+ \ Yes
+ \ on
+ \ ON
+ \ no
+ \ No
+ \ off
+ \ OFF
+syn keyword yamlConstant
+ \ null
+ \ Null
+ \ NULL
+ \ nil
+ \ Nil
+ \ NIL
+
+syn match yamlTimestamp
+ \ '\d\d\d\d-\%(1[0-2]\|\d\)-\%(3[0-2]\|2\d\|1\d\|\d\)\%( \%([01]\d\|2[0-3]\):[0-5]\d:[0-5]\d.\d\d [+-]\%([01]\d\|2[0-3]\):[0-5]\d\|t\%([01]\d\|2[0-3]\):[0-5]\d:[0-5]\d.\d\d[+-]\%([01]\d\|2[0-3]\):[0-5]\d\|T\%([01]\d\|2[0-3]\):[0-5]\d:[0-5]\d.\dZ\)\='
+
+syn region yamlDocumentHeader
+ \ start='---'
+ \ end='$'
+ \ contains=yamlDirective
+syn match yamlDocumentEnd
+ \ '\.\.\.'
+
+syn match yamlDirective
+ \ contained
+ \ '%[^:]+:.+'
+
+syn match yamlIndentation
+ \ '^s*'
+ \ contains=yamlIndentationError
+
+syn match yamlIndentationError
+ \ 't'
hi def link yamlTodo Todo
hi def link yamlComment Comment
@@ -76,6 +163,7 @@ hi def link yamlSingleEscape SpecialChar
hi def link yamlNumber Number
hi def link yamlConstant Constant
hi def link yamlTimestamp Number
+hi def link yamlIndentationError Error
let b:current_syntax = "yaml"