[GRASS-SVN] r30136 - grass/trunk/scripts/v.rast.stats

svn_grass at osgeo.org svn_grass at osgeo.org
Wed Feb 13 21:29:00 EST 2008


Author: hamish
Date: 2008-02-13 21:29:00 -0500 (Wed, 13 Feb 2008)
New Revision: 30136

Modified:
   grass/trunk/scripts/v.rast.stats/v.rast.stats
Log:
remove @mapset before setting talbe name

Modified: grass/trunk/scripts/v.rast.stats/v.rast.stats
===================================================================
--- grass/trunk/scripts/v.rast.stats/v.rast.stats	2008-02-14 01:10:26 UTC (rev 30135)
+++ grass/trunk/scripts/v.rast.stats/v.rast.stats	2008-02-14 02:29:00 UTC (rev 30136)
@@ -122,7 +122,6 @@
 trap "exitprocedure" 2 3 15
 
 
-VECTOR="$GIS_OPT_VECTOR"
 RASTER="$GIS_OPT_RASTER"
 COLPREFIX="$GIS_OPT_COLPREFIX"
 
@@ -131,11 +130,15 @@
 : ${GISBASE?} ${GISDBASE?} ${LOCATION_NAME?} ${MAPSET?}
 
 # does map exist in CURRENT mapset?
-eval `g.findfile element=vector file="$VECTOR" mapset="$MAPSET"`
+eval `g.findfile element=vector file="$GIS_OPT_VECTOR" mapset="$MAPSET"`
 if [ ! "$file" ] ; then
-   g.message -e "Vector map <$VECTOR> not found"
+   g.message -e "Vector map <$GIS_OPT_VECTOR> not found in current mapset"
    exit 1
+else
+   VECTOR=`echo "$GIS_OPT_VECTOR" | cut -f1 -d'@'`
 fi
+
+
 #check the input raster map
 eval `g.findfile element=cell file="$RASTER"`
 if [ ! "$file" ] ; then



More information about the grass-commit mailing list