[GRASS-SVN] r56725 - grass-addons/grass6/raster/r.diversity

svn_grass at osgeo.org svn_grass at osgeo.org
Sat Jun 15 20:47:47 PDT 2013


Author: hamish
Date: 2013-06-15 20:47:47 -0700 (Sat, 15 Jun 2013)
New Revision: 56725

Modified:
   grass-addons/grass6/raster/r.diversity/r.diversity.py
Log:
fix path creation

Modified: grass-addons/grass6/raster/r.diversity/r.diversity.py
===================================================================
--- grass-addons/grass6/raster/r.diversity/r.diversity.py	2013-06-16 03:37:39 UTC (rev 56724)
+++ grass-addons/grass6/raster/r.diversity/r.diversity.py	2013-06-16 03:47:47 UTC (rev 56725)
@@ -106,16 +106,18 @@
     if alpha != '':
 	alpha_value = checkValues(alpha,True)
 	print alpha_value
+
     # check if ~/.r.li path exists
-    if not os.path.exists(home+'/.r.li/'):
+    if not os.path.exists(home + '/.r.li'):
 	# create ~/.r.li
-	os.path.mkdir(home+'/.r.li/')
+	os.mkdir(home + '/.r.li')
 	# create ~/.r.li/history
-	os.path.mkdir(home+'/.r.li/history')
+	os.mkdir(home + '/.r.li/history')
     else:
-	if not os.path.exists(home+'/.r.li/history'):
+	if not os.path.exists(home + '/.r.li/history'):
 	    # create ~/.r.li/history
-	    os.path.mkdir(home+'/.r.li/history')
+	    os.mkdir(home + '/.r.li/history')
+
     # set overwrite
     if grass.overwrite():
         env['GRASS_OVERWRITE'] = '1'



More information about the grass-commit mailing list