mirror of
https://github.com/swc-project/swc.git
synced 2024-12-21 12:41:54 +03:00
19 lines
294 B
Bash
19 lines
294 B
Bash
|
#!/usr/bin/env bash
|
||
|
set -eu
|
||
|
|
||
|
echo ''
|
||
|
echo ''
|
||
|
echo ''
|
||
|
echo "Comparing $1"
|
||
|
EXPECTED=$(terser "$1" | xargs)
|
||
|
ACTUAL=$(cat "$1" | xargs)
|
||
|
|
||
|
if [[ $EXPECTED == $ACTUAL || $EXPECTED == "$ACTUAL;" ]]; then
|
||
|
echo "PASSED";
|
||
|
git add "$1"
|
||
|
else
|
||
|
echo $EXPECTED
|
||
|
echo $ACTUAL
|
||
|
echo "FAILED"
|
||
|
fi
|