diff --git a/.github/FUNDING.yml b/.github/FUNDING.yml new file mode 100644 index 00000000..8914ef48 --- /dev/null +++ b/.github/FUNDING.yml @@ -0,0 +1,12 @@ +# These are supported funding model platforms + +github: [pyenv] # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2] +patreon: # Replace with a single Patreon username +open_collective: pyenv # Replace with a single Open Collective username +ko_fi: # Replace with a single Ko-fi username +tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel +community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry +liberapay: # Replace with a single Liberapay username +issuehunt: # Replace with a single IssueHunt username +otechie: # Replace with a single Otechie username +custom: # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2'] diff --git a/.github/workflows/ubuntu_tests.yml b/.github/workflows/ubuntu_tests.yml index 665e6f16..81bab713 100644 --- a/.github/workflows/ubuntu_tests.yml +++ b/.github/workflows/ubuntu_tests.yml @@ -12,7 +12,7 @@ jobs: - 3.7.10 - 3.8.10 - 3.9.5 - - 3.10.0rc2 + - 3.10.0 runs-on: Ubuntu-20.04 steps: - uses: actions/checkout@v2 diff --git a/CHANGELOG.md b/CHANGELOG.md index b3964e9b..e66691e5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,21 @@ ## Version History +## Release 2.1.0 +* Fix mambaforge-pypy3 build (#2096) +* Add Python 3.10.0 (#2093) +* Add documentation for exec command (#2090) +* Add documentation for shims command (#2091) +* Add documentation for hooks command (#2089) +* Add documentation for root command (#2088) +* Add documentaion for prefix command (#2087) +* Update to Pyston's v2 package of the 2.3.1 release (#2078) +* Add pyston-2.3.1 support (#2075) +* Don't update conda when installing pip (#2074) +* Improve `add_miniconda.py` (#2072) +* GitHub actions tests (#2073) +* Fix sed commands (#2071) +* macOS: fix the build of Python 2.7.18 on macOS 11.5.2 (Big Sur) + Apple Silicon (#2061) + ## Release 2.0.7 * Update setup instructions in the Readme (#2067) * Allow tcl-tk as argument or try with homebrew by default (#1646) diff --git a/COMMANDS.md b/COMMANDS.md index 6da9c0e4..97d31721 100644 --- a/COMMANDS.md +++ b/COMMANDS.md @@ -16,7 +16,11 @@ The most common subcommands are: * [`pyenv versions`](#pyenv-versions) * [`pyenv which`](#pyenv-which) * [`pyenv whence`](#pyenv-whence) - +* [`pyenv exec`](#pyenv-exec) +* [`pyenv root`](#pyenv-root) +* [`pyenv prefix`](#pyenv-prefix) +* [`pyenv hooks`](#pyenv-hooks) +* [`pyenv shims`](#pyenv-shims) ## `pyenv commands` @@ -278,3 +282,66 @@ Lists all Python versions with the given command installed. 2.6.8 2.7.6 3.3.3 + +## `pyenv exec` + + `Usage: pyenv exec [arg1 arg2...]` + +Runs an executable by first preparing PATH so that the selected Python +version's `bin` directory is at the front. + +For example, if the currently selected Python version is 3.9.7: + + `pyenv exec pip install -r requirements.txt` + +is equivalent to: + + `PATH="$PYENV_ROOT/versions/3.9.7/bin:$PATH" pip install -r requirements.txt` + +## `pyenv root` + +Displays the root directory where versions and shims are kept. + + $ pyenv root + /home/user/.pyenv + +## `pyenv prefix` + +Displays the directory where a Python version is installed. If no +version is given, `pyenv prefix` displays the location of the +currently selected version. + + $ pyenv prefix 3.9.7 + /home/user/.pyenv/versions/3.9.7 + +## `pyenv hooks` + +Lists installed hook scripts for a given pyenv command. + + Usage: pyenv hooks + +## `pyenv shims` + +List existing pyenv shims. + + Usage: pyenv shims [--short] + + $ pyenv shims + /home/user/.pyenv/shims/2to3 + /home/user/.pyenv/shims/2to3-3.9 + /home/user/.pyenv/shims/idle + /home/user/.pyenv/shims/idle3 + /home/user/.pyenv/shims/idle3.9 + /home/user/.pyenv/shims/pip + /home/user/.pyenv/shims/pip3 + /home/user/.pyenv/shims/pip3.9 + /home/user/.pyenv/shims/pydoc + /home/user/.pyenv/shims/pydoc3 + /home/user/.pyenv/shims/pydoc3.9 + /home/user/.pyenv/shims/python + /home/user/.pyenv/shims/python3 + /home/user/.pyenv/shims/python3.9 + /home/user/.pyenv/shims/python3.9-config + /home/user/.pyenv/shims/python3.9-gdb.py + /home/user/.pyenv/shims/python3-config + /home/user/.pyenv/shims/python-config diff --git a/README.md b/README.md index 1a7ebf99..e7234cc0 100644 --- a/README.md +++ b/README.md @@ -2,8 +2,6 @@ [![Join the chat at https://gitter.im/yyuu/pyenv](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/yyuu/pyenv?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) -[![Build Status](https://travis-ci.org/pyenv/pyenv.svg?branch=master)](https://travis-ci.org/pyenv/pyenv) - pyenv lets you easily switch between multiple versions of Python. It's simple, unobtrusive, and follows the UNIX tradition of single-purpose tools that do one thing well. diff --git a/libexec/pyenv---version b/libexec/pyenv---version index 86fb741d..e09f99fd 100755 --- a/libexec/pyenv---version +++ b/libexec/pyenv---version @@ -12,7 +12,7 @@ set -e [ -n "$PYENV_DEBUG" ] && set -x -version="2.0.7" +version="2.1.0" git_revision="" if cd "${BASH_SOURCE%/*}" 2>/dev/null && git remote -v 2>/dev/null | grep -q pyenv; then diff --git a/plugins/python-build/share/python-build/3.10.0rc2 b/plugins/python-build/share/python-build/3.10.0 similarity index 53% rename from plugins/python-build/share/python-build/3.10.0rc2 rename to plugins/python-build/share/python-build/3.10.0 index 86c3c489..8542079c 100644 --- a/plugins/python-build/share/python-build/3.10.0rc2 +++ b/plugins/python-build/share/python-build/3.10.0 @@ -4,7 +4,7 @@ export PYTHON_BUILD_CONFIGURE_WITH_OPENSSL=1 install_package "openssl-1.1.1k" "https://www.openssl.org/source/openssl-1.1.1k.tar.gz#892a0875b9872acd04a9fde79b1f943075d5ea162415de3047c327df33fbaee5" mac_openssl --if has_broken_mac_openssl install_package "readline-8.0" "https://ftpmirror.gnu.org/readline/readline-8.0.tar.gz#e339f51971478d369f8a053a330a190781acb9864cf4c541060f12078948e461" mac_readline --if has_broken_mac_readline if has_tar_xz_support; then - install_package "Python-3.10.0rc2" "https://www.python.org/ftp/python/3.10.0/Python-3.10.0rc2.tar.xz#e75b56088548b7b9ad1f2571e6f5a2315e4808cb6b5fbe8288502afc802b2f24" standard verify_py310 copy_python_gdb ensurepip + install_package "Python-3.10.0" "https://www.python.org/ftp/python/3.10.0/Python-3.10.0.tar.xz#5a99f8e7a6a11a7b98b4e75e0d1303d3832cada5534068f69c7b6222a7b1b002" standard verify_py310 copy_python_gdb ensurepip else - install_package "Python-3.10.0rc2" "https://www.python.org/ftp/python/3.10.0/Python-3.10.0rc2.tgz#0f8bf53dbe6f85785d502e73984aa3f12f67ac4958d9b8d8012019c35c646fe2" standard verify_py310 copy_python_gdb ensurepip + install_package "Python-3.10.0" "https://www.python.org/ftp/python/3.10.0/Python-3.10.0.tgz#c4e0cbad57c90690cb813fb4663ef670b4d0f587d8171e2c42bd4c9245bd2758" standard verify_py310 copy_python_gdb ensurepip fi diff --git a/plugins/python-build/share/python-build/3.11.0a1 b/plugins/python-build/share/python-build/3.11.0a1 new file mode 100644 index 00000000..5305ec03 --- /dev/null +++ b/plugins/python-build/share/python-build/3.11.0a1 @@ -0,0 +1,10 @@ +#require_gcc +prefer_openssl11 +export PYTHON_BUILD_CONFIGURE_WITH_OPENSSL=1 +install_package "openssl-1.1.1k" "https://www.openssl.org/source/openssl-1.1.1k.tar.gz#892a0875b9872acd04a9fde79b1f943075d5ea162415de3047c327df33fbaee5" mac_openssl --if has_broken_mac_openssl +install_package "readline-8.0" "https://ftpmirror.gnu.org/readline/readline-8.0.tar.gz#e339f51971478d369f8a053a330a190781acb9864cf4c541060f12078948e461" mac_readline --if has_broken_mac_readline +if has_tar_xz_support; then + install_package "Python-3.11.0a1" "https://www.python.org/ftp/python/3.11.0/Python-3.11.0a1.tar.xz#966319daafa40f337e4d85a0b26fbdd919135c321eb3961a9b3d758abbc95376" standard verify_py311 copy_python_gdb ensurepip +else + install_package "Python-3.11.0a1" "https://www.python.org/ftp/python/3.11.0/Python-3.11.0a1.tgz#d2c83771a671d0755d1cda5d82aaea70ef32d337fe5bf87036bd113fc088edff" standard verify_py311 copy_python_gdb ensurepip +fi diff --git a/plugins/python-build/share/python-build/mambaforge-pypy3 b/plugins/python-build/share/python-build/mambaforge-pypy3 index c42197d8..fb493e4e 100644 --- a/plugins/python-build/share/python-build/mambaforge-pypy3 +++ b/plugins/python-build/share/python-build/mambaforge-pypy3 @@ -1,4 +1,4 @@ -ase "$(anaconda_architecture 2>/dev/null || true)" in +case "$(anaconda_architecture 2>/dev/null || true)" in "Linux-ppc64le" ) install_script "Mambaforge-pypy3-Linux-ppc64le" "https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-pypy3-Linux-ppc64le.sh" "miniconda" verify_py3_latest ;;