mirror of
https://github.com/keanuplayz/dotfiles.git
synced 2024-08-15 02:33:12 +00:00
[zsh] rewrite hooks with add-zsh-hook
This commit is contained in:
parent
d59880383b
commit
0ed3554233
1 changed files with 3 additions and 2 deletions
|
@ -37,8 +37,9 @@ setup_prompt() {
|
|||
setopt nopromptbang promptcr promptsp promptpercent promptsubst
|
||||
|
||||
zmodload zsh/datetime
|
||||
preexec_functions+=(prompt_preexec_hook)
|
||||
precmd_functions+=(prompt_precmd_hook)
|
||||
autoload -Uz add-zsh-hook
|
||||
add-zsh-hook preexec prompt_preexec_hook
|
||||
add-zsh-hook precmd prompt_precmd_hook
|
||||
|
||||
PROMPT='%F{8}┌─%f%B'
|
||||
PROMPT+='%F{%(!.red.yellow)}%n%f'
|
||||
|
|
Loading…
Reference in a new issue