summaryrefslogtreecommitdiff
path: root/htdocs/geojson/update_all.sh
diff options
context:
space:
mode:
authorMarkus Koch <markus@notsyncing.net>2021-11-02 16:58:19 +0100
committerMarkus Koch <markus@notsyncing.net>2021-11-02 16:58:19 +0100
commite4689aeb56f9607ca38e55d285a2da0f2cff6d60 (patch)
treedd410093e5b66e435674c6665ca134373ab490e3 /htdocs/geojson/update_all.sh
parent4625d4e25b5ebe98acc2bad69bed95dccd6037fd (diff)
downloadlifomapserver-e4689aeb56f9607ca38e55d285a2da0f2cff6d60.tar.gz
lifomapserver-e4689aeb56f9607ca38e55d285a2da0f2cff6d60.tar.bz2
lifomapserver-e4689aeb56f9607ca38e55d285a2da0f2cff6d60.zip
htdocs: geojson: Include train lines and water stuff
Diffstat (limited to 'htdocs/geojson/update_all.sh')
-rwxr-xr-xhtdocs/geojson/update_all.sh17
1 files changed, 12 insertions, 5 deletions
diff --git a/htdocs/geojson/update_all.sh b/htdocs/geojson/update_all.sh
index 5a0bc61..e25d843 100755
--- a/htdocs/geojson/update_all.sh
+++ b/htdocs/geojson/update_all.sh
@@ -1,12 +1,19 @@
#!/bin/bash
function fetch() {
- "./fetch_$1.sh" | json_reformat -m > "$1.json.tmp"
- rm -f "$1.json"
- mv "$1.json.tmp" "$1.json"
+ if [[ "$3" != "" ]]; then
+ fn="$3"
+ else
+ fn="$1"
+ fi
+ "./fetch_$1.sh" "$2" | json_reformat -m > "$fn.json.tmp"
+ rm -f "$fn.json"
+ mv "$fn.json.tmp" "$fn.json"
}
fetch streets
fetch city_outlines
-
-echo "OK."
+fetch trainlines "Train Lines"
+fetch trainlines "Access Paths" trainlines_access
+fetch bodiesofwater "Rivers" rivers
+fetch bodiesofwater "Oceans, Seas, and Lakes" oceans