annotate runtime/syntax/pcap.vim @ 18518:59c56c97049d v8.1.2253

patch 8.1.2253: using "which" to check for an executable is not reliable Commit: https://github.com/vim/vim/commit/ad4de52510d5b4a949c0c9e25b5d5333744820b3 Author: Bram Moolenaar <Bram@vim.org> Date: Mon Nov 4 21:24:48 2019 +0100 patch 8.1.2253: using "which" to check for an executable is not reliable Problem: Using "which" to check for an executable is not reliable. Solution: Use "command -v" instead. Also exit with error code when generating tags has an error. (closes #5174)
author Bram Moolenaar <Bram@vim.org>
date Mon, 04 Nov 2019 21:30:03 +0100
parents 46763b01cd9a
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
1 " Vim syntax file
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
2 " Config file: printcap
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
3 " Maintainer: Lennart Schultz <Lennart.Schultz@ecmwf.int> (defunct)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
4 " Modified by Bram
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
5 " Last Change: 2003 May 11
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
6
10048
43efa4f5a8ea commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents: 7
diff changeset
7 " 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
8 if exists("b:current_syntax")
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
9 finish
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
10 endif
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
11
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
12 "define keywords
10048
43efa4f5a8ea commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents: 7
diff changeset
13 setlocal isk=@,46-57,_,-,#,=,192-255
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
14
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
15 "first all the bad guys
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
16 syn match pcapBad '^.\+$' "define any line as bad
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
17 syn match pcapBadword '\k\+' contained "define any sequence of keywords as bad
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
18 syn match pcapBadword ':' contained "define any single : as bad
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
19 syn match pcapBadword '\\' contained "define any single \ as bad
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
20 "then the good boys
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
21 " Boolean keywords
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
22 syn match pcapKeyword contained ':\(fo\|hl\|ic\|rs\|rw\|sb\|sc\|sf\|sh\)'
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
23 " Numeric Keywords
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
24 syn match pcapKeyword contained ':\(br\|du\|fc\|fs\|mx\|pc\|pl\|pw\|px\|py\|xc\|xs\)#\d\+'
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
25 " String Keywords
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
26 syn match pcapKeyword contained ':\(af\|cf\|df\|ff\|gf\|if\|lf\|lo\|lp\|nd\|nf\|of\|rf\|rg\|rm\|rp\|sd\|st\|tf\|tr\|vf\)=\k*'
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
27 " allow continuation
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
28 syn match pcapEnd ':\\$' contained
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
29 "
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
30 syn match pcapDefineLast '^\s.\+$' contains=pcapBadword,pcapKeyword
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
31 syn match pcapDefine '^\s.\+$' contains=pcapBadword,pcapKeyword,pcapEnd
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
32 syn match pcapHeader '^\k[^|]\+\(|\k[^|]\+\)*:\\$'
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
33 syn match pcapComment "#.*$"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
34
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
35 syn sync minlines=50
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
36
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
37
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
38 " Define the default highlighting.
10048
43efa4f5a8ea commit https://github.com/vim/vim/commit/89bcfda6834aba724d12554a34b9ed49f5789fd5
Christian Brabandt <cb@256bit.org>
parents: 7
diff changeset
39 " Only when an item doesn't have highlighting yet
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
40
10051
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
41 hi def link pcapBad WarningMsg
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
42 hi def link pcapBadword WarningMsg
46763b01cd9a commit https://github.com/vim/vim/commit/f37506f60f87d52a9e8850e30067645e2b13783c
Christian Brabandt <cb@256bit.org>
parents: 10048
diff changeset
43 hi def link pcapComment Comment
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
44
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
45
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
46 let b:current_syntax = "pcap"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
47
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
48 " vim: ts=8