[GRASS-SVN] r39919 -
grass/branches/develbranch_6/gui/wxpython/support
svn_grass at osgeo.org
svn_grass at osgeo.org
Sun Dec 6 06:26:20 EST 2009
Author: martinl
Date: 2009-12-06 06:26:20 -0500 (Sun, 06 Dec 2009)
New Revision: 39919
Modified:
grass/branches/develbranch_6/gui/wxpython/support/update_menudata.py
Log:
print error message when menudata.xml is not found
(merge r39918 from trunk)
Modified: grass/branches/develbranch_6/gui/wxpython/support/update_menudata.py
===================================================================
--- grass/branches/develbranch_6/gui/wxpython/support/update_menudata.py 2009-12-06 11:24:34 UTC (rev 39918)
+++ grass/branches/develbranch_6/gui/wxpython/support/update_menudata.py 2009-12-06 11:26:20 UTC (rev 39919)
@@ -98,11 +98,13 @@
def writeData(data):
"""!Write updated menudata.xml"""
- file = os.path.join('..', 'xml', 'menudata.xml')
+ file = os.path.join('xml', 'menudata.xml')
try:
+ if not os.path.exists(file):
+ raise IOError
data.tree.write(file)
except IOError:
- print >> sys.stderr, "'menudata.xml' not found. Please run the script from 'gui/wxpython/support'."
+ print >> sys.stderr, "'%s' not found. Please run the script from 'gui/wxpython'." % file
def main(argv = None):
More information about the grass-commit
mailing list