Mercurial > vim
annotate runtime/syntax/sm.vim @ 10048:43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Author: Bram Moolenaar <Bram@vim.org>
Date: Tue Aug 30 23:26:57 2016 +0200
Updated runtime files. Remove version checks for Vim older than 6.0.
author | Christian Brabandt <cb@256bit.org> |
---|---|
date | Tue, 30 Aug 2016 23:30:09 +0200 |
parents | dff4e29c6905 |
children | 46763b01cd9a |
rev | line source |
---|---|
7 | 1 " Vim syntax file |
2 " Language: sendmail | |
6479 | 3 " Maintainer: Charles E. Campbell <NdrOchipS@PcampbellAfamily.Mbiz> |
6744 | 4 " Last Change: Oct 23, 2014 |
5 " Version: 7 | |
6479 | 6 " URL: http://www.drchip.org/astronaut/vim/index.html#SYNTAX_SM |
7 | 7 |
6484 | 8 if exists("b:current_syntax") |
7 | 9 finish |
10 endif | |
11 | |
12 " Comments | |
13 syn match smComment "^#.*$" contains=@Spell | |
14 | |
15 " Definitions, Classes, Files, Options, Precedence, Trusted Users, Mailers | |
16 syn match smDefine "^[CDF]." | |
17 syn match smDefine "^O[AaBcdDeFfgHiLmNoQqrSsTtuvxXyYzZ]" | |
18 syn match smDefine "^O\s"he=e-1 | |
19 syn match smDefine "^M[a-zA-Z0-9]\+,"he=e-1 | |
20 syn match smDefine "^T" nextgroup=smTrusted | |
21 syn match smDefine "^P" nextgroup=smMesg | |
22 syn match smTrusted "\S\+$" contained | |
23 syn match smMesg "\S*="he=e-1 contained nextgroup=smPrecedence | |
24 syn match smPrecedence "-\=[0-9]\+" contained | |
25 | |
26 " Header Format H?list-of-mailer-flags?name: format | |
27 syn match smHeaderSep contained "[?:]" | |
28 syn match smHeader "^H\(?[a-zA-Z]\+?\)\=[-a-zA-Z_]\+:" contains=smHeaderSep | |
29 | |
30 " Variables | |
31 syn match smVar "\$[a-z\.\|]" | |
32 | |
33 " Rulesets | |
34 syn match smRuleset "^S\d*" | |
35 | |
36 " Rewriting Rules | |
37 syn match smRewrite "^R" skipwhite nextgroup=smRewriteLhsToken,smRewriteLhsUser | |
38 | |
39 syn match smRewriteLhsUser contained "[^\t$]\+" skipwhite nextgroup=smRewriteLhsToken,smRewriteLhsSep | |
40 syn match smRewriteLhsToken contained "\(\$[-*+]\|\$[-=][A-Za-z]\|\$Y\)\+" skipwhite nextgroup=smRewriteLhsUser,smRewriteLhsSep | |
41 | |
42 syn match smRewriteLhsSep contained "\t\+" skipwhite nextgroup=smRewriteRhsToken,smRewriteRhsUser | |
43 | |
44 syn match smRewriteRhsUser contained "[^\t$]\+" skipwhite nextgroup=smRewriteRhsToken,smRewriteRhsSep | |
45 syn match smRewriteRhsToken contained "\(\$\d\|\$>\d\|\$#\|\$@\|\$:[-_a-zA-Z]\+\|\$[[\]]\|\$@\|\$:\|\$[A-Za-z]\)\+" skipwhite nextgroup=smRewriteRhsUser,smRewriteRhsSep | |
46 | |
47 syn match smRewriteRhsSep contained "\t\+" skipwhite nextgroup=smRewriteComment,smRewriteRhsSep | |
48 syn match smRewriteRhsSep contained "$" | |
49 | |
50 syn match smRewriteComment contained "[^\t$]*$" | |
51 | |
52 " Clauses | |
53 syn match smClauseError "\$\." | |
54 syn match smElse contained "\$|" | |
55 syn match smClauseCont contained "^\t" | |
56 syn region smClause matchgroup=Delimiter start="\$?." matchgroup=Delimiter end="\$\." contains=smElse,smClause,smVar,smClauseCont | |
57 | |
58 " Define the default highlighting. | |
10048
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
6744
diff
changeset
|
59 " Only when an item doesn't have highlighting yet |
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
6744
diff
changeset
|
60 command -nargs=+ HiLink hi def link <args> |
7 | 61 |
10048
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
6744
diff
changeset
|
62 HiLink smClause Special |
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
6744
diff
changeset
|
63 HiLink smClauseError Error |
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
6744
diff
changeset
|
64 HiLink smComment Comment |
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
6744
diff
changeset
|
65 HiLink smDefine Statement |
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
6744
diff
changeset
|
66 HiLink smElse Delimiter |
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
6744
diff
changeset
|
67 HiLink smHeader Statement |
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
6744
diff
changeset
|
68 HiLink smHeaderSep String |
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
6744
diff
changeset
|
69 HiLink smMesg Special |
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
6744
diff
changeset
|
70 HiLink smPrecedence Number |
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
6744
diff
changeset
|
71 HiLink smRewrite Statement |
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
6744
diff
changeset
|
72 HiLink smRewriteComment Comment |
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
6744
diff
changeset
|
73 HiLink smRewriteLhsToken String |
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
6744
diff
changeset
|
74 HiLink smRewriteLhsUser Statement |
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
6744
diff
changeset
|
75 HiLink smRewriteRhsToken String |
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
6744
diff
changeset
|
76 HiLink smRuleset Preproc |
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
6744
diff
changeset
|
77 HiLink smTrusted Special |
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
6744
diff
changeset
|
78 HiLink smVar String |
7 | 79 |
10048
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
6744
diff
changeset
|
80 delcommand HiLink |
7 | 81 |
82 let b:current_syntax = "sm" | |
83 | |
84 " vim: ts=18 |