docs copyedit: Rewrap to 80 columns, part 2.

This commit is contained in:
Daniel Shahaf
2015-11-17 03:02:39 +00:00
parent 3bedd8571e
commit 3f163a2fd4
9 changed files with 37 additions and 21 deletions

View File

@@ -14,7 +14,8 @@ Syntax highlighting is done by pluggable highlighters:
How to activate highlighters
----------------------------
To activate an highlighter, add it to the `ZSH_HIGHLIGHT_HIGHLIGHTERS` array in `~/.zshrc`, for example:
To activate an highlighter, add it to the `ZSH_HIGHLIGHT_HIGHLIGHTERS` array in
`~/.zshrc`, for example:
ZSH_HIGHLIGHT_HIGHLIGHTERS=(main brackets pattern cursor)
@@ -32,7 +33,8 @@ How to implement a new highlighter
To create your own `myhighlighter` highlighter:
* Create your script at `highlighters/${myhighlighter}/${myhighlighter}-highlighter.zsh`.
* Create your script at
`highlighters/${myhighlighter}/${myhighlighter}-highlighter.zsh`.
* Implement the `_zsh_highlight_myhighlighter_highlighter_predicate` function.
This function must return 0 when the highlighter needs to be called and

View File

@@ -1,7 +1,8 @@
zsh-syntax-highlighting / highlighters / brackets
=================================================
This is the `brackets` highlighter, that highlights brackets, parenthesis and matches them.
This is the `brackets` highlighter, that highlights brackets, parenthesis and
matches them.
How to activate it
@@ -21,7 +22,8 @@ This highlighter defines the following styles:
* `bracket-level-N` - brackets with nest level N
* `cursor-matchingbracket` - the matching bracket, if cursor is on a bracket
To override one of those styles, change its entry in `ZSH_HIGHLIGHT_STYLES`, for example in `~/.zshrc`:
To override one of those styles, change its entry in `ZSH_HIGHLIGHT_STYLES`,
for example in `~/.zshrc`:
# To define styles for nested brackets up to level 4
ZSH_HIGHLIGHT_STYLES[bracket-level-1]='fg=blue,bold'

View File

@@ -19,7 +19,8 @@ This highlighter defines the following styles:
* `cursor` - the style for the current cursor position
To override one of those styles, change its entry in `ZSH_HIGHLIGHT_STYLES`, for example in `~/.zshrc`:
To override one of those styles, change its entry in `ZSH_HIGHLIGHT_STYLES`,
for example in `~/.zshrc`:
ZSH_HIGHLIGHT_STYLES[cursor]='bg=blue'

View File

@@ -19,7 +19,8 @@ This highlighter defines the following styles:
* `line` - the style for the whole line
To override one of those styles, change its entry in `ZSH_HIGHLIGHT_STYLES`, for example in `~/.zshrc`:
To override one of those styles, change its entry in `ZSH_HIGHLIGHT_STYLES`,
for example in `~/.zshrc`:
ZSH_HIGHLIGHT_STYLES[line]='bold'

View File

@@ -52,7 +52,8 @@ This highlighter defines the following styles:
* `comment` - comments, when `setopt INTERACTIVE_COMMENTS` is in effect (`echo # foo`)
* `default` - everything else
To override one of those styles, change its entry in `ZSH_HIGHLIGHT_STYLES`, for example in `~/.zshrc`:
To override one of those styles, change its entry in `ZSH_HIGHLIGHT_STYLES`,
for example in `~/.zshrc`:
# Declare the variable
typeset -A ZSH_HIGHLIGHT_STYLES

View File

@@ -15,7 +15,8 @@ To activate it, add it to `ZSH_HIGHLIGHT_HIGHLIGHTERS`:
How to tweak it
---------------
To use this highlighter, associate patterns with styles in the `ZSH_HIGHLIGHT_PATTERNS` array, for example in `~/.zshrc`:
To use this highlighter, associate patterns with styles in the
`ZSH_HIGHLIGHT_PATTERNS` array, for example in `~/.zshrc`:
# To have commands starting with `rm -rf` in red:
ZSH_HIGHLIGHT_PATTERNS+=('rm -rf *' 'fg=white,bold,bg=red')

View File

@@ -1,7 +1,8 @@
zsh-syntax-highlighting / highlighters / root
=============================================
This is the `root` highlighter, that highlights the whole line if the current user is root.
This is the `root` highlighter, that highlights the whole line if the current
user is root.
How to activate it
@@ -19,7 +20,8 @@ This highlighter defines the following styles:
* `root` - the style for the whole line if the current user is root.
To override one of those styles, change its entry in `ZSH_HIGHLIGHT_STYLES`, for example in `~/.zshrc`:
To override one of those styles, change its entry in `ZSH_HIGHLIGHT_STYLES`,
for example in `~/.zshrc`:
ZSH_HIGHLIGHT_STYLES[root]='bg=red'