-
Notifications
You must be signed in to change notification settings - Fork 8
Expand file tree
/
Copy pathbuild-bundle
More file actions
executable file
·56 lines (46 loc) · 1.47 KB
/
build-bundle
File metadata and controls
executable file
·56 lines (46 loc) · 1.47 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
#!/bin/sh
fail () {
echo "$@"
exit 1
}
if [ "$1" = "upload" ] ; then
shift
FILENAME="$1"
if [ -z "$FILENAME" ] ; then
echo "Usage: `basename $0` uplaod FILENAME"
exit 2
fi
cat $FILENAME | ssh flow.openplans.org "ssh acura.openplans.org \"cd /www/deliverance.openplans.org/dist/ ; cat > $FILENAME ; rm Deliverance-snapshot-latest.pybundle ; ln -s $FILENAME Deliverance-snapshot-latest.pybundle\""
exit
fi
mkdir -p download-cache
export PIP_DOWNLOAD_CACHE="`pwd`/download-cache"
REV=$(python -c 'import pip; print pip.Subversion().get_revision(".")')
FILE="Deliverance-snapshot-r${REV}.pybundle"
if [ -e "$FILE" ] ; then
echo "Bundle file $FILE already exists"
exit 0
fi
echo "CREATING BUNDLE: $FILE"
echo
## FIXME: httplib2 still isn't being included
## httplib2 location is a temporary problem with a bad pypi entry
pip bundle $FILE --build=build-bundle-files/ --src=src-bundle-files/ \
http://httplib2.googlecode.com/files/httplib2-0.4.0.zip \
./lxml-2.2alpha1-staticbuild.tar.gz \
-e svn+http://codespeak.net/svn/z3/deliverance/trunk#egg=Deliverance \
supervisor PasteScript nose \
http://svn.colorstudy.com/home/ianb/PageCollector/trunk#egg=PageCollector \
Dozer \
|| fail 'Bundle failed'
echo 'INSTALLING'
echo
rm -rf TEST
virtualenv --no-site-packages TEST
pip install -E TEST $FILE \
|| fail 'Install failed'
cd TEST/bin
cd ../src/deliverance
chmod +x test
NOSE=../../bin/nosetests ./test \
|| fail 'Tests failed'