mirror of
https://github.com/pyenv/pyenv.git
synced 2025-11-08 11:33:49 -05:00
Compare commits
18 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
ad8f2886ae | ||
|
|
9a99d427ef | ||
|
|
6bb14c60da | ||
|
|
d9c933e0c0 | ||
|
|
19cb9f535a | ||
|
|
84c4ed5230 | ||
|
|
235eea3003 | ||
|
|
688c0af0cd | ||
|
|
c1af5ab0a9 | ||
|
|
e09d61780c | ||
|
|
4cef3d74ac | ||
|
|
f36d735e27 | ||
|
|
a6776562c1 | ||
|
|
9c4e489637 | ||
|
|
afbd54dd13 | ||
|
|
99b510859d | ||
|
|
2657f1049c | ||
|
|
99d16707e3 |
@@ -1,5 +1,12 @@
|
||||
## Version History
|
||||
|
||||
## 1.0.8
|
||||
|
||||
* pyenv: Fix fish subcommand completion (#831)
|
||||
* python-build: Add Anaconda2/Anaconda3 4.3.0 (#824)
|
||||
* python-build: Use CPython on GitHub as the source repository of CPython development versions (#836, #837)
|
||||
* python-build: Fix checksum verification issue on the platform where OpenSSL isn't available (#840)
|
||||
|
||||
## 1.0.7
|
||||
|
||||
* python-build: Add CPython 3.5.3 (#811)
|
||||
|
||||
34
README.md
34
README.md
@@ -87,7 +87,7 @@ then `/bin`.
|
||||
pyenv works by inserting a directory of _shims_ at the front of your
|
||||
`PATH`:
|
||||
|
||||
~/.pyenv/shims:/usr/local/bin:/usr/bin:/bin
|
||||
$(pyenv root)/shims:/usr/local/bin:/usr/bin:/bin
|
||||
|
||||
Through a process called _rehashing_, pyenv maintains shims in that
|
||||
directory to match every Python command across every installed version
|
||||
@@ -119,7 +119,7 @@ reading it from the following sources, in this order:
|
||||
3. The first `.python-version` file found (if any) by searching each parent
|
||||
directory, until reaching the root of your filesystem.
|
||||
|
||||
4. The global `~/.pyenv/version` file. You can modify this file using
|
||||
4. The global `$(pyenv root)/version` file. You can modify this file using
|
||||
the [`pyenv global`](https://github.com/yyuu/pyenv/blob/master/COMMANDS.md#pyenv-global) command. If the global version
|
||||
file is not present, pyenv assumes you want to use the "system"
|
||||
Python. (In other words, whatever version would run if pyenv weren't in your
|
||||
@@ -133,7 +133,7 @@ in this example), but also have Python 3.3.6, 3.2, and 2.5 available on your
|
||||
`PATH`, one would first `pyenv install` the missing versions, then set `pyenv
|
||||
global system 3.3.6 3.2 2.5`. At this point, one should be able to find the full
|
||||
executable path to each of these using `pyenv which`, e.g. `pyenv which python2.5`
|
||||
(should display `$PYENV_ROOT/versions/2.5/bin/python2.5`), or `pyenv which
|
||||
(should display `$(pyenv root)/versions/2.5/bin/python2.5`), or `pyenv which
|
||||
python3.4` (should display path to system Python3). You can also specify multiple
|
||||
versions in a `.python-version` file, separated by newlines or any whitespace.
|
||||
|
||||
@@ -144,16 +144,16 @@ specified, it passes the command along to the corresponding Python
|
||||
installation.
|
||||
|
||||
Each Python version is installed into its own directory under
|
||||
`~/.pyenv/versions`.
|
||||
`$(pyenv root)/versions`.
|
||||
|
||||
For example, you might have these versions installed:
|
||||
|
||||
* `~/.pyenv/versions/2.7.8/`
|
||||
* `~/.pyenv/versions/3.4.2/`
|
||||
* `~/.pyenv/versions/pypy-2.4.0/`
|
||||
* `$(pyenv root)/versions/2.7.8/`
|
||||
* `$(pyenv root)/versions/3.4.2/`
|
||||
* `$(pyenv root)/versions/pypy-2.4.0/`
|
||||
|
||||
As far as pyenv is concerned, version names are simply the directories in
|
||||
`~/.pyenv/versions`.
|
||||
`$(pyenv root)/versions`.
|
||||
|
||||
### Managing Virtual Environments
|
||||
|
||||
@@ -218,7 +218,7 @@ easy to fork and contribute any changes back upstream.
|
||||
```sh
|
||||
$ exec $SHELL
|
||||
```
|
||||
5. **Install Python versions into `$PYENV_ROOT/versions`.**
|
||||
5. **Install Python versions into `$(pyenv root)/versions`.**
|
||||
For example, to download and install Python 2.7.8, run:
|
||||
```sh
|
||||
$ pyenv install 2.7.8
|
||||
@@ -242,14 +242,14 @@ upgrade your installation at any time using git.
|
||||
To upgrade to the latest development version of pyenv, use `git pull`:
|
||||
|
||||
```sh
|
||||
$ cd ~/.pyenv
|
||||
$ cd $(pyenv root)
|
||||
$ git pull
|
||||
```
|
||||
|
||||
To upgrade to a specific release of pyenv, check out the corresponding tag:
|
||||
|
||||
```sh
|
||||
$ cd ~/.pyenv
|
||||
$ cd $(pyenv root)
|
||||
$ git fetch
|
||||
$ git tag
|
||||
v0.1.0
|
||||
@@ -271,9 +271,9 @@ uninstall from the system.
|
||||
|
||||
2. To completely **uninstall** pyenv, perform step (1) and then remove
|
||||
its root directory. This will **delete all Python versions** that were
|
||||
installed under `` `pyenv root`/versions/ `` directory:
|
||||
installed under `` $(pyenv root)/versions/ `` directory:
|
||||
```sh
|
||||
rm -rf `pyenv root`
|
||||
rm -rf $(pyenv root)
|
||||
```
|
||||
If you've installed pyenv using a package manager, as a final step
|
||||
perform the pyenv package removal. For instance, for Homebrew:
|
||||
@@ -308,11 +308,11 @@ opposed to this idea. Here's what `pyenv init` actually does:
|
||||
|
||||
1. **Sets up your shims path.** This is the only requirement for pyenv to
|
||||
function properly. You can do this by hand by prepending
|
||||
`~/.pyenv/shims` to your `$PATH`.
|
||||
`$(pyenv root)/shims` to your `$PATH`.
|
||||
|
||||
2. **Installs autocompletion.** This is entirely optional but pretty
|
||||
useful. Sourcing `~/.pyenv/completions/pyenv.bash` will set that
|
||||
up. There is also a `~/.pyenv/completions/pyenv.zsh` for Zsh
|
||||
useful. Sourcing `$(pyenv root)/completions/pyenv.bash` will set that
|
||||
up. There is also a `$(pyenv root)/completions/pyenv.zsh` for Zsh
|
||||
users.
|
||||
|
||||
3. **Rehashes shims.** From time to time you'll need to rebuild your
|
||||
@@ -332,7 +332,7 @@ To see exactly what happens under the hood for yourself, run `pyenv init -`.
|
||||
### Uninstalling Python Versions
|
||||
|
||||
As time goes on, you will accumulate Python versions in your
|
||||
`~/.pyenv/versions` directory.
|
||||
`$(pyenv root)/versions` directory.
|
||||
|
||||
To remove old Python versions, `pyenv uninstall` command to automate
|
||||
the removal process.
|
||||
|
||||
@@ -18,5 +18,6 @@ end
|
||||
|
||||
complete -f -c pyenv -n '__fish_pyenv_needs_command' -a '(pyenv commands)'
|
||||
for cmd in (pyenv commands)
|
||||
complete -f -c pyenv -n "__fish_pyenv_using_command $cmd" -a "(pyenv completions $cmd)"
|
||||
complete -f -c pyenv -n "__fish_pyenv_using_command $cmd" -a \
|
||||
"(pyenv completions (commandline -opc)[2..-1])"
|
||||
end
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
set -e
|
||||
[ -n "$PYENV_DEBUG" ] && set -x
|
||||
|
||||
version="1.0.7"
|
||||
version="1.0.8"
|
||||
git_revision=""
|
||||
|
||||
if cd "${BASH_SOURCE%/*}" 2>/dev/null && git remote -v 2>/dev/null | grep -q pyenv; then
|
||||
|
||||
@@ -247,7 +247,7 @@ compute_sha2() {
|
||||
output="$("$openssl" dgst -sha256 2>/dev/null)" || return 1
|
||||
echo "${output##* }"
|
||||
elif type sha256sum &>/dev/null; then
|
||||
output="$(sha256sum --quiet)" || return 1
|
||||
output="$(sha256sum -b)" || return 1
|
||||
echo "${output% *}"
|
||||
else
|
||||
return 1
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
#require_gcc
|
||||
install_package "openssl-1.0.2g" "https://www.openssl.org/source/openssl-1.0.2g.tar.gz#b784b1b3907ce39abf4098702dade6365522a253ad1552e267a9a0e89594aa33" mac_openssl --if has_broken_mac_openssl
|
||||
install_package "readline-6.3" "https://ftpmirror.gnu.org/readline/readline-6.3.tar.gz#56ba6071b9462f980c5a72ab0023893b65ba6debb4eeb475d7a563dc65cafd43" standard --if has_broken_mac_readline
|
||||
install_hg "Python-2.7-dev" "https://hg.python.org/cpython" "2.7" standard verify_py27 ensurepip
|
||||
install_git "Python-2.7-dev" "https://github.com/python/cpython" "2.7" standard verify_py27 ensurepip
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
#require_gcc
|
||||
install_package "openssl-1.0.2g" "https://www.openssl.org/source/openssl-1.0.2g.tar.gz#b784b1b3907ce39abf4098702dade6365522a253ad1552e267a9a0e89594aa33" mac_openssl --if has_broken_mac_openssl
|
||||
install_package "readline-6.3" "https://ftpmirror.gnu.org/readline/readline-6.3.tar.gz#56ba6071b9462f980c5a72ab0023893b65ba6debb4eeb475d7a563dc65cafd43" standard --if has_broken_mac_readline
|
||||
install_hg "Python-3.2-dev" "https://hg.python.org/cpython" "3.2" standard verify_py32
|
||||
install_git "Python-3.2-dev" "https://github.com/python/cpython" "3.2" standard verify_py32
|
||||
install_package "setuptools-17.1.1" "https://pypi.python.org/packages/source/s/setuptools/setuptools-17.1.1.tar.gz#5bf42dbf406fd58a41029f53cffff1c90db5de1c5e0e560b5545cf2ec949c431" python
|
||||
install_package "pip-7.1.2" "https://pypi.python.org/packages/source/p/pip/pip-7.1.2.tar.gz#ca047986f0528cfa975a14fb9f7f106271d4e0c3fe1ddced6c1db2e7ae57a477" python
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
#require_gcc
|
||||
install_package "openssl-1.0.2g" "https://www.openssl.org/source/openssl-1.0.2g.tar.gz#b784b1b3907ce39abf4098702dade6365522a253ad1552e267a9a0e89594aa33" mac_openssl --if has_broken_mac_openssl
|
||||
install_package "readline-6.3" "https://ftpmirror.gnu.org/readline/readline-6.3.tar.gz#56ba6071b9462f980c5a72ab0023893b65ba6debb4eeb475d7a563dc65cafd43" standard --if has_broken_mac_readline
|
||||
install_hg "Python-3.3-dev" "https://hg.python.org/cpython" "3.3" standard verify_py33 ensurepip
|
||||
install_git "Python-3.3-dev" "https://github.com/python/cpython" "3.3" standard verify_py33 ensurepip
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
#require_gcc
|
||||
install_package "openssl-1.0.2g" "https://www.openssl.org/source/openssl-1.0.2g.tar.gz#b784b1b3907ce39abf4098702dade6365522a253ad1552e267a9a0e89594aa33" mac_openssl --if has_broken_mac_openssl
|
||||
install_package "readline-6.3" "https://ftpmirror.gnu.org/readline/readline-6.3.tar.gz#56ba6071b9462f980c5a72ab0023893b65ba6debb4eeb475d7a563dc65cafd43" standard --if has_broken_mac_readline
|
||||
install_hg "Python-3.4-dev" "https://hg.python.org/cpython" "3.4" standard verify_py34 ensurepip
|
||||
install_git "Python-3.4-dev" "https://github.com/python/cpython" "3.4" standard verify_py34 ensurepip
|
||||
|
||||
@@ -1,8 +0,0 @@
|
||||
#require_gcc
|
||||
install_package "openssl-1.0.2g" "https://www.openssl.org/source/openssl-1.0.2g.tar.gz#b784b1b3907ce39abf4098702dade6365522a253ad1552e267a9a0e89594aa33" mac_openssl --if has_broken_mac_openssl
|
||||
install_package "readline-6.3" "https://ftpmirror.gnu.org/readline/readline-6.3.tar.gz#56ba6071b9462f980c5a72ab0023893b65ba6debb4eeb475d7a563dc65cafd43" standard --if has_broken_mac_readline
|
||||
if has_tar_xz_support; then
|
||||
install_package "Python-3.4.6rc1" "https://www.python.org/ftp/python/3.4.6/Python-3.4.6rc1.tar.xz#240722b8325a2322793e809d8d194cc0f5eb90a886b1f5bf47f8b3c0936f4a8f" ldflags_dirs standard verify_py34 ensurepip
|
||||
else
|
||||
install_package "Python-3.4.6rc1" "https://www.python.org/ftp/python/3.4.6/Python-3.4.6rc1.tgz#fb8ece0a237c78863fac2841587b754dc6fd4dbbfe6f7fdce2534dce88bd5c5b" ldflags_dirs standard verify_py34 ensurepip
|
||||
fi
|
||||
@@ -1,4 +1,4 @@
|
||||
#require_gcc
|
||||
install_package "openssl-1.0.2g" "https://www.openssl.org/source/openssl-1.0.2g.tar.gz#b784b1b3907ce39abf4098702dade6365522a253ad1552e267a9a0e89594aa33" mac_openssl --if has_broken_mac_openssl
|
||||
install_package "readline-6.3" "https://ftpmirror.gnu.org/readline/readline-6.3.tar.gz#56ba6071b9462f980c5a72ab0023893b65ba6debb4eeb475d7a563dc65cafd43" standard --if has_broken_mac_readline
|
||||
install_hg "Python-3.5-dev" "https://hg.python.org/cpython" "3.5" standard verify_py35 ensurepip
|
||||
install_git "Python-3.5-dev" "https://github.com/python/cpython" "3.5" standard verify_py35 ensurepip
|
||||
|
||||
@@ -1,8 +0,0 @@
|
||||
#require_gcc
|
||||
install_package "openssl-1.0.2g" "https://www.openssl.org/source/openssl-1.0.2g.tar.gz#b784b1b3907ce39abf4098702dade6365522a253ad1552e267a9a0e89594aa33" mac_openssl --if has_broken_mac_openssl
|
||||
install_package "readline-6.3" "https://ftpmirror.gnu.org/readline/readline-6.3.tar.gz#56ba6071b9462f980c5a72ab0023893b65ba6debb4eeb475d7a563dc65cafd43" standard --if has_broken_mac_readline
|
||||
if has_tar_xz_support; then
|
||||
install_package "Python-3.5.3rc1" "https://www.python.org/ftp/python/3.5.3/Python-3.5.3rc1.tar.xz#7140482a99df2684333fa4c56d2381d1295a16c5672adfb42e963fe72aebc1ff" ldflags_dirs standard verify_py35 ensurepip
|
||||
else
|
||||
install_package "Python-3.5.3rc1" "https://www.python.org/ftp/python/3.5.3/Python-3.5.3rc1.tgz#6d685edf75b272b342eb9af683227ea536f7a5fdf60bfdb2ce673e102658e3cf" ldflags_dirs standard verify_py35 ensurepip
|
||||
fi
|
||||
@@ -1,4 +1,4 @@
|
||||
#require_gcc
|
||||
install_package "openssl-1.0.2g" "https://www.openssl.org/source/openssl-1.0.2g.tar.gz#b784b1b3907ce39abf4098702dade6365522a253ad1552e267a9a0e89594aa33" mac_openssl --if has_broken_mac_openssl
|
||||
install_package "readline-6.3" "https://ftpmirror.gnu.org/readline/readline-6.3.tar.gz#56ba6071b9462f980c5a72ab0023893b65ba6debb4eeb475d7a563dc65cafd43" standard --if has_broken_mac_readline
|
||||
install_hg "Python-3.6-dev" "https://hg.python.org/cpython" "3.6" standard verify_py36 ensurepip
|
||||
install_git "Python-3.6-dev" "https://github.com/python/cpython" "3.6" standard verify_py36 ensurepip
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
#require_gcc
|
||||
install_package "openssl-1.0.2g" "https://www.openssl.org/source/openssl-1.0.2g.tar.gz#b784b1b3907ce39abf4098702dade6365522a253ad1552e267a9a0e89594aa33" mac_openssl --if has_broken_mac_openssl
|
||||
install_package "readline-6.3" "https://ftpmirror.gnu.org/readline/readline-6.3.tar.gz#56ba6071b9462f980c5a72ab0023893b65ba6debb4eeb475d7a563dc65cafd43" standard --if has_broken_mac_readline
|
||||
install_hg "Python-3.7-dev" "https://hg.python.org/cpython" "default" standard verify_py37 ensurepip
|
||||
install_git "Python-3.7-dev" "https://github.com/python/cpython" master standard verify_py37 ensurepip
|
||||
|
||||
19
plugins/python-build/share/python-build/anaconda2-4.3.0
Normal file
19
plugins/python-build/share/python-build/anaconda2-4.3.0
Normal file
@@ -0,0 +1,19 @@
|
||||
case "$(anaconda_architecture 2>/dev/null || true)" in
|
||||
"Linux-x86" )
|
||||
install_script "Anaconda2-4.3.0-Linux-x86" "https://repo.continuum.io/archive/Anaconda2-4.3.0-Linux-x86.sh#b80d471839e8cf7b100e59308720cc13c141deb1ba903a4776c9a05f613e5078" "anaconda" verify_py27
|
||||
;;
|
||||
"Linux-x86_64" )
|
||||
install_script "Anaconda2-4.3.0-Linux-x86_64" "https://repo.continuum.io/archive/Anaconda2-4.3.0-Linux-x86_64.sh#7c52e6e99aabb24a49880130615a48e685da444c3c14eb48d6a65f3313bf745c" "anaconda" verify_py27
|
||||
;;
|
||||
"MacOSX-x86_64" )
|
||||
install_script "Anaconda2-4.2.1-MacOSX-x86_64" "https://repo.continuum.io/archive/Anaconda2-4.3.0-MacOSX-x86_64.sh#834ac0287062929ab5930661735ee617fd379bdfe79f3e0a20aebd614835b6c5" "anaconda" verify_py27
|
||||
;;
|
||||
* )
|
||||
{ echo
|
||||
colorize 1 "ERROR"
|
||||
echo ": The binary distribution of Anaconda2 is not available for $(anaconda_architecture 2>/dev/null || true)."
|
||||
echo
|
||||
} >&2
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
19
plugins/python-build/share/python-build/anaconda3-4.3.0
Normal file
19
plugins/python-build/share/python-build/anaconda3-4.3.0
Normal file
@@ -0,0 +1,19 @@
|
||||
case "$(anaconda_architecture 2>/dev/null || true)" in
|
||||
"Linux-x86" )
|
||||
install_script "Anaconda3-4.3.0-Linux-x86" "https://repo.continuum.io/archive/Anaconda3-4.3.0-Linux-x86.sh#f7ce2eeec3e42c2ba1ee3b9fcd670478fd30f4be547c6e0a675d183c4ca9dd9b" "anaconda" verify_py36
|
||||
;;
|
||||
"Linux-x86_64" )
|
||||
install_script "Anaconda3-4.3.0-Linux-x86_64" "https://repo.continuum.io/archive/Anaconda3-4.3.0-Linux-x86_64.sh#e9169c3a5029aa820393ac92704eb9ee0701778a085ca7bdc3c57b388ac1beb6" "anaconda" verify_py36
|
||||
;;
|
||||
"MacOSX-x86_64" )
|
||||
install_script "Anaconda3-4.3.0-MacOSX-x86_64" "https://repo.continuum.io/archive/Anaconda3-4.3.0-MacOSX-x86_64.sh#c53059b810c5e7a9a5ef9c46a7ed76675dfc7183f4ea867b4d81449cbd5a093d" "anaconda" verify_py36
|
||||
;;
|
||||
* )
|
||||
{ echo
|
||||
colorize 1 "ERROR"
|
||||
echo ": The binary distribution of Anaconda3 is not available for $(anaconda_architecture 2>/dev/null || true)."
|
||||
echo
|
||||
} >&2
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
Reference in New Issue
Block a user