build HTML distribution (but not upload it yet)

This commit is contained in:
Mark Pilgrim
2009-08-27 16:14:28 -04:00
parent dbb69a52f6
commit e7f43bd409
+17
View File
@@ -8,6 +8,8 @@ die () {
echo "started build"
revision=`hg tip | grep changeset|cut -d":" -f2|cut -d" " -f4`
# make build directory and copy original files there for preflighting
rm -rf build
mkdir build
@@ -18,6 +20,21 @@ rm -f examples/*.pyc
cp -R examples build/
cp .htaccess build/
echo "building HTML distribution"
htmldir=build/diveintopython3-r"$revision"
mkdir "$htmldir"
cp *.html "$htmldir"/
cp dip3.css "$htmldir"/
mkdir "$htmldir"/i
cp i/*.png "$htmldir"/i/
mkdir "$htmldir"/j
cp j/dip3.js j/html5.js j/jquery.js j/prettify.js "$htmldir"/j/
mkdir "$htmldir"/examples
cp examples/*.jpg examples/*.json examples/*.pickle examples/*.py examples/*.txt examples/*.xml "$htmldir"/examples/
cd build/ && \
zip -9rq diveintopython3-r"$revision".zip diveintopython3-r"$revision" && \
cd ..
echo "linting JS"
[ -n "$(which js 2>/dev/null)" ] || die "SpiderMonkey (js or js.exe) not found"