Add instructions about initializing variable

Many users use modular configuration loaders for zshrc. Adding a note to users explaining how to define ZSH_HIGHLIGHT_HIGHLIGHTERS before sourcing zsh-syntax-highlighting. The typeset is important, since simply setting the variable doesn't have the desired effect.
This commit is contained in:
Ivan Smirnov 2018-08-20 16:49:35 -07:00 committed by GitHub
parent db6cac391b
commit 33315cc447
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -29,6 +29,10 @@ To activate an highlighter, add it to the `ZSH_HIGHLIGHT_HIGHLIGHTERS` array in
By default, `$ZSH_HIGHLIGHT_HIGHLIGHTERS` is unset and only the `main`
highlighter is active.
If you would like to set this variable before
sourcing zsh-syntax-highlighting, initialize it first with:
`typeset -ga ZSH_HIGHLIGHT_HIGHLIGHTERS`
How to tweak highlighters
-------------------------