[GRASS-SVN] r38614 - grass-addons/vector/v.krige
svn_grass at osgeo.org
svn_grass at osgeo.org
Tue Aug 4 06:06:46 EDT 2009
Author: aghisla
Date: 2009-08-04 06:06:44 -0400 (Tue, 04 Aug 2009)
New Revision: 38614
Modified:
grass-addons/vector/v.krige/v.krige.py
Log:
corrected overwrite check
Modified: grass-addons/vector/v.krige/v.krige.py
===================================================================
--- grass-addons/vector/v.krige/v.krige.py 2009-08-04 08:36:54 UTC (rev 38613)
+++ grass-addons/vector/v.krige/v.krige.py 2009-08-04 10:06:44 UTC (rev 38614)
@@ -135,7 +135,7 @@
# R packages gstat or geoR
for each in ["gstat", "spgrass6"]:
- if not robjects.r.require(each, verbose=False):
+ if not robjects.r.require(each, quietly=True):
sys.exit(_("R package " + each + " is missing. Install it and re-run v.krige."))
# globals
@@ -583,7 +583,7 @@
options, flags = argv
#CLI
#@TODO: Work on verbosity. Sometimes it's too verbose (R), sometimes not enough.
- print options
+ #print options
# re-cast integers from strings, as parser() cast everything to string.
for each in ("sill","nugget","range"):
if options[each] is not '':
@@ -602,8 +602,8 @@
options['output'] = options['input'] + '_kriging'
# check for output map with same name. g.parser can't handle this, afaik.
- if grass.find_file(options['output'], element = 'cell')['fullname'] and os.getenv("GRASS_OVERWRITE") == 1:
- grass.fatal(_("option: <output>: Raster map already exists."))
+ if grass.find_file(options['output'], element = 'cell')['fullname'] and os.getenv("GRASS_OVERWRITE") == None:
+ grass.fatal(_("option: <output>: Raster map already exists."))
if options['model'] is '':
try:
More information about the grass-commit
mailing list