mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2026-02-06 04:39:46 +08:00
feat(theme): Make agnoster support conda environment
This commit is contained in:
parent
95ef251669
commit
0207f6f8f4
@ -314,6 +314,9 @@ prompt_dir() {
|
|||||||
|
|
||||||
# Virtualenv: current working virtualenv
|
# Virtualenv: current working virtualenv
|
||||||
prompt_virtualenv() {
|
prompt_virtualenv() {
|
||||||
|
if [ -n "$CONDA_DEFAULT_ENV" ]; then
|
||||||
|
prompt_segment magenta $CURRENT_FG "🐍 $CONDA_DEFAULT_ENV"
|
||||||
|
fi
|
||||||
if [[ -n "$VIRTUAL_ENV" && -n "$VIRTUAL_ENV_DISABLE_PROMPT" ]]; then
|
if [[ -n "$VIRTUAL_ENV" && -n "$VIRTUAL_ENV_DISABLE_PROMPT" ]]; then
|
||||||
prompt_segment "$AGNOSTER_VENV_BG" "$AGNOSTER_VENV_FG" "(${VIRTUAL_ENV:t:gs/%/%%})"
|
prompt_segment "$AGNOSTER_VENV_BG" "$AGNOSTER_VENV_FG" "(${VIRTUAL_ENV:t:gs/%/%%})"
|
||||||
fi
|
fi
|
||||||
@ -354,9 +357,9 @@ prompt_aws() {
|
|||||||
build_prompt() {
|
build_prompt() {
|
||||||
RETVAL=$?
|
RETVAL=$?
|
||||||
prompt_status
|
prompt_status
|
||||||
prompt_virtualenv
|
|
||||||
prompt_aws
|
prompt_aws
|
||||||
prompt_context
|
prompt_context
|
||||||
|
prompt_virtualenv
|
||||||
prompt_dir
|
prompt_dir
|
||||||
prompt_git
|
prompt_git
|
||||||
prompt_bzr
|
prompt_bzr
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user