mirror of
https://github.com/romkatv/powerlevel10k.git
synced 2024-11-12 08:10:07 +00:00
pyenv: display python version alongside environment name if unequal
See #730.
This commit is contained in:
parent
f96c1eb5e5
commit
6998d06a91
4 changed files with 52 additions and 0 deletions
|
@ -873,6 +873,19 @@
|
||||||
typeset -g POWERLEVEL9K_PYENV_PROMPT_ALWAYS_SHOW=false
|
typeset -g POWERLEVEL9K_PYENV_PROMPT_ALWAYS_SHOW=false
|
||||||
# If set to false, hide python version if it's equal to "system".
|
# If set to false, hide python version if it's equal to "system".
|
||||||
typeset -g POWERLEVEL9K_PYENV_SHOW_SYSTEM=true
|
typeset -g POWERLEVEL9K_PYENV_SHOW_SYSTEM=true
|
||||||
|
|
||||||
|
# Pyenv segment format. The following parameters are available within the expansion.
|
||||||
|
#
|
||||||
|
# - P9K_CONTENT Current pyenv environment (pyenv version-name).
|
||||||
|
# - P9K_PYENV_PYTHON_VERSION Current python version (python --version).
|
||||||
|
#
|
||||||
|
# The default format has the following logic:
|
||||||
|
#
|
||||||
|
# 1. Display "$P9K_CONTENT $P9K_PYENV_PYTHON_VERSION" if $P9K_PYENV_PYTHON_VERSION is not
|
||||||
|
# empty and unequal to $P9K_CONTENT.
|
||||||
|
# 2. Otherwise display just "$P9K_CONTENT".
|
||||||
|
typeset -g POWERLEVEL9K_PYENV_CONTENT_EXPANSION='${P9K_CONTENT}${${P9K_PYENV_PYTHON_VERSION:#$P9K_CONTENT}:+ $P9K_PYENV_PYTHON_VERSION}'
|
||||||
|
|
||||||
# Custom icon.
|
# Custom icon.
|
||||||
# typeset -g POWERLEVEL9K_PYENV_VISUAL_IDENTIFIER_EXPANSION='⭐'
|
# typeset -g POWERLEVEL9K_PYENV_VISUAL_IDENTIFIER_EXPANSION='⭐'
|
||||||
|
|
||||||
|
|
|
@ -850,6 +850,19 @@
|
||||||
typeset -g POWERLEVEL9K_PYENV_PROMPT_ALWAYS_SHOW=false
|
typeset -g POWERLEVEL9K_PYENV_PROMPT_ALWAYS_SHOW=false
|
||||||
# If set to false, hide python version if it's equal to "system".
|
# If set to false, hide python version if it's equal to "system".
|
||||||
typeset -g POWERLEVEL9K_PYENV_SHOW_SYSTEM=true
|
typeset -g POWERLEVEL9K_PYENV_SHOW_SYSTEM=true
|
||||||
|
|
||||||
|
# Pyenv segment format. The following parameters are available within the expansion.
|
||||||
|
#
|
||||||
|
# - P9K_CONTENT Current pyenv environment (pyenv version-name).
|
||||||
|
# - P9K_PYENV_PYTHON_VERSION Current python version (python --version).
|
||||||
|
#
|
||||||
|
# The default format has the following logic:
|
||||||
|
#
|
||||||
|
# 1. Display "$P9K_CONTENT $P9K_PYENV_PYTHON_VERSION" if $P9K_PYENV_PYTHON_VERSION is not
|
||||||
|
# empty and unequal to $P9K_CONTENT.
|
||||||
|
# 2. Otherwise display just "$P9K_CONTENT".
|
||||||
|
typeset -g POWERLEVEL9K_PYENV_CONTENT_EXPANSION='${P9K_CONTENT}${${P9K_PYENV_PYTHON_VERSION:#$P9K_CONTENT}:+ $P9K_PYENV_PYTHON_VERSION}'
|
||||||
|
|
||||||
# Custom icon.
|
# Custom icon.
|
||||||
# typeset -g POWERLEVEL9K_PYENV_VISUAL_IDENTIFIER_EXPANSION='⭐'
|
# typeset -g POWERLEVEL9K_PYENV_VISUAL_IDENTIFIER_EXPANSION='⭐'
|
||||||
|
|
||||||
|
|
|
@ -850,6 +850,19 @@
|
||||||
typeset -g POWERLEVEL9K_PYENV_PROMPT_ALWAYS_SHOW=false
|
typeset -g POWERLEVEL9K_PYENV_PROMPT_ALWAYS_SHOW=false
|
||||||
# If set to false, hide python version if it's equal to "system".
|
# If set to false, hide python version if it's equal to "system".
|
||||||
typeset -g POWERLEVEL9K_PYENV_SHOW_SYSTEM=true
|
typeset -g POWERLEVEL9K_PYENV_SHOW_SYSTEM=true
|
||||||
|
|
||||||
|
# Pyenv segment format. The following parameters are available within the expansion.
|
||||||
|
#
|
||||||
|
# - P9K_CONTENT Current pyenv environment (pyenv version-name).
|
||||||
|
# - P9K_PYENV_PYTHON_VERSION Current python version (python --version).
|
||||||
|
#
|
||||||
|
# The default format has the following logic:
|
||||||
|
#
|
||||||
|
# 1. Display "$P9K_CONTENT $P9K_PYENV_PYTHON_VERSION" if $P9K_PYENV_PYTHON_VERSION is not
|
||||||
|
# empty and unequal to $P9K_CONTENT.
|
||||||
|
# 2. Otherwise display just "$P9K_CONTENT".
|
||||||
|
typeset -g POWERLEVEL9K_PYENV_CONTENT_EXPANSION='${P9K_CONTENT}${${P9K_PYENV_PYTHON_VERSION:#$P9K_CONTENT}:+ $P9K_PYENV_PYTHON_VERSION}'
|
||||||
|
|
||||||
# Custom icon.
|
# Custom icon.
|
||||||
# typeset -g POWERLEVEL9K_PYENV_VISUAL_IDENTIFIER_EXPANSION='⭐'
|
# typeset -g POWERLEVEL9K_PYENV_VISUAL_IDENTIFIER_EXPANSION='⭐'
|
||||||
|
|
||||||
|
|
|
@ -910,6 +910,19 @@
|
||||||
typeset -g POWERLEVEL9K_PYENV_PROMPT_ALWAYS_SHOW=false
|
typeset -g POWERLEVEL9K_PYENV_PROMPT_ALWAYS_SHOW=false
|
||||||
# If set to false, hide python version if it's equal to "system".
|
# If set to false, hide python version if it's equal to "system".
|
||||||
typeset -g POWERLEVEL9K_PYENV_SHOW_SYSTEM=true
|
typeset -g POWERLEVEL9K_PYENV_SHOW_SYSTEM=true
|
||||||
|
|
||||||
|
# Pyenv segment format. The following parameters are available within the expansion.
|
||||||
|
#
|
||||||
|
# - P9K_CONTENT Current pyenv environment (pyenv version-name).
|
||||||
|
# - P9K_PYENV_PYTHON_VERSION Current python version (python --version).
|
||||||
|
#
|
||||||
|
# The default format has the following logic:
|
||||||
|
#
|
||||||
|
# 1. Display "$P9K_CONTENT $P9K_PYENV_PYTHON_VERSION" if $P9K_PYENV_PYTHON_VERSION is not
|
||||||
|
# empty and unequal to $P9K_CONTENT.
|
||||||
|
# 2. Otherwise display just "$P9K_CONTENT".
|
||||||
|
typeset -g POWERLEVEL9K_PYENV_CONTENT_EXPANSION='${P9K_CONTENT}${${P9K_PYENV_PYTHON_VERSION:#$P9K_CONTENT}:+ $P9K_PYENV_PYTHON_VERSION}'
|
||||||
|
|
||||||
# Custom icon.
|
# Custom icon.
|
||||||
# typeset -g POWERLEVEL9K_PYENV_VISUAL_IDENTIFIER_EXPANSION='⭐'
|
# typeset -g POWERLEVEL9K_PYENV_VISUAL_IDENTIFIER_EXPANSION='⭐'
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue