2014-07-10 21:05:51 -07:00
|
|
|
" Vim syntax file
|
|
|
|
" Language: git rebase --interactive
|
|
|
|
" Maintainer: Tim Pope <vimNOSPAM@tpope.org>
|
|
|
|
" Filenames: git-rebase-todo
|
2020-11-26 20:30:56 -07:00
|
|
|
" Last Change: 2019 Dec 06
|
2014-07-10 21:05:51 -07:00
|
|
|
|
|
|
|
if exists("b:current_syntax")
|
|
|
|
finish
|
|
|
|
endif
|
|
|
|
|
|
|
|
syn case match
|
|
|
|
|
2020-11-26 20:28:07 -07:00
|
|
|
syn match gitrebaseHash "\v<\x{7,}>" contained
|
|
|
|
syn match gitrebaseCommit "\v<\x{7,}>" nextgroup=gitrebaseSummary skipwhite
|
2014-07-10 21:05:51 -07:00
|
|
|
syn match gitrebasePick "\v^p%(ick)=>" nextgroup=gitrebaseCommit skipwhite
|
|
|
|
syn match gitrebaseReword "\v^r%(eword)=>" nextgroup=gitrebaseCommit skipwhite
|
|
|
|
syn match gitrebaseEdit "\v^e%(dit)=>" nextgroup=gitrebaseCommit skipwhite
|
|
|
|
syn match gitrebaseSquash "\v^s%(quash)=>" nextgroup=gitrebaseCommit skipwhite
|
|
|
|
syn match gitrebaseFixup "\v^f%(ixup)=>" nextgroup=gitrebaseCommit skipwhite
|
|
|
|
syn match gitrebaseExec "\v^%(x|exec)>" nextgroup=gitrebaseCommand skipwhite
|
2020-11-26 20:28:07 -07:00
|
|
|
syn match gitrebaseBreak "\v^b%(reak)=>"
|
2017-04-28 12:06:44 -07:00
|
|
|
syn match gitrebaseDrop "\v^d%(rop)=>" nextgroup=gitrebaseCommit skipwhite
|
2020-11-26 20:28:07 -07:00
|
|
|
syn match gitrebaseNoop "\v^noop>"
|
|
|
|
syn match gitrebaseMerge "\v^m(erge)=>" nextgroup=gitrebaseMergeOption,gitrebaseName skipwhite
|
|
|
|
syn match gitrebaseLabel "\v^l(abel)=>" nextgroup=gitrebaseName skipwhite
|
2020-11-26 20:30:56 -07:00
|
|
|
syn match gitrebaseReset "\v^(t|reset)=>" nextgroup=gitrebaseName skipwhite
|
2014-07-10 21:05:51 -07:00
|
|
|
syn match gitrebaseSummary ".*" contains=gitrebaseHash contained
|
|
|
|
syn match gitrebaseCommand ".*" contained
|
2020-11-26 20:28:07 -07:00
|
|
|
syn match gitrebaseComment "^\s*#.*" contains=gitrebaseHash
|
2014-07-10 21:05:51 -07:00
|
|
|
syn match gitrebaseSquashError "\v%^%(s%(quash)=>|f%(ixup)=>)" nextgroup=gitrebaseCommit skipwhite
|
2020-11-26 20:28:07 -07:00
|
|
|
syn match gitrebaseMergeOption "\v-[Cc]>" nextgroup=gitrebaseMergeCommit skipwhite contained
|
|
|
|
syn match gitrebaseMergeCommit "\v<\x{7,}>" nextgroup=gitrebaseName skipwhite contained
|
|
|
|
syn match gitrebaseName "\v[^[:space:].*?i:^~/-]\S+" nextgroup=gitrebaseMergeComment skipwhite contained
|
|
|
|
syn match gitrebaseMergeComment "#" nextgroup=gitrebaseSummary skipwhite contained
|
2014-07-10 21:05:51 -07:00
|
|
|
|
|
|
|
hi def link gitrebaseCommit gitrebaseHash
|
|
|
|
hi def link gitrebaseHash Identifier
|
2020-11-26 20:28:07 -07:00
|
|
|
hi def link gitrebasePick Type
|
|
|
|
hi def link gitrebaseReword Conditional
|
2014-07-10 21:05:51 -07:00
|
|
|
hi def link gitrebaseEdit PreProc
|
2020-11-26 20:28:07 -07:00
|
|
|
hi def link gitrebaseSquash Statement
|
|
|
|
hi def link gitrebaseFixup Repeat
|
|
|
|
hi def link gitrebaseExec Operator
|
|
|
|
hi def link gitrebaseBreak Macro
|
2017-04-28 12:06:44 -07:00
|
|
|
hi def link gitrebaseDrop Comment
|
2020-11-26 20:28:07 -07:00
|
|
|
hi def link gitrebaseNoop Comment
|
|
|
|
hi def link gitrebaseMerge Exception
|
|
|
|
hi def link gitrebaseLabel Label
|
|
|
|
hi def link gitrebaseReset Keyword
|
2014-07-10 21:05:51 -07:00
|
|
|
hi def link gitrebaseSummary String
|
|
|
|
hi def link gitrebaseComment Comment
|
|
|
|
hi def link gitrebaseSquashError Error
|
2020-11-26 20:28:07 -07:00
|
|
|
hi def link gitrebaseMergeCommit gitrebaseCommit
|
|
|
|
hi def link gitrebaseMergeComment gitrebaseComment
|
|
|
|
hi def link gitrebaseName Tag
|
2014-07-10 21:05:51 -07:00
|
|
|
|
|
|
|
let b:current_syntax = "gitrebase"
|