mirror of
https://github.com/zdharma-continuum/history-search-multi-word
synced 2024-11-24 20:33:04 +00:00
Updated README.md
This commit is contained in:
parent
159aaa5e72
commit
7997c62697
1 changed files with 20 additions and 3 deletions
23
README.md
23
README.md
|
@ -28,9 +28,26 @@ Set:
|
||||||
zstyle :plugin:history-search-multi-word reset-prompt-protect 1
|
zstyle :plugin:history-search-multi-word reset-prompt-protect 1
|
||||||
```
|
```
|
||||||
|
|
||||||
to be able to use `zle reset-prompt` in your e.g. `sched` calls, in presence of `zdharma/fast-syntax-highlighting`,
|
to be able to use `zle reset-prompt` in your e.g. `sched` calls, in presence of
|
||||||
`zsh-users/zsh-syntax-highlighting`, `zsh-users/zsh-autosuggestions` and other plugins that hook up into Zshell by
|
`zdharma/fast-syntax-highlighting`, `zsh-users/zsh-syntax-highlighting`,
|
||||||
overloading Zle widgets. In general, HSMW should be loaded in bulk (no gap) with all those plugins, right before them.
|
`zsh-users/zsh-autosuggestions` and other plugins that hook up into Zshell by
|
||||||
|
overloading Zle widgets. You could e.g. use `sched` in following way:
|
||||||
|
|
||||||
|
```zsh
|
||||||
|
PROMPT=%B%F{yellow}%D{%H:%M:%S}%B%b%f
|
||||||
|
schedprompt() {
|
||||||
|
zle && zle reset-prompt
|
||||||
|
sched +1 schedprompt
|
||||||
|
}
|
||||||
|
|
||||||
|
zmodload -i zsh/sched
|
||||||
|
schedprompt
|
||||||
|
```
|
||||||
|
|
||||||
|
to refresh the clock in prompt every second. The `reset-prompt-protect` zstyle
|
||||||
|
needs to be set to 1 for correct cooperation with HSMW. Or, you could use `zle
|
||||||
|
.reset-prompt` (i.e. with the dot in front) to call the original, not
|
||||||
|
overloaded (by F-Sy-H, zsh-autosuggestsions, etc.) `reset-prompt` widget.
|
||||||
|
|
||||||
# News
|
# News
|
||||||
* 25-05-2018
|
* 25-05-2018
|
||||||
|
|
Loading…
Reference in a new issue