summaryrefslogtreecommitdiff
path: root/tools/writegame.sh
diff options
context:
space:
mode:
authorTor Andersson <tor@ccxvii.net>2023-05-25 20:52:06 +0200
committerTor Andersson <tor@ccxvii.net>2023-06-05 11:45:00 +0200
commitab74f660dd0301995d2b71be27e89764e1ee4b5e (patch)
treeb2a01bc8fc67af82486ba59479678fd26db6d49f /tools/writegame.sh
parentbd6644214c757a08c1c533048352a902fdefe4ae (diff)
downloadserver-ab74f660dd0301995d2b71be27e89764e1ee4b5e.tar.gz
Remove stale stuff.
Diffstat (limited to 'tools/writegame.sh')
-rw-r--r--tools/writegame.sh7
1 files changed, 7 insertions, 0 deletions
diff --git a/tools/writegame.sh b/tools/writegame.sh
new file mode 100644
index 0000000..ea0f599
--- /dev/null
+++ b/tools/writegame.sh
@@ -0,0 +1,7 @@
+#!/bin/bash
+if [ -n "$1" -a -f "$2" ]
+then
+ sqlite3 db "update game_state set state=readfile('$2') where game_id = $1"
+else
+ echo "usage: bash tools/writegame.sh GAME state.json"
+fi