ENH show conda env

This commit is contained in:
Nathan Dwarshuis 2023-03-10 12:22:07 -05:00
parent b4b8a88f12
commit 325b35b013
1 changed files with 6 additions and 1 deletions

View File

@ -198,13 +198,18 @@ function zle-line-init zle-keymap-select {
else;
GIT=""
fi
if [ -z "$CONDA_DEFAULT_ENV" ]; then
CONDA=""
else;
CONDA="─(%B%F{cyan}$CONDA_DEFAULT_ENV%f%b)"
fi
NORMAL="%F{yellow}N%f"
INSERT="%F{cyan}I%f"
VIMODE="─%B(${${KEYMAP/vicmd/$NORMAL}/(main|viins)/$INSERT})%b"
USER="$user_color%n$HOSTNAME%f"
TIME="%F{green}%*%f"
WD="%F{green}%1~%f"
PROMPT=$'\n%B┌($USER)─($TIME)$VIMODE$GIT\n└─($WD)─>%b '
PROMPT=$'\n%B┌($USER)─($TIME)$VIMODE$GIT$CONDA\n└─($WD)─>%b '
zle reset-prompt
}