#!/bin/sh alias uglify-js=$PWD/bin/uglifyjs UGLIFY_OPTIONS="--annotations $@" minify_in_situ() { ARGS="$UGLIFY_OPTIONS --in-situ" DIRS="$1" echo '> uglify-js' $DIRS $UGLIFY_OPTIONS for i in `find $DIRS -name '*.js'` do ARGS="$ARGS $i" done for i in `find $DIRS -name '*.mjs'` do ARGS="$ARGS $i" done uglify-js $ARGS } rm -rf tmp/mathjs \ && git clone --depth 1 --branch v9.2.0 https://github.com/josdejong/mathjs.git tmp/mathjs \ && cd tmp/mathjs \ && rm -rf .git/hooks \ && patch -l -p1 <