pyenv 修改了我对带有单词但不是纯编号版本的版本的提示

pyenv modifies my prompt for versions with words but not the purely numbered ones

我的 .bashrc 添加了以下行:

export PYENV_ROOT="$HOME/.pyenv"
export PATH="$PYENV_ROOT/bin:$PATH"
eval "$(pyenv init -)"
eval "$(pyenv virtualenv-init -)"

终端中的以下几行说明了问题:

cardamom@neptune ~ $ mkdir testDirectory
cardamom@neptune ~ $ cd testDirectory
cardamom@neptune ~/testDirectory $ pyenv versions
* system (set by /home/felix/.pyenv/version)
  3.4.3
  3.5.0
  project1
  miniconda2-latest
  miniconda3-latest
  miniconda3-latest/envs/project1
cardamom@neptune ~/testDirectory $ pyenv local miniconda3-latest
(miniconda3-latest) cardamom@neptune ~/testDirectory $ pyenv local miniconda2-latest
(miniconda2-latest) cardamom@neptune ~/testDirectory $ pyenv local 3.4.3
cardamom@neptune ~/testDirectory $ python --version
Python 3.4.3
cardamom@neptune ~/testDirectory $

有谁知道出了什么问题以及如何解决?

因为miniconda3-latest是一个虚拟环境,而3.4.3只是一个不同的Python版本。

pyenv,用于更改当前活动的 Python 版本,不会以任何方式更改命令行提示,但 pyenv-virtualenv 插件 does.

没有什么问题,只是virtualenvs在这种情况下得到了特殊处理。