fix reports backup, I hope

This commit is contained in:
Enno Rehling 2019-02-17 11:56:11 +01:00 committed by Enno Rehling
parent 894bb4db4c
commit d122ba22d0
1 changed files with 5 additions and 4 deletions

View File

@ -23,15 +23,16 @@ if [ ! -d backup ] ; then
ln -sf ~/backup/eressea/game-$GAME backup
fi
if [ -e reports/reports.txt ] ; then
echo "backup reports $TURN, game $GAME"
tar cjf backup/$TURN-reports.tar.bz2 reports
curl -s -n -T backup/$TURN-reports.tar.bz2 https://dav.box.com/dav/Eressea/game-$GAME/$TURN-reports.tar.bz2
fi
files="data/$TURN.dat parteien.full parteien"
if [ -e orders.$TURN ]; then
files="$files orders.$TURN"
fi
echo "backup turn $TURN, game $GAME, files: $files"
if [ -d reports ] ; then
tar cjf backup/$TURN-reports.tar.bz2 reports
fi
tar cjf backup/$TURN.tar.bz2 $files
echo "uploading game-$GAME/$TURN.tar.bz2"
curl -s -n -T backup/$TURN.tar.bz2 https://dav.box.com/dav/Eressea/game-$GAME/$TURN.tar.bz2
#curl -s -n -T eressea.db https://dav.box.com/dav/Eressea/eressea.db