changeset 3656:6603aeeda6e3

Shape importer: modified structure of run.sh script. flys-backend/trunk@5248 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Ingo Weinzierl <ingo.weinzierl@intevation.de>
date Thu, 23 Aug 2012 14:01:21 +0000
parents 8654e4480fc6
children 4f16070b917b
files flys-backend/ChangeLog flys-backend/contrib/shpimporter/run.sh
diffstat 2 files changed, 34 insertions(+), 13 deletions(-) [+]
line wrap: on
line diff
--- a/flys-backend/ChangeLog	Wed Aug 22 13:04:05 2012 +0000
+++ b/flys-backend/ChangeLog	Thu Aug 23 14:01:21 2012 +0000
@@ -1,3 +1,8 @@
+2012-08-22  Ingo Weinzierl <ingo@intevation.de>
+
+	* contrib/shpimporter/run.sh: Moved 'SKIP_XXX' variables to the top of
+	  the script.
+
 2012-08-22  Ingo Weinzierl <ingo@intevation.de>
 
 	* contrib/shpimporter/axis.py: Use log methods of shpimporter and
--- a/flys-backend/contrib/shpimporter/run.sh	Wed Aug 22 13:04:05 2012 +0000
+++ b/flys-backend/contrib/shpimporter/run.sh	Thu Aug 23 14:01:21 2012 +0000
@@ -1,5 +1,6 @@
 #!/bin/sh
 
+# Required
 RIVER_PATH="/path/to/rivers/river"
 RIVER_ID=1
 TARGET_SRS=31466
@@ -7,6 +8,21 @@
 USER=the_user
 PASS=the_pass
 
+# Optional
+VERBOSE=1
+SKIP_AXIS=0
+SKIP_KMS=0
+SKIP_CROSSSECTIONS=0
+SKIP_LINES=0
+SKIP_FIXPOINTS=0
+SKIP_BUILDINGS=0
+SKIP_FLOODPLAINS=0
+SKIP_HYDR_BOUNDARIES=0
+SKIP_HWS=0
+SKIP_GAUGE_LOCATION=0
+SKIP_CATCHMENTS=0
+SKIP_UESG=0
+
 exec python shpimporter.py \
     --directory $RIVER_PATH \
     --river_id $RIVER_ID \
@@ -14,17 +30,17 @@
     --host $HOST \
     --user $USER \
     --password $PASS \
-    --verbose 1 \
-    --skip_axis 0 \
-    --skip_kms 0 \
-    --skip_crosssections 0 \
-    --skip_lines 0 \
-    --skip_fixpoints 0 \
-    --skip_buildings 0 \
-    --skip_floodplains 0 \
-    --skip_hydr_boundaries 0 \
-    --skip_hws 0 \
-    --skip_gauge_locations 0 \
-    --skip_catchments 0 \
-    --skip_uesgs 0
+    --verbose $VERBOSE \
+    --skip_axis $SKIP_AXIS \
+    --skip_kms $SKIP_KMS \
+    --skip_crosssections $SKIP_CROSSSECTIONS \
+    --skip_lines $SKIP_LINES \
+    --skip_fixpoints $SKIP_FIXPOINTS \
+    --skip_buildings $SKIP_BUILDINGS \
+    --skip_floodplains $SKIP_FLOODPLAINS \
+    --skip_hydr_boundaries $SKIP_HYDR_BOUNDARIES \
+    --skip_hws $SKIP_HWS \
+    --skip_gauge_locations $SKIP_GAUGE_LOCATION \
+    --skip_catchments $SKIP_CATCHMENTS \
+    --skip_uesgs $SKIP_UESG
 

http://dive4elements.wald.intevation.org