add zsh usage

This commit is contained in:
Emily Daemon 2022-04-07 17:26:57 +03:00 committed by GitHub
parent 6077c17a2e
commit ca351ea90d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -18,3 +18,12 @@ set -g status-interval 2
set -g status-right-length 100 set -g status-right-length 100
set -g status-right "#(candybar)" set -g status-right "#(candybar)"
``` ```
### usage with zsh
add the following to your ~/.zshrc:
```zsh
precmd() {
psvar[1]="$(candybar)"
}
export CSI=$'\e'"["
export PROMPT="${CSI}s${CSI}1;$((LINES-1))r${CSI}$LINES;1f%S%1v%s${CSI}K${CSI}u${PROMPT}"
```