annotate runtime/syntax/diff.vim @ 574:25a70b1cd2da

updated for version 7.0163
author vimboss
date Tue, 06 Dec 2005 19:59:18 +0000
parents 7033303ea0c0
children f8f81a88a047
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 " Language: Diff (context or unified)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
3 " Maintainer: Bram Moolenaar <Bram@vim.org>
344
7033303ea0c0 updated for version 7.0089
vimboss
parents: 7
diff changeset
4 " Last Change: 2005 Jun 20
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
5
344
7033303ea0c0 updated for version 7.0089
vimboss
parents: 7
diff changeset
6 " Quit when a (custom) syntax file was already loaded
7033303ea0c0 updated for version 7.0089
vimboss
parents: 7
diff changeset
7 if exists("b:current_syntax")
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
8 finish
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
9 endif
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
10
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
11 syn match diffOnly "^Only in .*"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
12 syn match diffIdentical "^Files .* and .* are identical$"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
13 syn match diffDiffer "^Files .* and .* differ$"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
14 syn match diffBDiffer "^Binary files .* and .* differ$"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
15 syn match diffIsA "^File .* is a .* while file .* is a .*"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
16 syn match diffNoEOL "^No newline at end of file .*"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
17 syn match diffCommon "^Common subdirectories: .*"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
18
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
19 syn match diffRemoved "^-.*"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
20 syn match diffRemoved "^<.*"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
21 syn match diffAdded "^+.*"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
22 syn match diffAdded "^>.*"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
23 syn match diffChanged "^! .*"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
24
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
25 syn match diffSubname " @@..*"ms=s+3 contained
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
26 syn match diffLine "^@.*" contains=diffSubname
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
27 syn match diffLine "^\<\d\+\>.*"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
28 syn match diffLine "^\*\*\*\*.*"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
29
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
30 "Some versions of diff have lines like "#c#" and "#d#" (where # is a number)
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
31 syn match diffLine "^\d\+\(,\d\+\)\=[cda]\d\+\>.*"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
32
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
33 syn match diffFile "^diff.*"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
34 syn match diffFile "^+++ .*"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
35 syn match diffFile "^Index: .*$"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
36 syn match diffFile "^==== .*$"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
37 syn match diffOldFile "^\*\*\* .*"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
38 syn match diffNewFile "^--- .*"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
39
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
40 syn match diffComment "^#.*"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
41
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
42 " Define the default highlighting.
344
7033303ea0c0 updated for version 7.0089
vimboss
parents: 7
diff changeset
43 " Only used when an item doesn't have highlighting yet
7033303ea0c0 updated for version 7.0089
vimboss
parents: 7
diff changeset
44 hi def link diffOldFile diffFile
7033303ea0c0 updated for version 7.0089
vimboss
parents: 7
diff changeset
45 hi def link diffNewFile diffFile
7033303ea0c0 updated for version 7.0089
vimboss
parents: 7
diff changeset
46 hi def link diffFile Type
7033303ea0c0 updated for version 7.0089
vimboss
parents: 7
diff changeset
47 hi def link diffOnly Constant
7033303ea0c0 updated for version 7.0089
vimboss
parents: 7
diff changeset
48 hi def link diffIdentical Constant
7033303ea0c0 updated for version 7.0089
vimboss
parents: 7
diff changeset
49 hi def link diffDiffer Constant
7033303ea0c0 updated for version 7.0089
vimboss
parents: 7
diff changeset
50 hi def link diffBDiffer Constant
7033303ea0c0 updated for version 7.0089
vimboss
parents: 7
diff changeset
51 hi def link diffIsA Constant
7033303ea0c0 updated for version 7.0089
vimboss
parents: 7
diff changeset
52 hi def link diffNoEOL Constant
7033303ea0c0 updated for version 7.0089
vimboss
parents: 7
diff changeset
53 hi def link diffCommon Constant
7033303ea0c0 updated for version 7.0089
vimboss
parents: 7
diff changeset
54 hi def link diffRemoved Special
7033303ea0c0 updated for version 7.0089
vimboss
parents: 7
diff changeset
55 hi def link diffChanged PreProc
7033303ea0c0 updated for version 7.0089
vimboss
parents: 7
diff changeset
56 hi def link diffAdded Identifier
7033303ea0c0 updated for version 7.0089
vimboss
parents: 7
diff changeset
57 hi def link diffLine Statement
7033303ea0c0 updated for version 7.0089
vimboss
parents: 7
diff changeset
58 hi def link diffSubname PreProc
7033303ea0c0 updated for version 7.0089
vimboss
parents: 7
diff changeset
59 hi def link diffComment Comment
7
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
60
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
61 let b:current_syntax = "diff"
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
62
3fc0f57ecb91 updated for version 7.0001
vimboss
parents:
diff changeset
63 " vim: ts=8 sw=2