[GRASS-SVN] r46873 - grass/trunk/scripts/g.extension

svn_grass at osgeo.org svn_grass at osgeo.org
Thu Jun 30 10:53:06 EDT 2011


Author: martinl
Date: 2011-06-30 07:53:06 -0700 (Thu, 30 Jun 2011)
New Revision: 46873

Modified:
   grass/trunk/scripts/g.extension/g.extension.py
Log:
g.extension: fix creating addons subdirs (call os.makedirs)


Modified: grass/trunk/scripts/g.extension/g.extension.py
===================================================================
--- grass/trunk/scripts/g.extension/g.extension.py	2011-06-30 14:44:35 UTC (rev 46872)
+++ grass/trunk/scripts/g.extension/g.extension.py	2011-06-30 14:53:06 UTC (rev 46873)
@@ -355,7 +355,8 @@
     grass.message(_("Compiling '%s'...") % options['extension'])    
     if options['extension'] not in gui_list:
         for d in dirs.itervalues():
-            os.mkdir(d)
+            if not os.path.exists(d):
+                os.makedirs(d)
         
         ret = grass.call(makeCmd,
                          stdout = outdev)



More information about the grass-commit mailing list