7
|
1 " Vim syntax file
|
810
|
2 " Language: Subversion (svn) commit file
|
|
3 " Maintainer: Dmitry Vasiliev <dima at hlabs dot spb dot ru>
|
|
4 " URL: http://www.hlabs.spb.ru/vim/svn.vim
|
|
5 " Revision: $Id$
|
|
6 " Filenames: svn-commit*.tmp
|
|
7 " Version: 1.5
|
|
8
|
|
9 " Contributors:
|
|
10 " Stefano Zacchiroli
|
7
|
11
|
|
12 " For version 5.x: Clear all syntax items.
|
|
13 " For version 6.x: Quit when a syntax file was already loaded.
|
|
14 if version < 600
|
|
15 syntax clear
|
|
16 elseif exists("b:current_syntax")
|
|
17 finish
|
|
18 endif
|
|
19
|
810
|
20 syn region svnRegion start="^--.*--$" end="\%$" contains=ALL
|
|
21 syn match svnRemoved "^D .*$" contained
|
|
22 syn match svnAdded "^A[ M] .*$" contained
|
|
23 syn match svnModified "^M[ M] .*$" contained
|
|
24 syn match svnProperty "^_M .*$" contained
|
7
|
25
|
|
26 " Synchronization.
|
|
27 syn sync clear
|
810
|
28 syn sync match svnSync grouphere svnRegion "^--.*--$"me=s-1
|
7
|
29
|
|
30 " Define the default highlighting.
|
|
31 " For version 5.7 and earlier: only when not done already.
|
|
32 " For version 5.8 and later: only when an item doesn't have highlighting yet.
|
|
33 if version >= 508 || !exists("did_svn_syn_inits")
|
|
34 if version <= 508
|
|
35 let did_svn_syn_inits = 1
|
|
36 command -nargs=+ HiLink hi link <args>
|
|
37 else
|
|
38 command -nargs=+ HiLink hi def link <args>
|
|
39 endif
|
|
40
|
810
|
41 HiLink svnRegion Comment
|
|
42 HiLink svnRemoved Constant
|
|
43 HiLink svnAdded Identifier
|
|
44 HiLink svnModified Special
|
|
45 HiLink svnProperty Special
|
7
|
46
|
|
47 delcommand HiLink
|
|
48 endif
|
|
49
|
|
50 let b:current_syntax = "svn"
|