根据 python.org 的说法,
Python 3.6.1
已于 3 月底发布。但是:
» pyenv install -l | grep 3\.6\.
3.6.0a1
3.6.0a3
3.6-dev
Python 3.6.1
尚未在 pyenv
中可用?pyenv
支持的版本的文档? (何时添加,正在进行什么,...)。 pyenv 文档没有提供此信息。pyenv
支持的 Python 版本存储库? (类似于PyPi
)pyenv update
brew upgrade pyenv
cd $(pyenv root) && git pull
我尝试过
pyenv update
但这并没有解决我的问题。
在做
brew update && brew upgrade pyenv
之前我必须
pyenv install 3.6.1
谢谢@amigcamel 的完整答案。我是通过 Git 安装的,所以没有
pyenv update
,但我不想记住 Git 方法,所以我在 Copilot 的帮助下制作了这个并将其放入我的个人资料中。所以现在我有pyenv update
。 😀
pyenv() {
local pyenv_bin="/home/aquar/.pyenv/bin/pyenv"
local first_arg="$1"
# Check if the first argument is "update"
if [ "$first_arg" = "update" ]; then
# Execute the update commands
pushd "$(pyenv root)" && git pull && popd
else
# Pass all arguments to the original pyenv binary
"$pyenv_bin" "$@"
fi
}