[GRASS-CVS] hamish: grass6/scripts/v.report v.report,1.15,1.16

grass at intevation.de grass at intevation.de
Fri Nov 16 05:49:23 EST 2007


Author: hamish

Update of /grassrepository/grass6/scripts/v.report
In directory doto:/tmp/cvs-serv32654

Modified Files:
	v.report 
Log Message:
very minor cleanup


Index: v.report
===================================================================
RCS file: /grassrepository/grass6/scripts/v.report/v.report,v
retrieving revision 1.15
retrieving revision 1.16
diff -u -d -r1.15 -r1.16
--- v.report	15 Sep 2007 14:35:49 -0000	1.15
+++ v.report	16 Nov 2007 10:49:21 -0000	1.16
@@ -49,7 +49,7 @@
 #%option
 #% key: units
 #% type: string
-#% description: mi(les),f(eet),me(ters),k(ilometers),a(cres),h(ectares)
+#% description: mi(les),f(eet),me(ters),k(ilometers),a(cres),h(ectares),p(ercent)
 #% options: mi,miles,f,feet,me,meters,k,kilometers,a,acres,h,hectares,p,percent
 #% required: no
 #%end
@@ -130,7 +130,7 @@
 fi
 
 #check for optional units parameter:
-if [ ! -z $GIS_OPT_UNITS ] ; then
+if [ -n "$GIS_OPT_UNITS" ] ; then
    UNITSPARAM="units=$GIS_OPT_UNITS"
    # reset to meters since percent are unsupported in v.to.db
    if [ "$GIS_OPT_UNITS" = "p" -o "$GIS_OPT_UNITS" = "percent" ] ; then
@@ -171,7 +171,7 @@
 NUMCOLS=`echo "$COLNAMES$EXTRACOLNAMES" | tr -s '|' ' ' | wc -w | awk '{print $1}'`
 
 # calculate percents if requested
-if  [ ! -z $GIS_OPT_UNITS ] ; then
+if  [ -n "$GIS_OPT_UNITS" ] ; then
     if [ "$GIS_OPT_UNITS" = "p" -o "$GIS_OPT_UNITS" = "percent" ] ; then
     
        # calculate total area value




More information about the grass-commit mailing list