Check if game results have been changed.

This commit is contained in:
vonavi 2013-10-09 11:22:53 +03:00
parent 41a8f2b26f
commit 2b2b975e68

23
mktable
View File

@ -9,14 +9,19 @@ git checkout master
./tour-parse > $results ./tour-parse > $results
git add $results git add $results
git commit -m "Update game results." git commit -m "Update game results."
# Successful `git commit' returns exit code `0'
ret_code=$?
# Update the tournament table if [[ $ret_code == 0 ]]; then
bin/lorchess > temp_table.html
git checkout gh-pages
mv temp_table.html $table
git add $table
git commit -m "Update the tournament table."
git checkout master
# Check the difference between game results # Update the tournament table
git diff HEAD^ HEAD -- $results bin/lorchess > temp_table.html
git checkout gh-pages
mv temp_table.html $table
git add $table
git commit -m "Update the tournament table."
git checkout master
# Check the difference between game results
git diff HEAD^ HEAD -- $results
fi