mirror of
https://github.com/zsh-users/zsh-syntax-highlighting.git
synced 2026-06-19 01:12:48 +02:00
main: support highlighting paths with specific styles
If there are styles starting with `*.`, consider these "glob matchers" and style according to the matching glob. This allows users to color paths matching patterns in any way desired. Fixes: #605
This commit is contained in:
parent
99680ff695
commit
f39e4bbdfb
3 changed files with 19 additions and 0 deletions
|
|
@ -67,6 +67,11 @@ This highlighter defines the following styles:
|
|||
* `arg0` - a command word other than one of those enumerated above (other than a command, precommand, alias, function, or shell builtin command).
|
||||
* `default` - everything else
|
||||
|
||||
Additionally, styles starting with `*.` may be used to style `path` and
|
||||
`redirection` argument matches with a more specific style. For example,
|
||||
defining the `*.png` style will apply to any `path` or `redirection` target
|
||||
ending with `.png`.
|
||||
|
||||
To override one of those styles, change its entry in `ZSH_HIGHLIGHT_STYLES`,
|
||||
for example in `~/.zshrc`:
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue