[zsh] Move the history number later in the prompt and add a numero sign
Show non-zero exit status after the history number as a red exclamation mark. ``` eryn in ~/.dotfiles on .dotfiles(main) №36407 at 10:06:48 % ```
This commit is contained in:
parent
d92641ae85
commit
ae8955f99e
1 changed files with 3 additions and 2 deletions
|
@ -42,7 +42,7 @@ function prompt_loquacious_setup
|
|||
zstyle ':vcs_info:git:loquacious_precmd:*' formats '(%F{blue}%b%f)'
|
||||
zstyle ':vcs_info:git-svn:loquacious_precmd:*' formats '(%F{blue}%b%f)'
|
||||
|
||||
PS1='${PS1_STATUS}${PS1_NAME}${PS1_HOST}${PS1_CWD}${PS1_REPO}${PS1_BRANCH}${PS1_TIME}${PS1_ZLE_MODE}
|
||||
PS1='${PS1_NAME}${PS1_HOST}${PS1_CWD}${PS1_REPO}${PS1_BRANCH}${PS1_HISTORY}${PS1_STATUS}${PS1_TIME}${PS1_ZLE_MODE}
|
||||
$PS1_LINE'
|
||||
|
||||
zle -N zle-keymap-select on_keymap_select
|
||||
|
@ -85,7 +85,8 @@ function set_prompt_info
|
|||
PS1_TIME="at %*"
|
||||
PS1_NAME="%F{magenta}%n%f "
|
||||
PS1_CWD="in %F{green}%~%f "
|
||||
PS1_STATUS="[%(?.%F{blue}%!%f.%F{red}%!%f)] "
|
||||
PS1_STATUS="%(?..%F{red}!%f) "
|
||||
PS1_HISTORY="№%F{blue}%!%f"
|
||||
|
||||
if [[ -n "$SSH_CONNECTION" && "$TERM_PROGRAM" != "tmux" ]]; then
|
||||
PS1_HOST="at %F{red}%m%f "
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue