1
Fork 0

Check if game results have been changed.

master
vonavi 2013-10-09 11:22:53 +03:00
parent 41a8f2b26f
commit 2b2b975e68
1 changed files with 14 additions and 9 deletions

23
mktable
View File

@ -9,14 +9,19 @@ git checkout master
./tour-parse > $results
git add $results
git commit -m "Update game results."
# Successful `git commit' returns exit code `0'
ret_code=$?
# Update the tournament table
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
if [[ $ret_code == 0 ]]; then
# Check the difference between game results
git diff HEAD^ HEAD -- $results
# Update the tournament table
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