Mercurial > vim
annotate runtime/syntax/apachestyle.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 | 3fc0f57ecb91 |
children | 46763b01cd9a |
rev | line source |
---|---|
7 | 1 " Vim syntax file |
2 " Language: Apache-Style configuration files (proftpd.conf/apache.conf/..) | |
3 " Maintainer: Christian Hammers <ch@westend.com> | |
4 " URL: none | |
5 " ChangeLog: | |
6 " 2001-05-04,ch | |
7 " adopted Vim 6.0 syntax style | |
8 " 1999-10-28,ch | |
9 " initial release | |
10 | |
11 " The following formats are recognised: | |
12 " Apache-style .conf | |
13 " # Comment | |
14 " Option value | |
15 " Option value1 value2 | |
16 " Option = value1 value2 #not apache but also allowed | |
17 " <Section Name?> | |
18 " Option value | |
19 " <SubSection Name?> | |
20 " </SubSection> | |
21 " </Section> | |
22 | |
10048
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
7
diff
changeset
|
23 " quit when a syntax file was already loaded |
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
7
diff
changeset
|
24 if exists("b:current_syntax") |
7 | 25 finish |
26 endif | |
27 | |
28 syn case ignore | |
29 | |
30 syn match apComment /^\s*#.*$/ | |
31 syn match apOption /^\s*[^ \t#<=]*/ | |
32 "syn match apLastValue /[^ \t<=#]*$/ contains=apComment ugly | |
33 | |
34 " tags | |
35 syn region apTag start=/</ end=/>/ contains=apTagOption,apTagError | |
36 " the following should originally be " [^<>]+" but this didn't work :( | |
37 syn match apTagOption contained / [-\/_\.:*a-zA-Z0-9]\+/ms=s+1 | |
38 syn match apTagError contained /[^>]</ms=s+1 | |
39 | |
40 " Define the default highlighting. | |
10048
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
7
diff
changeset
|
41 " Only when an item doesn't have highlighting yet |
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
7
diff
changeset
|
42 command -nargs=+ HiLink hi def link <args> |
7 | 43 |
10048
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
7
diff
changeset
|
44 HiLink apComment Comment |
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
7
diff
changeset
|
45 HiLink apOption Keyword |
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
7
diff
changeset
|
46 "HiLink apLastValue Identifier ugly? |
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
7
diff
changeset
|
47 HiLink apTag Special |
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
7
diff
changeset
|
48 HiLink apTagOption Identifier |
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
7
diff
changeset
|
49 HiLink apTagError Error |
7 | 50 |
10048
43efa4f5a8ea
commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents:
7
diff
changeset
|
51 delcommand HiLink |
7 | 52 |
53 let b:current_syntax = "apachestyle" | |
54 " vim: ts=8 |