1
0
mirror of https://github.com/pyenv/pyenv.git synced 2025-11-08 11:33:49 -05:00

Compare commits

..

73 Commits

Author SHA1 Message Date
Yamashita, Yuu
bed627addd v1.1.0 2017-06-16 01:03:32 +00:00
Yamashita, Yuu
29436ffe6d Merge pull request #932 from Samureus/pypy-5.8
Add Pypy 5.8.0
2017-06-12 11:46:36 +09:00
Samuel Villamonte
d82324ecf9 Fix wrong Portable PyPy links 2017-06-11 21:19:50 -05:00
Samuel Villamonte
1910e8667f Merge branch 'pypy-5.8' of github.com:Samureus/pyenv into pypy-5.8 2017-06-10 15:33:55 -05:00
Samuel Villamonte
cb579583bc Dropped support for all EOL x86/x64 Ubuntu distros to use Portable PyPy instead, per issue #925 comments 2017-06-10 15:32:32 -05:00
Samuel Villamonte
7a6cbbcd08 Fixed error message, PyPy3 2017-06-10 15:18:48 -05:00
Samuel Villamonte
3314420f2e Fix yet another checksum 2017-06-09 12:42:31 -05:00
Samuel Villamonte
1f3b0ae017 Fix portable pypy typo 2017-06-09 11:38:39 -05:00
Samuel Villamonte
d3e40c34bb Added pypy3.5-5.8.0 2017-06-09 11:37:20 -05:00
Samuel Villamonte
38e2067ad6 Added pypy2.7-5.8.0 2017-06-09 11:27:20 -05:00
Samuel Villamonte
e0b0147056 Fix sha256 sum 2017-06-09 11:06:42 -05:00
Samuel Villamonte
88e46c4b5a Added pypy3.5-portable-5.8.0 2017-06-09 11:03:34 -05:00
Samuel Villamonte
ca00b8e2e9 Added pypy2.7-portable-5.8.0 2017-06-09 10:43:38 -05:00
Samuel Villamonte
02001dbfb3 Added pypy3.5-5.8.0-src 2017-06-09 10:11:34 -05:00
Samuel Villamonte
033dae622d Added pypy2.7-5.8.0-src 2017-06-09 10:05:35 -05:00
Yamashita, Yuu
0849776306 Merge pull request #930 from shoichiaizawa/master
python-build: add anaconda[23]-4.4.0
2017-06-08 15:15:06 +09:00
Shoichi Aizawa
d5b193e5b0 python-build: add anaconda[23]-4.4.0 2017-06-08 13:33:18 +09:00
Roman Bolshakov
01d39850b5 Do not attempt to read .python-version directories (#606) 2017-06-06 13:09:45 +02:00
Yamashita, Yuu
d461b5f1d8 Merge pull request #927 from blueyed/merge-rbenv
Merge rbenv master
2017-06-06 09:38:33 +09:00
Daniel Hahler
3fd23431af Merge remote-tracking branch 'rbenv/master'
Conflicts:
	README.md
	libexec/pyenv---version
	libexec/pyenv-init
	libexec/rbenv
	libexec/rbenv-sh-shell
	libexec/rbenv-which
	test/init.bats
	test/shell.bats
2017-06-05 15:18:44 +02:00
Yamashita, Yuu
acbd736eb3 Merge pull request #920 from scop/micropython
Add micropython-dev
2017-05-29 11:05:18 +09:00
Ville Skyttä
fd1fb13016 Add micropython-dev 2017-05-28 14:04:42 +03:00
Mislav Marohnić
755c820724 Merge pull request #986 from jeffkowalski/fix_init
Prefer 'set' over 'setenv' for fish shell
2017-05-17 00:34:20 +02:00
Mislav Marohnić
b4330a48b1 Merge pull request #999 from jacob-on-github/patch-1
Make homebrew installation instructions more clear
2017-05-17 00:12:52 +02:00
Jeff Kowalski
a81da8d864 Revert quoting change in previous commit; adjust test to match code
Revert back to original quoting style used before previous commit.
Adjust init.bats to reflect changes for successful tests.
2017-05-16 13:36:06 -07:00
jacob-on-github
4e27113494 Update README.md
I work on a team that has followed the Homebrew installations. More than once we've missed the `rbenv init` instruction and it has caused headaches down the road. This formatting makes it harder to miss.
2017-05-16 14:29:46 -05:00
Yamashita, Yuu
3292200786 Merge pull request #909 from joesiewert/fix-command
Fix --enable-shared sample command
2017-05-12 12:38:05 +09:00
Joe Siewert
a91b36b236 Fix --enable-shared sample command 2017-05-11 14:23:31 -07:00
Yamashita, Yuu
d15f3888f0 Merge pull request #907 from LarsFronius/patch-1
Fixes pip-rehash to rehash if pip was called with a flag
2017-05-10 09:01:34 +09:00
Lars Fronius
1ec90481e8 Update pip 2017-05-09 12:51:50 +02:00
Lars Fronius
95818ab802 Update pip 2017-05-09 12:50:46 +02:00
Lars Fronius
bbd8f2c01e Fixes pip-rehash to rehash if pip was called with a flag
`pip -v install foobar` or `pip -q install foobar` did not trigger a rehash before. Now it should have the same behaviour as `pip install foobar`.
2017-05-09 12:43:51 +02:00
Yamashita, Yuu
30212f0054 Merge pull request #903 from webb04/fix-pyenv-shell-readme-link
Update link to pyenv shell documentation in README
2017-05-03 06:05:38 +09:00
Jamie Webb
27a7466f15 Update link to pyenv shell documentation in README 2017-05-02 16:52:53 +01:00
Yamashita, Yuu
23d819ed69 Merge pull request #899 from joliveros/fix-anaconda-build-when-prefix_path-exists
add -f to anaconda install script
2017-05-01 09:50:43 +09:00
Yamashita, Yuu
da80a3d3cc Merge pull request #901 from Bachmann1234/Bachmann1234-patch-1
Remove duplicate heading
2017-04-29 21:00:02 +09:00
Matt Bachmann
0a69dbd818 Remove duplicate heading
Link was pointing to this heading. It seemed incorrect
2017-04-29 07:14:46 -04:00
José Oliveros
aad7c0e055 add -f to anaconda install script 2017-04-27 18:51:30 -05:00
Yamashita, Yuu
19e70e34a0 Merge pull request #897 from proinsias/proinsias/miniconda3-4.3.11
Add miniconda3-4.2.12 and miniconda3-4.3.11
2017-04-26 13:18:25 +09:00
Francis T. O'Donovan
19048f1b60 Add miniconda3-4.2.12 and miniconda3-4.3.11 2017-04-25 15:08:02 -04:00
Yamashita, Yuu
7209cc490e Merge pull request #892 from menduo/master
replace github.com/yyuu with github.com/pyenv
2017-04-18 12:47:08 +09:00
menduo
f5e49fe6fa changelog: correct doc for version 1.0.9 2017-04-18 10:16:37 +08:00
menduo
ff666ab489 replace github.com/yyuu with github.com/pyenv 2017-04-17 11:59:53 +08:00
Jeff Kowalski
be2e606fbd Prefer 'set' over 'setenv' for fish shell
The setenv function in fish shell has changed dramatically in
75600b6b53
It now conforms to the csh version, which takes at most two arguments.
In this init script, the form
    setenv PATH prepend_something $PATH
had been used, which had too many arguments.
Since setenv isn't a native command in fish, a suitable replacement is
to use the "set -gx" command, which can consume multiple arguments.
2017-04-06 23:55:48 -07:00
Josh Friend
bcc8ab231a Add PyPy 5.7.1 portable 2017-04-04 11:05:32 -04:00
Josh Friend
29126e4965 Add PyPy3.5 5.7.1 2017-04-04 10:27:20 -04:00
Josh Friend
ae11c56565 Add PyPy 5.7.1
closes #888
2017-04-03 20:54:27 -04:00
Yamashita, Yuu
eef042ad89 Merge pull request #884 from pyenv/ci-workaround-v1.0.10
Workaround for CI failures with versions with multiple digits
2017-03-28 13:47:35 +09:00
Yamashita, Yuu
bec978d0f6 Workaround for CI failures with versions with multiple digits
https://travis-ci.org/pyenv/pyenv/jobs/215777826
2017-03-28 04:43:28 +00:00
Yamashita, Yuu
b3efcc9d15 v1.0.10 (fixes #878) 2017-03-28 02:40:09 +00:00
Yamashita, Yuu
fe1bd31443 Merge pull request #881 from Samureus/miniconda-latest
Update miniconda-latest and miniconda3-latest
2017-03-27 11:43:14 +09:00
Samuel Villamonte
45f1d19240 Merge pull request #880 from NickAnderegg/anaconda2-typos
python-build: Fix typo in MacOS packages for anaconda2-4.3.0/4.2.0
2017-03-26 14:16:25 -05:00
Samuel Villamonte
cb2a5b3cea miniconda3 no longer seems to have ARM or PPC *latest* versions, only numbered versions, and is now based on 3.6 2017-03-26 13:22:41 -05:00
Nick Anderegg
6404661372 python-build: Fix typo in MacOS packages for anaconda2-4.3.0/4.2.0
The package names in the python-build files for anaconda2-4.2.0 and
anaconda2-4.3.0 both had 'Anaconda2-4.2.1-MacOSX-x86_64' erroneously
listed as the package name. Anaconda2-4.2.1 is not a version of Anaconda
in existence. The URL arguments were correct, just not the package name
arguments.
2017-03-26 14:03:24 -04:00
Samuel Villamonte
69cfc1a3e2 Make miniconda-latest point to miniconda2-latest 2017-03-26 12:49:19 -05:00
Samuel Villamonte
00165f5796 Merge pull request #876 from NickAnderegg/anaconda-4.3.1
python-build: Add Anaconda2/Anaconda3 4.3.1
2017-03-25 23:52:32 -05:00
Nick Anderegg
c148ac9f89 python-build: Add Anaconda2/Anaconda3 4.3.1 2017-03-23 14:18:02 -04:00
Mislav Marohnić
4f8925abe7 Merge pull request #958 from jasonkarns/rbenv-variable-namespace
Conforms OLD_RBENV_VERSION to RBENV_* convention
2016-12-20 14:34:32 +01:00
Jason Karns
8eb97549e1 Conforms OLD_RBENV_VERSION to RBENV_* convention
Keeping rbenv-controlled variables to RBENV_* "namespace" helps with
discoverability (and tools like rbenv-env) but also consistency and a
very minor degree of safety/isolation from env impact.
2016-12-19 17:21:45 -05:00
Mislav Marohnić
e60ad4a090 rbenv 1.1.0 2016-11-25 21:11:08 +01:00
Mislav Marohnić
6ced4e25de Merge pull request #873 from dmerand/patch-1
Fish shell "." is deprecated in favor of "source"
2016-11-25 20:32:54 +01:00
Mislav Marohnić
2207c27cb4 Merge branch 'shell-undo' 2016-11-25 20:26:24 +01:00
Mislav Marohnić
c4d97ad392 Finalize rbenv shell - implementation
This ensures that OLD_RBENV_VERSION is never exported. This makes the
implementation a little bit more complex, since more logic needs to be
pushed down into eval'd code.
2016-11-25 20:24:16 +01:00
Mislav Marohnić
1b751261ce Merge pull request #914 from yyuu/sh-help-stderr
Help message should not be written to stdout for `sh-` commands
2016-11-25 19:06:01 +01:00
Mislav Marohnić
c7dcaf1259 Merge pull request #924 from jlduran/add-freebsd-to-configure-c-extensions
src/configure: Add FreeBSD
2016-09-27 15:17:33 -04:00
Mislav Marohnić
d0779fc8fb Expand literal tilde in PATH
The literal tilde in a PATH entry (e.g. `~/.rbenv/shims`) doesn't seem
to be supported by system `which` utility, but *does* seem to be
supported by `command -v` (used in `rbenv-which`) and `type -p`.

Therefore, we must strip away `~/.rbenv/shims` from PATH when looking up
executables for system Ruby, lest we risk infinite loop. We do so by
substituting any occurence of `~` in PATH with the value of `HOME`.
2016-09-09 10:29:12 +02:00
Jose Luis Duran
99342d642f src/configure: Add FreeBSD 2016-08-08 17:24:07 -03:00
Yamashita, Yuu
26ac59fd1d Write help message to stdout 2016-07-04 00:56:08 +00:00
Yamashita, Yuu
7860ad5268 Help message should not be written to stdout for sh- commands (yyuu/pyenv#650) 2016-07-01 00:08:19 +00:00
Donald Merand
121159c089 Merge branch 'patch-1' of https://github.com/dmerand/rbenv into patch-1 2016-02-20 10:28:19 -05:00
Donald Merand
8b0b51a166 convert references to '.' to 'source' for fish shell 2016-02-20 10:27:39 -05:00
Donald Merand
b81f0a2c42 Fish shell "." is deprecated in favor of "source"
Per [the fish documentation for "source"](file:///usr/local/Cellar/fish/2.2.0/share/doc/fish/commands.html#source) - ". (a single period) is an alias for the source command. The use of . is deprecated in favour of source, and . will be removed in a future version of fish."
2016-02-17 15:48:00 -05:00
Aaron Patterson
6a912bf104 add support for rbenv shell -
`rbenv shell -` allows you to switch to the previously activated ruby
version.  Similar to `cd -` or `git checkout -`.

This tries to implement `rbenv shell -` as proposed in #854.  However,
adding support seemed to break the "shell change version" test.  I'm not
very good at Bash programming, can someone tell me what is wrong with
what I'm doing?  I'd like to add a bit more functionality to this, but
I'm really just cargo cult programming Bash.

Thank you!

fix tests
2016-01-12 15:32:59 -08:00
47 changed files with 450 additions and 96 deletions

View File

@@ -1,5 +1,21 @@
## Version History
## Unreleased
## v1.1.0
* python-build: Add PyPy 5.7.1 (#888)
* pyenv: Merge rbenv master (#927)
* python-build: Add PyPy 5.8.0 (#932)
* python-build: Anaconda[23] 4.4.0
* python-build: Add micropython-dev
## 1.0.10
* python-build: Add Anaconda2/Anaconda3 4.3.1 (#876)
* python-build: Make miniconda-latest point to miniconda2-latest (#881)
* python-build: Fix typo in MacOS packages for anaconda2-4.3.0/4.2.0 (#880)
## 1.0.9
* pyenv: Migrate project site from https://github.com/yyuu/pyenv to https://github.com/pyenv/pyenv
@@ -147,12 +163,12 @@
* pyenv: Merge recent changes from rbenv as of 2015-12-14 (#504)
* python-build: Add a `OPENSSL_NO_SSL3` patch for CPython 2.6, 2.7, 3.0, 3.1, 3.2 and 3.3 series (#507, #511)
* python-build: Stopped using mirror at yyuu.github.io for CPython since http://www.python.org is on fast.ly
* python-build: Stopped using mirror at pyenv.github.io for CPython since http://www.python.org is on fast.ly
### 20151210
* pyenv: Add a default hook for Anaconda to look for original `$PATH` (#491)
* pyenv: Skip virtualenv aliases on `pyenv versions --skip-aliases` (yyuu/pyenv-virtualenv#126)
* pyenv: Skip virtualenv aliases on `pyenv versions --skip-aliases` (pyenv/pyenv-virtualenv#126)
* python-build: Add CPython 2.7.11, 3.5.1 (#494, #498)
* python-build: Update OpenSSL to 1.0.1q (#496)
* python-build: Adding SSL patch to build 2.7.3 on Debian (#495)
@@ -264,7 +280,7 @@
#### 20141211
* pyenv: Add built-in `pip-rehash` feature. You don't need to install [pyenv-pip-rehash](https://github.com/yyuu/pyenv-pip-rehash) anymore.
* pyenv: Add built-in `pip-rehash` feature. You don't need to install [pyenv-pip-rehash](https://github.com/pyenv/pyenv-pip-rehash) anymore.
* python-build: Add new CPython release; 2.7.9 (#284)
* python-build: Add new PyPy releases; pypy3-2.4.0, pypy3-2.4.0-src (#277)
* python-build: Add build definitions of PyPy nightly build
@@ -376,7 +392,7 @@
* python-build: Do not exit with errors even if some of modules are absent (#131)
* python-build: MacOSX was misspelled as MaxOSX in `anaconda_architecture` (#136)
* python-build: Use default `cc` as the C Compiler to build CPython (#148, #150)
* python-build: Display value from `pypy_architecture` and `anaconda_architecture` on errors (yyuu/pyenv-virtualenv#18)
* python-build: Display value from `pypy_architecture` and `anaconda_architecture` on errors (pyenv/pyenv-virtualenv#18)
* python-build: Remove old development version; 2.6-dev
* python-build: Update default setuptools version (3.3 -> 3.4.1)
@@ -430,7 +446,7 @@
* python-build: Activate friendly CPython during build if the one is not activated (8fa6b4a1847851919ad7857c6c42ed809a4d277b)
* python-build: Fix broken install.sh
* python-build: Import recent changes from ruby-build v20131225.1
* version-ext-compat: Removed from default plugin. Please use [pyenv-version-ext](https://github.com/yyuu/pyenv-version-ext) instead.
* version-ext-compat: Removed from default plugin. Please use [pyenv-version-ext](https://github.com/pyenv/pyenv-version-ext) instead.
#### 0.4.0-20131217

View File

@@ -1,7 +1,7 @@
# Command Reference
Like `git`, the `pyenv` command delegates to subcommands based on its
first argument.
first argument.
The most common subcommands are:
@@ -185,7 +185,7 @@ or, if you prefer 3.3.3 over 2.7.6,
## `pyenv install`
Install a Python version (using [`python-build`](https://github.com/yyuu/pyenv/tree/master/plugins/python-build)).
Install a Python version (using [`python-build`](https://github.com/pyenv/pyenv/tree/master/plugins/python-build)).
Usage: pyenv install [-f] [-kvp] <version>
pyenv install [-f] [-kvp] <definition-file>

View File

@@ -207,7 +207,7 @@ easy to fork and contribute any changes back upstream.
```
**Zsh note**: Modify your `~/.zshenv` file instead of `~/.bash_profile`.
**Ubuntu and Fedora note**: Modify your `~/.bashrc` file instead of `~/.bash_profile`.
**General warning**: There are some systems where the `BASH_ENV` variable is configured
to point to `.bashrc`. On such systems you should almost certainly put the abovementioned line
`eval "$(pyenv init -)` into `.bash_profile`, and **not** into `.bashrc`. Otherwise you
@@ -226,7 +226,7 @@ easy to fork and contribute any changes back upstream.
```
**NOTE:** If you need to pass configure option to build, please use
```CONFIGURE_OPTS``` environment variable.
**NOTE:** If you want to use proxy to download, please use `http_proxy` and `https_proxy`
environment variable.
@@ -281,8 +281,6 @@ uninstall from the system.
brew uninstall pyenv
## Command Reference
### Homebrew on Mac OS X
You can also install pyenv using the [Homebrew](http://brew.sh)
@@ -357,7 +355,7 @@ You can affect how pyenv operates with the following settings:
name | default | description
-----|---------|------------
`PYENV_VERSION` | | Specifies the Python version to be used.<br>Also see [`pyenv shell`](#pyenv-shell)
`PYENV_VERSION` | | Specifies the Python version to be used.<br>Also see [`pyenv shell`](https://github.com/pyenv/pyenv/blob/master/COMMANDS.md#pyenv-shell)
`PYENV_ROOT` | `~/.pyenv` | Defines the directory under which Python versions and shims reside.<br>Also see `pyenv root`
`PYENV_DEBUG` | | Outputs debug information.<br>Also as: `pyenv --debug <subcommand>`
`PYENV_HOOK_PATH` | [_see wiki_][hooks] | Colon-separated list of paths searched for pyenv hooks.

View File

@@ -12,7 +12,7 @@
set -e
[ -n "$PYENV_DEBUG" ] && set -x
version="1.0.9"
version="1.1.0"
git_revision=""
if cd "${BASH_SOURCE%/*}" 2>/dev/null && git remote -v 2>/dev/null | grep -q pyenv; then

View File

@@ -86,8 +86,8 @@ mkdir -p "${PYENV_ROOT}/"{shims,versions}
case "$shell" in
fish )
echo "setenv PATH '${PYENV_ROOT}/shims' \$PATH"
echo "setenv PYENV_SHELL $shell"
echo "set -gx PATH '${PYENV_ROOT}/shims' \$PATH"
echo "set -gx PYENV_SHELL $shell"
;;
* )
echo 'export PATH="'${PYENV_ROOT}'/shims:${PATH}"'
@@ -97,10 +97,7 @@ esac
completion="${root}/completions/pyenv.${shell}"
if [ -r "$completion" ]; then
case "$shell" in
fish ) echo ". '$completion'" ;;
* ) echo "source '$completion'" ;;
esac
echo "source '$completion'"
fi
if [ -z "$no_rehash" ]; then
@@ -117,7 +114,7 @@ function pyenv
switch "\$command"
case ${commands[*]}
. (pyenv "sh-\$command" \$argv|psub)
source (pyenv "sh-\$command" \$argv|psub)
case '*'
command pyenv "\$command" \$argv
end

View File

@@ -2,7 +2,8 @@
#
# Summary: Set or show the shell-specific Python version
#
# Usage: pyenv shell <version>
# Usage: pyenv shell <version>...
# pyenv shell -
# pyenv shell --unset
#
# Sets a shell-specific Python version by setting the `PYENV_VERSION'
@@ -12,6 +13,11 @@
# <version> should be a string matching a Python version known to pyenv.
# The special version string `system' will use your default system Python.
# Run `pyenv versions' for a list of available Python versions.
#
# When `-` is passed instead of the version string, the previously set
# version will be restored. With `--unset`, the `PYENV_VERSION`
# environment variable gets unset, restoring the environment to the
# state before the first `pyenv shell` call.
set -e
[ -n "$PYENV_DEBUG" ] && set -x
@@ -31,7 +37,7 @@ if [ -z "$versions" ]; then
echo "pyenv: no shell-specific version configured" >&2
exit 1
else
echo "echo \"\$PYENV_VERSION\""
echo 'echo "$PYENV_VERSION"'
exit
fi
fi
@@ -39,28 +45,76 @@ fi
if [ "$versions" = "--unset" ]; then
case "$shell" in
fish )
echo 'set -gu PYENV_VERSION_OLD "$PYENV_VERSION"'
echo "set -e PYENV_VERSION"
;;
* )
echo 'PYENV_VERSION_OLD="$PYENV_VERSION"'
echo "unset PYENV_VERSION"
;;
esac
exit
fi
if [ "$versions" = "-" ]; then
case "$shell" in
fish )
cat <<EOS
if set -q PYENV_VERSION_OLD
if [ -n "\$PYENV_VERSION_OLD" ]
set PYENV_VERSION_OLD_ "\$PYENV_VERSION"
set -gx PYENV_VERSION "\$PYENV_VERSION_OLD"
set -gu PYENV_VERSION_OLD "\$PYENV_VERSION_OLD_"
set -e PYENV_VERSION_OLD_
else
set -gu PYENV_VERSION_OLD "\$PYENV_VERSION"
set -e PYENV_VERSION
end
else
echo "pyenv: PYENV_VERSION_OLD is not set" >&2
false
end
EOS
;;
* )
cat <<EOS
if [ -n "\${PYENV_VERSION_OLD+x}" ]; then
if [ -n "\$PYENV_VERSION_OLD" ]; then
PYENV_VERSION_OLD_="\$PYENV_VERSION"
export PYENV_VERSION="\$PYENV_VERSION_OLD"
PYENV_VERSION_OLD="\$PYENV_VERSION_OLD_"
unset PYENV_VERSION_OLD_
else
PYENV_VERSION_OLD="\$PYENV_VERSION"
unset PYENV_VERSION
fi
else
echo "pyenv: PYENV_VERSION_OLD is not set" >&2
false
fi
EOS
;;
esac
exit
fi
# Make sure the specified version is installed.
if pyenv-prefix "${versions[@]}" >/dev/null; then
OLDIFS="$IFS"
IFS=: version="${versions[*]}"
IFS="$OLDIFS"
case "$shell" in
fish )
echo "setenv PYENV_VERSION \"${version}\""
;;
* )
echo "export PYENV_VERSION=\"${version}\""
;;
esac
if [ "$version" != "$PYENV_VERSION" ]; then
case "$shell" in
fish )
echo 'set -gu PYENV_VERSION_OLD "$PYENV_VERSION"'
echo "set -gx PYENV_VERSION \"$version\""
;;
* )
echo 'PYENV_VERSION_OLD="$PYENV_VERSION"'
echo "export PYENV_VERSION=\"${version}\""
;;
esac
fi
else
echo "false"
exit 1

View File

@@ -9,7 +9,7 @@ target_dir="$1"
find_local_version_file() {
local root="$1"
while ! [[ "$root" =~ ^//[^/]*$ ]]; do
if [ -e "${root}/.python-version" ]; then
if [ -f "${root}/.python-version" ]; then
echo "${root}/.python-version"
return 0
fi

View File

@@ -18,7 +18,7 @@ fi
remove_from_path() {
local path_to_remove="$1"
local path_before
local result=":$PATH:"
local result=":${PATH//\~/$HOME}:"
while [ "$path_before" != "$result" ]; do
path_before="$result"
result="${result//:$path_to_remove:/:}"

View File

@@ -152,13 +152,13 @@ $ cat fix1.patch fix2.patch | pyenv install --patch 2.7.10
You can build CPython with `--enable-shared` to install a version with
shared object.
If `--enabled-shared` was found in `PYTHON_CONFIGURE_OPTS` or `CONFIGURE_OPTS`,
If `--enable-shared` was found in `PYTHON_CONFIGURE_OPTS` or `CONFIGURE_OPTS`,
`python-build` will automatically set `RPATH` to the pyenv's prefix directory.
This means you don't have to set `LD_LIBRARY_PATH` or `DYLD_LIBRARY_PATH` for
the version(s) installed with `--enable-shared`.
```sh
$ env PYTHON_CONFIGURE_OPTS="--enable-shared` pyenv install 2.7.9
$ env PYTHON_CONFIGURE_OPTS="--enable-shared" pyenv install 2.7.9
```
### Checksum verification

View File

@@ -938,6 +938,20 @@ build_package_ironpython_builder() {
( cd "Stage/Release/IronPython-"* && build_package_ironpython )
}
build_package_micropython() {
if [ "${MAKEOPTS+defined}" ]; then
MAKE_OPTS="$MAKEOPTS"
elif [ -z "${MAKE_OPTS+defined}" ]; then
MAKE_OPTS="-j $(num_cpu_cores)"
fi
{ cd unix
"$MAKE" $MAKE_OPTS axtls
"$MAKE" $MAKE_OPTS
"$MAKE" install $MAKE_INSTALL_OPTS PREFIX="${PREFIX_PATH}"
( cd "${PREFIX_PATH}/bin" && ln -fs micropython python )
}>&4 2>&1
}
pypy_architecture() {
case "$(uname -s)" in
"Darwin" ) echo "osx64" ;;
@@ -1027,7 +1041,7 @@ anaconda_architecture() {
build_package_anaconda() {
local package_name="$1"
{ bash "${package_name}.sh" -b -p "${PREFIX_PATH}"
{ bash "${package_name}.sh" -f -b -p "${PREFIX_PATH}"
} >&4 2>&1
}

View File

@@ -3,7 +3,7 @@ install_package "openssl-1.0.2k" "https://www.openssl.org/source/openssl-1.0.2k.
install_package "readline-6.3" "https://ftpmirror.gnu.org/readline/readline-6.3.tar.gz#56ba6071b9462f980c5a72ab0023893b65ba6debb4eeb475d7a563dc65cafd43" standard --if has_broken_mac_readline
install_package "Python-3.0.1" "https://www.python.org/ftp/python/3.0.1/Python-3.0.1.tgz#7d5f2feae9035f1d3d9e6bb7f092dbf374d6bb4b25abd0d2d11f13bba1cb04de" ldflags_dirs standard verify_py30
if [[ "Darwin" == "$(uname -s)" ]]; then
# https://github.com/yyuu/pyenv/issues/456
# https://github.com/pyenv/pyenv/issues/456
{ echo
colorize 1 "WARNING"
echo ": pyenv cannot install setuptools-1.4.2 to CPython 3.0.1 on OS X."

View File

@@ -6,7 +6,7 @@ case "$(anaconda_architecture 2>/dev/null || true)" in
install_script "Anaconda2-4.2.0-Linux-x86_64" "https://repo.continuum.io/archive/Anaconda2-4.2.0-Linux-x86_64.sh#beee286d24fb37dd6555281bba39b3deb5804baec509a9dc5c69185098cf661a" "anaconda" verify_py27
;;
"MacOSX-x86_64" )
install_script "Anaconda2-4.2.1-MacOSX-x86_64" "https://repo.continuum.io/archive/Anaconda2-4.2.0-MacOSX-x86_64.sh#a8b3ef86233635d9dcc3499dc384980762a0b42d354a318f8307029c399db452" "anaconda" verify_py27
install_script "Anaconda2-4.2.0-MacOSX-x86_64" "https://repo.continuum.io/archive/Anaconda2-4.2.0-MacOSX-x86_64.sh#a8b3ef86233635d9dcc3499dc384980762a0b42d354a318f8307029c399db452" "anaconda" verify_py27
;;
* )
{ echo

View File

@@ -6,7 +6,7 @@ case "$(anaconda_architecture 2>/dev/null || true)" in
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
install_script "Anaconda2-4.3.0-MacOSX-x86_64" "https://repo.continuum.io/archive/Anaconda2-4.3.0-MacOSX-x86_64.sh#834ac0287062929ab5930661735ee617fd379bdfe79f3e0a20aebd614835b6c5" "anaconda" verify_py27
;;
* )
{ echo

View File

@@ -0,0 +1,19 @@
case "$(anaconda_architecture 2>/dev/null || true)" in
"Linux-x86" )
install_script "Anaconda2-4.3.1-Linux-x86" "https://repo.continuum.io/archive/Anaconda2-4.3.1-Linux-x86.sh#4519ac724d5120d21bb80289c5509c0d1fd9f99c6e9b9a4c6fb352d8bda4aede" "anaconda" verify_py27
;;
"Linux-x86_64" )
install_script "Anaconda2-4.3.1-Linux-x86_64" "https://repo.continuum.io/archive/Anaconda2-4.3.1-Linux-x86_64.sh#e9b8f2645df6b1527ba56d61343162e0794acc3ee8dde2a6bba353719e2d878d" "anaconda" verify_py27
;;
"MacOSX-x86_64" )
install_script "Anaconda2-4.3.1-MacOSX-x86_64" "https://repo.continuum.io/archive/Anaconda2-4.3.1-MacOSX-x86_64.sh#35261360f2b01793f441b29715a94052dceaef1137866b7323c76be83c5bcc1a" "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

View File

@@ -0,0 +1,19 @@
case "$(anaconda_architecture 2>/dev/null || true)" in
"Linux-x86" )
install_script "Anaconda2-4.4.0-Linux-x86" "https://repo.continuum.io/archive/Anaconda2-4.4.0-Linux-x86.sh#452aa91ac83d3b6a68b79cea3042170ec591d468d6966307ff9af18fdbce9fbf" "anaconda" verify_py27
;;
"Linux-x86_64" )
install_script "Anaconda2-4.4.0-Linux-x86_64" "https://repo.continuum.io/archive/Anaconda2-4.4.0-Linux-x86_64.sh#2d30b91ed4d215b6b4a15162a3389e9057b15445a0c02da71bd7bd272e7b824e" "anaconda" verify_py27
;;
"MacOSX-x86_64" )
install_script "Anaconda2-4.4.0-MacOSX-x86_64" "https://repo.continuum.io/archive/Anaconda2-4.4.0-MacOSX-x86_64.sh#ab95aef1110c2a385fd39a17e5f11dfbaabce25c1a5944598de164d7a2772969" "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

View File

@@ -0,0 +1,19 @@
case "$(anaconda_architecture 2>/dev/null || true)" in
"Linux-x86" )
install_script "Anaconda3-4.3.1-Linux-x86" "https://repo.continuum.io/archive/Anaconda3-4.3.1-Linux-x86.sh#7b70bdba282a18ddbdc167afe8131f7532076cb1df8d3fbbd13e79ca3afaa2c1" "anaconda" verify_py36
;;
"Linux-x86_64" )
install_script "Anaconda3-4.3.1-Linux-x86_64" "https://repo.continuum.io/archive/Anaconda3-4.3.1-Linux-x86_64.sh#4447b93d2c779201e5fb50cfc45de0ec96c3804e7ad0fe201ab6b99f73e90302" "anaconda" verify_py36
;;
"MacOSX-x86_64" )
install_script "Anaconda3-4.3.1-MacOSX-x86_64" "https://repo.continuum.io/archive/Anaconda3-4.3.1-MacOSX-x86_64.sh#a42267203e207cb5e0f539e0d879ead12e436311825c7114d0edd880d001b539" "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

View File

@@ -0,0 +1,19 @@
case "$(anaconda_architecture 2>/dev/null || true)" in
"Linux-x86" )
install_script "Anaconda3-4.4.0-Linux-x86" "https://repo.continuum.io/archive/Anaconda3-4.4.0-Linux-x86.sh#b0e492206d43067314b25963bc7d1f012096ca0323b7629f4ebcd071b03905b5" "anaconda" verify_py36
;;
"Linux-x86_64" )
install_script "Anaconda3-4.4.0-Linux-x86_64" "https://repo.continuum.io/archive/Anaconda3-4.4.0-Linux-x86_64.sh#3301b37e402f3ff3df216fe0458f1e6a4ccbb7e67b4d626eae9651de5ea3ab63" "anaconda" verify_py36
;;
"MacOSX-x86_64" )
install_script "Anaconda3-4.4.0-MacOSX-x86_64" "https://repo.continuum.io/archive/Anaconda3-4.4.0-MacOSX-x86_64.sh#10fe58f09ae524df2548d17b8bb1e75db17da597a6ec10d695ce01387a2d7422" "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

View File

@@ -2,5 +2,5 @@ require_java
install_hg "jython-2.5-dev" "https://hg.python.org/jython" "2.5" jython_builder
install_package "setuptools-1.4.2" "https://pypi.python.org/packages/source/s/setuptools/setuptools-1.4.2.tar.gz#263986a60a83aba790a5bffc7d009ac88114ba4e908e5c90e453b3bf2155dbbd" python
# pip (>= 1.3) does not work properly since it uses HTTPS for downloads
# * https://github.com/yyuu/pyenv/issues/15
# * https://github.com/pyenv/pyenv/issues/15
install_package "pip-1.2.1" "https://pypi.python.org/packages/source/p/pip/pip-1.2.1.tar.gz#12a9302acfca62cdc7bc5d83386cac3e0581db61ac39acdb3a4e766a16b88eb1" python

View File

@@ -1,9 +1,9 @@
require_java
install_jar "jython-2.5.0" "https://downloads.sourceforge.net/project/jython/jython/2.5.0/jython_installer-2.5.0.jar#e3d8209ef9eb143df8101a5da6b3482cf457084e3a6247031fd510d71c13ab98" jython
# distribute (>= 0.33) does not support Jython prior to 2.5.2
# * https://github.com/yyuu/pyenv/issues/15
# * https://github.com/pyenv/pyenv/issues/15
# * https://bitbucket.org/tarek/distribute/issue/367/importing-setuptoolssandbox-fails-on
install_package "distribute-0.6.32" "https://pypi.python.org/packages/source/d/distribute/distribute-0.6.32.tar.gz#8970cd1e148b5d1fea9430584aea66c45ea22d80e0933393ec49ebc388f718df" python
# pip (>= 1.3) does not work properly since it uses HTTPS for downloads
# * https://github.com/yyuu/pyenv/issues/15
# * https://github.com/pyenv/pyenv/issues/15
install_package "pip-1.2.1" "https://pypi.python.org/packages/source/p/pip/pip-1.2.1.tar.gz#12a9302acfca62cdc7bc5d83386cac3e0581db61ac39acdb3a4e766a16b88eb1" python

View File

@@ -1,9 +1,9 @@
require_java
install_jar "jython-2.5.1" "https://downloads.sourceforge.net/project/jython/jython/2.5.1/jython_installer-2.5.1.jar#229dfd1ed9728aa7e00c71f111d08fa777a4edcd03383779c74216765098f9c5" jython
# distribute (>= 0.33) does not support Jython prior to 2.5.2
# * https://github.com/yyuu/pyenv/issues/15
# * https://github.com/pyenv/pyenv/issues/15
# * https://bitbucket.org/tarek/distribute/issue/367/importing-setuptoolssandbox-fails-on
install_package "distribute-0.6.32" "https://pypi.python.org/packages/source/d/distribute/distribute-0.6.32.tar.gz#8970cd1e148b5d1fea9430584aea66c45ea22d80e0933393ec49ebc388f718df" python
# pip (>= 1.3) does not work properly since it uses HTTPS for downloads
# * https://github.com/yyuu/pyenv/issues/15
# * https://github.com/pyenv/pyenv/issues/15
install_package "pip-1.2.1" "https://pypi.python.org/packages/source/p/pip/pip-1.2.1.tar.gz#12a9302acfca62cdc7bc5d83386cac3e0581db61ac39acdb3a4e766a16b88eb1" python

View File

@@ -2,5 +2,5 @@ require_java
install_jar "jython-2.5.2" "https://downloads.sourceforge.net/project/jython/jython/2.5.2/jython_installer-2.5.2.jar#1b7168b961e31ddd89012a36cde611c340dadfd8b60b81c4248b026730ee2f29" jython
install_package "setuptools-1.4.2" "https://pypi.python.org/packages/source/s/setuptools/setuptools-1.4.2.tar.gz#263986a60a83aba790a5bffc7d009ac88114ba4e908e5c90e453b3bf2155dbbd" python
# pip (>= 1.3) does not work properly since it uses HTTPS for downloads
# * https://github.com/yyuu/pyenv/issues/15
# * https://github.com/pyenv/pyenv/issues/15
install_package "pip-1.2.1" "https://pypi.python.org/packages/source/p/pip/pip-1.2.1.tar.gz#12a9302acfca62cdc7bc5d83386cac3e0581db61ac39acdb3a4e766a16b88eb1" python

View File

@@ -2,5 +2,5 @@ require_java
install_jar "jython-2.5.3" "https://search.maven.org/remotecontent?filepath=org/python/jython-installer/2.5.3/jython-installer-2.5.3.jar#05405966cdfa57abc8e705dd6aab92b8240097ce709fb916c8a0dbcaa491f99e" jython
install_package "setuptools-1.4.2" "https://pypi.python.org/packages/source/s/setuptools/setuptools-1.4.2.tar.gz#263986a60a83aba790a5bffc7d009ac88114ba4e908e5c90e453b3bf2155dbbd" python
# pip (>= 1.3) does not work properly since it uses HTTPS for downloads
# * https://github.com/yyuu/pyenv/issues/15
# * https://github.com/pyenv/pyenv/issues/15
install_package "pip-1.2.1" "https://pypi.python.org/packages/source/p/pip/pip-1.2.1.tar.gz#12a9302acfca62cdc7bc5d83386cac3e0581db61ac39acdb3a4e766a16b88eb1" python

View File

@@ -2,5 +2,5 @@ require_java
install_jar "jython-2.5.4-rc1" "https://search.maven.org/remotecontent?filepath=org/python/jython-installer/2.5.4-rc1/jython-installer-2.5.4-rc1.jar#2fa6821ef506804ca77f87631a21878c11d743f8a7fa9ed26e55dfd7696204d1" jython
install_package "setuptools-1.4.2" "https://pypi.python.org/packages/source/s/setuptools/setuptools-1.4.2.tar.gz#263986a60a83aba790a5bffc7d009ac88114ba4e908e5c90e453b3bf2155dbbd" python
# pip (>= 1.3) does not work properly since it uses HTTPS for downloads
# * https://github.com/yyuu/pyenv/issues/15
# * https://github.com/pyenv/pyenv/issues/15
install_package "pip-1.2.1" "https://pypi.python.org/packages/source/p/pip/pip-1.2.1.tar.gz#12a9302acfca62cdc7bc5d83386cac3e0581db61ac39acdb3a4e766a16b88eb1" python

View File

@@ -2,5 +2,5 @@ require_java
unrequire_python27
install_hg "jython-dev" "https://hg.python.org/jython" "default" jython_builder ez_setup
# pip (>= 1.3) does not work properly since it uses HTTPS for downloads
# * https://github.com/yyuu/pyenv/issues/15
# * https://github.com/pyenv/pyenv/issues/15
install_package "pip-1.2.1" "https://pypi.python.org/packages/source/p/pip/pip-1.2.1.tar.gz#12a9302acfca62cdc7bc5d83386cac3e0581db61ac39acdb3a4e766a16b88eb1" python

View File

@@ -0,0 +1,2 @@
#require_gcc
install_git micropython-dev https://github.com/micropython/micropython master micropython

View File

@@ -1,25 +1 @@
case "$(anaconda_architecture 2>/dev/null || true)" in
"Linux-armv7l" )
install_script "Miniconda-latest-Linux-armv7l" "https://repo.continuum.io/miniconda/Miniconda-latest-Linux-armv7l.sh" "miniconda" verify_py27
;;
"Linux-ppc64le" )
install_script "Miniconda-latest-Linux-ppc64le" "https://repo.continuum.io/miniconda/Miniconda-latest-Linux-ppc64le.sh" "miniconda" verify_py27
;;
"Linux-x86" )
install_script "Miniconda-latest-Linux-x86" "https://repo.continuum.io/miniconda/Miniconda-latest-Linux-x86.sh" "miniconda" verify_py27
;;
"Linux-x86_64" )
install_script "Miniconda-latest-Linux-x86_64" "https://repo.continuum.io/miniconda/Miniconda-latest-Linux-x86_64.sh" "miniconda" verify_py27
;;
"MacOSX-x86_64" )
install_script "Miniconda-latest-MacOSX-x86_64" "https://repo.continuum.io/miniconda/Miniconda-latest-MacOSX-x86_64.sh" "miniconda" verify_py27
;;
* )
{ echo
colorize 1 "ERROR"
echo ": The binary distribution of Miniconda is not available for $(anaconda_architecture 2>/dev/null || true)."
echo
} >&2
exit 1
;;
esac
source "${BASH_SOURCE%/*}/miniconda2-latest"

View File

@@ -0,0 +1,19 @@
case "$(anaconda_architecture 2>/dev/null || true)" in
"Linux-x86" )
install_script "Miniconda3-4.2.12-Linux-x86" "https://repo.continuum.io/miniconda/Miniconda3-4.2.12-Linux-x86.sh#64dae61d366ada1d5c6baf345a466c95b68eb6df574ee454fc234a7a99943702" "miniconda" verify_py35
;;
"Linux-x86_64" )
install_script "Miniconda3-4.2.12-Linux-x86_64" "https://repo.continuum.io/miniconda/Miniconda3-4.2.12-Linux-x86_64.sh#c59b3dd3cad550ac7596e0d599b91e75d88826db132e4146030ef471bb434e9a" "miniconda" verify_py35
;;
"MacOSX-x86_64" )
install_script "Miniconda3-4.2.12-MacOSX-x86_64" "https://repo.continuum.io/miniconda/Miniconda3-4.2.12-MacOSX-x86_64.sh#da15fd52352dcefc944a32cd54c8ec3cfc68cfbbadcb86dbea72fe681c7a7a70" "miniconda" verify_py35
;;
* )
{ echo
colorize 1 "ERROR"
echo ": The binary distribution of Miniconda is not available for $(anaconda_architecture 2>/dev/null || true)."
echo
} >&2
exit 1
;;
esac

View File

@@ -0,0 +1,19 @@
case "$(anaconda_architecture 2>/dev/null || true)" in
"Linux-x86" )
install_script "Miniconda3-4.3.11-Linux-x86" "https://repo.continuum.io/miniconda/Miniconda3-4.3.11-Linux-x86.sh#ebda072999dd24bbede7cf3d99fb781187aa9148f71826edadbac0a55ce278cb" "miniconda" verify_py35
;;
"Linux-x86_64" )
install_script "Miniconda3-4.3.11-Linux-x86_64" "https://repo.continuum.io/miniconda/Miniconda3-4.3.11-Linux-x86_64.sh#b9fe70ce7b6fa8df05abfb56995959b897d0365299f5046063bc236843474fb8" "miniconda" verify_py35
;;
"MacOSX-x86_64" )
install_script "Miniconda3-4.3.11-MacOSX-x86_64" "https://repo.continuum.io/miniconda/Miniconda3-4.3.11-MacOSX-x86_64.sh#81f127e36249064d0f87b5d5dfa4d6094c6d5998f36a7bc80cb5028b4e32b7a2" "miniconda" verify_py35
;;
* )
{ echo
colorize 1 "ERROR"
echo ": The binary distribution of Miniconda is not available for $(anaconda_architecture 2>/dev/null || true)."
echo
} >&2
exit 1
;;
esac

View File

@@ -1,23 +1,17 @@
case "$(anaconda_architecture 2>/dev/null || true)" in
"Linux-armv7l" )
install_script "Miniconda3-latest-Linux-armv7l" "https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-armv7l.sh" "miniconda" verify_py35
;;
"Linux-ppc64le" )
install_script "Miniconda3-latest-Linux-ppc64le" "https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-ppc64le.sh" "miniconda" verify_py35
;;
"Linux-x86" )
install_script "Miniconda3-latest-Linux-x86" "https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86.sh" "miniconda" verify_py35
install_script "Miniconda3-latest-Linux-x86" "https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86.sh" "miniconda" verify_py36
;;
"Linux-x86_64" )
install_script "Miniconda3-latest-Linux-x86_64" "https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh" "miniconda" verify_py35
install_script "Miniconda3-latest-Linux-x86_64" "https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh" "miniconda" verify_py36
;;
"MacOSX-x86_64" )
install_script "Miniconda3-latest-MacOSX-x86_64" "https://repo.continuum.io/miniconda/Miniconda3-latest-MacOSX-x86_64.sh" "miniconda" verify_py35
install_script "Miniconda3-latest-MacOSX-x86_64" "https://repo.continuum.io/miniconda/Miniconda3-latest-MacOSX-x86_64.sh" "miniconda" verify_py36
;;
* )
{ echo
colorize 1 "ERROR"
echo ": The binary distribution of Miniconda3 is not available for $(anaconda_architecture 2>/dev/null || true)."
echo ": The binary distribution of Miniconda3-latest is not available for $(anaconda_architecture 2>/dev/null || true)."
echo
} >&2
exit 1

View File

@@ -0,0 +1 @@
source "${BASH_SOURCE%/*}/pypy2-5.7.1"

View File

@@ -0,0 +1 @@
source "${BASH_SOURCE%/*}/pypy2-5.7.2-src"

View File

@@ -0,0 +1,42 @@
case "$(pypy_architecture 2>/dev/null || true)" in
"linux" )
if require_distro "Ubuntu 12.04" "Ubuntu 12.10" "Ubuntu 13.04" "Ubuntu 13.10" "Ubuntu 14.04" 1>/dev/null 2>&1; then
install_package "pypy2-v5.7.1-linux32" "https://bitbucket.org/pypy/pypy/downloads/pypy2-v5.7.1-linux32.tar.bz2#f125a227f8c814ba1698168a639ea6ca59bb69c280529639eed29076d8429a73" "pypy" verify_py27 ensurepip
fi
;;
"linux-armel" )
require_distro "Ubuntu 12.04" || true
install_package "pypy2-v5.7.1-linux-armel" "https://bitbucket.org/pypy/pypy/downloads/pypy2-v5.7.1-linux-armel.tar.bz2#591a4a73cc945a1125848f3615a28559692db8febf677d7087eaef40cb119a8d" "pypy" verify_py27 ensurepip
;;
"linux-armhf" )
if [[ "$(cat /etc/issue 2>/dev/null || true)" == "Raspbian"* ]]; then
install_package "pypy2-v5.7.1-linux-armhf-raspbian" "https://bitbucket.org/pypy/pypy/downloads/pypy2-v5.7.1-linux-armhf-raspbian.tar.bz2#67544f8c4b284db71cf1af74edef290722f97f82476cbdaff2015fdab244c6ee" "pypy" verify_py27 ensurepip
else
require_distro "Ubuntu 13.04" || true
install_package "pypy2-v5.7.1-linux-armhf-raring" "https://bitbucket.org/pypy/pypy/downloads/pypy2-v5.7.1-linux-armhf-raring.tar.bz2#c1b1a0968b22c58672f7492dc7900bc85e3bd02c791f219f31401a00ef387207" "pypy" verify_py27 ensurepip
fi
;;
"linux64" )
if require_distro "Ubuntu 12.04" "Ubuntu 12.10" "Ubuntu 13.04" "Ubuntu 13.10" "Ubuntu 14.04" 1>/dev/null 2>&1; then
install_package "pypy2-v5.7.1-linux64" "https://bitbucket.org/pypy/pypy/downloads/pypy2-v5.7.1-linux64.tar.bz2#c4fa3da42156bed4a9d912433b618a141e0c5161d7cc8c328786736ea5d1c2da" "pypy" verify_py27 ensurepip
else
install_package "pypy-5.7.1-linux_x86_64-portable" "https://bitbucket.org/squeaky/portable-pypy/downloads/pypy-5.7.1-linux_x86_64-portable.tar.bz2#8a6a194963eb58d582413c4bcdef6119f9f9f117a05032d1fb13192d934510c6" "pypy" verify_py27 ensurepip
fi
;;
"osx64" )
install_package "pypy2-v5.7.1-osx64" "https://bitbucket.org/pypy/pypy/downloads/pypy2-v5.7.1-osx64.tar.bz2#4e99ba356432861534917a9477ace0ccee617bd631512759a530f8383e153a3d" "pypy" verify_py27 ensurepip
;;
"win32" )
# FIXME: never tested on Windows
install_zip "pypy2-v5.7.1-win32" "https://bitbucket.org/pypy/pypy/downloads/pypy2-v5.7.1-win32.zip#a3ba7c946635236836f8536d8767a0f456b3b9a86876cb5c3173a04522bf451b" "pypy" verify_py27 ensurepip
;;
* )
{ echo
colorize 1 "ERROR"
echo ": The binary distribution of PyPy is not available for $(pypy_architecture 2>/dev/null || true)."
echo "try 'pypy2-5.7.0-src' to build from source."
echo
} >&2
exit 1
;;
esac

View File

@@ -0,0 +1,2 @@
require_gcc
install_package "pypy2-v5.7.0-src" "https://bitbucket.org/pypy/pypy/downloads/pypy2-v5.7.0-src.tar.bz2#e522ea7ca51b16ee5505f22b86803664b762a263a6d69ba84c359fcf8365ad3e" "pypy_builder" verify_py27 ensurepip

View File

@@ -0,0 +1,42 @@
case "$(pypy_architecture 2>/dev/null || true)" in
"linux" )
if require_distro "Ubuntu 14.04" 1>/dev/null 2>&1; then
install_package "pypy2-v5.8.0-linux32" "https://bitbucket.org/pypy/pypy/downloads/pypy2-v5.8.0-linux32.tar.bz2#a0b125a5781f7e5ddfc3baca46503b14f4ee6a0e234e8d72bfcf3afdf4120bef" "pypy" verify_py27 ensurepip
fi
;;
"linux-armel" )
require_distro "Ubuntu 12.04" || true
install_package "pypy2-v5.8.0-linux-armel" "https://bitbucket.org/pypy/pypy/downloads/pypy2-v5.8.0-linux-armel.tar.bz2#28b7fd0cc7418ffc66c71520728e87941be40ebf4b82675c57e25598a2a702b0" "pypy" verify_py27 ensurepip
;;
"linux-armhf" )
if [[ "$(cat /etc/issue 2>/dev/null || true)" == "Raspbian"* ]]; then
install_package "pypy2-v5.8.0-linux-armhf-raspbian" "https://bitbucket.org/pypy/pypy/downloads/pypy2-v5.8.0-linux-armhf-raspbian.tar.bz2#da58279a0e3706889fc0df06087cea08f8cfd22322139fe9bae73ef9b2d119b7" "pypy" verify_py27 ensurepip
else
require_distro "Ubuntu 13.04" || true
install_package "pypy2-v5.8.0-linux-armhf-raring" "https://bitbucket.org/pypy/pypy/downloads/pypy2-v5.8.0-linux-armhf-raring.tar.bz2#ddceca9c5c9a456d4bf1beab177660adffbbdf255a922244e1cc05f20318be46" "pypy" verify_py27 ensurepip
fi
;;
"linux64" )
if require_distro "Ubuntu 14.04" 1>/dev/null 2>&1; then
install_package "pypy2-v5.8.0-linux64" "https://bitbucket.org/pypy/pypy/downloads/pypy2-v5.8.0-linux64.tar.bz2#6274292d0e954a2609b15978cde6efa30942ba20aa5d2acbbf1c70c0a54e9b1e" "pypy" verify_py27 ensurepip
else
install_package "pypy-5.8-linux_x86_64-portable" "https://bitbucket.org/squeaky/portable-pypy/downloads/pypy-5.8-linux_x86_64-portable.tar.bz2#337fd7e947a74cb09253f5ff330fb1be471b1d7a64c2d0340ac387920e71bf3c" "pypy" verify_py27 ensurepip
fi
;;
"osx64" )
install_package "pypy2-v5.8.0-osx64" "https://bitbucket.org/pypy/pypy/downloads/pypy2-v5.8.0-osx64.tar.bz2#04b61d1cf13aaca6d0420e854c820b8bd049dc88be16c02542abe8ca26eb075c" "pypy" verify_py27 ensurepip
;;
"win32" )
# FIXME: never tested on Windows
install_zip "pypy2-v5.8.0-win32" "https://bitbucket.org/pypy/pypy/downloads/pypy2-v5.8.0-win32.zip#43d6217653e5bdc09e3ff8cb56fb52c4eb019429063d80107be4e88eef79ea8d" "pypy" verify_py27 ensurepip
;;
* )
{ echo
colorize 1 "ERROR"
echo ": The binary distribution of PyPy is not available for $(pypy_architecture 2>/dev/null || true)."
echo "try 'pypy2.7-5.8.0-src' to build from source."
echo
} >&2
exit 1
;;
esac

View File

@@ -0,0 +1,2 @@
require_gcc
install_package "pypy2-v5.8.0-src" "https://bitbucket.org/pypy/pypy/downloads/pypy2-v5.8.0-src.tar.bz2#504c2d522595baf8775ae1045a217a2b120732537861d31b889d47c340b58bd5" "pypy_builder" verify_py27 ensurepip

View File

@@ -0,0 +1,13 @@
case "$(pypy_architecture 2>/dev/null || true)" in
"linux64" )
install_package "pypy-5.8-linux_x86_64-portable" "https://bitbucket.org/squeaky/portable-pypy/downloads/pypy-5.8-linux_x86_64-portable.tar.bz2#337fd7e947a74cb09253f5ff330fb1be471b1d7a64c2d0340ac387920e71bf3c" "pypy" verify_py27 ensurepip
;;
* )
{ echo
colorize 1 "ERROR"
echo ": Portable PyPy is not available for $(pypy_architecture 2>/dev/null || true)."
echo
} >&2
exit 1
;;
esac

View File

@@ -0,0 +1,18 @@
case "$(pypy_architecture 2>/dev/null || true)" in
"linux64" )
if require_distro "Ubuntu 12.04" "Ubuntu 12.10" "Ubuntu 13.04" "Ubuntu 13.10" "Ubuntu 14.04" 1>/dev/null 2>&1; then
install_package "pypy3-v5.7.1-linux64" "https://bitbucket.org/pypy/pypy/downloads/pypy3-v5.7.1-linux64.tar.bz2#2abaa54d88c9b70b64c37083e7e430a1d3a8f78f8de92e484a988b7aca1e50a7" "pypy" verify_py35 ensurepip
else
install_package "pypy3.5-5.7.1-beta-linux_x86_64-portable" "https://bitbucket.org/squeaky/portable-pypy/downloads/pypy3.5-5.7.1-beta-linux_x86_64-portable.tar.bz2#3d1b02f6ef50d4e9069885e0b3f19f26491c7f4f9c5ccc8aa118e38fd6a23997" "pypy" verify_py35 ensurepip
fi
;;
* )
{ echo
colorize 1 "ERROR"
echo ": The binary distribution of PyPy is not available for $(pypy_architecture 2>/dev/null || true)."
echo "try 'pypy3.5-5.7-beta-src' to build from source."
echo
} >&2
exit 1
;;
esac

View File

@@ -0,0 +1,2 @@
require_gcc
install_package "pypy3-v5.7.1-src" "https://bitbucket.org/pypy/pypy/downloads/pypy3-v5.7.1-src.tar.bz2#40ece0145282980ac121390f13709404c0532896507d5767496381180b631bd0" "pypy_builder" verify_py35 ensurepip

View File

@@ -0,0 +1,18 @@
case "$(pypy_architecture 2>/dev/null || true)" in
"linux64" )
if require_distro "Ubuntu 14.04" 1>/dev/null 2>&1; then
install_package "pypy3-v5.8.0-linux64" "https://bitbucket.org/pypy/pypy/downloads/pypy3-v5.8.0-linux64.tar.bz2#57d871a7f1135719c138cee4e3533c3275d682a76a40ff668e95150c65923035" "pypy" verify_py35 ensurepip
else
install_package "pypy3.5-5.8-beta-linux_x86_64-portable" "https://bitbucket.org/squeaky/portable-pypy/downloads/pypy3.5-5.8-beta-linux_x86_64-portable.tar.bz2#76c2c4b2846e38d2b4846d4b5f9dc0bd9fd7a9b1f04beb92975ae090ad390d75" "pypy" verify_py35 ensurepip
fi
;;
* )
{ echo
colorize 1 "ERROR"
echo ": The binary distribution of PyPy is not available for $(pypy_architecture 2>/dev/null || true)."
echo "try 'pypy3.5-5.8.0-src' to build from source."
echo
} >&2
exit 1
;;
esac

View File

@@ -0,0 +1,2 @@
require_gcc
install_package "pypy3-v5.8.0-src" "https://bitbucket.org/pypy/pypy/downloads/pypy3-v5.8.0-src.tar.bz2#9d090127335c3c0fd2b14c8835bf91752e62756e55ea06aad3353f24a6854223" "pypy_builder" verify_py35 ensurepip

View File

@@ -0,0 +1,13 @@
case "$(pypy_architecture 2>/dev/null || true)" in
"linux64" )
install_package "pypy3.5-5.8-beta-linux_x86_64-portable" "https://bitbucket.org/squeaky/portable-pypy/downloads/pypy3.5-5.8-beta-linux_x86_64-portable.tar.bz2#76c2c4b2846e38d2b4846d4b5f9dc0bd9fd7a9b1f04beb92975ae090ad390d75" "pypy" verify_py35 ensurepip
;;
* )
{ echo
colorize 1 "ERROR"
echo ": Portable PyPy3 is not available for $(pypy_architecture 2>/dev/null || true)."
echo
} >&2
exit 1
;;
esac

View File

@@ -21,9 +21,11 @@ STATUS=0
# Run `pyenv-rehash` after a successful installation.
if [ "$STATUS" == "0" ]; then
case "$1" in
"install" | "uninstall" ) pyenv-rehash;;
esac
for piparg in "$@"; do
case ${piparg} in
"install" | "uninstall" ) pyenv-rehash ; break;;
esac
done
fi
exit "$STATUS"

View File

@@ -20,7 +20,7 @@ done
eval "conda_shim(){ case \"\$1\" in ${shims[@]} *)return 1;;esac;}"
# override `make_shims` to avoid conflict between pyenv-virtualenv's `envs.bash`
# https://github.com/yyuu/pyenv-virtualenv/blob/v20160716/etc/pyenv.d/rehash/envs.bash
# https://github.com/pyenv/pyenv-virtualenv/blob/v20160716/etc/pyenv.d/rehash/envs.bash
make_shims() {
local file shim
for file do

3
src/configure vendored
View File

@@ -21,6 +21,9 @@ case "$(uname -s)" in
Darwin* )
host_os="darwin$(uname -r)"
;;
FreeBSD* )
host_os="freebsd$(uname -r)"
;;
OpenBSD* )
host_os="openbsd$(uname -r)"
;;

View File

@@ -19,7 +19,7 @@ git_commit() {
assert [ ! -e "$PYENV_ROOT" ]
run pyenv---version
assert_success
[[ $output == "pyenv "?.?.? ]]
[[ $output == "pyenv "?.?.* ]]
}
@test "doesn't read version from non-pyenv repo" {
@@ -30,7 +30,7 @@ git_commit() {
run pyenv---version
assert_success
[[ $output == "pyenv "?.?.? ]]
[[ $output == "pyenv "?.?.* ]]
}
@test "reads version from git repo" {
@@ -51,5 +51,5 @@ git_commit() {
git_commit
run pyenv---version
[[ $output == "pyenv "?.?.? ]]
[[ $output == "pyenv "?.?.* ]]
}

6
test/init.bats Normal file → Executable file
View File

@@ -47,7 +47,7 @@ OUT
root="$(cd $BATS_TEST_DIRNAME/.. && pwd)"
run pyenv-init - fish
assert_success
assert_line ". '${root}/test/../libexec/../completions/pyenv.fish'"
assert_line "source '${root}/test/../libexec/../completions/pyenv.fish'"
}
@test "fish instructions" {
@@ -73,7 +73,7 @@ OUT
export PATH="${BATS_TEST_DIRNAME}/../libexec:/usr/bin:/bin:/usr/local/bin"
run pyenv-init - fish
assert_success
assert_line 0 "setenv PATH '${PYENV_ROOT}/shims' \$PATH"
assert_line 0 "set -gx PATH '${PYENV_ROOT}/shims' \$PATH"
}
@test "can add shims to PATH more than once" {
@@ -87,7 +87,7 @@ OUT
export PATH="${PYENV_ROOT}/shims:$PATH"
run pyenv-init - fish
assert_success
assert_line 0 "setenv PATH '${PYENV_ROOT}/shims' \$PATH"
assert_line 0 "set -gx PATH '${PYENV_ROOT}/shims' \$PATH"
}
@test "outputs sh-compatible syntax" {

View File

@@ -20,14 +20,34 @@ load test_helper
assert_success 'echo "$PYENV_VERSION"'
}
@test "shell revert" {
PYENV_SHELL=bash run pyenv-sh-shell -
assert_success
assert_line 0 'if [ -n "${PYENV_VERSION_OLD+x}" ]; then'
}
@test "shell revert (fish)" {
PYENV_SHELL=fish run pyenv-sh-shell -
assert_success
assert_line 0 'if set -q PYENV_VERSION_OLD'
}
@test "shell unset" {
PYENV_SHELL=bash run pyenv-sh-shell --unset
assert_success "unset PYENV_VERSION"
assert_success
assert_output <<OUT
PYENV_VERSION_OLD="\$PYENV_VERSION"
unset PYENV_VERSION
OUT
}
@test "shell unset (fish)" {
PYENV_SHELL=fish run pyenv-sh-shell --unset
assert_success "set -e PYENV_VERSION"
assert_success
assert_output <<OUT
set -gu PYENV_VERSION_OLD "\$PYENV_VERSION"
set -e PYENV_VERSION
OUT
}
@test "shell change invalid version" {
@@ -42,11 +62,19 @@ SH
@test "shell change version" {
mkdir -p "${PYENV_ROOT}/versions/1.2.3"
PYENV_SHELL=bash run pyenv-sh-shell 1.2.3
assert_success 'export PYENV_VERSION="1.2.3"'
assert_success
assert_output <<OUT
PYENV_VERSION_OLD="\$PYENV_VERSION"
export PYENV_VERSION="1.2.3"
OUT
}
@test "shell change version (fish)" {
mkdir -p "${PYENV_ROOT}/versions/1.2.3"
PYENV_SHELL=fish run pyenv-sh-shell 1.2.3
assert_success 'setenv PYENV_VERSION "1.2.3"'
assert_success
assert_output <<OUT
set -gu PYENV_VERSION_OLD "\$PYENV_VERSION"
set -gx PYENV_VERSION "1.2.3"
OUT
}