aboutsummaryrefslogtreecommitdiff
path: root/vim/syntax/paludis-general-conf.vim
diff options
context:
space:
mode:
Diffstat (limited to 'vim/syntax/paludis-general-conf.vim')
-rw-r--r--vim/syntax/paludis-general-conf.vim10
1 files changed, 7 insertions, 3 deletions
diff --git a/vim/syntax/paludis-general-conf.vim b/vim/syntax/paludis-general-conf.vim
index 537f682de..f8939b578 100644
--- a/vim/syntax/paludis-general-conf.vim
+++ b/vim/syntax/paludis-general-conf.vim
@@ -25,7 +25,8 @@ syn match PaludisGeneralConfEquals /=/ skipwhite
syn region PaludisGeneralConfValue contained start=// end=/$/
\ contains=PaludisGeneralConfString,PaludisGeneralConfUnquoted,
- \ PaludisGeneralConfContinuation,PaludisGeneralConfVariable
+ \ PaludisGeneralConfContinuation,PaludisGeneralConfVariable,
+ \ PaludisGeneralConfEnvVariable
\ skipwhite
syn match PaludisGeneralConfContinuation contained /\\$/
@@ -34,18 +35,21 @@ syn match PaludisGeneralConfContinuation contained /\\$/
syn match PaludisGeneralConfUnquoted contained /[^ \t$"'\\]\+/ skipwhite
syn region PaludisGeneralConfString contained start=/"/ end=/"/
- \ contains=PaludisGeneralConfVariable
+ \ contains=PaludisGeneralConfVariable,PaludisGeneralConfEnvVariable
\ skipwhite
syn keyword PaludisGeneralConfKnownKey contained
\ reduced_username portage_compatible distribution world
-syn match PaludisGeneralConfVariable contained /\$\({[^}]\+}\|[a-zA-Z0-9_]\+\)/ skipwhite
+syn match PaludisGeneralConfVariable contained /\$\({[^{}]\+}\|\(ENV{\)\@!=[a-zA-Z0-9_]\+\)/ skipwhite
+
+syn match PaludisGeneralConfEnvVariable contained /\$\({ENV{[^{}]\+}}\|ENV{[a-zA-Z0-9_]\+}\)/ skipwhite
hi def link PaludisGeneralConfKnownKey Keyword
hi def link PaludisGeneralConfString String
hi def link PaludisGeneralConfUnquoted Constant
hi def link PaludisGeneralConfVariable Identifier
+hi def link PaludisGeneralConfEnvVariable Statement
hi def link PaludisGeneralConfContinuation Preproc
hi def link PaludisGeneralConfComment Comment