X-Git-Url: https://adrianiainlam.tk/git/?a=blobdiff_plain;f=scripts%2Fweigh-in.sh;h=e3d0b990d1533bd37e6948176792ea74500a788c;hb=fd6b8dadbaa0614671bef1508c23d6a932e25081;hp=e58f7866ba4afb1e9496799d48a5e841ebf91849;hpb=2d0f8227350b84a6dee74cae5653db15b1ea8f1e;p=dygraphs.git diff --git a/scripts/weigh-in.sh b/scripts/weigh-in.sh index e58f786..e3d0b99 100755 --- a/scripts/weigh-in.sh +++ b/scripts/weigh-in.sh @@ -3,7 +3,15 @@ # See https://github.com/danvk/travis-weigh-in set -o errexit -curl -O https://raw.githubusercontent.com/danvk/travis-weigh-in/master/weigh_in.py -python weigh_in.py dist/dygraph-combined.js -gzip -c dist/dygraph.min.js > dist/dygraph.min.js.gz -python weigh_in.py dist/dygraph.min.js.gz +if [ -z "$GITHUB_TOKEN" ]; then + echo "GITHUB_TOKEN not set. Skipping size checks." + exit 0 + +else + + curl -O https://raw.githubusercontent.com/danvk/travis-weigh-in/master/weigh_in.py + python weigh_in.py dist/dygraph.min.js + gzip -c dist/dygraph.min.js > dist/dygraph.min.js.gz + python weigh_in.py dist/dygraph.min.js.gz + +fi