Files
dotfiles/.zsh/theme/functions/environment.zsh
2024-10-30 12:37:58 +01:00

21 lines
509 B
Bash
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
function ruby_prompt_info() {
if command -v rvm-prompt >/dev/null 2>&1; then
local ruby_version=$(rvm-prompt i v g)
if [[ -n "$ruby_version" ]]; then
echo "%F{red}${ruby_version}%f"
fi
fi
}
function virtualenv_prompt_info() {
if [[ -n "$VIRTUAL_ENV" ]]; then
echo "%F{green}${VIRTUAL_ENV:t}%f"
fi
}
function conda_prompt_info() {
if [[ -n "$CONDA_DEFAULT_ENV" ]]; then
echo "%F{green}${CONDA_DEFAULT_ENV}%f"
fi
}