Created
June 15, 2012 08:04
-
-
Save bjorne/2935316 to your computer and use it in GitHub Desktop.
Diff compressed Javascript files by beautifying them first
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
UGLIFY=`which uglifyjs` | |
ARGS="--beautify" | |
F1=/tmp/$RANDOM | |
F2=/tmp/$RANDOM | |
cat $1 | $UGLIFY $ARGS > $F1 | |
cat $2 | $UGLIFY $ARGS > $F2 | |
diff $F1 $F2 | less | |
rm $F1 $F2 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment