aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xgis-observation-map6
1 files changed, 4 insertions, 2 deletions
diff --git a/gis-observation-map b/gis-observation-map
index ac9baa7..1036009 100755
--- a/gis-observation-map
+++ b/gis-observation-map
@@ -103,10 +103,12 @@ if args.project_home is not None and args.project_name is not None:
raise Exception('Invalid CRS')
elif args.project_home is None or args.project_name is None:
- parser.error()
+ parser.print_usage()
+ exit(1)
if len(args.geometry) == 0 and len(args.point) == 0:
- parser.error()
+ parser.print_usage()
+ exit(1)
if len(args.point) > 0 and (args.margin is None or args.margin <= 0):
parser.error("--point requires positive --margin")