File: stgsquash.vim

package info (click to toggle)
stgit 0.19-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 1,748 kB
  • sloc: python: 10,558; sh: 5,739; lisp: 2,678; makefile: 142; perl: 42
file content (39 lines) | stat: -rw-r--r-- 1,462 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
" Vim syntax file
" Language:     StGit 'stg squash' commit message file
" Author:       Zane Bitter <zane.bitter@alliedtelesis.co.nz>

if exists("b:current_syntax")
  finish
endif


syn case match
syn sync minlines=50


if has("spell")
  syn spell toplevel
endif


syn match    stgsqFirstLine     "\%^.*" nextgroup=stgsqComment,stgsqContext,stgsqBlank skipnl
syn match    stgsqSummary       "^.\{0,50\}" contained containedin=stgsqFirstLine nextgroup=stgsqOverflow contains=@Spell
syn match    stgsqOverflow      ".*" contained contains=@Spell
syn match    stgsqBlank         "^.\+" contained contains=@Spell
syn match    stgsqSeparator     "-\+$" contained
syn region   stgsqPatch         start="^\(.\{66\}-\{4\}$\)\@=" end="\(^.\{66\}-\{4\}$\)\@=" contained containedin=stgsqContext contains=@Spell fold
syn match    stgsqNextPatch     "^.\{66\}-\{4\}$" contained containedin=stgsqPatch contains=stgsqPatchName
syn match    stgsqPatchName     "^.\{-\}\(-*$\)\@=" contained containedin=stgsqNextPatch nextgroup=stgsqSeparator
syn region   stgsqContext       start="^---" end="%$" contains=@Spell fold
syn match    stgsqComment       "^#.*"

hi def link  stgsqSummary       Keyword
hi def link  stgsqComment       Comment
hi def link  stgsqBlank         Error
hi def link  stgsqContext       Comment
hi def link  stgsqPatch         Constant
hi def link  stgsqPatchName     Identifier
hi def link  stgsqSeparator     Comment


let b:current_syntax = "stgsquash"