Permalink
Browse files

CLJS-161: updated bootstrap to use recent Google Closure Library.

  • Loading branch information...
1 parent 5ad58eb commit 7123171d9d5e08edf882d25be61d76243ef37841 @neotyk neotyk committed with David Nolen Apr 21, 2012
Showing with 27 additions and 4 deletions.
  1. +27 −4 script/bootstrap
View
@@ -17,10 +17,33 @@ rm clojure-1.3.0.zip
echo "Fetching Google Closure library..."
mkdir -p closure/library
cd closure/library
-curl -O -s http://closure-library.googlecode.com/files/closure-library-20110323-r790.zip
-unzip -qu closure-library-20110323-r790.zip
-echo "Cleaning up Google Closure library archive..."
-rm closure-library-20110323-r790.zip
+if [ "x$1" = "x--closure-library-head" ] ; then
+ echo "Building against HEAD of Google Closure library..."
+
+ # Check if svn present
+ type svn >/dev/null 2>&1 || { echo >&2 "Need svn command to checkout HEAD of Google Closure library. Aborting."; exit 1; }
+
+ # Existing checkout?
+ set +e
+ svn info --non-interactive >/dev/null 2>&1
+ declare -i r=$?
+ set -e
+ if [ 0 -eq $r ] ; then
+ echo "Updating Google Closure library from HEAD..."
+ svn update -q --non-interactive
+ else
+ echo "Checking out HEAD of Google Closure library..."
+ rm -rf *
+ svn checkout -q --non-interactive http://closure-library.googlecode.com/svn/trunk/ ./
+ fi
+else
+ echo "Fetching Google Closure library..."
+ f=closure-library-20111110-r1376.zip
+ curl -O -s http://closure-library.googlecode.com/files/$f
+ unzip -qu $f
+ echo "Cleaning up Google Closure library archive..."
+ rm $f
+fi
cd ..
echo "Fetching Google Closure compiler..."

0 comments on commit 7123171

Please sign in to comment.