summaryrefslogtreecommitdiff
path: root/sources/update_all.sh
diff options
context:
space:
mode:
authorJochen Topf <jochen@topf.org>2010-10-04 18:41:53 +0200
committerJochen Topf <jochen@topf.org>2010-10-04 18:41:53 +0200
commit9918c2c4c266a29848ce39fe2496876c66c3a48e (patch)
treeb49fe450d33dcb3c30b37f7bff68fbb475ecec66 /sources/update_all.sh
downloadtaginfo-9918c2c4c266a29848ce39fe2496876c66c3a48e.tar
taginfo-9918c2c4c266a29848ce39fe2496876c66c3a48e.tar.gz
first commit
Diffstat (limited to 'sources/update_all.sh')
-rwxr-xr-xsources/update_all.sh47
1 files changed, 47 insertions, 0 deletions
diff --git a/sources/update_all.sh b/sources/update_all.sh
new file mode 100755
index 0000000..4011a2d
--- /dev/null
+++ b/sources/update_all.sh
@@ -0,0 +1,47 @@
+#!/bin/sh
+#
+# Taginfo
+#
+# update_all.sh DIR
+#
+
+SOURCES="db josm wiki"
+
+set -e
+
+DIR=$1
+
+if [ "x" = "x$DIR" ]; then
+ echo "Usage: update.sh DIR"
+ exit 1
+fi
+
+exec >$DIR/update_all.log 2>&1
+
+echo -n "Start: "; date
+
+mkdir -p $DIR/download
+
+for source in $SOURCES; do
+ echo "====================================="
+ echo "Running $source/update.sh..."
+ mkdir -p $DIR/$source
+ cd $source
+ ./update.sh $DIR/$source
+ cd ..
+ echo "Running bzip2..."
+ bzip2 -9 -c $DIR/$source/taginfo-$source.db >$DIR/download/taginfo-$source.db.bz2
+ echo "Done."
+done
+
+echo "====================================="
+echo "Running master/update.sh..."
+cd master
+./update.sh $DIR
+cd ..
+echo "Running bzip2..."
+bzip2 -9 -c $DIR/taginfo-master.db >$DIR/download/taginfo-master.db.bz2
+echo "Done."
+
+echo -n "Done: "; date
+