Compare commits

...

21 Commits

Author SHA1 Message Date
kennethreitz 8266b99d1e don't uninstall pip or setuptools 2015-05-04 11:59:42 -07:00
kennethreitz e27470778c update pip-pop 2015-05-04 11:52:34 -07:00
kennethreitz 8ef4a006e0 make tools 2015-05-04 11:30:04 -07:00
kennethreitz 4fdaf14ded new pip, new setuptools 2015-05-04 11:09:15 -07:00
kennethreitz f1da8d4b5c Merge pull request #217 from heroku/pyOpenSSL
Detect pyOpenSSL
2015-04-24 15:09:29 -04:00
Steven F eb9689c0a2 Detect pyOpenSSL
Some people use pyOpenSSL (it is the literal name, e.g.: https://pypi.python.org/pypi/pyOpenSSL)
2015-04-24 06:03:43 +00:00
kennethreitz 6fe7c6bde0 Merge pull request #215 from ryanwitt/patch-1
correct usage comment
2015-04-21 17:18:36 -04:00
Ryan Witt a1b372ac66 correct usage comment 2015-04-21 13:22:17 -04:00
kennethreitz ddead6457a Merge pull request #213 from heroku/watsonian-update-readme
Update README to reflect new buildpack:set usage
2015-04-17 08:38:25 -04:00
Joel Watson 92b4385890 Update README to reflect new buildpack:set usage. 2015-04-15 15:45:09 -05:00
kennethreitz 7074d5cb50 Merge remote-tracking branch 'origin/master' 2015-04-02 14:35:16 -04:00
kennethreitz 2b1f1182c3 Merge pull request #211 from ollanta/ollanta/prefer-shallow-managepy
Prefer a 'manage.py' that exists higher up in the directory hierarchy
2015-04-02 14:34:53 -04:00
Ollanta 38fc8f4fe7 Prefer a 'manage.py' that exists higher up in the directory hierarchy 2015-04-02 14:53:52 +02:00
kennethreitz a203495532 pypy v2.5.1 2015-04-01 14:48:02 -04:00
kennethreitz 33a69d7f52 Merge remote-tracking branch 'origin/master' 2015-04-01 14:06:57 -04:00
kennethreitz fe3f12c430 Merge pull request #208 from cyx/master
Upgrade pip and make netrc github work
2015-03-26 13:16:55 -04:00
Cyril David aeb1a297d3 Patch to allow netrc buildpack[1] to work.
[1]: https://github.com/timshadel/heroku-buildpack-github-netrc
2015-03-23 05:47:01 -07:00
kennethreitz 4c1972c0b9 Merge pull request #206 from cclauss/patch-11
Update Readme.md to python-2.7.9 and python-3.4.3
2015-03-20 11:26:23 -07:00
kennethreitz 74f0f319dc pypy 2.5.0 2015-03-19 13:42:03 -07:00
Cyril David 683bba59d7 Update to 6.0.8 2015-03-18 21:15:43 -07:00
cclauss f890cdb889 Update Readme.md to python-2.7.9 and python-3.4.3 2015-03-19 02:42:19 +01:00
14 changed files with 55 additions and 20 deletions
+5
View File
@@ -3,3 +3,8 @@
tests:
./bin/test
tools:
git clone https://github.com/kennethreitz/pip-pop.git
mv pip-pop/bin/* vendor/pip-pop/
rm -fr pip-pop
+5 -5
View File
@@ -17,7 +17,7 @@ Example usage:
$ git push heroku master
...
-----> Python app detected
-----> Installing runtime (python-2.7.8)
-----> Installing runtime (python-2.7.9)
-----> Installing dependencies using pip
Downloading/unpacking requests (from -r requirements.txt (line 1))
Installing collected packages: requests
@@ -28,7 +28,7 @@ Example usage:
You can also add it to upcoming builds of an existing application:
$ heroku config:add BUILDPACK_URL=git://github.com/heroku/heroku-buildpack-python.git
$ heroku buildpack:set git://github.com/heroku/heroku-buildpack-python.git
The buildpack will detect your app as Python if it has the file `requirements.txt` in the root.
@@ -40,12 +40,12 @@ Specify a Runtime
You can also provide arbitrary releases Python with a `runtime.txt` file.
$ cat runtime.txt
python-3.4.2
python-3.4.3
Runtime options include:
- python-2.7.8
- python-3.4.2
- python-2.7.9
- python-3.4.3
- pypy-2.4.0 (unsupported, experimental)
- pypy3-2.4.0 (unsupported, experimental)
+2 -2
View File
@@ -29,8 +29,8 @@ WEBCONCURRENCY_PROFILE_PATH="$BUILD_DIR/.profile.d/python.webconcurrency.sh"
DEFAULT_PYTHON_VERSION="python-2.7.9"
DEFAULT_PYTHON_STACK="cedar"
PYTHON_EXE="/app/.heroku/python/bin/python"
PIP_VERSION="6.0.6"
SETUPTOOLS_VERSION="11.3.1"
PIP_VERSION="6.1.1"
SETUPTOOLS_VERSION="15.2"
# Setup bpwatch
export PATH=$PATH:$ROOT_DIR/vendor/bpwatch
+2 -2
View File
@@ -2,7 +2,7 @@
source $BIN_DIR/utils
MANAGE_FILE=$(find . -maxdepth 3 -type f -name 'manage.py' | head -1)
MANAGE_FILE=$(find . -maxdepth 3 -type f -name 'manage.py' -printf '%d\t%P\n' | sort -nk1 | cut -f2 | head -1)
MANAGE_FILE=${MANAGE_FILE:-fakepath}
[ -f .heroku/collectstatic_disabled ] && DISABLE_COLLECTSTATIC=1
@@ -33,4 +33,4 @@ if [ ! "$DISABLE_COLLECTSTATIC" ] && [ -f "$MANAGE_FILE" ]; then
echo
fi
bpwatch stop collectstatic
bpwatch stop collectstatic
+1 -1
View File
@@ -20,7 +20,7 @@ source $BIN_DIR/utils
bpwatch start libffi_install
# If pylibmc exists within requirements, use vendored cryptography.
if (pip-grep -s requirements.txt bcrypt cffi cryptography PyOpenSSL &> /dev/null) then
if (pip-grep -s requirements.txt bcrypt cffi cryptography pyOpenSSL PyOpenSSL &> /dev/null) then
if [ -d ".heroku/vendor/lib/libffi-3.1.1" ]; then
export LIBFFI=$(pwd)/vendor
+1 -1
View File
@@ -5,7 +5,7 @@ if [[ -f .heroku/python/requirements-declared.txt ]]; then
cp .heroku/python/requirements-declared.txt requirements-declared.txt
pip-diff --stale requirements-declared.txt requirements.txt > .heroku/python/requirements-stale.txt
pip-diff --stale requirements-declared.txt requirements.txt --exclude setuptools pip > .heroku/python/requirements-stale.txt
rm -fr requirements-declared.txt
+2 -2
View File
@@ -36,7 +36,7 @@ set-default-env() {
echo "export $1=\${$1:-$2}" >> $PROFILE_PATH
}
# Usage: $ set-default-env key value
# Usage: $ un-set-env key
un-set-env() {
echo "unset $1" >> $PROFILE_PATH
}
@@ -68,7 +68,7 @@ deep-rm() {
# subshell to avoid surprising caller with shopts.
(
shopt -s dotglob
rm -rf "$1"/!(tmp|.|..)
rm -rf "$1"/!(.curlrc|.netrc|tmp|.|..)
)
}
+14
View File
@@ -0,0 +1,14 @@
#!/usr/bin/env bash
# Build Path: /app/.heroku/python/
# Build Deps: libraries/sqlite
# NOTICE: This formula only works for the cedar-14 stack, not cedar.
OUT_PREFIX=$1
echo "Building PyPy..."
SOURCE_TARBALL='https://bitbucket.org/pypy/pypy/downloads/pypy-2.5.0-linux64.tar.bz2'
curl -L $SOURCE_TARBALL | tar jx
cp -R pypy-2.5.0-linux64/* $OUT_PREFIX
ln $OUT_PREFIX/bin/pypy $OUT_PREFIX/bin/python
+14
View File
@@ -0,0 +1,14 @@
#!/usr/bin/env bash
# Build Path: /app/.heroku/python/
# Build Deps: libraries/sqlite
# NOTICE: This formula only works for the cedar-14 stack, not cedar.
OUT_PREFIX=$1
echo "Building PyPy..."
SOURCE_TARBALL='https://bitbucket.org/pypy/pypy/downloads/pypy-2.5.1-linux64.tar.bz2'
curl -L $SOURCE_TARBALL | tar jx
cp -R pypy-2.5.1-linux64/* $OUT_PREFIX
ln $OUT_PREFIX/bin/pypy $OUT_PREFIX/bin/python
BIN
View File
Binary file not shown.
BIN
View File
Binary file not shown.
+9 -7
View File
@@ -2,7 +2,7 @@
# -*- coding: utf-8 -*-
"""Usage:
pip-diff (--fresh | --stale) <reqfile1> <reqfile2>
pip-diff (--fresh | --stale) <reqfile1> <reqfile2> [--exclude <package>...]
pip-diff (-h | --help)
Options:
@@ -41,7 +41,7 @@ class Requirements(object):
self.requirements.append(requirement.req)
def diff(self, requirements, ignore_versions=False):
def diff(self, requirements, ignore_versions=False, excludes=None):
r1 = self
r2 = requirements
results = {'fresh': [], 'stale': []}
@@ -55,7 +55,7 @@ class Requirements(object):
for req in r2.requirements:
r = req.project_name if ignore_versions else req
if r not in other_reqs:
if r not in other_reqs and r not in excludes:
results['fresh'].append(req)
# Generate stale packages.
@@ -67,7 +67,7 @@ class Requirements(object):
for req in r1.requirements:
r = req.project_name if ignore_versions else req
if r not in other_reqs:
if r not in other_reqs and r not in excludes:
results['stale'].append(req)
return results
@@ -76,9 +76,10 @@ class Requirements(object):
def diff(r1, r2, include_fresh=False, include_stale=False):
def diff(r1, r2, include_fresh=False, include_stale=False, excludes=None):
include_versions = True if include_stale else False
excludes = excludes if len(excludes) else []
try:
r1 = Requirements(r1)
@@ -87,7 +88,7 @@ def diff(r1, r2, include_fresh=False, include_stale=False):
print('There was a problem loading the given requirements files.')
exit(os.EX_NOINPUT)
results = r1.diff(r2, ignore_versions=True)
results = r1.diff(r2, ignore_versions=True, excludes=excludes)
if include_fresh:
for line in results['fresh']:
@@ -106,7 +107,8 @@ def main():
'r1': args['<reqfile1>'],
'r2': args['<reqfile2>'],
'include_fresh': args['--fresh'],
'include_stale': args['--stale']
'include_stale': args['--stale'],
'excludes': args['<package>']
}
diff(**kwargs)
BIN
View File
Binary file not shown.
BIN
View File
Binary file not shown.