[GRASS-SVN] r33020 - grass/branches/develbranch_6/gui/wxpython/scripts

svn_grass at osgeo.org svn_grass at osgeo.org
Sat Aug 23 08:57:34 EDT 2008


Author: martinl
Date: 2008-08-23 08:57:34 -0400 (Sat, 23 Aug 2008)
New Revision: 33020

Modified:
   grass/branches/develbranch_6/gui/wxpython/scripts/d.rast3d
Log:
wxGUI: d.rast3d pythonized

Modified: grass/branches/develbranch_6/gui/wxpython/scripts/d.rast3d
===================================================================
--- grass/branches/develbranch_6/gui/wxpython/scripts/d.rast3d	2008-08-23 12:48:36 UTC (rev 33019)
+++ grass/branches/develbranch_6/gui/wxpython/scripts/d.rast3d	2008-08-23 12:57:34 UTC (rev 33020)
@@ -1,4 +1,4 @@
-#!/bin/sh
+#!/usr/bin/env python
 #
 ############################################################################
 #
@@ -16,25 +16,21 @@
 #
 #############################################################################
 
-#%Module
+#%module
 #%  description: Displays 3d raster data in the active frame on the graphics monitor.
 #%  keywords: display, raster3d
-#%End
+#%end
+
 #%option
 #% key: map
 #% type: string
 #% gisprompt: old,grid3,3d-raster
 #% description: 3D raster map to be displayed
 #% required : yes
-#%END
+#%end
 
-if  [ -z "$GISBASE" ] ; then
- echo "You must be in GRASS GIS to run this program." >&2
- exit 1
-fi
+import grass
 
-if [ "$1" != "@ARGS_PARSED@" ] ; then
-  exec g.parser "$0" "$@"
-fi
-
-exit 0
+if __name__ == "__main__":
+    options, flags = grass.parser()
+    main()



More information about the grass-commit mailing list