[GRASS-SVN] r33180 - grass/branches/develbranch_6/lib/init

svn_grass at osgeo.org svn_grass at osgeo.org
Sun Aug 31 22:51:45 EDT 2008


Author: hamish
Date: 2008-08-31 22:51:44 -0400 (Sun, 31 Aug 2008)
New Revision: 33180

Modified:
   grass/branches/develbranch_6/lib/init/init.sh
Log:
version option actually displays version;
whitespace and comment cleanup


Modified: grass/branches/develbranch_6/lib/init/init.sh
===================================================================
--- grass/branches/develbranch_6/lib/init/init.sh	2008-08-31 22:47:54 UTC (rev 33179)
+++ grass/branches/develbranch_6/lib/init/init.sh	2008-09-01 02:51:44 UTC (rev 33180)
@@ -72,6 +72,8 @@
     
     	# Check if the user asked for the version
 	-v|--version)
+	    echo "$GRASS_VERSION"
+	    echo
 	    cat "$GISBASE/etc/license"
 	    exit
 	    ;;
@@ -597,28 +599,28 @@
 		    ;;
     	    esac
 	    ;;
-	
-	# Check for tcltk interface
+
+	# Check that GUI support software is functional
 	tcltk | gis.m | oldtcltk | d.m | wxpython)
 
-        if [ "$GRASS_GUI" = "tcltk" ] || \
-			[ "$GRASS_GUI" = "gis.m" ] || \
-			[ "$GRASS_GUI" = "oldtcltk" ] || \
-			[ "$GRASS_GUI" = "d.m" ] ; then
+	    if [ "$GRASS_GUI" = "tcltk" ] || \
+		[ "$GRASS_GUI" = "gis.m" ] || \
+		[ "$GRASS_GUI" = "oldtcltk" ] || \
+		[ "$GRASS_GUI" = "d.m" ] ; then
 
-			# eval `foo` will return subshell return code and not app foo return code!!!
-			eval '"$GRASS_WISH" -file "$TCLTKGRASSBASE/gis_set.tcl"'
-			thetest=$?
-		else
-			eval '"$GRASS_PYTHON" "$WXPYTHONGRASSBASE/gis_set.py"'
-			thetest=$?
-		fi
+		    # eval `foo` will return subshell return code and not app foo return code!!!
+		    eval '"$GRASS_WISH" -file "$TCLTKGRASSBASE/gis_set.tcl"'
+		    thetest=$?
+	    else
+		    eval '"$GRASS_PYTHON" "$WXPYTHONGRASSBASE/gis_set.py"'
+		    thetest=$?
+	    fi
 
 
 	    case $thetest in
      	    	1)
 
-         	    # The gis_set.tcl script printed an error message so wait
+         	    # The gis_set script printed an error message so wait
 		    # for user to read it
 		    echo "Error in GUI startup. If necessary, please"
 		    echo "report this error to the GRASS developers."



More information about the grass-commit mailing list