blob: 421b11ffa30898b6022f6e58ce68f9dd6c80ae5d [file] [log] [blame]
Bram Moolenaar01164a62017-11-02 22:58:42 +01001" Vim syntax file
2" Language: NeoMutt setup files
Bram Moolenaar403f3eb2019-11-20 22:31:13 +01003" Maintainer: Richard Russon <rich@flatcap.org>
4" Previous Maintainer: Guillaume Brogi <gui-gui@netcourrier.com>
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +01005" Last Change: 2022-04-08
Bram Moolenaar01164a62017-11-02 22:58:42 +01006" Original version based on syntax/muttrc.vim
7
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +01008" This file covers NeoMutt 2022-04-08
Bram Moolenaar01164a62017-11-02 22:58:42 +01009
10" quit when a syntax file was already loaded
11if exists("b:current_syntax")
12 finish
13endif
14
15let s:cpo_save = &cpo
16set cpo&vim
17
18" Set the keyword characters
19setlocal isk=@,48-57,_,-
20
21" handling optional variables
Bram Moolenaare46a4402020-06-30 20:38:27 +020022syntax match muttrcComment "^# .*$" contains=@Spell
23syntax match muttrcComment "^#[^ ].*$"
24syntax match muttrcComment "^#$"
25syntax match muttrcComment "[^\\]#.*$"lc=1
Bram Moolenaar01164a62017-11-02 22:58:42 +010026
27" Escape sequences (back-tick and pipe goes here too)
Bram Moolenaare46a4402020-06-30 20:38:27 +020028syntax match muttrcEscape +\\[#tnr"'Cc ]+
29syntax match muttrcEscape +[`|]+
30syntax match muttrcEscape +\\$+
Bram Moolenaar01164a62017-11-02 22:58:42 +010031
32" The variables takes the following arguments
Bram Moolenaare46a4402020-06-30 20:38:27 +020033syntax region muttrcString contained keepend start=+"+ms=e skip=+\\"+ end=+"+ contains=muttrcEscape,muttrcCommand,muttrcAction,muttrcShellString
34syntax region muttrcString contained keepend start=+'+ms=e skip=+\\'+ end=+'+ contains=muttrcEscape,muttrcCommand,muttrcAction
Bram Moolenaar01164a62017-11-02 22:58:42 +010035syntax match muttrcStringNL contained skipwhite skipnl "\s*\\$" nextgroup=muttrcString,muttrcStringNL
36
Bram Moolenaare46a4402020-06-30 20:38:27 +020037syntax region muttrcShellString matchgroup=muttrcEscape keepend start=+`+ skip=+\\`+ end=+`+ contains=muttrcVarStr,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcCommand
Bram Moolenaar01164a62017-11-02 22:58:42 +010038
39syntax match muttrcRXChars contained /[^\\][][.*?+]\+/hs=s+1
40syntax match muttrcRXChars contained /[][|()][.*?+]*/
41syntax match muttrcRXChars contained /['"]^/ms=s+1
42syntax match muttrcRXChars contained /$['"]/me=e-1
43syntax match muttrcRXChars contained /\\/
44" Why does muttrcRXString2 work with one \ when muttrcRXString requires two?
45syntax region muttrcRXString contained skipwhite start=+'+ skip=+\\'+ end=+'+ contains=muttrcRXChars
46syntax region muttrcRXString contained skipwhite start=+"+ skip=+\\"+ end=+"+ contains=muttrcRXChars
Bram Moolenaare46a4402020-06-30 20:38:27 +020047syntax region muttrcRXString contained skipwhite start=+[^ "'^]+ skip=+\\\s+ end=+\s+re=e-1 contains=muttrcRXChars
Bram Moolenaar01164a62017-11-02 22:58:42 +010048" For some reason, skip refuses to match backslashes here...
49syntax region muttrcRXString contained matchgroup=muttrcRXChars skipwhite start=+\^+ end=+[^\\]\s+re=e-1 contains=muttrcRXChars
50syntax region muttrcRXString contained matchgroup=muttrcRXChars skipwhite start=+\^+ end=+$\s+ contains=muttrcRXChars
51syntax region muttrcRXString2 contained skipwhite start=+'+ skip=+\'+ end=+'+ contains=muttrcRXChars
52syntax region muttrcRXString2 contained skipwhite start=+"+ skip=+\"+ end=+"+ contains=muttrcRXChars
53
Bram Moolenaare46a4402020-06-30 20:38:27 +020054" these must be kept synchronized with muttrcRXString, but are intended for muttrcRXHooks
Bram Moolenaar01164a62017-11-02 22:58:42 +010055syntax region muttrcRXHookString contained keepend skipwhite start=+'+ skip=+\\'+ end=+'+ contains=muttrcRXString nextgroup=muttrcString,muttrcStringNL
56syntax region muttrcRXHookString contained keepend skipwhite start=+"+ skip=+\\"+ end=+"+ contains=muttrcRXString nextgroup=muttrcString,muttrcStringNL
Bram Moolenaare46a4402020-06-30 20:38:27 +020057syntax region muttrcRXHookString contained keepend skipwhite start=+[^ "'^]+ skip=+\\\s+ end=+\s+re=e-1 contains=muttrcRXString nextgroup=muttrcString,muttrcStringNL
Bram Moolenaar01164a62017-11-02 22:58:42 +010058syntax region muttrcRXHookString contained keepend skipwhite start=+\^+ end=+[^\\]\s+re=e-1 contains=muttrcRXString nextgroup=muttrcString,muttrcStringNL
59syntax region muttrcRXHookString contained keepend matchgroup=muttrcRXChars skipwhite start=+\^+ end=+$\s+ contains=muttrcRXString nextgroup=muttrcString,muttrcStringNL
Bram Moolenaare46a4402020-06-30 20:38:27 +020060syntax match muttrcRXHookStringNL contained skipwhite skipnl "\s*\\$" nextgroup=muttrcRXHookString,muttrcRXHookStringNL
Bram Moolenaar01164a62017-11-02 22:58:42 +010061
62" these are exclusively for args lists (e.g. -rx pat pat pat ...)
Bram Moolenaare46a4402020-06-30 20:38:27 +020063syntax region muttrcRXPat contained keepend skipwhite start=+'+ skip=+\\'+ end=+'\s*+ contains=muttrcRXString nextgroup=muttrcRXPat
64syntax region muttrcRXPat contained keepend skipwhite start=+"+ skip=+\\"+ end=+"\s*+ contains=muttrcRXString nextgroup=muttrcRXPat
65syntax match muttrcRXPat contained /[^-'"#!]\S\+/ skipwhite contains=muttrcRXChars nextgroup=muttrcRXPat
66syntax match muttrcRXDef contained "-rx\s\+" skipwhite nextgroup=muttrcRXPat
Bram Moolenaar01164a62017-11-02 22:58:42 +010067
Bram Moolenaare46a4402020-06-30 20:38:27 +020068syntax match muttrcSpecial +\(['"]\)!\1+
Bram Moolenaar01164a62017-11-02 22:58:42 +010069
Bram Moolenaare46a4402020-06-30 20:38:27 +020070syntax match muttrcSetStrAssignment contained skipwhite /=\s*\%(\\\?\$\)\?[0-9A-Za-z_-]\+/hs=s+1 nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr contains=muttrcVariable,muttrcEscapedVariable
71syntax region muttrcSetStrAssignment contained skipwhite keepend start=+=\s*"+hs=s+1 end=+"+ skip=+\\"+ nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr contains=muttrcString
72syntax region muttrcSetStrAssignment contained skipwhite keepend start=+=\s*'+hs=s+1 end=+'+ skip=+\\'+ nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr contains=muttrcString
73syntax match muttrcSetBoolAssignment contained skipwhite /=\s*\\\?\$\w\+/hs=s+1 nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr contains=muttrcVariable,muttrcEscapedVariable
74syntax match muttrcSetBoolAssignment contained skipwhite /=\s*\%(yes\|no\)/hs=s+1 nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
75syntax match muttrcSetBoolAssignment contained skipwhite /=\s*"\%(yes\|no\)"/hs=s+1 nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
76syntax match muttrcSetBoolAssignment contained skipwhite /=\s*'\%(yes\|no\)'/hs=s+1 nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
77syntax match muttrcSetQuadAssignment contained skipwhite /=\s*\\\?\$\w\+/hs=s+1 nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr contains=muttrcVariable,muttrcEscapedVariable
78syntax match muttrcSetQuadAssignment contained skipwhite /=\s*\%(ask-\)\?\%(yes\|no\)/hs=s+1 nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
79syntax match muttrcSetQuadAssignment contained skipwhite /=\s*"\%(ask-\)\?\%(yes\|no\)"/hs=s+1 nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
80syntax match muttrcSetQuadAssignment contained skipwhite /=\s*'\%(ask-\)\?\%(yes\|no\)'/hs=s+1 nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
81syntax match muttrcSetNumAssignment contained skipwhite /=\s*\\\?\$\w\+/hs=s+1 nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr contains=muttrcVariable,muttrcEscapedVariable
82syntax match muttrcSetNumAssignment contained skipwhite /=\s*\d\+/hs=s+1 nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
83syntax match muttrcSetNumAssignment contained skipwhite /=\s*"\d\+"/hs=s+1 nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
84syntax match muttrcSetNumAssignment contained skipwhite /=\s*'\d\+'/hs=s+1 nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
Bram Moolenaar01164a62017-11-02 22:58:42 +010085
86" Now catch some email addresses and headers (purified version from mail.vim)
Bram Moolenaare46a4402020-06-30 20:38:27 +020087syntax match muttrcEmail "[a-zA-Z0-9._-]\+@[a-zA-Z0-9./-]\+"
88syntax match muttrcHeader "\<\c\%(From\|To\|C[Cc]\|B[Cc][Cc]\|Reply-To\|Subject\|Return-Path\|Received\|Date\|Replied\|Attach\)\>:\="
Bram Moolenaar01164a62017-11-02 22:58:42 +010089
90syntax match muttrcKeySpecial contained +\%(\\[Cc'"]\|\^\|\\[01]\d\{2}\)+
Bram Moolenaare46a4402020-06-30 20:38:27 +020091syntax match muttrcKey contained "\S\+" contains=muttrcKeySpecial,muttrcKeyName
92syntax region muttrcKey contained start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=muttrcKeySpecial,muttrcKeyName
93syntax region muttrcKey contained start=+'+ skip=+\\\\\|\\'+ end=+'+ contains=muttrcKeySpecial,muttrcKeyName
Bram Moolenaar01164a62017-11-02 22:58:42 +010094syntax match muttrcKeyName contained "\\[trne]"
95syntax match muttrcKeyName contained "\c<\%(BackSpace\|BackTab\|Delete\|Down\|End\|Enter\|Esc\|Home\|Insert\|Left\|Next\|PageDown\|PageUp\|Return\|Right\|Space\|Tab\|Up\)>"
96syntax match muttrcKeyName contained "\c<F\d\+>"
97
98syntax match muttrcFormatErrors contained /%./
99
100syntax match muttrcStrftimeEscapes contained /%[AaBbCcDdeFGgHhIjklMmnpRrSsTtUuVvWwXxYyZz+%]/
101syntax match muttrcStrftimeEscapes contained /%E[cCxXyY]/
102syntax match muttrcStrftimeEscapes contained /%O[BdeHImMSuUVwWy]/
103
Bram Moolenaare46a4402020-06-30 20:38:27 +0200104syntax region muttrcAliasFormatStr contained skipwhite keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcAliasFormatEscapes,muttrcAliasFormatConditionals,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
105syntax region muttrcAliasFormatStr contained skipwhite keepend start=+'+ skip=+\\'+ end=+'+ contains=muttrcAliasFormatEscapes,muttrcAliasFormatConditionals,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
106syntax region muttrcAttachFormatStr contained skipwhite keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcAttachFormatEscapes,muttrcAttachFormatConditionals,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
107syntax region muttrcAttachFormatStr contained skipwhite keepend start=+'+ skip=+\\'+ end=+'+ contains=muttrcAttachFormatEscapes,muttrcAttachFormatConditionals,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
108syntax region muttrcComposeFormatStr contained skipwhite keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcComposeFormatEscapes,muttrcComposeFormatConditionals,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
109syntax region muttrcComposeFormatStr contained skipwhite keepend start=+'+ skip=+\\'+ end=+'+ contains=muttrcComposeFormatEscapes,muttrcComposeFormatConditionals,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
110syntax region muttrcFolderFormatStr contained skipwhite keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcFolderFormatEscapes,muttrcFolderFormatConditionals,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
111syntax region muttrcFolderFormatStr contained skipwhite keepend start=+'+ skip=+\\'+ end=+'+ contains=muttrcFolderFormatEscapes,muttrcFolderFormatConditionals,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
112syntax region muttrcGroupIndexFormatStr contained skipwhite keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcGroupIndexFormatEscapes,muttrcGroupIndexFormatConditionals,muttrcFormatErrors,muttrcTimeEscapes nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
113syntax region muttrcGroupIndexFormatStr contained skipwhite keepend start=+'+ skip=+\\'+ end=+'+ contains=muttrcGroupIndexFormatEscapes,muttrcGroupIndexFormatConditionals,muttrcFormatErrors,muttrcTimeEscapes nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
114syntax region muttrcIndexFormatStr contained skipwhite keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcIndexFormatEscapes,muttrcIndexFormatConditionals,muttrcFormatErrors,muttrcTimeEscapes nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
115syntax region muttrcIndexFormatStr contained skipwhite keepend start=+'+ skip=+\\'+ end=+'+ contains=muttrcIndexFormatEscapes,muttrcIndexFormatConditionals,muttrcFormatErrors,muttrcTimeEscapes nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
116syntax region muttrcMixFormatStr contained skipwhite keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcMixFormatEscapes,muttrcMixFormatConditionals,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
117syntax region muttrcMixFormatStr contained skipwhite keepend start=+'+ skip=+\\'+ end=+'+ contains=muttrcMixFormatEscapes,muttrcMixFormatConditionals,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100118syntax region muttrcPatternFormatStr contained skipwhite keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcPatternFormatEscapes,muttrcPatternFormatConditionals,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
119syntax region muttrcPatternFormatStr contained skipwhite keepend start=+'+ skip=+\\'+ end=+'+ contains=muttrcPatternFormatEscapes,muttrcPatternFormatConditionals,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
Bram Moolenaare46a4402020-06-30 20:38:27 +0200120syntax region muttrcPGPCmdFormatStr contained skipwhite keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcPGPCmdFormatEscapes,muttrcPGPCmdFormatConditionals,muttrcVariable,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
121syntax region muttrcPGPCmdFormatStr contained skipwhite keepend start=+'+ skip=+\\'+ end=+'+ contains=muttrcPGPCmdFormatEscapes,muttrcPGPCmdFormatConditionals,muttrcVariable,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
122syntax region muttrcPGPFormatStr contained skipwhite keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcPGPFormatEscapes,muttrcPGPFormatConditionals,muttrcFormatErrors,muttrcPGPTimeEscapes nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
123syntax region muttrcPGPFormatStr contained skipwhite keepend start=+'+ skip=+\\'+ end=+'+ contains=muttrcPGPFormatEscapes,muttrcPGPFormatConditionals,muttrcFormatErrors,muttrcPGPTimeEscapes nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
124syntax region muttrcQueryFormatStr contained skipwhite keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcQueryFormatEscapes,muttrcQueryFormatConditionals,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
125syntax region muttrcQueryFormatStr contained skipwhite keepend start=+'+ skip=+\\'+ end=+'+ contains=muttrcQueryFormatEscapes,muttrcQueryFormatConditionals,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
126syntax region muttrcSidebarFormatStr contained skipwhite keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcSidebarFormatEscapes,muttrcSidebarFormatConditionals,muttrcFormatErrors,muttrcTimeEscapes nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
127syntax region muttrcSidebarFormatStr contained skipwhite keepend start=+'+ skip=+\\'+ end=+'+ contains=muttrcSidebarFormatEscapes,muttrcSidebarFormatConditionals,muttrcFormatErrors,muttrcTimeEscapes nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
128syntax region muttrcSmimeFormatStr contained skipwhite keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcSmimeFormatEscapes,muttrcSmimeFormatConditionals,muttrcVariable,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
129syntax region muttrcSmimeFormatStr contained skipwhite keepend start=+'+ skip=+\\'+ end=+'+ contains=muttrcSmimeFormatEscapes,muttrcSmimeFormatConditionals,muttrcVariable,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
130syntax region muttrcStatusFormatStr contained skipwhite keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcStatusFormatEscapes,muttrcStatusFormatConditionals,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
131syntax region muttrcStatusFormatStr contained skipwhite keepend start=+'+ skip=+\\'+ end=+'+ contains=muttrcStatusFormatEscapes,muttrcStatusFormatConditionals,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
132syntax region muttrcStrftimeFormatStr contained skipwhite keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcStrftimeEscapes,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
133syntax region muttrcStrftimeFormatStr contained skipwhite keepend start=+'+ skip=+\\'+ end=+'+ contains=muttrcStrftimeEscapes,muttrcFormatErrors nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
Bram Moolenaar01164a62017-11-02 22:58:42 +0100134
135" Format escapes and conditionals
136syntax match muttrcFormatConditionals2 contained /[^?]*?/
Bram Moolenaare46a4402020-06-30 20:38:27 +0200137function! s:escapesConditionals(baseName, sequence, padding, conditional)
Bram Moolenaar01164a62017-11-02 22:58:42 +0100138 exec 'syntax match muttrc' . a:baseName . 'Escapes contained /%\%(\%(-\?[0-9]\+\)\?\%(\.[0-9]\+\)\?\)\?[:_]\?\%(' . a:sequence . '\|%\)/'
Bram Moolenaare46a4402020-06-30 20:38:27 +0200139 if a:padding
Bram Moolenaar01164a62017-11-02 22:58:42 +0100140 exec 'syntax match muttrc' . a:baseName . 'Escapes contained /%[>|*]./'
141 endif
Bram Moolenaare46a4402020-06-30 20:38:27 +0200142 if a:conditional
Bram Moolenaar01164a62017-11-02 22:58:42 +0100143 exec 'syntax match muttrc' . a:baseName . 'Conditionals contained /%?\%(' . a:sequence . '\)?/ nextgroup=muttrcFormatConditionals2'
144 else
145 exec 'syntax match muttrc' . a:baseName . 'Conditionals contained /%?\%(' . a:sequence . '\)?/'
146 endif
147endfunction
148
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100149" CHECKED 2022-04-08
150" Ref: alias_format_str() in alias/dlg_alias.c
Bram Moolenaare46a4402020-06-30 20:38:27 +0200151call s:escapesConditionals('AliasFormat', '[acfnrt]', 1, 0)
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100152" Ref: attach_format_str() in attach/dlg_attach.c
Bram Moolenaar01164a62017-11-02 22:58:42 +0100153call s:escapesConditionals('AttachFormat', '[CcDdeFfIMmnQsTtuX]', 1, 1)
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100154" Ref: compose_format_str() in compose/cbar.c
Bram Moolenaare46a4402020-06-30 20:38:27 +0200155call s:escapesConditionals('ComposeFormat', '[ahlv]', 1, 1)
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100156" Ref: folder_format_str() in browser/browser.c
Bram Moolenaar403f3eb2019-11-20 22:31:13 +0100157call s:escapesConditionals('FolderFormat', '[CDdFfgilmNnstu]', 1, 0)
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100158" Ref: group_index_format_str() in nntp/browse.c
Bram Moolenaare46a4402020-06-30 20:38:27 +0200159call s:escapesConditionals('GroupIndexFormat', '[CdfMNns]', 1, 1)
160" Ref: index_format_str() in hdrline.c
161call s:escapesConditionals('IndexFormat', '[AaBbCDdEefgHIiJKLlMmNnOPqRrSsTtuvWXxYyZ(<[{]\|@\i\+@\|G[a-zA-Z]\+\|Fp\=\|z[cst]\|cr\=', 1, 1)
Bram Moolenaar7dda86f2018-04-20 22:36:41 +0200162" Ref: mix_format_str() in remailer.c
Bram Moolenaare46a4402020-06-30 20:38:27 +0200163call s:escapesConditionals('MixFormat', '[acns]', 1, 0)
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100164" Ref: pattern_format_str() in pattern/dlg_pattern.c
165call s:escapesConditionals('PatternFormat', '[den]', 1, 0)
Bram Moolenaare46a4402020-06-30 20:38:27 +0200166" Ref: pgp_command_format_str() in ncrypt/pgpinvoke.c
167call s:escapesConditionals('PGPCmdFormat', '[afprs]', 0, 1)
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100168" Ref: crypt_format_str() in ncrypt/dlg_gpgme.c
169" Ref: pgp_entry_format_str() in ncrypt/dlg_pgp.c
Bram Moolenaar7dda86f2018-04-20 22:36:41 +0200170" Note: crypt_format_str() supports 'p', but pgp_entry_fmt() does not
Bram Moolenaar403f3eb2019-11-20 22:31:13 +0100171call s:escapesConditionals('PGPFormat', '[AaCcFfKkLlnptu[]', 0, 0)
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100172" Ref: query_format_str() in alias/dlg_query.c
Bram Moolenaare46a4402020-06-30 20:38:27 +0200173call s:escapesConditionals('QueryFormat', '[acent]', 1, 1)
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100174" Ref: sidebar_format_str() in sidebar/window.c
Bram Moolenaare46a4402020-06-30 20:38:27 +0200175call s:escapesConditionals('SidebarFormat', '[!BDdFLNnorStZ]', 1, 1)
176" Ref: smime_command_format_str() in ncrypt/smime.c
177call s:escapesConditionals('SmimeFormat', '[aCcdfiks]', 0, 1)
178" Ref: status_format_str() in status.c
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100179call s:escapesConditionals('StatusFormat', '[bDdFfhLlMmnoPpRrSsTtuVv]', 1, 1)
Bram Moolenaar7dda86f2018-04-20 22:36:41 +0200180
Bram Moolenaar01164a62017-11-02 22:58:42 +0100181syntax region muttrcPGPTimeEscapes contained start=+%\[+ end=+\]+ contains=muttrcStrftimeEscapes
Bram Moolenaare46a4402020-06-30 20:38:27 +0200182syntax region muttrcTimeEscapes contained start=+%(+ end=+)+ contains=muttrcStrftimeEscapes
183syntax region muttrcTimeEscapes contained start=+%<+ end=+>+ contains=muttrcStrftimeEscapes
184syntax region muttrcTimeEscapes contained start=+%\[+ end=+\]+ contains=muttrcStrftimeEscapes
185syntax region muttrcTimeEscapes contained start=+%{+ end=+}+ contains=muttrcStrftimeEscapes
Bram Moolenaar01164a62017-11-02 22:58:42 +0100186
Bram Moolenaar7dda86f2018-04-20 22:36:41 +0200187syntax match muttrcVarEqualsAliasFmt contained skipwhite "=" nextgroup=muttrcAliasFormatStr
188syntax match muttrcVarEqualsAttachFmt contained skipwhite "=" nextgroup=muttrcAttachFormatStr
189syntax match muttrcVarEqualsComposeFmt contained skipwhite "=" nextgroup=muttrcComposeFormatStr
190syntax match muttrcVarEqualsFolderFmt contained skipwhite "=" nextgroup=muttrcFolderFormatStr
191syntax match muttrcVarEqualsGrpIdxFmt contained skipwhite "=" nextgroup=muttrcGroupIndexFormatStr
192syntax match muttrcVarEqualsIdxFmt contained skipwhite "=" nextgroup=muttrcIndexFormatStr
193syntax match muttrcVarEqualsMixFmt contained skipwhite "=" nextgroup=muttrcMixFormatStr
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100194syntax match muttrcVarEqualsPatternFmt contained skipwhite "=" nextgroup=muttrcPatternFormatStr
Bram Moolenaar7dda86f2018-04-20 22:36:41 +0200195syntax match muttrcVarEqualsPGPCmdFmt contained skipwhite "=" nextgroup=muttrcPGPCmdFormatStr
196syntax match muttrcVarEqualsPGPFmt contained skipwhite "=" nextgroup=muttrcPGPFormatStr
Bram Moolenaar7dda86f2018-04-20 22:36:41 +0200197syntax match muttrcVarEqualsQueryFmt contained skipwhite "=" nextgroup=muttrcQueryFormatStr
198syntax match muttrcVarEqualsSdbFmt contained skipwhite "=" nextgroup=muttrcSidebarFormatStr
199syntax match muttrcVarEqualsSmimeFmt contained skipwhite "=" nextgroup=muttrcSmimeFormatStr
200syntax match muttrcVarEqualsStatusFmt contained skipwhite "=" nextgroup=muttrcStatusFormatStr
201syntax match muttrcVarEqualsStrftimeFmt contained skipwhite "=" nextgroup=muttrcStrftimeFormatStr
Bram Moolenaar01164a62017-11-02 22:58:42 +0100202
Bram Moolenaare46a4402020-06-30 20:38:27 +0200203syntax match muttrcVPrefix contained /[?&]/ nextgroup=muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
Bram Moolenaar01164a62017-11-02 22:58:42 +0100204
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100205" CHECKED 2022-04-08
206" List of the different screens in NeoMutt (see MenuNames in menu/type.c)
207syntax keyword muttrcMenu contained alias attach autocrypt browser compose editor generic index key_select_pgp key_select_smime mix pager pgp postpone query smime
Bram Moolenaar01164a62017-11-02 22:58:42 +0100208syntax match muttrcMenuList "\S\+" contained contains=muttrcMenu
209syntax match muttrcMenuCommas /,/ contained
210
Bram Moolenaar01164a62017-11-02 22:58:42 +0100211syntax region muttrcSpamPattern contained skipwhite keepend start=+'+ skip=+\\'+ end=+'+ contains=muttrcPattern nextgroup=muttrcString,muttrcStringNL
212syntax region muttrcSpamPattern contained skipwhite keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcPattern nextgroup=muttrcString,muttrcStringNL
213
214syntax region muttrcNoSpamPattern contained skipwhite keepend start=+'+ skip=+\\'+ end=+'+ contains=muttrcPattern
215syntax region muttrcNoSpamPattern contained skipwhite keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcPattern
216
217syntax match muttrcAttachmentsMimeType contained "[*a-z0-9_-]\+/[*a-z0-9._-]\+\s*" skipwhite nextgroup=muttrcAttachmentsMimeType
218syntax match muttrcAttachmentsFlag contained "[+-]\%([AI]\|inline\|attachment\)\s\+" skipwhite nextgroup=muttrcAttachmentsMimeType
219syntax match muttrcAttachmentsLine "^\s*\%(un\)\?attachments\s\+" skipwhite nextgroup=muttrcAttachmentsFlag
220
221syntax match muttrcUnHighlightSpace contained "\%(\s\+\|\\$\)"
222
223syntax keyword muttrcAsterisk contained *
Bram Moolenaar403f3eb2019-11-20 22:31:13 +0100224
Bram Moolenaar01164a62017-11-02 22:58:42 +0100225syntax keyword muttrcListsKeyword lists skipwhite nextgroup=muttrcGroupDef,muttrcComment
226syntax keyword muttrcListsKeyword unlists skipwhite nextgroup=muttrcAsterisk,muttrcComment
227
Bram Moolenaar403f3eb2019-11-20 22:31:13 +0100228syntax keyword muttrcSubscribeKeyword subscribe skipwhite nextgroup=muttrcGroupDef,muttrcComment
229syntax keyword muttrcSubscribeKeyword unsubscribe skipwhite nextgroup=muttrcAsterisk,muttrcComment
Bram Moolenaar01164a62017-11-02 22:58:42 +0100230
231syntax keyword muttrcAlternateKeyword contained alternates unalternates
232syntax region muttrcAlternatesLine keepend start=+^\s*\%(un\)\?alternates\s+ skip=+\\$+ end=+$+ contains=muttrcAlternateKeyword,muttrcGroupDef,muttrcRXPat,muttrcUnHighlightSpace,muttrcComment
233
Bram Moolenaar403f3eb2019-11-20 22:31:13 +0100234" muttrcVariable includes a prefix because partial strings are considered valid.
Bram Moolenaar01164a62017-11-02 22:58:42 +0100235syntax match muttrcVariable contained "\\\@<![a-zA-Z_-]*\$[a-zA-Z_-]\+" contains=muttrcVariableInner
236syntax match muttrcVariableInner contained "\$[a-zA-Z_-]\+"
237syntax match muttrcEscapedVariable contained "\\\$[a-zA-Z_-]\+"
238
239syntax match muttrcBadAction contained "[^<>]\+" contains=muttrcEmail
240syntax match muttrcAction contained "<[^>]\{-}>" contains=muttrcBadAction,muttrcFunction,muttrcKeyName
241
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100242" CHECKED 2022-04-08
243" First, hooks that take regular expressions:
Bram Moolenaar01164a62017-11-02 22:58:42 +0100244syntax match muttrcRXHookNot contained /!\s*/ skipwhite nextgroup=muttrcRXHookString,muttrcRXHookStringNL
245syntax match muttrcRXHooks /\<\%(account\|append\|close\|crypt\|folder\|mbox\|open\|pgp\)-hook\>/ skipwhite nextgroup=muttrcRXHookNot,muttrcRXHookString,muttrcRXHookStringNL
246
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100247" Now, hooks that take patterns
Bram Moolenaar01164a62017-11-02 22:58:42 +0100248syntax match muttrcPatHookNot contained /!\s*/ skipwhite nextgroup=muttrcPattern
Bram Moolenaare46a4402020-06-30 20:38:27 +0200249syntax match muttrcPatHooks /\<\%(charset\|iconv\|index-format\)-hook\>/ skipwhite nextgroup=muttrcPatHookNot,muttrcPattern
Bram Moolenaar01164a62017-11-02 22:58:42 +0100250syntax match muttrcPatHooks /\<\%(message\|reply\|send\|send2\|save\|fcc\|fcc-save\)-hook\>/ skipwhite nextgroup=muttrcPatHookNot,muttrcOptPattern
251
Bram Moolenaare46a4402020-06-30 20:38:27 +0200252" Global hooks that take a command
253syntax keyword muttrcHooks skipwhite shutdown-hook startup-hook timeout-hook nextgroup=muttrcCommand
254
Bram Moolenaar01164a62017-11-02 22:58:42 +0100255syntax match muttrcBindFunction contained /\S\+\>/ skipwhite contains=muttrcFunction
256syntax match muttrcBindFunctionNL contained /\s*\\$/ skipwhite skipnl nextgroup=muttrcBindFunction,muttrcBindFunctionNL
257syntax match muttrcBindKey contained /\S\+/ skipwhite contains=muttrcKey nextgroup=muttrcBindFunction,muttrcBindFunctionNL
258syntax match muttrcBindKeyNL contained /\s*\\$/ skipwhite skipnl nextgroup=muttrcBindKey,muttrcBindKeyNL
259syntax match muttrcBindMenuList contained /\S\+/ skipwhite contains=muttrcMenu,muttrcMenuCommas nextgroup=muttrcBindKey,muttrcBindKeyNL
260syntax match muttrcBindMenuListNL contained /\s*\\$/ skipwhite skipnl nextgroup=muttrcBindMenuList,muttrcBindMenuListNL
261
262syntax region muttrcMacroDescr contained keepend skipwhite start=+\s*\S+ms=e skip=+\\ + end=+ \|$+me=s
263syntax region muttrcMacroDescr contained keepend skipwhite start=+'+ms=e skip=+\\'+ end=+'+me=s
264syntax region muttrcMacroDescr contained keepend skipwhite start=+"+ms=e skip=+\\"+ end=+"+me=s
265syntax match muttrcMacroDescrNL contained /\s*\\$/ skipwhite skipnl nextgroup=muttrcMacroDescr,muttrcMacroDescrNL
266syntax region muttrcMacroBody contained skipwhite start="\S" skip='\\ \|\\$' end=' \|$' contains=muttrcEscape,muttrcSet,muttrcUnset,muttrcReset,muttrcToggle,muttrcCommand,muttrcAction nextgroup=muttrcMacroDescr,muttrcMacroDescrNL
Bram Moolenaare46a4402020-06-30 20:38:27 +0200267syntax region muttrcMacroBody matchgroup=Type contained skipwhite start=+'+ms=e skip=+\\'+ end=+'\|\%(\%(\\\\\)\@<!$\)+me=s contains=muttrcEscape,muttrcSet,muttrcUnset,muttrcReset,muttrcToggle,muttrcSpam,muttrcNoSpam,muttrcCommand,muttrcAction,muttrcVariable nextgroup=muttrcMacroDescr,muttrcMacroDescrNL
268syntax region muttrcMacroBody matchgroup=Type contained skipwhite start=+"+ms=e skip=+\\"+ end=+"\|\%(\%(\\\\\)\@<!$\)+me=s contains=muttrcEscape,muttrcSet,muttrcUnset,muttrcReset,muttrcToggle,muttrcSpam,muttrcNoSpam,muttrcCommand,muttrcAction,muttrcVariable nextgroup=muttrcMacroDescr,muttrcMacroDescrNL
Bram Moolenaar01164a62017-11-02 22:58:42 +0100269syntax match muttrcMacroBodyNL contained /\s*\\$/ skipwhite skipnl nextgroup=muttrcMacroBody,muttrcMacroBodyNL
270syntax match muttrcMacroKey contained /\S\+/ skipwhite contains=muttrcKey nextgroup=muttrcMacroBody,muttrcMacroBodyNL
271syntax match muttrcMacroKeyNL contained /\s*\\$/ skipwhite skipnl nextgroup=muttrcMacroKey,muttrcMacroKeyNL
272syntax match muttrcMacroMenuList contained /\S\+/ skipwhite contains=muttrcMenu,muttrcMenuCommas nextgroup=muttrcMacroKey,muttrcMacroKeyNL
273syntax match muttrcMacroMenuListNL contained /\s*\\$/ skipwhite skipnl nextgroup=muttrcMacroMenuList,muttrcMacroMenuListNL
274
275syntax match muttrcAddrContent contained "[a-zA-Z0-9._-]\+@[a-zA-Z0-9./-]\+\s*" skipwhite contains=muttrcEmail nextgroup=muttrcAddrContent
276syntax region muttrcAddrContent contained start=+'+ end=+'\s*+ skip=+\\'+ skipwhite contains=muttrcEmail nextgroup=muttrcAddrContent
277syntax region muttrcAddrContent contained start=+"+ end=+"\s*+ skip=+\\"+ skipwhite contains=muttrcEmail nextgroup=muttrcAddrContent
Bram Moolenaare46a4402020-06-30 20:38:27 +0200278syntax match muttrcAddrDef contained "-addr\s\+" skipwhite nextgroup=muttrcAddrContent
Bram Moolenaar01164a62017-11-02 22:58:42 +0100279
280syntax match muttrcGroupFlag contained "-group"
281syntax region muttrcGroupDef contained start="-group\s\+" skip="\\$" end="\s" skipwhite keepend contains=muttrcGroupFlag,muttrcUnHighlightSpace
282
283syntax keyword muttrcGroupKeyword contained group ungroup
284syntax region muttrcGroupLine keepend start=+^\s*\%(un\)\?group\s+ skip=+\\$+ end=+$+ contains=muttrcGroupKeyword,muttrcGroupDef,muttrcAddrDef,muttrcRXDef,muttrcUnHighlightSpace,muttrcComment
285
286syntax match muttrcAliasGroupName contained /\w\+/ skipwhite nextgroup=muttrcAliasGroupDef,muttrcAliasKey,muttrcAliasNL
287syntax match muttrcAliasGroupDefNL contained /\s*\\$/ skipwhite skipnl nextgroup=muttrcAliasGroupName,muttrcAliasGroupDefNL
288syntax match muttrcAliasGroupDef contained /\s*-group/ skipwhite nextgroup=muttrcAliasGroupName,muttrcAliasGroupDefNL contains=muttrcGroupFlag
289syntax match muttrcAliasComma contained /,/ skipwhite nextgroup=muttrcAliasEmail,muttrcAliasEncEmail,muttrcAliasNameNoParens,muttrcAliasENNL
290syntax match muttrcAliasEmail contained /\S\+@\S\+/ contains=muttrcEmail nextgroup=muttrcAliasName,muttrcAliasNameNL skipwhite
291syntax match muttrcAliasEncEmail contained /<[^>]\+>/ contains=muttrcEmail nextgroup=muttrcAliasComma
292syntax match muttrcAliasEncEmailNL contained /\s*\\$/ skipwhite skipnl nextgroup=muttrcAliasEncEmail,muttrcAliasEncEmailNL
293syntax match muttrcAliasNameNoParens contained /[^<(@]\+\s\+/ nextgroup=muttrcAliasEncEmail,muttrcAliasEncEmailNL
294syntax region muttrcAliasName contained matchgroup=Type start=/(/ end=/)/ skipwhite
295syntax match muttrcAliasNameNL contained /\s*\\$/ skipwhite skipnl nextgroup=muttrcAliasName,muttrcAliasNameNL
296syntax match muttrcAliasENNL contained /\s*\\$/ skipwhite skipnl nextgroup=muttrcAliasEmail,muttrcAliasEncEmail,muttrcAliasNameNoParens,muttrcAliasENNL
297syntax match muttrcAliasKey contained /\s*[^- \t]\S\+/ skipwhite nextgroup=muttrcAliasEmail,muttrcAliasEncEmail,muttrcAliasNameNoParens,muttrcAliasENNL
298syntax match muttrcAliasNL contained /\s*\\$/ skipwhite skipnl nextgroup=muttrcAliasGroupDef,muttrcAliasKey,muttrcAliasNL
299
300syntax match muttrcUnAliasKey contained "\s*\w\+\s*" skipwhite nextgroup=muttrcUnAliasKey,muttrcUnAliasNL
301syntax match muttrcUnAliasNL contained /\s*\\$/ skipwhite skipnl nextgroup=muttrcUnAliasKey,muttrcUnAliasNL
302
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100303" CHECKED 2022-04-08
304" List of letters in Flags in pattern/flags.c
Bram Moolenaare46a4402020-06-30 20:38:27 +0200305" Parameter: none
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100306syntax match muttrcSimplePat contained "!\?\^\?[~][ADEFGgklNOPpQRSTUuVv#$=]"
Bram Moolenaare46a4402020-06-30 20:38:27 +0200307" Parameter: range
Bram Moolenaar01164a62017-11-02 22:58:42 +0100308syntax match muttrcSimplePat contained "!\?\^\?[~][mnXz]\s*\%([<>-][0-9]\+[kM]\?\|[0-9]\+[kM]\?[-]\%([0-9]\+[kM]\?\)\?\)"
Bram Moolenaare46a4402020-06-30 20:38:27 +0200309" Parameter: date
Bram Moolenaar01164a62017-11-02 22:58:42 +0100310syntax match muttrcSimplePat contained "!\?\^\?[~][dr]\s*\%(\%(-\?[0-9]\{1,2}\%(/[0-9]\{1,2}\%(/[0-9]\{2}\%([0-9]\{2}\)\?\)\?\)\?\%([+*-][0-9]\+[ymwd]\)*\)\|\%(\%([0-9]\{1,2}\%(/[0-9]\{1,2}\%(/[0-9]\{2}\%([0-9]\{2}\)\?\)\?\)\?\%([+*-][0-9]\+[ymwd]\)*\)-\%([0-9]\{1,2}\%(/[0-9]\{1,2}\%(/[0-9]\{2}\%([0-9]\{2}\)\?\)\?\)\?\%([+*-][0-9]\+[ymwd]\)\?\)\?\)\|\%([<>=][0-9]\+[ymwd]\)\|\%(`[^`]\+`\)\|\%(\$[a-zA-Z0-9_-]\+\)\)" contains=muttrcShellString,muttrcVariable
Bram Moolenaare46a4402020-06-30 20:38:27 +0200311" Parameter: regex
312syntax match muttrcSimplePat contained "!\?\^\?[~][BbCcefHhIiLMstwxYy]\s*" nextgroup=muttrcSimplePatRXContainer
313" Parameter: pattern
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100314syntax match muttrcSimplePat contained "!\?\^\?[%][BbCcefHhiLstxy]\s*" nextgroup=muttrcSimplePatString
Bram Moolenaare46a4402020-06-30 20:38:27 +0200315" Parameter: pattern
Bram Moolenaar01164a62017-11-02 22:58:42 +0100316syntax match muttrcSimplePat contained "!\?\^\?[=][bcCefhHiLstxy]\s*" nextgroup=muttrcSimplePatString
317syntax region muttrcSimplePat contained keepend start=+!\?\^\?[~](+ end=+)+ contains=muttrcSimplePat
Bram Moolenaare46a4402020-06-30 20:38:27 +0200318
Bram Moolenaar01164a62017-11-02 22:58:42 +0100319"syn match muttrcSimplePat contained /'[^~=%][^']*/ contains=muttrcRXString
320syntax region muttrcSimplePatString contained keepend start=+"+ end=+"+ skip=+\\"+
321syntax region muttrcSimplePatString contained keepend start=+'+ end=+'+ skip=+\\'+
Bram Moolenaare46a4402020-06-30 20:38:27 +0200322syntax region muttrcSimplePatString contained keepend start=+[^ "']+ skip=+\\ + end=+\s+re=e-1
Bram Moolenaar01164a62017-11-02 22:58:42 +0100323syntax region muttrcSimplePatRXContainer contained keepend start=+"+ end=+"+ skip=+\\"+ contains=muttrcRXString
324syntax region muttrcSimplePatRXContainer contained keepend start=+'+ end=+'+ skip=+\\'+ contains=muttrcRXString
Bram Moolenaare46a4402020-06-30 20:38:27 +0200325syntax region muttrcSimplePatRXContainer contained keepend start=+[^ "']+ skip=+\\ + end=+\s+re=e-1 contains=muttrcRXString
Bram Moolenaar01164a62017-11-02 22:58:42 +0100326syntax match muttrcSimplePatMetas contained /[(|)]/
327
328syntax match muttrcOptSimplePat contained skipwhite /[~=%!(^].*/ contains=muttrcSimplePat,muttrcSimplePatMetas
329syntax match muttrcOptSimplePat contained skipwhite /[^~=%!(^].*/ contains=muttrcRXString
330syntax region muttrcOptPattern contained matchgroup=Type keepend start=+"+ skip=+\\"+ end=+"+ contains=muttrcOptSimplePat,muttrcUnHighlightSpace nextgroup=muttrcString,muttrcStringNL
331syntax region muttrcOptPattern contained matchgroup=Type keepend skipwhite start=+'+ skip=+\\'+ end=+'+ contains=muttrcOptSimplePat,muttrcUnHighlightSpace nextgroup=muttrcString,muttrcStringNL
332syntax region muttrcOptPattern contained keepend skipwhite start=+[~](+ end=+)+ skip=+\\)+ contains=muttrcSimplePat nextgroup=muttrcString,muttrcStringNL
333syntax match muttrcOptPattern contained skipwhite /[~][A-Za-z]/ contains=muttrcSimplePat nextgroup=muttrcString,muttrcStringNL
334syntax match muttrcOptPattern contained skipwhite /[.]/ nextgroup=muttrcString,muttrcStringNL
335" Keep muttrcPattern and muttrcOptPattern synchronized
336syntax region muttrcPattern contained matchgroup=Type keepend skipwhite start=+"+ skip=+\\"+ end=+"+ contains=muttrcSimplePat,muttrcUnHighlightSpace,muttrcSimplePatMetas
337syntax region muttrcPattern contained matchgroup=Type keepend skipwhite start=+'+ skip=+\\'+ end=+'+ contains=muttrcSimplePat,muttrcUnHighlightSpace,muttrcSimplePatMetas
338syntax region muttrcPattern contained keepend skipwhite start=+[~](+ end=+)+ skip=+\\)+ contains=muttrcSimplePat
339syntax match muttrcPattern contained skipwhite /[~][A-Za-z]/ contains=muttrcSimplePat
340syntax match muttrcPattern contained skipwhite /[.]/
341syntax region muttrcPatternInner contained keepend start=+"[~=%!(^]+ms=s+1 skip=+\\"+ end=+"+me=e-1 contains=muttrcSimplePat,muttrcUnHighlightSpace,muttrcSimplePatMetas
342syntax region muttrcPatternInner contained keepend start=+'[~=%!(^]+ms=s+1 skip=+\\'+ end=+'+me=e-1 contains=muttrcSimplePat,muttrcUnHighlightSpace,muttrcSimplePatMetas
343
344" Colour definitions takes object, foreground and background arguments (regexps excluded).
345syntax match muttrcColorMatchCount contained "[0-9]\+"
346syntax match muttrcColorMatchCountNL contained skipwhite skipnl "\s*\\$" nextgroup=muttrcColorMatchCount,muttrcColorMatchCountNL
347syntax region muttrcColorRXPat contained start=+\s*'+ skip=+\\'+ end=+'\s*+ keepend skipwhite contains=muttrcRXString2 nextgroup=muttrcColorMatchCount,muttrcColorMatchCountNL
348syntax region muttrcColorRXPat contained start=+\s*"+ skip=+\\"+ end=+"\s*+ keepend skipwhite contains=muttrcRXString2 nextgroup=muttrcColorMatchCount,muttrcColorMatchCountNL
349syntax keyword muttrcColor contained black blue cyan default green magenta red white yellow
350syntax keyword muttrcColor contained brightblack brightblue brightcyan brightdefault brightgreen brightmagenta brightred brightwhite brightyellow
351syntax match muttrcColor contained "\<\%(bright\)\=color\d\{1,3}\>"
352" Now for the structure of the color line
353syntax match muttrcColorRXNL contained skipnl "\s*\\$" nextgroup=muttrcColorRXPat,muttrcColorRXNL
Bram Moolenaare46a4402020-06-30 20:38:27 +0200354syntax match muttrcColorBG contained /\s*[$]\?\w\+/ contains=muttrcColor,muttrcVariable,muttrcUnHighlightSpace nextgroup=muttrcColorRXPat,muttrcColorRXNL
Bram Moolenaar01164a62017-11-02 22:58:42 +0100355syntax match muttrcColorBGNL contained skipnl "\s*\\$" nextgroup=muttrcColorBG,muttrcColorBGNL
Bram Moolenaare46a4402020-06-30 20:38:27 +0200356syntax match muttrcColorFG contained /\s*[$]\?\w\+/ contains=muttrcColor,muttrcVariable,muttrcUnHighlightSpace nextgroup=muttrcColorBG,muttrcColorBGNL
Bram Moolenaar01164a62017-11-02 22:58:42 +0100357syntax match muttrcColorFGNL contained skipnl "\s*\\$" nextgroup=muttrcColorFG,muttrcColorFGNL
Bram Moolenaare46a4402020-06-30 20:38:27 +0200358syntax match muttrcColorContext contained /\s*[$]\?\w\+/ contains=muttrcColorField,muttrcVariable,muttrcUnHighlightSpace,muttrcColorCompose nextgroup=muttrcColorFG,muttrcColorFGNL
359syntax match muttrcColorNL contained skipnl "\s*\\$" nextgroup=muttrcColorContext,muttrcColorNL,muttrcColorCompose
Bram Moolenaar01164a62017-11-02 22:58:42 +0100360syntax match muttrcColorKeyword contained /^\s*color\s\+/ nextgroup=muttrcColorContext,muttrcColorNL,muttrcColorCompose
361" And now color's brother:
362syntax region muttrcUnColorPatterns contained skipwhite start=+\s*'+ end=+'+ skip=+\\'+ contains=muttrcPattern nextgroup=muttrcUnColorPatterns,muttrcUnColorPatNL
363syntax region muttrcUnColorPatterns contained skipwhite start=+\s*"+ end=+"+ skip=+\\"+ contains=muttrcPattern nextgroup=muttrcUnColorPatterns,muttrcUnColorPatNL
364syntax match muttrcUnColorPatterns contained skipwhite /\s*[^'"\s]\S\*/ contains=muttrcPattern nextgroup=muttrcUnColorPatterns,muttrcUnColorPatNL
365syntax match muttrcUnColorPatNL contained skipwhite skipnl /\s*\\$/ nextgroup=muttrcUnColorPatterns,muttrcUnColorPatNL
366syntax match muttrcUnColorAll contained skipwhite /[*]/
367syntax match muttrcUnColorAPNL contained skipwhite skipnl /\s*\\$/ nextgroup=muttrcUnColorPatterns,muttrcUnColorAll,muttrcUnColorAPNL
368syntax match muttrcUnColorIndex contained skipwhite /\s*index\s\+/ nextgroup=muttrcUnColorPatterns,muttrcUnColorAll,muttrcUnColorAPNL
369syntax match muttrcUnColorIndexNL contained skipwhite skipnl /\s*\\$/ nextgroup=muttrcUnColorIndex,muttrcUnColorIndexNL
370syntax match muttrcUnColorKeyword contained skipwhite /^\s*uncolor\s\+/ nextgroup=muttrcUnColorIndex,muttrcUnColorIndexNL
371syntax region muttrcUnColorLine keepend start=+^\s*uncolor\s+ skip=+\\$+ end=+$+ contains=muttrcUnColorKeyword,muttrcComment,muttrcUnHighlightSpace
372
373syntax keyword muttrcMonoAttrib contained bold none normal reverse standout underline
374syntax keyword muttrcMono contained mono skipwhite nextgroup=muttrcColorField,muttrcColorCompose
375syntax match muttrcMonoLine "^\s*mono\s\+\S\+" skipwhite nextgroup=muttrcMonoAttrib contains=muttrcMono
376
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100377" CHECKED 2022-04-08
378" List of fields in ColorFields in color/commmand.c
Bram Moolenaar7dda86f2018-04-20 22:36:41 +0200379syntax keyword muttrcColorField skipwhite contained
Bram Moolenaare46a4402020-06-30 20:38:27 +0200380 \ attachment attach_headers body bold error hdrdefault header index index_author
381 \ index_collapsed index_date index_flags index_label index_number index_size index_subject
382 \ index_tag index_tags indicator markers message normal options progress prompt quoted
383 \ search sidebar_divider sidebar_flagged sidebar_highlight sidebar_indicator sidebar_new
384 \ sidebar_ordinary sidebar_spoolfile sidebar_unread signature status tilde tree underline
385 \ warning nextgroup=muttrcColor
386
Bram Moolenaar01164a62017-11-02 22:58:42 +0100387syntax match muttrcColorField contained "\<quoted\d\=\>"
388
389syntax match muttrcColorCompose skipwhite contained /\s*compose\s*/ nextgroup=muttrcColorComposeField
Bram Moolenaar7dda86f2018-04-20 22:36:41 +0200390
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100391" CHECKED 2022-04-08
392" List of fields in ComposeColorFields in color/command.c
Bram Moolenaar01164a62017-11-02 22:58:42 +0100393syntax keyword muttrcColorComposeField skipwhite contained
Bram Moolenaare46a4402020-06-30 20:38:27 +0200394 \ header security_both security_encrypt security_none security_sign
395 \ nextgroup=muttrcColorFG,muttrcColorFGNL
Bram Moolenaar01164a62017-11-02 22:58:42 +0100396syntax region muttrcColorLine keepend start=/^\s*color\s\+/ skip=+\\$+ end=+$+ contains=muttrcColorKeyword,muttrcComment,muttrcUnHighlightSpace
397
Bram Moolenaar7dda86f2018-04-20 22:36:41 +0200398function! s:boolQuadGen(type, vars, deprecated)
Bram Moolenaar01164a62017-11-02 22:58:42 +0100399 let l:novars = copy(a:vars)
400 call map(l:novars, '"no" . v:val')
401 let l:invvars = copy(a:vars)
402 call map(l:invvars, '"inv" . v:val')
403
404 let l:orig_type = copy(a:type)
405 if a:deprecated
406 let l:type = 'Deprecated' . a:type
Bram Moolenaare46a4402020-06-30 20:38:27 +0200407 exec 'syntax keyword muttrcVar' . l:type . ' ' . join(a:vars)
408 exec 'syntax keyword muttrcVar' . l:type . ' ' . join(l:novars)
409 exec 'syntax keyword muttrcVar' . l:type . ' ' . join(l:invvars)
Bram Moolenaar01164a62017-11-02 22:58:42 +0100410 else
411 let l:type = a:type
Bram Moolenaare46a4402020-06-30 20:38:27 +0200412 exec 'syntax keyword muttrcVar' . l:type . ' skipwhite contained ' . join(a:vars) . ' nextgroup=muttrcSet' . l:orig_type . 'Assignment,muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr'
413 exec 'syntax keyword muttrcVar' . l:type . ' skipwhite contained ' . join(l:novars) . ' nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr'
414 exec 'syntax keyword muttrcVar' . l:type . ' skipwhite contained ' . join(l:invvars) . ' nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr'
Bram Moolenaar01164a62017-11-02 22:58:42 +0100415 endif
416
Bram Moolenaar01164a62017-11-02 22:58:42 +0100417endfunction
418
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100419" CHECKED 2022-04-08
Bram Moolenaare46a4402020-06-30 20:38:27 +0200420" List of DT_BOOL in MuttVars in mutt_config.c
Bram Moolenaar01164a62017-11-02 22:58:42 +0100421call s:boolQuadGen('Bool', [
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100422 \ 'abort_backspace', 'allow_8bit', 'allow_ansi', 'arrow_cursor', 'ascii_chars', 'ask_bcc',
423 \ 'ask_cc', 'ask_follow_up', 'ask_x_comment_to', 'attach_save_without_prompting',
424 \ 'attach_split', 'autocrypt', 'autocrypt_reply', 'auto_edit', 'auto_subscribe', 'auto_tag',
Bram Moolenaare46a4402020-06-30 20:38:27 +0200425 \ 'beep', 'beep_new', 'bounce_delivered', 'braille_friendly',
426 \ 'browser_abbreviate_mailboxes', 'change_folder_next', 'check_mbox_size', 'check_new',
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100427 \ 'collapse_all', 'collapse_flagged', 'collapse_unread', 'compose_show_user_headers',
428 \ 'confirm_append', 'confirm_create', 'copy_decode_weed', 'count_alternatives',
429 \ 'crypt_auto_encrypt', 'crypt_auto_pgp', 'crypt_auto_sign', 'crypt_auto_smime',
430 \ 'crypt_confirm_hook', 'crypt_opportunistic_encrypt',
Bram Moolenaare46a4402020-06-30 20:38:27 +0200431 \ 'crypt_opportunistic_encrypt_strong_keys', 'crypt_protected_headers_read',
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100432 \ 'crypt_protected_headers_save', 'crypt_protected_headers_write', 'crypt_reply_encrypt',
433 \ 'crypt_reply_sign', 'crypt_reply_sign_encrypted', 'crypt_timestamp', 'crypt_use_gpgme',
Bram Moolenaare46a4402020-06-30 20:38:27 +0200434 \ 'crypt_use_pka', 'delete_untag', 'digest_collapse', 'duplicate_threads', 'edit_headers',
435 \ 'encode_from', 'fast_reply', 'fcc_before_send', 'fcc_clear', 'flag_safe', 'followup_to',
436 \ 'force_name', 'forward_decode', 'forward_decrypt', 'forward_quote', 'forward_references',
437 \ 'hdrs', 'header', 'header_color_partial', 'help', 'hidden_host', 'hide_limited',
438 \ 'hide_missing', 'hide_thread_subject', 'hide_top_limited', 'hide_top_missing',
439 \ 'history_remove_dups', 'honor_disposition', 'idn_decode', 'idn_encode',
440 \ 'ignore_list_reply_to', 'imap_check_subscribed', 'imap_condstore', 'imap_deflate',
441 \ 'imap_idle', 'imap_list_subscribed', 'imap_passive', 'imap_peek', 'imap_qresync',
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100442 \ 'imap_rfc5161', 'imap_server_noise', 'implicit_autoview', 'include_encrypted',
443 \ 'include_only_first', 'keep_flagged', 'local_date_header', 'mailcap_sanitize',
444 \ 'maildir_check_cur', 'maildir_header_cache_verify', 'maildir_trash', 'mail_check_recent',
445 \ 'mail_check_stats', 'markers', 'mark_old', 'menu_move_off', 'menu_scroll',
446 \ 'message_cache_clean', 'meta_key', 'me_too', 'mh_purge', 'mime_forward_decode',
447 \ 'mime_type_query_first', 'narrow_tree', 'nm_query_window_enable', 'nm_record',
448 \ 'nntp_listgroup', 'nntp_load_description', 'pager_stop', 'pgp_auto_decode',
449 \ 'pgp_auto_inline', 'pgp_check_exit', 'pgp_check_gpg_decrypt_status_fd',
450 \ 'pgp_ignore_subkeys', 'pgp_long_ids', 'pgp_reply_inline', 'pgp_retainable_sigs',
Bram Moolenaare46a4402020-06-30 20:38:27 +0200451 \ 'pgp_self_encrypt', 'pgp_show_unusable', 'pgp_strict_enc', 'pgp_use_gpg_agent',
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100452 \ 'pipe_decode', 'pipe_decode_weed', 'pipe_split', 'pop_auth_try_all', 'pop_last',
453 \ 'postpone_encrypt', 'print_decode', 'print_decode_weed', 'print_split', 'prompt_after',
454 \ 'read_only', 'reflow_space_quotes', 'reflow_text', 'reply_self', 'reply_with_xorig',
455 \ 'resolve', 'resume_draft_files', 'resume_edited_draft_files', 'reverse_alias',
456 \ 'reverse_name', 'reverse_real_name', 'rfc2047_parameters', 'save_address', 'save_empty',
457 \ 'save_name', 'save_unsubscribed', 'score', 'show_new_news', 'show_only_unread',
458 \ 'sidebar_folder_indent', 'sidebar_new_mail_only', 'sidebar_next_new_wrap',
459 \ 'sidebar_non_empty_mailbox_only', 'sidebar_on_right', 'sidebar_short_path',
460 \ 'sidebar_visible', 'sig_dashes', 'sig_on_top', 'size_show_bytes', 'size_show_fractions',
461 \ 'size_show_mb', 'size_units_on_left', 'smart_wrap', 'smime_ask_cert_label',
462 \ 'smime_decrypt_use_default_key', 'smime_is_default', 'smime_self_encrypt', 'sort_re',
463 \ 'ssl_force_tls', 'ssl_use_sslv2', 'ssl_use_sslv3', 'ssl_use_system_certs',
464 \ 'ssl_use_tlsv1', 'ssl_use_tlsv1_1', 'ssl_use_tlsv1_2', 'ssl_use_tlsv1_3',
Bram Moolenaare46a4402020-06-30 20:38:27 +0200465 \ 'ssl_verify_dates', 'ssl_verify_host', 'ssl_verify_partial_chains', 'status_on_top',
466 \ 'strict_threads', 'suspend', 'text_flowed', 'thorough_search', 'thread_received', 'tilde',
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100467 \ 'ts_enabled', 'tunnel_is_secure', 'uncollapse_jump', 'uncollapse_new', 'user_agent',
468 \ 'use_8bit_mime', 'use_domain', 'use_envelope_from', 'use_from', 'use_ipv6',
469 \ 'virtual_spool_file', 'wait_key', 'weed', 'wrap_search', 'write_bcc', 'x_comment_to'
Bram Moolenaare46a4402020-06-30 20:38:27 +0200470 \ ], 0)
Bram Moolenaar01164a62017-11-02 22:58:42 +0100471
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100472" CHECKED 2022-04-08
Bram Moolenaar01164a62017-11-02 22:58:42 +0100473" Deprecated Bools
Bram Moolenaare46a4402020-06-30 20:38:27 +0200474" List of DT_SYNONYM or DT_DEPRECATED Bools in MuttVars in mutt_config.c
Bram Moolenaar01164a62017-11-02 22:58:42 +0100475call s:boolQuadGen('Bool', [
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100476 \ 'askbcc', 'askcc', 'autoedit', 'confirmappend', 'confirmcreate', 'crypt_autoencrypt',
477 \ 'crypt_autopgp', 'crypt_autosign', 'crypt_autosmime', 'crypt_confirmhook',
478 \ 'crypt_replyencrypt', 'crypt_replysign', 'crypt_replysignencrypted', 'edit_hdrs',
479 \ 'envelope_from', 'forw_decode', 'forw_decrypt', 'forw_quote', 'header_cache_compress',
480 \ 'ignore_linear_white_space', 'imap_servernoise', 'include_onlyfirst', 'metoo',
481 \ 'mime_subject', 'pgp_autoencrypt', 'pgp_autoinline', 'pgp_autosign',
482 \ 'pgp_auto_traditional', 'pgp_create_traditional', 'pgp_replyencrypt', 'pgp_replyinline',
483 \ 'pgp_replysign', 'pgp_replysignencrypted', 'reverse_realname', 'ssl_usesystemcerts',
484 \ 'use_8bitmime', 'virtual_spoolfile', 'xterm_set_titles'
Bram Moolenaare46a4402020-06-30 20:38:27 +0200485 \ ], 1)
Bram Moolenaar01164a62017-11-02 22:58:42 +0100486
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100487" CHECKED 2022-04-08
Bram Moolenaare46a4402020-06-30 20:38:27 +0200488" List of DT_QUAD in MuttVars in mutt_config.c
Bram Moolenaar01164a62017-11-02 22:58:42 +0100489call s:boolQuadGen('Quad', [
Bram Moolenaare46a4402020-06-30 20:38:27 +0200490 \ 'abort_noattach', 'abort_nosubject', 'abort_unmodified', 'bounce', 'catchup_newsgroup',
491 \ 'copy', 'crypt_verify_sig', 'delete', 'fcc_attach', 'followup_to_poster',
492 \ 'forward_attachments', 'forward_edit', 'honor_followup_to', 'include', 'mime_forward',
493 \ 'mime_forward_rest', 'move', 'pgp_mime_auto', 'pop_delete', 'pop_reconnect', 'postpone',
494 \ 'post_moderated', 'print', 'quit', 'recall', 'reply_to', 'ssl_starttls',
495 \ ], 0)
Bram Moolenaar01164a62017-11-02 22:58:42 +0100496
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100497" CHECKED 2022-04-08
Bram Moolenaar01164a62017-11-02 22:58:42 +0100498" Deprecated Quads
Bram Moolenaare46a4402020-06-30 20:38:27 +0200499" List of DT_SYNONYM or DT_DEPRECATED Quads in MuttVars in mutt_config.c
Bram Moolenaar01164a62017-11-02 22:58:42 +0100500call s:boolQuadGen('Quad', [
Bram Moolenaare46a4402020-06-30 20:38:27 +0200501 \ 'mime_fwd', 'pgp_encrypt_self', 'pgp_verify_sig', 'smime_encrypt_self'
502 \ ], 1)
Bram Moolenaar01164a62017-11-02 22:58:42 +0100503
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100504" CHECKED 2022-04-08
Bram Moolenaare46a4402020-06-30 20:38:27 +0200505" List of DT_NUMBER or DT_LONG in MuttVars in mutt_config.c
Bram Moolenaar01164a62017-11-02 22:58:42 +0100506syntax keyword muttrcVarNum skipwhite contained
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100507 \ connect_timeout debug_level header_cache_compress_level history imap_fetch_chunk_size
508 \ imap_keepalive imap_pipeline_depth imap_poll_timeout mail_check mail_check_stats_interval
509 \ menu_context net_inc nm_db_limit nm_open_timeout nm_query_window_current_position
510 \ nm_query_window_duration nntp_context nntp_poll pager_context pager_index_lines
511 \ pager_read_delay pager_skip_quoted_context pgp_timeout pop_check_interval read_inc
512 \ reflow_wrap save_history score_threshold_delete score_threshold_flag score_threshold_read
513 \ search_context sendmail_wait sidebar_component_depth sidebar_width sleep_time
514 \ smime_timeout ssl_min_dh_prime_bits timeout time_inc toggle_quoted_show_levels wrap
515 \ wrap_headers write_inc
Bram Moolenaare46a4402020-06-30 20:38:27 +0200516 \ nextgroup=muttrcSetNumAssignment,muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100517" CHECKED 2022-04-08
518" Deprecated Numbers
Bram Moolenaar7dda86f2018-04-20 22:36:41 +0200519syntax keyword muttrcVarDeprecatedNum contained skipwhite
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100520 \ header_cache_pagesize pop_checkinterval skip_quoted_offset
Bram Moolenaar01164a62017-11-02 22:58:42 +0100521
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100522" CHECKED 2022-04-08
Bram Moolenaare46a4402020-06-30 20:38:27 +0200523" List of DT_STRING in MuttVars in mutt_config.c
Bram Moolenaar01164a62017-11-02 22:58:42 +0100524" Special cases first, and all the rest at the end
Bram Moolenaar01164a62017-11-02 22:58:42 +0100525" Formats themselves must be updated in their respective groups
526" See s:escapesConditionals
Bram Moolenaare46a4402020-06-30 20:38:27 +0200527syntax match muttrcVarStr contained skipwhite 'my_[a-zA-Z0-9_]\+' nextgroup=muttrcSetStrAssignment,muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
Bram Moolenaar01164a62017-11-02 22:58:42 +0100528syntax keyword muttrcVarStr contained skipwhite alias_format nextgroup=muttrcVarEqualsAliasFmt
529syntax keyword muttrcVarStr contained skipwhite attach_format nextgroup=muttrcVarEqualsAttachFmt
530syntax keyword muttrcVarStr contained skipwhite compose_format nextgroup=muttrcVarEqualsComposeFmt
531syntax keyword muttrcVarStr contained skipwhite folder_format vfolder_format nextgroup=muttrcVarEqualsFolderFmt
Bram Moolenaare46a4402020-06-30 20:38:27 +0200532syntax keyword muttrcVarStr contained skipwhite attribution forward_format index_format message_format pager_format nextgroup=muttrcVarEqualsIdxFmt
Bram Moolenaar01164a62017-11-02 22:58:42 +0100533syntax keyword muttrcVarStr contained skipwhite mix_entry_format nextgroup=muttrcVarEqualsMixFmt
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100534syntax keyword muttrcVarStr contained skipwhite pattern_format nextgroup=muttrcVarEqualsPatternFmt
Bram Moolenaar7dda86f2018-04-20 22:36:41 +0200535syntax keyword muttrcVarStr contained skipwhite
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100536 \ pgp_clear_sign_command pgp_decode_command pgp_decrypt_command pgp_encrypt_only_command
537 \ pgp_encrypt_sign_command pgp_export_command pgp_get_keys_command pgp_import_command
538 \ pgp_list_pubring_command pgp_list_secring_command pgp_sign_command pgp_verify_command
539 \ pgp_verify_key_command
Bram Moolenaare46a4402020-06-30 20:38:27 +0200540 \ nextgroup=muttrcVarEqualsPGPCmdFmt
Bram Moolenaar01164a62017-11-02 22:58:42 +0100541syntax keyword muttrcVarStr contained skipwhite pgp_entry_format nextgroup=muttrcVarEqualsPGPFmt
Bram Moolenaar01164a62017-11-02 22:58:42 +0100542syntax keyword muttrcVarStr contained skipwhite query_format nextgroup=muttrcVarEqualsQueryFmt
543syntax keyword muttrcVarStr contained skipwhite
Bram Moolenaare46a4402020-06-30 20:38:27 +0200544 \ smime_decrypt_command smime_encrypt_command smime_get_cert_command
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100545 \ smime_get_cert_email_command smime_get_signer_cert_command smime_import_cert_command
546 \ smime_pk7out_command smime_sign_command smime_verify_command smime_verify_opaque_command
Bram Moolenaare46a4402020-06-30 20:38:27 +0200547 \ nextgroup=muttrcVarEqualsSmimeFmt
548syntax keyword muttrcVarStr contained skipwhite status_format ts_icon_format ts_status_format nextgroup=muttrcVarEqualsStatusFmt
Bram Moolenaar01164a62017-11-02 22:58:42 +0100549syntax keyword muttrcVarStr contained skipwhite date_format nextgroup=muttrcVarEqualsStrftimeFmt
Bram Moolenaar7dda86f2018-04-20 22:36:41 +0200550syntax keyword muttrcVarStr contained skipwhite group_index_format nextgroup=muttrcVarEqualsGrpIdxFmt
Bram Moolenaar01164a62017-11-02 22:58:42 +0100551syntax keyword muttrcVarStr contained skipwhite sidebar_format nextgroup=muttrcVarEqualsSdbFmt
552syntax keyword muttrcVarStr contained skipwhite
Bram Moolenaare46a4402020-06-30 20:38:27 +0200553 \ abort_key arrow_string assumed_charset attach_charset attach_sep attribution_locale
554 \ autocrypt_acct_format charset config_charset content_type crypt_protected_headers_subject
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100555 \ default_hook dsn_notify dsn_return empty_subject forward_attribution_intro
556 \ forward_attribution_trailer greeting header_cache_backend header_cache_compress_method
557 \ hidden_tags hostname imap_authenticators imap_delim_chars imap_headers imap_login
558 \ imap_pass imap_user indent_string mailcap_path mark_macro_prefix mh_seq_flagged
559 \ mh_seq_replied mh_seq_unseen newsgroups_charset news_server nm_default_url nm_exclude_tags
560 \ nm_flagged_tag nm_query_type nm_query_window_current_search nm_query_window_or_terms
561 \ nm_query_window_timebase nm_record_tags nm_replied_tag nm_unread_tag nntp_authenticators
562 \ nntp_pass nntp_user pgp_default_key pgp_sign_as pipe_sep pop_authenticators pop_host
563 \ pop_pass pop_user postpone_encrypt_as post_indent_string preconnect preferred_languages
564 \ real_name send_charset show_multipart_alternative sidebar_delim_chars sidebar_divider_char
565 \ sidebar_indent_string simple_search smime_default_key smime_encrypt_with smime_sign_as
566 \ smime_sign_digest_alg smtp_authenticators smtp_pass smtp_url smtp_user spam_separator
567 \ ssl_ciphers
Bram Moolenaare46a4402020-06-30 20:38:27 +0200568 \ nextgroup=muttrcSetStrAssignment,muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
569
Bram Moolenaar01164a62017-11-02 22:58:42 +0100570" Deprecated strings
Bram Moolenaare46a4402020-06-30 20:38:27 +0200571syntax keyword muttrcVarDeprecatedStr
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100572 \ abort_noattach_regexp attach_keyword escape forw_format hdr_format indent_str msg_format
573 \ nm_default_uri pgp_clearsign_command pgp_getkeys_command pgp_self_encrypt_as
574 \ post_indent_str print_cmd quote_regexp realname reply_regexp smime_self_encrypt_as
575 \ spoolfile visual xterm_icon xterm_title
Bram Moolenaar7dda86f2018-04-20 22:36:41 +0200576
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100577" CHECKED 2022-04-08
Bram Moolenaar01164a62017-11-02 22:58:42 +0100578" List of DT_ADDRESS
Bram Moolenaare46a4402020-06-30 20:38:27 +0200579syntax keyword muttrcVarStr contained skipwhite envelope_from_address from nextgroup=muttrcSetStrAssignment,muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
Bram Moolenaar403f3eb2019-11-20 22:31:13 +0100580" List of DT_ENUM
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100581syntax keyword muttrcVarStr contained skipwhite mbox_type use_threads nextgroup=muttrcSetStrAssignment,muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
Bram Moolenaar01164a62017-11-02 22:58:42 +0100582" List of DT_MBTABLE
Bram Moolenaare46a4402020-06-30 20:38:27 +0200583syntax keyword muttrcVarStr contained skipwhite crypt_chars flag_chars from_chars status_chars to_chars nextgroup=muttrcSetStrAssignment,muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
Bram Moolenaar7dda86f2018-04-20 22:36:41 +0200584
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100585" CHECKED 2022-04-08
586" List of DT_PATH or DT_MAILBOX
Bram Moolenaar01164a62017-11-02 22:58:42 +0100587syntax keyword muttrcVarStr contained skipwhite
Bram Moolenaare46a4402020-06-30 20:38:27 +0200588 \ alias_file attach_save_dir autocrypt_dir certificate_file debug_file
589 \ entropy_file folder header_cache history_file mbox message_cachedir newsrc
590 \ news_cache_dir postponed record signature smime_ca_location
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100591 \ smime_certificates smime_keys spool_file ssl_ca_certificates_file ssl_client_cert
592 \ tmpdir trash
Bram Moolenaare46a4402020-06-30 20:38:27 +0200593 \ nextgroup=muttrcSetStrAssignment,muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
Bram Moolenaar403f3eb2019-11-20 22:31:13 +0100594" List of DT_COMMAND (excluding pgp_*_command and smime_*_command)
595syntax keyword muttrcVarStr contained skipwhite
Bram Moolenaare46a4402020-06-30 20:38:27 +0200596 \ display_filter editor inews ispell mixmaster new_mail_command pager
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100597 \ print_command query_command sendmail shell external_search_command
Bram Moolenaare46a4402020-06-30 20:38:27 +0200598 \ imap_oauth_refresh_command pop_oauth_refresh_command
599 \ mime_type_query_command smtp_oauth_refresh_command tunnel
600 \ nextgroup=muttrcSetStrAssignment,muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
Bram Moolenaar7dda86f2018-04-20 22:36:41 +0200601
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100602" CHECKED 2022-04-08
Bram Moolenaar01164a62017-11-02 22:58:42 +0100603" List of DT_REGEX
604syntax keyword muttrcVarStr contained skipwhite
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100605 \ abort_noattach_regex gecos_mask mask pgp_decryption_okay pgp_good_sign quote_regex
606 \ reply_regex smileys
Bram Moolenaare46a4402020-06-30 20:38:27 +0200607 \ nextgroup=muttrcSetStrAssignment,muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
Bram Moolenaar01164a62017-11-02 22:58:42 +0100608" List of DT_SORT
609syntax keyword muttrcVarStr contained skipwhite
Bram Moolenaare46a4402020-06-30 20:38:27 +0200610 \ pgp_sort_keys sidebar_sort_method sort sort_alias sort_aux sort_browser
611 \ nextgroup=muttrcSetStrAssignment,muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
Bram Moolenaar01164a62017-11-02 22:58:42 +0100612
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100613" CHECKED 2022-04-08
614" List of commands in mutt_commands in mutt_commands.c
Bram Moolenaar01164a62017-11-02 22:58:42 +0100615" Remember to remove hooks, they have already been dealt with
Bram Moolenaar01164a62017-11-02 22:58:42 +0100616syntax keyword muttrcCommand skipwhite alias nextgroup=muttrcAliasGroupDef,muttrcAliasKey,muttrcAliasNL
Bram Moolenaare46a4402020-06-30 20:38:27 +0200617syntax keyword muttrcCommand skipwhite bind nextgroup=muttrcBindMenuList,muttrcBindMenuListNL
Bram Moolenaar01164a62017-11-02 22:58:42 +0100618syntax keyword muttrcCommand skipwhite exec nextgroup=muttrcFunction
Bram Moolenaare46a4402020-06-30 20:38:27 +0200619syntax keyword muttrcCommand skipwhite macro nextgroup=muttrcMacroMenuList,muttrcMacroMenuListNL
620syntax keyword muttrcCommand skipwhite nospam nextgroup=muttrcNoSpamPattern
621syntax keyword muttrcCommand skipwhite set unset reset toggle nextgroup=muttrcVPrefix,muttrcVarBool,muttrcVarQuad,muttrcVarNum,muttrcVarStr
622syntax keyword muttrcCommand skipwhite spam nextgroup=muttrcSpamPattern
623syntax keyword muttrcCommand skipwhite unalias nextgroup=muttrcUnAliasKey,muttrcUnAliasNL
624syntax keyword muttrcCommand skipwhite unhook nextgroup=muttrcHooks
Bram Moolenaar01164a62017-11-02 22:58:42 +0100625syntax keyword muttrcCommand skipwhite
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100626 \ alternative_order attachments auto_view cd echo finish hdr_order ifdef ifndef ignore lua
627 \ lua-source mailboxes mailto_allow mime_lookup my_hdr named-mailboxes push score setenv
628 \ sidebar_whitelist source subjectrx subscribe-to tag-formats tag-transforms
629 \ unalternative_order unattachments unauto_view unbind uncolor unhdr_order unignore unmacro
630 \ unmailboxes unmailto_allow unmime_lookup unmono unmy_hdr unscore unsetenv
631 \ unsidebar_whitelist unsubjectrx unsubscribe-from unvirtual-mailboxes virtual-mailboxes
Bram Moolenaar01164a62017-11-02 22:58:42 +0100632
Bram Moolenaare46a4402020-06-30 20:38:27 +0200633function! s:genFunctions(functions)
634 for f in a:functions
635 exec 'syntax match muttrcFunction contained "\<' . l:f . '\>"'
636 endfor
637endfunction
638
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100639" CHECKED 2022-04-08
Bram Moolenaare46a4402020-06-30 20:38:27 +0200640" List of functions in functions.c
641" Note: 'noop' is included but is elsewhere in the source
642call s:genFunctions(['noop',
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100643 \ 'accept', 'alias-dialog', 'append', 'attach-file', 'attach-key', 'attach-message',
644 \ 'attach-news-message', 'autocrypt-acct-menu', 'autocrypt-menu', 'backspace',
645 \ 'backward-char', 'backward-word', 'bol', 'bottom', 'bottom-page', 'bounce-message',
646 \ 'break-thread', 'buffy-cycle', 'buffy-list', 'capitalize-word', 'catchup', 'chain-next',
647 \ 'chain-prev', 'change-dir', 'change-folder', 'change-folder-readonly', 'change-newsgroup',
648 \ 'change-newsgroup-readonly', 'change-vfolder', 'check-new', 'check-stats',
Bram Moolenaare46a4402020-06-30 20:38:27 +0200649 \ 'check-traditional-pgp', 'clear-flag', 'collapse-all', 'collapse-parts',
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100650 \ 'collapse-thread', 'complete', 'complete-query', 'compose-to-sender', 'copy-file',
Bram Moolenaare46a4402020-06-30 20:38:27 +0200651 \ 'copy-message', 'create-account', 'create-alias', 'create-mailbox', 'current-bottom',
652 \ 'current-middle', 'current-top', 'decode-copy', 'decode-save', 'decrypt-copy',
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100653 \ 'decrypt-save', 'delete', 'delete-account', 'delete-char', 'delete-entry',
654 \ 'delete-mailbox', 'delete-message', 'delete-pattern', 'delete-subthread', 'delete-thread',
Bram Moolenaare46a4402020-06-30 20:38:27 +0200655 \ 'descend-directory', 'detach-file', 'display-address', 'display-filename',
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100656 \ 'display-message', 'display-toggle-weed', 'downcase-word', 'edit', 'edit-bcc', 'edit-cc',
657 \ 'edit-content-id', 'edit-description', 'edit-encoding', 'edit-fcc', 'edit-file',
658 \ 'edit-followup-to', 'edit-from', 'edit-headers', 'edit-label', 'edit-language',
659 \ 'edit-message', 'edit-mime', 'edit-newsgroups', 'edit-or-view-raw-message',
660 \ 'edit-raw-message', 'edit-reply-to', 'edit-subject', 'edit-to', 'edit-type',
661 \ 'edit-x-comment-to', 'end-cond', 'enter-command', 'enter-mask', 'entire-thread', 'eol',
662 \ 'error-history', 'exit', 'extract-keys', 'fetch-mail', 'filter-entry', 'first-entry',
663 \ 'flag-message', 'followup-message', 'forget-passphrase', 'forward-char',
664 \ 'forward-message', 'forward-to-group', 'forward-word', 'get-attachment', 'get-children',
665 \ 'get-message', 'get-parent', 'goto-folder', 'goto-parent', 'group-alternatives',
666 \ 'group-chat-reply', 'group-multilingual', 'group-related', 'group-reply', 'half-down',
667 \ 'half-up', 'help', 'history-down', 'history-search', 'history-up', 'imap-fetch-mail',
668 \ 'imap-logout-all', 'insert', 'ispell', 'jump', 'kill-eol', 'kill-eow', 'kill-line',
669 \ 'kill-word', 'last-entry', 'limit', 'limit-current-thread', 'link-threads', 'list-reply',
670 \ 'list-subscribe', 'list-unsubscribe', 'mail', 'mail-key', 'mailbox-cycle', 'mailbox-list',
671 \ 'mark-as-new', 'mark-message', 'middle-page', 'mix', 'modify-labels',
672 \ 'modify-labels-then-hide', 'modify-tags', 'modify-tags-then-hide', 'move-down', 'move-up',
673 \ 'new-mime', 'next-entry', 'next-line', 'next-new', 'next-new-then-unread', 'next-page',
674 \ 'next-subthread', 'next-thread', 'next-undeleted', 'next-unread', 'next-unread-mailbox',
675 \ 'parent-message', 'pgp-menu', 'pipe-entry', 'pipe-message', 'post-message',
676 \ 'postpone-message', 'previous-entry', 'previous-line', 'previous-new',
677 \ 'previous-new-then-unread', 'previous-page', 'previous-subthread', 'previous-thread',
678 \ 'previous-undeleted', 'previous-unread', 'print-entry', 'print-message', 'purge-message',
679 \ 'purge-thread', 'quasi-delete', 'query', 'query-append', 'quit', 'quote-char',
680 \ 'read-subthread', 'read-thread', 'recall-message', 'reconstruct-thread', 'redraw-screen',
681 \ 'refresh', 'reload-active', 'rename-attachment', 'rename-file', 'rename-mailbox', 'reply',
682 \ 'resend-message', 'root-message', 'save-entry', 'save-message', 'search', 'search-next',
683 \ 'search-opposite', 'search-reverse', 'search-toggle', 'select-entry', 'select-new',
Bram Moolenaare46a4402020-06-30 20:38:27 +0200684 \ 'send-message', 'set-flag', 'shell-escape', 'show-limit', 'show-log-messages',
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100685 \ 'show-version', 'sidebar-first', 'sidebar-last', 'sidebar-next', 'sidebar-next-new',
686 \ 'sidebar-open', 'sidebar-page-down', 'sidebar-page-up', 'sidebar-prev',
687 \ 'sidebar-prev-new', 'sidebar-toggle-virtual', 'sidebar-toggle-visible', 'skip-headers',
688 \ 'skip-quoted', 'smime-menu', 'sort', 'sort-alias', 'sort-alias-reverse', 'sort-mailbox',
689 \ 'sort-reverse', 'subscribe', 'subscribe-pattern', 'sync-mailbox', 'tag-entry',
690 \ 'tag-message', 'tag-pattern', 'tag-prefix', 'tag-prefix-cond', 'tag-subthread',
691 \ 'tag-thread', 'toggle-active', 'toggle-disposition', 'toggle-mailboxes', 'toggle-new',
692 \ 'toggle-prefer-encrypt', 'toggle-quoted', 'toggle-read', 'toggle-recode',
693 \ 'toggle-subscribed', 'toggle-unlink', 'toggle-write', 'top', 'top-page',
694 \ 'transpose-chars', 'uncatchup', 'undelete-entry', 'undelete-message', 'undelete-pattern',
695 \ 'undelete-subthread', 'undelete-thread', 'ungroup-attachment', 'unsubscribe',
696 \ 'unsubscribe-pattern', 'untag-pattern', 'upcase-word', 'update-encoding', 'verify-key',
697 \ 'vfolder-from-query', 'vfolder-from-query-readonly', 'vfolder-window-backward',
698 \ 'vfolder-window-forward', 'vfolder-window-reset', 'view-attach', 'view-attachments',
699 \ 'view-file', 'view-mailcap', 'view-name', 'view-pager', 'view-raw-message', 'view-text',
700 \ 'what-key', 'write-fcc'
Bram Moolenaare46a4402020-06-30 20:38:27 +0200701 \ ])
Bram Moolenaar01164a62017-11-02 22:58:42 +0100702
Bram Moolenaar01164a62017-11-02 22:58:42 +0100703" Define the default highlighting.
704" Only when an item doesn't have highlighting yet
705
Bram Moolenaar01164a62017-11-02 22:58:42 +0100706highlight def link muttrcSetBoolAssignment Boolean
707highlight def link muttrcSetQuadAssignment Boolean
Bram Moolenaare46a4402020-06-30 20:38:27 +0200708
709highlight def link muttrcComment Comment
710
711highlight def link muttrcAlternatesLine Error
Bram Moolenaar01164a62017-11-02 22:58:42 +0100712highlight def link muttrcBadAction Error
713highlight def link muttrcBindFunction Error
714highlight def link muttrcBindMenuList Error
Bram Moolenaar01164a62017-11-02 22:58:42 +0100715highlight def link muttrcColorBG Error
Bram Moolenaar01164a62017-11-02 22:58:42 +0100716highlight def link muttrcColorBGH Error
Bram Moolenaare46a4402020-06-30 20:38:27 +0200717highlight def link muttrcColorBGI Error
718highlight def link muttrcColorContext Error
719highlight def link muttrcColorFG Error
720highlight def link muttrcColorFGH Error
721highlight def link muttrcColorFGI Error
722highlight def link muttrcColorLine Error
Bram Moolenaar01164a62017-11-02 22:58:42 +0100723highlight def link muttrcFormatErrors Error
Bram Moolenaare46a4402020-06-30 20:38:27 +0200724highlight def link muttrcGroupLine Error
725highlight def link muttrcListsLine Error
726highlight def link muttrcPattern Error
727highlight def link muttrcSubscribeLine Error
728highlight def link muttrcUnColorLine Error
Bram Moolenaar01164a62017-11-02 22:58:42 +0100729highlight def link muttrcVarDeprecatedBool Error
730highlight def link muttrcVarDeprecatedQuad Error
731highlight def link muttrcVarDeprecatedStr Error
732
Bram Moolenaare46a4402020-06-30 20:38:27 +0200733highlight def link muttrcAliasEncEmail Identifier
734highlight def link muttrcAliasKey Identifier
735highlight def link muttrcColorCompose Identifier
736highlight def link muttrcColorComposeField Identifier
737highlight def link muttrcColorContextH Identifier
738highlight def link muttrcColorContextI Identifier
739highlight def link muttrcColorField Identifier
740highlight def link muttrcMenu Identifier
741highlight def link muttrcSimplePat Identifier
742highlight def link muttrcUnAliasKey Identifier
743highlight def link muttrcUnColorIndex Identifier
744highlight def link muttrcVarBool Identifier
745highlight def link muttrcVarNum Identifier
746highlight def link muttrcVarQuad Identifier
747highlight def link muttrcVarStr Identifier
748
749highlight def link muttrcCommand Keyword
750
751highlight def link muttrcAction Macro
752highlight def link muttrcAliasGroupName Macro
753highlight def link muttrcFunction Macro
754highlight def link muttrcGroupDef Macro
755highlight def link muttrcSimplePatString Macro
756
757highlight def link muttrcMonoAttrib muttrcColor
758
759highlight def link muttrcAlternateKeyword muttrcCommand
760highlight def link muttrcAttachmentsLine muttrcCommand
761highlight def link muttrcColorKeyword muttrcCommand
762highlight def link muttrcGroupKeyword muttrcCommand
763highlight def link muttrcListsKeyword muttrcCommand
764highlight def link muttrcMono muttrcCommand
765highlight def link muttrcPatHooks muttrcCommand
766highlight def link muttrcRXHooks muttrcCommand
767highlight def link muttrcSubscribeKeyword muttrcCommand
768highlight def link muttrcUnColorKeyword muttrcCommand
769
770highlight def link muttrcAliasFormatEscapes muttrcEscape
771highlight def link muttrcAttachFormatEscapes muttrcEscape
772highlight def link muttrcComposeFormatEscapes muttrcEscape
773highlight def link muttrcFolderFormatEscapes muttrcEscape
774highlight def link muttrcGroupIndexFormatEscapes muttrcEscape
775highlight def link muttrcIndexFormatEscapes muttrcEscape
776highlight def link muttrcMixFormatEscapes muttrcEscape
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100777highlight def link muttrcPatternFormatEscapes muttrcEscape
Bram Moolenaare46a4402020-06-30 20:38:27 +0200778highlight def link muttrcPGPCmdFormatEscapes muttrcEscape
779highlight def link muttrcPGPFormatEscapes muttrcEscape
780highlight def link muttrcPGPTimeEscapes muttrcEscape
781highlight def link muttrcQueryFormatEscapes muttrcEscape
782highlight def link muttrcShellString muttrcEscape
783highlight def link muttrcSidebarFormatEscapes muttrcEscape
784highlight def link muttrcSmimeFormatEscapes muttrcEscape
785highlight def link muttrcStatusFormatEscapes muttrcEscape
786highlight def link muttrcTimeEscapes muttrcEscape
787
788highlight def link muttrcAliasFormatConditionals muttrcFormatConditionals2
789highlight def link muttrcAttachFormatConditionals muttrcFormatConditionals2
790highlight def link muttrcComposeFormatConditionals muttrcFormatConditionals2
791highlight def link muttrcFolderFormatConditionals muttrcFormatConditionals2
792highlight def link muttrcIndexFormatConditionals muttrcFormatConditionals2
793highlight def link muttrcMixFormatConditionals muttrcFormatConditionals2
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100794highlight def link muttrcPatternFormatConditionals muttrcFormatConditionals2
Bram Moolenaare46a4402020-06-30 20:38:27 +0200795highlight def link muttrcPGPCmdFormatConditionals muttrcFormatConditionals2
796highlight def link muttrcPGPFormatConditionals muttrcFormatConditionals2
797highlight def link muttrcSmimeFormatConditionals muttrcFormatConditionals2
798highlight def link muttrcStatusFormatConditionals muttrcFormatConditionals2
799
800highlight def link muttrcAddrDef muttrcGroupFlag
801highlight def link muttrcRXDef muttrcGroupFlag
802
803highlight def link muttrcAliasFormatStr muttrcString
804highlight def link muttrcAttachFormatStr muttrcString
805highlight def link muttrcComposeFormatStr muttrcString
806highlight def link muttrcFolderFormatStr muttrcString
807highlight def link muttrcGroupIndexFormatStr muttrcString
808highlight def link muttrcIndexFormatStr muttrcString
809highlight def link muttrcMixFormatStr muttrcString
Bram Moolenaarcbaff5e2022-04-08 17:45:08 +0100810highlight def link muttrcPatternFormatStr muttrcString
Bram Moolenaare46a4402020-06-30 20:38:27 +0200811highlight def link muttrcPGPCmdFormatStr muttrcString
812highlight def link muttrcPGPFormatStr muttrcString
813highlight def link muttrcQueryFormatStr muttrcString
814highlight def link muttrcSidebarFormatStr muttrcString
815highlight def link muttrcSmimeFormatStr muttrcString
816highlight def link muttrcStatusFormatStr muttrcString
817highlight def link muttrcStrftimeFormatStr muttrcString
818
819highlight def link muttrcSetNumAssignment Number
820
821highlight def link muttrcEmail Special
822highlight def link muttrcSimplePatMetas Special
823highlight def link muttrcSpecial Special
824highlight def link muttrcVariableInner Special
825
826highlight def link muttrcAliasEncEmailNL SpecialChar
827highlight def link muttrcAliasENNL SpecialChar
828highlight def link muttrcAliasGroupDefNL SpecialChar
829highlight def link muttrcAliasNameNL SpecialChar
830highlight def link muttrcAliasNL SpecialChar
831highlight def link muttrcBindFunctionNL SpecialChar
832highlight def link muttrcBindKeyNL SpecialChar
833highlight def link muttrcBindMenuListNL SpecialChar
834highlight def link muttrcColorBGNL SpecialChar
835highlight def link muttrcColorFGNL SpecialChar
836highlight def link muttrcColorMatchCountNL SpecialChar
837highlight def link muttrcColorNL SpecialChar
838highlight def link muttrcColorRXNL SpecialChar
839highlight def link muttrcEscape SpecialChar
840highlight def link muttrcKeyName SpecialChar
841highlight def link muttrcKeySpecial SpecialChar
842highlight def link muttrcMacroBodyNL SpecialChar
843highlight def link muttrcMacroDescrNL SpecialChar
844highlight def link muttrcMacroKeyNL SpecialChar
845highlight def link muttrcMacroMenuListNL SpecialChar
846highlight def link muttrcPatternNL SpecialChar
847highlight def link muttrcRXChars SpecialChar
848highlight def link muttrcStringNL SpecialChar
849highlight def link muttrcUnAliasNL SpecialChar
850highlight def link muttrcUnColorAPNL SpecialChar
851highlight def link muttrcUnColorIndexNL SpecialChar
852highlight def link muttrcUnColorPatNL SpecialChar
853
854highlight def link muttrcAttachmentsMimeType String
855highlight def link muttrcEscapedVariable String
856highlight def link muttrcMacroDescr String
857highlight def link muttrcRXPat String
858highlight def link muttrcRXString String
859highlight def link muttrcRXString2 String
860highlight def link muttrcSetStrAssignment String
861highlight def link muttrcString String
862
863highlight def link muttrcAliasParens Type
864highlight def link muttrcAttachmentsFlag Type
865highlight def link muttrcColor Type
866highlight def link muttrcFormatConditionals2 Type
867highlight def link muttrcGroupFlag Type
868highlight def link muttrcHeader Type
869highlight def link muttrcHooks Type
870highlight def link muttrcKey Type
871highlight def link muttrcPatHookNot Type
872highlight def link muttrcRXHookNot Type
873highlight def link muttrcStrftimeEscapes Type
874
Bram Moolenaar01164a62017-11-02 22:58:42 +0100875let b:current_syntax = "neomuttrc"
876
877let &cpo = s:cpo_save
878unlet s:cpo_save
Bram Moolenaar7dda86f2018-04-20 22:36:41 +0200879
880" vim: ts=8 noet tw=100 sw=8 sts=0 ft=vim isk+=-