[GRASS-SVN] r36552 - grass/branches/develbranch_6/scripts/v.centroids

svn_grass at osgeo.org svn_grass at osgeo.org
Tue Mar 31 17:22:40 EDT 2009


Author: neteler
Date: 2009-03-31 17:22:40 -0400 (Tue, 31 Mar 2009)
New Revision: 36552

Modified:
   grass/branches/develbranch_6/scripts/v.centroids/v.centroids
Log:
Don't use locale dependent output for parsing

Modified: grass/branches/develbranch_6/scripts/v.centroids/v.centroids
===================================================================
--- grass/branches/develbranch_6/scripts/v.centroids/v.centroids	2009-03-31 21:22:34 UTC (rev 36551)
+++ grass/branches/develbranch_6/scripts/v.centroids/v.centroids	2009-03-31 21:22:40 UTC (rev 36552)
@@ -82,7 +82,7 @@
 if [ "$GIS_OPT_OPTION" = "add" ] ; then
 
    # check we have boundaries
-   NUM_BOUND=`v.info "$GIS_OPT_INPUT" | grep "Number of boundaries:" | cut -f2 -d: | awk '{print $1}'`
+   NUM_BOUND=`v.info -t "$GIS_OPT_INPUT" | grep boundaries | cut -d'=' -f2`
 
    if [ $NUM_BOUND -eq 0 ] ; then
        g.message -e "Input vector map contains no boundaries."



More information about the grass-commit mailing list