small fix to score.sh to remove newlines at end of file

This commit is contained in:
Mike Grimes
2022-10-22 11:50:49 -06:00
parent 1a75e5cc76
commit 52ab4e7c58
+2 -2
View File
@@ -1,6 +1,6 @@
if [[ $1 == '--update-readme' ]]; then
export NEW_SCORE=$(python3 ./tools/python/score.py)
echo $NEW_SCORE
echo "$NEW_SCORE"
python3 - <<'EOF' > README.md.tmp
import sys
import os
@@ -18,7 +18,7 @@ print(
)
)
EOF
mv README.md.tmp README.md
sed '$ { /^$/ d}' README.md.tmp > README.md # removes extra newlines at end of file
else
python3 ./tools/python/score.py "$@"
fi