Newer
Older
Import / projects / Gameloft / bne_lib / build / scripts / CheckGameDBSchema.sh
@John John on 29 Dec 2020 494 bytes bulk import from macbookpro checkouts
#!/bin/bash

cat ../../../../survivor/data/Survivor/Data/GameDB/schemaFlags.txt | cut -d ' ' -f 2-         > tmp.schema.previous
cat ../../../../survivor/data/Survivor/Data/GameDB/gameDB.json     | ./ExtractGameDBSchema.py > tmp.schema.currrent

#
# Compare the schemas to see if it has changed
#
CHANGED=0
diff -du tmp.schema.previous tmp.schema.currrent
if [ "$?" != "0" ]
then
  echo "GameDB schema has changed!"
  CHANGED=1
fi
rm -f tmp.schema.previous tmp.schema.currrent

exit $CHANGED